From michael.yuan at jboss.com  Fri Dec  1 00:17:59 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 00:17:59 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources  ...
Message-ID: <E1Gq0md-0008BR-5U@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 00:17:59

  Modified:    examples/hibernate2/resources  web.xml
  Log:
  oops, the full DTDs do not work in weblogic. Forgot to change it ...
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/examples/hibernate2/resources/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/web.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- web.xml	8 Nov 2006 10:01:02 -0000	1.1
  +++ web.xml	1 Dec 2006 05:17:59 -0000	1.2
  @@ -1 +1 @@
  -<?xml version="1.0" encoding="UTF-8"?>
<web-app version="2.5"
    xmlns="http://java.sun.com/xml/ns/javaee"    
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"    
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">   
      
    <context-param>      
      <param-name>javax.faces.CONFIG_FILES</param-name>      
      <param-value>/WEB-INF/navigation.xml</param-value>   
    </context-param>	   
    
    <!-- Ajax4jsf (must come first!) -->		   
    <filter>     
      <display-name>Ajax4jsf Filter</display-name>     
      <filter-name>ajax4jsf</filter-name>     
      <filter-class>org.ajax4jsf.Filter</filter-class>   
    </filter>	   
    <filter-mapping>     
      <filter-name>ajax4jsf</filter-name>     
      <url-pattern>*.seam</url-pattern>   
    </filter-mapping>   
    <context-param>     
      <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>     
      <param-value>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</param-value>   
    </context-param>        
    
    <!-- Seam -->           
    <listener>              
      <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>        
    </listener>    
    <!-- Propagate conversations across redirects -->    
    <filter>        
      <filter-name>Seam Redirect Filter</filter-name>        
      <filter-class>org.jboss.seam.servlet.SeamRedirectFilter</filter-class>    
    </filter>        
    <filter-mapping>        
      <filter-name>Seam Redirect Filter</filter-name>        
      <url-pattern>*.seam</url-pattern>    
    </filter-mapping>    
    <filter>        
      <filter-name>Seam Exception Filter</filter-name>        
      <filter-class>org.jboss.seam.servlet.SeamExceptionFilter</filter-class>    
    </filter>        
    <filter-mapping>        
      <filter-name>Seam Exception Filter</filter-name>        
      <url-pattern>*.seam</url-pattern>    
    </filter-mapping>      
    
    <!-- Faces Servlet -->    
    <servlet>              
      <servlet-name>Faces Servlet</servlet-name>              
      <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>              
      <load-on-startup>1</load-on-startup>        
    </servlet>    
    <!-- Faces Servlet Mapping -->    
    <servlet-mapping>              
      <servlet-name>Faces Servlet</servlet-name>              
      <url-pattern>*.seam</url-pattern>        
    </servlet-mapping>
    <!-- JSF parameters -->  
    <context-param>              
      <param-name>javax.faces.STATE_SAVING_METHOD</param-name>              
      <param-value>client</param-value>        
    </context-param>    
    <context-param>        
      <param-name>javax.faces.DEFAULT_SUFFIX</param-name>        
      <param-value>.xhtml</param-value>    
    </context-param>    
    <context-param>        
      <param-name>facelets.DEVELOPMENT</param-name>        
      <param-value>true</param-value>    
    </context-param>  
    
    <!-- MyFaces -->    
    <listener>        
      <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>    
    </listener>     
    
</web-app>
  \ No newline at end of file
  +<?xml version="1.0" encoding="UTF-8"?>
<web-app>   
      
    <context-param>      
      <param-name>javax.faces.CONFIG_FILES</param-name>      
      <param-value>/WEB-INF/navigation.xml</param-value>   
    </context-param>	   
    
    <!-- Ajax4jsf (must come first!) -->		   
    <filter>     
      <display-name>Ajax4jsf Filter</display-name>     
      <filter-name>ajax4jsf</filter-name>     
      <filter-class>org.ajax4jsf.Filter</filter-class>   
    </filter>	   
    <filter-mapping>     
      <filter-name>ajax4jsf</filter-name>     
      <url-pattern>*.seam</url-pattern>   
    </filter-mapping>   
    <context-param>     
      <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name>     
      <param-value>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</param-value>   
    </context-param>        
    
    <!-- Seam -->           
    <listener>              
      <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>        
    </listener>    
    <!-- Propagate conversations across redirects -->    
    <filter>        
      <filter-name>Seam Redirect Filter</filter-name>        
      <filter-class>org.jboss.seam.servlet.SeamRedirectFilter</filter-class>    
    </filter>        
    <filter-mapping>        
      <filter-name>Seam Redirect Filter</filter-name>        
      <url-pattern>*.seam</url-pattern>    
    </filter-mapping>    
    <filter>        
      <filter-name>Seam Exception Filter</filter-name>        
      <filter-class>org.jboss.seam.servlet.SeamExceptionFilter</filter-class>    
    </filter>        
    <filter-mapping>        
      <filter-name>Seam Exception Filter</filter-name>        
      <url-pattern>*.seam</url-pattern>    
    </filter-mapping>      
    
    <!-- Faces Servlet -->    
    <servlet>              
      <servlet-name>Faces Servlet</servlet-name>              
      <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>              
      <load-on-startup>1</load-on-startup>        
    </servlet>    
    <!-- Faces Servlet Mapping -->    
    <servlet-mapping>              
      <servlet-name>Faces Servlet</servlet-name>              
      <url-pattern>*.seam</url-pattern>        
    </servlet-mapping>
    <!-- JSF parameters -->  
    <context-param>              
      <param-name>javax.faces.STATE_SAVING_METHOD</param-name>              
      <param-value>client</param-value>        
    </context-param>    
    <context-param>        
      <param-name>javax.faces.DEFAULT_SUFFIX</param-name>        
      <param-value>.xhtml</param-value>    
    </context-param>    
    <context-param>        
      <param-name>facelets.DEVELOPMENT</param-name>        
      <param-value>true</param-value>    
    </context-param>  
    
    <!-- MyFaces -->    
    <listener>        
      <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>    
    </listener>     
    
</web-app>
  \ No newline at end of file
  
  
  


From forge-admin at jboss.com  Fri Dec  1 01:00:29 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Fri, 01 Dec 2006 01:00:29 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gq1Rl-0000Nb-Gh@committer01.frg.pub.inap.atl.jboss.com>

Commit from myuan (2006-11-30 01:39 EST)
-----------------

add GF support

  jboss-seam  examples/jpa/build.xml                            1.6
+ jboss-seam  examples/jpa/readme.txt                           1.1
+ jboss-seam  examples/jpa/resources/glassfish/log4j.xml        1.1
+ jboss-seam  examples/jpa/resources/glassfish/persistence.xml  1.1
+ jboss-seam  examples/jpa/resources/glassfish/web.xml          1.1


Commit from gavin (2006-11-30 05:24 EST)
-----------------

hibernate dist

  jboss-seam  build.xml             1.114
+ jboss-seam  hibernate/readme.txt  1.1


Commit from mandersen (2006-11-30 06:26 EST)
---------------------

no longer generate @Length for temporal and manytoone
no longer cascade = { } and other noisy empty annotation attributes

  jboss-seam  seam-gen/pojo/GetPropertyAnnotation.ftl  1.2
  jboss-seam  seam-gen/lib/hibernate-tools.jar         1.4


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-11-30 08:44 EST)
------------------------------------------------------

Don't try and measure timeouts

  JBossCache  tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java  1.1.16.4


Commit from gavin (2006-11-30 09:01 EST)
-----------------

changelog

  jboss-seam  changelog.txt  1.31


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-11-30 09:18 EST)
------------------------------------------------------

wc

  JBossCache  src/org/jboss/cache/TreeCache.java                                           1.142.2.6
  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderWithReplicationTest.java  1.16.2.2
  JBossCache  tests/functional/org/jboss/cache/loader/TxCacheLoaderTest.java               1.2.2.1
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java             1.14.2.7


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-11-30 11:10 EST)
------------------------------------------------------

wc

  JBossCache  tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java         1.7.2.5
  JBossCache  tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java  1.5.2.1


Commit from rawb (2006-11-30 11:10 EST)
----------------

EventLogMajorType extension... ...

+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/schema/EventLogMajorType.exsd  1.1
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml                     1.25


Commit from rawb (2006-11-30 11:11 EST)
----------------

Commented out useless preference page

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java  1.3


Commit from rawb (2006-11-30 11:13 EST)
----------------

Added preferences page

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java  1.4


Commit from rawb (2006-11-30 11:14 EST)
----------------

Accounted for module publish state

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java  1.16


Commit from rawb (2006-11-30 11:14 EST)
----------------

API change, added modulePublishState info

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java      1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPublisher.java           1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/IJBossServerPublisher.java  1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PathPublisher.java          1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/NullPublisher.java          1.2


Commit from rawb (2006-11-30 11:16 EST)
----------------

Added a comparator to stop exceptions from killing my mojo

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/PackagesBuildListener.java  1.2


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-11-30 11:23 EST)
------------------------------------------------------

removed WL contention on root node

  JBossCache  tests/stress/org/jboss/cache/LocalStressTest.java  1.2.2.1


Commit from vralev (2006-11-30 11:29 EST)
------------------

support for patch2

    repository.jboss.com/jboss/izpack-listeners/1.0.1.GA/component-info.xml  1.4


Commit from vralev (2006-11-30 11:40 EST)
------------------

I18N patch

+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/izevent.jar              1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/liquidlnf.jar            1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/uninstaller.jar          1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/standalone-compiler.jar  1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/looks.jar                1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/uninstaller-ext.jar      1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/jakarta-regexp-1.3.jar   1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/metouia.jar              1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/bin.zip                  1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/installer.jar            1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/compiler.jar             1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/kunststoff.jar           1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/ant.jar                  1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch2/component-info.xml           1.1


Commit from rawb (2006-11-30 12:53 EST)
----------------

Small fix to remove duplicate proposals in attributes

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLEditorConfiguration.java  1.2


Commit from jwilliams (2006-11-30 13:44 EST)
---------------------

fixed jira issue JBSEAM-543

  jboss-seam  seam-gen/build-scripts/build.xml  1.13


Commit from myuan (2006-11-30 15:59 EST)
-----------------

work around for GF

  jboss-seam  examples/jpa/src/org/jboss/seam/example/jpa/Booking.java  1.2


Commit from myuan (2006-11-30 16:03 EST)
-----------------

GF work around

  jboss-seam  examples/hibernate2/src/org/jboss/seam/example/hibernate/Booking.java  1.2


Commit from remm (2006-11-30 17:44 EST)
----------------

- New snapshot.

  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/el-api.jar           1.9
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jbossweb-extras.jar  1.6
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jbossweb.jar         1.24
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jsp-api.jar          1.7
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/servlet-api.jar      1.6
+ repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jbossweb-src.zip     1.1


Commit from gavin (2006-11-30 19:48 EST)
-----------------

better

  jboss-seam  seam-gen/build-scripts/build.xml  1.14


Commit from gavin (2006-11-30 22:05 EST)
-----------------

make it work on tomcat

  jboss-seam  examples/icefaces/build.xml                           1.5
  jboss-seam  examples/icefaces/resources/META-INF/jboss-beans.xml  1.3


Commit from myuan (2006-12-01 00:17 EST)
-----------------

oops, the full DTDs do not work in weblogic. Forgot to change it ...

  jboss-seam  examples/hibernate2/resources/web.xml  1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061201/214fd1b9/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:47:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:47:30 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1671 - in
	branches/Branch_1_0_1_SP/src/main/org/jboss:
	jms/server/endpoint messaging/core
Message-ID: <E1Gq4zS-0004ev-R9@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-01 04:47:27 -0500 (Fri, 01 Dec 2006)
New Revision: 1671

Modified:
   branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
Log:
More tweaks



Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-01 00:57:42 UTC (rev 1670)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-01 09:47:27 UTC (rev 1671)
@@ -904,15 +904,26 @@
       public synchronized void afterCommit(boolean onePhase) throws TransactionException
       {
          // Remove the deliveries from the delivery map.
-         Iterator iter = delList.iterator();
-         while (iter.hasNext())
+         
+         synchronized (lock)
          {
-            Long messageID = (Long)iter.next();
-
-            if (deliveries.remove(messageID) == null)
+            if (closed)
             {
-               throw new TransactionException("Failed to remove delivery " + messageID);
+               //We must throw an exception to the client otherwise they may think the commit has succeeded
+               //This can happen if the connection is closed by another thread - e.g. the leasePinger
+               throw new TransactionException("Failed to acknowledge message, session has been closed");
             }
+            
+            Iterator iter = delList.iterator();
+            while (iter.hasNext())
+            {
+               Long messageID = (Long)iter.next();
+   
+               if (deliveries.remove(messageID) == null)
+               {
+                  throw new TransactionException("Failed to remove delivery " + messageID);
+               }
+            }
          }
       }
 

Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-01 00:57:42 UTC (rev 1670)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-01 09:47:27 UTC (rev 1671)
@@ -753,7 +753,7 @@
 
                            iter = messageRefs.iterator();
 
-                           //And skip the next one (that's the one we just added back)
+                           //And skip the first one (that's the one we just added back)
 
                            iter.next();
                         }



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:50:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:50:11 -0500
Subject: [jboss-cvs] JBossAS SVN: r58795 -
	branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1Gq523-0004gD-45@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-01 04:50:08 -0500 (Fri, 01 Dec 2006)
New Revision: 58795

Added:
   branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java
Log:
JBAS3861, rename the test case so it's picked up automatically

Copied: branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java (from rev 58726, branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java)
===================================================================
--- branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-11-29 11:20:10 UTC (rev 58726)
+++ branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java	2006-12-01 09:50:08 UTC (rev 58795)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.test.console.jbas3861; 
+
+import javax.management.Attribute;
+import javax.management.ObjectName;
+import javax.management.RuntimeMBeanException;
+
+import org.jboss.mx.util.ObjectNameFactory;
+import org.jboss.test.JBossTestCase;
+
+/**
+ * Test JBAS-3861 (DeploymentFileRepository service)
+ * 
+ *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ *  @version $Revision: 57211 $
+ */
+public class JBAS3861UnitTestCase extends JBossTestCase
+{
+   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
+   
+   public JBAS3861UnitTestCase(String name)
+   {
+      super(name); 
+   }
+   
+   /**
+    * Check if BaseDir can be set outside the server home directory
+    */
+   public void testSetBaseDirOutsideServerHomeDir() throws Exception
+   {
+      // remember original BaseDir
+      String basedir = (String)getServer().getAttribute(target, "BaseDir");
+      try
+      {
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
+         
+         // Restore the original dir and fail the test
+         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
+         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   }   
+   
+   /**
+    * Check if we can write a file outside the server home directory
+    */
+   public void testStoreFileOutsideServerHomeDir() throws Exception
+   {
+      try
+      {
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
+
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
+         
+         // Remove the stored file and fail the test - normally it should throw an exception, too
+         getServer().invoke(
+               target,
+               "remove",
+               new Object[] { ".", "../jbas3861", ".tmp" },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
+         
+         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   } 
+   
+}



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:52:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:52:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r58796 -
	branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1Gq54J-0004kW-HN@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-01 04:52:26 -0500 (Fri, 01 Dec 2006)
New Revision: 58796

Added:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java
Log:
JBAS-3861, rename the test case so it's picked up automatically

Copied: branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java (from rev 58723, branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java)
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-11-29 11:15:52 UTC (rev 58723)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java	2006-12-01 09:52:26 UTC (rev 58796)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.test.console.jbas3861; 
+
+import javax.management.Attribute;
+import javax.management.ObjectName;
+import javax.management.RuntimeMBeanException;
+
+import org.jboss.mx.util.ObjectNameFactory;
+import org.jboss.test.JBossTestCase;
+
+/**
+ * Test JBAS-3861 (DeploymentFileRepository service)
+ * 
+ *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ *  @version $Revision: 57211 $
+ */
+public class JBAS3861UnitTestCase extends JBossTestCase
+{
+   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
+   
+   public JBAS3861UnitTestCase(String name)
+   {
+      super(name); 
+   }
+   
+   /**
+    * Check if BaseDir can be set outside the server home directory
+    */
+   public void testSetBaseDirOutsideServerHomeDir() throws Exception
+   {
+      // remember original BaseDir
+      String basedir = (String)getServer().getAttribute(target, "BaseDir");
+      try
+      {
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
+         
+         // Restore the original dir and fail the test
+         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
+         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   }   
+   
+   /**
+    * Check if we can write a file outside the server home directory
+    */
+   public void testStoreFileOutsideServerHomeDir() throws Exception
+   {
+      try
+      {
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
+
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
+         
+         // Remove the stored file and fail the test - normally it should throw an exception, too
+         getServer().invoke(
+               target,
+               "remove",
+               new Object[] { ".", "../jbas3861", ".tmp" },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
+         
+         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   } 
+   
+}



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:53:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:53:46 -0500
Subject: [jboss-cvs] JBossAS SVN: r58797 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1Gq55W-0004lE-4t@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-01 04:53:42 -0500 (Fri, 01 Dec 2006)
New Revision: 58797

Added:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java
Removed:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
Log:


Deleted: branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:52:26 UTC (rev 58796)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:53:42 UTC (rev 58797)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.test.console.jbas3861; 
-
-import javax.management.Attribute;
-import javax.management.ObjectName;
-import javax.management.RuntimeMBeanException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.JBossTestCase;
-
-/**
- * Test JBAS-3861 (DeploymentFileRepository service)
- * 
- *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- *  @version $Revision: 57211 $
- */
-public class JBAS3861TestCase extends JBossTestCase
-{
-   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
-   
-   public JBAS3861TestCase(String name)
-   {
-      super(name); 
-   }
-   
-   /**
-    * Check if BaseDir can be set outside the server home directory
-    */
-   public void testSetBaseDirOutsideServerHomeDir() throws Exception
-   {
-      // remember original BaseDir
-      String basedir = (String)getServer().getAttribute(target, "BaseDir");
-      try
-      {
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
-         
-         // Restore the original dir and fail the test
-         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
-         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   }   
-   
-   /**
-    * Check if we can write a file outside the server home directory
-    */
-   public void testStoreFileOutsideServerHomeDir() throws Exception
-   {
-      try
-      {
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
-
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
-         
-         // Remove the stored file and fail the test - normally it should throw an exception, too
-         getServer().invoke(
-               target,
-               "remove",
-               new Object[] { ".", "../jbas3861", ".tmp" },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
-         
-         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   } 
-   
-}

Copied: branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java (from rev 58725, branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java)
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-11-29 11:19:37 UTC (rev 58725)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java	2006-12-01 09:53:42 UTC (rev 58797)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.test.console.jbas3861; 
+
+import javax.management.Attribute;
+import javax.management.ObjectName;
+import javax.management.RuntimeMBeanException;
+
+import org.jboss.mx.util.ObjectNameFactory;
+import org.jboss.test.JBossTestCase;
+
+/**
+ * Test JBAS-3861 (DeploymentFileRepository service)
+ * 
+ *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ *  @version $Revision: 57211 $
+ */
+public class JBAS3861UnitTestCase extends JBossTestCase
+{
+   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
+   
+   public JBAS3861UnitTestCase(String name)
+   {
+      super(name); 
+   }
+   
+   /**
+    * Check if BaseDir can be set outside the server home directory
+    */
+   public void testSetBaseDirOutsideServerHomeDir() throws Exception
+   {
+      // remember original BaseDir
+      String basedir = (String)getServer().getAttribute(target, "BaseDir");
+      try
+      {
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
+         
+         // Restore the original dir and fail the test
+         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
+         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   }   
+   
+   /**
+    * Check if we can write a file outside the server home directory
+    */
+   public void testStoreFileOutsideServerHomeDir() throws Exception
+   {
+      try
+      {
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
+
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
+         
+         // Remove the stored file and fail the test - normally it should throw an exception, too
+         getServer().invoke(
+               target,
+               "remove",
+               new Object[] { ".", "../jbas3861", ".tmp" },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
+         
+         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   } 
+   
+}



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:54:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:54:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r58798 -
	branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1Gq55s-0004lX-7p@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-01 04:54:06 -0500 (Fri, 01 Dec 2006)
New Revision: 58798

Removed:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
Log:
JBAS-3861, rename the test case so it's picked up automatically

Deleted: branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:53:42 UTC (rev 58797)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:54:06 UTC (rev 58798)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.test.console.jbas3861; 
-
-import javax.management.Attribute;
-import javax.management.ObjectName;
-import javax.management.RuntimeMBeanException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.JBossTestCase;
-
-/**
- * Test JBAS-3861 (DeploymentFileRepository service)
- * 
- *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- *  @version $Revision: 57211 $
- */
-public class JBAS3861TestCase extends JBossTestCase
-{
-   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
-   
-   public JBAS3861TestCase(String name)
-   {
-      super(name); 
-   }
-   
-   /**
-    * Check if BaseDir can be set outside the server home directory
-    */
-   public void testSetBaseDirOutsideServerHomeDir() throws Exception
-   {
-      // remember original BaseDir
-      String basedir = (String)getServer().getAttribute(target, "BaseDir");
-      try
-      {
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
-         
-         // Restore the original dir and fail the test
-         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
-         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   }   
-   
-   /**
-    * Check if we can write a file outside the server home directory
-    */
-   public void testStoreFileOutsideServerHomeDir() throws Exception
-   {
-      try
-      {
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
-
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
-         
-         // Remove the stored file and fail the test - normally it should throw an exception, too
-         getServer().invoke(
-               target,
-               "remove",
-               new Object[] { ".", "../jbas3861", ".tmp" },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
-         
-         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   } 
-   
-}



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:54:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:54:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r58799 -
	branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1Gq56E-0004lq-1c@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-01 04:54:28 -0500 (Fri, 01 Dec 2006)
New Revision: 58799

Removed:
   branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
Log:
JBAS-3861, rename the test case so it's picked up automatically

Deleted: branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
===================================================================
--- branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:54:06 UTC (rev 58798)
+++ branches/Branch_3_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:54:28 UTC (rev 58799)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.test.console.jbas3861; 
-
-import javax.management.Attribute;
-import javax.management.ObjectName;
-import javax.management.RuntimeMBeanException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.JBossTestCase;
-
-/**
- * Test JBAS-3861 (DeploymentFileRepository service)
- * 
- *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- *  @version $Revision: 57211 $
- */
-public class JBAS3861TestCase extends JBossTestCase
-{
-   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
-   
-   public JBAS3861TestCase(String name)
-   {
-      super(name); 
-   }
-   
-   /**
-    * Check if BaseDir can be set outside the server home directory
-    */
-   public void testSetBaseDirOutsideServerHomeDir() throws Exception
-   {
-      // remember original BaseDir
-      String basedir = (String)getServer().getAttribute(target, "BaseDir");
-      try
-      {
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
-         
-         // Restore the original dir and fail the test
-         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
-         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   }   
-   
-   /**
-    * Check if we can write a file outside the server home directory
-    */
-   public void testStoreFileOutsideServerHomeDir() throws Exception
-   {
-      try
-      {
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
-
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
-         
-         // Remove the stored file and fail the test - normally it should throw an exception, too
-         getServer().invoke(
-               target,
-               "remove",
-               new Object[] { ".", "../jbas3861", ".tmp" },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
-         
-         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   } 
-   
-}



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 04:55:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 04:55:28 -0500
Subject: [jboss-cvs] JBossAS SVN: r58800 -
	trunk/testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1Gq57A-0004nf-JR@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-01 04:55:25 -0500 (Fri, 01 Dec 2006)
New Revision: 58800

Added:
   trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java
Removed:
   trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
Log:
JBAS-3861, rename the test case so it's picked up automatically

Deleted: trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:54:28 UTC (rev 58799)
+++ trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-12-01 09:55:25 UTC (rev 58800)
@@ -1,106 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.test.console.jbas3861; 
-
-import javax.management.Attribute;
-import javax.management.ObjectName;
-import javax.management.RuntimeMBeanException;
-
-import org.jboss.mx.util.ObjectNameFactory;
-import org.jboss.test.JBossTestCase;
-
-/**
- * Test JBAS-3861 (DeploymentFileRepository service)
- * 
- *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- *  @version $Revision: 57211 $
- */
-public class JBAS3861TestCase extends JBossTestCase
-{
-   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
-   
-   public JBAS3861TestCase(String name)
-   {
-      super(name); 
-   }
-   
-   /**
-    * Check if BaseDir can be set outside the server home directory
-    */
-   public void testSetBaseDirOutsideServerHomeDir() throws Exception
-   {
-      // remember original BaseDir
-      String basedir = (String)getServer().getAttribute(target, "BaseDir");
-      try
-      {
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
-         // Should throw an IllegalArgumentException
-         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
-         
-         // Restore the original dir and fail the test
-         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
-         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   }   
-   
-   /**
-    * Check if we can write a file outside the server home directory
-    */
-   public void testStoreFileOutsideServerHomeDir() throws Exception
-   {
-      try
-      {
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
-
-         // Should throw an exception
-         getServer().invoke(
-               target,
-               "store",
-               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
-         
-         // Remove the stored file and fail the test - normally it should throw an exception, too
-         getServer().invoke(
-               target,
-               "remove",
-               new Object[] { ".", "../jbas3861", ".tmp" },
-               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
-         
-         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
-      }
-      catch (RuntimeMBeanException e)
-      {
-         // expected
-      }
-   } 
-   
-}

Copied: trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java (from rev 58724, trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java)
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861TestCase.java	2006-11-29 11:19:06 UTC (rev 58724)
+++ trunk/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java	2006-12-01 09:55:25 UTC (rev 58800)
@@ -0,0 +1,106 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.test.console.jbas3861; 
+
+import javax.management.Attribute;
+import javax.management.ObjectName;
+import javax.management.RuntimeMBeanException;
+
+import org.jboss.mx.util.ObjectNameFactory;
+import org.jboss.test.JBossTestCase;
+
+/**
+ * Test JBAS-3861 (DeploymentFileRepository service)
+ * 
+ *  @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ *  @version $Revision: 57211 $
+ */
+public class JBAS3861UnitTestCase extends JBossTestCase
+{
+   ObjectName target= ObjectNameFactory.create("jboss.admin:service=DeploymentFileRepository");
+   
+   public JBAS3861UnitTestCase(String name)
+   {
+      super(name); 
+   }
+   
+   /**
+    * Check if BaseDir can be set outside the server home directory
+    */
+   public void testSetBaseDirOutsideServerHomeDir() throws Exception
+   {
+      // remember original BaseDir
+      String basedir = (String)getServer().getAttribute(target, "BaseDir");
+      try
+      {
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", ".."));
+         // Should throw an IllegalArgumentException
+         getServer().setAttribute(target, new Attribute("BaseDir", "/"));
+         
+         // Restore the original dir and fail the test
+         getServer().setAttribute(target, new Attribute("BaseDir", basedir));
+         fail("Managed to set BaseDir outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   }   
+   
+   /**
+    * Check if we can write a file outside the server home directory
+    */
+   public void testStoreFileOutsideServerHomeDir() throws Exception
+   {
+      try
+      {
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { "..", "jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });
+
+         // Should throw an exception
+         getServer().invoke(
+               target,
+               "store",
+               new Object[] { ".", "../jbas3861", ".tmp", "file content", Boolean.TRUE },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String", "java.lang.String", Boolean.TYPE.toString() });         
+         
+         // Remove the stored file and fail the test - normally it should throw an exception, too
+         getServer().invoke(
+               target,
+               "remove",
+               new Object[] { ".", "../jbas3861", ".tmp" },
+               new String[] { "java.lang.String", "java.lang.String", "java.lang.String" });  
+         
+         fail("Managed to create/remove a file outside ServerHomeDir for service: " + target);
+      }
+      catch (RuntimeMBeanException e)
+      {
+         // expected
+      }
+   } 
+   
+}



From c42 at fullmailmarket.com  Fri Dec  1 06:06:09 2006
From: c42 at fullmailmarket.com (TARGET-DDI)
Date: Fri, 1 Dec 2006 08:06:09 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Seminario_de_Negociaci=F3n_Aventajada?=
	=?iso-8859-1?q?=2E?=
Message-ID: <200612011106.kB1B6CdZ021364@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061201/a16facb8/attachment.html 

From gavin.king at jboss.com  Fri Dec  1 06:34:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 06:34:02 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util  ...
Message-ID: <E1Gq6eY-0006e2-01@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 06:34:01

  Modified:    src/main/org/jboss/seam/util  EL.java
  Log:
  fix JBSEAM-544
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/src/main/org/jboss/seam/util/EL.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EL.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/EL.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- EL.java	26 Oct 2006 17:42:24 -0000	1.1
  +++ EL.java	1 Dec 2006 11:34:01 -0000	1.2
  @@ -27,10 +27,10 @@
      {
         CompositeELResolver resolver = new CompositeELResolver();
         resolver.add( new SeamELResolver() );
  -      resolver.add( new BeanELResolver() );
         resolver.add( new MapELResolver() );
         resolver.add( new ListELResolver() );
         resolver.add( new ResourceBundleELResolver() );
  +      resolver.add( new BeanELResolver() );
         return resolver;
      }
   
  
  
  


From gavin.king at jboss.com  Fri Dec  1 06:34:06 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 06:34:06 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gq6ec-0006e9-W9@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 06:34:06

  Modified:    src/main/org/jboss/seam/core  TaskInstanceList.java
  Log:
  fix JBSEAM-544
  
  Revision  Changes    Path
  1.13      +1 -1      jboss-seam/src/main/org/jboss/seam/core/TaskInstanceList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TaskInstanceList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TaskInstanceList.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- TaskInstanceList.java	24 Nov 2006 23:15:17 -0000	1.12
  +++ TaskInstanceList.java	1 Dec 2006 11:34:05 -0000	1.13
  @@ -18,7 +18,7 @@
    * 
    * @see TaskInstanceListForType
    * @see PooledTask
  - * @author <a href="mailto:steve at hibernate.org">Steve Ebersole </a>
  + * @author <a href="mailto:steve at hibernate.org">Steve Ebersole</a>
    * @author Gavin King
    */
   @Name("org.jboss.seam.core.taskInstanceList")
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 07:23:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 07:23:33 -0500
Subject: [jboss-cvs] JBossAS SVN: r58801 -
	branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server
Message-ID: <E1Gq7QT-0007oQ-U3@committer01.frg.pub.inap.atl.jboss.com>

Author: vicky.kak at jboss.com
Date: 2006-12-01 07:23:30 -0500 (Fri, 01 Dec 2006)
New Revision: 58801

Modified:
   branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImplMBean.java
Log:
Changes Done for ASPATCH-124

Modified: branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImplMBean.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImplMBean.java	2006-12-01 09:55:25 UTC (rev 58800)
+++ branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImplMBean.java	2006-12-01 12:23:30 UTC (rev 58801)
@@ -20,6 +20,11 @@
     */
   boolean isStarted() ;
 
+   /** 
+	* A flag indicating if shutdown has been called. 
+	*/
+  boolean isInShutdown();
+  
    /**
     * Shutdown the Server instance and run shutdown hooks. <p>If the exit on shutdown flag is true, then {@link #exit} is called, else only the shutdown hook is run.
     * @throws IllegalStateException No started.    */



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 07:25:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 07:25:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r58802 -
	branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server
Message-ID: <E1Gq7SY-0007qT-OL@committer01.frg.pub.inap.atl.jboss.com>

Author: vicky.kak at jboss.com
Date: 2006-12-01 07:25:39 -0500 (Fri, 01 Dec 2006)
New Revision: 58802

Modified:
   branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImpl.java
Log:
Changes Done for ASPATCH-124

Modified: branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImpl.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImpl.java	2006-12-01 12:23:30 UTC (rev 58801)
+++ branches/JBoss_4_0_3_SP1_CP/system/src/main/org/jboss/system/server/ServerImpl.java	2006-12-01 12:25:39 UTC (rev 58802)
@@ -100,6 +100,9 @@
    /** The bootstrap UCL class loader ObjectName */
    private ObjectName bootstrapUCLName;
 
+   /** A flag indicating if shutdown has been called */
+   private boolean isInShutdown;
+   
    /**
     * No-arg constructor for {@link ServerLoader}.
     */
@@ -304,6 +307,16 @@
    }
 
    /**
+    * Check if the shutdown operation has been called/is in progress.
+    *
+    * @return true if shutdown has been called, false otherwise
+	*/
+    public boolean isInShutdown()
+    {
+	  return isInShutdown;
+    }
+   
+   /**
     * Start the Server instance.
     *
     * @throws IllegalStateException    Already started or not initialized.
@@ -621,6 +634,7 @@
       Notification msg = new Notification(STOP_NOTIFICATION_TYPE, this, 2);
       sendNotification(msg);
 
+      isInShutdown = true;
       boolean exitOnShutdown = config.getExitOnShutdown();
       boolean blockingShutdown = config.getBlockingShutdown();
       log.debug("Shutdown operation called, exitOnShutdown: " + exitOnShutdown
@@ -958,6 +972,7 @@
       public void shutdown()
       {
          log.info("JBoss SHUTDOWN: Undeploying all packages");
+         isInShutdown = true;
          if( log.isTraceEnabled() )
             log.trace("Shutdown caller:", new Throwable("Here"));
          shutdownDeployments();



From validimir.ralev at jboss.com  Fri Dec  1 07:29:05 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 01 Dec 2006 07:29:05 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch2/lib  ...
Message-ID: <E1Gq7Vp-0007uC-GR@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/01 07:29:05

  Modified:    repository.jboss.com/izpack/3.9.0.jboss.patch2/lib 
                        standalone-compiler.jar
  Log:
  fixed name
  
  Revision  Changes    Path
  1.2       +179 -167  /repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/standalone-compiler.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 07:44:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 07:44:52 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58803 - projects
Message-ID: <E1Gq7l6-0000G2-9i@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-01 07:44:49 -0500 (Fri, 01 Dec 2006)
New Revision: 58803

Added:
   projects/ejb3/
Log:




From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 07:46:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 07:46:41 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58804 - projects/ejb3
Message-ID: <E1Gq7mr-0000MO-6l@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-01 07:46:38 -0500 (Fri, 01 Dec 2006)
New Revision: 58804

Added:
   projects/ejb3/trunk/
Log:




From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 07:47:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 07:47:50 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58805 - projects/ejb3/trunk
Message-ID: <E1Gq7ny-0000R2-Qx@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-01 07:47:44 -0500 (Fri, 01 Dec 2006)
New Revision: 58805

Added:
   projects/ejb3/trunk/ejb3x/
Log:
Initial ejb3x binary plugin setup


Copied: projects/ejb3/trunk/ejb3x (from rev 58804, trunk/ejb3x)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 08:25:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 08:25:17 -0500
Subject: [jboss-cvs] JBossAS SVN: r58806 - in projects/ejb3/trunk/ejb3x: .
	.settings
Message-ID: <E1Gq8OD-0001pi-JO@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-01 08:25:10 -0500 (Fri, 01 Dec 2006)
New Revision: 58806

Added:
   projects/ejb3/trunk/ejb3x/.settings/
   projects/ejb3/trunk/ejb3x/.settings/org.eclipse.jdt.core.prefs
   projects/ejb3/trunk/ejb3x/pom.xml
Modified:
   projects/ejb3/trunk/ejb3x/
   projects/ejb3/trunk/ejb3x/.classpath
   projects/ejb3/trunk/ejb3x/.project
Log:
mavenized


Property changes on: projects/ejb3/trunk/ejb3x
___________________________________________________________________
Name: svn:ignore
   - output
build.log

   + output
build.log
target


Modified: projects/ejb3/trunk/ejb3x/.classpath
===================================================================
--- projects/ejb3/trunk/ejb3x/.classpath	2006-12-01 12:47:44 UTC (rev 58805)
+++ projects/ejb3/trunk/ejb3x/.classpath	2006-12-01 13:25:10 UTC (rev 58806)
@@ -1,11 +1,6 @@
-<?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-	<classpathentry kind="src" path="src/main"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="lib" path="/thirdparty/sun-servlet/lib/servlet-api.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/sun-jaf/lib/activation.jar"/>
-	<classpathentry kind="src" path="/j2ee"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
- <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
-	<classpathentry kind="output" path="output/eclipse-classes"/>
-</classpath>
+  <classpathentry kind="src" path="src/main"/>
+  <classpathentry kind="output" path="target/eclipse-classes"/>
+  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+  <classpathentry kind="var" path="M2_REPO/jboss/jboss-j2ee/4.0.2/jboss-j2ee-4.0.2.jar"/>
+</classpath>
\ No newline at end of file

Modified: projects/ejb3/trunk/ejb3x/.project
===================================================================
--- projects/ejb3/trunk/ejb3x/.project	2006-12-01 12:47:44 UTC (rev 58805)
+++ projects/ejb3/trunk/ejb3x/.project	2006-12-01 13:25:10 UTC (rev 58806)
@@ -1,17 +1,14 @@
-<?xml version="1.0" encoding="UTF-8"?>
 <projectDescription>
-	<name>ejb3x</name>
-	<comment></comment>
-	<projects>
-	</projects>
-	<buildSpec>
-		<buildCommand>
-			<name>org.eclipse.jdt.core.javabuilder</name>
-			<arguments>
-			</arguments>
-		</buildCommand>
-	</buildSpec>
-	<natures>
-		<nature>org.eclipse.jdt.core.javanature</nature>
-	</natures>
-</projectDescription>
+  <name>jboss-ejb3x</name>
+  <comment>The Java EJB 3.0 API classes</comment>
+  <projects/>
+  <buildSpec>
+    <buildCommand>
+      <name>org.eclipse.jdt.core.javabuilder</name>
+      <arguments/>
+    </buildCommand>
+  </buildSpec>
+  <natures>
+    <nature>org.eclipse.jdt.core.javanature</nature>
+  </natures>
+</projectDescription>
\ No newline at end of file

Added: projects/ejb3/trunk/ejb3x/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- projects/ejb3/trunk/ejb3x/.settings/org.eclipse.jdt.core.prefs	2006-12-01 12:47:44 UTC (rev 58805)
+++ projects/ejb3/trunk/ejb3x/.settings/org.eclipse.jdt.core.prefs	2006-12-01 13:25:10 UTC (rev 58806)
@@ -0,0 +1,5 @@
+#Fri Dec 01 14:19:26 CET 2006
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.source=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5

Added: projects/ejb3/trunk/ejb3x/pom.xml
===================================================================
--- projects/ejb3/trunk/ejb3x/pom.xml	2006-12-01 12:47:44 UTC (rev 58805)
+++ projects/ejb3/trunk/ejb3x/pom.xml	2006-12-01 13:25:10 UTC (rev 58806)
@@ -0,0 +1,102 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>jboss</groupId>
+  <artifactId>jboss-ejb3x</artifactId>
+  <packaging>jar</packaging>
+  <version>1.0.0.CR1</version>
+  <name>JBoss EJB 3.0 API</name>
+  <url>http://www.jboss.org</url>
+  <description>The Java EJB 3.0 API classes</description>
+  <licenses>
+   <license>
+      <name>lgpl</name>
+      <url>http://repository.jboss.com/licenses/lgpl.txt</url>
+   </license>
+  </licenses>
+  <organization>
+    <name>JBoss Inc.</name>
+    <url>http://www.jboss.org</url>
+  </organization>
+
+  <repositories>
+    <repository>
+      <id>jboss</id>
+      <name>JBoss Inc. Repository</name>
+      <layout>default</layout>
+      <url>http://repository.jboss.com/maven2/</url>
+      <snapshots>
+        <enabled>true</enabled>
+      </snapshots>
+    </repository>
+  </repositories>
+
+  <pluginRepositories>
+     <pluginRepository>
+        <id>jbosspluginrepo</id>
+        <name>jboss plugin repository</name>
+        <url>http://repository.jboss.com/maven2</url>
+        <layout>default</layout>
+        <snapshots>
+           <enabled>false</enabled>
+           <updatePolicy>never</updatePolicy>
+        </snapshots>
+     </pluginRepository>
+      <pluginRepository>
+        <id>central</id>
+        <name>LSU maven2 mirror</name>
+        <url>http://ibiblio.lsu.edu/main/pub/packages/maven2</url>
+        <layout>default</layout>
+        <snapshots>
+           <enabled>false</enabled>
+           <updatePolicy>never</updatePolicy>
+        </snapshots>
+     </pluginRepository>
+  </pluginRepositories>
+
+  
+  <build>
+    <sourceDirectory>src/main</sourceDirectory>
+    <finalName>${artifactId}</finalName>
+    <plugins>
+  
+
+    
+      <!-- define how we want compilation to take place
+           here, we accept most of the defaults but say that we want the
+           optimization flag set, and define the source and target to be 1.4,
+           these setting will be inherited by child projects -->
+      <plugin>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <version>2.0</version>
+          <configuration>
+              <optimize>true</optimize>
+              <source>1.5</source>
+              <target>1.5</target>
+          </configuration>
+      </plugin>  
+
+      <!-- define that we wish to create src jars -->
+      <plugin>
+        <artifactId>maven-source-plugin</artifactId>
+        <inherited>true</inherited>
+        <executions>
+          <execution>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+    
+    </plugins>
+  </build>
+
+  <dependencies>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-j2ee</artifactId>
+      <version>4.0.2</version>
+    </dependency>
+  </dependencies>
+</project>



From gavin.king at jboss.com  Fri Dec  1 08:26:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 08:26:18 -0500
Subject: [jboss-cvs] jboss-seam/src/main/META-INF  ...
Message-ID: <E1Gq8PC-0001s6-4t@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 08:26:18

  Modified:    src/main/META-INF  components.xml
  Log:
  add processInstanceList component (experimental)
  
  Revision  Changes    Path
  1.6       +1 -0      jboss-seam/src/main/META-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/META-INF/components.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- components.xml	30 Nov 2006 02:14:58 -0000	1.5
  +++ components.xml	1 Dec 2006 13:26:18 -0000	1.6
  @@ -35,6 +35,7 @@
     <factory scope="stateless" auto-create="true" name="switcher" value="#{org.jboss.seam.core.switcher}"/>
     <factory scope="stateless" auto-create="true" name="taskInstance" value="#{org.jboss.seam.core.taskInstance}"/>
     <factory scope="stateless" auto-create="true" name="taskInstanceList" value="#{org.jboss.seam.core.taskInstanceList}"/>
  +  <factory scope="stateless" auto-create="true" name="processInstanceList" value="#{org.jboss.seam.core.processInstanceList}"/>
     <factory scope="stateless" auto-create="true" name="taskInstanceListForType" value="#{org.jboss.seam.core.taskInstanceListForType}"/>
     <factory scope="stateless" auto-create="true" name="timeZone" value="#{org.jboss.seam.core.timeZone}"/>
     <factory scope="stateless" auto-create="true" name="timeZoneSelector" value="#{org.jboss.seam.core.timeZoneSelector}"/>
  
  
  


From gavin.king at jboss.com  Fri Dec  1 08:26:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 08:26:18 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gq8PC-0001sD-8N@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 08:26:18

  Added:       src/main/org/jboss/seam/core  ProcessInstanceList.java
  Log:
  add processInstanceList component (experimental)
  
  Revision  Changes    Path
  1.1      date: 2006/12/01 13:26:18;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/ProcessInstanceList.java
  
  Index: ProcessInstanceList.java
  ===================================================================
  package org.jboss.seam.core;
  
  import static org.jboss.seam.annotations.Install.BUILT_IN;
  
  import java.util.List;
  
  import org.hibernate.criterion.Order;
  import org.hibernate.criterion.Restrictions;
  import org.jboss.seam.annotations.Install;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Transactional;
  import org.jboss.seam.annotations.Unwrap;
  import org.jbpm.graph.exe.ProcessInstance;
  
  /**
   * Support for the process list.
   * 
   * @author Gavin King
   */
  @Name("org.jboss.seam.core.processInstanceList")
  @Install(precedence=BUILT_IN, dependencies="org.jboss.seam.core.jbpm")
  public class ProcessInstanceList
  {
     
     @Unwrap
     @Transactional
     public List<ProcessInstance> getTaskInstanceList()
     {
        return getProcessInstanceList();
     }
  
     private List<ProcessInstance> getProcessInstanceList()
     {
        return ManagedJbpmContext.instance()
              .getSession()
              .createCriteria(ProcessInstance.class)
              .add( Restrictions.isNull("end") )
              .createCriteria("rootToken")
                 .addOrder( Order.asc("nodeEnter") )
              .list();
     }
     
  }
  
  
  


From gavin.king at jboss.com  Fri Dec  1 08:27:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 08:27:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam  ...
Message-ID: <E1Gq8Qi-0001tW-AH@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 08:27:52

  Modified:    examples/dvdstore/src/com/jboss/dvd/seam 
                        StoreManagerBean.java
  Log:
  fix an npe and add process list
  
  Revision  Changes    Path
  1.9       +4 -3      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/StoreManagerBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StoreManagerBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/StoreManagerBean.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- StoreManagerBean.java	15 May 2006 21:33:28 -0000	1.8
  +++ StoreManagerBean.java	1 Dec 2006 13:27:52 -0000	1.9
  @@ -32,9 +32,10 @@
   
       public double getTotalSales() {
           try {
  -            return (Double) em.createQuery("select sum(o.totalAmount) from Order o where o.status != :status")
  +            Double totalSales = (Double) em.createQuery("select sum(o.totalAmount) from Order o where o.status != :status")
                   .setParameter("status", Order.Status.CANCELLED)
                   .getSingleResult();
  +            return totalSales==null ? 0.0 : totalSales;
           } catch (NoResultException e) {
               return 0.0;
           }
  
  
  


From gavin.king at jboss.com  Fri Dec  1 08:27:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 08:27:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web/admin  ...
Message-ID: <E1Gq8Qi-0001td-Dr@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 08:27:52

  Modified:    examples/dvdstore/web/admin  admin.xhtml
  Log:
  fix an npe and add process list
  
  Revision  Changes    Path
  1.4       +35 -0     jboss-seam/examples/dvdstore/web/admin/admin.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: admin.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/admin/admin.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- admin.xhtml	14 Nov 2006 05:03:01 -0000	1.3
  +++ admin.xhtml	1 Dec 2006 13:27:52 -0000	1.4
  @@ -166,6 +166,41 @@
                   </c:otherwise>
               </c:choose>
   
  +            <h2>Processes</h2>
  +            <c:choose>
  +                <c:when test="#{empty processInstanceList}">
  +                    <p>There are no active processes.</p>
  +                </c:when>
  +                <c:otherwise>
  +                    <h:dataTable value="#{processInstanceList}" var="process"
  +                            styleClass="dvdtable"
  +                            headerClass="dvdtablehead"
  +                            rowClasses="dvdtableodd,dvdtableeven"
  +                            columnClasses="dvdtablecol">
  +                        <h:column>
  +                             <f:facet name="header">Process Definition</f:facet>
  +                            #{process.processDefinition.name}
  +                        </h:column>
  +                        <h:column>
  +                            <f:facet name="header">Process Start</f:facet>
  +                            <h:outputText value="#{process.start}">
  +                                <s:convertDateTime type="both"/>
  +                            </h:outputText>
  +                        </h:column>
  +                        <h:column>
  +                            <f:facet name="header">Current Node</f:facet>
  +                            #{process.rootToken.node.name}
  +                        </h:column>
  +                        <h:column>
  +                            <f:facet name="header">Current Node Enter</f:facet>
  +                            <h:outputText value="#{process.rootToken.nodeEnter}">
  +                                <s:convertDateTime type="both"/>
  +                            </h:outputText>
  +                        </h:column>
  +                    </h:dataTable>
  +                </c:otherwise>
  +            </c:choose>
  +
           </f:subview>            
           </ui:define>
       </ui:composition>
  
  
  


From msurtani at jboss.com  Fri Dec  1 10:22:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 01 Dec 2006 10:22:44 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GqADs-0004Ag-2J@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/01 10:22:44

  Modified:    tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_3_0
                        IsolationLevelRepeatableReadTest.java
  Log:
  wc
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +64 -269   JBossCache/tests/functional/org/jboss/cache/transaction/Attic/IsolationLevelRepeatableReadTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelRepeatableReadTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/Attic/IsolationLevelRepeatableReadTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- IsolationLevelRepeatableReadTest.java	26 Nov 2006 11:52:05 -0000	1.1.2.1
  +++ IsolationLevelRepeatableReadTest.java	1 Dec 2006 15:22:44 -0000	1.1.2.2
  @@ -8,17 +8,20 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.TimeoutException;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.SystemException;
   import javax.transaction.Transaction;
   
  +import EDU.oswego.cs.dl.util.concurrent.Latch;
  +
   /**
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
    *
  - * @version $Id: IsolationLevelRepeatableReadTest.java,v 1.1.2.1 2006/11/26 11:52:05 msurtani Exp $
  + * @version $Id: IsolationLevelRepeatableReadTest.java,v 1.1.2.2 2006/12/01 15:22:44 msurtani Exp $
    */
   
   public class IsolationLevelRepeatableReadTest extends TestCase
  @@ -62,307 +65,99 @@
         cache=null;
      }
   
  -   public void testMultipleReaders() throws Exception
  +   /**
  +    * Test creates a cache node then starts a separate thread that removes
  +    * the node inside a tx. Test confirms that the removal cannot be seen
  +    * before the test commits.
  +    *
  +    * @throws Exception
  +    */
  +   public void testNodeRemoved() throws Exception
      {
  -      final Fqn fqn = Fqn.fromString("/test");
  -//      final Latch latch = new Latch();
  -      final Object lock = new Object();
  +      final Latch readerCanRead = new Latch();
  +      final Latch readerDone = new Latch();
  +      final Latch writerDone = new Latch();
  +
  +      cache.put(FQN, KEY, VALUE);
  +      assertEquals(VALUE, cache.get(FQN, KEY));
   
  -      class ReaderThread extends Thread
  +      // start a writer thread and a transaction
  +
  +      Thread writerThread = new Thread(new Runnable()
         {
            public void run()
            {
               try
               {
  -               cache.getTransactionManager().begin();
  -//               latch.acquire();
  -
  -               synchronized(lock)
  -               {
  -                  System.out.println(getName() + " waiting on lock");
  -                  lock.wait();
  -               }
  +               Transaction tx = startTransaction();
   
  -               assertNotNull(cache.get(fqn));
  +               // change VALUE in a transaction
  +               cache.remove(FQN);
   
  -               synchronized(lock)
  -               {
  -                  System.out.println(getName() + " waiting on lock");
  -                  lock.wait();
  -               }
  -               cache.getTransactionManager().commit();
  -            }
  -            catch (Exception e)
  -            {
  -               e.printStackTrace();
  -               fail();
  -            }
  -         }
  -      }
  -
  -      Thread[] t = new Thread[5];
  -      for (int i=0; i<t.length; i++)
  -      {
  -         t[i] = new ReaderThread();
  -         t[i].start();
  -      }
  +               // notify the reading thread
  +               readerCanRead.release();
   
  -      cache.put(fqn, "k", "v");
  -      // now all are ready to go...
  -//      latch.release();
  +               readerDone.acquire();
   
  -      synchronized(lock)
  -      {
  -         System.out.println(cache.printLockInfo());
  -         lock.notifyAll();
  +               tx.commit();
         }
  -
  -      System.out.println("2nd time...");
  -
  -      synchronized(lock)
  +            catch (AssertionFailedError e)
         {
  -         System.out.println(cache.printLockInfo());
  -         // check that we have multiple readers:         
  -         assertEquals(5, cache.get(Fqn.ROOT).getLock().getReaderOwners().size());
  -         assertEquals(5, cache.get(fqn).getLock().getReaderOwners().size());
  -         assertNull(cache.get(Fqn.ROOT).getLock().getWriterOwner());
  -         assertNull(cache.get(fqn).getLock().getWriterOwner());
  -
  -         lock.notifyAll();
  -      }
  -
  -
  -      for (int i=0; i<t.length; i++) t[i].join();
  -
  -
  -
  -      assertEquals(0, cache.get(Fqn.ROOT).getLock().getReaderOwners().size());
  -      assertEquals(0, cache.get(fqn).getLock().getReaderOwners().size());
  -      assertNull(cache.get(Fqn.ROOT).getLock().getWriterOwner());
  -      assertNull(cache.get(fqn).getLock().getWriterOwner());
  +               writerError = e;
      }
  -
  -
  -   public void testMultipleReadersOneWriter() throws Exception
  -   {
  -      final Fqn fqn = Fqn.fromString("/test");
  -//      final Latch latch = new Latch();
  -      final Object rLock = new Object();
  -      final Object wLock = new Object();
  -
  -      class ReaderThread extends Thread
  -      {
  -         public void run()
  +            catch(Throwable t)
            {
  -            try
  -            {
  -               cache.getTransactionManager().begin();
  -//               latch.acquire();
  -
  -               synchronized(rLock)
  -               {
  -                  System.out.println(getName() + " waiting on lock");
  -                  rLock.wait();
  +               t.printStackTrace();
  +               writerFailed = true;
                  }
  -
  -               assertNotNull(cache.get(fqn));
  -
  -               synchronized(rLock)
  -               {
  -                  System.out.println(getName() + " waiting on lock");
  -                  rLock.wait();
  -               }
  -               cache.getTransactionManager().commit();
  -            }
  -            catch (Exception e)
  +            finally
               {
  -               e.printStackTrace();
  -               fail();
  -            }
  +               System.out.println("writer thread exits");
  +               readerCanRead.release();
  +               writerDone.release();
            }
         }
  +      }, "WRITER");
  +      writerThread.start();
         
  -      class WriterThread extends Thread
  -      {
  -         public void run()
  -         {
               try
               {
  -               cache.getTransactionManager().begin();
  -//               latch.acquire();
  -
  -               synchronized(wLock)
  -               {
  -                  System.out.println(getName() + " waiting on lock");
  -                  wLock.wait();
  -               }
  -
  -               cache.put(fqn, "k2", "v2");
  -               fail("Should not be allowed to acquire the WL");
  +         // wait until the writer thread changes the value in a transaction,
  +         // but it did not yet commit or roll back.
  +         readerCanRead.acquire();
   
  -               synchronized(rLock)
  -               {
  -                  System.out.println(getName() + " waiting on lock");
  -                  rLock.wait();
  +         // I shouldn't be able to see the "dirty" value
  +         assertEquals("2nd thread cannot see uncommitted changes",
  +                       VALUE, cache.get(FQN, KEY));
                  }
  -               cache.getTransactionManager().commit();
  -            }
  -            catch (Exception e)
  +      catch (TimeoutException t)
               {
  -               //expected
  +         // ignore, this is good
               }
               finally
               {
  -               try
  -               {
  -                  cache.getTransactionManager().rollback();
  -               }
  -               catch (Exception e)
  -               {
  -               }
  -            }
  -         }
  +         System.out.println("reader thread exits");
  +         readerDone.release();
         }
   
  -      cache.put(fqn, "k", "v");
  +      // wait for the writer to finish
  +      writerDone.acquire();
   
  -      Thread[] t = new Thread[6];
  -      for (int i=0; i<t.length - 1; i++)
  -      {
  -         t[i] = new ReaderThread();
  -         t[i].start();
  -      }
  -
  -      t[t.length - 1] = new WriterThread();
  -      t[t.length - 1].start();
  -
  -
  -      // now all are ready to go...
  -//      latch.release();
  -
  -      synchronized(rLock) { rLock.notifyAll();}
  -      synchronized(wLock) { wLock.notifyAll();}
  +      assertNull("Node was removed", cache.get(FQN));
   
  -      System.out.println("2nd time...");
  +      // If any assertion failed, throw on the AssertionFailedError
   
  -      synchronized(rLock)
  +      if (writerError != null)
         {
  -         System.out.println(cache.printLockInfo());
  -         // check that we have multiple readers:
  -         assertEquals(6, cache.get(Fqn.ROOT).getLock().getReaderOwners().size());
  -         assertEquals(5, cache.get(fqn).getLock().getReaderOwners().size());
  -         assertNull(cache.get(Fqn.ROOT).getLock().getWriterOwner());
  -         assertNull(cache.get(fqn).getLock().getWriterOwner());
  -
  -         rLock.notifyAll();
  +         throw writerError;
         }
   
  -
  -      for (int i=0; i<t.length; i++) t[i].join();
  -
  -
  -      System.out.println("Locks: " + cache.printLockInfo());
  -
  -      assertEquals(0, cache.get(Fqn.ROOT).getLock().getReaderOwners().size());
  -      assertEquals(0, cache.get(fqn).getLock().getReaderOwners().size());
  -      assertNull(cache.get(Fqn.ROOT).getLock().getWriterOwner());
  -      assertNull(cache.get(fqn).getLock().getWriterOwner());
  +      if (writerFailed)
  +      {
  +         fail("The writer thread exited incorrectly. Watch the log for previous stack traces");
      }
   
  -
  -   /**
  -    * Test creates a cache node then starts a separate thread that removes
  -    * the node inside a tx. Test confirms that the removal cannot be seen
  -    * before the test commits.
  -    *
  -    * @throws Exception
  -    */
  -//   public void testNodeRemoved() throws Exception
  -//   {
  -//      final Latch readerCanRead = new Latch();
  -//      final Latch readerDone = new Latch();
  -//      final Latch writerDone = new Latch();
  -//
  -//      cache.put(FQN, KEY, VALUE);
  -//      assertEquals(VALUE, cache.get(FQN, KEY));
  -//
  -//      // start a writer thread and a transaction
  -//
  -//      Thread writerThread = new Thread(new Runnable()
  -//      {
  -//         public void run()
  -//         {
  -//            try
  -//            {
  -//               Transaction tx = startTransaction();
  -//
  -//               // change VALUE in a transaction
  -//               cache.remove(FQN);
  -//
  -//               // notify the reading thread
  -//               readerCanRead.release();
  -//
  -//               readerDone.acquire();
  -//
  -//               tx.commit();
  -//            }
  -//            catch (AssertionFailedError e)
  -//            {
  -//               writerError = e;
  -//            }
  -//            catch(Throwable t)
  -//            {
  -//               t.printStackTrace();
  -//               writerFailed = true;
  -//            }
  -//            finally
  -//            {
  -//               System.out.println("writer thread exits");
  -//               readerCanRead.release();
  -//               writerDone.release();
  -//            }
  -//         }
  -//      }, "WRITER");
  -//      writerThread.start();
  -//
  -//      try
  -//      {
  -//         // wait until the writer thread changes the value in a transaction,
  -//         // but it did not yet commit or roll back.
  -//         readerCanRead.acquire();
  -//
  -//         // I shouldn't be able to see the "dirty" value
  -//         assertEquals("2nd thread cannot see uncommitted changes",
  -//                       VALUE, cache.get(FQN, KEY));
  -//      }
  -//      catch (TimeoutException t)
  -//      {
  -//         // ignore, this is good
  -//      }
  -//      finally
  -//      {
  -//         System.out.println("reader thread exits");
  -//         readerDone.release();
  -//      }
  -//
  -//      // wait for the writer to finish
  -//      writerDone.acquire();
  -//
  -//      assertNull("Node was removed", cache.get(FQN));
  -//
  -//      // If any assertion failed, throw on the AssertionFailedError
  -//
  -//      if (writerError != null)
  -//      {
  -//         throw writerError;
  -//      }
  -//
  -//      if (writerFailed)
  -//      {
  -//         fail("The writer thread exited incorrectly. Watch the log for previous stack traces");
  -//      }
  -//
  -//   }
  +   }
   
      private Transaction startTransaction() throws SystemException, NotSupportedException
      {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 10:23:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 10:23:45 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58807 - trunk/build
Message-ID: <E1GqAEr-0004Aw-JI@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-01 10:23:44 -0500 (Fri, 01 Dec 2006)
New Revision: 58807

Modified:
   trunk/build/build-thirdparty.xml
Log:
- Switch to snapshot for jboss/web, with approval from Scott.

Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-01 13:25:10 UTC (rev 58806)
+++ trunk/build/build-thirdparty.xml	2006-12-01 15:23:44 UTC (rev 58807)
@@ -1,156 +1,156 @@
-<?xml version="1.0"?>
-<!-- $Id$ -->
-<project name="main.build"
-          default="synchronize"
-          basedir=".">
-
-   <!-- Property File definitions -->
-   <property file="local.properties"/>
-   <property file="synchronize.properties"/>
-   <property environment="env"/>
-
-   <!-- Property Definitions -->
-   <property name="generatedLibrariesFiles" value="../thirdparty/libraries.ent"/>
-
-   <!-- Allow jbossbuild.repository to be set from (in order or priority)
-      + Command line -Djbossbuild.repository=...
-      + synchronize.properties jbossbuild.repository setting
-      + JBOSS_REPOSITORY environment variable
-   -->
-   <condition property="jbossbuild.repository" value="${env.JBOSS_REPOSITORY}">
-      <isset property="env.JBOSS_REPOSITORY"/>
-   </condition>
-   <!-- Fall back to default -->
-   <property name="jbossbuild.repository" value="http://repository.jboss.com"/>
-
-   <!-- File Imports -->
-   <import file="../tools/etc/jbossbuild/tasks.xml"/>
-
-
-   <!-- Main Definition of dependencies -->
-   <build id="jbossas-thirdparty"
-          impltitle="JBossAS"
-          implversion="jboss-head"
-          implvendor="JBoss Inc."
-          implurl="http://www.jboss.org"
-          description="JBoss Application Server"
-          cvsroot="${cvs.prefix}@cvs.forge.jboss.com:/cvsroot/jboss"
-          thirdpartypath="../thirdparty/"
-          location="${jbossbuild.repository}"
-          targetdefs="targets">
-
-      <!--
-        The repository is in CVS under the module repository.jboss.com whose contents
-        are pushed to the http://repository.jboss.com site.
-      -->
-
-      <componentref name="antlr" version="2.7.6.ga"/>
-      <componentref name="apache-avalon" version="4.1.5"/>
-      <componentref name="apache-avalon-logkit" version="1.2"/>
-      <componentref name="apache-bcel" version="5.1"/>
-      <componentref name="apache-beanutils" version="1.7.0"/>
-      <componentref name="apache-bsf" version="2.3.0"/>
-      <componentref name="apache-codec" version="1.3.0"/>
-      <componentref name="apache-collections" version="3.1"/>
-      <componentref name="apache-digester" version="1.6"/>
-      <componentref name="apache-discovery" version="0.2"/>
-      <componentref name="apache-fileupload" version="1.0"/>
-      <componentref name="apache-httpclient" version="2.0.2"/>
-      <componentref name="apache-jaxme" version="0.2-cvs"/>
-      <componentref name="apache-log4j" version="1.2.8"/>
-      <componentref name="apache-logging" version="1.0.5.GA-jboss"/>
-      <componentref name="apache-myfaces" version="1.1.3"/>
-      <componentref name="apache-pool" version="1.0.1"/>
-      <componentref name="apache-scout" version="0.7rc2"/>
-      <componentref name="apache-slide" version="2.0"/>
-      <componentref name="apache-velocity" version="1.4jboss"/>
-      <componentref name="apache-xalan" version="j_2.7.0"/>
-      <componentref name="apache-xerces" version="2.7.1"/>
-      <componentref name="apache-xmlsec" version="1.3.0"/>
-      <componentref name="asm" version="1.5.3"/>
-      <componentref name="beanshell" version="1.3.0"/>
-      <componentref name="cglib" version="2.1.3.nodep"/>
-      <componentref name="codehaus-stax" version="1.1.1"/>
-      <componentref name="dom4j" version="1.6.1jboss"/>
-      <componentref name="easymock" version="1.1"/>
-      <componentref name="ehcache" version="1.2.0.GA"/>
-      <componentref name="gjt-jpl-util" version="1.0"/>
-      <componentref name="gnu-getopt" version="1.0.10"/>
-      <componentref name="hibernate" version="3.2.1.GA"/>
-      <componentref name="hibernate-annotations" version="3.2.0.GA"/>
-      <componentref name="hibernate-entitymanager" version="3.2.0.GA"/>
-      <componentref name="hsqldb" version="1.8.0.2"/>
-      <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
-      <componentref name="jacorb" version="2.2.4jboss.patch1"/>
-      <componentref name="javassist" version="3.4.GA"/>
-      <componentref name="jaxen" version="1.1-beta-9"/>
-      <componentref name="jboss/aop" version="2.0.0.alpha2"/>
-      <componentref name="jboss/aop14" version="2.0.0.alpha2"/>
-      <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
-      <componentref name="jboss/cache" version="2.0.0.ALPHA1"/>
-      <componentref name="jboss/common-core" version="2.0.2.GA"/>
-      <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
-      <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
-      <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
-      <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
-      <componentref name="jboss/jbossws" version="2.0.0.CR2"/>
-      <componentref name="jboss/messaging" version="1.0.1.GA"/>
-      <componentref name="jboss/microcontainer" version="2.0.0.Beta"/>
-      <componentref name="jboss/microcontainer14" version="2.0.0.Beta"/>
-      <componentref name="jboss/remoting" version="2.2.0.Alpha2"/>
-      <componentref name="jboss/jbossretro" version="1.0.4.GA"/>
-      <componentref name="jboss/jbossts" version="4.2.2.GA"/>
-      <componentref name="jboss/security-spi" version="2.0.0.Beta"/>
-      <componentref name="jboss/security" version="2.0.0.Beta"/>
-      <componentref name="jboss/serialization" version="1.0.3.GA"/>
-      <componentref name="jboss/profiler/jvmti" version="1.0.0.CR5"/>
-      <componentref name="jboss/test" version="1.0.0.GA"/>
-      <componentref name="jboss/web" version="2.0.0.Beta1"/>
-      <componentref name="jbpm" version="3.0.2"/>
-      <componentref name="jbpm-bpel" version="1.0.0.alpha4"/>
-      <componentref name="jfreechart" version="0.9.20"/>
-      <componentref name="jgroups" version="2.4"/>
-      <componentref name="joesnmp" version="0.3.4"/>
-      <componentref name="juddi" version="0.9RC4"/>
-      <componentref name="junit" version="3.8.1"/>
-      <componentref name="junitejb" version="1.4"/>
-      <componentref name="objectweb-joramtests" version="1.1"/>
-      <componentref name="odmg" version="3.0"/>
-      <componentref name="opensaml" version="1.1b"/>
-      <componentref name="oswego-concurrent" version="1.3.4"/>
-      <componentref name="quartz" version="1.5.2"/>
-      <componentref name="qdox" version="1.6"/>
-      <componentref name="sleepycat" version="3.0.12"/>
-      <componentref name="spring" version="2.0"/>
-      <componentref name="sun-jaf" version="1.1"/>
-      <componentref name="sun-jaxb" version="2.0.3"/>
-      <componentref name="sun-jsf" version="1.2.1_02"/>
-      <componentref name="sun-javacc" version="3.2"/>
-      <componentref name="sun-javamail" version="1.4"/>
-      <componentref name="sun-jstl" version="1.2"/>
-      <componentref name="sun-opends" version="0.1.0.build016"/>
-      <componentref name="sun-servlet" version="2.4"/>
-      <componentref name="sun-xacml" version="2.0"/>
-      <componentref name="trove" version="1.0.2"/>
-      <componentref name="wutka-dtdparser" version="1.2.1"/>
-      <componentref name="xdoclet" version="1.2b3"/>
-      <componentref name="xmlunit-xmlunit" version="1.0"/>
-
-
-   </build>
-
-   <synchronizeinfo/>
-
-   <!-- Generate the targets -->
-   <generate generate="jbossas-thirdparty"/>
-
-
-   <target name="generate-lib-file"
-      description="generate libraries.ent and thirdparty license info"
-      depends="synchronize">
-         <gen-lib-file filename="${generatedLibrariesFiles}" />
-      <visit-componentref-graph
-         componentVisitor="org.jboss.ant.util.graph.ComponentRefGraphLicenseVisitor" />
-   </target>
-
-</project>
+<?xml version="1.0"?>
+<!-- $Id$ -->
+<project name="main.build"
+          default="synchronize"
+          basedir=".">
+
+   <!-- Property File definitions -->
+   <property file="local.properties"/>
+   <property file="synchronize.properties"/>
+   <property environment="env"/>
+
+   <!-- Property Definitions -->
+   <property name="generatedLibrariesFiles" value="../thirdparty/libraries.ent"/>
+
+   <!-- Allow jbossbuild.repository to be set from (in order or priority)
+      + Command line -Djbossbuild.repository=...
+      + synchronize.properties jbossbuild.repository setting
+      + JBOSS_REPOSITORY environment variable
+   -->
+   <condition property="jbossbuild.repository" value="${env.JBOSS_REPOSITORY}">
+      <isset property="env.JBOSS_REPOSITORY"/>
+   </condition>
+   <!-- Fall back to default -->
+   <property name="jbossbuild.repository" value="http://repository.jboss.com"/>
+
+   <!-- File Imports -->
+   <import file="../tools/etc/jbossbuild/tasks.xml"/>
+
+
+   <!-- Main Definition of dependencies -->
+   <build id="jbossas-thirdparty"
+          impltitle="JBossAS"
+          implversion="jboss-head"
+          implvendor="JBoss Inc."
+          implurl="http://www.jboss.org"
+          description="JBoss Application Server"
+          cvsroot="${cvs.prefix}@cvs.forge.jboss.com:/cvsroot/jboss"
+          thirdpartypath="../thirdparty/"
+          location="${jbossbuild.repository}"
+          targetdefs="targets">
+
+      <!--
+        The repository is in CVS under the module repository.jboss.com whose contents
+        are pushed to the http://repository.jboss.com site.
+      -->
+
+      <componentref name="antlr" version="2.7.6.ga"/>
+      <componentref name="apache-avalon" version="4.1.5"/>
+      <componentref name="apache-avalon-logkit" version="1.2"/>
+      <componentref name="apache-bcel" version="5.1"/>
+      <componentref name="apache-beanutils" version="1.7.0"/>
+      <componentref name="apache-bsf" version="2.3.0"/>
+      <componentref name="apache-codec" version="1.3.0"/>
+      <componentref name="apache-collections" version="3.1"/>
+      <componentref name="apache-digester" version="1.6"/>
+      <componentref name="apache-discovery" version="0.2"/>
+      <componentref name="apache-fileupload" version="1.0"/>
+      <componentref name="apache-httpclient" version="2.0.2"/>
+      <componentref name="apache-jaxme" version="0.2-cvs"/>
+      <componentref name="apache-log4j" version="1.2.8"/>
+      <componentref name="apache-logging" version="1.0.5.GA-jboss"/>
+      <componentref name="apache-myfaces" version="1.1.3"/>
+      <componentref name="apache-pool" version="1.0.1"/>
+      <componentref name="apache-scout" version="0.7rc2"/>
+      <componentref name="apache-slide" version="2.0"/>
+      <componentref name="apache-velocity" version="1.4jboss"/>
+      <componentref name="apache-xalan" version="j_2.7.0"/>
+      <componentref name="apache-xerces" version="2.7.1"/>
+      <componentref name="apache-xmlsec" version="1.3.0"/>
+      <componentref name="asm" version="1.5.3"/>
+      <componentref name="beanshell" version="1.3.0"/>
+      <componentref name="cglib" version="2.1.3.nodep"/>
+      <componentref name="codehaus-stax" version="1.1.1"/>
+      <componentref name="dom4j" version="1.6.1jboss"/>
+      <componentref name="easymock" version="1.1"/>
+      <componentref name="ehcache" version="1.2.0.GA"/>
+      <componentref name="gjt-jpl-util" version="1.0"/>
+      <componentref name="gnu-getopt" version="1.0.10"/>
+      <componentref name="hibernate" version="3.2.1.GA"/>
+      <componentref name="hibernate-annotations" version="3.2.0.GA"/>
+      <componentref name="hibernate-entitymanager" version="3.2.0.GA"/>
+      <componentref name="hsqldb" version="1.8.0.2"/>
+      <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
+      <componentref name="jacorb" version="2.2.4jboss.patch1"/>
+      <componentref name="javassist" version="3.4.GA"/>
+      <componentref name="jaxen" version="1.1-beta-9"/>
+      <componentref name="jboss/aop" version="2.0.0.alpha2"/>
+      <componentref name="jboss/aop14" version="2.0.0.alpha2"/>
+      <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
+      <componentref name="jboss/cache" version="2.0.0.ALPHA1"/>
+      <componentref name="jboss/common-core" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
+      <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
+      <componentref name="jboss/jbossws" version="2.0.0.CR2"/>
+      <componentref name="jboss/messaging" version="1.0.1.GA"/>
+      <componentref name="jboss/microcontainer" version="2.0.0.Beta"/>
+      <componentref name="jboss/microcontainer14" version="2.0.0.Beta"/>
+      <componentref name="jboss/remoting" version="2.2.0.Alpha2"/>
+      <componentref name="jboss/jbossretro" version="1.0.4.GA"/>
+      <componentref name="jboss/jbossts" version="4.2.2.GA"/>
+      <componentref name="jboss/security-spi" version="2.0.0.Beta"/>
+      <componentref name="jboss/security" version="2.0.0.Beta"/>
+      <componentref name="jboss/serialization" version="1.0.3.GA"/>
+      <componentref name="jboss/profiler/jvmti" version="1.0.0.CR5"/>
+      <componentref name="jboss/test" version="1.0.0.GA"/>
+      <componentref name="jboss/web" version="2.0.0.snapshot"/>
+      <componentref name="jbpm" version="3.0.2"/>
+      <componentref name="jbpm-bpel" version="1.0.0.alpha4"/>
+      <componentref name="jfreechart" version="0.9.20"/>
+      <componentref name="jgroups" version="2.4"/>
+      <componentref name="joesnmp" version="0.3.4"/>
+      <componentref name="juddi" version="0.9RC4"/>
+      <componentref name="junit" version="3.8.1"/>
+      <componentref name="junitejb" version="1.4"/>
+      <componentref name="objectweb-joramtests" version="1.1"/>
+      <componentref name="odmg" version="3.0"/>
+      <componentref name="opensaml" version="1.1b"/>
+      <componentref name="oswego-concurrent" version="1.3.4"/>
+      <componentref name="quartz" version="1.5.2"/>
+      <componentref name="qdox" version="1.6"/>
+      <componentref name="sleepycat" version="3.0.12"/>
+      <componentref name="spring" version="2.0"/>
+      <componentref name="sun-jaf" version="1.1"/>
+      <componentref name="sun-jaxb" version="2.0.3"/>
+      <componentref name="sun-jsf" version="1.2.1_02"/>
+      <componentref name="sun-javacc" version="3.2"/>
+      <componentref name="sun-javamail" version="1.4"/>
+      <componentref name="sun-jstl" version="1.2"/>
+      <componentref name="sun-opends" version="0.1.0.build016"/>
+      <componentref name="sun-servlet" version="2.4"/>
+      <componentref name="sun-xacml" version="2.0"/>
+      <componentref name="trove" version="1.0.2"/>
+      <componentref name="wutka-dtdparser" version="1.2.1"/>
+      <componentref name="xdoclet" version="1.2b3"/>
+      <componentref name="xmlunit-xmlunit" version="1.0"/>
+
+
+   </build>
+
+   <synchronizeinfo/>
+
+   <!-- Generate the targets -->
+   <generate generate="jbossas-thirdparty"/>
+
+
+   <target name="generate-lib-file"
+      description="generate libraries.ent and thirdparty license info"
+      depends="synchronize">
+         <gen-lib-file filename="${generatedLibrariesFiles}" />
+      <visit-componentref-graph
+         componentVisitor="org.jboss.ant.util.graph.ComponentRefGraphLicenseVisitor" />
+   </target>
+
+</project>



From galder.zamarreno at jboss.com  Fri Dec  1 10:29:54 2006
From: galder.zamarreno at jboss.com (Galder Zamarreno)
Date: Fri, 01 Dec 2006 10:29:54 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1GqAKo-0004H8-Om@committer01.frg.pub.inap.atl.jboss.com>

  User: gzamarreno
  Date: 06/12/01 10:29:54

  Added:       tests/functional/org/jboss/cache/marshall 
                        RedeploymentEmulationTest.java
  Log:
  How to use JBC marshalling to get around redeployment ClassCastExceptions. QA entry added explaining the problem and resolution as well as a unit test emulating redeployment.
  
  Revision  Changes    Path
  1.2       +114 -0    JBossCache/tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RedeploymentEmulationTest.java
  ===================================================================
  RCS file: RedeploymentEmulationTest.java
  diff -N RedeploymentEmulationTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ RedeploymentEmulationTest.java	1 Dec 2006 15:29:54 -0000	1.2
  @@ -0,0 +1,114 @@
  +/*
  + * JBoss, the OpenSource J2EE webOS
  + * 
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.cache.marshall;
  +
  +import junit.framework.TestCase;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Cache;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.Region;
  +import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.config.Configuration;
  +import org.jgroups.Global;
  +
  +import java.net.URLClassLoader;
  +import java.net.URL;
  +import java.io.File;
  +
  +/**
  + * Unit test demonstrating usability of marshalling for application redeployment in application server.
  + *
  + * @author <a href="mailto:galder.zamarreno at jboss.com">Galder Zamarreno</a>
  + */
  +public class RedeploymentEmulationTest extends TestCase
  +{
  +   private Cache cache;
  +
  +   private static final String INSTANCE_LIBRARY = "jgroups.jar";
  +   private static final String INSTANCE_CLASS_NAME = "org.jgroups.Global";
  +   private static final String USER_DIR = System.getProperty("user.dir");
  +   private static final String FILE_SEPARATOR = System.getProperty("file.separator");
  +   private static final String LIB_DIR = "lib";
  +
  +   protected void setUp() throws Exception
  +   {
  +      TreeCache tc = new TreeCache();
  +
  +      cache = tc.getCacheSPI();
  +      
  +      cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
  +      cache.getConfiguration().setUseRegionBasedMarshalling(true);
  +   }
  +
  +   public void testClassCastException() throws Exception
  +   {
  +      cache.start();
  +
  +      File f = new File(USER_DIR + FILE_SEPARATOR + LIB_DIR + FILE_SEPARATOR);
  +      URL context = f.toURL();
  +      URL jar= new URL(context, INSTANCE_LIBRARY);
  +      URLClassLoader ucl1 = new URLClassLoader(new URL[]{jar}, null);
  +      Thread.currentThread().setContextClassLoader(ucl1);
  +      
  +      Class clazz1 = ucl1.loadClass(INSTANCE_CLASS_NAME);
  +      cache.put(fqn("/a"), "key", clazz1.newInstance());
  +
  +      Thread.currentThread().setContextClassLoader(ClassLoader.getSystemClassLoader());
  +      try
  +      {
  +         Global object = (Global)cache.get(fqn("/a"), "key");
  +         fail("Should have produced a ClassCastException");
  +      }
  +      catch(ClassCastException cce)
  +      {
  +         assertTrue(cce.getMessage().equals(INSTANCE_CLASS_NAME));
  +      }
  +   }
  +
  +   public void testRegisterUnregister() throws Exception
  +   {
  +      cache.start();
  +
  +      File f = new File(USER_DIR + FILE_SEPARATOR + LIB_DIR + FILE_SEPARATOR);
  +      URL context = f.toURL();
  +      URL jar= new URL(context, INSTANCE_LIBRARY);
  +      URLClassLoader ucl1 = new URLClassLoader(new URL[]{jar}, null);
  +      Thread.currentThread().setContextClassLoader(ucl1);
  +
  +      Region region = cache.getRegion(fqn("/"), true);
  +      region.registerContextClassLoader(Thread.currentThread().getContextClassLoader());
  +      region.activate();
  +
  +      Class clazz1 = ucl1.loadClass(INSTANCE_CLASS_NAME);
  +      cache.put(fqn("/a"), "key", clazz1.newInstance());
  +
  +      region.deactivate();
  +      region.unregisterContextClassLoader();
  +
  +      Thread.currentThread().setContextClassLoader(ClassLoader.getSystemClassLoader());
  +
  +      region.registerContextClassLoader(Thread.currentThread().getContextClassLoader());
  +      
  +      try
  +      {
  +         Global object = (Global)cache.get(fqn("/a"), "key");
  +         assertNull(object);
  +      }
  +      catch(ClassCastException cce)
  +      {
  +         fail("Should not have produced a ClassCastException");
  +      }
  +
  +      region.deactivate();
  +      region.unregisterContextClassLoader();
  +   }
  +
  +   private static Fqn fqn(String fqn)
  +   {
  +      return Fqn.fromString(fqn);
  +   }   
  +}
  
  
  


From galder.zamarreno at jboss.com  Fri Dec  1 10:29:54 2006
From: galder.zamarreno at jboss.com (Galder Zamarreno)
Date: Fri, 01 Dec 2006 10:29:54 -0500
Subject: [jboss-cvs] JBossCache/docs/faq/en  ...
Message-ID: <E1GqAKo-0004HF-Vc@committer01.frg.pub.inap.atl.jboss.com>

  User: gzamarreno
  Date: 06/12/01 10:29:54

  Modified:    docs/faq/en  master.xml
  Log:
  How to use JBC marshalling to get around redeployment ClassCastExceptions. QA entry added explaining the problem and resolution as well as a unit test emulating redeployment.
  
  Revision  Changes    Path
  1.43      +49 -0     JBossCache/docs/faq/en/master.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: master.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/docs/faq/en/master.xml,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- master.xml	1 Nov 2006 02:05:07 -0000	1.42
  +++ master.xml	1 Dec 2006 15:29:54 -0000	1.43
  @@ -32,6 +32,12 @@
            <email>smarlow at novell.com</email>
         </author>
   
  +      <author>
  +         <firstname>Galder</firstname>
  +         <surname>Zamarre??o</surname>
  +         <email>galder.zamarreno at jboss.com</email>
  +      </author>      
  +
         <abstract>
            <para>This is a compilation of the most frequently asked
               questions about JBoss Cache. Please report any bugs,
  @@ -1109,6 +1115,49 @@
                  </programlisting>
               </answer>
            </qandaentry>
  +
  +         <qandaentry>
  +            <question>
  +               <para>Can I use <literal>useRegionBasedMarshalling</literal> attribute in JBoss Cache in order to get
  +                  around ClassCastExceptions happening when accessing data in the cache that has just been redeployed?
  +               </para>
  +            </question>
  +
  +            <answer>
  +               <para>Yes, you can. Originally, <literal>TreeCache</literal> Marshalling was designed as a
  +                  workaround for those replicated caches that upon state transfer did not have access to the
  +                  classloaders defining the objects in the cache.
  +               </para>
  +
  +               <para>On each deployment, JBoss creates a new classloader per the top level deployment artifact, for
  +                  example an EAR. You also have to bear in mind that a class in an application server is defined not
  +                  only by the class name but also its classloader. So, assuming that the cache is not deployed as part
  +                  of your deployment, you could deploy an application and put instances of classes belonging to this
  +                  deployment inside the cache. If you did a redeployment and try to do a get operation of the data
  +                  previously put, this would result on a ClassCastException. This is because even though the class names
  +                  are the same, the class definitions are not. The current classloader is different to the one when
  +                  the classes were originally put.
  +               </para>
  +
  +               <para>By enabling marshalling, you can control the lifecycle of the data in the cache and if on
  +                  undeployment, you deactivate the region and unregister the classloader that you'd have registered on
  +                  deployment, you'd evict the data in the cache locally. That means that in the next deployment, the
  +                  data won't be in the cache, therefore avoiding the problem. Obviously, using marshalling to get
  +                  around this problem is only recommended when you have some kind of persistence backing where the data
  +                  survives, for example using CacheLoaders, or when JBossCache is used as a second level cache in a
  +                  persistence framework.
  +               </para>
  +
  +               <para>To implement this feature, please follow the instructions indicated in the example located
  +                  in the TreeCacheMarshaller section of the user's guide. It's worth noting that instead of a
  +                  <literal>ServletContextListener</literal>, you could add this code into an <literal>MBean</literal>
  +                  that contained lifecycle methods, such as <literal>start()</literal> and <literal>stop()</literal>.
  +                  The key would be for this MBean to depend on the target cache, so that it can operate as long as the
  +                  cache is up and running.
  +               </para>
  +            </answer>
  +         </qandaentry>
  +         
         </qandaset>
      </chapter>
   
  
  
  


From msurtani at jboss.com  Fri Dec  1 10:44:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 01 Dec 2006 10:44:20 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GqAYm-0004Wm-9k@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/01 10:44:20

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_3_0
                        PessimisticLockInterceptor.java
  Log:
  delete nodes marked for removal *before* releasing locks on them!!
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.14.2.8  +9 -7      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.14.2.7
  retrieving revision 1.14.2.8
  diff -u -b -r1.14.2.7 -r1.14.2.8
  --- PessimisticLockInterceptor.java	30 Nov 2006 14:18:04 -0000	1.14.2.7
  +++ PessimisticLockInterceptor.java	1 Dec 2006 15:44:20 -0000	1.14.2.8
  @@ -34,7 +34,7 @@
    * scope of the TX. When no TX is present, we keep track of the locks acquired during the current method and unlock
    * when the method returns
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.7 2006/11/30 14:18:04 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.8 2006/12/01 15:44:20 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor {
      TransactionTable           tx_table=null;
  @@ -341,6 +341,14 @@
            return;
         }
   
  +      // first remove nodes that should be deleted.
  +      Iterator removedNodes = entry.getRemovedNodes().iterator();
  +      while (removedNodes.hasNext())
  +      {
  +         Fqn f = (Fqn) removedNodes.next();
  +         cache.realRemove(f, false);
  +      }      
  +
         // Let's do it in stack style, LIFO
         List list=new LinkedList(entry.getLocks());
         for(int i=list.size() - 1; i >= 0; i--) {
  @@ -357,12 +365,6 @@
         tx_table.remove(ltx);
         tx_table.remove(gtx);
   
  -      Iterator removedNodes = entry.getRemovedNodes().iterator();
  -      while (removedNodes.hasNext())
  -      {
  -         Fqn f = (Fqn) removedNodes.next();
  -         cache.realRemove(f, false);
  -      }
      }
   
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 11:40:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 11:40:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r58808 -
	branches/JBoss_3_2_7_CP/testsuite/imports
Message-ID: <E1GqBRZ-0005cO-91@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-01 11:40:56 -0500 (Fri, 01 Dec 2006)
New Revision: 58808

Modified:
   branches/JBoss_3_2_7_CP/testsuite/imports/test-jars.xml
Log:
remove duplicated _jars-util target

Modified: branches/JBoss_3_2_7_CP/testsuite/imports/test-jars.xml
===================================================================
--- branches/JBoss_3_2_7_CP/testsuite/imports/test-jars.xml	2006-12-01 15:23:44 UTC (rev 58807)
+++ branches/JBoss_3_2_7_CP/testsuite/imports/test-jars.xml	2006-12-01 16:40:56 UTC (rev 58808)
@@ -4070,35 +4070,6 @@
       </zip>
    </target>
 
-   <!-- Utility services tests -->
-   <target name="_jars-util">
-      <!-- The external scheduler.jar -->
-      <jar destfile="${build.lib}/scheduler.jar">
-         <fileset dir="${build.classes}">
-            <include name="org/jboss/test/util/scheduler/*"/>
-         </fileset>
-      </jar>
-      <!-- The scheduler.sar -->
-      <jar destfile="${build.lib}/scheduler.sar">
-         <manifest>
-            <attribute name="Class-Path" value="../../scheduler.jar"/>
-         </manifest>
-         <metainf dir="${build.resources}/util/scheduler">
-            <include name="jboss-service.xml"/>
-         </metainf>
-      </jar>
-      <!-- The scheduler.ear -->
-      <ear destfile="${build.lib}/scheduler.ear"
-         appxml="${build.resources}/util/scheduler/application.xml">
-         <metainf dir="${build.resources}/util/scheduler">
-            <include name="jboss-app.xml"/>
-         </metainf>
-         <fileset dir="${build.lib}">
-            <include name="scheduler.sar"/>
-         </fileset>
-      </ear>
-   </target>
-
    <!-- xa test -->
    <target name="_jars-xa">
       <mkdir dir="${build.lib}"/>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 11:59:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 11:59:29 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58809 - trunk/build
Message-ID: <E1GqBjV-0005rO-QD@committer01.frg.pub.inap.atl.jboss.com>

Author: alex.loubyansky at jboss.com
Date: 2006-12-01 11:59:27 -0500 (Fri, 01 Dec 2006)
New Revision: 58809

Modified:
   trunk/build/build-thirdparty.xml
Log:
switched to snapshot for the jbossxb (needed for the cts work)

Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-01 16:40:56 UTC (rev 58808)
+++ trunk/build/build-thirdparty.xml	2006-12-01 16:59:27 UTC (rev 58809)
@@ -92,7 +92,7 @@
       <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
-      <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
+      <componentref name="jboss/jbossxb" version="snapshot"/>
       <componentref name="jboss/jbossws" version="2.0.0.CR2"/>
       <componentref name="jboss/messaging" version="1.0.1.GA"/>
       <componentref name="jboss/microcontainer" version="2.0.0.Beta"/>



From msurtani at jboss.com  Fri Dec  1 12:00:11 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 01 Dec 2006 12:00:11 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache  ...
Message-ID: <E1GqBkB-0005sn-6R@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/01 12:00:11

  Modified:    tests/stress/org/jboss/cache  Tag: Branch_JBossCache_1_3_0
                        LocalStressTest.java
  Log:
  removed classic deadlock scenario
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.2.2   +11 -4     JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java,v
  retrieving revision 1.2.2.1
  retrieving revision 1.2.2.2
  diff -u -b -r1.2.2.1 -r1.2.2.2
  --- LocalStressTest.java	30 Nov 2006 16:23:13 -0000	1.2.2.1
  +++ LocalStressTest.java	1 Dec 2006 17:00:11 -0000	1.2.2.2
  @@ -14,6 +14,8 @@
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.LockStrategyFactory;
   import org.jboss.cache.transaction.DummyTransactionManager;
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   
   import javax.naming.Context;
   import javax.naming.InitialContext;
  @@ -33,7 +35,7 @@
   /**
    * Local mode stress test for TreeCache.
    *
  - * @version $Revision: 1.2.2.1 $
  + * @version $Revision: 1.2.2.2 $
    * @author<a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
    */
   public class LocalStressTest extends TestCase
  @@ -164,6 +166,7 @@
         final int seed_;
         Random random_;
         UserTransaction tx_ = null;
  +      private Log log = LogFactory.getLog(LocalStressTest.class);
   
         public RunThread(UserTransaction tx, int seed)
         {
  @@ -207,9 +210,12 @@
            String node = (String) nodeList_.get(i);
            cache_.get(node, key);
            sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  -         cache_.put(node, key, value);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  -         cache_.remove(node, key);
  +
  +         // uncommenting these leads to a classic deadlock.
  +
  +//         cache_.put(node, key, value);
  +//         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +//         cache_.remove(node, key);
            tx_.commit();
         }
   
  @@ -239,6 +245,7 @@
            String node = (String) nodeList_.get(i);
            cache_.put(node, key, value);
            sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +         log.fatal("Sleeping");
            cache_.remove(node, key);
            tx_.commit();
         }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 14:20:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 14:20:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r58810 - in branches/JBoss_3_2_7_CP:
	console/src/main/org/jboss/console/manager
	testsuite/src/main/org/jboss/test
	testsuite/src/main/org/jboss/test/console
	testsuite/src/main/org/jboss/test/console/jbas3861
Message-ID: <E1GqDwJ-0000Hy-O0@committer01.frg.pub.inap.atl.jboss.com>

Author: vivekl at redhat.com
Date: 2006-12-01 14:20:44 -0500 (Fri, 01 Dec 2006)
New Revision: 58810

Added:
   branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console/
   branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console/jbas3861/
   branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java
Removed:
   branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console/jbas3861/
Modified:
   branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepository.java
   branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepositoryMBean.java
Log:
ASPATCH-128: JBAS-3861: DeploymentFileRepository can be used to write/remove arbitrary files in the filesystem
Merged the fixes from Branch_4_2.



Modified: branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepository.java
===================================================================
--- branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepository.java	2006-12-01 16:59:27 UTC (rev 58809)
+++ branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepository.java	2006-12-01 19:20:44 UTC (rev 58810)
@@ -6,18 +6,18 @@
  */
 package org.jboss.console.manager;
 
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.PrintWriter;
+
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+
 import org.jboss.system.ServiceMBeanSupport;
 import org.jboss.system.server.ServerConfig;
 import org.jboss.system.server.ServerConfigLocator;
 
-import javax.management.ObjectName;
-import javax.management.MBeanServer;
-import java.io.File;
-import java.io.FileOutputStream;
-import java.io.PrintWriter;
-import java.io.IOException;
-import java.net.URL;
-
 /**
  * This class wraps the file system
  * for deployments.  It gives a file-based
@@ -29,16 +29,17 @@
  * corresponds to the base file name.
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
  * @version $Revision$
- *
- **/
-public class DeploymentFileRepository extends ServiceMBeanSupport implements DeploymentFileRepositoryMBean
+ */
+public class DeploymentFileRepository extends ServiceMBeanSupport
+   implements DeploymentFileRepositoryMBean
 {
    private String baseDir;
    private File base;
+   
    /** The server's home directory, for relative paths. */
    protected File serverHome;
-   protected URL serverHomeURL;
 
    /**
     *
@@ -52,9 +53,9 @@
    public void store(String folder, String name, String fileExtension, String data, boolean noHotDeploy) throws IOException
    {
       System.out.println("store called");
-      File dir = new File(base, folder);
-      System.out.println("respository folder: " + dir.toString());
-      System.out.println("absolute: " + dir.getAbsolutePath());
+      File dir = getFile(base, folder);
+      log.debug("repository folder: " + dir.toString());
+      log.debug("absolute: " + dir.getAbsolutePath());
       if (!dir.exists())
       {
          if (!dir.mkdirs())
@@ -63,11 +64,13 @@
          }
       }
       String filename = name.replace(' ', '_') + fileExtension;
-      File file = new File(dir, filename);
+      File file = getFile(dir, filename);
+      
       File tmpfile = new File(dir, filename + ".tmp");
       PrintWriter writer = new PrintWriter(new FileOutputStream(tmpfile));
       writer.write(data);
       writer.close();
+      
       if (file.exists() && noHotDeploy)
       {
          long modified = file.lastModified();
@@ -80,19 +83,19 @@
       }
    }
 
-   public void remove(String folder, String name, String fileExtension)
+   public void remove(String folder, String name, String fileExtension) throws IOException
    {
-      File dir = new File(base, folder);
+      File dir = getFile(base, folder);
       String filename = name.replace(' ', '_') + fileExtension;
-      File file = new File(dir, filename);
+      File file = getFile(dir, filename);
       file.delete();
    }
 
-   public boolean isStored(String folder, String name, String fileExtension)
+   public boolean isStored(String folder, String name, String fileExtension) throws IOException
    {
-      File dir = new File(base, folder);
+      File dir = getFile(base, folder);
       String filename = name.replace(' ', '_') + fileExtension;
-      File file = new File(dir, filename);
+      File file = getFile(dir, filename);
       return file.exists();
    }
 
@@ -101,15 +104,15 @@
       return baseDir;
    }
 
-   public void setBaseDir(String baseDir)
+   public void setBaseDir(String baseDir) throws IOException
    {
+      this.base = getFile(serverHome, baseDir);      
       this.baseDir = baseDir;
-      this.base = new File(serverHome, baseDir);
+      
+      log.debug("BaseDir set to: " + this.base);
    }
 
-
-   public ObjectName preRegister(MBeanServer server, ObjectName name)
-      throws Exception
+   public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
    {
       // get server's home for relative paths, need this for setting
       // attribute final values, so we need to do it here
@@ -118,4 +121,20 @@
       return super.preRegister(server, name);
    }
 
+   /**
+    * Wrap the File(File parent, String child) CTOR to make sure the
+    * resulting child is indeed under the parent hierarchy,
+    * i.e. don't allow a ../../../rogue-child.txt
+    * 
+    * see JBAS-3861
+    */
+   private File getFile(File parent, String child) throws IOException
+   {
+      File childFile = new File(parent, child);
+      
+      if (childFile.getCanonicalPath().indexOf(parent.getCanonicalPath()) != 0)
+         throw new IllegalArgumentException("child '" + child + "' should be a child of parent '" + parent + "'");
+      
+      return childFile;
+   }
 }

Modified: branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepositoryMBean.java
===================================================================
--- branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepositoryMBean.java	2006-12-01 16:59:27 UTC (rev 58809)
+++ branches/JBoss_3_2_7_CP/console/src/main/org/jboss/console/manager/DeploymentFileRepositoryMBean.java	2006-12-01 19:20:44 UTC (rev 58810)
@@ -6,26 +6,31 @@
  */
 package org.jboss.console.manager;
 
+import java.io.IOException;
+
 import org.jboss.system.ServiceMBean;
 
-import java.io.IOException;
-
 /**
- * Comment
+ * MBean interface
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
  * @version $Revision$
- *
- **/
+ */
 public interface DeploymentFileRepositoryMBean extends ServiceMBean
 {
+   // Attributes ----------------------------------------------------
+
+   /** The base directory to use for storing/removing files */
+   void setBaseDir(String baseDir) throws IOException;
+   String getBaseDir();
+   
+   // Operations ----------------------------------------------------
+   
    void store(String folder, String name, String fileExtension, String data, boolean noHotDeploy) throws IOException;
 
-   void remove(String folder, String name, String fileExtension);
+   void remove(String folder, String name, String fileExtension) throws IOException;
 
-   boolean isStored(String folder, String name, String fileExtension);
+   boolean isStored(String folder, String name, String fileExtension) throws IOException;
 
-   String getBaseDir();
-
-   void setBaseDir(String baseDir);
 }

Copied: branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console (from rev 58725, branches/Branch_4_2/testsuite/src/main/org/jboss/test/console)

Copied: branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console/jbas3861 (from rev 58725, branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861)

Copied: branches/JBoss_3_2_7_CP/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java (from rev 58797, branches/Branch_4_2/testsuite/src/main/org/jboss/test/console/jbas3861/JBAS3861UnitTestCase.java)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 14:37:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 14:37:17 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1672 - in
	branches/Branch_1_0_1_SP: src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GqECD-0000db-3Z@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-01 14:37:10 -0500 (Fri, 01 Dec 2006)
New Revision: 1672

Modified:
   branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
   branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
Log:
More for patch



Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-01 09:47:27 UTC (rev 1671)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-01 19:37:10 UTC (rev 1672)
@@ -76,7 +76,7 @@
 
    private static final Logger log = Logger.getLogger(ServerConsumerEndpoint.class);
 
-   // Static --------------------------------------------------------
+   // Static --------------------------------------------------------  
 
    // Attributes ----------------------------------------------------
 
@@ -118,9 +118,9 @@
    private Object lock;
 
    private Map deliveries;
-
+   
    private CoreDestination dlq;
-
+   
    // Constructors --------------------------------------------------
 
    protected ServerConsumerEndpoint(int id, Channel channel,
@@ -148,7 +148,7 @@
          sessionEndpoint.getConnectionEndpoint().getServerPeer().getQueuedExecutorPool();
 
       this.executor = (QueuedExecutor)pool.get("consumer" + id);
-
+             
       // Note that using a PooledExecutor with a linked queue is not sufficient to ensure that
       // deliveries for the same consumer happen serially, since even if they are queued serially
       // the actual deliveries can happen in parallel, resulting in a later one "overtaking" an
@@ -162,9 +162,9 @@
 
       this.noLocal = noLocal;
       this.destination = dest;
-
+      
       this.toDeliver = new ArrayList();
-
+      
       this.lock = new Object();
 
       if (selector != null)
@@ -174,7 +174,7 @@
          if (trace) log.trace("created selector");
       }
 
-      //FIXME -
+      //FIXME - 
       //We really need to get rid of this delivery list - it's only purpose in life is to solve
       //the race condition where acks or cancels can come in before handle has returned - and
       //that can be solved in a simpler way anyway.
@@ -183,15 +183,15 @@
       //and when we do clustering we will have to replicate it too!!
       //Let's GET RID OF IT!!!!!!!!!!!
       this.deliveries = new LinkedHashMap();
-
+            
       this.started = this.sessionEndpoint.getConnectionEndpoint().isStarted();
 
       // adding the consumer to the channel
       this.channel.add(this);
-
+      
       // prompt delivery
       channel.deliver(false);
-
+      
       log.debug(this + " constructed");
    }
 
@@ -203,21 +203,21 @@
    public Delivery handle(DeliveryObserver observer, Routable reference, Transaction tx)
    {
       if (trace) { log.trace(this + " receives " + reference + " for delivery"); }
-
+      
       // This is ok to have outside lock - is volatile
       if (bufferFull)
       {
          // We buffer a maximum of PREFETCH_LIMIT messages at once
-
+         
          if (trace) { log.trace(this + " has reached prefetch size will not accept any more references"); }
-
+         
          return null;
       }
-
+       
       // Need to synchronized around the whole block to prevent setting started = false
       // but handle is already running and a message is deposited during the stop procedure.
       synchronized (lock)
-      {
+      {  
          // If the consumer is stopped then we don't accept the message, it should go back into the
          // channel for delivery later.
          if (!started)
@@ -237,40 +237,40 @@
          if (trace) { log.trace(this + " has the main lock, preparing the message for delivery"); }
 
          MessageReference ref = (MessageReference)reference;
-
+                     
          JBossMessage message = (JBossMessage)ref.getMessage();
-
+         
          boolean selectorRejected = !this.accept(message);
-
+   
          SimpleDelivery delivery = new SimpleDelivery(observer, ref, false, !selectorRejected);
-
+         
          if (selectorRejected)
          {
             return delivery;
          }
-
+                 
          if (delivery.isDone())
          {
             return delivery;
          }
-
-         deliveries.put(new Long(ref.getMessageID()), delivery);
-
+   
+         deliveries.put(new Long(ref.getMessageID()), delivery);                 
+   
          // We don't send the message as-is, instead we create a MessageProxy instance. This allows
          // local fields such as deliveryCount to be handled by the proxy but global data to be
          // fielded by the same underlying Message instance. This allows us to avoid expensive
          // copying of messages
-
+   
          MessageProxy mp = JBossMessage.createThinDelegate(message, ref.getDeliveryCount());
-
+    
          // Add the proxy to the list to deliver
-
-         toDeliver.add(mp);
-
+                           
+         toDeliver.add(mp);     
+          
          bufferFull = toDeliver.size() >= prefetchSize;
-
+             
          if (!clientConsumerFull)
-         {
+         {            
             try
             {
                if (trace) { log.trace(this + " scheduling a new Deliverer"); }
@@ -281,12 +281,12 @@
                log.warn("Thread interrupted", e);
             }
          }
-
-         return delivery;
+                             
+         return delivery;              
       }
-   }
+   }      
+   
 
-
    // Filter implementation -----------------------------------------
 
    public boolean accept(Routable r)
@@ -299,7 +299,7 @@
          if (messageSelector != null)
          {
             accept = messageSelector.accept(r);
-
+   
             if (trace) { log.trace("message selector " + (accept ? "accepts " :  "DOES NOT accept ") + "the message"); }
          }
       }
@@ -328,21 +328,21 @@
       try
       {
          if (trace) { log.trace(this + " closing"); }
-
-         stop();
+         
+         stop(); 
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " closing");
-      }
+      }     
    }
-
+   
    public void close() throws JMSException
-   {
+   {      
       try
       {
          synchronized (lock)
-         {
+         { 
             // On close we only disconnect the consumer from the Channel we don't actually remove
             // it. This is because it may still contain deliveries that may well be acknowledged
             // after the consumer has closed. This is perfectly valid.
@@ -352,11 +352,11 @@
             // keeping deliveries after this is closed.
 
             if (trace) { log.trace(this + " grabbed the main lock in close()"); }
-
-            disconnect();
-
+                  
+            disconnect(); 
+            
             JMSDispatcher.instance.unregisterTarget(new Integer(id));
-
+            
             // If it's a subscription, remove it
             if (channel instanceof Subscription)
             {
@@ -364,10 +364,10 @@
                if (!sub.isRecoverable())
                {
                   //We don't disconnect durable subs
-                  sub.disconnect();
-               }
-            }
-
+                  sub.disconnect();                  
+               }            
+            } 
+            
             // If it's non recoverable, i.e. it's a non durable sub or a temporary queue then remove
             // all its references
 
@@ -375,7 +375,7 @@
             {
                channel.removeAllReferences();
             }
-
+            
             closed = true;
          }
       }
@@ -389,15 +389,15 @@
    {
       return closed;
    }
-
+               
    // ConsumerEndpoint implementation -------------------------------
-
+   
    /*
     * This is called by the client consumer to tell the server to wake up and start sending more
     * messages if available
     */
    public void more() throws JMSException
-   {
+   {           
       try
       {
          /*
@@ -412,90 +412,83 @@
          5) The next deliverer runs but doesn't do anything since clientConsumerFull = true even
          though the client needs messages
          */
-         this.executor.execute(new Runnable() { public void run() { clientConsumerFull = false; } });
-
+         this.executor.execute(new Runnable() { public void run() { clientConsumerFull = false; } });         
+                           
          //Run a deliverer to deliver any existing ones
          this.executor.execute(new Deliverer());
-
+         
          //TODO Why do we need to wait for it to execute??
          //Why not just return immediately?
-
+         
          //Now wait for it to execute
          Future result = new Future();
-
+         
          this.executor.execute(new Waiter(result));
-
+         
          result.getResult();
-
+                  
          //Now we know the deliverer has delivered any outstanding messages to the client buffer
-
+         
          channel.deliver(false);
       }
       catch (InterruptedException e)
       {
          log.warn("Thread interrupted", e);
-      }
+      }       
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " more");
       }
    }
-
-
+   
+   
    // Public --------------------------------------------------------
-
+   
    public String toString()
    {
       return "ConsumerEndpoint[" + id + "]";
    }
-
+   
    public JBossDestination getDestination()
    {
       return destination;
    }
-
+   
    public ServerSessionEndpoint getSessionEndpoint()
    {
       return sessionEndpoint;
    }
-
+   
    public int getId()
    {
       return id;
    }
-
+    
    // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
+   
+   // Protected -----------------------------------------------------   
+   
    protected void acknowledgeTransactionally(long messageID, Transaction tx) throws Throwable
    {
       if (trace) { log.trace("acknowledging transactionally " + messageID); }
-
+      
       SingleReceiverDelivery d = null;
-
+                 
       // The actual removal of the deliveries from the delivery list is deferred until tx commit
       synchronized (lock)
       {
-         if (closed)
-         {
-            //We must throw an exception to the client otherwise they may think the ack has succeeded
-            //This can happen if the connection is closed by another thread - e.g. the leasePinger
-            throw new IllegalStateException("Failed to acknowledge message, session has been closed");
-         }
-
          d = (SingleReceiverDelivery)deliveries.get(new Long(messageID));
       }
-
+      
       DeliveryCallback deliveryCallback = (DeliveryCallback)tx.getKeyedCallback(this);
-
+            
       if (deliveryCallback == null)
       {
          deliveryCallback = new DeliveryCallback();
          tx.addKeyedCallback(deliveryCallback, this);
       }
       deliveryCallback.addMessageID(messageID);
-
+         
       if (d != null)
       {
          d.acknowledge(tx);
@@ -503,36 +496,29 @@
       else
       {
          throw new IllegalStateException("Failed to acknowledge delivery " + d);
-      }
-   }
-
+      }             
+   }      
+   
    protected void acknowledge(long messageID) throws Throwable
-   {
-      // acknowledge a delivery
+   {  
+      // acknowledge a delivery   
       SingleReceiverDelivery d;
-
+        
       synchronized (lock)
       {
-         if (closed)
-         {
-            //We must throw an exception to the client otherwise they may think the ack has succeeded
-            //This can happen if the connection is closed by another thread - e.g. the leasePinger
-            throw new IllegalStateException("Failed to acknowledge message, session has been closed");
-         }
-
          d = (SingleReceiverDelivery)deliveries.remove(new Long(messageID));
       }
-
+      
       if (d != null)
       {
          d.acknowledge(null);
       }
       else
-      {
+      {     
          throw new IllegalStateException("Cannot find delivery to acknowledge:" + messageID);
-      }
+      }      
    }
-
+   
    /**
     * Actually remove the consumer and clear up any deliveries it may have
     * This is called by the session on session.close()
@@ -540,33 +526,32 @@
     *
     **/
    protected void remove() throws Throwable
-   {
+   {         
       if (trace) log.trace("attempting to remove receiver " + this + " from destination " + channel);
-
+      
       boolean wereDeliveries = false;
+      for(Iterator i = deliveries.values().iterator(); i.hasNext(); )
+      {
+         SingleReceiverDelivery d = (SingleReceiverDelivery)i.next();
 
-      synchronized (lock)
+         d.cancel();
+         wereDeliveries = true;
+      }
+      deliveries.clear();           
+      
+      if (!disconnected)
       {
-         for(Iterator i = deliveries.values().iterator(); i.hasNext(); )
+         if (!closed)
          {
-            SingleReceiverDelivery d = (SingleReceiverDelivery)i.next();
-
-            d.cancel();
-            wereDeliveries = true;
+            close();
          }
-         deliveries.clear();
       }
-
-      if (!disconnected && !closed)
-      {
-         close();
-      }
-
+      
       sessionEndpoint.getConnectionEndpoint().
-         getServerPeer().removeConsumerEndpoint(new Integer(id));
-
+         getServerPeer().removeConsumerEndpoint(new Integer(id));                  
+            
       sessionEndpoint.removeConsumerEndpoint(id);
-
+      
       if (wereDeliveries)
       {
          //If we cancelled any deliveries we need to force a deliver on the channel
@@ -574,34 +559,34 @@
          //any of the cancelled messages
          channel.deliver(false);
       }
-   }
-
+   }  
+   
    protected void promptDelivery()
    {
       channel.deliver(false);
    }
-
+   
    protected void sendToDLQ(Long messageID, Transaction tx) throws Throwable
    {
       SingleReceiverDelivery del = (SingleReceiverDelivery)deliveries.remove(messageID);
-
+      
       if (del != null)
-      {
+      { 
          log.warn(del.getReference() + " has exceed maximum delivery attempts and will be sent to the DLQ");
-
+         
          if (dlq != null)
-         {
+         {         
             //reset delivery count to zero
             del.getReference().setDeliveryCount(0);
-
+            
             dlq.handle(null, del.getReference(), tx);
-
-            del.acknowledge(tx);
+            
+            del.acknowledge(tx);           
          }
          else
          {
             log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
-
+            
             del.acknowledge(tx);
          }
       }
@@ -609,44 +594,31 @@
       {
          throw new IllegalStateException("Cannot find delivery to send to DLQ:" + id);
       }
-
+      
    }
-
+   
    protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
    {
-      SingleReceiverDelivery del;
-
-      synchronized (lock)
-      {
-         if (closed)
-         {
-            //This can happen if the connection is closed by another thread - e.g. the leasePinger
-            //We should then ignore the cancel since the delivery will have already been cancelled
-            //back to the queue
-            return;
-         }
-
-         del = (SingleReceiverDelivery)deliveries.remove(messageID);
-      }
-
+      SingleReceiverDelivery del = (SingleReceiverDelivery)deliveries.remove(messageID);
+      
       if (del != null)
-      {
+      {                               
          //Cancel back to the queue
-
+         
          //Update the delivery count
-
+           
          del.getReference().setDeliveryCount(deliveryCount);
-
-         del.cancel();
+              
+         del.cancel();         
       }
       else
       {
          throw new IllegalStateException("Cannot find delivery to cancel:" + id);
       }
    }
-
+               
    protected void start()
-   {
+   {             
       synchronized (lock)
       {
          // Can't start or stop it if it is closed.
@@ -654,21 +626,21 @@
          {
             return;
          }
-
+         
          if (started)
          {
             return;
          }
-
+         
          started = true;
       }
-
+      
       // Prompt delivery
       channel.deliver(false);
    }
-
+   
    protected void stop() throws Throwable
-   {
+   {     
       //We need to:
       //Stop accepting any new messages in the SCE
       //Flush any messages from the SCE to the buffer
@@ -683,58 +655,58 @@
          {
             return;
          }
-
+         
          started = false;
       }
-
+      
       //Now we know no more messages will be accepted in the SCE
-
+            
       try
       {
          //Flush any messages waiting to be sent to the client
          this.executor.execute(new Deliverer());
-
+         
          //Now wait for it to execute
          Future result = new Future();
-
+         
          this.executor.execute(new Waiter(result));
-
+         
          result.getResult();
-
+             
          //Now we know any deliverer has delivered any outstanding messages to the client buffer
       }
       catch (InterruptedException e)
       {
          log.warn("Thread interrupted", e);
       }
-
+            
       //Now we know that there are no in flight messages on the way to the client consumer.
-
+      
       //But there may be messages still in the toDeliver list since the client consumer might be full
       //So we need to cancel these
-
+            
       if (!toDeliver.isEmpty())
-      {
+      { 
          synchronized (lock)
          {
             for (int i = toDeliver.size() - 1; i >= 0; i--)
             {
                MessageProxy proxy = (MessageProxy)toDeliver.get(i);
-
+               
                long id = proxy.getMessage().getMessageID();
-
+               
                cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
             }
          }
-
+                 
          toDeliver.clear();
-
+         
          bufferFull = false;
-      }
+      }      
    }
-
+      
    // Private -------------------------------------------------------
-
+   
    /**
     * Disconnect this consumer from the Channel that feeds it. This method does not clear up
     * deliveries
@@ -742,18 +714,18 @@
    private void disconnect()
    {
       boolean removed = channel.remove(this);
-
+      
       if (removed)
       {
          disconnected = true;
          if (trace) { log.trace(this + " removed from the channel"); }
       }
    }
-
-   // Inner classes -------------------------------------------------
-
+        
+   // Inner classes -------------------------------------------------   
+   
    /*
-    * Delivers messages to the client
+    * Delivers messages to the client 
     * TODO - We can make this a bit more intelligent by letting it measure the rate
     * the client is consuming messages and send messages at that rate.
     * This would mean the client consumer wouldn't be full so often and more wouldn't have to be called
@@ -770,9 +742,9 @@
             if (trace) { log.trace(this + " client consumer full, do nothing"); }
             return;
          }
-
+         
          List list = null;
-
+             
          synchronized (lock)
          {
             if (trace) { log.trace(this + " has the main lock, attempting delivery"); }
@@ -784,7 +756,7 @@
                bufferFull = false;
             }
          }
-
+                                                           
          if (list == null)
          {
             if (trace) { log.trace(this + " has a null list, returning"); }
@@ -796,20 +768,7 @@
 
          try
          {
-            if (trace)
-            {
-               StringBuffer sb = new StringBuffer(ServerConsumerEndpoint.this + " handing [");
-               for(int i = 0; i < list.size(); i++)
-               {
-                  sb.append(((MessageProxy)list.get(i)).getMessage().getMessageID());
-                  if (i < list.size() - 1)
-                  {
-                     sb.append(",");
-                  }
-               }
-               sb.append("] over to the remoting layer");
-               log.trace(sb.toString());
-            }
+            if (trace) { log.trace(ServerConsumerEndpoint.this + " handing " + list.size() + " message(s) over to the remoting layer"); }
 
             ClientDelivery del = new ClientDelivery(list, id);
 
@@ -848,7 +807,7 @@
          return "Deliverer[" + Integer.toHexString(hashCode()) + "]";
       }
    }
-
+   
    /*
     * The purpose of this class is to put it on the QueuedExecutor and wait for it to run
     * We can then ensure that all the Runnables in front of it on the queue have also executed
@@ -859,20 +818,20 @@
    private class Waiter implements Runnable
    {
       Future result;
-
+      
       Waiter(Future result)
       {
          this.result = result;
       }
-
+      
       public void run()
       {
          result.setResult(null);
       }
    }
-
+   
    /**
-    *
+    * 
     * The purpose of this class is to remove deliveries from the delivery list on commit
     * Each transaction has once instance of this per SCE
     *
@@ -880,62 +839,51 @@
    private class DeliveryCallback implements TxCallback
    {
       List delList = new ArrayList();
-
+         
       public void beforePrepare()
-      {
+      {         
          //NOOP
       }
-
+      
       public void beforeCommit(boolean onePhase)
-      {
+      {         
          //NOOP
       }
-
+      
       public void beforeRollback(boolean onePhase)
-      {
+      {         
          //NOOP
       }
-
+      
       public void afterPrepare()
-      {
+      {         
          //NOOP
       }
-
+      
       public synchronized void afterCommit(boolean onePhase) throws TransactionException
       {
          // Remove the deliveries from the delivery map.
-         
-         synchronized (lock)
+         Iterator iter = delList.iterator();
+         while (iter.hasNext())
          {
-            if (closed)
-            {
-               //We must throw an exception to the client otherwise they may think the commit has succeeded
-               //This can happen if the connection is closed by another thread - e.g. the leasePinger
-               throw new TransactionException("Failed to acknowledge message, session has been closed");
-            }
+            Long messageID = (Long)iter.next();
             
-            Iterator iter = delList.iterator();
-            while (iter.hasNext())
+            if (deliveries.remove(messageID) == null)
             {
-               Long messageID = (Long)iter.next();
-   
-               if (deliveries.remove(messageID) == null)
-               {
-                  throw new TransactionException("Failed to remove delivery " + messageID);
-               }
+               throw new TransactionException("Failed to remove delivery " + messageID);
             }
          }
       }
-
+      
       public void afterRollback(boolean onePhase) throws TransactionException
-      {
+      {                            
          //NOOP
       }
-
+      
       synchronized void addMessageID(long messageID)
       {
          delList.add(new Long(messageID));
       }
    }
-
+   
 }

Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-01 09:47:27 UTC (rev 1671)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-01 19:37:10 UTC (rev 1672)
@@ -278,29 +278,8 @@
 
    public void cancel(Delivery d) throws Throwable
    {
-      // We put the cancellation on the event queue
-      // try
-      // {
-      // Future result = new Future();
-      //
-      // this.executor.execute(new CancelRunnable(d, result));
-      //
-      // //For now we wait for result, but this may not be necessary
-      // result.getResult();
-      // }
-      // catch (InterruptedException e)
-      // {
-      // log.warn("Thread interrupted", e);
-      // }
-
-//      Exception e = new Exception();
-//
-//      log.error("cancelling delivery: " + d, e);
-//
-
-
-      // TODO We should also consider executing cancels on the event queue
-      cancelInternal(d);
+       //We put the cancellation on the event queue     
+       this.executor.execute(new CancelRunnable(d));
    }
 
    // Distributor implementation ------------------------------------
@@ -645,24 +624,23 @@
          // The iterator is used to iterate through the refs in the channel in the case that they
          // don't match the selectors of any receivers.
          ListIterator iter = null;
-
+         
          MessageReference ref = null;
-
+         
          while (true)
-         {
+         {           
             synchronized (refLock)
-            {
+            {              
                if (iter == null)
                {
-                  //ref = (MessageReference) messageRefs.peekFirst();
-                  ref = removeFirstInMemory();
+                  ref = (MessageReference) messageRefs.peekFirst();
                }
                else
                {
                   if (iter.hasNext())
-                  {
+                  {                        
                      ref = (MessageReference)iter.next();
-                  }
+                  } 
                   else
                   {
                      ref = null;
@@ -672,10 +650,9 @@
 
             if (ref != null)
             {
-               if (trace) { log.trace(this + " pushing " + ref); }
-
-               // Check if message is expired (we also do this on the client side). If so ack it
-               // from the channel.
+               // Check if message is expired (we also do this on the client
+               // side)
+               // If so ack it from the channel
                if (ref.isExpired())
                {
                   if (trace) { log.trace("Message reference: " + ref + " has expired"); }
@@ -683,8 +660,7 @@
                   // remove and acknowledge it
                   if (iter == null)
                   {
-                     //already removed
-                     //removeFirstInMemory();
+                     removeFirstInMemory();
                   }
                   else
                   {
@@ -711,28 +687,15 @@
                      if (trace) { log.trace(this + ": no delivery returned for message" + ref + " so no receiver got the message. Delivery is now complete"); }
 
                      receiversReady = false;
-
-                     if (iter == null)
-                     {
-                        // add the message back
-                        synchronized (refLock)
-                        {
-                           messageRefs.addFirst(ref, ref.getPriority());
-                        }
-                     }
-                     else
-                     {
-                        //we didn't remove it in the first place
-                     }
-
+                     
                      return;
                   }
                   else if (!del.isSelectorAccepted())
                   {
                      // No receiver accepted the message because no selectors matched, so we create
                      // an iterator (if we haven't already created it) to iterate through the refs
-                     // in the channel.
-
+                     // in the channel. 
+                     
                      // TODO Note that this is only a partial solution since if there are messages
                      // paged to storage it won't try those - i.e. it will only iterate through
                      // those refs in memory. Dealing with refs in storage is somewhat tricky since
@@ -742,27 +705,15 @@
                      // indexes here to prevent having to iterate through all the refs every time.
                      // Having said all that, having consumers on a queue that don't match many
                      // messages is an antipattern and should be avoided by the user.
-
                      if (iter == null)
                      {
-                        //Add the message back
-
-                        synchronized (refLock)
-                        {
-                           messageRefs.addFirst(ref, ref.getPriority());
-
-                           iter = messageRefs.iterator();
-
-                           //And skip the first one (that's the one we just added back)
-
-                           iter.next();
-                        }
-                     }
+                        iter = messageRefs.iterator();
+                     }                     
                   }
                   else
                   {
                      if (trace) { log.trace(this + ": " + del + " returned for message:" + ref); }
-
+                     
                      // Receiver accepted the reference
 
                      // We must synchronize here to cope with another race condition where message
@@ -776,9 +727,11 @@
                         // FIXME - It's actually possible the delivery could be
                         // cancelled before it reaches
                         // here, in which case we wouldn't get a delivery but we
-                        // still need to increment the delivery count
+                        // still need to increment the
+                        // delivery count
                         // All the problems related to these race conditions and
-                        // fiddly edge cases will disappear once we do
+                        // fiddly edge cases will disappear
+                        // once we do
                         // http://jira.jboss.com/jira/browse/JBMESSAGING-355
                         // This will make life a lot easier
 
@@ -786,13 +739,11 @@
                         {
                            if (iter == null)
                            {
-                              //do nothing - already removed
-                              //removeFirstInMemory();
+                              removeFirstInMemory();
                            }
                            else
                            {
-                              iter.remove();
-                              if (trace) { log.trace(this + " removed current message from iterator"); }
+                              iter.remove();                                
                            }
 
                            // delivered
@@ -802,7 +753,6 @@
                               synchronized (deliveryLock)
                               {
                                  deliveries.add(del);
-                                 if (trace) { log.trace(this + " starting to track  " + del); }
                               }
                            }
                         }
@@ -1734,7 +1684,29 @@
          }
       }
    }
+   
+   private class CancelRunnable implements Runnable
+   {
+      Delivery del;
+      
+      CancelRunnable(Delivery del)
+      {
+         this.del = del;
+      }
 
+      public void run()
+      {
+         try
+         {
+            cancelInternal(del);
+         }
+         catch (Exception e)
+         {
+            log.error("Failed to cancel delivery", e);
+         }
+      }
+   }
+
    private class HandleRunnable implements Runnable
    {
       Future result;

Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-01 09:47:27 UTC (rev 1671)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-01 19:37:10 UTC (rev 1672)
@@ -386,7 +386,7 @@
             
             ps.setLong(2, size);
             
-            int rows = ps.executeUpdate();
+            int rows = updateWithRetry(ps);
             
             if (trace)
             {
@@ -418,7 +418,7 @@
          
          ps.setString(2, counterName);
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -471,8 +471,6 @@
       PreparedStatement ps = null;
       TransactionWrapper wrap = new TransactionWrapper();
       
-      final int MAX_TRIES = 25;      
-      
       try
       {
          conn = ds.getConnection();
@@ -484,41 +482,15 @@
          ps.setLong(2, orderEnd);
          
          ps.setLong(3, channelID);
-         
-         int tries = 0;
-         
-         while (true)
+                  
+         int rows = updateWithRetry(ps);
+               
+         if (trace)
          {
-            try
-            {
-               int rows = ps.executeUpdate();
-               
-               if (trace)
-               {
-                  log.trace(JDBCUtil.statementToString(updateReliableRefs, new Long(channelID),
-                        new Long(orderStart), new Long(orderEnd))
-                        + " updated " + rows + " rows");
-               }
-               if (tries > 0)
-               {
-                  log.warn("Update worked after retry");
-               }
-               break;
-            }
-            catch (SQLException e)
-            {
-               log.warn("SQLException caught - assuming deadlock detected, try:" + (tries + 1), e);
-               tries++;
-               if (tries == MAX_TRIES)
-               {
-                  log.error("Retried " + tries + " times, now giving up");
-                  throw new IllegalStateException("Failed to update references");
-               }
-               log.warn("Trying again after a pause");
-               //Now we wait for a random amount of time to minimise risk of deadlock
-               Thread.sleep((long)(Math.random() * 500));
-            }  
-         }
+            log.trace(JDBCUtil.statementToString(updateReliableRefs, new Long(channelID),
+                  new Long(orderStart), new Long(orderEnd))
+                  + " updated " + rows + " rows");
+         }          
       }
       catch (Exception e)
       {
@@ -550,6 +522,8 @@
          wrap.end();
       }
    }
+   
+   
          
    public int getNumberOfUnloadedReferences(long channelID) throws Exception
    {
@@ -859,7 +833,7 @@
             }
             else
             {
-               int rows = psInsertReference.executeUpdate();
+               int rows = updateWithRetry(psInsertReference);
                
                if (trace)
                {
@@ -916,7 +890,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                                       
                   if (trace)
                   {
@@ -925,7 +899,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                  
                   if (trace)
                   {
@@ -941,7 +915,7 @@
          
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psInsertReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psInsertReference);
             
             if (trace)
             {
@@ -950,7 +924,7 @@
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace)
                {
@@ -959,7 +933,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -1092,7 +1066,7 @@
             }
             else
             {
-               int rows = psDeleteReference.executeUpdate();
+               int rows = updateWithRetry(psDeleteReference);
                
                if (trace)
                {
@@ -1150,7 +1124,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -1159,7 +1133,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -1175,7 +1149,7 @@
          
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psDeleteReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psDeleteReference);
             
             if (trace)
             {
@@ -1184,7 +1158,7 @@
             
             if (messageDeletionsInBatch)
             {
-               int[] rowsMessage = psDeleteMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -1193,7 +1167,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -1561,7 +1535,7 @@
             }
             else
             {
-               int rows = psUpdateReference.executeUpdate();
+               int rows = updateWithRetry(psUpdateReference);
                
                if (trace)
                {
@@ -1575,7 +1549,7 @@
                      
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psUpdateReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psUpdateReference);
             
             if (trace)
             {
@@ -1652,7 +1626,7 @@
             // Add the reference
             addReference(channelID, ref, psReference, true);
             
-            int rows = psReference.executeUpdate();
+            int rows = updateWithRetry(psReference);
             
             if (trace)
             {
@@ -1677,7 +1651,7 @@
                updateMessageChannelCount(m, psMessage);
             }
                            
-            rows = psMessage.executeUpdate();
+            rows = updateWithRetry(psMessage);
             if (trace)
             {
                log.trace("Inserted/updated " + rows + " rows");
@@ -1757,7 +1731,7 @@
          
          psReference.setLong(3, ref.getMessageID());
          
-         int rows = psReference.executeUpdate();                         
+         int rows = updateWithRetry(psReference);                         
       }
       catch (Exception e)
       {
@@ -1825,7 +1799,7 @@
             //Remove the message reference
             removeReference(channelID, ref, psReference);
             
-            int rows = psReference.executeUpdate();
+            int rows = updateWithRetry(psReference);
             
             if (trace)
             {
@@ -1850,7 +1824,7 @@
                updateMessageChannelCount(m, psMessage);
             }
                               
-            rows = psMessage.executeUpdate();
+            rows = updateWithRetry(psMessage);
             
             if (trace)
             {
@@ -2747,7 +2721,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -2802,7 +2776,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                   
                   if (trace)
                   {
@@ -2811,7 +2785,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -2827,7 +2801,7 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -2836,7 +2810,7 @@
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace)
                {
@@ -2845,7 +2819,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -2896,7 +2870,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -2953,7 +2927,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -2962,7 +2936,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -2978,7 +2952,7 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -2987,7 +2961,7 @@
             
             if (messageDeletionsInBatch)
             {
-               int[] rowsMessage = psDeleteMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -2996,7 +2970,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3190,7 +3164,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -3199,7 +3173,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3217,7 +3191,7 @@
          {
             if (messageDeletionsInBatch)
             {
-               int[] rows = psDeleteMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -3229,7 +3203,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rows = psUpdateMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3364,7 +3338,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -3419,7 +3393,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                   
                   if (trace)
                   {
@@ -3428,7 +3402,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3444,7 +3418,7 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -3453,7 +3427,7 @@
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace)
                {
@@ -3462,7 +3436,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3505,7 +3479,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -3519,7 +3493,7 @@
          
          if (batch)
          {
-            int[] rows = psReference.executeBatch();
+            int[] rows = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -3689,7 +3663,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -3698,7 +3672,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3716,7 +3690,7 @@
          {
             if (messageDeletionsInBatch)
             {
-               int[] rows = psDeleteMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -3728,7 +3702,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rows = psUpdateMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3820,7 +3794,7 @@
          ps.setInt(3, formatID);
          ps.setBytes(4, xid.getGlobalTransactionId());
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
       }
       finally
@@ -3845,7 +3819,7 @@
       }
    }
    
-   protected void removeTXRecord(Connection conn, Transaction tx) throws SQLException
+   protected void removeTXRecord(Connection conn, Transaction tx) throws Exception
    {
       PreparedStatement ps = null;
       try
@@ -3854,7 +3828,7 @@
          
          ps.setLong(1, tx.getId());
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -3948,7 +3922,7 @@
          
          ps.setLong(1, tx.getId());        
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -3959,7 +3933,7 @@
          ps = conn.prepareStatement(commitMessageRef2);
          ps.setLong(1, tx.getId());         
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -3994,7 +3968,7 @@
          
          ps.setLong(1, tx.getId());         
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4006,7 +3980,7 @@
          ps = conn.prepareStatement(rollbackMessageRef2);
          ps.setLong(1, tx.getId());
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4380,6 +4354,70 @@
       log.trace("Batch update " + name + ", " + action + " total of " + count + " rows");
    }
    
+   protected int updateWithRetry(PreparedStatement ps) throws Exception
+   {
+      return updateWithRetry(ps, false)[0];
+   }
+   
+   protected int[] updateWithRetryBatch(PreparedStatement ps) throws Exception
+   {
+      return updateWithRetry(ps, true);
+   }
+   
+   private int[] updateWithRetry(PreparedStatement ps, boolean batch) throws Exception
+   {
+      final int MAX_TRIES = 25;      
+      
+      int rows = 0;
+      
+      int[] rowsArr = null;
+      
+      int tries = 0;
+      
+      while (true)
+      {
+         try
+         {
+            if (batch)
+            {
+               rowsArr = ps.executeBatch();
+            }
+            else
+            {
+               rows = ps.executeUpdate();
+            }
+            
+            if (tries > 0)
+            {
+               log.warn("Update worked after retry");
+            }
+            break;
+         }
+         catch (SQLException e)
+         {
+            log.warn("SQLException caught - assuming deadlock detected, try:" + (tries + 1), e);
+            tries++;
+            if (tries == MAX_TRIES)
+            {
+               log.error("Retried " + tries + " times, now giving up");
+               throw new IllegalStateException("Failed to update references");
+            }
+            log.warn("Trying again after a pause");
+            //Now we wait for a random amount of time to minimise risk of deadlock
+            Thread.sleep((long)(Math.random() * 500));
+         }  
+      }
+      
+      if (batch)
+      {
+         return rowsArr;
+      }
+      else
+      {
+         return new int[] { rows };
+      }
+   }
+   
    // Private -------------------------------------------------------
 
    // never access directly

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-01 09:47:27 UTC (rev 1671)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-01 19:37:10 UTC (rev 1672)
@@ -895,6 +895,9 @@
 
           cons1.close();
           
+          //Cancelling is asynch so can take some time
+          Thread.sleep(500);
+          
           //rollback should cause redelivery of messages
 
           //in this case redelivery occurs to a different receiver



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 15:09:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 15:09:50 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1673 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GqEhi-0001Os-5C@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-01 15:09:48 -0500 (Fri, 01 Dec 2006)
New Revision: 1673

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
just adding headers.. nothing else

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-01 19:37:10 UTC (rev 1672)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-01 20:09:48 UTC (rev 1673)
@@ -1,12 +1,41 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
 
-import javax.jms.*;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.Queue;
+import javax.jms.Session;
+import javax.jms.Topic;
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
 /**
+ * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @version <tt>$Revision:$</tt>
  *          <p/>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-01 19:37:10 UTC (rev 1672)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-01 20:09:48 UTC (rev 1673)
@@ -1,20 +1,29 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
 
-import javax.jms.Destination;
-import javax.jms.Message;
 import javax.jms.MessageConsumer;
-import javax.jms.MessageProducer;
-import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.jms.Topic;
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.JBossMessageConsumer;
-import org.jboss.jms.client.JBossSession;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.client.state.ConsumerState;
-import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.tools.ServerManagement;



From michael.yuan at jboss.com  Fri Dec  1 15:40:52 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 15:40:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish  ...
Message-ID: <E1GqFBk-0001x8-3C@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 15:40:52

  Modified:    examples/glassfish  build.xml
  Log:
  move the jboss-archive-browsing.jar to shared lib
  
  Revision  Changes    Path
  1.3       +0 -2      jboss-seam/examples/glassfish/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- build.xml	30 Nov 2006 05:02:02 -0000	1.2
  +++ build.xml	1 Dec 2006 20:40:52 -0000	1.3
  @@ -106,8 +106,6 @@
         </fileset>
         <fileset dir="${hibernatelib}">
           <include name="hibernate*.jar" />
  -      </fileset>
  -      <fileset dir="${applib}">
           <include name="jboss-archive-browsing.jar" />
         </fileset>
         <fileset dir="${build.jars}">
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 15:40:52 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 15:40:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/lib  ...
Message-ID: <E1GqFBk-0001xC-6V@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 15:40:52

  Removed:     examples/glassfish/lib  jboss-archive-browsing.jar
  Log:
  move the jboss-archive-browsing.jar to shared lib


From michael.yuan at jboss.com  Fri Dec  1 15:41:43 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 15:41:43 -0500
Subject: [jboss-cvs] jboss-seam/hibernate/lib   ...
Message-ID: <E1GqFCZ-0001yV-CU@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 15:41:43

  Modified:    hibernate/lib   hibernate-entitymanager.jar
  Added:       hibernate/lib   jboss-archive-browsing.jar
  Log:
  Fix the EM for WL and shared jboss-archive-browsing.jar
  
  Revision  Changes    Path
  1.2       +184 -199  jboss-seam/hibernate/lib/hibernate-entitymanager.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/01 20:41:43;  author: myuan;  state: Exp;jboss-seam/hibernate/lib/jboss-archive-browsing.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 15:55:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 15:55:33 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1674 - in
	branches/Branch_1_0_1_SP: src/main/org/jboss/jms/server/endpoint
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GqFPx-0002EN-SU@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-01 15:55:27 -0500 (Fri, 01 Dec 2006)
New Revision: 1674

Modified:
   branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
Log:
More on fix



Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-01 20:09:48 UTC (rev 1673)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-01 20:55:27 UTC (rev 1674)
@@ -222,15 +222,8 @@
          // channel for delivery later.
          if (!started)
          {
-            // this is a common programming error, make this visible in the debug logs. However,
-            // make also possible to cut out the performance overhead for systems that raise the
-            // threshold to INFO or higher.
+            if (trace) { log.debug(this + " NOT started yet!"); }
 
-            if (log.isDebugEnabled())
-            {
-               log.debug(this + " NOT started yet!");
-            }
-
             return null;
          }
 
@@ -529,22 +522,27 @@
    {         
       if (trace) log.trace("attempting to remove receiver " + this + " from destination " + channel);
       
-      boolean wereDeliveries = false;
-      for(Iterator i = deliveries.values().iterator(); i.hasNext(); )
-      {
-         SingleReceiverDelivery d = (SingleReceiverDelivery)i.next();
-
-         d.cancel();
-         wereDeliveries = true;
-      }
-      deliveries.clear();           
+      boolean wereDeliveries = false;       
       
-      if (!disconnected)
-      {
-         if (!closed)
+      synchronized (lock)
+      {          
+         for (Iterator i = deliveries.values().iterator(); i.hasNext(); )
          {
-            close();
+            SingleReceiverDelivery d = (SingleReceiverDelivery)i.next();
+   
+            d.cancel();
+            wereDeliveries = true;
          }
+               
+         deliveries.clear();           
+         
+         if (!disconnected)
+         {
+            if (!closed)
+            {
+               close();
+            }
+         }
       }
       
       sessionEndpoint.getConnectionEndpoint().
@@ -599,8 +597,13 @@
    
    protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
    {
-      SingleReceiverDelivery del = (SingleReceiverDelivery)deliveries.remove(messageID);
+      SingleReceiverDelivery del = null;
       
+      synchronized (lock)
+      {         
+         del = (SingleReceiverDelivery)deliveries.remove(messageID);
+      }
+      
       if (del != null)
       {                               
          //Cancel back to the queue
@@ -655,10 +658,10 @@
          {
             return;
          }
+      }
          
-         started = false;
-      }
-      
+      started = false;      
+   
       //Now we know no more messages will be accepted in the SCE
             
       try
@@ -687,22 +690,19 @@
             
       if (!toDeliver.isEmpty())
       { 
-         synchronized (lock)
+         for (int i = toDeliver.size() - 1; i >= 0; i--)
          {
-            for (int i = toDeliver.size() - 1; i >= 0; i--)
-            {
-               MessageProxy proxy = (MessageProxy)toDeliver.get(i);
-               
-               long id = proxy.getMessage().getMessageID();
-               
-               cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
-            }
+            MessageProxy proxy = (MessageProxy)toDeliver.get(i);
+            
+            long id = proxy.getMessage().getMessageID();
+            
+            cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
          }
-                 
+             
          toDeliver.clear();
          
          bufferFull = false;
-      }      
+      }            
    }
       
    // Private -------------------------------------------------------
@@ -862,15 +862,17 @@
       
       public synchronized void afterCommit(boolean onePhase) throws TransactionException
       {
-         // Remove the deliveries from the delivery map.
-         Iterator iter = delList.iterator();
-         while (iter.hasNext())
+         synchronized (lock)
          {
-            Long messageID = (Long)iter.next();
-            
-            if (deliveries.remove(messageID) == null)
+            // Remove the deliveries from the delivery map.
+            Iterator iter = delList.iterator();
+            while (iter.hasNext())
             {
-               throw new TransactionException("Failed to remove delivery " + messageID);
+               Long messageID = (Long)iter.next();
+               
+               //The message might have been removed already if the consumer was closed for instance
+               //This is ok
+               deliveries.remove(messageID);               
             }
          }
       }

Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-01 20:09:48 UTC (rev 1673)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-01 20:55:27 UTC (rev 1674)
@@ -384,7 +384,7 @@
       }
    }
 
-   public void close() throws JMSException
+   public synchronized void close() throws JMSException
    {
       try
       {
@@ -438,10 +438,15 @@
       }
    }
    
-   public void acknowledgeBatch(List ackInfos) throws JMSException
+   public synchronized void acknowledgeBatch(List ackInfos) throws JMSException
    {      
       try
       {
+         if (closed)
+         {
+            throw new javax.jms.IllegalStateException("Cannot acknowledge batch since session is closed");
+         }
+                  
          Iterator iter = ackInfos.iterator();
          
          while (iter.hasNext())
@@ -457,10 +462,15 @@
       }
    }
    
-   public void acknowledge(AckInfo ackInfo) throws JMSException
+   public synchronized void acknowledge(AckInfo ackInfo) throws JMSException
    {
       try
       {
+         if (closed)
+         {
+            throw new javax.jms.IllegalStateException("Cannot acknowledge " + ackInfo + " since session is closed");
+         }
+         
          acknowledgeInternal(ackInfo);      
       }
       catch (Throwable t)
@@ -469,10 +479,19 @@
       }
    }      
         
-   public void cancelDeliveries(List ackInfos) throws JMSException
+   public synchronized void cancelDeliveries(List ackInfos) throws JMSException
    {
       try
       {
+         if (closed)
+         {
+            //We can safely ignore any cancels since closing the session will have cancelled anything
+            //remaining
+            log.warn("Call to cancelDeliveries came in after session was closed");
+            
+            return;
+         }
+         
          // deliveries must be cancelled in reverse order
           
          Set consumers = new HashSet();

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-01 20:09:48 UTC (rev 1673)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-01 20:55:27 UTC (rev 1674)
@@ -1012,6 +1012,9 @@
           assertEquals("hello1", rm1.getText());
 
           cons1.close();
+          
+          //Give time for asynch cancel to happen
+          Thread.sleep(500);
          
           log.debug("sess.recover()");
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 16:38:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 16:38:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r58811 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1GqG5b-0002yX-N4@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-01 16:38:33 -0500 (Fri, 01 Dec 2006)
New Revision: 58811

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java
Log:
Restore the ORB and UserTransaction enc bindings.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java	2006-12-01 19:20:44 UTC (rev 58810)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java	2006-12-01 21:38:33 UTC (rev 58811)
@@ -44,6 +44,7 @@
 import javax.management.ObjectName;
 import javax.naming.Context;
 import javax.naming.InitialContext;
+import javax.naming.LinkRef;
 
 import org.apache.catalina.Loader;
 import org.apache.tomcat.util.modeler.Registry;
@@ -51,6 +52,7 @@
 import org.jboss.logging.Logger;
 import org.jboss.metadata.WebMetaData;
 import org.jboss.mx.util.MBeanServerLocator;
+import org.jboss.naming.NonSerializableFactory;
 import org.jboss.security.AuthorizationManager;
 import org.jboss.security.authorization.PolicyRegistration;
 import org.jboss.virtual.VirtualFile;
@@ -337,6 +339,28 @@
             metaData.setENCLoader(webLoader.getClassLoader());
             InitialContext iniCtx = new InitialContext();
             Context envCtx = (Context) iniCtx.lookup("java:comp");
+            // Add ORB/UserTransaction
+            ORB orb = null;
+            try
+            {
+               ObjectName ORB_NAME = new ObjectName("jboss:service=CorbaORB");
+               orb = (ORB) server.getAttribute(ORB_NAME, "ORB");
+               // Bind the orb
+               if (orb != null)
+               {
+                  NonSerializableFactory.rebind(envCtx, "ORB", orb);
+                  log.debug("Bound java:comp/ORB");
+               }
+            }
+            catch (Throwable t)
+            {
+               log.debug("Unable to retrieve orb" + t.toString());
+            }
+
+            // TODO: injection, Add a link to the global transaction manager
+            envCtx.bind("UserTransaction", new LinkRef("UserTransaction"));
+            log.debug("Linked java:comp/UserTransaction to JNDI name: UserTransaction");
+
             envCtx = envCtx.createSubcontext("env");
             injectionContainer.populateEnc(webLoader.getClassLoader());
             // TODO: this should be bindings in the metadata



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 17:07:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 17:07:38 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58812 - trunk/server
Message-ID: <E1GqGXi-0003XM-FU@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-01 17:07:36 -0500 (Fri, 01 Dec 2006)
New Revision: 58812

Modified:
   trunk/server/build.xml
Log:
JBAS-3893, synch up the org.jboss.invocation classes included in jboss-client.jar with the 4.0 contents.

Modified: trunk/server/build.xml
===================================================================
--- trunk/server/build.xml	2006-12-01 21:38:33 UTC (rev 58811)
+++ trunk/server/build.xml	2006-12-01 22:07:36 UTC (rev 58812)
@@ -434,22 +434,7 @@
         <include name="org/jboss/ejb/plugins/keygenerator/KeyGenerator.class"/>
         <include name="org/jboss/ejb/plugins/keygenerator/KeyGeneratorFactory.class"/>
         <include name="org/jboss/ejb/plugins/lock/ApplicationDeadlockException.class"/>
-        <include name="org/jboss/invocation/ByValueInvokerInterceptor.class"/>
-        <include name="org/jboss/invocation/Invocation.class"/>
-        <include name="org/jboss/invocation/InvocationContext.class"/>
-        <include name="org/jboss/invocation/InvocationKey.class"/>
-        <include name="org/jboss/invocation/InvocationException.class"/>
-        <include name="org/jboss/invocation/InvocationType.class"/>
-        <include name="org/jboss/invocation/Invoker.class"/>
-        <include name="org/jboss/invocation/InvokerInterceptor.class"/>
-        <include name="org/jboss/invocation/JBossLazyUnmarshallingException.class"/>
-        <include name="org/jboss/invocation/MarshallingInvokerInterceptor.class"/>
-        <include name="org/jboss/invocation/PayloadKey.class"/>
-        <include name="org/jboss/invocation/MarshalledInvocation.class"/>
-        <include name="org/jboss/invocation/MarshalledValue.class"/>
-        <include name="org/jboss/invocation/MarshalledValueInputStream.class"/>
-        <include name="org/jboss/invocation/MarshalledValueOutputStream*.class"/>
-        <include name="org/jboss/invocation/ServiceUnavailableException.class"/>
+        <include name="org/jboss/invocation/*"/>
         <include name="org/jboss/invocation/http/interfaces/*"/>
         <include name="org/jboss/invocation/jrmp/interfaces/*"/>
         <include name="org/jboss/invocation/jrmp/server/*Stub.class"/>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 18:08:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 18:08:08 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1675 -
	branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging
Message-ID: <E1GqHUG-0004RV-AV@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-01 18:08:04 -0500 (Fri, 01 Dec 2006)
New Revision: 1675

Modified:
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
   branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
Log:
few more tweaks



Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-01 20:55:27 UTC (rev 1674)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-01 23:08:04 UTC (rev 1675)
@@ -829,6 +829,9 @@
          dels[i].cancel();   
       }
       
+      //Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -862,6 +865,9 @@
          dels[i].cancel();
       }
       
+//    Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -896,6 +902,8 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);      
       
       //This should cause the down cache to be flushed
       

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-01 20:55:27 UTC (rev 1674)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-01 23:08:04 UTC (rev 1675)
@@ -781,6 +781,9 @@
          dels[i].cancel();  
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -814,6 +817,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -847,6 +853,8 @@
       {
          dels[i].cancel();
       }
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
       
       //consumeCount += 20;
       

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-01 20:55:27 UTC (rev 1674)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-01 23:08:04 UTC (rev 1675)
@@ -819,6 +819,9 @@
          dels[i].cancel();  
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -852,6 +855,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -887,6 +893,9 @@
       }
       
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 20 ref in storage

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-01 20:55:27 UTC (rev 1674)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-01 23:08:04 UTC (rev 1675)
@@ -926,6 +926,9 @@
          dels[i].cancel(); 
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -965,6 +968,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -1004,6 +1010,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //consumeCount += 20;
       
       //This should cause the down cache to be flushed

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-01 20:55:27 UTC (rev 1674)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-01 23:08:04 UTC (rev 1675)
@@ -880,6 +880,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -918,6 +921,8 @@
       {
          dels[i].cancel();
       }
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
       
       //This should cause the down cache to be flushed
       
@@ -957,6 +962,9 @@
       {
          dels[i].cancel();
       }
+           
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);     
       
       //consumeCount += 20;
       

Modified: branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
===================================================================
--- branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-01 20:55:27 UTC (rev 1674)
+++ branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-01 23:08:04 UTC (rev 1675)
@@ -913,6 +913,9 @@
          dels[i].cancel();   
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250); 
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -952,6 +955,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -991,6 +997,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //consumeCount += 20;
       
       //This should cause the down cache to be flushed



From gavin.king at jboss.com  Fri Dec  1 18:28:25 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 18:28:25 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui  ...
Message-ID: <E1GqHnt-0004hm-9p@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 18:28:25

  Modified:    src/ui/org/jboss/seam/ui  HtmlButton.java
  Log:
  JBSEAM-574
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlButton.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- HtmlButton.java	19 Nov 2006 17:36:11 -0000	1.2
  +++ HtmlButton.java	1 Dec 2006 23:28:25 -0000	1.3
  @@ -190,7 +190,7 @@
            onclick += "location.href='" + encodedUrl + "'";
         }
         writer.writeAttribute("onclick", onclick, null);
  -      HTML.renderHTMLAttributes(writer, this, HTML.BUTTON_PASSTHROUGH_ATTRIBUTES_WITHOUT_DISABLED);
  +      HTML.renderHTMLAttributes(writer, this, HTML.BUTTON_PASSTHROUGH_ATTRIBUTES_WITHOUT_DISABLED_AND_ONCLICK);
         
         Object label = getValue();
         if (label!=null) 
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:56:16 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:56:16 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/src/org/jboss/seam/example/jpa ...
Message-ID: <E1GqIEq-0005BE-IZ@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:56:16

  Modified:    examples/jpa/src/org/jboss/seam/example/jpa  Booking.java
  Log:
  Make both WL and GF work ...
  
  Revision  Changes    Path
  1.3       +2 -2      jboss-seam/examples/jpa/src/org/jboss/seam/example/jpa/Booking.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Booking.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/src/org/jboss/seam/example/jpa/Booking.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Booking.java	30 Nov 2006 20:59:23 -0000	1.2
  +++ Booking.java	1 Dec 2006 23:56:16 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: Booking.java,v 1.2 2006/11/30 20:59:23 myuan Exp $
  +//$Id: Booking.java,v 1.3 2006/12/01 23:56:16 myuan Exp $
   package org.jboss.seam.example.jpa;
   
   import java.io.Serializable;
  @@ -44,7 +44,7 @@
         this.user = user;
      }
   
  -   @Id @GeneratedValue(strategy=GenerationType.IDENTITY)
  +   @Id @GeneratedValue
      public Long getId()
      {
         return id;
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:56:16 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:56:16 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/resources/weblogic  ...
Message-ID: <E1GqIEq-0005B7-DY@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:56:16

  Modified:    examples/jpa/resources/weblogic  log4j.xml
  Log:
  Make both WL and GF work ...
  
  Revision  Changes    Path
  1.2       +1 -2      jboss-seam/examples/jpa/resources/weblogic/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/weblogic/log4j.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- log4j.xml	29 Nov 2006 09:23:46 -0000	1.1
  +++ log4j.xml	1 Dec 2006 23:56:16 -0000	1.2
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.1 2006/11/29 09:23:46 myuan Exp $ -->
  +<!-- $Id: log4j.xml,v 1.2 2006/12/01 23:56:16 myuan Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -17,7 +17,6 @@
   <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
      
      <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
  -      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
         <param name="Target" value="System.out"/>
   
         <layout class="org.apache.log4j.PatternLayout">
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:56:16 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:56:16 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa   ...
Message-ID: <E1GqIEq-0005Af-3n@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:56:16

  Modified:    examples/jpa   build.xml readme.txt
  Log:
  Make both WL and GF work ...
  
  Revision  Changes    Path
  1.7       +5 -5      jboss-seam/examples/jpa/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/build.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- build.xml	30 Nov 2006 06:39:35 -0000	1.6
  +++ build.xml	1 Dec 2006 23:56:16 -0000	1.7
  @@ -209,9 +209,11 @@
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  +      <!--
         <lib dir="${applib}/mc">
           <include name="*.jar" />
         </lib>
  +      -->
         <lib dir="${lib}">
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
  @@ -241,6 +243,8 @@
         </fileset>
         <fileset dir="${resources}">
           <include name="seam.properties" />
  +      </fileset>
  +      <fileset dir="${resources}/glassfish">
           <include name="import.sql" />
         </fileset>
         <metainf dir="${resources}/glassfish">
  @@ -268,12 +272,7 @@
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  -      <lib dir="${applib}/mc">
  -        <include name="*.jar" />
  -      </lib>
         <lib dir="${lib}">
  -        <include name="myfaces-api-1.1.4.jar" />
  -        <include name="myfaces-impl-1.1.4.jar" />
           <include name="thirdparty-all.jar" />
           <include name="commons*.jar" />
         </lib>
  @@ -285,6 +284,7 @@
         </lib>
         <classes dir="${resources}/glassfish">
           <include name="log4j.xml" />
  +        <include name="GlassfishDerbyDialect.class" />
         </classes>
         <fileset dir="${view}"/>
       </war>
  
  
  
  1.2       +12 -3     jboss-seam/examples/jpa/readme.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: readme.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/readme.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- readme.txt	30 Nov 2006 06:39:35 -0000	1.1
  +++ readme.txt	1 Dec 2006 23:56:16 -0000	1.2
  @@ -2,17 +2,17 @@
   It can be deployed in JBoss AS 4.x, WebLogic, Glassfish, Tomcat without
   the EJB3 container.
   
  -JBoss AS 4.0.5 (no EJB3):
  +JBoss AS 4.0.5 (with or without EJB3):
     * Install JBoss AS 4.0.5 with the default J2EE profile
     * ant jboss
     * Deploy build/jboss-seam-jpa.war
     * Start JBoss AS 
     * Access the app at http://localhost:8080/jboss-seam-jpa/
   
  -WebLogic 9.2 (NOT working yet):
  +WebLogic 9.2:
     * Install WebLogic 9.2
     * ant weblogic
  -  * Start WebLogic
  +  * Start the WebLogic "examples" server
     * Load the admin console http://localhost:7001/console/
     * Deploy build/jboss-seam-jpa.war
     * Access the app at http://localhost:7001/jboss-seam-jpa/
  @@ -32,3 +32,12 @@
     * Deploy build/jboss-seam-jpa.war as Web App
     * Access the app at http://localhost:8080/jboss-seam-jpa/
   
  +NOTES TO GLASSFISH:
  +  In order for the app to work out of the box with Glassfish, we have
  +  used the Derby (i.e., Java DB) database in Glassfish. However,
  +  we strongly recommend you to use a non-Derby data source (e.g., HSQL
  +  is a much better embeded DB) if possible. The
  +  WEB/classes/GlassfishDerbyDialect.class is a special hack to get around
  +  a Derby bug in Glassfish TM. You must use it as your Hibernate dialect
  +  if you were to use Derby with Glassfish.
  +
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:56:16 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:56:16 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/resources/glassfish     ...
Message-ID: <E1GqIEq-0005Az-8m@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:56:16

  Modified:    examples/jpa/resources/glassfish     log4j.xml
                        persistence.xml
  Added:       examples/jpa/resources/glassfish    
                        GlassfishDerbyDialect.class import.sql
  Log:
  Make both WL and GF work ...
  
  Revision  Changes    Path
  1.2       +1 -2      jboss-seam/examples/jpa/resources/glassfish/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/glassfish/log4j.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- log4j.xml	30 Nov 2006 06:39:36 -0000	1.1
  +++ log4j.xml	1 Dec 2006 23:56:16 -0000	1.2
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.1 2006/11/30 06:39:36 myuan Exp $ -->
  +<!-- $Id: log4j.xml,v 1.2 2006/12/01 23:56:16 myuan Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -17,7 +17,6 @@
   <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
      
      <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
  -      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
         <param name="Target" value="System.out"/>
   
         <layout class="org.apache.log4j.PatternLayout">
  
  
  
  1.2       +3 -2      jboss-seam/examples/jpa/resources/glassfish/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/glassfish/persistence.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- persistence.xml	30 Nov 2006 06:39:36 -0000	1.1
  +++ persistence.xml	1 Dec 2006 23:56:16 -0000	1.2
  @@ -1,11 +1,12 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<persistence>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  +        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
      <persistence-unit name="bookingDatabase" transaction-type="JTA">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>jdbc/__default</jta-data-source>
         <properties>
             <property name="hibernate.dialect" 
  -                    value="org.hibernate.dialect.DerbyDialect"/>
  +                    value="GlassfishDerbyDialect"/>
            <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
            <property name="hibernate.show_sql" value="true"/>
            <property name="hibernate.cache.provider_class" value="org.hibernate.cache.HashtableCacheProvider"/>
  
  
  
  1.1      date: 2006/12/01 23:56:16;  author: myuan;  state: Exp;jboss-seam/examples/jpa/resources/glassfish/GlassfishDerbyDialect.class
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/01 23:56:16;  author: myuan;  state: Exp;jboss-seam/examples/jpa/resources/glassfish/import.sql
  
  Index: import.sql
  ===================================================================
  insert into Customer (username, password, name) values ('gavin', 'foobar', 'Gavin King')
  insert into Customer (username, password, name) values ('demo', 'demo', 'Demo User')
  insert into Hotel (name, address, city, state, zip, country) values ('Marriott Courtyard', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Doubletree', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('W Hotel', 'Union Square, Manhattan', 'NY', 'NY', '10011', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('W Hotel', 'Lexington Ave, Manhattan', 'NY', 'NY', '10011', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Hotel Rouge', '1315 16th Street NW', 'Washington', 'DC', '20036', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('70 Park Avenue Hotel', '70 Park Avenue', 'NY', 'NY', '10011', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Conrad Miami', '1395 Brickell Ave', 'Miami', 'FL', '33131', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Sea Horse Inn', '2106 N Clairemont Ave', 'Eau Claire', 'WI', '54703', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Super 8 Eau Claire Campus Area', '1151 W Macarthur Ave', 'Eau Claire', 'WI', '54701', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Marriot Downtown', '55 Fourth Street', 'San Francisco', 'CA', '94103', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Hilton Diagonal Mar', 'Passeig del Taulat 262-264', 'Barcelona', 'Catalunya', '08019', 'Spain')
  insert into Hotel (name, address, city, state, zip, country) values ('Hilton Tel Aviv', 'Independence Park', 'Tel Aviv', '', '63405', 'Israel')
  insert into Hotel (name, address, city, state, zip, country) values ('InterContinental Tokyo Bay', 'Takeshiba Pier', 'Tokyo', '', '105', 'Japan')
  insert into Hotel (name, address, city, state, zip, country) values ('Hotel Beaulac', ' Esplanade L?opold-Robert 2', 'Neuchatel', '', '2000', 'Switzerland')
  insert into Hotel (name, address, city, state, zip, country) values ('Conrad Treasury Place', 'William & George Streets', 'Brisbane', 'QLD', '4001', 'Australia')
  insert into Hotel (name, address, city, state, zip, country) values ('Ritz Carlton', '1228 Sherbrooke St', 'West Montreal', 'Quebec', 'H3G1H6', 'Canada')
  insert into Hotel (name, address, city, state, zip, country) values ('Ritz Carlton', 'Peachtree Rd, Buckhead', 'Atlanta', 'GA', '30326', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Swissotel', '68 Market Street', 'Sydney', 'NSW', '2000', 'Australia')
  insert into Hotel (name, address, city, state, zip, country) values ('Meli? White House', 'Albany Street', 'Regents Park London', '', 'NW13UP', 'Great Britain')
  insert into Hotel (name, address, city, state, zip, country) values ('Hotel Allegro', '171 West Randolph Street', 'Chicago', 'IL', '60601', 'USA')
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:57:22 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:57:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2   ...
Message-ID: <E1GqIFu-0005CS-NJ@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:57:22

  Modified:    examples/hibernate2   build.xml readme.txt
  Log:
  make WL and GF both work ...
  
  Revision  Changes    Path
  1.6       +4 -1      jboss-seam/examples/hibernate2/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/build.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- build.xml	30 Nov 2006 04:43:15 -0000	1.5
  +++ build.xml	1 Dec 2006 23:57:22 -0000	1.6
  @@ -207,9 +207,11 @@
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  +      <!--
         <lib dir="${applib}/mc">
           <include name="*.jar" />
         </lib>
  +      -->
         <lib dir="${lib}">
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
  @@ -239,10 +241,10 @@
         </fileset>
         <fileset dir="${resources}">
           <include name="seam.properties" />
  -        <include name="import.sql" />
         </fileset>
         <fileset dir="${resources}/glassfish">
           <include name="hibernate.cfg.xml" />
  +        <include name="import.sql" />
         </fileset>
       </jar>
       
  @@ -280,6 +282,7 @@
         </lib>
         <classes dir="${resources}/glassfish">
           <include name="log4j.xml" />
  +        <include name="GlassfishDerbyDialect.class" />
         </classes>
         <fileset dir="${view}"/>
       </war>
  
  
  
  1.2       +10 -2     jboss-seam/examples/hibernate2/readme.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: readme.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/readme.txt,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- readme.txt	30 Nov 2006 04:43:15 -0000	1.1
  +++ readme.txt	1 Dec 2006 23:57:22 -0000	1.2
  @@ -2,7 +2,7 @@
   It can be deployed in JBoss AS 4.x, WebLogic, Glassfish, Tomcat without
   the EJB3 container.
   
  -JBoss AS 4.0.5 (no EJB3):
  +JBoss AS 4.0.5 (with or without EJB3):
     * Install JBoss AS 4.0.5 with the default J2EE profile
     * ant jboss
     * Deploy build/jboss-seam-hibernate.war
  @@ -12,7 +12,7 @@
   WebLogic 9.2:
     * Install WebLogic 9.2
     * ant weblogic
  -  * Start WebLogic
  +  * Start the WebLogic "examples" server
     * Load the admin console http://localhost:7001/console/
     * Deploy build/jboss-seam-hibernate.war
     * Access the app at http://localhost:7001/jboss-seam-hibernate/
  @@ -32,3 +32,11 @@
     * Deploy build/jboss-seam-hibernate.war as Web App
     * Access the app at http://localhost:8080/jboss-seam-hibernate/
   
  +NOTES TO GLASSFISH:
  +  In order for the app to work out of the box with Glassfish, we have
  +  used the Derby (i.e., Java DB) database in Glassfish. However,
  +  we strongly recommend you to use a non-Derby data source (e.g., HSQL
  +  is a much better embeded DB) if possible. The 
  +  WEB/classes/GlassfishDerbyDialect.class is a special hack to get around 
  +  a Derby bug in Glassfish TM. You must use it as your Hibernate dialect
  +  if you were to use Derby with Glassfish.
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:57:22 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:57:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/glassfish ...
Message-ID: <E1GqIFu-0005Ch-RW@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:57:22

  Modified:    examples/hibernate2/resources/glassfish    
                        hibernate.cfg.xml log4j.xml
  Added:       examples/hibernate2/resources/glassfish    
                        GlassfishDerbyDialect.class import.sql
  Log:
  make WL and GF both work ...
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/examples/hibernate2/resources/glassfish/hibernate.cfg.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: hibernate.cfg.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/glassfish/hibernate.cfg.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- hibernate.cfg.xml	30 Nov 2006 04:43:15 -0000	1.1
  +++ hibernate.cfg.xml	1 Dec 2006 23:57:22 -0000	1.2
  @@ -10,7 +10,7 @@
           <property name="transaction.flush_before_completion">true</property>
           <property name="connection.release_mode">after_statement</property>
           <property name="cache.provider_class">org.hibernate.cache.HashtableCacheProvider</property>
  -        <property name="dialect">org.hibernate.dialect.DerbyDialect</property>
  +        <property name="dialect">GlassfishDerbyDialect</property>
           <property name="transaction.manager_lookup_class">org.hibernate.transaction.SunONETransactionManagerLookup</property>
           <property name="transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</property>
           <mapping class="org.jboss.seam.example.hibernate.Hotel"/>
  
  
  
  1.2       +1 -2      jboss-seam/examples/hibernate2/resources/glassfish/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/glassfish/log4j.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- log4j.xml	30 Nov 2006 04:43:15 -0000	1.1
  +++ log4j.xml	1 Dec 2006 23:57:22 -0000	1.2
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.1 2006/11/30 04:43:15 myuan Exp $ -->
  +<!-- $Id: log4j.xml,v 1.2 2006/12/01 23:57:22 myuan Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -17,7 +17,6 @@
   <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
      
      <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
  -      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
         <param name="Target" value="System.out"/>
   
         <layout class="org.apache.log4j.PatternLayout">
  
  
  
  1.1      date: 2006/12/01 23:57:22;  author: myuan;  state: Exp;jboss-seam/examples/hibernate2/resources/glassfish/GlassfishDerbyDialect.class
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/01 23:57:22;  author: myuan;  state: Exp;jboss-seam/examples/hibernate2/resources/glassfish/import.sql
  
  Index: import.sql
  ===================================================================
  insert into Customer (username, password, name) values ('gavin', 'foobar', 'Gavin King')
  insert into Customer (username, password, name) values ('demo', 'demo', 'Demo User')
  insert into Hotel (name, address, city, state, zip, country) values ('Marriott Courtyard', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Doubletree', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('W Hotel', 'Union Square, Manhattan', 'NY', 'NY', '10011', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('W Hotel', 'Lexington Ave, Manhattan', 'NY', 'NY', '10011', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Hotel Rouge', '1315 16th Street NW', 'Washington', 'DC', '20036', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('70 Park Avenue Hotel', '70 Park Avenue', 'NY', 'NY', '10011', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Conrad Miami', '1395 Brickell Ave', 'Miami', 'FL', '33131', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Sea Horse Inn', '2106 N Clairemont Ave', 'Eau Claire', 'WI', '54703', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Super 8 Eau Claire Campus Area', '1151 W Macarthur Ave', 'Eau Claire', 'WI', '54701', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Marriot Downtown', '55 Fourth Street', 'San Francisco', 'CA', '94103', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Hilton Diagonal Mar', 'Passeig del Taulat 262-264', 'Barcelona', 'Catalunya', '08019', 'Spain')
  insert into Hotel (name, address, city, state, zip, country) values ('Hilton Tel Aviv', 'Independence Park', 'Tel Aviv', '', '63405', 'Israel')
  insert into Hotel (name, address, city, state, zip, country) values ('InterContinental Tokyo Bay', 'Takeshiba Pier', 'Tokyo', '', '105', 'Japan')
  insert into Hotel (name, address, city, state, zip, country) values ('Hotel Beaulac', ' Esplanade L?opold-Robert 2', 'Neuchatel', '', '2000', 'Switzerland')
  insert into Hotel (name, address, city, state, zip, country) values ('Conrad Treasury Place', 'William & George Streets', 'Brisbane', 'QLD', '4001', 'Australia')
  insert into Hotel (name, address, city, state, zip, country) values ('Ritz Carlton', '1228 Sherbrooke St', 'West Montreal', 'Quebec', 'H3G1H6', 'Canada')
  insert into Hotel (name, address, city, state, zip, country) values ('Ritz Carlton', 'Peachtree Rd, Buckhead', 'Atlanta', 'GA', '30326', 'USA')
  insert into Hotel (name, address, city, state, zip, country) values ('Swissotel', '68 Market Street', 'Sydney', 'NSW', '2000', 'Australia')
  insert into Hotel (name, address, city, state, zip, country) values ('Meli? White House', 'Albany Street', 'Regents Park London', '', 'NW13UP', 'Great Britain')
  insert into Hotel (name, address, city, state, zip, country) values ('Hotel Allegro', '171 West Randolph Street', 'Chicago', 'IL', '60601', 'USA')
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:57:22 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:57:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/weblogic  ...
Message-ID: <E1GqIFu-0005Co-Vn@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:57:22

  Modified:    examples/hibernate2/resources/weblogic  log4j.xml
  Log:
  make WL and GF both work ...
  
  Revision  Changes    Path
  1.2       +1 -2      jboss-seam/examples/hibernate2/resources/weblogic/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/weblogic/log4j.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- log4j.xml	30 Nov 2006 04:43:15 -0000	1.1
  +++ log4j.xml	1 Dec 2006 23:57:22 -0000	1.2
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.1 2006/11/30 04:43:15 myuan Exp $ -->
  +<!-- $Id: log4j.xml,v 1.2 2006/12/01 23:57:22 myuan Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -17,7 +17,6 @@
   <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
      
      <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
  -      <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
         <param name="Target" value="System.out"/>
   
         <layout class="org.apache.log4j.PatternLayout">
  
  
  


From michael.yuan at jboss.com  Fri Dec  1 18:57:23 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 01 Dec 2006 18:57:23 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/hibernate2/src/org/jboss/seam/example/hibernate
	...
Message-ID: <E1GqIFv-0005Cv-3d@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/01 18:57:23

  Modified:    examples/hibernate2/src/org/jboss/seam/example/hibernate 
                        Booking.java
  Log:
  make WL and GF both work ...
  
  Revision  Changes    Path
  1.3       +2 -2      jboss-seam/examples/hibernate2/src/org/jboss/seam/example/hibernate/Booking.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Booking.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/src/org/jboss/seam/example/hibernate/Booking.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Booking.java	30 Nov 2006 21:03:45 -0000	1.2
  +++ Booking.java	1 Dec 2006 23:57:23 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: Booking.java,v 1.2 2006/11/30 21:03:45 myuan Exp $
  +//$Id: Booking.java,v 1.3 2006/12/01 23:57:23 myuan Exp $
   package org.jboss.seam.example.hibernate;
   
   import java.io.Serializable;
  @@ -44,7 +44,7 @@
         this.user = user;
      }
   
  -   @Id @GeneratedValue(strategy=GenerationType.IDENTITY)
  +   @Id @GeneratedValue
      public Long getId()
      {
         return id;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 19:04:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 19:04:55 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1676 - in
	branches/Branch_Client_Failover_Experiment/src:
	etc/server/default/deploy
	main/org/jboss/jms/server/connectionfactory
Message-ID: <E1GqIND-0005TB-Jb@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-01 19:04:52 -0500 (Fri, 01 Dec 2006)
New Revision: 1676

Modified:
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/connection-factories-service.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
Log:
changing dependencies as explained in
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3990684#3990684

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-01 23:08:04 UTC (rev 1675)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-02 00:04:52 UTC (rev 1676)
@@ -62,7 +62,6 @@
       xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends>jboss.messaging.destination:service=ConnectionFactory</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
       <attribute name="PostOfficeName">Clustered Queue</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
@@ -127,7 +126,6 @@
       xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends>jboss.messaging.destination:service=ConnectionFactory</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
       <attribute name="PostOfficeName">Clustered Topic</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/connection-factories-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/connection-factories-service.xml	2006-12-01 23:08:04 UTC (rev 1675)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/connection-factories-service.xml	2006-12-02 00:04:52 UTC (rev 1676)
@@ -13,6 +13,7 @@
       xmbean-dd="xmdesc/ConnectionFactory-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends optional-attribute-name="Connector">jboss.messaging:service=Connector,transport=socket</depends>
+      <depends>jboss.messaging:service=QueuePostOffice</depends>
 
       <attribute name="JNDIBindings">
          <bindings>

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-01 23:08:04 UTC (rev 1675)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-02 00:04:52 UTC (rev 1676)
@@ -26,11 +26,9 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
-
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
@@ -52,7 +50,7 @@
  *
  * $Id$
  */
-public class ConnectionFactoryJNDIMapper 
+public class ConnectionFactoryJNDIMapper
    implements ConnectionFactoryManager, ReplicationListener
 {
    // Constants -----------------------------------------------------
@@ -82,9 +80,9 @@
    }
    
    // ConnectionFactoryManager implementation -----------------------
-   
-   
-   
+
+
+
    public synchronized void registerConnectionFactory(String uniqueName,
             String clientID,
             JNDIBindings jndiBindings,
@@ -113,9 +111,10 @@
          //First we must replicate the delegate across the cluster so that all the ConnectionFactoryJNDIMapper
          //instances on different nodes have access to the list of local connection factories
          //so they can be added to the clustered connection factory
+
+         getReplicator();
+         replicator.putReplicant(CF_PREFIX + uniqueName, delegate);
          
-         replicator.putReplicant(CF_PREFIX + uniqueName, delegate);         
-         
          //Get the list of delegates
          
          Map replicants = replicator.getReplicants(CF_PREFIX + uniqueName);
@@ -187,8 +186,9 @@
       if (clustered)
       {
          //Remove from replicants
-         
-         replicator.removeReplicant(CF_PREFIX + uniqueName);         
+
+         getReplicator();
+         replicator.removeReplicant(CF_PREFIX + uniqueName);
       }
       
       JMSDispatcher.instance.unregisterTarget(new Integer(endpoint.getID()));
@@ -200,13 +200,19 @@
    {
       initialContext = new InitialContext();
       
+      /*
+
+      ConnectionFActoryJNDIMapper is started in a call of ServerPeer, while replicator is started later
+      when the postoffices are started. So, I'm keeping the registration of replicator lazy on the first connection
+      Allthough this is not a proper design, as we might loose messages when the PostOffice is connected
+
       replicator = serverPeer.getDataReplicator();
-      
+
       if (replicator != null)
       {
          replicator.registerListener(this);
-      }
-      
+      } */
+
       log.debug("started");
    }
    
@@ -317,7 +323,7 @@
          ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)entry.getValue();
          
          delegates[i] = del;
-         
+
          int failoverNode = replicator.getFailoverNodeForNode(nodeId);
          
          nodes[i] = nodeId;
@@ -360,6 +366,21 @@
       
       cf.setFailoverDelegates(delegates, failoverIndexes);
    }
+
+   private Replicator getReplicator() throws Exception
+   {
+      if (replicator==null)
+      {
+         replicator = serverPeer.getDataReplicator();
+
+         if (replicator != null)
+         {
+            replicator.registerListener(this);
+         }
+      }
+      return replicator;
+   }
+
    
    // Inner classes -------------------------------------------------
 }



From gavin.king at jboss.com  Fri Dec  1 19:54:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 19:54:33 -0500
Subject: [jboss-cvs] jboss-seam/src/main/META-INF  ...
Message-ID: <E1GqJ9F-000699-1O@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 19:54:33

  Modified:    src/main/META-INF  components.xml
  Log:
  ProcessInstanceFinder
  
  Revision  Changes    Path
  1.7       +2 -1      jboss-seam/src/main/META-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/META-INF/components.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- components.xml	1 Dec 2006 13:26:18 -0000	1.6
  +++ components.xml	2 Dec 2006 00:54:32 -0000	1.7
  @@ -29,13 +29,14 @@
     <factory scope="stateless" auto-create="true" name="pooledTask" value="#{org.jboss.seam.core.pooledTask}"/>
     <factory scope="stateless" auto-create="true" name="pooledTaskInstanceList" value="#{org.jboss.seam.core.pooledTaskInstanceList}"/>
     <factory scope="stateless" auto-create="true" name="processInstance" value="#{org.jboss.seam.core.processInstance}"/>
  +  <factory scope="stateless" auto-create="true" name="processInstanceFinder" value="#{org.jboss.seam.core.processInstanceFinder}"/>
  +  <factory scope="stateless" auto-create="true" name="processInstanceList" value="#{org.jboss.seam.core.processInstanceList}"/>
     <factory scope="stateless" auto-create="true" name="redirect" value="#{org.jboss.seam.core.redirect}"/>
     <factory scope="stateless" auto-create="true" name="resourceBundle" value="#{org.jboss.seam.core.resourceBundle}"/>
     <factory scope="stateless" auto-create="true" name="sessionContext" value="#{org.jboss.seam.core.sessionContext}"/>
     <factory scope="stateless" auto-create="true" name="switcher" value="#{org.jboss.seam.core.switcher}"/>
     <factory scope="stateless" auto-create="true" name="taskInstance" value="#{org.jboss.seam.core.taskInstance}"/>
     <factory scope="stateless" auto-create="true" name="taskInstanceList" value="#{org.jboss.seam.core.taskInstanceList}"/>
  -  <factory scope="stateless" auto-create="true" name="processInstanceList" value="#{org.jboss.seam.core.processInstanceList}"/>
     <factory scope="stateless" auto-create="true" name="taskInstanceListForType" value="#{org.jboss.seam.core.taskInstanceListForType}"/>
     <factory scope="stateless" auto-create="true" name="timeZone" value="#{org.jboss.seam.core.timeZone}"/>
     <factory scope="stateless" auto-create="true" name="timeZoneSelector" value="#{org.jboss.seam.core.timeZoneSelector}"/>
  
  
  


From gavin.king at jboss.com  Fri Dec  1 19:54:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 19:54:33 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GqJ9F-00069G-56@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 19:54:33

  Added:       src/main/org/jboss/seam/core   ProcessInstanceFinder.java
  Removed:     src/main/org/jboss/seam/core   ProcessInstanceList.java
  Log:
  ProcessInstanceFinder
  
  Revision  Changes    Path
  1.1      date: 2006/12/02 00:54:33;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/ProcessInstanceFinder.java
  
  Index: ProcessInstanceFinder.java
  ===================================================================
  package org.jboss.seam.core;
  
  import static org.hibernate.criterion.Order.asc;
  import static org.hibernate.criterion.Order.desc;
  import static org.hibernate.criterion.Restrictions.isNotNull;
  import static org.hibernate.criterion.Restrictions.isNull;
  import static org.jboss.seam.annotations.Install.BUILT_IN;
  
  import java.util.List;
  
  import org.hibernate.Criteria;
  import org.hibernate.criterion.Restrictions;
  import org.jboss.seam.annotations.Factory;
  import org.jboss.seam.annotations.Install;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Transactional;
  import org.jbpm.graph.exe.ProcessInstance;
  
  /**
   * Support for the process list.
   * 
   * @author Gavin King
   */
  @Name("org.jboss.seam.core.processInstanceFinder")
  @Install(precedence=BUILT_IN, dependencies="org.jboss.seam.core.jbpm")
  public class ProcessInstanceFinder
  {
     
     private String processDefinitionName;
     private String nodeName;
     private Boolean processInstanceEnded = false;
     private Boolean sortDescending = false;
     
     @Factory("org.jboss.seam.core.processInstanceList")
     @Transactional
     public List<ProcessInstance> getProcessInstanceList()
     {
        Criteria query = ManagedJbpmContext.instance().getSession()
                    .createCriteria(ProcessInstance.class);
        if ( processInstanceEnded!=null )
        {
           query.add( processInstanceEnded ? isNotNull("end") : isNull("end") );
        }
        
        if (processDefinitionName!=null)
        {
           query.createCriteria("processDefinition")
                 .add( Restrictions.eq("name", processDefinitionName) );
        }
        
        query = query.createCriteria("rootToken");
        if (sortDescending!=null)
        {
           query.addOrder( sortDescending ? desc("nodeEnter") : asc("nodeEnter") );
        }
        if (nodeName!=null)
        {
           query.createCriteria("node")
                 .add( Restrictions.eq("name", nodeName) );
        }
        
        return query.list();
     }
  
     protected String getNodeName()
     {
        return nodeName;
     }
  
     protected void setNodeName(String nodeName)
     {
        this.nodeName = nodeName;
     }
  
     protected String getProcessDefinitionName()
     {
        return processDefinitionName;
     }
  
     protected void setProcessDefinitionName(String processDefinitionName)
     {
        this.processDefinitionName = processDefinitionName;
     }
  
     protected Boolean isSortDescending()
     {
        return sortDescending;
     }
  
     protected void setSortDescending(Boolean sortDescending)
     {
        this.sortDescending = sortDescending;
     }
  
     protected Boolean getProcessInstanceEnded()
     {
        return processInstanceEnded;
     }
  
     protected void setProcessInstanceEnded(Boolean ended)
     {
        this.processInstanceEnded = ended;
     }
     
  }
  
  
  


From gavin.king at jboss.com  Fri Dec  1 19:56:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 19:56:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources  ...
Message-ID: <E1GqJBF-0006CI-3C@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 19:56:37

  Modified:    examples/dvdstore/resources  hibernate.cfg.xml
  Log:
  show the sql
  
  Revision  Changes    Path
  1.6       +1 -1      jboss-seam/examples/dvdstore/resources/hibernate.cfg.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: hibernate.cfg.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/hibernate.cfg.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- hibernate.cfg.xml	19 Apr 2006 02:56:25 -0000	1.5
  +++ hibernate.cfg.xml	2 Dec 2006 00:56:37 -0000	1.6
  @@ -7,7 +7,7 @@
   <hibernate-configuration>
     <session-factory>
   
  -    <property name="show_sql">false</property>
  +    <property name="show_sql">true</property>
       <property name="connection.datasource">java:/dvdDatasource</property>
       <property name="transaction.factory_class">org.hibernate.transaction.JTATransactionFactory</property>
       <property name="transaction.manager_lookup_class">org.hibernate.transaction.JBossTransactionManagerLookup</property>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 20:03:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 20:03:23 -0500
Subject: [jboss-cvs] JBossAS SVN: r58813 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1GqJHn-0006Uv-Aa@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-01 20:03:21 -0500 (Fri, 01 Dec 2006)
New Revision: 58813

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java
Log:
- Port Scott's patch for UserTransaction support.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java	2006-12-01 22:07:36 UTC (rev 58812)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java	2006-12-02 01:03:21 UTC (rev 58813)
@@ -44,6 +44,7 @@
 import javax.management.ObjectName;
 import javax.naming.Context;
 import javax.naming.InitialContext;
+import javax.naming.LinkRef;
 
 import org.apache.catalina.LifecycleListener;
 import org.apache.catalina.Loader;
@@ -54,6 +55,7 @@
 import org.jboss.logging.Logger;
 import org.jboss.metadata.WebMetaData;
 import org.jboss.mx.util.MBeanServerLocator;
+import org.jboss.naming.NonSerializableFactory;
 import org.jboss.security.AuthorizationManager;
 import org.jboss.security.authorization.PolicyRegistration;
 import org.jboss.virtual.VirtualFile;
@@ -332,6 +334,27 @@
             metaData.setENCLoader(webLoader.getClassLoader());
             InitialContext iniCtx = new InitialContext();
             Context envCtx = (Context) iniCtx.lookup("java:comp");
+            // Add ORB/UserTransaction
+            ORB orb = null;
+            try
+            {
+               ObjectName ORB_NAME = new ObjectName("jboss:service=CorbaORB");
+               orb = (ORB) server.getAttribute(ORB_NAME, "ORB");
+               // Bind the orb
+               if (orb != null)
+               {
+                  NonSerializableFactory.rebind(envCtx, "ORB", orb);
+                  log.debug("Bound java:comp/ORB");
+               }
+            }
+            catch (Throwable t)
+            {
+               log.debug("Unable to retrieve orb" + t.toString());
+            }
+
+            // TODO: injection, Add a link to the global transaction manager
+            envCtx.bind("UserTransaction", new LinkRef("UserTransaction"));
+            log.debug("Linked java:comp/UserTransaction to JNDI name: UserTransaction");
             envCtx = envCtx.createSubcontext("env");
             injectionContainer.populateEnc(webLoader.getClassLoader());
             // TODO: this should be bindings in the metadata



From gavin.king at jboss.com  Fri Dec  1 21:15:43 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:15:43 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1GqKPn-0007fl-H3@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:15:43

  Modified:    seam-gen/resources/META-INF  persistence.xml
  Log:
  JBSEAM-552
  
  Revision  Changes    Path
  1.5       +3 -1      jboss-seam/seam-gen/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/persistence.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- persistence.xml	8 Nov 2006 04:50:29 -0000	1.4
  +++ persistence.xml	2 Dec 2006 02:15:43 -0000	1.5
  @@ -1,4 +1,6 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  +        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">>
   	<persistence-unit name="@projectName@">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/@projectName at Datasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:15:44 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:15:44 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/WEB-INF    ...
Message-ID: <E1GqKPo-0007fy-JY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:15:44

  Modified:    seam-gen/resources/WEB-INF    components.xml
                        faces-config.xml navigation.xml
  Log:
  JBSEAM-552
  
  Revision  Changes    Path
  1.5       +20 -30    jboss-seam/seam-gen/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/components.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- components.xml	10 Nov 2006 19:24:22 -0000	1.4
  +++ components.xml	2 Dec 2006 02:15:44 -0000	1.5
  @@ -1,41 +1,31 @@
  -<?xml version="1.0" ?>
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  -
  -<components>
  -
  -    <component name="org.jboss.seam.core.init">
  -        <property name="debug">true</property>
  -        <property name="jndiPattern">@jndiPattern@</property>
  -    </component>    
  -     
  -    <component name="org.jboss.seam.core.manager">
  -        <!-- half second wait for conversation lock on concurrent requests -->
  -        <property name="concurrentRequestTimeout">500</property>
  -        <!-- 120 second conversation timeout -->
  -        <property name="conversationTimeout">120000</property>
  -        <property name="conversationIdParameter">cid</property>
  -        <property name="conversationIsLongRunningParameter">clr</property>
  -    </component>
  -    
  -    <component name="org.jboss.seam.core.pages">
  -        <property name="noConversationViewId">/home.xhtml</property>
  -    </component>
  -    
  -    <component name="entityManager"
  -            class="org.jboss.seam.core.ManagedPersistenceContext">
  -        <property name="persistenceUnitJndiName">java:/@projectName at EntityManagerFactory</property>
  -    </component>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
  +
  +    <core:init debug="true" jndi-pattern="@jndiPattern@"/>
  +     
  +    <core:manager concurrent-request-timeout="500" 
  +                  conversation-timeout="120000" 
  +                  conversation-id-parameter="cid" 
  +                  conversation-is-long-running-parameter="clr"/>
   
  -    <component class="org.jboss.seam.core.Ejb" installed="@embeddedEjb@"/>
  +    <core:pages no-conversation-view-id="/home.xhtml"/>
  +    
  +    <core:managed-persistence-context name="entityManager"
  +            persistence-unit-jndi-name="java:/@projectName at EntityManagerFactory"/>
  +
  +    <core:ejb installed="@embeddedEjb@"/>
       
       <!-- For use with jBPM pageflow or process management -->
       <!--  
  -    <component class="org.jboss.seam.core.Jbpm">
  -        <property name="processDefinitions"></property>
  -        <property name="pageflowDefinitions"></property>
  -    </component>
  +    <core:jbpm>
  +        <core:process-definitions></core:process-definitions>
  +        <core:pageflow-definitions></core:pageflow-definitions>
  +    </core:jbpm>
     -->
         
   </components>
  \ No newline at end of file
  
  
  
  1.5       +3 -4      jboss-seam/seam-gen/resources/WEB-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/faces-config.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- faces-config.xml	4 Nov 2006 02:32:38 -0000	1.4
  +++ faces-config.xml	2 Dec 2006 02:15:44 -0000	1.5
  @@ -1,5 +1,4 @@
   <?xml version='1.0' encoding='UTF-8'?>
  -
   <!DOCTYPE faces-config PUBLIC
     "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
     "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
  @@ -8,7 +7,7 @@
   
       <application>
           <message-bundle>messages</message-bundle>
  -        <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
  +        <view-handler>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</view-handler>
       </application>
   
       <!-- Seam transaction management -->
  
  
  
  1.2       +2 -3      jboss-seam/seam-gen/resources/WEB-INF/navigation.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: navigation.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/navigation.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- navigation.xml	2 Nov 2006 22:34:20 -0000	1.1
  +++ navigation.xml	2 Dec 2006 02:15:44 -0000	1.2
  @@ -1,5 +1,4 @@
   <?xml version='1.0' encoding='UTF-8'?>
  -
   <!DOCTYPE faces-config PUBLIC
     "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
     "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 21:23:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 21:23:04 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1677 -
	branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GqKWu-0007ov-6B@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-01 21:23:02 -0500 (Fri, 01 Dec 2006)
New Revision: 1677

Modified:
   branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XATest.java
Log:
correct transaction handling and run against JBossTS. Tx termination should be invoked on the TM, instead of the TX, to ensure correct thread disassociation

Modified: branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-02 00:04:52 UTC (rev 1676)
+++ branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-02 02:23:02 UTC (rev 1677)
@@ -42,7 +42,7 @@
 import org.jboss.jms.tx.MessagingXAResource;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.tm.TransactionManagerLocator;
+import org.jboss.tm.TxUtils;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -86,7 +86,7 @@
             
       if (!ServerManagement.isRemote())
       {
-         tm = TransactionManagerLocator.getInstance().locate();
+         tm = org.jboss.test.messaging.util.TransactionManagerLocator.getInstance().locate();
       }
 
       ServerManagement.undeployQueue("Queue");
@@ -106,11 +106,17 @@
       
       if (!ServerManagement.isRemote())
       {
-         if (tm.getTransaction() != null)
+         if (TxUtils.isUncommitted(tm))
          {
             //roll it back
             tm.rollback();
          }
+         if (tm.getTransaction() != null)
+         {
+            Transaction tx = tm.suspend();
+            if (tx != null)
+               log.warn("Transaction still associated with thread " + tx + " at status " + TxUtils.getStatusAsString(tx.getStatus()));
+         }
       }
       
       if (suspendedTx != null)
@@ -159,7 +165,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
          
-         tx.commit();
+         tm.commit();
          
          conn2 = cf.createConnection();
          conn2.start();
@@ -221,7 +227,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
 
-         tx.commit();
+         tm.commit();
 
          conn2 = cf.createConnection();
          conn2.start();
@@ -279,7 +285,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
 
-         tx.rollback();
+         tm.rollback();
 
          conn2 = cf.createConnection();
          conn2.start();
@@ -340,7 +346,9 @@
 
          try
          {
-            tx.commit();
+            tm.commit();
+
+            fail("should not get here");
          }
          catch (Exception e)
          {
@@ -399,7 +407,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
 
-         tx.rollback();
+         tm.rollback();
 
          conn2 = cf.createConnection();
          conn2.start();
@@ -469,7 +477,7 @@
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
-         tx.commit();
+         tm.commit();
 
          //New tx
          tm.begin();
@@ -545,7 +553,7 @@
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
-         tx.commit();
+         tm.commit();
 
          //New tx
          tm.begin();
@@ -620,7 +628,7 @@
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
-         tx.rollback();
+         tm.rollback();
 
          //Message should be redelivered
 
@@ -700,7 +708,7 @@
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
-         tx.rollback();
+         tm.rollback();
 
          //Message should be redelivered
 
@@ -766,7 +774,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
 
-         tx.commit();
+         tm.commit();
 
          conn2 = cf.createConnection();
          conn2.start();
@@ -819,7 +827,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
 
-         tx.rollback();
+         tm.rollback();
 
          conn2 = cf.createConnection();
          conn2.start();
@@ -883,7 +891,7 @@
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
-         tx.commit();
+         tm.commit();
 
          //New tx
          tm.begin();
@@ -954,7 +962,7 @@
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
-         tx.rollback();
+         tm.rollback();
 
          //Message should be redelivered
 
@@ -1044,7 +1052,7 @@
          assertEquals("jellyfish2", r2.getText());
 
          //commit
-         tx.commit();
+         tm.commit();
 
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
@@ -1122,7 +1130,7 @@
          assertEquals("jellyfish2", r2.getText());
 
          //commit
-         tx.commit();
+         tm.commit();
 
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
@@ -1216,7 +1224,7 @@
 
          //rollback
 
-         tx.rollback();
+         tm.rollback();
 
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
@@ -1323,7 +1331,7 @@
 
          cons2.close();
 
-         tx.rollback();
+         tm.rollback();
 
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
@@ -1433,7 +1441,8 @@
          //which should cause rollback to be called on the other resource
          try
          {
-            tx.commit();
+            tm.commit();
+            fail("should not get here");
          }
          catch (Exception e)
          {
@@ -1513,7 +1522,7 @@
          prod2.send(sess2.createTextMessage("echidna2"));
 
          //commit
-         tx.commit();
+         tm.commit();
 
          //Messages should be in queue
 
@@ -1585,7 +1594,7 @@
          prod2.send(sess2.createTextMessage("echidna2"));
 
          //commit
-         tx.commit();
+         tm.commit();
 
          //Messages should be in queue
 
@@ -1656,7 +1665,7 @@
          prod2.send(sess2.createTextMessage("echidna2"));
 
          //rollback
-         tx.rollback();
+         tm.rollback();
 
          //Messages should not be in queue
 
@@ -1722,7 +1731,7 @@
          prod2.send(sess2.createTextMessage("echidna2"));
 
          //rollback
-         tx.rollback();
+         tm.rollback();
 
          //Messages should not be in queue
 
@@ -1805,7 +1814,7 @@
          assertEquals("jellyfish2", r2.getText());
 
          //commit this transaction
-         tx2.commit();
+         tm.commit();
 
          //verify that no messages are available
          conn2 = cf.createConnection();
@@ -1817,7 +1826,7 @@
 
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
+         tm.commit();
 
 
       }
@@ -1892,7 +1901,7 @@
          cons1.close();
 
          //rollback this transaction
-         tx2.rollback();
+         tm.rollback();
 
          //verify that second message is available
          conn2 = cf.createConnection();
@@ -1910,7 +1919,7 @@
 
          //rollback the other tx
          tm.resume(suspended);
-         suspended.rollback();
+         tm.rollback();
 
          //Verify the first message is now available
          r3 = (TextMessage)cons.receive(1000);
@@ -1976,7 +1985,7 @@
          prod1.send(sess1.createTextMessage("kangaroo2"));
 
          //commit this transaction
-         tx2.commit();
+         tm.commit();
 
          //verify only kangaroo2 message is sent
          conn2 = cf.createConnection();
@@ -1991,7 +2000,7 @@
 
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
+         tm.commit();
 
          //verify that the first text message is received
          TextMessage r3 = (TextMessage)cons.receive(1000);
@@ -2055,7 +2064,7 @@
          prod1.send(sess1.createTextMessage("kangaroo2"));
 
          //rollback this transaction
-         tx2.rollback();
+         tm.rollback();
 
          //verify no messages are sent
          conn2 = cf.createConnection();
@@ -2069,7 +2078,7 @@
 
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
+         tm.commit();
 
          //verify that the first text message is received
          TextMessage r3 = (TextMessage)cons.receive(1000);



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 21:24:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 21:24:06 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1678 -
	branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GqKXu-0007pE-8J@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-01 21:24:04 -0500 (Fri, 01 Dec 2006)
New Revision: 1678

Modified:
   branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
Log:
run the mock coordinator test using JbossTS XID implementation

Modified: branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-02 02:23:02 UTC (rev 1677)
+++ branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-02 02:24:04 UTC (rev 1678)
@@ -31,6 +31,7 @@
 import javax.jms.XASession;
 import javax.naming.InitialContext;
 import javax.transaction.TransactionManager;
+import javax.transaction.UserTransaction;
 import javax.transaction.xa.XAResource;
 import javax.transaction.xa.Xid;
 
@@ -40,6 +41,9 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.util.TransactionManagerLocator;
 
+import com.arjuna.ats.jta.xa.XidImple;
+import com.arjuna.ats.arjuna.common.Uid;
+
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
@@ -96,7 +100,7 @@
 
    // Public --------------------------------------------------------
    
-   /*
+
    public void testJBossTSCoordinator() throws Exception
    {
       UserTransaction ut = com.arjuna.ats.jta.UserTransaction.userTransaction();
@@ -106,8 +110,8 @@
 
       ut.commit();
    }
-   */
 
+
    public void testMockCoordinatorRecovery() throws Exception
    {
 
@@ -200,5 +204,196 @@
    }
 
 
+   public void testMockCoordinatorRecoveryWithJBossTSXids() throws Exception
+   {
+
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImple(new Uid("gbtxid1"), new Uid("bq1"), 123);
+      Xid xid2 = new XidImple(new Uid("gbtxid2"), new Uid("bq2"), 124);
+
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queue);
+
+      TextMessage tm1 = sess1.createTextMessage("testing1");
+
+      prod1.send(tm1);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod2 = sess2.createProducer(queue);
+
+      TextMessage tm2 = sess2.createTextMessage("testing2");
+
+      prod2.send(tm2);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+
+      res.commit(xid1, false);
+
+      res.commit(xid2, false);
+
+      ServerManagement.deployQueue("Queue");
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      MessageConsumer cons = sessRec.createConsumer(queue);
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m1);
+      assertEquals("testing1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m2);
+
+      assertEquals("testing2", m2.getText());
+
+      conn3.close();
+
+   }
+/*
+   public void testMockCoordinatorRecovery3() throws Exception
+   {
+
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queue);
+
+      TextMessage tm1 = sess1.createTextMessage("testing1");
+
+      prod1.send(tm1);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod2 = sess2.createProducer(queue);
+
+      TextMessage tm2 = sess2.createTextMessage("testing2");
+
+      prod2.send(tm2);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+      res.commit(xids[0], false);
+
+      res.commit(xids[1], false);
+
+      ServerManagement.deployQueue("Queue");
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      MessageConsumer cons = sessRec.createConsumer(queue);
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m1);
+      assertEquals("testing1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m2);
+
+      assertEquals("testing2", m2.getText());
+
+      conn3.close();
+
+   }
+*/
+   public void testXidEquals()
+   {
+      Xid xid1 = new XidImple(new Uid("gbtxid1"), new Uid("bq1"), 123);
+      Xid xid2 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+
+      assertEquals(xid1, xid2);
+
+   }
 }
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 21:25:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 21:25:08 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1679 -
	branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/util
Message-ID: <E1GqKYu-0007qP-7m@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-01 21:25:06 -0500 (Fri, 01 Dec 2006)
New Revision: 1679

Modified:
   branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java
Log:
no changes

Modified: branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java
===================================================================
--- branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java	2006-12-02 02:24:04 UTC (rev 1678)
+++ branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java	2006-12-02 02:25:06 UTC (rev 1679)
@@ -53,7 +53,7 @@
          return tm;
 
       tm = com.arjuna.ats.jta.TransactionManager.transactionManager();
-
+      
       return tm;
    }
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 21:26:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 21:26:37 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1680 -
	branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/tx
Message-ID: <E1GqKaL-0007tF-Jv@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-01 21:26:36 -0500 (Fri, 01 Dec 2006)
New Revision: 1680

Modified:
   branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/tx/MessagingXAResource.java
Log:
disallow foreign xid implementations (JBMESSAGING-661)

Modified: branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/tx/MessagingXAResource.java
===================================================================
--- branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/tx/MessagingXAResource.java	2006-12-02 02:25:06 UTC (rev 1679)
+++ branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/tx/MessagingXAResource.java	2006-12-02 02:26:36 UTC (rev 1680)
@@ -28,6 +28,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.tx.XidImpl;
 
 /**
  * An XAResource implementation.
@@ -38,6 +39,7 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * 
  * Parts based on JBoss MQ XAResource implementation by:
  * 
@@ -112,7 +114,12 @@
    public void commit(Xid xid, boolean onePhase) throws XAException
    {
       if (trace) { log.trace(this + " committing " + xid + (onePhase ? " (one phase)" : " (two phase)")); }
-      
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       rm.commit(xid, onePhase, connection);
 
       // leave the session in a 'clean' state, the currentTxId will be set when the XAResource will
@@ -125,6 +132,11 @@
    {
       if (trace) { log.trace(this + " ending " + xid + ", flags: " + flags); }
 
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       synchronized (this)
       {
          switch (flags)
@@ -148,11 +160,22 @@
    public void forget(Xid xid) throws XAException
    {
       if (trace) { log.trace(this + " forgetting " + xid + " (currently an NOOP)"); }
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
    }
 
    public int prepare(Xid xid) throws XAException
    {
       if (trace) { log.trace(this + " preparing " + xid); }
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       return rm.prepare(xid, connection);
    }
 
@@ -167,6 +190,11 @@
    {
       if (trace) { log.trace(this + " rolling back " + xid); }
 
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       // TODO Hmmm on rollback should we also stop and start the consumers to remove any transient
       // messages, like we do on local session rollback??
       
@@ -177,6 +205,11 @@
    {
       if (trace) { log.trace(this + " starting " + xid + ", flags: " + flags); }
       
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       boolean convertTx = false;
       
       if (sessionState.getCurrentTxId() != null)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 21:28:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 21:28:40 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1681 -
	branches/Branch_1_0_XARecovery/src/main/org/jboss/messaging/core/plugin
Message-ID: <E1GqKcK-0007uw-MD@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-01 21:28:38 -0500 (Fri, 01 Dec 2006)
New Revision: 1681

Modified:
   branches/Branch_1_0_XARecovery/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
Log:
no changes

Modified: branches/Branch_1_0_XARecovery/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_1_0_XARecovery/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-02 02:26:36 UTC (rev 1680)
+++ branches/Branch_1_0_XARecovery/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-02 02:28:38 UTC (rev 1681)
@@ -3897,9 +3897,8 @@
          ps.setBytes(2, xid.getBranchQualifier());
          ps.setInt(3, formatID);
          ps.setBytes(4, xid.getGlobalTransactionId());
-         
+
          rows = ps.executeUpdate();
-         
       }
       finally
       {



From gavin.king at jboss.com  Fri Dec  1 21:33:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:33:31 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1GqKh1-00080p-PS@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:33:31

  Modified:    seam-gen  build.xml
  Log:
  auto-add jdbc driver jar to eclipse cp
  
  Revision  Changes    Path
  1.43      +8 -2      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- build.xml	29 Nov 2006 10:02:15 -0000	1.42
  +++ build.xml	2 Dec 2006 02:33:31 -0000	1.43
  @@ -8,6 +8,10 @@
           classname="org.jboss.seam.tool.PackageDirectoryTask" 
           classpath="../jboss-seam-gen.jar"/>
       
  +    <taskdef name="pathFilename" 
  +        classname="org.jboss.seam.tool.PathFilenameTask" 
  +        classpath="../jboss-seam-gen.jar"/>
  +    
       <taskdef name="lowercaseProperty" 
           classname="org.jboss.seam.tool.LowercasePropertyTask" 
           classpath="../jboss-seam-gen.jar"/>
  @@ -32,6 +36,7 @@
       <packageDirectory property="action.dir" package="${action.package}"/>
       <packageDirectory property="model.dir" package="${model.package}"/>
       <packageDirectory property="test.dir" package="${test.package}"/>
  +	<pathFilename property="driver.file" path="${driver.jar}"/>
   	
   	<condition property="hibernate.hbm2ddl.auto" value="update">
   		<equals arg1="${database.exists}" arg2="n"/>
  @@ -55,6 +60,7 @@
           <filter token="projectName" value="${project.name}" />
           <filter token="jbossHome" value="${jboss.home}" />
       	<filter token="hbm2ddl" value="${hibernate.hbm2ddl.auto}"/>
  +    	<filter token="driverJar" value="${driver.file}"/>
       </filterset>
       
       <fileset id="view" dir="${basedir}/view">
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:33:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:33:31 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/build-scripts  ...
Message-ID: <E1GqKh1-00080w-Sd@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:33:31

  Modified:    seam-gen/build-scripts  .classpath
  Log:
  auto-add jdbc driver jar to eclipse cp
  
  Revision  Changes    Path
  1.4       +1 -0      jboss-seam/seam-gen/build-scripts/.classpath
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: .classpath
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build-scripts/.classpath,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- .classpath	8 Nov 2006 03:09:53 -0000	1.3
  +++ .classpath	2 Dec 2006 02:33:31 -0000	1.4
  @@ -28,5 +28,6 @@
   	<classpathentry kind="lib" path="lib/thirdparty-all.jar"/>
   	<classpathentry kind="lib" path="lib/el-api.jar"/>
   	<classpathentry kind="lib" path="lib/el-ri.jar"/>
  +    <classpathentry kind="lib" path="lib/@driverJar@"/>
   	<classpathentry kind="output" path="exploded-archives/@projectName at .jar"/>
   </classpath>
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:33:32 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:33:32 -0500
Subject: [jboss-cvs] jboss-seam/src/gen/org/jboss/seam/tool  ...
Message-ID: <E1GqKh2-000813-3v@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:33:32

  Added:       src/gen/org/jboss/seam/tool  PathFilenameTask.java
  Log:
  auto-add jdbc driver jar to eclipse cp
  
  Revision  Changes    Path
  1.1      date: 2006/12/02 02:33:32;  author: gavin;  state: Exp;jboss-seam/src/gen/org/jboss/seam/tool/PathFilenameTask.java
  
  Index: PathFilenameTask.java
  ===================================================================
  package org.jboss.seam.tool;
  
  import org.apache.tools.ant.BuildException;
  import org.apache.tools.ant.Task;
  
  public class PathFilenameTask extends Task
  {
     private String path;
     private String propertyName;
     
     @Override
     public void execute() throws BuildException
     {
        if ( path!=null && !"".equals(path) )
        {
           int fwdloc = path.lastIndexOf('/');
           int backloc = path.lastIndexOf('\\');
           int loc = fwdloc > backloc ? fwdloc : backloc;
           String filename = loc>=0 ? path.substring(loc) : path;
           getProject().setProperty(propertyName, filename);
        }
     }
  
     public void setPath(String packageName)
     {
        this.path = packageName;
     }
  
     public void setProperty(String propertyName)
     {
        this.propertyName = propertyName;
     }
  }
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:37:15 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:37:15 -0500
Subject: [jboss-cvs] jboss-seam/src/gen/org/jboss/seam/tool  ...
Message-ID: <E1GqKkd-00085w-RY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:37:15

  Modified:    src/gen/org/jboss/seam/tool  PathFilenameTask.java
  Log:
  fix dupe slash
  
  Revision  Changes    Path
  1.2       +2 -2      jboss-seam/src/gen/org/jboss/seam/tool/PathFilenameTask.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PathFilenameTask.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/gen/org/jboss/seam/tool/PathFilenameTask.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- PathFilenameTask.java	2 Dec 2006 02:33:32 -0000	1.1
  +++ PathFilenameTask.java	2 Dec 2006 02:37:15 -0000	1.2
  @@ -15,8 +15,8 @@
         {
            int fwdloc = path.lastIndexOf('/');
            int backloc = path.lastIndexOf('\\');
  -         int loc = fwdloc > backloc ? fwdloc : backloc;
  -         String filename = loc>=0 ? path.substring(loc) : path;
  +         int loc = ( fwdloc > backloc ? fwdloc : backloc ) + 1;
  +         String filename = loc>0 ? path.substring(loc) : path;
            getProject().setProperty(propertyName, filename);
         }
      }
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:40:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:40:10 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/build-scripts  ...
Message-ID: <E1GqKnS-00087a-1w@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:40:10

  Modified:    seam-gen/build-scripts  .classpath
  Log:
  ws
  
  Revision  Changes    Path
  1.5       +1 -1      jboss-seam/seam-gen/build-scripts/.classpath
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: .classpath
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build-scripts/.classpath,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:49:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:49:00 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1GqKw0-0008G2-7a@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:49:00

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  don't show children on create screen
  
  Revision  Changes    Path
  1.8       +20 -18    jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- edit.xhtml.ftl	29 Nov 2006 10:02:15 -0000	1.7
  +++ edit.xhtml.ftl	2 Dec 2006 02:49:00 -0000	1.8
  @@ -121,6 +121,7 @@
   </#if>
   
   <#if c2h.isOneToManyCollection(property)>
  +          <f:subview rendered="${'#'}{${homeName}.managed}">
             <h2>${property.name}</h2>
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
   <#assign childPageName = childPojo.shortName>
  @@ -155,6 +156,7 @@
   	            	    value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
   	            </s:button>
   		    </div>
  +		  </f:subview>
   </#if>
   </#foreach>
       
  
  
  


From gavin.king at jboss.com  Fri Dec  1 21:53:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 01 Dec 2006 21:53:10 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1GqL02-0008Ll-5R@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/01 21:53:10

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  fix Done button on create screen
  
  Revision  Changes    Path
  1.9       +6 -1      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- edit.xhtml.ftl	2 Dec 2006 02:49:00 -0000	1.8
  +++ edit.xhtml.ftl	2 Dec 2006 02:53:10 -0000	1.9
  @@ -79,7 +79,12 @@
                   view="/${masterPageName}.xhtml"/>
               <s:button id="done" value="Done"
                   propagation="end" 
  -                view="/${pageName}.xhtml"/>
  +                view="/${pageName}.xhtml"
  +                rendered="${'#'}{${homeName}.managed}"/>
  +            <s:button id="cancel" value="Cancel"
  +                propagation="end" 
  +                view="/${masterPageName}.xhtml"
  +                rendered="${'#'}{!${homeName}.managed}"/>
           </div>
       </h:form>
       
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 22:43:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 22:43:01 -0500
Subject: [jboss-cvs] JBossAS SVN: r58814 -
	projects/aop/trunk/aop/src/main/org/jboss/aop/advice
Message-ID: <E1GqLmH-0000jn-Mf@committer01.frg.pub.inap.atl.jboss.com>

Author: flaviarnn
Date: 2006-12-01 22:42:57 -0500 (Fri, 01 Dec 2006)
New Revision: 58814

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/PerVmAdvice.java
Log:
[JBAOP-37] Temporary workaround to deal with inverted parameters on around advices.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/PerVmAdvice.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/PerVmAdvice.java	2006-12-02 01:03:21 UTC (rev 58813)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/PerVmAdvice.java	2006-12-02 03:42:57 UTC (rev 58814)
@@ -151,12 +151,23 @@
             invokeBody.append("{  ");
             if (matches.size() > 1)
             {
+               boolean noArg = false;
                for (int i = 0; i < matches.size(); i++)
                {
                   Method advice = (Method) matches.get(i);
-                  String param = advice.getParameterTypes()[0].getName();
-                  invokeBody.append("   if ($1 instanceof " + param + ") return aspectField." + adviceName + "((" + param + ")$1); ");
+                  if (advice.getParameterTypes().length > 0)
+                  {
+                     String param = advice.getParameterTypes()[0].getName();
+                     invokeBody.append("   if ($1 instanceof " + param + ") return aspectField." + adviceName + "((" + param + ")$1); ");
+                  }
+                  else
+                  {
+                     noArg = true;
+                     invokeBody.append("   return aspectField." + adviceName + "(); ");
+                     break;
+                  }
                }
+               if (!noArg)
                invokeBody.append("   return (org.jboss.aop.joinpoint.Invocation)null; ");
             }
             else
@@ -209,7 +220,8 @@
 
       // invoke
       String invokeBody = null;
-      if (Invocation.class.isAssignableFrom(advice.getParameterTypes()[0]))
+      if (advice.getParameterTypes().length > 0 &&
+         Invocation.class.isAssignableFrom(advice.getParameterTypes()[0]))
       {
          invokeBody = getInvocationBody(optimized, advice, method);
       }
@@ -242,7 +254,8 @@
       boolean first = true;
       if (adviceParams.length > 0)
       {
-         int adviceParam = 0;
+      // TODO review this with Kabir
+         /*int adviceParam = 0;
          for (int i = 0; i < params.length && adviceParam < adviceParams.length; i++)
          {
             if (adviceParams[adviceParam].equals(params[i]))
@@ -258,6 +271,35 @@
                }
                invokeBody += "optimized.arg" + i;
             }
+         }*/
+         boolean[] assignedParams = new boolean[params.length];
+         for (int i = 0; i < adviceParams.length; i++)
+         {
+            int j;
+            for (j = 0; j < params.length; j++)
+            {
+               if (adviceParams[i].equals(params[j]) && !assignedParams[j])
+               {
+                  break;
+               }
+            }
+            if (j == params.length)
+            {
+               for (j = 0; j < params.length; j++)
+               {
+                  if (adviceParams[i].isAssignableFrom(params[j]) && !assignedParams[j])
+                     break;
+               }
+               if (j == params.length)
+                  throw new RuntimeException();
+            }
+            assignedParams[j] = true;
+            if (i != 0)
+            {
+               invokeBody += ", ";
+            }
+            invokeBody += "optimized.arg" + j;
+            
          }
       }
       invokeBody += "); ";



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 22:45:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 22:45:15 -0500
Subject: [jboss-cvs] JBossAS SVN: r58815 -
	projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation
Message-ID: <E1GqLoR-0000lU-11@committer01.frg.pub.inap.atl.jboss.com>

Author: flaviarnn
Date: 2006-12-01 22:45:09 -0500 (Fri, 01 Dec 2006)
New Revision: 58815

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java
Log:
[JBAOP-37] Bug on assignability degree of return types solved.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java	2006-12-02 03:42:57 UTC (rev 58814)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java	2006-12-02 03:45:09 UTC (rev 58815)
@@ -200,7 +200,7 @@
     *                         annotation identified by <code>typeIndex</code>;
     *                         {@link AdviceMethodFactory#NOT_ASSIGNABLE_DEGREE} otherwise.
     */
-   public short getReturnAssignabilityDegree(AdviceMethodProperties properties)
+   public final short getReturnAssignabilityDegree(AdviceMethodProperties properties)
    {
       Class returnType = this.method.getReturnType();
       if (returnType == void.class)
@@ -212,7 +212,7 @@
       if (degree == AdviceMethodFactory.NOT_ASSIGNABLE_DEGREE)
       {
          // return type is Object.class and join point return type is not
-         // Object is worse than join point return type, but better than -1
+         // Object is worse than join point return type, but better than NOT_ASSIGNABLE
          return AdviceMethodFactory.MAX_DEGREE;
       }
       return degree;

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java	2006-12-02 03:42:57 UTC (rev 58814)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java	2006-12-02 03:45:09 UTC (rev 58815)
@@ -45,7 +45,7 @@
 public class AdviceMethodFactory
 {
    /**
-    * Rule to be applied for advice return types
+    * Rule to be applied on advice return types
     */
    enum ReturnType {VOID, ANY, NOT_VOID};
    
@@ -402,10 +402,11 @@
       {
          for (AdviceInfo currentAdvice: greatestRank)
          {
-            int currentDegree =  currentAdvice.getReturnAssignabilityDegree(properties);
+            short currentDegree =  currentAdvice.getReturnAssignabilityDegree(properties);
             if (currentDegree < bestDegree)
             {
                bestAdvice = currentAdvice;
+               bestDegree = currentDegree;
             }
          }
          //in case of two or more advices with the same match degree, pick any one of them



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 22:46:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 22:46:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r58816 -
	projects/aop/trunk/aop/src/main/org/jboss/aop/instrument
Message-ID: <E1GqLpT-0000o8-VO@committer01.frg.pub.inap.atl.jboss.com>

Author: flaviarnn
Date: 2006-12-01 22:46:16 -0500 (Fri, 01 Dec 2006)
New Revision: 58816

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java
Log:
[JBAOP-37] Reactivated advice method messages on verbose mode

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java	2006-12-02 03:45:09 UTC (rev 58815)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java	2006-12-02 03:46:16 UTC (rev 58816)
@@ -1463,7 +1463,7 @@
                System.out.print("[warn] No matching advice called '" + setups[i].getAdviceName() + 
                      "' could be found in " + setups[i].getAspectClass().getName() +
                      " for joinpoint " + info + ":");
-//               System.out.println(AdviceMethodFactory.getAdviceMatchingMessage());
+               System.out.println(AdviceMethodFactory.getAdviceMatchingMessage());
             }
          }
          beforeSetups = (beforeAspects == null) ? null : (AdviceSetup[])beforeAspects.toArray(new AdviceSetup[beforeAspects.size()]);



From jboss-cvs-commits at lists.jboss.org  Fri Dec  1 23:09:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 01 Dec 2006 23:09:41 -0500
Subject: [jboss-cvs] JBossAS SVN: r58817 - in projects/aop/trunk/aop/src:
	resources/test/args test/org/jboss/test/aop/args
Message-ID: <E1GqMC5-0001Dq-1O@committer01.frg.pub.inap.atl.jboss.com>

Author: flaviarnn
Date: 2006-12-01 23:09:03 -0500 (Fri, 01 Dec 2006)
New Revision: 58817

Added:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJO.java
Removed:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdvicePOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJOException.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SubValue.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SuperValue.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownTestCase.java
Modified:
   projects/aop/trunk/aop/src/resources/test/args/jboss-aop.xml
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationTestCase.java
Log:
[JBAOP-37] Corrected test errors

Modified: projects/aop/trunk/aop/src/resources/test/args/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/args/jboss-aop.xml	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/resources/test/args/jboss-aop.xml	2006-12-02 04:09:03 UTC (rev 58817)
@@ -2,189 +2,27 @@
 <!DOCTYPE aop SYSTEM "jboss-aop_1_0.dtd">
 
 <aop>
-   <!-- @Invocation test -->
-	<aspect class="org.jboss.test.aop.args.InvocationAspect" scope="PER_VM"/>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.InvocationPOJO->method1(..))">
-    	<before name="before" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-		<advice name="aroundMethodExecution1" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-		<after name="after" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-		<throwing name="throwing" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-   </bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.InvocationPOJO->method2(..))">
-		<advice name="aroundMethodExecution2" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-   </bind>
-	
-	<bind pointcut="get(* org.jboss.test.aop.args.InvocationPOJO->number)">
-		<advice name="aroundFieldRead" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-   </bind>
-
-	<bind pointcut="set(* org.jboss.test.aop.args.InvocationPOJO->number)">
-		<advice name="aroundFieldWrite" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-   </bind>
-   
-   <bind pointcut="call(* org.jboss.test.aop.args.InvocationPOJO->calleeMethod(..)) AND
-      withincode(* org.jboss.test.aop.args.InvocationPOJO->callerMethod(..))">
-		<advice name="aroundMethodCalledByMethod" aspect="org.jboss.test.aop.args.InvocationAspect"/>
-   </bind>
-
-   <!-- @JoinPoint test -->
-	<aspect class="org.jboss.test.aop.args.JoinPointAspect" scope="PER_VM"/>
-
-	<bind pointcut="field(* org.jboss.test.aop.args.JoinPointPOJO->number)">
-		<before name="before1" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-		<after name="after1" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-	<bind pointcut="set(* org.jboss.test.aop.args.JoinPointPOJO->text)">
-		<before name="before2" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-		<after name="after2" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-	<bind pointcut="get(* org.jboss.test.aop.args.JoinPointPOJO->text)">
-		<before name="before5" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-		<after name="after5" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.JoinPointPOJO->method1(..))">
-    	<before name="before3" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-		<after name="after3" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.JoinPointPOJO->method2(..))">
-    	<before name="before4" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-		<after name="after4" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   	<throwing name="throwing1" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-   
-	<bind pointcut="execution(* org.jboss.test.aop.args.JoinPointPOJO->method3(..))">
-   	<throwing name="throwing2" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.JoinPointPOJO->method4(..))">
-   	<throwing name="throwing3" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.JoinPointPOJO->method5(..))">
-   	<throwing name="throwing4" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.JoinPointPOJO->method6(..))">
-   	<throwing name="throwing5" aspect="org.jboss.test.aop.args.JoinPointAspect"/>
-   </bind>
-
-   <!-- Return type and @Return test -->
-	<aspect class="org.jboss.test.aop.args.ReturnAspect" scope="PER_VM"/>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method1(..))">
-		<before name="before" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<advice name="around1" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after1" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method2(..))">
-		<advice name="around2" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-      <after name="after2" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method3(..))">
-		<before name="before" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<advice name="around3" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-      <after name="after3" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method4(..))">
-		<advice name="around4" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after4" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method5(..))">
-		<advice name="around5" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after5" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method6(..))">
-		<advice name="around6" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after6" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method7(..))">
-		<advice name="around7" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after7" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method8(..))">
-		<before name="before" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<advice name="around8" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after8" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method9(..))">
-		<advice name="around9" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after9" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method10(..))">
-		<before name="before" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<advice name="around10" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after10" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ReturnPOJO->method11(..))">
-		<advice name="around11" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-		<after name="after11" aspect="org.jboss.test.aop.args.ReturnAspect"/>
-	</bind>
-
-   <!-- @Thrown test -->
-	<aspect class="org.jboss.test.aop.args.ThrownAspect" scope="PER_VM"/>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ThrownPOJO->method1(..))">
-		<throwing name="throwing1" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-	</bind>
-
-	<bind pointcut="execution(* org.jboss.test.aop.args.ThrownPOJO->method2(..))">
-		<throwing name="throwing2" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-	</bind>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.ThrownPOJO->method3(..))">
-		<throwing name="throwing3" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-	</bind>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.ThrownPOJO->method4(..))">
-		<throwing name="throwing4" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-	</bind>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.ThrownPOJO->method5(..))">
-		<throwing name="throwing5" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-	</bind>
-	
-	<bind pointcut="execution(* org.jboss.test.aop.args.ThrownPOJO->method6(..))">
-		<throwing name="throwing6" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-		<throwing name="throwing7" aspect="org.jboss.test.aop.args.ThrownAspect"/>
-	</bind>
-
    <!-- @Arg test -->
    <aspect class="org.jboss.test.aop.args.ArgAspect" scope="PER_VM"/>
 
-   <bind pointcut="execution(* org.jboss.test.aop.args.ArgPOJO->bunchArgs(..))">
+   <bind pointcut="execution(* org.jboss.test.aop.args.POJO->bunchArgs(..))">
       <advice name="bunchArgs" aspect="org.jboss.test.aop.args.ArgAspect"/>
    </bind>
 
-   <bind pointcut="execution(* org.jboss.test.aop.args.ArgPOJO->bunchArgsWithInvocation(..))">
+   <bind pointcut="execution(* org.jboss.test.aop.args.POJO->bunchArgsWithInvocation(..))">
       <advice name="bunchArgsWithInvocation" aspect="org.jboss.test.aop.args.ArgAspect"/>
    </bind>
 
-   <bind pointcut="execution(* org.jboss.test.aop.args.ArgPOJO->bunchWrapped(..))">
+   <bind pointcut="execution(* org.jboss.test.aop.args.POJO->bunchWrapped(..))">
       <advice name="wrap" aspect="org.jboss.test.aop.args.ArgAspect"/>
    </bind>
 
-   <bind pointcut="execution(* org.jboss.test.aop.args.ArgPOJO->bunch(..))">
+   <bind pointcut="execution(* org.jboss.test.aop.args.POJO->bunch(..))">
       <advice name="bunch" aspect="org.jboss.test.aop.args.ArgAspect"/>
-		<advice name="bunch1" aspect="org.jboss.test.aop.args.ArgAspect"/>
+<!--		<advice name="bunch1" aspect="org.jboss.test.aop.args.ArgAspect"/> -->
       <advice name="bunch2" aspect="org.jboss.test.aop.args.ArgAspect"/>
-      <advice name="bunch3" aspect="org.jboss.test.aop.args.ArgAspect"/>
-      <advice name="bunch4" aspect="org.jboss.test.aop.args.ArgAspect"/>
+<!--      <advice name="bunch3" aspect="org.jboss.test.aop.args.ArgAspect"/>
+      <advice name="bunch4" aspect="org.jboss.test.aop.args.ArgAspect"/> -->
       <advice name="arg1" aspect="org.jboss.test.aop.args.ArgAspect"/>
       <advice name="arg2" aspect="org.jboss.test.aop.args.ArgAspect"/>
       <advice name="arg3" aspect="org.jboss.test.aop.args.ArgAspect"/>
@@ -194,40 +32,35 @@
       <advice name="emptyArg" aspect="org.jboss.test.aop.args.ArgAspect"/>
    </bind>
    
-   <bind pointcut="execution(java.lang.String org.jboss.test.aop.args.ArgPOJO->echo(java.lang.String))">
+   <bind pointcut="execution(java.lang.String org.jboss.test.aop.args.POJO->echo(java.lang.String))">
       <advice name="echo" aspect="org.jboss.test.aop.args.ArgAspect"/>
    </bind>
-   
-   <!-- overloaded advices test -->
-   <aspect class="org.jboss.test.aop.args.OverloadedAdviceAspect" scope="PER_VM"/>
 
-  	<bind pointcut="field(* org.jboss.test.aop.args.OverloadedAdvicePOJO->text)">
-   	<before name="before1" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-      <before name="before2" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before3" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before4" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before5" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before6" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before7" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before8" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before9" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before10" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before11" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<before name="before12" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-  	</bind>
+   <!-- @Invocation test -->
+	<aspect class="org.jboss.test.aop.args.InvocationAspect" scope="PER_VM"/>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.args.POJO->method1(..))">
+<!--    	<before name="before" aspect="org.jboss.test.aop.args.InvocationAspect"/> -->
+		<advice name="aroundMethodExecution1" aspect="org.jboss.test.aop.args.InvocationAspect"/>
+<!--		<after name="after" aspect="org.jboss.test.aop.args.InvocationAspect"/> -->
+<!--		<throwing name="throwing" aspect="org.jboss.test.aop.args.InvocationAspect"/> -->
+   </bind>
+
+<!--	<bind pointcut="execution(* org.jboss.test.aop.args.POJO->method2(..))">
+		<advice name="aroundMethodExecution2" aspect="org.jboss.test.aop.args.InvocationAspect"/>
+   </bind> -->
+	
+	<bind pointcut="get(* org.jboss.test.aop.args.POJO->number)">
+		<advice name="aroundFieldRead" aspect="org.jboss.test.aop.args.InvocationAspect"/>
+   </bind>
+
+	<bind pointcut="set(* org.jboss.test.aop.args.POJO->number)">
+		<advice name="aroundFieldWrite" aspect="org.jboss.test.aop.args.InvocationAspect"/>
+   </bind>
    
-   <bind pointcut="execution(* org.jboss.test.aop.args.OverloadedAdvicePOJO->method(int,long))">
-   	<advice name="around1" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-      <advice name="around2" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around3" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around4" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around5" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around6" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around7" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around8" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around9" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around10" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around11" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-   	<advice name="around12" aspect="org.jboss.test.aop.args.OverloadedAdviceAspect"/>
-  	</bind>  	
+   <bind pointcut="call(* org.jboss.test.aop.args.POJO->calleeMethod(..)) AND
+      withincode(* org.jboss.test.aop.args.POJO->callerMethod(..))">
+		<advice name="aroundMethodCalledByMethod" aspect="org.jboss.test.aop.args.InvocationAspect"/>
+   </bind>
+   
 </aop>
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgPOJO.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgPOJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,56 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.aop.args;
-
-/**
- * Plain old java object used on @Arg parameter tests.
- * 
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision$
- */
-public class ArgPOJO implements ArgPOJOInterface
-{
-   public String echo(String echo)
-   {
-      return echo;
-   }
-
-   public int bunch(int x, double y, float z, String str, int q)
-   {
-      return x + (int) y + (int) z + q;
-   }
-
-   public int bunchArgs(int x, double y, float z, String str, int q)
-   {
-      return x + (int) y + (int) z + q;
-   }
-
-   public int bunchArgsWithInvocation(int x, double y, float z, String str, int q)
-   {
-      return x + (int) y + (int) z + q;
-   }
-
-   public int bunchWrapped(int x, double y, float z, String str, int q)
-   {
-      return x + (int) y + (int) z + q;
-   }
-}
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgTestCase.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgTestCase.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -36,7 +36,7 @@
  */
 public class ArgTestCase extends AOPTestWithSetup
 {
-   ArgPOJO pojo;
+   POJO pojo;
 
    public static void main(String[] args)
    {
@@ -58,7 +58,7 @@
    public void setUp() throws Exception
    {
       super.setUp();
-      pojo = new ArgPOJO();
+      pojo = new POJO();
       ArgAspect.clear();
    }
    

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationAspect.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationAspect.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,3 +1,24 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.args;
 
 import junit.framework.Assert;
@@ -10,7 +31,7 @@
 /**
  * Aspect used on @org.jboss.aop.advice.annotation.Invocation parameter tests.
  * 
- * @author Flavia Rainone
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
  */
 public class InvocationAspect
 {
@@ -23,21 +44,6 @@
       invokeReturn = null;
    }
    
-   public void before(@org.jboss.aop.advice.annotation.Invocation Object object)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void after(@org.jboss.aop.advice.annotation.Invocation Object object)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void throwing(@org.jboss.aop.advice.annotation.Invocation Object object)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-
    public Object aroundMethodExecution1()
    {
       advice = "aroundMethodExecution1";
@@ -67,7 +73,7 @@
       return null;
    }
    
-   public int aroundFieldRead(@org.jboss.aop.advice.annotation.Invocation
+   public Object aroundFieldRead(@org.jboss.aop.advice.annotation.Invocation
          FieldReadInvocation invocation) throws Throwable
    {
       advice = "aroundFieldRead";

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationPOJO.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationPOJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,32 +0,0 @@
-package org.jboss.test.aop.args;
-
-/**
- * Plain old java object used on @org.jboss.aop.advice.annotation.Invocation parameter
- * tests.
- * 
- * @author Flavia Rainone
- */
-public class InvocationPOJO
-{
-   public int number;
-
-   public int callerMethod(int i)
-   {
-      return calleeMethod(i);
-   }
-   
-   private int calleeMethod(int i)
-   {
-      return i*2;
-   }
-   
-   public String method1()
-   {
-      return "method";
-   }
-   
-   public int method2()
-   {
-      return 2;
-   }
-}
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationTestCase.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/InvocationTestCase.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,3 +1,24 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.args;
 
 import org.jboss.test.aop.AOPTestWithSetup;
@@ -9,11 +30,11 @@
 /**
  * Tests the use of @org.jboss.aop.advice.annotation.Invocation parameters.
  * 
- * @author Flavia Rainone
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
  */
 public class InvocationTestCase extends AOPTestWithSetup
 {
-   private InvocationPOJO pojo;
+   private POJO pojo;
    
    public static void main(String[] args)
    {
@@ -36,7 +57,7 @@
    {
       super.setUp();
       InvocationAspect.clear();
-      this.pojo = new InvocationPOJO();
+      this.pojo = new POJO();
    }
    
    public void test1()

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointAspect.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointAspect.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,121 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Assert;
-
-import org.jboss.aop.ConstructorInfo;
-import org.jboss.aop.FieldInfo;
-import org.jboss.aop.JoinPointInfo;
-import org.jboss.aop.MethodInfo;
-import org.jboss.aop.advice.annotation.JoinPoint;
-import org.jboss.aop.advice.annotation.Thrown;
-
-/**
- * Aspect used on @JoinPoint parameter tests.
- * 
- * @author Flavia Rainone
- */
-public class JoinPointAspect
-{
-   static String beforeAdvice = null;
-   static JoinPointInfo beforeJoinPointInfo = null;
-   static String afterAdvice = null;
-   static JoinPointInfo afterJoinPointInfo = null;
-   static String throwingAdvice = null;
-   static JoinPointInfo throwingJoinPointInfo = null;
-   
-   public static void clear()
-   {
-      beforeAdvice = null;
-      beforeJoinPointInfo = null;
-      afterAdvice = null;
-      afterJoinPointInfo = null;
-      throwingAdvice = null;
-      throwingJoinPointInfo = null;
-   }
-   
-   public void before1()
-   {
-      beforeAdvice = "before1";
-   }
-   
-   public void before2(@JoinPoint Object joinPointInfo)
-   {
-      beforeAdvice = "before2";
-      beforeJoinPointInfo = (JoinPointInfo) joinPointInfo;
-   }
-   
-   public void before3(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      beforeAdvice = "before3";
-      beforeJoinPointInfo = joinPointInfo;
-   }   
-   
-   public void before4(@JoinPoint MethodInfo joinPointInfo)
-   {
-      beforeAdvice = "before4";
-      beforeJoinPointInfo = (JoinPointInfo) joinPointInfo;
-   }
-   
-   public void before5(@JoinPoint MethodInfo joinPointInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void after1(@JoinPoint FieldInfo joinPointInfo)
-   {
-      afterAdvice = "after1";
-      afterJoinPointInfo = joinPointInfo;
-   }
-   
-   public void after2(@JoinPoint ConstructorInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void after3()
-   {
-      afterAdvice = "after3";
-   }
-   
-   public void after4(@JoinPoint Object joinPointInfo)
-   {
-      afterAdvice = "after4";
-      afterJoinPointInfo = (JoinPointInfo) joinPointInfo;
-   }
-   
-   public void after5(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      afterAdvice = "after5";
-      afterJoinPointInfo = joinPointInfo;
-   }
-   
-   public void throwing1(@Thrown Throwable throwable, @JoinPoint Object joinPointInfo)
-   {
-      throwingAdvice = "throwing1";
-      throwingJoinPointInfo = (JoinPointInfo) joinPointInfo;
-   }
-   
-   public void throwing2(@JoinPoint ConstructorInfo joinPointInfo,
-         @Thrown Throwable throwable)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void throwing3(@Thrown Throwable throwable,
-         @JoinPoint JoinPointInfo joinPointInfo)
-   {
-      throwingAdvice = "throwing3";
-      throwingJoinPointInfo = joinPointInfo;
-   }
-   
-   public void throwing4(@Thrown Throwable throwable)
-   {
-      throwingAdvice = "throwing4";
-   }
-   
-   public void throwing5(@JoinPoint MethodInfo joinPointInfo, @Thrown Throwable throwable)
-   {
-      throwingAdvice = "throwing5";
-      throwingJoinPointInfo = joinPointInfo;
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointPOJO.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointPOJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,46 +0,0 @@
-package org.jboss.test.aop.args;
-
-/**
- * Plain old java object used on @JoinPoint parameter tests.
- * 
- * @author Flavia Rainone
- */
-public class JoinPointPOJO
-{
-   public int number;
-   public String text;
-   
-   public void method1()
-   {
-      
-   }
-   
-   public String method2(boolean shouldThrow) throws POJOException
-   {
-      if (shouldThrow)
-      {
-         throw new POJOException();
-      }
-      return "method3";
-   }
-   
-   public void method3() throws POJOException
-   {
-      throw new POJOException();
-   }
-   
-   public void method4() throws POJOException
-   {
-      throw new POJOException();
-   }
-   
-   public void method5() throws POJOException
-   {
-      throw new POJOException();
-   }
-   
-   public void method6() throws POJOException
-   {
-      throw new POJOException();
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointTestCase.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointTestCase.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,227 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.aop.FieldInfo;
-import org.jboss.aop.MethodInfo;
-import org.jboss.test.aop.AOPTestWithSetup;
-
-/**
- * Tests the use of @JoinPoint parameters.
- * 
- * @author Flavia Rainone
- */
-public class JoinPointTestCase extends AOPTestWithSetup
-{
-   private JoinPointPOJO pojo;
-   
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("JoinPointTestCase");
-      suite.addTestSuite(JoinPointTestCase.class);
-      return suite;
-   }
-   
-   public JoinPointTestCase(String name)
-   {
-      super(name);
-   }
-   
-   public void setUp() throws Exception
-   {
-      super.setUp();
-      JoinPointAspect.clear();
-      this.pojo = new JoinPointPOJO();
-   }
-   
-   public void test1()
-   {
-      pojo.number = 0;
-      assertEquals("before1", JoinPointAspect.beforeAdvice);
-      assertNull(JoinPointAspect.beforeJoinPointInfo);
-      assertEquals("after1", JoinPointAspect.afterAdvice);
-      assertNotNull(JoinPointAspect.afterJoinPointInfo);
-      assertTrue(JoinPointAspect.afterJoinPointInfo instanceof FieldInfo);
-      FieldInfo fieldInfo = (FieldInfo) JoinPointAspect.afterJoinPointInfo;
-      assertEquals("number", fieldInfo.getAdvisedField().getName());
-      assertFalse(fieldInfo.isRead());
-   }
-   
-   public void test2()
-   {
-      pojo.text = "test2";
-      assertEquals("before2", JoinPointAspect.beforeAdvice);
-      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
-      assertNull(JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      
-      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof FieldInfo);
-      FieldInfo fieldInfo = (FieldInfo) JoinPointAspect.beforeJoinPointInfo;
-      assertEquals("text", fieldInfo.getAdvisedField().getName());
-      assertFalse(fieldInfo.isRead());
-   }
-   
-   public void test3()
-   {
-      String text = pojo.text;
-      assertNull(JoinPointAspect.beforeAdvice);
-      assertNull(JoinPointAspect.beforeJoinPointInfo);
-      assertEquals("after5", JoinPointAspect.afterAdvice);
-      assertNotNull(JoinPointAspect.afterJoinPointInfo);
-      assertTrue(JoinPointAspect.afterJoinPointInfo instanceof FieldInfo);
-      FieldInfo fieldInfo = (FieldInfo) JoinPointAspect.afterJoinPointInfo;
-      assertEquals("text", fieldInfo.getAdvisedField().getName());
-      assertTrue(fieldInfo.isRead());
-   }
-   
-   public void test4()
-   {
-      pojo.method1();
-      assertEquals("before3", JoinPointAspect.beforeAdvice);
-      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
-      assertEquals("after3", JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof MethodInfo);
-      assertEquals("method1", ((MethodInfo) JoinPointAspect.beforeJoinPointInfo).
-            getAdvisedMethod().getName());
-   }
-   
-   public void test5() throws POJOException
-   {
-      pojo.method2(false);
-      assertEquals("before4", JoinPointAspect.beforeAdvice);
-      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
-      assertEquals("after4", JoinPointAspect.afterAdvice);
-      assertNotNull(JoinPointAspect.afterJoinPointInfo);
-      assertNull(JoinPointAspect.throwingAdvice);
-      assertNull(JoinPointAspect.throwingJoinPointInfo);
-      assertSame(JoinPointAspect.beforeJoinPointInfo, JoinPointAspect.afterJoinPointInfo);
-      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof MethodInfo);
-      assertEquals("method2", ((MethodInfo) JoinPointAspect.beforeJoinPointInfo).
-            getAdvisedMethod().getName());
-   }
-   
-   public void test6() throws POJOException
-   {
-      boolean exceptionThrown = false;
-      try
-      {
-         pojo.method2(true);
-      }
-      catch (POJOException e)
-      {
-         exceptionThrown = true;
-      }
-      assertTrue(exceptionThrown);
-      
-      assertEquals("before4", JoinPointAspect.beforeAdvice);
-      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
-      assertNull(JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      assertEquals("throwing1", JoinPointAspect.throwingAdvice);
-      assertNotNull(JoinPointAspect.throwingJoinPointInfo);
-      assertSame(JoinPointAspect.beforeJoinPointInfo,
-            JoinPointAspect.throwingJoinPointInfo);
-      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof MethodInfo);
-      assertEquals("method2", ((MethodInfo) JoinPointAspect.beforeJoinPointInfo).
-            getAdvisedMethod().getName());
-   }
-   
-   public void test7() throws POJOException
-   {
-      boolean exceptionThrown = false;
-      try
-      {
-         pojo.method3();
-      }
-      catch (POJOException e)
-      {
-         exceptionThrown = true;
-      }
-      assertTrue(exceptionThrown);
-      
-      assertNull(JoinPointAspect.beforeAdvice);
-      assertNull(JoinPointAspect.beforeJoinPointInfo);
-      assertNull(JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      assertNull(JoinPointAspect.throwingAdvice);
-      assertNull(JoinPointAspect.throwingJoinPointInfo);
-   }
-   
-   public void test8() throws POJOException
-   {
-      boolean exceptionThrown = false;
-      try
-      {
-         pojo.method4();
-      }
-      catch (POJOException e)
-      {
-         exceptionThrown = true;
-      }
-      assertTrue(exceptionThrown);
-      
-      assertNull(JoinPointAspect.beforeAdvice);
-      assertNull(JoinPointAspect.beforeJoinPointInfo);
-      assertNull(JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      assertEquals("throwing3", JoinPointAspect.throwingAdvice);
-      assertNotNull(JoinPointAspect.throwingJoinPointInfo);
-      assertTrue(JoinPointAspect.throwingJoinPointInfo instanceof MethodInfo);
-      assertEquals("method4", ((MethodInfo) JoinPointAspect.throwingJoinPointInfo).
-            getAdvisedMethod().getName());
-   }
-   
-   public void test9() throws POJOException
-   {
-      boolean exceptionThrown = false;
-      try
-      {
-         pojo.method5();
-      }
-      catch (POJOException e)
-      {
-         exceptionThrown = true;
-      }
-      assertTrue(exceptionThrown);
-      
-      assertNull(JoinPointAspect.beforeAdvice);
-      assertNull(JoinPointAspect.beforeJoinPointInfo);
-      assertNull(JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      assertEquals("throwing4", JoinPointAspect.throwingAdvice);
-      assertNull(JoinPointAspect.throwingJoinPointInfo);
-   }
-   
-   public void test10() throws POJOException
-   {
-      boolean exceptionThrown = false;
-      try
-      {
-         pojo.method6();
-      }
-      catch (POJOException e)
-      {
-         exceptionThrown = true;
-      }
-      assertTrue(exceptionThrown);
-      
-      assertNull(JoinPointAspect.beforeAdvice);
-      assertNull(JoinPointAspect.beforeJoinPointInfo);
-      assertNull(JoinPointAspect.afterAdvice);
-      assertNull(JoinPointAspect.afterJoinPointInfo);
-      assertEquals("throwing5", JoinPointAspect.throwingAdvice);
-      assertNotNull(JoinPointAspect.throwingJoinPointInfo);
-      assertTrue(JoinPointAspect.throwingJoinPointInfo instanceof MethodInfo);
-      assertEquals("method6", ((MethodInfo) JoinPointAspect.throwingJoinPointInfo).
-            getAdvisedMethod().getName());
-
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceAspect.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceAspect.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,1333 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Assert;
-
-import org.jboss.aop.FieldInfo;
-import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.aop.JoinPointInfo;
-import org.jboss.aop.MethodInfo;
-import org.jboss.aop.advice.annotation.Arg;
-import org.jboss.aop.advice.annotation.JoinPoint;
-import org.jboss.aop.joinpoint.ConstructorInvocation;
-import org.jboss.aop.joinpoint.CurrentInvocation;
-import org.jboss.aop.joinpoint.MethodInvocation;
-
-/**
- * Aspect used on overloaded advice tests.
- *
- * @author Flavia Rainone
- */
-public class OverloadedAdviceAspect
-{
-   static String before1 = null;
-   static String before2 = null;
-   static String before3 = null;
-   static String before4 = null;
-   static String before5 = null;
-   static String before6 = null;
-   static String before7 = null;
-   static String before8 = null;
-   static String before9 = null;
-   static String before10 = null;
-   static String before11 = null;
-   static String before12 = null;
-   
-   static String around1 = null;
-   static String around2 = null;
-   static String around3 = null;
-   static String around4 = null;
-   static String around5 = null;
-   static String around6 = null;
-   static String around7 = null;
-   static String around8 = null;
-   static String around9 = null;
-   static String around10 = null;
-   static String around11 = null;
-   static String around12 = null;
-   
-   public static void clear()
-   {
-      before1 = null;
-      before2 = null;
-      before3 = null;
-      before4 = null;
-      before5 = null;
-      before6 = null;
-      before7 = null;
-      before8 = null;
-      before9 = null;
-      before10 = null;
-      before11 = null;
-      before12 = null;
-
-      around1 = null;
-      around2 = null;
-      around3 = null;
-      around4 = null;
-      around5 = null;
-      around6 = null;
-      around7 = null;
-      around8 = null;
-      around9 = null;
-      around10 = null;
-      around11 = null;
-      around12 = null;
-   }
-
-   /* BEFORE ADVICES */
-   
-   public void before1(@JoinPoint FieldInfo joinPointInfo, @Arg String text)
-   {
-      before1 = "FieldInfo,String";
-   }
-
-   public void before1(@JoinPoint FieldInfo joinPointInfo, @Arg Object text)
-   {
-      before1 = "FieldInfo,Object";
-   }
-   
-   public void before1(@JoinPoint JoinPointInfo joinPointInfo, @Arg String text)
-   {
-      before1 = "JoinPointInfo,String";
-   }
-
-   public void before1(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
-   {
-      before1 = "JoinPointInfo,Object";
-   }
-
-   public void before1(@JoinPoint Object joinPointInfo, @Arg String text)
-   {
-      before1 = "Object,String";
-   }
-
-   public void before1(@JoinPoint Object joinPointInfo, @Arg Object text)
-   {
-      before1 = "Object,Object";
-   }
-
-   public void before1(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before1 = "FieldInfo";
-   }
-   
-   public void before1(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before1 = "JoinPointInfo";
-   }
-
-   public void before1(@JoinPoint Object joinPointInfo)
-   {
-      before1 = "Object";
-   }
-   
-   public void before1(@Arg String text)
-   {
-      before1 = "String";
-   }
-      
-   public void before1()
-   {
-      before1 = "";
-   }
-   
-   public void before1(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before1(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before2(@JoinPoint FieldInfo joinPointInfo, @Arg Object text)
-   {
-      before2 = "FieldInfo,Object";
-   }
-   
-   public void before2(@JoinPoint JoinPointInfo joinPointInfo, @Arg String text)
-   {
-      before2 = "JoinPointInfo,String";
-   }
-
-   public void before2(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
-   {
-      before2 = "JoinPointInfo,Object";
-   }
-
-   public void before2(@JoinPoint Object joinPointInfo, @Arg String text)
-   {
-      before2 = "Object,String";
-   }
-
-   public void before2(@JoinPoint Object joinPointInfo, @Arg Object text)
-   {
-      before2 = "Object,Object";
-   }
-
-   public void before2(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before2 = "FieldInfo";
-   }
-   
-   public void before2(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before2 = "JoinPointInfo";
-   }
-
-   public void before2(@JoinPoint Object joinPointInfo)
-   {
-      before2 = "Object";
-   }
-   
-   public void before2(@Arg String text)
-   {
-      before2 = "String";
-   }
-      
-   public void before2()
-   {
-      before2 = "";
-   }
-   
-   public void before2(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before2(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before3(@JoinPoint JoinPointInfo joinPointInfo, @Arg String text)
-   {
-      before3 = "JoinPointInfo,String";
-   }
-
-   public void before3(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
-   {
-      before3 = "JoinPointInfo,Object";
-   }
-
-   public void before3(@JoinPoint Object joinPointInfo, @Arg String text)
-   {
-      before3 = "Object,String";
-   }
-
-   public void before3(@JoinPoint Object joinPointInfo, @Arg Object text)
-   {
-      before3 = "Object,Object";
-   }
-
-   public void before3(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before3 = "FieldInfo";
-   }
-   
-   public void before3(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before3 = "JoinPointInfo";
-   }
-
-   public void before3(@JoinPoint Object joinPointInfo)
-   {
-      before3 = "Object";
-   }
-   
-   public void before3(@Arg String text)
-   {
-      before3 = "String";
-   }
-      
-   public void before3()
-   {
-      before3 = "";
-   }
-   
-   public void before3(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before3(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before4(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
-   {
-      before4 = "JoinPointInfo,Object";
-   }
-
-   public void before4(@JoinPoint Object joinPointInfo, @Arg String text)
-   {
-      before4 = "Object,String";
-   }
-
-   public void before4(@JoinPoint Object joinPointInfo, @Arg Object text)
-   {
-      before4 = "Object,Object";
-   }
-
-   public void before4(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before4 = "FieldInfo";
-   }
-   
-   public void before4(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before4 = "JoinPointInfo";
-   }
-
-   public void before4(@JoinPoint Object joinPointInfo)
-   {
-      before4 = "Object";
-   }
-   
-   public void before4(@Arg String text)
-   {
-      before4 = "String";
-   }
-      
-   public void before4()
-   {
-      before4 = "";
-   }
-   
-   public void before4(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before4(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before5(@JoinPoint Object joinPointInfo, @Arg String text)
-   {
-      before5 = "Object,String";
-   }
-
-   public void before5(@JoinPoint Object joinPointInfo, @Arg Object text)
-   {
-      before5 = "Object,Object";
-   }
-
-   public void before5(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before5 = "FieldInfo";
-   }
-   
-   public void before5(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before5 = "JoinPointInfo";
-   }
-
-   public void before5(@JoinPoint Object joinPointInfo)
-   {
-      before5 = "Object";
-   }
-   
-   public void before5(@Arg String text)
-   {
-      before5 = "String";
-   }
-      
-   public void before5()
-   {
-      before5 = "";
-   }
-   
-   public void before5(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before5(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before6(@JoinPoint Object joinPointInfo, @Arg Object text)
-   {
-      before6 = "Object,Object";
-   }
-
-   public void before6(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before6 = "FieldInfo";
-   }
-   
-   public void before6(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before6 = "JoinPointInfo";
-   }
-
-   public void before6(@JoinPoint Object joinPointInfo)
-   {
-      before6 = "Object";
-   }
-   
-   public void before6(@Arg String text)
-   {
-      before6 = "String";
-   }
-      
-   public void before6()
-   {
-      before6 = "";
-   }
-   
-   public void before6(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before6(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before7(@JoinPoint FieldInfo joinPointInfo)
-   {
-      before7 = "FieldInfo";
-   }
-   
-   public void before7(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before7 = "JoinPointInfo";
-   }
-
-   public void before7(@JoinPoint Object joinPointInfo)
-   {
-      before7 = "Object";
-   }
-   
-   public void before7(@Arg String text)
-   {
-      before7 = "String";
-   }
-      
-   public void before7()
-   {
-      before7 = "";
-   }
-   
-   public void before7(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before7(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before8(@JoinPoint JoinPointInfo joinPointInfo)
-   {
-      before8 = "JoinPointInfo";
-   }
-
-   public void before8(@JoinPoint Object joinPointInfo)
-   {
-      before8 = "Object";
-   }
-   
-   public void before8(@Arg String text)
-   {
-      before8 = "String";
-   }
-      
-   public void before8()
-   {
-      before8 = "";
-   }
-   
-   public void before8(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before8(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before9(@JoinPoint Object joinPointInfo)
-   {
-      before9 = "Object";
-   }
-   
-   public void before9(@Arg String text)
-   {
-      before9 = "String";
-   }
-      
-   public void before9()
-   {
-      before9 = "";
-   }
-   
-   public void before9(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before9(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before10(@Arg String text)
-   {
-      before10 = "String";
-   }
-
-   public void before10(@Arg Object text)
-   {
-      before10 = "Object";
-   }
-   
-   public void before10()
-   {
-      before10 = "";
-   }
-   
-   public void before10(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before10(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before11(@Arg Object text)
-   {
-      before11 = "Object";
-   }
-   
-   public void before11()
-   {
-      before11 = "";
-   }
-   
-   public void before11(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before11(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before12()
-   {
-      before12 = "";
-   }
-   
-   public void before12(@JoinPoint MethodInfo constructorInfo)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void before12(@Arg SuperValue text)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   /* AROUND ADVICES */
-   
-   public Object around1(Invocation invocation) throws Throwable
-   {
-      around1 = "defaultSignature";
-      return invocation.invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around1 = "MethodInvocation,int,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around1 = "Invocation,int,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around1 = "Object,int,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1) throws Throwable
-   {
-      around1 = "MethodInvocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg long arg2) throws Throwable
-   {
-      around1 = "MethodInvocation,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1) throws Throwable
-   {
-      around1 = "Invocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg long arg2) throws Throwable
-   {
-      around1 = "Invocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around1 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around1 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around1 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-   
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around1 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around1(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around1 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around1(@Arg int arg1) throws Throwable
-   {
-      around1 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around1(@Arg long arg2) throws Throwable
-   {
-      around1 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around1() throws Throwable
-   {
-      around1 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around1(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-   
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around2 = "MethodInvocation,int,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around2 = "Invocation,int,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around2 = "Object,int,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1) throws Throwable
-   {
-      around2 = "MethodInvocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg long arg2) throws Throwable
-   {
-      around2 = "MethodInvocation,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1) throws Throwable
-   {
-      around2 = "Invocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg long arg2) throws Throwable
-   {
-      around2 = "Invocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around2 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around2 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around2 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-   
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around2 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around2(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around2 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around2(@Arg int arg1) throws Throwable
-   {
-      around2 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around2(@Arg long arg2) throws Throwable
-   {
-      around2 = "long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around2() throws Throwable
-   {
-      around2 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around2(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around3 = "Invocation,int,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around3 = "Object,int,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1) throws Throwable
-   {
-      around3 = "MethodInvocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg long arg2) throws Throwable
-   {
-      around3 = "MethodInvocation,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1) throws Throwable
-   {
-      around3 = "Invocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg long arg2) throws Throwable
-   {
-      around3 = "Invocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around3 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around3 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around3 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around3 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around3(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around3 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around3(@Arg int arg1) throws Throwable
-   {
-      around3 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around3(@Arg long arg2) throws Throwable
-   {
-      around3 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around3() throws Throwable
-   {
-      around3 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around3(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around4 = "Object,int,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1) throws Throwable
-   {
-      around4 = "MethodInvocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg long arg2) throws Throwable
-   {
-      around4 = "MethodInvocation,long";
-      return invocation.invokeNext();
-   }
-   
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1) throws Throwable
-   {
-      around4 = "Invocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg long arg2) throws Throwable
-   {
-      around4 = "Invocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around4 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around4 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around4 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around4 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around4(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around4 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around4(@Arg int arg1) throws Throwable
-   {
-      around4 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around4(@Arg long arg2) throws Throwable
-   {
-      around4 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around4() throws Throwable
-   {
-      around4 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg int arg1) throws Throwable
-   {
-      around5 = "MethodInvocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation, @Arg long arg2) throws Throwable
-   {
-      around5 = "MethodInvocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1) throws Throwable
-   {
-      around5 = "Invocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg long arg2) throws Throwable
-   {
-      around5 = "Invocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around5 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around5 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around5 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around5 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around5(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around5 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around5(@Arg int arg1) throws Throwable
-   {
-      around5 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around5(@Arg long arg2) throws Throwable
-   {
-      around5 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around5() throws Throwable
-   {
-      around5 = "";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around5(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around6(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg int arg1) throws Throwable
-   {
-      around6 = "Invocation,int";
-      return invocation.invokeNext();
-   }
-
-   public Object aroun6(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation, @Arg long arg2) throws Throwable
-   {
-      around6 = "Invocation,long";
-      return invocation.invokeNext();
-   }
-
-   public Object around6(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around6 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around6(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around6 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around6(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around6 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-   
-   public Object around6(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around6 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around6(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around6 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around6(@Arg int arg1) throws Throwable
-   {
-      around6 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around6(@Arg long arg2) throws Throwable
-   {
-      around6 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around6() throws Throwable
-   {
-      around6 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around6(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around7(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg int arg1) throws Throwable
-   {
-      around7 = "Object,int";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around7(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation, @Arg long arg2) throws Throwable
-   {
-      around7 = "Object,long";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around7(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around7 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-   
-   public Object around7(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around7 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around7(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around7 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around7(@Arg int arg1) throws Throwable
-   {
-      around7 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around7(@Arg long arg2) throws Throwable
-   {
-      around7 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around7() throws Throwable
-   {
-      around7 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around7(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around8(@org.jboss.aop.advice.annotation.Invocation
-         MethodInvocation invocation) throws Throwable
-   {
-      around8 = "MethodInvocation";
-      return invocation.invokeNext();
-   }
-
-   public Object around8(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around8 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-   
-   public Object around8(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around8 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around8(@Arg int arg1) throws Throwable
-   {
-      around8 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around8(@Arg long arg2) throws Throwable
-   {
-      around8 = "long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around8() throws Throwable
-   {
-      around8 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around8(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around9(@org.jboss.aop.advice.annotation.Invocation
-         Object invocation) throws Throwable
-   {
-      around9 = "Object";
-      return ((Invocation) invocation).invokeNext();
-   }
-
-   public Object around9(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around9 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around9(@Arg int arg1) throws Throwable
-   {
-      around9 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around9(@Arg long arg2) throws Throwable
-   {
-      around9 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around9() throws Throwable
-   {
-      around9 = "";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around9(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around10(@Arg int arg1, @Arg long arg2) throws Throwable
-   {
-      around10 = "int,long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around10(@Arg int arg1) throws Throwable
-   {
-      around10 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around10(@Arg long arg2) throws Throwable
-   {
-      around10 = "long";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around10() throws Throwable
-   {
-      around10 = "";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around10(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-
-   public Object around11(@Arg int arg1) throws Throwable
-   {
-      around11 = "int";
-      return CurrentInvocation.proceed();
-   }
-
-   public Object around11(@Arg long arg2) throws Throwable
-   {
-      around11 = "long";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around11() throws Throwable
-   {
-      around11 = "";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around11(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-   
-   public Object around12() throws Throwable
-   {
-      around12 = "";
-      return CurrentInvocation.proceed();
-   }
-   
-   public Object around12(@org.jboss.aop.advice.annotation.Invocation
-         ConstructorInvocation invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdvicePOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdvicePOJO.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdvicePOJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,13 +0,0 @@
-package org.jboss.test.aop.args;
-
-/**
- * Plain old java object used on overloaded advice tests.
- * 
- * @author Flavia Rainone
- */
-public class OverloadedAdvicePOJO
-{
-   public String text;
-   
-   public void method(int arg1, long arg2) {}
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceTestCase.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceTestCase.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,82 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.aop.AOPTestWithSetup;
-
-/**
- * Tests the selection of advice methods when these are overloaded.
- * 
- * @author Flavia Rainone
- */
-public class OverloadedAdviceTestCase extends AOPTestWithSetup
-{
-   private OverloadedAdvicePOJO pojo;
-   
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("OverloadedAdviceTestCase");
-      suite.addTestSuite(OverloadedAdviceTestCase.class);
-      return suite;
-   }
-   
-   public OverloadedAdviceTestCase(String name)
-   {
-      super(name);
-   }
-   
-   public void setUp() throws Exception
-   {
-      super.setUp();
-      OverloadedAdviceAspect.clear();
-      this.pojo = new OverloadedAdvicePOJO();
-   }
-   
-   public void test1()
-   {
-      pojo.method(10, 15);
-      assertEquals("defaultSignature", OverloadedAdviceAspect.around1);
-      assertEquals("MethodInvocation,int,long", OverloadedAdviceAspect.around2);
-      assertEquals("Invocation,int,long", OverloadedAdviceAspect.around3);
-      assertEquals("Object,int,long", OverloadedAdviceAspect.around4);
-      assertTrue(OverloadedAdviceAspect.around5.startsWith("MethodInvocation,"));
-      assertTrue(OverloadedAdviceAspect.around5.equals("MethodInvocation,int") ||
-            OverloadedAdviceAspect.around5.equals("MethodInvocation,long"));
-      assertTrue(OverloadedAdviceAspect.around6.startsWith("Invocation,"));
-      assertTrue(OverloadedAdviceAspect.around6.equals("Invocation,int") ||
-            OverloadedAdviceAspect.around6.equals("Invocation,long"));
-      assertTrue(OverloadedAdviceAspect.around7.startsWith("Object,"));
-      assertTrue(OverloadedAdviceAspect.around7.equals("Object,int") ||
-            OverloadedAdviceAspect.around7.equals("Object,long"));
-      assertEquals("MethodInvocation", OverloadedAdviceAspect.around8);
-      assertEquals("Object", OverloadedAdviceAspect.around9);
-      assertEquals("int,long", OverloadedAdviceAspect.around10);
-      assertTrue(OverloadedAdviceAspect.around11.equals("int") ||
-            OverloadedAdviceAspect.around11.equals("long"));
-      assertEquals("", OverloadedAdviceAspect.around12);
-   }
-   
-   public void test2()
-   {
-      pojo.text = "test2";
-      assertEquals("FieldInfo,String", OverloadedAdviceAspect.before1);
-      assertEquals("FieldInfo,Object", OverloadedAdviceAspect.before2);
-      assertEquals("JoinPointInfo,String", OverloadedAdviceAspect.before3);
-      assertEquals("JoinPointInfo,Object", OverloadedAdviceAspect.before4);
-      assertEquals("Object,String", OverloadedAdviceAspect.before5);
-      assertEquals("Object,Object", OverloadedAdviceAspect.before6);
-      assertEquals("FieldInfo", OverloadedAdviceAspect.before7);
-      assertEquals("JoinPointInfo", OverloadedAdviceAspect.before8);
-      assertEquals("Object", OverloadedAdviceAspect.before9);
-      assertEquals("String", OverloadedAdviceAspect.before10);
-      assertEquals("Object", OverloadedAdviceAspect.before11);
-      assertEquals("", OverloadedAdviceAspect.before12);
-   }
-}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJO.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgPOJO.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ArgPOJO.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -0,0 +1,87 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.args;
+
+
+/**
+ * Plain old java object used on the tests
+ * 
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision$
+ */
+public class POJO implements ArgPOJOInterface
+{
+   /* ArgTestCase */
+   
+   public String echo(String echo)
+   {
+      return echo;
+   }
+
+   public int bunch(int x, double y, float z, String str, int q)
+   {
+      return x + (int) y + (int) z + q;
+   }
+
+   public int bunchArgs(int x, double y, float z, String str, int q)
+   {
+      return x + (int) y + (int) z + q;
+   }
+
+   public int bunchArgsWithInvocation(int x, double y, float z, String str, int q)
+   {
+      return x + (int) y + (int) z + q;
+   }
+
+   public int bunchWrapped(int x, double y, float z, String str, int q)
+   {
+      return x + (int) y + (int) z + q;
+   }
+   
+   /* InvocationTestCase */
+   
+   public int number;
+
+   public int callerMethod(int i)
+   {
+      return calleeMethod(i);
+   }
+   
+   private int calleeMethod(int i)
+   {
+      return i*2;
+   }
+   
+   public String method1()
+   {
+      return "method";
+   }
+   
+   public int method2()
+   {
+      return 2;
+   }
+   
+   /* OverloadedTestCase */
+   
+   public void method3(int arg1, long arg2) {}
+}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJOException.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJOException.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJOException.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,34 +0,0 @@
-package org.jboss.test.aop.args;
-
-/**
- * Class used on annotated parameter tests.
- * 
- * @author Flavia Rainone
- */
-public class POJOException extends Exception
-{
-   private static final long serialVersionUID = 1L;
-
-   /**
-    * A number that identifies the exception thrown.
-    */
-   int number;
-
-   /**
-    * Constructor.
-    */
-   public POJOException()
-   {
-      this(0);
-   }
-
-   /**
-    * Constructor.
-    * 
-    * @param number a number identifying the exception.
-    */
-   public POJOException(int number)
-   {
-      this.number = number;  
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnAspect.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnAspect.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,185 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Assert;
-
-import org.jboss.aop.JoinPointInfo;
-import org.jboss.aop.advice.annotation.JoinPoint;
-import org.jboss.aop.advice.annotation.Return;
-import org.jboss.aop.joinpoint.Invocation;
-
-/**
- * Aspect used both on @Return parameter tests, and on advice return type tests.
- * 
- * @author Flavia Rainone
- */
-public class ReturnAspect
-{
-   public static String aroundAdvice = null;
-   public static Object aroundReturn = null;
-   public static String afterAdvice = null;
-   public static Object afterReturn = null;
-   
-   public static void clear()
-   {
-      aroundAdvice = null;
-      aroundReturn = null;
-      afterAdvice = null;
-      afterReturn = null;
-   }
-   
-   public void before(@Return Object object)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void throwing(@Return Object object)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void around1(Invocation invocation) throws Exception
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void around2(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation) throws Exception
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public Object around3(Invocation invocation) throws Throwable
-   {
-      aroundAdvice = "around3";
-      aroundReturn = invocation.invokeNext();
-      return aroundAdvice;
-   }
-   
-   public Object around4(@org.jboss.aop.advice.annotation.Invocation
-         Invocation invocation) throws Throwable
-   {
-      aroundAdvice = "around4";
-      aroundReturn = invocation.invokeNext();
-      return aroundAdvice;
-   }
-   
-   public Object around5()
-   {
-      aroundAdvice = "around5";
-      return aroundAdvice;
-   }
-   
-   public void around6()
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public String around7(@org.jboss.aop.advice.annotation.Invocation Invocation
-         invocation) throws Throwable
-   {
-      aroundAdvice = "around7";
-      aroundReturn = invocation.invokeNext();
-      return aroundAdvice;
-   }
-   
-   public SubValue around8()
-   {
-      aroundAdvice = "around8";
-      return new SubValue(80);
-   }
-   
-   public SuperValue around9(@org.jboss.aop.advice.annotation.Invocation Invocation
-         invocation) throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-   
-   public SubValue around10(@org.jboss.aop.advice.annotation.Invocation Invocation
-         invocation) throws Throwable
-   {
-      aroundAdvice = "around10";
-      aroundReturn = invocation.invokeNext();
-      return new SubValue(100);
-   }
-   
-   public SuperValue around11(@org.jboss.aop.advice.annotation.Invocation Invocation
-         invocation) throws Throwable
-   {
-      aroundAdvice = "around11";
-      aroundReturn = invocation.invokeNext();
-      return new SuperValue(110);
-   }
-
-   
-   public void after1(@org.jboss.aop.advice.annotation.JoinPoint JoinPointInfo info) throws Exception
-   {
-      afterAdvice = "after1";
-   }
-   
-   public void after2(@Return Object returnedValue) throws Exception
-   {
-      afterAdvice = "after2";
-      afterReturn = returnedValue;
-   }
-   
-   public Object after3(@JoinPoint JoinPointInfo info, @Return String returnedValue)
-   throws Throwable
-   {
-      afterAdvice = "after3";
-      afterReturn = returnedValue;
-      return afterAdvice;
-   }
-   
-   public Object after4(@Return Object returnedValue) throws Throwable
-   {
-      afterAdvice = "after4";
-      afterReturn = returnedValue;
-      return afterAdvice;
-   }
-   
-   public Object after5()
-   {
-      afterAdvice = "after5";
-      return afterAdvice;
-   }
-   
-   public void after6()
-   {
-      afterAdvice = "after6";
-   }
-   
-   public String after7(@JoinPoint JoinPointInfo joinPoint,
-         @Return String returnedValue) throws Throwable
-   {
-      afterAdvice = "after7";
-      afterReturn = returnedValue;
-      return afterAdvice;
-   }
-   
-   public SubValue after8()
-   {
-      afterAdvice = "after8";
-      return new SubValue(800);
-   }
-   
-   public SuperValue after9() throws Throwable
-   {
-      Assert.fail("This advice should never be executed");
-      return null;
-   }
-   
-   public SubValue after10(@Return SubValue returnedValue) throws Throwable
-   {
-      afterAdvice = "after10";
-      afterReturn = returnedValue;
-      return new SubValue(1000);
-   }
-   
-   public SubValue after11(@Return SuperValue returnedValue) throws Throwable
-   {
-      afterAdvice = "after11";
-      afterReturn = returnedValue;
-      return new SubValue(1100);
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnPOJO.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnPOJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,67 +0,0 @@
-package org.jboss.test.aop.args;
-
-/**
- * Plain old java object used both on @Return parameter tests, and on advice return type
- * tests.
- * 
- * @author Flavia Rainone
- */
-public class ReturnPOJO
-{
-   public void method1() {}
-
-   public String method2()
-   {
-      return "method2";
-   }
-   
-   public String method3()
-   {
-      return "method3";
-   }
-   
-   public String method4()
-   {
-      return "method4";
-   }
-   
-   public String method5()
-   {
-      return "method5";
-   }
-   
-   public String method6()
-   {
-      return "method6";
-   }
-   
-   public String method7()
-   {
-      return "method7";
-   }
-   
-   public SubValue method8()
-   {
-      return new SubValue(8);
-   }
-   
-   public SubValue method9()
-   {
-      return new SubValue(9);
-   }
-   
-   public SuperValue method10()
-   {
-      return new SuperValue(10);
-   }
-   
-   public SuperValue method11()
-   {
-      return new SuperValue(11);
-   }
-   
-   public Object method12() throws POJOException
-   {
-      throw new POJOException();
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnTestCase.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnTestCase.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,160 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.aop.AOPTestWithSetup;
-
-/**
- * Tests both the use of @Return parameters, and the use of return values in advices.
- * 
- * @author Flavia Rainone
- */
-public class ReturnTestCase extends AOPTestWithSetup
-{
-   private ReturnPOJO pojo;
-   
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("ReturnTestCase");
-      suite.addTestSuite(ReturnTestCase.class);
-      return suite;
-   }
-   
-   public ReturnTestCase(String name)
-   {
-      super(name);
-   }
-   
-   public void setUp() throws Exception
-   {
-      super.setUp();
-      ReturnAspect.clear();
-      this.pojo = new ReturnPOJO();
-   }
-   
-   public void test1()
-   {
-      pojo.method1();
-      assertNull(ReturnAspect.aroundAdvice);
-      assertNull(ReturnAspect.aroundReturn);
-      assertEquals("after1", ReturnAspect.afterAdvice);
-      assertNull(ReturnAspect.afterReturn);
-   }
-   
-   public void test2()
-   {
-      assertEquals("method2", pojo.method2());
-      assertNull(ReturnAspect.aroundAdvice);
-      assertNull(ReturnAspect.aroundReturn);
-      assertEquals("after2", ReturnAspect.afterAdvice);
-      assertEquals("method2", ReturnAspect.afterReturn);
-   }
-   
-   public void test3()
-   {
-      assertEquals("after3", pojo.method3());
-      assertEquals("around3", ReturnAspect.aroundAdvice);
-      assertEquals("method3", ReturnAspect.aroundReturn);
-      assertEquals("after3", ReturnAspect.afterAdvice);
-      assertEquals("around3", ReturnAspect.afterReturn);
-   }
-   
-   public void test4()
-   {
-      assertEquals("after4", pojo.method4());
-      assertEquals("around4", ReturnAspect.aroundAdvice);
-      assertEquals("method4", ReturnAspect.aroundReturn);
-      assertEquals("after4", ReturnAspect.afterAdvice);
-      assertEquals("around4", ReturnAspect.afterReturn);
-   }
-   
-   public void test5()
-   {
-      assertEquals("after5", pojo.method5());
-      assertEquals("around5", ReturnAspect.aroundAdvice);
-      assertNull(ReturnAspect.aroundReturn);
-      assertEquals("after5", ReturnAspect.afterAdvice);
-      assertNull(ReturnAspect.afterReturn);
-   }
-   
-   public void test6()
-   {
-      assertEquals("method6", pojo.method6());
-      assertNull(ReturnAspect.aroundAdvice);
-      assertNull(ReturnAspect.aroundReturn);
-      assertEquals("after6", ReturnAspect.afterAdvice);
-      assertNull(ReturnAspect.afterReturn);
-   }
-   
-   public void test7()
-   {
-      assertEquals("after7", pojo.method7());
-      assertEquals("around7", ReturnAspect.aroundAdvice);
-      assertEquals("method7", ReturnAspect.aroundReturn);
-      assertEquals("after7", ReturnAspect.afterAdvice);
-      assertEquals("around7", ReturnAspect.afterReturn);
-   }
-   
-   public void test8()
-   {
-      SubValue value = pojo.method8();
-      assertNotNull(value);
-      assertEquals(800, value.i);
-      assertEquals("around8", ReturnAspect.aroundAdvice);
-      assertNull(ReturnAspect.aroundReturn);
-      assertEquals("after8", ReturnAspect.afterAdvice);
-      assertNull(ReturnAspect.afterReturn);
-   }
-   
-   public void test9()
-   {
-      SubValue value = pojo.method9();
-      assertNotNull(value);
-      assertEquals(9, value.i);
-      assertNull(ReturnAspect.aroundAdvice);
-      assertNull(ReturnAspect.aroundReturn);
-      assertNull(ReturnAspect.afterAdvice);
-      assertNull(ReturnAspect.afterReturn);
-   }
-   
-   public void test10()
-   {
-      SuperValue value = pojo.method10();
-      assertNotNull(value);
-      assertEquals(100, value.i);
-      assertEquals("around10", ReturnAspect.aroundAdvice);
-      assertNotNull(ReturnAspect.aroundReturn);
-      assertEquals(10, ((SuperValue) ReturnAspect.aroundReturn).i);
-      assertNull(ReturnAspect.afterAdvice);
-      assertNull(ReturnAspect.afterReturn);
-   }
-
-   public void test11()
-   {
-      SuperValue value = pojo.method11();
-      assertNotNull(value);
-      assertEquals(1100, value.i);
-      assertEquals("around11", ReturnAspect.aroundAdvice);
-      assertNotNull(ReturnAspect.aroundReturn);
-      assertEquals(11, ((SuperValue) ReturnAspect.aroundReturn).i);
-      assertEquals("after11", ReturnAspect.afterAdvice);
-      assertNotNull(ReturnAspect.afterReturn);
-      assertEquals(110, ((SuperValue) ReturnAspect.afterReturn).i);
-   }
-   
-   public void test12()
-   {
-      try
-      {
-         pojo.method12();
-      }
-      catch(POJOException e){}
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SubValue.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SubValue.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SubValue.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,38 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.test.aop.args;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 39449 $
- */
-public class SubValue extends SuperValue
-{
-
-   public SubValue(int i)
-   {
-      // FIXME SubValue constructor
-      super(i);
-   }
-
-}

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SuperValue.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SuperValue.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SuperValue.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,47 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.test.aop.args;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 39449 $
- */
-public class SuperValue
-{
-   int i;
-   public SuperValue(int i)
-   {
-      this.i = i;
-   }
-   
-   public int getValue()
-   {
-      return i;
-   }
-   
-   public void doubleValue()
-   {
-      i *= 2;
-   }
-
-}

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownAspect.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownAspect.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,67 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Assert;
-
-import org.jboss.aop.advice.annotation.Arg;
-import org.jboss.aop.advice.annotation.Thrown;
-
-/**
- * Aspect used on @Thrown parameter tests.
- * 
- * @author Flavia Rainone
- */
-public class ThrownAspect
-{
-
-   public static String advice;
-   public static Throwable thrown;
-   public static int thrownNumber;
-   
-   public static void clear()
-   {
-      advice = null;
-      thrown = null;
-      thrownNumber = 0;
-   }
-   
-   public void throwing1()
-   {
-      advice = "throwing1";
-   }
-   
-   public void throwing2(@Thrown Throwable throwable, @Arg int i)
-   {
-      advice = "throwing2";
-      thrownNumber = i;
-      thrown = throwable;
-   }
-   
-   public void throwing3(@Thrown Exception exception)
-   {
-      advice = "throwing3";
-      thrownNumber = ((POJOException) exception).number;
-      thrown = exception;
-   }
-   
-   public void throwing4(@Thrown POJOException pojoException, @Arg int i)
-   {
-      advice = "throwing4";
-      thrownNumber = i;
-      thrown = pojoException;
-   }
-   
-   public void throwing5(@Thrown RuntimeException runtimeException)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void throwing6(Throwable throwable)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-   
-   public void throwing7(@Arg int i)
-   {
-      Assert.fail("This advice should never be executed");
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownPOJO.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownPOJO.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,39 +0,0 @@
-package org.jboss.test.aop.args;
-
-/**
- * Plain old java object used on @Thrown parameter tests.
- * 
- * @author Flavia Rainone
- */
-public class ThrownPOJO
-{
-   public void method1(int i) throws POJOException
-   {
-      throw new POJOException(i);
-   }
-   
-   public void method2(int i) throws POJOException
-   {
-      throw new POJOException(i);
-   }
-   
-   public void method3(int i) throws POJOException
-   {
-      throw new POJOException(i);
-   }
-   
-   public void method4(int i) throws POJOException
-   {
-      throw new POJOException(i);
-   }
-   
-   public void method5(int i) throws POJOException
-   {
-      throw new POJOException(i);
-   }
-   
-   public void method6() throws POJOException
-   {
-      throw new POJOException(6);
-   }
-}
\ No newline at end of file

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownTestCase.java	2006-12-02 03:46:16 UTC (rev 58816)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownTestCase.java	2006-12-02 04:09:03 UTC (rev 58817)
@@ -1,156 +0,0 @@
-package org.jboss.test.aop.args;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-import org.jboss.test.aop.AOPTestWithSetup;
-
-/**
- * Tests parameter annotation @Thrown. 
- * 
- * @author Flavia Rainone
- *
- */
-public class ThrownTestCase extends AOPTestWithSetup
-{
-   private ThrownPOJO pojo;
-
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("ThrownTestCase");
-      suite.addTestSuite(ThrownTestCase.class);
-      return suite;
-   }
-
-   public ThrownTestCase(String name)
-   {
-      super(name);
-   }
-
-   public void setUp() throws Exception
-   {
-      super.setUp();
-      ThrownAspect.clear();
-      this.pojo = new ThrownPOJO();
-   }
-
-   public void test1()
-   {
-      boolean thrown = false;
-      try
-      {
-         pojo.method1(11);
-      }
-      catch(POJOException pojoException)
-      {
-         thrown = true;
-         assertEquals(11, pojoException.number);
-         assertNull(ThrownAspect.advice);
-         assertNull(ThrownAspect.thrown);
-         assertEquals(0, ThrownAspect.thrownNumber);
-      }
-      assertTrue(thrown);
-   }
-
-   public void test2()
-   {
-      boolean thrown = false;
-      try
-      {
-         pojo.method2(23);
-      }
-      catch(POJOException pojoException)
-      {
-         thrown = true;
-         assertEquals(23, pojoException.number);
-         assertEquals("throwing2", ThrownAspect.advice);
-         assertEquals(pojoException, ThrownAspect.thrown);
-         assertEquals(23, ThrownAspect.thrownNumber);
-      }
-      assertTrue(thrown);
-   }
-   
-   public void test3()
-   {
-      boolean thrown = false;
-      try
-      {
-         pojo.method3(37);
-      }
-      catch(POJOException pojoException)
-      {
-         thrown = true;
-         assertEquals(37, pojoException.number);
-         assertNull(ThrownAspect.advice);
-         assertNull(ThrownAspect.thrown);
-         assertEquals(0, ThrownAspect.thrownNumber);
-         /*assertEquals("throwing3", ThrownAspect.advice);
-         assertEquals(pojoException, ThrownAspect.thrown);
-         assertEquals(37, ThrownAspect.thrownNumber);*/
-      }
-      assertTrue(thrown);
-   }
-   
-   public void test4()
-   {
-      boolean thrown = false;
-      try
-      {
-         pojo.method4(43);
-      }
-      catch(POJOException pojoException)
-      {
-         thrown = true;
-         assertEquals(43, pojoException.number);
-         assertNull(ThrownAspect.advice);
-         assertNull(ThrownAspect.thrown);
-         assertEquals(0, ThrownAspect.thrownNumber);
-         /*assertEquals("throwing4", ThrownAspect.advice);
-         assertEquals(pojoException, ThrownAspect.thrown);
-         assertEquals(43, ThrownAspect.thrownNumber);*/
-      }
-      assertTrue(thrown);
-   }
-   
-   public void test5()
-   {
-      boolean thrown = false;
-      try
-      {
-         pojo.method5(59);
-      }
-      catch(POJOException pojoException)
-      {
-         thrown = true;
-         assertEquals(59, pojoException.number);
-         assertNull(ThrownAspect.advice);
-         assertNull(ThrownAspect.thrown);
-         assertEquals(0, ThrownAspect.thrownNumber);
-      }
-      assertTrue(thrown);
-   }
-   
-   public void test6()
-   {
-      boolean thrown = false;
-      try
-      {
-         pojo.method6();
-      }
-      catch(POJOException pojoException)
-      {
-         thrown = true;
-         assertEquals(6, pojoException.number);
-         assertNull(ThrownAspect.advice);
-         assertNull(ThrownAspect.thrown);
-         assertEquals(0, ThrownAspect.thrownNumber);
-      }
-      assertTrue(thrown);
-   }
-}
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 00:53:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 00:53:39 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1682 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server:
	. connectionfactory
Message-ID: <E1GqNoh-0002fu-99@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-02 00:53:37 -0500 (Sat, 02 Dec 2006)
New Revision: 1682

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
Log:
minor refactoring

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-02 02:28:38 UTC (rev 1681)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-02 05:53:37 UTC (rev 1682)
@@ -619,8 +619,8 @@
    
    public Replicator getDataReplicator() throws Exception
    {
-      //For now we just choose the queue post office - soon we merge both post offices into one
-      //anyway
+      // For now we just choose the queue post office - soon we merge both post offices into one
+      // anyway
       
       PostOffice office = getQueuePostOfficeInstance();
       

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-02 02:28:38 UTC (rev 1681)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-02 05:53:37 UTC (rev 1682)
@@ -81,41 +81,41 @@
    
    // ConnectionFactoryManager implementation -----------------------
 
-
-
    public synchronized void registerConnectionFactory(String uniqueName,
-            String clientID,
-            JNDIBindings jndiBindings,
-            String locatorURI,
-            boolean clientPing,
-            int prefetchSize,
-            int defaultTempQueueFullSize,
-            int defaultTempQueuePageSize,
-            int defaultTempQueueDownCacheSize,
-            boolean clustered) throws Exception
+                                                      String clientID,
+                                                      JNDIBindings jndiBindings,
+                                                      String locatorURI,
+                                                      boolean clientPing,
+                                                      int prefetchSize,
+                                                      int defaultTempQueueFullSize,
+                                                      int defaultTempQueuePageSize,
+                                                      int defaultTempQueueDownCacheSize,
+                                                      boolean clustered)
+      throws Exception
    {
       int id = serverPeer.getNextObjectID();
-      
+
       ServerConnectionFactoryEndpoint endpoint =
          new ServerConnectionFactoryEndpoint(id, serverPeer, clientID,
-                  jndiBindings, prefetchSize,
-                  defaultTempQueueFullSize,
-                  defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
-      
+                                             jndiBindings, prefetchSize,
+                                             defaultTempQueueFullSize,
+                                             defaultTempQueuePageSize,
+                                             defaultTempQueueDownCacheSize);
+
       ClientConnectionFactoryDelegate delegate =
-         new ClientConnectionFactoryDelegate(id, locatorURI, serverPeer.getVersion(),
-                  clientPing);
+         new ClientConnectionFactoryDelegate(id, locatorURI, serverPeer.getVersion(), clientPing);
       
       if (clustered)
       {
-         //First we must replicate the delegate across the cluster so that all the ConnectionFactoryJNDIMapper
-         //instances on different nodes have access to the list of local connection factories
-         //so they can be added to the clustered connection factory
+         // First we must replicate the delegate across the cluster so that all the
+         // ConnectionFactoryJNDIMapper instances on different nodes have access to the list of
+         // local connection factories so they can be added to the clustered connection factory
 
-         getReplicator();
+         setUpReplicator();
+
          replicator.putReplicant(CF_PREFIX + uniqueName, delegate);
          
-         //Get the list of delegates
+         // Get the list of delegates
          
          Map replicants = replicator.getReplicants(CF_PREFIX + uniqueName);
          
@@ -185,9 +185,10 @@
       
       if (clustered)
       {
-         //Remove from replicants
+         // Remove from replicants
 
-         getReplicator();
+         setUpReplicator();
+
          replicator.removeReplicant(CF_PREFIX + uniqueName);
       }
       
@@ -320,9 +321,7 @@
          
          int nodeId = ((Integer)entry.getKey()).intValue();
          
-         ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)entry.getValue();
-         
-         delegates[i] = del;
+         delegates[i] = (ClientConnectionFactoryDelegate)entry.getValue();
 
          int failoverNode = replicator.getFailoverNodeForNode(nodeId);
          
@@ -333,8 +332,7 @@
          i++;
       }
       
-      //Generate the failover indexes
-      //This could probably be optimised if need be
+      // Generate the failover indexes. This could probably be optimised if need be.
       
       int[] failoverIndexes = new int[s];
       
@@ -367,20 +365,20 @@
       cf.setFailoverDelegates(delegates, failoverIndexes);
    }
 
-   private Replicator getReplicator() throws Exception
+   private void setUpReplicator() throws Exception
    {
-      if (replicator==null)
+      if (replicator == null)
       {
          replicator = serverPeer.getDataReplicator();
 
-         if (replicator != null)
+         if (replicator == null)
          {
-            replicator.registerListener(this);
+            throw new IllegalStateException("Cannot get replicator from ServerPeer!");
          }
+
+         replicator.registerListener(this);
       }
-      return replicator;
    }
 
-   
    // Inner classes -------------------------------------------------
 }



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 00:55:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 00:55:09 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1683 - in
	branches/Branch_Client_Failover_Experiment/tests: bin etc
	src/org/jboss/test/messaging/jms/crash
	src/org/jboss/test/messaging/tools
	src/org/jboss/test/messaging/tools/jmx
	src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GqNq9-0002hE-QN@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-02 00:55:02 -0500 (Sat, 02 Dec 2006)
New Revision: 1683

Modified:
   branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
   branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
Enabling test framework to take clustering mode from container.xml/test.clustered

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example	2006-12-02 05:55:02 UTC (rev 1683)
@@ -13,8 +13,16 @@
 # (the database configuration definition MUST exist in tests/etc/container.xml)
 #
 TEST_DATABASE=hsqldb
+
 #
+# Each test can be run in clustered or non-clustered mode. However, setting CLUSTERED to "true"
+# doesn't guarantee that the test will be actually run in clustered mode, the test database must
+# be also permitting sharing over a LAN. "mysql" allows this, "hsqldb" doesn't. The test will
+# quickly fail in such a situation.
 #
+CLUSTERED=true
+#
+#
 # util
 #
 #TARGET_CLASS=org.jboss.test.messaging.util.SelectiveIteratorTest

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-02 05:55:02 UTC (rev 1683)
@@ -21,6 +21,7 @@
 
 ENV_TEST_DATABASE=$TEST_DATABASE
 ENV_TEST_SERIALIZATION=$TEST_SERIALIZATION
+ENV_TEST_CLUSTERED=$TEST_CLUSTERED
 
 if [ -z "$TARGET_CLASS" -a -f $reldir/.testrc ]; then
    . $reldir/.testrc
@@ -37,7 +38,11 @@
 if [ "$ENV_TEST_SERIALIZATION" != "" ]; then
    TEST_SERIALIZATION=$ENV_TEST_SERIALIZATION
 fi
+if [ "$ENV_TEST_CLUSTERED" != "" ]; then
+   TEST_CLUSTERED=$ENV_TEST_CLUSTERED
+fi
 
+
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get
 # it from there.
@@ -94,14 +99,14 @@
     shift
 done
 
-JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dbuild.lib=../../output/lib"
+JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.clustered=$TEST_CLUSTERED -Dbuild.lib=../../output/lib"
 
 if [ "$TARGET_TEST" != "" ]; then
    TARGET_TEST="-t $TARGET_TEST"
 fi
 
 if [ "$isRemote" = "true" ]; then
-  export TEST_DATABASE TEST_SERIALIZATION
+  export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED
   $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file
 fi
 

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-02 05:55:02 UTC (rev 1683)
@@ -45,6 +45,11 @@
    JAVA_OPTS="$JAVA_OPTS -Dtest.serialization=$TEST_SERIALIZATION"
 fi
 
+if [ "$TEST_CLUSTERED" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.clustered=$TEST_CLUSTERED"
+fi
+
+
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
 else

Modified: branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-02 05:55:02 UTC (rev 1683)
@@ -68,6 +68,17 @@
 
    <serialization-type>jms</serialization-type>
 
+
+   <!--
+      Specifies whether to start a clustered messaging server or not. If "test.clustered" is set,
+      the value of the system property takes precedence. Supported values are "true" or "false".
+
+      Setting "clustered" to "true" doesn't guarantee that the test will be actually run in
+      clustered mode, the test database must be also permitting sharing over a LAN. "mysql" allows
+      this, "hsqldb" doesn't. The test will quickly fail in such a situation.
+   -->
+   <clustered>true</clustered>
+
 </container>
 
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       //Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
             
       localServer.deployQueue("Queue", null, false);
            

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       localServer.setAttribute(ServiceContainer.REMOTING_OBJECT_NAME, "LeasePeriod", "30000");
        

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       //Set lease period to -1 --> this should disable leasing so the state won't be cleared up
       

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
       // the default, whatever that is ...

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -75,7 +75,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
       // the default, whatever that is ...

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       //Set lease period to 0 --> this should disable leasing so the state won't be cleared up
       

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -138,10 +138,10 @@
    
    public static synchronized void start(String config) throws Exception
    {
-      start(config, 0, false);
+      start(config, 0);
    }
 
-   public static synchronized void start(String config, int index, boolean clustered) throws Exception
+   public static synchronized void start(String config, int index) throws Exception
    {
       create(index);
 
@@ -156,8 +156,8 @@
       
       MessageIdGeneratorFactory.instance.clear();      
 
-      //Now start the server
-      servers[index].start(config, clustered);
+      // Now start the server
+      servers[index].start(config);
 
       log.debug("server started");
    }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -372,10 +372,13 @@
 
          loadJNDIContexts();
 
-         log.info("remoting = \"" +
-            (remotingSocket ? "socket" : (remotingMultiplex ? "multiplex" : "disabled")) + "\", " +
-            "serialization = \"" + "jms" + "\", " + 
-            "database = \"" + getDatabaseType() + "\"");
+         log.info("REMOTING TYPE: ........... " +
+            (remotingSocket ? "socket" : (remotingMultiplex ? "multiplex" : "disabled")));
+         log.info("SERIALIZATION TYPE: ...... " + config.getSerializationType());
+         log.info("DATABASE: ................ " + config.getDatabaseType());
+         log.info("CLUSTERING MODE: ......... " +
+            (config.isClustered() ? "CLUSTERED" : "NON-CLUSTERED"));
+
          log.debug(this + " started");
       }
       catch(Throwable e)
@@ -747,6 +750,11 @@
       return config.getDatabaseType();
    }
 
+   public boolean isClustered()
+   {
+      return config.isClustered();
+   }
+
    public String toString()
    {
       return "ServiceContainer[" + Integer.toHexString(hashCode()) + "]";

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -29,6 +29,8 @@
 {
    // Constants -----------------------------------------------------
 
+   public static final boolean DEFAULT_CLUSTERED_MODE = false;
+
    // Static --------------------------------------------------------
 
    public static String getHypersonicDatabase(String connectionURL)
@@ -74,6 +76,7 @@
    private String database;
    private Map dbConfigurations;
    private String serializationType;
+   private Boolean clusteredMode;
 
    // Constructors --------------------------------------------------
 
@@ -140,6 +143,14 @@
       return serializationType;
    }
 
+   /**
+    * @return the clustered mode in which the container should run an individual test.
+    */
+   public boolean isClustered()
+   {
+      return clusteredMode.booleanValue();
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -151,6 +162,7 @@
       Reader reader = new InputStreamReader(is);
       String currentDatabase = null;
       String currentSerializationType = null;
+      boolean currentClusteredMode = DEFAULT_CLUSTERED_MODE;
 
       try
       {
@@ -189,6 +201,10 @@
                {
                   currentSerializationType = XMLUtil.getTextContent(n);
                }
+               else if ("clustered".equals(name))
+               {
+                  currentClusteredMode = Boolean.getBoolean(XMLUtil.getTextContent(n));
+               }
                else
                {
                   throw new Exception("Unexpected child <" + name + "> of node " +
@@ -199,6 +215,7 @@
 
          setCurrentDatabase(currentDatabase);
          setCurrentSerializationType(currentSerializationType);
+         setCurrentClusteredMode(currentClusteredMode);
       }
       finally
       {
@@ -220,8 +237,8 @@
    }
 
    /**
-    * Always the value of "test.serialization" system property takes precedence over the c
-    * onfiguration file value.
+    * Always the value of "test.serialization" system property takes precedence over the
+    * configuration file value.
     */
    private void setCurrentSerializationType(String xmlConfigSerializationType)
    {
@@ -232,6 +249,24 @@
       }
    }
 
+   /**
+    * Always the value of "test.clustered" system property takes precedence over the configuration
+    * file value.
+    */
+   private void setCurrentClusteredMode(boolean xmlClusteredMode) throws Exception
+   {
+      String s = System.getProperty("test.clustered");
+      if (s != null)
+      {
+         clusteredMode = Boolean.valueOf(s);
+      }
+
+      if (clusteredMode == null)
+      {
+         clusteredMode = new Boolean(xmlClusteredMode);
+      }
+   }
+
    private void validate() throws Exception
    {
       // make sure that I have a corresponding "database-configuration"

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -99,7 +99,7 @@
 
    // Server implementation -----------------------------------------
 
-   public synchronized void start(String containerConfig, boolean clustered) throws Exception
+   public synchronized void start(String containerConfig) throws Exception
    {
       if (isStarted())
       {
@@ -110,10 +110,8 @@
 
       sc = new ServiceContainer(containerConfig, null, serverIndex);
       sc.start();
-      
-      log.info("********* STARTING SERVER DATABASE TYPE IS " + sc.getDatabaseType());
-      
-      if (this.getDatabaseType().equals("hsqldb") && clustered)
+
+      if (this.getDatabaseType().equals("hsqldb") && sc.isClustered())
       {
          throw new IllegalStateException("The test server cannot be started in clustered mode with hsqldb as a database - must use a shared database");
       }
@@ -123,7 +121,7 @@
          return;
       }
 
-      startServerPeer(serverIndex, null, null, clustered);
+      startServerPeer(serverIndex, null, null, sc.isClustered());
 
       log.info("server started");
    }
@@ -238,7 +236,7 @@
    {
       try
       {         
-         log.info("******* STARTING SERVER PEER WITH ID " + serverPeerID);
+         log.info(" SERVER PEER ID ........... " + serverPeerID);
          
          log.debug("creating ServerPeer instance");
    
@@ -267,9 +265,9 @@
             persistenceConfigFile  =
                "server/default/deploy/" + databaseType + "-persistence-service.xml";
          }
-         
-         log.info("********* LOADING CONFIG FILE: " + persistenceConfigFile);
-         
+
+         log.info(" PERSISTENCE CONFIG FILE .. " + persistenceConfigFile);
+
          URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
          if (persistenceConfigFileURL == null)
          {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -319,9 +319,9 @@
       server.setDefaultSecurityConfig(config);
    }
 
-   public void start(String containerConfig, boolean clustered) throws Exception
+   public void start(String containerConfig) throws Exception
    {
-      server.start(containerConfig, clustered);
+      server.start(containerConfig);
    }
 
    public void startServerPeer(int serverPeerID, String defaultQueueJNDIContext,

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-02 05:53:37 UTC (rev 1682)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-02 05:55:02 UTC (rev 1683)
@@ -42,7 +42,7 @@
  */
 public interface Server extends Remote
 {
-   void start(String containerConfig, boolean clustered) throws Exception;
+   void start(String containerConfig) throws Exception;
    void stop(boolean sendNotification) throws Exception;
    void stop() throws Exception;
    void destroy() throws Exception;



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 00:55:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 00:55:39 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1684 -
	branches/Branch_Client_Failover_Experiment
Message-ID: <E1GqNqd-0002jC-Jo@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-02 00:55:38 -0500 (Sat, 02 Dec 2006)
New Revision: 1684

Modified:
   branches/Branch_Client_Failover_Experiment/
Log:
ignoring IntelliJ artifacts


Property changes on: branches/Branch_Client_Failover_Experiment
___________________________________________________________________
Name: svn:ignore
   - output
thirdparty
messaging.iws


   + output
thirdparty
messaging.iws
messaging-Branch_Client_Failover_Experiment.ipr
messaging-Branch_Client_Failover_Experiment.iws
messaging-Branch_Client_Failover_Experiment.iml




From forge-admin at jboss.com  Sat Dec  2 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sat, 02 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GqNvI-0002nC-K0@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-01 06:34 EST)
-----------------

fix JBSEAM-544

  jboss-seam  src/main/org/jboss/seam/util/EL.java                1.2
  jboss-seam  src/main/org/jboss/seam/core/TaskInstanceList.java  1.13


Commit from vralev (2006-12-01 07:29 EST)
------------------

fixed name

    repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/standalone-compiler.jar  1.2


Commit from gavin (2006-12-01 08:26 EST)
-----------------

add processInstanceList component (experimental)

  jboss-seam  src/main/META-INF/components.xml                       1.6
+ jboss-seam  src/main/org/jboss/seam/core/ProcessInstanceList.java  1.1


Commit from gavin (2006-12-01 08:27 EST)
-----------------

fix an npe and add process list

  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/StoreManagerBean.java  1.9
  jboss-seam  examples/dvdstore/web/admin/admin.xhtml                         1.4


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-01 10:22 EST)
------------------------------------------------------

wc

  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java  1.1.2.2


Commit from gzamarreno (2006-12-01 10:29 EST)
----------------------

How to use JBC marshalling to get around redeployment ClassCastExceptions. QA entry added explaining the problem and resolution as well as a unit test emulating redeployment.

+ JBossCache  tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java  1.2
  JBossCache  docs/faq/en/master.xml                                                    1.43


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-01 10:44 EST)
------------------------------------------------------

delete nodes marked for removal *before* releasing locks on them!!

  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.14.2.8


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-01 12:00 EST)
------------------------------------------------------

removed classic deadlock scenario

  JBossCache  tests/stress/org/jboss/cache/LocalStressTest.java  1.2.2.2


Commit from myuan (2006-12-01 15:40 EST)
-----------------

move the jboss-archive-browsing.jar to shared lib

  jboss-seam  examples/glassfish/build.xml                       1.3
- jboss-seam  examples/glassfish/lib/jboss-archive-browsing.jar  1.2


Commit from myuan (2006-12-01 15:41 EST)
-----------------

Fix the EM for WL and shared jboss-archive-browsing.jar

  jboss-seam  hibernate/lib/hibernate-entitymanager.jar  1.2
+ jboss-seam  hibernate/lib/jboss-archive-browsing.jar   1.1


Commit from gavin (2006-12-01 18:28 EST)
-----------------

JBSEAM-574

  jboss-seam  src/ui/org/jboss/seam/ui/HtmlButton.java  1.3


Commit from myuan (2006-12-01 18:56 EST)
-----------------

Make both WL and GF work ...

  jboss-seam  examples/jpa/build.xml                                        1.7
  jboss-seam  examples/jpa/readme.txt                                       1.2
+ jboss-seam  examples/jpa/resources/glassfish/GlassfishDerbyDialect.class  1.1
+ jboss-seam  examples/jpa/resources/glassfish/import.sql                   1.1
  jboss-seam  examples/jpa/resources/glassfish/log4j.xml                    1.2
  jboss-seam  examples/jpa/resources/glassfish/persistence.xml              1.2
  jboss-seam  examples/jpa/resources/weblogic/log4j.xml                     1.2
  jboss-seam  examples/jpa/src/org/jboss/seam/example/jpa/Booking.java      1.3


Commit from myuan (2006-12-01 18:57 EST)
-----------------

make WL and GF both work ...

  jboss-seam  examples/hibernate2/build.xml                                          1.6
  jboss-seam  examples/hibernate2/readme.txt                                         1.2
+ jboss-seam  examples/hibernate2/resources/glassfish/GlassfishDerbyDialect.class    1.1
  jboss-seam  examples/hibernate2/resources/glassfish/hibernate.cfg.xml              1.2
+ jboss-seam  examples/hibernate2/resources/glassfish/import.sql                     1.1
  jboss-seam  examples/hibernate2/resources/glassfish/log4j.xml                      1.2
  jboss-seam  examples/hibernate2/resources/weblogic/log4j.xml                       1.2
  jboss-seam  examples/hibernate2/src/org/jboss/seam/example/hibernate/Booking.java  1.3


Commit from gavin (2006-12-01 19:54 EST)
-----------------

ProcessInstanceFinder

  jboss-seam  src/main/META-INF/components.xml                         1.7
+ jboss-seam  src/main/org/jboss/seam/core/ProcessInstanceFinder.java  1.1
- jboss-seam  src/main/org/jboss/seam/core/ProcessInstanceList.java    1.2


Commit from gavin (2006-12-01 19:56 EST)
-----------------

show the sql

  jboss-seam  examples/dvdstore/resources/hibernate.cfg.xml  1.6


Commit from gavin (2006-12-01 21:15 EST)
-----------------

JBSEAM-552

  jboss-seam  seam-gen/resources/META-INF/persistence.xml  1.5
  jboss-seam  seam-gen/resources/WEB-INF/components.xml    1.5
  jboss-seam  seam-gen/resources/WEB-INF/faces-config.xml  1.5
  jboss-seam  seam-gen/resources/WEB-INF/navigation.xml    1.2


Commit from gavin (2006-12-01 21:33 EST)
-----------------

auto-add jdbc driver jar to eclipse cp

  jboss-seam  seam-gen/build.xml                                 1.43
  jboss-seam  seam-gen/build-scripts/.classpath                  1.4
+ jboss-seam  src/gen/org/jboss/seam/tool/PathFilenameTask.java  1.1


Commit from gavin (2006-12-01 21:37 EST)
-----------------

fix dupe slash

  jboss-seam  src/gen/org/jboss/seam/tool/PathFilenameTask.java  1.2


Commit from gavin (2006-12-01 21:40 EST)
-----------------

ws

  jboss-seam  seam-gen/build-scripts/.classpath  1.5


Commit from gavin (2006-12-01 21:49 EST)
-----------------

don't show children on create screen

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.8


Commit from gavin (2006-12-01 21:53 EST)
-----------------

fix Done button on create screen

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.9
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061202/802444db/attachment.html 

From gavin.king at jboss.com  Sat Dec  2 02:51:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 02:51:33 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GqPen-0004d3-Q8@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 02:51:33

  Modified:    src/main/org/jboss/seam/contexts  Lifecycle.java
  Log:
  fix JBSEAM-551
  
  Revision  Changes    Path
  1.68      +7 -1      jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.67
  retrieving revision 1.68
  diff -u -b -r1.67 -r1.68
  --- Lifecycle.java	29 Nov 2006 12:51:33 -0000	1.67
  +++ Lifecycle.java	2 Dec 2006 07:51:33 -0000	1.68
  @@ -31,7 +31,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.67 $
  + * @version $Revision: 1.68 $
    */
   public class Lifecycle
   {
  @@ -223,10 +223,16 @@
            Contexts.conversationContext.set(null);
         }
   
  +      Context tempConversationContext = new MapContext(ScopeType.CONVERSATION);
  +      Contexts.conversationContext.set(tempConversationContext);
  +
         log.debug("destroying session context");
         Contexts.destroy(tempSessionContext);
         Contexts.sessionContext.set(null);
   
  +      Contexts.destroy(tempConversationContext);
  +      Contexts.conversationContext.set(null);
  +
         Contexts.destroy(tempEventContext);
         Contexts.eventContext.set(null);
   
  
  
  


From gavin.king at jboss.com  Sat Dec  2 02:51:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 02:51:33 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GqPen-0004dA-Vo@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 02:51:33

  Modified:    src/main/org/jboss/seam/interceptors 
                        ManagedEntityIdentityInterceptor.java
  Log:
  fix JBSEAM-551
  
  Revision  Changes    Path
  1.14      +23 -20    jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedEntityIdentityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ManagedEntityIdentityInterceptor.java	28 Nov 2006 21:29:21 -0000	1.13
  +++ ManagedEntityIdentityInterceptor.java	2 Dec 2006 07:51:33 -0000	1.14
  @@ -170,6 +170,8 @@
            for (PassivatedEntity pe: list)
            {
               Object persistenceContext = Component.getInstance( pe.getPersistenceContext() );
  +            if ( persistenceContext!=null )
  +            {
               Object reference;
               if (persistenceContext instanceof EntityManager)
               {
  @@ -195,6 +197,7 @@
                  catch (NoSuchFieldException nsfe) {}
               }
            }
  +         }
            list.clear();
         }
      }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 08:36:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 08:36:21 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1685 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GqV2T-0002AG-Vp@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-02 08:36:20 -0500 (Sat, 02 Dec 2006)
New Revision: 1685

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Enabling test framework to take clustering mode from container.xml/test.clustered

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-02 05:55:38 UTC (rev 1684)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-02 13:36:20 UTC (rev 1685)
@@ -81,11 +81,11 @@
       try
       {
 
-         ServerManagement.start("all", 0, true);
+         ServerManagement.start("all", 0);
 
-         ServerManagement.start("all", 1, true);
+         ServerManagement.start("all", 1);
 
-         ServerManagement.start("all", 2, true);
+         ServerManagement.start("all", 2);
 
          ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
          ServerManagement.deployClusteredTopic("testDistributedTopic", 0);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-02 05:55:38 UTC (rev 1684)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-02 13:36:20 UTC (rev 1685)
@@ -66,7 +66,7 @@
       }
       finally
       {
-         ServerManagement.start("all", 0, true); // tear down needs the server up
+         ServerManagement.start("all", 0); // tear down needs the server up
       }
    }
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 09:14:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 09:14:29 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1686 - in branches/Branch_1_0: .
	lib lib/jbossts src/main/org/jboss/jms
	src/main/org/jboss/jms/recovery src/main/org/jboss/jms/server
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core/plugin
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/tx tests
	tests/src/org/jboss/test/messaging/core
	tests/src/org/jboss/test/messaging/core/base
	tests/src/org/jboss/test/messaging/core/distributed/queue
	tests/src/org/jboss/test/messaging/core/local
	tests/src/org/jboss/test/messaging/core/paging
	tests/src/org/jboss/test/messaging/core/plugin
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/util util
Message-ID: <E1GqVdN-0002lF-Af@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-02 09:14:09 -0500 (Sat, 02 Dec 2006)
New Revision: 1686

Added:
   branches/Branch_1_0/lib/jbossts/
   branches/Branch_1_0/lib/jbossts/jboss-service.xml
   branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml
   branches/Branch_1_0/src/main/org/jboss/jms/recovery/
   branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java
   branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/PreparedTxInfo.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java
Removed:
   branches/Branch_1_0/lib/jbossts/jboss-service.xml
   branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml
   branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java
   branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java
Modified:
   branches/Branch_1_0/build-messaging.xml
   branches/Branch_1_0/build-thirdparty.xml
   branches/Branch_1_0/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_1_0/src/main/org/jboss/jms/tx/MessagingXAResource.java
   branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java
   branches/Branch_1_0/src/main/org/jboss/jms/tx/TransactionRequest.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/MessageStore.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   branches/Branch_1_0/tests/build.xml
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/base/ChannelTestBase.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/distributed/queue/RecoverableDistributedQueueTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableQueueTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableSubscriptionTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/PagingStateTestBase.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
   branches/Branch_1_0/util/release-admin.xml
Log:
merge Branch_1_0_XARecovery

Modified: branches/Branch_1_0/build-messaging.xml
===================================================================
--- branches/Branch_1_0/build-messaging.xml	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/build-messaging.xml	2006-12-02 14:14:09 UTC (rev 1686)
@@ -139,6 +139,7 @@
       <path refid="javassist.classpath"/>
       <path refid="jgroups.jgroups.classpath"/>
       <path refid="trove.trove.classpath"/>
+      <path refid="apache.logging.classpath"/>
    </path>
 
    <!--
@@ -155,6 +156,7 @@
       <path refid="jboss.aop.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
+      <path refid="jboss.jbossts.classpath"/>
    </path>
 
    <!--
@@ -193,6 +195,13 @@
       <pathelement location="${project.root}/lib/jboss-jmx.jar"/>
    </path>
 
+   <!--
+       This is for compiling the JBossAS JBossTS driven JMS recovery code which uses XAResourceWrapper implementation
+   -->
+   <path id="jboss.classpath">
+      <pathelement location="${project.root}/lib/jboss.jar"/>
+   </path>
+   
    <property name="jboss.server.lib" value="${project.root}/lib/"/>
 
    <property name="jboss.naming.lib" value="${project.root}/lib/"/>
@@ -206,6 +215,7 @@
       <path refid="jboss.jmx.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
+      <path refid="jboss.classpath"/>
    </path>
 
    <!--
@@ -400,13 +410,20 @@
 
       <mkdir dir="${build.lib}"/>
       <jar jarfile="${build.lib}/jboss-${module.name}.jar" manifest="${build.etc}/default.mf">
-         <fileset dir="${build.classes}" includes="**"/>
+         <fileset dir="${build.classes}" includes="**" excludes="org/jboss/jms/recovery/*.class"/>
          <fileset dir="${build.jar}">
             <exclude name="*-service.xml"/>
             <exclude name="*-ds.xml"/>
             <exclude name="messaging-*.properties"/>
          </fileset>
       </jar>
+
+      <!-- JBossTS integration layer for XA recovery -->
+      
+      <jar jarfile="${build.lib}/jboss-${module.name}-integration.jar" manifest="${build.etc}/default.mf">
+         <fileset dir="${build.classes}" includes="org/jboss/jms/recovery/*.class"/>
+      </jar>
+      
    </target>
 
    <target name="scoped-sar" depends="compile, jar, scoped-sar-structure, extract-server-dependencies">

Modified: branches/Branch_1_0/build-thirdparty.xml
===================================================================
--- branches/Branch_1_0/build-thirdparty.xml	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/build-thirdparty.xml	2006-12-02 14:14:09 UTC (rev 1686)
@@ -78,7 +78,7 @@
 
 
       <!--
-           Dependencies requrired to build the project.
+           Dependencies required to build the project.
       -->
       <componentref name="retrotranslator" version="0.9.6jboss"/>
       <componentref name="sun-javacc" version="3.2"/>
@@ -93,6 +93,7 @@
       <componentref name="jboss/aop" version="1.5.0.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
       <componentref name="jboss/remoting" version="2.2.0.Alpha3"/>
+      <componentref name="jboss/jbossts" version="4.2.2.GA"/>
 
       <!-- Need this otherwise project doesn't build in Eclipse -->
       <componentref name="apache-logging" version="1.0.4.1jboss"/>

Copied: branches/Branch_1_0/lib/jbossts (from rev 1684, branches/Branch_1_0_XARecovery/lib/jbossts)

Deleted: branches/Branch_1_0/lib/jbossts/jboss-service.xml
===================================================================
--- branches/Branch_1_0_XARecovery/lib/jbossts/jboss-service.xml	2006-12-02 05:55:38 UTC (rev 1684)
+++ branches/Branch_1_0/lib/jbossts/jboss-service.xml	2006-12-02 14:14:09 UTC (rev 1686)
@@ -1,535 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id: jboss-service.xml 38992 2005-12-13 15:29:35Z jerrygauth $ -->
-
-<!-- ===================================================================== -->
-<!--  JBoss Server Configuration                                           -->
-<!-- ===================================================================== -->
-
-<server>
-
-   <!-- Load all jars from the JBOSS_DIST/server/<config>/lib directory. This
-     can be restricted to specific jars by specifying them in the archives
-     attribute.
-    -->
-   <classpath codebase="${jboss.server.lib.url:lib}" archives="*"/>
-
-   <!-- ==================================================================== -->
-   <!-- JSR-77 Single JBoss Server Management Domain                         -->
-   <!-- ==================================================================== -->
-   <mbean code="org.jboss.management.j2ee.LocalJBossServerDomain"
-      name="jboss.management.local:j2eeType=J2EEDomain,name=Manager">
-      <attribute name="MainDeployer">jboss.system:service=MainDeployer</attribute>
-      <attribute name="SARDeployer">jboss.system:service=ServiceDeployer</attribute>
-      <attribute name="EARDeployer">jboss.j2ee:service=EARDeployer</attribute>
-      <attribute name="EJBDeployer">jboss.ejb:service=EJBDeployer</attribute>
-      <attribute name="RARDeployer">jboss.jca:service=RARDeployer</attribute>
-      <attribute name="CMDeployer">jboss.jca:service=ConnectionFactoryDeployer</attribute>
-      <attribute name="WARDeployer">jboss.web:service=WebServer</attribute>
-      <attribute name="CARDeployer">jboss.j2ee:service=ClientDeployer</attribute>
-      <attribute name="MailService">jboss:service=Mail</attribute>
-      <attribute name="JMSService">jboss.mq:service=DestinationManager</attribute>
-      <attribute name="JNDIService">jboss:service=Naming</attribute>
-      <attribute name="JTAService">jboss:service=TransactionManager</attribute>
-      <attribute name="UserTransactionService">jboss:service=ClientUserTransaction</attribute>
-      <attribute name="RMI_IIOPService">jboss:service=CorbaORB</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- XMBean Persistence                                                   -->
-   <!-- ==================================================================== -->   
-   <mbean code="org.jboss.system.pm.AttributePersistenceService"
-      name="jboss:service=AttributePersistenceService"
-      xmbean-dd="resource:xmdesc/AttributePersistenceService-xmbean.xml">
-      <!-- the AttributePersistenceService is persistent, itself -->
-           
-      <!--
-      <attribute name="AttributePersistenceManagerClass">org.jboss.system.pm.XMLAttributePersistenceManager</attribute>
-      <attribute name="AttributePersistenceManagerConfig">
-         <data-directory>data/xmbean-attrs</data-directory>
-      </attribute>      
-      <attribute name="ApmDestroyOnServiceStop">false</attribute>
-      <attribute name="VersionTag"></attribute>
-      -->
-   </mbean>
-
-   <!-- A Thread pool service -->
-   <mbean code="org.jboss.util.threadpool.BasicThreadPool"
-      name="jboss.system:service=ThreadPool">
-      <attribute name="Name">JBoss System Threads</attribute>
-      <attribute name="ThreadGroupName">System Threads</attribute>
-      <!-- How long a thread will live without any tasks in MS -->
-      <attribute name="KeepAliveTime">60000</attribute>
-      <!-- The max number of threads in the pool -->
-      <attribute name="MaximumPoolSize">10</attribute>
-      <!-- The max number of tasks before the queue is full -->
-      <attribute name="MaximumQueueSize">1000</attribute>
-      <!-- The behavior of the pool when a task is added and the queue is full.
-      abort - a RuntimeException is thrown
-      run - the calling thread executes the task
-      wait - the calling thread blocks until the queue has room
-      discard - the task is silently discarded without being run
-      discardOldest - check to see if a task is about to complete and enque
-         the new task if possible, else run the task in the calling thread
-      -->
-      <attribute name="BlockingMode">run</attribute>
-   </mbean>
-
-   <!-- Preload all custom editors for VMs that don't use the thread
-        context class loader when searching for PropertyEditors. Uncomment
-        if your JDK 1.3.0 VM fails to find JBoss PropertyEditors.
-   <mbean code="org.jboss.varia.property.PropertyEditorManagerService"
-     name="jboss:type=Service,name=BootstrapEditors">
-     <attribute name="BootstrapEditors">
-       java.math.BigDecimal=org.jboss.util.propertyeditor.BigDecimalEditor
-       java.lang.Boolean=org.jboss.util.propertyeditor.BooleanEditor
-       java.lang.Class=org.jboss.util.propertyeditor.ClassEditor
-       java.util.Date=org.jboss.util.propertyeditor.DateEditor
-       java.io.File=org.jboss.util.propertyeditor.FileEditor
-       java.net.InetAddress=org.jboss.util.propertyeditor.InetAddressEditor
-       java.lang.Integer=org.jboss.util.propertyeditor.IntegerEditor
-       javax.management.ObjectName=org.jboss.mx.util.propertyeditor.ObjectNameEditor
-       java.util.Properties=org.jboss.util.propertyeditor.PropertiesEditor
-       [Ljava.lang.String;=org.jboss.util.propertyeditor.StringArrayEditor
-       java.net.URL=org.jboss.util.propertyeditor.URLEditor
-     </attribute>
-   </mbean>
-   -->
-
-   <!-- ==================================================================== -->
-   <!-- Log4j Initialization                                                 -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.logging.Log4jService"
-      name="jboss.system:type=Log4jService,service=Logging"
-	  xmbean-dd="resource:xmdesc/Log4jService-xmbean.xml">
-      <attribute name="ConfigurationURL">resource:log4j.xml</attribute>
-      <!-- Set the org.apache.log4j.helpers.LogLog.setQuiteMode. As of log4j1.2.8
-      this needs to be set to avoid a possible deadlock on exception at the
-      appender level. See bug#696819.
-      -->
-      <attribute name="Log4jQuietMode">true</attribute>
-      <!-- How frequently in seconds the ConfigurationURL is checked for changes -->
-      <attribute name="RefreshPeriod">60</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Active Alarm Table                                                   -->
-   <!-- ==================================================================== -->
-
-   <!--
-      | The ActiveAlarmTable service is a simple JMX notification listener
-      | that maintains a table with the received notifications (alarms).
-      | The alarms can be acknowledged through the jmx or the web console.
-      | Modify the SubscriptionList below to subscribe for any notification
-      | in the system and treat it as an alarm.
-      | The JMXNotificationAppender is a log4j Appender that can be configured
-      | in log4j.xml, that trasforms logging events to JMX notification so they
-      | can be fed back into the table. By storing the WARN or higher level logging
-      | events you can have a quick view of important system faults.
-      |
-      | The following attributes may be set:
-      |
-      | MaxTableSize (default 1000)
-      |  - set an upper limit to the number of stored alarms
-      | LogLevel (default DEBUG)
-      |  - the log level to use for received notification, can be set to NONE
-      | ServerId (default jboss)
-      |  - used to construct unique alarm ids
-      | SubscriptionList
-      |  - subscribe for the notifications to be stored in the table
-
-   <mbean code="org.jboss.monitor.services.ActiveAlarmTable" 
-          name="jboss.monitor:service=ActiveAlarmTable">
-      <attribute name="SubscriptionList">
-         <subscription-list>
-            <mbean name="jboss.monitor:*">
-               <notification type="jboss.alarm"/>
-               <notification type="JBOSS_MONITOR_NOTIFICATION"/>               
-            </mbean>
-            <mbean name="jboss.system:service=Logging,type=JMXNotificationAppender"/>
-         </subscription-list>
-      </attribute>
-   </mbean>
-   -->
-  
-   <!-- ==================================================================== -->
-   <!-- JBoss RMI Classloader - only install when available                  -->
-   <!-- ==================================================================== -->
-   <mbean code="org.jboss.util.property.jmx.SystemPropertyClassValue"
-      name="jboss.rmi:type=RMIClassLoader">
-      <attribute name="Property">java.rmi.server.RMIClassLoaderSpi</attribute>
-      <attribute name="ClassName">org.jboss.system.JBossRMIClassLoader</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Service Binding                                                      -->
-   <!-- ==================================================================== -->
-
-   <!-- Automatically activated when generatting the clustering environment -->
-   <!-- @TESTSUITE_CLUSTER_CONFIG@ -->
-
-   <!--
-      | Binding service manager for port/host mapping. This is a sample
-      | config that demonstrates a JBoss instances with a server name 'ports-01'
-      | loading its bindings from an XML file using the ServicesStoreFactory
-      | implementation returned by the XMLServicesStoreFactory.
-      |
-      | ServerName: The unique name assigned to a JBoss server instance for
-      | lookup purposes. This allows a single ServicesStore to handle mulitiple
-      | JBoss servers.
-      |
-      | StoreURL: The URL string passed to org.jboss.services.binding.ServicesStore
-      | during initialization that specifies how to connect to the bindings store.
-      | StoreFactory: The org.jboss.services.binding.ServicesStoreFactory interface
-      | implementation to create to obtain the ServicesStore instance.
-
-   <mbean code="org.jboss.services.binding.ServiceBindingManager"
-     name="jboss.system:service=ServiceBindingManager">
-     <attribute name="ServerName">ports-01</attribute>
-     <attribute name="StoreURL">${jboss.home.url}/docs/examples/binding-manager/sample-bindings.xml</attribute>
-     <attribute name="StoreFactoryClassName">
-       org.jboss.services.binding.XMLServicesStoreFactory
-     </attribute>
-   </mbean>
-   -->
-
-   <!-- ==================================================================== -->
-   <!-- Class Loading                                                        -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.web.WebService"
-      name="jboss:service=WebService">
-      <attribute name="Port">8083</attribute>
-      <!-- Should non-EJB .class files be downloadable -->
-      <attribute name="DownloadServerClasses">true</attribute>
-      <!-- Should resources other than .class files be downloadable. Both
-         DownloadServerClasses and DownloadResources must be true for resources
-         to be downloadable. This is false by default because its generally a
-         bad idea as server configuration files that container security
-         information can be accessed.
-       -->
-      <attribute name="DownloadResources">false</attribute>
-      <attribute name="Host">${jboss.bind.address}</attribute>
-      <attribute name="BindAddress">${jboss.bind.address}</attribute>
-      <!-- Use the default thread pool for dynamic class loading -->
-      <depends optional-attribute-name="ThreadPool"
-         proxy-type="attribute">jboss.system:service=ThreadPool</depends>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- JNDI                                                                 -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.naming.NamingService"
-      name="jboss:service=Naming"
-      xmbean-dd="resource:xmdesc/NamingService-xmbean.xml">
-      <!-- The call by value mode. true if all lookups are unmarshalled using
-      the caller's TCL, false if in VM lookups return the value by reference.
-      -->
-      <attribute name="CallByValue">false</attribute>
-      <!-- The listening port for the bootstrap JNP service. Set this to -1
-        to run the NamingService without the JNP invoker listening port.
-      -->
-      <attribute name="Port">1099</attribute>
-      <!-- The bootstrap JNP server bind address. This also sets the default
-      RMI service bind address. Empty == all addresses
-       -->
-      <attribute name="BindAddress">${jboss.bind.address}</attribute>
-      <!-- The port of the RMI naming service, 0 == anonymous -->
-      <attribute name="RmiPort">1098</attribute>
-      <!-- The RMI service bind address. Empty == all addresses
-       -->
-      <attribute name="RmiBindAddress">${jboss.bind.address}</attribute>
-      <!-- The thread pool service used to control the bootstrap lookups -->
-      <depends optional-attribute-name="LookupPool"
-         proxy-type="attribute">jboss.system:service=ThreadPool</depends>
-   </mbean>
-
-   <mbean code="org.jboss.naming.JNDIView"
-   	name="jboss:service=JNDIView"
-   	xmbean-dd="resource:xmdesc/JNDIView-xmbean.xml">
-   	<!-- The HANamingService service name -->
-   	<attribute name="HANamingService">jboss:service=HAJNDI</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Security                                                             -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.security.plugins.SecurityConfig"
-      name="jboss.security:service=SecurityConfig">
-      <attribute name="LoginConfig">jboss.security:service=XMLLoginConfig</attribute>
-   </mbean>
-   <mbean code="org.jboss.security.auth.login.XMLLoginConfig"
-      name="jboss.security:service=XMLLoginConfig">
-      <attribute name="ConfigResource">login-config.xml</attribute>
-   </mbean>
-
-   <!-- JAAS security manager and realm mapping -->
-   <mbean code="org.jboss.security.plugins.JaasSecurityManagerService"
-      name="jboss.security:service=JaasSecurityManager">
-      <!-- A flag which indicates whether the SecurityAssociation server mode
-      is set on service creation. This is true by default since the
-      SecurityAssociation should be thread local for multi-threaded server
-      operation.
-      -->
-      <attribute name="ServerMode">true</attribute>
-      <attribute name="SecurityManagerClassName">org.jboss.security.plugins.JaasSecurityManager</attribute>
-      <attribute name="DefaultUnauthenticatedPrincipal">anonymous</attribute>
-      <!-- DefaultCacheTimeout: Specifies the default timed cache policy timeout
-      in seconds.
-      If you want to disable caching of security credentials, set this to 0 to
-      force authentication to occur every time. This has no affect if the
-      AuthenticationCacheJndiName has been changed from the default value.
-      -->
-      <attribute name="DefaultCacheTimeout">1800</attribute>
-      <!-- DefaultCacheResolution: Specifies the default timed cache policy
-      resolution in seconds. This controls the interval at which the cache
-      current timestamp is updated and should be less than the DefaultCacheTimeout
-      in order for the timeout to be meaningful. This has no affect if the
-      AuthenticationCacheJndiName has been changed from the default value.
-      -->
-      <attribute name="DefaultCacheResolution">60</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Transactions                                                         -->
-   <!-- ==================================================================== -->
-   <!-- The configurable Xid factory.  For use with Oracle, set pad to true -->
-   <mbean code="org.jboss.tm.XidFactory"
-      name="jboss:service=XidFactory">
-      <!--attribute name="Pad">true</attribute-->
-   </mbean>
-
-   <!--
-      | The fast in-memory transaction manager.
-    
-   <mbean code="org.jboss.tm.TransactionManagerService"
-      name="jboss:service=TransactionManager"
-      xmbean-dd="resource:xmdesc/TransactionManagerService-xmbean.xml">
-      <attribute name="TransactionTimeout">300</attribute>
-      <!- set to false to disable transaction demarcation over IIOP ->
-      <attribute name="GlobalIdsEnabled">true</attribute>
-      <depends optional-attribute-name="XidFactory">jboss:service=XidFactory</depends>
-
-      <!- Transaction Integrity Checking ->
-      <!- Force a rollback if another thread is associated with the transaction at commit ->
-      <!-depends optional-attribute-name="TransactionIntegrityFactory" 
-               proxy-type="org.jboss.tm.integrity.TransactionIntegrityFactory">
-         <mbean code="org.jboss.tm.integrity.FailIncompleteTransaction"
-                name="jboss:service=TransactionManager,plugin=TransactionIntegrity"/>
-      </depends->
-   </mbean-->
-   
-   <mbean code="com.arjuna.ats.jbossatx.jta.TransactionManagerService"
-      name="jboss:service=TransactionManager">
-      <attribute name="TransactionTimeout">300</attribute>
-   </mbean>
-   
-   <!--
-      | UserTransaction support.
-    -->
-   <mbean code="org.jboss.tm.usertx.server.ClientUserTransactionService"
-      name="jboss:service=ClientUserTransaction"
-      xmbean-dd="resource:xmdesc/ClientUserTransaction-xmbean.xml">
-      <depends>
-         <mbean code="org.jboss.invocation.jrmp.server.JRMPProxyFactory"
-            name="jboss:service=proxyFactory,target=ClientUserTransactionFactory">
-            <attribute name="InvokerName">jboss:service=invoker,type=jrmp</attribute>
-            <attribute name="TargetName">jboss:service=ClientUserTransaction</attribute>
-            <attribute name="JndiName">UserTransactionSessionFactory</attribute>
-            <attribute name="ExportedInterface">org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory</attribute>
-            <attribute name="ClientInterceptors">
-               <interceptors>
-                  <interceptor>org.jboss.proxy.ClientMethodInterceptor</interceptor>
-                  <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
-               </interceptors>
-            </attribute>
-            <depends>jboss:service=invoker,type=jrmp</depends>
-         </mbean>
-      </depends>
-      <depends optional-attribute-name="TxProxyName">
-         <mbean code="org.jboss.invocation.jrmp.server.JRMPProxyFactory"
-            name="jboss:service=proxyFactory,target=ClientUserTransaction">
-            <attribute name="InvokerName">jboss:service=invoker,type=jrmp</attribute>
-            <attribute name="TargetName">jboss:service=ClientUserTransaction</attribute>
-            <attribute name="JndiName"></attribute>
-            <attribute name="ExportedInterface">org.jboss.tm.usertx.interfaces.UserTransactionSession</attribute>
-            <attribute name="ClientInterceptors">
-               <interceptors>
-                  <interceptor>org.jboss.proxy.ClientMethodInterceptor</interceptor>
-                  <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
-               </interceptors>
-            </attribute>
-            <depends>jboss:service=invoker,type=jrmp</depends>
-         </mbean>
-      </depends>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Invokers to the JMX node                                             -->
-   <!-- ==================================================================== -->
-
-   <!-- RMI/JRMP invoker -->
-   <mbean code="org.jboss.invocation.jrmp.server.JRMPInvoker"
-      name="jboss:service=invoker,type=jrmp">
-      <attribute name="RMIObjectPort">4444</attribute>
-      <attribute name="ServerAddress">${jboss.bind.address}</attribute>
-      <!--
-      <attribute name="RMIClientSocketFactory">custom</attribute>
-      <attribute name="RMIServerSocketFactory">custom</attribute>
-      <attribute name="RMIServerSocketAddr">custom</attribute>
-      <attribute name="SecurityDomain">ssl-domain-name</attribute>
-      -->
-      <depends>jboss:service=TransactionManager</depends>
-   </mbean>
-
-   <mbean code="org.jboss.invocation.local.LocalInvoker"
-      name="jboss:service=invoker,type=local">
-
-      <depends>jboss:service=TransactionManager</depends>
-   </mbean>
-
-   <mbean code="org.jboss.invocation.pooled.server.PooledInvoker"
-      name="jboss:service=invoker,type=pooled">
-      <attribute name="NumAcceptThreads">1</attribute>
-      <attribute name="MaxPoolSize">300</attribute>
-      <attribute name="ClientMaxPoolSize">300</attribute>
-      <attribute name="SocketTimeout">60000</attribute>
-      <attribute name="ServerBindAddress">${jboss.bind.address}</attribute>
-      <attribute name="ServerBindPort">4445</attribute>
-      <attribute name="ClientConnectAddress">${jboss.bind.address}</attribute>
-      <attribute name="ClientConnectPort">0</attribute>
-      <attribute name="ClientRetryCount">1</attribute>
-      <attribute name="EnableTcpNoDelay">false</attribute>
-
-      <!-- Customized socket factory attributes
-      <attribute name="ClientSocketFactoryName">custom.client.factory</attribute>
-      <attribute name="ServerSocketFactoryName">custom.server.factory</attribute>
-      <attribute name="SslDomain">java:/jaas/pooledInvoker</attribute>
-      -->
-      <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Monitoring and Management                                            -->
-   <!-- ==================================================================== -->
-
-   <!-- Uncomment to enable JMX monitoring of the bean cache
-   <mbean code="org.jboss.monitor.BeanCacheMonitor"
-          name="jboss.monitor:name=BeanCacheMonitor"/>
-   -->
-
-   <!-- Uncomment to enable JMX monitoring of the entity bean locking
-   <mbean code="org.jboss.monitor.EntityLockMonitor"
-          name="jboss.monitor:name=EntityLockMonitor"/>
-   -->
-
-   <!-- ==================================================================== -->
-   <!-- An MBean that is a registry for JDBC type-mapping metadata           -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.ejb.plugins.cmp.jdbc.metadata.MetaDataLibrary"
-      name="jboss.jdbc:service=metadata"/>
-
-   <!-- ==================================================================== -->
-   <!-- Deployment Scanning                                                  -->
-   <!-- ==================================================================== -->
-
-   <!-- An mbean for hot deployment/undeployment of archives.
-   -->
-   <mbean code="org.jboss.deployment.scanner.URLDeploymentScanner"
-      name="jboss.deployment:type=DeploymentScanner,flavor=URL">
-
-      <!-- Uncomment (and comment/remove version below) to enable usage of the
-        DeploymentCache
-      <depends optional-attribute-name="Deployer">jboss.deployment:type=DeploymentCache</depends>
-      -->
-      <depends optional-attribute-name="Deployer">jboss.system:service=MainDeployer</depends>
-
-      <!-- The URLComparator can be used to specify a deployment ordering
-           for deployments found in a scanned directory.  The class specified
-           must be an implementation of java.util.Comparator, it must be able
-           to compare two URL objects, and it must have a no-arg constructor.
-           Two deployment comparators are shipped with JBoss:
-             - org.jboss.deployment.DeploymentSorter
-               Sorts by file extension, as follows:
-                 "sar", "service.xml", "rar", "jar", "war", "wsr", "ear", "zip",
-                 "*"
-             - org.jboss.deployment.scanner.PrefixDeploymentSorter
-               If the name portion of the url begins with 1 or more digits, those
-               digits are converted to an int (ignoring leading zeroes), and
-               files are deployed in that order.  Files that do not start with
-               any digits will be deployed first, and they will be sorted by
-               extension as above with DeploymentSorter.
-      -->
-      <attribute name="URLComparator">org.jboss.deployment.DeploymentSorter</attribute>
-      
-      <!--
-      <attribute name="URLComparator">org.jboss.deployment.scanner.PrefixDeploymentSorter</attribute>
-      -->
-
-      <!-- The FilterInstance specifies a URLLister.URLFilter for scanned
-           directories. This DeploymentFilter is initialized with the given
-           prefixes, suffixes and matches that define which URLs should be
-           ignored.
-      -->
-      <attribute name="FilterInstance"
-         attributeClass="org.jboss.deployment.scanner.DeploymentFilter"
-         serialDataType="javaBean">
-         <!-- Files starting with theses strings are ignored -->
-         <property name="prefixes">#,%,\,,.,_$</property>
-         <!-- Files ending with theses strings are ignored -->
-         <property name="suffixes">#,$,%,~,\,v,.BAK,.bak,.old,.orig,.tmp,.rej,.sh</property>
-         <!-- Files matching with theses strings are ignored -->
-         <property name="matches">.make.state,.nse_depinfo,CVS,CVS.admin,RCS,RCSLOG,SCCS,TAGS,core,tags</property>
-      </attribute>
-
-      <!-- Frequency in milliseconds to rescan the URLs for changes -->
-      <attribute name="ScanPeriod">5000</attribute>
-      
-      <!-- A flag to disable the scans -->
-      <attribute name="ScanEnabled">true</attribute>
-
-      <!-- URLs are comma separated and resolve relative to the server home URL
-         unless the given path is absolute. If the URL ends in "/" it is
-         considered a collection and scanned, otherwise it is simply deployed;
-         this follows RFC2518 convention and allows discrimination between
-         collections and directories that are simply unpacked archives.
-
-         URLs may be local (file:) or remote (http:). Scanning is supported
-         for remote URLs but unpacked deployment units are not.
-
-         Example URLs:
-            deploy/
-                 scans ${jboss.server.url}/deploy/, which is local or remote
-                 depending on the URL used to boot the server
-            ${jboss.server.home}/deploy/
-                 scans ${jboss.server.home)/deploy, which is always local
-            file:/var/opt/myapp.ear
-                 deploy myapp.ear from a local location
-            file:/var/opt/apps/
-                 scans the specified directory
-            http://www.test.com/netboot/myapp.ear
-                 deploys myapp.ear from a remote location
-            http://www.test.com/netboot/apps/
-                 scans the specified WebDAV location
-       -->
-      <attribute name="URLs">
-         deploy/
-      </attribute>
-
-      <!-- Indicates if the scanner should recursively scan directories that
-      contain no "." in their names. This can be used to group applications
-      and services that must be deployed and that have the same
-      logical function in the same directory i.e.
-        deploy/JMX/
-        deploy/JMS/
-        ...
-      -->
-      <attribute name="RecursiveSearch">True</attribute>
-
-   </mbean>
-
-</server>

Copied: branches/Branch_1_0/lib/jbossts/jboss-service.xml (from rev 1684, branches/Branch_1_0_XARecovery/lib/jbossts/jboss-service.xml)

Deleted: branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml
===================================================================
--- branches/Branch_1_0_XARecovery/lib/jbossts/jbossjta-properties.xml	2006-12-02 05:55:38 UTC (rev 1684)
+++ branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml	2006-12-02 14:14:09 UTC (rev 1686)
@@ -1,278 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<transaction-service>
-    <properties depends="common" name="arjuna">
-        <!--
-        Transaction Reaper Timeout (default is 120000 microseconds).
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.coordinator.txReaperTimeout" value="120000"/>
-        <!--
-        Transaction Reaper Mode, can be: NORMAL or DYNAMIC (default is NORMAL).
-      -->
-        <property name="com.arjuna.ats.arjuna.coordinator.txReaperMode" value="NORMAL"/>
-        <!--
-        (default is NO)
-      -->
-        <property name="com.arjuna.ats.arjuna.coordinator.asyncCommit" value="NO"/>
-        <!--
-        (default is NO)
-      -->
-        <property name="com.arjuna.ats.arjuna.coordinator.asyncPrepare" value="NO"/>
-        <!--
-        (default is YES)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.coordinator.commitOnePhase" value="YES"/>
-        <!--
-        (default is defaultStore)
-      -->
-        <property name="com.arjuna.ats.arjuna.objectstore.localOSRoot" value="defaultStore"/>
-        <!--
-        default is under user.home - must be writeable!)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.objectStoreDir" value="PutObjectStoreDirHere"/>
-        <!--
-        (default is ON)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.objectStoreSync" value="ON"/>
-        <!--
-        (default is ShadowNoFileLockStore)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.objectStoreType" value="ShadowNoFileLockStore"/>
-        <!--
-        (default is 255)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.hashedDirectories" value="255"/>
-        <!--
-        (default is ON)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.transactionSync" value="ON"/>
-        <!--
-        (Must be unique across all Arjuna instances.)
-      -->
-        <property name="com.arjuna.ats.arjuna.xa.nodeIdentifier" value="1"/>
-        <!-- property
-        name="com.arjuna.ats.arjuna.coordinator.actionStore"
-		value="HashedActionStore"
-		value="JDBCActionStore"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcTxDbAccess"
-		value="JDBCAccess"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.objectStoreType"
-		value="ShadowNoFileLockStore"
-		value="JDBCStore"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcUserDbAccess"
-		value="JDBCAccess"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcPoolSizeInitial"
-		value="1"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcPoolSizeMaximum"
-		value="1"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcPoolPutConnections"
-		value="false"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.internal.arjuna.objectstore.cacheStore.size"
-		value=""
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.internal.arjuna.objectstore.cacheStore.period"
-		value=""
-      -->
-        <!--
-        The location for creating temporary files, e.g., Uids.
-        Default is under user.home.
-        IMPORTANT: make sure the directory is lockable, e.g., /tmp on Unix
-        may not be!
-      -->
-        <!--
-        <property
-          name="com.arjuna.ats.arjuna.common.varDir"
-          value="var"/>
-      -->
-    </properties>
-    <properties depends="arjuna" name="recoverymanager">
-        <!--
-        Properties used only by the RecoveryManager.
-      -->
-        <!--
-        Periodic recovery settings.
-        Time values in this section are in seconds.
-      -->
-        <!--
-        Interval in seconds between initiating the periodic recovery modules.
-        Default is 120 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.periodicRecoveryPeriod" value="120"/>
-        <!--
-        Interval in seconds between first and second pass of periodic recovery.
-        Default is 10 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.recoveryBackoffPeriod" value="10"/>
-        
-        <!--
-        Expired entry removal
-      -->
-        <!--
-        Expiry scanners to use (order of invocation is random).
-        Names must begin with "com.arjuna.ats.arjuna.recovery.expiryScanner"
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScannerTransactionStatusManager" value="com.arjuna.ats.internal.arjuna.recovery.ExpiredTransactionStatusManagerScanner"/>
-        <!--
-        Interval, in hours, between running the expiry scanners.
-        This can be quite long. The absolute value determines the interval -
-        if the value is negative, the scan will NOT be run until after one
-        interval has elapsed. If positive the first scan will be immediately
-        after startup. Zero will prevent any scanning.
-        Default  = 12 = run immediately, then every 12 hours.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScanInterval" value="12"/>
-        <!--
-        Age, in hours, for removal of transaction status manager item.
-        This should be longer than any ts-using process will remain running.
-        Zero = Never removed.  Default is 12.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerExpiryTime" value="12"/>
-        <!--
-        Use this to fix the port on which the TransactionStatusManager listens,
-        The default behaviour is to use any free port.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerPort" value="0"/>
-        <!--
-        Properties used only by the RecoveryManager.
-      -->
-        <!--
-        Periodic recovery settings.
-        Time values in this section are in seconds.
-      -->
-        <!--
-        Interval in seconds between initiating the periodic recovery modules.
-        Default is 120 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.periodicRecoveryPeriod" value="120"/>
-        <!--
-        Interval in seconds between first and second pass of periodic recovery.
-        Default is 10 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.recoveryBackoffPeriod" value="10"/>
-        <!--
-        Periodic recovery modules to use.  Invoked in sort-order of names.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.recoveryExtension1" value="com.arjuna.ats.internal.jta.recovery.arjunacore.XARecoveryModule"/>
-        <!--
-        Expired entry removal
-      -->
-        <!--
-        Expiry scanners to use (order of invocation is random).
-        Names must begin with "com.arjuna.ats.arjuna.recovery.expiryScanner"
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScannerTransactionStatusManager" value="com.arjuna.ats.internal.arjuna.recovery.ExpiredTransactionStatusManagerScanner"/>
-        <!--
-        Interval, in hours, between running the expiry scanners.
-        This can be quite long. The absolute value determines the interval -
-        if the value is negative, the scan will NOT be run until after one
-        interval has elapsed. If positive the first scan will be immediately
-        after startup. Zero will prevent any scanning.
-        Default  = 12 = run immediately, then every 12 hours.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScanInterval" value="12"/>
-        <!--
-        Age, in hours, for removal of transaction status manager item.
-        This should be longer than any ts-using process will remain running.
-        Zero = Never removed.  Default is 12.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerExpiryTime" value="12"/>
-        <!--
-        Use this to fix the port on which the TransactionStatusManager listens,
-        The default behaviour is to use any free port.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerPort" value="0"/>
-    </properties>
-    <properties name="common">
-        <!-- CLF 2.0 properties -->
-        <property name="com.arjuna.common.util.logging.DebugLevel"
-            type="System" value="0x00000000"/>
-        <property name="com.arjuna.common.util.logging.FacilityLevel"
-            type="System" value="0xffffffff"/>
-        <property name="com.arjuna.common.util.logging.VisibilityLevel"
-            type="System" value="0xffffffff"/>
-        <property name="com.arjuna.common.util.logger" type="System" value="log4j"/>
-    </properties>
-    <properties depends="arjuna" name="txoj">
-        <!--
-        (default is LockStore of installation - must be writeable!)
-      -->
-        <!--
-        <property
-          name="com.arjuna.ats.txoj.lockstore.lockStoreDir"
-          value="LockStore"/>
-      -->
-        <!--
-        (default is BasicLockStore)
-      -->
-        <property name="com.arjuna.ats.txoj.lockstore.lockStoreType" value="BasicLockStore"/>
-        <!--
-        (default is NO)
-      -->
-        <property name="com.arjuna.ats.txoj.lockstore.multipleLockStore" value="NO"/>
-        <!--
-        (default is YES)
-      -->
-        <property name="com.arjuna.ats.txoj.lockstore.singleLockStore" value="YES"/>
-        <!--
-        (default is YES)
-      -->
-        <property
-            name="com.arjuna.ats.txoj.lockstore.allowNestedLocking" value="YES"/>
-    </properties>
-    <properties depends="arjuna" name="jta">
-        <property
-            name="com.arjuna.ats.jta.recovery.XAResourceRecovery.JBMESSAGING" value="org.jboss.jms.recovery.JMSProviderXAResourceRecovery"/>
-        <!--
-        Support subtransactions in the JTA layer?
-        Default is NO.
-      -->
-        <property name="com.arjuna.ats.jta.supportSubtransactions" value="NO"/>
-        <property name="com.arjuna.ats.jta.jtaTMImplementation" value="com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionManagerImple"/>
-        <!--
-			com.arjuna.ats.internal.jta.transaction.jts.TransactionManagerImple
-			-->
-        <property name="com.arjuna.ats.jta.jtaUTImplementation" value="com.arjuna.ats.internal.jta.transaction.arjunacore.UserTransactionImple"/>
-        <!--
-			com.arjuna.ats.internal.jta.transaction.jts.UserTransactionImple
-			-->
-    </properties>
-    <properties depends="jta" name="jdbc">
-        <!--
-           property name="com.arjuna.ats.jdbc.isolationLevel" value="TRANSACTION_SERIALIZABLE"/>
-        -->
-    </properties>
-</transaction-service>

Copied: branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml (from rev 1684, branches/Branch_1_0_XARecovery/lib/jbossts/jbossjta-properties.xml)

Copied: branches/Branch_1_0/src/main/org/jboss/jms/recovery (from rev 1684, branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/recovery)

Deleted: branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java
===================================================================
--- branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java	2006-12-02 05:55:38 UTC (rev 1684)
+++ branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -1,100 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.jms.recovery;
-
-import javax.transaction.xa.XAResource;
-
-import org.jboss.logging.Logger;
-
-import com.arjuna.ats.jta.recovery.XAResourceRecovery;
-
-/**
- * JMS Provider Adapter based recovery.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @author <a href="juha at jboss.com">Juha Lindfors</a>
- *
- * @version $Revision: 1.1 $
- */
-public class JMSProviderXAResourceRecovery implements XAResourceRecovery
-{
-   private boolean trace = log.isTraceEnabled();
-
-	private static final Logger log = Logger.getLogger(JMSProviderXAResourceRecovery.class);
-
-   /** The jms provider name */
-   private String providerName;
-
-   /** The delegate XAResource */
-   private XAResourceWrapper wrapper;
-
-   /** Whether the XAResource is working */
-   private boolean working = false;
-
-   public JMSProviderXAResourceRecovery()
-   {
-      if(trace)
-			log.trace("Constructing JMSProviderXAResourceRecovery..");
-   }
-
-   public boolean initialise(String p)
-   {
-      if(trace)
-			log.trace("Initialising JMSProviderXAResourceRecovery..");
-
-      this.providerName = p;
-      return true;
-   }
-
-   public boolean hasMoreResources()
-   {
-      // If the XAResource is already working
-      if (working)
-         return false;
-
-      // Have we initialized yet?
-      if (wrapper == null)
-      {
-         wrapper = new XAResourceWrapper();
-         wrapper.setProviderName(providerName);
-      }
-
-      // Test the connection
-      try
-      {
-         wrapper.getTransactionTimeout();
-         working = true;
-      }
-      catch (Exception ignored)
-      {
-         //System.out.println(ignored.getMessage());
-      }
-
-      // This will return false until we get a successful connection
-      return working;
-   }
-
-   public XAResource getXAResource()
-   {
-      return wrapper;
-   }
-}

Copied: branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java (from rev 1684, branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java)

Deleted: branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java
===================================================================
--- branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java	2006-12-02 05:55:38 UTC (rev 1684)
+++ branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -1,133 +0,0 @@
-package org.jboss.jms.recovery;
-
-import java.sql.SQLException;
-import javax.jms.XAConnection;
-import javax.jms.XAConnectionFactory;
-import javax.jms.XASession;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import javax.transaction.xa.XAResource;
-
-import org.jboss.logging.Logger;
-
-import com.arjuna.ats.jta.recovery.XAResourceRecovery;
-
-public class MessagingXAResourceRecovery implements XAResourceRecovery {
-
-	private boolean trace = log.isTraceEnabled();
-
-	private static final Logger log = Logger.getLogger(MessagingXAResourceRecovery.class);
-
-	private boolean working = false;
-
-	private XAResource xaRes = null;
-
-	private String xaConnFactory = null;
-
-	public MessagingXAResourceRecovery() {
-	}
-
-	public XAResource getXAResource() throws SQLException {
-		if(trace)
-			log.trace("returning the xaresource "+xaRes);
-		return xaRes;
-	}
-
-	/**
-	 * This method returns the Messaging XAResource reference.
-	 * You have to pass the jndi name of the XAConnectionFactory
-	 * via the JBossTS RecoveryManager's properties
-	 * @return
-	 */
-	public XAResource initXAResource() {
-		if(trace)
-			log.trace("Initialising xaresource..");
-		try {
-			Context ctx = new InitialContext();
-
-			XAConnectionFactory cf = (XAConnectionFactory) ctx
-					.lookup(xaConnFactory);
-
-			XAConnection xaConn = cf.createXAConnection();
-
-			XASession session = xaConn.createXASession();
-			xaRes = session.getXAResource();
-
-			if(trace)
-				log.trace("Found the xares: "+xaRes);
-
-		} catch (Exception e) {
-			// You may get this exception when the messaging server
-			// is not fully booted up. Nothing to worry, it'll keep
-			// trying until successful.
-			log.warn("XAConnectionFactory is not found. \n" +
-					"The messaging server is not yet initialized.\n" +
-					"we'll try again once server is fully back");
-
-		}
-
-		return xaRes;
-	}
-
-	/**
-	 * This method is used to pass any
-	 * intialisation parameters to this
-	 * class
-	 * @param param
-	 * @return
-	 * @throws SQLException
-	 */
-	public boolean initialise(String param) throws SQLException
-  {
-		if(trace)
-			log.trace("Passed in parameter: "+param);
-
-		if(param != null)
-		{
-			// parama is in the form of name=value
-			String value = param.substring(param.indexOf("=")+1);
-
-			if(trace)
-				log.trace("The connection factory is "+value);
-
-      xaConnFactory = value;
-		}
-		else
-		{
-			log.debug("The XA connection factory parameter is null. " +
-					"Using the default 'XAConnectionFactory'");
-
-      xaConnFactory = "XAConnectionFactory";
-		}
-		return true;
-	}
-
-	/**
-	 * This method checks whether there's an xa resource available
-	 *
-	 * @return
-	 */
-	public boolean hasMoreResources() {
-
-		if (working)
-			return false;
-
-		if (xaRes == null) {
-			xaRes = initXAResource();
-		}
-
-		// test the resource
-		try {
-
-			xaRes.getTransactionTimeout();
-
-			working = true;
-
-		} catch (Exception ignored) {
-
-			// ignore this exception
-		}
-
-		return working;
-	}
-}

Copied: branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java (from rev 1684, branches/Branch_1_0_XARecovery/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java)

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -69,6 +69,8 @@
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * 
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -218,7 +220,7 @@
          destinationJNDIMapper.start();
          securityStore.start();
          connFactoryJNDIMapper.start();
-         txRepository.start(persistenceManagerDelegate);
+         txRepository.start(persistenceManagerDelegate, messageStoreDelegate);
          txRepository.loadPreparedTransactions();
          
          //TODO Make block size configurable

Modified: branches/Branch_1_0/src/main/org/jboss/jms/tx/MessagingXAResource.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/tx/MessagingXAResource.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/jms/tx/MessagingXAResource.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -28,6 +28,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.tx.XidImpl;
 
 /**
  * An XAResource implementation.
@@ -38,6 +39,7 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * 
  * Parts based on JBoss MQ XAResource implementation by:
  * 
@@ -112,7 +114,12 @@
    public void commit(Xid xid, boolean onePhase) throws XAException
    {
       if (trace) { log.trace(this + " committing " + xid + (onePhase ? " (one phase)" : " (two phase)")); }
-      
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       rm.commit(xid, onePhase, connection);
 
       // leave the session in a 'clean' state, the currentTxId will be set when the XAResource will
@@ -125,6 +132,11 @@
    {
       if (trace) { log.trace(this + " ending " + xid + ", flags: " + flags); }
 
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       synchronized (this)
       {
          switch (flags)
@@ -148,11 +160,22 @@
    public void forget(Xid xid) throws XAException
    {
       if (trace) { log.trace(this + " forgetting " + xid + " (currently an NOOP)"); }
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
    }
 
    public int prepare(Xid xid) throws XAException
    {
       if (trace) { log.trace(this + " preparing " + xid); }
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       return rm.prepare(xid, connection);
    }
 
@@ -167,6 +190,11 @@
    {
       if (trace) { log.trace(this + " rolling back " + xid); }
 
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       // TODO Hmmm on rollback should we also stop and start the consumers to remove any transient
       // messages, like we do on local session rollback??
       
@@ -177,6 +205,11 @@
    {
       if (trace) { log.trace(this + " starting " + xid + ", flags: " + flags); }
       
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       boolean convertTx = false;
       
       if (sessionState.getCurrentTxId() != null)

Modified: branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -49,7 +49,9 @@
  * This is one instance of ResourceManager per JMS server. The ResourceManager instances are managed
  * by ResourceManagerFactory.
  * 
- * @author <a href="mailto:tim.fox at jboss.com>Tim Fox</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * 
  * Parts adapted from SpyXAResourceManager by:
  *
@@ -127,8 +129,6 @@
     * 
     * @param xid - The id of the transaction to add the message to
     * @param ackInfo Information describing the acknowledgement
-    * @param sessionState - the session the ack is in - we need this so on rollback we can tell each session
-    * to redeliver it's messages
     */
    public void addAck(Object xid, AckInfo ackInfo) throws JMSException
    {
@@ -452,6 +452,17 @@
          try
          {
             Xid[] txs = conn.getPreparedTransactions();
+
+            //populate with TxState --MK
+            for(int i = 0; i < txs.length;i++)
+            {
+               TxState tx = new TxState();
+
+               tx.setState(TxState.TX_PREPARED);
+
+               transactions.put(txs[i], tx);
+            }
+
             return txs;
          }
          catch (JMSException e)

Modified: branches/Branch_1_0/src/main/org/jboss/jms/tx/TransactionRequest.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/tx/TransactionRequest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/jms/tx/TransactionRequest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -31,7 +31,7 @@
 import org.jboss.messaging.core.tx.XidImpl;
 
 /**
- * This class contians all the data needed to perform a JMS transaction.
+ * This class contains all the data needed to perform a JMS transaction.
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * 

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -66,6 +66,7 @@
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.core.tx.XidImpl;
+import org.jboss.messaging.core.tx.PreparedTxInfo;
 import org.jboss.messaging.util.Util;
 import org.jboss.serial.io.JBossObjectInputStream;
 import org.jboss.serial.io.JBossObjectOutputStream;
@@ -81,6 +82,8 @@
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  *
  * @version <tt>1.1</tt>
  *
@@ -210,7 +213,16 @@
    
    protected String selectAllChannels = "SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE";
    
-        
+   //RECOVERY --MK
+   protected String selectMessageIdForRef = "SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE "
+	      + "WHERE TRANSACTIONID = ? AND STATE = '+' ";
+
+   protected String selectMessageIdForAck = "SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE "
+	      + "WHERE TRANSACTIONID = ? AND STATE = '-' ";
+
+   protected String selectChannelId = "SELECT CHANNELLID FROM JMS_MESSAGE_REFERENCE "
+	      + "WHERE TRANSACTIONID = ?";
+
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------
@@ -619,8 +631,117 @@
       }
    }
    
-   
-   
+   public ChannelMapper getChannelMapperReference()
+   {
+	   return cm;
+   }
+
+   public long getMessageIdForRef(long transactionId) throws Exception
+   {
+	   return getId(selectMessageIdForRef, transactionId, 1);
+   }
+   public long getMessageIdForAck(long transactionId) throws Exception
+   {
+	   return getId(selectMessageIdForAck, transactionId, 1);
+   }
+
+   public long getChannelId(long transactionId) throws Exception
+   {
+	   return getId(selectChannelId, transactionId, 1);
+   }
+
+
+   /**
+    * This method associates a TransactionCallback to the
+    * resurrected transaction. This method is called from
+    * the TransactionRepository once a transaction object
+    * is resurrected.
+    */
+   public void associateTxCallbackToPreparedTx(Transaction tx)
+   {
+	  TransactionCallback callback = (TransactionCallback) tx.getKeyedCallback(this);
+
+      if (callback == null)
+      {
+         callback = new TransactionCallback(tx);
+
+         tx.addKeyedCallback(callback, this);
+      }
+   }
+
+   /**
+    * MK
+    * Load the message refs for the corresponding tx id
+    */
+   public long getId(String sqlQuery, long transactionId, int index) throws Exception
+   {
+      if (trace) { log.trace("loading references for tx [" + transactionId + "]"); }
+
+      Connection conn = null;
+      PreparedStatement ps = null;
+      ResultSet rs = null;
+      TransactionWrapper wrap = new TransactionWrapper();
+      long messageId = 0;
+
+      try
+      {
+         conn = ds.getConnection();
+
+         ps = conn.prepareStatement(sqlQuery);
+
+         ps.setLong(1, transactionId);
+
+         rs = ps.executeQuery();
+
+         while(rs.next())
+         {
+        	   messageId = rs.getLong(index);
+         }
+
+         return messageId;
+      }
+      catch (Exception e)
+      {
+         wrap.exceptionOccurred();
+         throw e;
+      }
+      finally
+      {
+         if (rs != null)
+         {
+            try
+            {
+               rs.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (ps != null)
+         {
+            try
+            {
+               ps.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         wrap.end();
+      }
+   }
+
+
    /*
     * Retrieve a List of messages corresponding to the specified List of message ids.
     * The implementation here for HSQLDB does this by using a PreparedStatment with an IN clause
@@ -2030,35 +2151,43 @@
 //   }
    
    
-   
    public List retrievePreparedTransactions() throws Exception
    {
+      /* Note the API change for 1.0.2 XA Recovery -- List now contains instances of PreparedTxInfo<TxId, Xid>
+       * instead of direct Xids [JPL] */
+
       Connection conn = null;
       Statement st = null;
       ResultSet rs = null;
+      PreparedTxInfo txInfo = null;
       TransactionWrapper wrap = new TransactionWrapper();
-      
+
       try
       {
          List transactions = new ArrayList();
-         
+
          conn = ds.getConnection();
-         
+
          st = conn.createStatement();
          rs = st.executeQuery(selectPreparedTransactions);
-         
+
          while (rs.next())
          {
+           	//get the existing tx id --MK START
+            long txId = rs.getLong(1);
+
             byte[] branchQual = rs.getBytes(2);
             int formatId = rs.getInt(3);
             byte[] globalTxId = rs.getBytes(4);
             Xid xid = new XidImpl(branchQual, formatId, globalTxId);
-            
-            transactions.add(xid);
+
+            // create a tx info object with the result set detailsdetails
+            txInfo = new PreparedTxInfo(txId, xid);
+            transactions.add(txInfo);
          }
-         
+
          return transactions;
-         
+
       }
       catch (Exception e)
       {
@@ -2100,35 +2229,35 @@
          wrap.end();
       }
    }
-   
+
    /*
-    
+
     Reference counting code commented out until 1.2
-    
+
     public int getMessageReferenceCount(Serializable messageID) throws Exception
     {
     Connection conn = null;
     PreparedStatement ps = null;
     ResultSet rs = null;
     TransactionWrapper wrap = new TransactionWrapper();
-    
+
     try
     {
     conn = ds.getConnection();
-    
+
     ps = conn.prepareStatement(selectReferenceCount);
     ps.setString(1, (String)messageID);
-    
+
     rs = ps.executeQuery();
-    
+
     int count = 0;
     if (rs.next())
     {
     count = rs.getInt(1);
     }
-    
+
     if (trace) { log.trace(JDBCUtil.statementToString(selectReferenceCount, messageID) + " returned " + (count == 0 ? "no rows" : Integer.toString(count))); }
-    
+
     return count;
     }
     catch (Exception e)
@@ -2168,7 +2297,7 @@
     wrap.end();
     }
     }
-    
+
     */
    
    // Public --------------------------------------------------------
@@ -2497,6 +2626,11 @@
       
       //Other
       selectAllChannels = sqlProperties.getProperty("SELECT_ALL_CHANNELS", selectAllChannels);
+
+      //recovery
+      selectMessageIdForRef = sqlProperties.getProperty("SELECT_MESSAGEID_FOR_REFS",selectMessageIdForRef);
+      selectMessageIdForAck = sqlProperties.getProperty("SELECT_MESSAGEID_FOR_ACKS",selectMessageIdForAck);
+      selectChannelId  = sqlProperties.getProperty("SELECT_CHANNEL_ID",selectChannelId );
    }
    
    protected TransactionCallback getCallback(Transaction tx)
@@ -3817,9 +3951,8 @@
          ps.setBytes(2, xid.getBranchQualifier());
          ps.setInt(3, formatID);
          ps.setBytes(4, xid.getGlobalTransactionId());
-         
+
          rows = ps.executeUpdate();
-         
       }
       finally
       {

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/MessageStore.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/MessageStore.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/MessageStore.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -29,7 +29,7 @@
    /**
     * A non-recoverable message store cannot guarantee recoverability for reliable messages so by
     * default it won't accept reliable messages. If specifically configured to do so, it must
-    * unequivocally indicates that it accepts reliable messages by returning true as result of this
+    * unequivocally indicate that it accepts reliable messages by returning true as result of this
     * method.
     *
     * A recoverable message store must always accept reliable messages, so this method must always

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -25,23 +25,33 @@
 
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.jms.server.plugin.contract.ChannelMapper;
 
 /**
  * The interface to the persistence manager
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ *
  * @version <tt>1.1</tt>
  *
  * PersistenceManager.java,v 1.1 2006/02/22 17:33:42 timfox Exp
  */
 public interface PersistenceManager extends ServerPlugin
 {
-   /*
-    * Currently unused but will be used for XA recovery
-    */
    List retrievePreparedTransactions() throws Exception;
-      
+
+   ChannelMapper getChannelMapperReference();
+
+   long getMessageIdForRef(long transactionId) throws Exception;
+
+   long getMessageIdForAck(long transactionId) throws Exception;
+
+   long getChannelId(long transactionId) throws Exception;
+
+	void associateTxCallbackToPreparedTx(Transaction tx);
+
    void resetLoadedStatus(long channelID) throws Exception;
       
    void addReference(long channelID, MessageReference ref, Transaction tx) throws Exception;

Copied: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/PreparedTxInfo.java (from rev 1684, branches/Branch_1_0_XARecovery/src/main/org/jboss/messaging/core/tx/PreparedTxInfo.java)

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -25,11 +25,20 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-
 import javax.transaction.xa.Xid;
 
+import org.jboss.jms.destination.JBossDestination;
+import org.jboss.jms.server.plugin.JDBCChannelMapper;
+import org.jboss.jms.server.plugin.contract.ChannelMapper;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Delivery;
+import org.jboss.messaging.core.DeliveryObserver;
+import org.jboss.messaging.core.Message;
+import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.SimpleDelivery;
+import org.jboss.messaging.core.local.CoreDestination;
 import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 
 import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
@@ -39,6 +48,9 @@
  * This class maintains JMS Server local transactions.
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ *
  * @version $Revision 1.1 $
  *
  * $Id$
@@ -56,7 +68,9 @@
    protected Map globalToLocalMap;     
    
    protected PersistenceManager persistenceManager;
-   
+
+   protected MessageStore messageStore;
+
    protected IdManager idManager;
 
    // Static --------------------------------------------------------
@@ -70,10 +84,11 @@
    
    // Public --------------------------------------------------------
 
-   public void start(PersistenceManager persistenceManager) throws Exception
+   public void start(PersistenceManager persistenceManager, MessageStore store) throws Exception
    {
       this.persistenceManager = persistenceManager;
-      
+      this.messageStore = store;
+
       //TODO make this configurable
       idManager = new IdManager("TRANSACTION_ID", 4096, persistenceManager);
    }
@@ -82,48 +97,77 @@
    {
    }
 
-   public List getPreparedTransactions()
+	public List getPreparedTransactions()
    {
-      ArrayList prepared = new ArrayList();
-      Iterator iter = globalToLocalMap.values().iterator();
-      while (iter.hasNext())
+		ArrayList prepared = new ArrayList();
+
+		Iterator iter = globalToLocalMap.values().iterator();
+
+		while (iter.hasNext())
       {
-         Transaction tx = (Transaction)iter.next();
-         if (tx.xid != null && tx.getState() == Transaction.STATE_PREPARED)
+			Transaction tx = (Transaction) iter.next();
+
+			if (tx.xid != null && tx.getState() == Transaction.STATE_PREPARED)
          {
-            prepared.add(tx.getXid());
-         }
-      }
-      return prepared;
-   }
-   
-   /*
-    * Load any prepared transactions into the repository so they can be recovered
-    */
-   public void loadPreparedTransactions() throws Exception
+            try
+            {
+               if(trace)
+                  log.trace("Loading and handling refs and acks to the Tx "+tx);
+
+               handleReferences(tx, tx.getId());
+               handleAcks(tx, tx.getId());
+            }
+            catch (Exception e)
+            {
+               log.debug("Exception in replaying a prepared transaction.", e);
+            }
+
+				prepared.add(tx.getXid());
+			}
+		}
+
+		return prepared;
+	}
+
+	/*
+	 * Load any prepared transactions into the repository so they can be
+	 * recovered
+	 */
+	public void loadPreparedTransactions() throws Exception
    {
-      List prepared = null;
-            
-      prepared = persistenceManager.retrievePreparedTransactions();
-      
-      if (prepared != null)
-      {         
-         Iterator iter = prepared.iterator();
-         
-         while (iter.hasNext())
-         {
-            Xid xid = (Xid)iter.next();
-            Transaction tx = createTransaction(xid);            
-            tx.state = Transaction.STATE_PREPARED;
-            
-            //Load the references for this transaction
-         }
-      }
-   }
-         
+		List prepared = null;
+
+		prepared = persistenceManager.retrievePreparedTransactions();
+
+		if (prepared != null) {
+			Iterator iter = prepared.iterator();
+
+			while (iter.hasNext()) {
+				PreparedTxInfo txInfo = (PreparedTxInfo) iter.next();
+
+				Transaction tx = createTransaction(txInfo);
+				tx.state = Transaction.STATE_PREPARED;
+
+				// // we have to associate a callback to the prepared
+				// transaction
+				// // --MK
+				persistenceManager.associateTxCallbackToPreparedTx(tx);
+				// log.info(">>>ASSOCIATING THE MEMCALLBACK <<<");
+
+            // TODO: [JPL] needs to be completed.
+
+            // associateInMemoryCallbackToPreparedTx(tx);
+				// Load the references for this transaction
+
+			}
+		}
+	}
+
+
    public Transaction getPreparedTx(Xid xid) throws Exception
    {
       Transaction tx = (Transaction)globalToLocalMap.get(xid);
+
       if (tx == null)
       {
          throw new TransactionException("Cannot find local tx for xid:" + xid);
@@ -150,7 +194,7 @@
 		   throw new TransactionException("Transaction with xid " + id + " can't be removed as it's not yet commited or rolledback: (Current state is " + Transaction.stateToString(state));
 	   }
 	   
-	   globalToLocalMap.remove(id);  
+	   globalToLocalMap.remove(id);
    }
    
    public Transaction createTransaction(Xid xid) throws Exception
@@ -175,8 +219,8 @@
 
       return tx;
    }
-   
-   
+
+
    /** To be used only by testcases */
    public int getNumberOfRegisteredTransactions()
    {
@@ -188,7 +232,138 @@
    // Protected -----------------------------------------------------         
    
    // Private -------------------------------------------------------
-   
+
+	/**
+	 * Load the references and invoke the channel to handle those refs
+	 */
+	private void handleReferences(Transaction tx, long txId) throws Exception {
+
+		long messageId = persistenceManager.getMessageIdForRef(txId);
+
+		List refsList = getRefs(messageId);
+
+		// now we got all the refs
+		// for each ref loaded, we'll invoke channel.handle
+		for (Iterator iter = refsList.iterator(); iter.hasNext();)
+		{
+			CoreDestination d = getChannel(persistenceManager.getChannelId(txId), txId);
+
+         if (trace)
+			   log.trace("Handling the channel");
+
+         d.handle(null, (MessageReference) iter.next(), tx);
+		}
+	}
+
+	/**
+	 * Load the acks and acknowledge them
+	 */
+	private void handleAcks(Transaction tx, long txId) throws Exception {
+
+		long messageId = persistenceManager.getMessageIdForAck(txId);
+
+		List refsList = getRefs(messageId);
+
+		for (Iterator iter = refsList.iterator(); iter.hasNext();)
+		{
+			Delivery del = new SimpleDelivery(null, (MessageReference) iter.next());
+
+			try
+         {
+				if(trace)
+					log.trace("Acknowledging..");
+
+				((DeliveryObserver)del).acknowledge(del, tx);
+			}
+         catch (Throwable e)
+         {
+				log.debug("Acknowledgement failed.", e);
+			}
+		}
+	}
+
+	/**
+	 * Get the message references based on the messageId from database
+	 */
+	private List getRefs(long messageId) throws Exception
+	{
+		List noRefsList = new ArrayList();
+		List refsList = new ArrayList();
+
+		// and message reference from store
+		MessageReference ref = messageStore.reference(messageId);
+
+		// Store, sometime, does'nt know about the message referece
+		// and the above ref may be null. Hence we need to load actual message
+		// by goind back to the database and loading them based on id
+
+		if (ref == null)
+		{
+			noRefsList.add(new Long(messageId));
+		}
+		else
+		{
+			refsList.add(ref);
+		}
+
+		// ask the pm to get the messages from messageId list
+		List messagesList = persistenceManager.getMessages(noRefsList);
+
+		for (Iterator iter = messagesList.iterator(); iter.hasNext();)
+		{
+			Message m = (Message) iter.next();
+			MessageReference r = messageStore.reference(m);
+			refsList.add(r);
+		}
+
+		return refsList;
+	}
+
+	/**
+	 * This method returns a core destination representation based on
+	 * the channel id and transaction id
+	 */
+	private CoreDestination getChannel(long channelId, long txId)
+			throws Exception {
+
+		// first get the reference to the channel mapper
+		ChannelMapper mapper = persistenceManager.getChannelMapperReference();
+
+		// find out the destination from channelId
+		JBossDestination destn = ((JDBCChannelMapper)mapper).getJBossDestination(channelId);
+
+		// get the core destination from jbossdestination
+		return mapper.getCoreDestination(destn);
+
+	}
+
+	/**
+	 * Creates a prepared transaction
+	 *
+	 * @param txInfo
+	 * @return
+	 * @throws Exception
+	 */
+	private Transaction createTransaction(PreparedTxInfo txInfo) throws Exception
+   {
+		if (globalToLocalMap.containsKey(txInfo.getXid()))
+      {
+			throw new TransactionException(
+					"There is already a local tx for global tx "	+ txInfo.getXid());
+		}
+
+		// Resurrected tx
+		Transaction tx = new Transaction(txInfo.getTxId(), txInfo.getXid(), this);
+
+		if (trace) {
+			log.trace("created transaction " + tx);
+		}
+
+		globalToLocalMap.put(txInfo.getXid(), tx);
+
+		return tx;
+	}
+
    // Inner classes -------------------------------------------------
    
 }
\ No newline at end of file

Modified: branches/Branch_1_0/tests/build.xml
===================================================================
--- branches/Branch_1_0/tests/build.xml	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/build.xml	2006-12-02 14:14:09 UTC (rev 1686)
@@ -176,6 +176,7 @@
       <path refid="test.compilation.classpath"/>
       <path refid="dom4j.dom4j.classpath"/>
       <path refid="apache.log4j.classpath"/>
+      <path refid="apache.logging.classpath"/>
       <path refid="apache.xerces.classpath"/>
       <path refid="jboss.mbeans.classpath"/>
       <path refid="jboss.naming.classpath"/>

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -26,6 +26,7 @@
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
+import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
@@ -95,7 +96,7 @@
       
       TransactionRepository tr = new TransactionRepository();
       
-      tr.start(pm);
+      tr.start(pm, new SimpleMessageStore("test.store"));
       
       Transaction tx = tr.createTransaction();
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/base/ChannelTestBase.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/base/ChannelTestBase.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/base/ChannelTestBase.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -106,10 +106,11 @@
       
       ((JDBCPersistenceManager)msPersistenceManagerDelegate).start();
       
-      tr.start(this.msPersistenceManagerDelegate);
-      
       ms = new SimpleMessageStore("s47");
 
+      tr.start(this.msPersistenceManagerDelegate, ms);
+      
+
    }
 
    public void tearDown() throws Exception

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/distributed/queue/RecoverableDistributedQueueTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/distributed/queue/RecoverableDistributedQueueTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/distributed/queue/RecoverableDistributedQueueTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -83,7 +83,7 @@
       channel3 = new DistributedQueue("test", ms3, tl3, dispatcher3);
 
       // initialize the transaction repository with the new transaction log
-      tr.start(tl);
+      tr.start(tl, ms);
 
       log.debug("setup done");
    }

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableQueueTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableQueueTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableQueueTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -61,7 +61,7 @@
       channel = new Queue(1, ms, pm, null, true, 100, 20, 10, new QueuedExecutor());
 
       
-      tr.start(pm);
+      tr.start(pm, ms);
    }
 
    public void tearDown() throws Exception

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableSubscriptionTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableSubscriptionTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/local/RecoverableSubscriptionTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -63,7 +63,7 @@
 
       ms = new SimpleMessageStore("s20");
 
-      tr.start(tl);
+      tr.start(tl, ms);
    
       channel = new CoreSubscription(123, null, ms, tl, null, true, 100, 20, 10, new QueuedExecutor(), null);
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/PagingStateTestBase.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/PagingStateTestBase.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/PagingStateTestBase.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -56,6 +56,8 @@
  * A PagingStateTestBase.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * 
  * @version 1.1
  *
  * PagingStateTestBase.java,v 1.1 2006/03/22 10:23:35 timfox Exp
@@ -107,7 +109,7 @@
       
       tr = new TransactionRepository();
       
-      tr.start(pm);
+      tr.start(pm, ms);
       
    }
    

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -40,6 +40,8 @@
  * A PagingTest_Reload.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * 
  * @version 1.1
  *
  * SingleChannel_Reload.java,v 1.1 2006/03/22 10:23:35 timfox Exp
@@ -124,7 +126,7 @@
       
       tr = new TransactionRepository();
       
-      tr.start(pm);
+      tr.start(pm, ms);
          
       ChannelSupport queue2 = new Queue(1, ms, pm, null, true, 100, 20, 10, new QueuedExecutor());
       
@@ -213,7 +215,7 @@
       
       tr = new TransactionRepository();
       
-      tr.start(pm);
+      tr.start(pm, ms);
          
       ChannelSupport queue2 = new Queue(1, ms, pm, null, false, 100, 20, 10, new QueuedExecutor());
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -46,6 +46,7 @@
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
+import org.jboss.messaging.core.tx.PreparedTxInfo;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.core.SimpleChannel;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -56,6 +57,8 @@
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ *
  * @version <tt>1.1</tt>
  *
  * JDBCPersistenceManagerTest.java,v 1.1 2006/02/22 17:33:44 timfox Exp
@@ -1024,7 +1027,7 @@
       Channel channel = new SimpleChannel(0, ms);
       
       TransactionRepository txRep = new TransactionRepository();
-      txRep.start(pm);
+      txRep.start(pm, ms);
 
       Message[] messages = createMessages(10);
       
@@ -1043,11 +1046,16 @@
       List txList = pm.retrievePreparedTransactions();
       assertNotNull(txList);
       assertEquals(messages.length, txList.size());
-      
+
+      List retrievedXids = new ArrayList();
+
       for (int i = 0; i < xids.length; i++)
+         retrievedXids.add(((PreparedTxInfo)txList.get(i)).getXid());
+
+      for (int i = 0; i < xids.length; i++)
       {
          Xid xid = xids[i];
-         assertTrue(txList.contains(xid));
+         assertTrue(retrievedXids.contains(xid));
       }
       
       //rollback the txs
@@ -1378,7 +1386,7 @@
 
       Channel channel = new SimpleChannel(0, ms);
       TransactionRepository txRep = new TransactionRepository();
-      txRep.start(pm);
+      txRep.start(pm, ms);
 
       log.debug("transaction log started");
 
@@ -1485,7 +1493,7 @@
 
       Channel channel = new SimpleChannel(0, ms);
       TransactionRepository txRep = new TransactionRepository();
-      txRep.start(pm);
+      txRep.start(pm, ms);
  
       Message[] messages = createMessages(10);     
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -21,16 +21,32 @@
   */
 package org.jboss.test.messaging.jms;
 
+import javax.jms.Connection;
 import javax.jms.Destination;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.jms.XAConnection;
+import javax.jms.XASession;
 import javax.naming.InitialContext;
+import javax.transaction.TransactionManager;
+import javax.transaction.UserTransaction;
+import javax.transaction.xa.XAResource;
+import javax.transaction.xa.Xid;
 
 import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.messaging.core.tx.XidImpl;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.test.messaging.util.TransactionManagerLocator;
 
+import com.arjuna.ats.jta.xa.XidImple;
+import com.arjuna.ats.arjuna.common.Uid;
+
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  */
 public class XARecoveryTest extends MessagingTestCase
 {
@@ -43,8 +59,10 @@
    protected InitialContext initialContext;
    
    protected JBossConnectionFactory cf;
-   protected Destination queue;   
+   protected Destination queue;
 
+   TransactionManager tm;
+
    // Constructors --------------------------------------------------
 
    public XARecoveryTest(String name)
@@ -64,7 +82,7 @@
       cf = (JBossConnectionFactory)initialContext.lookup("/ConnectionFactory");
       
       
-      //if (!ServerManagement.isRemote()) tm = TransactionManagerLocator.getInstance().locate();
+      if (!ServerManagement.isRemote()) tm = TransactionManagerLocator.getInstance().locate();
       
       ServerManagement.undeployQueue("Queue");
       ServerManagement.deployQueue("Queue");
@@ -82,114 +100,306 @@
 
    // Public --------------------------------------------------------
    
-   //TODO Re-enable when we complete XA Recovery
-   
-   public void testNoop()
+
+   public void testJBossTSCoordinator() throws Exception
    {
-      
+      UserTransaction ut = com.arjuna.ats.jta.UserTransaction.userTransaction();
+
+      ut.begin();
+
+
+      ut.commit();
    }
-   
-//
-//   public void test1() throws Exception
-//   {
-//      
-//      XAConnection conn1 = cf.createXAConnection();
-//      
-//      XAConnection conn2 = cf.createXAConnection();
-//      
-//      XASession sess1 = conn1.createXASession();
-//      
-//      XASession sess2 = conn2.createXASession();
-//      
-//      XAResource res1 = sess1.getXAResource();
-//      
-//      XAResource res2 = sess2.getXAResource();
-//      
-//      //Pretend to be a transaction manager by interacting through the XAResources
-//      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
-//      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
-//      
-//      
-////    Send a message in each tx
-//      
-//      
-//      res1.start(xid1, XAResource.TMNOFLAGS);
-//      
-//      MessageProducer prod1 = sess1.createProducer(queue);
-//      
-//      TextMessage tm1 = sess1.createTextMessage("testing1");
-//      
-//      prod1.send(tm1);
-//      
-//      res1.end(xid1, XAResource.TMSUCCESS);
-//      
-//      
-//      
-//      
-//      res2.start(xid2, XAResource.TMNOFLAGS);
-//      
-//      MessageProducer prod2 = sess2.createProducer(queue);
-//      
-//      TextMessage tm2 = sess2.createTextMessage("testing2");
-//      
-//      prod2.send(tm2);
-//      
-//      res2.end(xid2, XAResource.TMSUCCESS);
-//      
-//      //prepare both txs
-//      
-//      
-//      res1.prepare(xid1);      
-//      res2.prepare(xid2);
-//      
-//      //Now "crash" the server
-//      
-//      ServerManagement.stopServerPeer();
-//
-//      ServerManagement.startServerPeer();
-//
-//      //Now lookup the recoverable in JNDI
-//      InitialContext ic = new InitialContext();
-//      JMSRecoverable recoverable = (JMSRecoverable)ic.lookup("/" +
-//            ServerPeer.RECOVERABLE_CTX_NAME + "/"+ ServerManagement.getServerPeer().getServerPeerID());
-//      
-//      XAResource res = recoverable.getResource();
-//      
-//      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-//      assertEquals(2, xids.length);
-//      
-//      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-//      assertEquals(0, xids2.length);
-//      
-//      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-//      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-//      
-//      res.commit(xid1, false);
-//      
-//      res.commit(xid2, false);
-//      
-//      recoverable.cleanUp();
-//      
-//      ServerManagement.deployQueue("Queue");
-//            
-//      Connection conn3 = cf.createConnection();
-//      
-//      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//      MessageConsumer cons = sessRec.createConsumer(queue);
-//      conn3.start();
-//      
-//      TextMessage m2 = (TextMessage)cons.receiveNoWait();
-//      assertNotNull(m2);
-//      assertEquals("testing1", m2.getText());
-//      
-//      
-//      TextMessage m3 = (TextMessage)cons.receiveNoWait();
-//      assertNotNull(m3);
-//      assertEquals("testing2", m3.getText());
-//      
-//      conn3.close();
-//
-//   }
- 
+
+
+   public void testMockCoordinatorRecovery() throws Exception
+   {
+
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queue);
+
+      TextMessage tm1 = sess1.createTextMessage("testing1");
+
+      prod1.send(tm1);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod2 = sess2.createProducer(queue);
+
+      TextMessage tm2 = sess2.createTextMessage("testing2");
+
+      prod2.send(tm2);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+      res.commit(xid1, false);
+
+      res.commit(xid2, false);
+
+      ServerManagement.deployQueue("Queue");
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      MessageConsumer cons = sessRec.createConsumer(queue);
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m1);
+      assertEquals("testing1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m2);
+
+      assertEquals("testing2", m2.getText());
+
+      conn3.close();
+
+   }
+
+
+   public void testMockCoordinatorRecoveryWithJBossTSXids() throws Exception
+   {
+
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImple(new Uid("gbtxid1"), new Uid("bq1"), 123);
+      Xid xid2 = new XidImple(new Uid("gbtxid2"), new Uid("bq2"), 124);
+
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queue);
+
+      TextMessage tm1 = sess1.createTextMessage("testing1");
+
+      prod1.send(tm1);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod2 = sess2.createProducer(queue);
+
+      TextMessage tm2 = sess2.createTextMessage("testing2");
+
+      prod2.send(tm2);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+
+      res.commit(xid1, false);
+
+      res.commit(xid2, false);
+
+      ServerManagement.deployQueue("Queue");
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      MessageConsumer cons = sessRec.createConsumer(queue);
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m1);
+      assertEquals("testing1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m2);
+
+      assertEquals("testing2", m2.getText());
+
+      conn3.close();
+
+   }
+/*
+   public void testMockCoordinatorRecovery3() throws Exception
+   {
+
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queue);
+
+      TextMessage tm1 = sess1.createTextMessage("testing1");
+
+      prod1.send(tm1);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod2 = sess2.createProducer(queue);
+
+      TextMessage tm2 = sess2.createTextMessage("testing2");
+
+      prod2.send(tm2);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+      res.commit(xids[0], false);
+
+      res.commit(xids[1], false);
+
+      ServerManagement.deployQueue("Queue");
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      MessageConsumer cons = sessRec.createConsumer(queue);
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m1);
+      assertEquals("testing1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      assertNotNull(m2);
+
+      assertEquals("testing2", m2.getText());
+
+      conn3.close();
+
+   }
+*/
+   public void testXidEquals()
+   {
+      Xid xid1 = new XidImple(new Uid("gbtxid1"), new Uid("bq1"), 123);
+      Xid xid2 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+
+      try
+      {
+         assertEquals(xid1, xid2);
+      }
+      catch (Throwable t)
+      {
+         // different xid impls are not expected to equal
+      }
+   }
 }
 

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-02 14:14:09 UTC (rev 1686)
@@ -42,10 +42,11 @@
 import org.jboss.jms.tx.MessagingXAResource;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.tm.TransactionManagerLocator;
+import org.jboss.tm.TxUtils;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  *
  * $Id$
  */
@@ -83,13 +84,20 @@
       initialContext = new InitialContext(ServerManagement.getJNDIEnvironment());
       cf = (JBossConnectionFactory)initialContext.lookup("/ConnectionFactory");
             
-      if (!ServerManagement.isRemote()) tm = TransactionManagerLocator.getInstance().locate();
-      
+      if (!ServerManagement.isRemote())
+      {
+         tm = org.jboss.test.messaging.util.TransactionManagerLocator.getInstance().locate();
+      }
+
       ServerManagement.undeployQueue("Queue");
       ServerManagement.deployQueue("Queue");
       queue = (Destination)initialContext.lookup("/queue/Queue");
-      
-      if (!ServerManagement.isRemote()) suspendedTx = tm.suspend();
+
+
+      if (!ServerManagement.isRemote())
+      {
+         suspendedTx = tm.suspend();
+      }
    }
 
    public void tearDown() throws Exception
@@ -98,11 +106,17 @@
       
       if (!ServerManagement.isRemote())
       {
-         if (tm.getTransaction() != null)
+         if (TxUtils.isUncommitted(tm))
          {
             //roll it back
             tm.rollback();
          }
+         if (tm.getTransaction() != null)
+         {
+            Transaction tx = tm.suspend();
+            if (tx != null)
+               log.warn("Transaction still associated with thread " + tx + " at status " + TxUtils.getStatusAsString(tx.getStatus()));
+         }
       }
       
       if (suspendedTx != null)
@@ -151,7 +165,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
          
-         tx.commit();
+         tm.commit();
          
          conn2 = cf.createConnection();
          conn2.start();
@@ -177,42 +191,44 @@
       }
 
    }
-   
+
+
+
    public void test2PCSendCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
-      
+
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
-         
-         MessagingXAResource res = (MessagingXAResource)sess.getXAResource();         
+
+         MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
          XAResource res2 = new DummyXAResource();
-         
+
          //To prevent 1PC optimization being used
          res.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
          prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -237,47 +253,47 @@
       }
 
    }
-   
-   
+
+
    public void test2PCSendRollback1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m);   
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
          Message m2 = cons.receive(1000);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -291,59 +307,61 @@
          }
       }
    }
-   
-   
+
+
    public void test2PCSendFailOnPrepare() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
-         
+
          //prevent 1Pc optimisation
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource(true);
          XAResource res3 = new DummyXAResource();
          XAResource res4 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
          tx.enlistResource(res3);
          tx.enlistResource(res4);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m);   
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
+
          try
          {
-            tx.commit();         
+            tm.commit();
+
+            fail("should not get here");
          }
          catch (Exception e)
          {
             //We should expect this
          }
-         
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
          Message m2 = cons.receive(1000);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -357,47 +375,47 @@
          }
       }
    }
-   
+
    public void test2PCSendRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
-         
+
          //prevent 1Pc optimisation
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m);   
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
          Message m2 = cons.receive(1000);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -415,12 +433,12 @@
    public void test2PCReceiveCommit1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-            
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -431,49 +449,49 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
          conn.start();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
+
          TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         
+
          m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          Message m3 = cons.receive(1000);
-         
+
          assertNull(m3);
-         
+
          tm.commit();
-         
 
+
       }
       finally
       {
@@ -486,16 +504,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test2PCReceiveCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-            
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -506,50 +524,50 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
          conn.start();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
+
          TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         
+
          m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          Message m3 = cons.receive(1000);
-         
+
          assertNull(m3);
-         
+
          tm.commit();
-         
 
+
       }
       finally
       {
@@ -562,18 +580,18 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test2PCReceiveRollback1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -581,54 +599,54 @@
          MessageProducer prod  = sessProducer.createProducer(queue);
          Message m = sessProducer.createTextMessage("XATest1");
          prod.send(m);
-         
+
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m2 = (TextMessage)cons.receive(1000);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);         
+         m2 = (TextMessage)cons.receive(1000);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          //Message should be redelivered
-         
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
-         TextMessage m3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m3 = (TextMessage)cons.receive(1000);
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         m3 = (TextMessage)cons.receive(1000);         
+         m3 = (TextMessage)cons.receive(1000);
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
-         
+
          assertTrue(m3.getJMSRedelivered());
-         
+
          tm.commit();
 
       }
@@ -643,16 +661,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test2PCReceiveRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -660,55 +678,55 @@
          MessageProducer prod  = sessProducer.createProducer(queue);
          Message m = sessProducer.createTextMessage("XATest1");
          prod.send(m);
-         
+
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m2 = (TextMessage)cons.receive(1000);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);         
+         m2 = (TextMessage)cons.receive(1000);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          //Message should be redelivered
-         
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
-         TextMessage m3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m3 = (TextMessage)cons.receive(1000);
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         m3 = (TextMessage)cons.receive(1000);         
+         m3 = (TextMessage)cons.receive(1000);
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
-         
+
          assertTrue(m3.getJMSRedelivered());
-         
+
          tm.commit();
 
       }
@@ -723,41 +741,41 @@
             conn2.close();
          }
       }
-      
+
    }
-   
-   
+
+
    public void test1PCSendCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
-      
+
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
-         
+
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
 
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
          prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -782,20 +800,20 @@
       }
 
    }
-   
-   
+
+
    public void test1PCSendRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
 
@@ -805,19 +823,19 @@
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m); 
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
-         prod.send(queue, m); 
-         
-         tx.rollback();
-         
+         prod.send(queue, m);
+
+         tm.rollback();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
          Message m2 = cons.receive(1000);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -835,10 +853,10 @@
    public void test1PCReceiveCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -849,44 +867,44 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
          conn.start();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
+
          TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
          m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
-         
+
          Message m3 = cons.receive(1000);
-         
+
          assertNull(m3);
-         
+
          tm.commit();
-         
 
+
       }
       finally
       {
@@ -899,16 +917,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test1PCReceiveRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -918,53 +936,53 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
 
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
+
          TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         
+
          m2 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          //Message should be redelivered
-         
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
-         
+
          TextMessage m3 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         
+
          m3 = (TextMessage)cons.receive(1000);
-         
+
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
-         
+
          assertTrue(m3.getJMSRedelivered());
-         
+
          tm.commit();
 
       }
@@ -979,18 +997,18 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitAcknowledge1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       try
       {
          //First send 2 messages
@@ -1001,50 +1019,50 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          XAResource res2 = sess2.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, one on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
          TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-                  
+
          cons1.close();
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
          TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
-         //commit        
-         tx.commit();
-         
+
+         //commit
+         tm.commit();
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNull(r3);
-       
-         
 
+
+
       }
       finally
       {
@@ -1057,16 +1075,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          //First send 2 messages
@@ -1077,13 +1095,13 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1091,36 +1109,36 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, one on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
          TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-                  
+
          cons1.close();
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
          TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
-         //commit        
-         tx.commit();
-         
+
+         //commit
+         tm.commit();
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNull(r3);
-       
+
       }
       finally
       {
@@ -1133,19 +1151,19 @@
             conn2.close();
          }
       }
-      
+
    }
-   
-   
+
+
    public void testMultipleSessionsOneTxRollbackAcknowledge1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       try
       {
          //First send 2 messages
@@ -1160,75 +1178,75 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
- 
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, two on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
          TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
-                  
+
          cons1.close();
-      
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
          TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+
          assertNotNull(r2);
          assertEquals("jellyfish3", r2.getText());
-         
+
          r2 = (TextMessage)cons2.receive(1000);
-         
+
          assertNotNull(r2);
          assertEquals("jellyfish4", r2.getText());
-         
-         cons2.close();            
-         
-         //rollback                          
-         
-         tx.rollback();
-         
+
+         cons2.close();
+
+         //rollback
+
+         tm.rollback();
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
-         
-         r3 = (TextMessage)cons.receive(1000);         
+
+         r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish2", r3.getText());
 
-         TextMessage r4 = (TextMessage)cons.receive(1000);         
+         TextMessage r4 = (TextMessage)cons.receive(1000);
          assertNotNull(r4);
          assertEquals("jellyfish3", r4.getText());
 
-         r4 = (TextMessage)cons.receive(1000);         
+         r4 = (TextMessage)cons.receive(1000);
          assertNotNull(r4);
          assertEquals("jellyfish4", r4.getText());
-         
 
+
       }
       finally
       {
@@ -1241,13 +1259,13 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxRollbackAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
 
@@ -1265,13 +1283,13 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1279,69 +1297,69 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, two on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
          TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
-                  
+
          cons1.close();
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
          TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+
          assertNotNull(r2);
          assertEquals("jellyfish3", r2.getText());
-         
+
          r2 = (TextMessage)cons2.receive(1000);
-         
+
          assertNotNull(r2);
          assertEquals("jellyfish4", r2.getText());
-         
-         //rollback                 
-         
+
+         //rollback
+
          cons2.close();
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          //NOTE
          //The order here is actually probably dependent on the transaction manager implementation
          //In this case, rollback will be called on each session, but whether it is called first on res1
          //or res2 determines the order the messages are put back in the queue
          //This test assumes it is called in order res1, res2
-         
-         TextMessage r3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish3", r3.getText());
-         
-         r3 = (TextMessage)cons.receive(1000);         
+
+         r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish4", r3.getText());
 
-         TextMessage r4 = (TextMessage)cons.receive(1000);         
+         TextMessage r4 = (TextMessage)cons.receive(1000);
          assertNotNull(r4);
          assertEquals("jellyfish1", r4.getText());
-  
-         r4 = (TextMessage)cons.receive(1000);         
+
+         r4 = (TextMessage)cons.receive(1000);
          assertNotNull(r4);
          assertEquals("jellyfish2", r4.getText());
-         
 
+
       }
       finally
       {
@@ -1354,13 +1372,13 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxRollbackAcknowledgeForceFailureInCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
 
@@ -1378,79 +1396,80 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
          DummyXAResource res2 = new DummyXAResource(true);
          res1.setPreventJoining(true);
-                  
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons1 = sess1.createConsumer(queue);
          TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
-         
+
          r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish3", r1.getText());
-         
+
          r1 = (TextMessage)cons1.receive(1000);
-         
+
          assertNotNull(r1);
          assertEquals("jellyfish4", r1.getText());
-                  
+
          cons1.close();
-         
-         
-         
+
+
+
          //try and commit - and we're going to make the dummyxaresource throw an exception on commit,
          //which should cause rollback to be called on the other resource
          try
          {
-            tx.commit();
+            tm.commit();
+            fail("should not get here");
          }
          catch (Exception e)
          {
             //We should expect this
          }
-         
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-          
-         TextMessage r3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
-         
-         r3 = (TextMessage)cons.receive(1000);         
+
+         r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish2", r3.getText());
-  
-         TextMessage r4 = (TextMessage)cons.receive(1000);         
+
+         TextMessage r4 = (TextMessage)cons.receive(1000);
          assertNotNull(r4);
          assertEquals("jellyfish3", r4.getText());
-      
-         r4 = (TextMessage)cons.receive(1000);         
+
+         r4 = (TextMessage)cons.receive(1000);
          assertNotNull(r4);
          assertEquals("jellyfish4", r4.getText());
-         
 
+
       }
       finally
       {
@@ -1463,59 +1482,59 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitSend1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          XAResource res2 = sess2.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //commit
-         tx.commit();
-         
+         tm.commit();
+
          //Messages should be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          TextMessage r1 = (TextMessage)cons.receive(1000);
          assertNotNull(r1);
          assertEquals("echidna1", r1.getText());
-         
+
          TextMessage r2 = (TextMessage)cons.receive(1000);
          assertNotNull(r2);
          assertEquals("echidna2", r2.getText());
@@ -1533,27 +1552,27 @@
          }
 
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1561,33 +1580,33 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //commit
-         tx.commit();
-         
+         tm.commit();
+
          //Messages should be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          TextMessage r1 = (TextMessage)cons.receive(1000);
          assertNotNull(r1);
          assertEquals("echidna1", r1.getText());
-         
+
          TextMessage r2 = (TextMessage)cons.receive(1000);
          assertNotNull(r2);
          assertEquals("echidna2", r2.getText());
@@ -1605,60 +1624,60 @@
          }
 
       }
-      
+
    }
-   
-   
+
+
    public void testMultipleSessionsOneTxRollbackSend1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          XAResource res2 = sess2.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //rollback
-         tx.rollback();
-         
+         tm.rollback();
+
          //Messages should not be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          TextMessage r1 = (TextMessage)cons.receive(1000);
          assertNull(r1);
-         
 
+
       }
       finally
       {
@@ -1672,25 +1691,25 @@
          }
 
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxRollbackSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1698,33 +1717,33 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //rollback
-         tx.rollback();
-         
+         tm.rollback();
+
          //Messages should not be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
+
          TextMessage r1 = (TextMessage)cons.receive(1000);
          assertNull(r1);
-         
 
+
       }
       finally
       {
@@ -1738,20 +1757,20 @@
          }
 
       }
-      
+
    }
-   
- 
+
+
    public void testOneSessionTwoTransactionsCommitAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
-      {         
+      {
          //First send 2 messages
          conn2 = cf.createConnection();
          Session sessProducer = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1760,43 +1779,43 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-                  
+
          conn.start();
          MessageConsumer cons1 = sess1.createConsumer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Receive one message in one tx
-         
+
          TextMessage r1 = (TextMessage)cons1.receive(1000);
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-                  
+
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Receive 2nd message in a different tx
          TextMessage r2 = (TextMessage)cons1.receive(1000);
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
+
          //commit this transaction
-         tx2.commit();
-         
+         tm.commit();
+
          //verify that no messages are available
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1804,12 +1823,12 @@
          MessageConsumer cons = sess.createConsumer(queue);
          TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNull(r3);
-         
+
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
-         
+         tm.commit();
 
+
       }
       finally
       {
@@ -1823,20 +1842,20 @@
          }
 
       }
-      
+
    }
-   
-   
+
+
    public void testOneSessionTwoTransactionsRollbackAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-       
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
-      {         
+      {
          //First send 2 messages
          conn2 = cf.createConnection();
          Session sessProducer = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1845,45 +1864,45 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-                  
+
          conn.start();
          MessageConsumer cons1 = sess1.createConsumer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Receive one message in one tx
-         
+
          TextMessage r1 = (TextMessage)cons1.receive(1000);
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-                  
+
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Receive 2nd message in a different tx
          TextMessage r2 = (TextMessage)cons1.receive(1000);
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
+
          cons1.close();
-         
+
          //rollback this transaction
-         tx2.rollback();
-     
+         tm.rollback();
+
          //verify that second message is available
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1896,19 +1915,19 @@
          assertEquals("jellyfish2", r3.getText());
          r3 = (TextMessage)cons.receive(1000);
          assertNull(r3);
-         
-         
+
+
          //rollback the other tx
          tm.resume(suspended);
-         suspended.rollback();
-       
+         tm.rollback();
+
          //Verify the first message is now available
          r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
          r3 = (TextMessage)cons.receive(1000);
          assertNull(r3);
-         
+
       }
       finally
       {
@@ -1922,52 +1941,52 @@
          }
 
       }
-      
+
    }
-   
 
+
    public void testOneSessionTwoTransactionsCommitSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo1"));
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-         
+
          //Send another message in another tx using the same session
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo2"));
-         
+
          //commit this transaction
-         tx2.commit();
-         
+         tm.commit();
+
          //verify only kangaroo2 message is sent
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1978,16 +1997,16 @@
          assertEquals("kangaroo2", r1.getText());
          TextMessage r2 = (TextMessage)cons.receive(1000);
          assertNull(r2);
-         
+
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
-         
+         tm.commit();
+
          //verify that the first text message is received
          TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("kangaroo1", r3.getText());
-         
+
       }
       finally
       {
@@ -2001,70 +2020,71 @@
          }
 
       }
-      
+
    }
-   
-   
+
+
    public void testOneSessionTwoTransactionsRollbackSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo1"));
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-         
+
          //Send another message in another tx using the same session
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo2"));
-         
+
          //rollback this transaction
-         tx2.rollback();
-         
+         tm.rollback();
+
          //verify no messages are sent
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
          TextMessage r1 = (TextMessage)cons.receive(1000);
+
          assertNull(r1);
-         
-         
+
+
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
-         
+         tm.commit();
+
          //verify that the first text message is received
          TextMessage r3 = (TextMessage)cons.receive(1000);
          assertNotNull(r3);
          assertEquals("kangaroo1", r3.getText());
-         
+
       }
       finally
       {
@@ -2078,9 +2098,9 @@
          }
 
       }
-      
+
    }
-   
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Copied: branches/Branch_1_0/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java (from rev 1684, branches/Branch_1_0_XARecovery/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java)

Modified: branches/Branch_1_0/util/release-admin.xml
===================================================================
--- branches/Branch_1_0/util/release-admin.xml	2006-12-02 13:36:20 UTC (rev 1685)
+++ branches/Branch_1_0/util/release-admin.xml	2006-12-02 14:14:09 UTC (rev 1686)
@@ -18,8 +18,12 @@
    <property name="jboss.home" value="${ENV.JBOSS_HOME}"/>
    <property name="messaging.config.name" value="messaging"/>
    <property name="standalone.messaging.config.name" value="standalone-messaging"/>
+   <property name="thirdparty.home" value="../thirdparty"/>
+   <property name="thirdparty.jbossts.home" value="${thirdparty.home}/jboss/jbossts"/>
+   <property name="lib.home" value="../lib"/>
+   <property name="lib.jbossts.home" value="${lib.home}/jbossts"/>
+   <property name="output.lib.home" value="../output/lib"/>
 
-
    <!-- DO NOT change this value here, otherwise the installation script won't work. Change it in
         do-not-distribute.properties.
    -->
@@ -85,6 +89,22 @@
          <substitution expression="&lt;category name=&quot;org.jboss.serial&quot;&gt;&#013;&#010;      &lt;priority value=&quot;INFO&quot;/&gt;&#013;&#010;   &lt;/category&gt;&#013;&#010;&#013;&#010;   \1"/>
       </replaceregexp>
 
+      <!-- Replace local TM with JBossTS -->
+      
+      <copy file="${thirdparty.jbossts.home}/lib/jbossjta.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+      <copy file="${thirdparty.jbossts.home}/lib/jbossjta-integration.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+      <copy file="${thirdparty.jbossts.home}/lib/jbossts-common.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+      <copy file="${lib.jbossts.home}/jbossjta-properties.xml"
+            todir="${jboss.home}/server/${messaging.config.name}/conf"/>
+      <copy overwrite="true" 
+            file="${lib.jbossts.home}/jboss-service.xml"
+            todir="${jboss.home}/server/${messaging.config.name}/conf"/>
+      <copy file="${output.lib.home}/jboss-messaging-integration.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+            
       <!-- copy the scoped sar
       <copy todir="${jboss.home}/server/${messaging.config.name}/deploy"
             file="${relative.sar.location}/${messaging.sar.name}"/>



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 10:36:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 10:36:37 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1687 -
	branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core
Message-ID: <E1GqWur-00040t-VK@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-02 10:36:36 -0500 (Sat, 02 Dec 2006)
New Revision: 1687

Modified:
   branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
Log:
minor reformatting

Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-02 14:14:09 UTC (rev 1686)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-02 15:36:36 UTC (rev 1687)
@@ -53,8 +53,9 @@
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt> $Id: ChannelSupport.java,v 1.65
- *          2006/06/27 19:44:39 timfox Exp $
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
  */
 public abstract class ChannelSupport implements Channel
 {
@@ -278,7 +279,7 @@
 
    public void cancel(Delivery d) throws Throwable
    {
-       //We put the cancellation on the event queue     
+       //We put the cancellation on the event queue
        this.executor.execute(new CancelRunnable(d));
    }
 
@@ -624,13 +625,13 @@
          // The iterator is used to iterate through the refs in the channel in the case that they
          // don't match the selectors of any receivers.
          ListIterator iter = null;
-         
+
          MessageReference ref = null;
-         
+
          while (true)
-         {           
+         {
             synchronized (refLock)
-            {              
+            {
                if (iter == null)
                {
                   ref = (MessageReference) messageRefs.peekFirst();
@@ -638,9 +639,9 @@
                else
                {
                   if (iter.hasNext())
-                  {                        
+                  {
                      ref = (MessageReference)iter.next();
-                  } 
+                  }
                   else
                   {
                      ref = null;
@@ -687,15 +688,15 @@
                      if (trace) { log.trace(this + ": no delivery returned for message" + ref + " so no receiver got the message. Delivery is now complete"); }
 
                      receiversReady = false;
-                     
+
                      return;
                   }
                   else if (!del.isSelectorAccepted())
                   {
                      // No receiver accepted the message because no selectors matched, so we create
                      // an iterator (if we haven't already created it) to iterate through the refs
-                     // in the channel. 
-                     
+                     // in the channel.
+
                      // TODO Note that this is only a partial solution since if there are messages
                      // paged to storage it won't try those - i.e. it will only iterate through
                      // those refs in memory. Dealing with refs in storage is somewhat tricky since
@@ -708,12 +709,12 @@
                      if (iter == null)
                      {
                         iter = messageRefs.iterator();
-                     }                     
+                     }
                   }
                   else
                   {
                      if (trace) { log.trace(this + ": " + del + " returned for message:" + ref); }
-                     
+
                      // Receiver accepted the reference
 
                      // We must synchronize here to cope with another race condition where message
@@ -743,7 +744,7 @@
                            }
                            else
                            {
-                              iter.remove();                                
+                              iter.remove();
                            }
 
                            // delivered
@@ -1684,11 +1685,11 @@
          }
       }
    }
-   
+
    private class CancelRunnable implements Runnable
    {
       Delivery del;
-      
+
       CancelRunnable(Delivery del)
       {
          this.del = del;



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 10:51:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 10:51:56 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1688 - in
	branches/Branch_1_0_1_SP/src/main/org/jboss:
	jms/server/endpoint messaging/core
Message-ID: <E1GqX9g-0004FV-RF@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-02 10:51:53 -0500 (Sat, 02 Dec 2006)
New Revision: 1688

Modified:
   branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
Log:

Added a couple of trace statements back in



Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-02 15:36:36 UTC (rev 1687)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-02 15:51:53 UTC (rev 1688)
@@ -768,8 +768,21 @@
 
          try
          {
-            if (trace) { log.trace(ServerConsumerEndpoint.this + " handing " + list.size() + " message(s) over to the remoting layer"); }
-
+            if (trace)
+            {
+               StringBuffer sb = new StringBuffer(ServerConsumerEndpoint.this + " handing [");
+               for(int i = 0; i < list.size(); i++)
+               {
+                  sb.append(((MessageProxy)list.get(i)).getMessage().getMessageID());
+                  if (i < list.size() - 1)
+                  {
+                     sb.append(",");
+                  }
+               }
+               sb.append("] over to the remoting layer");
+               log.trace(sb.toString());
+            }
+            
             ClientDelivery del = new ClientDelivery(list, id);
 
             // TODO How can we ensure that messages for the same consumer aren't delivered

Modified: branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-02 15:36:36 UTC (rev 1687)
+++ branches/Branch_1_0_1_SP/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-02 15:51:53 UTC (rev 1688)
@@ -651,6 +651,8 @@
 
             if (ref != null)
             {
+            	if (trace) { log.trace(this + " pushing " + ref); }
+                        
                // Check if message is expired (we also do this on the client
                // side)
                // If so ack it from the channel
@@ -744,7 +746,9 @@
                            }
                            else
                            {
-                              iter.remove();
+                              iter.remove();     
+                              if (trace) { log.trace(this + " removed current message from iterator"); }                           
+
                            }
 
                            // delivered
@@ -754,6 +758,7 @@
                               synchronized (deliveryLock)
                               {
                                  deliveries.add(del);
+                                 if (trace) { log.trace(this + " starting to track  " + del); }
                               }
                            }
                         }



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 10:53:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 10:53:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1689 - in
	branches/Branch_Client_Failover_Experiment/src: etc
	main/org/jboss/jms/client/container
	main/org/jboss/jms/client/delegate main/org/jboss/jms/server
	main/org/jboss/jms/server/connectionfactory
	main/org/jboss/jms/server/remoting
Message-ID: <E1GqXBe-0004Fo-Ui@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-02 10:53:51 -0500 (Sat, 02 Dec 2006)
New Revision: 1689

Modified:
   branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
Log:
Get basics running again



Modified: branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml	2006-12-02 15:53:51 UTC (rev 1689)
@@ -18,7 +18,7 @@
    <aspect class="org.jboss.jms.client.container.AsfAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.BrowserAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.ConnectionAspect" scope="PER_INSTANCE"/>
-   <aspect class="org.jboss.jms.client.container.FailoverAspect" scope="PER_INSTANCE"/>
+   <aspect class="org.jboss.jms.client.container.HAAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.FactoryAspect" scope="PER_INSTANCE"/>
 
    <!-- ConnectionFactory Stack-->        
@@ -30,7 +30,7 @@
       <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
    </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
-      <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.FailoverAspect"/>
+      <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.HAAspect"/>
    </bind>
                
    <!-- Connection Stack -->   

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -128,17 +128,15 @@
          
          delegates = (ClientConnectionFactoryDelegate[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES);
          
-         if (delegates == null)
-         {
-            throw new IllegalStateException("Cannot find delegates!");
+         if (delegates != null)
+         {          
+            failoverIndexes = (int[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES);
+            
+            if (failoverIndexes == null)
+            {
+               throw new IllegalStateException("Cannot find failoverIndexes!");
+            }
          }
-         
-         failoverIndexes = (int[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES);
-         
-         if (failoverIndexes == null)
-         {
-            throw new IllegalStateException("Cannot find failoverIndexes!");
-         }
       }
       
       return delegates;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -91,7 +91,7 @@
          ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID)).intValue();
       
       Version connectionVersion = 
-         (Version)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.VERSION_NUMBER);
+         (Version)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION);
       
       JMSRemotingConnection connection = 
          (JMSRemotingConnection)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -58,7 +58,7 @@
 
    // This should not be exposed other than through meta data
    private int serverId;
-
+   
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -27,6 +27,7 @@
 import javax.jms.JMSException;
 
 import org.jboss.aop.Advised;
+import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
@@ -156,6 +157,11 @@
       if (trace) { log.trace("invoking " + methodName + " on server"); }
 
       SimpleMetaData md = mi.getMetaData();
+      
+      md.addMetaData(Dispatcher.DISPATCHER,
+                     Dispatcher.OID,
+                     new Integer(id),
+                     PayloadKey.AS_IS);
 
       /*
        * If the method being invoked is createConnectionDelegate then we must invoke it on the same
@@ -212,7 +218,8 @@
       }
 
       //What version should we use for invocations on this connection factory?
-      byte v = getVersionToUse(serverVersion).getProviderIncrementingVersion();
+      Version version = getVersionToUse(serverVersion);
+      byte v = version.getProviderIncrementingVersion();
       
       MessagingMarshallable request = new MessagingMarshallable(v, mi);
       
@@ -258,8 +265,8 @@
          metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION,
                               remotingConnection, PayloadKey.TRANSIENT);
          
-         metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.VERSION_NUMBER,
-                              new Byte(v), PayloadKey.TRANSIENT);
+         metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
+                              version, PayloadKey.TRANSIENT);
 
       }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -49,7 +49,6 @@
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.contract.Replicator;
-import org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.Util;
 import org.jboss.mx.loading.UnifiedClassLoader3;
@@ -128,8 +127,6 @@
    protected ObjectName jmsUserManagerObjectName;
    protected JMSUserManager jmsUserManager;
    
-   protected Replicator dataReplicator;
-   
    //Other stuff
 
    // We keep a map of consumers to prevent us to recurse through the attached session in order to
@@ -602,6 +599,15 @@
       {
          queuePostOffice = (PostOffice)getServer().
             getAttribute(queuePostOfficeObjectName, "Instance");
+         
+         //We also inject the replicator dependency into the ConnectionFactoryJNDIMapper
+         //This is a bit messy but we have a circular dependency
+         //POJOContainer should be able to help us here
+         
+         if (!queuePostOffice.isLocal())
+         {
+            connFactoryJNDIMapper.injectReplicator((Replicator)queuePostOffice);
+         }
       }
       return queuePostOffice;
    }
@@ -617,21 +623,6 @@
       return topicPostOffice;        
    }
    
-   public Replicator getDataReplicator() throws Exception
-   {
-      // For now we just choose the queue post office - soon we merge both post offices into one
-      // anyway
-      
-      PostOffice office = getQueuePostOfficeInstance();
-      
-      if (!office.isLocal())
-      {
-         dataReplicator = (Replicator)office;
-      }
-      
-      return dataReplicator;
-   }
-      
    public synchronized int getNextObjectID()
    {
       return objectIDSequence++;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -104,31 +104,36 @@
 
       ClientConnectionFactoryDelegate delegate =
          new ClientConnectionFactoryDelegate(id, locatorURI, serverPeer.getVersion(), clientPing);
-      
+            
       if (clustered)
       {
-         // First we must replicate the delegate across the cluster so that all the
-         // ConnectionFactoryJNDIMapper instances on different nodes have access to the list of
-         // local connection factories so they can be added to the clustered connection factory
-
-         setUpReplicator();
-
-         replicator.putReplicant(CF_PREFIX + uniqueName, delegate);
+         setupReplicator();
          
-         // Get the list of delegates
-         
-         Map replicants = replicator.getReplicants(CF_PREFIX + uniqueName);
-         
-         //Create a clustered delegate which contains the array of the local delegates
-         //and failover indexes
-         
-         ClusteredClientConnectionFactoryDelegate clusteredDel = 
-            new ClusteredClientConnectionFactoryDelegate(id,
-                     locatorURI, serverPeer.getVersion(), clientPing);
-         
-         setFailoverDelegates(clusteredDel, replicants);
-         
-         delegate = clusteredDel;
+         //We may have no clustered post office deployed, in which case a clustered connection factory
+         //behaves like a standard connection factory
+         if (replicator != null)
+         {                        
+            // First we must replicate the delegate across the cluster so that all the
+            // ConnectionFactoryJNDIMapper instances on different nodes have access to the list of
+            // local connection factories so they can be added to the clustered connection factory
+   
+            replicator.putReplicant(CF_PREFIX + uniqueName, delegate);
+            
+            // Get the list of delegates
+            
+            Map replicants = replicator.getReplicants(CF_PREFIX + uniqueName);
+            
+            //Create a clustered delegate which contains the array of the local delegates
+            //and failover indexes
+            
+            ClusteredClientConnectionFactoryDelegate clusteredDel = 
+               new ClusteredClientConnectionFactoryDelegate(id,
+                        locatorURI, serverPeer.getVersion(), clientPing);
+            
+            setFailoverDelegates(clusteredDel, replicants);
+            
+            delegate = clusteredDel;
+         }
       }
       
       ConnectionFactoryAdvised connFactoryAdvised = new ConnectionFactoryAdvised(endpoint);
@@ -185,11 +190,16 @@
       
       if (clustered)
       {
+         setupReplicator();
+         
          // Remove from replicants
 
-         setUpReplicator();
-
-         replicator.removeReplicant(CF_PREFIX + uniqueName);
+         if (replicator != null)
+         {         
+            //There may be no clustered post office deployed
+            replicator.removeReplicant(CF_PREFIX + uniqueName);
+         }
+         
       }
       
       JMSDispatcher.instance.unregisterTarget(new Integer(endpoint.getID()));
@@ -289,13 +299,25 @@
    
    // Public --------------------------------------------------------
    
+   public void injectReplicator(Replicator replicator)
+   {
+      this.replicator = replicator;
+      
+      replicator.registerListener(this);
+   }
+   
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------
    
    // Private -------------------------------------------------------
    
+   private void setupReplicator() throws Exception
+   {
+      this.serverPeer.getQueuePostOfficeInstance();
+   }
    
+   
    private void setFailoverDelegates(ClusteredClientConnectionFactoryDelegate cf,
                                      Map replicants)
    {
@@ -365,20 +387,5 @@
       cf.setFailoverDelegates(delegates, failoverIndexes);
    }
 
-   private void setUpReplicator() throws Exception
-   {
-      if (replicator == null)
-      {
-         replicator = serverPeer.getDataReplicator();
-
-         if (replicator == null)
-         {
-            throw new IllegalStateException("Cannot get replicator from ServerPeer!");
-         }
-
-         replicator.registerListener(this);
-      }
-   }
-
    // Inner classes -------------------------------------------------
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-02 15:51:53 UTC (rev 1688)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-02 15:53:51 UTC (rev 1689)
@@ -54,4 +54,6 @@
    public static final String REMOTING_CONNECTION = "REMOTING_CONNECTION";
    
    public static final String CF_FAILOVER_INDEXES = "CF_FAIL_IND";
+   
+   public static final String CONNECTION_VERSION = "CONNECTION_VERSION";
 }



From validimir.ralev at jboss.com  Sat Dec  2 16:12:04 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 02 Dec 2006 16:12:04 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch2/lib  ...
Message-ID: <E1Gqc9U-0000tI-0M@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/02 16:12:04

  Modified:    repository.jboss.com/izpack/3.9.0.jboss.patch2/lib 
                        standalone-compiler.jar
  Log:
  MB,KB... localization
  
  Revision  Changes    Path
  1.3       +317 -288  /repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/standalone-compiler.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 17:58:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 17:58:50 -0500
Subject: [jboss-cvs] JBossBlog SVN: r33 - in trunk: .
	blog-core/src/etc/META-INF blog-core/src/etc/conf/hibernate
	blog-core/src/java/org/jboss/blog/model
	blog-core/src/java/org/jboss/blog/model/impl
	blog-core/src/java/org/jboss/blog/service/model
	blog-core/src/java/org/jboss/blog/service/model/rome
	blog-core/src/java/org/jboss/blog/service/store
	blog-core/src/java/org/jboss/blog/service/store/hibernate
	blog-core/src/java/org/jboss/blog/service/store/model
Message-ID: <E1Gqdoo-0002Tp-3T@committer01.frg.pub.inap.atl.jboss.com>

Author: adamw
Date: 2006-12-02 17:58:36 -0500 (Sat, 02 Dec 2006)
New Revision: 33

Added:
   trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogItem.java
   trunk/blog-core/src/java/org/jboss/blog/model/BlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java
   trunk/blog-core/src/java/org/jboss/blog/service/model/rome/
   trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java
Removed:
   trunk/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java
Modified:
   trunk/blog-core/src/etc/META-INF/jboss-service.xml
   trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml
   trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java
   trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/model/BlogModel.java
   trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java
   trunk/jbossblog.iws
Log:
http://jira.jboss.com/jira/browse/JBBLOG-13

Modified: trunk/blog-core/src/etc/META-INF/jboss-service.xml
===================================================================
--- trunk/blog-core/src/etc/META-INF/jboss-service.xml	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/etc/META-INF/jboss-service.xml	2006-12-02 22:58:36 UTC (rev 33)
@@ -58,9 +58,9 @@
         <depends optional-attribute-name="DelegateModelService"
                  proxy-type="attribute">blog:service=RomeParsingModel</depends>
     </mbean>
-    <mbean code="org.jboss.blog.service.model.RomeParsingBlogModelService"
+    <mbean code="org.jboss.blog.service.model.rome.RomeParsingBlogModelService"
            name="blog:service=RomeParsingModel"
-           xmbean-dd="org/jboss/blog/service/model/RomeParsingBlogModelService.xml">
+           xmbean-dd="org/jboss/blog/service/model/rome/RomeParsingBlogModelService.xml">
     </mbean>
 
     <!-- Permissions service -->

Modified: trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml
===================================================================
--- trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml	2006-12-02 22:58:36 UTC (rev 33)
@@ -35,9 +35,11 @@
         <mapping resource="org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml"/>
         <mapping resource="org/jboss/blog/service/store/hibernate/HBlogModelPost.hbm.xml"/>
         <mapping resource="org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml"/>
+        <mapping resource="org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml"/>
 
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogModel" usage="read-write" />
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogModelPost" usage="read-write" />
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogPost" usage="read-write" />
+        <class-cache class="org.jboss.blog.service.store.hibernate.HBlogComment" usage="read-write" />
     </session-factory>
 </hibernate-configuration>
\ No newline at end of file

Added: trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogComment.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogComment.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,7 @@
+package org.jboss.blog.model;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public abstract class AbstractBlogComment extends AbstractBlogItem implements BlogComment {
+}

Added: trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogItem.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogItem.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogItem.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,42 @@
+package org.jboss.blog.model;
+
+import java.text.DateFormat;
+import java.util.Locale;
+
+/**
+ * A base class for {@link BlogItem} implementations, handling date methods.
+ * Not thread safe.
+ * @author Adam Warski (adamw at aster.pl)
+ */
+public abstract class AbstractBlogItem implements BlogItem {
+    private boolean dateInitialized;
+    private boolean timeInitialized;
+
+    private String createdDate;
+    private String createdTime;
+
+    public String getCreatedDate() {
+        if (!dateInitialized) {
+            createdDate = DateFormat.getDateInstance(DateFormat.FULL,
+                Locale.getDefault()).format(getCreated());
+            dateInitialized = true;
+        }
+
+        return createdDate;
+    }
+
+    public String getCreatedTime() {
+        if (!timeInitialized) {
+            createdTime = DateFormat.getTimeInstance(DateFormat.SHORT,
+                Locale.getDefault()).format(getCreated());
+            timeInitialized = true;
+        }
+
+        return createdTime;
+    }      
+
+    public int compareTo(Object o) {
+        BlogPost post = (BlogPost) o;
+        return post.getCreated().compareTo(getCreated());
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -7,7 +7,7 @@
  * A base class for {@link BlogModel} implementations.
  * @author Adam Warski (adamw at aster.pl)
  */
-public abstract class AbstractBlogModel implements BlogModel {
+public abstract class AbstractBlogModel extends AbstractBlogItem implements BlogModel {
     public BlogPost getPostByGuid(String guid)
             throws BlogPostDoesNotExistException {
         for (Iterator iter = getPosts().iterator(); iter.hasNext();) {

Modified: trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -2,23 +2,19 @@
 
 import org.jboss.blog.tools.BlogTools;
 
-import java.util.Locale;
-import java.text.DateFormat;
-
 /**
  * A base class for {@link BlogPost} implementations, handling title-as-id
  * and date methods. Not thread safe.
  * @author Adam Warski (adamw at aster.pl)
  */
-public abstract class AbstractBlogPost implements BlogPost {
+public abstract class AbstractBlogPost extends AbstractBlogItem implements BlogPost {
     private boolean titleAsIdInitialized;
-    private boolean dateInitialized;
-    private boolean timeInitialized;
-
-    private String createdDate;
-    private String createdTime;
     private String titleAsId;
 
+    public boolean hasComments() {
+        return ((getComments() == null) || (getComments().size() == 0));
+    }
+
     public String getTitleAsId() {
         if (!titleAsIdInitialized) {
             titleAsId = BlogTools.convertToId(getTitle());
@@ -27,29 +23,4 @@
 
         return titleAsId;
     }
-
-    public String getCreatedDate() {
-        if (!dateInitialized) {
-            createdDate = DateFormat.getDateInstance(DateFormat.FULL,
-                Locale.getDefault()).format(getCreated());
-            dateInitialized = true;
-        }
-
-        return createdDate;
-    }
-
-    public String getCreatedTime() {
-        if (!timeInitialized) {
-            createdTime = DateFormat.getTimeInstance(DateFormat.SHORT,
-                Locale.getDefault()).format(getCreated());
-            timeInitialized = true;
-        }
-
-        return createdTime;
-    }
-
-    public int compareTo(Object o) {
-        BlogPost post = (BlogPost) o;
-        return post.getCreated().compareTo(getCreated());
-    }
 }

Added: trunk/blog-core/src/java/org/jboss/blog/model/BlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogComment.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogComment.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,8 @@
+package org.jboss.blog.model;
+
+/**
+ * An interface representing a single blog comment
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public interface BlogComment extends BlogItem {
+}

Added: trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,17 @@
+package org.jboss.blog.model;
+
+import java.util.Date;
+
+/**
+ * A base class for blog items: models, posts and comments.
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public interface BlogItem extends Comparable{
+    public String getAuthor();
+    public String getTitle();
+    public String getDescription();
+    public Date getCreated();
+    public String getCreatedDate();
+    public String getCreatedTime();    
+    public String getLink();
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/model/BlogModel.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogModel.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogModel.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -1,6 +1,5 @@
 package org.jboss.blog.model;
 
-import java.util.Date;
 import java.util.Set;
 import java.util.List;
 
@@ -9,13 +8,7 @@
  * posts, together with basic blog information.
  * @author Adam Warski (adamw at aster.pl)
  */
-public interface BlogModel {
-    public String getAuthor();
-    public String getTitle();
-    public String getDescription();
-    public String getLink();
-    public Date getCreated();
-
+public interface BlogModel extends BlogItem {
     /**
      * Gets all posts that are in this model. Invoking this method is
      * discouraged. If possible, use {@link BlogModel#getPosts(int, int)}.

Modified: trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -1,21 +1,14 @@
 package org.jboss.blog.model;
 
-import java.util.Date;
 import java.util.Set;
+import java.util.List;
 
 /**
  * An interface representing a single blog post.
  * @author Adam Warski (adamw at aster.pl)
  */
-public interface BlogPost extends Comparable {
-    public String getAuthor();
-    public String getTitle();
+public interface BlogPost extends BlogItem {
     public String getTitleAsId();
-    public String getDescription();
-    public Date getCreated();
-    public String getCreatedDate();
-    public String getCreatedTime();
-    public String getLink();
     public String getGuid();
 
     /**
@@ -27,6 +20,22 @@
 
     /**
      *
+     * @return True iff this post has any comments.
+     */
+    public boolean hasComments();
+
+    /**
+     *
+     * @return A list of all comments for this item. Objects in the list
+     * implements the {@link BlogComment} interface. If the blog doesn't
+     * have/support comments, null is returned (this is different from the
+     * situation where a blog supports comments, but there are no comments
+     * to this post - in this case, an empty list is returned).
+     */
+    public List getComments();
+
+    /**
+     *
      * @return Immutable set of {@link java.lang.String} - name of categories to
      * which this post belongs.
      */

Added: trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,47 @@
+package org.jboss.blog.model.impl;
+
+import org.jboss.blog.model.AbstractBlogComment;
+
+import java.util.Date;
+
+/**
+ * A simple java-bean implementation of the comment interface.
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class BlogCommentImpl extends AbstractBlogComment {
+    private String author;
+    private String title;
+    private String description;
+    private Date created;
+    private String link;
+
+    public BlogCommentImpl(String author, String title,
+                           String description, Date created,
+                           String link) {
+        this.author = author;
+        this.title = title;
+        this.description = description;
+        this.created = created;
+        this.link = link;
+    }
+
+    public String getAuthor() {
+        return author;
+    }
+
+    public String getTitle() {
+        return title;
+    }
+
+    public String getDescription() {
+        return description;
+    }
+
+    public Date getCreated() {
+        return created;
+    }
+
+    public String getLink() {
+        return link;
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -19,10 +19,11 @@
     private String guid;
     private Set categories;
     private String commentLink;
+    private List comments;
 
     public BlogPostImpl(String author, String title, String description,
                         Date created, String link, String guid,
-                        Set categories, String commentLink) {
+                        Set categories, String commentLink, List comments) {
         this.author = author;
         this.title = title;
         this.description = description;
@@ -31,6 +32,7 @@
         this.guid = guid;
         this.categories = categories;
         this.commentLink = commentLink;
+        this.comments = comments;
     }
 
     public String getAuthor() {
@@ -64,4 +66,8 @@
     public String getCommentLink() {
         return commentLink;
     }
+
+    public List getComments() {
+        return comments;
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -8,6 +8,6 @@
  */
 public class EmptyBlogPost extends BlogPostImpl {
     public EmptyBlogPost() {
-        super("", "", "", new Date(), "", "", new HashSet(), null);
+        super("", "", "", new Date(), "", "", new HashSet(), null, null);
     }
 }

Deleted: trunk/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -1,98 +0,0 @@
-package org.jboss.blog.service.model;
-
-import org.jboss.blog.model.BlogModel;
-import org.jboss.blog.model.BlogModelDoesNotExistException;
-import org.jboss.blog.model.impl.BlogPostImpl;
-import org.jboss.blog.model.impl.BlogModelImpl;
-import org.jboss.blog.BlogName;
-import org.jboss.blog.service.AbstractBlogService;
-import org.jboss.blog.rome.CommentRssModule;
-import org.jboss.blog.tools.BlogTools;
-
-import java.util.*;
-import java.net.URL;
-import java.io.IOException;
-
-import com.sun.syndication.io.SyndFeedInput;
-import com.sun.syndication.io.XmlReader;
-import com.sun.syndication.io.FeedException;
-import com.sun.syndication.feed.synd.SyndFeed;
-import com.sun.syndication.feed.synd.SyndEntry;
-import com.sun.syndication.feed.synd.SyndCategory;
-
-/**
- * @author Adam Warski (adamw at aster.pl)
- *
- * @jmx.mbean
- * @jboss.xmbean
- */
-public class RomeParsingBlogModelService extends AbstractBlogService implements BlogModelService {
-    public RomeParsingBlogModelService() {
-
-    }
-
-    private Set getStringCategories(List categories) {
-        if (categories == null) {
-            return null;
-        }
-
-        Set ret = new HashSet();
-        for (Iterator iter = categories.iterator(); iter.hasNext();) {
-            ret.add(((SyndCategory) iter.next()).getName());
-        }
-
-        return ret;
-    }
-
-    /**
-     * @jmx.managed-operation
-     * @jmx.managed-parameter type="org.jboss.blog.BlogName"
-     */
-    public BlogModel getBlogModel(BlogName name) throws BlogModelDoesNotExistException {
-        if (name.getId() == null) {
-            throw new BlogModelDoesNotExistException("No blog selected (null blog id)");
-        }
-
-        // Parsing the feed, which's address is the id of the selected blog.
-        SyndFeedInput input = new SyndFeedInput();
-        SyndFeed inFeed;
-        try {
-            inFeed = input.build(new XmlReader(new URL(name.getId()).openStream()));
-        } catch (IOException e) {
-            throw new BlogModelDoesNotExistException(e);
-        } catch (FeedException e) {
-            throw new BlogModelDoesNotExistException(e);
-        }
-        
-        List posts = new ArrayList();
-
-        String defaultAuthor = inFeed.getAuthor();
-        for (Iterator iter = inFeed.getEntries().iterator(); iter.hasNext();) {
-            SyndEntry post = (SyndEntry) iter.next();
-
-            CommentRssModule commRssModule = (CommentRssModule)
-                    post.getModule("http://wellformedweb.org/CommentAPI/");
-            String commentsRss = null;
-            if (commRssModule != null) {
-                commentsRss = commRssModule.getCommentRss();
-                if (commentsRss != null) {
-                    commentsRss = commentsRss.trim();
-                }
-            }
-
-            String author = post.getAuthor();
-            posts.add(new BlogPostImpl(
-                    BlogTools.isEmpty(author) ? defaultAuthor : author,
-                    post.getTitle(), post.getDescription().getValue(),
-                    post.getPublishedDate(), post.getLink(),
-                    post.getUri(),
-                    Collections.unmodifiableSet(getStringCategories(post.getCategories())),
-                    commentsRss));
-        }
-
-        return new BlogModelImpl(inFeed.getAuthor(), inFeed.getTitle(),
-                inFeed.getDescription(), inFeed.getLink(),
-                inFeed.getPublishedDate(), Collections.unmodifiableList(posts),
-                Collections.unmodifiableSet(getStringCategories(inFeed.getCategories())));
-    }
-}

Added: trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,59 @@
+package org.jboss.blog.service.model.rome;
+
+import org.jboss.blog.model.impl.BlogPostImpl;
+import org.jboss.blog.model.impl.BlogCommentImpl;
+import org.jboss.blog.tools.BlogTools;
+
+import java.util.*;
+import java.net.URL;
+
+import com.sun.syndication.io.SyndFeedInput;
+import com.sun.syndication.io.XmlReader;
+import com.sun.syndication.feed.synd.SyndFeed;
+import com.sun.syndication.feed.synd.SyndEntry;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class RomeBlogPost extends BlogPostImpl {
+    private boolean commentsInitialized;
+    private List comments;
+
+    public RomeBlogPost(String author, String title, String description, Date created,
+                        String link, String guid, Set categories, String commentLink) {
+        super(author, title, description, created, link, guid, categories, commentLink, null);
+    }
+
+    public List getComments() {
+        if (!commentsInitialized) {
+            commentsInitialized = true;
+
+            if (getCommentLink() == null) {
+                return null;
+            }
+
+            try {
+                SyndFeedInput input = new SyndFeedInput();
+                SyndFeed inFeed;
+                inFeed = input.build(new XmlReader(new URL(getCommentLink()).openStream()));
+
+                comments = new ArrayList();
+
+                String defaultAuthor = inFeed.getAuthor();
+                for (Iterator iter = inFeed.getEntries().iterator(); iter.hasNext();) {
+                    SyndEntry post = (SyndEntry) iter.next();
+
+                    String author = post.getAuthor();
+                    comments.add(new BlogCommentImpl(
+                            BlogTools.isEmpty(author) ? defaultAuthor : author,
+                            post.getTitle(), post.getDescription().getValue(),
+                            post.getPublishedDate(), post.getLink()));
+                }
+            } catch (Exception e) {
+                comments = null;
+            }
+        }
+
+        return comments;
+    }
+}

Copied: trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java (from rev 26, trunk/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java)
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java	2006-11-11 14:25:51 UTC (rev 26)
+++ trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,99 @@
+package org.jboss.blog.service.model.rome;
+
+import org.jboss.blog.model.BlogModel;
+import org.jboss.blog.model.BlogModelDoesNotExistException;
+import org.jboss.blog.model.impl.BlogPostImpl;
+import org.jboss.blog.model.impl.BlogModelImpl;
+import org.jboss.blog.BlogName;
+import org.jboss.blog.service.AbstractBlogService;
+import org.jboss.blog.service.model.BlogModelService;
+import org.jboss.blog.rome.CommentRssModule;
+import org.jboss.blog.tools.BlogTools;
+
+import java.util.*;
+import java.net.URL;
+import java.io.IOException;
+
+import com.sun.syndication.io.SyndFeedInput;
+import com.sun.syndication.io.XmlReader;
+import com.sun.syndication.io.FeedException;
+import com.sun.syndication.feed.synd.SyndFeed;
+import com.sun.syndication.feed.synd.SyndEntry;
+import com.sun.syndication.feed.synd.SyndCategory;
+
+/**
+ * @author Adam Warski (adamw at aster.pl)
+ *
+ * @jmx.mbean
+ * @jboss.xmbean
+ */
+public class RomeParsingBlogModelService extends AbstractBlogService implements BlogModelService {
+    public RomeParsingBlogModelService() {
+
+    }
+
+    private Set getStringCategories(List categories) {
+        if (categories == null) {
+            return null;
+        }
+
+        Set ret = new HashSet();
+        for (Iterator iter = categories.iterator(); iter.hasNext();) {
+            ret.add(((SyndCategory) iter.next()).getName());
+        }
+
+        return ret;
+    }
+
+    /**
+     * @jmx.managed-operation
+     * @jmx.managed-parameter type="org.jboss.blog.BlogName"
+     */
+    public BlogModel getBlogModel(BlogName name) throws BlogModelDoesNotExistException {
+        if (name.getId() == null) {
+            throw new BlogModelDoesNotExistException("No blog selected (null blog id)");
+        }
+
+        // Parsing the feed, which's address is the id of the selected blog.
+        SyndFeedInput input = new SyndFeedInput();
+        SyndFeed inFeed;
+        try {
+            inFeed = input.build(new XmlReader(new URL(name.getId()).openStream()));
+        } catch (IOException e) {
+            throw new BlogModelDoesNotExistException(e);
+        } catch (FeedException e) {
+            throw new BlogModelDoesNotExistException(e);
+        }
+        
+        List posts = new ArrayList();
+
+        String defaultAuthor = inFeed.getAuthor();
+        for (Iterator iter = inFeed.getEntries().iterator(); iter.hasNext();) {
+            SyndEntry post = (SyndEntry) iter.next();
+
+            CommentRssModule commRssModule = (CommentRssModule)
+                    post.getModule("http://wellformedweb.org/CommentAPI/");
+            String commentsRss = null;
+            if (commRssModule != null) {
+                commentsRss = commRssModule.getCommentRss();
+                if (commentsRss != null) {
+                    commentsRss = commentsRss.trim();
+                }
+            }
+
+            String author = post.getAuthor();
+            posts.add(new RomeBlogPost(
+                    BlogTools.isEmpty(author) ? defaultAuthor : author,
+                    post.getTitle(), post.getDescription().getValue(),
+                    post.getPublishedDate(), post.getLink(),
+                    post.getUri(),
+                    Collections.unmodifiableSet(getStringCategories(post.getCategories())),
+                    commentsRss));
+        }
+
+        return new BlogModelImpl(inFeed.getAuthor(), inFeed.getTitle(),
+                inFeed.getDescription(), inFeed.getLink(),
+                inFeed.getPublishedDate(), Collections.unmodifiableList(posts),
+                Collections.unmodifiableSet(getStringCategories(inFeed.getCategories())));
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -86,6 +86,15 @@
     public void deletePost(ModifiableBlogPost post)
             throws IllegalArgumentException;
 
+    /**
+     * Deletes the given comment.
+     * @param comment Comment to delete.
+     * @throws IllegalArgumentException If comment is null, is a new
+     * comment or wasn't obtained from this store service.
+     */
+    public void deleteComment(ModifiableBlogComment comment)
+            throws IllegalArgumentException;
+
     // Factory methods
 
     /**
@@ -107,4 +116,12 @@
      * blog model and saved.
      */
     public ModifiableBlogPost newBlogPost();
+
+    /**
+     * Creates a new blog comment. To later save the it, simply add it
+     * to a post.
+     * @return A new blog comment, which can be later added to a
+     * blog post and saved.
+     */
+    public ModifiableBlogComment newBlogComment();
 }

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,26 @@
+<?xml version="1.0"?>
+<!DOCTYPE hibernate-mapping PUBLIC
+      "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
+          "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
+
+<hibernate-mapping package="org.jboss.blog.service.store.hibernate">
+    <class name="HBlogComment"
+           table="BLOG_COMMENTS">
+        <id name="id" column="COMMENT_ID">
+            <generator class="native" />
+        </id>
+
+        <many-to-one name="post" column="POST" not-null="true" class="HBlogPost" />
+        
+        <property name="author" column="AUTHOR" not-null="true" />
+
+        <property name="created" column="CREATED" not-null="true" type="timestamp"
+                  update="false" />
+
+        <property name="title" column="TITLE" not-null="true" />
+
+        <property name="link" column="LINK" />
+        
+        <property name="description" column="DESCRIPTION" type="text" />
+    </class>
+</hibernate-mapping>
\ No newline at end of file

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,79 @@
+package org.jboss.blog.service.store.hibernate;
+
+import org.jboss.blog.model.AbstractBlogComment;
+import org.jboss.blog.service.store.model.ModifiableBlogComment;
+
+import java.util.Date;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class HBlogComment extends AbstractBlogComment implements ModifiableBlogComment {
+    private Integer id;
+    private String author;
+    private String title;
+    private String description;
+    private Date created;
+    private String link;
+    private HBlogPost post;
+
+    public HBlogComment() {
+
+    }
+
+    public Integer getId() {
+        return id;
+    }
+
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    public String getAuthor() {
+        return author;
+    }
+
+    public HBlogPost getPost() {
+        return post;
+    }
+
+    public void setPost(HBlogPost post) {
+        this.post = post;
+    }
+
+    public void setAuthor(String author) {
+        this.author = author;
+    }
+
+    public String getTitle() {
+        return title;
+    }
+
+    public void setTitle(String title) {
+        this.title = title;
+    }
+
+    public String getDescription() {
+        return description;
+    }
+
+    public void setDescription(String description) {
+        this.description = description;
+    }
+
+    public Date getCreated() {
+        return created;
+    }
+
+    public void setCreated(Date created) {
+        this.created = created;
+    }
+
+    public String getLink() {
+        return link;
+    }
+
+    public void setLink(String link) {
+        this.link = link;
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -141,9 +141,12 @@
         if (posts == null) {
             posts = new ArrayList();
             modelPosts = getModelPosts();
+            HibernateBlogStoreService storeService = getStoreService();
 
             for (Iterator iter = modelPosts.iterator(); iter.hasNext();) {
-                posts.add(((HBlogModelPost) iter.next()).getPost());
+                HBlogPost post = ((HBlogModelPost) iter.next()).getPost();
+                post.setStoreService(storeService);
+                posts.add(post);
             }
 
             Collections.sort(posts);

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml	2006-12-02 22:58:36 UTC (rev 33)
@@ -31,5 +31,10 @@
             <key column="POST_ID" not-null="true" />
             <one-to-many class="HBlogModelPost" />
         </bag>
+
+        <bag name="comments" order-by="created desc" inverse="true">
+            <key column="POST_ID" not-null="true" />
+            <one-to-many class="HBlogComment" />
+        </bag>
     </class>
 </hibernate-mapping>
\ No newline at end of file

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -1,6 +1,7 @@
 package org.jboss.blog.service.store.hibernate;
 
 import org.jboss.blog.service.store.model.ModifiableBlogPost;
+import org.jboss.blog.service.store.model.ModifiableBlogComment;
 import org.jboss.blog.model.AbstractBlogPost;
 import org.jboss.blog.tools.BlogTools;
 
@@ -20,9 +21,12 @@
     private String titleAsId;
     private Date created;
 
+    private List comments;
     private List modelPosts;
     private Set categories;
 
+    private HibernateBlogStoreService storeService;
+
     public HBlogPost() {
 
     }
@@ -104,6 +108,14 @@
         this.created = created;
     }
 
+    public List getComments() {
+        return comments;
+    }
+
+    public void setComments(List comments) {
+        this.comments = comments;
+    }
+
     public List getModelPosts() {
         return modelPosts;
     }
@@ -122,4 +134,25 @@
 
         return Collections.unmodifiableSet(categories);
     }
+
+    public HibernateBlogStoreService getStoreService() {
+        return storeService;
+    }
+
+    public void setStoreService(HibernateBlogStoreService storeService) {
+        this.storeService = storeService;
+    }
+
+    public void addComment(ModifiableBlogComment comment) throws IllegalArgumentException {
+        HibernateBlogStoreService storeService = getStoreService();
+        HBlogComment hcomment = storeService.castAndAssertBlogComment(comment);
+
+        storeService.addComment(this, hcomment);
+    }
+
+    public void removeComment(ModifiableBlogComment comment) throws IllegalArgumentException {
+        HibernateBlogStoreService storeService = getStoreService();
+
+        storeService.deleteComment(comment);
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -4,6 +4,7 @@
 import org.jboss.blog.service.store.model.ModifiableBlogModel;
 import org.jboss.blog.service.store.model.ModifiableBlogPost;
 import org.jboss.blog.service.store.model.BlogModelAlreadyExistsException;
+import org.jboss.blog.service.store.model.ModifiableBlogComment;
 import org.jboss.blog.service.AbstractBlogService;
 import org.jboss.blog.BlogName;
 import org.jboss.blog.model.BlogModelDoesNotExistException;
@@ -63,6 +64,15 @@
         return (HBlogPost) post;
     }
 
+    HBlogComment castAndAssertBlogComment(ModifiableBlogComment comment) {
+        BlogTools.assertNotNull(comment, "Blog comment cannot be null.");
+        if (!(comment instanceof HBlogComment)) {
+            throw new IllegalArgumentException("Comment must be obtained from this store service.");
+        }
+
+        return (HBlogComment) comment;
+    }
+
     /**
      * @jmx.managed-operation
      */
@@ -160,8 +170,16 @@
     public ModifiableBlogPost newBlogPost() {
         HBlogPost post = new HBlogPost();
         post.setModelPosts(new ArrayList());
+        post.setStoreService(this);
 
         return post;
+    }    
+
+    /**
+     * @jmx.managed-operation
+     */
+    public ModifiableBlogComment newBlogComment() {
+        return new HBlogComment();
     }
 
     /**
@@ -226,6 +244,19 @@
         sf.getCurrentSession().delete(hpost);
     }
 
+    /**
+     * @jmx.managed-operation
+     * @jmx.managed-parameter type="org.jboss.blog.service.store.model.ModifiableBlogComment"
+     */
+    public void deleteComment(ModifiableBlogComment comment) {
+        HBlogComment hcomment = castAndAssertBlogComment(comment);
+        if (hcomment.getId() == null) {
+            throw new IllegalArgumentException("Cannot delete a new comment.");
+        }
+
+        sf.getCurrentSession().delete(hcomment);
+    }
+
     //
 
     /**
@@ -275,6 +306,21 @@
     }
 
     /**
+     * To the given blog post, adds the given comment.
+     * @param post Post to which the comment should be added.
+     * @param comment Comment to add.
+     */
+    void addComment(HBlogPost post, HBlogComment comment) {
+        HBlogPost hpost = castAndAssertBlogPost(post);
+        HBlogComment hcomment = castAndAssertBlogComment(comment);
+
+        hcomment.setPost(hpost);
+
+        hpost.getComments().add(hcomment);
+        sf.getCurrentSession().saveOrUpdate(hcomment);
+    }
+
+    /**
      * Gets posts for the given model which, when sorted, are between the given
      * indexes in the list of all posts.
      * @param model Model for which to get the posts.
@@ -284,11 +330,17 @@
      * in the list of all posts.
      */
     List getPosts(HBlogModel model, int from, int to) {
-        return sf.getCurrentSession().createQuery(
+        List posts = sf.getCurrentSession().createQuery(
                 "select bmp.post from HBlogModelPost bmp where bmp.model = :model " +
                         "order by bmp.post.created desc")
                 .setEntity("model", model).setFirstResult(from)
                 .setMaxResults(to-from).list();
+
+        for (Iterator iter = posts.iterator(); iter.hasNext();) {
+            ((HBlogPost) iter.next()).setStoreService(this);
+        }
+
+        return posts;
     }
 
     /**
@@ -299,9 +351,13 @@
      * post exists.
      */
     HBlogPost getPostByTitleAsId(HBlogModel model, String titleAsId) {
-        return (HBlogPost) sf.getCurrentSession().createQuery(
+        HBlogPost ret = (HBlogPost) sf.getCurrentSession().createQuery(
                 "select bmp.post from HBlogModelPost bmp where bmp.model = :model " +
                         "and bmp.post.titleAsId = :titleAsId").setEntity("model", model)
                 .setParameter("titleAsId", titleAsId).uniqueResult();
+
+        ret.setStoreService(this);
+
+        return ret;
     }
 }

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,9 @@
+package org.jboss.blog.service.store.model;
+
+import org.jboss.blog.model.BlogComment;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public interface ModifiableBlogComment extends ModifiableBlogItem, BlogComment {
+}

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -0,0 +1,16 @@
+package org.jboss.blog.service.store.model;
+
+import org.jboss.blog.model.BlogItem;
+
+import java.util.Date;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public interface ModifiableBlogItem extends BlogItem { 
+    public void setAuthor(String author);
+    public void setTitle(String title);
+    public void setDescription(String description);
+    public void setLink(String link);
+    public void setCreated(Date created);
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -3,20 +3,12 @@
 import org.jboss.blog.model.BlogModel;
 import org.jboss.blog.model.BlogPostDoesNotExistException;
 
-import java.util.Date;
 import java.util.Set;
-import java.util.List;
 
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
-public interface ModifiableBlogModel extends BlogModel {
-    public void setAuthor(String author);
-    public void setTitle(String title);
-    public void setDescription(String description);
-    public void setLink(String link);
-    public void setCreated(Date created);
-
+public interface ModifiableBlogModel extends BlogModel, ModifiableBlogItem {
     /**
      *
      * @return Set containg {@link ModifiableBlogModel#getCategory()} - name of

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java	2006-12-02 22:58:36 UTC (rev 33)
@@ -2,18 +2,32 @@
 
 import org.jboss.blog.model.BlogPost;
 
-import java.util.Date;
-import java.util.Set;
-
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
-public interface ModifiableBlogPost extends BlogPost {
-    public void setAuthor(String author);
-    public void setTitle(String title);
-    public void setDescription(String description);
-    public void setCreated(Date created);
-    public void setLink(String link);
+public interface ModifiableBlogPost extends BlogPost, ModifiableBlogItem {
     public void setGuid(String guid);
     public void setCommentLink(String commentLink);
+
+    /**
+     * Adds the given comment to this blog post. This method should be used
+     * instead of modifying the {@link ModifiableBlogPost#getComments()} ()}
+     * list.
+     * @param comment Comment to add.
+     * @throws IllegalArgumentException If comment is null, or
+     * it hasn't been obtained in a proper way.
+     */
+    public void addComment(ModifiableBlogComment comment)
+            throws IllegalArgumentException;
+
+    /**
+     * Removes the given comment from this blog post. This method should be used
+     * instead of modifying the {@link ModifiableBlogPost#getComments()}
+     * list.
+     * @param comment Post to remove.
+     * @throws IllegalArgumentException If either comment is null, or
+     * it hasn't been obtained in a proper way.
+     */
+    public void removeComment(ModifiableBlogComment comment)
+            throws IllegalArgumentException;
 }

Modified: trunk/jbossblog.iws
===================================================================
--- trunk/jbossblog.iws	2006-11-23 14:00:40 UTC (rev 32)
+++ trunk/jbossblog.iws	2006-12-02 22:58:36 UTC (rev 33)
@@ -17,12 +17,34 @@
   </component>
   <component name="ChangeListManager">
     <list default="true" name="Default" comment="">
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/caching/CachingBlogModelService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/caching/CachingBlogModelService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogComment.java" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogItem.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogItem.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogModel.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/etc/conf" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java" />
+      <change type="DELETED" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java" afterPath="" />
     </list>
   </component>
   <component name="ChangeListSynchronizer" />
@@ -147,44 +169,78 @@
   </component>
   <component name="FileEditorManager">
     <leaf>
-      <file leaf-file-name="hibernate.cfg.xml" pinned="false" current="true" current-in-tab="true">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
+      <file leaf-file-name="HBlogModel.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="37" column="29" selection-start="1755" selection-end="1755" vertical-scroll-proportion="0.888">
+            <state line="165" column="48" selection-start="4229" selection-end="4229" vertical-scroll-proportion="0.63022506">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogModel.hbm.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml">
+      <file leaf-file-name="HBlogComment.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="7" column="32" selection-start="310" selection-end="310" vertical-scroll-proportion="0.1640625">
+            <state line="38" column="0" selection-start="811" selection-end="811" vertical-scroll-proportion="0.511254">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="jboss-service.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml">
+      <file leaf-file-name="HBlogPost.hbm.xml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="76" column="73" selection-start="4033" selection-end="4033" vertical-scroll-proportion="1.0176">
+            <state line="34" column="66" selection-start="1240" selection-end="1240" vertical-scroll-proportion="0.8199357">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
+      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
       <file leaf-file-name="HibernateBlogStoreService.java" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="304" column="16" selection-start="10882" selection-end="10882" vertical-scroll-proportion="1.1136">
-              <folding>
-                <element signature="imports" expanded="true" />
-              </folding>
+            <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="1.0889621">
+              <folding />
             </state>
           </provider>
         </entry>
       </file>
+      <file leaf-file-name="HBlogPost.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="18" column="24" selection-start="588" selection-end="588" vertical-scroll-proportion="0.31350482">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="BlogPost.java" pinned="false" current="true" current-in-tab="true">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="22" column="51" selection-start="529" selection-end="529" vertical-scroll-proportion="0.50643086">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="PostEdit.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="16" column="13" selection-start="520" selection-end="520" vertical-scroll-proportion="-4.822076">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
     </leaf>
   </component>
   <component name="FindManager">
@@ -400,6 +456,40 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -480,6 +570,48 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -560,7 +692,7 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/caching" />
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
       </PATH>
@@ -582,6 +714,78 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/etc" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -655,7 +859,7 @@
       <showLibraryContents />
       <hideEmptyPackages />
       <abbreviatePackageNames />
-      <showStructure Favorites="false" PackagesPane="false" Scope="false" ProjectPane="false" />
+      <showStructure PackagesPane="false" ProjectPane="false" Scope="false" Favorites="false" />
       <autoscrollToSource />
       <autoscrollFromSource />
       <sortByType />
@@ -683,11 +887,11 @@
       <recent name="org.jboss.blog.service.configuration" />
     </key>
     <key name="MoveClassesOrPackagesDialog.RECENTS_KEY">
+      <recent name="org.jboss.blog.service.model.rome" />
       <recent name="org.jboss.blog.service.model.caching" />
       <recent name="org.jboss.blog.service.store.hibernate" />
       <recent name="org.jboss.blog.service.store.hibernate.filter" />
       <recent name="org.jboss.blog.model.impl" />
-      <recent name="org.jboss.blog.service.permissions" />
     </key>
   </component>
   <component name="RestoreUpdateTree" />
@@ -702,6 +906,18 @@
       <option name="ENABLE_SWING_INSPECTOR" value="false" />
       <module name="" />
     </configuration>
+    <configuration default="true" type="Applet" factoryName="Applet">
+      <module name="" />
+      <option name="MAIN_CLASS_NAME" />
+      <option name="HTML_FILE_NAME" />
+      <option name="HTML_USED" value="false" />
+      <option name="WIDTH" value="400" />
+      <option name="HEIGHT" value="300" />
+      <option name="POLICY_FILE" value="$APPLICATION_HOME_DIR$/bin/appletviewer.policy" />
+      <option name="VM_PARAMETERS" />
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
+      <option name="ALTERNATIVE_JRE_PATH" />
+    </configuration>
     <configuration default="true" type="JUnit" factoryName="JUnit" enabled="false" merge="false">
       <module name="" />
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
@@ -721,18 +937,6 @@
         <option name="Make" value="true" />
       </method>
     </configuration>
-    <configuration default="true" type="Applet" factoryName="Applet">
-      <module name="" />
-      <option name="MAIN_CLASS_NAME" />
-      <option name="HTML_FILE_NAME" />
-      <option name="HTML_USED" value="false" />
-      <option name="WIDTH" value="400" />
-      <option name="HEIGHT" value="300" />
-      <option name="POLICY_FILE" value="$APPLICATION_HOME_DIR$/bin/appletviewer.policy" />
-      <option name="VM_PARAMETERS" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-    </configuration>
     <configuration default="true" type="Remote" factoryName="Remote">
       <option name="USE_SOCKET_TRANSPORT" value="true" />
       <option name="SERVER_MODE" value="false" />
@@ -818,7 +1022,7 @@
   </component>
   <component name="ToolWindowManager">
     <frame x="0" y="25" width="1690" height="1004" extended-state="6" />
-    <editor active="false" />
+    <editor active="true" />
     <layout>
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="13" />
@@ -827,7 +1031,7 @@
       <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26118946" order="0" />
       <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32839224" order="1" />
       <window_info id="Structure" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24367674" order="7" />
-      <window_info id="Messages" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
+      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.39977092" order="6" />
       <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="4" />
       <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="10" />
@@ -936,127 +1140,107 @@
     <option name="myLastEditedConfigurable" value="Project Default" />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="33" column="42" selection-start="1342" selection-end="1342" vertical-scroll-proportion="0.81280786">
+        <state line="86" column="43" selection-start="3364" selection-end="3364" vertical-scroll-proportion="0.5615942">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/blog_view.xhtml">
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="66" column="33" selection-start="2989" selection-end="2989" vertical-scroll-proportion="0.7941681">
+        <state line="42" column="79" selection-start="2231" selection-end="2231" vertical-scroll-proportion="0.77490777">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="34" column="99" selection-start="1271" selection-end="1347" vertical-scroll-proportion="0.8279221">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/view.xhtml">
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModelPost.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="19" column="54" selection-start="927" selection-end="927" vertical-scroll-proportion="0.47420964">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml">
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="60" column="37" selection-start="2753" selection-end="2753" vertical-scroll-proportion="0.8198052">
+        <state line="165" column="48" selection-start="4229" selection-end="4229" vertical-scroll-proportion="0.63022506">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="35" column="71" selection-start="1322" selection-end="1322" vertical-scroll-proportion="0.817757">
+        <state line="34" column="66" selection-start="1240" selection-end="1240" vertical-scroll-proportion="0.8199357">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="81" column="31" selection-start="2205" selection-end="2205" vertical-scroll-proportion="0.21028037">
+        <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml">
-      <provider editor-type-id="com.intellij.jsf.ui.FacesConfigEditorProvider">
-        <state />
-      </provider>
-      <provider editor-type-id="com.intellij.jsf.yfilesGraph.editor.FacesNavigationFileEditorProvider">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="16" column="103" selection-start="748" selection-end="748" vertical-scroll-proportion="0.38961038">
+        <state line="38" column="0" selection-start="811" selection-end="811" vertical-scroll-proportion="0.511254">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/caching/BlogLock.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="5" column="21" selection-start="224" selection-end="224" vertical-scroll-proportion="0.088652484">
+        <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="1.0889621">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/BlogName.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="12" column="13" selection-start="334" selection-end="334" vertical-scroll-proportion="-0.2578125">
+        <state line="18" column="24" selection-start="588" selection-end="588" vertical-scroll-proportion="0.31350482">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/caching/CachingBlogModelService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="19" column="47" selection-start="585" selection-end="585" vertical-scroll-proportion="0.2578125">
+        <state line="7" column="17" selection-start="168" selection-end="168" vertical-scroll-proportion="0.1688103">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="76" column="73" selection-start="4033" selection-end="4033" vertical-scroll-proportion="1.0176">
+        <state line="16" column="13" selection-start="520" selection-end="520" vertical-scroll-proportion="-4.822076">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="304" column="16" selection-start="10882" selection-end="10882" vertical-scroll-proportion="1.1136">
-          <folding>
-            <element signature="imports" expanded="true" />
-          </folding>
+        <state line="12" column="13" selection-start="273" selection-end="273" vertical-scroll-proportion="0.19292605">
+          <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="7" column="32" selection-start="310" selection-end="310" vertical-scroll-proportion="0.1640625">
+        <state line="13" column="46" selection-start="425" selection-end="425" vertical-scroll-proportion="0.31350482">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="37" column="29" selection-start="1755" selection-end="1755" vertical-scroll-proportion="0.888">
+        <state line="22" column="51" selection-start="529" selection-end="529" vertical-scroll-proportion="0.50643086">
           <folding />
         </state>
       </provider>



From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 18:03:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 18:03:15 -0500
Subject: [jboss-cvs] JBossBlog SVN: r34 - in trunk: .
	blog-core/src/etc/META-INF
	blog-core/src/java/org/jboss/blog/service/configuration
	blog-core/src/web/WEB-INF
Message-ID: <E1Gqdt5-0002iV-5Q@committer01.frg.pub.inap.atl.jboss.com>

Author: adamw
Date: 2006-12-02 18:03:09 -0500 (Sat, 02 Dec 2006)
New Revision: 34

Modified:
   trunk/blog-core/src/etc/META-INF/jboss-service.xml
   trunk/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java
   trunk/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java
   trunk/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java
   trunk/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java
   trunk/blog-core/src/web/WEB-INF/portlet-instances.xml
   trunk/blog-core/src/web/WEB-INF/web.xml
   trunk/jbossblog.iws
Log:
http://jira.jboss.com/jira/browse/JBBLOG-13

Modified: trunk/blog-core/src/etc/META-INF/jboss-service.xml
===================================================================
--- trunk/blog-core/src/etc/META-INF/jboss-service.xml	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/etc/META-INF/jboss-service.xml	2006-12-02 23:03:09 UTC (rev 34)
@@ -34,6 +34,7 @@
         <attribute name="NumberOfPostsPerPageName">numberOfPostsPerPage</attribute>
         <attribute name="ViewPostsOnSeparatePageName">viewPostsOnSeparatePage</attribute>
         <attribute name="ViewAllPostsName">viewAllPosts</attribute>
+        <attribute name="CommentsEnabledName">commentsEnabled</attribute>
     </mbean>
 
     <!-- Model service -->

Modified: trunk/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java	2006-12-02 23:03:09 UTC (rev 34)
@@ -10,6 +10,7 @@
     private String numberOfPostsPerPageName;
     private String viewPostsOnSeparatePageName;
     private String viewAllPostsName;
+    private String commentsEnabledName;
 
     /**
      * @jmx.managed-attribute
@@ -56,4 +57,18 @@
     public void setViewAllPostsName(String viewAllPostsName) {
         this.viewAllPostsName = viewAllPostsName;
     }
+
+    /**
+     * @jmx.managed-attribute
+     */
+    public String getCommentsEnabledName() {
+        return commentsEnabledName;
+    }
+
+    /**
+     * @jmx.managed-attribute
+     */
+    public void setCommentsEnabledName(String commentsEnabledName) {
+        this.commentsEnabledName = commentsEnabledName;
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java	2006-12-02 23:03:09 UTC (rev 34)
@@ -34,4 +34,12 @@
      * comments.
      */
     public Boolean getViewAllPosts(Object request);
+
+    /**
+     *
+     * @param request Request from which to read the configuration.
+     * @return True iff authorized users can add comments to posts
+     * in this blog.
+     */
+    public Boolean getCommentsEnabled(Object request);
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java	2006-12-02 23:03:09 UTC (rev 34)
@@ -44,4 +44,14 @@
         return Boolean.valueOf(BlogTools.getInitParam(
                 getViewAllPostsName()));
     }
+
+    /**
+     * @jmx.managed-operation
+     * @jmx.managed-parameter type="java.lang.Object"
+     */
+    public Boolean getCommentsEnabled(Object request) {
+        BlogTools.assertNotNull(request, REQUEST_NULL_EX_MSG);
+        return Boolean.valueOf(BlogTools.getInitParam(
+                getCommentsEnabledName()));
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java	2006-12-02 23:03:09 UTC (rev 34)
@@ -47,4 +47,15 @@
                 BlogTools.castToPortletRequest(this, request),
                 getViewAllPostsName()));
     }
+
+    /**
+     * @jmx.managed-operation
+     * @jmx.managed-parameter type="java.lang.Object"
+     */
+    public Boolean getCommentsEnabled(Object request) {
+        BlogTools.assertNotNull(request, REQUEST_NULL_EX_MSG);
+         return Boolean.valueOf(BlogTools.getPortletPreference(
+                BlogTools.castToPortletRequest(this, request),
+                getCommentsEnabledName()));
+    }
 }

Modified: trunk/blog-core/src/web/WEB-INF/portlet-instances.xml
===================================================================
--- trunk/blog-core/src/web/WEB-INF/portlet-instances.xml	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/web/WEB-INF/portlet-instances.xml	2006-12-02 23:03:09 UTC (rev 34)
@@ -21,6 +21,10 @@
                 <preference>
                     <name>viewPostsOnSeparatePage</name>
                     <value>false</value>
+                </preference>  
+                <preference>
+                    <name>commentsEnabled</name>
+                    <value>false</value>
                 </preference>
             </preferences>
         </instance>
@@ -47,6 +51,10 @@
                     <name>viewPostsOnSeparatePage</name>
                     <value>true</value>
                 </preference>
+                <preference>
+                    <name>commentsEnabled</name>
+                    <value>false</value>
+                </preference>
             </preferences>
         </instance>
     </deployment>
@@ -72,6 +80,10 @@
                     <name>viewPostsOnSeparatePage</name>
                     <value>true</value>
                 </preference>
+                <preference>
+                    <name>commentsEnabled</name>
+                    <value>true</value>
+                </preference>
             </preferences>
         </instance>
     </deployment>
@@ -97,6 +109,10 @@
                     <name>viewPostsOnSeparatePage</name>
                     <value>true</value>
                 </preference>
+                <preference>
+                    <name>commentsEnabled</name>
+                    <value>true</value>
+                </preference>
             </preferences>
         </instance>
     </deployment>

Modified: trunk/blog-core/src/web/WEB-INF/web.xml
===================================================================
--- trunk/blog-core/src/web/WEB-INF/web.xml	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/blog-core/src/web/WEB-INF/web.xml	2006-12-02 23:03:09 UTC (rev 34)
@@ -43,6 +43,10 @@
         <param-name>viewAllPosts</param-name>
         <param-value>false</param-value>
     </context-param>
+    <context-param>
+        <param-name>commentsEnabled</param-name>
+        <param-value>true</param-value>
+    </context-param>
 
     <filter>
         <filter-name>Hibernate Session Filter</filter-name>

Modified: trunk/jbossblog.iws
===================================================================
--- trunk/jbossblog.iws	2006-12-02 22:58:36 UTC (rev 33)
+++ trunk/jbossblog.iws	2006-12-02 23:03:09 UTC (rev 34)
@@ -17,34 +17,13 @@
   </component>
   <component name="ChangeListManager">
     <list default="true" name="Default" comment="">
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/web.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/web.xml" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogItem.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogItem.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogModel.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogModel.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogModel.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogComment.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java" />
-      <change type="DELETED" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/RomeParsingBlogModelService.java" afterPath="" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml" />
     </list>
   </component>
   <component name="ChangeListSynchronizer" />
@@ -196,7 +175,7 @@
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="false" current-in-tab="false">
+      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="true" current-in-tab="true">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
           <provider selected="true" editor-type-id="text-editor">
             <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
@@ -223,15 +202,6 @@
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="BlogPost.java" pinned="false" current="true" current-in-tab="true">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="22" column="51" selection-start="529" selection-end="529" vertical-scroll-proportion="0.50643086">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
       <file leaf-file-name="PostEdit.java" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
           <provider selected="true" editor-type-id="text-editor">
@@ -369,32 +339,10 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-      </PATH>
-      <PATH>
         <PATH_ELEMENT>
-          <option name="myItemId" value="jbossblog.ipr" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/web" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -414,17 +362,13 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/web" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/web/WEB-INF" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -443,22 +387,6 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -485,14 +413,6 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -523,14 +443,6 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -562,17 +474,9 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -607,14 +511,6 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -650,7 +546,7 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model" />
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
       </PATH>
@@ -672,120 +568,6 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-      </PATH>
-      <PATH>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="jbossblog.ipr" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-      </PATH>
-      <PATH>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="jbossblog.ipr" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-      </PATH>
-      <PATH>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="jbossblog.ipr" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
-          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
-          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
-        </PATH_ELEMENT>
-        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/etc" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -1022,7 +804,7 @@
   </component>
   <component name="ToolWindowManager">
     <frame x="0" y="25" width="1690" height="1004" extended-state="6" />
-    <editor active="true" />
+    <editor active="false" />
     <layout>
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="13" />
@@ -1031,7 +813,7 @@
       <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26118946" order="0" />
       <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32839224" order="1" />
       <window_info id="Structure" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24367674" order="7" />
-      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
+      <window_info id="Messages" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.39977092" order="6" />
       <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="4" />
       <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="10" />
@@ -1140,107 +922,107 @@
     <option name="myLastEditedConfigurable" value="Project Default" />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="86" column="43" selection-start="3364" selection-end="3364" vertical-scroll-proportion="0.5615942">
+        <state line="16" column="13" selection-start="520" selection-end="520" vertical-scroll-proportion="-4.822076">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="42" column="79" selection-start="2231" selection-end="2231" vertical-scroll-proportion="0.77490777">
+        <state line="12" column="13" selection-start="273" selection-end="273" vertical-scroll-proportion="0.19292605">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="13" column="46" selection-start="425" selection-end="425" vertical-scroll-proportion="0.31350482">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModelPost.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="22" column="51" selection-start="529" selection-end="529" vertical-scroll-proportion="0.4340836">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="165" column="48" selection-start="4229" selection-end="4229" vertical-scroll-proportion="0.63022506">
+        <state line="18" column="24" selection-start="588" selection-end="588" vertical-scroll-proportion="0.31350482">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="34" column="66" selection-start="1240" selection-end="1240" vertical-scroll-proportion="0.8199357">
+        <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="1.0889621">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
+        <state line="41" column="20" selection-start="1487" selection-end="1487" vertical-scroll-proportion="0.75165564">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="38" column="0" selection-start="811" selection-end="811" vertical-scroll-proportion="0.511254">
+        <state line="69" column="7" selection-start="1875" selection-end="1875" vertical-scroll-proportion="0.8013245">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="1.0889621">
+        <state line="58" column="40" selection-start="2071" selection-end="2071" vertical-scroll-proportion="1.4403974">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="18" column="24" selection-start="588" selection-end="588" vertical-scroll-proportion="0.31350482">
+        <state line="47" column="4" selection-start="1460" selection-end="1779" vertical-scroll-proportion="0.6141479">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="7" column="17" selection-start="168" selection-end="168" vertical-scroll-proportion="0.1688103">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="16" column="13" selection-start="520" selection-end="520" vertical-scroll-proportion="-4.822076">
+        <state line="36" column="61" selection-start="1990" selection-end="1990" vertical-scroll-proportion="0.51894563">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/web.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="12" column="13" selection-start="273" selection-end="273" vertical-scroll-proportion="0.19292605">
+        <state line="47" column="25" selection-start="1603" selection-end="1603" vertical-scroll-proportion="0.8440514">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="13" column="46" selection-start="425" selection-end="425" vertical-scroll-proportion="0.31350482">
+        <state line="47" column="43" selection-start="1772" selection-end="1772" vertical-scroll-proportion="1.1334405">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="22" column="51" selection-start="529" selection-end="529" vertical-scroll-proportion="0.50643086">
+        <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
           <folding />
         </state>
       </provider>



From qajkdsk at yahoo.co.jp  Fri Dec  1 23:04:23 2006
From: qajkdsk at yahoo.co.jp (=?iso-2022-jp?B?GyRCNUwhIUh+QGMbKEI=?=)
Date: Sat, 02 Dec 2006 13:04:23 +0900
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCO2QhIjxMPz8kQCRIJDMkcyRKNDYbKEI=?=
	=?iso-2022-jp?b?GyRCJDgkRyQ5JDEkSUJnPmZJVyRHJDkkKyEpGyhCKF5eOyk=?=
Message-ID: <200612022353.kB2Nrr19000823@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061202/3c5aa1ef/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Sat Dec  2 19:11:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 02 Dec 2006 19:11:13 -0500
Subject: [jboss-cvs] JBossBlog SVN: r35 - in trunk: .
	blog-core/src/java/org/jboss/blog/model
	blog-core/src/java/org/jboss/blog/service/store/hibernate
	blog-core/src/java/org/jboss/blog/ui
	blog-core/src/web/WEB-INF blog-core/src/web/views lib/hibernate
Message-ID: <E1Gqewr-0003l6-AR@committer01.frg.pub.inap.atl.jboss.com>

Author: adamw
Date: 2006-12-02 19:10:53 -0500 (Sat, 02 Dec 2006)
New Revision: 35

Modified:
   trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
   trunk/blog-core/src/web/WEB-INF/portlet.xml
   trunk/blog-core/src/web/views/post_view.xhtml
   trunk/jbossblog.iws
   trunk/lib/hibernate/hibernate3.jar
Log:
http://jira.jboss.com/jira/browse/JBBLOG-13

Modified: trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java	2006-12-03 00:10:53 UTC (rev 35)
@@ -11,8 +11,8 @@
     private boolean titleAsIdInitialized;
     private String titleAsId;
 
-    public boolean hasComments() {
-        return ((getComments() == null) || (getComments().size() == 0));
+    public boolean getHasComments() {
+        return ((getComments() != null) && (getComments().size() > 0));
     }
 
     public String getTitleAsId() {

Modified: trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogPost.java	2006-12-03 00:10:53 UTC (rev 35)
@@ -22,7 +22,7 @@
      *
      * @return True iff this post has any comments.
      */
-    public boolean hasComments();
+    public boolean getHasComments();
 
     /**
      *

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml	2006-12-03 00:10:53 UTC (rev 35)
@@ -10,7 +10,7 @@
             <generator class="native" />
         </id>
 
-        <many-to-one name="post" column="POST" not-null="true" class="HBlogPost" />
+        <many-to-one name="post" column="POST_ID" not-null="true" class="HBlogPost" />
         
         <property name="author" column="AUTHOR" not-null="true" />
 

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml	2006-12-03 00:10:53 UTC (rev 35)
@@ -32,7 +32,7 @@
             <one-to-many class="HBlogModelPost" />
         </bag>
 
-        <bag name="comments" order-by="created desc" inverse="true">
+        <bag name="comments" order-by="created desc" inverse="true" cascade="all">
             <key column="POST_ID" not-null="true" />
             <one-to-many class="HBlogComment" />
         </bag>

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-03 00:10:53 UTC (rev 35)
@@ -26,6 +26,7 @@
 
     // Faces-managed properties
     private UIData postsData;
+    private UIData commentsData;
     private State state;
 
     public UIData getPostsData() {
@@ -36,6 +37,14 @@
         this.postsData = postsData;
     }
 
+    public UIData getCommentsData() {
+        return commentsData;
+    }
+
+    public void setCommentsData(UIData commentsData) {
+        this.commentsData = commentsData;
+    }
+
     public State getState() {
         return state;
     }
@@ -51,10 +60,11 @@
     private Integer numberOfPostsPerPage;
     private Boolean viewPostsOnSeparatePage;
     private Boolean viewAllPosts;
+    private Boolean commentsEnabled;
     private Boolean postsExpandable;
     private Boolean blogModifiable;
     private Boolean defaultBlog;
-    
+
     /* A list of posts to show in the current view, plus the next post,
      * if such a post exists (used to checking if there is a next page). */
     private List postsWithNext;
@@ -112,6 +122,15 @@
         return blogModel;
     }
 
+    public Boolean getCommentsEnabled() {
+        if (commentsEnabled == null) {
+            commentsEnabled = BlogTools.getBlogService().getConfigurationService().
+                    getCommentsEnabled(getRequest());
+        }
+
+        return commentsEnabled;
+    }
+
     public Integer getNumberOfPostsPerPage() {
         if (numberOfPostsPerPage == null) {
             numberOfPostsPerPage = BlogTools.getBlogService().getConfigurationService().
@@ -280,13 +299,13 @@
     public String postEditFromBlogView() {
         postSelect();
         exitFromBlogView();
-        
+
         return UITools.POST_EDIT;
     }
 
     public String postEditFromPostView() {
         exitFromPostView();
-        
+
         return UITools.POST_EDIT;
     }
 

Modified: trunk/blog-core/src/web/WEB-INF/portlet.xml
===================================================================
--- trunk/blog-core/src/web/WEB-INF/portlet.xml	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/web/WEB-INF/portlet.xml	2006-12-03 00:10:53 UTC (rev 35)
@@ -35,6 +35,10 @@
                 <name>viewPostsOnSeparatePage</name>
                 <value>true</value>
             </preference>
+            <preference>
+                <name>commentsEnabled</name>
+                <value>false</value>
+            </preference>
         </portlet-preferences>
     </portlet>
 </portlet-app>

Modified: trunk/blog-core/src/web/views/post_view.xhtml
===================================================================
--- trunk/blog-core/src/web/views/post_view.xhtml	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/blog-core/src/web/views/post_view.xhtml	2006-12-03 00:10:53 UTC (rev 35)
@@ -35,6 +35,75 @@
             <h:outputText value="#{blogView.selectedPost.description}" escape="false" />
         </p>
 
+        <h:panelGroup rendered="#{blogView.selectedPost.hasComments}">
+        <blog:isAllowed fragment="acl://viewComment" contextData="#{blogView.blogName}">
+            <hr />
+
+            <h3>Comments</h3>
+
+            <h:dataTable value="#{blogView.selectedPost.comments}" var="comment"
+                         binding="#{blogView.commentsData}" styleClass="posts"
+                         rowClasses="posts-row,posts-row-alternate" >
+                <h:column>
+                    <span class="post-title">#{comment.title}</span>
+                    <span class="post-data">
+                        created on #{comment.createdTime}, #{comment.createdDate}
+                        by #{comment.author}.
+                    </span>
+
+                    <p class="post-description">
+                        <h:outputText value="#{comment.description}" escape="false" />
+                    </p>
+                </h:column>
+
+                <h:column>
+                    <h:panelGroup rendered="#{blogView.blogModifiable}">
+                    <blog:isAllowed fragment="acl://manageComment"
+                                    contextData="#{blogView.blogName}">
+                        <span class="admin-link">
+                            <h:commandLink value="Delete"
+                                           action="#{commentEdit.commentDelete}" />
+                        </span>
+                    </blog:isAllowed>
+                    </h:panelGroup>
+                </h:column>
+            </h:dataTable>
+        </blog:isAllowed>
+        </h:panelGroup>
+
+        <h:panelGroup rendered="#{blogView.commentsEnabled}">
+        <blog:isAllowed fragment="acl://addComment" contextData="#{blogView.blogName}">
+            <hr />
+
+            <h3>Add a comment!</h3>
+
+            <h:form>
+                <h:panelGrid columns="2" headerClass="">
+                    <h:panelGroup>Title: (*)</h:panelGroup>
+                    <h:panelGroup>
+                        <h:inputText value="#{commentEdit.title}" required="true"
+                                     maxlength="255" size="32" />
+                    </h:panelGroup>
+
+                    <h:panelGroup>Author: (*)</h:panelGroup>
+                    <h:panelGroup>
+                        <h:inputText value="#{commentEdit.author}" required="true"
+                                     maxlength="255" size="32" />
+                    </h:panelGroup>
+
+                    <h:panelGroup>Description:</h:panelGroup>
+                    <h:panelGroup>
+                        <h:inputTextarea value="#{commentEdit.description}" rows="10" cols="40" />
+                    </h:panelGroup>
+                </h:panelGrid>
+
+                <h:commandLink value="Add" action="#{commentEdit.saveNew}" />
+            </h:form>
+
+            <hr />
+        </blog:isAllowed>
+        </h:panelGroup>
+
         <h:form>
             <h:commandLink action="#{blogView.blogView}">
                 &lt;&lt; Back

Modified: trunk/jbossblog.iws
===================================================================
--- trunk/jbossblog.iws	2006-12-02 23:03:09 UTC (rev 34)
+++ trunk/jbossblog.iws	2006-12-03 00:10:53 UTC (rev 35)
@@ -17,13 +17,13 @@
   </component>
   <component name="ChangeListManager">
     <list default="true" name="Default" comment="">
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/web.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/web.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" />
     </list>
   </component>
   <component name="ChangeListSynchronizer" />
@@ -148,19 +148,22 @@
   </component>
   <component name="FileEditorManager">
     <leaf>
-      <file leaf-file-name="HBlogModel.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
+      <file leaf-file-name="post_view.xhtml" pinned="false" current="true" current-in-tab="true">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
+          <provider editor-type-id="HtmlPreview">
+            <state />
+          </provider>
           <provider selected="true" editor-type-id="text-editor">
-            <state line="165" column="48" selection-start="4229" selection-end="4229" vertical-scroll-proportion="0.63022506">
+            <state line="39" column="18" selection-start="1540" selection-end="1540" vertical-scroll-proportion="-0.25838926">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogComment.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java">
+      <file leaf-file-name="AbstractBlogPost.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="38" column="0" selection-start="811" selection-end="811" vertical-scroll-proportion="0.511254">
+            <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
               <folding />
             </state>
           </provider>
@@ -169,16 +172,16 @@
       <file leaf-file-name="HBlogPost.hbm.xml" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="34" column="66" selection-start="1240" selection-end="1240" vertical-scroll-proportion="0.8199357">
+            <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="true" current-in-tab="true">
+      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
+            <state line="14" column="15" selection-start="525" selection-end="525" vertical-scroll-proportion="0.3376206">
               <folding />
             </state>
           </provider>
@@ -187,21 +190,12 @@
       <file leaf-file-name="HibernateBlogStoreService.java" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="1.0889621">
+            <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="0.49588138">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogPost.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="18" column="24" selection-start="588" selection-end="588" vertical-scroll-proportion="0.31350482">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
       <file leaf-file-name="PostEdit.java" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
           <provider selected="true" editor-type-id="text-editor">
@@ -387,6 +381,14 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/web" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/web/views" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -405,7 +407,25 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
+      </PATH>
+      <PATH>
         <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -546,6 +566,86 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -568,6 +668,40 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/etc" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -804,7 +938,7 @@
   </component>
   <component name="ToolWindowManager">
     <frame x="0" y="25" width="1690" height="1004" extended-state="6" />
-    <editor active="false" />
+    <editor active="true" />
     <layout>
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="13" />
@@ -813,7 +947,7 @@
       <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26118946" order="0" />
       <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32839224" order="1" />
       <window_info id="Structure" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24367674" order="7" />
-      <window_info id="Messages" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
+      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.39977092" order="6" />
       <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="4" />
       <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="10" />
@@ -922,107 +1056,122 @@
     <option name="myLastEditedConfigurable" value="Project Default" />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="16" column="13" selection-start="520" selection-end="520" vertical-scroll-proportion="-4.822076">
+        <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="12" column="13" selection-start="273" selection-end="273" vertical-scroll-proportion="0.19292605">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="-1.2224109">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/view.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="13" column="46" selection-start="425" selection-end="425" vertical-scroll-proportion="0.31350482">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
     </entry>
     <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="22" column="51" selection-start="529" selection-end="529" vertical-scroll-proportion="0.4340836">
+        <state line="24" column="27" selection-start="565" selection-end="565" vertical-scroll-proportion="0.5546624">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="18" column="24" selection-start="588" selection-end="588" vertical-scroll-proportion="0.31350482">
+        <state line="12" column="61" selection-start="394" selection-end="394" vertical-scroll-proportion="0.2170418">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="1.0889621">
+        <state line="155" column="35" selection-start="3933" selection-end="3933" vertical-scroll-proportion="0.38906753">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/BlogConfigurationService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="41" column="20" selection-start="1487" selection-end="1487" vertical-scroll-proportion="0.75165564">
+        <state line="38" column="0" selection-start="1018" selection-end="1018" vertical-scroll-proportion="0.51446944">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/AbstractPreferencesBlogConfigurationService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="69" column="7" selection-start="1875" selection-end="1875" vertical-scroll-proportion="0.8013245">
+        <state line="91" column="49" selection-start="3926" selection-end="3926" vertical-scroll-proportion="-0.049423393">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/PortletPreferencesBlogConfigurationService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/blog_view.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="58" column="40" selection-start="2071" selection-end="2071" vertical-scroll-proportion="1.4403974">
+        <state line="48" column="53" selection-start="2106" selection-end="2106" vertical-scroll-proportion="0.30981067">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration/InitParamsBlogConfigurationService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/blog.css">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="47" column="4" selection-start="1460" selection-end="1779" vertical-scroll-proportion="0.6141479">
+        <state line="56" column="1" selection-start="695" selection-end="695" vertical-scroll-proportion="0.8553055">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="57" column="39" selection-start="2581" selection-end="2581" vertical-scroll-proportion="0.42114094">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_new.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="36" column="61" selection-start="1990" selection-end="1990" vertical-scroll-proportion="0.51894563">
+        <state line="18" column="79" selection-start="634" selection-end="693" vertical-scroll-proportion="0.45302013">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/web.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="47" column="25" selection-start="1603" selection-end="1603" vertical-scroll-proportion="0.8440514">
+        <state line="15" column="66" selection-start="759" selection-end="759" vertical-scroll-proportion="0.37067544">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet-instances.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="47" column="43" selection-start="1772" selection-end="1772" vertical-scroll-proportion="1.1334405">
+        <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="12" column="83" selection-start="497" selection-end="497" vertical-scroll-proportion="0.28938907">
+        <state line="39" column="18" selection-start="1540" selection-end="1540" vertical-scroll-proportion="-0.25838926">
           <folding />
         </state>
       </provider>

Modified: trunk/lib/hibernate/hibernate3.jar
===================================================================
(Binary files differ)



From gavin.king at jboss.com  Sat Dec  2 23:06:46 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:46 -0500
Subject: [jboss-cvs] jboss-seam/facelets/lib   ...
Message-ID: <E1Gqico-0007Vk-R8@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:46

  Modified:    facelets/lib   el-api.jar el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.2       +168 -135  jboss-seam/facelets/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.2       +226 -234  jboss-seam/facelets/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/META-INF  ...
Message-ID: <E1Gqicp-0007Vr-1Q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:47

  Modified:    examples/booking/resources/META-INF  persistence.xml
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.10      +3 -1      jboss-seam/examples/booking/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/META-INF/persistence.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- persistence.xml	19 Apr 2006 21:22:34 -0000	1.9
  +++ persistence.xml	3 Dec 2006 04:06:46 -0000	1.10
  @@ -1,4 +1,6 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  +        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">>
      <persistence-unit name="bookingDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/bookingDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF/lib    ...
Message-ID: <E1Gqicp-0007W2-As@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:47

  Modified:    examples/booking/resources/WEB-INF/lib    ajax4jsf.jar
                        el-api.jar el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.4       +2750 -2571jboss-seam/examples/booking/resources/WEB-INF/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  
  1.4       +168 -135  jboss-seam/examples/booking/resources/WEB-INF/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.4       +226 -234  jboss-seam/examples/booking/resources/WEB-INF/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/lib   ...
Message-ID: <E1Gqicp-0007WA-EX@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:47

  Modified:    examples/dvdstore/lib   el-api.jar el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.3       +168 -135  jboss-seam/examples/dvdstore/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.3       +226 -234  jboss-seam/examples/dvdstore/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/lib   ...
Message-ID: <E1Gqicp-0007WI-QI@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:47

  Modified:    examples/glassfish/lib   el-api.jar el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.2       +168 -135  jboss-seam/examples/glassfish/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.2       +226 -234  jboss-seam/examples/glassfish/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/lib   ...
Message-ID: <E1Gqicp-0007WQ-Tq@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:47

  Modified:    examples/hibernate2/lib   el-api.jar el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.2       +168 -135  jboss-seam/examples/hibernate2/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.2       +226 -234  jboss-seam/examples/hibernate2/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:48 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:48 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces/resources/WEB-INF/lib   ...
Message-ID: <E1Gqicq-0007Wd-2u@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:48

  Modified:    examples/icefaces/resources/WEB-INF/lib   el-api.jar
                        el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.2       +168 -135  jboss-seam/examples/icefaces/resources/WEB-INF/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.3       +495 -497  jboss-seam/examples/icefaces/resources/WEB-INF/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:48 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:48 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/issues/src/org/jboss/seam/example/issues ...
Message-ID: <E1Gqicq-0007Wn-7M@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:48

  Modified:    examples/issues/src/org/jboss/seam/example/issues  
                        IssueFinderBean.java ProjectFinderBean.java
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/examples/issues/src/org/jboss/seam/example/issues/IssueFinderBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IssueFinderBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/src/org/jboss/seam/example/issues/IssueFinderBean.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IssueFinderBean.java	15 Apr 2006 23:22:33 -0000	1.2
  +++ IssueFinderBean.java	3 Dec 2006 04:06:48 -0000	1.3
  @@ -102,7 +102,7 @@
           for (Entry <String, Object> param: parameters.entrySet()) {
               query.setParameter( param.getKey(), param.getValue() );
           }
  -        issueList = (List<Issue>) query.setMaxResults(pageSize)
  +        issueList = query.setMaxResults(pageSize)
                   .setFirstResult(pageSize*pageNumber)
                   .getResultList();
       }
  
  
  
  1.5       +1 -1      jboss-seam/examples/issues/src/org/jboss/seam/example/issues/ProjectFinderBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProjectFinderBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/src/org/jboss/seam/example/issues/ProjectFinderBean.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ProjectFinderBean.java	12 Oct 2006 02:49:35 -0000	1.4
  +++ ProjectFinderBean.java	3 Dec 2006 04:06:48 -0000	1.5
  @@ -37,7 +37,7 @@
       }
   
       private void executeQuery() {
  -       projectList = (List<Project>) entityManager.createQuery("select project from Project project order by project.name")
  +       projectList = entityManager.createQuery("select project from Project project order by project.name")
               .getResultList();
       }
           
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:48 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:48 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/lib   ...
Message-ID: <E1Gqicq-0007Wv-CD@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:48

  Modified:    examples/jpa/lib   el-api.jar el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.2       +168 -135  jboss-seam/examples/jpa/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.2       +226 -234  jboss-seam/examples/jpa/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:06:48 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:06:48 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/stories/resources/WEB-INF/lib ...
Message-ID: <E1Gqicq-0007X3-HF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:06:48

  Modified:    examples/remoting/stories/resources/WEB-INF/lib   el-api.jar
                        el-ri.jar
  Log:
  upgrade EL and Ajax4JSF 1.0.4
  
  Revision  Changes    Path
  1.2       +169 -122  jboss-seam/examples/remoting/stories/resources/WEB-INF/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.2       +496 -508  jboss-seam/examples/remoting/stories/resources/WEB-INF/lib/el-ri.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/META-INF  ...
Message-ID: <E1GqioW-0007j3-CB@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:52

  Modified:    examples/blog/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.4       +5 -1      jboss-seam/examples/blog/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/META-INF/persistence.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- persistence.xml	16 Apr 2006 04:53:19 -0000	1.3
  +++ persistence.xml	3 Dec 2006 04:18:52 -0000	1.4
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="entityManager">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/blogDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/alter.config/META-INF  ...
Message-ID: <E1GqioW-0007jA-GH@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:52

  Modified:    examples/booking/alter.config/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.5       +5 -1      jboss-seam/examples/booking/alter.config/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/alter.config/META-INF/persistence.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- persistence.xml	16 Apr 2006 04:53:19 -0000	1.4
  +++ persistence.xml	3 Dec 2006 04:18:52 -0000	1.5
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="bookingDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/bookingDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/META-INF  ...
Message-ID: <E1GqioW-0007jH-LL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:52

  Modified:    examples/booking/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.11      +4 -2      jboss-seam/examples/booking/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/META-INF/persistence.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- persistence.xml	3 Dec 2006 04:06:46 -0000	1.10
  +++ persistence.xml	3 Dec 2006 04:18:52 -0000	1.11
  @@ -1,6 +1,8 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  -        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="bookingDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/bookingDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/contactlist/resources/META-INF  ...
Message-ID: <E1GqioW-0007jO-PM@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:52

  Modified:    examples/contactlist/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.3       +5 -1      jboss-seam/examples/contactlist/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/contactlist/resources/META-INF/persistence.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- persistence.xml	28 Sep 2006 00:54:13 -0000	1.2
  +++ persistence.xml	3 Dec 2006 04:18:52 -0000	1.3
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
   	<persistence-unit name="userDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/DefaultDS</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/META-INF  ...
Message-ID: <E1GqioW-0007jV-UV@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:52

  Modified:    examples/dvdstore/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.9       +5 -1      jboss-seam/examples/dvdstore/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/persistence.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- persistence.xml	31 May 2006 21:00:18 -0000	1.8
  +++ persistence.xml	3 Dec 2006 04:18:52 -0000	1.9
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="dvdDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/dvdDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/resources/META-INF  ...
Message-ID: <E1GqioX-0007jc-2U@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/glassfish/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.2       +5 -3      jboss-seam/examples/glassfish/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/resources/META-INF/persistence.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- persistence.xml	29 Nov 2006 09:30:41 -0000	1.1
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.2
  @@ -1,6 +1,8 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  -        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="bookingDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>jdbc/__default</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/resources/toplink  ...
Message-ID: <E1GqioX-0007jj-7C@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/glassfish/resources/toplink  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.2       +5 -3      jboss-seam/examples/glassfish/resources/toplink/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/resources/toplink/persistence.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- persistence.xml	29 Nov 2006 09:30:41 -0000	1.1
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.2
  @@ -1,6 +1,8 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  -        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
       <persistence-unit name ="em">
           <provider>oracle.toplink.essentials.ejb.cmp3.EntityManagerFactoryProvider</provider>
           <!-- JNDI name of the database resource to use -->
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces/resources/META-INF  ...
Message-ID: <E1GqioX-0007jq-B2@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/icefaces/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.3       +5 -1      jboss-seam/examples/icefaces/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/resources/META-INF/persistence.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- persistence.xml	20 Nov 2006 05:41:37 -0000	1.2
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.3
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="bookingDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/icefacesDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/issues/resources/META-INF  ...
Message-ID: <E1GqioX-0007jx-FW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/issues/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.8       +5 -1      jboss-seam/examples/issues/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/resources/META-INF/persistence.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- persistence.xml	16 Apr 2006 04:53:19 -0000	1.7
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.8
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="entityManager">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/issuesDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/resources/META-INF  ...
Message-ID: <E1GqioX-0007k4-LF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/jbms/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.2       +5 -1      jboss-seam/examples/jbms/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jbms/resources/META-INF/persistence.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- persistence.xml	25 Apr 2006 05:54:54 -0000	1.1
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.2
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
   	<persistence-unit name="userDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/DefaultDS</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/resources  ...
Message-ID: <E1GqioX-0007kB-PP@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/jpa/resources  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.2       +5 -1      jboss-seam/examples/jpa/resources/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/persistence.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- persistence.xml	8 Nov 2006 09:38:58 -0000	1.1
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.2
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="bookingDatabase" transaction-type="JTA">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/DefaultDS</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/resources/glassfish  ...
Message-ID: <E1GqioX-0007kI-TW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:53

  Modified:    examples/jpa/resources/glassfish  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.3       +5 -3      jboss-seam/examples/jpa/resources/glassfish/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/glassfish/persistence.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- persistence.xml	1 Dec 2006 23:56:16 -0000	1.2
  +++ persistence.xml	3 Dec 2006 04:18:53 -0000	1.3
  @@ -1,6 +1,8 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  -        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="bookingDatabase" transaction-type="JTA">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>jdbc/__default</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages/resources/META-INF  ...
Message-ID: <E1GqioY-0007kP-1j@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:54

  Modified:    examples/messages/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.4       +5 -1      jboss-seam/examples/messages/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/resources/META-INF/persistence.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- persistence.xml	16 Apr 2006 04:53:19 -0000	1.3
  +++ persistence.xml	3 Dec 2006 04:18:54 -0000	1.4
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
   	<persistence-unit name="messageDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/DefaultDS</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/registration/resources/META-INF  ...
Message-ID: <E1GqioY-0007kW-6N@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:54

  Modified:    examples/registration/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.8       +5 -1      jboss-seam/examples/registration/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/registration/resources/META-INF/persistence.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- persistence.xml	28 Sep 2006 00:25:33 -0000	1.7
  +++ persistence.xml	3 Dec 2006 04:18:54 -0000	1.8
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
   	<persistence-unit name="userDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/DefaultDS</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/resources/META-INF
	...
Message-ID: <E1GqioY-0007kd-C1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:54

  Modified:    examples/remoting/stories/resources/META-INF 
                        persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.2       +5 -1      jboss-seam/examples/remoting/stories/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/stories/resources/META-INF/persistence.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- persistence.xml	16 Apr 2006 05:51:24 -0000	1.1
  +++ persistence.xml	3 Dec 2006 04:18:54 -0000	1.2
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="storiesDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/storiesDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF  ...
Message-ID: <E1GqioY-0007kk-FX@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:54

  Modified:    examples/seamspace/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.3       +5 -1      jboss-seam/examples/seamspace/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/persistence.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- persistence.xml	31 Oct 2006 04:55:00 -0000	1.2
  +++ persistence.xml	3 Dec 2006 04:18:54 -0000	1.3
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="seamspaceDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/seamspaceDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:18:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:18:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/resources/META-INF  ...
Message-ID: <E1GqioY-0007kr-Jh@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:18:54

  Modified:    examples/security/resources/META-INF  persistence.xml
  Log:
  schema dec in persistence.xml
  
  Revision  Changes    Path
  1.3       +5 -1      jboss-seam/examples/security/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/security/resources/META-INF/persistence.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- persistence.xml	5 Aug 2006 02:00:54 -0000	1.2
  +++ persistence.xml	3 Dec 2006 04:18:54 -0000	1.3
  @@ -1,4 +1,8 @@
  -<persistence>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
      <persistence-unit name="securityDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/securityDatasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:19:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:19:37 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1GqipF-0007l9-AZ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:19:37

  Modified:    seam-gen/resources/META-INF  persistence.xml
  Log:
  schema dec
  
  Revision  Changes    Path
  1.6       +4 -2      jboss-seam/seam-gen/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/persistence.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- persistence.xml	2 Dec 2006 02:15:43 -0000	1.5
  +++ persistence.xml	3 Dec 2006 04:19:37 -0000	1.6
  @@ -1,6 +1,8 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<persistence xmlns="http://java.sun.com/xml/ns/persistence" version="1.0"
  -        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
   	<persistence-unit name="@projectName@">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/@projectName at Datasource</jta-data-source>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:33 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/META-INF  ...
Message-ID: <E1GqjAT-00084W-P5@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:33

  Modified:    examples/blog/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.3       +6 -1      jboss-seam/examples/blog/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	17 Apr 2006 20:53:27 -0000	1.2
  +++ application.xml	3 Dec 2006 04:41:33 -0000	1.3
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Blog</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:33 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/alter.config/META-INF  ...
Message-ID: <E1GqjAT-00084d-Sz@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:33

  Modified:    examples/booking/alter.config/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.6       +6 -1      jboss-seam/examples/booking/alter.config/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/alter.config/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	17 Apr 2006 20:53:28 -0000	1.5
  +++ application.xml	3 Dec 2006 04:41:33 -0000	1.6
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Booking</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/META-INF   ...
Message-ID: <E1GqjAU-00084n-1e@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/booking/resources/META-INF   application.xml
                        ejb-jar.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.5       +6 -1      jboss-seam/examples/booking/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	17 Apr 2006 20:53:27 -0000	1.4
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.5
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Booking</display-name>
   
   	<module>
  
  
  
  1.4       +1 -0      jboss-seam/examples/booking/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ejb-jar.xml	12 Oct 2006 02:43:39 -0000	1.3
  +++ ejb-jar.xml	3 Dec 2006 04:41:34 -0000	1.4
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/contactlist/resources/META-INF  ...
Message-ID: <E1GqjAU-00084u-5o@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/contactlist/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.3       +6 -1      jboss-seam/examples/contactlist/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/contactlist/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	28 Sep 2006 00:54:13 -0000	1.2
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.3
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Contact List</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools/resources/META-INF  ...
Message-ID: <E1GqjAU-000851-9z@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/drools/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.5       +6 -1      jboss-seam/examples/drools/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	29 Nov 2006 21:49:40 -0000	1.4
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.5
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Numberguess</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/META-INF  ...
Message-ID: <E1GqjAU-000858-Dh@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/dvdstore/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.5       +7 -6      jboss-seam/examples/dvdstore/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	25 Sep 2006 20:58:08 -0000	1.4
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.5
  @@ -1,10 +1,11 @@
  -<application xmlns="http://java.sun.com/xml/ns/j2ee" version="1.4"
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
  -    xsi:schemaLocation="http://java.sun.com /xml/ns/j2ee 
  -                        http://java.sun.com/xml/ns/j2ee/application_1_4.xsd">
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
                           
       <display-name>DVD Store</display-name>
  -    <description>Seam DVD Store Example</description>
  +    
       <module>
           <ejb>jboss-seam-dvd.jar</ejb>
       </module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/resources/META-INF  ...
Message-ID: <E1GqjAU-00085F-Ha@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/glassfish/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.2       +6 -1      jboss-seam/examples/glassfish/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/resources/META-INF/application.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- application.xml	29 Nov 2006 09:30:41 -0000	1.1
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.2
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Booking</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces/resources/META-INF  ...
Message-ID: <E1GqjAU-00085M-LQ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/icefaces/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.5       +6 -1      jboss-seam/examples/icefaces/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	29 Nov 2006 19:17:05 -0000	1.4
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.5
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>ICEfaces Booking</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/issues/resources/META-INF  ...
Message-ID: <E1GqjAU-00085T-Ou@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/issues/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.4       +6 -1      jboss-seam/examples/issues/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	17 Apr 2006 20:53:28 -0000	1.3
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.4
  @@ -1,4 +1,9 @@
   <?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   <application>
   	<display-name>Seam Issue Tracker</display-name>
   
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/resources/META-INF  ...
Message-ID: <E1GqjAU-00085a-Sn@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:34

  Modified:    examples/jbms/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.2       +6 -1      jboss-seam/examples/jbms/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jbms/resources/META-INF/application.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- application.xml	25 Apr 2006 05:54:54 -0000	1.1
  +++ application.xml	3 Dec 2006 04:41:34 -0000	1.2
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam JBMS</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages/resources/META-INF  ...
Message-ID: <E1GqjAV-00085h-1P@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/messages/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.5       +6 -1      jboss-seam/examples/messages/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	17 Apr 2006 20:53:27 -0000	1.4
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.5
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Messages</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/numberguess/resources/META-INF  ...
Message-ID: <E1GqjAV-00085o-5n@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/numberguess/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.7       +6 -1      jboss-seam/examples/numberguess/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/resources/META-INF/application.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- application.xml	25 Sep 2006 20:58:08 -0000	1.6
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.7
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Numberguess</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/registration/resources/META-INF  ...
Message-ID: <E1GqjAV-00085v-9X@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/registration/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.9       +6 -1      jboss-seam/examples/registration/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/registration/resources/META-INF/application.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- application.xml	28 Sep 2006 00:25:33 -0000	1.8
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.9
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Registration</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/chatroom/resources/META-INF
	...
Message-ID: <E1GqjAV-000862-Dg@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/remoting/chatroom/resources/META-INF 
                        application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.6       +6 -1      jboss-seam/examples/remoting/chatroom/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/chatroom/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	6 Jun 2006 20:00:21 -0000	1.5
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.6
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Remoting Chat Room</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/poker/resources/META-INF ...
Message-ID: <E1GqjAV-00086G-Ll@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/remoting/poker/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.2       +6 -1      jboss-seam/examples/remoting/poker/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/poker/resources/META-INF/application.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- application.xml	11 Oct 2006 04:43:22 -0000	1.1
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.2
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Remoting Poker</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/helloworld/resources/META-INF ...
Message-ID: <E1GqjAV-000869-Hp@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/remoting/helloworld/resources/META-INF 
                        application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.5       +6 -1      jboss-seam/examples/remoting/helloworld/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/helloworld/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	1 May 2006 14:29:30 -0000	1.4
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.5
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Remoting HelloWorld</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/progressbar/resources/META-INF ...
Message-ID: <E1GqjAV-00086N-Qs@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/remoting/progressbar/resources/META-INF 
                        application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.3       +6 -1      jboss-seam/examples/remoting/progressbar/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/progressbar/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	17 Apr 2006 20:53:28 -0000	1.2
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.3
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Progress Bar</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/resources/META-INF
	...
Message-ID: <E1GqjAV-00086U-Us@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:35

  Modified:    examples/remoting/stories/resources/META-INF 
                        application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.3       +6 -1      jboss-seam/examples/remoting/stories/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/stories/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	17 Apr 2006 20:53:28 -0000	1.2
  +++ application.xml	3 Dec 2006 04:41:35 -0000	1.3
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Stories</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:36 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:36 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/resources/META-INF  ...
Message-ID: <E1GqjAW-00086b-3M@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:36

  Modified:    examples/seampay/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.3       +6 -5      jboss-seam/examples/seampay/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	23 Oct 2006 22:38:24 -0000	1.2
  +++ application.xml	3 Dec 2006 04:41:36 -0000	1.3
  @@ -1,8 +1,9 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -<application version="5" 
  -             xmlns="http://java.sun.com/xml/ns/javaee" 
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
  -             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd">
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
       <display-name>Seam Pay Example</display-name>
       
       <module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:36 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:36 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF  ...
Message-ID: <E1GqjAW-00086i-Nd@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:36

  Modified:    examples/seamspace/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.2       +6 -1      jboss-seam/examples/seamspace/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/application.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- application.xml	23 Oct 2006 12:25:21 -0000	1.1
  +++ application.xml	3 Dec 2006 04:41:36 -0000	1.2
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>SeamSpace</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:36 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:36 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/resources/META-INF  ...
Message-ID: <E1GqjAW-00086p-Sf@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:36

  Modified:    examples/security/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.2       +6 -1      jboss-seam/examples/security/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/security/resources/META-INF/application.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- application.xml	25 Jul 2006 06:56:15 -0000	1.1
  +++ application.xml	3 Dec 2006 04:41:36 -0000	1.2
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Security</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/todo/resources/META-INF  ...
Message-ID: <E1GqjAX-00086w-0t@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:37

  Modified:    examples/todo/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.7       +6 -1      jboss-seam/examples/todo/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/todo/resources/META-INF/application.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- application.xml	25 Sep 2006 20:58:08 -0000	1.6
  +++ application.xml	3 Dec 2006 04:41:36 -0000	1.7
  @@ -1,4 +1,9 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
   	<display-name>Seam Todo</display-name>
   
   	<module>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:41:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:41:37 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1GqjAX-000873-64@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:41:37

  Modified:    seam-gen/resources/META-INF  application.xml
  Log:
  schema for app.xml
  
  Revision  Changes    Path
  1.2       +8 -3      jboss-seam/seam-gen/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/application.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- application.xml	28 Oct 2006 17:56:05 -0000	1.1
  +++ application.xml	3 Dec 2006 04:41:37 -0000	1.2
  @@ -1,6 +1,10 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +    
   	<display-name>Seam Generated Application</display-name>
  -    <description>created by seam-gen</description>
   
   	<module>
   		<web>
  @@ -17,4 +21,5 @@
   	<module>
   	    <java>jbpm-3.1.2.jar</java>
   	</module>
  +    
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/contactlist/resources/META-INF  ...
Message-ID: <E1GqjDU-00087V-E4@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:40

  Modified:    examples/contactlist/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/contactlist/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/contactlist/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:40 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:40 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/META-INF  ...
Message-ID: <E1GqjDU-00087c-I0@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:40

  Modified:    examples/dvdstore/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/dvdstore/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:40 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:40 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/resources/META-INF  ...
Message-ID: <E1GqjDU-00087j-LT@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:40

  Modified:    examples/glassfish/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.2       +1 -0      jboss-seam/examples/glassfish/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ejb-jar.xml	29 Nov 2006 09:30:41 -0000	1.1
  +++ ejb-jar.xml	3 Dec 2006 04:44:40 -0000	1.2
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces/resources/META-INF  ...
Message-ID: <E1GqjDU-00087q-P0@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:40

  Modified:    examples/icefaces/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.2       +1 -0      jboss-seam/examples/icefaces/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ejb-jar.xml	20 Nov 2006 05:03:27 -0000	1.1
  +++ ejb-jar.xml	3 Dec 2006 04:44:40 -0000	1.2
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/issues/resources/META-INF  ...
Message-ID: <E1GqjDU-00087x-U2@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:40

  Modified:    examples/issues/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/issues/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:41 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:40 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/resources/META-INF  ...
Message-ID: <E1GqjDV-000884-24@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/jbms/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/jbms/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jbms/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:41 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages/resources/META-INF  ...
Message-ID: <E1GqjDV-00088B-6v@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/messages/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/messages/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:41 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/registration/resources/META-INF  ...
Message-ID: <E1GqjDV-00088I-Ax@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/registration/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/registration/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/registration/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:42 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/chatroom/resources/META-INF
	...
Message-ID: <E1GqjDV-00088P-FE@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/remoting/chatroom/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/remoting/chatroom/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/chatroom/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:42 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/helloworld/resources/META-INF ...
Message-ID: <E1GqjDV-00088W-KL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/remoting/helloworld/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/remoting/helloworld/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/helloworld/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:42 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/poker/resources/META-INF ...
Message-ID: <E1GqjDV-00088d-OE@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/remoting/poker/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/remoting/poker/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/poker/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:43 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/progressbar/resources/META-INF ...
Message-ID: <E1GqjDV-00088k-Ru@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/remoting/progressbar/resources/META-INF 
                        ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/remoting/progressbar/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/progressbar/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:43 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/resources/META-INF  ...
Message-ID: <E1GqjDV-00088r-Vu@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:41

  Modified:    examples/seampay/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +8 -0      jboss-seam/examples/seampay/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	23 Oct 2006 22:38:24 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:41 -0000	1.3
  @@ -3,10 +3,18 @@
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" 
            version="3.0">
  +
  +   <interceptors>
  +     <interceptor>
  +       <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
  +     </interceptor>
  +   </interceptors>
  +   
      <assembly-descriptor>
         <interceptor-binding>
            <ejb-name>*</ejb-name>
            <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
         </interceptor-binding>
      </assembly-descriptor>
  +
   </ejb-jar>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:42 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF  ...
Message-ID: <E1GqjDW-00088y-4M@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:42

  Modified:    examples/seamspace/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.2       +1 -0      jboss-seam/examples/seamspace/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ejb-jar.xml	23 Oct 2006 12:25:21 -0000	1.1
  +++ ejb-jar.xml	3 Dec 2006 04:44:42 -0000	1.2
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:42 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/resources/META-INF  ...
Message-ID: <E1GqjDW-000895-9F@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:42

  Modified:    examples/security/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/examples/security/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/security/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	12 Oct 2006 02:43:43 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:42 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:44:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:44:42 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1GqjDW-00089C-Cr@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:44:42

  Modified:    seam-gen/resources/META-INF  ejb-jar.xml
  Log:
  xml dec
  
  Revision  Changes    Path
  1.3       +1 -0      jboss-seam/seam-gen/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ejb-jar.xml	2 Nov 2006 00:37:02 -0000	1.2
  +++ ejb-jar.xml	3 Dec 2006 04:44:42 -0000	1.3
  @@ -1,3 +1,4 @@
  +<?xml version="1.0" encoding="UTF-8"?>
   <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" 
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
            xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd"
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:55:16 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:55:16 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources  ...
Message-ID: <E1GqjNk-0008JE-4M@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:55:16

  Modified:    seam-gen/resources  datasource-ds.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.3       +13 -14    jboss-seam/seam-gen/resources/datasource-ds.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: datasource-ds.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/datasource-ds.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- datasource-ds.xml	6 Nov 2006 22:18:20 -0000	1.2
  +++ datasource-ds.xml	3 Dec 2006 04:55:16 -0000	1.3
  @@ -1,5 +1,4 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -
   <datasources>
      
       <local-tx-datasource>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:55:16 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:55:16 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF       ...
Message-ID: <E1GqjNk-0008Ja-F2@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:55:16

  Modified:    seam-gen/resources/META-INF       application-wtp.xml
                        application.xml ejb-jar.xml jboss-app.xml
                        jboss-beans.xml persistence.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.3       +24 -19    jboss-seam/seam-gen/resources/META-INF/application-wtp.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application-wtp.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/application-wtp.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application-wtp.xml	2 Nov 2006 00:37:02 -0000	1.2
  +++ application-wtp.xml	3 Dec 2006 04:55:16 -0000	1.3
  @@ -1,6 +1,10 @@
  -<application>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +    
   	<display-name>Seam Generated Application</display-name>
  -    <description>created by seam-gen</description>
   
   	<module>
   		<web>
  @@ -17,4 +21,5 @@
   	<module>
   	    <java>jbpm-3.1.1.jar</java>
   	</module>
  +    
   </application>
  \ No newline at end of file
  
  
  
  1.3       +16 -16    jboss-seam/seam-gen/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  
  
  
  1.4       +3 -3      jboss-seam/seam-gen/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  
  
  
  1.2       +2 -2      jboss-seam/seam-gen/resources/META-INF/jboss-app.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-app.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/jboss-app.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  
  
  
  1.3       +0 -1      jboss-seam/seam-gen/resources/META-INF/jboss-beans.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-beans.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/jboss-beans.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- jboss-beans.xml	8 Nov 2006 05:32:16 -0000	1.2
  +++ jboss-beans.xml	3 Dec 2006 04:55:16 -0000	1.3
  @@ -1,5 +1,4 @@
   <?xml version="1.0" encoding="UTF-8"?>
  -
   <deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd"
               xmlns="urn:jboss:bean-deployer">
  
  
  
  1.7       +4 -2      jboss-seam/seam-gen/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/persistence.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- persistence.xml	3 Dec 2006 04:19:37 -0000	1.6
  +++ persistence.xml	3 Dec 2006 04:55:16 -0000	1.7
  @@ -3,6 +3,7 @@
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
                version="1.0">
  +             
   	<persistence-unit name="@projectName@">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/@projectName at Datasource</jta-data-source>
  @@ -13,4 +14,5 @@
            <property name="jboss.entity.manager.factory.jndi.name" value="java:/@projectName at EntityManagerFactory"/>
         </properties>
   	</persistence-unit>
  +    
   </persistence>
  
  
  


From gavin.king at jboss.com  Sat Dec  2 23:55:16 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 02 Dec 2006 23:55:16 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/WEB-INF     ...
Message-ID: <E1GqjNk-0008Jq-QP@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/02 23:55:16

  Modified:    seam-gen/resources/WEB-INF     components.xml
                        faces-config.xml navigation.xml web.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.6       +17 -17    jboss-seam/seam-gen/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/components.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  
  
  
  1.6       +16 -16    jboss-seam/seam-gen/resources/WEB-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/faces-config.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  
  
  
  1.3       +9 -9      jboss-seam/seam-gen/resources/WEB-INF/navigation.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: navigation.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/navigation.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  
  
  
  1.3       +49 -49    jboss-seam/seam-gen/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/WEB-INF/web.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  
  
  


From forge-admin at jboss.com  Sun Dec  3 01:00:26 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sun, 03 Dec 2006 01:00:26 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GqkOo-0000r7-5T@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-02 02:51 EST)
-----------------

fix JBSEAM-551

  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java                             1.68
  jboss-seam  src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java  1.14


Commit from vralev (2006-12-02 16:12 EST)
------------------

MB,KB... localization

    repository.jboss.com/izpack/3.9.0.jboss.patch2/lib/standalone-compiler.jar  1.3


Commit from gavin (2006-12-02 23:06 EST)
-----------------

upgrade EL and Ajax4JSF 1.0.4

  jboss-seam  facelets/lib/el-api.jar                                                   1.2
  jboss-seam  facelets/lib/el-ri.jar                                                    1.2
  jboss-seam  examples/booking/resources/META-INF/persistence.xml                       1.10
  jboss-seam  examples/booking/resources/WEB-INF/lib/ajax4jsf.jar                       1.4
  jboss-seam  examples/booking/resources/WEB-INF/lib/el-api.jar                         1.4
  jboss-seam  examples/booking/resources/WEB-INF/lib/el-ri.jar                          1.4
  jboss-seam  examples/dvdstore/lib/el-api.jar                                          1.3
  jboss-seam  examples/dvdstore/lib/el-ri.jar                                           1.3
  jboss-seam  examples/glassfish/lib/el-api.jar                                         1.2
  jboss-seam  examples/glassfish/lib/el-ri.jar                                          1.2
  jboss-seam  examples/hibernate2/lib/el-api.jar                                        1.2
  jboss-seam  examples/hibernate2/lib/el-ri.jar                                         1.2
  jboss-seam  examples/icefaces/resources/WEB-INF/lib/el-api.jar                        1.2
  jboss-seam  examples/icefaces/resources/WEB-INF/lib/el-ri.jar                         1.3
  jboss-seam  examples/issues/src/org/jboss/seam/example/issues/IssueFinderBean.java    1.3
  jboss-seam  examples/issues/src/org/jboss/seam/example/issues/ProjectFinderBean.java  1.5
  jboss-seam  examples/jpa/lib/el-api.jar                                               1.2
  jboss-seam  examples/jpa/lib/el-ri.jar                                                1.2
  jboss-seam  examples/remoting/stories/resources/WEB-INF/lib/el-api.jar                1.2
  jboss-seam  examples/remoting/stories/resources/WEB-INF/lib/el-ri.jar                 1.2


Commit from gavin (2006-12-02 23:18 EST)
-----------------

schema dec in persistence.xml

  jboss-seam  examples/blog/resources/META-INF/persistence.xml              1.4
  jboss-seam  examples/booking/alter.config/META-INF/persistence.xml        1.5
  jboss-seam  examples/booking/resources/META-INF/persistence.xml           1.11
  jboss-seam  examples/contactlist/resources/META-INF/persistence.xml       1.3
  jboss-seam  examples/dvdstore/resources/META-INF/persistence.xml          1.9
  jboss-seam  examples/glassfish/resources/META-INF/persistence.xml         1.2
  jboss-seam  examples/glassfish/resources/toplink/persistence.xml          1.2
  jboss-seam  examples/icefaces/resources/META-INF/persistence.xml          1.3
  jboss-seam  examples/issues/resources/META-INF/persistence.xml            1.8
  jboss-seam  examples/jbms/resources/META-INF/persistence.xml              1.2
  jboss-seam  examples/jpa/resources/persistence.xml                        1.2
  jboss-seam  examples/jpa/resources/glassfish/persistence.xml              1.3
  jboss-seam  examples/messages/resources/META-INF/persistence.xml          1.4
  jboss-seam  examples/registration/resources/META-INF/persistence.xml      1.8
  jboss-seam  examples/remoting/stories/resources/META-INF/persistence.xml  1.2
  jboss-seam  examples/seamspace/resources/META-INF/persistence.xml         1.3
  jboss-seam  examples/security/resources/META-INF/persistence.xml          1.3


Commit from gavin (2006-12-02 23:19 EST)
-----------------

schema dec

  jboss-seam  seam-gen/resources/META-INF/persistence.xml  1.6


Commit from gavin (2006-12-02 23:41 EST)
-----------------

schema for app.xml

  jboss-seam  examples/blog/resources/META-INF/application.xml                  1.3
  jboss-seam  examples/booking/alter.config/META-INF/application.xml            1.6
  jboss-seam  examples/booking/resources/META-INF/application.xml               1.5
  jboss-seam  examples/booking/resources/META-INF/ejb-jar.xml                   1.4
  jboss-seam  examples/contactlist/resources/META-INF/application.xml           1.3
  jboss-seam  examples/drools/resources/META-INF/application.xml                1.5
  jboss-seam  examples/dvdstore/resources/META-INF/application.xml              1.5
  jboss-seam  examples/glassfish/resources/META-INF/application.xml             1.2
  jboss-seam  examples/icefaces/resources/META-INF/application.xml              1.5
  jboss-seam  examples/issues/resources/META-INF/application.xml                1.4
  jboss-seam  examples/jbms/resources/META-INF/application.xml                  1.2
  jboss-seam  examples/messages/resources/META-INF/application.xml              1.5
  jboss-seam  examples/numberguess/resources/META-INF/application.xml           1.7
  jboss-seam  examples/registration/resources/META-INF/application.xml          1.9
  jboss-seam  examples/remoting/chatroom/resources/META-INF/application.xml     1.6
  jboss-seam  examples/remoting/helloworld/resources/META-INF/application.xml   1.5
  jboss-seam  examples/remoting/poker/resources/META-INF/application.xml        1.2
  jboss-seam  examples/remoting/progressbar/resources/META-INF/application.xml  1.3
  jboss-seam  examples/remoting/stories/resources/META-INF/application.xml      1.3
  jboss-seam  examples/seampay/resources/META-INF/application.xml               1.3
  jboss-seam  examples/seamspace/resources/META-INF/application.xml             1.2
  jboss-seam  examples/security/resources/META-INF/application.xml              1.2
  jboss-seam  examples/todo/resources/META-INF/application.xml                  1.7
  jboss-seam  seam-gen/resources/META-INF/application.xml                       1.2


Commit from gavin (2006-12-02 23:44 EST)
-----------------

xml dec

  jboss-seam  examples/contactlist/resources/META-INF/ejb-jar.xml           1.3
  jboss-seam  examples/dvdstore/resources/META-INF/ejb-jar.xml              1.3
  jboss-seam  examples/glassfish/resources/META-INF/ejb-jar.xml             1.2
  jboss-seam  examples/icefaces/resources/META-INF/ejb-jar.xml              1.2
  jboss-seam  examples/issues/resources/META-INF/ejb-jar.xml                1.3
  jboss-seam  examples/jbms/resources/META-INF/ejb-jar.xml                  1.3
  jboss-seam  examples/messages/resources/META-INF/ejb-jar.xml              1.3
  jboss-seam  examples/registration/resources/META-INF/ejb-jar.xml          1.3
  jboss-seam  examples/remoting/chatroom/resources/META-INF/ejb-jar.xml     1.3
  jboss-seam  examples/remoting/helloworld/resources/META-INF/ejb-jar.xml   1.3
  jboss-seam  examples/remoting/poker/resources/META-INF/ejb-jar.xml        1.3
  jboss-seam  examples/remoting/progressbar/resources/META-INF/ejb-jar.xml  1.3
  jboss-seam  examples/seampay/resources/META-INF/ejb-jar.xml               1.3
  jboss-seam  examples/seamspace/resources/META-INF/ejb-jar.xml             1.2
  jboss-seam  examples/security/resources/META-INF/ejb-jar.xml              1.3
  jboss-seam  seam-gen/resources/META-INF/ejb-jar.xml                       1.3


Commit from gavin (2006-12-02 23:55 EST)
-----------------

ws

  jboss-seam  seam-gen/resources/datasource-ds.xml             1.3
  jboss-seam  seam-gen/resources/META-INF/application-wtp.xml  1.3
  jboss-seam  seam-gen/resources/META-INF/application.xml      1.3
  jboss-seam  seam-gen/resources/META-INF/ejb-jar.xml          1.4
  jboss-seam  seam-gen/resources/META-INF/jboss-app.xml        1.2
  jboss-seam  seam-gen/resources/META-INF/jboss-beans.xml      1.3
  jboss-seam  seam-gen/resources/META-INF/persistence.xml      1.7
  jboss-seam  seam-gen/resources/WEB-INF/components.xml        1.6
  jboss-seam  seam-gen/resources/WEB-INF/faces-config.xml      1.6
  jboss-seam  seam-gen/resources/WEB-INF/navigation.xml        1.3
  jboss-seam  seam-gen/resources/WEB-INF/web.xml               1.3
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061203/6c9e2ef7/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 01:31:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 01:31:04 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1690 - in
	branches/Branch_1_0_1_SP: docs/examples/ejb3mdb
	docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb
	tests/smoke util
Message-ID: <E1GqksS-0001VO-DJ@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 01:30:58 -0500 (Sun, 03 Dec 2006)
New Revision: 1690

Modified:
   branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/do-not-distribute.properties
   branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java
   branches/Branch_1_0_1_SP/tests/smoke/build.xml
   branches/Branch_1_0_1_SP/util/do-not-distribute.properties
Log:
fixed the EJB3 example to work with 4.0.5.GA. http://jira.jboss.org/jira/browse/JBMESSAGING-665

Modified: branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/do-not-distribute.properties
===================================================================
--- branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-02 15:53:51 UTC (rev 1689)
+++ branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-03 06:30:58 UTC (rev 1690)
@@ -4,5 +4,6 @@
 #
 messaging.client.jar.path=../../../output/lib
 messaging.client.jar.name=jboss-messaging-client.jar
-jboss.configuration=messaging-smoke-test
+jboss.configuration=messaging
 jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
+jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3

Modified: branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java
===================================================================
--- branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java	2006-12-02 15:53:51 UTC (rev 1689)
+++ branches/Branch_1_0_1_SP/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java	2006-12-03 06:30:58 UTC (rev 1690)
@@ -30,7 +30,8 @@
 @MessageDriven(activationConfig =
 {
       @ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"),
-      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue")
+      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue"),
+      @ActivationConfigProperty(propertyName="DLQMaxResent", propertyValue="10")
 })
 public class EJB3MDBExample implements MessageListener
 {

Modified: branches/Branch_1_0_1_SP/tests/smoke/build.xml
===================================================================
--- branches/Branch_1_0_1_SP/tests/smoke/build.xml	2006-12-02 15:53:51 UTC (rev 1689)
+++ branches/Branch_1_0_1_SP/tests/smoke/build.xml	2006-12-03 06:30:58 UTC (rev 1690)
@@ -71,16 +71,28 @@
 
       <!-- 4.0.0, 4.0.1 NOT SUPPORTED -->
 
+      <!--
+           4.0.1sp1
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss401sp1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.2
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss402.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.3
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss403.home}"/>
          <param name="run.secure-socket.example" value="false"/>
@@ -91,6 +103,10 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.3SP1
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss403SP1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
@@ -109,6 +125,10 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.4.GA
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss404GA.home}"/>
       </antcall>
@@ -125,12 +145,20 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.5.GA
+      -->
+
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405CR1.home}"/>
+         <param name="jboss.home" value="${jboss405GA.home}"/>
       </antcall>
-
+                                                                                                <!--
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405CR1.home}"/>
+         <param name="jboss.home" value="${jboss405GA-installer.home}"/>
+      </antcall>
+                                                                                                 -->
+      <antcall target="installation-test">
+         <param name="jboss.home" value="${jboss405GA.home}"/>
          <param name="release.admin.target" value="standalone"/>
          <param name="run.mdb.example" value="false"/>
          <param name="run.stateless.example" value="false"/>
@@ -138,7 +166,7 @@
       </antcall>
 
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405CR1ejb3.home}"/>
+         <param name="jboss.home" value="${jboss405GAejb3.home}"/>
          <param name="no.java4" value="true"/>
          <param name="run.ejb3mdb.example" value="true"/>
       </antcall>

Modified: branches/Branch_1_0_1_SP/util/do-not-distribute.properties
===================================================================
--- branches/Branch_1_0_1_SP/util/do-not-distribute.properties	2006-12-02 15:53:51 UTC (rev 1689)
+++ branches/Branch_1_0_1_SP/util/do-not-distribute.properties	2006-12-03 06:30:58 UTC (rev 1690)
@@ -6,7 +6,7 @@
 #jboss.home=C:\\work/src/cvs/jboss-head/build/output/jboss-5.0.0.Alpha
 #jboss.home=C:\\work\\src\\jboss-4.0.3SP1-src\\build\\output\\jboss-4.0.3SP1
 jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
-#jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
+jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3
 messaging.config.name=messaging
 relative.artifact.location=../output/lib
 messaging.artifact.name=jboss-messaging-scoped.sar



From gavin.king at jboss.com  Sun Dec  3 02:01:48 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 02:01:48 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GqlMC-0001vR-7T@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 02:01:47

  Modified:    src/main/org/jboss/seam/contexts  Lifecycle.java
  Log:
  fix bad handling of contexts during logout
  don't redirect to the debug page when not in a JSF request
  
  Revision  Changes    Path
  1.69      +11 -8     jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -b -r1.68 -r1.69
  --- Lifecycle.java	2 Dec 2006 07:51:33 -0000	1.68
  +++ Lifecycle.java	3 Dec 2006 07:01:47 -0000	1.69
  @@ -31,7 +31,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.68 $
  + * @version $Revision: 1.69 $
    */
   public class Lifecycle
   {
  @@ -249,6 +249,8 @@
   
            if ( Seam.isSessionInvalid() )
            {
  +            clearThreadlocals();
  +            Lifecycle.setPhaseId(null);
               ContextAdaptor.getSession(externalContext).invalidate(); //huh? we create a session just to invalidate it?
               //actual session context will be destroyed from the listener
            }
  @@ -287,6 +289,7 @@
   
            if ( Seam.isSessionInvalid() )
            {
  +            clearThreadlocals();
               ContextAdaptor.getSession(session).invalidate(); //huh? we create a session just to invalidate it?
               //actual session context will be destroyed from the listener
   
  @@ -302,12 +305,12 @@
      }
   
      private static void clearThreadlocals() {
  -      Contexts.eventContext.set( null );
  -      Contexts.pageContext.set( null );
  -      Contexts.sessionContext.set( null );
  -      Contexts.conversationContext.set( null );
  -      Contexts.businessProcessContext.set( null );
  -      Contexts.applicationContext.set( null );
  +      Contexts.eventContext.set(null);
  +      Contexts.pageContext.set(null);
  +      Contexts.sessionContext.set(null);
  +      Contexts.conversationContext.set(null);
  +      Contexts.businessProcessContext.set(null);
  +      Contexts.applicationContext.set(null);
      }
   
      private static void flushAndDestroyContexts()
  
  
  


From gavin.king at jboss.com  Sun Dec  3 02:01:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 02:01:54 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GqlMI-0001vX-Ns@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 02:01:54

  Modified:    src/main/org/jboss/seam/core  Exceptions.java
  Log:
  fix bad handling of contexts during logout
  don't redirect to the debug page when not in a JSF request
  
  Revision  Changes    Path
  1.16      +5 -4      jboss-seam/src/main/org/jboss/seam/core/Exceptions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Exceptions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Exceptions.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- Exceptions.java	24 Nov 2006 23:15:17 -0000	1.15
  +++ Exceptions.java	3 Dec 2006 07:01:54 -0000	1.16
  @@ -29,7 +29,6 @@
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.contexts.Lifecycle;
  -import org.jboss.seam.interceptors.ExceptionInterceptor;
   import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Reflections;
   import org.jboss.seam.util.Resources;
  @@ -48,7 +47,7 @@
   @Name("org.jboss.seam.core.exceptions")
   public class Exceptions 
   {
  -   private static final Log log = LogFactory.getLog(ExceptionInterceptor.class);
  +   private static final Log log = LogFactory.getLog(Exceptions.class);
      
      private List<ExceptionHandler> exceptionHandlers = new ArrayList<ExceptionHandler>();
      
  @@ -244,7 +243,8 @@
         public boolean isHandler(Exception e)
         {
            return e.getClass().isAnnotationPresent(Redirect.class) && 
  -               Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE;
  +               Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
  +               Lifecycle.getPhaseId()!=null;
         }
         
         protected String getMessage(Exception e)
  @@ -383,7 +383,8 @@
   
         public boolean isHandler(Exception e)
         {
  -         return Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE;
  +         return Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
  +               Lifecycle.getPhaseId()!=null;
         }
         
         @Override
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 02:53:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 02:53:09 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1691 -
	branches/Branch_1_0_1_SP/docs
Message-ID: <E1Gqm9t-0002rL-D8@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 02:53:07 -0500 (Sun, 03 Dec 2006)
New Revision: 1691

Modified:
   branches/Branch_1_0_1_SP/docs/README.html
Log:
release notes for 1.0.1.SP2

Modified: branches/Branch_1_0_1_SP/docs/README.html
===================================================================
--- branches/Branch_1_0_1_SP/docs/README.html	2006-12-03 06:30:58 UTC (rev 1690)
+++ branches/Branch_1_0_1_SP/docs/README.html	2006-12-03 07:53:07 UTC (rev 1691)
@@ -7,9 +7,9 @@
 </head>
 <body>
 <h1><br>
-JBoss Messaging 1.0.1.GA Release Notes</h1>
+JBoss Messaging 1.0.1.SP2 Release Notes</h1>
 <br>
-October 09, 2006<br>
+December 02, 2006<br>
 <br>
 <h2>Installation</h2>
 <br>
@@ -26,403 +26,32 @@
 <br>
 <br>
 <h2>Summary of Changes</h2>
-The <a
- href="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessaging101GAChanges">changes</a>
-introduced by this release are summarized in the JBoss Messaging
-Release History, available online <a
- href="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingReleaseHistory">here</a>.<br>
 <br>
+This is a bug fix release. It fixes a major concurrency bug (<a
+ href="http://jira.jboss.org/jira/browse/JBMESSAGING-660">JBMESSAGING-660</a>),
+and also adds some DLQ handling improvements.<br>
+<br>
 <h2>Release Notes </h2>
-<big>Includes versions: 1.0.1.CR1, 1.0.1.CR2, 1.0.1.CR3, 1.0.1.CR4,
-1.0.1.CR5, 1.0.1.GA</big>
+<big></big>
 <h3> </h3>
-<br>
-<h2 style="margin-left: 40px;">Feature Request</h2>
-<ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-294">JBMESSAGING-294</a>
-] Multiple Connectors (transports) per Server instance </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-296">JBMESSAGING-296</a>
-] Oracle PersistenceManager MBean configuration </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-345">JBMESSAGING-345</a>
-] Messaging should report it version in an INFO statement at boot </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-367">JBMESSAGING-367</a>
-] Upgrade JBossSerialization to GA version </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-476">JBMESSAGING-476</a>
-] Reoccuring Consumer endpoint activation failed Error </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-528">JBMESSAGING-528</a>
-] Update user manual to include details on configuring remoting's
-serverBindAddress </li>
-</ul>
 <h2 style="margin-left: 40px;">Bug</h2>
 <ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-274">JBMESSAGING-274</a>
-] server redeployment fails under unclear circumstances </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-277">JBMESSAGING-277</a>
-] Setting remoting lease period to -1 breaks ASF </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-279">JBMESSAGING-279</a>
-] IllegalStateException on ConnectionEndpoint: Cannot find consumer <id>
-    </id></li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-290">JBMESSAGING-290</a>
-] ServiceContainer.stop does not function correctlly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-292">JBMESSAGING-292</a>
-] Remoting Lease memory leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-305">JBMESSAGING-305</a>
-] The release script includes unnecessary libraries in the scoped
-messaging sar </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-308">JBMESSAGING-308</a>
-] Transaction mem leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-323">JBMESSAGING-323</a>
-] At undeployment, JBossManagedConnectionPool is stopped after
-ServerPeer, causing org.jboss.remoting.InvalidConfigurationException </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-325">JBMESSAGING-325</a>
-] Message selectors and subscriptions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-333">JBMESSAGING-333</a>
-] ConnectionFactory deployment fails with "Exception setting attribute
-JNDIBindings / NullPointerException" on JBoss 4.0.2 and lower </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-334">JBMESSAGING-334</a>
-] The Connector fails to deploy in JBoss 4.0.1SP1 and lower due to
-obsolete org.jboss.util.propertyeditor.PropertyEditors dependency </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-335">JBMESSAGING-335</a>
-] Remoting deployment fails on JBoss 4.0.1 and lower because of
-SecurityAssociation obsolete dependency </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-336">JBMESSAGING-336</a>
-] The automated installation procedure fails for an installer-created
-JBoss 4.x instance. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-337">JBMESSAGING-337</a>
-] PersistenceManager and ChannelMapper try to create the proxy to their
-TransactionManager dependency too early. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-339">JBMESSAGING-339</a>
-] The MDB example fails with classloading problems on an
-installer-created 4.0.3SP1 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-344">JBMESSAGING-344</a>
-] MDB example dies with "java.lang.UnsupportedOperationException:
-Destination not specified" on server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-346">JBMESSAGING-346</a>
-] Spurious ConcurrentModificationException on connection failure </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-359">JBMESSAGING-359</a>
-] Using jboss-serialization 1.0.0.CR7 breaks functional testsuite </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-362">JBMESSAGING-362</a>
-] Remote stress test fails </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-363">JBMESSAGING-363</a>
-] TCK tests fail on account of wrong exception being thrown </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-364">JBMESSAGING-364</a>
-] TCK ee.mdb.xa.MDBClient tests fail </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-366">JBMESSAGING-366</a>
-] Cannot Get SSL Remoting To Work </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-368">JBMESSAGING-368</a>
-] Since 1.0.0.CR7, Serialization produces per-message DEBUG statements </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-370">JBMESSAGING-370</a>
-] Using Serialization 1.0.0.GA generates client-side
-NullPointerException </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-371">JBMESSAGING-371</a>
-] MessageListener times out on inactivity, after receiving at least one
-message </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-372">JBMESSAGING-372</a>
-] Two JMSRemotingConnections instances are created per connection. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-391">JBMESSAGING-391</a>
-] Getting SSLException with jboss-remoting head </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-392">JBMESSAGING-392</a>
-] ConcurrentModificationException in SimpleConnectionManager </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-394">JBMESSAGING-394</a>
-] JBoss Serialization 1.0.0.GA corrupts serialized data on concurrent
-access </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-396">JBMESSAGING-396</a>
-] Client not compatible with 1.0.1.CR1 server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-397">JBMESSAGING-397</a>
-] 1.0.1.CR1 client not compatible with this server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-399">JBMESSAGING-399</a>
-] Race condition in deserializing Objectmessage </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-405">JBMESSAGING-405</a>
-] Memory leak with message selector </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-410">JBMESSAGING-410</a>
-] java:/JmsXA in no-tx context does not work the same way as JBossMQ </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-411">JBMESSAGING-411</a>
-] Fails with strings &gt;= 64K </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-415">JBMESSAGING-415</a>
-] Memory leak in acknowledgment </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-416">JBMESSAGING-416</a>
-] Issue with cancellation of messages on client failure </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-417">JBMESSAGING-417</a>
-] JMS Client does not exit </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-419">JBMESSAGING-419</a>
-] Getting started installation doco is broken </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-420">JBMESSAGING-420</a>
-] Channel State not reloaded on redeploy </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-421">JBMESSAGING-421</a>
-] Destination should be added to JNDI after it is loaded </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-423">JBMESSAGING-423</a>
-] Cannot retrieve long JMS string message (TextMessage) from JMS Queue </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-424">JBMESSAGING-424</a>
-] Cannot access the first message when starting the JMS subscriber </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-426">JBMESSAGING-426</a>
-] Expired messages remain on queue </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-427">JBMESSAGING-427</a>
-] MDB compatibility test fails with an 1.0.1.CR1 server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-428">JBMESSAGING-428</a>
-] Stress tests fail </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-430">JBMESSAGING-430</a>
-] Messy close of connection consumer </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-432">JBMESSAGING-432</a>
-] One connection per unique JMS server leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-433">JBMESSAGING-433</a>
-] MessageConsumer.receive() successfully returned although the
-acknowledgement is failed </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-434">JBMESSAGING-434</a>
-] Client receive the server side exception </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-436">JBMESSAGING-436</a>
-] Messages are not cloned on resend </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-440">JBMESSAGING-440</a>
-] ConcurrentModificationException in transaction commit </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-442">JBMESSAGING-442</a>
-] JBoss Serialization issue with readResolve </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-448">JBMESSAGING-448</a>
-] Durable subscription state on unsubscribe </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-449">JBMESSAGING-449</a>
-] Persisted messages not removed on acknowledgement </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-450">JBMESSAGING-450</a>
-] Queue/Topic removeAllMessages is broken </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-451">JBMESSAGING-451</a>
-] Closing of non recoveranle channel does not remove references </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-452">JBMESSAGING-452</a>
-] On startup of server remaining non persistent messages are not
-cleaned properly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-453">JBMESSAGING-453</a>
-] QueuedExecutors not being shutdown explicitly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-477">JBMESSAGING-477</a>
-] Messages are left in the Messages table after retry message is
-printed and are retried every time the server is restarted </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-484">JBMESSAGING-484</a>
-] org.jboss.test.messaging.jms.MessageConsumerTest.testNoLocal fails
-locally and remotely </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-487">JBMESSAGING-487</a>
-] ssh smoke test fails on 4.0.4.GA </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-489">JBMESSAGING-489</a>
-] stress tests fail on dual core </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-490">JBMESSAGING-490</a>
-] Race condition on ServerConsumerEndpoint creation </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-491">JBMESSAGING-491</a>
-] Deadlock among ServerConsumerEndpoint.lock and
-RoundRobinPointToPointRouter.receiver's locks </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-492">JBMESSAGING-492</a>
-] DurableSubscriberTest, MessageConsumerTest timeout occasionally </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-493">JBMESSAGING-493</a>
-] QueuedExecutor is bounded </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-499">JBMESSAGING-499</a>
-] get-test-execution-classpath assumes windows </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-500">JBMESSAGING-500</a>
-] Intermittent race in BrowserTest::testBrowse </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-501">JBMESSAGING-501</a>
-] Race with removeAllReferences </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-503">JBMESSAGING-503</a>
-] QueueManagementTest::testMessageCount </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-506">JBMESSAGING-506</a>
-] On restart, the channel mapper throws java.sql.SQLException: Invalid
-column index </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-507">JBMESSAGING-507</a>
-] JDBCChannelMapper ignores CreateTablesOnStartup value from
-xxx-peristence-service.xml </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-508">JBMESSAGING-508</a>
-] The MessageCount property on the queue appears to climb to the
-FullSize value, then stop. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-510">JBMESSAGING-510</a>
-] JDBCChannelMapper has a createTablesOnStartup variable but no
-overide. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-520">JBMESSAGING-520</a>
-] Messages received from Receiver.receive() using an XA are never
-deleted from the database if not withing a transactional boundary. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-521">JBMESSAGING-521</a>
-] IllegalStateException: Cannot find delivery to cancel for 1000
-Message test. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-522">JBMESSAGING-522</a>
-] javax.jms.IllegalStateException: The session is closed </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-526">JBMESSAGING-526</a>
-] JMSRedelivered flag not correctly set on true in certain redelivery
-scenarios </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-531">JBMESSAGING-531</a>
-] ServerPeer destroyTopic()/destroyQueue() must not throw exception on
-non-existent destinations, but return false. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-532">JBMESSAGING-532</a>
-] jboss-messaging.jar inappropriately packs service deployment
-descriptors </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-533">JBMESSAGING-533</a>
-] Class not found when creating durable subscription from a different
-classloading domain </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-535">JBMESSAGING-535</a>
-] Possible race condition in initialization of the server-side Remoting
-callback client:
-"org.jboss.remoting.ServerInvoker$InvalidStateException: Can not
-process invocation request since is not in started state" </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-536">JBMESSAGING-536</a>
-] The CallbackServer cannot be contacted for some particular network
-interface configurations </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-538">JBMESSAGING-538</a>
-] The MessageCount property on the queue appears to climb to the
-FullSize value, then stop </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-541">JBMESSAGING-541</a>
-] If the first opened connections is closed, Remoting Lease doesn't
-work any more </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-542">JBMESSAGING-542</a>
-] Closing connection inside MessageListener's onMessage() causes
-deadlock </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-545">JBMESSAGING-545</a>
-] Transaction edge cases and memory leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-546">JBMESSAGING-546</a>
-] org.jboss.test.messaging.jms.DurableSubscriberTest times out </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-549">JBMESSAGING-549</a>
-] Remoting 2.2.0.Alpha1 breaks 2 crash tests </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-564">JBMESSAGING-564</a>
-] Session.unsubscribe() leaves an active associated consumer (durable
-subscriber) in an undefined state </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-587">JBMESSAGING-587</a>
-] Fix perf/build.xml </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-588">JBMESSAGING-588</a>
-] MSSQL configuration appears invalid </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-598">JBMESSAGING-598</a>
-] secure-socket example fails on JBoss 4.0.5.CR1 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-599">JBMESSAGING-599</a>
-]
-org.jboss.test.messaging.jms.TransactedSessionTest.testRedeliveredQueue2()
-fails </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-600">JBMESSAGING-600</a>
-]
-org.jboss.test.messaging.jms.server.destination.QueueManagementTest.testMessageCountOverFullSize()
-fails </li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-644">JBMESSAGING-644</a>]
+- Lease fails with a NPE if server is restarted and client still running</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-660">JBMESSAGING-660</a>]
+- Race Condition Between Session.close and Session.commit or
+Session.rollback</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-665">JBMESSAGING-665</a>]
+- 4.0.5.GA ejb3 smoke test fails</li>
 </ul>
-<h2 style="margin-left: 40px;">Task</h2>
-<ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-117">JBMESSAGING-117</a>
-] Document dependencies on JBoss 5.0 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-125">JBMESSAGING-125</a>
-] Review the messaging core code for thread safety </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-172">JBMESSAGING-172</a>
-] Stress tests </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-187">JBMESSAGING-187</a>
-] Certify JBoss Messaging Content on JBoss Labs </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-195">JBMESSAGING-195</a>
-] Integration test: run existing JBossAS unit tests agains the new
-stack </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-215">JBMESSAGING-215</a>
-] Factor common behavior out of JDBC support classes
-(JDBCTransactionLog, JDBCMessageStore and JDBCDurableSubscriptionStore)
-  </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-280">JBMESSAGING-280</a>
-] Allow datasource to be configurable in servicecontainer </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-282">JBMESSAGING-282</a>
-] Document how to use the functional test suite </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-295">JBMESSAGING-295</a>
-] Make serialization manager pluggable </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-303">JBMESSAGING-303</a>
-] Describe how jboss-messaging and ejb3 need to be configured to work
-together </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-304">JBMESSAGING-304</a>
-] Use TransactionManagerLocator instead of TxManager </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-311">JBMESSAGING-311</a>
-] Add destination deployment params test </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-316">JBMESSAGING-316</a>
-] Extend the smoke matrix to test all JBoss 4.X released versions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-318">JBMESSAGING-318</a>
-] Review the user guide and send it to the documentation team for
-processing </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-320">JBMESSAGING-320</a>
-] Validate Messaging with *ALL* released JBoss 4.0.X versions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-328">JBMESSAGING-328</a>
-] Optimisation - batch messages to consumers </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-338">JBMESSAGING-338</a>
-] Include all "installer" installation in the smoke test matrix </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-341">JBMESSAGING-341</a>
-] Modify the ant release task to bundle the test source code with the
-release </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-347">JBMESSAGING-347</a>
-] Use Serialization release that fixed the bug described in JBSER-59 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-350">JBMESSAGING-350</a>
-] Test and bundle the Postgres configuration example </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-356">JBMESSAGING-356</a>
-] Split jboss-service.xml into their own files </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-358">JBMESSAGING-358</a>
-] Provide a docs/example EJB3 MDB example </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-369">JBMESSAGING-369</a>
-] Add backward and forward compatibilty tests to run on release </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-376">JBMESSAGING-376</a>
-] Hand over the release to the QA team </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-389">JBMESSAGING-389</a>
-] Test with JBoss AOP 1.5.0.GA </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-393">JBMESSAGING-393</a>
-] Remove the serverless packages from CVS </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-401">JBMESSAGING-401</a>
-] Release 1.0.1 GA after waiting for a week for feedback on the latest
-CR </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-403">JBMESSAGING-403</a>
-] The Getting Started guide contains obsolete version numbers </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-418">JBMESSAGING-418</a>
-] JMS examples not handling exceptions properly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-431">JBMESSAGING-431</a>
-] Socket transports should use configurable port </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-441">JBMESSAGING-441</a>
-] Refactoring of message delivery </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-472">JBMESSAGING-472</a>
-] Test and use remoting 2.0.0.CR1 (or 2.0.0.GA if it's released in
-time) </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-481">JBMESSAGING-481</a>
-] Implement a round robin routing strategy for queues and subscriptions
-  </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-485">JBMESSAGING-485</a>
-] CTSMiscellaneousTest.testContestedQueueOnRollback temporarily
-commented out </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-502">JBMESSAGING-502</a>
-] Create a MSSQL persistence manager config </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-504">JBMESSAGING-504</a>
-] Release with a tagged JBossSerialization jar </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-529">JBMESSAGING-529</a>
-] Install TCK5 locally and fix all errors that prevent Messaging from
-passing </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-530">JBMESSAGING-530</a>
-] Make sure QA cruisecontrol tests Branch_1_0 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-534">JBMESSAGING-534</a>
-] Create a new "messaging" subdirectory in repository.jboss.com and
-start uploading messaging artifacts there </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-547">JBMESSAGING-547</a>
-] Upgrade JBossSerialization to 1.0.3.GA </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-551">JBMESSAGING-551</a>
-] Upgrade JBoss Remoting </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-559">JBMESSAGING-559</a>
-] Add a 4.0.5.CR1 EJB3 smoke test </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-590">JBMESSAGING-590</a>
-] Add JBoss 4.0.4.SP1 to the smoke test suite </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-591">JBMESSAGING-591</a>
-] MessageConsumerTest::testTimeoutReceiveOnClose can randomly fail </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-602">JBMESSAGING-602</a>
-] Clear all open user issues on the forum<br>
-  </li>
-</ul>
 <h2 style="margin-left: 40px;">Sub-task</h2>
-<ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-317">JBMESSAGING-317</a>
-] Test the client jar with all JBoss 4.X released versions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-349">JBMESSAGING-349</a>
-] Standalone Messaging based on "extracted" JBoss 4.0.3SP1 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-351">JBMESSAGING-351</a>
-] EJB3 MDB example </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-360">JBMESSAGING-360</a>
-] BytesJBossMessage fails with jboss-serialization 1.0.0.CR7 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-361">JBMESSAGING-361</a>
-] WireFormatTest.testNullResponse(), testDeactivateResponse() fragments
-invalid </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-479">JBMESSAGING-479</a>
-] Implement iteration </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-486">JBMESSAGING-486</a>
-] Re-enable user documentation generation </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-496">JBMESSAGING-496</a>
-] The remoting snapshot breaks
-ConnectionFactoryTest.testAdministrativelyConfiguredConnectors() in-vm
-and remote </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-497">JBMESSAGING-497</a>
-] The remoting snapshot breaks TopicManagementTest (timeout) </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-498">JBMESSAGING-498</a>
-] StressTest.testTopicMultipleReceivers() (InVM) fails </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-539">JBMESSAGING-539</a>
-] Rig an RI and investigate the behavior of an XASession in absence of
-a global transaction </li>
+<div style="margin-left: 40px;">
+<ul>
+  <li>[<a href="http://jira.jboss.org/jira/browse/JBMESSAGING-666">JBMESSAGING-666</a>]
+-&nbsp; Basic DLQ functionality</li>
 </ul>
+</div>
+<br>
 <h2 style="margin-left: 40px;"><br>
 </h2>
 <br>



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 02:55:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 02:55:31 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1692 - tags
Message-ID: <E1GqmCB-0002u0-NO@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 02:55:29 -0500 (Sun, 03 Dec 2006)
New Revision: 1692

Added:
   tags/JBossMessaging_1_0_1_SP2/
Log:
Tagging 1.0.1.SP2

Copied: tags/JBossMessaging_1_0_1_SP2 (from rev 1691, branches/Branch_1_0_1_SP)



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 03:36:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 03:36:24 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1693 - in branches/Branch_1_0:
	docs docs/examples/ejb3mdb
	docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin tests/smoke
	tests/src/org/jboss/test/messaging/core/paging
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/stress util
Message-ID: <E1Gqmpk-0003a4-1N@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 03:36:09 -0500 (Sun, 03 Dec 2006)
New Revision: 1693

Added:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/stress/ConcurrentCloseStressTest.java
Modified:
   branches/Branch_1_0/docs/README.html
   branches/Branch_1_0/docs/examples/ejb3mdb/do-not-distribute.properties
   branches/Branch_1_0/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java
   branches/Branch_1_0/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   branches/Branch_1_0/tests/smoke/build.xml
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/JMSTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   branches/Branch_1_0/util/do-not-distribute.properties
Log:
merging 1.0.1.SP2 changes into Branch_1_0

Modified: branches/Branch_1_0/docs/README.html
===================================================================
--- branches/Branch_1_0/docs/README.html	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/docs/README.html	2006-12-03 08:36:09 UTC (rev 1693)
@@ -7,9 +7,9 @@
 </head>
 <body>
 <h1><br>
-JBoss Messaging 1.0.1.GA Release Notes</h1>
+JBoss Messaging 1.0.1.SP2 Release Notes</h1>
 <br>
-October 09, 2006<br>
+December 02, 2006<br>
 <br>
 <h2>Installation</h2>
 <br>
@@ -26,403 +26,32 @@
 <br>
 <br>
 <h2>Summary of Changes</h2>
-The <a
- href="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessaging101GAChanges">changes</a>
-introduced by this release are summarized in the JBoss Messaging
-Release History, available online <a
- href="http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossMessagingReleaseHistory">here</a>.<br>
 <br>
+This is a bug fix release. It fixes a major concurrency bug (<a
+ href="http://jira.jboss.org/jira/browse/JBMESSAGING-660">JBMESSAGING-660</a>),
+and also adds some DLQ handling improvements.<br>
+<br>
 <h2>Release Notes </h2>
-<big>Includes versions: 1.0.1.CR1, 1.0.1.CR2, 1.0.1.CR3, 1.0.1.CR4,
-1.0.1.CR5, 1.0.1.GA</big>
+<big></big>
 <h3> </h3>
-<br>
-<h2 style="margin-left: 40px;">Feature Request</h2>
-<ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-294">JBMESSAGING-294</a>
-] Multiple Connectors (transports) per Server instance </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-296">JBMESSAGING-296</a>
-] Oracle PersistenceManager MBean configuration </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-345">JBMESSAGING-345</a>
-] Messaging should report it version in an INFO statement at boot </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-367">JBMESSAGING-367</a>
-] Upgrade JBossSerialization to GA version </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-476">JBMESSAGING-476</a>
-] Reoccuring Consumer endpoint activation failed Error </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-528">JBMESSAGING-528</a>
-] Update user manual to include details on configuring remoting's
-serverBindAddress </li>
-</ul>
 <h2 style="margin-left: 40px;">Bug</h2>
 <ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-274">JBMESSAGING-274</a>
-] server redeployment fails under unclear circumstances </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-277">JBMESSAGING-277</a>
-] Setting remoting lease period to -1 breaks ASF </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-279">JBMESSAGING-279</a>
-] IllegalStateException on ConnectionEndpoint: Cannot find consumer <id>
-    </id></li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-290">JBMESSAGING-290</a>
-] ServiceContainer.stop does not function correctlly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-292">JBMESSAGING-292</a>
-] Remoting Lease memory leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-305">JBMESSAGING-305</a>
-] The release script includes unnecessary libraries in the scoped
-messaging sar </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-308">JBMESSAGING-308</a>
-] Transaction mem leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-323">JBMESSAGING-323</a>
-] At undeployment, JBossManagedConnectionPool is stopped after
-ServerPeer, causing org.jboss.remoting.InvalidConfigurationException </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-325">JBMESSAGING-325</a>
-] Message selectors and subscriptions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-333">JBMESSAGING-333</a>
-] ConnectionFactory deployment fails with "Exception setting attribute
-JNDIBindings / NullPointerException" on JBoss 4.0.2 and lower </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-334">JBMESSAGING-334</a>
-] The Connector fails to deploy in JBoss 4.0.1SP1 and lower due to
-obsolete org.jboss.util.propertyeditor.PropertyEditors dependency </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-335">JBMESSAGING-335</a>
-] Remoting deployment fails on JBoss 4.0.1 and lower because of
-SecurityAssociation obsolete dependency </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-336">JBMESSAGING-336</a>
-] The automated installation procedure fails for an installer-created
-JBoss 4.x instance. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-337">JBMESSAGING-337</a>
-] PersistenceManager and ChannelMapper try to create the proxy to their
-TransactionManager dependency too early. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-339">JBMESSAGING-339</a>
-] The MDB example fails with classloading problems on an
-installer-created 4.0.3SP1 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-344">JBMESSAGING-344</a>
-] MDB example dies with "java.lang.UnsupportedOperationException:
-Destination not specified" on server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-346">JBMESSAGING-346</a>
-] Spurious ConcurrentModificationException on connection failure </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-359">JBMESSAGING-359</a>
-] Using jboss-serialization 1.0.0.CR7 breaks functional testsuite </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-362">JBMESSAGING-362</a>
-] Remote stress test fails </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-363">JBMESSAGING-363</a>
-] TCK tests fail on account of wrong exception being thrown </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-364">JBMESSAGING-364</a>
-] TCK ee.mdb.xa.MDBClient tests fail </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-366">JBMESSAGING-366</a>
-] Cannot Get SSL Remoting To Work </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-368">JBMESSAGING-368</a>
-] Since 1.0.0.CR7, Serialization produces per-message DEBUG statements </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-370">JBMESSAGING-370</a>
-] Using Serialization 1.0.0.GA generates client-side
-NullPointerException </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-371">JBMESSAGING-371</a>
-] MessageListener times out on inactivity, after receiving at least one
-message </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-372">JBMESSAGING-372</a>
-] Two JMSRemotingConnections instances are created per connection. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-391">JBMESSAGING-391</a>
-] Getting SSLException with jboss-remoting head </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-392">JBMESSAGING-392</a>
-] ConcurrentModificationException in SimpleConnectionManager </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-394">JBMESSAGING-394</a>
-] JBoss Serialization 1.0.0.GA corrupts serialized data on concurrent
-access </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-396">JBMESSAGING-396</a>
-] Client not compatible with 1.0.1.CR1 server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-397">JBMESSAGING-397</a>
-] 1.0.1.CR1 client not compatible with this server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-399">JBMESSAGING-399</a>
-] Race condition in deserializing Objectmessage </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-405">JBMESSAGING-405</a>
-] Memory leak with message selector </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-410">JBMESSAGING-410</a>
-] java:/JmsXA in no-tx context does not work the same way as JBossMQ </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-411">JBMESSAGING-411</a>
-] Fails with strings &gt;= 64K </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-415">JBMESSAGING-415</a>
-] Memory leak in acknowledgment </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-416">JBMESSAGING-416</a>
-] Issue with cancellation of messages on client failure </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-417">JBMESSAGING-417</a>
-] JMS Client does not exit </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-419">JBMESSAGING-419</a>
-] Getting started installation doco is broken </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-420">JBMESSAGING-420</a>
-] Channel State not reloaded on redeploy </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-421">JBMESSAGING-421</a>
-] Destination should be added to JNDI after it is loaded </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-423">JBMESSAGING-423</a>
-] Cannot retrieve long JMS string message (TextMessage) from JMS Queue </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-424">JBMESSAGING-424</a>
-] Cannot access the first message when starting the JMS subscriber </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-426">JBMESSAGING-426</a>
-] Expired messages remain on queue </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-427">JBMESSAGING-427</a>
-] MDB compatibility test fails with an 1.0.1.CR1 server </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-428">JBMESSAGING-428</a>
-] Stress tests fail </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-430">JBMESSAGING-430</a>
-] Messy close of connection consumer </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-432">JBMESSAGING-432</a>
-] One connection per unique JMS server leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-433">JBMESSAGING-433</a>
-] MessageConsumer.receive() successfully returned although the
-acknowledgement is failed </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-434">JBMESSAGING-434</a>
-] Client receive the server side exception </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-436">JBMESSAGING-436</a>
-] Messages are not cloned on resend </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-440">JBMESSAGING-440</a>
-] ConcurrentModificationException in transaction commit </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-442">JBMESSAGING-442</a>
-] JBoss Serialization issue with readResolve </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-448">JBMESSAGING-448</a>
-] Durable subscription state on unsubscribe </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-449">JBMESSAGING-449</a>
-] Persisted messages not removed on acknowledgement </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-450">JBMESSAGING-450</a>
-] Queue/Topic removeAllMessages is broken </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-451">JBMESSAGING-451</a>
-] Closing of non recoveranle channel does not remove references </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-452">JBMESSAGING-452</a>
-] On startup of server remaining non persistent messages are not
-cleaned properly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-453">JBMESSAGING-453</a>
-] QueuedExecutors not being shutdown explicitly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-477">JBMESSAGING-477</a>
-] Messages are left in the Messages table after retry message is
-printed and are retried every time the server is restarted </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-484">JBMESSAGING-484</a>
-] org.jboss.test.messaging.jms.MessageConsumerTest.testNoLocal fails
-locally and remotely </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-487">JBMESSAGING-487</a>
-] ssh smoke test fails on 4.0.4.GA </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-489">JBMESSAGING-489</a>
-] stress tests fail on dual core </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-490">JBMESSAGING-490</a>
-] Race condition on ServerConsumerEndpoint creation </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-491">JBMESSAGING-491</a>
-] Deadlock among ServerConsumerEndpoint.lock and
-RoundRobinPointToPointRouter.receiver's locks </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-492">JBMESSAGING-492</a>
-] DurableSubscriberTest, MessageConsumerTest timeout occasionally </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-493">JBMESSAGING-493</a>
-] QueuedExecutor is bounded </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-499">JBMESSAGING-499</a>
-] get-test-execution-classpath assumes windows </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-500">JBMESSAGING-500</a>
-] Intermittent race in BrowserTest::testBrowse </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-501">JBMESSAGING-501</a>
-] Race with removeAllReferences </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-503">JBMESSAGING-503</a>
-] QueueManagementTest::testMessageCount </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-506">JBMESSAGING-506</a>
-] On restart, the channel mapper throws java.sql.SQLException: Invalid
-column index </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-507">JBMESSAGING-507</a>
-] JDBCChannelMapper ignores CreateTablesOnStartup value from
-xxx-peristence-service.xml </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-508">JBMESSAGING-508</a>
-] The MessageCount property on the queue appears to climb to the
-FullSize value, then stop. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-510">JBMESSAGING-510</a>
-] JDBCChannelMapper has a createTablesOnStartup variable but no
-overide. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-520">JBMESSAGING-520</a>
-] Messages received from Receiver.receive() using an XA are never
-deleted from the database if not withing a transactional boundary. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-521">JBMESSAGING-521</a>
-] IllegalStateException: Cannot find delivery to cancel for 1000
-Message test. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-522">JBMESSAGING-522</a>
-] javax.jms.IllegalStateException: The session is closed </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-526">JBMESSAGING-526</a>
-] JMSRedelivered flag not correctly set on true in certain redelivery
-scenarios </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-531">JBMESSAGING-531</a>
-] ServerPeer destroyTopic()/destroyQueue() must not throw exception on
-non-existent destinations, but return false. </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-532">JBMESSAGING-532</a>
-] jboss-messaging.jar inappropriately packs service deployment
-descriptors </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-533">JBMESSAGING-533</a>
-] Class not found when creating durable subscription from a different
-classloading domain </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-535">JBMESSAGING-535</a>
-] Possible race condition in initialization of the server-side Remoting
-callback client:
-"org.jboss.remoting.ServerInvoker$InvalidStateException: Can not
-process invocation request since is not in started state" </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-536">JBMESSAGING-536</a>
-] The CallbackServer cannot be contacted for some particular network
-interface configurations </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-538">JBMESSAGING-538</a>
-] The MessageCount property on the queue appears to climb to the
-FullSize value, then stop </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-541">JBMESSAGING-541</a>
-] If the first opened connections is closed, Remoting Lease doesn't
-work any more </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-542">JBMESSAGING-542</a>
-] Closing connection inside MessageListener's onMessage() causes
-deadlock </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-545">JBMESSAGING-545</a>
-] Transaction edge cases and memory leak </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-546">JBMESSAGING-546</a>
-] org.jboss.test.messaging.jms.DurableSubscriberTest times out </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-549">JBMESSAGING-549</a>
-] Remoting 2.2.0.Alpha1 breaks 2 crash tests </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-564">JBMESSAGING-564</a>
-] Session.unsubscribe() leaves an active associated consumer (durable
-subscriber) in an undefined state </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-587">JBMESSAGING-587</a>
-] Fix perf/build.xml </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-588">JBMESSAGING-588</a>
-] MSSQL configuration appears invalid </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-598">JBMESSAGING-598</a>
-] secure-socket example fails on JBoss 4.0.5.CR1 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-599">JBMESSAGING-599</a>
-]
-org.jboss.test.messaging.jms.TransactedSessionTest.testRedeliveredQueue2()
-fails </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-600">JBMESSAGING-600</a>
-]
-org.jboss.test.messaging.jms.server.destination.QueueManagementTest.testMessageCountOverFullSize()
-fails </li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-644">JBMESSAGING-644</a>]
+- Lease fails with a NPE if server is restarted and client still running</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-660">JBMESSAGING-660</a>]
+- Race Condition Between Session.close and Session.commit or
+Session.rollback</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-665">JBMESSAGING-665</a>]
+- 4.0.5.GA ejb3 smoke test fails</li>
 </ul>
-<h2 style="margin-left: 40px;">Task</h2>
-<ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-117">JBMESSAGING-117</a>
-] Document dependencies on JBoss 5.0 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-125">JBMESSAGING-125</a>
-] Review the messaging core code for thread safety </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-172">JBMESSAGING-172</a>
-] Stress tests </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-187">JBMESSAGING-187</a>
-] Certify JBoss Messaging Content on JBoss Labs </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-195">JBMESSAGING-195</a>
-] Integration test: run existing JBossAS unit tests agains the new
-stack </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-215">JBMESSAGING-215</a>
-] Factor common behavior out of JDBC support classes
-(JDBCTransactionLog, JDBCMessageStore and JDBCDurableSubscriptionStore)
-  </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-280">JBMESSAGING-280</a>
-] Allow datasource to be configurable in servicecontainer </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-282">JBMESSAGING-282</a>
-] Document how to use the functional test suite </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-295">JBMESSAGING-295</a>
-] Make serialization manager pluggable </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-303">JBMESSAGING-303</a>
-] Describe how jboss-messaging and ejb3 need to be configured to work
-together </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-304">JBMESSAGING-304</a>
-] Use TransactionManagerLocator instead of TxManager </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-311">JBMESSAGING-311</a>
-] Add destination deployment params test </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-316">JBMESSAGING-316</a>
-] Extend the smoke matrix to test all JBoss 4.X released versions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-318">JBMESSAGING-318</a>
-] Review the user guide and send it to the documentation team for
-processing </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-320">JBMESSAGING-320</a>
-] Validate Messaging with *ALL* released JBoss 4.0.X versions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-328">JBMESSAGING-328</a>
-] Optimisation - batch messages to consumers </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-338">JBMESSAGING-338</a>
-] Include all "installer" installation in the smoke test matrix </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-341">JBMESSAGING-341</a>
-] Modify the ant release task to bundle the test source code with the
-release </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-347">JBMESSAGING-347</a>
-] Use Serialization release that fixed the bug described in JBSER-59 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-350">JBMESSAGING-350</a>
-] Test and bundle the Postgres configuration example </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-356">JBMESSAGING-356</a>
-] Split jboss-service.xml into their own files </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-358">JBMESSAGING-358</a>
-] Provide a docs/example EJB3 MDB example </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-369">JBMESSAGING-369</a>
-] Add backward and forward compatibilty tests to run on release </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-376">JBMESSAGING-376</a>
-] Hand over the release to the QA team </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-389">JBMESSAGING-389</a>
-] Test with JBoss AOP 1.5.0.GA </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-393">JBMESSAGING-393</a>
-] Remove the serverless packages from CVS </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-401">JBMESSAGING-401</a>
-] Release 1.0.1 GA after waiting for a week for feedback on the latest
-CR </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-403">JBMESSAGING-403</a>
-] The Getting Started guide contains obsolete version numbers </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-418">JBMESSAGING-418</a>
-] JMS examples not handling exceptions properly </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-431">JBMESSAGING-431</a>
-] Socket transports should use configurable port </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-441">JBMESSAGING-441</a>
-] Refactoring of message delivery </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-472">JBMESSAGING-472</a>
-] Test and use remoting 2.0.0.CR1 (or 2.0.0.GA if it's released in
-time) </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-481">JBMESSAGING-481</a>
-] Implement a round robin routing strategy for queues and subscriptions
-  </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-485">JBMESSAGING-485</a>
-] CTSMiscellaneousTest.testContestedQueueOnRollback temporarily
-commented out </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-502">JBMESSAGING-502</a>
-] Create a MSSQL persistence manager config </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-504">JBMESSAGING-504</a>
-] Release with a tagged JBossSerialization jar </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-529">JBMESSAGING-529</a>
-] Install TCK5 locally and fix all errors that prevent Messaging from
-passing </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-530">JBMESSAGING-530</a>
-] Make sure QA cruisecontrol tests Branch_1_0 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-534">JBMESSAGING-534</a>
-] Create a new "messaging" subdirectory in repository.jboss.com and
-start uploading messaging artifacts there </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-547">JBMESSAGING-547</a>
-] Upgrade JBossSerialization to 1.0.3.GA </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-551">JBMESSAGING-551</a>
-] Upgrade JBoss Remoting </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-559">JBMESSAGING-559</a>
-] Add a 4.0.5.CR1 EJB3 smoke test </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-590">JBMESSAGING-590</a>
-] Add JBoss 4.0.4.SP1 to the smoke test suite </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-591">JBMESSAGING-591</a>
-] MessageConsumerTest::testTimeoutReceiveOnClose can randomly fail </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-602">JBMESSAGING-602</a>
-] Clear all open user issues on the forum<br>
-  </li>
-</ul>
 <h2 style="margin-left: 40px;">Sub-task</h2>
-<ul style="margin-left: 40px;">
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-317">JBMESSAGING-317</a>
-] Test the client jar with all JBoss 4.X released versions </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-349">JBMESSAGING-349</a>
-] Standalone Messaging based on "extracted" JBoss 4.0.3SP1 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-351">JBMESSAGING-351</a>
-] EJB3 MDB example </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-360">JBMESSAGING-360</a>
-] BytesJBossMessage fails with jboss-serialization 1.0.0.CR7 </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-361">JBMESSAGING-361</a>
-] WireFormatTest.testNullResponse(), testDeactivateResponse() fragments
-invalid </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-479">JBMESSAGING-479</a>
-] Implement iteration </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-486">JBMESSAGING-486</a>
-] Re-enable user documentation generation </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-496">JBMESSAGING-496</a>
-] The remoting snapshot breaks
-ConnectionFactoryTest.testAdministrativelyConfiguredConnectors() in-vm
-and remote </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-497">JBMESSAGING-497</a>
-] The remoting snapshot breaks TopicManagementTest (timeout) </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-498">JBMESSAGING-498</a>
-] StressTest.testTopicMultipleReceivers() (InVM) fails </li>
-  <li> [ <a href="http://jira.jboss.com/jira/browse/JBMESSAGING-539">JBMESSAGING-539</a>
-] Rig an RI and investigate the behavior of an XASession in absence of
-a global transaction </li>
+<div style="margin-left: 40px;">
+<ul>
+  <li>[<a href="http://jira.jboss.org/jira/browse/JBMESSAGING-666">JBMESSAGING-666</a>]
+-&nbsp; Basic DLQ functionality</li>
 </ul>
+</div>
+<br>
 <h2 style="margin-left: 40px;"><br>
 </h2>
 <br>

Modified: branches/Branch_1_0/docs/examples/ejb3mdb/do-not-distribute.properties
===================================================================
--- branches/Branch_1_0/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-03 08:36:09 UTC (rev 1693)
@@ -4,5 +4,6 @@
 #
 messaging.client.jar.path=../../../output/lib
 messaging.client.jar.name=jboss-messaging-client.jar
-jboss.configuration=messaging-smoke-test
+jboss.configuration=messaging
 jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
+jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3

Modified: branches/Branch_1_0/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java
===================================================================
--- branches/Branch_1_0/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -30,7 +30,8 @@
 @MessageDriven(activationConfig =
 {
       @ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"),
-      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue")
+      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue"),
+      @ActivationConfigProperty(propertyName="DLQMaxResent", propertyValue="10")
 })
 public class EJB3MDBExample implements MessageListener
 {

Modified: branches/Branch_1_0/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -217,8 +217,21 @@
     */
    public HandleMessageResponse handleMessage(List msgs) throws HandleCallbackException
    {            
-      if (trace) { log.trace(this + " receiving " + msgs.size() + " message(s) from the remoting layer"); }
-                      
+      if (trace)
+      {
+         StringBuffer sb = new StringBuffer(this + " receiving [");
+         for(int i = 0; i < msgs.size(); i++)
+         {
+            sb.append(((MessageProxy)msgs.get(i)).getMessage().getMessageID());
+            if (i < msgs.size() - 1)
+            {
+               sb.append(",");
+            }
+         }
+         sb.append("] from the remoting layer");
+         log.trace(sb.toString());
+      }
+
       synchronized (mainLock)
       {
          if (closed)
@@ -233,7 +246,7 @@
                    
          buffer.addAll(msgs);                  
          
-         if (trace) { log.trace(this + " added messages to the buffer"); }            
+         if (trace) { log.trace(this + " added message(s) to the buffer"); }
          
          boolean full = buffer.size() >= bufferSize;         
          
@@ -341,9 +354,9 @@
       {
          sessionExecutor.execute(new Closer(result));
 
-         if (trace) { log.trace("blocking wait for Closer execution"); }
+         if (trace) { log.trace(this + " blocking wait for Closer execution"); }
          result.getResult();
-         if (trace) { log.trace("got Closer result"); }
+         if (trace) { log.trace(this + " got Closer result"); }
       }
       catch (InterruptedException e)
       {
@@ -426,7 +439,7 @@
                   }
                }
                               
-               if (trace) { log.trace("received " + m + " after being blocked on buffer"); }
+               if (trace) { log.trace(this + " received " + m + " after being blocked on buffer"); }
                        
                // If message is expired we still call pre and post deliver. This makes sure the
                // message is acknowledged so it gets removed from the queue/subscription.
@@ -436,14 +449,14 @@
                
                if (!m.getMessage().isExpired())
                {
-                  if (trace) { log.trace("message " + m + " is not expired, pushing it to the caller"); }
+                  if (trace) { log.trace(this + ": message " + m + " is not expired, pushing it to the caller"); }
                   
                   break;
                }
                
                if (trace)
                {
-                  log.trace("message expired, discarding");
+                  log.trace(this + ": message expired, discarding");
                }
                
                // the message expired, so discard the message, adjust timeout and reenter the buffer

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -753,7 +753,7 @@
          if (trace) { log.trace("sent " + m); }
       }
       
-      if (trace) { log.trace("done the sends"); }
+      if (trace) { log.trace(tx + ": done the sends"); }
       
       // Then ack the acks
       
@@ -775,7 +775,7 @@
          if (trace) { log.trace("acked " + ack.getMessageID()); }
       }
       
-      if (trace) { log.trace("done the acks"); }
+      if (trace) { log.trace(tx + ": done the acks"); }
    }   
 
    // Inner classes -------------------------------------------------

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -21,17 +21,16 @@
  */
 package org.jboss.jms.server.endpoint;
 
-
+import EDU.oswego.cs.dl.util.concurrent.Executor;
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
-
 import javax.jms.IllegalStateException;
 import javax.jms.InvalidSelectorException;
 import javax.jms.JMSException;
-
 import org.jboss.jms.client.remoting.HandleMessageResponse;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.JBossMessage;
@@ -59,9 +58,6 @@
 import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.util.Future;
 
-import EDU.oswego.cs.dl.util.concurrent.Executor;
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
  * Concrete implementation of ConsumerEndpoint. Lives on the boundary between Messaging Core and the
  * JMS Facade.
@@ -533,22 +529,27 @@
    {         
       if (trace) log.trace("attempting to remove receiver " + this + " from destination " + channel);
       
-      boolean wereDeliveries = false;
-      for(Iterator i = deliveries.values().iterator(); i.hasNext(); )
-      {
-         SingleReceiverDelivery d = (SingleReceiverDelivery)i.next();
-
-         d.cancel();
-         wereDeliveries = true;
-      }
-      deliveries.clear();           
+      boolean wereDeliveries = false;       
       
-      if (!disconnected)
-      {
-         if (!closed)
+      synchronized (lock)
+      {          
+         for (Iterator i = deliveries.values().iterator(); i.hasNext(); )
          {
-            close();
+            SingleReceiverDelivery d = (SingleReceiverDelivery)i.next();
+   
+            d.cancel();
+            wereDeliveries = true;
          }
+               
+         deliveries.clear();           
+         
+         if (!disconnected)
+         {
+            if (!closed)
+            {
+               close();
+            }
+         }
       }
       
       sessionEndpoint.getConnectionEndpoint().
@@ -603,8 +604,13 @@
    
    protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
    {
-      SingleReceiverDelivery del = (SingleReceiverDelivery)deliveries.remove(messageID);
+      SingleReceiverDelivery del = null;
       
+      synchronized (lock)
+      {         
+         del = (SingleReceiverDelivery)deliveries.remove(messageID);
+      }
+      
       if (del != null)
       {                               
          //Cancel back to the queue
@@ -659,10 +665,10 @@
          {
             return;
          }
+      }
          
-         started = false;
-      }
-      
+      started = false;      
+   
       //Now we know no more messages will be accepted in the SCE
             
       try
@@ -691,22 +697,19 @@
             
       if (!toDeliver.isEmpty())
       { 
-         synchronized (lock)
+         for (int i = toDeliver.size() - 1; i >= 0; i--)
          {
-            for (int i = toDeliver.size() - 1; i >= 0; i--)
-            {
-               MessageProxy proxy = (MessageProxy)toDeliver.get(i);
-               
-               long id = proxy.getMessage().getMessageID();
-               
-               cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
-            }
+            MessageProxy proxy = (MessageProxy)toDeliver.get(i);
+            
+            long id = proxy.getMessage().getMessageID();
+            
+            cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
          }
-                 
+             
          toDeliver.clear();
          
          bufferFull = false;
-      }      
+      }            
    }
       
    // Private -------------------------------------------------------
@@ -772,8 +775,21 @@
 
          try
          {
-            if (trace) { log.trace(ServerConsumerEndpoint.this + " handing " + list.size() + " message(s) over to the remoting layer"); }
-
+            if (trace)
+            {
+               StringBuffer sb = new StringBuffer(ServerConsumerEndpoint.this + " handing [");
+               for(int i = 0; i < list.size(); i++)
+               {
+                  sb.append(((MessageProxy)list.get(i)).getMessage().getMessageID());
+                  if (i < list.size() - 1)
+                  {
+                     sb.append(",");
+                  }
+               }
+               sb.append("] over to the remoting layer");
+               log.trace(sb.toString());
+            }
+            
             ClientDelivery del = new ClientDelivery(list, id);
 
             // TODO How can we ensure that messages for the same consumer aren't delivered
@@ -866,15 +882,17 @@
       
       public synchronized void afterCommit(boolean onePhase) throws TransactionException
       {
-         // Remove the deliveries from the delivery map.
-         Iterator iter = delList.iterator();
-         while (iter.hasNext())
+         synchronized (lock)
          {
-            Long messageID = (Long)iter.next();
-            
-            if (deliveries.remove(messageID) == null)
+            // Remove the deliveries from the delivery map.
+            Iterator iter = delList.iterator();
+            while (iter.hasNext())
             {
-               throw new TransactionException("Failed to remove delivery " + messageID);
+               Long messageID = (Long)iter.next();
+               
+               //The message might have been removed already if the consumer was closed for instance
+               //This is ok
+               deliveries.remove(messageID);               
             }
          }
       }

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -384,7 +384,7 @@
       }
    }
 
-   public void close() throws JMSException
+   public synchronized void close() throws JMSException
    {
       try
       {
@@ -438,10 +438,15 @@
       }
    }
    
-   public void acknowledgeBatch(List ackInfos) throws JMSException
+   public synchronized void acknowledgeBatch(List ackInfos) throws JMSException
    {      
       try
       {
+         if (closed)
+         {
+            throw new javax.jms.IllegalStateException("Cannot acknowledge batch since session is closed");
+         }
+                  
          Iterator iter = ackInfos.iterator();
          
          while (iter.hasNext())
@@ -457,10 +462,15 @@
       }
    }
    
-   public void acknowledge(AckInfo ackInfo) throws JMSException
+   public synchronized void acknowledge(AckInfo ackInfo) throws JMSException
    {
       try
       {
+         if (closed)
+         {
+            throw new javax.jms.IllegalStateException("Cannot acknowledge " + ackInfo + " since session is closed");
+         }
+         
          acknowledgeInternal(ackInfo);      
       }
       catch (Throwable t)
@@ -469,10 +479,19 @@
       }
    }      
         
-   public void cancelDeliveries(List ackInfos) throws JMSException
+   public synchronized void cancelDeliveries(List ackInfos) throws JMSException
    {
       try
       {
+         if (closed)
+         {
+            //We can safely ignore any cancels since closing the session will have cancelled anything
+            //remaining
+            log.warn("Call to cancelDeliveries came in after session was closed");
+            
+            return;
+         }
+         
          // deliveries must be cancelled in reverse order
           
          Set consumers = new HashSet();
@@ -721,11 +740,12 @@
    
    protected void acknowledgeInternal(AckInfo ackInfo) throws Throwable
    {
-      //If the message was delivered via a connection consumer then the message needs to be acked
-      //via the original consumer that was used to feed the connection consumer - which
-      //won't be one of the consumers of this session
-      //Therefore we always look in the global map of consumers held in the server peer
-      ServerConsumerEndpoint consumer = this.connectionEndpoint.getConsumerEndpoint(ackInfo.getConsumerID());
+      // If the message was delivered via a connection consumer then the message needs to be acked
+      // via the original consumer that was used to feed the connection consumer - which won't be
+      // one of the consumers of this session. Therefore we always look in the global map of
+      // consumers held in the server peer.
+      ServerConsumerEndpoint consumer =
+         connectionEndpoint.getConsumerEndpoint(ackInfo.getConsumerID());
 
       if (consumer == null)
       {

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -21,6 +21,8 @@
  */
 package org.jboss.messaging.core;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+import EDU.oswego.cs.dl.util.concurrent.SynchronizedLong;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.HashSet;
@@ -30,7 +32,6 @@
 import java.util.ListIterator;
 import java.util.Map;
 import java.util.Set;
-
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.memory.MemoryManager;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
@@ -42,9 +43,6 @@
 import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.util.Future;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-import EDU.oswego.cs.dl.util.concurrent.SynchronizedLong;
-
 /**
  * Channel implementation. It supports atomicity, isolation and recoverability of reliable messages.
  * The channel implementation here uses a "SEDA-type" approach, where requests to handle messages,
@@ -52,11 +50,12 @@
  * queue and executed serially by a single thread. This prevents lock contention since requests are
  * executed serially, resulting in better scalability and higher throughput at the expense of some
  * latency.
- * 
+ *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt> $Id: ChannelSupport.java,v 1.65
- *          2006/06/27 19:44:39 timfox Exp $
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
  */
 public abstract class ChannelSupport implements Channel
 {
@@ -203,11 +202,11 @@
    public Delivery handle(DeliveryObserver sender, Routable r, Transaction tx)
    {
       checkClosed();
-      
+
       Future result = new Future();
 
       if (tx == null)
-      {         
+      {
          try
          {
             // Instead of executing directly, we add the handle request to the event queue.
@@ -220,7 +219,7 @@
          {
             log.warn("Thread interrupted", e);
          }
-   
+
          return (Delivery)result.getResult();
       }
       else
@@ -228,7 +227,7 @@
          return this.handleInternal(sender, r, tx);
       }
    }
-      
+
    // DeliveryObserver implementation --------------------------
 
    public void acknowledge(Delivery d, Transaction tx) throws Throwable
@@ -252,7 +251,7 @@
          // Future result = new Future();
          //
          // this.executor.execute(new AcknowledgeRunnable(d, result));
-         //               
+         //
          // //For now we wait for result, but this may not be necessary
          // result.getResult();
          // }
@@ -280,29 +279,8 @@
 
    public void cancel(Delivery d) throws Throwable
    {
-      // We put the cancellation on the event queue
-      // try
-      // {
-      // Future result = new Future();
-      //         
-      // this.executor.execute(new CancelRunnable(d, result));
-      //         
-      // //For now we wait for result, but this may not be necessary
-      // result.getResult();
-      // }
-      // catch (InterruptedException e)
-      // {
-      // log.warn("Thread interrupted", e);
-      // }
-
-//      Exception e = new Exception();
-//      
-//      log.error("cancelling delivery: " + d, e);
-//      
-      
-      
-      // TODO We should also consider executing cancels on the event queue
-      cancelInternal(d);   
+       //We put the cancellation on the event queue
+       this.executor.execute(new CancelRunnable(d));
    }
 
    // Distributor implementation ------------------------------------
@@ -314,7 +292,7 @@
       boolean added = router.add(r);
 
       if (trace) { log.trace("receiver " + r + (added ? "" : " NOT") + " added"); }
-      
+
       receiversReady = true;
       return added;
    }
@@ -372,7 +350,7 @@
          log.trace(this + " browse"
                   + (filter == null ? "" : ", filter = " + filter));
       }
-      
+
       synchronized (deliveryLock)
       {
          synchronized (refLock)
@@ -380,14 +358,14 @@
             //FIXME - This is currently broken since it doesn't take into account
             // refs paged into persistent storage
             // Also is very inefficient since it makes a copy
-            
+
             //TODO use the ref queue iterator
             List references = delivering(filter);
-                        
-            List undel = undelivered(filter);            
 
+            List undel = undelivered(filter);
+
             references.addAll(undel);
-            
+
             // dereference pass
             ArrayList messages = new ArrayList(references.size());
             for (Iterator i = references.iterator(); i.hasNext();)
@@ -397,25 +375,25 @@
             }
             return messages;
          }
-      }   
+      }
    }
 
    public void deliver(boolean synchronous)
    {
-      checkClosed();           
-     
+      checkClosed();
+
       // We put a delivery request on the event queue.
       try
       {
          Future future = null;
-         
+
          if (synchronous)
          {
             future = new Future();
          }
-                  
+
          this.executor.execute(new DeliveryRunnable(future));
-         
+
          if (synchronous)
          {
             // Wait to complete
@@ -435,25 +413,25 @@
          router.clear();
          router = null;
       }
-      
-   }  
-   
+
+   }
+
    /*
     * This method clears the channel.
     * Basically it acknowledges any outstanding deliveries and consumes the rest of the messages in the channel.
     * We can't just delete the corresponding references directly from the database since
     * a) We might be paging
     * b) The message might remain in the message store causing a leak
-    * 
+    *
     */
    public void removeAllReferences() throws Throwable
-   {        
+   {
       synchronized (refLock)
       {
          synchronized (deliveryLock)
          {
             //Ack the deliveries
-            
+
             //Clone to avoid ConcurrentModificationException
             Set dels = new HashSet(deliveries);
 
@@ -461,26 +439,26 @@
             while (iter.hasNext())
             {
                SimpleDelivery d = (SimpleDelivery) iter.next();
-               
+
                d.acknowledge(null);
             }
-            
+
             //Now we consume the rest of the messages
             //This may take a while if we have a lot of messages including perhaps millions
             //paged in the database - but there's no obvious other way to do it.
             //We cannot just delete them directly from the database - because we may end up with messages leaking
             //in the message store,
             //also we might get race conditions when other channels are updating the same message in the db
-            
+
             //Note - we don't do this in a tx - because the tx could be too big if we have millions of refs
             //paged in storage
-            
+
             MessageReference ref;
             while ((ref = removeFirstInMemory()) != null)
             {
                SimpleDelivery del = new SimpleDelivery(this, ref, false);
-               
-               del.acknowledge(null);           
+
+               del.acknowledge(null);
             }
          }
       }
@@ -580,7 +558,7 @@
     * Returns the count of messages stored AND being delivered.
     */
    public int messageCount()
-   {   
+   {
       synchronized (refLock)
       {
          synchronized (deliveryLock)
@@ -636,8 +614,8 @@
    /*
     * This methods delivers as many messages as possible to the router until no
     * more deliveries are returned. This method should never be called at the
-    * same time as handle. 
-    * 
+    * same time as handle.
+    *
     * @see org.jboss.messaging.core.Channel#deliver()
     */
    protected void deliverInternal()
@@ -647,13 +625,13 @@
          // The iterator is used to iterate through the refs in the channel in the case that they
          // don't match the selectors of any receivers.
          ListIterator iter = null;
-         
+
          MessageReference ref = null;
-         
+
          while (true)
-         {           
+         {
             synchronized (refLock)
-            {              
+            {
                if (iter == null)
                {
                   ref = (MessageReference) messageRefs.peekFirst();
@@ -661,9 +639,9 @@
                else
                {
                   if (iter.hasNext())
-                  {                        
+                  {
                      ref = (MessageReference)iter.next();
-                  } 
+                  }
                   else
                   {
                      ref = null;
@@ -673,6 +651,8 @@
 
             if (ref != null)
             {
+            	if (trace) { log.trace(this + " pushing " + ref); }
+                        
                // Check if message is expired (we also do this on the client
                // side)
                // If so ack it from the channel
@@ -710,15 +690,15 @@
                      if (trace) { log.trace(this + ": no delivery returned for message" + ref + " so no receiver got the message. Delivery is now complete"); }
 
                      receiversReady = false;
-                     
+
                      return;
                   }
                   else if (!del.isSelectorAccepted())
                   {
                      // No receiver accepted the message because no selectors matched, so we create
                      // an iterator (if we haven't already created it) to iterate through the refs
-                     // in the channel. 
-                     
+                     // in the channel.
+
                      // TODO Note that this is only a partial solution since if there are messages
                      // paged to storage it won't try those - i.e. it will only iterate through
                      // those refs in memory. Dealing with refs in storage is somewhat tricky since
@@ -731,12 +711,12 @@
                      if (iter == null)
                      {
                         iter = messageRefs.iterator();
-                     }                     
+                     }
                   }
                   else
                   {
                      if (trace) { log.trace(this + ": " + del + " returned for message:" + ref); }
-                     
+
                      // Receiver accepted the reference
 
                      // We must synchronize here to cope with another race condition where message
@@ -766,7 +746,9 @@
                            }
                            else
                            {
-                              iter.remove();                                
+                              iter.remove();     
+                              if (trace) { log.trace(this + " removed current message from iterator"); }                           
+
                            }
 
                            // delivered
@@ -776,6 +758,7 @@
                               synchronized (deliveryLock)
                               {
                                  deliveries.add(del);
+                                 if (trace) { log.trace(this + " starting to track  " + del); }
                               }
                            }
                         }
@@ -818,9 +801,9 @@
             //pages and is non recoverable a reliable ref will be paged in the database as reliable
             //which makes them hard to remove on server restart.
             //If we always page them as unreliable then it is easy to remove them.
-            ref.setReliable(false);               
+            ref.setReliable(false);
          }
-         
+
          if (tx == null)
          {
             // Don't even attempt synchronous delivery for a reliable message
@@ -838,18 +821,18 @@
                return null;
             }
 
-            checkMemory();                        
+            checkMemory();
 
             ref.setOrdering(messageOrdering.increment());
-            
+
             if (ref.isReliable() && recoverable)
             {
                // Reliable message in a recoverable state - also add to db
                if (trace) { log.trace(this + "adding " + ref + " to database non-transactionally"); }
 
-               pm.addReference(channelID, ref, null);               
+               pm.addReference(channelID, ref, null);
             }
-            
+
             addReferenceInMemory(ref);
 
             // We only do delivery if there are receivers that haven't said they don't want
@@ -877,17 +860,13 @@
                   log.trace(this + " cannot handle reliable messages, dooming the transaction");
                }
                tx.setRollbackOnly();
-            } 
+            }
             else
             {
                // add to post commit callback
                ref.setOrdering(messageOrdering.increment());
                this.getCallback(tx).addRef(ref);
-               if (trace)
-               {
-                  log.trace(this + " added transactionally " + ref
-                           + " in memory");
-               }
+               if (trace) { log.trace(this + " added " + ref + " to memory transactional callback, in transaction: " + tx); }
             }
 
             if (ref.isReliable() && recoverable)
@@ -913,26 +892,23 @@
    }
 
    protected void acknowledgeInternal(Delivery d) throws Exception
-   {      
+   {
       synchronized (deliveryLock)
       {
          acknowledgeInMemory(d);
       }
-         
+
       if (recoverable && d.getReference().isReliable())
       {
          pm.removeReference(channelID, d.getReference(), null);
       }
-           
-      d.getReference().releaseMemoryReference();        
+
+      d.getReference().releaseMemoryReference();
    }
 
    protected void cancelInternal(Delivery del) throws Exception
    {
-      if (trace)
-      {
-         log.trace(this + " cancelling " + del + " in memory");
-      }
+      if (trace) { log.trace(this + " cancelling " + del + " in memory"); }
 
       boolean removed;
 
@@ -968,14 +944,14 @@
                refsInStorage++;
             }
          }
-         
+
          //We may need to update the delivery count in the database
          if (ref.isReliable())
          {
             pm.updateDeliveryCount(this.channelID, ref);
          }
 
-         if (trace) { log.trace(this + " added " + ref + " back into state"); }
+         if (trace) { log.trace(this + " added " + ref + " back into memory, ready for redelivery"); }
       }
    }
 
@@ -999,6 +975,7 @@
             paging = false;
          }
 
+         if (trace) { log.trace(this + " removing first message in memory, which is " + result); }
          return (MessageReference) result;
       }
    }
@@ -1043,21 +1020,21 @@
       // if (mm != null)
       // {
       // boolean isLow = mm.isMemoryLow();
-      //         
+      //
       // if (isLow)
       // {
-      //            
+      //
       // synchronized (refLock)
       // {
       // if (!paging)
       // {
       // log.info("Memory is low:" + this);
-      //                  
+      //
       // fullSize = messageRefs.size() + 1;
-      //                  
+      //
       // //TODO Make this configurable
       // pageSize = downCacheSize = Math.max(1, fullSize / 50);
-      //                  
+      //
       // log.info("Turned paging on, fullSize=" + fullSize + " dc:" +
       // downCacheSize + " ps: " + pageSize);
       // }
@@ -1065,7 +1042,7 @@
       // {
       // //log.info("already paging");
       // }
-      //               
+      //
       // }
       // }
       // }
@@ -1091,11 +1068,7 @@
          {
             messageRefs.addLast(ref, ref.getPriority());
 
-            if (trace)
-            {
-               log.trace(this + " added " + ref
-                        + " non-transactionally in memory");
-            }
+            if (trace) { log.trace(this + " added " + ref + " in memory"); }
 
             if (messageRefs.size() == fullSize)
             {
@@ -1250,7 +1223,7 @@
       {
          log.trace(this + " removed " + d + " from memory:" + removed);
       }
-      
+
       return removed;
    }
 
@@ -1268,7 +1241,7 @@
 
       // We may load less than desired due to "holes" - this is ok
       int numberLoaded = refInfos.size();
-      
+
       if (numberLoaded == 0)
       {
          throw new IllegalStateException(
@@ -1331,7 +1304,7 @@
             // return a reference
             // to the pre-existing message
             MessageReference ref = ms.reference(m);
-            
+
             refMap.put(new Long(m.getMessageID()), ref);
          }
       }
@@ -1366,15 +1339,15 @@
          ref.setDeliveryCount(info.getDeliveryCount());
 
          ref.setOrdering(info.getOrdering());
-         
+
          //We ignore the reliable field from the message - this is because reliable might be true on the message
          //but this is a non recoverable state
-         
+
          //FIXME - Really the message shouldn't have a reliable field at all,
          //Reliability is an attribute of the message reference, not the message
-         
+
          ref.setReliable(info.isReliable());
-         
+
          messageRefs.addLast(ref, ref.getPriority());
 
          if (recoverable && ref.isReliable())
@@ -1436,8 +1409,8 @@
 
       return callback;
    }
-   
 
+
    // Private -------------------------------------------------------
 
    // Inner classes -------------------------------------------------
@@ -1591,7 +1564,7 @@
          {
             MessageReference ref = (MessageReference) iter.next();
 
-            if (trace) { log.trace(this + ": adding " + ref + " to non-recoverable state"); }
+            if (trace) { log.trace(this + " adding " + ref + " to memory"); }
 
             try
             {
@@ -1687,7 +1660,7 @@
 
       return d;
    }
-   
+
    private void checkClosed()
    {
       if (router == null)
@@ -1695,18 +1668,18 @@
          throw new IllegalStateException(this + " closed");
       }
    }
-  
+
    // Inner classes -------------------------------------------------
 
    private class DeliveryRunnable implements Runnable
    {
       Future result;
-      
+
       DeliveryRunnable(Future result)
       {
          this.result = result;
       }
-      
+
       public void run()
       {
          receiversReady = true;
@@ -1718,6 +1691,28 @@
       }
    }
 
+   private class CancelRunnable implements Runnable
+   {
+      Delivery del;
+
+      CancelRunnable(Delivery del)
+      {
+         this.del = del;
+      }
+
+      public void run()
+      {
+         try
+         {
+            cancelInternal(del);
+         }
+         catch (Exception e)
+         {
+            log.error("Failed to cancel delivery", e);
+         }
+      }
+   }
+
    private class HandleRunnable implements Runnable
    {
       Future result;
@@ -1738,5 +1733,5 @@
          Delivery d = handleInternal(sender, routable, null);
          result.setResult(d);
       }
-   }   
+   }
 }

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -398,7 +398,7 @@
             
             ps.setLong(2, size);
             
-            int rows = ps.executeUpdate();
+            int rows = updateWithRetry(ps);
             
             if (trace)
             {
@@ -430,7 +430,7 @@
          
          ps.setString(2, counterName);
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -483,8 +483,6 @@
       PreparedStatement ps = null;
       TransactionWrapper wrap = new TransactionWrapper();
       
-      final int MAX_TRIES = 25;      
-      
       try
       {
          conn = ds.getConnection();
@@ -496,41 +494,15 @@
          ps.setLong(2, orderEnd);
          
          ps.setLong(3, channelID);
-         
-         int tries = 0;
-         
-         while (true)
+                  
+         int rows = updateWithRetry(ps);
+               
+         if (trace)
          {
-            try
-            {
-               int rows = ps.executeUpdate();
-               
-               if (trace)
-               {
-                  log.trace(JDBCUtil.statementToString(updateReliableRefs, new Long(channelID),
-                        new Long(orderStart), new Long(orderEnd))
-                        + " updated " + rows + " rows");
-               }
-               if (tries > 0)
-               {
-                  log.warn("Update worked after retry");
-               }
-               break;
-            }
-            catch (SQLException e)
-            {
-               log.warn("SQLException caught - assuming deadlock detected, try:" + (tries + 1), e);
-               tries++;
-               if (tries == MAX_TRIES)
-               {
-                  log.error("Retried " + tries + " times, now giving up");
-                  throw new IllegalStateException("Failed to update references");
-               }
-               log.warn("Trying again after a pause");
-               //Now we wait for a random amount of time to minimise risk of deadlock
-               Thread.sleep((long)(Math.random() * 500));
-            }  
-         }
+            log.trace(JDBCUtil.statementToString(updateReliableRefs, new Long(channelID),
+                  new Long(orderStart), new Long(orderEnd))
+                  + " updated " + rows + " rows");
+         }          
       }
       catch (Exception e)
       {
@@ -562,6 +534,8 @@
          wrap.end();
       }
    }
+   
+   
          
    public int getNumberOfUnloadedReferences(long channelID) throws Exception
    {
@@ -980,7 +954,7 @@
             }
             else
             {
-               int rows = psInsertReference.executeUpdate();
+               int rows = updateWithRetry(psInsertReference);
                
                if (trace)
                {
@@ -1037,7 +1011,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                                       
                   if (trace)
                   {
@@ -1046,7 +1020,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                  
                   if (trace)
                   {
@@ -1062,7 +1036,7 @@
          
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psInsertReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psInsertReference);
             
             if (trace)
             {
@@ -1071,7 +1045,7 @@
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace)
                {
@@ -1080,7 +1054,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -1213,7 +1187,7 @@
             }
             else
             {
-               int rows = psDeleteReference.executeUpdate();
+               int rows = updateWithRetry(psDeleteReference);
                
                if (trace)
                {
@@ -1271,7 +1245,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -1280,7 +1254,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -1296,7 +1270,7 @@
          
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psDeleteReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psDeleteReference);
             
             if (trace)
             {
@@ -1305,7 +1279,7 @@
             
             if (messageDeletionsInBatch)
             {
-               int[] rowsMessage = psDeleteMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -1314,7 +1288,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -1682,7 +1656,7 @@
             }
             else
             {
-               int rows = psUpdateReference.executeUpdate();
+               int rows = updateWithRetry(psUpdateReference);
                
                if (trace)
                {
@@ -1696,7 +1670,7 @@
                      
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psUpdateReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psUpdateReference);
             
             if (trace)
             {
@@ -1742,11 +1716,11 @@
    {      
       if (tx != null)
       {
-         //In a tx so we just add the ref in the tx in memory for now
+         // We are in a transaction so we just add the ref in the tx in memory for now
 
          TransactionCallback callback = getCallback(tx);
-
          callback.addReferenceToAdd(channelID, ref);
+         if (trace) { log.trace(this + " added " + ref + " to database transactional callback, in transaction: " + tx); }
       }
       else
       {         
@@ -1773,7 +1747,7 @@
             // Add the reference
             addReference(channelID, ref, psReference, true);
             
-            int rows = psReference.executeUpdate();
+            int rows = updateWithRetry(psReference);
             
             if (trace)
             {
@@ -1798,7 +1772,7 @@
                updateMessageChannelCount(m, psMessage);
             }
                            
-            rows = psMessage.executeUpdate();
+            rows = updateWithRetry(psMessage);
             if (trace)
             {
                log.trace("Inserted/updated " + rows + " rows");
@@ -1878,7 +1852,7 @@
          
          psReference.setLong(3, ref.getMessageID());
          
-         int rows = psReference.executeUpdate();                         
+         int rows = updateWithRetry(psReference);                         
       }
       catch (Exception e)
       {
@@ -1946,7 +1920,7 @@
             //Remove the message reference
             removeReference(channelID, ref, psReference);
             
-            int rows = psReference.executeUpdate();
+            int rows = updateWithRetry(psReference);
             
             if (trace)
             {
@@ -1971,7 +1945,7 @@
                updateMessageChannelCount(m, psMessage);
             }
                               
-            rows = psMessage.executeUpdate();
+            rows = updateWithRetry(psMessage);
             
             if (trace)
             {
@@ -2804,6 +2778,8 @@
       //TODO - A slight optimisation - it's possible we have refs referring to the same message
       //so we will end up acquiring the lock more than once which is unnecessary
       //If find unique set of messages can avoid this
+      if (trace) { log.trace("handling before commit 1PC, tx: " + tx);  }
+
       List allRefs = new ArrayList(refsToAdd.size() + refsToRemove.size());
       Iterator iter = refsToAdd.iterator();
       while (iter.hasNext())
@@ -2879,7 +2855,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -2934,7 +2910,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                   
                   if (trace)
                   {
@@ -2943,7 +2919,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -2959,7 +2935,7 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -2968,7 +2944,7 @@
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace)
                {
@@ -2977,7 +2953,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3028,7 +3004,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -3085,7 +3061,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -3094,7 +3070,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3110,7 +3086,7 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -3119,7 +3095,7 @@
             
             if (messageDeletionsInBatch)
             {
-               int[] rowsMessage = psDeleteMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -3128,7 +3104,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3322,7 +3298,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -3331,7 +3307,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3349,7 +3325,7 @@
          {
             if (messageDeletionsInBatch)
             {
-               int[] rows = psDeleteMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -3361,7 +3337,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rows = psUpdateMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3496,7 +3472,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -3551,7 +3527,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                   
                   if (trace)
                   {
@@ -3560,7 +3536,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3576,7 +3552,7 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -3585,7 +3561,7 @@
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace)
                {
@@ -3594,7 +3570,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3637,7 +3613,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace)
                {
@@ -3651,7 +3627,7 @@
          
          if (batch)
          {
-            int[] rows = psReference.executeBatch();
+            int[] rows = updateWithRetryBatch(psReference);
             
             if (trace)
             {
@@ -3821,7 +3797,7 @@
             {
                if (removed)
                {
-                  int rows = psDeleteMessage.executeUpdate();
+                  int rows = updateWithRetry(psDeleteMessage);
                   
                   if (trace)
                   {
@@ -3830,7 +3806,7 @@
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -3848,7 +3824,7 @@
          {
             if (messageDeletionsInBatch)
             {
-               int[] rows = psDeleteMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psDeleteMessage);
                
                if (trace)
                {
@@ -3860,7 +3836,7 @@
             }
             if (messageUpdatesInBatch)
             {
-               int[] rows = psUpdateMessage.executeBatch();
+               int[] rows = updateWithRetryBatch(psUpdateMessage);
                
                if (trace)
                {
@@ -3952,7 +3928,7 @@
          ps.setInt(3, formatID);
          ps.setBytes(4, xid.getGlobalTransactionId());
 
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
       }
       finally
       {
@@ -3976,7 +3952,7 @@
       }
    }
    
-   protected void removeTXRecord(Connection conn, Transaction tx) throws SQLException
+   protected void removeTXRecord(Connection conn, Transaction tx) throws Exception
    {
       PreparedStatement ps = null;
       try
@@ -3985,7 +3961,7 @@
          
          ps.setLong(1, tx.getId());
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4079,7 +4055,7 @@
          
          ps.setLong(1, tx.getId());        
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4090,7 +4066,7 @@
          ps = conn.prepareStatement(commitMessageRef2);
          ps.setLong(1, tx.getId());         
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4125,7 +4101,7 @@
          
          ps.setLong(1, tx.getId());         
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4137,7 +4113,7 @@
          ps = conn.prepareStatement(rollbackMessageRef2);
          ps.setLong(1, tx.getId());
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -4511,6 +4487,70 @@
       log.trace("Batch update " + name + ", " + action + " total of " + count + " rows");
    }
    
+   protected int updateWithRetry(PreparedStatement ps) throws Exception
+   {
+      return updateWithRetry(ps, false)[0];
+   }
+   
+   protected int[] updateWithRetryBatch(PreparedStatement ps) throws Exception
+   {
+      return updateWithRetry(ps, true);
+   }
+   
+   private int[] updateWithRetry(PreparedStatement ps, boolean batch) throws Exception
+   {
+      final int MAX_TRIES = 25;      
+      
+      int rows = 0;
+      
+      int[] rowsArr = null;
+      
+      int tries = 0;
+      
+      while (true)
+      {
+         try
+         {
+            if (batch)
+            {
+               rowsArr = ps.executeBatch();
+            }
+            else
+            {
+               rows = ps.executeUpdate();
+            }
+            
+            if (tries > 0)
+            {
+               log.warn("Update worked after retry");
+            }
+            break;
+         }
+         catch (SQLException e)
+         {
+            log.warn("SQLException caught - assuming deadlock detected, try:" + (tries + 1), e);
+            tries++;
+            if (tries == MAX_TRIES)
+            {
+               log.error("Retried " + tries + " times, now giving up");
+               throw new IllegalStateException("Failed to update references");
+            }
+            log.warn("Trying again after a pause");
+            //Now we wait for a random amount of time to minimise risk of deadlock
+            Thread.sleep((long)(Math.random() * 500));
+         }  
+      }
+      
+      if (batch)
+      {
+         return rowsArr;
+      }
+      else
+      {
+         return new int[] { rows };
+      }
+   }
+   
    // Private -------------------------------------------------------
 
    // never access directly

Modified: branches/Branch_1_0/tests/smoke/build.xml
===================================================================
--- branches/Branch_1_0/tests/smoke/build.xml	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/smoke/build.xml	2006-12-03 08:36:09 UTC (rev 1693)
@@ -74,16 +74,28 @@
 
       <!-- 4.0.0, 4.0.1 NOT SUPPORTED -->
 
+      <!--
+           4.0.1sp1
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss401sp1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.2
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss402.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 <!--
+      <!--
+           4.0.3
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss403.home}"/>
          <param name="run.secure-socket.example" value="false"/>
@@ -94,6 +106,10 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 -->
+      <!--
+           4.0.3SP1
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss403SP1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
@@ -112,6 +128,10 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.4.GA
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss404GA.home}"/>
       </antcall>
@@ -128,12 +148,20 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 <!--
+      <!--
+           4.0.5.GA
+      -->
+
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405CR1.home}"/>
+         <param name="jboss.home" value="${jboss405GA.home}"/>
       </antcall>
-
+                                                                                                <!--
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405CR1.home}"/>
+         <param name="jboss.home" value="${jboss405GA-installer.home}"/>
+      </antcall>
+                                                                                                 -->
+      <antcall target="installation-test">
+         <param name="jboss.home" value="${jboss405GA.home}"/>
          <param name="release.admin.target" value="standalone"/>
          <param name="run.mdb.example" value="false"/>
          <param name="run.stateless.example" value="false"/>
@@ -141,7 +169,7 @@
       </antcall>
 
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405CR1ejb3.home}"/>
+         <param name="jboss.home" value="${jboss405GAejb3.home}"/>
          <param name="no.java4" value="true"/>
          <param name="run.ejb3mdb.example" value="true"/>
       </antcall>

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -829,6 +829,9 @@
          dels[i].cancel();   
       }
       
+      //Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -862,6 +865,9 @@
          dels[i].cancel();
       }
       
+//    Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -896,6 +902,8 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);      
       
       //This should cause the down cache to be flushed
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -781,6 +781,9 @@
          dels[i].cancel();  
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -814,6 +817,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -847,6 +853,8 @@
       {
          dels[i].cancel();
       }
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
       
       //consumeCount += 20;
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -819,6 +819,9 @@
          dels[i].cancel();  
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -852,6 +855,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -887,6 +893,9 @@
       }
       
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 20 ref in storage

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -926,6 +926,9 @@
          dels[i].cancel(); 
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -965,6 +968,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -1004,6 +1010,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //consumeCount += 20;
       
       //This should cause the down cache to be flushed

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -880,6 +880,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -918,6 +921,8 @@
       {
          dels[i].cancel();
       }
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
       
       //This should cause the down cache to be flushed
       
@@ -957,6 +962,9 @@
       {
          dels[i].cancel();
       }
+           
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);     
       
       //consumeCount += 20;
       

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -913,6 +913,9 @@
          dels[i].cancel();   
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250); 
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -952,6 +955,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -991,6 +997,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //consumeCount += 20;
       
       //This should cause the down cache to be flushed

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/JMSTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -194,6 +194,45 @@
       conn.close();
    }
 
+   public void test_Persistent_Transactional_Send() throws Exception
+   {
+      ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+
+      Queue queue = (Queue)ic.lookup("/queue/JMSTestQueue");
+
+      Connection conn = cf.createConnection();
+
+      Session session = conn.createSession(true, Session.SESSION_TRANSACTED);
+
+      MessageProducer prod = session.createProducer(queue);
+      prod.setDeliveryMode(DeliveryMode.PERSISTENT);
+
+      TextMessage m = session.createTextMessage("message one");
+      prod.send(m);
+      m = session.createTextMessage("message two");
+      prod.send(m);
+
+      session.commit();
+
+      conn.close();
+
+      conn = cf.createConnection();
+
+      session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+      MessageConsumer cons = session.createConsumer(queue);
+
+      conn.start();
+
+      TextMessage rm = (TextMessage)cons.receive();
+      assertEquals("message one", rm.getText());
+      rm = (TextMessage)cons.receive();
+      assertEquals("message two", rm.getText());
+
+      conn.close();
+   }
+
+
    public void test_NonPersistent_Transactional_Acknowledgment() throws Exception
    {
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
@@ -227,7 +266,6 @@
       conn.close();
    }
 
-
    public void test_Asynchronous_to_Client() throws Exception
    {
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-03 08:36:09 UTC (rev 1693)
@@ -895,6 +895,9 @@
 
           cons1.close();
           
+          //Cancelling is asynch so can take some time
+          Thread.sleep(500);
+          
           //rollback should cause redelivery of messages
 
           //in this case redelivery occurs to a different receiver
@@ -1009,6 +1012,9 @@
           assertEquals("hello1", rm1.getText());
 
           cons1.close();
+          
+          //Give time for asynch cancel to happen
+          Thread.sleep(500);
          
           log.debug("sess.recover()");
 

Copied: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/stress/ConcurrentCloseStressTest.java (from rev 1692, branches/Branch_1_0_1_SP/tests/src/org/jboss/test/messaging/jms/stress/ConcurrentCloseStressTest.java)

Modified: branches/Branch_1_0/util/do-not-distribute.properties
===================================================================
--- branches/Branch_1_0/util/do-not-distribute.properties	2006-12-03 07:55:29 UTC (rev 1692)
+++ branches/Branch_1_0/util/do-not-distribute.properties	2006-12-03 08:36:09 UTC (rev 1693)
@@ -6,7 +6,7 @@
 #jboss.home=C:\\work/src/cvs/jboss-head/build/output/jboss-5.0.0.Alpha
 #jboss.home=C:\\work\\src\\jboss-4.0.3SP1-src\\build\\output\\jboss-4.0.3SP1
 jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
-#jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
+jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3
 messaging.config.name=messaging
 relative.artifact.location=../output/lib
 messaging.artifact.name=jboss-messaging-scoped.sar



From gavin.king at jboss.com  Sun Dec  3 04:02:27 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 04:02:27 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view   ...
Message-ID: <E1GqnEx-00046S-1A@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 04:02:26

  Modified:    seam-gen/view   edit.xhtml.ftl view.xhtml.ftl
  Log:
  JBSEAM-554
  
  Revision  Changes    Path
  1.10      +8 -0      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- edit.xhtml.ftl	2 Dec 2006 02:53:10 -0000	1.9
  +++ edit.xhtml.ftl	3 Dec 2006 09:02:26 -0000	1.10
  @@ -49,6 +49,14 @@
   			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertDateTime type="both" dateStyle="short"/>
   			           </h:inputText>
  +<#elseif property.value.typeName == "big_decimal">
  +			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			               <f:convertNumber/>
  +			           </h:inputText>
  +<#elseif property.value.typeName == "big_integer">
  +			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			               <f:convertNumber integerOnly="true"/>
  +			           </h:inputText>
   <#elseif property.value.typeName == "boolean">
   			           <h:selectBooleanCheckbox id="${property.name}"
   			               value="${'#'}{${homeName}.instance.${property.name}}"/>
  
  
  
  1.4       +8 -0      jboss-seam/seam-gen/view/view.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: view.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/view.xhtml.ftl,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- view.xhtml.ftl	14 Nov 2006 05:03:48 -0000	1.3
  +++ view.xhtml.ftl	3 Dec 2006 09:02:26 -0000	1.4
  @@ -46,6 +46,14 @@
   			           <h:outputText value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertDateTime type="both" dateStyle="short"/>
   			           </h:outputText>
  +<#elseif property.value.typeName == "big_decimal">
  +			           <h:outputText value="${'#'}{${homeName}.instance.${property.name}}">
  +			               <f:convertNumber/>
  +			           </h:outputText>
  +<#elseif property.value.typeName == "big_integer">
  +			           <h:outputText value="${'#'}{${homeName}.instance.${property.name}}">
  +			               <f:convertNumber integerOnly="true"/>
  +			           </h:outputText>
   <#else>
                          ${'#'}{${homeName}.instance.${property.name}}
   </#if>
  
  
  


From gavin.king at jboss.com  Sun Dec  3 04:20:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 04:20:00 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1GqnVw-0004Ic-KC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 04:20:00

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  use textArea for long fields, and adjust field size
  
  Revision  Changes    Path
  1.11      +10 -1     jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- edit.xhtml.ftl	3 Dec 2006 09:02:26 -0000	1.10
  +++ edit.xhtml.ftl	3 Dec 2006 09:20:00 -0000	1.11
  @@ -60,6 +60,15 @@
   <#elseif property.value.typeName == "boolean">
   			           <h:selectBooleanCheckbox id="${property.name}"
   			               value="${'#'}{${homeName}.instance.${property.name}}"/>
  +<#elseif property.value.typeName == "string">
  +<#if property.columnIterator.next().length gt 200>
  +			           <h:inputTextarea id="${property.name}"
  +			               value="${'#'}{${homeName}.instance.${property.name}}"/>
  +<#else>
  +                       <h:inputText id="${property.name}" 
  +                            size="${property.columnIterator.next().length}"
  +                            value="${'#'}{${homeName}.instance.${property.name}}"/>
  +</#if>
   <#else>
                           <h:inputText id="${property.name}"
                               value="${'#'}{${homeName}.instance.${property.name}}"/>
  
  
  


From gavin.king at jboss.com  Sun Dec  3 04:21:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 04:21:41 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/stylesheet  ...
Message-ID: <E1GqnXZ-0004MV-2q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 04:21:41

  Modified:    seam-gen/view/stylesheet  theme.css
  Log:
  use textArea for long fields, and adjust field size
  
  Revision  Changes    Path
  1.3       +2 -2      jboss-seam/seam-gen/view/stylesheet/theme.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: theme.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/stylesheet/theme.css,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- theme.css	2 Nov 2006 04:08:27 -0000	1.2
  +++ theme.css	3 Dec 2006 09:21:41 -0000	1.3
  @@ -132,9 +132,9 @@
   	color: red;
   	text-align: left;
   }
  -.value input {
  +/*.value input {
   	width:190px;
  -}
  +}*/
   .errors input {
   	border: 1px solid red;
   }
  
  
  


From bwang at jboss.com  Sun Dec  3 05:29:58 2006
From: bwang at jboss.com (Ben Wang)
Date: Sun, 03 Dec 2006 05:29:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/aop   ...
Message-ID: <E1Gqobe-0005Kq-6o@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/03 05:29:58

  Modified:    tests/functional/org/jboss/cache/aop   Tag:
                        Branch_JBossCache_1_4_0 NewReplicatedAopTest.java
                        NewLocalAopTest.java
  Log:
  Test for JBCACHE-885 but it works.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.10.2.1  +29 -0     JBossCache/tests/functional/org/jboss/cache/aop/Attic/NewReplicatedAopTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewReplicatedAopTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/aop/Attic/NewReplicatedAopTest.java,v
  retrieving revision 1.10
  retrieving revision 1.10.2.1
  diff -u -b -r1.10 -r1.10.2.1
  --- NewReplicatedAopTest.java	21 May 2006 15:46:39 -0000	1.10
  +++ NewReplicatedAopTest.java	3 Dec 2006 10:29:57 -0000	1.10.2.1
  @@ -114,6 +114,35 @@
         assertEquals("Age should be ", 0, remote.getAge());
      }
   
  +   public void testPutArray1() throws Exception
  +   {
  +      log_.info("testPutArray1() ....");
  +      long[] arr = new long[] {1, 2};
  +      cache_.putObject("array", arr);
  +
  +      long[] a2 = (long[])cache1_.getObject("array");
  +      assertEquals("arr 0", 1, a2[0]);
  +   }
  +
  +   public void testPutArray2() throws Exception
  +   {
  +      log_.info("testPutArray2() ....");
  +      Person p1 = new Person();
  +      p1.setName("Ben");
  +      p1.setAge(10);
  +
  +      Person p2 = new Person();
  +      p2.setName("Joe");
  +      p2.setAge(20);
  +      Person[] arr = new Person[] {p1, p2};
  +
  +      cache_.putObject("array", arr);
  +
  +      Person[] a2 = (Person[])cache1_.getObject("array");
  +      assertEquals("arr 0", "Ben", a2[0].getName());
  +   }
  +
  +
      /**
       * JBCACHE-200.
       * @throws Exception
  
  
  
  1.8.2.3   +21 -0     JBossCache/tests/functional/org/jboss/cache/aop/Attic/NewLocalAopTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewLocalAopTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/aop/Attic/NewLocalAopTest.java,v
  retrieving revision 1.8.2.2
  retrieving revision 1.8.2.3
  diff -u -b -r1.8.2.2 -r1.8.2.3
  --- NewLocalAopTest.java	16 Nov 2006 06:44:48 -0000	1.8.2.2
  +++ NewLocalAopTest.java	3 Dec 2006 10:29:58 -0000	1.8.2.3
  @@ -237,6 +237,27 @@
         assertEquals("Objects size should be ", 2, map.size());
      }
   
  +   public void testPutArray1() throws Exception
  +   {
  +      log_.info("testPutArray1() ....");
  +      long[] arr = new long[] {1, 2};
  +      cache_.putObject("array", arr);
  +   }
  +
  +   public void testPutArray2() throws Exception
  +   {
  +      log_.info("testPutArray2() ....");
  +      Person p1 = new Person();
  +      p1.setName("Ben");
  +      p1.setAge(10);
  +
  +      Person p2 = new Person();
  +      p2.setName("Joe");
  +      p2.setAge(20);
  +      Person[] arr = new Person[] {p1, p2};
  +      cache_.putObject("array", arr);
  +   }
  +
      public void testNotification() throws Exception
      {
         log_.info("testNotification() ....");
  
  
  


From bwang at jboss.com  Sun Dec  3 05:30:30 2006
From: bwang at jboss.com (Ben Wang)
Date: Sun, 03 Dec 2006 05:30:30 -0500
Subject: [jboss-cvs] JBossCache/tests-50/functional/org/jboss/cache/pojo  ...
Message-ID: <E1GqocA-0005N5-TX@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/03 05:30:30

  Modified:    tests-50/functional/org/jboss/cache/pojo 
                        NewReplicatedTest.java
  Log:
  added test for array.
  
  Revision  Changes    Path
  1.7       +29 -0     JBossCache/tests-50/functional/org/jboss/cache/pojo/NewReplicatedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewReplicatedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/NewReplicatedTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- NewReplicatedTest.java	31 Oct 2006 11:07:17 -0000	1.6
  +++ NewReplicatedTest.java	3 Dec 2006 10:30:30 -0000	1.7
  @@ -168,6 +168,35 @@
         assertEquals("Name should be ", 95123, remote.getZip());
      }
   
  +   public void testPutArray1() throws Exception
  +   {
  +      log_.info("testPutArray1() ....");
  +      long[] arr = new long[] {1, 2};
  +      cache_.attach("array", arr);
  +
  +      long[] a2 = (long[])cache1_.find("array");
  +      assertEquals("arr 0", 1, a2[0]);
  +   }
  +
  +   public void testPutArray2() throws Exception
  +   {
  +      log_.info("testPutArray2() ....");
  +      Person p1 = new Person();
  +      p1.setName("Ben");
  +      p1.setAge(10);
  +
  +      Person p2 = new Person();
  +      p2.setName("Joe");
  +      p2.setAge(20);
  +      Person[] arr = new Person[] {p1, p2};
  +
  +      cache_.attach("array", arr);
  +
  +      Person[] a2 = (Person[])cache1_.find("array");
  +      assertEquals("arr 0", "Ben", a2[0].getName());
  +   }
  +
  +
      /**
       * JBCACHE-200.
       *
  
  
  


From msurtani at jboss.com  Sun Dec  3 11:00:28 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 03 Dec 2006 11:00:28 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/aop/statetransfer ...
Message-ID: <E1GqtlU-00029e-KG@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/03 11:00:28

  Modified:    tests/functional/org/jboss/cache/aop/statetransfer  Tag:
                        Branch_JBossCache_1_3_0
                        StateTransferAopTestBase.java
  Log:
  wc
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.1  +36 -13    JBossCache/tests/functional/org/jboss/cache/aop/statetransfer/Attic/StateTransferAopTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferAopTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/aop/statetransfer/Attic/StateTransferAopTestBase.java,v
  retrieving revision 1.13
  retrieving revision 1.13.2.1
  diff -u -b -r1.13 -r1.13.2.1
  --- StateTransferAopTestBase.java	19 Mar 2006 05:30:55 -0000	1.13
  +++ StateTransferAopTestBase.java	3 Dec 2006 16:00:28 -0000	1.13.2.1
  @@ -303,12 +303,16 @@
       * 
       * @throws Exception
       */
  -   public void testConcurrentActivationSync() throws Exception
  -   { 
  -      log.info("Enter testConcurrentActivationSync");
         
  -      concurrentActivationTest(true);
  -   }
  +   // commented out since concurrent activations will cause deadlocks and then timeouts since JBCACHE-875.
  +   // Correctness over performance. - Manik
  +   
  +//   public void testConcurrentActivationSync() throws Exception
  +//   {
  +//      log.info("Enter testConcurrentActivationSync");
  +//
  +//      concurrentActivationTest(true);
  +//   }
      
      /**
       * Tests concurrent activation of the same subtree by multiple nodes in a 
  @@ -415,13 +419,17 @@
       * 
       * @throws Exception
       */
  -   public void testConcurrentUseSync() throws Exception
  -   { 
  -      log.info("Enter testConcurrentUseSync");
         
  -      concurrentUseTest(true);
  -   }
  +   // commented out since concurrent activations will cause deadlocks and then timeouts since JBCACHE-875.
  +   // Correctness over performance. - Manik
      
  +//   public void testConcurrentUseSync() throws Exception
  +//   {
  +//      log.info("Enter testConcurrentUseSync");
  +//
  +//      concurrentUseTest(true);
  +//   }
  +//
      /**
       * Tests partial state transfer under heavy concurrent load and REPL_ASYNC.
       * See <code>concurrentUseTest</code> for details.
  @@ -471,6 +479,10 @@
            {
               stressors[i] = new CacheStressor(semaphore, names[i], sync);
               caches[i + 1] = stressors[i].getTreeCache();
  +            stressors[i].getTreeCache().put("/" + names[i], null);
  +         }
  +         for (int i = 0; i < count; i++)
  +         {
               stressors[i].start();
               // Give each one a chance to stabilize
               sleepThread(100);
  @@ -788,6 +800,17 @@
         {
            try
            {
  +            TransactionManager m = cache.getTransactionManager();
  +            try
  +            {
  +               if (m!= null && m.getTransaction() != null)
  +               {
  +                  m.rollback();
  +               }
  +            }
  +            catch (Exception e)
  +            {
  +            }
               cache.stopService();
               cache.destroyService();
            }
  
  
  


From msurtani at jboss.com  Sun Dec  3 11:00:28 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 03 Dec 2006 11:00:28 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/aop/loader ...
Message-ID: <E1GqtlU-00029p-VC@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/03 11:00:28

  Modified:    tests/functional/org/jboss/cache/aop/loader  Tag:
                        Branch_JBossCache_1_3_0 CacheLoaderTestsBase.java
  Log:
  wc
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.1   +3 -1      JBossCache/tests/functional/org/jboss/cache/aop/loader/Attic/CacheLoaderTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/aop/loader/Attic/CacheLoaderTestsBase.java,v
  retrieving revision 1.8
  retrieving revision 1.8.2.1
  diff -u -b -r1.8 -r1.8.2.1
  --- CacheLoaderTestsBase.java	9 Mar 2006 20:15:30 -0000	1.8
  +++ CacheLoaderTestsBase.java	3 Dec 2006 16:00:28 -0000	1.8.2.1
  @@ -19,7 +19,7 @@
    * Commons tests for all CacheLoaders. Aop version.
    *
    * @author bwang
  - * @version $Id: CacheLoaderTestsBase.java,v 1.8 2006/03/09 20:15:30 smarlow Exp $
  + * @version $Id: CacheLoaderTestsBase.java,v 1.8.2.1 2006/12/03 16:00:28 msurtani Exp $
    */
   abstract public class CacheLoaderTestsBase extends AbstractCacheLoaderTestBase {
      TreeCacheAop cache;
  @@ -64,9 +64,11 @@
         cache.evict(Fqn.fromString("/first/second/third"));  // removes node, because there are no children
         addDelay();
         assertFalse(cache.exists("/first/second/third"));
  +      assertNull("Should not exist at all, even if marked for removal", cache.peek(Fqn.fromString("/first/second/third")));
         assertTrue(cache.exists("/first/second"));
         assertTrue(cache.exists("/first"));
         String val = (String) cache.getObject("/first/second/third"); // should be loaded from cache loader
  +
         assertEquals("val1", val);
         assertTrue(cache.exists("/first/second/third"));
         assertTrue(cache.exists("/first/second"));
  
  
  


From msurtani at jboss.com  Sun Dec  3 11:00:29 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 03 Dec 2006 11:00:29 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/aop  ...
Message-ID: <E1GqtlV-0002A0-Jf@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/03 11:00:29

  Modified:    src/org/jboss/cache/aop  Tag: Branch_JBossCache_1_3_0
                        TreeCacheAop.java
  Log:
  wc
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.23.2.2  +3 -0      JBossCache/src/org/jboss/cache/aop/Attic/TreeCacheAop.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheAop.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/aop/Attic/TreeCacheAop.java,v
  retrieving revision 1.23.2.1
  retrieving revision 1.23.2.2
  diff -u -b -r1.23.2.1 -r1.23.2.2
  --- TreeCacheAop.java	13 Apr 2006 09:27:22 -0000	1.23.2.1
  +++ TreeCacheAop.java	3 Dec 2006 16:00:29 -0000	1.23.2.2
  @@ -127,6 +127,9 @@
         boolean sendNodeEvent = false;
         // Let's do it brute force.
         _remove(null, fqn, create_undo_ops, sendNodeEvent);
  +
  +      // since this is not in the scope of a tx, do a realRemove() immediately - Manik, 1/Dec/2006 - JBCACHE-871
  +      realRemove(fqn, false);
      }
   
      /**
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 12:26:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 12:26:23 -0500
Subject: [jboss-cvs] JBossAS SVN: r58818 -
	trunk/varia/src/main/org/jboss/tools
Message-ID: <E1Gqv6d-0003d3-T6@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-03 12:26:21 -0500 (Sun, 03 Dec 2006)
New Revision: 58818

Modified:
   trunk/varia/src/main/org/jboss/tools/ClassVersionInfo.java
Log:
Add a main so this can be used to print the serialVersionUID info.

Modified: trunk/varia/src/main/org/jboss/tools/ClassVersionInfo.java
===================================================================
--- trunk/varia/src/main/org/jboss/tools/ClassVersionInfo.java	2006-12-02 04:09:03 UTC (rev 58817)
+++ trunk/varia/src/main/org/jboss/tools/ClassVersionInfo.java	2006-12-03 17:26:21 UTC (rev 58818)
@@ -23,6 +23,8 @@
 
 import java.io.ObjectStreamClass;
 import java.io.Serializable;
+import java.net.URL;
+import java.security.CodeSource;
 
 /**
  * Encapsulates a class serialVersionUID and codebase.
@@ -39,12 +41,16 @@
    /** The binary class name */
    private String name;
    private boolean hasExplicitSerialVersionUID;
+   private transient URL location;
 
    public ClassVersionInfo(String name, ClassLoader loader)
       throws ClassNotFoundException
    {
       this.name = name;
       Class c = loader.loadClass(name);
+      CodeSource cs = c.getProtectionDomain().getCodeSource();
+      if( cs != null )
+         location = cs.getLocation();
       if( c.isInterface() == false )
       {
          ObjectStreamClass osc = ObjectStreamClass.lookup(c);
@@ -87,7 +93,27 @@
       tmp.append(hasExplicitSerialVersionUID);
       tmp.append(", name=");
       tmp.append(name);
+      tmp.append(", location=");
+      tmp.append(location);
       tmp.append('}');
       return tmp.toString();
    }
+
+   /**
+    * Usage: ClassVersionInfo class-name
+    * 
+    * Locate the class name on the thread context class loader classpath
+    * and print its version info.
+    *  
+    * @param args [0] = class-name
+    */
+   public static void main(String[] args)
+      throws Exception
+   {
+      if( args.length == 0 )
+         throw new IllegalStateException("Usage: ...ClassVersionInfo class-name");
+      ClassLoader loader = Thread.currentThread().getContextClassLoader();
+      ClassVersionInfo info = new ClassVersionInfo(args[0], loader);
+      System.out.println(info);
+   }
 }



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 13:12:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 13:12:29 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58819 - trunk/system/src/bin
Message-ID: <E1GqvpF-0004QM-6d@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-03 13:12:23 -0500 (Sun, 03 Dec 2006)
New Revision: 58819

Modified:
   trunk/system/src/bin/run.bat
Log:
group the if exist native check

Modified: trunk/system/src/bin/run.bat
===================================================================
--- trunk/system/src/bin/run.bat	2006-12-03 17:26:21 UTC (rev 58818)
+++ trunk/system/src/bin/run.bat	2006-12-03 18:12:23 UTC (rev 58819)
@@ -20,8 +20,10 @@
 REM
 REM Add bin/native to the PATH if present
 REM
-if exist "%JBOSS_HOME%\bin\native" set PATH=%JBOSS_HOME%\bin\native;%PATH%
-if exist "%JBOSS_HOME%\bin\native" set JAVA_OPTS=%JAVA_OPTS% -Djava.library.path=%JBOSS_HOME%\bin\native
+if exist "%JBOSS_HOME%\bin\native" (
+   set PATH=%JBOSS_HOME%\bin\native;%PATH%
+   set JAVA_OPTS=%JAVA_OPTS% -Djava.library.path=%JBOSS_HOME%\bin\native
+)
 
 rem Read all command line arguments
 
@@ -74,9 +76,9 @@
 rem result in including the local directory, which makes error tracking
 rem harder.
 if "%JBOSS_CLASSPATH%" == "" (
-	set JBOSS_CLASSPATH=%JAVAC_JAR%;%RUNJAR%
+   set JBOSS_CLASSPATH=%JAVAC_JAR%;%RUNJAR%
 ) else (
-	set JBOSS_CLASSPATH=%JBOSS_CLASSPATH%;%JAVAC_JAR%;%RUNJAR%
+   set JBOSS_CLASSPATH=%JBOSS_CLASSPATH%;%JAVAC_JAR%;%RUNJAR%
 )
 
 rem Setup JBoss specific properties



From gavin.king at jboss.com  Sun Dec  3 14:28:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 14:28:31 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1Gqx0p-0005WO-0S@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 14:28:30

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  generate required=true
  
  Revision  Changes    Path
  1.12      +42 -14    jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- edit.xhtml.ftl	3 Dec 2006 09:20:00 -0000	1.11
  +++ edit.xhtml.ftl	3 Dec 2006 19:28:30 -0000	1.12
  @@ -34,44 +34,72 @@
   <#if property.value.identifierGeneratorStrategy == "assigned">
                           <h:inputText id="${property.name}"
                               value="${'#'}{${homeName}.instance.${property.name}}" 
  +                               required="true"
                               disabled="${'#'}{${homeName}.managed}"/>
   </#if>
   <#else>
   <#if property.value.typeName == "date">
  -			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			           <h:inputText id="${property.name}" 
  +<#if !property.columnIterator.next().nullable>
  +                              required="true"
  +</#if>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertDateTime type="date" dateStyle="short"/>
   			           </h:inputText>
   <#elseif property.value.typeName == "time">
  -			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			           <h:inputText id="${property.name}" 
  +<#if !property.columnIterator.next().nullable>
  +                              required="true"
  +</#if>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertDateTime type="time"/>
   			           </h:inputText>
   <#elseif property.value.typeName == "timestamp">
  -			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			           <h:inputText id="${property.name}" 
  +<#if !property.columnIterator.next().nullable>
  +                              required="true"
  +</#if>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertDateTime type="both" dateStyle="short"/>
   			           </h:inputText>
   <#elseif property.value.typeName == "big_decimal">
  -			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			           <h:inputText id="${property.name}" 
  +<#if !property.columnIterator.next().nullable>
  +                              required="true"
  +</#if>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertNumber/>
   			           </h:inputText>
   <#elseif property.value.typeName == "big_integer">
  -			           <h:inputText id="${property.name}" value="${'#'}{${homeName}.instance.${property.name}}">
  +			           <h:inputText id="${property.name}" 
  +<#if !property.columnIterator.next().nullable>
  +                              required="true"
  +</#if>
  +			                    value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertNumber integerOnly="true"/>
   			           </h:inputText>
   <#elseif property.value.typeName == "boolean">
   			           <h:selectBooleanCheckbox id="${property.name}"
  +<#if !property.columnIterator.next().nullable>
  +                                          required="true"
  +</#if>
   			               value="${'#'}{${homeName}.instance.${property.name}}"/>
   <#elseif property.value.typeName == "string">
   <#if property.columnIterator.next().length gt 200>
   			           <h:inputTextarea id="${property.name}"
  +<#if !property.columnIterator.next().nullable>
  +                                  required="true"
  +</#if>
   			               value="${'#'}{${homeName}.instance.${property.name}}"/>
   <#else>
                          <h:inputText id="${property.name}" 
  +<#if !property.columnIterator.next().nullable>
  +                              required="true"
  +</#if>
                               size="${property.columnIterator.next().length}"
  +                             maxlength="${property.columnIterator.next().length}"
                               value="${'#'}{${homeName}.instance.${property.name}}"/>
   </#if>
  -<#else>
  -                       <h:inputText id="${property.name}"
  -                            value="${'#'}{${homeName}.instance.${property.name}}"/>
   </#if>
   </#if>
                       </s:decorate>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 15:11:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 15:11:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r58820 -
	trunk/varia/src/main/org/jboss/tools
Message-ID: <E1GqxgR-0006Ed-6b@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-03 15:11:29 -0500 (Sun, 03 Dec 2006)
New Revision: 58820

Modified:
   trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java
Log:
Make the generateJBossSerialVersionUIDReport the default. To run the ri report one must specify -rihome home.

Modified: trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java
===================================================================
--- trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java	2006-12-03 18:12:23 UTC (rev 58819)
+++ trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java	2006-12-03 20:11:29 UTC (rev 58820)
@@ -53,7 +53,8 @@
       throws MalformedURLException
    {
       File[] files = dir.listFiles();
-      for(int n = 0; n < files.length; n ++)
+      int count = files != null ? files.length : 0;
+      for(int n = 0; n < count; n ++)
       {
          File child = files[n];
          // Ignore the server tmp directory
@@ -206,15 +207,15 @@
    {
       if( args.length != 1 )
       {
-         System.err.println("Usage: jboss-home");
+         System.err.println("Usage: jboss-home | -rihome ri-home");
          System.exit(1);
       }
       File distHome = new File(args[0]);
       Map classVersionMap = null;
-      if( distHome.getName().startsWith("jboss") )
+      if( args.length == 2 )
+         classVersionMap = generateRISerialVersionUIDReport(distHome);
+      else
          classVersionMap = generateJBossSerialVersionUIDReport(distHome);
-      else
-         classVersionMap = generateRISerialVersionUIDReport(distHome);
       // Write the map out the object file
       log.info("Total classes with serialVersionUID != 0: "+classVersionMap.size());
       FileOutputStream fos = new FileOutputStream("serialuid.ser");



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 16:13:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 16:13:06 -0500
Subject: [jboss-cvs] JBossAS SVN: r58821 -
	trunk/ejb3/src/main/org/jboss/ejb3/stateless
Message-ID: <E1Gqye2-0007Bs-CF@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-03 16:13:04 -0500 (Sun, 03 Dec 2006)
New Revision: 58821

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/stateless/StatelessRemoteProxy.java
Log:
Fix the serialVersionUID to the previous release value.

Modified: trunk/ejb3/src/main/org/jboss/ejb3/stateless/StatelessRemoteProxy.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/stateless/StatelessRemoteProxy.java	2006-12-03 20:11:29 UTC (rev 58820)
+++ trunk/ejb3/src/main/org/jboss/ejb3/stateless/StatelessRemoteProxy.java	2006-12-03 21:13:04 UTC (rev 58821)
@@ -44,6 +44,7 @@
  */
 public class StatelessRemoteProxy extends org.jboss.ejb3.session.BaseSessionRemoteProxy
 {
+   private static final long serialVersionUID = 2583299153931800023L;
    private static final Logger log = Logger.getLogger(StatelessRemoteProxy.class);
    
    protected InvokerLocator uri;



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 17:41:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 17:41:34 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1694 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/client/delegate messaging/core/plugin
	messaging/core/plugin/contract messaging/core/plugin/postoffice
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1Gr01e-0008Va-St@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 17:41:30 -0500 (Sun, 03 Dec 2006)
New Revision: 1694

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java
Log:
minor renaming, formatting and logging changes

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -38,56 +38,76 @@
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
- *
  */
-public class ClusteredClientConnectionFactoryDelegate extends
-                ClientConnectionFactoryDelegate
+public class ClusteredClientConnectionFactoryDelegate extends ClientConnectionFactoryDelegate
 {
+   // Constants -----------------------------------------------------
+
    private static final long serialVersionUID = 8286850860206289277L;
-   
-   
-   /*
-    * If delegates[i] is the current delegate, then the failover delegate
-    * is given by delegates[failoverIndexes[i]]
-    */   
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   /**
+    * If delegates[i] is the current delegate, then the failover delegate is given by
+    * delegates[failoverIndexes[i]]
+    */
    private ClientConnectionFactoryDelegate[] delegates;
-   
+
    private int[] failoverIndexes;
-      
-   public ClusteredClientConnectionFactoryDelegate(int objectID,
-            String serverLocatorURI, Version serverVersion, boolean clientPing)
+
+   // Constructors --------------------------------------------------
+
+   public ClusteredClientConnectionFactoryDelegate(int objectID, String serverLocatorURI,
+                                                   Version serverVersion, boolean clientPing)
    {
       super(objectID, serverLocatorURI, serverVersion, clientPing);
    }
-   
+
+   // DelegateSupport overrides -------------------------------------
+
    public void init()
    {
       super.init();
-      
-      for (int i=0; i < delegates.length; i++)
+
+      for (int i = 0; i < delegates.length; i++)
       {
          delegates[i].init();
       }
-      
-      //We add this to the meta data so the failOver aspect can get access to it
-      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES,
+
+      // We add this to the meta data so the failOver aspect can get access to it
+      getMetaData().addMetaData(MetaDataConstants.JMS,
+                                MetaDataConstants.CF_DELEGATES,
                                 delegates, PayloadKey.TRANSIENT);
-      
-      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES,
+
+      getMetaData().addMetaData(MetaDataConstants.JMS,
+                                MetaDataConstants.CF_FAILOVER_INDEXES,
                                 failoverIndexes, PayloadKey.TRANSIENT);
    }
-   
-   //Only be used in testing
+
+   // Public --------------------------------------------------------
+
+
+   public void setFailoverDelegates(ClientConnectionFactoryDelegate[] delegates,
+                                    int[] failoverIndexes)
+   {
+      this.delegates = delegates;
+      this.failoverIndexes = failoverIndexes;
+   }
+
+   // Only be used in testing
    public ClientConnectionFactoryDelegate[] getDelegates()
    {
       return delegates;
    }
-   
-   public void setFailoverDelegates(ClientConnectionFactoryDelegate[] delegates, int[] failoverIndexes)
-   {
-      this.delegates = delegates;
-      
-      this.failoverIndexes = failoverIndexes;
-   }
-   
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -240,16 +240,16 @@
          FilterFactory ff = new SelectorFactory();
          
          FailoverMapper mapper = new DefaultFailoverMapper();
-            
+
          postOffice =  new DefaultClusteredPostOffice(ds, tm, sqlProperties, createTablesOnStartup,
-                                               nodeId, officeName, ms,
-                                               pm, tr, ff, pool, 
-                                               groupName,
-                                               syncChannelConfig, asyncChannelConfig,
-                                               stateTimeout, castTimeout,
-                                               pullPolicy, rf,
-                                               mapper,
-                                               statsSendPeriod);
+                                                      nodeId, officeName, ms,
+                                                      pm, tr, ff, pool,
+                                                      groupName,
+                                                      syncChannelConfig, asyncChannelConfig,
+                                                      stateTimeout, castTimeout,
+                                                      pullPolicy, rf,
+                                                      mapper,
+                                                      statsSendPeriod);
          
          postOffice.start();
          

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -45,7 +45,10 @@
    void putReplicant(Serializable key, Serializable replicant) throws Exception;
    
    boolean removeReplicant(Serializable key) throws Exception;
-   
+
+   /**
+    * @return an empty map if no replicants are found for 'key', but never null.
+    */
    Map getReplicants(Serializable key) throws Exception;
    
    void registerListener(ReplicationListener listener);
@@ -53,9 +56,10 @@
    void unregisterListener(ReplicationListener listener);
    
    /**
-    * Gets the current failover node id for the specified node id
-    * @param nodeId The node to get the failover node id for
-    * @return the failover node id
+    * Gets the current failover node id for the specified node id.
+    * @param nodeId The node to get the failover node id for.
+    * @return the failover node id. If there is no failover node (one-node cluster), the method
+    *         returns the original nodeID. 
     */
    int getFailoverNodeForNode(int nodeId);   
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -122,13 +122,13 @@
    
    public void start() throws Exception
    {
-      if (trace) { log.trace(this + " starting"); }
+      log.debug(this + " starting");
       
       super.start();
       
       loadBindings();
       
-      if (trace) { log.trace(this + " started"); }
+      log.debug(this + " started");
    }
 
    public void stop() throws Exception

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -137,13 +137,13 @@
    
    private Set leftSet;
    
-   private Element syncChannelConfigE;
+   private Element syncChannelConfigElement;
    
-   private Element asyncChannelConfigE;
+   private Element asyncChannelConfigElement;
    
-   private String syncChannelConfigS;
+   private String syncChannelConfig;
    
-   private String asyncChannelConfigS;
+   private String asyncChannelConfig;
    
    private long stateTimeout;
    
@@ -186,76 +186,87 @@
    /*
     * Constructor using Element for configuration
     */
-   public DefaultClusteredPostOffice(DataSource ds, TransactionManager tm, Properties sqlProperties,
-            boolean createTablesOnStartup,
-            int nodeId, String officeName, MessageStore ms,
-            PersistenceManager pm,
-            TransactionRepository tr,
-            FilterFactory filterFactory,
-            QueuedExecutorPool pool,                              
-            String groupName,
-            Element syncChannelConfig,
-            Element asyncChannelConfig,
-            long stateTimeout, long castTimeout,
-            MessagePullPolicy redistributionPolicy,
-            ClusterRouterFactory rf,
-            FailoverMapper failoverMapper,
-            long statsSendPeriod) throws Exception
-   {            
+   public DefaultClusteredPostOffice(DataSource ds,
+                                     TransactionManager tm,
+                                     Properties sqlProperties,
+                                     boolean createTablesOnStartup,
+                                     int nodeId,
+                                     String officeName,
+                                     MessageStore ms,
+                                     PersistenceManager pm,
+                                     TransactionRepository tr,
+                                     FilterFactory filterFactory,
+                                     QueuedExecutorPool pool,
+                                     String groupName,
+                                     Element syncChannelConfig,
+                                     Element asyncChannelConfig,
+                                     long stateTimeout, long castTimeout,
+                                     MessagePullPolicy redistributionPolicy,
+                                     ClusterRouterFactory rf,
+                                     FailoverMapper failoverMapper,
+                                     long statsSendPeriod)
+      throws Exception
+   {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
            pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
            rf, failoverMapper, statsSendPeriod);
       
-      this.syncChannelConfigE = syncChannelConfig;      
-      this.asyncChannelConfigE = asyncChannelConfig;
+      this.syncChannelConfigElement = syncChannelConfig;
+      this.asyncChannelConfigElement = asyncChannelConfig;
    }
      
    /*
     * Constructor using String for configuration
     */
-   public DefaultClusteredPostOffice(DataSource ds, TransactionManager tm, Properties sqlProperties,
-                              boolean createTablesOnStartup,
-                              int nodeId, String officeName, MessageStore ms,
-                              PersistenceManager pm,
-                              TransactionRepository tr,
-                              FilterFactory filterFactory,
-                              QueuedExecutorPool pool,                              
-                              String groupName,
-                              String syncChannelConfig,
-                              String asyncChannelConfig,
-                              long stateTimeout, long castTimeout,
-                              MessagePullPolicy redistributionPolicy,                      
-                              ClusterRouterFactory rf,
-                              FailoverMapper failoverMapper,
-                              long statsSendPeriod) throws Exception
+   public DefaultClusteredPostOffice(DataSource ds,
+                                     TransactionManager tm,
+                                     Properties sqlProperties,
+                                     boolean createTablesOnStartup,
+                                     int nodeId,
+                                     String officeName,
+                                     MessageStore ms,
+                                     PersistenceManager pm,
+                                     TransactionRepository tr,
+                                     FilterFactory filterFactory,
+                                     QueuedExecutorPool pool,
+                                     String groupName,
+                                     String syncChannelConfig,
+                                     String asyncChannelConfig,
+                                     long stateTimeout, long castTimeout,
+                                     MessagePullPolicy redistributionPolicy,
+                                     ClusterRouterFactory rf,
+                                     FailoverMapper failoverMapper,
+                                     long statsSendPeriod) throws Exception
    {            
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
            pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
            rf, failoverMapper, statsSendPeriod);
 
-      this.syncChannelConfigS = syncChannelConfig;      
-      this.asyncChannelConfigS = asyncChannelConfig;     
+      this.syncChannelConfig = syncChannelConfig;
+      this.asyncChannelConfig = asyncChannelConfig;
    }
-   
-   private DefaultClusteredPostOffice(DataSource ds, TransactionManager tm, Properties sqlProperties,
-                               boolean createTablesOnStartup,
-                               int nodeId, String officeName, MessageStore ms,
-                               PersistenceManager pm,                               
-                               TransactionRepository tr,
-                               FilterFactory filterFactory,
-                               QueuedExecutorPool pool,
-                               String groupName,
-                               long stateTimeout, long castTimeout,                             
-                               MessagePullPolicy redistributionPolicy,                               
-                               ClusterRouterFactory rf,
-                               FailoverMapper failoverMapper,
-                               long statsSendPeriod)
+
+   private DefaultClusteredPostOffice(DataSource ds,
+                                      TransactionManager tm,
+                                      Properties sqlProperties,
+                                      boolean createTablesOnStartup,
+                                      int nodeId,
+                                      String officeName,
+                                      MessageStore ms,
+                                      PersistenceManager pm,
+                                      TransactionRepository tr,
+                                      FilterFactory filterFactory,
+                                      QueuedExecutorPool pool,
+                                      String groupName,
+                                      long stateTimeout, long castTimeout,
+                                      MessagePullPolicy redistributionPolicy,
+                                      ClusterRouterFactory rf,
+                                      FailoverMapper failoverMapper,
+                                      long statsSendPeriod)
    {
-      super (ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms, pm, tr, filterFactory,
-             pool);
+      super (ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms, pm, tr,
+             filterFactory, pool);
                    
-      this.pm = pm;
-      
       this.groupName = groupName;
       
       this.stateTimeout = stateTimeout;
@@ -287,18 +298,18 @@
          log.warn("Attempt to start() but " + this + " is already started");
       }
       
-      if (syncChannelConfigE != null)
+      if (syncChannelConfigElement != null)
       {        
-         this.syncChannel = new JChannel(syncChannelConfigE);
-         this.asyncChannel = new JChannel(asyncChannelConfigE); 
+         this.syncChannel = new JChannel(syncChannelConfigElement);
+         this.asyncChannel = new JChannel(asyncChannelConfigElement);
       }
       else
       {
-         this.syncChannel = new JChannel(syncChannelConfigS);
-         this.asyncChannel = new JChannel(asyncChannelConfigS); 
+         this.syncChannel = new JChannel(syncChannelConfig);
+         this.asyncChannel = new JChannel(asyncChannelConfig);
       }
       
-      //We don't want to receive local messages on any of the channels
+      // We don't want to receive local messages on any of the channels
       syncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
       
       asyncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
@@ -309,8 +320,10 @@
       
       this.controlMembershipListener = new ControlMembershipListener();
       
-      this.controlMessageDispatcher = new MessageDispatcher(syncChannel, controlMessageListener,
-                                                            controlMembershipListener, requestHandler, true);      
+      this.controlMessageDispatcher =
+         new MessageDispatcher(syncChannel, controlMessageListener,
+                               controlMembershipListener, requestHandler, true);
+
       this.dataReceiver = new DataReceiver();
       
       asyncChannel.setReceiver(dataReceiver);    
@@ -596,7 +609,7 @@
       
       if (failoverNode == null)
       {
-         throw new IllegalArgumentException("Cannot find failover node for node " + nodeId);
+         return nodeId;
       }
       
       return failoverNode.intValue();
@@ -612,7 +625,7 @@
       {
          Map m = (Map)replicatedData.get(key);
          
-         return m == null ? null : Collections.unmodifiableMap(m);
+         return m == null ? Collections.EMPTY_MAP : Collections.unmodifiableMap(m);
       }
       finally
       {
@@ -622,16 +635,16 @@
 
    public void putReplicant(Serializable key, Serializable replicant) throws Exception
    {
-      putReplicantFromCluster(this.nodeId, key, replicant);
+      putReplicantLocally(nodeId, key, replicant);
       
-      PutReplicantRequest request = new PutReplicantRequest(this.nodeId, key, replicant);
+      PutReplicantRequest request = new PutReplicantRequest(nodeId, key, replicant);
       
       syncSendRequest(request);
    }
    
    public boolean removeReplicant(Serializable key) throws Exception
    {
-      if (removeReplicantFromCluster(this.nodeId, key))
+      if (removeReplicantLocally(this.nodeId, key))
       {      
          RemoveReplicantRequest request = new RemoveReplicantRequest(this.nodeId, key);
          
@@ -679,8 +692,12 @@
          lock.writeLock().release();
       }      
    }
-   
-   public void putReplicantFromCluster(int nodeId, Serializable key, Serializable replicant) throws Exception
+
+   /**
+    * @param originatorNodeID - the ID of the node that initiated the modification.
+    */
+   public void putReplicantLocally(int originatorNodeID, Serializable key, Serializable replicant)
+      throws Exception
    {
       lock.writeLock().acquire();
       
@@ -697,15 +714,18 @@
          
          m.put(new Integer(nodeId), replicant); 
          
-         notifyListeners(key, m);         
+         notifyListeners(key, m);
       }
       finally
       {
          lock.writeLock().release();
       }
    }
-   
-   public boolean removeReplicantFromCluster(int nodeId, Serializable key) throws Exception
+
+   /**
+    * @param originatorNodeID - the ID of the node that initiated the modification.
+    */
+   public boolean removeReplicantLocally(int originatorNodeID, Serializable key) throws Exception
    {
       lock.writeLock().acquire();
       
@@ -730,7 +750,7 @@
             replicatedData.remove(key);
          }
          
-         notifyListeners(key, m);         
+         notifyListeners(key, m);
          
          return true;
       }
@@ -1658,7 +1678,7 @@
    
    protected void loadBindings() throws Exception
    {
-      if (trace) { log.trace(this.nodeId + " loading bindings"); }
+      log.debug(this.nodeId + " loading bindings");
       
       boolean isState = syncChannel.getState(null, stateTimeout);
       
@@ -1728,18 +1748,17 @@
    }
    
    /*
-    * Removes all non durable binding data, and any local replicant data for the specified
-    * node
+    * Removes all non durable binding data, and any local replicant data for the specified node.
     */
-   private void removeDataForNode(Integer parameterNodeId) throws Exception
+   private void removeDataForNode(Integer nodeID) throws Exception
    {
-      log.info("Node " + parameterNodeId + " requested to leave cluster");
+      log.info("Node " + nodeID + " requested to leave cluster");
       
       lock.writeLock().acquire();
 
       try
       {          
-         Map nameMap = (Map)nameMaps.get(parameterNodeId);
+         Map nameMap = (Map)nameMaps.get(nodeID);
 
          if (nameMap != null)
          {
@@ -1765,30 +1784,26 @@
             {
                Binding binding = (Binding)iter.next();
                
-               removeBinding(parameterNodeId.intValue(), binding.getQueue().getName());
+               removeBinding(nodeID.intValue(), binding.getQueue().getName());
             }
          }
          
-         //We need to remove any replicant data for the node
-         //this includes the node-address info
-         Iterator iter = replicatedData.entrySet().iterator();
-         
-         while (iter.hasNext())
+         // We need to remove any replicant data for the node. This includes the node-address info.
+         for(Iterator i = replicatedData.entrySet().iterator(); i.hasNext(); )
          {
-            Map.Entry entry = (Map.Entry)iter.next();
+            Map.Entry entry = (Map.Entry)i.next();
             
             String key = (String)entry.getKey();
-            
             Map replicants = (Map)entry.getValue();
             
-            replicants.remove(parameterNodeId);
+            replicants.remove(nodeID);
             
             if (replicants.isEmpty())
             {
-               iter.remove();
+               i.remove();
             }     
             
-            //Need to trigger listeners
+            // Need to trigger listeners
             notifyListeners(key, replicants);
          }                  
       }
@@ -1800,12 +1815,9 @@
    
    private void notifyListeners(Serializable key, Map replicants)
    {
-      Iterator iter = replicationListeners.iterator();
-      
-      while (iter.hasNext())
+      for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
       {
-         ReplicationListener listener = (ReplicationListener)iter.next();
-         
+         ReplicationListener listener = (ReplicationListener)i.next();
          listener.onReplicationChange(key, replicants);
       }
    } 
@@ -1815,17 +1827,15 @@
     */
    private void syncSendRequest(ClusterRequest request) throws Exception
    {
-      if (trace) { log.info(this.nodeId + " sending synch request to group, request: " + request); }
+      if (trace) { log.trace(this.nodeId + " sending synch request to group, request: " + request); }
 
-       System.out.println("***************Request Sent **************");
-
       byte[] bytes = writeRequest(request);
 
       Message message = new Message(null, null, bytes);
 
       controlMessageDispatcher.castMessage(null, message, GroupRequest.GET_ALL, castTimeout);
 
-      if (trace) { log.info(this.nodeId + " sent and executed ok"); }
+      if (trace) { log.trace(this.nodeId + " sent and executed ok"); }
    }
    
 
@@ -1835,7 +1845,7 @@
       lock.readLock().acquire();
       try
       { 
-         Map map = this.getReplicants(ADDRESS_INFO_KEY);
+         Map map = getReplicants(ADDRESS_INFO_KEY);
          
          if (map == null)
          {
@@ -2049,25 +2059,29 @@
    }
    
    /*
-    * Given a JGroups view, generate a map of node to failover node
-    * The mapping is determined by a pluggable policy
+    * Given a JGroups view, generate a map of node to failover node.
+    * The mapping is determined by a pluggable policy.
     */
    private void generateFailoverMap(View view) throws Exception
    {
       List nodes = new ArrayList();
       
-      Iterator iter = view.getMembers().iterator();
-      
-      while (iter.hasNext())
+      for (Iterator i = view.getMembers().iterator(); i.hasNext(); )
       {
-         Address address = (Address)iter.next();
+         Address address = (Address)i.next();
+
+         // Ignore own address, a node can't be its own failover node
+         if (syncChannel.getLocalAddress().equals(address))
+         {
+            continue;
+         }
+
+         // Convert to node id
+         // TODO this should be optimised - currently the implementation of the lookup
+         // is a bit tortuous
          
-         //Convert to node id
-         //TODO this should be optimised - currently the implementation of the lookup
-         //is a bit tortuous
+         Integer n = getNodeIdForSyncAddress(address);
          
-         Integer n = this.getNodeIdForSyncAddress(address);
-         
          if (n == null)
          {
             throw new IllegalStateException("Cannot find node id for address: " + address);
@@ -2078,23 +2092,75 @@
             
       List failoverNodes = failoverMapper.generateMapping(nodes);
       
-      //Now put this in the map of node -> failover node
+      // Now put this in the map of node -> failover node
       
       failoverMap.clear();
-      
-      iter = nodes.iterator();
+
+      Iterator iter = nodes.iterator();
       Iterator iter2 = failoverNodes.iterator();
-      
+
       while (iter.hasNext())
       {
          Integer node = (Integer)iter.next();
-         
+
          Integer failoverNode = (Integer)iter2.next();
-         
+
          failoverMap.put(node, failoverNode);
-      }            
+      }
    }
-   
+
+   /*
+    * A new node has joined the group
+    */
+   private void nodeJoined(Address address) throws Exception
+   {
+      // We need to regenerate the failover map
+
+      generateFailoverMap(currentView);
+   }
+
+   /*
+    * A node has left the group
+    */
+   private void nodeLeft(Address address) throws Throwable
+   {
+      Integer nodeId = getNodeIdForSyncAddress(address);
+
+      if (nodeId != null)
+      {
+         throw new IllegalStateException("Cannot find node id for address " + address);
+      }
+
+      boolean crashed = !this.leaveMessageReceived(nodeId);
+
+      if (trace) { log.trace("Node " + address + " id: " + nodeId +" has left the group, crashed = " + crashed); }
+
+      //Cleanup any hanging transactions - we do this irrespective of whether we crashed
+      check(nodeId);
+
+      //Need to evaluate this before we regenerate the failover map
+      boolean isFailover = isFailoverNodeForNode(nodeId.intValue());
+
+      //Now we recalculate the failover mapping - this needs to be done before removeDataForNode is called
+      //since that may cause connection factories to be rebound
+      generateFailoverMap(currentView);
+
+      //Remove any replicant data and non durable bindings for the node - again we need to do this
+      //irrespective of whether we crashed
+      //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
+      removeDataForNode(nodeId);
+
+      if (crashed && isFailover)
+      {
+         //The node crashed and we are the failover node
+         //so let's perform failover
+
+         //TODO server side valve
+
+         failOver(nodeId.intValue());
+      }
+   }
+
    // Inner classes -------------------------------------------------------------------
     
    /*
@@ -2171,58 +2237,6 @@
    }
    
    /*
-    * A new node has joined the group
-    */
-   private void nodeJoined(Address address) throws Exception
-   {
-      //We need to regenerate the failover map
-      
-      generateFailoverMap(currentView);     
-   }
-   
-   /*
-    * A node has left the group
-    */
-   private void nodeLeft(Address address) throws Throwable
-   {
-      Integer nodeId = getNodeIdForSyncAddress(address);
-      
-      if (nodeId != null)
-      {
-         throw new IllegalStateException("Cannot find node id for address " + address);
-      }
-                  
-      boolean crashed = !this.leaveMessageReceived(nodeId);
-                        
-      if (trace) { log.trace("Node " + address + " id: " + nodeId +" has left the group, crashed = " + crashed); }
-            
-      //Cleanup any hanging transactions - we do this irrespective of whether we crashed      
-      check(nodeId);
-      
-      //Need to evaluate this before we regenerate the failover map
-      boolean isFailover = isFailoverNodeForNode(nodeId.intValue());
-      
-      //Now we recalculate the failover mapping - this needs to be done before removeDataForNode is called
-      //since that may cause connection factories to be rebound
-      generateFailoverMap(currentView);
-      
-      //Remove any replicant data and non durable bindings for the node - again we need to do this
-      //irrespective of whether we crashed
-      //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
-      removeDataForNode(nodeId);
-      
-      if (crashed && isFailover)
-      {
-         //The node crashed and we are the failover node
-         //so let's perform failover
-         
-         //TODO server side valve
-         
-         failOver(nodeId.intValue());
-      }
-   }
-      
-   /*
     * We use this class so we notice when members leave the group
     */
    private class ControlMembershipListener implements MembershipListener
@@ -2241,7 +2255,7 @@
       {
          if (trace) { log.trace(nodeId + " Got new view, size=" + view.size()); }
 
-         //JGroups will make sure this method is never called by more than one thread concurrently
+         // JGroups will make sure this method is never called by more than one thread concurrently
          
          View oldView = currentView;
          
@@ -2359,9 +2373,7 @@
             
             ClusterRequest request = readRequest(bytes);
             
-            Object result = request.execute(DefaultClusteredPostOffice.this);
-            
-            return result;
+            return request.execute(DefaultClusteredPostOffice.this);
          }
          catch (Throwable e)
          {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -52,9 +52,9 @@
  
    void handleNodeLeft(int nodeId) throws Exception;
    
-   void putReplicantFromCluster(int nodeId, Serializable key, Serializable replicant) throws Exception;
+   void putReplicantLocally(int nodeId, Serializable key, Serializable replicant) throws Exception;
    
-   boolean removeReplicantFromCluster(int nodeId, Serializable key) throws Exception;
+   boolean removeReplicantLocally(int nodeId, Serializable key) throws Exception;
    
    void routeFromCluster(Message message, String routingKey, Map queueNameNodeIdMap) throws Exception;
    

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -40,54 +40,74 @@
  */
 class PutReplicantRequest extends ClusterRequest
 {
+   // Constants -----------------------------------------------------
+
    static final int TYPE = 12;
 
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private int nodeId;
-   
    private Serializable key;
-   
    private Serializable replicant;
-   
+
+   // Constructors --------------------------------------------------
+
    PutReplicantRequest()
-   {      
+   {
    }
-   
+
    PutReplicantRequest(int nodeId, Serializable key, Serializable replicant)
    {
-      this.nodeId = nodeId;  
-      
+      this.nodeId = nodeId;
+
       this.key = key;
-      
+
       this.replicant = replicant;
    }
-   
-   Object execute(PostOfficeInternal office) throws Exception
-   {
-      office.putReplicantFromCluster(nodeId, key, replicant);
-      
-      return null;
-   }
-   
-   byte getType()
-   {
-      return TYPE;
-   }
 
+   // Streamable implementation -------------------------------------
+
    public void read(DataInputStream in) throws Exception
    {
       nodeId = in.readInt();
-      
+
       key = (Serializable)StreamUtils.readObject(in, true);
-      
+
       replicant = (Serializable)StreamUtils.readObject(in, true);
    }
 
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeInt(nodeId);   
-      
+      out.writeInt(nodeId);
+
       StreamUtils.writeObject(out, key, true, true);
-      
+
       StreamUtils.writeObject(out, replicant, true, true);
    }
+
+   // ClusterRequest overrides --------------------------------------
+
+   Object execute(PostOfficeInternal office) throws Exception
+   {
+      office.putReplicantLocally(nodeId, key, replicant);
+      return null;
+   }
+
+   byte getType()
+   {
+      return TYPE;
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java	2006-12-03 08:36:09 UTC (rev 1693)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java	2006-12-03 22:41:30 UTC (rev 1694)
@@ -48,7 +48,7 @@
    
    Object execute(PostOfficeInternal office) throws Exception
    {
-      office.removeReplicantFromCluster(nodeId, key);
+      office.removeReplicantLocally(nodeId, key);
       
       return null;
    }



From c44 at fullmailmarket.com  Sun Dec  3 19:37:33 2006
From: c44 at fullmailmarket.com (Decopaisaje)
Date: Sun, 3 Dec 2006 21:37:33 -0300
Subject: [jboss-cvs] Cansada/o que el pasto se le seque o se le mueran las
	flores?
Message-ID: <200612040037.kB40bb5X001467@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061203/576956d4/attachment.html 

From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:50 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1Gr2IE-0002U0-7x@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:50

  Modified:    src/main/org/jboss/seam  Component.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.215     +11 -11    jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.214
  retrieving revision 1.215
  diff -u -b -r1.214 -r1.215
  --- Component.java	30 Nov 2006 02:09:10 -0000	1.214
  +++ Component.java	4 Dec 2006 01:06:50 -0000	1.215
  @@ -75,7 +75,7 @@
   import org.jboss.seam.annotations.Transactional;
   import org.jboss.seam.annotations.Unwrap;
   import org.jboss.seam.annotations.datamodel.DataModel;
  -import org.jboss.seam.annotations.security.Secure;
  +import org.jboss.seam.annotations.security.Restrict;
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Events;
  @@ -121,7 +121,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.214 $
  + * @version $Revision: 1.215 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -777,7 +777,7 @@
         {
            addInterceptor( new Interceptor( new ManagedEntityIdentityInterceptor(), this ) );
         }
  -      if ( beanClassHasAnnotation(Secure.class) )
  +      if ( beanClassHasAnnotation(Restrict.class) )
         {
           addInterceptor( new Interceptor( new SecurityInterceptor(), this ) );
         }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:50 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/annotations/security
	...
Message-ID: <E1Gr2IE-0002UD-D6@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:50

  Modified:    src/main/org/jboss/seam/annotations/security      
                        Permission.java
  Added:       src/main/org/jboss/seam/annotations/security      
                        Permissions.java Restrict.java
  Removed:     src/main/org/jboss/seam/annotations/security      
                        AclProvider.java DefinePermissions.java Secure.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.2       +3 -3      jboss-seam/src/main/org/jboss/seam/annotations/security/Permission.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Permission.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/security/Permission.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Permission.java	9 Nov 2006 03:26:15 -0000	1.1
  +++ Permission.java	4 Dec 2006 01:06:50 -0000	1.2
  @@ -2,12 +2,12 @@
   
   import static java.lang.annotation.ElementType.ANNOTATION_TYPE;
   import static java.lang.annotation.RetentionPolicy.RUNTIME;
  +
   import java.lang.annotation.Retention;
   import java.lang.annotation.Target;
   
   /**
  - * Used in conjunction with @Secure to control access to a Seam component or
  - * component method.
  + * Used to define a specific permission for a Seam component
    *
    * @author Shane Bryzak
    */
  @@ -15,6 +15,6 @@
   @Retention(RUNTIME)
   public @interface Permission
   {
  -  String name();
     String action();
  +  String expr();
   }
  
  
  
  1.1      date: 2006/12/04 01:06:50;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/annotations/security/Permissions.java
  
  Index: Permissions.java
  ===================================================================
  package org.jboss.seam.annotations.security;
  
  /**
   *
   *
   * @author Shane Bryzak
   */
  public @interface Permissions
  {
    Permission[] value() default {};
  }
  
  
  
  1.1      date: 2006/12/04 01:06:50;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/annotations/security/Restrict.java
  
  Index: Restrict.java
  ===================================================================
  package org.jboss.seam.annotations.security;
  
  import static java.lang.annotation.ElementType.METHOD;
  import static java.lang.annotation.ElementType.TYPE;
  import static java.lang.annotation.RetentionPolicy.RUNTIME;
  
  import java.lang.annotation.Documented;
  import java.lang.annotation.Retention;
  import java.lang.annotation.Target;
  
  /**
   * Used to restrict access to a Seam component or component method.
   *
   * @author Shane Bryzak
   */
  @Target({TYPE,METHOD})
  @Documented
  @Retention(RUNTIME)
  public @interface Restrict {
    String value() default "";
  }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:50 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1Gr2IE-0002UK-Ht@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:50

  Modified:    src/main/org/jboss/seam/interceptors 
                        SecurityInterceptor.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.12      +15 -81    jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SecurityInterceptor.java	9 Nov 2006 03:26:15 -0000	1.11
  +++ SecurityInterceptor.java	4 Dec 2006 01:06:50 -0000	1.12
  @@ -6,13 +6,9 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
  -import org.jboss.seam.annotations.security.Permission;
  -import org.jboss.seam.annotations.security.Secure;
  -import org.jboss.seam.core.FacesMessages;
  +import org.jboss.seam.annotations.security.Restrict;
   import org.jboss.seam.intercept.InvocationContext;
  -import org.jboss.seam.security.Authentication;
  -import org.jboss.seam.security.AuthenticationException;
  -import org.jboss.seam.security.SeamSecurityManager;
  +import org.jboss.seam.security.Identity;
   
   /**
    * Provides authorization services for component invocations.
  @@ -30,86 +26,24 @@
     public Object checkSecurity(InvocationContext invocation)
         throws Exception
     {
  -    Secure sec = null;
  +    Restrict r = null;
   
  -    try
  -    {
         Method method = invocation.getMethod();
   
  -      if (method.isAnnotationPresent(Secure.class))
  -        sec = method.getAnnotation(Secure.class);
  -      else if (method.getDeclaringClass().isAnnotationPresent(Secure.class))
  -        sec = method.getDeclaringClass().getAnnotation(Secure.class);
  -
  -      if (sec != null)
  -      {
  -        boolean redirectToLogin = false;
  -        Authentication auth = null;
  +    if (method.isAnnotationPresent(Restrict.class))
  +      r = method.getAnnotation(Restrict.class);
  +    else if (method.getDeclaringClass().isAnnotationPresent(Restrict.class))
  +      r = method.getDeclaringClass().getAnnotation(Restrict.class);
  +
  +    if (r != null)
  +    {
  +      Identity identity = Identity.instance();
  +      if (!identity.isValid())
  +        throw new SecurityException("Invalid identity");
   
  -        try
  -        {
  -          auth = Authentication.instance();
  -          if (!auth.isValid())
  -            redirectToLogin = true;
  -        }
  -        catch (AuthenticationException ex)
  -        {
  -          if (String.class.equals(method.getReturnType()))
  -            redirectToLogin = true;
  -          else
  -            throw ex;
  -        }
  -
  -        if (redirectToLogin)
  -        {
  -          return SeamSecurityManager.instance().getLoginAction();
  +      /** todo perform restriction check here */
           }
   
  -        // If roles() are specified check them first
  -        if (sec.roles().length > 0)
  -        {
  -          for (String role : sec.roles())
  -          {
  -            if (auth.isUserInRole(role))
                 return invocation.proceed();
             }
  -        }
  -
  -        // No roles match, check permissions
  -        try
  -        {
  -          if (sec.permissions().length > 0)
  -          {
  -            for (Permission p : sec.permissions())
  -            {
  -              SeamSecurityManager.instance().checkPermission(p.name(), p.action());
  -            }
  -          }
  -        }
  -        catch (SecurityException ex)
  -        {
  -          log.info(ex.getMessage());
  -          FacesMessages.instance().add(ex.getMessage());
  -          // Fall through to error page
  -        }
  -
  -        return forwardToErrorPage(sec);
  -      }
  -
  -      return invocation.proceed();
  -    }
  -    catch (SecurityException ex)
  -    {
  -      return forwardToErrorPage(sec);
  -    }
  -  }
  -
  -  private String forwardToErrorPage(Secure sec)
  -  {
  -    // Authorization has failed.. redirect the user to an error page
  -    if (sec != null && sec.onfail() != null && !"".equals(sec.onfail()))
  -      return sec.onfail();
  -
  -    return SeamSecurityManager.instance().getSecurityErrorAction();
  -  }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:50 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/mock   ...
Message-ID: <E1Gr2IE-0002UU-LW@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:50

  Modified:    src/main/org/jboss/seam/mock   MockAclPermission.java
                        MockSecureEntity.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/src/main/org/jboss/seam/mock/MockAclPermission.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockAclPermission.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockAclPermission.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MockAclPermission.java	13 Nov 2006 00:05:58 -0000	1.1
  +++ MockAclPermission.java	4 Dec 2006 01:06:50 -0000	1.2
  @@ -5,7 +5,7 @@
   import javax.persistence.Id;
   import javax.persistence.ManyToOne;
   
  -import org.jboss.seam.security.acl.AclProvider.RecipientType;
  +import org.jboss.seam.security.acl.AclManager.RecipientType;
   
   /**
    * Defines permissions for an object
  
  
  
  1.3       +7 -9      jboss-seam/src/main/org/jboss/seam/mock/MockSecureEntity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockSecureEntity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockSecureEntity.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MockSecureEntity.java	18 Nov 2006 00:38:23 -0000	1.2
  +++ MockSecureEntity.java	4 Dec 2006 01:06:50 -0000	1.3
  @@ -6,8 +6,8 @@
   
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.annotations.security.AclProvider;
  -import org.jboss.seam.annotations.security.DefinePermissions;
  +import org.jboss.seam.annotations.security.Permission;
  +import org.jboss.seam.annotations.security.Permissions;
   
   /**
    * Used by security unit tests
  @@ -16,13 +16,11 @@
    */
   @Name("mockSecureEntity")
   @Install(false)
  - at DefinePermissions(
  -    permissions = {
  -  @AclProvider(action = "read", provider = "persistentAclProvider", mask = 0x01),
  -  @AclProvider(action = "delete", provider = "persistentAclProvider", mask = 0x02),
  -  @AclProvider(action = "special", provider = "persistentAclProvider", mask = 0x04)
  -  }
  -)
  + at Permissions({
  +  @Permission(action = "read", expr = "#{aclPermissionChecker.checkPermission}"),
  +  @Permission(action = "delete", expr = "#{aclPermissionChecker.checkPermission}"),
  +  @Permission(action = "special", expr = "#{aclPermissionChecker.checkPermission}")
  +})
   @Entity
   public class MockSecureEntity implements Serializable
   {
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:50 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security    ...
Message-ID: <E1Gr2IE-0002Uh-QX@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:50

  Modified:    src/main/org/jboss/seam/security    PermissionHandler.java
                        SeamSecurityManager.java
  Added:       src/main/org/jboss/seam/security    Identity.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.3       +30 -31    jboss-seam/src/main/org/jboss/seam/security/PermissionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PermissionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/PermissionHandler.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PermissionHandler.java	15 Nov 2006 21:55:00 -0000	1.2
  +++ PermissionHandler.java	4 Dec 2006 01:06:50 -0000	1.3
  @@ -8,13 +8,12 @@
   
   import org.jboss.seam.Component;
   import org.jboss.seam.Seam;
  -import org.jboss.seam.annotations.security.DefinePermissions;
  -import org.jboss.seam.security.acl.AclProvider;
  +//import org.jboss.seam.annotations.security.DefinePermissions;
  +import org.jboss.seam.security.acl.AclManager;
   
   /**
    * 
    * @author shane_bryzak
  - *
    */
   public class PermissionHandler 
   {
  @@ -24,31 +23,31 @@
     
     public PermissionHandler(Class cls)
     {
  -    DefinePermissions def = null;
  +//    DefinePermissions def = null;
      
  -    if (cls.isAnnotationPresent(DefinePermissions.class))
  -      def = (DefinePermissions) cls.getAnnotation(DefinePermissions.class);
  +//    if (cls.isAnnotationPresent(DefinePermissions.class))
  +//      def = (DefinePermissions) cls.getAnnotation(DefinePermissions.class);
   
       // Determine the permission name.  If it is specified in a @DefinePermissions
       // annotation, use that one, otherwise use the component name.  If the object
       // is not a Seam component, use its fully qualified class name.
  -    if (def != null && !"".equals(def.name()))
  -    {
  -      permissionName = ((DefinePermissions) cls.getAnnotation(DefinePermissions.class)).name();
  -    }
  -    else
  -      permissionName = Seam.getComponentName(cls);
  +//    if (def != null && !"".equals(def.name()))
  +//    {
  +//      permissionName = ((DefinePermissions) cls.getAnnotation(DefinePermissions.class)).name();
  +//    }
  +//    else
  +//      permissionName = Seam.getComponentName(cls);
   
       if (permissionName == null)
         permissionName = cls.getName();
   
  -    if (def != null)
  -    {
  -      for (org.jboss.seam.annotations.security.AclProvider p : def.permissions())
  -      {
  -        providers.put(p.action(), p.provider());        
  -      }
  -    }
  +//    if (def != null)
  +//    {
  +//      for (org.jboss.seam.annotations.security.AclProvider p : def.permissions())
  +//      {
  +//        providers.put(p.action(), p.provider());
  +//      }
  +//    }
     }
     
     public String getPermissionName()
  @@ -79,7 +78,7 @@
     {
       Permission required = new SeamPermission(permissionName, action);
   
  -    AclProvider provider = (AclProvider) Component.getInstance(providers.get(action), true);
  +    AclManager provider = (AclManager) Component.getInstance(providers.get(action), true);
       Principal principal = Authentication.instance();
       
       if (provider != null)
  
  
  
  1.18      +3 -3      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- SeamSecurityManager.java	24 Nov 2006 23:15:19 -0000	1.17
  +++ SeamSecurityManager.java	4 Dec 2006 01:06:50 -0000	1.18
  @@ -17,7 +17,7 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.security.acl.AclProvider;
  +import org.jboss.seam.security.acl.AclManager;
   import org.jboss.seam.security.acl.IdentityGenerator;
   import org.jboss.seam.security.acl.JPAIdentityGenerator;
   
  @@ -166,13 +166,13 @@
     }
   
     public void grantPermission(Object target, String action, String recipient,
  -                               AclProvider.RecipientType recipientType)
  +                               AclManager.RecipientType recipientType)
     {
       /** @todo  */
     }
   
     public void revokePermission(Object target, String action, String recipient,
  -                               AclProvider.RecipientType recipientType)
  +                               AclManager.RecipientType recipientType)
     {
       /** @todo  */
     }
  
  
  
  1.1      date: 2006/12/04 01:06:50;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/security/Identity.java
  
  Index: Identity.java
  ===================================================================
  package org.jboss.seam.security;
  
  import static org.jboss.seam.ScopeType.SESSION;
  
  import java.io.Serializable;
  import java.security.Principal;
  
  import org.jboss.seam.Component;
  import org.jboss.seam.ScopeType;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Scope;
  import org.jboss.seam.contexts.Contexts;
  
  @Name("org.jboss.seam.security.identity")
  @Scope(SESSION)
  public abstract class Identity implements Principal, Serializable
  {
    protected boolean authenticated;
    protected boolean valid;
  
    public static Identity instance()
    {
      if (!Contexts.isSessionContextActive())
         throw new IllegalStateException("No active session context");
  
      Identity instance = (Identity) Component.getInstance(
          Identity.class, ScopeType.SESSION, true);
  
      if (instance==null)
      {
        throw new AuthenticationException(
            "No Identity exists in session scope");
      }
  
      return instance;
    }
  
    public abstract String[] getRoles();
    public abstract Object getCredentials();
    public abstract Object getPrincipal();
  
    public final boolean isAuthenticated()
    {
      return authenticated;
    }
  
    public final boolean isValid()
    {
      return valid;
    }
  
    public final void invalidate()
    {
      valid = false;
    }
  
    /**
     * Checks if the authenticated user contains the specified role.
     *
     * @param role String
     * @return boolean Returns true if the authenticated user contains the role,
     * or false if otherwise.
     */
    public boolean isUserInRole(String role)
    {
      for (String r : getRoles())
      {
        if (r.equals(role))
          return true;
      }
      return false;
    }
  }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:50 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl   ...
Message-ID: <E1Gr2IE-0002Ur-Uc@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:50

  Modified:    src/main/org/jboss/seam/security/acl  
                        AbstractAclProvider.java PersistentAclProvider.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/src/main/org/jboss/seam/security/acl/AbstractAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/AbstractAclProvider.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- AbstractAclProvider.java	22 Oct 2006 09:59:22 -0000	1.1
  +++ AbstractAclProvider.java	4 Dec 2006 01:06:50 -0000	1.2
  @@ -15,7 +15,7 @@
    *
    * @author Shane Bryzak
    */
  -public abstract class AbstractAclProvider implements AclProvider
  +public abstract class AbstractAclProvider implements AclManager
   {
     public Acl getAcls(Object obj)
     {
  
  
  
  1.12      +13 -14    jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PersistentAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- PersistentAclProvider.java	17 Nov 2006 17:17:42 -0000	1.11
  +++ PersistentAclProvider.java	4 Dec 2006 01:06:50 -0000	1.12
  @@ -18,7 +18,6 @@
   
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Scope;
  -import org.jboss.seam.annotations.security.DefinePermissions;
   import org.jboss.seam.core.ManagedHibernateSession;
   import org.jboss.seam.core.ManagedPersistenceContext;
   import org.jboss.seam.security.Authentication;
  @@ -181,13 +180,13 @@
             String recipient = (String) values[1];
             RecipientType recipientType = (RecipientType) values[2];
             
  -          DefinePermissions def = target.getClass().getAnnotation(DefinePermissions.class);
  -          for (org.jboss.seam.annotations.security.AclProvider provider : def.permissions())
  -          {
  -            if ((provider.mask() & mask) > 0)
  +//          DefinePermissions def = target.getClass().getAnnotation(DefinePermissions.class);
  +//          for (org.jboss.seam.annotations.security.AclProvider provider : def.permissions())
  +//          {
  +//            if ((provider.mask() & mask) > 0)
                 /** todo - use the correct name to create the permission */
  -              permissions.add(new SeamPermission("permissionName", provider.action()));
  -          }                   
  +//              permissions.add(new SeamPermission("permissionName", provider.action()));
  +//          }
           }
         }
         
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:51 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:51 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/adapter/jboss
	...
Message-ID: <E1Gr2IF-0002Uy-35@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:51

  Modified:    src/main/org/jboss/seam/security/adapter/jboss 
                        JBossAuthenticationAdapter.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.3       +33 -24    jboss-seam/src/main/org/jboss/seam/security/adapter/jboss/JBossAuthenticationAdapter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossAuthenticationAdapter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/adapter/jboss/JBossAuthenticationAdapter.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JBossAuthenticationAdapter.java	25 Oct 2006 15:14:37 -0000	1.2
  +++ JBossAuthenticationAdapter.java	4 Dec 2006 01:06:51 -0000	1.3
  @@ -6,9 +6,14 @@
   
   import org.jboss.seam.security.Authentication;
   import org.jboss.seam.security.adapter.AuthenticationAdapter;
  +import org.jboss.security.SecurityAssociation;
   import org.jboss.security.auth.callback.UsernamePasswordHandler;
  +import java.security.Principal;
  +import javax.security.auth.Subject;
   
   /**
  + *
  + *
    * @author Shane Bryzak
    */
   public class JBossAuthenticationAdapter implements AuthenticationAdapter
  @@ -17,34 +22,38 @@
   
     public void beginRequest()
     {
  -    Authentication auth = Authentication.instance();
  +    SecurityAssociation.clear();
  +//    Authentication auth = Authentication.instance();
   
  -    CallbackHandler handler = new UsernamePasswordHandler(
  -        auth.getPrincipal().toString(),
  -        auth.getCredentials());
  -    try
  -    {
  -      contexts.set(new LoginContext("client-login", handler));
  -      contexts.get().login();
  -    }
  -    catch (LoginException ex)
  -    {
  -      ex.printStackTrace();
  -    }
  +//    CallbackHandler handler = new UsernamePasswordHandler(
  +//        auth.getPrincipal().toString(),
  +//        auth.getCredentials());
  +//    try
  +//    {
  +//      contexts.set(new LoginContext("client-login", handler));
  +//      contexts.get().login();
  +//    }
  +//    catch (LoginException ex)
  +//    {
  +//      ex.printStackTrace();
  +//    }
     }
   
     public void endRequest()
     {
  -    try
  -    {
  -      contexts.get().logout();
  -    }
  -    catch (LoginException ex)
  -    {
  -    }
  -    finally
  -    {
  -      contexts.remove();
  -    }
  +//    try
  +//    {
  +//      LoginContext ctx = contexts.get();
  +//      if (ctx != null)
  +//        ctx.logout();
  +//    }
  +//    catch (LoginException ex)
  +//    {
  +//      ex.printStackTrace();
  +//    }
  +//    finally
  +//    {
  +//      contexts.remove();
  +//    }
     }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:06:51 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:06:51 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/filter  ...
Message-ID: <E1Gr2IF-0002V5-77@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:06:51

  Modified:    src/main/org/jboss/seam/security/filter 
                        SeamSecurityFilter.java
  Log:
  bye bye old security design
  
  Revision  Changes    Path
  1.11      +18 -64    jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- SeamSecurityFilter.java	25 Oct 2006 15:14:38 -0000	1.10
  +++ SeamSecurityFilter.java	4 Dec 2006 01:06:51 -0000	1.11
  @@ -1,10 +1,6 @@
   package org.jboss.seam.security.filter;
   
   import java.io.IOException;
  -import java.util.HashSet;
  -import java.util.Set;
  -
  -import javax.security.auth.login.LoginException;
   import javax.servlet.Filter;
   import javax.servlet.FilterChain;
   import javax.servlet.FilterConfig;
  @@ -74,77 +70,35 @@
   //    Authentication authentication = (Authentication)sessionContext.get(
   //            "org.jboss.seam.security.Authentication");
   
  -//    LoginContext lc = null;
   //    try
   //    {
  -//      Lifecycle.beginInitialization(servletContext);
  -//
  -//      if (authentication != null)
  +      chain.doFilter(request, response);
  +//    }
  +//    catch (Exception e)
   //      {
  -//        AuthenticationContext.instance().setAuthentication(Authenticator.instance().authenticate(authentication));
  -//        CallbackHandler handler = new UsernamePasswordHandler(
  -//            authentication.getPrincipal().toString(),
  -//            authentication.getCredentials());
  -//        try
  +//      if (e instanceof ServletException)
   //        {
  -//          lc = new LoginContext("client-login", handler);
  -//          lc.login();
  -//        }
  -//        catch (LoginException ex)
  +//        Throwable cause = ( (ServletException) e).getRootCause();
  +//
  +//        Set<Throwable> causes = new HashSet<Throwable> ();
  +//        while (cause != null && !causes.contains(cause))
  +//        {
  +//          if (cause instanceof LoginException)
   //        {
  -//          ex.printStackTrace();
  -//        }
  -//      }
  -//    }
  -//    catch (AuthenticationException ex) { }
  -
  -    try
  -    {
  -      chain.doFilter(request, response);
  -    }
  -    catch (Exception e)
  -    {
  -      if (e instanceof ServletException)
  -      {
  -        Throwable cause = ( (ServletException) e).getRootCause();
  -
  -        Set<Throwable> causes = new HashSet<Throwable> ();
  -        while (cause != null && !causes.contains(cause))
  -        {
  -          if (cause instanceof LoginException)
  -          {
               // Redirect to login page
  -            log.info("User not logged in... redirecting to login page.");
  +//            log.info("User not logged in... redirecting to login page.");
   
               /** @todo Redirect based on whatever authentication method is being used */
   
   //             SecurityConfig.instance().getAuthenticator().showLogin(hRequest, hResponse);
  -            break;
  -          }
  -          causes.add(cause);
  -          cause = cause.getCause();
  -        }
  -      }
  -      throw new ServletException(e);
  -    }
  -    finally
  -    {
  -      // Have to set the application context again because it's probably null
  -//      Lifecycle.beginInitialization(servletContext);
  -
  -//      AuthenticationContext.instance().setAuthentication(null);
  -
  -//      if (lc != null)
  -//      {
  -//        try
  -//        {
  -//          lc.logout();
  +//            break;
   //        }
  -//        catch (LoginException ex){ }
  +//          causes.add(cause);
  +//          cause = cause.getCause();
  +//        }
  +//      }
  +//      throw new ServletException(e);
   //      }
  -
  -      /** @todo Clear the application context somewhere here */
  -    }
     }
   
     public void destroy()
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:10:19 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:10:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/mock  ...
Message-ID: <E1Gr2Lb-0002XW-Bk@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:10:19

  Modified:    src/main/org/jboss/seam/mock  MockAclPermission.java
  Log:
  undid name change to AclProvider
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/src/main/org/jboss/seam/mock/MockAclPermission.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockAclPermission.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockAclPermission.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MockAclPermission.java	4 Dec 2006 01:06:50 -0000	1.2
  +++ MockAclPermission.java	4 Dec 2006 01:10:19 -0000	1.3
  @@ -5,7 +5,7 @@
   import javax.persistence.Id;
   import javax.persistence.ManyToOne;
   
  -import org.jboss.seam.security.acl.AclManager.RecipientType;
  +import org.jboss.seam.security.acl.AclProvider.RecipientType;
   
   /**
    * Defines permissions for an object
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:10:19 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:10:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security   ...
Message-ID: <E1Gr2Lb-0002Xg-Gq@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:10:19

  Modified:    src/main/org/jboss/seam/security   PermissionHandler.java
                        SeamSecurityManager.java
  Log:
  undid name change to AclProvider
  
  Revision  Changes    Path
  1.4       +2 -3      jboss-seam/src/main/org/jboss/seam/security/PermissionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PermissionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/PermissionHandler.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PermissionHandler.java	4 Dec 2006 01:06:50 -0000	1.3
  +++ PermissionHandler.java	4 Dec 2006 01:10:19 -0000	1.4
  @@ -8,8 +8,7 @@
   
   import org.jboss.seam.Component;
   import org.jboss.seam.Seam;
  -//import org.jboss.seam.annotations.security.DefinePermissions;
  -import org.jboss.seam.security.acl.AclManager;
  +import org.jboss.seam.security.acl.AclProvider;
   
   /**
    *
  @@ -78,7 +77,7 @@
     {
       Permission required = new SeamPermission(permissionName, action);
   
  -    AclManager provider = (AclManager) Component.getInstance(providers.get(action), true);
  +    AclProvider provider = (AclProvider) Component.getInstance(providers.get(action), true);
       Principal principal = Authentication.instance();
   
       if (provider != null)
  
  
  
  1.19      +7 -7      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- SeamSecurityManager.java	4 Dec 2006 01:06:50 -0000	1.18
  +++ SeamSecurityManager.java	4 Dec 2006 01:10:19 -0000	1.19
  @@ -17,7 +17,7 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.security.acl.AclManager;
  +import org.jboss.seam.security.acl.AclProvider;
   import org.jboss.seam.security.acl.IdentityGenerator;
   import org.jboss.seam.security.acl.JPAIdentityGenerator;
   
  @@ -166,13 +166,13 @@
     }
   
     public void grantPermission(Object target, String action, String recipient,
  -                               AclManager.RecipientType recipientType)
  +                               AclProvider.RecipientType recipientType)
     {
       /** @todo  */
     }
   
     public void revokePermission(Object target, String action, String recipient,
  -                               AclManager.RecipientType recipientType)
  +                               AclProvider.RecipientType recipientType)
     {
       /** @todo  */
     }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:10:19 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:10:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl  ...
Message-ID: <E1Gr2Lb-0002Xn-LE@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:10:19

  Modified:    src/main/org/jboss/seam/security/acl 
                        AbstractAclProvider.java
  Log:
  undid name change to AclProvider
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/src/main/org/jboss/seam/security/acl/AbstractAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/AbstractAclProvider.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- AbstractAclProvider.java	4 Dec 2006 01:06:50 -0000	1.2
  +++ AbstractAclProvider.java	4 Dec 2006 01:10:19 -0000	1.3
  @@ -15,7 +15,7 @@
    *
    * @author Shane Bryzak
    */
  -public abstract class AbstractAclProvider implements AclManager
  +public abstract class AbstractAclProvider implements AclProvider
   {
     public Acl getAcls(Object obj)
     {
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:11:59 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:11:59 -0500
Subject: [jboss-cvs] jboss-seam/examples/security  ...
Message-ID: <E1Gr2ND-0002bV-Ue@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:11:59

  Removed:     examples/security  build.xml
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:12:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:12:00 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/resources/META-INF     ...
Message-ID: <E1Gr2NE-0002bZ-3y@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:12:00

  Removed:     examples/security/resources/META-INF     application.xml
                        ejb-jar.xml jboss-app.xml persistence.xml
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:12:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:12:00 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/resources/WEB-INF     ...
Message-ID: <E1Gr2NE-0002bd-9m@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:12:00

  Removed:     examples/security/resources/WEB-INF     components.xml
                        faces-config.xml seam-security.xml web.xml
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:12:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:12:00 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/resources    ...
Message-ID: <E1Gr2NE-0002bh-FS@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:12:00

  Removed:     examples/security/resources    import.sql seam.properties
                        security-ds.xml
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:12:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:12:00 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/security/src/org/jboss/seam/example/security ...
Message-ID: <E1Gr2NE-0002bl-Kp@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:12:00

  Removed:     examples/security/src/org/jboss/seam/example/security         
                        AuthenticatorAction.java Customer.java
                        CustomerAclProvider.java LoginAction.java
                        LoginLocal.java ProtectedAction.java
                        ProtectedLocal.java Role.java User.java
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:12:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:12:00 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/view     ...
Message-ID: <E1Gr2NE-0002bp-PR@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:12:00

  Removed:     examples/security/view     home.xhtml index.html
                        protected.xhtml welcome.xhtml
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:12:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:12:00 -0500
Subject: [jboss-cvs] jboss-seam/examples/security/view/protected  ...
Message-ID: <E1Gr2NE-0002bt-TB@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:12:00

  Removed:     examples/security/view/protected  protected.xhtml
  Log:
  removed redundant security example


From Shane_Bryzak at symantec.com  Sun Dec  3 20:15:39 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:15:39 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/adapter  ...
Message-ID: <E1Gr2Ql-0002eP-BQ@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:15:39

  Removed:     src/main/org/jboss/seam/security/adapter 
                        AuthenticationAdapter.java
  Log:
  removed until core security framework is complete


From Shane_Bryzak at symantec.com  Sun Dec  3 20:15:39 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:15:39 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/adapter/jboss
	...
Message-ID: <E1Gr2Ql-0002eT-GT@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:15:39

  Removed:     src/main/org/jboss/seam/security/adapter/jboss  
                        JBossAuthenticationAdapter.java
                        SeamLoginModule.java
  Log:
  removed until core security framework is complete


From Shane_Bryzak at symantec.com  Sun Dec  3 20:15:39 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:15:39 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/provider ...
Message-ID: <E1Gr2Ql-0002eX-KR@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:15:39

  Removed:     src/main/org/jboss/seam/security/provider 
                        AuthenticationProvider.java
  Log:
  removed until core security framework is complete


From Shane_Bryzak at symantec.com  Sun Dec  3 20:15:39 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:15:39 -0500
Subject: [jboss-cvs]
	jboss-seam/src/main/org/jboss/seam/security/provider/catalina ...
Message-ID: <E1Gr2Ql-0002eg-Pj@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:15:39

  Removed:     src/main/org/jboss/seam/security/provider/catalina 
                        CatalinaProvider.java
  Log:
  removed until core security framework is complete


From Shane_Bryzak at symantec.com  Sun Dec  3 20:15:39 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:15:39 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/provider/jaas
	...
Message-ID: <E1Gr2Ql-0002ek-Ts@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:15:39

  Removed:     src/main/org/jboss/seam/security/provider/jaas  
                        JaasAuthenticationProvider.java
                        JaasCallbackHandler.java
  Log:
  removed until core security framework is complete


From Shane_Bryzak at symantec.com  Sun Dec  3 20:21:52 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:21:52 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security     ...
Message-ID: <E1Gr2Wm-0002lv-M4@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:21:52

  Modified:    src/main/org/jboss/seam/security     PermissionHandler.java
                        SeamSecurityManager.java UsernamePasswordToken.java
  Removed:     src/main/org/jboss/seam/security     Authentication.java
  Log:
  Authentication superseded by Identity
  
  Revision  Changes    Path
  1.5       +1 -1      jboss-seam/src/main/org/jboss/seam/security/PermissionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PermissionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/PermissionHandler.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- PermissionHandler.java	4 Dec 2006 01:10:19 -0000	1.4
  +++ PermissionHandler.java	4 Dec 2006 01:21:52 -0000	1.5
  @@ -78,7 +78,7 @@
       Permission required = new SeamPermission(permissionName, action);
   
       AclProvider provider = (AclProvider) Component.getInstance(providers.get(action), true);
  -    Principal principal = Authentication.instance();
  +    Principal principal = Identity.instance();
   
       if (provider != null)
       {
  
  
  
  1.20      +2 -2      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- SeamSecurityManager.java	4 Dec 2006 01:10:19 -0000	1.19
  +++ SeamSecurityManager.java	4 Dec 2006 01:21:52 -0000	1.20
  @@ -124,7 +124,7 @@
     private void checkRolePermissions(String permissionName, String action)
     {
       Permission required = new SeamPermission(permissionName, action);
  -    for (String role : Authentication.instance().getRoles())
  +    for (String role : Identity.instance().getRoles())
       {
         Set<Permission> permissions = rolePermissions.get(role);
         if (permissions != null && permissions.contains(required))
  @@ -155,7 +155,7 @@
       return null;
     }
   
  -  public Permissions getPermissions(Object value, Authentication auth)
  +  public Permissions getPermissions(Object value, Identity ident)
     {
       return null;
     }
  
  
  
  1.7       +3 -3      jboss-seam/src/main/org/jboss/seam/security/UsernamePasswordToken.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UsernamePasswordToken.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/UsernamePasswordToken.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- UsernamePasswordToken.java	14 Nov 2006 05:24:04 -0000	1.6
  +++ UsernamePasswordToken.java	4 Dec 2006 01:21:52 -0000	1.7
  @@ -3,7 +3,7 @@
   /**
    * @author Shane Bryzak
    */
  -public class UsernamePasswordToken extends Authentication
  +public class UsernamePasswordToken extends Identity
   {
     private String[] roles;
     private Object credentials;
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:21:52 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:21:52 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl   ...
Message-ID: <E1Gr2Wm-0002m5-Q3@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:21:52

  Modified:    src/main/org/jboss/seam/security/acl  
                        AbstractAclProvider.java PersistentAclProvider.java
  Log:
  Authentication superseded by Identity
  
  Revision  Changes    Path
  1.4       +2 -2      jboss-seam/src/main/org/jboss/seam/security/acl/AbstractAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/AbstractAclProvider.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- AbstractAclProvider.java	4 Dec 2006 01:10:19 -0000	1.3
  +++ AbstractAclProvider.java	4 Dec 2006 01:21:52 -0000	1.4
  @@ -8,7 +8,7 @@
   import java.util.Map;
   import java.util.Set;
   
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   
   /**
    * Abstract base implementation of AclProvider
  @@ -32,7 +32,7 @@
   
     protected Acl internalGetAcls(Object obj, Principal principal)
     {
  -    Principal owner = Authentication.instance();
  +    Principal owner = Identity.instance();
   
       Acl acl = new AclImpl(owner);
   
  
  
  
  1.13      +3 -3      jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PersistentAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- PersistentAclProvider.java	4 Dec 2006 01:06:50 -0000	1.12
  +++ PersistentAclProvider.java	4 Dec 2006 01:21:52 -0000	1.13
  @@ -20,7 +20,7 @@
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.core.ManagedHibernateSession;
   import org.jboss.seam.core.ManagedPersistenceContext;
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.SeamPermission;
   import org.jboss.seam.security.SeamSecurityManager;
   import org.jboss.seam.util.Naming;
  @@ -124,9 +124,9 @@
     {
       List<String> roles = new ArrayList<String>();
   
  -    if (Authentication.class.isAssignableFrom(principal.getClass()))
  +    if (Identity.class.isAssignableFrom(principal.getClass()))
       {
  -      for (String role : ((Authentication) principal).getRoles())
  +      for (String role : ((Identity) principal).getRoles())
         {
           roles.add(role);
         }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:21:52 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:21:52 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/authenticator
	...
Message-ID: <E1Gr2Wm-0002mF-VI@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:21:52

  Modified:    src/main/org/jboss/seam/security/authenticator  
                        Authenticator.java ProviderAuthenticator.java
  Log:
  Authentication superseded by Identity
  
  Revision  Changes    Path
  1.15      +9 -9      jboss-seam/src/main/org/jboss/seam/security/authenticator/Authenticator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Authenticator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/authenticator/Authenticator.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- Authenticator.java	24 Nov 2006 23:15:19 -0000	1.14
  +++ Authenticator.java	4 Dec 2006 01:21:52 -0000	1.15
  @@ -11,7 +11,7 @@
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
   import org.jboss.seam.security.UsernamePasswordToken;
   import org.jboss.seam.security.adapter.AuthenticationAdapter;
  @@ -45,26 +45,26 @@
       return instance;
     }
   
  -  public Authentication authenticate(String username, String password)
  +  public Identity authenticate(String username, String password)
         throws AuthenticationException
     {
       return authenticate(new UsernamePasswordToken(username, password));
     }
   
  -  public final Authentication authenticate(Authentication authentication)
  +  public final Identity authenticate(Identity ident)
         throws AuthenticationException
     {
  -    Authentication auth = doAuthentication(authentication);
  -    Contexts.getSessionContext().set(Seam.getComponentName(Authentication.class), auth);
  +    Identity auth = doAuthentication(ident);
  +    Contexts.getSessionContext().set(Seam.getComponentName(Identity.class), auth);
       return auth;
     }
   
  -  public abstract Authentication doAuthentication(Authentication authentication)
  +  public abstract Identity doAuthentication(Identity ident)
         throws AuthenticationException;
   
     public void unauthenticateSession()
     {
  -    Authentication.instance().invalidate();
  +    Identity.instance().invalidate();
     }
   
     public void setAdapters(List<String> adapterNames)
  @@ -96,7 +96,7 @@
         adapter.endRequest();
       }
   
  -    if (!Authentication.instance().isValid())
  -      Contexts.getSessionContext().remove(Seam.getComponentName(Authentication.class));
  +    if (!Identity.instance().isValid())
  +      Contexts.getSessionContext().remove(Seam.getComponentName(Identity.class));
     }
   }
  
  
  
  1.11      +3 -3      jboss-seam/src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProviderAuthenticator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ProviderAuthenticator.java	24 Nov 2006 23:15:19 -0000	1.10
  +++ ProviderAuthenticator.java	4 Dec 2006 01:21:52 -0000	1.11
  @@ -10,7 +10,7 @@
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
   import org.jboss.seam.security.provider.AuthenticationProvider;
   import org.jboss.seam.util.Reflections;
  @@ -34,7 +34,7 @@
      * @throws AuthenticationException
      */
     @Override
  -  public Authentication doAuthentication(Authentication authentication)
  +  public Identity doAuthentication(Identity authentication)
         throws AuthenticationException
     {
       for (Object p : providers)
  @@ -46,7 +46,7 @@
         else if (p instanceof Component)
           provider = (AuthenticationProvider) ( (Component) p).newInstance();
   
  -      Authentication result = provider.authenticate(authentication);
  +      Identity result = provider.authenticate(authentication);
         if (result != null)
           return result;
       }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:21:53 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:21:53 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/adapter  ...
Message-ID: <E1Gr2Wn-0002mM-3O@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:21:53

  Added:       src/main/org/jboss/seam/security/adapter 
                        AuthenticationAdapter.java
  Log:
  Authentication superseded by Identity
  
  Revision  Changes    Path
  1.3       +0 -0      jboss-seam/src/main/org/jboss/seam/security/adapter/AuthenticationAdapter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AuthenticationAdapter.java
  ===================================================================
  RCS file: AuthenticationAdapter.java
  diff -N AuthenticationAdapter.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ AuthenticationAdapter.java	4 Dec 2006 01:21:53 -0000	1.3
  @@ -0,0 +1,12 @@
  +package org.jboss.seam.security.adapter;
  +
  +/**
  + * <p> </p>
  + *
  + * @author Shane Bryzak
  + */
  +public interface AuthenticationAdapter
  +{
  +  void beginRequest();
  +  void endRequest();
  +}
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:21:53 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:21:53 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/provider ...
Message-ID: <E1Gr2Wn-0002mT-74@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:21:53

  Added:       src/main/org/jboss/seam/security/provider 
                        AuthenticationProvider.java
  Log:
  Authentication superseded by Identity
  
  Revision  Changes    Path
  1.7       +0 -0      jboss-seam/src/main/org/jboss/seam/security/provider/AuthenticationProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AuthenticationProvider.java
  ===================================================================
  RCS file: AuthenticationProvider.java
  diff -N AuthenticationProvider.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ AuthenticationProvider.java	4 Dec 2006 01:21:53 -0000	1.7
  @@ -0,0 +1,13 @@
  +package org.jboss.seam.security.provider;
  +
  +import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.AuthenticationException;
  +
  +/**
  + * @author Shane Bryzak
  + */
  +public interface AuthenticationProvider
  +{
  +  Authentication authenticate(Authentication authentication)
  +        throws AuthenticationException;
  +}
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 20:23:59 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 20:23:59 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/provider ...
Message-ID: <E1Gr2Yp-0002mi-8n@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 20:23:59

  Modified:    src/main/org/jboss/seam/security/provider 
                        AuthenticationProvider.java
  Log:
  fixed invalid import
  
  Revision  Changes    Path
  1.8       +2 -2      jboss-seam/src/main/org/jboss/seam/security/provider/AuthenticationProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AuthenticationProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/provider/AuthenticationProvider.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- AuthenticationProvider.java	4 Dec 2006 01:21:53 -0000	1.7
  +++ AuthenticationProvider.java	4 Dec 2006 01:23:59 -0000	1.8
  @@ -1,6 +1,6 @@
   package org.jboss.seam.security.provider;
   
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
   
   /**
  @@ -8,6 +8,6 @@
    */
   public interface AuthenticationProvider
   {
  -  Authentication authenticate(Authentication authentication)
  +  Identity authenticate(Identity authentication)
           throws AuthenticationException;
   }
  
  
  


From gavin.king at jboss.com  Sun Dec  3 20:45:25 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 20:45:25 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1Gr2tZ-00036r-VT@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 20:45:25

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  better formatting
  better handling of id properties
  JBSEAM-561
  
  Revision  Changes    Path
  1.13      +139 -92   jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- edit.xhtml.ftl	3 Dec 2006 19:28:30 -0000	1.12
  +++ edit.xhtml.ftl	4 Dec 2006 01:45:25 -0000	1.13
  @@ -21,26 +21,26 @@
       <h:messages globalOnly="true" styleClass="message"/>
       
       <h:form id="${componentName}">
  +    
           <div class="dialog">
           <table>
           <s:validateAll>
   <#foreach property in pojo.allPropertiesIterator>
  -<#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
  +<#if !c2h.isCollection(property) && !c2h.isManyToOne(property) && property.columnSpan==1>
  +<#assign propertyIsId = property.equals(pojo.identifierProperty)>
  +<#if !propertyIsId || property.value.identifierGeneratorStrategy == "assigned">
  +<#assign column = property.columnIterator.next()>
  +
               <tr class="prop">
                   <td class="name">${property.name}</td>
                   <td class="value">
                       <s:decorate>
  -<#if property.equals(pojo.identifierProperty)>
  -<#if property.value.identifierGeneratorStrategy == "assigned">
  -                        <h:inputText id="${property.name}"
  -                                  value="${'#'}{${homeName}.instance.${property.name}}" 
  -                               required="true"
  -                               disabled="${'#'}{${homeName}.managed}"/>
  -</#if>
  -<#else>
   <#if property.value.typeName == "date">
   			           <h:inputText id="${property.name}" 
  -<#if !property.columnIterator.next().nullable>
  +<#if propertyIsId>
  +                              disabled="${'#'}{${homeName}.managed}"
  +</#if>
  +<#if !column.nullable>
                                 required="true"
   </#if>
   			                     value="${'#'}{${homeName}.instance.${property.name}}">
  @@ -48,7 +48,7 @@
   			           </h:inputText>
   <#elseif property.value.typeName == "time">
   			           <h:inputText id="${property.name}" 
  -<#if !property.columnIterator.next().nullable>
  +<#if !column.nullable>
                                 required="true"
   </#if>
   			                     value="${'#'}{${homeName}.instance.${property.name}}">
  @@ -56,7 +56,7 @@
   			           </h:inputText>
   <#elseif property.value.typeName == "timestamp">
   			           <h:inputText id="${property.name}" 
  -<#if !property.columnIterator.next().nullable>
  +<#if !column.nullable>
                                 required="true"
   </#if>
   			                     value="${'#'}{${homeName}.instance.${property.name}}">
  @@ -64,81 +64,116 @@
   			           </h:inputText>
   <#elseif property.value.typeName == "big_decimal">
   			           <h:inputText id="${property.name}" 
  -<#if !property.columnIterator.next().nullable>
  +<#if !column.nullable>
                                 required="true"
   </#if>
  -			                     value="${'#'}{${homeName}.instance.${property.name}}">
  -			               <f:convertNumber/>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}"
  +			                      size="${column.precision+7}">
  +			               <f:convertNumber maxIntegerDigits="${column.precision-column.scale}" 
  +			                               maxFractionDigits="${column.scale}"/>
   			           </h:inputText>
   <#elseif property.value.typeName == "big_integer">
   			           <h:inputText id="${property.name}" 
  -<#if !property.columnIterator.next().nullable>
  +<#if propertyIsId>
  +                              disabled="${'#'}{${homeName}.managed}"
  +</#if>
  +<#if !column.nullable>
                                 required="true"
   </#if>
  -			                    value="${'#'}{${homeName}.instance.${property.name}}">
  -			               <f:convertNumber integerOnly="true"/>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}"
  +			                      size="${column.precision+6}">
  +			               <f:convertNumber integerOnly="true"
  +			                           maxIntegerDigits="${column.precision}"/>
   			           </h:inputText>
   <#elseif property.value.typeName == "boolean">
   			           <h:selectBooleanCheckbox id="${property.name}"
  -<#if !property.columnIterator.next().nullable>
  +<#if !column.nullable>
                                             required="true"
   </#if>
   			                                 value="${'#'}{${homeName}.instance.${property.name}}"/>
   <#elseif property.value.typeName == "string">
  -<#if property.columnIterator.next().length gt 200>
  +<#if column.length gt 200>
   			           <h:inputTextarea id="${property.name}"
  -<#if !property.columnIterator.next().nullable>
  +<#if propertyIsId>
  +                                 disabled="${'#'}{${homeName}.managed}"
  +</#if>
  +<#if !column.nullable>
                                     required="true"
   </#if>
   			                         value="${'#'}{${homeName}.instance.${property.name}}"/>
   <#else>
                          <h:inputText id="${property.name}" 
  -<#if !property.columnIterator.next().nullable>
  +<#if propertyIsId>
  +                              disabled="${'#'}{${homeName}.managed}"
  +</#if>
  +<#if !column.nullable>
                                 required="true"
   </#if>
  -                                  size="${property.columnIterator.next().length}"
  -                             maxlength="${property.columnIterator.next().length}"
  +                                  size="${column.length}"
  +                             maxlength="${column.length}"
                                    value="${'#'}{${homeName}.instance.${property.name}}"/>
   </#if>
  +<#else>
  +			           <h:inputText id="${property.name}"
  +<#if !column.nullable>
  +                              required="true"
   </#if>
  +<#if propertyIsId>
  +                              disabled="${'#'}{${homeName}.managed}"
  +</#if>
  +			                     value="${'#'}{${homeName}.instance.${property.name}}"/>
   </#if>
                       </s:decorate>
                   </td>
               </tr>
   </#if>
  +</#if>
   </#foreach>
  +
           </s:validateAll>
           </table>
           </div>
  +        
           <div class="actionButtons">
  -            <h:commandButton id="save" value="Save" 
  +        
  +            <h:commandButton id="save" 
  +                          value="Save" 
                   action="${'#'}{${homeName}.persist}"
                   rendered="${'#'}{!${homeName}.managed}"/>     			  
  -            <h:commandButton id="update" value="Save" 
  +                          			  
  +            <h:commandButton id="update" 
  +                          value="Save" 
                   action="${'#'}{${homeName}.update}"
                   rendered="${'#'}{${homeName}.managed}"/>    			  
  -            <s:button id="delete" value="Delete" 
  +                        			  
  +            <s:button id="delete" 
  +                   value="Delete" 
                   action="${'#'}{${homeName}.remove}"
                   rendered="${'#'}{${homeName}.managed}"
                   propagation="end"
                   view="/${masterPageName}.xhtml"/>
  -            <s:button id="done" value="Done"
  +                    
  +            <s:button id="done" 
  +                   value="Done"
                   propagation="end" 
                   view="/${pageName}.xhtml"
                   rendered="${'#'}{${homeName}.managed}"/>
  -            <s:button id="cancel" value="Cancel"
  +                
  +            <s:button id="cancel" 
  +                   value="Cancel"
                   propagation="end" 
                   view="/${masterPageName}.xhtml"
                   rendered="${'#'}{!${homeName}.managed}"/>
  +                
           </div>
  -    </h:form>
       
  +    </h:form>
   <#foreach property in pojo.allPropertiesIterator>
  -
   <#if c2h.isManyToOne(property)>
   <#assign parentPojo = c2j.getPOJOClass(cfg.getClassMapping(property.value.referencedEntityName))>
   <#assign parentPageName = parentPojo.shortName>
   <#assign parentName = util.lower(parentPojo.shortName)>
  +
              <h2>${property.name}</h2>
              <h:outputText value="No ${property.name}" rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
              <h:dataTable var="${parentName}" 
  @@ -163,15 +198,20 @@
   </#foreach>
                  <h:column>
                      <f:facet name="header">action</f:facet>
  -		           <s:link id="view${parentName}" value="View" view="/${parentPageName}.xhtml" propagation="end">
  -		               <f:param name="${parentName}Id" value="${'#'}{${parentName}.${parentPojo.identifierProperty.name}}"/>
  +            <s:link view="/${parentPageName}.xhtml" 
  +                     id="view${parentName}" 
  +                  value="View" 
  +            propagation="end">
  +                <f:param name="${parentName}Id" 
  +                        value="${'#'}{${parentName}.${parentPojo.identifierProperty.name}}"/>
   		           </s:link>
                  </h:column>
              </h:dataTable>
   </#if>
  -
   <#if c2h.isOneToManyCollection(property)>
  +
             <f:subview rendered="${'#'}{${homeName}.managed}">
  +    
               <h2>${property.name}</h2>
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
   <#assign childPageName = childPojo.shortName>
  @@ -193,19 +233,26 @@
   </#foreach>
                 <h:column>
                     <f:facet name="header">action</f:facet>
  -		          <s:link id="select${childName}" value="Select" view="/${childPageName}.xhtml" propagation="end">
  -		              <f:param name="${childName}Id" value="${'#'}{${childName}.${childPojo.identifierProperty.name}}"/>
  +                <s:link view="/${childPageName}.xhtml" 
  +                          id="select${childName}" 
  +                       value="Select"
  +                 propagation="end">
  +                    <f:param name="${childName}Id" 
  +                            value="${'#'}{${childName}.${childPojo.identifierProperty.name}}"/>
   		          </s:link>
                 </h:column>
               </h:dataTable>
             
   		    <div class="actionButtons">
  -		        <s:button id="add${childName}" value="Add ${childName}"
  -		            view="/${childEditPageName}.xhtml" propagation="begin">
  +            <s:button id="add${childName}" 
  +                   value="Add ${childName}"
  +                    view="/${childEditPageName}.xhtml" 
  +             propagation="begin">
   	            	<f:param name="${componentName}Id" 
   	            	    value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
   	            </s:button>
   		    </div>
  +        
   		  </f:subview>
   </#if>
   </#foreach>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 21:26:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 21:26:24 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1695 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/server/connectionfactory messaging/core/plugin/contract
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1Gr3XE-0003w4-WC@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 21:26:21 -0500 (Sun, 03 Dec 2006)
New Revision: 1695

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
Fixed broken clustered ConnectionFactory initialization. http://jira.jboss.org/jira/browse/JBMESSAGING-667

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-03 22:41:30 UTC (rev 1694)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-04 02:26:21 UTC (rev 1695)
@@ -34,6 +34,7 @@
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.server.ConnectionFactoryManager;
 import org.jboss.jms.server.ServerPeer;
+import org.jboss.jms.server.Version;
 import org.jboss.jms.server.endpoint.ServerConnectionFactoryEndpoint;
 import org.jboss.jms.server.endpoint.advised.ConnectionFactoryAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
@@ -65,8 +66,12 @@
    
    protected Context initialContext;
    protected ServerPeer serverPeer;
+
+   // Map<uniqueName<String> - ServerConnectionFactoryEndpoint>
    protected Map endpoints;
-   protected Map factories;
+
+   // Map<uniqueName<String> - ClusteredClientConnectionFactoryDelegate>
+   protected Map clusteredDelegates;
    
    protected Replicator replicator;
    
@@ -76,7 +81,7 @@
    {
       this.serverPeer = serverPeer;
       endpoints = new HashMap();
-      factories = new HashMap();
+      clusteredDelegates = new HashMap();
    }
    
    // ConnectionFactoryManager implementation -----------------------
@@ -94,6 +99,7 @@
       throws Exception
    {
       int id = serverPeer.getNextObjectID();
+      Version version = serverPeer.getVersion();
 
       ServerConnectionFactoryEndpoint endpoint =
          new ServerConnectionFactoryEndpoint(id, serverPeer, clientID,
@@ -101,61 +107,43 @@
                                              defaultTempQueueFullSize,
                                              defaultTempQueuePageSize,
                                              defaultTempQueueDownCacheSize);
+      endpoints.put(uniqueName, endpoint);
 
-      ClientConnectionFactoryDelegate delegate =
-         new ClientConnectionFactoryDelegate(id, locatorURI, serverPeer.getVersion(), clientPing);
-            
-      if (clustered)
+      JMSDispatcher.instance.
+         registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
+
+      ClientConnectionFactoryDelegate localDelegate =
+         new ClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
+
+      if (!clustered)
       {
-         setupReplicator();
-         
-         //We may have no clustered post office deployed, in which case a clustered connection factory
-         //behaves like a standard connection factory
-         if (replicator != null)
-         {                        
-            // First we must replicate the delegate across the cluster so that all the
-            // ConnectionFactoryJNDIMapper instances on different nodes have access to the list of
-            // local connection factories so they can be added to the clustered connection factory
-   
-            replicator.putReplicant(CF_PREFIX + uniqueName, delegate);
-            
-            // Get the list of delegates
-            
-            Map replicants = replicator.getReplicants(CF_PREFIX + uniqueName);
-            
-            //Create a clustered delegate which contains the array of the local delegates
-            //and failover indexes
-            
-            ClusteredClientConnectionFactoryDelegate clusteredDel = 
-               new ClusteredClientConnectionFactoryDelegate(id,
-                        locatorURI, serverPeer.getVersion(), clientPing);
-            
-            setFailoverDelegates(clusteredDel, replicants);
-            
-            delegate = clusteredDel;
-         }
+         rebindConnectionFactory(initialContext, jndiBindings, localDelegate);
+         return;
       }
-      
-      ConnectionFactoryAdvised connFactoryAdvised = new ConnectionFactoryAdvised(endpoint);
-      
-      JBossConnectionFactory cf = new JBossConnectionFactory(delegate);
-      
-      if (jndiBindings != null)
+
+      // We are clustered, we need to propagate the local delegate across the cluster.
+
+      setupReplicator();
+
+      if (replicator == null)
       {
-         List jndiNames = jndiBindings.getNames();
-         for(Iterator i = jndiNames.iterator(); i.hasNext(); )
-         {
-            String jndiName = (String)i.next();
-            JNDIUtil.rebind(initialContext, jndiName, cf);
-         }
+         return;
       }
-      
-      factories.put(uniqueName, cf);
-      
-      endpoints.put(uniqueName, endpoint);
-      
-      JMSDispatcher.instance.registerTarget(new Integer(id), connFactoryAdvised);
-            }
+
+      // Create a "hollow" clustered delegate ...
+
+      ClusteredClientConnectionFactoryDelegate clusteredDelegate =
+         new ClusteredClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
+
+      clusteredDelegates.put(uniqueName, clusteredDelegate);
+
+      // ... and then update it (and the clustered delegate on every node, while we're at it) by
+      // replicating the local delegate across the cluster. This way, the clustred delegates on each
+      // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
+      // will rebind updated ConnectionFactories in JNDI.
+
+      replicator.putReplicant(CF_PREFIX + uniqueName, localDelegate);
+   }
    
    public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception
    {
@@ -181,7 +169,7 @@
       }
       
       ClientConnectionFactoryDelegate delegate =
-         (ClientConnectionFactoryDelegate)factories.remove(uniqueName);
+         (ClientConnectionFactoryDelegate)clusteredDelegates.remove(uniqueName);
       
       if (delegate == null)
       {
@@ -241,55 +229,44 @@
    
    // ReplicationListener interface ----------------------------------
    
-   public synchronized void onReplicationChange(Serializable key, Map replicants)
+   public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap)
    {
       try
       {
-         //The list of connection factories across the cluster has changed -
-         //we need to update the clustered connection factories in JNDI with
-         //new ones with the up to date list
+         // The list of connection factories across the cluster has changed, so we need to update
+         // the clustered connection factories in JNDI with new ones with the up to date list.
+         // Replication can be used for other stuff (not just connection factories) so we check
+         // the prefix.
          
-         //Replication can be used for other stuff (not just connection factories)
-         //so we check the prefix
-         
          String sKey = (String)key;
          
          if (key instanceof String && sKey.startsWith(CF_PREFIX))
          {
             String uniqueName = sKey.substring(CF_PREFIX.length());
             
-            ClusteredClientConnectionFactoryDelegate cf =
-               (ClusteredClientConnectionFactoryDelegate)factories.get(uniqueName);
+            ClusteredClientConnectionFactoryDelegate clusteredDelegate =
+               (ClusteredClientConnectionFactoryDelegate)clusteredDelegates.get(uniqueName);
             
-            if (cf == null)
+            if (clusteredDelegate == null)
             {
-               throw new IllegalStateException("Cannot find connection factory " + uniqueName + " to update");
+               throw new IllegalStateException("Cannot find connection delegate for " +
+                                               uniqueName + " to update");
             }
             
-            setFailoverDelegates(cf, replicants);
+            setFailoverDelegates(clusteredDelegate, updatedReplicantMap);
             
-            //Now rebind
+            // Now rebind ...
             
             ServerConnectionFactoryEndpoint endpoint =
-               (ServerConnectionFactoryEndpoint)endpoints.remove(uniqueName);
+               (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
             
             if (endpoint == null)
             {
                throw new IllegalStateException("Cannot find endpoint " + uniqueName );
             }
-            
-            JNDIBindings jndiBindings = endpoint.getJNDIBindings();
-            
-            if (jndiBindings != null)
-            {
-               List jndiNames = jndiBindings.getNames();
-               for(Iterator i = jndiNames.iterator(); i.hasNext(); )
-               {
-                  String jndiName = (String)i.next();
-                  initialContext.rebind(jndiName, cf);
-               }
-            }  
-         } 
+
+            rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), clusteredDelegate);
+         }
       }
       catch (NamingException e)
       {
@@ -316,62 +293,50 @@
    {
       this.serverPeer.getQueuePostOfficeInstance();
    }
-   
-   
-   private void setFailoverDelegates(ClusteredClientConnectionFactoryDelegate cf,
-                                     Map replicants)
+
+
+   /**
+    * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
+    */
+   private void setFailoverDelegates(ClusteredClientConnectionFactoryDelegate clusteredDelegate,
+                                     Map localDelegates)
    {
-      // We need to get the failover indexes too
-      // If delegates[i] is the current delegate, then the failover delegate
-      // is given by delegates[failoverIndexes[i]]
-      
-      int s = replicants.size();
-      
+      int s = localDelegates.size();
+
+      int[] nodesIDs = new int[s];
+      int[] failoverNodeIDs = new int[s];
       ClientConnectionFactoryDelegate[] delegates = new ClientConnectionFactoryDelegate[s];
-      
-      Iterator iter = replicants.entrySet().iterator();
-      
-      int i = 0;
-      
-      int[] nodes = new int[s];
-      
-      int[] failoverNodes = new int[s];
-      
-      while (iter.hasNext())
+
+      int idx = 0;
+
+      for(Iterator i = localDelegates.entrySet().iterator(); i.hasNext(); )
       {
-         Map.Entry entry = (Map.Entry)iter.next();
-         
-         int nodeId = ((Integer)entry.getKey()).intValue();
-         
-         delegates[i] = (ClientConnectionFactoryDelegate)entry.getValue();
+         Map.Entry entry = (Map.Entry)i.next();
 
-         int failoverNode = replicator.getFailoverNodeForNode(nodeId);
-         
-         nodes[i] = nodeId;
-         
-         failoverNodes[i] = failoverNode; 
-         
-         i++;
+         int nodeID = ((Integer)entry.getKey()).intValue();
+         int failoverNodeID = replicator.getFailoverNodeID(nodeID);
+
+         nodesIDs[idx] = nodeID;
+         failoverNodeIDs[idx] = failoverNodeID;
+         delegates[idx] = (ClientConnectionFactoryDelegate)entry.getValue();
+
+         idx++;
       }
       
       // Generate the failover indexes. This could probably be optimised if need be.
       
       int[] failoverIndexes = new int[s];
       
-      for (int j = 0; j < s; i++)
+      for (int i = 0; i < s; i++)
       {
-         int failoverNode = failoverNodes[j];
-         
-         //What index is this node?
-         
+         int failoverNode = failoverNodeIDs[i];
          int failoverIndex = -1;
          
-         for (int k = 0; k  < s; k++)
+         for (int j = 0; j < s; j++)
          {
-            if (nodes[k] == failoverNode)
+            if (nodesIDs[j] == failoverNode)
             {
-               failoverIndex = k;
-               
+               failoverIndex = j;
                break;
             }
          }
@@ -381,11 +346,29 @@
             throw new IllegalStateException("Failover node is not in list of nodes!");
          }
          
-         failoverIndexes[j] = failoverIndex;
+         failoverIndexes[i] = failoverIndex;
       }
       
-      cf.setFailoverDelegates(delegates, failoverIndexes);
+      clusteredDelegate.setFailoverDelegates(delegates, failoverIndexes);
    }
 
+   private void rebindConnectionFactory(Context ic,
+                                        JNDIBindings jndiBindings,
+                                        ClientConnectionFactoryDelegate delegate)
+      throws NamingException
+   {
+      JBossConnectionFactory cf = new JBossConnectionFactory(delegate);
+
+      if (jndiBindings != null)
+      {
+         List jndiNames = jndiBindings.getNames();
+         for(Iterator i = jndiNames.iterator(); i.hasNext(); )
+         {
+            String jndiName = (String)i.next();
+            JNDIUtil.rebind(ic, jndiName, cf);
+         }
+      }
+   }
+
    // Inner classes -------------------------------------------------
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java	2006-12-03 22:41:30 UTC (rev 1694)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java	2006-12-04 02:26:21 UTC (rev 1695)
@@ -35,5 +35,9 @@
  */
 public interface ReplicationListener
 {
-   void onReplicationChange(Serializable key, Map replicants);
+   /**
+    * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
+    *        the given key.
+    */
+   void onReplicationChange(Serializable key, Map updatedReplicantMap);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-03 22:41:30 UTC (rev 1694)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-04 02:26:21 UTC (rev 1695)
@@ -56,10 +56,12 @@
    void unregisterListener(ReplicationListener listener);
    
    /**
-    * Gets the current failover node id for the specified node id.
-    * @param nodeId The node to get the failover node id for.
-    * @return the failover node id. If there is no failover node (one-node cluster), the method
+    * Gets the current failover node ID for the specified node ID.
+    *
+    * @param nodeID - The node to get the failover node id for.
+    *
+    * @return the failover node ID. If there is no failover node (one-node cluster), the method
     *         returns the original nodeID. 
     */
-   int getFailoverNodeForNode(int nodeId);   
+   int getFailoverNodeID(int nodeID);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-03 22:41:30 UTC (rev 1694)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 02:26:21 UTC (rev 1695)
@@ -314,11 +314,11 @@
       
       asyncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
       
-      this.controlMessageListener = new ControlMessageListener();
+      controlMessageListener = new ControlMessageListener();
       
-      this.requestHandler = new PostOfficeRequestHandler();
+      requestHandler = new PostOfficeRequestHandler();
       
-      this.controlMembershipListener = new ControlMembershipListener();
+      controlMembershipListener = new ControlMembershipListener();
       
       this.controlMessageDispatcher =
          new MessageDispatcher(syncChannel, controlMessageListener,
@@ -603,7 +603,7 @@
       return listBindingsForConditionInternal(condition, false);
    }
    
-   public int getFailoverNodeForNode(int nodeId)
+   public int getFailoverNodeID(int nodeId)
    {
       Integer failoverNode = (Integer)failoverMap.get(new Integer(nodeId));
       
@@ -1812,13 +1812,17 @@
          lock.writeLock().release();
       }
    }
-   
-   private void notifyListeners(Serializable key, Map replicants)
+
+   /**
+    * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
+    *        the given key.
+    */
+   private void notifyListeners(Serializable key, Map updatedReplicantMap)
    {
       for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
       {
          ReplicationListener listener = (ReplicationListener)i.next();
-         listener.onReplicationChange(key, replicants);
+         listener.onReplicationChange(key, updatedReplicantMap);
       }
    } 
    
@@ -1898,7 +1902,7 @@
     */
    private boolean isFailoverNodeForNode(int nodeId)
    {
-      return this.nodeId == getFailoverNodeForNode(nodeId);
+      return this.nodeId == getFailoverNodeID(nodeId);
    }
       
    private byte[] getStateAsBytes() throws Exception



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 21:33:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 21:33:20 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1696 - in
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx:
	. rmi
Message-ID: <E1Gr3dw-00040p-2K@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 21:33:18 -0500 (Sun, 03 Dec 2006)
New Revision: 1696

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
cosmetic logging changes

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-04 02:26:21 UTC (rev 1695)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-04 02:33:18 UTC (rev 1696)
@@ -372,11 +372,11 @@
 
          loadJNDIContexts();
 
-         log.info("REMOTING TYPE: ........... " +
+         log.info("Remoting type: ........... " +
             (remotingSocket ? "socket" : (remotingMultiplex ? "multiplex" : "disabled")));
-         log.info("SERIALIZATION TYPE: ...... " + config.getSerializationType());
-         log.info("DATABASE: ................ " + config.getDatabaseType());
-         log.info("CLUSTERING MODE: ......... " +
+         log.info("Serialization type: ...... " + config.getSerializationType());
+         log.info("Database: ................ " + config.getDatabaseType());
+         log.info("Clustering mode: ......... " +
             (config.isClustered() ? "CLUSTERED" : "NON-CLUSTERED"));
 
          log.debug(this + " started");
@@ -1187,7 +1187,7 @@
    {
       try
       {
-         log.info("************************** Deleting all data from database");
+         log.info("DELETING ALL DATA FROM DATABASE!");
          
          InitialContext ctx = new InitialContext();
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-04 02:26:21 UTC (rev 1695)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-04 02:33:18 UTC (rev 1696)
@@ -236,7 +236,7 @@
    {
       try
       {         
-         log.info(" SERVER PEER ID ........... " + serverPeerID);
+         log.info(" Server peer ID ........... " + serverPeerID);
          
          log.debug("creating ServerPeer instance");
    
@@ -266,7 +266,7 @@
                "server/default/deploy/" + databaseType + "-persistence-service.xml";
          }
 
-         log.info(" PERSISTENCE CONFIG FILE .. " + persistenceConfigFile);
+         log.info(" Persistence config file .. " + persistenceConfigFile);
 
          URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
          if (persistenceConfigFileURL == null)



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 21:38:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 21:38:16 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1697 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice
Message-ID: <E1Gr3ii-00045M-MI@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 21:38:15 -0500 (Sun, 03 Dec 2006)
New Revision: 1697

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
Log:
removed spurious logging statements

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-04 02:33:18 UTC (rev 1696)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-04 02:38:15 UTC (rev 1697)
@@ -257,8 +257,11 @@
       }
    }
 
-   /** Internal methods (e.g. failOver) will already hold a lock and will need to call getBindingForQueueNames without a lock.
-    *  (Also... I dind't move this method to the protected section of the code as this is related to getBindingForQueueNames */
+   /**
+    * Internal methods (e.g. failOver) will already hold a lock and will need to call
+    * getBindingForQueueNames without a lock. (Also... I dind't move this method to the protected
+    * section of the code as this is related to getBindingForQueueNames).
+    */
    protected Binding internalGetBindingForQueueName(String queueName)
    {
       Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
@@ -269,13 +272,7 @@
       {
          binding = (Binding)nameMap.get(queueName);
       }
-      else
-      {
-          log.info("nameMap is null");
-      }
 
-
-      log.info("Returned " + binding);
       return binding;
    }
 



From jboss-cvs-commits at lists.jboss.org  Sun Dec  3 21:58:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 03 Dec 2006 21:58:22 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1698 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/server/connectionfactory messaging/core/plugin/contract
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1Gr42A-0004LC-7S@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-03 21:58:19 -0500 (Sun, 03 Dec 2006)
New Revision: 1698

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
Replicator method name refactoring

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-04 02:38:15 UTC (rev 1697)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-04 02:58:19 UTC (rev 1698)
@@ -142,7 +142,7 @@
       // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
       // will rebind updated ConnectionFactories in JNDI.
 
-      replicator.putReplicant(CF_PREFIX + uniqueName, localDelegate);
+      replicator.put(CF_PREFIX + uniqueName, localDelegate);
    }
    
    public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception
@@ -185,7 +185,7 @@
          if (replicator != null)
          {         
             //There may be no clustered post office deployed
-            replicator.removeReplicant(CF_PREFIX + uniqueName);
+            replicator.remove(CF_PREFIX + uniqueName);
          }
          
       }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-04 02:38:15 UTC (rev 1697)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-04 02:58:19 UTC (rev 1698)
@@ -35,6 +35,7 @@
  * Then, for that key, there is an entry for each node id.
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -42,20 +43,34 @@
  */
 public interface Replicator
 {
-   void putReplicant(Serializable key, Serializable replicant) throws Exception;
-   
-   boolean removeReplicant(Serializable key) throws Exception;
+   /**
+    * Broadcast data across the cluster, updating replication maps on all nodes, including the local
+    * node.
+    */
+   void put(Serializable key, Serializable data) throws Exception;
 
    /**
-    * @return an empty map if no replicants are found for 'key', but never null.
+    * Return a node-mapped replicated data.
+    *
+    * @return a Map<Integer(nodeID)-data>. Returns an empty map if no replicants are found for
+    *         'key', but never null.
     */
-   Map getReplicants(Serializable key) throws Exception;
-   
+   Map get(Serializable key) throws Exception;
+
+   /**
+    * Updates the replication maps across the cluster by removing the data corresponding to the give
+    * key. Only the data corresponding to the current node is removed.
+    */
+   boolean remove(Serializable key) throws Exception;
+
    void registerListener(ReplicationListener listener);
    
    void unregisterListener(ReplicationListener listener);
    
    /**
+    * TODO - this method doesn't belong here, as no semantics should be associated with data at this
+    *        level
+    *
     * Gets the current failover node ID for the specified node ID.
     *
     * @param nodeID - The node to get the failover node id for.

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 02:38:15 UTC (rev 1697)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 02:58:19 UTC (rev 1698)
@@ -340,7 +340,7 @@
 
       PostOfficeAddressInfo info = new PostOfficeAddressInfo(syncAddress, asyncAddress);
       
-      putReplicant(ADDRESS_INFO_KEY, info);
+      put(ADDRESS_INFO_KEY, info);
       
       statsSender.start();
       
@@ -617,7 +617,7 @@
 
    // Replicator implementation --------------------------------------------------------------------------
    
-   public Map getReplicants(Serializable key) throws Exception
+   public Map get(Serializable key) throws Exception
    {
       lock.readLock().acquire();
       
@@ -633,7 +633,7 @@
       }
    }
 
-   public void putReplicant(Serializable key, Serializable replicant) throws Exception
+   public void put(Serializable key, Serializable replicant) throws Exception
    {
       putReplicantLocally(nodeId, key, replicant);
       
@@ -642,7 +642,7 @@
       syncSendRequest(request);
    }
    
-   public boolean removeReplicant(Serializable key) throws Exception
+   public boolean remove(Serializable key) throws Exception
    {
       if (removeReplicantLocally(this.nodeId, key))
       {      
@@ -1849,7 +1849,7 @@
       lock.readLock().acquire();
       try
       { 
-         Map map = getReplicants(ADDRESS_INFO_KEY);
+         Map map = get(ADDRESS_INFO_KEY);
          
          if (map == null)
          {
@@ -2031,7 +2031,7 @@
 
       try
       {
-         Map map = this.getReplicants(ADDRESS_INFO_KEY);
+         Map map = this.get(ADDRESS_INFO_KEY);
          
          if (map == null)
          {



From gavin.king at jboss.com  Sun Dec  3 22:06:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 22:06:04 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view   ...
Message-ID: <E1Gr49c-0004eR-4C@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 22:06:04

  Modified:    seam-gen/view   edit.xhtml.ftl view.xhtml.ftl
  Log:
  various improvements
  
  Revision  Changes    Path
  1.14      +136 -110  jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- edit.xhtml.ftl	4 Dec 2006 01:45:25 -0000	1.13
  +++ edit.xhtml.ftl	4 Dec 2006 03:06:04 -0000	1.14
  @@ -20,7 +20,7 @@
       
       <h:messages globalOnly="true" styleClass="message"/>
       
  -    <h:form id="${componentName}">
  +    <h:form id="${componentName}" styleClass="edit">
       
           <div class="dialog">
           <table>
  @@ -92,8 +92,15 @@
   </#if>
   			                                 value="${'#'}{${homeName}.instance.${property.name}}"/>
   <#elseif property.value.typeName == "string">
  -<#if column.length gt 200>
  +<#if column.length gt 160>
  +<#if column.length gt 800>
  +<#assign rows = 10>
  +<#else>
  +<#assign rows = (column.length/80)?int>
  +</#if>
   			           <h:inputTextarea id="${property.name}"
  +	        		                           cols="80"
  +	        		                           rows="${rows}"
   <#if propertyIsId>
                                    disabled="${'#'}{${homeName}.managed}"
   </#if>
  @@ -102,6 +109,11 @@
   </#if>
   			                         value="${'#'}{${homeName}.instance.${property.name}}"/>
   <#else>
  +<#if column.length gt 100>
  +<#assign size = 100>
  +<#else>
  +<#assign size = column.length>
  +</#if>
                          <h:inputText id="${property.name}" 
   <#if propertyIsId>
                                 disabled="${'#'}{${homeName}.managed}"
  @@ -109,7 +121,7 @@
   <#if !column.nullable>
                                 required="true"
   </#if>
  -                                  size="${column.length}"
  +                                          size="${size}"
                                maxlength="${column.length}"
                                    value="${'#'}{${homeName}.instance.${property.name}}"/>
   </#if>
  @@ -174,8 +186,13 @@
   <#assign parentPageName = parentPojo.shortName>
   <#assign parentName = util.lower(parentPojo.shortName)>
   
  +    <div class="association" id="${property.name}">
  +    
       <h2>${property.name}</h2>
  -    <h:outputText value="No ${property.name}" rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
  +    
  +        <h:outputText value="No ${property.name}" 
  +                   rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
  +    
       <h:dataTable var="${parentName}" 
                  value="${'#'}{${homeName}.instance.${property.name}}" 
               rendered="${'#'}{${homeName}.instance.${property.name} != null}"
  @@ -207,17 +224,24 @@
               </s:link>
           </h:column>
       </h:dataTable>
  +
  +    </div>
   </#if>
   <#if c2h.isOneToManyCollection(property)>
   
  -    <f:subview rendered="${'#'}{${homeName}.managed}">
  +    <f:subview rendered="${'#'}{${homeName}.managed}" id="${property.name}">
  +    
  +        <div class="association" id="${property.name}">
       
           <h2>${property.name}</h2>
  +        
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
   <#assign childPageName = childPojo.shortName>
   <#assign childEditPageName = childPojo.shortName + "Edit">
   <#assign childName = util.lower(childPojo.shortName)>
  -        <h:outputText value="No ${property.name}" rendered="${'#'}{empty ${homeName}.${property.name}}"/>
  +            <h:outputText value="No ${property.name}" 
  +                       rendered="${'#'}{empty ${homeName}.${property.name}}"/>
  +        
           <h:dataTable value="${'#'}{${homeName}.${property.name}}" 
                          var="${childName}" 
                     rendered="${'#'}{not empty ${homeName}.${property.name}}" 
  @@ -243,6 +267,8 @@
               </h:column>
           </h:dataTable>
             
  +        </div>
  +          
           <div class="actionButtons">
               <s:button id="add${childName}" 
                      value="Add ${childName}"
  
  
  
  1.5       +96 -85    jboss-seam/seam-gen/view/view.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: view.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/view.xhtml.ftl,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- view.xhtml.ftl	3 Dec 2006 09:02:26 -0000	1.4
  +++ view.xhtml.ftl	4 Dec 2006 03:06:04 -0000	1.5
  @@ -20,20 +20,15 @@
       
       <h:messages globalOnly="true" styleClass="message"/>
       
  -    <h:form id="${componentName}">
  -        <div class="dialog">
  +    <div id="${componentName}" class="dialog">
           <table>
  -        <s:validateAll>
   <#foreach property in pojo.allPropertiesIterator>
   <#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
  +<#if !property.equals(pojo.identifierProperty) || property.value.identifierGeneratorStrategy == "assigned">
  +
               <tr class="prop">
                   <td class="name">${property.name}</td>
  -                <td class="value">
  -<#if property.equals(pojo.identifierProperty)>
  -<#if property.value.identifierGeneratorStrategy == "assigned">
  -                        ${'#'}{${homeName}.instance.${property.name}}
  -</#if>
  -<#else>
  +                <td class="value" id="${property.name}">
   <#if property.value.typeName == "date">
   			           <h:outputText value="${'#'}{${homeName}.instance.${property.name}}">
   			               <f:convertDateTime type="date" dateStyle="short"/>
  @@ -57,21 +52,24 @@
   <#else>
                          ${'#'}{${homeName}.instance.${property.name}}
   </#if>
  -</#if>
                   </td>
               </tr>
   </#if>
  +</#if>
   </#foreach>
  -        </s:validateAll>
  +
           </table>
           </div>
  +    
           <div class="actionButtons">  			  
  +           
               <s:button id="edit" value="Edit" 
                   view="/${editPageName}.xhtml" 
                   propagation="begin">
               	<f:param name="${componentName}Id" 
               	    value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
               </s:button>		  
  +        
               <s:button id="delete" value="Delete" 
                   action="${'#'}{${homeName}.remove}"
                   rendered="${'#'}{${homeName}.managed}"
  @@ -79,17 +77,21 @@
               	<f:param name="${componentName}Id" 
               	    value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
               </s:button>		  
  -        </div>
  -    </h:form>
       
  +    </div>
   <#foreach property in pojo.allPropertiesIterator>
  -
   <#if c2h.isManyToOne(property)>
   <#assign parentPojo = c2j.getPOJOClass(cfg.getClassMapping(property.value.referencedEntityName))>
   <#assign parentPageName = parentPojo.shortName>
   <#assign parentName = util.lower(parentPojo.shortName)>
  +
  +    <div class="association" id="${property.name}">
  +    
              <h2>${property.name}</h2>
  -           <h:outputText value="No ${property.name}" rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
  +        
  +        <h:outputText value="No ${property.name}" 
  +                   rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
  +        
              <h:dataTable var="${parentName}" 
                         value="${'#'}{${homeName}.instance.${property.name}}" 
                      rendered="${'#'}{${homeName}.instance.${property.name} != null}"
  @@ -117,16 +119,23 @@
   		           </s:link>
                  </h:column>
              </h:dataTable>
  -</#if>
   
  +    </div>
  +</#if>
   <#if c2h.isOneToManyCollection(property)>
  +
  +    <div class="association" id="${property.name}">
  +    
             <h2>${property.name}</h2>
  +        
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
   <#assign childPageName = childPojo.shortName>
   <#assign childEditPageName = childPojo.shortName + "Edit">
   <#assign childName = util.lower(childPojo.shortName)>
   <#assign childHomeName = childName + "Home">
  -          <h:outputText value="No ${property.name}" rendered="${'#'}{empty ${homeName}.${property.name}}"/>
  +        <h:outputText value="No ${property.name}" 
  +                   rendered="${'#'}{empty ${homeName}.${property.name}}"/>
  +        
             <h:dataTable value="${'#'}{${homeName}.${property.name}}" 
                            var="${childName}" 
                       rendered="${'#'}{not empty ${homeName}.${property.name}}" 
  @@ -148,6 +157,8 @@
               </h:column>
             </h:dataTable>
   
  +    </div>
  +
   		    <div class="actionButtons">
   		        <s:button id="add${childName}" value="Add ${childName}"
   		            view="/${childEditPageName}.xhtml" propagation="begin">
  
  
  


From gavin.king at jboss.com  Sun Dec  3 22:11:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 22:11:04 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1Gr4ES-0004iE-Vo@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 22:11:04

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  size for date fields
  
  Revision  Changes    Path
  1.15      +4 -0      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- edit.xhtml.ftl	4 Dec 2006 03:06:04 -0000	1.14
  +++ edit.xhtml.ftl	4 Dec 2006 03:11:04 -0000	1.15
  @@ -37,6 +37,8 @@
                               <s:decorate>
   <#if property.value.typeName == "date">
   	        		           <h:inputText id="${property.name}" 
  +	        		                 maxlength="10"
  +	        		                      size="10"
   <#if propertyIsId>
                                         disabled="${'#'}{${homeName}.managed}"
   </#if>
  @@ -48,6 +50,7 @@
   		        	           </h:inputText>
   <#elseif property.value.typeName == "time">
   		        	           <h:inputText id="${property.name}" 
  +	        		                      size="5"
   <#if !column.nullable>
                                         required="true"
   </#if>
  @@ -56,6 +59,7 @@
   		        	           </h:inputText>
   <#elseif property.value.typeName == "timestamp">
   		        	           <h:inputText id="${property.name}" 
  +	        		                      size="16"
   <#if !column.nullable>
                                         required="true"
   </#if>
  
  
  


From gavin.king at jboss.com  Sun Dec  3 22:36:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 03 Dec 2006 22:36:03 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view    ...
Message-ID: <E1Gr4cd-00056u-8L@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/03 22:36:03

  Modified:    seam-gen/view    edit.xhtml.ftl list.xhtml.ftl
                        view.xhtml.ftl
  Log:
  minor improvs
  
  Revision  Changes    Path
  1.16      +1 -1      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- edit.xhtml.ftl	4 Dec 2006 03:11:04 -0000	1.15
  +++ edit.xhtml.ftl	4 Dec 2006 03:36:03 -0000	1.16
  @@ -18,7 +18,7 @@
       <h1>${entityName}</h1>
       <p>Generated edit page</p>
       
  -    <h:messages globalOnly="true" styleClass="message"/>
  +    <h:messages globalOnly="true" styleClass="message" id="globalMessages"/>
       
       <h:form id="${componentName}" styleClass="edit">
       
  
  
  
  1.6       +46 -24    jboss-seam/seam-gen/view/list.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.xhtml.ftl,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- list.xhtml.ftl	14 Nov 2006 05:03:48 -0000	1.5
  +++ list.xhtml.ftl	4 Dec 2006 03:36:03 -0000	1.6
  @@ -19,11 +19,13 @@
       <h1>${entityName} list</h1>
       <p>Generated list page</p>
       
  -    <h:messages globalOnly="true" styleClass="message"/>
  +    <h:messages globalOnly="true" styleClass="message" id="globalMessages"/>
       
       <h:outputText value="No ${componentName} exists" 
               rendered="${'#'}{empty ${listName}.resultList}"/>
  -    <h:dataTable id="${listName}" var="${componentName}"
  +               
  +    <h:dataTable id="${listName}" 
  +                var="${componentName}"
               value="${'#'}{${listName}.resultList}" 
               rendered="${'#'}{not empty ${listName}.resultList}">
   <#foreach property in pojo.allPropertiesIterator>
  @@ -43,35 +45,55 @@
   </#foreach>
           <h:column>
               <f:facet name="header">action</f:facet>
  -            <s:link id="${componentName}" value="Select" view="/${pageName}.xhtml">
  -                <f:param name="${componentName}Id" value="${'#'}{${componentName}.${pojo.identifierProperty.name}}"/>
  +            <s:link view="/${pageName}.xhtml" 
  +                   value="Select" 
  +                      id="${componentName}">
  +                <f:param name="${componentName}Id" 
  +                        value="${'#'}{${componentName}.${pojo.identifierProperty.name}}"/>
               </s:link>
           </h:column>
       </h:dataTable>
   
       <div class="tableControl">
         
  -        <s:link view="/${listPageName}.xhtml" rendered="${'#'}{${listName}.previousExists}" value="&lt;&lt; First Page">
  +        <s:link view="/${listPageName}.xhtml" 
  +            rendered="${'#'}{${listName}.previousExists}" 
  +               value="&lt;&lt; First Page"
  +               id="firstPage">
             <f:param name="firstResult" value="0"/>
           </s:link>
           
  -        <s:link view="/${listPageName}.xhtml" rendered="${'#'}{${listName}.previousExists}" value="&lt; Previous Page">
  -          <f:param name="firstResult" value="${'#'}{${listName}.previousFirstResult}"/>
  +        <s:link view="/${listPageName}.xhtml" 
  +            rendered="${'#'}{${listName}.previousExists}" 
  +               value="&lt; Previous Page"
  +                  id="previousPage">
  +            <f:param name="firstResult" 
  +                    value="${'#'}{${listName}.previousFirstResult}"/>
           </s:link>
           
  -        <s:link view="/${listPageName}.xhtml" rendered="${'#'}{${listName}.nextExists}" value="Next Page &gt;">
  -          <f:param name="firstResult" value="${'#'}{${listName}.nextFirstResult}"/>
  +        <s:link view="/${listPageName}.xhtml" 
  +            rendered="${'#'}{${listName}.nextExists}" 
  +               value="Next Page &gt;"
  +                  id="nextPage">
  +            <f:param name="firstResult" 
  +                    value="${'#'}{${listName}.nextFirstResult}"/>
           </s:link>
           
  -        <s:link view="/${listPageName}.xhtml" rendered="${'#'}{${listName}.nextExists}" value="Last Page &gt;&gt;">
  -          <f:param name="firstResult" value="${'#'}{${listName}.lastFirstResult}"/>
  +        <s:link view="/${listPageName}.xhtml" 
  +            rendered="${'#'}{${listName}.nextExists}" 
  +               value="Last Page &gt;&gt;"
  +                  id="lastPage">
  +            <f:param name="firstResult" 
  +                    value="${'#'}{${listName}.lastFirstResult}"/>
           </s:link>
           
       </div>
       
       <div class="actionButtons">
  -        <s:button id="create" value="Create ${componentName}"
  -            view="/${editPageName}.xhtml" propagation="begin"/>			  
  +        <s:button view="/${editPageName}.xhtml"
  +                    id="create" 
  +                 value="Create ${componentName}"
  +           propagation="begin"/>
       </div>
       
   </ui:define>
  
  
  
  1.6       +1 -1      jboss-seam/seam-gen/view/view.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: view.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/view.xhtml.ftl,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- view.xhtml.ftl	4 Dec 2006 03:06:04 -0000	1.5
  +++ view.xhtml.ftl	4 Dec 2006 03:36:03 -0000	1.6
  @@ -18,7 +18,7 @@
       <h1>${entityName}</h1>
       <p>Generated view page</p>
       
  -    <h:messages globalOnly="true" styleClass="message"/>
  +    <h:messages globalOnly="true" styleClass="message" id="globalMessages"/>
       
       <div id="${componentName}" class="dialog">
           <table>
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 23:23:51 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 23:23:51 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security     ...
Message-ID: <E1Gr5Mt-0005r8-Ma@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 23:23:51

  Modified:    src/main/org/jboss/seam/security     Identity.java
                        SeamSecurityManager.java UsernamePasswordToken.java
  Added:       src/main/org/jboss/seam/security     Role.java
  Log:
  added a proper Role class
  
  Revision  Changes    Path
  1.2       +3 -3      jboss-seam/src/main/org/jboss/seam/security/Identity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Identity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/Identity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Identity.java	4 Dec 2006 01:06:50 -0000	1.1
  +++ Identity.java	4 Dec 2006 04:23:51 -0000	1.2
  @@ -35,7 +35,7 @@
       return instance;
     }
   
  -  public abstract String[] getRoles();
  +  public abstract Role[] getRoles();
     public abstract Object getCredentials();
     public abstract Object getPrincipal();
   
  @@ -63,9 +63,9 @@
      */
     public boolean isUserInRole(String role)
     {
  -    for (String r : getRoles())
  +    for (Role r : getRoles())
       {
  -      if (r.equals(role))
  +      if (r.getName().equals(role))
           return true;
       }
       return false;
  
  
  
  1.21      +8 -1      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- SeamSecurityManager.java	4 Dec 2006 01:21:52 -0000	1.20
  +++ SeamSecurityManager.java	4 Dec 2006 04:23:51 -0000	1.21
  @@ -20,6 +20,7 @@
   import org.jboss.seam.security.acl.AclProvider;
   import org.jboss.seam.security.acl.IdentityGenerator;
   import org.jboss.seam.security.acl.JPAIdentityGenerator;
  +import org.jboss.seam.annotations.Create;
   
   /**
    * Holds configuration settings and provides functionality for the security API
  @@ -54,6 +55,12 @@
      */
     private Map<Class,PermissionHandler> permissionHandlers = new HashMap<Class,PermissionHandler>();
   
  +  @Create
  +  public void initSecurityManager()
  +  {
  +
  +  }
  +
     public static SeamSecurityManager instance()
     {
       if (!Contexts.isApplicationContextActive())
  @@ -124,7 +131,7 @@
     private void checkRolePermissions(String permissionName, String action)
     {
       Permission required = new SeamPermission(permissionName, action);
  -    for (String role : Identity.instance().getRoles())
  +    for (Role role : Identity.instance().getRoles())
       {
         Set<Permission> permissions = rolePermissions.get(role);
         if (permissions != null && permissions.contains(required))
  
  
  
  1.8       +3 -3      jboss-seam/src/main/org/jboss/seam/security/UsernamePasswordToken.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UsernamePasswordToken.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/UsernamePasswordToken.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- UsernamePasswordToken.java	4 Dec 2006 01:21:52 -0000	1.7
  +++ UsernamePasswordToken.java	4 Dec 2006 04:23:51 -0000	1.8
  @@ -5,7 +5,7 @@
    */
   public class UsernamePasswordToken extends Identity
   {
  -  private String[] roles;
  +  private Role[] roles;
     private Object credentials;
     private Object principal;
   
  @@ -16,7 +16,7 @@
       this.authenticated = false;
     }
   
  -  public UsernamePasswordToken(Object principal, Object credentials, String[] roles)
  +  public UsernamePasswordToken(Object principal, Object credentials, Role[] roles)
     {
       this(principal, credentials);
       this.roles = roles;
  @@ -30,7 +30,7 @@
     }
   
     @Override
  -  public String[] getRoles()
  +  public Role[] getRoles()
     {
       return roles;
     }
  
  
  
  1.1      date: 2006/12/04 04:23:51;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/security/Role.java
  
  Index: Role.java
  ===================================================================
  package org.jboss.seam.security;
  
  import java.io.Serializable;
  import java.security.Principal;
  import java.security.acl.Group;
  import java.security.acl.Permission;
  import java.util.Collections;
  import java.util.Enumeration;
  import java.util.HashSet;
  import java.util.Set;
  
  /**
   * A Role implementation.  Roles can contain other roles.
   *
   * @author Shane Bryzak
   */
  public class Role implements Group, Serializable
  {
    /**
     * The name of the role
     */
    private String name;
  
    /**
     * The members of this role.  This role has the authority to perform any action
     * that any of its members (or member's members, ad infinitum) can perform.
     */
    private Set<Principal> members = new HashSet<Principal>();
  
    /**
     * A set of permissions explicitly assigned to this role.
     */
    private Set<Permission> permissions = new HashSet<Permission>();
  
    public Role(String name)
    {
      this.name = name;
    }
  
    public boolean addPermission(Permission permission)
    {
      return permissions.add(permission);
    }
  
    public boolean hasPermission(Permission permission)
    {
      return permissions.contains(permission);
    }
  
    public boolean removePermission(Permission permission)
    {
      return permissions.remove(permission);
    }
  
    public boolean addMember(Principal user)
    {
      return members.add(user);
    }
  
    public boolean isMember(Principal member)
    {
      if (members.contains(member))
        return true;
      else
      {
        for (Principal m : members)
        {
          if (m instanceof Group && ((Group) m).isMember(member))
            return true;
        }
      }
      return false;
    }
  
    public Enumeration<? extends Principal> members()
    {
      return Collections.enumeration(members);
    }
  
    public boolean removeMember(Principal user)
    {
      return members.remove(user);
    }
  
    public String getName()
    {
      return name;
    }
  
    public boolean equals(Object obj)
    {
      if (!(obj instanceof Role))
        return false;
  
      Role other = (Role) obj;
  
      return other.name.equals(name);
    }
  
    public int hashCode()
    {
      return name.hashCode();
    }
  }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 23:23:51 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 23:23:51 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl  ...
Message-ID: <E1Gr5Mt-0005rF-Pw@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 23:23:51

  Modified:    src/main/org/jboss/seam/security/acl 
                        PersistentAclProvider.java
  Log:
  added a proper Role class
  
  Revision  Changes    Path
  1.14      +3 -2      jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PersistentAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- PersistentAclProvider.java	4 Dec 2006 01:21:52 -0000	1.13
  +++ PersistentAclProvider.java	4 Dec 2006 04:23:51 -0000	1.14
  @@ -24,6 +24,7 @@
   import org.jboss.seam.security.SeamPermission;
   import org.jboss.seam.security.SeamSecurityManager;
   import org.jboss.seam.util.Naming;
  +import org.jboss.seam.security.Role;
   
   /**
    * Persistent Acl provider.
  @@ -122,11 +123,11 @@
   
     protected void bindQueryParams(Object query, Object target, Principal principal)
     {
  -    List<String> roles = new ArrayList<String>();
  +    List<Role> roles = new ArrayList<Role>();
   
       if (Identity.class.isAssignableFrom(principal.getClass()))
       {
  -      for (String role : ((Identity) principal).getRoles())
  +      for (Role role : ((Identity) principal).getRoles())
         {
           roles.add(role);
         }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 23:26:00 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 23:26:00 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui  ...
Message-ID: <E1Gr5Oy-0005u2-Oq@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 23:26:00

  Modified:    src/ui/org/jboss/seam/ui  UISecure.java
  Log:
  fixed compiler errors
  
  Revision  Changes    Path
  1.2       +3 -3      jboss-seam/src/ui/org/jboss/seam/ui/UISecure.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UISecure.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/UISecure.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UISecure.java	13 Oct 2006 04:53:46 -0000	1.1
  +++ UISecure.java	4 Dec 2006 04:26:00 -0000	1.2
  @@ -4,7 +4,7 @@
   import javax.faces.component.UIComponentBase;
   import javax.faces.context.FacesContext;
   
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   
   /**
    * Only renders the child tags if the authenticated user contains at least one
  @@ -32,10 +32,10 @@
       {
         String[] parts = roles.split("[,]");
   
  -      Authentication auth = null;
  +      Identity auth = null;
         try
         {
  -        auth = Authentication.instance();
  +        auth = Identity.instance();
   
           for (int i = 0; i < parts.length; i++)
           {
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec  3 23:29:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 23:29:28 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui  ...
Message-ID: <E1Gr5SK-0005wW-87@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 23:29:28

  Removed:     src/ui/org/jboss/seam/ui  UISecure.java
  Log:
  remove UISecure tag, will be replaced by UIRestrict


From Shane_Bryzak at symantec.com  Sun Dec  3 23:29:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 03 Dec 2006 23:29:28 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui/tag  ...
Message-ID: <E1Gr5SK-0005wa-DK@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/03 23:29:28

  Removed:     src/ui/org/jboss/seam/ui/tag  SecureTag.java
  Log:
  remove UISecure tag, will be replaced by UIRestrict


From forge-admin at jboss.com  Mon Dec  4 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Mon, 04 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gr6sO-0007IX-R9@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-03 02:01 EST)
-----------------

fix bad handling of contexts during logout
don't redirect to the debug page when not in a JSF request

  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java  1.69
  jboss-seam  src/main/org/jboss/seam/core/Exceptions.java     1.16


Commit from gavin (2006-12-03 04:02 EST)
-----------------

JBSEAM-554

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.10
  jboss-seam  seam-gen/view/view.xhtml.ftl  1.4


Commit from gavin (2006-12-03 04:20 EST)
-----------------

use textArea for long fields, and adjust field size

  jboss-seam  seam-gen/view/edit.xhtml.ftl        1.11
  jboss-seam  seam-gen/view/stylesheet/theme.css  1.3


Commit from bwang on branch Branch_JBossCache_1_4_0 (2006-12-03 05:29 EST)
---------------------------------------------------

Test for JBCACHE-885 but it works.

  JBossCache  tests/functional/org/jboss/cache/aop/NewReplicatedAopTest.java  1.10.2.1
  JBossCache  tests/functional/org/jboss/cache/aop/NewLocalAopTest.java       1.8.2.3


Commit from bwang (2006-12-03 05:30 EST)
-----------------

added test for array.

  JBossCache  tests-50/functional/org/jboss/cache/pojo/NewReplicatedTest.java  1.7


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-03 11:00 EST)
------------------------------------------------------

wc

  JBossCache  tests/functional/org/jboss/cache/aop/statetransfer/StateTransferAopTestBase.java  1.13.2.1
  JBossCache  tests/functional/org/jboss/cache/aop/loader/CacheLoaderTestsBase.java             1.8.2.1
  JBossCache  src/org/jboss/cache/aop/TreeCacheAop.java                                         1.23.2.2


Commit from gavin (2006-12-03 14:28 EST)
-----------------

generate required=true

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.12


Commit from sbryzak2 (2006-12-03 20:06 EST)
--------------------

bye bye old security design

  jboss-seam  src/main/org/jboss/seam/Component.java                                          1.215
  jboss-seam  src/main/org/jboss/seam/annotations/security/Permission.java                    1.2
+ jboss-seam  src/main/org/jboss/seam/annotations/security/Permissions.java                   1.1
+ jboss-seam  src/main/org/jboss/seam/annotations/security/Restrict.java                      1.1
- jboss-seam  src/main/org/jboss/seam/annotations/security/AclProvider.java                   1.2
- jboss-seam  src/main/org/jboss/seam/annotations/security/DefinePermissions.java             1.3
- jboss-seam  src/main/org/jboss/seam/annotations/security/Secure.java                        1.3
  jboss-seam  src/main/org/jboss/seam/interceptors/SecurityInterceptor.java                   1.12
  jboss-seam  src/main/org/jboss/seam/mock/MockAclPermission.java                             1.2
  jboss-seam  src/main/org/jboss/seam/mock/MockSecureEntity.java                              1.3
  jboss-seam  src/main/org/jboss/seam/security/PermissionHandler.java                         1.3
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java                       1.18
+ jboss-seam  src/main/org/jboss/seam/security/Identity.java                                  1.1
  jboss-seam  src/main/org/jboss/seam/security/acl/AbstractAclProvider.java                   1.2
  jboss-seam  src/main/org/jboss/seam/security/acl/PersistentAclProvider.java                 1.12
  jboss-seam  src/main/org/jboss/seam/security/adapter/jboss/JBossAuthenticationAdapter.java  1.3
  jboss-seam  src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java                 1.11


Commit from sbryzak2 (2006-12-03 20:10 EST)
--------------------

undid name change to AclProvider

  jboss-seam  src/main/org/jboss/seam/mock/MockAclPermission.java            1.3
  jboss-seam  src/main/org/jboss/seam/security/PermissionHandler.java        1.4
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java      1.19
  jboss-seam  src/main/org/jboss/seam/security/acl/AbstractAclProvider.java  1.3


Commit from sbryzak2 (2006-12-03 20:11 EST)
--------------------

removed redundant security example

- jboss-seam  examples/security/build.xml                                                     1.5
- jboss-seam  examples/security/resources/META-INF/application.xml                            1.3
- jboss-seam  examples/security/resources/META-INF/ejb-jar.xml                                1.4
- jboss-seam  examples/security/resources/META-INF/jboss-app.xml                              1.3
- jboss-seam  examples/security/resources/META-INF/persistence.xml                            1.4
- jboss-seam  examples/security/resources/WEB-INF/components.xml                              1.12
- jboss-seam  examples/security/resources/WEB-INF/faces-config.xml                            1.5
- jboss-seam  examples/security/resources/WEB-INF/seam-security.xml                           1.2
- jboss-seam  examples/security/resources/WEB-INF/web.xml                                     1.5
- jboss-seam  examples/security/resources/import.sql                                          1.4
- jboss-seam  examples/security/resources/seam.properties                                     1.2
- jboss-seam  examples/security/resources/security-ds.xml                                     1.2
- jboss-seam  examples/security/src/org/jboss/seam/example/security/AuthenticatorAction.java  1.5
- jboss-seam  examples/security/src/org/jboss/seam/example/security/Customer.java             1.3
- jboss-seam  examples/security/src/org/jboss/seam/example/security/CustomerAclProvider.java  1.2
- jboss-seam  examples/security/src/org/jboss/seam/example/security/LoginAction.java          1.8
- jboss-seam  examples/security/src/org/jboss/seam/example/security/LoginLocal.java           1.3
- jboss-seam  examples/security/src/org/jboss/seam/example/security/ProtectedAction.java      1.8
- jboss-seam  examples/security/src/org/jboss/seam/example/security/ProtectedLocal.java       1.4
- jboss-seam  examples/security/src/org/jboss/seam/example/security/Role.java                 1.2
- jboss-seam  examples/security/src/org/jboss/seam/example/security/User.java                 1.6
- jboss-seam  examples/security/view/home.xhtml                                               1.6
- jboss-seam  examples/security/view/index.html                                               1.2
- jboss-seam  examples/security/view/protected.xhtml                                          1.4
- jboss-seam  examples/security/view/welcome.xhtml                                            1.5
- jboss-seam  examples/security/view/protected/protected.xhtml                                1.2


Commit from sbryzak2 (2006-12-03 20:15 EST)
--------------------

removed until core security framework is complete

- jboss-seam  src/main/org/jboss/seam/security/adapter/AuthenticationAdapter.java             1.2
- jboss-seam  src/main/org/jboss/seam/security/adapter/jboss/JBossAuthenticationAdapter.java  1.4
- jboss-seam  src/main/org/jboss/seam/security/adapter/jboss/SeamLoginModule.java             1.6
- jboss-seam  src/main/org/jboss/seam/security/provider/AuthenticationProvider.java           1.6
- jboss-seam  src/main/org/jboss/seam/security/provider/catalina/CatalinaProvider.java        1.6
- jboss-seam  src/main/org/jboss/seam/security/provider/jaas/JaasAuthenticationProvider.java  1.5
- jboss-seam  src/main/org/jboss/seam/security/provider/jaas/JaasCallbackHandler.java         1.2


Commit from sbryzak2 (2006-12-03 20:21 EST)
--------------------

Authentication superseded by Identity

  jboss-seam  src/main/org/jboss/seam/security/PermissionHandler.java                    1.5
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java                  1.20
  jboss-seam  src/main/org/jboss/seam/security/UsernamePasswordToken.java                1.7
- jboss-seam  src/main/org/jboss/seam/security/Authentication.java                       1.9
  jboss-seam  src/main/org/jboss/seam/security/acl/AbstractAclProvider.java              1.4
  jboss-seam  src/main/org/jboss/seam/security/acl/PersistentAclProvider.java            1.13
  jboss-seam  src/main/org/jboss/seam/security/authenticator/Authenticator.java          1.15
  jboss-seam  src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java  1.11
+ jboss-seam  src/main/org/jboss/seam/security/adapter/AuthenticationAdapter.java        1.3
+ jboss-seam  src/main/org/jboss/seam/security/provider/AuthenticationProvider.java      1.7


Commit from sbryzak2 (2006-12-03 20:23 EST)
--------------------

fixed invalid import

  jboss-seam  src/main/org/jboss/seam/security/provider/AuthenticationProvider.java  1.8


Commit from gavin (2006-12-03 20:45 EST)
-----------------

better formatting
better handling of id properties
JBSEAM-561

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.13


Commit from gavin (2006-12-03 22:06 EST)
-----------------

various improvements

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.14
  jboss-seam  seam-gen/view/view.xhtml.ftl  1.5


Commit from gavin (2006-12-03 22:11 EST)
-----------------

size for date fields

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.15


Commit from gavin (2006-12-03 22:36 EST)
-----------------

minor improvs

  jboss-seam  seam-gen/view/edit.xhtml.ftl  1.16
  jboss-seam  seam-gen/view/list.xhtml.ftl  1.6
  jboss-seam  seam-gen/view/view.xhtml.ftl  1.6


Commit from sbryzak2 (2006-12-03 23:23 EST)
--------------------

added a proper Role class

  jboss-seam  src/main/org/jboss/seam/security/Identity.java                   1.2
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java        1.21
  jboss-seam  src/main/org/jboss/seam/security/UsernamePasswordToken.java      1.8
+ jboss-seam  src/main/org/jboss/seam/security/Role.java                       1.1
  jboss-seam  src/main/org/jboss/seam/security/acl/PersistentAclProvider.java  1.14


Commit from sbryzak2 (2006-12-03 23:26 EST)
--------------------

fixed compiler errors

  jboss-seam  src/ui/org/jboss/seam/ui/UISecure.java  1.2


Commit from sbryzak2 (2006-12-03 23:29 EST)
--------------------

remove UISecure tag, will be replaced by UIRestrict

- jboss-seam  src/ui/org/jboss/seam/ui/UISecure.java       1.3
- jboss-seam  src/ui/org/jboss/seam/ui/tag/SecureTag.java  1.3
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061204/ac16e595/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 01:04:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 01:04:27 -0500
Subject: [jboss-cvs] JBossAS SVN: r58822 -
	branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader
Message-ID: <E1Gr6wF-0007Uu-ME@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 01:04:24 -0500 (Mon, 04 Dec 2006)
New Revision: 58822

Modified:
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java
Log:
Add missing license block

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java	2006-12-03 21:13:04 UTC (rev 58821)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java	2006-12-04 06:04:24 UTC (rev 58822)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
 import java.io.Serializable;
@@ -14,6 +35,12 @@
 import org.hibernate.annotations.Cache;
 import org.hibernate.annotations.CacheConcurrencyStrategy;
 
+/**
+ * Entity used to test handling of @Lob fields in the second level cache.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
 @Entity
 @Cache (usage=CacheConcurrencyStrategy.TRANSACTIONAL)
 @NamedQueries({

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java	2006-12-03 21:13:04 UTC (rev 58821)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java	2006-12-04 06:04:24 UTC (rev 58822)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
 import java.io.IOException;
@@ -6,6 +27,12 @@
 
 import javax.persistence.Embeddable;
 
+/**
+ * Class used as an @Lob field in {@link Account}.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
 //@Embeddable
 public class AccountHolderPK implements Serializable
 {   

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java	2006-12-03 21:13:04 UTC (rev 58821)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java	2006-12-04 06:04:24 UTC (rev 58822)
@@ -1,5 +1,32 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
+/**
+ * SFSB interface for {@link EntityQueryTestBean}.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
 public interface EntityQueryTest
 {
 

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java	2006-12-03 21:13:04 UTC (rev 58821)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java	2006-12-04 06:04:24 UTC (rev 58822)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
 import java.util.HashSet;
@@ -22,6 +43,12 @@
 import org.jboss.mx.util.MBeanProxyExt;
 import org.jboss.mx.util.MBeanServerLocator;
 
+/**
+ * SFSB used for testing @Lob field replication in the second level test.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
 @Stateful
 @Remote(EntityQueryTest.class)
 public class EntityQueryTestBean implements EntityQueryTest



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 01:48:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 01:48:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r58823 -
	branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/entity
Message-ID: <E1Gr7d9-00083v-Jx@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 01:48:46 -0500 (Mon, 04 Dec 2006)
New Revision: 58823

Modified:
   branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java
Log:
Disable state transfer for StandardQueryCache region

Modified: branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java
===================================================================
--- branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java	2006-12-04 06:04:24 UTC (rev 58822)
+++ branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java	2006-12-04 06:48:46 UTC (rev 58823)
@@ -46,11 +46,26 @@
 		this.regionFqn = Fqn.fromString( regionName.replace( '.', '/' ) );
 		this.transactionManager = transactionManager;
         if (cache.getUseRegionBasedMarshalling())
-        {
-           // We always activate
-           activateCacheRegion(regionFqn.toString());
+        {           
+           localWritesOnly = StandardQueryCache.class.getName().equals(regionName);
            
-           localWritesOnly = StandardQueryCache.class.getName().equals(regionName);
+           boolean fetchState = cache.getFetchInMemoryState();
+           try
+           {
+              // We don't want a state transfer for the StandardQueryCache,
+              // as it can include classes from multiple scoped classloaders
+              if (localWritesOnly)
+                 cache.setFetchInMemoryState(false);
+              
+              // We always activate
+              activateCacheRegion(regionFqn.toString());
+           }
+           finally
+           {
+              // Restore the normal state transfer setting
+              if (localWritesOnly)
+                 cache.setFetchInMemoryState(fetchState);              
+           }
         }
 	}
 



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 01:50:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 01:50:11 -0500
Subject: [jboss-cvs] JBossAS SVN: r58824 - in branches/Branch_4_0/ejb3/src:
	resources/test/clusteredentity
	resources/test/clusteredentity/embeddedid
	test/org/jboss/ejb3/test/clusteredentity
Message-ID: <E1Gr7eV-00085E-Tv@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 01:50:10 -0500 (Mon, 04 Dec 2006)
New Revision: 58824

Added:
   branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/embeddedid/
   branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/embeddedid/META-INF/
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/
Log:
Add a test with @EmbeddedId



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 01:50:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 01:50:15 -0500
Subject: [jboss-cvs] JBossAS SVN: r58825 - in branches/Branch_4_0/ejb3: .
	src/resources/test/clusteredentity/embeddedid/META-INF
	src/test/org/jboss/ejb3/test/clusteredentity/embeddedid
Message-ID: <E1Gr7eZ-00085g-88@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 01:50:13 -0500 (Mon, 04 Dec 2006)
New Revision: 58825

Added:
   branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/embeddedid/META-INF/application.xml
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTest.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTestBean.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/Musician.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/MusicianPK.java
Modified:
   branches/Branch_4_0/ejb3/build-test.xml
Log:
Add a test with @EmbeddedId

Modified: branches/Branch_4_0/ejb3/build-test.xml
===================================================================
--- branches/Branch_4_0/ejb3/build-test.xml	2006-12-04 06:50:10 UTC (rev 58824)
+++ branches/Branch_4_0/ejb3/build-test.xml	2006-12-04 06:50:13 UTC (rev 58825)
@@ -2596,7 +2596,29 @@
         <include name="clusteredentity-ds.xml"/>
        </fileset>
     </jar>
-   	
+
+    <jar jarfile="${build.lib}/clusteredentity-embeddedid-test.jar">
+       <fileset dir="${build.classes}">
+          <include name="org/jboss/ejb3/test/clusteredentity/embeddedid/*.class"/>
+       </fileset>
+       <fileset dir="${resources}/test/clusteredentity/classloader">
+          <include name="META-INF/persistence.xml"/>
+          <!--include name="META-INF/jboss.xml"/-->
+       </fileset>
+    </jar>
+
+    <jar jarfile="${build.lib}/clusteredentity-embeddedid-test.ear">
+       <fileset dir="${build.lib}">
+          <include name="clusteredentity-embeddedid-test.jar"/>
+       </fileset>
+       <fileset dir="${resources}/test/clusteredentity/classloader">
+          <include name="META-INF/jboss-app.xml"/>
+          <include name="clusteredentity-ds.xml"/>
+       </fileset>
+       <fileset dir="${resources}/test/clusteredentity/embeddedid">
+         <include name="META-INF/application.xml"/>
+       </fileset>
+    </jar>
 	   
    </target>
 

Added: branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/embeddedid/META-INF/application.xml
===================================================================
--- branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/embeddedid/META-INF/application.xml	2006-12-04 06:50:10 UTC (rev 58824)
+++ branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/embeddedid/META-INF/application.xml	2006-12-04 06:50:13 UTC (rev 58825)
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<application>
+   <display-name>Second clustered entity with scoped classloader test ear</display-name>
+   <module>
+      <ejb>clusteredentity-embeddedid-test.jar</ejb>
+   </module>
+</application>
\ No newline at end of file

Added: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTest.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTest.java	2006-12-04 06:50:10 UTC (rev 58824)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTest.java	2006-12-04 06:50:13 UTC (rev 58825)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.embeddedid;
+
+import java.util.List;
+
+
+/**
+ * SFSB interface for {@link EmbeddedIdTestBean}.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
+public interface EmbeddedIdTest
+{
+   static final MusicianPK DEFAULT_PK = new MusicianPK("Brian", "Stansberry", "None of your business");
+   
+   void createMusician(MusicianPK pk, String instrument);
+   
+   List<MusicianPK> getMusiciansForInstrument(String instrument, boolean useNamedRegion);
+   
+   void cleanup();
+   
+   void remove();
+}

Added: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTestBean.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTestBean.java	2006-12-04 06:50:10 UTC (rev 58824)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/EmbeddedIdTestBean.java	2006-12-04 06:50:13 UTC (rev 58825)
@@ -0,0 +1,109 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.embeddedid;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.ejb.Remote;
+import javax.ejb.Remove;
+import javax.ejb.Stateful;
+import javax.persistence.EntityManager;
+import javax.persistence.PersistenceContext;
+import javax.persistence.Query;
+
+import org.jboss.logging.Logger;
+
+/**
+ * SFSB used for testing replicated query caching with an @EmbeddedId.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
+ at Stateful
+ at Remote(EmbeddedIdTest.class)
+public class EmbeddedIdTestBean implements EmbeddedIdTest
+{
+   private static final Logger log = Logger.getLogger(EmbeddedIdTestBean.class);
+   
+   @PersistenceContext
+   private EntityManager manager;
+
+   public void createMusician(MusicianPK pk, String instrument)
+   {
+      Musician musician = new Musician();
+      musician.setId(pk);
+      musician.setInstrument(instrument);
+      manager.persist(musician);
+   }
+
+   public List<MusicianPK> getMusiciansForInstrument(String instrument, boolean useNamedRegion)
+   {
+      String queryName = useNamedRegion ? "musician.byinstrument.namedregion"
+                                        : "musician.byinstrument.default";
+      Query query = manager.createNamedQuery(queryName);
+      query.setParameter(1, instrument);
+      List<MusicianPK> result = new ArrayList<MusicianPK>();
+      List users = query.getResultList();
+      if (users != null)
+      {
+         for (Iterator it = users.iterator(); it.hasNext();)
+         {
+            result.add(((Musician) it.next()).getId());
+         }
+      }
+      return result;
+   }
+
+   /* (non-Javadoc)
+    * @see org.jboss.ejb3.test.clusteredentity.classloader.UserTest#cleanup()
+    */
+   public void cleanup()
+   {
+      Query query = manager.createQuery("select musician from Musician as musician");
+      List accts = query.getResultList();
+      if (accts != null)
+      {
+         for (Iterator it = accts.iterator(); it.hasNext();)
+         {
+            try
+            {
+               Musician musician = (Musician) it.next();
+               log.info("Removing " + musician);
+               manager.remove(musician);
+            }
+            catch (Exception ignored) {}
+         }
+      }
+   }
+
+   /* (non-Javadoc)
+    * @see org.jboss.ejb3.test.clusteredentity.classloader.UserTest#remove()
+    */
+   @Remove
+   public void remove()
+   {
+      cleanup();
+   }
+
+}

Added: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/Musician.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/Musician.java	2006-12-04 06:50:10 UTC (rev 58824)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/Musician.java	2006-12-04 06:50:13 UTC (rev 58825)
@@ -0,0 +1,73 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.embeddedid;
+
+import javax.persistence.EmbeddedId;
+import javax.persistence.Entity;
+import javax.persistence.NamedQueries;
+import javax.persistence.NamedQuery;
+import javax.persistence.QueryHint;
+
+import org.hibernate.annotations.Cache;
+import org.hibernate.annotations.CacheConcurrencyStrategy;
+
+/**
+ * Entity used for testing replicated query caching with an @EmbeddedId.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
+ at Entity
+ at Cache (usage=CacheConcurrencyStrategy.TRANSACTIONAL)
+ at NamedQueries({
+   @NamedQuery(name="musician.byinstrument.default",query="select musician from Musician as musician where musician.instrument = ?1",
+               hints={@QueryHint(name="org.hibernate.cacheable",value="true")}),
+   @NamedQuery(name="musician.byinstrument.namedregion",query="select musician from Musician as musician where musician.instrument = ?1",
+         hints={@QueryHint(name="org.hibernate.cacheable",value="true"),
+                @QueryHint(name="org.hibernate.cacheable",value="true")
+               })
+})
+public class Musician
+{
+   private MusicianPK id;
+   private String instrument;
+   
+   @EmbeddedId
+   public MusicianPK getId()
+   {
+      return id;
+   }
+   public void setId(MusicianPK id)
+   {
+      this.id = id;
+   }
+   
+   public String getInstrument()
+   {
+      return instrument;
+   }
+   public void setInstrument(String instrument)
+   {
+      this.instrument = instrument;
+   }
+   
+}

Added: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/MusicianPK.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/MusicianPK.java	2006-12-04 06:50:10 UTC (rev 58824)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/embeddedid/MusicianPK.java	2006-12-04 06:50:13 UTC (rev 58825)
@@ -0,0 +1,127 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.embeddedid;
+
+import java.io.Serializable;
+
+import javax.persistence.Embeddable;
+
+/**
+ * Primary key for the {@link Musician} entity.
+ * 
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
+ at Embeddable
+public class MusicianPK implements Serializable
+{
+   private static final long serialVersionUID = 1L;
+   
+   private String firstName;
+   private String lastName;
+   private String ssn;
+   
+   /**
+    * Default constructor
+    */
+   public MusicianPK() {}
+   
+   public MusicianPK(String firstName, String lastName, String ssn)
+   {
+      this.firstName = firstName;
+      this.lastName = lastName;
+      this.ssn = ssn;
+   }
+   
+   public String getFirstName()
+   {
+      return firstName;
+   }
+   
+   public void setFirstName(String firstName)
+   {
+      this.firstName = firstName;
+   }
+   
+   public String getLastName()
+   {
+      return lastName;
+   }
+   
+   public void setLastName(String lastName)
+   {
+      this.lastName = lastName;
+   }
+   
+   public String getSsn()
+   {
+      return ssn;
+   }
+   
+   public void setSsn(String ssn)
+   {
+      this.ssn = ssn;
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      boolean equal = (this == obj);
+      
+      if (!equal && obj instanceof MusicianPK)
+      {
+         MusicianPK other = (MusicianPK) obj;
+         
+         equal = firstName.equals(other.firstName)
+                  && lastName.equals(other.lastName)
+                  && ssn.equals(other.ssn);
+      }
+      return equal;
+   }
+
+   @Override
+   public int hashCode()
+   {
+      int result = 19;
+      result = result * 29 + firstName.hashCode();
+      result = result * 29 + lastName.hashCode();
+      result = result * 29 + ssn.hashCode();
+      return result;
+   }
+
+   @Override
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer(getClass().getName());
+      sb.append("[firstName=");
+      sb.append(firstName);
+      sb.append(",lastName=");
+      sb.append(lastName);
+      sb.append(",ssn=");
+      sb.append(ssn);
+      sb.append("]");
+      return sb.toString();
+   }
+   
+   
+   
+}



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 01:50:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 01:50:40 -0500
Subject: [jboss-cvs] JBossAS SVN: r58826 -
	branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit
Message-ID: <E1Gr7ey-00086Z-CA@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 01:50:39 -0500 (Mon, 04 Dec 2006)
New Revision: 58826

Added:
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EmbeddedIdClassloaderTestCase.java
Log:
Add a test with @EmbeddedId

Added: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EmbeddedIdClassloaderTestCase.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EmbeddedIdClassloaderTestCase.java	2006-12-04 06:50:13 UTC (rev 58825)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EmbeddedIdClassloaderTestCase.java	2006-12-04 06:50:39 UTC (rev 58826)
@@ -0,0 +1,162 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.unit;
+
+import java.util.List;
+import java.util.Properties;
+import java.util.Set;
+
+import javax.naming.InitialContext;
+import org.jboss.ejb3.test.clusteredentity.Customer;
+import org.jboss.ejb3.test.clusteredentity.EntityTest;
+import org.jboss.ejb3.test.clusteredentity.classloader.EntityQueryTest;
+import org.jboss.ejb3.test.clusteredentity.embeddedid.MusicianPK;
+import org.jboss.ejb3.test.clusteredentity.embeddedid.EmbeddedIdTest;
+import org.jboss.test.JBossClusteredTestCase;
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+/**
+ * Simple test of replication of entities and related queries with @EmbeddedId 
+ * fields involved.
+ *
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
+ */
+public class EmbeddedIdClassloaderTestCase
+extends JBossClusteredTestCase
+{
+   private org.apache.log4j.Category log = getLog();
+
+   protected static final long SLEEP_TIME = 300L;
+
+   private EmbeddedIdTest sfsb0;
+   private EmbeddedIdTest sfsb1;
+   
+   public EmbeddedIdClassloaderTestCase(String name)
+   {
+      super(name);
+   }
+   
+   protected void setUp() throws Exception
+   {
+      sfsb0 = getUserTest(System.getProperty("jbosstest.cluster.node0"));
+      sfsb1 = getUserTest(System.getProperty("jbosstest.cluster.node1"));  
+      sfsb0.cleanup();
+      sfsb1.cleanup();
+   }
+    
+   protected void tearDown() throws Exception
+   {
+      if (sfsb0 != null)
+      {
+         try
+         {
+            sfsb0.remove();
+         }
+         catch (Exception e) {}
+      }
+      if (sfsb1 != null)
+      {
+         try
+         {
+            sfsb1.remove();
+         }
+         catch (Exception e) {}
+      }
+      
+      sfsb0 = sfsb1 = null;
+   }
+   
+   protected EmbeddedIdTest getUserTest(String nodeJNDIAddress) throws Exception
+   {
+      Properties prop1 = new Properties();
+      prop1.put("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
+      prop1.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
+      prop1.put("java.naming.provider.url", "jnp://" + nodeJNDIAddress + ":1099");
+   
+      log.info("===== Naming properties for " + nodeJNDIAddress + ": ");
+      log.info(prop1);
+      log.info("Create InitialContext for " + nodeJNDIAddress);
+      InitialContext ctx1 = new InitialContext(prop1);
+   
+      log.info("Lookup sfsb from " + nodeJNDIAddress);
+      return (EmbeddedIdTest) ctx1.lookup("clusteredentity-embeddedid-test/EmbeddedIdTestBean/remote");
+      
+   }
+   
+   public void testQuery() throws Exception
+   {
+      try
+      {
+         sfsb0.createMusician(EmbeddedIdTest.DEFAULT_PK, "zither");
+         
+         queryByInstrument(sfsb0, "zither", false);
+         queryByInstrument(sfsb0, "zither", true);
+         
+         // pause to let queries replicate async
+         sleep(SLEEP_TIME);
+         
+         queryByInstrument(sfsb1, "zither", false);
+         queryByInstrument(sfsb1, "zither", true);
+      }
+      finally
+      {
+         // cleanup the db so we can run this test multiple times w/o restarting the cluster
+         sfsb0.cleanup();
+      }
+   }
+   
+   private void queryByInstrument(EmbeddedIdTest sfsb, String instrument, boolean useNamedRegion)
+   {
+      List<MusicianPK> pks = sfsb.getMusiciansForInstrument(instrument, useNamedRegion);
+      assertNotNull("Got pks", pks);
+      assertEquals("Got one pk", 1, pks.size());
+      assertEquals("Got correct pks", EmbeddedIdTest.DEFAULT_PK, pks.get(0));
+   }
+   
+   protected void sleep(long millis)
+   {
+      try
+      {
+         Thread.sleep(millis);
+      }
+      catch (InterruptedException e)
+      {
+         log.warn("Interrupted while sleeping", e);
+      }
+   }
+
+   public static Test suite() throws Exception
+   {
+
+      TestSuite suite = new TestSuite();
+      Test t1 = getDeploySetup(EmbeddedIdClassloaderTestCase.class, 
+                               "clusteredentity-embeddedid-test.ear");
+
+      suite.addTest(t1);
+
+      // Create an initializer for the test suite
+      DBSetup wrapper = new DBSetup(suite);
+      return wrapper;
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 01:50:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 01:50:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r58827 -
	branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit
Message-ID: <E1Gr7fC-00087X-FD@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 01:50:53 -0500 (Mon, 04 Dec 2006)
New Revision: 58827

Modified:
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java
Log:
Javadoc

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java	2006-12-04 06:50:39 UTC (rev 58826)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java	2006-12-04 06:50:53 UTC (rev 58827)
@@ -34,12 +34,12 @@
 import junit.framework.TestSuite;
 
 /**
- * Sample client for the jboss container.
+ * Tests EJB redeployment when entities with @Lob fields are stored
+ * in the second level cache.
  *
- * @author <a href="mailto:bill at burkecentral.com">Bill Burke</a>
- * @version $Id: EntityUnitTestCase.java 57207 2006-09-26 12:06:13Z dimitris at jboss.org $
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
  */
-
 public class EntityQueryRedeployUnitTestCase
 extends EntityClassloaderTestBase
 {

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java	2006-12-04 06:50:39 UTC (rev 58826)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java	2006-12-04 06:50:53 UTC (rev 58827)
@@ -33,12 +33,11 @@
 import junit.framework.TestSuite;
 
 /**
- * Sample client for the jboss container.
+ * Tests caching of queries involving custom types.
  *
- * @author <a href="mailto:bill at burkecentral.com">Bill Burke</a>
- * @version $Id: EntityUnitTestCase.java 57207 2006-09-26 12:06:13Z dimitris at jboss.org $
+ * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
+ * @version $Revision: 1.1 $
  */
-
 public class EntityQueryUnitTestCase
 extends EntityClassloaderTestBase
 {



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 02:07:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 02:07:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58828 -
	tags/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity
Message-ID: <E1Gr7uz-0008VE-EU@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-04 02:07:12 -0500 (Mon, 04 Dec 2006)
New Revision: 58828

Modified:
   tags/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java
Log:
Disable state transfer for StandardQueryCache region

Modified: tags/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java
===================================================================
--- tags/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java	2006-12-04 06:50:53 UTC (rev 58827)
+++ tags/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java	2006-12-04 07:07:12 UTC (rev 58828)
@@ -46,11 +46,26 @@
 		this.regionFqn = Fqn.fromString( regionName.replace( '.', '/' ) );
 		this.transactionManager = transactionManager;
         if (cache.getUseRegionBasedMarshalling())
-        {
-           // We always activate
-           activateCacheRegion(regionFqn.toString());
+        {           
+           localWritesOnly = StandardQueryCache.class.getName().equals(regionName);
            
-           localWritesOnly = StandardQueryCache.class.getName().equals(regionName);
+           boolean fetchState = cache.getFetchInMemoryState();
+           try
+           {
+              // We don't want a state transfer for the StandardQueryCache,
+              // as it can include classes from multiple scoped classloaders
+              if (localWritesOnly)
+                 cache.setFetchInMemoryState(false);
+              
+              // We always activate
+              activateCacheRegion(regionFqn.toString());
+           }
+           finally
+           {
+              // Restore the normal state transfer setting
+              if (localWritesOnly)
+                 cache.setFetchInMemoryState(fetchState);              
+           }
         }
 	}
 



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 03:56:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 03:56:38 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58829 - trunk/system/src/bin
Message-ID: <E1Gr9cs-0001jK-97@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-04 03:56:36 -0500 (Mon, 04 Dec 2006)
New Revision: 58829

Modified:
   trunk/system/src/bin/run.bat
Log:
A grouped if statement doesn't seem to work on all windows versions.

Modified: trunk/system/src/bin/run.bat
===================================================================
--- trunk/system/src/bin/run.bat	2006-12-04 07:07:12 UTC (rev 58828)
+++ trunk/system/src/bin/run.bat	2006-12-04 08:56:36 UTC (rev 58829)
@@ -17,13 +17,9 @@
 set JBOSS_HOME=%CD%
 popd
 
-REM
 REM Add bin/native to the PATH if present
-REM
-if exist "%JBOSS_HOME%\bin\native" (
-   set PATH=%JBOSS_HOME%\bin\native;%PATH%
-   set JAVA_OPTS=%JAVA_OPTS% -Djava.library.path=%JBOSS_HOME%\bin\native
-)
+if exist "%JBOSS_HOME%\bin\native" set PATH=%JBOSS_HOME%\bin\native;%PATH%
+if exist "%JBOSS_HOME%\bin\native" set JAVA_OPTS=%JAVA_OPTS% -Djava.library.path=%JBOSS_HOME%\bin\native
 
 rem Read all command line arguments
 



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 05:33:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 05:33:05 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1699 - in
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools:
	. jmx jmx/rmi jndi
Message-ID: <E1GrB8D-0003N3-9T@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-04 05:33:01 -0500 (Mon, 04 Dec 2006)
New Revision: 1699

Added:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java
Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
Log:
modified test JNDI support to allow for multiple JNDI spaces in the same VM

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -112,7 +112,7 @@
 
       if (isLocal())
       {
-         servers[index] = new LocalTestServer();
+         servers[index] = new LocalTestServer(index);
          return;
       }
 
@@ -585,20 +585,20 @@
 
    public static Hashtable getJNDIEnvironment()
    {
+      return getJNDIEnvironment(0);
+   }
+   
+   public static Hashtable getJNDIEnvironment(int serverIndex)
+   {
       if (isLocal())
       {
-         return InVMInitialContextFactory.getJNDIEnvironment();
+         return InVMInitialContextFactory.getJNDIEnvironment(serverIndex);
       }
       else
       {
-         return getJNDIEnvironment(0);
+         return RemoteInitialContextFactory.getJNDIEnvironment(serverIndex);
       }
    }
-   
-   public static Hashtable getJNDIEnvironment(int index)
-   {
-      return RemoteInitialContextFactory.getJNDIEnvironment(index);      
-   }
 
    // Attributes ----------------------------------------------------
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -279,14 +279,15 @@
          //TODO: need to think more about this; if I don't do it, though, bind() fails because it tries to use "java.naming.provider.url"
          try
          {
-            NamingManager.setInitialContextFactoryBuilder(new InVMInitialContextFactoryBuilder());
+            NamingManager.
+               setInitialContextFactoryBuilder(new InVMInitialContextFactoryBuilder());
          }
          catch(IllegalStateException e)
          {
             // OK
          }
 
-         Hashtable t = InVMInitialContextFactory.getJNDIEnvironment();
+         Hashtable t = InVMInitialContextFactory.getJNDIEnvironment(serverIndex);
          System.setProperty("java.naming.factory.initial",
                             (String)t.get("java.naming.factory.initial"));
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -41,6 +41,7 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.test.messaging.tools.jndi.Constants;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
 import org.jboss.test.messaging.tools.jboss.ServiceDeploymentDescriptor;
 import org.jboss.test.messaging.tools.jmx.MockJBossSecurityManager;
@@ -62,7 +63,17 @@
    private static final Logger log = Logger.getLogger(LocalTestServer.class);
 
    // Static --------------------------------------------------------
-  
+
+   public static void setEnvironmentServerIndex(int serverIndex)
+   {
+      System.setProperty(Constants.SERVER_INDEX_PROPERTY_NAME, Integer.toString(serverIndex));
+   }
+
+   public static void clearEnvironmentServerIndex()
+   {
+      System.getProperty(Constants.SERVER_INDEX_PROPERTY_NAME, null);
+   }
+
    // Attributes ----------------------------------------------------
 
    private ServiceContainer sc;
@@ -108,22 +119,31 @@
       
       log.debug("starting service container");
 
-      sc = new ServiceContainer(containerConfig, null, serverIndex);
-      sc.start();
+      try
+      {
+         setEnvironmentServerIndex(serverIndex);
 
-      if (this.getDatabaseType().equals("hsqldb") && sc.isClustered())
-      {
-         throw new IllegalStateException("The test server cannot be started in clustered mode with hsqldb as a database - must use a shared database");
+         sc = new ServiceContainer(containerConfig, null, serverIndex);
+         sc.start();
+
+         if (this.getDatabaseType().equals("hsqldb") && sc.isClustered())
+         {
+            throw new IllegalStateException("The test server cannot be started in clustered mode with hsqldb as a database - must use a shared database");
+         }
+
+         if ("none".equals(containerConfig))
+         {
+            return;
+         }
+
+         startServerPeer(serverIndex, null, null, sc.isClustered());
+
+         log.info("server started");
       }
-
-      if ("none".equals(containerConfig))
+      finally
       {
-         return;
+         clearEnvironmentServerIndex();
       }
-
-      startServerPeer(serverIndex, null, null, sc.isClustered());
-
-      log.info("server started");
    }
 
    public synchronized void stop() throws Exception

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -0,0 +1,36 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.tools.jndi;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class Constants
+{
+   // Constants -----------------------------------------------------
+
+   public static final String SERVER_INDEX_PROPERTY_NAME = "jboss.messaging.test.server.index";      
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -25,6 +25,8 @@
 import javax.naming.NamingException;
 import javax.naming.Context;
 import java.util.Hashtable;
+import java.util.List;
+import java.util.ArrayList;
 
 /**
  * An in-VM JNDI InitialContextFactory. Lightweight JNDI implementation used for testing.
@@ -38,44 +40,99 @@
 {
    // Constants -----------------------------------------------------
 
-   private static InVMContext initialContext;
-
    // Static --------------------------------------------------------
 
+   // List<InitialContext>
+   private static List initialContexts;
+
+   static
+   {
+      initialContexts = new ArrayList();
+   }
+
+   public static Hashtable getJNDIEnvironment()
+   {
+      return getJNDIEnvironment(0);
+   }
+
    /**
     * @return the JNDI environment to use to get this InitialContextFactory.
     */
-   public static Hashtable getJNDIEnvironment()
+   public static Hashtable getJNDIEnvironment(int serverIndex)
    {
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial",
               "org.jboss.messaging.tools.jndi.InVMInitialContextFactory");
       env.put("java.naming.provider.url", "");
       env.put("java.naming.factory.url.pkgs", "");
+      env.put(Constants.SERVER_INDEX_PROPERTY_NAME, Integer.toString(serverIndex));
       return env;
    }
 
    // Attributes ----------------------------------------------------
-   
+
    // Constructors --------------------------------------------------
-   
+
    // Public --------------------------------------------------------
 
    public Context getInitialContext(Hashtable environment) throws NamingException
    {
-      if (initialContext == null)
+      // try first in the environment passed as argument ...
+      String s = (String)environment.get(Constants.SERVER_INDEX_PROPERTY_NAME);
+
+      if (s == null)
       {
-         initialContext = new InVMContext();
-         initialContext.bind("java:/", new InVMContext());
+         // ... then in the global environment
+         s = System.getProperty(Constants.SERVER_INDEX_PROPERTY_NAME);
+
+         if (s == null)
+         {
+            throw new NamingException("Cannot figure out server index!");
+         }
       }
-      return initialContext;
+
+      int serverIndex;
+
+      try
+      {
+         serverIndex = Integer.parseInt(s);
+      }
+      catch(Exception e)
+      {
+         throw new NamingException("Failure parsing \"" +
+                                   Constants.SERVER_INDEX_PROPERTY_NAME +"\". " +
+                                   s + " is not an integer");
+      }
+
+      int size = initialContexts.size();
+
+      // pad the list to the right size
+
+      if (size <= serverIndex)
+      {
+         for(int i = 0; i < serverIndex - size + 1; i++)
+         {
+            initialContexts.add(null);
+         }
+      }
+
+      InVMContext ic = (InVMContext)initialContexts.get(serverIndex);
+
+      if (ic == null)
+      {
+         ic = new InVMContext();
+         ic.bind("java:/", new InVMContext());
+         initialContexts.set(serverIndex, ic);
+      }
+
+      return ic;
    }
 
    // Package protected ---------------------------------------------
-   
+
    // Protected -----------------------------------------------------
-   
+
    // Private -------------------------------------------------------
-   
+
    // Inner classes -------------------------------------------------   
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -35,9 +35,34 @@
  */
 public class InVMInitialContextFactoryBuilder implements InitialContextFactoryBuilder
 {
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public InVMInitialContextFactoryBuilder()
+   {
+   }
+
+   // InitialContextFactoryBuilder implementation -------------------
+
    public InitialContextFactory createInitialContextFactory(Hashtable environment)
          throws NamingException
    {
       return new InVMInitialContextFactory();
    }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-04 02:58:19 UTC (rev 1698)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-04 10:33:01 UTC (rev 1699)
@@ -42,21 +42,20 @@
 
    // Static --------------------------------------------------------
 
-   private static RemoteContext[] initialContexts = new RemoteContext[RMITestServer.RMI_REGISTRY_PORTS.length];
+   private static RemoteContext[] initialContexts =
+      new RemoteContext[RMITestServer.RMI_REGISTRY_PORTS.length];
    
-   private static final String REMOTE_SERVER_INDEX_KEY_NAME = "jboss.messaging.test.remoteserverindex";
-
    /**
     * @return the JNDI environment to use to get this InitialContextFactory.
     */
-   public static Hashtable getJNDIEnvironment(int index)
+   public static Hashtable getJNDIEnvironment(int serverIndex)
    {
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial",
               "org.jboss.test.messaging.tools.jndi.RemoteInitialContextFactory");
       env.put("java.naming.provider.url", "");
       env.put("java.naming.factory.url.pkgs", "");
-      env.put(REMOTE_SERVER_INDEX_KEY_NAME, String.valueOf(index));
+      env.put(Constants.SERVER_INDEX_PROPERTY_NAME, Integer.toString(serverIndex));
       return env;
    }
 
@@ -68,11 +67,12 @@
 
    public Context getInitialContext(Hashtable environment) throws NamingException
    {
-      String s = (String)environment.get(REMOTE_SERVER_INDEX_KEY_NAME);
+      String s = (String)environment.get(Constants.SERVER_INDEX_PROPERTY_NAME);
       
       if (s == null)
       {
-         throw new IllegalArgumentException("Initial context environment must contain entry for " + REMOTE_SERVER_INDEX_KEY_NAME);
+         throw new IllegalArgumentException("Initial context environment must contain " +
+                                            "entry for " + Constants.SERVER_INDEX_PROPERTY_NAME);
       }
       
       int remoteServerIndex = Integer.parseInt(s);



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 05:34:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 05:34:00 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1700 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/local/base
Message-ID: <E1GrB96-0003NM-3V@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-04 05:33:58 -0500 (Mon, 04 Dec 2006)
New Revision: 1700

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
Log:
minor reformatting

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-04 10:33:01 UTC (rev 1699)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-04 10:33:58 UTC (rev 1700)
@@ -114,10 +114,9 @@
       sc = new ServiceContainer("all,-remoting,-security");
       sc.start();
 
-      pm =
-         new JDBCPersistenceManager(sc.getDataSource(), sc.getTransactionManager(),
-                  sc.getPersistenceManagerSQLProperties(),
-                  true, true, true, 100);
+      pm = new JDBCPersistenceManager(sc.getDataSource(), sc.getTransactionManager(),
+                                      sc.getPersistenceManagerSQLProperties(),
+                                      true, true, true, 100);
       pm.start();
       
       idm = new IdManager("TRANSACTION_ID", 10, pm);



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 05:35:03 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 05:35:03 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1701 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GrBA7-0003OD-Dt@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-04 05:35:01 -0500 (Mon, 04 Dec 2006)
New Revision: 1701

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
temporary changes

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-04 10:33:58 UTC (rev 1700)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-04 10:35:01 UTC (rev 1701)
@@ -38,89 +38,81 @@
  * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
+ * $Id:$
  */
 public class ClusteringBase extends MessagingTestCase
 {
+   // Constants -----------------------------------------------------
 
-   protected Context ic1;
+   // Static --------------------------------------------------------
 
-   protected Context ic2;
+   // Attributes ----------------------------------------------------
 
+   protected Context ic1;
+   protected Context ic2;
    protected Context ic3;
 
    protected Queue queue1;
-
-   protected Topic topic1;
-
    protected Queue queue2;
-
-   protected Topic topic2;
-
    protected Queue queue3;
 
+   protected Topic topic1;
+   protected Topic topic2;
    protected Topic topic3;
 
    protected ConnectionFactory cf1;
-
    protected ConnectionFactory cf2;
-
    protected ConnectionFactory cf3;
 
+   // Constructors --------------------------------------------------
+
    public ClusteringBase(String name)
    {
       super(name);
    }
 
+   // Public --------------------------------------------------------
 
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
    protected void setUp() throws Exception
    {
       super.setUp();
 
       try
       {
-
          ServerManagement.start("all", 0);
-
          ServerManagement.start("all", 1);
+//         ServerManagement.start("all", 2);
 
-         ServerManagement.start("all", 2);
-
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
-
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 1);
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 1);
-
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 2);
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 2);
-
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-
-         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-
-         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
-
-         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-
-         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
-
-         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
-
-         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-
-         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
-
-         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-
-         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-
-         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
-
-         drainQueues();
+//         ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
+//         ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
+//
+//         ServerManagement.deployClusteredQueue("testDistributedQueue", 1);
+//         ServerManagement.deployClusteredTopic("testDistributedTopic", 1);
+//
+//         ServerManagement.deployClusteredQueue("testDistributedQueue", 2);
+//         ServerManagement.deployClusteredTopic("testDistributedTopic", 2);
+//
+//         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+//         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+//         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+//
+//         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
+//         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
+//         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
+//
+//         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
+//         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
+//         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
+//
+//         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
+//         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
+//         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
+//
+//         drainQueues();
       }
       catch (Exception e)
       {
@@ -145,9 +137,7 @@
          ServerManagement.undeployTopic("testDistributedTopic", 2);
 
          ic1.close();
-
          ic2.close();
-
          ic3.close();
       }
       catch (Exception e)
@@ -160,35 +150,25 @@
    protected void drainQueues() throws Exception
    {
       Connection conn1 = null;
-
       Connection conn2 = null;
-
       Connection conn3 = null;
 
       try
       {
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
-
          conn3 = cf3.createConnection();
 
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
          MessageConsumer cons1 = sess1.createConsumer(queue1);
-
          MessageConsumer cons2 = sess2.createConsumer(queue2);
-
          MessageConsumer cons3 = sess3.createConsumer(queue3);
 
          conn1.start();
-
          conn2.start();
-
          conn3.start();
 
          Message msg = null;
@@ -214,12 +194,13 @@
       finally
       {
          if (conn1 != null) conn1.close();
-
          if (conn2 != null) conn2.close();
-
          if (conn3 != null) conn3.close();
       }
    }
 
+   // Private -------------------------------------------------------
 
+   // Inner classes -------------------------------------------------
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-04 10:33:58 UTC (rev 1700)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-04 10:35:01 UTC (rev 1701)
@@ -31,30 +31,31 @@
 /**
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
+ *
+ * $Id:$
  */
 public class HATest extends ClusteringBase
 {
-   protected Logger log = Logger.getLogger(getClass());
 
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
    public HATest(String name)
    {
       super(name);
    }
 
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-   }
+   // Public --------------------------------------------------------
 
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-   }
-
    public void testLeaveFailover() throws Exception
    {
+      log.info("XXXXXXXXXXXXXXX DONE XXXXXXXXXXXXXXXXXXXXXX");
+      Thread.sleep(999999999);
       try
       {
          System.out.println("Number of nodes on Cluster = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
@@ -269,7 +270,22 @@
 //
 //   }
 
+   // Package protected ---------------------------------------------
 
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
    private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
    {
       MessageProxy message = (MessageProxy) consumer.receive(3000);
@@ -293,5 +309,6 @@
       }
    }
 
+   // Inner classes -------------------------------------------------
 
 }



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 05:37:03 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 05:37:03 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1702 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/client/delegate messaging/core/plugin/contract
	messaging/core/plugin/postoffice
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1GrBC3-0003Rj-C4@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-04 05:36:59 -0500 (Mon, 04 Dec 2006)
New Revision: 1702

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java
Log:
refactoring, logging improvments

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-04 10:35:01 UTC (rev 1701)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-04 10:36:59 UTC (rev 1702)
@@ -275,7 +275,7 @@
 
    public String toString()
    {
-      return "ClientConnectionFactoryDelegate[objectId=" + id + "]";
+      return "ClientConnectionFactoryDelegate[" + id + "]";
    }
    
    //This MUST ONLY be used in testing

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-04 10:35:01 UTC (rev 1701)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-04 10:36:59 UTC (rev 1702)
@@ -42,13 +42,16 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
  *
  */
 public interface PostOffice extends MessagingComponent
-{   
+{
+   String getOfficeName();
+
    Binding bindQueue(String condition, Queue queue) throws Exception;
 
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-04 10:35:01 UTC (rev 1701)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-04 10:36:59 UTC (rev 1702)
@@ -51,6 +51,7 @@
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -122,7 +123,7 @@
    
    public void start() throws Exception
    {
-      log.debug(this + " starting");
+      if (trace) { log.trace(this + " starting"); }
       
       super.start();
       
@@ -142,10 +143,15 @@
       
       super.stop();
       
-      if (trace) { log.trace(this + " stopped"); }
+      log.debug(this + " stopped");
    }
      
-   // PostOffice implementation ---------------------------------------        
+   // PostOffice implementation ---------------------------------------
+
+   public String getOfficeName()
+   {
+      return officeName;
+   }
          
    public Binding bindQueue(String condition, Queue queue) throws Exception
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 10:35:01 UTC (rev 1701)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 10:36:59 UTC (rev 1702)
@@ -82,6 +82,7 @@
  * A DefaultClusteredPostOffice
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -112,14 +113,6 @@
    
    private MessageDispatcher controlMessageDispatcher;
    
-   private MessageListener controlMessageListener;
-   
-   private Receiver dataReceiver;
-   
-   private MembershipListener controlMembershipListener;
-   
-   private RequestHandler requestHandler;
-   
    private Object setStateLock = new Object();
    
    private boolean stateSet;
@@ -297,6 +290,8 @@
       {
          log.warn("Attempt to start() but " + this + " is already started");
       }
+
+      if (trace) { log.trace(this + " starting"); }
       
       if (syncChannelConfigElement != null)
       {        
@@ -314,19 +309,14 @@
       
       asyncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
       
-      controlMessageListener = new ControlMessageListener();
+      MessageListener cml = new ControlMessageListener();
+      MembershipListener ml = new ControlMembershipListener();
+      RequestHandler rh = new PostOfficeRequestHandler();
       
-      requestHandler = new PostOfficeRequestHandler();
-      
-      controlMembershipListener = new ControlMembershipListener();
-      
-      this.controlMessageDispatcher =
-         new MessageDispatcher(syncChannel, controlMessageListener,
-                               controlMembershipListener, requestHandler, true);
+      this.controlMessageDispatcher = new MessageDispatcher(syncChannel, cml, ml, rh, true);
 
-      this.dataReceiver = new DataReceiver();
-      
-      asyncChannel.setReceiver(dataReceiver);    
+      Receiver r = new DataReceiver();
+      asyncChannel.setReceiver(r);
 
       syncChannel.connect(groupName);
       
@@ -344,10 +334,9 @@
       
       statsSender.start();
       
-      started = true;   
-      
-      if (trace) { log.trace("Started " + this + " with sync address " + syncAddress +
-                             " async address " + asyncAddress); }
+      started = true;
+
+      log.debug(this + " started");
    }
    
    public synchronized void stop(boolean sendNotification) throws Exception
@@ -1265,13 +1254,36 @@
       }      
    }
    
-   
-   
-   
    public int getNodeId()
    {
       return nodeId;
    }
+
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer("ClusteredPostOffice[");
+      sb.append(nodeId).append(":").append(getOfficeName()).append(":");
+
+      if (syncChannel == null)
+      {
+         sb.append("UNINITIALIZED");
+      }
+      else
+      {
+         Address addr = syncChannel.getLocalAddress();
+         if (addr == null)
+         {
+            sb.append("UNCONNECTED");
+         }
+         else
+         {
+            sb.append(addr);
+         }
+      }
+
+      sb.append("]");
+      return sb.toString();
+   }
                         
    // Public ------------------------------------------------------------------------------------------
       
@@ -1678,7 +1690,7 @@
    
    protected void loadBindings() throws Exception
    {
-      log.debug(this.nodeId + " loading bindings");
+      if (trace) { log.trace(this + " loading bindings"); }
       
       boolean isState = syncChannel.getState(null, stateTimeout);
       
@@ -1686,7 +1698,7 @@
       {
          //Must be first member in group or non clustered- we load the state ourself from the database
          
-         if (trace) { log.trace(this.nodeId + " First member of group- so loading bindings from db"); }
+         if (trace) { log.trace(this + " is the first member of group, so will load bindings from database"); }
          
          super.loadBindings();
       }
@@ -1724,9 +1736,7 @@
          queue = new RemoteQueueStub(nodeId, queueName, channelId, durable, pm, filter);
       }
       
-      Binding binding = new DefaultBinding(nodeId, condition, queue, failed);
-      
-      return binding;
+      return new DefaultBinding(nodeId, condition, queue, failed);
    }
    
    // Private ------------------------------------------------------------------------------------------
@@ -1737,9 +1747,7 @@
       
       try
       {
-         boolean removed = leftSet.remove(nodeId);
-         
-         return removed;
+         return leftSet.remove(nodeId);
       }
       finally
       {
@@ -1831,7 +1839,7 @@
     */
    private void syncSendRequest(ClusterRequest request) throws Exception
    {
-      if (trace) { log.trace(this.nodeId + " sending synch request to group, request: " + request); }
+      if (trace) { log.trace(this + " sending synch request " + request); }
 
       byte[] bytes = writeRequest(request);
 
@@ -1839,7 +1847,7 @@
 
       controlMessageDispatcher.castMessage(null, message, GroupRequest.GET_ALL, castTimeout);
 
-      if (trace) { log.trace(this.nodeId + " sent and executed ok"); }
+      if (trace) { log.trace(this + " request sent OK"); }
    }
    
 
@@ -1935,20 +1943,18 @@
       
       SharedState state = new SharedState(bindings, replicatedData);
       
-      byte[] bytes = StreamUtils.toBytes(state); 
-           
-      return bytes;
+      return StreamUtils.toBytes(state);
    }
    
    private void processStateBytes(byte[] bytes) throws Exception
    {
-      if (trace) { log.trace(this.nodeId + " received state from group"); }
+      if (trace) { log.trace(this + " received state from group"); }
       
       SharedState state = new SharedState();
       
       StreamUtils.fromBytes(state, bytes);
       
-      if (trace) { log.trace(this.nodeId + " received " + state.getBindings().size() + " bindings and map " + state.getReplicatedData()); }
+      if (trace) { log.trace(this + " received " + state.getBindings().size() + " bindings and map " + state.getReplicatedData()); }
       
       nameMaps.clear();
       
@@ -2118,8 +2124,9 @@
     */
    private void nodeJoined(Address address) throws Exception
    {
+      if (trace) { log.trace(this + ": " + address + " joined"); }
+
       // We need to regenerate the failover map
-
       generateFailoverMap(currentView);
    }
 
@@ -2128,6 +2135,8 @@
     */
    private void nodeLeft(Address address) throws Throwable
    {
+      if (trace) { log.trace(this + ": " + address + " left"); }
+
       Integer nodeId = getNodeIdForSyncAddress(address);
 
       if (nodeId != null)
@@ -2255,39 +2264,32 @@
          //NOOP
       }
       
-      public void viewAccepted(View view)
+      public void viewAccepted(View newView)
       {
-         if (trace) { log.trace(nodeId + " Got new view, size=" + view.size()); }
+         if (trace) { log.trace(DefaultClusteredPostOffice.this  + " got new view: " + newView); }
 
          // JGroups will make sure this method is never called by more than one thread concurrently
          
          View oldView = currentView;
+         currentView = newView;
          
-         currentView = view;
-         
          try
          {         
             if (oldView != null)
             {
-               Iterator iter = oldView.getMembers().iterator();
-               
-               while (iter.hasNext())
+               for(Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
                {
-                  Address address = (Address)iter.next();
-                  
-                  if (!view.containsMember(address))
+                  Address address = (Address)i.next();
+                  if (!newView.containsMember(address))
                   {
                      nodeLeft(address);
                   }
                }
             }
             
-            Iterator iter = view.getMembers().iterator();
-            
-            while (iter.hasNext())
+            for(Iterator i = newView.getMembers().iterator(); i.hasNext(); )
             {
-               Address address = (Address)iter.next();
-               
+               Address address = (Address)i.next();
                if (oldView == null || !oldView.containsMember(address))
                {
                   nodeJoined(address);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java	2006-12-04 10:35:01 UTC (rev 1701)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java	2006-12-04 10:36:59 UTC (rev 1702)
@@ -43,42 +43,39 @@
  */
 class PostOfficeAddressInfo implements Streamable, Serializable
 {
+   // Constants -----------------------------------------------------
+
    private static final long serialVersionUID = 8462102430717730566L;
 
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private Address syncChannelAddress;
-   
    private Address asyncChannelAddress;
 
+   // Constructors --------------------------------------------------
+
    public PostOfficeAddressInfo()
-   {     
+   {
    }
-   
+
    PostOfficeAddressInfo(Address syncChannelAddress, Address asyncChannelAddress)
    {
       this.syncChannelAddress = syncChannelAddress;
-      
       this.asyncChannelAddress = asyncChannelAddress;
    }
 
-   Address getSyncChannelAddress()
-   {
-      return syncChannelAddress;
-   }
-   
-   Address getAsyncChannelAddress()
-   {
-      return asyncChannelAddress;
-   }
+   // Streamable implementation -------------------------------------
 
-
    public void read(DataInputStream in) throws Exception
    {
       syncChannelAddress = new IpAddress();
-      
+
       syncChannelAddress.readFrom(in);
-      
+
       asyncChannelAddress = new IpAddress();
-      
+
       asyncChannelAddress.readFrom(in);
 
       byte[] byteInput = new byte[in.readInt()];
@@ -92,23 +89,46 @@
       {
          throw new IllegalStateException("Address must be IpAddress");
       }
-      
+
       if (!(asyncChannelAddress instanceof IpAddress))
       {
          throw new IllegalStateException("Address must be IpAddress");
       }
-      
+
       syncChannelAddress.writeTo(out);
-      
+
       asyncChannelAddress.writeTo(out);
    }
 
+   // Public --------------------------------------------------------
+
    public String toString()
    {
-      StringBuffer buffer = new StringBuffer();
-      buffer.append("syncChannelAddress=" + syncChannelAddress +
-           ", asyncChannelAddress=" + asyncChannelAddress +", ");
+      StringBuffer sb = new StringBuffer("[");
+      sb.append("synch addr ").append(syncChannelAddress);
+      sb.append(", asynch addr ").append(asyncChannelAddress);
+      sb.append("]");
 
-      return buffer.toString();
+      return sb.toString();
    }
+
+
+   // Package protected ---------------------------------------------
+
+   Address getSyncChannelAddress()
+   {
+      return syncChannelAddress;
+   }
+
+   Address getAsyncChannelAddress()
+   {
+      return asyncChannelAddress;
+   }
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java	2006-12-04 10:35:01 UTC (rev 1701)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java	2006-12-04 10:36:59 UTC (rev 1702)
@@ -102,6 +102,11 @@
 
    // Public --------------------------------------------------------
 
+   public String toString()
+   {
+      return "PutRequest[" + key + "][" + replicant + "]";
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------



From msurtani at jboss.com  Mon Dec  4 05:59:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 05:59:39 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrBXv-0003mJ-Ig@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 05:59:39

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_3_0
                        Version.java
  Log:
  Updated version numbers
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.4  +4 -4      JBossCache/src/org/jboss/cache/Version.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Version.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Version.java,v
  retrieving revision 1.13.2.3
  retrieving revision 1.13.2.4
  diff -u -b -r1.13.2.3 -r1.13.2.4
  --- Version.java	5 Jul 2006 17:29:41 -0000	1.13.2.3
  +++ Version.java	4 Dec 2006 10:59:39 -0000	1.13.2.4
  @@ -4,12 +4,12 @@
   
   /**
    * @author Bela Ban
  - * @version $Id: Version.java,v 1.13.2.3 2006/07/05 17:29:41 msurtani Exp $
  + * @version $Id: Version.java,v 1.13.2.4 2006/12/04 10:59:39 msurtani Exp $
    */
   public class Version {
  -    public static final String version="1.3.0.SP3";
  -    public static byte[] version_id={'0', '1', '3', '0', 'S', 'P', '3'};
  -    public static final String cvs="$Id: Version.java,v 1.13.2.3 2006/07/05 17:29:41 msurtani Exp $";
  +    public static final String version="1.3.0.SP4";
  +    public static byte[] version_id={'0', '1', '3', '0', 'S', 'P', '4'};
  +    public static final String cvs="$Id: Version.java,v 1.13.2.4 2006/12/04 10:59:39 msurtani Exp $";
   
       private static final int MAJOR_SHIFT = 11;
       private static final int MINOR_SHIFT = 6;
  
  
  


From msurtani at jboss.com  Mon Dec  4 05:59:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 05:59:39 -0500
Subject: [jboss-cvs] JBossCache/docs  ...
Message-ID: <E1GrBXv-0003mU-ME@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 05:59:39

  Modified:    docs     Tag: Branch_JBossCache_1_3_0 Changelog.txt
  Log:
  Updated version numbers
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.15.2.4  +14 -1     JBossCache/docs/Changelog.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Changelog.txt
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/docs/Changelog.txt,v
  retrieving revision 1.15.2.3
  retrieving revision 1.15.2.4
  diff -u -b -r1.15.2.3 -r1.15.2.4
  --- Changelog.txt	5 Jul 2006 17:29:41 -0000	1.15.2.3
  +++ Changelog.txt	4 Dec 2006 10:59:39 -0000	1.15.2.4
  @@ -1,5 +1,18 @@
  -$Id: Changelog.txt,v 1.15.2.3 2006/07/05 17:29:41 msurtani Exp $
  +$Id: Changelog.txt,v 1.15.2.4 2006/12/04 10:59:39 msurtani Exp $
   
  +Release 1.3.0.SP4 (December 4, 2006)
  +====================================
  +
  +A bug fix release.
  +
  +** Bug
  +    *  [ JBCACHE-836 ] TreeCache isCoordinator() returns incorrect value after clean shutdown of coordinator
  +    *  [ JBCACHE-871 ] Calling remove(FQN) inside a transaction destroys the node before the commit phase
  +    *  [ JBCACHE-872 ] Lock release methods should produce similar log messages to lock acquire methods
  +    *  [ JBCACHE-875 ] Pessimistic lock interceptor does not write-lock parent nodes when creating or deleting children
  +
  +** Task
  +    *  [ JBCACHE-824 ] Don't call Channel.getView() in viewAccepted() callback 
   
   Release 1.3.0.SP3 (June 14, 2006)
   =================================
  
  
  


From msurtani at jboss.com  Mon Dec  4 05:59:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 05:59:39 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GrBXv-0003mf-SL@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 05:59:39

  Modified:    JBossCache  Tag: Branch_JBossCache_1_3_0 build.xml
  Log:
  Updated version numbers
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.95.2.7  +2 -2      JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.95.2.6
  retrieving revision 1.95.2.7
  diff -u -b -r1.95.2.6 -r1.95.2.7
  --- build.xml	29 Nov 2006 16:44:47 -0000	1.95.2.6
  +++ build.xml	4 Dec 2006 10:59:39 -0000	1.95.2.7
  @@ -1,12 +1,12 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.95.2.6 2006/11/29 16:44:47 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.95.2.7 2006/12/04 10:59:39 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
      <property name="module.name" value="JBossCache"/>
      <!--We now requires version to have no white space since Ant+JBossAop will sometime choke. -->
  -   <property name="module.version" value="1.3.0.SP3"/>
  +   <property name="module.version" value="1.3.0.SP4"/>
      <property name="implementation.url" value="http://www.jboss.com/products/jbosscache"/>
      <property file="build.properties"/>
      <property name="root.dir" value="${basedir}"/>
  
  
  


From msurtani at jboss.com  Mon Dec  4 06:21:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 06:21:57 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock  ...
Message-ID: <E1GrBtV-0004RD-NK@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 06:21:57

  Modified:    tests/functional/org/jboss/cache/lock 
                        ReentrantWriterPreference2Readers1WriterLockTest.java
  Log:
  testing using java 5's util.concurrent
  
  Revision  Changes    Path
  1.3       +92 -55    JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReentrantWriterPreference2Readers1WriterLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ReentrantWriterPreference2Readers1WriterLockTest.java	5 May 2006 12:06:58 -0000	1.2
  +++ ReentrantWriterPreference2Readers1WriterLockTest.java	4 Dec 2006 11:21:57 -0000	1.3
  @@ -6,58 +6,68 @@
    */
   package org.jboss.cache.lock;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
   import org.jboss.cache.misc.TestingUtil;
   
  +import java.util.concurrent.locks.ReentrantReadWriteLock;
  +
   /**
    * Tests ReentrantWriterPreferenceReadWriteLock
  + *
    * @author Bela Ban
  - * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.2 2006/05/05 12:06:58 msurtani Exp $
  + * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.3 2006/12/04 11:21:57 msurtani Exp $
    */
  -public class ReentrantWriterPreference2Readers1WriterLockTest extends TestCase {
  +public class ReentrantWriterPreference2Readers1WriterLockTest extends TestCase
  +{
      // ReentrantWriterPreferenceReadWriteLock lock;
  -   SimpleReadWriteLock lock;
  -   Sync rl, wl;
  -   Exception thread_ex=null;
  +   ReentrantReadWriteLock lock;
  +   ReentrantReadWriteLock.ReadLock rl;
  +   ReentrantReadWriteLock.WriteLock wl;
  +   Exception thread_ex = null;
   
  -   protected void setUp() throws Exception {
  +   protected void setUp() throws Exception
  +   {
         super.setUp();
         // lock=new ReentrantWriterPreferenceReadWriteLock();
  -      lock=new SimpleReadWriteLock();
  -      rl=lock.readLock();
  -      wl=lock.writeLock();
  -      thread_ex=null;
  +      //lock=new SimpleReadWriteLock();
  +      lock = new ReentrantReadWriteLock();
  +      rl = lock.readLock();
  +      wl = lock.writeLock();
  +      thread_ex = null;
      }
   
  -   protected void tearDown() throws Exception {
  +   protected void tearDown() throws Exception
  +   {
         super.tearDown();
  -      lock=null;
  -      if(thread_ex != null)
  +      lock = null;
  +      if (thread_ex != null)
            throw thread_ex;
      }
   
   
  -
  -   private static void log(String msg) {
  +   private static void log(String msg)
  +   {
         System.out.println(System.currentTimeMillis() + "  " + Thread.currentThread() +
                            " [" + Thread.currentThread().getName() + "]: " + msg);
      }
   
  -    public void test2ReadersAnd1Writer() throws InterruptedException {
  -      Upgrader upgrader=new Upgrader("Upgrader");
  -      Reader reader=new Reader("Reader");
  +   public void test2ReadersAnd1Writer() throws InterruptedException
  +   {
  +      Upgrader upgrader = new Upgrader("Upgrader");
  +      Reader reader = new Reader("Reader");
         upgrader.start();
         reader.start();
   
         TestingUtil.sleepThread(500);
  -      synchronized(upgrader) {
  +      synchronized (upgrader)
  +      {
            upgrader.notify();
         }
         TestingUtil.sleepThread(500);
  -      synchronized(reader) {
  +      synchronized (reader)
  +      {
            reader.notify();
         }
         reader.join();
  @@ -66,98 +76,125 @@
      }
   
   
  +   class Reader extends Thread
  +   {
   
  -   class Reader extends Thread {
  -
  -      public Reader(String name) {
  +      public Reader(String name)
  +      {
            super(name);
         }
   
  -      public void run() {
  -         try {
  +      public void run()
  +      {
  +         try
  +         {
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquiring RL");
  -            rl.acquire();
  +            rl.tryLock();
  +            //rl.acquire();
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquired RL");
  -            synchronized(this) {
  +            synchronized (this)
  +            {
                  this.wait();
               }
               ReentrantWriterPreference2Readers1WriterLockTest.log("releasing RL");
  -            rl.release();
  +            rl.unlock();
  +            //rl.release();
               ReentrantWriterPreference2Readers1WriterLockTest.log("released RL");
            }
  -         catch(InterruptedException e) {
  +         catch (InterruptedException e)
  +         {
               ;
            }
         }
      }
   
   
  -   class Writer extends Thread {
  +   class Writer extends Thread
  +   {
   
  -      public Writer(String name) {
  +      public Writer(String name)
  +      {
            super(name);
         }
   
  -      public void run() {
  -         try {
  +      public void run()
  +      {
  +         try
  +         {
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquiring WL");
  -            wl.acquire();
  +            //wl.acquire();
  +            wl.tryLock();
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquired WL");
  -            synchronized(this) {
  +            synchronized (this)
  +            {
                  this.wait();
               }
               ReentrantWriterPreference2Readers1WriterLockTest.log("releasing WL");
  -            wl.release();
  +            //wl.release();
  +            wl.unlock();
               ReentrantWriterPreference2Readers1WriterLockTest.log("released WL");
            }
  -         catch(InterruptedException e) {
  +         catch (InterruptedException e)
  +         {
               ;
            }
         }
      }
   
   
  -   class Upgrader extends Thread {
  -      boolean upgradeSuccessful=false;
  -      public Upgrader(String name) {
  +   class Upgrader extends Thread
  +   {
  +      boolean upgradeSuccessful = false;
  +
  +      public Upgrader(String name)
  +      {
            super(name);
         }
   
  -      public boolean wasUpgradeSuccessful() {
  +      public boolean wasUpgradeSuccessful()
  +      {
            return upgradeSuccessful;
         }
   
   
  -      public void run() {
  -         try {
  +      public void run()
  +      {
  +         try
  +         {
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquiring RL");
  -            rl.acquire();
  +            //rl.acquire();
  +            rl.tryLock();
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquired RL");
  -            synchronized(this) {
  +            synchronized (this)
  +            {
                  this.wait();
               }
               ReentrantWriterPreference2Readers1WriterLockTest.log("attempting to acquire WL");
               // rl.release();
  -            wl.acquire();
  -            upgradeSuccessful=true;
  +            //wl.acquire();
  +            wl.tryLock();
  +            upgradeSuccessful = true;
               ReentrantWriterPreference2Readers1WriterLockTest.log("acquired WL");
               ReentrantWriterPreference2Readers1WriterLockTest.log("releasing WL/RL");
  -            wl.release();
  +            //wl.release();
  +            rl.unlock();
               ReentrantWriterPreference2Readers1WriterLockTest.log("released WL/RL");
            }
  -         catch(InterruptedException e) {
  +         catch (InterruptedException e)
  +         {
               ;
            }
         }
      }
   
   
  -
  -   public static Test suite() {
  +   public static Test suite()
  +   {
         return new TestSuite(ReentrantWriterPreference2Readers1WriterLockTest.class);
      }
   
  -   public static void main(String[] args) {
  +   public static void main(String[] args)
  +   {
         junit.textui.TestRunner.run(ReentrantWriterPreference2Readers1WriterLockTest.suite());
      }
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 06:37:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 06:37:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r58830 -
	branches/JBoss_3_2_7_CP/tools/etc/buildmagic
Message-ID: <E1GrC8q-0004k9-2Y@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-04 06:37:46 -0500 (Mon, 04 Dec 2006)
New Revision: 58830

Modified:
   branches/JBoss_3_2_7_CP/tools/etc/buildmagic/buildmagic.ent
   branches/JBoss_3_2_7_CP/tools/etc/buildmagic/version-info.xml
Log:
update version files

Modified: branches/JBoss_3_2_7_CP/tools/etc/buildmagic/buildmagic.ent
===================================================================
--- branches/JBoss_3_2_7_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-04 08:56:36 UTC (rev 58829)
+++ branches/JBoss_3_2_7_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-04 11:37:46 UTC (rev 58830)
@@ -102,10 +102,10 @@
   <property name="version.major" value="3"/>
   <property name="version.minor" value="2"/>
   <property name="version.revision" value="7"/>
-  <property name="version.tag" value=".GA_CP02"/>
+  <property name="version.tag" value=".GA_CP03"/>
   <property name="version.name" value="WonderLand"/>
   <!-- This must be set to the CVS tag for any release -->
-  <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_3_2_7_GA_CP02/"/>
+  <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_3_2_7_GA_CP03/"/>
 
   <!-- Manifest version info -->
   <property name="specification.title" value="JBoss"/>

Modified: branches/JBoss_3_2_7_CP/tools/etc/buildmagic/version-info.xml
===================================================================
--- branches/JBoss_3_2_7_CP/tools/etc/buildmagic/version-info.xml	2006-12-04 08:56:36 UTC (rev 58829)
+++ branches/JBoss_3_2_7_CP/tools/etc/buildmagic/version-info.xml	2006-12-04 11:37:46 UTC (rev 58830)
@@ -17,10 +17,10 @@
     <property name="version.major" value="3"/>
     <property name="version.minor" value="2"/>
     <property name="version.revision" value="7"/>
-    <property name="version.tag" value=".GA_CP02"/>
+    <property name="version.tag" value=".GA_CP03"/>
     <property name="version.name" value="WonderLand"/>
     <!-- This must be set to the CVS tag for any release -->
-    <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_3_2_7_GA_CP02/"/>
+    <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_3_2_7_GA_CP03/"/>
 
     <!-- Manifest version info -->
     <property name="specification.title" value="JBoss"/>



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 06:48:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 06:48:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r58831 - in
	trunk/ejb3/src/main/org/jboss/ejb3: deployers metamodel
Message-ID: <E1GrCJd-0004vK-Fh@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-04 06:48:50 -0500 (Mon, 04 Dec 2006)
New Revision: 58831

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBossClientParsingDeployer.java
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossClientDDObjectFactory.java
Log:
fixed NPE in DelegatingObjectModelFactory.newChild

Modified: trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBossClientParsingDeployer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBossClientParsingDeployer.java	2006-12-04 11:37:46 UTC (rev 58830)
+++ trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBossClientParsingDeployer.java	2006-12-04 11:48:50 UTC (rev 58831)
@@ -63,6 +63,10 @@
    @Override
    protected ObjectModelFactory getObjectModelFactory(ApplicationClientDD root)
    {
+      // if we haven't gotten an application-client.xml yet
+      if(root == null)
+         root = new ApplicationClientDD();
+      
       return new JBossClientDDObjectFactory(root);
    }
 

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossClientDDObjectFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossClientDDObjectFactory.java	2006-12-04 11:37:46 UTC (rev 58830)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossClientDDObjectFactory.java	2006-12-04 11:48:50 UTC (rev 58831)
@@ -78,6 +78,10 @@
    
    public JBossClientDDObjectFactory(ApplicationClientDD dd)
    {
+      // JBossXB will otherwise fail later on
+      if(dd == null)
+         throw new NullPointerException("dd is null");
+      
       this.dd = dd;
    }
    



From bela.ban at jboss.com  Mon Dec  4 07:03:33 2006
From: bela.ban at jboss.com (Bela Ban)
Date: Mon, 04 Dec 2006 07:03:33 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock  ...
Message-ID: <E1GrCXl-0005K9-8f@committer01.frg.pub.inap.atl.jboss.com>

  User: bela    
  Date: 06/12/04 07:03:33

  Modified:    tests/functional/org/jboss/cache/lock 
                        ReentrantWriterPreference2Readers1WriterLockTest.java
  Log:
  removed dependency on TestingUtil
  
  Revision  Changes    Path
  1.4       +12 -4     JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReentrantWriterPreference2Readers1WriterLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ReentrantWriterPreference2Readers1WriterLockTest.java	4 Dec 2006 11:21:57 -0000	1.3
  +++ ReentrantWriterPreference2Readers1WriterLockTest.java	4 Dec 2006 12:03:33 -0000	1.4
  @@ -9,15 +9,15 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -import org.jboss.cache.misc.TestingUtil;
   
   import java.util.concurrent.locks.ReentrantReadWriteLock;
   
  +
   /**
    * Tests ReentrantWriterPreferenceReadWriteLock
    *
    * @author Bela Ban
  - * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.3 2006/12/04 11:21:57 msurtani Exp $
  + * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.4 2006/12/04 12:03:33 bela Exp $
    */
   public class ReentrantWriterPreference2Readers1WriterLockTest extends TestCase
   {
  @@ -60,12 +60,12 @@
         upgrader.start();
         reader.start();
   
  -      TestingUtil.sleepThread(500);
  +      sleepThread(500);
         synchronized (upgrader)
         {
            upgrader.notify();
         }
  -      TestingUtil.sleepThread(500);
  +      sleepThread(500);
         synchronized (reader)
         {
            reader.notify();
  @@ -188,6 +188,14 @@
      }
   
   
  +   static void sleepThread(long timeout) {
  +      try {
  +         Thread.sleep(timeout);
  +      }
  +      catch(InterruptedException e) {
  +      }
  +   }
  +
      public static Test suite()
      {
         return new TestSuite(ReentrantWriterPreference2Readers1WriterLockTest.class);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 07:05:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 07:05:17 -0500
Subject: [jboss-cvs] JBossAS SVN: r58832 -
	branches/JBoss_4_0_2_CP/tools/etc/buildmagic
Message-ID: <E1GrCZR-0005Le-3V@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-04 07:05:16 -0500 (Mon, 04 Dec 2006)
New Revision: 58832

Modified:
   branches/JBoss_4_0_2_CP/tools/etc/buildmagic/buildmagic.ent
   branches/JBoss_4_0_2_CP/tools/etc/buildmagic/version-info.xml
Log:
update version files

Modified: branches/JBoss_4_0_2_CP/tools/etc/buildmagic/buildmagic.ent
===================================================================
--- branches/JBoss_4_0_2_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-04 11:48:50 UTC (rev 58831)
+++ branches/JBoss_4_0_2_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-04 12:05:16 UTC (rev 58832)
@@ -99,10 +99,10 @@
   <property name="version.major" value="4"/>
   <property name="version.minor" value="0"/>
   <property name="version.revision" value="2"/>
-  <property name="version.tag" value=".GA_CP02"/>
+  <property name="version.tag" value=".GA_CP03"/>
   <property name="version.name" value="Zion"/>
   <!-- This must be set to the CVS tag for any release -->
-  <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_2_GA_CP02"/>
+  <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_2_GA_CP03"/>
 
   <!-- Manifest version info -->
   <property name="specification.title" value="JBoss"/>

Modified: branches/JBoss_4_0_2_CP/tools/etc/buildmagic/version-info.xml
===================================================================
--- branches/JBoss_4_0_2_CP/tools/etc/buildmagic/version-info.xml	2006-12-04 11:48:50 UTC (rev 58831)
+++ branches/JBoss_4_0_2_CP/tools/etc/buildmagic/version-info.xml	2006-12-04 12:05:16 UTC (rev 58832)
@@ -17,10 +17,10 @@
     <property name="version.major" value="4"/>
     <property name="version.minor" value="0"/>
     <property name="version.revision" value="2"/>
-    <property name="version.tag" value=".GA_CP02"/>
+    <property name="version.tag" value=".GA_CP03"/>
     <property name="version.name" value="Zion"/>
     <!-- This must be set to the CVS tag for any release -->
-    <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_2_GA_CP02"/>
+    <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_2_GA_CP03"/>
 
     <!-- Manifest version info -->
     <property name="specification.title" value="JBoss"/>



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 07:14:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 07:14:34 -0500
Subject: [jboss-cvs] JBossAS SVN: r58833 -
	branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic
Message-ID: <E1GrCiQ-0005Tz-Rm@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-04 07:14:34 -0500 (Mon, 04 Dec 2006)
New Revision: 58833

Modified:
   branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent
   branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml
Log:
update version files

Modified: branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent
===================================================================
--- branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-04 12:05:16 UTC (rev 58832)
+++ branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-04 12:14:34 UTC (rev 58833)
@@ -99,10 +99,10 @@
   <property name="version.major" value="4"/>
   <property name="version.minor" value="0"/>
   <property name="version.revision" value="4"/>
-  <property name="version.tag" value="GA_CP02"/>
+  <property name="version.tag" value="GA_CP03"/>
   <property name="version.name" value="Zion"/>
   <!-- This must be set to the CVS tag for any release -->
-  <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_4_GA_CP02" />
+  <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_4_GA_CP03" />
 
   <!-- Manifest version info -->
   <property name="specification.title" value="JBoss"/>

Modified: branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml	2006-12-04 12:05:16 UTC (rev 58832)
+++ branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml	2006-12-04 12:14:34 UTC (rev 58833)
@@ -17,10 +17,10 @@
     <property name="version.major" value="4"/>
     <property name="version.minor" value="0"/>
     <property name="version.revision" value="4"/>
-    <property name="version.tag" value="GA_CP02"/>
+    <property name="version.tag" value="GA_CP03"/>
     <property name="version.name" value="Zion"/>
     <!-- This must be set to the CVS tag for any release -->
-    <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_4_GA_CP02"/>
+    <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_4_GA_CP03"/>
 
     <!-- Manifest version info -->
     <property name="specification.title" value="JBoss"/>



From bela.ban at jboss.com  Mon Dec  4 07:33:40 2006
From: bela.ban at jboss.com (Bela Ban)
Date: Mon, 04 Dec 2006 07:33:40 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock  ...
Message-ID: <E1GrD0u-0005kZ-IL@committer01.frg.pub.inap.atl.jboss.com>

  User: bela    
  Date: 06/12/04 07:33:40

  Modified:    tests/functional/org/jboss/cache/lock 
                        ReentrantWriterPreference2Readers1WriterLockTest.java
  Log:
  ns
  
  Revision  Changes    Path
  1.5       +117 -113  JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReentrantWriterPreference2Readers1WriterLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ReentrantWriterPreference2Readers1WriterLockTest.java	4 Dec 2006 12:03:33 -0000	1.4
  +++ ReentrantWriterPreference2Readers1WriterLockTest.java	4 Dec 2006 12:33:40 -0000	1.5
  @@ -11,179 +11,185 @@
   import junit.framework.TestSuite;
   
   import java.util.concurrent.locks.ReentrantReadWriteLock;
  +import java.util.concurrent.TimeUnit;
   
   
   /**
    * Tests ReentrantWriterPreferenceReadWriteLock
  - *
    * @author Bela Ban
  - * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.4 2006/12/04 12:03:33 bela Exp $
  + * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.5 2006/12/04 12:33:40 bela Exp $
    */
  -public class ReentrantWriterPreference2Readers1WriterLockTest extends TestCase
  -{
  -   // ReentrantWriterPreferenceReadWriteLock lock;
  +public class ReentrantWriterPreference2Readers1WriterLockTest extends TestCase {
      ReentrantReadWriteLock lock;
      ReentrantReadWriteLock.ReadLock rl;
      ReentrantReadWriteLock.WriteLock wl;
  -   Exception thread_ex = null;
  +   Exception thread_ex=null;
   
  -   protected void setUp() throws Exception
  -   {
  +   protected void setUp() throws Exception {
         super.setUp();
  -      // lock=new ReentrantWriterPreferenceReadWriteLock();
  -      //lock=new SimpleReadWriteLock();
  -      lock = new ReentrantReadWriteLock();
  -      rl = lock.readLock();
  -      wl = lock.writeLock();
  -      thread_ex = null;
  +      lock=new ReentrantReadWriteLock();
  +      rl=lock.readLock();
  +      wl=lock.writeLock();
  +      thread_ex=null;
      }
   
  -   protected void tearDown() throws Exception
  -   {
  +   protected void tearDown() throws Exception {
         super.tearDown();
  -      lock = null;
  -      if (thread_ex != null)
  +      lock=null;
  +      if(thread_ex != null)
            throw thread_ex;
      }
   
   
  -   private static void log(String msg)
  -   {
  +   private void log(String msg) {
         System.out.println(System.currentTimeMillis() + "  " + Thread.currentThread() +
                 " [" + Thread.currentThread().getName() + "]: " + msg);
      }
   
  -   public void test2ReadersAnd1Writer() throws InterruptedException
  -   {
  -      Upgrader upgrader = new Upgrader("Upgrader");
  -      Reader reader = new Reader("Reader");
  -      upgrader.start();
  +
  +   public void testSimpleUpgradeFromReadLockToWriteLock() {
  +      int readers, writers;
  +      try {
  +         rl.lock();
  +         readers=lock.getReadLockCount();
  +         assertEquals(1, readers);
  +         boolean wl_acquired=wl.tryLock(500, TimeUnit.MILLISECONDS);
  +         if(!wl_acquired) {
  +            fail("write lock could not be acquired");
  +            return;
  +         }
  +         readers=lock.getReadLockCount();
  +         assertEquals(1, readers);
  +         writers=lock.getWriteHoldCount();
  +         assertEquals(1, writers);
  +      }
  +      catch(InterruptedException e) {
  +
  +      }
  +      finally {
  +         rl.unlock();
  +         if(lock.getWriteHoldCount() > 0)
  +            wl.unlock();
  +      }
  +   }
  +
  +   public void test2ReadersAnd1Writer() throws InterruptedException {
  +      int readers, writers;
  +      Upgrader upgrader=new Upgrader("Upgrader");
  +      Reader reader=new Reader("Reader");
         reader.start();
  +      sleepThread(500);
  +
  +      readers=lock.getReadLockCount();
  +      assertEquals(1, readers);
   
  +      upgrader.start();
         sleepThread(500);
  -      synchronized (upgrader)
  -      {
  +
  +      readers=lock.getReadLockCount();
  +      assertEquals(2, readers);
  +
  +      synchronized(upgrader) { // writer upgrades from RL to WL, this should fail
            upgrader.notify();
         }
         sleepThread(500);
  -      synchronized (reader)
  -      {
  +
  +      readers=lock.getReadLockCount();
  +      assertEquals(2, readers);
  +      writers=lock.getWriteHoldCount();
  +      assertEquals(0, writers);
  +
  +      synchronized(reader) { // reader unlocks its RL, now writer should be able to upgrade to a WL
            reader.notify();
         }
         reader.join();
  -      upgrader.join(3000);
  -      assertTrue("Known failure. See JBCACHE-461; This is due to a bug in ReentrantWriterPreferenceReadWriteLock !", upgrader.wasUpgradeSuccessful());
  -   }
   
  +      readers=lock.getReadLockCount();
  +      assertEquals(1, readers);
  +      writers=lock.getWriteHoldCount();
  +      assertEquals(1, writers);
   
  -   class Reader extends Thread
  -   {
  -
  -      public Reader(String name)
  -      {
  -         super(name);
  +       synchronized(upgrader) { // writer releases WL
  +         upgrader.notify();
         }
  +      sleepThread(500);
  +      readers=lock.getReadLockCount();
  +      assertEquals(0, readers);
  +      writers=lock.getWriteHoldCount();
  +      assertEquals(0, writers);
   
  -      public void run()
  -      {
  -         try
  -         {
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquiring RL");
  -            rl.tryLock();
  -            //rl.acquire();
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquired RL");
  -            synchronized (this)
  -            {
  -               this.wait();
  -            }
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("releasing RL");
  -            rl.unlock();
  -            //rl.release();
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("released RL");
  -         }
  -         catch (InterruptedException e)
  -         {
  -            ;
  -         }
  -      }
  +      upgrader.join(3000);
  +      assertTrue("Known failure. See JBCACHE-461; This is due to a potential bug in ReentrantWriterPreferenceReadWriteLock !",
  +                 upgrader.wasUpgradeSuccessful());
      }
   
   
  -   class Writer extends Thread
  -   {
  +   private class Reader extends Thread {
   
  -      public Writer(String name)
  -      {
  +      public Reader(String name) {
            super(name);
         }
   
  -      public void run()
  -      {
  -         try
  -         {
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquiring WL");
  -            //wl.acquire();
  -            wl.tryLock();
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquired WL");
  -            synchronized (this)
  -            {
  +      public void run() {
  +         try {
  +            log("acquiring RL");
  +            rl.lock();
  +            log("acquired RL");
  +            synchronized(this) {
                  this.wait();
               }
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("releasing WL");
  -            //wl.release();
  -            wl.unlock();
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("released WL");
            }
  -         catch (InterruptedException e)
  -         {
  -            ;
  +         catch(InterruptedException e) {
  +         }
  +         finally {
  +            log("releasing RL");
  +            rl.unlock();
  +            log("released RL");
            }
         }
      }
   
   
  -   class Upgrader extends Thread
  -   {
  -      boolean upgradeSuccessful = false;
  +   private class Upgrader extends Thread {
  +      boolean upgradeSuccessful=false;
   
  -      public Upgrader(String name)
  -      {
  +      public Upgrader(String name) {
            super(name);
         }
   
  -      public boolean wasUpgradeSuccessful()
  -      {
  +      public boolean wasUpgradeSuccessful() {
            return upgradeSuccessful;
         }
   
   
  -      public void run()
  -      {
  -         try
  -         {
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquiring RL");
  -            //rl.acquire();
  -            rl.tryLock();
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquired RL");
  -            synchronized (this)
  -            {
  +      public void run() {
  +         try {
  +            log("acquiring RL");
  +            rl.lock();
  +            log("acquired RL");
  +            synchronized(this) {
  +               this.wait();
  +            }
  +            log("attempting to acquire WL");
  +            wl.lock();
  +            upgradeSuccessful=true;
  +            log("acquired WL");
  +
  +
  +            synchronized(this) {
                  this.wait();
               }
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("attempting to acquire WL");
  -            // rl.release();
  -            //wl.acquire();
  -            wl.tryLock();
  -            upgradeSuccessful = true;
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("acquired WL");
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("releasing WL/RL");
  -            //wl.release();
  +            log("releasing WL");
               rl.unlock();
  -            ReentrantWriterPreference2Readers1WriterLockTest.log("released WL/RL");
  +            log("released WL");
            }
  -         catch (InterruptedException e)
  -         {
  +         catch(InterruptedException e) {
               ;
            }
  +         finally {
  +            wl.unlock();
  +            rl.unlock();
  +         }
         }
      }
   
  @@ -196,13 +202,11 @@
         }
      }
   
  -   public static Test suite()
  -   {
  +   public static Test suite() {
         return new TestSuite(ReentrantWriterPreference2Readers1WriterLockTest.class);
      }
   
  -   public static void main(String[] args)
  -   {
  +   public static void main(String[] args) {
         junit.textui.TestRunner.run(ReentrantWriterPreference2Readers1WriterLockTest.suite());
      }
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 08:13:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 08:13:44 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58834 - trunk/system/src/bin
Message-ID: <E1GrDdg-0006SD-Q5@committer01.frg.pub.inap.atl.jboss.com>

Author: mladen.turk at jboss.com
Date: 2006-12-04 08:13:43 -0500 (Mon, 04 Dec 2006)
New Revision: 58834

Modified:
   trunk/system/src/bin/run.bat
Log:
Remove the if processing that contains (. They are breaking if the environment variable contains the (

Modified: trunk/system/src/bin/run.bat
===================================================================
--- trunk/system/src/bin/run.bat	2006-12-04 12:14:34 UTC (rev 58833)
+++ trunk/system/src/bin/run.bat	2006-12-04 13:13:43 UTC (rev 58834)
@@ -71,11 +71,9 @@
 rem If JBOSS_CLASSPATH is empty, don't include it, as this will 
 rem result in including the local directory, which makes error tracking
 rem harder.
-if "%JBOSS_CLASSPATH%" == "" (
-   set JBOSS_CLASSPATH=%JAVAC_JAR%;%RUNJAR%
-) else (
-   set JBOSS_CLASSPATH=%JBOSS_CLASSPATH%;%JAVAC_JAR%;%RUNJAR%
-)
+if "%JBOSS_CLASSPATH%" == "" set RUN_CLASSPATH=%JAVAC_JAR%;%RUNJAR%
+if "%RUN_CLASSPATH%" == "" set RUN_CLASSPATH=%JBOSS_CLASSPATH%;%JAVAC_JAR%;%RUNJAR%
+set JBOSS_CLASSPATH=%RUN_CLASSPATH%
 
 rem Setup JBoss specific properties
 set JAVA_OPTS=%JAVA_OPTS% -Dprogram.name=%PROGNAME%



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 09:18:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 09:18:07 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58835 - tags
Message-ID: <E1GrEdz-0007hh-W4@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-04 09:18:07 -0500 (Mon, 04 Dec 2006)
New Revision: 58835

Added:
   tags/JBoss_4_0_4_GA_CP03/
Log:
cut the 4.0.4_CP03 release

Copied: tags/JBoss_4_0_4_GA_CP03 (from rev 58834, branches/JBoss_4_0_4_GA_CP)



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 09:19:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 09:19:52 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58836 - tags
Message-ID: <E1GrEfg-0007i0-NZ@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-04 09:19:52 -0500 (Mon, 04 Dec 2006)
New Revision: 58836

Added:
   tags/JBoss_4_0_2_GA_CP03/
Log:
cut the 4.0.2.GA_CP03 release

Copied: tags/JBoss_4_0_2_GA_CP03 (from rev 58835, branches/JBoss_4_0_2_CP)



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 09:20:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 09:20:46 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58837 - tags
Message-ID: <E1GrEgY-0007kY-IJ@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-04 09:20:46 -0500 (Mon, 04 Dec 2006)
New Revision: 58837

Added:
   tags/JBoss_3_2_7_GA_CP03/
Log:
cut the 3.2.7.GA_CP03 release

Copied: tags/JBoss_3_2_7_GA_CP03 (from rev 58836, branches/JBoss_3_2_7_CP)



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 09:41:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 09:41:15 -0500
Subject: [jboss-cvs] JBossAS SVN: r58838 - in
	projects/microcontainer/trunk/container/src: main/org/jboss
	main/org/jboss/beans/info/plugins main/org/jboss/reflect/plugins
	main/org/jboss/reflect/plugins/introspection
	main/org/jboss/reflect/plugins/javassist
	main/org/jboss/reflect/spi main/org/jboss/util
	main/org/jboss/util/collection main/org/jboss/util/collection/temp
	tests/org/jboss/test/classinfo/support
	tests/org/jboss/test/classinfo/test
Message-ID: <E1GrF0N-00083W-4l@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-04 09:40:50 -0500 (Mon, 04 Dec 2006)
New Revision: 58838

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/util/
   projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/
   projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/
   projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME
   projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java
   projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java
Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java
Log:
Generification of the TypeInfo api.

TODO:
* Complete the support for TypeVariable and GenericArray
* Implement this for the javassist version
* Move the org.jboss.util.collection.temp to the common-core project once
it properly supports JDK5

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -42,7 +42,7 @@
 import org.jboss.reflect.spi.PrimitiveInfo;
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.util.JBossStringBuilder;
-import org.jboss.util.collection.WeakValueHashMap;
+import org.jboss.util.collection.temp.WeakValueHashMap;
 
 /**
  * A bean info factory.
@@ -140,7 +140,7 @@
          BeanInfo result = createBeanInfo(classAdapter, properties, constructors, methods, events);
          if (map == null)
          {
-            map = new WeakValueHashMap();
+            map = new WeakValueHashMap<String, BeanInfo>();
             cache.put(cl, map);
          }
          map.put(className, result);

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -21,7 +21,6 @@
 */
 package org.jboss.reflect.plugins;
 
-import org.jboss.reflect.spi.AnnotatedInfo;
 import org.jboss.reflect.spi.AnnotationValue;
 import org.jboss.reflect.spi.ArrayInfo;
 import org.jboss.reflect.spi.TypeInfo;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -21,6 +21,8 @@
 */
 package org.jboss.reflect.plugins;
 
+import org.jboss.reflect.plugins.introspection.ParameterizedClassInfo;
+import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.InterfaceInfo;
 import org.jboss.reflect.spi.TypeInfo;
 
@@ -41,6 +43,14 @@
    ClassInfoImpl getSuperClass(ClassInfoImpl classInfo);
 
    /**
+    * Get the generic super class
+    * 
+    * @param classInfo the class info
+    * @return the super class info
+    */
+   ClassInfo getGenericSuperClass(ClassInfoImpl classInfo);
+
+   /**
     * Get the interfaces
     * 
     * @param classInfo the class info
@@ -49,6 +59,14 @@
    InterfaceInfo[] getInterfaces(ClassInfoImpl classInfo);
 
    /**
+    * Get the generic interfaces
+    * 
+    * @param classInfo the class info
+    * @return the interface info
+    */
+   InterfaceInfo[] getGenericInterfaces(ClassInfoImpl classInfo);
+
+   /**
     * Get the constructors
     * 
     * @param classInfo the class info
@@ -79,4 +97,20 @@
     * @return the type info
     */
    TypeInfo getTypeInfo(Class clazz);
+   
+   /**
+    * Get the actual type parameters
+    * 
+    * @param classInfo the parameterized class info
+    * @return the type parameters
+    */
+   TypeInfo[] getActualTypeArguments(ParameterizedClassInfo classInfo);
+   
+   /**
+    * Get the owner type
+    * 
+    * @param classInfo the parameterized class info
+    * @return the owner type
+    */
+   TypeInfo getOwnerType(ParameterizedClassInfo classInfo);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -48,19 +48,28 @@
    private static final long serialVersionUID = 3545798779904340792L;
 
    /** Marker for generation */
-   static final ClassInfo UNKNOWN_CLASS = new UnknownClassInfo();
+   public static final ClassInfo UNKNOWN_CLASS = new UnknownClassInfo();
 
    /** Marker for generation */
-   static final InterfaceInfo[] UNKNOWN_INTERFACES = new InterfaceInfo[0];
+   public static final ClassInfo[] UNKNOWN_CLASSES = new UnknownClassInfo[0];
 
    /** Marker for generation */
-   static final ConstructorInfo[] UNKNOWN_CONSTRUCTORS = new ConstructorInfo[0];
+   public static final TypeInfo UNKNOWN_TYPE = new UnknownTypeInfo();
 
    /** Marker for generation */
-   static final MethodInfo[] UNKNOWN_METHODS = new MethodInfo[0];
+   public static final TypeInfo[] UNKNOWN_TYPES = new UnknownTypeInfo[0];
 
    /** Marker for generation */
-   private static final FieldInfo[] UNKNOWN_FIELDS = new FieldInfo[0];
+   public static final InterfaceInfo[] UNKNOWN_INTERFACES = new InterfaceInfo[0];
+
+   /** Marker for generation */
+   public static final ConstructorInfo[] UNKNOWN_CONSTRUCTORS = new ConstructorInfo[0];
+
+   /** Marker for generation */
+   public static final MethodInfo[] UNKNOWN_METHODS = new MethodInfo[0];
+
+   /** Marker for generation */
+   public static final FieldInfo[] UNKNOWN_FIELDS = new FieldInfo[0];
    
    /** The class name */
    protected String name;
@@ -71,6 +80,9 @@
    /** The interfaces */
    protected InterfaceInfo[] interfaces = UNKNOWN_INTERFACES;
    
+   /** The generic interfaces */
+   protected InterfaceInfo[] genericInterfaces = UNKNOWN_INTERFACES;
+   
    /** The methods */
    protected MethodInfo[] methods = UNKNOWN_METHODS;
    
@@ -83,6 +95,9 @@
    /** The super class */
    protected ClassInfo superclass = UNKNOWN_CLASS;
 
+   /** The generic super class */
+   protected ClassInfo genericSuperclass = UNKNOWN_CLASS;
+
    /** The constructor info */
    protected ConstructorInfo[] constructors = UNKNOWN_CONSTRUCTORS; 
 
@@ -243,6 +258,16 @@
    {
       this.interfaces = interfaces;
    }
+   
+   /**
+    * Set the generic interfaces
+    * 
+    * @param interfaces the interfaces
+    */
+   public void setGenericInterfaces(InterfaceInfo[] interfaces)
+   {
+      this.genericInterfaces = interfaces;
+   }
 
    /**
     * Set the declared methods
@@ -303,6 +328,15 @@
       this.superclass = superInfo;
    }
 
+   /**
+    * Set the generic super class
+    * 
+    * @param superInfo the super class
+    */
+   public void setGenericSuperclass(ClassInfo superInfo)
+   {
+      this.genericSuperclass = superInfo;
+   }
 
    public boolean isInterface()
    {
@@ -315,6 +349,13 @@
          setInterfaces(classInfoHelper.getInterfaces(this));
       return interfaces;
    }
+
+   public InterfaceInfo[] getGenericInterfaces()
+   {
+      if (genericInterfaces == UNKNOWN_INTERFACES)
+         setGenericInterfaces(classInfoHelper.getGenericInterfaces(this));
+      return genericInterfaces;
+   }
    
    public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
    {
@@ -366,6 +407,13 @@
          setSuperclass(classInfoHelper.getSuperClass(this));
       return superclass;
    }
+
+   public ClassInfo getGenericSuperclass()
+   {
+      if (genericSuperclass == UNKNOWN_CLASS)
+         setGenericSuperclass(classInfoHelper.getGenericSuperClass(this));
+      return genericSuperclass;
+   }
    
    public int getModifiers()
    {
@@ -426,6 +474,21 @@
       return (Object[]) Array.newInstance(clazz.getComponentType(), size);
    }
 
+   public TypeInfo[] getActualTypeArguments()
+   {
+      return null;
+   }
+
+   public TypeInfo getOwnerType()
+   {
+      return null;
+   }
+
+   public ClassInfo getRawType()
+   {
+      return this;
+   }
+
    protected InheritableAnnotationHolder getSuperHolder()
    {
       return (ClassInfoImpl) getSuperclass();
@@ -456,121 +519,137 @@
       return (name != null ? name.hashCode() : 0);
    }
    
-   static class UnknownClassInfo implements ClassInfo
+   public static class UnknownTypeInfo implements TypeInfo
    {
       /** The serialVersionUID */
       private static final long serialVersionUID = 1L;
 
-      public ConstructorInfo[] getDeclaredConstructors()
+      public Object convertValue(Object value) throws Throwable
       {
          throw new UnreachableStatementException();
       }
 
-      public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
+      public TypeInfo getArrayType(int depth)
       {
          throw new UnreachableStatementException();
       }
 
-      public FieldInfo getDeclaredField(String name)
+      public String getName()
       {
          throw new UnreachableStatementException();
       }
 
-      public FieldInfo[] getDeclaredFields()
+      public Class getType()
       {
          throw new UnreachableStatementException();
       }
 
-      public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
+      public boolean isArray()
       {
          throw new UnreachableStatementException();
       }
 
-      public MethodInfo[] getDeclaredMethods()
+      public boolean isEnum()
       {
          throw new UnreachableStatementException();
       }
 
-      public InterfaceInfo[] getInterfaces()
+      public boolean isPrimitive()
       {
          throw new UnreachableStatementException();
       }
 
-      public String getName()
+      public Object[] newArrayInstance(int size) throws Throwable
       {
          throw new UnreachableStatementException();
       }
+   }
+   
+   static class UnknownClassInfo extends UnknownTypeInfo implements ClassInfo
+   {
+      /** The serialVersionUID */
+      private static final long serialVersionUID = 1L;
 
-      public ClassInfo getSuperclass()
+      public ConstructorInfo[] getDeclaredConstructors()
       {
          throw new UnreachableStatementException();
       }
 
-      public boolean isInterface()
+      public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
       {
          throw new UnreachableStatementException();
       }
 
-      public AnnotationValue getAnnotation(String name)
+      public FieldInfo getDeclaredField(String name)
       {
          throw new UnreachableStatementException();
       }
 
-      public AnnotationValue[] getAnnotations()
+      public FieldInfo[] getDeclaredFields()
       {
          throw new UnreachableStatementException();
       }
 
-      public boolean isAnnotationPresent(String name)
+      public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
       {
          throw new UnreachableStatementException();
       }
 
-      public String toShortString()
+      public MethodInfo[] getDeclaredMethods()
       {
          throw new UnreachableStatementException();
       }
 
-      public void toShortString(JBossStringBuilder buffer)
+      public InterfaceInfo[] getInterfaces()
       {
          throw new UnreachableStatementException();
       }
 
-      public Class getType()
+      public InterfaceInfo[] getGenericInterfaces()
       {
          throw new UnreachableStatementException();
       }
 
-      public Object convertValue(Object value) throws Throwable
+      public ClassInfo getSuperclass()
       {
          throw new UnreachableStatementException();
       }
 
-      public TypeInfo getArrayType(int depth)
+      public ClassInfo getGenericSuperclass()
       {
          throw new UnreachableStatementException();
       }
 
-      public boolean isArray()
+      public boolean isInterface()
       {
          throw new UnreachableStatementException();
       }
 
-      public boolean isEnum()
+      public AnnotationValue getAnnotation(String name)
       {
          throw new UnreachableStatementException();
       }
 
-      public boolean isPrimitive()
+      public AnnotationValue[] getAnnotations()
       {
          throw new UnreachableStatementException();
       }
 
-      public Object[] newArrayInstance(int size) throws Throwable
+      public boolean isAnnotationPresent(String name)
       {
          throw new UnreachableStatementException();
       }
 
+      public String toShortString()
+      {
+         throw new UnreachableStatementException();
+      }
+
+      public void toShortString(JBossStringBuilder buffer)
+      {
+         throw new UnreachableStatementException();
+      }
+
       public int getModifiers()
       {
          throw new UnreachableStatementException();
@@ -590,5 +669,20 @@
       {
          throw new UnreachableStatementException();
       }
+
+      public TypeInfo[] getActualTypeArguments()
+      {
+         throw new UnreachableStatementException();
+      }
+
+      public TypeInfo getOwnerType()
+      {
+         throw new UnreachableStatementException();
+      }
+
+      public ClassInfo getRawType()
+      {
+         throw new UnreachableStatementException();
+      }
    }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -21,6 +21,8 @@
 */
 package org.jboss.reflect.plugins.introspection;
 
+import java.lang.reflect.Type;
+
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.TypeInfoFactory;
 
@@ -46,4 +48,9 @@
    {
       return delegate.getTypeInfo(name, cl);
    }
+
+   public TypeInfo getTypeInfo(Type type)
+   {
+      return delegate.getTypeInfo(type);
+   }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -26,6 +26,8 @@
 import java.lang.reflect.Constructor;
 import java.lang.reflect.Field;
 import java.lang.reflect.Method;
+import java.lang.reflect.ParameterizedType;
+import java.lang.reflect.Type;
 import java.security.AccessController;
 import java.security.PrivilegedAction;
 
@@ -43,20 +45,20 @@
 import org.jboss.reflect.plugins.MethodInfoImpl;
 import org.jboss.reflect.spi.AnnotationInfo;
 import org.jboss.reflect.spi.AnnotationValue;
+import org.jboss.reflect.spi.ArrayInfo;
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.InterfaceInfo;
 import org.jboss.reflect.spi.PrimitiveInfo;
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.util.collection.WeakClassCache;
+import org.jboss.util.collection.temp.WeakTypeCache;
 
 /**
  * An introspection type factory.
  *
- * FIXME: use lazy loading to avoid reading the entire class model
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  */
-public class IntrospectionTypeInfoFactoryImpl extends WeakClassCache implements TypeInfoFactory, AnnotationHelper, ClassInfoHelper
+public class IntrospectionTypeInfoFactoryImpl extends WeakTypeCache<TypeInfo> implements TypeInfoFactory, AnnotationHelper, ClassInfoHelper
 {
    final static AnnotationValue[] NO_ANNOTATIONS = new AnnotationValue[0];
 
@@ -84,6 +86,19 @@
       return superType;
    }
 
+   public ClassInfo getGenericSuperClass(ClassInfoImpl classInfo)
+   {
+      Class clazz = classInfo.getType();
+      ClassInfo superType = null;
+      if (clazz.isInterface() == false)
+      {
+         Type superClazz = clazz.getGenericSuperclass();
+         if (superClazz != null)
+            superType = (ClassInfo) getTypeInfo(superClazz);
+      }
+      return superType;
+   }
+
    public AnnotationValue[] getAnnotations(Object obj)
    {
       Annotation[] annotations;
@@ -132,7 +147,7 @@
             for (int i = 0; i < constructors.length; ++i)
             {
                AnnotationValue[] annotations = getAnnotations(constructors[i]);
-               infos[i] = new ReflectConstructorInfoImpl(annotations, getTypeInfos(constructors[i].getParameterTypes()), getParameterAnnotations(constructors[i].getParameterAnnotations()), getClassInfos(constructors[i].getExceptionTypes()), constructors[i].getModifiers(), (ClassInfo) getTypeInfo(constructors[i].getDeclaringClass()));
+               infos[i] = new ReflectConstructorInfoImpl(annotations, getTypeInfos(constructors[i].getGenericParameterTypes()), getParameterAnnotations(constructors[i].getParameterAnnotations()), getClassInfos(constructors[i].getGenericExceptionTypes()), constructors[i].getModifiers(), (ClassInfo) getTypeInfo(constructors[i].getDeclaringClass()));
                infos[i].setConstructor(constructors[i]);
             }
          }
@@ -151,7 +166,7 @@
       for (int i = 0; i < fields.length; ++i)
       {
          AnnotationValue[] annotations = getAnnotations(fields[i]);
-         infos[i] = new ReflectFieldInfoImpl(annotations, fields[i].getName(), getTypeInfo(fields[i].getType()), fields[i].getModifiers(), (ClassInfo) getTypeInfo(fields[i].getDeclaringClass()));
+         infos[i] = new ReflectFieldInfoImpl(annotations, fields[i].getName(), getTypeInfo(fields[i].getGenericType()), fields[i].getModifiers(), (ClassInfo) getTypeInfo(fields[i].getDeclaringClass()));
          infos[i].setField(fields[i]);
       }
       
@@ -169,7 +184,7 @@
       for (int i = 0; i < methods.length; ++i)
       {
          AnnotationValue[] annotations = getAnnotations(methods[i]);
-         infos[i] = new ReflectMethodInfoImpl(annotations, methods[i].getName(), getTypeInfo(methods[i].getReturnType()), getTypeInfos(methods[i].getParameterTypes()), getParameterAnnotations(methods[i].getParameterAnnotations()), getClassInfos(methods[i].getExceptionTypes()), methods[i].getModifiers(), (ClassInfo) getTypeInfo(methods[i].getDeclaringClass()));
+         infos[i] = new ReflectMethodInfoImpl(annotations, methods[i].getName(), getTypeInfo(methods[i].getGenericReturnType()), getTypeInfos(methods[i].getGenericParameterTypes()), getParameterAnnotations(methods[i].getParameterAnnotations()), getClassInfos(methods[i].getGenericExceptionTypes()), methods[i].getModifiers(), (ClassInfo) getTypeInfo(methods[i].getDeclaringClass()));
          infos[i].setMethod(methods[i]);
       }
       return infos;
@@ -189,13 +204,27 @@
       return infos;
    }
 
+   public InterfaceInfo[] getGenericInterfaces(ClassInfoImpl classInfo)
+   {
+      Class clazz = classInfo.getType();
+      Type[] interfaces = clazz.getGenericInterfaces();
+      if (interfaces == null || interfaces.length == 0)
+         return null;
+
+      InterfaceInfo[] infos = new InterfaceInfo[interfaces.length];
+      for (int i = 0; i < interfaces.length; ++i)
+         infos[i] = (InterfaceInfo) getTypeInfo(interfaces[i]);
+
+      return infos;
+   }
+
    /**
     * Get the type infos for some classes
     *
     * @param classes the classes
     * @return the type infos
     */
-   public TypeInfo[] getTypeInfos(Class[] classes)
+   public TypeInfo[] getTypeInfos(Type[] classes)
    {
       if (classes == null || classes.length == 0)
          return null;
@@ -212,7 +241,7 @@
     * @param classes the classes
     * @return the class infos
     */
-   public ClassInfo[] getClassInfos(Class[] classes)
+   public ClassInfo[] getClassInfos(Type[] classes)
    {
       if (classes == null || classes.length == 0)
          return null;
@@ -232,9 +261,27 @@
       if (primitive != null)
          return primitive;
 
-      return (TypeInfo) get(clazz);
+      return get(clazz);
    }
 
+   public TypeInfo getTypeInfo(Type type)
+   {
+      if (type == null)
+         throw new IllegalArgumentException("Null type");
+
+      String name = null;
+      if (type instanceof Class)
+         name = ((Class) type).getName();
+      if (name != null)
+      {
+         TypeInfo primitive = PrimitiveInfo.valueOf(((Class) type).getName());
+         if (primitive != null)
+            return primitive;
+      }
+
+      return get(type);
+   }
+
    public TypeInfo getTypeInfo(String name, ClassLoader cl) throws ClassNotFoundException
    {
       if (name == null)
@@ -251,7 +298,7 @@
       return getTypeInfo(clazz);
    }
 
-   protected Object instantiate(Class clazz)
+   protected TypeInfo instantiate(Class<?> clazz)
    {
       ClassInfoImpl result;
       if (clazz.isArray())
@@ -295,11 +342,25 @@
       return result;
    }
 
-   protected void generate(Class clazz, Object result)
+   protected TypeInfo instantiate(ParameterizedType type)
    {
+      Class rawType = (Class) type.getRawType();
+      ClassInfo rawTypeInfo = (ClassInfo) getTypeInfo(rawType);
+      if (rawTypeInfo instanceof ArrayInfo)
+         return new ParameterizedArrayInfo(this, (ArrayInfo) rawTypeInfo, type);
+      return new ParameterizedClassInfo(this, rawTypeInfo, type);
+   }
+
+   protected void generate(Class<?> clazz, TypeInfo result)
+   {
       generateTypeInfo(clazz, (ClassInfoImpl) result);
    }
 
+   protected void generate(ParameterizedType type, TypeInfo result)
+   {
+      // Everything is lazy
+   }
+
    protected Constructor[] getDeclaredConstructors(final Class clazz)
    {
       if (System.getSecurityManager() == null)
@@ -402,4 +463,27 @@
       return annotationValues;
    }
 
+   public TypeInfo[] getActualTypeArguments(ParameterizedClassInfo classInfo)
+   {
+      ParameterizedType type = classInfo.parameterizedType;
+      Type[] types = type.getActualTypeArguments();
+      if (types == null)
+         return null;
+      
+      TypeInfo[] result = new TypeInfo[types.length];
+      for (int i = 0; i < types.length; ++i)
+         result[i] = getTypeInfo(types[i]);
+      
+      return result;
+   }
+   
+   public TypeInfo getOwnerType(ParameterizedClassInfo classInfo)
+   {
+      ParameterizedType type = classInfo.parameterizedType;
+      Type owner = type.getOwnerType();
+      if (owner == null)
+         return null;
+      
+      return getTypeInfo(owner);
+   }
 }

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,57 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.plugins.introspection;
+
+import java.lang.reflect.ParameterizedType;
+
+import org.jboss.reflect.plugins.ClassInfoHelper;
+import org.jboss.reflect.spi.ArrayInfo;
+import org.jboss.reflect.spi.TypeInfo;
+
+/**
+ * ParameterizedArrayInfo.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ParameterizedArrayInfo extends ParameterizedClassInfo implements ArrayInfo
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -2126867826240682161L;
+
+   /**
+    * Create a new ParameterizedArrayInfo.
+    * 
+    * @param helper the helper
+    * @param delegate the raw array info
+    * @param parameterizedType the parameterized  type
+    */
+   public ParameterizedArrayInfo(ClassInfoHelper helper, ArrayInfo delegate, ParameterizedType parameterizedType)
+   {
+      super(helper, delegate, parameterizedType);
+   }
+
+   public TypeInfo getComponentType()
+   {
+      return ((ArrayInfo) delegate).getComponentType();
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,251 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.plugins.introspection;
+
+import java.lang.reflect.ParameterizedType;
+
+import org.jboss.reflect.plugins.ClassInfoHelper;
+import org.jboss.reflect.plugins.ClassInfoImpl;
+import org.jboss.reflect.spi.AnnotationValue;
+import org.jboss.reflect.spi.ClassInfo;
+import org.jboss.reflect.spi.ConstructorInfo;
+import org.jboss.reflect.spi.FieldInfo;
+import org.jboss.reflect.spi.InterfaceInfo;
+import org.jboss.reflect.spi.MethodInfo;
+import org.jboss.reflect.spi.TypeInfo;
+import org.jboss.util.JBossObject;
+import org.jboss.util.JBossStringBuilder;
+
+/**
+ * ParameterizedClassInfo.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ParameterizedClassInfo extends JBossObject implements ClassInfo, InterfaceInfo
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -8739806147734002603L;
+   
+   /** The helper */
+   protected ClassInfoHelper helper;
+   
+   /** The raw class info */
+   protected ClassInfo delegate;
+   
+   /** The parameterized type */
+   ParameterizedType parameterizedType;
+   
+   /** The owner type */
+   private TypeInfo ownerType = ClassInfoImpl.UNKNOWN_TYPE;
+   
+   /** The type arguments */
+   private TypeInfo[] typeArguments = ClassInfoImpl.UNKNOWN_TYPES;
+   
+   /**
+    * Create a new ParameterizedClassInfo.
+    *
+    * @param helper the helper
+    * @param delegate the raw array info
+    * @param parameterizedType the parameterized  type
+    */
+   public ParameterizedClassInfo(ClassInfoHelper helper, ClassInfo delegate, ParameterizedType parameterizedType)
+   {
+      this.helper = helper;
+      this.delegate = delegate;
+      this.parameterizedType = parameterizedType;
+   }
+
+   public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
+   {
+      return delegate.getDeclaredConstructor(parameters);
+   }
+
+   public ConstructorInfo[] getDeclaredConstructors()
+   {
+      return delegate.getDeclaredConstructors();
+   }
+
+   public FieldInfo getDeclaredField(String name)
+   {
+      return delegate.getDeclaredField(name);
+   }
+
+   public FieldInfo[] getDeclaredFields()
+   {
+      return delegate.getDeclaredFields();
+   }
+
+   public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
+   {
+      return delegate.getDeclaredMethod(name, parameters);
+   }
+
+   public MethodInfo[] getDeclaredMethods()
+   {
+      return delegate.getDeclaredMethods();
+   }
+
+   public InterfaceInfo[] getGenericInterfaces()
+   {
+      return delegate.getGenericInterfaces();
+   }
+
+   public ClassInfo getGenericSuperclass()
+   {
+      return delegate.getGenericSuperclass();
+   }
+
+   public InterfaceInfo[] getInterfaces()
+   {
+      return delegate.getInterfaces();
+   }
+
+   public String getName()
+   {
+      return delegate.getName();
+   }
+
+   public ClassInfo getSuperclass()
+   {
+      return delegate.getSuperclass();
+   }
+
+   public boolean isInterface()
+   {
+      return delegate.isInterface();
+   }
+
+   public AnnotationValue getAnnotation(String name)
+   {
+      return delegate.getAnnotation(name);
+   }
+
+   public AnnotationValue[] getAnnotations()
+   {
+      return delegate.getAnnotations();
+   }
+
+   public boolean isAnnotationPresent(String name)
+   {
+      return delegate.isAnnotationPresent(name);
+   }
+
+   public int getModifiers()
+   {
+      return delegate.getModifiers();
+   }
+
+   public boolean isPublic()
+   {
+      return delegate.isPublic();
+   }
+
+   public boolean isStatic()
+   {
+      return delegate.isStatic();
+   }
+
+   public Object convertValue(Object value) throws Throwable
+   {
+      return delegate.convertValue(value);
+   }
+
+   public TypeInfo getArrayType(int depth)
+   {
+      return delegate.getArrayType(depth);
+   }
+   
+   public Class getType()
+   {
+      return delegate.getType();
+   }
+
+   public boolean isArray()
+   {
+      return delegate.isArray();
+   }
+
+   public boolean isEnum()
+   {
+      return delegate.isEnum();
+   }
+
+   public boolean isPrimitive()
+   {
+      return delegate.isPrimitive();
+   }
+
+   public Object[] newArrayInstance(int size) throws Throwable
+   {
+      return delegate.newArrayInstance(size);
+   }
+
+   public TypeInfo[] getActualTypeArguments()
+   {
+      if (typeArguments == ClassInfoImpl.UNKNOWN_TYPES)
+         typeArguments = helper.getActualTypeArguments(this);
+      return typeArguments;
+   }
+
+   public TypeInfo getOwnerType()
+   {
+      if (ownerType == ClassInfoImpl.UNKNOWN_TYPE)
+         ownerType = helper.getOwnerType(this);
+      return ownerType;
+   }
+
+   public ClassInfo getRawType()
+   {
+      return delegate;
+   }
+
+   protected int getHashCode()
+   {
+      return delegate.hashCode();
+   }
+
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      
+      if (obj == null || obj instanceof ClassInfo == false)
+         return false;
+      
+      ClassInfo other = (ClassInfo) obj;
+      if (other instanceof ParameterizedClassInfo)
+         other = ((ParameterizedClassInfo) other).delegate;
+      
+      return delegate.equals(other);
+   }
+
+   public void toShortString(JBossStringBuilder buffer)
+   {
+      buffer.append(parameterizedType);
+   }
+
+   protected void toString(JBossStringBuilder buffer)
+   {
+      buffer.append(parameterizedType);
+   }
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -23,7 +23,6 @@
 
 import javassist.CtClass;
 
-import org.jboss.reflect.spi.AnnotatedInfo;
 import org.jboss.reflect.spi.AnnotationValue;
 import org.jboss.reflect.spi.ArrayInfo;
 import org.jboss.reflect.spi.TypeInfo;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -156,6 +156,12 @@
       }
    }
 
+   public ClassInfo getGenericSuperclass()
+   {
+      // TODO getGenericSuperclass
+      throw new org.jboss.util.NotImplementedException("getGenericSuperclass");
+   }
+
    public InterfaceInfo[] getInterfaces()
    {
       try
@@ -174,6 +180,12 @@
       }
    }
 
+   public InterfaceInfo[] getGenericInterfaces()
+   {
+      // TODO getGenericInterfaces
+      throw new org.jboss.util.NotImplementedException("getGenericInterfaces");
+   }
+
    public ConstructorInfo[] getDeclaredConstructors()
    {
       if (constructorArray == null)
@@ -542,4 +554,19 @@
       }
    }
 
+   public TypeInfo[] getActualTypeArguments()
+   {
+      return null;
+   }
+
+   public TypeInfo getOwnerType()
+   {
+      return null;
+   }
+
+   public ClassInfo getRawType()
+   {
+      return this;
+   }
+
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -21,6 +21,8 @@
 */
 package org.jboss.reflect.plugins.javassist;
 
+import java.lang.reflect.Type;
+
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.TypeInfoFactory;
 
@@ -46,4 +48,10 @@
    {
       return delegate.getTypeInfo(name, cl);
    }
+   
+   public TypeInfo getTypeInfo(Type type)
+   {
+      return delegate.getTypeInfo(type);
+   }
+
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -22,6 +22,7 @@
 package org.jboss.reflect.plugins.javassist;
 
 import java.lang.annotation.Annotation;
+import java.lang.reflect.Type;
 
 import javassist.ClassPool;
 import javassist.CtClass;
@@ -273,6 +274,15 @@
       return getTypeInfo(clazz);
    }
    
+   public TypeInfo getTypeInfo(Type type)
+   {
+      if (type instanceof Class)
+         return getTypeInfo((Class) type);
+
+      // TODO getTypeInfo
+      throw new org.jboss.util.NotImplementedException("getTypeInfo");
+   }
+
    public AnnotationValue[] getAnnotations(Object obj)
    {
       try

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -51,6 +51,13 @@
    InterfaceInfo[] getInterfaces();
    
    /**
+    * Get the generic interfaces
+    *
+    * @return the generic interfaces
+    */
+   InterfaceInfo[] getGenericInterfaces();
+   
+   /**
     * Get the declared method
     * 
     * @param name the method name
@@ -102,4 +109,32 @@
     * @return the super class
     */
    ClassInfo getSuperclass();
+
+   /**
+    * Get the generic super class
+    * 
+    * @return the super class
+    */
+   ClassInfo getGenericSuperclass();
+   
+   /**
+    * Get the actual type parameters
+    * 
+    * @return the type parameters
+    */
+   TypeInfo[] getActualTypeArguments();
+   
+   /**
+    * Get the raw type
+    * 
+    * @return the raw type
+    */
+   ClassInfo getRawType();
+   
+   /**
+    * Get the owner type
+    * 
+    * @return the owner type
+    */
+   TypeInfo getOwnerType();
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -21,6 +21,8 @@
 */
 package org.jboss.reflect.spi;
 
+import java.lang.reflect.Type;
+
 /**
  * A type info factory.
  *
@@ -45,4 +47,12 @@
     * @return the type info
     */
    TypeInfo getTypeInfo(Class clazz);
+
+   /**
+    * Get a type info
+    * 
+    * @param type the type
+    * @return the type info
+    */
+   TypeInfo getTypeInfo(Type type);
 }

Added: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1 @@
+THESE CLASSES NEED TO BE MOVED TO COMMON WHEN IT SUPPORTS JDK5 + JBOSS RETRO
\ No newline at end of file

Added: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,283 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.util.collection.temp;
+
+import java.lang.reflect.GenericArrayType;
+import java.lang.reflect.ParameterizedType;
+import java.lang.reflect.Type;
+import java.lang.reflect.TypeVariable;
+import java.util.Map;
+import java.util.WeakHashMap;
+
+/**
+ * A weak class cache that instantiates does not a hold a
+ * strong reference to either the classloader or class.<p>
+ * 
+ * It creates the class specific data in two stages
+ * to avoid recursion.<p>
+ * 
+ * instantiate - creates the data<br>
+ * generate - fills in the details
+ *
+ * @param <T> the cached type
+ * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
+ */
+public abstract class WeakTypeCache<T>
+{
+   /** The cache */
+   private Map<ClassLoader, Map<String, T>> cache = new WeakHashMap<ClassLoader, Map<String, T>>(); 
+   
+   /**
+    * Get the information for a type
+    * 
+    * @param type the type
+    * @return the info
+    */
+   public T get(Type type)
+   {
+      if (type == null)
+         throw new IllegalArgumentException("Null type");
+
+      if (type instanceof ParameterizedType)
+         return getParameterizedType((ParameterizedType) type);
+      else if (type instanceof Class)
+         return getClass((Class<?>) type);
+      else if (type instanceof TypeVariable)
+         return getTypeVariable((TypeVariable) type);
+      else if (type instanceof GenericArrayType)
+         return getGenericArrayType((GenericArrayType) type);
+      else
+         throw new UnsupportedOperationException("Unknown type: " + type + " class=" + type.getClass());
+   }
+   
+   /**
+    * Get the information for a class
+    * 
+    * @param name the name
+    * @param cl the classloader
+    * @return the info
+    * @throws ClassNotFoundException when the class cannot be found
+    */
+   public T get(String name, ClassLoader cl) throws ClassNotFoundException
+   {
+      if (name == null)
+         throw new IllegalArgumentException("Null name");
+      if (cl == null)
+         throw new IllegalArgumentException("Null classloader");
+
+      Class<?> clazz = cl.loadClass(name);
+      return get(clazz);
+   }
+   
+   /**
+    * Instantiate for a class
+    * 
+    * @param clazz the class
+    * @return the result
+    */
+   protected abstract T instantiate(Class<?> clazz);
+   
+   /**
+    * Fill in the result
+    * 
+    * @param clazz the class
+    * @param result the result
+    */
+   protected abstract void generate(Class<?> clazz, T result);
+   
+   /**
+    * Instantiate for a parameterized type
+    * 
+    * @param type the parameterized type
+    * @return the result
+    */
+   protected abstract T instantiate(ParameterizedType type);
+   
+   /**
+    * Fill in the result
+    * 
+    * @param type the parameterized type
+    * @param result the result
+    */
+   protected abstract void generate(ParameterizedType type, T result);
+
+   /**
+    * Get the information for a parameterized type
+    * 
+    * @param type the paremeterized type
+    * @return the info
+    */
+   private T getParameterizedType(ParameterizedType type)
+   {
+      // First check if we already have it
+      T result = peek(type);
+      if (result != null)
+         return result;
+      
+      // Instantiate
+      result = instantiate(type);
+
+      // Put the perlimanary result into the cache
+      put(type, result);
+
+      // Generate the details
+      generate(type, result);
+      
+      return result;
+   }
+
+   /**
+    * Get the information for a type variable
+    * 
+    * @param type the type variable
+    * @return the info
+    */
+   private T getTypeVariable(TypeVariable type)
+   {
+      // TODO improve this
+      return get(type.getBounds()[0]);
+   }
+
+   /**
+    * Get the information for an array type
+    * 
+    * @param type the array type
+    * @return the info
+    */
+   private T getGenericArrayType(GenericArrayType type)
+   {
+      // TODO this needs implementing properly
+      return get(Object[].class);
+   }
+
+   /**
+    * Peek into the cache
+    * 
+    * @param type the type
+    * @return the value
+    */
+   private T peek(ParameterizedType type)
+   {
+      Class<?> rawType = (Class<?>) type.getRawType();
+      Map<String, T> classLoaderCache = getClassLoaderCache(rawType.getClassLoader());
+      
+      synchronized (classLoaderCache)
+      {
+         return classLoaderCache.get(type.toString());
+      }
+   }
+
+   /**
+    * Put a result into the cache
+    * 
+    * @param clazz the class
+    * @param result the value
+    */
+   private void put(ParameterizedType type, T result)
+   {
+      Class<?> rawType = (Class<?>) type.getRawType();
+      Map<String, T> classLoaderCache = getClassLoaderCache(rawType.getClassLoader());
+
+      synchronized (classLoaderCache)
+      {
+         // TODO something better than toString()?
+         classLoaderCache.put(type.toString(), result);
+      }
+   }
+
+   /**
+    * Get the information for a class
+    * 
+    * @param clazz the class
+    * @return the info
+    */
+   private T getClass(Class<?> clazz)
+   {
+      // First check if we already have it
+      T result = peek(clazz);
+      if (result != null)
+         return result;
+
+      // Instantiate
+      result = instantiate(clazz);
+
+      // Put the perlimanary result into the cache
+      put(clazz, result);
+
+      // Generate the details
+      generate(clazz, result);
+      
+      return result;
+   }
+
+   /**
+    * Peek into the cache
+    * 
+    * @param clazz the class
+    * @return the value
+    */
+   private T peek(Class<?> clazz)
+   {
+      Map<String, T> classLoaderCache = getClassLoaderCache(clazz.getClassLoader());
+
+      synchronized (classLoaderCache)
+      {
+         return classLoaderCache.get(clazz.getName());
+      }
+   }
+
+   /**
+    * Put a result into the cache
+    * 
+    * @param clazz the class
+    * @param result the value
+    */
+   private void put(Class<?> clazz, T result)
+   {
+      Map<String, T> classLoaderCache = getClassLoaderCache(clazz.getClassLoader());
+
+      synchronized (classLoaderCache)
+      {
+         classLoaderCache.put(clazz.getName(), result);
+      }
+   }
+   
+   /**
+    * Get the cache for the classloader
+    * 
+    * @param cl the classloader
+    * @return the map
+    */
+   private Map<String, T> getClassLoaderCache(ClassLoader cl)
+   {
+      synchronized (cache)
+      {
+         Map<String, T> result = cache.get(cl);
+         if (result == null)
+         {
+            result = new WeakValueHashMap<String, T>();
+            cache.put(cl, result);
+         }
+         return result;
+      }
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,293 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.util.collection.temp;
+
+import java.lang.ref.ReferenceQueue;
+import java.lang.ref.WeakReference;
+import java.util.AbstractMap;
+import java.util.AbstractSet;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.Set;
+
+
+/**
+ * This Map will remove entries when the value in the map has been
+ * cleaned from garbage collection
+ *
+ * @param <K> the key type
+ * @param <V> the value type
+ * @author  <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author  <a href="mailto:adrian at jboss.org">Adrian Brock</a>
+ * @version <tt>$Revision: 1958 $</tt>
+ */
+public class WeakValueHashMap<K, V> extends AbstractMap<K, V> 
+{
+   /** Hash table mapping keys to weak values */
+   private Map<K, WeakValueRef<K, V>> hash;
+
+   /** Reference queue for cleared WeakKeys */
+   private ReferenceQueue<V> queue = new ReferenceQueue<V>();
+
+   /**
+    * Constructs a new, empty <code>WeakHashMap</code> with the given
+    * initial capacity and the given load factor.
+    *
+    * @param  initialCapacity  The initial capacity of the
+    *                          <code>WeakHashMap</code>
+    *
+    * @param  loadFactor       The load factor of the <code>WeakHashMap</code>
+    *
+    * @throws IllegalArgumentException  If the initial capacity is less than
+    *                                   zero, or if the load factor is
+    *                                   nonpositive
+    */
+   public WeakValueHashMap(int initialCapacity, float loadFactor)
+   {
+      hash = new HashMap<K, WeakValueRef<K, V>>(initialCapacity, loadFactor);
+   }
+
+   /**
+    * Constructs a new, empty <code>WeakHashMap</code> with the given
+    * initial capacity and the default load factor, which is
+    * <code>0.75</code>.
+    *
+    * @param  initialCapacity  The initial capacity of the
+    *                          <code>WeakHashMap</code>
+    *
+    * @throws IllegalArgumentException  If the initial capacity is less than
+    *                                   zero
+    */
+   public WeakValueHashMap(int initialCapacity)
+   {
+      hash = new HashMap<K, WeakValueRef<K, V>>(initialCapacity);
+   }
+
+   /**
+    * Constructs a new, empty <code>WeakHashMap</code> with the default
+    * initial capacity and the default load factor, which is
+    * <code>0.75</code>.
+    */
+   public WeakValueHashMap()
+   {
+      hash = new HashMap<K, WeakValueRef<K, V>>();
+   }
+
+   /**
+    * Constructs a new <code>WeakHashMap</code> with the same mappings as the
+    * specified <tt>Map</tt>.  The <code>WeakHashMap</code> is created with an
+    * initial capacity of twice the number of mappings in the specified map
+    * or 11 (whichever is greater), and a default load factor, which is
+    * <tt>0.75</tt>.
+    *
+    * @param   t the map whose mappings are to be placed in this map.
+    * @since    1.3
+    */
+   public WeakValueHashMap(Map<K, V> t)
+   {
+      this(Math.max(2*t.size(), 11), 0.75f);
+      putAll(t);
+   }
+
+   @Override
+   public int size()
+   {
+      processQueue();
+      return hash.size();
+   }
+
+   @Override
+   public boolean containsKey(Object key)
+   {
+      processQueue();
+      return hash.containsKey(key);
+   }
+
+   @Override
+   public V get(Object key)
+   {
+      processQueue();
+      WeakValueRef<K, V> ref = hash.get(key);
+      if (ref != null)
+         return ref.get();
+      return null;
+   }
+
+   @Override
+   public V put(K key, V value) 
+   {
+      processQueue();
+      WeakValueRef<K, V> ref = WeakValueRef.create(key, value, queue);
+      WeakValueRef<K, V> result = hash.put(key, ref);
+      if (result != null)
+         return result.get();
+      return null;
+   }
+
+   @Override
+   public V remove(Object key) 
+   {
+      processQueue();
+      WeakValueRef<K, V> result = hash.remove(key);
+      if (result != null)
+         return result.get();
+      return null;
+   }
+   
+   @Override
+   public Set<Entry<K,V>> entrySet() 
+   { 
+      processQueue();
+      return new EntrySet();
+   }
+
+   @Override
+   public void clear()
+   {
+      processQueue();
+      hash.clear();
+   }
+   
+   /**
+    * Remove all entries whose values have been discarded.  
+    */
+   @SuppressWarnings("unchecked")
+   private void processQueue()
+   {
+      WeakValueRef<K, V> ref = (WeakValueRef<K, V>) queue.poll();
+      while (ref != null)
+      {
+         // only remove if it is the *exact* same WeakValueRef
+         if (ref == hash.get(ref.key))
+            hash.remove(ref.key);
+         
+         ref = (WeakValueRef<K, V>) queue.poll();
+      }
+   }
+   
+   /**
+    * EntrySet.
+    */
+   private class EntrySet extends AbstractSet<Entry<K, V>>
+   {
+      @Override
+      public Iterator<Entry<K, V>> iterator()
+      {
+         return new EntrySetIterator(hash.entrySet().iterator());
+      }
+
+      @Override
+      public int size()
+      {
+         return WeakValueHashMap.this.size();
+      }
+   }
+   
+   /**
+    * EntrySet iterator
+    */
+   private class EntrySetIterator implements Iterator<Entry<K, V>>
+   {
+      /** The delegate */
+      private Iterator<Entry<K, WeakValueRef<K, V>>> delegate;
+      
+      /**
+       * Create a new EntrySetIterator.
+       * 
+       * @param delegate the delegate
+       */
+      public EntrySetIterator(Iterator<Entry<K, WeakValueRef<K, V>>> delegate)
+      {
+         this.delegate = delegate;
+      }
+
+      public boolean hasNext()
+      {
+         return delegate.hasNext();
+      }
+
+      public Entry<K, V> next()
+      {
+         Entry<K, WeakValueRef<K, V>> next = delegate.next();
+         return next.getValue();
+      }
+
+      public void remove()
+      {
+         throw new UnsupportedOperationException("remove");
+      }
+   }
+   
+   /**
+    * WeakValueRef.
+    */
+   private static class WeakValueRef<K, V> extends WeakReference<V> implements Map.Entry<K, V>
+   {
+      /** The key */
+      public K key;
+
+      /**
+       * Safely create a new WeakValueRef
+       * 
+       * @param key the key
+       * @param val the value
+       * @param q the reference queue
+       * @return the reference or null if the value is null
+       */
+      private static <K, V> WeakValueRef<K, V> create(K key, V val, ReferenceQueue<V> q)
+      {
+         if (val == null)
+            return null;
+         else 
+            return new WeakValueRef<K, V>(key, val, q);
+      }
+
+      /**
+       * Create a new WeakValueRef.
+       * 
+       * @param key the key
+       * @param val the value
+       * @param q the reference queue
+       */
+      private WeakValueRef(K key, V val, ReferenceQueue<V> q)
+      {
+         super(val, q);
+         this.key = key;
+      }
+
+      public K getKey()
+      {
+         return key;
+      }
+
+      public V getValue()
+      {
+         return get();
+      }
+
+      public V setValue(V value)
+      {
+         throw new UnsupportedOperationException("setValue");
+      }
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,33 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericClass
+ * 
+ * @param <T> the generic type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericClass<T>
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,34 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericConstructors
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericConstructorsClass
+{
+   ClassInfoGenericConstructorsClass(ClassInfoGenericClass<String> p1) {};
+   ClassInfoGenericConstructorsClass(ClassInfoGenericClass<String> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {};
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,34 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericField
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericFieldsClass
+{
+   ClassInfoGenericClass<String> fieldString;
+   ClassInfoGenericClass<ClassInfoEmptyClass> fieldClass;
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,34 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericFieldsInterface
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface ClassInfoGenericFieldsInterface
+{
+   ClassInfoGenericClass<String> fieldString = null;
+   ClassInfoGenericClass<ClassInfoEmptyClass> fieldClass = null;
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,33 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericInterface
+ * 
+ * @param <T> the generic type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface ClassInfoGenericInterface<T>
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,38 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericMethods
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericMethodsClass
+{
+   void doSomething(ClassInfoGenericClass<String> p1) {};
+   void doSomething(ClassInfoGenericClass<String> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {};
+   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1) {return null;};
+   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {return null;};
+   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1) {return null;};
+   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {return null;};
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,38 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericMethods
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface ClassInfoGenericMethodsInterface
+{
+   void doSomething(ClassInfoGenericClass<String> p1);
+   void doSomething(ClassInfoGenericClass<String> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2);
+   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1);
+   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2);
+   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1);
+   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2);
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoSuperClass
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericSuperClassEmptyClass extends ClassInfoGenericClass<ClassInfoEmptyClass>
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoSuperClass
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericSuperClassString extends ClassInfoGenericClass<String>
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericSuperInterfaceEmptyClass.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericSuperInterfaceEmptyClass implements ClassInfoGenericInterface<ClassInfoEmptyClass>
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
+
+/**
+ * ClassInfoGenericSuperInterfaceString.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassInfoGenericSuperInterfaceString implements ClassInfoGenericInterface<String>
+{
+}

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -26,6 +26,7 @@
 import java.lang.reflect.Constructor;
 import java.lang.reflect.Field;
 import java.lang.reflect.Method;
+import java.lang.reflect.Type;
 import java.util.Arrays;
 import java.util.HashMap;
 import java.util.HashSet;
@@ -187,7 +188,7 @@
       Set<FieldInfo> expected = new HashSet<FieldInfo>();
       for (Field field : clazz.getDeclaredFields())
       {
-         TypeInfo type = factory.getTypeInfo(field.getType());
+         TypeInfo type = factory.getTypeInfo(field.getGenericType());
          FieldInfo f = new FieldInfoImpl(null, field.getName(), type, field.getModifiers(), classInfo);
          expected.add(f);
       }
@@ -218,8 +219,8 @@
       
       FieldInfo fieldInfo = classInfo.getDeclaredField(field.getName());
       assertNotNull(field.getName(), fieldInfo);
-      TypeInfo type = factory.getTypeInfo(field.getType());
-      assertEquals(type, fieldInfo.getType());
+      TypeInfo type = factory.getTypeInfo(field.getGenericType());
+      assertTypeEquals(field.getName(), type, fieldInfo.getType());
       assertEquals(classInfo, fieldInfo.getDeclaringClass());
       assertEquals(field.getModifiers(), fieldInfo.getModifiers());
       assertFieldAnnotations(field, fieldInfo);
@@ -266,24 +267,24 @@
 
       TypeInfoFactory factory = getTypeInfoFactory();
       
-      Class[] paramClasses = method.getParameterTypes();
+      Type[] paramClasses = method.getGenericParameterTypes();
       TypeInfo[] paramTypes = new TypeInfo[paramClasses.length];
       for (int i = 0; i < paramClasses.length; ++i)
          paramTypes[i] = factory.getTypeInfo(paramClasses[i]);
       MethodInfo methodInfo = classInfo.getDeclaredMethod(method.getName(), paramTypes);
       assertNotNull(method.getName(), methodInfo);
-      TypeInfo returnType = factory.getTypeInfo(method.getReturnType());
+      TypeInfo returnType = factory.getTypeInfo(method.getGenericReturnType());
       TypeInfo[] actualParamTypes = methodInfo.getParameterTypes();
       for (int i = 0; i < paramTypes.length; ++i)
-         assertEquals(paramTypes[i], actualParamTypes[i]);
+         assertTypeEquals(method.getName() + " param" + i, paramTypes[i], actualParamTypes[i]);
       Class[] exceptionClasses = method.getExceptionTypes();
       TypeInfo[] expectedExceptionTypes = new TypeInfo[exceptionClasses.length];
       for (int i = 0; i < exceptionClasses.length; ++i)
          expectedExceptionTypes[i] = factory.getTypeInfo(exceptionClasses[i]);
       TypeInfo[] actualExceptionTypes = methodInfo.getExceptionTypes();
       for (int i = 0; i < exceptionClasses.length; ++i)
-         assertEquals(expectedExceptionTypes[i], actualExceptionTypes[i]);
-      assertEquals(returnType, methodInfo.getReturnType());
+         assertTypeEquals(method.getName() + " exception" + i, expectedExceptionTypes[i], actualExceptionTypes[i]);
+      assertTypeEquals(method.getName() + " returnType", returnType, methodInfo.getReturnType());
       assertEquals(classInfo, methodInfo.getDeclaringClass());
       assertEquals(method.getModifiers(), methodInfo.getModifiers());
       assertMethodAnnotations(method, methodInfo);
@@ -330,7 +331,7 @@
 
       TypeInfoFactory factory = getTypeInfoFactory();
       
-      Class[] paramClasses = constructor.getParameterTypes();
+      Type[] paramClasses = constructor.getGenericParameterTypes();
       TypeInfo[] paramTypes = new TypeInfo[paramClasses.length];
       for (int i = 0; i < paramClasses.length; ++i)
          paramTypes[i] = factory.getTypeInfo(paramClasses[i]);
@@ -338,14 +339,14 @@
       assertNotNull(constructorInfo);
       TypeInfo[] actualParamTypes = constructorInfo.getParameterTypes();
       for (int i = 0; i < paramTypes.length; ++i)
-         assertEquals(paramTypes[i], actualParamTypes[i]);
+         assertTypeEquals(clazz + " constructorParameter" + i, paramTypes[i], actualParamTypes[i]);
       Class[] exceptionClasses = constructor.getExceptionTypes();
       TypeInfo[] expectedExceptionTypes = new TypeInfo[exceptionClasses.length];
       for (int i = 0; i < exceptionClasses.length; ++i)
          expectedExceptionTypes[i] = factory.getTypeInfo(exceptionClasses[i]);
       TypeInfo[] actualExceptionTypes = constructorInfo.getExceptionTypes();
       for (int i = 0; i < exceptionClasses.length; ++i)
-         assertEquals(expectedExceptionTypes[i], actualExceptionTypes[i]);
+         assertTypeEquals(clazz + " constructorException" + i, expectedExceptionTypes[i], actualExceptionTypes[i]);
       assertEquals(classInfo, constructorInfo.getDeclaringClass());
       assertEquals(constructor.getModifiers(), constructorInfo.getModifiers());
       assertConstructorAnnotations(constructor, constructorInfo);
@@ -476,6 +477,30 @@
       }
       return expected;
    }
+
+   protected void assertTypeEquals(String context, TypeInfo expected, TypeInfo actual) throws Exception
+   {
+      assertEquals(expected, actual);
+      if (expected instanceof ClassInfo)
+      {
+         ClassInfo expectedClassInfo = (ClassInfo) expected;
+         ClassInfo actualClassInfo = (ClassInfo) actual;
+         assertEquals(context, expectedClassInfo.getOwnerType(), actualClassInfo.getOwnerType());
+         assertEquals(context, expectedClassInfo.getRawType(), actualClassInfo.getRawType());
+         TypeInfo[] expectedTypeArgs = expectedClassInfo.getActualTypeArguments();
+         TypeInfo[] actualTypeArgs = expectedClassInfo.getActualTypeArguments();
+         if (expectedTypeArgs == null)
+            assertNull(context, actualTypeArgs);
+         else
+         {
+            assertNotNull(context, actualTypeArgs);
+            getLog().debug("Checking type args for " + context + " expected: " + Arrays.asList(expectedTypeArgs) + " actual: " + Arrays.asList(actualTypeArgs));
+            assertEquals(expectedTypeArgs.length, actualTypeArgs.length);
+            for (int i = 0; i < expectedTypeArgs.length; ++i)
+               assertTypeEquals(context + "arg" + i, expectedTypeArgs[i], actualTypeArgs[i]);
+         }
+      }
+   }
    
    protected abstract TypeInfoFactory getTypeInfoFactory();
    

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,145 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
+
+import java.lang.reflect.Modifier;
+import java.util.Arrays;
+
+import org.jboss.reflect.plugins.ClassInfoImpl;
+import org.jboss.reflect.spi.ClassInfo;
+import org.jboss.reflect.spi.InterfaceInfo;
+import org.jboss.reflect.spi.TypeInfo;
+import org.jboss.reflect.spi.TypeInfoFactory;
+import org.jboss.test.classinfo.support.ClassInfoEmptyClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericConstructorsClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericFieldsClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericInterface;
+import org.jboss.test.classinfo.support.ClassInfoGenericMethodsClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericSuperClassEmptyClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericSuperClassString;
+import org.jboss.test.classinfo.support.ClassInfoGenericSuperInterfaceEmptyClass;
+import org.jboss.test.classinfo.support.ClassInfoGenericSuperInterfaceString;
+
+
+/**
+ * ClassInfoGenericClassTest.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ClassInfoGenericClassTest extends AbstractClassInfoTest
+{
+   public ClassInfoGenericClassTest(String name)
+   {
+      super(name);
+   }
+   
+   public void testGenericSuperClassString()
+   {
+      testGenericSuperClass(ClassInfoGenericSuperClassString.class, ClassInfoGenericClass.class, new Class[] { String.class });
+   }
+   
+   public void testGenericSuperClassEmptyClass()
+   {
+      testGenericSuperClass(ClassInfoGenericSuperClassEmptyClass.class, ClassInfoGenericClass.class, new Class[] { ClassInfoEmptyClass.class });
+   }
+   
+   public void testGenericSuperInterfaceString()
+   {
+      testGenericSuperInterface(ClassInfoGenericSuperInterfaceString.class, ClassInfoGenericInterface.class, new Class[] { String.class });
+   }
+   
+   public void testGenericSuperInterfaceEmptyClass()
+   {
+      testGenericSuperInterface(ClassInfoGenericSuperInterfaceEmptyClass.class, ClassInfoGenericInterface.class, new Class[] { ClassInfoEmptyClass.class });
+   }
+   
+   public void testGenericSuperClass(Class clazz, Class genericClass, Class[] genericTypes)
+   {
+      TypeInfoFactory factory = getTypeInfoFactory();
+      ClassInfo typeInfo = (ClassInfo) factory.getTypeInfo(clazz);
+      ClassInfo superClassInfo = typeInfo.getGenericSuperclass();
+      ClassInfo genericClassInfo = (ClassInfo) factory.getTypeInfo(genericClass);
+      getLog().debug("Checking superClass: " + genericClass + " against " + superClassInfo);
+      assertEquals(genericClassInfo, superClassInfo);
+
+      TypeInfo[] types = new TypeInfo[genericTypes.length];
+      for (int i = 0; i < types.length; ++i)
+         types[i] = factory.getTypeInfo(genericTypes[i]);
+      TypeInfo[] actualTypes = superClassInfo.getActualTypeArguments();
+      getLog().debug("Checking superClass types: " + Arrays.asList(genericTypes) + " against " + Arrays.asList(actualTypes));
+      assertEquals(types.length, actualTypes.length);
+      for (int i = 0; i < types.length; ++i)
+         assertEquals(types[i], actualTypes[i]);
+   }
+   
+   public void testGenericSuperInterface(Class clazz, Class genericClass, Class[] genericTypes)
+   {
+      TypeInfoFactory factory = getTypeInfoFactory();
+      ClassInfo typeInfo = (ClassInfo) factory.getTypeInfo(clazz);
+      InterfaceInfo[] superInterfaces = typeInfo.getGenericInterfaces();
+      assertNotNull(superInterfaces);
+      assertEquals(1, superInterfaces.length);
+      InterfaceInfo superInterface = superInterfaces[0]; 
+      getLog().debug("Checking superInterface: " + genericClass + " against " + superInterface);
+      ClassInfo genericClassInfo = (ClassInfo) factory.getTypeInfo(genericClass);
+      assertEquals(genericClassInfo, superInterface);
+
+      TypeInfo[] types = new TypeInfo[genericTypes.length];
+      for (int i = 0; i < types.length; ++i)
+         types[i] = factory.getTypeInfo(genericTypes[i]);
+      TypeInfo[] actualTypes = superInterface.getActualTypeArguments();
+      getLog().debug("Checking superInterface types: " + Arrays.asList(genericTypes) + " against " + Arrays.asList(actualTypes));
+      assertEquals(types.length, actualTypes.length);
+      for (int i = 0; i < types.length; ++i)
+         assertEquals(types[i], actualTypes[i]);
+   }
+
+   public void testGenericMethodsClass() throws Throwable
+   {
+      testGenericClass(ClassInfoGenericMethodsClass.class);
+   }
+
+   public void testGenericConstructorsClass() throws Throwable
+   {
+      testGenericClass(ClassInfoGenericConstructorsClass.class);
+   }
+   
+   public void testGenericFieldsClass() throws Throwable
+   {
+      testGenericClass(ClassInfoGenericFieldsClass.class);
+   }
+   
+   private void testGenericClass(Class clazz) throws Throwable
+   {
+      ClassInfoImpl expected = new ClassInfoImpl(clazz.getName(), Modifier.PUBLIC);
+      TypeInfo info = testBasics(clazz, expected);
+      
+      assertFalse(info.isArray());
+      assertFalse(info.isEnum());
+      assertFalse(info.isPrimitive());
+      
+      ClassInfo classInfo = (ClassInfo) info;
+      assertClassInfo(classInfo, clazz);
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
+
+import java.lang.reflect.Modifier;
+
+import org.jboss.reflect.plugins.ClassInfoImpl;
+import org.jboss.reflect.spi.ClassInfo;
+import org.jboss.reflect.spi.TypeInfo;
+import org.jboss.test.classinfo.support.ClassInfoGenericFieldsInterface;
+import org.jboss.test.classinfo.support.ClassInfoGenericMethodsInterface;
+
+/**
+ * ClassInfoInterfaceTest.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ClassInfoGenericInterfaceTest extends AbstractClassInfoTest
+{
+   public ClassInfoGenericInterfaceTest(String name)
+   {
+      super(name);
+   }
+
+   public void testGenericMethodsInterface() throws Throwable
+   {
+      testGenericInterface(ClassInfoGenericMethodsInterface.class);
+   }
+   
+   public void testGenericFieldsInterface() throws Throwable
+   {
+      testGenericInterface(ClassInfoGenericFieldsInterface.class);
+   }
+   
+   private void testGenericInterface(Class clazz) throws Throwable
+   {
+      ClassInfoImpl expected = new ClassInfoImpl(clazz.getName(), Modifier.PUBLIC);
+      TypeInfo info = testBasics(clazz, expected);
+      
+      assertFalse(info.isArray());
+      assertFalse(info.isEnum());
+      assertFalse(info.isPrimitive());
+      
+      ClassInfo classInfo = (ClassInfo) info;
+      assertClassInfo(classInfo, clazz);
+   }
+}

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -56,6 +56,8 @@
       suite.addTest(JavassistClassInfoTestCase.suite());
       suite.addTest(IntrospectionAnnotatedClassInfoTestCase.suite());
       suite.addTest(JavassistAnnotatedClassInfoTestCase.suite());
+      suite.addTest(IntrospectionGenericInterfaceUnitTestCase.suite());
+      suite.addTest(IntrospectionGenericClassUnitTestCase.suite());
       
       return suite;
    }

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,52 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
+
+import junit.framework.Test;
+
+import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory;
+import org.jboss.reflect.spi.TypeInfoFactory;
+
+/**
+ * Introspection ClassInfo Test Case.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 45663 $
+ */
+public class IntrospectionGenericClassUnitTestCase extends ClassInfoGenericClassTest
+{
+   public static Test suite()
+   {
+      return suite(IntrospectionGenericClassUnitTestCase.class);
+   }
+   
+   public IntrospectionGenericClassUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   protected TypeInfoFactory getTypeInfoFactory()
+   {
+      return new IntrospectionTypeInfoFactory();
+   }
+
+}
\ No newline at end of file

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java	2006-12-04 14:20:46 UTC (rev 58837)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java	2006-12-04 14:40:50 UTC (rev 58838)
@@ -0,0 +1,51 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
+
+import junit.framework.Test;
+
+import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory;
+import org.jboss.reflect.spi.TypeInfoFactory;
+
+/**
+ * IntrospectionGenericInterfaceUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class IntrospectionGenericInterfaceUnitTestCase extends ClassInfoGenericInterfaceTest
+{
+   public IntrospectionGenericInterfaceUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public static Test suite()
+   {
+      return suite(IntrospectionGenericInterfaceUnitTestCase.class);
+   }
+
+   protected TypeInfoFactory getTypeInfoFactory()
+   {
+      return new IntrospectionTypeInfoFactory();
+   }
+}



From sacha.labourey.ml at jboss.org  Mon Dec  4 10:08:17 2006
From: sacha.labourey.ml at jboss.org (Sacha Labourey)
Date: Mon, 04 Dec 2006 16:08:17 +0100
Subject: [jboss-cvs] JBossAS SVN: r58838 -
	in	projects/microcontainer/trunk/container/src:
	main/org/jboss	main/org/jboss/beans/info/plugins
	main/org/jboss/reflect/plugins
	main/org/jboss/reflect/plugins/introspection	main/org/jboss/reflect/plugins/javassist
	main/org/jboss/reflect/spi
	main/org/jboss/util	main/org/jboss/util/collection
	main/org/jboss/util/collection/temp	tests/org/jboss/test/classinfo/support
	tests/org/jboss/test/classinfo/test
In-Reply-To: <E1GrF0N-00083W-4l@committer01.frg.pub.inap.atl.jboss.com>
References: <E1GrF0N-00083W-4l@committer01.frg.pub.inap.atl.jboss.com>
Message-ID: <457439E1.8010109@jboss.org>

Adrian is on fire! (as always :) )

jboss-cvs-commits at lists.jboss.org wrote:
> Author: adrian at jboss.org
> Date: 2006-12-04 09:40:50 -0500 (Mon, 04 Dec 2006)
> New Revision: 58838
>
> Added:
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/util/
>    projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/
>    projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/
>    projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME
>    projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java
> Modified:
>    projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java
>    projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java
>    projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java
> Log:
> Generification of the TypeInfo api.
>
> TODO:
> * Complete the support for TypeVariable and GenericArray
> * Implement this for the javassist version
> * Move the org.jboss.util.collection.temp to the common-core project once
> it properly supports JDK5
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -42,7 +42,7 @@
>  import org.jboss.reflect.spi.PrimitiveInfo;
>  import org.jboss.reflect.spi.TypeInfo;
>  import org.jboss.util.JBossStringBuilder;
> -import org.jboss.util.collection.WeakValueHashMap;
> +import org.jboss.util.collection.temp.WeakValueHashMap;
>  
>  /**
>   * A bean info factory.
> @@ -140,7 +140,7 @@
>           BeanInfo result = createBeanInfo(classAdapter, properties, constructors, methods, events);
>           if (map == null)
>           {
> -            map = new WeakValueHashMap();
> +            map = new WeakValueHashMap<String, BeanInfo>();
>              cache.put(cl, map);
>           }
>           map.put(className, result);
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayInfoImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -21,7 +21,6 @@
>  */
>  package org.jboss.reflect.plugins;
>  
> -import org.jboss.reflect.spi.AnnotatedInfo;
>  import org.jboss.reflect.spi.AnnotationValue;
>  import org.jboss.reflect.spi.ArrayInfo;
>  import org.jboss.reflect.spi.TypeInfo;
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoHelper.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -21,6 +21,8 @@
>  */
>  package org.jboss.reflect.plugins;
>  
> +import org.jboss.reflect.plugins.introspection.ParameterizedClassInfo;
> +import org.jboss.reflect.spi.ClassInfo;
>  import org.jboss.reflect.spi.InterfaceInfo;
>  import org.jboss.reflect.spi.TypeInfo;
>  
> @@ -41,6 +43,14 @@
>     ClassInfoImpl getSuperClass(ClassInfoImpl classInfo);
>  
>     /**
> +    * Get the generic super class
> +    * 
> +    * @param classInfo the class info
> +    * @return the super class info
> +    */
> +   ClassInfo getGenericSuperClass(ClassInfoImpl classInfo);
> +
> +   /**
>      * Get the interfaces
>      * 
>      * @param classInfo the class info
> @@ -49,6 +59,14 @@
>     InterfaceInfo[] getInterfaces(ClassInfoImpl classInfo);
>  
>     /**
> +    * Get the generic interfaces
> +    * 
> +    * @param classInfo the class info
> +    * @return the interface info
> +    */
> +   InterfaceInfo[] getGenericInterfaces(ClassInfoImpl classInfo);
> +
> +   /**
>      * Get the constructors
>      * 
>      * @param classInfo the class info
> @@ -79,4 +97,20 @@
>      * @return the type info
>      */
>     TypeInfo getTypeInfo(Class clazz);
> +   
> +   /**
> +    * Get the actual type parameters
> +    * 
> +    * @param classInfo the parameterized class info
> +    * @return the type parameters
> +    */
> +   TypeInfo[] getActualTypeArguments(ParameterizedClassInfo classInfo);
> +   
> +   /**
> +    * Get the owner type
> +    * 
> +    * @param classInfo the parameterized class info
> +    * @return the owner type
> +    */
> +   TypeInfo getOwnerType(ParameterizedClassInfo classInfo);
>  }
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -48,19 +48,28 @@
>     private static final long serialVersionUID = 3545798779904340792L;
>  
>     /** Marker for generation */
> -   static final ClassInfo UNKNOWN_CLASS = new UnknownClassInfo();
> +   public static final ClassInfo UNKNOWN_CLASS = new UnknownClassInfo();
>  
>     /** Marker for generation */
> -   static final InterfaceInfo[] UNKNOWN_INTERFACES = new InterfaceInfo[0];
> +   public static final ClassInfo[] UNKNOWN_CLASSES = new UnknownClassInfo[0];
>  
>     /** Marker for generation */
> -   static final ConstructorInfo[] UNKNOWN_CONSTRUCTORS = new ConstructorInfo[0];
> +   public static final TypeInfo UNKNOWN_TYPE = new UnknownTypeInfo();
>  
>     /** Marker for generation */
> -   static final MethodInfo[] UNKNOWN_METHODS = new MethodInfo[0];
> +   public static final TypeInfo[] UNKNOWN_TYPES = new UnknownTypeInfo[0];
>  
>     /** Marker for generation */
> -   private static final FieldInfo[] UNKNOWN_FIELDS = new FieldInfo[0];
> +   public static final InterfaceInfo[] UNKNOWN_INTERFACES = new InterfaceInfo[0];
> +
> +   /** Marker for generation */
> +   public static final ConstructorInfo[] UNKNOWN_CONSTRUCTORS = new ConstructorInfo[0];
> +
> +   /** Marker for generation */
> +   public static final MethodInfo[] UNKNOWN_METHODS = new MethodInfo[0];
> +
> +   /** Marker for generation */
> +   public static final FieldInfo[] UNKNOWN_FIELDS = new FieldInfo[0];
>     
>     /** The class name */
>     protected String name;
> @@ -71,6 +80,9 @@
>     /** The interfaces */
>     protected InterfaceInfo[] interfaces = UNKNOWN_INTERFACES;
>     
> +   /** The generic interfaces */
> +   protected InterfaceInfo[] genericInterfaces = UNKNOWN_INTERFACES;
> +   
>     /** The methods */
>     protected MethodInfo[] methods = UNKNOWN_METHODS;
>     
> @@ -83,6 +95,9 @@
>     /** The super class */
>     protected ClassInfo superclass = UNKNOWN_CLASS;
>  
> +   /** The generic super class */
> +   protected ClassInfo genericSuperclass = UNKNOWN_CLASS;
> +
>     /** The constructor info */
>     protected ConstructorInfo[] constructors = UNKNOWN_CONSTRUCTORS; 
>  
> @@ -243,6 +258,16 @@
>     {
>        this.interfaces = interfaces;
>     }
> +   
> +   /**
> +    * Set the generic interfaces
> +    * 
> +    * @param interfaces the interfaces
> +    */
> +   public void setGenericInterfaces(InterfaceInfo[] interfaces)
> +   {
> +      this.genericInterfaces = interfaces;
> +   }
>  
>     /**
>      * Set the declared methods
> @@ -303,6 +328,15 @@
>        this.superclass = superInfo;
>     }
>  
> +   /**
> +    * Set the generic super class
> +    * 
> +    * @param superInfo the super class
> +    */
> +   public void setGenericSuperclass(ClassInfo superInfo)
> +   {
> +      this.genericSuperclass = superInfo;
> +   }
>  
>     public boolean isInterface()
>     {
> @@ -315,6 +349,13 @@
>           setInterfaces(classInfoHelper.getInterfaces(this));
>        return interfaces;
>     }
> +
> +   public InterfaceInfo[] getGenericInterfaces()
> +   {
> +      if (genericInterfaces == UNKNOWN_INTERFACES)
> +         setGenericInterfaces(classInfoHelper.getGenericInterfaces(this));
> +      return genericInterfaces;
> +   }
>     
>     public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
>     {
> @@ -366,6 +407,13 @@
>           setSuperclass(classInfoHelper.getSuperClass(this));
>        return superclass;
>     }
> +
> +   public ClassInfo getGenericSuperclass()
> +   {
> +      if (genericSuperclass == UNKNOWN_CLASS)
> +         setGenericSuperclass(classInfoHelper.getGenericSuperClass(this));
> +      return genericSuperclass;
> +   }
>     
>     public int getModifiers()
>     {
> @@ -426,6 +474,21 @@
>        return (Object[]) Array.newInstance(clazz.getComponentType(), size);
>     }
>  
> +   public TypeInfo[] getActualTypeArguments()
> +   {
> +      return null;
> +   }
> +
> +   public TypeInfo getOwnerType()
> +   {
> +      return null;
> +   }
> +
> +   public ClassInfo getRawType()
> +   {
> +      return this;
> +   }
> +
>     protected InheritableAnnotationHolder getSuperHolder()
>     {
>        return (ClassInfoImpl) getSuperclass();
> @@ -456,121 +519,137 @@
>        return (name != null ? name.hashCode() : 0);
>     }
>     
> -   static class UnknownClassInfo implements ClassInfo
> +   public static class UnknownTypeInfo implements TypeInfo
>     {
>        /** The serialVersionUID */
>        private static final long serialVersionUID = 1L;
>  
> -      public ConstructorInfo[] getDeclaredConstructors()
> +      public Object convertValue(Object value) throws Throwable
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
> +      public TypeInfo getArrayType(int depth)
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public FieldInfo getDeclaredField(String name)
> +      public String getName()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public FieldInfo[] getDeclaredFields()
> +      public Class getType()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
> +      public boolean isArray()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public MethodInfo[] getDeclaredMethods()
> +      public boolean isEnum()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public InterfaceInfo[] getInterfaces()
> +      public boolean isPrimitive()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public String getName()
> +      public Object[] newArrayInstance(int size) throws Throwable
>        {
>           throw new UnreachableStatementException();
>        }
> +   }
> +   
> +   static class UnknownClassInfo extends UnknownTypeInfo implements ClassInfo
> +   {
> +      /** The serialVersionUID */
> +      private static final long serialVersionUID = 1L;
>  
> -      public ClassInfo getSuperclass()
> +      public ConstructorInfo[] getDeclaredConstructors()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public boolean isInterface()
> +      public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public AnnotationValue getAnnotation(String name)
> +      public FieldInfo getDeclaredField(String name)
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public AnnotationValue[] getAnnotations()
> +      public FieldInfo[] getDeclaredFields()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public boolean isAnnotationPresent(String name)
> +      public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public String toShortString()
> +      public MethodInfo[] getDeclaredMethods()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public void toShortString(JBossStringBuilder buffer)
> +      public InterfaceInfo[] getInterfaces()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public Class getType()
> +      public InterfaceInfo[] getGenericInterfaces()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public Object convertValue(Object value) throws Throwable
> +      public ClassInfo getSuperclass()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public TypeInfo getArrayType(int depth)
> +      public ClassInfo getGenericSuperclass()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public boolean isArray()
> +      public boolean isInterface()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public boolean isEnum()
> +      public AnnotationValue getAnnotation(String name)
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public boolean isPrimitive()
> +      public AnnotationValue[] getAnnotations()
>        {
>           throw new UnreachableStatementException();
>        }
>  
> -      public Object[] newArrayInstance(int size) throws Throwable
> +      public boolean isAnnotationPresent(String name)
>        {
>           throw new UnreachableStatementException();
>        }
>  
> +      public String toShortString()
> +      {
> +         throw new UnreachableStatementException();
> +      }
> +
> +      public void toShortString(JBossStringBuilder buffer)
> +      {
> +         throw new UnreachableStatementException();
> +      }
> +
>        public int getModifiers()
>        {
>           throw new UnreachableStatementException();
> @@ -590,5 +669,20 @@
>        {
>           throw new UnreachableStatementException();
>        }
> +
> +      public TypeInfo[] getActualTypeArguments()
> +      {
> +         throw new UnreachableStatementException();
> +      }
> +
> +      public TypeInfo getOwnerType()
> +      {
> +         throw new UnreachableStatementException();
> +      }
> +
> +      public ClassInfo getRawType()
> +      {
> +         throw new UnreachableStatementException();
> +      }
>     }
>  }
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -21,6 +21,8 @@
>  */
>  package org.jboss.reflect.plugins.introspection;
>  
> +import java.lang.reflect.Type;
> +
>  import org.jboss.reflect.spi.TypeInfo;
>  import org.jboss.reflect.spi.TypeInfoFactory;
>  
> @@ -46,4 +48,9 @@
>     {
>        return delegate.getTypeInfo(name, cl);
>     }
> +
> +   public TypeInfo getTypeInfo(Type type)
> +   {
> +      return delegate.getTypeInfo(type);
> +   }
>  }
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -26,6 +26,8 @@
>  import java.lang.reflect.Constructor;
>  import java.lang.reflect.Field;
>  import java.lang.reflect.Method;
> +import java.lang.reflect.ParameterizedType;
> +import java.lang.reflect.Type;
>  import java.security.AccessController;
>  import java.security.PrivilegedAction;
>  
> @@ -43,20 +45,20 @@
>  import org.jboss.reflect.plugins.MethodInfoImpl;
>  import org.jboss.reflect.spi.AnnotationInfo;
>  import org.jboss.reflect.spi.AnnotationValue;
> +import org.jboss.reflect.spi.ArrayInfo;
>  import org.jboss.reflect.spi.ClassInfo;
>  import org.jboss.reflect.spi.InterfaceInfo;
>  import org.jboss.reflect.spi.PrimitiveInfo;
>  import org.jboss.reflect.spi.TypeInfo;
>  import org.jboss.reflect.spi.TypeInfoFactory;
> -import org.jboss.util.collection.WeakClassCache;
> +import org.jboss.util.collection.temp.WeakTypeCache;
>  
>  /**
>   * An introspection type factory.
>   *
> - * FIXME: use lazy loading to avoid reading the entire class model
>   * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
>   */
> -public class IntrospectionTypeInfoFactoryImpl extends WeakClassCache implements TypeInfoFactory, AnnotationHelper, ClassInfoHelper
> +public class IntrospectionTypeInfoFactoryImpl extends WeakTypeCache<TypeInfo> implements TypeInfoFactory, AnnotationHelper, ClassInfoHelper
>  {
>     final static AnnotationValue[] NO_ANNOTATIONS = new AnnotationValue[0];
>  
> @@ -84,6 +86,19 @@
>        return superType;
>     }
>  
> +   public ClassInfo getGenericSuperClass(ClassInfoImpl classInfo)
> +   {
> +      Class clazz = classInfo.getType();
> +      ClassInfo superType = null;
> +      if (clazz.isInterface() == false)
> +      {
> +         Type superClazz = clazz.getGenericSuperclass();
> +         if (superClazz != null)
> +            superType = (ClassInfo) getTypeInfo(superClazz);
> +      }
> +      return superType;
> +   }
> +
>     public AnnotationValue[] getAnnotations(Object obj)
>     {
>        Annotation[] annotations;
> @@ -132,7 +147,7 @@
>              for (int i = 0; i < constructors.length; ++i)
>              {
>                 AnnotationValue[] annotations = getAnnotations(constructors[i]);
> -               infos[i] = new ReflectConstructorInfoImpl(annotations, getTypeInfos(constructors[i].getParameterTypes()), getParameterAnnotations(constructors[i].getParameterAnnotations()), getClassInfos(constructors[i].getExceptionTypes()), constructors[i].getModifiers(), (ClassInfo) getTypeInfo(constructors[i].getDeclaringClass()));
> +               infos[i] = new ReflectConstructorInfoImpl(annotations, getTypeInfos(constructors[i].getGenericParameterTypes()), getParameterAnnotations(constructors[i].getParameterAnnotations()), getClassInfos(constructors[i].getGenericExceptionTypes()), constructors[i].getModifiers(), (ClassInfo) getTypeInfo(constructors[i].getDeclaringClass()));
>                 infos[i].setConstructor(constructors[i]);
>              }
>           }
> @@ -151,7 +166,7 @@
>        for (int i = 0; i < fields.length; ++i)
>        {
>           AnnotationValue[] annotations = getAnnotations(fields[i]);
> -         infos[i] = new ReflectFieldInfoImpl(annotations, fields[i].getName(), getTypeInfo(fields[i].getType()), fields[i].getModifiers(), (ClassInfo) getTypeInfo(fields[i].getDeclaringClass()));
> +         infos[i] = new ReflectFieldInfoImpl(annotations, fields[i].getName(), getTypeInfo(fields[i].getGenericType()), fields[i].getModifiers(), (ClassInfo) getTypeInfo(fields[i].getDeclaringClass()));
>           infos[i].setField(fields[i]);
>        }
>        
> @@ -169,7 +184,7 @@
>        for (int i = 0; i < methods.length; ++i)
>        {
>           AnnotationValue[] annotations = getAnnotations(methods[i]);
> -         infos[i] = new ReflectMethodInfoImpl(annotations, methods[i].getName(), getTypeInfo(methods[i].getReturnType()), getTypeInfos(methods[i].getParameterTypes()), getParameterAnnotations(methods[i].getParameterAnnotations()), getClassInfos(methods[i].getExceptionTypes()), methods[i].getModifiers(), (ClassInfo) getTypeInfo(methods[i].getDeclaringClass()));
> +         infos[i] = new ReflectMethodInfoImpl(annotations, methods[i].getName(), getTypeInfo(methods[i].getGenericReturnType()), getTypeInfos(methods[i].getGenericParameterTypes()), getParameterAnnotations(methods[i].getParameterAnnotations()), getClassInfos(methods[i].getGenericExceptionTypes()), methods[i].getModifiers(), (ClassInfo) getTypeInfo(methods[i].getDeclaringClass()));
>           infos[i].setMethod(methods[i]);
>        }
>        return infos;
> @@ -189,13 +204,27 @@
>        return infos;
>     }
>  
> +   public InterfaceInfo[] getGenericInterfaces(ClassInfoImpl classInfo)
> +   {
> +      Class clazz = classInfo.getType();
> +      Type[] interfaces = clazz.getGenericInterfaces();
> +      if (interfaces == null || interfaces.length == 0)
> +         return null;
> +
> +      InterfaceInfo[] infos = new InterfaceInfo[interfaces.length];
> +      for (int i = 0; i < interfaces.length; ++i)
> +         infos[i] = (InterfaceInfo) getTypeInfo(interfaces[i]);
> +
> +      return infos;
> +   }
> +
>     /**
>      * Get the type infos for some classes
>      *
>      * @param classes the classes
>      * @return the type infos
>      */
> -   public TypeInfo[] getTypeInfos(Class[] classes)
> +   public TypeInfo[] getTypeInfos(Type[] classes)
>     {
>        if (classes == null || classes.length == 0)
>           return null;
> @@ -212,7 +241,7 @@
>      * @param classes the classes
>      * @return the class infos
>      */
> -   public ClassInfo[] getClassInfos(Class[] classes)
> +   public ClassInfo[] getClassInfos(Type[] classes)
>     {
>        if (classes == null || classes.length == 0)
>           return null;
> @@ -232,9 +261,27 @@
>        if (primitive != null)
>           return primitive;
>  
> -      return (TypeInfo) get(clazz);
> +      return get(clazz);
>     }
>  
> +   public TypeInfo getTypeInfo(Type type)
> +   {
> +      if (type == null)
> +         throw new IllegalArgumentException("Null type");
> +
> +      String name = null;
> +      if (type instanceof Class)
> +         name = ((Class) type).getName();
> +      if (name != null)
> +      {
> +         TypeInfo primitive = PrimitiveInfo.valueOf(((Class) type).getName());
> +         if (primitive != null)
> +            return primitive;
> +      }
> +
> +      return get(type);
> +   }
> +
>     public TypeInfo getTypeInfo(String name, ClassLoader cl) throws ClassNotFoundException
>     {
>        if (name == null)
> @@ -251,7 +298,7 @@
>        return getTypeInfo(clazz);
>     }
>  
> -   protected Object instantiate(Class clazz)
> +   protected TypeInfo instantiate(Class<?> clazz)
>     {
>        ClassInfoImpl result;
>        if (clazz.isArray())
> @@ -295,11 +342,25 @@
>        return result;
>     }
>  
> -   protected void generate(Class clazz, Object result)
> +   protected TypeInfo instantiate(ParameterizedType type)
>     {
> +      Class rawType = (Class) type.getRawType();
> +      ClassInfo rawTypeInfo = (ClassInfo) getTypeInfo(rawType);
> +      if (rawTypeInfo instanceof ArrayInfo)
> +         return new ParameterizedArrayInfo(this, (ArrayInfo) rawTypeInfo, type);
> +      return new ParameterizedClassInfo(this, rawTypeInfo, type);
> +   }
> +
> +   protected void generate(Class<?> clazz, TypeInfo result)
> +   {
>        generateTypeInfo(clazz, (ClassInfoImpl) result);
>     }
>  
> +   protected void generate(ParameterizedType type, TypeInfo result)
> +   {
> +      // Everything is lazy
> +   }
> +
>     protected Constructor[] getDeclaredConstructors(final Class clazz)
>     {
>        if (System.getSecurityManager() == null)
> @@ -402,4 +463,27 @@
>        return annotationValues;
>     }
>  
> +   public TypeInfo[] getActualTypeArguments(ParameterizedClassInfo classInfo)
> +   {
> +      ParameterizedType type = classInfo.parameterizedType;
> +      Type[] types = type.getActualTypeArguments();
> +      if (types == null)
> +         return null;
> +      
> +      TypeInfo[] result = new TypeInfo[types.length];
> +      for (int i = 0; i < types.length; ++i)
> +         result[i] = getTypeInfo(types[i]);
> +      
> +      return result;
> +   }
> +   
> +   public TypeInfo getOwnerType(ParameterizedClassInfo classInfo)
> +   {
> +      ParameterizedType type = classInfo.parameterizedType;
> +      Type owner = type.getOwnerType();
> +      if (owner == null)
> +         return null;
> +      
> +      return getTypeInfo(owner);
> +   }
>  }
>
> Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedArrayInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,57 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.reflect.plugins.introspection;
> +
> +import java.lang.reflect.ParameterizedType;
> +
> +import org.jboss.reflect.plugins.ClassInfoHelper;
> +import org.jboss.reflect.spi.ArrayInfo;
> +import org.jboss.reflect.spi.TypeInfo;
> +
> +/**
> + * ParameterizedArrayInfo.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ParameterizedArrayInfo extends ParameterizedClassInfo implements ArrayInfo
> +{
> +   /** The serialVersionUID */
> +   private static final long serialVersionUID = -2126867826240682161L;
> +
> +   /**
> +    * Create a new ParameterizedArrayInfo.
> +    * 
> +    * @param helper the helper
> +    * @param delegate the raw array info
> +    * @param parameterizedType the parameterized  type
> +    */
> +   public ParameterizedArrayInfo(ClassInfoHelper helper, ArrayInfo delegate, ParameterizedType parameterizedType)
> +   {
> +      super(helper, delegate, parameterizedType);
> +   }
> +
> +   public TypeInfo getComponentType()
> +   {
> +      return ((ArrayInfo) delegate).getComponentType();
> +   }
> +}
>
> Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,251 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.reflect.plugins.introspection;
> +
> +import java.lang.reflect.ParameterizedType;
> +
> +import org.jboss.reflect.plugins.ClassInfoHelper;
> +import org.jboss.reflect.plugins.ClassInfoImpl;
> +import org.jboss.reflect.spi.AnnotationValue;
> +import org.jboss.reflect.spi.ClassInfo;
> +import org.jboss.reflect.spi.ConstructorInfo;
> +import org.jboss.reflect.spi.FieldInfo;
> +import org.jboss.reflect.spi.InterfaceInfo;
> +import org.jboss.reflect.spi.MethodInfo;
> +import org.jboss.reflect.spi.TypeInfo;
> +import org.jboss.util.JBossObject;
> +import org.jboss.util.JBossStringBuilder;
> +
> +/**
> + * ParameterizedClassInfo.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ParameterizedClassInfo extends JBossObject implements ClassInfo, InterfaceInfo
> +{
> +   /** The serialVersionUID */
> +   private static final long serialVersionUID = -8739806147734002603L;
> +   
> +   /** The helper */
> +   protected ClassInfoHelper helper;
> +   
> +   /** The raw class info */
> +   protected ClassInfo delegate;
> +   
> +   /** The parameterized type */
> +   ParameterizedType parameterizedType;
> +   
> +   /** The owner type */
> +   private TypeInfo ownerType = ClassInfoImpl.UNKNOWN_TYPE;
> +   
> +   /** The type arguments */
> +   private TypeInfo[] typeArguments = ClassInfoImpl.UNKNOWN_TYPES;
> +   
> +   /**
> +    * Create a new ParameterizedClassInfo.
> +    *
> +    * @param helper the helper
> +    * @param delegate the raw array info
> +    * @param parameterizedType the parameterized  type
> +    */
> +   public ParameterizedClassInfo(ClassInfoHelper helper, ClassInfo delegate, ParameterizedType parameterizedType)
> +   {
> +      this.helper = helper;
> +      this.delegate = delegate;
> +      this.parameterizedType = parameterizedType;
> +   }
> +
> +   public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
> +   {
> +      return delegate.getDeclaredConstructor(parameters);
> +   }
> +
> +   public ConstructorInfo[] getDeclaredConstructors()
> +   {
> +      return delegate.getDeclaredConstructors();
> +   }
> +
> +   public FieldInfo getDeclaredField(String name)
> +   {
> +      return delegate.getDeclaredField(name);
> +   }
> +
> +   public FieldInfo[] getDeclaredFields()
> +   {
> +      return delegate.getDeclaredFields();
> +   }
> +
> +   public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
> +   {
> +      return delegate.getDeclaredMethod(name, parameters);
> +   }
> +
> +   public MethodInfo[] getDeclaredMethods()
> +   {
> +      return delegate.getDeclaredMethods();
> +   }
> +
> +   public InterfaceInfo[] getGenericInterfaces()
> +   {
> +      return delegate.getGenericInterfaces();
> +   }
> +
> +   public ClassInfo getGenericSuperclass()
> +   {
> +      return delegate.getGenericSuperclass();
> +   }
> +
> +   public InterfaceInfo[] getInterfaces()
> +   {
> +      return delegate.getInterfaces();
> +   }
> +
> +   public String getName()
> +   {
> +      return delegate.getName();
> +   }
> +
> +   public ClassInfo getSuperclass()
> +   {
> +      return delegate.getSuperclass();
> +   }
> +
> +   public boolean isInterface()
> +   {
> +      return delegate.isInterface();
> +   }
> +
> +   public AnnotationValue getAnnotation(String name)
> +   {
> +      return delegate.getAnnotation(name);
> +   }
> +
> +   public AnnotationValue[] getAnnotations()
> +   {
> +      return delegate.getAnnotations();
> +   }
> +
> +   public boolean isAnnotationPresent(String name)
> +   {
> +      return delegate.isAnnotationPresent(name);
> +   }
> +
> +   public int getModifiers()
> +   {
> +      return delegate.getModifiers();
> +   }
> +
> +   public boolean isPublic()
> +   {
> +      return delegate.isPublic();
> +   }
> +
> +   public boolean isStatic()
> +   {
> +      return delegate.isStatic();
> +   }
> +
> +   public Object convertValue(Object value) throws Throwable
> +   {
> +      return delegate.convertValue(value);
> +   }
> +
> +   public TypeInfo getArrayType(int depth)
> +   {
> +      return delegate.getArrayType(depth);
> +   }
> +   
> +   public Class getType()
> +   {
> +      return delegate.getType();
> +   }
> +
> +   public boolean isArray()
> +   {
> +      return delegate.isArray();
> +   }
> +
> +   public boolean isEnum()
> +   {
> +      return delegate.isEnum();
> +   }
> +
> +   public boolean isPrimitive()
> +   {
> +      return delegate.isPrimitive();
> +   }
> +
> +   public Object[] newArrayInstance(int size) throws Throwable
> +   {
> +      return delegate.newArrayInstance(size);
> +   }
> +
> +   public TypeInfo[] getActualTypeArguments()
> +   {
> +      if (typeArguments == ClassInfoImpl.UNKNOWN_TYPES)
> +         typeArguments = helper.getActualTypeArguments(this);
> +      return typeArguments;
> +   }
> +
> +   public TypeInfo getOwnerType()
> +   {
> +      if (ownerType == ClassInfoImpl.UNKNOWN_TYPE)
> +         ownerType = helper.getOwnerType(this);
> +      return ownerType;
> +   }
> +
> +   public ClassInfo getRawType()
> +   {
> +      return delegate;
> +   }
> +
> +   protected int getHashCode()
> +   {
> +      return delegate.hashCode();
> +   }
> +
> +   public boolean equals(Object obj)
> +   {
> +      if (obj == this)
> +         return true;
> +      
> +      if (obj == null || obj instanceof ClassInfo == false)
> +         return false;
> +      
> +      ClassInfo other = (ClassInfo) obj;
> +      if (other instanceof ParameterizedClassInfo)
> +         other = ((ParameterizedClassInfo) other).delegate;
> +      
> +      return delegate.equals(other);
> +   }
> +
> +   public void toShortString(JBossStringBuilder buffer)
> +   {
> +      buffer.append(parameterizedType);
> +   }
> +
> +   protected void toString(JBossStringBuilder buffer)
> +   {
> +      buffer.append(parameterizedType);
> +   }
> +}
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistArrayInfoImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -23,7 +23,6 @@
>  
>  import javassist.CtClass;
>  
> -import org.jboss.reflect.spi.AnnotatedInfo;
>  import org.jboss.reflect.spi.AnnotationValue;
>  import org.jboss.reflect.spi.ArrayInfo;
>  import org.jboss.reflect.spi.TypeInfo;
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -156,6 +156,12 @@
>        }
>     }
>  
> +   public ClassInfo getGenericSuperclass()
> +   {
> +      // TODO getGenericSuperclass
> +      throw new org.jboss.util.NotImplementedException("getGenericSuperclass");
> +   }
> +
>     public InterfaceInfo[] getInterfaces()
>     {
>        try
> @@ -174,6 +180,12 @@
>        }
>     }
>  
> +   public InterfaceInfo[] getGenericInterfaces()
> +   {
> +      // TODO getGenericInterfaces
> +      throw new org.jboss.util.NotImplementedException("getGenericInterfaces");
> +   }
> +
>     public ConstructorInfo[] getDeclaredConstructors()
>     {
>        if (constructorArray == null)
> @@ -542,4 +554,19 @@
>        }
>     }
>  
> +   public TypeInfo[] getActualTypeArguments()
> +   {
> +      return null;
> +   }
> +
> +   public TypeInfo getOwnerType()
> +   {
> +      return null;
> +   }
> +
> +   public ClassInfo getRawType()
> +   {
> +      return this;
> +   }
> +
>  }
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -21,6 +21,8 @@
>  */
>  package org.jboss.reflect.plugins.javassist;
>  
> +import java.lang.reflect.Type;
> +
>  import org.jboss.reflect.spi.TypeInfo;
>  import org.jboss.reflect.spi.TypeInfoFactory;
>  
> @@ -46,4 +48,10 @@
>     {
>        return delegate.getTypeInfo(name, cl);
>     }
> +   
> +   public TypeInfo getTypeInfo(Type type)
> +   {
> +      return delegate.getTypeInfo(type);
> +   }
> +
>  }
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -22,6 +22,7 @@
>  package org.jboss.reflect.plugins.javassist;
>  
>  import java.lang.annotation.Annotation;
> +import java.lang.reflect.Type;
>  
>  import javassist.ClassPool;
>  import javassist.CtClass;
> @@ -273,6 +274,15 @@
>        return getTypeInfo(clazz);
>     }
>     
> +   public TypeInfo getTypeInfo(Type type)
> +   {
> +      if (type instanceof Class)
> +         return getTypeInfo((Class) type);
> +
> +      // TODO getTypeInfo
> +      throw new org.jboss.util.NotImplementedException("getTypeInfo");
> +   }
> +
>     public AnnotationValue[] getAnnotations(Object obj)
>     {
>        try
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/ClassInfo.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -51,6 +51,13 @@
>     InterfaceInfo[] getInterfaces();
>     
>     /**
> +    * Get the generic interfaces
> +    *
> +    * @return the generic interfaces
> +    */
> +   InterfaceInfo[] getGenericInterfaces();
> +   
> +   /**
>      * Get the declared method
>      * 
>      * @param name the method name
> @@ -102,4 +109,32 @@
>      * @return the super class
>      */
>     ClassInfo getSuperclass();
> +
> +   /**
> +    * Get the generic super class
> +    * 
> +    * @return the super class
> +    */
> +   ClassInfo getGenericSuperclass();
> +   
> +   /**
> +    * Get the actual type parameters
> +    * 
> +    * @return the type parameters
> +    */
> +   TypeInfo[] getActualTypeArguments();
> +   
> +   /**
> +    * Get the raw type
> +    * 
> +    * @return the raw type
> +    */
> +   ClassInfo getRawType();
> +   
> +   /**
> +    * Get the owner type
> +    * 
> +    * @return the owner type
> +    */
> +   TypeInfo getOwnerType();
>  }
>
> Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/TypeInfoFactory.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -21,6 +21,8 @@
>  */
>  package org.jboss.reflect.spi;
>  
> +import java.lang.reflect.Type;
> +
>  /**
>   * A type info factory.
>   *
> @@ -45,4 +47,12 @@
>      * @return the type info
>      */
>     TypeInfo getTypeInfo(Class clazz);
> +
> +   /**
> +    * Get a type info
> +    * 
> +    * @param type the type
> +    * @return the type info
> +    */
> +   TypeInfo getTypeInfo(Type type);
>  }
>
> Added: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/FIXME	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1 @@
> +THESE CLASSES NEED TO BE MOVED TO COMMON WHEN IT SUPPORTS JDK5 + JBOSS RETRO
> \ No newline at end of file
>
> Added: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,283 @@
> +/*
> + * JBoss, Home of Professional Open Source
> + * Copyright 2006, JBoss Inc., and individual contributors as indicated
> + * by the @authors tag. See the copyright.txt 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.util.collection.temp;
> +
> +import java.lang.reflect.GenericArrayType;
> +import java.lang.reflect.ParameterizedType;
> +import java.lang.reflect.Type;
> +import java.lang.reflect.TypeVariable;
> +import java.util.Map;
> +import java.util.WeakHashMap;
> +
> +/**
> + * A weak class cache that instantiates does not a hold a
> + * strong reference to either the classloader or class.<p>
> + * 
> + * It creates the class specific data in two stages
> + * to avoid recursion.<p>
> + * 
> + * instantiate - creates the data<br>
> + * generate - fills in the details
> + *
> + * @param <T> the cached type
> + * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
> + */
> +public abstract class WeakTypeCache<T>
> +{
> +   /** The cache */
> +   private Map<ClassLoader, Map<String, T>> cache = new WeakHashMap<ClassLoader, Map<String, T>>(); 
> +   
> +   /**
> +    * Get the information for a type
> +    * 
> +    * @param type the type
> +    * @return the info
> +    */
> +   public T get(Type type)
> +   {
> +      if (type == null)
> +         throw new IllegalArgumentException("Null type");
> +
> +      if (type instanceof ParameterizedType)
> +         return getParameterizedType((ParameterizedType) type);
> +      else if (type instanceof Class)
> +         return getClass((Class<?>) type);
> +      else if (type instanceof TypeVariable)
> +         return getTypeVariable((TypeVariable) type);
> +      else if (type instanceof GenericArrayType)
> +         return getGenericArrayType((GenericArrayType) type);
> +      else
> +         throw new UnsupportedOperationException("Unknown type: " + type + " class=" + type.getClass());
> +   }
> +   
> +   /**
> +    * Get the information for a class
> +    * 
> +    * @param name the name
> +    * @param cl the classloader
> +    * @return the info
> +    * @throws ClassNotFoundException when the class cannot be found
> +    */
> +   public T get(String name, ClassLoader cl) throws ClassNotFoundException
> +   {
> +      if (name == null)
> +         throw new IllegalArgumentException("Null name");
> +      if (cl == null)
> +         throw new IllegalArgumentException("Null classloader");
> +
> +      Class<?> clazz = cl.loadClass(name);
> +      return get(clazz);
> +   }
> +   
> +   /**
> +    * Instantiate for a class
> +    * 
> +    * @param clazz the class
> +    * @return the result
> +    */
> +   protected abstract T instantiate(Class<?> clazz);
> +   
> +   /**
> +    * Fill in the result
> +    * 
> +    * @param clazz the class
> +    * @param result the result
> +    */
> +   protected abstract void generate(Class<?> clazz, T result);
> +   
> +   /**
> +    * Instantiate for a parameterized type
> +    * 
> +    * @param type the parameterized type
> +    * @return the result
> +    */
> +   protected abstract T instantiate(ParameterizedType type);
> +   
> +   /**
> +    * Fill in the result
> +    * 
> +    * @param type the parameterized type
> +    * @param result the result
> +    */
> +   protected abstract void generate(ParameterizedType type, T result);
> +
> +   /**
> +    * Get the information for a parameterized type
> +    * 
> +    * @param type the paremeterized type
> +    * @return the info
> +    */
> +   private T getParameterizedType(ParameterizedType type)
> +   {
> +      // First check if we already have it
> +      T result = peek(type);
> +      if (result != null)
> +         return result;
> +      
> +      // Instantiate
> +      result = instantiate(type);
> +
> +      // Put the perlimanary result into the cache
> +      put(type, result);
> +
> +      // Generate the details
> +      generate(type, result);
> +      
> +      return result;
> +   }
> +
> +   /**
> +    * Get the information for a type variable
> +    * 
> +    * @param type the type variable
> +    * @return the info
> +    */
> +   private T getTypeVariable(TypeVariable type)
> +   {
> +      // TODO improve this
> +      return get(type.getBounds()[0]);
> +   }
> +
> +   /**
> +    * Get the information for an array type
> +    * 
> +    * @param type the array type
> +    * @return the info
> +    */
> +   private T getGenericArrayType(GenericArrayType type)
> +   {
> +      // TODO this needs implementing properly
> +      return get(Object[].class);
> +   }
> +
> +   /**
> +    * Peek into the cache
> +    * 
> +    * @param type the type
> +    * @return the value
> +    */
> +   private T peek(ParameterizedType type)
> +   {
> +      Class<?> rawType = (Class<?>) type.getRawType();
> +      Map<String, T> classLoaderCache = getClassLoaderCache(rawType.getClassLoader());
> +      
> +      synchronized (classLoaderCache)
> +      {
> +         return classLoaderCache.get(type.toString());
> +      }
> +   }
> +
> +   /**
> +    * Put a result into the cache
> +    * 
> +    * @param clazz the class
> +    * @param result the value
> +    */
> +   private void put(ParameterizedType type, T result)
> +   {
> +      Class<?> rawType = (Class<?>) type.getRawType();
> +      Map<String, T> classLoaderCache = getClassLoaderCache(rawType.getClassLoader());
> +
> +      synchronized (classLoaderCache)
> +      {
> +         // TODO something better than toString()?
> +         classLoaderCache.put(type.toString(), result);
> +      }
> +   }
> +
> +   /**
> +    * Get the information for a class
> +    * 
> +    * @param clazz the class
> +    * @return the info
> +    */
> +   private T getClass(Class<?> clazz)
> +   {
> +      // First check if we already have it
> +      T result = peek(clazz);
> +      if (result != null)
> +         return result;
> +
> +      // Instantiate
> +      result = instantiate(clazz);
> +
> +      // Put the perlimanary result into the cache
> +      put(clazz, result);
> +
> +      // Generate the details
> +      generate(clazz, result);
> +      
> +      return result;
> +   }
> +
> +   /**
> +    * Peek into the cache
> +    * 
> +    * @param clazz the class
> +    * @return the value
> +    */
> +   private T peek(Class<?> clazz)
> +   {
> +      Map<String, T> classLoaderCache = getClassLoaderCache(clazz.getClassLoader());
> +
> +      synchronized (classLoaderCache)
> +      {
> +         return classLoaderCache.get(clazz.getName());
> +      }
> +   }
> +
> +   /**
> +    * Put a result into the cache
> +    * 
> +    * @param clazz the class
> +    * @param result the value
> +    */
> +   private void put(Class<?> clazz, T result)
> +   {
> +      Map<String, T> classLoaderCache = getClassLoaderCache(clazz.getClassLoader());
> +
> +      synchronized (classLoaderCache)
> +      {
> +         classLoaderCache.put(clazz.getName(), result);
> +      }
> +   }
> +   
> +   /**
> +    * Get the cache for the classloader
> +    * 
> +    * @param cl the classloader
> +    * @return the map
> +    */
> +   private Map<String, T> getClassLoaderCache(ClassLoader cl)
> +   {
> +      synchronized (cache)
> +      {
> +         Map<String, T> result = cache.get(cl);
> +         if (result == null)
> +         {
> +            result = new WeakValueHashMap<String, T>();
> +            cache.put(cl, result);
> +         }
> +         return result;
> +      }
> +   }
> +}
>
> Added: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakValueHashMap.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,293 @@
> +/*
> +  * JBoss, Home of Professional Open Source
> +  * Copyright 2005, JBoss Inc., and individual contributors as indicated
> +  * by the @authors tag. See the copyright.txt 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.util.collection.temp;
> +
> +import java.lang.ref.ReferenceQueue;
> +import java.lang.ref.WeakReference;
> +import java.util.AbstractMap;
> +import java.util.AbstractSet;
> +import java.util.HashMap;
> +import java.util.Iterator;
> +import java.util.Map;
> +import java.util.Set;
> +
> +
> +/**
> + * This Map will remove entries when the value in the map has been
> + * cleaned from garbage collection
> + *
> + * @param <K> the key type
> + * @param <V> the value type
> + * @author  <a href="mailto:bill at jboss.org">Bill Burke</a>
> + * @author  <a href="mailto:adrian at jboss.org">Adrian Brock</a>
> + * @version <tt>$Revision: 1958 $</tt>
> + */
> +public class WeakValueHashMap<K, V> extends AbstractMap<K, V> 
> +{
> +   /** Hash table mapping keys to weak values */
> +   private Map<K, WeakValueRef<K, V>> hash;
> +
> +   /** Reference queue for cleared WeakKeys */
> +   private ReferenceQueue<V> queue = new ReferenceQueue<V>();
> +
> +   /**
> +    * Constructs a new, empty <code>WeakHashMap</code> with the given
> +    * initial capacity and the given load factor.
> +    *
> +    * @param  initialCapacity  The initial capacity of the
> +    *                          <code>WeakHashMap</code>
> +    *
> +    * @param  loadFactor       The load factor of the <code>WeakHashMap</code>
> +    *
> +    * @throws IllegalArgumentException  If the initial capacity is less than
> +    *                                   zero, or if the load factor is
> +    *                                   nonpositive
> +    */
> +   public WeakValueHashMap(int initialCapacity, float loadFactor)
> +   {
> +      hash = new HashMap<K, WeakValueRef<K, V>>(initialCapacity, loadFactor);
> +   }
> +
> +   /**
> +    * Constructs a new, empty <code>WeakHashMap</code> with the given
> +    * initial capacity and the default load factor, which is
> +    * <code>0.75</code>.
> +    *
> +    * @param  initialCapacity  The initial capacity of the
> +    *                          <code>WeakHashMap</code>
> +    *
> +    * @throws IllegalArgumentException  If the initial capacity is less than
> +    *                                   zero
> +    */
> +   public WeakValueHashMap(int initialCapacity)
> +   {
> +      hash = new HashMap<K, WeakValueRef<K, V>>(initialCapacity);
> +   }
> +
> +   /**
> +    * Constructs a new, empty <code>WeakHashMap</code> with the default
> +    * initial capacity and the default load factor, which is
> +    * <code>0.75</code>.
> +    */
> +   public WeakValueHashMap()
> +   {
> +      hash = new HashMap<K, WeakValueRef<K, V>>();
> +   }
> +
> +   /**
> +    * Constructs a new <code>WeakHashMap</code> with the same mappings as the
> +    * specified <tt>Map</tt>.  The <code>WeakHashMap</code> is created with an
> +    * initial capacity of twice the number of mappings in the specified map
> +    * or 11 (whichever is greater), and a default load factor, which is
> +    * <tt>0.75</tt>.
> +    *
> +    * @param   t the map whose mappings are to be placed in this map.
> +    * @since    1.3
> +    */
> +   public WeakValueHashMap(Map<K, V> t)
> +   {
> +      this(Math.max(2*t.size(), 11), 0.75f);
> +      putAll(t);
> +   }
> +
> +   @Override
> +   public int size()
> +   {
> +      processQueue();
> +      return hash.size();
> +   }
> +
> +   @Override
> +   public boolean containsKey(Object key)
> +   {
> +      processQueue();
> +      return hash.containsKey(key);
> +   }
> +
> +   @Override
> +   public V get(Object key)
> +   {
> +      processQueue();
> +      WeakValueRef<K, V> ref = hash.get(key);
> +      if (ref != null)
> +         return ref.get();
> +      return null;
> +   }
> +
> +   @Override
> +   public V put(K key, V value) 
> +   {
> +      processQueue();
> +      WeakValueRef<K, V> ref = WeakValueRef.create(key, value, queue);
> +      WeakValueRef<K, V> result = hash.put(key, ref);
> +      if (result != null)
> +         return result.get();
> +      return null;
> +   }
> +
> +   @Override
> +   public V remove(Object key) 
> +   {
> +      processQueue();
> +      WeakValueRef<K, V> result = hash.remove(key);
> +      if (result != null)
> +         return result.get();
> +      return null;
> +   }
> +   
> +   @Override
> +   public Set<Entry<K,V>> entrySet() 
> +   { 
> +      processQueue();
> +      return new EntrySet();
> +   }
> +
> +   @Override
> +   public void clear()
> +   {
> +      processQueue();
> +      hash.clear();
> +   }
> +   
> +   /**
> +    * Remove all entries whose values have been discarded.  
> +    */
> +   @SuppressWarnings("unchecked")
> +   private void processQueue()
> +   {
> +      WeakValueRef<K, V> ref = (WeakValueRef<K, V>) queue.poll();
> +      while (ref != null)
> +      {
> +         // only remove if it is the *exact* same WeakValueRef
> +         if (ref == hash.get(ref.key))
> +            hash.remove(ref.key);
> +         
> +         ref = (WeakValueRef<K, V>) queue.poll();
> +      }
> +   }
> +   
> +   /**
> +    * EntrySet.
> +    */
> +   private class EntrySet extends AbstractSet<Entry<K, V>>
> +   {
> +      @Override
> +      public Iterator<Entry<K, V>> iterator()
> +      {
> +         return new EntrySetIterator(hash.entrySet().iterator());
> +      }
> +
> +      @Override
> +      public int size()
> +      {
> +         return WeakValueHashMap.this.size();
> +      }
> +   }
> +   
> +   /**
> +    * EntrySet iterator
> +    */
> +   private class EntrySetIterator implements Iterator<Entry<K, V>>
> +   {
> +      /** The delegate */
> +      private Iterator<Entry<K, WeakValueRef<K, V>>> delegate;
> +      
> +      /**
> +       * Create a new EntrySetIterator.
> +       * 
> +       * @param delegate the delegate
> +       */
> +      public EntrySetIterator(Iterator<Entry<K, WeakValueRef<K, V>>> delegate)
> +      {
> +         this.delegate = delegate;
> +      }
> +
> +      public boolean hasNext()
> +      {
> +         return delegate.hasNext();
> +      }
> +
> +      public Entry<K, V> next()
> +      {
> +         Entry<K, WeakValueRef<K, V>> next = delegate.next();
> +         return next.getValue();
> +      }
> +
> +      public void remove()
> +      {
> +         throw new UnsupportedOperationException("remove");
> +      }
> +   }
> +   
> +   /**
> +    * WeakValueRef.
> +    */
> +   private static class WeakValueRef<K, V> extends WeakReference<V> implements Map.Entry<K, V>
> +   {
> +      /** The key */
> +      public K key;
> +
> +      /**
> +       * Safely create a new WeakValueRef
> +       * 
> +       * @param key the key
> +       * @param val the value
> +       * @param q the reference queue
> +       * @return the reference or null if the value is null
> +       */
> +      private static <K, V> WeakValueRef<K, V> create(K key, V val, ReferenceQueue<V> q)
> +      {
> +         if (val == null)
> +            return null;
> +         else 
> +            return new WeakValueRef<K, V>(key, val, q);
> +      }
> +
> +      /**
> +       * Create a new WeakValueRef.
> +       * 
> +       * @param key the key
> +       * @param val the value
> +       * @param q the reference queue
> +       */
> +      private WeakValueRef(K key, V val, ReferenceQueue<V> q)
> +      {
> +         super(val, q);
> +         this.key = key;
> +      }
> +
> +      public K getKey()
> +      {
> +         return key;
> +      }
> +
> +      public V getValue()
> +      {
> +         return get();
> +      }
> +
> +      public V setValue(V value)
> +      {
> +         throw new UnsupportedOperationException("setValue");
> +      }
> +   }
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericClass.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,33 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericClass
> + * 
> + * @param <T> the generic type
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericClass<T>
> +{
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericConstructorsClass.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,34 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericConstructors
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericConstructorsClass
> +{
> +   ClassInfoGenericConstructorsClass(ClassInfoGenericClass<String> p1) {};
> +   ClassInfoGenericConstructorsClass(ClassInfoGenericClass<String> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {};
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsClass.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,34 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericField
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericFieldsClass
> +{
> +   ClassInfoGenericClass<String> fieldString;
> +   ClassInfoGenericClass<ClassInfoEmptyClass> fieldClass;
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericFieldsInterface.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,34 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericFieldsInterface
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public interface ClassInfoGenericFieldsInterface
> +{
> +   ClassInfoGenericClass<String> fieldString = null;
> +   ClassInfoGenericClass<ClassInfoEmptyClass> fieldClass = null;
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericInterface.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,33 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericInterface
> + * 
> + * @param <T> the generic type
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public interface ClassInfoGenericInterface<T>
> +{
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsClass.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,38 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericMethods
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericMethodsClass
> +{
> +   void doSomething(ClassInfoGenericClass<String> p1) {};
> +   void doSomething(ClassInfoGenericClass<String> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {};
> +   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1) {return null;};
> +   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {return null;};
> +   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1) {return null;};
> +   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2) {return null;};
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericMethodsInterface.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,38 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericMethods
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public interface ClassInfoGenericMethodsInterface
> +{
> +   void doSomething(ClassInfoGenericClass<String> p1);
> +   void doSomething(ClassInfoGenericClass<String> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2);
> +   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1);
> +   ClassInfoGenericClass<String> doSomething2(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2);
> +   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1);
> +   ClassInfoGenericClass<ClassInfoEmptyClass> doSomething3(ClassInfoGenericClass<Integer> p1, ClassInfoGenericClass<ClassInfoEmptyClass> p2);
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassEmptyClass.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,32 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoSuperClass
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericSuperClassEmptyClass extends ClassInfoGenericClass<ClassInfoEmptyClass>
> +{
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperClassString.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,32 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoSuperClass
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericSuperClassString extends ClassInfoGenericClass<String>
> +{
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceEmptyClass.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,32 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericSuperInterfaceEmptyClass.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericSuperInterfaceEmptyClass implements ClassInfoGenericInterface<ClassInfoEmptyClass>
> +{
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/ClassInfoGenericSuperInterfaceString.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,32 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.support;
> +
> +/**
> + * ClassInfoGenericSuperInterfaceString.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class ClassInfoGenericSuperInterfaceString implements ClassInfoGenericInterface<String>
> +{
> +}
>
> Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -26,6 +26,7 @@
>  import java.lang.reflect.Constructor;
>  import java.lang.reflect.Field;
>  import java.lang.reflect.Method;
> +import java.lang.reflect.Type;
>  import java.util.Arrays;
>  import java.util.HashMap;
>  import java.util.HashSet;
> @@ -187,7 +188,7 @@
>        Set<FieldInfo> expected = new HashSet<FieldInfo>();
>        for (Field field : clazz.getDeclaredFields())
>        {
> -         TypeInfo type = factory.getTypeInfo(field.getType());
> +         TypeInfo type = factory.getTypeInfo(field.getGenericType());
>           FieldInfo f = new FieldInfoImpl(null, field.getName(), type, field.getModifiers(), classInfo);
>           expected.add(f);
>        }
> @@ -218,8 +219,8 @@
>        
>        FieldInfo fieldInfo = classInfo.getDeclaredField(field.getName());
>        assertNotNull(field.getName(), fieldInfo);
> -      TypeInfo type = factory.getTypeInfo(field.getType());
> -      assertEquals(type, fieldInfo.getType());
> +      TypeInfo type = factory.getTypeInfo(field.getGenericType());
> +      assertTypeEquals(field.getName(), type, fieldInfo.getType());
>        assertEquals(classInfo, fieldInfo.getDeclaringClass());
>        assertEquals(field.getModifiers(), fieldInfo.getModifiers());
>        assertFieldAnnotations(field, fieldInfo);
> @@ -266,24 +267,24 @@
>  
>        TypeInfoFactory factory = getTypeInfoFactory();
>        
> -      Class[] paramClasses = method.getParameterTypes();
> +      Type[] paramClasses = method.getGenericParameterTypes();
>        TypeInfo[] paramTypes = new TypeInfo[paramClasses.length];
>        for (int i = 0; i < paramClasses.length; ++i)
>           paramTypes[i] = factory.getTypeInfo(paramClasses[i]);
>        MethodInfo methodInfo = classInfo.getDeclaredMethod(method.getName(), paramTypes);
>        assertNotNull(method.getName(), methodInfo);
> -      TypeInfo returnType = factory.getTypeInfo(method.getReturnType());
> +      TypeInfo returnType = factory.getTypeInfo(method.getGenericReturnType());
>        TypeInfo[] actualParamTypes = methodInfo.getParameterTypes();
>        for (int i = 0; i < paramTypes.length; ++i)
> -         assertEquals(paramTypes[i], actualParamTypes[i]);
> +         assertTypeEquals(method.getName() + " param" + i, paramTypes[i], actualParamTypes[i]);
>        Class[] exceptionClasses = method.getExceptionTypes();
>        TypeInfo[] expectedExceptionTypes = new TypeInfo[exceptionClasses.length];
>        for (int i = 0; i < exceptionClasses.length; ++i)
>           expectedExceptionTypes[i] = factory.getTypeInfo(exceptionClasses[i]);
>        TypeInfo[] actualExceptionTypes = methodInfo.getExceptionTypes();
>        for (int i = 0; i < exceptionClasses.length; ++i)
> -         assertEquals(expectedExceptionTypes[i], actualExceptionTypes[i]);
> -      assertEquals(returnType, methodInfo.getReturnType());
> +         assertTypeEquals(method.getName() + " exception" + i, expectedExceptionTypes[i], actualExceptionTypes[i]);
> +      assertTypeEquals(method.getName() + " returnType", returnType, methodInfo.getReturnType());
>        assertEquals(classInfo, methodInfo.getDeclaringClass());
>        assertEquals(method.getModifiers(), methodInfo.getModifiers());
>        assertMethodAnnotations(method, methodInfo);
> @@ -330,7 +331,7 @@
>  
>        TypeInfoFactory factory = getTypeInfoFactory();
>        
> -      Class[] paramClasses = constructor.getParameterTypes();
> +      Type[] paramClasses = constructor.getGenericParameterTypes();
>        TypeInfo[] paramTypes = new TypeInfo[paramClasses.length];
>        for (int i = 0; i < paramClasses.length; ++i)
>           paramTypes[i] = factory.getTypeInfo(paramClasses[i]);
> @@ -338,14 +339,14 @@
>        assertNotNull(constructorInfo);
>        TypeInfo[] actualParamTypes = constructorInfo.getParameterTypes();
>        for (int i = 0; i < paramTypes.length; ++i)
> -         assertEquals(paramTypes[i], actualParamTypes[i]);
> +         assertTypeEquals(clazz + " constructorParameter" + i, paramTypes[i], actualParamTypes[i]);
>        Class[] exceptionClasses = constructor.getExceptionTypes();
>        TypeInfo[] expectedExceptionTypes = new TypeInfo[exceptionClasses.length];
>        for (int i = 0; i < exceptionClasses.length; ++i)
>           expectedExceptionTypes[i] = factory.getTypeInfo(exceptionClasses[i]);
>        TypeInfo[] actualExceptionTypes = constructorInfo.getExceptionTypes();
>        for (int i = 0; i < exceptionClasses.length; ++i)
> -         assertEquals(expectedExceptionTypes[i], actualExceptionTypes[i]);
> +         assertTypeEquals(clazz + " constructorException" + i, expectedExceptionTypes[i], actualExceptionTypes[i]);
>        assertEquals(classInfo, constructorInfo.getDeclaringClass());
>        assertEquals(constructor.getModifiers(), constructorInfo.getModifiers());
>        assertConstructorAnnotations(constructor, constructorInfo);
> @@ -476,6 +477,30 @@
>        }
>        return expected;
>     }
> +
> +   protected void assertTypeEquals(String context, TypeInfo expected, TypeInfo actual) throws Exception
> +   {
> +      assertEquals(expected, actual);
> +      if (expected instanceof ClassInfo)
> +      {
> +         ClassInfo expectedClassInfo = (ClassInfo) expected;
> +         ClassInfo actualClassInfo = (ClassInfo) actual;
> +         assertEquals(context, expectedClassInfo.getOwnerType(), actualClassInfo.getOwnerType());
> +         assertEquals(context, expectedClassInfo.getRawType(), actualClassInfo.getRawType());
> +         TypeInfo[] expectedTypeArgs = expectedClassInfo.getActualTypeArguments();
> +         TypeInfo[] actualTypeArgs = expectedClassInfo.getActualTypeArguments();
> +         if (expectedTypeArgs == null)
> +            assertNull(context, actualTypeArgs);
> +         else
> +         {
> +            assertNotNull(context, actualTypeArgs);
> +            getLog().debug("Checking type args for " + context + " expected: " + Arrays.asList(expectedTypeArgs) + " actual: " + Arrays.asList(actualTypeArgs));
> +            assertEquals(expectedTypeArgs.length, actualTypeArgs.length);
> +            for (int i = 0; i < expectedTypeArgs.length; ++i)
> +               assertTypeEquals(context + "arg" + i, expectedTypeArgs[i], actualTypeArgs[i]);
> +         }
> +      }
> +   }
>     
>     protected abstract TypeInfoFactory getTypeInfoFactory();
>     
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericClassTest.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,145 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
> +
> +import java.lang.reflect.Modifier;
> +import java.util.Arrays;
> +
> +import org.jboss.reflect.plugins.ClassInfoImpl;
> +import org.jboss.reflect.spi.ClassInfo;
> +import org.jboss.reflect.spi.InterfaceInfo;
> +import org.jboss.reflect.spi.TypeInfo;
> +import org.jboss.reflect.spi.TypeInfoFactory;
> +import org.jboss.test.classinfo.support.ClassInfoEmptyClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericConstructorsClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericFieldsClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericInterface;
> +import org.jboss.test.classinfo.support.ClassInfoGenericMethodsClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericSuperClassEmptyClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericSuperClassString;
> +import org.jboss.test.classinfo.support.ClassInfoGenericSuperInterfaceEmptyClass;
> +import org.jboss.test.classinfo.support.ClassInfoGenericSuperInterfaceString;
> +
> +
> +/**
> + * ClassInfoGenericClassTest.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public abstract class ClassInfoGenericClassTest extends AbstractClassInfoTest
> +{
> +   public ClassInfoGenericClassTest(String name)
> +   {
> +      super(name);
> +   }
> +   
> +   public void testGenericSuperClassString()
> +   {
> +      testGenericSuperClass(ClassInfoGenericSuperClassString.class, ClassInfoGenericClass.class, new Class[] { String.class });
> +   }
> +   
> +   public void testGenericSuperClassEmptyClass()
> +   {
> +      testGenericSuperClass(ClassInfoGenericSuperClassEmptyClass.class, ClassInfoGenericClass.class, new Class[] { ClassInfoEmptyClass.class });
> +   }
> +   
> +   public void testGenericSuperInterfaceString()
> +   {
> +      testGenericSuperInterface(ClassInfoGenericSuperInterfaceString.class, ClassInfoGenericInterface.class, new Class[] { String.class });
> +   }
> +   
> +   public void testGenericSuperInterfaceEmptyClass()
> +   {
> +      testGenericSuperInterface(ClassInfoGenericSuperInterfaceEmptyClass.class, ClassInfoGenericInterface.class, new Class[] { ClassInfoEmptyClass.class });
> +   }
> +   
> +   public void testGenericSuperClass(Class clazz, Class genericClass, Class[] genericTypes)
> +   {
> +      TypeInfoFactory factory = getTypeInfoFactory();
> +      ClassInfo typeInfo = (ClassInfo) factory.getTypeInfo(clazz);
> +      ClassInfo superClassInfo = typeInfo.getGenericSuperclass();
> +      ClassInfo genericClassInfo = (ClassInfo) factory.getTypeInfo(genericClass);
> +      getLog().debug("Checking superClass: " + genericClass + " against " + superClassInfo);
> +      assertEquals(genericClassInfo, superClassInfo);
> +
> +      TypeInfo[] types = new TypeInfo[genericTypes.length];
> +      for (int i = 0; i < types.length; ++i)
> +         types[i] = factory.getTypeInfo(genericTypes[i]);
> +      TypeInfo[] actualTypes = superClassInfo.getActualTypeArguments();
> +      getLog().debug("Checking superClass types: " + Arrays.asList(genericTypes) + " against " + Arrays.asList(actualTypes));
> +      assertEquals(types.length, actualTypes.length);
> +      for (int i = 0; i < types.length; ++i)
> +         assertEquals(types[i], actualTypes[i]);
> +   }
> +   
> +   public void testGenericSuperInterface(Class clazz, Class genericClass, Class[] genericTypes)
> +   {
> +      TypeInfoFactory factory = getTypeInfoFactory();
> +      ClassInfo typeInfo = (ClassInfo) factory.getTypeInfo(clazz);
> +      InterfaceInfo[] superInterfaces = typeInfo.getGenericInterfaces();
> +      assertNotNull(superInterfaces);
> +      assertEquals(1, superInterfaces.length);
> +      InterfaceInfo superInterface = superInterfaces[0]; 
> +      getLog().debug("Checking superInterface: " + genericClass + " against " + superInterface);
> +      ClassInfo genericClassInfo = (ClassInfo) factory.getTypeInfo(genericClass);
> +      assertEquals(genericClassInfo, superInterface);
> +
> +      TypeInfo[] types = new TypeInfo[genericTypes.length];
> +      for (int i = 0; i < types.length; ++i)
> +         types[i] = factory.getTypeInfo(genericTypes[i]);
> +      TypeInfo[] actualTypes = superInterface.getActualTypeArguments();
> +      getLog().debug("Checking superInterface types: " + Arrays.asList(genericTypes) + " against " + Arrays.asList(actualTypes));
> +      assertEquals(types.length, actualTypes.length);
> +      for (int i = 0; i < types.length; ++i)
> +         assertEquals(types[i], actualTypes[i]);
> +   }
> +
> +   public void testGenericMethodsClass() throws Throwable
> +   {
> +      testGenericClass(ClassInfoGenericMethodsClass.class);
> +   }
> +
> +   public void testGenericConstructorsClass() throws Throwable
> +   {
> +      testGenericClass(ClassInfoGenericConstructorsClass.class);
> +   }
> +   
> +   public void testGenericFieldsClass() throws Throwable
> +   {
> +      testGenericClass(ClassInfoGenericFieldsClass.class);
> +   }
> +   
> +   private void testGenericClass(Class clazz) throws Throwable
> +   {
> +      ClassInfoImpl expected = new ClassInfoImpl(clazz.getName(), Modifier.PUBLIC);
> +      TypeInfo info = testBasics(clazz, expected);
> +      
> +      assertFalse(info.isArray());
> +      assertFalse(info.isEnum());
> +      assertFalse(info.isPrimitive());
> +      
> +      ClassInfo classInfo = (ClassInfo) info;
> +      assertClassInfo(classInfo, clazz);
> +   }
> +}
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoGenericInterfaceTest.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,67 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
> +
> +import java.lang.reflect.Modifier;
> +
> +import org.jboss.reflect.plugins.ClassInfoImpl;
> +import org.jboss.reflect.spi.ClassInfo;
> +import org.jboss.reflect.spi.TypeInfo;
> +import org.jboss.test.classinfo.support.ClassInfoGenericFieldsInterface;
> +import org.jboss.test.classinfo.support.ClassInfoGenericMethodsInterface;
> +
> +/**
> + * ClassInfoInterfaceTest.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public abstract class ClassInfoGenericInterfaceTest extends AbstractClassInfoTest
> +{
> +   public ClassInfoGenericInterfaceTest(String name)
> +   {
> +      super(name);
> +   }
> +
> +   public void testGenericMethodsInterface() throws Throwable
> +   {
> +      testGenericInterface(ClassInfoGenericMethodsInterface.class);
> +   }
> +   
> +   public void testGenericFieldsInterface() throws Throwable
> +   {
> +      testGenericInterface(ClassInfoGenericFieldsInterface.class);
> +   }
> +   
> +   private void testGenericInterface(Class clazz) throws Throwable
> +   {
> +      ClassInfoImpl expected = new ClassInfoImpl(clazz.getName(), Modifier.PUBLIC);
> +      TypeInfo info = testBasics(clazz, expected);
> +      
> +      assertFalse(info.isArray());
> +      assertFalse(info.isEnum());
> +      assertFalse(info.isPrimitive());
> +      
> +      ClassInfo classInfo = (ClassInfo) info;
> +      assertClassInfo(classInfo, clazz);
> +   }
> +}
>
> Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/ClassInfoTestSuite.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -56,6 +56,8 @@
>        suite.addTest(JavassistClassInfoTestCase.suite());
>        suite.addTest(IntrospectionAnnotatedClassInfoTestCase.suite());
>        suite.addTest(JavassistAnnotatedClassInfoTestCase.suite());
> +      suite.addTest(IntrospectionGenericInterfaceUnitTestCase.suite());
> +      suite.addTest(IntrospectionGenericClassUnitTestCase.suite());
>        
>        return suite;
>     }
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericClassUnitTestCase.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,52 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2005, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
> +
> +import junit.framework.Test;
> +
> +import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory;
> +import org.jboss.reflect.spi.TypeInfoFactory;
> +
> +/**
> + * Introspection ClassInfo Test Case.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 45663 $
> + */
> +public class IntrospectionGenericClassUnitTestCase extends ClassInfoGenericClassTest
> +{
> +   public static Test suite()
> +   {
> +      return suite(IntrospectionGenericClassUnitTestCase.class);
> +   }
> +   
> +   public IntrospectionGenericClassUnitTestCase(String name)
> +   {
> +      super(name);
> +   }
> +
> +   protected TypeInfoFactory getTypeInfoFactory()
> +   {
> +      return new IntrospectionTypeInfoFactory();
> +   }
> +
> +}
> \ No newline at end of file
>
> Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java
> ===================================================================
> --- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java	2006-12-04 14:20:46 UTC (rev 58837)
> +++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/IntrospectionGenericInterfaceUnitTestCase.java	2006-12-04 14:40:50 UTC (rev 58838)
> @@ -0,0 +1,51 @@
> +/*
> +* JBoss, Home of Professional Open Source
> +* Copyright 2006, JBoss Inc., and individual contributors as indicated
> +* by the @authors tag. See the copyright.txt 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.test.classinfo.test;
> +
> +import junit.framework.Test;
> +
> +import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory;
> +import org.jboss.reflect.spi.TypeInfoFactory;
> +
> +/**
> + * IntrospectionGenericInterfaceUnitTestCase.
> + * 
> + * @author <a href="adrian at jboss.com">Adrian Brock</a>
> + * @version $Revision: 1.1 $
> + */
> +public class IntrospectionGenericInterfaceUnitTestCase extends ClassInfoGenericInterfaceTest
> +{
> +   public IntrospectionGenericInterfaceUnitTestCase(String name)
> +   {
> +      super(name);
> +   }
> +
> +   public static Test suite()
> +   {
> +      return suite(IntrospectionGenericInterfaceUnitTestCase.class);
> +   }
> +
> +   protected TypeInfoFactory getTypeInfoFactory()
> +   {
> +      return new IntrospectionTypeInfoFactory();
> +   }
> +}
>
> _______________________________________________
> jboss-cvs-commits mailing list
> jboss-cvs-commits at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jboss-cvs-commits
>
>
>   



From brian.stansberry at jboss.com  Mon Dec  4 12:00:06 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Mon, 04 Dec 2006 12:00:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrHAk-0002Hy-B1@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/04 12:00:06

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Add a log message when inactivating a region
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.25 +5 -1      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.24
  retrieving revision 1.195.2.25
  diff -u -b -r1.195.2.24 -r1.195.2.25
  --- TreeCache.java	29 Nov 2006 04:43:02 -0000	1.195.2.24
  +++ TreeCache.java	4 Dec 2006 17:00:06 -0000	1.195.2.25
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.24 2006/11/29 04:43:02 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.25 2006/12/04 17:00:06 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -2249,6 +2249,10 @@
         DataNode subtreeRoot = null;
         boolean parentLocked = false;
         boolean subtreeLocked = false;
  +
  +      if (log.isDebugEnabled())
  +         log.debug("inactivating " + fqn);
  +      
         try
         {
   
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:45:30 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:45:30 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs
	...
Message-ID: <E1GrHsg-0003BU-LG@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:45:30

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs  
                        XPathDialogs.java
  Added:       as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs  
                        ConvertNodeToXPathDialog.java
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.9       +299 -134  jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: XPathDialogs.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- XPathDialogs.java	28 Nov 2006 17:31:48 -0000	1.8
  +++ XPathDialogs.java	4 Dec 2006 17:45:30 -0000	1.9
  @@ -21,17 +21,21 @@
    */
   package org.jboss.ide.eclipse.as.ui.dialogs;
   
  +import java.lang.reflect.InvocationTargetException;
   import java.util.ArrayList;
   import java.util.Arrays;
   import java.util.HashMap;
   
  +import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.Path;
   import org.eclipse.jface.dialogs.Dialog;
   import org.eclipse.jface.dialogs.IDialogConstants;
  +import org.eclipse.jface.dialogs.ProgressMonitorDialog;
   import org.eclipse.jface.fieldassist.ContentProposalAdapter;
   import org.eclipse.jface.fieldassist.IContentProposal;
   import org.eclipse.jface.fieldassist.IContentProposalProvider;
   import org.eclipse.jface.fieldassist.TextContentAdapter;
  +import org.eclipse.jface.operation.IRunnableWithProgress;
   import org.eclipse.jface.viewers.ITreeContentProvider;
   import org.eclipse.jface.viewers.TreeViewer;
   import org.eclipse.jface.viewers.Viewer;
  @@ -43,9 +47,13 @@
   import org.eclipse.swt.layout.FormAttachment;
   import org.eclipse.swt.layout.FormData;
   import org.eclipse.swt.layout.FormLayout;
  +import org.eclipse.swt.layout.GridData;
  +import org.eclipse.swt.layout.GridLayout;
   import org.eclipse.swt.widgets.Button;
  +import org.eclipse.swt.widgets.Combo;
   import org.eclipse.swt.widgets.Composite;
   import org.eclipse.swt.widgets.Control;
  +import org.eclipse.swt.widgets.Display;
   import org.eclipse.swt.widgets.Label;
   import org.eclipse.swt.widgets.Shell;
   import org.eclipse.swt.widgets.Text;
  @@ -53,6 +61,8 @@
   import org.eclipse.swt.widgets.TreeColumn;
   import org.eclipse.ui.ISharedImages;
   import org.eclipse.ui.PlatformUI;
  +import org.eclipse.wst.server.core.IServer;
  +import org.jboss.ide.eclipse.as.core.JBossServerCore;
   import org.jboss.ide.eclipse.as.core.model.DescriptorModel;
   import org.jboss.ide.eclipse.as.core.model.DescriptorModel.ServerDescriptorModel;
   import org.jboss.ide.eclipse.as.core.model.DescriptorModel.ServerDescriptorModel.XPathTreeItem;
  @@ -154,37 +164,43 @@
   	
   	public static class XPathDialog extends Dialog {
   
  -		private Label errorImage, errorLabel;
  -		private Text nameText, xpathText, attributeText;
  -		private Label nameLabel, xpathLabel, attributeLabel;
  -		private Button previewButton;
  +		protected Label errorImage, errorLabel, descriptionLabel;
  +		protected Text nameText, xpathText, attributeText;
  +		protected Combo categoryCombo, serverCombo;
  +		protected Label nameLabel, serverLabel, categoryLabel, xpathLabel, attributeLabel;
  +		protected Button previewButton;
   		
  -		private SimpleTreeItem tree;
  -		private String category;
  -		private JBossServer server;
  -		private String name, xpath, attribute;
  -		private String originalName = null;
  -		private XPathPreferenceTreeItem original = null;
  -		int previewId = 48879;
  -		
  -		private Tree previewTree;
  -		private TreeColumn column, column2, column3;
  -		private TreeViewer previewTreeViewer;
  -		private Composite main;
  +		protected XPathProposalProvider proposalProvider;
   		
  -		public XPathDialog(Shell parentShell, SimpleTreeItem tree, String categoryName, JBossServer server) {
  -			super(parentShell);
  -			this.tree = tree;
  -			this.category = categoryName;
  -			this.server = server;
  +		protected SimpleTreeItem tree;
  +		protected JBossServer server;
  +		protected String name, xpath, attribute, category;
  +		protected String originalName = null;
  +		protected XPathPreferenceTreeItem original = null;
  +		protected int previewId = 48879;
  +		
  +		protected Tree previewTree;
  +		protected TreeColumn column, column2, column3;
  +		protected TreeViewer previewTreeViewer;
  +		protected Composite main;
  +		
  +		public XPathDialog(Shell parentShell) {
  +			this(parentShell, null);
  +		}
  +		public XPathDialog(Shell parentShell, JBossServer server) {
  +			this(parentShell, server, null);
  +		}
  +		public XPathDialog(Shell parentShell, JBossServer server, String categoryName) {
  +			this(parentShell, server, categoryName, null);
   		}
   
  -		public XPathDialog(Shell parentShell, SimpleTreeItem tree, String categoryName, JBossServer server, String originalName) {
  +		public XPathDialog(Shell parentShell, JBossServer server, String categoryName, String originalName) {
   			super(parentShell);
  -			this.tree = tree;
   			this.category = categoryName;
   			this.server = server;
   			this.originalName = this.name = originalName;
  +			if( server != null )
  +				this.tree = server.getAttributeHelper().getXPathPreferenceTree();
   		}
   
   		protected void configureShell(Shell shell) {
  @@ -199,8 +215,12 @@
   			super.createButtonsForButtonBar(parent);
   			previewButton = createButton(parent, previewId, "Preview", true);
   			if( name == null ) getButton(IDialogConstants.OK_ID).setEnabled(false);
  -
   			addListeners();
  +			try {
  +				checkErrors();
  +			} catch( Exception e ) {
  +				e.printStackTrace();
  +			}
   		}
   
   		
  @@ -208,24 +228,40 @@
   			main = (Composite)super.createDialogArea(parent);
   			main.setLayout(new FormLayout());
   			layoutWidgets(main);
  -			
  +			fillCombos();
   			if( name != null ) nameText.setText(name);
   			if( attribute != null ) attributeText.setText(attribute);
   			if( xpath != null ) xpathText.setText(xpath);
   			
  +			proposalProvider = new XPathProposalProvider();
  +			proposalProvider.setServer(server);
   			 ContentProposalAdapter adapter = new
   			 ContentProposalAdapter(xpathText, new TextContentAdapter(),
  -			                                 new XPathProposalProvider(server), null, null);
  +					proposalProvider, null, null);
   			                
   			 adapter.setProposalAcceptanceStyle(ContentProposalAdapter.PROPOSAL_REPLACE);
  -
   			return main;
   		} 
   		
  +		protected void fillCombos() {
  +			if( serverCombo != null ) {
  +				IServer servers[] = JBossServerCore.getIServerJBossServers();
  +				String[] names = new String[servers.length];
  +				for( int i = 0; i < servers.length; i++ ) {
  +					names[i] = servers[i].getName();
  +				}
  +				serverCombo.setItems(names);
  +			}
  +			
  +			if( categoryCombo != null && tree != null ) {
  +				refreshCategoryCombo();
  +			}
  +		}
  +		
   		protected void addListeners() {
   			nameText.addModifyListener(new ModifyListener() {
   				public void modifyText(ModifyEvent e) {
  -					verifyName();
  +					checkErrors();
   					name = nameText.getText();
   				} 
   			});
  @@ -247,17 +283,94 @@
   					previewPressed();
   				} 
   			});
  +			
  +			
  +			if( serverCombo != null ) {
  +				serverCombo.addSelectionListener(new SelectionListener() {
  +					public void widgetDefaultSelected(SelectionEvent e) {
  +					}
  +					public void widgetSelected(SelectionEvent e) {
  +						int index = serverCombo.getSelectionIndex();
  +						String val = serverCombo.getItem(index);
  +						JBossServer[] serverList = JBossServerCore.getAllJBossServers();
  +						for( int i = 0; i < serverList.length; i++ ) {
  +							if( serverList[i].getServer().getName().equals(val)) {
  +								setServer(serverList[i]);
  +								return;
  +							}
  +						}
  +					} 
  +				});
   		}
  -		protected void verifyName() {
   			
  -			if( nameText.getText().equals("")) {
  -				errorLabel.setText(Messages.XPathNameEmpty);
  -				errorLabel.setVisible(true);
  -				errorImage.setVisible(true);
  +			if( categoryCombo != null ) {
  +				categoryCombo.addModifyListener(new ModifyListener() {
  +					public void modifyText(ModifyEvent e) {
  +						category = categoryCombo.getText();
  +						checkErrors();
  +					} 
  +				});
  +				categoryCombo.addSelectionListener(new SelectionListener() {
  +					public void widgetDefaultSelected(SelectionEvent e) {
  +					}
  +					public void widgetSelected(SelectionEvent e) {
  +						category = categoryCombo.getText();
  +						checkErrors();
  +					}
  +				});
  +			}
  +		}
  +		
  +		
  +		protected void checkErrors() {
  +			ArrayList errorList = getErrors();
  +			if( errorList.size() == 0 ) { 
  +				setError(null); 
  +				getButton(IDialogConstants.OK_ID).setEnabled(true);
  +				return; 
  +			}
  +			setError((String)errorList.get(0));
  +			if( getButton(IDialogConstants.OK_ID) != null ) 
   				getButton(IDialogConstants.OK_ID).setEnabled(false);
   				return;
   			}
  +		protected ArrayList getErrors() {
  +			ArrayList list = new ArrayList();
  +			String serverError = getServerError(); if( serverError != null ) list.add(serverError);
  +			String nameError = getNameError(); if( nameError != null ) list.add(nameError);
  +			String categoryError = getCategoryError(); if( categoryError != null ) list.add(categoryError);
  +			return list;
  +		}
  +		
  +		protected String getServerError() {
  +			if( server == null ) return "Please Select a Server";
  +			return null;
  +		}
   			
  +		protected String getCategoryError() {
  +			if( "".equals(category)) {
  +				return "Category must not be blank";
  +			}
  +			return null;
  +		}
  +		
  +		protected void setError(String message) {
  +			if( message == null ) {
  +				errorImage.setVisible(false);
  +				errorLabel.setVisible(false);
  +				errorLabel.setText("");
  +			} else {
  +				errorImage.setVisible(true);
  +				errorLabel.setVisible(true);
  +				errorLabel.setText(message);
  +			}
  +		}
  +		
  +		protected String getNameError() {
  +			if( nameText.getText().equals("")) {
  +				return Messages.XPathNameEmpty;
  +			}
  +			if( tree != null ) {
   			SimpleTreeItem[] categories = tree.getChildren();
   			SimpleTreeItem categoryItem = null;
   			for( int i = 0; i < categories.length; i++ ) {
  @@ -271,51 +384,80 @@
   					if(nameText.getText().equals( ((XPathPreferenceTreeItem)xpathNames[i]).getName())) {
   						
   						if( originalName == null || !nameText.getText().equals(originalName)) 
  -							found = true;
  +								return Messages.XPathNameInUse;
   					}
   				}
  -				if( found ) {
  -					// error, name in use
  -					errorLabel.setText(Messages.XPathNameInUse);
  -					errorLabel.setVisible(true);
  -					errorImage.setVisible(true);
  -					getButton(IDialogConstants.OK_ID).setEnabled(false);
  -				} else {
  -					errorLabel.setVisible(false);
  -					errorImage.setVisible(false);
  -					getButton(IDialogConstants.OK_ID).setEnabled(true);
   				}
   			}
  +			return null;
  +		}
  +
  +		
  +		protected void setServer(JBossServer s) {
  +			server = s;
  +			tree = server.getAttributeHelper().getXPathPreferenceTree();
  +			proposalProvider.setServer(s);
  +			refreshCategoryCombo();
  +			checkErrors();
   		}
  +		
  +		protected void refreshCategoryCombo() {
  +			SimpleTreeItem[] categories = tree.getChildren();
  +			String[] categoryNames = new String[categories.length];
  +			for( int i = 0; i < categories.length; i++ ) {
  +				categoryNames[i] = (String)categories[i].getData();
  +			}
  +			categoryCombo.setItems(categoryNames);
  +		}
  +		
   		protected void previewPressed() {
  +			if( server == null ) {
  +				checkErrors();
  +				return;
  +			}
  +			
  +			IRunnableWithProgress op = new IRunnableWithProgress() {
  +				public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
  +					final IProgressMonitor monitor2 = monitor;
  +					server.getDescriptorModel().refreshDescriptors(monitor2);
   			XPathTreeItem[] item = server.getDescriptorModel().getXPath(xpathText.getText(), attributeText.getText());
  -			ArrayList list = new ArrayList();
  +					final ArrayList list = new ArrayList();
   			list.addAll(Arrays.asList(item));
  +					Display.getDefault().asyncExec(new Runnable() { 
  +						public void run() {
   			previewTreeViewer.setInput(list);
  -			
   			if( list.size() == 0 ) {
   				errorImage.setVisible(true);
   				errorLabel.setText("No XML elements matched your search.");
   				errorLabel.setVisible(true);
   			} else {
  -				errorImage.setVisible(false);
  -				errorLabel.setVisible(false);
  +								checkErrors();
   			}
  -			
   			main.layout();
   		}
  +					});
  +				}
  +			};
  +			try {
  +				new ProgressMonitorDialog(new Shell()).run(false, true, op);
  +			} catch( Exception e) {
  +				e.printStackTrace();
  +			}
  +		}
   		protected void layoutWidgets(Composite c) {
   			// create widgets
  +			descriptionLabel = new Label(c, SWT.WRAP);
  +			descriptionLabel.setText("An XPath is a way to find a specific XML element inside an xml file. \n" + 
  +					"This dialog will help you create one. These XPaths' values can then be modified\n"
  +					+ "by using the JBoss Servers View with the Properties View.");
  +			descriptionLabel.setVisible(true);
   			errorLabel = new Label(c, SWT.NONE);
   			errorImage = new Label(c, SWT.NONE);
   			errorImage.setImage(PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJS_ERROR_TSK));
   			
  -			nameLabel = new Label(c, SWT.NONE);
  -			xpathLabel = new Label(c, SWT.NONE);
  -			attributeLabel = new Label(c, SWT.NONE);
  -			nameText= new Text(c, SWT.BORDER);
  -			xpathText = new Text(c, SWT.BORDER);
  -			attributeText = new Text(c, SWT.BORDER);
  +			
  +			Composite middleComposite = createMiddleComposite(c);
  +			
   
   			// Now do the tree and viewer
   			previewTree = new Tree(c, SWT.BORDER);
  @@ -336,76 +478,46 @@
   			previewTreeViewer = new TreeViewer(previewTree);
   
   			
  -			// set some text
  -			nameLabel.setText(Messages.XPathName);
  -			xpathLabel.setText(Messages.XPathPattern);
  -			attributeLabel.setText(Messages.XPathAttribute);
  +
  +			
   
   			c.layout();
   			int pixel = Math.max(Math.max(nameLabel.getSize().x, xpathLabel.getSize().x), attributeLabel.getSize().x);
   			pixel += 5;
   			
   			// Lay them out
  -			//errorLabel.setText("Category Name In Use.");
  +			FormData descriptionData = new FormData();
  +			descriptionData.left = new FormAttachment(0, 5);
  +			descriptionData.right = new FormAttachment(100, -5);
  +			descriptionData.top = new FormAttachment(0,5);
  +			descriptionLabel.setLayoutData(descriptionData);
  +			
   			FormData errorData = new FormData();
   			errorData.left = new FormAttachment(errorImage,5);
  -			errorData.top = new FormAttachment(0,5);
  +			errorData.top = new FormAttachment(descriptionLabel,5);
   			errorData.right = new FormAttachment(0,300);
   			errorLabel.setLayoutData(errorData);
   			errorLabel.setVisible(false);
   			
   			FormData errorImageData = new FormData();
   			errorImageData.left = new FormAttachment(0,5);
  -			errorImageData.top = new FormAttachment(0,5);
  +			errorImageData.top = new FormAttachment(descriptionLabel,5);
   			errorImage.setLayoutData(errorImageData);
   			errorImage.setVisible(false);
   
   			
  -			/* Name */
  -			FormData nameLabelData = new FormData();
  -			nameLabelData.left = new FormAttachment(0,5);
  -			nameLabelData.top = new FormAttachment(errorLabel,5);
  -			nameLabel.setLayoutData(nameLabelData);
  -
  -			FormData nameTextData = new FormData();
  -			nameTextData.left = new FormAttachment(0,pixel);
  -			nameTextData.right = new FormAttachment(100,-5);
  -			nameTextData.top = new FormAttachment(errorLabel,4);
  -			nameText.setLayoutData(nameTextData);
  -
  -
  -			/* XPath */
  -			FormData xpathLabelData = new FormData();
  -			xpathLabelData.left = new FormAttachment(0,5);
  -			xpathLabelData.top = new FormAttachment(nameText,5);
  -			xpathLabel.setLayoutData(xpathLabelData);
  -
  -			FormData xpathTextData = new FormData();
  -			xpathTextData.left = new FormAttachment(0,pixel);
  -			xpathTextData.right = new FormAttachment(100,-5);
  -			xpathTextData.top = new FormAttachment(nameText,4);
  -			xpathText.setLayoutData(xpathTextData);
  -
  -
  -			/* Attribute */
  -			FormData attributeLabelData = new FormData();
  -			attributeLabelData.left = new FormAttachment(0,5);
  -			attributeLabelData.top = new FormAttachment(xpathText,5);
  -			attributeLabel.setLayoutData(attributeLabelData);
  -
  -			FormData attributeTextData = new FormData();
  -			attributeTextData.left = new FormAttachment(0, pixel);
  -			attributeTextData.right = new FormAttachment(100,-5);
  -			attributeTextData.top = new FormAttachment(xpathText,4);
  -			
  -			attributeText.setLayoutData(attributeTextData);
   			
  +			FormData middleCompositeData = new FormData();
  +			middleCompositeData.left = new FormAttachment(0,5);
  +			middleCompositeData.right = new FormAttachment(100, -5);
  +			middleCompositeData.top = new FormAttachment(errorLabel, 5);
  +			middleComposite.setLayoutData(middleCompositeData);
   			
   			// Tree layout data
   			FormData previewTreeData = new FormData();
   			previewTreeData.left = new FormAttachment(0,5);
   			previewTreeData.right = new FormAttachment(100,-5);
  -			previewTreeData.top = new FormAttachment(attributeText,5);
  +			previewTreeData.top = new FormAttachment(middleComposite,5);
   			previewTreeData.bottom = new FormAttachment(100,-5);
   			previewTree.setLayoutData(previewTreeData);
   			
  @@ -455,6 +567,44 @@
   			});
   			
   			previewTreeViewer.setLabelProvider(new XPathPropertyLabelProvider());
  +			
  +		}
  +
  +		protected Composite createMiddleComposite(Composite c) {
  +			Composite gridComposite = new Composite(c, SWT.NONE);
  +			gridComposite.setLayout(new GridLayout(2, false));
  +			
  +			nameLabel = new Label(gridComposite, SWT.NONE);
  +			nameText= new Text(gridComposite, SWT.BORDER);
  +			nameText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true));
  +			
  +			if( server == null ) {
  +				serverLabel = new Label(gridComposite, SWT.NONE);
  +				serverCombo = new Combo(gridComposite, SWT.BORDER | SWT.READ_ONLY);
  +				serverCombo.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true));
  +			}
  +			
  +			if( category == null ) {
  +				categoryLabel = new Label(gridComposite, SWT.NONE);
  +				categoryCombo = new Combo(gridComposite, SWT.BORDER);
  +				categoryCombo.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true));
  +			}
  +			
  +			xpathLabel = new Label(gridComposite, SWT.NONE);
  +			xpathText = new Text(gridComposite, SWT.BORDER);
  +			xpathText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true));
  +			attributeLabel = new Label(gridComposite, SWT.NONE);
  +			attributeText = new Text(gridComposite, SWT.BORDER);
  +			attributeText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true));
  +
  +
  +			// set some text
  +			nameLabel.setText(Messages.XPathName);
  +			if( serverLabel != null ) serverLabel.setText("Server: ");
  +			if( categoryLabel != null ) categoryLabel.setText("Category: ");
  +			xpathLabel.setText(Messages.XPathPattern);
  +			attributeLabel.setText(Messages.XPathAttribute);
  +			return gridComposite;
   		}
   
   		public String getAttribute() {
  @@ -469,6 +619,13 @@
   			return xpath;
   		}
   
  +		public String getCategory() {
  +			return category;
  +		}
  +		public JBossServer getServer() {
  +			return server;
  +		}
  +
   		public void setAttribute(String attribute) {
   			this.attribute = attribute;
   			if( attributeText != null && !attributeText.isDisposed())
  @@ -503,12 +660,20 @@
   		
   		private JBossServer server;
   		private ServerDescriptorModel model;
  -		public XPathProposalProvider(JBossServer server) {
  +		public XPathProposalProvider() {
  +		}
  +		public void setServer(JBossServer server) {
   			this.server = server;
  +			if( server != null ) {
   			String serverConfDir = server.getConfigDirectory(false);
   			model = DescriptorModel.getDefault().getServerModel(new Path(serverConfDir));
  +			} else {
  +				model = null;
  +			}
   		}
   		public IContentProposal[] getProposals(String contents, int position) {
  +			if( model == null ) return new IContentProposal[]{};
  +			
   			if( contents.equals("") || contents.equals("/") || contents.equals(" ")) {
   				return new IContentProposal[] { new XPathContentProposal("/server/", "/server/".length(), null, null)};
   			}
  @@ -520,7 +685,7 @@
   			if( type == IN_ATTRIBUTE ) return getAttributeNameProposals(contents);
   			if( type == NEW_ATTRIBUTE_VALUE ) return getAttributeValueProposals(contents, "");
   			if( type == IN_ATTRIBUTE_VALUE ) return getAttributeValueProposals(contents);
  -			return null;
  +			return new IContentProposal[]{};
   		}
   		
   		protected XPathTreeItem2[] getXPath(String xpath) {
  
  
  
  1.1      date: 2006/12/04 17:45:30;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/ConvertNodeToXPathDialog.java
  
  Index: ConvertNodeToXPathDialog.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.ui.dialogs;
  
  import java.util.ArrayList;
  
  import org.eclipse.jface.text.DocumentEvent;
  import org.eclipse.jface.text.IDocument;
  import org.eclipse.jface.text.ITextViewer;
  import org.eclipse.jface.text.contentassist.ICompletionProposal;
  import org.eclipse.jface.text.contentassist.ICompletionProposalExtension2;
  import org.eclipse.jface.text.contentassist.IContextInformation;
  import org.eclipse.jface.window.Window;
  import org.eclipse.swt.SWT;
  import org.eclipse.swt.events.SelectionEvent;
  import org.eclipse.swt.events.SelectionListener;
  import org.eclipse.swt.graphics.Image;
  import org.eclipse.swt.graphics.Point;
  import org.eclipse.swt.layout.FormAttachment;
  import org.eclipse.swt.layout.FormData;
  import org.eclipse.swt.layout.FormLayout;
  import org.eclipse.swt.layout.GridData;
  import org.eclipse.swt.layout.GridLayout;
  import org.eclipse.swt.widgets.Combo;
  import org.eclipse.swt.widgets.Composite;
  import org.eclipse.swt.widgets.Control;
  import org.eclipse.swt.widgets.Group;
  import org.eclipse.swt.widgets.Label;
  import org.eclipse.swt.widgets.Shell;
  import org.eclipse.wst.xml.core.internal.document.AttrImpl;
  import org.eclipse.wst.xml.core.internal.provisional.document.IDOMDocument;
  import org.eclipse.wst.xml.ui.internal.contentassist.ContentAssistRequest;
  import org.eclipse.wst.xml.ui.internal.contentassist.XMLContentAssistProcessor;
  import org.jboss.ide.eclipse.as.core.server.JBossServer;
  import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper;
  import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper.SimpleXPathPreferenceTreeItem;
  import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper.XPathPreferenceTreeItem;
  import org.jboss.ide.eclipse.as.core.util.SimpleTreeItem;
  import org.jboss.ide.eclipse.as.ui.Messages;
  import org.jboss.ide.eclipse.as.ui.dialogs.XPathDialogs.XPathDialog;
  import org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals.IServiceXMLQuickFixProposalProvider;
  import org.jboss.ide.eclipse.as.ui.views.server.JBossServerView;
  import org.w3c.dom.NamedNodeMap;
  import org.w3c.dom.Node;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public class ConvertNodeToXPathDialog extends XPathDialog {
  	private Node node;
  	private ArrayList keyRows;
  	
  	private static final String NO_ATTRIBUTE = "NONE";
  	
  	protected ConvertNodeToXPathDialog(Shell parentShell, Node node, String attributeName) {
  		super(parentShell);
  		this.node = node;
  		setAttribute(attributeName == null ? "" : attributeName);
  	}
  	
  	protected void configureShell(Shell shell) {
  		super.configureShell(shell);
  		setShellStyle(getShellStyle() | SWT.RESIZE);
  		shell.setText(Messages.XPathNewXpath);
  		shell.setBounds(shell.getLocation().x, shell.getLocation().y, 550, 550);
  	}
  
  	protected Control createDialogArea(Composite parent) {
  		Control c = super.createDialogArea(parent);
  		refreshXPath();
  		return c;
  	}
  	
  	protected Composite createMiddleComposite(Composite c) {
  		Composite middleComposite = new Composite(c, SWT.NONE);
  		middleComposite.setLayout(new FormLayout());
  		
  		Composite gridComposite = super.createMiddleComposite(middleComposite);
  		FormData gridData = new FormData();
  		gridData.left = new FormAttachment(0,5);
  		gridData.right = new FormAttachment(100, -5);
  		gridData.top = new FormAttachment(0,5);
  		gridComposite.setLayoutData(gridData);
  		
  		// now add my stuff?
  		Composite keyComposite = createKeyComposite(middleComposite);
  		FormData keyData = new FormData();
  		keyData.left = new FormAttachment(0,5);
  		keyData.right = new FormAttachment(100,-5);
  		keyData.top = new FormAttachment(gridComposite, 5);
  		keyComposite.setLayoutData(keyData);
  		
  		return middleComposite;
  	}
  	
  	protected Composite createKeyComposite(Composite parent) {
  		Group main = new Group(parent, SWT.NONE);
  		main.setLayout(new GridLayout(2, false));
  		keyRows = new ArrayList();
  		Node localNode = node;
  		String pathText = "";
  		while( localNode != null && !(localNode instanceof IDOMDocument)) {
  			if( !localNode.getNodeName().equals("#text")) {
  				keyRows.add(0, new NameComboPair(main, localNode));
  			}
  			localNode = localNode.getParentNode();
  		}
  
  		for( int i = 0; i < keyRows.size(); i++ ) {
  			((NameComboPair)keyRows.get(i)).create();
  		}
  		
  		main.setText("Keyed Attributes");
  		
  		
  		// The very last row should not key off the same attribute name that they wish to change
  		final NameComboPair lastRow = (NameComboPair)keyRows.get(keyRows.size()-1);
  		lastRow.combo.addSelectionListener(new SelectionListener() {
  			public void widgetDefaultSelected(SelectionEvent e) {
  			}
  			public void widgetSelected(SelectionEvent e) {
  				checkErrors();
  			} 
  		});
  		
  		return main;
  	}
  	protected ArrayList getErrors() {
  		ArrayList errors = super.getErrors();
  		NameComboPair pair = (NameComboPair)keyRows.get(keyRows.size()-1);
  		String val = pair.combo.getItem(pair.combo.getSelectionIndex());
  		if(attribute != null && val.startsWith(attribute + "=")) {
  			errors.add("You should not key off the value you wish to change");
  		}
  		return errors;
  	}
  
  	
  	public void refreshXPath() {
  		String finalString = "";
  		for( int i = 0; i < keyRows.size(); i++ ) {
  			finalString += ((NameComboPair)keyRows.get(i)).toString();
  		}
  		setXpath(finalString);
  		previewPressed();
  	}
  	
  	protected class NameComboPair {
  		private Node node;
  		private Composite parent;
  		private Label label;
  		private Combo combo;
  		public NameComboPair(Composite parent, Node node) {
  			this.node = node;
  			this.parent = parent;
  		}
  		public void create() {
  			label = new Label(parent, SWT.NONE);
  			label.setText(node.getNodeName());
  			combo = new Combo(parent, SWT.BORDER | SWT.READ_ONLY);
  			label.setLayoutData(new GridData(SWT.LEFT, SWT.CENTER, false, false));
  			combo.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true));
  			
  			// fill the combo
  			NamedNodeMap map = node.getAttributes();
  			ArrayList list = new ArrayList();
  			list.add(NO_ATTRIBUTE);
  			int selectedIndex = 0;
  			for( int i = 0; i < map.getLength(); i++ ) {
  				Node attr = map.item(i);
  				if( attr instanceof AttrImpl ) {
  					AttrImpl impl = ((AttrImpl)attr);
  					list.add(impl.getName() + "='" + impl.getValue() + "'");
  					if( impl.getName().equals("name") && !attribute.equals("name"))
  						selectedIndex = i+1;
  				}
  			}
  			
  			combo.setItems((String[]) list.toArray(new String[list.size()]));
  			combo.select(selectedIndex);
  			
  			
  			// selection listener
  			combo.addSelectionListener(new SelectionListener() {
  				public void widgetDefaultSelected(SelectionEvent e) {
  				}
  				public void widgetSelected(SelectionEvent e) {
  					refreshXPath();
  				} 
  			});
  		}
  		
  		public String toString() {
  			String ret = "/" + node.getNodeName();
  			String comboSelection = combo.getItem(combo.getSelectionIndex());
  			if( !comboSelection.equals(NO_ATTRIBUTE))
  				ret += "[@" + comboSelection + "]";
  			return ret;
  		}
  	}
  
  	
  	public static class ConvertNodeToXPathDialogProvider extends XMLContentAssistProcessor implements IServiceXMLQuickFixProposalProvider {
  
  		public ICompletionProposal[] getProposals(ITextViewer viewer, int offset) {
  			return computeCompletionProposals(viewer, offset);
  		}
  		
  		protected void addAttributeNameProposals(ContentAssistRequest contentAssistRequest) {
  			Node n = contentAssistRequest.getNode();
  			String name = n.getNodeName();
  			String attName = ((AttrImpl)n.getAttributes().getNamedItem(contentAssistRequest.getText())).getName();
  			contentAssistRequest.addProposal(createProposal(n, attName));
  		}
  		
  		protected void addAttributeValueProposals(ContentAssistRequest contentAssistRequest) {
  			String elementName = contentAssistRequest.getNode().getNodeName();
  			String match = contentAssistRequest.getMatchString();
  			String text = contentAssistRequest.getText();
  			int beginPos = contentAssistRequest.getReplacementBeginPosition();
  
  			// find the attribute we're inside of, because the contentAssistRequester only returns the element (BOO!)
  			NamedNodeMap map = contentAssistRequest.getNode().getAttributes();
  			
  			boolean found = false;
  			AttrImpl attribute = null;
  			for( int i = 0; i < map.getLength() && !found; i++ ) {
  				Node tmp = map.item(i);
  				if( tmp instanceof AttrImpl ) {
  					int start = ((AttrImpl)tmp).getStartOffset();
  					int end = ((AttrImpl)tmp).getEndOffset();
  					if( beginPos > start && beginPos < end ) {
  						found = true;
  						attribute = (AttrImpl)tmp;
  					}
  				}
  			}
  			if( found ) {
  				contentAssistRequest.addProposal(createProposal(contentAssistRequest.getNode(), attribute.getName()));
  			}
  		}
  		
  		protected void addEmptyDocumentProposals(ContentAssistRequest contentAssistRequest) {
  		}
  		
  		protected void addTagInsertionProposals(ContentAssistRequest contentAssistRequest, int childPosition) {
  			contentAssistRequest.addProposal(createProposal(contentAssistRequest.getNode(), null));
  		}
  		
  		
  		protected ICompletionProposal createProposal(Node node, String attributeName) {
  			return new OpenXPathDialogProposal(node, attributeName);
  		}
  	}
  	
  	public static class OpenXPathDialogProposal implements ICompletionProposal, ICompletionProposalExtension2 {
  		private Node node;
  		private String attributeName;
  		public OpenXPathDialogProposal(Node node, String attributeName ) {
  			this.node = node;
  			this.attributeName = attributeName;
  		}
  		public void apply(IDocument document) {
  		}
  
  		public String getAdditionalProposalInfo() {
  			return null;
  		}
  
  		public IContextInformation getContextInformation() {
  			return null;
  		}
  
  		public String getDisplayString() {
  			return "Add to XPaths";
  		}
  
  		public Image getImage() {
  			return null;
  		}
  
  		public Point getSelection(IDocument document) {
  			return null;
  		}
  
  		public void apply(ITextViewer viewer, char trigger, int stateMask, int offset) {
  			ConvertNodeToXPathDialog d = new ConvertNodeToXPathDialog(new Shell(), node, attributeName);
  			int result = d.open();
  			if( result == Window.OK) {
  				JBossServer s = d.getServer();
  				SimpleTreeItem tree = s.getAttributeHelper().getXPathPreferenceTree();
  				String category = d.getCategory();
  				SimpleTreeItem[] categories = tree.getChildren();
  				SimpleTreeItem categoryItem = null;
  				for( int i = 0; i < categories.length; i++ ) {
  					if( categories[i].getData().equals(category)) 
  						categoryItem = categories[i];
  				}
  				
  				// If the category doesn't exist, create it
  				if( categoryItem == null ) {
  					categoryItem = new SimpleXPathPreferenceTreeItem(tree, category);
  				}
  				
  				XPathPreferenceTreeItem dsfa = new XPathPreferenceTreeItem(categoryItem, d.getName(), d.getXpath(), d.getAttribute());
  				ServerAttributeHelper helper = s.getAttributeHelper();
  				helper.saveXPathPreferenceTree(tree);
  				helper.save();
  				JBossServerView.getDefault().refreshJBTree(null);
  			}
  		}
  
  		public void selected(ITextViewer viewer, boolean smartToggle) {
  		}
  
  		public void unselected(ITextViewer viewer) {
  		}
  
  		public boolean validate(IDocument document, int offset, DocumentEvent event) {
  			return false;
  		}
  		
  	}
  	
  }
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:46:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:46:39 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers
	...
Message-ID: <E1GrHtn-0003Dj-9Q@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:46:39

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers 
                        DescriptorXPathViewProvider.java
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view. Added action which allows you to open file directly in editor
  
  Revision  Changes    Path
  1.4       +40 -5     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DescriptorXPathViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DescriptorXPathViewProvider.java	30 Nov 2006 16:11:42 -0000	1.3
  +++ DescriptorXPathViewProvider.java	4 Dec 2006 17:46:39 -0000	1.4
  @@ -27,6 +27,8 @@
   import java.util.Arrays;
   import java.util.HashMap;
   
  +import org.eclipse.core.filesystem.EFS;
  +import org.eclipse.core.filesystem.IFileStore;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.jface.action.Action;
   import org.eclipse.jface.action.IMenuListener;
  @@ -75,7 +77,14 @@
   import org.eclipse.swt.widgets.TreeColumn;
   import org.eclipse.swt.widgets.TreeItem;
   import org.eclipse.ui.IActionBars;
  +import org.eclipse.ui.IEditorDescriptor;
  +import org.eclipse.ui.IEditorInput;
  +import org.eclipse.ui.IWorkbench;
  +import org.eclipse.ui.IWorkbenchPage;
   import org.eclipse.ui.IWorkbenchPart;
  +import org.eclipse.ui.IWorkbenchWindow;
  +import org.eclipse.ui.PlatformUI;
  +import org.eclipse.ui.internal.editors.text.JavaFileEditorInput;
   import org.eclipse.ui.views.properties.IPropertySheetPage;
   import org.eclipse.wst.server.core.IServer;
   import org.jboss.ide.eclipse.as.core.JBossServerCore;
  @@ -103,7 +112,8 @@
   	private XPathTreeLabelProvider labelProvider;
   	private DescriptorXPathPropertySheetPage propertyPage;
   
  -	private Action newXPathCategoryAction, deleteXPathCategoryAction, newXPathAction, editXPathAction, deleteXPathAction;
  +	private Action newXPathCategoryAction, deleteXPathCategoryAction, newXPathAction, 
  +					editXPathAction, deleteXPathAction, editFileAction;
   
   	private IServer server;
   	private JBossServer jbServer;
  @@ -242,7 +252,7 @@
   				Object o = getActiveCategory();
   				if( o != null && o instanceof SimpleXPathPreferenceTreeItem) {
   					String category = (String)  ((SimpleXPathPreferenceTreeItem)o).getData();
  -					XPathDialog d = new XPathDialog(Display.getCurrent().getActiveShell(), tree, category, jbServer);
  +					XPathDialog d = new XPathDialog(Display.getCurrent().getActiveShell(), jbServer, category);
   					if( d.open() == Window.OK ) {
   						SimpleTreeItem[] categories = tree.getChildren();
   						SimpleTreeItem categoryItem = null;
  @@ -265,14 +275,13 @@
   
   		editXPathAction = new Action() {
   			public void run() {
  -				SimpleTreeItem tree = getRoot();
   				Object o = getPropertySelection();
   				if( o != null && o instanceof XPathPreferenceTreeItem) {
   					XPathPreferenceTreeItem original = (XPathPreferenceTreeItem)o;
   					String category = (String)  original.getParent().getData();
   					
  -					XPathDialog d = new XPathDialog(Display.getCurrent().getActiveShell(), tree, 
  -													category, jbServer, original.getName());
  +					XPathDialog d = new XPathDialog(Display.getCurrent().getActiveShell(), 
  +							jbServer, category, original.getName());
   					d.setAttribute(original.getAttributeName());
   					d.setXpath(original.getXPath());
   					
  @@ -303,6 +312,27 @@
   			}
   		};
   		deleteXPathAction.setText(Messages.DescriptorXPathDeleteXPath);
  +		
  +		editFileAction = new Action() {
  +			public void run() {
  +				try {
  +					Object o = getPropertySelection();
  +					File file = ((XPathTreeItem)o).getFile();
  +					IWorkbench wb = PlatformUI.getWorkbench();
  +					IWorkbenchWindow win = wb.getActiveWorkbenchWindow();
  +					IWorkbenchPage page = win.getActivePage();
  +					IFileStore fileStore= EFS.getLocalFileSystem().fromLocalFile(file);
  +					if( fileStore != null ) {
  +						IEditorInput input = new JavaFileEditorInput(fileStore);
  +						IEditorDescriptor desc = PlatformUI.getWorkbench().
  +							getEditorRegistry().getDefaultEditor(file.getName());
  +					   page.openEditor(input, desc.getId());
  +					}
  +				} catch( Exception exc ) {
  +				}
  +			}
  +		};
  +		editFileAction.setText("Edit File");
   	}
   
   	public void fillContextMenu(Shell shell, IMenuManager menu, Object selection) {
  @@ -313,6 +343,7 @@
   		}
   		
   		if( selection instanceof SimpleXPathPreferenceTreeItem ) {
  +			setActiveCategory(((SimpleXPathPreferenceTreeItem)selection));
   			menu.add(this.newXPathAction);
   			menu.add(this.deleteXPathCategoryAction);
   			menu.add(new Separator());
  @@ -529,6 +560,10 @@
   				menu.add(editXPathAction);
   				menu.add(deleteXPathAction);
   			}
  +			if( getPropertySelection() != null && getPropertySelection() instanceof XPathTreeItem 
  +					&& ((XPathTreeItem)getPropertySelection()).getFile() != null ) {
  +				menu.add(editFileAction);
  +			}
   		}
   
   		
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:47:08 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:08 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui  ...
Message-ID: <E1GrHuG-0003E9-Tn@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:08

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui  plugin.xml
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.26      +4 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- plugin.xml	30 Nov 2006 16:10:34 -0000	1.25
  +++ plugin.xml	4 Dec 2006 17:47:08 -0000	1.26
  @@ -219,6 +219,10 @@
                  name="Startup / Shutdown Events"
                  typeId="org.jboss.ide.eclipse.as.core.runtime.server.polling.MajorType"/>
         </extension>
  +      <extension
  +            point="org.jboss.ide.eclipse.as.ui.mbeans.ServiceXMLQuickFixProvider">
  +         <QuickFixProvider class="org.jboss.ide.eclipse.as.ui.dialogs.ConvertNodeToXPathDialog$ConvertNodeToXPathDialogProvider"/>
  +      </extension>
      
      
   </plugin>
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:47:36 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:36 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema -
	New directory ...
Message-ID: <E1GrHui-0003EG-Pz@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:36

  Log:
  Directory /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema added to the repository


From rawblem at gmail.com  Mon Dec  4 12:47:36 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:36 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals
	- New directory ...
Message-ID: <E1GrHui-0003EK-Sm@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:36

  Log:
  Directory /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals added to the repository


From rawblem at gmail.com  Mon Dec  4 12:47:38 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:38 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors
	...
Message-ID: <E1GrHuk-0003Ea-Lw@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:38

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors 
                        ServiceXMLCorrectionAssistantProvider.java
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.3       +37 -2     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLCorrectionAssistantProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServiceXMLCorrectionAssistantProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLCorrectionAssistantProvider.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ServiceXMLCorrectionAssistantProvider.java	20 Nov 2006 19:22:25 -0000	1.2
  +++ ServiceXMLCorrectionAssistantProvider.java	4 Dec 2006 17:47:38 -0000	1.3
  @@ -25,6 +25,9 @@
   import java.util.Arrays;
   
   import org.eclipse.core.runtime.CoreException;
  +import org.eclipse.core.runtime.IConfigurationElement;
  +import org.eclipse.core.runtime.IExtensionRegistry;
  +import org.eclipse.core.runtime.Platform;
   import org.eclipse.jdt.core.IMethod;
   import org.eclipse.jdt.core.IType;
   import org.eclipse.jface.text.contentassist.CompletionProposal;
  @@ -47,13 +50,34 @@
   import org.eclipse.wst.xml.ui.internal.correction.QuickFixProcessorXML;
   import org.eclipse.wst.xml.ui.internal.editor.XMLEditorPluginImageHelper;
   import org.eclipse.wst.xml.ui.internal.editor.XMLEditorPluginImages;
  +import org.jboss.ide.eclipse.as.ui.mbeans.Activator;
   import org.jboss.ide.eclipse.as.ui.mbeans.Messages;
  +import org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals.IServiceXMLQuickFixProposalProvider;
   import org.jboss.ide.eclipse.as.ui.util.ServiceXMLEditorUtil;
   import org.w3c.dom.NamedNodeMap;
   import org.w3c.dom.Node;
   import org.w3c.dom.NodeList;
   
   public class ServiceXMLCorrectionAssistantProvider extends CorrectionAssistantProviderXML {
  +	public static IServiceXMLQuickFixProposalProvider[] providers;
  +	
  +	public static IServiceXMLQuickFixProposalProvider[] getProviders() {
  +		if( providers == null ) {
  +			ArrayList list = new ArrayList();
  +			IExtensionRegistry registry = Platform.getExtensionRegistry();
  +			IConfigurationElement[] cf = registry.getConfigurationElementsFor(Activator.PLUGIN_ID, "ServiceXMLQuickFixProvider");
  +			for( int i = 0; i < cf.length; i++ ) {
  +				try {
  +					list.add((IServiceXMLQuickFixProposalProvider)cf[i].createExecutableExtension("class"));
  +				} catch( CoreException ce ) {
  +					ce.printStackTrace();
  +				}
  +			}
  +			providers = (IServiceXMLQuickFixProposalProvider[])
  +				list.toArray(new IServiceXMLQuickFixProposalProvider[list.size()]);
  +		}
  +		return providers;
  +	}
   
   	public ServiceXMLCorrectionAssistantProvider() {
   		super();
  @@ -161,10 +185,21 @@
   
   			IDOMNode node = (IDOMNode) ContentAssistUtils.getNodeAt(viewer, offset);
   			addMissingAttributesProposal(node, props);
  -			
  +			addXPathProposals(viewer, offset, props);
   			return (ICompletionProposal[]) props.toArray(new ICompletionProposal[props.size()]);
   		}
   		
  +		protected void addXPathProposals(StructuredTextViewer viewer, int offset, ArrayList proposals) {
  +			IServiceXMLQuickFixProposalProvider[] providers = getProviders();
  +			ICompletionProposal[] props;
  +			for( int i = 0; i < providers.length; i++ ) {
  +				props = providers[i].getProposals(viewer, offset);
  +				if( props != null )
  +					proposals.addAll(Arrays.asList(props));
  +			}
  +		}
  +		
  +		
   		protected void addMissingAttributesProposal(IDOMNode node, ArrayList proposals) {
   			String[] missing = mbeanGetMissingAttributes(node);
   			if( missing.length == 0 ) return;
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:47:38 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:38 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema ...
Message-ID: <E1GrHuk-0003Eh-PK@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:38

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema 
                        ServiceXMLQuickFixProvider.exsd
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.1      date: 2006/12/04 17:47:38;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema/ServiceXMLQuickFixProvider.exsd
  
  Index: ServiceXMLQuickFixProvider.exsd
  ===================================================================
  <?xml version='1.0' encoding='UTF-8'?>
  <!-- Schema file written by PDE -->
  <schema targetNamespace="org.jboss.ide.eclipse.as.ui.mbeans">
  <annotation>
        <appInfo>
           <meta.schema plugin="org.jboss.ide.eclipse.as.ui.mbeans" id="ServiceXMLQuickFixProvider" name="org.jboss.ide.eclipse.as.ui.mbeans.serviceXMLQuickFixProvider"/>
        </appInfo>
        <documentation>
           [Enter description of this extension point.]
        </documentation>
     </annotation>
  
     <element name="extension">
        <complexType>
        	<sequence>
        	  <element ref="QuickFixProvider" minOccurs="0" maxOccurs="unbounded"/>
        	</sequence>
           <attribute name="point" type="string" use="required">
              <annotation>
                 <documentation>
                    
                 </documentation>
              </annotation>
           </attribute>
           <attribute name="id" type="string">
              <annotation>
                 <documentation>
                    
                 </documentation>
              </annotation>
           </attribute>
           <attribute name="name" type="string">
              <annotation>
                 <documentation>
                    
                 </documentation>
                 <appInfo>
                    <meta.attribute translatable="true"/>
                 </appInfo>
              </annotation>
           </attribute>
        </complexType>
     </element>
  
     <element name="QuickFixProvider">
        <complexType>
           <attribute name="class" type="string" use="required">
              <annotation>
                 <documentation>
                    
                 </documentation>
                 <appInfo>
                    <meta.attribute kind="java" basedOn="org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals.IServiceXMLQuickFixProposalProvider"/>
                 </appInfo>
              </annotation>
           </attribute>
        </complexType>
     </element>
  
     <annotation>
        <appInfo>
           <meta.section type="since"/>
        </appInfo>
        <documentation>
           [Enter the first release in which this extension point appears.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="examples"/>
        </appInfo>
        <documentation>
           [Enter extension point usage example here.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="apiInfo"/>
        </appInfo>
        <documentation>
           [Enter API information here.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="implementation"/>
        </appInfo>
        <documentation>
           [Enter information about supplied implementation of this extension point.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="copyright"/>
        </appInfo>
        <documentation>
           
        </documentation>
     </annotation>
  
  </schema>
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:47:38 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:38 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals
	...
Message-ID: <E1GrHuk-0003Eo-TU@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:38

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals 
                        IServiceXMLQuickFixProposalProvider.java
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.1      date: 2006/12/04 17:47:38;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals/IServiceXMLQuickFixProposalProvider.java
  
  Index: IServiceXMLQuickFixProposalProvider.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.ui.mbeans.editors.proposals;
  
  import org.eclipse.jface.text.ITextViewer;
  import org.eclipse.jface.text.contentassist.ICompletionProposal;
  import org.eclipse.wst.xml.core.internal.provisional.document.IDOMNode;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public interface IServiceXMLQuickFixProposalProvider {
  	public ICompletionProposal[] getProposals(ITextViewer viewer, int offset);
  }
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:47:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:39 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/META-INF ...
Message-ID: <E1GrHul-0003Ev-2L@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:39

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/META-INF 
                        MANIFEST.MF
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.2       +1 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/META-INF/MANIFEST.MF,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MANIFEST.MF	16 Nov 2006 22:45:30 -0000	1.1
  +++ MANIFEST.MF	4 Dec 2006 17:47:39 -0000	1.2
  @@ -22,3 +22,4 @@
    org.eclipse.ui.ide,
    org.eclipse.core.filesystem
   Eclipse-LazyStart: true
  +Export-Package: org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals
  
  
  


From rawblem at gmail.com  Mon Dec  4 12:47:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 12:47:39 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans ...
Message-ID: <E1GrHul-0003F2-6k@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 12:47:39

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui.mbeans  plugin.xml
  Log:
  Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view
  
  Revision  Changes    Path
  1.2       +2 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/plugin.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- plugin.xml	16 Nov 2006 22:45:30 -0000	1.1
  +++ plugin.xml	4 Dec 2006 17:47:39 -0000	1.2
  @@ -1,6 +1,7 @@
   <?xml version="1.0" encoding="UTF-8"?>
   <?eclipse version="3.2"?>
   <plugin>
  +   <extension-point id="ServiceXMLQuickFixProvider" name="org.jboss.ide.eclipse.as.ui.mbeans.serviceXMLQuickFixProvider" schema="schema/ServiceXMLQuickFixProvider.exsd"/>
      <extension
            point="org.eclipse.core.runtime.contentTypes">
         <content-type
  @@ -39,7 +40,7 @@
      </extension>
      <extension point="org.eclipse.wst.sse.ui.adapterFactoryDescription">
   		<adapterFactoryDescription
  -				class="org.jboss.ide.eclipse.as.ui.editors.AdaptorFactoryProviderForServiceXML"/>
  +				class="org.jboss.ide.eclipse.as.ui.mbeans.editors.AdaptorFactoryProviderForServiceXML"/>
      </extension>
      <extension
            point="org.eclipse.ui.newWizards">
  
  
  


From emmanuel.bernard at jboss.com  Mon Dec  4 12:59:38 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 12:59:38 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT
	- New directory ...
Message-ID: <E1GrI6M-0003Oq-92@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 12:59:38

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT added to the repository


From emmanuel.bernard at jboss.com  Mon Dec  4 12:59:40 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 12:59:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT/lib -
	New directory ...
Message-ID: <E1GrI6O-0003Oz-UL@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 12:59:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT/lib added to the repository


From emmanuel.bernard at jboss.com  Mon Dec  4 12:59:47 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 12:59:47 -0500
Subject: [jboss-cvs]
	repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT -
	New directory ...
Message-ID: <E1GrI6V-0003PD-Ol@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 12:59:47

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT added to the repository


From emmanuel.bernard at jboss.com  Mon Dec  4 12:59:50 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 12:59:50 -0500
Subject: [jboss-cvs]
	repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT/lib
	- New directory ...
Message-ID: <E1GrI6Y-0003PM-A2@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 12:59:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT/lib added to the repository


From emmanuel.bernard at jboss.com  Mon Dec  4 13:00:19 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 13:00:19 -0500
Subject: [jboss-cvs]
	repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT ...
Message-ID: <E1GrI71-0003Qt-CV@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 13:00:19

  Added:       hibernate-entitymanager/3.2.1.SNAPSHOT  component-info.xml
  Log:
  SNAPSHOT
  
  Revision  Changes    Path
  1.1      date: 2006/12/04 18:00:19;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="hibernate-entitymanager-component-info">
     <component id="hibernate-entitymanager"
                version="3.2.1.SNAPSHOT"
                licenseType="lgpl"
                projectHome="http://entitymanager.hibernate.org/"
                description="Hibernate EntityManager for EJB3"
        >
        <artifact id="hibernate-entitymanager.jar"/>
        <artifact id="ejb3-persistence.jar"/>
        <import componentref="hibernate">
  	     <compatible version="3.2.0.GA"/>
           <compatible version="3.2.1.GA"/>
        </import>
        <import componentref="hibernate-annotations">
           <compatible version="3.2.1.SNAPSHOT"/>
        </import>
        <export>
           <include input="hibernate-entitymanager.jar"/>
           <include input="ejb3-persistence.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From emmanuel.bernard at jboss.com  Mon Dec  4 13:00:19 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 13:00:19 -0500
Subject: [jboss-cvs]
	repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT/lib ...
Message-ID: <E1GrI71-0003R1-FU@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 13:00:19

  Added:       hibernate-entitymanager/3.2.1.SNAPSHOT/lib  
                        ejb3-persistence.jar hibernate-entitymanager.jar
  Log:
  SNAPSHOT
  
  Revision  Changes    Path
  1.1      date: 2006/12/04 18:00:19;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT/lib/ejb3-persistence.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/04 18:00:19;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-entitymanager/3.2.1.SNAPSHOT/lib/hibernate-entitymanager.jar
  
  	<<Binary file>>
  
  


From emmanuel.bernard at jboss.com  Mon Dec  4 13:00:39 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 13:00:39 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT
	...
Message-ID: <E1GrI7L-0003Re-Gz@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 13:00:39

  Added:       hibernate-annotations/3.2.1.SNAPSHOT  component-info.xml
  Log:
  SNAPSHOT
  
  Revision  Changes    Path
  1.1      date: 2006/12/04 18:00:39;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="hibernate-annotations-component-info">
     <component id="hibernate-annotations"
                 licenseType="lgpl"
                 version="3.2.1.SNAPSHOT"
                 projectHome="http://annotations.hibernate.org"
        description="Annotations for Hibernate/EJB3"
      >
        <artifact id="hibernate-annotations.jar"/>
        <import componentref="hibernate">
           <compatible version="3.2.0.GA"/>
  		 <compatible version="3.2.1.GA"/>
        </import>
        <export>
           <include input="hibernate-annotations.jar"/>         
        </export>
        
     </component>
  
  </project>
  
  
  


From emmanuel.bernard at jboss.com  Mon Dec  4 13:00:39 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Mon, 04 Dec 2006 13:00:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT/lib ...
Message-ID: <E1GrI7L-0003Rk-Ju@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/04 13:00:39

  Added:       hibernate-annotations/3.2.1.SNAPSHOT/lib 
                        hibernate-annotations.jar
  Log:
  SNAPSHOT
  
  Revision  Changes    Path
  1.1      date: 2006/12/04 18:00:39;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-annotations/3.2.1.SNAPSHOT/lib/hibernate-annotations.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 13:08:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 13:08:17 -0500
Subject: [jboss-cvs] JBossAS SVN: r58839 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/security/authorization/delegates
Message-ID: <E1GrIEj-0003lL-2H@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-04 13:08:16 -0500 (Mon, 04 Dec 2006)
New Revision: 58839

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/security/authorization/delegates/WebJACCPolicyModuleDelegate.java
Log:
merge fro JEE_TCK branch -r 57088:HEAD

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/security/authorization/delegates/WebJACCPolicyModuleDelegate.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/security/authorization/delegates/WebJACCPolicyModuleDelegate.java	2006-12-04 14:40:50 UTC (rev 58838)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/security/authorization/delegates/WebJACCPolicyModuleDelegate.java	2006-12-04 18:08:16 UTC (rev 58839)
@@ -41,6 +41,7 @@
 import org.apache.catalina.connector.Response;
 import org.apache.catalina.deploy.SecurityConstraint;
 import org.jboss.logging.Logger;
+import org.jboss.security.AuthorizationManager;
 import org.jboss.security.authorization.AuthorizationContext;
 import org.jboss.security.authorization.PolicyRegistration;
 import org.jboss.security.authorization.Resource;
@@ -61,6 +62,7 @@
 public class WebJACCPolicyModuleDelegate extends AuthorizationModuleDelegate
 {   
    private Policy policy = Policy.getPolicy();
+   private AuthorizationManager authorizationManager;
 
    public WebJACCPolicyModuleDelegate()
    {  
@@ -80,6 +82,11 @@
 
       if(map.size() == 0)
          throw new IllegalStateException("Map from the Resource is size zero");
+      //Get the Authorization Manager
+      authorizationManager = (AuthorizationManager)map.get(ResourceKeys.AUTHORIZATION_MANAGER);
+      if(authorizationManager == null)
+         throw new IllegalStateException("Authorization Manager is null");
+      
       //Get the Catalina Request Object
       Request request = (Request)map.get(ResourceKeys.WEB_REQUEST);
       Response response = (Response)map.get(ResourceKeys.WEB_RESPONSE);
@@ -163,6 +170,7 @@
    {  
       // Get the caller principals, its null if there is no caller
       Principal[] principals = null;
+      /*
       if( caller != null )
       {
          if( trace )
@@ -170,7 +178,17 @@
          Set principalsSet = caller.getPrincipals();
          principals = new Principal[principalsSet.size()];
          principalsSet.toArray(principals);
+      }*/
+      
+      //Previously we relied on principals in the subject. Now we use
+      //the security context roles
+      if(authorizationManager != null)
+      { 
+         Set<Principal> roleset = authorizationManager.getUserRoles(requestPrincpal);
+         principals = new Principal[roleset.size()];
+         roleset.toArray(principals); 
       }
+      
       return checkSecurityAssociation(perm, principals);
    }
    
@@ -235,7 +253,7 @@
    }
 
    /**
-    * Perform hasRole check
+    * Perform hasRole check 
     * @param principal
     * @param role
     * @param roles



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 13:09:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 13:09:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r58840 -
	trunk/server/src/main/org/jboss/metadata
Message-ID: <E1GrIFt-0003le-4f@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-04 13:09:28 -0500 (Mon, 04 Dec 2006)
New Revision: 58840

Modified:
   trunk/server/src/main/org/jboss/metadata/WebSecurityMetaData.java
Log:
roles were hidden in AuthConstraint and never pulled into the global rolesSet

Modified: trunk/server/src/main/org/jboss/metadata/WebSecurityMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/WebSecurityMetaData.java	2006-12-04 18:08:16 UTC (rev 58839)
+++ trunk/server/src/main/org/jboss/metadata/WebSecurityMetaData.java	2006-12-04 18:09:28 UTC (rev 58840)
@@ -170,6 +170,8 @@
       this.authConstraint = authConstraint;
       if( authConstraint.getRoleNames().size() == 0 )
          setExcluded(true);
+      else
+         this.roles.addAll(authConstraint.getRoleNames());
    }
 
    /** The security-constraint/web-resource-collection child element container



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 13:09:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 13:09:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r58841 -
	trunk/server/src/main/org/jboss/web
Message-ID: <E1GrIG9-0003lx-HL@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-04 13:09:44 -0500 (Mon, 04 Dec 2006)
New Revision: 58841

Modified:
   trunk/server/src/main/org/jboss/web/WebPermissionMapping.java
Log:
merge fro JEE_TCK branch -r 57088:HEAD

Modified: trunk/server/src/main/org/jboss/web/WebPermissionMapping.java
===================================================================
--- trunk/server/src/main/org/jboss/web/WebPermissionMapping.java	2006-12-04 18:09:28 UTC (rev 58840)
+++ trunk/server/src/main/org/jboss/web/WebPermissionMapping.java	2006-12-04 18:09:44 UTC (rev 58841)
@@ -47,6 +47,7 @@
  * permission from a deployment's metadata.
  * 
  * @author Scott.Stark at jboss.org
+ * @author Anil.Saldhana at jboss.org
  * @version $Revision$
  */
 public class WebPermissionMapping
@@ -148,7 +149,8 @@
       Iterator iter = patternMap.values().iterator();
       while( iter.hasNext() )
       {
-         PatternInfo info = (PatternInfo) iter.next();
+         PatternInfo info = (PatternInfo) iter.next(); 
+         
          String qurl = info.getQualifiedPattern();
          if( info.isOverriden == true )
          {
@@ -166,6 +168,13 @@
                httpMethods, null);
             pc.addToExcludedPolicy(wrp);
             pc.addToExcludedPolicy(wudp);
+            
+            //!(excluded methods)  [JACC 1.1]
+            String excludedString = "!" + getCommaSeparatedString(httpMethods);
+            WebResourcePermission wrp1 = new WebResourcePermission(info.pattern, excludedString);
+            WebUserDataPermission wudp1 = new WebUserDataPermission(info.pattern,excludedString);
+            pc.addToUncheckedPolicy(wrp1);
+            pc.addToUncheckedPolicy(wudp1); 
          }
 
          // Create the role permissions
@@ -179,16 +188,20 @@
             methods.toArray(httpMethods);
             WebResourcePermission wrp = new WebResourcePermission(qurl, httpMethods);
             pc.addToRole(role, wrp);
+            
+            //JACC 1.1: create !(httpmethods) in unchecked perms
+            WebResourcePermission wrpUnchecked = new WebResourcePermission(info.pattern, 
+                          "!" + getCommaSeparatedString(httpMethods));
+            pc.addToUncheckedPolicy(wrpUnchecked);
          }
 
          // Create the unchecked permissions
-         String[] missingHttpMethods = info.getMissingMethods();
+         String[] missingHttpMethods = info.getMissingMethods(); 
          if( missingHttpMethods.length > 0 )
          {
             // Create the unchecked permissions WebResourcePermissions
             WebResourcePermission wrp = new WebResourcePermission(qurl, missingHttpMethods);
-            pc.addToUncheckedPolicy(wrp);
-
+            pc.addToUncheckedPolicy(wrp);  
          }
 
          // Create the unchecked permissions WebUserDataPermissions
@@ -202,6 +215,21 @@
             methods.toArray(httpMethods);
             WebUserDataPermission wudp = new WebUserDataPermission(qurl, httpMethods, transport);
             pc.addToUncheckedPolicy(wudp);
+            
+            //If the transport is "NONE", then add an exlusive WebUserDataPermission
+            //with the url pattern and null
+            if("NONE".equals(transport))
+            {
+               WebUserDataPermission wudp1 = new WebUserDataPermission(info.pattern, null);
+               pc.addToUncheckedPolicy(wudp1);
+            } 
+            else
+            {
+               //JACC 1.1: Transport is CONFIDENTIAL/INTEGRAL, add a !(http methods)
+               WebUserDataPermission wudpNonNull = new WebUserDataPermission(info.pattern, 
+                     "!" + getCommaSeparatedString(httpMethods));
+               pc.addToUncheckedPolicy(wudpNonNull);
+            }
          }
       }
 
@@ -209,14 +237,15 @@
       with all the cross product of servlets and security-role elements that
       are not referenced via a security-role-ref as described in JACC section
       3.1.3.2
-      */
-      Set unreferencedRoles = metaData.getSecurityRoleNames();
+      */ 
       Map servletRoleRefs = metaData.getSecurityRoleRefs();
       Iterator roleRefsIter = servletRoleRefs.keySet().iterator();
       while( roleRefsIter.hasNext() )
       {
          String servletName = (String) roleRefsIter.next();
          ArrayList roleRefs = (ArrayList) servletRoleRefs.get(servletName);
+         //Perform the unreferenced roles processing for every servlet name
+         Set unreferencedRoles = metaData.getSecurityRoleNames();
          for(int n = 0; n < roleRefs.size(); n ++)
          {
             SecurityRoleRefMetaData roleRef = (SecurityRoleRefMetaData) roleRefs.get(n);
@@ -232,7 +261,33 @@
             // Remove the role from the unreferencedRoles
             unreferencedRoles.remove(roleName);
          }
+         
+         //Spec 3.1.3.2: For each servlet element in the deployment descriptor 
+         //a WebRoleRefPermission must be added to each security-role of the 
+         //application whose name does not appear as the rolename 
+         //in a security-role-ref within the servlet element.  
+         Iterator unref = unreferencedRoles.iterator();
+         while(unref.hasNext())
+         {
+            String unrefRole = (String)unref.next();
+            WebRoleRefPermission unrefP = new WebRoleRefPermission(servletName,unrefRole);
+            pc.addToRole(unrefRole, unrefP);
+         }
       }
+
+      Set unreferencedRoles = metaData.getSecurityRoleNames();
+      //JACC 1.1:Spec 3.1.3.2: For each security-role defined in the deployment descriptor, an
+      //additional WebRoleRefPermission must be added to the corresponding role by
+      //calling the addToRole method on the PolicyConfiguration object. The
+      //name of all such permissions must be the empty string, and the actions of each
+      //such permission must be the role-name of the corresponding role.
+      Iterator unreferencedRolesIter = unreferencedRoles.iterator();
+      while(unreferencedRolesIter.hasNext())
+      {
+        String unreferencedRole = (String)unreferencedRolesIter.next();
+        WebRoleRefPermission wrrep = new WebRoleRefPermission("", unreferencedRole);
+        pc.addToRole(unreferencedRole, wrrep); 
+      }
       
       // Now build the cross product of the unreferencedRoles and servlets
       Set servletNames = metaData.getServletNames();
@@ -260,6 +315,20 @@
          pc.addToRole(role, wrrp);  
       } 
    }
+   
+   static String getCommaSeparatedString(String[] str)
+   {
+      int len = str.length; 
+      Arrays.sort(str);
+      
+      StringBuilder buf = new StringBuilder();
+      for(int i = 0; i < len ; i++)
+      {
+         if(i > 0) buf.append(",");
+         buf.append(str[i]);
+      }
+      return buf.toString();
+   }
 
    /**
     * Determine the url-pattern type
@@ -591,7 +660,7 @@
             httpMethods = WebSecurityMetaData.getMissingHttpMethods(allMethods);
          }
          return httpMethods;
-      }
+      } 
 
       /**
        * Add the qualifying pattern. If info is a prefix pattern that matches
@@ -672,7 +741,7 @@
             isExtensionFor = pattern.regionMatches(1, other.pattern, offset, length);
          }
          return isExtensionFor;
-      }
+      } 
 
       public String toString()
       {



From rawblem at gmail.com  Mon Dec  4 13:13:08 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 04 Dec 2006 13:13:08 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF
	...
Message-ID: <E1GrIJQ-0003rT-DQ@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/04 13:13:08

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/META-INF  MANIFEST.MF
  Log:
  forgot this
  
  Revision  Changes    Path
  1.11      +2 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- MANIFEST.MF	10 Nov 2006 00:30:22 -0000	1.10
  +++ MANIFEST.MF	4 Dec 2006 18:13:08 -0000	1.11
  @@ -52,7 +52,8 @@
    org.eclipse.jst.ws.axis.creation.ui,
    org.eclipse.wst.ws,
    org.eclipse.wst.ws.ui,
  - org.jboss.ide.eclipse.firstrun
  + org.jboss.ide.eclipse.firstrun,
  + org.jboss.ide.eclipse.as.ui.mbeans
   Eclipse-LazyStart: true
   Export-Package: org.jboss.ide.eclipse.as.ui,
    org.jboss.ide.eclipse.as.ui.wizards
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 13:13:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 13:13:10 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1703 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster
Message-ID: <E1GrIJS-0003rc-Ra@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-04 13:13:09 -0500 (Mon, 04 Dec 2006)
New Revision: 1703

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
fixed variable name mixup

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 10:36:59 UTC (rev 1702)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 18:13:09 UTC (rev 1703)
@@ -701,7 +701,7 @@
             replicatedData.put(key, m);
          }
          
-         m.put(new Integer(nodeId), replicant); 
+         m.put(new Integer(originatorNodeID), replicant);
          
          notifyListeners(key, m);
       }
@@ -727,7 +727,7 @@
             return false;
          }
          
-         Object obj = m.remove(new Integer(nodeId));
+         Object obj = m.remove(new Integer(originatorNodeID));
          
          if (obj == null)
          {



From gutoferozuni at libra.livedoor.com  Sun Dec  3 21:58:40 2006
From: gutoferozuni at libra.livedoor.com (=?iso-2022-jp?B?GyRCQFBETSEhPz9NfTtSGyhC?=)
Date: Mon, 04 Dec 2006 11:58:40 +0900
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCMyRIfiQ1JHMkKyRpJE5FQThAJEcbKEI=?=
	=?iso-2022-jp?b?GyRCJDkhIxsoQg==?=
Message-ID: <200612042001.kB4K1TUk030944@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061204/e8afbb20/attachment.html 

From brian.stansberry at jboss.com  Mon Dec  4 17:17:25 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Mon, 04 Dec 2006 17:17:25 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1GrM7p-00087x-Ex@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/04 17:17:25

  Added:       tests/functional/org/jboss/cache/marshall    Tag:
                        Branch_JBossCache_1_4_0 FooClassLoader.java
                        Foo.notjava Foo.clazz
  Log:
  [JBCACHE-876] Add tests that custom classes in Fqn's work properly
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +39 -0     JBossCache/tests/functional/org/jboss/cache/marshall/Attic/FooClassLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FooClassLoader.java
  ===================================================================
  RCS file: FooClassLoader.java
  diff -N FooClassLoader.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ FooClassLoader.java	4 Dec 2006 22:17:25 -0000	1.1.2.1
  @@ -0,0 +1,39 @@
  +package org.jboss.cache.marshall;
  +
  +import java.io.ByteArrayOutputStream;
  +import java.io.IOException;
  +import java.io.InputStream;
  +
  +public class FooClassLoader extends ClassLoader
  +{
  +   private Class foo;
  +   public FooClassLoader(ClassLoader parent)
  +   {
  +      super(parent);
  +   }
  +   
  +   public Class loadFoo() throws ClassNotFoundException
  +   {
  +      if (foo == null)
  +      {
  +         try
  +         {
  +            InputStream is = getResourceAsStream("org/jboss/cache/marshall/Foo.clazz");
  +            byte[] bytes = new byte[1024];                
  +            ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
  +            int read;
  +            while ((read = is.read(bytes)) > -1) {
  +                baos.write(bytes, 0, read);
  +            }
  +            bytes = baos.toByteArray();
  +            foo = this.defineClass("org.jboss.cache.marshall.Foo", bytes, 0, bytes.length);
  +         }
  +         catch (IOException e)
  +         {
  +            throw new ClassNotFoundException("cannot read org/jboss/cache/marshall/Foo.clazz", e);
  +         }
  +      }
  +      return foo;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +37 -0     JBossCache/tests/functional/org/jboss/cache/marshall/Attic/Foo.notjava
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Foo.notjava
  ===================================================================
  RCS file: Foo.notjava
  diff -N Foo.notjava
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ Foo.notjava	4 Dec 2006 22:17:25 -0000	1.1.2.1
  @@ -0,0 +1,37 @@
  +package org.jboss.cache.marshall;
  +
  +import java.io.Serializable;
  +import java.security.SecureRandom;
  +import java.util.Random;
  +
  +/**
  + * This is the java code used to create the Foo.clazz file. File deliberately
  + * doesn't end in .java, as we don't want a Foo.class on the classpath,
  + * only the Foo.clazz file that FooClassLoader can load.
  + * 
  + * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  + * @version $Revision: 1.1.2.1 $
  + */
  +public class Foo implements Serializable
  +{
  +   /** The serialVersionUID */
  +   private static final long serialVersionUID = 1L;
  +
  +   public boolean equals(Object obj)
  +   {      
  +      return obj instanceof Foo;
  +   }
  +
  +   public int hashCode()
  +   {
  +      return 1;
  +   }   
  +
  +   public String toString()
  +   {
  +      Random random = new SecureRandom();
  +      StringBuffer sb=new StringBuffer("org.jboss.cache.marshall.Foo[random=");
  +      sb.append(random.nextInt()).append("]");
  +      return sb.toString();
  +   }
  +}
  
  
  
  1.1.2.1   +10 -0     JBossCache/tests/functional/org/jboss/cache/marshall/Attic/Foo.clazz
  
  	<<Binary file>>
  
  


From brian.stansberry at jboss.com  Mon Dec  4 17:18:54 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Mon, 04 Dec 2006 17:18:54 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1GrM9G-0008AV-S3@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/04 17:18:54

  Modified:    tests/functional/org/jboss/cache/marshall   Tag:
                        Branch_JBossCache_1_4_0 SyncReplTest.java
                        AsyncReplTest.java
  Log:
  [JBCACHE-876] Add tests that custom classes in Fqn's work properly
  Be more specific about the usage of classloader in testPuts()
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.5.2.1   +58 -8     JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java,v
  retrieving revision 1.5
  retrieving revision 1.5.2.1
  diff -u -b -r1.5 -r1.5.2.1
  --- SyncReplTest.java	5 May 2006 12:06:58 -0000	1.5
  +++ SyncReplTest.java	4 Dec 2006 22:18:54 -0000	1.5.2.1
  @@ -12,6 +12,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.PropertyConfigurator;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
  @@ -27,7 +29,7 @@
    * Test case for marshalling using Sync mode.
    * @author Ben Wang
    *
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.5.2.1 $
    */
   public class SyncReplTest extends TestCase {
      TreeCache cache1, cache2;
  @@ -65,7 +67,7 @@
         config.configure(tree, "META-INF/replSync-service.xml"); // read in generic replAsync xml
         tree.setClusterName(name);
         // Use marshaller
  -      tree.setUseMarshalling(true);
  +      tree.setUseRegionBasedMarshalling(true);
         tree.createService();
         tree.startService();
         return tree;
  @@ -207,17 +209,33 @@
      {
         ClassLoader cl = getClassLoader();
         cache1.registerClassLoader("/aop", cl);
  +      // Create an empty Person loaded by this classloader
  +      Object scopedBen1 = getPersonFromClassloader(cl);
  +      
         cl = getClassLoader();
         cache2.registerClassLoader("/aop", cl);
  +      // Create another empty Person loaded by this classloader
  +      Object scopedBen2 = getPersonFromClassloader(cl);
   
         cache1.put("/aop/1", "person", ben_);
  -      cache1.put("/aop/1", "person", ben_);
  +      cache1.put("/aop/2", "person", scopedBen1);
   
         Object ben2 = null;
  +      try
  +      {
         // Can't cast it to Person. CCE will resutl.
         ben2 = cache2.get("/aop/1", "person");
         assertEquals(ben_.toString(), ben2.toString());
   
  +         ben2 = cache2.get("/aop/2", "person");
  +         assertFalse("cache2 deserialized with scoped classloader", ben2 instanceof Person);
  +         assertFalse("cache2 deserialized with cache2 classloader", scopedBen1.equals(ben2));
  +         assertEquals("scopedBen deserialized properly", scopedBen2, ben2);
  +      } catch (Exception ex)
  +      {
  +         fail("Test fails with exception " +ex);
  +      }
  +
      }
   
      public void testMethodCall() throws Exception
  @@ -326,6 +344,32 @@
         // Need to test out if app is not registered with beforehand??
      }
   
  +   public void testCustomFqn() throws Exception
  +   {
  +      FooClassLoader cl1 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache1.registerClassLoader("/aop", cl1);
  +      FooClassLoader cl2 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache2.registerClassLoader("/aop", cl2); 
  +      
  +      Class clazz = cl1.loadFoo();
  +      Object custom1 = clazz.newInstance();
  +
  +      clazz = cl2.loadFoo();
  +      Object custom2 = clazz.newInstance();
  +      
  +      Fqn base = Fqn.fromString("/aop");
  +      cache1.put(new Fqn(base, custom1), "key", "value");
  +
  +      try
  +      {
  +         Object val = cache2.get(new Fqn(base, custom2), "key");
  +         assertEquals("value", val);
  +      } catch (Exception ex)
  +      {
  +         fail("Test fails with exception " +ex);
  +      }      
  +   }
  +
      Transaction beginTransaction() throws SystemException, NotSupportedException {
         DummyTransactionManager mgr=DummyTransactionManager.getInstance();
         mgr.begin();
  @@ -341,6 +385,12 @@
         return new SelectedClassnameClassLoader(includesClasses, excludesClasses, cl);
      }
   
  +   protected Object getPersonFromClassloader(ClassLoader cl) throws Exception
  +   {
  +      Class clazz = cl.loadClass("org.jboss.cache.marshall.Person");
  +      return clazz.newInstance();
  +   }
  +
      void log(String msg) {
         System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
      }
  
  
  
  1.5.2.1   +50 -5     JBossCache/tests/functional/org/jboss/cache/marshall/AsyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/AsyncReplTest.java,v
  retrieving revision 1.5
  retrieving revision 1.5.2.1
  diff -u -b -r1.5 -r1.5.2.1
  --- AsyncReplTest.java	8 Jun 2006 00:41:14 -0000	1.5
  +++ AsyncReplTest.java	4 Dec 2006 22:18:54 -0000	1.5.2.1
  @@ -12,6 +12,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.PropertyConfigurator;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
  @@ -26,7 +28,7 @@
   /**
    * Test marshalling for async mode.
    * @author Ben Wang
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.5.2.1 $
    */
   public class AsyncReplTest extends TestCase {
      TreeCache cache1, cache2;
  @@ -65,7 +67,7 @@
         config.configure(tree, "META-INF/replAsync-service.xml"); // read in generic replAsync xml
         tree.setClusterName(name);
         // Use marshaller
  -      tree.setUseMarshalling(true);
  +      tree.setUseRegionBasedMarshalling(true);
         tree.createService();
         tree.startService();
         return tree;
  @@ -150,11 +152,16 @@
      {
         ClassLoader cl = getClassLoader();
         cache1.registerClassLoader("/aop", cl);
  +      // Create an empty Person loaded by this classloader
  +      Object scopedBen1 = getPersonFromClassloader(cl);
  +      
         cl = getClassLoader();
         cache2.registerClassLoader("/aop", cl);
  +      // Create another empty Person loaded by this classloader
  +      Object scopedBen2 = getPersonFromClassloader(cl);
   
         cache1.put("/aop/1", "person", ben_);
  -      cache1.put("/aop/1", "person", ben_);
  +      cache1.put("/aop/2", "person", scopedBen1);
         TestingUtil.sleepThread(1000);
   
         Object ben2 = null;
  @@ -163,6 +170,11 @@
            // Can't cast it to Person. CCE will resutl.
            ben2 = cache2.get("/aop/1", "person");
            assertEquals(ben_.toString(), ben2.toString());
  +         
  +         ben2 = cache2.get("/aop/2", "person");
  +         assertFalse("cache2 deserialized with scoped classloader", ben2 instanceof Person);
  +         assertFalse("cache2 deserialized with cache2 classloader", scopedBen1.equals(ben2));
  +         assertEquals("scopedBen deserialized properly", scopedBen2, ben2);
         } catch (Exception ex)
         {
            fail("Test fails with exception " +ex);
  @@ -242,6 +254,33 @@
         // Need to test out if app is not registered with beforehand??
      }
   
  +   public void testCustomFqn() throws Exception
  +   {
  +      FooClassLoader cl1 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache1.registerClassLoader("/aop", cl1);
  +      FooClassLoader cl2 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache2.registerClassLoader("/aop", cl2); 
  +      
  +      Class clazz = cl1.loadFoo();
  +      Object custom1 = clazz.newInstance();
  +
  +      clazz = cl2.loadFoo();
  +      Object custom2 = clazz.newInstance();
  +      
  +      Fqn base = Fqn.fromString("/aop");
  +      cache1.put(new Fqn(base, custom1), "key", "value");
  +      TestingUtil.sleepThread(1000);
  +
  +      try
  +      {
  +         Object val = cache2.get(new Fqn(base, custom2), "key");
  +         assertEquals("value", val);
  +      } catch (Exception ex)
  +      {
  +         fail("Test fails with exception " +ex);
  +      }      
  +   }
  +
      Transaction beginTransaction() throws SystemException, NotSupportedException {
         DummyTransactionManager mgr=DummyTransactionManager.getInstance();
         mgr.begin();
  @@ -257,6 +296,12 @@
         return new SelectedClassnameClassLoader(includesClasses, excludesClasses, cl);
      }
   
  +   protected Object getPersonFromClassloader(ClassLoader cl) throws Exception
  +   {
  +      Class clazz = cl.loadClass("org.jboss.cache.marshall.Person");
  +      return clazz.newInstance();
  +   }
  +
      void log(String msg) {
         System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
      }
  
  
  


From mculpepper at jboss.com  Mon Dec  4 17:21:28 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Mon, 04 Dec 2006 17:21:28 -0500
Subject: [jboss-cvs]
	jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test
	...
Message-ID: <E1GrMBk-0008DG-PH@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/04 17:21:28

  Modified:    core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test   
                        NewProjectTest.java AllTests.java
                        PackagesEARTest.java
  Log:
  moved the testJARDefaultConfig unit test to the PackagesEARTest where there are some actual java files that are compiled into classes so we can test the jar package type
  
  Revision  Changes    Path
  1.2       +7 -0      jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/NewProjectTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewProjectTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/NewProjectTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- NewProjectTest.java	6 Nov 2006 21:38:13 -0000	1.1
  +++ NewProjectTest.java	4 Dec 2006 22:21:28 -0000	1.2
  @@ -10,15 +10,21 @@
   
   import org.eclipse.core.resources.IFile;
   import org.eclipse.core.resources.IResource;
  +import org.eclipse.core.resources.IncrementalProjectBuilder;
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.jdt.core.IJavaProject;
   import org.jboss.ide.eclipse.core.test.util.JavaProjectHelper;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  +import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  +import org.jboss.ide.eclipse.packages.core.model.internal.PackageBuildDelegate;
   import org.jboss.ide.eclipse.packages.core.model.internal.PackagesModel;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XMLBinding;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackage;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackages;
  +import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  +import org.jboss.ide.eclipse.packages.core.model.types.JARPackageType;
   
   public class NewProjectTest extends TestCase {
   
  @@ -93,4 +99,5 @@
   		IPackage pkg = (IPackage) packages.get(0);
   		assertEquals(pkg.getName(), "test.jar");
   	}
  +
   }
  
  
  
  1.2       +1 -1      jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/AllTests.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AllTests.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/AllTests.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- AllTests.java	6 Nov 2006 21:38:13 -0000	1.1
  +++ AllTests.java	4 Dec 2006 22:21:28 -0000	1.2
  @@ -13,10 +13,10 @@
   		suite.addTest(new PackagesEARTest("testSave"));
   		suite.addTest(new PackagesEARTest("testWorkingCopies"));
   		suite.addTest(new PackagesEARTest("testBuild"));
  +		suite.addTest(new PackagesEARTest("testJARDefaultConfig"));
   		
   		suite.addTest(new NewProjectTest("testXbConsistency"));
   		suite.addTest(new NewProjectTest("testEclipseModelConsistency"));
  -		
   		return suite;
   	}
   }
  
  
  
  1.3       +60 -1     jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/PackagesEARTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesEARTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/PackagesEARTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackagesEARTest.java	8 Nov 2006 19:54:42 -0000	1.2
  +++ PackagesEARTest.java	4 Dec 2006 22:21:28 -0000	1.3
  @@ -31,6 +31,8 @@
   
   import org.eclipse.core.resources.IFile;
   import org.eclipse.core.resources.IResource;
  +import org.eclipse.core.resources.IncrementalProjectBuilder;
  +import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.jdt.core.IJavaProject;
   import org.jboss.ide.eclipse.core.test.util.JavaProjectHelper;
  @@ -38,7 +40,6 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFolderWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
   import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  @@ -48,6 +49,8 @@
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFolder;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackage;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackages;
  +import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  +import org.jboss.ide.eclipse.packages.core.model.types.JARPackageType;
   
   public class PackagesEARTest extends TestCase {
   
  @@ -122,6 +125,7 @@
   		assertNull(ejbJar.getRef(), null);
   		assertNull(ejbJar.getToDir());
   		assertEquals(metaInfFiles.getFile(), "descriptors/application.xml");
  +		assertTrue(metaInfFiles.isInWorkspace());
   		
   		assertEquals(ejbJar.getFileSets().size(), 1);
   		assertEquals(ejbJar.getFolders().size(), 1);
  @@ -328,5 +332,60 @@
   		IFile packageFile = pkg.getPackageFile();
   		
   		assertTrue(packageFile.exists());
  +		assertEquals(packageFile.getName(), "MyApp2.ear");
  +		assertEquals(packageFile.getParent(), pkg.getDestinationContainer());
  +		
  +		de.schlichtherle.io.File packageZipFile = new de.schlichtherle.io.File(packageFile.getRawLocation().toString());
  +		assertTrue(packageZipFile.exists());
  +		
  +		File[] children = packageZipFile.listFiles();
  +		assertEquals(children.length, 2);
  +		
  +		File packagesFolder = children[0];
  +		File metaInfFolder = children[1];
  +		
  +		assertEquals(metaInfFolder.getName(), "META-INF");
  +		assertEquals(packagesFolder.getName(), "packages");
  +		
  +		children = metaInfFolder.listFiles();
  +		assertEquals(children.length, 1);
  +		
  +		File applicationXml = children[0];
  +		assertEquals(applicationXml.getName(), "application.xml");
  +		
  +		children = packagesFolder.listFiles();
  +		assertEquals(children.length, 2);
  +		
  +	}
  +	
  +	public void testJARDefaultConfig ()
  +	{
  +		NullProgressMonitor nullMonitor = new NullProgressMonitor();
  +		IPackageType jarPackageType = PackagesCore.getPackageType(JARPackageType.TYPE_ID);
  +		
  +		assertTrue(jarPackageType instanceof JARPackageType);
  +		
  +		IPackage jar = jarPackageType.createDefaultConfiguration(testPackagesProject.getProject(), nullMonitor);
  +		
  +		assertEquals(jar.getName(), "testPackagesProject.jar");
  +		assertEquals(jar.getPackageType(), jarPackageType);
  +		IPackageFileSet filesets[] = jar.getFileSets();
  +		
  +		assertEquals(filesets.length, 1);
  +		IPackageFileSet classes = filesets[0];
  +		
  +		assertEquals(classes.getIncludesPattern(), "**/*");
  +		
  +//		try {
  +//			testPackagesProject.getProject().build(IncrementalProjectBuilder.FULL_BUILD, nullMonitor);
  +//		} catch (CoreException e) {
  +//			fail(e.getMessage());
  +//		}
  +		
  +		PackagesCore.buildPackage(jar, nullMonitor);
  +		
  +		IFile jarFile = jar.getPackageFile();
  +		assertTrue(jarFile.exists());
  +		
   	}
   }
  
  
  


From mculpepper at jboss.com  Mon Dec  4 17:23:08 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Mon, 04 Dec 2006 17:23:08 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model
	...
Message-ID: <E1GrMDM-0008Fu-Gi@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/04 17:23:08

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model 
                        PackagesCore.java
  Log:
  added a note about proper build order etc in buildProject method
  
  Revision  Changes    Path
  1.9       +3 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesCore.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- PackagesCore.java	28 Nov 2006 19:53:23 -0000	1.8
  +++ PackagesCore.java	4 Dec 2006 22:23:08 -0000	1.9
  @@ -34,6 +34,7 @@
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.core.runtime.Path;
  +import org.eclipse.core.runtime.Platform;
   import org.eclipse.core.runtime.QualifiedName;
   import org.jboss.ide.eclipse.packages.core.Trace;
   import org.jboss.ide.eclipse.packages.core.model.internal.PackageBuildDelegate;
  @@ -257,7 +258,8 @@
   	}
   	
   	/**
  -	 * Builds all of a project's packages
  +	 * Builds all of a project's packages. Note that this does not call any builders before or after the package builder (i.e. the JDT builder).
  +	 * If you are looking to run all the builders on a project use project.build()
   	 * @param project The project to build
   	 * @param buildType FULL_BUILD, INCREMENTAL_BUILD, CLEAN_BUILD, etc
   	 * @param monitor A progress monitor
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 17:37:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 17:37:53 -0500
Subject: [jboss-cvs] JBossBlog SVN: r36 - in trunk: .
	blog-core/src/java/org/jboss/blog/model
	blog-core/src/java/org/jboss/blog/service/store/hibernate
	blog-core/src/java/org/jboss/blog/service/store/model
	blog-core/src/java/org/jboss/blog/tools
	blog-core/src/java/org/jboss/blog/ui blog-core/src/web
	blog-core/src/web/WEB-INF blog-core/src/web/views
Message-ID: <E1GrMRd-0008Vs-Ju@committer01.frg.pub.inap.atl.jboss.com>

Author: adamw
Date: 2006-12-04 17:37:40 -0500 (Mon, 04 Dec 2006)
New Revision: 36

Added:
   trunk/blog-core/src/java/org/jboss/blog/model/BlogCommentDoesNotExistException.java
   trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java
Modified:
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/tools/UITools.java
   trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
   trunk/blog-core/src/web/WEB-INF/faces-config.xml
   trunk/blog-core/src/web/blog.css
   trunk/blog-core/src/web/views/post_view.xhtml
   trunk/jbossblog.iws
Log:
http://jira.jboss.com/jira/browse/JBBLOG-13

Added: trunk/blog-core/src/java/org/jboss/blog/model/BlogCommentDoesNotExistException.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogCommentDoesNotExistException.java	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogCommentDoesNotExistException.java	2006-12-04 22:37:40 UTC (rev 36)
@@ -0,0 +1,21 @@
+package org.jboss.blog.model;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class BlogCommentDoesNotExistException extends Exception {
+    public BlogCommentDoesNotExistException() {
+    }
+
+    public BlogCommentDoesNotExistException(String message) {
+        super(message);
+    }
+
+    public BlogCommentDoesNotExistException(String message, Throwable cause) {
+        super(message, cause);
+    }
+
+    public BlogCommentDoesNotExistException(Throwable cause) {
+        super(cause);
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-04 22:37:40 UTC (rev 36)
@@ -3,6 +3,8 @@
 import org.jboss.blog.service.store.model.ModifiableBlogPost;
 import org.jboss.blog.service.store.model.ModifiableBlogComment;
 import org.jboss.blog.model.AbstractBlogPost;
+import org.jboss.blog.model.BlogComment;
+import org.jboss.blog.model.BlogCommentDoesNotExistException;
 import org.jboss.blog.tools.BlogTools;
 
 import java.util.*;
@@ -150,9 +152,12 @@
         storeService.addComment(this, hcomment);
     }
 
-    public void removeComment(ModifiableBlogComment comment) throws IllegalArgumentException {
-        HibernateBlogStoreService storeService = getStoreService();
+    public ModifiableBlogComment getModifiableBlogComment(BlogComment comment)
+            throws BlogCommentDoesNotExistException {
+        if (!(comment instanceof HBlogComment)) {
+            throw new BlogCommentDoesNotExistException(comment.getTitle());
+        }
 
-        storeService.deleteComment(comment);
+        return (ModifiableBlogComment) comment;
     }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java	2006-12-04 22:37:40 UTC (rev 36)
@@ -1,6 +1,8 @@
 package org.jboss.blog.service.store.model;
 
 import org.jboss.blog.model.BlogPost;
+import org.jboss.blog.model.BlogComment;
+import org.jboss.blog.model.BlogCommentDoesNotExistException;
 
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
@@ -21,13 +23,13 @@
             throws IllegalArgumentException;
 
     /**
-     * Removes the given comment from this blog post. This method should be used
-     * instead of modifying the {@link ModifiableBlogPost#getComments()}
-     * list.
-     * @param comment Post to remove.
-     * @throws IllegalArgumentException If either comment is null, or
-     * it hasn't been obtained in a proper way.
+     * Given a blog comment, gets a modifiable version of the same blog
+     * comment.
+     * @param comment Comment for which to get a modifiable version.
+     * @return A modifiable version of the given blog comment.
+     * @throws BlogCommentDoesNotExistException If the blog comment is not
+     * modifiable.
      */
-    public void removeComment(ModifiableBlogComment comment)
-            throws IllegalArgumentException;
+    public ModifiableBlogComment getModifiableBlogComment(BlogComment comment)
+            throws BlogCommentDoesNotExistException;
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/tools/UITools.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/tools/UITools.java	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/java/org/jboss/blog/tools/UITools.java	2006-12-04 22:37:40 UTC (rev 36)
@@ -20,6 +20,8 @@
     public static final String POST_NEW     = "post_new";
     public static final String POST_DEL     = "post_del";
 
+    public static final String COMMENT_DEL  = "comment_del";
+
     public static final String ADMIN_PANEL  = "admin_panel";
     public static final String ID_EDIT      = "id_edit";
 
@@ -40,4 +42,8 @@
     public static void addMessagePostDoesntExist(String id) {
         addErrorMessage("The post you requested: " + id + " does not exist.");
     }
+
+    public static void addMessageCommentDoesntExist() {
+        addErrorMessage("The comment you requested does not exist.");
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-04 22:37:40 UTC (rev 36)
@@ -26,7 +26,6 @@
 
     // Faces-managed properties
     private UIData postsData;
-    private UIData commentsData;
     private State state;
 
     public UIData getPostsData() {
@@ -37,14 +36,6 @@
         this.postsData = postsData;
     }
 
-    public UIData getCommentsData() {
-        return commentsData;
-    }
-
-    public void setCommentsData(UIData commentsData) {
-        this.commentsData = commentsData;
-    }
-
     public State getState() {
         return state;
     }

Added: trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java	2006-12-04 22:37:40 UTC (rev 36)
@@ -0,0 +1,128 @@
+package org.jboss.blog.ui;
+
+import org.jboss.blog.tools.BlogTools;
+import org.jboss.blog.tools.UITools;
+import org.jboss.blog.service.store.model.ModifiableBlogModel;
+import org.jboss.blog.service.store.model.ModifiableBlogPost;
+import org.jboss.blog.service.store.model.ModifiableBlogComment;
+import org.jboss.blog.model.*;
+
+import javax.faces.component.UIData;
+import java.util.*;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class CommentEdit {
+    private BlogView blogView;
+    private UIData commentsData;
+
+    private String title;
+    private String author;
+    private String description;
+
+    public CommentEdit() {
+
+    }
+
+    public String getAuthor() {
+        return author;
+    }
+
+    public void setAuthor(String author) {
+        this.author = author;
+    }
+
+    public String getDescription() {
+        return description;
+    }
+
+    public void setDescription(String description) {
+        this.description = description;
+    }
+
+    public String getTitle() {
+        return title;
+    }
+
+    public void setTitle(String title) {
+        this.title = title;
+    }
+
+    public BlogView getBlogView() {
+        return blogView;
+    }
+
+    public void setBlogView(BlogView blogView) {
+        this.blogView = blogView;
+    }
+
+    public UIData getCommentsData() {
+        return commentsData;
+    }
+
+    public void setCommentsData(UIData commentsData) {
+        this.commentsData = commentsData;
+    }
+
+    // Actions
+
+    private ModifiableBlogPost getPost() throws BlogPostDoesNotExistException,
+            BlogModelDoesNotExistException {
+        ModifiableBlogModel model = BlogTools.getBlogService().getStoreService().getBlogModel(
+                blogView.getBlogName());
+        return model.getModifiableBlogPostByTitleAsId(
+                blogView.getSelectedPostTitleAsId());
+    }
+
+    public String saveNew() {
+        try {
+            ModifiableBlogComment comment;
+
+            comment = BlogTools.getBlogService().getStoreService().newBlogComment();
+
+            comment.setAuthor(author);
+
+            comment.setTitle(title);
+            comment.setDescription(description);
+            comment.setCreated(new Date());
+
+            ModifiableBlogPost post = getPost();
+
+            post.addComment(comment);
+
+            UITools.addInfoMessage("New comment saved.");
+        } catch (BlogModelDoesNotExistException e) {
+            UITools.addMessageBlogDoesntExist(blogView.getBlogName());
+        } catch (BlogPostDoesNotExistException e) {
+            UITools.addMessagePostDoesntExist(blogView.getSelectedPostTitleAsId());
+        }
+
+        return null;
+    }
+
+    public String delete() {
+        try {
+            ModifiableBlogPost post = getPost();
+            BlogComment notModifiableComment = (BlogComment) commentsData.getRowData();
+            ModifiableBlogComment comment = post.getModifiableBlogComment(notModifiableComment);
+
+            BlogTools.getBlogService().getStoreService().deleteComment(comment);
+
+            UITools.addInfoMessage("Comment deleted.");
+        } catch (BlogModelDoesNotExistException e) {
+            UITools.addMessageBlogDoesntExist(blogView.getBlogName());
+        } catch (BlogPostDoesNotExistException e) {
+            UITools.addMessagePostDoesntExist(blogView.getSelectedPostTitleAsId());
+        } catch (BlogCommentDoesNotExistException e) {
+            UITools.addMessageCommentDoesntExist();
+        }
+
+        return UITools.POST_VIEW;
+
+    }
+
+    public String back() {
+        return blogView.getReturnTo();
+    }
+}

Modified: trunk/blog-core/src/web/WEB-INF/faces-config.xml
===================================================================
--- trunk/blog-core/src/web/WEB-INF/faces-config.xml	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/web/WEB-INF/faces-config.xml	2006-12-04 22:37:40 UTC (rev 36)
@@ -66,6 +66,16 @@
     </managed-bean>
 
     <managed-bean>
+        <managed-bean-name>commentEdit</managed-bean-name>
+        <managed-bean-class>org.jboss.blog.ui.CommentEdit</managed-bean-class>
+        <managed-bean-scope>request</managed-bean-scope>
+        <managed-property>
+            <property-name>blogView</property-name>
+            <value>#{blogView}</value>
+        </managed-property>
+    </managed-bean>
+
+    <managed-bean>
         <managed-bean-name>state</managed-bean-name>
         <managed-bean-class>org.jboss.blog.ui.State</managed-bean-class>
         <managed-bean-scope>session</managed-bean-scope>

Modified: trunk/blog-core/src/web/blog.css
===================================================================
--- trunk/blog-core/src/web/blog.css	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/web/blog.css	2006-12-04 22:37:40 UTC (rev 36)
@@ -54,4 +54,12 @@
 
 .sidenote {
     font-size: 10px;
+}
+
+.empty {
+
+}
+
+.column-top {
+    vertical-align: text-top;
 }
\ No newline at end of file

Modified: trunk/blog-core/src/web/views/post_view.xhtml
===================================================================
--- trunk/blog-core/src/web/views/post_view.xhtml	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/blog-core/src/web/views/post_view.xhtml	2006-12-04 22:37:40 UTC (rev 36)
@@ -41,9 +41,11 @@
 
             <h3>Comments</h3>
 
+            <h:form>
             <h:dataTable value="#{blogView.selectedPost.comments}" var="comment"
-                         binding="#{blogView.commentsData}" styleClass="posts"
-                         rowClasses="posts-row,posts-row-alternate" >
+                         binding="#{commentEdit.commentsData}" styleClass="posts"
+                         rowClasses="posts-row,posts-row-alternate"
+                         columnClasses="empty,column-top">
                 <h:column>
                     <span class="post-title">#{comment.title}</span>
                     <span class="post-data">
@@ -68,6 +70,7 @@
                     </h:panelGroup>
                 </h:column>
             </h:dataTable>
+            </h:form>
         </blog:isAllowed>
         </h:panelGroup>
 
@@ -91,13 +94,18 @@
                                      maxlength="255" size="32" />
                     </h:panelGroup>
 
-                    <h:panelGroup>Description:</h:panelGroup>
+                    <h:panelGroup>Description: (*)</h:panelGroup>
                     <h:panelGroup>
-                        <h:inputTextarea value="#{commentEdit.description}" rows="10" cols="40" />
+                        <h:inputTextarea value="#{commentEdit.description}"
+                                         rows="10" cols="40" required="true" />
                     </h:panelGroup>
                 </h:panelGrid>
 
                 <h:commandLink value="Add" action="#{commentEdit.saveNew}" />
+
+                <p class="sidenote">
+                    Fields marked with (*) are required. <ui:insert name="sidenotes" />
+                </p>
             </h:form>
 
             <hr />

Modified: trunk/jbossblog.iws
===================================================================
--- trunk/jbossblog.iws	2006-12-03 00:10:53 UTC (rev 35)
+++ trunk/jbossblog.iws	2006-12-04 22:37:40 UTC (rev 36)
@@ -18,12 +18,14 @@
   <component name="ChangeListManager">
     <list default="true" name="Default" comment="">
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/blog.css" afterPath="$PROJECT_DIR$/blog-core/src/web/blog.css" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogCommentDoesNotExistException.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools/UITools.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools/UITools.java" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" />
     </list>
   </component>
   <component name="ChangeListSynchronizer" />
@@ -150,61 +152,96 @@
     <leaf>
       <file leaf-file-name="post_view.xhtml" pinned="false" current="true" current-in-tab="true">
         <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="47" column="52" selection-start="1877" selection-end="1877" vertical-scroll-proportion="0.23154363">
+              <folding />
+            </state>
+          </provider>
           <provider editor-type-id="HtmlPreview">
             <state />
           </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="blog.css" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/web/blog.css">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="39" column="18" selection-start="1540" selection-end="1540" vertical-scroll-proportion="-0.25838926">
+            <state line="63" column="29" selection-start="753" selection-end="753" vertical-scroll-proportion="1.1623794">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="AbstractBlogPost.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
+      <file leaf-file-name="CommentEdit.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
+            <state line="68" column="5" selection-start="1465" selection-end="1465" vertical-scroll-proportion="0.19292605">
+              <folding>
+                <element signature="imports" expanded="true" />
+              </folding>
+            </state>
+          </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="BlogView.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="36" column="5" selection-start="984" selection-end="984" vertical-scroll-proportion="-4.869775">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogPost.hbm.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
+      <file leaf-file-name="ModifiableBlogComment.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
+            <state line="7" column="71" selection-start="225" selection-end="225" vertical-scroll-proportion="0.1688103">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
+      <file leaf-file-name="faces-config.xml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml">
+          <provider editor-type-id="com.intellij.jsf.yfilesGraph.editor.FacesNavigationFileEditorProvider">
+            <state />
+          </provider>
           <provider selected="true" editor-type-id="text-editor">
-            <state line="14" column="15" selection-start="525" selection-end="525" vertical-scroll-proportion="0.3376206">
+            <state line="68" column="32" selection-start="2584" selection-end="2584" vertical-scroll-proportion="0.55421686">
               <folding />
             </state>
           </provider>
+          <provider editor-type-id="com.intellij.jsf.ui.FacesConfigEditorProvider">
+            <state />
+          </provider>
         </entry>
       </file>
-      <file leaf-file-name="HibernateBlogStoreService.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
+      <file leaf-file-name="AbstractBlogPost.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="316" column="30" selection-start="10929" selection-end="10929" vertical-scroll-proportion="0.49588138">
+            <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="PostEdit.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
+      <file leaf-file-name="HBlogPost.hbm.xml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="16" column="13" selection-start="520" selection-end="520" vertical-scroll-proportion="-4.822076">
+            <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
+      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="14" column="15" selection-start="525" selection-end="525" vertical-scroll-proportion="0.3376206">
+              <folding />
+            </state>
+          </provider>
+        </entry>
+      </file>
     </leaf>
   </component>
   <component name="FindManager">
@@ -608,6 +645,48 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -775,7 +854,7 @@
       <showLibraryContents />
       <hideEmptyPackages />
       <abbreviatePackageNames />
-      <showStructure PackagesPane="false" ProjectPane="false" Scope="false" Favorites="false" />
+      <showStructure Favorites="false" PackagesPane="false" Scope="false" ProjectPane="false" />
       <autoscrollToSource />
       <autoscrollFromSource />
       <sortByType />
@@ -812,16 +891,6 @@
   </component>
   <component name="RestoreUpdateTree" />
   <component name="RunManager">
-    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
-      <option name="MAIN_CLASS_NAME" />
-      <option name="VM_PARAMETERS" />
-      <option name="PROGRAM_PARAMETERS" />
-      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-      <option name="ENABLE_SWING_INSPECTOR" value="false" />
-      <module name="" />
-    </configuration>
     <configuration default="true" type="Applet" factoryName="Applet">
       <module name="" />
       <option name="MAIN_CLASS_NAME" />
@@ -834,6 +903,23 @@
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
       <option name="ALTERNATIVE_JRE_PATH" />
     </configuration>
+    <configuration default="true" type="Remote" factoryName="Remote">
+      <option name="USE_SOCKET_TRANSPORT" value="true" />
+      <option name="SERVER_MODE" value="false" />
+      <option name="SHMEM_ADDRESS" value="javadebug" />
+      <option name="HOST" value="localhost" />
+      <option name="PORT" value="5005" />
+    </configuration>
+    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
+      <option name="MAIN_CLASS_NAME" />
+      <option name="VM_PARAMETERS" />
+      <option name="PROGRAM_PARAMETERS" />
+      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
+      <option name="ALTERNATIVE_JRE_PATH" />
+      <option name="ENABLE_SWING_INSPECTOR" value="false" />
+      <module name="" />
+    </configuration>
     <configuration default="true" type="JUnit" factoryName="JUnit" enabled="false" merge="false">
       <module name="" />
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
@@ -853,13 +939,6 @@
         <option name="Make" value="true" />
       </method>
     </configuration>
-    <configuration default="true" type="Remote" factoryName="Remote">
-      <option name="USE_SOCKET_TRANSPORT" value="true" />
-      <option name="SERVER_MODE" value="false" />
-      <option name="SHMEM_ADDRESS" value="javadebug" />
-      <option name="HOST" value="localhost" />
-      <option name="PORT" value="5005" />
-    </configuration>
   </component>
   <component name="ScopeViewComponent">
     <subPane subId="Project">
@@ -938,7 +1017,7 @@
   </component>
   <component name="ToolWindowManager">
     <frame x="0" y="25" width="1690" height="1004" extended-state="6" />
-    <editor active="true" />
+    <editor active="false" />
     <layout>
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="13" />
@@ -947,7 +1026,7 @@
       <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26118946" order="0" />
       <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32839224" order="1" />
       <window_info id="Structure" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24367674" order="7" />
-      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
+      <window_info id="Messages" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.39977092" order="6" />
       <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="4" />
       <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="10" />
@@ -1056,125 +1135,130 @@
     <option name="myLastEditedConfigurable" value="Project Default" />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
+        <state line="91" column="40" selection-start="3490" selection-end="3490" vertical-scroll-proportion="0.48913044">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="-1.2224109">
+        <state line="22" column="44" selection-start="853" selection-end="853" vertical-scroll-proportion="0.37037036">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/view.xhtml">
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="142" column="62" selection-start="3504" selection-end="3504" vertical-scroll-proportion="0.2210145">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="24" column="27" selection-start="565" selection-end="565" vertical-scroll-proportion="0.5546624">
+        <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="12" column="61" selection-start="394" selection-end="394" vertical-scroll-proportion="0.2170418">
+        <state line="152" column="5" selection-start="3620" selection-end="3620" vertical-scroll-proportion="0.692029">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools/UITools.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="155" column="35" selection-start="3933" selection-end="3933" vertical-scroll-proportion="0.38906753">
+        <state line="46" column="50" selection-start="1718" selection-end="1718" vertical-scroll-proportion="0.7789855">
           <folding />
         </state>
       </provider>
     </entry>
     <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="38" column="0" selection-start="1018" selection-end="1018" vertical-scroll-proportion="0.51446944">
+        <state line="36" column="5" selection-start="984" selection-end="984" vertical-scroll-proportion="-4.869775">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml">
+      <provider editor-type-id="com.intellij.jsf.yfilesGraph.editor.FacesNavigationFileEditorProvider">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="91" column="49" selection-start="3926" selection-end="3926" vertical-scroll-proportion="-0.049423393">
+        <state line="68" column="32" selection-start="2584" selection-end="2584" vertical-scroll-proportion="0.55421686">
           <folding />
         </state>
       </provider>
-    </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/blog_view.xhtml">
-      <provider editor-type-id="HtmlPreview">
+      <provider editor-type-id="com.intellij.jsf.ui.FacesConfigEditorProvider">
         <state />
       </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="48" column="53" selection-start="2106" selection-end="2106" vertical-scroll-proportion="0.30981067">
+        <state line="68" column="5" selection-start="1465" selection-end="1465" vertical-scroll-proportion="0.19292605">
+          <folding>
+            <element signature="imports" expanded="true" />
+          </folding>
+        </state>
+      </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
+      <provider selected="true" editor-type-id="text-editor">
+        <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/blog.css">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_edit.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="56" column="1" selection-start="695" selection-end="695" vertical-scroll-proportion="0.8553055">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
-    </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml">
       <provider editor-type-id="HtmlPreview">
         <state />
       </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_new.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="57" column="39" selection-start="2581" selection-end="2581" vertical-scroll-proportion="0.42114094">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
-    </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_new.xhtml">
       <provider editor-type-id="HtmlPreview">
         <state />
       </provider>
+    </entry>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="18" column="79" selection-start="634" selection-end="693" vertical-scroll-proportion="0.45302013">
+        <state line="64" column="16" selection-start="2836" selection-end="2965" vertical-scroll-proportion="0.59731543">
           <folding />
         </state>
       </provider>
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/portlet.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/blog.css">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="15" column="66" selection-start="759" selection-end="759" vertical-scroll-proportion="0.37067544">
+        <state line="63" column="29" selection-start="753" selection-end="753" vertical-scroll-proportion="1.1623794">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
+        <state line="47" column="52" selection-start="1877" selection-end="1877" vertical-scroll-proportion="0.23154363">
           <folding />
         </state>
       </provider>
-    </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
       <provider editor-type-id="HtmlPreview">
         <state />
       </provider>
-      <provider selected="true" editor-type-id="text-editor">
-        <state line="39" column="18" selection-start="1540" selection-end="1540" vertical-scroll-proportion="-0.25838926">
-          <folding />
-        </state>
-      </provider>
     </entry>
   </component>
 </project>



From c45 at fullmailmarket.com  Mon Dec  4 18:45:09 2006
From: c45 at fullmailmarket.com (Fundación Instituto de Seguridad del Trabajo)
Date: Mon, 4 Dec 2006 20:45:09 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Curso_Eficiencia_Energ=E9tica?=
Message-ID: <200612042345.kB4NjDM2005352@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061204/efe8f736/attachment.html 

From msurtani at jboss.com  Mon Dec  4 19:01:51 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 19:01:51 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/lock  ...
Message-ID: <E1GrNkt-0001Nv-Rk@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 19:01:51

  Modified:    src/org/jboss/cache/lock  Tag: Branch_JBossCache_1_4_0
                        IdentityLock.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.12.2.1  +7 -3      JBossCache/src/org/jboss/cache/lock/IdentityLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdentityLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/IdentityLock.java,v
  retrieving revision 1.12
  retrieving revision 1.12.2.1
  diff -u -b -r1.12 -r1.12.2.1
  --- IdentityLock.java	1 Jun 2006 05:48:03 -0000	1.12
  +++ IdentityLock.java	5 Dec 2006 00:01:51 -0000	1.12.2.1
  @@ -12,7 +12,10 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   
  -import java.util.*;
  +import java.util.ArrayList;
  +import java.util.Collection;
  +import java.util.Iterator;
  +import java.util.Set;
   
   /**
    * Lock object which grants and releases locks, and associates locks with
  @@ -53,7 +56,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 11, 2003
    * @author Ben Wang July 2003
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.12.2.1 $
    */
   public class IdentityLock
   {
  @@ -94,7 +97,8 @@
            mustReacquireRead_ = false;
         } else {         
            IsolationLevel level = cache.getIsolationLevelClass();
  -         lock_ = LockStrategyFactory.getLockStrategy(level);
  +         // Repeatable Read *is* the default ...
  +         lock_ = LockStrategyFactory.getLockStrategy(level == null ? IsolationLevel.REPEATABLE_READ : level);
            mustReacquireRead_ = (level == IsolationLevel.READ_COMMITTED);
         }
         map_ = new LockMap();
  
  
  


From msurtani at jboss.com  Mon Dec  4 19:01:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 19:01:52 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache    ...
Message-ID: <E1GrNku-0001OC-76@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 19:01:52

  Modified:    src/org/jboss/cache    Tag: Branch_JBossCache_1_4_0
                        TransactionEntry.java TreeCache.java
                        TransactionTable.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.1   +33 -6     JBossCache/src/org/jboss/cache/TransactionEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionEntry.java,v
  retrieving revision 1.8
  retrieving revision 1.8.2.1
  diff -u -b -r1.8 -r1.8.2.1
  --- TransactionEntry.java	12 Jun 2006 20:24:32 -0000	1.8
  +++ TransactionEntry.java	5 Dec 2006 00:01:51 -0000	1.8.2.1
  @@ -7,15 +7,19 @@
   package org.jboss.cache;
   
   
  -import org.jboss.cache.lock.IdentityLock;
  -import org.jboss.cache.config.Option;
  -import org.jgroups.blocks.MethodCall;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.config.Option;
  +import org.jboss.cache.lock.IdentityLock;
  +import org.jgroups.blocks.MethodCall;
   
   import javax.transaction.Transaction;
  -import java.util.*;
  +import java.util.ArrayList;
  +import java.util.Collection;
  +import java.util.Iterator;
  +import java.util.LinkedList;
  +import java.util.List;
  +import java.util.ListIterator;
   
   /**
    * This is the value (key being the {@link GlobalTransaction}) in the transaction table
  @@ -31,7 +35,7 @@
    * </ul>
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.8 $
  + * @version $Revision: 1.8.2.1 $
    */
   public class TransactionEntry {
   
  @@ -69,6 +73,11 @@
      protected List dummyNodesCreatedByCacheLoader;
   
      /**
  +    * List<Fqn> of nodes that have been removed by the transaction
  +    */
  +    protected List removedNodes = new LinkedList();
  +
  +   /**
       * Constructs a new TransactionEntry.
       */
      public TransactionEntry() {
  @@ -109,6 +118,24 @@
      }
   
      /**
  +    * Adds the node that has been removed.
  +    *
  +    * @param fqn
  +    */
  +    public void addRemovedNode(Fqn fqn) {
  +       removedNodes.add(fqn);
  +    }
  +
  +    /**
  +     * Gets the list of removed nodes.
  +     */
  +    public List getRemovedNodes()
  +    {
  +       return new ArrayList(removedNodes);
  +    }
  +
  +
  +   /**
       * Returns the undo operations in use.
       * Note:  This list may be concurrently modified.
       */
  
  
  
  1.195.2.26 +125 -34   JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.25
  retrieving revision 1.195.2.26
  diff -u -b -r1.195.2.25 -r1.195.2.26
  --- TreeCache.java	4 Dec 2006 17:00:06 -0000	1.195.2.25
  +++ TreeCache.java	5 Dec 2006 00:01:51 -0000	1.195.2.26
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.25 2006/12/04 17:00:06 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.26 2006/12/05 00:01:51 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -108,6 +108,8 @@
      private static final String CREATE_MUX_CHANNEL = "createMultiplexerChannel";
      private static final String[] MUX_TYPES = {"java.lang.String", "java.lang.String"};
      private static final String JBOSS_SERVER_DOMAIN = "jboss";
  +
  +   private static final String REMOVAL_MARKER = "__JBOSS_MARKED_FOR_REMOVAL";
      /**
       * Default replication version, from {@link Version#getVersionShort}.
       */
  @@ -3566,7 +3568,7 @@
       */
      public DataNode peek(Fqn fqn)
      {
  -      return findInternal(fqn);
  +      return findInternal(fqn, true);
      }
   
      /**
  @@ -3595,7 +3597,7 @@
       */
      public boolean exists(Fqn fqn)
      {
  -      DataNode n = findInternal(fqn);
  +      DataNode n = findInternal(fqn, false);
         return n != null;
      }
   
  @@ -3604,7 +3606,7 @@
       *
       * @param fqn
       */
  -   private DataNode findInternal(Fqn fqn)
  +   private DataNode findInternal(Fqn fqn, boolean includeNodesMarkedAsRemoved)
      {
         if (fqn == null || fqn.size() == 0) return root;
         TreeNode n = root;
  @@ -3615,6 +3617,8 @@
            n = n.getChild(obj);
            if (n == null)
               return null;
  +         else if (!includeNodesMarkedAsRemoved && isMarkedForRemoval(n))
  +            return null;
         }
         return (DataNode) n;
      }
  @@ -3640,11 +3644,8 @@
       */
      public boolean exists(Fqn fqn, Object key)
      {
  -      DataNode n = findInternal(fqn);
  -      if (n == null)
  -         return false;
  -      else
  -         return n.containsKey(key);
  +      DataNode n = findInternal(fqn, false);
  +      return n != null && n.containsKey(key);
      }
   
   
  @@ -4055,6 +4056,14 @@
         int indent = 0;
         Map children;
   
  +      sb.append("Root lock: ");
  +      if(root.isLocked()) {
  +         sb.append("\t(");
  +         root.getLock().toString(sb);
  +         sb.append(")");
  +      }
  +      sb.append("\n");
  +      
         children = root.getChildren();
         if (children != null && children.size() > 0)
         {
  @@ -4127,6 +4136,76 @@
         return count;
      }
   
  +    private void markForRemoval(TreeNode n)
  +    {
  +       n.put(REMOVAL_MARKER, null);
  +       // mark children as well.
  +       Map children = n.getChildren();
  +       if (children != null && !children.isEmpty())
  +       {
  +          // traverse children
  +          Iterator i = children.values().iterator();
  +          while (i.hasNext())
  +          {
  +             markForRemoval((TreeNode) i.next());
  +          }
  +       }
  +    }
  +
  +    private void scrubRemoveMarker(TreeNode n, boolean deep)
  +    {
  +       n.remove(REMOVAL_MARKER);
  +       // unmark children as well.
  +       Map children = n.getChildren();
  +       if (children != null && !children.isEmpty())
  +       {
  +          // traverse children
  +          Iterator i = children.values().iterator();
  +          while (i.hasNext())
  +          {
  +             scrubRemoveMarker((TreeNode) i.next(), true);
  +          }
  +       }
  +
  +    }
  +
  +    private boolean isMarkedForRemoval(TreeNode n)
  +    {
  +       return n.containsKey(REMOVAL_MARKER);
  +    }
  +
  +    /**
  +     * Internal method; not to be used externally.
  +     * @param f
  +     */
  +    public void realRemove(Fqn f, boolean skipMarkerCheck)
  +    {
  +       DataNode n = findInternal(f, true);
  +       if (n == null)
  +          return;
  +
  +       if (log.isDebugEnabled()) log.debug("Performing a real remove for node " + f + ", marked for removal.");
  +       if (skipMarkerCheck || isMarkedForRemoval(n))
  +       {
  +          if (n.getFqn().isRoot())
  +          {
  +             // do not actually delete; just remove deletion marker
  +             scrubRemoveMarker(n, false);
  +             // but now remove all children, since the call has been to remove("/")
  +             n.removeAllChildren();
  +          }
  +          else
  +          {
  +             n.getParent().removeChild(n.getName());
  +          }
  +       }
  +       else
  +       {
  +          if (log.isDebugEnabled()) log.debug("Node " + f + " NOT marked for removal as expected, not removing!");
  +       }
  +    }
  +
  +
      /**
       * Returns an <em>approximation</em> of the total number of attributes in
       * the tree. Since this method doesn't acquire any locks, the number might
  @@ -4481,6 +4560,9 @@
            throw new NodeNotExistsException(errStr);
         }
         notifyNodeModify(fqn, true);
  +
  +      scrubRemoveMarker(n, false);
  +
         // TODO: move creation of undo-operations to separate Interceptor
         // create a compensating method call (reverting the effect of
         // this modification) and put it into the TX's undo list.
  @@ -4555,6 +4637,8 @@
         notifyNodeModify(fqn, true);
         old_value = n.put(key, value);
   
  +      scrubRemoveMarker(n, false);
  +
         // create a compensating method call (reverting the effect of
         // this modification) and put it into the TX's undo list.
         if (tx != null && create_undo_ops)
  @@ -4645,8 +4729,27 @@
         TreeNode parent_node;
         MethodCall undo_op = null;
   
  -      if (log.isTraceEnabled())
  -         log.trace(new StringBuffer("_remove(").append(tx).append(", \"").append(fqn).append("\")"));
  +      if (log.isTraceEnabled()) log.trace(new StringBuffer("_remove(").append(tx).append(", \"").append(fqn).append("\")"));
  +
  +      // check if this is triggered by a rollback operation ...
  +      if (tx != null)
  +      {
  +         try
  +         {
  +            int status = getTransactionManager().getTransaction().getStatus();
  +            if (status == Status.STATUS_MARKED_ROLLBACK || status == Status.STATUS_ROLLEDBACK || status == Status.STATUS_ROLLING_BACK)
  +            {
  +               if (log.isDebugEnabled()) log.debug("This remove call is triggered by a transaction rollback, as a compensation operation.  Do a realRemove() instead.");
  +               realRemove(fqn, true);
  +               return;
  +            }
  +         }
  +         catch (Exception e)
  +         {
  +            // what do we do here?
  +            log.trace("Caught exception dealing with transaction manager", e);
  +         }
  +      }
   
         if (fqn.size() == 0)
         {
  @@ -4687,13 +4790,17 @@
   
         parent_node = n.getParent();
   
  -      // remove subtree from parent
  +      if (isNodeLockingOptimistic() || eviction)
         parent_node.removeChild(n.getName());
  +      else
  +         markForRemoval(n);
  +      
         if (eviction)
            parent_node.setChildrenLoaded(false);
   
         // release all locks for the entire subtree
  -      n.releaseAll(tx != null ? tx : (Object) Thread.currentThread());
  +      // JBCACHE-871 -- this is not correct!  This is the lock interceptor's task
  +      // n.releaseAll(tx != null ? tx : (Object) Thread.currentThread());
   
         // create a compensating method call (reverting the effect of
         // this modification) and put it into the TX's undo list.
  @@ -4962,6 +5069,8 @@
            return;
         }
         tmp.addChild(child_name, old_node);
  +      // make sure any deleted markers are removed from this child.
  +      scrubRemoveMarker(old_node, true);
         notifyNodeCreated(new Fqn(parent_fqn, child_name));
      }
   
  @@ -5712,26 +5821,8 @@
         int treeNodeSize;
   
         if (fqn == null) return null;
  -      DataNode toReturn = null;
  -      if ((treeNodeSize = fqn.size()) == 0)
  -      {
  -         toReturn = root;
  -      }
  -      else
  -      {
  -         n = root;
  -         for (int i = 0; i < treeNodeSize; i++)
  -         {
  -            child_name = fqn.get(i);
  -            child_node = n.getChild(child_name);
  -            if (child_node == null)
  -            {
  -               return null;
  -            }
  -            n = child_node;
  -         }
  -         toReturn = (DataNode) child_node;
  -      }
  +
  +      DataNode toReturn = findInternal(fqn, false);
   
         if (version != null)
         {
  
  
  
  1.7.2.1   +14 -1     JBossCache/src/org/jboss/cache/TransactionTable.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTable.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionTable.java,v
  retrieving revision 1.7
  retrieving revision 1.7.2.1
  diff -u -b -r1.7 -r1.7.2.1
  --- TransactionTable.java	12 Jun 2006 20:24:32 -0000	1.7
  +++ TransactionTable.java	5 Dec 2006 00:01:52 -0000	1.7.2.1
  @@ -25,7 +25,7 @@
    * given TX.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.7.2.1 $
    */
   public class TransactionTable {
   
  @@ -202,6 +202,19 @@
      }
   
      /**
  +    * Adds a node that has been removed to the global transaction
  +    */
  +    public void addRemovedNode(GlobalTransaction gtx, Fqn fqn)
  +    {
  +       TransactionEntry entry=get(gtx);
  +       if(entry == null) {
  +          log.error("transaction entry not found for (gtx=" + gtx + ")");
  +         return;
  +       }
  +       entry.addRemovedNode(fqn);
  +    }
  +
  +   /**
       * Returns summary debug information.
       */
      public String toString() {
  
  
  


From msurtani at jboss.com  Mon Dec  4 19:01:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 19:01:52 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GrNku-0001ON-BB@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 19:01:52

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.2  +111 -37   JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.1
  retrieving revision 1.20.2.2
  diff -u -b -r1.20.2.1 -r1.20.2.2
  --- PessimisticLockInterceptor.java	31 Oct 2006 17:10:46 -0000	1.20.2.1
  +++ PessimisticLockInterceptor.java	5 Dec 2006 00:01:52 -0000	1.20.2.2
  @@ -23,6 +23,7 @@
   
   import javax.transaction.Transaction;
   import java.util.Collections;
  +import java.util.Iterator;
   import java.util.LinkedList;
   import java.util.List;
   import java.util.Map;
  @@ -35,7 +36,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.1 2006/10/31 17:10:46 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.2 2006/12/05 00:01:52 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -65,6 +66,7 @@
         long lock_timeout = lock_acquisition_timeout;
         Object[] args = m.getArgs();
         InvocationContext ctx = getInvocationContext();
  +      boolean storeLockedNode = false;
   
         if (log.isTraceEnabled()) log.trace("PessimisticLockInterceptor invoked for method " + m);
         if (ctx.getOptionOverrides() != null && ctx.getOptionOverrides().isSuppressLocking())
  @@ -112,6 +114,8 @@
               fqn = (Fqn) args[1];
               lock_type = DataNode.LOCK_TYPE_WRITE;
               recursive = true; // remove node and *all* child nodes
  +            // JBCACHE-871 We need to store the node
  +            storeLockedNode = true;
               break;
            case MethodDeclarations.removeKeyMethodLocal_id:
            case MethodDeclarations.removeDataMethodLocal_id:
  @@ -165,13 +169,13 @@
            {
               do
               {
  -               lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, zeroLockTimeout ? 0 : lock_timeout, createIfNotExists);
  +               lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, zeroLockTimeout ? 0 : lock_timeout, createIfNotExists, storeLockedNode);
               }
               while (!cache.exists(fqn)); // keep trying until we have the lock (fixes concurrent remove())
               // terminates successfully, or with (Timeout)Exception
            }
            else
  -            lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, zeroLockTimeout ? 0 : lock_timeout, createIfNotExists);
  +            lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, zeroLockTimeout ? 0 : lock_timeout, createIfNotExists, storeLockedNode);
         }
         else
         {
  @@ -180,6 +184,17 @@
         }
         if (m.getMethodId() == MethodDeclarations.lockMethodLocal_id)
            return null;
  +
  +      // FIXME this should be done in UnlockInterceptor, but I didn't want
  +      // to add the removedNodes map to TreeCache
  +      if (storeLockedNode && ctx.getGlobalTransaction() == null)
  +      {
  +         //cache.getRemovedNodesMap().remove(fqn);
  +         //cache.peek(fqn);
  +         // do a REAL remove here.
  +         cache.realRemove(fqn, true);
  +      }
  +
         return super.invoke(m);
      }
   
  @@ -193,7 +208,7 @@
       * @param recursive Lock children recursively
       */
      private void lock(Fqn fqn, GlobalTransaction gtx, int lock_type, boolean recursive,
  -                     long lock_timeout, boolean createIfNotExists)
  +                     long lock_timeout, boolean createIfNotExists, boolean isRemoveNodeOperation)
              throws TimeoutException, LockingException, InterruptedException
      {
         DataNode n;
  @@ -203,6 +218,7 @@
         Object owner = (gtx != null) ? (Object) gtx : currentThread;
         int treeNodeSize;
         boolean acquired = false;
  +      int currentLockType;
   
   
         if (log.isTraceEnabled()) log.trace("Attempting to lock node " + fqn + " for owner " + owner);
  @@ -220,10 +236,19 @@
            lock_type = DataNode.LOCK_TYPE_NONE;
   
         n = cache.getRoot();
  -      for (int i = 0; i < treeNodeSize; i++)
  +      for (int i = -1; i < treeNodeSize; i++)
  +      {
  +         if (i == -1)
  +         {
  +            child_name = Fqn.ROOT.getName();
  +            child_node = cache.getRoot();
  +         }
  +         else
         {
            child_name = fqn.get(i);
            child_node = (DataNode) n.getOrCreateChild(child_name, gtx, createIfNotExists);
  +         }
  +
            if (child_node == null)
            {
               if (log.isTraceEnabled())
  @@ -239,35 +264,21 @@
            }
            else
            {
  -            if (lock_type == DataNode.LOCK_TYPE_WRITE && i == (treeNodeSize - 1))
  +            if (writeLockNeeded(lock_type, i, treeNodeSize, isRemoveNodeOperation, createIfNotExists, fqn, child_node.getFqn()))
               {
  -               acquired = child_node.acquire(owner, lock_timeout, DataNode.LOCK_TYPE_WRITE);
  +               currentLockType = DataNode.LOCK_TYPE_WRITE;
               }
               else
               {
  -               acquired = child_node.acquire(owner, lock_timeout, DataNode.LOCK_TYPE_READ);
  +               currentLockType = DataNode.LOCK_TYPE_READ;
               }
            }
   
  +         // Try to acquire the lock; recording that we did if successful
  +         acquireNodeLock(child_node, owner, gtx, currentLockType, lock_timeout);
   
  -         if (acquired)
  -         {
  -            if (gtx != null)
  -            {
  -               // add the lock to the list of locks maintained for this transaction
  -               // (needed for release of locks on commit or rollback)
  -               cache.getTransactionTable().addLock(gtx, child_node.getLock());
  -            }
  -            else
  +         if (recursive && isTargetNode(i, treeNodeSize))
               {
  -               IdentityLock l = child_node.getLock();
  -               List locks = getLocks(currentThread);
  -               if (!locks.contains(l))
  -                  locks.add(l);
  -            }
  -         }
  -
  -         if (recursive && i == (treeNodeSize - 1))
            {
               Set acquired_locks = child_node.acquireAll(owner, lock_timeout, lock_type);
               if (acquired_locks.size() > 0)
  @@ -278,15 +289,62 @@
                  }
                  else
                  {
  -                  List locks = getLocks(currentThread);
  +                     List locks = getLocks(Thread.currentThread());
                     locks.addAll(acquired_locks);
                  }
               }
            }
  +         }
            n = child_node;
         }
  +
  +      // Add the Fqn to be removed to the transaction entry so we can clean up after ourselves during commit/rollback
  +      if (isRemoveNodeOperation && gtx != null) cache.getTransactionTable().get(gtx).addRemovedNode(fqn);
  +   }
  +
  +   private boolean writeLockNeeded(int lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
  +   {
  +      if (isRemoveOperation && currentNodeIndex == treeNodeSize - 2)
  +         return true; // we're doing a remove and we've reached the PARENT node of the target to be removed.
  +
  +      if (!isTargetNode(currentNodeIndex, treeNodeSize) && !cache.exists(new Fqn(currentFqn, targetFqn.get(currentNodeIndex + 1))))
  +         return createIfNotExists; // we're at a node in the tree, not yet at the target node, and we need to create the next node.  So we need a WL here.
  +
  +      return lock_type == DataNode.LOCK_TYPE_WRITE && isTargetNode(currentNodeIndex, treeNodeSize) && createIfNotExists; //normal operation, write lock explicitly requested and this is the target to be written to.
  +   }
  +
  +   private boolean isTargetNode(int nodePosition, int treeNodeSize)
  +   {
  +      return nodePosition == (treeNodeSize - 1);
  +   }
  +
  +   private void acquireNodeLock(DataNode node, Object owner, GlobalTransaction gtx, int lock_type, long lock_timeout) throws LockingException, TimeoutException, InterruptedException
  +   {
  +      boolean acquired = node.acquire(owner, lock_timeout, lock_type);
  +      if (acquired)
  +      {
  +         // Record the lock for release on method return or tx commit/rollback
  +         recordNodeLock(gtx, node.getLock());
  +      }
  +   }
  +
  +   private void recordNodeLock(GlobalTransaction gtx, IdentityLock lock)
  +   {
  +      if (gtx != null)
  +      {
  +         // add the lock to the list of locks maintained for this transaction
  +         // (needed for release of locks on commit or rollback)
  +         cache.getTransactionTable().addLock(gtx, lock);
  +      }
  +      else
  +      {
  +         List locks = getLocks(Thread.currentThread());
  +         if (!locks.contains(lock))
  +            locks.add(lock);
  +      }
      }
   
  +
      private List getLocks(Thread currentThread)
      {
         // This sort of looks like a get/put race condition, but
  @@ -338,6 +396,14 @@
            return;
         }
   
  +      // first remove nodes that should be deleted.
  +      Iterator removedNodes = entry.getRemovedNodes().iterator();
  +      while (removedNodes.hasNext())
  +      {
  +         Fqn f = (Fqn) removedNodes.next();
  +         cache.realRemove(f, false);
  +      }
  +
         // Let's do it in stack style, LIFO
         entry.releaseAllLocksLIFO(gtx);
   
  @@ -375,6 +441,14 @@
            return;
         }
   
  +      Iterator removedNodes = entry.getRemovedNodes().iterator();
  +      while (removedNodes.hasNext())
  +      {
  +         Fqn f = (Fqn) removedNodes.next();
  +         cache.realRemove(f, false);
  +
  +      }
  +
         // 1. Revert the modifications by running the undo-op list in reverse. This *cannot* throw any exceptions !
         entry.undoOperations(cache);
   
  
  
  


From msurtani at jboss.com  Mon Dec  4 19:01:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 04 Dec 2006 19:01:52 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/aop  ...
Message-ID: <E1GrNku-0001OY-G7@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/04 19:01:52

  Modified:    src/org/jboss/cache/aop  Tag: Branch_JBossCache_1_4_0
                        PojoCache.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.23.2.3  +18 -15    JBossCache/src/org/jboss/cache/aop/Attic/PojoCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/aop/Attic/PojoCache.java,v
  retrieving revision 1.23.2.2
  retrieving revision 1.23.2.3
  diff -u -b -r1.23.2.2 -r1.23.2.3
  --- PojoCache.java	11 Jul 2006 10:09:53 -0000	1.23.2.2
  +++ PojoCache.java	5 Dec 2006 00:01:52 -0000	1.23.2.3
  @@ -6,35 +6,35 @@
    */
   package org.jboss.cache.aop;
   
  -import org.jboss.cache.xml.XmlHelper;
  -import org.jboss.cache.lock.UpgradeException;
  +import org.jboss.aop.InstanceAdvisor;
  +import org.jboss.cache.CacheException;
  +import org.jboss.cache.DataNode;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.Node;
  +import org.jboss.cache.RegionNotEmptyException;
  +import org.jboss.cache.TreeCache;
   import org.jboss.cache.aop.eviction.AopEvictionPolicy;
   import org.jboss.cache.aop.util.ObjectUtil;
  +import org.jboss.cache.lock.UpgradeException;
  +import org.jboss.cache.marshall.ObjectSerializationFactory;
   import org.jboss.cache.marshall.Region;
   import org.jboss.cache.marshall.RegionNameConflictException;
  -import org.jboss.cache.marshall.ObjectSerializationFactory;
   import org.jboss.cache.transaction.BatchModeTransactionManager;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.Fqn;
  -import org.jboss.cache.CacheException;
  -import org.jboss.cache.RegionNotEmptyException;
  -import org.jboss.cache.DataNode;
  -import org.jboss.cache.Node;
  -import org.jboss.aop.InstanceAdvisor;
  +import org.jboss.cache.xml.XmlHelper;
   import org.jgroups.JChannel;
   import org.w3c.dom.Element;
   
  +import javax.transaction.RollbackException;
   import javax.transaction.Status;
   import javax.transaction.SystemException;
  -import javax.transaction.TransactionManager;
  -import javax.transaction.RollbackException;
   import javax.transaction.Transaction;
  +import javax.transaction.TransactionManager;
  +import java.lang.reflect.Field;
  +import java.util.ArrayList;
   import java.util.Iterator;
  +import java.util.List;
   import java.util.Map;
   import java.util.WeakHashMap;
  -import java.util.List;
  -import java.util.ArrayList;
  -import java.lang.reflect.Field;
   
   /**
    * PojoCache implementation class. User should use the {@link PojoCacheIfc} interface directly to
  @@ -216,6 +216,9 @@
         boolean sendNodeEvent = false;
         // Let's do it brute force.
         _remove(null, fqn, create_undo_ops, sendNodeEvent);
  +
  +      // since this is not in the scope of a tx, do a realRemove() immediately - Manik, 1/Dec/2006 - JBCACHE-871
  +      realRemove(fqn, false);      
      }
   
      /**
  
  
  


From jgreene at jboss.com  Mon Dec  4 19:25:44 2006
From: jgreene at jboss.com (Jason Thomas Greene)
Date: Mon, 04 Dec 2006 19:25:44 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib      ...
Message-ID: <E1GrO80-0001y7-24@committer01.frg.pub.inap.atl.jboss.com>

  User: jgreene 
  Date: 06/12/04 19:25:43

  Modified:    jboss/jbossws/snapshot/lib      jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws.sar
  Log:
  sync jars
  
  Revision  Changes    Path
  1.26      +123 -122  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.25      +213 -212  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.26      +69 -68    repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.37      +3217 -3299repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.37      +4504 -4566repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 19:26:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 19:26:29 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58842 - trunk/build
Message-ID: <E1GrO8j-0001yy-Et@committer01.frg.pub.inap.atl.jboss.com>

Author: jason.greene at jboss.com
Date: 2006-12-04 19:26:28 -0500 (Mon, 04 Dec 2006)
New Revision: 58842

Modified:
   trunk/build/build-thirdparty.xml
Log:
Switch jbossws to snapshot since the Servlet metadata API has changed


Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-04 18:09:44 UTC (rev 58841)
+++ trunk/build/build-thirdparty.xml	2006-12-05 00:26:28 UTC (rev 58842)
@@ -93,7 +93,7 @@
       <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
       <componentref name="jboss/jbossxb" version="snapshot"/>
-      <componentref name="jboss/jbossws" version="2.0.0.CR2"/>
+      <componentref name="jboss/jbossws" version="snapshot"/>
       <componentref name="jboss/messaging" version="1.0.1.GA"/>
       <componentref name="jboss/microcontainer" version="2.0.0.Beta"/>
       <componentref name="jboss/microcontainer14" version="2.0.0.Beta"/>



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 22:10:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 22:10:33 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1704 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/util messaging/core/plugin
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1GrQhV-0004cI-K9@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-04 22:10:30 -0500 (Mon, 04 Dec 2006)
New Revision: 1704

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/JNDIUtil.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
Fixing dependency of stateTransfer & membership + adding listBindings into ClusteredPostOfficeService to help debug membership data

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/JNDIUtil.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/JNDIUtil.java	2006-12-04 18:13:09 UTC (rev 1703)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/JNDIUtil.java	2006-12-05 03:10:30 UTC (rev 1704)
@@ -21,12 +21,12 @@
   */
 package org.jboss.jms.util;
 
+import java.util.StringTokenizer;
+import javax.naming.Binding;
 import javax.naming.Context;
 import javax.naming.NameNotFoundException;
+import javax.naming.NamingEnumeration;
 import javax.naming.NamingException;
-import javax.naming.NamingEnumeration;
-import javax.naming.Binding;
-import java.util.StringTokenizer;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -101,7 +101,19 @@
          context = createContext(c, jndiName.substring(0, idx));
          name = jndiName.substring(idx + 1);
       }
-      context.bind(name, o);
+      boolean failed=false;
+      try
+      {
+         context.rebind(name,o);
+      }
+      catch (Exception ignored)
+      {
+         failed=true;
+      }
+      if (failed)
+      {
+         context.bind(name, o);
+      }
    }
 
    // Attributes ----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-04 18:13:09 UTC (rev 1703)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-05 03:10:30 UTC (rev 1704)
@@ -23,7 +23,6 @@
 
 import javax.management.ObjectName;
 import javax.transaction.TransactionManager;
-
 import org.jboss.jms.selector.SelectorFactory;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
@@ -201,6 +200,11 @@
    {
       this.messagePullPolicy = messagePullPolicy;
    }
+
+   public String listBindings()
+   {
+      return postOffice.printBindingInformation();
+   }
    
    // ServiceMBeanSupport overrides ---------------------------------
    

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-04 18:13:09 UTC (rev 1703)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-05 03:10:30 UTC (rev 1704)
@@ -21,6 +21,7 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
@@ -39,10 +40,8 @@
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
-
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
-
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -75,8 +74,6 @@
 import org.jgroups.blocks.RequestHandler;
 import org.w3c.dom.Element;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
  * 
  * A DefaultClusteredPostOffice
@@ -312,7 +309,7 @@
       MessageListener cml = new ControlMessageListener();
       MembershipListener ml = new ControlMembershipListener();
       RequestHandler rh = new PostOfficeRequestHandler();
-      
+
       this.controlMessageDispatcher = new MessageDispatcher(syncChannel, cml, ml, rh, true);
 
       Receiver r = new DataReceiver();
@@ -323,7 +320,7 @@
       asyncChannel.connect(groupName);
       
       super.start();
-                  
+
       Address syncAddress = syncChannel.getLocalAddress();
       
       Address asyncAddress = asyncChannel.getLocalAddress();
@@ -331,7 +328,9 @@
       PostOfficeAddressInfo info = new PostOfficeAddressInfo(syncAddress, asyncAddress);
       
       put(ADDRESS_INFO_KEY, info);
-      
+
+      verifyMembership(null,this.currentView);
+
       statsSender.start();
       
       started = true;
@@ -1314,7 +1313,48 @@
       return holdingArea.values();
    }
 
+
    /**
+    *  Verifies changes on the View deciding if a node joined or lefted the cluster
+    *
+    * */
+   private void verifyMembership(View oldView, View newView)
+   {
+      try
+      {
+         if (oldView != null)
+         {
+            for(Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+            {
+               Address address = (Address)i.next();
+               if (!newView.containsMember(address))
+               {
+                  nodeLeft(address);
+               }
+            }
+         }
+
+         for(Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+         {
+            Address address = (Address)i.next();
+            if (oldView == null || !oldView.containsMember(address))
+            {
+               nodeJoined(address);
+            }
+         }
+      }
+      catch (Throwable e)
+      {
+         log.error("Caught Exception in MembershipListener", e);
+         IllegalStateException e2 = new IllegalStateException(e.getMessage());
+         e2.setStackTrace(e.getStackTrace());
+         throw e2;
+      }
+   }
+
+
+   
+   /**
     * This method fails over all the queues from node <nodeId> onto this node
     * It is triggered when a JGroups view change occurs due to a member leaving and 
     * it's determined the member didn't leave cleanly
@@ -1567,17 +1607,40 @@
 
       out.println("</table>");
 
-//      out.println("Clustered Information");
-//
-//      NodeAddressInfo info[] = getClusterNodes();
-//
-//      out.println("<table border=1><tr><td>Node</td><td>AsyncChannel</td><td>SyncChannel</td></tr>");
-//      for (int i = 0; i < info.length; i++)
-//      {
-//         out.println("<tr><td>" + info[i].getNodeId() + "</td><td>" + info[i].getAsyncChannelAddress() + "</td><td>" + info[i].getSyncChannelAddress() + "</td>");
-//      }
-//      out.println("</table>");
+      out.println("Replicator's Information");
 
+      out.println("<table border=1><tr><td>Node</td><td>Key</td><td>Value</td></tr>");
+
+      for (Iterator iter = replicatedData.entrySet().iterator(); iter.hasNext();)
+      {
+         Map.Entry entry = (Map.Entry) iter.next();
+         Map subMap = (Map)entry.getValue();
+         boolean firstTime=true;
+         for (Iterator subIterator = subMap.entrySet().iterator(); subIterator.hasNext();)
+         {
+            Map.Entry subValue = (Map.Entry) subIterator.next();
+            out.println("<tr><td>" + entry.getKey() + "</td>");
+            out.println("<td>" + subValue.getKey() + "</td><td>" + subValue.getValue() + "</td></tr>" );
+         }
+
+      }
+
+      out.println("</table>");
+
+
+      out.println("View Information");
+
+      out.println("<table border=1><tr><td>Members</td></tr>");
+
+
+      for (Iterator iterMembers = currentView.getMembers().iterator(); iterMembers.hasNext();)
+      {
+         Address address = (Address) iterMembers.next();
+         out.println("<tr><td>" + address + "</td></tr>");
+      }
+
+      out.println("</table>");
+
       return buffer.toString();
    }
 
@@ -1693,7 +1756,7 @@
       if (trace) { log.trace(this + " loading bindings"); }
       
       boolean isState = syncChannel.getState(null, stateTimeout);
-      
+
       if (!isState)
       {
          //Must be first member in group or non clustered- we load the state ourself from the database
@@ -1707,20 +1770,20 @@
          //The state will be set in due course via the MessageListener - we must wait until this happens
          
          if (trace) { log.trace(this.nodeId + " Not first member of group- so waiting for state to arrive...."); }
-         
-         synchronized (setStateLock)
+
+      synchronized (setStateLock)
+      {
+         //TODO we should implement a timeout on this
+         while (!stateSet)
          {
-            //TODO we should implement a timeout on this
-            while (!stateSet)
-            {
-               setStateLock.wait();
-            }
+            setStateLock.wait();
          }
-         
+      }
+
          if (trace) { log.trace(this.nodeId + " Received state"); }
       }
    }
-   
+
    protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
    {
       Queue queue;
@@ -2193,6 +2256,8 @@
          }
          try
          {
+            // TODO: Make it trace
+            log.info("getState:" + DefaultClusteredPostOffice.this.getOfficeName());
             return getStateAsBytes();
          }
          catch (Exception e)
@@ -2226,7 +2291,9 @@
             }
             try
             {
-               processStateBytes(bytes);               
+               // TODO: Make it trace
+               log.info("setState:" + DefaultClusteredPostOffice.this.getOfficeName());
+               processStateBytes(bytes);
             }
             catch (Exception e)
             {
@@ -2266,52 +2333,36 @@
       
       public void viewAccepted(View newView)
       {
-         if (trace) { log.trace(DefaultClusteredPostOffice.this  + " got new view: " + newView); }
+         //if (trace) { log.trace(DefaultClusteredPostOffice.this  + " got new view: " + newView
+         // + DefaultClusteredPostOffice.this.getOfficeName()); }
+         //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
+         //TODO:     can't we do the same since this is pretty useful?
+         log.info(DefaultClusteredPostOffice.this  + " got new view: " + newView + " postOffice:"
+            + DefaultClusteredPostOffice.this.getOfficeName());
 
          // JGroups will make sure this method is never called by more than one thread concurrently
          
          View oldView = currentView;
          currentView = newView;
-         
-         try
-         {         
-            if (oldView != null)
-            {
-               for(Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
-               {
-                  Address address = (Address)i.next();
-                  if (!newView.containsMember(address))
-                  {
-                     nodeLeft(address);
-                  }
-               }
-            }
-            
-            for(Iterator i = newView.getMembers().iterator(); i.hasNext(); )
-            {
-               Address address = (Address)i.next();
-               if (oldView == null || !oldView.containsMember(address))
-               {
-                  nodeJoined(address);
-               }
-            }
-         }
-         catch (Throwable e)
+
+         // Since now membership is sent over state transfer, we have to wait stateSet to be set.
+         // If this logic is not good enough, we will have to place Address in a separate data structure
+         // as it used to be (NodeInfos)
+         if (stateSet)
          {
-            log.error("Caught Exception in MembershipListener", e);
-            IllegalStateException e2 = new IllegalStateException(e.getMessage());
-            e2.setStackTrace(e.getStackTrace());
-            throw e2;
+            verifyMembership(oldView, newView);
          }
       }
-  
+
       public byte[] getState()
       {        
          //NOOP
          return null;
       }     
    }
-  
+
+
+
    /*
     * This class is used to listen for messages on the async channel
     */



From jboss-cvs-commits at lists.jboss.org  Mon Dec  4 23:03:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 04 Dec 2006 23:03:06 -0500
Subject: [jboss-cvs] JBossAS SVN: r58843 -
	projects/microcontainer/trunk/container/src/main/org/jboss/virtual
Message-ID: <E1GrRWM-0005S1-Rz@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-04 23:03:05 -0500 (Mon, 04 Dec 2006)
New Revision: 58843

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
Log:
JBMICROCONT-115, remove the finalize

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-05 00:26:28 UTC (rev 58842)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-05 04:03:05 UTC (rev 58843)
@@ -383,10 +383,5 @@
       VirtualFile other = (VirtualFile) obj;
       return handler.equals(other.handler);
    }
-   
-   @Override
-   protected void finalize() throws Throwable
-   {
-      close();
-   }
+
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 00:09:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 00:09:18 -0500
Subject: [jboss-cvs] JBossAS SVN: r58844 -
	projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test
Message-ID: <E1GrSYQ-0006V5-7a@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-05 00:09:16 -0500 (Tue, 05 Dec 2006)
New Revision: 58844

Modified:
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java
Log:
Drop the milliseconds on both files in testRootLastModified.

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java	2006-12-05 04:03:05 UTC (rev 58843)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java	2006-12-05 05:09:16 UTC (rev 58844)
@@ -166,7 +166,9 @@
       long realLastModified = getRealLastModified("simple", null);
       // strip any milliseconds
       realLastModified = realLastModified / 1000 * 1000;
-      assertEquals(realLastModified, root.getLastModified());
+      long fileLastModified = root.getLastModified();
+      fileLastModified = fileLastModified / 1000 * 1000;
+      assertEquals(realLastModified, fileLastModified);
    }
    
    public void testChildLastModified() throws Exception



From forge-admin at jboss.com  Tue Dec  5 01:00:29 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Tue, 05 Dec 2006 01:00:29 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GrTLx-0007Bc-3J@committer01.frg.pub.inap.atl.jboss.com>

Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-04 05:59 EST)
------------------------------------------------------

Updated version numbers

  JBossCache  src/org/jboss/cache/Version.java  1.13.2.4
  JBossCache  docs/Changelog.txt                1.15.2.4
  JBossCache  build.xml                         1.95.2.7


Commit from msurtani (2006-12-04 06:21 EST)
--------------------

testing using java 5's util.concurrent

  JBossCache  tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java  1.3


Commit from bela (2006-12-04 07:03 EST)
----------------

removed dependency on TestingUtil

  JBossCache  tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java  1.4


Commit from bela (2006-12-04 07:33 EST)
----------------

ns

  JBossCache  tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java  1.5


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-04 12:00 EST)
---------------------------------------------------------

Add a log message when inactivating a region

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.25


Commit from rawb (2006-12-04 12:45 EST)
----------------

Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java              1.9
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/ConvertNodeToXPathDialog.java  1.1


Commit from rawb (2006-12-04 12:46 EST)
----------------

Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view. Added action which allows you to open file directly in editor

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java  1.4


Commit from rawb (2006-12-04 12:47 EST)
----------------

Changes to dialog allow you to turn a selection from an xml file into an xpath to be used in the properties view

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml                                                                                                1.26
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLCorrectionAssistantProvider.java          1.3
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema/ServiceXMLQuickFixProvider.exsd                                                             1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals/IServiceXMLQuickFixProposalProvider.java  1.1
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/META-INF/MANIFEST.MF                                                                               1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/plugin.xml                                                                                         1.2


Commit from ebernard (2006-12-04 13:00 EST)
--------------------

SNAPSHOT

+ repository.jboss.com  hibernate-entitymanager/3.2.1.SNAPSHOT/component-info.xml               1.1
+ repository.jboss.com  hibernate-entitymanager/3.2.1.SNAPSHOT/lib/ejb3-persistence.jar         1.1
+ repository.jboss.com  hibernate-entitymanager/3.2.1.SNAPSHOT/lib/hibernate-entitymanager.jar  1.1
+ repository.jboss.com  hibernate-annotations/3.2.1.SNAPSHOT/component-info.xml                 1.1
+ repository.jboss.com  hibernate-annotations/3.2.1.SNAPSHOT/lib/hibernate-annotations.jar      1.1


Commit from rawb (2006-12-04 13:13 EST)
----------------

forgot this

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF  1.11


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-04 17:17 EST)
---------------------------------------------------------

[JBCACHE-876] Add tests that custom classes in Fqn's work properly

+ JBossCache  tests/functional/org/jboss/cache/marshall/FooClassLoader.java  1.1.2.1
+ JBossCache  tests/functional/org/jboss/cache/marshall/Foo.notjava          1.1.2.1
+ JBossCache  tests/functional/org/jboss/cache/marshall/Foo.clazz            1.1.2.1


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-04 17:18 EST)
---------------------------------------------------------

[JBCACHE-876] Add tests that custom classes in Fqn's work properly
Be more specific about the usage of classloader in testPuts()

  JBossCache  tests/functional/org/jboss/cache/marshall/SyncReplTest.java   1.5.2.1
  JBossCache  tests/functional/org/jboss/cache/marshall/AsyncReplTest.java  1.5.2.1


Commit from mculpepper (2006-12-04 17:21 EST)
----------------------

moved the testJARDefaultConfig unit test to the PackagesEARTest where there are some actual java files that are compiled into classes so we can test the jar package type

  jbosside  core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/NewProjectTest.java   1.2
  jbosside  core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/AllTests.java         1.2
  jbosside  core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/PackagesEARTest.java  1.3


Commit from mculpepper (2006-12-04 17:23 EST)
----------------------

added a note about proper build order etc in buildProject method

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java  1.9


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-04 19:01 EST)
------------------------------------------------------

ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch

  JBossCache  src/org/jboss/cache/lock/IdentityLock.java                        1.12.2.1
  JBossCache  src/org/jboss/cache/TransactionEntry.java                         1.8.2.1
  JBossCache  src/org/jboss/cache/TreeCache.java                                1.195.2.26
  JBossCache  src/org/jboss/cache/TransactionTable.java                         1.7.2.1
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.20.2.2
  JBossCache  src/org/jboss/cache/aop/PojoCache.java                            1.23.2.3


Commit from jgreene (2006-12-04 19:25 EST)
-------------------

sync jars

  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar    1.26
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar     1.25
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar      1.26
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar  1.37
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar         1.37
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061205/43dc00f2/attachment.html 

From scott.stark at jboss.com  Tue Dec  5 01:13:29 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 05 Dec 2006 01:13:29 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1GrTYX-0007Wm-Gi@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/05 01:13:29

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  Compatible with javassist 3.4.GA
  
  Revision  Changes    Path
  1.31      +1 -0      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- component-info.xml	4 Nov 2006 19:55:40 -0000	1.30
  +++ component-info.xml	5 Dec 2006 06:13:29 -0000	1.31
  @@ -16,6 +16,7 @@
         </import>
         <import componentref="javassist">
         	<compatible version="3.3.0.GA"/>
  +      	<compatible version="3.4.GA"/>
         </import>
         <import componentref="ibm-wsdl4j">
         	<compatible version="1.5.2jboss"/>
  
  
  


From lankkaorippp at gmail.com  Tue Dec  5 04:51:57 2006
From: lankkaorippp at gmail.com (=?iso-2022-jp?B?GyRCR3BMWiEhTEBIfhsoQg==?=)
Date: Tue, 05 Dec 2006 18:51:57 +0900
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCNls1Xk8iTW0kRyQ5ISNCZztqNV4bKEI=?=
	=?iso-2022-jp?b?GyRCJDQzTkcnJC8kQCQ1JCQhIxsoQg==?=
Message-ID: <200612051033.kB5AXHXq016322@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061205/6a9dd78f/attachment.html 

From gavin.king at jboss.com  Tue Dec  5 08:13:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:13:13 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF    ...
Message-ID: <E1Gra6j-00068t-Fb@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:13:13

  Modified:    src/ui/META-INF    faces-config.xml seam.taglib.xml
                        taglib.tld
  Log:
  remove obsolete
  
  Revision  Changes    Path
  1.21      +0 -5      jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- faces-config.xml	19 Nov 2006 17:36:11 -0000	1.20
  +++ faces-config.xml	5 Dec 2006 13:13:13 -0000	1.21
  @@ -456,9 +456,4 @@
           <converter-class>org.jboss.seam.ui.ConvertDateTime</converter-class>
       </converter>
   
  -    <component>
  -      <component-type>org.jboss.seam.ui.UISecure</component-type>
  -      <component-class>org.jboss.seam.ui.UISecure</component-class>
  -    </component>
  -    
   </faces-config>
  
  
  
  1.18      +0 -7      jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- seam.taglib.xml	19 Nov 2006 17:36:11 -0000	1.17
  +++ seam.taglib.xml	5 Dec 2006 13:13:13 -0000	1.18
  @@ -111,11 +111,4 @@
           </converter>
       </tag>
       
  -    <tag>
  -      <tag-name>secure</tag-name>
  -      <component>
  -        <component-type>org.jboss.seam.ui.UISecure</component-type>
  -      </component>
  -    </tag>
  -    
   </facelet-taglib>
  \ No newline at end of file
  
  
  
  1.22      +0 -12     jboss-seam/src/ui/META-INF/taglib.tld
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: taglib.tld
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/taglib.tld,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- taglib.tld	14 Nov 2006 05:20:42 -0000	1.21
  +++ taglib.tld	5 Dec 2006 13:13:13 -0000	1.22
  @@ -908,16 +908,4 @@
       </attribute>
     </tag>
   
  -  <tag>
  -    <name>secure</name>
  -    <tag-class>org.jboss.seam.ui.tag.SecureTag</tag-class>
  -    <body-content>JSP</body-content>
  -    <attribute>
  -      <name>roles</name>
  -      <required>false</required>
  -      <rtexprvalue>false</rtexprvalue>
  -    </attribute>
  -
  -  </tag>
  -
   </taglib>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:20:22 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:20:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/chatroom  ...
Message-ID: <E1GraDe-0006GB-Ln@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:20:22

  Modified:    examples/remoting/chatroom  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.10      +10 -66    jboss-seam/examples/remoting/chatroom/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/chatroom/build.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- build.xml	6 Jun 2006 20:00:21 -0000	1.9
  +++ build.xml	5 Dec 2006 13:20:22 -0000	1.10
  @@ -6,71 +6,15 @@
       <property name="Name"                   value="Seam Remoting Chat Room Example"/>
       <property name="example.name"           value="seam-chatroom"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="chatroom-service.xml"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -        <include name="META-INF/*"/>
  -        <include name="treecache.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../../lib">
  -        <include name="jgroups.jar"/>
  -    	<include name="jboss-cache*.jar"/>
  -    	<include name="jboss-aop*.jar"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.facelets.lib"    value="yes"/>
  +	<property name="example.cache.lib"       value="yes"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.eejb.classpath"/>
  +    <property name="tomcat.conf"             value="eejb.conf"/>
   
     <import file="../../../build.xml"/>
   
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:20:22 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:20:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/chatroom/resources/META-INF
	...
Message-ID: <E1GraDe-0006GI-R3@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:20:22

  Modified:    examples/remoting/chatroom/resources/META-INF 
                        application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.7       +6 -0      jboss-seam/examples/remoting/chatroom/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/chatroom/resources/META-INF/application.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.6
  +++ application.xml	5 Dec 2006 13:20:22 -0000	1.7
  @@ -19,6 +19,12 @@
   	    <java>jboss-seam.jar</java>
   	</module>
   	<module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
  +	<module>
   	    <java>jboss-cache-jdk50.jar</java>
   	</module>
   	<module>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:20:23 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:20:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/helloworld  ...
Message-ID: <E1GraDf-0006GP-19@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:20:23

  Modified:    examples/remoting/helloworld  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.10      +7 -61     jboss-seam/examples/remoting/helloworld/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/helloworld/build.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- build.xml	6 Aug 2006 13:59:20 -0000	1.9
  +++ build.xml	5 Dec 2006 13:20:22 -0000	1.10
  @@ -6,67 +6,13 @@
       <property name="Name"                   value="Seam Remoting HelloWorld Example"/>
       <property name="example.name"           value="seam-helloworld"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -     
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -      <include name="META-INF/*"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../../lib">
  -      <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
  +    <property name="tomcat.conf"             value="eejb.conf"/>
   
       <import file="../../../build.xml"/>
   
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:20:23 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:20:23 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/helloworld/resources/META-INF ...
Message-ID: <E1GraDf-0006GW-6I@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:20:23

  Modified:    examples/remoting/helloworld/resources/META-INF 
                        application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.6       +6 -0      jboss-seam/examples/remoting/helloworld/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/helloworld/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.5
  +++ application.xml	5 Dec 2006 13:20:23 -0000	1.6
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:20:23 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:20:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/progressbar  ...
Message-ID: <E1GraDf-0006Ge-Ah@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:20:23

  Modified:    examples/remoting/progressbar  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.8       +7 -61     jboss-seam/examples/remoting/progressbar/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/progressbar/build.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- build.xml	6 Aug 2006 13:59:20 -0000	1.7
  +++ build.xml	5 Dec 2006 13:20:23 -0000	1.8
  @@ -6,67 +6,13 @@
       <property name="Name"                   value="Seam Remoting Progress Bar Example"/>
       <property name="example.name"           value="seam-progressbar"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -      <include name="META-INF/*"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../../lib">
  -      <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
  +    <property name="tomcat.conf"             value="eejb.conf"/>
   
       <import file="../../../build.xml"/>
   
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:20:23 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:20:23 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/progressbar/resources/META-INF ...
Message-ID: <E1GraDf-0006Gq-GB@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:20:23

  Modified:    examples/remoting/progressbar/resources/META-INF 
                        application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.4       +6 -0      jboss-seam/examples/remoting/progressbar/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/progressbar/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.3
  +++ application.xml	5 Dec 2006 13:20:23 -0000	1.4
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:23:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking  ...
Message-ID: <E1GraGp-0006J9-CL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:39

  Modified:    examples/booking  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.45      +8 -87     jboss-seam/examples/booking/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/build.xml,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- build.xml	2 Nov 2006 18:27:36 -0000	1.44
  +++ build.xml	5 Dec 2006 13:23:39 -0000	1.45
  @@ -6,89 +6,10 @@
       <property name="Name"                   value="Seam on JBoss Booking Example"/>
       <property name="example.name"           value="jboss-seam-booking"/>
   	
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    	<include name="classes/tidy.properties"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/persistence.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -    
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -        <exclude name="jboss-beans.xml"/>
  -    	<exclude name="ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="booking-ds.xml"/>
  -    </fileset>
  -    
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="booking-ds.xml"/>
  -    </patternset>
  -
  -    <!-- Test -->
  -    <fileset id="example.resources" dir="resources">
  -        <include name="**/*.*"/>
  -    </fileset>
  -
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="navigation.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -        <include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="import.sql"/>
  -        <include name="META-INF/persistence.xml"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/jboss-beans.xml"/> <!-- TODO: move out of META-INF -->
  -    </fileset>
  -    
       <!-- Overrides -->
  +	<property name="example.seam.lib"       value="yes"/>
  +	<property name="example.facelets.lib"   value="yes"/>
  +	<property name="example.ds"             value="booking-ds.xml"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.eejb.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:23:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/META-INF  ...
Message-ID: <E1GraGp-0006JG-Ge@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:39

  Modified:    examples/booking/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.6       +6 -0      jboss-seam/examples/booking/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.5
  +++ application.xml	5 Dec 2006 13:23:39 -0000	1.6
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   	
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:23:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GraGp-0006JN-MK@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:39

  Modified:    examples/booking/resources/WEB-INF  web.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.32      +2 -0      jboss-seam/examples/booking/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/web.xml,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- web.xml	2 Nov 2006 18:27:36 -0000	1.31
  +++ web.xml	5 Dec 2006 13:23:39 -0000	1.32
  @@ -4,6 +4,8 @@
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
   
  +   <session-config><session-timeout>1</session-timeout></session-config>
  +
      <context-param>
         <param-name>javax.faces.CONFIG_FILES</param-name>
         <param-value>/WEB-INF/navigation.xml</param-value>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:23:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF/lib    ...
Message-ID: <E1GraGq-0006JR-2e@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:40

  Removed:     examples/booking/resources/WEB-INF/lib    el-api.jar
                        el-ri.jar jsf-facelets.jar
  Log:
  migrate to new build


From gavin.king at jboss.com  Tue Dec  5 08:23:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore  ...
Message-ID: <E1GraGq-0006JY-7Y@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:40

  Modified:    examples/dvdstore  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.38      +13 -95    jboss-seam/examples/dvdstore/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/build.xml,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -b -r1.37 -r1.38
  --- build.xml	2 Nov 2006 18:26:03 -0000	1.37
  +++ build.xml	5 Dec 2006 13:23:40 -0000	1.38
  @@ -6,95 +6,13 @@
       <property name="Name"               value="Seam DVD Store Example"/>
       <property name="example.name"       value="jboss-seam-dvd"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="web">
  -        <include name="**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/persistence.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -    	<include name="META-INF/jboss.xml"/>
  -    </fileset>
  -	
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="jbpm*.jar"/>
  -    </fileset>
  -  
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -               dir="resources">
  -    	<include name="*.jpdl.xml"/>
  -    	<exclude name=".gpd.*"/>
  -    	<include name="*.cfg.xml"/>
  -    	<include name="*.xsd"/>
  -        <include name="META-INF/*"/>
  -        <exclude name="META-INF/persistence.xml"/>
  -    	<exclude name="META-INF/ejb-jar.xml"/>
  -    	<exclude name="META-INF/jboss-beans.xml"/>
  -    </zipfileset>
  -
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="navigation.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -        <include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="import.sql"/>
  -        <include name="META-INF/persistence.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/jboss-beans.xml"/> <!-- TODO: move out of META-INF -->
  -    	<include name="*.jpdl.xml"/>
  -    	<exclude name=".gpd.*"/>
  -    	<include name="*.cfg.xml"/>
  -    </fileset>
  -    
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="dvd-ds.xml"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="dvd-ds.xml"/>
  -    </patternset>
  -
  -    <!-- Test -->
  -    <fileset id="example.resources" dir="resources">
  -        <include name="**/*.*"/>
  -    </fileset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="lib"/>
  +	<property name="example.docroot.dir"     value="web"/>
  +    <property name="example.seam.lib"        value="yes"/>
  +	<property name="example.facelets.lib"    value="yes"/>
  +    <property name="example.jbpm.lib"        value="yes"/>
  +	<property name="example.ds"              value="dvd-ds.xml"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.eejb.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:23:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/lib    ...
Message-ID: <E1GraGq-0006Jc-KA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:40

  Removed:     examples/dvdstore/lib    el-api.jar el-ri.jar
                        jsf-facelets.jar
  Log:
  migrate to new build


From gavin.king at jboss.com  Tue Dec  5 08:23:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:23:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/META-INF  ...
Message-ID: <E1GraGq-0006Jj-O5@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:23:40

  Modified:    examples/dvdstore/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.6       +6 -0      jboss-seam/examples/dvdstore/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.5
  +++ application.xml	5 Dec 2006 13:23:40 -0000	1.6
  @@ -19,6 +19,12 @@
   	    <java>jboss-seam.jar</java>
   	</module>
   	<module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
  +	<module>
   	    <java>jbpm-3.1.2.jar</java>
   	</module>
   	
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:24:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:24:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GraHR-0006Jw-T7@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:24:17

  Modified:    examples/booking/resources/WEB-INF  web.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.33      +1 -1      jboss-seam/examples/booking/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/web.xml,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- web.xml	5 Dec 2006 13:23:39 -0000	1.32
  +++ web.xml	5 Dec 2006 13:24:17 -0000	1.33
  @@ -4,7 +4,7 @@
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
   
  -   <session-config><session-timeout>1</session-timeout></session-config>
  +   <!-- session-config><session-timeout>1</session-timeout></session-config-->
   
      <context-param>
         <param-name>javax.faces.CONFIG_FILES</param-name>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:26:12 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:26:12 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces  ...
Message-ID: <E1GraJI-0006NF-R7@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:26:12

  Modified:    examples/icefaces  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.6       +8 -94     jboss-seam/examples/icefaces/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/build.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- build.xml	1 Dec 2006 03:05:16 -0000	1.5
  +++ build.xml	5 Dec 2006 13:26:12 -0000	1.6
  @@ -6,89 +6,9 @@
       <property name="Name"                   value="ICEfaces Booking Example"/>
       <property name="example.name"           value="jboss-seam-icefaces"/>
   	
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    	<include name="classes/tidy.properties"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/persistence.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -    
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -        <exclude name="jboss-beans.xml"/>
  -    	<exclude name="ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="icefaces-ds.xml"/>
  -    </fileset>
  -    
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="icefaces-ds.xml"/>
  -    </patternset>
  -
  -    <!-- Test -->
  -    <fileset id="example.resources" dir="resources">
  -        <include name="**/*.*"/>
  -    </fileset>
  -
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="navigation.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -        <include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="import.sql"/>
  -        <include name="META-INF/persistence.xml"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/jboss-beans.xml"/> <!-- TODO: move out of META-INF -->
  -    </fileset>
  -    
       <!-- Overrides -->
  +	<property name="example.seam.lib"       value="yes"/>
  +	<property name="example.ds"             value="icefaces-ds.xml"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.eejb.classpath"/>
  @@ -96,10 +16,4 @@
   
       <import file="../../build.xml"/>
       
  -    <path id="build.classpath">
  -        <path refid="example.path"/>
  -        <fileset refid="lib"/>
  -        <fileset refid="seam.jar"/>
  -    </path>
  -    
   </project>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:26:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:26:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces/resources/META-INF  ...
Message-ID: <E1GraJI-0006NM-WF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:26:12

  Modified:    examples/icefaces/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.6       +6 -0      jboss-seam/examples/icefaces/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.5
  +++ application.xml	5 Dec 2006 13:26:12 -0000	1.6
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   	
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:26:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:26:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate  ...
Message-ID: <E1GraJJ-0006NV-7Y@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:26:13

  Modified:    examples/hibernate  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.13      +17 -80    jboss-seam/examples/hibernate/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate/build.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- build.xml	10 Jun 2006 07:16:12 -0000	1.12
  +++ build.xml	5 Dec 2006 13:26:13 -0000	1.13
  @@ -6,78 +6,11 @@
       <property name="Name"                   value="Seam on JBoss Hibernate3 Example"/>
       <property name="example.name"           value="jboss-seam-hibernate"/>
       
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="**/*"/>
  -        <exclude name="lib/**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root" dir=".">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -  
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources" dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- Test -->
  -    <fileset id="example.resources" dir="resources">
  -        <include name="**/*.*"/>
  -    </fileset>
  -
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -        <include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="import.sql"/>
  -        <include name="hibernate.cfg.xml"/>
  -        <include name="jboss-beans.xml"/>
  -    </fileset>
  -    
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="hibernate-ds.xml"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="hibernate-ds.xml"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.facelets.lib"    value="yes"/>
  +	<property name="example.ds"              value="hibernate-ds.xml"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.mc.classpath"/>
  @@ -108,10 +41,14 @@
           </copy>
       	
           <jar destfile="${build.dir}/${example.name}.war">
  +            <zipfileset refid="example.tomcat.seam.jar"/>
               <zipfileset refid="example.war.docroot"/>
               <zipfileset refid="example.war.webinf.lib"/>
  -        	<zipfileset refid="example.war.webinf.lib.extra"/>
  -            <zipfileset refid="example.tomcat.seam.jar"/>
  +	        <zipfileset refid="facelets.jar"/>
  +            <zipfileset refid="seam.extra.jar"/>
  +            <zipfileset dir="${lib.dir}" prefix="WEB-INF/lib">
  +                <include name="el-*.jar"/>
  +            </zipfileset>
               <zipfileset dir="${build.dir}/resources">
               	<include name="WEB-INF/**/*.*"/>
               </zipfileset>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog  ...
Message-ID: <E1GraMb-0006QK-HF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:37

  Modified:    examples/blog  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.13      +8 -81     jboss-seam/examples/blog/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/build.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- build.xml	10 Jun 2006 07:14:53 -0000	1.12
  +++ build.xml	5 Dec 2006 13:29:37 -0000	1.13
  @@ -6,84 +6,11 @@
       <property name="Name"                   value="Seam Blog Example"/>
       <property name="example.name"           value="jboss-seam-blog"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/persistence.xml"/>
  -    </fileset>
  -    
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -        <exclude name="jboss-beans.xml"/>
  -    </zipfileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="blog-ds.xml"/>
  -    </fileset>
  -    
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="blog-ds.xml"/>
  -    </patternset>
  -
  -    <!-- Test -->
  -    <fileset id="example.resources" dir="resources">
  -        <include name="**/*.*"/>
  -    </fileset>
  -
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="web.xml"/>
  -        <include name="faces-config.xml"/>
  -    	<include name="components.xml"/>
  -        <include name="pages.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="META-INF/persistence.xml"/>
  -        <include name="import.sql"/>
  -    	<include name="seam.properties"/>
  -        <include name="META-INF/jboss-beans.xml"/> <!-- TODO: move out of META-INF -->
  -    </fileset>
  -    
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.facelets.lib"    value="yes"/>
  +	<property name="example.ds"              value="blog-ds.xml"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.eejb.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/META-INF  ...
Message-ID: <E1GraMb-0006QR-LW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:37

  Modified:    examples/blog/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.4       +7 -0      jboss-seam/examples/blog/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	3 Dec 2006 04:41:33 -0000	1.3
  +++ application.xml	5 Dec 2006 13:29:37 -0000	1.4
  @@ -18,4 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
  +    
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/contactlist  ...
Message-ID: <E1GraMb-0006QY-R8@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:37

  Modified:    examples/contactlist  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.8       +9 -92     jboss-seam/examples/contactlist/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/contactlist/build.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- build.xml	14 Nov 2006 00:18:31 -0000	1.7
  +++ build.xml	5 Dec 2006 13:29:37 -0000	1.8
  @@ -1,103 +1,20 @@
   <?xml version="1.0"?>
   
  -<project name="CRUD" default="deploy" basedir=".">
  +<project name="Contacts" default="deploy" basedir=".">
   
       <!-- Example name -->
       <property name="Name"                   value="Seam Contact List Example"/>
       <property name="example.name"           value="jboss-seam-contactlist"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    	<include name="classes/*.*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="ui.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="META-INF/components.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/persistence.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="application.xml"/>
  -        <include name="jboss-app.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -	
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -          prefix="WEB-INF"
  -             dir="resources/WEB-INF" >
  -       <include name="web.xml"/>
  -       <include name="pages.xml"/>
  -       <include name="components.xml"/>
  -       <include name="faces-config.xml"/>
  -       <include name="navigation.xml"/>
  -       <include name="classes/*.*"/>
  -    </zipfileset>
  -  
  -    <fileset id="example.tomcat.resources"
  -          dir="resources">
  -       <include name="META-INF/components.xml"/>
  -       <include name="META-INF/persistence.xml"/>
  -       <include name="META-INF/ejb-jar.xml"/>
  -       <include name="import.sql"/>
  -    </fileset>
  -  
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
   	<property name="tomcat.conf" value="eejb.conf"/>
     
  -
       <import file="../../build.xml"/>
   
   </project>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/contactlist/resources/META-INF  ...
Message-ID: <E1GraMb-0006Qf-Vg@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:37

  Modified:    examples/contactlist/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.4       +6 -0      jboss-seam/examples/contactlist/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/contactlist/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.3
  +++ application.xml	5 Dec 2006 13:29:37 -0000	1.4
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools  ...
Message-ID: <E1GraMc-0006Qm-4w@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:38

  Modified:    examples/drools  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.2       +9 -84     jboss-seam/examples/drools/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/build.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- build.xml	18 Jun 2006 07:01:30 -0000	1.1
  +++ build.xml	5 Dec 2006 13:29:38 -0000	1.2
  @@ -6,86 +6,11 @@
       <property name="Name"                   value="Seam Drools Example"/>
       <property name="example.name"           value="jboss-seam-drools"/>
   
  -    <!-- WAR -->
  -
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -     </zipfileset>
  -     
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -    	<include name="pageflow.jpdl.xml"/>
  -    	<include name="jbpm.cfg.xml"/>
  -    	<include name="*.drl"/>
  -        <include name="META-INF/*"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../..">
  -        <include name="lib/jbpm*.jar"/>
  -    	<include name="drools/lib/*.jar"/>
  -    </fileset>
  -  
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -    	<include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    	<include name="jbpm.cfg.xml"/>
  -    	<include name="*.drl"/>
  -    	<include name="pageflow.jpdl.xml"/>
  -    </fileset>
  -    
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.jbpm.lib"        value="yes"/>
  +	<property name="example.drools.lib"      value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.mc.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools/resources/META-INF  ...
Message-ID: <E1GraMc-0006Qt-9A@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:38

  Modified:    examples/drools/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.6       +18 -10    jboss-seam/examples/drools/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.5
  +++ application.xml	5 Dec 2006 13:29:38 -0000	1.6
  @@ -22,34 +22,42 @@
   	</module>
   	
   	<module>
  -	    <java>lib/jbpm-3.1.2.jar</java>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
  +
  +	<module>
  +	    <java>jbpm-3.1.2.jar</java>
   	</module>
   	
       <module>
  -	    <java>drools/lib/drools-compiler-3.0.5.jar</java>
  +	    <java>drools-compiler-3.0.5.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/drools-core-3.0.5.jar</java>
  +	    <java>drools-core-3.0.5.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/antlr-2.7.6.jar</java>
  +	    <java>antlr-2.7.6.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/antlr-3.0ea8.jar</java>
  +	    <java>antlr-3.0ea8.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/commons-jci-core-1.0-406301.jar</java>
  +	    <java>commons-jci-core-1.0-406301.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/commons-jci-janino-2.4.3.jar</java>
  +	    <java>commons-jci-janino-2.4.3.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/commons-lang-2.1.jar</java>
  +	    <java>commons-lang-2.1.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/janino-2.4.3.jar</java>
  +	    <java>janino-2.4.3.jar</java>
   	</module>
       <module>
  -	    <java>drools/lib/stringtemplate-2.3b6.jar</java>
  +	    <java>stringtemplate-2.3b6.jar</java>
   	</module>
  +    
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces/resources/WEB-INF/lib   ...
Message-ID: <E1GraMc-0006Qx-HD@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:38

  Removed:     examples/icefaces/resources/WEB-INF/lib   el-api.jar
                        el-ri.jar
  Log:
  migrate to new build


From gavin.king at jboss.com  Tue Dec  5 08:29:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/issues  ...
Message-ID: <E1GraMc-0006R4-KR@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:38

  Modified:    examples/issues  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.22      +6 -80     jboss-seam/examples/issues/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/build.xml,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- build.xml	10 Jun 2006 07:20:03 -0000	1.21
  +++ build.xml	5 Dec 2006 13:29:38 -0000	1.22
  @@ -6,88 +6,14 @@
       <property name="Name"               value="Seam Issue Tracker Example"/>
       <property name="example.name"       value="jboss-seam-issues"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -        <zipfileset id="example.war.webinf.lib.extra" 
  -                prefix="WEB-INF/lib"
  -                   dir=".">
  -            <include name="_NONE_"/>
  -        </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/persistence.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -	
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -  
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -    	<exclude name="ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="web.xml"/>
  -        <include name="faces-config.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="events.xml"/>
  -    	<include name="components.xml"/>
  -    	<include name="classes/messages.properties"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="import.sql"/>
  -        <include name="META-INF/persistence.xml"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/jboss-beans.xml"/> <!-- TODO: move out of META-INF -->
  -    </fileset>
  -    
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="issues-ds.xml"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="issues-ds.xml"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.ds"             value="issues-ds.xml"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
  +    <property name="test.classpath"         value="test.eejb.classpath"/>
       <property name="tomcat.conf" value="eejb.conf"/>
   	
  +	
       <import file="../../build.xml"/>
       
   </project>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/issues/resources/META-INF  ...
Message-ID: <E1GraMc-0006RB-P4@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:38

  Modified:    examples/issues/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.5       +7 -2      jboss-seam/examples/issues/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/issues/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.4
  +++ application.xml	5 Dec 2006 13:29:38 -0000	1.5
  @@ -4,7 +4,6 @@
                xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
                version="5">
                
  -<application>
   	<display-name>Seam Issue Tracker</display-name>
   
   	<module>
  @@ -19,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   	
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages  ...
Message-ID: <E1GraMc-0006RI-Tp@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:38

  Modified:    examples/messages  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.12      +7 -85     jboss-seam/examples/messages/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/build.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- build.xml	10 Jun 2006 07:25:08 -0000	1.11
  +++ build.xml	5 Dec 2006 13:29:38 -0000	1.12
  @@ -6,87 +6,9 @@
       <property name="Name"                   value="Seam Message List Example"/>
       <property name="example.name"           value="jboss-seam-messages"/>
   
  -    <!-- WAR -->
  -
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               refid="ui.seam.jar"/>
  -
  -    <!-- EJB3 -->
  -
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/persistence.xml"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -  
  -    <!-- Tomcat build -->
  -	
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="web.xml"/>
  -    	<include name="components.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    	<include name="import.sql"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -    	<include name="META-INF/persistence.xml"/>
  -    </fileset>
  -    
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/numberguess  ...
Message-ID: <E1GraMd-0006RP-1x@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:39

  Modified:    examples/numberguess  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.16      +8 -79     jboss-seam/examples/numberguess/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/build.xml,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- build.xml	16 Nov 2006 23:19:25 -0000	1.15
  +++ build.xml	5 Dec 2006 13:29:39 -0000	1.16
  @@ -6,81 +6,10 @@
       <property name="Name"                   value="Seam Numberguess Example"/>
       <property name="example.name"           value="jboss-seam-numberguess"/>
   
  -    <!-- WAR -->
  -
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -     </zipfileset>
  -     
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               refid="ui.seam.jar"/>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -    	<include name="*.jpdl.xml"/>
  -    	<include name="jbpm.cfg.xml"/>
  -        <include name="META-INF/*"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="jbpm*.jar"/>
  -    </fileset>
  -  
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -    	<include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    	<include name="jbpm.cfg.xml"/>
  -    	<include name="pageflow.jpdl.xml"/>
  -    </fileset>
  -    
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.jbpm.lib"        value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.mc.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/registration  ...
Message-ID: <E1GraMd-0006RW-6e@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:39

  Modified:    examples/registration  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.27      +6 -89     jboss-seam/examples/registration/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/registration/build.xml,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- build.xml	28 Sep 2006 00:25:33 -0000	1.26
  +++ build.xml	5 Dec 2006 13:29:39 -0000	1.27
  @@ -6,96 +6,13 @@
       <property name="Name"                   value="Seam Registration Example"/>
       <property name="example.name"           value="jboss-seam-registration"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="ui.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/persistence.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -    	<exclude name="META-INF/ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -	
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -          prefix="WEB-INF"
  -             dir="resources/WEB-INF" >
  -       <include name="web.xml"/>
  -       <include name="components.xml"/>
  -       <include name="faces-config.xml"/>
  -    </zipfileset>
  -  
  -    <fileset id="example.tomcat.resources"
  -          dir="resources">
  -       <include name="seam.properties"/>
  -       <include name="META-INF/persistence.xml"/>
  -  	   <include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -  
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
   	<property name="tomcat.conf" value="eejb.conf"/>
     
  -
       <import file="../../build.xml"/>
   
   </project>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay  ...
Message-ID: <E1GraMd-0006Rd-CQ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:39

  Modified:    examples/seampay  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.2       +9 -85     jboss-seam/examples/seampay/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/build.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- build.xml	20 Oct 2006 16:51:26 -0000	1.1
  +++ build.xml	5 Dec 2006 13:29:39 -0000	1.2
  @@ -1,96 +1,20 @@
   <?xml version="1.0"?>
   
  -<project name="CRUD" default="deploy" basedir=".">
  +<project name="Payments" default="deploy" basedir=".">
   
       <!-- Example name -->
       <property name="Name"                   value="Seam Payment Example"/>
       <property name="example.name"           value="jboss-seam-pay"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -    	<include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/persistence.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            prefix="META-INF"
  -               dir="resources/META-INF">
  -        <include name="*"/>
  -        <exclude name="persistence.xml"/>
  -    	<exclude name="META-INF/ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -	
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -          prefix="WEB-INF"
  -             dir="resources/WEB-INF" >
  -       <include name="web.xml"/>
  -       <include name="pages.xml"/>
  -       <include name="components.xml"/>
  -       <include name="faces-config.xml"/>
  -    </zipfileset>
  -  
  -    <fileset id="example.tomcat.resources"
  -          dir="resources">
  -       <include name="seam.properties"/>
  -       <include name="META-INF/persistence.xml"/>
  -  	   <include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -  
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
   	<property name="tomcat.conf" value="eejb.conf"/>
     
  -
       <import file="../../build.xml"/>
   
   </project>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/resources/META-INF  ...
Message-ID: <E1GraMd-0006Rk-FU@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:39

  Modified:    examples/seampay/resources/META-INF  application.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.4       +6 -0      jboss-seam/examples/seampay/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	3 Dec 2006 04:41:36 -0000	1.3
  +++ application.xml	5 Dec 2006 13:29:39 -0000	1.4
  @@ -18,5 +18,11 @@
       <module>
           <java>jboss-seam.jar</java>
       </module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:29:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:29:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/todo  ...
Message-ID: <E1GraMd-0006Rr-Jz@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:29:39

  Modified:    examples/todo  build.xml
  Log:
  migrate to new build
  
  Revision  Changes    Path
  1.18      +8 -82     jboss-seam/examples/todo/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/todo/build.xml,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- build.xml	10 Jun 2006 07:24:52 -0000	1.17
  +++ build.xml	5 Dec 2006 13:29:39 -0000	1.18
  @@ -6,84 +6,10 @@
       <property name="Name"                   value="Seam Todo List Example"/>
       <property name="example.name"           value="jboss-seam-todo"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -     </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="resources/WEB-INF">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -	
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               refid="ui.seam.jar"/>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -    	    dir="resources">
  -    	<include name="todo.jpdl.xml"/>
  -    	<include name="jbpm.cfg.xml"/>
  -    	<include name="hibernate.cfg.xml"/>
  -        <include name="META-INF/*"/>
  -    	<exclude name="META-INF/jboss-beans.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="jbpm*.jar"/>
  -    </fileset>
  -  
  -    <!-- Tomcat build -->
  -    <zipfileset id="example.tomcat.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="faces-config.xml"/>
  -        <include name="pages.xml"/>
  -    	<include name="components.xml"/>
  -        <include name="web.xml"/>
  -    </zipfileset>
  -    
  -    <fileset id="example.tomcat.resources"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    	<include name="jbpm.cfg.xml"/>
  -        <include name="hibernate.cfg.xml"/>
  -    	<include name="todo.jpdl.xml"/>
  -        <include name="META-INF/jboss-beans.xml"/> <!-- TODO: move out of META-INF -->
  -    </fileset>
  -    
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.jbpm.lib"        value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.mc.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:31:06 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:31:06 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GraO2-0006Ue-Ld@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:31:06

  Modified:    jboss-seam  build.xml
  Log:
  the new build
  
  Revision  Changes    Path
  1.115     +167 -37   jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.114
  retrieving revision 1.115
  diff -u -b -r1.114 -r1.115
  --- build.xml	30 Nov 2006 10:24:51 -0000	1.114
  +++ build.xml	5 Dec 2006 13:31:06 -0000	1.115
  @@ -74,6 +74,12 @@
       <property name="javac.debug"          value="true"/>
       <property name="javac.deprecation"    value="false"/>
       
  +	<property name="example.docroot.dir"     value="view"/>
  +	<property name="example.resources.dir"   value="resources"/>
  +	<property name="example.webinf.dir"      value="${example.resources.dir}/WEB-INF"/>
  +	<property name="example.webinf.lib.dir"  value="${example.resources.dir}/WEB-INF/lib"/>
  +	<property name="example.ds"              value="${example.name}-ds.xml"/>
  +
       <path id="example.path" />
       
       <fileset id="lib" 
  @@ -81,26 +87,118 @@
           description="compile-time dependencies">
           <include name="lib/*.jar"/>
           <include name="drools/lib/*.jar"/>
  -      <include name="facelets/lib/*.jar"/>
       </fileset>
       
  -    <fileset id="seam.jar" 
  +    <zipfileset id="seam.jar" 
               dir="${imported.basedir}"
               description="the main Seam jar">
  -        <include name="${name}.jar" />
  -    </fileset>
  +        <include name="${name}.jar"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="el.jar" 
  +               dir="${lib.dir}"
  +            description="the unified EL jars">
  +        <include name="el-*.jar" />
  +    </zipfileset>
  +	
  +    <zipfileset id="jbpm.jar" 
  +               dir="${lib.dir}" 
  +            description="the jBPM jar">
  +        <include name="jbpm*.jar" if="example.jbpm.lib"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="drools.jar" 
  +               dir="${drools.lib.dir}" 
  +            description="the Drools jars">
  +    	<include name="*.jar" if="example.drools.lib"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="cache.jar" 
  +               dir="${lib.dir}" 
  +            description="the JBoss Cache and JGroups jars">
  +        <include name="jboss-cache-jdk50.jar" if="example.cache.lib"/>
  +        <include name="jboss-aop-jdk50.jar" if="example.cache.lib"/>
  +        <include name="jgroups.jar" if="example.cache.lib"/>
  +    </zipfileset>
       
  -    <fileset id="extra.seam.jar" 
  +    <zipfileset id="seam.extra.jar" 
               dir="${imported.basedir}"
  -            description="the Seam debug and UI jars">
  -        <include name="${name}-ui.jar" />
  -        <include name="${name}-debug.jar" />
  +    	    prefix="WEB-INF/lib"
  +            description="the extra Seam jars">
  +        <include name="jboss-seam-ui.jar" if="example.seam.lib"/>
  +    	<include name="jboss-seam-debug.jar" if="example.seam.lib"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="facelets.jar" 
  +            dir="${lib.dir}"
  +    	 prefix="WEB-INF/lib"
  +            description="the facelets jar">
  +        <include name="jsf-facelets.jar" if="example.facelets.lib"/>
  +    </zipfileset>
  +    
  +    <fileset id="example.resources" 
  +    	    dir="${example.resources.dir}">
  +        <include name="**/*.*"/>
       </fileset>
       
  -    <fileset id="ui.seam.jar" 
  -            dir="${imported.basedir}"
  -            description="the Seam UI jar">
  -        <include name="${name}-ui.jar" />
  +    <zipfileset id="example.war.docroot"
  +               dir="${example.docroot.dir}">
  +        <include name="**/*"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="example.war.webinf"
  +            prefix="WEB-INF"
  +               dir="${example.webinf.dir}" >
  +        <patternset refid="meta.files"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="example.war.webinf.lib"
  +            prefix="WEB-INF/lib"
  +               dir="${example.webinf.lib.dir}">
  +        <include name="*.jar"/>
  +    </zipfileset>
  +
  +    <fileset id="example.ejb3.resources"
  +            dir="${example.resources.dir}">
  +        <include name="import.sql"/>
  +        <include name="seam.properties"/>
  +        <include name="META-INF/persistence.xml"/>
  +    	<include name="META-INF/ejb-jar.xml"/>
  +    	<include name="META-INF/components.xml"/>
  +    	<include name="META-INF/jboss.xml"/>
  +    </fileset>
  +    
  +    <zipfileset id="example.ear.resources"
  +               dir="${example.resources.dir}">
  +        <include name="META-INF/application.xml"/>
  +    	<include name="META-INF/jboss-app.xml"/>
  +    	<include name="treecache.xml"/>
  +    	<include name="*.jpdl.xml"/>
  +    	<exclude name=".gpd.*"/>
  +    	<include name="*.cfg.xml"/>
  +    	<include name="*.xsd"/>
  +    	<include name="*.drl"/>
  +    </zipfileset>
  +
  +    <fileset id="example.deploy"
  +            dir="${example.resources.dir}">
  +        <include name="${example.ds}"/>
  +    </fileset>
  +    
  +	<patternset id="example.undeploy">
  +        <include name="${example.ds}"/>
  +    </patternset>
  +    
  +    <zipfileset id="example.tomcat.war.webinf"
  +            prefix="WEB-INF"
  +               dir="resources/WEB-INF" >
  +        <include name="**/*.*"/>
  +    </zipfileset>
  +    
  +    <fileset id="example.tomcat.resources"
  +            dir="resources">
  +        <include name="**/*.*"/>
  +        <exclude name="WEB-INF/**/*.*"/>
       </fileset>
       
       <zipfileset id="example.tomcat.lib" 
  @@ -108,7 +206,12 @@
                  dir="${lib.dir}"
                  description="run-time dependencies for tomcat deployment">
           <include name="*.jar"/>
  +		<exclude name="jsf-facelets*.jar"/>
  +		<exclude name="jboss-*-jdk50.jar"/>
  +		<exclude name="jgroups*.jar"/>
  +		<exclude name="jbpm*.jar"/>
           <exclude name="servlet-api.jar"/>
  +    	<exclude name="ant*.jar"/>
           <exclude name="javax.servlet.jsp.jar"/>
           <exclude name="testng-*.jar"/>
       </zipfileset>
  @@ -116,7 +219,26 @@
       <zipfileset id="example.tomcat.seam.jar" 
               prefix="WEB-INF/lib"
               dir="${imported.basedir}">
  -        <include name="${name}.jar" />
  +        <include name="${name}.jar"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="example.tomcat.drools.jar" 
  +    	    prefix="WEB-INF/lib"
  +            dir="${drools.lib.dir}">
  +    	<include name="${example.drools.lib}"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="example.tomcat.cache.jar" 
  +    	    prefix="WEB-INF/lib"
  +            dir="${lib.dir}">
  +        <include name="${example.cache.lib}"/>
  +        <include name="${example.jgroups.lib}"/>
  +    </zipfileset>
  +    
  +    <zipfileset id="example.tomcat.jbpm.jar" 
  +    	    prefix="WEB-INF/lib"
  +            dir="${lib.dir}">
  +    	<include name="${example.jbpm.lib}"/>
       </zipfileset>
       
       <path id="build.classpath">
  @@ -819,7 +941,8 @@
           <jar destfile="${build.dir}/${example.name}.war">
               <zipfileset refid="example.war.docroot"/>
               <zipfileset refid="example.war.webinf.lib"/>
  -            <zipfileset refid="example.war.webinf.lib.extra"/>
  +        	<zipfileset refid="facelets.jar"/>
  +        	<zipfileset refid="seam.extra.jar"/>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
               </zipfileset>
  @@ -830,13 +953,17 @@
       <target name="ejb3" depends="compile">
           <jar jarfile="${build.dir}/${example.name}.jar">
               <fileset refid="example.classes"/>
  -            <fileset refid="example.ejb3.root"/>
  +            <fileset refid="example.ejb3.resources"/>
           </jar>
       </target>
   
       <target name="ear" depends="ejb3, war">
           <jar destfile="${build.dir}/${example.name}.ear">
               <fileset refid="seam.jar"/>
  +        	<fileset refid="el.jar"/>
  +            <fileset refid="drools.jar"/>
  +            <fileset refid="cache.jar"/>
  +            <fileset refid="jbpm.jar"/>
               <zipfileset dir="${build.dir}">
                   <include name="${example.name}.jar"/>
               </zipfileset>
  @@ -844,7 +971,6 @@
                   <include name="${example.name}.war"/>
               </zipfileset>
               <zipfileset refid="example.ear.resources"/>
  -            <fileset refid="example.ejb3.lib"/>
           </jar>
       </target>
   
  @@ -895,9 +1021,13 @@
           <jar destfile="${build.dir}/${example.name}.war" duplicate="preserve">
               <zipfileset refid="example.tomcat.lib"/>
               <zipfileset refid="example.tomcat.seam.jar"/>
  +        	<zipfileset refid="example.tomcat.drools.jar"/>
  +        	<zipfileset refid="example.tomcat.cache.jar"/>
  +        	<zipfileset refid="example.tomcat.jbpm.jar"/>
               <zipfileset refid="example.war.docroot"/>
               <zipfileset refid="example.war.webinf.lib"/>
  -            <zipfileset refid="example.war.webinf.lib.extra"/>
  +        	<zipfileset refid="facelets.jar"/>
  +        	<zipfileset refid="seam.extra.jar"/>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
               </zipfileset>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 08:51:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:51:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms   ...
Message-ID: <E1GraiD-0006qv-9e@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:51:57

  Removed:     examples/jbms   build.xml readme.txt
  Log:
  get rid of mail example


From gavin.king at jboss.com  Tue Dec  5 08:51:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:51:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/resources/META-INF     ...
Message-ID: <E1GraiD-0006qz-CW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:51:57

  Removed:     examples/jbms/resources/META-INF     application.xml
                        ejb-jar.xml jboss-app.xml persistence.xml
  Log:
  get rid of mail example


From gavin.king at jboss.com  Tue Dec  5 08:51:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:51:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/resources/WEB-INF   ...
Message-ID: <E1GraiD-0006r3-HG@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:51:57

  Removed:     examples/jbms/resources/WEB-INF   faces-config.xml web.xml
  Log:
  get rid of mail example


From gavin.king at jboss.com  Tue Dec  5 08:51:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:51:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/src/org/jboss/seam/example/jbms
	...
Message-ID: <E1GraiD-0006r7-Ll@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:51:57

  Removed:     examples/jbms/src/org/jboss/seam/example/jbms   
                        Register.java RegisterAction.java User.java
  Log:
  get rid of mail example


From gavin.king at jboss.com  Tue Dec  5 08:51:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:51:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/view    ...
Message-ID: <E1GraiD-0006rB-Px@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:51:57

  Removed:     examples/jbms/view    index.html register.jsp registered.jsp
  Log:
  get rid of mail example


From gavin.king at jboss.com  Tue Dec  5 08:53:22 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 08:53:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/jbms/resources  ...
Message-ID: <E1Graja-0006rX-T3@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 08:53:22

  Removed:     examples/jbms/resources  seam.properties
  Log:
  get rid of mail example


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 09:06:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 09:06:46 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1705 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin/postoffice
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/tools/jmx
Message-ID: <E1GrawY-0007Gl-4v@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-05 09:06:32 -0500 (Tue, 05 Dec 2006)
New Revision: 1705

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
Log:
Various fixes to get things running



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -70,8 +70,8 @@
    // Map<uniqueName<String> - ServerConnectionFactoryEndpoint>
    protected Map endpoints;
 
-   // Map<uniqueName<String> - ClusteredClientConnectionFactoryDelegate>
-   protected Map clusteredDelegates;
+   // Map<uniqueName<String> - ClientConnectionFactoryDelegate> (not just clustered delegates)
+   protected Map delegates;
    
    protected Replicator replicator;
    
@@ -81,7 +81,7 @@
    {
       this.serverPeer = serverPeer;
       endpoints = new HashMap();
-      clusteredDelegates = new HashMap();
+      delegates = new HashMap();
    }
    
    // ConnectionFactoryManager implementation -----------------------
@@ -98,6 +98,8 @@
                                                       boolean clustered)
       throws Exception
    {
+      log.info("Registering connection factory with name " + uniqueName + " bindings " + jndiBindings);
+      
       int id = serverPeer.getNextObjectID();
       Version version = serverPeer.getVersion();
 
@@ -107,42 +109,51 @@
                                              defaultTempQueueFullSize,
                                              defaultTempQueuePageSize,
                                              defaultTempQueueDownCacheSize);
-      endpoints.put(uniqueName, endpoint);
-
-      JMSDispatcher.instance.
-         registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
-
-      ClientConnectionFactoryDelegate localDelegate =
-         new ClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
-
-      if (!clustered)
+      endpoints.put(uniqueName, endpoint);   
+      
+      ClientConnectionFactoryDelegate delegate = null;
+      
+      boolean replicateChanges = false;
+      
+      if (clustered)
       {
-         rebindConnectionFactory(initialContext, jndiBindings, localDelegate);
-         return;
+         setupReplicator();
+         
+         if (replicator != null)
+         {                                             
+            //Replicator might still be null since we might be deploying a clustered cf in a non clustered
+            //post office (which is ok)
+            delegate = new ClusteredClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
+         }
       }
-
-      // We are clustered, we need to propagate the local delegate across the cluster.
-
-      setupReplicator();
-
-      if (replicator == null)
+      
+      if (delegate == null)
       {
-         return;
+         //Local
+         delegate = new ClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
       }
+      
+      delegates.put(uniqueName, delegate);
+      
+      //Now bind it in JNDI
+      rebindConnectionFactory(initialContext, jndiBindings, delegate);
+      
+      if (replicateChanges)
+      {
+         // We are clustered, we need to propagate the local delegate across the cluster.
 
-      // Create a "hollow" clustered delegate ...
+         // ... and then update it (and the clustered delegate on every node, while we're at it) by
+         // replicating the local delegate across the cluster. This way, the clustred delegates on each
+         // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
+         // will rebind updated ConnectionFactories in JNDI.
+         // This will update the local node too
 
-      ClusteredClientConnectionFactoryDelegate clusteredDelegate =
-         new ClusteredClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
-
-      clusteredDelegates.put(uniqueName, clusteredDelegate);
-
-      // ... and then update it (and the clustered delegate on every node, while we're at it) by
-      // replicating the local delegate across the cluster. This way, the clustred delegates on each
-      // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
-      // will rebind updated ConnectionFactories in JNDI.
-
-      replicator.put(CF_PREFIX + uniqueName, localDelegate);
+         replicator.put(CF_PREFIX + uniqueName, delegate);
+      }
+            
+      //Registering with the dispatcher should always be the last thing otherwise a client could use
+      //a partially initialised object
+      JMSDispatcher.instance.registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
    }
    
    public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception
@@ -169,7 +180,7 @@
       }
       
       ClientConnectionFactoryDelegate delegate =
-         (ClientConnectionFactoryDelegate)clusteredDelegates.remove(uniqueName);
+         (ClientConnectionFactoryDelegate)delegates.remove(uniqueName);
       
       if (delegate == null)
       {
@@ -245,7 +256,7 @@
             String uniqueName = sKey.substring(CF_PREFIX.length());
             
             ClusteredClientConnectionFactoryDelegate clusteredDelegate =
-               (ClusteredClientConnectionFactoryDelegate)clusteredDelegates.get(uniqueName);
+               (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
             
             if (clusteredDelegate == null)
             {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -65,6 +65,7 @@
           
    private String officeName;
    
+   //This lock protects the condition and name maps
    protected ReadWriteLock lock;
    
    protected MessageStore ms;     
@@ -73,7 +74,7 @@
    
    protected TransactionRepository tr;
    
-   protected int nodeId;
+   protected int currentNodeId;
    
    //Map <node id, Map < queue name, binding > >
    protected Map nameMaps;
@@ -104,7 +105,7 @@
        
       conditionMap = new LinkedHashMap(); 
       
-      this.nodeId = nodeId;
+      this.currentNodeId = nodeId;
       
       this.officeName = officeName;
       
@@ -172,7 +173,7 @@
       try
       {         
          //We currently only allow one binding per name per node
-         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
+         Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
          
          Binding binding = null;
          
@@ -186,7 +187,7 @@
             throw new IllegalArgumentException("Binding already exists for name " + queue.getName());
          }
                  
-         binding = new DefaultBinding(nodeId, condition, queue, false);
+         binding = new DefaultBinding(currentNodeId, condition, queue, false);
          
          addBinding(binding);
                
@@ -217,13 +218,13 @@
 
       try
       {         
-         Binding binding = removeBinding(nodeId,queueName);
+         Binding binding = removeBinding(currentNodeId,queueName);
       
          if (binding.getQueue().isRecoverable())
          {
             //Need to remove from db too
             
-            deleteBinding(nodeId, binding.getQueue().getName());
+            deleteBinding(currentNodeId, binding.getQueue().getName());
          }
          
          binding.getQueue().removeAllReferences();         
@@ -270,7 +271,7 @@
     */
    protected Binding internalGetBindingForQueueName(String queueName)
    {
-      Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
+      Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
 
       Binding binding = null;
 
@@ -339,7 +340,7 @@
                Binding binding = (Binding)iter.next();
                
                //Sanity check
-               if (binding.getNodeId() != this.nodeId)
+               if (binding.getNodeId() != this.currentNodeId)
                {
                   throw new IllegalStateException("Local post office has foreign bindings!");
                }
@@ -407,7 +408,7 @@
             {
                Binding binding = (Binding)iter.next();
                
-               if (!localOnly || (binding.getNodeId() == this.nodeId))
+               if (!localOnly || (binding.getNodeId() == this.currentNodeId))
                {
                   list.add(binding);
                }
@@ -499,7 +500,7 @@
     protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
     {
         Queue queue;
-        if (nodeId == this.nodeId)
+        if (nodeId == this.currentNodeId)
         {
            QueuedExecutor executor = (QueuedExecutor)pool.get();
 
@@ -532,7 +533,7 @@
          String filterString = binding.getQueue().getFilter() == null ? null : binding.getQueue().getFilter().getFilterString();
                   
          ps.setString(1, this.officeName);
-         ps.setInt(2, this.nodeId);
+         ps.setInt(2, this.currentNodeId);
          ps.setString(3, binding.getQueue().getName());
          ps.setString(4, binding.getCondition());         
          if (filterString != null)
@@ -564,7 +565,7 @@
    
    protected boolean deleteBinding(int parameterNodeId, String queueName) throws Exception
    {
-      if (parameterNodeId<0) parameterNodeId=this.nodeId;
+      if (parameterNodeId<0) parameterNodeId=this.currentNodeId;
       Connection conn = null;
       PreparedStatement ps  = null;
       TransactionWrapper wrap = new TransactionWrapper();

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -21,7 +21,6 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
@@ -40,8 +39,10 @@
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
+
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
+
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -74,6 +75,8 @@
 import org.jgroups.blocks.RequestHandler;
 import org.w3c.dom.Element;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * 
  * A DefaultClusteredPostOffice
@@ -99,6 +102,7 @@
    private boolean failAfterCommit;
    
    private boolean failHandleResult;
+   //End of failure testing attributes
      
    private boolean trace = log.isTraceEnabled();
 
@@ -152,27 +156,11 @@
    private Map failedBindings;
 
    private StatsSender statsSender;
+   
+   private ReplicationListener nodeAddressMapListener;
 
    private boolean started;
      
-   public DefaultClusteredPostOffice()
-   {        
-      init();
-   }
-   
-   private void init()
-   {
-      holdingArea = new HashMap();
-      
-      replicatedData = new HashMap();      
-      
-      replicationListeners = new HashSet();
-      
-      failoverMap = new LinkedHashMap();
-      
-      leftSet = new HashSet();
-   }
-   
    /*
     * Constructor using Element for configuration
     */
@@ -275,7 +263,15 @@
       
       statsSender = new StatsSender(this, statsSendPeriod);
       
-      init();
+      holdingArea = new HashMap();
+      
+      replicatedData = new HashMap();      
+      
+      replicationListeners = new HashSet();
+      
+      failoverMap = new LinkedHashMap();
+      
+      leftSet = new HashSet();
    }
 
    // MessagingComponent overrides
@@ -309,10 +305,16 @@
       MessageListener cml = new ControlMessageListener();
       MembershipListener ml = new ControlMembershipListener();
       RequestHandler rh = new PostOfficeRequestHandler();
+      
+      //Register as a listener for nodeid-adress mapping events
+      nodeAddressMapListener = new NodeAddressMapListener();
+      
+      registerListener(nodeAddressMapListener);
 
       this.controlMessageDispatcher = new MessageDispatcher(syncChannel, cml, ml, rh, true);
 
       Receiver r = new DataReceiver();
+      
       asyncChannel.setReceiver(r);
 
       syncChannel.connect(groupName);
@@ -320,7 +322,7 @@
       asyncChannel.connect(groupName);
       
       super.start();
-
+            
       Address syncAddress = syncChannel.getLocalAddress();
       
       Address asyncAddress = asyncChannel.getLocalAddress();
@@ -329,7 +331,7 @@
       
       put(ADDRESS_INFO_KEY, info);
 
-      verifyMembership(null,this.currentView);
+      //verifyMembership(null, this.currentView);
 
       statsSender.start();
       
@@ -346,8 +348,11 @@
       }
 
       syncSendRequest(new LeaveClusterRequest(this.getNodeId()));
+      
       super.stop(sendNotification);
       
+      unregisterListener(nodeAddressMapListener);
+      
       statsSender.stop();
          
       syncChannel.close();
@@ -365,10 +370,10 @@
    {
       if (trace)
       {
-         log.trace(this.nodeId + " binding clustered queue: " + queue + " with condition: " + condition);
+         log.trace(this.currentNodeId + " binding clustered queue: " + queue + " with condition: " + condition);
       }
         
-      if (queue.getNodeId() != this.nodeId)
+      if (queue.getNodeId() != this.currentNodeId)
       {
           log.warn("queue.getNodeId is not this node");
          //throw new IllegalArgumentException("Queue node id does not match office node id");
@@ -386,7 +391,7 @@
       throws Exception
    {
       BindRequest request =
-         new BindRequest(this.nodeId, queue.getName(), condition, queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
+         new BindRequest(this.currentNodeId, queue.getName(), condition, queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
                          binding.getQueue().getChannelID(), queue.isRecoverable(), binding.isFailed());
 
       syncSendRequest(request);
@@ -396,12 +401,12 @@
    {
       if (trace)
       {
-         log.trace(this.nodeId + " unbind clustered queue: " + queueName);
+         log.trace(this.currentNodeId + " unbind clustered queue: " + queueName);
       }
       
       Binding binding = (Binding)super.unbindQueue(queueName);
       
-      UnbindRequest request = new UnbindRequest(this.nodeId, queueName);
+      UnbindRequest request = new UnbindRequest(this.currentNodeId, queueName);
       
       syncSendRequest(request);
       
@@ -412,7 +417,7 @@
    {
       if (trace)
       {
-         log.trace(this.nodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx);
+         log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx);
       }
       
       if (ref == null)
@@ -451,7 +456,7 @@
                   startInternalTx = true;
                   if (trace)
                   {
-                     log.trace(this.nodeId + " Starting internal transaction since more than one durable sub or remote durable subs");
+                     log.trace(this.currentNodeId + " Starting internal transaction since more than one durable sub or remote durable subs");
                   }
                }
             }                        
@@ -485,7 +490,7 @@
                   
                   if (trace)
                   {
-                     log.trace(this.nodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
+                     log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
                                queue.getNodeId() +" local:" + queue.isLocal());
                   }
                   
@@ -527,14 +532,14 @@
                {
                   if (numberRemote == 1)
                   {
-                     if (trace) { log.trace(this.nodeId + " unicasting message to " + lastNodeId); }
+                     if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
                      
                      //Unicast - only one node is interested in the message                                        
                      asyncSendRequest(new MessageRequest(condition, ref.getMessage(), null), lastNodeId);
                   }
                   else
                   {
-                     if (trace) { log.trace(this.nodeId + " multicasting message to group"); }
+                     if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
                      
                      //Multicast - more than one node is interested
                      asyncSendRequest(new MessageRequest(condition, ref.getMessage(), queueNameNodeIdMap));
@@ -546,7 +551,7 @@
                   
                   if (callback == null)
                   {
-                     callback = new CastMessagesCallback(nodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
+                     callback = new CastMessagesCallback(currentNodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
                      
                      //This callback MUST be executed first
                      
@@ -593,48 +598,45 @@
    
    public int getFailoverNodeID(int nodeId)
    {
-      Integer failoverNode = (Integer)failoverMap.get(new Integer(nodeId));
-      
-      if (failoverNode == null)
-      {
-         return nodeId;
+      synchronized (failoverMap)
+      {         
+         Integer failoverNode = (Integer)failoverMap.get(new Integer(nodeId));
+         
+         if (failoverNode == null)
+         {
+            return nodeId;
+         }
+         
+         return failoverNode.intValue();
       }
-      
-      return failoverNode.intValue();
    }
 
    // Replicator implementation --------------------------------------------------------------------------
    
    public Map get(Serializable key) throws Exception
    {
-      lock.readLock().acquire();
-      
-      try
-      {
+      synchronized (replicatedData)
+      {         
          Map m = (Map)replicatedData.get(key);
-         
+            
          return m == null ? Collections.EMPTY_MAP : Collections.unmodifiableMap(m);
       }
-      finally
-      {
-         lock.readLock().release();
-      }
    }
 
    public void put(Serializable key, Serializable replicant) throws Exception
    {
-      putReplicantLocally(nodeId, key, replicant);
+      putReplicantLocally(currentNodeId, key, replicant);
       
-      PutReplicantRequest request = new PutReplicantRequest(nodeId, key, replicant);
+      PutReplicantRequest request = new PutReplicantRequest(currentNodeId, key, replicant);
       
       syncSendRequest(request);
    }
    
    public boolean remove(Serializable key) throws Exception
    {
-      if (removeReplicantLocally(this.nodeId, key))
+      if (removeReplicantLocally(this.currentNodeId, key))
       {      
-         RemoveReplicantRequest request = new RemoveReplicantRequest(this.nodeId, key);
+         RemoveReplicantRequest request = new RemoveReplicantRequest(this.currentNodeId, key);
          
          syncSendRequest(request);
          
@@ -648,20 +650,26 @@
    
    public void registerListener(ReplicationListener listener)
    {
-      if (replicationListeners.contains(listener))
+      synchronized (replicationListeners)
       {
-         throw new IllegalArgumentException("Listener " + listener + " is already registered");
+         if (replicationListeners.contains(listener))
+         {
+            throw new IllegalArgumentException("Listener " + listener + " is already registered");
+         }
+         replicationListeners.add(listener);
       }
-      replicationListeners.add(listener);
    }
    
    public void unregisterListener(ReplicationListener listener)
    {
-      boolean removed = replicationListeners.remove(listener);
-      
-      if (!removed)
+      synchronized (replicationListeners)
       {
-         throw new IllegalArgumentException("Cannot find listener " + listener + " to remove");
+         boolean removed = replicationListeners.remove(listener);
+         
+         if (!removed)
+         {
+            throw new IllegalArgumentException("Cannot find listener " + listener + " to remove");
+         }
       }
    }
     
@@ -669,16 +677,10 @@
    
    public void handleNodeLeft(int nodeId) throws Exception
    {
-      lock.writeLock().acquire();
-      
-      try
+      synchronized (leftSet)
       {
          leftSet.add(new Integer(nodeId));
       }
-      finally
-      {
-         lock.writeLock().release();
-      }      
    }
 
    /**
@@ -687,9 +689,7 @@
    public void putReplicantLocally(int originatorNodeID, Serializable key, Serializable replicant)
       throws Exception
    {
-      lock.writeLock().acquire();
-      
-      try
+      synchronized (replicatedData)
       {         
          Map m = (Map)replicatedData.get(key);
          
@@ -704,10 +704,6 @@
          
          notifyListeners(key, m);
       }
-      finally
-      {
-         lock.writeLock().release();
-      }
    }
 
    /**
@@ -715,10 +711,10 @@
     */
    public boolean removeReplicantLocally(int originatorNodeID, Serializable key) throws Exception
    {
-      lock.writeLock().acquire();
-      
-      try
+      synchronized (replicatedData)
       {
+         log.info(this.currentNodeId + " removing key " + key + " from node " + originatorNodeID);
+         
          Map m = (Map)replicatedData.get(key);
          
          if (m == null)
@@ -736,16 +732,11 @@
          if (m.isEmpty())
          {
             replicatedData.remove(key);
-         }
-         
+         } 
          notifyListeners(key, m);
-         
-         return true;
+      
+         return true; 
       }
-      finally
-      {
-         lock.writeLock().release();
-      }
    }
      
    /*
@@ -759,7 +750,7 @@
     
       if (trace)
       {
-         log.info(this.nodeId + " adding binding from node: " + nodeId + " queue: " + queueName + " with condition: " + condition);
+         log.info(this.currentNodeId + " adding binding from node: " + nodeId + " queue: " + queueName + " with condition: " + condition);
       }
             
       try
@@ -783,7 +774,7 @@
          
          if (binding != null && failed)
          {
-            throw new IllegalArgumentException(this.nodeId + " Binding already exists for node Id " + nodeId + " queue name " + queueName);
+            throw new IllegalArgumentException(this.currentNodeId + " Binding already exists for node Id " + nodeId + " queue name " + queueName);
          }
             
          binding = this.createBinding(nodeId, condition, queueName, channelID, filterString, durable, failed);
@@ -805,7 +796,7 @@
       
       if (trace)
       {
-         log.trace(this.nodeId + " removing binding from node: " + nodeId + " queue: " + queueName);        
+         log.trace(this.currentNodeId + " removing binding from node: " + nodeId + " queue: " + queueName);        
       }
       
       try
@@ -829,7 +820,7 @@
    {
       if (trace)
       {
-         log.trace(this.nodeId + " routing from cluster, message: " + message + " routing key " +
+         log.trace(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
                   routingKey + " map " + queueNameNodeIdMap);
       }
             
@@ -860,7 +851,7 @@
             {
                Binding binding = (Binding)iter.next();
                                                      
-               if (binding.getNodeId() == this.nodeId)
+               if (binding.getNodeId() == this.currentNodeId)
                {  
                   boolean handle = true;
                   
@@ -873,7 +864,7 @@
                      
                      if (in != null)
                      {
-                        handle = in.intValue() == nodeId;
+                        handle = in.intValue() == currentNodeId;
                      }
                   }
                   
@@ -887,7 +878,7 @@
                      
                      if (trace)
                      {
-                        log.trace(this.nodeId + " queue " + queue.getName() + " handled reference from cluster " + del);
+                        log.trace(this.currentNodeId + " queue " + queue.getName() + " handled reference from cluster " + del);
                      }
                   }
                }
@@ -909,7 +900,7 @@
     */
    public void asyncSendRequest(ClusterRequest request) throws Exception
    {     
-      if (trace) { log.trace(this.nodeId + " sending asynch request to group, request: " + request); }
+      if (trace) { log.trace(this.currentNodeId + " sending asynch request to group, request: " + request); }
       
       byte[] bytes = writeRequest(request);
               
@@ -921,11 +912,11 @@
     */
    public void asyncSendRequest(ClusterRequest request, int nodeId) throws Exception
    {               
-      if (trace) { log.trace(this.nodeId + " sending asynch request to single node, request: " + request + " node " + nodeId); }
+      if (trace) { log.trace(this.currentNodeId + " sending asynch request to single node, request: " + request + " node " + nodeId); }
       
       Address address = this.getAddressForNodeId(nodeId, false);
       
-      if (trace) { log.trace(this.nodeId + " sending to address " + address); }
+      if (trace) { log.trace(this.currentNodeId + " sending to address " + address); }
       
       if (address == null)
       {
@@ -948,13 +939,13 @@
       {
          holdingArea.put(id, tx);
          
-         if (trace) { log.trace(this.nodeId + " added transaction " + tx + " to holding area with id " + id); }
+         if (trace) { log.trace(this.currentNodeId + " added transaction " + tx + " to holding area with id " + id); }
       } 
    }
    
    public void commitTransaction(TransactionId id) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " committing transaction " + id ); }
+      if (trace) { log.trace(this.currentNodeId + " committing transaction " + id ); }
       
       ClusterTransaction tx = null;
         
@@ -970,12 +961,12 @@
       
       tx.commit(this);
       
-      if (trace) { log.trace(this.nodeId + " committed transaction " + id ); }
+      if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
    
    public void rollbackTransaction(TransactionId id) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " rolling back transaction " + id ); }
+      if (trace) { log.trace(this.currentNodeId + " rolling back transaction " + id ); }
       
       ClusterTransaction tx = null;
         
@@ -991,7 +982,7 @@
       
       tx.rollback(this);
       
-      if (trace) { log.trace(this.nodeId + " committed transaction " + id ); }
+      if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
    
    /**
@@ -999,7 +990,7 @@
     */
    public void check(Integer nodeId) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " checking for any stranded transactions for node " + nodeId); }
+      if (trace) { log.trace(this.currentNodeId + " checking for any stranded transactions for node " + nodeId); }
       
       synchronized (holdingArea)
       {
@@ -1021,7 +1012,7 @@
                 
                boolean commit = tx.check(this);
                
-               if (trace) { log.trace(this.nodeId + " transaction " + tx + " will be committed?: " + commit); }
+               if (trace) { log.trace(this.currentNodeId + " transaction " + tx + " will be committed?: " + commit); }
                
                if (commit)
                {
@@ -1034,7 +1025,7 @@
                
                toRemove.add(id);
                
-               if (trace) { log.trace(this.nodeId + " resolved " + tx); }
+               if (trace) { log.trace(this.currentNodeId + " resolved " + tx); }
             }
          }
          
@@ -1049,7 +1040,7 @@
             holdingArea.remove(id);
          }
       }
-      if (trace) { log.trace(this.nodeId + " check complete"); }
+      if (trace) { log.trace(this.currentNodeId + " check complete"); }
    }
    
    public void sendQueueStats() throws Exception
@@ -1065,7 +1056,7 @@
       
       try
       {         
-         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
+         Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
          
          if (nameMap != null)
          {            
@@ -1090,7 +1081,7 @@
 
                      statsList.add(stats);
                      
-                     if (trace) { log.trace(this.nodeId + " adding stat for send " + stats); }
+                     if (trace) { log.trace(this.currentNodeId + " adding stat for send " + stats); }
                   } 
                }
             }
@@ -1103,11 +1094,11 @@
       
       if (statsList != null)
       {
-         ClusterRequest req = new QueueStatsRequest(nodeId, statsList);
+         ClusterRequest req = new QueueStatsRequest(currentNodeId, statsList);
          
          asyncSendRequest(req);
          
-         if (trace) { log.trace(this.nodeId + " Sent stats"); }
+         if (trace) { log.trace(this.currentNodeId + " Sent stats"); }
       }
    }
    
@@ -1115,11 +1106,11 @@
    {
       lock.readLock().acquire();
 
-      if (trace) { log.trace(this.nodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
+      if (trace) { log.trace(this.currentNodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
       
       try
       {      
-         if (nodeId == this.nodeId)
+         if (nodeId == this.currentNodeId)
          {
             //Sanity check
             throw new IllegalStateException("Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!");
@@ -1130,7 +1121,7 @@
          if (nameMap == null)
          {
             //This is ok, the node might have left
-            if (trace) { log.trace(this.nodeId + " cannot find node in name map, i guess the node might have left?"); }
+            if (trace) { log.trace(this.currentNodeId + " cannot find node in name map, i guess the node might have left?"); }
          }
          else
          {     
@@ -1145,7 +1136,7 @@
                if (bb == null)
                {
                   //I guess this is possible if the queue was unbound
-                  if (trace) { log.trace(this.nodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
+                  if (trace) { log.trace(this.currentNodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
                }
                else
                {                  
@@ -1153,7 +1144,7 @@
                   
                   stub.setStats(st);
                   
-                  if (trace) { log.trace(this.nodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
+                  if (trace) { log.trace(this.currentNodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
                   
                   ClusterRouter router = (ClusterRouter)routerMap.get(st.getQueueName());
                   
@@ -1166,7 +1157,7 @@
                      //TODO - the call to getQueues is too slow since it creates a new list and adds the local queue!!!
                      RemoteQueueStub toQueue = (RemoteQueueStub)messagePullPolicy.chooseQueue(router.getQueues());
                      
-                     if (trace) { log.trace(this.nodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
+                     if (trace) { log.trace(this.currentNodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
                                     
                      localQueue.setPullQueue(toQueue);
                      
@@ -1177,7 +1168,7 @@
                         
                         localQueue.deliver(false);
                                                                     
-                        if (trace) { log.trace(this.nodeId + " triggered delivery for " + localQueue.getName()); }
+                        if (trace) { log.trace(this.currentNodeId + " triggered delivery for " + localQueue.getName()); }
                      }
                   } 
                }
@@ -1199,7 +1190,7 @@
    public void handleMessagePullResult(int remoteNodeId, long holdingTxId,
                                        String queueName, org.jboss.messaging.core.Message message) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " handling pull result " + message + " for " + queueName); }
+      if (trace) { log.trace(this.currentNodeId + " handling pull result " + message + " for " + queueName); }
                
       Binding binding = getBindingForQueueName(queueName);
       
@@ -1246,22 +1237,22 @@
          if (message.isReliable())
          {
             //Only reliable messages will be in holding area
-            this.asyncSendRequest(new RollbackPullRequest(this.nodeId, holdingTxId), remoteNodeId);
+            this.asyncSendRequest(new RollbackPullRequest(this.currentNodeId, holdingTxId), remoteNodeId);
             
-            if (trace) { log.trace(this.nodeId + " send rollback pull request"); }
+            if (trace) { log.trace(this.currentNodeId + " send rollback pull request"); }
          }
       }      
    }
    
    public int getNodeId()
    {
-      return nodeId;
+      return currentNodeId;
    }
 
    public String toString()
    {
       StringBuffer sb = new StringBuffer("ClusteredPostOffice[");
-      sb.append(nodeId).append(":").append(getOfficeName()).append(":");
+      sb.append(currentNodeId).append(":").append(getOfficeName()).append(":");
 
       if (syncChannel == null)
       {
@@ -1324,7 +1315,7 @@
       {
          if (oldView != null)
          {
-            for(Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+            for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
             {
                Address address = (Address)i.next();
                if (!newView.containsMember(address))
@@ -1334,7 +1325,7 @@
             }
          }
 
-         for(Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+         for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
          {
             Address address = (Address)i.next();
             if (oldView == null || !oldView.containsMember(address))
@@ -1457,7 +1448,7 @@
             }
            
             //Create a new binding
-            Binding newBinding = this.createBinding(this.nodeId, binding.getCondition(),
+            Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
                                                     stub.getName(), stub.getChannelID(),
                                                     stub.getFilter(), stub.isRecoverable(), failed);
 
@@ -1497,7 +1488,7 @@
       {
          //First look in the failed map
          //Failed bindings are stored in the failed map by channel id
-         Map channelMap = (Map)failedBindings.get(new Integer(nodeId));
+         Map channelMap = (Map)failedBindings.get(new Integer(currentNodeId));
          Binding binding = null;
          if (channelMap != null)
          {
@@ -1507,7 +1498,7 @@
          if (binding == null)
          {
             //Not found in the failed map - look in the name map
-            Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
+            Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
 
             if (nameMap != null)
             {
@@ -1684,7 +1675,7 @@
 
       if (bindings == null)
       {
-         bindings = new DefaultClusteredBindings(nodeId);
+         bindings = new DefaultClusteredBindings(currentNodeId);
 
          conditionMap.put(condition, bindings);
       }
@@ -1769,7 +1760,7 @@
       {
          //The state will be set in due course via the MessageListener - we must wait until this happens
          
-         if (trace) { log.trace(this.nodeId + " Not first member of group- so waiting for state to arrive...."); }
+         if (trace) { log.trace(this.currentNodeId + " Not first member of group- so waiting for state to arrive...."); }
 
       synchronized (setStateLock)
       {
@@ -1780,14 +1771,14 @@
          }
       }
 
-         if (trace) { log.trace(this.nodeId + " Received state"); }
+         if (trace) { log.trace(this.currentNodeId + " Received state"); }
       }
    }
 
    protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
    {
       Queue queue;
-      if (nodeId == this.nodeId)
+      if (nodeId == this.currentNodeId)
       {
          QueuedExecutor executor = (QueuedExecutor)pool.get();
          
@@ -1806,16 +1797,10 @@
    
    private boolean leaveMessageReceived(Integer nodeId) throws Exception
    {
-      lock.writeLock().acquire();
-      
-      try
+      synchronized (leftSet)
       {
          return leftSet.remove(nodeId);
       }
-      finally
-      {
-         lock.writeLock().release();
-      }    
    }
    
    /*
@@ -1857,8 +1842,15 @@
                
                removeBinding(nodeID.intValue(), binding.getQueue().getName());
             }
-         }
+         }         
+      }
+      finally
+      {
+         lock.writeLock().release();
+      }
          
+      synchronized (replicatedData)
+      {         
          // We need to remove any replicant data for the node. This includes the node-address info.
          for(Iterator i = replicatedData.entrySet().iterator(); i.hasNext(); )
          {
@@ -1876,12 +1868,8 @@
             
             // Need to trigger listeners
             notifyListeners(key, replicants);
-         }                  
+         }         
       }
-      finally
-      {
-         lock.writeLock().release();
-      }
    }
 
    /**
@@ -1890,10 +1878,14 @@
     */
    private void notifyListeners(Serializable key, Map updatedReplicantMap)
    {
-      for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
-      {
-         ReplicationListener listener = (ReplicationListener)i.next();
-         listener.onReplicationChange(key, updatedReplicantMap);
+      synchronized (replicationListeners)
+      {         
+         for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
+         {
+            ReplicationListener listener = (ReplicationListener)i.next();
+            
+            listener.onReplicationChange(key, updatedReplicantMap);
+         }
       }
    } 
    
@@ -1913,13 +1905,33 @@
       if (trace) { log.trace(this + " request sent OK"); }
    }
    
+   //DEBUG ONLY - remove this
+   private void dumpNodeIdAddressMap(Map map) throws Exception   
+   {
+      log.info("** DUMPING NODE ADDRESS MAPPING");
+      
+      Iterator iter = map.entrySet().iterator();
+      
+      while (iter.hasNext())
+      {
+         Map.Entry entry = (Map.Entry)iter.next();
+         
+         Integer theNodeId = (Integer)entry.getKey();
+         
+         PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
+         
+         log.info("node id: " + theNodeId +" --------->(async:sync) " + info.getAsyncChannelAddress() + ":" + info.getSyncChannelAddress());
+      }
+      
+      log.info("** END DUMP");      
+   }
+   
 
    //TODO - this is a bit tortuous - needs optimising
    private Integer getNodeIdForSyncAddress(Address address) throws Exception
    {
-      lock.readLock().acquire();
-      try
-      { 
+      synchronized (replicatedData)
+      {
          Map map = get(ADDRESS_INFO_KEY);
          
          if (map == null)
@@ -1927,43 +1939,54 @@
             throw new IllegalStateException("Cannot find node id -> address mapping");
          }
          
+         this.dumpNodeIdAddressMap(map);
+         
          Iterator iter = map.entrySet().iterator();
          
-         Integer nodeId = null;
+         log.info("iterating, looking for " + address);
+         
+         Integer theNodeId = null;
          while (iter.hasNext())
          {
             Map.Entry entry = (Map.Entry)iter.next();
             
             PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
             
+            log.info("info synch channel address: " + info.getSyncChannelAddress());
+            
             if (info.getSyncChannelAddress().equals(address))
             {
-               nodeId = (Integer)entry.getKey();
+               log.info("equal");
+               theNodeId = (Integer)entry.getKey();
+               break;
             }
+            else
+            {
+               log.info("Not equal");
+            }
          }
-         return nodeId;
+         return theNodeId;
       }
-      finally
-      {
-         lock.readLock().release();
-      }
    }
    
    private boolean knowAboutNodeId(int nodeId)
    {
       //The nodeid->Address info mapping is stored in the replicated data
       
-      Map nodeIdAddressMapping = (Map)replicatedData.get(ADDRESS_INFO_KEY);
-      
-      if (nodeIdAddressMapping == null)
-      {
-         return false;
-      }
-      else
-      {
-         Object obj = nodeIdAddressMapping.get(new Integer(nodeId));
+      synchronized (replicatedData)
+      {         
+         Map nodeIdAddressMapping = (Map)replicatedData.get(ADDRESS_INFO_KEY);
          
-         return obj != null;
+         if (nodeIdAddressMapping == null)
+         {
+            return false;
+         }
+         else
+         {
+            Object obj = nodeIdAddressMapping.get(new Integer(nodeId));
+            
+            return obj != null;
+         }
       }
    }
 
@@ -1973,7 +1996,7 @@
     */
    private boolean isFailoverNodeForNode(int nodeId)
    {
-      return this.nodeId == getFailoverNodeID(nodeId);
+      return this.currentNodeId == getFailoverNodeID(nodeId);
    }
       
    private byte[] getStateAsBytes() throws Exception
@@ -2004,8 +2027,17 @@
          }
       }
       
-      SharedState state = new SharedState(bindings, replicatedData);
+      //Need to copy
       
+      Map copy;
+      
+      synchronized (replicatedData)
+      {
+         copy = copyReplicatedData(replicatedData);
+      }
+      
+      SharedState state = new SharedState(bindings, copy);
+      
       return StreamUtils.toBytes(state);
    }
    
@@ -2034,7 +2066,7 @@
          Binding binding = this.createBinding(info.getNodeId(), info.getCondition(), info.getQueueName(), info.getChannelId(),
                                               info.getFilterString(), info.isDurable(),info.isFailed());
          
-         if (binding.getNodeId() == this.nodeId)
+         if (binding.getNodeId() == this.currentNodeId)
          {
             //We deactivate if this is one of our own bindings - it can only
             //be one of our own durable bindings - and since state is retrieved before we are fully started
@@ -2046,11 +2078,20 @@
          addBinding(binding);         
       }
       
-      //Copy the map
-      this.replicatedData.clear();
+      //Update the replicated data
       
-      iter = state.getReplicatedData().entrySet().iterator();
+      synchronized (replicatedData)
+      {
+         replicatedData = copyReplicatedData(state.getReplicatedData());
+      }
+   }
+   
+   private Map copyReplicatedData(Map toCopy)
+   {
+      Map copy = new HashMap();
       
+      Iterator iter = toCopy.entrySet().iterator();
+      
       while (iter.hasNext())
       {
          Map.Entry entry = (Map.Entry)iter.next();
@@ -2063,8 +2104,10 @@
          
          m.putAll(replicants);
          
-         replicatedData.put(key, m);
+         copy.put(key, m);
       }
+      
+      return copy;
    }
    
 
@@ -2096,9 +2139,7 @@
    
    private Address getAddressForNodeId(int nodeId, boolean sync) throws Exception
    {  
-      lock.readLock().acquire();
-
-      try
+      synchronized (replicatedData)
       {
          Map map = this.get(ADDRESS_INFO_KEY);
          
@@ -2124,64 +2165,11 @@
          {
             return null;
          }
-      }
-      finally
-      {
-         lock.readLock().release();      
-      }
+      }      
    }
    
-   /*
-    * Given a JGroups view, generate a map of node to failover node.
-    * The mapping is determined by a pluggable policy.
-    */
-   private void generateFailoverMap(View view) throws Exception
-   {
-      List nodes = new ArrayList();
-      
-      for (Iterator i = view.getMembers().iterator(); i.hasNext(); )
-      {
-         Address address = (Address)i.next();
+   
 
-         // Ignore own address, a node can't be its own failover node
-         if (syncChannel.getLocalAddress().equals(address))
-         {
-            continue;
-         }
-
-         // Convert to node id
-         // TODO this should be optimised - currently the implementation of the lookup
-         // is a bit tortuous
-         
-         Integer n = getNodeIdForSyncAddress(address);
-         
-         if (n == null)
-         {
-            throw new IllegalStateException("Cannot find node id for address: " + address);
-         }
-         
-         nodes.add(n);                  
-      }
-            
-      List failoverNodes = failoverMapper.generateMapping(nodes);
-      
-      // Now put this in the map of node -> failover node
-      
-      failoverMap.clear();
-
-      Iterator iter = nodes.iterator();
-      Iterator iter2 = failoverNodes.iterator();
-
-      while (iter.hasNext())
-      {
-         Integer node = (Integer)iter.next();
-
-         Integer failoverNode = (Integer)iter2.next();
-
-         failoverMap.put(node, failoverNode);
-      }
-   }
-
    /*
     * A new node has joined the group
     */
@@ -2189,8 +2177,10 @@
    {
       if (trace) { log.trace(this + ": " + address + " joined"); }
 
+      log.info(this.currentNodeId + " Node with address: " + address + " joined");
+      
       // We need to regenerate the failover map
-      generateFailoverMap(currentView);
+      //generateFailoverMap(currentView);
    }
 
    /*
@@ -2199,32 +2189,34 @@
    private void nodeLeft(Address address) throws Throwable
    {
       if (trace) { log.trace(this + ": " + address + " left"); }
+      
+      log.info(this.currentNodeId + " Node with address: " + address + " left");
 
-      Integer nodeId = getNodeIdForSyncAddress(address);
+      Integer theNodeId = getNodeIdForSyncAddress(address);
 
-      if (nodeId != null)
+      if (theNodeId == null)
       {
-         throw new IllegalStateException("Cannot find node id for address " + address);
+         throw new IllegalStateException(this.currentNodeId + " Cannot find node id for address " + address);
       }
 
-      boolean crashed = !this.leaveMessageReceived(nodeId);
+      boolean crashed = !this.leaveMessageReceived(theNodeId);
 
-      if (trace) { log.trace("Node " + address + " id: " + nodeId +" has left the group, crashed = " + crashed); }
+      if (trace) { log.trace("Node " + address + " id: " + theNodeId +" has left the group, crashed = " + crashed); }
 
       //Cleanup any hanging transactions - we do this irrespective of whether we crashed
-      check(nodeId);
+      check(theNodeId);
 
       //Need to evaluate this before we regenerate the failover map
-      boolean isFailover = isFailoverNodeForNode(nodeId.intValue());
+      boolean isFailover = isFailoverNodeForNode(theNodeId.intValue());
 
       //Now we recalculate the failover mapping - this needs to be done before removeDataForNode is called
       //since that may cause connection factories to be rebound
-      generateFailoverMap(currentView);
+      //generateFailoverMap(currentView);
 
       //Remove any replicant data and non durable bindings for the node - again we need to do this
       //irrespective of whether we crashed
       //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
-      removeDataForNode(nodeId);
+      removeDataForNode(theNodeId);
 
       if (crashed && isFailover)
       {
@@ -2233,7 +2225,7 @@
 
          //TODO server side valve
 
-         failOver(nodeId.intValue());
+         failOver(theNodeId.intValue());
       }
    }
 
@@ -2337,8 +2329,8 @@
          // + DefaultClusteredPostOffice.this.getOfficeName()); }
          //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
          //TODO:     can't we do the same since this is pretty useful?
-         log.info(DefaultClusteredPostOffice.this  + " got new view: " + newView + " postOffice:"
-            + DefaultClusteredPostOffice.this.getOfficeName());
+         log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
+                  + DefaultClusteredPostOffice.this.getOfficeName());
 
          // JGroups will make sure this method is never called by more than one thread concurrently
          
@@ -2347,11 +2339,16 @@
 
          // Since now membership is sent over state transfer, we have to wait stateSet to be set.
          // If this logic is not good enough, we will have to place Address in a separate data structure
-         // as it used to be (NodeInfos)
-         if (stateSet)
-         {
+         // as it used to be (NodeInfos) - Clebert
+         
+         
+         // FIXME - I don't understand why this check with flag (stateSet)is necessary
+         //The state will always be set before any view changes occur - JGroups guarantees this -
+         //Maybe I am wrong - Tim
+//         if (stateSet)
+//         {
             verifyMembership(oldView, newView);
-         }
+        // }
       }
 
       public byte[] getState()
@@ -2391,7 +2388,7 @@
       
       public void receive(Message message)
       {
-         if (trace) { log.trace(nodeId + " received message " + message + " on async channel"); }
+         if (trace) { log.trace(currentNodeId + " received message " + message + " on async channel"); }
          
          try
          {
@@ -2423,7 +2420,7 @@
    {
       public Object handle(Message message)
       {
-         if (trace) { log.info(nodeId + " received message " + message + " on sync channel"); }
+         if (trace) { log.info(currentNodeId + " received message " + message + " on sync channel"); }
          try
          {   
             byte[] bytes = message.getBuffer();
@@ -2441,4 +2438,66 @@
          }         
       }      
    }
+   
+   /*
+    * We use this class to respond to node address mappings being added or removed from the cluster
+    * and then recalculate the node->failover node mapping
+    * 
+    */
+   private class NodeAddressMapListener implements ReplicationListener
+   {
+
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap)
+      {
+         if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
+         {
+            log.info(currentNodeId + " got node address change");
+            
+            try
+            {
+               //DEBUG only
+               dumpNodeIdAddressMap(updatedReplicantMap);
+            }
+            catch (Exception ignore)
+            {               
+            }
+            
+            //A node-address mapping has been added/removed from global state-
+            //We need to update the failover map
+            generateFailoverMap(updatedReplicantMap);
+         }
+      }
+      
+      private void generateFailoverMap(Map nodeAddressMap)
+      {
+         List nodes = new ArrayList(nodeAddressMap.keySet());
+         
+         log.info("generating failover map");
+         
+         log.info("I have " + nodes.size() + " nodes");
+                                
+         List failoverNodes = failoverMapper.generateMapping(nodes);
+         
+         log.info("I generated " + failoverNodes.size() +" failover nodes");
+         
+         // Now put this in the map of node -> failover node
+         
+         synchronized (failoverMap)
+         {            
+            failoverMap.clear();
+   
+            Iterator iter = nodes.iterator();
+            Iterator iter2 = failoverNodes.iterator();
+   
+            while (iter.hasNext())
+            {
+               Integer node = (Integer)iter.next();
+   
+               Integer failoverNode = (Integer)iter2.next();
+   
+               failoverMap.put(node, failoverNode);
+            }
+         }
+      }      
+   }
 }
\ No newline at end of file

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -24,6 +24,7 @@
 import java.util.ArrayList;
 import java.util.List;
 
+import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 
 /**
@@ -40,22 +41,25 @@
  */
 public class DefaultFailoverMapper implements FailoverMapper
 {
-
+   private static final Logger log = Logger.getLogger(DefaultFailoverMapper.class);
+   
    public List generateMapping(List nodes)
    {
-      List failoverNodes = new ArrayList(nodes.size());
+      int s = nodes.size();
       
+      log.info("Genertaing failover mapping, node size="+ s);
+            
+      List failoverNodes = new ArrayList(s);
+      
       if (!(nodes instanceof ArrayList))
       {
          //So we can ensure fast index based access
          nodes = new ArrayList(nodes);
       }
-      
-      int s = nodes.size();
-      
+            
       for (int i = 0; i < s; i++)
       {
-         int j = i++;
+         int j = i + 1;
          
          if (j == s)
          {
@@ -67,6 +71,8 @@
          failoverNodes.add(failoverNode);
       }
       
+      log.info("Returning " + failoverNodes.size() + " nodes");
+      
       return failoverNodes;
    }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -36,6 +36,7 @@
    Object execute(PostOfficeInternal office) throws Throwable
    {
       office.handleNodeLeft(nodeId);
+      
       return null;
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -85,6 +85,60 @@
       super.tearDown();
    }
    
+   public final void testSimpleJoinLeave() throws Throwable
+   {
+      ClusteredPostOffice office1 = null;
+      
+      ClusteredPostOffice office2 = null;
+      
+      //ClusteredPostOffice office3 = null;
+      
+      try
+      {         
+         log.info("Starting office 1");
+         office1 = createClusteredPostOffice(1, "testgroup");
+         
+         log.info("starting office 2");
+         office2 = createClusteredPostOffice(2, "testgroup");
+                  
+         //office3 = createClusteredPostOffice(3, "testgroup");
+         
+         Thread.sleep(2000);
+         
+         office1.stop();
+         office1 = null;
+         
+         office2.stop();
+         office2 = null;
+         
+//         office3.stop();
+//         office3 = null;
+      }
+      finally
+      {
+         if (office1 != null)
+         {
+            office1.stop();
+         }
+         
+         if (office2 != null)
+         {
+            office2.stop();
+         }
+         
+//         if (office3 != null)
+//         {
+//            office3.stop();
+//         }
+         
+         if (checkNoBindingData())
+         {
+            fail("data still in database");
+         }
+      }
+         
+   }
+   
    public final void testClusteredBindUnbind() throws Throwable
    {
       ClusteredPostOffice office1 = null;

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-05 03:10:30 UTC (rev 1704)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-05 14:06:32 UTC (rev 1705)
@@ -56,6 +56,7 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
 import org.jboss.test.messaging.tools.jboss.ServiceDeploymentDescriptor;
+import org.jboss.test.messaging.tools.jndi.Constants;
 import org.jboss.test.messaging.tools.jndi.InVMInitialContextFactory;
 import org.jboss.test.messaging.tools.jndi.InVMInitialContextFactoryBuilder;
 import org.jboss.tm.TransactionManagerLocator;
@@ -290,6 +291,8 @@
          Hashtable t = InVMInitialContextFactory.getJNDIEnvironment(serverIndex);
          System.setProperty("java.naming.factory.initial",
                             (String)t.get("java.naming.factory.initial"));
+         System.setProperty(Constants.SERVER_INDEX_PROPERTY_NAME,
+                            Integer.toString(serverIndex));
 
          initialContext = new InitialContext();
 



From gavin.king at jboss.com  Tue Dec  5 10:06:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:06:33 -0500
Subject: [jboss-cvs] jboss-seam/facelets  ...
Message-ID: <E1GrbsP-0008PB-IZ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:06:33

  Removed:     facelets  readme.txt
  Log:
  move facelets to lib


From gavin.king at jboss.com  Tue Dec  5 10:06:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:06:33 -0500
Subject: [jboss-cvs] jboss-seam/facelets/lib    ...
Message-ID: <E1GrbsP-0008PF-Ps@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:06:33

  Removed:     facelets/lib    el-api.jar el-ri.jar jsf-facelets.jar
  Log:
  move facelets to lib


From gavin.king at jboss.com  Tue Dec  5 10:06:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:06:34 -0500
Subject: [jboss-cvs] jboss-seam/lib  ...
Message-ID: <E1GrbsQ-0008PL-2i@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:06:34

  Added:       lib      jsf-facelets.jar
  Log:
  move facelets to lib
  
  Revision  Changes    Path
  1.1      date: 2006/12/05 15:06:34;  author: gavin;  state: Exp;jboss-seam/lib/jsf-facelets.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Tue Dec  5 10:14:01 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:14:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages/resources/META-INF  ...
Message-ID: <E1Grbzd-00006E-4o@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:14:01

  Modified:    examples/messages/resources/META-INF  application.xml
  Log:
  add el jars
  
  Revision  Changes    Path
  1.6       +6 -0      jboss-seam/examples/messages/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.5
  +++ application.xml	5 Dec 2006 15:14:00 -0000	1.6
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 10:14:01 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:14:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/numberguess/resources/META-INF  ...
Message-ID: <E1Grbzd-00006L-8k@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:14:01

  Modified:    examples/numberguess/resources/META-INF  application.xml
  Log:
  add el jars
  
  Revision  Changes    Path
  1.8       +6 -0      jboss-seam/examples/numberguess/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/resources/META-INF/application.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.7
  +++ application.xml	5 Dec 2006 15:14:01 -0000	1.8
  @@ -21,5 +21,11 @@
   	<module>
   	    <java>jbpm-3.1.2.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 10:14:01 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:14:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/registration/resources/META-INF  ...
Message-ID: <E1Grbzd-00006S-DZ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:14:01

  Modified:    examples/registration/resources/META-INF  application.xml
  Log:
  add el jars
  
  Revision  Changes    Path
  1.10      +6 -0      jboss-seam/examples/registration/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/registration/resources/META-INF/application.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.9
  +++ application.xml	5 Dec 2006 15:14:01 -0000	1.10
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 10:14:01 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 10:14:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/todo/resources/META-INF  ...
Message-ID: <E1Grbzd-00006Z-JE@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 10:14:01

  Modified:    examples/todo/resources/META-INF  application.xml
  Log:
  add el jars
  
  Revision  Changes    Path
  1.8       +6 -0      jboss-seam/examples/todo/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/todo/resources/META-INF/application.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- application.xml	3 Dec 2006 04:41:36 -0000	1.7
  +++ application.xml	5 Dec 2006 15:14:01 -0000	1.8
  @@ -21,5 +21,11 @@
   	<module>
   	    <java>jbpm-3.1.2.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 10:25:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 10:25:55 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1706 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster
Message-ID: <E1GrcB9-0000Kk-3Q@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-05 10:25:53 -0500 (Tue, 05 Dec 2006)
New Revision: 1706

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
a few more bits and pieces



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-05 14:06:32 UTC (rev 1705)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-05 15:25:53 UTC (rev 1706)
@@ -331,8 +331,6 @@
       
       put(ADDRESS_INFO_KEY, info);
 
-      //verifyMembership(null, this.currentView);
-
       statsSender.start();
       
       started = true;
@@ -346,22 +344,24 @@
       {
          log.warn("Attempt to stop() but " + this + " is not started");
       }
-
-      syncSendRequest(new LeaveClusterRequest(this.getNodeId()));
-      
-      super.stop(sendNotification);
-      
-      unregisterListener(nodeAddressMapListener);
-      
-      statsSender.stop();
+      else
+      {   
+         syncSendRequest(new LeaveClusterRequest(this.getNodeId()));
          
-      syncChannel.close();
-      
-      asyncChannel.close();
-      
-      started = false;
-      
-      if (trace) { log.trace("Stopped " + this); }
+         super.stop(sendNotification);
+         
+         unregisterListener(nodeAddressMapListener);
+         
+         statsSender.stop();
+            
+         syncChannel.close();
+         
+         asyncChannel.close();
+         
+         started = false;
+         
+         if (trace) { log.trace("Stopped " + this); }
+      }
    }  
    
    // PostOffice implementation ---------------------------------------        
@@ -1309,38 +1309,28 @@
     *  Verifies changes on the View deciding if a node joined or lefted the cluster
     *
     * */
-   private void verifyMembership(View oldView, View newView)
+   private void verifyMembership(View oldView, View newView) throws Throwable
    {
-      try
+      if (oldView != null)
       {
-         if (oldView != null)
+         for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
          {
-            for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+            Address address = (Address)i.next();
+            if (!newView.containsMember(address))
             {
-               Address address = (Address)i.next();
-               if (!newView.containsMember(address))
-               {
-                  nodeLeft(address);
-               }
+               nodeLeft(address);
             }
          }
+      }
 
-         for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+      for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+      {
+         Address address = (Address)i.next();
+         if (oldView == null || !oldView.containsMember(address))
          {
-            Address address = (Address)i.next();
-            if (oldView == null || !oldView.containsMember(address))
-            {
-               nodeJoined(address);
-            }
+            nodeJoined(address);
          }
       }
-      catch (Throwable e)
-      {
-         log.error("Caught Exception in MembershipListener", e);
-         IllegalStateException e2 = new IllegalStateException(e.getMessage());
-         e2.setStackTrace(e.getStackTrace());
-         throw e2;
-      }
    }
 
 
@@ -2337,18 +2327,17 @@
          View oldView = currentView;
          currentView = newView;
 
-         // Since now membership is sent over state transfer, we have to wait stateSet to be set.
-         // If this logic is not good enough, we will have to place Address in a separate data structure
-         // as it used to be (NodeInfos) - Clebert
-         
-         
-         // FIXME - I don't understand why this check with flag (stateSet)is necessary
-         //The state will always be set before any view changes occur - JGroups guarantees this -
-         //Maybe I am wrong - Tim
-//         if (stateSet)
-//         {
+         try
+         {
             verifyMembership(oldView, newView);
-        // }
+         }
+         catch (Throwable e)
+         {
+            log.error("Caught Exception in MembershipListener", e);
+            IllegalStateException e2 = new IllegalStateException(e.getMessage());
+            e2.setStackTrace(e.getStackTrace());
+            throw e2;
+         }
       }
 
       public byte[] getState()



From msurtani at jboss.com  Tue Dec  5 10:27:51 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:51 -0500
Subject: [jboss-cvs] JBossCache/lib  ...
Message-ID: <E1GrcD1-0000OC-AP@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:51

  Modified:    lib      Tag: Branch_JBossCache_1_4_0 jgroups.jar
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.2   +2040 -5837JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Tue Dec  5 10:27:51 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:51 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache   ...
Message-ID: <E1GrcD1-0000ON-Ex@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:51

  Modified:    tests/functional/org/jboss/cache   Tag:
                        Branch_JBossCache_1_4_0 LifeCycleTest.java
  Removed:     tests/functional/org/jboss/cache   Tag:
                        Branch_JBossCache_1_4_0 JGroupsConfigTest.java
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.4.1   +3 -3      JBossCache/tests/functional/org/jboss/cache/LifeCycleTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LifeCycleTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/LifeCycleTest.java,v
  retrieving revision 1.2
  retrieving revision 1.2.4.1
  diff -u -b -r1.2 -r1.2.4.1
  --- LifeCycleTest.java	3 Nov 2005 12:39:53 -0000	1.2
  +++ LifeCycleTest.java	5 Dec 2006 15:27:51 -0000	1.2.4.1
  @@ -14,7 +14,7 @@
   /**
    * Tests restart (stop-destroy-create-start) of TreeCache
    * @author Bela Ban
  - * @version $Id: LifeCycleTest.java,v 1.2 2005/11/03 12:39:53 msurtani Exp $
  + * @version $Id: LifeCycleTest.java,v 1.2.4.1 2006/12/05 15:27:51 msurtani Exp $
    */
   public class LifeCycleTest extends TestCase {
   
  @@ -48,12 +48,12 @@
         cache.put("/a/b/c", null);
         log.debug("cache locks before restart:\n" + cache.printLockInfo());
         assertTrue(cache.getNumberOfNodes() > 0);
  -      assertEquals(3, cache.getNumberOfLocksHeld());
  +      assertEquals(4, cache.getNumberOfLocksHeld());
   
         restartCache(cache);
         log.debug("cache locks after restart:\n" + cache.printLockInfo());
   
  -      assertEquals(3, cache.getNumberOfLocksHeld());
  +      assertEquals(4, cache.getNumberOfLocksHeld());
         assertTrue(cache.getNumberOfNodes() > 0);
   
         tx.rollback();
  
  
  


From msurtani at jboss.com  Tue Dec  5 10:27:51 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:51 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader  ...
Message-ID: <E1GrcD1-0000OY-LX@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:51

  Modified:    tests/functional/org/jboss/cache/loader  Tag:
                        Branch_JBossCache_1_4_0 CacheLoaderTestsBase.java
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.24.2.1  +2 -2      JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java,v
  retrieving revision 1.24
  retrieving revision 1.24.2.1
  diff -u -b -r1.24 -r1.24.2.1
  --- CacheLoaderTestsBase.java	4 May 2006 23:11:07 -0000	1.24
  +++ CacheLoaderTestsBase.java	5 Dec 2006 15:27:51 -0000	1.24.2.1
  @@ -15,7 +15,7 @@
   /**
    * Commons tests for all CacheLoaders
    * @author Bela Ban
  - * @version $Id: CacheLoaderTestsBase.java,v 1.24 2006/05/04 23:11:07 msurtani Exp $
  + * @version $Id: CacheLoaderTestsBase.java,v 1.24.2.1 2006/12/05 15:27:51 msurtani Exp $
    */
   abstract public class CacheLoaderTestsBase extends AbstractCacheLoaderTestBase {
   
  @@ -815,7 +815,7 @@
   
          System.out.println("lock info " + cache.printLockInfo());
   
  -      assertEquals(4, cache.getNumberOfLocksHeld());
  +      assertEquals(5, cache.getNumberOfLocksHeld());
         tx.commit();
   
      }
  
  
  


From msurtani at jboss.com  Tue Dec  5 10:27:51 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:51 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GrcD1-0000Oj-Pg@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:51

  Modified:    tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_4_0 TransactionTest.java
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.9.4.1   +285 -65   JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java,v
  retrieving revision 1.9
  retrieving revision 1.9.4.1
  diff -u -b -r1.9 -r1.9.4.1
  --- TransactionTest.java	9 Feb 2006 16:01:45 -0000	1.9
  +++ TransactionTest.java	5 Dec 2006 15:27:51 -0000	1.9.4.1
  @@ -27,7 +27,7 @@
    * Tests transactional access to a local TreeCache.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: TransactionTest.java,v 1.9 2006/02/09 16:01:45 bela Exp $
  + * @version $Id: TransactionTest.java,v 1.9.4.1 2006/12/05 15:27:51 msurtani Exp $
    */
   public class TransactionTest extends TestCase {
      TreeCache cache=null;
  @@ -121,6 +121,40 @@
         }
      }
   
  +   public void testGetAfterRemovalRollback() throws Exception
  +   {
  +      cache.put("/a/b", null);
  +      assertTrue(cache.exists("/a/b"));
  +      tx.begin();
  +      cache.remove("/a/b");
  +      assertFalse(cache.exists("/a/b"));
  +      tx.rollback();
  +      assertTrue(cache.exists("/a/b"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +      // new tx in new thread
  +      Thread th = new Thread()
  +      {
  +         public void run()
  +         {
  +            try
  +            {
  +               cache.getTransactionManager().begin();
  +               assertNotNull(cache.get("/a/b"));
  +               cache.getTransactionManager().rollback();
  +            }
  +            catch (Exception e)
  +            {
  +               e.printStackTrace();
  +               fail("Caught exception");
  +            }
  +         }
  +      };
  +
  +      th.start();
  +      th.join();
  +
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +   }
   
      public void testRollbackTx2() {
         try {
  @@ -285,91 +319,275 @@
   
   
   
  -   public void testNodeDeletionRollback3() {
  +    public void testNodeCreation() throws Exception {
  +      GlobalTransaction gtx;
  +      cache.put("/a/b", null);
  +      tx.begin();
  +      gtx=cache.getCurrentTransaction();
  +      cache.put("/a/b/c", null);
  +      assertLocked(gtx, "/a", false);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c", true);
  +      System.out.println("locks: " + cache.printLockInfo());
  +   }
  +
  +
  +    public void testNodeCreation2() throws Exception {
  +      GlobalTransaction gtx;
  +      tx.begin();
  +      gtx=cache.getCurrentTransaction();
  +      cache.put("/a/b/c", null);
  +      assertLocked(gtx, "/a", true);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c", true);
  +      System.out.println("locks: " + cache.printLockInfo());
  +   }
  +
  +
  +    public void testNodeRemoval() {
         GlobalTransaction gtx;
         try {
  +         cache.put("/a/b/c", null);
  +         tx.begin();
  +         gtx=cache.getCurrentTransaction();
  +         cache.remove("/a/b/c"); // need to remove the node, not just the data in the node.
  +         assertLocked(gtx, "/a", false);
  +         assertLocked(gtx, "/a/b", true);
  +         assertLocked(gtx, "/a/b/c", true);
  +         System.out.println("locks: " + cache.printLockInfo());
  +      }
  +      catch(Throwable t) {
  +         t.printStackTrace();
  +         fail(t.toString());
  +      }
  +   }
  +
  +
  +   public void testNodeRemoval2() {
  +     GlobalTransaction gtx;
  +     try {
  +        cache.put("/a/b/c", null);
  +        tx.begin();
  +        gtx=cache.getCurrentTransaction();
  +        cache.remove("/a/b"); // need to remove the node, not just the data in the node.
  +        assertLocked(gtx, "/a", true);
  +        assertLocked(gtx, "/a/b", true);
  +        assertLocked(gtx, "/a/b/c", true);
  +        System.out.println("locks: " + cache.printLockInfo());
  +     }
  +     catch(Throwable t) {
  +        t.printStackTrace();
  +        fail(t.toString());
  +     }
  +  }
  +
  +  public void testIntermediateNodeCreationOnWrite() throws Exception
  +  {
  +     cache.put("/a", null);
  +     tx.begin();
  +     cache.put("/a/b/c", null);
  +     // expecting WLs on /a, /a/b and /a/b/c.
  +     GlobalTransaction gtx=cache.getCurrentTransaction();
  +     assertLocked(gtx, "/a", true);
  +     assertLocked(gtx, "/a/b", true);
  +     assertLocked(gtx, "/a/b/c", true);
  +     tx.rollback();
  +
  +  }
  +
  +  public void testIntermediateNodeCreationOnRead() throws Exception
  +  {
  +     cache.put("/a", null);
  +     tx.begin();
  +     cache.get("/a/b/c");
  +
  +     // expecting RLs on /, /a
  +     // /a/b, /a/b/c should NOT be created!
  +     GlobalTransaction gtx=cache.getCurrentTransaction();
  +     assertLocked(gtx, "/", false);
  +     assertLocked(gtx, "/a", false);
  +     assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +     assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +     tx.rollback();
  +     assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +     assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +
  +  }
  +
  +
  +   public void testIntermediateNodeCreationOnRemove() throws Exception
  +   {
  +      cache.put("/a", null);
  +      tx.begin();
  +      cache.remove("/a/b/c");
  +
  +      // expecting RLs on /, /a
  +      // /a/b, /a/b/c should NOT be created!
  +      GlobalTransaction gtx=cache.getCurrentTransaction();
  +      assertLocked(gtx, "/", false);
  +      assertLocked(gtx, "/a", false);
  +      assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +      assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +      tx.rollback();
  +      assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +      assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +
  +   }
  +
  +
  +   public void testNodeDeletionRollback3() throws Exception{
  +      GlobalTransaction gtx;
  +      cache.put("/a/b/c1", null);
  +
            tx.begin();
            gtx=cache.getCurrentTransaction();
            cache.put("/a/b/c1", null);
  -         checkLock(gtx, "/a", false);
  -         checkLock(gtx, "/a/b", false);
  -         checkLock(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a", false);
  +      assertLocked(gtx, "/a/b", false);
  +      assertLocked(gtx, "/a/b/c1", true);
   
            cache.put("/a/b/c2", null);
  -         checkLock(gtx, "/a/b/c2", true);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c2", true);
   
            cache.put("/a/b/c3", null);
            cache.put("/a/b/c1/one", null);
  -         checkLock(gtx, "/a/b/c1", true);
  -         checkLock(gtx, "/a/b/c1/one", true);
  +      assertLocked(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a/b/c1/one", true);
   
            cache.put("/a/b/c1/two", null);
            cache.put("/a/b/c1/one/1", null);
  -         checkLock(gtx, "/a/b/c1", true);
  -         checkLock(gtx, "/a/b/c1/one", true);
  -         checkLock(gtx, "/a/b/c1/one/1", true);
  +      assertLocked(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a/b/c1/one", true);
  +      assertLocked(gtx, "/a/b/c1/one/1", true);
   
            cache.put("/a/b/c1/two/2/3/4", null);
  -         checkLock(gtx, "/a/b/c1", true);
  -         checkLock(gtx, "/a/b/c1/two", true);
  -         checkLock(gtx, "/a/b/c1/two/2", false);
  -         checkLock(gtx, "/a/b/c1/two/2/3", false);
  -         checkLock(gtx, "/a/b/c1/two/2/3/4", true);
  +      assertLocked(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a/b/c1/two", true);
  +      assertLocked(gtx, "/a/b/c1/two/2", true);
  +      assertLocked(gtx, "/a/b/c1/two/2/3", true);
  +      assertLocked(gtx, "/a/b/c1/two/2/3/4", true);
   
            System.out.println("locks: " + cache.printLockInfo());
   
            cache.remove("/a/b");
            tx.rollback();
  -         assertNull(cache.getChildrenNames("/a/b"));
  -      }
  -      catch(Throwable t) {
  -         t.printStackTrace();
  -         fail(t.toString());
  -      }
  +      assertTrue(cache.getChildrenNames("/a/b/c1").isEmpty());
  +      Set cn = cache.getChildrenNames("/a/b");
  +      assertEquals(1, cn.size());
  +      assertEquals("c1", cn.iterator().next());
      }
   
  -   public void testDoubleLocks() {
  -      try {
  +   public void testDoubleLocks() throws Exception{
            tx.begin();
  +      GlobalTransaction gtx = cache.getCurrentTransaction();
            cache.put("/a/b/c", null);
            cache.put("/a/b/c", null);
   
            DataNode n=cache.get("/a");
            IdentityLock lock=n.getLock();
            int num=lock.getReaderOwners().size();
  -         assertEquals(1, num);
  +      assertEquals(0, num);
  +      // make sure this is write locked.
  +      assertLocked(gtx, "/a", true);
   
            n=cache.get("/a/b");
            lock=n.getLock();
            num=lock.getReaderOwners().size();
  -         assertEquals(1, num);
  -         // added this here since we had stale gtxs lurking about. - Manik, 02Jan06  
  +      assertEquals(0, num);
  +      // make sure this is write locked.
  +      assertLocked(gtx, "/a/b", true);
  +
  +      n=cache.get("/a/b/c");
  +      lock=n.getLock();
  +      num=lock.getReaderOwners().size();
  +      assertEquals(0, num);
  +      // make sure this is write locked.
  +      assertLocked(gtx, "/a/b/c", true);
  +
            tx.rollback();
  -      }
  -      catch(Throwable t) {
  -         t.printStackTrace();
  -         fail(t.toString());
  -      }
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
  -   private void checkLock(Object owner, String fqn, boolean write_locked) throws Exception {
  -      DataNode n=cache.get(fqn);
  +   private void assertLocked(Object owner, String fqn, boolean write_locked) throws Exception{
  +      DataNode n=cache.peek(Fqn.fromString(fqn));
         IdentityLock lock=n.getLock();
         if(owner == null)
            owner=Thread.currentThread();
  -      if(lock.isLocked() == false)
  -         throw new Exception("node " + fqn + " is not locked");
  +      assertTrue("node " + fqn + " is not locked", lock.isLocked());
         if(write_locked) {
  -         if(lock.isWriteLocked() == false)
  -            throw new Exception("node " + fqn + " is not write-locked");
  +         assertTrue("node " + fqn + " is not write-locked"  + (lock.isReadLocked() ? " but is read-locked instead!" : "!"), lock.isWriteLocked());
         }
         else {
  -         if(lock.isReadLocked() == false)
  -            throw new Exception("node " + fqn + " is not read-locked");
  +         assertTrue("node " + fqn + " is not read-locked" + (lock.isWriteLocked() ? " but is write-locked instead!" : "!"), lock.isReadLocked());
  +      }
  +      assertTrue("owner " + owner + "is not owner", lock.isOwner(owner));
  +   }
  +
  +   public void testConcurrentNodeAccessOnRemovalWithTx() throws Exception
  +   {
  +      cache.put("/a/b/c", null);
  +      tx.begin();
  +      cache.remove("/a/b/c");
  +      // this node should now be locked.
  +      Transaction t = cache.getTransactionManager().suspend();
  +      Transaction t2 = null;
  +      try
  +      {
  +         System.out.println(cache.printLockInfo());
  +         // start a new tx
  +         cache.getTransactionManager().begin();
  +         t2 = cache.getTransactionManager().getTransaction();
  +         cache.get("/a/b/c"); // should fail
  +         t2.commit();
  +         fail("Should not be able to get a hold of /a/b/c until the deleting tx completes");
  +      }
  +      catch (Exception e)
  +      {
  +         // expected
  +         t2.commit();
  +      }
  +
  +      cache.getTransactionManager().resume(t);
  +      tx.rollback();
  +
  +      assertNotNull(cache.get("/a/b/c"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +   }
  +
  +   public void testConcurrentNodeAccessOnRemovalWithoutTx() throws Exception
  +   {
  +      cache.put("/a/b/c", null);
  +      tx.begin();
  +      cache.remove("/a/b/c");
  +      // this node should now be locked.
  +      Transaction t = cache.getTransactionManager().suspend();
  +      Thread th = new Thread(){
  +         public void run(){
  +            try
  +            {
  +               System.out.println(cache.printLockInfo());
  +               cache.get("/a/b/c"); // should fail
  +
  +               fail("Should not be able to get a hold of /a/b/c until the deleting tx completes");
  +            }
  +            catch (Exception e)
  +            {
  +               // expected
         }
  -      if(lock.isOwner(owner) == false)
  -         throw new Exception("owner " + owner + "is not owner");
      }
  +      };
  +
  +      th.start();
  +      th.join();
  +
  +      cache.getTransactionManager().resume(t);
  +      tx.rollback();
  +
  +      assertNotNull(cache.get("/a/b/c"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +   }
  +
   
   
      public void testRemove() throws CacheException, SystemException, NotSupportedException, HeuristicMixedException, HeuristicRollbackException, RollbackException {
  @@ -385,7 +603,9 @@
         tx.begin();
         cache.remove("/a/b/c");
         System.out.println("locks held (after removing /a/b/c): \n" + cache.printLockInfo());
  -      assertEquals(2, cache.getNumberOfLocksHeld());
  +      // this used to test for 2 locks held.  After the fixes for JBCACHE-875 however, 2 more locks are acquired - for the root node as well as the deleted node.
  +      // and since we would lock all children of the deleted node as well, we have 10 locks here.
  +      assertEquals(10, cache.getNumberOfLocksHeld());
         tx.commit();
         System.out.println("locks held (after committing /a/b/c): \n" + cache.printLockInfo());
         assertEquals(0, cache.getNumberOfLocksHeld());
  @@ -406,7 +626,7 @@
         System.out.println("locks held (before removing /a/b/c): \n" + cache.printLockInfo());
         cache.remove("/a/b/c");
         System.out.println("locks held (after removing /a/b/c): \n" + cache.printLockInfo());
  -      assertEquals(2, cache.getNumberOfLocksHeld());
  +      assertEquals(10, cache.getNumberOfLocksHeld());
         tx.rollback();
         System.out.println("locks held (after rollback): \n" + cache.printLockInfo());
         assertEquals(0, cache.getNumberOfLocksHeld());
  @@ -594,7 +814,7 @@
         cache.remove(FQN);
         cache.put(FQN, "entry", "rollback");
         tx.rollback();
  -      assertEquals("Node should keep the commited value", "commit", cache.get(FQN).get("entry")); // THIS FAILS
  +      assertEquals("Node should keep the commited value", "commit", cache.get(FQN).get("entry"));
      }
   
   
  
  
  


From msurtani at jboss.com  Tue Dec  5 10:27:51 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:51 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1GrcD1-0000Ou-Um@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:51

  Modified:    tests/functional/org/jboss/cache/passivation  Tag:
                        Branch_JBossCache_1_4_0 PassivationTestsBase.java
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.1  +16 -8     JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java,v
  retrieving revision 1.13
  retrieving revision 1.13.2.1
  diff -u -b -r1.13 -r1.13.2.1
  --- PassivationTestsBase.java	8 Apr 2006 05:24:39 -0000	1.13
  +++ PassivationTestsBase.java	5 Dec 2006 15:27:51 -0000	1.13.2.1
  @@ -3,27 +3,35 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -import org.jboss.cache.*;
  -import org.jboss.cache.xml.XmlHelper;
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheException;
  +import org.jboss.cache.DataNode;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.Modification;
  +import org.jboss.cache.TreeCache;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.loader.SamplePojo;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.transaction.DummyTransactionManager;
  +import org.jboss.cache.xml.XmlHelper;
   import org.w3c.dom.Element;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.Transaction;
   import java.io.Serializable;
  -import java.util.*;
  -
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import java.util.ArrayList;
  +import java.util.HashMap;
  +import java.util.Iterator;
  +import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
   
   /**
    * Base tests for passivation using any of the cache loaders
    * 
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationTestsBase.java,v 1.13 2006/04/08 05:24:39 genman Exp $
  + * @version $Id: PassivationTestsBase.java,v 1.13.2.1 2006/12/05 15:27:51 msurtani Exp $
    */
   abstract public class PassivationTestsBase extends TestCase {
   
  @@ -780,7 +788,7 @@
         assertTrue(children.contains("1"));
         assertTrue(children.contains("2"));
         assertTrue(children.contains("3"));
  -      assertEquals(4, cache.getNumberOfLocksHeld());
  +      assertEquals(5, cache.getNumberOfLocksHeld());
         tx.commit();
      }
   
  
  
  


From msurtani at jboss.com  Tue Dec  5 10:27:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:52 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock    ...
Message-ID: <E1GrcD2-0000PB-4Z@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:52

  Modified:    tests/functional/org/jboss/cache/lock    Tag:
                        Branch_JBossCache_1_4_0
                        ReadWriteLockWithUpgradeTest.java
                        UpgradeLockTest.java LockReleaseTest.java
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.2.1   +124 -0    JBossCache/tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReadWriteLockWithUpgradeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java,v
  retrieving revision 1.2
  retrieving revision 1.2.2.1
  diff -u -b -r1.2 -r1.2.2.1
  --- ReadWriteLockWithUpgradeTest.java	5 May 2006 12:06:58 -0000	1.2
  +++ ReadWriteLockWithUpgradeTest.java	5 Dec 2006 15:27:52 -0000	1.2.2.1
  @@ -5,11 +5,15 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.jboss.cache.misc.TestingUtil;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.DataNode;
   
   import java.io.FileWriter;
   import java.io.IOException;
   import java.io.Writer;
   import java.util.Vector;
  +import java.util.ArrayList;
  +import java.util.List;
   
   /**
    * NonBlockingWriterLock is a read/write lock (with upgrade) that has
  @@ -615,5 +619,125 @@
         if (t1.isAlive() || t2.isAlive())
            fail("Possible deadlock resulted in testRead.");
      }
  +
  +   public void testCacheContentionOnRoot() throws Exception
  +    {
  +       final int threads = 10, loops = 100;
  +       TreeCache cache = null;
  +       try
  +       {
  +          cache = new TreeCache();
  +          cache.startService();
  +          final DataNode root = cache.getRoot();
  +          final List exceptions = new ArrayList();
  +          final List timeouts = new ArrayList();
  +
  +
  +          // get a hold of the WL first
  +          root.acquire(Thread.currentThread(), 10, DataNode.LOCK_TYPE_WRITE);
  +
  +          Thread[] t = new Thread[threads];
  +
  +          for (int i=0; i<t.length; i++)
  +          {
  +             t[i] = new Thread()
  +             {
  +                public void run()
  +                {
  +                   for (int i=0; i<loops; i++)
  +                   {
  +                      try
  +                      {
  +                         root.acquire(Thread.currentThread(), 10, DataNode.LOCK_TYPE_WRITE);
  +                      }
  +                      catch (TimeoutException te)
  +                      {
  +                         // expected
  +                         timeouts.add( te );
  +                      }
  +                      catch (Exception ex)
  +                      {
  +                         ex.printStackTrace();
  +                         exceptions.add(ex);
  +                      }
  +                   }
  +                }
  +             };
  +
  +             t[i].start();
  +          }
  +
  +          for (int i=0; i<t.length; i++) t[i].join();
  +          root.releaseAll(Thread.currentThread());
  +
  +          // we should have 0 exceptions
  +          assertEquals(0, exceptions.size());
  +       }
  +       finally
  +       {
  +          if (cache != null) cache.stopService();
  +       }
  +    }
  +
  +
  +    public void testCacheContentionOnNode() throws Exception
  +    {
  +       final int threads = 10, loops = 100;
  +       TreeCache cache = null;
  +       try
  +       {
  +          cache = new TreeCache();
  +          cache.startService();
  +          cache.put("/test/node", null);
  +          final DataNode node = cache.get("/test/node");
  +          final List exceptions = new ArrayList();
  +          final List timeouts = new ArrayList();
  +
  +
  +          // get a hold of the WL first
  +          node.acquire(Thread.currentThread(), 10, DataNode.LOCK_TYPE_WRITE);
  +
  +          Thread[] t = new Thread[threads];
  +
  +          for (int i=0; i<t.length; i++)
  +          {
  +             t[i] = new Thread()
  +             {
  +                public void run()
  +                {
  +                   for (int i=0; i<loops; i++)
  +                   {
  +                      try
  +                      {
  +                         node.acquire(Thread.currentThread(), 10, DataNode.LOCK_TYPE_WRITE);
  +                      }
  +                      catch (TimeoutException te)
  +                      {
  +                         // expected
  +                         timeouts.add( te );
  +                      }
  +                      catch (Exception ex)
  +                      {
  +                         ex.printStackTrace();
  +                         exceptions.add(ex);
  +                      }
  +                   }
  +                }
  +             };
  +
  +             t[i].start();
  +          }
  +
  +          for (int i=0; i<t.length; i++) t[i].join();
  +          node.releaseAll(Thread.currentThread());
  +
  +          // we should have 0 exceptions
  +          assertEquals(0, exceptions.size());
  +       }
  +       finally
  +       {
  +          if (cache != null) cache.stopService();
  +       }
  +    }
   }
   
  
  
  
  1.2.2.1   +2 -2      JBossCache/tests/functional/org/jboss/cache/lock/UpgradeLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UpgradeLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/UpgradeLockTest.java,v
  retrieving revision 1.2
  retrieving revision 1.2.2.1
  diff -u -b -r1.2 -r1.2.2.1
  --- UpgradeLockTest.java	5 May 2006 12:06:58 -0000	1.2
  +++ UpgradeLockTest.java	5 Dec 2006 15:27:52 -0000	1.2.2.1
  @@ -24,7 +24,7 @@
    * Tests upgrade locks from read -> write
    *
    * @author Bela Ban
  - * @version $Id: UpgradeLockTest.java,v 1.2 2006/05/05 12:06:58 msurtani Exp $
  + * @version $Id: UpgradeLockTest.java,v 1.2.2.1 2006/12/05 15:27:52 msurtani Exp $
    */
   public class UpgradeLockTest extends TestCase {
      TreeCache cache=null;
  @@ -123,7 +123,7 @@
         cache=createCache(l);
         tx.begin();
   
  -      int expected_num_locks=l == IsolationLevel.NONE? 0 : 1;
  +      int expected_num_locks=l == IsolationLevel.NONE? 0 : 2;
   
         cache.put(NODE1, null);
         assertEquals(expected_num_locks, cache.getNumberOfLocksHeld());
  
  
  
  1.1.20.1  +14 -15    JBossCache/tests/functional/org/jboss/cache/lock/LockReleaseTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockReleaseTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/LockReleaseTest.java,v
  retrieving revision 1.1
  retrieving revision 1.1.20.1
  diff -u -b -r1.1 -r1.1.20.1
  --- LockReleaseTest.java	8 Jul 2005 05:58:11 -0000	1.1
  +++ LockReleaseTest.java	5 Dec 2006 15:27:52 -0000	1.1.20.1
  @@ -14,7 +14,6 @@
   import org.apache.commons.logging.Log;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
  -import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
  @@ -27,7 +26,7 @@
    * Verifies that there are no read locks held when a transaction ends.
    *
    * @author Bela Ban
  - * @version $Id: LockReleaseTest.java,v 1.1 2005/07/08 05:58:11 msurtani Exp $
  + * @version $Id: LockReleaseTest.java,v 1.1.20.1 2006/12/05 15:27:52 msurtani Exp $
    */
   public class LockReleaseTest extends TestCase {
      TreeCache cache=null;
  @@ -142,11 +141,11 @@
   
         tx.begin();
         keys=cache.getKeys(NODE1);
  -      assertEquals("we should hold 1 read locks now: ", 1, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 2 read locks now: ", 2, cache.getNumberOfLocksHeld());
         keys=cache.getKeys(NODE2);
  -      assertEquals("we should hold 3 read locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 4 read locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
  -      assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
  +      assertEquals("we should have released all 4 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
   
   
  @@ -164,11 +163,11 @@
   
         tx.begin();
         keys=cache.getChildrenNames(NODE1);
  -      assertEquals("we should hold 1 read locks now: ", 1, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 2 read locks now: ", 2, cache.getNumberOfLocksHeld());
         keys=cache.getChildrenNames(NODE2);
  -      assertEquals("we should hold 3 read locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 4 read locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
  -      assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
  +      assertEquals("we should have released all 4 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
   
      public void testPrint() throws Exception {
  @@ -183,11 +182,11 @@
   
         tx.begin();
         cache.print(NODE1);
  -      assertEquals("we should hold 1 read locks now (for print()): ", 1, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 2 read locks now (for print()): ", 2, cache.getNumberOfLocksHeld());
         cache.print(NODE2);
  -      assertEquals("we should hold 3 read locks now (for print()): ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 4 read locks now (for print()): ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
  -      assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
  +      assertEquals("we should have released all 4 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
   
   
  @@ -202,9 +201,9 @@
         tx.begin();
         assertEquals(VAL1, cache.get(NODE1, KEY));
         assertEquals(VAL1, cache.get(NODE2, KEY));
  -      assertEquals("we should hold 3 read locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 4 read locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
  -      assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
  +      assertEquals("we should have released all 4 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
   
      void testWriteLockRelease(IsolationLevel level) throws Exception {
  @@ -218,9 +217,9 @@
         tx.begin();
         cache.put(NODE1, KEY, VAL1);
         cache.put(NODE2, KEY, VAL1);
  -      assertEquals("we should hold 3 write locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 4 write locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
  -      assertEquals("we should have released all 3 write locks: ", 0, cache.getNumberOfLocksHeld());
  +      assertEquals("we should have released all 4 write locks: ", 0, cache.getNumberOfLocksHeld());
      }
   
      void log(String msg) {
  
  
  


From msurtani at jboss.com  Tue Dec  5 10:27:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 10:27:52 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrcD2-0000PM-Mt@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 10:27:52

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Ported stuff from 1.3.0.SP4 + upgraded JGroups
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.27 +5 -44     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.26
  retrieving revision 1.195.2.27
  diff -u -b -r1.195.2.26 -r1.195.2.27
  --- TreeCache.java	5 Dec 2006 00:01:51 -0000	1.195.2.26
  +++ TreeCache.java	5 Dec 2006 15:27:52 -0000	1.195.2.27
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.26 2006/12/05 00:01:51 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.27 2006/12/05 15:27:52 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -4311,16 +4311,10 @@
         if (log.isTraceEnabled())
            log.trace("callRemoteMethods(): valid members are " + validMembers + " method: " + method_call);
   
  -      // this is a temporary workaround (JBCACHE-813) until AnyCast (JGRP-338) is available.
  -      if (useTcpWorkaround())
  -      {
  -         // use a UNICAST
  -         rsps = multipleUnicast(validMembers, method_call, mode, timeout);
  -      }
  -      else
  -      {
  -         rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout);
  -      }
  +
  +      // if we are using buddy replication, all calls should use ANYCAST.  Otherwise, use the default (multicast).
  +      rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout, buddyManager != null && buddyManager.isEnabled());
  +
   
         // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
         // JGroups supports http://jira.jboss.com/jira/browse/JGRP-193
  @@ -4359,39 +4353,6 @@
         return retval;
      }
   
  -   boolean useTcpWorkaround()
  -   {
  -      return channel.getProtocolStack().findProtocol("UDP") == null;
  -   }
  -
  -   /**
  -    * This is a workaround for JBCACHE-813
  -    */
  -   private RspList multipleUnicast(List recipients, MethodCall call, int mode, long timeout) throws Exception
  -   {
  -      if (recipients == null || recipients.isEmpty()) return null;
  -
  -      Iterator i = recipients.iterator();
  -      RspList rsps = new RspList();
  -
  -      while (i.hasNext())
  -      {
  -         Address recipient = (Address) i.next();
  -         Object r = null;
  -         try
  -         {
  -            r = disp.callRemoteMethod(recipient, call, mode, timeout);
  -         }
  -         catch (Throwable throwable)
  -         {
  -            throw new Exception(throwable);
  -         }
  -         rsps.addRsp(recipient, r);
  -      }
  -      return rsps;
  -   }
  -
  -
      /**
       * @param members
       * @param method
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:38 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog  ...
Message-ID: <E1Grd26-0001PW-T1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:38

  Modified:    examples/blog  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.14      +2 -1      jboss-seam/examples/blog/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/build.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- build.xml	5 Dec 2006 13:29:37 -0000	1.13
  +++ build.xml	5 Dec 2006 16:20:38 -0000	1.14
  @@ -8,7 +8,8 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"    value="yes"/>
   	<property name="example.ds"              value="blog-ds.xml"/>
       <property name="src.java.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking  ...
Message-ID: <E1Grd27-0001Pd-2s@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:39

  Modified:    examples/booking  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.46      +2 -1      jboss-seam/examples/booking/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/build.xml,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- build.xml	5 Dec 2006 13:23:39 -0000	1.45
  +++ build.xml	5 Dec 2006 16:20:39 -0000	1.46
  @@ -7,7 +7,8 @@
       <property name="example.name"           value="jboss-seam-booking"/>
   	
       <!-- Overrides -->
  -	<property name="example.seam.lib"       value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"   value="yes"/>
   	<property name="example.ds"             value="booking-ds.xml"/>
       <property name="src.java.dir"           value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/contactlist  ...
Message-ID: <E1Grd27-0001Pk-8u@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:39

  Modified:    examples/contactlist  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.9       +2 -1      jboss-seam/examples/contactlist/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/contactlist/build.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- build.xml	5 Dec 2006 13:29:37 -0000	1.8
  +++ build.xml	5 Dec 2006 16:20:39 -0000	1.9
  @@ -8,7 +8,8 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools  ...
Message-ID: <E1Grd27-0001Pr-Cv@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:39

  Modified:    examples/drools  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/examples/drools/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- build.xml	5 Dec 2006 13:29:38 -0000	1.2
  +++ build.xml	5 Dec 2006 16:20:39 -0000	1.3
  @@ -8,7 +8,7 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
   	<property name="example.jbpm.lib"        value="yes"/>
   	<property name="example.drools.lib"      value="yes"/>
       <property name="src.java.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore  ...
Message-ID: <E1Grd27-0001Py-IY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:39

  Modified:    examples/dvdstore  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.39      +2 -1      jboss-seam/examples/dvdstore/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/build.xml,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -b -r1.38 -r1.39
  --- build.xml	5 Dec 2006 13:23:40 -0000	1.38
  +++ build.xml	5 Dec 2006 16:20:39 -0000	1.39
  @@ -9,7 +9,8 @@
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="lib"/>
   	<property name="example.docroot.dir"     value="web"/>
  -    <property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"    value="yes"/>
       <property name="example.jbpm.lib"        value="yes"/>
   	<property name="example.ds"              value="dvd-ds.xml"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate  ...
Message-ID: <E1Grd27-0001Q5-Na@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:39

  Modified:    examples/hibernate  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.14      +2 -1      jboss-seam/examples/hibernate/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate/build.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- build.xml	5 Dec 2006 13:26:13 -0000	1.13
  +++ build.xml	5 Dec 2006 16:20:39 -0000	1.14
  @@ -8,7 +8,8 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"    value="yes"/>
   	<property name="example.ds"              value="hibernate-ds.xml"/>
       <property name="src.java.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:39 -0500
Subject: [jboss-cvs] jboss-seam/examples/icefaces  ...
Message-ID: <E1Grd27-0001QM-Tc@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:39

  Modified:    examples/icefaces  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.7       +2 -1      jboss-seam/examples/icefaces/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/build.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- build.xml	5 Dec 2006 13:26:12 -0000	1.6
  +++ build.xml	5 Dec 2006 16:20:39 -0000	1.7
  @@ -7,7 +7,8 @@
       <property name="example.name"           value="jboss-seam-icefaces"/>
   	
       <!-- Overrides -->
  -	<property name="example.seam.lib"       value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.ds"             value="icefaces-ds.xml"/>
       <property name="src.java.dir"           value="src"/>
       <property name="src.test.dir"           value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages  ...
Message-ID: <E1Grd28-0001QT-2d@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:40

  Modified:    examples/messages  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.13      +1 -1      jboss-seam/examples/messages/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/build.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- build.xml	5 Dec 2006 13:29:38 -0000	1.12
  +++ build.xml	5 Dec 2006 16:20:40 -0000	1.13
  @@ -8,7 +8,7 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
       <property name="test.classpath"          value="test.eejb.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/numberguess  ...
Message-ID: <E1Grd28-0001Qa-7B@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:40

  Modified:    examples/numberguess  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.17      +1 -1      jboss-seam/examples/numberguess/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/build.xml,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- build.xml	5 Dec 2006 13:29:39 -0000	1.16
  +++ build.xml	5 Dec 2006 16:20:40 -0000	1.17
  @@ -8,7 +8,7 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
   	<property name="example.jbpm.lib"        value="yes"/>
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/chatroom  ...
Message-ID: <E1Grd28-0001Qh-DV@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:40

  Modified:    examples/remoting/chatroom  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.11      +2 -1      jboss-seam/examples/remoting/chatroom/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/chatroom/build.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- build.xml	5 Dec 2006 13:20:22 -0000	1.10
  +++ build.xml	5 Dec 2006 16:20:40 -0000	1.11
  @@ -8,7 +8,8 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"    value="yes"/>
   	<property name="example.cache.lib"       value="yes"/>
       <property name="src.java.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay  ...
Message-ID: <E1Grd28-0001Qo-Iq@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:40

  Modified:    examples/seampay  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.3       +2 -1      jboss-seam/examples/seampay/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/build.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- build.xml	5 Dec 2006 13:29:39 -0000	1.2
  +++ build.xml	5 Dec 2006 16:20:40 -0000	1.3
  @@ -8,7 +8,8 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
  +	<property name="example.seam.debug.lib"  value="yes"/>
   	<property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:20:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:20:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/todo  ...
Message-ID: <E1Grd28-0001Qv-OX@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:20:40

  Modified:    examples/todo  build.xml
  Log:
  fix the jsp examples
  
  Revision  Changes    Path
  1.19      +1 -1      jboss-seam/examples/todo/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/todo/build.xml,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- build.xml	5 Dec 2006 13:29:39 -0000	1.18
  +++ build.xml	5 Dec 2006 16:20:40 -0000	1.19
  @@ -8,7 +8,7 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  -	<property name="example.seam.lib"        value="yes"/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
   	<property name="example.jbpm.lib"        value="yes"/>
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 11:21:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:21:02 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1Grd2U-0001S5-TW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:21:02

  Modified:    jboss-seam  build.xml
  Log:
  make it work on tomcat
  
  Revision  Changes    Path
  1.116     +31 -58    jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.115
  retrieving revision 1.116
  diff -u -b -r1.115 -r1.116
  --- build.xml	5 Dec 2006 13:31:06 -0000	1.115
  +++ build.xml	5 Dec 2006 16:21:02 -0000	1.116
  @@ -89,51 +89,30 @@
           <include name="drools/lib/*.jar"/>
       </fileset>
       
  -    <zipfileset id="seam.jar" 
  +    <zipfileset id="example.seam.jar" 
                  dir="${imported.basedir}"
  -            description="the main Seam jar">
  +    	    prefix="WEB-INF/lib"
  +       description="the Seam jars">
           <include name="${name}.jar"/>
  +    	<include name="jboss-seam-debug.jar" if="example.seam.debug.lib"/>
  +        <include name="jboss-seam-ui.jar" if="example.seam.ui.lib"/>
       </zipfileset>
       
  -    <zipfileset id="el.jar" 
  +    <zipfileset id="example.extra.jar" 
                  dir="${lib.dir}"
  -            description="the unified EL jars">
  +       description="extra jars for the EAR">
           <include name="el-*.jar" />
  -    </zipfileset>
  -	
  -    <zipfileset id="jbpm.jar" 
  -               dir="${lib.dir}" 
  -            description="the jBPM jar">
           <include name="jbpm*.jar" if="example.jbpm.lib"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="drools.jar" 
  -               dir="${drools.lib.dir}" 
  -            description="the Drools jars">
  -    	<include name="*.jar" if="example.drools.lib"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="cache.jar" 
  -               dir="${lib.dir}" 
  -            description="the JBoss Cache and JGroups jars">
  +        <include name="jsf-facelets.jar" if="example.facelets.lib"/>
           <include name="jboss-cache-jdk50.jar" if="example.cache.lib"/>
           <include name="jboss-aop-jdk50.jar" if="example.cache.lib"/>
           <include name="jgroups.jar" if="example.cache.lib"/>
       </zipfileset>
           
  -    <zipfileset id="seam.extra.jar" 
  -               dir="${imported.basedir}"
  -    	    prefix="WEB-INF/lib"
  -            description="the extra Seam jars">
  -        <include name="jboss-seam-ui.jar" if="example.seam.lib"/>
  -    	<include name="jboss-seam-debug.jar" if="example.seam.lib"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="facelets.jar" 
  -            dir="${lib.dir}"
  -    	 prefix="WEB-INF/lib"
  -            description="the facelets jar">
  -        <include name="jsf-facelets.jar" if="example.facelets.lib"/>
  +    <zipfileset id="example.drools.jar" 
  +               dir="${drools.lib.dir}" 
  +       description="the Drools jars">
  +    	<include name="*.jar" if="example.drools.lib"/>
       </zipfileset>
       
       <fileset id="example.resources" 
  @@ -220,31 +199,30 @@
               prefix="WEB-INF/lib"
               dir="${imported.basedir}">
           <include name="${name}.jar"/>
  +    	<include name="jboss-seam-debug.jar" if="example.seam.debug.lib"/>
  +        <include name="jboss-seam-ui.jar" if="example.seam.ui.lib"/>
       </zipfileset>
       
       <zipfileset id="example.tomcat.drools.jar" 
       	    prefix="WEB-INF/lib"
               dir="${drools.lib.dir}">
  -    	<include name="${example.drools.lib}"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.tomcat.cache.jar" 
  -    	    prefix="WEB-INF/lib"
  -            dir="${lib.dir}">
  -        <include name="${example.cache.lib}"/>
  -        <include name="${example.jgroups.lib}"/>
  +    	<include name="*.jar" if="example.drools.lib"/>
       </zipfileset>
       
  -    <zipfileset id="example.tomcat.jbpm.jar" 
  +    <zipfileset id="example.tomcat.extra.jar" 
       	    prefix="WEB-INF/lib"
               dir="${lib.dir}">
  -    	<include name="${example.jbpm.lib}"/>
  +        <include name="jsf-facelets.jar" if="example.facelets.lib"/>
  +        <include name="jboss-cache-jdk50.jar" if="example.cache.lib"/>
  +    	<include name="jboss-aop-jdk50.jar" if="example.cache.lib"/>
  +        <include name="jgroups.jar" if="example.cache.lib"/>
  +    	<include name="jbpm*.jar" if="example.jbpm.lib"/>
       </zipfileset>
       
       <path id="build.classpath">
           <path refid="example.path"/>
           <fileset refid="lib"/>
  -        <fileset refid="seam.jar"/>
  +        <fileset refid="example.seam.jar"/>
       </path>
       
       <property name="test.classpath" value="test.classpath"/>
  @@ -959,11 +937,9 @@
   
       <target name="ear" depends="ejb3, war">
           <jar destfile="${build.dir}/${example.name}.ear">
  -            <fileset refid="seam.jar"/>
  -        	<fileset refid="el.jar"/>
  -            <fileset refid="drools.jar"/>
  -            <fileset refid="cache.jar"/>
  -            <fileset refid="jbpm.jar"/>
  +            <fileset refid="example.seam.jar"/>
  +            <fileset refid="example.drools.jar"/>
  +            <fileset refid="example.extra.jar"/>
               <zipfileset dir="${build.dir}">
                   <include name="${example.name}.jar"/>
               </zipfileset>
  @@ -1022,12 +998,9 @@
               <zipfileset refid="example.tomcat.lib"/>
               <zipfileset refid="example.tomcat.seam.jar"/>
           	<zipfileset refid="example.tomcat.drools.jar"/>
  -        	<zipfileset refid="example.tomcat.cache.jar"/>
  -        	<zipfileset refid="example.tomcat.jbpm.jar"/>
  +        	<zipfileset refid="example.tomcat.extra.jar"/>
               <zipfileset refid="example.war.docroot"/>
               <zipfileset refid="example.war.webinf.lib"/>
  -        	<zipfileset refid="facelets.jar"/>
  -        	<zipfileset refid="seam.extra.jar"/>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
               </zipfileset>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 11:22:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 11:22:17 -0500
Subject: [jboss-cvs] JBossAS SVN: r58845 -
	trunk/server/src/main/org/jboss/metadata
Message-ID: <E1Grd3h-0001SJ-RI@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 11:22:16 -0500 (Tue, 05 Dec 2006)
New Revision: 58845

Modified:
   trunk/server/src/main/org/jboss/metadata/BeanMetaData.java
Log:
add a method to add SecurityRoleRefMetaData

Modified: trunk/server/src/main/org/jboss/metadata/BeanMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/BeanMetaData.java	2006-12-05 05:09:16 UTC (rev 58844)
+++ trunk/server/src/main/org/jboss/metadata/BeanMetaData.java	2006-12-05 16:22:16 UTC (rev 58845)
@@ -114,7 +114,7 @@
    /** The HashMap<ServiceRefMetaData> service-ref element(s) info */
    private HashMap serviceReferences = new HashMap();
    /** The security-role-ref element(s) info */
-   private ArrayList securityRoleReferences = new ArrayList();
+   private ArrayList<SecurityRoleRefMetaData> securityRoleReferences = new ArrayList<SecurityRoleRefMetaData>();
    /** The security-idemtity element info */
    private SecurityIdentityMetaData securityIdentity = null;
    /** */
@@ -1019,6 +1019,11 @@
       this.securityProxy = securityProxy;
    }
 
+   public void addSecurityRoleReference(SecurityRoleRefMetaData srrf)
+   {
+      this.securityRoleReferences.add(srrf);
+   }
+   
    public void setSecurityRoleReferences(ArrayList securityRoleReferences)
    {
       this.securityRoleReferences = securityRoleReferences;



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 11:22:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 11:22:58 -0500
Subject: [jboss-cvs] JBossAS SVN: r58846 -
	trunk/server/src/main/org/jboss/deployment
Message-ID: <E1Grd4M-0001Sh-UZ@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 11:22:57 -0500 (Tue, 05 Dec 2006)
New Revision: 58846

Modified:
   trunk/server/src/main/org/jboss/deployment/EjbJarObjectFactory.java
Log:
handle security role-ref in ejb-jar.xml

Modified: trunk/server/src/main/org/jboss/deployment/EjbJarObjectFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/EjbJarObjectFactory.java	2006-12-05 16:22:16 UTC (rev 58845)
+++ trunk/server/src/main/org/jboss/deployment/EjbJarObjectFactory.java	2006-12-05 16:22:57 UTC (rev 58846)
@@ -37,6 +37,7 @@
 import org.jboss.metadata.RelationshipRoleMetaData;
 import org.jboss.metadata.SecurityIdentityMetaData;
 import org.jboss.metadata.SecurityRoleMetaData;
+import org.jboss.metadata.SecurityRoleRefMetaData;
 import org.jboss.metadata.SessionMetaData;
 import org.jboss.metadata.BeanMetaData;
 import org.jboss.metadata.ActivationConfigPropertyMetaData;
@@ -184,6 +185,8 @@
       {
          return child;
       }
+      else if(localName.equals("security-role-ref"))
+         child = new SecurityRoleRefMetaData();
       else if (localName.equals("security-identity"))
       {
          child = new SecurityIdentityMetaData();
@@ -234,6 +237,8 @@
          return child;
       else if (localName.equals("security-identity"))
          child = new SecurityIdentityMetaData();
+      else if(localName.equals("security-role-ref"))
+         child = new SecurityRoleRefMetaData();
       else if(log.isTraceEnabled())
       {
          log.trace("Ignoring child of session: " + localName);
@@ -344,7 +349,7 @@
          parent.setUseCallerIdentity(true);
       }
       return null;
-   }
+   } 
 
    public Object newChild(MethodPermission parent, UnmarshallingContext navigator,
          String namespaceURI, String localName, Attributes attrs)
@@ -405,6 +410,12 @@
    {
       parent.setSecurityIdentityMetaData(child);
    }
+   
+   public void addChild(EntityMetaData parent, SecurityRoleRefMetaData child,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   { 
+      parent.addSecurityRoleReference(child);
+   }
 
    public void addChild(EntityMetaData parent, CMPFieldMetaData field,
          UnmarshallingContext navigator, String namespaceURI, String localName)
@@ -465,6 +476,12 @@
    {
       parent.setSecurityIdentityMetaData(child);
    }
+   
+   public void addChild(SessionMetaData parent, SecurityRoleRefMetaData child,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   {
+      parent.addSecurityRoleReference(child);
+   }
 
    public void addChild(SessionMetaData parent, EjbLocalRefMetaData child,
          UnmarshallingContext navigator, String namespaceURI, String localName)
@@ -1012,6 +1029,23 @@
       }
    }
    
+   /**
+    * <!ELEMENT security-role-ref (rolename,role-link))>
+    */
+   public void setValue(SecurityRoleRefMetaData parent,
+         UnmarshallingContext navigator, String namespaceURI, String localName,
+         String value)
+   {
+      if(localName.equals("role-name"))
+      {
+         parent.setName(value); 
+      }
+      else if(localName.equals("role-link"))
+      {
+         parent.setLink(value); 
+      }
+   }
+   
    public void setValue(MessageDestinationMetaData mdmd,
          UnmarshallingContext navigator, String namespaceURI, String localName,
          String value)



From c46 at fullmailmarket.com  Tue Dec  5 11:23:48 2006
From: c46 at fullmailmarket.com (FonoIP)
Date: Tue, 5 Dec 2006 13:23:48 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Telefon=EDa_IP_al_alcance_de_TODOS!?=
Message-ID: <200612051623.kB5GNqo0028263@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061205/0ab4f2a7/attachment.html 

From gavin.king at jboss.com  Tue Dec  5 11:30:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 11:30:02 -0500
Subject: [jboss-cvs] jboss-seam/lib  ...
Message-ID: <E1GrdBC-0001Yq-IL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 11:30:02

  Removed:     lib      mailstuff.jar
  Log:
  remove mailstuff


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 11:35:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 11:35:38 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1707 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GrdGc-0001fG-NR@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-05 11:35:36 -0500 (Tue, 05 Dec 2006)
New Revision: 1707

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Fixing Test

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 15:25:53 UTC (rev 1706)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 16:35:36 UTC (rev 1707)
@@ -85,34 +85,34 @@
       {
          ServerManagement.start("all", 0);
          ServerManagement.start("all", 1);
-//         ServerManagement.start("all", 2);
+         ServerManagement.start("all", 2);
 
-//         ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
-//         ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
-//
-//         ServerManagement.deployClusteredQueue("testDistributedQueue", 1);
-//         ServerManagement.deployClusteredTopic("testDistributedTopic", 1);
-//
-//         ServerManagement.deployClusteredQueue("testDistributedQueue", 2);
-//         ServerManagement.deployClusteredTopic("testDistributedTopic", 2);
-//
-//         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-//         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-//         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-//
-//         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
-//         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-//         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
-//
-//         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
-//         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-//         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
-//
-//         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-//         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-//         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
-//
-//         drainQueues();
+         ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
+         ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
+
+         ServerManagement.deployClusteredQueue("testDistributedQueue", 1);
+         ServerManagement.deployClusteredTopic("testDistributedTopic", 1);
+
+         ServerManagement.deployClusteredQueue("testDistributedQueue", 2);
+         ServerManagement.deployClusteredTopic("testDistributedTopic", 2);
+
+         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+
+         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
+         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
+         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
+
+         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
+         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
+         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
+
+         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
+         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
+         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
+
+         drainQueues();
       }
       catch (Exception e)
       {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-05 15:25:53 UTC (rev 1706)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-05 16:35:36 UTC (rev 1707)
@@ -25,7 +25,6 @@
 import javax.jms.MessageConsumer;
 import javax.jms.TextMessage;
 import org.jboss.jms.message.MessageProxy;
-import org.jboss.logging.Logger;
 import org.jboss.test.messaging.tools.ServerManagement;
 
 /**
@@ -54,8 +53,6 @@
 
    public void testLeaveFailover() throws Exception
    {
-      log.info("XXXXXXXXXXXXXXX DONE XXXXXXXXXXXXXXXXXXXXXX");
-      Thread.sleep(999999999);
       try
       {
          System.out.println("Number of nodes on Cluster = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());



From msurtani at jboss.com  Tue Dec  5 11:35:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 11:35:49 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache  ...
Message-ID: <E1GrdGn-0001fp-Mu@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 11:35:49

  Modified:    tests/stress/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        LocalStressTest.java
  Log:
  Ported stuff from 1.3.0.SP4
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.1   +14 -4     JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java,v
  retrieving revision 1.3
  retrieving revision 1.3.2.1
  diff -u -b -r1.3 -r1.3.2.1
  --- LocalStressTest.java	31 May 2006 14:08:39 -0000	1.3
  +++ LocalStressTest.java	5 Dec 2006 16:35:49 -0000	1.3.2.1
  @@ -33,7 +33,7 @@
   /**
    * Local mode stress test for TreeCache.
    *
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.3.2.1 $
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
    */
   public class LocalStressTest extends TestCase
  @@ -139,6 +139,13 @@
         UserTransaction tx = null;
         tx = (UserTransaction) new InitialContext(p_).lookup("UserTransaction");
   
  +      // create "root" nodes to remove WL contention on /
  +      cache_.put("/", null);
  +      cache_.put("/0", null);
  +      cache_.put("/1", null);
  +      cache_.put("/2", null);
  +      cache_.put("/3", null);
  +
         RunThread t1 = new RunThread(tx, 1);
         RunThread t2 = new RunThread(tx, 2);
   
  @@ -200,9 +207,12 @@
            String node = (String) nodeList_.get(i);
            cache_.get(node, key);
            sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  -         cache_.put(node, key, value);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  -         cache_.remove(node, key);
  +
  +         // uncommenting these leads to a classic deadlock.
  +
  +//         cache_.put(node, key, value);
  +//         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +//         cache_.remove(node, key);
            tx_.commit();
         }
   
  
  
  


From gavin.king at jboss.com  Tue Dec  5 12:05:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 12:05:54 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Grdju-0002Z9-1P@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 12:05:54

  Modified:    seam-gen  build.xml
  Log:
  put el in the ear
  
  Revision  Changes    Path
  1.44      +6 -5      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.43
  retrieving revision 1.44
  diff -u -b -r1.43 -r1.44
  --- build.xml	2 Dec 2006 02:33:31 -0000	1.43
  +++ build.xml	5 Dec 2006 17:05:53 -0000	1.44
  @@ -345,7 +345,6 @@
   
           <copy todir="${project.home}/lib">
               <fileset dir="../lib"/>
  -            <fileset dir="../facelets/lib"/>
               <fileset dir="../">
                   <include name="jboss-seam.jar"/>
                   <include name="jboss-seam-ui.jar"/>
  @@ -458,7 +457,10 @@
           </copy>
           
           <copy todir="${project.home}Web/WebContent/WEB-INF/lib" overwrite="true">
  -            <fileset dir="../facelets/lib"/>
  +            <fileset dir="../lib">
  +            	<include name="jsf-facelets.jar"/>
  +            	<include name="el-*.jar"/>
  +            </fileset>
               <fileset file="../jboss-seam-debug.jar"/>
               <fileset file="../jboss-seam-ui.jar"/>
           </copy>
  @@ -533,9 +535,8 @@
                   <include name="jboss-seam-ui.jar" />
                   <include name="jboss-seam-debug.jar" />
               </fileset>
  -            <fileset dir="../facelets/lib">
  -                <include name="el-api.jar" />
  -                <include name="el-ri.jar" />
  +            <fileset dir="../lib">
  +                <include name="el-*.jar" />
                   <include name="jsf-facelets.jar" />
               </fileset>
           </copy>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 12:05:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 12:05:54 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/build-scripts  ...
Message-ID: <E1Grdju-0002ZG-65@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 12:05:54

  Modified:    seam-gen/build-scripts  build.xml
  Log:
  put el in the ear
  
  Revision  Changes    Path
  1.15      +2 -3      jboss-seam/seam-gen/build-scripts/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build-scripts/build.xml,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- build.xml	1 Dec 2006 00:48:10 -0000	1.14
  +++ build.xml	5 Dec 2006 17:05:54 -0000	1.15
  @@ -90,8 +90,6 @@
   		</copy>		
   		<copy todir="${war.dir}/WEB-INF/lib">
   			<fileset dir="${lib.dir}">
  -				<include name="el-api.jar" />
  -				<include name="el-ri.jar" />
   				<include name="jsf-facelets.jar" />
   				<include name="jboss-seam-debug.jar" />
   				<include name="jboss-seam-ui.jar" />
  @@ -114,6 +112,7 @@
   			<fileset dir="${lib.dir}">
   				<include name="jboss-seam.jar" />
   				<include name="jbpm*.jar" />
  +				<include name="el-*.jar" />
   			</fileset>
   		</copy>
   		<copy todir="${ear.dir}/META-INF">
  
  
  


From gavin.king at jboss.com  Tue Dec  5 12:05:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 12:05:54 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/build-scripts-wtp  ...
Message-ID: <E1Grdju-0002ZN-Ax@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 12:05:54

  Modified:    seam-gen/build-scripts-wtp  build.xml
  Log:
  put el in the ear
  
  Revision  Changes    Path
  1.7       +1 -2      jboss-seam/seam-gen/build-scripts-wtp/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build-scripts-wtp/build.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- build.xml	14 Nov 2006 08:08:08 -0000	1.6
  +++ build.xml	5 Dec 2006 17:05:54 -0000	1.7
  @@ -68,8 +68,6 @@
   		</copy>
   		<copy todir="${basedir}/exploded-archives/@projectName at .war/WEB-INF/lib">
   			<fileset dir="${lib.dir}">
  -				<include name="el-api.jar" />
  -				<include name="el-ri.jar" />
   				<include name="jsf-facelets.jar" />
   				<include name="jboss-seam-ui.jar" />
   				<include name="jboss-seam-debug.jar" />
  @@ -99,6 +97,7 @@
   			<fileset dir="${lib.dir}">
   				<include name="jboss-seam.jar" />
   				<include name="jbpm*.jar" />
  +				<include name="el-*.jar" />
   			</fileset>
   		</copy>
   		<copy todir="${basedir}/exploded-archives/@projectName at .ear/META-INF">
  
  
  


From gavin.king at jboss.com  Tue Dec  5 12:05:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 12:05:54 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1Grdju-0002ZU-FY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 12:05:54

  Modified:    seam-gen/resources/META-INF  application.xml
  Log:
  put el in the ear
  
  Revision  Changes    Path
  1.4       +6 -0      jboss-seam/seam-gen/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	3 Dec 2006 04:55:16 -0000	1.3
  +++ application.xml	5 Dec 2006 17:05:54 -0000	1.4
  @@ -21,5 +21,11 @@
      <module>
         <java>jbpm-3.1.2.jar</java>
      </module>
  +   <module>
  +      <java>el-api.jar</java>
  +   </module>
  +   <module>
  +      <java>el-ri.jar</java>
  +   </module>
       
   </application>
  \ No newline at end of file
  
  
  


From msurtani at jboss.com  Tue Dec  5 12:16:35 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 12:16:35 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrduF-0002io-Qk@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 12:16:35

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Ported stuff from 1.3.0.SP4
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.28 +12 -10    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.27
  retrieving revision 1.195.2.28
  diff -u -b -r1.195.2.27 -r1.195.2.28
  --- TreeCache.java	5 Dec 2006 15:27:52 -0000	1.195.2.27
  +++ TreeCache.java	5 Dec 2006 17:16:35 -0000	1.195.2.28
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.27 2006/12/05 15:27:52 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.28 2006/12/05 17:16:35 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -4152,10 +4152,12 @@
          }
       }
   
  -    private void scrubRemoveMarker(TreeNode n, boolean deep)
  +    public void scrubRemoveMarker(TreeNode n, boolean deep)
       {
          n.remove(REMOVAL_MARKER);
          // unmark children as well.
  +       if (deep)
  +       {
          Map children = n.getChildren();
          if (children != null && !children.isEmpty())
          {
  @@ -4166,10 +4168,10 @@
                scrubRemoveMarker((TreeNode) i.next(), true);
             }
          }
  -
  +       }
       }
   
  -    private boolean isMarkedForRemoval(TreeNode n)
  +    public boolean isMarkedForRemoval(TreeNode n)
       {
          return n.containsKey(REMOVAL_MARKER);
       }
  
  
  


From msurtani at jboss.com  Tue Dec  5 12:16:35 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 12:16:35 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GrduF-0002j0-Vj@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 12:16:35

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  Ported stuff from 1.3.0.SP4
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.3  +20 -3     JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.2
  retrieving revision 1.20.2.3
  diff -u -b -r1.20.2.2 -r1.20.2.3
  --- PessimisticLockInterceptor.java	5 Dec 2006 00:01:52 -0000	1.20.2.2
  +++ PessimisticLockInterceptor.java	5 Dec 2006 17:16:35 -0000	1.20.2.3
  @@ -36,7 +36,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.2 2006/12/05 00:01:52 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.3 2006/12/05 17:16:35 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -171,7 +171,7 @@
               {
                  lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, zeroLockTimeout ? 0 : lock_timeout, createIfNotExists, storeLockedNode);
               }
  -            while (!cache.exists(fqn)); // keep trying until we have the lock (fixes concurrent remove())
  +            while(!cache.exists(fqn)); // keep trying until we have the lock (fixes concurrent remove())
               // terminates successfully, or with (Timeout)Exception
            }
            else
  @@ -274,6 +274,13 @@
               }
            }
   
  +         // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  +         if (needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation))
  +         {
  +            reverseRemove(child_node);
  +         }
  +
  +
            // Try to acquire the lock; recording that we did if successful
            acquireNodeLock(child_node, owner, gtx, currentLockType, lock_timeout);
   
  @@ -302,6 +309,16 @@
         if (isRemoveNodeOperation && gtx != null) cache.getTransactionTable().get(gtx).addRemovedNode(fqn);
      }
   
  +   private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation)
  +   {
  +      return !isRemoveOperation && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
  +   }
  +
  +   private void reverseRemove(DataNode n)
  +   {
  +      cache.scrubRemoveMarker(n, false);
  +   }
  +
      private boolean writeLockNeeded(int lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
      {
         if (isRemoveOperation && currentNodeIndex == treeNodeSize - 2)
  @@ -310,7 +327,7 @@
         if (!isTargetNode(currentNodeIndex, treeNodeSize) && !cache.exists(new Fqn(currentFqn, targetFqn.get(currentNodeIndex + 1))))
            return createIfNotExists; // we're at a node in the tree, not yet at the target node, and we need to create the next node.  So we need a WL here.
   
  -      return lock_type == DataNode.LOCK_TYPE_WRITE && isTargetNode(currentNodeIndex, treeNodeSize) && createIfNotExists; //normal operation, write lock explicitly requested and this is the target to be written to.
  +      return lock_type == DataNode.LOCK_TYPE_WRITE && isTargetNode(currentNodeIndex, treeNodeSize) && (createIfNotExists || isRemoveOperation); //normal operation, write lock explicitly requested and this is the target to be written to.
      }
   
      private boolean isTargetNode(int nodePosition, int treeNodeSize)
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 12:21:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 12:21:05 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1708 - in
	branches/Branch_Client_Failover_Experiment:
	src/etc/server/default/deploy
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin/postoffice tests
	tests/bin tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/tools/jndi
Message-ID: <E1Grdyb-0002mA-Ck@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-05 12:20:56 -0500 (Tue, 05 Dec 2006)
New Revision: 1708

Modified:
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
Log:
More tweaks



Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-05 17:20:56 UTC (rev 1708)
@@ -67,8 +67,8 @@
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
       <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID) VALUES (?, ?, ?, ?, ?, ?)
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))
+INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
 DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
 LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
       ]]></attribute>
@@ -84,8 +84,8 @@
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
       <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID) VALUES (?, ?, ?, ?, ?, ?)
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))
+INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
 DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
 LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
       ]]></attribute>

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-05 17:20:56 UTC (rev 1708)
@@ -100,6 +100,12 @@
    {
       log.info("Registering connection factory with name " + uniqueName + " bindings " + jndiBindings);
       
+      //Sanity check
+      if (delegates.containsKey(uniqueName))
+      {
+         throw new IllegalArgumentException("There's already a connection factory registered with name " + uniqueName);
+      }
+      
       int id = serverPeer.getNextObjectID();
       Version version = serverPeer.getVersion();
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-05 17:20:56 UTC (rev 1708)
@@ -545,7 +545,7 @@
             ps.setNull(5, Types.VARCHAR);
          }
          ps.setLong(6, binding.getQueue().getChannelID());
-         ps.setString(7,binding.isFailed()?"Y":"N");
+         ps.setString(7,binding.isFailed() ? "Y":"N");
 
          ps.executeUpdate();
       }
@@ -801,7 +801,7 @@
       map.put("CREATE_POSTOFFICE_TABLE",
               "CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER," +
               "QUEUE_NAME VARCHAR(1023), CONDITION VARCHAR(1023), " +
-              "SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER VARCHAR(1))");
+              "SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))");
       return map;
    }
    

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-05 17:20:56 UTC (rev 1708)
@@ -42,6 +42,7 @@
    TEST_CLUSTERED=$ENV_TEST_CLUSTERED
 fi
 
+TEST_DATABASE=mysql
 
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-05 17:20:56 UTC (rev 1708)
@@ -647,6 +647,7 @@
       <antcall target="start-rmi-server-clustering">
          <param name="test.registry.index" value="0"/>
       </antcall>
+
       <antcall target="start-rmi-server-clustering">
          <param name="test.registry.index" value="1"/>
       </antcall>
@@ -654,6 +655,7 @@
          <param name="test.registry.index" value="2"/>
       </antcall>
 
+
       <mkdir dir="${build.tests.reports}"/>
 
       <echo message=""/>
@@ -703,7 +705,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/ManualClusteringTest.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 17:20:56 UTC (rev 1708)
@@ -83,10 +83,10 @@
 
       try
       {
-         ServerManagement.start("all", 0);
-         ServerManagement.start("all", 1);
+         ServerManagement.start("all", 0);
+         ServerManagement.start("all", 1);         
          ServerManagement.start("all", 2);
-
+
          ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
          ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
 
@@ -99,6 +99,8 @@
          ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
          ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
          ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+         
+         log.info("Deployed destinations ok");
 
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
@@ -112,7 +114,7 @@
          cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
          cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
 
-         drainQueues();
+         drainQueues();
       }
       catch (Exception e)
       {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-05 17:20:56 UTC (rev 1708)
@@ -54,6 +54,9 @@
    {
       String n =
          "//localhost:" + RMITestServer.RMI_REGISTRY_PORTS[remoteServerIndex] + "/" + RMITestServer.NAMING_SERVER_NAME;
+      
+      log.info("Using this url for rmi server lookup " + n);
+      
       namingDelegate = (NamingDelegate)Naming.lookup(n);
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-05 16:35:36 UTC (rev 1707)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-05 17:20:56 UTC (rev 1708)
@@ -50,6 +50,8 @@
     */
    public static Hashtable getJNDIEnvironment(int serverIndex)
    {
+      log.info("Returning remote context... server index:" + serverIndex);
+      
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial",
               "org.jboss.test.messaging.tools.jndi.RemoteInitialContextFactory");
@@ -69,6 +71,8 @@
    {
       String s = (String)environment.get(Constants.SERVER_INDEX_PROPERTY_NAME);
       
+      log.info("Created initial context for " + s);
+      
       if (s == null)
       {
          throw new IllegalArgumentException("Initial context environment must contain " +



From msurtani at jboss.com  Tue Dec  5 12:22:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 12:22:49 -0500
Subject: [jboss-cvs] JBossCache/etc  ...
Message-ID: <E1Gre0H-0002qH-Lw@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 12:22:49

  Modified:    etc      Tag: Branch_JBossCache_1_3_0 log4j.xml
  Log:
  Updated the default logging settings
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.10.2.1  +5 -18     JBossCache/etc/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/log4j.xml,v
  retrieving revision 1.10
  retrieving revision 1.10.2.1
  diff -u -b -r1.10 -r1.10.2.1
  --- log4j.xml	14 Mar 2006 14:03:06 -0000	1.10
  +++ log4j.xml	5 Dec 2006 17:22:49 -0000	1.10.2.1
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.10 2006/03/14 14:03:06 bwang Exp $ -->
  +<!-- $Id: log4j.xml,v 1.10.2.1 2006/12/05 17:22:49 msurtani Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -82,34 +82,21 @@
       <priority value="INFO" class="org.jboss.logging.XLevel"/>
     </category>
   
  -    <category name="org.jboss.jrunit">
  -        <priority value="FATAL" class="org.jboss.logging.XLevel"/>
  -    </category>
  -
  -   <category name="org.jboss.jrunit.*">
  -      <priority value="FATAL" class="org.jboss.logging.XLevel"/>
  -   </category>
  -
       <category name="org.jboss.tm">
  -    <priority value="FATAL" class="org.jboss.logging.XLevel"/>
  +    <priority value="WARN" class="org.jboss.logging.XLevel"/>
       </category>
   
      <category name="org.jgroups">
  -      <priority value="FATAL"/>
  +      <priority value="WARN"/>
      </category>
   
  -    <category name="test">
  -        <priority value="FATAL"/>
  -    </category>
  -
  -
       <!-- ======================= -->
     <!-- Setup the Root category -->
     <!-- ======================= -->
   
     <root>
       <!--appender-ref ref="CONSOLE"/-->
  -    <!--appender-ref ref="FILE"/-->
  +    <appender-ref ref="FILE"/>
     </root>
     
   </log4j:configuration>
  
  
  


From gavin.king at jboss.com  Tue Dec  5 12:24:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 12:24:17 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1Gre1h-0002qw-WD@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 12:24:17

  Modified:    jboss-seam  build.xml
  Log:
  oops, make it work on jboss
  
  Revision  Changes    Path
  1.117     +18 -7     jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.116
  retrieving revision 1.117
  diff -u -b -r1.116 -r1.117
  --- build.xml	5 Dec 2006 16:21:02 -0000	1.116
  +++ build.xml	5 Dec 2006 17:24:17 -0000	1.117
  @@ -89,21 +89,32 @@
           <include name="drools/lib/*.jar"/>
       </fileset>
       
  -    <zipfileset id="example.seam.jar" 
  +    <zipfileset id="example.seam.misc.jar" 
                  dir="${imported.basedir}"
       	    prefix="WEB-INF/lib"
          description="the Seam jars">
  -        <include name="${name}.jar"/>
       	<include name="jboss-seam-debug.jar" if="example.seam.debug.lib"/>
           <include name="jboss-seam-ui.jar" if="example.seam.ui.lib"/>
       </zipfileset>
       
  +    <zipfileset id="example.seam.main.jar" 
  +               dir="${imported.basedir}"
  +       description="the main Seam jar">
  +        <include name="${name}.jar"/>
  +    </zipfileset>
  +
  +    <zipfileset id="example.facelets.jar" 
  +               dir="${lib.dir}"
  +           prefix="WEB-INF/lib"
  +      description="the facelets jar">
  +        <include name="jsf-facelets.jar" if="example.facelets.lib"/>
  +    </zipfileset>
  +	
       <zipfileset id="example.extra.jar" 
                  dir="${lib.dir}" 
          description="extra jars for the EAR">
           <include name="el-*.jar" />
           <include name="jbpm*.jar" if="example.jbpm.lib"/>
  -        <include name="jsf-facelets.jar" if="example.facelets.lib"/>
           <include name="jboss-cache-jdk50.jar" if="example.cache.lib"/>
           <include name="jboss-aop-jdk50.jar" if="example.cache.lib"/>
           <include name="jgroups.jar" if="example.cache.lib"/>
  @@ -222,7 +233,7 @@
       <path id="build.classpath">
           <path refid="example.path"/>
           <fileset refid="lib"/>
  -        <fileset refid="example.seam.jar"/>
  +        <fileset refid="example.seam.main.jar"/>
       </path>
       
       <property name="test.classpath" value="test.classpath"/>
  @@ -919,8 +930,8 @@
           <jar destfile="${build.dir}/${example.name}.war">
               <zipfileset refid="example.war.docroot"/>
               <zipfileset refid="example.war.webinf.lib"/>
  -        	<zipfileset refid="facelets.jar"/>
  -        	<zipfileset refid="seam.extra.jar"/>
  +        	<zipfileset refid="example.seam.misc.jar"/>
  +        	<zipfileset refid="example.facelets.jar"/>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
               </zipfileset>
  @@ -937,7 +948,7 @@
   
       <target name="ear" depends="ejb3, war">
           <jar destfile="${build.dir}/${example.name}.ear">
  -            <fileset refid="example.seam.jar"/>
  +            <fileset refid="example.seam.main.jar"/>
               <fileset refid="example.drools.jar"/>
               <fileset refid="example.extra.jar"/>
               <zipfileset dir="${build.dir}">
  
  
  


From msurtani at jboss.com  Tue Dec  5 12:25:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 12:25:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gre37-0002t9-9b@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 12:25:45

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_3_0
                        TreeCache.java
  Log:
  Some fine-tunings
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.142.2.7 +12 -10    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.142.2.6
  retrieving revision 1.142.2.7
  diff -u -b -r1.142.2.6 -r1.142.2.7
  --- TreeCache.java	30 Nov 2006 14:18:04 -0000	1.142.2.6
  +++ TreeCache.java	5 Dec 2006 17:25:45 -0000	1.142.2.7
  @@ -60,7 +60,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.142.2.6 2006/11/30 14:18:04 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.142.2.7 2006/12/05 17:25:45 msurtani Exp $
    *          <p/>
    */
   public class TreeCache extends ServiceMBeanSupport implements TreeCacheMBean, Cloneable, MembershipListener
  @@ -4198,10 +4198,12 @@
         }
      }
   
  -   private void scrubRemoveMarker(TreeNode n, boolean deep)
  +   public void scrubRemoveMarker(TreeNode n, boolean deep)
      {
         n.remove(REMOVAL_MARKER);
         // unmark children as well.
  +      if (deep)
  +      {
         Map children = n.getChildren();
         if (children != null && !children.isEmpty())
         {
  @@ -4212,10 +4214,10 @@
               scrubRemoveMarker((TreeNode) i.next(), true);
            }
         }
  -
  +      }
      }
   
  -   private boolean isMarkedForRemoval(TreeNode n)
  +   public boolean isMarkedForRemoval(TreeNode n)
      {
         return n.containsKey(REMOVAL_MARKER);
      }
  
  
  


From msurtani at jboss.com  Tue Dec  5 12:25:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 05 Dec 2006 12:25:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1Gre37-0002tK-EK@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/05 12:25:45

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_3_0
                        PessimisticLockInterceptor.java
  Log:
  Some fine-tunings
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.14.2.9  +20 -4     JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.14.2.8
  retrieving revision 1.14.2.9
  diff -u -b -r1.14.2.8 -r1.14.2.9
  --- PessimisticLockInterceptor.java	1 Dec 2006 15:44:20 -0000	1.14.2.8
  +++ PessimisticLockInterceptor.java	5 Dec 2006 17:25:45 -0000	1.14.2.9
  @@ -34,7 +34,7 @@
    * scope of the TX. When no TX is present, we keep track of the locks acquired during the current method and unlock
    * when the method returns
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.8 2006/12/01 15:44:20 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.9 2006/12/05 17:25:45 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor {
      TransactionTable           tx_table=null;
  @@ -145,7 +145,7 @@
               do {
                  lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, lock_timeout, createIfNotExists, storeLockedNode);
               }
  -            while(cache.peek(fqn) == null); // keep trying until we have the lock (fixes concurrent remove())
  +            while(!cache.exists(fqn)); // keep trying until we have the lock (fixes concurrent remove())
                                                  // terminates successfully, or with (Timeout)Exception
            }
            else
  @@ -243,6 +243,12 @@
               currentLockType = DataNode.LOCK_TYPE_READ;
            }
   
  +         // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  +         if (needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation))
  +         {
  +            reverseRemove(child_node);
  +         }
  +
            // Try to acquire the lock; recording that we did if successful
            acquireNodeLock(child_node, owner, gtx, currentLockType, lock_timeout);
   
  @@ -269,6 +275,16 @@
         if (isRemoveNodeOperation && gtx != null) cache.getTransactionTable().get(gtx).addRemovedNode(fqn);
      }
   
  +   private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation)
  +   {
  +      return !isRemoveOperation && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
  +   }
  +
  +   private void reverseRemove(DataNode n)
  +   {
  +      cache.scrubRemoveMarker(n, false);
  +   }
  +
      private boolean writeLockNeeded(int lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
      {
         if (isRemoveOperation && currentNodeIndex == treeNodeSize - 2)
  @@ -277,7 +293,7 @@
         if (!isTargetNode(currentNodeIndex, treeNodeSize) && !cache.exists(new Fqn(currentFqn, targetFqn.get(currentNodeIndex + 1))))
            return createIfNotExists; // we're at a node in the tree, not yet at the target node, and we need to create the next node.  So we need a WL here.
         
  -      return lock_type == DataNode.LOCK_TYPE_WRITE && isTargetNode(currentNodeIndex, treeNodeSize) && createIfNotExists; //normal operation, write lock explicitly requested and this is the target to be written to.
  +      return lock_type == DataNode.LOCK_TYPE_WRITE && isTargetNode(currentNodeIndex, treeNodeSize) && (createIfNotExists || isRemoveOperation); //normal operation, write lock explicitly requested and this is the target to be written to.
      }
   
      private boolean isTargetNode(int nodePosition, int treeNodeSize)
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 13:20:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 13:20:41 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58847 - trunk/tomcat/src/resources
Message-ID: <E1GreuH-0003wx-5b@committer01.frg.pub.inap.atl.jboss.com>

Author: hmesha
Date: 2006-12-05 13:20:39 -0500 (Tue, 05 Dec 2006)
New Revision: 58847

Modified:
   trunk/tomcat/src/resources/tc6-cluster-beans.xml
   trunk/tomcat/src/resources/tc6-cluster-service.xml
Log:
JBAS-3571 - enabling back the cache loader config element for http session replication

Modified: trunk/tomcat/src/resources/tc6-cluster-beans.xml
===================================================================
--- trunk/tomcat/src/resources/tc6-cluster-beans.xml	2006-12-05 16:22:57 UTC (rev 58846)
+++ trunk/tomcat/src/resources/tc6-cluster-beans.xml	2006-12-05 18:20:39 UTC (rev 58847)
@@ -50,7 +50,6 @@
       		</property>
       	</bean>
       </property>
-      <!--
       <property name="cacheLoaderConfig">
       	<bean name="TomcatClusteringCacheLoaderConfig" 
       		class="org.jboss.cache.config.CacheLoaderConfig">
@@ -69,7 +68,6 @@
                 </property>
       	</bean>
       </property>
-      -->
    </bean>
     
    <!-- Now we use the above configuration to construct the cache itself -->

Modified: trunk/tomcat/src/resources/tc6-cluster-service.xml
===================================================================
--- trunk/tomcat/src/resources/tc6-cluster-service.xml	2006-12-05 16:22:57 UTC (rev 58846)
+++ trunk/tomcat/src/resources/tc6-cluster-service.xml	2006-12-05 18:20:39 UTC (rev 58847)
@@ -176,7 +176,7 @@
             </config>
         </attribute>
 
-		<!-- passivation store config using jboss cache 1.3 +
+		<!-- passivation store config using jboss cache 1.3 + -->
  
         <attribute name="CacheLoaderConfiguration">
             <config>
@@ -194,8 +194,7 @@
                 </cacheloader>
             </config>
         </attribute>
-        
-         -->
+
          
     </mbean>
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 13:38:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 13:38:11 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1709 - in
	branches/Branch_Client_Failover_Experiment/tests: etc
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/tools/jmx
	src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GrfBD-0004ES-Jq@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-05 13:38:08 -0500 (Tue, 05 Dec 2006)
New Revision: 1709

Modified:
   branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
Trying to fix problems on "ant clustering-tests"

Modified: branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-05 17:20:56 UTC (rev 1708)
+++ branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-05 18:38:08 UTC (rev 1709)
@@ -68,17 +68,6 @@
 
    <serialization-type>jms</serialization-type>
 
-
-   <!--
-      Specifies whether to start a clustered messaging server or not. If "test.clustered" is set,
-      the value of the system property takes precedence. Supported values are "true" or "false".
-
-      Setting "clustered" to "true" doesn't guarantee that the test will be actually run in
-      clustered mode, the test database must be also permitting sharing over a LAN. "mysql" allows
-      this, "hsqldb" doesn't. The test will quickly fail in such a situation.
-   -->
-   <clustered>true</clustered>
-
 </container>
 
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 17:20:56 UTC (rev 1708)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 18:38:08 UTC (rev 1709)
@@ -83,25 +83,20 @@
 
       try
       {
-         ServerManagement.start("all", 0);
-         ServerManagement.start("all", 1);         
-         ServerManagement.start("all", 2);
-
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 0);
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
+         startServer(0);
+         startServer(1);
+         startServer(2);
 
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 1);
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 1);
-
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 2);
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 2);
-
          ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
          ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
          ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
          
          log.info("Deployed destinations ok");
 
+         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
+         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
+         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
+
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
          queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
@@ -110,11 +105,7 @@
          topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
          topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
 
-         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
-
-         drainQueues();
+         drainQueues();
       }
       catch (Exception e)
       {
@@ -123,6 +114,14 @@
       }
    }
 
+   private void startServer(int peer)
+      throws Exception
+   {
+      ServerManagement.start("all-cluster", peer);
+      ServerManagement.deployClusteredQueue("testDistributedQueue", peer);
+      ServerManagement.deployClusteredTopic("testDistributedTopic", peer);
+   }
+
    protected void tearDown() throws Exception
    {
       try

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-05 17:20:56 UTC (rev 1708)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-05 18:38:08 UTC (rev 1709)
@@ -25,9 +25,26 @@
 import java.io.ByteArrayInputStream;
 import java.io.InputStream;
 import java.net.URL;
-import java.sql.*;
-import java.util.*;
-import javax.management.*;
+import java.sql.Connection;
+import java.sql.DriverManager;
+import java.sql.PreparedStatement;
+import java.sql.SQLException;
+import java.sql.Statement;
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Hashtable;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Properties;
+import java.util.Set;
+import java.util.StringTokenizer;
+import javax.management.Attribute;
+import javax.management.MBeanAttributeInfo;
+import javax.management.MBeanException;
+import javax.management.MBeanInfo;
+import javax.management.MBeanServer;
+import javax.management.MBeanServerFactory;
+import javax.management.ObjectName;
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
@@ -49,7 +66,11 @@
 import org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory;
 import org.jboss.resource.adapter.jdbc.remote.WrapperDataSourceService;
 import org.jboss.resource.adapter.jms.JmsManagedConnectionFactory;
-import org.jboss.resource.connectionmanager.*;
+import org.jboss.resource.connectionmanager.CachedConnectionManager;
+import org.jboss.resource.connectionmanager.CachedConnectionManagerMBean;
+import org.jboss.resource.connectionmanager.ConnectionFactoryBindingService;
+import org.jboss.resource.connectionmanager.JBossManagedConnectionPool;
+import org.jboss.resource.connectionmanager.TxConnectionManager;
 import org.jboss.system.Registry;
 import org.jboss.system.ServiceController;
 import org.jboss.system.ServiceCreator;
@@ -158,6 +179,7 @@
    private Server hsqldbServer;
 
    private boolean transaction;
+   private boolean cluster;
    private boolean database;
    private boolean jca;
    private boolean remotingSocket;
@@ -381,7 +403,7 @@
          log.info("Serialization type: ...... " + config.getSerializationType());
          log.info("Database: ................ " + config.getDatabaseType());
          log.info("Clustering mode: ......... " +
-            (config.isClustered() ? "CLUSTERED" : "NON-CLUSTERED"));
+            (this.isClustered() ? "CLUSTERED" : "NON-CLUSTERED"));
 
          log.debug(this + " started");
       }
@@ -480,7 +502,7 @@
    public Properties getPersistenceManagerSQLProperties() throws Exception
    {
       String databaseType = getDatabaseType();
-      
+
       String persistenceConfigFile =
          "server/default/deploy/" + databaseType + "-persistence-service.xml";
       
@@ -756,7 +778,7 @@
 
    public boolean isClustered()
    {
-      return config.isClustered();
+      return cluster;
    }
 
    public String toString()
@@ -1283,6 +1305,16 @@
             minus = true;
          }
 
+         if ("all-cluster".equals(tok))
+         {
+            cluster = true;
+            transaction = true;
+            database = true;
+            jca = true;
+            remotingSocket = true;
+            security = true;
+         }
+         else
          if ("all".equals(tok))
          {
             transaction = true;

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-05 17:20:56 UTC (rev 1708)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-05 18:38:08 UTC (rev 1709)
@@ -29,8 +29,6 @@
 {
    // Constants -----------------------------------------------------
 
-   public static final boolean DEFAULT_CLUSTERED_MODE = false;
-
    // Static --------------------------------------------------------
 
    public static String getHypersonicDatabase(String connectionURL)
@@ -76,7 +74,6 @@
    private String database;
    private Map dbConfigurations;
    private String serializationType;
-   private Boolean clusteredMode;
 
    // Constructors --------------------------------------------------
 
@@ -102,7 +99,7 @@
       {
     	  databaseType="mssql";
       }
-      return databaseType; 
+      return databaseType;
    }
 
    public String getDatabaseConnectionURL()
@@ -143,14 +140,6 @@
       return serializationType;
    }
 
-   /**
-    * @return the clustered mode in which the container should run an individual test.
-    */
-   public boolean isClustered()
-   {
-      return clusteredMode.booleanValue();
-   }
-
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -162,7 +151,6 @@
       Reader reader = new InputStreamReader(is);
       String currentDatabase = null;
       String currentSerializationType = null;
-      boolean currentClusteredMode = DEFAULT_CLUSTERED_MODE;
 
       try
       {
@@ -201,10 +189,6 @@
                {
                   currentSerializationType = XMLUtil.getTextContent(n);
                }
-               else if ("clustered".equals(name))
-               {
-                  currentClusteredMode = Boolean.getBoolean(XMLUtil.getTextContent(n));
-               }
                else
                {
                   throw new Exception("Unexpected child <" + name + "> of node " +
@@ -215,7 +199,6 @@
 
          setCurrentDatabase(currentDatabase);
          setCurrentSerializationType(currentSerializationType);
-         setCurrentClusteredMode(currentClusteredMode);
       }
       finally
       {
@@ -237,8 +220,8 @@
    }
 
    /**
-    * Always the value of "test.serialization" system property takes precedence over the
-    * configuration file value.
+    * Always the value of "test.serialization" system property takes precedence over the c
+    * onfiguration file value.
     */
    private void setCurrentSerializationType(String xmlConfigSerializationType)
    {
@@ -249,24 +232,6 @@
       }
    }
 
-   /**
-    * Always the value of "test.clustered" system property takes precedence over the configuration
-    * file value.
-    */
-   private void setCurrentClusteredMode(boolean xmlClusteredMode) throws Exception
-   {
-      String s = System.getProperty("test.clustered");
-      if (s != null)
-      {
-         clusteredMode = Boolean.valueOf(s);
-      }
-
-      if (clusteredMode == null)
-      {
-         clusteredMode = new Boolean(xmlClusteredMode);
-      }
-   }
-
    private void validate() throws Exception
    {
       // make sure that I have a corresponding "database-configuration"

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-05 17:20:56 UTC (rev 1708)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-05 18:38:08 UTC (rev 1709)
@@ -41,12 +41,12 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.test.messaging.tools.jndi.Constants;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
 import org.jboss.test.messaging.tools.jboss.ServiceDeploymentDescriptor;
 import org.jboss.test.messaging.tools.jmx.MockJBossSecurityManager;
 import org.jboss.test.messaging.tools.jmx.RemotingJMXWrapper;
 import org.jboss.test.messaging.tools.jmx.ServiceContainer;
+import org.jboss.test.messaging.tools.jndi.Constants;
 import org.w3c.dom.Element;
 
 /**
@@ -255,7 +255,7 @@
                                boolean clustered) throws Exception
    {
       try
-      {         
+      {
          log.info(" Server peer ID ........... " + serverPeerID);
          
          log.debug("creating ServerPeer instance");
@@ -272,6 +272,9 @@
    
          String databaseType = sc.getDatabaseType();
          String persistenceConfigFile;
+
+         log.info("DatabaseType=" + databaseType);
+         log.info("Clustered:" + clustered);
          
          if (clustered && !databaseType.equals("hsqldb"))
          {



From gavin.king at jboss.com  Tue Dec  5 14:37:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 14:37:02 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Grg6A-0005RW-60@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 14:37:02

  Modified:    src/main/org/jboss/seam/core  Ejb.java
  Log:
  JBSEAM-563
  
  Revision  Changes    Path
  1.19      +3 -1      jboss-seam/src/main/org/jboss/seam/core/Ejb.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Ejb.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Ejb.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- Ejb.java	24 Nov 2006 23:15:17 -0000	1.18
  +++ Ejb.java	5 Dec 2006 19:37:02 -0000	1.19
  @@ -1,4 +1,4 @@
  -//$Id: Ejb.java,v 1.18 2006/11/24 23:15:17 gavin Exp $
  +//$Id: Ejb.java,v 1.19 2006/12/05 19:37:02 gavin Exp $
   package org.jboss.seam.core;
   
   import static org.jboss.seam.InterceptionType.NEVER;
  @@ -45,6 +45,8 @@
         
         deployer = EJB3StandaloneBootstrap.createDeployer();
         deployer.getArchivesByResource().add("seam.properties");
  +      deployer.getArchivesByResource().add("META-INF/seam.properties");
  +      deployer.getArchivesByResource().add("META-INF/components.xml");
         
         // need to set the InitialContext properties that deployer will use
         // to initial EJB containers
  
  
  


From gavin.king at jboss.com  Tue Dec  5 14:37:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 14:37:02 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/init  ...
Message-ID: <E1Grg6A-0005Rd-DH@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 14:37:02

  Modified:    src/main/org/jboss/seam/init  Initialization.java
  Log:
  JBSEAM-563
  
  Revision  Changes    Path
  1.131     +2 -1      jboss-seam/src/main/org/jboss/seam/init/Initialization.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Initialization.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/init/Initialization.java,v
  retrieving revision 1.130
  retrieving revision 1.131
  diff -u -b -r1.130 -r1.131
  --- Initialization.java	24 Nov 2006 23:51:23 -0000	1.130
  +++ Initialization.java	5 Dec 2006 19:37:02 -0000	1.131
  @@ -57,7 +57,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.130 $
  + * @version $Revision: 1.131 $
    */
   public class Initialization
   {
  @@ -437,6 +437,7 @@
         Set<Package> scannedPackages = new HashSet<Package>();
         Set<Class<Object>> scannedClasses = new HashSet<Class<Object>>();
         scannedClasses.addAll( new ComponentScanner("seam.properties").getClasses() );
  +      scannedClasses.addAll( new ComponentScanner("META-INF/seam.properties").getClasses() );
         scannedClasses.addAll( new ComponentScanner("META-INF/components.xml").getClasses() );
         for (Class<Object> scannedClass: scannedClasses)
         {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 14:42:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 14:42:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r58848 - in trunk:
	server/src/main/org/jboss/metadata
	tomcat/src/main/org/jboss/web/tomcat/tc6/session
Message-ID: <E1GrgB2-0005WV-BD@committer01.frg.pub.inap.atl.jboss.com>

Author: hmesha
Date: 2006-12-05 14:42:00 -0500 (Tue, 05 Dec 2006)
New Revision: 58848

Modified:
   trunk/server/src/main/org/jboss/metadata/WebMetaData.java
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JBossManager.java
Log:
JBAS-3872

Modified: trunk/server/src/main/org/jboss/metadata/WebMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-05 18:20:39 UTC (rev 58847)
+++ trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-05 19:42:00 UTC (rev 58848)
@@ -194,26 +194,6 @@
    private boolean replicationFieldBatchMode = true;
    
    /**
-    * If true then the session passivation is enabled for this web app.
-    * If false then the session passivation is disabled for this web app. 
-    */
-   private boolean sessionPassivationMode = false;
-   
-   /**
-    * Min time (seconds) the session must be idle since lastAccesstime before it's eligable for passivation
-    * This overrides maxActive_, to prevent thrashing if the there are lots of active sessions.
-    * Setting to -1 means it's ignored
-    */
-   private int sessionPassivationMinIdleTime = -1;
-   
-   /**
-    * Max time (seconds) the session must be idle since lastAccesstime before it's eligable for passivation
-    * This overrides maxActive_, to prevent thrashing if the there are lots of active sessions.
-    * Setting to -1 means session should not be forced out.
-    */
-   private int sessionPassivationMaxIdleTime = -1;
-   
-   /**
     * The maximum number of active sessions allowed, or -1 for no limit
     */
    private int maxActiveSessions = -1;
@@ -1085,36 +1065,6 @@
       return replicationFieldBatchMode;
    }
    
-   public boolean getSessionPassivationMode()
-   {
-      return sessionPassivationMode;
-   }
-   
-   public void setSessionPassivationMode(boolean mode)
-   {
-      this.sessionPassivationMode = mode;
-   }
-   
-   public int getSessionPassivationMinIdleTime()
-   {
-      return sessionPassivationMinIdleTime;
-   }
-   
-   public void setSessionPassivationMinIdleTime(int time)
-   {
-      this.sessionPassivationMinIdleTime = time;
-   }
-   
-   public int getSessionPassivationMaxIdleTime()
-   {
-      return sessionPassivationMaxIdleTime;
-   }
-   
-   public void setSessionPassivationMaxIdleTime(int time)
-   {
-      this.sessionPassivationMaxIdleTime = time;
-   }
-   
    public int getMaxActiveSessionsAllowed()
    {
       return maxActiveSessions;
@@ -1343,34 +1293,45 @@
       {
          // manage "use-session-passivation" first ...
          Element usePassivationElement = MetaData.getOptionalChild(sessionPassivationRootElement, "use-session-passivation");
-         if (usePassivationElement != null && Boolean.valueOf(getElementContent(usePassivationElement)).booleanValue())
+         if (usePassivationElement != null)
          {
-            sessionPassivationMode = true;
+            passivationConfig.setUseSessionPassivation(getElementContent(usePassivationElement));
          }
          else
          {
-            sessionPassivationMode = false;
+            passivationConfig.setUseSessionPassivation(String.valueOf(false));
          }
-         log.info("WebMetaData:importJBossWebXml: sessionPassivationMode = " + sessionPassivationMode);
+         log.info("WebMetaData:importJBossWebXml: PassivationConfig.UseSessionPassivation = " + passivationConfig.getUseSessionPassivation());
          // then manage passivation-min-idle-time and -passivation-max-idle-time
-         if (getSessionPassivationMode())
+         if (Boolean.valueOf(passivationConfig.getUseSessionPassivation()).booleanValue())
          {
             Element minIdleTimeElement = MetaData.getOptionalChild(sessionPassivationRootElement, "passivation-min-idle-time");
             if (minIdleTimeElement != null)
             {
-               Long minIdleTimeValue = Long.valueOf(getElementContent(minIdleTimeElement));
-               sessionPassivationMinIdleTime = minIdleTimeValue.intValue();
-               log.info("WebMetaData:importJBossWebXml: sessionPassivationMinIdleTime = " + sessionPassivationMinIdleTime);
+               passivationConfig.setPassivationMinIdleTime(getElementContent(minIdleTimeElement));
+               log.info("WebMetaData:importJBossWebXml: passivationConfig.passivationMinIdleTime = " + passivationConfig.getPassivationMinIdleTime());
             }
+            else
+            {
+               passivationConfig.setPassivationMinIdleTime(String.valueOf(0));
+            }
             
             Element maxIdleTimeElement = MetaData.getOptionalChild(sessionPassivationRootElement, "passivation-max-idle-time");
             if (maxIdleTimeElement != null)
             {
-               Long maxIdleTimeValue = Long.valueOf(getElementContent(maxIdleTimeElement));
-               sessionPassivationMaxIdleTime = maxIdleTimeValue.intValue();
-               log.info("WebMetaData:importJBossWebXml: sessionPassivationMaxIdleTime = " + sessionPassivationMaxIdleTime);
+               passivationConfig.setPassivationMaxIdleTime(getElementContent(maxIdleTimeElement));
+               log.info("WebMetaData:importJBossWebXml: passivationConfig.passivationMaxIdleTime = " + passivationConfig.getPassivationMaxIdleTime());
             }
+            else
+            {
+               passivationConfig.setPassivationMaxIdleTime(String.valueOf(0));
+            }
          }
+         else
+         {
+            passivationConfig.setPassivationMinIdleTime(String.valueOf(0));
+            passivationConfig.setPassivationMaxIdleTime(String.valueOf(0));
+         }
       }
       // Parse the jboss-web/session-replication element
 

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JBossManager.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JBossManager.java	2006-12-05 18:20:39 UTC (rev 58847)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JBossManager.java	2006-12-05 19:42:00 UTC (rev 58848)
@@ -48,6 +48,7 @@
 import org.jboss.logging.Logger;
 import org.jboss.metadata.WebMetaData;
 import org.jboss.metadata.web.ReplicationConfig;
+import org.jboss.metadata.web.PassivationConfig;
 import org.jboss.mx.util.MBeanServerLocator;
 import org.jboss.web.tomcat.statistics.ReplicationStatistics;
 
@@ -201,12 +202,17 @@
          invalidateSessionPolicy_ = InvalidateSessionPolicy.fromString(rpc.getTrigger());
       }
       maxActive_ = webMetaData.getMaxActiveSessionsAllowed();
-      passivationMode_ = webMetaData.getSessionPassivationMode();
-      if (passivationMode_)
+      PassivationConfig pConfig = webMetaData.getPassivationConfig();
+      if (pConfig != null)
       {
-         passivationMinIdleTime_ = webMetaData.getSessionPassivationMinIdleTime();
-         passivationMaxIdleTime_ = webMetaData.getSessionPassivationMaxIdleTime();
+         passivationMode_ = Boolean.valueOf(pConfig.getUseSessionPassivation()).booleanValue();
+         if (passivationMode_)
+         {
+            passivationMinIdleTime_ = Integer.valueOf(pConfig.getPassivationMinIdleTime()).intValue();
+            passivationMaxIdleTime_ = Integer.valueOf(pConfig.getPassivationMaxIdleTime()).intValue();
+         }
       }
+      
       useLocalCache_ = useLocalCache;
       log_.info("init(): replicationGranularity_ is " + replicationGranularity_ +
          " and invaldateSessionPolicy is " + invalidateSessionPolicy_ +



From gavin.king at jboss.com  Tue Dec  5 14:48:19 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 14:48:19 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GrgH5-0005cX-6q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 14:48:19

  Modified:    jboss-seam  build.xml
  Log:
  facelets dir is gone
  
  Revision  Changes    Path
  1.118     +1 -11     jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.117
  retrieving revision 1.118
  diff -u -b -r1.117 -r1.118
  --- build.xml	5 Dec 2006 17:24:17 -0000	1.117
  +++ build.xml	5 Dec 2006 19:48:19 -0000	1.118
  @@ -32,12 +32,10 @@
       <property name="src.test.dir"         value="src/test"/>
   
       <property name="lib.dir"              value="${imported.basedir}/lib"/>
  -    <property name="facelets.lib.dir"     value="${imported.basedir}/facelets/lib"/>
       <property name="drools.lib.dir"       value="${imported.basedir}/drools/lib"/>
       <property name="eejb.conf.dir"        value="${imported.basedir}/embedded-ejb/conf"/>
       <property name="mc.conf.dir"          value="${imported.basedir}/microcontainer/conf"/>
       <property name="example.coverage.dir" value="${imported.basedir}/build/coverage"/>
  -    <property name="facelets.dir"         value="${imported.basedir}/facelets"/>
       <property name="drools.dir"           value="${imported.basedir}/drools"/>
   	<property name="hibernate.dir"        value="${imported.basedir}/hibernate"/>
       <property name="seamgen.dir"          value="${imported.basedir}/seam-gen"/>
  @@ -61,7 +59,6 @@
       <property name="dist.lib.dir"         value="${dist.dir}/lib"/>
       <property name="dist.eejb.conf.dir"   value="${dist.dir}/embedded-ejb/conf"/>
       <property name="dist.mc.conf.dir"     value="${dist.dir}/microcontainer/conf"/>
  -    <property name="dist.facelets.dir"    value="${dist.dir}/facelets"/>
       <property name="dist.drools.dir"      value="${dist.dir}/drools"/>
   	<property name="dist.hibernate.dir"   value="${dist.dir}/hibernate"/>
       <property name="dist.seamgen.dir"     value="${dist.dir}/seam-gen"/>
  @@ -471,7 +468,6 @@
           	target="1.5"
               destdir="${uiclasses.dir}"
               classpathref="build.classpath"
  -            classpath="facelets/lib/jsf-facelets.jar:facelets/lib/el-ri.jar:facelets/lib/el-api.jar"
               debug="${javac.debug}"
               deprecation="${javac.deprecation}"
               nowarn="on">
  @@ -486,7 +482,6 @@
           	target="1.5"
               destdir="${debugclasses.dir}"
               classpathref="build.classpath"
  -            classpath="facelets/lib/jsf-facelets.jar:facelets/lib/el-ri.jar:facelets/lib/el-api.jar"
               debug="${javac.debug}"
               deprecation="${javac.deprecation}"
               nowarn="on">
  @@ -655,11 +650,6 @@
           <copy file="microcontainer/readme.txt" todir="${dist.dir}/microcontainer"/>
           <copy file="embedded-ejb/readme.txt" todir="${dist.dir}/embedded-ejb"/>
   
  -    	<copy todir="${dist.facelets.dir}">
  -            <fileset dir="${facelets.dir}">
  -                <include name="**/*.*"/>
  -            </fileset>
  -        </copy>
           <copy todir="${dist.drools.dir}">
               <fileset dir="${drools.dir}">
                   <include name="**/*.*"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 14:54:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 14:54:07 -0500
Subject: [jboss-cvs] JBossAS SVN: r58849 -
	trunk/aspects/src/main/org/jboss/aspects/security
Message-ID: <E1GrgMh-0005hJ-FX@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 14:54:06 -0500 (Tue, 05 Dec 2006)
New Revision: 58849

Modified:
   trunk/aspects/src/main/org/jboss/aspects/security/RunAsSecurityInterceptor.java
Log:
merge from JEE_TCK branch

Modified: trunk/aspects/src/main/org/jboss/aspects/security/RunAsSecurityInterceptor.java
===================================================================
--- trunk/aspects/src/main/org/jboss/aspects/security/RunAsSecurityInterceptor.java	2006-12-05 19:42:00 UTC (rev 58848)
+++ trunk/aspects/src/main/org/jboss/aspects/security/RunAsSecurityInterceptor.java	2006-12-05 19:54:06 UTC (rev 58849)
@@ -69,10 +69,10 @@
       // If a run-as role was specified, push it so that any calls made
       // by this bean will have the runAsRole available for declarative
       // security checks.
-      if(runAsRole != null)
-      {
+      /*if(runAsRole != null)
+      {*/
          SecurityActions.pushRunAsIdentity(runAsRole);
-      }
+      /*}*/
      
       try
       {
@@ -80,10 +80,10 @@
       }
       finally
       {
-         if(runAsRole != null)
-         {
+        /* if(runAsRole != null)
+         {*/
             SecurityActions.popRunAsIdentity();
-         }
+         /*}*/
       }
    }
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 14:56:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 14:56:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r58850 -
	trunk/ejb3/src/main/org/jboss/ejb3/security
Message-ID: <E1GrgPR-0005ld-N3@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 14:56:55 -0500 (Tue, 05 Dec 2006)
New Revision: 58850

Added:
   trunk/ejb3/src/main/org/jboss/ejb3/security/SecurityDomainManager.java
Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/security/AuthenticationInterceptorFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptorFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptorFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptor.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/security/SecurityActions.java
Log:
merge from JEE_TCK branch

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/AuthenticationInterceptorFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/AuthenticationInterceptorFactory.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/AuthenticationInterceptorFactory.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -48,7 +48,7 @@
          SecurityDomain securityAnnotation = (SecurityDomain) advisor.resolveAnnotation(SecurityDomain.class);
          if (securityAnnotation != null)
          {
-            domain = ctx.lookup("java:/jaas/" + securityAnnotation.value());
+            domain = SecurityDomainManager.getSecurityManager(securityAnnotation.value(),ctx);
          }
       }
       catch (NamingException e)
@@ -77,6 +77,6 @@
    public String getName()
    {
       return getClass().getName();
-   }
+   } 
 }
 

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -22,12 +22,8 @@
 package org.jboss.ejb3.security;
 
 import java.security.GeneralSecurityException;
-import java.security.Principal;
-import java.util.Set;
-import java.util.HashSet;
+import java.security.Principal; 
 
-import javax.security.auth.Subject;
-
 import javax.ejb.EJBAccessException;
 
 import org.jboss.ejb3.Container;
@@ -40,15 +36,16 @@
 import org.jboss.aspects.security.AuthenticationInterceptor;
 import org.jboss.aspects.security.SecurityContext;
 import org.jboss.security.AuthenticationManager;
-import org.jboss.security.RealmMapping;
-import org.jboss.security.RunAsIdentity;
+import org.jboss.security.RealmMapping; 
 import org.jboss.security.SecurityAssociation;
+import org.jboss.security.SecurityRolesAssociation;
 import org.jboss.security.SimplePrincipal;
 
 /**
- * Comment
+ * Authentication Interceptor
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author Anil.Saldhana at jboss.org
  * @version $Revision$
  */
 public class Ejb3AuthenticationInterceptor extends AuthenticationInterceptor
@@ -98,7 +95,15 @@
             }
          }
       }
-
-      return super.invoke(invocation);
-   }
+      try
+      {  
+         //Set a map of principal-roles that may be configured at deployment level
+         SecurityRolesAssociation.setSecurityRoles(container.getAssemblyDescriptor().getPrincipalVersusRolesMap());
+         return super.invoke(invocation);
+      }
+      finally
+      { 
+         SecurityRolesAssociation.setSecurityRoles(null);
+      }
+   } 
 }

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -29,6 +29,7 @@
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aspects.remoting.InvokeRemoteInterceptor;
 import org.jboss.remoting.InvokerLocator;
+import org.jboss.security.RealmMapping;
 
 
 /**
@@ -44,6 +45,7 @@
 
    private String ejbName;
    private CodeSource ejbCS;
+   private RealmMapping realmMapping;
 
    public JaccAuthorizationInterceptor(String ejbName, CodeSource cs)
    {
@@ -55,6 +57,11 @@
    {
       return "JaccAuthorizationInterceptor";
    }
+   
+   public void setRealmMapping(RealmMapping ssm)
+   {
+      this.realmMapping = ssm;
+   }
 
    public Object invoke(Invocation inv) throws Throwable
    {
@@ -90,7 +97,7 @@
       String iface = (locator != null) ? "Remote" : "Local";
 
       EJBMethodPermission methodPerm = new EJBMethodPermission(ejbName, iface, m);
-      JaccHelper.checkPermission(ejbCS, methodPerm);
+      JaccHelper.checkPermission(ejbCS, methodPerm,realmMapping);
       /*// Get the caller
       Subject caller = SecurityActions.getContextSubject(); 
 

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptorFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptorFactory.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptorFactory.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -23,14 +23,24 @@
 package org.jboss.ejb3.security;
 
 import java.security.CodeSource;
+
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+
+import org.jboss.annotation.security.SecurityDomain;
 import org.jboss.aop.Advisor;
 import org.jboss.aop.InstanceAdvisor;
 import org.jboss.aop.advice.AspectFactory;
 import org.jboss.aop.joinpoint.Joinpoint;
+import org.jboss.ejb3.Container;
 import org.jboss.ejb3.EJBContainer;
+import org.jboss.security.AuthenticationManager;
+import org.jboss.security.RealmMapping;
+import org.jboss.security.SubjectSecurityManager;
 
 /**
  * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @author Anil.Saldhana at jboss.org
  * @version $Revision$
  */
 public class JaccAuthorizationInterceptorFactory implements AspectFactory
@@ -51,8 +61,9 @@
          CodeSource ejbCS = advisor.getClazz().getProtectionDomain().getCodeSource();
          
          String ejbName = ((EJBContainer)advisor).getEjbName(); 
-
-         return new JaccAuthorizationInterceptor(ejbName, ejbCS);
+         JaccAuthorizationInterceptor jai = new JaccAuthorizationInterceptor(ejbName, ejbCS);
+         jai.setRealmMapping(getSecurityManager(advisor)); 
+         return jai;
       }
       catch (Exception e)
       {
@@ -79,6 +90,26 @@
    {
       return getClass().getName();
    }
+   
+   public RealmMapping getSecurityManager(Advisor advisor)
+   {
+      Object domain = null;
+      Container container = (Container)advisor;
+      try
+      {
+         InitialContext ctx = container.getInitialContext();
+         SecurityDomain securityAnnotation = (SecurityDomain) advisor.resolveAnnotation(SecurityDomain.class);
+         if (securityAnnotation != null)
+         {
+            domain = SecurityDomainManager.getSecurityManager(securityAnnotation.value(),ctx);
+         }
+      }
+      catch (NamingException e)
+      {
+         throw new RuntimeException(e);
+      }
+      return (RealmMapping) domain;
+   }
 }
 
 

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -28,12 +28,18 @@
 import java.security.Policy;
 import java.security.Principal;
 import java.security.ProtectionDomain;
+import java.util.ArrayList;
+import java.util.Iterator;
 import java.util.Set;
+
+import javax.annotation.security.DeclareRoles;
 import javax.annotation.security.DenyAll;
 import javax.annotation.security.PermitAll;
 import javax.annotation.security.RolesAllowed;
+import javax.ejb.EJBAccessException;
 import javax.security.auth.Subject;
 import javax.security.jacc.EJBMethodPermission;
+import javax.security.jacc.EJBRoleRefPermission;
 import javax.security.jacc.PolicyConfiguration;
 import javax.security.jacc.PolicyConfigurationFactory;
 import javax.security.jacc.PolicyContextException;
@@ -44,9 +50,13 @@
 import org.jboss.ejb3.EJBContainer;
 import org.jboss.logging.Logger;
 import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.security.RealmMapping; 
+import org.jboss.security.RunAsIdentity;
 
 /**
+ * JACC Helper class that created permissions as well as done the checks
  * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @author Anil.Saldhana at jboss.com
  * @version $Revision$
  */
 public class JaccHelper
@@ -89,8 +99,10 @@
 
    public static void putJaccInService(PolicyConfiguration pc, DeploymentUnit di) throws Exception
    {
-
+      //TODO: How do we link this with the parent PC?
+      pc.commit(); 
    }
+   
    public static void putJaccInService(PolicyConfiguration pc, DeploymentInfo di) throws Exception
    {
       di.context.put("javax.security.jacc.PolicyConfiguration", pc);
@@ -133,25 +145,19 @@
          addPermissions(container, pc);
       }
       catch (Exception e)
-      {
-         e.printStackTrace();
+      { 
          throw new RuntimeException(e);
       }
    }
 
    private static void addPermissions(EJBContainer container, PolicyConfiguration pc)
    {
-      SecurityDomain sd = (SecurityDomain) container.resolveAnnotation(SecurityDomain.class);
+      SecurityDomain sd = (SecurityDomain) container.resolveAnnotation(SecurityDomain.class); 
 
-      if (sd == null)
-      {
-         log.debug(container.getEjbName() + " has no @SecurityDomain - skipping JACC configuration");
-         return;
-      }
-      log.debug(container.getEjbName() + " has @SecurityDomain - peforming JACC configuration");
-
       PermitAll beanUnchecked = (PermitAll) container.resolveAnnotation(PermitAll.class);
       RolesAllowed beanPermissions = (RolesAllowed) container.resolveAnnotation(RolesAllowed.class);
+      
+      DeclareRoles beanDeclareRolesPerms = (DeclareRoles)container.resolveAnnotation(DeclareRoles.class);
 
       if (beanUnchecked != null && beanPermissions != null)
       {
@@ -160,6 +166,24 @@
 
       String ejbName = container.getEjbName();
 
+      //Add the security role references
+      if(beanDeclareRolesPerms != null)
+      {
+         String[] rolerefs = beanDeclareRolesPerms.value();
+         int len = rolerefs != null ? rolerefs.length : 0;
+         for(int i=0; i < len; i++)
+         {
+             try
+            {
+               pc.addToRole(rolerefs[i], new EJBRoleRefPermission(ejbName, rolerefs[i]));
+            }
+            catch (PolicyContextException e)
+            {
+               throw new RuntimeException(e);
+            } 
+         }
+      }
+      
       //Am I iterating over the right thing here? Should I be using the stuff from 
       //Advisor.methodInterceptors instead?
       Method[] methods = container.getBeanClass().getDeclaredMethods();
@@ -182,7 +206,16 @@
 
          if (annotationCount == 0 && beanPermissions == null && beanUnchecked == null)
          {
-            continue;
+            //continue;
+            //EJBTHREE-755:Add to unchecked if there are no annotations
+            try
+            {
+               pc.addToUncheckedPolicy(permission);
+            }
+            catch (PolicyContextException e)
+            {
+               throw new RuntimeException(e); 
+            } 
          }
          else if (annotationCount > 1)
          {
@@ -228,7 +261,7 @@
          }
          catch (PolicyContextException e)
          {
-            throw new RuntimeException(e); // TODO Auto-generated catch block
+            throw new RuntimeException(e);  
          }
       }
    }
@@ -266,28 +299,47 @@
       container.addClassMetaData(jaccCtx);
    }
 
-   public static void checkPermission(CodeSource ejbCS, EJBMethodPermission methodPerm) throws SecurityException
+   public static void checkPermission(CodeSource ejbCS, EJBMethodPermission methodPerm,
+         RealmMapping realmMapping) 
+   throws EJBAccessException
    {
       try
       {
          Policy policy = Policy.getPolicy();
          // Get the caller
          Subject caller = SecurityActions.getContextSubject();
+  
+         RunAsIdentity rai = SecurityActions.peekRunAsIdentity();
 
          Principal[] principals = null;
-         if (caller != null)
+         if(rai != null)
          {
-            // Get the caller principals
-            Set principalsSet = caller.getPrincipals();
-            principals = new Principal[principalsSet.size()];
-            principalsSet.toArray(principals);
+            Set runAsRoles = rai.getRunAsRoles();
+            principals = new Principal[runAsRoles.size()];
+            runAsRoles.toArray(principals); 
          }
-
+         else
+         {
+            /*if (caller != null)
+            {
+               // Get the caller principals
+               Set principalsSet = caller.getPrincipals();
+               principals = new Principal[principalsSet.size()];
+               principalsSet.toArray(principals);
+            }*/
+            //Get the current roles from the Authorization Manager
+            Principal callerP = SecurityActions.getCallerPrincipal();
+            Set principalSet = realmMapping.getUserRoles(callerP);
+            principals = new Principal[principalSet.size()];
+            principalSet.toArray(principals);
+         } 
+         
          ProtectionDomain pd = new ProtectionDomain(ejbCS, null, null, principals);
          if (policy.implies(pd, methodPerm) == false)
          {
             String msg = "Denied: " + methodPerm + ", caller=" + caller;
-            SecurityException e = new SecurityException(msg);
+            //SecurityException e = new SecurityException(msg);
+            EJBAccessException e = new EJBAccessException(msg);
             throw e;
          }
       }

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptorFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptorFactory.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/RoleBasedAuthorizationInterceptorFactory.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -46,7 +46,7 @@
       {
          InitialContext ctx = container.getInitialContext();
          org.jboss.annotation.security.SecurityDomain securityAnnotation = (org.jboss.annotation.security.SecurityDomain) advisor.resolveAnnotation(org.jboss.annotation.security.SecurityDomain.class);
-         domain = ctx.lookup("java:/jaas/" + securityAnnotation.value());
+         domain = SecurityDomainManager.getSecurityManager(securityAnnotation.value(), ctx);
       }
       catch (NamingException e)
       {
@@ -76,6 +76,7 @@
    public String getName()
    {
       return getClass().getName();
-   }
+   } 
+   
 }
 

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptor.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptor.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -20,21 +20,12 @@
   * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
   */
 package org.jboss.ejb3.security;
-
-import java.util.Set;
-import java.util.HashSet;
-import java.util.Iterator;
-
-import java.security.Principal;
-
-import javax.annotation.security.RunAs;
-import org.jboss.aop.joinpoint.Invocation;
+ 
+import org.jboss.aop.joinpoint.Invocation;  
 import org.jboss.logging.Logger;
 import org.jboss.security.AuthenticationManager;
 import org.jboss.security.RealmMapping;
-import org.jboss.security.RunAsIdentity;
-import org.jboss.security.SecurityAssociation;
-import org.jboss.security.SimplePrincipal;
+import org.jboss.security.RunAsIdentity; 
 
 /**
  * An interceptor that enforces the run-as identity declared by a bean.
@@ -50,7 +41,7 @@
    public RunAsSecurityInterceptor(AuthenticationManager manager, RealmMapping realmMapping, RunAsIdentity id)
    {
       super(manager, realmMapping);
-      this.runAsIdentity = id;
+      this.runAsIdentity = id; 
    }
 
    protected RunAsIdentity getRunAsIdentity(Invocation invocation)
@@ -59,8 +50,8 @@
    }
 
    public Object invoke(Invocation invocation) throws Throwable
-   {
-      return super.invoke(invocation);
+   { 
+      return super.invoke(invocation); 
    }
 
 }

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -21,30 +21,26 @@
   */
 package org.jboss.ejb3.security;
 
+import java.util.HashSet;
+
+import javax.annotation.security.RunAs;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
-import javax.annotation.security.RunAs;
 
+import org.jboss.annotation.security.RunAsPrincipal;
 import org.jboss.aop.Advisor;
 import org.jboss.aop.InstanceAdvisor;
 import org.jboss.aop.advice.AspectFactory;
+import org.jboss.aop.advice.Interceptor;
 import org.jboss.aop.joinpoint.Joinpoint;
-import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.ejb3.EJBContainer;
+import org.jboss.ejb3.metamodel.AssemblyDescriptor;
+import org.jboss.ejb3.tx.NullInterceptor;
 import org.jboss.logging.Logger;
 import org.jboss.security.AuthenticationManager;
 import org.jboss.security.RealmMapping;
 import org.jboss.security.RunAsIdentity;
-import org.jboss.security.SecurityAssociation;
-import org.jboss.ejb3.Container;
-import org.jboss.ejb3.EJBContainer;
-import org.jboss.ejb3.tx.NullInterceptor;
-import org.jboss.annotation.security.RunAsPrincipal;
 
-import java.security.Principal;
-import java.util.Set;
-import java.util.Iterator;
-import java.util.HashSet;
-
 public class RunAsSecurityInterceptorFactory implements AspectFactory
 {
    private static final Logger log = Logger.getLogger(RunAsSecurityInterceptorFactory.class);
@@ -65,9 +61,17 @@
       }
       RunAsPrincipal rap = (RunAsPrincipal) container.resolveAnnotation(RunAsPrincipal.class);
       String runAsPrincipal = null;
-      if (rap != null) runAsPrincipal = rap.value();
+      if (rap != null) 
+         runAsPrincipal = rap.value();
+      else
+      {
+         //Check if jboss.xml has it  
+         runAsPrincipal = container.getXml().getSecurityIdentity().getRunAsPrincipal();
+      }
 
-      HashSet extraRoles = new HashSet(); // todo get extra mapped roles.
+      HashSet extraRoles = new HashSet();  
+      AssemblyDescriptor ad = container.getAssemblyDescriptor();
+      extraRoles.addAll(ad.getSecurityRolesGivenPrincipal(runAsPrincipal));
 
       return new RunAsIdentity(runAs.value(), runAsPrincipal, extraRoles);
    }
@@ -75,27 +79,37 @@
 
    public Object createPerClass(Advisor advisor)
    {
-      Object domain = null;
       EJBContainer container = (EJBContainer)advisor;
       RunAsIdentity runAsIdentity = getRunAsIdentity(container);
-      if (runAsIdentity == null)
+      /*if (runAsIdentity == null)
       {
          return new NullInterceptor();
-      }
+      }*/
+
+      Object domain = null;
       try
       {
          InitialContext ctx = container.getInitialContext();
-         org.jboss.annotation.security.SecurityDomain securityAnnotation = (org.jboss.annotation.security.SecurityDomain) advisor.resolveAnnotation(org.jboss.annotation.security.SecurityDomain.class);
-         domain = ctx.lookup("java:/jaas/" + securityAnnotation.value());
+         org.jboss.annotation.security.SecurityDomain anSecurityDomain = (org.jboss.annotation.security.SecurityDomain) advisor.resolveAnnotation(org.jboss.annotation.security.SecurityDomain.class);
+         if (anSecurityDomain != null)
+         {
+            String domainName = anSecurityDomain.value();
+            domain = SecurityDomainManager.getSecurityManager(domainName, ctx);
+         }
       }
       catch (NamingException e)
       {
          throw new RuntimeException(e);
       }
-      AuthenticationManager manager = (AuthenticationManager) domain;
-      RealmMapping mapping = (RealmMapping) domain;
-      if (manager == null) throw new RuntimeException("Unable to find Security Domain");
-      return new RunAsSecurityInterceptor(manager, mapping, getRunAsIdentity(container));
+      
+      Interceptor interceptor = new NullInterceptor();
+      if (domain != null)
+      {
+         AuthenticationManager manager = (AuthenticationManager) domain;
+         RealmMapping mapping = (RealmMapping) domain;
+         interceptor = new RunAsSecurityInterceptor(manager, mapping, getRunAsIdentity(container));
+      }
+      return interceptor;
    }
 
    public Object createPerInstance(Advisor advisor, InstanceAdvisor instanceAdvisor)

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/SecurityActions.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/SecurityActions.java	2006-12-05 19:54:06 UTC (rev 58849)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/SecurityActions.java	2006-12-05 19:56:55 UTC (rev 58850)
@@ -23,12 +23,16 @@
 
 import java.lang.reflect.UndeclaredThrowableException;
 import java.security.AccessController;
+import java.security.Principal;
 import java.security.PrivilegedAction;
 import java.security.PrivilegedActionException;
 import java.security.PrivilegedExceptionAction;
 import javax.security.auth.Subject;
 import javax.security.jacc.PolicyContext;
 import javax.security.jacc.PolicyContextException;
+  
+import org.jboss.security.RunAsIdentity;
+import org.jboss.security.SecurityAssociation;
 
 
 /**
@@ -41,6 +45,7 @@
  * @author Scott.Stark at jboss.org
  * @author <a href="mailto:alex at jboss.org">Alexey Loubyansky</a>
  * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @author Anil.Saldhana at jboss.org
  * @version $Revison: 1.1$
  */
 class SecurityActions
@@ -108,7 +113,77 @@
       Subject getContextSubject()
               throws PolicyContextException;
    }
+   
+   interface RunAsIdentityActions
+   {
+      RunAsIdentityActions PRIVILEGED = new RunAsIdentityActions()
+      {
+         private final PrivilegedAction peekAction = new PrivilegedAction()
+         {
+            public Object run()
+            {
+               return SecurityAssociation.peekRunAsIdentity();
+            }
+         };
 
+         private final PrivilegedAction popAction = new PrivilegedAction()
+         {
+            public Object run()
+            {
+               return SecurityAssociation.popRunAsIdentity();
+            }
+         };
+
+         public RunAsIdentity peek()
+         {
+            return (RunAsIdentity)AccessController.doPrivileged(peekAction);
+         }
+
+         public void push(final RunAsIdentity id)
+         {
+            AccessController.doPrivileged(
+               new PrivilegedAction()
+               {
+                  public Object run()
+                  {
+                     SecurityAssociation.pushRunAsIdentity(id);
+                     return null;
+                  }
+               }
+            );
+         }
+
+         public RunAsIdentity pop()
+         {
+            return (RunAsIdentity)AccessController.doPrivileged(popAction);
+         }
+      };
+
+      RunAsIdentityActions NON_PRIVILEGED = new RunAsIdentityActions()
+      {
+         public RunAsIdentity peek()
+         {
+            return SecurityAssociation.peekRunAsIdentity();
+         }
+
+         public void push(RunAsIdentity id)
+         {
+            SecurityAssociation.pushRunAsIdentity(id);
+         }
+
+         public RunAsIdentity pop()
+         {
+            return SecurityAssociation.popRunAsIdentity();
+         }
+      };
+
+      RunAsIdentity peek();
+
+      void push(RunAsIdentity id);
+
+      RunAsIdentity pop();
+   } 
+
    static Subject getContextSubject()
            throws PolicyContextException
    {
@@ -128,4 +203,50 @@
       String previousID = (String) AccessController.doPrivileged(action);
       return previousID;
    }
+   
+   static RunAsIdentity peekRunAsIdentity()
+   {
+      if(System.getSecurityManager() == null)
+      {
+         return RunAsIdentityActions.NON_PRIVILEGED.peek();
+      }
+      else
+      {
+         return RunAsIdentityActions.PRIVILEGED.peek();
+      }
+   }
+   
+   static void pushRunAsIdentity(RunAsIdentity principal)
+   {
+      if(System.getSecurityManager() == null)
+      {
+         RunAsIdentityActions.NON_PRIVILEGED.push(principal);
+      }
+      else
+      {
+         RunAsIdentityActions.PRIVILEGED.push(principal);
+      }
+   }
+   
+   static RunAsIdentity popRunAsIdentity()
+   {
+      if(System.getSecurityManager() == null)
+      {
+         return RunAsIdentityActions.NON_PRIVILEGED.pop();
+      }
+      else
+      {
+         return RunAsIdentityActions.PRIVILEGED.pop();
+      }
+   }
+   
+   static Principal getCallerPrincipal()
+   {
+      return (Principal)AccessController.doPrivileged(new PrivilegedAction(){
+
+         public Object run()
+         { 
+            return SecurityAssociation.getCallerPrincipal();
+         }});
+   }
 }

Copied: trunk/ejb3/src/main/org/jboss/ejb3/security/SecurityDomainManager.java (from rev 58846, branches/JEE5_TCK/ejb3/src/main/org/jboss/ejb3/security/SecurityDomainManager.java)



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 14:57:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 14:57:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r58851 - trunk/ejb3/src/main/org/jboss/ejb3
Message-ID: <E1GrgPq-0005lw-Lw@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 14:57:21 -0500 (Tue, 05 Dec 2006)
New Revision: 58851

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java
Log:
remove unused imports

Modified: trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java	2006-12-05 19:56:55 UTC (rev 58850)
+++ trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java	2006-12-05 19:57:21 UTC (rev 58851)
@@ -28,11 +28,8 @@
 import org.jboss.ejb3.enc.EjbModuleEjbResolver;
 import org.jboss.ejb3.enc.EjbModulePersistenceUnitResolver;
 import org.jboss.ejb3.entity.PersistenceUnitDeployment;
-import org.jboss.logging.Logger;
-import org.jboss.util.file.ArchiveBrowser;
-import org.jboss.util.file.ClassFileFilter;
-import org.jboss.virtual.VirtualFile;
-import org.jboss.virtual.VFS;
+import org.jboss.logging.Logger; 
+import org.jboss.virtual.VirtualFile; 
 
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
@@ -46,8 +43,7 @@
 import java.io.InputStream;
 import java.net.URL;
 import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.Iterator;
+import java.util.HashMap; 
 import java.util.LinkedHashMap;
 import java.util.List;
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 14:57:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 14:57:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r58852 -
	trunk/ejb3/src/main/org/jboss/ejb3/metamodel
Message-ID: <E1GrgQG-0005mF-Qo@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 14:57:47 -0500 (Tue, 05 Dec 2006)
New Revision: 58852

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/AssemblyDescriptor.java
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossDDObjectFactory.java
Log:
merge from JEE_TCK branch

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/AssemblyDescriptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/AssemblyDescriptor.java	2006-12-05 19:57:21 UTC (rev 58851)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/AssemblyDescriptor.java	2006-12-05 19:57:47 UTC (rev 58852)
@@ -20,13 +20,19 @@
 * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
 */ 
 package org.jboss.ejb3.metamodel;
-
+ 
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
 import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
 import org.jboss.logging.Logger;
-
+ 
+import org.jboss.metadata.SecurityRoleMetaData;
 import org.jboss.metamodel.descriptor.SecurityRole;
 
 /**
@@ -34,6 +40,7 @@
  * schema
  *
  * @author <a href="mailto:bdecoste at jboss.com">William DeCoste</a>
+ * @author Anil.Saldhana at jboss.org
  * @version <tt>$Revision$</tt>
  */
 public class AssemblyDescriptor
@@ -41,6 +48,8 @@
    private static final Logger log = Logger.getLogger(AssemblyDescriptor.class);
 
    private List securityRoles = new ArrayList();
+   
+   private Map<String, SecurityRoleMetaData> securityRoleMetaData = new HashMap();
 
    private List methodPermissions = new ArrayList();
 
@@ -167,6 +176,60 @@
    {
       containerTransactions.add(containerTransaction);
    }
+   
+   public void addSecurityRoleMetaData(SecurityRoleMetaData srm)
+   {
+      this.securityRoleMetaData.put(srm.getRoleName(), srm);
+   }
+   
+   public Set getSecurityRolesGivenPrincipal(String userName)
+   {
+      HashSet roleNames = new HashSet();
+      Iterator it = securityRoleMetaData.values().iterator();
+      while (it.hasNext())
+      {
+         SecurityRoleMetaData srMetaData = (SecurityRoleMetaData) it.next();
+         if (srMetaData.getPrincipals().contains(userName))
+            roleNames.add(srMetaData.getRoleName());
+      }
+      return roleNames;
+   }
+   
+   /**
+    * Get a map of principals versus set of roles
+    * that may be configured by the user at the deployment level
+    * @return
+    */
+   public Map getPrincipalVersusRolesMap()
+   {
+      Map principalRolesMap = null;
+      
+      Iterator iter = securityRoleMetaData.keySet().iterator();
+      while(iter.hasNext())
+      {
+         if(principalRolesMap == null)
+            principalRolesMap = new HashMap(); 
+         String rolename = (String)iter.next();
+         SecurityRoleMetaData srm = (SecurityRoleMetaData) securityRoleMetaData.get(rolename);
+         Iterator principalIter = srm.getPrincipals().iterator();
+         while(principalIter.hasNext())
+         {
+            String pr = (String)principalIter.next(); 
+            Set roleset = (Set)principalRolesMap.get(pr);
+            if(roleset == null)
+               roleset = new HashSet();
+            if(!roleset.contains(rolename))
+               roleset.add(rolename);
+            principalRolesMap.put(pr, roleset);
+         } 
+      } 
+      return principalRolesMap;
+   }
+   
+   public Map<String,SecurityRoleMetaData> getSecurityRoleMetaData()
+   {
+      return this.securityRoleMetaData;
+   }
 
    public String toString()
    {

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java	2006-12-05 19:57:21 UTC (rev 58851)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java	2006-12-05 19:57:47 UTC (rev 58852)
@@ -30,11 +30,9 @@
 
 import org.jboss.metamodel.descriptor.EnvironmentRefGroup;
 import org.jboss.metamodel.descriptor.InjectionTarget;
-import org.jboss.metamodel.descriptor.MessageDestinationRef;
-import org.jboss.metamodel.descriptor.PersistenceUnitRef;
+import org.jboss.metamodel.descriptor.MessageDestinationRef; 
 import org.jboss.metamodel.descriptor.ResourceEnvRef;
-import org.jboss.metamodel.descriptor.ResourceRef;
-import org.jboss.metamodel.descriptor.PersistenceContextRef;
+import org.jboss.metamodel.descriptor.ResourceRef; 
 
 /**
  * Represents an EJB element of the ejb-jar.xml deployment descriptor for the
@@ -185,8 +183,15 @@
 
    public void setRunAsPrincipal(String principal)
    {
-      if (securityIdentity != null)
-         securityIdentity.setRunAsPrincipal(principal);
+      /**
+       * A case where the RunAs is defined in annotations and the 
+       * RunAsPrincipal is specified in jboss.xml
+       */
+      if (securityIdentity == null)
+      {
+         securityIdentity = new SecurityIdentity();
+      }
+      securityIdentity.setRunAsPrincipal(principal);
    }
 
    public void setCallByValue(boolean callByValue)

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossDDObjectFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossDDObjectFactory.java	2006-12-05 19:57:21 UTC (rev 58851)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/JBossDDObjectFactory.java	2006-12-05 19:57:47 UTC (rev 58852)
@@ -22,7 +22,7 @@
 package org.jboss.ejb3.metamodel;
 
 import java.io.IOException;
-import java.net.URL;
+import java.net.URL; 
 
 import javax.management.ObjectName;
 
@@ -37,23 +37,24 @@
 import org.jboss.xb.binding.UnmarshallingContext;
 import org.xml.sax.Attributes;
 
+import org.jboss.metadata.SecurityRoleMetaData;
 import org.jboss.metamodel.descriptor.DDObjectFactory;
 import org.jboss.metamodel.descriptor.EjbLocalRef;
-import org.jboss.metamodel.descriptor.EjbRef;
-import org.jboss.metamodel.descriptor.EnvEntry;
+import org.jboss.metamodel.descriptor.EjbRef; 
 import org.jboss.metamodel.descriptor.InjectionTarget;
 import org.jboss.metamodel.descriptor.JndiRef;
 import org.jboss.metamodel.descriptor.MessageDestinationRef;
 import org.jboss.metamodel.descriptor.NameValuePair;
 import org.jboss.metamodel.descriptor.ResourceEnvRef;
-import org.jboss.metamodel.descriptor.ResourceRef;
-import org.jboss.metamodel.descriptor.SecurityRole;
+import org.jboss.metamodel.descriptor.ResourceRef; 
 import org.jboss.metamodel.descriptor.ServiceRef;
+import org.jboss.metamodel.descriptor.ServiceRef;
 
 /**
  * Represents the jboss.xml deployment descriptor for the 2.1 schema
  *
  * @author <a href="mailto:bdecoste at jboss.com">William DeCoste</a>
+ * @author Anil.Saldhana at jboss.com
  * @version <tt>$Revision$</tt>
  */
 public class JBossDDObjectFactory extends DDObjectFactory
@@ -283,6 +284,10 @@
       {
          child = new MessageDestination();
       }
+      if (localName.equals("security-role"))
+      { 
+         child = new SecurityRoleMetaData("dummy_to_be_replaced_in_setValue"); 
+      }
 
       return child;
    }
@@ -431,7 +436,13 @@
       parent.addMessageDestination(destination);
    }
    
+   public void addChild(AssemblyDescriptor parent, SecurityRoleMetaData srm,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   {
+      parent.addSecurityRoleMetaData(srm);
+   }
    
+   
    /**
     * Called when parsing character is complete.
     */
@@ -662,8 +673,7 @@
     */
    public void addChild(EnterpriseBeans parent, EnterpriseBeans ejbs,
                         UnmarshallingContext navigator, String namespaceURI, String localName)
-   {
-
+   { 
    }
 
    /**
@@ -1108,6 +1118,22 @@
       }
    }
    
+   /**
+    * Called when a child element with simple content is read for DD.
+    */
+   public void setValue(SecurityRoleMetaData srm, UnmarshallingContext navigator,
+                        String namespaceURI, String localName, String value)
+   {
+      if (localName.equals("role-name"))
+      {
+         srm.setRoleName(getValue(localName, value)); 
+      }
+      else if (localName.equals("principal-name"))
+      {
+         srm.addPrincipalName(getValue(localName, value));
+      } 
+   }
+   
    protected String getValue(String name, String value)
    {
       if (value.startsWith("${") && value.endsWith("}"))
@@ -1128,6 +1154,5 @@
       }
       
       return value;
-   }
-
+   } 
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 15:28:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 15:28:27 -0500
Subject: [jboss-cvs] JBossAS SVN: r58853 -
	trunk/ejb3/src/main/org/jboss/ejb3/security
Message-ID: <E1Grgtv-0006Om-25@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-05 15:28:26 -0500 (Tue, 05 Dec 2006)
New Revision: 58853

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java
Log:
replace debug logging with trace

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java	2006-12-05 19:57:47 UTC (rev 58852)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/JaccHelper.java	2006-12-05 20:28:26 UTC (rev 58853)
@@ -27,9 +27,7 @@
 import java.security.CodeSource;
 import java.security.Policy;
 import java.security.Principal;
-import java.security.ProtectionDomain;
-import java.util.ArrayList;
-import java.util.Iterator;
+import java.security.ProtectionDomain; 
 import java.util.Set;
 
 import javax.annotation.security.DeclareRoles;
@@ -69,7 +67,7 @@
     */
    public static PolicyConfiguration initialiseJacc(String contextID) throws Exception
    {
-      log.debug("Initialising JACC Context for deployment: " + contextID);
+      log.trace("Initialising JACC Context for deployment: " + contextID);
       PolicyConfigurationFactory pcFactory = Ejb3PolicyConfigurationFactory.getPolicyConfigurationFactory();
       boolean removeExistingContext = true;
       PolicyConfiguration pc = pcFactory.getPolicyConfiguration(contextID, removeExistingContext);
@@ -123,7 +121,7 @@
       }
 
       pc.commit();
-      log.debug("JACC Policy Configuration for deployment has been put in service");
+      log.trace("JACC Policy Configuration for deployment has been put in service");
    }
 
    public static void unregisterJacc(String contextID) throws Exception
@@ -196,7 +194,7 @@
          }
 
          EJBMethodPermission permission = new EJBMethodPermission(ejbName, null, m);
-         log.debug("Creating permission: " + permission);
+         log.trace("Creating permission: " + permission);
 
          PermitAll unchecked = (PermitAll) container.resolveAnnotation(m, PermitAll.class);
          RolesAllowed permissions = (RolesAllowed) container.resolveAnnotation(m, RolesAllowed.class);
@@ -228,7 +226,7 @@
             if (unchecked != null)
             {
                pc.addToUncheckedPolicy(permission);
-               log.debug("Adding permission to unchecked policy");
+               log.trace("Adding permission to unchecked policy");
                continue;
             }
             if (permissions != null)
@@ -239,14 +237,14 @@
             if (exclude != null)
             {
                pc.addToExcludedPolicy(permission);
-               log.debug("Adding permission to excluded policy");
+               log.trace("Adding permission to excluded policy");
                continue;
             }
 
             if (beanUnchecked != null)
             {
                pc.addToUncheckedPolicy(permission);
-               log.debug("Adding permission to unchecked policy");
+               log.trace("Adding permission to unchecked policy");
                continue;
             }
             if (beanPermissions != null)
@@ -257,7 +255,7 @@
 
             //The default is unchecked
             pc.addToUncheckedPolicy(permission);
-            log.debug("Adding permission to unchecked policy");
+            log.trace("Adding permission to unchecked policy");
          }
          catch (PolicyContextException e)
          {
@@ -282,7 +280,7 @@
       for (int i = 0; i < roles.length; i++)
       {
          pc.addToRole(roles[i], p);
-         log.debug("Adding permission to role: " + roles[i]);
+         log.trace("Adding permission to role: " + roles[i]);
       }
    }
 



From gavin.king at jboss.com  Tue Dec  5 15:28:27 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 15:28:27 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules   ...
Message-ID: <E1Grgtv-0006P8-PZ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 15:28:27

  Modified:    doc/reference/en/modules   configuration.xml tutorial.xml
  Log:
  update
  
  Revision  Changes    Path
  1.32      +98 -41    jboss-seam/doc/reference/en/modules/configuration.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: configuration.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/configuration.xml,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- configuration.xml	29 Nov 2006 10:28:03 -0000	1.31
  +++ configuration.xml	5 Dec 2006 20:28:27 -0000	1.32
  @@ -33,31 +33,6 @@
           </para>
   
           <para>
  -            If you are using Seam in Apache MyFaces (and possibly some other JSF implementations),
  -            you <emphasis>must</emphasis> use client-side state saving. So you'll also need this 
  -            in <literal>web.xml</literal>:
  -        </para>
  -        
  -<programlisting><![CDATA[<context-param>
  -    <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
  -    <param-value>client</param-value>
  -</context-param>]]></programlisting>
  -        
  -        <!-- No longer required:
  -        
  -        <para>
  -            To force JSF to delegate variable resolution to Seam, we need to register
  -            a <literal>VariableResolver</literal> in the 
  -            <literal>faces-config.xml</literal> file:
  -        </para>
  -        
  -        <programlisting><![CDATA[<application>
  -    <variable-resolver>org.jboss.seam.jsf.SeamVariableResolver</variable-resolver>
  -</application>]]></programlisting>
  -
  -         -->
  -
  -        <para>
               To integrate with the JSF request lifecycle, we also need a JSF
               <literal>PhaseListener</literal> registered in in the 
               <literal>faces-config.xml</literal> file:
  @@ -86,6 +61,18 @@
               around a minor bug in the RI.)
           </para>
           
  +        <para>
  +            Some JSF implementations have a broken implementation of server-side state
  +            saving that interferes with Seam's conversation propagation. If you have problems
  +            with conversation propagation during form submissions, try switching to client-side 
  +            state saving. You'll need this in <literal>web.xml</literal>:
  +        </para>
  +        
  +<programlisting><![CDATA[<context-param>
  +    <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
  +    <param-value>client</param-value>
  +</context-param>]]></programlisting>
  +        
           </sect2>
           
           <sect2>
  @@ -182,6 +169,29 @@
           
           </sect2>
   
  +        <sect2>
  +            <title>Using facelets</title>
  +
  +            <para>
  +                If you want follow our advice and use facelets instead of JSP,
  +                add the following lines to <literal>faces-config.xml</literal>:
  +            </para>
  +            
  +            <programlisting><![CDATA[<application>
  +    <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
  +</application>]]></programlisting>
  +
  +            <para>
  +                And the following lines to <literal>web.xml</literal>:
  +            </para>
  +            
  +            <programlisting><![CDATA[<context-param>
  +    <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
  +    <param-value>.xhtml</param-value>
  +</context-param>]]></programlisting>
  +
  +        </sect2>
  +
       </sect1>
       
       <sect1>
  @@ -199,11 +209,12 @@
           <para>
               If you're running in a Java EE 5 environment, this is all the configuration
               required to start using Seam! But there is one final item you need to know about. 
  -            You must place a <literal>seam.properties</literal> file in the root of any 
  -            archive in which your Seam components are deployed (even an empty properties file 
  -            will do). At startup, Seam will scan any archives with
  +            You must place a <literal>seam.properties</literal>, 
  +            <literal>META-INF/seam.properties</literal> or <literal>META-INF/components.xml</literal>
  +            file in any archive in which your Seam components are deployed (even an empty 
  +            properties file will do). At startup, Seam will scan any archives with
               <literal>seam.properties</literal> files for seam components. If that doesn't
  -            work for you, you can also add components by installing them explicitly in
  +            work for you, you can also add components by installing them explicitly via
               <literal>components.xml</literal>. (We don't recommend this alternative approach.)
           </para>
           
  @@ -217,6 +228,8 @@
           
           <programlisting><![CDATA[my-application.ear/
       jboss-seam.jar
  +    el-api.jar
  +    el-ri.jar
       META-INF/
           MANIFEST.MF
           application.xml
  @@ -227,6 +240,9 @@
               web.xml
               components.xml
               faces-config.xml
  +            lib/
  +                jsf-facelets.jar
  +                jboss-seam-ui.jar
           login.jsp
           register.jsp
           ...
  @@ -246,8 +262,32 @@
                       ...]]></programlisting>
           
           <para>
  -            Make sure you reference <literal>jboss-seam.jar</literal> from manifests of the
  -            EJB-JAR and WAR.
  +            You must include <literal>jboss-seam.jar</literal>, <literal>el-api.jar</literal> and 
  +            <literal>el-ri.jar</literal> in the EAR classpath. Make sure you reference all of these 
  +            jars from <literal>application.xml</literal>.
  +        </para>
  +        
  +        <para>
  +            If you want to use jBPM or Drools, you must include the needed jars in the EAR classpath. 
  +            Make sure you reference all of the jars from <literal>application.xml</literal>.
  +        </para>
  +        
  +        <para>
  +            If you want to use facelets (our recommendation), you must include
  +            <literal>jsf-facelets.jar</literal> in the <literal>WEB-INF/lib</literal> directory
  +            of the WAR.
  +        </para>
  +        
  +        <para>
  +            If you want to use the Seam tag library (most Seam applications do), you must include
  +            <literal>jboss-seam-ui.jar</literal> in the <literal>WEB-INF/lib</literal> directory
  +            of the WAR.
  +        </para>
  +        
  +        <para>
  +            If you want to use the Seam debug page (only works for applications using facelets), you 
  +            must include <literal>jboss-seam-debug.jar</literal> in the <literal>WEB-INF/lib</literal> 
  +            directory of the WAR.
           </para>
           
           <para>
  @@ -386,6 +426,10 @@
           faces-config.xml
           lib/
               jboss-seam.jar
  +            jboss-seam-ui.jar
  +            el-api.jar
  +            el-ri.jar
  +            jsf-facelets.jar
               myfaces-api.jar
               myfaces-impl.jar
               jboss-ejb3.jar
  @@ -663,6 +707,10 @@
           faces-config.xml
           lib/
               jboss-seam.jar
  +            jboss-seam-ui.jar
  +            el-api.jar
  +            el-ri.jar
  +            jsf-facelets.jar
               hibernate3.jar
               ...
               my-application.jar/
  @@ -803,6 +851,10 @@
           faces-config.xml
           lib/
               jboss-seam.jar
  +            jboss-seam-ui.jar
  +            el-api.jar
  +            el-ri.jar
  +            jsf-facelets.jar
               hibernate3.jar
               ...
               jboss-microcontainer.jar
  @@ -898,6 +950,8 @@
               
           <programlisting><![CDATA[my-application.ear/
       jboss-seam.jar
  +    el-api.jar
  +    el-ri.jar
       jbpm-3.1.jar
       META-INF/
           MANIFEST.MF
  @@ -909,6 +963,9 @@
               web.xml
               components.xml
               faces-config.xml
  +            lib/
  +                jsf-facelets.jar
  +                jboss-seam-ui.jar
           login.jsp
           register.jsp
           ...
  
  
  
  1.75      +18 -3     jboss-seam/doc/reference/en/modules/tutorial.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: tutorial.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/tutorial.xml,v
  retrieving revision 1.74
  retrieving revision 1.75
  diff -u -b -r1.74 -r1.75
  --- tutorial.xml	29 Nov 2006 10:28:03 -0000	1.74
  +++ tutorial.xml	5 Dec 2006 20:28:27 -0000	1.75
  @@ -674,7 +674,11 @@
               enables automatic schema export at startup time.
           </para>
   
  -        <programlisting><![CDATA[<persistence>
  +        <programlisting><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
  +<persistence xmlns="http://java.sun.com/xml/ns/persistence" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
  +             version="1.0">
       <persistence-unit name="userDatabase">
         <provider>org.hibernate.ejb.HibernatePersistence</provider>
         <jta-data-source>java:/DefaultDS</jta-data-source>
  @@ -770,8 +774,13 @@
           </para>
           
           <example id="registration-application-xml">
  -          <programlisting><![CDATA[<application>
  -    <display-name>Seam</display-name>
  +          <programlisting><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
  +<application xmlns="http://java.sun.com/xml/ns/javaee" 
  +             xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +             xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
  +             version="5">
  +             
  +    <display-name>Seam Registration</display-name>
   
       <module>
           <web>
  @@ -785,6 +794,12 @@
       <module>
           <java>jboss-seam.jar</java>
       </module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
       
   </application>]]></programlisting>
           </example>
  
  
  


From c47 at fullmailmarket.com  Tue Dec  5 16:57:09 2006
From: c47 at fullmailmarket.com (RamChile)
Date: Tue, 5 Dec 2006 18:57:09 -0300
Subject: [jboss-cvs] Venta de Bodega
Message-ID: <200612052157.kB5LvEnp007397@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061205/1f9f559a/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 17:05:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 17:05:18 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58854 - branches
Message-ID: <E1GriPe-00086K-Sq@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-05 17:05:17 -0500 (Tue, 05 Dec 2006)
New Revision: 58854

Added:
   branches/JBoss_4_0_5_GA_EJBTHREE-798/
Log:
Create a branch for the EJBTHREE-798 patch

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798 (from rev 58853, tags/JBoss_4_0_5_GA)



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 18:04:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 18:04:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r58855 - in projects/aop/trunk/aop: .
	src/resources/test src/resources/test/beforeafterArgs
	src/test/org/jboss/test/aop/beforeafter
	src/test/org/jboss/test/aop/beforeafter/arg
Message-ID: <E1GrjKr-0000ew-At@committer01.frg.pub.inap.atl.jboss.com>

Author: flaviarnn
Date: 2006-12-05 18:03:14 -0500 (Tue, 05 Dec 2006)
New Revision: 58855

Added:
   projects/aop/trunk/aop/src/resources/test/beforeafterArgs/
   projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/InvalidAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAdvicePOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAdviceTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAfterAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAroundAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedBeforeAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/POJOException.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubClass.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubValue.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperClass.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperValue.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownTestCase.java
Modified:
   projects/aop/trunk/aop/build-tests-jdk14.xml
   projects/aop/trunk/aop/build-tests-jdk50.xml
Log:
[JBAOP-37] Old arg tests plus new ones

Modified: projects/aop/trunk/aop/build-tests-jdk14.xml
===================================================================
--- projects/aop/trunk/aop/build-tests-jdk14.xml	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/build-tests-jdk14.xml	2006-12-05 23:03:14 UTC (rev 58855)
@@ -521,6 +521,10 @@
          <param name="caller" value="precompiled-genadvisor-tests"/>
       </antcall>
       <antcall target="_run-precompiled-test" inheritRefs="true">
+         <param name="test" value="beforeafterArgs"/>
+         <param name="caller" value="precompiled-genadvisor-tests"/>
+      </antcall>
+      <antcall target="_run-precompiled-test" inheritRefs="true">
          <param name="test" value="dynamicgenadvisor"/>
          <param name="caller" value="precompiled-genadvisor-tests"/>
       </antcall>

Modified: projects/aop/trunk/aop/build-tests-jdk50.xml
===================================================================
--- projects/aop/trunk/aop/build-tests-jdk50.xml	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/build-tests-jdk50.xml	2006-12-05 23:03:14 UTC (rev 58855)
@@ -506,6 +506,10 @@
          <param name="caller" value="precompiled-genadvisor-tests"/>
       </antcall>
       <antcall target="_run-precompiled-test" inheritRefs="true">
+         <param name="test" value="beforeafterArgs"/>
+         <param name="caller" value="precompiled-genadvisor-tests"/>
+      </antcall>
+      <antcall target="_run-precompiled-test" inheritRefs="true">
          <param name="test" value="dynamicgenadvisor"/>
          <param name="caller" value="precompiled-genadvisor-tests"/>
       </antcall>

Added: projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,235 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE aop SYSTEM "jboss-aop_1_0.dtd">
+
+<aop>
+   <!-- @JoinPoint test -->
+	<aspect class="org.jboss.test.aop.beforeafterArgs.JoinPointAspect" scope="PER_VM"/>
+
+	<bind pointcut="field(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->number)">
+		<before name="before1" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+		<after name="after1" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+	<bind pointcut="set(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->text)">
+		<before name="before2" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+		<after name="after2" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+	<bind pointcut="get(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->text)">
+		<before name="before5" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+		<after name="after5" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->method1(..))">
+    	<before name="before3" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+		<after name="after3" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->method2(..))">
+    	<before name="before4" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+		<after name="after4" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   	<throwing name="throwing1" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+   
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->method3(..))">
+   	<throwing name="throwing2" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->method4(..))">
+   	<throwing name="throwing3" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->method5(..))">
+   	<throwing name="throwing4" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.JoinPointPOJO->method6(..))">
+   	<throwing name="throwing5" aspect="org.jboss.test.aop.beforeafterArgs.JoinPointAspect"/>
+   </bind>
+
+   <!-- Return type and @Return test -->
+	<aspect class="org.jboss.test.aop.beforeafterArgs.ReturnAspect" scope="PER_VM"/>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method1(..))">
+		<before name="before" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<advice name="around1" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after1" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method2(..))">
+		<advice name="around2" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+      <after name="after2" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method3(..))">
+		<before name="before" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<advice name="around3" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+      <after name="after3" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method4(..))">
+		<advice name="around4" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after4" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method5(..))">
+		<advice name="around5" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after5" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method6(..))">
+		<advice name="around6" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after6" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method7(..))">
+		<advice name="around7" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after7" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method8(..))">
+		<before name="before" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<advice name="around8" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after8" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method9(..))">
+		<advice name="around9" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after9" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method10(..))">
+		<before name="before" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<advice name="around10" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after10" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ReturnPOJO->method11(..))">
+		<advice name="around11" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+		<after name="after11" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
+	</bind>
+
+   <!-- @Thrown test -->
+	<aspect class="org.jboss.test.aop.beforeafterArgs.ThrownAspect" scope="PER_VM"/>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ThrownPOJO->method1(..))">
+		<throwing name="throwing1" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ThrownPOJO->method2(..))">
+		<throwing name="throwing2" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+	</bind>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ThrownPOJO->method3(..))">
+		<throwing name="throwing3" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+	</bind>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ThrownPOJO->method4(..))">
+		<throwing name="throwing4" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+	</bind>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ThrownPOJO->method5(..))">
+		<throwing name="throwing5" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+	</bind>
+	
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ThrownPOJO->method6(..))">
+		<throwing name="throwing6" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+		<throwing name="throwing7" aspect="org.jboss.test.aop.beforeafterArgs.ThrownAspect"/>
+	</bind>
+
+   <!-- overloaded advices test -->
+   
+   <aspect class="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect" scope="PER_VM"/>
+
+  	<bind pointcut="set(* org.jboss.test.aop.beforeafterArgs.OverloadedAdvicePOJO->text)">
+   	<before name="before1" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+      <before name="before2" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before3" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before4" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before5" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before6" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before7" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before8" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before9" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before10" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before11" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+   	<before name="before12" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+  	</bind>
+  	
+   <aspect class="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect" scope="PER_VM"/>
+  	   
+  	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.OverloadedAdvicePOJO->method1(int,long))">
+   	<advice name="around1" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+      <advice name="around2" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around3" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around4" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around5" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around6" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around7" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around8" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around9" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around10" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around11" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/>
+   	<advice name="around12" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect"/> 
+  	</bind>
+   
+   <aspect class="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect" scope="PER_VM"/>
+   
+  	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.OverloadedAdvicePOJO->method2(..))">
+   	<after name="after1" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after2" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after3" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after4" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after5" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after6" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after7" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after8" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after9" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+   	<after name="after10" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after11" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after12" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after13" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after14" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after15" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after16" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after17" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after18" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after19" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after20" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after21" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after22" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after23" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after24" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after25" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after26" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after27" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after28" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after29" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after30" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after31" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after32" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after33" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after34" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after35" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after36" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after37" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after38" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after39" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after40" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after41" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after42" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after43" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after44" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after45" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after46" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after47" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after48" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after49" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after50" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after51" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after52" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after53" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after54" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+      <after name="after55" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
+  	</bind>
+</aop>
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/InvalidAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/InvalidAspect.java	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/InvalidAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+/**
+ * Aspect whose advices must never be called.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+/* TODO remove configuration from jboss-aop.xml file (in org.jboss.test.aop.args
+ * and use it here
+ */
+public class InvalidAspect
+{
+   public void before(@org.jboss.aop.advice.annotation.Invocation Object object)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void after(@org.jboss.aop.advice.annotation.Invocation Object object)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void throwing(@org.jboss.aop.advice.annotation.Invocation Object object)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointAspect.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointAspect.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointAspect.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,142 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+import org.jboss.aop.ConstructorInfo;
+import org.jboss.aop.FieldInfo;
+import org.jboss.aop.JoinPointInfo;
+import org.jboss.aop.MethodInfo;
+import org.jboss.aop.advice.annotation.JoinPoint;
+import org.jboss.aop.advice.annotation.Thrown;
+
+/**
+ * Aspect used on @JoinPoint parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class JoinPointAspect
+{
+   static String beforeAdvice = null;
+   static JoinPointInfo beforeJoinPointInfo = null;
+   static String afterAdvice = null;
+   static JoinPointInfo afterJoinPointInfo = null;
+   static String throwingAdvice = null;
+   static JoinPointInfo throwingJoinPointInfo = null;
+   
+   public static void clear()
+   {
+      beforeAdvice = null;
+      beforeJoinPointInfo = null;
+      afterAdvice = null;
+      afterJoinPointInfo = null;
+      throwingAdvice = null;
+      throwingJoinPointInfo = null;
+   }
+   
+   public void before1()
+   {
+      beforeAdvice = "before1";
+   }
+   
+   public void before2(@JoinPoint Object joinPointInfo)
+   {
+      beforeAdvice = "before2";
+      beforeJoinPointInfo = (JoinPointInfo) joinPointInfo;
+   }
+   
+   public void before3(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      beforeAdvice = "before3";
+      beforeJoinPointInfo = joinPointInfo;
+   }   
+   
+   public void before4(@JoinPoint MethodInfo joinPointInfo)
+   {
+      beforeAdvice = "before4";
+      beforeJoinPointInfo = (JoinPointInfo) joinPointInfo;
+   }
+   
+   public void before5(@JoinPoint MethodInfo joinPointInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void after1(@JoinPoint FieldInfo joinPointInfo)
+   {
+      afterAdvice = "after1";
+      afterJoinPointInfo = joinPointInfo;
+   }
+   
+   public void after2(@JoinPoint ConstructorInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void after3()
+   {
+      afterAdvice = "after3";
+   }
+   
+   public void after4(@JoinPoint Object joinPointInfo)
+   {
+      afterAdvice = "after4";
+      afterJoinPointInfo = (JoinPointInfo) joinPointInfo;
+   }
+   
+   public void after5(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      afterAdvice = "after5";
+      afterJoinPointInfo = joinPointInfo;
+   }
+   
+   public void throwing1(@Thrown Throwable throwable, @JoinPoint Object joinPointInfo)
+   {
+      throwingAdvice = "throwing1";
+      throwingJoinPointInfo = (JoinPointInfo) joinPointInfo;
+   }
+   
+   public void throwing2(@JoinPoint ConstructorInfo joinPointInfo,
+         @Thrown Throwable throwable)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void throwing3(@Thrown Throwable throwable,
+         @JoinPoint JoinPointInfo joinPointInfo)
+   {
+      throwingAdvice = "throwing3";
+      throwingJoinPointInfo = joinPointInfo;
+   }
+   
+   public void throwing4(@Thrown Throwable throwable)
+   {
+      throwingAdvice = "throwing4";
+   }
+   
+   public void throwing5(@JoinPoint MethodInfo joinPointInfo, @Thrown Throwable throwable)
+   {
+      throwingAdvice = "throwing5";
+      throwingJoinPointInfo = joinPointInfo;
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointPOJO.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointPOJO.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointPOJO.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointPOJO.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,67 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Plain old java object used on @JoinPoint parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class JoinPointPOJO
+{
+   public int number;
+   public String text;
+   
+   public void method1()
+   {
+      
+   }
+   
+   public String method2(boolean shouldThrow) throws POJOException
+   {
+      if (shouldThrow)
+      {
+         throw new POJOException();
+      }
+      return "method3";
+   }
+   
+   public void method3() throws POJOException
+   {
+      throw new POJOException();
+   }
+   
+   public void method4() throws POJOException
+   {
+      throw new POJOException();
+   }
+   
+   public void method5() throws POJOException
+   {
+      throw new POJOException();
+   }
+   
+   public void method6() throws POJOException
+   {
+      throw new POJOException();
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointTestCase.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointTestCase.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/JoinPointTestCase.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/JoinPointTestCase.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,248 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.aop.FieldInfo;
+import org.jboss.aop.MethodInfo;
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * Tests the use of @JoinPoint parameters.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class JoinPointTestCase extends AOPTestWithSetup
+{
+   private JoinPointPOJO pojo;
+   
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("JoinPointTestCase");
+      suite.addTestSuite(JoinPointTestCase.class);
+      return suite;
+   }
+   
+   public JoinPointTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      JoinPointAspect.clear();
+      this.pojo = new JoinPointPOJO();
+   }
+   
+   public void test1()
+   {
+      pojo.number = 0;
+      assertEquals("before1", JoinPointAspect.beforeAdvice);
+      assertNull(JoinPointAspect.beforeJoinPointInfo);
+      assertEquals("after1", JoinPointAspect.afterAdvice);
+      assertNotNull(JoinPointAspect.afterJoinPointInfo);
+      assertTrue(JoinPointAspect.afterJoinPointInfo instanceof FieldInfo);
+      FieldInfo fieldInfo = (FieldInfo) JoinPointAspect.afterJoinPointInfo;
+      assertEquals("number", fieldInfo.getAdvisedField().getName());
+      assertFalse(fieldInfo.isRead());
+   }
+   
+   public void test2()
+   {
+      pojo.text = "test2";
+      assertEquals("before2", JoinPointAspect.beforeAdvice);
+      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
+      assertNull(JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      
+      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof FieldInfo);
+      FieldInfo fieldInfo = (FieldInfo) JoinPointAspect.beforeJoinPointInfo;
+      assertEquals("text", fieldInfo.getAdvisedField().getName());
+      assertFalse(fieldInfo.isRead());
+   }
+   
+   public void test3()
+   {
+      String text = pojo.text;
+      assertNull(JoinPointAspect.beforeAdvice);
+      assertNull(JoinPointAspect.beforeJoinPointInfo);
+      assertEquals("after5", JoinPointAspect.afterAdvice);
+      assertNotNull(JoinPointAspect.afterJoinPointInfo);
+      assertTrue(JoinPointAspect.afterJoinPointInfo instanceof FieldInfo);
+      FieldInfo fieldInfo = (FieldInfo) JoinPointAspect.afterJoinPointInfo;
+      assertEquals("text", fieldInfo.getAdvisedField().getName());
+      assertTrue(fieldInfo.isRead());
+   }
+   
+   public void test4()
+   {
+      pojo.method1();
+      assertEquals("before3", JoinPointAspect.beforeAdvice);
+      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
+      assertEquals("after3", JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof MethodInfo);
+      assertEquals("method1", ((MethodInfo) JoinPointAspect.beforeJoinPointInfo).
+            getAdvisedMethod().getName());
+   }
+   
+   public void test5() throws POJOException
+   {
+      pojo.method2(false);
+      assertEquals("before4", JoinPointAspect.beforeAdvice);
+      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
+      assertEquals("after4", JoinPointAspect.afterAdvice);
+      assertNotNull(JoinPointAspect.afterJoinPointInfo);
+      assertNull(JoinPointAspect.throwingAdvice);
+      assertNull(JoinPointAspect.throwingJoinPointInfo);
+      assertSame(JoinPointAspect.beforeJoinPointInfo, JoinPointAspect.afterJoinPointInfo);
+      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof MethodInfo);
+      assertEquals("method2", ((MethodInfo) JoinPointAspect.beforeJoinPointInfo).
+            getAdvisedMethod().getName());
+   }
+   
+   public void test6() throws POJOException
+   {
+      boolean exceptionThrown = false;
+      try
+      {
+         pojo.method2(true);
+      }
+      catch (POJOException e)
+      {
+         exceptionThrown = true;
+      }
+      assertTrue(exceptionThrown);
+      
+      assertEquals("before4", JoinPointAspect.beforeAdvice);
+      assertNotNull(JoinPointAspect.beforeJoinPointInfo);
+      assertNull(JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      assertEquals("throwing1", JoinPointAspect.throwingAdvice);
+      assertNotNull(JoinPointAspect.throwingJoinPointInfo);
+      assertSame(JoinPointAspect.beforeJoinPointInfo,
+            JoinPointAspect.throwingJoinPointInfo);
+      assertTrue(JoinPointAspect.beforeJoinPointInfo instanceof MethodInfo);
+      assertEquals("method2", ((MethodInfo) JoinPointAspect.beforeJoinPointInfo).
+            getAdvisedMethod().getName());
+   }
+   
+   public void test7() throws POJOException
+   {
+      boolean exceptionThrown = false;
+      try
+      {
+         pojo.method3();
+      }
+      catch (POJOException e)
+      {
+         exceptionThrown = true;
+      }
+      assertTrue(exceptionThrown);
+      
+      assertNull(JoinPointAspect.beforeAdvice);
+      assertNull(JoinPointAspect.beforeJoinPointInfo);
+      assertNull(JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      assertNull(JoinPointAspect.throwingAdvice);
+      assertNull(JoinPointAspect.throwingJoinPointInfo);
+   }
+   
+   public void test8() throws POJOException
+   {
+      boolean exceptionThrown = false;
+      try
+      {
+         pojo.method4();
+      }
+      catch (POJOException e)
+      {
+         exceptionThrown = true;
+      }
+      assertTrue(exceptionThrown);
+      
+      assertNull(JoinPointAspect.beforeAdvice);
+      assertNull(JoinPointAspect.beforeJoinPointInfo);
+      assertNull(JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      assertEquals("throwing3", JoinPointAspect.throwingAdvice);
+      assertNotNull(JoinPointAspect.throwingJoinPointInfo);
+      assertTrue(JoinPointAspect.throwingJoinPointInfo instanceof MethodInfo);
+      assertEquals("method4", ((MethodInfo) JoinPointAspect.throwingJoinPointInfo).
+            getAdvisedMethod().getName());
+   }
+   
+   public void test9() throws POJOException
+   {
+      boolean exceptionThrown = false;
+      try
+      {
+         pojo.method5();
+      }
+      catch (POJOException e)
+      {
+         exceptionThrown = true;
+      }
+      assertTrue(exceptionThrown);
+      
+      assertNull(JoinPointAspect.beforeAdvice);
+      assertNull(JoinPointAspect.beforeJoinPointInfo);
+      assertNull(JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      assertEquals("throwing4", JoinPointAspect.throwingAdvice);
+      assertNull(JoinPointAspect.throwingJoinPointInfo);
+   }
+   
+   public void test10() throws POJOException
+   {
+      boolean exceptionThrown = false;
+      try
+      {
+         pojo.method6();
+      }
+      catch (POJOException e)
+      {
+         exceptionThrown = true;
+      }
+      assertTrue(exceptionThrown);
+      
+      assertNull(JoinPointAspect.beforeAdvice);
+      assertNull(JoinPointAspect.beforeJoinPointInfo);
+      assertNull(JoinPointAspect.afterAdvice);
+      assertNull(JoinPointAspect.afterJoinPointInfo);
+      assertEquals("throwing5", JoinPointAspect.throwingAdvice);
+      assertNotNull(JoinPointAspect.throwingJoinPointInfo);
+      assertTrue(JoinPointAspect.throwingJoinPointInfo instanceof MethodInfo);
+      assertEquals("method6", ((MethodInfo) JoinPointAspect.throwingJoinPointInfo).
+            getAdvisedMethod().getName());
+
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAdvicePOJO.java (from rev 58716, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdvicePOJO.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdvicePOJO.java	2006-11-29 01:03:28 UTC (rev 58716)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAdvicePOJO.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Plain old java object used on overloaded advice tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class OverloadedAdvicePOJO
+{
+   public String text;
+   
+   public void method1(int arg1, long arg2) {}
+   
+   public SuperClass method2(float arg1, SubValue arg2)
+   {
+      return null;
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAdviceTestCase.java (from rev 58716, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceTestCase.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/OverloadedAdviceTestCase.java	2006-11-29 01:03:28 UTC (rev 58716)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAdviceTestCase.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,165 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * Tests the selection of advice methods when these are overloaded.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class OverloadedAdviceTestCase extends AOPTestWithSetup
+{
+   private OverloadedAdvicePOJO pojo;
+   
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("OverloadedAdviceTestCase");
+      suite.addTestSuite(OverloadedAdviceTestCase.class);
+      return suite;
+   }
+   
+   public OverloadedAdviceTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      this.pojo = new OverloadedAdvicePOJO();
+   }
+
+   public void test1()
+   {
+      OverloadedBeforeAspect.clear();
+      pojo.text = "test2";
+      assertEquals("FieldInfo,String", OverloadedBeforeAspect.before1);
+      assertEquals("FieldInfo,Object", OverloadedBeforeAspect.before2);
+      assertEquals("JoinPointInfo,String", OverloadedBeforeAspect.before3);
+      assertEquals("JoinPointInfo,Object", OverloadedBeforeAspect.before4);
+      assertEquals("Object,String", OverloadedBeforeAspect.before5);
+      assertEquals("Object,Object", OverloadedBeforeAspect.before6);
+      assertEquals("FieldInfo", OverloadedBeforeAspect.before7);
+      assertEquals("JoinPointInfo", OverloadedBeforeAspect.before8);
+      assertEquals("Object", OverloadedBeforeAspect.before9);
+      assertEquals("String", OverloadedBeforeAspect.before10);
+      assertEquals("Object", OverloadedBeforeAspect.before11);
+      assertEquals("", OverloadedBeforeAspect.before12);
+   }
+   
+   public void test2()
+   {
+      OverloadedAroundAspect.clear();
+      pojo.method1(10, 15);
+      assertEquals("defaultSignature", OverloadedAroundAspect.around1);
+      assertEquals("MethodInvocation,int,long", OverloadedAroundAspect.around2);
+      assertEquals("Invocation,int,long", OverloadedAroundAspect.around3);
+      assertEquals("Object,int,long", OverloadedAroundAspect.around4);
+      assertTrue(OverloadedAroundAspect.around5.startsWith("MethodInvocation,"));
+      assertTrue(OverloadedAroundAspect.around5.equals("MethodInvocation,int") ||
+            OverloadedAroundAspect.around5.equals("MethodInvocation,long"));
+      assertTrue(OverloadedAroundAspect.around6.startsWith("Invocation,"));
+      assertTrue(OverloadedAroundAspect.around6.equals("Invocation,int") ||
+            OverloadedAroundAspect.around6.equals("Invocation,long"));
+      assertTrue(OverloadedAroundAspect.around7.startsWith("Object,"));
+      assertTrue(OverloadedAroundAspect.around7.equals("Object,int") ||
+            OverloadedAroundAspect.around7.equals("Object,long"));
+      assertEquals("MethodInvocation", OverloadedAroundAspect.around8);
+      assertEquals("Object", OverloadedAroundAspect.around9);
+      assertEquals("int,long", OverloadedAroundAspect.around10);
+      assertTrue(OverloadedAroundAspect.around11.equals("int") ||
+            OverloadedAroundAspect.around11.equals("long"));
+      assertEquals("", OverloadedAroundAspect.around12);
+   }
+   
+   public void test3()
+   {
+      OverloadedAfterAspect.clear();
+      pojo.method2(0, null);
+      assertEquals("Object,MethodInfo,SuperClass,float,SubValue", OverloadedAfterAspect.after1);
+      assertEquals("Object,MethodInfo,SuperClass,float,SuperValue", OverloadedAfterAspect.after2);
+      assertEquals("Object,MethodInfo,SuperClass,float,Object", OverloadedAfterAspect.after3);
+      assertEquals("Object,MethodInfo,Object,float,SubValue", OverloadedAfterAspect.after4);
+      assertEquals("Object,MethodInfo,Object,float,SuperValue", OverloadedAfterAspect.after5);
+      assertEquals("Object,MethodInfo,Object,float,Object", OverloadedAfterAspect.after6);
+      assertEquals("Object,JoinPointInfo,SuperClass,float,SubValue", OverloadedAfterAspect.after7);
+      assertEquals("SuperClass,MethodInfo,SuperClass,SubValue", OverloadedAfterAspect.after8);
+      assertEquals("Object,MethodInfo,SuperClass,float", OverloadedAfterAspect.after9);
+      assertEquals("Object,MethodInfo,SuperClass,SuperValue", OverloadedAfterAspect.after10);
+      assertEquals("SuperClass,MethodInfo,SuperClass,Object", OverloadedAfterAspect.after11);
+      assertEquals("SuperClass,MethodInfo,Object,SubValue", OverloadedAfterAspect.after12);
+      assertEquals("Object,MethodInfo,Object,float", OverloadedAfterAspect.after13);
+      assertEquals("SubClass,MethodInfo,Object,SuperValue", OverloadedAfterAspect.after14);
+      assertEquals("SubClass,MethodInfo,Object,Object", OverloadedAfterAspect.after15);
+      assertEquals("SuperClass,JoinPointInfo,SuperClass,SubValue", OverloadedAfterAspect.after16);
+      assertEquals("SubClass,JoinPointInfo,SuperClass,float", OverloadedAfterAspect.after17);
+      assertEquals("SubClass,JoinPointInfo,SuperClass,SuperValue", OverloadedAfterAspect.after18);
+      assertEquals("SuperClass,JoinPointInfo,SuperClass,Object", OverloadedAfterAspect.after19);
+      assertEquals("SubClass,Object,SuperClass,SubValue", OverloadedAfterAspect.after20);
+      assertEquals("Object,Object,SuperClass,float", OverloadedAfterAspect.after21);
+      assertEquals("SubClass,Object,SuperClass,SuperValue", OverloadedAfterAspect.after22);
+      assertEquals("Object,Object,SuperClass,Object", OverloadedAfterAspect.after23);
+      assertEquals("Object,MethodInfo,SuperClass", OverloadedAfterAspect.after24);
+      assertEquals("Object,MethodInfo,Object", OverloadedAfterAspect.after25);
+      assertEquals("Object,JoinPointInfo,SuperClass", OverloadedAfterAspect.after26);
+      assertEquals("Object,MethodInfo,float,SubValue", OverloadedAfterAspect.after27);
+      assertEquals("Object,MethodInfo,float,SuperValue", OverloadedAfterAspect.after28);
+      assertEquals("Object,MethodInfo,float,Object", OverloadedAfterAspect.after29);
+      assertEquals("Object,JoinPointInfo,float,SubValue", OverloadedAfterAspect.after30);
+      assertEquals("SuperClass,MethodInfo,SubValue", OverloadedAfterAspect.after31);
+      assertEquals("Object,MethodInfo,float", OverloadedAfterAspect.after32);
+      assertEquals("Object,MethodInfo,SuperValue", OverloadedAfterAspect.after33);
+      assertEquals("SuperClass,JoinPointInfo,SubValue", OverloadedAfterAspect.after34);
+      assertEquals("SubClass,JoinPointInfo,float", OverloadedAfterAspect.after35);
+      assertEquals("SubClass,JoinPointInfo,SuperValue", OverloadedAfterAspect.after36);
+      assertEquals("SubClass,Object,SubValue", OverloadedAfterAspect.after37);
+      assertEquals("Object,Object,float", OverloadedAfterAspect.after38);
+      assertEquals("SubClass,Object,SuperValue", OverloadedAfterAspect.after39);
+      assertEquals("Object,MethodInfo", OverloadedAfterAspect.after40);
+      assertEquals("Object,JoinPointInfo", OverloadedAfterAspect.after41);
+      assertEquals("Object,SuperClass,float,SubValue", OverloadedAfterAspect.after42);
+      assertEquals("Object,SuperClass,float,SuperValue", OverloadedAfterAspect.after43);
+      assertEquals("Object,SuperClass,float,Object", OverloadedAfterAspect.after44);
+      assertEquals("SuperClass,SuperClass,float", OverloadedAfterAspect.after45);
+      assertEquals("Object,SuperClass,SubValue", OverloadedAfterAspect.after46);
+      assertEquals("Object,SuperClass,SuperValue", OverloadedAfterAspect.after47);
+      assertEquals("SuperClass,SuperClass,Object", OverloadedAfterAspect.after48);
+      assertEquals("Object,SuperClass", OverloadedAfterAspect.after49);
+      assertEquals("Object,Object", OverloadedAfterAspect.after50);
+      assertEquals("void,float,SubValue", OverloadedAfterAspect.after51);
+      assertEquals("Object,float", OverloadedAfterAspect.after52);
+      assertEquals("void,SubValue", OverloadedAfterAspect.after53);
+      assertEquals("void,SuperValue", OverloadedAfterAspect.after54);
+      assertEquals("void", OverloadedAfterAspect.after55);
+   }
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAfterAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAfterAspect.java	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAfterAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,10122 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import org.jboss.aop.JoinPointInfo;
+import org.jboss.aop.MethodInfo;
+import org.jboss.aop.advice.annotation.Arg;
+import org.jboss.aop.advice.annotation.JoinPoint;
+import org.jboss.aop.advice.annotation.Return;
+
+/**
+ * Aspect used on overloaded after advice tests.
+ *
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class OverloadedAfterAspect
+{
+   static String after1 = null;
+   static String after2 = null;
+   static String after3 = null;
+   static String after4 = null;
+   static String after5 = null;
+   static String after6 = null;
+   static String after7 = null;
+   static String after8 = null;
+   static String after9 = null;
+   static String after10 = null;
+   static String after11 = null;
+   static String after12 = null;
+   static String after13 = null;
+   static String after14 = null;
+   static String after15 = null;
+   static String after16 = null;
+   static String after17 = null;
+   static String after18 = null;
+   static String after19 = null;
+   static String after20 = null;
+   static String after21 = null;
+   static String after22 = null;
+   static String after23 = null;
+   static String after24 = null;
+   static String after25 = null;
+   static String after26 = null;
+   static String after27 = null;
+   static String after28 = null;
+   static String after29 = null;
+   static String after30 = null;
+   static String after31 = null;
+   static String after32 = null;
+   static String after33 = null;
+   static String after34 = null;
+   static String after35 = null;
+   static String after36 = null;
+   static String after37 = null;
+   static String after38 = null;
+   static String after39 = null;
+   static String after40 = null;
+   static String after41 = null;
+   static String after42 = null;
+   static String after43 = null;
+   static String after44 = null;
+   static String after45 = null;
+   static String after46 = null;
+   static String after47 = null;
+   static String after48 = null;
+   static String after49 = null;
+   static String after50 = null;
+   static String after51 = null;
+   static String after52 = null;
+   static String after53 = null;
+   static String after54 = null;
+   static String after55 = null;
+   static String after56 = null;
+   static String after57 = null;
+   static String after58 = null;
+   static String after59 = null;
+   static String after60 = null;
+
+   public static void clear()
+   {
+      after1 = null;
+      after2 = null;
+      after3 = null;
+      after4 = null;
+      after5 = null;
+      after6 = null;
+      after7 = null;
+      after8 = null;
+      after9 = null;
+      after10 = null;
+      after11 = null;
+      after12 = null;
+      after13 = null;
+      after14 = null;
+      after15 = null;
+      after16 = null;
+      after17 = null;
+      after18 = null;
+      after19 = null;
+      after20 = null;
+      after21 = null;
+      after22 = null;
+      after23 = null;
+      after24 = null;
+      after25 = null;
+      after26 = null;
+      after27 = null;
+      after28 = null;
+      after29 = null;
+      after30 = null;
+      after31 = null;
+      after32 = null;
+      after33 = null;
+      after34 = null;
+      after35 = null;
+      after36 = null;
+      after37 = null;
+      after38 = null;
+      after39 = null;
+      after40 = null;
+      after41 = null;
+      after42 = null;
+      after43 = null;
+      after44 = null;
+      after45 = null;
+      after46 = null;
+      after47 = null;
+      after48 = null;
+      after49 = null;
+      after50 = null;
+      after51 = null;
+      after52 = null;
+      after53 = null;
+      after54 = null;
+      after55 = null;
+      after56 = null;
+      after57 = null;
+      after58 = null;
+      after59 = null;
+      after60 = null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after1 = "Object,MethodInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after1 = "Object,MethodInfo,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg Object arg2)
+   {
+      after1 = "Object,MethodInfo,SuperClass,float,Object";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SubValue arg2)
+   {
+      after1 = "Object,MethodInfo,Object,float,SubValue";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after1 = "Object,MethodInfo,Object,float,SuperValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg Object arg2)
+   {
+      after1 = "Object,MethodInfo,Object,float,Object";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after1 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after1 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after1 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after1 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after1 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after1 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after1 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after1 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after1 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after1(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after1 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after1(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after1 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after1(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after1 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after1(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after1 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after1(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after1 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after1 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after1(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after1 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after1 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after1 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after1 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after1(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after1 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after1 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after1 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after1 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after1 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after1(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after1 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after1 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after1(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after1 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after1(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after1 = "SuperClass,JoinPointInfo,SuperValue,SubValue";
+      return null;
+   }
+   
+   public SubClass after1(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after1 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after1(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after1 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after1(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after1 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after1 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after1(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after1 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after1(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after1 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after1(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after1 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after1(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after1 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after1(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after1 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after1(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after1 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after1(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after1 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after1(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after1 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after1(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after1 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after1(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after1 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after1(@Return SuperClass valueReturned)
+   {
+      after1 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after1(@Return Object valueReturned)
+   {
+      after1 = "Object,Object";
+      return null;
+   }
+   
+   public void after1(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after1 = "void,float,SubValue";
+   }
+
+   public Object after1(@Arg float arg1)
+   {
+      after1 = "Object,float";
+      return null;
+   }
+   
+   public void after1(@Arg SubValue arg2)
+   {
+      after1 = "void,SubValue";
+   }
+   
+   public void after1(@Arg SuperValue arg2)
+   {
+      after1 = "void,SuperValue";
+   }
+   
+   public void after1()
+   {
+      after1 = "void";
+   }
+   
+   public void after1(@Arg int arg1)
+   {
+      after1 = "void,int";
+   }
+   
+   /* AFTER2 ADVICE */
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after2 = "Object,MethodInfo,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg Object arg2)
+   {
+      after2 = "Object,MethodInfo,SuperClass,float,Object";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SubValue arg2)
+   {
+      after2 = "Object,MethodInfo,Object,float,SubValue";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after2 = "Object,MethodInfo,Object,float,SuperValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg Object arg2)
+   {
+      after2 = "Object,MethodInfo,Object,float,Object";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after2 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after2 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after2 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after2 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after2 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after2 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after2 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after2 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after2 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after2(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after2 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after2(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after2 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after2(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after2 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after2(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after2 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after2(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after2 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after2 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after2(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after2 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after2 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after2 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after2 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after2(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after2 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after2 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after2 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after2 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after2 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after2 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after2(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after2 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after2(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after2 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after2(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after2 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after2(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after2 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after2(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after2 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after2 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after2(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after2 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after2(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after2 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after2(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after2 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after2(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after2 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after2(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after2 = "Object,MethodInfo,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after2(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after2 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after2(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after2 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after2(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after2 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after2(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after2 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after2(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after2 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after2(@Return SuperClass valueReturned)
+   {
+      after2 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after2(@Return Object valueReturned)
+   {
+      after2 = "Object,Object";
+      return null;
+   }
+   
+   public void after2(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after2 = "void,float,SubValue";
+   }
+
+   public Object after2(@Arg float arg1)
+   {
+      after2 = "Object,float";
+      return null;
+   }
+   
+   public void after2(@Arg SubValue arg2)
+   {
+      after2 = "void,SubValue";
+   }
+   
+   public void after2(@Arg SuperValue arg2)
+   {
+      after2 = "void,SuperValue";
+   }
+   
+   public void after2()
+   {
+      after2 = "void";
+   }
+   
+   public void after2(@Arg int arg1)
+   {
+      after2 = "void,int";
+   }
+   
+   /* AFTER3 ADVICE */
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg Object arg2)
+   {
+      after3 = "Object,MethodInfo,SuperClass,float,Object";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SubValue arg2)
+   {
+      after3 = "Object,MethodInfo,Object,float,SubValue";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after3 = "Object,MethodInfo,Object,float,SuperValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg Object arg2)
+   {
+      after3 = "Object,MethodInfo,Object,float,Object";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after3 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after3 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after3 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after3 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after3 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after3 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after3 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after3 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after3 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after3(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after3 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after3(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after3 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after3(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after3 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after3(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after3 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+   
+   public SubClass after3(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after3 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after3 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after3(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after3 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after3 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after3 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after3 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after3(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after3 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after3 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after3 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after3 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after3 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after3(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after3 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after3 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after3(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after3 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after3(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after3 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after3(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after3 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after3(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after3 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after3(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after3 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after3 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after3(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after3 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after3(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after3 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after3(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after3 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after3(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+    after3 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after3(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after3 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after3(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after3 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after3(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after3 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after3(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after3 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after3(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after3 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after3(@Return SuperClass valueReturned)
+   {
+      after3 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after3(@Return Object valueReturned)
+   {
+      after3 = "Object,Object";
+      return null;
+   }
+
+   public void after3(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after3 = "void,float,SubValue";
+   }
+
+   public Object after3(@Arg float arg1)
+   {
+      after3 = "Object,float";
+      return null;
+   }
+   
+   public void after3(@Arg SubValue arg2)
+   {
+      after3 = "void,SubValue";
+   }
+   
+   public void after3(@Arg SuperValue arg2)
+   {
+      after3 = "void,SuperValue";
+   }
+   
+   public void after3()
+   {
+      after3 = "void";
+   }
+   
+   public void after3(@Arg int arg1)
+   {
+      after3 = "void,int";
+   }
+   
+   /* AFTER4 ADVICE */
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SubValue arg2)
+   {
+      after4 = "Object,MethodInfo,Object,float,SubValue";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after4 = "Object,MethodInfo,Object,float,SuperValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg Object arg2)
+   {
+      after4 = "Object,MethodInfo,Object,float,Object";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after4 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after4 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after4 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after4 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after4 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after4 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after4 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after4 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after4 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after4(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after4 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after4(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after4 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after4(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after4 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after4(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after4 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after4(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after4 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after4 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after4(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after4 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after4 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after4 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after4 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after4(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after4 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after4 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after4 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after4 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after4 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after4(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after4 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after4 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after4(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after4 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after4(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after4 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after4(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after4 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after4(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after4 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after4(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after4 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after4 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after4(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after4 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after4(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after4 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after4(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after4 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after4(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after4 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after4(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after4 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after4(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after4 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after4(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after4 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after4(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after4 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after4(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after4 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after4(@Return SuperClass valueReturned)
+   {
+      after4 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after4(@Return Object valueReturned)
+   {
+      after4 = "Object,Object";
+      return null;
+   }
+
+   public void after4(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after4 = "void,float,SubValue";
+   }
+
+   public Object after4(@Arg float arg1)
+   {
+      after4 = "Object,float";
+      return null;
+   }
+   
+   public void after4(@Arg SubValue arg2)
+   {
+      after4 = "void,SubValue";
+   }
+   
+   public void after4(@Arg SuperValue arg2)
+   {
+      after4 = "void,SuperValue";
+   }
+   
+   public void after4()
+   {
+      after4 = "void";
+   }
+   
+   public void after4(@Arg int arg1)
+   {
+      after4 = "void,int";
+   }
+   
+   /* AFTER5 ADVICE */
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg SuperValue arg2)
+   {
+      after5 = "Object,MethodInfo,Object,float,SuperValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg Object arg2)
+   {
+      after5 = "Object,MethodInfo,Object,float,Object";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after5 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after5 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after5 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after5 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after5 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after5 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after5 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after5 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after5 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after5(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after5 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after5(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after5 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after5(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after5 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after5(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after5 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after5(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after5 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after5 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after5(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after5 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after5 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after5(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after5 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after5 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after5(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after5 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after5 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after5 = "Object,MethodInfo,float,SuperClass";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after5 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after5 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+   
+   public SuperClass after5(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after5 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after5 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after5(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after5 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after5(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after5 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after5(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after5 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after5(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after5 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after5(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after5 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after5 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after5(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after5 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after5(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after5 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after5(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after5 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after5(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after5 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after5(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after5 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after5(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after5 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after5(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after5 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after5(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after5 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after5(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after5 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after5(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after5 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after5(@Return SuperClass valueReturned)
+   {
+      after5 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after5(@Return Object valueReturned)
+   {
+      after5 = "Object,Object";
+      return null;
+   }
+
+   public void after5(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after5 = "void,float,SubValue";
+   }
+
+   public Object after5(@Arg float arg1)
+   {
+      after5 = "Object,float";
+      return null;
+   }
+   
+   public void after5(@Arg SubValue arg2)
+   {
+      after5 = "void,SubValue";
+   }
+   
+   public void after5(@Arg SuperValue arg2)
+   {
+      after5 = "void,SuperValue";
+   }
+   
+   public void after5()
+   {
+      after5 = "void";
+   }
+   
+   public void after5(@Arg int arg1)
+   {
+      after5 = "void,int";
+   }
+   
+   /* AFTER6 ADVICE */
+   
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1, @Arg Object arg2)
+   {
+      after6 = "Object,MethodInfo,Object,float,Object";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after6 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after6 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after6 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after6 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after6 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after6 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after6 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after6 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after6 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after6(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after6 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after6(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after6 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after6(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after6 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after6(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after6 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after6(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after6 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after6 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after6(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after6 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after6 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after6(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after6 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after6 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after6(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after6 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after6 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after6 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after6 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after6 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after6(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after6 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after6 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after6(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after6 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after6(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after6 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after6(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after6 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after6(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after6 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after6(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after6 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after6 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after6(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after6 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after6(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after6 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after6(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after6 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after6(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after6 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after6(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after6 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after6(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after6 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after6(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after6 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after6(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after6 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after6(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after6 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after6(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after6 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after6(@Return SuperClass valueReturned)
+   {
+      after6 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after6(@Return Object valueReturned)
+   {
+      after6 = "Object,Object";
+      return null;
+   }
+
+   public void after6(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after6 = "void,float,SubValue";
+   }
+
+   public Object after6(@Arg float arg1)
+   {
+      after6 = "Object,float";
+      return null;
+   }
+   
+   public void after6(@Arg SubValue arg2)
+   {
+      after6 = "void,SubValue";
+   }
+   
+   public void after6(@Arg SuperValue arg2)
+   {
+      after6 = "void,SuperValue";
+   }
+   
+   public void after6()
+   {
+      after6 = "void";
+   }
+   
+   public void after6(@Arg int arg1)
+   {
+      after6 = "void,int";
+   }
+   
+   /* AFTER7 ADVICE */
+   
+   public Object after7(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1, @Arg SubValue arg2)
+   {
+      after7 = "Object,JoinPointInfo,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after7 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after7 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after7 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after7 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after7 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after7 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after7 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after7 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after7(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after7 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after7(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after7 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after7(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after7 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after7(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after7 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after7(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after7 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after7 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after7(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after7 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after7 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after7(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after7 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after7 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after7(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after7 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after7 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after7 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after7 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after7 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after7(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after7 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after7 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after7(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after7 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after7(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after7 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after7(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after7 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after7(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after7 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after7(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after7 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after7 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after7(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after7 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after7(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after7 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after7(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after7 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after7(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after7 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after7(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after7 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after7(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after7 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after7(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after7 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after7(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after7 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after7(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after7 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after7(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after7 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after7(@Return SuperClass valueReturned)
+   {
+      after7 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after7(@Return Object valueReturned)
+   {
+      after7 = "Object,SuperClass";
+      return null;
+   }
+
+   public void after7(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after7 = "void,float,SubValue";
+   }
+
+   public Object after7(@Arg float arg1)
+   {
+      after7 = "Object,float";
+      return null;
+   }
+   
+   public void after7(@Arg SubValue arg2)
+   {
+      after7 = "void,SubValue";
+   }
+   
+   public void after7(@Arg SuperValue arg2)
+   {
+      after7 = "void,SuperValue";
+   }
+   
+   public void after7()
+   {
+      after7 = "void";
+   }
+   
+   public void after7(@Arg int arg1)
+   {
+      after7 = "void,int";
+   }
+   
+   /* AFTER8 ADVICE */
+   
+   public SuperClass after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after8 = "SuperClass,MethodInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after8 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after8 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after8 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after8 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after8 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after8 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after8 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after8(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after8 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after8(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after8 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after8(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after8 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after8(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after8 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after8(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after8 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after8 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after8(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after8 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after8 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after8(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after8 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after8 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after8(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after8 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after8 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after8 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after8 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after8 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after8(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after8 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after8 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after8(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after8 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after8(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after8 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after8(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after8 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after8(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after8 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after8(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after8 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after8 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after8(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after8 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after8(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after8 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after8(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after8 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after8(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after8 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after8(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after8 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after8(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after8 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after8(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after8 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after8(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after8 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after8(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after8 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after8(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after8 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after8(@Return SuperClass valueReturned)
+   {
+      after8 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after8(@Return Object valueReturned)
+   {
+      after7 = "Object,SuperClass";
+      return null;
+   }
+
+   public void after8(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after8 = "void,float,SubValue";
+   }
+
+   public Object after8(@Arg float arg1)
+   {
+      after8 = "Object,float";
+      return null;
+   }
+   
+   public void after8(@Arg SubValue arg2)
+   {
+      after8 = "void,SubValue";
+   }
+   
+   public void after8(@Arg SuperValue arg2)
+   {
+      after8 = "void,SuperValue";
+   }
+   
+   public void after8()
+   {
+      after8 = "void";
+   }
+   
+   public void after8(@Arg int arg1)
+   {
+      after8 = "void,int";
+   }
+   
+   /* AFTER9 ADVICE */
+   
+   public Object after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after9 = "Object,MethodInfo,SuperClass,float";
+      return null;
+   }
+
+   public Object after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after9 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after9 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after9 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after9 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after9 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after9 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after9(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after9 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after9(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after9 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after9(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after9 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after9(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after9 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after9(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after9 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after9 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after9(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after9 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after9 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after9(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after9 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after9 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after9(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after9 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after9 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after9 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after9 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after9 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after9(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after9 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after9 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after9(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after9 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after9(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after9 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after9(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after9 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after9(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after9 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after9(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after9 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after9 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after9(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after9 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after9(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after9 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after9(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after9 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after9(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after9 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after9(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after9 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after9(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after9 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after9(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after9 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after9(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after9 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after9(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after9 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after9(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after9 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after9(@Return SuperClass valueReturned)
+   {
+      after9 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after9(@Return Object valueReturned)
+   {
+      after9 = "Object,Object";
+      return null;
+   }
+
+   public void after9(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after9 = "void,float,SubValue";
+   }
+
+   public Object after9(@Arg float arg1)
+   {
+      after9 = "Object,float";
+      return null;
+   }
+   
+   public void after9(@Arg SubValue arg2)
+   {
+      after9 = "void,SubValue";
+   }
+   
+   public void after9(@Arg SuperValue arg2)
+   {
+      after9 = "void,SuperValue";
+   }
+   
+   public void after9()
+   {
+      after9 = "void";
+   }
+   
+   public void after9(@Arg int arg1)
+   {
+      after9 = "void,int";
+   }
+   
+   /* AFTER10 ADVICE */
+   
+   public Object after10(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after10 = "Object,MethodInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after10(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after10 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after10(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after10 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after10 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after10(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after10 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after10(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after10 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after10(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after10 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after10(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after10 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after10(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after10 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after10(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after10 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after10(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after10 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after10 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after10(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after10 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after10 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after10(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after10 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after10 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after10(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after10 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after10 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after10 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after10 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after10 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after10(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after10 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after10 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after10(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after10 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after10(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after10 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after10(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after10 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after10(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after10 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after10(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after10 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after10 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after10(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after10 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after10(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after10 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after10(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after10 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after10(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after10 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after10(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after10 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after10(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after10 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after10(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after10 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after10(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after10 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after10(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after10 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after10(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after10 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after10(@Return SuperClass valueReturned)
+   {
+      after10 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after10(@Return Object valueReturned)
+   {
+      after10 = "Object,Object";
+      return null;
+   }
+
+   public void after10(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after10 = "void,float,SubValue";
+   }
+
+   public Object after10(@Arg float arg1)
+   {
+      after10 = "Object,float";
+      return null;
+   }
+   
+   public void after10(@Arg SubValue arg2)
+   {
+      after10 = "void,SubValue";
+   }
+   
+   public void after10(@Arg SuperValue arg2)
+   {
+      after10 = "void,SuperValue";
+   }
+   
+   public void after10()
+   {
+      after10 = "void";
+   }
+   
+   public void after10(@Arg int arg1)
+   {
+      after10 = "void,int";
+   }
+   
+   /* AFTER11 ADVICE */
+   
+   public SuperClass after11(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after11 = "SuperClass,MethodInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SuperClass after11(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after11 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after11 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after11(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after11 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after11(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after11 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after11(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after11 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after11(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after11 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after11(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after11 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after11(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after11 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after11(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after11 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after11 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after11(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after11 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after11 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after11(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after11 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after11 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after11(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after11 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after11 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after11 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after11 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after11 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after11(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after11 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after11 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after11(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after11 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after11(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after11 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after11(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after11 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after11(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after11 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after11(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after11 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after11 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after11(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after11 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after11(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after11 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after11(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after11 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after11(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after11 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after11(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after11 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after11(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after11 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after11(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after11 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after11(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after11 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after11(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after11 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after11(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after11 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after11(@Return SuperClass valueReturned)
+   {
+      after11 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after11(@Return Object valueReturned)
+   {
+      after11 = "Object,Object";
+      return null;
+   }
+
+   public void after11(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after11 = "void,float,SubValue";
+   }
+
+   public Object after11(@Arg float arg1)
+   {
+      after11 = "Object,float";
+      return null;
+   }
+   
+   public void after11(@Arg SubValue arg2)
+   {
+      after11 = "void,SubValue";
+   }
+   
+   public void after11(@Arg SuperValue arg2)
+   {
+      after11 = "void,SuperValue";
+   }
+   
+   public void after11()
+   {
+      after11 = "void";
+   }
+   
+   public void after11(@Arg int arg1)
+   {
+      after11 = "void,int";
+   }
+   
+   /* AFTER12 ADVICE */
+ 
+   public SuperClass after12(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SubValue arg2)
+   {
+      after12 = "SuperClass,MethodInfo,Object,SubValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after12 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after12(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after12 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after12(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after12 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after12(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after12 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after12(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after12 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after12(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after12 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after12(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after12 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+   
+   public SubClass after12(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after12 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after12 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after12(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after12 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after12 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after12 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after12 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after12(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after12 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after12 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after12 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after12 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after12 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after12(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after12 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after12 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after12(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after12 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after12(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after12 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after12(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after12 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after12(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after12 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after12(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after12 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after12 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after12(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after12 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after12(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after12 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after12(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after12 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after12(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after12 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after12(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after12 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after12(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after12 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after12(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after12 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after12(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after12 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after12(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after12 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after12(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after12 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after12(@Return SuperClass valueReturned)
+   {
+      after12 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after12(@Return Object valueReturned)
+   {
+      after12 = "Object,Object";
+      return null;
+   }
+
+   public void after12(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after12 = "void,float,SubValue";
+   }
+
+   public Object after12(@Arg float arg1)
+   {
+      after12 = "Object,float";
+      return null;
+   }
+   
+   public void after12(@Arg SubValue arg2)
+   {
+      after12 = "void,SubValue";
+   }
+   
+   public void after12(@Arg SuperValue arg2)
+   {
+      after12 = "void,SuperValue";
+   }
+   
+   public void after12()
+   {
+      after12 = "void";
+   }
+   
+   public void after12(@Arg int arg1)
+   {
+      after12 = "void,int";
+   }
+   
+   /* AFTER13 ADVICE */
+   
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned,
+         @Arg float arg1)
+   {
+      after13 = "Object,MethodInfo,Object,float";
+      return null;
+   }
+
+   public SubClass after13(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after13 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after13(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after13 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after13(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after13 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after13(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after13 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after13(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after13 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after13(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after13 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after13(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after13 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after13 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after13(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after13 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after13 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after13(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after13 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after13 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after13(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after13 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after13 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after13 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after13 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after13 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after13(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after13 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after13 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after13(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after13 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after13(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after13 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after13(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after13 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after13(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after13 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after13(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after13 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after13 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after13(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after13 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after13(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after13 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after13(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after13 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after13(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after13 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after13(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after13 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after13(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after13 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after13(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after13 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after13(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after13 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after13(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after13 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after13(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after13 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after13(@Return SuperClass valueReturned)
+   {
+      after13 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after13(@Return Object valueReturned)
+   {
+      after13 = "Object,Object";
+      return null;
+   }
+
+   public void after13(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after13 = "void,float,SubValue";
+   }
+
+   public Object after13(@Arg float arg1)
+   {
+      after13 = "Object,float";
+      return null;
+   }
+   
+   public void after13(@Arg SubValue arg2)
+   {
+      after13 = "void,SubValue";
+   }
+   
+   public void after13(@Arg SuperValue arg2)
+   {
+      after13 = "void,SuperValue";
+   }
+   
+   public void after13()
+   {
+      after13 = "void";
+   }
+   
+   public void after13(@Arg int arg1)
+   {
+      after13 = "void,int";
+   }
+   
+   /* AFTER14 ADVICE */
+   
+   public SubClass after14(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg SuperValue arg2)
+   {
+      after14 = "SubClass,MethodInfo,Object,SuperValue";
+      return null;
+   }
+   
+   public SubClass after14(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after14 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after14(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after14 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after14(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after14 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after14(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after14 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after14(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after14 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after14(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after14 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after14 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after14(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after14 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after14 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after14(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after14 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after14(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after14 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after14(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after14 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after14(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after14 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after14(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after14 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after14 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after14 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after14(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after14 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after14 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after14(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after14 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after14(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after14 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after14(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after14 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after14(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after14 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after14(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after14 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after14 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after14(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after14 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after14(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after14 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after14(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after14 = "Object,JoinPointInfo";
+      return null;
+   }
+      
+   public Object after14(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after14 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after14(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after14 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after14(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after14 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after14(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after14 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after14(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after14 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after14(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after14 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after14(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after14 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after14(@Return SuperClass valueReturned)
+   {
+      after14 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after14(@Return Object valueReturned)
+   {
+      after14 = "Object,Object";
+      return null;
+   }
+
+   public void after14(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after14 = "void,float,SubValue";
+   }
+
+   public Object after14(@Arg float arg1)
+   {
+      after14 = "Object,float";
+      return null;
+   }
+   
+   public void after14(@Arg SubValue arg2)
+   {
+      after14 = "void,SubValue";
+   }
+   
+   public void after14(@Arg SuperValue arg2)
+   {
+      after14 = "void,SuperValue";
+   }
+   
+   public void after14()
+   {
+      after14 = "void";
+   }
+   
+   public void after14(@Arg int arg1)
+   {
+      after14 = "void,int";
+   }
+   
+   /* AFTER15 ADVICE */
+   
+   public SubClass after15(@JoinPoint MethodInfo joinPointInfo,
+         @Return Object valueReturned, @Arg Object arg2)
+   {
+      after15 = "SubClass,MethodInfo,Object,Object";
+      return null;
+   }
+   
+   public SuperClass after15(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after15 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after15(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after15 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after15(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after15 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after15(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after15 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after15(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after15 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after15 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after15(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after15 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after15 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after15(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after15 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after15(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after15 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after15(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after15 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after15(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after15 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after15(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after15 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after15 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after15 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after15(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after15 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after15 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after15(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after15 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after15(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after15 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after15(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after15 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after15(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after15 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after15(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after15 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after15 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after15(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after15 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after15(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after15 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after15(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after15 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after15(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after15 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after15(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after15 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after15(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after15 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after15(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after15 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after15(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after15 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after15(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after15 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after15(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after15 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after15(@Return SuperClass valueReturned)
+   {
+      after15 = "Object,SuperClass";
+      return null;
+   }
+
+   public Object after15(@Return Object valueReturned)
+   {
+      after15 = "Object,Object";
+      return null;
+   }
+
+   public void after15(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after15 = "void,float,SubValue";
+   }
+
+   public Object after15(@Arg float arg1)
+   {
+      after15 = "Object,float";
+      return null;
+   }
+   
+   public void after15(@Arg SubValue arg2)
+   {
+      after15 = "void,SubValue";
+   }
+   
+   public void after15(@Arg SuperValue arg2)
+   {
+      after15 = "void,SuperValue";
+   }
+   
+   public void after15()
+   {
+      after15 = "void";
+   }
+   
+   public void after15(@Arg int arg1)
+   {
+      after15 = "void,int";
+   }
+   
+   /* AFTER16 ADVICE */
+
+   public SuperClass after16(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after16 = "SuperClass,JoinPointInfo,SuperClass,SubValue";
+      return null;
+   }
+   
+   public SubClass after16(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after16 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after16(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after16 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after16(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after16 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after16(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after16 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after16 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after16(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after16 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after16 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after16(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after16 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after16(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after16 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after16(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after16 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after16(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after16 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after16(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after16 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after16 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after16 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after16(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after16 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after16 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after16(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after16 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after16(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after16 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after16(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after16 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after16(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after16 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after16(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after16 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after16 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after16(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after16 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after16(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after16 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after16(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after16 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after16(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after16 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after16(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after16 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after16(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after16 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after16(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after16 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after16(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after16 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after16(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after16 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after16(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after16 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after16(@Return SuperClass valueReturned)
+   {
+      after16 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after16(@Return Object valueReturned)
+   {
+      after16 = "Object,Object";
+      return null;
+   }
+   
+   public void after16(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after16 = "void,float,SubValue";
+   }
+
+   public Object after16(@Arg float arg1)
+   {
+      after16 = "Object,float";
+      return null;
+   }
+   
+   public void after16(@Arg SubValue arg2)
+   {
+      after16 = "void,SubValue";
+   }
+   
+   public void after16(@Arg SuperValue arg2)
+   {
+      after16 = "void,SuperValue";
+   }
+   
+   public void after16()
+   {
+      after16 = "void";
+   }
+   
+   public void after16(@Arg int arg1)
+   {
+      after16 = "void,int";
+   }
+   
+   /* AFTER17 ADVICE */
+
+   public SubClass after17(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after17 = "SubClass,JoinPointInfo,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after17(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after17 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after17(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after17 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after17(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after17 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after17 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after17(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after17 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after17 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after17 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after17(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after17 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after17(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after17 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after17(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after17 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after17(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after17 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after17 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after17 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after17(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after17 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after17 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after17(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after17 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after17(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after17 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after17(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after17 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after17(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after17 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after17(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after17 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after17 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after17(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after17 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after17(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after17 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after17(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after17 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after17(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after17 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after17(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after17 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after17(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after17 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after17(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after17 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after17(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after17 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after17(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after17 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after17(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after17 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after17(@Return SuperClass valueReturned)
+   {
+      after17 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after17(@Return Object valueReturned)
+   {
+      after17 = "Object,Object";
+      return null;
+   }
+   
+   public void after17(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after17 = "void,float,SubValue";
+   }
+
+   public Object after17(@Arg float arg1)
+   {
+      after17 = "Object,float";
+      return null;
+   }
+   
+   public void after17(@Arg SubValue arg2)
+   {
+      after17 = "void,SubValue";
+   }
+   
+   public void after17(@Arg SuperValue arg2)
+   {
+      after17 = "void,SuperValue";
+   }
+   
+   public void after17()
+   {
+      after17 = "void";
+   }
+   
+   public void after17(@Arg int arg1)
+   {
+      after17 = "void,int";
+   }
+   
+   /* AFTER18 ADVICE */
+   
+   public SubClass after18(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after18 = "SubClass,JoinPointInfo,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after18(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after18 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after18(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after18 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after18 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after18(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after18 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after18 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after18(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after18 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after18(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after18 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after18(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after18 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after18(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after18 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after18(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after18 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after18 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after18 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after18(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after18 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after18 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after18(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after18 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after18(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after18 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after18(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after18 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after18(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after18 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after18(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after18 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after18 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after18(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after18 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after18(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after18 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after18(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after18 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after18(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after18 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after18(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after18 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after18(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after18 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after18(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after18 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after18(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after18 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after18(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after18 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after18(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after18 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after18(@Return SuperClass valueReturned)
+   {
+      after18 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after18(@Return Object valueReturned)
+   {
+      after18 = "Object,Object";
+      return null;
+   }
+   
+   public void after18(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after18 = "void,float,SubValue";
+   }
+
+   public Object after18(@Arg float arg1)
+   {
+      after18 = "Object,float";
+      return null;
+   }
+   
+   public void after18(@Arg SubValue arg2)
+   {
+      after18 = "void,SubValue";
+   }
+   
+   public void after18(@Arg SuperValue arg2)
+   {
+      after18 = "void,SuperValue";
+   }
+   
+   public void after18()
+   {
+      after18 = "void";
+   }
+   
+   public void after18(@Arg int arg1)
+   {
+      after18 = "void,int";
+   }
+   
+   /* AFTER19 ADVICE */
+   
+   public SuperClass after19(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after19 = "SuperClass,JoinPointInfo,SuperClass,Object";
+      return null;
+   }
+
+   public SubClass after19(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after19 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after19 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after19(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after19 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after19 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after19(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after19 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after19(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after19 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after19(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after19 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after19(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after19 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after19(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after19 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after19 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after19 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after19(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after19 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after19 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after19(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after19 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after19(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after19 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after19(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after19 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after19(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after19 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after19(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after19 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after19 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after19(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after19 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after19(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after19 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after19(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after19 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after19(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after19 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after19(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after19 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after19(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after19 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after19(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after19 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after19(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after19 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after19(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after19 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after19(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after19 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after19(@Return SuperClass valueReturned)
+   {
+      after19 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after19(@Return Object valueReturned)
+   {
+      after19 = "Object,Object";
+      return null;
+   }
+   
+   public void after19(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after19 = "void,float,SubValue";
+   }
+
+   public Object after19(@Arg float arg1)
+   {
+      after19 = "Object,float";
+      return null;
+   }
+   
+   public void after19(@Arg SubValue arg2)
+   {
+      after19 = "void,SubValue";
+   }
+   
+   public void after19(@Arg SuperValue arg2)
+   {
+      after19 = "void,SuperValue";
+   }
+   
+   public void after19()
+   {
+      after19 = "void";
+   }
+   
+   public void after19(@Arg int arg1)
+   {
+      after19 = "void,int";
+   }
+   
+   /* AFTER20 ADVICE */
+
+   public SubClass after20(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after20 = "SubClass,Object,SuperClass,SubValue";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after20 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after20(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after20 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after20 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after20(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after20 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after20(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after20 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after20(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after20 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after20(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after20 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after20(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after20 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after20 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after20 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after20(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after20 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after20 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after20(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after20 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after20(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after20 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after20(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after20 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after20(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after20 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after20(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after20 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after20 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after20(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after20 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after20(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after20 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after20(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after20 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after20(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after20 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after20(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after20 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after20(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after20 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after20(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after20 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after20(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after20 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after20(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after20 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after20(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after20 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after20(@Return SuperClass valueReturned)
+   {
+      after20 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after20(@Return Object valueReturned)
+   {
+      after20 = "Object,Object";
+      return null;
+   }
+   
+   public void after20(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after20 = "void,float,SubValue";
+   }
+
+   public Object after20(@Arg float arg1)
+   {
+      after20 = "Object,float";
+      return null;
+   }
+   
+   public void after20(@Arg SubValue arg2)
+   {
+      after20 = "void,SubValue";
+   }
+   
+   public void after20(@Arg SuperValue arg2)
+   {
+      after20 = "void,SuperValue";
+   }
+   
+   public void after20()
+   {
+      after20 = "void";
+   }
+   
+   public void after20(@Arg int arg1)
+   {
+      after20 = "void,int";
+   }
+   
+   /* AFTER21 ADVICE */
+   
+   public Object after21(@JoinPoint Object joinPointInfo, @Return SuperClass valueReturned,
+         @Arg float arg1)
+   {
+      after21 = "Object,Object,SuperClass,float";
+      return null;
+   }
+
+   public SubClass after21(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after21 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after21(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after21 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after21(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after21 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after21(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after21 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after21(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after21 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after21(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after21 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after21(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after21 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after21(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after21 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after21(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after21 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after21(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after21 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after21(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after21 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after21(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after21 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after21(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after21 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after21(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after21 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after21(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after21 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after21(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after21 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after21(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after21 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after21(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after21 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after21(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after21 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after21(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after21 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after21(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after21 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after21(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after21 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after21(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after21 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after21(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after21 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after21(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after21 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after21(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after21 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after21(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after21 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after21(@Return SuperClass valueReturned)
+   {
+      after21 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after21(@Return Object valueReturned)
+   {
+      after21 = "Object,Object";
+      return null;
+   }
+   
+   public void after21(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after21 = "void,float,SubValue";
+   }
+
+   public Object after21(@Arg float arg1)
+   {
+      after21 = "Object,float";
+      return null;
+   }
+   
+   public void after21(@Arg SubValue arg2)
+   {
+      after21 = "void,SubValue";
+   }
+   
+   public void after21(@Arg SuperValue arg2)
+   {
+      after21 = "void,SuperValue";
+   }
+   
+   public void after21()
+   {
+      after21 = "void";
+   }
+   
+   public void after21(@Arg int arg1)
+   {
+      after21 = "void,int";
+   }
+   
+   /* AFTER22 ADVICE */
+   
+   public SubClass after22(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after22 = "SubClass,Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public Object after22(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after22 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after22(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after22 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after22(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after22 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after22(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after22 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after22(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after22 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after22(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after22 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after22(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after22 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after22(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after22 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after22(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after22 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after22(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after22 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after22(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after22 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after22(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after22 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after22(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after22 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after22(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after22 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after22(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after22 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after22(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after22 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after22(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after22 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after22(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after22 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after22(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after22 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after22(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after22 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after22(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after22 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after22(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after22 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after22(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after22 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after22(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after22 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after22(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after22 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after22(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after22 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after22(@Return SuperClass valueReturned)
+   {
+      after22 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after22(@Return Object valueReturned)
+   {
+      after22 = "Object,Object";
+      return null;
+   }
+   
+   public void after22(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after22 = "void,float,SubValue";
+   }
+
+   public Object after22(@Arg float arg1)
+   {
+      after22 = "Object,float";
+      return null;
+   }
+   
+   public void after22(@Arg SubValue arg2)
+   {
+      after22 = "void,SubValue";
+   }
+   
+   public void after22(@Arg SuperValue arg2)
+   {
+      after22 = "void,SuperValue";
+   }
+   
+   public void after22()
+   {
+      after22 = "void";
+   }
+   
+   public void after22(@Arg int arg1)
+   {
+      after22 = "void,int";
+   }
+   
+   /* AFTER23 ADVICE */
+   
+   public Object after23(@JoinPoint Object joinPointInfo,
+         @Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after23 = "Object,Object,SuperClass,Object";
+      return null;
+   }
+
+   public Object after23(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after23 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after23(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after23 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after23(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after23 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after23(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after23 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after23(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after23 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after23(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after23 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after23(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after23 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after23(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after23 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after23(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after23 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after23(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after23 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after23(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after23 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after23(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after23 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after23(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after23 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after23(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after23 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after23(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after23 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after23(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after23 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after23(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after23 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after23(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after23 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after23(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after23 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after23(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after23 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after23(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after23 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after23(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after23 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after23(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after23 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after23(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after23 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after23(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after23 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after23(@Return SuperClass valueReturned)
+   {
+      after23 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after23(@Return Object valueReturned)
+   {
+      after23 = "Object,Object";
+      return null;
+   }
+   
+   public void after23(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after23 = "void,float,SubValue";
+   }
+
+   public Object after23(@Arg float arg1)
+   {
+      after23 = "Object,float";
+      return null;
+   }
+   
+   public void after23(@Arg SubValue arg2)
+   {
+      after23 = "void,SubValue";
+   }
+   
+   public void after23(@Arg SuperValue arg2)
+   {
+      after23 = "void,SuperValue";
+   }
+   
+   public void after23()
+   {
+      after23 = "void";
+   }
+   
+   public void after23(@Arg int arg1)
+   {
+      after23 = "void,int";
+   }
+   
+   /* AFTER24 ADVICE */
+   
+   public Object after24(@JoinPoint MethodInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after24 = "Object,MethodInfo,SuperClass";
+      return null;
+   }
+
+   public Object after24(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after24 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after24(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after24 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after24(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after24 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after24(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after24 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after24(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after24 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after24(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after24 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after24(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after24 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after24(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after24 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after24(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after24 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after24(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after24 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after24(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after24 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after24(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after24 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after24(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after24 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after24(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after24 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after24(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after24 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after24(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after24 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after24(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after24 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after24(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after24 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after24(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after24 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after24(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after24 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after24(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after24 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after24(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after24 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after24(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after24 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after24(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after24 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after24(@Return SuperClass valueReturned)
+   {
+      after24 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after24(@Return Object valueReturned)
+   {
+      after24 = "Object,Object";
+      return null;
+   }
+   
+   public void after24(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after24 = "void,float,SubValue";
+   }
+
+   public Object after24(@Arg float arg1)
+   {
+      after24 = "Object,float";
+      return null;
+   }
+   
+   public void after24(@Arg SubValue arg2)
+   {
+      after24 = "void,SubValue";
+   }
+   
+   public void after24(@Arg SuperValue arg2)
+   {
+      after24 = "void,SuperValue";
+   }
+   
+   public void after24()
+   {
+      after24 = "void";
+   }
+   
+   public void after24(@Arg int arg1)
+   {
+      after24 = "void,int";
+   }
+   
+   /* AFTER25 ADVICE */
+   
+   public Object after25(@JoinPoint MethodInfo joinPointInfo, @Return Object valueReturned)
+   {
+      after25 = "Object,MethodInfo,Object";
+      return null;
+   }
+
+   public Object after25(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after25 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after25(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after25 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after25(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after25 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after25(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after25 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after25(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after25 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after25(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after25 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after25(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after25 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after25(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after25 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after25(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after25 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after25(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after25 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after25(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after25 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after25(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after25 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after25(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after25 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after25(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after25 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after25(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after25 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after25(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after25 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after25(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after25 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after25(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after25 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after25(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after25 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after25(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after25 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after25(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after25 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after25(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after25 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after25(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after25 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after25(@Return SuperClass valueReturned)
+   {
+      after25 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after25(@Return Object valueReturned)
+   {
+      after25 = "Object,Object";
+      return null;
+   }
+   
+   public void after25(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after25 = "void,float,SubValue";
+   }
+
+   public Object after25(@Arg float arg1)
+   {
+      after25 = "Object,float";
+      return null;
+   }
+   
+   public void after25(@Arg SubValue arg2)
+   {
+      after25 = "void,SubValue";
+   }
+   
+   public void after25(@Arg SuperValue arg2)
+   {
+      after25 = "void,SuperValue";
+   }
+   
+   public void after25()
+   {
+      after25 = "void";
+   }
+   
+   public void after25(@Arg int arg1)
+   {
+      after25 = "void,int";
+   }
+   
+   /* AFTER26 ADVICE */
+   
+   public Object after26(@JoinPoint JoinPointInfo joinPointInfo,
+         @Return SuperClass valueReturned)
+   {
+      after26 = "Object,JoinPointInfo,SuperClass";
+      return null;
+   }
+
+   public Object after26(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after26 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after26(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after26 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after26(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after26 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after26(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after26 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after26(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after26 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after26(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after26 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after26(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after26 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after26(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after26 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after26(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after26 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after26(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after26 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after26(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after26 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after26(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after26 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after26(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after26 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after26(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after26 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after26(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after26 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after26(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after26 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after26(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after26 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after26(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after26 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after26(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after26 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after26(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after26 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after26(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after26 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after26(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after26 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after26(@Return SuperClass valueReturned)
+   {
+      after26 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after26(@Return Object valueReturned)
+   {
+      after26 = "Object,Object";
+      return null;
+   }
+   
+   public void after26(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after26 = "void,float,SubValue";
+   }
+
+   public Object after26(@Arg float arg1)
+   {
+      after26 = "Object,float";
+      return null;
+   }
+   
+   public void after26(@Arg SubValue arg2)
+   {
+      after26 = "void,SubValue";
+   }
+   
+   public void after26(@Arg SuperValue arg2)
+   {
+      after26 = "void,SuperValue";
+   }
+   
+   public void after26()
+   {
+      after26 = "void";
+   }
+   
+   public void after26(@Arg int arg1)
+   {
+      after26 = "void,int";
+   }
+   
+   /* AFTER27 ADVICE */
+      
+   public Object after27(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after27 = "Object,MethodInfo,float,SubValue";
+      return null;
+   }
+
+   public Object after27(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after27 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after27(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after27 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after27(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after27 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after27(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after27 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after27(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after27 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after27(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after27 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after27(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after27 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after27(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after27 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after27(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after27 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after27(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after27 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after27(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after27 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after27(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after27 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after27(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after27 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after27(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after27 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after27(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after27 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after27(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after27 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after27(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after27 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after27(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after27 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after27(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after27 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after27(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after27 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after27(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after27 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after27(@Return SuperClass valueReturned)
+   {
+      after27 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after27(@Return Object valueReturned)
+   {
+      after27 = "Object,Object";
+      return null;
+   }
+   
+   public void after27(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after27 = "void,float,SubValue";
+   }
+
+   public Object after27(@Arg float arg1)
+   {
+      after27 = "Object,float";
+      return null;
+   }
+   
+   public void after27(@Arg SubValue arg2)
+   {
+      after27 = "void,SubValue";
+   }
+   
+   public void after27(@Arg SuperValue arg2)
+   {
+      after27 = "void,SuperValue";
+   }
+   
+   public void after27()
+   {
+      after27 = "void";
+   }
+   
+   public void after27(@Arg int arg1)
+   {
+      after27 = "void,int";
+   }
+   
+   /* AFTER28 ADVICE */
+   
+   public Object after28(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after28 = "Object,MethodInfo,float,SuperValue";
+      return null;
+   }
+   
+   public Object after28(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after28 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after28(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after28 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+   
+   public SuperClass after28(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after28 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after28(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after28 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after28(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after28 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after28(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after28 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after28(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after28 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after28(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after28 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after28(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after28 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after28(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after28 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after28(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after28 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after28(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after28 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after28(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after28 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after28(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after28 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after28(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after28 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after28(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after28 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after28(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after28 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after28(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after28 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after28(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after28 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after28(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after28 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after28(@Return SuperClass valueReturned)
+   {
+      after28 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after28(@Return Object valueReturned)
+   {
+      after28 = "Object,SuperClass";
+      return null;
+   }
+   
+   public void after28(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after28 = "void,float,SubValue";
+   }
+
+   public Object after28(@Arg float arg1)
+   {
+      after28 = "Object,float";
+      return null;
+   }
+   
+   public void after28(@Arg SubValue arg2)
+   {
+      after28 = "void,SubValue";
+   }
+   
+   public void after28(@Arg SuperValue arg2)
+   {
+      after28 = "void,SuperValue";
+   }
+   
+   public void after28()
+   {
+      after28 = "void";
+   }
+   
+   public void after28(@Arg int arg1)
+   {
+      after28 = "void,int";
+   }
+   
+   /* AFTER29 ADVICE */
+   
+   public Object after29(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after29 = "Object,MethodInfo,float,Object";
+      return null;
+   }
+   
+   public Object after29(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after29 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after29(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after29 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after29(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after29 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after29(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after29 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after29(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after29 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after29(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after29 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after29(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after29 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after29(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after29 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after29(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after29 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after29(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after29 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after29(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after29 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after29(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after29 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after29(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after29 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after29(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after29 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after29(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after29 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after29(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after29 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after29(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after29 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after29(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after29 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after29(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after29 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after29(@Return SuperClass valueReturned)
+   {
+      after29 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after29(@Return Object valueReturned)
+   {
+      after29 = "Object,Object";
+      return null;
+   }
+   
+   public void after29(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after29 = "void,float,SubValue";
+   }
+
+   public Object after29(@Arg float arg1)
+   {
+      after29 = "Object,float";
+      return null;
+   }
+   
+   public void after29(@Arg SubValue arg2)
+   {
+      after29 = "void,SubValue";
+   }
+   
+   public void after29(@Arg SuperValue arg2)
+   {
+      after29 = "void,SuperValue";
+   }
+   
+   public void after29()
+   {
+      after29 = "void";
+   }
+   
+   public void after29(@Arg int arg1)
+   {
+      after29 = "void,int";
+   }
+   
+   /* AFTER30 ADVICE */
+   
+   public Object after30(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after30 = "Object,JoinPointInfo,float,SubValue";
+      return null;
+   }
+
+   public SuperClass after30(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after30 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after30(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after30 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after30(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after30 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after30(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after30 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after30(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after30 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after30(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after30 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after30(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after30 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after30(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after30 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after30(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after30 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after30(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after30 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after30(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after30 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after30(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after30 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after30(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after30 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after30(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after30 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after30(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after30 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after30(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after30 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after30(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after30 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after30(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after30 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after30(@Return SuperClass valueReturned)
+   {
+      after30 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after30(@Return Object valueReturned)
+   {
+      after30 = "Object,Object";
+      return null;
+   }
+   
+   public void after30(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after30 = "void,float,SubValue";
+   }
+
+   public Object after30(@Arg float arg1)
+   {
+      after30 = "Object,float";
+      return null;
+   }
+   
+   public void after30(@Arg SubValue arg2)
+   {
+      after30 = "void,SubValue";
+   }
+   
+   public void after30(@Arg SuperValue arg2)
+   {
+      after30 = "void,SuperValue";
+   }
+   
+   public void after30()
+   {
+      after30 = "void";
+   }
+   
+   public void after30(@Arg int arg1)
+   {
+      after30 = "void,int";
+   }
+   
+   /* AFTER31 ADVICE */
+   
+   public SuperClass after31(@JoinPoint MethodInfo joinPointInfo, @Arg SubValue arg2)
+   {
+      after31 = "SuperClass,MethodInfo,SubValue";
+      return null;
+   }
+   
+   public Object after31(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after31 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after31(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after31 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after31(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after31 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after31(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after31 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after31(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after31 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after31(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after31 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after31(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after31 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after31(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after31 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after31(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after31 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after31(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after31 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after31(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after31 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after31(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after31 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after31(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after31 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after31(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after31 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after31(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after31 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after31(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after31 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after31(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after31 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after31(@Return SuperClass valueReturned)
+   {
+      after31 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after31(@Return Object valueReturned)
+   {
+      after31 = "Object,Object";
+      return null;
+   }
+   
+   public void after31(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after31 = "void,float,SubValue";
+   }
+
+   public Object after31(@Arg float arg1)
+   {
+      after31 = "Object,float";
+      return null;
+   }
+   
+   public void after31(@Arg SubValue arg2)
+   {
+      after31 = "void,SubValue";
+   }
+   
+   public void after31(@Arg SuperValue arg2)
+   {
+      after31 = "void,SuperValue";
+   }
+   
+   public void after31()
+   {
+      after31 = "void";
+   }
+   
+   public void after31(@Arg int arg1)
+   {
+      after31 = "void,int";
+   }
+   
+   /* AFTER32 ADVICE */
+   
+   public Object after32(@JoinPoint MethodInfo joinPointInfo, @Arg float arg1)
+   {
+      after32 = "Object,MethodInfo,float";
+      return null;
+   }
+
+   public Object after32(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after32 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after32(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after32 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after32(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after32 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after32(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after32 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after32(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after32 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after32(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after32 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after32(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after32 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after32(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after32 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after32(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after32 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after32(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after32 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after32(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after32 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after32(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after32 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after32(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after32 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after32(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after32 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after32(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after32 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after32(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after32 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after32(@Return SuperClass valueReturned)
+   {
+      after32 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after32(@Return Object valueReturned)
+   {
+      after32 = "Object,Object";
+      return null;
+   }
+   
+   public void after32(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after32 = "void,float,SubValue";
+   }
+
+   public Object after32(@Arg float arg1)
+   {
+      after32 = "Object,float";
+      return null;
+   }
+   
+   public void after32(@Arg SubValue arg2)
+   {
+      after32 = "void,SubValue";
+   }
+   
+   public void after32(@Arg SuperValue arg2)
+   {
+      after32 = "void,SuperValue";
+   }
+   
+   public void after32()
+   {
+      after32 = "void";
+   }
+   
+   public void after32(@Arg int arg1)
+   {
+      after32 = "void,int";
+   }
+   
+   /* AFTER33 ADVICE */
+
+   public Object after33(@JoinPoint MethodInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after33 = "Object,MethodInfo,SuperValue";
+      return null;
+   }
+      
+   public SuperClass after33(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after33 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after33(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after33 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after33(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after33 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after33(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after33 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after33(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after33 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after33(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after33 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after33(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after33 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after33(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after33 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after33(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after33 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after33(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after33 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after33(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after33 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after33(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after33 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after33(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after33 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after33(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after33 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after33(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after33 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after33(@Return SuperClass valueReturned)
+   {
+      after33 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after33(@Return Object valueReturned)
+   {
+      after33 = "Object,Object";
+      return null;
+   }
+   
+   public void after33(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after33 = "void,float,SubValue";
+   }
+
+   public Object after33(@Arg float arg1)
+   {
+      after33 = "Object,float";
+      return null;
+   }
+   
+   public void after33(@Arg SubValue arg2)
+   {
+      after33 = "void,SubValue";
+   }
+   
+   public void after33(@Arg SuperValue arg2)
+   {
+      after33 = "void,SuperValue";
+   }
+   
+   public void after33()
+   {
+      after33 = "void";
+   }
+   
+   public void after33(@Arg int arg1)
+   {
+      after33 = "void,int";
+   }
+   
+   /* AFTER34 ADVICE */
+   
+   public SuperClass after34(@JoinPoint JoinPointInfo joinPointInfo, at Arg SubValue arg2)
+   {
+      after34 = "SuperClass,JoinPointInfo,SubValue";
+      return null;
+   }
+   
+   public SubClass after34(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after34 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after34(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after34 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after34(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after34 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after34(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after34 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after34(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after34 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after34(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after34 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after34(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after34 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after34(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after34 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after34(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after34 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after34(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after34 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after34(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after34 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after34(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after34 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after34(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after34 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after34(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after34 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after34(@Return SuperClass valueReturned)
+   {
+      after34 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after34(@Return Object valueReturned)
+   {
+      after34 = "Object,Object";
+      return null;
+   }
+   
+   public void after34(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after34 = "void,float,SubValue";
+   }
+
+   public Object after34(@Arg float arg1)
+   {
+      after34 = "Object,float";
+      return null;
+   }
+   
+   public void after34(@Arg SubValue arg2)
+   {
+      after34 = "void,SubValue";
+   }
+   
+   public void after34(@Arg SuperValue arg2)
+   {
+      after34 = "void,SuperValue";
+   }
+   
+   public void after34()
+   {
+      after34 = "void";
+   }
+   
+   public void after34(@Arg int arg1)
+   {
+      after34 = "void,int";
+   }
+   
+   /* AFTER35 ADVICE */
+   
+   public SubClass after35(@JoinPoint JoinPointInfo joinPointInfo, @Arg float arg1)
+   {
+      after35 = "SubClass,JoinPointInfo,float";
+      return null;
+   }
+
+   public SuperClass after35(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after35 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after35(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after35 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after35(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after35 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after35(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after35 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after35(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after35 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after35(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after35 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after35(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after35 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after35(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after35 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after35(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after35 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after35(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after35 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after35(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after35 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after35(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after35 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after35(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after35 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after35(@Return SuperClass valueReturned)
+   {
+      after35 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after35(@Return Object valueReturned)
+   {
+      after35 = "Object,Object";
+      return null;
+   }
+   
+   public void after35(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after35 = "void,float,SubValue";
+   }
+
+   public Object after35(@Arg float arg1)
+   {
+      after35 = "Object,float";
+      return null;
+   }
+   
+   public void after35(@Arg SubValue arg2)
+   {
+      after35 = "void,SubValue";
+   }
+   
+   public void after35(@Arg SuperValue arg2)
+   {
+      after35 = "void,SuperValue";
+   }
+   
+   public void after35()
+   {
+      after35 = "void";
+   }
+   
+   public void after35(@Arg int arg1)
+   {
+      after35 = "void,int";
+   }
+   
+   /* AFTER36 ADVICE */
+   
+   public SuperClass after36(@JoinPoint JoinPointInfo joinPointInfo, @Arg SuperValue arg2)
+   {
+      after36 = "SubClass,JoinPointInfo,SuperValue";
+      return null;
+   }
+   
+   public SubClass after36(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after36 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after36(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after36 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after36(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after36 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after36(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after36 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after36(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after36 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after36(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after36 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after36(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after36 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after36(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after36 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after36(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after36 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after36(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after36 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after36(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after36 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after36(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after36 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after36(@Return SuperClass valueReturned)
+   {
+      after36 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after36(@Return Object valueReturned)
+   {
+      after36 = "Object,Object";
+      return null;
+   }
+   
+   public void after36(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after36 = "void,float,SubValue";
+   }
+
+   public Object after36(@Arg float arg1)
+   {
+      after36 = "Object,float";
+      return null;
+   }
+   
+   public void after36(@Arg SubValue arg2)
+   {
+      after36 = "void,SubValue";
+   }
+   
+   public void after36(@Arg SuperValue arg2)
+   {
+      after36 = "void,SuperValue";
+   }
+   
+   public void after36()
+   {
+      after36 = "void";
+   }
+   
+   public void after36(@Arg int arg1)
+   {
+      after36 = "void,int";
+   }
+   
+   /* AFTER37 ADVICE */
+   
+   public SubClass after37(@JoinPoint Object joinPointInfo, @Arg SubValue arg2)
+   {
+      after37 = "SubClass,Object,SubValue";
+      return null;
+   }
+   
+   public Object after37(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after37 = "Object,Object,float";
+      return null;
+   }
+
+   public SubClass after37(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after37 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after37(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after37 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after37(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after37 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after37(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after37 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after37(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after37 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after37(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after37 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after37(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after37 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after37(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after37 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after37(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after37 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after37(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after37 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after37(@Return SuperClass valueReturned)
+   {
+      after37 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after37(@Return Object valueReturned)
+   {
+      after37 = "Object,Object";
+      return null;
+   }
+   
+   public void after37(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after37 = "void,float,SubValue";
+   }
+
+   public Object after37(@Arg float arg1)
+   {
+      after37 = "Object,float";
+      return null;
+   }
+   
+   public void after37(@Arg SubValue arg2)
+   {
+      after37 = "void,SubValue";
+   }
+   
+   public void after37(@Arg SuperValue arg2)
+   {
+      after37 = "void,SuperValue";
+   }
+   
+   public void after37()
+   {
+      after37 = "void";
+   }
+   
+   public void after37(@Arg int arg1)
+   {
+      after37 = "void,int";
+   }
+   
+   /* AFTER38 ADVICE */
+   
+   public Object after38(@JoinPoint Object joinPointInfo, @Arg float arg1)
+   {
+      after38 = "Object,Object,float";
+      return null;
+   }
+   
+   public SubClass after38(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after38 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after38(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after38 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after38(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after38 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after38(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after38 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after38(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after38 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after38(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after38 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after38(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after38 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after38(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after38 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after38(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after38 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after38(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after38 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after38(@Return SuperClass valueReturned)
+   {
+      after38 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after38(@Return Object valueReturned)
+   {
+      after38 = "Object,Object";
+      return null;
+   }
+   
+   public void after38(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after38 = "void,float,SubValue";
+   }
+
+   public Object after38(@Arg float arg1)
+   {
+      after38 = "Object,float";
+      return null;
+   }
+   
+   public void after38(@Arg SubValue arg2)
+   {
+      after38 = "void,SubValue";
+   }
+   
+   public void after38(@Arg SuperValue arg2)
+   {
+      after38 = "void,SuperValue";
+   }
+   
+   public void after38()
+   {
+      after38 = "void";
+   }
+   
+   public void after38(@Arg int arg1)
+   {
+      after38 = "void,int";
+   }
+   
+   /* AFTER39 ADVICE */
+   
+   public SubClass after39(@JoinPoint Object joinPointInfo, @Arg SuperValue arg2)
+   {
+      after39 = "SubClass,Object,SuperValue";
+      return null;
+   }
+   
+   public Object after39(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after39 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after39(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after39 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after39(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after39 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after39(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after39 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after39(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after39 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after39(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after39 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after39(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after39 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after39(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after39 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after39(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after39 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after39(@Return SuperClass valueReturned)
+   {
+      after39 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after39(@Return Object valueReturned)
+   {
+      after39 = "Object,Object";
+      return null;
+   }
+   
+   public void after39(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after39 = "void,float,SubValue";
+   }
+
+   public Object after39(@Arg float arg1)
+   {
+      after39 = "Object,float";
+      return null;
+   }
+   
+   public void after39(@Arg SubValue arg2)
+   {
+      after39 = "void,SubValue";
+   }
+   
+   public void after39(@Arg SuperValue arg2)
+   {
+      after39 = "void,SuperValue";
+   }
+   
+   public void after39()
+   {
+      after39 = "void";
+   }
+   
+   public void after39(@Arg int arg1)
+   {
+      after39 = "void,int";
+   }
+   
+   /* AFTER40 ADVICE */
+
+   public Object after40(@JoinPoint MethodInfo joinPointInfo)
+   {
+      after40 = "Object,MethodInfo";
+      return null;
+   }
+        
+   public Object after40(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after40 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after40(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after40 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after40(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after40 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after40(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after40 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after40(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after40 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after40(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after40 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after40(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after40 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after40(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after40 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after40(@Return SuperClass valueReturned)
+   {
+      after40 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after40(@Return Object valueReturned)
+   {
+      after40 = "Object,Object";
+      return null;
+   }
+   
+   public void after40(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after40 = "void,float,SubValue";
+   }
+
+   public Object after40(@Arg float arg1)
+   {
+      after40 = "Object,float";
+      return null;
+   }
+   
+   public void after40(@Arg SubValue arg2)
+   {
+      after40 = "void,SubValue";
+   }
+   
+   public void after40(@Arg SuperValue arg2)
+   {
+      after40 = "void,SuperValue";
+   }
+   
+   public void after40()
+   {
+      after40 = "void";
+   }
+   
+   public void after40(@Arg int arg1)
+   {
+      after40 = "void,int";
+   }
+   
+   /* AFTER41 ADVICE */
+   
+   public Object after41(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      after41 = "Object,JoinPointInfo";
+      return null;
+   }
+   
+   public Object after41(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after41 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after41(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after41 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after41(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after41 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after41(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after41 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after41(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after41 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after41(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after41 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after41(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after41 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after41(@Return SuperClass valueReturned)
+   {
+      after41 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after41(@Return Object valueReturned)
+   {
+      after41 = "Object,Object";
+      return null;
+   }
+   
+   public void after41(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after41 = "void,float,SubValue";
+   }
+
+   public Object after41(@Arg float arg1)
+   {
+      after41 = "Object,float";
+      return null;
+   }
+   
+   public void after41(@Arg SubValue arg2)
+   {
+      after41 = "void,SubValue";
+   }
+   
+   public void after41(@Arg SuperValue arg2)
+   {
+      after41 = "void,SuperValue";
+   }
+   
+   public void after41()
+   {
+      after41 = "void";
+   }
+   
+   public void after41(@Arg int arg1)
+   {
+      after41 = "void,int";
+   }
+   
+   /* AFTER42 ADVICE */
+   
+   public Object after42(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SubValue arg2)
+   {
+      after42 = "Object,SuperClass,float,SubValue";
+      return null;
+   }
+
+   public Object after42(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after42 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after42(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after42 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after42(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after42 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after42(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after42 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after42(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after42 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after42(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after42 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after42(@Return SuperClass valueReturned)
+   {
+      after42 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after42(@Return Object valueReturned)
+   {
+      after42 = "Object,Object";
+      return null;
+   }
+   
+   public void after42(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after42 = "void,float,SubValue";
+   }
+
+   public Object after42(@Arg float arg1)
+   {
+      after42 = "Object,float";
+      return null;
+   }
+   
+   public void after42(@Arg SubValue arg2)
+   {
+      after42 = "void,SubValue";
+   }
+   
+   public void after42(@Arg SuperValue arg2)
+   {
+      after42 = "void,SuperValue";
+   }
+   
+   public void after42()
+   {
+      after42 = "void";
+   }
+   
+   public void after42(@Arg int arg1)
+   {
+      after42 = "void,int";
+   }
+   
+   /* AFTER43 ADVICE */
+   
+   public Object after43(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg SuperValue arg2)
+   {
+      after43 = "Object,SuperClass,float,SuperValue";
+      return null;
+   }
+   
+   public Object after43(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after43 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after43(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after43 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after43(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after43 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after43(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after43 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after43(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after43 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after43(@Return SuperClass valueReturned)
+   {
+      after43 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after43(@Return Object valueReturned)
+   {
+      after43 = "Object,Object";
+      return null;
+   }
+   
+   public void after43(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after43 = "void,float,SubValue";
+   }
+
+   public Object after43(@Arg float arg1)
+   {
+      after43 = "Object,float";
+      return null;
+   }
+   
+   public void after43(@Arg SubValue arg2)
+   {
+      after43 = "void,SubValue";
+   }
+   
+   public void after43(@Arg SuperValue arg2)
+   {
+      after43 = "void,SuperValue";
+   }
+   
+   public void after43()
+   {
+      after43 = "void";
+   }
+   
+   public void after43(@Arg int arg1)
+   {
+      after43 = "void,int";
+   }
+   
+   /* AFTER44 ADVICE */
+   
+   public Object after44(@Return SuperClass valueReturned, @Arg float arg1,
+         @Arg Object arg2)
+   {
+      after44 = "Object,SuperClass,float,Object";
+      return null;
+   }
+
+   public SuperClass after44(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after44 = "SuperClass,MethodInfo,SuperClass,float";
+      return null;
+   }
+   
+   public Object after44(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after44 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after44(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after44 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after44(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after44 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after44(@Return SuperClass valueReturned)
+   {
+      after44 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after44(@Return Object valueReturned)
+   {
+      after44 = "Object,Object";
+      return null;
+   }
+   
+   public void after44(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after44 = "void,float,SubValue";
+   }
+
+   public Object after44(@Arg float arg1)
+   {
+      after44 = "Object,float";
+      return null;
+   }
+   
+   public void after44(@Arg SubValue arg2)
+   {
+      after44 = "void,SubValue";
+   }
+   
+   public void after44(@Arg SuperValue arg2)
+   {
+      after44 = "void,SuperValue";
+   }
+   
+   public void after44()
+   {
+      after44 = "void";
+   }
+   
+   public void after44(@Arg int arg1)
+   {
+      after44 = "void,int";
+   }
+   
+   /* AFTER45 ADVICE */
+   
+   public SuperClass after45(@Return SuperClass valueReturned, @Arg float arg1)
+   {
+      after45 = "SuperClass,SuperClass,float";
+      return null;
+   }
+   
+   public Object after45(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after45 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after45(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after45 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after45(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after45 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after45(@Return SuperClass valueReturned)
+   {
+      after45 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after45(@Return Object valueReturned)
+   {
+      after45 = "Object,Object";
+      return null;
+   }
+   
+   public void after45(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after45 = "void,float,SubValue";
+   }
+
+   public Object after45(@Arg float arg1)
+   {
+      after45 = "Object,float";
+      return null;
+   }
+   
+   public void after45(@Arg SubValue arg2)
+   {
+      after45 = "void,SubValue";
+   }
+   
+   public void after45(@Arg SuperValue arg2)
+   {
+      after45 = "void,SuperValue";
+   }
+   
+   public void after45()
+   {
+      after45 = "void";
+   }
+   
+   public void after45(@Arg int arg1)
+   {
+      after45 = "void,int";
+   }
+   
+   /* AFTER46 ADVICE */
+   
+   public Object after46(@Return SuperClass valueReturned, @Arg SubValue arg2)
+   {
+      after46 = "Object,SuperClass,SubValue";
+      return null;
+   }
+
+   public Object after46(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after46 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after46(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after46 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after46(@Return SuperClass valueReturned)
+   {
+      after46 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after46(@Return Object valueReturned)
+   {
+      after46 = "Object,Object";
+      return null;
+   }
+   
+   public void after46(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after46 = "void,float,SubValue";
+   }
+
+   public Object after46(@Arg float arg1)
+   {
+      after46 = "Object,float";
+      return null;
+   }
+   
+   public void after46(@Arg SubValue arg2)
+   {
+      after46 = "void,SubValue";
+   }
+   
+   public void after46(@Arg SuperValue arg2)
+   {
+      after46 = "void,SuperValue";
+   }
+   
+   public void after46()
+   {
+      after46 = "void";
+   }
+   
+   public void after46(@Arg int arg1)
+   {
+      after46 = "void,int";
+   }
+   
+   /* AFTER47 ADVICE */
+   
+   public Object after47(@Return SuperClass valueReturned, @Arg SuperValue arg2)
+   {
+      after47 = "Object,SuperClass,SuperValue";
+      return null;
+   }
+   
+   public SuperClass after47(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after47 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after47(@Return SuperClass valueReturned)
+   {
+      after47 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after47(@Return Object valueReturned)
+   {
+      after47 = "Object,Object";
+      return null;
+   }
+   
+   public void after47(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after47 = "void,float,SubValue";
+   }
+
+   public Object after47(@Arg float arg1)
+   {
+      after47 = "Object,float";
+      return null;
+   }
+   
+   public void after47(@Arg SubValue arg2)
+   {
+      after47 = "void,SubValue";
+   }
+   
+   public void after47(@Arg SuperValue arg2)
+   {
+      after47 = "void,SuperValue";
+   }
+   
+   public void after47()
+   {
+      after47 = "void";
+   }
+   
+   public void after47(@Arg int arg1)
+   {
+      after47 = "void,int";
+   }
+   
+   /* AFTER48 ADVICE */
+   
+   public SuperClass after48(@Return SuperClass valueReturned, @Arg Object arg2)
+   {
+      after48 = "SuperClass,SuperClass,Object";
+      return null;
+   }
+   
+   public Object after48(@Return SuperClass valueReturned)
+   {
+      after48 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after48(@Return Object valueReturned)
+   {
+      after48 = "Object,Object";
+      return null;
+   }
+   
+   public void after48(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after48 = "void,float,SubValue";
+   }
+
+   public Object after48(@Arg float arg1)
+   {
+      after48 = "Object,float";
+      return null;
+   }
+   
+   public void after48(@Arg SubValue arg2)
+   {
+      after48 = "void,SubValue";
+   }
+   
+   public void after48(@Arg SuperValue arg2)
+   {
+      after48 = "void,SuperValue";
+   }
+   
+   public void after48()
+   {
+      after48 = "void";
+   }
+   
+   public void after48(@Arg int arg1)
+   {
+      after48 = "void,int";
+   }
+   
+   /* AFTER49 ADVICE */
+   
+   public Object after49(@Return SuperClass valueReturned)
+   {
+      after49 = "Object,SuperClass";
+      return null;
+   }
+   
+   public Object after49(@Return Object valueReturned)
+   {
+      after49 = "Object,Object";
+      return null;
+   }
+   
+   public void after49(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after49 = "void,float,SubValue";
+   }
+
+   public Object after49(@Arg float arg1)
+   {
+      after49 = "Object,float";
+      return null;
+   }
+   
+   public void after49(@Arg SubValue arg2)
+   {
+      after49 = "void,SubValue";
+   }
+   
+   public void after49(@Arg SuperValue arg2)
+   {
+      after49 = "void,SuperValue";
+   }
+   
+   public void after49()
+   {
+      after49 = "void";
+   }
+   
+   public void after49(@Arg int arg1)
+   {
+      after49 = "void,int";
+   }
+   
+   /* AFTER50 ADVICE */
+   
+   public Object after50(@Return Object valueReturned)
+   {
+      after50 = "Object,Object";
+      return null;
+   }
+   
+   public void after50(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after50 = "void,float,SubValue";
+   }
+
+   public Object after50(@Arg float arg1)
+   {
+      after50 = "Object,float";
+      return null;
+   }
+   
+   public void after50(@Arg SubValue arg2)
+   {
+      after50 = "void,SubValue";
+   }
+   
+   public void after50(@Arg SuperValue arg2)
+   {
+      after50 = "void,SuperValue";
+   }
+   
+   public void after50()
+   {
+      after50 = "void";
+   }
+   
+   public void after50(@Arg int arg1)
+   {
+      after50 = "void,int";
+   }
+   
+   /* AFTER51 ADVICE */
+   
+   public void after51(@Arg float arg1, @Arg SubValue arg2)
+   {
+      after51 = "void,float,SubValue";
+   }
+
+   public Object after51(@Arg float arg1)
+   {
+      after51 = "Object,float";
+      return null;
+   }
+   
+   public void after51(@Arg SubValue arg2)
+   {
+      after51 = "void,SubValue";
+   }
+   
+   public void after51(@Arg SuperValue arg2)
+   {
+      after51 = "void,SuperValue";
+   }
+   
+   public void after51()
+   {
+      after51 = "void";
+   }
+   
+   public void after51(@Arg int arg1)
+   {
+      after51 = "void,int";
+   }
+   
+   /* AFTER52 ADVICE */
+   
+   public Object after52(@Arg float arg1)
+   {
+      after52 = "Object,float";
+      return null;
+   }
+   
+   public void after52(@Arg SubValue arg2)
+   {
+      after52 = "void,SubValue";
+   }
+   
+   public void after52(@Arg SuperValue arg2)
+   {
+      after52 = "void,SuperValue";
+   }
+   
+   public void after52()
+   {
+      after52 = "void";
+   }
+   
+   public void after52(@Arg int arg1)
+   {
+      after52 = "void,int";
+   }
+   
+   /* AFTER53  ADVICE */
+   
+   public void after53 (@Arg SubValue arg2)
+   {
+      after53  = "void,SubValue";
+   }
+   
+   public void after53 (@Arg SuperValue arg2)
+   {
+      after53  = "void,SuperValue";
+   }
+   
+   public void after53 ()
+   {
+      after53  = "void";
+   }
+   
+   public void after53 (@Arg int arg1)
+   {
+      after53  = "void,int";
+   }
+   
+   /* AFTER54  ADVICE */
+   
+   public void after54 (@Arg SuperValue arg2)
+   {
+      after54  = "void,SuperValue";
+   }
+   
+   public void after54 ()
+   {
+      after54  = "void";
+   }
+   
+   public void after54 (@Arg int arg1)
+   {
+      after54  = "void,int";
+   }
+   
+   /* AFTER55  ADVICE */
+   
+   public void after55 ()
+   {
+      after55  = "void";
+   }
+   
+   public void after55 (@Arg int arg1)
+   {
+      after55  = "void,int";
+   }
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAroundAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAroundAspect.java	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedAroundAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,880 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+import org.jboss.aop.advice.annotation.Arg;
+import org.jboss.aop.joinpoint.ConstructorInvocation;
+import org.jboss.aop.joinpoint.CurrentInvocation;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
+
+/**
+ * Aspect used on overloaded around advice tests.
+ *
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+// TODO temporary in this package
+public class OverloadedAroundAspect
+{
+   static String around1 = null;
+   static String around2 = null;
+   static String around3 = null;
+   static String around4 = null;
+   static String around5 = null;
+   static String around6 = null;
+   static String around7 = null;
+   static String around8 = null;
+   static String around9 = null;
+   static String around10 = null;
+   static String around11 = null;
+   static String around12 = null;
+   
+   public static void clear()
+   {
+      around1 = null;
+      around2 = null;
+      around3 = null;
+      around4 = null;
+      around5 = null;
+      around6 = null;
+      around7 = null;
+      around8 = null;
+      around9 = null;
+      around10 = null;
+      around11 = null;
+      around12 = null;
+   }
+
+   /* AROUND1 ADVICE */
+   
+   public Object around1(Invocation invocation) throws Throwable
+   {
+      around1 = "defaultSignature";
+      return invocation.invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around1 = "MethodInvocation,int,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around1 = "Invocation,int,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around1 = "Object,int,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1) throws Throwable
+   {
+      around1 = "MethodInvocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg long arg2) throws Throwable
+   {
+      around1 = "MethodInvocation,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1) throws Throwable
+   {
+      around1 = "Invocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg long arg2) throws Throwable
+   {
+      around1 = "Invocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around1 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around1 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around1 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+   
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around1 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around1(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around1 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around1(@Arg int arg1) throws Throwable
+   {
+      around1 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around1(@Arg long arg2) throws Throwable
+   {
+      around1 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around1() throws Throwable
+   {
+      around1 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around1(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+   
+   /* AROUND2 ADVICE */
+   
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around2 = "MethodInvocation,int,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around2 = "Invocation,int,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around2 = "Object,int,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1) throws Throwable
+   {
+      around2 = "MethodInvocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg long arg2) throws Throwable
+   {
+      around2 = "MethodInvocation,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1) throws Throwable
+   {
+      around2 = "Invocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg long arg2) throws Throwable
+   {
+      around2 = "Invocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around2 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around2 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around2 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+   
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around2 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around2(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around2 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around2(@Arg int arg1) throws Throwable
+   {
+      around2 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around2(@Arg long arg2) throws Throwable
+   {
+      around2 = "long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around2() throws Throwable
+   {
+      around2 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around2(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND3 ADVICE */
+   
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around3 = "Invocation,int,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around3 = "Object,int,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1) throws Throwable
+   {
+      around3 = "MethodInvocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg long arg2) throws Throwable
+   {
+      around3 = "MethodInvocation,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1) throws Throwable
+   {
+      around3 = "Invocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg long arg2) throws Throwable
+   {
+      around3 = "Invocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around3 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around3 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around3 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around3 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around3(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around3 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around3(@Arg int arg1) throws Throwable
+   {
+      around3 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around3(@Arg long arg2) throws Throwable
+   {
+      around3 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around3() throws Throwable
+   {
+      around3 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around3(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND4 ADVICE */
+   
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around4 = "Object,int,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1) throws Throwable
+   {
+      around4 = "MethodInvocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg long arg2) throws Throwable
+   {
+      around4 = "MethodInvocation,long";
+      return invocation.invokeNext();
+   }
+   
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1) throws Throwable
+   {
+      around4 = "Invocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg long arg2) throws Throwable
+   {
+      around4 = "Invocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around4 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around4 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around4 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around4 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around4(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around4 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around4(@Arg int arg1) throws Throwable
+   {
+      around4 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around4(@Arg long arg2) throws Throwable
+   {
+      around4 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around4() throws Throwable
+   {
+      around4 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND5 ADVICE */
+   
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg int arg1) throws Throwable
+   {
+      around5 = "MethodInvocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation, @Arg long arg2) throws Throwable
+   {
+      around5 = "MethodInvocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1) throws Throwable
+   {
+      around5 = "Invocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg long arg2) throws Throwable
+   {
+      around5 = "Invocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around5 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around5 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around5 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around5 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around5(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around5 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around5(@Arg int arg1) throws Throwable
+   {
+      around5 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around5(@Arg long arg2) throws Throwable
+   {
+      around5 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around5() throws Throwable
+   {
+      around5 = "";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around5(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND6 ADVICE */
+   
+   public Object around6(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg int arg1) throws Throwable
+   {
+      around6 = "Invocation,int";
+      return invocation.invokeNext();
+   }
+
+   public Object aroun6(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation, @Arg long arg2) throws Throwable
+   {
+      around6 = "Invocation,long";
+      return invocation.invokeNext();
+   }
+
+   public Object around6(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around6 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around6(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around6 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around6(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around6 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+   
+   public Object around6(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around6 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around6(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around6 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around6(@Arg int arg1) throws Throwable
+   {
+      around6 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around6(@Arg long arg2) throws Throwable
+   {
+      around6 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around6() throws Throwable
+   {
+      around6 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around6(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND7 ADVICE */
+   
+   public Object around7(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg int arg1) throws Throwable
+   {
+      around7 = "Object,int";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around7(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation, @Arg long arg2) throws Throwable
+   {
+      around7 = "Object,long";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around7(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around7 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+   
+   public Object around7(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around7 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around7(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around7 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around7(@Arg int arg1) throws Throwable
+   {
+      around7 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around7(@Arg long arg2) throws Throwable
+   {
+      around7 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around7() throws Throwable
+   {
+      around7 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around7(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND8 ADVICE */
+   
+   public Object around8(@org.jboss.aop.advice.annotation.Invocation
+         MethodInvocation invocation) throws Throwable
+   {
+      around8 = "MethodInvocation";
+      return invocation.invokeNext();
+   }
+
+   public Object around8(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around8 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+   
+   public Object around8(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around8 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around8(@Arg int arg1) throws Throwable
+   {
+      around8 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around8(@Arg long arg2) throws Throwable
+   {
+      around8 = "long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around8() throws Throwable
+   {
+      around8 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around8(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND9 ADVICE */
+   
+   public Object around9(@org.jboss.aop.advice.annotation.Invocation
+         Object invocation) throws Throwable
+   {
+      around9 = "Object";
+      return ((Invocation) invocation).invokeNext();
+   }
+
+   public Object around9(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around9 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around9(@Arg int arg1) throws Throwable
+   {
+      around9 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around9(@Arg long arg2) throws Throwable
+   {
+      around9 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around9() throws Throwable
+   {
+      around9 = "";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around9(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND10 ADVICE */
+   
+   public Object around10(@Arg int arg1, @Arg long arg2) throws Throwable
+   {
+      around10 = "int,long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around10(@Arg int arg1) throws Throwable
+   {
+      around10 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around10(@Arg long arg2) throws Throwable
+   {
+      around10 = "long";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around10() throws Throwable
+   {
+      around10 = "";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around10(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+
+   /* AROUND11 ADVICE */
+   
+   public Object around11(@Arg int arg1) throws Throwable
+   {
+      around11 = "int";
+      return CurrentInvocation.proceed();
+   }
+
+   public Object around11(@Arg long arg2) throws Throwable
+   {
+      around11 = "long";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around11() throws Throwable
+   {
+      around11 = "";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around11(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+   
+   /* AROUND12 ADVICE */
+   
+   public Object around12() throws Throwable
+   {
+      around12 = "";
+      return CurrentInvocation.proceed();
+   }
+   
+   public Object around12(@org.jboss.aop.advice.annotation.Invocation
+         ConstructorInvocation invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }   
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedBeforeAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedBeforeAspect.java	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/OverloadedBeforeAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,556 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+import org.jboss.aop.FieldInfo;
+import org.jboss.aop.JoinPointInfo;
+import org.jboss.aop.MethodInfo;
+import org.jboss.aop.advice.annotation.Arg;
+import org.jboss.aop.advice.annotation.JoinPoint;
+
+/**
+ * Aspect used on overloaded before advice tests.
+ *
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class OverloadedBeforeAspect
+{
+   static String before1 = null;
+   static String before2 = null;
+   static String before3 = null;
+   static String before4 = null;
+   static String before5 = null;
+   static String before6 = null;
+   static String before7 = null;
+   static String before8 = null;
+   static String before9 = null;
+   static String before10 = null;
+   static String before11 = null;
+   static String before12 = null;
+   
+   public static void clear()
+   {
+      before1 = null;
+      before2 = null;
+      before3 = null;
+      before4 = null;
+      before5 = null;
+      before6 = null;
+      before7 = null;
+      before8 = null;
+      before9 = null;
+      before10 = null;
+      before11 = null;
+      before12 = null;
+   }
+   
+   /* BEFORE1 ADVICE */
+   
+   public void before1(@JoinPoint FieldInfo joinPointInfo, @Arg String text)
+   {
+      before1 = "FieldInfo,String";
+   }
+
+   public void before1(@JoinPoint FieldInfo joinPointInfo, @Arg Object text)
+   {
+      before1 = "FieldInfo,Object";
+   }
+   
+   public void before1(@JoinPoint JoinPointInfo joinPointInfo, @Arg String text)
+   {
+      before1 = "JoinPointInfo,String";
+   }
+
+   public void before1(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
+   {
+      before1 = "JoinPointInfo,Object";
+   }
+
+   public void before1(@JoinPoint Object joinPointInfo, @Arg String text)
+   {
+      before1 = "Object,String";
+   }
+
+   public void before1(@JoinPoint Object joinPointInfo, @Arg Object text)
+   {
+      before1 = "Object,Object";
+   }
+
+   public void before1(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before1 = "FieldInfo";
+   }
+   
+   public void before1(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before1 = "JoinPointInfo";
+   }
+
+   public void before1(@JoinPoint Object joinPointInfo)
+   {
+      before1 = "Object";
+   }
+   
+   public void before1(@Arg String text)
+   {
+      before1 = "String";
+   }
+      
+   public void before1()
+   {
+      before1 = "";
+   }
+   
+/*   public void before1(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before1(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+  */ 
+   /* BEFORE2 ADVICE */
+   
+   public void before2(@JoinPoint FieldInfo joinPointInfo, @Arg Object text)
+   {
+      before2 = "FieldInfo,Object";
+   }
+   
+   public void before2(@JoinPoint JoinPointInfo joinPointInfo, @Arg String text)
+   {
+      before2 = "JoinPointInfo,String";
+   }
+
+   public void before2(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
+   {
+      before2 = "JoinPointInfo,Object";
+   }
+
+   public void before2(@JoinPoint Object joinPointInfo, @Arg String text)
+   {
+      before2 = "Object,String";
+   }
+
+   public void before2(@JoinPoint Object joinPointInfo, @Arg Object text)
+   {
+      before2 = "Object,Object";
+   }
+
+   public void before2(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before2 = "FieldInfo";
+   }
+   
+   public void before2(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before2 = "JoinPointInfo";
+   }
+
+   public void before2(@JoinPoint Object joinPointInfo)
+   {
+      before2 = "Object";
+   }
+   
+   public void before2(@Arg String text)
+   {
+      before2 = "String";
+   }
+      
+   public void before2()
+   {
+      before2 = "";
+   }
+   
+   public void before2(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before2(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE3 ADVICE */
+   
+   public void before3(@JoinPoint JoinPointInfo joinPointInfo, @Arg String text)
+   {
+      before3 = "JoinPointInfo,String";
+   }
+
+   public void before3(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
+   {
+      before3 = "JoinPointInfo,Object";
+   }
+
+   public void before3(@JoinPoint Object joinPointInfo, @Arg String text)
+   {
+      before3 = "Object,String";
+   }
+
+   public void before3(@JoinPoint Object joinPointInfo, @Arg Object text)
+   {
+      before3 = "Object,Object";
+   }
+
+   public void before3(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before3 = "FieldInfo";
+   }
+   
+   public void before3(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before3 = "JoinPointInfo";
+   }
+
+   public void before3(@JoinPoint Object joinPointInfo)
+   {
+      before3 = "Object";
+   }
+   
+   public void before3(@Arg String text)
+   {
+      before3 = "String";
+   }
+      
+   public void before3()
+   {
+      before3 = "";
+   }
+   
+   public void before3(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before3(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE4 ADVICE */
+   
+   public void before4(@JoinPoint JoinPointInfo joinPointInfo, @Arg Object text)
+   {
+      before4 = "JoinPointInfo,Object";
+   }
+
+   public void before4(@JoinPoint Object joinPointInfo, @Arg String text)
+   {
+      before4 = "Object,String";
+   }
+
+   public void before4(@JoinPoint Object joinPointInfo, @Arg Object text)
+   {
+      before4 = "Object,Object";
+   }
+
+   public void before4(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before4 = "FieldInfo";
+   }
+   
+   public void before4(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before4 = "JoinPointInfo";
+   }
+
+   public void before4(@JoinPoint Object joinPointInfo)
+   {
+      before4 = "Object";
+   }
+   
+   public void before4(@Arg String text)
+   {
+      before4 = "String";
+   }
+      
+   public void before4()
+   {
+      before4 = "";
+   }
+   
+   public void before4(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before4(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE5 ADVICE */
+   
+   public void before5(@JoinPoint Object joinPointInfo, @Arg String text)
+   {
+      before5 = "Object,String";
+   }
+
+   public void before5(@JoinPoint Object joinPointInfo, @Arg Object text)
+   {
+      before5 = "Object,Object";
+   }
+
+   public void before5(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before5 = "FieldInfo";
+   }
+   
+   public void before5(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before5 = "JoinPointInfo";
+   }
+
+   public void before5(@JoinPoint Object joinPointInfo)
+   {
+      before5 = "Object";
+   }
+   
+   public void before5(@Arg String text)
+   {
+      before5 = "String";
+   }
+      
+   public void before5()
+   {
+      before5 = "";
+   }
+   
+   public void before5(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before5(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE6 ADVICE */
+   
+   public void before6(@JoinPoint Object joinPointInfo, @Arg Object text)
+   {
+      before6 = "Object,Object";
+   }
+
+   public void before6(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before6 = "FieldInfo";
+   }
+   
+   public void before6(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before6 = "JoinPointInfo";
+   }
+
+   public void before6(@JoinPoint Object joinPointInfo)
+   {
+      before6 = "Object";
+   }
+   
+   public void before6(@Arg String text)
+   {
+      before6 = "String";
+   }
+      
+   public void before6()
+   {
+      before6 = "";
+   }
+   
+   public void before6(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before6(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE7 ADVICE */
+   
+   public void before7(@JoinPoint FieldInfo joinPointInfo)
+   {
+      before7 = "FieldInfo";
+   }
+   
+   public void before7(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before7 = "JoinPointInfo";
+   }
+
+   public void before7(@JoinPoint Object joinPointInfo)
+   {
+      before7 = "Object";
+   }
+   
+   public void before7(@Arg String text)
+   {
+      before7 = "String";
+   }
+      
+   public void before7()
+   {
+      before7 = "";
+   }
+   
+   public void before7(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before7(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE8 ADVICE */
+   
+   public void before8(@JoinPoint JoinPointInfo joinPointInfo)
+   {
+      before8 = "JoinPointInfo";
+   }
+
+   public void before8(@JoinPoint Object joinPointInfo)
+   {
+      before8 = "Object";
+   }
+   
+   public void before8(@Arg String text)
+   {
+      before8 = "String";
+   }
+      
+   public void before8()
+   {
+      before8 = "";
+   }
+   
+   public void before8(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before8(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE9 ADVICE */
+   
+   public void before9(@JoinPoint Object joinPointInfo)
+   {
+      before9 = "Object";
+   }
+   
+   public void before9(@Arg String text)
+   {
+      before9 = "String";
+   }
+      
+   public void before9()
+   {
+      before9 = "";
+   }
+   
+   public void before9(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before9(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE10 ADVICE */
+   
+   public void before10(@Arg String text)
+   {
+      before10 = "String";
+   }
+
+   public void before10(@Arg Object text)
+   {
+      before10 = "Object";
+   }
+   
+   public void before10()
+   {
+      before10 = "";
+   }
+   
+   public void before10(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before10(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE11 ADVICE */
+   
+   public void before11(@Arg Object text)
+   {
+      before11 = "Object";
+   }
+   
+   public void before11()
+   {
+      before11 = "";
+   }
+   
+   public void before11(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before11(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   /* BEFORE12 ADVICE */
+   
+   public void before12()
+   {
+      before12 = "";
+   }
+   
+   public void before12(@JoinPoint MethodInfo constructorInfo)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before12(@Arg SuperValue text)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/POJOException.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJOException.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/POJOException.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/POJOException.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Class used on annotated parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class POJOException extends Exception
+{
+   private static final long serialVersionUID = 1L;
+
+   /**
+    * A number that identifies the exception thrown.
+    */
+   int number;
+
+   /**
+    * Constructor.
+    */
+   public POJOException()
+   {
+      this(0);
+   }
+
+   /**
+    * Constructor.
+    * 
+    * @param number a number identifying the exception.
+    */
+   public POJOException(int number)
+   {
+      this.number = number;  
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnAspect.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnAspect.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnAspect.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,206 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+import org.jboss.aop.JoinPointInfo;
+import org.jboss.aop.advice.annotation.JoinPoint;
+import org.jboss.aop.advice.annotation.Return;
+import org.jboss.aop.joinpoint.Invocation;
+
+/**
+ * Aspect used both on @Return parameter tests, and on advice return type tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ReturnAspect
+{
+   public static String aroundAdvice = null;
+   public static Object aroundReturn = null;
+   public static String afterAdvice = null;
+   public static Object afterReturn = null;
+   
+   public static void clear()
+   {
+      aroundAdvice = null;
+      aroundReturn = null;
+      afterAdvice = null;
+      afterReturn = null;
+   }
+   
+   public void before(@Return Object object)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void throwing(@Return Object object)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void around1(Invocation invocation) throws Exception
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void around2(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation) throws Exception
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public Object around3(Invocation invocation) throws Throwable
+   {
+      aroundAdvice = "around3";
+      aroundReturn = invocation.invokeNext();
+      return aroundAdvice;
+   }
+   
+   public Object around4(@org.jboss.aop.advice.annotation.Invocation
+         Invocation invocation) throws Throwable
+   {
+      aroundAdvice = "around4";
+      aroundReturn = invocation.invokeNext();
+      return aroundAdvice;
+   }
+   
+   public Object around5()
+   {
+      aroundAdvice = "around5";
+      return aroundAdvice;
+   }
+   
+   public void around6()
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public String around7(@org.jboss.aop.advice.annotation.Invocation Invocation
+         invocation) throws Throwable
+   {
+      aroundAdvice = "around7";
+      aroundReturn = invocation.invokeNext();
+      return aroundAdvice;
+   }
+   
+   public SubValue around8()
+   {
+      aroundAdvice = "around8";
+      return new SubValue(80);
+   }
+   
+   public SuperValue around9(@org.jboss.aop.advice.annotation.Invocation Invocation
+         invocation) throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+   
+   public SubValue around10(@org.jboss.aop.advice.annotation.Invocation Invocation
+         invocation) throws Throwable
+   {
+      aroundAdvice = "around10";
+      aroundReturn = invocation.invokeNext();
+      return new SubValue(100);
+   }
+   
+   public SuperValue around11(@org.jboss.aop.advice.annotation.Invocation Invocation
+         invocation) throws Throwable
+   {
+      aroundAdvice = "around11";
+      aroundReturn = invocation.invokeNext();
+      return new SuperValue(110);
+   }
+
+   
+   public void after1(@org.jboss.aop.advice.annotation.JoinPoint JoinPointInfo info) throws Exception
+   {
+      afterAdvice = "after1";
+   }
+   
+   public void after2(@Return Object returnedValue) throws Exception
+   {
+      afterAdvice = "after2";
+      afterReturn = returnedValue;
+   }
+   
+   public Object after3(@JoinPoint JoinPointInfo info, @Return String returnedValue)
+   throws Throwable
+   {
+      afterAdvice = "after3";
+      afterReturn = returnedValue;
+      return afterAdvice;
+   }
+   
+   public Object after4(@Return Object returnedValue) throws Throwable
+   {
+      afterAdvice = "after4";
+      afterReturn = returnedValue;
+      return afterAdvice;
+   }
+   
+   public Object after5()
+   {
+      afterAdvice = "after5";
+      return afterAdvice;
+   }
+   
+   public void after6()
+   {
+      afterAdvice = "after6";
+   }
+   
+   public String after7(@JoinPoint JoinPointInfo joinPoint,
+         @Return String returnedValue) throws Throwable
+   {
+      afterAdvice = "after7";
+      afterReturn = returnedValue;
+      return afterAdvice;
+   }
+   
+   public SubValue after8()
+   {
+      afterAdvice = "after8";
+      return new SubValue(800);
+   }
+   
+   public SuperValue after9() throws Throwable
+   {
+      Assert.fail("This advice should never be executed");
+      return null;
+   }
+   
+   public SubValue after10(@Return SubValue returnedValue) throws Throwable
+   {
+      afterAdvice = "after10";
+      afterReturn = returnedValue;
+      return new SubValue(1000);
+   }
+   
+   public SubValue after11(@Return SuperValue returnedValue) throws Throwable
+   {
+      afterAdvice = "after11";
+      afterReturn = returnedValue;
+      return new SubValue(1100);
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnPOJO.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnPOJO.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnPOJO.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnPOJO.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,88 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Plain old java object used both on @Return parameter tests, and on advice return type
+ * tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ReturnPOJO
+{
+   public void method1() {}
+
+   public String method2()
+   {
+      return "method2";
+   }
+   
+   public String method3()
+   {
+      return "method3";
+   }
+   
+   public String method4()
+   {
+      return "method4";
+   }
+   
+   public String method5()
+   {
+      return "method5";
+   }
+   
+   public String method6()
+   {
+      return "method6";
+   }
+   
+   public String method7()
+   {
+      return "method7";
+   }
+   
+   public SubValue method8()
+   {
+      return new SubValue(8);
+   }
+   
+   public SubValue method9()
+   {
+      return new SubValue(9);
+   }
+   
+   public SuperValue method10()
+   {
+      return new SuperValue(10);
+   }
+   
+   public SuperValue method11()
+   {
+      return new SuperValue(11);
+   }
+   
+   public Object method12() throws POJOException
+   {
+      throw new POJOException();
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnTestCase.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnTestCase.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ReturnTestCase.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ReturnTestCase.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,181 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * Tests both the use of @Return parameters, and the use of return values in advices.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ReturnTestCase extends AOPTestWithSetup
+{
+   private ReturnPOJO pojo;
+   
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("ReturnTestCase");
+      suite.addTestSuite(ReturnTestCase.class);
+      return suite;
+   }
+   
+   public ReturnTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      ReturnAspect.clear();
+      this.pojo = new ReturnPOJO();
+   }
+   
+   public void test1()
+   {
+      pojo.method1();
+      assertNull(ReturnAspect.aroundAdvice);
+      assertNull(ReturnAspect.aroundReturn);
+      assertEquals("after1", ReturnAspect.afterAdvice);
+      assertNull(ReturnAspect.afterReturn);
+   }
+   
+   public void test2()
+   {
+      assertEquals("method2", pojo.method2());
+      assertNull(ReturnAspect.aroundAdvice);
+      assertNull(ReturnAspect.aroundReturn);
+      assertEquals("after2", ReturnAspect.afterAdvice);
+      assertEquals("method2", ReturnAspect.afterReturn);
+   }
+   
+   public void test3()
+   {
+      assertEquals("after3", pojo.method3());
+      assertEquals("around3", ReturnAspect.aroundAdvice);
+      assertEquals("method3", ReturnAspect.aroundReturn);
+      assertEquals("after3", ReturnAspect.afterAdvice);
+      assertEquals("around3", ReturnAspect.afterReturn);
+   }
+   
+   public void test4()
+   {
+      assertEquals("after4", pojo.method4());
+      assertEquals("around4", ReturnAspect.aroundAdvice);
+      assertEquals("method4", ReturnAspect.aroundReturn);
+      assertEquals("after4", ReturnAspect.afterAdvice);
+      assertEquals("around4", ReturnAspect.afterReturn);
+   }
+   
+   public void test5()
+   {
+      assertEquals("after5", pojo.method5());
+      assertEquals("around5", ReturnAspect.aroundAdvice);
+      assertNull(ReturnAspect.aroundReturn);
+      assertEquals("after5", ReturnAspect.afterAdvice);
+      assertNull(ReturnAspect.afterReturn);
+   }
+   
+   public void test6()
+   {
+      assertEquals("method6", pojo.method6());
+      assertNull(ReturnAspect.aroundAdvice);
+      assertNull(ReturnAspect.aroundReturn);
+      assertEquals("after6", ReturnAspect.afterAdvice);
+      assertNull(ReturnAspect.afterReturn);
+   }
+   
+   public void test7()
+   {
+      assertEquals("after7", pojo.method7());
+      assertEquals("around7", ReturnAspect.aroundAdvice);
+      assertEquals("method7", ReturnAspect.aroundReturn);
+      assertEquals("after7", ReturnAspect.afterAdvice);
+      assertEquals("around7", ReturnAspect.afterReturn);
+   }
+   
+   public void test8()
+   {
+      SubValue value = pojo.method8();
+      assertNotNull(value);
+      assertEquals(800, value.i);
+      assertEquals("around8", ReturnAspect.aroundAdvice);
+      assertNull(ReturnAspect.aroundReturn);
+      assertEquals("after8", ReturnAspect.afterAdvice);
+      assertNull(ReturnAspect.afterReturn);
+   }
+   
+   public void test9()
+   {
+      SubValue value = pojo.method9();
+      assertNotNull(value);
+      assertEquals(9, value.i);
+      assertNull(ReturnAspect.aroundAdvice);
+      assertNull(ReturnAspect.aroundReturn);
+      assertNull(ReturnAspect.afterAdvice);
+      assertNull(ReturnAspect.afterReturn);
+   }
+   
+   public void test10()
+   {
+      SuperValue value = pojo.method10();
+      assertNotNull(value);
+      assertEquals(100, value.i);
+      assertEquals("around10", ReturnAspect.aroundAdvice);
+      assertNotNull(ReturnAspect.aroundReturn);
+      assertEquals(10, ((SuperValue) ReturnAspect.aroundReturn).i);
+      assertNull(ReturnAspect.afterAdvice);
+      assertNull(ReturnAspect.afterReturn);
+   }
+
+   public void test11()
+   {
+      SuperValue value = pojo.method11();
+      assertNotNull(value);
+      assertEquals(1100, value.i);
+      assertEquals("around11", ReturnAspect.aroundAdvice);
+      assertNotNull(ReturnAspect.aroundReturn);
+      assertEquals(11, ((SuperValue) ReturnAspect.aroundReturn).i);
+      assertEquals("after11", ReturnAspect.afterAdvice);
+      assertNotNull(ReturnAspect.afterReturn);
+      assertEquals(110, ((SuperValue) ReturnAspect.afterReturn).i);
+   }
+   
+   public void test12()
+   {
+      try
+      {
+         pojo.method12();
+      }
+      catch(POJOException e){}
+   }
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubClass.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubClass.java	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubClass.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,27 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+public class SubClass extends SuperClass
+{
+
+}

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubValue.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SubValue.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SubValue.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SubValue.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,38 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 39449 $
+ */
+public class SubValue extends SuperValue
+{
+
+   public SubValue(int i)
+   {
+      // FIXME SubValue constructor
+      super(i);
+   }
+
+}

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperClass.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperClass.java	2006-12-05 22:05:17 UTC (rev 58854)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperClass.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,27 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+public class SuperClass
+{
+
+}

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperValue.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SuperValue.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/SuperValue.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/SuperValue.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,47 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 39449 $
+ */
+public class SuperValue
+{
+   int i;
+   public SuperValue(int i)
+   {
+      this.i = i;
+   }
+   
+   public int getValue()
+   {
+      return i;
+   }
+   
+   public void doubleValue()
+   {
+      i *= 2;
+   }
+
+}

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownAspect.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownAspect.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownAspect.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownAspect.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,88 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+import org.jboss.aop.advice.annotation.Arg;
+import org.jboss.aop.advice.annotation.Thrown;
+
+/**
+ * Aspect used on @Thrown parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ThrownAspect
+{
+
+   public static String advice;
+   public static Throwable thrown;
+   public static int thrownNumber;
+   
+   public static void clear()
+   {
+      advice = null;
+      thrown = null;
+      thrownNumber = 0;
+   }
+   
+   public void throwing1()
+   {
+      advice = "throwing1";
+   }
+   
+   public void throwing2(@Thrown Throwable throwable, @Arg int i)
+   {
+      advice = "throwing2";
+      thrownNumber = i;
+      thrown = throwable;
+   }
+   
+   public void throwing3(@Thrown Exception exception)
+   {
+      advice = "throwing3";
+      thrownNumber = ((POJOException) exception).number;
+      thrown = exception;
+   }
+   
+   public void throwing4(@Thrown POJOException pojoException, @Arg int i)
+   {
+      advice = "throwing4";
+      thrownNumber = i;
+      thrown = pojoException;
+   }
+   
+   public void throwing5(@Thrown RuntimeException runtimeException)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void throwing6(Throwable throwable)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void throwing7(@Arg int i)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownPOJO.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownPOJO.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownPOJO.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownPOJO.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,60 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Plain old java object used on @Thrown parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ThrownPOJO
+{
+   public void method1(int i) throws POJOException
+   {
+      throw new POJOException(i);
+   }
+   
+   public void method2(int i) throws POJOException
+   {
+      throw new POJOException(i);
+   }
+   
+   public void method3(int i) throws POJOException
+   {
+      throw new POJOException(i);
+   }
+   
+   public void method4(int i) throws POJOException
+   {
+      throw new POJOException(i);
+   }
+   
+   public void method5(int i) throws POJOException
+   {
+      throw new POJOException(i);
+   }
+   
+   public void method6() throws POJOException
+   {
+      throw new POJOException(6);
+   }
+}
\ No newline at end of file

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownTestCase.java (from rev 58706, projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownTestCase.java)
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/args/ThrownTestCase.java	2006-11-28 17:24:44 UTC (rev 58706)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/ThrownTestCase.java	2006-12-05 23:03:14 UTC (rev 58855)
@@ -0,0 +1,177 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * Tests parameter annotation @Thrown. 
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ *
+ */
+public class ThrownTestCase extends AOPTestWithSetup
+{
+   private ThrownPOJO pojo;
+
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("ThrownTestCase");
+      suite.addTestSuite(ThrownTestCase.class);
+      return suite;
+   }
+
+   public ThrownTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      ThrownAspect.clear();
+      this.pojo = new ThrownPOJO();
+   }
+
+   public void test1()
+   {
+      boolean thrown = false;
+      try
+      {
+         pojo.method1(11);
+      }
+      catch(POJOException pojoException)
+      {
+         thrown = true;
+         assertEquals(11, pojoException.number);
+         assertNull(ThrownAspect.advice);
+         assertNull(ThrownAspect.thrown);
+         assertEquals(0, ThrownAspect.thrownNumber);
+      }
+      assertTrue(thrown);
+   }
+
+   public void test2()
+   {
+      boolean thrown = false;
+      try
+      {
+         pojo.method2(23);
+      }
+      catch(POJOException pojoException)
+      {
+         thrown = true;
+         assertEquals(23, pojoException.number);
+         assertEquals("throwing2", ThrownAspect.advice);
+         assertEquals(pojoException, ThrownAspect.thrown);
+         assertEquals(23, ThrownAspect.thrownNumber);
+      }
+      assertTrue(thrown);
+   }
+   
+   public void test3()
+   {
+      boolean thrown = false;
+      try
+      {
+         pojo.method3(37);
+      }
+      catch(POJOException pojoException)
+      {
+         thrown = true;
+         assertEquals(37, pojoException.number);
+         assertNull(ThrownAspect.advice);
+         assertNull(ThrownAspect.thrown);
+         assertEquals(0, ThrownAspect.thrownNumber);
+         /*assertEquals("throwing3", ThrownAspect.advice);
+         assertEquals(pojoException, ThrownAspect.thrown);
+         assertEquals(37, ThrownAspect.thrownNumber);*/
+      }
+      assertTrue(thrown);
+   }
+   
+   public void test4()
+   {
+      boolean thrown = false;
+      try
+      {
+         pojo.method4(43);
+      }
+      catch(POJOException pojoException)
+      {
+         thrown = true;
+         assertEquals(43, pojoException.number);
+         assertNull(ThrownAspect.advice);
+         assertNull(ThrownAspect.thrown);
+         assertEquals(0, ThrownAspect.thrownNumber);
+         /*assertEquals("throwing4", ThrownAspect.advice);
+         assertEquals(pojoException, ThrownAspect.thrown);
+         assertEquals(43, ThrownAspect.thrownNumber);*/
+      }
+      assertTrue(thrown);
+   }
+   
+   public void test5()
+   {
+      boolean thrown = false;
+      try
+      {
+         pojo.method5(59);
+      }
+      catch(POJOException pojoException)
+      {
+         thrown = true;
+         assertEquals(59, pojoException.number);
+         assertNull(ThrownAspect.advice);
+         assertNull(ThrownAspect.thrown);
+         assertEquals(0, ThrownAspect.thrownNumber);
+      }
+      assertTrue(thrown);
+   }
+   
+   public void test6()
+   {
+      boolean thrown = false;
+      try
+      {
+         pojo.method6();
+      }
+      catch(POJOException pojoException)
+      {
+         thrown = true;
+         assertEquals(6, pojoException.number);
+         assertNull(ThrownAspect.advice);
+         assertNull(ThrownAspect.thrown);
+         assertEquals(0, ThrownAspect.thrownNumber);
+      }
+      assertTrue(thrown);
+   }
+}
\ No newline at end of file



From brian.stansberry at jboss.com  Tue Dec  5 18:07:25 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Tue, 05 Dec 2006 18:07:25 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1GrjNl-0000l0-7a@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/05 18:07:25

  Modified:    tests/functional/org/jboss/cache/marshall     
                        SyncReplTest.java AsyncReplTest.java
  Added:       tests/functional/org/jboss/cache/marshall     
                        FooClassLoader.java Foo.notjava Foo.clazz
  Log:
  Port JBCACHE-874 tests from 1.4.0 branch
  
  Revision  Changes    Path
  1.12      +60 -10    JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SyncReplTest.java	13 Sep 2006 11:42:42 -0000	1.11
  +++ SyncReplTest.java	5 Dec 2006 23:07:25 -0000	1.12
  @@ -11,6 +11,8 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  +
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -29,7 +31,7 @@
    * Test case for marshalling using Sync mode.
    *
    * @author Ben Wang
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class SyncReplTest extends RegionBasedMarshallingTestBase
   {
  @@ -215,17 +217,33 @@
      {
         ClassLoader cl = getClassLoader();
         cache1.registerClassLoader("/aop", cl);
  +      // Create an empty Person loaded by this classloader
  +      Object scopedBen1 = getPersonFromClassloader(cl);
  +      
         cl = getClassLoader();
         cache2.registerClassLoader("/aop", cl);
  +      // Create another empty Person loaded by this classloader
  +      Object scopedBen2 = getPersonFromClassloader(cl);
   
         cache1.put("/aop/1", "person", ben_);
  -      cache1.put("/aop/1", "person", ben_);
  +      cache1.put("/aop/2", "person", scopedBen1);
   
  -      Object ben2;
  +      Object ben2 = null;
  +      try
  +      {
         // Can't cast it to Person. CCE will resutl.
         ben2 = cache2.get("/aop/1", "person");
         assertEquals(ben_.toString(), ben2.toString());
   
  +         ben2 = cache2.get("/aop/2", "person");
  +         assertFalse("cache2 deserialized with scoped classloader", ben2 instanceof Person);
  +         assertFalse("cache2 deserialized with cache2 classloader", scopedBen1.equals(ben2));
  +         assertEquals("scopedBen deserialized properly", scopedBen2, ben2);
  +      } catch (Exception ex)
  +      {
  +         fail("Test fails with exception " +ex);
  +      }
  +
      }
   
      public void testMethodCall() throws Exception
  @@ -334,13 +352,45 @@
         // Need to test out if app is not registered with beforehand??
      }
   
  +   public void testCustomFqn() throws Exception
  +   {
  +      FooClassLoader cl1 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache1.registerClassLoader("/aop", cl1);
  +      FooClassLoader cl2 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache2.registerClassLoader("/aop", cl2); 
  +      
  +      Class clazz = cl1.loadFoo();
  +      Object custom1 = clazz.newInstance();
  +
  +      clazz = cl2.loadFoo();
  +      Object custom2 = clazz.newInstance();
  +      
  +      Fqn base = Fqn.fromString("/aop");
  +      cache1.put(new Fqn(base, custom1), "key", "value");
  +
  +      try
  +      {
  +         Object val = cache2.get(new Fqn(base, custom2), "key");
  +         assertEquals("value", val);
  +      } catch (Exception ex)
  +      {
  +         fail("Test fails with exception " +ex);
  +      }      
  +   }
  +
      Transaction beginTransaction() throws SystemException, NotSupportedException
      {
  -      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  +      DummyTransactionManager mgr=DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
   
  +   protected Object getPersonFromClassloader(ClassLoader cl) throws Exception
  +   {
  +      Class clazz = cl.loadClass("org.jboss.cache.marshall.Person");
  +      return clazz.newInstance();
  +   }
  +
      void log(String msg)
      {
         System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
  
  
  
  1.12      +52 -15    JBossCache/tests/functional/org/jboss/cache/marshall/AsyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/AsyncReplTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- AsyncReplTest.java	6 Sep 2006 15:30:58 -0000	1.11
  +++ AsyncReplTest.java	5 Dec 2006 23:07:25 -0000	1.12
  @@ -12,6 +12,7 @@
   import junit.framework.Test;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.marshall.data.Address;
  @@ -28,7 +29,7 @@
    * Test marshalling for async mode.
    *
    * @author Ben Wang
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class AsyncReplTest extends RegionBasedMarshallingTestBase
   {
  @@ -156,21 +157,30 @@
      {
         ClassLoader cl = getClassLoader();
         cache1.registerClassLoader("/aop", cl);
  +      // Create an empty Person loaded by this classloader
  +      Object scopedBen1 = getPersonFromClassloader(cl);
  +      
         cl = getClassLoader();
         cache2.registerClassLoader("/aop", cl);
  +      // Create another empty Person loaded by this classloader
  +      Object scopedBen2 = getPersonFromClassloader(cl);
   
         cache1.put("/aop/1", "person", ben_);
  -      cache1.put("/aop/1", "person", ben_);
  +      cache1.put("/aop/2", "person", scopedBen1);
         TestingUtil.sleepThread(1000);
   
  -      Object ben2;
  +      Object ben2 = null;
         try
         {
            // Can't cast it to Person. CCE will resutl.
            ben2 = cache2.get("/aop/1", "person");
            assertEquals(ben_.toString(), ben2.toString());
  -      }
  -      catch (Exception ex)
  +         
  +         ben2 = cache2.get("/aop/2", "person");
  +         assertFalse("cache2 deserialized with scoped classloader", ben2 instanceof Person);
  +         assertFalse("cache2 deserialized with cache2 classloader", scopedBen1.equals(ben2));
  +         assertEquals("scopedBen deserialized properly", scopedBen2, ben2);
  +      } catch (Exception ex)
         {
            fail("Test fails with exception " + ex);
         }
  @@ -251,19 +261,46 @@
         // Need to test out if app is not registered with beforehand??
      }
   
  +   public void testCustomFqn() throws Exception
  +   {
  +      // FIXME work via the Cache API
  +      
  +      FooClassLoader cl1 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache1.registerClassLoader("/aop", cl1);
  +      FooClassLoader cl2 = new FooClassLoader(Thread.currentThread().getContextClassLoader());
  +      cache2.registerClassLoader("/aop", cl2); 
  +      
  +      Class clazz = cl1.loadFoo();
  +      Object custom1 = clazz.newInstance();
  +
  +      clazz = cl2.loadFoo();
  +      Object custom2 = clazz.newInstance();
  +      
  +      Fqn base = Fqn.fromString("/aop");
  +      cache1.put(new Fqn(base, custom1), "key", "value");
  +      TestingUtil.sleepThread(1000);
  +
  +      try
  +      {
  +         Object val = cache2.get(new Fqn(base, custom2), "key");
  +         assertEquals("value", val);
  +      } catch (Exception ex)
  +      {
  +         fail("Test fails with exception " +ex);
  +      }      
  +   }
  +
      Transaction beginTransaction() throws SystemException, NotSupportedException
      {
  -      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  +      DummyTransactionManager mgr=DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
   
  -   protected ClassLoader getClassLoader() throws Exception
  +   protected Object getPersonFromClassloader(ClassLoader cl) throws Exception
      {
  -      String[] includesClasses = {PERSON_CLASSNAME, ADDRESS_CLASSNAME};
  -      String [] excludesClasses = {};
  -      ClassLoader cl = Thread.currentThread().getContextClassLoader();
  -      return new SelectedClassnameClassLoader(includesClasses, excludesClasses, cl);
  +      Class clazz = cl.loadClass(PERSON_CLASSNAME);
  +      return clazz.newInstance();
      }
   
      void log(String msg)
  
  
  
  1.2       +39 -0     JBossCache/tests/functional/org/jboss/cache/marshall/FooClassLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FooClassLoader.java
  ===================================================================
  RCS file: FooClassLoader.java
  diff -N FooClassLoader.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ FooClassLoader.java	5 Dec 2006 23:07:25 -0000	1.2
  @@ -0,0 +1,39 @@
  +package org.jboss.cache.marshall;
  +
  +import java.io.ByteArrayOutputStream;
  +import java.io.IOException;
  +import java.io.InputStream;
  +
  +public class FooClassLoader extends ClassLoader
  +{
  +   private Class foo;
  +   public FooClassLoader(ClassLoader parent)
  +   {
  +      super(parent);
  +   }
  +   
  +   public Class loadFoo() throws ClassNotFoundException
  +   {
  +      if (foo == null)
  +      {
  +         try
  +         {
  +            InputStream is = getResourceAsStream("org/jboss/cache/marshall/Foo.clazz");
  +            byte[] bytes = new byte[1024];                
  +            ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
  +            int read;
  +            while ((read = is.read(bytes)) > -1) {
  +                baos.write(bytes, 0, read);
  +            }
  +            bytes = baos.toByteArray();
  +            foo = this.defineClass("org.jboss.cache.marshall.Foo", bytes, 0, bytes.length);
  +         }
  +         catch (IOException e)
  +         {
  +            throw new ClassNotFoundException("cannot read org/jboss/cache/marshall/Foo.clazz", e);
  +         }
  +      }
  +      return foo;
  +   }
  +
  +}
  
  
  
  1.2       +37 -0     JBossCache/tests/functional/org/jboss/cache/marshall/Foo.notjava
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Foo.notjava
  ===================================================================
  RCS file: Foo.notjava
  diff -N Foo.notjava
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ Foo.notjava	5 Dec 2006 23:07:25 -0000	1.2
  @@ -0,0 +1,37 @@
  +package org.jboss.cache.marshall;
  +
  +import java.io.Serializable;
  +import java.security.SecureRandom;
  +import java.util.Random;
  +
  +/**
  + * This is the java code used to create the Foo.clazz file. File deliberately
  + * doesn't end in .java, as we don't want a Foo.class on the classpath,
  + * only the Foo.clazz file that FooClassLoader can load.
  + * 
  + * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  + * @version $Revision: 1.2 $
  + */
  +public class Foo implements Serializable
  +{
  +   /** The serialVersionUID */
  +   private static final long serialVersionUID = 1L;
  +
  +   public boolean equals(Object obj)
  +   {      
  +      return obj instanceof Foo;
  +   }
  +
  +   public int hashCode()
  +   {
  +      return 1;
  +   }   
  +
  +   public String toString()
  +   {
  +      Random random = new SecureRandom();
  +      StringBuffer sb=new StringBuffer("org.jboss.cache.marshall.Foo[random=");
  +      sb.append(random.nextInt()).append("]");
  +      return sb.toString();
  +   }
  +}
  
  
  
  1.2       +10 -0     JBossCache/tests/functional/org/jboss/cache/marshall/Foo.clazz
  
  	<<Binary file>>
  
  


From Shane_Bryzak at symantec.com  Tue Dec  5 18:19:44 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 05 Dec 2006 18:19:44 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/poker  ...
Message-ID: <E1GrjZg-0000w4-HY@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/05 18:19:44

  Modified:    examples/remoting/poker  build.xml
  Log:
  updated build files
  
  Revision  Changes    Path
  1.2       +6 -61     jboss-seam/examples/remoting/poker/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/poker/build.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- build.xml	11 Oct 2006 04:43:22 -0000	1.1
  +++ build.xml	5 Dec 2006 23:19:44 -0000	1.2
  @@ -6,69 +6,14 @@
       <property name="Name"                   value="Seam Remoting Poker Example"/>
       <property name="example.name"           value="seam-poker"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -     
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -      <include name="META-INF/*"/>
  -      <exclude name="ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../../lib">
  -      <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="_NONE_"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="_NONE_"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +
  +    <property name="example.webinf.lib.dir"  value="."/>
  +	  <property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
  -
  +    <property name="tomcat.conf"             value="eejb.conf"/>
       <import file="../../../build.xml"/>
   
   </project>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec  5 18:19:44 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 05 Dec 2006 18:19:44 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories  ...
Message-ID: <E1GrjZg-0000wB-LK@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/05 18:19:44

  Modified:    examples/remoting/stories  build.xml
  Log:
  updated build files
  
  Revision  Changes    Path
  1.5       +7 -62     jboss-seam/examples/remoting/stories/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/stories/build.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- build.xml	28 May 2006 04:38:35 -0000	1.4
  +++ build.xml	5 Dec 2006 23:19:44 -0000	1.5
  @@ -6,69 +6,14 @@
       <property name="Name"                   value="Seam Stories Example"/>
       <property name="example.name"           value="seam-stories"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -            prefix="WEB-INF/lib"
  -               dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
  -
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="seam.properties"/>
  -    	<include name="META-INF/persistence.xml"/>
  -    	<include name="import.sql"/>
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -      <include name="META-INF/*"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../../lib">
  -      <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="stories-ds.xml"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="stories-ds.xml"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +
  +    <property name="example.webinf.lib.dir"  value="."/>
  +	  <property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
       <property name="src.test.dir" value="src"/>
       <property name="test.classpath" value="test.eejb.classpath"/>
  -
  +    <property name="tomcat.conf"             value="eejb.conf"/>
     <import file="../../../build.xml"/>
   
   </project>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec  5 18:19:44 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 05 Dec 2006 18:19:44 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace  ...
Message-ID: <E1GrjZg-0000wI-Qw@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/05 18:19:44

  Modified:    examples/seamspace  build.xml
  Log:
  updated build files
  
  Revision  Changes    Path
  1.4       +7 -62     jboss-seam/examples/seamspace/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/build.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- build.xml	31 Oct 2006 02:54:36 -0000	1.3
  +++ build.xml	5 Dec 2006 23:19:44 -0000	1.4
  @@ -6,69 +6,14 @@
       <property name="Name"                   value="SeamSpace Security Example"/>
       <property name="example.name"           value="seam-space"/>
   
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -      <include name="**/*"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <patternset refid="meta.files"/>
  -    </zipfileset>
  -     
  -    <zipfileset id="example.war.webinf.lib"
  -            prefix="WEB-INF/lib"
  -               dir="../../facelets/lib">
  -        <include name="*.jar"/>
  -    </zipfileset>
  -    
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="extra.seam.jar"/>    
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root"
  -            dir="resources">
  -        <include name="import.sql"/>
  -        <include name="seam.properties"/>
  -        <include name="META-INF/ejb-jar.xml"/>
  -        <include name="META-INF/persistence.xml"/>  
  -    </fileset>
  -
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources"
  -            dir="resources">
  -      <include name="META-INF/*"/>
  -      <exclude name="ejb-jar.xml"/>
  -    </zipfileset>
  -
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -      <include name="_NONE_"/>
  -    </fileset>
  -  
  -	<!-- Test -->
  -	<fileset id="example.resources" dir="resources">
  -		<include name="**/*.*"/>
  -	</fileset>
  -
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -      <include name="seamspace-ds.xml"/>
  -    </fileset>
  -
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -      <include name="booking-ds.xml"/>
  -    </patternset>
  -
       <!-- Overrides -->
  +
  +    <property name="example.webinf.lib.dir"  value="."/>
  +	  <property name="example.facelets.lib"    value="yes"/>
       <property name="src.java.dir" value="src"/>
   	<property name="src.test.dir" value="src"/>
   	<property name="test.classpath" value="test.eejb.classpath"/>
  -
  +    <property name="tomcat.conf"             value="eejb.conf"/>
     <import file="../../build.xml"/>
   
   </project>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec  5 18:19:45 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 05 Dec 2006 18:19:45 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF  ...
Message-ID: <E1GrjZh-0000wP-0d@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/05 18:19:45

  Modified:    examples/seamspace/resources/WEB-INF  web.xml
  Log:
  updated build files
  
  Revision  Changes    Path
  1.2       +9 -9      jboss-seam/examples/seamspace/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/web.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  
  
  


From brian.stansberry at jboss.com  Tue Dec  5 18:33:48 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Tue, 05 Dec 2006 18:33:48 -0500
Subject: [jboss-cvs] JBossCache/etc/META-INF    ...
Message-ID: <E1GrjnI-0001Du-3Y@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/05 18:33:48

  Modified:    etc/META-INF    Tag: Branch_JBossCache_1_4_0
                        replAsync-optimistic-service.xml
                        replAsync-service.xml
                        replAsyncSharedCacheLoader-service.xml
  Log:
  Add FC
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.1   +3 -2      JBossCache/etc/META-INF/replAsync-optimistic-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsync-optimistic-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsync-optimistic-service.xml,v
  retrieving revision 1.8
  retrieving revision 1.8.2.1
  diff -u -b -r1.8 -r1.8.2.1
  --- replAsync-optimistic-service.xml	11 May 2006 00:01:00 -0000	1.8
  +++ replAsync-optimistic-service.xml	5 Dec 2006 23:33:48 -0000	1.8.2.1
  @@ -104,10 +104,11 @@
                       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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  
  1.7.2.1   +3 -2      JBossCache/etc/META-INF/replAsync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsync-service.xml,v
  retrieving revision 1.7
  retrieving revision 1.7.2.1
  diff -u -b -r1.7 -r1.7.2.1
  --- replAsync-service.xml	11 May 2006 00:01:00 -0000	1.7
  +++ replAsync-service.xml	5 Dec 2006 23:33:48 -0000	1.7.2.1
  @@ -94,10 +94,11 @@
                       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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  
  1.9.2.1   +3 -2      JBossCache/etc/META-INF/replAsyncSharedCacheLoader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsyncSharedCacheLoader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsyncSharedCacheLoader-service.xml,v
  retrieving revision 1.9
  retrieving revision 1.9.2.1
  diff -u -b -r1.9 -r1.9.2.1
  --- replAsyncSharedCacheLoader-service.xml	30 May 2006 18:40:24 -0000	1.9
  +++ replAsyncSharedCacheLoader-service.xml	5 Dec 2006 23:33:48 -0000	1.9.2.1
  @@ -94,10 +94,11 @@
                       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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  


From brian.stansberry at jboss.com  Tue Dec  5 18:35:41 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Tue, 05 Dec 2006 18:35:41 -0500
Subject: [jboss-cvs] JBossCache/etc/META-INF    ...
Message-ID: <E1Grjp7-0001Fm-QD@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/05 18:35:41

  Modified:    etc/META-INF    replAsync-optimistic-service.xml
                        replAsync-service.xml
                        replAsyncSharedCacheLoader-service.xml
  Log:
  Add FC
  
  Revision  Changes    Path
  1.12      +3 -2      JBossCache/etc/META-INF/replAsync-optimistic-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsync-optimistic-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsync-optimistic-service.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- replAsync-optimistic-service.xml	21 Sep 2006 15:08:39 -0000	1.11
  +++ replAsync-optimistic-service.xml	5 Dec 2006 23:35:41 -0000	1.12
  @@ -110,10 +110,11 @@
                   <UNICAST timeout="600,1200,2400" 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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  
  1.12      +2 -0      JBossCache/etc/META-INF/replAsync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsync-service.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- replAsync-service.xml	14 Nov 2006 19:56:09 -0000	1.11
  +++ replAsync-service.xml	5 Dec 2006 23:35:41 -0000	1.12
  @@ -120,6 +120,8 @@
                           down_thread="false" up_thread="false"
                           join_retry_timeout="2000" shun="false"
                           view_bundling="true"/>
  +            <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
               <FRAG2 frag_size="60000" down_thread="false" up_thread="false"/>
               <!-- <pbcast.STREAMING_STATE_TRANSFER down_thread="false" up_thread="false" use_reading_thread="true"/> -->
               <pbcast.STATE_TRANSFER down_thread="false" up_thread="false"/>
  
  
  
  1.13      +3 -2      JBossCache/etc/META-INF/replAsyncSharedCacheLoader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsyncSharedCacheLoader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsyncSharedCacheLoader-service.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- replAsyncSharedCacheLoader-service.xml	21 Sep 2006 15:08:39 -0000	1.12
  +++ replAsyncSharedCacheLoader-service.xml	5 Dec 2006 23:35:41 -0000	1.13
  @@ -100,10 +100,11 @@
                   <UNICAST timeout="600,1200,2400" 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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  


From brian.stansberry at jboss.com  Tue Dec  5 18:36:24 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Tue, 05 Dec 2006 18:36:24 -0500
Subject: [jboss-cvs] JBossCache/etc/META-INF  ...
Message-ID: <E1Grjpo-0001Gj-Vk@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/05 18:36:24

  Modified:    etc/META-INF 
                        optimal-for-large-cluster-http-session-repl.xml
  Log:
  Add FC
  
  Revision  Changes    Path
  1.12      +3 -2      JBossCache/etc/META-INF/optimal-for-large-cluster-http-session-repl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: optimal-for-large-cluster-http-session-repl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/optimal-for-large-cluster-http-session-repl.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- optimal-for-large-cluster-http-session-repl.xml	21 Sep 2006 15:08:39 -0000	1.11
  +++ optimal-for-large-cluster-http-session-repl.xml	5 Dec 2006 23:36:24 -0000	1.12
  @@ -103,10 +103,11 @@
                   <UNICAST timeout="600,1200,2400" 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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  


From brian.stansberry at jboss.com  Tue Dec  5 18:37:10 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Tue, 05 Dec 2006 18:37:10 -0500
Subject: [jboss-cvs] JBossCache/etc/META-INF  ...
Message-ID: <E1GrjqY-0001Hv-GK@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/05 18:37:10

  Modified:    etc/META-INF  Tag: Branch_JBossCache_1_4_0
                        optimal-for-large-cluster-http-session-repl.xml
  Log:
  Add FC
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.1   +3 -2      JBossCache/etc/META-INF/optimal-for-large-cluster-http-session-repl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: optimal-for-large-cluster-http-session-repl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/optimal-for-large-cluster-http-session-repl.xml,v
  retrieving revision 1.8
  retrieving revision 1.8.2.1
  diff -u -b -r1.8 -r1.8.2.1
  --- optimal-for-large-cluster-http-session-repl.xml	30 May 2006 18:40:24 -0000	1.8
  +++ optimal-for-large-cluster-http-session-repl.xml	5 Dec 2006 23:37:10 -0000	1.8.2.1
  @@ -97,10 +97,11 @@
                       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"/>
  +                <FC max_credits="2000000" down_thread="false" up_thread="false"
  +                    min_threshold="0.20"/>
  +                <FRAG frag_size="8192" down_thread="false" up_thread="true"/>
                   <pbcast.STATE_TRANSFER up_thread="true" down_thread="true"/>
               </config>
           </attribute>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 18:50:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 18:50:09 -0500
Subject: [jboss-cvs] JBossBlog SVN: r37 - in trunk: .
	blog-core/src/etc/META-INF
	blog-core/src/java/org/jboss/blog/model/impl
	blog-core/src/java/org/jboss/blog/service/store/hibernate
	blog-core/src/java/org/jboss/blog/service/store/model
	blog-core/src/java/org/jboss/blog/ui
	blog-core/src/web/WEB-INF blog-core/src/web/views
Message-ID: <E1Grk37-0001Xp-U7@committer01.frg.pub.inap.atl.jboss.com>

Author: adamw
Date: 2006-12-05 18:49:59 -0500 (Tue, 05 Dec 2006)
New Revision: 37

Added:
   trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java
   trunk/blog-core/src/web/views/comment_del.xhtml
Modified:
   trunk/blog-core/src/etc/META-INF/acl-mapping.xml
   trunk/blog-core/src/etc/META-INF/acl-permissions.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
   trunk/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java
   trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java
   trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java
   trunk/blog-core/src/web/WEB-INF/faces-config.xml
   trunk/jbossblog.iws
Log:
http://jira.jboss.com/jira/browse/JBBLOG-13

Modified: trunk/blog-core/src/etc/META-INF/acl-mapping.xml
===================================================================
--- trunk/blog-core/src/etc/META-INF/acl-mapping.xml	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/etc/META-INF/acl-mapping.xml	2006-12-05 23:49:59 UTC (rev 37)
@@ -88,10 +88,11 @@
 				<id>acl://addComment</id>
 			</resource>
 			<!-- action protection -->
-			<!--<resource type="jsfAction" criteriaId="addComment://action">
-				<class>org.jboss.blog.ui.action.NewTopic</class>
-				<method>execute</method>
-			</resource>-->
+			<resource type="jsfAction" criteriaId="addComment://action">
+				<class>org.jboss.blog.ui.CommentEdit</class>
+				<method>saveNew</method>
+			</resource>
+            <implies>viewCategory</implies>
             <implies>viewComment</implies>
         </function>
 	</module>		
@@ -104,10 +105,10 @@
 				<id>acl://manageComment</id>
 			</resource>
 			<!-- action protection -->
-			<!--<resource type="jsfAction" criteriaId="manageComments://action">				
-				<class>org.jboss.portlet.Blogs.ui.action.ModeratorAction</class>
-				<method>manageComments</method>
-			</resource>-->
+			<resource type="jsfAction" criteriaId="manageComment://action">
+				<class>org.jboss.blog.ui.CommentEdit</class>
+				<method>delete</method>
+			</resource>
 		</function>
 
         <function id="managePost" name="Manage Post">

Modified: trunk/blog-core/src/etc/META-INF/acl-permissions.xml
===================================================================
--- trunk/blog-core/src/etc/META-INF/acl-permissions.xml	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/etc/META-INF/acl-permissions.xml	2006-12-05 23:49:59 UTC (rev 37)
@@ -28,7 +28,7 @@
 		<!--permission action="readCategory">
 			<criteria for="readCategory://ui">param[0].title.toLowerCase().startsWith('unit testing')</criteria>
 		</permission-->	
-		<permission action="viewComment"/>
+		<permission action="viewComment" />
         <!--<permission action="managePost"/>-->
 
         <!--<permission action="manageCategory"/>-->
@@ -43,8 +43,8 @@
 		<!-- Admin Module permissions -->
 		
 		<!-- User Module permissions -->
-		<permission action="addComment"/>
-		<!-- permission to edit only my own posts -->
+        <permission action="addComment" />
+        <!-- permission to edit only my own posts -->
 		<!--<permission action="editPost">
 			<criteria for="editPost://ui">param[0].poster.user.userName.equals(identity.identity.userName)</criteria>
 			<criteria for="editPost://action">target.post.poster.user.userName.equals(identity.identity.userName)</criteria>
@@ -62,7 +62,7 @@
 		<!-- Owner Module permissions -->
 		
 		<!-- wild card permission -->
-		<permission action="all"/>		
+		<permission action="all" />
 	</role>		
 	
 	<!-- 

Added: trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -0,0 +1,12 @@
+package org.jboss.blog.model.impl;
+
+import java.util.Date;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class EmptyBlogComment extends BlogCommentImpl {
+    public EmptyBlogComment() {
+        super("", "", "", new Date(), "");
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -4,6 +4,7 @@
 import org.jboss.blog.service.store.model.ModifiableBlogComment;
 
 import java.util.Date;
+import java.io.Serializable;
 
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
@@ -21,6 +22,10 @@
 
     }
 
+    public Serializable getCommentId() {
+        return getId();
+    }
+
     public Integer getId() {
         return id;
     }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -8,6 +8,7 @@
 import org.jboss.blog.tools.BlogTools;
 
 import java.util.*;
+import java.io.Serializable;
 
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
@@ -160,4 +161,9 @@
 
         return (ModifiableBlogComment) comment;
     }
+
+    public ModifiableBlogComment getModifiableBlogComment(Serializable id)
+            throws BlogCommentDoesNotExistException {
+        return getStoreService().getComment(id);
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -8,6 +8,7 @@
 import org.jboss.blog.service.AbstractBlogService;
 import org.jboss.blog.BlogName;
 import org.jboss.blog.model.BlogModelDoesNotExistException;
+import org.jboss.blog.model.BlogCommentDoesNotExistException;
 import org.jboss.blog.tools.BlogTools;
 import org.hibernate.SessionFactory;
 import org.hibernate.cfg.Configuration;
@@ -15,6 +16,7 @@
 import java.util.List;
 import java.util.ArrayList;
 import java.util.Iterator;
+import java.io.Serializable;
 
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
@@ -360,4 +362,21 @@
 
         return ret;
     }
+
+    /**
+     * Gets a comment with the specified id.
+     * @param id Unique id of the comment to get.
+     * @return Comment with the given id.
+     * @throws BlogCommentDoesNotExistException If a comment with the given id does
+     * not exist.
+     */
+    HBlogComment getComment(Serializable id) throws BlogCommentDoesNotExistException {
+        HBlogComment ret = (HBlogComment) sf.getCurrentSession().get(HBlogComment.class, id);
+
+        if (ret == null) {
+            throw new BlogCommentDoesNotExistException(id.toString());
+        }
+
+        return ret;
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -2,8 +2,19 @@
 
 import org.jboss.blog.model.BlogComment;
 
+import java.io.Serializable;
+
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
 public interface ModifiableBlogComment extends ModifiableBlogItem, BlogComment {
+    /**
+     * Gets a unique id identifing this object. The comment returned
+     * by the {@link ModifiableBlogPost#getModifiableBlogComment(Object)}
+     * should be representing the same comment. Shouldn't be called on
+     * new comment, which aren't yet added to a blog post (or are added to
+     * a blog post which is itself not yet in any model).
+     * @return A unique id of this comment.
+     */
+    public Serializable getCommentId();
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -4,6 +4,8 @@
 import org.jboss.blog.model.BlogComment;
 import org.jboss.blog.model.BlogCommentDoesNotExistException;
 
+import java.io.Serializable;
+
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
@@ -32,4 +34,16 @@
      */
     public ModifiableBlogComment getModifiableBlogComment(BlogComment comment)
             throws BlogCommentDoesNotExistException;
+
+    /**
+     * Given a blog comment id, gets an object representing it.
+     * @param id Unique id of the comment to get.
+     * @return Comment with the given id. So,
+     * {@link ModifiableBlogComment#getCommentId()} should return the
+     * given id.
+     * @throws BlogCommentDoesNotExistException If a blog comment with the
+     * given id does not exist.
+     */
+    public ModifiableBlogComment getModifiableBlogComment(Serializable id)
+            throws BlogCommentDoesNotExistException;
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -7,6 +7,8 @@
 import org.jboss.blog.model.impl.EmptyBlogPost;
 import org.jboss.blog.model.impl.EmptyBlogModel;
 import org.jboss.blog.BlogName;
+import org.jboss.blog.service.store.model.ModifiableBlogPost;
+import org.jboss.blog.service.store.model.ModifiableBlogModel;
 import org.jboss.blog.tools.BlogTools;
 import org.jboss.blog.tools.UITools;
 
@@ -230,6 +232,17 @@
         return new EmptyBlogPost();
     }
 
+    ModifiableBlogModel getModifiableModel() throws BlogModelDoesNotExistException {
+        return BlogTools.getBlogService().getStoreService().getBlogModel(
+                getBlogName());
+    }
+
+    ModifiableBlogPost getModifiableSelectedPost()
+            throws BlogPostDoesNotExistException, BlogModelDoesNotExistException {        
+        return getModifiableModel().getModifiableBlogPostByTitleAsId(
+                getSelectedPostTitleAsId());
+    }
+
     public BlogPost getSelectedPost() {
         String titleAsId = getSelectedPostTitleAsId();
 

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -1,5 +1,7 @@
 package org.jboss.blog.ui;
 
+import java.io.Serializable;
+
 /**
  * A view state of one specific blog:
  * - number of a post that should be shown as the first one
@@ -9,6 +11,7 @@
 public class BlogViewState {
     private int from;
     private String selectedPostTitleAsId;
+    private Serializable selectedCommentId;
 
     public BlogViewState() {
         from = 0;
@@ -29,4 +32,12 @@
     public void setSelectedPostTitleAsId(String selectedPostTitleAsId) {
         this.selectedPostTitleAsId = selectedPostTitleAsId;
     }
+
+    public Serializable getSelectedCommentId() {
+        return selectedCommentId;
+    }
+
+    public void setSelectedCommentId(Serializable selectedCommentId) {
+        this.selectedCommentId = selectedCommentId;
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -2,10 +2,10 @@
 
 import org.jboss.blog.tools.BlogTools;
 import org.jboss.blog.tools.UITools;
-import org.jboss.blog.service.store.model.ModifiableBlogModel;
 import org.jboss.blog.service.store.model.ModifiableBlogPost;
 import org.jboss.blog.service.store.model.ModifiableBlogComment;
 import org.jboss.blog.model.*;
+import org.jboss.blog.model.impl.EmptyBlogComment;
 
 import javax.faces.component.UIData;
 import java.util.*;
@@ -67,14 +67,28 @@
 
     // Actions
 
-    private ModifiableBlogPost getPost() throws BlogPostDoesNotExistException,
-            BlogModelDoesNotExistException {
-        ModifiableBlogModel model = BlogTools.getBlogService().getStoreService().getBlogModel(
-                blogView.getBlogName());
-        return model.getModifiableBlogPostByTitleAsId(
-                blogView.getSelectedPostTitleAsId());
+    private ModifiableBlogComment getComment() throws BlogCommentDoesNotExistException,
+            BlogModelDoesNotExistException, BlogPostDoesNotExistException {
+        ModifiableBlogPost post = blogView.getModifiableSelectedPost();
+
+        BlogComment notModifiableComment = (BlogComment) commentsData.getRowData();
+        return post.getModifiableBlogComment(notModifiableComment);
     }
 
+    private ModifiableBlogComment getSelectedModifiableComment()
+            throws BlogModelDoesNotExistException, BlogPostDoesNotExistException, BlogCommentDoesNotExistException {
+        return blogView.getModifiableSelectedPost().getModifiableBlogComment(
+                    blogView.getBlogViewState().getSelectedCommentId());
+    }
+
+    public BlogComment getSelectedComment() {
+        try {
+            return getSelectedModifiableComment();
+        } catch (Exception e) {
+            return new EmptyBlogComment();
+        } 
+    }
+
     public String saveNew() {
         try {
             ModifiableBlogComment comment;
@@ -87,11 +101,11 @@
             comment.setDescription(description);
             comment.setCreated(new Date());
 
-            ModifiableBlogPost post = getPost();
+            ModifiableBlogPost post = blogView.getModifiableSelectedPost();
 
             post.addComment(comment);
 
-            UITools.addInfoMessage("New comment saved.");
+            UITools.addInfoMessage("New comment added.");
         } catch (BlogModelDoesNotExistException e) {
             UITools.addMessageBlogDoesntExist(blogView.getBlogName());
         } catch (BlogPostDoesNotExistException e) {
@@ -103,9 +117,7 @@
 
     public String delete() {
         try {
-            ModifiableBlogPost post = getPost();
-            BlogComment notModifiableComment = (BlogComment) commentsData.getRowData();
-            ModifiableBlogComment comment = post.getModifiableBlogComment(notModifiableComment);
+            ModifiableBlogComment comment = getSelectedModifiableComment();
 
             BlogTools.getBlogService().getStoreService().deleteComment(comment);
 
@@ -119,10 +131,23 @@
         }
 
         return UITools.POST_VIEW;
+    }
 
+    public String commentDelete() {
+        try {
+            blogView.getBlogViewState().setSelectedCommentId(getComment().getCommentId());
+        } catch (BlogModelDoesNotExistException e) {
+            UITools.addMessageBlogDoesntExist(blogView.getBlogName());
+        } catch (BlogPostDoesNotExistException e) {
+            UITools.addMessagePostDoesntExist(blogView.getSelectedPostTitleAsId());
+        } catch (BlogCommentDoesNotExistException e) {
+            UITools.addMessageCommentDoesntExist();
+        }
+
+        return UITools.COMMENT_DEL;
     }
 
-    public String back() {
-        return blogView.getReturnTo();
+    public String backFromDelete() {
+        return UITools.POST_VIEW;
     }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java	2006-12-05 23:49:59 UTC (rev 37)
@@ -226,10 +226,8 @@
         removedCategories.removeAll(selectedCategories);
 
         try {
-            ModifiableBlogModel model = BlogTools.getBlogService().getStoreService().getBlogModel(
-                    blogView.getBlogName());
-            ModifiableBlogPost post = model.getModifiableBlogPostByTitleAsId(
-                    blogView.getSelectedPostTitleAsId());
+            ModifiableBlogModel model;
+            ModifiableBlogPost post = blogView.getModifiableSelectedPost();
 
             boolean changed = false;
 

Modified: trunk/blog-core/src/web/WEB-INF/faces-config.xml
===================================================================
--- trunk/blog-core/src/web/WEB-INF/faces-config.xml	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/web/WEB-INF/faces-config.xml	2006-12-05 23:49:59 UTC (rev 37)
@@ -131,6 +131,16 @@
         </navigation-case>
     </navigation-rule>
 
+    <!-- Comment del -->
+
+    <navigation-rule>
+        <from-view-id>/views/post_view.xhtml</from-view-id>
+        <navigation-case>
+            <from-outcome>comment_del</from-outcome>
+            <to-view-id>/views/comment_del.xhtml</to-view-id>
+        </navigation-case>
+    </navigation-rule>
+
     <!-- Admin -->
     <navigation-rule>
         <from-view-id>/views/index.xhtml</from-view-id>

Added: trunk/blog-core/src/web/views/comment_del.xhtml
===================================================================
--- trunk/blog-core/src/web/views/comment_del.xhtml	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/blog-core/src/web/views/comment_del.xhtml	2006-12-05 23:49:59 UTC (rev 37)
@@ -0,0 +1,26 @@
+<div  xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:ui="http://java.sun.com/jsf/facelets"
+      xmlns:c="http://java.sun.com/jstl/core"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:blog="http://www.jboss.org/portal/jbossblog">
+    <ui:composition template="del_confirm.xhtml">
+        <ui:param name="requiredPermission" value="acl://manageBlog" />
+
+        <ui:define name="delname">
+            comment
+        </ui:define>
+
+        <ui:define name="delsubject">
+            #{commentEdit.selectedComment.title}
+        </ui:define>
+
+        <ui:define name="cancellink">
+            <h:commandLink value="No" action="#{commentEdit.backFromDelete}" />
+        </ui:define>
+
+        <ui:define name="deletelink">
+            <h:commandLink value="Yes" action="#{commentEdit.delete}" />
+        </ui:define>
+    </ui:composition>
+</div>
\ No newline at end of file

Modified: trunk/jbossblog.iws
===================================================================
--- trunk/jbossblog.iws	2006-12-04 22:37:40 UTC (rev 36)
+++ trunk/jbossblog.iws	2006-12-05 23:49:59 UTC (rev 37)
@@ -17,15 +17,20 @@
   </component>
   <component name="ChangeListManager">
     <list default="true" name="Default" comment="">
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/blog.css" afterPath="$PROJECT_DIR$/blog-core/src/web/blog.css" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogCommentDoesNotExistException.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools/UITools.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools/UITools.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/web/views/comment_del.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml" />
     </list>
   </component>
   <component name="ChangeListSynchronizer" />
@@ -150,10 +155,10 @@
   </component>
   <component name="FileEditorManager">
     <leaf>
-      <file leaf-file-name="post_view.xhtml" pinned="false" current="true" current-in-tab="true">
+      <file leaf-file-name="post_view.xhtml" pinned="false" current="false" current-in-tab="false">
         <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="47" column="52" selection-start="1877" selection-end="1877" vertical-scroll-proportion="0.23154363">
+            <state line="17" column="64" selection-start="818" selection-end="818" vertical-scroll-proportion="0.44117647">
               <folding />
             </state>
           </provider>
@@ -162,81 +167,87 @@
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="blog.css" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/web/blog.css">
+      <file leaf-file-name="AclBlogPermissionsService.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="63" column="29" selection-start="753" selection-end="753" vertical-scroll-proportion="1.1623794">
+            <state line="31" column="40" selection-start="1141" selection-end="1141" vertical-scroll-proportion="0.4074703">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="CommentEdit.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
+      <file leaf-file-name="JBossPortalUtil.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/JBossPortalUtil.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="68" column="5" selection-start="1465" selection-end="1465" vertical-scroll-proportion="0.19292605">
-              <folding>
-                <element signature="imports" expanded="true" />
-              </folding>
+            <state line="54" column="23" selection-start="1481" selection-end="1481" vertical-scroll-proportion="0.34271523">
+              <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="BlogView.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
+      <file leaf-file-name="comment_del.xhtml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/comment_del.xhtml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="36" column="5" selection-start="984" selection-end="984" vertical-scroll-proportion="-4.869775">
+            <state line="14" column="47" selection-start="572" selection-end="572" vertical-scroll-proportion="0.3633218">
               <folding />
             </state>
           </provider>
+          <provider editor-type-id="HtmlPreview">
+            <state />
+          </provider>
         </entry>
       </file>
-      <file leaf-file-name="ModifiableBlogComment.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java">
+      <file leaf-file-name="CommentEdit.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="7" column="71" selection-start="225" selection-end="225" vertical-scroll-proportion="0.1688103">
+            <state line="107" column="53" selection-start="2908" selection-end="2908" vertical-scroll-proportion="0.5925297">
+              <folding>
+                <element signature="imports" expanded="true" />
+              </folding>
+            </state>
+          </provider>
+        </entry>
+      </file>
+      <file leaf-file-name="acl-permissions.xml" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
+          <provider selected="true" editor-type-id="text-editor">
+            <state line="44" column="40" selection-start="1646" selection-end="1646" vertical-scroll-proportion="0.7385399">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="faces-config.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml">
-          <provider editor-type-id="com.intellij.jsf.yfilesGraph.editor.FacesNavigationFileEditorProvider">
-            <state />
-          </provider>
+      <file leaf-file-name="acl-mapping.xml" pinned="false" current="true" current-in-tab="true">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="68" column="32" selection-start="2584" selection-end="2584" vertical-scroll-proportion="0.55421686">
+            <state line="88" column="47" selection-start="3790" selection-end="3790" vertical-scroll-proportion="0.61799663">
               <folding />
             </state>
           </provider>
-          <provider editor-type-id="com.intellij.jsf.ui.FacesConfigEditorProvider">
-            <state />
-          </provider>
         </entry>
       </file>
-      <file leaf-file-name="AbstractBlogPost.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
+      <file leaf-file-name="PostEdit.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
+            <state line="228" column="37" selection-start="6439" selection-end="6439" vertical-scroll-proportion="0.23089983">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogPost.hbm.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
+      <file leaf-file-name="BlogView.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
+            <state line="237" column="29" selection-start="6827" selection-end="6827" vertical-scroll-proportion="0.6258278">
               <folding />
             </state>
           </provider>
         </entry>
       </file>
-      <file leaf-file-name="HBlogComment.hbm.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml">
+      <file leaf-file-name="HibernateBlogStoreService.java" pinned="false" current="false" current-in-tab="false">
+        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
           <provider selected="true" editor-type-id="text-editor">
-            <state line="14" column="15" selection-start="525" selection-end="525" vertical-scroll-proportion="0.3376206">
+            <state line="370" column="17" selection-start="13065" selection-end="13065" vertical-scroll-proportion="0.9524618">
               <folding />
             </state>
           </provider>
@@ -470,6 +481,10 @@
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/security/acl" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -725,6 +740,86 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -781,6 +876,44 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/etc" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -854,7 +987,7 @@
       <showLibraryContents />
       <hideEmptyPackages />
       <abbreviatePackageNames />
-      <showStructure Favorites="false" PackagesPane="false" Scope="false" ProjectPane="false" />
+      <showStructure ProjectPane="false" PackagesPane="false" Scope="false" Favorites="false" />
       <autoscrollToSource />
       <autoscrollFromSource />
       <sortByType />
@@ -910,16 +1043,6 @@
       <option name="HOST" value="localhost" />
       <option name="PORT" value="5005" />
     </configuration>
-    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
-      <option name="MAIN_CLASS_NAME" />
-      <option name="VM_PARAMETERS" />
-      <option name="PROGRAM_PARAMETERS" />
-      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-      <option name="ENABLE_SWING_INSPECTOR" value="false" />
-      <module name="" />
-    </configuration>
     <configuration default="true" type="JUnit" factoryName="JUnit" enabled="false" merge="false">
       <module name="" />
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
@@ -939,6 +1062,16 @@
         <option name="Make" value="true" />
       </method>
     </configuration>
+    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
+      <option name="MAIN_CLASS_NAME" />
+      <option name="VM_PARAMETERS" />
+      <option name="PROGRAM_PARAMETERS" />
+      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
+      <option name="ALTERNATIVE_JRE_PATH" />
+      <option name="ENABLE_SWING_INSPECTOR" value="false" />
+      <module name="" />
+    </configuration>
   </component>
   <component name="ScopeViewComponent">
     <subPane subId="Project">
@@ -1017,7 +1150,7 @@
   </component>
   <component name="ToolWindowManager">
     <frame x="0" y="25" width="1690" height="1004" extended-state="6" />
-    <editor active="false" />
+    <editor active="true" />
     <layout>
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="13" />
@@ -1026,7 +1159,7 @@
       <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26118946" order="0" />
       <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32839224" order="1" />
       <window_info id="Structure" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24367674" order="7" />
-      <window_info id="Messages" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
+      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.39977092" order="6" />
       <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="4" />
       <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="10" />
@@ -1135,130 +1268,124 @@
     <option name="myLastEditedConfigurable" value="Project Default" />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="91" column="40" selection-start="3490" selection-end="3490" vertical-scroll-proportion="0.48913044">
+        <state line="9" column="41" selection-start="256" selection-end="256" vertical-scroll-proportion="0.16304348">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/id_edit.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="22" column="44" selection-start="853" selection-end="853" vertical-scroll-proportion="0.37037036">
+        <state line="47" column="70" selection-start="2207" selection-end="2207" vertical-scroll-proportion="0.97231835">
           <folding />
         </state>
       </provider>
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="142" column="62" selection-start="3504" selection-end="3504" vertical-scroll-proportion="0.2210145">
+        <state line="237" column="29" selection-start="6827" selection-end="6827" vertical-scroll-proportion="0.6258278">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="14" column="66" selection-start="495" selection-end="495" vertical-scroll-proportion="0.3376206">
+        <state line="228" column="37" selection-start="6439" selection-end="6439" vertical-scroll-proportion="0.23089983">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/comment_del.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="152" column="5" selection-start="3620" selection-end="3620" vertical-scroll-proportion="0.692029">
+        <state line="14" column="47" selection-start="572" selection-end="572" vertical-scroll-proportion="0.3633218">
           <folding />
         </state>
       </provider>
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools/UITools.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/view.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="46" column="50" selection-start="1718" selection-end="1718" vertical-scroll-proportion="0.7789855">
+        <state line="15" column="43" selection-start="834" selection-end="834" vertical-scroll-proportion="0.38726333">
           <folding />
         </state>
       </provider>
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/security/acl/AclKernelFactory.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="36" column="5" selection-start="984" selection-end="984" vertical-scroll-proportion="-4.869775">
+        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml">
-      <provider editor-type-id="com.intellij.jsf.yfilesGraph.editor.FacesNavigationFileEditorProvider">
-        <state />
-      </provider>
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/ACLTagHandler.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="68" column="32" selection-start="2584" selection-end="2584" vertical-scroll-proportion="0.55421686">
+        <state line="106" column="48" selection-start="3564" selection-end="3564" vertical-scroll-proportion="0.6425041">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="com.intellij.jsf.ui.FacesConfigEditorProvider">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="68" column="5" selection-start="1465" selection-end="1465" vertical-scroll-proportion="0.19292605">
-          <folding>
-            <element signature="imports" expanded="true" />
-          </folding>
+        <state line="17" column="64" selection-start="818" selection-end="818" vertical-scroll-proportion="0.44117647">
+          <folding />
         </state>
       </provider>
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/JBossPortalUtil.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="33" column="9" selection-start="1173" selection-end="1173" vertical-scroll-proportion="0.79581994">
+        <state line="54" column="23" selection-start="1481" selection-end="1481" vertical-scroll-proportion="0.34271523">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_edit.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="370" column="17" selection-start="13065" selection-end="13065" vertical-scroll-proportion="0.9524618">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_new.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="31" column="40" selection-start="1141" selection-end="1141" vertical-scroll-proportion="0.4074703">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="64" column="16" selection-start="2836" selection-end="2965" vertical-scroll-proportion="0.59731543">
-          <folding />
+        <state line="107" column="53" selection-start="2908" selection-end="2908" vertical-scroll-proportion="0.5925297">
+          <folding>
+            <element signature="imports" expanded="true" />
+          </folding>
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/blog.css">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="63" column="29" selection-start="753" selection-end="753" vertical-scroll-proportion="1.1623794">
+        <state line="44" column="40" selection-start="1646" selection-end="1646" vertical-scroll-proportion="0.7385399">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="47" column="52" selection-start="1877" selection-end="1877" vertical-scroll-proportion="0.23154363">
+        <state line="88" column="47" selection-start="3790" selection-end="3790" vertical-scroll-proportion="0.61799663">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
   </component>
 </project>



From jboss-cvs-commits at lists.jboss.org  Tue Dec  5 21:07:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 05 Dec 2006 21:07:11 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1710 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GrmBj-0004FD-4M@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-05 21:07:06 -0500 (Tue, 05 Dec 2006)
New Revision: 1710

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Fixing ClusteredClientConnectionFactoryDelegate and other stuff

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-05 18:38:08 UTC (rev 1709)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-06 02:07:06 UTC (rev 1710)
@@ -73,7 +73,10 @@
 
       for (int i = 0; i < delegates.length; i++)
       {
-         delegates[i].init();
+         if (this!=delegates[i])
+         {
+            delegates[i].init();
+         }
       }
 
       // We add this to the meta data so the failOver aspect can get access to it
@@ -102,6 +105,11 @@
       return delegates;
    }
 
+   public String toString()
+   {
+      return "ClusteredClientConnectionFactoryDelegate[" + id + "] with delegates.length = " + (delegates==null?"null":Integer.toString(delegates.length));
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-05 18:38:08 UTC (rev 1709)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-06 02:07:06 UTC (rev 1710)
@@ -119,8 +119,6 @@
       
       ClientConnectionFactoryDelegate delegate = null;
       
-      boolean replicateChanges = false;
-      
       if (clustered)
       {
          setupReplicator();
@@ -138,25 +136,23 @@
          //Local
          delegate = new ClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
       }
-      
+
+      log.trace("Adding delegates factory " + uniqueName + " pointing to " + delegate);
       delegates.put(uniqueName, delegate);
-      
+
       //Now bind it in JNDI
       rebindConnectionFactory(initialContext, jndiBindings, delegate);
       
-      if (replicateChanges)
-      {
-         // We are clustered, we need to propagate the local delegate across the cluster.
+      // We are clustered, we need to propagate the local delegate across the cluster.
 
-         // ... and then update it (and the clustered delegate on every node, while we're at it) by
-         // replicating the local delegate across the cluster. This way, the clustred delegates on each
-         // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
-         // will rebind updated ConnectionFactories in JNDI.
-         // This will update the local node too
+      // ... and then update it (and the clustered delegate on every node, while we're at it) by
+      // replicating the local delegate across the cluster. This way, the clustred delegates on each
+      // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
+      // will rebind updated ConnectionFactories in JNDI.
+      // This will update the local node too
 
-         replicator.put(CF_PREFIX + uniqueName, delegate);
-      }
-            
+      replicator.put(CF_PREFIX + uniqueName, delegate);
+
       //Registering with the dispatcher should always be the last thing otherwise a client could use
       //a partially initialised object
       JMSDispatcher.instance.registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
@@ -164,6 +160,7 @@
    
    public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception
    {
+      log.trace("ConnectionFactory " + uniqueName + " being unregistered");
       ServerConnectionFactoryEndpoint endpoint =
          (ServerConnectionFactoryEndpoint)endpoints.remove(uniqueName);
       
@@ -184,7 +181,7 @@
             log.debug(jndiName + " unregistered");
          }
       }
-      
+
       ClientConnectionFactoryDelegate delegate =
          (ClientConnectionFactoryDelegate)delegates.remove(uniqueName);
       
@@ -248,6 +245,7 @@
    
    public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap)
    {
+      log.info("Got replication call " + key + " replicants=" + updatedReplicantMap);
       try
       {
          // The list of connection factories across the cluster has changed, so we need to update
@@ -266,6 +264,12 @@
             
             if (clusteredDelegate == null)
             {
+               log.info("Delegates list: delegates.length=" + delegates.size());
+               for (Iterator iterDelegates = delegates.entrySet().iterator(); iterDelegates.hasNext();)
+               {
+                  Map.Entry entry = (Map.Entry)iterDelegates.next();
+                  log.info("key=" + entry.getKey() + ", value=" + entry.getValue());
+               }
                throw new IllegalStateException("Cannot find connection delegate for " +
                                                uniqueName + " to update");
             }
@@ -315,9 +319,11 @@
    /**
     * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
     */
-   private void setFailoverDelegates(ClusteredClientConnectionFactoryDelegate clusteredDelegate,
+   private void  setFailoverDelegates(ClusteredClientConnectionFactoryDelegate clusteredDelegate,
                                      Map localDelegates)
    {
+      //TODO: make it trace after the code is stable
+      log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
       int s = localDelegates.size();
 
       int[] nodesIDs = new int[s];
@@ -360,7 +366,7 @@
          
          if (failoverIndex == -1)
          {
-            throw new IllegalStateException("Failover node is not in list of nodes!");
+            throw new IllegalStateException("Failover node is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
          }
          
          failoverIndexes[i] = failoverIndex;
@@ -382,6 +388,7 @@
          for(Iterator i = jndiNames.iterator(); i.hasNext(); )
          {
             String jndiName = (String)i.next();
+            log.info("Rebinding " + jndiName + " CF=" + cf );
             JNDIUtil.rebind(ic, jndiName, cf);
          }
       }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-05 18:38:08 UTC (rev 1709)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-06 02:07:06 UTC (rev 1710)
@@ -21,6 +21,7 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
@@ -39,10 +40,8 @@
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
-
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
-
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -75,8 +74,6 @@
 import org.jgroups.blocks.RequestHandler;
 import org.w3c.dom.Element;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
  * 
  * A DefaultClusteredPostOffice
@@ -1306,7 +1303,7 @@
 
 
    /**
-    *  Verifies changes on the View deciding if a node joined or lefted the cluster
+    *  Verifies changes on the View deciding if a node joined or left the cluster
     *
     * */
    private void verifyMembership(View oldView, View newView) throws Throwable
@@ -1858,7 +1855,7 @@
             
             // Need to trigger listeners
             notifyListeners(key, replicants);
-         }         
+         }
       }
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-05 18:38:08 UTC (rev 1709)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-06 02:07:06 UTC (rev 1710)
@@ -117,7 +117,7 @@
    private void startServer(int peer)
       throws Exception
    {
-      ServerManagement.start("all-cluster", peer);
+      ServerManagement.start("all", peer);
       ServerManagement.deployClusteredQueue("testDistributedQueue", peer);
       ServerManagement.deployClusteredTopic("testDistributedTopic", peer);
    }
@@ -128,12 +128,15 @@
       {
          super.tearDown();
 
+         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 0");
          ServerManagement.undeployQueue("testDistributedQueue", 0);
          ServerManagement.undeployTopic("testDistributedTopic", 0);
 
+         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 1");
          ServerManagement.undeployQueue("testDistributedQueue", 1);
          ServerManagement.undeployTopic("testDistributedTopic", 1);
 
+         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 2");
          ServerManagement.undeployQueue("testDistributedQueue", 2);
          ServerManagement.undeployTopic("testDistributedTopic", 2);
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-05 18:38:08 UTC (rev 1709)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-06 02:07:06 UTC (rev 1710)
@@ -24,6 +24,8 @@
 
 import javax.jms.MessageConsumer;
 import javax.jms.TextMessage;
+import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.tools.ServerManagement;
 
@@ -51,21 +53,35 @@
 
    // Public --------------------------------------------------------
 
-   public void testLeaveFailover() throws Exception
+   public void testConnectionFactoryConnect() throws Exception
    {
       try
       {
-         System.out.println("Number of nodes on Cluster = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         assertEquals(3,ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         assertEquals(3,ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-         ServerManagement.stop(0,true);
-         System.out.println("Number of nodes on Cluster = " + ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-         assertEquals(2,ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         ClusteredClientConnectionFactoryDelegate delegate =
+                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         log.info ("number of delegates = " + delegate.getDelegates().length);
+         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+
+         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         assertEquals(3, delegate.getDelegates().length);
+
+
+         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
+         ServerManagement.stop(2,true);
+
+         factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         assertEquals(2, delegate.getDelegates().length);
       }
       finally
       {
-         ServerManagement.start("all", 0); // tear down needs the server up
+         ServerManagement.start("all", 2);
       }
+
+
    }
 
 



From gavin.king at jboss.com  Tue Dec  5 21:49:16 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 21:49:16 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/WEB-INF  ...
Message-ID: <E1GrmqS-0004sc-Ol@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 21:49:16

  Modified:    examples/dvdstore/resources/WEB-INF  web.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.15      +2 -2      jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  
  
  


From gavin.king at jboss.com  Tue Dec  5 22:17:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories  ...
Message-ID: <E1GrnHZ-0005VZ-8x@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:17

  Removed:     examples/remoting/stories  build.xml
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/resources  ...
Message-ID: <E1GrnHZ-0005Vd-CS@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:17

  Removed:     examples/remoting/stories/resources  stories-ds.xml
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/resources/META-INF
	...
Message-ID: <E1GrnHZ-0005Vh-GY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:17

  Removed:     examples/remoting/stories/resources/META-INF   
                        application.xml jboss-app.xml persistence.xml
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/resources/WEB-INF ...
Message-ID: <E1GrnHZ-0005Vl-Kw@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:17

  Removed:     examples/remoting/stories/resources/WEB-INF   
                        faces-config.xml pages.xml web.xml
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/src/stories ...
Message-ID: <E1GrnHZ-0005Vp-PD@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:17

  Removed:     examples/remoting/stories/src/stories       Project.java
                        Projects.java ProjectsBean.java Stories.java
                        StoriesBean.java Story.java
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/view       ...
Message-ID: <E1GrnHZ-0005Vt-TF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:17

  Removed:     examples/remoting/stories/view       application.js
                        planning.js planning.xhtml story.js story.xhtml
                        template.xhtml
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/view/css   ...
Message-ID: <E1GrnHa-0005Vx-1e@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:18

  Removed:     examples/remoting/stories/view/css   application.css
                        planning.css
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/view/img   ...
Message-ID: <E1GrnHa-0005W3-4z@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:18

  Removed:     examples/remoting/stories/view/img   delete.gif
                        new_child.png
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:17:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:17:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/view/js       ...
Message-ID: <E1GrnHa-0005W7-9I@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:17:18

  Removed:     examples/remoting/stories/view/js       behaviour.js
                        controls.js dragdrop.js effects.js
                        event-selectors.js prototype.js
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:19:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:19:42 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/remoting/stories/resources/WEB-INF/lib ...
Message-ID: <E1GrnJu-0005WM-0G@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:19:42

  Removed:     examples/remoting/stories/resources/WEB-INF/lib   
                        el-api.jar el-ri.jar jsf-facelets.jar
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:21:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:21:03 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/stories/resources   ...
Message-ID: <E1GrnLD-0005ZE-Pu@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:21:03

  Removed:     examples/remoting/stories/resources   import.sql
                        seam.properties
  Log:
  get rid of broken example


From gavin.king at jboss.com  Tue Dec  5 22:23:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:23:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/poker/resources/META-INF ...
Message-ID: <E1GrnNf-0005ba-CD@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:23:35

  Modified:    examples/remoting/poker/resources/META-INF  application.xml
  Log:
  add el jars
  
  Revision  Changes    Path
  1.3       +6 -0      jboss-seam/examples/remoting/poker/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/poker/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	3 Dec 2006 04:41:35 -0000	1.2
  +++ application.xml	6 Dec 2006 03:23:35 -0000	1.3
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Tue Dec  5 22:24:08 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:24:08 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace  ...
Message-ID: <E1GrnOC-0005bt-CM@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:24:08

  Modified:    examples/seamspace  build.xml
  Log:
  el jars
  
  Revision  Changes    Path
  1.5       +1 -1      jboss-seam/examples/seamspace/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/build.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  
  
  


From gavin.king at jboss.com  Tue Dec  5 22:24:08 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 22:24:08 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF  ...
Message-ID: <E1GrnOC-0005c0-Hw@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 22:24:08

  Modified:    examples/seamspace/resources/META-INF  application.xml
  Log:
  el jars
  
  Revision  Changes    Path
  1.3       +6 -0      jboss-seam/examples/seamspace/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	3 Dec 2006 04:41:36 -0000	1.2
  +++ application.xml	6 Dec 2006 03:24:08 -0000	1.3
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +    <module>
  +        <java>el-api.jar</java>
  +    </module>
  +    <module>
  +        <java>el-ri.jar</java>
  +    </module>
   
   </application>
  \ No newline at end of file
  
  
  


From scott.stark at jboss.com  Tue Dec  5 23:08:55 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 05 Dec 2006 23:08:55 -0500
Subject: [jboss-cvs] repository.jboss.com/junit/3.8.1/lib  ...
Message-ID: <E1Gro5X-0006PP-A3@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/05 23:08:55

  Added:       junit/3.8.1/lib  junit-src.zip
  Log:
  Add the src zip
  
  Revision  Changes    Path
  1.1      date: 2006/12/06 04:08:55;  author: starksm;  state: Exp;repository.jboss.com/junit/3.8.1/lib/junit-src.zip
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Tue Dec  5 23:36:05 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 05 Dec 2006 23:36:05 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util  ...
Message-ID: <E1GroVp-0006pa-4x@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/05 23:36:05

  Modified:    src/main/org/jboss/seam/util  Parameters.java
  Log:
  fix npe
  
  Revision  Changes    Path
  1.3       +2 -1      jboss-seam/src/main/org/jboss/seam/util/Parameters.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Parameters.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Parameters.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Parameters.java	8 Oct 2006 14:01:54 -0000	1.2
  +++ Parameters.java	6 Dec 2006 04:36:05 -0000	1.3
  @@ -1,6 +1,7 @@
   package org.jboss.seam.util;
   
   import java.lang.reflect.Array;
  +import java.util.Collections;
   import java.util.Map;
   
   import javax.faces.context.FacesContext;
  @@ -39,7 +40,7 @@
            return servletRequest.getParameterMap();
         }
         
  -      return null;
  +      return Collections.EMPTY_MAP;
      }
   
      public static Object convertMultiValueRequestParameter(Map<String, String[]> requestParameters, String name, Class<?> type)
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:18 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:18 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization
	...
Message-ID: <E1Grp1y-0007Ts-N6@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:18

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization 
                        CallbackStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization/CallbackStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization/CallbackStoreCallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- CallbackStoreCallbackTestCase.java	12 Oct 2006 02:55:51 -0000	1.1
  +++ CallbackStoreCallbackTestCase.java	6 Dec 2006 05:09:18 -0000	1.2
  @@ -40,11 +40,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:18 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:18 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore
	...
Message-ID: <E1Grp1y-0007Tz-Rc@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:18

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore 
                        NullStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.5       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore/NullStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NullStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore/NullStoreCallbackTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- NullStoreCallbackTestCase.java	30 Dec 2005 05:26:39 -0000	1.4
  +++ NullStoreCallbackTestCase.java	6 Dec 2006 05:09:18 -0000	1.5
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      /**
       * How long to wait for test results to be returned from the client(s).  If goes longer than the
       * specified limit, will throw an exception and kill the running test cases.  Default value is
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi ...
Message-ID: <E1Grp1z-0007UC-1P@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/detection/jndi   
                        RestartTestCase.java JNDIDetectorTestCase.java
                        JNDIDetector2TestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/RestartTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RestartTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/RestartTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RestartTestCase.java	11 Oct 2006 19:18:53 -0000	1.1
  +++ RestartTestCase.java	6 Dec 2006 05:09:19 -0000	1.2
  @@ -50,11 +50,6 @@
                        RestartTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  
  1.5       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JNDIDetectorTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- JNDIDetectorTestCase.java	30 Dec 2005 05:26:41 -0000	1.4
  +++ JNDIDetectorTestCase.java	6 Dec 2006 05:09:19 -0000	1.5
  @@ -68,11 +68,6 @@
         }
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetector2TestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JNDIDetector2TestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetector2TestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- JNDIDetector2TestCase.java	27 Apr 2006 17:51:57 -0000	1.1
  +++ JNDIDetector2TestCase.java	6 Dec 2006 05:09:19 -0000	1.2
  @@ -47,11 +47,6 @@
         }
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/connection ...
Message-ID: <E1Grp1z-0007UJ-5x@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/connection 
                        ConnectionValidationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/connection/ConnectionValidationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/connection/ConnectionValidationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ConnectionValidationTestCase.java	30 Dec 2005 05:26:41 -0000	1.2
  +++ ConnectionValidationTestCase.java	6 Dec 2006 05:09:19 -0000	1.3
  @@ -36,9 +36,4 @@
                        1,
                        ConnectionValidationServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/callback
	...
Message-ID: <E1Grp1z-0007UQ-9S@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/callback 
                        CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.5       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/CallbackTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- CallbackTestCase.java	30 Dec 2005 05:26:40 -0000	1.4
  +++ CallbackTestCase.java	6 Dec 2006 05:09:19 -0000	1.5
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/server
	...
Message-ID: <E1Grp1z-0007UX-Dk@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/callback/multiple/server 
                        CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/server/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/server/CallbackTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- CallbackTestCase.java	9 Nov 2006 21:35:23 -0000	1.2
  +++ CallbackTestCase.java	6 Dec 2006 05:09:19 -0000	1.3
  @@ -36,11 +36,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/classloader ...
Message-ID: <E1Grp1z-0007Ue-Ic@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/classloader 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/classloader/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/classloader/InvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- InvokerTestCase.java	30 Dec 2005 05:26:40 -0000	1.2
  +++ InvokerTestCase.java	6 Dec 2006 05:09:19 -0000	1.3
  @@ -43,11 +43,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/push/disconnect
	...
Message-ID: <E1Grp1z-0007Ul-NU@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/callback/push/disconnect 
                        CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/push/disconnect/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/push/disconnect/CallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- CallbackTestCase.java	3 Feb 2006 20:34:37 -0000	1.1
  +++ CallbackTestCase.java	6 Dec 2006 05:09:19 -0000	1.2
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore
	...
Message-ID: <E1Grp1z-0007Us-Qy@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore 
                        CallbackStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.5       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/CallbackStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/CallbackStoreCallbackTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- CallbackStoreCallbackTestCase.java	30 Dec 2005 05:26:39 -0000	1.4
  +++ CallbackStoreCallbackTestCase.java	6 Dec 2006 05:09:19 -0000	1.5
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:19 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:19 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/blocking
	...
Message-ID: <E1Grp1z-0007Uz-Ux@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:19

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/blocking 
                        BlockingStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/blocking/BlockingStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BlockingStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/blocking/BlockingStoreCallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- BlockingStoreCallbackTestCase.java	19 May 2006 19:10:35 -0000	1.1
  +++ BlockingStoreCallbackTestCase.java	6 Dec 2006 05:09:19 -0000	1.2
  @@ -20,11 +20,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      /**
       * How long to wait for test results to be returned from the client(s).  If goes longer than the
       * specified limit, will throw an exception and kill the running test cases.  Default value is
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:20 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:20 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client
	...
Message-ID: <E1Grp20-0007V6-3J@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:20

  Modified:    src/tests/org/jboss/test/remoting/callback/multiple/client 
                        CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- CallbackTestCase.java	9 Nov 2006 21:35:23 -0000	1.2
  +++ CallbackTestCase.java	6 Dec 2006 05:09:20 -0000	1.3
  @@ -36,11 +36,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:09:20 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:09:20 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/exception ...
Message-ID: <E1Grp20-0007VD-8e@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:09:20

  Modified:    src/tests/org/jboss/test/remoting/callback/exception 
                        CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/exception/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/exception/CallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- CallbackTestCase.java	3 Jan 2006 06:34:46 -0000	1.1
  +++ CallbackTestCase.java	6 Dec 2006 05:09:20 -0000	1.2
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/jboss
	...
Message-ID: <E1Grp5T-0007cN-Gr@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:55

  Modified:    src/tests/org/jboss/test/remoting/serialization/jboss 
                        JBossSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/jboss/JBossSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/jboss/JBossSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JBossSerializationTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ JBossSerializationTestCase.java	6 Dec 2006 05:12:55 -0000	1.3
  @@ -36,9 +36,4 @@
                        1,
                        JBossSerializationServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss
	...
Message-ID: <E1Grp5T-0007cU-Kz@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:55

  Modified:    src/tests/org/jboss/test/remoting/serialization/invocations/jboss 
                        JBossSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/JBossSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/JBossSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JBossSerializationTestCase.java	30 Dec 2005 05:26:45 -0000	1.2
  +++ JBossSerializationTestCase.java	6 Dec 2006 05:12:55 -0000	1.3
  @@ -37,11 +37,6 @@
                        ServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/multiple
	...
Message-ID: <E1Grp5T-0007cb-PB@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:55

  Modified:    src/tests/org/jboss/test/remoting/lease/http/multiple 
                        HTTPLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/multiple/HTTPLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/multiple/HTTPLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- HTTPLeaseTestCase.java	21 Sep 2006 04:43:06 -0000	1.1
  +++ HTTPLeaseTestCase.java	6 Dec 2006 05:12:55 -0000	1.2
  @@ -35,9 +35,4 @@
                        1,
                        HTTPLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/multiple
	...
Message-ID: <E1Grp5T-0007ci-Tp@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:55

  Modified:    src/tests/org/jboss/test/remoting/lease/socket/multiple 
                        SocketLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/multiple/SocketLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/multiple/SocketLeaseTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SocketLeaseTestCase.java	9 Nov 2006 21:35:23 -0000	1.2
  +++ SocketLeaseTestCase.java	6 Dec 2006 05:12:55 -0000	1.3
  @@ -15,11 +15,6 @@
                        SocketLeaseTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      /**
       * How long to wait for test results to be returned from the client(s).  If goes longer than the
       * specified limit, will throw an exception and kill the running test cases.  Default value is
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/java
	...
Message-ID: <E1Grp5U-0007cp-25@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:56

  Modified:    src/tests/org/jboss/test/remoting/serialization/invocations/java 
                        JavaSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/java/JavaSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JavaSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/java/JavaSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JavaSerializationTestCase.java	30 Dec 2005 05:26:45 -0000	1.2
  +++ JavaSerializationTestCase.java	6 Dec 2006 05:12:56 -0000	1.3
  @@ -37,11 +37,6 @@
                        ServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/local
	...
Message-ID: <E1Grp5U-0007cx-Ef@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:56

  Modified:    src/tests/org/jboss/test/remoting/marshall/dynamic/local 
                        MarshallerLoadingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/local/MarshallerLoadingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MarshallerLoadingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/local/MarshallerLoadingTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MarshallerLoadingTestCase.java	30 Dec 2005 05:26:43 -0000	1.3
  +++ MarshallerLoadingTestCase.java	6 Dec 2006 05:12:56 -0000	1.4
  @@ -64,11 +64,4 @@
                        1,
                        MarshallerLoadingServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http
	...
Message-ID: <E1Grp5U-0007d4-JQ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:56

  Modified:    src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http 
                        HTTPMarshallerLoadingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http/HTTPMarshallerLoadingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPMarshallerLoadingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http/HTTPMarshallerLoadingTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- HTTPMarshallerLoadingTestCase.java	30 Dec 2005 05:26:43 -0000	1.3
  +++ HTTPMarshallerLoadingTestCase.java	6 Dec 2006 05:12:56 -0000	1.4
  @@ -52,10 +52,4 @@
                        1,
                        MarshallerLoadingServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket ...
Message-ID: <E1Grp5U-0007dB-NU@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:56

  Modified:    src/tests/org/jboss/test/remoting/lease/socket 
                        SocketLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/SocketLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/SocketLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketLeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ SocketLeaseTestCase.java	6 Dec 2006 05:12:56 -0000	1.2
  @@ -35,9 +35,4 @@
                        1,
                        SocketLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket
	...
Message-ID: <E1Grp5U-0007dI-S9@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:56

  Modified:    src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket 
                        SocketMarshallerLoadingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket/SocketMarshallerLoadingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketMarshallerLoadingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket/SocketMarshallerLoadingTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SocketMarshallerLoadingTestCase.java	30 Dec 2005 05:26:43 -0000	1.3
  +++ SocketMarshallerLoadingTestCase.java	6 Dec 2006 05:12:56 -0000	1.4
  @@ -52,9 +52,4 @@
                        1,
                        MarshallerLoadingServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:57 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/stream ...
Message-ID: <E1Grp5V-0007dS-7U@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:57

  Modified:    src/tests/org/jboss/test/remoting/stream  
                        Streaming2TestCase.java StreamingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/stream/Streaming2TestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Streaming2TestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/stream/Streaming2TestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Streaming2TestCase.java	24 Jun 2006 03:53:07 -0000	1.1
  +++ Streaming2TestCase.java	6 Dec 2006 05:12:57 -0000	1.2
  @@ -14,9 +14,4 @@
                        1,
                        StreamingTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  
  
  
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/stream/StreamingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StreamingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/stream/StreamingTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- StreamingTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ StreamingTestCase.java	6 Dec 2006 05:12:57 -0000	1.3
  @@ -36,9 +36,4 @@
                        1,
                        StreamingTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable
	...
Message-ID: <E1Grp5V-0007dZ-Fw@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:57

  Modified:    src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable 
                        NonSerializableTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable/NonSerializableTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NonSerializableTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable/NonSerializableTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- NonSerializableTestCase.java	30 Dec 2005 05:26:45 -0000	1.2
  +++ NonSerializableTestCase.java	6 Dec 2006 05:12:57 -0000	1.3
  @@ -37,11 +37,6 @@
                        ServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/multiplex ...
Message-ID: <E1Grp5V-0007dg-Kc@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:57

  Modified:    src/tests/org/jboss/test/remoting/lease/multiplex 
                        MultiplexLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/multiplex/MultiplexLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/multiplex/MultiplexLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MultiplexLeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ MultiplexLeaseTestCase.java	6 Dec 2006 05:12:57 -0000	1.2
  @@ -35,9 +35,4 @@
                        1,
                        MultiplexLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/java ...
Message-ID: <E1Grp5V-0007dn-Vq@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:57

  Modified:    src/tests/org/jboss/test/remoting/serialization/java 
                        JavaSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/java/JavaSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JavaSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/java/JavaSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JavaSerializationTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ JavaSerializationTestCase.java	6 Dec 2006 05:12:57 -0000	1.3
  @@ -36,9 +36,4 @@
                        1,
                        JavaSerializationServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/http ...
Message-ID: <E1Grp5W-0007du-43@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:58

  Modified:    src/tests/org/jboss/test/remoting/lease/http 
                        HTTPLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/HTTPLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/HTTPLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- HTTPLeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ HTTPLeaseTestCase.java	6 Dec 2006 05:12:58 -0000	1.2
  @@ -35,9 +35,4 @@
                        1,
                        HTTPLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http ...
Message-ID: <E1Grp5W-0007e1-8q@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:58

  Modified:    src/tests/org/jboss/test/remoting/transport/http 
                        HTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.5       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/HTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/HTTPInvokerTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- HTTPInvokerTestCase.java	30 Dec 2005 05:26:47 -0000	1.4
  +++ HTTPInvokerTestCase.java	6 Dec 2006 05:12:58 -0000	1.5
  @@ -41,10 +41,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/ssl ...
Message-ID: <E1Grp5W-0007e8-Eg@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:58

  Modified:    src/tests/org/jboss/test/remoting/detection/jndi/ssl 
                        SSLRestartTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/ssl/SSLRestartTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLRestartTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/ssl/SSLRestartTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SSLRestartTestCase.java	11 Oct 2006 19:18:53 -0000	1.1
  +++ SSLRestartTestCase.java	6 Dec 2006 05:12:58 -0000	1.2
  @@ -45,11 +45,6 @@
                        SSLRestartTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:58 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/oneway ...
Message-ID: <E1Grp5W-0007eF-JI@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:58

  Modified:    src/tests/org/jboss/test/remoting/oneway 
                        OnewayInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/oneway/OnewayInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OnewayInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/oneway/OnewayInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- OnewayInvokerTestCase.java	30 Dec 2005 05:26:44 -0000	1.3
  +++ OnewayInvokerTestCase.java	6 Dec 2006 05:12:58 -0000	1.4
  @@ -41,9 +41,4 @@
                        1,
                        OnewayInvokerServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/handler/mbean ...
Message-ID: <E1Grp5W-0007eM-Oe@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:58

  Modified:    src/tests/org/jboss/test/remoting/handler/mbean 
                        MBeanHandlerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/handler/mbean/MBeanHandlerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MBeanHandlerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/handler/mbean/MBeanHandlerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MBeanHandlerTestCase.java	30 Dec 2005 05:26:42 -0000	1.3
  +++ MBeanHandlerTestCase.java	6 Dec 2006 05:12:58 -0000	1.4
  @@ -41,9 +41,4 @@
                        1,
                        ServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:12:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:12:58 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/lease/rmi
	...
Message-ID: <E1Grp5W-0007eT-Sk@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:12:58

  Modified:    src/tests/org/jboss/test/remoting/lease/rmi 
                        RMILeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/rmi/RMILeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMILeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/rmi/RMILeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RMILeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ RMILeaseTestCase.java	6 Dec 2006 05:12:58 -0000	1.2
  @@ -36,11 +36,6 @@
                        RMILeaseTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.INFO;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:05 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:05 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex
	...
Message-ID: <E1Grp7Z-0007g4-JB@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:05

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex 
                        MultiplexInvokerTestCase.java
  Log:
  JBREM-644: Reduced test log level to INFO.
  
  Revision  Changes    Path
  1.7       +2 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/MultiplexInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/MultiplexInvokerTestCase.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- MultiplexInvokerTestCase.java	10 Nov 2006 02:04:34 -0000	1.6
  +++ MultiplexInvokerTestCase.java	6 Dec 2006 05:15:05 -0000	1.7
  @@ -28,7 +28,7 @@
   
   /**
    * @author <a href="mailto:r.sigal at computer.org">Ron Sigal</a>
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    *          <p/>
    *          Copyright (c) 2005
    *          </p>
  @@ -51,7 +51,7 @@
      
      protected Level getTestLogLevel()
      {
  -      return Level.DEBUG;
  +      return Level.INFO;
      }
   }
   
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:48 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:48 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname
	...
Message-ID: <E1Grp8G-0007hg-IX@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:48

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname 
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:15:48 -0000	1.2
  @@ -15,9 +15,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:48 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:48 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/handshake
	...
Message-ID: <E1Grp8G-0007hn-MV@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:48

  Modified:    src/tests/org/jboss/test/remoting/transport/http/ssl/handshake 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/handshake/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/handshake/InvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- InvokerTestCase.java	3 May 2006 17:04:28 -0000	1.1
  +++ InvokerTestCase.java	6 Dec 2006 05:15:48 -0000	1.2
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:48 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:48 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi ...
Message-ID: <E1Grp8G-0007hw-RN@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:48

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi 
                        RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.5       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/RMIInvokerTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- RMIInvokerTestCase.java	30 Dec 2005 05:26:48 -0000	1.4
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:15:48 -0000	1.5
  @@ -41,9 +41,4 @@
                        1,
                        RMIInvokerServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:48 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:48 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/method
	...
Message-ID: <E1Grp8G-0007i3-WB@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:48

  Modified:    src/tests/org/jboss/test/remoting/transport/http/method 
                        HTTPMethodInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/method/HTTPMethodInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPMethodInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/method/HTTPMethodInvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- HTTPMethodInvokerTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ HTTPMethodInvokerTestCase.java	6 Dec 2006 05:15:48 -0000	1.3
  @@ -41,10 +41,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom
	...
Message-ID: <E1Grp8H-0007iA-4v@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom 
                        MultiplexInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom/MultiplexInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom/MultiplexInvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MultiplexInvokerTestCase.java	9 Nov 2006 22:48:44 -0000	1.2
  +++ MultiplexInvokerTestCase.java	6 Dec 2006 05:15:49 -0000	1.3
  @@ -43,11 +43,6 @@
                        MultiplexInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.INFO;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/basic
	...
Message-ID: <E1Grp8H-0007iH-9d@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/http/ssl/basic 
                        HTTPSInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/basic/HTTPSInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPSInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/basic/HTTPSInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- HTTPSInvokerTestCase.java	30 Dec 2005 05:26:47 -0000	1.3
  +++ HTTPSInvokerTestCase.java	6 Dec 2006 05:15:49 -0000	1.4
  @@ -41,9 +41,4 @@
                        1,
                        HTTPSInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean
	...
Message-ID: <E1Grp8H-0007iO-D8@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean 
                        SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:15:49 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked
	...
Message-ID: <E1Grp8H-0007iY-HJ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/http/chunked  
                        Chunked2TestCase.java ChunkedTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/Chunked2TestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Chunked2TestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/Chunked2TestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Chunked2TestCase.java	5 May 2006 06:07:11 -0000	1.1
  +++ Chunked2TestCase.java	6 Dec 2006 05:15:49 -0000	1.2
  @@ -14,10 +14,4 @@
                        1,
                        ChunkedServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  
  
  
  1.2       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/ChunkedTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChunkedTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/ChunkedTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ChunkedTestCase.java	5 May 2006 06:07:11 -0000	1.1
  +++ ChunkedTestCase.java	6 Dec 2006 05:15:49 -0000	1.2
  @@ -35,10 +35,4 @@
                        1,
                        ChunkedServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance
	...
Message-ID: <E1Grp8H-0007if-MG@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance 
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:15:49 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake
	...
Message-ID: <E1Grp8H-0007im-SA@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake/InvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- InvokerTestCase.java	9 Nov 2006 22:48:44 -0000	1.3
  +++ InvokerTestCase.java	6 Dec 2006 05:15:49 -0000	1.4
  @@ -43,11 +43,6 @@
               InvokerServerTest.class.getName());
      }
      
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -   
      protected Level getTestLogLevel()
      {
         return Level.INFO;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/keep_alive
	...
Message-ID: <E1Grp8I-0007it-1b@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/http/keep_alive 
                        NoKeepAliveHTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/keep_alive/NoKeepAliveHTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NoKeepAliveHTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/keep_alive/NoKeepAliveHTTPInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- NoKeepAliveHTTPInvokerTestCase.java	30 Dec 2005 05:26:46 -0000	1.3
  +++ NoKeepAliveHTTPInvokerTestCase.java	6 Dec 2006 05:15:50 -0000	1.4
  @@ -37,10 +37,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/compression
	...
Message-ID: <E1Grp8I-0007j0-5z@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/http/compression 
                        CompressedHTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/compression/CompressedHTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CompressedHTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/compression/CompressedHTTPInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- CompressedHTTPInvokerTestCase.java	1 May 2006 05:48:04 -0000	1.1
  +++ CompressedHTTPInvokerTestCase.java	6 Dec 2006 05:15:50 -0000	1.2
  @@ -19,10 +19,4 @@
                        1,
                        CompressedHTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex
	...
Message-ID: <E1Grp8I-0007jA-Af@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex  
                        SimpleMultiplexTestCase.java
                        BasicServerSocketTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/SimpleMultiplexTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SimpleMultiplexTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/SimpleMultiplexTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SimpleMultiplexTestCase.java	30 Dec 2005 05:26:48 -0000	1.2
  +++ SimpleMultiplexTestCase.java	6 Dec 2006 05:15:50 -0000	1.3
  @@ -36,9 +36,4 @@
                        1,
                        SimpleServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  
  1.5       +1 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/BasicServerSocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BasicServerSocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/BasicServerSocketTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- BasicServerSocketTestCase.java	30 Dec 2005 05:26:48 -0000	1.4
  +++ BasicServerSocketTestCase.java	6 Dec 2006 05:15:50 -0000	1.5
  @@ -28,7 +28,7 @@
   
   /**
    * @author <a href="mailto:r.sigal at computer.org">Ron Sigal</a>
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    *          <p/>
    *          Copyright (c) 2005
    *          </p>
  @@ -44,11 +44,6 @@
                        MultiplexServer.class.getName());
   
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   //
   //   protected Level getTestLogLevel()
   //   {
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic
	...
Message-ID: <E1Grp8I-0007jH-Fy@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic 
                        MultiplexInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic/MultiplexInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic/MultiplexInvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MultiplexInvokerTestCase.java	9 Nov 2006 22:48:44 -0000	1.2
  +++ MultiplexInvokerTestCase.java	6 Dec 2006 05:15:50 -0000	1.3
  @@ -43,11 +43,6 @@
                        MultiplexInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.INFO;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/raw ...
Message-ID: <E1Grp8I-0007jO-Lb@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/http/raw 
                        HTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- HTTPInvokerTestCase.java	29 Oct 2006 20:28:13 -0000	1.1
  +++ HTTPInvokerTestCase.java	6 Dec 2006 05:15:50 -0000	1.2
  @@ -29,7 +29,7 @@
   /**
    *  
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    * <p>
    * Copyright Oct 29, 2006
    * </p>
  @@ -42,10 +42,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean
	...
Message-ID: <E1Grp8I-0007jX-Qz@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean 
                        SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:15:50 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance
	...
Message-ID: <E1Grp8I-0007je-WA@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:50

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance 
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:15:50 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/custom
	...
Message-ID: <E1Grp8J-0007jm-52@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:51

  Modified:    src/tests/org/jboss/test/remoting/transport/http/ssl/custom 
                        HTTPSInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/custom/HTTPSInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPSInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/custom/HTTPSInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- HTTPSInvokerTestCase.java	30 Dec 2005 05:26:47 -0000	1.3
  +++ HTTPSInvokerTestCase.java	6 Dec 2006 05:15:51 -0000	1.4
  @@ -41,10 +41,4 @@
                        1,
                        HTTPSInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:15:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:15:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname
	...
Message-ID: <E1Grp8J-0007jt-9T@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:15:51

  Modified:    src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname 
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:15:51 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Wed Dec  6 00:16:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 00:16:29 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/WEB-INF  ...
Message-ID: <E1Grp8v-0007lI-2V@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 00:16:29

  Modified:    examples/dvdstore/resources/WEB-INF  web.xml
  Log:
  set the session timeout
  
  Revision  Changes    Path
  1.16      +4 -0      jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- web.xml	6 Dec 2006 02:49:16 -0000	1.15
  +++ web.xml	6 Dec 2006 05:16:29 -0000	1.16
  @@ -5,6 +5,10 @@
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
   
  +   <session-config>
  +      <session-timeout>3</session-timeout>
  +   </session-config>
  +   
      <context-param>
           <param-name>javax.faces.CONFIG_FILES</param-name>
           <param-value>/WEB-INF/navigation.xml</param-value>
  
  
  


From gavin.king at jboss.com  Wed Dec  6 00:16:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 00:16:29 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1Grp8v-0007lP-6u@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 00:16:29

  Modified:    examples/booking/resources/WEB-INF  web.xml
  Log:
  set the session timeout
  
  Revision  Changes    Path
  1.34      +3 -1      jboss-seam/examples/booking/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/web.xml,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- web.xml	5 Dec 2006 13:24:17 -0000	1.33
  +++ web.xml	6 Dec 2006 05:16:29 -0000	1.34
  @@ -4,7 +4,9 @@
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">
   
  -   <!-- session-config><session-timeout>1</session-timeout></session-config-->
  +   <session-config>
  +      <session-timeout>3</session-timeout>
  +   </session-config>
   
      <context-param>
         <param-name>javax.faces.CONFIG_FILES</param-name>
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean
	...
Message-ID: <E1Grp9u-0007oN-FH@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:30

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean 
                        SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:17:30 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake
	...
Message-ID: <E1Grp9u-0007oU-Lz@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:30

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake 
                        RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake/RMIInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RMIInvokerTestCase.java	20 Jun 2006 17:16:59 -0000	1.1
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:17:30 -0000	1.2
  @@ -43,11 +43,6 @@
               RMIInvokerServerTest.class.getName());
      }
      
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -   
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool
	...
Message-ID: <E1Grp9u-0007ob-QC@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:30

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/socketpool 
                        SocketPoolTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketPoolTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketPoolTestCase.java	3 Nov 2006 04:02:45 -0000	1.1
  +++ SocketPoolTestCase.java	6 Dec 2006 05:17:30 -0000	1.2
  @@ -32,7 +32,7 @@
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
    * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
    *  
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    * <p>
    * Copyright Nov 2, 2006
    * </p>
  @@ -46,11 +46,6 @@
                        SocketPoolTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom
	...
Message-ID: <E1Grp9u-0007oi-UT@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:30

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/custom 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.7       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerTestCase.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- InvokerTestCase.java	28 Mar 2006 02:44:03 -0000	1.6
  +++ InvokerTestCase.java	6 Dec 2006 05:17:30 -0000	1.7
  @@ -43,11 +43,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check
	...
Message-ID: <E1Grp9v-0007op-23@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- InvokerTestCase.java	14 May 2006 05:29:59 -0000	1.1
  +++ InvokerTestCase.java	6 Dec 2006 05:17:31 -0000	1.2
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transporter/multiInterface
	...
Message-ID: <E1Grp9v-0007ow-5g@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transporter/multiInterface 
                        TransporterTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transporter/multiInterface/TransporterTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransporterTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transporter/multiInterface/TransporterTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- TransporterTestCase.java	17 Jul 2006 16:54:47 -0000	1.1
  +++ TransporterTestCase.java	6 Dec 2006 05:17:31 -0000	1.2
  @@ -14,9 +14,4 @@
                        1,
                        TestServerImpl.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transporter ...
Message-ID: <E1Grp9v-0007p3-9U@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transporter 
                        TransporterTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transporter/TransporterTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransporterTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transporter/TransporterTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- TransporterTestCase.java	30 Dec 2005 05:26:50 -0000	1.2
  +++ TransporterTestCase.java	6 Dec 2006 05:17:31 -0000	1.3
  @@ -36,9 +36,4 @@
                        1,
                        TestServerImpl.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket ...
Message-ID: <E1Grp9v-0007pA-DA@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transport/socket 
                        SocketInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/SocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/SocketInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SocketInvokerTestCase.java	30 Dec 2005 05:26:50 -0000	1.3
  +++ SocketInvokerTestCase.java	6 Dec 2006 05:17:31 -0000	1.4
  @@ -42,11 +42,6 @@
                        SocketInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance
	...
Message-ID: <E1Grp9v-0007pH-Hn@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance 
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:17:31 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection
	...
Message-ID: <E1Grp9v-0007pR-LZ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection  
                        SocketConnectionTestCase.java
                        SocketConnectionCheckTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.4       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SocketConnectionTestCase.java	16 Nov 2006 06:46:38 -0000	1.3
  +++ SocketConnectionTestCase.java	6 Dec 2006 05:17:31 -0000	1.4
  @@ -21,11 +21,6 @@
                        SocketTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return XLevel.TRACE;
  
  
  
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionCheckTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SocketConnectionCheckTestCase.java	31 Oct 2006 04:37:53 -0000	1.2
  +++ SocketConnectionCheckTestCase.java	6 Dec 2006 05:17:31 -0000	1.3
  @@ -36,11 +36,6 @@
                        SocketConnectionCheckTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance
	...
Message-ID: <E1Grp9v-0007pY-Px@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance 
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:17:31 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:31 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic
	...
Message-ID: <E1Grp9v-0007pf-TG@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:31

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic 
                        RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic/RMIInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RMIInvokerTestCase.java	20 Jun 2006 17:16:59 -0000	1.1
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:17:31 -0000	1.2
  @@ -43,11 +43,6 @@
                        RMIInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic
	...
Message-ID: <E1Grp9w-0007pm-0i@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/basic 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.5       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- InvokerTestCase.java	30 Dec 2005 05:26:49 -0000	1.4
  +++ InvokerTestCase.java	6 Dec 2006 05:17:31 -0000	1.5
  @@ -43,11 +43,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake
	...
Message-ID: <E1Grp9w-0007pt-5m@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake/InvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- InvokerTestCase.java	3 May 2006 03:25:14 -0000	1.1
  +++ InvokerTestCase.java	6 Dec 2006 05:17:32 -0000	1.2
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean
	...
Message-ID: <E1Grp9w-0007q0-Ba@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean 
                        SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:17:32 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check
	...
Message-ID: <E1Grp9w-0007q7-Fg@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check 
                        InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.3       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check/InvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- InvokerTestCase.java	14 May 2006 05:29:59 -0000	1.2
  +++ InvokerTestCase.java	6 Dec 2006 05:17:32 -0000	1.3
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname
	...
Message-ID: <E1Grp9w-0007qE-Jw@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname 
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:17:32 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom
	...
Message-ID: <E1Grp9w-0007qL-NQ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom 
                        RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -4      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom/RMIInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RMIInvokerTestCase.java	20 Jun 2006 17:16:59 -0000	1.1
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:17:32 -0000	1.2
  @@ -43,10 +43,6 @@
                        RMIInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   
      protected Level getTestLogLevel()
      {
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transporter/proxy ...
Message-ID: <E1Grp9w-0007qS-SW@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:32

  Modified:    src/tests/org/jboss/test/remoting/transporter/proxy 
                        TransporterProxyTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transporter/proxy/TransporterProxyTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransporterProxyTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transporter/proxy/TransporterProxyTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- TransporterProxyTestCase.java	4 May 2006 05:19:04 -0000	1.1
  +++ TransporterProxyTestCase.java	6 Dec 2006 05:17:32 -0000	1.2
  @@ -35,9 +35,4 @@
                        1,
                        Server.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:33 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:33 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl ...
Message-ID: <E1Grp9x-0007qZ-BB@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:33

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl 
                        SSLRMiInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/SSLRMiInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLRMiInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/SSLRMiInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SSLRMiInvokerTestCase.java	22 Jun 2006 21:19:11 -0000	1.1
  +++ SSLRMiInvokerTestCase.java	6 Dec 2006 05:17:33 -0000	1.2
  @@ -42,11 +42,6 @@
                        SSLRMIInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:17:33 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:17:33 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname
	...
Message-ID: <E1Grp9x-0007qg-Ke@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:17:33

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname 
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  1.2       +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:17:33 -0000	1.2
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Wed Dec  6 00:18:30 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 00:18:30 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/WEB-INF  ...
Message-ID: <E1GrpAs-0007qy-W0@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 00:18:30

  Modified:    examples/dvdstore/resources/WEB-INF  web.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.17      +5 -5      jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  
  
  


From gavin.king at jboss.com  Wed Dec  6 00:18:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 00:18:31 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GrpAt-0007r5-3r@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 00:18:31

  Modified:    examples/booking/resources/WEB-INF  web.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.35      +26 -26    jboss-seam/examples/booking/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/web.xml,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:52 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:52 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname
	...
Message-ID: <E1GrpI0-000803-Ut@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:52

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname 
                        Tag: remoting_2_x
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:25:52 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.rmi.connection.socketfactory.by_classname;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.rmi.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/handler/mbean ...
Message-ID: <E1GrpI1-00080E-4K@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:53

  Modified:    src/tests/org/jboss/test/remoting/handler/mbean  Tag:
                        remoting_2_x MBeanHandlerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/handler/mbean/MBeanHandlerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MBeanHandlerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/handler/mbean/MBeanHandlerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- MBeanHandlerTestCase.java	30 Dec 2005 05:26:42 -0000	1.3
  +++ MBeanHandlerTestCase.java	6 Dec 2006 05:25:53 -0000	1.3.10.1
  @@ -41,9 +41,4 @@
                        1,
                        ServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:53 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/callback
	...
Message-ID: <E1GrpI1-00080P-9D@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:53

  Modified:    src/tests/org/jboss/test/remoting/callback  Tag:
                        remoting_2_x CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/CallbackTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- CallbackTestCase.java	30 Dec 2005 05:26:40 -0000	1.4
  +++ CallbackTestCase.java	6 Dec 2006 05:25:53 -0000	1.4.10.1
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/raw ...
Message-ID: <E1GrpI1-00080a-EG@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:53

  Modified:    src/tests/org/jboss/test/remoting/transport/http/raw  Tag:
                        remoting_2_x HTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.2.1
  diff -u -b -r1.1 -r1.1.2.1
  --- HTTPInvokerTestCase.java	29 Oct 2006 20:28:13 -0000	1.1
  +++ HTTPInvokerTestCase.java	6 Dec 2006 05:25:53 -0000	1.1.2.1
  @@ -22,14 +22,13 @@
   
   package org.jboss.test.remoting.transport.http.raw;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.http.HTTPInvokerTestServer;
   
   /**
    *  
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.1.2.1 $
    * <p>
    * Copyright Oct 29, 2006
    * </p>
  @@ -42,10 +41,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/keep_alive
	...
Message-ID: <E1GrpI2-00080l-9B@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:54

  Modified:    src/tests/org/jboss/test/remoting/transport/http/keep_alive 
                        Tag: remoting_2_x
                        NoKeepAliveHTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/keep_alive/NoKeepAliveHTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NoKeepAliveHTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/keep_alive/NoKeepAliveHTTPInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- NoKeepAliveHTTPInvokerTestCase.java	30 Dec 2005 05:26:46 -0000	1.3
  +++ NoKeepAliveHTTPInvokerTestCase.java	6 Dec 2006 05:25:54 -0000	1.3.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transport.http.keep_alive;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.http.HTTPInvokerTestServer;
   
  @@ -37,10 +36,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic
	...
Message-ID: <E1GrpI2-00080w-Dv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/basic 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- InvokerTestCase.java	30 Dec 2005 05:26:49 -0000	1.4
  +++ InvokerTestCase.java	6 Dec 2006 05:25:54 -0000	1.4.10.1
  @@ -43,11 +43,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi ...
Message-ID: <E1GrpI2-00081D-Ii@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:54

  Modified:    src/tests/org/jboss/test/remoting/detection/jndi    Tag:
                        remoting_2_x JNDIDetectorTestCase.java
                        JNDIDetector2TestCase.java RestartTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JNDIDetectorTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- JNDIDetectorTestCase.java	30 Dec 2005 05:26:41 -0000	1.4
  +++ JNDIDetectorTestCase.java	6 Dec 2006 05:25:54 -0000	1.4.10.1
  @@ -68,11 +68,6 @@
         }
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetector2TestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JNDIDetector2TestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetector2TestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- JNDIDetector2TestCase.java	27 Apr 2006 17:51:57 -0000	1.1
  +++ JNDIDetector2TestCase.java	6 Dec 2006 05:25:54 -0000	1.1.4.1
  @@ -47,11 +47,6 @@
         }
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  
  1.1.2.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/RestartTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RestartTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/RestartTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.2.1
  diff -u -b -r1.1 -r1.1.2.1
  --- RestartTestCase.java	11 Oct 2006 19:18:53 -0000	1.1
  +++ RestartTestCase.java	6 Dec 2006 05:25:54 -0000	1.1.2.1
  @@ -50,11 +50,6 @@
                        RestartTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname
	...
Message-ID: <E1GrpI2-00081T-Mq@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname 
                        Tag: remoting_2_x
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:25:54 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.socket.connection.socketfactory.by_classname;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.socket.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -37,8 +36,4 @@
                        SocketFactoryTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic
	...
Message-ID: <E1GrpI2-00081f-RD@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:54

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic 
                        Tag: remoting_2_x MultiplexInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic/MultiplexInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic/MultiplexInvokerTestCase.java,v
  retrieving revision 1.1.8.1
  retrieving revision 1.1.8.2
  diff -u -b -r1.1.8.1 -r1.1.8.2
  --- MultiplexInvokerTestCase.java	9 Nov 2006 23:07:17 -0000	1.1.8.1
  +++ MultiplexInvokerTestCase.java	6 Dec 2006 05:25:54 -0000	1.1.8.2
  @@ -43,11 +43,6 @@
                        MultiplexInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.INFO;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean
	...
Message-ID: <E1GrpI2-00081q-VL@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:54

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean 
                        Tag: remoting_2_x SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:25:54 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.multiplex.connection.socketfactory.by_mbean;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.multiplex.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/local
	...
Message-ID: <E1GrpI3-000821-3o@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/marshall/dynamic/local 
                        Tag: remoting_2_x MarshallerLoadingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/local/MarshallerLoadingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MarshallerLoadingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/local/MarshallerLoadingTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- MarshallerLoadingTestCase.java	30 Dec 2005 05:26:43 -0000	1.3
  +++ MarshallerLoadingTestCase.java	6 Dec 2006 05:25:55 -0000	1.3.10.1
  @@ -64,11 +64,4 @@
                        1,
                        MarshallerLoadingServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance
	...
Message-ID: <E1GrpI3-00082C-8G@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance 
                        Tag: remoting_2_x
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:25:55 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.multiplex.connection.socketfactory.by_instance;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.multiplex.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/handshake
	...
Message-ID: <E1GrpI3-00082N-Cs@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/transport/http/ssl/handshake 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/handshake/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/handshake/InvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- InvokerTestCase.java	3 May 2006 17:04:28 -0000	1.1
  +++ InvokerTestCase.java	6 Dec 2006 05:25:55 -0000	1.1.4.1
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool
	...
Message-ID: <E1GrpI3-00082Y-Hp@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/socketpool 
                        Tag: remoting_2_x SocketPoolTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +1 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketPoolTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestCase.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- SocketPoolTestCase.java	3 Nov 2006 04:04:00 -0000	1.1.2.2
  +++ SocketPoolTestCase.java	6 Dec 2006 05:25:55 -0000	1.1.2.3
  @@ -32,7 +32,7 @@
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
    * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
    *  
  - * @version $Revision: 1.1.2.2 $
  + * @version $Revision: 1.1.2.3 $
    * <p>
    * Copyright Nov 2, 2006
    * </p>
  @@ -46,11 +46,6 @@
                        SocketPoolTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/method
	...
Message-ID: <E1GrpI3-00082j-ME@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/transport/http/method 
                        Tag: remoting_2_x HTTPMethodInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/method/HTTPMethodInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPMethodInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/method/HTTPMethodInvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- HTTPMethodInvokerTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ HTTPMethodInvokerTestCase.java	6 Dec 2006 05:25:55 -0000	1.2.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transport.http.method;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   
   /**
  @@ -41,10 +40,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/compression
	...
Message-ID: <E1GrpI3-00082u-Qi@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/transport/http/compression 
                        Tag: remoting_2_x
                        CompressedHTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/compression/CompressedHTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CompressedHTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/compression/CompressedHTTPInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- CompressedHTTPInvokerTestCase.java	1 May 2006 05:48:04 -0000	1.1
  +++ CompressedHTTPInvokerTestCase.java	6 Dec 2006 05:25:55 -0000	1.1.4.1
  @@ -1,6 +1,5 @@
   package org.jboss.test.remoting.transport.http.compression;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   
   /**
  @@ -19,10 +18,4 @@
                        1,
                        CompressedHTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transporter ...
Message-ID: <E1GrpI3-000835-Vh@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:55

  Modified:    src/tests/org/jboss/test/remoting/transporter  Tag:
                        remoting_2_x TransporterTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transporter/TransporterTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransporterTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transporter/TransporterTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- TransporterTestCase.java	30 Dec 2005 05:26:50 -0000	1.2
  +++ TransporterTestCase.java	6 Dec 2006 05:25:55 -0000	1.2.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transporter;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -36,9 +35,4 @@
                        1,
                        TestServerImpl.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl ...
Message-ID: <E1GrpI4-00083G-3x@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl  Tag:
                        remoting_2_x SSLRMiInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/SSLRMiInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLRMiInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/SSLRMiInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- SSLRMiInvokerTestCase.java	22 Jun 2006 21:19:11 -0000	1.1
  +++ SSLRMiInvokerTestCase.java	6 Dec 2006 05:25:56 -0000	1.1.4.1
  @@ -42,11 +42,6 @@
                        SSLRMIInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/multiple
	...
Message-ID: <E1GrpI4-00083R-8f@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/lease/http/multiple  Tag:
                        remoting_2_x HTTPLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/multiple/HTTPLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/multiple/HTTPLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.2.1
  diff -u -b -r1.1 -r1.1.2.1
  --- HTTPLeaseTestCase.java	21 Sep 2006 04:43:06 -0000	1.1
  +++ HTTPLeaseTestCase.java	6 Dec 2006 05:25:56 -0000	1.1.2.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.lease.http.multiple;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -35,9 +34,4 @@
                        1,
                        HTTPLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/classloader ...
Message-ID: <E1GrpI4-00083c-Dv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/classloader  Tag:
                        remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/classloader/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/classloader/InvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- InvokerTestCase.java	30 Dec 2005 05:26:40 -0000	1.2
  +++ InvokerTestCase.java	6 Dec 2006 05:25:56 -0000	1.2.10.1
  @@ -43,11 +43,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom
	...
Message-ID: <E1GrpI4-00083n-I8@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom 
                        Tag: remoting_2_x RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom/RMIInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- RMIInvokerTestCase.java	20 Jun 2006 17:16:59 -0000	1.1
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:25:56 -0000	1.1.4.1
  @@ -43,11 +43,6 @@
                        RMIInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance
	...
Message-ID: <E1GrpI4-000843-Lw@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance 
                        Tag: remoting_2_x
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:25:56 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.rmi.connection.socketfactory.by_instance;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.rmi.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/http ...
Message-ID: <E1GrpI4-00084E-Qn@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/lease/http  Tag:
                        remoting_2_x HTTPLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/HTTPLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/http/HTTPLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- HTTPLeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ HTTPLeaseTestCase.java	6 Dec 2006 05:25:56 -0000	1.1.4.1
  @@ -35,9 +35,4 @@
                        1,
                        HTTPLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transporter/multiInterface
	...
Message-ID: <E1GrpI4-00084P-VD@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:56

  Modified:    src/tests/org/jboss/test/remoting/transporter/multiInterface 
                        Tag: remoting_2_x TransporterTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transporter/multiInterface/TransporterTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransporterTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transporter/multiInterface/TransporterTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- TransporterTestCase.java	17 Jul 2006 16:54:47 -0000	1.1
  +++ TransporterTestCase.java	6 Dec 2006 05:25:56 -0000	1.1.4.1
  @@ -1,6 +1,5 @@
   package org.jboss.test.remoting.transporter.multiInterface;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -14,9 +13,4 @@
                        1,
                        TestServerImpl.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex
	...
Message-ID: <E1GrpI5-00084d-3b@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex   Tag:
                        remoting_2_x SimpleMultiplexTestCase.java
                        BasicServerSocketTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/SimpleMultiplexTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SimpleMultiplexTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/SimpleMultiplexTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- SimpleMultiplexTestCase.java	30 Dec 2005 05:26:48 -0000	1.2
  +++ SimpleMultiplexTestCase.java	6 Dec 2006 05:25:57 -0000	1.2.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transport.multiplex;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -36,9 +35,4 @@
                        1,
                        SimpleServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  
  1.4.10.1  +1 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/BasicServerSocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BasicServerSocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/BasicServerSocketTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- BasicServerSocketTestCase.java	30 Dec 2005 05:26:48 -0000	1.4
  +++ BasicServerSocketTestCase.java	6 Dec 2006 05:25:57 -0000	1.4.10.1
  @@ -28,7 +28,7 @@
   
   /**
    * @author <a href="mailto:r.sigal at computer.org">Ron Sigal</a>
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.4.10.1 $
    *          <p/>
    *          Copyright (c) 2005
    *          </p>
  @@ -45,10 +45,6 @@
   
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   //
   //   protected Level getTestLogLevel()
   //   {
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http ...
Message-ID: <E1GrpI5-00084p-8P@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/transport/http  Tag:
                        remoting_2_x HTTPInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/HTTPInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/HTTPInvokerTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- HTTPInvokerTestCase.java	30 Dec 2005 05:26:47 -0000	1.4
  +++ HTTPInvokerTestCase.java	6 Dec 2006 05:25:57 -0000	1.4.10.1
  @@ -41,10 +41,4 @@
                        1,
                        HTTPInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked
	...
Message-ID: <E1GrpI5-000853-Cq@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/transport/http/chunked  
                        Tag: remoting_2_x ChunkedTestCase.java
                        Chunked2TestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/ChunkedTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChunkedTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/ChunkedTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- ChunkedTestCase.java	5 May 2006 06:07:11 -0000	1.1
  +++ ChunkedTestCase.java	6 Dec 2006 05:25:57 -0000	1.1.4.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.http.chunked;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   
   /**
  @@ -35,10 +34,4 @@
                        1,
                        ChunkedServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  
  1.1.4.1   +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/Chunked2TestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Chunked2TestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/chunked/Chunked2TestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- Chunked2TestCase.java	5 May 2006 06:07:11 -0000	1.1
  +++ Chunked2TestCase.java	6 Dec 2006 05:25:57 -0000	1.1.4.1
  @@ -1,6 +1,5 @@
   package org.jboss.test.remoting.transport.http.chunked;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   
   /**
  @@ -14,10 +13,4 @@
                        1,
                        ChunkedServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean
	...
Message-ID: <E1GrpI5-00085E-Ga@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean 
                        Tag: remoting_2_x SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:25:57 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.http.connection.socketfactory.by_mbean;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.http.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/oneway ...
Message-ID: <E1GrpI5-00085P-MU@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/oneway  Tag: remoting_2_x
                        OnewayInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/oneway/OnewayInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OnewayInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/oneway/OnewayInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- OnewayInvokerTestCase.java	30 Dec 2005 05:26:44 -0000	1.3
  +++ OnewayInvokerTestCase.java	6 Dec 2006 05:25:57 -0000	1.3.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.oneway;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -41,9 +40,4 @@
                        1,
                        OnewayInvokerServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/multiplex ...
Message-ID: <E1GrpI5-00085a-QT@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/lease/multiplex  Tag:
                        remoting_2_x MultiplexLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/lease/multiplex/MultiplexLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/multiplex/MultiplexLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- MultiplexLeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ MultiplexLeaseTestCase.java	6 Dec 2006 05:25:57 -0000	1.1.4.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.lease.multiplex;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -35,9 +34,4 @@
                        1,
                        MultiplexLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable
	...
Message-ID: <E1GrpI5-00085l-VR@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:57

  Modified:    src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable 
                        Tag: remoting_2_x NonSerializableTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable/NonSerializableTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NonSerializableTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable/NonSerializableTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- NonSerializableTestCase.java	30 Dec 2005 05:26:45 -0000	1.2
  +++ NonSerializableTestCase.java	6 Dec 2006 05:25:57 -0000	1.2.10.1
  @@ -37,11 +37,6 @@
                        ServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket ...
Message-ID: <E1GrpI6-00085w-3O@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:58

  Modified:    src/tests/org/jboss/test/remoting/lease/socket  Tag:
                        remoting_2_x SocketLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/SocketLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/SocketLeaseTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- SocketLeaseTestCase.java	9 May 2006 00:59:39 -0000	1.1
  +++ SocketLeaseTestCase.java	6 Dec 2006 05:25:58 -0000	1.1.4.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.lease.socket;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -35,9 +34,4 @@
                        1,
                        SocketLeaseTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake
	...
Message-ID: <E1GrpI6-000867-8L@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:58

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake 
                        Tag: remoting_2_x RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake/RMIInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- RMIInvokerTestCase.java	20 Jun 2006 17:16:59 -0000	1.1
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:25:58 -0000	1.1.4.1
  @@ -43,11 +43,6 @@
               RMIInvokerServerTest.class.getName());
      }
      
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -   
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check
	...
Message-ID: <E1GrpI6-00086I-Cv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:58

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check/InvokerTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.4.1
  diff -u -b -r1.2 -r1.2.4.1
  --- InvokerTestCase.java	14 May 2006 05:29:59 -0000	1.2
  +++ InvokerTestCase.java	6 Dec 2006 05:25:58 -0000	1.2.4.1
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transporter/proxy ...
Message-ID: <E1GrpI6-00086T-HD@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:58

  Modified:    src/tests/org/jboss/test/remoting/transporter/proxy  Tag:
                        remoting_2_x TransporterProxyTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transporter/proxy/TransporterProxyTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransporterProxyTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transporter/proxy/TransporterProxyTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- TransporterProxyTestCase.java	4 May 2006 05:19:04 -0000	1.1
  +++ TransporterProxyTestCase.java	6 Dec 2006 05:25:58 -0000	1.1.4.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transporter.proxy;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -35,9 +34,4 @@
                        1,
                        Server.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/jboss
	...
Message-ID: <E1GrpI6-00086j-Mk@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:58

  Modified:    src/tests/org/jboss/test/remoting/serialization/jboss  Tag:
                        remoting_2_x JBossSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/jboss/JBossSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/jboss/JBossSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- JBossSerializationTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ JBossSerializationTestCase.java	6 Dec 2006 05:25:58 -0000	1.2.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.serialization.jboss;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -36,9 +35,4 @@
                        1,
                        JBossSerializationServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom
	...
Message-ID: <E1GrpI6-00086u-RB@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:58

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom 
                        Tag: remoting_2_x MultiplexInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom/MultiplexInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MultiplexInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom/MultiplexInvokerTestCase.java,v
  retrieving revision 1.1.8.1
  retrieving revision 1.1.8.2
  diff -u -b -r1.1.8.1 -r1.1.8.2
  --- MultiplexInvokerTestCase.java	9 Nov 2006 23:07:17 -0000	1.1.8.1
  +++ MultiplexInvokerTestCase.java	6 Dec 2006 05:25:58 -0000	1.1.8.2
  @@ -43,11 +43,6 @@
                        MultiplexInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.INFO;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:59 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:59 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check
	...
Message-ID: <E1GrpI7-000875-Eu@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:59

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- InvokerTestCase.java	14 May 2006 05:29:59 -0000	1.1
  +++ InvokerTestCase.java	6 Dec 2006 05:25:59 -0000	1.1.4.1
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:59 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:59 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss
	...
Message-ID: <E1GrpI7-00087G-P9@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:59

  Modified:    src/tests/org/jboss/test/remoting/serialization/invocations/jboss 
                        Tag: remoting_2_x JBossSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/JBossSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/jboss/JBossSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- JBossSerializationTestCase.java	30 Dec 2005 05:26:45 -0000	1.2
  +++ JBossSerializationTestCase.java	6 Dec 2006 05:25:59 -0000	1.2.10.1
  @@ -37,11 +37,6 @@
                        ServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake
	...
Message-ID: <E1GrpI8-00087r-7e@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake/InvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- InvokerTestCase.java	3 May 2006 03:25:14 -0000	1.1
  +++ InvokerTestCase.java	6 Dec 2006 05:26:00 -0000	1.1.4.1
  @@ -20,11 +20,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean
	...
Message-ID: <E1GrpI8-000882-Bj@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean 
                        Tag: remoting_2_x SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:26:00 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.rmi.connection.socketfactory.by_mbean;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.rmi.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:25:59 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:25:59 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/stream ...
Message-ID: <E1GrpI7-00087U-UK@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:25:59

  Modified:    src/tests/org/jboss/test/remoting/stream   Tag: remoting_2_x
                        StreamingTestCase.java Streaming2TestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/stream/StreamingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StreamingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/stream/StreamingTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- StreamingTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ StreamingTestCase.java	6 Dec 2006 05:25:59 -0000	1.2.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.stream;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -36,9 +35,4 @@
                        1,
                        StreamingTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  
  1.1.4.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/stream/Streaming2TestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Streaming2TestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/stream/Streaming2TestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- Streaming2TestCase.java	24 Jun 2006 03:53:07 -0000	1.1
  +++ Streaming2TestCase.java	6 Dec 2006 05:25:59 -0000	1.1.4.1
  @@ -1,6 +1,5 @@
   package org.jboss.test.remoting.stream;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -14,9 +13,4 @@
                        1,
                        StreamingTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket ...
Message-ID: <E1GrpI8-00087f-3J@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/transport/socket  Tag:
                        remoting_2_x SocketInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/SocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/SocketInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- SocketInvokerTestCase.java	30 Dec 2005 05:26:50 -0000	1.3
  +++ SocketInvokerTestCase.java	6 Dec 2006 05:26:00 -0000	1.3.10.1
  @@ -42,11 +42,6 @@
                        SocketInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/blocking
	...
Message-ID: <E1GrpI8-00088D-GV@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/blocking 
                        Tag: remoting_2_x
                        BlockingStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/blocking/BlockingStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BlockingStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/blocking/BlockingStoreCallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- BlockingStoreCallbackTestCase.java	19 May 2006 19:10:35 -0000	1.1
  +++ BlockingStoreCallbackTestCase.java	6 Dec 2006 05:26:00 -0000	1.1.4.1
  @@ -20,11 +20,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      /**
       * How long to wait for test results to be returned from the client(s).  If goes longer than the
       * specified limit, will throw an exception and kill the running test cases.  Default value is
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/push/disconnect
	...
Message-ID: <E1GrpI8-00088V-Lz@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/callback/push/disconnect 
                        Tag: remoting_2_x CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/push/disconnect/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/push/disconnect/CallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- CallbackTestCase.java	3 Feb 2006 20:34:37 -0000	1.1
  +++ CallbackTestCase.java	6 Dec 2006 05:26:00 -0000	1.1.8.1
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake
	...
Message-ID: <E1GrpI8-00088s-Va@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.4.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake/InvokerTestCase.java,v
  retrieving revision 1.2.4.1
  retrieving revision 1.2.4.2
  diff -u -b -r1.2.4.1 -r1.2.4.2
  --- InvokerTestCase.java	9 Nov 2006 23:07:16 -0000	1.2.4.1
  +++ InvokerTestCase.java	6 Dec 2006 05:26:00 -0000	1.2.4.2
  @@ -43,11 +43,6 @@
               InvokerServerTest.class.getName());
      }
      
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -   
      protected Level getTestLogLevel()
      {
         return Level.INFO;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/multiple
	...
Message-ID: <E1GrpI9-000893-48@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/lease/socket/multiple 
                        Tag: remoting_2_x SocketLeaseTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/multiple/SocketLeaseTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketLeaseTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/lease/socket/multiple/SocketLeaseTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SocketLeaseTestCase.java	7 Nov 2006 16:19:29 -0000	1.1.2.1
  +++ SocketLeaseTestCase.java	6 Dec 2006 05:26:01 -0000	1.1.2.2
  @@ -15,11 +15,6 @@
                        SocketLeaseTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -   
      /**
       * How long to wait for test results to be returned from the client(s).  If goes longer than the
       * specified limit, will throw an exception and kill the running test cases.  Default value is
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/basic
	...
Message-ID: <E1GrpI8-00088g-QK@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:00

  Modified:    src/tests/org/jboss/test/remoting/transport/http/ssl/basic 
                        Tag: remoting_2_x HTTPSInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/basic/HTTPSInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPSInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/basic/HTTPSInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- HTTPSInvokerTestCase.java	30 Dec 2005 05:26:47 -0000	1.3
  +++ HTTPSInvokerTestCase.java	6 Dec 2006 05:26:00 -0000	1.3.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transport.http.ssl.basic;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -41,9 +40,4 @@
                        1,
                        HTTPSInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic
	...
Message-ID: <E1GrpI9-00089E-8k@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic 
                        Tag: remoting_2_x RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic/RMIInvokerTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- RMIInvokerTestCase.java	20 Jun 2006 17:16:59 -0000	1.1
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:26:01 -0000	1.1.4.1
  @@ -43,11 +43,6 @@
                        RMIInvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi ...
Message-ID: <E1GrpI9-00089P-DY@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/transport/rmi  Tag:
                        remoting_2_x RMIInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/RMIInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RMIInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/rmi/RMIInvokerTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- RMIInvokerTestCase.java	30 Dec 2005 05:26:48 -0000	1.4
  +++ RMIInvokerTestCase.java	6 Dec 2006 05:26:01 -0000	1.4.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transport.rmi;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   
   /**
  @@ -41,9 +40,4 @@
                        1,
                        RMIInvokerServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/java ...
Message-ID: <E1GrpI9-00089a-I2@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/serialization/java  Tag:
                        remoting_2_x JavaSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/java/JavaSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JavaSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/java/JavaSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- JavaSerializationTestCase.java	30 Dec 2005 05:26:46 -0000	1.2
  +++ JavaSerializationTestCase.java	6 Dec 2006 05:26:01 -0000	1.2.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.serialization.java;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -36,9 +35,4 @@
                        1,
                        JavaSerializationServerTest.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean
	...
Message-ID: <E1GrpI9-00089l-MT@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean 
                        Tag: remoting_2_x SocketFactoryByMBeanTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByMBeanTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByMBeanTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByMBeanTestCase.java	6 Dec 2006 05:26:01 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.socket.connection.socketfactory.by_mbean;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.socket.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/server
	...
Message-ID: <E1GrpI9-00089w-Qq@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/callback/multiple/server 
                        Tag: remoting_2_x CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/server/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/server/CallbackTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- CallbackTestCase.java	9 Nov 2006 20:33:59 -0000	1.1.2.1
  +++ CallbackTestCase.java	6 Dec 2006 05:26:01 -0000	1.1.2.2
  @@ -36,11 +36,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname
	...
Message-ID: <E1GrpI9-0008A7-V4@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:01

  Modified:    src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname 
                        Tag: remoting_2_x
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:26:01 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.http.connection.socketfactory.by_classname;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.http.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection
	...
Message-ID: <E1GrpIA-0008AL-3M@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:02

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection  
                        Tag: remoting_2_x SocketConnectionTestCase.java
                        SocketConnectionCheckTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketConnectionTestCase.java	13 Feb 2006 20:11:41 -0000	1.1
  +++ SocketConnectionTestCase.java	6 Dec 2006 05:26:02 -0000	1.1.8.1
  @@ -20,11 +20,6 @@
                        SocketTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  
  1.1.2.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionCheckTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SocketConnectionCheckTestCase.java	31 Oct 2006 04:21:07 -0000	1.1.2.1
  +++ SocketConnectionCheckTestCase.java	6 Dec 2006 05:26:02 -0000	1.1.2.2
  @@ -36,11 +36,6 @@
                        SocketConnectionCheckTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket
	...
Message-ID: <E1GrpIA-0008AW-7K@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:02

  Modified:    src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket 
                        Tag: remoting_2_x
                        SocketMarshallerLoadingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket/SocketMarshallerLoadingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketMarshallerLoadingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket/SocketMarshallerLoadingTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- SocketMarshallerLoadingTestCase.java	30 Dec 2005 05:26:43 -0000	1.3
  +++ SocketMarshallerLoadingTestCase.java	6 Dec 2006 05:26:02 -0000	1.3.10.1
  @@ -52,9 +52,4 @@
                        1,
                        MarshallerLoadingServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore
	...
Message-ID: <E1GrpIA-0008Ah-Bl@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:02

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore 
                        Tag: remoting_2_x
                        CallbackStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/CallbackStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/CallbackStoreCallbackTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- CallbackStoreCallbackTestCase.java	30 Dec 2005 05:26:39 -0000	1.4
  +++ CallbackStoreCallbackTestCase.java	6 Dec 2006 05:26:02 -0000	1.4.10.1
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/custom
	...
Message-ID: <E1GrpIA-0008As-KL@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:02

  Modified:    src/tests/org/jboss/test/remoting/transport/http/ssl/custom 
                        Tag: remoting_2_x HTTPSInvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -7      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/custom/HTTPSInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPSInvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/ssl/custom/HTTPSInvokerTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- HTTPSInvokerTestCase.java	30 Dec 2005 05:26:47 -0000	1.3
  +++ HTTPSInvokerTestCase.java	6 Dec 2006 05:26:02 -0000	1.3.10.1
  @@ -22,7 +22,6 @@
   
   package org.jboss.test.remoting.transport.http.ssl.custom;
   
  -import org.apache.log4j.Level;
   import org.jboss.jrunit.harness.TestDriver;
   
   /**
  @@ -41,10 +40,4 @@
                        1,
                        HTTPSInvokerTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/java
	...
Message-ID: <E1GrpIA-0008B8-PK@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:02

  Modified:    src/tests/org/jboss/test/remoting/serialization/invocations/java 
                        Tag: remoting_2_x JavaSerializationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/java/JavaSerializationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JavaSerializationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/serialization/invocations/java/JavaSerializationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- JavaSerializationTestCase.java	30 Dec 2005 05:26:45 -0000	1.2
  +++ JavaSerializationTestCase.java	6 Dec 2006 05:26:02 -0000	1.2.10.1
  @@ -37,11 +37,6 @@
                        ServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/connection ...
Message-ID: <E1GrpIA-0008BK-U3@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:02

  Modified:    src/tests/org/jboss/test/remoting/connection  Tag:
                        remoting_2_x ConnectionValidationTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/connection/ConnectionValidationTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidationTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/connection/ConnectionValidationTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.10.1
  diff -u -b -r1.2 -r1.2.10.1
  --- ConnectionValidationTestCase.java	30 Dec 2005 05:26:41 -0000	1.2
  +++ ConnectionValidationTestCase.java	6 Dec 2006 05:26:02 -0000	1.2.10.1
  @@ -36,9 +36,4 @@
                        1,
                        ConnectionValidationServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:03 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:03 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization
	...
Message-ID: <E1GrpIB-0008BV-4j@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:03

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization 
                        Tag: remoting_2_x
                        CallbackStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization/CallbackStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization/CallbackStoreCallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.2.1
  diff -u -b -r1.1 -r1.1.2.1
  --- CallbackStoreCallbackTestCase.java	12 Oct 2006 02:55:51 -0000	1.1
  +++ CallbackStoreCallbackTestCase.java	6 Dec 2006 05:26:03 -0000	1.1.2.1
  @@ -40,11 +40,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:03 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:03 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http
	...
Message-ID: <E1GrpIB-0008Bg-A2@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:03

  Modified:    src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http 
                        Tag: remoting_2_x
                        HTTPMarshallerLoadingTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.10.1  +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http/HTTPMarshallerLoadingTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPMarshallerLoadingTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http/HTTPMarshallerLoadingTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.3.10.1
  diff -u -b -r1.3 -r1.3.10.1
  --- HTTPMarshallerLoadingTestCase.java	30 Dec 2005 05:26:43 -0000	1.3
  +++ HTTPMarshallerLoadingTestCase.java	6 Dec 2006 05:26:03 -0000	1.3.10.1
  @@ -52,10 +52,4 @@
                        1,
                        MarshallerLoadingServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:03 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:03 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom
	...
Message-ID: <E1GrpIB-0008Br-F7@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:03

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/custom 
                        Tag: remoting_2_x InvokerTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.6.6.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerTestCase.java,v
  retrieving revision 1.6
  retrieving revision 1.6.6.1
  diff -u -b -r1.6 -r1.6.6.1
  --- InvokerTestCase.java	28 Mar 2006 02:44:03 -0000	1.6
  +++ InvokerTestCase.java	6 Dec 2006 05:26:03 -0000	1.6.6.1
  @@ -43,11 +43,6 @@
                        InvokerServerTest.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:03 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:03 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client
	...
Message-ID: <E1GrpIB-0008C2-Jl@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:03

  Modified:    src/tests/org/jboss/test/remoting/callback/multiple/client 
                        Tag: remoting_2_x CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- CallbackTestCase.java	9 Nov 2006 20:33:59 -0000	1.1.2.1
  +++ CallbackTestCase.java	6 Dec 2006 05:26:03 -0000	1.1.2.2
  @@ -36,11 +36,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:03 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:03 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/ssl ...
Message-ID: <E1GrpIB-0008CD-Oi@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:03

  Modified:    src/tests/org/jboss/test/remoting/detection/jndi/ssl  Tag:
                        remoting_2_x SSLRestartTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/ssl/SSLRestartTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLRestartTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/detection/jndi/ssl/SSLRestartTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.2.1
  diff -u -b -r1.1 -r1.1.2.1
  --- SSLRestartTestCase.java	11 Oct 2006 19:18:53 -0000	1.1
  +++ SSLRestartTestCase.java	6 Dec 2006 05:26:03 -0000	1.1.2.1
  @@ -45,11 +45,6 @@
                        SSLRestartTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:03 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:03 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/exception ...
Message-ID: <E1GrpIB-0008CO-Ts@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:03

  Modified:    src/tests/org/jboss/test/remoting/callback/exception  Tag:
                        remoting_2_x CallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/exception/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/exception/CallbackTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.10.1
  diff -u -b -r1.1 -r1.1.10.1
  --- CallbackTestCase.java	3 Jan 2006 06:34:46 -0000	1.1
  +++ CallbackTestCase.java	6 Dec 2006 05:26:03 -0000	1.1.10.1
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      protected Level getTestLogLevel()
      {
         return Level.DEBUG;
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:04 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:04 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance
	...
Message-ID: <E1GrpIC-0008CZ-2n@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:04

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance 
                        Tag: remoting_2_x
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -6      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:54 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:26:04 -0000	1.1.8.1
  @@ -21,7 +21,6 @@
   */
   package org.jboss.test.remoting.transport.socket.connection.socketfactory.by_instance;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.socket.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -36,9 +35,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:04 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:04 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore
	...
Message-ID: <E1GrpIC-0008Ck-7P@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:04

  Modified:    src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore 
                        Tag: remoting_2_x NullStoreCallbackTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.10.1  +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore/NullStoreCallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NullStoreCallbackTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore/NullStoreCallbackTestCase.java,v
  retrieving revision 1.4
  retrieving revision 1.4.10.1
  diff -u -b -r1.4 -r1.4.10.1
  --- NullStoreCallbackTestCase.java	30 Dec 2005 05:26:39 -0000	1.4
  +++ NullStoreCallbackTestCase.java	6 Dec 2006 05:26:04 -0000	1.4.10.1
  @@ -42,11 +42,6 @@
                        CallbackTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
  -
      /**
       * How long to wait for test results to be returned from the client(s).  If goes longer than the
       * specified limit, will throw an exception and kill the running test cases.  Default value is
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:05 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:05 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance
	...
Message-ID: <E1GrpID-0008D1-4b@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:05

  Modified:    src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance 
                        Tag: remoting_2_x
                        SocketFactoryByInstanceTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByInstanceTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByInstanceTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByInstanceTestCase.java	6 Dec 2006 05:26:05 -0000	1.1.8.1
  @@ -36,9 +36,4 @@
                        1,
                        SocketFactoryTestServer.class.getName());
      }
  -
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 00:26:05 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 00:26:05 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname
	...
Message-ID: <E1GrpID-0008DC-8n@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 00:26:05

  Modified:    src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname 
                        Tag: remoting_2_x
                        SocketFactoryByClassnameTestCase.java
  Log:
  JBREM-644: Removed overriding getTestHarnessLogLevel().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.8.1   +0 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketFactoryByClassnameTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.8.1
  diff -u -b -r1.1 -r1.1.8.1
  --- SocketFactoryByClassnameTestCase.java	14 Mar 2006 18:32:53 -0000	1.1
  +++ SocketFactoryByClassnameTestCase.java	6 Dec 2006 05:26:05 -0000	1.1.8.1
  @@ -1,6 +1,5 @@
   package org.jboss.test.remoting.transport.multiplex.connection.socketfactory.by_classname;
   
  -import org.apache.log4j.Level;
   import org.jboss.test.remoting.transport.InvokerTestDriver;
   import org.jboss.test.remoting.transport.multiplex.connection.socketfactory.SocketFactoryTestClient;
   
  @@ -16,8 +15,4 @@
                        SocketFactoryTestServer.class.getName());
      }
   
  -   protected Level getTestHarnessLogLevel()
  -   {
  -      return Level.DEBUG;
  -   }
   }
  
  
  


From scott.stark at jboss.com  Wed Dec  6 00:33:01 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 00:33:01 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1GrpOv-0008Jl-14@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 00:33:01

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  Add a jbossws-src.zip for the snapshot
  
  Revision  Changes    Path
  1.32      +1 -0      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- component-info.xml	5 Dec 2006 06:13:29 -0000	1.31
  +++ component-info.xml	6 Dec 2006 05:33:00 -0000	1.32
  @@ -10,6 +10,7 @@
         <artifact id="jboss-saaj.jar"/>
         <artifact id="jbossws-client.jar"/>
         <artifact id="jbossws.sar"/>
  +      <artifact id="jbossws-src.zip"/>
   
         <import componentref="apache-xmlsec">
         	<compatible version="1.3.0"/>
  
  
  


From scott.stark at jboss.com  Wed Dec  6 00:33:03 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 00:33:03 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1GrpOx-0008K1-IS@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 00:33:03

  Modified:    jboss/jbossws/snapshot/lib       jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws.sar
  Added:       jboss/jbossws/snapshot/lib       jbossws-src.zip
  Log:
  Add a jbossws-src.zip for the snapshot
  
  Revision  Changes    Path
  1.27      +122 -123  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.26      +202 -203  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.27      +68 -69    repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.38      +2065 -2003repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.38      +4505 -4514repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/06 05:33:02;  author: starksm;  state: Exp;repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-src.zip
  
  	<<Binary file>>
  
  


From forge-admin at jboss.com  Wed Dec  6 01:00:30 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Wed, 06 Dec 2006 01:00:30 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GrppW-0000GT-SN@committer01.frg.pub.inap.atl.jboss.com>

Commit from starksm (2006-12-05 01:13 EST)
-------------------

Compatible with javassist 3.4.GA

  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml  1.31


Commit from gavin (2006-12-05 08:13 EST)
-----------------

remove obsolete

  jboss-seam  src/ui/META-INF/faces-config.xml  1.21
  jboss-seam  src/ui/META-INF/seam.taglib.xml   1.18
  jboss-seam  src/ui/META-INF/taglib.tld        1.22


Commit from gavin (2006-12-05 08:20 EST)
-----------------

migrate to new build

  jboss-seam  examples/remoting/chatroom/build.xml                              1.10
  jboss-seam  examples/remoting/chatroom/resources/META-INF/application.xml     1.7
  jboss-seam  examples/remoting/helloworld/build.xml                            1.10
  jboss-seam  examples/remoting/helloworld/resources/META-INF/application.xml   1.6
  jboss-seam  examples/remoting/progressbar/build.xml                           1.8
  jboss-seam  examples/remoting/progressbar/resources/META-INF/application.xml  1.4


Commit from gavin (2006-12-05 08:23 EST)
-----------------

migrate to new build

  jboss-seam  examples/booking/build.xml                               1.45
  jboss-seam  examples/booking/resources/META-INF/application.xml      1.6
  jboss-seam  examples/booking/resources/WEB-INF/web.xml               1.32
- jboss-seam  examples/booking/resources/WEB-INF/lib/el-api.jar        1.5
- jboss-seam  examples/booking/resources/WEB-INF/lib/el-ri.jar         1.5
- jboss-seam  examples/booking/resources/WEB-INF/lib/jsf-facelets.jar  1.7
  jboss-seam  examples/dvdstore/build.xml                              1.38
- jboss-seam  examples/dvdstore/lib/el-api.jar                         1.4
- jboss-seam  examples/dvdstore/lib/el-ri.jar                          1.4
- jboss-seam  examples/dvdstore/lib/jsf-facelets.jar                   1.5
  jboss-seam  examples/dvdstore/resources/META-INF/application.xml     1.6


Commit from gavin (2006-12-05 08:24 EST)
-----------------

migrate to new build

  jboss-seam  examples/booking/resources/WEB-INF/web.xml            1.33
  jboss-seam  examples/icefaces/build.xml                           1.6
  jboss-seam  examples/icefaces/resources/META-INF/application.xml  1.6
  jboss-seam  examples/hibernate/build.xml                          1.13


Commit from gavin (2006-12-05 08:29 EST)
-----------------

migrate to new build

  jboss-seam  examples/blog/build.xml                                  1.13
  jboss-seam  examples/blog/resources/META-INF/application.xml         1.4
  jboss-seam  examples/contactlist/build.xml                           1.8
  jboss-seam  examples/contactlist/resources/META-INF/application.xml  1.4
  jboss-seam  examples/drools/build.xml                                1.2
  jboss-seam  examples/drools/resources/META-INF/application.xml       1.6
- jboss-seam  examples/icefaces/resources/WEB-INF/lib/el-api.jar       1.3
- jboss-seam  examples/icefaces/resources/WEB-INF/lib/el-ri.jar        1.4
  jboss-seam  examples/issues/build.xml                                1.22
  jboss-seam  examples/issues/resources/META-INF/application.xml       1.5
  jboss-seam  examples/messages/build.xml                              1.12
  jboss-seam  examples/numberguess/build.xml                           1.16
  jboss-seam  examples/registration/build.xml                          1.27
  jboss-seam  examples/seampay/build.xml                               1.2
  jboss-seam  examples/seampay/resources/META-INF/application.xml      1.4
  jboss-seam  examples/todo/build.xml                                  1.18


Commit from gavin (2006-12-05 08:31 EST)
-----------------

the new build

  jboss-seam  build.xml  1.115


Commit from gavin (2006-12-05 08:51 EST)
-----------------

get rid of mail example

- jboss-seam  examples/jbms/build.xml                                            1.3
- jboss-seam  examples/jbms/readme.txt                                           1.4
- jboss-seam  examples/jbms/resources/META-INF/application.xml                   1.3
- jboss-seam  examples/jbms/resources/META-INF/ejb-jar.xml                       1.4
- jboss-seam  examples/jbms/resources/META-INF/jboss-app.xml                     1.3
- jboss-seam  examples/jbms/resources/META-INF/persistence.xml                   1.3
- jboss-seam  examples/jbms/resources/WEB-INF/faces-config.xml                   1.2
- jboss-seam  examples/jbms/resources/WEB-INF/web.xml                            1.4
- jboss-seam  examples/jbms/src/org/jboss/seam/example/jbms/Register.java        1.2
- jboss-seam  examples/jbms/src/org/jboss/seam/example/jbms/RegisterAction.java  1.5
- jboss-seam  examples/jbms/src/org/jboss/seam/example/jbms/User.java            1.2
- jboss-seam  examples/jbms/view/index.html                                      1.2
- jboss-seam  examples/jbms/view/register.jsp                                    1.3
- jboss-seam  examples/jbms/view/registered.jsp                                  1.2
- jboss-seam  examples/jbms/resources/seam.properties                            1.2


Commit from gavin (2006-12-05 10:06 EST)
-----------------

move facelets to lib

- jboss-seam  facelets/readme.txt            1.2
- jboss-seam  facelets/lib/el-api.jar        1.3
- jboss-seam  facelets/lib/el-ri.jar         1.3
- jboss-seam  facelets/lib/jsf-facelets.jar  1.3
+ jboss-seam  lib/jsf-facelets.jar           1.1


Commit from gavin (2006-12-05 10:14 EST)
-----------------

add el jars

  jboss-seam  examples/messages/resources/META-INF/application.xml      1.6
  jboss-seam  examples/numberguess/resources/META-INF/application.xml   1.8
  jboss-seam  examples/registration/resources/META-INF/application.xml  1.10
  jboss-seam  examples/todo/resources/META-INF/application.xml          1.8


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-05 10:27 EST)
------------------------------------------------------

Ported stuff from 1.3.0.SP4 + upgraded JGroups

  JBossCache  lib/jgroups.jar                                      1.4.2.2
  JBossCache  tests/functional/org/jboss/cache/LifeCycleTest.java  1.2.4.1


Commit from msurtani (2006-12-05 10:27 EST)
--------------------

JBCACHE-813

- JBossCache  tests/functional/org/jboss/cache/JGroupsConfigTest.java  1.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-05 10:27 EST)
------------------------------------------------------

Ported stuff from 1.3.0.SP4 + upgraded JGroups

  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java        1.24.2.1
  JBossCache  tests/functional/org/jboss/cache/transaction/TransactionTest.java        1.9.4.1
  JBossCache  tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java   1.13.2.1
  JBossCache  tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java  1.2.2.1
  JBossCache  tests/functional/org/jboss/cache/lock/UpgradeLockTest.java               1.2.2.1
  JBossCache  tests/functional/org/jboss/cache/lock/LockReleaseTest.java               1.1.20.1
  JBossCache  src/org/jboss/cache/TreeCache.java                                       1.195.2.27


Commit from gavin (2006-12-05 11:20 EST)
-----------------

fix the jsp examples

  jboss-seam  examples/blog/build.xml               1.14
  jboss-seam  examples/booking/build.xml            1.46
  jboss-seam  examples/contactlist/build.xml        1.9
  jboss-seam  examples/drools/build.xml             1.3
  jboss-seam  examples/dvdstore/build.xml           1.39
  jboss-seam  examples/hibernate/build.xml          1.14
  jboss-seam  examples/icefaces/build.xml           1.7
  jboss-seam  examples/messages/build.xml           1.13
  jboss-seam  examples/numberguess/build.xml        1.17
  jboss-seam  examples/remoting/chatroom/build.xml  1.11
  jboss-seam  examples/seampay/build.xml            1.3
  jboss-seam  examples/todo/build.xml               1.19


Commit from gavin (2006-12-05 11:21 EST)
-----------------

make it work on tomcat

  jboss-seam  build.xml  1.116


Commit from gavin (2006-12-05 11:30 EST)
-----------------

remove mailstuff

- jboss-seam  lib/mailstuff.jar  1.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-05 11:35 EST)
------------------------------------------------------

Ported stuff from 1.3.0.SP4

  JBossCache  tests/stress/org/jboss/cache/LocalStressTest.java  1.3.2.1


Commit from gavin (2006-12-05 12:05 EST)
-----------------

put el in the ear

  jboss-seam  seam-gen/build.xml                           1.44
  jboss-seam  seam-gen/build-scripts/build.xml             1.15
  jboss-seam  seam-gen/build-scripts-wtp/build.xml         1.7
  jboss-seam  seam-gen/resources/META-INF/application.xml  1.4


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-05 12:16 EST)
------------------------------------------------------

Ported stuff from 1.3.0.SP4

  JBossCache  src/org/jboss/cache/TreeCache.java                                1.195.2.28
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.20.2.3


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-05 12:22 EST)
------------------------------------------------------

Updated the default logging settings

  JBossCache  etc/log4j.xml  1.10.2.1


Commit from gavin (2006-12-05 12:24 EST)
-----------------

oops, make it work on jboss

  jboss-seam  build.xml  1.117


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-05 12:25 EST)
------------------------------------------------------

Some fine-tunings

  JBossCache  src/org/jboss/cache/TreeCache.java                                1.142.2.7
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.14.2.9


Commit from gavin (2006-12-05 14:37 EST)
-----------------

JBSEAM-563

  jboss-seam  src/main/org/jboss/seam/core/Ejb.java             1.19
  jboss-seam  src/main/org/jboss/seam/init/Initialization.java  1.131


Commit from gavin (2006-12-05 14:48 EST)
-----------------

facelets dir is gone

  jboss-seam  build.xml  1.118


Commit from gavin (2006-12-05 15:28 EST)
-----------------

update

  jboss-seam  doc/reference/en/modules/configuration.xml  1.32
  jboss-seam  doc/reference/en/modules/tutorial.xml       1.75


Commit from bstansberry (2006-12-05 18:07 EST)
-----------------------

Port JBCACHE-874 tests from 1.4.0 branch

  JBossCache  tests/functional/org/jboss/cache/marshall/SyncReplTest.java    1.12
  JBossCache  tests/functional/org/jboss/cache/marshall/AsyncReplTest.java   1.12
+ JBossCache  tests/functional/org/jboss/cache/marshall/FooClassLoader.java  1.2
+ JBossCache  tests/functional/org/jboss/cache/marshall/Foo.notjava          1.2
+ JBossCache  tests/functional/org/jboss/cache/marshall/Foo.clazz            1.2


Commit from sbryzak2 (2006-12-05 18:19 EST)
--------------------

updated build files

  jboss-seam  examples/remoting/poker/build.xml             1.2
  jboss-seam  examples/remoting/stories/build.xml           1.5
  jboss-seam  examples/seamspace/build.xml                  1.4
  jboss-seam  examples/seamspace/resources/WEB-INF/web.xml  1.2


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-05 18:33 EST)
---------------------------------------------------------

Add FC

  JBossCache  etc/META-INF/replAsync-optimistic-service.xml        1.8.2.1
  JBossCache  etc/META-INF/replAsync-service.xml                   1.7.2.1
  JBossCache  etc/META-INF/replAsyncSharedCacheLoader-service.xml  1.9.2.1


Commit from bstansberry (2006-12-05 18:35 EST)
-----------------------

Add FC

  JBossCache  etc/META-INF/replAsync-optimistic-service.xml                 1.12
  JBossCache  etc/META-INF/replAsync-service.xml                            1.12
  JBossCache  etc/META-INF/replAsyncSharedCacheLoader-service.xml           1.13
  JBossCache  etc/META-INF/optimal-for-large-cluster-http-session-repl.xml  1.12


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-05 18:37 EST)
---------------------------------------------------------

Add FC

  JBossCache  etc/META-INF/optimal-for-large-cluster-http-session-repl.xml  1.8.2.1


Commit from gavin (2006-12-05 21:49 EST)
-----------------

ws

  jboss-seam  examples/dvdstore/resources/WEB-INF/web.xml  1.15


Commit from gavin (2006-12-05 22:17 EST)
-----------------

get rid of broken example

- jboss-seam  examples/remoting/stories/build.xml                               1.6
- jboss-seam  examples/remoting/stories/resources/stories-ds.xml                1.2
- jboss-seam  examples/remoting/stories/resources/META-INF/application.xml      1.4
- jboss-seam  examples/remoting/stories/resources/META-INF/jboss-app.xml        1.2
- jboss-seam  examples/remoting/stories/resources/META-INF/persistence.xml      1.3
- jboss-seam  examples/remoting/stories/resources/WEB-INF/faces-config.xml      1.2
- jboss-seam  examples/remoting/stories/resources/WEB-INF/pages.xml             1.3
- jboss-seam  examples/remoting/stories/resources/WEB-INF/web.xml               1.4
- jboss-seam  examples/remoting/stories/src/stories/Project.java                1.2
- jboss-seam  examples/remoting/stories/src/stories/Projects.java               1.2
- jboss-seam  examples/remoting/stories/src/stories/ProjectsBean.java           1.2
- jboss-seam  examples/remoting/stories/src/stories/Stories.java                1.2
- jboss-seam  examples/remoting/stories/src/stories/StoriesBean.java            1.2
- jboss-seam  examples/remoting/stories/src/stories/Story.java                  1.2
- jboss-seam  examples/remoting/stories/view/application.js                     1.2
- jboss-seam  examples/remoting/stories/view/planning.js                        1.2
- jboss-seam  examples/remoting/stories/view/planning.xhtml                     1.2
- jboss-seam  examples/remoting/stories/view/story.js                           1.2
- jboss-seam  examples/remoting/stories/view/story.xhtml                        1.2
- jboss-seam  examples/remoting/stories/view/template.xhtml                     1.3
- jboss-seam  examples/remoting/stories/view/css/application.css                1.2
- jboss-seam  examples/remoting/stories/view/css/planning.css                   1.2
- jboss-seam  examples/remoting/stories/view/img/delete.gif                     1.2
- jboss-seam  examples/remoting/stories/view/img/new_child.png                  1.2
- jboss-seam  examples/remoting/stories/view/js/behaviour.js                    1.2
- jboss-seam  examples/remoting/stories/view/js/controls.js                     1.2
- jboss-seam  examples/remoting/stories/view/js/dragdrop.js                     1.2
- jboss-seam  examples/remoting/stories/view/js/effects.js                      1.2
- jboss-seam  examples/remoting/stories/view/js/event-selectors.js              1.2
- jboss-seam  examples/remoting/stories/view/js/prototype.js                    1.2
- jboss-seam  examples/remoting/stories/resources/WEB-INF/lib/el-api.jar        1.3
- jboss-seam  examples/remoting/stories/resources/WEB-INF/lib/el-ri.jar         1.3
- jboss-seam  examples/remoting/stories/resources/WEB-INF/lib/jsf-facelets.jar  1.2
- jboss-seam  examples/remoting/stories/resources/import.sql                    1.2
- jboss-seam  examples/remoting/stories/resources/seam.properties               1.2


Commit from gavin (2006-12-05 22:23 EST)
-----------------

add el jars

  jboss-seam  examples/remoting/poker/resources/META-INF/application.xml  1.3


Commit from gavin (2006-12-05 22:24 EST)
-----------------

el jars

  jboss-seam  examples/seamspace/build.xml                           1.5
  jboss-seam  examples/seamspace/resources/META-INF/application.xml  1.3


Commit from starksm (2006-12-05 23:08 EST)
-------------------

Add the src zip

+ repository.jboss.com  junit/3.8.1/lib/junit-src.zip  1.1


Commit from gavin (2006-12-05 23:36 EST)
-----------------

fix npe

  jboss-seam  src/main/org/jboss/seam/util/Parameters.java  1.3


Commit from rsigal (2006-12-06 00:09 EST)
------------------

JBREM-644: Removed overriding getTestHarnessLogLevel().

  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization/CallbackStoreCallbackTestCase.java  1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore/NullStoreCallbackTestCase.java                             1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/RestartTestCase.java                                                       1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTestCase.java                                                  1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetector2TestCase.java                                                 1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/connection/ConnectionValidationTestCase.java                                              1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/CallbackTestCase.java                                                            1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/server/CallbackTestCase.java                                            1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/classloader/InvokerTestCase.java                                                          1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/push/disconnect/CallbackTestCase.java                                            1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/CallbackStoreCallbackTestCase.java                     1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/blocking/BlockingStoreCallbackTestCase.java                          1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestCase.java                                            1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/exception/CallbackTestCase.java                                                  1.2


Commit from rsigal (2006-12-06 00:12 EST)
------------------

JBREM-644: Removed overriding getTestHarnessLogLevel().

  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/jboss/JBossSerializationTestCase.java                           1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/invocations/jboss/JBossSerializationTestCase.java               1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/http/multiple/HTTPLeaseTestCase.java                                    1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/socket/multiple/SocketLeaseTestCase.java                                1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/invocations/java/JavaSerializationTestCase.java                 1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/marshall/dynamic/local/MarshallerLoadingTestCase.java                         1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http/HTTPMarshallerLoadingTestCase.java               1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/socket/SocketLeaseTestCase.java                                         1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket/SocketMarshallerLoadingTestCase.java           1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/stream/Streaming2TestCase.java                                                1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/stream/StreamingTestCase.java                                                 1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable/NonSerializableTestCase.java  1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/multiplex/MultiplexLeaseTestCase.java                                   1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/java/JavaSerializationTestCase.java                             1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/http/HTTPLeaseTestCase.java                                             1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/HTTPInvokerTestCase.java                                       1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/ssl/SSLRestartTestCase.java                                    1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/oneway/OnewayInvokerTestCase.java                                             1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/handler/mbean/MBeanHandlerTestCase.java                                       1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/rmi/RMILeaseTestCase.java                                               1.2


Commit from rsigal (2006-12-06 00:15 EST)
------------------

JBREM-644: Reduced test log level to INFO.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/MultiplexInvokerTestCase.java  1.7


Commit from rsigal (2006-12-06 00:15 EST)
------------------

JBREM-644: Removed overriding getTestHarnessLogLevel().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java  1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/ssl/handshake/InvokerTestCase.java                                                1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/RMIInvokerTestCase.java                                                            1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/method/HTTPMethodInvokerTestCase.java                                             1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom/MultiplexInvokerTestCase.java                                     1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/ssl/basic/HTTPSInvokerTestCase.java                                               1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java          1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/chunked/Chunked2TestCase.java                                                     1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/chunked/ChunkedTestCase.java                                                      1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java         1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake/InvokerTestCase.java                                           1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/keep_alive/NoKeepAliveHTTPInvokerTestCase.java                                    1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/compression/CompressedHTTPInvokerTestCase.java                                    1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/SimpleMultiplexTestCase.java                                                 1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/BasicServerSocketTestCase.java                                               1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic/MultiplexInvokerTestCase.java                                      1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestCase.java                                                      1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java               1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java    1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/ssl/custom/HTTPSInvokerTestCase.java                                              1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java       1.2


Commit from gavin (2006-12-06 00:16 EST)
-----------------

set the session timeout

  jboss-seam  examples/dvdstore/resources/WEB-INF/web.xml  1.16
  jboss-seam  examples/booking/resources/WEB-INF/web.xml   1.34


Commit from rsigal (2006-12-06 00:17 EST)
------------------

JBREM-644: Removed overriding getTestHarnessLogLevel().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java             1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake/RMIInvokerTestCase.java                                           1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestCase.java                                           1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerTestCase.java                                              1.7
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerTestCase.java                                    1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transporter/multiInterface/TransporterTestCase.java                                           1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transporter/TransporterTestCase.java                                                          1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/SocketInvokerTestCase.java                                                   1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java    1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionTestCase.java                                     1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestCase.java                                1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java       1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic/RMIInvokerTestCase.java                                               1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerTestCase.java                                               1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake/InvokerTestCase.java                                           1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java          1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check/InvokerTestCase.java                                 1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java  1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom/RMIInvokerTestCase.java                                              1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transporter/proxy/TransporterProxyTestCase.java                                               1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/SSLRMiInvokerTestCase.java                                                  1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java     1.2


Commit from gavin (2006-12-06 00:18 EST)
-----------------

ws

  jboss-seam  examples/dvdstore/resources/WEB-INF/web.xml  1.17
  jboss-seam  examples/booking/resources/WEB-INF/web.xml   1.35


Commit from rsigal on branch remoting_2_x (2006-12-06 00:25 EST)
-----------------------------------------

JBREM-644: Removed overriding getTestHarnessLogLevel().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java        1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/handler/mbean/MBeanHandlerTestCase.java                                                          1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/CallbackTestCase.java                                                                   1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/raw/HTTPInvokerTestCase.java                                                      1.1.2.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/keep_alive/NoKeepAliveHTTPInvokerTestCase.java                                    1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerTestCase.java                                                  1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetectorTestCase.java                                                         1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/JNDIDetector2TestCase.java                                                        1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/RestartTestCase.java                                                              1.1.2.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java     1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/ssl/basic/MultiplexInvokerTestCase.java                                      1.1.8.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java          1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/marshall/dynamic/local/MarshallerLoadingTestCase.java                                            1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java    1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/ssl/handshake/InvokerTestCase.java                                                1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestCase.java                                              1.1.2.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/method/HTTPMethodInvokerTestCase.java                                             1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/compression/CompressedHTTPInvokerTestCase.java                                    1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transporter/TransporterTestCase.java                                                             1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/SSLRMiInvokerTestCase.java                                                     1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/http/multiple/HTTPLeaseTestCase.java                                                       1.1.2.1
  JBossRemoting  src/tests/org/jboss/test/remoting/classloader/InvokerTestCase.java                                                                 1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/custom/RMIInvokerTestCase.java                                                 1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java          1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/http/HTTPLeaseTestCase.java                                                                1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transporter/multiInterface/TransporterTestCase.java                                              1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/SimpleMultiplexTestCase.java                                                 1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/BasicServerSocketTestCase.java                                               1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/HTTPInvokerTestCase.java                                                          1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/chunked/ChunkedTestCase.java                                                      1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/chunked/Chunked2TestCase.java                                                     1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java               1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/oneway/OnewayInvokerTestCase.java                                                                1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/multiplex/MultiplexLeaseTestCase.java                                                      1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/invocations/jboss/nonserializable/NonSerializableTestCase.java                     1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/socket/SocketLeaseTestCase.java                                                            1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/handshake/RMIInvokerTestCase.java                                              1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/no_connection_check/InvokerTestCase.java                                    1.2.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transporter/proxy/TransporterProxyTestCase.java                                                  1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/jboss/JBossSerializationTestCase.java                                              1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/ssl/custom/MultiplexInvokerTestCase.java                                     1.1.8.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerTestCase.java                                       1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/invocations/jboss/JBossSerializationTestCase.java                                  1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/stream/StreamingTestCase.java                                                                    1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/stream/Streaming2TestCase.java                                                                   1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/SocketInvokerTestCase.java                                                      1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/handshake/InvokerTestCase.java                                              1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java                1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/blocking/BlockingStoreCallbackTestCase.java                                 1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/push/disconnect/CallbackTestCase.java                                                   1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/ssl/basic/HTTPSInvokerTestCase.java                                               1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/ssl/handshake/InvokerTestCase.java                                           1.2.4.2
  JBossRemoting  src/tests/org/jboss/test/remoting/lease/socket/multiple/SocketLeaseTestCase.java                                                   1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/ssl/basic/RMIInvokerTestCase.java                                                  1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/rmi/RMIInvokerTestCase.java                                                            1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/java/JavaSerializationTestCase.java                                                1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_mbean/SocketFactoryByMBeanTestCase.java             1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/server/CallbackTestCase.java                                                   1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java       1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionTestCase.java                                        1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestCase.java                                   1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/marshall/dynamic/remote/socket/SocketMarshallerLoadingTestCase.java                              1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/CallbackStoreCallbackTestCase.java                            1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/ssl/custom/HTTPSInvokerTestCase.java                                              1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/serialization/invocations/java/JavaSerializationTestCase.java                                    1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/connection/ConnectionValidationTestCase.java                                                     1.2.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/callbackstore/jbossSerialization/CallbackStoreCallbackTestCase.java         1.1.2.1
  JBossRemoting  src/tests/org/jboss/test/remoting/marshall/dynamic/remote/http/HTTPMarshallerLoadingTestCase.java                                  1.3.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerTestCase.java                                                 1.6.6.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestCase.java                                                   1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/detection/jndi/ssl/SSLRestartTestCase.java                                                       1.1.2.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/exception/CallbackTestCase.java                                                         1.1.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java       1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/pull/memory/nullstore/NullStoreCallbackTestCase.java                                    1.4.10.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/http/connection/socketfactory/by_instance/SocketFactoryByInstanceTestCase.java         1.1.8.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/multiplex/connection/socketfactory/by_classname/SocketFactoryByClassnameTestCase.java  1.1.8.1


Commit from starksm (2006-12-06 00:33 EST)
-------------------

Add a jbossws-src.zip for the snapshot

  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml      1.32
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar    1.27
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar     1.26
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar      1.27
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar  1.38
+ repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-src.zip     1.1
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar         1.38
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061206/97dcfb05/attachment.html 

From gavin.king at jboss.com  Wed Dec  6 01:07:22 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 01:07:22 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GrpwA-0000ZC-JA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 01:07:22

  Modified:    jboss-seam  build.xml
  Log:
  fix proxy deserialization outside of web context
  
  Revision  Changes    Path
  1.119     +65 -64    jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.118
  retrieving revision 1.119
  diff -u -b -r1.118 -r1.119
  --- build.xml	5 Dec 2006 19:48:19 -0000	1.118
  +++ build.xml	6 Dec 2006 06:07:22 -0000	1.119
  @@ -1004,6 +1004,7 @@
               <zipfileset refid="example.war.webinf.lib"/>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
  +                <exclude name="WEB-INF/lib/*.jar"/>
               </zipfileset>
               <zipfileset dir="${build.dir}" prefix="WEB-INF/lib">
                   <include name="${example.name}.jar"/>
  
  
  


From gavin.king at jboss.com  Wed Dec  6 01:07:27 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 01:07:27 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GrpwF-0000ZJ-7h@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 01:07:27

  Modified:    src/main/org/jboss/seam  Component.java
  Log:
  fix proxy deserialization outside of web context
  
  Revision  Changes    Path
  1.216     +7 -9      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.215
  retrieving revision 1.216
  diff -u -b -r1.215 -r1.216
  --- Component.java	4 Dec 2006 01:06:50 -0000	1.215
  +++ Component.java	6 Dec 2006 06:07:26 -0000	1.216
  @@ -121,7 +121,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.215 $
  + * @version $Revision: 1.216 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -262,8 +262,6 @@
   
         initInitializers(applicationContext);
   
  -      //factory = createProxyFactory();
  -
      }
   
      private void initNamespaces(String componentName, Context applicationContext)
  @@ -1064,16 +1062,16 @@
       */
      public Object wrap(Object bean, MethodInterceptor interceptor) throws Exception
      {
  -      Factory proxy = getFactory().newInstance();
  +      Factory proxy = getProxyFactory().newInstance();
         proxy.setCallback(0, interceptor);
         return proxy;
      }
   
  -   private synchronized Class<Factory> getFactory()
  +   private synchronized Class<Factory> getProxyFactory()
      {
         if (factory==null)
         {
  -         factory = createProxyFactory();
  +         factory = createProxyFactory( getType(), getBeanClass(), getBusinessInterfaces() );
         }
         return factory;
      }
  @@ -1455,7 +1453,7 @@
         }
      }
   
  -   private static Set<Class> getBusinessInterfaces(Class clazz)
  +   public static Set<Class> getBusinessInterfaces(Class clazz)
      {
         Set<Class> result = new HashSet<Class>();
   
  @@ -1917,7 +1915,7 @@
         return "Component(" + name + ")";
      }
   
  -   private Class<Factory> createProxyFactory()
  +   public static Class<Factory> createProxyFactory(ComponentType type, Class beanClass, Collection<Class> businessInterfaces)
      {
         Enhancer en = new Enhancer();
         en.setUseCache(false);
  @@ -1927,7 +1925,7 @@
         Set<Class> interfaces = new HashSet<Class>();
         if ( type.isSessionBean() )
         {
  -         interfaces.addAll( getBusinessInterfaces() );
  +         interfaces.addAll(businessInterfaces);
         }
         else
         {
  
  
  


From gavin.king at jboss.com  Wed Dec  6 01:07:32 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 01:07:32 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/intercept   ...
Message-ID: <E1GrpwK-0000ZU-33@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 01:07:32

  Modified:    src/main/org/jboss/seam/intercept  
                        ClientSideInterceptor.java JavaBeanInterceptor.java
  Log:
  fix proxy deserialization outside of web context
  
  Revision  Changes    Path
  1.8       +25 -5     jboss-seam/src/main/org/jboss/seam/intercept/ClientSideInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClientSideInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/ClientSideInterceptor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ClientSideInterceptor.java	13 Nov 2006 20:02:13 -0000	1.7
  +++ ClientSideInterceptor.java	6 Dec 2006 06:07:31 -0000	1.8
  @@ -1,12 +1,14 @@
  -//$Id: ClientSideInterceptor.java,v 1.7 2006/11/13 20:02:13 gavin Exp $
  +//$Id: ClientSideInterceptor.java,v 1.8 2006/12/06 06:07:31 gavin Exp $
   package org.jboss.seam.intercept;
   
   import java.lang.reflect.Method;
   
  +import net.sf.cglib.proxy.Factory;
   import net.sf.cglib.proxy.MethodInterceptor;
   import net.sf.cglib.proxy.MethodProxy;
   
   import org.jboss.seam.Component;
  +import org.jboss.seam.ComponentType;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.ejb.SeamInterceptor;
   
  @@ -21,11 +23,13 @@
   {
      
      private final Object bean;
  +   private final Class beanClass;
   
      public ClientSideInterceptor(Object bean, Component component)
      {
         super(InterceptorType.CLIENT);
         this.bean = bean;
  +      this.beanClass = component.getBeanClass();
         init(component);
      }
      
  @@ -81,16 +85,32 @@
      //TODO: copy/paste from JavaBean interceptor
      Object readResolve()
      {
  -      Component comp = getComponent();
  -      if (comp==null)
  +      Component comp = null;
  +      try
         {
  -         throw new IllegalStateException("No component found: " + getComponentName());
  +         comp = getComponent();
  +      }
  +      catch (IllegalStateException ise) {
  +         //this can occur when tomcat deserializes persistent sessions
         }
         
         try
         {
  +         if (comp==null)
  +         {
  +            Factory proxy = Component.createProxyFactory( 
  +                  ComponentType.STATEFUL_SESSION_BEAN, 
  +                  beanClass, 
  +                  Component.getBusinessInterfaces(beanClass)
  +               ).newInstance();
  +            proxy.setCallback(0, this);
  +            return proxy;
  +         }
  +         else
  +         {
            return comp.wrap(bean, this);
         }
  +      }
         catch (Exception e)
         {
            throw new RuntimeException(e);
  
  
  
  1.10      +25 -5     jboss-seam/src/main/org/jboss/seam/intercept/JavaBeanInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JavaBeanInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/JavaBeanInterceptor.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- JavaBeanInterceptor.java	15 Nov 2006 21:48:19 -0000	1.9
  +++ JavaBeanInterceptor.java	6 Dec 2006 06:07:32 -0000	1.10
  @@ -1,12 +1,14 @@
  -//$Id: JavaBeanInterceptor.java,v 1.9 2006/11/15 21:48:19 gavin Exp $
  +//$Id: JavaBeanInterceptor.java,v 1.10 2006/12/06 06:07:32 gavin Exp $
   package org.jboss.seam.intercept;
   
   import java.lang.reflect.Method;
   
  +import net.sf.cglib.proxy.Factory;
   import net.sf.cglib.proxy.MethodInterceptor;
   import net.sf.cglib.proxy.MethodProxy;
   
   import org.jboss.seam.Component;
  +import org.jboss.seam.ComponentType;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.annotations.ReadOnly;
   import org.jboss.seam.core.Mutable;
  @@ -21,12 +23,14 @@
   {
      
      private final Object bean;
  +   private final Class beanClass;
      private transient boolean dirty;
      
      public JavaBeanInterceptor(Object bean, Component component)
      {
         super(InterceptorType.ANY);
         this.bean = bean;
  +      this.beanClass = component.getBeanClass();
         init(component);
      }
   
  @@ -143,16 +147,32 @@
      // TODO: copy/paste from ClientSide interceptor
      Object readResolve()
      {
  -      Component comp = getComponent();
  -      if (comp==null)
  +      Component comp = null;
  +      try
         {
  -         throw new IllegalStateException("No component found: " + getComponentName());
  +         comp = getComponent();
  +      }
  +      catch (IllegalStateException ise) {
  +         //this can occur when tomcat deserializes persistent sessions
         }
         
         try
         {
  +         if (comp==null)
  +         {
  +            Factory proxy = Component.createProxyFactory( 
  +                  ComponentType.JAVA_BEAN, 
  +                  beanClass, 
  +                  Component.getBusinessInterfaces(beanClass)
  +               ).newInstance();
  +            proxy.setCallback(0, this);
  +            return proxy;
  +         }
  +         else
  +         {
            return comp.wrap(bean, this);
         }
  +      }
         catch (Exception e)
         {
            throw new RuntimeException(e);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 01:12:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 01:12:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r58856 - trunk/testsuite/imports/sections
Message-ID: <E1Grq1V-0000dv-6A@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 01:12:47 -0500 (Wed, 06 Dec 2006)
New Revision: 58856

Modified:
   trunk/testsuite/imports/sections/deployers.xml
Log:
Fix the location of the deployment.wars

Modified: trunk/testsuite/imports/sections/deployers.xml
===================================================================
--- trunk/testsuite/imports/sections/deployers.xml	2006-12-05 23:03:14 UTC (rev 58855)
+++ trunk/testsuite/imports/sections/deployers.xml	2006-12-06 06:12:47 UTC (rev 58856)
@@ -253,17 +253,17 @@
       <!-- build deployment-web.war -->
       <war warfile="${build.lib}/deployment-web.war"
          webxml="${build.resources}/deployment/WEB-INF/web.xml">
-         <fileset dir="${build.classes}">
-            <include name="org/jboss/test/deployment/SampleServlet.class"/>
-         </fileset>
+         <classes dir="${build.classes}">
+            <include name="org/jboss/test/deployment/SampleServlet.class"/>            
+         </classes>
       </war>
       
       <!-- build deployment-web-jboss.war -->
       <war warfile="${build.lib}/deployment-web-jboss.war"
          webxml="${build.resources}/deployment/WEB-INF/web.xml">
-         <fileset dir="${build.classes}">
-            <include name="org/jboss/test/deployment/SampleServlet.class"/>
-         </fileset>
+         <classes dir="${build.classes}">
+            <include name="org/jboss/test/deployment/SampleServlet.class"/>            
+         </classes>
          <fileset dir="${build.resources}/deployment/">
             <include name="META-INF/jboss-web.xml"/>
          </fileset>



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 01:21:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 01:21:05 -0500
Subject: [jboss-cvs] JBossAS SVN: r58857 - in
	branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src:
	resources/test/clusteredentity
	resources/test/clusteredentity/classloader
	test/org/jboss/ejb3/test/clusteredentity
Message-ID: <E1Grq9R-0000o3-9w@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-06 01:21:01 -0500 (Wed, 06 Dec 2006)
New Revision: 58857

Added:
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/test/clusteredentity/classloader/
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/test/clusteredentity/classloader/META-INF/
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/
Removed:
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/test/clusteredentity/classloader/META-INF/
Log:
Port EJBTHREE-798 changes to branch

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/test/clusteredentity/classloader (from rev 58855, branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/classloader)

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/test/clusteredentity/classloader/META-INF (from rev 58855, branches/Branch_4_0/ejb3/src/resources/test/clusteredentity/classloader/META-INF)

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader (from rev 58855, branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader)



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 01:21:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 01:21:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58858 - in branches:
	Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader
	JBoss_4_0_5_GA_EJBTHREE-798/ejb3
	JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity
	JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources
	JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity
	JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit
Message-ID: <E1Grq9Z-0000oM-Iw@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-06 01:21:08 -0500 (Wed, 06 Dec 2006)
New Revision: 58858

Added:
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/DBSetup.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityClassloaderTestBase.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java
Modified:
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java
   branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/build-test.xml
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/TreeCacheProviderHook.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/ejb3-entity-cache-service.xml
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTest.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTestBean.java
   branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityUnitTestCase.java
Log:
Port EJBTHREE-798 changes to branch

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/Account.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -1,24 +1,3 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
 import java.io.Serializable;
@@ -35,12 +14,6 @@
 import org.hibernate.annotations.Cache;
 import org.hibernate.annotations.CacheConcurrencyStrategy;
 
-/**
- * Entity used to test handling of @Lob fields in the second level cache.
- * 
- * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
- * @version $Revision: 1.1 $
- */
 @Entity
 @Cache (usage=CacheConcurrencyStrategy.TRANSACTIONAL)
 @NamedQueries({

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/AccountHolderPK.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -1,24 +1,3 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
 import java.io.IOException;
@@ -27,12 +6,6 @@
 
 import javax.persistence.Embeddable;
 
-/**
- * Class used as an @Lob field in {@link Account}.
- * 
- * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
- * @version $Revision: 1.1 $
- */
 //@Embeddable
 public class AccountHolderPK implements Serializable
 {   

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTest.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -1,32 +1,5 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
-/**
- * SFSB interface for {@link EntityQueryTestBean}.
- * 
- * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
- * @version $Revision: 1.1 $
- */
 public interface EntityQueryTest
 {
 

Modified: branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/classloader/EntityQueryTestBean.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -1,24 +1,3 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.ejb3.test.clusteredentity.classloader;
 
 import java.util.HashSet;
@@ -43,12 +22,6 @@
 import org.jboss.mx.util.MBeanProxyExt;
 import org.jboss.mx.util.MBeanServerLocator;
 
-/**
- * SFSB used for testing @Lob field replication in the second level test.
- * 
- * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
- * @version $Revision: 1.1 $
- */
 @Stateful
 @Remote(EntityQueryTest.class)
 public class EntityQueryTestBean implements EntityQueryTest

Modified: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/build-test.xml
===================================================================
--- branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/build-test.xml	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/build-test.xml	2006-12-06 06:21:08 UTC (rev 58858)
@@ -143,6 +143,7 @@
       <path refid="quartz.quartz.classpath"/>
       <path refid="jboss.microcontainer.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
+      <path refid="hsqldb.hsqldb.classpath"/>
    </path>
 
    <!-- ======= -->
@@ -2574,6 +2575,29 @@
             <include name="META-INF/persistence.xml"/>
          </fileset>
       </jar>
+
+      <jar jarfile="${build.lib}/clusteredentity-classloader-test.jar">
+         <fileset dir="${build.classes}">
+            <include name="org/jboss/ejb3/test/clusteredentity/classloader/*.class"/>
+         </fileset>
+         <fileset dir="${resources}/test/clusteredentity/classloader">
+            <include name="META-INF/persistence.xml"/>
+            <!--include name="META-INF/jboss.xml"/-->
+         </fileset>
+      </jar>
+
+    <jar jarfile="${build.lib}/clusteredentity-classloader-test.ear">
+       <fileset dir="${build.lib}">
+          <include name="clusteredentity-classloader-test.jar"/>
+       </fileset>
+       <fileset dir="${resources}/test/clusteredentity/classloader">
+          <include name="META-INF/application.xml"/>
+          <include name="META-INF/jboss-app.xml"/>
+        <include name="clusteredentity-ds.xml"/>
+       </fileset>
+    </jar>
+   	
+	   
    </target>
 
    <target name="clusteredsession"
@@ -2698,6 +2722,9 @@
 
             <!-- EJBTHREE-485 needs javassist -->
             <path refid="javassist.classpath"/>
+            
+            <!-- For clustered entities -->
+            <path refid="hsqldb.hsqldb.classpath"/>
          </classpath>
 
          <formatter type="plain" usefile="true"/>

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java (from rev 58855, branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/entity/JBCCache.java)

Modified: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/TreeCacheProviderHook.java
===================================================================
--- branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/TreeCacheProviderHook.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/main/org/jboss/ejb3/entity/TreeCacheProviderHook.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -28,7 +28,6 @@
 import org.hibernate.cache.Cache;
 import org.hibernate.cache.CacheException;
 import org.hibernate.cache.CacheProvider;
-import org.hibernate.cache.TreeCache;
 import org.jboss.cache.TreeCacheMBean;
 import org.jboss.ejb3.tx.TxUtil;
 import org.jboss.mx.util.MBeanProxyExt;
@@ -56,7 +55,7 @@
     */
    public Cache buildCache(String regionName, Properties properties) throws CacheException
    {
-      return new TreeCache(cache, regionName, TxUtil.getTransactionManager());
+      return new JBCCache(cache, regionName, TxUtil.getTransactionManager());
    }
 
    public boolean isMinimalPutsEnabledByDefault()

Modified: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/ejb3-entity-cache-service.xml
===================================================================
--- branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/ejb3-entity-cache-service.xml	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/resources/ejb3-entity-cache-service.xml	2006-12-06 06:21:08 UTC (rev 58858)
@@ -38,6 +38,11 @@
              to find each other -->
     <attribute name="ClusterName">EJB3-entity-cache</attribute>
 
+    <!-- Must be true if any entity deployment uses a scoped classloader -->
+    <attribute name="UseRegionBasedMarshalling">true</attribute>
+    <!-- Must match the value of "UseRegionBasedMarshalling" -->
+    <attribute name="InactiveOnStartup">true</attribute>
+    
     <attribute name="ClusterConfig">
       <config>
         <!-- UDP: if you have a multihomed machine,

Modified: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTest.java
===================================================================
--- branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTest.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTest.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -36,4 +36,6 @@
    Customer findByCustomerId(Integer id);
    
    void loadedFromCache();
+   
+   void cleanup();
 }

Modified: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTestBean.java
===================================================================
--- branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTestBean.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/EntityTestBean.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -22,9 +22,11 @@
 package org.jboss.ejb3.test.clusteredentity;
 
 import java.util.HashSet;
+import java.util.Iterator;
 import java.util.Set;
 
 import javax.ejb.Remote;
+import javax.ejb.Remove;
 import javax.ejb.Stateless;
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
@@ -154,6 +156,20 @@
       }
       
    }
+   
+   @Remove
+   public void cleanup()
+   {
+      Customer c = findByCustomerId(1);
+      if (c != null)
+      {
+         Set contacts = c.getContacts();
+         for (Iterator it = contacts.iterator(); it.hasNext();)
+            manager.remove(it.next());
+         c.setContacts(null);
+         manager.remove(c);
+      }
+   }
 
    private TreeCache getCache() throws Exception
    {

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/DBSetup.java (from rev 58855, branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/DBSetup.java)

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityClassloaderTestBase.java (from rev 58855, branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityClassloaderTestBase.java)

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java (from rev 58855, branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java)
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java	2006-12-05 23:03:14 UTC (rev 58855)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryRedeployUnitTestCase.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -0,0 +1,98 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.unit;
+
+import java.util.Properties;
+import javax.naming.InitialContext;
+
+import org.hibernate.cache.StandardQueryCache;
+import org.jboss.ejb3.test.clusteredentity.classloader.Account;
+import org.jboss.ejb3.test.clusteredentity.classloader.AccountHolderPK;
+import org.jboss.ejb3.test.clusteredentity.classloader.EntityQueryTest;
+import org.jboss.jmx.adaptor.rmi.RMIAdaptor;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+/**
+ * Sample client for the jboss container.
+ *
+ * @author <a href="mailto:bill at burkecentral.com">Bill Burke</a>
+ * @version $Id: EntityUnitTestCase.java 57207 2006-09-26 12:06:13Z dimitris at jboss.org $
+ */
+
+public class EntityQueryRedeployUnitTestCase
+extends EntityClassloaderTestBase
+{
+   private static boolean firstNamedRegionTest = true;
+   private static final String EAR_NAME = "clusteredentity-classloader-test.ear";
+   
+   public EntityQueryRedeployUnitTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void testRedeploy() throws Exception
+   {
+      // Set things up with the default region
+      queryTest(true, true, false, true);
+      // Now get the named query regions active
+      queryTest(false, true, true, true);
+      
+      // Don't set this false, as after redeploy it's as if its the first test
+//      firstNamedRegionTest = false;
+      
+      redeploy();
+      
+      // Redo the test, but no entity creation
+      queryTest(false, true, false, true);
+      queryTest(false, true, true, true);
+   }
+   
+   private void redeploy() throws Exception
+   {
+      RMIAdaptor[] adaptors = getAdaptors();
+      undeploy(adaptors[1], EAR_NAME);
+      
+      sleep(2000);
+      
+      deploy(adaptors[1], EAR_NAME);
+      
+      sleep(2000);
+      
+      // Get the SFSB again
+      sfsb1 = getEntityQueryTest(System.getProperty("jbosstest.cluster.node1"));
+   }
+   
+   
+   public static Test suite() throws Exception
+   {
+      TestSuite suite = new TestSuite();
+      Test t1 = getDeploySetup(EntityQueryRedeployUnitTestCase.class, EAR_NAME);
+
+      suite.addTest(t1);
+
+      // Create an initializer for the test suite
+      DBSetup wrapper = new DBSetup(suite);
+      return wrapper;
+   }
+}

Copied: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java (from rev 58855, branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java)
===================================================================
--- branches/Branch_4_0/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java	2006-12-05 23:03:14 UTC (rev 58855)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityQueryUnitTestCase.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -0,0 +1,111 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3.test.clusteredentity.unit;
+
+import java.util.Properties;
+import javax.naming.InitialContext;
+
+import org.hibernate.cache.StandardQueryCache;
+import org.jboss.ejb3.test.clusteredentity.classloader.Account;
+import org.jboss.ejb3.test.clusteredentity.classloader.AccountHolderPK;
+import org.jboss.ejb3.test.clusteredentity.classloader.EntityQueryTest;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+/**
+ * Sample client for the jboss container.
+ *
+ * @author <a href="mailto:bill at burkecentral.com">Bill Burke</a>
+ * @version $Id: EntityUnitTestCase.java 57207 2006-09-26 12:06:13Z dimitris at jboss.org $
+ */
+
+public class EntityQueryUnitTestCase
+extends EntityClassloaderTestBase
+{
+   private static boolean firstNamedRegionTest = true;
+   
+   public EntityQueryUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testManualQueryDefaultRegion() throws Exception
+   {
+      log.info("+++ start testManualQueryDefaultRegion");
+      queryTest(false, false);
+      log.info("+++ end testManualQueryDefaultRegion");
+   }
+   
+   public void testManualQueryNamedRegion() throws Exception
+   {      
+      log.info("+++ start testManualQueryNamedRegion");
+      try
+      {
+         queryTest(false, true);
+      }
+      finally
+      {
+         firstNamedRegionTest = false;
+      }
+      log.info("+++ end testManualQueryNamedRegion");
+   }
+   
+   public void testNamedQueryDefaultRegion() throws Exception
+   {    
+      log.info("+++ start testNamedQueryDefaultRegion");
+      queryTest(true, false);
+      log.info("+++ end testNamedQueryDefaultRegion");
+   }
+   
+   public void testNamedQueryNamedRegion() throws Exception
+   {      
+      log.info("+++ start testNamedQueryNamedRegion");
+      try
+      {
+         queryTest(true, true);
+      }
+      finally
+      {
+         firstNamedRegionTest = false;
+      }
+      log.info("+++ start testNamedQueryNamedRegion");
+   }
+
+   private void queryTest(boolean useNamedQuery, boolean useNamedRegion)
+   {
+      queryTest(true, useNamedQuery, useNamedRegion, firstNamedRegionTest);
+   }
+   
+   public static Test suite() throws Exception
+   {
+      TestSuite suite = new TestSuite();
+      Test t1 = getDeploySetup(EntityQueryUnitTestCase.class, 
+                               "clusteredentity-classloader-test.ear");
+
+      suite.addTest(t1);
+
+      // Create an initializer for the test suite
+      DBSetup wrapper = new DBSetup(suite);
+      return wrapper;
+   }
+}

Modified: branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityUnitTestCase.java
===================================================================
--- branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityUnitTestCase.java	2006-12-06 06:21:01 UTC (rev 58857)
+++ branches/JBoss_4_0_5_GA_EJBTHREE-798/ejb3/src/test/org/jboss/ejb3/test/clusteredentity/unit/EntityUnitTestCase.java	2006-12-06 06:21:08 UTC (rev 58858)
@@ -40,6 +40,8 @@
 {
    org.apache.log4j.Category log = getLog();
 
+   protected static final long SLEEP_TIME = 300L;
+
    static boolean deployed = false;
    static int test = 0;
 
@@ -77,31 +79,43 @@
       
       System.out.println("Create node 0");
       EntityTest tester0 = (EntityTest)ctx0.lookup("EntityTestBean/remote");
-      Customer customer = tester0.createCustomer();
 
-      //Call finder twice since Hibernate seems to not actually save collections 
-      //into cache on persist(), so make sure it is put into cache on find.       
-      System.out.println("Find node 0");
-      customer = tester0.findByCustomerId(customer.getId());
-      System.out.println("Find(2) node 0");
-      customer = tester0.findByCustomerId(customer.getId());
-
-      //Check everything was in cache
-      System.out.println("Check cache 0");
-      tester0.loadedFromCache();
-
-      //Now connect to cache on node2 and make sure it is all there
-      System.out.println("Lookup node 1");
-      InitialContext ctx1 = new InitialContext(prop1);
-      
-      EntityTest tester1 = (EntityTest)ctx1.lookup("EntityTestBean/remote");
-      System.out.println("Find node 1");
-      customer = tester1.findByCustomerId(customer.getId());
-
-      //Check everything was in cache
-      System.out.println("Check cache 1");
-      tester1.loadedFromCache();
-      
+      try
+      {
+         Customer customer = tester0.createCustomer();
+         
+         //Call finder twice since Hibernate seems to not actually save collections 
+         //into cache on persist(), so make sure it is put into cache on find.       
+         System.out.println("Find node 0");
+         customer = tester0.findByCustomerId(customer.getId());
+         System.out.println("Find(2) node 0");
+         customer = tester0.findByCustomerId(customer.getId());
+         
+         //Check everything was in cache
+         System.out.println("Check cache 0");
+         tester0.loadedFromCache();
+   
+         // The above placement of the collection in the cache is replicated async
+         // so pause a bit before checking node 1
+         sleep(SLEEP_TIME);
+         
+         //Now connect to cache on node2 and make sure it is all there
+         System.out.println("Lookup node 1");
+         InitialContext ctx1 = new InitialContext(prop1);
+         
+         EntityTest tester1 = (EntityTest)ctx1.lookup("EntityTestBean/remote");
+         System.out.println("Find node 1");
+         customer = tester1.findByCustomerId(customer.getId());
+   
+         //Check everything was in cache
+         System.out.println("Check cache 1");
+         tester1.loadedFromCache();
+      }
+      finally
+      {
+         // cleanup the db so we can run this test multiple times w/o restarting the cluster
+         tester0.cleanup();
+      }
    }
 
    public static Test suite() throws Exception



From michael.yuan at jboss.com  Wed Dec  6 01:55:39 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 06 Dec 2006 01:55:39 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Grqgt-0001Dy-RX@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/06 01:55:39

  Modified:    seam-gen  build.xml
  Log:
  Add a "create-drop" question in the wizard and add debug support in NB
  
  Revision  Changes    Path
  1.45      +20 -4     jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- build.xml	5 Dec 2006 17:05:53 -0000	1.44
  +++ build.xml	6 Dec 2006 06:55:39 -0000	1.45
  @@ -39,10 +39,19 @@
   	<pathFilename property="driver.file" path="${driver.jar}"/>
   	
   	<condition property="hibernate.hbm2ddl.auto" value="update">
  +           <and>
   		<equals arg1="${database.exists}" arg2="n"/>
  +		<equals arg1="${database.drop}" arg2="n"/>
  +           </and>
   	</condition>
   	<condition property="hibernate.hbm2ddl.auto" value="validate">
  +           <and>
   		<equals arg1="${database.exists}" arg2="y"/>
  +		<equals arg1="${database.drop}" arg2="n"/>
  +           </and>
  +	</condition>
  +	<condition property="hibernate.hbm2ddl.auto" value="create-drop">
  +		<equals arg1="${database.drop}" arg2="y"/>
   	</condition>
       
       <property name="project.home" value="${workspace.home}/${project.name}"/>
  @@ -261,6 +270,12 @@
           	     validargs="y,n,"
                 defaultvalue="${database.exists}"/>
                   
  +        <property name="database.drop" value="n"/>
  +        <input addproperty="database.drop.new" 
  +                   message="Do you want to init the database tables everytime you deploy the app (e.g., to use import.sql) and drop the tables when you undeploy (useful in development)? [${database.drop}] "
  +        	     validargs="y,n,"
  +              defaultvalue="${database.drop}"/>
  +
           <propertyfile file="build.properties">
               <entry key="workspace.home" value="${workspace.home.new}"/>
               <entry key="project.name" value="${project.name.new}"/>
  @@ -271,6 +286,7 @@
               <entry key="test.package" value="${test.package.new}"/>
               <entry key="database.type" value="${database.type.new}"/>
           	<entry key="database.exists" value="${database.exists.new}"/>
  +        	<entry key="database.drop" value="${database.drop.new}"/>
               <entry key="hibernate.dialect" value="${hibernate.dialect.new}"/>
               <entry key="hibernate.connection.driver_class" value="${hibernate.connection.driver_class.new}"/>
               <entry key="hibernate.connection.url" value="${hibernate.connection.url.new}"/>
  @@ -390,8 +406,8 @@
           <mkdir dir="${project.home}/src"/>
   
           <mkdir dir="${project.home}/nbproject"/>
  -        <copy tofile="${project.home}/nbproject/project.xml" 
  -                file="${basedir}/nbproject/project.xml">
  +        <copy todir="${project.home}/nbproject">
  +            <fileset dir="${basedir}/nbproject" />
               <filterset refid="project"/>
           </copy>
           
  
  
  


From michael.yuan at jboss.com  Wed Dec  6 01:55:40 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 06 Dec 2006 01:55:40 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/nbproject    ...
Message-ID: <E1Grqgu-0001EB-1n@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/06 01:55:40

  Modified:    seam-gen/nbproject    project.xml
  Added:       seam-gen/nbproject    debug-jboss.properties
                        ide-file-targets.xml
  Log:
  Add a "create-drop" question in the wizard and add debug support in NB
  
  Revision  Changes    Path
  1.4       +6 -1      jboss-seam/seam-gen/nbproject/project.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: project.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/nbproject/project.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- project.xml	15 Nov 2006 19:14:34 -0000	1.3
  +++ project.xml	6 Dec 2006 06:55:40 -0000	1.4
  @@ -32,6 +32,10 @@
                   <action name="test">
                       <target>test</target>
                   </action>
  +                <action name="debug">
  +                    <script>nbproject/ide-file-targets.xml</script>
  +                    <target>debug-nb</target>
  +                </action> 
               </ide-actions>
               <view>
                   <items>
  @@ -53,10 +57,11 @@
                   </items>
                   <context-menu>
                       <ide-action name="clean"/>
  +                    <ide-action name="restart"/>
  +                    <ide-action name="debug"/>
                       <ide-action name="build"/>
                       <ide-action name="deploy"/>
                       <ide-action name="undeploy"/>
  -                    <ide-action name="restart"/>
                       <ide-action name="test"/>
                   </context-menu>
               </view>
  
  
  
  1.1      date: 2006/12/06 06:55:40;  author: myuan;  state: Exp;jboss-seam/seam-gen/nbproject/debug-jboss.properties
  
  Index: debug-jboss.properties
  ===================================================================
  # JBoss server related settings
  # Edit the following parameter according to your JBoss configuration
  jpda.host=localhost
  jpda.address=4142
  jpda.transport=dt_socket
  
  
  
  1.1      date: 2006/12/06 06:55:40;  author: myuan;  state: Exp;jboss-seam/seam-gen/nbproject/ide-file-targets.xml
  
  Index: ide-file-targets.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <project basedir=".." name="@projectName at -IDE">
      
    <property file="nbproject/debug-jboss.properties"/>
  
    <target name="debug-nb">
      <nbjpdaconnect name="@projectName@" host="${jpda.host}" address="${jpda.address}" transport="${jpda.transport}">
        <!--classpath>
          <path path="exploded-archives/@projectName at .jar"/>
        </classpath>
        <sourcepath>
          <path path="src"/>
        </sourcepath-->
      </nbjpdaconnect>
    </target>
  </project>
  
  
  


From gavin.king at jboss.com  Wed Dec  6 02:36:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 02:36:58 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GrrKs-0001xK-Nr@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 02:36:58

  Modified:    src/main/org/jboss/seam  Component.java
  Log:
  namingpolicy, perhaps
  
  Revision  Changes    Path
  1.217     +8 -2      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.216
  retrieving revision 1.217
  diff -u -b -r1.216 -r1.217
  --- Component.java	6 Dec 2006 06:07:26 -0000	1.216
  +++ Component.java	6 Dec 2006 07:36:58 -0000	1.217
  @@ -121,7 +121,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.216 $
  + * @version $Revision: 1.217 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -1915,13 +1915,19 @@
         return "Component(" + name + ")";
      }
   
  -   public static Class<Factory> createProxyFactory(ComponentType type, Class beanClass, Collection<Class> businessInterfaces)
  +   public static Class<Factory> createProxyFactory(ComponentType type, final Class beanClass, Collection<Class> businessInterfaces)
      {
         Enhancer en = new Enhancer();
         en.setUseCache(false);
         en.setInterceptDuringConstruction(false);
         en.setCallbackType(MethodInterceptor.class);
         en.setSuperclass( type==JAVA_BEAN ? beanClass : Object.class );
  +      /*en.setNamingPolicy( new NamingPolicy() {
  +         public String getClassName(String prefix, String source, Object key, Predicate names)
  +         {
  +            return beanClass.getName() + "SeamProxy";
  +         }
  +      });*/
         Set<Class> interfaces = new HashSet<Class>();
         if ( type.isSessionBean() )
         {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 03:25:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 03:25:17 -0500
Subject: [jboss-cvs] JBossAS SVN: r58859 -
	projects/microcontainer/trunk/build
Message-ID: <E1Grs5d-0002tH-9r@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 03:25:14 -0500 (Wed, 06 Dec 2006)
New Revision: 58859

Modified:
   projects/microcontainer/trunk/build/build.xml
Log:
Update the microcontainer14 install jars

Modified: projects/microcontainer/trunk/build/build.xml
===================================================================
--- projects/microcontainer/trunk/build/build.xml	2006-12-06 06:21:08 UTC (rev 58858)
+++ projects/microcontainer/trunk/build/build.xml	2006-12-06 08:25:14 UTC (rev 58859)
@@ -271,20 +271,14 @@
               version="${jbossbuild.repository.version}"
               >
       <artifact id="jboss-aop-mc-int14.jar"/>
-      <artifact id="jboss-aop-mc-int-boot14.jar"/>
-      <artifact id="jboss-aop-mc-int-deployer14.jar"/>
       <artifact id="jboss-container14.jar"/>
       <artifact id="jboss-dependency14.jar"/>
       <artifact id="jboss-microcontainer14.jar"/>
-      <artifact id="jboss-deployers14.jar"/>
       <export>
          <include input="jboss-aop-mc-int14.jar"/>
-         <include input="jboss-aop-mc-int-boot14.jar"/>
-         <include input="jboss-aop-mc-int-deployer14.jar"/>
          <include input="jboss-container14.jar"/>
          <include input="jboss-dependency14.jar"/>
          <include input="jboss-microcontainer14.jar"/>
-         <include input="jboss-deployers14.jar"/>
       </export>
    </component>
 



From msurtani at jboss.com  Wed Dec  6 05:57:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 05:57:53 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GruTJ-0005bb-IX@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 05:57:53

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_3_0
                        PessimisticLockInterceptor.java
  Log:
  fixed problem with recreating nodes after deletion
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.14.2.10 +4 -4      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.14.2.9
  retrieving revision 1.14.2.10
  diff -u -b -r1.14.2.9 -r1.14.2.10
  --- PessimisticLockInterceptor.java	5 Dec 2006 17:25:45 -0000	1.14.2.9
  +++ PessimisticLockInterceptor.java	6 Dec 2006 10:57:53 -0000	1.14.2.10
  @@ -34,7 +34,7 @@
    * scope of the TX. When no TX is present, we keep track of the locks acquired during the current method and unlock
    * when the method returns
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.9 2006/12/05 17:25:45 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.10 2006/12/06 10:57:53 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor {
      TransactionTable           tx_table=null;
  @@ -244,7 +244,7 @@
            }
   
            // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  -         if (needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation))
  +         if (needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation, createIfNotExists))
            {
               reverseRemove(child_node);
            }
  @@ -275,9 +275,9 @@
         if (isRemoveNodeOperation && gtx != null) cache.getTransactionTable().get(gtx).addRemovedNode(fqn);
      }
   
  -   private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation)
  +   private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation, boolean createIfNotExists)
      {
  -      return !isRemoveOperation && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
  +      return !isRemoveOperation && createIfNotExists && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
      }
   
      private void reverseRemove(DataNode n)
  
  
  


From msurtani at jboss.com  Wed Dec  6 06:36:15 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 06:36:15 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1Grv4R-0006TH-Eh@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 06:36:15

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_3_0
                        PessimisticLockInterceptor.java
  Log:
  gtx test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.14.2.11 +2 -2      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.14.2.10
  retrieving revision 1.14.2.11
  diff -u -b -r1.14.2.10 -r1.14.2.11
  --- PessimisticLockInterceptor.java	6 Dec 2006 10:57:53 -0000	1.14.2.10
  +++ PessimisticLockInterceptor.java	6 Dec 2006 11:36:15 -0000	1.14.2.11
  @@ -34,7 +34,7 @@
    * scope of the TX. When no TX is present, we keep track of the locks acquired during the current method and unlock
    * when the method returns
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.10 2006/12/06 10:57:53 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.14.2.11 2006/12/06 11:36:15 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor {
      TransactionTable           tx_table=null;
  @@ -244,7 +244,7 @@
            }
   
            // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  -         if (needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation, createIfNotExists))
  +         if (gtx!=null && needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation, createIfNotExists))
            {
               reverseRemove(child_node);
            }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 06:38:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 06:38:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r58860 -
	trunk/ejb3/src/main/org/jboss/injection
Message-ID: <E1Grv6p-0006Xq-H6@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-06 06:38:41 -0500 (Wed, 06 Dec 2006)
New Revision: 58860

Added:
   trunk/ejb3/src/main/org/jboss/injection/lang/
Log:
refactored ResourceHandler to clean up duplicate code



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 06:39:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 06:39:10 -0500
Subject: [jboss-cvs] JBossAS SVN: r58861 - in
	trunk/ejb3/src/main/org/jboss/injection: . lang lang/reflect
Message-ID: <E1Grv7G-0006Y9-Lp@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-06 06:38:46 -0500 (Wed, 06 Dec 2006)
New Revision: 58861

Added:
   trunk/ejb3/src/main/org/jboss/injection/AbstractPropertyInjector.java
   trunk/ejb3/src/main/org/jboss/injection/EJBContextPropertyInjector.java
   trunk/ejb3/src/main/org/jboss/injection/JndiPropertyInjector.java
   trunk/ejb3/src/main/org/jboss/injection/TimerServicePropertyInjector.java
   trunk/ejb3/src/main/org/jboss/injection/UserTransactionPropertyInjector.java
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/FieldBeanProperty.java
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/MethodBeanProperty.java
Modified:
   trunk/ejb3/src/main/org/jboss/injection/EJBContextFieldInjector.java
   trunk/ejb3/src/main/org/jboss/injection/EJBContextMethodInjector.java
   trunk/ejb3/src/main/org/jboss/injection/JndiFieldInjector.java
   trunk/ejb3/src/main/org/jboss/injection/JndiMethodInjector.java
   trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java
   trunk/ejb3/src/main/org/jboss/injection/TimerServiceFieldInjector.java
   trunk/ejb3/src/main/org/jboss/injection/TimerServiceMethodInjector.java
   trunk/ejb3/src/main/org/jboss/injection/UserTransactionFieldInjector.java
   trunk/ejb3/src/main/org/jboss/injection/UserTransactionMethodInjector.java
Log:
refactored ResourceHandler to clean up duplicate code

Added: trunk/ejb3/src/main/org/jboss/injection/AbstractPropertyInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/AbstractPropertyInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/AbstractPropertyInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.ejb3.BeanContext;
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public abstract class AbstractPropertyInjector implements Injector
+{
+   protected BeanProperty property;
+   
+   protected AbstractPropertyInjector(BeanProperty property)
+   {
+      this.property = property;
+   }
+   
+   public Class<?> getInjectionClass()
+   {
+      return property.getType();
+   }
+
+   public void inject(BeanContext ctx)
+   {
+      inject(ctx.getInstance());
+   }
+}

Modified: trunk/ejb3/src/main/org/jboss/injection/EJBContextFieldInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/EJBContextFieldInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/EJBContextFieldInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -29,6 +29,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use EJBContextPropertyInjector
  */
 public class EJBContextFieldInjector implements Injector, PojoInjector
 {

Modified: trunk/ejb3/src/main/org/jboss/injection/EJBContextMethodInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/EJBContextMethodInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/EJBContextMethodInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -30,6 +30,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use EJBContextPropertyInjector
  */
 public class EJBContextMethodInjector implements Injector, PojoInjector
 {

Added: trunk/ejb3/src/main/org/jboss/injection/EJBContextPropertyInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/EJBContextPropertyInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/EJBContextPropertyInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,62 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.ejb3.BeanContext;
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Injects an ejb context into an ejb.
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: 1.1 $
+ */
+public class EJBContextPropertyInjector implements Injector, PojoInjector
+{
+   private BeanProperty property;
+
+   public EJBContextPropertyInjector(BeanProperty property)
+   {
+      this.property = property;
+   }
+
+   public void inject(BeanContext ctx)
+   {
+      inject(ctx, ctx.getInstance());
+   }
+   
+   public void inject(BeanContext ctx, Object instance)
+   {
+      property.set(instance, ctx.getEJBContext());
+   }
+
+   public void inject(Object instance)
+   {
+      throw new RuntimeException("Illegal operation");
+   }
+
+   public Class getInjectionClass()
+   {
+      return property.getType();
+   }
+}

Modified: trunk/ejb3/src/main/org/jboss/injection/JndiFieldInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/JndiFieldInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/JndiFieldInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -34,6 +34,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated  use JndiPropertyInjector
  */
 public class JndiFieldInjector implements Injector, PojoInjector
 {
@@ -97,7 +98,7 @@
    {
       
       Object dependency = lookup(jndiName, field.getType());
- //     log.info("!! inject jndiName " + jndiName + " " + field.getType() + " " + dependency);
+      log.trace("!! inject jndiName " + jndiName + " " + field.getType() + " " + dependency);
       
       try
       {

Modified: trunk/ejb3/src/main/org/jboss/injection/JndiMethodInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/JndiMethodInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/JndiMethodInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -33,9 +33,11 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use JndiPropertyInjector
  */
 public class JndiMethodInjector implements Injector, PojoInjector
 {
+   @SuppressWarnings("unused")
    private static final Logger log = Logger.getLogger(JndiMethodInjector.class);
    
    private Method setMethod;

Added: trunk/ejb3/src/main/org/jboss/injection/JndiPropertyInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/JndiPropertyInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/JndiPropertyInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,88 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+
+import org.jboss.ejb3.BeanContext;
+import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.logging.Logger;
+
+/**
+ * Injects a jndi dependency into a bean property.
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class JndiPropertyInjector extends AbstractPropertyInjector implements PojoInjector
+{
+   @SuppressWarnings("unused")
+   private static final Logger log = Logger.getLogger(JndiPropertyInjector.class);
+   
+   private String jndiName;
+   private Context ctx;
+
+   public JndiPropertyInjector(BeanProperty property, String jndiName, Context ctx)
+   {
+      super(property);
+      this.jndiName = jndiName;
+      this.ctx = ctx;
+   }
+
+   public void inject(BeanContext bctx)
+   {
+      inject(bctx, bctx.getInstance());
+   }
+   
+   public Class<?> getInjectionClass()
+   {
+      return property.getType();
+   }
+   
+   protected Object lookup(String jndiName)
+   {
+      Object dependency = null;
+      
+      try
+      {
+         dependency = ctx.lookup(jndiName);
+      }
+      catch (NamingException e)
+      {
+         throw new RuntimeException("Unable to inject jndi dependency: " + jndiName + " into property " + property, e);
+      }
+      return dependency;
+   }
+   
+   public void inject(BeanContext bctx, Object instance)
+   {
+      inject(instance);
+   }
+
+   public void inject(Object instance)
+   {
+      Object value = lookup(jndiName);
+      property.set(instance, value);
+   }
+}

Modified: trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -22,6 +22,9 @@
 package org.jboss.injection;
 
 import org.jboss.ejb3.Container;
+import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.injection.lang.reflect.FieldBeanProperty;
+import org.jboss.injection.lang.reflect.MethodBeanProperty;
 import org.jboss.logging.Logger;
 import org.jboss.metamodel.descriptor.EnvEntry;
 import org.jboss.metamodel.descriptor.EnvironmentRefGroup;
@@ -197,6 +200,10 @@
       Resource ref = method.getAnnotation(Resource.class);
       if (ref == null) return;
 
+      log.trace("method " + method + " has @Resource");
+      
+      handlePropertyAnnotation(ref, new MethodBeanProperty(method), container, injectors);
+      /*
       String encName = ref.name();
       if (encName == null || encName.equals(""))
       {
@@ -282,7 +289,9 @@
          }
          injectors.put(method, new JndiMethodInjector(method, encName, container.getEnc()));
       }
+      */
    }
+   
    public void handleFieldAnnotations(Field field, InjectionContainer container, Map<AccessibleObject, Injector> injectors)
    {
       Resource ref = field.getAnnotation(Resource.class);
@@ -290,6 +299,8 @@
 
       log.trace("field " + field + " has @Resource");
       
+      handlePropertyAnnotation(ref, new FieldBeanProperty(field), container, injectors);
+      /*
       String encName = ref.name();
       if (encName == null || encName.equals(""))
       {
@@ -373,7 +384,106 @@
          }
          injectors.put(field, new JndiFieldInjector(field, encName, container.getEnc()));
       }
+      */
    }
 
+   private void handlePropertyAnnotation(Resource ref, BeanProperty property, InjectionContainer container, Map<AccessibleObject, Injector> injectors)
+   {
+      assert ref != null;
+      assert property != null;
+      assert container != null;
+      assert injectors != null;
+      
+      String encName = ref.name();
+      if (encName == null || encName.equals(""))
+      {
+         //encName = InjectionUtil.getEncName(field);
+         encName = property.getDeclaringClass().getName() + "/" + property.getName();
+      }
+      else
+      {
+         encName = "env/" + encName;
+      }
 
+      AccessibleObject accObj = property.getAccessibleObject();
+      
+      Class<?> type = property.getType();
+      if (!ref.type().equals(Object.class))
+      {
+         type = ref.type();
+      }
+      if (type.equals(UserTransaction.class))
+      {
+         injectors.put(accObj, new UserTransactionPropertyInjector(property, container));
+      }
+      else if (type.equals(TimerService.class))
+      {
+         injectors.put(accObj, new TimerServicePropertyInjector(property, (Container) container)); // only EJBs
+      }
+      else if (EJBContext.class.isAssignableFrom(type))
+      {
+         injectors.put(accObj, new EJBContextPropertyInjector(property));
+      }
+      else if (type.equals(WebServiceContext.class))
+      {
+         // FIXME: For now we skip it, and rely on the WS stack to perform the injection
+      }
+      else if (type.equals(String.class)
+              || type.equals(Character.class)
+              || type.equals(Byte.class)
+              || type.equals(Short.class)
+              || type.equals(Integer.class)
+              || type.equals(Long.class)
+              || type.equals(Boolean.class)
+              || type.equals(Double.class)
+              || type.equals(Float.class)
+              || type.isPrimitive()
+              )
+      {
+         // don't add an injector if no XML <env-entry is present as there will be no value to inject
+         if (container.getEncInjectors().containsKey(encName))
+         {
+            injectors.put(accObj, new JndiPropertyInjector(property, encName, container.getEnc()));
+         }
+         else if (ref.mappedName() != null && ref.mappedName().length() > 0)
+         {
+            // Use the mappedName as the string value
+            String s = ref.mappedName().trim();
+            try
+            {
+               Object value = ValueConvertor.convertValue(type, s);
+               container.getEncInjectors().put(encName, new ValueEncInjector(encName, value, "@Resource"));
+               injectors.put(accObj, new JndiPropertyInjector(property, encName, container.getEnc()));
+            }
+            catch(Throwable t)
+            {
+               throw new RuntimeException("Failed to convert: "+ref.mappedName()+" to type:"+type, t);
+            }
+         }
+         else
+         {
+            log.warn("Not injecting " + property.getName() + ", no matching enc injector " + encName + " found");
+         }
+      }
+      else
+      {
+         if (!container.getEncInjectors().containsKey(encName))
+         {
+            String mappedName = ref.mappedName();
+            if (mappedName == null || mappedName.equals(""))
+            {
+               // TODO: is this a nice trick?
+//               if(ConnectionFactory.class.isAssignableFrom(type))
+//               {
+//                  // neat little trick
+//                  mappedName = "java:/ConnectionFactory";
+//               }
+//               else
+                  throw new RuntimeException("You did not specify a @Resource.mappedName() on " + accObj + " and there is no binding for enc name " + encName + " in XML");
+            }
+            container.getEncInjectors().put(encName, new LinkRefEncInjector(encName, ref.mappedName(), "@Resource"));
+         }
+         injectors.put(accObj, new JndiPropertyInjector(property, encName, container.getEnc()));
+      }      
+   }
 }

Modified: trunk/ejb3/src/main/org/jboss/injection/TimerServiceFieldInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/TimerServiceFieldInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/TimerServiceFieldInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -30,6 +30,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use TimerServicePropertyInjector
  */
 public class TimerServiceFieldInjector implements Injector
 {

Modified: trunk/ejb3/src/main/org/jboss/injection/TimerServiceMethodInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/TimerServiceMethodInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/TimerServiceMethodInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -31,6 +31,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use TimerServicePropertyInjector
  */
 public class TimerServiceMethodInjector implements Injector
 {

Added: trunk/ejb3/src/main/org/jboss/injection/TimerServicePropertyInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/TimerServicePropertyInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/TimerServicePropertyInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,60 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.ejb3.BeanContext;
+import org.jboss.ejb3.Container;
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Injects a timer service into an ejb.
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: 1.1 $
+ */
+public class TimerServicePropertyInjector implements Injector
+{
+   private BeanProperty property;
+   private Container container;
+
+   public TimerServicePropertyInjector(BeanProperty property, Container container)
+   {
+      this.property = property;
+      this.container = container;
+   }
+
+   public void inject(Object instance)
+   {
+      throw new RuntimeException("Illegal operation");
+   }
+
+   public void inject(BeanContext ctx)
+   {
+      property.set(ctx.getInstance(), container.getTimerService());
+   }
+   
+   public Class getInjectionClass()
+   {
+      return property.getType();
+   }
+}

Modified: trunk/ejb3/src/main/org/jboss/injection/UserTransactionFieldInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/UserTransactionFieldInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/UserTransactionFieldInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -35,6 +35,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use UserTransactionPropertyInjector
  */
 public class UserTransactionFieldInjector implements Injector
 {

Modified: trunk/ejb3/src/main/org/jboss/injection/UserTransactionMethodInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/UserTransactionMethodInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/UserTransactionMethodInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -37,6 +37,7 @@
  *
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @version $Revision$
+ * @deprecated use UserTransactionPropertyInjector
  */
 public class UserTransactionMethodInjector implements Injector
 {

Added: trunk/ejb3/src/main/org/jboss/injection/UserTransactionPropertyInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/UserTransactionPropertyInjector.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/UserTransactionPropertyInjector.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,59 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import javax.ejb.TransactionManagementType;
+import javax.transaction.UserTransaction;
+
+import org.jboss.aop.Advisor;
+import org.jboss.ejb3.Container;
+import org.jboss.ejb3.tx.TxUtil;
+import org.jboss.ejb3.tx.UserTransactionImpl;
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Injects a user transaction into a bean property.
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class UserTransactionPropertyInjector extends AbstractPropertyInjector
+{
+   public UserTransactionPropertyInjector(BeanProperty property, InjectionContainer container)
+   {
+      super(property);
+      
+      if (container instanceof Container)
+      {
+         TransactionManagementType type = TxUtil.getTransactionManagementType(((Advisor) container));
+         if (type != TransactionManagementType.BEAN)
+            throw new IllegalStateException("Container " + ((Container) container).getEjbName() + ": it is illegal to inject UserTransaction into a CMT bean");
+      }
+   }
+
+   public void inject(Object instance)
+   {
+      UserTransaction ut = new UserTransactionImpl();
+      property.set(instance, ut);
+   }
+}

Added: trunk/ejb3/src/main/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,47 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.lang.reflect;
+
+import java.lang.reflect.AccessibleObject;
+
+/**
+ * Makes sure that the accessible object is accessible.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public abstract class AbstractAccessibleObjectBeanProperty<T extends AccessibleObject>
+   implements BeanProperty
+{
+   private T obj;
+   
+   protected AbstractAccessibleObjectBeanProperty(T obj)
+   {
+      this.obj = obj;
+      obj.setAccessible(true);
+   }
+   
+   public T getAccessibleObject()
+   {
+      return obj;
+   }
+}

Added: trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.lang.reflect;
+
+import java.lang.reflect.AccessibleObject;
+
+/**
+ * A bean property defines a propery of a pojo from the EJB3 point of view.
+ * It can be used to inject values into it.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface BeanProperty
+{
+   AccessibleObject getAccessibleObject();
+   
+   Class<?> getDeclaringClass();
+   
+   String getName();
+   
+   Class<?> getType();
+   
+   void set(Object instance, Object value);
+}

Added: trunk/ejb3/src/main/org/jboss/injection/lang/reflect/FieldBeanProperty.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/FieldBeanProperty.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/lang/reflect/FieldBeanProperty.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,88 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.lang.reflect;
+
+import java.lang.reflect.Field;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Morphes a field into a bean property.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class FieldBeanProperty extends AbstractAccessibleObjectBeanProperty<Field>
+{
+   private static final Logger log = Logger.getLogger(FieldBeanProperty.class);
+   
+   /**
+    * @param field
+    */
+   public FieldBeanProperty(Field field)
+   {
+      super(field);
+   }
+   
+   public Class<?> getDeclaringClass()
+   {
+      return getField().getDeclaringClass();
+   }
+   
+   protected Field getField()
+   {
+      return getAccessibleObject();
+   }
+   
+   public String getName()
+   {
+      return getField().getName();
+   }
+   
+   public Class<?> getType()
+   {
+      return getField().getType();
+   }
+   
+   /* (non-Javadoc)
+    * @see org.jboss.injection.lang.reflect.BeanProperty#set(java.lang.Object)
+    */
+   public void set(Object instance, Object value)
+   {
+      Field field = getField();
+      try
+      {
+         field.set(instance, value);
+      }
+      catch(IllegalAccessException e)
+      {
+         log.fatal("illegal access on field " + field, e);
+         throw new RuntimeException(e);
+      }
+      catch(IllegalArgumentException e)
+      {
+         String msg = "failed to set value " + value + " on field " + field;
+         log.error(msg, e);
+         throw new IllegalArgumentException(msg);
+      }
+   }
+}

Added: trunk/ejb3/src/main/org/jboss/injection/lang/reflect/MethodBeanProperty.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/MethodBeanProperty.java	2006-12-06 11:38:41 UTC (rev 58860)
+++ trunk/ejb3/src/main/org/jboss/injection/lang/reflect/MethodBeanProperty.java	2006-12-06 11:38:46 UTC (rev 58861)
@@ -0,0 +1,119 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.lang.reflect;
+
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Morphs a setter method into a bean property.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class MethodBeanProperty extends AbstractAccessibleObjectBeanProperty<Method>
+{
+   private final Logger log = Logger.getLogger(MethodBeanProperty.class);
+   
+   private String name = null; // lazily initialized
+   
+   /**
+    * @param method
+    */
+   public MethodBeanProperty(Method method)
+   {
+      super(method);
+      
+      assert method.getReturnType() == Void.TYPE;
+      assert method.getParameterTypes().length == 1;
+      assert method.getName().startsWith("set");
+   }
+
+   public Class<?> getDeclaringClass()
+   {
+      return getMethod().getDeclaringClass();
+   }
+   
+   public String getName()
+   {
+      if(name == null)
+      {
+         String name = getMethod().getName().substring(3);
+         if (name.length() > 1)
+         {
+            name = name.substring(0, 1).toLowerCase() + name.substring(1);
+         }
+         else
+         {
+            name = name.toLowerCase();
+         }
+         this.name = name; // atomair, no synch
+      }
+      return name;
+   }
+   
+   protected Method getMethod()
+   {
+      return getAccessibleObject();
+   }
+   
+   public Class<?> getType()
+   {
+      return getMethod().getParameterTypes()[0];
+   }
+   
+   /* (non-Javadoc)
+    * @see org.jboss.injection.lang.reflect.BeanProperty#set(java.lang.Object, java.lang.Object)
+    */
+   public void set(Object instance, Object value)
+   {
+      Method method = getMethod();
+      Object args[] = { value };
+      try
+      {
+         method.invoke(instance, args);
+      }
+      catch (IllegalAccessException e)
+      {
+         log.fatal("illegal access on method " + method, e);
+         throw new RuntimeException(e);
+      }
+      catch (IllegalArgumentException e)
+      {
+         String msg = "failed to set value " + value + " with setter " + method;
+         log.error(msg, e);
+         throw new IllegalArgumentException(msg);
+      }
+      catch (InvocationTargetException e)
+      {
+         Throwable cause = e.getCause();
+         if(cause instanceof Error)
+            throw (Error) cause;
+         if(cause instanceof RuntimeException)
+            throw (RuntimeException) cause;
+         throw new RuntimeException(cause);
+      }
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 06:42:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 06:42:34 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1711 -
	branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GrvAY-0006ca-Q4@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-06 06:42:33 -0500 (Wed, 06 Dec 2006)
New Revision: 1711

Modified:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
Log:
attempt to fix timing issue on QA machine

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-06 02:07:06 UTC (rev 1710)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-06 11:42:33 UTC (rev 1711)
@@ -21,28 +21,27 @@
   */
 package org.jboss.test.messaging.jms;
 
-import javax.jms.Connection;
 import javax.jms.Destination;
+import javax.jms.TextMessage;
 import javax.jms.MessageConsumer;
+import javax.jms.Session;
+import javax.jms.Connection;
 import javax.jms.MessageProducer;
-import javax.jms.Session;
-import javax.jms.TextMessage;
 import javax.jms.XAConnection;
 import javax.jms.XASession;
 import javax.naming.InitialContext;
 import javax.transaction.TransactionManager;
-import javax.transaction.UserTransaction;
+import javax.transaction.xa.Xid;
 import javax.transaction.xa.XAResource;
-import javax.transaction.xa.Xid;
 
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.messaging.core.tx.XidImpl;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.test.messaging.util.TransactionManagerLocator;
+import org.jboss.tm.TransactionManagerLocator;
 
+import com.arjuna.ats.arjuna.common.Uid;
 import com.arjuna.ats.jta.xa.XidImple;
-import com.arjuna.ats.arjuna.common.Uid;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -52,6 +51,9 @@
 {
    // Constants -----------------------------------------------------
 
+   private final static int MAX_TIMEOUT = 1000 * 60 /* seconds */;
+
+
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------
@@ -99,8 +101,9 @@
 
 
    // Public --------------------------------------------------------
-   
 
+
+   /*
    public void testJBossTSCoordinator() throws Exception
    {
       UserTransaction ut = com.arjuna.ats.jta.UserTransaction.userTransaction();
@@ -110,8 +113,111 @@
 
       ut.commit();
    }
+   */
 
 
+   public void testTransactionalDeliveryRecovery() throws Exception
+   {
+
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queue);
+
+      TextMessage tm1 = sess1.createTextMessage("tm1");
+
+      prod1.send(tm1);
+
+      TextMessage tm2 = sess1.createTextMessage("tm2");
+
+      prod1.send(tm2);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod2 = sess2.createProducer(queue);
+
+      TextMessage tm3 = sess2.createTextMessage("tm3");
+
+      prod2.send(tm3);
+
+      TextMessage tm4 = sess2.createTextMessage("tm4");
+
+      prod2.send(tm4);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+      res.commit(xid1, false);
+
+      res.commit(xid2, false);
+
+      ServerManagement.deployQueue("Queue");
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      MessageConsumer cons = sessRec.createConsumer(queue);
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+      assertNotNull(m1);
+      assertEquals("tm1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+      assertNotNull(m2);
+
+      assertEquals("tm2", m2.getText());
+
+      // TODO
+
+      conn3.close();
+
+   }
+
+
    public void testMockCoordinatorRecovery() throws Exception
    {
 
@@ -190,11 +296,11 @@
       MessageConsumer cons = sessRec.createConsumer(queue);
       conn3.start();
 
-      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m1);
       assertEquals("testing1", m1.getText());
 
-      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m2);
 
       assertEquals("testing2", m2.getText());
@@ -203,7 +309,6 @@
 
    }
 
-
    public void testMockCoordinatorRecoveryWithJBossTSXids() throws Exception
    {
 
@@ -284,11 +389,11 @@
       MessageConsumer cons = sessRec.createConsumer(queue);
       conn3.start();
 
-      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m1);
       assertEquals("testing1", m1.getText());
 
-      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m2);
 
       assertEquals("testing2", m2.getText());
@@ -296,6 +401,7 @@
       conn3.close();
 
    }
+
 /*
    public void testMockCoordinatorRecovery3() throws Exception
    {
@@ -374,11 +480,11 @@
       MessageConsumer cons = sessRec.createConsumer(queue);
       conn3.start();
 
-      TextMessage m1 = (TextMessage)cons.receiveNoWait();
+      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m1);
       assertEquals("testing1", m1.getText());
 
-      TextMessage m2 = (TextMessage)cons.receiveNoWait();
+      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m2);
 
       assertEquals("testing2", m2.getText());



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 06:43:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 06:43:35 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1712 -
	branches/Branch_1_0/src/main/org/jboss/messaging/core/tx
Message-ID: <E1GrvBX-0006ct-Gy@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-06 06:43:33 -0500 (Wed, 06 Dec 2006)
New Revision: 1712

Modified:
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java
Log:
toString implementation

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java	2006-12-06 11:42:33 UTC (rev 1711)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java	2006-12-06 11:43:33 UTC (rev 1712)
@@ -30,6 +30,7 @@
  * Xid implementation
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * 
  * @version $Revision 1.1 $
  */
@@ -121,4 +122,11 @@
       return true;
    }
 
+   public String toString()
+   {
+      return getClass().getName() + "(GID: " + new String(getGlobalTransactionId()) +
+                                    ", Branch: " + new String(getBranchQualifier()) +
+                                    ", Format: " + getFormatId() + ")";
+   }
+
 }



From msurtani at jboss.com  Wed Dec  6 06:44:22 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 06:44:22 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1GrvCI-0006dM-1r@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 06:44:22

  Modified:    tests/functional/org/jboss/cache/replicated  Tag:
                        Branch_JBossCache_1_4_0 SyncCacheListenerTest.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.6.2.1   +5 -1      JBossCache/tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncCacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java,v
  retrieving revision 1.6
  retrieving revision 1.6.2.1
  diff -u -b -r1.6 -r1.6.2.1
  --- SyncCacheListenerTest.java	5 May 2006 12:06:59 -0000	1.6
  +++ SyncCacheListenerTest.java	6 Dec 2006 11:44:22 -0000	1.6.2.1
  @@ -32,7 +32,7 @@
   /**
    * Test out the TreeCacheListener
    *
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.6.2.1 $
    */
   public class SyncCacheListenerTest extends TestCase {
      TreeCache cache1, cache2;
  @@ -133,7 +133,9 @@
            Listener lis = new Listener();
            cache1.addTreeCacheListener(lis);
            lis.put("/a/b/c", "age", new Integer(38));
  +         cache1.getTransactionManager().suspend();
            assertNull("age on cache2 must be null as the TX has not yet been committed", cache2.get("/a/b/c", "age"));
  +         cache1.getTransactionManager().resume(tx);
            tx.commit();
   
            // value on cache2 must be 38
  @@ -199,7 +201,9 @@
            map.put("age", new Integer(38));
            map.put("name", "Ben");
            lis.put("/a/b/c", map);
  +         cache1.getTransactionManager().suspend();
            assertNull("age on cache2 must be null as the TX has not yet been committed", cache2.get("/a/b/c", "age"));
  +         cache1.getTransactionManager().resume(tx);
            tx.commit();
   
            // value on cache2 must be 38
  
  
  


From msurtani at jboss.com  Wed Dec  6 06:44:22 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 06:44:22 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GrvCI-0006dX-62@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 06:44:22

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.4  +4 -6      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.3
  retrieving revision 1.20.2.4
  diff -u -b -r1.20.2.3 -r1.20.2.4
  --- PessimisticLockInterceptor.java	5 Dec 2006 17:16:35 -0000	1.20.2.3
  +++ PessimisticLockInterceptor.java	6 Dec 2006 11:44:22 -0000	1.20.2.4
  @@ -36,7 +36,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.3 2006/12/05 17:16:35 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.4 2006/12/06 11:44:22 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -275,7 +275,7 @@
            }
   
            // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  -         if (needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation))
  +         if (gtx != null && needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isRemoveNodeOperation, createIfNotExists))
            {
               reverseRemove(child_node);
            }
  @@ -309,9 +309,9 @@
         if (isRemoveNodeOperation && gtx != null) cache.getTransactionTable().get(gtx).addRemovedNode(fqn);
      }
   
  -   private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation)
  +   private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation, boolean createIfNotExists)
      {
  -      return !isRemoveOperation && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
  +      return !isRemoveOperation && createIfNotExists && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
      }
   
      private void reverseRemove(DataNode n)
  @@ -445,9 +445,7 @@
       */
      private void rollback(GlobalTransaction tx)
      {
  -      List undo_ops;
         TransactionEntry entry = tx_table.get(tx);
  -      MethodCall undo_op;
   
         if (log.isTraceEnabled())
            log.trace("called to rollback cache with GlobalTransaction=" + tx);
  
  
  


From msurtani at jboss.com  Wed Dec  6 06:44:22 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 06:44:22 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GrvCI-0006di-Ab@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 06:44:22

  Modified:    tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_4_0 IsolationLevelNoneTest.java
  Log:
  ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.20.1  +102 -103  JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelNoneTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java,v
  retrieving revision 1.1
  retrieving revision 1.1.20.1
  diff -u -b -r1.1 -r1.1.20.1
  --- IsolationLevelNoneTest.java	8 Jul 2005 05:58:10 -0000	1.1
  +++ IsolationLevelNoneTest.java	6 Dec 2006 11:44:22 -0000	1.1.20.1
  @@ -7,7 +7,6 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.lock.IsolationLevel;
  -import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.SystemException;
  @@ -16,7 +15,7 @@
   /**
    * Tests whether modifications within callbacks (TreeCacheListener) are handled correctly
    * @author Bela Ban
  - * @version $Id: IsolationLevelNoneTest.java,v 1.1 2005/07/08 05:58:10 msurtani Exp $
  + * @version $Id: IsolationLevelNoneTest.java,v 1.1.20.1 2006/12/06 11:44:22 msurtani Exp $
    */
   public class IsolationLevelNoneTest extends TestCase {
      TreeCache cache=null;
  @@ -84,7 +83,7 @@
         assertTrue(cache.exists(FQN, KEY));
         assertEquals(VALUE, cache.get(FQN, KEY));
         System.out.println("cache: " + cache.toString(true) + ", locks: " + cache.printLockInfo());
  -      assertEquals(4, cache.getNumberOfLocksHeld());
  +      assertEquals(5, cache.getNumberOfLocksHeld());
         tx.commit();
      }
   
  
  
  


From msurtani at jboss.com  Wed Dec  6 07:46:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 07:46:53 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GrwAn-0007p9-MW@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 07:46:53

  Modified:    tests/functional/org/jboss/cache/transaction 
                        TransactionTest.java
  Log:
  Partially brought in tests for JBCACHE-875 and JBCACHE-871
  
  Revision  Changes    Path
  1.18      +281 -86   JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- TransactionTest.java	20 Nov 2006 03:53:57 -0000	1.17
  +++ TransactionTest.java	6 Dec 2006 12:46:53 -0000	1.18
  @@ -15,9 +15,10 @@
   import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
  +import org.jboss.cache.NodeImpl;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.lock.IdentityLock;
   import org.jboss.cache.lock.IsolationLevel;
  -import org.jboss.cache.lock.NodeLock;
   
   import javax.naming.Context;
   import javax.naming.InitialContext;
  @@ -37,7 +38,7 @@
    * Tests transactional access to a local TreeCache.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: TransactionTest.java,v 1.17 2006/11/20 03:53:57 genman Exp $
  + * @version $Id: TransactionTest.java,v 1.18 2006/12/06 12:46:53 msurtani Exp $
    */
   public class TransactionTest extends TestCase
   {
  @@ -152,27 +153,40 @@
      }
   
   
  -   public void testRollbackTx()
  +   public void testGetAfterRemovalRollback() throws Exception
      {
  -      try
  -      {
  -         cache.put("/a/b/c", "age", new Integer(38));
  -         assertNotNull(cache.get("/a/b/c", "age"));
  +      cache.put("/a/b", null);
  +      assertTrue(cache.exists("/a/b"));
            tx.begin();
  -         cache.remove("/a/b/c");
  +      cache.remove("/a/b");
  +      assertFalse(cache.exists("/a/b"));
            tx.rollback();
  -
  -         // This test is done outside the TX, it wouldn't work if someone else
  -         // modified "age". This works because we're the only TX running.
  -         assertNotNull(cache.get("/a/b/c", "age"));
  +      assertTrue(cache.exists("/a/b"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +      // new tx in new thread
  +      Thread th = new Thread()
  +      {
  +         public void run()
  +         {
  +            try
  +            {
  +               cache.getTransactionManager().begin();
  +               assertNotNull(cache.get("/a/b"));
  +               cache.getTransactionManager().rollback();
         }
  -      catch (Throwable t)
  +            catch (Exception e)
         {
  -         t.printStackTrace();
  -         fail(t.toString());
  +               e.printStackTrace();
  +               fail("Caught exception");
         }
      }
  +      };
   
  +      th.start();
  +      th.join();
  +
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +   }
   
      public void testRollbackTx2()
      {
  @@ -360,109 +374,288 @@
      }
   
   
  -   public void testNodeDeletionRollback3()
  +   public void testNodeCreation() throws Exception
  +   {
  +      GlobalTransaction gtx;
  +      cache.put("/a/b", null);
  +      tx.begin();
  +      gtx = cache.getCurrentTransaction();
  +      cache.put("/a/b/c", null);
  +      assertLocked(gtx, "/a", false);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c", true);
  +      System.out.println("locks: " + cache.printLockInfo());
  +   }
  +
  +
  +   public void testNodeCreation2() throws Exception
  +   {
  +      GlobalTransaction gtx;
  +      tx.begin();
  +      gtx = cache.getCurrentTransaction();
  +      cache.put("/a/b/c", null);
  +      assertLocked(gtx, "/a", true);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c", true);
  +      System.out.println("locks: " + cache.printLockInfo());
  +   }
  +
  +
  +   public void testNodeRemoval()
      {
         GlobalTransaction gtx;
         try
         {
  +         cache.put("/a/b/c", null);
  +         tx.begin();
  +         gtx = cache.getCurrentTransaction();
  +         cache.remove("/a/b/c"); // need to remove the node, not just the data in the node.
  +         assertLocked(gtx, "/a", false);
  +         assertLocked(gtx, "/a/b", true);
  +         assertLocked(gtx, "/a/b/c", true);
  +         System.out.println("locks: " + cache.printLockInfo());
  +      }
  +      catch (Throwable t)
  +      {
  +         t.printStackTrace();
  +         fail(t.toString());
  +      }
  +   }
  +
  +
  +   public void testNodeRemoval2()
  +   {
  +      GlobalTransaction gtx;
  +      try
  +      {
  +         cache.put("/a/b/c", null);
  +         tx.begin();
  +         gtx = cache.getCurrentTransaction();
  +         cache.remove("/a/b"); // need to remove the node, not just the data in the node.
  +         assertLocked(gtx, "/a", true);
  +         assertLocked(gtx, "/a/b", true);
  +         assertLocked(gtx, "/a/b/c", true);
  +         System.out.println("locks: " + cache.printLockInfo());
  +      }
  +      catch (Throwable t)
  +      {
  +         t.printStackTrace();
  +         fail(t.toString());
  +      }
  +   }
  +
  +   public void testIntermediateNodeCreationOnWrite() throws Exception
  +   {
  +      cache.put("/a", null);
  +      tx.begin();
  +      cache.put("/a/b/c", null);
  +      // expecting WLs on /a, /a/b and /a/b/c.
  +      GlobalTransaction gtx = cache.getCurrentTransaction();
  +      assertLocked(gtx, "/a", true);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c", true);
  +      tx.rollback();
  +
  +   }
  +
  +   public void testIntermediateNodeCreationOnRead() throws Exception
  +   {
  +      cache.put("/a", null);
  +      tx.begin();
  +      cache.get("/a/b/c");
  +
  +      // expecting RLs on /, /a
  +      // /a/b, /a/b/c should NOT be created!
  +      GlobalTransaction gtx = cache.getCurrentTransaction();
  +      assertLocked(gtx, "/", false);
  +      assertLocked(gtx, "/a", false);
  +      assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +      assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +      tx.rollback();
  +      assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +      assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +
  +   }
  +
  +
  +   public void testIntermediateNodeCreationOnRemove() throws Exception
  +   {
  +      cache.put("/a", null);
  +      tx.begin();
  +      cache.remove("/a/b/c");
  +
  +      // expecting RLs on /, /a
  +      // /a/b, /a/b/c should NOT be created!
  +      GlobalTransaction gtx = cache.getCurrentTransaction();
  +      assertLocked(gtx, "/", false);
  +      assertLocked(gtx, "/a", false);
  +      assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +      assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +      tx.rollback();
  +      assertNull("/a/b should not exist", cache.peek(Fqn.fromString("/a/b")));
  +      assertNull("/a/b/c should not exist", cache.peek(Fqn.fromString("/a/b/c")));
  +
  +   }
  +
  +
  +   public void testNodeDeletionRollback3() throws Exception
  +   {
  +      GlobalTransaction gtx;
  +      cache.put("/a/b/c1", null);
  +
            tx.begin();
            gtx = cache.getCurrentTransaction();
            cache.put("/a/b/c1", null);
  -         checkLock(gtx, "/a", false);
  -         checkLock(gtx, "/a/b", false);
  -         checkLock(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a", false);
  +      assertLocked(gtx, "/a/b", false);
  +      assertLocked(gtx, "/a/b/c1", true);
   
            cache.put("/a/b/c2", null);
  -         checkLock(gtx, "/a/b/c2", true);
  +      assertLocked(gtx, "/a/b", true);
  +      assertLocked(gtx, "/a/b/c2", true);
   
            cache.put("/a/b/c3", null);
            cache.put("/a/b/c1/one", null);
  -         checkLock(gtx, "/a/b/c1", true);
  -         checkLock(gtx, "/a/b/c1/one", true);
  +      assertLocked(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a/b/c1/one", true);
   
            cache.put("/a/b/c1/two", null);
            cache.put("/a/b/c1/one/1", null);
  -         checkLock(gtx, "/a/b/c1", true);
  -         checkLock(gtx, "/a/b/c1/one", true);
  -         checkLock(gtx, "/a/b/c1/one/1", true);
  +      assertLocked(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a/b/c1/one", true);
  +      assertLocked(gtx, "/a/b/c1/one/1", true);
   
            cache.put("/a/b/c1/two/2/3/4", null);
  -         checkLock(gtx, "/a/b/c1", true);
  -         checkLock(gtx, "/a/b/c1/two", true);
  -         checkLock(gtx, "/a/b/c1/two/2", false);
  -         checkLock(gtx, "/a/b/c1/two/2/3", false);
  -         checkLock(gtx, "/a/b/c1/two/2/3/4", true);
  +      assertLocked(gtx, "/a/b/c1", true);
  +      assertLocked(gtx, "/a/b/c1/two", true);
  +      assertLocked(gtx, "/a/b/c1/two/2", true);
  +      assertLocked(gtx, "/a/b/c1/two/2/3", true);
  +      assertLocked(gtx, "/a/b/c1/two/2/3/4", true);
   
            System.out.println("locks: " + cache.printLockInfo());
   
            cache.remove("/a/b");
            tx.rollback();
  -         assertNull(cache.getChildrenNames("/a/b"));
  -      }
  -      catch (Throwable t)
  -      {
  -         t.printStackTrace();
  -         fail(t.toString());
  -      }
  +      assertTrue(cache.getChildrenNames("/a/b/c1").isEmpty());
  +      Set cn = cache.getChildrenNames("/a/b");
  +      assertEquals(1, cn.size());
  +      assertEquals("c1", cn.iterator().next());
      }
   
  -   public void testDoubleLocks()
  -   {
  -      try
  +   public void testDoubleLocks() throws Exception
         {
            tx.begin();
  +      GlobalTransaction gtx = cache.getCurrentTransaction();
            cache.put("/a/b/c", null);
            cache.put("/a/b/c", null);
   
  -         DataNode n = cache.get("/a");
  -         NodeLock lock = n.getNodeSPI().getLock();
  +      NodeImpl n = cache.get("/a");
  +      IdentityLock lock = n.getLock();
            int num = lock.getReaderOwners().size();
  -         assertEquals(1, num);
  +      assertEquals(0, num);
  +      // make sure this is write locked.
  +      assertLocked(gtx, "/a", true);
   
            n = cache.get("/a/b");
  -         lock = n.getNodeSPI().getLock();
  +      lock = n.getLock();
            num = lock.getReaderOwners().size();
  -         assertEquals(1, num);
  -         // added this here since we had stale gtxs lurking about. - Manik, 02Jan06
  +      assertEquals(0, num);
  +      // make sure this is write locked.
  +      assertLocked(gtx, "/a/b", true);
  +
  +      n = cache.get("/a/b/c");
  +      lock = n.getLock();
  +      num = lock.getReaderOwners().size();
  +      assertEquals(0, num);
  +      // make sure this is write locked.
  +      assertLocked(gtx, "/a/b/c", true);
  +
            tx.rollback();
  -      }
  -      catch (Throwable t)
  -      {
  -         t.printStackTrace();
  -         fail(t.toString());
  -      }
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
  -   private void checkLock(Object owner, String fqn, boolean write_locked) throws Exception
  +   private void assertLocked(Object owner, String fqn, boolean write_locked) throws Exception
      {
  -      DataNode n = cache.get(fqn);
  -      NodeLock lock = n.getNodeSPI().getLock();
  +      NodeImpl n = cache.get(fqn);
  +      IdentityLock lock = n.getLock();
         if (owner == null)
  -      {
            owner = Thread.currentThread();
  +      assertTrue("node " + fqn + " is not locked", lock.isLocked());
  +      if (write_locked)
  +      {
  +         assertTrue("node " + fqn + " is not write-locked" + (lock.isReadLocked() ? " but is read-locked instead!" : "!"), lock.isWriteLocked());
         }
  -      if (lock.isLocked() == false)
  +      else
         {
  -         throw new Exception("node " + fqn + " is not locked");
  +         assertTrue("node " + fqn + " is not read-locked" + (lock.isWriteLocked() ? " but is write-locked instead!" : "!"), lock.isReadLocked());
         }
  -      if (write_locked)
  +      assertTrue("owner " + owner + "is not owner", lock.isOwner(owner));
  +   }
  +
  +   public void testConcurrentNodeAccessOnRemovalWithTx() throws Exception
         {
  -         if (lock.isWriteLocked() == false)
  +      cache.put("/a/b/c", null);
  +      tx.begin();
  +      cache.remove("/a/b/c");
  +      // this node should now be locked.
  +      Transaction t = cache.getTransactionManager().suspend();
  +      Transaction t2 = null;
  +      try
            {
  -            throw new Exception("node " + fqn + " is not write-locked");
  +         System.out.println(cache.printLockInfo());
  +         // start a new tx
  +         cache.getTransactionManager().begin();
  +         t2 = cache.getTransactionManager().getTransaction();
  +         cache.get("/a/b/c"); // should fail
  +         t2.commit();
  +         fail("Should not be able to get a hold of /a/b/c until the deleting tx completes");
            }
  +      catch (Exception e)
  +      {
  +         // expected
  +         t2.commit();
         }
  -      else
  +
  +      cache.getTransactionManager().resume(t);
  +      tx.rollback();
  +
  +      assertNotNull(cache.get("/a/b/c"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +   }
  +
  +   public void testConcurrentNodeAccessOnRemovalWithoutTx() throws Exception
  +   {
  +      cache.put("/a/b/c", null);
  +      tx.begin();
  +      cache.remove("/a/b/c");
  +      // this node should now be locked.
  +      Transaction t = cache.getTransactionManager().suspend();
  +      Thread th = new Thread()
         {
  -         if (lock.isReadLocked() == false)
  +         public void run()
            {
  -            throw new Exception("node " + fqn + " is not read-locked");
  -         }
  +            try
  +            {
  +               System.out.println(cache.printLockInfo());
  +               cache.get("/a/b/c"); // should fail
  +
  +               fail("Should not be able to get a hold of /a/b/c until the deleting tx completes");
         }
  -      if (lock.isOwner(owner) == false)
  +            catch (Exception e)
         {
  -         throw new Exception("owner " + owner + "is not owner");
  +               // expected
  +            }
         }
  +      };
  +
  +      th.start();
  +      th.join();
  +
  +      cache.getTransactionManager().resume(t);
  +      tx.rollback();
  +
  +      assertNotNull(cache.get("/a/b/c"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
   
  @@ -480,7 +673,9 @@
         tx.begin();
         cache.remove("/a/b/c");
         System.out.println("locks held (after removing /a/b/c): \n" + cache.printLockInfo());
  -      assertEquals(2, cache.getNumberOfLocksHeld());
  +      // this used to test for 2 locks held.  After the fixes for JBCACHE-875 however, 2 more locks are acquired - for the root node as well as the deleted node.
  +      // and since we would lock all children of the deleted node as well, we have 10 locks here.
  +      assertEquals(10, cache.getNumberOfLocksHeld());
         tx.commit();
         System.out.println("locks held (after committing /a/b/c): \n" + cache.printLockInfo());
         assertEquals(0, cache.getNumberOfLocksHeld());
  @@ -502,7 +697,7 @@
         System.out.println("locks held (before removing /a/b/c): \n" + cache.printLockInfo());
         cache.remove("/a/b/c");
         System.out.println("locks held (after removing /a/b/c): \n" + cache.printLockInfo());
  -      assertEquals(2, cache.getNumberOfLocksHeld());
  +      assertEquals(10, cache.getNumberOfLocksHeld());
         tx.rollback();
         System.out.println("locks held (after rollback): \n" + cache.printLockInfo());
         assertEquals(0, cache.getNumberOfLocksHeld());
  
  
  


From msurtani at jboss.com  Wed Dec  6 07:54:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 07:54:46 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrwIQ-0007vC-IM@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 07:54:46

  Modified:    src/org/jboss/cache  GlobalTransaction.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  1.16      +52 -34    JBossCache/src/org/jboss/cache/GlobalTransaction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransaction.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/GlobalTransaction.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- GlobalTransaction.java	6 Nov 2006 23:34:08 -0000	1.15
  +++ GlobalTransaction.java	6 Dec 2006 12:54:46 -0000	1.16
  @@ -22,9 +22,10 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 12, 2003
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.15 $
  + * @version $Revision: 1.16 $
    */
  -public class GlobalTransaction implements Externalizable {
  +public class GlobalTransaction implements Externalizable
  +{
   
      private static final long serialVersionUID = 8011434781266976149L;
   
  @@ -35,7 +36,7 @@
      private transient boolean remote = false;
   
      // cache the hashcode
  -   private transient int hash_code=-1;  // in the worst case, hashCode() returns 0, then increases, so we're safe here
  +   private transient int hash_code = -1;  // in the worst case, hashCode() returns 0, then increases, so we're safe here
   
       /**
        * empty ctor used by externalization
  @@ -46,11 +47,12 @@
   
      private GlobalTransaction(Address addr)
      {
  -      this.addr=addr;
  -      id=newId();
  +      this.addr = addr;
  +      id = newId();
      }
   
  -   private static synchronized long newId() {
  +   private static synchronized long newId()
  +   {
         return ++sid;
      }
   
  @@ -59,7 +61,8 @@
         return new GlobalTransaction(addr);
      }
   
  -   public Object getAddress() {
  +   public Object getAddress()
  +   {
         return addr;
      }
      
  @@ -68,55 +71,70 @@
         addr = address;
      }
   
  -   public long getId() {
  +   public long getId()
  +   {
         return id;
      }
   
  -   public int hashCode() {
  -      if(hash_code == -1)
  +   public int hashCode()
         {
  -         hash_code=(addr != null ? addr.hashCode() : 0) + (int)id;
  +      if (hash_code == -1)
  +      {
  +         hash_code = (addr != null ? addr.hashCode() : 0) + (int) id;
         }
         return hash_code;
      }
   
  -   public boolean equals(Object other) {
  +   public boolean equals(Object other)
  +   {
         if (this == other)
            return true;
  -      if(!(other instanceof GlobalTransaction))
  +      if (!(other instanceof GlobalTransaction))
            return false;
         return compareTo(other) == 0;
      }
   
  -   public int compareTo(Object o) {
  +   public int compareTo(Object o)
  +   {
         GlobalTransaction other;
         int comp;
  -      if(o == null || !(o instanceof GlobalTransaction))
  +      if (o == null || !(o instanceof GlobalTransaction))
            throw new ClassCastException("GlobalTransaction.compareTo(): other object is " + o);
  -      other=(GlobalTransaction)o;
  -      comp=addr != null ? addr.compareTo(other.addr) : 0;
  -      if(comp == 0)
  +      other = (GlobalTransaction) o;
  +      if (addr == null && other.addr == null)
  +         comp = 0;
  +      else if (addr != null && other.addr == null)
  +         comp = 1;
  +      else if (addr == null && other.addr != null)
  +         comp = -1;
  +      else
  +         comp = addr.compareTo(other.addr);
  +
  +      if (comp == 0)
         {
  -          if(id < other.getId()) comp = -1;
  -          else if(id > other.getId()) comp = 1;
  +         if (id < other.getId()) comp = -1;
  +         else if (id > other.getId()) comp = 1;
         }
         return comp;
      }
   
  -   public String toString() {
  -      StringBuffer sb=new StringBuffer();
  +   public String toString()
  +   {
  +      StringBuffer sb = new StringBuffer();
         sb.append("GlobalTransaction:<").append(addr).append(">:").append(id);
         return sb.toString();
      }
   
  -   public void writeExternal(ObjectOutput out) throws IOException {
  +   public void writeExternal(ObjectOutput out) throws IOException
  +   {
         out.writeObject(addr);
         out.writeLong(id);
         // out.writeInt(hash_code);
      }
   
  -   public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
  -      addr = (Address)in.readObject();
  +   public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
  +   {
  +      addr = (Address) in.readObject();
         id = in.readLong();
         hash_code = -1;
      }
  
  
  


From msurtani at jboss.com  Wed Dec  6 08:01:19 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 08:01:19 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrwOl-00083W-JO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 08:01:19

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        GlobalTransaction.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.1  +6 -16     JBossCache/src/org/jboss/cache/GlobalTransaction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransaction.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/GlobalTransaction.java,v
  retrieving revision 1.13
  retrieving revision 1.13.2.1
  diff -u -b -r1.13 -r1.13.2.1
  --- GlobalTransaction.java	13 Apr 2006 12:02:59 -0000	1.13
  +++ GlobalTransaction.java	6 Dec 2006 13:01:19 -0000	1.13.2.1
  @@ -22,7 +22,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 12, 2003
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.13 $
  + * @version $Revision: 1.13.2.1 $
    */
   public class GlobalTransaction implements Externalizable {
      Address addr=null;
  @@ -83,22 +83,12 @@
            return true;
         if(!(other instanceof GlobalTransaction))
            return false;
  -      return compareTo(other) == 0;
  -   }
   
  -   public int compareTo(Object o) {
  -      GlobalTransaction other;
  -      int comp;
  -      if(o == null || !(o instanceof GlobalTransaction))
  -         throw new ClassCastException("GlobalTransaction.compareTo(): other object is " + o);
  -      other=(GlobalTransaction)o;
  -      comp=addr != null ? addr.compareTo(other.addr) : 0;
  -      if(comp == 0)
  -      {
  -          if(id < other.getId()) comp = -1;
  -          else if(id > other.getId()) comp = 1;
  -      }
  -      return comp;
  +      if(other == null) throw new NullPointerException("GlobalTransaction.compareTo(): other object is null");
  +      
  +      GlobalTransaction otherGtx=(GlobalTransaction)other;
  +
  +      return (addr == null && otherGtx.addr == null) || (addr != null && otherGtx.addr != null && addr.compareTo(otherGtx.addr) == 0) && id == otherGtx.id;
      }
   
      public String toString() {
  
  
  


From msurtani at jboss.com  Wed Dec  6 08:01:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 08:01:53 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrwPJ-00084j-Px@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 08:01:53

  Modified:    src/org/jboss/cache  GlobalTransaction.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  1.17      +5 -24     JBossCache/src/org/jboss/cache/GlobalTransaction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransaction.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/GlobalTransaction.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- GlobalTransaction.java	6 Dec 2006 12:54:46 -0000	1.16
  +++ GlobalTransaction.java	6 Dec 2006 13:01:53 -0000	1.17
  @@ -22,7 +22,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 12, 2003
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    */
   public class GlobalTransaction implements Externalizable
   {
  @@ -91,31 +91,12 @@
            return true;
         if (!(other instanceof GlobalTransaction))
            return false;
  -      return compareTo(other) == 0;
  -   }
   
  -   public int compareTo(Object o)
  -   {
  -      GlobalTransaction other;
  -      int comp;
  -      if (o == null || !(o instanceof GlobalTransaction))
  -         throw new ClassCastException("GlobalTransaction.compareTo(): other object is " + o);
  -      other = (GlobalTransaction) o;
  -      if (addr == null && other.addr == null)
  -         comp = 0;
  -      else if (addr != null && other.addr == null)
  -         comp = 1;
  -      else if (addr == null && other.addr != null)
  -         comp = -1;
  -      else
  -         comp = addr.compareTo(other.addr);
  +      if (other == null) throw new NullPointerException("GlobalTransaction.compareTo(): other object is null");
   
  -      if (comp == 0)
  -      {
  -         if (id < other.getId()) comp = -1;
  -         else if (id > other.getId()) comp = 1;
  -      }
  -      return comp;
  +      GlobalTransaction otherGtx = (GlobalTransaction) other;
  +
  +      return (addr == null && otherGtx.addr == null) || (addr != null && otherGtx.addr != null && addr.compareTo(otherGtx.addr) == 0) && id == otherGtx.id;
      }
   
      public String toString()
  
  
  


From msurtani at jboss.com  Wed Dec  6 08:10:31 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 08:10:31 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache  ...
Message-ID: <E1GrwXf-0008Mw-Ig@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 08:10:31

  Modified:    tests/functional/org/jboss/cache  GlobalTransactionTest.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  1.8       +91 -58    JBossCache/tests/functional/org/jboss/cache/GlobalTransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/GlobalTransactionTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- GlobalTransactionTest.java	22 Aug 2006 11:46:07 -0000	1.7
  +++ GlobalTransactionTest.java	6 Dec 2006 13:10:31 -0000	1.8
  @@ -12,114 +12,124 @@
   import junit.framework.TestSuite;
   import org.jgroups.stack.IpAddress;
   
  -import java.io.*;
  +import java.io.ByteArrayInputStream;
  +import java.io.ByteArrayOutputStream;
  +import java.io.IOException;
  +import java.io.ObjectInputStream;
  +import java.io.ObjectOutputStream;
   import java.net.UnknownHostException;
   
   
   /**
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Id: GlobalTransactionTest.java,v 1.7 2006/08/22 11:46:07 msurtani Exp $
  + * @version $Id: GlobalTransactionTest.java,v 1.8 2006/12/06 13:10:31 msurtani Exp $
    */
  -public class GlobalTransactionTest extends TestCase {
  +public class GlobalTransactionTest extends TestCase
  +{
   
  -   public GlobalTransactionTest(String name) {
  +   public GlobalTransactionTest(String name)
  +   {
         super(name);
      }
   
   
  -
      public void testEquality() throws UnknownHostException
      {
  -      IpAddress a1=new IpAddress("localhost", 4444);
  +      IpAddress a1 = new IpAddress("localhost", 4444);
         GlobalTransaction tx1, tx2;
   
  -      tx1=GlobalTransaction.create(a1);
  -      tx2=GlobalTransaction.create(a1);
  +      tx1 = GlobalTransaction.create(a1);
  +      tx2 = GlobalTransaction.create(a1);
   
         System.out.println("\ntx1: " + tx1 + "\ntx2: " + tx2);
         assertTrue(tx1.equals(tx2) == false);
   
  -      tx2=tx1;
  +      tx2 = tx1;
         assertTrue(tx1.equals(tx2));
   
      }
   
      public void testEqualityWithOtherObject() throws UnknownHostException
      {
  -      IpAddress a1=new IpAddress("localhost", 4444);
  -      GlobalTransaction tx1=GlobalTransaction.create(a1);
  +      IpAddress a1 = new IpAddress("localhost", 4444);
  +      GlobalTransaction tx1 = GlobalTransaction.create(a1);
         System.out.println("\ntx1: " + tx1);
         assertFalse(tx1.equals(Thread.currentThread()));
      }
   
      public void testEqualityWithNull() throws UnknownHostException
      {
  -      IpAddress a1=new IpAddress("localhost", 4444);
  -      GlobalTransaction tx1=GlobalTransaction.create(a1);
  +      IpAddress a1 = new IpAddress("localhost", 4444);
  +      GlobalTransaction tx1 = GlobalTransaction.create(a1);
         System.out.println("\ntx1: " + tx1);
         assertFalse(tx1.equals(null));
      }
   
      public void testHashcode() throws UnknownHostException
      {
  -      IpAddress a1=new IpAddress("localhost", 4444);
  +      IpAddress a1 = new IpAddress("localhost", 4444);
         GlobalTransaction tx1, tx2;
   
   
  -      tx1=GlobalTransaction.create(a1);
  -      tx2=GlobalTransaction.create(a1);
  +      tx1 = GlobalTransaction.create(a1);
  +      tx2 = GlobalTransaction.create(a1);
   
         System.out.println("\ntx1: " + tx1 + "\ntx2: " + tx2);
         assertTrue(tx1.equals(tx2) == false);
   
  -      int hcode_1=tx1.hashCode();
  -      int hcode_2=tx2.hashCode();
  +      int hcode_1 = tx1.hashCode();
  +      int hcode_2 = tx2.hashCode();
         assertFalse(hcode_1 == hcode_2);
   
  -      tx2=tx1;
  +      tx2 = tx1;
         assertTrue(tx1.equals(tx2));
  -      hcode_1=tx1.hashCode();
  -      hcode_2=tx2.hashCode();
  +      hcode_1 = tx1.hashCode();
  +      hcode_2 = tx2.hashCode();
         assertEquals(hcode_1, hcode_2);
      }
   
   
      public void testExternalization() throws UnknownHostException
      {
  -      IpAddress a1=new IpAddress("localhost", 4444);
  -      IpAddress a2=new IpAddress("localhost", 5555);
  -      GlobalTransaction tx1, tx2, tx1_copy=null, tx2_copy=null;
  -      ByteArrayOutputStream bos=null;
  -      ByteArrayInputStream bis=null;
  -      ObjectOutputStream out=null;
  -      ObjectInputStream in=null;
  -      byte[] buf=null;
  -
  -      tx1=GlobalTransaction.create(a1);
  -      tx2=GlobalTransaction.create(a2);
  -
  -      try {
  -         bos=new ByteArrayOutputStream(1024);
  -         out=new ObjectOutputStream(bos);
  +      IpAddress a1 = new IpAddress("localhost", 4444);
  +      IpAddress a2 = new IpAddress("localhost", 5555);
  +      GlobalTransaction tx1, tx2, tx1_copy = null, tx2_copy = null;
  +      ByteArrayOutputStream bos = null;
  +      ByteArrayInputStream bis = null;
  +      ObjectOutputStream out = null;
  +      ObjectInputStream in = null;
  +      byte[] buf = null;
  +
  +      tx1 = GlobalTransaction.create(a1);
  +      tx2 = GlobalTransaction.create(a2);
  +
  +      try
  +      {
  +         bos = new ByteArrayOutputStream(1024);
  +         out = new ObjectOutputStream(bos);
            out.writeObject(tx1);
            out.writeObject(tx2);
            out.flush();
  -         buf=bos.toByteArray();
  +         buf = bos.toByteArray();
         }
  -      catch(IOException ex) {
  +      catch (IOException ex)
  +      {
            fail("creation of output stream");
         }
   
  -      try {
  -         bis=new ByteArrayInputStream(buf);
  -         in=new ObjectInputStream(bis);
  -         tx1_copy=(GlobalTransaction)in.readObject();
  -         tx2_copy=(GlobalTransaction)in.readObject();
  +      try
  +      {
  +         bis = new ByteArrayInputStream(buf);
  +         in = new ObjectInputStream(bis);
  +         tx1_copy = (GlobalTransaction) in.readObject();
  +         tx2_copy = (GlobalTransaction) in.readObject();
         }
  -      catch(IOException ex) {
  +      catch (IOException ex)
  +      {
            fail("creation of input stream");
         }
  -      catch(ClassNotFoundException e) {
  +      catch (ClassNotFoundException e)
  +      {
            e.printStackTrace();
            fail();
         }
  @@ -132,10 +142,10 @@
         assertEquals(tx1, tx1_copy);
         assertEquals(tx2, tx2_copy);
   
  -      int hcode_1=tx1.hashCode();
  -      int hcode_2=tx2.hashCode();
  -      int hcode_3=tx1_copy.hashCode();
  -      int hcode_4=tx2_copy.hashCode();
  +      int hcode_1 = tx1.hashCode();
  +      int hcode_2 = tx2.hashCode();
  +      int hcode_3 = tx1_copy.hashCode();
  +      int hcode_4 = tx2_copy.hashCode();
         assertFalse(hcode_1 == hcode_2);
         assertFalse(hcode_3 == hcode_4);
         assertEquals(hcode_1, hcode_3);
  @@ -143,28 +153,51 @@
      }
   
   
  -   public void testWithNullAddress() {
  +   public void testWithNullAddress()
  +   {
         GlobalTransaction tx1, tx2, tmp_tx1;
   
  -      tx1=GlobalTransaction.create(null);
  -      tx2=GlobalTransaction.create(null);
  +      tx1 = GlobalTransaction.create(null);
  +      tx2 = GlobalTransaction.create(null);
   
  -      tmp_tx1=tx1;
  +      tmp_tx1 = tx1;
         assertEquals(tx1, tmp_tx1);
         assertTrue(tx1.equals(tx2) == false);
      }
   
  +   public void testOneNullAddress() throws UnknownHostException
  +   {
  +      GlobalTransaction tx1, tx2;
  +      tx1 = GlobalTransaction.create(null);
   
  -   void log(String msg) {
  +      assertFalse(tx1.equals(null));
  +
  +      tx2 = GlobalTransaction.create(null);
  +
  +      assertFalse(tx1.equals(tx2));
  +      assertFalse(tx2.equals(tx1));
  +
  +      IpAddress a1 = new IpAddress("localhost", 4444);
  +      tx2 = GlobalTransaction.create(a1);
  +
  +      assertFalse(tx1.equals(tx2));
  +      assertFalse(tx2.equals(tx1));
  +   }
  +
  +
  +   void log(String msg)
  +   {
         System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
      }
   
  -   public static Test suite() {
  -      TestSuite s=new TestSuite(GlobalTransactionTest.class);
  +   public static Test suite()
  +   {
  +      TestSuite s = new TestSuite(GlobalTransactionTest.class);
         return s;
      }
   
  -   public static void main(String[] args) {
  +   public static void main(String[] args)
  +   {
         junit.textui.TestRunner.run(suite());
      }
   
  
  
  


From msurtani at jboss.com  Wed Dec  6 08:10:31 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 08:10:31 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrwXf-0008N4-OY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 08:10:31

  Modified:    src/org/jboss/cache  GlobalTransaction.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  1.18      +3 -4      JBossCache/src/org/jboss/cache/GlobalTransaction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransaction.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/GlobalTransaction.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- GlobalTransaction.java	6 Dec 2006 13:01:53 -0000	1.17
  +++ GlobalTransaction.java	6 Dec 2006 13:10:31 -0000	1.18
  @@ -22,7 +22,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 12, 2003
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class GlobalTransaction implements Externalizable
   {
  @@ -92,11 +92,10 @@
         if (!(other instanceof GlobalTransaction))
            return false;
   
  -      if (other == null) throw new NullPointerException("GlobalTransaction.compareTo(): other object is null");
  -
         GlobalTransaction otherGtx = (GlobalTransaction) other;
   
  -      return (addr == null && otherGtx.addr == null) || (addr != null && otherGtx.addr != null && addr.compareTo(otherGtx.addr) == 0) && id == otherGtx.id;
  +      return ((addr == null && otherGtx.addr == null) || (addr != null && otherGtx.addr != null && addr.compareTo(otherGtx.addr) == 0)) &&
  +              id == otherGtx.id;
      }
   
      public String toString()
  
  
  


From c48 at fullmailmarket.com  Wed Dec  6 08:11:38 2006
From: c48 at fullmailmarket.com (Carrier 179)
Date: Wed, 6 Dec 2006 10:11:38 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?El_Viejito_Pascuero_est=E1_de_viaje?=
	=?iso-8859-1?q?=3F?=
Message-ID: <200612061311.kB6DBfQO030203@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061206/cd671005/attachment.html 

From msurtani at jboss.com  Wed Dec  6 08:12:08 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 08:12:08 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GrwZE-0008Q1-Np@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 08:12:08

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        GlobalTransaction.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.2  +8 -7      JBossCache/src/org/jboss/cache/GlobalTransaction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransaction.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/GlobalTransaction.java,v
  retrieving revision 1.13.2.1
  retrieving revision 1.13.2.2
  diff -u -b -r1.13.2.1 -r1.13.2.2
  --- GlobalTransaction.java	6 Dec 2006 13:01:19 -0000	1.13.2.1
  +++ GlobalTransaction.java	6 Dec 2006 13:12:08 -0000	1.13.2.2
  @@ -22,7 +22,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 12, 2003
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.13.2.1 $
  + * @version $Revision: 1.13.2.2 $
    */
   public class GlobalTransaction implements Externalizable {
      Address addr=null;
  @@ -78,19 +78,20 @@
         return hash_code;
      }
   
  -   public boolean equals(Object other) {
  +   public boolean equals(Object other)
  +   {
         if (this == other)
            return true;
  -      if(!(other instanceof GlobalTransaction))
  +      if (!(other instanceof GlobalTransaction))
            return false;
   
  -      if(other == null) throw new NullPointerException("GlobalTransaction.compareTo(): other object is null");
  -      
  -      GlobalTransaction otherGtx=(GlobalTransaction)other;
  +      GlobalTransaction otherGtx = (GlobalTransaction) other;
   
  -      return (addr == null && otherGtx.addr == null) || (addr != null && otherGtx.addr != null && addr.compareTo(otherGtx.addr) == 0) && id == otherGtx.id;
  +      return ((addr == null && otherGtx.addr == null) || (addr != null && otherGtx.addr != null && addr.compareTo(otherGtx.addr) == 0)) &&
  +                id == otherGtx.id;
      }
   
  +
      public String toString() {
         StringBuffer sb=new StringBuffer();
         sb.append("GlobalTransaction:<").append(addr).append(">:").append(id);
  
  
  


From msurtani at jboss.com  Wed Dec  6 08:12:08 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 08:12:08 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache  ...
Message-ID: <E1GrwZE-0008QC-SO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 08:12:08

  Modified:    tests/functional/org/jboss/cache  Tag:
                        Branch_JBossCache_1_4_0 GlobalTransactionTest.java
  Log:
  JBCACHE-895
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.5.2.2   +25 -2     JBossCache/tests/functional/org/jboss/cache/GlobalTransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GlobalTransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/GlobalTransactionTest.java,v
  retrieving revision 1.5.2.1
  retrieving revision 1.5.2.2
  diff -u -b -r1.5.2.1 -r1.5.2.2
  --- GlobalTransactionTest.java	3 Nov 2006 09:48:13 -0000	1.5.2.1
  +++ GlobalTransactionTest.java	6 Dec 2006 13:12:08 -0000	1.5.2.2
  @@ -12,13 +12,17 @@
   import junit.framework.TestSuite;
   import org.jgroups.stack.IpAddress;
   
  -import java.io.*;
  +import java.io.ByteArrayInputStream;
  +import java.io.ByteArrayOutputStream;
  +import java.io.IOException;
  +import java.io.ObjectInputStream;
  +import java.io.ObjectOutputStream;
   import java.net.UnknownHostException;
   
   
   /**
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Id: GlobalTransactionTest.java,v 1.5.2.1 2006/11/03 09:48:13 msurtani Exp $
  + * @version $Id: GlobalTransactionTest.java,v 1.5.2.2 2006/12/06 13:12:08 msurtani Exp $
    */
   public class GlobalTransactionTest extends TestCase {
   
  @@ -154,6 +158,25 @@
         assertTrue(tx1.equals(tx2) == false);
      }
   
  +   public void testOneNullAddress() throws UnknownHostException
  +   {
  +      GlobalTransaction tx1, tx2;
  +      tx1 = GlobalTransaction.create(null);
  +
  +      assertFalse(tx1.equals(null));
  +
  +      tx2 = GlobalTransaction.create(null);
  +
  +      assertFalse(tx1.equals(tx2));
  +      assertFalse(tx2.equals(tx1));
  +
  +      IpAddress a1 = new IpAddress("localhost", 4444);
  +      tx2 = GlobalTransaction.create(a1);
  +
  +      assertFalse(tx1.equals(tx2));
  +      assertFalse(tx2.equals(tx1));
  +   }
  +
   
      void log(String msg) {
         System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 08:29:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 08:29:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r58862 - in
	projects/microcontainer/trunk/container/src:
	main/org/jboss/beans/info/plugins main/org/jboss/config/plugins
	main/org/jboss/reflect/plugins/introspection
	tests/org/jboss/test tests/org/jboss/test/beaninfo
	tests/org/jboss/test/beaninfo/support
	tests/org/jboss/test/beaninfo/test
Message-ID: <E1Grwq7-0000DX-Db@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-06 08:29:23 -0500 (Wed, 06 Dec 2006)
New Revision: 58862

Added:
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetter.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetterSimpleMerge.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterOnly.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedSetterOnly.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation1.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation2.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoBooleanProperties.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoConstructors.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoEmpty.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterAndSetter.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterOnly.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericInconsistentTypes.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericSetterOnly.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterAndSetter.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterOnly.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoInconsistentTypes.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoMethods.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoSetterOnly.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoUpperPropertyName.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoTestSuite.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoUnitTestCase.java
Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerTest.java
Log:
Tests for BeanInfo, includes:

1) Fix for only showing public constructors
2) Fix for only showing public non-static methods
3) Tests for annotation merging between getter and setter for a property

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -62,6 +62,9 @@
       TypeInfo[] parameters = minfo.getParameterTypes();
       if ((name.length() > 3 && name.startsWith("get")) || (name.length() > 2 && name.startsWith("is")))
       {
+         // isBoolean() is not a getter for java.lang.Boolean
+         if (name.startsWith("is") && returnType.equals(PrimitiveInfo.BOOLEAN) == false)
+            return false;
          if (parameters.length == 0 && PrimitiveInfo.VOID.equals(returnType) == false)
             return true;
       }
@@ -177,7 +180,10 @@
 
       HashSet<ConstructorInfo> result = new HashSet<ConstructorInfo>();
       for (int i = 0; i < cinfos.length; ++i)
-         result.add(cinfos[i]);
+      {
+         if (cinfos[i].isPublic() && cinfos[i].isStatic() == false)
+            result.add(cinfos[i]);
+      }
       return result;
    }
    
@@ -197,7 +203,7 @@
          {
             for (int i = 0; i < minfos.length; ++i)
             {
-               if (result.contains(minfos[i]) == false)
+               if (result.contains(minfos[i]) == false && minfos[i].isPublic() && minfos[i].isStatic() == false)
                   result.add(minfos[i]);
             }
          }
@@ -221,24 +227,21 @@
       {
          for (MethodInfo methodInfo : methods)
          {
-            if (methodInfo.isPublic() && methodInfo.isStatic() == false)
+            String name = methodInfo.getName();
+            String upperName = getUpperPropertyName(name);
+            if (isGetter(methodInfo))
             {
-               String name = methodInfo.getName();
-               String upperName = getUpperPropertyName(name);
-               if (isGetter(methodInfo))
+               getters.put(upperName, methodInfo);
+            }
+            else if (isSetter(methodInfo))
+            {
+               List<MethodInfo> list = setters.get(upperName);
+               if (list == null)
                {
-                  getters.put(upperName, methodInfo);
+                  list = new ArrayList<MethodInfo>();
+                  setters.put(upperName, list);
                }
-               else if (isSetter(methodInfo))
-               {
-                  List<MethodInfo> list = setters.get(upperName);
-                  if (list == null)
-                  {
-                     list = new ArrayList<MethodInfo>();
-                     setters.put(upperName, list);
-                  }
-                  list.add(methodInfo);
-               }
+               list.add(methodInfo);
             }
          }
       }
@@ -272,7 +275,7 @@
             AnnotationValue[] annotations = getter.getAnnotations();
             AnnotationValue[] setterAnnotations = null;
             if (setter != null)
-               setter.getAnnotations();
+               setterAnnotations = setter.getAnnotations();
             if (annotations == null || annotations.length == 0)
                annotations = setterAnnotations;
             else if (setterAnnotations != null && setterAnnotations.length > 0)

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -56,7 +56,9 @@
 
    protected ClassAdapterFactory createDefaultClassAdapterFactory() throws Throwable
    {
-      return new BasicClassAdapterFactory();
+      BasicClassAdapterFactory result = new BasicClassAdapterFactory();
+      result.setConfiguration(this);
+      return result;
    }
 
    protected TypeInfoFactory createDefaultTypeInfoFactory() throws Throwable

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/ParameterizedClassInfo.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -233,10 +233,28 @@
          return false;
       
       ClassInfo other = (ClassInfo) obj;
+      ClassInfo otherDelegate = other;
       if (other instanceof ParameterizedClassInfo)
-         other = ((ParameterizedClassInfo) other).delegate;
+         otherDelegate = ((ParameterizedClassInfo) other).delegate;
       
-      return delegate.equals(other);
+      if (delegate.equals(otherDelegate) == false)
+         return false;
+      
+      // We are equal to the raw type (seems hacky?)
+      if (other instanceof ParameterizedClassInfo == false)
+         return true;
+      
+      TypeInfo[] typeArguments = getActualTypeArguments();
+      TypeInfo[] otherTypeArguments = other.getActualTypeArguments();
+      if (typeArguments.length != otherTypeArguments.length)
+         return false;
+      
+      for (int i = 0; i < typeArguments.length; ++i)
+      {
+         if (typeArguments[i].equals(otherTypeArguments[i]) == false)
+            return false;
+      }
+      return true;
    }
 
    public void toShortString(JBossStringBuilder buffer)

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -25,6 +25,7 @@
 import junit.framework.TestSuite;
 import junit.textui.TestRunner;
 
+import org.jboss.test.beaninfo.test.BeanInfoTestSuite;
 import org.jboss.test.classinfo.test.ClassInfoTestSuite;
 import org.jboss.test.joinpoint.test.JoinpointTestSuite;
 import org.jboss.test.metadata.MetaDataAllTestSuite;
@@ -49,6 +50,7 @@
 
       suite.addTest(ClassInfoTestSuite.suite());
       suite.addTest(JoinpointTestSuite.suite());
+      suite.addTest(BeanInfoTestSuite.suite());
       suite.addTest(MetaDataAllTestSuite.suite());
       suite.addTest(VFSAllTestSuite.suite());
       

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerTest.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerTest.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -23,6 +23,8 @@
 
 import java.util.Arrays;
 
+import junit.framework.AssertionFailedError;
+
 /**
  * A ContainerTest.
  * 
@@ -52,8 +54,29 @@
       if (array != null)
          assertEquals(Arrays.asList(array).toString(), 0, array.length);
    }
-   
+
    /**
+    * Assert two arrays are equal
+    *
+    * TODO fix the abstract test case
+    * @param expected the expected array
+    * @param actual the actual array
+    */
+   protected void assertEquals(Object[] expected, Object[] actual)
+   {
+      if (Arrays.equals(expected, actual) == false)
+      {
+         String expectedString = null;
+         if (expected != null)
+            expectedString = Arrays.asList(expected).toString();
+         String actualString = null;
+         if (actual != null)
+            actualString = Arrays.asList(actual).toString();
+         throw new AssertionFailedError("expected: " + expectedString + " actual: " + actualString);
+      }
+   }
+
+   /**
     * Default setup with security manager enabled
     * 
     * @param clazz the class

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetter.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetter.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetter.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,42 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterAndSetter.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoAnnotatedGetterAndSetter
+{
+   @BeanInfoAnnotation1
+   public int getSomething()
+   {
+      return 0;
+   }
+
+   @BeanInfoAnnotation1
+   public void setSomething(int x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetterSimpleMerge.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetterSimpleMerge.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterAndSetterSimpleMerge.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,42 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterAndSetter.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoAnnotatedGetterAndSetterSimpleMerge
+{
+   @BeanInfoAnnotation1
+   public int getSomething()
+   {
+      return 0;
+   }
+
+   @BeanInfoAnnotation2
+   public void setSomething(int x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterOnly.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterOnly.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedGetterOnly.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterOnly.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoAnnotatedGetterOnly
+{
+   @BeanInfoAnnotation1
+   public int getSomething()
+   {
+      return 0;
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedSetterOnly.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedSetterOnly.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotatedSetterOnly.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoSetterOnly.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoAnnotatedSetterOnly
+{
+   @BeanInfoAnnotation1
+   public void setSomething(BeanInfoGenericClass<String> x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation1.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation1.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation1.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+ * BeanInfoAnnotation1.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface BeanInfoAnnotation1
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation2.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation2.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoAnnotation2.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+ * BeanInfoAnnotation1.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface BeanInfoAnnotation2
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoBooleanProperties.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoBooleanProperties.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoBooleanProperties.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,54 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoBooleanProperties
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoBooleanProperties
+{
+   public boolean isSomething()
+   {
+      return true;
+   }
+
+   public void setSomething(boolean x)
+   {
+   }
+
+   public Boolean getSomethingElse()
+   {
+      return true;
+   }
+
+   public void setSomethingElse(Boolean x)
+   {
+   }
+
+   public Boolean isNotGetter()
+   {
+      return true;
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoConstructors.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoConstructors.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoConstructors.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoConstructors.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoConstructors
+{
+   private BeanInfoConstructors() {}
+   BeanInfoConstructors(int p1) {}
+   protected BeanInfoConstructors(int p1, String p2) {}
+   public BeanInfoConstructors(long p1, String p2) throws IllegalArgumentException, IllegalStateException { }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoEmpty.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoEmpty.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoEmpty.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoEmpty.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoEmpty
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericClass.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericClass.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,33 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGenericClass.
+ *
+ * @param <T> the generic type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGenericClass<T>
+{
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterAndSetter.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterAndSetter.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterAndSetter.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterAndSetter.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGenericGetterAndSetter
+{
+   public BeanInfoGenericClass<String> getSomething()
+   {
+      return null;
+   }
+
+   public void setSomething(BeanInfoGenericClass<String> x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterOnly.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterOnly.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericGetterOnly.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterOnly.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGenericGetterOnly
+{
+   public BeanInfoGenericClass<String> getSomething()
+   {
+      return null;
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericInconsistentTypes.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericInconsistentTypes.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericInconsistentTypes.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGenericInconsistentTypes.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGenericInconsistentTypes
+{
+   public BeanInfoGenericClass<String> getSomething()
+   {
+      return null;
+   }
+
+   public void setSomething(BeanInfoGenericClass<Integer> x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericSetterOnly.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericSetterOnly.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGenericSetterOnly.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,35 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoSetterOnly.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGenericSetterOnly
+{
+   public void setSomething(BeanInfoGenericClass<String> x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterAndSetter.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterAndSetter.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterAndSetter.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterAndSetter.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGetterAndSetter
+{
+   public int getSomething()
+   {
+      return 0;
+   }
+
+   public void setSomething(int x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterOnly.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterOnly.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoGetterOnly.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoGetterOnly.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoGetterOnly
+{
+   public int getSomething()
+   {
+      return 0;
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoInconsistentTypes.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoInconsistentTypes.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoInconsistentTypes.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,34 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+public class BeanInfoInconsistentTypes
+{
+   public String getSomething()
+   {
+      return null;
+   }
+
+   public void setSomething(long x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoMethods.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoMethods.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoMethods.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,60 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoMethodsClass
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoMethods
+{
+   private void voidMethodVoidPrivate() {}
+   private long longMethodVoidPrivate() { return 0; }
+   private void voidMethodintPrivate(int p1) {}
+   private long longMethodintPrivate(int p1) { return 0; }
+   private void voidMethodintStringPrivate(int p1, String p2) {}
+   private long longMethodintStringPrivate(int p1, String p2) { return 0; }
+   private long longMethodintStringThrowsPrivate(int p1, String p2) throws IllegalArgumentException, IllegalStateException { return 0; }
+   void voidMethodVoidPackage() { voidMethodVoidPrivate(); }
+   long longMethodVoidPackage() { return longMethodVoidPrivate(); }
+   void voidMethodintPackage(int p1) { voidMethodintPrivate(p1); }
+   long longMethodintPackage(int p1) { return longMethodintPrivate(p1); }
+   void voidMethodintStringPackage(int p1, String p2) { voidMethodintStringPrivate(p1, p2); }
+   long longMethodintStringPackage(int p1, String p2) { return longMethodintStringPrivate(p1, p2); }
+   long longMethodintStringThrowsPackage(int p1, String p2) throws IllegalArgumentException, IllegalStateException { return longMethodintStringThrowsPrivate(p1, p2); }
+   protected void voidMethodVoidProtected() {}
+   protected long longMethodVoidProtected() { return 0; }
+   protected void voidMethodintProtected(int p1) {}
+   protected long longMethodintProtected(int p1) { return 0; }
+   protected void voidMethodintStringProtected(int p1, String p2) {}
+   protected long longMethodintStringProtected(int p1, String p2) { return 0; }
+   protected long longMethodintStringThrowsProtected(int p1, String p2) throws IllegalArgumentException, IllegalStateException { return 0; }
+   public void voidMethodVoidPublic() {}
+   public long longMethodVoidPublic() { return 0; }
+   public void voidMethodintPublic(int p1) {}
+   public long longMethodintPublic(int p1) { return 0; }
+   public void voidMethodintStringPublic(int p1, String p2) {}
+   public long longMethodintStringPublic(int p1, String p2) { return 0; }
+   public long longMethodintStringThrowsPublic(int p1, String p2) throws IllegalArgumentException, IllegalStateException { return 0; }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoSetterOnly.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoSetterOnly.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoSetterOnly.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,35 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoSetterOnly.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoSetterOnly
+{
+   public void setSomething(int x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoUpperPropertyName.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoUpperPropertyName.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/support/BeanInfoUpperPropertyName.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.support;
+
+/**
+ * BeanInfoUpperPropertyName.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class BeanInfoUpperPropertyName
+{
+   public Object getMBean()
+   {
+      return null;
+   }
+
+   public void setMBean(Object x)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,361 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.test;
+
+import java.lang.reflect.Constructor;
+import java.lang.reflect.Method;
+import java.lang.reflect.Type;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import org.jboss.beans.info.plugins.AbstractPropertyInfo;
+import org.jboss.beans.info.spi.BeanInfo;
+import org.jboss.beans.info.spi.PropertyInfo;
+import org.jboss.config.plugins.BasicConfiguration;
+import org.jboss.config.spi.Configuration;
+import org.jboss.reflect.plugins.ConstructorInfoImpl;
+import org.jboss.reflect.plugins.MethodInfoImpl;
+import org.jboss.reflect.spi.AnnotationValue;
+import org.jboss.reflect.spi.ClassInfo;
+import org.jboss.reflect.spi.ConstructorInfo;
+import org.jboss.reflect.spi.MethodInfo;
+import org.jboss.reflect.spi.PrimitiveInfo;
+import org.jboss.reflect.spi.TypeInfo;
+import org.jboss.reflect.spi.TypeInfoFactory;
+import org.jboss.test.classinfo.test.AbstractClassInfoTest;
+
+/**
+ * AbstractBeanInfoTest.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class AbstractBeanInfoTest extends AbstractClassInfoTest
+{
+   private Configuration configuration = new BasicConfiguration();
+   
+   public AbstractBeanInfoTest(String name)
+   {
+      super(name);
+   }
+   
+   protected void assertBeanInfo(BeanInfo beanInfo, Class<?> clazz) throws Throwable
+   {
+      assertEquals(clazz.getName(), beanInfo.getName());
+      ClassInfo classInfo = beanInfo.getClassInfo();
+      assertClassInfo(classInfo, clazz);
+      assertBeanConstructors(beanInfo, clazz);
+      assertBeanMethods(beanInfo, clazz);
+      assertBeanProperties(beanInfo, clazz);
+   }
+   
+   protected void assertBeanConstructors(BeanInfo beanInfo, Class clazz)
+   {
+      ClassInfo classInfo = beanInfo.getClassInfo();
+      
+      TypeInfoFactory factory = getTypeInfoFactory();
+      Set<ConstructorInfo> expected = new HashSet<ConstructorInfo>();
+      for (Constructor constructor : clazz.getConstructors())
+      {
+         Class[] paramClasses = constructor.getParameterTypes();
+         TypeInfo[] paramTypes = new TypeInfo[paramClasses.length];
+         AnnotationValue[][] paramAnnotations = new AnnotationValue[paramClasses.length][0];
+         int i = 0;
+         for (Class c : paramClasses)
+            paramTypes[i++] = factory.getTypeInfo(c);
+         ConstructorInfo c = new ConstructorInfoImpl(null, paramTypes, paramAnnotations, null, constructor.getModifiers(), classInfo);
+         expected.add(c);
+      }
+      
+      Set<ConstructorInfo> actual = beanInfo.getConstructors();
+      if (expected.isEmpty())
+      {
+         assertEmpty(actual);
+         return;
+      }
+      assertNotNull(actual);
+      assertEquals(expected.size(), actual.size());
+      getLog().debug(clazz + " expected constructors=" + expected + " actual=" + actual);
+      assertEquals(expected, actual);
+   }
+   
+   protected void assertBeanMethods(BeanInfo beanInfo, Class<?> clazz) throws Throwable
+   {
+      TypeInfoFactory factory = getTypeInfoFactory();
+      Set<MethodInfo> expected = new HashSet<MethodInfo>();
+      for (Method method : clazz.getMethods())
+      {
+         TypeInfo returnType = factory.getTypeInfo(method.getReturnType());
+         Class[] paramClasses = method.getParameterTypes();
+         TypeInfo[] paramTypes = new TypeInfo[paramClasses.length];
+         AnnotationValue[][] paramAnnotations = new AnnotationValue[paramClasses.length][0];
+         int i = 0;
+         for (Class c : paramClasses)
+            paramTypes[i++] = factory.getTypeInfo(c);
+         ClassInfo classInfo = (ClassInfo) factory.getTypeInfo(method.getDeclaringClass());
+         MethodInfo m = new MethodInfoImpl(null, method.getName(), returnType, paramTypes, paramAnnotations, null, method.getModifiers(), classInfo);
+         expected.add(m);
+      }
+      
+      Set<MethodInfo> actual = beanInfo.getMethods();
+      if (expected.isEmpty())
+      {
+         assertEmpty(actual);
+         return;
+      }
+      getLog().debug(clazz + " expected methods=" + expected + " actual=" + actual);
+      assertEquals(expected, actual);
+   }
+   
+   protected void assertBeanProperties(BeanInfo beanInfo, Class<?> clazz) throws Throwable
+   {
+      Set<PropertyInfo> expected = getExpectedProperties(clazz);
+      
+      Set<PropertyInfo> actual = beanInfo.getProperties();
+      if (expected.isEmpty())
+      {
+         assertEmpty(actual);
+         return;
+      }
+      getLog().debug(clazz + " expected properties=" + expected + " actual=" + actual);
+      assertEquals(expected, actual);
+      
+      HashMap<String, PropertyInfo> actualProps = new HashMap<String, PropertyInfo>();
+      for (PropertyInfo prop : actual)
+         actualProps.put(prop.getName(), prop);
+      
+      for (PropertyInfo propExpected : expected)
+      {
+         PropertyInfo propActual = actualProps.get(propExpected.getName());
+         AnnotationValue[] annotationsExpected = propExpected.getAnnotations();
+         AnnotationValue[] annotationsActual = propActual.getAnnotations();
+         Set<AnnotationValue> expectedSet = new HashSet<AnnotationValue>();
+         if (annotationsExpected != null)
+         {
+            for (AnnotationValue a : annotationsExpected)
+               expectedSet.add(a);
+         }
+         Set<AnnotationValue> actualSet = new HashSet<AnnotationValue>();
+         if (annotationsActual != null)
+         {
+            for (AnnotationValue a : annotationsActual)
+               actualSet.add(a);
+         }
+         getLog().debug("Checking annotations for " + propExpected.getName() + " expected: " + expectedSet + " actual=" + actualSet);
+         assertEquals(expectedSet, actualSet);
+      }
+   }
+
+   protected Set<PropertyInfo> getExpectedProperties(Class clazz)
+   {
+      TypeInfoFactory factory = getTypeInfoFactory();
+      Method[] methods = clazz.getMethods();
+      HashMap<String, Method> getters = new HashMap<String, Method>();
+      HashMap<String, List<Method>> setters = new HashMap<String, List<Method>>();
+      if (methods.length > 0)
+      {
+         for (Method method : methods)
+         {
+            String name = method.getName();
+            String upperName = getUpperPropertyName(name);
+            if (isGetter(method))
+               getters.put(upperName, method);
+            else if (isSetter(method))
+            {
+               List<Method> list = setters.get(upperName);
+               if (list == null)
+               {
+                  list = new ArrayList<Method>();
+                  setters.put(upperName, list);
+               }
+               list.add(method);
+            }
+         }
+      }
+
+      HashSet<PropertyInfo> properties = new HashSet<PropertyInfo>();
+      if (getters.isEmpty() == false)
+      {
+         for (Iterator<Map.Entry<String, Method>> i = getters.entrySet().iterator(); i.hasNext();)
+         {
+            Map.Entry<String, Method> entry = i.next();
+            String name = entry.getKey();
+            Method getter = entry.getValue();
+            Method setter = null;
+            List<Method> setterList = setters.remove(name);
+            if (setterList != null && setterList.size() != 0)
+            {
+               for (int j = 0; j < setterList.size(); ++j)
+               {
+                  Method thisSetter = setterList.get(j);
+                  Type pinfo = thisSetter.getGenericParameterTypes()[0];
+                  if (getter.getGenericReturnType().equals(pinfo) == true)
+                  {
+                     setter = thisSetter;
+                     break;
+                  }
+               }
+            }
+            String lowerName = getLowerPropertyName(name);
+            
+            // Merge the annotations between the getters and setters
+            Set<AnnotationValue> getterAnnotations = getExpectedAnnotations(getter.getAnnotations());
+            Set<AnnotationValue> setterAnnotations = null;
+            if (setter != null)
+               setterAnnotations = getExpectedAnnotations(setter.getAnnotations());
+            AnnotationValue[] annotations = getterAnnotations.toArray(new AnnotationValue[getterAnnotations.size()]);
+            if (annotations == null || annotations.length == 0)
+            {
+               if (setterAnnotations != null)
+                  annotations = setterAnnotations.toArray(new AnnotationValue[setterAnnotations.size()]);
+            }
+            else if (setterAnnotations != null && setterAnnotations.size() > 0)
+            {
+               HashSet<AnnotationValue> merged = new HashSet<AnnotationValue>();
+               merged.addAll(getterAnnotations);
+               merged.addAll(setterAnnotations);
+               annotations = merged.toArray(new AnnotationValue[merged.size()]);
+            }
+            
+            TypeInfo type = factory.getTypeInfo(getter.getGenericReturnType());
+            ClassInfo declaringType = (ClassInfo) factory.getTypeInfo(getter.getDeclaringClass());
+            MethodInfo getterInfo = new MethodInfoImpl(null, getter.getName(), type, new TypeInfo[0], null, null, getter.getModifiers(), declaringType);
+            MethodInfo setterInfo = null;
+            if (setter != null)
+            {
+               declaringType = (ClassInfo) factory.getTypeInfo(setter.getDeclaringClass());
+               AnnotationValue[][] paramAnnotations = new AnnotationValue[1][];
+               setterAnnotations = getExpectedAnnotations(setter.getParameterAnnotations()[0]); 
+               paramAnnotations[0] = setterAnnotations.toArray(new AnnotationValue[setterAnnotations.size()]);
+               setterInfo = new MethodInfoImpl(null, setter.getName(), PrimitiveInfo.VOID, new TypeInfo[] { type }, paramAnnotations, null, setter.getModifiers(), declaringType);
+            }
+            properties.add(new AbstractPropertyInfo(lowerName, name, type, getterInfo, setterInfo, annotations));
+         }
+      }
+      if (setters.isEmpty() == false)
+      {
+         for (Iterator<Map.Entry<String, List<Method>>> i = setters.entrySet().iterator(); i.hasNext();)
+         {
+            Map.Entry<String, List<Method>> entry = i.next();
+            String name = entry.getKey();
+            List<Method> setterList = entry.getValue();
+            // Review: Maybe should just create duplicate propertyInfo and let the configurator guess?
+            if (setterList.size() == 1)
+            {
+               Method setter = setterList.get(0);
+               Type pinfo = setter.getGenericParameterTypes()[0];
+               TypeInfo type = factory.getTypeInfo(pinfo);
+               String lowerName = getLowerPropertyName(name);
+               Set<AnnotationValue> setterAnnotations = getExpectedAnnotations(setter.getAnnotations()); 
+               AnnotationValue[] annotations = setterAnnotations.toArray(new AnnotationValue[setterAnnotations.size()]);
+               ClassInfo declaringType = (ClassInfo) factory.getTypeInfo(setter.getDeclaringClass());
+               AnnotationValue[][] paramAnnotations = new AnnotationValue[1][];
+               setterAnnotations = getExpectedAnnotations(setter.getParameterAnnotations()[0]); 
+               paramAnnotations[0] = setterAnnotations.toArray(new AnnotationValue[setterAnnotations.size()]);
+               MethodInfo setterInfo = new MethodInfoImpl(null, setter.getName(), PrimitiveInfo.VOID, new TypeInfo[] { type }, paramAnnotations, null, setter.getModifiers(), declaringType);
+               properties.add(new AbstractPropertyInfo(lowerName, name, type, null, setterInfo, annotations));
+            }
+         }
+      }
+      return properties;
+   }
+   
+   protected static String getUpperPropertyName(String name)
+   {
+      int start = 3;
+      if (name.startsWith("is"))
+         start = 2;
+      
+      return name.substring(start);
+   }
+   
+   protected static String getLowerPropertyName(String name)
+   {
+      // If the second character is upper case then we don't make
+      // the first character lower case
+      if (name.length() > 1)
+      {
+         if (Character.isUpperCase(name.charAt(1)))
+            return name;
+      }
+
+      StringBuilder buffer = new StringBuilder(name.length());
+      buffer.append(Character.toLowerCase(name.charAt(0)));
+      if (name.length() > 1)
+         buffer.append(name.substring(1));
+      return buffer.toString();
+   }
+   
+   protected static boolean isGetter(Method method)
+   {
+      String name = method.getName();
+      Class returnType = method.getReturnType();
+      Class[] parameters = method.getParameterTypes();
+      if ((name.length() > 3 && name.startsWith("get")) || (name.length() > 2 && name.startsWith("is")))
+      {
+         // isBoolean() is not a getter for java.lang.Boolean
+         if (name.startsWith("is") && returnType.equals(Boolean.TYPE) == false)
+            return false;
+         if (parameters.length == 0 && Void.TYPE.equals(returnType) == false)
+            return true;
+      }
+      return false;
+   }
+   
+   protected static boolean isSetter(Method method)
+   {
+      String name = method.getName();
+      Class returnType = method.getReturnType();
+      Class[] parameters = method.getParameterTypes();
+      if ((name.length() > 3 && name.startsWith("set")))
+      {
+         if (parameters.length == 1 && Void.TYPE.equals(returnType))
+            return true;
+      }
+      return false;
+   }
+
+   protected TypeInfoFactory getTypeInfoFactory()
+   {
+      return configuration.getTypeInfoFactory();
+   }
+   
+   protected BeanInfo getBeanInfo(Class clazz) throws Throwable
+   {
+      return configuration.getBeanInfo(clazz);
+   }
+   
+   protected Configuration getConfiguration()
+   {
+      return configuration;
+   }
+   
+   protected void configureLogging()
+   {
+      enableTrace("org.jboss.beans");
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoTestSuite.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoTestSuite.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoTestSuite.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,49 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.test;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * BeanInfo Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 58838 $
+ */
+public class BeanInfoTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("BeanInfo Tests");
+
+      suite.addTest(BeanInfoUnitTestCase.suite());
+      
+      return suite;
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoUnitTestCase.java	2006-12-06 11:38:46 UTC (rev 58861)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/BeanInfoUnitTestCase.java	2006-12-06 13:29:23 UTC (rev 58862)
@@ -0,0 +1,168 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.beaninfo.test;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import junit.framework.Test;
+
+import org.jboss.beans.info.spi.BeanInfo;
+import org.jboss.beans.info.spi.PropertyInfo;
+import org.jboss.test.beaninfo.support.BeanInfoAnnotatedGetterAndSetter;
+import org.jboss.test.beaninfo.support.BeanInfoAnnotatedGetterAndSetterSimpleMerge;
+import org.jboss.test.beaninfo.support.BeanInfoAnnotatedGetterOnly;
+import org.jboss.test.beaninfo.support.BeanInfoAnnotatedSetterOnly;
+import org.jboss.test.beaninfo.support.BeanInfoBooleanProperties;
+import org.jboss.test.beaninfo.support.BeanInfoConstructors;
+import org.jboss.test.beaninfo.support.BeanInfoEmpty;
+import org.jboss.test.beaninfo.support.BeanInfoGenericGetterAndSetter;
+import org.jboss.test.beaninfo.support.BeanInfoGenericGetterOnly;
+import org.jboss.test.beaninfo.support.BeanInfoGenericInconsistentTypes;
+import org.jboss.test.beaninfo.support.BeanInfoGenericSetterOnly;
+import org.jboss.test.beaninfo.support.BeanInfoGetterAndSetter;
+import org.jboss.test.beaninfo.support.BeanInfoGetterOnly;
+import org.jboss.test.beaninfo.support.BeanInfoInconsistentTypes;
+import org.jboss.test.beaninfo.support.BeanInfoSetterOnly;
+import org.jboss.test.beaninfo.support.BeanInfoUpperPropertyName;
+
+/**
+ * BeanInfo Test Case.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 45663 $
+ */
+public class BeanInfoUnitTestCase extends AbstractBeanInfoTest
+{
+   public static Test suite()
+   {
+      return suite(BeanInfoUnitTestCase.class);
+   }
+   
+   public BeanInfoUnitTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void testEmptyBean() throws Throwable
+   {
+      testBean(BeanInfoEmpty.class, null);
+   }
+   
+   public void testBeanConstructors() throws Throwable
+   {
+      testBean(BeanInfoConstructors.class, null);
+   }
+   
+   public void testBeanMethods() throws Throwable
+   {
+      testBean(BeanInfoConstructors.class, null);
+   }
+   
+   public void testBeanGetterOnly() throws Throwable
+   {
+      testBean(BeanInfoGetterOnly.class, new String[] { "something" });
+   }
+   
+   public void testBeanSetterOnly() throws Throwable
+   {
+      testBean(BeanInfoSetterOnly.class, new String[] { "something" });
+   }
+   
+   public void testBeanGetterAndSetter() throws Throwable
+   {
+      testBean(BeanInfoGetterAndSetter.class, new String[] { "something" });
+   }
+   
+   public void testBeanBooleanProperties() throws Throwable
+   {
+      testBean(BeanInfoBooleanProperties.class, new String[] { "something", "somethingElse" });
+   }
+   
+   public void testBeanUpperPropertyName() throws Throwable
+   {
+      testBean(BeanInfoUpperPropertyName.class, new String[] { "MBean" });
+   }
+   
+   public void testBeanInconsistentTypes() throws Throwable
+   {
+      testBean(BeanInfoInconsistentTypes.class, new String[] { "something" });
+   }
+   
+   public void testBeanGenericGetterOnly() throws Throwable
+   {
+      testBean(BeanInfoGenericGetterOnly.class, new String[] { "something" });
+   }
+   
+   public void testBeanGenericSetterOnly() throws Throwable
+   {
+      testBean(BeanInfoGenericSetterOnly.class, new String[] { "something" });
+   }
+   
+   public void testBeanGenericGetterAndSetter() throws Throwable
+   {
+      testBean(BeanInfoGenericGetterAndSetter.class, new String[] { "something" });
+   }
+   
+   public void testBeanGenericInconsistentTypes() throws Throwable
+   {
+      testBean(BeanInfoGenericInconsistentTypes.class, new String[] { "something" });
+   }
+   
+   public void testBeanAnnotatedGetterOnly() throws Throwable
+   {
+      testBean(BeanInfoAnnotatedGetterOnly.class, new String[] { "something" });
+   }
+   
+   public void testBeanAnnotatedSetterOnly() throws Throwable
+   {
+      testBean(BeanInfoAnnotatedSetterOnly.class, new String[] { "something" });
+   }
+   
+   public void testBeanAnnotatedGetterAndSetter() throws Throwable
+   {
+      testBean(BeanInfoAnnotatedGetterAndSetter.class, new String[] { "something" });
+   }
+   
+   public void testBeanAnnotatedGetterAndSetterSimpleMerge() throws Throwable
+   {
+      testBean(BeanInfoAnnotatedGetterAndSetterSimpleMerge.class, new String[] { "something" });
+   }
+
+   protected void testBean(Class clazz, String[] beanNames) throws Throwable
+   {
+      BeanInfo beanInfo = getBeanInfo(clazz);
+      assertBeanInfo(beanInfo, clazz);
+      if (beanNames != null)
+      {
+         Set<PropertyInfo> properties = beanInfo.getProperties();
+         Set<String> props = new HashSet<String>();
+         for (PropertyInfo p : properties)
+            props.add(p.getName());
+         Set<String> expected = new HashSet<String>();
+         for (String beanName : beanNames)
+            expected.add(beanName);
+         expected.add("class");
+         assertEquals(expected, props);
+      }
+   }
+}
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 09:59:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 09:59:11 -0500
Subject: [jboss-cvs] JBossAS SVN: r58864 - in
	projects/microcontainer/trunk/container/src:
	main/org/jboss/annotation/factory/javassist
	main/org/jboss/beans/info/plugins main/org/jboss/classadapter/spi
	main/org/jboss/metadata/plugins/context
	main/org/jboss/reflect/plugins
	main/org/jboss/reflect/plugins/javassist
	main/org/jboss/reflect/spi main/org/jboss/repository/plugins
	main/org/jboss/util/collection/temp
	main/org/jboss/virtual/classloading
	main/org/jboss/virtual/plugins/context/file
	main/org/jboss/virtual/plugins/context/jar
	tests/org/jboss/test/beaninfo/test
	tests/org/jboss/test/classinfo/support
	tests/org/jboss/test/classinfo/test
Message-ID: <E1GryEp-0001gD-TW@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-06 09:58:47 -0500 (Wed, 06 Dec 2006)
New Revision: 58864

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/annotation/factory/javassist/ProxyMapCreator.java
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/AnnotationValueFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayValueImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/AbstractKernelRepository.java
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/InvocationMetaDataCombiner.java
   projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/classloading/VFSClassLoader.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NoCopyNestedJarHandler.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/AnnotatedSubClass.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/JavassistArrayUnitTestCase.java
Log:
Update the non-VFS TODOs to include a reference to the JIRA issue.

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/annotation/factory/javassist/ProxyMapCreator.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/annotation/factory/javassist/ProxyMapCreator.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/annotation/factory/javassist/ProxyMapCreator.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -230,7 +230,7 @@
 
    public static Map<String, Object> createProxyMap(Class annotation, javassist.bytecode.annotation.Annotation info)
    {
-      //TODO: Need to handle default values for annotations in jdk 1.5
+      // TODO JBMICROCONT-126 Need to handle default values for annotations in jdk 1.5
       Map<String, Object> map = new HashMap<String, Object>();
 
       if (info.getMemberNames() == null) return map;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -298,7 +298,7 @@
             Map.Entry<String, List<MethodInfo>> entry = i.next();
             String name = entry.getKey();
             List<MethodInfo> setterList = entry.getValue();
-            // Review: Maybe should just create duplicate propertyInfo and let the configurator guess?
+            // TODO JBMICROCONT-125 Maybe should just create duplicate propertyInfo and let the configurator guess?
             if (setterList.size() == 1)
             {
                MethodInfo setter = setterList.get(0);

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -48,14 +48,6 @@
  * <li> Obtain the JoinpointFactory so the instance can be
  *       constructed.
  * </ol>
- *
- * FIXME: This class deals with too many concerns
- * FIXME: Need a mechanism to allow different use cases
- *              for the unadvised case.
- *              i.e. whether in the absence of aop requirements 
- *              the adapter should give a proxy advisor,
- *              instrument the class for aop anyway
- *              or default back to reflection (most likely!)
  * 
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  */

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -37,7 +37,7 @@
 /**
  * CachingMetaDataContext.
  * 
- * @TODO LRU Cache
+ * TODO JBMICROCONT-120 LRU Cache
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/AnnotationValueFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/AnnotationValueFactory.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/AnnotationValueFactory.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -77,7 +77,8 @@
       }
       else if (type instanceof ClassInfo)
       {
-         rtnValue = new ClassValueImpl(((Class)value).getName(), type); //FixMe - do not depend on Class
+         // TODO JBMICROCONT-118 do not depend on Class
+         rtnValue = new ClassValueImpl(((Class)value).getName(), type);
       }
       
       return rtnValue;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayValueImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayValueImpl.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ArrayValueImpl.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -103,7 +103,6 @@
     */
    protected void calculateHash()
    {
-      // FIXME java5 hash = Arrays.hashCode(values);
-      hash = hash * 29 +  type.hashCode();
+      hash = Arrays.hashCode(values);
    }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ClassInfoImpl.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -38,7 +38,7 @@
 /**
  * Class info
  *
- * @todo fix the introspection assumption
+ * TODO JBMICROCONT-118 fix the introspection assumption
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  */
@@ -171,7 +171,7 @@
    /**
     * Get an array class
     * 
-    * @todo there must be a better way to do this!
+    * TODO JBMICROCONT-123 there must be a better way to do this!
     * @param clazz the class
     * @param depth the depth
     * @return the array class

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -34,7 +34,7 @@
 /**
  * PropertyEditorHelper.
  *
- * @todo fix the introspection assumption
+ * TODO JBMICROCONT-118 fix the introspection assumption
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
@@ -58,7 +58,7 @@
    /**
     * Convert a value
     * 
-    * @todo look at integer progression, e.g. Integer.longValue()
+    * TODO JBMICROCONT-119 look at integer progression, e.g. Integer.longValue()
     * @param clazz the class
     * @param value the value
     * @return the value or null if there is no editor
@@ -108,7 +108,7 @@
       }
       
 
-      // TODO improve <init>(String) might not be relevent?
+      // TODO JBMICROCONT-132 improve <init>(String) might not be relevent?
       if (valueClass == String.class)
       {
          try

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -42,8 +42,8 @@
 /**
  * JavassistReflectionFactory.
  * 
- * @todo proper classpool with pruning
- * @todo non compiler based implementation
+ * TODO JBMICROCONT-122 proper classpool with pruning
+ * TODO JBMICROCONT-121 non compiler based implementation
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
@@ -604,7 +604,7 @@
    /**
     * Get the boxed type
     * 
-    * @todo integer progression?
+    * TODO JBMICROCONT-119 integer progression?
     * @param type the type to box
     * @return the boxed type name
     */

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfo.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -158,7 +158,7 @@
 
    public ClassInfo getGenericSuperclass()
    {
-      // TODO getGenericSuperclass
+      // TODO JBMICROCONT-129 getGenericSuperclass
       throw new org.jboss.util.NotImplementedException("getGenericSuperclass");
    }
 
@@ -182,7 +182,7 @@
 
    public InterfaceInfo[] getGenericInterfaces()
    {
-      // TODO getGenericInterfaces
+      // TODO JBMICROCONT-129 getGenericInterfaces
       throw new org.jboss.util.NotImplementedException("getGenericInterfaces");
    }
 
@@ -318,7 +318,7 @@
    /**
     * Get an array class
     * 
-    * @todo there must be a better way to do this!
+    * TODO JBMICROCONT-123 there must be a better way to do this!
     * @param clazz the class
     * @param depth the depth
     * @return the array class

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -279,7 +279,7 @@
       if (type instanceof Class)
          return getTypeInfo((Class) type);
 
-      // TODO getTypeInfo
+      // TODO JBMICROCONT-129 getTypeInfo
       throw new org.jboss.util.NotImplementedException("getTypeInfo");
    }
 

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -32,7 +32,7 @@
 /**
  * Primitive info
  *
- * @todo fix the introspection assumption
+ * TODO JBMICROCONT-118 fix the introspection assumption
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  */

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/AbstractKernelRepository.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/AbstractKernelRepository.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/AbstractKernelRepository.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -33,7 +33,6 @@
 import org.jboss.repository.spi.CommonNames;
 
 /**
- @todo update for synchronization and concurrent reader maps
 
  @author Scott.Stark at jboss.org
  @version $Revision$
@@ -72,8 +71,6 @@
    }
 
    /**
-    @todo should the loader be used to attempt to load data if the requested
-      name does not currently exist?
 
     @param key
     @param combiner
@@ -159,7 +156,6 @@
    }
 
    /**
-    @todo Not implemented.
     @param nameRE
     @param attributes
     @return null currently

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/InvocationMetaDataCombiner.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/InvocationMetaDataCombiner.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/repository/plugins/InvocationMetaDataCombiner.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -56,7 +56,7 @@
 
    public Object combine(Key key, MetaData[] levelData)
    {
-      Object value = null; // @todo Some function of context
+      Object value = null;
       if( value != null )
          return value;
       value = next.combine(key, levelData);

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/util/collection/temp/WeakTypeCache.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -153,7 +153,7 @@
     */
    private T getTypeVariable(TypeVariable type)
    {
-      // TODO improve this
+      // TODO JBMICROCONT-131 improve this
       return get(type.getBounds()[0]);
    }
 
@@ -165,7 +165,7 @@
     */
    private T getGenericArrayType(GenericArrayType type)
    {
-      // TODO this needs implementing properly
+      // TODO JBMICROCONT-131 this needs implementing properly
       return get(Object[].class);
    }
 
@@ -199,7 +199,7 @@
 
       synchronized (classLoaderCache)
       {
-         // TODO something better than toString()?
+         // TODO JBMICROCONT-131 something better than toString()?
          classLoaderCache.put(type.toString(), result);
       }
    }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/classloading/VFSClassLoader.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/classloading/VFSClassLoader.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/classloading/VFSClassLoader.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -150,7 +150,6 @@
     */
    public String[] getPackageNames()
    {
-      // TODO Auto-generated method stub
       return null;
    }
 

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -83,7 +83,6 @@
 
       public List<VirtualFileHandler> getChildren(boolean ignoreErrors) throws IOException
       {
-         // TODO Auto-generated method stub
          return null;
       }
 

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NoCopyNestedJarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NoCopyNestedJarHandler.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NoCopyNestedJarHandler.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -126,7 +126,6 @@
    @Override
    public List<VirtualFileHandler> getChildren(boolean ignoreErrors) throws IOException
    {
-      // TODO Auto-generated method stub
       return super.getChildren(ignoreErrors);
    }
    

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/beaninfo/test/AbstractBeanInfoTest.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -263,7 +263,7 @@
             Map.Entry<String, List<Method>> entry = i.next();
             String name = entry.getKey();
             List<Method> setterList = entry.getValue();
-            // Review: Maybe should just create duplicate propertyInfo and let the configurator guess?
+            // TODO JBMICROCONT-125 Maybe should just create duplicate propertyInfo and let the configurator guess?
             if (setterList.size() == 1)
             {
                Method setter = setterList.get(0);

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/AnnotatedSubClass.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/AnnotatedSubClass.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/support/AnnotatedSubClass.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -32,7 +32,7 @@
 
    public AnnotatedSubClass(int i, String x)
    {
-      // FIXME AnnotatedSubClass constructor
+      // TODO JBMICROCONT-124 AnnotatedSubClass constructor
       super(i, x);
    }
 

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/AbstractClassInfoTest.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -84,7 +84,7 @@
       getLog().debug("Type: " + info.getType());
       assertEquals(clazz, info.getType());
       
-      // TODO fix the serialization
+      // TODO JBMICROCONT-128 fix the serialization
       //byte[] bytes = serialize(info);
       //Object deserialized = deserialize(bytes);
       //assertEquals(info, deserialized);
@@ -471,7 +471,7 @@
       {
          Class type = annotation.annotationType();
          AnnotationInfoImpl info = new AnnotationInfoImpl(type.getName(), type.getModifiers());
-         // TODO attributes
+         // TODO JBMICROCONT-127 attributes
          AnnotationValue a = new AnnotationValueImpl(info, new HashMap<String, Value>());
          expected.add(a);
       }

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/JavassistArrayUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/JavassistArrayUnitTestCase.java	2006-12-06 14:48:01 UTC (rev 58863)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/classinfo/test/JavassistArrayUnitTestCase.java	2006-12-06 14:58:47 UTC (rev 58864)
@@ -47,12 +47,12 @@
 
    protected void assertInterfaces(Class<?> clazz, ClassInfo classInfo) throws Throwable
    {
-      // TODO this is broken for javassist
+      // TODO JBMICROCONT-130 this is broken for javassist
    }
 
    protected void assertModifiers(Class<?> clazz, ClassInfo classInfo) throws Throwable
    {
-      // TODO this is broken for javassist
+      // TODO JBMICROCONT-130 this is broken for javassist
    }
 
    protected TypeInfoFactory getTypeInfoFactory()



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 10:16:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 10:16:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r58865 -
	trunk/ejb3/src/main/org/jboss/ejb3/security
Message-ID: <E1GryVr-00029Q-6c@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-06 10:16:46 -0500 (Wed, 06 Dec 2006)
New Revision: 58865

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java
Log:
avoid NPE

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java	2006-12-06 14:58:47 UTC (rev 58864)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/Ejb3AuthenticationInterceptor.java	2006-12-06 15:16:46 UTC (rev 58865)
@@ -98,7 +98,10 @@
       try
       {  
          //Set a map of principal-roles that may be configured at deployment level
-         SecurityRolesAssociation.setSecurityRoles(container.getAssemblyDescriptor().getPrincipalVersusRolesMap());
+         if(container.getAssemblyDescriptor() != null)
+         {
+            SecurityRolesAssociation.setSecurityRoles(container.getAssemblyDescriptor().getPrincipalVersusRolesMap());
+         }
          return super.invoke(invocation);
       }
       finally



From gavin.king at jboss.com  Wed Dec  6 10:23:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 10:23:02 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/deployment  ...
Message-ID: <E1Grybu-0002EG-2P@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 10:23:02

  Modified:    src/main/org/jboss/seam/deployment  Scanner.java
  Log:
  throw exception if javassist is missing
  
  Revision  Changes    Path
  1.21      +3 -2      jboss-seam/src/main/org/jboss/seam/deployment/Scanner.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Scanner.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/deployment/Scanner.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- Scanner.java	21 Nov 2006 19:42:31 -0000	1.20
  +++ Scanner.java	6 Dec 2006 15:23:01 -0000	1.21
  @@ -1,4 +1,4 @@
  -//$Id: Scanner.java,v 1.20 2006/11/21 19:42:31 gavin Exp $
  +//$Id: Scanner.java,v 1.21 2006/12/06 15:23:01 gavin Exp $
   package org.jboss.seam.deployment;
   
   import java.io.DataInputStream;
  @@ -36,6 +36,7 @@
      {
         this.resourceName = resourceName;
         this.classLoader = classLoader;      
  +      ClassFile.class.getPackage(); //to force loading of javassist, throwing an exception if it is missing
      }
      
      public static String filenameToClassname(String filename)
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 10:34:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 10:34:01 -0500
Subject: [jboss-cvs] JBossAS SVN: r58866 -
	trunk/ejb3/src/main/org/jboss/ejb3/security
Message-ID: <E1GrymX-0002Oh-PT@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-06 10:34:00 -0500 (Wed, 06 Dec 2006)
New Revision: 58866

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java
Log:
do not do jacc checks if the realmMapping is null - security is not configured- need to check this again

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java	2006-12-06 15:16:46 UTC (rev 58865)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/JaccAuthorizationInterceptor.java	2006-12-06 15:34:00 UTC (rev 58866)
@@ -97,7 +97,10 @@
       String iface = (locator != null) ? "Remote" : "Local";
 
       EJBMethodPermission methodPerm = new EJBMethodPermission(ejbName, iface, m);
-      JaccHelper.checkPermission(ejbCS, methodPerm,realmMapping);
+      if(realmMapping != null)
+      { 
+         JaccHelper.checkPermission(ejbCS, methodPerm,realmMapping);  
+      }
       /*// Get the caller
       Subject caller = SecurityActions.getContextSubject(); 
 



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 10:43:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 10:43:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r58867 -
	trunk/ejb3/src/main/org/jboss/ejb3/security
Message-ID: <E1Gryvq-0002YK-Vs@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-06 10:43:35 -0500 (Wed, 06 Dec 2006)
New Revision: 58867

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java
Log:
fixed NPEs

Modified: trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java	2006-12-06 15:34:00 UTC (rev 58866)
+++ trunk/ejb3/src/main/org/jboss/ejb3/security/RunAsSecurityInterceptorFactory.java	2006-12-06 15:43:35 UTC (rev 58867)
@@ -66,12 +66,16 @@
       else
       {
          //Check if jboss.xml has it  
-         runAsPrincipal = container.getXml().getSecurityIdentity().getRunAsPrincipal();
+         if(container.getXml() != null && container.getXml().getSecurityIdentity() != null)
+         {
+            runAsPrincipal = container.getXml().getSecurityIdentity().getRunAsPrincipal();
+         }
       }
 
       HashSet extraRoles = new HashSet();  
       AssemblyDescriptor ad = container.getAssemblyDescriptor();
-      extraRoles.addAll(ad.getSecurityRolesGivenPrincipal(runAsPrincipal));
+      if(ad != null)
+         extraRoles.addAll(ad.getSecurityRolesGivenPrincipal(runAsPrincipal));
 
       return new RunAsIdentity(runAs.value(), runAsPrincipal, extraRoles);
    }



From hmesha at novell.com  Wed Dec  6 10:46:09 2006
From: hmesha at novell.com (Hany Mesha)
Date: Wed, 06 Dec 2006 10:46:09 -0500
Subject: [jboss-cvs] JBossCache/etc  ...
Message-ID: <E1GryyH-0002ap-CZ@committer01.frg.pub.inap.atl.jboss.com>

  User: hmesha  
  Date: 06/12/06 10:46:09

  Modified:    etc      build.xml
  Log:
  JBCACHE-861
  
  Revision  Changes    Path
  1.18      +3 -0      JBossCache/etc/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/build.xml,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- build.xml	24 Sep 2006 10:08:23 -0000	1.17
  +++ build.xml	6 Dec 2006 15:46:09 -0000	1.18
  @@ -90,6 +90,9 @@
         <copy todir="output/etc" filtering="no" overwrite="yes">
            <fileset dir="etc">
               <include name="log4j.xml"/>
  +         	<!-- The following copies the cache-jdbc.properties file for
  +         	                         running jdbc cache loader test against different DBMS -->
  +         	<include name="cache-jdbc.properties"/>
            </fileset>
         </copy>
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 10:56:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 10:56:07 -0500
Subject: [jboss-cvs] JBossAS SVN: r58868 - in
	projects/aop/trunk/aop/src/test/org/jboss/test/aop: . beforeafter
Message-ID: <E1Grz7v-0002m1-5y@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 10:56:02 -0500 (Wed, 06 Dec 2006)
New Revision: 58868

Added:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/
Removed:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg/
Log:
[JBAOP-37] Subclipse commited files in the wrong directory

Copied: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs (from rev 58865, projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/arg)



From msurtani at jboss.com  Wed Dec  6 11:00:14 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:00:14 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1GrzBu-0002qm-BY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:00:14

  Modified:    src/org/jboss/cache/optimistic  Tag: Branch_JBossCache_1_4_0
                        DefaultDataVersion.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.1   +4 -0      JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.3
  retrieving revision 1.3.2.1
  diff -u -b -r1.3 -r1.3.2.1
  --- DefaultDataVersion.java	8 Apr 2006 18:34:42 -0000	1.3
  +++ DefaultDataVersion.java	6 Dec 2006 16:00:14 -0000	1.3.2.1
  @@ -91,4 +91,8 @@
           return (int)version;
       }
   
  +   public long getRawVersion()
  +   {
  +      return version;
  +   }
   }
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:00:14 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:00:14 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors   ...
Message-ID: <E1GrzBu-0002r0-FO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:00:14

  Modified:    src/org/jboss/cache/interceptors   Tag:
                        Branch_JBossCache_1_4_0
                        OptimisticReplicationInterceptor.java
                        OptimisticValidatorInterceptor.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.21.2.4  +1 -0      JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticReplicationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java,v
  retrieving revision 1.21.2.3
  retrieving revision 1.21.2.4
  diff -u -b -r1.21.2.3 -r1.21.2.4
  --- OptimisticReplicationInterceptor.java	13 Nov 2006 13:00:03 -0000	1.21.2.3
  +++ OptimisticReplicationInterceptor.java	6 Dec 2006 16:00:14 -0000	1.21.2.4
  @@ -243,6 +243,7 @@
      private DataVersion getVersionToBroadcast(TransactionWorkspace w, Fqn f)
      {
         WorkspaceNode n = w.getNode(f);
  +      if (n == null) return null;
         if (w.isVersioningImplicit())
         {
            DefaultDataVersion v = (DefaultDataVersion) n.getVersion();
  
  
  
  1.25.2.7  +5 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.25.2.6
  retrieving revision 1.25.2.7
  diff -u -b -r1.25.2.6 -r1.25.2.7
  --- OptimisticValidatorInterceptor.java	13 Nov 2006 13:00:03 -0000	1.25.2.6
  +++ OptimisticValidatorInterceptor.java	6 Dec 2006 16:00:14 -0000	1.25.2.7
  @@ -139,7 +139,7 @@
               if (!workspaceNode.isCreated() )
               {
                  // test that the 2 DataVersion types match up
  -               if (!realNode.getVersion().getClass().equals(workspaceNode.getVersion().getClass()))
  +               if (!realNode.getVersion().getClass().equals(workspaceNode.getVersion().getClass()) && checkNotInitialRootVersion(realNode))
                  {
                     throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node that already contains version of type " + realNode.getVersion().getClass());                  
                  }
  @@ -152,6 +152,10 @@
           }
       }
   
  +   private boolean checkNotInitialRootVersion(OptimisticTreeNode n)
  +   {
  +      return !n.getFqn().isRoot() || !(n.getVersion() instanceof DefaultDataVersion) || n.getVersion() != DefaultDataVersion.ZERO;
  +   }
   
       private void commit(GlobalTransaction gtx)
       {
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:00:14 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:00:14 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1GrzBu-0002rB-MT@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:00:14

  Added:       tests/functional/org/jboss/cache/optimistic  Tag:
                        Branch_JBossCache_1_4_0 RemoveBeforeCreateTest.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +102 -0    JBossCache/tests/functional/org/jboss/cache/optimistic/Attic/RemoveBeforeCreateTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveBeforeCreateTest.java
  ===================================================================
  RCS file: RemoveBeforeCreateTest.java
  diff -N RemoveBeforeCreateTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ RemoveBeforeCreateTest.java	6 Dec 2006 16:00:14 -0000	1.1.2.1
  @@ -0,0 +1,102 @@
  +package org.jboss.cache.optimistic;
  +
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.OptimisticTreeNode;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.misc.TestingUtil;
  +
  +import javax.transaction.TransactionManager;
  +
  +/**
  + * Tests removal of a node before the node is even created.
  + */
  +public class RemoveBeforeCreateTest extends AbstractOptimisticTestCase
  +{
  +   TreeCache[] c = null;
  +   TransactionManager t;
  +
  +   protected void setUp() throws Exception
  +   {
  +      c = new TreeCache[2];
  +      c[0] = createReplicatedCache(TreeCache.REPL_ASYNC);
  +      c[1] = createReplicatedCache(TreeCache.REPL_ASYNC);
  +
  +      TestingUtil.blockUntilViewsReceived(c, 20000);
  +
  +      t = c[0].getTransactionManager();
  +   }
  +
  +   protected void tearDown()
  +   {
  +      if (c != null)
  +      {
  +         destroyCache(c[0]);
  +         destroyCache(c[1]);
  +         c = null;
  +      }
  +   }
  +
  +   public RemoveBeforeCreateTest(String name)
  +   {
  +      super(name);
  +   }
  +
  +   public void testControl() throws Exception
  +   {
  +      t.begin();
  +      c[0].put("/control", "key", "value");
  +      t.commit();
  +
  +      assertEquals("value", c[0].get("/control", "key"));
  +      assertEquals("value", c[1].get("/control", "key"));
  +      
  +      DefaultDataVersion v1 = (DefaultDataVersion) ((OptimisticTreeNode) c[0].get("/control")).getVersion();
  +      assertEquals(1, v1.getRawVersion());
  +
  +      DefaultDataVersion v2 = (DefaultDataVersion) ((OptimisticTreeNode) c[1].get("/control")).getVersion();
  +      assertEquals(1, v2.getRawVersion());
  +
  +
  +   }
  +
  +   public void testRemoveBeforePut() throws Exception
  +   {
  +      Fqn f = Fqn.fromString("/test");
  +      assertNull(c[0].get(f));
  +      assertNull(c[1].get(f));
  +
  +      t.begin();
  +      c[0].remove(f);
  +
  +      // should NOT barf!!!
  +      t.commit();
  +
  +      assertNull(c[0].get(f));
  +      assertNull(c[1].get(f));
  +   }
  +
  +   public void testCCEOnPrepare() throws Exception
  +   {
  +      Fqn f = Fqn.fromString("/test");
  +
  +      try
  +      {
  +         t.begin();
  +         c[0].remove(f);
  +
  +         // should NOT barf!!!
  +         t.commit();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +         System.out.println("***** Expected *****");
  +      }
  +
  +      t.begin();
  +      c[0].put(f, "key", "value");
  +      t.commit();
  +   }
  +  
  +
  +}
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:00:14 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:00:14 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options ...
Message-ID: <E1GrzBu-0002rP-Rz@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:00:14

  Modified:    tests/functional/org/jboss/cache/options   Tag:
                        Branch_JBossCache_1_4_0 SuppressLockingTest.java
                        ExplicitVersionsReplTest.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.1   +6 -6      JBossCache/tests/functional/org/jboss/cache/options/SuppressLockingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuppressLockingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/SuppressLockingTest.java,v
  retrieving revision 1.4
  retrieving revision 1.4.2.1
  diff -u -b -r1.4 -r1.4.2.1
  --- SuppressLockingTest.java	12 May 2006 00:01:48 -0000	1.4
  +++ SuppressLockingTest.java	6 Dec 2006 16:00:14 -0000	1.4.2.1
  @@ -44,7 +44,7 @@
   
              m.begin();
              cache.put(fqn, "x", "1");
  -           assertEquals(1, cache.getNumberOfLocksHeld());
  +           assertEquals(2, cache.getNumberOfLocksHeld());
              m.commit();
              assertEquals(0, cache.getNumberOfLocksHeld());
   
  @@ -61,7 +61,7 @@
   
              m.begin();
              cache.put(fqn, "x", "3");
  -           assertEquals(1, cache.getNumberOfLocksHeld());
  +           assertEquals(2, cache.getNumberOfLocksHeld());
              m.commit();
              assertEquals(0, cache.getNumberOfLocksHeld());
   
  @@ -89,7 +89,7 @@
   
              m.begin();
              cache.put(fqn, "x", "1");
  -           assertEquals(1, cache.getNumberOfLocksHeld());
  +           assertEquals(2, cache.getNumberOfLocksHeld());
              m.commit();
              assertEquals(0, cache.getNumberOfLocksHeld());
   
  @@ -116,7 +116,7 @@
   
              m.begin();
              cache.put(fqn, "x", "3");
  -           assertEquals(1, cache.getNumberOfLocksHeld());
  +           assertEquals(2, cache.getNumberOfLocksHeld());
              m.commit();
              assertEquals(0, cache.getNumberOfLocksHeld());
   
  @@ -142,7 +142,7 @@
   
               m.begin();
               cache.get(fqn, "x");
  -            assertEquals(1, cache.getNumberOfLocksHeld());
  +            assertEquals(2, cache.getNumberOfLocksHeld());
               m.commit();
               assertEquals(0, cache.getNumberOfLocksHeld());
   
  @@ -156,7 +156,7 @@
   
               m.begin();
               cache.get(fqn, "x");
  -            assertEquals(1, cache.getNumberOfLocksHeld());
  +            assertEquals(2, cache.getNumberOfLocksHeld());
               m.commit();
               assertEquals(0, cache.getNumberOfLocksHeld());
   
  
  
  
  1.1.2.2   +13 -0     JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- ExplicitVersionsReplTest.java	11 Nov 2006 17:50:03 -0000	1.1.2.1
  +++ ExplicitVersionsReplTest.java	6 Dec 2006 16:00:14 -0000	1.1.2.2
  @@ -288,5 +288,18 @@
         assertEquals(expected, ((OptimisticTreeNode) cache[1].get(fqn)).getVersion());
      }
   
  +   public void testExplicitVersionOnRoot() throws Exception
  +   {
  +      TestVersion newVersion = new TestVersion("100");
  +      option = new Option();
  +      option.setDataVersion(newVersion);
  +
  +      cache[0].getTransactionManager().begin();
  +      cache[0].put(Fqn.ROOT, "k", "v", option);
  +
  +      // should not barf
  +      cache[0].getTransactionManager().commit();
  +   }
  +
   
   }
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:28:36 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:28:36 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1GrzdM-0003Y5-Og@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:28:36

  Added:       tests/functional/org/jboss/cache/optimistic 
                        RemoveBeforeCreateTest.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.2       +79 -0     JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveBeforeCreateTest.java
  ===================================================================
  RCS file: RemoveBeforeCreateTest.java
  diff -N RemoveBeforeCreateTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ RemoveBeforeCreateTest.java	6 Dec 2006 16:28:36 -0000	1.2
  @@ -0,0 +1,79 @@
  +package org.jboss.cache.optimistic;
  +
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.OptimisticTreeNode;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.config.Configuration;
  +import org.jboss.cache.misc.TestingUtil;
  +
  +import javax.transaction.TransactionManager;
  +
  +/**
  + * Tests removal of a node before the node is even created.
  + */
  +public class RemoveBeforeCreateTest extends AbstractOptimisticTestCase
  +{
  +   TreeCache[] c = null;
  +   TransactionManager t;
  +
  +   protected void setUp() throws Exception
  +   {
  +      c = new TreeCache[2];
  +      c[0] = createReplicatedCache(Configuration.CacheMode.REPL_ASYNC);
  +      c[1] = createReplicatedCache(Configuration.CacheMode.REPL_ASYNC);
  +
  +      TestingUtil.blockUntilViewsReceived(c, 20000);
  +
  +      t = c[0].getTransactionManager();
  +   }
  +
  +   protected void tearDown()
  +   {
  +      if (c != null)
  +      {
  +         destroyCache(c[0]);
  +         destroyCache(c[1]);
  +         c = null;
  +      }
  +   }
  +
  +   public RemoveBeforeCreateTest(String name)
  +   {
  +      super(name);
  +   }
  +
  +   public void testControl() throws Exception
  +   {
  +      t.begin();
  +      c[0].put("/control", "key", "value");
  +      t.commit();
  +
  +      assertEquals("value", c[0].get("/control", "key"));
  +      assertEquals("value", c[1].get("/control", "key"));
  +
  +      DefaultDataVersion v1 = (DefaultDataVersion) ((OptimisticTreeNode) c[0].get("/control")).getVersion();
  +      assertEquals(1, v1.getRawVersion());
  +
  +      DefaultDataVersion v2 = (DefaultDataVersion) ((OptimisticTreeNode) c[1].get("/control")).getVersion();
  +      assertEquals(1, v2.getRawVersion());
  +
  +
  +   }
  +
  +   public void testRemoveBeforePut() throws Exception
  +   {
  +      Fqn f = Fqn.fromString("/test");
  +      assertNull(c[0].get(f));
  +      assertNull(c[1].get(f));
  +
  +      t.begin();
  +      c[0].remove(f);
  +
  +      // should NOT barf!!!
  +      t.commit();
  +
  +      assertNull(c[0].get(f));
  +      assertNull(c[1].get(f));
  +   }
  +
  +}
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:28:37 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:28:37 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1GrzdN-0003YC-3s@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:28:37

  Modified:    src/org/jboss/cache/optimistic  DefaultDataVersion.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.4       +84 -74    JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DefaultDataVersion.java	8 Apr 2006 18:34:42 -0000	1.3
  +++ DefaultDataVersion.java	6 Dec 2006 16:28:37 -0000	1.4
  @@ -36,6 +36,7 @@
   
       /**
        * Constructs with version 0.
  +    *
        * @deprecated use {@link #ZERO} constant
        */
       public DefaultDataVersion()
  @@ -56,9 +57,13 @@
       public DataVersion increment()
       {
           if (this == ZERO)
  +      {
               return ONE;
  +      }
           if (this == ONE)
  +      {
               return TWO;
  +      }
           return new DefaultDataVersion(version + 1);
       }
   
  @@ -74,7 +79,7 @@
   
       public String toString()
       {
  -        return "Ver="+version;
  +      return "Ver=" + version;
       }
   
       public boolean equals(Object other)
  @@ -88,7 +93,12 @@
   
       public int hashCode()
       {
  -        return (int)version;
  +      return (int) version;
  +   }
  +
  +   public long getRawVersion()
  +   {
  +      return version;
       }
   
   }
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:28:37 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:28:37 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors   ...
Message-ID: <E1GrzdN-0003YM-9X@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:28:37

  Modified:    src/org/jboss/cache/interceptors  
                        OptimisticReplicationInterceptor.java
                        OptimisticValidatorInterceptor.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.30      +1 -0      JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticReplicationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- OptimisticReplicationInterceptor.java	13 Nov 2006 14:20:32 -0000	1.29
  +++ OptimisticReplicationInterceptor.java	6 Dec 2006 16:28:37 -0000	1.30
  @@ -297,6 +297,7 @@
      private DataVersion getVersionToBroadcast(TransactionWorkspace w, Fqn f)
      {
         WorkspaceNode n = w.getNode(f);
  +      if (n == null) return null;
         if (w.isVersioningImplicit())
         {
            DefaultDataVersion v = (DefaultDataVersion) n.getVersion();
  
  
  
  1.45      +17 -9     JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- OptimisticValidatorInterceptor.java	25 Nov 2006 18:40:18 -0000	1.44
  +++ OptimisticValidatorInterceptor.java	6 Dec 2006 16:28:37 -0000	1.45
  @@ -13,7 +13,6 @@
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
   import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.optimistic.DataVersion;
  @@ -24,7 +23,6 @@
   
   import javax.transaction.Transaction;
   import java.util.Collection;
  -import java.util.Collections;
   import java.util.Iterator;
   import java.util.Map;
   
  @@ -119,7 +117,7 @@
            if (trace) log.trace("validating version for node " + fqn);
   
            OptimisticTreeNode realNode;
  -         realNode = (OptimisticTreeNode)cache.peek(fqn);
  +         realNode = (OptimisticTreeNode) cache.peek(fqn);
   
            if (workspaceNode.isCreated())
            {
  @@ -141,12 +139,14 @@
               }
               
               if (workspaceNode.getVersion() == null)
  +            {
                  throw new DataVersioningException("No version for workspace node");
  +            }
               
               DataVersion rnv = realNode.getVersion();
               DataVersion wnv = workspaceNode.getVersion();            
               // test that the 2 DataVersion types match up
  -            if (!rnv.getClass().equals(wnv.getClass()))
  +            if (!rnv.getClass().equals(wnv.getClass()) && checkNotInitialRootVersion(realNode))
               {
                  throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node that already contains version of type " + realNode.getVersion().getClass());
               }
  @@ -159,6 +159,10 @@
         }
      }
   
  +   private boolean checkNotInitialRootVersion(OptimisticTreeNode n)
  +   {
  +      return !n.getFqn().isRoot() || !(n.getVersion() instanceof DefaultDataVersion) || n.getVersion() != DefaultDataVersion.ZERO;
  +   }
   
      private void commit(GlobalTransaction gtx)
      {
  @@ -198,7 +202,9 @@
                  cache.getNotifier().notifyNodeRemoved(dNode.getFqn(), true, dNode.getNodeSPI().getRawData());
                  DataNode parent = (DataNode) dNode.getParent();
                  if (parent == null)
  +               {
                     throw new IllegalStateException("dNode " + dNode + " has no parent");
  +               }
                  parent.removeChild(dNode.getFqn().getLast());
                  cache.getNotifier().notifyNodeRemoved(dNode.getFqn(), false, null);
               }
  @@ -224,7 +230,9 @@
                  if (needsNotify)
                  {
                     if (log.isTraceEnabled())
  +                  {
                        log.trace("inserting merged data " + mergedData + " for " + current);
  +                  }
                     cache.getNotifier().notifyNodeModified(wrappedNode.getFqn(), true, rawData);
                  }
   
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:28:37 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:28:37 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options  ...
Message-ID: <E1GrzdN-0003YT-Ef@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:28:37

  Modified:    tests/functional/org/jboss/cache/options 
                        ExplicitVersionsReplTest.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.4       +20 -8     JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ExplicitVersionsReplTest.java	16 Nov 2006 14:37:09 -0000	1.3
  +++ ExplicitVersionsReplTest.java	6 Dec 2006 16:28:37 -0000	1.4
  @@ -42,8 +42,8 @@
         // give us lots of time to trace and debug shit
         c.setSyncCommitPhase(true);
         c.setSyncRollbackPhase(true);
  -      c.setSyncReplTimeout(600000);
  -      c.setLockAcquisitionTimeout(600000);
  +      c.setSyncReplTimeout(1000);
  +      c.setLockAcquisitionTimeout(1000);
         c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
   
         cache.setConfiguration(c);
  @@ -83,7 +83,7 @@
      {
         DataVersion version = new TestVersion("99");
         cache[0].getInvocationContext().getOptionOverrides().setDataVersion(version);
  -      cache[0].put(fqn, key, "value"); // TestVersion-99 should be on both caches now
  +      cache[0].put(fqn, key, "value");// TestVersion-99 should be on both caches now
   
         TransactionManager mgr = cache[0].getTransactionManager();
         mgr.begin();
  @@ -120,7 +120,7 @@
      {
         DataVersion version = new TestVersion("99");
         cache[0].getInvocationContext().getOptionOverrides().setDataVersion(version);
  -      cache[0].put(fqn, key, "value"); // TestVersion-99 should be on both caches now
  +      cache[0].put(fqn, key, "value");// TestVersion-99 should be on both caches now
   
         TransactionManager mgr = cache[0].getTransactionManager();
         mgr.begin();
  @@ -142,7 +142,7 @@
      {
         DataVersion version = new TestVersion("99");
         cache[0].getInvocationContext().getOptionOverrides().setDataVersion(version);
  -      cache[0].put(fqn, key, "value"); // TestVersion-99 should be on both caches now
  +      cache[0].put(fqn, key, "value");// TestVersion-99 should be on both caches now
   
         TransactionManager mgr = cache[0].getTransactionManager();
         mgr.begin();
  @@ -171,7 +171,7 @@
       */
      public void testIncompatibleVersionTypes2() throws Exception
      {
  -      cache[0].put(fqn, key, "value"); // default data version should be on both caches now
  +      cache[0].put(fqn, key, "value");// default data version should be on both caches now
   
         TransactionManager mgr = cache[0].getTransactionManager();
         mgr.begin();
  @@ -201,7 +201,7 @@
       */
      public void testCompatibleVersionTypes2() throws Exception
      {
  -      cache[0].put(fqn, key, "value"); // TestVersion-99 should be on both caches now
  +      cache[0].put(fqn, key, "value");// TestVersion-99 should be on both caches now
   
         TransactionManager mgr = cache[0].getTransactionManager();
         mgr.begin();
  @@ -223,7 +223,7 @@
      {
         DataVersion version = new DefaultDataVersion(200);
         cache[0].getInvocationContext().getOptionOverrides().setDataVersion(version);
  -      cache[0].put(fqn, key, "value"); // TestVersion-99 should be on both caches now
  +      cache[0].put(fqn, key, "value");// TestVersion-99 should be on both caches now
   
         TransactionManager mgr = cache[0].getTransactionManager();
         mgr.begin();
  @@ -286,5 +286,17 @@
         assertEquals(expected, ((OptimisticTreeNode) cache[1].get(fqn)).getVersion());
      }
   
  +   public void testExplicitVersionOnRoot() throws Exception
  +   {
  +      TestVersion newVersion = new TestVersion("100");
  +
  +      cache[0].getInvocationContext().getOptionOverrides().setDataVersion(newVersion);
  +      cache[0].getTransactionManager().begin();
  +      cache[0].put(Fqn.ROOT, "k", "v");
  +
  +      // should not barf
  +      cache[0].getTransactionManager().commit();
  +   }
  +
   
   }
  
  
  


From msurtani at jboss.com  Wed Dec  6 11:29:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 06 Dec 2006 11:29:45 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1GrzeT-0003Ym-O1@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/06 11:29:45

  Modified:    tests/functional/org/jboss/cache/optimistic  Tag:
                        Branch_JBossCache_1_4_0 RemoveBeforeCreateTest.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +0 -24     JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveBeforeCreateTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- RemoveBeforeCreateTest.java	6 Dec 2006 16:00:14 -0000	1.1.2.1
  +++ RemoveBeforeCreateTest.java	6 Dec 2006 16:29:45 -0000	1.1.2.2
  @@ -75,28 +75,4 @@
         assertNull(c[1].get(f));
      }
   
  -   public void testCCEOnPrepare() throws Exception
  -   {
  -      Fqn f = Fqn.fromString("/test");
  -
  -      try
  -      {
  -         t.begin();
  -         c[0].remove(f);
  -
  -         // should NOT barf!!!
  -         t.commit();
  -      }
  -      catch (Exception e)
  -      {
  -         e.printStackTrace();
  -         System.out.println("***** Expected *****");
  -      }
  -
  -      t.begin();
  -      c[0].put(f, "key", "value");
  -      t.commit();
  -   }
  -  
  -
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 12:00:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 12:00:46 -0500
Subject: [jboss-cvs] JBossAS SVN: r58869 -
	projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test
Message-ID: <E1Gs08U-00045e-Ie@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 12:00:44 -0500 (Wed, 06 Dec 2006)
New Revision: 58869

Modified:
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
Log:
Add additional tests of accessing resource by url including a test of accessing a resource in a files only jar.

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-06 15:56:02 UTC (rev 58868)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-06 17:00:44 UTC (rev 58869)
@@ -202,6 +202,82 @@
       mfIS.close();
    }
 
+   /**
+    * Basic tests of accessing resources in a jar
+    * @throws Exception
+    */
+   public void testFindResourceUsingURLStream()
+      throws Exception
+   {
+      URL rootURL = getResource("/vfs/test");
+      VFS vfs = VFS.getVFS(rootURL);
+      VirtualFile jar = vfs.findChild("outer.jar");
+      assertTrue("outer.jar != null", jar != null);
+
+      /*
+      ArrayList<String> searchCtx = new ArrayList<String>();
+      searchCtx.add("outer.jar");
+      VirtualFile metaInf = vfs.resolveFile("META-INF/MANIFEST.MF", searchCtx);
+      */
+      VirtualFile metaInf = jar.findChild("META-INF/MANIFEST.MF");
+      assertTrue("META-INF/MANIFEST.MF != null", metaInf != null);
+      InputStream mfIS = metaInf.toURL().openStream();
+      assertTrue("META-INF/MANIFEST.MF.openStream != null", mfIS != null);
+      Manifest mf = new Manifest(mfIS);
+      Attributes mainAttrs = mf.getMainAttributes();
+      String version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
+      assertEquals("1.0.0.GA", version);
+      mfIS.close();
+
+      String urlString = metaInf.toURL().toString();
+      URL mfURL = new URL(urlString);
+      mfIS = mfURL.openStream();
+      assertTrue("META-INF/MANIFEST.MF.openStream != null", mfIS != null);
+      mf = new Manifest(mfIS);
+      mainAttrs = mf.getMainAttributes();
+      version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
+      assertEquals("1.0.0.GA", version);
+      mfIS.close();
+   }
+
+   /**
+    * Basic tests of accessing resources in a jar that does not
+    * have parent directory entries.
+    * @throws Exception
+    */
+   public void testFindResourceInFilesOnlyJar()
+      throws Exception
+   {
+      URL rootURL = getResource("/vfs/test");
+      VFS vfs = VFS.getVFS(rootURL);
+      VirtualFile jar = vfs.findChild("jar1-filesonly.jar");
+      assertTrue("jar1-filesonly.jar != null", jar != null);
+
+      VirtualFile metaInf = jar.findChild("META-INF/MANIFEST.MF");
+      assertTrue("META-INF/MANIFEST.MF != null", metaInf != null);
+      InputStream mfIS = metaInf.toURL().openStream();
+      assertTrue("META-INF/MANIFEST.MF.openStream != null", mfIS != null);
+      Manifest mf = new Manifest(mfIS);
+      Attributes mainAttrs = mf.getMainAttributes();
+      String version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
+      assertEquals("1.0.0.GA-jboss", version);
+      String title = mf.getMainAttributes().getValue(Attributes.Name.SPECIFICATION_TITLE);
+      assertEquals("jar1-filesonly", title);
+      mfIS.close();
+
+      String urlString = metaInf.toURL().toString();
+      URL mfURL = new URL(urlString);
+      mfIS = mfURL.openStream();
+      assertTrue("META-INF/MANIFEST.MF.openStream != null", mfIS != null);
+      mf = new Manifest(mfIS);
+      mainAttrs = mf.getMainAttributes();
+      version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
+      assertEquals("1.0.0.GA-jboss", version);
+      title = mf.getMainAttributes().getValue(Attributes.Name.SPECIFICATION_TITLE);
+      assertEquals("jar1-filesonly", title);
+      mfIS.close();
+   }
+
    public void testFindResourceUnpackedJar()
       throws Exception
    {
@@ -352,6 +428,31 @@
       mfIS.close();
    }
 
+   public void testInnerJarUsingURLStream()
+      throws Exception
+   {
+      URL rootURL = getResource("/vfs/test");
+      VFS vfs = VFS.getVFS(rootURL);
+      VirtualFile inner = vfs.findChild("outer.jar/jar1.jar");
+      log.info("IsFile: "+inner.isLeaf());
+      log.info(inner.getLastModified());
+      List<VirtualFile> contents = inner.getChildren();
+      // META-INF/*, org/jboss/test/vfs/support/jar1/* at least
+      assertTrue("jar1.jar children.length("+contents.size()+") >= 2", contents.size() >= 2);
+      for(VirtualFile vf : contents)
+      {
+         log.info("  "+vf.getName());
+      }
+      VirtualFile vf = vfs.findChild("outer.jar/jar1.jar");
+      VirtualFile jar1MF = vf.findChild("META-INF/MANIFEST.MF");
+      InputStream mfIS = jar1MF.toURL().openStream();
+      Manifest mf = new Manifest(mfIS);
+      Attributes mainAttrs = mf.getMainAttributes();
+      String version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_TITLE);
+      assertEquals(Attributes.Name.SPECIFICATION_TITLE.toString(), "jar1", version);
+      mfIS.close();
+   }
+
    /**
     * Test a scan of the outer.jar vfs to locate all .class files
     * @throws Exception



From mculpepper at jboss.com  Wed Dec  6 12:02:56 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:56 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model
	...
Message-ID: <E1Gs0Aa-0004KK-PT@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:56

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model        
                        IPackageNodeWorkingCopy.java
                        IPackageFolderWorkingCopy.java
                        IPackageWorkingCopy.java IPackageNode.java
                        PackagesCore.java IPackageFileSetWorkingCopy.java
                        IPackageFileSet.java
  Added:       core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model        
                        IPackageNodeBase.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.2       +17 -1     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeWorkingCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageNodeWorkingCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeWorkingCopy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackageNodeWorkingCopy.java	6 Nov 2006 21:35:27 -0000	1.1
  +++ IPackageNodeWorkingCopy.java	6 Dec 2006 17:02:56 -0000	1.2
  @@ -1,10 +1,26 @@
   package org.jboss.ide.eclipse.packages.core.model;
   
  -public interface IPackageNodeWorkingCopy extends IPackageNode {
  +/**
  + * A working copy of a package node. Working copies are used to set attributes on a package node.
  + * @author Marshall
  + */
  +public interface IPackageNodeWorkingCopy extends IPackageNodeBase {
   	
  +	/**
  +	 * Set a property on this working copy
  +	 * @param property The property to set
  +	 * @param value The value of the property
  +	 */
   	public void setProperty(String property, String value);
   	
  +	/**
  +	 * Save this working copy (will overwrite the values in the original node)
  +	 * @return The original node
  +	 */
   	public IPackageNode save();
   	
  +	/**
  +	 * @return The original node this working copy is derived from
  +	 */
   	public IPackageNode getOriginal();
   }
  
  
  
  1.2       +17 -4     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolderWorkingCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageFolderWorkingCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolderWorkingCopy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackageFolderWorkingCopy.java	6 Nov 2006 21:35:27 -0000	1.1
  +++ IPackageFolderWorkingCopy.java	6 Dec 2006 17:02:56 -0000	1.2
  @@ -1,12 +1,25 @@
   package org.jboss.ide.eclipse.packages.core.model;
   
  +/**
  + * A working copy of an IPackageFolder, used to set the folder's attributes
  + * @author Marshall
  + */
   public interface IPackageFolderWorkingCopy extends IPackageFolder, IPackageNodeWorkingCopy {
  -	public void setName(String name);
   	
  -	public void addPackage(IPackage pkg);
  -	public void addFolder(IPackageFolder folder);
  -	public void addFileSet(IPackageFileSet fileset);
  +	/**
  +	 * Set the name of this folder
  +	 * @param name The name of this folder
  +	 */
  +	public void setName(String name);
   	
  +	/**
  +	 * @return The original folder this working copy is derived from
  +	 */
   	public IPackageFolder getOriginalFolder();
  +	
  +	/**
  +	 * Save this working copy's data into the original folder
  +	 * @return A reference to the original folder
  +	 */
   	public IPackageFolder saveFolder();
   }
  
  
  
  1.3       +35 -4     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageWorkingCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageWorkingCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageWorkingCopy.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IPackageWorkingCopy.java	20 Nov 2006 21:06:04 -0000	1.2
  +++ IPackageWorkingCopy.java	6 Dec 2006 17:02:56 -0000	1.3
  @@ -5,24 +5,55 @@
   import org.eclipse.core.runtime.IPath;
   import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
   
  +/**
  + * A working copy of an IPackage, used to set the package's attributes
  + * @author Marshall
  + */
   public interface IPackageWorkingCopy extends IPackage, IPackageNodeWorkingCopy {
  +	/**
  +	 * Set the package type of this package
  +	 * @param type The package type
  +	 */
   	public void setPackageType(IPackageType type);
   
  +	/**
  +	 * Set the name of this package
  +	 * @param name This package's name
  +	 */
   	public void setName(String name);
   	
  +	/**
  +	 * Set whether or not this package is generated as a folder
  +	 * @param exploded
  +	 */
   	public void setExploded(boolean exploded);
   	
  +	/**
  +	 * Set a path to a custom manifest for this package. This is usefulf or runnable JARs etc.
  +	 * @param manifestFile The manifest file in the workspace
  +	 */
   	public void setManifest(IFile manifestFile);
   	
  +	/**
  +	 * Sets the destination folder in the filesystem for this package
  +	 * @param path The absolute path where this package will be built
  +	 */
   	public void setDestinationFolder (IPath path);
   	
  +	/**
  +	 * Sets the destination container in the workspace for this package
  +	 * @param container The container where this package will be built
  +	 */
   	public void setDestinationContainer(IContainer container);
   	
  -	public void addPackage(IPackage pkb);
  -	public void addFolder(IPackageFolder folder);
  -	public void addFileSet(IPackageFileSet fileset);
  -	
  +	/**
  +	 * @return The package that this working copy was derived from
  +	 */
   	public IPackage getOriginalPackage();
   	
  +	/**
  +	 * Save this working copy's data into the original package
  +	 * @return A reference to the original package
  +	 */
   	public IPackage savePackage();
   }
  
  
  
  1.3       +10 -27    jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNode.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IPackageNode.java	8 Nov 2006 19:54:41 -0000	1.2
  +++ IPackageNode.java	6 Dec 2006 17:02:56 -0000	1.3
  @@ -21,43 +21,26 @@
    */
   package org.jboss.ide.eclipse.packages.core.model;
   
  -import org.eclipse.core.resources.IProject;
  -import org.eclipse.core.runtime.IAdaptable;
  -
   /**
    * The super type of all package nodes (IPackage, IPackageFileSet, IPackageFolder)
    * 
    * Each node in a package may have arbitrary properties that can be reflected upon by other plug-ins
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
  -public interface IPackageNode extends IAdaptable {
  -
  -	public static final int TYPE_PACKAGE = 0;
  -	public static final int TYPE_PACKAGE_FILESET = 1;
  -	public static final int TYPE_PACKAGE_FOLDER = 2;
  -	
  -	public IPackageNode getParent();
  -	public IPackageNode[] getChildren(int type);
  -	public IPackageNode[] getAllChildren();
  -	public boolean hasChildren();
  -	public boolean hasChild(IPackageNode child);
  -	
  -	public int getNodeType();
  -	
  -	public String getProperty(String property);
  -	
  -	public IProject getProject();
  -	
  -	public boolean accept(IPackageNodeVisitor visitor);
  -	public boolean accept(IPackageNodeVisitor visitor, boolean depthFirst);
  -	
  -	public IPackageNodeWorkingCopy createWorkingCopy();
  +public interface IPackageNode extends IPackageNodeBase {
   	
  +	/**
  +	 * Add a child node to this node
  +	 * @param child The child to add
  +	 */
   	public void addChild(IPackageNode child);
   	
  +	/**
  +	 * Remove a child node from this node
  +	 * @param child The child to remove
  +	 */
   	public void removeChild(IPackageNode child);
   	
  -	public boolean hasWorkingCopy();
   }
  
  
  
  1.10      +1 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesCore.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- PackagesCore.java	4 Dec 2006 22:23:08 -0000	1.9
  +++ PackagesCore.java	6 Dec 2006 17:02:56 -0000	1.10
  @@ -190,7 +190,7 @@
   	
   	public static IPackage getTopLevelPackage (IPackageNode node)
   	{
  -		IPackageNode tmp = node.getParent(), top = tmp;
  +		IPackageNodeBase tmp = node.getParent(), top = tmp;
   		while (tmp != null)
   		{
   			top = tmp;
  
  
  
  1.2       +53 -1     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSetWorkingCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageFileSetWorkingCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSetWorkingCopy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackageFileSetWorkingCopy.java	6 Nov 2006 21:35:27 -0000	1.1
  +++ IPackageFileSetWorkingCopy.java	6 Dec 2006 17:02:56 -0000	1.2
  @@ -5,10 +5,14 @@
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.runtime.IPath;
   
  +/**
  + * A working copy of an IPackageFileSet, used to set the fileset's attributes
  + * @author Marshall
  + */
   public interface IPackageFileSetWorkingCopy extends IPackageFileSet, IPackageNodeWorkingCopy {
   	
   	/**
  -	 * Set this fileset to be a single file
  +	 * Set this fileset to be a single file in the workspace
   	 * Equivalent to:
   	 * <code>setSingleFile(file, null);</code>
   	 * 
  @@ -16,25 +20,73 @@
   	 */
   	public void setSingleFile(IFile file);
   	
  +	/**
  +	 * Set this fileset to be a single file in the workspace, using the specified destination filename
  +	 * @param file The single file to be included in this fileset
  +	 * @param destinationFilename The filename that the file will be called in the package
  +	 */
   	public void setSingleFile(IFile file, String destinationFilename);
   	
  +	/**
  +	 * Set this fileset to be a single file in the filesystem
  +	 * Equivalent to:
  +	 * <code>setSingleFile(path, null);</code>
  +	 * @param path An absolute path to a file on the filesystem 
  +	 */
   	public void setSingleFile(IPath path);
   	
  +	/**
  +	 * Set this fileset to be a single file in the filesystem, using the specified destination filename
  +	 * @param path An absolute path to a file on the filesystem
  +	 * @param destinationFilename The filename that the file will be called in the package
  +	 */
   	public void setSingleFile(IPath path, String destinationFilename);
   	
  +	/**
  +	 * Sets the "root" or "source" of this fileset to be the passed-in project
  +	 * @param project The project that is the source of this fileset
  +	 */
   	public void setSourceProject(IProject project);
   	
  +	/**
  +	 * Sets the "root" or "source" of this fileset to the be the passed-in container
  +	 * @param container The container that is the source of this fileset
  +	 */
   	public void setSourceContainer(IContainer container);
   	
  +	/**
  +	 * Sets the "root" or "source" of this fileset to be an absolute path on the filesystem
  +	 * @param path The absolute path that is the source of this fileset
  +	 */
   	public void setSourceFolder(IPath path);
   	
  +	/**
  +	 * Set the includes pattern for this fileset. This pattern uses the same syntax as Ant's include pattern.
  +	 * @param includes The includes pattern for this fileset
  +	 */
   	public void setIncludesPattern(String includes);
   	
  +	/**
  +	 * Set the excludes pattern for this fileset. This pattern uses the same syntax as Ant's exclude pattern.
  +	 * @param excludes The excludes pattern for this fileset
  +	 */
   	public void setExcludesPattern(String excludes);
   	
  +	/**
  +	 * Set whether or not this fileset's source is in the workspace. This will automatically be handled if you
  +	 * use setSingleFile, setSourceProject, setSourceContainer, or setSourceFolder.
  +	 * @param isInWorkspace Whether or not this fileset's source is in the workspace
  +	 */
   	public void setInWorkspace(boolean isInWorkspace);
   	
  +	/**
  +	 * @return The original fileset this working copy is derived from
  +	 */
   	public IPackageFileSet getOriginalFileSet();
   	
  +	/**
  +	 * Save this working copy's data into the original fileset
  +	 * @return A reference to the original fileset
  +	 */
   	public IPackageFileSet saveFileSet();
   }
  
  
  
  1.2       +51 -0     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageFileSet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackageFileSet.java	6 Nov 2006 21:35:27 -0000	1.1
  +++ IPackageFileSet.java	6 Dec 2006 17:02:56 -0000	1.2
  @@ -32,37 +32,88 @@
    * </p>
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public interface IPackageFileSet extends IPackageNode {
   
  +	/**
  +	 * @return Whether or not this fileset represents a single file
  +	 */
   	public boolean isSingleFile();
   	
  +	/**
  +	 * @return Whether or not this fileset's basedir is inside the workspace
  +	 */
   	public boolean isInWorkspace();
   	
  +	/**
  +	 * If this fileset represents a single file, and that file is in the workspace, this will return a reference to that file.
  +	 * Otherwise this will return null.
  +	 */
   	public IFile getFile();
   	
  +	/**
  +	 * If this fileset represents a single file, and that file is not in the workspace, this will return a filesystem path to that file.
  +	 * Otherwise this will return null.
  +	 */
   	public IPath getFilePath();
   	
  +	/**
  +	 * If this fileset represents a single file, this will return the destination filename of the file within this package
  +	 */
   	public String getDestinationFilename();
   	
  +	/**
  +	 * This is a convenience method that will cast getSourceContainer() to an IProject if the source/basedir for this fileset represents a project
  +	 */
   	public IProject getSourceProject();
   	
  +	/**
  +	 * If this fileset is based inside the workspace, this will return the workspace container at the root / base of this fileset.
  +	 * @return The source container ("basedir" in ant terminology) for this fileset
  +	 */
   	public IContainer getSourceContainer();
   	
  +	/**
  +	 * If this fileset is based in the external filesystem, this will return the absolute path of the root / base of this fileset.
  +	 * @return The path to the source folder ("basedir" in ant terminology) for this fileset
  +	 */
   	public IPath getSourceFolder();
   	
  +	/**
  +	 * @return The includes pattern for this fileset
  +	 */
   	public String getIncludesPattern();
   	
  +	/**
  +	 * @return The excludes pattern for this fileset
  +	 */
   	public String getExcludesPattern();
   	
  +	/**
  +	 * @return An array of matching IFile's in the workspace (for workspace-rooted filesets)
  +	 */
   	public IFile[] findMatchingFiles();
   	
  +	/**
  +	 * @return An array of matching IPath's in the filesystem (for external filesystem filesets)
  +	 */
   	public IPath[] findMatchingPaths();
   	
  +	/**
  +	 * @param file The file to check
  +	 * @return Whether or not this fileset matches the passed-in file
  +	 */
   	public boolean matchesFile(IFile file);
   	
  +	/**
  +	 * @param path The absolute path on the filesystem to check
  +	 * @return Whether or not this fileset matches the passed-in path
  +	 */
   	public boolean matchesPath(IPath path);
   	
  +	/**
  +	 * @return A working copy of this fileset
  +	 */
   	public IPackageFileSetWorkingCopy createFileSetWorkingCopy();
   }
  
  
  
  1.1      date: 2006/12/06 17:02:56;  author: mculpepper;  state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeBase.java
  
  Index: IPackageNodeBase.java
  ===================================================================
  package org.jboss.ide.eclipse.packages.core.model;
  
  import org.eclipse.core.resources.IProject;
  import org.eclipse.core.runtime.IAdaptable;
  
  /**
   * The base the entire package node class hierarchy.
   * 
   * Each node in a package may have arbitrary properties that can be reflected upon by other plug-ins
   * 
   * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
   * @version $Revision: 1.1 $
   */
  public interface IPackageNodeBase extends IAdaptable {
  
  	/**
  	 * The node type that represents an IPackage
  	 */
  	public static final int TYPE_PACKAGE = 0;
  	
  	/**
  	 * The node type that represents an IPackageFileSet
  	 */
  	public static final int TYPE_PACKAGE_FILESET = 1;
  	
  	/**
  	 * The node type that represents an IPackageFolder
  	 */
  	public static final int TYPE_PACKAGE_FOLDER = 2;
  	
  	/**
  	 * @return The parent of this package node, or null if this node is top level
  	 */
  	public IPackageNodeBase getParent();
  	
  	/**
  	 * @param type TYPE_PACKAGE, TYPE_PACKAGE_FILESET, or TYPE_PACKAGE_FOLDER
  	 * @return An array of child nodes of the passed in type
  	 */
  	public IPackageNodeBase[] getChildren(int type);
  	
  	/**
  	 * @return An array of all children nodes
  	 */
  	public IPackageNodeBase[] getAllChildren();
  	
  	/**
  	 * @return Whether or not this node has children
  	 */
  	public boolean hasChildren();
  	
  	/**
  	 * @param child A possible child node
  	 * @return Whether or not the passed-in node is a child of this node
  	 */
  	public boolean hasChild(IPackageNodeBase child);
  	
  	/**
  	 * @return The type of this package node
  	 */
  	public int getNodeType();
  	
  	/**
  	 * @param property The name of the property to fetch
  	 * @return The value of the specified property
  	 */
  	public String getProperty(String property);
  	
  	/**
  	 * @return The project that this node is defined in (not necessarily the project where this is based if this is a fileset)
  	 */
  	public IProject getProject();
  	
  	/**
  	 * Recursively visit the package node tree below this node with the passed-in package node visitor.
  	 * @param visitor A package node visitor
  	 * @return Whether or not the entire sub-tree was visited
  	 */
  	public boolean accept(IPackageNodeVisitor visitor);
  	
  	/**
  	 * Recursively visit the package node tree below this node with the passed-in package node visitor, using depth-first ordering
  	 * @param visitor A package node visitor
  	 * @return Whether or not the entire sub-tree was visited
  	 */
  	public boolean accept(IPackageNodeVisitor visitor, boolean depthFirst);
  	
  	/**
  	 * @return A working copy of this package node
  	 */
  	public IPackageNodeWorkingCopy createWorkingCopy();
  
  	/**
  	 * @return Whether or not this node has an outstanding working copy
  	 */
  	public boolean hasWorkingCopy();
  }
  
  
  


From mculpepper at jboss.com  Wed Dec  6 12:02:56 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:56 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal
	...
Message-ID: <E1Gs0Aa-0004Ka-UK@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:56

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal    
                        PackageFolderImpl.java PackageImpl.java
                        PackageNodeImpl.java PackageBuildDelegate.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.3       +6 -5      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFolderImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageFolderImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFolderImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackageFolderImpl.java	8 Nov 2006 19:54:41 -0000	1.2
  +++ PackageFolderImpl.java	6 Dec 2006 17:02:56 -0000	1.3
  @@ -29,6 +29,7 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolderWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFolder;
   
  @@ -36,7 +37,7 @@
    * A PackageFolderImpl.
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public class PackageFolderImpl extends PackageNodeImpl implements
   		IPackageFolder, IPackageFolderWorkingCopy {
  @@ -56,20 +57,20 @@
   	}
   
   	public IPackageFileSet[] getFileSets() {
  -		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FILESET);
  +		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FILESET);
   		IPackageFileSet filesets[] = new IPackageFileSet[nodes.length];
   		System.arraycopy(nodes, 0, filesets, 0, nodes.length);
   		return filesets;
   	}
   
   	public IPackageFolder[] getFolders() {
  -		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
  +		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
   		IPackageFolder folders[] = new IPackageFolder[nodes.length];
   		System.arraycopy(nodes, 0, folders, 0, nodes.length);
   		return folders;
   	}
   	public IPackage[] getPackages() {
  -		IPackageNode nodes[] = getChildren(TYPE_PACKAGE);
  +		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE);
   		IPackage pkgs[] = new IPackage[nodes.length];
   		System.arraycopy(nodes, 0, pkgs, 0, nodes.length);
   		return pkgs;
  @@ -136,7 +137,7 @@
   	public IPath getPackageRelativePath() {
   		String path = new String(getName());
   		
  -		IPackageNode parent = getParent(), save = null;
  +		IPackageNodeBase parent = getParent(), save = null;
   		while (true) {
   			if (parent.getNodeType() == IPackageNode.TYPE_PACKAGE)
   				path = ((IPackage)parent).getName() + "/" + path;
  
  
  
  1.5       +6 -5      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- PackageImpl.java	20 Nov 2006 21:06:03 -0000	1.4
  +++ PackageImpl.java	6 Dec 2006 17:02:56 -0000	1.5
  @@ -35,6 +35,7 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackage;
  @@ -45,7 +46,7 @@
    * A Package.
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class PackageImpl extends PackageNodeImpl implements IPackage, IPackageWorkingCopy {
   
  @@ -89,14 +90,14 @@
   	}
   
   	public IPackageFileSet[] getFileSets() {
  -		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FILESET);
  +		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FILESET);
   		IPackageFileSet filesets[] = new IPackageFileSet[nodes.length];
   		System.arraycopy(nodes, 0, filesets, 0, nodes.length);
   		return filesets;
   	}
   
   	public IPackageFolder[] getFolders() {
  -		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
  +		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
   		IPackageFolder folders[] = new IPackageFolder[nodes.length];
   		System.arraycopy(nodes, 0, folders, 0, nodes.length);
   		return folders;
  @@ -107,7 +108,7 @@
   	}
   
   	public IPackage[] getPackages() {
  -		IPackageNode nodes[] = getChildren(TYPE_PACKAGE);
  +		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE);
   		IPackage pkgs[] = new IPackage[nodes.length];
   		System.arraycopy(nodes, 0, pkgs, 0, nodes.length);
   		return pkgs;
  @@ -239,7 +240,7 @@
   		
   		String path = new String(getName());
   		
  -		IPackageNode parent = getParent(), save = null;
  +		IPackageNodeBase parent = getParent(), save = null;
   		while (true) {
   			if (parent.getNodeType() == IPackageNode.TYPE_PACKAGE)
   				path = ((IPackage)parent).getName() + "/" + path;
  
  
  
  1.3       +6 -5      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageNodeImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackageNodeImpl.java	8 Nov 2006 19:54:41 -0000	1.2
  +++ PackageNodeImpl.java	6 Dec 2006 17:02:56 -0000	1.3
  @@ -29,6 +29,7 @@
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.runtime.Assert;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeVisitor;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFileSet;
  @@ -99,12 +100,12 @@
   		return children;
   	}
   	
  -	public IPackageNode[] getAllChildren ()
  +	public IPackageNodeBase[] getAllChildren ()
   	{
   		return nodesToChildren(nodeDelegate.getAllChildren());
   	}
   	
  -	public IPackageNode[] getChildren(int type) {
  +	public IPackageNodeBase[] getChildren(int type) {
   		return nodesToChildren(nodeDelegate.getChildren(intTypeToNodeType(type)));
   	}
   	
  @@ -112,13 +113,13 @@
   		return nodeDelegate.hasChildren();
   	}
   	
  -	public boolean hasChild (IPackageNode child)
  +	public boolean hasChild (IPackageNodeBase child)
   	{
   		PackageNodeImpl childImpl = (PackageNodeImpl)child;
   		return nodeDelegate.getAllChildren().contains(childImpl.nodeDelegate);
   	}
   
  -	public IPackageNode getParent() {
  +	public IPackageNodeBase getParent() {
   		XbPackageNode parent = nodeDelegate.getParent();
   		if (parent != null)
   			return PackagesModel.instance().getPackageNodeImpl(parent);
  @@ -147,7 +148,7 @@
   	}
   	
   	public boolean accept(IPackageNodeVisitor visitor, boolean depthFirst) {
  -		IPackageNode children[] = getAllChildren();
  +		IPackageNodeBase children[] = getAllChildren();
   		boolean keepGoing = true;
   		
   		if (!depthFirst)
  
  
  
  1.6       +3 -2      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageBuildDelegate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageBuildDelegate.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageBuildDelegate.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- PackageBuildDelegate.java	28 Nov 2006 19:54:29 -0000	1.5
  +++ PackageBuildDelegate.java	6 Dec 2006 17:02:56 -0000	1.6
  @@ -50,6 +50,7 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeVisitor;
   import org.jboss.ide.eclipse.packages.core.model.IPackagesBuildListener;
   import org.jboss.ide.eclipse.packages.core.model.IPackagesModelListener;
  @@ -456,7 +457,7 @@
   		{
   			// Is this right?? Is the parent guarenteed to be a package?
   			for( int i = 0; i < filesets.length; i++ ) {
  -				IPackageNode n = filesets[i].getParent();
  +				IPackageNodeBase n = filesets[i].getParent();
   				if( n instanceof IPackage ) 
   					packagesBeingChanged.add(n);
   			}
  @@ -481,7 +482,7 @@
   	{
   		ArrayList parents = new ArrayList();
   		
  -		IPackageNode parent = fileset.getParent();
  +		IPackageNodeBase parent = fileset.getParent();
   		while (parent != null)
   		{
   			parents.add(0, parent);
  
  
  


From mculpepper at jboss.com  Wed Dec  6 12:02:58 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:58 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages
	...
Message-ID: <E1Gs0Ac-0004Ku-2i@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:58

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages 
                        FilesetInfoWizardPage.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.3       +3 -2      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/FilesetInfoWizardPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FilesetInfoWizardPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/FilesetInfoWizardPage.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- FilesetInfoWizardPage.java	8 Nov 2006 19:54:44 -0000	1.2
  +++ FilesetInfoWizardPage.java	6 Dec 2006 17:02:58 -0000	1.3
  @@ -42,6 +42,7 @@
   import org.eclipse.ui.part.PageBook;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIMessages;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
  @@ -50,7 +51,7 @@
   public class FilesetInfoWizardPage extends WizardPage {
   
   	private IPackageFileSet fileset;
  -	private IPackageNode parentNode;
  +	private IPackageNodeBase parentNode;
   	private Text includesText;
   	private Text excludesText;
   	private TableViewer previewTable;
  @@ -77,7 +78,7 @@
   	private Composite singleFileComposite;
   	private Label singleFileProjectLabel;
   	
  -	public FilesetInfoWizardPage (Shell parent, IPackageFileSet fileset, IPackageNode parentNode)
  +	public FilesetInfoWizardPage (Shell parent, IPackageFileSet fileset, IPackageNodeBase parentNode)
   	{
   		super(PackagesUIMessages.FilesetInfoWizardPage_new_title, PackagesUIMessages.FilesetInfoWizardPage_new_title, null);
   		
  
  
  


From mculpepper at jboss.com  Wed Dec  6 12:02:58 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:58 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions
	...
Message-ID: <E1Gs0Ac-0004L4-7E@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:58

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions 
                        BuildPackagesAction.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.3       +41 -7     jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/BuildPackagesAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuildPackagesAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/BuildPackagesAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- BuildPackagesAction.java	21 Nov 2006 19:42:37 -0000	1.2
  +++ BuildPackagesAction.java	6 Dec 2006 17:02:58 -0000	1.3
  @@ -24,11 +24,15 @@
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.jface.dialogs.ProgressMonitorDialog;
  +import org.eclipse.jface.resource.ImageDescriptor;
  +import org.eclipse.jface.viewers.IStructuredSelection;
   import org.eclipse.ui.IWorkbenchWindow;
   import org.eclipse.ui.IWorkbenchWindowActionDelegate;
   import org.jboss.ide.eclipse.core.util.ProjectUtil;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  +import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
  +import org.jboss.ide.eclipse.packages.ui.views.ProjectPackagesView;
   import org.jboss.ide.eclipse.ui.util.ActionWithDelegate;
   
   public class BuildPackagesAction extends ActionWithDelegate implements IWorkbenchWindowActionDelegate {
  @@ -39,25 +43,55 @@
   	}
   
   	public void run() {
  -		if (getSelection() != null)
  -		{
  -			IProject project = ProjectUtil.getProject(getSelection());
  +		IProject project = null;
  +		IStructuredSelection selection = getSelection();
   			
  -			if (project != null)
  +		if (selection != null)
   			{
  +			project = ProjectUtil.getProject(selection);
  +		}
  +		else {
  +			if (ProjectPackagesView.instance() != null)
  +				project = ProjectPackagesView.instance().getCurrentProject();
  +		}
  +		
   				ProgressMonitorDialog dialog = new ProgressMonitorDialog(window.getShell());
   				IProgressMonitor monitor = dialog.getProgressMonitor();
  -				//dialog.setBlockOnOpen(false);
  +		
  +		if (project != null)
  +		{
   				dialog.open();
   				
   				PackagesCore.buildProject(project, monitor);
   				
   				dialog.close();
   			}
  +		else {
  +			if (selection.getFirstElement() instanceof IPackage)
  +			{
  +				dialog.open();
  +				
  +				IPackage pkg = (IPackage) selection.getFirstElement();
  +				PackagesCore.buildPackage(pkg, monitor);
  +				
  +				dialog.close();
  +			}
   		}
   	}
   
   	public void init(IWorkbenchWindow window) {
   		this.window = window;
   	}
  +	
  +	public ImageDescriptor getImageDescriptor() {
  +		return PackagesUIPlugin.getImageDescriptor(PackagesUIPlugin.IMG_BUILD_PACKAGES);
  +	}
  +	
  +	public String getText() {
  +		return "Build Packages";
  +	}
  +	
  +	public String getToolTipText () {
  +		return "Build Packages";
  +	}
   }
  
  
  


From mculpepper at jboss.com  Wed Dec  6 12:02:58 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:58 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views
	...
Message-ID: <E1Gs0Ac-0004LF-ET@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:58

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views 
                        ProjectPackagesView.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.7       +24 -2     jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views/ProjectPackagesView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProjectPackagesView.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views/ProjectPackagesView.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ProjectPackagesView.java	21 Nov 2006 16:47:46 -0000	1.6
  +++ ProjectPackagesView.java	6 Dec 2006 17:02:58 -0000	1.7
  @@ -41,6 +41,7 @@
   import org.jboss.ide.eclipse.packages.core.model.internal.PackagesModel;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIMessages;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
  +import org.jboss.ide.eclipse.packages.ui.actions.BuildPackagesAction;
   import org.jboss.ide.eclipse.packages.ui.actions.NewJARAction;
   import org.jboss.ide.eclipse.packages.ui.providers.PackagesContentProvider;
   import org.jboss.ide.eclipse.packages.ui.providers.PackagesLabelProvider;
  @@ -57,7 +58,7 @@
   	private Composite loadingPackagesComposite;
   	private TreeViewer packageTree;
   	private ProgressMonitorPart loadingProgress;
  -	private Action newJARAction, editAction, deleteAction, newFolderAction, newFilesetAction;
  +	private Action newJARAction, editAction, deleteAction, newFolderAction, newFilesetAction, buildAllAction, buildPackageAction;
   	private Action collapseAllAction;
   	private GroupMarker newPackageContributions;
   	private MenuManager newPackageManager;
  @@ -65,6 +66,17 @@
   	private boolean loading;
   	private PackagesContentProvider contentProvider;
   	
  +	private static ProjectPackagesView _instance;
  +	public ProjectPackagesView ()
  +	{
  +		_instance = this;
  +	}
  +	
  +	public static ProjectPackagesView instance()
  +	{
  +		return _instance;
  +	}
  +	
   	public void createPartControl(Composite parent) {
   		
   		ProjectSelectionService.instance().addProjectSelectionListener(this);
  @@ -160,12 +172,16 @@
   			}
   		};
   
  +		buildAllAction = new BuildPackagesAction();
  +		buildPackageAction = new BuildPackagesAction();
  +		
   		newPackageContributions = new GroupMarker(IWorkbenchActionConstants.MB_ADDITIONS);
   	}
   	
   	private void createToolbar ()
   	{
   		IToolBarManager manager = getViewSite().getActionBars().getToolBarManager();
  +		manager.add(buildAllAction);
   		manager.add(newJARAction);
   		manager.add(new Separator());
   		manager.add(collapseAllAction);
  @@ -217,6 +233,7 @@
   						editAction.setText(PackagesUIMessages.ProjectPackagesView_editPackageAction_label); //$NON-NLS-1$
   						deleteAction.setText(PackagesUIMessages.ProjectPackagesView_deletePackageAction_label); //$NON-NLS-1$
   						editAction.setImageDescriptor(PackagesUIPlugin.getImageDescriptor(PackagesUIPlugin.IMG_PACKAGE_EDIT));
  +						manager.add(buildPackageAction);
   					}
   					else if (node.getNodeType() == IPackageNode.TYPE_PACKAGE_FOLDER)
   					{
  @@ -361,7 +378,7 @@
   		IPackageNode node = getSelectedNode();
   		if (node != null)
   		{
  -			IPackageNode parent = node.getParent();
  +			IPackageNode parent = (IPackageNode) node.getParent();
   			if (parent != null)
   			{
   				parent.removeChild(node);
  @@ -418,4 +435,9 @@
   			packageTree.remove(removed);
   		}
   	}
  +	
  +	public IProject getCurrentProject ()
  +	{
  +		return currentProject;
  +	}
   }
  
  
  


From mculpepper at jboss.com  Wed Dec  6 12:02:58 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:58 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards
	...
Message-ID: <E1Gs0Ac-0004LN-L5@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:58

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards 
                        FilesetWizard.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.4       +3 -3      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/FilesetWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FilesetWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/FilesetWizard.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- FilesetWizard.java	15 Nov 2006 03:36:32 -0000	1.3
  +++ FilesetWizard.java	6 Dec 2006 17:02:58 -0000	1.4
  @@ -5,7 +5,7 @@
   import org.eclipse.jface.wizard.Wizard;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSetWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.ui.wizards.pages.FilesetInfoWizardPage;
   
  @@ -13,9 +13,9 @@
   
   	private FilesetInfoWizardPage page1;
   	private IPackageFileSet fileset;
  -	private IPackageNode parentNode;
  +	private IPackageNodeBase parentNode;
   	
  -	public FilesetWizard(IPackageFileSet fileset, IPackageNode parentNode)
  +	public FilesetWizard(IPackageFileSet fileset, IPackageNodeBase parentNode)
   	{
   		this.fileset = fileset;
   		this.parentNode = parentNode;
  
  
  


From mculpepper at jboss.com  Wed Dec  6 12:02:58 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 12:02:58 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui
	...
Message-ID: <E1Gs0Ac-0004LU-Rl@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 12:02:58

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui 
                        PackagesUIPlugin.java
  Log:
  changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before
  
  Revision  Changes    Path
  1.2       +2 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/PackagesUIPlugin.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesUIPlugin.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/PackagesUIPlugin.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- PackagesUIPlugin.java	6 Nov 2006 21:36:50 -0000	1.1
  +++ PackagesUIPlugin.java	6 Dec 2006 17:02:58 -0000	1.2
  @@ -32,6 +32,7 @@
   	public static final String IMG_EJB_JAR = "icons/EJBJar.gif";
   	public static final String IMG_NEW_WAR_WIZARD="icons/new_war_wiz.png";
   	public static final String IMG_NEW_EAR_WIZARD="icons/ear-wiz-banner.gif";
  +	public static final String IMG_BUILD_PACKAGES = "icons/build_packages.gif";
   	
   	// The shared instance
   	private static PackagesUIPlugin plugin;
  @@ -76,7 +77,7 @@
   			IMG_NEW_PACKAGE, IMG_NEW_JAR_WIZARD, IMG_SINGLE_FILE,
   			IMG_MULTIPLE_FILES, IMG_COLLAPSE_ALL, IMG_PACKAGE_EDIT,
   			IMG_EAR, IMG_EJB_JAR, IMG_WAR, IMG_NEW_EAR_WIZARD,
  -			IMG_NEW_WAR_WIZARD
  +			IMG_NEW_WAR_WIZARD, IMG_BUILD_PACKAGES
   		});
   	}
   	
  
  
  


From rawblem at gmail.com  Wed Dec  6 12:14:36 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 06 Dec 2006 12:14:36 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server
	...
Message-ID: <E1Gs0Ls-0004X7-AW@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/06 12:14:36

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server 
                        ServerTableViewer.java
  Log:
  Forcing a selection event makes the icon bars reload. 
  
  Revision  Changes    Path
  1.4       +2 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ServerTableViewer.java	28 Nov 2006 17:32:51 -0000	1.3
  +++ ServerTableViewer.java	6 Dec 2006 17:14:36 -0000	1.4
  @@ -262,6 +262,8 @@
   			public void run() {
   				try {
   					refresh(server);
  +					ISelection sel = ServerTableViewer.this.getSelection();
  +					ServerTableViewer.this.setSelection(sel);
   				} catch (Exception e) {
   					// ignore
   				}
  
  
  


From rawblem at gmail.com  Wed Dec  6 12:47:33 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 06 Dec 2006 12:47:33 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal
	...
Message-ID: <E1Gs0rl-000584-Ue@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/06 12:47:33

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal 
                        PackagesModel.java
  Log:
  added a force api to firing model change events, because it was the easy bandaid solution. 
  
  Revision  Changes    Path
  1.8       +12 -7     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- PackagesModel.java	20 Nov 2006 21:06:03 -0000	1.7
  +++ PackagesModel.java	6 Dec 2006 17:47:33 -0000	1.8
  @@ -156,7 +156,7 @@
   		}
   		
   		saveModel(pkg.getProject());
  -		fireNodeRemoved(pkg);
  +		fireNodeRemoved(pkg, true);
   	}
   	
   	public XbPackages getXbPackages(IProject project)
  @@ -402,9 +402,8 @@
   		});
   	}
   	
  -	protected void fireNodeRemoved (final IPackageNode removed)
  -	{
  -		fireEvent(removed, new Runnable() {
  +	protected void fireNodeRemoved (final IPackageNode removed, boolean force) {
  +		fireEvent(removed, force, new Runnable() {
   			public void run() {
   				for (Iterator iter = modelListeners.iterator(); iter.hasNext(); )
   				{
  @@ -414,6 +413,9 @@
   			}
   		});
   	}
  +	protected void fireNodeRemoved (final IPackageNode removed) {
  +		fireNodeRemoved(removed, false);
  +	}
   	
   	protected void fireNodeChanged (final IPackageNode changed)
   	{
  @@ -428,9 +430,8 @@
   		});
   	}
   	
  -	protected void fireEvent (IPackageNode source, Runnable runnable)
  -	{
  -		if (!modelBridge.containsKey(source)) //not registered in the model, no event should be broadcast
  +	protected void fireEvent (IPackageNode source, boolean force, Runnable runnable) {
  +		if (!force && !modelBridge.containsKey(source)) //not registered in the model, no event should be broadcast
   			return;
   		
   		PackageNodeImpl nodeImpl = (PackageNodeImpl) source;
  @@ -439,6 +440,10 @@
   			runnable.run();
   		}
   	}
  +	protected void fireEvent (IPackageNode source, Runnable runnable)
  +	{
  +		fireEvent(source, false, runnable);
  +	}
   	
   	public boolean isPackageNodeRegistered (IPackageNode node)
   	{
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 13:02:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 13:02:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r58871 -
	projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test
Message-ID: <E1Gs16E-0005Yt-BE@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 13:02:28 -0500 (Wed, 06 Dec 2006)
New Revision: 58871

Modified:
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java
Log:
Update the testJarInDirectory check of jar urls to file urls since out jar files don't return a jar url any longer.

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java	2006-12-06 17:02:24 UTC (rev 58870)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java	2006-12-06 18:02:28 UTC (rev 58871)
@@ -149,8 +149,13 @@
       
       // Test it got all the candidates
       Map<String, Boolean> expected = new HashMap<String, Boolean>();
+      /* With the change to not expose the outer jar url, these are
+         no longer valid checks.
       expected.put(getJarURL("/structure/jar/indirectory/archive.jar"), true);
       expected.put(getJarURL("/structure/jar/indirectory/archive.zip"), true);
+      */
+      expected.put(getURL("/structure/jar/indirectory/archive.jar"), true);
+      expected.put(getURL("/structure/jar/indirectory/archive.zip"), true);
       assertContexts(expected, context.getChildren());
       
       assertCandidatesValid(context);



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 13:03:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 13:03:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r58872 -
	projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test
Message-ID: <E1Gs173-0005ZC-Jq@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 13:03:19 -0500 (Wed, 06 Dec 2006)
New Revision: 58872

Modified:
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
Log:
Correct the version check

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-06 18:02:28 UTC (rev 58871)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-06 18:03:19 UTC (rev 58872)
@@ -260,7 +260,7 @@
       Manifest mf = new Manifest(mfIS);
       Attributes mainAttrs = mf.getMainAttributes();
       String version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
-      assertEquals("1.0.0.GA-jboss", version);
+      assertEquals("1.0.0.GA", version);
       String title = mf.getMainAttributes().getValue(Attributes.Name.SPECIFICATION_TITLE);
       assertEquals("jar1-filesonly", title);
       mfIS.close();
@@ -272,7 +272,7 @@
       mf = new Manifest(mfIS);
       mainAttrs = mf.getMainAttributes();
       version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
-      assertEquals("1.0.0.GA-jboss", version);
+      assertEquals("1.0.0.GA", version);
       title = mf.getMainAttributes().getValue(Attributes.Name.SPECIFICATION_TITLE);
       assertEquals("jar1-filesonly", title);
       mfIS.close();



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 13:05:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 13:05:14 -0500
Subject: [jboss-cvs] JBossAS SVN: r58873 -
	projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar
Message-ID: <E1Gs18s-0005ay-8J@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 13:05:12 -0500 (Wed, 06 Dec 2006)
New Revision: 58873

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
Log:
Merge the entry url creation into a common getURL method and correctly assign SyntheticDirEntryHandlers a jar url.

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-06 18:03:19 UTC (rev 58872)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-06 18:05:12 UTC (rev 58873)
@@ -240,7 +240,7 @@
          catch (IOException e)
          {
             // Create a synthetic parent
-            URL url = getURL(parent, path);
+            URL url = getURL(parent, path, true);
             next = new SynthenticDirEntryHandler(getVFSContext(), parent, path,
                     entry.getTime(), url);
             parentMap.put(pathName.toString(), next);
@@ -268,13 +268,30 @@
       return parent;
    }
 
-   protected URL getURL(VirtualFileHandler parent, String path)
+   /**
+    * Create the URL for the entry represented by path.
+    * 
+    * @param parent - the parent handler
+    * @param path - the simple path to the entry without any trailing '/'
+    * @return the jar entry URL
+    * @throws MalformedURLException
+    */
+   protected URL getURL(VirtualFileHandler parent, String path, boolean isDirEntry)
            throws MalformedURLException
    {
       StringBuilder buffer = new StringBuilder();
       try
       {
-         buffer.append(parent.toURL());
+         String parentUrl = parent.toURL().toString();
+         if (parent instanceof JarEntryHandler || parent instanceof SynthenticDirEntryHandler)
+         {
+            buffer.append(parentUrl);
+         }
+         else
+         {
+            buffer.append("jar:").append(parentUrl).append("!/");
+         }
+
          if (buffer.charAt(buffer.length() - 1) != '/')
             buffer.append('/');
          buffer.append(path);
@@ -284,6 +301,9 @@
          // Should not happen
          throw new MalformedURLException(e.getMessage());
       }
+      // Jar directory URLs must end in /
+      if( isDirEntry && buffer.charAt(buffer.length() - 1) != '/')
+         buffer.append('/');
       URL url = new URL(buffer.toString());
       return url;
    }
@@ -332,13 +352,13 @@
     *
     * @param parent the parent
     * @param entry  the entry
-    * @param entryName the entry name
+    * @param entryName - the entry name without any trailing '/'
     * @return the handler
     * @throws IOException              for any error accessing the file system
     * @throws IllegalArgumentException for a null parent or entry
     */
-   protected VirtualFileHandler createVirtualFileHandler(VirtualFileHandler parent, JarEntry entry,
-                                                         String entryName)
+   protected VirtualFileHandler createVirtualFileHandler(VirtualFileHandler parent,
+         JarEntry entry, String entryName)
            throws IOException
    {
       if (parent == null)
@@ -346,31 +366,7 @@
       if (entry == null)
          throw new IllegalArgumentException("Null entry");
 
-
-      StringBuilder buffer = new StringBuilder();
-      try
-      {
-         String parentUrl = parent.toURL().toString();
-         if (parent instanceof JarEntryHandler || parent instanceof SynthenticDirEntryHandler)
-         {
-            buffer.append(parentUrl);
-         }
-         else
-         {
-            buffer.append("jar:").append(parentUrl).append("!/");
-         }
-
-         if (buffer.charAt(buffer.length() - 1) != '/')
-            buffer.append('/');
-         buffer.append(entryName);
-      }
-      catch (URISyntaxException e)
-      {
-         // Should not happen
-         throw new MalformedURLException(e.getMessage());
-      }
-      URL url = new URL(buffer.toString());
-
+      URL url = getURL(parent, entryName, entry.isDirectory());
       VFSContext context = parent.getVFSContext();
 
       VirtualFileHandler vfh;
@@ -386,9 +382,6 @@
       }
       else
       {
-         // Jar directory URLs must end in /
-         if (entry.isDirectory())
-            url = new URL(url.toString() + "/");
          vfh = new JarEntryHandler(context, parent, jar, entry, entryName, url);
       }
 



From michael.yuan at jboss.com  Wed Dec  6 13:15:08 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 06 Dec 2006 13:15:08 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/nbproject  ...
Message-ID: <E1Gs1IS-0005jE-Nj@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/06 13:15:08

  Modified:    seam-gen/nbproject  project.xml
  Log:
  Better menu options
  
  Revision  Changes    Path
  1.5       +9 -8      jboss-seam/seam-gen/nbproject/project.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: project.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/nbproject/project.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- project.xml	6 Dec 2006 06:55:40 -0000	1.4
  +++ project.xml	6 Dec 2006 18:15:08 -0000	1.5
  @@ -16,17 +16,18 @@
               <ide-actions>
                   <action name="clean">
                       <target>clean</target>
  +                    <target>unexplode</target>
                   </action>
  -                <action name="build">
  +                <action name="Build">
                       <target>archive</target>
                   </action>
  -                <action name="deploy">
  +                <action name="Deploy">
                       <target>explode</target>
                   </action>
  -                <action name="undeploy">
  +                <action name="Undeploy">
                       <target>unexplode</target>
                   </action>
  -                <action name="restart">
  +                <action name="redeploy">
                       <target>restart</target>
                   </action>
                   <action name="test">
  @@ -57,11 +58,11 @@
                   </items>
                   <context-menu>
                       <ide-action name="clean"/>
  -                    <ide-action name="restart"/>
  +                    <ide-action name="Build"/>
  +                    <ide-action name="Deploy"/>
  +                    <ide-action name="redeploy"/>
  +                    <ide-action name="Undeploy"/>
                       <ide-action name="debug"/>
  -                    <ide-action name="build"/>
  -                    <ide-action name="deploy"/>
  -                    <ide-action name="undeploy"/>
                       <ide-action name="test"/>
                   </context-menu>
               </view>
  
  
  


From scott.stark at jboss.com  Wed Dec  6 13:38:24 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 13:38:24 -0500
Subject: [jboss-cvs] JBossRemoting  ...
Message-ID: <E1Gs1ey-00064Z-Fr@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 13:38:24

  Modified:    JBossRemoting  build.xml
  Log:
  Generate a jboss-remoting-src.zip artifact for inclusion into the repository
  
  Revision  Changes    Path
  1.91      +8 -1      JBossRemoting/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/build.xml,v
  retrieving revision 1.90
  retrieving revision 1.91
  diff -u -b -r1.90 -r1.91
  --- build.xml	13 Nov 2006 21:52:42 -0000	1.90
  +++ build.xml	6 Dec 2006 18:38:24 -0000	1.91
  @@ -9,7 +9,7 @@
   <!--                                                                        -->
   <!-- ====================================================================== -->
   
  -<!-- $Id: build.xml,v 1.90 2006/11/13 21:52:42 telrod Exp $ -->
  +<!-- $Id: build.xml,v 1.91 2006/12/06 18:38:24 starksm Exp $ -->
   
   <project default="most" name="JBossRemoting">
   
  @@ -282,6 +282,13 @@
            </fileset>
         </jar>
   
  +      <jar jarfile="${output.lib.dir}/jboss-remoting-src.zip"
  +         manifest="${manifest.file}">
  +         <fileset dir="${src.dir}">
  +            <exclude name="org/jboss/remoting/samples/**"/>
  +         </fileset>
  +      </jar>
  +
         <!-- build out the server invoker war -->
         <mkdir dir="${output.lib.dir}/${servlet.invoker.war}/WEB-INF"/>
         <mkdir dir="${output.lib.dir}/${servlet.invoker.war}/WEB-INF/classes"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 14:01:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 14:01:28 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58874 - tags
Message-ID: <E1Gs21I-0006UZ-M4@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 14:01:28 -0500 (Wed, 06 Dec 2006)
New Revision: 58874

Removed:
   tags/JBoss_4_0_4_GA_CP03/
Log:
wrong version info - missing dot



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 14:11:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 14:11:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r58875 -
	branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic
Message-ID: <E1Gs2BO-0006qf-2w@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 14:11:53 -0500 (Wed, 06 Dec 2006)
New Revision: 58875

Modified:
   branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent
   branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml
Log:
updated version info

Modified: branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent
===================================================================
--- branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-06 19:01:28 UTC (rev 58874)
+++ branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-06 19:11:53 UTC (rev 58875)
@@ -99,7 +99,7 @@
   <property name="version.major" value="4"/>
   <property name="version.minor" value="0"/>
   <property name="version.revision" value="4"/>
-  <property name="version.tag" value="GA_CP03"/>
+  <property name="version.tag" value=".GA_CP03"/>
   <property name="version.name" value="Zion"/>
   <!-- This must be set to the CVS tag for any release -->
   <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_4_GA_CP03" />

Modified: branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml	2006-12-06 19:01:28 UTC (rev 58874)
+++ branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml	2006-12-06 19:11:53 UTC (rev 58875)
@@ -17,7 +17,7 @@
     <property name="version.major" value="4"/>
     <property name="version.minor" value="0"/>
     <property name="version.revision" value="4"/>
-    <property name="version.tag" value="GA_CP03"/>
+    <property name="version.tag" value=".GA_CP03"/>
     <property name="version.name" value="Zion"/>
     <!-- This must be set to the CVS tag for any release -->
     <property name="version.cvstag" value="https://svn.jboss.org/repos/jbossas/tags/JBoss_4_0_4_GA_CP03"/>



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 14:14:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 14:14:11 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58876 - tags
Message-ID: <E1Gs2Db-0006qy-K6@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 14:14:11 -0500 (Wed, 06 Dec 2006)
New Revision: 58876

Added:
   tags/JBoss_4_0_4_GA_CP03/
Log:
cut the 4.0.4.GA_CP03 release

Copied: tags/JBoss_4_0_4_GA_CP03 (from rev 58875, branches/JBoss_4_0_4_GA_CP)



From ovidiu.feodorov at jboss.com  Wed Dec  6 14:23:12 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 06 Dec 2006 14:23:12 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.0.1.SP2 - New
	directory ...
Message-ID: <E1Gs2MK-0006zE-Ha@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/06 14:23:12

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/messaging/1.0.1.SP2 added to the repository


From ovidiu.feodorov at jboss.com  Wed Dec  6 14:23:48 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 06 Dec 2006 14:23:48 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.0.1.SP2/lib - New
	directory ...
Message-ID: <E1Gs2Mu-0006zS-AL@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/06 14:23:48

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/messaging/1.0.1.SP2/lib added to the repository


From rawblem at gmail.com  Wed Dec  6 14:24:33 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 06 Dec 2006 14:24:33 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards
	- New directory ...
Message-ID: <E1Gs2Nd-0006zh-NP@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/06 14:24:33

  Log:
  Directory /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards added to the repository


From rawblem at gmail.com  Wed Dec  6 14:24:35 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 06 Dec 2006 14:24:35 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards
	...
Message-ID: <E1Gs2Nf-0006zw-2l@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/06 14:24:35

  Added:       core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards  
                        WizardPageWithNotification.java
                        WizardWithNotification.java
  Log:
  More informative API for the pages
  
  Revision  Changes    Path
  1.1      date: 2006/12/06 19:24:35;  author: rawb;  state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardPageWithNotification.java
  
  Index: WizardPageWithNotification.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.ui.wizards;
  
  import org.eclipse.jface.dialogs.PageChangedEvent;
  import org.eclipse.jface.resource.ImageDescriptor;
  import org.eclipse.jface.wizard.IWizardPage;
  import org.eclipse.jface.wizard.WizardPage;
  import org.eclipse.swt.widgets.Composite;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public abstract class WizardPageWithNotification extends WizardPage implements IWizardPage {
  	/**
  	 * @param pageName
  	 */
  	protected WizardPageWithNotification(String pageName) {
  		super(pageName);
  	}
  	
      protected WizardPageWithNotification(String pageName, String title,
              ImageDescriptor titleImage) {
      	super(pageName, title, titleImage);
      }
  
  	
      public void pageEntered(int button) {}
      public void pageExited(int button) {}
  }
  
  
  
  1.1      date: 2006/12/06 19:24:35;  author: rawb;  state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardWithNotification.java
  
  Index: WizardWithNotification.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.ui.wizards;
  
  import org.eclipse.jface.dialogs.IDialogPage;
  import org.eclipse.jface.dialogs.IPageChangedListener;
  import org.eclipse.jface.dialogs.PageChangedEvent;
  import org.eclipse.jface.wizard.IWizardContainer;
  import org.eclipse.jface.wizard.IWizardPage;
  import org.eclipse.jface.wizard.Wizard;
  import org.eclipse.jface.wizard.WizardDialog;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public abstract class WizardWithNotification extends Wizard implements IPageChangedListener {
  	public static final int NEXT = 1;
  	public static final int PREVIOUS = 2;
  	public static final int UNKNOWN = 4;
  	
  	
  	private IWizardPage currentPage;
  	public WizardWithNotification() {
  		super();
  		currentPage = null;
  	}
      public void setContainer(IWizardContainer wizardContainer) {
      	IWizardContainer previous = getContainer();
      	super.setContainer(wizardContainer);
      	
      	// listeners
      	if( previous instanceof WizardDialog ) {
      		((WizardDialog)previous).removePageChangedListener(this);
      	}
      	
      	if( wizardContainer instanceof WizardDialog ) {
      		((WizardDialog)wizardContainer).addPageChangedListener(this);
      	}
      }
  	public void pageChanged(PageChangedEvent event) {
  		if( currentPage == null ) {
  			currentPage = (IWizardPage)event.getSelectedPage();
  			if( currentPage instanceof WizardPageWithNotification) {
  				((WizardPageWithNotification)currentPage).pageEntered(UNKNOWN);
  			}
  			return;
  		}
  		
  		Object selectedPage = event.getSelectedPage();
  		IWizardPage previous = currentPage.getPreviousPage();
  		IWizardPage next = currentPage.getNextPage();
  		
  		if( previous != null && previous.equals(selectedPage)) {
  			if( currentPage instanceof WizardPageWithNotification ) 
  				((WizardPageWithNotification)currentPage).pageExited(PREVIOUS);
  			if( selectedPage instanceof WizardPageWithNotification ) 
  				((WizardPageWithNotification)selectedPage).pageEntered(PREVIOUS);
  		} else if( next != null && next.equals(selectedPage)) {
  			if( currentPage instanceof WizardPageWithNotification ) 
  				((WizardPageWithNotification)currentPage).pageExited(NEXT);
  			if( selectedPage instanceof WizardPageWithNotification ) 
  				((WizardPageWithNotification)selectedPage).pageEntered(NEXT);
  		} else {
  			if( currentPage instanceof WizardPageWithNotification ) {
  				((WizardPageWithNotification)currentPage).pageExited(UNKNOWN);
  			}
  			if( selectedPage instanceof WizardPageWithNotification) {
  				((WizardPageWithNotification)selectedPage).pageEntered(UNKNOWN);
  			}
  		}
  		currentPage = selectedPage instanceof IWizardPage ? ((IWizardPage)selectedPage) : null;
  	}
  
  
  }
  
  
  


From ovidiu.feodorov at jboss.com  Wed Dec  6 14:24:39 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 06 Dec 2006 14:24:39 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.0.1.SP2  ...
Message-ID: <E1Gs2Nj-000706-4n@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/06 14:24:39

  Added:       jboss/messaging/1.0.1.SP2  component-info.xml
  Log:
  adding 1.0.1.SP2
  
  Revision  Changes    Path
  1.1      date: 2006/12/06 19:24:39;  author: ovidiu;  state: Exp;repository.jboss.com/jboss/messaging/1.0.1.SP2/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/messaging-component-info">
  
     <component id="jboss/messaging"
                version="1.0.1.SP1"
                licenseType="lgpl"
                projectHome="http://www.jboss.org/products/messaging"
                description="The JBoss JMS provider">
  
        <artifact id="jboss-messaging.jar"/>
  
        <import componentref="jboss/serialization">
               <compatible version="1.0.2.GA"/>
               <compatible version="1.0.3.GA"/>
        </import>
  
        <import componentref="jboss/remoting">
               <compatible version="2.2.0.Alpha3"/>
        </import>
  
        <import componentref="jboss/aop">
               <compatible version="1.5.0.GA"/>
        </import>
  
        <export>
           <include input="jboss-messaging.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From ovidiu.feodorov at jboss.com  Wed Dec  6 14:24:39 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 06 Dec 2006 14:24:39 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.0.1.SP2/lib  ...
Message-ID: <E1Gs2Nj-00070C-81@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/06 14:24:39

  Added:       jboss/messaging/1.0.1.SP2/lib  jboss-messaging.jar
  Log:
  adding 1.0.1.SP2
  
  Revision  Changes    Path
  1.1      date: 2006/12/06 19:24:39;  author: ovidiu;  state: Exp;repository.jboss.com/jboss/messaging/1.0.1.SP2/lib/jboss-messaging.jar
  
  	<<Binary file>>
  
  


From scott.stark at jboss.com  Wed Dec  6 14:42:06 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 14:42:06 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/remoting/2.2.0.Alpha4  ...
Message-ID: <E1Gs2ec-0007Lu-Lu@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 14:42:06

  Modified:    jboss/remoting/2.2.0.Alpha4  component-info.xml
  Log:
  Add a jboss-remoting-src.zip artifact
  
  Revision  Changes    Path
  1.2       +1 -0      repository.jboss.com/jboss/remoting/2.2.0.Alpha4/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/remoting/2.2.0.Alpha4/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	23 Nov 2006 01:41:27 -0000	1.1
  +++ component-info.xml	6 Dec 2006 19:42:06 -0000	1.2
  @@ -10,6 +10,7 @@
                 projectHome="http://www.jboss.org/products/remoting"
                 description="a single API for most network based invocations and related service that uses pluggable transports and data marshallers">
         <artifact id="jboss-remoting.jar"/>
  +      <artifact id="jboss-remoting-src.zip"/>
   
         <import componentref="jboss/serialization">
         	<compatible version="1.0.0.GA"/>
  
  
  


From scott.stark at jboss.com  Wed Dec  6 14:42:06 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 14:42:06 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/remoting/2.2.0.Alpha4/lib ...
Message-ID: <E1Gs2ec-0007M0-Pw@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 14:42:06

  Added:       jboss/remoting/2.2.0.Alpha4/lib  jboss-remoting-src.zip
  Log:
  Add a jboss-remoting-src.zip artifact
  
  Revision  Changes    Path
  1.1      date: 2006/12/06 19:42:06;  author: starksm;  state: Exp;repository.jboss.com/jboss/remoting/2.2.0.Alpha4/lib/jboss-remoting-src.zip
  
  	<<Binary file>>
  
  


From rawblem at gmail.com  Wed Dec  6 14:42:20 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 06 Dec 2006 14:42:20 -0500
Subject: [jboss-cvs] jbosside/core/plugins/org.jboss.ide.eclipse.ui/META-INF
	...
Message-ID: <E1Gs2eq-0007MA-Cm@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/06 14:42:20

  Modified:    core/plugins/org.jboss.ide.eclipse.ui/META-INF  MANIFEST.MF
  Log:
  More informative API for the pages
  
  Revision  Changes    Path
  1.6       +2 -1      jbosside/core/plugins/org.jboss.ide.eclipse.ui/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.ui/META-INF/MANIFEST.MF,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- MANIFEST.MF	2 Jun 2006 22:11:13 -0000	1.5
  +++ MANIFEST.MF	6 Dec 2006 19:42:20 -0000	1.6
  @@ -9,7 +9,8 @@
   Bundle-Localization: plugin
   Export-Package: org.jboss.ide.eclipse.ui,
    org.jboss.ide.eclipse.ui.dialogs,
  - org.jboss.ide.eclipse.ui.util
  + org.jboss.ide.eclipse.ui.util,
  + org.jboss.ide.eclipse.ui.wizards
   Require-Bundle: org.eclipse.core.runtime,
    org.eclipse.ui.ide,
    org.eclipse.ui.views,
  
  
  


From scott.stark at jboss.com  Wed Dec  6 14:45:05 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 14:45:05 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/remoting/2.2.0.Alpha2  ...
Message-ID: <E1Gs2hV-0007NA-2z@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 14:45:05

  Modified:    jboss/remoting/2.2.0.Alpha2  component-info.xml
  Log:
  Add a jboss-remoting-src.zip artifact
  
  Revision  Changes    Path
  1.2       +1 -0      repository.jboss.com/jboss/remoting/2.2.0.Alpha2/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/remoting/2.2.0.Alpha2/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	21 Sep 2006 22:25:50 -0000	1.1
  +++ component-info.xml	6 Dec 2006 19:45:05 -0000	1.2
  @@ -10,6 +10,7 @@
                 projectHome="http://www.jboss.org/products/remoting"
                 description="a single API for most network based invocations and related service that uses pluggable transports and data marshallers">
         <artifact id="jboss-remoting.jar"/>
  +      <artifact id="jboss-remoting-src.zip"/>
   
         <import componentref="jboss/serialization">
         	<compatible version="1.0.0.GA"/>
  
  
  


From scott.stark at jboss.com  Wed Dec  6 14:45:05 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 06 Dec 2006 14:45:05 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/remoting/2.2.0.Alpha2/lib ...
Message-ID: <E1Gs2hV-0007NH-7q@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/06 14:45:05

  Added:       jboss/remoting/2.2.0.Alpha2/lib  jboss-remoting-src.zip
  Log:
  Add a jboss-remoting-src.zip artifact
  
  Revision  Changes    Path
  1.1      date: 2006/12/06 19:45:05;  author: starksm;  state: Exp;repository.jboss.com/jboss/remoting/2.2.0.Alpha2/lib/jboss-remoting-src.zip
  
  	<<Binary file>>
  
  


From mculpepper at jboss.com  Wed Dec  6 15:17:55 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 15:17:55 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal
	...
Message-ID: <E1Gs3DH-000894-B0@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 15:17:55

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal 
                        PackageImpl.java
  Log:
  added getPackageFilePath() to appease rawb
  
  Revision  Changes    Path
  1.6       +7 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- PackageImpl.java	6 Dec 2006 17:02:56 -0000	1.5
  +++ PackageImpl.java	6 Dec 2006 20:17:55 -0000	1.6
  @@ -46,7 +46,7 @@
    * A Package.
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class PackageImpl extends PackageNodeImpl implements IPackage, IPackageWorkingCopy {
   
  @@ -124,6 +124,12 @@
   		} else return null;
   	}
   
  +	public IPath getPackageFilePath() {
  +		if (!isDestinationInWorkspace()) {
  +			return getDestinationFolder().append(new Path(getName()));
  +		} else return null;
  +	}
  +	
   	public boolean isExploded() {
   		return packageDelegate.isExploded();
   	}
  
  
  


From mculpepper at jboss.com  Wed Dec  6 15:17:55 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 06 Dec 2006 15:17:55 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model
	...
Message-ID: <E1Gs3DH-00089B-F0@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/06 15:17:55

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model 
                        IPackage.java
  Log:
  added getPackageFilePath() to appease rawb
  
  Revision  Changes    Path
  1.4       +7 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackage.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- IPackage.java	20 Nov 2006 21:06:04 -0000	1.3
  +++ IPackage.java	6 Dec 2006 20:17:55 -0000	1.4
  @@ -35,7 +35,7 @@
    * </p>
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    */
   public interface IPackage extends IPackageNode {
   
  @@ -128,6 +128,12 @@
   	public IFile getPackageFile();
   
   	/**
  +	 * Get the absolute path on the file system that corresponds with this package. Note that this method only works for external (filesystem) packages (null will be returned otherwise)
  +	 * @return The absolute path to the package (note the file may not exist)
  +	 */
  +	public IPath getPackageFilePath();
  +	
  +	/**
   	 * If this package is not top-level, this will return a relative path to this package from within it's parent, i.e.
   	 * my.ear/web/my.war/WEB-INF/lib. Otherwise, this will return null
   	 * @return a relative IPath to this package's top level parent
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 15:46:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 15:46:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r58877 -
	trunk/deployment/src/main/org/jboss/deployment/services
Message-ID: <E1Gs3fA-000082-J2@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 15:46:42 -0500 (Wed, 06 Dec 2006)
New Revision: 58877

Modified:
   trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerService.java
   trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerServiceMBean.java
Log:
Correct the module type identification and add an ejb3DeployerType.

Modified: trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerService.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerService.java	2006-12-06 19:14:11 UTC (rev 58876)
+++ trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerService.java	2006-12-06 20:46:42 UTC (rev 58877)
@@ -28,7 +28,6 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.net.URL;
-import java.net.URLConnection;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.HashMap;
@@ -40,7 +39,7 @@
 import javax.enterprise.deploy.spi.exceptions.TargetException;
 
 import org.jboss.deployers.plugins.structure.AbstractDeploymentContext;
-import org.jboss.deployers.spi.attachments.Attachments;
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
 import org.jboss.deployers.spi.deployment.MainDeployer;
 import org.jboss.deployers.spi.structure.DeploymentContext;
 import org.jboss.deployers.spi.structure.DeploymentState;
@@ -79,6 +78,7 @@
     * The type of attachment used to identify a EJB
     */
    private Class ejbDeployerType;
+   private Class ejb3DeployerType;
    /**
     * The type of attachment used to identify a RAR
     */
@@ -132,6 +132,16 @@
    {
       this.ejbDeployerType = ejbDeployerType;
    }
+
+   public Class getEjb3DeployerType()
+   {
+      return ejb3DeployerType;
+   }
+   public void setEjb3DeployerType(Class ejb3DeployerType)
+   {
+      this.ejb3DeployerType = ejb3DeployerType;
+   }
+
    public Class getRarDeployerType()
    {
       return rarDeployerType;
@@ -194,8 +204,7 @@
 
       // Create a status object
       URL deployURL = new URL(url);
-      URLConnection conn = deployURL.openConnection();
-      int contentLength = conn.getContentLength();
+      int contentLength = deployURL.openConnection().getContentLength();
       log.debug("Begin deploy, url: " + deployURL + ", contentLength: " + contentLength);
 
       // Create the local path
@@ -215,7 +224,11 @@
             throw new IOException("Failed to create local path: " + parentFile);
       }
 
-      InputStream is = conn.getInputStream();
+      InputStream is = moduleID.getContentIS();
+      if( is == null )
+      {
+         is = deployURL.openStream();
+      }
       BufferedInputStream bis = new BufferedInputStream(is);
       byte[] buffer = new byte[4096];
       FileOutputStream fos = new FileOutputStream(deployFile);
@@ -316,6 +329,11 @@
       return ids;
    }
 
+   /**
+    * Travers the deployment children to build up the jsr88 module children 
+    * @param moduleID
+    * @param info
+    */
    private void fillChildrenTargetModuleID(SerializableTargetModuleID moduleID,
          DeploymentContext info)
    {
@@ -354,25 +372,26 @@
    private ModuleType getModuleType(DeploymentContext info)
    {
       ModuleType type = null;
+      DeploymentUnit unit = info.getDeploymentUnit();
 
-      Attachments attachments = info.getTransientAttachments();      
-      if (attachments.getAttachment(carDeployerType) != null)
+      if (unit.getAttachment(carDeployerType) != null)
       {
          type = ModuleType.CAR;
       }
-      else if (attachments.getAttachment(ejbDeployerType) != null)
+      else if (unit.getAttachment(ejbDeployerType) != null
+            || unit.getAttachment(ejb3DeployerType) != null)
       {
          type = ModuleType.EJB;
       }
-      else if (attachments.getAttachment(earDeployerType) != null)
+      else if (unit.getAttachment(earDeployerType) != null)
       {
          type = ModuleType.EAR;
       }
-      else if (attachments.getAttachment(rarDeployerType) != null)
+      else if (unit.getAttachment(rarDeployerType) != null)
       {
          type = ModuleType.RAR;
       }
-      else if (attachments.getAttachment(warDeployerType) != null)
+      else if (unit.getAttachment(warDeployerType) != null)
       {
          type = ModuleType.WAR;
       }

Modified: trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerServiceMBean.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerServiceMBean.java	2006-12-06 19:14:11 UTC (rev 58876)
+++ trunk/deployment/src/main/org/jboss/deployment/services/DeploymentManagerServiceMBean.java	2006-12-06 20:46:42 UTC (rev 58877)
@@ -27,8 +27,6 @@
 import javax.enterprise.deploy.spi.exceptions.TargetException;
 
 import org.jboss.deployers.spi.deployment.MainDeployer;
-import org.jboss.deployers.spi.structure.vfs.StructureBuilder;
-import org.jboss.deployers.spi.structure.vfs.StructuredDeployers;
 import org.jboss.deployment.spi.SerializableTargetModuleID;
 
 /**
@@ -53,6 +51,8 @@
    public void setEarDeployerType(Class earDeployerType);
    public Class getEjbDeployerType();
    public void setEjbDeployerType(Class ejbDeployerType);
+   public Class getEjb3DeployerType();
+   public void setEjb3DeployerType(Class ejb3DeployerType);
    public Class getRarDeployerType();
    public void setRarDeployerType(Class rarDeployerType);
    public Class getWarDeployerType();



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 15:48:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 15:48:01 -0500
Subject: [jboss-cvs] JBossAS SVN: r58878 - in trunk/deployment: . src/etc
	src/main/org/jboss/deployment src/main/org/jboss/deployment/remoting
	src/main/org/jboss/deployment/spi
	src/main/org/jboss/deployment/spi/factories
Message-ID: <E1Gs3gP-0000Ao-1x@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 15:47:52 -0500 (Wed, 06 Dec 2006)
New Revision: 58878

Added:
   trunk/deployment/src/main/org/jboss/deployment/remoting/
   trunk/deployment/src/main/org/jboss/deployment/remoting/DeployHandler.java
   trunk/deployment/src/main/org/jboss/deployment/remoting/StreamingTarget.java
Modified:
   trunk/deployment/.classpath
   trunk/deployment/build.xml
   trunk/deployment/src/etc/jsr88-service.xml
   trunk/deployment/src/main/org/jboss/deployment/spi/DeploymentManagerImpl.java
   trunk/deployment/src/main/org/jboss/deployment/spi/JMXTarget.java
   trunk/deployment/src/main/org/jboss/deployment/spi/SerializableTargetModuleID.java
   trunk/deployment/src/main/org/jboss/deployment/spi/factories/DeploymentFactoryImpl.java
Log:
Add support for a remoting streaming target implementation.

Modified: trunk/deployment/.classpath
===================================================================
--- trunk/deployment/.classpath	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/.classpath	2006-12-06 20:47:52 UTC (rev 58878)
@@ -11,6 +11,7 @@
 	<classpathentry combineaccessrules="false" kind="src" path="/j2se"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/system"/>
 	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar" />
+	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: trunk/deployment/build.xml
===================================================================
--- trunk/deployment/build.xml	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/build.xml	2006-12-06 20:47:52 UTC (rev 58878)
@@ -88,6 +88,7 @@
       <path refid="jboss.j2se.classpath"/>
       <path refid="jboss.system.classpath"/>
       <path refid="jboss.systemjmx.classpath"/>
+      <path refid="jboss.remoting.classpath"/>
     </path>
 
     <!-- ===== -->

Modified: trunk/deployment/src/etc/jsr88-service.xml
===================================================================
--- trunk/deployment/src/etc/jsr88-service.xml	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/etc/jsr88-service.xml	2006-12-06 20:47:52 UTC (rev 58878)
@@ -8,7 +8,8 @@
       type 
       -->
       <attribute name="EarDeployerType">org.jboss.deployment.J2eeApplicationMetaData</attribute>
-      <attribute name="EjbDeployerType">org.jboss.ejb3.Ejb3Deployment</attribute>
+      <attribute name="EjbDeployerType">org.jboss.metadata.ApplicationMetaData</attribute>
+      <attribute name="Ejb3DeployerType">org.jboss.ejb3.Ejb3Deployment</attribute>
       <attribute name="RarDeployerType">org.jboss.resource.metadata.ConnectorMetaData</attribute>
       <attribute name="WarDeployerType">org.jboss.metadata.WebMetaData</attribute>
       <attribute name="CarDeployerType">org.jboss.ejb3.metamodel.ApplicationClientDD</attribute>

Added: trunk/deployment/src/main/org/jboss/deployment/remoting/DeployHandler.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/remoting/DeployHandler.java	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/main/org/jboss/deployment/remoting/DeployHandler.java	2006-12-06 20:47:52 UTC (rev 58878)
@@ -0,0 +1,142 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.deployment.remoting;
+
+import java.io.InputStream;
+import java.util.Map;
+
+import javax.management.MBeanServer;
+import javax.management.MBeanServerInvocationHandler;
+import javax.management.ObjectName;
+
+import org.jboss.deployment.services.DeploymentManagerServiceMBean;
+import org.jboss.deployment.spi.SerializableTargetModuleID;
+import org.jboss.logging.Logger;
+import org.jboss.remoting.InvocationRequest;
+import org.jboss.remoting.ServerInvoker;
+import org.jboss.remoting.callback.InvokerCallbackHandler;
+import org.jboss.remoting.stream.StreamInvocationHandler;
+
+/**
+ * A remoting StreamInvocationHandler installed as the JSR88 subsystem
+ * handler and used by the StreamingTarget implementation. 
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class DeployHandler implements StreamInvocationHandler
+{
+   static Logger log = Logger.getLogger(DeployHandler.class);
+
+   private DeploymentManagerServiceMBean deployService;
+
+   public DeploymentManagerServiceMBean getDeployService()
+   {
+      return deployService;
+   }
+
+   public void setDeployService(DeploymentManagerServiceMBean deployService)
+   {
+      this.deployService = deployService;
+   }
+
+   /**
+    * Handle a deployService deploy invocation
+    * @param request - the remoting invocation
+    */
+   public Object handleStream(InputStream contentIS, InvocationRequest request)
+      throws Throwable
+   {
+      SerializableTargetModuleID moduleID = (SerializableTargetModuleID) request.getParameter();
+      log.debug("handleStream, moduleID: "+moduleID);
+      moduleID.setContentIS(contentIS);
+      deployService.deploy(moduleID);
+      return null;
+   }
+
+   public void addListener(InvokerCallbackHandler arg0)
+   {      
+   }
+
+   /**
+    * Handle a deployService invocation other than deploy
+    * @param request - the remoting invocation
+    */
+   public Object invoke(InvocationRequest request) throws Throwable
+   {
+      String name = request.getParameter().toString();
+      Map payload = request.getRequestPayload();
+      String url = (String) payload.get("moduleID");
+      Object returnValue = null;
+      log.debug("invoke, moduleID: "+url+", payload: "+payload);
+
+      if( name.equals("start") )
+      {
+         deployService.start(url);
+      }
+      else if( name.equals("stop") )
+      {
+         deployService.stop(url);
+         
+      }
+      else if( name.equals("undeploy") )
+      {
+         deployService.undeploy(url);         
+      }
+      else if( name.equals("getAvailableModules") )
+      {
+         Integer moduleType = (Integer) payload.get("moduleType");
+         SerializableTargetModuleID[] ids = deployService.getAvailableModules(moduleType);
+         returnValue = ids;
+      }
+      return returnValue;
+   }
+
+   public void removeListener(InvokerCallbackHandler arg0)
+   {
+   }
+
+   public void setInvoker(ServerInvoker arg0)
+   {
+   }
+
+   /**
+    * Legacy initialzation of the DeploymentManagerServiceMBean via
+    * jmx lookup.
+    * TODO: the deployService should be injected.
+    */
+   public void setMBeanServer(MBeanServer server)
+   {
+      try
+      {
+         ObjectName jsr88 = new ObjectName("jboss.management.local:type=JSR88DeploymentManager,name=DefaultManager");
+         deployService = (DeploymentManagerServiceMBean)
+            MBeanServerInvocationHandler.newProxyInstance(server, jsr88, DeploymentManagerServiceMBean.class, false);
+         log.debug("Initialzied DeploymentManagerServiceMBean");
+      }
+      catch(Exception e)
+      {
+         log.warn("Failed to lookup DeploymentManagerServiceMBean", e);
+      }
+   }
+
+}

Added: trunk/deployment/src/main/org/jboss/deployment/remoting/StreamingTarget.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/remoting/StreamingTarget.java	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/main/org/jboss/deployment/remoting/StreamingTarget.java	2006-12-06 20:47:52 UTC (rev 58878)
@@ -0,0 +1,309 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.deployment.remoting;
+
+import java.io.InputStream;
+import java.net.InetAddress;
+import java.net.URI;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
+
+import javax.enterprise.deploy.shared.ModuleType;
+import javax.enterprise.deploy.spi.TargetModuleID;
+import javax.enterprise.deploy.spi.exceptions.TargetException;
+
+import org.jboss.deployment.spi.DeploymentManagerImpl;
+import org.jboss.deployment.spi.JBossTarget;
+import org.jboss.deployment.spi.SerializableTargetModuleID;
+import org.jboss.deployment.spi.TargetModuleIDImpl;
+import org.jboss.logging.Logger;
+import org.jboss.remoting.Client;
+import org.jboss.remoting.InvokerLocator;
+
+/**
+ * A JBossTarget implementation that uses remoting streaming to upload
+ * deployments. This target is selected by including a targetType=remote
+ * param in the DeploymentManager deployURI. 
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class StreamingTarget implements JBossTarget
+{
+   private static final Logger log = Logger.getLogger(StreamingTarget.class);
+   public static final String DESCRIPTION = "JBoss remoting streaming deployment target";
+
+   /**
+    * The default remoting subsystem
+    */
+   private static final String REMOTING_SUBSYSTEM = "JSR88";
+
+   /** The deployment target uri */
+   private URI deployURI;
+
+   /**
+    * Create a target given a remoting locator URI 
+    * @param deployURI
+    */
+   public StreamingTarget(URI deployURI)
+   {
+      log.debug("new StreamingTarget: " + deployURI);
+      try
+      {
+         String localHostName = InetAddress.getLocalHost().getHostName();
+
+         String scheme = deployURI.getScheme();
+         String host = deployURI.getHost();
+         int port = deployURI.getPort();
+         String query = deployURI.getRawQuery();
+
+         String uri = deployURI.toASCIIString();
+         if (uri.startsWith(DeploymentManagerImpl.DEPLOYER_URI))
+         {
+            // Using unified invoker remoting defaults
+            scheme = "socket";
+            host = localHostName;
+            port = 4446;
+            query = null;
+         }
+
+         StringBuffer tmp = new StringBuffer(scheme + "://");
+         tmp.append(host != null ? host : localHostName);
+         tmp.append(port > 0 ? ":" + port : "");
+         tmp.append(query != null ? "/?" + query : "");
+         deployURI = new URI(tmp.toString());
+
+         log.debug("URI changed to: " + deployURI);
+         this.deployURI = deployURI;
+      }
+      catch (Exception e)
+      {
+         log.error(e);
+      }
+
+   }
+
+   /**
+    * Get the target's description
+    * @return the description
+    */
+   public String getDescription()
+   {
+      return DESCRIPTION;
+   }
+
+   /**
+    * Get the target's name
+    * @return the name
+    */
+   public String getName()
+   {
+      return deployURI.toString();
+   }
+
+   /**
+    * Get the target's host name
+    */
+   public String getHostName()
+   {
+      return deployURI.getHost();
+   }
+
+   /**
+    * Deploy a given module
+    */
+   public void deploy(TargetModuleID targetModuleID) throws Exception
+   {
+      TargetModuleIDImpl moduleID = (TargetModuleIDImpl)targetModuleID;
+      SerializableTargetModuleID smoduleID = new SerializableTargetModuleID(moduleID);
+      Client client = getClient();
+      log.info("Begin deploy: " + moduleID);
+      transferDeployment(client, smoduleID);
+      log.info("End deploy");
+      client.disconnect();
+   }
+
+   /**
+    * Start a given module
+    */
+   public void start(TargetModuleID targetModuleID) throws Exception
+   {
+      Client client = getClient();
+      URL url = new URL(targetModuleID.getModuleID());
+      log.debug("Start: " + url);
+      HashMap<String, String> args = new HashMap<String, String>(1);
+      args.put("moduleID", url.toExternalForm());
+      log.info("Begin start: " + url);
+      invoke(client, "start", args);
+      log.info("End start");
+   }
+
+   /**
+    * Stop a given module
+    */
+   public void stop(TargetModuleID targetModuleID) throws Exception
+   {
+      Client client = getClient();
+      URL url = new URL(targetModuleID.getModuleID());
+      log.debug("Start: " + url);
+      HashMap<String, String> args = new HashMap<String, String>(1);
+      args.put("moduleID", url.toExternalForm());
+      log.info("Begin stop: " + url);
+      invoke(client, "stop", args);
+      log.info("End stop");
+   }
+
+   /**
+    * Undeploy a given module
+    */
+   public void undeploy(TargetModuleID targetModuleID) throws Exception
+   {
+      Client client = getClient();
+      URL url = new URL(targetModuleID.getModuleID());
+      log.debug("Start: " + url);
+      HashMap<String, String> args = new HashMap<String, String>(1);
+      args.put("moduleID", url.toExternalForm());
+      log.info("Begin undeploy: " + url);
+      invoke(client, "undeploy", args);
+      log.info("End undeploy");
+   }
+
+   /**
+    * Retrieve the list of all J2EE application modules running or not running
+    * on the identified targets.
+    */
+   public TargetModuleID[] getAvailableModules(ModuleType moduleType) throws TargetException
+   {
+      try
+      {
+         Client client = getClient();
+         HashMap<String, Integer> args = new HashMap<String, Integer>(1);
+         args.put("moduleType", moduleType.getValue());
+         SerializableTargetModuleID[] modules = (SerializableTargetModuleID[])
+            invoke(client, "getAvailableModules", args);
+         List<TargetModuleID> list = new ArrayList<TargetModuleID>();
+         for (int n = 0; n < modules.length; n++)
+         {
+            SerializableTargetModuleID id = modules[n];
+            String moduleID = id.getModuleID();
+            boolean isRunning = id.isRunning();
+            ModuleType type = ModuleType.getModuleType(id.getModuleType());
+            TargetModuleIDImpl tmid = new TargetModuleIDImpl(this, moduleID, null, isRunning, type);
+            convertChildren(tmid, id);
+            list.add(tmid);
+         }
+
+         TargetModuleID[] targetModuleIDs = new TargetModuleID[list.size()];
+         list.toArray(targetModuleIDs);
+         return targetModuleIDs;
+      }
+      catch (Exception e)
+      {
+         TargetException tex = new TargetException("Failed to get available modules");
+         tex.initCause(e);
+         throw tex;
+      }
+   }
+
+   private void convertChildren(TargetModuleIDImpl parent, SerializableTargetModuleID parentID)
+   {
+      SerializableTargetModuleID[] children = parentID.getChildModuleIDs();
+      int length = children != null ? children.length : 0;
+      for (int n = 0; n < length; n++)
+      {
+         SerializableTargetModuleID id = children[n];
+         String moduleID = id.getModuleID();
+         boolean isRunning = id.isRunning();
+         ModuleType type = ModuleType.getModuleType(id.getModuleType());
+         TargetModuleIDImpl child = new TargetModuleIDImpl(this, moduleID, parent, isRunning, type);
+         parent.addChildTargetModuleID(child);
+         convertChildren(child, id);
+      }
+   }
+
+   /**
+    * Get the remoting client connection
+    * @return
+    * @throws Exception
+    */
+   private Client getClient() throws Exception
+   {
+      String locatorURI = deployURI.toString();
+      InvokerLocator locator = new InvokerLocator(locatorURI);
+      log.debug("Calling remoting server with locator uri of: " + locatorURI);
+
+      Client remotingClient = new Client(locator, REMOTING_SUBSYSTEM);
+      remotingClient.connect();
+      return remotingClient;
+   }
+
+   private void transferDeployment(Client client, SerializableTargetModuleID smoduleID)
+      throws Exception
+   {
+      URL deployURL = new URL(smoduleID.getModuleID());
+      InputStream is = deployURL.openStream();
+      try
+      {
+         client.invoke(is, smoduleID);
+      }
+      catch(Exception e)
+      {
+         throw e;
+      }
+      catch(Error e)
+      {
+         throw new RuntimeException(e);
+      }
+      catch(Throwable e)
+      {
+         throw new RuntimeException(e);         
+      }
+      finally
+      {
+         is.close();
+      }
+   }
+
+   private Object invoke(Client client, String name, HashMap args)
+      throws Exception
+   {
+      try
+      {
+         Object returnValue = client.invoke(name, args);
+         return returnValue;
+      }
+      catch(Exception e)
+      {
+         throw e;
+      }
+      catch(Error e)
+      {
+         throw new RuntimeException(e);
+      }
+      catch(Throwable e)
+      {
+         throw new RuntimeException(e);         
+      }      
+   }
+}

Modified: trunk/deployment/src/main/org/jboss/deployment/spi/DeploymentManagerImpl.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/spi/DeploymentManagerImpl.java	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/main/org/jboss/deployment/spi/DeploymentManagerImpl.java	2006-12-06 20:47:52 UTC (rev 58878)
@@ -60,6 +60,7 @@
 
 import org.dom4j.Document;
 import org.dom4j.io.SAXReader;
+import org.jboss.deployment.remoting.StreamingTarget;
 import org.jboss.deployment.spi.configurations.WarConfiguration;
 import org.jboss.deployment.spi.status.DeploymentStatusImpl;
 import org.jboss.deployment.spi.status.ProgressObjectImpl;
@@ -121,10 +122,12 @@
    }
 
    /**
-    * Get the available targets. This is determined by parsing the deployURI.
-    * Currently there is only one target, either a JMXTarget that uses
-    * the RMIAdaptor based on the URI info, or a LocalhostTarget if the
-    * URI opaque.
+    * Get the available targets. This is determined by parsing the deployURI
+    * and looking at the targetType query parameter if the URI is not
+    * opaque. Supported targetTypes are:
+    * jmx = JMXTarget
+    * remote = StreamingTarget
+    * LocalhostTarget is the target type used if the URI is opaque.
     *
     * @return the available targets
     * @throws IllegalStateException when the manager is disconnected
@@ -143,8 +146,27 @@
          }
          else
          {
-            log.debug("Non-Opaque URI seen, using to JMXTarget");
-            targets = new Target[] { new JMXTarget(deployURI) };
+            log.debug("Non-Opaque URI seen, checking query for targetType");
+            // Check the query parameters
+            String query = deployURI.getQuery();
+            String[] params = {};
+            if( query != null )
+            {
+               params = query.split("&|=");
+            }
+            String targetType = "jmx";
+            for(int n = 0; n < params.length; n += 2)
+            {
+               String key = params[n];
+               String value = params[n+1];
+               if( key.endsWith("targetType") )
+                  targetType = value;
+            }
+
+            if( targetType.equals("remote") )
+               targets = new Target[] { new StreamingTarget(deployURI) };               
+            else
+               targets = new Target[] { new JMXTarget(deployURI) };
          }
       }
       return targets;

Modified: trunk/deployment/src/main/org/jboss/deployment/spi/JMXTarget.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/spi/JMXTarget.java	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/main/org/jboss/deployment/spi/JMXTarget.java	2006-12-06 20:47:52 UTC (rev 58878)
@@ -45,7 +45,9 @@
 
 /**
  * A Target that deploys using the JMX adaptor to communicate with the
- * MainDeployer using file URLs to the deployments.
+ * MainDeployer using file URLs to the deployments. This target is selected
+ * by including a targetType=jmx param in the DeploymentManager deployURI.
+ * 
  * @author Thomas.Diesler at jboss.org
  * @author Scott.Stark at jboss.com
  * @version $Revision$
@@ -53,6 +55,7 @@
 public class JMXTarget implements JBossTarget
 {
    private static final Logger log = Logger.getLogger(JMXTarget.class);
+   public static final String DESCRIPTION = "JBoss JMX deployment target";
    /**
     * The default RMIAdaptor JNDI location
     */
@@ -86,7 +89,8 @@
          String path = deployURI.getPath();
          String query = deployURI.getRawQuery();
 
-         if (new URI(DeploymentManagerImpl.DEPLOYER_URI).equals(deployURI))
+         String uri = deployURI.toASCIIString();
+         if (uri.startsWith(DeploymentManagerImpl.DEPLOYER_URI))
          {
             // Using JNDI defaults
             scheme = "jnp";
@@ -117,12 +121,12 @@
             }
          }
 
-         StringBuffer uri = new StringBuffer(scheme + "://");
-         uri.append(host != null ? host : localHostName);
-         uri.append(port > 0 ? ":" + port : "");
-         uri.append(path != null && path.length() > 0 ? path : DEFAULT_ADAPTOR_PATH);
-         uri.append(query != null ? "?" + query : "");
-         deployURI = new URI(uri.toString());
+         StringBuffer tmp = new StringBuffer(scheme + "://");
+         tmp.append(host != null ? host : localHostName);
+         tmp.append(port > 0 ? ":" + port : "");
+         tmp.append(path != null && path.length() > 0 ? path : DEFAULT_ADAPTOR_PATH);
+         tmp.append(query != null ? "?" + query : "");
+         deployURI = new URI(tmp.toString());
 
          log.debug("URI changed to: " + deployURI);
          this.deployURI = deployURI;
@@ -143,7 +147,7 @@
     */
    public String getDescription()
    {
-      return "JBoss JMX deployment target";
+      return DESCRIPTION;
    }
 
    /**
@@ -257,8 +261,7 @@
       }
       catch (Exception e)
       {
-         log.error("Cannot get available modules", e);
-         TargetException tex = new TargetException("");
+         TargetException tex = new TargetException("Failed to get available modules");
          tex.initCause(e);
          throw tex;
       }

Modified: trunk/deployment/src/main/org/jboss/deployment/spi/SerializableTargetModuleID.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/spi/SerializableTargetModuleID.java	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/main/org/jboss/deployment/spi/SerializableTargetModuleID.java	2006-12-06 20:47:52 UTC (rev 58878)
@@ -21,6 +21,7 @@
  */
 package org.jboss.deployment.spi;
 
+import java.io.InputStream;
 import java.io.Serializable;
 import java.util.ArrayList;
 
@@ -40,7 +41,10 @@
    private ArrayList childModuleIDs = new ArrayList();
    private String moduleID;
    private int moduleType;
+   /** */
    private boolean isRunning;
+   /** An optional InputStream to use to copy the contents */
+   private transient InputStream contentIS;
 
    public SerializableTargetModuleID(TargetModuleIDImpl impl)
    {
@@ -112,6 +116,25 @@
       this.isRunning = flag;
    }
 
+   /**
+    * An optional deployment archive content stream for the top-level
+    * module that should be used over the moduleID url.
+    * 
+    * @return the archive input stream if it exists
+    */
+   public InputStream getContentIS()
+   {
+      return contentIS;
+   }
+   /**
+    * 
+    * @param contentIS
+    */
+   public void setContentIS(InputStream contentIS)
+   {
+      this.contentIS = contentIS;
+   }
+
    public String toString()
    {
       return "SerializableTargetModuleID{" + "parentModuleID=@" + System.identityHashCode(parentModuleID) + ", childModuleIDs=" + childModuleIDs + ", moduleID='"

Modified: trunk/deployment/src/main/org/jboss/deployment/spi/factories/DeploymentFactoryImpl.java
===================================================================
--- trunk/deployment/src/main/org/jboss/deployment/spi/factories/DeploymentFactoryImpl.java	2006-12-06 20:46:42 UTC (rev 58877)
+++ trunk/deployment/src/main/org/jboss/deployment/spi/factories/DeploymentFactoryImpl.java	2006-12-06 20:47:52 UTC (rev 58878)
@@ -69,21 +69,34 @@
     */
    static
    {
-      Package pkg = Package.getPackage("org.jboss.deploy.spi.factories");
-      if (pkg != null)
+      register();
+   }
+
+   /**
+    * Register a DeploymentFactoryImpl instance with the DeploymentFactoryManager.
+    * This obtains the display name and version from the Package object for
+    * org.jboss.deploy.spi.factories
+    *
+    */
+   public synchronized static void register()
+   {
+      // Register this deployment factory with the manager
+      if( DISPLAY_NAME == null )
       {
-         DISPLAY_NAME = pkg.getImplementationVendor();
-         PRODUCT_VERSION = pkg.getImplementationVersion();
+         DeploymentFactoryManager manager = DeploymentFactoryManager.getInstance();
+         manager.registerDeploymentFactory(new DeploymentFactoryImpl());      
+         Package pkg = Package.getPackage("org.jboss.deploy.spi.factories");
+         if (pkg != null)
+         {
+            DISPLAY_NAME = pkg.getImplementationVendor();
+            PRODUCT_VERSION = pkg.getImplementationVersion();
+         }
+         if (DISPLAY_NAME == null || PRODUCT_VERSION == null)
+         {
+            DISPLAY_NAME = "DeploymentFactoryImpl";
+            PRODUCT_VERSION = "1.1-DEV";
+         }
       }
-      if (DISPLAY_NAME == null || PRODUCT_VERSION == null)
-      {
-         DISPLAY_NAME = "DeploymentFactoryImpl";
-         PRODUCT_VERSION = "1.1-DEV";
-      }
-
-      // Register this deployment factory with the manager 
-      DeploymentFactoryManager manager = DeploymentFactoryManager.getInstance();
-      manager.registerDeploymentFactory(new DeploymentFactoryImpl());
    }
 
    /**



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 15:49:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 15:49:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r58879 - trunk/server/src/etc/conf/default
Message-ID: <E1Gs3hl-0000B7-9y@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 15:49:23 -0500 (Wed, 06 Dec 2006)
New Revision: 58879

Modified:
   trunk/server/src/etc/conf/default/jboss-service.xml
Log:
Add a JSR88 subsystem handler of type org.jboss.deployment.remoting.DeployHandler


Modified: trunk/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- trunk/server/src/etc/conf/default/jboss-service.xml	2006-12-06 20:47:52 UTC (rev 58878)
+++ trunk/server/src/etc/conf/default/jboss-service.xml	2006-12-06 20:49:23 UTC (rev 58879)
@@ -537,6 +537,7 @@
             <handlers>
                <!-- can also specify handler by fully qualified classname -->
                <handler subsystem="invoker">jboss:service=invoker,type=unified</handler>
+               <handler subsystem="JSR88">org.jboss.deployment.remoting.DeployHandler</handler>               
             </handlers>
          </config>
       </attribute>



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 15:50:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 15:50:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r58880 - trunk/server/src/etc/conf/default
Message-ID: <E1Gs3iT-0000CO-Uj@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 15:50:08 -0500 (Wed, 06 Dec 2006)
New Revision: 58880

Modified:
   trunk/server/src/etc/conf/default/jboss-service.xml
Log:
Comment the JSR88 handler

Modified: trunk/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- trunk/server/src/etc/conf/default/jboss-service.xml	2006-12-06 20:49:23 UTC (rev 58879)
+++ trunk/server/src/etc/conf/default/jboss-service.xml	2006-12-06 20:50:08 UTC (rev 58880)
@@ -537,6 +537,7 @@
             <handlers>
                <!-- can also specify handler by fully qualified classname -->
                <handler subsystem="invoker">jboss:service=invoker,type=unified</handler>
+               <!-- The JSR88 deployment service StreamingTarget handler -->
                <handler subsystem="JSR88">org.jboss.deployment.remoting.DeployHandler</handler>               
             </handlers>
          </config>



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 16:01:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 16:01:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58881 -
	trunk/testsuite/src/main/org/jboss/test/deployment
Message-ID: <E1Gs3tB-0000O8-6h@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 16:01:09 -0500 (Wed, 06 Dec 2006)
New Revision: 58881

Added:
   trunk/testsuite/src/main/org/jboss/test/deployment/BaseDeploymentTestCase.java
   trunk/testsuite/src/main/org/jboss/test/deployment/JMXDeploymentTestCase.java
   trunk/testsuite/src/main/org/jboss/test/deployment/StreamingDeploymentTestCase.java
Removed:
   trunk/testsuite/src/main/org/jboss/test/deployment/DeploymentTestCase.java
Log:
Update to support both jmx and remote targetType tests

Copied: trunk/testsuite/src/main/org/jboss/test/deployment/BaseDeploymentTestCase.java (from rev 58810, trunk/testsuite/src/main/org/jboss/test/deployment/DeploymentTestCase.java)
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/deployment/DeploymentTestCase.java	2006-12-01 19:20:44 UTC (rev 58810)
+++ trunk/testsuite/src/main/org/jboss/test/deployment/BaseDeploymentTestCase.java	2006-12-06 21:01:09 UTC (rev 58881)
@@ -0,0 +1,420 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.deployment;
+
+import org.jboss.deployment.spi.DeploymentManagerImpl;
+import org.jboss.deployment.spi.DeploymentMetaData;
+import org.jboss.deployment.spi.JarUtils;
+import org.jboss.deployment.spi.TargetModuleIDImpl;
+import org.jboss.deployment.spi.factories.DeploymentFactoryImpl;
+import org.jboss.test.JBossTestCase;
+import org.jboss.util.UnreachableStatementException;
+
+import javax.ejb.CreateException;
+import javax.enterprise.deploy.shared.ModuleType;
+import javax.enterprise.deploy.shared.StateType;
+import javax.enterprise.deploy.shared.factories.DeploymentFactoryManager;
+import javax.enterprise.deploy.spi.DeploymentManager;
+import javax.enterprise.deploy.spi.Target;
+import javax.enterprise.deploy.spi.TargetModuleID;
+import javax.enterprise.deploy.spi.factories.DeploymentFactory;
+import javax.enterprise.deploy.spi.status.DeploymentStatus;
+import javax.enterprise.deploy.spi.status.ProgressObject;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+import javax.rmi.PortableRemoteObject;
+
+import java.io.BufferedReader;
+import java.io.ByteArrayInputStream;
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStreamReader;
+import java.net.URI;
+import java.net.URL;
+import java.rmi.RemoteException;
+import java.util.jar.JarOutputStream;
+
+/** 
+ * Deployment API JSR-88 tests
+ *
+ * @author Thomas.Diesler at jboss.org
+ * @author Fabiano C. de Oliveira (JBAS-1995)
+ * @author Scott.stark at jboss.org
+ * @version $Revision$
+ */
+public class BaseDeploymentTestCase extends JBossTestCase
+{
+   private static final String WAR_JBOSS_FILE = "WEB-INF/jboss-web.xml";
+
+   private static final String JAR_JBOSS_FILE = "META-INF/jboss.xml";
+
+   private static final String EAR_JBOSS_FILE = "META-INF/jboss-app.xml";
+
+   private DeploymentFactory factory;
+   private String targetType;
+
+   public BaseDeploymentTestCase(String name, String targetType)
+   {
+      super(name);
+      this.targetType = targetType;
+   }
+
+   protected String getTargetDescription()
+   {
+      return "No target specified";
+   }
+
+   /** Get the DeploymentManager
+    */
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+      DeploymentFactoryImpl.register();
+      DeploymentFactoryManager dfManager = DeploymentFactoryManager.getInstance();
+      DeploymentFactory[] factories = dfManager.getDeploymentFactories();
+      assertTrue("No DeploymentFactory available", factories.length > 0);
+      factory = factories[0];
+   }
+
+   /** Check DeploymentManager
+    */
+   public void testDeploymentManager() throws Exception
+   {
+      DeploymentManager manager = getDeploymentManager();
+
+      assertNotNull("No deployment manager", manager);
+
+      Target target = manager.getTargets()[0];
+      assertEquals(getTargetDescription(), target.getDescription());
+   }
+
+   /** Distribute a web app
+    */
+   public void testDistributeWebApp() throws Exception
+   {
+      ProgressObject progress = jsr88Deployment("deployment-web.war");
+      try
+      {
+         assertServletAccess("custom-context");
+      }
+      finally
+      {
+         jsr88Undeploy(progress.getResultTargetModuleIDs());
+      }
+      try
+      {
+         assertServletAccess("custom-context");
+         fail("Test deployment not undeployed");
+      }
+      catch (IOException e)
+      {
+         // ignore
+      }
+   }
+
+   /** 
+    * Distribute a EJB app
+    */
+   public void testDistributeEjbApp() throws Exception
+   {
+      ProgressObject progress = jsr88Deployment("deployment-ejb.jar");
+      try
+      {
+          assertEjbEchoAccess();
+      }
+      finally
+      {
+          jsr88Undeploy(progress.getResultTargetModuleIDs());
+      }
+      try
+      {
+         assertEjbEchoAccess();
+         fail("Test deployment not undeployed");
+      }
+      catch (Exception e)
+      {
+         // ignore
+      }
+   }
+
+   public void testDistributeEARApp() throws Exception
+   {
+      ProgressObject progress = jsr88Deployment("deployment-ear.ear");
+      try
+      {
+         assertServletAccess("custom-context");
+         assertEjbEchoAccess();
+      }
+      finally
+      {
+         jsr88Undeploy(progress.getResultTargetModuleIDs());
+      }
+      try
+      {
+         assertServletAccess("custom-context");
+         fail("Test deployment not undeployed");
+      }
+      catch (Exception e)
+      {
+         // ignore
+      }
+
+      try
+      {
+         assertEjbEchoAccess();
+         fail("Test deployment not undeployed");
+      }
+      catch (Exception e)
+      {
+         // ignore
+      }
+   }
+
+   /**
+    * 
+    * @throws Exception
+    */ 
+   public void testListStartStopModules() throws Exception
+   {
+      TargetModuleIDImpl child = null;
+      TargetModuleIDImpl parent = null;
+
+      // Get the deployment manager and the distribution targets
+      DeploymentManager manager = getDeploymentManager();
+      Target[] targets = manager.getTargets();
+      assertEquals(1, targets.length);
+
+      TargetModuleID[] modules = manager.getRunningModules(ModuleType.EAR, manager.getTargets());
+      assertNull("no modules Available", modules);
+
+      ProgressObject parentProgress = jsr88Deployment("deployment-ear.ear");
+      assertServletAccess("custom-context");
+      assertEjbEchoAccess();
+
+      modules = manager.getRunningModules(ModuleType.EAR, manager.getTargets());
+      assertNotNull(modules);
+      assertEquals("one EAR module in the server", modules.length, 1);
+
+      parent = (TargetModuleIDImpl) modules[0];
+      assertTrue("wrong state", parent.isRunning());
+      assertEquals("wrong type", parent.getModuleType(), ModuleType.EAR);
+      assertEquals("EAR module have a jar and a war", parent.getChildTargetModuleID().length, 2);
+
+      child = (TargetModuleIDImpl) parent.getChildTargetModuleID()[0];
+      assertTrue("wrong state", child.isRunning());
+      assertTrue("wrong type", child.getModuleType().equals(ModuleType.EJB) || child.getModuleType().equals(ModuleType.WAR));
+      assertEquals("child have no child", child.getChildTargetModuleID().length, 0);
+
+      child = (TargetModuleIDImpl) parent.getChildTargetModuleID()[1];
+      assertTrue("wrong state", child.isRunning());
+      assertTrue("wrong type " + child.getModuleType(), child.getModuleType().equals(ModuleType.EJB) || child.getModuleType().equals(ModuleType.WAR));
+      assertEquals("child have no child", child.getChildTargetModuleID().length, 0);
+
+      parentProgress = manager.stop(new TargetModuleID[] { parent });
+      waitForCompletion(parentProgress.getDeploymentStatus());
+
+      modules = manager.getNonRunningModules(ModuleType.EAR, manager.getTargets());
+      assertNotNull(modules);
+      assertEquals("one EAR module in the server", modules.length, 1);
+
+      parent = (TargetModuleIDImpl) modules[0];
+      assertFalse("wrong state", parent.isRunning());
+      assertEquals("wrong type", parent.getModuleType(), ModuleType.EAR);
+      assertEquals("EAR module have a jar and a war", parent.getChildTargetModuleID().length, 2);
+
+      parentProgress = manager.start(new TargetModuleID[]{ parent });
+      waitForCompletion(parentProgress.getDeploymentStatus());
+
+      modules = manager.getRunningModules(ModuleType.EAR, manager.getTargets());
+      assertNotNull(modules);
+      assertEquals("one EAR module in the server", modules.length, 1);
+
+      parent = (TargetModuleIDImpl) modules[0];
+      assertTrue("wrong state", parent.isRunning());
+      assertEquals("wrong type", parent.getModuleType(), ModuleType.EAR);
+      assertEquals("EAR module have a jar and a war", parent.getChildTargetModuleID().length, 2);
+      parentProgress = manager.undeploy(new TargetModuleID[]{ parent });
+      waitForCompletion(parentProgress.getDeploymentStatus());
+
+      modules = manager.getAvailableModules(ModuleType.EAR, manager.getTargets());
+      assertNull("EAR must not be available", modules);
+
+      try
+      {
+         assertServletAccess("custom-context");
+         fail("Test deployment not undeployed");
+      }
+      catch (Exception e)
+      {
+         // ignore
+      }
+
+      try
+      {
+         assertEjbEchoAccess();
+         fail("Test deployment not undeployed");
+      }
+      catch (Exception e)
+      {
+         // ignore
+      }
+   }
+
+   /**
+    * Obtain a DeploymentManager using a deployURI of the form
+    * http://org.jboss.deployment/jsr88?targetType=targetType
+    * Valid targetType values are:
+    * jmx - Use the JMXTarget RMIAdaptor based deployment target
+    * remote - Use the StreamingTarget remoting based deployment target
+    * @return JSR88 DeploymentManager
+    * @throws Exception
+    */
+   protected DeploymentManager getDeploymentManager()
+      throws Exception
+   {
+      // Get the deployment manager and the distribution targets
+      String mgrURI = DeploymentManagerImpl.DEPLOYER_URI+"?targetType="+targetType;
+      DeploymentManager manager = factory.getDeploymentManager(mgrURI, null, null);
+      return manager;
+   }
+   private void jsr88Undeploy(TargetModuleID[] resultTargetModuleIDs) throws Exception
+   {
+      DeploymentManager manager = getDeploymentManager();
+      Target[] targets = manager.getTargets();
+      assertEquals(1, targets.length);
+
+      ProgressObject progress = manager.stop(resultTargetModuleIDs);
+      DeploymentStatus status = progress.getDeploymentStatus();
+      waitForCompletion(status);
+
+      // Check the webapp is undeployed
+      assertEquals(status.getMessage(), StateType.COMPLETED, status.getState());
+
+      progress = manager.undeploy(resultTargetModuleIDs);
+      status = progress.getDeploymentStatus();
+      waitForCompletion(status);
+      assertEquals(status.getMessage(), StateType.COMPLETED, status.getState());
+   }
+
+   private ProgressObject jsr88Deployment(String module)
+      throws Exception
+   {
+      // Get the deployment manager and the distribution targets
+      DeploymentManager manager = getDeploymentManager();
+      Target[] targets = manager.getTargets();
+      assertEquals(1, targets.length);
+
+      File deploymentPlan = createDeploymentPlan(module);
+
+      // Get a pointer to the plain web archive
+      log.debug("module=" + module);
+      File moduleArchive = new File(new URI(getDeployURL(module).toString()));
+      assertTrue(moduleArchive.exists());
+
+      // Deploy the test war
+      ProgressObject progress = manager.distribute(targets, moduleArchive, deploymentPlan);
+      DeploymentStatus status = progress.getDeploymentStatus();
+      waitForCompletion(status);
+
+      assertEquals(status.getMessage(), StateType.COMPLETED, status.getState());
+
+      TargetModuleID[] moduleIDs = progress.getResultTargetModuleIDs();
+      progress = manager.start(moduleIDs);
+      status = progress.getDeploymentStatus();
+      waitForCompletion(status);
+
+      return progress;
+   }
+
+   private void assertEjbEchoAccess() throws NamingException, RemoteException, CreateException
+   {
+      InitialContext initial = new InitialContext();
+      Object obj = initial.lookup("deployment/test/Echo");
+      EchoHome home = (EchoHome) PortableRemoteObject.narrow(obj, EchoHome.class);
+      Echo echo = home.create();
+
+      assertEquals("Wrong EJB return", "Hello!", echo.echo("Hello!"));
+   }
+
+   private void waitForCompletion(DeploymentStatus status) throws InterruptedException
+   {
+      // wait for the deployment to finish
+      while (StateType.RUNNING == status.getState())
+         Thread.sleep(100);
+   }
+
+   private void assertServletAccess(String context) throws IOException
+   {
+      // Check that we can access the servlet
+      URL servletURL = new URL("http://" + getServerHost() + ":8080/" + context);
+      BufferedReader br = new BufferedReader(new InputStreamReader(servletURL.openStream()));
+      String message = br.readLine();
+      assertEquals("Hello World!", message);
+   }
+
+   private File createDeploymentPlan(String deploymentFile) throws Exception
+   {
+      String[] strs = null;
+
+      // Create temp file for deployment plan
+      File deploymentPlan = File.createTempFile("deploymentplan", ".zip");
+      deploymentPlan.deleteOnExit();
+
+      String jbossFile = getJBossFile(deploymentFile);
+      String resourcedir = getResourceURL("deployment/" + jbossFile);
+      File jbossDescriptor = new File(new URI(resourcedir));
+      assertTrue(jbossDescriptor.exists());
+
+      JarOutputStream jos = new JarOutputStream(new FileOutputStream(deploymentPlan));
+      JarUtils.addJarEntry(jos, "!/" + jbossFile, new FileInputStream(jbossDescriptor));
+
+      // Setup deployment plan meta data with propriatary descriptor
+      DeploymentMetaData metaData = new DeploymentMetaData(deploymentFile);
+
+      strs = jbossFile.split("/");
+      metaData.addEntry(deploymentFile, strs[strs.length - 1]);
+
+      // Add the meta data to the deployment plan
+      String metaStr = metaData.toXMLString();
+
+      JarUtils.addJarEntry(jos, DeploymentMetaData.ENTRY_NAME, new ByteArrayInputStream(metaStr.getBytes()));
+      jos.flush();
+      jos.close();
+
+      return deploymentPlan;
+   }
+
+   private String getJBossFile(String deploymentFile)
+   {
+      if (deploymentFile.endsWith(".war"))
+         return WAR_JBOSS_FILE;
+      else if (deploymentFile.endsWith(".jar"))
+         return JAR_JBOSS_FILE;
+      else if (deploymentFile.endsWith(".ear"))
+         return EAR_JBOSS_FILE;
+      else
+         fail("Wrong J2EE Module found...");
+      throw new UnreachableStatementException();
+   }
+}

Deleted: trunk/testsuite/src/main/org/jboss/test/deployment/DeploymentTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/deployment/DeploymentTestCase.java	2006-12-06 20:50:08 UTC (rev 58880)
+++ trunk/testsuite/src/main/org/jboss/test/deployment/DeploymentTestCase.java	2006-12-06 21:01:09 UTC (rev 58881)
@@ -1,393 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.test.deployment;
-
-import org.jboss.deployment.spi.DeploymentManagerImpl;
-import org.jboss.deployment.spi.DeploymentMetaData;
-import org.jboss.deployment.spi.JarUtils;
-import org.jboss.deployment.spi.TargetModuleIDImpl;
-import org.jboss.test.JBossTestCase;
-import org.jboss.util.UnreachableStatementException;
-
-import javax.ejb.CreateException;
-import javax.enterprise.deploy.shared.ModuleType;
-import javax.enterprise.deploy.shared.StateType;
-import javax.enterprise.deploy.shared.factories.DeploymentFactoryManager;
-import javax.enterprise.deploy.spi.DeploymentManager;
-import javax.enterprise.deploy.spi.Target;
-import javax.enterprise.deploy.spi.TargetModuleID;
-import javax.enterprise.deploy.spi.factories.DeploymentFactory;
-import javax.enterprise.deploy.spi.status.DeploymentStatus;
-import javax.enterprise.deploy.spi.status.ProgressObject;
-import javax.naming.InitialContext;
-import javax.naming.NamingException;
-import javax.rmi.PortableRemoteObject;
-
-import java.io.BufferedReader;
-import java.io.ByteArrayInputStream;
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileOutputStream;
-import java.io.IOException;
-import java.io.InputStreamReader;
-import java.net.URI;
-import java.net.URL;
-import java.rmi.RemoteException;
-import java.util.jar.JarOutputStream;
-
-/** 
- * Deployment API JSR-88 tests
- *
- * @author Thomas.Diesler at jboss.org
- * @author Fabiano C. de Oliveira (JBAS-1995)
- * @version $Revision$
- */
-public class DeploymentTestCase extends JBossTestCase
-{
-   private static final String WAR_JBOSS_FILE = "WEB-INF/jboss-web.xml";
-
-   private static final String JAR_JBOSS_FILE = "META-INF/jboss.xml";
-
-   private static final String EAR_JBOSS_FILE = "META-INF/jboss-app.xml";
-
-   private DeploymentFactory factory;
-
-   public DeploymentTestCase(String name)
-   {
-      super(name);
-   }
-
-   /** Get the DeploymentManager
-    */
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-      DeploymentFactoryManager dfManager = DeploymentFactoryManager.getInstance();
-      DeploymentFactory[] factories = dfManager.getDeploymentFactories();
-      assertTrue("No DeploymentFactory available", factories.length > 0);
-      factory = factories[0];
-   }
-
-   /** Check DeploymentManager
-    */
-   public void testDeploymentManager() throws Exception
-   {
-      String uri = DeploymentManagerImpl.DEPLOYER_URI;
-      DeploymentManager manager = factory.getDeploymentManager(uri, null, null);
-      assertNotNull("No deployment manager", manager);
-
-      Target target = manager.getTargets()[0];
-      assertEquals("JBoss JMX deployment target", target.getDescription());
-   }
-
-   /** Distribute a web app
-    */
-   public void testDistributeWebApp() throws Exception
-   {
-      ProgressObject progress = jsr88Deployment("deployment-web.war");
-      try
-      {
-         assertServletAccess("custom-context");
-      }
-      finally
-      {
-         jsr88Undeploy(progress.getResultTargetModuleIDs());
-      }
-      try
-      {
-         assertServletAccess("custom-context");
-         fail("Test deployment not undeployed");
-      }
-      catch (IOException e)
-      {
-         // ignore
-      }
-   }
-
-   /** 
-    * Distribute a EJB app
-    */
-   public void testDistributeEjbApp() throws Exception
-   {
-      ProgressObject progress = jsr88Deployment("deployment-ejb.jar");
-      try
-      {
-          assertEjbEchoAccess();
-      }
-      finally
-      {
-          jsr88Undeploy(progress.getResultTargetModuleIDs());
-      }
-      try
-      {
-         assertEjbEchoAccess();
-         fail("Test deployment not undeployed");
-      }
-      catch (Exception e)
-      {
-         // ignore
-      }
-   }
-
-   public void testDistributeEARApp() throws Exception
-   {
-      ProgressObject progress = jsr88Deployment("deployment-ear.ear");
-      try
-      {
-         assertServletAccess("custom-context");
-         assertEjbEchoAccess();
-      }
-      finally
-      {
-         jsr88Undeploy(progress.getResultTargetModuleIDs());
-      }
-      try
-      {
-         assertServletAccess("custom-context");
-         fail("Test deployment not undeployed");
-      }
-      catch (Exception e)
-      {
-         // ignore
-      }
-
-      try
-      {
-         assertEjbEchoAccess();
-         fail("Test deployment not undeployed");
-      }
-      catch (Exception e)
-      {
-         // ignore
-      }
-   }
-
-   /**
-    * 
-    * @throws Exception
-    */ 
-   public void testListStartStopModules() throws Exception
-   {
-      TargetModuleIDImpl child = null;
-      TargetModuleIDImpl parent = null;
-
-      // Get the deployment manager and the distribution targets
-      DeploymentManager manager = factory.getDeploymentManager(DeploymentManagerImpl.DEPLOYER_URI, null, null);
-      Target[] targets = manager.getTargets();
-      assertEquals(1, targets.length);
-
-      TargetModuleID[] modules = manager.getRunningModules(ModuleType.EAR, manager.getTargets());
-      assertNull("no modules Available", modules);
-
-      ProgressObject parentProgress = jsr88Deployment("deployment-ear.ear");
-      assertServletAccess("custom-context");
-      assertEjbEchoAccess();
-
-      modules = manager.getRunningModules(ModuleType.EAR, manager.getTargets());
-      assertNotNull(modules);
-      assertEquals("one EAR module in the server", modules.length, 1);
-
-      parent = (TargetModuleIDImpl) modules[0];
-      assertTrue("wrong state", parent.isRunning());
-      assertEquals("wrong type", parent.getModuleType(), ModuleType.EAR);
-      assertEquals("EAR module have a jar and a war", parent.getChildTargetModuleID().length, 2);
-
-      child = (TargetModuleIDImpl) parent.getChildTargetModuleID()[0];
-      assertTrue("wrong state", child.isRunning());
-      assertTrue("wrong type", child.getModuleType().equals(ModuleType.EJB) || child.getModuleType().equals(ModuleType.WAR));
-      assertEquals("child have no child", child.getChildTargetModuleID().length, 0);
-
-      child = (TargetModuleIDImpl) parent.getChildTargetModuleID()[1];
-      assertTrue("wrong state", child.isRunning());
-      assertTrue("wrong type " + child.getModuleType(), child.getModuleType().equals(ModuleType.EJB) || child.getModuleType().equals(ModuleType.WAR));
-      assertEquals("child have no child", child.getChildTargetModuleID().length, 0);
-
-      parentProgress = manager.stop(new TargetModuleID[] { parent });
-      waitForCompletion(parentProgress.getDeploymentStatus());
-
-      modules = manager.getNonRunningModules(ModuleType.EAR, manager.getTargets());
-      assertNotNull(modules);
-      assertEquals("one EAR module in the server", modules.length, 1);
-
-      parent = (TargetModuleIDImpl) modules[0];
-      assertFalse("wrong state", parent.isRunning());
-      assertEquals("wrong type", parent.getModuleType(), ModuleType.EAR);
-      assertEquals("EAR module have a jar and a war", parent.getChildTargetModuleID().length, 2);
-
-      parentProgress = manager.start(new TargetModuleID[]{ parent });
-      waitForCompletion(parentProgress.getDeploymentStatus());
-
-      modules = manager.getRunningModules(ModuleType.EAR, manager.getTargets());
-      assertNotNull(modules);
-      assertEquals("one EAR module in the server", modules.length, 1);
-
-      parent = (TargetModuleIDImpl) modules[0];
-      assertTrue("wrong state", parent.isRunning());
-      assertEquals("wrong type", parent.getModuleType(), ModuleType.EAR);
-      assertEquals("EAR module have a jar and a war", parent.getChildTargetModuleID().length, 2);
-      parentProgress = manager.undeploy(new TargetModuleID[]{ parent });
-      waitForCompletion(parentProgress.getDeploymentStatus());
-
-      modules = manager.getAvailableModules(ModuleType.EAR, manager.getTargets());
-      assertNull("EAR must not be available", modules);
-
-      try
-      {
-         assertServletAccess("custom-context");
-         fail("Test deployment not undeployed");
-      }
-      catch (Exception e)
-      {
-         // ignore
-      }
-
-      try
-      {
-         assertEjbEchoAccess();
-         fail("Test deployment not undeployed");
-      }
-      catch (Exception e)
-      {
-         // ignore
-      }
-   }
-
-   private void jsr88Undeploy(TargetModuleID[] resultTargetModuleIDs) throws Exception
-   {
-      // Get the deployment manager and the distribution targets
-      DeploymentManager manager = factory.getDeploymentManager(DeploymentManagerImpl.DEPLOYER_URI, null, null);
-      Target[] targets = manager.getTargets();
-      assertEquals(1, targets.length);
-
-      ProgressObject progress = manager.stop(resultTargetModuleIDs);
-      DeploymentStatus status = progress.getDeploymentStatus();
-      waitForCompletion(status);
-
-      // Check the webapp is undeployed
-      assertEquals(status.getMessage(), StateType.COMPLETED, status.getState());
-
-      progress = manager.undeploy(resultTargetModuleIDs);
-      status = progress.getDeploymentStatus();
-      waitForCompletion(status);
-      assertEquals(status.getMessage(), StateType.COMPLETED, status.getState());
-   }
-
-   private ProgressObject jsr88Deployment(String module) throws Exception
-   {
-      // Get the deployment manager and the distribution targets
-      DeploymentManager manager = factory.getDeploymentManager(DeploymentManagerImpl.DEPLOYER_URI, null, null);
-      Target[] targets = manager.getTargets();
-      assertEquals(1, targets.length);
-
-      File deploymentPlan = createDeploymentPlan(module);
-
-      // Get a pointer to the plain web archive
-      log.debug("module=" + module);
-      File moduleArchive = new File(new URI(getDeployURL(module).toString()));
-      assertTrue(moduleArchive.exists());
-
-      // Deploy the test war
-      ProgressObject progress = manager.distribute(targets, moduleArchive, deploymentPlan);
-      DeploymentStatus status = progress.getDeploymentStatus();
-      waitForCompletion(status);
-
-      assertEquals(status.getMessage(), StateType.COMPLETED, status.getState());
-
-      TargetModuleID[] moduleIDs = progress.getResultTargetModuleIDs();
-      progress = manager.start(moduleIDs);
-      status = progress.getDeploymentStatus();
-      waitForCompletion(status);
-
-      return progress;
-   }
-
-   private void assertEjbEchoAccess() throws NamingException, RemoteException, CreateException
-   {
-      InitialContext initial = new InitialContext();
-      Object obj = initial.lookup("deployment/test/Echo");
-      EchoHome home = (EchoHome) PortableRemoteObject.narrow(obj, EchoHome.class);
-      Echo echo = home.create();
-
-      assertEquals("Wrong EJB return", "Hello!", echo.echo("Hello!"));
-   }
-
-   private void waitForCompletion(DeploymentStatus status) throws InterruptedException
-   {
-      // wait for the deployment to finish
-      while (StateType.RUNNING == status.getState())
-         Thread.sleep(100);
-   }
-
-   private void assertServletAccess(String context) throws IOException
-   {
-      // Check that we can access the servlet
-      URL servletURL = new URL("http://" + getServerHost() + ":8080/" + context);
-      BufferedReader br = new BufferedReader(new InputStreamReader(servletURL.openStream()));
-      String message = br.readLine();
-      assertEquals("Hello World!", message);
-   }
-
-   private File createDeploymentPlan(String deploymentFile) throws Exception
-   {
-      String[] strs = null;
-
-      // Create temp file for deployment plan
-      File deploymentPlan = File.createTempFile("deploymentplan", ".zip");
-      deploymentPlan.deleteOnExit();
-
-      String jbossFile = getJBossFile(deploymentFile);
-      String resourcedir = getResourceURL("deployment/" + jbossFile);
-      File jbossDescriptor = new File(new URI(resourcedir));
-      assertTrue(jbossDescriptor.exists());
-
-      JarOutputStream jos = new JarOutputStream(new FileOutputStream(deploymentPlan));
-      JarUtils.addJarEntry(jos, "!/" + jbossFile, new FileInputStream(jbossDescriptor));
-
-      // Setup deployment plan meta data with propriatary descriptor
-      DeploymentMetaData metaData = new DeploymentMetaData(deploymentFile);
-
-      strs = jbossFile.split("/");
-      metaData.addEntry(deploymentFile, strs[strs.length - 1]);
-
-      // Add the meta data to the deployment plan
-      String metaStr = metaData.toXMLString();
-
-      JarUtils.addJarEntry(jos, DeploymentMetaData.ENTRY_NAME, new ByteArrayInputStream(metaStr.getBytes()));
-      jos.flush();
-      jos.close();
-
-      return deploymentPlan;
-   }
-
-   private String getJBossFile(String deploymentFile)
-   {
-      if (deploymentFile.endsWith(".war"))
-         return WAR_JBOSS_FILE;
-      else if (deploymentFile.endsWith(".jar"))
-         return JAR_JBOSS_FILE;
-      else if (deploymentFile.endsWith(".ear"))
-         return EAR_JBOSS_FILE;
-      else
-         fail("Wrong J2EE Module found...");
-      throw new UnreachableStatementException();
-   }
-}

Added: trunk/testsuite/src/main/org/jboss/test/deployment/JMXDeploymentTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/deployment/JMXDeploymentTestCase.java	2006-12-06 20:50:08 UTC (rev 58880)
+++ trunk/testsuite/src/main/org/jboss/test/deployment/JMXDeploymentTestCase.java	2006-12-06 21:01:09 UTC (rev 58881)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.test.deployment;
+
+import org.jboss.deployment.spi.JMXTarget;
+
+/**
+ * JSR88 deployment tests using the JMXTarget, targetType=jmx
+ * javax.enterprise.deploy.spi.Target implemention.
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class JMXDeploymentTestCase extends BaseDeploymentTestCase
+{
+   public JMXDeploymentTestCase(String name)
+   {
+      super(name, "jmx");
+   }
+
+   protected String getTargetDescription()
+   {
+      return JMXTarget.DESCRIPTION;
+   }
+
+}

Added: trunk/testsuite/src/main/org/jboss/test/deployment/StreamingDeploymentTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/deployment/StreamingDeploymentTestCase.java	2006-12-06 20:50:08 UTC (rev 58880)
+++ trunk/testsuite/src/main/org/jboss/test/deployment/StreamingDeploymentTestCase.java	2006-12-06 21:01:09 UTC (rev 58881)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.test.deployment;
+
+import org.jboss.deployment.remoting.StreamingTarget;
+
+/**
+ * JSR88 deployment tests using the StreamingTarget, targetType=remote
+ * javax.enterprise.deploy.spi.Target implemention.
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class StreamingDeploymentTestCase extends BaseDeploymentTestCase
+{
+   public StreamingDeploymentTestCase(String name)
+   {
+      super(name, "remote");
+   }
+
+   protected String getTargetDescription()
+   {
+      return StreamingTarget.DESCRIPTION;
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 16:03:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 16:03:10 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58882 - trunk/testsuite
Message-ID: <E1Gs3v4-0000bp-EA@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-06 16:03:08 -0500 (Wed, 06 Dec 2006)
New Revision: 58882

Modified:
   trunk/testsuite/.classpath
Log:
Update sources paths for thirdparty elements

Modified: trunk/testsuite/.classpath
===================================================================
--- trunk/testsuite/.classpath	2006-12-06 21:01:09 UTC (rev 58881)
+++ trunk/testsuite/.classpath	2006-12-06 21:03:08 UTC (rev 58882)
@@ -16,7 +16,7 @@
 	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/apache-httpclient/lib/commons-httpclient.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar" sourcepath="/thirdparty/junit/lib/junit-src.zip"/>
 	<classpathentry kind="lib" path="/thirdparty/junitejb/lib/junitejb.jar"/>
 	<classpathentry kind="lib" path="/tools/lib/ant.jar"/>
 	<classpathentry kind="src" path="/aspects"/>
@@ -36,7 +36,7 @@
 	<classpathentry kind="src" path="/jmx"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/deployment"/>
 	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/remoting/lib/jboss-remoting.jar" sourcepath="/thirdparty/jboss/remoting/lib/jboss-remoting-src.zip"/>
 	<classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/xercesImpl.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/xmlunit-xmlunit/lib/xmlunit1.0.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/hibernate-int"/>



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 16:08:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 16:08:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r58883 -
	branches/Branch_4_2/connector/src/etc/example-config
Message-ID: <E1Gs404-0000hm-78@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-06 16:08:19 -0500 (Wed, 06 Dec 2006)
New Revision: 58883

Added:
   branches/Branch_4_2/connector/src/etc/example-config/db2-jcc-xa-ds.xml
Log:
Adding db2-jcc-xa-ds.xml file for IBM Type4 XA JDBC driver.

Added: branches/Branch_4_2/connector/src/etc/example-config/db2-jcc-xa-ds.xml
===================================================================
--- branches/Branch_4_2/connector/src/etc/example-config/db2-jcc-xa-ds.xml	2006-12-06 21:03:08 UTC (rev 58882)
+++ branches/Branch_4_2/connector/src/etc/example-config/db2-jcc-xa-ds.xml	2006-12-06 21:08:19 UTC (rev 58883)
@@ -0,0 +1,32 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<datasources>
+    <!--
+        IBM DB2 XA driver
+        db2jcc.jar
+    -->
+    
+    <xa-datasource>
+        <jndi-name>DB2XADS</jndi-name>
+       
+        <xa-datasource-class>com.ibm.db2.jcc.DB2XADataSource</xa-datasource-class>
+        
+        <xa-datasource-property name="DatabaseName">your_database_name</xa-datasource-property>
+        <xa-datasource-property name="User">your_user</xa-datasource-property>
+        <xa-datasource-property name="Password">your_password</xa-datasource-property>
+        
+        <!-- Note, as opposed to the Type2 driver, DB2 Type 4 requires the PortNumber. By default this is 50000-->
+        <xa-datasource-property name="PortNumber">your_port_number</xa-datasource-property>
+        
+        <!-- Must be set if using multiple DB2 XA resources in same transaction -->
+        
+        <isSameRM-override-value>false</isSameRM-override-value>    
+        
+        <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
+        <metadata>
+            <type-mapping>DB2</type-mapping>
+        </metadata>
+    
+    </xa-datasource>
+    
+</datasources>
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 16:10:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 16:10:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r58884 -
	branches/Branch_4_2/connector/src/etc/example-config
Message-ID: <E1Gs42B-0000kA-7r@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-06 16:10:30 -0500 (Wed, 06 Dec 2006)
New Revision: 58884

Modified:
   branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml
Log:
Updating DB2 XA configuration to address isSameRM override value in the same manner as Oracle.

Modified: branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml
===================================================================
--- branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml	2006-12-06 21:08:19 UTC (rev 58883)
+++ branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml	2006-12-06 21:10:30 UTC (rev 58884)
@@ -23,6 +23,10 @@
      <xa-datasource-property name="User">your_user</xa-datasource-property>
      <xa-datasource-property name="Password">your_password</xa-datasource-property>
 
+      <!-- Must be set if using multiple DB2 XA resources in same transaction -->
+      
+      <isSameRM-override-value>false</isSameRM-override-value>    
+      
       <!-- corresponding type-mapping in the standardjbosscmp-jdbc.xml (optional) -->
       <metadata>
          <type-mapping>DB2</type-mapping>



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 16:15:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 16:15:39 -0500
Subject: [jboss-cvs] JBossAS SVN: r58885 -
	branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server
Message-ID: <E1Gs479-0000r3-Dw@committer01.frg.pub.inap.atl.jboss.com>

Author: jerrygauth
Date: 2006-12-06 16:15:38 -0500 (Wed, 06 Dec 2006)
New Revision: 58885

Modified:
   branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/HAPartitionImpl.java
Log:
Modified to allow suppression of partition JNDI registration; prerequisite for JBAS-2470

Modified: branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/HAPartitionImpl.java
===================================================================
--- branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/HAPartitionImpl.java	2006-12-06 21:10:30 UTC (rev 58884)
+++ branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/HAPartitionImpl.java	2006-12-06 21:15:38 UTC (rev 58885)
@@ -129,6 +129,8 @@
    protected MBeanServer server;
    /** Number of ms to wait for state */
    protected long state_transfer_timeout=60000;
+   /** Whether to bind the partition into JNDI */
+   protected boolean bindIntoJndi = true;
 
    /**
     * True if state was initialized during start-up.
@@ -287,7 +289,10 @@
       // Start the asynch listener handler thread
       asynchHandler.start();
       
-      // Bind ourself in the public JNDI space
+      // Bind ourself in the public JNDI space if configured to do so
+      if (!bindIntoJndi)
+    	  return;
+      
       Context ctx = new InitialContext();
       this.bind("/HAPartition/" + partitionName, this, HAPartitionImpl.class, ctx);
    }
@@ -400,20 +405,21 @@
          log.error("operation failed", e);
       }
 
-      String boundName = "/HAPartition/" + partitionName;
-
-      InitialContext ctx = new InitialContext();
-      try
+      if (bindIntoJndi)
       {
-
-         ctx.unbind(boundName);
+         String boundName = "/HAPartition/" + partitionName;
+         InitialContext ctx = new InitialContext();
+         try
+         {
+            ctx.unbind(boundName);
+         }
+         finally
+         {
+            ctx.close();
+         }
+         NonSerializableFactory.unbind (boundName);    	  
       }
-      finally
-      {
-         ctx.close();
-      }
-      NonSerializableFactory.unbind (boundName);
-
+      
       log.info("Partition " + partitionName + " closed.");
    }
 
@@ -1272,7 +1278,28 @@
       }
       log.debug("End notifyListeners, viewID: "+viewID);
    }
-
+   
+   /*
+    * Allows caller to specify whether the partition instance should be bound into JNDI.  Default value is true.
+    * This method must be called before the partition is started as the binding occurs during startup.
+    * 
+    * @param bind  Whether to bind the partition into JNDI.
+    */
+   public void setBindIntoJndi(boolean bind)
+   {
+	   bindIntoJndi = bind;
+   }
+   
+   /*
+    * Allows caller to determine whether the partition instance has been bound into JNDI.
+    * 
+    * @return true if the partition has been bound into JNDI.
+    */
+   public boolean getBindIntoJndi()
+   {
+	   return bindIntoJndi;
+   }
+   
    protected Vector translateAddresses (Vector jgAddresses)
    {
       if (jgAddresses == null)



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 16:19:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 16:19:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r58886 -
	branches/Branch_4_2/connector/src/etc/example-config
Message-ID: <E1Gs4AX-0000v2-MC@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-06 16:19:08 -0500 (Wed, 06 Dec 2006)
New Revision: 58886

Modified:
   branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml
Log:
Fixed typo.

Modified: branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml
===================================================================
--- branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml	2006-12-06 21:15:38 UTC (rev 58885)
+++ branches/Branch_4_2/connector/src/etc/example-config/db2-xa-ds.xml	2006-12-06 21:19:08 UTC (rev 58886)
@@ -19,7 +19,7 @@
      <jndi-name>DB2XADS</jndi-name>
 
      <xa-datasource-class>COM.ibm.db2.jdbc.DB2XADataSource</xa-datasource-class>
-     <xa-datasource-property name="DatabaseName">yout_database_name</xa-datasource-property>
+     <xa-datasource-property name="DatabaseName">your_database_name</xa-datasource-property>
      <xa-datasource-property name="User">your_user</xa-datasource-property>
      <xa-datasource-property name="Password">your_password</xa-datasource-property>
 



From c49 at fullmailmarket.com  Wed Dec  6 17:12:10 2006
From: c49 at fullmailmarket.com (Respaldo de Datos)
Date: Wed, 6 Dec 2006 19:12:10 -0300
Subject: [jboss-cvs] RESPALDO EN LINEA, REMOTO, SIMPLE, EFICIENTE Y SEGURO,
	PARA WINDOWS, LINUX Y MAC,
	OTRO SERVICIO DE HOSTEX.CL -- SIEMPRE INNOVANDO
Message-ID: <200612062212.kB6MCCKH015816@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061206/0116297d/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 17:37:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 17:37:56 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1713 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/server/connectionfactory
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gs5Om-0002Jj-HE@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-06 17:37:53 -0500 (Wed, 06 Dec 2006)
New Revision: 1713

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Adding tracing for debug

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-06 11:43:33 UTC (rev 1712)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-06 22:37:53 UTC (rev 1713)
@@ -182,6 +182,9 @@
          }
       }
 
+      log.trace("Removing delegate from delegates list with key=" + uniqueName + " at serverPeerID=" +
+                  this.serverPeer.getServerPeerID());
+
       ClientConnectionFactoryDelegate delegate =
          (ClientConnectionFactoryDelegate)delegates.remove(uniqueName);
       
@@ -245,7 +248,7 @@
    
    public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap)
    {
-      log.info("Got replication call " + key + " replicants=" + updatedReplicantMap);
+      log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap);
       try
       {
          // The list of connection factories across the cluster has changed, so we need to update
@@ -339,6 +342,8 @@
          int nodeID = ((Integer)entry.getKey()).intValue();
          int failoverNodeID = replicator.getFailoverNodeID(nodeID);
 
+         log.trace("setFailoverDelegates inside forIterator::nodeID=" + nodeID + " failoverNodeID=" + failoverNodeID);
+
          nodesIDs[idx] = nodeID;
          failoverNodeIDs[idx] = failoverNodeID;
          delegates[idx] = (ClientConnectionFactoryDelegate)entry.getValue();
@@ -366,7 +371,7 @@
          
          if (failoverIndex == -1)
          {
-            throw new IllegalStateException("Failover node is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
+            throw new IllegalStateException("Failover node " + failoverNode + " is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
          }
          
          failoverIndexes[i] = failoverIndex;

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-06 11:43:33 UTC (rev 1712)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-06 22:37:53 UTC (rev 1713)
@@ -81,6 +81,13 @@
    {
       super.setUp();
 
+      String banner =
+         "####################################################### Start " +
+         (isRemote() ? "REMOTE" : "IN-VM") + " test: " + getName();
+
+      ServerManagement.log(ServerManagement.INFO,banner);
+
+
       try
       {
          startServer(0);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-06 11:43:33 UTC (rev 1712)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-06 22:37:53 UTC (rev 1713)
@@ -70,6 +70,8 @@
          ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
          ServerManagement.stop(2,true);
 
+         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
+
          factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
          delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 17:52:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 17:52:22 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58887 - tags
Message-ID: <E1Gs5ck-0002VL-AD@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 17:52:22 -0500 (Wed, 06 Dec 2006)
New Revision: 58887

Removed:
   tags/JBoss_4_0_4_GA_CP03/
Log:
wrong version info - additional dot



From michael.yuan at jboss.com  Wed Dec  6 17:53:06 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 06 Dec 2006 17:53:06 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/nbproject   ...
Message-ID: <E1Gs5dS-0002Vn-AS@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/06 17:53:06

  Modified:    seam-gen/nbproject   debug-jboss.properties project.xml
  Log:
  netbeans improvement
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/seam-gen/nbproject/debug-jboss.properties
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: debug-jboss.properties
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/nbproject/debug-jboss.properties,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- debug-jboss.properties	6 Dec 2006 06:55:40 -0000	1.1
  +++ debug-jboss.properties	6 Dec 2006 22:53:06 -0000	1.2
  @@ -1,5 +1,5 @@
   # JBoss server related settings
   # Edit the following parameter according to your JBoss configuration
   jpda.host=localhost
  -jpda.address=4142
  +jpda.address=8787
   jpda.transport=dt_socket
  
  
  
  1.6       +4 -8      jboss-seam/seam-gen/nbproject/project.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: project.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/nbproject/project.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- project.xml	6 Dec 2006 18:15:08 -0000	1.5
  +++ project.xml	6 Dec 2006 22:53:06 -0000	1.6
  @@ -18,18 +18,15 @@
                       <target>clean</target>
                       <target>unexplode</target>
                   </action>
  -                <action name="Build">
  +                <action name="build">
                       <target>archive</target>
                   </action>
  -                <action name="Deploy">
  -                    <target>explode</target>
  +                <action name="redeploy">
  +                    <target>restart</target>
                   </action>
                   <action name="Undeploy">
                       <target>unexplode</target>
                   </action>
  -                <action name="redeploy">
  -                    <target>restart</target>
  -                </action>
                   <action name="test">
                       <target>test</target>
                   </action>
  @@ -58,8 +55,7 @@
                   </items>
                   <context-menu>
                       <ide-action name="clean"/>
  -                    <ide-action name="Build"/>
  -                    <ide-action name="Deploy"/>
  +                    <ide-action name="build"/>
                       <ide-action name="redeploy"/>
                       <ide-action name="Undeploy"/>
                       <ide-action name="debug"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 18:04:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 18:04:15 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58888 - tags
Message-ID: <E1Gs5oF-0002qE-WD@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 18:04:15 -0500 (Wed, 06 Dec 2006)
New Revision: 58888

Added:
   tags/JBoss_4_0_4_GA_CP_03/
Log:
restored CP03

Copied: tags/JBoss_4_0_4_GA_CP_03 (from rev 58833, branches/JBoss_4_0_4_GA_CP)



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 18:08:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 18:08:37 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58889 - tags
Message-ID: <E1Gs5sT-0002v9-LP@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 18:08:37 -0500 (Wed, 06 Dec 2006)
New Revision: 58889

Removed:
   tags/JBoss_4_0_4_GA_CP_03/
Log:
wrong name - additional _



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 18:08:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 18:08:54 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58890 - tags
Message-ID: <E1Gs5sk-0002vX-LG@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-06 18:08:54 -0500 (Wed, 06 Dec 2006)
New Revision: 58890

Added:
   tags/JBoss_4_0_4_GA_CP03/
Log:
restored CP03

Copied: tags/JBoss_4_0_4_GA_CP03 (from rev 58833, branches/JBoss_4_0_4_GA_CP)



From rajesh.rajasekaran at jboss.com  Wed Dec  6 19:15:57 2006
From: rajesh.rajasekaran at jboss.com (Rajesh Rajasekaran)
Date: Wed, 06 Dec 2006 19:15:57 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.3.0.SP4 - New
	directory ...
Message-ID: <E1Gs6vd-0003vm-Lx@committer01.frg.pub.inap.atl.jboss.com>

  User: rrajasekaran
  Date: 06/12/06 19:15:57

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/cache/1.3.0.SP4 added to the repository


From rajesh.rajasekaran at jboss.com  Wed Dec  6 19:16:11 2006
From: rajesh.rajasekaran at jboss.com (Rajesh Rajasekaran)
Date: Wed, 06 Dec 2006 19:16:11 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.3.0.SP4/lib - New
	directory ...
Message-ID: <E1Gs6vr-0003wD-5S@committer01.frg.pub.inap.atl.jboss.com>

  User: rrajasekaran
  Date: 06/12/06 19:16:11

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/cache/1.3.0.SP4/lib added to the repository


From rajesh.rajasekaran at jboss.com  Wed Dec  6 19:17:16 2006
From: rajesh.rajasekaran at jboss.com (Rajesh Rajasekaran)
Date: Wed, 06 Dec 2006 19:17:16 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.3.0.SP4   ...
Message-ID: <E1Gs6wu-0003ze-Uu@committer01.frg.pub.inap.atl.jboss.com>

  User: rrajasekaran
  Date: 06/12/06 19:17:16

  Added:       jboss/cache/1.3.0.SP4   README.txt component-info.xml
  Log:
  JBossCache 1.3.0.SP4
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 00:17:16;  author: rrajasekaran;  state: Exp;repository.jboss.com/jboss/cache/1.3.0.SP4/README.txt
  
  Index: README.txt
  ===================================================================
  
  $Id: README.txt,v 1.1 2006/12/07 00:17:16 rrajasekaran Exp $
  
  NAME:    JBossCache
  VERSION: 1.3.0.SP4
  PROJECT: http://www.jboss.com/products/jbosscache
  PURPOSE: Used by Clustering in JBossAS, HTTP session replication
  
  
  
  
  1.1      date: 2006/12/07 00:17:16;  author: rrajasekaran;  state: Exp;repository.jboss.com/jboss/cache/1.3.0.SP4/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-cache-component-info">
  
     <!-- ============================================================ -->
     <!-- jboss/cache                                                      -->
     <!-- ============================================================ -->
  
     <component id="jboss/cache"
                version="1.3.0.SP4"
                licenseType="lgpl"
                projectHome="http://www.jboss.org/products/jbosscache"
                description="JBoss Cache is a product designed to cache 
                frequently accessed Java objects in order to dramatically improve 
                the performance of e-business applications."
     >
        <artifact id="jboss-cache.jar"/>
        <artifact id="jboss-cache-jdk50.jar"/>
        <export>
           <include input="jboss-cache.jar"/>
           <include input="jboss-cache-jdk50.jar"/>
        </export>
     </component>
  </project>
  
  


From rajesh.rajasekaran at jboss.com  Wed Dec  6 19:17:17 2006
From: rajesh.rajasekaran at jboss.com (Rajesh Rajasekaran)
Date: Wed, 06 Dec 2006 19:17:17 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.3.0.SP4/lib   ...
Message-ID: <E1Gs6wv-0003zm-1u@committer01.frg.pub.inap.atl.jboss.com>

  User: rrajasekaran
  Date: 06/12/06 19:17:17

  Added:       jboss/cache/1.3.0.SP4/lib   jboss-cache-jdk50.jar
                        jboss-cache.jar
  Log:
  JBossCache 1.3.0.SP4
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 00:17:17;  author: rrajasekaran;  state: Exp;repository.jboss.com/jboss/cache/1.3.0.SP4/lib/jboss-cache-jdk50.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/07 00:17:17;  author: rrajasekaran;  state: Exp;repository.jboss.com/jboss/cache/1.3.0.SP4/lib/jboss-cache.jar
  
  	<<Binary file>>
  
  


From norman.richards at jboss.com  Wed Dec  6 19:19:15 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:19:15 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF    ...
Message-ID: <E1Gs6yp-00040R-5c@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:19:15

  Modified:    src/ui/META-INF    faces-config.xml seam.taglib.xml
                        taglib.tld
  Log:
  JBSEAM-556: add s:selectDate
  
  Revision  Changes    Path
  1.22      +10 -0     jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- faces-config.xml	5 Dec 2006 13:13:13 -0000	1.21
  +++ faces-config.xml	7 Dec 2006 00:19:15 -0000	1.22
  @@ -441,6 +441,16 @@
           </property>
       </component>
   
  +    <component>
  +        <component-type>org.jboss.seam.ui.SelectDate</component-type>
  +        <component-class>org.jboss.seam.ui.SelectDate</component-class>
  +        <property>
  +            <property-name>for</property-name>
  +            <property-class>java.lang.String</property-class>
  +        </property>
  +    </component>
  +
  +
       <validator>
           <validator-id>org.jboss.seam.ui.ModelValidator</validator-id>
           <validator-class>org.jboss.seam.ui.ModelValidator</validator-class>
  
  
  
  1.19      +8 -1      jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- seam.taglib.xml	5 Dec 2006 13:13:13 -0000	1.18
  +++ seam.taglib.xml	7 Dec 2006 00:19:15 -0000	1.19
  @@ -98,6 +98,13 @@
       </tag>
       
       <tag>
  +        <tag-name>selectDate</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.ui.SelectDate</component-type>
  +        </component>
  +    </tag>
  +    
  +    <tag>
           <tag-name>validate</tag-name>
           <validator>
               <validator-id>org.jboss.seam.ui.ModelValidator</validator-id>
  
  
  
  1.23      +14 -1     jboss-seam/src/ui/META-INF/taglib.tld
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: taglib.tld
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/taglib.tld,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- taglib.tld	5 Dec 2006 13:13:13 -0000	1.22
  +++ taglib.tld	7 Dec 2006 00:19:15 -0000	1.23
  @@ -867,6 +867,18 @@
     </tag>
   
     <tag>
  +    <name>selectDate</name>
  +    <tag-class>org.jboss.seam.ui.tag.SelectDateTag</tag-class>
  +    <body-content>JSP</body-content>
  +    <attribute>
  +      <name>for</name>
  +      <required>true</required>
  +      <rtexprvalue>false</rtexprvalue>
  +      <description>the field identifier of the input item to pick a date for</description>
  +    </attribute>
  +  </tag>
  +
  +  <tag>
       <name>convertDateTime</name>
       <tag-class>org.jboss.seam.ui.tag.ConvertDateTimeTag</tag-class>
       <body-content>empty</body-content>
  @@ -908,4 +920,5 @@
       </attribute>
     </tag>
   
  +
   </taglib>
  \ No newline at end of file
  
  
  


From norman.richards at jboss.com  Wed Dec  6 19:19:15 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:19:15 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1Gs6yp-00040b-9V@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:19:15

  Added:       src/ui/org/jboss/seam/ui   SelectDate.java selectDate.js
  Log:
  JBSEAM-556: add s:selectDate
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 00:19:15;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java
  
  Index: SelectDate.java
  ===================================================================
  package org.jboss.seam.ui;
  
  import java.io.*;
  import java.util.*;
  
  import javax.faces.application.*;
  import javax.faces.component.*;
  import javax.faces.context.*;
  import javax.faces.el.ValueBinding;
  
  public class SelectDate 
      extends UIComponentBase
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.ui.SelectDate";
      public static final String COMPONENT_FAMILY = "org.jboss.seam.ui.SelectDate";
      
      public static final String SELECTDATE_JS    = "org/jboss/seam/ui/selectDate.js";
  
      private String info;
      private String forField;
      
      
      public String getFor()
      {
          return forField;
      }
      
      public void setFor(String forField)
      {
          this.forField = forField;
      }    
  
      
      public String getInfo()
      {
          return info;
      }
      
      public void setInfo(String info)
      {
          this.info = info;
      }    
  
      @Override
      public String getFamily()
      {
          return COMPONENT_FAMILY;
      }
      
      @Override
      public boolean getRendersChildren() {
          return false;
      }
  
  
     @Override
     public void restoreState(FacesContext context, Object state) {
        Object[] values = (Object[]) state;
        super.restoreState(context, values[0]);
        info = (String) values[1];
        forField = (String) values[2];
     }
  
     @Override
     public Object saveState(FacesContext context) {
        Object[] values = new Object[3];
        values[0] = super.saveState(context);
        values[1] = info;
        values[2] = forField;
        return values;
     }
      
      @Override
      public void encodeBegin(FacesContext context) throws IOException
      {
          UIComponent forComponent = findComponent(forField);
  
          writeScript(context, SELECTDATE_JS);
          ResponseWriter response = context.getResponseWriter();
          response.startElement("span", this);
          response.writeAttribute("onclick", 
                                  "displayDatePicker('" + forComponent.getClientId(context) + "');", 
                                  null);
      }
  
      @Override
      public void encodeEnd(FacesContext context) throws IOException
      {
          ResponseWriter response = context.getResponseWriter();
          response.endElement("span");
          response.flush();
          super.encodeEnd(context);
      }
  
  
      public void writeScript(FacesContext context,
                              String scriptResource) 
          throws IOException
      {
          Map request = context.getExternalContext().getRequestMap();
          if (request.get("SELECTDATE_SCRIPT") != null) {
              // already written out
              return;
          }
              
          request.put("SELECTDATE_SCRIPT", scriptResource);
          
          ViewHandler handler = context.getApplication().getViewHandler();
  
          ResponseWriter response = context.getResponseWriter();
          response.startElement("script", null);
          response.writeAttribute("type", "text/javascript", null);
          InputStream is = this.getClass().getClassLoader().getResourceAsStream(scriptResource);
  
          if (is == null) {
              throw new IOException("resource " + scriptResource + " not found");
          }
  
          try {
              InputStreamReader reader = new InputStreamReader(is);
              char[] buf = new char[512];
              int nread; 
              while ((nread = reader.read(buf,0,512))!= -1) {
                  response.write(buf, 0, nread);
              }
          } finally {
              is.close();
          }
  
          response.endElement("script");
      }
                              
  }
  
  
  
  1.1      date: 2006/12/07 00:19:15;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/selectDate.js
  
  Index: selectDate.js
  ===================================================================
  /**
  This is a JavaScript library that will allow you to easily add some basic DHTML
  drop-down datepicker functionality to your Notes forms. This script is not as
  full-featured as others you may find on the Internet, but it's free, it's easy to
  understand, and it's easy to change.
  
  You'll also want to include a stylesheet that makes the datepicker elements
  look nice. An example one can be found in the database that this script was
  originally released with, at:
  
  http://www.nsftools.com/tips/NotesTips.htm#datepicker
  
  I've tested this lightly with Internet Explorer 6 and Mozilla Firefox. I have no idea
  how compatible it is with other browsers.
  
  version 1.5
  December 4, 2005
  Julian Robichaux -- http://www.nsftools.com
  
  HISTORY
  --  version 1.0 (Sept. 4, 2004):
  Initial release.
  
  --  version 1.1 (Sept. 5, 2004):
  Added capability to define the date format to be used, either globally (using the
  defaultDateSeparator and defaultDateFormat variables) or when the displayDatePicker
  function is called.
  
  --  version 1.2 (Sept. 7, 2004):
  Fixed problem where datepicker x-y coordinates weren't right inside of a table.
  Fixed problem where datepicker wouldn't display over selection lists on a page.
  Added a call to the datePickerClosed function (if one exists) after the datepicker
  is closed, to allow the developer to add their own custom validation after a date
  has been chosen. For this to work, you must have a function called datePickerClosed
  somewhere on the page, that accepts a field object as a parameter. See the
  example in the comments of the updateDateField function for more details.
  
  --  version 1.3 (Sept. 9, 2004)
  Fixed problem where adding the <div> and <iFrame> used for displaying the datepicker
  was causing problems on IE 6 with global variables that had handles to objects on
  the page (I fixed the problem by adding the elements using document.createElement()
  and document.body.appendChild() instead of document.body.innerHTML += ...).
  
  --  version 1.4 (Dec. 20, 2004)
  Added "targetDateField.focus();" to the updateDateField function (as suggested
  by Alan Lepofsky) to avoid a situation where the cursor focus is at the top of the
  form after a date has been picked. Added "padding: 0px;" to the dpButton CSS
  style, to keep the table from being so wide when displayed in Firefox.
  
  -- version 1.5 (Dec 4, 2005)
  Added display=none when datepicker is hidden, to fix problem where cursor is
  not visible on input fields that are beneath the date picker. Added additional null
  date handling for date errors in Safari when the date is empty. Added additional
  error handling for iFrame creation, to avoid reported errors in Opera. Added
  onMouseOver event for day cells, to allow color changes when the mouse hovers
  over a cell (to make it easier to determine what cell you're over). Added comments
  in the style sheet, to make it more clear what the different style elements are for.
  */
  
  var datePickerDivID = "datepicker";
  var iFrameDivID = "datepickeriframe";
  
  var dayArrayShort = new Array('Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa');
  var dayArrayMed = new Array('Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat');
  var dayArrayLong = new Array('Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday');
  var monthArrayShort = new Array('Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec');
  var monthArrayMed = new Array('Jan', 'Feb', 'Mar', 'Apr', 'May', 'June', 'July', 'Aug', 'Sept', 'Oct', 'Nov', 'Dec');
  var monthArrayLong = new Array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');
   
  // these variables define the date formatting we're expecting and outputting.
  // If you want to use a different format by default, change the defaultDateSeparator
  // and defaultDateFormat variables either here or on your HTML page.
  var defaultDateSeparator = "/";        // common values would be "/" or "."
  var defaultDateFormat = "mdy"    // valid values are "mdy", "dmy", and "ymd"
  var dateSeparator = defaultDateSeparator;
  var dateFormat = defaultDateFormat;
  
  /**
  This is the main function you'll call from the onClick event of a button.
  Normally, you'll have something like this on your HTML page:
  
  Start Date: <input name="StartDate">
  <input type=button value="select" onclick="displayDatePicker('StartDate');">
  
  That will cause the datepicker to be displayed beneath the StartDate field and
  any date that is chosen will update the value of that field. If you'd rather have the
  datepicker display beneath the button that was clicked, you can code the button
  like this:
  
  <input type=button value="select" onclick="displayDatePicker('StartDate', this);">
  
  So, pretty much, the first argument (dateFieldName) is a string representing the
  name of the field that will be modified if the user picks a date, and the second
  argument (displayBelowThisObject) is optional and represents an actual node
  on the HTML document that the datepicker should be displayed below.
  
  In version 1.1 of this code, the dtFormat and dtSep variables were added, allowing
  you to use a specific date format or date separator for a given call to this function.
  Normally, you'll just want to set these defaults globally with the defaultDateSeparator
  and defaultDateFormat variables, but it doesn't hurt anything to add them as optional
  parameters here. An example of use is:
  
  <input type=button value="select" onclick="displayDatePicker('StartDate', false, 'dmy', '.');">
  
  This would display the datepicker beneath the StartDate field (because the
  displayBelowThisObject parameter was false), and update the StartDate field with
  the chosen value of the datepicker using a date format of dd.mm.yyyy
  */
  function displayDatePicker(dateFieldName, displayBelowThisObject, dtFormat, dtSep)
  {
    var targetDateField = document.getElementsByName (dateFieldName).item(0);
   
    // if we weren't told what node to display the datepicker beneath, just display it
    // beneath the date field we're updating
    if (!displayBelowThisObject)
      displayBelowThisObject = targetDateField;
   
    // if a date separator character was given, update the dateSeparator variable
    if (dtSep)
      dateSeparator = dtSep;
    else
      dateSeparator = defaultDateSeparator;
   
    // if a date format was given, update the dateFormat variable
    if (dtFormat)
      dateFormat = dtFormat;
    else
      dateFormat = defaultDateFormat;
   
    var x = displayBelowThisObject.offsetLeft;
    var y = displayBelowThisObject.offsetTop + displayBelowThisObject.offsetHeight ;
   
    // deal with elements inside tables and such
    var parent = displayBelowThisObject;
    while (parent.offsetParent) {
      parent = parent.offsetParent;
      x += parent.offsetLeft;
      y += parent.offsetTop ;
    }
   
    drawDatePicker(targetDateField, x, y);
  }
  
  
  /**
  Draw the datepicker object (which is just a table with calendar elements) at the
  specified x and y coordinates, using the targetDateField object as the input tag
  that will ultimately be populated with a date.
  
  This function will normally be called by the displayDatePicker function.
  */
  function drawDatePicker(targetDateField, x, y)
  {
    var dt = getFieldDate(targetDateField.value );
   
    // the datepicker table will be drawn inside of a <div> with an ID defined by the
    // global datePickerDivID variable. If such a div doesn't yet exist on the HTML
    // document we're working with, add one.
    if (!document.getElementById(datePickerDivID)) {
      // don't use innerHTML to update the body, because it can cause global variables
      // that are currently pointing to objects on the page to have bad references
      //document.body.innerHTML += "<div id='" + datePickerDivID + "' class='dpDiv'></div>";
      var newNode = document.createElement("div");
      newNode.setAttribute("id", datePickerDivID);
      newNode.setAttribute("class", "dpDiv");
      newNode.setAttribute("style", "visibility: hidden;");
      document.body.appendChild(newNode);
    }
   
    // move the datepicker div to the proper x,y coordinate and toggle the visiblity
    var pickerDiv = document.getElementById(datePickerDivID);
    pickerDiv.style.position = "absolute";
    pickerDiv.style.left = x + "px";
    pickerDiv.style.top = y + "px";
    pickerDiv.style.visibility = (pickerDiv.style.visibility == "visible" ? "hidden" : "visible");
    pickerDiv.style.display = (pickerDiv.style.display == "block" ? "none" : "block");
    pickerDiv.style.zIndex = 10000;
   
    // draw the datepicker table
    refreshDatePicker(targetDateField.name, dt.getFullYear(), dt.getMonth(), dt.getDate());
  }
  
  
  /**
  This is the function that actually draws the datepicker calendar.
  */
  function refreshDatePicker(dateFieldName, year, month, day)
  {
    // if no arguments are passed, use today's date; otherwise, month and year
    // are required (if a day is passed, it will be highlighted later)
    var thisDay = new Date();
   
    if ((month >= 0) && (year > 0)) {
      thisDay = new Date(year, month, 1);
    } else {
      day = thisDay.getDate();
      thisDay.setDate(1);
    }
   
    // the calendar will be drawn as a table
    // you can customize the table elements with a global CSS style sheet,
    // or by hardcoding style and formatting elements below
    var crlf = "\r\n";
    var TABLE = "<table cols='7' class='dpTable'>" + crlf;
    var xTABLE = "</table>" + crlf;
    var TR = "<tr class='dpTR'>";
    var TR_title = "<tr class='dpTitleTR'>";
    var TR_days = "<tr class='dpDayTR'>";
    var TR_todaybutton = "<tr class='dpTodayButtonTR'>";
    var xTR = "</tr>" + crlf;
    var TD = "<td class='dpTD' onmouseout='this.className=\"dpTD\";' onmouseover=' this.className=\"dpTDHover\";' ";    // leave this tag open, because we'll be adding an onclick event
    var TD_title = "<td colspan='5' class='dpTitleTD'>";
    var TD_buttons = "<td class='dpButtonTD'>";
    var TD_todaybutton = "<td colspan='7' class='dpTodayButtonTD'>";
    var TD_days = "<td class='dpDayTD'>";
    var TD_selected = "<td class='dpDayHighlightTD' onmouseout='this.className=\"dpDayHighlightTD\";' onmouseover='this.className=\"dpTDHover\";' ";    // leave this tag open, because we'll be adding an onclick event
    var xTD = "</td>" + crlf;
    var DIV_title = "<div class='dpTitleText'>";
    var DIV_selected = "<div class='dpDayHighlight'>";
    var xDIV = "</div>";
   
    // start generating the code for the calendar table
    var html = TABLE;
   
    // this is the title bar, which displays the month and the buttons to
    // go back to a previous month or forward to the next month
    html += TR_title;
    html += TD_buttons + getButtonCode(dateFieldName, thisDay, -1, "&lt;") + xTD;
    html += TD_title + DIV_title + monthArrayLong[ thisDay.getMonth()] + " " + thisDay.getFullYear() + xDIV + xTD;
    html += TD_buttons + getButtonCode(dateFieldName, thisDay, 1, "&gt;") + xTD;
    html += xTR;
   
    // this is the row that indicates which day of the week we're on
    html += TR_days;
    for(i = 0; i < dayArrayShort.length; i++)
      html += TD_days + dayArrayShort[i] + xTD;
    html += xTR;
   
    // now we'll start populating the table with days of the month
    html += TR;
   
    // first, the leading blanks
    for (i = 0; i < thisDay.getDay(); i++)
      html += TD + "> " + xTD;
   
    // now, the days of the month
    do {
      dayNum = thisDay.getDate();
      TD_onclick = " onclick=\"updateDateField('" + dateFieldName + "', '" + getDateString(thisDay) + "');\">";
      
      if (dayNum == day)
        html += TD_selected + TD_onclick + DIV_selected + dayNum + xDIV + xTD;
      else
        html += TD + TD_onclick + dayNum + xTD;
      
      // if this is a Saturday, start a new row
      if (thisDay.getDay() == 6)
        html += xTR + TR;
      
      // increment the day
      thisDay.setDate(thisDay.getDate() + 1);
    } while (thisDay.getDate() > 1)
   
    // fill in any trailing blanks
    if (thisDay.getDay() > 0) {
      for (i = 6; i > thisDay.getDay(); i--)
        html += TD + "> " + xTD;
    }
    html += xTR;
   
    // add a button to allow the user to easily return to today, or close the calendar
    var today = new Date();
    var todayString = "Today is " + dayArrayMed[today.getDay()] + ", " + monthArrayMed[ today.getMonth()] + " " + today.getDate();
    html += TR_todaybutton + TD_todaybutton;
    html += "<button class='dpTodayButton' onclick='refreshDatePicker(\"" + dateFieldName + "\");'>this month</button> ";
    html += "<button class='dpTodayButton' onclick='updateDateField(\"" + dateFieldName + "\");'>close</button>";
    html += xTD + xTR;
   
    // and finally, close the table
    html += xTABLE;
   
    document.getElementById(datePickerDivID).innerHTML = html;
    // add an "iFrame shim" to allow the datepicker to display above selection lists
    adjustiFrame();
  }
  
  
  /**
  Convenience function for writing the code for the buttons that bring us back or forward
  a month.
  */
  function getButtonCode(dateFieldName, dateVal, adjust, label)
  {
    var newMonth = (dateVal.getMonth () + adjust) % 12;
    var newYear = dateVal.getFullYear() + parseInt((dateVal.getMonth() + adjust) / 12);
    if (newMonth < 0) {
      newMonth += 12;
      newYear += -1;
    }
   
    return "<button class='dpButton' onclick='refreshDatePicker(\"" + dateFieldName + "\", " + newYear + ", " + newMonth + ");'>" + label + "</button>";
  }
  
  
  /**
  Convert a JavaScript Date object to a string, based on the dateFormat and dateSeparator
  variables at the beginning of this script library.
  */
  function getDateString(dateVal)
  {
    var dayString = "00" + dateVal.getDate();
    var monthString = "00" + (dateVal.getMonth()+1);
    dayString = dayString.substring(dayString.length - 2);
    monthString = monthString.substring(monthString.length - 2);
   
    switch (dateFormat) {
      case "dmy" :
        return dayString + dateSeparator + monthString + dateSeparator + dateVal.getFullYear();
      case "ymd" :
        return dateVal.getFullYear() + dateSeparator + monthString + dateSeparator + dayString;
      case "mdy" :
      default :
        return monthString + dateSeparator + dayString + dateSeparator + dateVal.getFullYear();
    }
  }
  
  
  /**
  Convert a string to a JavaScript Date object.
  */
  function getFieldDate(dateString)
  {
    var dateVal;
    var dArray;
    var d, m, y;
   
    try {
      dArray = splitDateString(dateString);
      if (dArray) {
        switch (dateFormat) {
          case "dmy" :
            d = parseInt(dArray[0], 10);
            m = parseInt(dArray[1], 10) - 1;
            y = parseInt(dArray[2], 10);
            break;
          case "ymd" :
            d = parseInt(dArray[2], 10);
            m = parseInt(dArray[1], 10) - 1;
            y = parseInt(dArray[0], 10);
            break;
          case "mdy" :
          default :
            d = parseInt(dArray[1], 10);
            m = parseInt(dArray[0], 10) - 1;
            y = parseInt(dArray[2], 10);
            break;
        }
        dateVal = new Date(y, m, d);
      } else if (dateString) {
        dateVal = new Date(dateString);
      } else {
        dateVal = new Date();
      }
    } catch(e) {
      dateVal = new Date();
    }
   
    return dateVal;
  }
  
  
  /**
  Try to split a date string into an array of elements, using common date separators.
  If the date is split, an array is returned; otherwise, we just return false.
  */
  function splitDateString(dateString)
  {
    var dArray;
    if (dateString.indexOf("/") >= 0)
      dArray = dateString.split("/");
    else if (dateString.indexOf(".") >= 0)
      dArray = dateString.split(".");
    else if (dateString.indexOf("-") >= 0)
      dArray = dateString.split("-");
    else if (dateString.indexOf("\\") >= 0)
      dArray = dateString.split("\\");
    else
      dArray = false;
   
    return dArray;
  }
  
  /**
  Update the field with the given dateFieldName with the dateString that has been passed,
  and hide the datepicker. If no dateString is passed, just close the datepicker without
  changing the field value.
  
  Also, if the page developer has defined a function called datePickerClosed anywhere on
  the page or in an imported library, we will attempt to run that function with the updated
  field as a parameter. This can be used for such things as date validation, setting default
  values for related fields, etc. For example, you might have a function like this to validate
  a start date field:
  
  function datePickerClosed(dateField)
  {
    var dateObj = getFieldDate(dateField.value);
    var today = new Date();
    today = new Date(today.getFullYear(), today.getMonth(), today.getDate());
   
    if (dateField.name == "StartDate") {
      if (dateObj < today) {
        // if the date is before today, alert the user and display the datepicker again
        alert("Please enter a date that is today or later");
        dateField.value = "";
        document.getElementById(datePickerDivID).style.visibility = "visible";
        adjustiFrame();
      } else {
        // if the date is okay, set the EndDate field to 7 days after the StartDate
        dateObj.setTime(dateObj.getTime() + (7 * 24 * 60 * 60 * 1000));
        var endDateField = document.getElementsByName ("EndDate").item(0);
        endDateField.value = getDateString(dateObj);
      }
    }
  }
  
  */
  function updateDateField(dateFieldName, dateString)
  {
    var targetDateField = document.getElementsByName (dateFieldName).item(0);
    if (dateString)
      targetDateField.value = dateString;
   
    var pickerDiv = document.getElementById(datePickerDivID);
    pickerDiv.style.visibility = "hidden";
    pickerDiv.style.display = "none";
   
    adjustiFrame();
    targetDateField.focus();
   
    // after the datepicker has closed, optionally run a user-defined function called
    // datePickerClosed, passing the field that was just updated as a parameter
    // (note that this will only run if the user actually selected a date from the datepicker)
    if ((dateString) && (typeof(datePickerClosed) == "function"))
      datePickerClosed(targetDateField);
  }
  
  
  /**
  Use an "iFrame shim" to deal with problems where the datepicker shows up behind
  selection list elements, if they're below the datepicker. The problem and solution are
  described at:
  
  http://dotnetjunkies.com/WebLog/jking/archive/2003/07/21/488.aspx
  http://dotnetjunkies.com/WebLog/jking/archive/2003/10/30/2975.aspx
  */
  function adjustiFrame(pickerDiv, iFrameDiv)
  {
    // we know that Opera doesn't like something about this, so if we
    // think we're using Opera, don't even try
    var is_opera = (navigator.userAgent.toLowerCase().indexOf("opera") != -1);
    if (is_opera)
      return;
    
    // put a try/catch block around the whole thing, just in case
    try {
      if (!document.getElementById(iFrameDivID)) {
        // don't use innerHTML to update the body, because it can cause global variables
        // that are currently pointing to objects on the page to have bad references
        //document.body.innerHTML += "<iframe id='" + iFrameDivID + "' src='javascript:false;' scrolling='no' frameborder='0'>";
        var newNode = document.createElement("iFrame");
        newNode.setAttribute("id", iFrameDivID);
        newNode.setAttribute("src", "javascript:false;");
        newNode.setAttribute("scrolling", "no");
        newNode.setAttribute ("frameborder", "0");
        document.body.appendChild(newNode);
      }
      
      if (!pickerDiv)
        pickerDiv = document.getElementById(datePickerDivID);
      if (!iFrameDiv)
        iFrameDiv = document.getElementById(iFrameDivID);
      
      try {
        iFrameDiv.style.position = "absolute";
        iFrameDiv.style.width = pickerDiv.offsetWidth;
        iFrameDiv.style.height = pickerDiv.offsetHeight ;
        iFrameDiv.style.top = pickerDiv.style.top;
        iFrameDiv.style.left = pickerDiv.style.left;
        iFrameDiv.style.zIndex = pickerDiv.style.zIndex - 1;
        iFrameDiv.style.visibility = pickerDiv.style.visibility ;
        iFrameDiv.style.display = pickerDiv.style.display;
      } catch(e) {
      }
   
    } catch (ee) {
    }
   
  }
  
  
  


From norman.richards at jboss.com  Wed Dec  6 19:19:15 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:19:15 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui/tag  ...
Message-ID: <E1Gs6yp-00040i-ED@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:19:15

  Added:       src/ui/org/jboss/seam/ui/tag  SelectDateTag.java
  Log:
  JBSEAM-556: add s:selectDate
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 00:19:15;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/tag/SelectDateTag.java
  
  Index: SelectDateTag.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source
   * Copyright 2006, JBoss Inc., and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.seam.ui.tag;
  
  import javax.faces.component.UIComponent;
  
  import org.jboss.seam.ui.SelectDate;
  
  
  public class SelectDateTag extends UIComponentTagBase
  {
      @Override
      public String getComponentType()
      {
          return SelectDate.COMPONENT_TYPE;
      }
  
      @Override
      public String getRendererType()
      {
          return null;
      }
  
      private String forField;
  
      @Override
      protected void setProperties(UIComponent component)
      {
          super.setProperties(component);
          setStringProperty(component, "for", forField);
      }
  
      public void setFor(String forField)
      {
          this.forField = forField;
      }
  
  }
  
  
  


From norman.richards at jboss.com  Wed Dec  6 19:23:53 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:23:53 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/view/img - New directory ...
Message-ID: <E1Gs73J-00046V-CN@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:23:53

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/seampay/view/img added to the repository


From norman.richards at jboss.com  Wed Dec  6 19:24:19 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:24:19 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay  ...
Message-ID: <E1Gs73j-00046z-Aq@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:24:19

  Modified:    examples/seampay  build.xml
  Log:
  use s:selectDate
  
  Revision  Changes    Path
  1.4       +9 -10     jboss-seam/examples/seampay/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/build.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- build.xml	5 Dec 2006 16:20:40 -0000	1.3
  +++ build.xml	7 Dec 2006 00:24:19 -0000	1.4
  @@ -17,6 +17,5 @@
       <property name="tomcat.conf"             value="eejb.conf"/>  
   
       <import file="../../build.xml"/>
  -
   </project>
   
  
  
  


From norman.richards at jboss.com  Wed Dec  6 19:24:19 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:24:19 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/view   ...
Message-ID: <E1Gs73j-000479-Ej@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:24:19

  Modified:    examples/seampay/view   search.xhtml
  Added:       examples/seampay/view   date.css
  Log:
  use s:selectDate
  
  Revision  Changes    Path
  1.7       +6 -1      jboss-seam/examples/seampay/view/search.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: search.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/view/search.xhtml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- search.xhtml	14 Nov 2006 05:03:02 -0000	1.6
  +++ search.xhtml	7 Dec 2006 00:24:19 -0000	1.7
  @@ -9,6 +9,7 @@
       <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
       <title>Seam Pay</title>
       <link href="screen.css" rel="stylesheet" type="text/css" />
  +    <link href="date.css"   rel="stylesheet" type="text/css" />
   </head>
   <body>
         
  @@ -114,9 +115,13 @@
                           <tr>
                               <td>Date:</td>
                               <td><h:inputText id="paymentDate" value="#{newPayment.paymentDate}" required="true"> 
  -                                <f:convertDateTime type="date" dateStyle="short"/>
  +                                    <s:convertDateTime pattern="MM/dd/yyyy"/>
                                   
                                   </h:inputText>
  +                                <s:selectDate for="paymentDate">
  +                                    <h:graphicImage url="img/dtpick.gif" />
  +                                </s:selectDate>
  +
                                   <h:message for="paymentDate" />
                               </td>
                           </tr>
  
  
  
  1.1      date: 2006/12/07 00:24:19;  author: nrichards;  state: Exp;jboss-seam/examples/seampay/view/date.css
  
  Index: date.css
  ===================================================================
  /* Date Picker 
  ----------------------------------------------- */
  
  /* the div that holds the date picker calendar */
  .dpDiv {
  }
  
  
  /* the table (within the div) that holds the date picker calendar */
  .dpTable {
      font-family: Tahoma, Arial, Helvetica, sans-serif;
      font-size: 12px;
      text-align: center;
      color: #505050;
      background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
      background-color: #FFFFFF;
      border: 1px solid #AAAAAA;
      margin-top: 5px;
  }
  
  
  /* a table row that holds date numbers (either blank or 1-31) */
  .dpTR {
  }
  
  
  /* the top table row that holds the month, year, and forward/backward buttons */
  .dpTitleTR {
  }
  
  
  /* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  .dpDayTR {
  }
  
  
  /* the bottom table row, that has the "This Month" and "Close" buttons */
  .dpTodayButtonTR {
  }
  
  
  /* a table cell that holds a date number (either blank or 1-31) */
  .dpTD {
      border: 1px solid #ece9d8;
  }
  
  
  /* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  .dpDayHighlightTD {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
  }
  
  
  /* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  .dpTDHover {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      cursor: pointer;
      color: red;
  }
  
  
  /* the table cell that holds the name of the month and the year */
  .dpTitleTD {
  }
  
  
  /* a table cell that holds one of the forward/backward buttons */
  .dpButtonTD {
  }
  
  
  /* the table cell that holds the "This Month" or "Close" button at the bottom */
  .dpTodayButtonTD {
  }
  
  
  /* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  .dpDayTD {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      color: white;
  }
  
  
  /* additional style information for the text that indicates the month and year */
  .dpTitleText {
      font-size: 12px;
      color: gray;
      font-weight: bold;
  }
  
  
  /* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  .dpDayHighlight {
      font-weight: bold;
  }
  
  
  /* the forward/backward buttons at the top */
  .dpButton {
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      padding: 0px;
      border: 1px solid #AAAAAA;
  }
  
  
  /* the "This Month" and "Close" buttons at the bottom */
  .dpTodayButton {
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      border: 1px solid #AAAAAA;
      display:none;
  }
  
  
  
  


From norman.richards at jboss.com  Wed Dec  6 19:24:19 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 19:24:19 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/view/img  ...
Message-ID: <E1Gs73j-00047F-JC@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 19:24:19

  Added:       examples/seampay/view/img  dtpick.gif
  Log:
  use s:selectDate
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 00:24:19;  author: nrichards;  state: Exp;jboss-seam/examples/seampay/view/img/dtpick.gif
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 19:56:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 19:56:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r58891 - in projects/aop/trunk/aop/src:
	resources/test/beforeafterArgs
	test/org/jboss/test/aop/beforeafterArgs
Message-ID: <E1Gs7Yr-0004co-0L@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 19:56:01 -0500 (Wed, 06 Dec 2006)
New Revision: 58891

Added:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Implementor.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Interface.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedThrowingAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubInterface.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperInterface.java
Modified:
   projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdvicePOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/POJOException.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ReturnPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubClass.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperClass.java
Log:
[JBAOP-37] Added a partical overloaded throwing advice tests (will complete these when specification of the thrown exception is implemented)

Modified: projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-07 00:56:01 UTC (rev 58891)
@@ -232,4 +232,10 @@
       <after name="after54" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
       <after name="after55" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedAfterAspect"/>
   	</bind>
+  	
+  	<aspect class="org.jboss.test.aop.beforeafterArgs.OverloadedThrowingAspect" scope="PER_VM"/>
+   
+  	<bind pointcut="call(* org.jboss.test.aop.beforeafterArgs.OverloadedAdvicePOJO->method4(..))">
+   	<throwing name="throwing1" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedThrowingAspect"/>
+  	</bind>
 </aop>
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Implementor.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Implementor.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Implementor.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Class used on before/after/throwing annotated parameter tests.
+ * 
+ * @author  <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class Implementor implements SubInterface
+{}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Interface.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Interface.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/Interface.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -0,0 +1,31 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * @author  <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ *
+ */
+public interface Interface extends SuperInterface
+{
+
+}

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdvicePOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdvicePOJO.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdvicePOJO.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -36,4 +36,14 @@
    {
       return null;
    }
+   
+   public void method3() throws POJOException
+   {
+      this.method4(null, null);
+   }
+   
+   public void method4(SubInterface arg1, Implementor arg2) throws POJOException
+   {
+      throw new POJOException();
+   }
 }
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -162,4 +162,14 @@
       assertEquals("void,SuperValue", OverloadedAfterAspect.after54);
       assertEquals("void", OverloadedAfterAspect.after55);
    }
+   
+   public void test4()
+   {
+      try
+      {
+         pojo.method3();
+      } catch (POJOException pe) {}
+      assertEquals("JoinPointInfo,Throwable,SubInterface,Implementor",
+            OverloadedThrowingAspect.throwing1);
+   }
 }
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedThrowingAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedThrowingAspect.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedThrowingAspect.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -0,0 +1,502 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import org.jboss.aop.JoinPointInfo;
+import org.jboss.aop.advice.annotation.Arg;
+import org.jboss.aop.advice.annotation.JoinPoint;
+import org.jboss.aop.advice.annotation.Thrown;
+
+/**
+ * Aspect used on overloaded throwing advice tests.
+ *
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class OverloadedThrowingAspect
+{
+   static String throwing1 = null;
+   
+   static void clear()
+   {
+      throwing1 = null;
+   }
+
+   // TODO finish this test when we can define the throwing to catch POJOException
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SubInterface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SubInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg Interface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Interface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SubInterface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SubInterface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SubInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SubInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SuperInterface arg,
+         @Arg Implementor implementor)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SuperInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SubInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SubInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg Interface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Interface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SuperInterface arg1,
+         @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SuperInterface,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SuperInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SuperInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg Interface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Interface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SubInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SubInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SuperInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SuperInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg Interface arg1, @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Interface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown POJOException thrown, @Arg SuperInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SuperInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SubInterface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SubInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg Interface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,Interface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SubInterface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SubInterface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SubInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SubInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SuperInterface arg,
+         @Arg Implementor implementor)
+   {
+      throwing1 = "JoinPointInfo,Exception,SuperInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SubInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SubInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg Interface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,Interface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SuperInterface arg1,
+         @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SuperInterface,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SuperInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SuperInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg Interface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,Interface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SubInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SubInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SuperInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SuperInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg Interface arg1, @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,Interface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Exception thrown, @Arg SuperInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Exception,SuperInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SubInterface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SubInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg Interface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Interface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SubInterface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SubInterface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SubInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SubInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SuperInterface arg,
+         @Arg Implementor implementor)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SuperInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SubInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SubInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg Interface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Interface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SuperInterface arg1,
+         @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SuperInterface,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SuperInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SuperInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg Interface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Interface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SubInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SubInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SuperInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SuperInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg Interface arg1, @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Interface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Throwable thrown, @Arg SuperInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SuperInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SubInterface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SubInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg Interface arg1, @Arg Implementor arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,Interface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SubInterface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SubInterface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SubInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SubInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SuperInterface arg,
+         @Arg Implementor implementor)
+   {
+      throwing1 = "JoinPointInfo,Object,SuperInterface,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SubInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SubInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg Interface arg1, @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,Interface,SubInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SuperInterface arg1,
+         @Arg SubInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SuperInterface,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SuperInterface arg1, @Arg Object arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SuperInterface,Object";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg Interface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,Interface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SubInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SubInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SuperInterface arg1, @Arg Interface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SuperInterface,Interface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg Interface arg1, @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,Interface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinpoint,
+         @Thrown Object thrown, @Arg SuperInterface arg1, 
+         @Arg SuperInterface arg2)
+   {
+      throwing1 = "JoinPointInfo,Object,SuperInterface,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown POJOException thrown, @Arg SubInterface arg1)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown POJOException thrown, @Arg Implementor arg1)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown POJOException thrown, @Arg Interface arg1)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Interface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown POJOException thrown, @Arg Object arg1)
+   {
+      throwing1 = "JoinPointInfo,POJOException,Object";
+   }
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown POJOException thrown, @Arg SuperInterface arg1)
+   {
+      throwing1 = "JoinPointInfo,POJOException,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Exception thrown, @Arg SubInterface arg1)
+   {
+      throwing1 = "JoinPointInfo,Exception,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Exception thrown, @Arg Implementor arg1)
+   {
+      throwing1 = "JoinPointInfo,Exception,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Exception thrown, @Arg Interface arg1)
+   {
+      throwing1 = "JoinPointInfo,Exception,Interface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Exception thrown, @Arg Object arg1)
+   {
+      throwing1 = "JoinPointInfo,Exception,Object";
+   }
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Exception thrown, @Arg SuperInterface arg1)
+   {
+      throwing1 = "JoinPointInfo,Exception,SuperInterface";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Throwable thrown, @Arg SubInterface arg1)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SubInterface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Throwable thrown, @Arg Implementor arg1)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Implementor";
+   }
+   
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Throwable thrown, @Arg Interface arg1)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Interface";
+   }
+
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Throwable thrown, @Arg Object arg1)
+   {
+      throwing1 = "JoinPointInfo,Throwable,Object";
+   }
+   public void throwing1(@JoinPoint JoinPointInfo joinPoint,
+         @Thrown Throwable thrown, @Arg SuperInterface arg1)
+   {
+      throwing1 = "JoinPointInfo,Throwable,SuperInterface";
+   }
+   
+   public void throwing1(@Thrown POJOException thrown)
+   {
+      throwing1 = "POJOException";
+   }
+   
+   public void throwing1(@Thrown Exception thrown)
+   {
+      throwing1 = "Exception";
+   }
+   
+   public void throwing1(@Thrown Throwable thrown)
+   {
+      throwing1 = "Throwable";
+   }
+   
+   public void throwing1(@Thrown Object thrown)
+   {
+      throwing1 = "Object";
+   }
+}
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/POJOException.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/POJOException.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/POJOException.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -22,7 +22,7 @@
 package org.jboss.test.aop.beforeafterArgs;
 
 /**
- * Class used on annotated parameter tests.
+ * Class used on before/after/throwing annotated parameter tests.
  * 
  * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
  */

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ReturnPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ReturnPOJO.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ReturnPOJO.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -22,8 +22,8 @@
 package org.jboss.test.aop.beforeafterArgs;
 
 /**
- * Plain old java object used both on @Return parameter tests, and on advice return type
- * tests.
+ * Plain old java object used both on @Return parameter tests, and on advice return
+ * type tests.
  * 
  * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
  */

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubClass.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubClass.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubClass.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -21,7 +21,10 @@
  */
 package org.jboss.test.aop.beforeafterArgs;
 
+/**
+ * Class used on before/after/throwing annotated parameter tests.
+ * 
+ * @author  <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
 public class SubClass extends SuperClass
-{
-
-}
+{}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubInterface.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubInterface.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SubInterface.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -0,0 +1,32 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Class used on before/after/throwing annotated parameter tests.
+ * 
+ * @author  <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public interface SubInterface extends Interface
+{
+
+}

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperClass.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperClass.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperClass.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -21,7 +21,10 @@
  */
 package org.jboss.test.aop.beforeafterArgs;
 
+/**
+ * Class used on before/after/throwing annotated parameter tests.
+ * 
+ * @author  <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
 public class SuperClass
-{
-
-}
+{}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperInterface.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperInterface.java	2006-12-06 23:08:54 UTC (rev 58890)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/SuperInterface.java	2006-12-07 00:56:01 UTC (rev 58891)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Class used on before/after/throwing annotated parameter tests.
+ * 
+ * @author  <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public interface SuperInterface
+{}
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 19:57:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 19:57:01 -0500
Subject: [jboss-cvs] JBossAS SVN: r58892 -
	projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation
Message-ID: <E1Gs7ZN-0004eA-0T@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 19:56:57 -0500 (Wed, 06 Dec 2006)
New Revision: 58892

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java
Log:
[JBAOP-37] Fixed a warning message.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java	2006-12-07 00:56:01 UTC (rev 58891)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java	2006-12-07 00:56:57 UTC (rev 58892)
@@ -406,7 +406,7 @@
             {
                AdviceMethodFactory.adviceMatchingMessage.append("\n[warn] - mandatory parameter annotation ");
                AdviceMethodFactory.adviceMatchingMessage.append(rule.getAnnotation());
-               AdviceMethodFactory.adviceMatchingMessage.append("not found on method ");
+               AdviceMethodFactory.adviceMatchingMessage.append(" not found on method ");
                AdviceMethodFactory.adviceMatchingMessage.append(method);
             }
             return false;



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 20:33:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 20:33:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r58893 -
	projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter
Message-ID: <E1Gs88y-0005LV-0h@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 20:33:37 -0500 (Wed, 06 Dec 2006)
New Revision: 58893

Modified:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/ArgsAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/BeforeAfterThrowingTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/GeneralAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/POJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/SimpleAspect.java
Log:
[JBAOP-37] Updated tests so they check whether advices are being called at the correct moment (before/after/around/throwing).

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/ArgsAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/ArgsAspect.java	2006-12-07 00:56:57 UTC (rev 58892)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/ArgsAspect.java	2006-12-07 01:33:37 UTC (rev 58893)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.test.aop.beforeafter;
 
+import junit.framework.Assert;
+
 import org.jboss.aop.ConstructorInfo;
 import org.jboss.aop.FieldInfo;
 import org.jboss.aop.MethodInfo;
@@ -40,6 +42,7 @@
    public static String before;
    public static String after;
    public static String throwing;
+   public static Throwable exception;
 
 
    public static void clear()
@@ -47,53 +50,63 @@
       before = null;
       after = null;
       throwing = null;
+      POJO.joinPointRun = false;
    }
    
    public void before(@Arg boolean b, @Arg int i)
    {
       before = "before1";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public void before(@JoinPoint MethodInfo mjp, @Arg int i)
    {
       before = "before2";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public void before(@JoinPoint FieldInfo fjp, @Arg int i)
    {
       before = "before3";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public void before(@JoinPoint FieldInfo fjp)
    {
       before = "before4";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public void before(@JoinPoint FieldInfo fjp, @Arg SubValue val)
    {
       before = "before5";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public void before(@Arg SubValue sup, @Arg SubValue sub)
    {
       before = "before6";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public void before(@Arg SuperValue sup, @Arg SubValue sub)
    {
       before = "before7";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public POJO after(@JoinPoint MethodInfo mjp, @Return POJO ret, @Arg int i,
          @Arg long l)
    {
       after = "after1";
+      Assert.assertTrue(POJO.joinPointRun);
       return ret;
    }
    
    public POJO after(@JoinPoint ConstructorInfo cjp, @Return POJO ret)
    {
       after = "after2";
+      Assert.assertTrue(POJO.joinPointRun);
       return ret;
    }
    
@@ -129,29 +142,34 @@
    {
       after = "after6";
       ret.doubleValue();
+      Assert.assertTrue(POJO.joinPointRun);
       return new SubValue(ret.getValue());
    }
    
    public void after(@Arg SuperValue sup, @Arg SuperValue sup2)
    {
       after = "after7";
+      Assert.assertTrue(POJO.joinPointRun);
    }
    
    public Throwable throwing(@Thrown Throwable t, @Arg int i)
    {
       throwing = "throwing1";
+      exception = t;
       return t;
    }
    
    public Throwable throwing(@JoinPoint MethodInfo mjp, @Thrown Throwable t)
    {
       throwing = "throwing2";
+      exception = t;
       return t;
    }
    
    public Throwable throwing(@JoinPoint MethodInfo mjp, @Thrown Throwable t, @Arg int i)
    {
       throwing = "throwing3";
+      exception = t;
       return t;
    }
 }

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/BeforeAfterThrowingTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/BeforeAfterThrowingTestCase.java	2006-12-07 00:56:57 UTC (rev 58892)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/BeforeAfterThrowingTestCase.java	2006-12-07 01:33:37 UTC (rev 58893)
@@ -59,7 +59,7 @@
       }
       catch(TestException e) 
       {
-         
+         assertSame(e, SimpleAspect.exception);
       }
       
       assertTrue(SimpleAspect.before);
@@ -86,6 +86,7 @@
           assertEquals("before1", ArgsAspect.before);
           assertNull(ArgsAspect.after);
           assertEquals("throwing1", ArgsAspect.throwing);
+          assertSame(e, ArgsAspect.exception);
       }
       
       System.out.println("* Testing ctor(boolean, int, long, String)");
@@ -119,6 +120,8 @@
       }
       catch (TestException e)
       {
+         assertSame(e, ArgsAspect.exception);
+         assertSame(e, SimpleAspect.exception);
       }
       assertNull(ArgsAspect.before);
       assertNull(ArgsAspect.after);
@@ -151,6 +154,7 @@
       }
       catch (TestException e)
       {
+         assertSame(e, ArgsAspect.exception);
       }
 
       System.out.println("* Testing method(boolean, int, long, String)");
@@ -167,6 +171,7 @@
       }
       catch (TestException e)
       {
+         assertSame(e, ArgsAspect.exception);
       }
       
       assertEquals("before2", ArgsAspect.before);

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/GeneralAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/GeneralAspect.java	2006-12-07 00:56:57 UTC (rev 58892)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/GeneralAspect.java	2006-12-07 01:33:37 UTC (rev 58893)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.test.aop.beforeafter;
 
+import junit.framework.Assert;
+
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.advice.annotation.Arg;
 import org.jboss.aop.advice.annotation.JoinPoint;
@@ -40,18 +42,21 @@
    {
       before = null;
       after = null;
+      POJO.joinPointRun = false;
    }
    
 
    public void before(@JoinPoint JoinPointInfo jp, @Arg SuperValue superValue, @Arg int i)
    {
       before = "before";
+      Assert.assertFalse(POJO.joinPointRun);
    }
    
    public Object after(@JoinPoint JoinPointInfo jp, @Return Object ret,
          @Arg SuperValue superValue, @Arg int i)
    {
       after = "after";
+      Assert.assertTrue(POJO.joinPointRun);
       return ret;
    }
 }
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/POJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/POJO.java	2006-12-07 00:56:57 UTC (rev 58892)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/POJO.java	2006-12-07 01:33:37 UTC (rev 58893)
@@ -28,6 +28,7 @@
  */
 public class POJO
 {
+   static boolean joinPointRun = false;
    int i;
    
    SubValue subValue;
@@ -35,21 +36,23 @@
    
    public POJO()
    {
-      
+      joinPointRun = true;
    }
    
    public POJO(boolean error, int i, long l, String s) throws TestException
    {
+      joinPointRun = true;
       if (error) throw new TestException();
    }
    
    public POJO(SuperValue superValue, int i)
    {
-      
+      joinPointRun = true;
    }
 
    public int method(boolean error)throws TestException
    {
+      joinPointRun = true;
       if (error) throw new TestException();
       
       return 1;
@@ -57,6 +60,7 @@
    
    public int method(boolean error, int i, long l, String s) throws TestException
    {
+      joinPointRun = true;
       if (error) throw new TestException();
       
       return i;
@@ -64,6 +68,7 @@
    
    public POJO method(boolean error, int i, long l, String s, int i2) throws TestException
    {
+      joinPointRun = true;
       if (error) throw new TestException();
       
       return this;
@@ -71,26 +76,29 @@
    
    public void method()
    {
-      
+      joinPointRun = true;   
    }
 
    public SuperValue method(SubValue sup, SubValue sub)
    {
+      joinPointRun = true;
       return sub;
    }
    
    public void method(SuperValue sup, SubValue sub)
    {
-      
+      joinPointRun = true;
    }
    
    public SubValue method(SubValue subValue, int i)
    {
+      joinPointRun = true;
       return subValue;
    }
    
    public SuperValue method(SuperValue superValue, int i)
    {
+      joinPointRun = true;
       return superValue;
    }
-}
+}
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/SimpleAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/SimpleAspect.java	2006-12-07 00:56:57 UTC (rev 58892)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafter/SimpleAspect.java	2006-12-07 01:33:37 UTC (rev 58893)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.test.aop.beforeafter;
 
+import junit.framework.Assert;
+
 import org.jboss.aop.advice.annotation.Return;
 import org.jboss.aop.advice.annotation.Thrown;
 import org.jboss.aop.joinpoint.Invocation;
@@ -36,6 +38,7 @@
    public static boolean around;
    public static boolean after;
    public static boolean throwing;
+   public static Throwable exception;
    
    public static void clear()
    {
@@ -43,19 +46,24 @@
       around = false;
       after = false;
       throwing = false;
+      POJO.joinPointRun = false;
    }
    
    public void before()
    {
       System.out.println("SimpleAspect.before");
       before = true;
+      Assert.assertFalse(POJO.joinPointRun);
    }
 
    public Object around(Invocation invocation) throws Throwable
    {
       System.out.println("SimpleAspect.around");
       around = true;
-      return invocation.invokeNext();
+      Assert.assertFalse(POJO.joinPointRun);
+      Object result = invocation.invokeNext();
+      Assert.assertTrue(POJO.joinPointRun);
+      return result;
    }
 
    //Do we have to return the same exception as the target joinpoint?
@@ -63,13 +71,14 @@
    {
       System.out.println("SimpleAspect.after");
       after = true;
+      Assert.assertTrue(POJO.joinPointRun);
       return i;
    }
 
    public void throwing(@Thrown Throwable t)
    {
       System.out.println("SimpleAspect.throwing");
+      exception = t;
       throwing = true;
    }
-
-}
+}
\ No newline at end of file



From norman.richards at jboss.com  Wed Dec  6 20:59:23 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 20:59:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view  ...
Message-ID: <E1Gs8Xj-0005hR-Q6@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 20:59:23

  Modified:    examples/booking/view  book.xhtml
  Log:
  use s:selectDate
  
  Revision  Changes    Path
  1.27      +192 -189  jboss-seam/examples/booking/view/book.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: book.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/book.xhtml,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- book.xhtml	20 Nov 2006 19:42:56 -0000	1.26
  +++ book.xhtml	7 Dec 2006 01:59:23 -0000	1.27
  @@ -9,7 +9,6 @@
   
   <!-- content -->
   <ui:define name="content">
  -<script language="JavaScript" src="js/datePicker.js"/>
   <div class="section">
   	<h1>Book Hotel</h1>
   </div>
  @@ -51,7 +50,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkinDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkinDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkinDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkinDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  @@ -66,7 +67,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkoutDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkoutDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkoutDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkoutDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  
  
  


From norman.richards at jboss.com  Wed Dec  6 20:59:23 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Wed, 06 Dec 2006 20:59:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view/js  ...
Message-ID: <E1Gs8Xj-0005hV-TA@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/06 20:59:23

  Removed:     examples/booking/view/js  datePicker.js
  Log:
  use s:selectDate


From ron_sigal at yahoo.com  Wed Dec  6 21:58:12 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gs9Se-0006oB-0z@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 21:58:12

  Modified:    src/main/org/jboss/remoting  AbstractInvoker.java
  Log:
  JBREM-622:  Stores InvokerCallbackHandlers keyed on sessionId + listenerId.
  
  Revision  Changes    Path
  1.15      +9 -4      JBossRemoting/src/main/org/jboss/remoting/AbstractInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/AbstractInvoker.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- AbstractInvoker.java	16 Nov 2006 18:06:13 -0000	1.14
  +++ AbstractInvoker.java	7 Dec 2006 02:58:11 -0000	1.15
  @@ -47,7 +47,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.14 $
  + * @version $Revision: 1.15 $
    */
   public abstract class AbstractInvoker implements Invoker
   {
  @@ -113,10 +113,10 @@
   
      /**
       * Generates a listener id for the callbackhandler and callback server locator combination
  -    *
  +    * @param sessionId
       * @param locator
       */
  -   public String addClientLocator(InvokerCallbackHandler callbackhandler, InvokerLocator locator)
  +   public String addClientLocator(String sessionId, InvokerCallbackHandler callbackhandler, InvokerLocator locator)
      {
         String listenerId = null;
         synchronized(localServerLocators)
  @@ -136,6 +136,8 @@
            // if got this far, the entry does not exist, so need to add it and create a listener id
            CallbackHandlerHolder holder = new CallbackHandlerHolder(callbackhandler, locator);
            listenerId = new GUID().toString();
  +         if (sessionId != null)
  +            listenerId = sessionId + "+" + listenerId;
            localServerLocators.put(listenerId, holder);
         }
   
  @@ -162,7 +164,7 @@
         return locator;
      }
   
  -   public List getClientLocators(InvokerCallbackHandler handler)
  +   public List getClientLocators(String sessionId, InvokerCallbackHandler handler)
      {
         List holderList = new ArrayList();
         if (handler != null)
  @@ -175,6 +177,9 @@
               {
                  Map.Entry entry = (Map.Entry) itr.next();
                  String listenerId = (String) entry.getKey();
  +               String prefix = listenerId.substring(0, listenerId.indexOf('+'));
  +               if (!sessionId.equals(prefix))
  +                  continue;
                  CallbackHandlerHolder holder = (CallbackHandlerHolder) entry.getValue();
                  InvokerCallbackHandler holderHandler = holder.getHandler();
                  if (holderHandler.equals(handler))
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 21:58:42 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 21:58:42 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gs9T8-0006oL-98@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 21:58:42

  Modified:    src/main/org/jboss/remoting  Client.java
  Log:
  JBREM-622:  Conforms to change in AbstractInvoker, which stores InvokerCallbackHandlers keyed on sessionId + listenerId.
  
  Revision  Changes    Path
  1.59      +3 -3      JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -b -r1.58 -r1.59
  --- Client.java	28 Nov 2006 20:36:31 -0000	1.58
  +++ Client.java	7 Dec 2006 02:58:42 -0000	1.59
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.58 $
  + * @version $Revision: 1.59 $
    */
   public class Client implements Externalizable
   {
  @@ -1035,7 +1035,7 @@
         {
            // is going to be push callbacks which means callback server locator involved.
            // will have to delegate to client invoker.
  -         String listenerId = invoker.addClientLocator(callbackhandler, callbackLocator);
  +         String listenerId = invoker.addClientLocator(sessionId, callbackhandler, callbackLocator);
   
            if (listenerId != null)
            {
  @@ -1176,7 +1176,7 @@
               else
               {
                  // have a push callback handler
  -               List holderList = invoker.getClientLocators(callbackHandler);
  +               List holderList = invoker.getClientLocators(sessionId, callbackHandler);
                  if(holderList != null && holderList.size() > 0)
                  {
                     for(int x = 0; x < holderList.size(); x++)
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 22:00:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 22:00:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple ...
Message-ID: <E1Gs9VF-0006qq-R0@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 22:00:53

  Added:       src/tests/org/jboss/test/remoting/callback/multiple   
                        CallbackTestServer.java CallbackTestClient.java
                        CallbackTestCase.java
  Log:
  JBREM-622:  New unit tests for multiple registrations of an InvokerCallbackHandler.
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 03:00:53;  author: rsigal;  state: Exp;JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestServer.java
  
  Index: CallbackTestServer.java
  ===================================================================
  package org.jboss.test.remoting.callback.multiple;
  
  import java.util.ArrayList;
  import java.util.Iterator;
  import java.util.List;
  
  import javax.management.MBeanServer;
  
  import org.jboss.jrunit.extensions.ServerTestCase;
  import org.jboss.remoting.InvocationRequest;
  import org.jboss.remoting.InvokerLocator;
  import org.jboss.remoting.ServerInvocationHandler;
  import org.jboss.remoting.ServerInvoker;
  import org.jboss.remoting.callback.Callback;
  import org.jboss.remoting.callback.InvokerCallbackHandler;
  import org.jboss.remoting.transport.Connector;
  
  /**
   * Simple remoting server.  Uses inner class SampleInvocationHandler
   * as the invocation target handler class.
   *
   * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
   */
  public class CallbackTestServer extends ServerTestCase
  {
     // Default locator values
     private static String transport = "socket";
     private static String host = "localhost";
     private static int port = 5530;
  
     private String locatorURI = transport + "://" + host + ":" + port;
     private Connector connector;
  
     // String to be returned from invocation handler upon client invocation calls.
     public static final String RESPONSE_VALUE = "This is the return to SampleInvocationHandler invocation";
     public static final String CALLBACK_VALUE = "This is the payload of callback invocation.";
  
  
     public void setupServer() throws Exception
     {
        InvokerLocator locator = new InvokerLocator(locatorURI);
        System.out.println("Starting remoting server with locator uri of: " + locatorURI);
        connector = new Connector();
        connector.setInvokerLocator(locator.getLocatorURI());
        connector.start();
  
        CallbackTestServer.SampleInvocationHandler invocationHandler = new CallbackTestServer.SampleInvocationHandler();
        // first parameter is sub-system name.  can be any String value.
        connector.addInvocationHandler("sample", invocationHandler);
     }
  
     protected void setUp() throws Exception
     {
        setupServer();
     }
  
     protected void tearDown() throws Exception
     {
        if(connector != null)
        {
           connector.stop();
           connector.destroy();
        }
     }
  
     public static void main(String[] args)
     {
        CallbackTestServer server = new CallbackTestServer();
        try
        {
           server.setUp();
  
           Thread.sleep(600000);
        }
        catch (Exception e)
        {
           e.printStackTrace();
        }
     }
  
     /**
      * Simple invocation handler implementation.
      */
     public static class SampleInvocationHandler implements ServerInvocationHandler
     {
  
        private List listeners = new ArrayList();
  
  
        /**
         * called to handle a specific invocation
         *
         * @param invocation
         * @return
         * @throws Throwable
         */
        public Object invoke(InvocationRequest invocation) throws Throwable
        {
           // Just going to return static string as this is just simple example code.
  
           // Will also fire callback to listeners if they were to exist using
           // simple invocation request.
           Callback callback = new Callback(CALLBACK_VALUE);
           Iterator itr = listeners.iterator();
           while(itr.hasNext())
           {
              InvokerCallbackHandler callbackHandler = (InvokerCallbackHandler) itr.next();
              callbackHandler.handleCallback(callback);
           }
  
           return RESPONSE_VALUE;
  
        }
  
        /**
         * Adds a callback handler that will listen for callbacks from
         * the server invoker handler.
         *
         * @param callbackHandler
         */
        public void addListener(InvokerCallbackHandler callbackHandler)
        {
           listeners.add(callbackHandler);
        }
  
        /**
         * Removes the callback handler that was listening for callbacks
         * from the server invoker handler.
         *
         * @param callbackHandler
         */
        public void removeListener(InvokerCallbackHandler callbackHandler)
        {
           listeners.remove(callbackHandler);
        }
  
        /**
         * set the mbean server that the handler can reference
         *
         * @param server
         */
        public void setMBeanServer(MBeanServer server)
        {
           // NO OP as do not need reference to MBeanServer for this handler
        }
  
        /**
         * set the invoker that owns this handler
         *
         * @param invoker
         */
        public void setInvoker(ServerInvoker invoker)
        {
           // NO OP as do not need reference back to the server invoker
        }
  
     }
  }
  
  
  
  1.1      date: 2006/12/07 03:00:53;  author: rsigal;  state: Exp;JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestClient.java
  
  Index: CallbackTestClient.java
  ===================================================================
  package org.jboss.test.remoting.callback.multiple;
  
  import junit.framework.TestCase;
  import org.jboss.logging.Logger;
  import org.jboss.remoting.AbstractInvoker;
  import org.jboss.remoting.Client;
  import org.jboss.remoting.InvocationRequest;
  import org.jboss.remoting.InvokerLocator;
  import org.jboss.remoting.ServerInvocationHandler;
  import org.jboss.remoting.ServerInvoker;
  import org.jboss.remoting.callback.Callback;
  import org.jboss.remoting.callback.HandleCallbackException;
  import org.jboss.remoting.callback.InvokerCallbackHandler;
  import org.jboss.remoting.transport.ClientInvoker;
  import org.jboss.remoting.transport.Connector;
  
  import javax.management.MBeanServer;
  
  import java.lang.reflect.Field;
  import java.util.ArrayList;
  import java.util.Iterator;
  import java.util.List;
  import java.util.Map;
  
  /**
   * These tests supplement the tests in org.jboss.test.remoting.callback.multiple.client
   * and org.jboss.test.remoting.callback.multiple.server.
   *  
   * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
   * @version $Revision: 1.1 $
   * <p>
   * Copyright Dec 6, 2006
   * </p>
   */
  public class CallbackTestClient extends TestCase
  {
     // Default locator values
     private static String transport = "socket";
     private static String host = "localhost";
     private static int port = 5530;
     private static int nextPort = port + 10;
  
     private String locatorURI = transport + "://" + host + ":" + port;
  
     private static final Logger log = Logger.getLogger(CallbackTestClient.class);
  
     public static final String RESPONSE_VALUE = "This is the return to SampleInvocationHandler invocation";
  
     
     public void testPush1Client1Connector2Handlers() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
        CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client = new Client(locator);
        client.connect();
        Connector connector = null;
  
        try
        {
           String callbackLocatorURI = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator = new InvokerLocator(callbackLocatorURI);
           connector = setupServer(callbackLocator);
           client.addListener(callbackHandler1, callbackLocator);
           client.addListener(callbackHandler2, callbackLocator);
           client.invoke("Do something", null);
           client.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           int count = callbackHandler1.getCallbackCount();
           assertEquals(2, count);
           count = callbackHandler2.getCallbackCount();
           assertEquals(2, count);
        }
        finally
        {
           if(client != null)
           {
              // remove callback handler from server
              client.removeListener(callbackHandler1);
              client.removeListener(callbackHandler2);
              client.disconnect();
           }
           teardownServer(connector);
        }
     }
     
     public void testPush1Client2Connectors1Handler() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client = new Client(locator);
        client.connect();
        Connector connector1 = null;
        Connector connector2 = null;
  
        try
        {
           String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
           connector1 = setupServer(callbackLocator1);
           client.addListener(callbackHandler, callbackLocator1);
           String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
           connector2 = setupServer(callbackLocator2);
           client.addListener(callbackHandler, callbackLocator2);
           client.invoke("Do something", null);
           client.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           int count = callbackHandler.getCallbackCount();
           assertEquals(4, count);
        }
        finally
        {
           if(client != null)
           {
              // remove callback handler from server
              client.removeListener(callbackHandler);
              client.disconnect();
           }
           teardownServer(connector1);
           teardownServer(connector2);
        }
     }
  
     public void testPush1Client2Connectors2Handlers() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
        CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client = new Client(locator);
        client.connect();
        Connector connector1 = null;
        Connector connector2 = null;
  
        try
        {
           String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
           connector1 = setupServer(callbackLocator1);
           client.addListener(callbackHandler1, callbackLocator1);
           String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
           connector2 = setupServer(callbackLocator2);
           client.addListener(callbackHandler2, callbackLocator2);
           client.invoke("Do something", null);
           client.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           int count = callbackHandler1.getCallbackCount();
           assertEquals(2, count);
           count = callbackHandler2.getCallbackCount();
           assertEquals(2, count);
        }
        finally
        {
           if(client != null)
           {
              // remove callback handler from server
              client.removeListener(callbackHandler1);
              client.removeListener(callbackHandler2);
              client.disconnect();
           }
           teardownServer(connector1);
           teardownServer(connector2);
        }
     }
     
     public void testPush2Clients1Connector1Handler() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client1 = new Client(locator);
        client1.connect();
        Client client2 = new Client(locator);
        client2.connect();
        Connector connector = null;
  
        try
        {
           String callbackLocatorURI = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator = new InvokerLocator(callbackLocatorURI);
           connector = setupServer(callbackLocator);
           log.info("created callback server: " + connector.getLocator());
           client1.addListener(callbackHandler, callbackLocator);
           client2.addListener(callbackHandler, callbackLocator);
           client1.invoke("Do something", null);
           client2.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           // The CallbackHandler should be registered just once.
           int count = callbackHandler.getCallbackCount();
           assertEquals(2, count);
        }
        finally
        {
           if(client1 != null)
           {
              // remove callback handler from server
              client1.removeListener(callbackHandler);
              client1.disconnect();
           }
           teardownServer(connector);
        }
     }
     
     public void testPush2Clients1Connector2Handlers() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
        CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client1 = new Client(locator);
        client1.connect();
        Client client2 = new Client(locator);
        client2.connect();
        Connector connector = null;
  
        try
        {
           String callbackLocatorURI = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator = new InvokerLocator(callbackLocatorURI);
           connector = setupServer(callbackLocator);
           client1.addListener(callbackHandler1, callbackLocator);
           client2.addListener(callbackHandler2, callbackLocator);
           client1.invoke("Do something", null);
           client2.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           int count = callbackHandler1.getCallbackCount();
           assertEquals(2, count);
           count = callbackHandler1.getCallbackCount();
           assertEquals(2, count);
        }
        finally
        {
           Field field = AbstractInvoker.class.getDeclaredField("localServerLocators");
           field.setAccessible(true);
           
           if(client1 != null)
           {
              ClientInvoker invoker = client1.getInvoker();
              Map localServerLocators = (Map) field.get(invoker);
              assertEquals(2, localServerLocators.size());
              client1.removeListener(callbackHandler1);
              assertEquals(1, localServerLocators.size());
              client1.removeListener(callbackHandler2);
              // client1 shouldn't be able to remove callbackHandler2.
              assertEquals(1, localServerLocators.size());
              client1.disconnect();
           }
           if (client2 != null)
           {
              ClientInvoker invoker = client2.getInvoker();
              Map localServerLocators = (Map) field.get(invoker);
              assertEquals(1, localServerLocators.size());
              client2.removeListener(callbackHandler2);
              assertEquals(0, localServerLocators.size());
              client2.disconnect();
           }
           teardownServer(connector);
        }
     }
     
     public void testPush2Clients2Connectors1Handler() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client1 = new Client(locator);
        client1.connect();
        Client client2 = new Client(locator);
        client2.connect();
        Connector connector1 = null;
        Connector connector2 = null;
  
        try
        {
           String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
           connector1 = setupServer(callbackLocator1);
           String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
           connector2 = setupServer(callbackLocator2);
           client1.addListener(callbackHandler, callbackLocator1);
           client2.addListener(callbackHandler, callbackLocator2);
           client1.invoke("Do something", null);
           client2.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           int count = callbackHandler.getCallbackCount();
           assertEquals(4, count);
        }
        finally
        {
           Field field = AbstractInvoker.class.getDeclaredField("localServerLocators");
           field.setAccessible(true);
           
           if(client1 != null)
           {
              ClientInvoker invoker = client1.getInvoker();
              Map localServerLocators = (Map) field.get(invoker);
              assertEquals(2, localServerLocators.size());
              client1.removeListener(callbackHandler);
              // callbackHandler should still be registered with connector2.
              assertEquals(1, localServerLocators.size());
              client1.disconnect();
           }
           if (client2 != null)
           {
              ClientInvoker invoker = client2.getInvoker();
              Map localServerLocators = (Map) field.get(invoker);
              assertEquals(1, localServerLocators.size());
              client2.removeListener(callbackHandler);
              assertEquals(0, localServerLocators.size());
              client2.disconnect();
           }
           teardownServer(connector1);
           teardownServer(connector2);
        }
     }
     
     public void testPush2Clients2Connectors2Handlers() throws Throwable
     {
        log.info("entering " + getName());
        CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
        CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
        InvokerLocator locator = new InvokerLocator(locatorURI);
        Client client1 = new Client(locator);
        client1.connect();
        Client client2 = new Client(locator);
        client2.connect();
        Connector connector1 = null;
        Connector connector2 = null;
  
        try
        {
           String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
           connector1 = setupServer(callbackLocator1);
           String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
           InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
           connector2 = setupServer(callbackLocator2);
           client1.addListener(callbackHandler1, callbackLocator1);
           client2.addListener(callbackHandler2, callbackLocator2);
           client1.invoke("Do something", null);
           client2.invoke("Do something else", null);
           
           // need to wait for brief moment so server can callback
           Thread.sleep(5000);
  
           int count = callbackHandler1.getCallbackCount();
           assertEquals(2, count);
           count = callbackHandler1.getCallbackCount();
           assertEquals(2, count);
        }
        finally
        {
           Field field = AbstractInvoker.class.getDeclaredField("localServerLocators");
           field.setAccessible(true);
           
           if(client1 != null)
           {
              ClientInvoker invoker = client1.getInvoker();
              Map localServerLocators = (Map) field.get(invoker);
              assertEquals(2, localServerLocators.size());
              client1.removeListener(callbackHandler1);
              assertEquals(1, localServerLocators.size());
              client1.removeListener(callbackHandler2);
              // client1 shouldn't be able to remove callbackHandler2.
              assertEquals(1, localServerLocators.size());
              client1.disconnect();
           }
           if (client2 != null)
           {
              ClientInvoker invoker = client2.getInvoker();
              Map localServerLocators = (Map) field.get(invoker);
              assertEquals(1, localServerLocators.size());
              client2.removeListener(callbackHandler2);
              assertEquals(0, localServerLocators.size());
              client2.disconnect();
           }
           teardownServer(connector1);
           teardownServer(connector2);
        }
     }
     
     
     public Connector setupServer(InvokerLocator locator) throws Exception
     {
        log.info("Starting remoting server with locator uri of: " + locator);
        try
        {
           Connector connector = new Connector();
           connector.setInvokerLocator(locator.getLocatorURI());
           connector.start();
           log.info("started callback Connector: " + connector.getLocator());
           
           CallbackTestClient.SampleInvocationHandler invocationHandler = new CallbackTestClient.SampleInvocationHandler();
           // first parameter is sub-system name.  can be any String value.
           connector.addInvocationHandler("sample", invocationHandler);
           return connector;
        }
        catch(Exception e)
        {
           log.error("Error starting callback server", e);
           throw e;
        }
     }
     
     public void teardownServer(Connector connector)
     {
        if(connector != null)
        {
           connector.stop();
           connector.destroy();
        }
     }
  
     /**
      * Simple invocation handler implementation.
      */
     public static class SampleInvocationHandler implements ServerInvocationHandler
     {
  
        private List listeners = new ArrayList();
  
  
        /**
         * called to handle a specific invocation
         *
         * @param invocation
         * @return
         * @throws Throwable
         */
        public Object invoke(InvocationRequest invocation) throws Throwable
        {
           // Just going to return static string as this is just simple example code.
  
           // Will also fire callback to listeners if they were to exist using
           // simple invocation request.
           Callback callback = new Callback("This is the payload of callback invocation.");
           Iterator itr = listeners.iterator();
           while(itr.hasNext())
           {
              InvokerCallbackHandler callbackHandler = (InvokerCallbackHandler) itr.next();
              try
              {
                 callbackHandler.handleCallback(callback);
              }
              catch(HandleCallbackException e)
              {
                 e.printStackTrace();
              }
           }
  
           return RESPONSE_VALUE;
  
        }
  
        /**
         * Adds a callback handler that will listen for callbacks from
         * the server invoker handler.
         *
         * @param callbackHandler
         */
        public void addListener(InvokerCallbackHandler callbackHandler)
        {
           listeners.add(callbackHandler);
        }
  
        /**
         * Removes the callback handler that was listening for callbacks
         * from the server invoker handler.
         *
         * @param callbackHandler
         */
        public void removeListener(InvokerCallbackHandler callbackHandler)
        {
           listeners.remove(callbackHandler);
        }
  
        /**
         * set the mbean server that the handler can reference
         *
         * @param server
         */
        public void setMBeanServer(MBeanServer server)
        {
           // NO OP as do not need reference to MBeanServer for this handler
        }
  
        /**
         * set the invoker that owns this handler
         *
         * @param invoker
         */
        public void setInvoker(ServerInvoker invoker)
        {
           // NO OP as do not need reference back to the server invoker
        }
  
     }
  
  
     public class CallbackHandler implements InvokerCallbackHandler
     {
        private Callback callback;
        private int callbackNumber = 0;
  
        /**
         * Will take the callback message and send back to client.
         * If client locator is null, will store them till client polls to get them.
         *
         * @param callback
         * @throws org.jboss.remoting.callback.HandleCallbackException
         *
         */
        public void handleCallback(Callback callback) throws HandleCallbackException
        {
           callbackNumber++;
           this.callback = callback;
           System.out.println("Received callback value of: " + callback.getCallbackObject());
           System.out.println("Received callback handle object of: " + callback.getCallbackHandleObject());
           System.out.println("Received callback server invoker of: " + callback.getServerLocator());
        }
  
        public Callback getCallback()
        {
           return callback;
        }
  
        public int getCallbackCount()
        {
           return callbackNumber;
        }
     }
  
  }
  
  
  
  1.1      date: 2006/12/07 03:00:53;  author: rsigal;  state: Exp;JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestCase.java
  
  Index: CallbackTestCase.java
  ===================================================================
  /*
  * JBoss, a division of Red Hat
  * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  * by the @authors tag. See the copyright.txt 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.test.remoting.callback.multiple;
  
  import org.jboss.jrunit.harness.TestDriver;
  
  /**
   * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
   */
  public class CallbackTestCase extends TestDriver
  {
     public void declareTestClasses()
     {
        addTestClasses(CallbackTestClient.class.getName(),
                       1,
                       CallbackTestServer.class.getName());
     }
  
     /**
      * How long to wait for test results to be returned from the client(s).  If goes longer than the
      * specified limit, will throw an exception and kill the running test cases.  Default value is
      * RESULTS_TIMEOUT.
      *
      * @return
      */
     protected long getResultsTimeout()
     {
        return 600000;
     }
  
     /**
      * How long for the server test case to wait for tear down message.  If exceeds timeout,
      * will throw exception.  The default value is TEARDOWN_TIMEOUT.
      *
      * @return
      */
     protected long getTearDownTimeout()
     {
        return 600000;
     }
  
     /**
      * How long to allow each of the test cases to run their tests.  If exceeds this timeout
      * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
      *
      * @return
      */
     protected long getRunTestTimeout()
     {
        return 600000;
     }
  
  }
  
  


From ron_sigal at yahoo.com  Wed Dec  6 22:16:39 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 22:16:39 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/transport  ...
Message-ID: <E1Gs9kV-0007JT-BD@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 22:16:39

  Modified:    src/main/org/jboss/remoting/transport  ClientInvoker.java
  Log:
  JBREM-622:  Changed addClientLocator() and getClientLocators() to take sessionId parameter.
  
  Revision  Changes    Path
  1.9       +5 -3      JBossRemoting/src/main/org/jboss/remoting/transport/ClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClientInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/ClientInvoker.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ClientInvoker.java	9 Nov 2006 21:35:24 -0000	1.8
  +++ ClientInvoker.java	7 Dec 2006 03:16:39 -0000	1.9
  @@ -48,11 +48,12 @@
       * of callbacks to receive (pull or push).  Set to null to poll for callback messages.
       * This can also be used to receive callbacks using another transport and subsystem,
       * if desired.
  -    *
  +    * @param sessionId
       * @param locator
  +    *
       * @return id for callback handler and locator combination
       */
  -   public String addClientLocator(InvokerCallbackHandler callbackhandler, InvokerLocator locator);
  +   public String addClientLocator(String sessionId, InvokerCallbackHandler callbackhandler, InvokerLocator locator);
   
      /**
       * Gets the client locator.  This locator will be used by the server side
  @@ -64,10 +65,11 @@
   
      /**
       * Gets list of AbstractInvoker.CallbackLocatorHolder containing listener id and locator
  +    * @param sessionId TODO
       * @param handler
       * @return
       */
  -   public List getClientLocators(InvokerCallbackHandler handler);
  +   public List getClientLocators(String sessionId, InvokerCallbackHandler handler);
   
      /**
       * Gets SocketFactory used to connect to ServerInvoker.
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 22:17:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 22:17:54 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1714 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gs9li-0007Jh-EW@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-06 22:17:47 -0500 (Wed, 06 Dec 2006)
New Revision: 1714

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Fixing clustering CF & adding server redirect logic into HAAspect

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -25,9 +25,7 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
-
 import javax.jms.JMSException;
-
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
@@ -37,6 +35,7 @@
 import org.jboss.jms.client.delegate.ClientConsumerDelegate;
 import org.jboss.jms.client.delegate.ClientProducerDelegate;
 import org.jboss.jms.client.delegate.ClientSessionDelegate;
+import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
@@ -47,7 +46,6 @@
 import org.jboss.jms.client.state.ProducerState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.destination.JBossDestination;
-import org.jboss.jms.server.remoting.MetaDataConstants;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -103,6 +101,8 @@
       else
       {
          //Non clustered
+
+         log.info("Assumed non clustered");
          
          return invocation.invokeNext();
       }
@@ -123,15 +123,31 @@
    private synchronized ClientConnectionFactoryDelegate[] getServers(Invocation invocation)
    {
       if (delegates == null)
-      {         
+      {
+         log.info("Looking for delegates");
          SimpleMetaData metaData = invocation.getMetaData();
-         
-         delegates = (ClientConnectionFactoryDelegate[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES);
-         
+
+         //delegates = (ClientConnectionFactoryDelegate[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES);
+
+         MethodInvocation methodInvoke = (MethodInvocation)invocation;
+         //delegates = (ClientConnectionFactoryDelegate[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES);
+
+
+         // this is a hack, but I couldn't get this working through metaData
+         // TODO: FIX THIS! metaData should contain CF_DELEGATES
+         Object target = methodInvoke.getTargetObject();
+         if (target instanceof ClusteredClientConnectionFactoryDelegate)
+         {
+            delegates = ((ClusteredClientConnectionFactoryDelegate)target).getDelegates();
+         }
+
+
          if (delegates != null)
-         {          
-            failoverIndexes = (int[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES);
-            
+         {
+            //TODO: Fix this! metadata should contain CF_FAILOVER_INDEXES
+            //failoverIndexes = (int[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES);
+            failoverIndexes = (int[])((ClusteredClientConnectionFactoryDelegate)target).getFailoverIndexes();
+
             if (failoverIndexes == null)
             {
                throw new IllegalStateException("Cannot find failoverIndexes!");
@@ -145,6 +161,7 @@
    private ClientConnectionDelegate createConnection(ClientConnectionFactoryDelegate cf, String username, String password)
       throws Exception
    {
+      log.info("createConnection");
       ClientConnectionDelegate connDelegate = (ClientConnectionDelegate)cf.createConnectionDelegate(username, password);
       
       //Add a connection listener
@@ -161,11 +178,11 @@
    private void handleFailure(ClientConnectionDelegate failedConnection) throws Exception
    {
       ClientConnectionFactoryDelegate newCF = getAlternateDelegate(failedConnection);
-      
+
       //TODO implement client side valve to prevent invocations occurring whilst failover is occurring
       
       ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
-      
+
       ClientConnectionDelegate newConnection = createConnection(newCF, state.getUser(), state.getPassword());
       
       try
@@ -181,7 +198,7 @@
       }
    }
    
-   private ClientConnectionFactoryDelegate getAlternateDelegate(ClientConnectionDelegate currentDelegate)
+   private ClientConnectionFactoryDelegate getAlternateDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
    {
       //We need to choose which delegate to fail over to
       
@@ -189,13 +206,6 @@
       //The fail over delegate for delegates[i] is given by
       //delegates[failoverIndexes[i]]
       
-      //The technique (TODO) is to try that server. There is a possibility the expected failover server
-      //is not actually the real failover server, e.g. since the client side array and server side state
-      //are not totally in synch.
-      //In this case we need to implement hopping, so the incorrect server redirects us to the correct server.
-      //This may require several hops to get the right server (since another failure(s) can occur when the hop is
-      //happening!)
-      
       ConnectionState currentState = (ConnectionState)((DelegateSupport)currentDelegate).getState();
       
       String currentLocator =
@@ -229,7 +239,33 @@
          throw new IllegalStateException("Cannot failover connection since no servers to fail over onto");
       }      
 
-      return delegates[failoverIndexes[local]];
+      ClientConnectionFactoryDelegate delegateFound = delegates[failoverIndexes[local]];
+
+
+      // Redirect connection routine.
+      // Verify the failureMap on the server and if out of sync find the correct delegate
+      
+      int failoverNode = delegateFound.getFailoverNode(currentState.getServerID());
+      if (failoverNode!=delegateFound.getServerId())
+      {
+         delegateFound = null;
+         for (int i = 0; i < delegates.length; i++)
+         {
+            if (delegates[i].getServerId() == failoverNode)
+            {
+               delegateFound = delegates[i];
+            }
+         }
+
+         if (delegateFound==null)
+         {
+            throw new IllegalStateException("Cannot find failover node on current map for nodeId=" + failoverNode);
+         }
+
+      }
+
+      return delegateFound;
+
    }
    
    private void failover(ClientConnectionDelegate failedConnection, ClientConnectionDelegate newConnection) throws Exception
@@ -244,6 +280,9 @@
 
       failedState.copy(newState);
 
+      // this is necessary so the connection will start "talking" to the new server instead
+      failedState.setRemotingConnection(newState.getRemotingConnection());
+
       if (failedState.getClientID() != null)
       {
          newConnection.setClientID(failedState.getClientID());

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -23,9 +23,7 @@
 
 import java.util.HashMap;
 import java.util.Map;
-
 import javax.jms.JMSException;
-
 import org.jboss.aop.Advised;
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.Invocation;
@@ -70,6 +68,9 @@
    //This data is needed in order to create a connection
    protected String serverLocatorURI;
    protected Version serverVersion;
+
+   // This property is used on redirect on failover logic (verify if a new delegate could be used during a failover)
+   protected int serverId;
    protected boolean clientPing;
    
    private transient boolean trace;
@@ -101,12 +102,13 @@
 
    // Constructors --------------------------------------------------
 
-   public ClientConnectionFactoryDelegate(int objectID, String serverLocatorURI,
+   public ClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
                                           Version serverVersion,
                                           boolean clientPing)
    {
       super(objectID);
 
+      this.serverId = serverId;
       this.serverLocatorURI = serverLocatorURI;
       this.serverVersion = serverVersion;
       this.clientPing = clientPing;
@@ -147,6 +149,16 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
+   public int getFailoverNode(int node) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   public boolean stillAround(int node) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
    // Public --------------------------------------------------------
 
    public synchronized Object invoke(Invocation invocation) throws Throwable
@@ -157,7 +169,7 @@
       if (trace) { log.trace("invoking " + methodName + " on server"); }
 
       SimpleMetaData md = mi.getMetaData();
-      
+
       md.addMetaData(Dispatcher.DISPATCHER,
                      Dispatcher.OID,
                      new Integer(id),
@@ -174,19 +186,19 @@
        * difficulties in knowing when to close it.
        */
 
-      Client client; 
-      
+      Client client;
+
       JMSRemotingConnection remotingConnection = null;
 
       if ("createConnectionDelegate".equals(methodName))
       {
          // Create a new connection
-         
+
          remotingConnection = new JMSRemotingConnection(serverLocatorURI, clientPing);
          remotingConnection.start();
-         
+
          client = remotingConnection.getInvokingClient();
-         
+
          md.addMetaData(MetaDataConstants.JMS,
                         MetaDataConstants.REMOTING_SESSION_ID,
                         client.getSessionId(),
@@ -200,42 +212,42 @@
       else
       {
          //getClientAOPConfig or getIDBlock
-         
+
          // Create a client - make sure pinging is off
-         
+
          Map configuration = new HashMap();
 
          configuration.put(Client.ENABLE_LEASE, String.valueOf(false));
-         
-         client = new Client(new InvokerLocator(serverLocatorURI), configuration);     
-         
+
+         client = new Client(new InvokerLocator(serverLocatorURI), configuration);
+
          client.setSubsystem(ServerPeer.REMOTING_JMS_SUBSYSTEM);
-         
-         client.connect();         
-         
+
+         client.connect();
+
          client.setMarshaller(new JMSWireFormat());
-         client.setUnMarshaller(new JMSWireFormat());         
+         client.setUnMarshaller(new JMSWireFormat());
       }
 
       //What version should we use for invocations on this connection factory?
       Version version = getVersionToUse(serverVersion);
       byte v = version.getProviderIncrementingVersion();
-      
+
       MessagingMarshallable request = new MessagingMarshallable(v, mi);
-      
+
       MessagingMarshallable response;
 
       try
       {
          response = (MessagingMarshallable)client.invoke(request, null);
-         
+
          if (trace) { log.trace("got server response for " + methodName); }
       }
       catch (Throwable t)
       {
          //If we were invoking createConnectionDelegate and failure occurs then we need to clear
          //up the JMSRemotingConnection
-         
+
          if (remotingConnection != null)
          {
             try
@@ -246,25 +258,25 @@
             {
             }
          }
-         
+
          throw t;
       }
 
       Object ret = response.getLoad();
-      
+
       if (remotingConnection != null)
       {
          // It was a call to createConnectionDelegate - set the remoting connection to use
          ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)ret;
-         
+
          //We set the version for the connection and the remoting connection on the meta-data
          //this is so the StateCreationAspect can pick it up
-         
+
          SimpleMetaData metaData = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
-         
+
          metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION,
                               remotingConnection, PayloadKey.TRANSIENT);
-         
+
          metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
                               version, PayloadKey.TRANSIENT);
 
@@ -284,6 +296,11 @@
       return serverLocatorURI;
    }
 
+   public int getServerId()
+   {
+      return serverId;
+   }
+
    // Protected -----------------------------------------------------
 
    protected Client getClient()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -59,10 +59,10 @@
 
    // Constructors --------------------------------------------------
 
-   public ClusteredClientConnectionFactoryDelegate(int objectID, String serverLocatorURI,
+   public ClusteredClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
                                                    Version serverVersion, boolean clientPing)
    {
-      super(objectID, serverLocatorURI, serverVersion, clientPing);
+      super(objectID, serverId, serverLocatorURI, serverVersion, clientPing);
    }
 
    // DelegateSupport overrides -------------------------------------
@@ -105,6 +105,12 @@
       return delegates;
    }
 
+   /** As metadata is not working, I'm exposing this temporarily */
+   public int[] getFailoverIndexes()
+   {
+      return failoverIndexes;
+   }
+
    public String toString()
    {
       return "ClusteredClientConnectionFactoryDelegate[" + id + "] with delegates.length = " + (delegates==null?"null":Integer.toString(delegates.length));

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -21,16 +21,15 @@
   */
 package org.jboss.jms.server;
 
+import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
 import java.io.ByteArrayOutputStream;
 import java.io.InputStream;
 import java.net.URL;
 import java.util.Map;
 import java.util.Set;
-
 import javax.management.Attribute;
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
-
 import org.jboss.aop.AspectXmlLoader;
 import org.jboss.jms.server.connectionfactory.ConnectionFactoryJNDIMapper;
 import org.jboss.jms.server.connectionmanager.SimpleConnectionManager;
@@ -58,8 +57,6 @@
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
 
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
-
 /**
  * A JMS server peer.
  *
@@ -591,6 +588,16 @@
    {
       return jmsUserManager;
    }
+
+   public Replicator getReplicator() throws Exception
+   {
+      PostOffice postOffice = getQueuePostOfficeInstance();
+      if (!(postOffice instanceof Replicator))
+      {
+         throw new  IllegalAccessException("This operations is only legal on clustering configurations");
+      }
+      return (Replicator)postOffice;
+   }
    
    public PostOffice getQueuePostOfficeInstance() throws Exception
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -127,14 +127,15 @@
          {                                             
             //Replicator might still be null since we might be deploying a clustered cf in a non clustered
             //post office (which is ok)
-            delegate = new ClusteredClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
+            delegate = new ClusteredClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(), locatorURI, version, clientPing);
          }
       }
       
       if (delegate == null)
       {
          //Local
-         delegate = new ClientConnectionFactoryDelegate(id, locatorURI, version, clientPing);
+         delegate = new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
+                                        locatorURI, version, clientPing);
       }
 
       log.trace("Adding delegates factory " + uniqueName + " pointing to " + delegate);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -22,7 +22,6 @@
 package org.jboss.jms.server.endpoint;
 
 import javax.jms.JMSException;
-
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.messaging.core.plugin.IdBlock;
 
@@ -44,5 +43,25 @@
    byte[] getClientAOPConfig() throws JMSException;
 
    IdBlock getIdBlock(int size) throws JMSException;
+
+   /** Return the node that should take over a given node */
+   int getFailoverNode(int node) throws JMSException;
+
+   /**
+    * This method will be used by HAAspect interceptor to ask other servers if
+    * a given server still around.
+    *
+    * This will be useful on retries from client2server communication. If a communication exception happened
+    * on the communication with a given server we will check with other peers to confirm if the server really
+    * diead before restabilishing a connection.
+    *
+    * This method is not very useful on leasing but it will be usefull on Exception listeners.
+    *
+    * Say, if a communication exception happens on an interceptor, the interceptor could ask other servers
+    * about their current membership and decide about a retry or a failover. 
+    *
+    * TODO: a better name for this method?
+    * */
+   boolean stillAround(int node) throws JMSException;
 }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -22,7 +22,6 @@
 package org.jboss.jms.server.endpoint;
 
 import javax.jms.JMSException;
-
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.server.ServerPeer;
@@ -137,7 +136,36 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " createConnectionDelegate");
       }
    }
-   
+
+
+   public int getFailoverNode(int node) throws JMSException
+   {
+      try
+      {
+         ServerPeer peer = (ServerPeer )serverPeer.getInstance();
+         return peer.getReplicator().getFailoverNodeID(node);
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " getFailoverNode");
+      }
+   }
+
+
+   // TODO: Better name
+   public boolean stillAround(int node) throws JMSException
+   {
+      try
+      {
+         ServerPeer peer = (ServerPeer )serverPeer.getInstance();
+         return peer.getReplicator().stillAround(node);
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " stillAround");
+      }
+   }
+
    public byte[] getClientAOPConfig() throws JMSException
    {
       try

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -22,7 +22,6 @@
 package org.jboss.jms.server.endpoint.advised;
 
 import javax.jms.JMSException;
-
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint;
 import org.jboss.messaging.core.plugin.IdBlock;
@@ -74,6 +73,17 @@
       return endpoint.getIdBlock(size);
    }
 
+   public int getFailoverNode(int node) throws JMSException
+   {
+      return endpoint.getFailoverNode(node);
+   }
+
+   // TODO: find a better name... look at javadoc on ConnectionFactoryInterface
+   public boolean stillAround(int node) throws JMSException
+   {
+      return endpoint.stillAround(node);
+   }
+
    // AdvisedSupport override ---------------------------------------
 
    public Object getEndpoint()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -79,4 +79,18 @@
     *         returns the original nodeID. 
     */
    int getFailoverNodeID(int nodeID);
+
+
+   /**
+    *
+    * This method will be used by HAAspect interceptor to ask other servers if
+    * a given server still around.
+    *
+    * This will be useful on retries from client2server communication. If a communication exception happened
+    * on the communication with a given server we will check with other peers to confirm if the server really
+    * diead before restabilishing a connection
+    *
+    * TODO: a better name for this method?
+    * */
+   public boolean stillAround(int nodeId);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -608,6 +608,15 @@
       }
    }
 
+   // TODO: find a better name
+   public boolean stillAround(int nodeId)
+   {
+      synchronized (failoverMap)
+      {
+         return failoverMap.get(new Integer(nodeId))!=null;
+      }
+   }
+
    // Replicator implementation --------------------------------------------------------------------------
    
    public Map get(Serializable key) throws Exception

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-06 22:37:53 UTC (rev 1713)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-07 03:17:47 UTC (rev 1714)
@@ -22,10 +22,22 @@
 
 package org.jboss.test.messaging.jms.clustering;
 
+import javax.jms.Destination;
+import javax.jms.Message;
 import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
 import javax.jms.TextMessage;
+import javax.jms.Topic;
+import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.jms.client.JBossMessageConsumer;
+import org.jboss.jms.client.JBossSession;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
+import org.jboss.jms.client.state.ConsumerState;
+import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.tools.ServerManagement;
 
@@ -53,146 +65,145 @@
 
    // Public --------------------------------------------------------
 
-   public void testConnectionFactoryConnect() throws Exception
-   {
-      try
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         ClusteredClientConnectionFactoryDelegate delegate =
-                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         log.info ("number of delegates = " + delegate.getDelegates().length);
-         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-
-         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         assertEquals(3, delegate.getDelegates().length);
-
-
-         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
-         ServerManagement.stop(2,true);
-
-         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
-
-         factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         assertEquals(2, delegate.getDelegates().length);
-      }
-      finally
-      {
-         ServerManagement.start("all", 2);
-      }
-
-
-   }
-
-
-//   public void testTopicSubscriber() throws Exception
+//   public void testConnectionFactoryConnect() throws Exception
 //   {
 //      try
 //      {
-//         log.info("++testTopicSubscriber");
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         log.info ("number of delegates = " + delegate.getDelegates().length);
+//         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
 //
-//         log.info(">>Lookup Queue");
-//         Destination destination = (Destination) ic1.lookup("topic/testDistributedTopic");
+//         delegate.init();
 //
-//         log.info("Creating connection server1");
-//         JBossConnection conn = (JBossConnection) cf1.createConnection();
-//         conn.setClientID("testClient");
-//         conn.start();
+//         for (int i = 0; i < 3; i++)
+//         {
+//            int failNode = delegate.getDelegates()[0].getFailoverNode(i);
+//            log.info("Failover node for server" + i + " = " + failNode);
+//            log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
 //
-//         JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
-//         ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
-//         SessionState sessionState = (SessionState) clientSessionDelegate.getState();
-//
-//         MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
-//         JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
-//
-//         org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
-//         ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
-//
-//         log.info("subscriptionName=" + consumerState.getSubscriptionName());
-//
-//
-//         log.info(">>Creating Producer");
-//         MessageProducer producer = session.createProducer(destination);
-//         log.info(">>creating Message");
-//         Message message = session.createTextMessage("Hello Before");
-//         log.info(">>sending Message");
-//         producer.send(message);
-//         session.commit();
-//
-//         receiveMessage("consumerHA", consumerHA, true, false);
-//
-//         session.commit();
-//         //if (true) return;
-//
-//         Object txID = sessionState.getCurrentTxId();
-//
-//         producer.send(session.createTextMessage("Hello again before failover"));
-//
-//         ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
-//
-//         JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//
-//         log.info(">>Creating alternate connection");
-//         JBossConnection conn2 = (JBossConnection) cf2.createConnection();
-//         log.info("NewConnectionCreated=" + conn2);
-//
-//         log.info(">>Failling over");
-//         assertSame(originalRemoting, delegate.getRemotingConnection());
-//         conn.getDelegate().failOver(conn2.getDelegate());
-//
-//
-//
-//         try
-//         {
-//            originalRemoting.stop();
-//         } catch (Throwable throwable)
-//         {
-//            throwable.printStackTrace();
+//            assertEquals("Server1 should have the same failoverMapping",
+//                         failNode, delegate.getDelegates()[1].getFailoverNode(i));
+//            assertEquals("Server2 should have the same failoverMapping",
+//                         failNode, delegate.getDelegates()[2].getFailoverNode(i));
 //         }
 //
-//         ServerManagement.stop(0, false);
+//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         assertEquals(3, delegate.getDelegates().length);
 //
-//         assertNotSame(originalRemoting, delegate.getRemotingConnection());
 //
-//         //System.out.println("Kill server1"); Thread.sleep(10000);
+//         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
+//         ServerManagement.stop(2,true);
 //
-//         message = session.createTextMessage("Hello After");
-//         log.info(">>Sending new message");
-//         producer.send(message);
+//         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
 //
-//         assertEquals(txID, sessionState.getCurrentTxId());
-//         System.out.println("TransactionID on client = " + txID);
-//         log.info(">>Final commit");
+//         factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 //
-//         /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//          connSecondServer.start();
-//          JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//          MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
-//
-//         session.commit();
-//
-//         /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-//        receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-//        receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
-//
-//         log.info("Calling alternate receiver");
-//         receiveMessage("consumerHA", consumerHA, true, false);
-//         receiveMessage("consumerHA", consumerHA, true, false);
-//         receiveMessage("consumerHA", consumerHA, true, true);
-//
-//
-//         session.commit();
-//
+//         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         assertEquals(2, delegate.getDelegates().length);
 //      }
 //      finally
 //      {
-//         // restart the server as it was probably stopped (tearDown will need that)
-//         ServerManagement.start("all", 0, true);
+//         ServerManagement.start("all", 2);
 //      }
+//
+//
 //   }
+
+
+   public void testTopicSubscriber() throws Exception
+   {
+      try
+      {
+         log.info("++testTopicSubscriber");
+
+
+         JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf1;
+         assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
+
+         log.info(">>Lookup Queue");
+         Destination destination = (Destination) ic1.lookup("topic/testDistributedTopic");
+
+         log.info("Creating connection server1");
+         JBossConnection conn = (JBossConnection) cf1.createConnection();
+         conn.setClientID("testClient");
+         conn.start();
+
+         JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+         ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
+         SessionState sessionState = (SessionState) clientSessionDelegate.getState();
+
+         MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
+         JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
+
+         org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
+         ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
+
+         log.info("subscriptionName=" + consumerState.getSubscriptionName());
+
+
+         log.info(">>Creating Producer");
+         MessageProducer producer = session.createProducer(destination);
+         log.info(">>creating Message");
+         Message message = session.createTextMessage("Hello Before");
+         log.info(">>sending Message");
+         producer.send(message);
+         session.commit();
+
+         receiveMessage("consumerHA", consumerHA, true, false);
+
+         session.commit();
+         //if (true) return;
+
+         Object txID = sessionState.getCurrentTxId();
+
+         producer.send(session.createTextMessage("Hello again before failover"));
+
+         ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
+
+         ServerManagement.stop(0, false);
+
+         Thread.sleep(25000);
+
+         //System.out.println("Kill server1"); Thread.sleep(10000);
+
+         message = session.createTextMessage("Hello After");
+         log.info(">>Sending new message");
+         producer.send(message);
+
+         assertEquals(txID, sessionState.getCurrentTxId());
+         System.out.println("TransactionID on client = " + txID);
+         log.info(">>Final commit");
+
+         /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
+          connSecondServer.start();
+          JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
+          MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
+
+         session.commit();
+
+         /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+        receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+        receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
+
+         log.info("Calling alternate receiver");
+         receiveMessage("consumerHA", consumerHA, true, false);
+         receiveMessage("consumerHA", consumerHA, true, false);
+         receiveMessage("consumerHA", consumerHA, true, true);
+
+
+         session.commit();
+
+      }
+      finally
+      {
+         // restart the server as it was probably stopped (tearDown will need that)
+         ServerManagement.start("all", 0);
+      }
+   }
+
 //
 //   public void testQueueHA() throws Exception
 //   {



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 22:20:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 22:20:15 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1715 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gs9nz-0007LL-8M@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-06 22:20:14 -0500 (Wed, 06 Dec 2006)
New Revision: 1715

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
placing back a test

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-07 03:17:47 UTC (rev 1714)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-07 03:20:14 UTC (rev 1715)
@@ -65,54 +65,54 @@
 
    // Public --------------------------------------------------------
 
-//   public void testConnectionFactoryConnect() throws Exception
-//   {
-//      try
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         log.info ("number of delegates = " + delegate.getDelegates().length);
-//         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//
-//         delegate.init();
-//
-//         for (int i = 0; i < 3; i++)
-//         {
-//            int failNode = delegate.getDelegates()[0].getFailoverNode(i);
-//            log.info("Failover node for server" + i + " = " + failNode);
-//            log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
-//
-//            assertEquals("Server1 should have the same failoverMapping",
-//                         failNode, delegate.getDelegates()[1].getFailoverNode(i));
-//            assertEquals("Server2 should have the same failoverMapping",
-//                         failNode, delegate.getDelegates()[2].getFailoverNode(i));
-//         }
-//
-//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         assertEquals(3, delegate.getDelegates().length);
-//
-//
-//         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
-//         ServerManagement.stop(2,true);
-//
-//         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
-//
-//         factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         assertEquals(2, delegate.getDelegates().length);
-//      }
-//      finally
-//      {
-//         ServerManagement.start("all", 2);
-//      }
-//
-//
-//   }
+   public void testConnectionFactoryConnect() throws Exception
+   {
+      try
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         ClusteredClientConnectionFactoryDelegate delegate =
+                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         log.info ("number of delegates = " + delegate.getDelegates().length);
+         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
 
+         delegate.init();
 
+         for (int i = 0; i < 3; i++)
+         {
+            int failNode = delegate.getDelegates()[0].getFailoverNode(i);
+            log.info("Failover node for server" + i + " = " + failNode);
+            log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
+
+            assertEquals("Server1 should have the same failoverMapping",
+                         failNode, delegate.getDelegates()[1].getFailoverNode(i));
+            assertEquals("Server2 should have the same failoverMapping",
+                         failNode, delegate.getDelegates()[2].getFailoverNode(i));
+         }
+
+         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         assertEquals(3, delegate.getDelegates().length);
+
+
+         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
+         ServerManagement.stop(2,true);
+
+         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
+
+         factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         assertEquals(2, delegate.getDelegates().length);
+      }
+      finally
+      {
+         ServerManagement.start("all", 2);
+      }
+
+
+   }
+
+
    public void testTopicSubscriber() throws Exception
    {
       try



From ron_sigal at yahoo.com  Wed Dec  6 22:20:16 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 22:20:16 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gs9o0-0007Lq-63@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 22:20:16

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        AbstractInvoker.java
  Log:
  JBREM-622:  Stores InvokerCallbackHandlers keyed on sessionId + listenerId.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.12.4.4  +11 -6     JBossRemoting/src/main/org/jboss/remoting/AbstractInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/AbstractInvoker.java,v
  retrieving revision 1.12.4.3
  retrieving revision 1.12.4.4
  diff -u -b -r1.12.4.3 -r1.12.4.4
  --- AbstractInvoker.java	16 Nov 2006 17:57:02 -0000	1.12.4.3
  +++ AbstractInvoker.java	7 Dec 2006 03:20:16 -0000	1.12.4.4
  @@ -47,7 +47,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.12.4.3 $
  + * @version $Revision: 1.12.4.4 $
    */
   public abstract class AbstractInvoker implements Invoker
   {
  @@ -116,7 +116,7 @@
       *
       * @param locator
       */
  -   public String addClientLocator(InvokerCallbackHandler callbackhandler, InvokerLocator locator)
  +   public String addClientLocator(String sessionId, InvokerCallbackHandler callbackhandler, InvokerLocator locator)
      {
         String listenerId = null;
         synchronized(localServerLocators)
  @@ -140,6 +140,8 @@
            // if got this far, the entry does not exist, so need to add it and create a listener id
            CallbackHandlerHolder holder = new CallbackHandlerHolder(callbackhandler, locator);
            listenerId = new GUID().toString();
  +         if (sessionId != null)
  +            listenerId = sessionId + "+" + listenerId;
            localServerLocators.put(listenerId, holder);
         }
   
  @@ -166,7 +168,7 @@
         return locator;
      }
   
  -   public List getClientLocators(InvokerCallbackHandler handler)
  +   public List getClientLocators(String sessionId, InvokerCallbackHandler handler)
      {
         List holderList = new ArrayList();
         if(handler != null)
  @@ -177,9 +179,12 @@
               Iterator itr = entries.iterator();
               while(itr.hasNext())
               {
  -               Map.Entry entry = (Map.Entry)itr.next();
  -               String listenerId = (String)entry.getKey();
  -               CallbackHandlerHolder holder = (CallbackHandlerHolder)entry.getValue();
  +               Map.Entry entry = (Map.Entry) itr.next();
  +               String listenerId = (String) entry.getKey();
  +               String prefix = listenerId.substring(0, listenerId.indexOf('+'));
  +               if (!sessionId.equals(prefix))
  +                  continue;
  +               CallbackHandlerHolder holder = (CallbackHandlerHolder) entry.getValue();
                  InvokerCallbackHandler holderHandler = holder.getHandler();
                  if(holderHandler.equals(handler))
                  {
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 22:20:52 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 22:20:52 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gs9oa-0007NA-L9@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 22:20:52

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x Client.java
  Log:
  JBREM-622:  Conforms to change in AbstractInvoker, which stores InvokerCallbackHandlers keyed on sessionId
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.53.2.7  +30 -13    JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.53.2.6
  retrieving revision 1.53.2.7
  diff -u -b -r1.53.2.6 -r1.53.2.7
  --- Client.java	28 Nov 2006 20:30:23 -0000	1.53.2.6
  +++ Client.java	7 Dec 2006 03:20:52 -0000	1.53.2.7
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.53.2.6 $
  + * @version $Revision: 1.53.2.7 $
    */
   public class Client implements Externalizable
   {
  @@ -1035,7 +1035,7 @@
         {
            // is going to be push callbacks which means callback server locator involved.
            // will have to delegate to client invoker.
  -         String listenerId = invoker.addClientLocator(callbackhandler, callbackLocator);
  +         String listenerId = invoker.addClientLocator(sessionId, callbackhandler, callbackLocator);
   
            if (listenerId != null)
            {
  @@ -1157,18 +1157,32 @@
            if (callbackHandler != null)
            {
               // first need to see if is push or pull callback (i.e. does have locator associated with it)
  -            String listenerId = (String)listeners.remove(callbackHandler);
  +            String listenerId = (String)listeners.get(callbackHandler);
               if(listenerId != null)
               {
                  // have a pull callback handler
                  Map metadata = new HashMap();
                  metadata.put(LISTENER_ID_KEY, listenerId);
                  invoke(new InternalInvocation(InternalInvocation.REMOVELISTENER, null), metadata);
  +               
  +               // clean up callback poller if one exists
  +               CallbackPoller callbackPoller = (CallbackPoller) callbackPollers.remove(callbackHandler);
  +               if (callbackPoller != null)
  +               {
  +                  callbackPoller.stop();
  +               }
  +               
  +               listeners.remove(callbackHandler);
  +               
  +//               // have a pull callback handler
  +//               Map metadata = new HashMap();
  +//               metadata.put(LISTENER_ID_KEY, listenerId);
  +//               invoke(new InternalInvocation(InternalInvocation.REMOVELISTENER, null), metadata);
               }
               else
               {
                  // have a push callback handler
  -               List holderList = invoker.getClientLocators(callbackHandler);
  +               List holderList = invoker.getClientLocators(sessionId, callbackHandler);
                  if(holderList != null && holderList.size() > 0)
                  {
                     for(int x = 0; x < holderList.size(); x++)
  @@ -1179,6 +1193,9 @@
                        Map metadata = new HashMap();
                        metadata.put(LISTENER_ID_KEY, listenerId);
   
  +                     // now call target server to remove listener
  +                     invoke(new InternalInvocation(InternalInvocation.REMOVELISTENER, null), metadata);
  +                     
                        // call to callback server to remove listener
                        Client client = new Client(locator, subsystem);
                        client.setSessionId(getSessionId());
  @@ -1187,9 +1204,9 @@
                                                             new Object[]{callbackHandler}),
                                      metadata);
                        client.disconnect();
  -
  -                     // now call target server to remove listener
  -                     invoke(new InternalInvocation(InternalInvocation.REMOVELISTENER, null), metadata);
  +//
  +//                     // now call target server to remove listener
  +//                     invoke(new InternalInvocation(InternalInvocation.REMOVELISTENER, null), metadata);
   
                     }
                  }
  @@ -1223,12 +1240,12 @@
                  callbackConnector.destroy();
               }
   
  -            // clean up callback poller if one exists
  -            CallbackPoller callbackPoller = (CallbackPoller) callbackPollers.remove(callbackHandler);
  -            if (callbackPoller != null)
  -            {
  -               callbackPoller.stop();
  -            }
  +//            // clean up callback poller if one exists
  +//            CallbackPoller callbackPoller = (CallbackPoller) callbackPollers.remove(callbackHandler);
  +//            if (callbackPoller != null)
  +//            {
  +//               callbackPoller.stop();
  +//            }
            }
            else
            {
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 22:22:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 22:22:31 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/transport  ...
Message-ID: <E1Gs9qB-0007Q5-Hs@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 22:22:31

  Modified:    src/main/org/jboss/remoting/transport  Tag: remoting_2_x
                        ClientInvoker.java
  Log:
  JBREM-622:  Changed addClientLocator() and getClientLocators() to take sessionId parameter.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.7.2.2   +5 -3      JBossRemoting/src/main/org/jboss/remoting/transport/ClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClientInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/ClientInvoker.java,v
  retrieving revision 1.7.2.1
  retrieving revision 1.7.2.2
  diff -u -b -r1.7.2.1 -r1.7.2.2
  --- ClientInvoker.java	9 Nov 2006 20:33:58 -0000	1.7.2.1
  +++ ClientInvoker.java	7 Dec 2006 03:22:31 -0000	1.7.2.2
  @@ -48,11 +48,12 @@
       * of callbacks to receive (pull or push).  Set to null to poll for callback messages.
       * This can also be used to receive callbacks using another transport and subsystem,
       * if desired.
  -    *
  +    * @param sessionId
       * @param locator
  +    *
       * @return id for callback handler and locator combination
       */
  -   public String addClientLocator(InvokerCallbackHandler callbackhandler, InvokerLocator locator);
  +   public String addClientLocator(String sessionId, InvokerCallbackHandler callbackhandler, InvokerLocator locator);
   
      /**
       * Gets the client locator.  This locator will be used by the server side
  @@ -64,10 +65,11 @@
   
      /**
       * Gets list of AbstractInvoker.CallbackLocatorHolder containing listener id and locator
  +    * @param sessionId
       * @param handler
       * @return
       */
  -   public List getClientLocators(InvokerCallbackHandler handler);
  +   public List getClientLocators(String sessionId, InvokerCallbackHandler handler);
   
      /**
       * Gets SocketFactory used to connect to ServerInvoker.
  
  
  


From ron_sigal at yahoo.com  Wed Dec  6 22:23:20 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 06 Dec 2006 22:23:20 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple ...
Message-ID: <E1Gs9qy-0007QW-DC@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/06 22:23:20

  Added:       src/tests/org/jboss/test/remoting/callback/multiple    Tag:
                        remoting_2_x CallbackTestCase.java
                        CallbackTestClient.java CallbackTestServer.java
  Log:
  BREM-622:  New unit tests for multiple registrations of an InvokerCallbackHandler.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +72 -0     JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestCase.java
  ===================================================================
  RCS file: CallbackTestCase.java
  diff -N CallbackTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ CallbackTestCase.java	7 Dec 2006 03:23:20 -0000	1.1.2.2
  @@ -0,0 +1,72 @@
  +/*
  +* JBoss, a division of Red Hat
  +* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.callback.multiple;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + */
  +public class CallbackTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(CallbackTestClient.class.getName(),
  +                     1,
  +                     CallbackTestServer.class.getName());
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.1.2.2   +556 -0    JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestClient.java
  ===================================================================
  RCS file: CallbackTestClient.java
  diff -N CallbackTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ CallbackTestClient.java	7 Dec 2006 03:23:20 -0000	1.1.2.2
  @@ -0,0 +1,556 @@
  +package org.jboss.test.remoting.callback.multiple;
  +
  +import junit.framework.TestCase;
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.AbstractInvoker;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +import org.jboss.remoting.transport.ClientInvoker;
  +import org.jboss.remoting.transport.Connector;
  +
  +import javax.management.MBeanServer;
  +
  +import java.lang.reflect.Field;
  +import java.util.ArrayList;
  +import java.util.Iterator;
  +import java.util.List;
  +import java.util.Map;
  +
  +/**
  + * These tests supplement the tests in org.jboss.test.remoting.callback.multiple.client
  + * and org.jboss.test.remoting.callback.multiple.server.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.2 $
  + * <p>
  + * Copyright Dec 6, 2006
  + * </p>
  + */
  +public class CallbackTestClient extends TestCase
  +{
  +   // Default locator values
  +   private static String transport = "socket";
  +   private static String host = "localhost";
  +   private static int port = 5530;
  +   private static int nextPort = port + 10;
  +
  +   private String locatorURI = transport + "://" + host + ":" + port;
  +
  +   private static final Logger log = Logger.getLogger(CallbackTestClient.class);
  +
  +   public static final String RESPONSE_VALUE = "This is the return to SampleInvocationHandler invocation";
  +
  +   
  +   public void testPush1Client1Connector2Handlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
  +      CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client = new Client(locator);
  +      client.connect();
  +      Connector connector = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator = new InvokerLocator(callbackLocatorURI);
  +         connector = setupServer(callbackLocator);
  +         client.addListener(callbackHandler1, callbackLocator);
  +         client.addListener(callbackHandler2, callbackLocator);
  +         client.invoke("Do something", null);
  +         client.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         int count = callbackHandler1.getCallbackCount();
  +         assertEquals(2, count);
  +         count = callbackHandler2.getCallbackCount();
  +         assertEquals(2, count);
  +      }
  +      finally
  +      {
  +         if(client != null)
  +         {
  +            // remove callback handler from server
  +            client.removeListener(callbackHandler1);
  +            client.removeListener(callbackHandler2);
  +            client.disconnect();
  +         }
  +         teardownServer(connector);
  +      }
  +   }
  +   
  +   public void testPush1Client2Connectors1Handler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client = new Client(locator);
  +      client.connect();
  +      Connector connector1 = null;
  +      Connector connector2 = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
  +         connector1 = setupServer(callbackLocator1);
  +         client.addListener(callbackHandler, callbackLocator1);
  +         String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
  +         connector2 = setupServer(callbackLocator2);
  +         client.addListener(callbackHandler, callbackLocator2);
  +         client.invoke("Do something", null);
  +         client.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         int count = callbackHandler.getCallbackCount();
  +         assertEquals(4, count);
  +      }
  +      finally
  +      {
  +         if(client != null)
  +         {
  +            // remove callback handler from server
  +            client.removeListener(callbackHandler);
  +            client.disconnect();
  +         }
  +         teardownServer(connector1);
  +         teardownServer(connector2);
  +      }
  +   }
  +
  +   public void testPush1Client2Connectors2Handlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
  +      CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client = new Client(locator);
  +      client.connect();
  +      Connector connector1 = null;
  +      Connector connector2 = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
  +         connector1 = setupServer(callbackLocator1);
  +         client.addListener(callbackHandler1, callbackLocator1);
  +         String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
  +         connector2 = setupServer(callbackLocator2);
  +         client.addListener(callbackHandler2, callbackLocator2);
  +         client.invoke("Do something", null);
  +         client.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         int count = callbackHandler1.getCallbackCount();
  +         assertEquals(2, count);
  +         count = callbackHandler2.getCallbackCount();
  +         assertEquals(2, count);
  +      }
  +      finally
  +      {
  +         if(client != null)
  +         {
  +            // remove callback handler from server
  +            client.removeListener(callbackHandler1);
  +            client.removeListener(callbackHandler2);
  +            client.disconnect();
  +         }
  +         teardownServer(connector1);
  +         teardownServer(connector2);
  +      }
  +   }
  +   
  +   public void testPush2Clients1Connector1Handler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client1 = new Client(locator);
  +      client1.connect();
  +      Client client2 = new Client(locator);
  +      client2.connect();
  +      Connector connector = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator = new InvokerLocator(callbackLocatorURI);
  +         connector = setupServer(callbackLocator);
  +         log.info("created callback server: " + connector.getLocator());
  +         client1.addListener(callbackHandler, callbackLocator);
  +         client2.addListener(callbackHandler, callbackLocator);
  +         client1.invoke("Do something", null);
  +         client2.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         // The CallbackHandler should be registered just once.
  +         int count = callbackHandler.getCallbackCount();
  +         assertEquals(2, count);
  +      }
  +      finally
  +      {
  +         if(client1 != null)
  +         {
  +            // remove callback handler from server
  +            client1.removeListener(callbackHandler);
  +            client1.disconnect();
  +         }
  +         teardownServer(connector);
  +      }
  +   }
  +   
  +   public void testPush2Clients1Connector2Handlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
  +      CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client1 = new Client(locator);
  +      client1.connect();
  +      Client client2 = new Client(locator);
  +      client2.connect();
  +      Connector connector = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator = new InvokerLocator(callbackLocatorURI);
  +         connector = setupServer(callbackLocator);
  +         client1.addListener(callbackHandler1, callbackLocator);
  +         client2.addListener(callbackHandler2, callbackLocator);
  +         client1.invoke("Do something", null);
  +         client2.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         int count = callbackHandler1.getCallbackCount();
  +         assertEquals(2, count);
  +         count = callbackHandler1.getCallbackCount();
  +         assertEquals(2, count);
  +      }
  +      finally
  +      {
  +         Field field = AbstractInvoker.class.getDeclaredField("localServerLocators");
  +         field.setAccessible(true);
  +         
  +         if(client1 != null)
  +         {
  +            ClientInvoker invoker = client1.getInvoker();
  +            Map localServerLocators = (Map) field.get(invoker);
  +            assertEquals(2, localServerLocators.size());
  +            client1.removeListener(callbackHandler1);
  +            assertEquals(1, localServerLocators.size());
  +            client1.removeListener(callbackHandler2);
  +            // client1 shouldn't be able to remove callbackHandler2.
  +            assertEquals(1, localServerLocators.size());
  +            client1.disconnect();
  +         }
  +         if (client2 != null)
  +         {
  +            ClientInvoker invoker = client2.getInvoker();
  +            Map localServerLocators = (Map) field.get(invoker);
  +            assertEquals(1, localServerLocators.size());
  +            client2.removeListener(callbackHandler2);
  +            assertEquals(0, localServerLocators.size());
  +            client2.disconnect();
  +         }
  +         teardownServer(connector);
  +      }
  +   }
  +   
  +   public void testPush2Clients2Connectors1Handler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client1 = new Client(locator);
  +      client1.connect();
  +      Client client2 = new Client(locator);
  +      client2.connect();
  +      Connector connector1 = null;
  +      Connector connector2 = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
  +         connector1 = setupServer(callbackLocator1);
  +         String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
  +         connector2 = setupServer(callbackLocator2);
  +         client1.addListener(callbackHandler, callbackLocator1);
  +         client2.addListener(callbackHandler, callbackLocator2);
  +         client1.invoke("Do something", null);
  +         client2.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         int count = callbackHandler.getCallbackCount();
  +         assertEquals(4, count);
  +      }
  +      finally
  +      {
  +         Field field = AbstractInvoker.class.getDeclaredField("localServerLocators");
  +         field.setAccessible(true);
  +         
  +         if(client1 != null)
  +         {
  +            ClientInvoker invoker = client1.getInvoker();
  +            Map localServerLocators = (Map) field.get(invoker);
  +            assertEquals(2, localServerLocators.size());
  +            client1.removeListener(callbackHandler);
  +            // callbackHandler should still be registered with connector2.
  +            assertEquals(1, localServerLocators.size());
  +            client1.disconnect();
  +         }
  +         if (client2 != null)
  +         {
  +            ClientInvoker invoker = client2.getInvoker();
  +            Map localServerLocators = (Map) field.get(invoker);
  +            assertEquals(1, localServerLocators.size());
  +            client2.removeListener(callbackHandler);
  +            assertEquals(0, localServerLocators.size());
  +            client2.disconnect();
  +         }
  +         teardownServer(connector1);
  +         teardownServer(connector2);
  +      }
  +   }
  +   
  +   public void testPush2Clients2Connectors2Handlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      CallbackTestClient.CallbackHandler callbackHandler1 = new CallbackTestClient.CallbackHandler();
  +      CallbackTestClient.CallbackHandler callbackHandler2 = new CallbackTestClient.CallbackHandler();
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      Client client1 = new Client(locator);
  +      client1.connect();
  +      Client client2 = new Client(locator);
  +      client2.connect();
  +      Connector connector1 = null;
  +      Connector connector2 = null;
  +
  +      try
  +      {
  +         String callbackLocatorURI1 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator1 = new InvokerLocator(callbackLocatorURI1);
  +         connector1 = setupServer(callbackLocator1);
  +         String callbackLocatorURI2 = transport + "://" + host + ":" + nextPort++;
  +         InvokerLocator callbackLocator2 = new InvokerLocator(callbackLocatorURI2);
  +         connector2 = setupServer(callbackLocator2);
  +         client1.addListener(callbackHandler1, callbackLocator1);
  +         client2.addListener(callbackHandler2, callbackLocator2);
  +         client1.invoke("Do something", null);
  +         client2.invoke("Do something else", null);
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(5000);
  +
  +         int count = callbackHandler1.getCallbackCount();
  +         assertEquals(2, count);
  +         count = callbackHandler1.getCallbackCount();
  +         assertEquals(2, count);
  +      }
  +      finally
  +      {
  +         Field field = AbstractInvoker.class.getDeclaredField("localServerLocators");
  +         field.setAccessible(true);
  +         
  +         if(client1 != null)
  +         {
  +            ClientInvoker invoker = client1.getInvoker();
  +            Map localServerLocators = (Map) field.get(invoker);
  +            assertEquals(2, localServerLocators.size());
  +            client1.removeListener(callbackHandler1);
  +            assertEquals(1, localServerLocators.size());
  +            client1.removeListener(callbackHandler2);
  +            // client1 shouldn't be able to remove callbackHandler2.
  +            assertEquals(1, localServerLocators.size());
  +            client1.disconnect();
  +         }
  +         if (client2 != null)
  +         {
  +            ClientInvoker invoker = client2.getInvoker();
  +            Map localServerLocators = (Map) field.get(invoker);
  +            assertEquals(1, localServerLocators.size());
  +            client2.removeListener(callbackHandler2);
  +            assertEquals(0, localServerLocators.size());
  +            client2.disconnect();
  +         }
  +         teardownServer(connector1);
  +         teardownServer(connector2);
  +      }
  +   }
  +   
  +   
  +   public Connector setupServer(InvokerLocator locator) throws Exception
  +   {
  +      log.info("Starting remoting server with locator uri of: " + locator);
  +      try
  +      {
  +         Connector connector = new Connector();
  +         connector.setInvokerLocator(locator.getLocatorURI());
  +         connector.start();
  +         log.info("started callback Connector: " + connector.getLocator());
  +         
  +         CallbackTestClient.SampleInvocationHandler invocationHandler = new CallbackTestClient.SampleInvocationHandler();
  +         // first parameter is sub-system name.  can be any String value.
  +         connector.addInvocationHandler("sample", invocationHandler);
  +         return connector;
  +      }
  +      catch(Exception e)
  +      {
  +         log.error("Error starting callback server", e);
  +         throw e;
  +      }
  +   }
  +   
  +   public void teardownServer(Connector connector)
  +   {
  +      if(connector != null)
  +      {
  +         connector.stop();
  +         connector.destroy();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.
  +    */
  +   public static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +
  +      private List listeners = new ArrayList();
  +
  +
  +      /**
  +       * called to handle a specific invocation
  +       *
  +       * @param invocation
  +       * @return
  +       * @throws Throwable
  +       */
  +      public Object invoke(InvocationRequest invocation) throws Throwable
  +      {
  +         // Just going to return static string as this is just simple example code.
  +
  +         // Will also fire callback to listeners if they were to exist using
  +         // simple invocation request.
  +         Callback callback = new Callback("This is the payload of callback invocation.");
  +         Iterator itr = listeners.iterator();
  +         while(itr.hasNext())
  +         {
  +            InvokerCallbackHandler callbackHandler = (InvokerCallbackHandler) itr.next();
  +            try
  +            {
  +               callbackHandler.handleCallback(callback);
  +            }
  +            catch(HandleCallbackException e)
  +            {
  +               e.printStackTrace();
  +            }
  +         }
  +
  +         return RESPONSE_VALUE;
  +
  +      }
  +
  +      /**
  +       * Adds a callback handler that will listen for callbacks from
  +       * the server invoker handler.
  +       *
  +       * @param callbackHandler
  +       */
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         listeners.add(callbackHandler);
  +      }
  +
  +      /**
  +       * Removes the callback handler that was listening for callbacks
  +       * from the server invoker handler.
  +       *
  +       * @param callbackHandler
  +       */
  +      public void removeListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         listeners.remove(callbackHandler);
  +      }
  +
  +      /**
  +       * set the mbean server that the handler can reference
  +       *
  +       * @param server
  +       */
  +      public void setMBeanServer(MBeanServer server)
  +      {
  +         // NO OP as do not need reference to MBeanServer for this handler
  +      }
  +
  +      /**
  +       * set the invoker that owns this handler
  +       *
  +       * @param invoker
  +       */
  +      public void setInvoker(ServerInvoker invoker)
  +      {
  +         // NO OP as do not need reference back to the server invoker
  +      }
  +
  +   }
  +
  +
  +   public class CallbackHandler implements InvokerCallbackHandler
  +   {
  +      private Callback callback;
  +      private int callbackNumber = 0;
  +
  +      /**
  +       * Will take the callback message and send back to client.
  +       * If client locator is null, will store them till client polls to get them.
  +       *
  +       * @param callback
  +       * @throws org.jboss.remoting.callback.HandleCallbackException
  +       *
  +       */
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         callbackNumber++;
  +         this.callback = callback;
  +         System.out.println("Received callback value of: " + callback.getCallbackObject());
  +         System.out.println("Received callback handle object of: " + callback.getCallbackHandleObject());
  +         System.out.println("Received callback server invoker of: " + callback.getServerLocator());
  +      }
  +
  +      public Callback getCallback()
  +      {
  +         return callback;
  +      }
  +
  +      public int getCallbackCount()
  +      {
  +         return callbackNumber;
  +      }
  +   }
  +
  +}
  
  
  
  1.1.2.2   +158 -0    JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestServer.java
  ===================================================================
  RCS file: CallbackTestServer.java
  diff -N CallbackTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ CallbackTestServer.java	7 Dec 2006 03:23:20 -0000	1.1.2.2
  @@ -0,0 +1,158 @@
  +package org.jboss.test.remoting.callback.multiple;
  +
  +import java.util.ArrayList;
  +import java.util.Iterator;
  +import java.util.List;
  +
  +import javax.management.MBeanServer;
  +
  +import org.jboss.jrunit.extensions.ServerTestCase;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +import org.jboss.remoting.transport.Connector;
  +
  +/**
  + * Simple remoting server.  Uses inner class SampleInvocationHandler
  + * as the invocation target handler class.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class CallbackTestServer extends ServerTestCase
  +{
  +   // Default locator values
  +   private static String transport = "socket";
  +   private static String host = "localhost";
  +   private static int port = 5530;
  +
  +   private String locatorURI = transport + "://" + host + ":" + port;
  +   private Connector connector;
  +
  +   // String to be returned from invocation handler upon client invocation calls.
  +   public static final String RESPONSE_VALUE = "This is the return to SampleInvocationHandler invocation";
  +   public static final String CALLBACK_VALUE = "This is the payload of callback invocation.";
  +
  +
  +   public void setupServer() throws Exception
  +   {
  +      InvokerLocator locator = new InvokerLocator(locatorURI);
  +      System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  +      connector = new Connector();
  +      connector.setInvokerLocator(locator.getLocatorURI());
  +      connector.start();
  +
  +      CallbackTestServer.SampleInvocationHandler invocationHandler = new CallbackTestServer.SampleInvocationHandler();
  +      // first parameter is sub-system name.  can be any String value.
  +      connector.addInvocationHandler("sample", invocationHandler);
  +   }
  +
  +   protected void setUp() throws Exception
  +   {
  +      setupServer();
  +   }
  +
  +   protected void tearDown() throws Exception
  +   {
  +      if(connector != null)
  +      {
  +         connector.stop();
  +         connector.destroy();
  +      }
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      CallbackTestServer server = new CallbackTestServer();
  +      try
  +      {
  +         server.setUp();
  +
  +         Thread.sleep(600000);
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.
  +    */
  +   public static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +
  +      private List listeners = new ArrayList();
  +
  +
  +      /**
  +       * called to handle a specific invocation
  +       *
  +       * @param invocation
  +       * @return
  +       * @throws Throwable
  +       */
  +      public Object invoke(InvocationRequest invocation) throws Throwable
  +      {
  +         // Just going to return static string as this is just simple example code.
  +
  +         // Will also fire callback to listeners if they were to exist using
  +         // simple invocation request.
  +         Callback callback = new Callback(CALLBACK_VALUE);
  +         Iterator itr = listeners.iterator();
  +         while(itr.hasNext())
  +         {
  +            InvokerCallbackHandler callbackHandler = (InvokerCallbackHandler) itr.next();
  +            callbackHandler.handleCallback(callback);
  +         }
  +
  +         return RESPONSE_VALUE;
  +
  +      }
  +
  +      /**
  +       * Adds a callback handler that will listen for callbacks from
  +       * the server invoker handler.
  +       *
  +       * @param callbackHandler
  +       */
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         listeners.add(callbackHandler);
  +      }
  +
  +      /**
  +       * Removes the callback handler that was listening for callbacks
  +       * from the server invoker handler.
  +       *
  +       * @param callbackHandler
  +       */
  +      public void removeListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         listeners.remove(callbackHandler);
  +      }
  +
  +      /**
  +       * set the mbean server that the handler can reference
  +       *
  +       * @param server
  +       */
  +      public void setMBeanServer(MBeanServer server)
  +      {
  +         // NO OP as do not need reference to MBeanServer for this handler
  +      }
  +
  +      /**
  +       * set the invoker that owns this handler
  +       *
  +       * @param invoker
  +       */
  +      public void setInvoker(ServerInvoker invoker)
  +      {
  +         // NO OP as do not need reference back to the server invoker
  +      }
  +
  +   }
  +}
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 22:39:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 22:39:26 -0500
Subject: [jboss-cvs] JBossAS SVN: r58894 -
	projects/aop/trunk/aop/src/resources/test/beforeafter
Message-ID: <E1GsA6Y-0007du-6u@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 22:39:22 -0500 (Wed, 06 Dec 2006)
New Revision: 58894

Modified:
   projects/aop/trunk/aop/src/resources/test/beforeafter/jboss-aop.xml
Log:
[JBAOP-37] Updated tests so they check whether advices are being called at the correct moment (before/after/around/throwing).

Modified: projects/aop/trunk/aop/src/resources/test/beforeafter/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/beforeafter/jboss-aop.xml	2006-12-07 01:33:37 UTC (rev 58893)
+++ projects/aop/trunk/aop/src/resources/test/beforeafter/jboss-aop.xml	2006-12-07 03:39:22 UTC (rev 58894)
@@ -18,7 +18,7 @@
       <throwing name="throwingzzz" aspect="org.jboss.test.aop.beforeafter.ArgsAspect"/>
    </stack>
 
-   <bind pointcut="execution(org.jboss.test.aop.beforeafter.POJO->new(..)) OR execution(* org.jboss.test.aop.beforeafter.POJO->method(..)) OR field(* org.jboss.test.aop.beforeafter.POJO->*)">
+   <bind pointcut="execution(org.jboss.test.aop.beforeafter.POJO->new(..)) OR execution(* org.jboss.test.aop.beforeafter.POJO->method(..)) OR field(!static * org.jboss.test.aop.beforeafter.POJO->*)">
       <stack-ref name="argsStack"/>
    </bind>
    



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 22:40:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 22:40:12 -0500
Subject: [jboss-cvs] JBossAS SVN: r58895 -
	projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation
Message-ID: <E1GsA7I-0007fJ-5v@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 22:40:06 -0500 (Wed, 06 Dec 2006)
New Revision: 58895

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java
Log:
[JBAOP-37] Removed feature that allowed more than one valid annotation per parameter.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java	2006-12-07 03:39:22 UTC (rev 58894)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java	2006-12-07 03:40:06 UTC (rev 58895)
@@ -256,11 +256,6 @@
             }catch (ParameterAnnotationRuleException pare)
             {
                // no need to print messages -> exception prints automatically on verbose
-            } catch (MultipleAdviceInfoException maie)
-            {
-               // parameters with more than one annotation
-               rankedAdvices.addAll(AnnotatedParameterAdviceInfo.createAllAdviceInfo(
-                     methods[i], rules, maie.totalInstances, maie.annotations));
             }
          }
       }

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java	2006-12-07 03:39:22 UTC (rev 58894)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java	2006-12-07 03:40:06 UTC (rev 58895)
@@ -2,7 +2,6 @@
 
 import java.lang.annotation.Annotation;
 import java.lang.reflect.Method;
-import java.util.ArrayList;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.LinkedList;
@@ -21,10 +20,6 @@
  */
 class AnnotatedParameterAdviceInfo extends AdviceInfo
 {
-   // list that may contain temporary information regarding parameters with more than one
-   // valid annotation. Field is static to avoid the cost of constantly creating a list
-   private static List<Integer> extraAnnotations = new ArrayList<Integer>();
-   
    // the annotated parameter types
    private ParameterAnnotationType paramTypes[];
    
@@ -36,12 +31,9 @@
     * 
     * @throws ParameterAnnotationRuleException thrown when the advice method does not
     *         comply with a parameter annotation rule.
-    * @throws MultipleAdviceInfoException thrown when one parameter contains more than one
-    *         valid annotation. Indicates that there must be multiple advice infos to
-    *         represent <code>method</code>.
     */
    public AnnotatedParameterAdviceInfo(Method method, ParameterAnnotationRule[] rules)
-      throws ParameterAnnotationRuleException, MultipleAdviceInfoException
+      throws ParameterAnnotationRuleException
    {
       this(rules, method);
       this.applyRules();
@@ -205,149 +197,91 @@
     * 
     * @throws ParameterAnnotationRuleException thrown when the advice method does not
     *         comply with a parameter annotation rule.
-    * @throws MultipleAdviceInfoException thrown when one or more parameters is annotated
-    *         with more than one valid annotation
     */
-   private void applyRules() throws ParameterAnnotationRuleException,
-      MultipleAdviceInfoException
+   private void applyRules() throws ParameterAnnotationRuleException
    {
       Annotation[][] paramAnnotations = method.getParameterAnnotations();
-      int[] annotated = new int[paramAnnotations.length];
+      boolean annotated;
       for (int i = 0; i < paramAnnotations.length; i++)
       {
-         annotated[i] = -1;
-         extraAnnotations.clear();
+         annotated = false;
          for (Annotation annotation: paramAnnotations[i])
          {
             // no valid annotation found for parameter i yet
-            if (annotated[i] == -1)
+            if (!annotated)
             for (int j = 0; j < paramTypes.length; j++)
             {
                // found
                 if (paramTypes[j].applies(annotation, i))
                 {
-                   annotated[i] = j;
+                   annotated = true;
                    break;
                 }
             }
             else
             {
                // look for an extra annotation
-               extraAnnotations.add(annotated[i]);
                for (int j = 0; j < paramTypes.length; j++)
                {
                   if (paramTypes[j].applies(annotation))
                   {
-                     extraAnnotations.add(j);
+                     throwMultiAnnotationFoundException(i);
                   }
                }
             }
          }
-         if (annotated[i] == -1)
+         if (!annotated)
          {
             throwAnnotationNotFoundException(i);
-            
          }
-         else if(extraAnnotations.size() > 1)
-         {
-            throwMAIException(paramAnnotations, annotated, i);
-         }
       }
       
    }
 
    /**
-    * Throws an exception indicating the ith parameter of this advice is not annotated.
+    * Throws an exception indicating the ith parameter of this advice contains
+    * multiple valid annotations.
     * 
     * @param i the index of the not annotated parameter.
     * 
     * @throws ParameterAnnotationRuleException
     */
-   private final void throwAnnotationNotFoundException(int i)
+   private final void throwMultiAnnotationFoundException(int i)
       throws ParameterAnnotationRuleException
    {
       if (AspectManager.verbose)
       {
          throw new ParameterAnnotationRuleException("\n[warn] -parameter " + i  +
-               " of method " + method +  " is not annotated");
+               " of method " + method +  " contains more than one valid annotation");
       }
       else
       {
          throw new ParameterAnnotationRuleException(null);
       }
    }
-
+   
    /**
-    * Throws an exception indicating this advice contains one ore more parameters with
-    * more than one valid annotation.
-    * The exception thrown contains all information about the advice method parameter
-    * annotations.
+    * Throws an exception indicating the ith parameter of this advice is not annotated.
     * 
-    * @param paramAnnotations      the list of parameter annotations of this advice method
-    * @param singleAnnotations     the list of previous parameters whose single annotation
-    *                              has been processed
-    * @param singleAnnotationsSize the number parameteres whose single annotation has been
-    *                              processed before a multi-annotated parameter was found
-    * @throws MultipleAdviceInfoException
+    * @param i the index of the not annotated parameter.
+    * 
+    * @throws ParameterAnnotationRuleException
     */
-   private final void throwMAIException(Annotation[][] paramAnnotations,
-      int[] singleAnnotations, int singleAnnotationsSize)
-      throws MultipleAdviceInfoException
+   private final void throwAnnotationNotFoundException(int i)
+      throws ParameterAnnotationRuleException
    {
-      int[][] allAnnotations = new int[paramAnnotations.length][];
-      int i = singleAnnotationsSize;
-      // record single annotation information
-      for (int j = 0; j < i; j++)
+      if (AspectManager.verbose)
       {
-         allAnnotations[j] = new int[1];
-         allAnnotations[j][0] = singleAnnotations[j];
+         throw new ParameterAnnotationRuleException("\n[warn] -parameter " + i  +
+               " of method " + method +  " is not annotated");
       }
-      // fill multi-annotations information
-      int totalCombinations = fillAllAnnotations(allAnnotations, i);
-      
-      while (++i < paramAnnotations.length)
+      else
       {
-         extraAnnotations.clear();
-         for (Annotation annotation: paramAnnotations[i])
-         {
-            for (int j = 0; j < paramTypes.length; j++)
-            {
-               if (paramTypes[j].applies(annotation))
-               {
-                  extraAnnotations.add(j);
-               }
-            }
-         }
-         if (extraAnnotations.isEmpty())
-         {
-            throw new RuntimeException("Parameter " + singleAnnotationsSize  + " of method " +
-                  method +  " is not annotated");
-         }
-         totalCombinations *= fillAllAnnotations(allAnnotations, i);
+         throw new ParameterAnnotationRuleException(null);
       }
-      throw new MultipleAdviceInfoException(totalCombinations, allAnnotations);
    }
    
    /**
-    * Helper method that fills <code>allAnnotations[i]</code> with all annotations found
-    * on the ith advice parameter.
-    * @param allAnnotations the list of all annotations found on this advice method
-    * @param i              the index of the parameter whose annotations must be filled in
-    *                       <code>allAnnotations</code>.
-    * @return the total number of annotations found on the ith parameter
-    */
-   private int fillAllAnnotations(int[][] allAnnotations, int i)
-   {
-      allAnnotations[i] = new int[extraAnnotations.size()];
-      Iterator<Integer> iterator = extraAnnotations.iterator();
-      for (int k = 0; k < allAnnotations[i].length; k++)
-      {
-         allAnnotations[i][k] = iterator.next();
-      }
-      return allAnnotations[i].length;
-   }
-   
-   /**
     * Contains validation data concerning a parameter annotation rule.
     */
    abstract class ParameterAnnotationType
@@ -621,7 +555,6 @@
             return -1;
          }
          Class[] expectedTypes = (Class[]) rule.getAssignableFrom(properties);
-         Class[] paramTypes = method.getParameterTypes();
          short level = 0;
          for (int i = 0; i < indexesLength; i++)
          {



From jboss-cvs-commits at lists.jboss.org  Wed Dec  6 22:49:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 06 Dec 2006 22:49:33 -0500
Subject: [jboss-cvs] JBossAS SVN: r58896 - in projects/aop/trunk/aop/src:
	resources/test/beforeafterArgs
	test/org/jboss/test/aop/beforeafterArgs
Message-ID: <E1GsAGL-0007mx-Gs@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-06 22:49:22 -0500 (Wed, 06 Dec 2006)
New Revision: 58896

Modified:
   projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedBeforeAspect.java
Log:
[JBAOP-37] Added case where the type of joinpoint (field read/write) controls which advice must be called

Modified: projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-07 03:40:06 UTC (rev 58895)
+++ projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-07 03:49:22 UTC (rev 58896)
@@ -156,6 +156,10 @@
    	<before name="before12" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
   	</bind>
   	
+  	<bind pointcut="field(* org.jboss.test.aop.beforeafterArgs.OverloadedAdvicePOJO->text)">
+  	   <before name="before13" aspect="org.jboss.test.aop.beforeafterArgs.OverloadedBeforeAspect"/>
+  	</bind>
+  	
    <aspect class="org.jboss.test.aop.beforeafterArgs.OverloadedAroundAspect" scope="PER_VM"/>
   	   
   	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.OverloadedAdvicePOJO->method1(int,long))">

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java	2006-12-07 03:40:06 UTC (rev 58895)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedAdviceTestCase.java	2006-12-07 03:49:22 UTC (rev 58896)
@@ -75,6 +75,10 @@
       assertEquals("String", OverloadedBeforeAspect.before10);
       assertEquals("Object", OverloadedBeforeAspect.before11);
       assertEquals("", OverloadedBeforeAspect.before12);
+      assertEquals("FieldInfo,String", OverloadedBeforeAspect.before13);
+      String myText = pojo.text;
+      assertEquals("FieldInfo", OverloadedBeforeAspect.before13);
+      
    }
    
    public void test2()

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedBeforeAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedBeforeAspect.java	2006-12-07 03:40:06 UTC (rev 58895)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/OverloadedBeforeAspect.java	2006-12-07 03:49:22 UTC (rev 58896)
@@ -48,6 +48,7 @@
    static String before10 = null;
    static String before11 = null;
    static String before12 = null;
+   static String before13 = null;
    
    public static void clear()
    {
@@ -63,6 +64,7 @@
       before10 = null;
       before11 = null;
       before12 = null;
+      before13 = null;
    }
    
    /* BEFORE1 ADVICE */
@@ -553,4 +555,14 @@
    {
       Assert.fail("This advice should never be executed");
    }
+   
+   public void before13(@JoinPoint FieldInfo fieldInfo, @Arg String text)
+   {
+      before13 = "FieldInfo,String";
+   }
+   
+   public void before13(@JoinPoint FieldInfo fieldInfo)
+   {
+      before13 = "FieldInfo";
+   }
 }
\ No newline at end of file



From gavin.king at jboss.com  Wed Dec  6 23:15:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 23:15:45 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1GsAfh-0008Jk-Ki@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 23:15:45

  Modified:    seam-gen  build.xml
  Log:
  add datepicker to date fields
  fix bigdecimal conversion
  
  Revision  Changes    Path
  1.46      +2 -1      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- build.xml	6 Dec 2006 06:55:39 -0000	1.45
  +++ build.xml	7 Dec 2006 04:15:45 -0000	1.46
  @@ -78,6 +78,7 @@
           <include name="layout/template.xhtml"/>
       	<include name="layout/menu.xhtml"/>
           <include name="stylesheet/*"/>
  +    	<include name="img/*"/>
       </fileset>
   	
   	<!-- targets -->
  
  
  


From gavin.king at jboss.com  Wed Dec  6 23:15:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 23:15:45 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/stylesheet  ...
Message-ID: <E1GsAfh-0008K3-T4@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 23:15:45

  Modified:    seam-gen/view/stylesheet  theme.css
  Log:
  add datepicker to date fields
  fix bigdecimal conversion
  
  Revision  Changes    Path
  1.4       +126 -0    jboss-seam/seam-gen/view/stylesheet/theme.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: theme.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/stylesheet/theme.css,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- theme.css	3 Dec 2006 09:21:41 -0000	1.3
  +++ theme.css	7 Dec 2006 04:15:45 -0000	1.4
  @@ -138,3 +138,129 @@
   .errors input {
   	border: 1px solid red;
   }
  +
  +/* Date Picker 
  +----------------------------------------------- */
  +
  +/* the div that holds the date picker calendar */
  +.dpDiv {
  +	width: 300px;
  +	}
  +
  +
  +/* the table (within the div) that holds the date picker calendar */
  +.dpTable {
  +	font-family: Tahoma, Arial, Helvetica, sans-serif;
  +	font-size: 12px;
  +	text-align: center;
  +	color: #505050;
  +	background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
  +	background-color: #FFFFFF;
  +	border: 1px solid #AAAAAA;
  +	margin-top: 5px;
  +	}
  +
  +
  +/* a table row that holds date numbers (either blank or 1-31) */
  +.dpTR {
  +	}
  +
  +
  +/* the top table row that holds the month, year, and forward/backward buttons */
  +.dpTitleTR {
  +	}
  +
  +
  +/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  +.dpDayTR {
  +	}
  +
  +
  +/* the bottom table row, that has the "This Month" and "Close" buttons */
  +.dpTodayButtonTR {
  +	}
  +
  +
  +/* a table cell that holds a date number (either blank or 1-31) */
  +.dpTD {
  +	border: 1px solid #ece9d8;
  +	width: 14%;
  +	}
  +
  +
  +/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  +.dpDayHighlightTD {
  +	background-color: #CCCCCC;
  +	border: 1px solid #AAAAAA;
  +	}
  +
  +
  +/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  +.dpTDHover {
  +	background-color: #CCCCCC;
  +	border: 1px solid #AAAAAA;
  +	cursor: pointer;
  +	color: red;
  +	}
  +
  +
  +/* the table cell that holds the name of the month and the year */
  +.dpTitleTD {
  +	}
  +
  +
  +/* a table cell that holds one of the forward/backward buttons */
  +.dpButtonTD {
  +	}
  +
  +
  +/* the table cell that holds the "This Month" or "Close" button at the bottom */
  +.dpTodayButtonTD {
  +	}
  +
  +
  +/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  +.dpDayTD {
  +	background-color: #CCCCCC;
  +	border: 1px solid #AAAAAA;
  +	color: white;
  +	}
  +
  +
  +/* additional style information for the text that indicates the month and year */
  +.dpTitleText {
  +	font-size: 12px;
  +	color: gray;
  +	font-weight: bold;
  +	}
  +
  +
  +/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  +.dpDayHighlight {
  +	font-weight: bold;
  +	}
  +
  +
  +/* the forward/backward buttons at the top */
  +.dpButton {
  +	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  +	font-size: 10px;
  +	color: gray;
  +	background: #FFFFFF;
  +	font-weight: bold;
  +	padding: 0px;
  +	border: 1px solid #AAAAAA;
  +	}
  +
  +
  +/* the "This Month" and "Close" buttons at the bottom */
  +.dpTodayButton {
  +	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  +	font-size: 10px;
  +	color: gray;
  +	background: #FFFFFF;
  +	font-weight: bold;
  +	border: 1px solid #AAAAAA;
  +	display:none;
  +	}
  +
  
  
  


From gavin.king at jboss.com  Wed Dec  6 23:15:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 23:15:45 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1GsAfh-0008Jr-OJ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 23:15:45

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  add datepicker to date fields
  fix bigdecimal conversion
  
  Revision  Changes    Path
  1.17      +6 -9      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- edit.xhtml.ftl	4 Dec 2006 03:36:03 -0000	1.16
  +++ edit.xhtml.ftl	7 Dec 2006 04:15:45 -0000	1.17
  @@ -46,8 +46,11 @@
                                         required="true"
   </#if>
   		        	                     value="${'#'}{${homeName}.instance.${property.name}}">
  -		        	               <f:convertDateTime type="date" dateStyle="short"/>
  +		        	               <f:convertDateTime type="date" dateStyle="short" pattern="MM/dd/yyyy"/>
   		        	           </h:inputText>
  +		        	           <s:selectDate for="${property.name}">
  +		        	               <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +		        	           </s:selectDate>
   <#elseif property.value.typeName == "time">
   		        	           <h:inputText id="${property.name}" 
   	        		                      size="5"
  @@ -72,10 +75,7 @@
                                         required="true"
   </#if>
   			                             value="${'#'}{${homeName}.instance.${property.name}}"
  -			                              size="${column.precision+7}">
  -			                       <f:convertNumber maxIntegerDigits="${column.precision-column.scale}" 
  -			                                       maxFractionDigits="${column.scale}"/>
  -			                   </h:inputText>
  +			                              size="${column.precision+7}"/>
   <#elseif property.value.typeName == "big_integer">
   			                   <h:inputText id="${property.name}" 
   <#if propertyIsId>
  @@ -85,10 +85,7 @@
                                         required="true"
   </#if>
   			                             value="${'#'}{${homeName}.instance.${property.name}}"
  -			                              size="${column.precision+6}">
  -			                       <f:convertNumber integerOnly="true"
  -			                                   maxIntegerDigits="${column.precision}"/>
  -			                   </h:inputText>
  +			                              size="${column.precision+6}"/>
   <#elseif property.value.typeName == "boolean">
   			                   <h:selectBooleanCheckbox id="${property.name}"
   <#if !column.nullable>
  
  
  


From gavin.king at jboss.com  Wed Dec  6 23:16:01 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 23:16:01 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/img - New directory ...
Message-ID: <E1GsAfx-0008Kp-FF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 23:16:01

  Log:
  Directory /cvsroot/jboss/jboss-seam/seam-gen/view/img added to the repository


From gavin.king at jboss.com  Wed Dec  6 23:16:27 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 23:16:27 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/img  ...
Message-ID: <E1GsAgN-0008L6-AW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 23:16:27

  Added:       seam-gen/view/img  dtpick.gif
  Log:
  add datepicker to date fields
  fix bigdecimal conversion
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 04:16:27;  author: gavin;  state: Exp;jboss-seam/seam-gen/view/img/dtpick.gif
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Wed Dec  6 23:19:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 06 Dec 2006 23:19:18 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF  ...
Message-ID: <E1GsAj8-0008LS-NR@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/06 23:19:18

  Modified:    src/ui/META-INF  faces-config.xml
  Log:
  workaround what looks like a bug in myfaces
  
  Revision  Changes    Path
  1.23      +10 -0     jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- faces-config.xml	7 Dec 2006 00:19:15 -0000	1.22
  +++ faces-config.xml	7 Dec 2006 04:19:18 -0000	1.23
  @@ -466,4 +466,14 @@
           <converter-class>org.jboss.seam.ui.ConvertDateTime</converter-class>
       </converter>
       
  +    <converter>
  +        <converter-for-class>java.math.BigDecimal</converter-for-class>
  +        <converter-class>javax.faces.convert.BigDecimalConverter</converter-class>
  +    </converter>
  +
  +    <converter>
  +        <converter-for-class>java.math.BigInteger</converter-for-class>
  +        <converter-class>javax.faces.convert.BigIntegerConverter</converter-class>
  +    </converter>
  +
   </faces-config>
  
  
  


From forge-admin at jboss.com  Thu Dec  7 01:00:35 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Thu, 07 Dec 2006 01:00:35 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GsCJ9-0001Qq-UY@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-06 01:07 EST)
-----------------

fix proxy deserialization outside of web context

  jboss-seam  build.xml                                                     1.119
  jboss-seam  src/main/org/jboss/seam/Component.java                        1.216
  jboss-seam  src/main/org/jboss/seam/intercept/ClientSideInterceptor.java  1.8
  jboss-seam  src/main/org/jboss/seam/intercept/JavaBeanInterceptor.java    1.10


Commit from myuan (2006-12-06 01:55 EST)
-----------------

Add a "create-drop" question in the wizard and add debug support in NB

  jboss-seam  seam-gen/build.xml                         1.45
+ jboss-seam  seam-gen/nbproject/debug-jboss.properties  1.1
+ jboss-seam  seam-gen/nbproject/ide-file-targets.xml    1.1
  jboss-seam  seam-gen/nbproject/project.xml             1.4


Commit from gavin (2006-12-06 02:36 EST)
-----------------

namingpolicy, perhaps

  jboss-seam  src/main/org/jboss/seam/Component.java  1.217


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-06 05:57 EST)
------------------------------------------------------

fixed problem with recreating nodes after deletion

  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.14.2.10


Commit from msurtani on branch Branch_JBossCache_1_3_0 (2006-12-06 06:36 EST)
------------------------------------------------------

gtx test

  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.14.2.11


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-06 06:44 EST)
------------------------------------------------------

ported fixes for JBCACHE-871 and JBCACHE-875 from the 1.3.0 branch

  JBossCache  tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java    1.6.2.1
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java          1.20.2.4
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java  1.1.20.1


Commit from msurtani (2006-12-06 07:46 EST)
--------------------

Partially brought in tests for JBCACHE-875 and JBCACHE-871

  JBossCache  tests/functional/org/jboss/cache/transaction/TransactionTest.java  1.18


Commit from msurtani (2006-12-06 07:54 EST)
--------------------

JBCACHE-895

  JBossCache  src/org/jboss/cache/GlobalTransaction.java  1.16


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-06 08:01 EST)
------------------------------------------------------

JBCACHE-895

  JBossCache  src/org/jboss/cache/GlobalTransaction.java  1.13.2.1


Commit from msurtani (2006-12-06 08:01 EST)
--------------------

JBCACHE-895

  JBossCache  src/org/jboss/cache/GlobalTransaction.java  1.17


Commit from msurtani (2006-12-06 08:10 EST)
--------------------

JBCACHE-895

  JBossCache  tests/functional/org/jboss/cache/GlobalTransactionTest.java  1.8
  JBossCache  src/org/jboss/cache/GlobalTransaction.java                   1.18


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-06 08:12 EST)
------------------------------------------------------

JBCACHE-895

  JBossCache  src/org/jboss/cache/GlobalTransaction.java                   1.13.2.2
  JBossCache  tests/functional/org/jboss/cache/GlobalTransactionTest.java  1.5.2.2


Commit from gavin (2006-12-06 10:23 EST)
-----------------

throw exception if javassist is missing

  jboss-seam  src/main/org/jboss/seam/deployment/Scanner.java  1.21


Commit from hmesha (2006-12-06 10:46 EST)
------------------

JBCACHE-861

  JBossCache  etc/build.xml  1.18


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-06 11:00 EST)
------------------------------------------------------

JBCACHE-894

  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java                   1.3.2.1
  JBossCache  src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java   1.21.2.4
  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java     1.25.2.7
+ JBossCache  tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java  1.1.2.1
  JBossCache  tests/functional/org/jboss/cache/options/SuppressLockingTest.java        1.4.2.1
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java   1.1.2.2


Commit from msurtani (2006-12-06 11:28 EST)
--------------------

JBCACHE-894

+ JBossCache  tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java  1.2
  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java                   1.4
  JBossCache  src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java   1.30
  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java     1.45
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java   1.4


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-06 11:29 EST)
------------------------------------------------------

JBCACHE-894

  JBossCache  tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java  1.1.2.2


Commit from mculpepper (2006-12-06 12:02 EST)
----------------------

changed the model hierarchy so node working copy's have no reference to add/remove child, and removed addFolder etc from the working copy classes (they should've been removed a long time ago). also made wrote lots of javadoc where there was none before

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeWorkingCopy.java        1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolderWorkingCopy.java      1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageWorkingCopy.java            1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNode.java                   1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java                   1.10
+ jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeBase.java               1.1
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSetWorkingCopy.java     1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSet.java                1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFolderImpl.java     1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java           1.5
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageNodeImpl.java       1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageBuildDelegate.java  1.6
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/FilesetInfoWizardPage.java      1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/actions/BuildPackagesAction.java              1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views/ProjectPackagesView.java                1.7
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/FilesetWizard.java                    1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/PackagesUIPlugin.java                         1.2


Commit from rawb (2006-12-06 12:14 EST)
----------------

Forcing a selection event makes the icon bars reload.

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java  1.4


Commit from rawb (2006-12-06 12:47 EST)
----------------

added a force api to firing model change events, because it was the easy bandaid solution.

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java  1.8


Commit from myuan (2006-12-06 13:15 EST)
-----------------

Better menu options

  jboss-seam  seam-gen/nbproject/project.xml  1.5


Commit from starksm (2006-12-06 13:38 EST)
-------------------

Generate a jboss-remoting-src.zip artifact for inclusion into the repository

  JBossRemoting  build.xml  1.91


Commit from rawb (2006-12-06 14:24 EST)
----------------

More informative API for the pages

+ jbosside  core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardPageWithNotification.java  1.1
+ jbosside  core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardWithNotification.java      1.1


Commit from ovidiu (2006-12-06 14:24 EST)
------------------

adding 1.0.1.SP2

+ repository.jboss.com  jboss/messaging/1.0.1.SP2/component-info.xml       1.1
+ repository.jboss.com  jboss/messaging/1.0.1.SP2/lib/jboss-messaging.jar  1.1


Commit from starksm (2006-12-06 14:42 EST)
-------------------

Add a jboss-remoting-src.zip artifact

  repository.jboss.com  jboss/remoting/2.2.0.Alpha4/component-info.xml          1.2
+ repository.jboss.com  jboss/remoting/2.2.0.Alpha4/lib/jboss-remoting-src.zip  1.1


Commit from rawb (2006-12-06 14:42 EST)
----------------

More informative API for the pages

  jbosside  core/plugins/org.jboss.ide.eclipse.ui/META-INF/MANIFEST.MF  1.6


Commit from starksm (2006-12-06 14:45 EST)
-------------------

Add a jboss-remoting-src.zip artifact

  repository.jboss.com  jboss/remoting/2.2.0.Alpha2/component-info.xml          1.2
+ repository.jboss.com  jboss/remoting/2.2.0.Alpha2/lib/jboss-remoting-src.zip  1.1


Commit from mculpepper (2006-12-06 15:17 EST)
----------------------

added getPackageFilePath() to appease rawb

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java  1.6
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackage.java              1.4


Commit from myuan (2006-12-06 17:53 EST)
-----------------

netbeans improvement

  jboss-seam  seam-gen/nbproject/debug-jboss.properties  1.2
  jboss-seam  seam-gen/nbproject/project.xml             1.6


Commit from rrajasekaran (2006-12-06 19:17 EST)
------------------------

JBossCache 1.3.0.SP4

+ repository.jboss.com  jboss/cache/1.3.0.SP4/README.txt                 1.1
+ repository.jboss.com  jboss/cache/1.3.0.SP4/component-info.xml         1.1
+ repository.jboss.com  jboss/cache/1.3.0.SP4/lib/jboss-cache-jdk50.jar  1.1
+ repository.jboss.com  jboss/cache/1.3.0.SP4/lib/jboss-cache.jar        1.1


Commit from nrichards (2006-12-06 19:19 EST)
---------------------

JBSEAM-556: add s:selectDate

  jboss-seam  src/ui/META-INF/faces-config.xml                 1.22
  jboss-seam  src/ui/META-INF/seam.taglib.xml                  1.19
  jboss-seam  src/ui/META-INF/taglib.tld                       1.23
+ jboss-seam  src/ui/org/jboss/seam/ui/SelectDate.java         1.1
+ jboss-seam  src/ui/org/jboss/seam/ui/selectDate.js           1.1
+ jboss-seam  src/ui/org/jboss/seam/ui/tag/SelectDateTag.java  1.1


Commit from nrichards (2006-12-06 19:24 EST)
---------------------

use s:selectDate

  jboss-seam  examples/seampay/build.xml            1.4
+ jboss-seam  examples/seampay/view/date.css        1.1
  jboss-seam  examples/seampay/view/search.xhtml    1.7
+ jboss-seam  examples/seampay/view/img/dtpick.gif  1.1


Commit from nrichards (2006-12-06 20:59 EST)
---------------------

use s:selectDate

  jboss-seam  examples/booking/view/book.xhtml        1.27
- jboss-seam  examples/booking/view/js/datePicker.js  1.4


Commit from rsigal (2006-12-06 21:58 EST)
------------------

JBREM-622:  Stores InvokerCallbackHandlers keyed on sessionId + listenerId.

  JBossRemoting  src/main/org/jboss/remoting/AbstractInvoker.java  1.15


Commit from rsigal (2006-12-06 21:58 EST)
------------------

JBREM-622:  Conforms to change in AbstractInvoker, which stores InvokerCallbackHandlers keyed on sessionId + listenerId.

  JBossRemoting  src/main/org/jboss/remoting/Client.java  1.59


Commit from rsigal (2006-12-06 22:00 EST)
------------------

JBREM-622:  New unit tests for multiple registrations of an InvokerCallbackHandler.

+ JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestServer.java  1.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestClient.java  1.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestCase.java    1.1


Commit from rsigal (2006-12-06 22:16 EST)
------------------

JBREM-622:  Changed addClientLocator() and getClientLocators() to take sessionId parameter.

  JBossRemoting  src/main/org/jboss/remoting/transport/ClientInvoker.java  1.9


Commit from rsigal on branch remoting_2_x (2006-12-06 22:20 EST)
-----------------------------------------

JBREM-622:  Stores InvokerCallbackHandlers keyed on sessionId + listenerId.

  JBossRemoting  src/main/org/jboss/remoting/AbstractInvoker.java  1.12.4.4


Commit from rsigal on branch remoting_2_x (2006-12-06 22:20 EST)
-----------------------------------------

JBREM-622:  Conforms to change in AbstractInvoker, which stores InvokerCallbackHandlers keyed on sessionId

  JBossRemoting  src/main/org/jboss/remoting/Client.java  1.53.2.7


Commit from rsigal on branch remoting_2_x (2006-12-06 22:22 EST)
-----------------------------------------

JBREM-622:  Changed addClientLocator() and getClientLocators() to take sessionId parameter.

  JBossRemoting  src/main/org/jboss/remoting/transport/ClientInvoker.java  1.7.2.2


Commit from rsigal on branch remoting_2_x (2006-12-06 22:23 EST)
-----------------------------------------

BREM-622:  New unit tests for multiple registrations of an InvokerCallbackHandler.

+ JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestCase.java    1.1.2.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestClient.java  1.1.2.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/CallbackTestServer.java  1.1.2.2


Commit from gavin (2006-12-06 23:15 EST)
-----------------

add datepicker to date fields
fix bigdecimal conversion

  jboss-seam  seam-gen/build.xml                  1.46
  jboss-seam  seam-gen/view/edit.xhtml.ftl        1.17
  jboss-seam  seam-gen/view/stylesheet/theme.css  1.4
+ jboss-seam  seam-gen/view/img/dtpick.gif        1.1


Commit from gavin (2006-12-06 23:19 EST)
-----------------

workaround what looks like a bug in myfaces

  jboss-seam  src/ui/META-INF/faces-config.xml  1.23
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061207/9b568bc0/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 06:13:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 06:13:14 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1716 -
	branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GsHBi-0006bZ-EU@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-07 06:13:12 -0500 (Thu, 07 Dec 2006)
New Revision: 1716

Modified:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
Log:
switch back to JBossTM to see if it affects the random QA failures

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-07 03:20:14 UTC (rev 1715)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-07 11:13:12 UTC (rev 1716)
@@ -43,6 +43,7 @@
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.tm.TxUtils;
+import org.jboss.tm.TransactionManagerLocator;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -86,7 +87,7 @@
             
       if (!ServerManagement.isRemote())
       {
-         tm = org.jboss.test.messaging.util.TransactionManagerLocator.getInstance().locate();
+         tm = TransactionManagerLocator.getInstance().locate();
       }
 
       ServerManagement.undeployQueue("Queue");



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 07:57:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 07:57:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r58897 -
	projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist
Message-ID: <E1GsIor-0008If-8d@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-07 07:57:43 -0500 (Thu, 07 Dec 2006)
New Revision: 58897

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java
Log:
[JBMICROCONT-133] - Remove the magic accessor usage until we figure out
how to do this across JDKs.

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java	2006-12-07 03:49:22 UTC (rev 58896)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistReflectionFactory.java	2006-12-07 12:57:43 UTC (rev 58897)
@@ -76,6 +76,7 @@
    {
       ClassPool pool = JavassistTypeInfoFactoryImpl.pool;
       final CtClass result = pool.makeClass(JavassistMethod.class.getName() + counter.increment());
+      /* TODO JBMICROCONT-133 figure out how to do this on all JDKs
       try
       {
          CtClass magic = pool.get("sun.reflect.MagicAccessorImpl");
@@ -83,7 +84,7 @@
       }
       catch (NotFoundException ignored)
       {
-      }
+      }*/
       result.addInterface(pool.get(JavassistMethod.class.getName()));
       
       CtConstructor constructor = new CtConstructor(null, result);



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 08:22:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 08:22:10 -0500
Subject: [jboss-cvs] JBossAS SVN: r58898 -
	projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar
Message-ID: <E1GsJCU-0000PT-JC@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-07 08:22:08 -0500 (Thu, 07 Dec 2006)
New Revision: 58898

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
Log:
Javadoc fix

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-07 12:57:43 UTC (rev 58897)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-07 13:22:08 UTC (rev 58898)
@@ -273,6 +273,7 @@
     * 
     * @param parent - the parent handler
     * @param path - the simple path to the entry without any trailing '/'
+    * @param isDirEntry - whether this is a directory entry
     * @return the jar entry URL
     * @throws MalformedURLException
     */



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 08:59:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 08:59:54 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58899 - trunk/tools/etc/buildmagic
Message-ID: <E1GsJn0-0000wv-5q@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-07 08:59:52 -0500 (Thu, 07 Dec 2006)
New Revision: 58899

Modified:
   trunk/tools/etc/buildmagic/modules.ent
Log:
Fix the build

Modified: trunk/tools/etc/buildmagic/modules.ent
===================================================================
--- trunk/tools/etc/buildmagic/modules.ent	2006-12-07 13:22:08 UTC (rev 58898)
+++ trunk/tools/etc/buildmagic/modules.ent	2006-12-07 13:59:52 UTC (rev 58899)
@@ -87,6 +87,7 @@
 <property name="jboss.deployment.lib" value="${jboss.deployment.root}/lib"/>
 <path id="jboss.deployment.classpath">
   <pathelement path="${jboss.deployment.lib}/jboss-deployment.jar"/>
+  <pathelement path="${jboss.deployment.lib}/jboss-jsr88.jar"/>
 </path>
 
 <!-- EJB3 -->



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 10:34:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 10:34:04 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58900 - trunk/build
Message-ID: <E1GsLG8-0002tX-4s@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-07 10:34:02 -0500 (Thu, 07 Dec 2006)
New Revision: 58900

Modified:
   trunk/build/build.xml
Log:
exclude jbossws jars from jbossall-clinet

Modified: trunk/build/build.xml
===================================================================
--- trunk/build/build.xml	2006-12-07 13:59:52 UTC (rev 58899)
+++ trunk/build/build.xml	2006-12-07 15:34:02 UTC (rev 58900)
@@ -777,9 +777,7 @@
         <include name="jboss-ejb3x.jar"/>
         <include name="jboss-j2ee.jar"/>
         <include name="jboss-j2se.jar"/>
-        <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-remoting.jar"/>
-        <include name="jboss-saaj.jar"/>
         <include name="jboss-serialization.jar"/>
         <include name="jbossmqha.jar"/>
         <include name="jmx-connector-client-factory.jar"/>
@@ -819,9 +817,7 @@
         <include name="jboss-ejb3x.jar"/>
         <include name="jboss-j2ee.jar"/>
         <include name="jboss-j2se.jar"/>
-        <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-remoting.jar"/>
-        <include name="jboss-saaj.jar"/>
         <include name="jboss-serialization.jar"/>
         <include name="jbossmqha.jar"/>
         <include name="jmx-connector-client-factory.jar"/>



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 10:39:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 10:39:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r58901 -
	trunk/ejb3/src/main/org/jboss/injection
Message-ID: <E1GsLLQ-0002xx-6y@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-07 10:39:30 -0500 (Thu, 07 Dec 2006)
New Revision: 58901

Modified:
   trunk/ejb3/src/main/org/jboss/injection/WebServiceRefInjector.java
Log:
update to latest jbossws

Modified: trunk/ejb3/src/main/org/jboss/injection/WebServiceRefInjector.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/WebServiceRefInjector.java	2006-12-07 15:34:02 UTC (rev 58900)
+++ trunk/ejb3/src/main/org/jboss/injection/WebServiceRefInjector.java	2006-12-07 15:39:30 UTC (rev 58901)
@@ -29,7 +29,8 @@
 
 import org.jboss.logging.Logger;
 import org.jboss.metamodel.descriptor.ServiceRef;
-import org.jboss.ws.jaxws.injection.WebServiceRefDeployer;
+import org.jboss.ws.core.jaxws.client.UnifiedServiceRef;
+import org.jboss.ws.core.jaxws.client.WebServiceRefDeployer;
 
 /**
  * Inject a jaxws web service ref.
@@ -71,9 +72,9 @@
       }
    }
 
-   private org.jboss.ws.jaxws.injection.ServiceRef getAdaptedServiceRef()
+   private UnifiedServiceRef getAdaptedServiceRef()
    {
-      org.jboss.ws.jaxws.injection.ServiceRef newRef = new org.jboss.ws.jaxws.injection.ServiceRef();
+      UnifiedServiceRef newRef = new UnifiedServiceRef();
       newRef.setEncName(sref.getEncName());
       newRef.setWsdlLocation(sref.getWsdlLocation());
       newRef.setConfigName(sref.getConfigName());



From thomas.diesler at jboss.com  Thu Dec  7 10:41:14 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Thu, 07 Dec 2006 10:41:14 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1GsLN4-00031Q-98@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/07 10:41:14

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  reorganised package structure
  
  Revision  Changes    Path
  1.33      +4 -6      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- component-info.xml	6 Dec 2006 05:33:00 -0000	1.32
  +++ component-info.xml	7 Dec 2006 15:41:14 -0000	1.33
  @@ -5,18 +5,16 @@
                 version="snapshot"
                 description="JBossWS an implementation of J2EE Web Services">
   
  +      <artifact id="jbossws.sar"/>
  +      <artifact id="jbossws-client.jar"/>
         <artifact id="jboss-jaxrpc.jar"/>
         <artifact id="jboss-jaxws.jar"/>
         <artifact id="jboss-saaj.jar"/>
  -      <artifact id="jbossws-client.jar"/>
  -      <artifact id="jbossws.sar"/>
  -      <artifact id="jbossws-src.zip"/>
   
         <import componentref="apache-xmlsec">
         	<compatible version="1.3.0"/>
         </import>
         <import componentref="javassist">
  -      	<compatible version="3.3.0.GA"/>
         	<compatible version="3.4.GA"/>
         </import>
         <import componentref="ibm-wsdl4j">
  @@ -33,11 +31,11 @@
         </import>
   
         <export>
  +         <include input="jbossws.sar"/>
  +         <include input="jbossws-client.jar"/>
            <include input="jboss-jaxrpc.jar"/>
            <include input="jboss-jaxws.jar"/>
            <include input="jboss-saaj.jar"/>
  -         <include input="jbossws-client.jar"/>
  -         <include input="jbossws.sar"/>
         </export>
   
      </component>
  
  
  


From thomas.diesler at jboss.com  Thu Dec  7 10:41:21 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Thu, 07 Dec 2006 10:41:21 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1GsLNB-000322-7p@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/07 10:41:21

  Modified:    jboss/jbossws/snapshot/lib        jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws.sar
  Added:       jboss/jbossws/snapshot/lib       
                        jbossws-jboss-integration.jar
                        jbossws-tomcat-integration.jar
  Log:
  reorganised package structure
  
  Revision  Changes    Path
  1.28      +133 -140  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.27      +213 -256  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.28      +94 -97    repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.39      +5619 -5506repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.39      +4586 -4569repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/07 15:41:15;  author: tdiesler;  state: Exp;repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/07 15:41:15;  author: tdiesler;  state: Exp;repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar
  
  	<<Binary file>>
  
  


From mazz at jboss.com  Thu Dec  7 10:42:53 2006
From: mazz at jboss.com (John Mazzitelli)
Date: Thu, 07 Dec 2006 10:42:53 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6 - New
	directory ...
Message-ID: <E1GsLOf-00033t-Mk@committer01.frg.pub.inap.atl.jboss.com>

  User: jmazzitelli
  Date: 06/12/07 10:42:53

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6 added to the repository


From mazz at jboss.com  Thu Dec  7 10:44:58 2006
From: mazz at jboss.com (John Mazzitelli)
Date: Thu, 07 Dec 2006 10:44:58 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6 ...
Message-ID: <E1GsLQg-00034U-Jj@committer01.frg.pub.inap.atl.jboss.com>

  User: jmazzitelli
  Date: 06/12/07 10:44:58

  Added:       maven2/i18nlog/i18nlog/1.0.6       i18nlog-1.0.6.jar
                        i18nlog-1.0.6.jar.md5 i18nlog-1.0.6.jar.sha1
                        i18nlog-1.0.6.pom i18nlog-1.0.6.pom.md5
                        i18nlog-1.0.6.pom.sha1
  Log:
  add the i18nlog 1.0.6 version - jboss-on uses it
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 15:44:58;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/07 15:44:58;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.jar.md5
  
  Index: i18nlog-1.0.6.jar.md5
  ===================================================================
  4ac321fa66122eeb88a98337266b80c7
  
  
  1.1      date: 2006/12/07 15:44:58;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.jar.sha1
  
  Index: i18nlog-1.0.6.jar.sha1
  ===================================================================
  2884e397868f652ccbc521117b1b8bba26042836
  
  
  1.1      date: 2006/12/07 15:44:58;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.pom
  
  Index: i18nlog-1.0.6.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>i18nlog</groupId>
    <artifactId>i18nlog</artifactId>
    <version>1.0.6</version>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/07 15:44:58;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.pom.md5
  
  Index: i18nlog-1.0.6.pom.md5
  ===================================================================
  f639e566e8a3e307bed558a743dc051b
  
  
  1.1      date: 2006/12/07 15:44:58;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.pom.sha1
  
  Index: i18nlog-1.0.6.pom.sha1
  ===================================================================
  cbf7433677293a634c7b2d91a27b5a8844a0f73f
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 12:21:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 12:21:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r58903 -
	trunk/server/src/main/org/jboss/ejb
Message-ID: <E1GsMw8-0004tO-0J@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-07 12:21:31 -0500 (Thu, 07 Dec 2006)
New Revision: 58903

Modified:
   trunk/server/src/main/org/jboss/ejb/EjbModule.java
Log:
use the shorter name for jacc context id

Modified: trunk/server/src/main/org/jboss/ejb/EjbModule.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EjbModule.java	2006-12-07 16:15:12 UTC (rev 58902)
+++ trunk/server/src/main/org/jboss/ejb/EjbModule.java	2006-12-07 17:21:31 UTC (rev 58903)
@@ -47,7 +47,7 @@
 import javax.transaction.TransactionManager;
 
 import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.deployers.spi.structure.DeploymentContext; 
 import org.jboss.deployment.DeploymentException;
 import org.jboss.deployment.DeploymentInfo;
 import org.jboss.deployment.EARDeployerMBean;
@@ -62,8 +62,7 @@
 import org.jboss.metadata.XmlLoadable;
 import org.jboss.metadata.MethodMetaData;
 import org.jboss.metadata.SecurityRoleRefMetaData;
-import org.jboss.mx.loading.RepositoryClassLoader;
-import org.jboss.ejb.deployers.EjbDeployer;
+import org.jboss.mx.loading.RepositoryClassLoader; 
 import org.jboss.ejb.plugins.SecurityProxyInterceptor;
 import org.jboss.ejb.plugins.StatefulSessionInstancePool;
 import org.jboss.security.AuthenticationManager;
@@ -365,7 +364,7 @@
          Iterator beans = appMetaData.getEnterpriseBeans();
          String contextID = appMetaData.getJaccContextID();
          if( contextID == null )
-            contextID = deploymentUnit.getSimpleName();
+            contextID = shortNameFromDeploymentName(deploymentUnit.getSimpleName()); 
          appMetaData.setJaccContextID(contextID);
          PolicyConfigurationFactory pcFactory = PolicyConfigurationFactory.getPolicyConfigurationFactory();
          PolicyConfiguration pc = pcFactory.getPolicyConfiguration(contextID, true);
@@ -383,7 +382,7 @@
             // Link this to the parent PC
             DeploymentContext current = deploymentUnit.getDeploymentContext();
             while (current.getParent() != null)
-               current = current.getParent();
+               current = current.getParent(); 
             PolicyConfiguration parentPC =
                current.getTransientAttachments().getAttachment(PolicyConfiguration.class);
             if (parentPC != null && parentPC != pc)
@@ -1294,7 +1293,28 @@
          ((XmlLoadable) ic).importXml(conf.getContainerCacheConf());
 
       return ic;
-   }  
+   } 
+   
+   /**
+    * A utility method that takes a deployment unit name and strips it down to the base jar
+    * name without the .jar suffix.
+    * @param name - the DeploymentUnit name.
+    */
+   public static String shortNameFromDeploymentName(String name)
+   {
+      String shortName = name.trim();
+      String[] parts = name.split("/|\\.|\\!");
+      if( parts.length > 1 )
+      {
+         // If it ends in .war, use the previous part
+         if( parts[parts.length-1].equals("jar") )
+            shortName = parts[parts.length-2];
+         // else use the last part
+         else
+            shortName = parts[parts.length-1];
+      }
+      return shortName;
+   }
 }
 /*
 vim:ts=3:sw=3:et



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 12:22:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 12:22:01 -0500
Subject: [jboss-cvs] JBossAS SVN: r58904 - in trunk/server/src:
	etc/deployers main/org/jboss/deployment
Message-ID: <E1GsMwb-0004uS-Hq@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-07 12:22:00 -0500 (Thu, 07 Dec 2006)
New Revision: 58904

Added:
   trunk/server/src/main/org/jboss/deployment/EARInitializingDeployer.java
Modified:
   trunk/server/src/etc/deployers/ear-deployer-beans.xml
Log:
an initializing ear deployer for jacc initialization

Modified: trunk/server/src/etc/deployers/ear-deployer-beans.xml
===================================================================
--- trunk/server/src/etc/deployers/ear-deployer-beans.xml	2006-12-07 17:21:31 UTC (rev 58903)
+++ trunk/server/src/etc/deployers/ear-deployer-beans.xml	2006-12-07 17:22:00 UTC (rev 58904)
@@ -42,5 +42,17 @@
          </parameter>
       </uninstall>
    </bean>
-   
+
+   <bean name="EARInitializingDeployer" class="org.jboss.deployment.EARInitializingDeployer">
+      <install bean="MainDeployer" method="addDeployer">
+         <parameter>
+            <this/>
+         </parameter>
+      </install>
+      <uninstall bean="MainDeployer" method="removeDeployer">
+         <parameter>
+            <this/>
+         </parameter>
+      </uninstall>
+   </bean>
 </deployment>

Added: trunk/server/src/main/org/jboss/deployment/EARInitializingDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/EARInitializingDeployer.java	2006-12-07 17:21:31 UTC (rev 58903)
+++ trunk/server/src/main/org/jboss/deployment/EARInitializingDeployer.java	2006-12-07 17:22:00 UTC (rev 58904)
@@ -0,0 +1,96 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.deployment;
+
+import javax.security.jacc.PolicyConfiguration;
+import javax.security.jacc.PolicyConfigurationFactory;
+import javax.security.jacc.PolicyContextException;
+
+import org.jboss.deployers.plugins.deployers.helpers.AbstractSimpleRealDeployer;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
+
+//$Id$
+
+/**
+ *  EAR Deployer that can be used for initialization
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 6, 2006 
+ *  @version $Revision$
+ */
+public class EARInitializingDeployer extends AbstractSimpleRealDeployer<J2eeApplicationMetaData>
+{    
+   public EARInitializingDeployer()
+   {
+      super(J2eeApplicationMetaData.class);
+   } 
+
+   public void deploy(DeploymentUnit unit, J2eeApplicationMetaData deployment) throws DeploymentException
+   { 
+      //Perform JACC Policy Configuration
+      String contextID =  shortNameFromDeploymentName(unit.getSimpleName()); 
+      PolicyConfigurationFactory pcFactory = null;
+      try
+      {
+         pcFactory = PolicyConfigurationFactory.getPolicyConfigurationFactory();
+         PolicyConfiguration pc = pcFactory.getPolicyConfiguration(contextID, true);
+         unit.addAttachment(PolicyConfiguration.class, pc);
+      } 
+      catch (PolicyContextException e)
+      { 
+         throw new DeploymentException("PolicyContextException generated in deploy", e);
+      }
+      catch(Exception e)
+      {
+         throw new DeploymentException("Exception generated in deploy", e);
+      }
+      
+   }
+ 
+   public void undeploy(DeploymentUnit unit, J2eeApplicationMetaData deployment)
+   {  
+      //Perform JACC cleanup for the EAR
+      unit.removeAttachment(PolicyConfiguration.class);
+   } 
+   
+   
+   /**
+    * A utility method that takes a deployment unit name and strips it down to the base ear
+    * name without the .ear suffix.
+    * @param name - the DeploymentUnit name.
+    */
+   public static String shortNameFromDeploymentName(String name)
+   {
+      String shortName = name.trim();
+      String[] parts = name.split("/|\\.|\\!");
+      if( parts.length > 1 )
+      {
+         // If it ends in .war, use the previous part
+         if( parts[parts.length-1].equals("ear") )
+            shortName = parts[parts.length-2];
+         // else use the last part
+         else
+            shortName = parts[parts.length-1];
+      }
+      return shortName;
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 12:36:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 12:36:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r58905 - in
	trunk/testsuite/src/main/org/jboss/test/ws: . jaxws/webserviceref
Message-ID: <E1GsNAU-000565-MY@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-07 12:36:20 -0500 (Thu, 07 Dec 2006)
New Revision: 58905

Modified:
   trunk/testsuite/src/main/org/jboss/test/ws/JBossWSTest.java
   trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefClientTestCase.java
   trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefEJB3TestCase.java
   trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefServletTestCase.java
Log:
remove dependencies on non public api

Modified: trunk/testsuite/src/main/org/jboss/test/ws/JBossWSTest.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/ws/JBossWSTest.java	2006-12-07 17:22:00 UTC (rev 58904)
+++ trunk/testsuite/src/main/org/jboss/test/ws/JBossWSTest.java	2006-12-07 17:36:20 UTC (rev 58905)
@@ -35,7 +35,7 @@
 import junit.framework.TestCase;
 
 import org.jboss.logging.Logger;
-import org.jboss.ws.utils.DOMWriter;
+import org.jboss.util.xml.DOMWriter;
 import org.w3c.dom.Element;
 import org.w3c.dom.Node;
 import org.w3c.dom.NodeList;

Modified: trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefClientTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefClientTestCase.java	2006-12-07 17:22:00 UTC (rev 58904)
+++ trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefClientTestCase.java	2006-12-07 17:36:20 UTC (rev 58905)
@@ -21,8 +21,6 @@
  */
 package org.jboss.test.ws.jaxws.webserviceref;
 
-import java.io.File;
-import java.net.MalformedURLException;
 import java.net.URL;
 
 import javax.xml.namespace.QName;
@@ -32,8 +30,6 @@
 
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitionsFactory;
 
 /**
  * Test the JAXWS annotation: javax.xml.ws.WebServiceref
@@ -50,14 +46,6 @@
       return JBossWSTestSetup.newTestSetup(WebServiceRefClientTestCase.class, "jaxws-webserviceref.war, jaxws-webserviceref-client.jar");
    }
 
-   public void testWSDLAccess() throws MalformedURLException
-   {
-      URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
-      WSDLDefinitionsFactory factory = WSDLDefinitionsFactory.newInstance();
-      WSDLDefinitions wsdlDefinitions = factory.parse(wsdlURL);
-      assertNotNull(wsdlDefinitions);
-   }
-   
    public void testDynamicProxy() throws Exception
    {
       URL wsdlURL = getResource("ws/jaxws/webserviceref/META-INF/wsdl/TestEndpoint.wsdl");

Modified: trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefEJB3TestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefEJB3TestCase.java	2006-12-07 17:22:00 UTC (rev 58904)
+++ trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefEJB3TestCase.java	2006-12-07 17:36:20 UTC (rev 58905)
@@ -21,7 +21,6 @@
  */
 package org.jboss.test.ws.jaxws.webserviceref;
 
-import java.net.MalformedURLException;
 import java.net.URL;
 
 import javax.naming.InitialContext;
@@ -32,8 +31,6 @@
 
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitionsFactory;
 
 /**
  * Test the JAXWS annotation: javax.xml.ws.WebServiceref
@@ -50,14 +47,6 @@
       return JBossWSTestSetup.newTestSetup(WebServiceRefEJB3TestCase.class, "jaxws-webserviceref.war, jaxws-webserviceref-ejb3-client.jar");
    }
 
-   public void testWSDLAccess() throws MalformedURLException
-   {
-      URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
-      WSDLDefinitionsFactory factory = WSDLDefinitionsFactory.newInstance();
-      WSDLDefinitions wsdlDefinitions = factory.parse(wsdlURL);
-      assertNotNull(wsdlDefinitions);
-   }
-   
    public void testDynamicProxy() throws Exception
    {
       URL wsdlURL = super.getResource("ws/jaxws/webserviceref/META-INF/wsdl/TestEndpoint.wsdl");

Modified: trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefServletTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefServletTestCase.java	2006-12-07 17:22:00 UTC (rev 58904)
+++ trunk/testsuite/src/main/org/jboss/test/ws/jaxws/webserviceref/WebServiceRefServletTestCase.java	2006-12-07 17:36:20 UTC (rev 58905)
@@ -22,9 +22,7 @@
 package org.jboss.test.ws.jaxws.webserviceref;
 
 import java.io.BufferedReader;
-import java.io.File;
 import java.io.InputStreamReader;
-import java.net.MalformedURLException;
 import java.net.URL;
 
 import javax.xml.namespace.QName;
@@ -34,8 +32,6 @@
 
 import org.jboss.test.ws.JBossWSTest;
 import org.jboss.test.ws.JBossWSTestSetup;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitionsFactory;
 
 /**
  * Test the JAXWS annotation: javax.xml.ws.WebServiceref
@@ -52,14 +48,6 @@
       return JBossWSTestSetup.newTestSetup(WebServiceRefServletTestCase.class, "jaxws-webserviceref.war, jaxws-webserviceref-servlet-client.war");
    }
 
-   public void testWSDLAccess() throws MalformedURLException
-   {
-      URL wsdlURL = new URL(TARGET_ENDPOINT_ADDRESS + "?wsdl");
-      WSDLDefinitionsFactory factory = WSDLDefinitionsFactory.newInstance();
-      WSDLDefinitions wsdlDefinitions = factory.parse(wsdlURL);
-      assertNotNull(wsdlDefinitions);
-   }
-   
    public void testDynamicProxy() throws Exception
    {
       URL wsdlURL = getResource("ws/jaxws/webserviceref/META-INF/wsdl/TestEndpoint.wsdl");



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 13:21:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 13:21:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r58906 - in trunk: build ejb3 j2ee
	j2ee/src/main/javax/xml server tools/etc/buildmagic varia
Message-ID: <E1GsNro-0006Af-6E@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-07 13:21:00 -0500 (Thu, 07 Dec 2006)
New Revision: 58906

Removed:
   trunk/j2ee/src/main/javax/xml/rpc/
   trunk/j2ee/src/main/javax/xml/soap/
Modified:
   trunk/build/build-distr.xml
   trunk/ejb3/build.xml
   trunk/j2ee/build.xml
   trunk/server/build.xml
   trunk/tools/etc/buildmagic/modules.ent
   trunk/varia/build.xml
Log:
remove jaxrpc, saaj api from as

Modified: trunk/build/build-distr.xml
===================================================================
--- trunk/build/build-distr.xml	2006-12-07 17:36:20 UTC (rev 58905)
+++ trunk/build/build-distr.xml	2006-12-07 18:21:00 UTC (rev 58906)
@@ -296,8 +296,6 @@
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
         <include name="jboss-j2ee.jar"/>
-        <include name="jboss-jaxrpc.jar"/>
-        <include name="jboss-saaj.jar"/>
       </fileset>
     </copy>
 
@@ -306,8 +304,6 @@
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
         <include name="jboss-j2ee.jar"/>
-        <include name="jboss-jaxrpc.jar"/>
-        <include name="jboss-saaj.jar"/>
       </fileset>
       <fileset dir="${sun.jaf.lib}">
         <include name="activation.jar"/>
@@ -1830,6 +1826,8 @@
       </fileset>
       <fileset dir="${jboss.jbossws.lib}">
         <include name="jbossws-client.jar"/>
+        <include name="jboss-jaxrpc.jar"/>
+        <include name="jboss-saaj.jar"/>
       </fileset>
     </copy>
 
@@ -1852,6 +1850,10 @@
       <fileset dir="${apache.logging.lib}">
         <include name="commons-logging.jar"/>
       </fileset>
+      <fileset dir="${jboss.jbossws.lib}">
+        <include name="jboss-jaxrpc.jar"/>
+        <include name="jboss-saaj.jar"/>
+      </fileset>
     </copy>
 
 

Modified: trunk/ejb3/build.xml
===================================================================
--- trunk/ejb3/build.xml	2006-12-07 17:36:20 UTC (rev 58905)
+++ trunk/ejb3/build.xml	2006-12-07 18:21:00 UTC (rev 58906)
@@ -485,7 +485,7 @@
          <zipfileset src="${jboss.jca.lib}/jboss-xa-jdbc.jar" />
          <zipfileset src="${jboss.system.lib}/jboss-system.jar" />
          <zipfileset src="${jboss.serialization.lib}/jboss-serialization.jar" />
-         <zipfileset src="${jboss.j2ee.lib}/jboss-jaxrpc.jar" />
+         <zipfileset src="${jboss.jbossws.lib}/jboss-jaxrpc.jar" />
       </jar>
       
       

Modified: trunk/j2ee/build.xml
===================================================================
--- trunk/j2ee/build.xml	2006-12-07 17:36:20 UTC (rev 58905)
+++ trunk/j2ee/build.xml	2006-12-07 18:21:00 UTC (rev 58906)
@@ -77,6 +77,7 @@
       <path refid="apache.xerces.classpath"/>
       <path refid="sun.jaf.classpath"/>
       <path refid="sun.servlet.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
     </path>
 
     <!-- ======= -->
@@ -229,28 +230,12 @@
         <include name="javax/sql/**"/>
         <include name="javax/transaction/**"/>
         <include name="javax/xml/**"/>
-        <exclude name="javax/xml/rpc/**"/>
-        <exclude name="javax/xml/soap/**"/>
       </fileset>
       <fileset dir="${jboss.jmx.root}/classes">
         <include name="javax/management/**"/>
       </fileset>
     </jar>
 
-    <jar jarfile="${build.lib}/jboss-jaxrpc.jar"
-      manifest="${build.etc}/default.mf">
-      <fileset dir="${build.classes}">
-        <include name="javax/xml/rpc/**"/>
-      </fileset>
-    </jar>
-
-    <jar jarfile="${build.lib}/jboss-saaj.jar"
-      manifest="${build.etc}/default.mf">
-      <fileset dir="${build.classes}">
-        <include name="javax/xml/soap/**"/>
-      </fileset>
-    </jar>
-
   </target>
 
   <!-- ================================================================== -->

Modified: trunk/server/build.xml
===================================================================
--- trunk/server/build.xml	2006-12-07 17:36:20 UTC (rev 58905)
+++ trunk/server/build.xml	2006-12-07 18:21:00 UTC (rev 58906)
@@ -86,6 +86,7 @@
       <path refid="sun.servlet.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
       <path refid="jboss.microcontainer.classpath"/>
     </path>
 
@@ -96,8 +97,8 @@
     &modules;
     <!-- The combined dependant module classpath -->
     <path id="dependentmodule.classpath">
+      <path refid="ejb3-persistence.classpath"/>
       <path refid="jboss.j2ee.classpath"/>
-      <path refid="ejb3-persistence.classpath"/>
       <path refid="jboss.common.core.classpath"/>
       <path refid="jboss.common.logging.spi.classpath"/>
       <path refid="jboss.common.logging.log4j.classpath"/>

Modified: trunk/tools/etc/buildmagic/modules.ent
===================================================================
--- trunk/tools/etc/buildmagic/modules.ent	2006-12-07 17:36:20 UTC (rev 58905)
+++ trunk/tools/etc/buildmagic/modules.ent	2006-12-07 18:21:00 UTC (rev 58906)
@@ -68,8 +68,6 @@
 <property name="jboss.j2ee.lib" value="${jboss.j2ee.root}/lib"/>
 <path id="jboss.j2ee.classpath">
   <pathelement path="${jboss.j2ee.lib}/jboss-j2ee.jar"/>
-  <pathelement path="${jboss.j2ee.lib}/jboss-jaxrpc.jar"/>
-  <pathelement path="${jboss.j2ee.lib}/jboss-saaj.jar"/>
 </path>
 
 <!-- J2SE -->

Modified: trunk/varia/build.xml
===================================================================
--- trunk/varia/build.xml	2006-12-07 17:36:20 UTC (rev 58905)
+++ trunk/varia/build.xml	2006-12-07 18:21:00 UTC (rev 58906)
@@ -92,6 +92,7 @@
       <path refid="oswego.concurrent.classpath"/>
       <path refid="juddi.juddi.classpath"/>
       <path refid="jboss.microcontainer.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
     </path>
 



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 14:15:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 14:15:57 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1717 - in
	branches/Branch_Client_Failover_Experiment/tests: . bin etc
	src/org/jboss/test/messaging/jms
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/tools
	src/org/jboss/test/messaging/tools/jmx
	src/org/jboss/test/messaging/tools/jmx/rmi
	src/org/jboss/test/messaging/tools/jndi
Message-ID: <E1GsOir-0007H5-Ls@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-07 14:15:49 -0500 (Thu, 07 Dec 2006)
New Revision: 1717

Modified:
   branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
   branches/Branch_Client_Failover_Experiment/tests/bin/stop-rmi-server
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
Log:
committing changes that were supposed to be in repository since yesterday: modified the test framwork for a higher flexibility in running clustered tests

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example	2006-12-07 19:15:49 UTC (rev 1717)
@@ -20,6 +20,9 @@
 # be also permitting sharing over a LAN. "mysql" allows this, "hsqldb" doesn't. The test will
 # quickly fail in such a situation.
 #
+# It is also possible to configure a test to run in clustered mode by using the "-clustered"
+# switch.
+#
 CLUSTERED=true
 #
 #

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-07 19:15:49 UTC (rev 1717)
@@ -97,6 +97,9 @@
     if [ "$1" = "-remotedebug" ]; then
         REMOTE_DEBUG_FLAG="-debug"
     fi
+    if [ "$1" = "-clustered" ]; then
+        TEST_CLUSTERED=true
+    fi
     shift
 done
 
@@ -109,6 +112,13 @@
 if [ "$isRemote" = "true" ]; then
   export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED
   $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file
+
+  if [ "$TEST_CLUSTERED" = "true" ]; then
+
+     # start the second remote server
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file -index 1
+  fi
+
 fi
 
 
@@ -116,6 +126,10 @@
 org.jboss.test.messaging.tools.junit.SelectiveTestRunner $TARGET_CLASS $TARGET_TEST
 
 if [ "$isRemote" = "true" ]; then
+  $reldir/stop-rmi-server -use-existent-test-classpath-file -index 1
+
+  # stop the second remote server
   $reldir/stop-rmi-server -use-existent-test-classpath-file
+
 fi
 

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-07 19:15:49 UTC (rev 1717)
@@ -27,6 +27,9 @@
         else
             JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=y,address=rmiserver"
         fi
+    elif [ "$1" = "-index" ]; then
+        shift
+        index=$1
     elif [ "$1" = "-use-existent-test-classpath-file" ]; then
         USE_EXISTENT_TEST_CLASSPATH_FILE=true;
     fi
@@ -49,6 +52,9 @@
    JAVA_OPTS="$JAVA_OPTS -Dtest.clustered=$TEST_CLUSTERED"
 fi
 
+if [ "$index" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.server.index=$index"
+fi
 
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
@@ -68,4 +74,4 @@
 JAVA_OPTS="$JAVA_OPTS -Xmx768M"
 
 java $JAVA_OPTS -cp $CLASSPATH -Dtest.bind.address=localhost \
-org.jboss.test.messaging.tools.jmx.rmi.RMITestServer &
+org.jboss.test.messaging.tools.jmx.rmi.RMITestServer $port &

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/stop-rmi-server
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/stop-rmi-server	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/stop-rmi-server	2006-12-07 19:15:49 UTC (rev 1717)
@@ -27,10 +27,17 @@
         fi
     elif [ "$1" = "-use-existent-test-classpath-file" ]; then
         USE_EXISTENT_TEST_CLASSPATH_FILE=true;
+    elif [ "$1" = "-index" ]; then
+        shift
+        index=$1
     fi
     shift
 done
 
+if [ "$index" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.server.index=$index"
+fi
+
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
 else

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-07 19:15:49 UTC (rev 1717)
@@ -281,7 +281,7 @@
            description="Starts the RMI server used by clustering tests">
 
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
-         <sysproperty key="test.registry.index" value="${test.registry.index}"/>
+         <sysproperty key="test.server.index" value="${test.server.index}"/>
          <sysproperty key="module.output" value="${tests.output}"/>
          <sysproperty key="remote.test.suffix" value="-remote"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
@@ -319,7 +319,7 @@
            description="Stops the RMI server used by clustering tests">
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.StopRMIServer"
             classpathref="test.execution.classpath">
-         <sysproperty key="test.registry.index" value="${test.registry.index}"/>
+         <sysproperty key="test.server.index" value="${test.server.index}"/>
       </java>
    </target>
 
@@ -633,26 +633,26 @@
       <!-- Stop the rmi servers in case a previous run aborted -->
 
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="0"/>
+         <param name="test.server.index" value="0"/>
       </antcall>
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="1"/>
+         <param name="test.server.index" value="1"/>
       </antcall>
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="2"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
 
       <!-- Start 3 rmi servers -->
 
       <antcall target="start-rmi-server-clustering">
-         <param name="test.registry.index" value="0"/>
+         <param name="test.server.index" value="0"/>
       </antcall>
 
       <antcall target="start-rmi-server-clustering">
-         <param name="test.registry.index" value="1"/>
+         <param name="test.server.index" value="1"/>
       </antcall>
       <antcall target="start-rmi-server-clustering">
-         <param name="test.registry.index" value="2"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
 
 
@@ -711,13 +711,13 @@
       </junit>
 
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="0"/>
+         <param name="test.server.index" value="0"/>
       </antcall>
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="1"/>
+         <param name="test.server.index" value="1"/>
       </antcall>
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="2"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
 
    </target>

Modified: branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-07 19:15:49 UTC (rev 1717)
@@ -68,6 +68,20 @@
 
    <serialization-type>jms</serialization-type>
 
+
+   <!--
+      Specifies whether to start a clustered messaging server or not. If "test.clustered" is set,
+      the value of the system property takes precedence. Supported values are "true" or "false".
+
+      Setting "clustered" to "true" doesn't guarantee that the test will be actually run in
+      clustered mode, the test database must be also permitting sharing over a LAN. "mysql" allows
+      this, "hsqldb" doesn't. The test will quickly fail in such a situation.
+   -->
+
+   <!--
+   <clustered>true</clustered>
+   -->
+
 </container>
 
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -87,6 +87,11 @@
       super.tearDown();
    }
 
+   public void testNoop() throws Exception
+   {
+      log.info("noop");
+   }
+
    public void test_NonPersistent_NonTransactional() throws Exception
    {
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -92,27 +92,27 @@
       {
          startServer(0);
          startServer(1);
-         startServer(2);
-
+//         startServer(2);
+//
          ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
          ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-         
+//         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+//
          log.info("Deployed destinations ok");
-
+//
          cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
          cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
-
+//         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
+//
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
-
+//         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
+//
          topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
          topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
-
-         drainQueues();
+//         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
+//
+//         drainQueues();
       }
       catch (Exception e)
       {
@@ -133,8 +133,6 @@
    {
       try
       {
-         super.tearDown();
-
          ServerManagement.log(ServerManagement.INFO,"Undeploying Server 0");
          ServerManagement.undeployQueue("testDistributedQueue", 0);
          ServerManagement.undeployTopic("testDistributedTopic", 0);
@@ -142,6 +140,9 @@
          ServerManagement.log(ServerManagement.INFO,"Undeploying Server 1");
          ServerManagement.undeployQueue("testDistributedQueue", 1);
          ServerManagement.undeployTopic("testDistributedTopic", 1);
+//
+//         ServerManagement.undeployQueue("testDistributedQueue", 2);
+//         ServerManagement.undeployTopic("testDistributedTopic", 2);
 
          ServerManagement.log(ServerManagement.INFO,"Undeploying Server 2");
          ServerManagement.undeployQueue("testDistributedQueue", 2);
@@ -149,7 +150,9 @@
 
          ic1.close();
          ic2.close();
-         ic3.close();
+//         ic3.close();
+
+         super.tearDown();
       }
       catch (Exception e)
       {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -37,85 +37,97 @@
  */
 public class ManualClusteringTest extends ClusteringBase
 {
+
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
    public ManualClusteringTest(String name)
    {
       super(name);
    }
-   
 
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-   }
+   // Public --------------------------------------------------------
 
-   protected void tearDown() throws Exception
-   {
-         super.tearDown();
-   }
-   
    public void testClusteredQueueLocalConsumerNonPersistent() throws Exception
    {
-      clusteredQueueLocalConsumer(false);
+      System.out.println("xxxxxxxxxxxx");
+//      clusteredQueueLocalConsumer(false);
    }
-   
+
    public void testClusteredQueueLocalConsumerPersistent() throws Exception
    {
       clusteredQueueLocalConsumer(true);
    }
-        
+
    public void testClusteredTopicNonDurableNonPersistent() throws Exception
    {
       clusteredTopicNonDurable(false);
    }
-   
+
    public void testClusteredTopicNonDurablePersistent() throws Exception
    {
       clusteredTopicNonDurable(true);
    }
-      
+
    public void testClusteredTopicNonDurableWithSelectorsNonPersistent() throws Exception
    {
       clusteredTopicNonDurableWithSelectors(false);
    }
-   
+
    public void testClusteredTopicNonDurableWithSelectorsPersistent() throws Exception
    {
       clusteredTopicNonDurableWithSelectors(true);
    }
-   
+
    public void testClusteredTopicDurableNonPersistent() throws Exception
    {
       clusteredTopicDurable(false);
    }
-   
+
    public void testClusteredTopicDurablePersistent() throws Exception
    {
       clusteredTopicDurable(true);
    }
-   
+
    public void testClusteredTopicSharedDurableLocalConsumerNonPersistent() throws Exception
    {
       clusteredTopicSharedDurableLocalConsumer(false);
    }
-   
+
    public void testClusteredTopicSharedDurableLocalConsumerPersistent() throws Exception
    {
       clusteredTopicSharedDurableLocalConsumer(true);
    }
-   
+
    public void testClusteredTopicSharedDurableNoLocalSubNonPersistent() throws Exception
    {
       clusteredTopicSharedDurableNoLocalSub(false);
    }
-   
+
    public void testClusteredTopicSharedDurableNoLocalSubPersistent() throws Exception
    {
       clusteredTopicSharedDurableNoLocalSub(true);
    }
-   
-   
-   
-   
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+   }
+
+   protected void tearDown() throws Exception
+   {
+         super.tearDown();
+   }
+
    /*
     * Create a consumer on each queue on each node.
     * Send messages in turn from all nodes.
@@ -124,307 +136,308 @@
    protected void clusteredQueueLocalConsumer(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
       try
       {
          conn1 = cf1.createConnection();
-         
+
          conn2 = cf2.createConnection();
-         
+
          conn3 = cf3.createConnection();
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          MessageConsumer cons1 = sess1.createConsumer(queue1);
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue2);
-         
+
          MessageConsumer cons3 = sess3.createConsumer(queue3);
-         
+
          conn1.start();
-         
+
          conn2.start();
-         
+
          conn3.start();
-         
+
          //Send at node1
-         
+
          MessageProducer prod1 = sess1.createProducer(queue1);
-         
+
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             prod1.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          Message m = cons2.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
+
          // Send at node2
-         
+
          MessageProducer prod2 = sess2.createProducer(queue2);
-         
+
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess2.createTextMessage("message" + i);
-            
+
             prod2.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
+
          // Send at node3
-         
+
          MessageProducer prod3 = sess3.createProducer(queue3);
-         
+
          prod3.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess3.createTextMessage("message" + i);
-            
+
             prod3.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons2.receive(2000);
-         
-         assertNull(m);         
+
+         assertNull(m);
       }
       finally
-      {      
+      {
          if (conn1 != null) conn1.close();
-         
+
          if (conn2 != null) conn2.close();
-         
+
          if (conn3 != null) conn3.close();
       }
    }
-   
-   
+
+   // Private -------------------------------------------------------
+
    /*
     * Create non durable subscriptions on all nodes of the cluster.
     * Ensure all messages are receive as appropriate
     */
-   public void clusteredTopicNonDurable(boolean persistent) throws Exception
+   private void clusteredTopicNonDurable(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
       try
       {
          conn1 = cf1.createConnection();
-         
+
          conn2 = cf2.createConnection();
-         
+
          conn3 = cf3.createConnection();
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          MessageConsumer cons1 = sess1.createConsumer(topic1);
-         
+
          MessageConsumer cons2 = sess2.createConsumer(topic2);
-         
+
          MessageConsumer cons3 = sess3.createConsumer(topic3);
-         
+
          MessageConsumer cons4 = sess1.createConsumer(topic1);
-         
+
          MessageConsumer cons5 = sess2.createConsumer(topic2);
-            
+
          conn1.start();
-         
+
          conn2.start();
-         
+
          conn3.start();
-         
+
          //Send at node1
-         
+
          MessageProducer prod1 = sess1.createProducer(topic1);
-         
+
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             prod1.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-                        
-            assertEquals("message" + i, tm.getText());                        
+
+            assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-                      
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons4.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons5.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
+         }
       }
       finally
-      {      
+      {
          if (conn1 != null) conn1.close();
-         
+
          if (conn2 != null) conn2.close();
-         
+
          if (conn3 != null) conn3.close();
       }
    }
-   
-   
-   
-   
+
+
+
+
    /*
     * Create non durable subscriptions on all nodes of the cluster.
     * Include some with selectors
     * Ensure all messages are receive as appropriate
     */
-   public void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
+   private void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
       try
       {
          conn1 = cf1.createConnection();
-         
+
          conn2 = cf2.createConnection();
-         
+
          conn3 = cf3.createConnection();
-                             
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          MessageConsumer cons1 = sess1.createConsumer(topic1);
-         
+
          MessageConsumer cons2 = sess2.createConsumer(topic2);
-         
+
          MessageConsumer cons3 = sess3.createConsumer(topic3);
-         
+
          MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='red'");
-         
+
          MessageConsumer cons5 = sess2.createConsumer(topic2, "COLOUR='blue'");
-            
+
          conn1.start();
-         
+
          conn2.start();
-         
+
          conn3.start();
-         
+
          //Send at node1
-         
+
          MessageProducer prod1 = sess1.createProducer(topic1);
-         
+
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             int c = i % 3;
             if (c == 0)
             {
@@ -434,422 +447,422 @@
             {
                tm.setStringProperty("COLOUR", "blue");
             }
-            
+
             prod1.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-                        
-            assertEquals("message" + i, tm.getText());                        
+
+            assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-                      
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             int c = i % 3;
-            
+
             if (c == 0)
             {
                TextMessage tm = (TextMessage)cons4.receive(1000);
-                           
+
                assertNotNull(tm);
-                
+
                assertEquals("message" + i, tm.getText());
             }
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             int c = i % 3;
-            
+
             if (c == 1)
             {
                TextMessage tm = (TextMessage)cons5.receive(1000);
-                           
+
                assertNotNull(tm);
-                
+
                assertEquals("message" + i, tm.getText());
             }
-         } 
+         }
       }
       finally
-      {      
+      {
          if (conn1 != null) conn1.close();
-         
+
          if (conn2 != null) conn2.close();
-         
+
          if (conn3 != null) conn3.close();
       }
    }
-   
-   
-   
+
+
+
    /*
     * Create durable subscriptions on all nodes of the cluster.
     * Include a couple with selectors
     * Ensure all messages are receive as appropriate
     * None of the durable subs are shared
     */
-   public void clusteredTopicDurable(boolean persistent) throws Exception
+   private void clusteredTopicDurable(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
       try
       {
          conn1 = cf1.createConnection();
-         
+
          conn2 = cf2.createConnection();
-         
+
          conn3 = cf3.createConnection();
-         
+
          conn1.setClientID("wib1");
-         
+
          conn2.setClientID("wib1");
-         
+
          conn3.setClientID("wib1");
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-                  
-         try         
+
+         try
          {
             sess1.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess2.unsubscribe("sub2");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess3.unsubscribe("sub3");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess1.unsubscribe("sub4");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess2.unsubscribe("sub5");
          }
          catch (Exception ignore) {}
-         
+
          MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
-         
+
          MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub2");
-         
+
          MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub3");
-         
+
          MessageConsumer cons4 = sess1.createDurableSubscriber(topic1, "sub4");
-         
+
          MessageConsumer cons5 = sess2.createDurableSubscriber(topic2, "sub5");
-            
+
          conn1.start();
-         
+
          conn2.start();
-         
+
          conn3.start();
-         
+
          //Send at node1
-         
+
          MessageProducer prod1 = sess1.createProducer(topic1);
-         
+
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             prod1.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-                        
-            assertEquals("message" + i, tm.getText());                        
+
+            assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-                      
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons4.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons5.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          cons1.close();
-         
+
          cons2.close();
-         
+
          cons3.close();
-         
+
          cons4.close();
-         
+
          cons5.close();
-         
+
          sess1.unsubscribe("sub1");
-         
+
          sess2.unsubscribe("sub2");
-         
+
          sess3.unsubscribe("sub3");
-         
+
          sess1.unsubscribe("sub4");
-         
+
          sess2.unsubscribe("sub5");
-         
+
       }
       finally
-      {      
+      {
          if (conn1 != null) conn1.close();
-         
+
          if (conn2 != null) conn2.close();
-         
+
          if (conn3 != null) conn3.close();
       }
    }
-   
-   
-   
-   
+
+
+
+
    /*
     * Create shared durable subs on multiple nodes, the local instance should always get the message
     */
    protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
       try
       {
          conn1 = cf1.createConnection();
-         
+
          conn2 = cf2.createConnection();
-         
+
          conn3 = cf3.createConnection();
-         
+
          conn1.setClientID("wib1");
-         
+
          conn2.setClientID("wib1");
-         
+
          conn3.setClientID("wib1");
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         try         
+
+         try
          {
             sess1.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess2.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess3.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-         
+
          MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
-         
+
          MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
-         
+
          MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub1");
-         
+
          conn1.start();
-         
+
          conn2.start();
-         
+
          conn3.start();
-         
+
          //Send at node1
-         
+
          MessageProducer prod1 = sess1.createProducer(topic1);
-         
+
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             prod1.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          Message m = cons2.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
+
          // Send at node2
-         
+
          MessageProducer prod2 = sess2.createProducer(topic2);
-         
+
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess2.createTextMessage("message" + i);
-            
+
             prod2.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-            
+
             assertNotNull(tm);
-               
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
+
          // Send at node3
-         
+
          MessageProducer prod3 = sess3.createProducer(topic3);
-         
+
          prod3.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess3.createTextMessage("message" + i);
-            
+
             prod3.send(tm);
          }
-           
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons2.receive(2000);
-         
-         assertNull(m);         
-         
+
+         assertNull(m);
+
          cons1.close();
-         
+
          cons2.close();
-         
+
          cons3.close();
-         
+
          //Need to unsubscribe on any node that the durable sub was created on
-         
+
          sess1.unsubscribe("sub1");
-         
+
          sess2.unsubscribe("sub1");
-         
+
          sess3.unsubscribe("sub1");
       }
       finally
-      {      
+      {
          if (conn1 != null) conn1.close();
-         
+
          if (conn2 != null) conn2.close();
-         
+
          if (conn3 != null) conn3.close();
       }
    }
-   
-   
-   
+
+
+
    /*
     * Create shared durable subs on multiple nodes, but without sub on local node
     * should round robin
@@ -858,97 +871,97 @@
    protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
       try
       {
          conn1 = cf1.createConnection();
-         
+
          conn2 = cf2.createConnection();
-         
+
          conn3 = cf3.createConnection();
-         
+
          conn2.setClientID("wib1");
-         
+
          conn3.setClientID("wib1");
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         try         
+
+         try
          {
             sess2.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
             sess3.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-                  
+
          MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
-         
+
          MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub1");
-         
+
          conn2.start();
-         
+
          conn3.start();
-         
+
          //Send at node1
-         
+
          //Should round robin between the other 2 since there is no active consumer on sub1 on node1
-         
+
          MessageProducer prod1 = sess1.createProducer(topic1);
-         
+
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             prod1.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i * 2, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + (i * 2 + 1), tm.getText());
          }
-         
+
          cons2.close();
-         
+
          cons3.close();
-         
+
          sess2.unsubscribe("sub1");
-         
+
          sess3.unsubscribe("sub1");
-      
+
       }
       finally
-      {      
+      {
          if (conn1 != null) conn1.close();
-         
+
          if (conn2 != null) conn2.close();
-         
+
          if (conn3 != null) conn3.close();
       }
    }
@@ -956,7 +969,7 @@
    class MyListener implements MessageListener
    {
       private int i;
-      
+
       MyListener(int i)
       {
          this.i = i;
@@ -967,7 +980,7 @@
          try
          {
             int count = m.getIntProperty("count");
-            
+
             log.info("Listener " + i + " received message " + count);
          }
          catch (Exception e)
@@ -975,7 +988,12 @@
             e.printStackTrace();
          }
       }
-      
+
    }
+
+
+   // Inner classes -------------------------------------------------
+
    
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -52,6 +52,8 @@
 {
    // Constants -----------------------------------------------------
 
+   public static final int MAX_SERVER_COUNT = 10;
+
    // logging levels used by the remote client to forward log output on a remote server
    public static int FATAL = 0;
    public static int ERROR = 1;
@@ -69,7 +71,7 @@
 
    private static final int RMI_SERVER_LOOKUP_RETRIES = 10;
 
-   private static Server[] servers = new Server[RMITestServer.RMI_REGISTRY_PORTS.length];
+   private static Server[] servers = new Server[MAX_SERVER_COUNT];
 
    public static boolean isLocal()
    {
@@ -541,12 +543,13 @@
     * Simulates a destination un-deployment (deleting the destination descriptor from the deploy
     * directory).
     */
-   private static void undeployDestination(boolean isQueue, String name, int serverIndex) throws Exception
+   private static void undeployDestination(boolean isQueue, String name, int serverIndex)
+      throws Exception
    {
       insureStarted(serverIndex);
       servers[serverIndex].undeployDestination(isQueue, name);
    }
-
+                                                                                                                
    public static void deployConnectionFactory(String objectName,
                                               String[] jndiBindings,
                                               int prefetchSize,
@@ -631,15 +634,19 @@
 
    private static Server acquireRemote(int initialRetries, int index)
    {
-      String name = "//localhost:" + RMITestServer.RMI_REGISTRY_PORTS[index] + "/" + RMITestServer.RMI_SERVER_NAME;
+      String name =
+         "//localhost:" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
+         RMITestServer.RMI_SERVER_PREFIX + index;
+
       Server s = null;
       int retries = initialRetries;
+
       while(s == null && retries > 0)
       {
          int attempt = initialRetries - retries + 1;
          try
          {
-            log.info("trying to connect to the remote RMI server" +
+            log.info("trying to connect to the remote RMI server " + index + 
                      (attempt == 1 ? "" : ", attempt " + attempt));
             s = (Server)Naming.lookup(name);
             log.info("connected to the remote server");

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -179,7 +179,6 @@
    private Server hsqldbServer;
 
    private boolean transaction;
-   private boolean cluster;
    private boolean database;
    private boolean jca;
    private boolean remotingSocket;
@@ -778,7 +777,7 @@
 
    public boolean isClustered()
    {
-      return cluster;
+      return config.isClustered();
    }
 
    public String toString()
@@ -1305,16 +1304,6 @@
             minus = true;
          }
 
-         if ("all-cluster".equals(tok))
-         {
-            cluster = true;
-            transaction = true;
-            database = true;
-            jca = true;
-            remotingSocket = true;
-            security = true;
-         }
-         else
          if ("all".equals(tok))
          {
             transaction = true;

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -29,6 +29,8 @@
 {
    // Constants -----------------------------------------------------
 
+   public static final boolean DEFAULT_CLUSTERED_MODE = false;
+
    // Static --------------------------------------------------------
 
    public static String getHypersonicDatabase(String connectionURL)
@@ -74,6 +76,7 @@
    private String database;
    private Map dbConfigurations;
    private String serializationType;
+   private Boolean clusteredMode;
 
    // Constructors --------------------------------------------------
 
@@ -140,6 +143,14 @@
       return serializationType;
    }
 
+   /**
+    * @return the clustered mode in which the container should run an individual test.
+    */
+   public boolean isClustered()
+   {
+      return clusteredMode.booleanValue();
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -151,6 +162,7 @@
       Reader reader = new InputStreamReader(is);
       String currentDatabase = null;
       String currentSerializationType = null;
+      boolean currentClusteredMode = DEFAULT_CLUSTERED_MODE;
 
       try
       {
@@ -189,6 +201,10 @@
                {
                   currentSerializationType = XMLUtil.getTextContent(n);
                }
+               else if ("clustered".equals(name))
+               {
+                  currentClusteredMode = Boolean.getBoolean(XMLUtil.getTextContent(n));
+               }
                else
                {
                   throw new Exception("Unexpected child <" + name + "> of node " +
@@ -199,6 +215,7 @@
 
          setCurrentDatabase(currentDatabase);
          setCurrentSerializationType(currentSerializationType);
+         setCurrentClusteredMode(currentClusteredMode);
       }
       finally
       {
@@ -220,8 +237,8 @@
    }
 
    /**
-    * Always the value of "test.serialization" system property takes precedence over the c
-    * onfiguration file value.
+    * Always the value of "test.serialization" system property takes precedence over the
+    * configuration file value.
     */
    private void setCurrentSerializationType(String xmlConfigSerializationType)
    {
@@ -232,6 +249,24 @@
       }
    }
 
+   /**
+    * Always the value of "test.clustered" system property takes precedence over the configuration
+    * file value.
+    */
+   private void setCurrentClusteredMode(boolean xmlClusteredMode) throws Exception
+   {
+      String s = System.getProperty("test.clustered");
+      if (s != null)
+      {
+         clusteredMode = Boolean.valueOf(s);
+      }
+
+      if (clusteredMode == null)
+      {
+         clusteredMode = new Boolean(xmlClusteredMode);
+      }
+   }
+
    private void validate() throws Exception
    {
       // make sure that I have a corresponding "database-configuration"

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -24,6 +24,7 @@
 import java.rmi.registry.LocateRegistry;
 import java.rmi.registry.Registry;
 import java.rmi.server.UnicastRemoteObject;
+import java.rmi.RemoteException;
 import java.util.Set;
 import javax.management.ObjectName;
 import javax.transaction.UserTransaction;
@@ -48,21 +49,21 @@
 {
    private static final long serialVersionUID = -368445344011004778L;
 
+   public static final int DEFAULT_REGISTRY_PORT = 22555;
+   public static final int DEFAULT_SERVER_INDEX = 0;
+   public static final String DEFAULT_SERVER_HOST = "localhost";
+
    private static final Logger log = Logger.getLogger(RMITestServer.class);
 
    protected RemoteTestServer server;
 
    private RMINamingDelegate namingDelegate;
+   private int index;
 
-   //public static final int RMI_REGISTRY_PORT = 25989;
-   
-   //We allow for up to 5 rmi test servers running simultaneously
-   public static final int[] RMI_REGISTRY_PORTS = 
-      new int[] {25989, 25990, 25991, 25992, 25993};
-   
-   public static final String RMI_SERVER_NAME = "messaging-rmi-server";
-   public static final String NAMING_SERVER_NAME = "naming-rmi-server";
 
+   public static final String RMI_SERVER_PREFIX = "messaging_rmi_server_";
+   public static final String NAMING_SERVER_PREFIX = "naming_rmi_server_";
+
    private static Registry registry;
    
    public static void main(String[] args) throws Exception
@@ -70,39 +71,50 @@
       log.debug("initializing RMI runtime");
 
       String host = System.getProperty("test.bind.address");
+
       if (host == null)
       {
-         host = "localhost";
+         host = DEFAULT_SERVER_HOST;
       }
 
-      log.info("bind address: " + host);
-      
-      int index;
-      String registryIndex = System.getProperty("test.registry.index");
-      if (registryIndex == null)
+      int serverIndex = DEFAULT_SERVER_INDEX;
+
+      String s = System.getProperty("test.server.index");
+
+      if (s != null)
       {
-         //Use the 0th port
-         index = 0;
+         serverIndex = Integer.parseInt(s);
       }
-      else
-      {
-         index = Integer.parseInt(registryIndex);         
-      }
-      int port = RMI_REGISTRY_PORTS[index];
 
+      log.info("RMI server " + serverIndex + ", bind address " + host);
+
+      RMITestServer testServer = new RMITestServer(serverIndex);
+      log.debug("RMI server " + serverIndex + " created");
+
       // let RMI know the bind address
       System.setProperty("java.rmi.server.hostname", host);
 
-      registry = LocateRegistry.createRegistry(port);
-      log.debug("registry created at port: " + port);
 
-      RMITestServer testServer = new RMITestServer(index);
-      log.debug("RMI server created");
+      // try to bind first
+      try
+      {
+         registry = LocateRegistry.getRegistry(DEFAULT_REGISTRY_PORT);
+         registry.bind(RMI_SERVER_PREFIX + serverIndex, testServer);
+         registry.bind(NAMING_SERVER_PREFIX + serverIndex, testServer.getNamingDelegate());
 
-      registry.bind(RMI_SERVER_NAME, testServer);
-      registry.bind(NAMING_SERVER_NAME, testServer.getNamingDelegate());
+      }
+      catch(Exception e)
+      {
+         log.info("Failure using an existing registry, trying creating it");
 
-      log.info("RMI server bound");
+         // try to create it
+         registry = LocateRegistry.createRegistry(DEFAULT_REGISTRY_PORT);
+
+         registry.bind(RMI_SERVER_PREFIX + serverIndex, testServer);
+         registry.bind(NAMING_SERVER_PREFIX + serverIndex, testServer.getNamingDelegate());
+      }
+
+      log.info("RMI server " + serverIndex + " bound");
    }
 
    public class VMKiller implements Runnable
@@ -126,8 +138,8 @@
 
    public RMITestServer(int index) throws Exception
    {
+      this.index = index;
       namingDelegate = new RMINamingDelegate();
-
       server = new RemoteTestServer(index);
    }
 
@@ -213,10 +225,10 @@
    {
       server.destroy();
 
-      registry.unbind(RMI_SERVER_NAME);
-      registry.unbind(NAMING_SERVER_NAME);
+      registry.unbind(RMI_SERVER_PREFIX + index);
+      registry.unbind(NAMING_SERVER_PREFIX + index);
       
-      //Now shutdown the process
+      // Now shutdown the process. The registry will be taken out with the last RMI server standing
       
       //TODO - we should shutdown cleanly - let main() exit - not kill the process
       

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -51,20 +51,20 @@
       }
       
       int index;
-      String registryIndex = System.getProperty("test.registry.index");
-      if (registryIndex == null)
+
+      String serverIndex = System.getProperty("test.server.index");
+      if (serverIndex == null)
       {
-         //Use the 0th port
-         index = 0;
+         index = RMITestServer.DEFAULT_SERVER_INDEX;
       }
       else
       {
-         index = Integer.parseInt(registryIndex);         
+         index = Integer.parseInt(serverIndex);
       }
-      int port = RMITestServer.RMI_REGISTRY_PORTS[index];
 
       String name =
-         "//" + host + ":" + port + "/" + RMITestServer.RMI_SERVER_NAME;
+         "//" + host + ":" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
+         RMITestServer.RMI_SERVER_PREFIX + index;
 
       log.info("Stopping " + name);
 
@@ -79,9 +79,12 @@
          return;
       }
 
-      //We should shut down cleanly - not kill the process like we are currently doing
+      // We should shut down cleanly - not kill the process like we are currently doing
       
       server.destroy();
+
+      // The last RMI server will take with it the registry too
+
       log.info("RMI server stopped");
 
    }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -53,7 +53,8 @@
    public RemoteContext(int remoteServerIndex) throws Exception
    {
       String n =
-         "//localhost:" + RMITestServer.RMI_REGISTRY_PORTS[remoteServerIndex] + "/" + RMITestServer.NAMING_SERVER_NAME;
+         "//localhost:" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
+          RMITestServer.NAMING_SERVER_PREFIX + remoteServerIndex;
       
       log.info("Using this url for rmi server lookup " + n);
       

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-07 11:13:12 UTC (rev 1716)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-07 19:15:49 UTC (rev 1717)
@@ -42,9 +42,6 @@
 
    // Static --------------------------------------------------------
 
-   private static RemoteContext[] initialContexts =
-      new RemoteContext[RMITestServer.RMI_REGISTRY_PORTS.length];
-   
    /**
     * @return the JNDI environment to use to get this InitialContextFactory.
     */
@@ -71,29 +68,26 @@
    {
       String s = (String)environment.get(Constants.SERVER_INDEX_PROPERTY_NAME);
       
-      log.info("Created initial context for " + s);
-      
       if (s == null)
       {
          throw new IllegalArgumentException("Initial context environment must contain " +
                                             "entry for " + Constants.SERVER_INDEX_PROPERTY_NAME);
       }
-      
+
+      log.info("Created initial context for " + s);
+
       int remoteServerIndex = Integer.parseInt(s);
-      
-      if (initialContexts[remoteServerIndex] == null)
+
+      try
       {
-         try
-         {
-            initialContexts[remoteServerIndex] = new RemoteContext(remoteServerIndex);
-         }
-         catch(Exception e)
-         {
-            log.error("Cannot get the remote context", e);
-            throw new NamingException("Cannot get the remote context");
-         }
+         return new RemoteContext(remoteServerIndex);
       }
-      return initialContexts[remoteServerIndex];
+      catch(Exception e)
+      {
+         log.error("Cannot get the remote context", e);
+         throw new NamingException("Cannot get the remote context");
+      }
+
    }
 
    // Package protected ---------------------------------------------



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 14:26:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 14:26:39 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58907 - branches
Message-ID: <E1GsOtD-0007Sx-6I@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 14:26:38 -0500 (Thu, 07 Dec 2006)
New Revision: 58907

Added:
   branches/JBoss_4_0_5_GA_JBAS_3657/
Log:
patch of WebSphereMQ integration

Copied: branches/JBoss_4_0_5_GA_JBAS_3657 (from rev 58906, tags/JBoss_4_0_5_GA)



From brian.stansberry at jboss.com  Thu Dec  7 15:01:19 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 15:01:19 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GsPQl-000834-5j@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 15:01:19

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  Remove javadoc link to internal field
  
  Revision  Changes    Path
  1.289     +4 -3      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.288
  retrieving revision 1.289
  diff -u -b -r1.288 -r1.289
  --- TreeCache.java	29 Nov 2006 22:10:23 -0000	1.288
  +++ TreeCache.java	7 Dec 2006 20:01:19 -0000	1.289
  @@ -94,7 +94,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.288 2006/11/29 22:10:23 genman Exp $
  + * @version $Id: TreeCache.java,v 1.289 2006/12/07 20:01:19 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -3717,8 +3717,9 @@
       * Whenever nodes are created, and the global transaction is not null, the created
       * nodes have to be added to the transaction's {@link TransactionEntry}
       * field.<br>
  -    * When a lock is acquired on a node, a reference to the lock has to be added to the list
  -    * of locked nodes in the {@link TransactionEntry#locks} field.
  +    * When a lock is acquired on a node, a reference to the lock has to be 
  +    * {@link TransactionEntry#addLock(IdentityLock) added to the list of locked nodes} 
  +    * in the {@link TransactionEntry}.
       * <p>This operation will also apply different locking to the tree nodes, depending on
       * <tt>operation_type</tt>. If it is <tt>read</tt> type, all nodes will be acquired with
       * read lock. Otherwise, the operation is <tt>write</tt> type, all parent nodes will be acquired
  
  
  


From brian.stansberry at jboss.com  Thu Dec  7 15:03:23 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 15:03:23 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GsPSl-0008Gf-SL@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 15:03:23

  Modified:    src/org/jboss/cache  TransactionEntry.java
  Log:
  Make internal fields private
  
  Revision  Changes    Path
  1.15      +8 -8      JBossCache/src/org/jboss/cache/TransactionEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionEntry.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- TransactionEntry.java	21 Nov 2006 08:57:01 -0000	1.14
  +++ TransactionEntry.java	7 Dec 2006 20:03:23 -0000	1.15
  @@ -32,7 +32,7 @@
    * </ul>
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.14 $
  + * @version $Revision: 1.15 $
    */
   public class TransactionEntry {
   
  @@ -41,14 +41,14 @@
      /**
       * Local transaction
       */
  -   protected Transaction ltx=null;
  -   protected Option option;
  +   private Transaction ltx=null;
  +   private Option option;
   
      /**
       * List<MethodCall> of modifications ({@link MethodCall}). They will be replicated on TX commit
       */
  -   protected List<MethodCall> modification_list=new LinkedList<MethodCall>();
  -   protected List<MethodCall> cl_mod_list = new LinkedList<MethodCall>();
  +   private List<MethodCall> modification_list=new LinkedList<MethodCall>();
  +   private List<MethodCall> cl_mod_list = new LinkedList<MethodCall>();
   
      /**
       * List<MethodCall>. List of compensating {@link org.jboss.cache.marshall.MethodCall} objects
  @@ -56,18 +56,18 @@
       * we have a corresponding entry in this list. A rollback will simply iterate over this list in
       * reverse to undo the modifications. Note that these undo-ops will never be replicated.
       */
  -   protected List undo_list=new LinkedList();
  +   private List undo_list=new LinkedList();
   
      /**
       * List<IdentityLock> of locks acquired by the transaction ({@link IdentityLock})
       */
  -   protected List locks = new LinkedList();
  +   private List locks = new LinkedList();
   
      /**
       * A list of dummy uninitialised nodes created by the cache loader interceptor to load data for a
       * given node in this tx.
       */
  -   protected List dummyNodesCreatedByCacheLoader;
  +   private List dummyNodesCreatedByCacheLoader;
   
      /**
       * Constructs a new TransactionEntry.
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 15:31:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 15:31:52 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1718 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms:
	client/delegate server/connectionfactory
Message-ID: <E1GsPuK-0000Hu-Io@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-07 15:31:50 -0500 (Thu, 07 Dec 2006)
New Revision: 1718

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
Log:
Fixing connection factories

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-07 19:15:49 UTC (rev 1717)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-07 20:31:50 UTC (rev 1718)
@@ -60,11 +60,26 @@
    // Constructors --------------------------------------------------
 
    public ClusteredClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
-                                                   Version serverVersion, boolean clientPing)
+                                                   Version serverVersion, boolean clientPing,
+                                                   ClientConnectionFactoryDelegate[] delegates,
+                                                   int[] failoverIndexes)
    {
       super(objectID, serverId, serverLocatorURI, serverVersion, clientPing);
+      this.delegates = delegates;
+      this.failoverIndexes = failoverIndexes;
    }
 
+   // Some of the properties of ClientConnectionFactoryDelegate are not exposed..
+   // I didn't want to expose then while I needed another delegate's properties to perform a copy.
+   // So, I created this Constructor so I could have access into protected members inside an extension class
+   public ClusteredClientConnectionFactoryDelegate(ClientConnectionFactoryDelegate mainDelegate,
+                                                   ClientConnectionFactoryDelegate[] delegates,
+                                                   int[] failoverIndexes)
+   {
+      this(mainDelegate.getID(), mainDelegate.serverId, mainDelegate.serverLocatorURI,
+         mainDelegate.serverVersion, mainDelegate.clientPing, delegates, failoverIndexes);
+   }
+
    // DelegateSupport overrides -------------------------------------
 
    public void init()
@@ -92,13 +107,6 @@
    // Public --------------------------------------------------------
 
 
-   public void setFailoverDelegates(ClientConnectionFactoryDelegate[] delegates,
-                                    int[] failoverIndexes)
-   {
-      this.delegates = delegates;
-      this.failoverIndexes = failoverIndexes;
-   }
-
    // Only be used in testing
    public ClientConnectionFactoryDelegate[] getDelegates()
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-07 19:15:49 UTC (rev 1717)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-07 20:31:50 UTC (rev 1718)
@@ -118,10 +118,19 @@
       endpoints.put(uniqueName, endpoint);   
       
       ClientConnectionFactoryDelegate delegate = null;
-      
+
       if (clustered)
       {
          setupReplicator();
+      }
+      else
+      {
+         log.info("ConnectionFactoryJNDIMapper is non clustered");
+      }
+      
+      /* if (clustered)
+      {
+         setupReplicator();
          
          if (replicator != null)
          {                                             
@@ -136,14 +145,19 @@
          //Local
          delegate = new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
                                         locatorURI, version, clientPing);
-      }
+      } */
 
+      delegate = new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
+                                     locatorURI, version, clientPing);
+
+
+      //delegate = new ClusteredClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(), locatorURI, version, clientPing);
+
+
       log.trace("Adding delegates factory " + uniqueName + " pointing to " + delegate);
       delegates.put(uniqueName, delegate);
 
-      //Now bind it in JNDI
-      rebindConnectionFactory(initialContext, jndiBindings, delegate);
-      
+
       // We are clustered, we need to propagate the local delegate across the cluster.
 
       // ... and then update it (and the clustered delegate on every node, while we're at it) by
@@ -152,7 +166,16 @@
       // will rebind updated ConnectionFactories in JNDI.
       // This will update the local node too
 
-      replicator.put(CF_PREFIX + uniqueName, delegate);
+      log.info("CF_PREFIX=" + CF_PREFIX + " uniqueName=" + uniqueName + " delegate = " + delegate + " replicator = " + replicator);
+      if (replicator != null)
+      {
+         replicator.put(CF_PREFIX + uniqueName, delegate);
+      }
+      else
+      {
+         //Now bind it in JNDI
+         rebindConnectionFactory(initialContext, jndiBindings, delegate);
+      }
 
       //Registering with the dispatcher should always be the last thing otherwise a client could use
       //a partially initialised object
@@ -263,22 +286,19 @@
          {
             String uniqueName = sKey.substring(CF_PREFIX.length());
             
-            ClusteredClientConnectionFactoryDelegate clusteredDelegate =
-               (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
-            
-            if (clusteredDelegate == null)
+            if (log.isTraceEnabled())
             {
-               log.info("Delegates list: delegates.length=" + delegates.size());
+               log.trace("Delegates list: delegates.length=" + delegates.size());
                for (Iterator iterDelegates = delegates.entrySet().iterator(); iterDelegates.hasNext();)
                {
                   Map.Entry entry = (Map.Entry)iterDelegates.next();
-                  log.info("key=" + entry.getKey() + ", value=" + entry.getValue());
+                  log.trace("key=" + entry.getKey() + ", value=" + entry.getValue());
                }
                throw new IllegalStateException("Cannot find connection delegate for " +
                                                uniqueName + " to update");
             }
             
-            setFailoverDelegates(clusteredDelegate, updatedReplicantMap);
+            ClusteredClientConnectionFactoryDelegate clusteredDelegate = createClusteredDelegate(updatedReplicantMap);
             
             // Now rebind ...
             
@@ -323,16 +343,22 @@
    /**
     * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
     */
-   private void  setFailoverDelegates(ClusteredClientConnectionFactoryDelegate clusteredDelegate,
-                                     Map localDelegates)
+   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates)
    {
+
+
       //TODO: make it trace after the code is stable
       log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
+
+
       int s = localDelegates.size();
 
       int[] nodesIDs = new int[s];
       int[] failoverNodeIDs = new int[s];
       ClientConnectionFactoryDelegate[] delegates = new ClientConnectionFactoryDelegate[s];
+      // Ths created ClusteredClientFactoryDelegate will copy the properties from this delegate which is
+      // the delegate on this current serverPeer
+      ClientConnectionFactoryDelegate mainDelegate = null;
 
       int idx = 0;
 
@@ -349,8 +375,25 @@
          failoverNodeIDs[idx] = failoverNodeID;
          delegates[idx] = (ClientConnectionFactoryDelegate)entry.getValue();
 
+         if (delegates[idx].getServerId() == this.serverPeer.getServerPeerID())
+         {
+
+            // sanity check
+            if (mainDelegate != null)
+            {
+               throw new IllegalStateException("There are two server with serverID, verify your clustering configuration");
+            }
+            mainDelegate = delegates[idx];
+         }
+
          idx++;
       }
+      // sanity check
+      if (mainDelegate == null)
+      {
+         throw new IllegalStateException("Couldn't find a delegate for this serverID=" + this.serverPeer.getServerPeerID());
+      }
+
       
       // Generate the failover indexes. This could probably be optimised if need be.
       
@@ -377,8 +420,11 @@
          
          failoverIndexes[i] = failoverIndex;
       }
-      
-      clusteredDelegate.setFailoverDelegates(delegates, failoverIndexes);
+
+      ClusteredClientConnectionFactoryDelegate clusteredDelegate =
+         new ClusteredClientConnectionFactoryDelegate(mainDelegate,delegates,failoverIndexes);
+
+      return clusteredDelegate;
    }
 
    private void rebindConnectionFactory(Context ic,



From ron_sigal at yahoo.com  Thu Dec  7 15:44:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 07 Dec 2006 15:44:09 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1GsQ6D-0000SI-ID@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/07 15:44:09

  Modified:    src/main/org/jboss/remoting  Client.java
  Log:
  JBREM-647:  Initialize configuration to empty HashMap.
  
  Revision  Changes    Path
  1.60      +4 -3      JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.59
  retrieving revision 1.60
  diff -u -b -r1.59 -r1.60
  --- Client.java	7 Dec 2006 02:58:42 -0000	1.59
  +++ Client.java	7 Dec 2006 20:44:09 -0000	1.60
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.59 $
  + * @version $Revision: 1.60 $
    */
   public class Client implements Externalizable
   {
  @@ -161,7 +161,7 @@
      private InvokerLocator locator;
   
      private ConnectionValidator connectionValidator = null;
  -   private Map configuration = null;
  +   private Map configuration = new HashMap();
   
      private boolean enableLease = false;
      private long leasePeriod = -1;
  @@ -260,6 +260,7 @@
         this.classloader = cl;
         this.locator = locator;
         this.subsystem = subsystem == null ? null : subsystem.toUpperCase();
  +      if (configuration != null)
         this.configuration = configuration;
         this.sessionId = new GUID().toString();
      }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 15:44:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 15:44:56 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1719 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory
Message-ID: <E1GsQ6y-0000ST-Cg@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-07 15:44:55 -0500 (Thu, 07 Dec 2006)
New Revision: 1719

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
Log:
Fixing connection factories

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-07 20:31:50 UTC (rev 1718)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-07 20:44:55 UTC (rev 1719)
@@ -286,18 +286,6 @@
          {
             String uniqueName = sKey.substring(CF_PREFIX.length());
             
-            if (log.isTraceEnabled())
-            {
-               log.trace("Delegates list: delegates.length=" + delegates.size());
-               for (Iterator iterDelegates = delegates.entrySet().iterator(); iterDelegates.hasNext();)
-               {
-                  Map.Entry entry = (Map.Entry)iterDelegates.next();
-                  log.trace("key=" + entry.getKey() + ", value=" + entry.getValue());
-               }
-               throw new IllegalStateException("Cannot find connection delegate for " +
-                                               uniqueName + " to update");
-            }
-            
             ClusteredClientConnectionFactoryDelegate clusteredDelegate = createClusteredDelegate(updatedReplicantMap);
             
             // Now rebind ...



From ron_sigal at yahoo.com  Thu Dec  7 15:45:39 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 07 Dec 2006 15:45:39 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1GsQ7f-0000Ui-Jv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/07 15:45:39

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x Client.java
  Log:
  JBREM-647:  Initialize configuration to empty HashMap.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.53.2.8  +4 -3      JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.53.2.7
  retrieving revision 1.53.2.8
  diff -u -b -r1.53.2.7 -r1.53.2.8
  --- Client.java	7 Dec 2006 03:20:52 -0000	1.53.2.7
  +++ Client.java	7 Dec 2006 20:45:39 -0000	1.53.2.8
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.53.2.7 $
  + * @version $Revision: 1.53.2.8 $
    */
   public class Client implements Externalizable
   {
  @@ -161,7 +161,7 @@
      private InvokerLocator locator;
   
      private ConnectionValidator connectionValidator = null;
  -   private Map configuration = null;
  +   private Map configuration = new HashMap();
   
      private boolean enableLease = false;
      private long leasePeriod = -1;
  @@ -260,6 +260,7 @@
         this.classloader = cl;
         this.locator = locator;
         this.subsystem = subsystem == null ? null : subsystem.toUpperCase();
  +      if (configuration != null)
         this.configuration = configuration;
         this.sessionId = new GUID().toString();
      }
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:04:40 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:04:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish  ...
Message-ID: <E1GsQQ4-0000yb-9x@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:04:40

  Modified:    examples/glassfish  build.xml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.4       +5 -3      jboss-seam/examples/glassfish/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/build.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- build.xml	1 Dec 2006 20:40:52 -0000	1.3
  +++ build.xml	7 Dec 2006 21:04:40 -0000	1.4
  @@ -72,14 +72,14 @@
           <include name="navigation.xml" />
           <include name="components.xml" />
         </webinf>
  +      <lib dir="${lib}">
  +        <include name="jsf-facelets.jar" />
  +      </lib>
         <lib dir="${seamlib}">
           <include name="jboss-seam-ui.jar" />
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  @@ -94,6 +94,8 @@
         appxml="${resources}/META-INF/application.xml">
         
         <fileset dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
           <include name="thirdparty-all.jar" />
           <include name="commons-digester-*.jar" />
           <include name="commons-beanutils-*.jar" />
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:04:40 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:04:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/lib    ...
Message-ID: <E1GsQQ4-0000yf-EQ@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:04:40

  Removed:     examples/glassfish/lib    el-api.jar el-ri.jar
                        jsf-facelets.jar
  Log:
  move libs and use s:selectDate


From michael.yuan at jboss.com  Thu Dec  7 16:04:40 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:04:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/resources/META-INF  ...
Message-ID: <E1GsQQ4-0000ym-Ij@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:04:40

  Modified:    examples/glassfish/resources/META-INF  application.xml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.3       +7 -1      jboss-seam/examples/glassfish/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/resources/META-INF/application.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- application.xml	3 Dec 2006 04:41:34 -0000	1.2
  +++ application.xml	7 Dec 2006 21:04:40 -0000	1.3
  @@ -18,5 +18,11 @@
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +	<module>
  +	    <java>el-api.jar</java>
  +	</module>
  +	<module>
  +	    <java>el-ri.jar</java>
  +	</module>
   	
   </application>
  \ No newline at end of file
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:04:40 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:04:40 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/view  ...
Message-ID: <E1GsQQ4-0000yt-MS@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:04:40

  Modified:    examples/glassfish/view  book.xhtml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.2       +192 -189  jboss-seam/examples/glassfish/view/book.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: book.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/view/book.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- book.xhtml	29 Nov 2006 09:30:42 -0000	1.1
  +++ book.xhtml	7 Dec 2006 21:04:40 -0000	1.2
  @@ -9,7 +9,6 @@
   
   <!-- content -->
   <ui:define name="content">
  -<script language="JavaScript" src="js/datePicker.js"/>
   <div class="section">
   	<h1>Book Hotel</h1>
   </div>
  @@ -51,7 +50,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkinDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkinDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkinDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkinDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  @@ -66,7 +67,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkoutDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkoutDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkoutDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkoutDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:35:17 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:35:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa  ...
Message-ID: <E1GsQth-0001T2-Rs@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:35:17

  Modified:    examples/jpa  build.xml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.8       +14 -14    jboss-seam/examples/jpa/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/build.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- build.xml	1 Dec 2006 23:56:16 -0000	1.7
  +++ build.xml	7 Dec 2006 21:35:17 -0000	1.8
  @@ -83,9 +83,6 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
           <!-- do not need the following for 4.0.4 and 4.0.5 
  @@ -95,13 +92,16 @@
         <lib dir="${hibernatelib}">
           <include name="*.jar" />
         </lib>
  -      <!-- do not need the following jars for 4.0.4 and 4.0.5
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
  +        <!-- do not need the following jars for 4.0.4 and 4.0.5
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
           <include name="commons*.jar" />
  -      </lib>
         -->
  +      </lib>
         <lib dir="${build.jars}">
           <include name="${projname}.jar" />
         </lib>
  @@ -142,9 +142,6 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  @@ -152,6 +149,9 @@
           <include name="*.jar" />
         </lib>
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
           <include name="thirdparty-all.jar" />
  @@ -203,9 +203,6 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  @@ -215,6 +212,9 @@
         </lib>
         -->
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
           <include name="thirdparty-all.jar" />
  @@ -266,13 +266,13 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
           <include name="thirdparty-all.jar" />
           <include name="commons*.jar" />
         </lib>
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:35:18 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:35:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/lib     ...
Message-ID: <E1GsQti-0001T6-1Q@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:35:18

  Removed:     examples/jpa/lib     el-api.jar el-ri.jar jsf-facelets.jar
                        note.txt
  Log:
  move libs and use s:selectDate


From michael.yuan at jboss.com  Thu Dec  7 16:35:18 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:35:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/view  ...
Message-ID: <E1GsQti-0001TD-64@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:35:18

  Modified:    examples/jpa/view  book.xhtml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.6       +192 -184  jboss-seam/examples/jpa/view/book.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: book.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/view/book.xhtml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- book.xhtml	20 Nov 2006 19:45:50 -0000	1.5
  +++ book.xhtml	7 Dec 2006 21:35:18 -0000	1.6
  @@ -9,7 +9,6 @@
   
   <!-- content -->
   <ui:define name="content">
  -<script language="JavaScript" src="js/datePicker.js"/>
   <div class="section">
   	<h1>Book Hotel</h1>
   </div>
  @@ -51,7 +50,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkinDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkinDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkinDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkinDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  @@ -66,7 +67,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkoutDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkoutDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkoutDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkoutDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  @@ -183,6 +186,11 @@
      tabs. But you can even switch between multiple tasks inside a single browser tab!
      The "Workspaces" section showcases this advanced feature.
   </p>
  +<p>
  +   <a href="#" onclick="window.open('exp/workspaceExp.html','exp','width=752,height=500,scrollbars=yes');">
  +      How does the workspace list work?
  +   </a>
  +</p>
   
   </ui:define>
   
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:35:18 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:35:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/view/js  ...
Message-ID: <E1GsQti-0001TH-9L@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:35:18

  Removed:     examples/jpa/view/js  datePicker.js
  Log:
  move libs and use s:selectDate


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 16:38:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 16:38:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r58908 - branches/JBoss_4_0_3_SP1_CP/build
Message-ID: <E1GsQwq-0001W2-9y@committer01.frg.pub.inap.atl.jboss.com>

Author: vivekl at redhat.com
Date: 2006-12-07 16:38:31 -0500 (Thu, 07 Dec 2006)
New Revision: 58908

Modified:
   branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml
Log:
ASPATCH-113: org.jboss.test.web.test.JSFIntegrationUnitTestCase fails
Reverting to tomcat 5.5.9jboss.



Modified: branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml	2006-12-07 19:26:38 UTC (rev 58907)
+++ branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml	2006-12-07 21:38:31 UTC (rev 58908)
@@ -155,7 +155,7 @@
        <componentref name="apache-slide"
          version="1.0.16" />
        <componentref name="apache-tomcat"
-         version="5.5.9.patch01" />
+         version="5.5.9jboss" />
 
        <componentref name="apache-wss4j"
          version="cvs-7-19" />



From ron_sigal at yahoo.com  Thu Dec  7 16:43:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 07 Dec 2006 16:43:30 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/marshal/http ...
Message-ID: <E1GsR1e-0001c8-KJ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/07 16:43:30

  Modified:    src/main/org/jboss/remoting/marshal/http 
                        HTTPUnMarshaller.java
  Log:
  JBREM-635:  (1) Test for EOFException in read(). (2) No longer throws exception from isBinaryData().
  
  Revision  Changes    Path
  1.12      +11 -5     JBossRemoting/src/main/org/jboss/remoting/marshal/http/HTTPUnMarshaller.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPUnMarshaller.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/marshal/http/HTTPUnMarshaller.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- HTTPUnMarshaller.java	21 Nov 2006 05:49:49 -0000	1.11
  +++ HTTPUnMarshaller.java	7 Dec 2006 21:43:30 -0000	1.12
  @@ -31,6 +31,7 @@
   import java.io.BufferedReader;
   import java.io.ByteArrayInputStream;
   import java.io.ByteArrayOutputStream;
  +import java.io.EOFException;
   import java.io.IOException;
   import java.io.InputStream;
   import java.io.InputStreamReader;
  @@ -60,7 +61,16 @@
      public Object read(InputStream inputStream, Map metadata) throws IOException, ClassNotFoundException
      {
         if (isBinaryData(metadata))
  +      {
  +         try
  +         {
            return super.read(inputStream, metadata);
  +         }
  +         catch (EOFException e)
  +         {
  +            return null;
  +         }
  +      }
         
         int contentLength = -1;
         Object ret = null;
  @@ -205,10 +215,6 @@
               }
               isBinary = WebUtil.isBinary((String) value);
            }
  -         else
  -         {
  -            throw new IOException("Can not not determine data type because content-type not specified.");
  -         }
         }
         return isBinary;
      }
  
  
  


From ron_sigal at yahoo.com  Thu Dec  7 16:44:43 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 07 Dec 2006 16:44:43 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/marshal/http ...
Message-ID: <E1GsR2p-0001cb-Tj@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/07 16:44:43

  Modified:    src/main/org/jboss/remoting/marshal/http  Tag: remoting_2_x
                        HTTPUnMarshaller.java
  Log:
  JBREM-635:  (1) Test for EOFException in read(). (2) No longer throws exception from isBinaryData()
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.10.2.1  +9 -10     JBossRemoting/src/main/org/jboss/remoting/marshal/http/HTTPUnMarshaller.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HTTPUnMarshaller.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/marshal/http/HTTPUnMarshaller.java,v
  retrieving revision 1.10
  retrieving revision 1.10.2.1
  diff -u -b -r1.10 -r1.10.2.1
  --- HTTPUnMarshaller.java	21 Sep 2006 07:37:03 -0000	1.10
  +++ HTTPUnMarshaller.java	7 Dec 2006 21:44:43 -0000	1.10.2.1
  @@ -31,6 +31,7 @@
   import java.io.BufferedReader;
   import java.io.ByteArrayInputStream;
   import java.io.ByteArrayOutputStream;
  +import java.io.EOFException;
   import java.io.IOException;
   import java.io.InputStream;
   import java.io.InputStreamReader;
  @@ -59,14 +60,16 @@
       */
      public Object read(InputStream inputStream, Map metadata) throws IOException, ClassNotFoundException
      {
  +      if (isBinaryData(metadata))
  +      {
         try
         {
  -         if (isBinaryData(metadata))
               return super.read(inputStream, metadata);
         }
  -      catch (Exception e)
  +         catch (EOFException e)
         {
  -         log.warn("Can not get Content-Type from header for http unmarshalling.");
  +            return null;
  +         }
         }
         
         int contentLength = -1;
  @@ -212,10 +215,6 @@
               }
               isBinary = WebUtil.isBinary((String) value);
            }
  -         else
  -         {
  -            throw new IOException("Can not not determine data type because content-type not specified.");
  -         }
         }
         return isBinary;
      }
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:44:57 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:44:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2  ...
Message-ID: <E1GsR33-0001cn-65@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:44:57

  Modified:    examples/hibernate2  build.xml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.7       +14 -14    jboss-seam/examples/hibernate2/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/build.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- build.xml	1 Dec 2006 23:57:22 -0000	1.6
  +++ build.xml	7 Dec 2006 21:44:57 -0000	1.7
  @@ -81,9 +81,6 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
           <!-- do not need the following for 4.0.4 and 4.0.5
  @@ -93,13 +90,16 @@
         <lib dir="${hibernatelib}">
           <include name="*.jar" />
         </lib>
  -      <!-- do not need the following jars for 4.0.4 and 4.0.5
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
  +        <!-- do not need the following jars for 4.0.4 and 4.0.5
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
           <include name="commons*.jar" />
  -      </lib>
         -->
  +      </lib>
         <lib dir="${build.jars}">
           <include name="${projname}.jar" />
         </lib>
  @@ -138,9 +138,6 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  @@ -148,6 +145,9 @@
           <include name="*.jar" />
         </lib>
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
           <include name="thirdparty-all.jar" />
  @@ -201,9 +201,6 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
  @@ -213,6 +210,9 @@
         </lib>
         -->
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
           <include name="myfaces-api-1.1.4.jar" />
           <include name="myfaces-impl-1.1.4.jar" />
           <include name="thirdparty-all.jar" />
  @@ -264,13 +264,13 @@
           <include name="jboss-seam-debug.jar" />
         </lib>
         <lib dir="${applib}">
  -        <include name="el-api.jar" />
  -        <include name="el-ri.jar" />
  -        <include name="jsf-facelets.jar" />
           <include name="ajax4jsf.jar" />
           <include name="oscache-2.3.2.jar" />
         </lib>
         <lib dir="${lib}">
  +        <include name="el-api.jar" />
  +        <include name="el-ri.jar" />
  +        <include name="jsf-facelets.jar" />
           <include name="thirdparty-all.jar" />
           <include name="commons*.jar" />
         </lib>
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:44:57 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:44:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/lib     ...
Message-ID: <E1GsR33-0001cr-Ab@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:44:57

  Removed:     examples/hibernate2/lib     el-api.jar el-ri.jar
                        jsf-facelets.jar note.txt
  Log:
  move libs and use s:selectDate


From michael.yuan at jboss.com  Thu Dec  7 16:44:57 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:44:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/view  ...
Message-ID: <E1GsR33-0001cy-Ee@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:44:57

  Modified:    examples/hibernate2/view  book.xhtml
  Log:
  move libs and use s:selectDate
  
  Revision  Changes    Path
  1.6       +192 -184  jboss-seam/examples/hibernate2/view/book.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: book.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/view/book.xhtml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- book.xhtml	20 Nov 2006 19:45:40 -0000	1.5
  +++ book.xhtml	7 Dec 2006 21:44:57 -0000	1.6
  @@ -9,7 +9,6 @@
   
   <!-- content -->
   <ui:define name="content">
  -<script language="JavaScript" src="js/datePicker.js"/>
   <div class="section">
   	<h1>Book Hotel</h1>
   </div>
  @@ -51,7 +50,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkinDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkinDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkinDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkinDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  @@ -66,7 +67,9 @@
                               <s:convertDateTime pattern="MM/dd/yyyy"/>
                               <a:support event="onblur" reRender="checkoutDateErrors"/>
                           </h:inputText>
  -                        <h:graphicImage url="img/dtpick.gif" onclick="displayDatePicker('booking:checkoutDate');" style="margin-left:5px"/>
  +                                    <s:selectDate for="checkoutDate">
  +                                        <h:graphicImage url="img/dtpick.gif" style="margin-left:5px"/>
  +                                    </s:selectDate>
   						<br/>
                           <a:outputPanel id="checkoutDateErrors"><s:message/></a:outputPanel>
   					</s:decorate>
  @@ -183,6 +186,11 @@
      tabs. But you can even switch between multiple tasks inside a single browser tab!
      The "Workspaces" section showcases this advanced feature.
   </p>
  +<p>
  +   <a href="#" onclick="window.open('exp/workspaceExp.html','exp','width=752,height=500,scrollbars=yes');">
  +      How does the workspace list work?
  +   </a>
  +</p>
   
   </ui:define>
   
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 16:44:57 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 16:44:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/view/js  ...
Message-ID: <E1GsR33-0001d2-Hy@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 16:44:57

  Removed:     examples/hibernate2/view/js  datePicker.js
  Log:
  move libs and use s:selectDate


From bill at jboss.com  Thu Dec  7 16:48:47 2006
From: bill at jboss.com (Bill Burke)
Date: Thu, 07 Dec 2006 16:48:47 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/common-core/2.0.3.GA - New
	directory ...
Message-ID: <E1GsR6l-0001it-SG@committer01.frg.pub.inap.atl.jboss.com>

  User: bill    
  Date: 06/12/07 16:48:47

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/common-core/2.0.3.GA added to the repository


From bill at jboss.com  Thu Dec  7 16:48:55 2006
From: bill at jboss.com (Bill Burke)
Date: Thu, 07 Dec 2006 16:48:55 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/common-core/2.0.3.GA/lib - New
	directory ...
Message-ID: <E1GsR6t-0001j2-GL@committer01.frg.pub.inap.atl.jboss.com>

  User: bill    
  Date: 06/12/07 16:48:55

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/common-core/2.0.3.GA/lib added to the repository


From bill at jboss.com  Thu Dec  7 16:49:36 2006
From: bill at jboss.com (Bill Burke)
Date: Thu, 07 Dec 2006 16:49:36 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/common-core/2.0.3.GA  ...
Message-ID: <E1GsR7Y-0001jL-Fk@committer01.frg.pub.inap.atl.jboss.com>

  User: bill    
  Date: 06/12/07 16:49:36

  Added:       jboss/common-core/2.0.3.GA  component-info.xml
  Log:
  refactor ArchiveBrowser so we can plug in vfs urls separately
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 21:49:36;  author: bill;  state: Exp;repository.jboss.com/jboss/common-core/2.0.3.GA/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/common-core-component-info">
  
     <component id="jboss/common-core"
                licenseType="lgpl"
                version="2.0.3.GA"
                description="JBoss Common Core Utility classes"
                scm="svn:https://svn.jboss.org/repos/common/common-core/tags/2.0.3.GA/"
                >
  
        <artifact id="jboss-common-core.jar"/>
        <artifact id="jboss-common-core-sources.jar"/>
  
        <export>
           <include input="jboss-common-core.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  
  


From bill at jboss.com  Thu Dec  7 16:49:36 2006
From: bill at jboss.com (Bill Burke)
Date: Thu, 07 Dec 2006 16:49:36 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/common-core/2.0.3.GA/lib ...
Message-ID: <E1GsR7Y-0001jT-Ja@committer01.frg.pub.inap.atl.jboss.com>

  User: bill    
  Date: 06/12/07 16:49:36

  Added:       jboss/common-core/2.0.3.GA/lib  
                        jboss-common-core-sources.jar jboss-common-core.jar
  Log:
  refactor ArchiveBrowser so we can plug in vfs urls separately
  
  Revision  Changes    Path
  1.1      date: 2006/12/07 21:49:36;  author: bill;  state: Exp;repository.jboss.com/jboss/common-core/2.0.3.GA/lib/jboss-common-core-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/07 21:49:36;  author: bill;  state: Exp;repository.jboss.com/jboss/common-core/2.0.3.GA/lib/jboss-common-core.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 16:58:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 16:58:05 -0500
Subject: [jboss-cvs] JBossAS SVN: r58909 - in
	trunk/ejb3/src/main/org/jboss/ejb3: . deployers
Message-ID: <E1GsRFl-0001vN-5s@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-07 16:58:03 -0500 (Thu, 07 Dec 2006)
New Revision: 58909

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/MCDependencyPolicy.java
   trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBoss5DependencyPolicy.java
Log:
create a real DataSource dependency

Modified: trunk/ejb3/src/main/org/jboss/ejb3/MCDependencyPolicy.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/MCDependencyPolicy.java	2006-12-07 21:38:31 UTC (rev 58908)
+++ trunk/ejb3/src/main/org/jboss/ejb3/MCDependencyPolicy.java	2006-12-07 21:58:03 UTC (rev 58909)
@@ -34,7 +34,7 @@
  */
 public class MCDependencyPolicy implements DependencyPolicy
 {
-   protected HashSet<String> dependencies = new HashSet<String>();
+   protected HashSet dependencies = new HashSet();
 
    public void addDependency(String dependency)
    {
@@ -59,7 +59,7 @@
    public HashSet<DemandMetaData> getDependencies()
    {
       HashSet<DemandMetaData> set = new HashSet<DemandMetaData>();
-      for (String depends : dependencies)
+      for (Object depends : dependencies)
       {
          set.add(new AbstractDemandMetaData(depends));
       }

Modified: trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBoss5DependencyPolicy.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBoss5DependencyPolicy.java	2006-12-07 21:38:31 UTC (rev 58908)
+++ trunk/ejb3/src/main/org/jboss/ejb3/deployers/JBoss5DependencyPolicy.java	2006-12-07 21:58:03 UTC (rev 58909)
@@ -23,6 +23,9 @@
 
 import org.jboss.ejb3.MCDependencyPolicy;
 
+import javax.management.ObjectName;
+import javax.management.MalformedObjectNameException;
+
 /**
  * Comment
  *
@@ -33,6 +36,18 @@
 {
    public void addDatasource(String jndiName)
    {
-      // todo can't implement this until I know how to create the dependency
+      String ds = jndiName;
+      if (ds.startsWith("java:/"))
+      {
+         ds = ds.substring(6);
+
+      }
+      else if (ds.startsWith("java:"))
+      {
+         ds = ds.substring(5);
+      }
+      //tring onStr = "jboss.jca:name=" + ds + ",service=ManagedConnectionFactory";
+      String onStr = "jboss.jca:name=" + ds + ",service=DataSourceBinding";
+      dependencies.add(onStr);
    }
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 16:59:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 16:59:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r58910 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms
Message-ID: <E1GsRH7-0001w3-0Y@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 16:59:27 -0500 (Thu, 07 Dec 2006)
New Revision: 58910

Modified:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java	2006-12-07 21:58:03 UTC (rev 58909)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java	2006-12-07 21:59:27 UTC (rev 58910)
@@ -1,24 +1,12 @@
-/*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
- */
+/***************************************
+ *                                     *
+ *  JBoss: The OpenSource J2EE WebOS   *
+ *                                     *
+ *  Distributable under LGPL license.  *
+ *  See terms of license at gnu.org.   *
+ *                                     *
+ ***************************************/
+
 package org.jboss.ejb.plugins.jms;
 
 import java.lang.reflect.Method;
@@ -26,8 +14,6 @@
 import java.security.Principal;
 import java.security.PrivilegedAction;
 import java.util.Collection;
-
-import javax.ejb.EJBMetaData;
 import javax.jms.Connection;
 import javax.jms.ConnectionConsumer;
 import javax.jms.Destination;
@@ -69,21 +55,31 @@
 
 /**
  * EJBProxyFactory for JMS MessageDrivenBeans
- * 
  * @author <a href="mailto:peter.antman at tim.se">Peter Antman</a> .
- * @author <a href="mailto:rickard.oberg at telkel.com">Rickard Oberg</a>
+ * @author <a href="mailto:rickard.oberg at telkel.com">Rickard ?berg</a>
  * @author <a href="mailto:sebastien.alborini at m4x.org">Sebastien Alborini</a>
  * @author <a href="mailto:marc.fleury at telkel.com">Marc Fleury</a>
  * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
+ * @author <a href="mailto:weston.price at jboss.com>Weston Price</a>
+ * 
  * @version <tt>$Revision$</tt>
+ * @jmx:mbean extends="org.jboss.system.ServiceMBean"
  */
-public class JMSContainerInvoker extends ServiceMBeanSupport
+/**
+ * A JMSContainerInvoker.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision$
+ */
+public class JMSContainerInvoker
+   extends ServiceMBeanSupport
    implements EJBProxyFactory, JMSContainerInvokerMBean
 {
+   // Constants -----------------------------------------------------
+   
    /** The logger */
    private static final Logger log = Logger.getLogger(JMSContainerInvoker.class);
-   
+
    /** Notification sent before connectioning */
    private static final String CONNECTING_NOTIFICATION = "org.jboss.ejb.plugins.jms.CONNECTING";
 
@@ -99,7 +95,9 @@
    /** Notification sent at connection failure */
    private static final String FAILURE_NOTIFICATION = "org.jboss.ejb.plugins.jms.FAILURE";
    
-   /** {@link MessageListener#onMessage} reference. */
+   /**
+    * {@link MessageListener#onMessage} reference.
+    */
    protected static Method ON_MESSAGE;
 
    /**
@@ -108,7 +106,7 @@
     * successfull. Default value: javax.jms.Topic.
     */
    protected final static String DEFAULT_DESTINATION_TYPE = "javax.jms.Topic";
-   
+
    /**
     * Initialize the ON_MESSAGE reference.
     */
@@ -122,67 +120,113 @@
       }
       catch (Exception e)
       {
+         e.printStackTrace();
          throw new ExceptionInInitializerError(e);
       }
    }
    
+   // Attributes ----------------------------------------------------
+   
    protected boolean optimize;
 
-   /** Maximum number provider is allowed to stuff into a session. */
+   /**
+    * Maximum number provider is allowed to stuff into a session.
+    */
    protected int maxMessagesNr = 1;
 
-   /** Minimun pool size of server sessions. */
+   /**
+    * Minimun pool size of server sessions.
+    */
    protected int minPoolSize = 1;
 
-   /** Keep alive server sessions. */
+   /**
+    * Keep alive server sessions.
+    */
    protected long keepAlive = 30 * 1000;
 
-   /** Maximun pool size of server sessions. */
+   /**
+    * Maximun pool size of server sessions.
+    */
    protected int maxPoolSize = 15;
-
-   /** Time to wait before retrying to reconnect a lost connection. */
+   
+   /** The lazyInitialization */
+   protected boolean lazyInitialization = false;
+   
+   /** The recycleIdleSessions */
+   protected boolean recycleIdleSessions = false;
+   
+   /** The idleTimeoutMinutes */
+   //Thirty minutes by default
+   protected long idleTimeoutMinutes = 1000 * 60 * 30; 
+   
+   /** The alwaysReconnect */
+   protected boolean alwaysReconnect;
+   
+   protected boolean destroySessionOnError = false;
+   
+   protected String supportCodeUrl = "NoUrl";
+   
+   protected boolean validateLinkedException = false;
+   
+   protected String exceptionSorterClassName = "NoSorter";
+   
+   /**
+    * Time to wait before retrying to reconnect a lost connection.
+    */
    protected long reconnectInterval = 10000;
 
-   /** If Dead letter queue should be used or not. */
+   /**
+    * If Dead letter queue should be used or not.
+    */
    protected boolean useDLQ = false;
 
    /**
     * JNDI name of the provider adapter.
-    * 
     * @see org.jboss.jms.jndi.JMSProviderAdapter
     */
    protected String providerAdapterJNDI;
 
    /**
     * JNDI name of the server session factory.
-    * 
     * @see org.jboss.jms.asf.ServerSessionPoolFactory
     */
    protected String serverSessionPoolFactoryJNDI;
 
-   /** JMS acknowledge mode, used when session is not XA. */
+   /**
+    * JMS acknowledge mode, used when session is not XA.
+    */
    protected int acknowledgeMode;
 
    protected boolean isContainerManagedTx;
    protected boolean isNotSupportedTx;
 
-   /** The container. */
+   /**
+    * The container.
+    */
    protected Container container;
 
-   /** The JMS connection. */
+   /**
+    * The JMS connection.
+    */
    protected Connection connection;
 
-   /** The JMS connection consumer. */
+   /**
+    * The JMS connection consumer.
+    */
    protected ConnectionConsumer connectionConsumer;
 
    protected TransactionManager tm;
    protected ServerSessionPool pool;
    protected ExceptionListenerImpl exListener;
 
-   /** Dead letter queue handler. */
+   /**
+    * Dead letter queue handler.
+    */
    protected DLQHandler dlqHandler;
 
-   /** DLQConfig element from MDBConfig element from jboss.xml. */
+   /**
+    * DLQConfig element from MDBConfig element from jboss.xml.
+    */
    protected Element dlqConfig;
 
    protected InvokerProxyBindingMetaData invokerMetaData;
@@ -208,57 +252,271 @@
    {
       invokerBinding = binding;
    }
+
+   // ContainerService implementation -------------------------------
    
    /**
     * Set the container for which this is an invoker to.
-    * 
     * @param container The container for which this is an invoker to.
     */
    public void setContainer(final Container container)
    {
       this.container = container;
    }
+   
+   // Static --------------------------------------------------------
+   
+   // Constructors --------------------------------------------------
+   
+   // Public --------------------------------------------------------
 
+   /**
+    * @jmx:managed-attribute
+    */
    public int getMinPoolSize()
    {
       return minPoolSize;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public void setMinPoolSize(int minPoolSize)
    {
       this.minPoolSize = minPoolSize;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public int getMaxPoolSize()
    {
       return maxPoolSize;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public void setMaxPoolSize(int maxPoolSize)
    {
       this.maxPoolSize = maxPoolSize;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public long getKeepAliveMillis()
    {
       return keepAlive;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public void setKeepAliveMillis(long keepAlive)
    {
       this.keepAlive = keepAlive;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public int getMaxMessages()
    {
       return maxMessagesNr;
    }
 
+   /**
+    * @jmx:managed-attribute
+    */
    public void setMaxMessages(int maxMessages)
    {
       this.maxMessagesNr = maxMessages;
    }
+   
+   public long getIdleTimeOutMinutes()
+   {
+      return this.idleTimeoutMinutes / (1000 * 60);
+      
+   }
+   
+   public boolean getLazyInitialization()
+   {
+      return this.lazyInitialization;
+   }
+   
+   public void setLazyInitialization(boolean lazy)
+   {
+      this.lazyInitialization = lazy;
+      
+   }
+   
+   public boolean getRecycleIdleSessions()
+   {
+      return this.recycleIdleSessions;
+   }
+   
+   public void setRecycleIdleSessions(boolean recycle)
+   {
+      this.recycleIdleSessions = recycle;
+      
+   }
+   
+   public void setIdleTimeOutMinutes(long idleTimeout)
+   {
+      this.idleTimeoutMinutes = (idleTimeout * 1000 * 60);
+   }
+   
+   public boolean getAlwaysReconnect()
+   {
+      return this.alwaysReconnect;
+      
+   }
+   
+   public void setAlwaysReconnect(boolean alwaysReconnect)
+   {
+      this.alwaysReconnect = alwaysReconnect;
+   }
+   
+   public int getSessionTimedOutCount()
+   {
+      int timedOut = 0;
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         timedOut = sp.getTimedOut();
+      }
+      
+      return timedOut;
+   }
+   
+   public int getCurrentSessionCount() 
+   {
+      int currentCount = 0;
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         currentCount = sp.getCurrentSessionCount();
+      }
+      
+      return currentCount;
 
+   }
+   
+   public int getMaxSessionInUseCount()
+   {
+      int maxInUseCount = 0;
+     
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         maxInUseCount = sp.getSessionMaxInUseCount();
+      }
+      
+      return maxInUseCount;
+
+   }
+   
+   public int getCurrentSessionInUseCount()
+   {
+      int inUse = 0;
+      
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         inUse = sp.getCurrentSessionInUseCount();
+         
+      }
+      return inUse;
+      
+   }
+   
+   public int getSessionErrorCount()
+   {
+      int error = 0;
+      
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         error = sp.getSessionErrorCount();
+         
+      }
+      return error;
+   }
+   
+   public int getSessionCreatedCount()
+   {
+      int total = 0;
+      
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         total = sp.getSessionCreatedCount();
+         
+      }      
+      return total;
+   }
+   
+   public int getSessionDestroyedCount()
+   {
+      int destroyed = 0;
+      
+      if(pool != null)
+      {
+         StdServerSessionPool sp = (StdServerSessionPool)pool;
+         destroyed = sp.getSessionDestroyedCount();
+         
+      }      
+      return destroyed;
+   }
+      
+   
+   public boolean getDestroySessionOnError()
+   {
+      return destroySessionOnError;
+      
+   }
+   
+   public void setDestroySessionOnError(boolean destroy)
+   {
+      this.destroySessionOnError = destroy;
+      
+   }
+   
+   public String getExceptionSorterClassName()
+   {
+      return this.exceptionSorterClassName;
+      
+   }
+   
+   public void setExceptionSorterClassName(String name)
+   {
+      this.exceptionSorterClassName = name;
+   }
+   
+   public void setSupportCodeUrl(String supportCodeUrl)
+   {
+      this.supportCodeUrl = supportCodeUrl;
+   }
+   
+   public String getSupportCodeUrl()
+   {
+      return this.supportCodeUrl;
+      
+   }
+
+   public void setValidateLinkedException(boolean vle)
+   {
+      this.validateLinkedException = vle;
+   }
+   
+   public boolean getValidateLinkedException()
+   {
+      return this.validateLinkedException;
+   }
+   /**
+    * @jmx:managed-attribute
+    */
    public MessageDrivenMetaData getMetaData()
    {
       MessageDrivenMetaData config =
@@ -266,16 +524,27 @@
       return config;
    }
 
+   /**
+    * @return whether delivery is active
+    * @jmx:managed-attribute
+    */
    public boolean getDeliveryActive()
    {
       return deliveryActive;
    }
 
+   /**
+    * @return whether we are creating jbossmq destinations
+    * @jmx:managed-attribute
+    */
    public boolean getCreateJBossMQDestination()
    {
       return createJBossMQDestination;
    }
 
+   /**
+    * @jmx:managed-operation
+    */
    public void startDelivery()
       throws Exception
    {
@@ -286,7 +555,106 @@
       deliveryActive = true;
       startService();
    }
+   
+   /**
+    * @jmx:managed-operation
+    */
+   public void refreshSupportCodes()
+   {
+      if(pool instanceof StdServerSessionPool)
+      {
+         StdServerSessionPool stdPool = (StdServerSessionPool)pool;
+         stdPool.refreshSupportCodeFile();
+         
+      }
+   }
+   /**
+    * @jmx:managed-operation
+    */  
+   public void clearCurrentSupportCodes()
+   {
+      if(pool instanceof StdServerSessionPool)
+      {
+         StdServerSessionPool stdPool = (StdServerSessionPool)pool;
+         stdPool.clearCurrentSupportCodes();         
+         
+      }
+      
+   }
+   
+   /**
+    * @jmx:managed-operation
+    */
+   public void loadSupportCodeFile(String fileName)
+   {
+      if(pool instanceof StdServerSessionPool)
+      {
+         StdServerSessionPool stdPool = (StdServerSessionPool)pool;
+         stdPool.loadSupportCodeFile(fileName);
+                  
+      }
+      
+   }
+   
+   public void addSupportCodes(String fileName)
+   {
+      if(pool instanceof StdServerSessionPool)
+      {
+         StdServerSessionPool stdPool = (StdServerSessionPool)pool;
+         stdPool.addSupportCodes(fileName);         
+                  
+      }
+      
+   }
+   
+   public String isCodeInUse(int code)
+   {
+ 
+      if(pool instanceof StdServerSessionPool)
+      {
+         StdServerSessionPool stdPool = (StdServerSessionPool)pool;
+         boolean inUse = stdPool.isCodeInUse(code);         
+         return (inUse) ? "Support code " + code + " is in use" : "Support code " + code + " is not in use";         
+      }
+      
+      return "";
+      
+   }
+   public String listCurrentSupportCodes()
+   {      
+      Integer[] codes = null;
+      StringBuffer codeBuff = new StringBuffer();
+      codeBuff.append("JMS Fatal Exception Codes: \n");
+      
+      if(pool instanceof StdServerSessionPool)
+      {
+         StdServerSessionPool stdPool = (StdServerSessionPool)pool;
+         codes = stdPool.listCurrentSupportCodes();         
+                  
+      }
 
+      if(codes != null && codes.length != 0)
+      {
+         for (int i = 0; i < codes.length; i++)
+         {
+            Integer code = codes[i];
+            codeBuff.append("Fatal Code: " + code + "\n");
+            
+         }
+      
+      }else
+      {
+         codeBuff.append("No codes found.\n");
+         
+      }
+      
+      return codeBuff.toString();
+      
+   }
+   
+   /**
+    * @jmx:managed-operation
+    */
    public void stopDelivery()
       throws Exception
    {
@@ -297,63 +665,97 @@
       deliveryActive = false;
       stopService();
    }
-
+   
    /**
     * Sets the Optimized attribute of the JMSContainerInvoker object
-    * 
     * @param optimize The new Optimized value
     */
    public void setOptimized(final boolean optimize)
    {
+      if (log.isDebugEnabled())
+         log.debug("Container Invoker optimize set to " + optimize);
+
       this.optimize = optimize;
    }
+   
+   // EJBProxyFactory implementation
 
    public boolean isIdentical(Container container, Invocation mi)
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
+   /**
+    * Always throws an Error
+    * @throws Error Not valid for MDB
+    */
    public Object getEJBHome()
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
-   public EJBMetaData getEJBMetaData()
+   /**
+    * Always throws an Error
+    * @throws Error Not valid for MDB
+    */
+   public javax.ejb.EJBMetaData getEJBMetaData()
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
+   /**
+    * Always throws an Error
+    * @throws Error Not valid for MDB
+    */
    public Collection getEntityCollection(Collection ids)
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
+   /**
+    * Always throws an Error
+    * @throws Error Not valid for MDB
+    */
    public Object getEntityEJBObject(Object id)
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
+   /**
+    * Always throws an Error
+    * @throws Error Not valid for MDB
+    */
    public Object getStatefulSessionEJBObject(Object id)
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
+   /**
+    * Always throws an Error
+    * @throws Error Not valid for MDB
+    */
    public Object getStatelessSessionEJBObject()
    {
       throw new Error("Not valid for MessageDriven beans");
    }
 
+   /**
+    * Gets the Optimized attribute of the JMSContainerInvoker object
+    * @return The Optimized value
+    */
    public boolean isOptimized()
    {
+      if (log.isDebugEnabled())
+         log.debug("Optimize in action: " + optimize);
+
       return optimize;
    }
 
    /**
     * XmlLoadable implementation.
     *
-    * @todo FIXME - we ought to move all config into MDBConfig, but I do not do that
+    * FIXME - we ought to move all config into MDBConfig, but I do not do that
     * now due to backward compatibility.
-    * 
     * @param element Description of Parameter
     * @throws DeploymentException Description of Exception
     */
@@ -409,7 +811,107 @@
       catch (Exception ignore)
       {
       }
+      
+      try
+      {
+         String lazy =  MetaData.getElementContent
+            (MetaData.getUniqueChild(element, "LazyInitialization"));
+         lazyInitialization = Boolean.valueOf(lazy).booleanValue(); 
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+      
+      try
+      {
+         String ris =  MetaData.getElementContent
+            (MetaData.getUniqueChild(element, "RecycleIdleSessions"));
+         recycleIdleSessions = Boolean.valueOf(ris).booleanValue(); 
+         
+      }catch(Exception ignore)
+      {
+         
+      }
 
+      try
+      {
+         String rc =  MetaData.getElementContent
+            (MetaData.getUniqueChild(element, "AlwaysReconnect"));
+         alwaysReconnect = Boolean.valueOf(rc).booleanValue(); 
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+
+            
+      try
+      {
+         String it =  MetaData.getElementContent
+            (MetaData.getUniqueChild(element, "IdleTimeOutMinutes"));
+         idleTimeoutMinutes = (Integer.valueOf(it).longValue() * 1000 * 60); 
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+
+      try
+      {
+         String destroy =  MetaData.getElementContent
+            (MetaData.getUniqueChild(element, "DestroySessionOnError"));
+         destroySessionOnError = Boolean.valueOf(destroy).booleanValue(); ; 
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+
+      try
+      {
+         String url =  MetaData.getElementContent
+         (MetaData.getUniqueChild(element, "SupportCodeUrl"));
+         
+         if(url != null && !url.equalsIgnoreCase(""))
+         {
+            this.supportCodeUrl = url; 
+            
+         }
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+      
+      try
+      {
+         String linked = MetaData.getElementContent
+         (MetaData.getUniqueChild(element, "ValidateLinkedException"));
+         validateLinkedException = Boolean.valueOf(linked).booleanValue();
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+      
+      try
+      {
+         
+         String sorter = MetaData.getElementContent
+         (MetaData.getUniqueChild(element, "ExceptionSorterClassName"));
+         
+         if(sorter != null && !sorter.equalsIgnoreCase(""))
+         {
+            this.exceptionSorterClassName = sorter;
+         }
+         
+      }catch(Exception ignore)
+      {
+         
+      }
+            
+      
       Element mdbConfig = MetaData.getUniqueChild(element, "MDBConfig");
 
       try
@@ -468,22 +970,20 @@
     * Initialize the container invoker. Sets up a connection, a server session
     * pool and a connection consumer for the configured destination.
     *
-    * <p>Any JMSExceptions produced while initializing will be assumed to be caused
+    * Any JMSExceptions produced while initializing will be assumed to be caused
     * due to JMS Provider failure.
-    * 
     * @throws Exception Failed to initalize.
     */
    protected void createService() throws Exception
    {
       importXml(invokerMetaData.getProxyFactoryConfig());
 
-      exListener = new ExceptionListenerImpl(this);
+      exListener = new ExceptionListenerImpl(this, alwaysReconnect);
    }
 
    /**
     * Initialize the container invoker. Sets up a connection, a server session
     * pool and a connection consumer for the configured destination.
-    * 
     * @throws Exception Failed to initalize.
     */
    protected void innerStartDelivery() throws Exception
@@ -494,10 +994,12 @@
          return;
       }
       
+      
       sendNotification(CONNECTING_NOTIFICATION, null);
 
+      
       log.debug("Initializing");
-
+      
       // Get the JMS provider
       JMSProviderAdapter adapter = getJMSProviderAdapter();
       log.debug("Provider adapter: " + adapter);
@@ -670,6 +1172,9 @@
                keepAlive,
                true, // tx
                acknowledgeMode,
+               lazyInitialization,
+               recycleIdleSessions,
+               idleTimeoutMinutes,
                new MessageListenerImpl(this));
 
             int subscriptionDurablity = config.getSubscriptionDurability();
@@ -788,6 +1293,9 @@
                keepAlive,
                true, // tx
                acknowledgeMode,
+               lazyInitialization,
+               recycleIdleSessions,
+               idleTimeoutMinutes,
                new MessageListenerImpl(this));
             log.debug("Server session pool: " + pool);
             
@@ -817,23 +1325,27 @@
       log.debug("Initialized with config " + toString());
 
       context.close();
-      
+
       if (dlqHandler != null)
-      {
          dlqHandler.start();
-      }
 
       if (connection != null)
       {
          connection.setExceptionListener(exListener);
          connection.start();
       }
-
+      
       sendNotification(CONNECTED_NOTIFICATION, null);
    }
 
    protected void startService() throws Exception
    {
+      
+      if(exListener != null)
+      {
+         exListener.setAlwaysReconnect(alwaysReconnect);
+      }
+      
       try
       {
          innerStartDelivery();
@@ -883,7 +1395,7 @@
       }
       catch (Throwable t)
       {
-         log.trace("Could not set ExceptionListener to null", t);
+         log.error("Could not set ExceptionListener to null", t);
       }
       
       // Stop the connection
@@ -897,28 +1409,25 @@
       }
       catch (Throwable t)
       {
-         log.trace("Could not stop JMS connection", t);
+         log.error("Could not stop JMS connection", t);
       }
 
-      try
+      if (dlqHandler != null)
       {
-         if (dlqHandler != null)
-            dlqHandler.stop();
+         dlqHandler.stop();
       }
-      catch (Throwable t)
-      {
-         log.trace("Failed to stop the dlq handler", t);
-      }
 
       // close the connection consumer
       try
       {
          if (connectionConsumer != null)
+         {
             connectionConsumer.close();
+         }
       }
       catch (Throwable t)
       {
-         log.trace("Failed to close connection consumer", t);
+         log.error("Failed to close connection consumer", t);
       }
       connectionConsumer = null;
       
@@ -933,7 +1442,7 @@
       }
       catch (Throwable t)
       {
-         log.trace("Failed to clear session pool", t);
+         log.error("Failed to clear session pool", t);
       }
       
       // close the connection
@@ -945,7 +1454,7 @@
          }
          catch (Throwable t)
          {
-            log.trace("Failed to close connection", t);
+            log.error("Failed to close connection", t);
          }
       }
       connection = null;
@@ -960,7 +1469,7 @@
       }
       catch (Throwable t)
       {
-         log.trace("Failed to close the dlq handler", t);
+         log.error("Failed to close the dlq handler", t);
       }
       dlqHandler = null;
       
@@ -996,7 +1505,6 @@
     * Try to get a destination type by looking up the destination JNDI, or
     * provide a default if there is not destinationJNDI or if it is not possible
     * to lookup.
-    * 
     * @param ctx The naming context to lookup destinations from.
     * @param destinationJNDI The name to use when looking up destinations.
     * @return The destination type, either derived from destinationJDNI or
@@ -1039,10 +1547,10 @@
 
    /**
     * Return the JMSProviderAdapter that should be used.
-    * 
     * @return The JMSProviderAdapter to use.
     */
-   protected JMSProviderAdapter getJMSProviderAdapter() throws NamingException
+   protected JMSProviderAdapter getJMSProviderAdapter()
+      throws NamingException
    {
       Context context = new InitialContext();
       try
@@ -1058,7 +1566,6 @@
 
    /**
     * Create and or lookup a JMS destination.
-    * 
     * @param type Either javax.jms.Queue or javax.jms.Topic.
     * @param ctx The naming context to lookup destinations from.
     * @param jndiName The name to use when looking up destinations.
@@ -1153,6 +1660,9 @@
       final long keepAlive,
       final boolean isTransacted,
       final int ack,
+      final boolean lazyInit,
+      final boolean recycleIdle,
+      final long idleTimeout,
       final MessageListener listener)
       throws NamingException, JMSException
    {
@@ -1168,7 +1678,7 @@
             context.lookup(serverSessionPoolFactoryJNDI);
          
          // the create the pool
-         pool = factory.getServerSessionPool(destination, connection, minSession, maxSession, keepAlive, isTransacted, ack, !isContainerManagedTx || isNotSupportedTx, listener);
+         pool = factory.getServerSessionPool(destination, connection, minSession, maxSession, keepAlive, isTransacted, ack, !isContainerManagedTx || isNotSupportedTx, lazyInit, recycleIdle, idleTimeout, destroySessionOnError, supportCodeUrl, exceptionSorterClassName, validateLinkedException, listener);
       }
       finally
       {
@@ -1193,7 +1703,6 @@
    
    /**
     * Parse the JNDI suffix from the given JNDI name.
-    * 
     * @param jndiname The JNDI name used to lookup the destination.
     * @param defautSuffix Description of Parameter
     * @return The parsed suffix or the defaultSuffix
@@ -1231,28 +1740,33 @@
     * An implementation of MessageListener that passes messages on to the
     * container invoker.
     */
-   class MessageListenerImpl implements MessageListener
+   class MessageListenerImpl
+      implements MessageListener
    {
-      /** The container invoker. */
+      /**
+       * The container invoker.
+       */
       JMSContainerInvoker invoker;
+      // = null;
       
       /**
        * Construct a <tt>MessageListenerImpl</tt> .
-       * 
        * @param invoker The container invoker. Must not be null.
        */
       MessageListenerImpl(final JMSContainerInvoker invoker)
       {
+         // assert invoker != null;
+         
          this.invoker = invoker;
       }
 
       /**
        * Process a message.
-       * 
        * @param message The message to process.
        */
       public void onMessage(final Message message)
       {
+         // assert message != null;
          if (log.isTraceEnabled())
          {
             log.trace("processing message: " + message);
@@ -1306,7 +1820,8 @@
       JMSContainerInvoker invoker;
       Thread currentThread;
       boolean notStopped = true;
-
+      boolean alwaysReconnect;
+      
       /**
        * Create a new ExceptionListenerImpl.
        * 
@@ -1316,6 +1831,12 @@
       {
          this.invoker = invoker;
       }
+      
+      ExceptionListenerImpl(final JMSContainerInvoker invoker, boolean alwaysReconnect)
+      {
+         this.invoker = invoker;
+         this.alwaysReconnect = alwaysReconnect;
+      }
 
       /**
        * Called on jms connection failure events
@@ -1326,7 +1847,7 @@
       {
          handleFailure(ex);
       }
-
+      
       /**
        * Handle a failure
        * 
@@ -1337,12 +1858,19 @@
          MessageDrivenMetaData metaData = invoker.getMetaData();
          log.warn("JMS provider failure detected for " + metaData.getEjbName(), t);
          
-         // JBAS-3750 - Help debug integration with foreign JMS providers
-         if (t instanceof JMSException)
+         if(t instanceof JMSException)
          {
-            Exception le = ((JMSException)t).getLinkedException();
-            if (le != null)
-               log.debug("Linked exception: " + le + ", cause: " + le.getCause());
+            JMSException jmex = (JMSException)t;            
+            Exception linked = jmex.getLinkedException();
+            
+            if(linked != null)
+            {
+               log.trace("JMSException error code " + jmex.getErrorCode());
+               log.trace("JMSException linked exception", linked);
+               log.trace("JMSException cause", linked.getCause());
+               
+            }
+            
          }
          
          // Run the reconnection in the background
@@ -1373,7 +1901,10 @@
             }
          }
       }
-
+      void setAlwaysReconnect(boolean alwaysReconnect)
+      {
+         this.alwaysReconnect = alwaysReconnect;
+      }
       class ExceptionListenerRunnable implements Runnable
       {
          Throwable failure;
@@ -1397,7 +1928,7 @@
             try
             {
                boolean tryIt = true;
-               while (tryIt && notStopped)
+               while (tryIt && notStopped || tryIt && alwaysReconnect)
                {
                   try
                   {
@@ -1445,7 +1976,21 @@
             }
          }
       }
-
+      
+//      void restart()
+//      {
+//         synchronized (lock)
+//         {
+//            log.debug("Start requested for recovery thread: " + currentThread);
+//            notStopped = true;
+//            if (currentThread != null)
+//            {
+//               currentThread.interrupt();
+//               log.debug("Recovery thread interrupted: " + currentThread);
+//            }
+//            
+//         }
+//      }
       void stop()
       {
          synchronized (lock)

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java	2006-12-07 21:58:03 UTC (rev 58909)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java	2006-12-07 21:59:27 UTC (rev 58910)
@@ -1,125 +1,101 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.ejb.plugins.jms;
 
-import org.jboss.metadata.MessageDrivenMetaData;
-
 /**
  * MBean interface.
- * 
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
- * @version <tt>$Revision$</tt>
+ * @author <a href="mailto:weston.price at jboss.com>Weston Price</a>
  */
 public interface JMSContainerInvokerMBean extends org.jboss.system.ServiceMBean
 {
-   /**
-    * Get the minimum pool size
-    * 
-    * @return the minimum pool size
-    */
+
    int getMinPoolSize();
 
-   /**
-    * Set the minimum pool size
-    * 
-    * @param minPoolSize the size
-    */
    void setMinPoolSize(int minPoolSize);
 
-   /**
-    * Get the maximum pool size
-    * 
-    * @return the maximum pool size
-    */
    int getMaxPoolSize();
 
-   /**
-    * Set the maximum pool size
-    * 
-    * @param maxPoolSize the size
-    */
    void setMaxPoolSize(int maxPoolSize);
 
-   /**
-    * Get the keep alive millis
-    * 
-    * @return the milliseconds
-    */
    long getKeepAliveMillis();
 
-   /**
-    * Set the keep alive millis
-    * 
-    * @param keepAlive the milliseconds
-    */
    void setKeepAliveMillis(long keepAlive);
 
-   /**
-    * Get the maximum number of messages
-    * 
-    * @return the number of messages
-    */
    int getMaxMessages();
 
-   /**
-    * Set the maximum number of messages
-    * 
-    * @param maxMessages the number of messages
-    */
    void setMaxMessages(int maxMessages);
 
-   /**
-    * Get the message driven metadata
-    * 
-    * @return the metadata
-    */
-   MessageDrivenMetaData getMetaData();
+   org.jboss.metadata.MessageDrivenMetaData getMetaData();
 
-   /**
-    * Get whether delivery is active
-    * 
-    * @return true when active
-    */
    boolean getDeliveryActive();
 
-   /**
-    * Get whether JBossMQ destinations should be constructed
-    * when the destination is not in JNDI
-    * 
-    * @return true to create
-    */
    boolean getCreateJBossMQDestination();
 
-   /**
-    * Start delivery
-    * 
-    * @throws Exception for any error
-    */
-   void startDelivery() throws Exception;
+   void startDelivery() throws java.lang.Exception;
 
-   /**
-    * Stop delivery
-    * 
-    * @throws Exception for any error
-    */
-   void stopDelivery() throws Exception;
+   void stopDelivery() throws java.lang.Exception;
+   
+   boolean getLazyInitialization();
+   
+   void setLazyInitialization(boolean lazy);
+      
+   void setRecycleIdleSessions(boolean recycle);
+   
+   boolean getRecycleIdleSessions();
+   
+   long getIdleTimeOutMinutes();
+   
+   void setIdleTimeOutMinutes(long idleTimeout);
+   
+   int getSessionTimedOutCount();
+
+   int getCurrentSessionCount();
+  
+   int getCurrentSessionInUseCount();
+   
+   int getMaxSessionInUseCount();
+   
+   int getSessionErrorCount();
+   
+   int getSessionCreatedCount();
+   
+   int getSessionDestroyedCount();
+   
+   void setAlwaysReconnect(boolean alwaysReconnect);
+   
+   boolean getAlwaysReconnect();
+  
+   boolean getDestroySessionOnError();
+   
+   void setDestroySessionOnError(boolean destroy);
+   
+   String getExceptionSorterClassName();
+   
+   void setExceptionSorterClassName(String name);
+   
+   String getSupportCodeUrl();
+   
+   void setSupportCodeUrl(String supportCodeUrl);
+   
+   boolean getValidateLinkedException();
+   
+   void setValidateLinkedException(boolean vle);
+   
+   public void loadSupportCodeFile(String fileName);
+   
+   public void refreshSupportCodes();
+   
+   public String listCurrentSupportCodes();
+   
+   public void clearCurrentSupportCodes();
+   
+   public void addSupportCodes(String fileName);
+   
+   public String isCodeInUse(int code);
+   
+   
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:00:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:00:01 -0500
Subject: [jboss-cvs] JBossAS SVN: r58911 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf
Message-ID: <E1GsRHd-0001x6-HA@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 16:59:59 -0500 (Thu, 07 Dec 2006)
New Revision: 58911

Added:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,39 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import javax.jms.JMSException;
+
+
+/**
+ * A AllFatalJMSExceptionSorter.
+ * 
+ * @author <a href="mailto:weston.price at jboss.org>Weston Price</a>
+ * @version $Revision: 1.1 $
+ */
+public class AllFatalJMSExceptionSorter implements JMSExceptionSorter
+{
+   private boolean validateLinkedException;
+   
+   public boolean isJMSExceptionFatal(JMSException e)
+   {
+      return true;
+   }
+
+   public boolean getValidateLinkedException()
+   {
+      return this.validateLinkedException;
+   }
+
+   public void setValidateLinkedException(boolean vle)
+   {
+      this.validateLinkedException = vle;
+      
+   }
+
+   
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import javax.jms.JMSException;
+
+/**
+ * A AllNonFatalJMSExceptionSorter.
+ * 
+ * @author <a href="mailto:weston.price at jboss.org>Weston Price</a>
+ * @version $Revision: 1.1 $
+ */
+public class AllNonFatalJMSExceptionSorter implements JMSExceptionSorter
+{
+   private boolean validateLinkedException;
+   
+   public boolean isJMSExceptionFatal(JMSException e)
+   {      
+      return false;
+   }
+
+   public boolean getValidateLinkedException()
+   {
+      return this.validateLinkedException;
+   }
+
+   public void setValidateLinkedException(boolean vle)
+   {
+      this.validateLinkedException = vle;
+      
+   }
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,33 @@
+package org.jboss.jms.asf;
+
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
+
+import org.jboss.logging.Logger;
+
+public class JMSExceptionCodeMatcher
+{
+   private static final Logger log = Logger.getLogger(JMSExceptionCodeMatcher.class);
+   
+   public static boolean matches(final String errorCode, final String code)
+   {   
+      boolean matches = false;
+      boolean trace = log.isTraceEnabled();
+      
+      if(trace)
+         log.trace("Attempting to match JMSErrorCode: " + errorCode + " with candidate code " + code);
+      Pattern p = Pattern.compile(code);
+      Matcher m = p.matcher(errorCode);
+      matches = m.find();
+      
+      if(trace)
+         log.trace("Match results for JMSErrorCode: " +  errorCode + " with candidate " + code + " are" + matches);
+
+      return matches;
+   }
+
+   public static boolean matches(String errorCode, Integer code)
+   {
+      return matches(errorCode, code.toString());
+   }
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,11 @@
+package org.jboss.jms.asf;
+
+import javax.jms.JMSException;
+
+public interface JMSExceptionSorter
+{
+   
+   public boolean isJMSExceptionFatal(JMSException e);
+   public void setValidateLinkedException(boolean vle);
+   public boolean getValidateLinkedException();
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,249 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.jms.JMSException;
+
+import org.jboss.logging.Logger;
+
+/**
+ * A JMSSupportCodeHandler.
+ * 
+ *
+ */
+public class JMSSupportCodeHandler implements JMSExceptionSorter
+{
+   private static final Logger log = Logger.getLogger(JMSSupportCodeLoader.class);
+   private static final String NO_SORTER = "NoSorter";
+   private static final String NO_URL = "NoUrl";
+   
+   private boolean validateLinkedExcpetion;
+   private List fatalCodes = new ArrayList();
+   private JMSExceptionSorter sorter;
+   private String supportCodeUrl;
+   
+   public boolean hasSupportCodes()
+   {
+      return fatalCodes.size() > 0;
+      
+   }
+   
+   //For testing only.
+   public JMSExceptionSorter getUnderlyingSorter()
+   {
+      return this.sorter;
+      
+   }
+   
+   public JMSSupportCodeHandler(final String fileName, final String sorterClassName)
+   {
+      this(fileName, sorterClassName, false);
+      
+   }
+   public JMSSupportCodeHandler(final String fileName, final String sorterClassName, boolean validateLinkedException)
+   {
+      this.validateLinkedExcpetion = validateLinkedException;
+      
+      if(sorterClassName == null || sorterClassName.equalsIgnoreCase(NO_SORTER))
+      {  
+         
+         if(fileName != null && !fileName.equalsIgnoreCase("") && !fileName.equalsIgnoreCase(NO_URL))
+         {
+            log.trace("Exception sorter class name is null. Attempting to load codes from external file " + fileName);
+            this.supportCodeUrl = fileName;
+            fatalCodes = JMSSupportCodeLoader.loadJMSSupportCodes(fileName);
+            
+         }else
+         {
+            log.trace("No external url or exception sorter classname was provided. JMSSessions will not be validated.");
+         }
+         
+         
+      }else
+      {
+         
+         final ClassLoader cl = Thread.currentThread().getContextClassLoader();
+         
+         try
+         {
+            final Class sorterClass = cl.loadClass(sorterClassName);
+            sorter = (JMSExceptionSorter)sorterClass.newInstance();
+            sorter.setValidateLinkedException(validateLinkedException);
+            
+         }catch(Exception e)
+         {
+            log.error("Sorter class " + sorterClassName + " could not be loaded. Using default exception sorter");
+            sorter = new AllNonFatalJMSExceptionSorter();
+            sorter.setValidateLinkedException(validateLinkedException);
+         }
+         
+         
+      }
+      
+   }
+
+   public JMSSupportCodeHandler(final String fileName)
+   {
+      this(fileName, null, false);
+      
+   }
+   
+   public void reloadSupportFile()
+   {      
+      if(fatalCodes != null)
+         log.trace("Attempting to reload support code file " + supportCodeUrl);
+      
+      synchronized (this)
+      {
+         if(fatalCodes != null)
+         {
+            fatalCodes = null;
+            fatalCodes = JMSSupportCodeLoader.loadJMSSupportCodes(supportCodeUrl);
+            
+         }
+      }      
+   }
+
+   public void addSupportCodes(String fileName)
+   {
+      if(fatalCodes != null)
+         log.trace("Attempting to reload support code file " + fileName);
+
+      List newCodes = JMSSupportCodeLoader.loadJMSSupportCodes(fileName);
+      
+      synchronized (fatalCodes)
+      {
+         fatalCodes.addAll(newCodes);
+                 
+      }
+      
+   }
+   
+   public boolean isCodeInUse(int code)
+   {
+      return (fatalCodes != null && fatalCodes.contains(new Integer(code)));
+      
+   }
+   public void reloadSupportFile(String fileName)
+   {
+      if(fatalCodes != null)
+         log.trace("Attempting to reload support code file " + fileName);
+      
+      synchronized (this)
+      {
+         fatalCodes = JMSSupportCodeLoader.loadJMSSupportCodes(fileName);
+         
+      }
+            
+   }
+   
+   public void clearSupportCodes()
+   {
+      synchronized (fatalCodes)
+      {
+         fatalCodes.clear();
+         
+      }      
+      
+   }
+   public Integer[] getCurrentCodes()
+   {
+      synchronized (fatalCodes)
+      {
+         return (Integer[]) fatalCodes.toArray(new Integer[fatalCodes.size()]);      
+         
+      }
+   }
+   
+   public boolean isJMSExceptionFatal(final JMSException e)
+   {
+    
+      if(sorter != null)
+      {
+         return sorter.isJMSExceptionFatal(e);
+         
+      }
+      
+      boolean fatal = false;      
+      final String errorCode = e.getErrorCode();
+      
+      if(errorCode != null)
+      {
+         for(Iterator iter = fatalCodes.iterator(); iter.hasNext();)
+         {
+            Integer code = (Integer)iter.next();         
+            
+            if(code != null)
+            {
+           
+               
+               if(JMSExceptionCodeMatcher.matches(errorCode, code))
+               {
+                  log.trace("JMS error code " + errorCode + " contains value " + code + " and will be processed as a fatal exception.");
+                  fatal = true;               
+                  break;
+               }
+            }
+         
+         }         
+      }
+      
+      if(fatal || !fatal && !validateLinkedExcpetion)
+      {
+         return fatal;
+      }
+      
+      if(e.getLinkedException() instanceof JMSException)
+      {
+         JMSException linked = (JMSException)e.getLinkedException();
+         final String linkedErrorCode = linked.getErrorCode();
+         
+         if(linkedErrorCode != null)
+         {
+            for(Iterator iter = fatalCodes.iterator(); iter.hasNext();)
+            {
+               Integer code = (Integer)iter.next();
+               
+               if(linkedErrorCode != null)
+               {
+                  if(JMSExceptionCodeMatcher.matches(linkedErrorCode,code))
+                  {
+                     log.trace("JMS error code from linked exception " + linkedErrorCode + " contains value " + code + " and will be processed as a fatal exception.");
+                     fatal = true;
+                     break;
+                  }
+                  
+               }
+            }
+                     
+         }
+      }
+   
+      return fatal;
+   }
+
+   public boolean getValidateLinkedException()
+   {
+      return validateLinkedExcpetion;
+      
+   }
+
+   public void setValidateLinkedException(boolean vle)
+   {
+      this.validateLinkedExcpetion = vle;
+      
+   }
+
+   
+
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,151 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import java.io.File;
+import java.io.FileReader;
+import java.io.InputStream;
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+
+import org.jboss.logging.Logger;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
+import org.xml.sax.InputSource;
+
+/**
+ * A JMSSupportCodeLoader.
+ *
+ */
+public class JMSSupportCodeLoader
+{
+   private static final Logger log = Logger.getLogger(JMSSupportCodeLoader.class);
+   private static final String FATAL_CODE_ELEM_NAME = "jms-fatal-code";
+   
+   public static List loadJMSSupportCodes(final String fileName)
+   {
+      final List supportCodes = new ArrayList();
+      InputStream is = null;
+      DocumentBuilder builder = null;
+      InputSource source = null;
+      boolean loaded = false;
+      
+      if(fileName == null)
+         return supportCodes;
+      
+      try
+      {
+         if(fileName != null)
+         {
+            
+            try
+            {
+               builder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
+               
+            }catch(Exception e)
+            {
+               log.trace("Could not instantiate DocumentBuilder.", e);
+               return supportCodes;
+               
+            }
+            
+            //First try the file system
+            try
+            {
+               source = new InputSource(new FileReader(new File(fileName)));
+               loaded = true;
+            
+            }catch(Exception e)
+            {
+               log.trace("Could not load filesystem resource", e);                           
+            }
+
+            if(source == null || loaded == false)
+            {
+               log.debug("Could not load filesystem resource " + fileName + " attempting to load from classpath");            
+               final ClassLoader cl = Thread.currentThread().getContextClassLoader();
+               is = cl.getResourceAsStream(fileName);
+               
+               if(is == null)
+               {
+                  log.debug("Could not load system resource " + fileName + " from classpath");
+                  return supportCodes;
+               }
+               
+               source = new InputSource(is);
+            }
+            
+            try
+            {
+               Document document = builder.parse(source);            
+               //Get nodes and populate
+               NodeList nl = document.getElementsByTagName(FATAL_CODE_ELEM_NAME);
+               log.debug("Found " + nl.getLength() + " codes for processing.");
+               
+               for(int i = 0; i < nl.getLength(); i++)
+               {
+                  Node fatal = (Node)nl.item(i);
+                  String txt = fatal.getFirstChild().getNodeValue();
+                  
+                  try
+                  {
+                     
+                     if(txt != null)
+                     {
+                        Integer code = Integer.valueOf(txt);
+                        supportCodes.add(code);
+                        
+                     }
+                  
+                  }catch(Exception e)
+                  {
+                     log.trace("Could not format or add supoprt code " + txt + " please validate support code file " + fileName);
+                     
+                  }
+                  
+               }
+
+               log.trace("Loaded " + supportCodes.size() + " codes " + "from " + fileName);       
+               
+               return supportCodes;
+               
+            }catch(Exception e)
+            {
+               log.trace("Could not parse support code file.", e);
+               return supportCodes;            
+               
+            }
+                        
+         }
+           
+         
+      }finally
+      {
+         try
+         {
+            if(is != null)
+               is.close();
+            
+         }catch(Exception ignore)
+         {
+            
+         }
+      }
+      
+      return supportCodes;
+      
+      
+   }
+   
+   
+   
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,134 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Iterator;
+
+import org.jboss.logging.Logger;
+
+/**
+ * A JmsServerSessionReaper based on JCA <code>org.jboss.resource.connectionmanager.IdleRemover</code>.
+ * 
+ * @author <a href="mailto:weston.price at jboss.com>Weston Price</a>
+ * 
+ * @see org.jboss.resource.connectionmanager.IdleRemover
+ * @version $Revision: 1.1 $
+ */
+public class JmsServerSessionReaper
+{
+   
+   private static final Logger logger = Logger.getLogger(JmsServerSessionReaper.class);
+   private static final Collection pools = new ArrayList();
+   private long interval = Long.MAX_VALUE;
+   private long next = Long.MAX_VALUE;
+   private Thread reaperThread;
+   
+   private static final JmsServerSessionReaper reaper = new JmsServerSessionReaper();
+   
+   public static void registerSessionPool(StdServerSessionPool pool, long interval)
+   {
+      reaper.internalRegisterPool(pool, interval);
+   }
+   
+   public static void unregisterSessionPool(StdServerSessionPool pool)
+   {     
+      reaper.internalUnregisterPool(pool);
+   }
+
+   private JmsServerSessionReaper()
+   {
+      reaperThread = new Thread(
+            new Runnable() {
+
+               public void run()
+               {
+                  synchronized (pools)
+                  {
+                     while (true)
+                     {
+                        try 
+                        {
+                           pools.wait(interval);
+                           logger.debug("run: JmsSessionReaper notifying pools, interval: " + interval);
+                           
+                           for (Iterator i = pools.iterator(); i.hasNext(); ) 
+                           {
+                             StdServerSessionPool pool = (StdServerSessionPool)i.next();
+                             pool.removeTimedOut();
+                           } 
+                           next = System.currentTimeMillis() + interval;
+                           
+                           if (next < 0) 
+                           {
+                              next = Long.MAX_VALUE;      
+                           } 
+                           
+                        }
+                        catch (InterruptedException ie)
+                        {
+                           logger.info("run: JmsSessionReaper has been interrupted, returning");
+                           return;  
+                        } 
+                        catch (RuntimeException e)
+                        {
+                           logger.warn("run: JmsSessionReaper ignored unexpected runtime exception", e);
+                        }
+                        catch (Error e)
+                        {
+                           logger.warn("run: JmsSessionReaper ignored unexpected error", e);
+                        }
+                           
+                     } 
+                     
+                  }
+               }
+            }, "JmsSessionReaper");
+         reaperThread.setDaemon(true);
+         reaperThread.start();
+      
+   }
+   private void internalRegisterPool(StdServerSessionPool pool, long interval)
+   {
+      logger.debug("Registering StdServerSessionPool with interval " + interval);
+      
+      synchronized (pools)
+      {
+         pools.add(pool);
+         
+         if (interval > 1 && interval/2 < this.interval) 
+         {
+            this.interval = interval/2;
+            long maybeNext = System.currentTimeMillis() + this.interval;
+            if (next > maybeNext && maybeNext > 0) 
+            {
+               next = maybeNext;
+               logger.debug("internalRegisterPool: about to notify thread: old next: " + next + ", new next: " + maybeNext);
+               pools.notify();
+
+            } 
+            
+         } 
+      }
+      
+   }
+   
+   private void internalUnregisterPool(StdServerSessionPool pool)
+   {
+      synchronized (pools)
+      {
+         pools.remove(pool);
+         if (pools.size() == 0) 
+         {
+            logger.debug("internalUnregisterPool: setting interval to Long.MAX_VALUE");
+            interval = Long.MAX_VALUE;
+         } 
+         
+      }
+   }
+}

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java	2006-12-07 21:59:27 UTC (rev 58910)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java	2006-12-07 21:59:59 UTC (rev 58911)
@@ -0,0 +1,90 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import java.util.LinkedList;
+
+/**
+ * A JmsSessionPoolFiller.
+ * 
+ * @author <a href="weston.price at jboss.com">Weston Price</a>
+ * @version $Revision: 1.1 $
+ */
+public class JmsSessionPoolFiller implements Runnable
+{
+   private final LinkedList pools = new LinkedList();
+
+   private final Thread fillerThread;
+
+   private static final JmsSessionPoolFiller filler = new JmsSessionPoolFiller();
+
+   public static void fillPool(StdServerSessionPool pool)
+   {
+      filler.internalFillPool(pool);
+   }
+
+   public JmsSessionPoolFiller ()
+   {
+      fillerThread = new Thread(this, "JMS Session PoolFiller");
+      fillerThread.start();
+   }
+
+   public void run()
+   {
+      ClassLoader myClassLoader = getClass().getClassLoader();
+      Thread.currentThread().setContextClassLoader(myClassLoader);
+      //keep going unless interrupted
+      while (true)
+      {
+         try 
+         {
+            StdServerSessionPool sp = null;
+            //keep iterating through pools till empty, exception escapes.
+            while (true)
+            {
+                     
+               synchronized (pools)
+               {
+                  sp = (StdServerSessionPool)pools.removeFirst();
+               }
+               if (sp == null) 
+               {
+                  break;
+               } 
+                        
+               sp.fillToMin();
+            } 
+
+         }
+         catch (Exception e)
+         {
+         } 
+                        
+         try 
+         {
+            synchronized (pools)
+            {
+               pools.wait();                        
+            }
+         }
+         catch (InterruptedException ie)
+         {
+            return;
+         } 
+      } 
+   }
+
+   private void internalFillPool(StdServerSessionPool mcp)
+   {
+      synchronized (pools)
+      {
+         pools.addLast(mcp);
+         pools.notify();
+      }
+   }
+   
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:00:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:00:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r58912 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf
Message-ID: <E1GsRHx-0001yI-5p@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 17:00:20 -0500 (Thu, 07 Dec 2006)
New Revision: 58912

Added:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Added: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java	2006-12-07 21:59:59 UTC (rev 58911)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java	2006-12-07 22:00:20 UTC (rev 58912)
@@ -0,0 +1,91 @@
+/*
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.asf;
+
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.jms.JMSException;
+
+/**
+ * A WebSphereMQExceptionSorter.
+ * 
+ */
+public class WebSphereMQExceptionSorter implements JMSExceptionSorter
+{
+   private static final List errorCodes = new ArrayList();
+   private boolean validateLinkedException = true;
+   
+   static
+   {
+      errorCodes.add(new Integer(2009));                 
+   }
+
+   public boolean isJMSExceptionFatal(final JMSException e)
+   {          
+      
+      final String errorCode = e.getErrorCode();
+      boolean fatal = false;
+      
+      if(errorCode != null)
+      {
+         for(Iterator iter = errorCodes.iterator(); iter.hasNext();)
+         {
+            final Integer code = (Integer)iter.next();
+            
+            if(JMSExceptionCodeMatcher.matches(errorCode, code))
+            {
+               fatal = true;
+               break;            
+            }
+         }
+         
+      }
+  
+      if(!fatal && validateLinkedException)
+      {
+         
+         if(e.getLinkedException() instanceof JMSException)
+         {
+            final JMSException linked = (JMSException)e.getLinkedException();
+            
+            if(linked != null && linked.getErrorCode() != null)
+            {
+               final String linkedCode = linked.getErrorCode();
+
+               for(Iterator iter = errorCodes.iterator(); iter.hasNext();)
+               {
+                  Integer code = (Integer)iter.next();
+                  
+                  if(JMSExceptionCodeMatcher.matches(linkedCode, code))
+                  {
+                     fatal = true;
+                     break;            
+                  }
+               }                             
+            }
+                     
+         }
+               
+      }
+      
+      return fatal;      
+   }
+   
+   public boolean getValidateLinkedException()
+   {
+      return this.validateLinkedException;
+   }
+
+   public void setValidateLinkedException(boolean vle)
+   {
+      this.validateLinkedException = vle;
+      
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:00:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:00:40 -0500
Subject: [jboss-cvs] JBossAS SVN: r58913 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf
Message-ID: <E1GsRIG-0001yz-4W@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 17:00:38 -0500 (Thu, 07 Dec 2006)
New Revision: 58913

Modified:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java	2006-12-07 22:00:20 UTC (rev 58912)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java	2006-12-07 22:00:38 UTC (rev 58913)
@@ -1,23 +1,8 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.jms.asf;
 
@@ -31,10 +16,11 @@
 /**
  * Defines the model for creating <tt>ServerSessionPoolFactory</tt> objects. <p>
  *
+ * Created: Wed Nov 29 15:55:21 2000
+ *
  * @author    <a href="mailto:peter.antman at tim.se">Peter Antman</a> .
  * @author    <a href="mailto:hiram.chirino at jboss.org">Hiram Chirino</a> .
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
+ * @author    <a href="mailto:weston.price at jboss.com>Weston Price</a>
  * @version   $Revision$
  */
 public interface ServerSessionPoolFactory
@@ -84,7 +70,29 @@
     * @return A new pool.
     * @throws JMSException for any error
     */
-   ServerSessionPool getServerSessionPool(Destination destination, Connection con, int minSession, int maxSession,
-         long keepAlive, boolean isTransacted, int ack, boolean useLocalTX, MessageListener listener)
-         throws JMSException;
+   ServerSessionPool getServerSessionPool(Destination destination, Connection con, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack,
+         boolean useLocalTX, MessageListener listener) throws JMSException;
+
+   /**
+    * Create a new <tt>ServerSessionPool</tt>.
+    * 
+    * @param destination the destination
+    * @param con the jms connection
+    * @param minSession the minimum number of sessions
+    * @param maxSession the maximum number of sessions
+    * @param keepAlive the time to keep sessions alive
+    * @param isTransacted whether the pool is transacted
+    * @param ack the acknowledegement method
+    * @param listener the listener
+    * @param useLocalTX whether to use local transactions
+    * @param lazy whether the pool is lazily initialized
+    * @param recycle whether or not idle sessions are recycled
+    * @param idleTimeout the time between runs of the reaper thread
+    * @return A new pool.
+    * @throws JMSException for any error
+    */
+   ServerSessionPool getServerSessionPool(Destination destination, Connection con, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack,
+         boolean useLocalTX, boolean lazy, boolean recycle, long idleTimeout, boolean destroyOnError, String supportCodeUrl, String sorterClassName, boolean validateLinkedExcpetion, MessageListener listener) throws JMSException;
+
+
 }
\ No newline at end of file

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java	2006-12-07 22:00:20 UTC (rev 58912)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java	2006-12-07 22:00:38 UTC (rev 58913)
@@ -1,30 +1,14 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.jms.asf;
 
 import javax.management.ObjectName;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
-
 import org.jboss.util.naming.NonSerializableFactory;
 import org.jboss.system.ServiceMBeanSupport;
 import org.jboss.tm.XidFactoryMBean;
@@ -32,12 +16,17 @@
 /**
  * A loader for <tt>ServerSessionPools</tt>.
  *
+ * <p>Created: Wed Nov 29 16:14:46 2000
+ *
  * @author <a href="mailto:peter.antman at tim.se">Peter Antman</a>.
  * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
+ *
+ * @jmx.mbean extends="org.jboss.system.ServiceMBean"
  */
-public class ServerSessionPoolLoader extends ServiceMBeanSupport implements ServerSessionPoolLoaderMBean
+public class ServerSessionPoolLoader
+   extends ServiceMBeanSupport
+   implements ServerSessionPoolLoaderMBean
 {
    /** The factory used to create server session pools. */
    private ServerSessionPoolFactory poolFactory;
@@ -50,88 +39,138 @@
 
    private ObjectName xidFactory;
 
+   /**
+    * Set the pool name.
+    *
+    * @param name    The pool name.
+    *
+    * @jmx:managed-attribute
+    */
    public void setPoolName(final String name)
    {
       this.name = name;
    }
-
+   
+   /**
+    * Get the pool name.
+    *
+    * @return    The pool name.
+    *
+    * @jmx:managed-attribute
+    */
    public String getPoolName()
    {
       return name;
    }
 
+   /**
+    * Set the classname of pool factory to use.
+    *
+    * @param classname    The name of the pool factory class.
+    *
+    * @jmx:managed-attribute
+    */
    public void setPoolFactoryClass(final String classname)
    {
       this.poolFactoryClass = classname;
    }
 
+   /**
+    * Get the classname of pool factory to use.
+    *
+    * @return    The name of the pool factory class.
+    *
+    * @jmx:managed-attribute
+    */
    public String getPoolFactoryClass()
    {
       return poolFactoryClass;
    }
 
+   
+   
+   /**
+    * mbean get-set pair for field xidFactory
+    * Get the value of xidFactory
+    * @return value of xidFactory
+    *
+    * @jmx:managed-attribute
+    */
    public ObjectName getXidFactory()
    {
       return xidFactory;
    }
-
+   
+   
+   /**
+    * Set the value of xidFactory
+    * @param xidFactory  Value to assign to xidFactory
+    *
+    * @jmx:managed-attribute
+    */
    public void setXidFactory(final ObjectName xidFactory)
    {
       this.xidFactory = xidFactory;
    }
+   
+   
 
+
+   /**
+    * Start the service.
+    *
+    * <p>Bind the pool factory into JNDI.
+    *
+    * @throws Exception
+    */
    protected void startService() throws Exception
    {
-      XidFactoryMBean xidFactoryObj = (XidFactoryMBean) getServer().getAttribute(xidFactory, "Instance");
+      XidFactoryMBean xidFactoryObj = (XidFactoryMBean)getServer().getAttribute(xidFactory, "Instance");
 
       Class cls = Class.forName(poolFactoryClass);
-      poolFactory = (ServerSessionPoolFactory) cls.newInstance();
+      poolFactory = (ServerSessionPoolFactory)cls.newInstance();
       poolFactory.setName(name);
       poolFactory.setXidFactory(xidFactoryObj);
-      log.debug("initialized with pool factory: " + poolFactory);
 
+      if (log.isDebugEnabled())
+         log.debug("initialized with pool factory: " + poolFactory);
       InitialContext ctx = new InitialContext();
       String name = poolFactory.getName();
       String jndiname = "java:/" + name;
-      try
-      {
+      try {
          NonSerializableFactory.rebind(ctx, jndiname, poolFactory);
-         log.debug("pool factory " + name + " bound to " + jndiname);
+         log.debug("pool factory " + name + " bound to "  + jndiname);
       }
-      finally
-      {
+      finally {
          ctx.close();
       }
    }
 
+   /**
+    * Stop the service.
+    *
+    * <p>Unbind from JNDI.
+    */
    protected void stopService()
    {
       // Unbind from JNDI
       InitialContext ctx = null;
-      try
-      {
+      try {
          ctx = new InitialContext();
          String name = poolFactory.getName();
          String jndiname = "java:/" + name;
-
+         
          ctx.unbind(jndiname);
          NonSerializableFactory.unbind(jndiname);
          log.debug("pool factory " + name + " unbound from " + jndiname);
       }
-      catch (NamingException ignore)
-      {
-      }
-      finally
-      {
-         if (ctx != null)
-         {
-            try
-            {
+      catch (NamingException ignore) {}
+      finally {
+         if (ctx != null) {
+            try {
                ctx.close();
             }
-            catch (NamingException ignore)
-            {
-            }
+            catch (NamingException ignore) {}
          }
       }
    }

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java	2006-12-07 22:00:20 UTC (rev 58912)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java	2006-12-07 22:00:38 UTC (rev 58913)
@@ -1,75 +1,52 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.jms.asf;
 
-import javax.management.ObjectName;
-
 /**
  * MBean interface.
- * 
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
+ * @author <a href="mailto:weston.price at jboss.com>Weston Price</a>
  */
 public interface ServerSessionPoolLoaderMBean extends org.jboss.system.ServiceMBean
 {
+
    /**
     * Set the pool name.
-    * 
     * @param name The pool name.
     */
-   void setPoolName(String name);
+   void setPoolName(java.lang.String name);
 
    /**
     * Get the pool name.
-    * 
     * @return The pool name.
     */
-   String getPoolName();
+   java.lang.String getPoolName();
 
    /**
     * Set the classname of pool factory to use.
-    * 
     * @param classname The name of the pool factory class.
     */
-   void setPoolFactoryClass(String classname);
+   void setPoolFactoryClass(java.lang.String classname);
 
    /**
     * Get the classname of pool factory to use.
-    * 
     * @return The name of the pool factory class.
     */
-   String getPoolFactoryClass();
+   java.lang.String getPoolFactoryClass();
 
    /**
     * mbean get-set pair for field xidFactory Get the value of xidFactory
-    * 
     * @return value of xidFactory
     */
-   ObjectName getXidFactory();
+   javax.management.ObjectName getXidFactory();
 
    /**
     * Set the value of xidFactory
-    * 
     * @param xidFactory Value to assign to xidFactory
     */
-   void setXidFactory(ObjectName xidFactory);
+   void setXidFactory(javax.management.ObjectName xidFactory);
+
 }

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java	2006-12-07 22:00:20 UTC (rev 58912)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java	2006-12-07 22:00:38 UTC (rev 58913)
@@ -1,23 +1,8 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.jms.asf;
 
@@ -33,6 +18,7 @@
 import javax.transaction.TransactionManager;
 import javax.transaction.xa.XAResource;
 import javax.transaction.xa.Xid;
+
 import org.jboss.logging.Logger;
 import org.jboss.tm.TransactionManagerService;
 import org.jboss.tm.XidFactoryMBean;
@@ -40,68 +26,75 @@
 /**
  * An implementation of ServerSession. <p>
  *
- * @author <a href="mailto:peter.antman at tim.se">Peter Antman</a> .
- * @author <a href="mailto:jason at planet57.com">Jason Dillon</a>
- * @author <a href="mailto:hiram.chirino at jboss.org">Hiram Chirino</a> .
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
- * @version $Revision$
+ * Created: Thu Dec 7 18:25:40 2000
+ *
+ * @author    <a href="mailto:peter.antman at tim.se">Peter Antman</a> .
+ * @author    <a href="mailto:jason at planet57.com">Jason Dillon</a>
+ * @author    <a href="mailto:hiram.chirino at jboss.org">Hiram Chirino</a> .
+ * @author    <a href="mailto:weston.price at jboss.com>Weston Price</a>
+ * @version   $Revision$
  */
-public class StdServerSession implements Runnable, ServerSession, MessageListener
+public class StdServerSession
+   implements Runnable, ServerSession, MessageListener
 {
-   /** Instance logger. */
+   /**
+    * Instance logger.
+    */
    static Logger log = Logger.getLogger(StdServerSession.class);
-
-   /** The server session pool which we belong to. */
+   
+   /**
+    * The server session pool which we belong to.
+    */
    private StdServerSessionPool serverSessionPool;
-
-   /** Our session resource. */
+   
+   /**
+    * Our session resource.
+    */
    private Session session;
-
-   /** Our XA session resource. */
+   
+   /**
+    * Our XA session resource.
+    */
    private XASession xaSession;
-
-   /** The transaction manager that we will use for transactions. */
+   
+   /**
+    * The transaction manager that we will use for transactions.
+    */
    private TransactionManager tm;
-
+   
    /**
     * Use the session's XAResource directly if we have an JBossMQ XASession.
     * this allows us to get around the TX timeout problem when you have
     * extensive message processing.
     */
    private boolean useLocalTX;
-
-   /** The listener to delegate calls, to. In our case the container invoker. */
+   
+   /**
+    * The listener to delegate calls, to. In our case the container invoker.
+    */
    private MessageListener delegateListener;
 
    private XidFactoryMBean xidFactory;
-
+   
+   private long lastUse;
+   
+   private boolean hasPermit;
+   
+   private boolean hasError = false;
+   
+   private JMSExceptionSorter sorter;
+   
+   
    /**
-    * @deprecated 
-    * @todo these appeared in jboss-head where are they used?
-    */
-   public TransactionManager getTransactionManager()
-   {
-      return tm;
-   }
-
-   /**
-    * @deprecated 
-    * @todo these appeared in jboss-head where are they used?
-    */
-   public void setTransactionManager(TransactionManager transactionManager)
-   {
-      this.tm = transactionManager;
-   }
-
-   /**
     * Create a <tt>StdServerSession</tt> .
     *
-    * @param pool             The server session pool which we belong to.
-    * @param session          Our session resource.
-    * @param xaSession        Our XA session resource.
-    * @param delegateListener Listener to call when messages arrives.
+    * @param pool              The server session pool which we belong to.
+    * @param session           Our session resource.
+    * @param xaSession         Our XA session resource.
+    * @param delegateListener  Listener to call when messages arrives.
     * @param useLocalTX       Will this session be used in a global TX (we can optimize with 1 phase commit)
-    * @throws JMSException Transation manager was not found.
+    * @throws JMSException     Transation manager was not found.
+    * @exception JMSException  Description of Exception
     */
    StdServerSession(final StdServerSessionPool pool,
                     final Session session,
@@ -109,74 +102,86 @@
                     final MessageListener delegateListener,
                     boolean useLocalTX,
                     final XidFactoryMBean xidFactory,
-                    final TransactionManager tm)
-           throws JMSException
+                    final JMSExceptionSorter sorter)
+      throws JMSException
    {
+
+      
       this.serverSessionPool = pool;
       this.session = session;
       this.xaSession = xaSession;
       this.delegateListener = delegateListener;
-      if (xaSession == null)
+      
+      if(xaSession == null)
          useLocalTX = false;
+      
       this.useLocalTX = useLocalTX;
-      this.xidFactory = xidFactory;
-      this.tm = tm;
-
-      log.debug("initializing (pool, session, xaSession, useLocalTX): " +
-                pool + ", " + session + ", " + xaSession + ", " + useLocalTX);
-
-      // Set out self as message listener
-      if (xaSession != null)
+      this.xidFactory = xidFactory;      
+      this.sorter = sorter;
+      
+      if (log.isDebugEnabled())
+         log.debug("initializing (pool, session, xaSession, useLocalTX): " +
+            pool + ", " + session + ", " + xaSession + ", " + useLocalTX);
+      
+      if (StdServerSessionPool.USE_OLD && xaSession != null)
+      {
          xaSession.setMessageListener(this);
+         
+      }
       else
-         session.setMessageListener(this);
-
-      if (tm == null)
       {
-         InitialContext ctx = null;
-         try
+         session.setMessageListener(this);         
+      }
+      
+      InitialContext ctx = null;
+            
+      try
+      {
+        
+        ctx = new InitialContext();
+        tm = (TransactionManager) ctx.lookup(TransactionManagerService.JNDI_NAME);
+        lastUse = System.currentTimeMillis(); 
+        
+      }
+      catch (Exception e)
+      {
+         throw new JMSException("Transation manager was not found");
+      }
+     
+      finally
+      {
+         if (ctx != null)
          {
-            ctx = new InitialContext();
-            this.tm = (TransactionManager) ctx.lookup(TransactionManagerService.JNDI_NAME);
-         }
-         catch (Exception e)
-         {
-            throw new JMSException("Transation manager was not found");
-         }
-         finally
-         {
-            if (ctx != null)
+            try
             {
-               try
-               {
-                  ctx.close();
-               }
-               catch (Exception ignore)
-               {
-               }
+               ctx.close();
             }
+            catch (Exception ignore)
+            {
+            }
          }
       }
    }
-
+   
+   
    /**
     * Returns the session. <p>
-    * <p/>
+    *
     * This simply returns what it has fetched from the connection. It is up to
     * the jms provider to typecast it and have a private API to stuff messages
     * into it.
     *
-    * @return The session.
-    * @throws JMSException Description of Exception
+    * @return                  The session.
+    * @exception JMSException  Description of Exception
     */
    public Session getSession() throws JMSException
    {
-      if (xaSession != null)
+      if (StdServerSessionPool.USE_OLD && xaSession != null)
          return xaSession;
       else
          return session;
    }
-
+   
    /**
     * Runs in an own thread, basically calls the session.run(), it is up to the
     * session to have been filled with messages and it will run against the
@@ -186,30 +191,61 @@
    public void run()
    {
       boolean trace = log.isTraceEnabled();
+      
       if (trace)
-         log.trace("running...");
+         log.trace("Running StdServerSession" + this);
+      
+      TransactionDemarcationStrategy td = null;
+      
+      
+      if (StdServerSessionPool.USE_OLD == false)
+      {
+         td = createTransactionDemarcation();
+         
+         if (td == null)
+            return;
+      }
+
       try
       {
-         if (xaSession != null)
+
+         if (StdServerSessionPool.USE_OLD && xaSession != null)
+         {
             xaSession.run();
+            
+         }      
          else
+         {
             session.run();
+            
+         }
+
+      }catch(Throwable t)
+      {
+         
+         if (td != null)
+         {
+            td.error();
+            
+         }
+         
+         handleSessionFailure(t);
+         
       }
       finally
       {
-         if (trace)
-            log.trace("recycling...");
-
+         if(td != null)
+         {
+            td.end();
+            
+         }                        
          recycle();
-
-         if (trace)
-            log.trace("finished run");
       }
    }
 
    /**
     * Will get called from session for each message stuffed into it.
-    * <p/>
+    *
     * Starts a transaction with the TransactionManager
     * and enlists the XAResource of the JMS XASession if a XASession was
     * available. A good JMS implementation should provide the XASession for use
@@ -220,107 +256,324 @@
     * not be too common (JBossMQ provides XASessions).
     */
    public void onMessage(Message msg)
-   {
+   {      
       boolean trace = log.isTraceEnabled();
-      if (trace)
+      
+      if( trace )
          log.trace("onMessage running (pool, session, xaSession, useLocalTX): " +
-                   ", " + session + ", " + xaSession + ", " + useLocalTX);
-
-      // Used if run with useLocalTX if true
-      Xid localXid = null;
-      boolean localRollbackFlag = false;
-      // Used if run with useLocalTX if false
-      Transaction trans = null;
+         ", " + session + ", " + xaSession + ", " + useLocalTX);
+      
+      TransactionDemarcationStrategy td = null;
+      
+      if (StdServerSessionPool.USE_OLD)
+      {
+         td = createTransactionDemarcation();
+         if (td == null)
+            return;
+      }
+      
       try
       {
+         delegateListener.onMessage(msg);
+         
+      }catch(Throwable t)
+      {
+         log.error("Unexpected error invoking on message " + msg, t);
+         
+         if(td != null)
+            td.error();
+         
+      }
+      finally
+      {
+         if(td != null)
+            td.end();
+      }
+    
+      
+     
+      if( trace )
+         log.trace("onMessage done");
+   }
 
-         if (useLocalTX)
+   /**
+    * Start the session and begin consuming messages.
+    *
+    * @throws JMSException  No listener has been specified.
+    */
+   public void start() throws JMSException
+   {
+      log.trace("starting invokes on server session");
+      
+      if (session != null)
+      {
+         try
          {
-            // Use JBossMQ One Phase Commit to commit the TX
-            localXid = xidFactory.newXid();//new XidImpl();
-            XAResource res = xaSession.getXAResource();
-            res.start(localXid, XAResource.TMNOFLAGS);
+            serverSessionPool.getExecutor().execute(this);
+         }
+         catch (InterruptedException ignore)
+         {
+         }
+      }
+      else
+      {
+         throw new JMSException("No listener has been specified");
+      }
+   }
 
-            if (trace)
-               log.trace("Using optimized 1p commit to control TX.");
+   /**
+    * Called by the ServerSessionPool when the sessions should be closed.
+    */
+   void close()
+   {
+      if (session != null)
+      {
+         try
+         {
+            session.close();
          }
-         else
+         catch (Exception ignore)
          {
+         }
 
-            // Use the TM to control the TX
-            tm.begin();
-            trans = tm.getTransaction();
+         session = null;
+      }
 
-            if (xaSession != null)
+      if (xaSession != null)
+      {
+         try
+         {
+            xaSession.close();
+         }
+         catch (Exception ignore)
+         {
+         }
+         xaSession = null;
+      }
+
+      log.debug("closed");
+   }
+   
+   /**
+    * This method is called by the ServerSessionPool when it is ready to be
+    * recycled intot the pool
+    */
+   void recycle()
+   {
+      serverSessionPool.recycle(this, false);
+   }
+   
+   boolean getHasError()
+   {
+      return hasError;
+      
+   }
+   void setHasError(boolean destroy)
+   {
+      this.hasError = destroy;
+   }
+   
+   boolean isTimedOut(long timeout)
+   {
+      return this.lastUse < timeout;
+   }
+   
+   void setLastUsed(long lastUsed)
+   {
+      this.lastUse = lastUsed;
+   }
+   
+   public void setHasPermit(boolean permit)
+   {
+	   this.hasPermit = permit;
+   }
+
+   public boolean getHasPermit()
+   {
+	   return this.hasPermit;
+   }
+
+   private TransactionDemarcationStrategy createTransactionDemarcation()
+   {      
+      return new DemarcationStrategyFactory().getStrategy();      
+   }
+   
+   private void handleSessionFailure(final Throwable t)
+   {
+      if(t instanceof JMSException)
+      {
+         JMSException jmex = (JMSException)t;
+         
+         if(log.isTraceEnabled())
+         {
+            log.trace("JMSException thrown in: " + this + "  ", jmex);
+            log.trace("JMSException error code: " + jmex.getErrorCode());
+            
+            Exception linked = jmex.getLinkedException();
+            
+            if(linked != null)
             {
-               XAResource res = xaSession.getXAResource();
-               if (!trans.enlistResource(res))
+               log.trace("JMSLinkedException is ", jmex);
+            
+               if(linked instanceof JMSException)
                {
-                  throw new JMSException("could not enlist resource");
+                  JMSException linkedex = (JMSException)linked;
+                  log.trace("Linked JMSException error code: " + linkedex.getErrorCode());
                }
-               if (trace)
-                  log.trace("XAResource '" + res + "' enlisted.");
             }
+                        
          }
-         // Call delegate listener
-         delegateListener.onMessage(msg);
+         
+         if(sorter != null)
+         {
+            setHasError(sorter.isJMSExceptionFatal(jmex));               
+         }
+                     
       }
-      catch (Exception e)
+   }
+
+   
+   private interface TransactionDemarcationStrategy
+   {
+      void error();
+      void end();
+      
+   }
+   
+   private class DemarcationStrategyFactory
+   {
+      
+      public DemarcationStrategyFactory()
       {
-         log.error("session failed to run; setting rollback only", e);
+      }
 
-         if (useLocalTX)
+      TransactionDemarcationStrategy getStrategy()
+      {         
+         try
          {
-            // Use JBossMQ One Phase Commit to commit the TX
-            localRollbackFlag = true;
+            return new TransactionDemarcation();
          }
+         catch (Throwable t)
+         {
+            log.error(this + " error creating transaction demarcation ", t);
+            return null;
+         }
+      }
+   
+   }
+   private class TransactionDemarcation implements TransactionDemarcationStrategy
+   {     
+      boolean trace = log.isTraceEnabled();
+
+      Xid localXid = null;
+      boolean localRollbackFlag = false;
+      Transaction trans = null;
+      
+      public TransactionDemarcation() throws Throwable
+      {            
+            if(useLocalTX)
+            {
+               localXid = xidFactory.newXid();
+               XAResource res = xaSession.getXAResource();
+               res.start(localXid, XAResource.TMNOFLAGS);
+               
+               if(trace)
+                 log.trace(StdServerSession.this + " using optimized 1p commit to control Tx. xid=" + localXid);
+            }
+            else
+            {
+               tm.begin();
+
+               try
+               {
+                  trans = tm.getTransaction();
+
+                  if (trace)
+                     log.trace(StdServerSession.this + " using tx=" + trans);
+
+                  if (xaSession != null)
+                  {
+                     XAResource res = xaSession.getXAResource();
+
+                     if (!trans.enlistResource(res))
+                     {
+                        throw new JMSException("could not enlist resource");
+                     }
+                     if (trace)
+                        log.trace(StdServerSession.this + " XAResource '" + res + "' enlisted.");
+                  }
+               }
+               catch (Throwable t)
+               {
+                  try
+                  {
+                     tm.rollback();
+                  }
+                  catch (Throwable ignored)
+                  {
+                     log.trace(StdServerSession.this + " ignored error rolling back after failed enlist", ignored);
+                  }
+                  throw t;
+               }
+            }            
+
+       }
+         
+      
+      public void error()
+      {
+         if(useLocalTX)
+         {
+            localRollbackFlag = true;           
+         }
          else
          {
-            // Mark for tollback TX via TM
             try
             {
-               // The transaction will be rolledback in the finally
+
                if (trace)
-                  log.trace("Using TM to mark TX for rollback.");
+                  log.trace(StdServerSession.this + " using TM to mark TX for rollback tx=" + trans);               
                trans.setRollbackOnly();
             }
-            catch (Exception x)
+            catch (Throwable t)
             {
-               log.error("failed to set rollback only", x);
+               handleSessionFailure(t);
+               log.error(StdServerSession.this + " failed to set rollback only", t);
             }
+            
          }
-
+         
       }
-      finally
+      
+      public void end()
       {
+         
          try
          {
-            if (useLocalTX)
+
+            if(useLocalTX)
             {
-               if (localRollbackFlag == true)
+               if(localRollbackFlag)
                {
-                  if (trace)
-                     log.trace("Using optimized 1p commit to rollback TX.");
-
                   XAResource res = xaSession.getXAResource();
                   res.end(localXid, XAResource.TMSUCCESS);
-                  res.rollback(localXid);
-
+                  res.rollback(localXid);                  
                }
                else
                {
-                  if (trace)
-                     log.trace("Using optimized 1p commit to commit TX.");
-
                   XAResource res = xaSession.getXAResource();
                   res.end(localXid, XAResource.TMSUCCESS);
                   res.commit(localXid, true);
+                  
                }
+            
             }
             else
             {
+               
                // Use the TM to commit the Tx (assert the correct association) 
                Transaction currentTx = tm.getTransaction();
+               
                if (trans.equals(currentTx) == false)
                   throw new IllegalStateException("Wrong tx association: expected " + trans + " was " + currentTx);
 
@@ -328,7 +581,7 @@
                if (trans.getStatus() == Status.STATUS_MARKED_ROLLBACK)
                {
                   if (trace)
-                     log.trace("Rolling back JMS transaction");
+                     log.trace(StdServerSession.this + " rolling back JMS transaction tx=" + trans);
                   // actually roll it back
                   tm.rollback();
 
@@ -347,7 +600,7 @@
                   // a) everything goes well
                   // b) app. exception was thrown
                   if (trace)
-                     log.trace("Commiting the JMS transaction");
+                     log.trace(StdServerSession.this + " commiting the JMS transaction tx=" + trans);
                   tm.commit();
 
                   // NO XASession? then manually commit.  This is not so good but
@@ -359,92 +612,24 @@
                }
                else
                {
-                  if(trace)
-                     log.trace(StdServerSession.this + "transaction already ended");
-                  
                   tm.suspend();
-                  
+                
                   if (xaSession == null && serverSessionPool.isTransacted())
                   {
-                     session.rollback();
+                     session.commit();
                   }
-                  
                }
+               
             }
+                  
+         
          }
-         catch (Exception e)
+         catch(Throwable t)
          {
-            log.error("failed to commit/rollback", e);
+            log.error(StdServerSession.this + "failed to commit/rollback", t);            
+            handleSessionFailure(t);
          }
       }
-      if (trace)
-         log.trace("onMessage done");
    }
+}
 
-   /**
-    * Start the session and begin consuming messages.
-    *
-    * @throws JMSException No listener has been specified.
-    */
-   public void start() throws JMSException
-   {
-      log.trace("starting invokes on server session");
-
-      if (session != null)
-      {
-         try
-         {
-            serverSessionPool.getExecutor().execute(this);
-         }
-         catch (InterruptedException ignore)
-         {
-         }
-      }
-      else
-      {
-         throw new JMSException("No listener has been specified");
-      }
-   }
-
-   /**
-    * Called by the ServerSessionPool when the sessions should be closed.
-    */
-   void close()
-   {
-      if (session != null)
-      {
-         try
-         {
-            session.close();
-         }
-         catch (Exception ignore)
-         {
-         }
-
-         session = null;
-      }
-
-      if (xaSession != null)
-      {
-         try
-         {
-            xaSession.close();
-         }
-         catch (Exception ignore)
-         {
-         }
-         xaSession = null;
-      }
-
-      log.debug("closed");
-   }
-
-   /**
-    * This method is called by the ServerSessionPool when it is ready to be
-    * recycled intot the pool
-    */
-   void recycle()
-   {
-      serverSessionPool.recycle(this);
-   }
-}

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java	2006-12-07 22:00:20 UTC (rev 58912)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java	2006-12-07 22:00:38 UTC (rev 58913)
@@ -1,26 +1,12 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.jms.asf;
-
+import java.security.AccessController;
+import java.security.PrivilegedAction;
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
@@ -41,78 +27,213 @@
 import javax.jms.XASession;
 import javax.jms.XATopicConnection;
 import javax.jms.XATopicSession;
-import javax.transaction.TransactionManager;
 
 import org.jboss.logging.Logger;
 import org.jboss.tm.XidFactoryMBean;
 
 import EDU.oswego.cs.dl.util.concurrent.Executor;
+import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
 import EDU.oswego.cs.dl.util.concurrent.PooledExecutor;
 import EDU.oswego.cs.dl.util.concurrent.ThreadFactory;
 
 /**
- * Implementation of ServerSessionPool.
+ * Implementation of ServerSessionPool. <p>
  *
+ * Created: Thu Dec 7 17:02:03 2000
+ *
  * @author    <a href="mailto:peter.antman at tim.se">Peter Antman</a> .
  * @author    <a href="mailto:hiram.chirino at jboss.org">Hiram Chirino</a> .
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
+ * @author    <a href="mailto:weston.price at jboss.com>Weston Price</a>
  * @version   $Revision$
  */
-public class StdServerSessionPool implements ServerSessionPool
+public class StdServerSessionPool
+       implements ServerSessionPool
 {
-   /** The thread group which session workers will run. */
-   private static ThreadGroup threadGroup = new ThreadGroup("ASF Session Pool Threads");
+   public static final boolean USE_OLD;
+   
+   static
+   {
+      USE_OLD = ((Boolean) AccessController.doPrivileged(new PrivilegedAction()
+      {
+         public Object run()
+         {
+            return new Boolean(System.getProperty("org.jboss.jms.asf.useold", "false"));
+         }
+      })).booleanValue();
+   }
+   /**
+    * The thread group which session workers will run.
+    */
+   private static ThreadGroup threadGroup =
+         new ThreadGroup("ASF Session Pool Threads");
 
-   /** Instance logger. */
+   /**
+    * Instance logger.
+    */
    private final Logger log = Logger.getLogger(this.getClass());
 
    /** The minimum size of the pool */
    private int minSize;
 
-   /** The size of the pool. */
+   /**
+    * The size of the pool.
+    */
    private int poolSize;
 
-   /** The message acknowledgment mode. */
+   /** How long to keep sessions alive */
+   private long keepAlive;
+
+   /**
+    * The message acknowledgment mode.
+    */
    private int ack;
 
-   /** Is the bean container managed? */
+   /**
+    * Is the bean container managed?
+    */
    private boolean useLocalTX;
 
-   /** True if this is a transacted session. */
+   /**
+    * True if this is a transacted session.
+    */
    private boolean transacted;
-
-   /** The destination. */
+   
+   /** The lazyInitialization */
+   private boolean lazyInitialization;
+   
+   /** The recycleIdleSessions */
+   private boolean recycleIdleSessions;
+   
+   /** The idleTimeOut */
+   private long idleTimeOut;
+   
+   /**
+    * The destination.
+    */
    private Destination destination;
 
-   /** The session connection. */
+   /**
+    * The session connection.
+    */
    private Connection con;
 
-   /** The message listener for the session. */
+   /**
+    * The message listener for the session.
+    */
    private MessageListener listener;
 
-   /** The list of ServerSessions. */
+   /**
+    * The list of ServerSessions.
+    */
    private List sessionPool;
 
-   /** The executor for processing messages? */
+   /**
+    * The executor for processing messages?
+    */
    private PooledExecutor executor;
 
-   /** Used to signal when the Pool is being closed down */
+   /**
+    * Used to signal when the Pool is being closed down
+    */
    private boolean closing = false;
-
-   /** Used during close down to wait for all server sessions to be returned and closed. */
+   
+   /**
+    * Used during close down to wait for all server sessions to be returned and
+    * closed.
+    */
    private int numServerSessions = 0;
-
+   
+   private boolean destroyOnError = false;
+   
+   private JMSExceptionSorter sorter;
+   
    private XidFactoryMBean xidFactory;
+   
+   private FIFOSemaphore permits;
+      
+   private SessionPoolStatisticsCollector counter = new SessionPoolStatisticsCollector();
+   
+   private JMSSupportCodeHandler handler;
+   
+   private String supportCodeUrl;
+   
+   private String sorterClassName;
+   
+   public StdServerSessionPool(final Destination destination, 
+                           final Connection con, 
+                           final boolean transacted, 
+                           final int ack, 
+                           final boolean useLocalTx, 
+                           final MessageListener listener, 
+                           final int minSession,
+                           final int maxSession,
+                           final long keepAlive,
+                           final boolean lazy,
+                           final boolean recycle,
+                           final long idleTimeout,
+                           final boolean destroyOnError,
+                           final String supportCodeUrl,
+                           final String sorterClassName,
+                           final boolean validateLinkedException,
+                           final XidFactoryMBean xidFactory) throws JMSException
+   {
+      
+      this.destination = destination;
+      this.con = con;
+      this.ack = ack;
+      this.listener = listener;
+      this.transacted = transacted;
+      this.minSize = minSession;
+      this.poolSize = maxSession;
+      this.keepAlive = keepAlive;
+      this.sessionPool = new ArrayList(maxSession);
+      this.useLocalTX = useLocalTx;
+      this.xidFactory = xidFactory;
+      
+      // setup the worker pool
+      executor = new MyPooledExecutor(poolSize);
+      executor.setMinimumPoolSize(minSize);
+      executor.setKeepAliveTime(keepAlive);
+      executor.waitWhenBlocked();
+      executor.setThreadFactory(new DefaultThreadFactory());
+      
+      permits = new FIFOSemaphore(maxSession);
+      
+      this.lazyInitialization = lazy;
+      this.recycleIdleSessions = recycle;
+      this.idleTimeOut = idleTimeout;
+      this.destroyOnError = destroyOnError;
+      // finish initializing the session
+      if(!lazyInitialization)
+      {
+         log.debug("StdServerSessionPool is configured for non-lazy inititalization. " + poolSize + " sessions being created for use." );
+         create(this.poolSize);         
 
-   private TransactionManager tm;
-
+      }else
+      {
+         log.debug("StdServerSessionPool is specified as lazy initialization. " + poolSize + " session(s) being created");
+         create(this.minSize);
+      }
+      
+      if(recycleIdleSessions)
+      {
+         log.debug("Session Pool registering for background recycling at interval" +  idleTimeout);
+         JmsServerSessionReaper.registerSessionPool(this, idleTimeOut);
+         
+      }
+      
+      this.supportCodeUrl = supportCodeUrl;
+      this.sorterClassName = sorterClassName;
+      
+      handler = new JMSSupportCodeHandler(supportCodeUrl, sorterClassName, validateLinkedException);
+      
+      log.debug("Server Session pool set up");
+      
+      
+   }
    /**
-    * Construct a <tt>StdServerSessionPool</tt>. Note the maxSession parameter controls
-    * both the maximum number of sessions in the pool, as well as the number of listener 
-    * threads assigned to service requests from the JMS Provider. 
-    * 
-    * 
-    * 
+    * Construct a <tt>StdServerSessionPool</tt> using the default pool size.
+    *
     * @param destination the destination
     * @param con connection to get sessions from
     * @param transacted transaction mode when not XA (
@@ -121,8 +242,7 @@
     * @param minSession minumum number of sessions in the pool
     * @param maxSession maximum number of sessions in the pool
     * @param keepAlive the time to keep sessions alive
-    * @param xidFactory  the xid factory
-    * @param tm the transaction manager
+    * @param xidFactory  Description of Parameter
     * @exception JMSException    Description of Exception
     */
    public StdServerSessionPool(final Destination destination,
@@ -134,8 +254,7 @@
                                final int minSession,
                                final int maxSession,
                                final long keepAlive,
-                               final XidFactoryMBean xidFactory,
-                               final TransactionManager tm)
+                               final XidFactoryMBean xidFactory)
       throws JMSException
    {
       this.destination = destination;
@@ -145,10 +264,10 @@
       this.transacted = transacted;
       this.minSize = minSession;
       this.poolSize = maxSession;
+      this.keepAlive = keepAlive;
       this.sessionPool = new ArrayList(maxSession);
       this.useLocalTX = useLocalTX;
       this.xidFactory = xidFactory;
-      this.tm = tm;
       // setup the worker pool
       executor = new MyPooledExecutor(poolSize);
       executor.setMinimumPoolSize(minSize);
@@ -157,10 +276,12 @@
       executor.setThreadFactory(new DefaultThreadFactory());
 
       // finish initializing the session
-      create();
+      create(this.poolSize);
       log.debug("Server Session pool set up");
    }
 
+   // --- JMS API for ServerSessionPool
+
    /**
     * Get a server session.
     *
@@ -175,6 +296,9 @@
 
       try
       {
+    	 //Note, we will block until we get a new one to keep old behavior
+    	 permits.acquire();
+    	 
          while (true)
          {
             synchronized (sessionPool)
@@ -186,17 +310,17 @@
                else if (sessionPool.size() > 0)
                {
                   session = (ServerSession)sessionPool.remove(0);
+                  ((StdServerSession)session).setHasPermit(true);
+                  counter.inUse();
                   break;
                }
                else
                {
-                  try
-                  {
-                     sessionPool.wait();
-                  }
-                  catch (InterruptedException ignore)
-                  {
-                  }
+            	  log.trace("Creating lazy session.");
+            	  session = createLazySession();
+            	  ((StdServerSession)session).setHasPermit(true);
+                  counter.inUse();
+                  break;
                }
             }
          }
@@ -208,9 +332,13 @@
 
       if( log.isTraceEnabled() )
          log.trace("using server session: " + session);
+      
+      int size = (int)(poolSize - permits.permits());
+      counter.maxSessionInUse(size);
       return session;
    }
-
+   
+     
    /**
     * Clear the pool, clear out both threads and ServerSessions,
     * connection.stop() should be run before this method.
@@ -225,7 +353,11 @@
          // ThreadPool won't leave any more threads out.
          closing = true;
 
-         log.debug("Clearing " + sessionPool.size() + " from ServerSessionPool");
+         if (log.isDebugEnabled())
+         {
+            log.debug("Clearing " + sessionPool.size() +
+                  " from ServerSessionPool");
+         }
 
          Iterator iter = sessionPool.iterator();
          while (iter.hasNext())
@@ -239,6 +371,9 @@
          sessionPool.clear();
          sessionPool.notifyAll();
       }
+      
+      //Unregister with the Reaper
+      JmsServerSessionReaper.unregisterSessionPool(this);
 
       //Must be outside synchronized block because of recycle method.
       executor.shutdownAfterProcessingCurrentlyQueuedTasks();
@@ -258,7 +393,7 @@
          }
       }
    }
-
+   
    /**
     * Get the executor we are using.
     *
@@ -268,7 +403,45 @@
    {
       return executor;
    }
+   
+   public int getTimedOut()
+   {
+      return counter.getTimedOutCount();
+   }
 
+   public int getCurrentSessionCount()
+   {
+      return numServerSessions;
+   }
+   
+   public int getCurrentSessionInUseCount()
+   {
+      return counter.getInUseCount();
+   }
+   
+   public int getSessionMaxInUseCount()
+   {
+      return counter.getMaxSessionInUse();
+   }
+   
+   public int getSessionErrorCount()
+   {
+      return counter.getSessionErrorCount();
+      
+   }
+   
+   public int getSessionCreatedCount()
+   {      
+      return counter.getTotalSessionCreated();
+   
+   }
+   
+   public int getSessionDestroyedCount()
+   {
+      return counter.getSessionDestroyedCount();
+      
+   }
+
    // --- Protected messages for StdServerSession to use
 
    /**
@@ -280,45 +453,189 @@
    {
       return transacted;
    }
+   
+   public void fillToMin() throws JMSException
+   {
+	  
+	  try
+	  {
+	      permits.acquire();
+		  
+	      synchronized (sessionPool)
+	      {
+	    	  if(numServerSessions < minSize)
+	    		  create(minSize);
+	      
+	      }
+		  
+	  }catch(InterruptedException e)
+	  {
+		  log.debug("Interrupted exception in attemping to fill JMS Session pool to minimum allowance.", e);
+	  }
 
+      finally
+	  {
+		 permits.release();
+	  }
+   
+   }
+   
+   public void refreshSupportCodeFile()
+   {
+      handler.reloadSupportFile();
+      
+   }
+
+   public void loadSupportCodeFile(String fileName)
+   {      
+    
+      handler.reloadSupportFile(fileName);      
+   }
+   
+   public Integer[] listCurrentSupportCodes()
+   {
+      return handler.getCurrentCodes();
+           
+   }
+   
+   public void clearCurrentSupportCodes()
+   {
+      
+      handler.clearSupportCodes();
+      
+   }
+   
+   public void addSupportCodes(final String fileName)
+   {
+      handler.addSupportCodes(fileName);      
+   }
+   
+   public boolean isCodeInUse(int code)
+   {
+      return handler.isCodeInUse(code);
+      
+   }
    /**
     * Recycle a server session.
     *
     * @param session  Description of Parameter
     */
-   void recycle(StdServerSession session)
+   void recycle(StdServerSession session, boolean isTimedOut)
    {
-      synchronized (sessionPool)
+	  
+	  if(session.getHasPermit())
+	  {
+		  session.setHasPermit(false);
+		  permits.release();
+	  }
+
+	  synchronized (sessionPool)
       {
-         if (closing)
+         if(!isTimedOut)
+            counter.decInUse();
+         
+         if(session.getHasError())
+            counter.incError();
+                  
+         if (closing || isTimedOut || (session.getHasError() && destroyOnError))
          {
+            
+            if(session.getHasError())
+            {
+               counter.incDestroyed();
+               
+            }
+            
             session.close();
+            
+            
             numServerSessions--;
+            
             if (numServerSessions == 0)
             {
                //notify clear thread.
                sessionPool.notifyAll();
             }
+         
          }
          else
          {
+            session.setLastUsed(System.currentTimeMillis());
             sessionPool.add(session);
             sessionPool.notifyAll();
+          
             if( log.isTraceEnabled() )
                log.trace("recycled server session: " + session);
          }
       }
+	  
+     
+   
    }
 
-   private void create() throws JMSException
+   // --- Private methods used internally
+   
+   private ServerSession createLazySession() throws JMSException
    {
-      for (int index = 0; index < poolSize; index++)
+      boolean debug = log.isDebugEnabled();
+      Session ses = null;
+      XASession xaSes = null;
+
+      if (debug)
+         log.debug("initializing lazy session with connection: " + con);
+
+      if (destination instanceof Topic && con instanceof XATopicConnection)
       {
+         xaSes = ((XATopicConnection)con).createXATopicSession();
+         ses = ((XATopicSession)xaSes).getTopicSession();
+      }
+      else if (destination instanceof Queue && con instanceof XAQueueConnection)
+      {
+         xaSes = ((XAQueueConnection)con).createXAQueueSession();
+         ses = ((XAQueueSession)xaSes).getQueueSession();
+      }
+      else if (destination instanceof Topic && con instanceof TopicConnection)
+      {
+         ses = ((TopicConnection)con).createTopicSession(transacted, ack);
+         log.warn("Using a non-XA TopicConnection.  " +
+               "It will not be able to participate in a Global UOW");
+      }
+      else if (destination instanceof Queue && con instanceof QueueConnection)
+      {
+         ses = ((QueueConnection)con).createQueueSession(transacted, ack);
+         log.warn("Using a non-XA QueueConnection.  " +
+               "It will not be able to participate in a Global UOW");
+      }
+      else
+      {
+         throw new JMSException("Connection was not reconizable: " + con + " for destination " + destination);
+      }
+
+      // create the server session and add it to the pool - it is up to the
+      // server session to set the listener
+      StdServerSession serverSession = new StdServerSession(this, ses, xaSes,
+         listener, useLocalTX, xidFactory, handler);
+      numServerSessions++;
+      counter.incTotalCreated();
+
+      if (debug)
+         log.debug("" + serverSession);
+      
+      return serverSession;
+   }
+   
+   private void create(int size) throws JMSException
+   {
+      boolean debug = log.isDebugEnabled();
+
+      for (int index = 0; index < size; index++)
+      {
          // Here is the meat, that MUST follow the spec
          Session ses = null;
          XASession xaSes = null;
 
-         log.debug("initializing with connection: " + con);
+         if (debug)
+            log.debug("initializing with connection: " + con);
 
          if (destination instanceof Topic && con instanceof XATopicConnection)
          {
@@ -350,15 +667,76 @@
          // create the server session and add it to the pool - it is up to the
          // server session to set the listener
          StdServerSession serverSession = new StdServerSession(this, ses, xaSes,
-            listener, useLocalTX, xidFactory, tm);
-
+            listener, useLocalTX, xidFactory, handler);
+         
+         counter.incTotalCreated();
          sessionPool.add(serverSession);
          numServerSessions++;
-
-         log.debug("added server session to the pool: " + serverSession);
+         
+         if (debug)
+            log.debug("added server session to the pool: " + serverSession);
       }
    }
-
+   
+   
+   void removeTimedOut()
+   {
+   
+      long timeout = System.currentTimeMillis() - idleTimeOut;
+      boolean trace = log.isTraceEnabled();
+      List timedOut = new ArrayList();
+      
+      while(true)
+      {
+         synchronized (sessionPool)
+         {
+            
+            if(sessionPool.size() > 0)
+            {
+               StdServerSession session = (StdServerSession)sessionPool.get(0);
+               
+               if (session.isTimedOut(timeout))
+               {
+                  sessionPool.remove(0);                  
+                  timedOut.add(session);
+                
+                  if(trace)
+                  {
+                     log.trace("Recycling timed out session" + session);
+                     
+                  }
+                  
+               }
+             
+               else
+               {
+                  break;
+               }
+            
+            }
+            
+            else
+            	break;
+         }
+         
+      }
+      
+      counter.timedOut(timedOut.size());
+      
+      for(Iterator iter = timedOut.iterator(); iter.hasNext();)
+      {
+         StdServerSession session = (StdServerSession)iter.next();
+         log.trace("Recycling timed out StdServerSession" + session);
+         recycle(session, true);
+         
+      }
+      
+      if(!closing && minSize > 0)
+         JmsSessionPoolFiller.fillPool(this);
+   
+   }        
+      
+         
    /**
     * A pooled executor where the minimum pool size
     * threads are kept alive
@@ -414,4 +792,90 @@
          return thread;
       }
    }
+   
+   //Simple class to record SessionStatistics
+   private static class SessionPoolStatisticsCollector
+   {
+      private int timedOut;
+      private int inUse;
+      private int maxInUse;
+      private int error;
+      private int totalCreated;
+      private int destroyedCount;
+      
+      synchronized void incTotalCreated()
+      {
+         ++totalCreated;
+         
+      }
+      
+      synchronized void decInUse()
+      {
+         --inUse;
+      }
+      
+      synchronized void incDestroyed()
+      {
+         ++destroyedCount;
+         
+      }
+      
+      synchronized void inUse()
+      {
+         ++inUse;
+      }
+      
+      synchronized void timedOut(int count)
+      {
+         timedOut += count;
+      }
+      synchronized void timedOut()
+      {
+         ++timedOut;
+         
+      }      
+      synchronized void incError()
+      {
+         ++error;
+         
+      }
+      synchronized void maxSessionInUse(int count)
+      {
+         if(count > maxInUse)
+            maxInUse = count;
+      }
+      
+      private int getMaxSessionInUse()
+      {
+         return maxInUse;
+      }
+
+      private int getTimedOutCount()
+      {
+         return timedOut;
+      }
+      
+      private int getInUseCount()
+      {
+         return inUse;
+      }
+      
+      private int getSessionErrorCount()
+      {
+         return error;
+         
+      }
+      
+      private int getTotalSessionCreated()
+      {
+         return totalCreated;
+      }
+   
+      private int getSessionDestroyedCount()
+      {
+         return destroyedCount;
+         
+      }
+   }
+
 }

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java	2006-12-07 22:00:20 UTC (rev 58912)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java	2006-12-07 22:00:38 UTC (rev 58913)
@@ -1,56 +1,42 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource J2EE webOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.jms.asf;
 
 import java.io.Serializable;
-
 import javax.jms.Connection;
 import javax.jms.Destination;
 import javax.jms.JMSException;
 import javax.jms.MessageListener;
+
 import javax.jms.ServerSessionPool;
 import javax.transaction.TransactionManager;
 
 import org.jboss.tm.XidFactoryMBean;
 
 /**
- * An implementation of ServerSessionPoolFactory. 
+ * An implementation of ServerSessionPoolFactory. <p>
  *
+ * Created: Fri Dec 22 09:47:41 2000
+ *
  * @author    <a href="mailto:peter.antman at tim.se">Peter Antman</a> .
  * @author    <a href="mailto:hiram.chirino at jboss.org">Hiram Chirino</a> .
- * @author <a href="mailto:adrian at jboss.com">Adrian Brock</a>
+ * @author    <a href="mailto:weston.price at jboss.com>Weston Price</a>
  * @version   $Revision$
  */
-public class StdServerSessionPoolFactory implements ServerSessionPoolFactory, Serializable
+public class StdServerSessionPoolFactory
+       implements ServerSessionPoolFactory, Serializable
 {
-   private static final long serialVersionUID = 4969432475779524576L;
+   static final long serialVersionUID = 4969432475779524576L;
 
    /** The name of this factory. */
    private String name;
 
    private XidFactoryMBean xidFactory;
 
-   private TransactionManager transactionManager;
-
    public StdServerSessionPoolFactory()
    {
       super();
@@ -75,20 +61,19 @@
    {
       return xidFactory;
    }
+   
 
-   public void setTransactionManager(TransactionManager transactionManager)
+   public javax.jms.ServerSessionPool getServerSessionPool(Destination destination, Connection con, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack, boolean useLocalTX, boolean lazyInit, boolean recycle, long idleTimeout, boolean destroySessionOnError, String supportCodeUrl, String sorterClassName, boolean validateLinkedException, javax.jms.MessageListener listener) throws javax.jms.JMSException
    {
-      this.transactionManager = transactionManager;
+     
+      ServerSessionPool pool = (ServerSessionPool)new StdServerSessionPool(destination, con, isTransacted, ack, useLocalTX, listener, minSession, maxSession, keepAlive, lazyInit, recycle, idleTimeout, destroySessionOnError, supportCodeUrl, sorterClassName, validateLinkedException, xidFactory);
+      return pool;
    }
-
-   public TransactionManager getTransactionManager()
+   
+   public javax.jms.ServerSessionPool getServerSessionPool(Destination destination, Connection con, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack, boolean useLocalTX, javax.jms.MessageListener listener) throws javax.jms.JMSException
    {
-      return transactionManager;
-   }
-
-   public ServerSessionPool getServerSessionPool(Destination destination, Connection con, int minSession, int maxSession, long keepAlive, boolean isTransacted, int ack, boolean useLocalTX, MessageListener listener) throws JMSException
-   {
-      ServerSessionPool pool = new StdServerSessionPool(destination, con, isTransacted, ack, useLocalTX, listener, minSession, maxSession, keepAlive, xidFactory, transactionManager);
+      
+      ServerSessionPool pool = (ServerSessionPool)new StdServerSessionPool(destination, con, isTransacted, ack, useLocalTX, listener, minSession, maxSession, keepAlive, xidFactory);
       return pool;
    }
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:00:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:00:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r58914 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf
Message-ID: <E1GsRIR-0001zW-G6@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 17:00:50 -0500 (Thu, 07 Dec 2006)
New Revision: 58914

Modified:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/package.html
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/package.html
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/package.html	2006-12-07 22:00:38 UTC (rev 58913)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/package.html	2006-12-07 22:00:50 UTC (rev 58914)
@@ -3,25 +3,23 @@
   <head>
     <!-- $Id$ -->
     <!--
- JBoss, Home of Professional Open Source
- Copyright 2005, JBoss Inc., and individual contributors as indicated
- by the @authors tag. See the copyright.txt 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 file is part of JBoss; the OpenSource J2EE webOS.
+                                                                              
+    This library 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 of the License, or      
+    (at your option) any later version.                                       
+                                                                              
+    This library 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 library; if not, write to the Free Software       
+    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA   
 
- 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.
     -->
   </head>
 



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:06:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:06:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r58915 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf
Message-ID: <E1GsROE-0002HT-VY@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 17:06:48 -0500 (Thu, 07 Dec 2006)
New Revision: 58915

Modified:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllFatalJMSExceptionSorter.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/AllNonFatalJMSExceptionSorter.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionCodeMatcher.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.jms.asf;
 
 import java.util.regex.Matcher;

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSExceptionSorter.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.jms.asf;
 
 import javax.jms.JMSException;

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeHandler.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JMSSupportCodeLoader.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsServerSessionReaper.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,10 +1,24 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
- */
-package org.jboss.jms.asf;
+ * 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.jms.asf;
 
 import java.util.ArrayList;
 import java.util.Collection;

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/JmsSessionPoolFiller.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolFactory.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoader.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/ServerSessionPoolLoaderMBean.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSession.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPool.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 import java.security.AccessController;

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/StdServerSessionPoolFactory.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java	2006-12-07 22:00:50 UTC (rev 58914)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/jms/asf/WebSphereMQExceptionSorter.java	2006-12-07 22:06:48 UTC (rev 58915)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.jms.asf;
 



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:06:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:06:56 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58916 - tags
Message-ID: <E1GsROK-0002Hs-KY@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-07 17:06:55 -0500 (Thu, 07 Dec 2006)
New Revision: 58916

Removed:
   tags/JBoss_4_0_3_SP1_CP03/
Log:
deleting this tag, it was created in November, but never released



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:07:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:07:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58917 -
	branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms
Message-ID: <E1GsROb-0002IY-IX@committer01.frg.pub.inap.atl.jboss.com>

Author: weston.price at jboss.com
Date: 2006-12-07 17:07:12 -0500 (Thu, 07 Dec 2006)
New Revision: 58917

Modified:
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java
   branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java
Log:
[JBAS-3657][JBAS-3511] Port of patch made for client in integrating with WebSphereMQ

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java	2006-12-07 22:06:55 UTC (rev 58916)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java	2006-12-07 22:07:12 UTC (rev 58917)
@@ -1,11 +1,24 @@
-/***************************************
- *                                     *
- *  JBoss: The OpenSource J2EE WebOS   *
- *                                     *
- *  Distributable under LGPL license.  *
- *  See terms of license at gnu.org.   *
- *                                     *
- ***************************************/
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.plugins.jms;
 

Modified: branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java
===================================================================
--- branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java	2006-12-07 22:06:55 UTC (rev 58916)
+++ branches/JBoss_4_0_5_GA_JBAS_3657/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvokerMBean.java	2006-12-07 22:07:12 UTC (rev 58917)
@@ -1,8 +1,23 @@
 /*
- * JBoss, the OpenSource J2EE webOS
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.
  *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
+ * 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.plugins.jms;
 



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:09:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:09:45 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1720 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/client/delegate jms/server/endpoint
	jms/server/endpoint/advised messaging/core/plugin/contract
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1GsRR3-0002Ll-Gw@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-07 17:09:40 -0500 (Thu, 07 Dec 2006)
New Revision: 1720

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
Removing a stupid idea from my brain flatulence :-)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-07 20:44:55 UTC (rev 1719)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-07 22:09:40 UTC (rev 1720)
@@ -154,11 +154,6 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
-   public boolean stillAround(int node) throws JMSException
-   {
-      throw new IllegalStateException("This invocation should not be handled here!");
-   }
-
    // Public --------------------------------------------------------
 
    public synchronized Object invoke(Invocation invocation) throws Throwable

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-07 20:44:55 UTC (rev 1719)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-07 22:09:40 UTC (rev 1720)
@@ -47,21 +47,5 @@
    /** Return the node that should take over a given node */
    int getFailoverNode(int node) throws JMSException;
 
-   /**
-    * This method will be used by HAAspect interceptor to ask other servers if
-    * a given server still around.
-    *
-    * This will be useful on retries from client2server communication. If a communication exception happened
-    * on the communication with a given server we will check with other peers to confirm if the server really
-    * diead before restabilishing a connection.
-    *
-    * This method is not very useful on leasing but it will be usefull on Exception listeners.
-    *
-    * Say, if a communication exception happens on an interceptor, the interceptor could ask other servers
-    * about their current membership and decide about a retry or a failover. 
-    *
-    * TODO: a better name for this method?
-    * */
-   boolean stillAround(int node) throws JMSException;
 }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-07 20:44:55 UTC (rev 1719)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-07 22:09:40 UTC (rev 1720)
@@ -152,20 +152,6 @@
    }
 
 
-   // TODO: Better name
-   public boolean stillAround(int node) throws JMSException
-   {
-      try
-      {
-         ServerPeer peer = (ServerPeer )serverPeer.getInstance();
-         return peer.getReplicator().stillAround(node);
-      }
-      catch (Throwable t)
-      {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " stillAround");
-      }
-   }
-
    public byte[] getClientAOPConfig() throws JMSException
    {
       try

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-07 20:44:55 UTC (rev 1719)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-07 22:09:40 UTC (rev 1720)
@@ -78,12 +78,6 @@
       return endpoint.getFailoverNode(node);
    }
 
-   // TODO: find a better name... look at javadoc on ConnectionFactoryInterface
-   public boolean stillAround(int node) throws JMSException
-   {
-      return endpoint.stillAround(node);
-   }
-
    // AdvisedSupport override ---------------------------------------
 
    public Object getEndpoint()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-07 20:44:55 UTC (rev 1719)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-07 22:09:40 UTC (rev 1720)
@@ -81,16 +81,4 @@
    int getFailoverNodeID(int nodeID);
 
 
-   /**
-    *
-    * This method will be used by HAAspect interceptor to ask other servers if
-    * a given server still around.
-    *
-    * This will be useful on retries from client2server communication. If a communication exception happened
-    * on the communication with a given server we will check with other peers to confirm if the server really
-    * diead before restabilishing a connection
-    *
-    * TODO: a better name for this method?
-    * */
-   public boolean stillAround(int nodeId);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-07 20:44:55 UTC (rev 1719)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-07 22:09:40 UTC (rev 1720)
@@ -608,15 +608,6 @@
       }
    }
 
-   // TODO: find a better name
-   public boolean stillAround(int nodeId)
-   {
-      synchronized (failoverMap)
-      {
-         return failoverMap.get(new Integer(nodeId))!=null;
-      }
-   }
-
    // Replicator implementation --------------------------------------------------------------------------
    
    public Map get(Serializable key) throws Exception



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:14:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:14:05 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58918 - tags
Message-ID: <E1GsRVF-0002Sf-LT@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-07 17:14:05 -0500 (Thu, 07 Dec 2006)
New Revision: 58918

Added:
   tags/JBoss_4_0_3_SP1_CP03/
Log:
cut the 4.0.3.SP1_CP03 release

Copied: tags/JBoss_4_0_3_SP1_CP03 (from rev 58917, branches/JBoss_4_0_3_SP1_CP)



From vladimir.blagojevic at jboss.com  Thu Dec  7 17:20:23 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 07 Dec 2006 17:20:23 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1GsRbL-0002ad-08@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/07 17:20:22

  Modified:    src/org/jboss/cache/marshall  MethodDeclarations.java
  Log:
  [JBCACHE-315] work in progress (JGroups block event passed to interceptors)
  
  Revision  Changes    Path
  1.25      +9 -1      JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodDeclarations.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- MethodDeclarations.java	20 Nov 2006 03:53:55 -0000	1.24
  +++ MethodDeclarations.java	7 Dec 2006 22:20:22 -0000	1.25
  @@ -31,7 +31,7 @@
    * allowing lookup operations both ways.
    *
    * @author <a href="galder.zamarreno at jboss.com">Galder Zamarreno</a>
  - * @version $Revision: 1.24 $
  + * @version $Revision: 1.25 $
    */
   public class MethodDeclarations
   {
  @@ -112,6 +112,8 @@
   
      public static final Method moveMethodLocal;
   
  +   public static final Method blockChannelLocal;
  +
      // these are basic crud methods that are version-aware - JBCACHE-843.
   
      public static final Method putDataVersionedMethodLocal;
  @@ -210,6 +212,8 @@
   
      public static final int removeDataVersionedMethodLocal_id = 42;
   
  +   public static final int blockChannelMethodLocal_id = 43;
  +
   
      static
      {
  @@ -259,6 +263,9 @@
            // ------------ move() api
            moveMethodLocal = TreeCache.class.getDeclaredMethod("_move", Fqn.class, Fqn.class);
   
  +         // ------------ Channel BLOCK event 
  +         blockChannelLocal =  TreeCache.class.getDeclaredMethod("_block"); 
  +
            // ------------ version-aware methods - see JBCACHE-843
            putDataVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, DataVersion.class);
            putDataEraseVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, boolean.class, DataVersion.class);
  @@ -310,6 +317,7 @@
         methods.put(dataGravitationMethod_id, dataGravitationMethod);
   
         methods.put(moveMethodLocal_id, moveMethodLocal);
  +      methods.put(blockChannelMethodLocal_id, blockChannelLocal);
   
         methods.put(putDataVersionedMethodLocal_id, putDataVersionedMethodLocal);
         methods.put(putDataEraseVersionedMethodLocal_id, putDataEraseVersionedMethodLocal);
  
  
  


From vladimir.blagojevic at jboss.com  Thu Dec  7 17:20:23 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 07 Dec 2006 17:20:23 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GsRbL-0002ak-Kd@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/07 17:20:23

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  [JBCACHE-315] work in progress (JGroups block event passed to interceptors)
  
  Revision  Changes    Path
  1.290     +21 -3     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.289
  retrieving revision 1.290
  diff -u -b -r1.289 -r1.290
  --- TreeCache.java	7 Dec 2006 20:01:19 -0000	1.289
  +++ TreeCache.java	7 Dec 2006 22:20:23 -0000	1.290
  @@ -94,7 +94,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.289 2006/12/07 20:01:19 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.290 2006/12/07 22:20:23 vblagojevic Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -3195,6 +3195,11 @@
         }
      }
   
  +   public void _block()
  +   {
  +      log.info("Invoking block on " + getLocalAddress());
  +   }
  +
      private void moveFqns(Node node, Fqn newBase)
      {
         Fqn newFqn = new Fqn(newBase, ((TreeNode)node).getName());
  @@ -3358,9 +3363,18 @@
            }
            try
            {
  -            getStateTransferManager().setState(istream, Fqn.ROOT, null);
  +            MarshalledValueInputStream in = new MarshalledValueInputStream(istream);
  +            boolean hasState = in.readBoolean();
  +            if (!hasState)
  +            {
  +               in.close();
  +            }
  +            else
  +            {
  +               getStateTransferManager().setState(in, Fqn.ROOT, null);
               isStateSet = true;
            }
  +         }
            catch (Throwable t)
            {
               my_log.error("failed setting state", t);
  @@ -3542,10 +3556,14 @@
      }
   
      /**
  -    * Blocks sending and receiving of messages until viewAccepted() is called.
  +    * Indicates that a channel has received a BLOCK event from FLUSH protocol.
  +    * 
  +    * 
       */
      public void block()
      {
  +      MethodCall m = MethodCallFactory.create(MethodDeclarations.blockChannelLocal);
  +      invokeMethod(m);
      }
   
      /*------------------- End of MembershipListener ----------------------*/
  
  
  


From vladimir.blagojevic at jboss.com  Thu Dec  7 17:21:48 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 07 Dec 2006 17:21:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer  ...
Message-ID: <E1GsRci-0002cS-Q1@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/07 17:21:48

  Modified:    src/org/jboss/cache/statetransfer  StateTransferManager.java
  Log:
  bypass interceptor chain while state is being integrated
  
  Revision  Changes    Path
  1.16      +15 -0     JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- StateTransferManager.java	20 Nov 2006 03:53:55 -0000	1.15
  +++ StateTransferManager.java	7 Dec 2006 22:21:48 -0000	1.16
  @@ -17,6 +17,7 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.config.Option;
   import org.jboss.cache.loader.CacheLoaderManager;
   import org.jboss.cache.loader.NodeData;
   import org.jboss.cache.loader.NodeDataMarker;
  @@ -266,6 +267,20 @@
   
            integrator = getStateTransferIntegrator(in, targetRoot.getFqn());
            long startTime = System.currentTimeMillis();
  +         
  +         /*
  +          * Vladimir/Manik/Brian (Dec 7,2006)
  +          * 
  +          * integrator.integrateState(in,targetRoot, cl) will call cache.put for each 
  +          * node read from stream. Having option override below allows nodes read  
  +          * to be directly stored into a tree since we bypass interceptor chain.
  +          *                
  +          */
  +         
  +         Option option = new Option();
  +         option.setBypassInterceptorChain(true);
  +         treeCache.getInvocationContext().setOptionOverrides(option);
  +         
            try
            {
               log.info("starting state integration at node " + targetRoot);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:33:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:33:10 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58919 - trunk/build
Message-ID: <E1GsRni-0002sC-Tn@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-07 17:33:10 -0500 (Thu, 07 Dec 2006)
New Revision: 58919

Modified:
   trunk/build/build-thirdparty.xml
Log:
update common-core

Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-07 22:14:05 UTC (rev 58918)
+++ trunk/build/build-thirdparty.xml	2006-12-07 22:33:10 UTC (rev 58919)
@@ -88,7 +88,7 @@
       <componentref name="jboss/aop14" version="2.0.0.alpha2"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/cache" version="2.0.0.ALPHA1"/>
-      <componentref name="jboss/common-core" version="2.0.2.GA"/>
+      <componentref name="jboss/common-core" version="2.0.3.GA"/>
       <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>



From brian.stansberry at jboss.com  Thu Dec  7 17:35:39 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 17:35:39 -0500
Subject: [jboss-cvs] JBossCache/docs/TreeCache/en/modules  ...
Message-ID: <E1GsRq7-0002vK-C1@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 17:35:39

  Modified:    docs/TreeCache/en/modules  Tag: Branch_JBossCache_1_4_0
                        configuration.xml
  Log:
  Add mux config docs
  General cleanup, alphabetize
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.10.2.3  +113 -76   JBossCache/docs/TreeCache/en/modules/configuration.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: configuration.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/docs/TreeCache/en/modules/configuration.xml,v
  retrieving revision 1.10.2.2
  retrieving revision 1.10.2.3
  diff -u -b -r1.10.2.2 -r1.10.2.3
  --- configuration.xml	29 Nov 2006 04:01:12 -0000	1.10.2.2
  +++ configuration.xml	7 Dec 2006 22:35:39 -0000	1.10.2.3
  @@ -56,10 +56,21 @@
           registered to capture and display its statistics.  --&gt;
       &lt;attribute name="UseInterceptorMbeans"&gt;true&lt;/attribute&gt;
   
  -    &lt;!-- Name of cluster. Needs to be the same for all clusters, in order
  -             to find each other --&gt;
  +    &lt;!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
  +    cluster, in order to find each other --&gt;
       &lt;attribute name="ClusterName"&gt;JBoss-Cache-Cluster&lt;/attribute&gt;
   
  +    &lt;!-- Uncomment next three statements to enable JGroups multiplexer.
  +         This configuration is dependent on the JGroups multiplexer being
  +         registered in an MBean server such as JBossAS. --&gt;
  +    &lt;!--
  +    &lt;depends&gt;jgroups.mux:name=Multiplexer&lt;/depends&gt;
  +    &lt;attribute name="MultiplexerService"&gt;jgroups.mux:name=Multiplexer&lt;/attribute&gt;
  +    &lt;attribute name="MultiplexerStack"&gt;udp&lt;/attribute&gt;
  +    --&gt;
  +
  +    &lt;!-- JGroups protocol stack properties. ClusterConfig isn't used if the
  +     multiplexer is enabled and successfully initialized. --&gt;
       &lt;attribute name="ClusterConfig"&gt;
         &lt;config&gt;
           &lt;!-- UDP: if you have a multihomed machine,
  @@ -245,23 +256,29 @@
   
             <row>
               <entry>
  -              <para>ClusterName</para>
  +              <para>ClusterConfig</para>
               </entry>
   
               <entry>
  -              <para>Name of cluster. Needs to be the same for all nodes in a
  -              cluster in order to find each other.</para>
  +              <para>The configuration of the underlying JGroups stack.              
  +              Ignored if <literal>MultiplexerService</literal> and
  +              <literal>MultiplexerStack</literal> are used. 
  +              See the various *-service.xml files in the source distribution
  +              <literal>etc/META-INF</literal> folder for examples.
  +              See the <ulink  url="http://www.jgroups.org">JGroups documentation</ulink>
  +              or the <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">JGroups wiki page</ulink> 
  +              for more information.</para>
               </entry>
             </row>
   
             <row>
               <entry>
  -              <para>ClusterConfig</para>
  +              <para>ClusterName</para>
               </entry>
   
               <entry>
  -              <para>The configuration of the underlying JGroups stack. See
  -              cluster-service.xml for an example.</para>
  +              <para>Name of cluster. Needs to be the same for all nodes in a
  +              cluster in order for them to communicate with each other.</para>
               </entry>
             </row>
   
  @@ -271,8 +288,9 @@
               </entry>
   
               <entry>
  -              <para>The name of a class implementing EvictionPolicy. If empty,
  -              no eviction policy is enabled.</para>
  +              <para>The name of a class implementing EvictionPolicy. Deprecated;
  +              it is preferable to configure the eviction policy class as 
  +              part of the <literal>EvictionPolicyConfig</literal>.</para>
               </entry>
             </row>
   
  @@ -295,7 +313,7 @@
   
               <entry>
                 <para>Whether or not to acquire the initial in-memory state from
  -              existing members. Allows for warm/hot caches (true/false). Also
  +              existing members. Allows for hot/cold caches (true/false). Also
                 see the fetchPersistentState element in
                 CacheLoaderConfiguration.</para>
               </entry>
  @@ -303,6 +321,22 @@
   
             <row>
               <entry>
  +              <para>InactiveOnStartup</para>
  +            </entry>
  +
  +            <entry>
  +              <para>Whether or not the entire tree is inactive upon startup,
  +              only responding to replication messages after
  +              <literal>activateRegion()</literal> is called to activate one or
  +              more parts of the tree. If true, property
  +              <literal>FetchInMemoryState</literal> is ignored. This property
  +              should only be set to true if <literal>UseRegionBasedMarshalling</literal>
  +              is also <literal>true</literal>.</para>
  +            </entry>
  +          </row>
  +
  +          <row>
  +            <entry>
                 <para>InitialStateRetrievalTimeout</para>
               </entry>
   
  @@ -317,56 +351,74 @@
   
             <row>
               <entry>
  -              <para>InactiveOnStartup</para>
  +              <para>IsolationLevel</para>
               </entry>
   
               <entry>
  -              <para>Whether or not the entire tree is inactive upon startup,
  -              only responding to replication messages after
  -              <literal>activateRegion()</literal> is called to activate one or
  -              more parts of the tree. If true, property
  -              <literal>FetchInMemoryState</literal> is ignored. This property
  -              should only be set to true if <literal>UseRegionBasedMarshalling</literal>
  -              is also <literal>true</literal>.</para>
  +              <para>Node locking isolation level : SERIALIZABLE, REPEATABLE_READ
  +                        (default), READ_COMMITTED, READ_UNCOMMITTED, and NONE. Note that this is ignored if
  +                        NodeLockingScheme is OPTIMISTIC. Case doesn't matter. See documentation on Transactions and
  +                        Concurrency for more details.
  +                     </para>
               </entry>
             </row>
   
             <row>
               <entry>
  -              <para>NodeLockingScheme</para>
  +              <para>LockAcquisitionTimeout</para>
               </entry>
   
               <entry>
  -              <para>May be PESSIMISTIC (default) or OPTIMISTIC.  See documentation on Transactions and Concurrency for more details.</para>
  +              <para>Time in milliseconds to wait for a lock to be acquired. If
  +              a lock cannot be acquired an exception will be thrown.</para>
               </entry>
             </row>
   
  +           <row>
  +              <entry>
  +                 <para>MultiplexerService</para>
  +              </entry>
  +
  +              <entry>
  +                 <para>The JMX object name of the service that defines the JGroups multiplexer.
  +                    In JBoss AS 5 this service is normally defined in the jgroups-multiplexer.sar.
  +                    If this attribute is defined, the cache will look up the multiplexer service 
  +                    in JMX and will use it to obtain a multiplexed JGroups channel. The configuration
  +                    of the channel will be that associated with <literal>MultiplexerStack</literal>.
  +                    The <literal>ClusterConfig</literal> attribute will be ignored.
  +                 </para>
  +              </entry>
  +           </row>
   
             <row>
               <entry>
  -              <para>IsolationLevel</para>
  +                 <para>MultiplexerStack</para>
               </entry>
   
               <entry>
  -              <para>Node locking isolation level : SERIALIZABLE, REPEATABLE_READ
  -              (default), READ_COMMITTED, READ_UNCOMMITTED, and NONE. Note that this is ignored if NodeLockingScheme is OPTIMISTIC.  Case doesn't matter. See documentation on Transactions and Concurrency for more details.</para>
  +                 <para>The name of the JGroups stack to be used with the TreeCache cluster.
  +                    Stacks are defined in the configuration of the external <literal>MultiplexerService</literal>
  +                    discussed above.  In JBoss AS 5 this is normally done in the 
  +                    jgroups-multiplexer.sar\META-INF\multiplexer-stacks.xml file.
  +                    The default stack is <literal>udp</literal>. This attribute is used in conjunction with
  +                    <literal>MultiplexerService</literal>.
  +                 </para>
               </entry>
             </row>
   
             <row>
               <entry>
  -              <para>LockAcquisitionTimeout</para>
  +              <para>NodeLockingScheme</para>
               </entry>
   
               <entry>
  -              <para>Time in milliseconds to wait for a lock to be acquired. If
  -              a lock cannot be acquired an exception will be thrown.</para>
  +              <para>May be PESSIMISTIC (default) or OPTIMISTIC.  See documentation on Transactions and Concurrency for more details.</para>
               </entry>
             </row>
   
             <row>
                <entry><para>ReplicationVersion</para></entry>
  -             <entry><para>Tells the cache to serialize replication traffic
  +             <entry><para>Tells the cache to serialize cluster traffic
                in a format consistent with that used by the given release
                of JBoss Cache.  Different JBoss Cache versions use different
                wire formats; setting this attribute tells a cache from a later
  @@ -392,39 +444,54 @@
   
             <row>
               <entry>
  -              <para>SyncReplTimeout</para>
  +              <para>ReplQueueMaxElements</para>
               </entry>
   
               <entry>
  -              <para>For synchronous replication: time in milliseconds to wait
  -              until replication acks have been received from all nodes in the
  -              cluster.</para>
  +              <para>Max number of elements in the replication queue until
  +              replication kicks in.</para>
               </entry>
             </row>
   
             <row>
               <entry>
  -              <para>ReplQueueMaxElements</para>
  +              <para>SyncCommitPhase</para>
               </entry>
   
               <entry>
  -              <para>Max number of elements in the replication queue until
  -              replication kicks in.</para>
  +              <para>This option is used to control the behaviour of the commit part of a 2-phase commit protocol, when
  +                    using REPL_SYNC (does not apply to other cache modes).  By default this is set to
  +                    <literal>false</literal>.  There is a performance penalty to enabling this, especially when running
  +                    in a large cluster, but the upsides are greater cluster-wide data integrity.  See the chapter on
  +                    Clustered Caches for more information on this.
  +              </para>
               </entry>
             </row>
   
             <row>
               <entry>
  -              <para>StateTransferVersion</para>
  +              <para>SyncReplTimeout</para>
               </entry>
   
               <entry>
  -              <para>The binary format to use for state transfer data.
  -              Different releases of JBossCache use different formats; if this
  -              attribute is set a later release will use an earlier release's
  -              format, allowing interoperability. Valid values are "124" for
  -              JBossCache 1.2.4, "130" for release 1.3.0, etc. Earliest valid
  -              version is 124.</para>
  +              <para>For synchronous replication: time in milliseconds to wait
  +              until replication acks have been received from all nodes in the
  +              cluster.</para>
  +            </entry>
  +          </row>
  +
  +           <row>
  +             <entry>
  +               <para>SyncRollbackPhase</para>
  +             </entry>
  +
  +             <entry>
  +               <para>This option is used to control the behaviour of the rollback part of a 2-phase commit protocol, when
  +                     using REPL_SYNC (does not apply to other cache modes).  By default this is set to
  +                     <literal>false</literal>.  There is a performance penalty to enabling this, especially when running
  +                     in a large cluster, but the upsides are greater cluster-wide data integrity.  See the chapter on
  +                    Clustered Caches for more information on this.
  +               </para>
               </entry>
             </row>
   
  @@ -448,8 +515,8 @@
   
               <entry>
                 <para> Specifies whether each interceptor should have an associated
  -              mbean registered.  Interceptor mbeans are used to capture and display 
  -              statistics.  This setting enables or disables all such interceptor 
  +              mbean registered.  Interceptor mbeans are used to capture statistics
  +              and display them in JMX.  This setting enables or disables all such interceptor 
                 mbeans.  Default value is <emphasis>true</emphasis>.</para>
               </entry>
             </row>
  @@ -476,36 +543,6 @@
               </entry>
             </row>
   
  -          <row>
  -            <entry>
  -              <para>SyncCommitPhase</para>
  -            </entry>
  -
  -            <entry>
  -              <para>This option is used to control the behaviour of the commit part of a 2-phase commit protocol, when
  -                    using REPL_SYNC (does not apply to other cache modes).  By default this is set to
  -                    <literal>false</literal>.  There is a performance penalty to enabling this, especially when running
  -                    in a large cluster, but the upsides are greater cluster-wide data integrity.  See the chapter on
  -                    Clustered Caches for more information on this.
  -              </para>
  -            </entry>
  -          </row>
  -
  -           <row>
  -             <entry>
  -               <para>SyncRollbackPhase</para>
  -             </entry>
  -
  -             <entry>
  -               <para>This option is used to control the behaviour of the rollback part of a 2-phase commit protocol, when
  -                     using REPL_SYNC (does not apply to other cache modes).  By default this is set to
  -                     <literal>false</literal>.  There is a performance penalty to enabling this, especially when running
  -                     in a large cluster, but the upsides are greater cluster-wide data integrity.  See the chapter on
  -                    Clustered Caches for more information on this.
  -               </para>
  -             </entry>
  -           </row>
  -
           </tbody>
         </tgroup>
       </informaltable>
  
  
  


From brian.stansberry at jboss.com  Thu Dec  7 17:36:16 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 17:36:16 -0500
Subject: [jboss-cvs] JBossCache/docs/TreeCache/en/modules  ...
Message-ID: <E1GsRqi-0002wD-BC@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 17:36:16

  Modified:    docs/TreeCache/en/modules  configuration.xml
  Log:
  General cleanup, alphabetize
  
  Revision  Changes    Path
  1.14      +102 -117  JBossCache/docs/TreeCache/en/modules/configuration.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: configuration.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/docs/TreeCache/en/modules/configuration.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- configuration.xml	29 Nov 2006 04:12:18 -0000	1.13
  +++ configuration.xml	7 Dec 2006 22:36:16 -0000	1.14
  @@ -64,7 +64,7 @@
            &lt;!--
            &lt;depends&gt;jgroups.mux:name=Multiplexer&lt;/depends&gt;
            &lt;attribute name="MultiplexerService"&gt;jgroups.mux:name=Multiplexer&lt;/attribute&gt;
  -         &lt;attribute name="MultiplexerStack"&gt;fc-fast-minimalthreads&lt;/attribute&gt;
  +         &lt;attribute name="MultiplexerStack"&gt;udp&lt;/attribute&gt;
            --&gt;
   
            &lt;!-- JGroups protocol stack properties. ClusterConfig isn't used if the
  @@ -260,54 +260,29 @@
   
                  <row>
                     <entry>
  -                     <para>ClusterName</para>
  -                  </entry>
  -
  -                  <entry>
  -                     <para>Name of cluster. Needs to be the same for all nodes in a
  -                        cluster in order to find each other.
  -                     </para>
  -                  </entry>
  -               </row>
  -
  -               <row>
  -                  <entry>
  -                     <para>MultiplexerService</para>
  -                  </entry>
  -
  -                  <entry>
  -                     <para>The name of the service that defines the JGroups multiplexer.
  -                        This service is normally defined in jgroups-multiplexer.sar\META-INF\jboss-service.xml.
  -                        When this attribute is defined and initialized successfully, the TreeCache cluster will
  -                        use a multiplexed JGroups channel and the ClusterConfig attribute will be ignored.
  -                     </para>
  -                  </entry>
  -               </row>
  -
  -               <row>
  -                  <entry>
  -                     <para>MultiplexerStack</para>
  +                     <para>ClusterConfig</para>
                     </entry>
   
                     <entry>
  -                     <para>The name of the JGroups stack to be used with the TreeCache cluster.
  -                        Stacks are defined in jgroups-multiplexer.sar\META-INF\multiplexer-stacks.xml.
  -                        The default stack is fc-fast-minimalthreads. This attribute is used in conjunction with
  -                        MultiplexerService.
  -                     </para>
  +              <para>The configuration of the underlying JGroups stack.              
  +              Ignored if <literal>MultiplexerService</literal> and
  +              <literal>MultiplexerStack</literal> are used. 
  +              See the various *-service.xml files in the source distribution
  +              <literal>etc/META-INF</literal> folder for examples.
  +              See the <ulink  url="http://www.jgroups.org">JGroups documentation</ulink>
  +              or the <ulink url="http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups">JGroups wiki page</ulink> 
  +              for more information.</para>
                     </entry>
                  </row>
   
                  <row>
                     <entry>
  -                     <para>ClusterConfig</para>
  +                     <para>ClusterName</para>
                     </entry>
   
                     <entry>
  -                     <para>The configuration of the underlying JGroups stack. See
  -                        cluster-service.xml for an example. This attribute isn't used when
  -                        MultiplexerService is defined.
  -                     </para>
  +                     <para>Name of cluster. Needs to be the same for all nodes in a
  +              cluster in order for them to communicate with each other.</para>
                     </entry>
                  </row>
   
  @@ -317,9 +292,9 @@
                     </entry>
   
                     <entry>
  -                     <para>The name of a class implementing EvictionPolicy. If empty,
  -                        no eviction policy is enabled.
  -                     </para>
  +              <para>The name of a class implementing EvictionPolicy. Deprecated;
  +              it is preferable to configure the eviction policy class as 
  +              part of the <literal>EvictionPolicyConfig</literal>.</para>
                     </entry>
                  </row>
   
  @@ -344,7 +319,7 @@
   
                     <entry>
                        <para>Whether or not to acquire the initial in-memory state from
  -                        existing members. Allows for warm/hot caches (true/false). Also
  +              existing members. Allows for hot/cold caches (true/false). Also
                           see the fetchPersistentState element in
                           CacheLoaderConfiguration.
                        </para>
  @@ -353,22 +328,6 @@
   
                  <row>
                     <entry>
  -                     <para>InitialStateRetrievalTimeout</para>
  -                  </entry>
  -
  -                  <entry>
  -                     <para>Time in milliseconds to wait for initial state
  -                        retrieval. This should be longer than
  -                        <literal>LockAcquisitionTimeout</literal>
  -                        as the node
  -                        providing state may need to wait that long to acquire
  -                        necessary read locks on the cache.
  -                     </para>
  -                  </entry>
  -               </row>
  -
  -               <row>
  -                  <entry>
                        <para>InactiveOnStartup</para>
                     </entry>
   
  @@ -391,12 +350,16 @@
   
                  <row>
                     <entry>
  -                     <para>NodeLockingScheme</para>
  +                     <para>InitialStateRetrievalTimeout</para>
                     </entry>
   
                     <entry>
  -                     <para>May be PESSIMISTIC (default) or OPTIMISTIC. See documentation on Transactions and Concurrency
  -                        for more details.
  +                     <para>Time in milliseconds to wait for initial state
  +                        retrieval. This should be longer than
  +                        <literal>LockAcquisitionTimeout</literal>
  +                        as the node
  +                        providing state may need to wait that long to acquire
  +                        necessary read locks on the cache.
                        </para>
                     </entry>
                  </row>
  @@ -430,10 +393,51 @@
   
                  <row>
                     <entry>
  -                     <para>ReplicationVersion</para>
  +                     <para>MultiplexerService</para>
  +                  </entry>
  +
  +                  <entry>
  +                     <para>The JMX object name of the service that defines the JGroups multiplexer.
  +                        In JBoss AS 5 this service is normally defined in the jgroups-multiplexer.sar.
  +                        If this attribute is defined, the cache will look up the multiplexer service 
  +                        in JMX and will use it to obtain a multiplexed JGroups channel. The configuration
  +                        of the channel will be that associated with <literal>MultiplexerStack</literal>.
  +                    The <literal>ClusterConfig</literal> attribute will be ignored.
  +                     </para>
  +                  </entry>
  +               </row>
  +
  +               <row>
  +                  <entry>
  +                     <para>MultiplexerStack</para>
  +                  </entry>
  +
  +                  <entry>
  +                     <para>The name of the JGroups stack to be used with the TreeCache cluster.
  +                    Stacks are defined in the configuration of the external <literal>MultiplexerService</literal>
  +                        discussed above.  In JBoss AS 5 this is normally done in the 
  +                        jgroups-multiplexer.sar\META-INF\multiplexer-stacks.xml file.
  +                        The default stack is <literal>udp</literal>. This attribute is used in conjunction with
  +                        <literal>MultiplexerService</literal>.
  +                     </para>
  +                  </entry>
  +               </row>
  +
  +               <row>
  +                  <entry>
  +                     <para>NodeLockingScheme</para>
                     </entry>
  +
                     <entry>
  -                     <para>Tells the cache to serialize replication traffic
  +                     <para>May be PESSIMISTIC (default) or OPTIMISTIC. See documentation on Transactions and Concurrency
  +                        for more details.
  +                     </para>
  +                  </entry>
  +               </row>
  +
  +               <row>
  +             <entry><para>ReplicationVersion</para></entry>
  +             <entry><para>Tells the cache to serialize cluster traffic
                           in a format consistent with that used by the given release
                           of JBoss Cache. Different JBoss Cache versions use different
                           wire formats; setting this attribute tells a cache from a later
  @@ -461,41 +465,59 @@
   
                  <row>
                     <entry>
  -                     <para>SyncReplTimeout</para>
  +                     <para>ReplQueueMaxElements</para>
                     </entry>
   
                     <entry>
  -                     <para>For synchronous replication: time in milliseconds to wait
  -                        until replication acks have been received from all nodes in the
  -                        cluster.
  +                     <para>Max number of elements in the replication queue until
  +                        replication kicks in.
                        </para>
                     </entry>
                  </row>
   
                  <row>
                     <entry>
  -                     <para>ReplQueueMaxElements</para>
  +                     <para>SyncCommitPhase</para>
                     </entry>
   
                     <entry>
  -                     <para>Max number of elements in the replication queue until
  -                        replication kicks in.
  +                     <para>This option is used to control the behaviour of the commit part of a 2-phase commit protocol,
  +                        when
  +                        using REPL_SYNC (does not apply to other cache modes). By default this is set to
  +                        <literal>false</literal>
  +                        . There is a performance penalty to enabling this, especially when running
  +                        in a large cluster, but the upsides are greater cluster-wide data integrity. See the chapter on
  +                        Clustered Caches for more information on this.
  +                     </para>
  +                  </entry>
  +               </row>
  +
  +               <row>
  +                  <entry>
  +                     <para>SyncReplTimeout</para>
  +                  </entry>
  +
  +                  <entry>
  +                     <para>For synchronous replication: time in milliseconds to wait
  +                        until replication acks have been received from all nodes in the
  +                        cluster.
                        </para>
                     </entry>
                  </row>
   
                  <row>
                     <entry>
  -                     <para>StateTransferVersion</para>
  +                     <para>SyncRollbackPhase</para>
                     </entry>
   
                     <entry>
  -                     <para>The binary format to use for state transfer data.
  -                        Different releases of JBossCache use different formats; if this
  -                        attribute is set a later release will use an earlier release's
  -                        format, allowing interoperability. Valid values are "124" for
  -                        JBossCache 1.2.4, "130" for release 1.3.0, etc. Earliest valid
  -                        version is 124.
  +                     <para>This option is used to control the behaviour of the rollback part of a 2-phase commit
  +                        protocol, when
  +                        using REPL_SYNC (does not apply to other cache modes). By default this is set to
  +                        <literal>false</literal>
  +                        . There is a performance penalty to enabling this, especially when running
  +                        in a large cluster, but the upsides are greater cluster-wide data integrity. See the chapter on
  +                        Clustered Caches for more information on this.
                        </para>
                     </entry>
                  </row>
  @@ -521,12 +543,9 @@
   
                     <entry>
                        <para>Specifies whether each interceptor should have an associated
  -                        mbean registered. Interceptor mbeans are used to capture and display
  -                        statistics. This setting enables or disables all such interceptor
  -                        mbeans. Default value is
  -                        <emphasis>true</emphasis>
  -                        .
  -                     </para>
  +              mbean registered.  Interceptor mbeans are used to capture statistics
  +              and display them in JMX.  This setting enables or disables all such interceptor 
  +              mbeans.  Default value is <emphasis>true</emphasis>.</para>
                     </entry>
                  </row>
   
  @@ -556,40 +575,6 @@
                     </entry>
                  </row>
   
  -               <row>
  -                  <entry>
  -                     <para>SyncCommitPhase</para>
  -                  </entry>
  -
  -                  <entry>
  -                     <para>This option is used to control the behaviour of the commit part of a 2-phase commit protocol,
  -                        when
  -                        using REPL_SYNC (does not apply to other cache modes). By default this is set to
  -                        <literal>false</literal>
  -                        . There is a performance penalty to enabling this, especially when running
  -                        in a large cluster, but the upsides are greater cluster-wide data integrity. See the chapter on
  -                        Clustered Caches for more information on this.
  -                     </para>
  -                  </entry>
  -               </row>
  -
  -               <row>
  -                  <entry>
  -                     <para>SyncRollbackPhase</para>
  -                  </entry>
  -
  -                  <entry>
  -                     <para>This option is used to control the behaviour of the rollback part of a 2-phase commit
  -                        protocol, when
  -                        using REPL_SYNC (does not apply to other cache modes). By default this is set to
  -                        <literal>false</literal>
  -                        . There is a performance penalty to enabling this, especially when running
  -                        in a large cluster, but the upsides are greater cluster-wide data integrity. See the chapter on
  -                        Clustered Caches for more information on this.
  -                     </para>
  -                  </entry>
  -               </row>
  -
               </tbody>
            </tgroup>
         </informaltable>
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 17:42:41 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 17:42:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/resources/META-INF  ...
Message-ID: <E1GsRwv-00034b-Iq@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 17:42:41

  Modified:    examples/glassfish/resources/META-INF  persistence.xml
  Log:
  minor fix
  
  Revision  Changes    Path
  1.3       +2 -1      jboss-seam/examples/glassfish/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/resources/META-INF/persistence.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- persistence.xml	3 Dec 2006 04:18:53 -0000	1.2
  +++ persistence.xml	7 Dec 2006 22:42:41 -0000	1.3
  @@ -12,6 +12,7 @@
                 value="org.hibernate.dialect.DerbyDialect"/>
            <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
            <property name="hibernate.show_sql" value="true"/>
  +         <property name="hibernate.transaction.flush_before_completion" value="true"/>
            
            <property name="hibernate.cache.provider_class" 
                 value="org.hibernate.cache.HashtableCacheProvider"/>
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 17:42:41 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 17:42:41 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/glassfish/src/org/jboss/seam/example/booking ...
Message-ID: <E1GsRwv-00034i-Md@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 17:42:41

  Modified:    examples/glassfish/src/org/jboss/seam/example/booking 
                        Booking.java
  Log:
  minor fix
  
  Revision  Changes    Path
  1.2       +3 -1      jboss-seam/examples/glassfish/src/org/jboss/seam/example/booking/Booking.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Booking.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/src/org/jboss/seam/example/booking/Booking.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Booking.java	29 Nov 2006 09:30:41 -0000	1.1
  +++ Booking.java	7 Dec 2006 22:42:41 -0000	1.2
  @@ -1,4 +1,4 @@
  -//$Id: Booking.java,v 1.1 2006/11/29 09:30:41 myuan Exp $
  +//$Id: Booking.java,v 1.2 2006/12/07 22:42:41 myuan Exp $
   package org.jboss.seam.example.booking;
   
   import java.io.Serializable;
  @@ -8,6 +8,7 @@
   import javax.persistence.Basic;
   import javax.persistence.Entity;
   import javax.persistence.GeneratedValue;
  +import javax.persistence.GenerationType;
   import javax.persistence.Id;
   import javax.persistence.ManyToOne;
   import javax.persistence.Temporal;
  @@ -43,6 +44,7 @@
         this.user = user;
      }
   
  +   // error with locking @Id @GeneratedValue(strategy=GenerationType.IDENTITY)
      @Id @GeneratedValue
      public Long getId()
      {
  
  
  


From michael.yuan at jboss.com  Thu Dec  7 17:42:41 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Thu, 07 Dec 2006 17:42:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/view/js  ...
Message-ID: <E1GsRwv-00034m-Qt@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/07 17:42:41

  Removed:     examples/glassfish/view/js  datePicker.js
  Log:
  minor fix


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 17:56:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 17:56:04 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1721 - in
	branches/Branch_Client_Failover_Experiment/tests: bin
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GsS9s-0003Ku-QS@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-07 17:55:59 -0500 (Thu, 07 Dec 2006)
New Revision: 1721

Modified:
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
Log:
more changes to make clustered tests work

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-07 22:55:59 UTC (rev 1721)
@@ -110,13 +110,19 @@
 fi
 
 if [ "$isRemote" = "true" ]; then
+
   export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED
-  $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file
 
+  #$reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file
+  $reldir/start-rmi-server -use-existent-test-classpath-file -index 0
+
   if [ "$TEST_CLUSTERED" = "true" ]; then
 
      # start the second remote server
      $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file -index 1
+
+     # start the third remote server
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file -index 2
   fi
 
 fi
@@ -125,11 +131,24 @@
 $JAVA_HOME/bin/java $JAVA_OPTS -cp "$CLASSPATH" \
 org.jboss.test.messaging.tools.junit.SelectiveTestRunner $TARGET_CLASS $TARGET_TEST
 
+
+#
+# stop the servers in the reverse order
+#
+
 if [ "$isRemote" = "true" ]; then
-  $reldir/stop-rmi-server -use-existent-test-classpath-file -index 1
 
-  # stop the second remote server
-  $reldir/stop-rmi-server -use-existent-test-classpath-file
+    if [ "$TEST_CLUSTERED" = "true" ]; then
 
+       # stop the third remote server
+       $reldir/stop-rmi-server -use-existent-test-classpath-file -index 2
+
+       # stop the second remote server
+       $reldir/stop-rmi-server -use-existent-test-classpath-file -index 1
+
+    fi
+
+  $reldir/stop-rmi-server -use-existent-test-classpath-file -index 0
+
 fi
 

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-07 22:55:59 UTC (rev 1721)
@@ -20,13 +20,11 @@
     SEP=":"
 fi
 
+index=0
+
 while [ "$1" != "" ]; do
     if [ "$1" = "-debug" ]; then
-        if [ $cygwin = false ]; then
-            JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=12348"
-        else
-            JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=y,address=rmiserver"
-        fi
+         debug=true
     elif [ "$1" = "-index" ]; then
         shift
         index=$1
@@ -36,9 +34,21 @@
     shift
 done
 
+echo
+echo "Starting remoting server $index ..."
+echo
+
+if [ "$debug" = true ]; then
+    if [ $cygwin = false ]; then
+        JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=12348"
+    else
+        JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=n,address=rmiserver_$index"
+    fi
+fi
+
 mkdir -p $reldir/../output/logs
 
-JAVA_OPTS="$JAVA_OPTS -Xmx768M -Dmodule.output=$reldir/../output -Dremote.test.suffix=-remote"
+JAVA_OPTS="$JAVA_OPTS -Xmx768M -Dmodule.output=$reldir/../output -Dremote.test.suffix=-remote-$index"
 
 if [ "$TEST_DATABASE" != "" ]; then
    JAVA_OPTS="$JAVA_OPTS -Dtest.database=$TEST_DATABASE"

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-07 22:55:59 UTC (rev 1721)
@@ -48,21 +48,21 @@
 
    // Attributes ----------------------------------------------------
 
+   protected Context ic;
    protected Context ic1;
    protected Context ic2;
-   protected Context ic3;
 
+   protected Queue queue;
    protected Queue queue1;
    protected Queue queue2;
-   protected Queue queue3;
 
+   protected Topic topic;
    protected Topic topic1;
    protected Topic topic2;
-   protected Topic topic3;
 
+   protected ConnectionFactory cf;
    protected ConnectionFactory cf1;
    protected ConnectionFactory cf2;
-   protected ConnectionFactory cf3;
 
    // Constructors --------------------------------------------------
 
@@ -87,32 +87,31 @@
 
       ServerManagement.log(ServerManagement.INFO,banner);
 
-
       try
       {
          startServer(0);
          startServer(1);
-//         startServer(2);
-//
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-//         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-//
+         startServer(2);
+
          log.info("Deployed destinations ok");
-//
+
+         ic = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+
+         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
          cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
          cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-//         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
-//
+
+         queue = (Queue)ic.lookup("queue/testDistributedQueue");
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-//         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
-//
+
+         topic = (Topic)ic.lookup("topic/testDistributedTopic");
          topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
          topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-//         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
-//
-//         drainQueues();
+
+         drainQueues();
       }
       catch (Exception e)
       {
@@ -121,12 +120,11 @@
       }
    }
 
-   private void startServer(int peer)
-      throws Exception
+   private void startServer(int serverIndex) throws Exception
    {
-      ServerManagement.start("all", peer);
-      ServerManagement.deployClusteredQueue("testDistributedQueue", peer);
-      ServerManagement.deployClusteredTopic("testDistributedTopic", peer);
+      ServerManagement.start("all", serverIndex);
+      ServerManagement.deployClusteredQueue("testDistributedQueue", serverIndex);
+      ServerManagement.deployClusteredTopic("testDistributedTopic", serverIndex);
    }
 
    protected void tearDown() throws Exception
@@ -140,17 +138,14 @@
          ServerManagement.log(ServerManagement.INFO,"Undeploying Server 1");
          ServerManagement.undeployQueue("testDistributedQueue", 1);
          ServerManagement.undeployTopic("testDistributedTopic", 1);
-//
-//         ServerManagement.undeployQueue("testDistributedQueue", 2);
-//         ServerManagement.undeployTopic("testDistributedTopic", 2);
 
          ServerManagement.log(ServerManagement.INFO,"Undeploying Server 2");
          ServerManagement.undeployQueue("testDistributedQueue", 2);
          ServerManagement.undeployTopic("testDistributedTopic", 2);
 
+         ic.close();
          ic1.close();
          ic2.close();
-//         ic3.close();
 
          super.tearDown();
       }
@@ -163,53 +158,64 @@
 
    protected void drainQueues() throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
-      Connection conn3 = null;
 
       try
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
          conn2 = cf2.createConnection();
-         conn3 = cf3.createConnection();
 
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
+         MessageConsumer cons = sess.createConsumer(queue);
          MessageConsumer cons1 = sess1.createConsumer(queue1);
          MessageConsumer cons2 = sess2.createConsumer(queue2);
-         MessageConsumer cons3 = sess3.createConsumer(queue3);
 
+         conn.start();
          conn1.start();
          conn2.start();
-         conn3.start();
 
          Message msg = null;
 
          do
          {
-            msg = cons1.receive(1000);
+            msg = cons.receive(1000);
          }
          while (msg != null);
 
          do
          {
-            msg = cons2.receive(1000);
+            msg = cons1.receive(1000);
          }
          while (msg != null);
 
          do
          {
-            msg = cons3.receive(1000);
+            msg = cons2.receive(1000);
          }
          while (msg != null);
       }
       finally
       {
-         if (conn1 != null) conn1.close();
-         if (conn2 != null) conn2.close();
-         if (conn3 != null) conn3.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
+
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-07 22:55:59 UTC (rev 1721)
@@ -135,136 +135,136 @@
     */
    protected void clusteredQueueLocalConsumer(boolean persistent) throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
-
       Connection conn2 = null;
 
-      Connection conn3 = null;
       try
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
 
-         conn3 = cf3.createConnection();
-
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
+         MessageConsumer cons = sess.createConsumer(queue);
          MessageConsumer cons1 = sess1.createConsumer(queue1);
-
          MessageConsumer cons2 = sess2.createConsumer(queue2);
 
-         MessageConsumer cons3 = sess3.createConsumer(queue3);
-
+         conn.start();
          conn1.start();
-
          conn2.start();
 
-         conn3.start();
+         // Send at node 0
 
-         //Send at node1
+         MessageProducer prod = sess.createProducer(queue);
 
-         MessageProducer prod1 = sess1.createProducer(queue1);
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
          final int NUM_MESSAGES = 100;
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess.createTextMessage("message" + i);
 
-            prod1.send(tm);
+            prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         Message m = cons2.receive(2000);
+         Message m = cons1.receive(2000);
 
          assertNull(m);
 
-         m = cons3.receive(2000);
+         m = cons2.receive(2000);
 
          assertNull(m);
 
-         // Send at node2
+         // Send at node 1
 
-         MessageProducer prod2 = sess2.createProducer(queue2);
+         MessageProducer prod1 = sess1.createProducer(queue1);
 
-         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess2.createTextMessage("message" + i);
+            TextMessage tm = sess1.createTextMessage("message" + i);
 
-            prod2.send(tm);
+            prod1.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons1.receive(2000);
+         m = cons.receive(2000);
 
          assertNull(m);
 
-         m = cons3.receive(2000);
+         m = cons2.receive(2000);
 
          assertNull(m);
 
-         // Send at node3
+         // Send at node 2
 
-         MessageProducer prod3 = sess3.createProducer(queue3);
+         MessageProducer prod2 = sess2.createProducer(queue2);
 
-         prod3.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess3.createTextMessage("message" + i);
+            TextMessage tm = sess2.createTextMessage("message" + i);
 
-            prod3.send(tm);
+            prod2.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons1.receive(2000);
+         m = cons.receive(2000);
 
          assertNull(m);
 
-         m = cons2.receive(2000);
+         m = cons1.receive(2000);
 
          assertNull(m);
       }
       finally
       {
-         if (conn1 != null) conn1.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
 
-         if (conn2 != null) conn2.close();
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
 
-         if (conn3 != null) conn3.close();
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 
@@ -276,59 +276,49 @@
     */
    private void clusteredTopicNonDurable(boolean persistent) throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
-
       Connection conn2 = null;
-
-      Connection conn3 = null;
       try
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
 
-         conn3 = cf3.createConnection();
-
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
+         MessageConsumer cons = sess.createConsumer(topic);
          MessageConsumer cons1 = sess1.createConsumer(topic1);
-
          MessageConsumer cons2 = sess2.createConsumer(topic2);
 
-         MessageConsumer cons3 = sess3.createConsumer(topic3);
+         MessageConsumer cons3 = sess.createConsumer(topic);
 
          MessageConsumer cons4 = sess1.createConsumer(topic1);
 
-         MessageConsumer cons5 = sess2.createConsumer(topic2);
-
+         conn.start();
          conn1.start();
-
          conn2.start();
 
-         conn3.start();
+         // Send at node 0
 
-         //Send at node1
+         MessageProducer prod = sess.createProducer(topic);
 
-         MessageProducer prod1 = sess1.createProducer(topic1);
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
          final int NUM_MESSAGES = 100;
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess.createTextMessage("message" + i);
 
-            prod1.send(tm);
+            prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons.receive(1000);
 
             assertNotNull(tm);
 
@@ -337,7 +327,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -346,7 +336,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
@@ -355,7 +345,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
@@ -364,7 +354,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons5.receive(1000);
+            TextMessage tm = (TextMessage)cons4.receive(1000);
 
             assertNotNull(tm);
 
@@ -373,17 +363,23 @@
       }
       finally
       {
-         if (conn1 != null) conn1.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
 
-         if (conn2 != null) conn2.close();
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
 
-         if (conn3 != null) conn3.close();
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 
-
-
-
    /*
     * Create non durable subscriptions on all nodes of the cluster.
     * Include some with selectors
@@ -391,52 +387,43 @@
     */
    private void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
-
       Connection conn2 = null;
 
-      Connection conn3 = null;
       try
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
 
-         conn3 = cf3.createConnection();
-
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
+         MessageConsumer cons = sess.createConsumer(topic);
          MessageConsumer cons1 = sess1.createConsumer(topic1);
-
          MessageConsumer cons2 = sess2.createConsumer(topic2);
 
-         MessageConsumer cons3 = sess3.createConsumer(topic3);
+         MessageConsumer cons3 = sess.createConsumer(topic, "COLOUR='red'");
 
-         MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='red'");
+         MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='blue'");
 
-         MessageConsumer cons5 = sess2.createConsumer(topic2, "COLOUR='blue'");
-
+         conn.start();
          conn1.start();
-
          conn2.start();
 
-         conn3.start();
+         // Send at node 0
 
-         //Send at node1
+         MessageProducer prod = sess.createProducer(topic);
 
-         MessageProducer prod1 = sess1.createProducer(topic1);
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
          final int NUM_MESSAGES = 100;
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess.createTextMessage("message" + i);
 
             int c = i % 3;
             if (c == 0)
@@ -448,12 +435,12 @@
                tm.setStringProperty("COLOUR", "blue");
             }
 
-            prod1.send(tm);
+            prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons.receive(1000);
 
             assertNotNull(tm);
 
@@ -462,7 +449,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -471,7 +458,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
@@ -484,7 +471,7 @@
 
             if (c == 0)
             {
-               TextMessage tm = (TextMessage)cons4.receive(1000);
+               TextMessage tm = (TextMessage)cons3.receive(1000);
 
                assertNotNull(tm);
 
@@ -498,7 +485,7 @@
 
             if (c == 1)
             {
-               TextMessage tm = (TextMessage)cons5.receive(1000);
+               TextMessage tm = (TextMessage)cons4.receive(1000);
 
                assertNotNull(tm);
 
@@ -508,11 +495,20 @@
       }
       finally
       {
-         if (conn1 != null) conn1.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
 
-         if (conn2 != null) conn2.close();
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
 
-         if (conn3 != null) conn3.close();
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 
@@ -526,91 +522,77 @@
     */
    private void clusteredTopicDurable(boolean persistent) throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
-
       Connection conn2 = null;
-
-      Connection conn3 = null;
       try
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
 
-         conn3 = cf3.createConnection();
-
+         conn.setClientID("wib1");
          conn1.setClientID("wib1");
-
          conn2.setClientID("wib1");
 
-         conn3.setClientID("wib1");
-
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          try
          {
-            sess1.unsubscribe("sub1");
+            sess.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub2");
+            sess1.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
          try
          {
-            sess3.unsubscribe("sub3");
+            sess2.unsubscribe("sub2");
          }
          catch (Exception ignore) {}
          try
          {
-            sess1.unsubscribe("sub4");
+            sess.unsubscribe("sub3");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub5");
+            sess1.unsubscribe("sub4");
          }
          catch (Exception ignore) {}
 
+         MessageConsumer cons = sess.createDurableSubscriber(topic, "sub");
          MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
-
          MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub2");
-
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub3");
-
+         MessageConsumer cons3 = sess.createDurableSubscriber(topic, "sub3");
          MessageConsumer cons4 = sess1.createDurableSubscriber(topic1, "sub4");
 
-         MessageConsumer cons5 = sess2.createDurableSubscriber(topic2, "sub5");
-
+         conn.start();
          conn1.start();
-
          conn2.start();
 
-         conn3.start();
+         // Send at node 0
 
-         //Send at node1
+         MessageProducer prod = sess.createProducer(topic);
 
-         MessageProducer prod1 = sess1.createProducer(topic1);
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
          final int NUM_MESSAGES = 100;
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
 
-            prod1.send(tm);
+            prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons.receive(1000);
 
             assertNotNull(tm);
 
@@ -619,7 +601,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -628,7 +610,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
@@ -637,7 +619,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
@@ -646,41 +628,42 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons5.receive(1000);
+            TextMessage tm = (TextMessage)cons4.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
+         cons.close();
          cons1.close();
-
          cons2.close();
-
          cons3.close();
-
          cons4.close();
 
-         cons5.close();
-
+         sess.unsubscribe("sub");
          sess1.unsubscribe("sub1");
-
          sess2.unsubscribe("sub2");
-
-         sess3.unsubscribe("sub3");
-
+         sess.unsubscribe("sub3");
          sess1.unsubscribe("sub4");
 
-         sess2.unsubscribe("sub5");
-
       }
       finally
       {
-         if (conn1 != null) conn1.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
 
-         if (conn2 != null) conn2.close();
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
 
-         if (conn3 != null) conn3.close();
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 
@@ -692,172 +675,166 @@
     */
    protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
-
       Connection conn2 = null;
-
-      Connection conn3 = null;
       try
+
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
 
-         conn3 = cf3.createConnection();
-
+         conn.setClientID("wib1");
          conn1.setClientID("wib1");
-
          conn2.setClientID("wib1");
 
-         conn3.setClientID("wib1");
-
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          try
          {
-            sess1.unsubscribe("sub1");
+            sess.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub1");
+            sess1.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess3.unsubscribe("sub1");
+            sess2.unsubscribe("sub");
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
+         MessageConsumer cons = sess.createDurableSubscriber(topic, "sub");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub");
 
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
-
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub1");
-
+         conn.start();
          conn1.start();
-
          conn2.start();
 
-         conn3.start();
+         // Send at node 0
 
-         //Send at node1
+         MessageProducer prod = sess.createProducer(topic);
 
-         MessageProducer prod1 = sess1.createProducer(topic1);
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
          final int NUM_MESSAGES = 100;
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess.createTextMessage("message" + i);
 
-            prod1.send(tm);
+            prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         Message m = cons2.receive(2000);
+         Message m = cons1.receive(2000);
 
          assertNull(m);
 
-         m = cons3.receive(2000);
+         m = cons2.receive(2000);
 
          assertNull(m);
 
-         // Send at node2
+         // Send at node 1
 
-         MessageProducer prod2 = sess2.createProducer(topic2);
+         MessageProducer prod1 = sess1.createProducer(topic1);
 
-         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess2.createTextMessage("message" + i);
 
-            prod2.send(tm);
+            prod1.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons1.receive(2000);
+         m = cons.receive(2000);
 
          assertNull(m);
 
-         m = cons3.receive(2000);
+         m = cons2.receive(2000);
 
          assertNull(m);
 
-         // Send at node3
+         // Send at node 2
 
-         MessageProducer prod3 = sess3.createProducer(topic3);
+         MessageProducer prod2 = sess2.createProducer(topic2);
 
-         prod3.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess3.createTextMessage("message" + i);
+            TextMessage tm = sess2.createTextMessage("message" + i);
 
-            prod3.send(tm);
+            prod2.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons1.receive(2000);
+         m = cons.receive(2000);
 
          assertNull(m);
 
-         m = cons2.receive(2000);
+         m = cons1.receive(2000);
 
          assertNull(m);
 
+         cons.close();
          cons1.close();
-
          cons2.close();
 
-         cons3.close();
+         // Need to unsubscribe on any node that the durable sub was created on
 
-         //Need to unsubscribe on any node that the durable sub was created on
-
-         sess1.unsubscribe("sub1");
-
-         sess2.unsubscribe("sub1");
-
-         sess3.unsubscribe("sub1");
+         sess.unsubscribe("sub");
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub");
       }
       finally
       {
-         if (conn1 != null) conn1.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
 
-         if (conn2 != null) conn2.close();
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
 
-         if (conn3 != null) conn3.close();
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 
@@ -870,68 +847,60 @@
     */
    protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
    {
+      Connection conn = null;
       Connection conn1 = null;
-
       Connection conn2 = null;
 
-      Connection conn3 = null;
       try
       {
+         conn = cf.createConnection();
          conn1 = cf1.createConnection();
-
          conn2 = cf2.createConnection();
 
-         conn3 = cf3.createConnection();
-
+         conn1.setClientID("wib1");
          conn2.setClientID("wib1");
 
-         conn3.setClientID("wib1");
-
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
          try
          {
-            sess2.unsubscribe("sub1");
+            sess1.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess3.unsubscribe("sub1");
+            sess2.unsubscribe("sub");
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub");
 
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub1");
-
+         conn1.start();
          conn2.start();
 
-         conn3.start();
+         // Send at node 0
 
-         //Send at node1
+         //Should round robin between the other 2 since there is no active consumer on sub  on node 0
 
-         //Should round robin between the other 2 since there is no active consumer on sub1 on node1
+         MessageProducer prod = sess.createProducer(topic);
 
-         MessageProducer prod1 = sess1.createProducer(topic1);
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
          final int NUM_MESSAGES = 100;
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess.createTextMessage("message" + i);
 
-            prod1.send(tm);
+            prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -940,29 +909,36 @@
 
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + (i * 2 + 1), tm.getText());
          }
 
+         cons1.close();
          cons2.close();
 
-         cons3.close();
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub");
 
-         sess2.unsubscribe("sub1");
-
-         sess3.unsubscribe("sub1");
-
       }
       finally
       {
-         if (conn1 != null) conn1.close();
+         if (conn != null)
+         {
+            conn.close();
+         }
 
-         if (conn2 != null) conn2.close();
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
 
-         if (conn3 != null) conn3.close();
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
       }
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-07 22:55:59 UTC (rev 1721)
@@ -273,9 +273,6 @@
          String databaseType = sc.getDatabaseType();
          String persistenceConfigFile;
 
-         log.info("DatabaseType=" + databaseType);
-         log.info("Clustered:" + clustered);
-         
          if (clustered && !databaseType.equals("hsqldb"))
          {
             //HSQL can't be used for clustered server peer - since it's not a shared database

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java	2006-12-07 22:55:59 UTC (rev 1721)
@@ -43,12 +43,14 @@
    // Attributes ----------------------------------------------------
 
    private InitialContextAccess ica;
+   private int serverIndex;
 
    // Constructors --------------------------------------------------
 
-   public RMINamingDelegate() throws Exception
+   public RMINamingDelegate(int serverIndex) throws Exception
    {
       super();
+      this.serverIndex = serverIndex;
       ica = new InitialContextAccess();
    }
 
@@ -87,7 +89,7 @@
       {
          if (ic == null)
          {
-            ic = new InitialContext(InVMInitialContextFactory.getJNDIEnvironment());
+            ic = new InitialContext(InVMInitialContextFactory.getJNDIEnvironment(serverIndex));
          }
          return ic;
       }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-07 22:09:40 UTC (rev 1720)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-07 22:55:59 UTC (rev 1721)
@@ -139,7 +139,7 @@
    public RMITestServer(int index) throws Exception
    {
       this.index = index;
-      namingDelegate = new RMINamingDelegate();
+      namingDelegate = new RMINamingDelegate(index);
       server = new RemoteTestServer(index);
    }
 



From msurtani at jboss.com  Thu Dec  7 19:19:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 07 Dec 2006 19:19:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1GsTT4-0006HV-SM@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/07 19:19:58

  Modified:    tests/functional/org/jboss/cache/optimistic  Tag:
                        Branch_JBossCache_1_4_0 RemoveBeforeCreateTest.java
  Log:
  Added a delay
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +3 -0      JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveBeforeCreateTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- RemoveBeforeCreateTest.java	6 Dec 2006 16:29:45 -0000	1.1.2.2
  +++ RemoveBeforeCreateTest.java	8 Dec 2006 00:19:58 -0000	1.1.2.3
  @@ -47,6 +47,9 @@
         c[0].put("/control", "key", "value");
         t.commit();
   
  +      // sleep to replicate - remember, this is repl_async
  +      TestingUtil.sleepThread(500);
  +
         assertEquals("value", c[0].get("/control", "key"));
         assertEquals("value", c[1].get("/control", "key"));
         
  
  
  


From norman.richards at jboss.com  Thu Dec  7 19:37:05 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 19:37:05 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui  ...
Message-ID: <E1GsTjd-0006bd-0E@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 19:37:04

  Modified:    src/ui/org/jboss/seam/ui  selectDate.js
  Log:
  update selectDate css
  
  Revision  Changes    Path
  1.2       +24 -105   jboss-seam/src/ui/org/jboss/seam/ui/selectDate.js
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: selectDate.js
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/selectDate.js,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- selectDate.js	7 Dec 2006 00:19:15 -0000	1.1
  +++ selectDate.js	8 Dec 2006 00:37:04 -0000	1.2
  @@ -1,60 +1,6 @@
   /**
  -This is a JavaScript library that will allow you to easily add some basic DHTML
  -drop-down datepicker functionality to your Notes forms. This script is not as
  -full-featured as others you may find on the Internet, but it's free, it's easy to
  -understand, and it's easy to change.
  -
  -You'll also want to include a stylesheet that makes the datepicker elements
  -look nice. An example one can be found in the database that this script was
  -originally released with, at:
  -
  -http://www.nsftools.com/tips/NotesTips.htm#datepicker
  -
  -I've tested this lightly with Internet Explorer 6 and Mozilla Firefox. I have no idea
  -how compatible it is with other browsers.
  -
  -version 1.5
  -December 4, 2005
  -Julian Robichaux -- http://www.nsftools.com
  -
  -HISTORY
  ---  version 1.0 (Sept. 4, 2004):
  -Initial release.
  -
  ---  version 1.1 (Sept. 5, 2004):
  -Added capability to define the date format to be used, either globally (using the
  -defaultDateSeparator and defaultDateFormat variables) or when the displayDatePicker
  -function is called.
  -
  ---  version 1.2 (Sept. 7, 2004):
  -Fixed problem where datepicker x-y coordinates weren't right inside of a table.
  -Fixed problem where datepicker wouldn't display over selection lists on a page.
  -Added a call to the datePickerClosed function (if one exists) after the datepicker
  -is closed, to allow the developer to add their own custom validation after a date
  -has been chosen. For this to work, you must have a function called datePickerClosed
  -somewhere on the page, that accepts a field object as a parameter. See the
  -example in the comments of the updateDateField function for more details.
  -
  ---  version 1.3 (Sept. 9, 2004)
  -Fixed problem where adding the <div> and <iFrame> used for displaying the datepicker
  -was causing problems on IE 6 with global variables that had handles to objects on
  -the page (I fixed the problem by adding the elements using document.createElement()
  -and document.body.appendChild() instead of document.body.innerHTML += ...).
  -
  ---  version 1.4 (Dec. 20, 2004)
  -Added "targetDateField.focus();" to the updateDateField function (as suggested
  -by Alan Lepofsky) to avoid a situation where the cursor focus is at the top of the
  -form after a date has been picked. Added "padding: 0px;" to the dpButton CSS
  -style, to keep the table from being so wide when displayed in Firefox.
  -
  --- version 1.5 (Dec 4, 2005)
  -Added display=none when datepicker is hidden, to fix problem where cursor is
  -not visible on input fields that are beneath the date picker. Added additional null
  -date handling for date errors in Safari when the date is empty. Added additional
  -error handling for iFrame creation, to avoid reported errors in Opera. Added
  -onMouseOver event for day cells, to allow color changes when the mouse hovers
  -over a cell (to make it easier to determine what cell you're over). Added comments
  -in the style sheet, to make it more clear what the different style elements are for.
  +Datepicker, based on the work of Julian Robichaux -- http://www.nsftools.com
  +history deleted for file size
   */
   
   var datePickerDivID = "datepicker";
  @@ -75,37 +21,7 @@
   var dateSeparator = defaultDateSeparator;
   var dateFormat = defaultDateFormat;
   
  -/**
  -This is the main function you'll call from the onClick event of a button.
  -Normally, you'll have something like this on your HTML page:
  -
  -Start Date: <input name="StartDate">
  -<input type=button value="select" onclick="displayDatePicker('StartDate');">
   
  -That will cause the datepicker to be displayed beneath the StartDate field and
  -any date that is chosen will update the value of that field. If you'd rather have the
  -datepicker display beneath the button that was clicked, you can code the button
  -like this:
  -
  -<input type=button value="select" onclick="displayDatePicker('StartDate', this);">
  -
  -So, pretty much, the first argument (dateFieldName) is a string representing the
  -name of the field that will be modified if the user picks a date, and the second
  -argument (displayBelowThisObject) is optional and represents an actual node
  -on the HTML document that the datepicker should be displayed below.
  -
  -In version 1.1 of this code, the dtFormat and dtSep variables were added, allowing
  -you to use a specific date format or date separator for a given call to this function.
  -Normally, you'll just want to set these defaults globally with the defaultDateSeparator
  -and defaultDateFormat variables, but it doesn't hurt anything to add them as optional
  -parameters here. An example of use is:
  -
  -<input type=button value="select" onclick="displayDatePicker('StartDate', false, 'dmy', '.');">
  -
  -This would display the datepicker beneath the StartDate field (because the
  -displayBelowThisObject parameter was false), and update the StartDate field with
  -the chosen value of the datepicker using a date format of dd.mm.yyyy
  -*/
   function displayDatePicker(dateFieldName, displayBelowThisObject, dtFormat, dtSep)
   {
     var targetDateField = document.getElementsByName (dateFieldName).item(0);
  @@ -162,7 +78,7 @@
       //document.body.innerHTML += "<div id='" + datePickerDivID + "' class='dpDiv'></div>";
       var newNode = document.createElement("div");
       newNode.setAttribute("id", datePickerDivID);
  -    newNode.setAttribute("class", "dpDiv");
  +    newNode.setAttribute("class", "seam-date");
       newNode.setAttribute("style", "visibility: hidden;");
       document.body.appendChild(newNode);
     }
  @@ -201,23 +117,26 @@
     // you can customize the table elements with a global CSS style sheet,
     // or by hardcoding style and formatting elements below
     var crlf = "\r\n";
  -  var TABLE = "<table cols='7' class='dpTable'>" + crlf;
  +  var TABLE = "<table cols='7'>" + crlf;
     var xTABLE = "</table>" + crlf;
  -  var TR = "<tr class='dpTR'>";
  -  var TR_title = "<tr class='dpTitleTR'>";
  -  var TR_days = "<tr class='dpDayTR'>";
  -  var TR_todaybutton = "<tr class='dpTodayButtonTR'>";
  +  var DIV = "<div>";
  +  var xDIV = "</div>";
  +
  +  var TR = "<tr class='seam-date-week'>";
  +  var TR_title = "<tr class='seam-date-title'>";
  +  var TR_days = "<tr class='seam-date-header'>";
  +  var TR_todaybutton = "<tr class='seam-date-footer'>";
     var xTR = "</tr>" + crlf;
  -  var TD = "<td class='dpTD' onmouseout='this.className=\"dpTD\";' onmouseover=' this.className=\"dpTDHover\";' ";    // leave this tag open, because we'll be adding an onclick event
  -  var TD_title = "<td colspan='5' class='dpTitleTD'>";
  -  var TD_buttons = "<td class='dpButtonTD'>";
  -  var TD_todaybutton = "<td colspan='7' class='dpTodayButtonTD'>";
  -  var TD_days = "<td class='dpDayTD'>";
  -  var TD_selected = "<td class='dpDayHighlightTD' onmouseout='this.className=\"dpDayHighlightTD\";' onmouseover='this.className=\"dpTDHover\";' ";    // leave this tag open, because we'll be adding an onclick event
  +
  +  var TD = "<td class='seam-date-day' onmouseout='this.className=\"seam-date-day\";' onmouseover='this.className=\"seam-date-hover\";' ";    // leave this tag open, because we'll be adding an onclick event
  +  var TD_selected = "<td class='seam-date-selected' onmouseout='this.className=\"seam-date-selected\";' onmouseover='this.className=\"seam-date-hover\";' ";    // leave this tag open, because we'll be adding an onclick event
  +  var TD_blank = "<td";
  +  var TD_title = "<td colspan='5'>";
  +  var TD_buttons = "<td>";
  +  var TD_todaybutton = "<td colspan='7' class='seam-date-button'>";
  +  var TD_days = "<td>";
     var xTD = "</td>" + crlf;
  -  var DIV_title = "<div class='dpTitleText'>";
  -  var DIV_selected = "<div class='dpDayHighlight'>";
  -  var xDIV = "</div>";
  +
    
     // start generating the code for the calendar table
     var html = TABLE;
  @@ -226,7 +145,7 @@
     // go back to a previous month or forward to the next month
     html += TR_title;
     html += TD_buttons + getButtonCode(dateFieldName, thisDay, -1, "&lt;") + xTD;
  -  html += TD_title + DIV_title + monthArrayLong[ thisDay.getMonth()] + " " + thisDay.getFullYear() + xDIV + xTD;
  +  html += TD_title + DIV + monthArrayLong[ thisDay.getMonth()] + " " + thisDay.getFullYear() + xDIV + xTD;
     html += TD_buttons + getButtonCode(dateFieldName, thisDay, 1, "&gt;") + xTD;
     html += xTR;
    
  @@ -241,7 +160,7 @@
    
     // first, the leading blanks
     for (i = 0; i < thisDay.getDay(); i++)
  -    html += TD + "> " + xTD;
  +    html += TD_blank + "> " + xTD;
    
     // now, the days of the month
     do {
  @@ -249,7 +168,7 @@
       TD_onclick = " onclick=\"updateDateField('" + dateFieldName + "', '" + getDateString(thisDay) + "');\">";
       
       if (dayNum == day)
  -      html += TD_selected + TD_onclick + DIV_selected + dayNum + xDIV + xTD;
  +      html += TD_selected + TD_onclick + dayNum + xTD;
       else
         html += TD + TD_onclick + dayNum + xTD;
       
  @@ -264,7 +183,7 @@
     // fill in any trailing blanks
     if (thisDay.getDay() > 0) {
       for (i = 6; i > thisDay.getDay(); i--)
  -      html += TD + "> " + xTD;
  +      html += TD_blank + "> " + xTD;
     }
     html += xTR;
    
  
  
  


From norman.richards at jboss.com  Thu Dec  7 19:37:05 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 19:37:05 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/stylesheet  ...
Message-ID: <E1GsTjd-0006bk-6o@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 19:37:05

  Modified:    seam-gen/view/stylesheet  theme.css
  Log:
  update selectDate css
  
  Revision  Changes    Path
  1.5       +64 -104   jboss-seam/seam-gen/view/stylesheet/theme.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: theme.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/stylesheet/theme.css,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- theme.css	7 Dec 2006 04:15:45 -0000	1.4
  +++ theme.css	8 Dec 2006 00:37:05 -0000	1.5
  @@ -139,17 +139,16 @@
   	border: 1px solid red;
   }
   
  -/* Date Picker 
  ------------------------------------------------ */
  +/* Seam Date Picker */
   
   /* the div that holds the date picker calendar */
  -.dpDiv {
  -	width: 300px;
  -	}
  +.seam-date {
  +
  +}
   
   
   /* the table (within the div) that holds the date picker calendar */
  -.dpTable {
  +.seam-date table {
   	font-family: Tahoma, Arial, Helvetica, sans-serif;
   	font-size: 12px;
   	text-align: center;
  @@ -158,91 +157,18 @@
   	background-color: #FFFFFF;
   	border: 1px solid #AAAAAA;
   	margin-top: 5px;
  -	}
  -
  -
  -/* a table row that holds date numbers (either blank or 1-31) */
  -.dpTR {
  -	}
  -
  -
  -/* the top table row that holds the month, year, and forward/backward buttons */
  -.dpTitleTR {
  -	}
  -
  -
  -/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTR {
  -	}
  -
  -
  -/* the bottom table row, that has the "This Month" and "Close" buttons */
  -.dpTodayButtonTR {
  -	}
  -
  -
  -/* a table cell that holds a date number (either blank or 1-31) */
  -.dpTD {
  -	border: 1px solid #ece9d8;
  -	width: 14%;
  -	}
  -
  -
  -/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  -.dpDayHighlightTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  -.dpTDHover {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	cursor: pointer;
  -	color: red;
  -	}
  -
  -
  -/* the table cell that holds the name of the month and the year */
  -.dpTitleTD {
  -	}
  -
  -
  -/* a table cell that holds one of the forward/backward buttons */
  -.dpButtonTD {
  -	}
  -
  -
  -/* the table cell that holds the "This Month" or "Close" button at the bottom */
  -.dpTodayButtonTD {
  -	}
  -
  -
  -/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	color: white;
  -	}
  +}
   
   
  -/* additional style information for the text that indicates the month and year */
  -.dpTitleText {
  +.seam-date-title div {
   	font-size: 12px;
   	color: gray;
   	font-weight: bold;
  -	}
  -
  -
  -/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  -.dpDayHighlight {
  -	font-weight: bold;
  -	}
  +}
   
   
   /* the forward/backward buttons at the top */
  -.dpButton {
  +.seam-date-title button{
   	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
   	font-size: 10px;
   	color: gray;
  @@ -250,17 +176,51 @@
   	font-weight: bold;
   	padding: 0px;
   	border: 1px solid #AAAAAA;
  -	}
  +}
   
   
   /* the "This Month" and "Close" buttons at the bottom */
  -.dpTodayButton {
  +.seam-date-footer {
  +	display: none;
  +}
  +
  +.seam-date-footer button {
   	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
   	font-size: 10px;
   	color: gray;
   	background: #FFFFFF;
   	font-weight: bold;
   	border: 1px solid #AAAAAA;
  -	display:none;
  -	}
  +}
  +
  +
  +
  +/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  +.seam-date-header td {
  +    background-color: #CCCCCC;
  +    border: 1px solid #AAAAAA;
  +    color: white;
  +}
  +
  +
  +
  +/* a table cell that holds a date number (either blank or 1-31) */
  +.seam-date-week td.seam-date-day {
  +    border: 1px solid #ece9d8;	
  +}
  +
  +/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  +.seam-date-week td.seam-date-hover  {
  +    background-color: #CCCCCC;
  +    border: 1px solid #AAAAAA;
  +    cursor: pointer;
  +    color: red;
  +}
  +
   
  +/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  +.seam-date-week td.seam-date-selected {
  +    background-color: #CCCCCC;        
  +    border: 1px solid #AAAAAA;
  +    font-weight: bold;
  +}
  
  
  


From norman.richards at jboss.com  Thu Dec  7 19:38:14 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 19:38:14 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view/css   ...
Message-ID: <E1GsTkk-0006e7-U1@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 19:38:14

  Modified:    examples/booking/view/css   screen.css
  Added:       examples/booking/view/css   date.css
  Log:
  selectDate css
  
  Revision  Changes    Path
  1.8       +0 -123    jboss-seam/examples/booking/view/css/screen.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: screen.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/css/screen.css,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- screen.css	22 Nov 2006 10:00:34 -0000	1.7
  +++ screen.css	8 Dec 2006 00:38:14 -0000	1.8
  @@ -263,126 +263,3 @@
   #pgHome input[type="submit"] {
   	height: 30px;
   }
  -/* Date Picker 
  ------------------------------------------------ */
  -
  -/* the div that holds the date picker calendar */
  -.dpDiv {
  -	}
  -
  -
  -/* the table (within the div) that holds the date picker calendar */
  -.dpTable {
  -	font-family: Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 12px;
  -	text-align: center;
  -	color: #505050;
  -	background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
  -	background-color: #FFFFFF;
  -	border: 1px solid #AAAAAA;
  -	margin-top: 5px;
  -	}
  -
  -
  -/* a table row that holds date numbers (either blank or 1-31) */
  -.dpTR {
  -	}
  -
  -
  -/* the top table row that holds the month, year, and forward/backward buttons */
  -.dpTitleTR {
  -	}
  -
  -
  -/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTR {
  -	}
  -
  -
  -/* the bottom table row, that has the "This Month" and "Close" buttons */
  -.dpTodayButtonTR {
  -	}
  -
  -
  -/* a table cell that holds a date number (either blank or 1-31) */
  -.dpTD {
  -	border: 1px solid #ece9d8;
  -	}
  -
  -
  -/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  -.dpDayHighlightTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  -.dpTDHover {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	cursor: pointer;
  -	color: red;
  -	}
  -
  -
  -/* the table cell that holds the name of the month and the year */
  -.dpTitleTD {
  -	}
  -
  -
  -/* a table cell that holds one of the forward/backward buttons */
  -.dpButtonTD {
  -	}
  -
  -
  -/* the table cell that holds the "This Month" or "Close" button at the bottom */
  -.dpTodayButtonTD {
  -	}
  -
  -
  -/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	color: white;
  -	}
  -
  -
  -/* additional style information for the text that indicates the month and year */
  -.dpTitleText {
  -	font-size: 12px;
  -	color: gray;
  -	font-weight: bold;
  -	}
  -
  -
  -/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  -.dpDayHighlight {
  -	font-weight: bold;
  -	}
  -
  -
  -/* the forward/backward buttons at the top */
  -.dpButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	padding: 0px;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the "This Month" and "Close" buttons at the bottom */
  -.dpTodayButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	border: 1px solid #AAAAAA;
  -	display:none;
  -	}
  -
  
  
  
  1.1      date: 2006/12/08 00:38:14;  author: nrichards;  state: Exp;jboss-seam/examples/booking/view/css/date.css
  
  Index: date.css
  ===================================================================
  /* Seam Date Picker */
  
  /* the div that holds the date picker calendar */
  .seam-date {
  
  }
  
  
  /* the table (within the div) that holds the date picker calendar */
  .seam-date table {
      font-family: Tahoma, Arial, Helvetica, sans-serif;
      font-size: 12px;
      text-align: center;
      color: #505050;
      background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
      background-color: #FFFFFF;
      border: 1px solid #AAAAAA;
      margin-top: 5px;
  }
  
  
  .seam-date-title div {
      font-size: 12px;
      color: gray;
      font-weight: bold;
  }
  
  
  /* the forward/backward buttons at the top */
  .seam-date-title button{
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      padding: 0px;
      border: 1px solid #AAAAAA;
  }
  
  
  /* the "This Month" and "Close" buttons at the bottom */
  .seam-date-footer {
  	display: none;
  }
  
  .seam-date-footer button {
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      border: 1px solid #AAAAAA;
  }
  
  
  
  /* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  .seam-date-header td {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      color: white;
  }
  
  
  
  /* a table cell that holds a date number (either blank or 1-31) */
  .seam-date-week td.seam-date-day {
      border: 1px solid #ece9d8;	
  }
  
  /* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  .seam-date-week td.seam-date-hover  {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      cursor: pointer;
      color: red;
  }
  
  
  /* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  .seam-date-week td.seam-date-selected {
      background-color: #CCCCCC;        
      border: 1px solid #AAAAAA;
      font-weight: bold;
  }
  
  
  


From norman.richards at jboss.com  Thu Dec  7 19:38:15 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 19:38:15 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view  ...
Message-ID: <E1GsTkl-0006eE-1J@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 19:38:15

  Modified:    examples/booking/view  template.xhtml
  Log:
  selectDate css
  
  Revision  Changes    Path
  1.9       +2 -1      jboss-seam/examples/booking/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/template.xhtml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- template.xhtml	23 Nov 2006 22:50:38 -0000	1.8
  +++ template.xhtml	8 Dec 2006 00:38:15 -0000	1.9
  @@ -6,6 +6,7 @@
   	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
   	<title>JBoss Suites: Seam Framework</title>
   	<link href="css/screen.css" rel="stylesheet" type="text/css" />
  +	<link href="css/date.css" rel="stylesheet" type="text/css" />
   </head>
   <body>
   
  
  
  


From norman.richards at jboss.com  Thu Dec  7 19:38:15 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 19:38:15 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/view  ...
Message-ID: <E1GsTkl-0006eL-6D@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 19:38:15

  Modified:    examples/seampay/view  date.css
  Log:
  selectDate css
  
  Revision  Changes    Path
  1.2       +39 -77    jboss-seam/examples/seampay/view/date.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: date.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/view/date.css,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- date.css	7 Dec 2006 00:24:19 -0000	1.1
  +++ date.css	8 Dec 2006 00:38:15 -0000	1.2
  @@ -1,13 +1,13 @@
  -/* Date Picker 
  ------------------------------------------------ */
  +/* Seam Date Picker */
   
   /* the div that holds the date picker calendar */
  -.dpDiv {
  +.seam-date {
  +
   }
   
   
   /* the table (within the div) that holds the date picker calendar */
  -.dpTable {
  +.seam-date table {
       font-family: Tahoma, Arial, Helvetica, sans-serif;
       font-size: 12px;
       text-align: center;
  @@ -19,105 +19,67 @@
   }
   
   
  -/* a table row that holds date numbers (either blank or 1-31) */
  -.dpTR {
  -}
  -
  -
  -/* the top table row that holds the month, year, and forward/backward buttons */
  -.dpTitleTR {
  -}
  -
  -
  -/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTR {
  -}
  -
  -
  -/* the bottom table row, that has the "This Month" and "Close" buttons */
  -.dpTodayButtonTR {
  -}
  -
  -
  -/* a table cell that holds a date number (either blank or 1-31) */
  -.dpTD {
  -    border: 1px solid #ece9d8;
  -}
  -
  -
  -/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  -.dpDayHighlightTD {
  -    background-color: #CCCCCC;
  -    border: 1px solid #AAAAAA;
  +.seam-date-title div {
  +    font-size: 12px;
  +    color: gray;
  +    font-weight: bold;
   }
   
   
  -/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  -.dpTDHover {
  -    background-color: #CCCCCC;
  +/* the forward/backward buttons at the top */
  +.seam-date-title button{
  +    font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  +    font-size: 10px;
  +    color: gray;
  +    background: #FFFFFF;
  +    font-weight: bold;
  +    padding: 0px;
       border: 1px solid #AAAAAA;
  -    cursor: pointer;
  -    color: red;
   }
   
   
  -/* the table cell that holds the name of the month and the year */
  -.dpTitleTD {
  +/* the "This Month" and "Close" buttons at the bottom */
  +.seam-date-footer {
  +	display: none;
   }
   
  -
  -/* a table cell that holds one of the forward/backward buttons */
  -.dpButtonTD {
  +.seam-date-footer button {
  +    font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  +    font-size: 10px;
  +    color: gray;
  +    background: #FFFFFF;
  +    font-weight: bold;
  +    border: 1px solid #AAAAAA;
   }
   
   
  -/* the table cell that holds the "This Month" or "Close" button at the bottom */
  -.dpTodayButtonTD {
  -}
  -
   
   /* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTD {
  +.seam-date-header td {
       background-color: #CCCCCC;
       border: 1px solid #AAAAAA;
       color: white;
   }
   
   
  -/* additional style information for the text that indicates the month and year */
  -.dpTitleText {
  -    font-size: 12px;
  -    color: gray;
  -    font-weight: bold;
  -}
   
  -
  -/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  -.dpDayHighlight {
  -    font-weight: bold;
  +/* a table cell that holds a date number (either blank or 1-31) */
  +.seam-date-week td.seam-date-day {
  +    border: 1px solid #ece9d8;	
   }
   
  -
  -/* the forward/backward buttons at the top */
  -.dpButton {
  -    font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -    font-size: 10px;
  -    color: gray;
  -    background: #FFFFFF;
  -    font-weight: bold;
  -    padding: 0px;
  +/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  +.seam-date-week td.seam-date-hover  {
  +    background-color: #CCCCCC;
       border: 1px solid #AAAAAA;
  +    cursor: pointer;
  +    color: red;
   }
   
   
  -/* the "This Month" and "Close" buttons at the bottom */
  -.dpTodayButton {
  -    font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -    font-size: 10px;
  -    color: gray;
  -    background: #FFFFFF;
  -    font-weight: bold;
  +/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  +.seam-date-week td.seam-date-selected {
  +    background-color: #CCCCCC;        
       border: 1px solid #AAAAAA;
  -    display:none;
  +    font-weight: bold;
   }
  -
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 19:49:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 19:49:17 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1722 - in
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering:
	. base
Message-ID: <E1GsTvR-0006qC-MJ@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-07 19:49:15 -0500 (Thu, 07 Dec 2006)
New Revision: 1722

Added:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Removed:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
Log:
minor clustering test refactoring; placing the base in 'base' and adding some simple tests

Deleted: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-07 22:55:59 UTC (rev 1721)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ClusteringBase.java	2006-12-08 00:49:15 UTC (rev 1722)
@@ -1,226 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
-
-import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
-import javax.jms.Message;
-import javax.jms.MessageConsumer;
-import javax.jms.Queue;
-import javax.jms.Session;
-import javax.jms.Topic;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import org.jboss.test.messaging.MessagingTestCase;
-import org.jboss.test.messaging.tools.ServerManagement;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- * $Id:$
- */
-public class ClusteringBase extends MessagingTestCase
-{
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   protected Context ic;
-   protected Context ic1;
-   protected Context ic2;
-
-   protected Queue queue;
-   protected Queue queue1;
-   protected Queue queue2;
-
-   protected Topic topic;
-   protected Topic topic1;
-   protected Topic topic2;
-
-   protected ConnectionFactory cf;
-   protected ConnectionFactory cf1;
-   protected ConnectionFactory cf2;
-
-   // Constructors --------------------------------------------------
-
-   public ClusteringBase(String name)
-   {
-      super(name);
-   }
-
-   // Public --------------------------------------------------------
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-
-      String banner =
-         "####################################################### Start " +
-         (isRemote() ? "REMOTE" : "IN-VM") + " test: " + getName();
-
-      ServerManagement.log(ServerManagement.INFO,banner);
-
-      try
-      {
-         startServer(0);
-         startServer(1);
-         startServer(2);
-
-         log.info("Deployed destinations ok");
-
-         ic = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-
-         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
-         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-
-         queue = (Queue)ic.lookup("queue/testDistributedQueue");
-         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
-         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-
-         topic = (Topic)ic.lookup("topic/testDistributedTopic");
-         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
-         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-
-         drainQueues();
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
-   }
-
-   private void startServer(int serverIndex) throws Exception
-   {
-      ServerManagement.start("all", serverIndex);
-      ServerManagement.deployClusteredQueue("testDistributedQueue", serverIndex);
-      ServerManagement.deployClusteredTopic("testDistributedTopic", serverIndex);
-   }
-
-   protected void tearDown() throws Exception
-   {
-      try
-      {
-         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 0");
-         ServerManagement.undeployQueue("testDistributedQueue", 0);
-         ServerManagement.undeployTopic("testDistributedTopic", 0);
-
-         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 1");
-         ServerManagement.undeployQueue("testDistributedQueue", 1);
-         ServerManagement.undeployTopic("testDistributedTopic", 1);
-
-         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 2");
-         ServerManagement.undeployQueue("testDistributedQueue", 2);
-         ServerManagement.undeployTopic("testDistributedTopic", 2);
-
-         ic.close();
-         ic1.close();
-         ic2.close();
-
-         super.tearDown();
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
-   }
-
-   protected void drainQueues() throws Exception
-   {
-      Connection conn = null;
-      Connection conn1 = null;
-      Connection conn2 = null;
-
-      try
-      {
-         conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
-
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         MessageConsumer cons = sess.createConsumer(queue);
-         MessageConsumer cons1 = sess1.createConsumer(queue1);
-         MessageConsumer cons2 = sess2.createConsumer(queue2);
-
-         conn.start();
-         conn1.start();
-         conn2.start();
-
-         Message msg = null;
-
-         do
-         {
-            msg = cons.receive(1000);
-         }
-         while (msg != null);
-
-         do
-         {
-            msg = cons1.receive(1000);
-         }
-         while (msg != null);
-
-         do
-         {
-            msg = cons2.receive(1000);
-         }
-         while (msg != null);
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-      }
-   }
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-07 22:55:59 UTC (rev 1721)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 00:49:15 UTC (rev 1722)
@@ -40,6 +40,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 
 /**
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
@@ -47,7 +48,7 @@
  *
  * $Id:$
  */
-public class HATest extends ClusteringBase
+public class HATest extends ClusteringTestBase
 {
 
    // Constants -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-07 22:55:59 UTC (rev 1721)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 00:49:15 UTC (rev 1722)
@@ -21,6 +21,8 @@
  */
 package org.jboss.test.messaging.jms.clustering;
 
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+
 import javax.jms.*;
 
 /**
@@ -35,7 +37,7 @@
  * $Id$
  *
  */
-public class ManualClusteringTest extends ClusteringBase
+public class ManualClusteringTest extends ClusteringTestBase
 {
 
    // Constants -----------------------------------------------------

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-07 22:55:59 UTC (rev 1721)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 00:49:15 UTC (rev 1722)
@@ -0,0 +1,152 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+
+import javax.jms.Connection;
+import javax.jms.Session;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageListener;
+import javax.jms.Message;
+import javax.jms.TextMessage;
+
+import EDU.oswego.cs.dl.util.concurrent.Slot;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class SimpleClusteringTest extends ClusteringTestBase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public SimpleClusteringTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testDistributedTopic() throws Exception
+   {
+      Connection conn = null;
+      Connection conn1 = null;
+      Connection conn2 = null;
+
+      try
+      {
+         conn = cf.createConnection();
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+
+         Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session s1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session s2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         SimpleMessageListener ml = new SimpleMessageListener();
+         SimpleMessageListener ml1 = new SimpleMessageListener();
+         SimpleMessageListener ml2 = new SimpleMessageListener();
+
+         s.createConsumer(topic).setMessageListener(ml);
+         s1.createConsumer(topic).setMessageListener(ml1);
+         s2.createConsumer(topic).setMessageListener(ml2);
+
+         conn.start();
+         conn1.start();
+         conn2.start();
+
+         s.createProducer(topic).send(s.createTextMessage("boom"));
+
+         TextMessage rm = null;
+
+         rm = ml.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = ml1.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = ml2.poll(5000);
+         assertEquals("boom", rm.getText());
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+      }
+
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+   private class SimpleMessageListener implements MessageListener
+   {
+      private Slot slot;
+
+      SimpleMessageListener()
+      {
+         slot = new Slot();
+      }
+
+      public void onMessage(Message message)
+      {
+         try
+         {
+            slot.put(message);
+         }
+         catch(InterruptedException e)
+         {
+            log.error(e);
+         }
+      }
+
+      public TextMessage poll(long timeout) throws InterruptedException
+      {
+         return (TextMessage)slot.poll(timeout);
+      }
+   }
+}

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-07 22:55:59 UTC (rev 1721)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 00:49:15 UTC (rev 1722)
@@ -0,0 +1,226 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering.base;
+
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.Queue;
+import javax.jms.Session;
+import javax.jms.Topic;
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+/**
+ * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ * $Id:$
+ */
+public class ClusteringTestBase extends MessagingTestCase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   protected Context ic;
+   protected Context ic1;
+   protected Context ic2;
+
+   protected Queue queue;
+   protected Queue queue1;
+   protected Queue queue2;
+
+   protected Topic topic;
+   protected Topic topic1;
+   protected Topic topic2;
+
+   protected ConnectionFactory cf;
+   protected ConnectionFactory cf1;
+   protected ConnectionFactory cf2;
+
+   // Constructors --------------------------------------------------
+
+   public ClusteringTestBase(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      String banner =
+         "####################################################### Start " +
+         (isRemote() ? "REMOTE" : "IN-VM") + " test: " + getName();
+
+      ServerManagement.log(ServerManagement.INFO,banner);
+
+      try
+      {
+         startServer(0);
+         startServer(1);
+         startServer(2);
+
+         log.info("Deployed destinations ok");
+
+         ic = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+
+         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
+         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
+
+         queue = (Queue)ic.lookup("queue/testDistributedQueue");
+         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
+         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
+
+         topic = (Topic)ic.lookup("topic/testDistributedTopic");
+         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
+         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
+
+         drainQueues();
+      }
+      catch (Exception e)
+      {
+         e.printStackTrace();
+         throw e;
+      }
+   }
+
+   protected void tearDown() throws Exception
+   {
+      try
+      {
+         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 0");
+         ServerManagement.undeployQueue("testDistributedQueue", 0);
+         ServerManagement.undeployTopic("testDistributedTopic", 0);
+
+         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 1");
+         ServerManagement.undeployQueue("testDistributedQueue", 1);
+         ServerManagement.undeployTopic("testDistributedTopic", 1);
+
+         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 2");
+         ServerManagement.undeployQueue("testDistributedQueue", 2);
+         ServerManagement.undeployTopic("testDistributedTopic", 2);
+
+         ic.close();
+         ic1.close();
+         ic2.close();
+
+         super.tearDown();
+      }
+      catch (Exception e)
+      {
+         e.printStackTrace();
+         throw e;
+      }
+   }
+
+   protected void drainQueues() throws Exception
+   {
+      Connection conn = null;
+      Connection conn1 = null;
+      Connection conn2 = null;
+
+      try
+      {
+         conn = cf.createConnection();
+         conn1 = cf1.createConnection();
+         conn2 = cf2.createConnection();
+
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageConsumer cons = sess.createConsumer(queue);
+         MessageConsumer cons1 = sess1.createConsumer(queue1);
+         MessageConsumer cons2 = sess2.createConsumer(queue2);
+
+         conn.start();
+         conn1.start();
+         conn2.start();
+
+         Message msg = null;
+
+         do
+         {
+            msg = cons.receive(1000);
+         }
+         while (msg != null);
+
+         do
+         {
+            msg = cons1.receive(1000);
+         }
+         while (msg != null);
+
+         do
+         {
+            msg = cons2.receive(1000);
+         }
+         while (msg != null);
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+      }
+   }
+
+   // Private -------------------------------------------------------
+
+   private void startServer(int serverIndex) throws Exception
+   {
+      ServerManagement.start("all", serverIndex);
+      ServerManagement.deployClusteredQueue("testDistributedQueue", serverIndex);
+      ServerManagement.deployClusteredTopic("testDistributedTopic", serverIndex);
+   }
+
+   // Inner classes -------------------------------------------------
+
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 20:08:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 20:08:14 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1723 - in
	branches/Branch_Client_Failover_Experiment/tests: .
	src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GsUDm-0007JV-HS@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-07 20:08:12 -0500 (Thu, 07 Dec 2006)
New Revision: 1723

Modified:
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
Log:
fixed ant clustering-tests. Now clustering tests can be run from and, not only with runtest

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 00:49:15 UTC (rev 1722)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 01:08:12 UTC (rev 1723)
@@ -283,10 +283,11 @@
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
          <sysproperty key="test.server.index" value="${test.server.index}"/>
          <sysproperty key="module.output" value="${tests.output}"/>
-         <sysproperty key="remote.test.suffix" value="-remote"/>
+         <sysproperty key="remote.test.suffix" value="-remote-${test.server.index}"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${clustering.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.clustered" value="true"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=rmiserver"/>
          -->
@@ -662,6 +663,13 @@
       <echo message="Running clustering tests, fork=${junit.fork}, junit.batchtest.fork=${junit.batchtest.fork}"/>
       <echo message=""/>
 
+      <!--
+
+           By default, clustered tests are run in a "remote" configuration (the clustered
+           nodes physically live in different VMs. If you want to test a co-located clustered
+           configuration, use bin/runtest -clustered
+      -->
+
       <junit printsummary="${junit.printsummary}"
              fork="${junit.fork}"
              includeantruntime="yes"
@@ -675,21 +683,23 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${clustering.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.clustered" value="true"/>
          <jvmarg value="-Xmx512M"/>
-         <!--
-         <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
-         -->
+
          <classpath>
             <path refid="test.execution.classpath"/>
-
-            <!-- Add this when http://jira.jboss.org/jira/browse/JBAS-2554 is done -->
             <!--
-            <path refid="jboss.test.classpath"/>
+                Add this when http://jira.jboss.org/jira/browse/JBAS-2554 is done
             -->
+            <!--
+                 <path refid="jboss.test.classpath"/>
+            -->
          </classpath>
 
-         <!-- Use this when http://jira.jboss.org/jira/browse/JBAS-2554 is done -->
          <!--
+              Use this when http://jira.jboss.org/jira/browse/JBAS-2554 is done
+         -->
+         <!--
          <sysproperty key="jboss-junit-configuration" value="Remote"/>
          <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter"
             usefile="${junit.formatter.usefile}" extension="-Remote.xml"/>
@@ -706,18 +716,27 @@
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
                <include name="**/jms/clustering/ManualClusteringTest.class"/>
+               <!--
+               <include name="**/jms/clustering/SimpleClusteringTest.class"/>
+               -->
             </fileset>
          </batchtest>
       </junit>
 
+      <!--
+          Stop the servers in the reverse order, so the VM that runs the RMI registry dies last.
+      -->
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.server.index" value="0"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
          <param name="test.server.index" value="1"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.server.index" value="2"/>
+         <param name="test.server.index" value="0"/>
       </antcall>
 
    </target>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 00:49:15 UTC (rev 1722)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 01:08:12 UTC (rev 1723)
@@ -10,7 +10,6 @@
 
 import javax.jms.Connection;
 import javax.jms.Session;
-import javax.jms.MessageConsumer;
 import javax.jms.MessageListener;
 import javax.jms.Message;
 import javax.jms.TextMessage;



From brian.stansberry at jboss.com  Thu Dec  7 20:24:59 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 20:24:59 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GsUTz-0007Ze-HN@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 20:24:59

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Don't refer to internal field in Javadoc
  Default mux stack should be udp
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.29 +6 -5      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.28
  retrieving revision 1.195.2.29
  diff -u -b -r1.195.2.28 -r1.195.2.29
  --- TreeCache.java	5 Dec 2006 17:16:35 -0000	1.195.2.28
  +++ TreeCache.java	8 Dec 2006 01:24:59 -0000	1.195.2.29
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.28 2006/12/05 17:16:35 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.29 2006/12/08 01:24:59 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -158,9 +158,9 @@
      protected String mux_serviceName = null;
   
      /**
  -    * The JGroups multiplexer stack name, default is "fc-fast-minimalthreads"
  +    * The JGroups multiplexer stack name, default is "udp"
       */
  -   protected String mux_stackName = "fc-fast-minimalthreads";
  +   protected String mux_stackName = "udp";
   
      /**
       * Is this cache using a channel from the JGroups multiplexer
  @@ -5751,8 +5751,9 @@
       * Whenever nodes are created, and the global transaction is not null, the created
       * nodes have to be added to the transaction's {@link TransactionEntry}
       * field.<br>
  -    * When a lock is acquired on a node, a reference to the lock has to be added to the list
  -    * of locked nodes in the {@link TransactionEntry#locks} field.
  +    * When a lock is acquired on a node, a reference to the lock has to be 
  +    * {@link TransactionEntry#addLock(IdentityLock) added to the list of locked nodes} 
  +    * in the {@link TransactionEntry}.
       * <p>This operation will also apply different locking to the tree nodes, depending on
       * <tt>operation_type</tt>. If it is <tt>read</tt> type, all nodes will be acquired with
       * read lock. Otherwise, the operation is <tt>write</tt> type, all parent nodes will be acquired
  
  
  


From brian.stansberry at jboss.com  Thu Dec  7 20:26:15 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 20:26:15 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GsUVD-0007cj-O2@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 20:26:15

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TransactionEntry.java
  Log:
  [JBCACHE-874] Store locks in a LinkedHashSet
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.2   +22 -23    JBossCache/src/org/jboss/cache/TransactionEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionEntry.java,v
  retrieving revision 1.8.2.1
  retrieving revision 1.8.2.2
  diff -u -b -r1.8.2.1 -r1.8.2.2
  --- TransactionEntry.java	5 Dec 2006 00:01:51 -0000	1.8.2.1
  +++ TransactionEntry.java	8 Dec 2006 01:26:15 -0000	1.8.2.2
  @@ -17,6 +17,7 @@
   import java.util.ArrayList;
   import java.util.Collection;
   import java.util.Iterator;
  +import java.util.LinkedHashSet;
   import java.util.LinkedList;
   import java.util.List;
   import java.util.ListIterator;
  @@ -35,7 +36,7 @@
    * </ul>
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.8.2.1 $
  + * @version $Revision: 1.8.2.2 $
    */
   public class TransactionEntry {
   
  @@ -62,9 +63,12 @@
      protected List undo_list=new LinkedList();
   
      /**
  -    * List<IdentityLock> of locks acquired by the transaction ({@link IdentityLock})
  +    * LinkedHashSet<IdentityLock> of locks acquired by the transaction We use
  +    * a LinkedHashSet because we need efficient Set semantics (same lock can
  +    * be added multiple times) but also need guaranteed ordering for use
  +    * by lock release code (see JBCCACHE-874).
       */
  -   protected List locks = new LinkedList();
  +   private LinkedHashSet locks = new LinkedHashSet();
   
      /**
       * A list of dummy uninitialised nodes created by the cache loader interceptor to load data for a
  @@ -163,13 +167,10 @@
      public void addLock(IdentityLock l) {
         if(l != null) {
            synchronized(locks) {
  -             if (!locks.contains(l))
  -             {
                    locks.add(l);
                }
            }
         }
  -   }
   
      /**
       * Add multiple locks to the lock list.
  @@ -177,25 +178,22 @@
       */
      public void addLocks(Collection newLocks) {
         if(newLocks != null) {
  -         IdentityLock tmp;
            synchronized(locks) {
  -            for(Iterator it=newLocks.iterator(); it.hasNext();) {
  -               tmp=(IdentityLock)it.next();
  -                if (!locks.contains(tmp))
  -                {
  -                    locks.add(tmp);
  -                }
  -            }
  +            locks.addAll(newLocks);
            }
         }
      }
   
      /**
       * Returns the locks in use.
  -    * Note:  This list may be concurrently modified.
  +    * 
  +    * @return a defensive copy of the internal data structure.
       */
      public List getLocks() {
  -      return locks;
  +      synchronized(locks)
  +      {
  +         return new ArrayList(locks);
  +      }
      }
   
      /**
  @@ -214,16 +212,17 @@
       * Clears the list of locks held.
       */
      public void releaseAllLocksLIFO(Object owner) {
  -      // I guess a copy would work as well
  -      // This seems fairly safe though
  +      
         synchronized (locks) {
  -         for (ListIterator i = locks.listIterator(locks.size()); i.hasPrevious();) {
  -            IdentityLock lock = (IdentityLock)i.previous();
  +         // Copying out to an array is faster than creating an ArrayList and iterating,
  +         // since list creation will just copy out to an array internally
  +         IdentityLock[] lockArray = (IdentityLock[]) locks.toArray(new IdentityLock[locks.size()]);
  +         for (int i = lockArray.length -1; i >= 0; i--) {
                if (log.isTraceEnabled())
                {
  -                 log.trace("releasing lock for " + lock.getFqn() + " (" + lock + ")");
  +                 log.trace("releasing lock for " + lockArray[i].getFqn() + " (" + lockArray[i] + ")");
                }
  -             lock.release(owner);
  +             lockArray[i].release(owner);
            }
            locks.clear();
         }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 20:43:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 20:43:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r58920 - in projects/microcontainer/trunk:
	build container/src/main/org/jboss/net/protocol
	container/src/main/org/jboss/virtual
	container/src/main/org/jboss/virtual/plugins/context
	container/src/main/org/jboss/virtual/plugins/context/file
	container/src/main/org/jboss/virtual/plugins/context/jar
	container/src/main/org/jboss/virtual/plugins/vfs
	container/src/main/org/jboss/virtual/protocol
	container/src/main/org/jboss/virtual/protocol/vfsfile
	container/src/main/org/jboss/virtual/protocol/vfsjar
	container/src/main/org/jboss/virtual/spi
	container/src/tests/org/jboss/test/virtual/support
	container/src/tests/org/jboss/test/virtual/test
Message-ID: <E1GsUlm-0007sj-0I@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-07 20:43:14 -0500 (Thu, 07 Dec 2006)
New Revision: 58920

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java
Removed:
   projects/microcontainer/trunk/container/src/main/org/jboss/net/protocol/vfsfile/
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/VirtualFileURLConnection.java
Modified:
   projects/microcontainer/trunk/build/build-thirdparty.xml
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VFS.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileSystemContext.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarFromStream.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VFSContextFactoryLocator.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/support/AbstractMockVirtualFileHandler.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVFSContextTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java
Log:
vfs based URL support

Modified: projects/microcontainer/trunk/build/build-thirdparty.xml
===================================================================
--- projects/microcontainer/trunk/build/build-thirdparty.xml	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/build/build-thirdparty.xml	2006-12-08 01:43:14 UTC (rev 58920)
@@ -46,7 +46,7 @@
       <componentref name="apache-log4j" version="1.2.8"/>
       <componentref name="apache-xerces" version="2.7.1"/>
       <componentref name="javassist" version="3.4.GA"/>
-      <componentref name="jboss/common-core" version="2.0.2.GA"/>
+      <componentref name="jboss/common-core" version="2.0.3.GA"/>
       <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VFS.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VFS.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VFS.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -27,10 +27,12 @@
 import java.util.List;
 
 import org.jboss.virtual.plugins.vfs.helpers.WrappingVirtualFileHandlerVisitor;
+import org.jboss.virtual.plugins.context.VfsArchiveBrowserFactory;
 import org.jboss.virtual.spi.VFSContext;
 import org.jboss.virtual.spi.VFSContextFactory;
 import org.jboss.virtual.spi.VFSContextFactoryLocator;
 import org.jboss.virtual.spi.VirtualFileHandler;
+import org.jboss.util.file.ArchiveBrowser;
 
 /**
  * Virtual File System
@@ -44,6 +46,23 @@
    /** The VFS Context */
    private final VFSContext context;
 
+   static
+   {
+      String pkgs = System.getProperty("java.protocol.handler.pkgs");
+      if (pkgs == null || pkgs.trim().length() == 0)
+      {
+         pkgs = "org.jboss.virtual.protocol";
+         System.setProperty("java.protocol.handler.pkgs", pkgs);
+      }
+      else if (!pkgs.contains("org.jboss.virtual.protocol"))
+      {
+         pkgs += "|org.jboss.virtual.protocol";
+         System.setProperty("java.protocol.handler.pkgs", pkgs);
+      }
+      // keep this until AOP and HEM uses VFS internally instead of the stupid ArchiveBrowser crap.
+      ArchiveBrowser.factoryFinder.put("vfsfile", new VfsArchiveBrowserFactory());
+   }
+
    /**
     * Get the virtual file system for a root uri
     * 

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -24,10 +24,12 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.Serializable;
+import java.io.File;
 import java.net.MalformedURLException;
 import java.net.URI;
 import java.net.URISyntaxException;
 import java.net.URL;
+import java.net.URLEncoder;
 import java.util.Collections;
 import java.util.List;
 import java.util.Set;
@@ -41,7 +43,7 @@
 
 /**
  * A virtual file as seen by the user
- * 
+ *
  * @author Scott.Stark at jboss.org
  * @author adrian at jboss.org
  * @version $Revision: 44334 $
@@ -54,14 +56,14 @@
    private final VirtualFileHandler handler;
 
    /** Whether we are closed */
-   private AtomicBoolean closed = new AtomicBoolean(false); 
-   
+   private AtomicBoolean closed = new AtomicBoolean(false);
+
    /** The open streams */
    private transient final Set<InputStream> streams = Collections.synchronizedSet(new WeakSet());
-   
+
    /**
     * Create a new VirtualFile.
-    * 
+    *
     * @param handler the handler
     * @throws IllegalArgumentException if the handler is null
     */
@@ -74,20 +76,20 @@
 
    /**
     * Get the virtual file handler
-    * 
+    *
     * @return the handler
     * @throws IllegalStateException if the file is closed
     */
-   protected VirtualFileHandler getHandler()
+   public VirtualFileHandler getHandler()
    {
       if (closed.get())
          throw new IllegalStateException("The virtual file is closed");
       return handler;
    }
-   
+
    /**
     * Get the simple VF name (X.java)
-    * 
+    *
     * @return the simple file name
     * @throws IllegalStateException if the file is closed
     */
@@ -98,7 +100,7 @@
 
    /**
     * Get the VFS relative path name (org/jboss/X.java)
-    * 
+    *
     * @return the VFS relative path name
     * @throws IllegalStateException if the file is closed
     */
@@ -109,7 +111,7 @@
 
    /**
     * Get the VF URL (file://root/org/jboss/X.java)
-    * 
+    *
     * @return the full URL to the VF in the VFS.
     * @throws MalformedURLException if a url cannot be parsed
     * @throws URISyntaxException if a uri cannot be parsed
@@ -117,24 +119,24 @@
     */
    public URL toURL() throws MalformedURLException, URISyntaxException
    {
-      return getHandler().toURL();
+      return getHandler().toVfsUrl();
    }
-   
+
    /**
     * Get the VF URI (file://root/org/jboss/X.java)
-    * 
+    *
     * @return the full URI to the VF in the VFS.
     * @throws URISyntaxException if a uri cannot be parsed
     * @throws IllegalStateException if the file is closed
     */
-   public URI toURI() throws URISyntaxException
+   public URI toURI() throws MalformedURLException, URISyntaxException
    {
-      return getHandler().toURI();
+      return VFSUtils.toURI(toURL());
    }
 
    /**
     * When the file was last modified
-    * 
+    *
     * @return the last modified time
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -143,10 +145,10 @@
    {
       return getHandler().getLastModified();
    }
-   
+
    /**
     * Get the size
-    * 
+    *
     * @return the size
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -159,7 +161,7 @@
    /**
     * Whether it is a simple leaf of the VFS,
     * i.e. whether it can contain other files
-    * 
+    *
     * @return true if a simple file.
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -168,10 +170,10 @@
    {
       return getHandler().isLeaf();
    }
-   
+
    /**
     * Whether it is hidden
-    * 
+    *
     * @return true when hidden
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -183,9 +185,9 @@
 
    /**
     * Access the file contents.
-    * 
+    *
     * @return an InputStream for the file contents.
-    * @throws IOException for any error accessing the file system 
+    * @throws IOException for any error accessing the file system
     * @throws IllegalStateException if the file is closed
     */
    public InputStream openStream() throws IOException
@@ -228,10 +230,10 @@
          handler.close();
       }
    }
-   
+
    /**
     * Get the VFS instance for this virtual file
-    * 
+    *
     * @return the VFS
     * @throws IllegalStateException if the file is closed
     */
@@ -240,10 +242,10 @@
       VFSContext context = getHandler().getVFSContext();
       return context.getVFS();
    }
-   
+
    /**
     * Get the parent
-    * 
+    *
     * @return the parent or null if there is no parent
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -255,10 +257,10 @@
          return parent.getVirtualFile();
       return null;
    }
-   
+
    /**
     * Get the children
-    * 
+    *
     * @return the children
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -270,7 +272,7 @@
 
    /**
     * Get the children
-    * 
+    *
     * @param filter to filter the children
     * @return the children
     * @throws IOException for any problem accessing the virtual file system
@@ -287,12 +289,12 @@
       visit(visitor);
       return visitor.getMatched();
    }
-   
+
    /**
     * Get all the children recursively<p>
-    * 
+    *
     * This always uses {@link VisitorAttributes#RECURSE}
-    * 
+    *
     * @return the children
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalStateException if the file is closed
@@ -301,12 +303,12 @@
    {
       return getChildrenRecursively(null);
    }
-   
+
    /**
     * Get all the children recursively<p>
-    * 
+    *
     * This always uses {@link VisitorAttributes#RECURSE}
-    * 
+    *
     * @param filter to filter the children
     * @return the children
     * @throws IOException for any problem accessing the virtual file system
@@ -323,10 +325,10 @@
       visit(visitor);
       return visitor.getMatched();
    }
-   
+
    /**
     * Visit the virtual file system
-    * 
+    *
     * @param visitor the visitor
     * @throws IOException for any problem accessing the virtual file system
     * @throws IllegalArgumentException if the visitor is null
@@ -342,8 +344,8 @@
 
    /**
     * Find a child
-    * 
-    * @param path the path 
+    *
+    * @param path the path
     * @return the child
     * @throws IOException for any problem accessing the VFS (including the child does not exist)
     * @throws IllegalArgumentException if the path is null
@@ -352,7 +354,7 @@
    public VirtualFile findChild(String path) throws IOException
    {
       VirtualFileHandler handler = getHandler();
-      
+
       if (handler.isLeaf())
          throw new IllegalStateException("File cannot contain children: " + this);
 
@@ -372,7 +374,7 @@
    {
       return handler.hashCode();
    }
-   
+
    @Override
    public boolean equals(Object obj)
    {

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -60,7 +60,8 @@
    private static final ObjectStreamField[] serialPersistentFields = {
       new ObjectStreamField("rootURI", URI.class),
       new ObjectStreamField("parent", VirtualFileHandler.class),
-      new ObjectStreamField("name", String.class)
+           new ObjectStreamField("name", String.class),
+           new ObjectStreamField("vfsUrl", URL.class)
    };
 
    /** The VFS context
@@ -81,6 +82,8 @@
    /** The vfsPath */
    private transient String vfsPath;
 
+   protected URL vfsUrl;
+
    /** The reference count */
    private transient AtomicInteger references = new AtomicInteger(0);
 
@@ -124,6 +127,12 @@
       return toURI().toURL();
    }
 
+
+   public URL toVfsUrl() throws MalformedURLException, URISyntaxException
+   {
+      return vfsUrl;
+   }
+
    /**
     * Initialise the path into the path name
     * 
@@ -344,6 +353,7 @@
       fields.put("rootURI", this.getVFSContext().getRootURI());
       fields.put("parent", parent);
       fields.put("name", name);
+      fields.put("vfsUrl", vfsUrl);
       out.writeFields();
    }
    private void readObject(ObjectInputStream in)
@@ -357,6 +367,7 @@
       VFSContextFactory factory = VFSContextFactoryLocator.getFactory(rootURI);
       this.context = factory.getVFS(rootURI);
       this.references = new AtomicInteger(0);
+      this.vfsUrl = (URL)fields.get("vfsUrl", null);
       // Restore the log
       log = Logger.getLogger(getClass());
    }

Added: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -0,0 +1,107 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.virtual.plugins.context;
+
+import org.jboss.util.file.ArchiveBrowser;
+import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.VirtualFileFilter;
+import org.jboss.virtual.VisitorAttributes;
+import org.jboss.virtual.plugins.vfs.helpers.SuffixesExcludeFilter;
+import org.jboss.virtual.plugins.vfs.helpers.FilterVirtualFileVisitor;
+import org.jboss.virtual.plugins.context.jar.JarUtils;
+
+import java.util.Iterator;
+import java.util.List;
+import java.io.InputStream;
+import java.io.IOException;
+
+/**
+ * This is a bridge to an older, crappier API written by myself.
+ *
+ * @deprecated
+ *
+ * @author <a href="bill at jboss.com">Bill Burke</a>
+ * @version $Revision: 1.1 $
+ */
+public class VfsArchiveBrowser implements Iterator
+{
+   private ArchiveBrowser.Filter filter;
+   private VirtualFile vf;
+   private Iterator<VirtualFile> it;
+
+
+   public VfsArchiveBrowser(final ArchiveBrowser.Filter filter, VirtualFile vf)
+   {
+      this.filter = filter;
+      this.vf = vf;
+      List<VirtualFile> classes = getResources(new VirtualFileFilter() {
+         public boolean accepts(VirtualFile file)
+         {
+            return filter.accept(file.getName());
+         }
+      });
+
+      it = classes.iterator();
+   }
+
+   public List<VirtualFile> getResources(VirtualFileFilter filter)
+   {
+      VisitorAttributes va = new VisitorAttributes();
+      va.setLeavesOnly(true);
+      SuffixesExcludeFilter noJars = new SuffixesExcludeFilter(JarUtils.getSuffixes());
+      va.setRecurseFilter(noJars);
+      FilterVirtualFileVisitor visitor = new FilterVirtualFileVisitor(filter, va);
+
+      try
+      {
+         vf.visit(visitor);
+      }
+      catch (IOException e)
+      {
+         throw new RuntimeException(e);
+      }
+      return visitor.getMatched();
+   }
+
+
+   public boolean hasNext()
+   {
+      return it.hasNext();
+   }
+
+   public Object next()
+   {
+      try
+      {
+         return it.next().openStream();
+      }
+      catch (IOException e)
+      {
+         throw new RuntimeException(e);
+      }
+   }
+
+   public void remove()
+   {
+      it.remove();
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -0,0 +1,57 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.virtual.plugins.context;
+
+import org.jboss.util.file.ArchiveBrowserFactory;
+import org.jboss.util.file.ArchiveBrowser;
+import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.VFS;
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
+
+import java.util.Iterator;
+import java.net.URL;
+import java.io.IOException;
+
+/**
+ * This is a bridge to an older, crappier API written by myself.
+ *
+ * @deprecated
+ *
+ * @author <a href="bill at jboss.com">Bill Burke</a>
+ * @version $Revision: 1.1 $
+ */
+public class VfsArchiveBrowserFactory implements ArchiveBrowserFactory
+{
+   public Iterator create(URL url, ArchiveBrowser.Filter filter)
+   {
+      try
+      {
+         VirtualFileURLConnection conn = (VirtualFileURLConnection)url.openConnection();
+         VirtualFile vf = conn.getVirtualFile();
+         return new VfsArchiveBrowser(filter, vf);
+      }
+      catch (IOException e)
+      {               
+         throw new RuntimeException("Unable to browse URL: " + url, e);
+      }
+   }
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -27,13 +27,18 @@
 import java.io.ObjectInputStream;
 import java.net.URI;
 import java.net.URL;
+import java.net.MalformedURLException;
+import java.net.URISyntaxException;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.List;
+import java.util.Map;
+import java.util.HashMap;
 
 import org.jboss.virtual.plugins.context.AbstractURLHandler;
 import org.jboss.virtual.plugins.context.StructuredVirtualFileHandler;
 import org.jboss.virtual.spi.VirtualFileHandler;
+import org.jboss.virtual.VFS;
 
 /**
  * FileHandler.
@@ -49,6 +54,8 @@
    /** The file */
    private transient File file;
    
+   private transient Map<String, VirtualFileHandler> childCache = Collections.synchronizedMap(new HashMap<String, VirtualFileHandler>());
+
    /**
     * Create a new FileHandler.
     * 
@@ -66,6 +73,7 @@
       this.file = file;
       if (file.exists() == false)
          throw new FileNotFoundException("File does not exist: " + file.getCanonicalPath());
+      this.vfsUrl = new URL("vfs" + url.toString());
    }
    /**
     * Create a new FileHandler
@@ -82,6 +90,16 @@
       this(context, parent, file, uri.toURL());
    }
 
+
+   public URL toVfsUrl() throws MalformedURLException, URISyntaxException
+   {
+      if (vfsUrl == null)
+      {
+         vfsUrl = new URL("vfs" + getURL().toString());
+      }
+      return vfsUrl;
+   }
+
    @Override
    public FileSystemContext getVFSContext()
    {
@@ -133,12 +151,24 @@
       FileSystemContext context = getVFSContext();
       
       List<VirtualFileHandler> result = new ArrayList<VirtualFileHandler>();
+      Map<String, VirtualFileHandler> newCache = Collections.synchronizedMap(new HashMap<String, VirtualFileHandler>());
+      Map<String, VirtualFileHandler> oldCache = childCache;
       for (File file : files)
       {
          try
          {
-            VirtualFileHandler handler = context.createVirtualFileHandler(this, file);
+            VirtualFileHandler handler = null;
+            handler = oldCache.get(file.getName());
+            if (handler != null && file.lastModified() != handler.getLastModified())
+            {
+               handler = null;
+            }
+            if (handler == null)
+            {
+               handler = context.createVirtualFileHandler(this, file);
+            }
             result.add(handler);
+            newCache.put(file.getName(), handler);
          }
          catch (IOException e)
          {
@@ -148,6 +178,8 @@
                throw e;
          }
       }
+      // cleanup old entries
+      childCache = newCache;
       return result;
    }
 
@@ -161,7 +193,17 @@
       FileSystemContext context = getVFSContext();
       File parentFile = getFile();
       File child = new File(parentFile, name);
-      return context.createVirtualFileHandler(this, child);
+      VirtualFileHandler handler = childCache.get(name);
+      if (handler != null)
+      {
+         if (handler.getLastModified() != child.lastModified()) handler = null;
+      }
+      if (handler == null)
+      {
+         handler = context.createVirtualFileHandler(this, child);
+         childCache.put(name, handler);
+      }
+      return handler;
    }
 
    private void readObject(ObjectInputStream in)

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileSystemContext.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileSystemContext.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileSystemContext.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -56,7 +56,7 @@
    /**
     * Get the file for a url
     * 
-    * @param url the url
+    * @param uri the url
     * @return the file
     * @throws IOException for any error accessing the file system
     * @throws IllegalArgumentException for a null url

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/LinkHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -26,6 +26,7 @@
 import java.net.URI;
 import java.net.URISyntaxException;
 import java.net.URL;
+import java.net.MalformedURLException;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.List;
@@ -66,6 +67,14 @@
       public ParentOfLink(VFSContext context, VirtualFileHandler parent, URL url, String name)
       {
          super(context, parent, url, name);
+         try
+         {
+            this.vfsUrl = new URL("vfs" + url.toString());
+         }
+         catch (MalformedURLException e)
+         {
+            throw new RuntimeException(e);
+         }
       }
       void addChild(VirtualFileHandler child, String name)
       {
@@ -90,6 +99,8 @@
       {
          return false;
       }
+
+
    }
 
    /**
@@ -111,7 +122,8 @@
       // TODO: This URL is not consistent with the getName, but does point to the raw link file
       super(context, parent, uri.toURL(), name);
       this.links = links;
-      // Create handlers for the links and add 
+      this.vfsUrl = new URL("vfs" + uri.toURL().toString());
+      // Create handlers for the links and add
       for(LinkInfo link : links)
       {
          String linkName = link.getName();
@@ -211,4 +223,5 @@
       // TODO: if the factory caches contexts the root handler may not point to the link
       return new DelegatingHandler(this.getVFSContext(), parent, name, rootHandler);
    }
+
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -390,6 +390,44 @@
    }
 
    /**
+    * Convert a URL into a JarFIle
+    *
+    * @param url
+    * @return
+    * @throws IOException
+    */
+   public static JarFile fromURL(URL url) throws IOException
+   {
+      try
+      {
+         URLConnection connection = url.openConnection();
+         JarURLConnection jarConnection;
+         if (connection instanceof JarURLConnection)
+         {
+            jarConnection = (JarURLConnection)connection;
+         }
+         else
+         {
+            // try wrapping it in jar:
+            URL jarUrl = new URL("jar:" + url + "!/");
+            jarConnection = (JarURLConnection)jarUrl.openConnection();
+         }
+         jarConnection.setUseCaches(false);
+         return jarConnection.getJarFile();
+      }
+      catch (IOException original)
+      {
+         // Fix the context of the error message
+         IOException e = new IOException("Error opening jar file: " + url + " reason=" + original.getMessage());
+         e.setStackTrace(original.getStackTrace());
+         throw e;
+
+      }
+
+   }
+
+
+   /**
     * Restore the jar file from the jar URL
     *
     * @param in

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -24,7 +24,10 @@
 import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.io.InputStream;
+import java.io.ByteArrayInputStream;
+import java.io.ByteArrayOutputStream;
 import java.net.URL;
+import java.net.URISyntaxException;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.HashMap;
@@ -76,6 +79,21 @@
       throws IOException
    {
       super(context, parent, url, entryName);
+      try
+      {
+         URL parentVfsUrl = parent.toVfsUrl();
+         String vfsParentUrl = parentVfsUrl.toString();
+         String vfsUrlString = null;
+         if (vfsParentUrl.endsWith("/")) vfsUrlString = vfsParentUrl + entryName;
+         else vfsUrlString = vfsParentUrl + "/" + entryName;
+         if (entry.isDirectory()) vfsUrlString += "/";
+         vfsUrl = new URL(vfsUrlString);
+      }
+      catch (URISyntaxException e)
+      {
+         throw new RuntimeException(e);
+      }
+
       if (jar == null)
          throw new IllegalArgumentException("Null jar");
       
@@ -128,12 +146,6 @@
       return false;
    }
 
-   @Override
-   public InputStream openStream() throws IOException
-   {
-      return jar.getInputStream(getEntry());
-   }
-
    public List<VirtualFileHandler> getChildren(boolean ignoreErrors) throws IOException
    {
       checkClosed();
@@ -148,6 +160,14 @@
       return super.structuredFindChild(path);
    }
 
+   @Override
+   public InputStream openStream() throws IOException
+   {
+      return jar.getInputStream(getEntry());
+   }
+
+
+
    /**
     * TODO: synchronization on lazy entryMap creation
     */

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -55,6 +55,7 @@
    public JarHandler(VFSContext context, VirtualFileHandler parent, URL url, String name) throws IOException
    {
       super(context, parent, url, name);
+      this.vfsUrl = new URL("vfs" + url.toString());
 
       try
       {
@@ -73,6 +74,7 @@
    public JarHandler(VFSContext context, VirtualFileHandler parent, File file, URL url, String name) throws IOException
    {
       super(context, parent, url, name);
+      this.vfsUrl = new URL("vfs" + url.toString());
 
       try
       {

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarFromStream.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarFromStream.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarFromStream.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -25,14 +25,16 @@
 
 /**
  * A nested jar implementation used to represent a jar within a jar.
- * 
+ *
  * @author Scott.Stark at jboss.org
  * @version $Revision: 44334 $
  */
 public class NestedJarFromStream
-   extends AbstractVirtualFileHandler
+        extends AbstractVirtualFileHandler
 {
-   /** serialVersionUID */
+   /**
+    * serialVersionUID
+    */
    private static final long serialVersionUID = 1L;
 
    private ZipInputStream zis;
@@ -47,11 +49,12 @@
 
    /**
     * Create a nested jar from the parent zip inputstream/zip entry.
+    *
     * @param context - the context containing the jar
-    * @param parent - the jar handler for this nested jar
-    * @param zis - the jar zip input stream
-    * @param jarURL - the URL to use as the jar URL
-    * @param entry - the parent jar ZipEntry for the nested jar
+    * @param parent  - the jar handler for this nested jar
+    * @param zis     - the jar zip input stream
+    * @param jarURL  - the URL to use as the jar URL
+    * @param entry   - the parent jar ZipEntry for the nested jar
     */
    public NestedJarFromStream(VFSContext context, VirtualFileHandler parent, ZipInputStream zis, URL jarURL, ZipEntry entry)
    {
@@ -61,19 +64,32 @@
       this.lastModified = entry.getTime();
       this.size = entry.getSize();
       this.zis = zis;
+      try
+      {
+         if (parent != null)
+         {
+            String vfsParentUrl = parent.toVfsUrl().toString();
+            if (vfsParentUrl.endsWith("/")) vfsUrl = new URL(vfsParentUrl + this.name);
+            else vfsUrl = new URL(vfsParentUrl + "/" + this.name);
+         }
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException(e);
+      }
    }
 
 
    public VirtualFileHandler findChild(String path) throws IOException
    {
-      if( inited == false )
+      if (inited == false)
          init();
       return entries.get(name);
    }
 
    public List<VirtualFileHandler> getChildren(boolean ignoreErrors) throws IOException
    {
-      if( inited == false )
+      if (inited == false)
          init();
       List<VirtualFileHandler> children = new ArrayList<VirtualFileHandler>();
       children.addAll(entries.values());
@@ -102,31 +118,34 @@
 
 
    public Iterator<JarEntryContents> getEntries()
-      throws IOException
+           throws IOException
    {
-      if( inited == false )
+      if (inited == false)
          init();
       return entries.values().iterator();
    }
+
    public JarEntryContents getEntry(String name)
-      throws IOException
+           throws IOException
    {
-      if( inited == false )
+      if (inited == false)
          init();
       return entries.get(name);
    }
+
    public ZipEntry getJarEntry(String name)
-      throws IOException
+           throws IOException
    {
-      if( inited == false )
+      if (inited == false)
          init();
       JarEntryContents jec = entries.get(name);
       return (jec != null ? jec.getEntry() : null);
    }
+
    public byte[] getContents(String name)
-      throws IOException
+           throws IOException
    {
-      if( inited == false )
+      if (inited == false)
          init();
       JarEntryContents jec = entries.get(name);
       return (jec != null ? jec.getContents() : null);
@@ -136,6 +155,7 @@
    {
       return name;
    }
+
    public String getPathName()
    {
       return vfsPath;
@@ -150,13 +170,13 @@
    public void close()
    {
       entries.clear();
-      if( zis != null )
+      if (zis != null)
       {
          try
          {
             zis.close();
          }
-         catch(IOException e)
+         catch (IOException e)
          {
             log.error("close error", e);
          }
@@ -168,10 +188,10 @@
    {
       try
       {
-         if( entryURL == null )
+         if (entryURL == null)
             entryURL = new URL(jarURL, getName());
       }
-      catch(MalformedURLException e)
+      catch (MalformedURLException e)
       {
          throw new URISyntaxException("Failed to create relative jarURL", e.getMessage());
       }
@@ -193,7 +213,7 @@
       {
          tmp.append(toURI());
       }
-      catch(URISyntaxException e)
+      catch (URISyntaxException e)
       {
       }
       tmp.append(']');
@@ -201,21 +221,21 @@
    }
 
    protected void init()
-      throws IOException
+           throws IOException
    {
       inited = true;
       ZipEntry entry = zis.getNextEntry();
-      while( entry != null )
+      while (entry != null)
       {
          try
          {
-            String url = toURI().toASCIIString() + "!/" +  entry.getName();
+            String url = toURI().toASCIIString() + "!/" + entry.getName();
             URL jecURL = new URL(url);
             JarEntryContents jec = new JarEntryContents(getVFSContext(), this, entry, jecURL, zis, getPathName());
             entries.put(entry.getName(), jec);
             entry = zis.getNextEntry();
          }
-         catch(URISyntaxException e)
+         catch (URISyntaxException e)
          {
             e.printStackTrace();
          }
@@ -225,9 +245,11 @@
    }
 
    public static class JarEntryContents
-      extends AbstractVirtualFileHandler
+           extends AbstractVirtualFileHandler
    {
-      /** serialVersionUID */
+      /**
+       * serialVersionUID
+       */
       private static final long serialVersionUID = 1L;
       private ZipEntry entry;
       private URL entryURL;
@@ -238,8 +260,8 @@
       private InputStream openStream;
 
       JarEntryContents(VFSContext context, VirtualFileHandler parent, ZipEntry entry, URL entryURL, InputStream zis,
-         String parentVfsPath)
-         throws IOException
+                       String parentVfsPath)
+              throws IOException
       {
          super(context, parent, entry.getName());
          this.entry = entry;
@@ -247,15 +269,15 @@
          this.vfsPath = parentVfsPath + "/" + entry.getName();
          this.isJar = JarUtils.isArchive(entry.getName());
          int size = (int) entry.getSize();
-         if( size <= 0 )
+         if (size <= 0)
             return;
 
          ByteArrayOutputStream baos = new ByteArrayOutputStream(size);
          byte[] tmp = new byte[1024];
-         while( zis.available() > 0 )
+         while (zis.available() > 0)
          {
             int length = zis.read(tmp);
-            if( length > 0 )
+            if (length > 0)
                baos.write(tmp, 0, length);
          }
          contents = baos.toByteArray();
@@ -270,6 +292,7 @@
       {
          return entry;
       }
+
       public byte[] getContents()
       {
          return contents;
@@ -279,6 +302,7 @@
       {
          return entry.getName();
       }
+
       public String getPathName()
       {
          return vfsPath;
@@ -287,24 +311,25 @@
       public List<VirtualFileHandler> getChildren(boolean ignoreErrors) throws IOException
       {
          List<VirtualFileHandler> children = null;
-         if( isJar )
+         if (isJar)
          {
             initNestedJar();
             children = njar.getChildren(ignoreErrors);
          }
          return children;
       }
+
       public VirtualFileHandler findChild(String path) throws IOException
       {
          VirtualFileHandler child;
-         if( isJar )
+         if (isJar)
          {
             initNestedJar();
             child = njar.findChild(path);
          }
          else
          {
-            throw new FileNotFoundException("JarEntryContents("+entry.getName()+") has no children");
+            throw new FileNotFoundException("JarEntryContents(" + entry.getName() + ") has no children");
          }
          return child;
       }
@@ -329,10 +354,10 @@
 
       // Stream accessor
       public synchronized InputStream openStream()
-         throws IOException
+              throws IOException
       {
          initNestedJar();
-         if( njar != null )
+         if (njar != null)
             openStream = njar.openStream();
          else
             openStream = new ByteArrayInputStream(contents);
@@ -341,13 +366,13 @@
 
       public synchronized void close()
       {
-         if( openStream != null )
+         if (openStream != null)
          {
             try
             {
                openStream.close();
             }
-            catch(IOException e)
+            catch (IOException e)
             {
                log.error("close error", e);
             }
@@ -375,7 +400,7 @@
          {
             tmp.append(toURI());
          }
-         catch(URISyntaxException e)
+         catch (URISyntaxException e)
          {
          }
          tmp.append(']');
@@ -383,9 +408,9 @@
       }
 
       private synchronized void initNestedJar()
-         throws IOException
+              throws IOException
       {
-         if( isJar && njar == null )
+         if (isJar && njar == null)
          {
             ByteArrayInputStream bais = new ByteArrayInputStream(contents);
             ZipInputStream zis = new ZipInputStream(bais);

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/NestedJarHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -28,6 +28,7 @@
 import java.io.InputStream;
 import java.io.ObjectInputStream;
 import java.net.URL;
+import java.net.URISyntaxException;
 import java.util.jar.JarEntry;
 import java.util.jar.JarFile;
 
@@ -138,6 +139,17 @@
    {
       super(context, parent, temp.toURL(), entryName);
 
+      try
+      {
+         String vfsParentUrl = parent.toVfsUrl().toString();
+         if (vfsParentUrl.endsWith("/")) vfsUrl = new URL(vfsParentUrl + entryName);
+         else vfsUrl = new URL(vfsParentUrl + "/" + entryName);
+      }
+      catch (URISyntaxException e)
+      {
+         throw new RuntimeException(e);
+      }
+
       this.temp = temp;
       this.original = original;
       

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -25,6 +25,7 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.net.URL;
+import java.net.URISyntaxException;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.HashMap;
@@ -69,6 +70,17 @@
       throws IOException
    {
       super(context, parent, url, entryName);
+      try
+      {
+         URL parentVfsUrl = parent.toVfsUrl();
+         String vfsParentUrl = parentVfsUrl.toString();
+         if (vfsParentUrl.endsWith("/")) vfsUrl = new URL(vfsParentUrl + entryName);
+         else vfsUrl = new URL(vfsParentUrl + "/" + entryName + "/");
+      }
+      catch (URISyntaxException e)
+      {
+         throw new RuntimeException(e);
+      }
       this.lastModified = lastModified;
    }
 

Copied: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java (from rev 58701, projects/microcontainer/trunk/container/src/main/org/jboss/net/protocol/vfsfile/VirtualFileURLConnection.java)
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/net/protocol/vfsfile/VirtualFileURLConnection.java	2006-11-28 13:43:29 UTC (rev 58701)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -0,0 +1,100 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.virtual.plugins.vfs;
+
+import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.VFS;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URL;
+import java.net.URLConnection;
+import java.util.Map;
+import java.util.Collections;
+import java.util.HashMap;
+
+/**
+ * Implements basic URLConnection for a VirtualFile
+ *
+ * @author <a href="bill at jboss.com">Bill Burke</a>
+ * @version $Revision: 1.1 $
+ */
+public class   VirtualFileURLConnection extends URLConnection
+{
+   public static Map<URL, VFS> urlCache = Collections.synchronizedMap(new HashMap<URL, VFS>());
+
+   protected VirtualFile file;
+   protected URL vfsurl;
+   protected String relativePath;
+
+
+   public VirtualFileURLConnection(URL url, URL vfsurl, String relativePath)
+   {
+      super(url);
+      this.vfsurl = vfsurl;
+      this.relativePath = relativePath;
+   }
+
+   public void connect() throws IOException
+   {
+   }
+
+   public static VirtualFile resolveCachedVirtualFile(URL vfsurl, String relativePath) throws IOException
+   {
+      VFS vfs = urlCache.get(vfsurl);
+      if (vfs == null)
+      {
+         vfs = VFS.getVFS(vfsurl);
+         urlCache.put(vfsurl, vfs);
+      }
+      return vfs.findChild(relativePath);
+
+   }
+
+   public static VirtualFile resolveVirtualFile(URL vfsurl, String relativePath) throws IOException
+   {
+      VFS vfs = VFS.getVFS(vfsurl);
+      return vfs.findChild(relativePath);
+   }
+
+   public synchronized VirtualFile getVirtualFile() throws IOException
+   {
+      if (file == null)
+      {
+         if (this.getUseCaches())
+         {
+            file = resolveCachedVirtualFile(vfsurl, relativePath);
+         }
+         else
+         {
+            file = resolveVirtualFile(vfsurl, relativePath);
+         }
+      }
+      return file;
+   }
+
+
+   public InputStream getInputStream() throws IOException
+   {
+      return getVirtualFile().openStream();
+   }
+}

Copied: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile (from rev 58907, projects/microcontainer/trunk/container/src/main/org/jboss/net/protocol/vfsfile)

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/net/protocol/vfsfile/Handler.java	2006-12-07 19:26:38 UTC (rev 58907)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -19,10 +19,10 @@
 * 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.net.protocol.vfsfile;
+package org.jboss.virtual.protocol.vfsfile;
 
 import org.jboss.virtual.VFS;
-import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
 
 import java.io.File;
 import java.io.IOException;
@@ -30,6 +30,14 @@
 import java.net.URL;
 import java.net.URLConnection;
 import java.net.URLStreamHandler;
+import java.net.URLClassLoader;
+import java.util.jar.JarEntry;
+import java.util.jar.JarFile;
+import java.util.HashSet;
+import java.util.Enumeration;
+import java.util.Map;
+import java.util.Collections;
+import java.util.HashMap;
 
 /**
  * URLStreamHandler for VFS
@@ -39,43 +47,81 @@
  */
 public class Handler extends URLStreamHandler
 {
-
    protected URLConnection openConnection(URL u) throws IOException
    {
       String file = u.toString().substring(8); // strip out vfsfile:
+      URL vfsurl = null;
+      String relative;
       File fp = new File(file);
-
-      File parent = fp;
-      File curr = fp;
-      String relative = fp.getName();
-      while ((curr = curr.getParentFile()) != null)
+      if (fp.exists())
       {
-         parent = curr;
-         if (parent.getParentFile() != null) relative = parent.getName() + "/" + relative;
+         vfsurl = fp.getParentFile().toURL();
+         relative = fp.getName();
       }
+      else
+      {
+         File curr = fp;
+         relative = fp.getName();
+         while ((curr = curr.getParentFile()) != null)
+         {
+            if (curr.exists())
+            {
+               vfsurl = curr.toURL();
+               break;
+            }
+            else
+            {
+               relative = curr.getName() + "/" + relative;
+            }
+         }
+      }
 
-      URL url = parent.toURL();
-
-      VFS vfs = VFS.getVFS(url);
-      VirtualFile vf = vfs.findChild(relative);
-
-
-      return new VirtualFileURLConnection(url, vf);
+      if (vfsurl == null) throw new IOException("vfsfile does not exist: " + u.toString());
+      return new VirtualFileURLConnection(u, vfsurl, relative);
    }
 
-
    public static void main(String[] args) throws Exception
    {
-      System.setProperty("java.protocol.handler.pkgs", "org.jboss.net.protocol");
+      System.setProperty("java.protocol.handler.pkgs", "org.jboss.virtual.protocol");
+
       //URL url = new URL("vfsfile:/c:/tmp/urlstream.java");
       //URL url = new URL("vfsfile:/C:\\jboss\\jboss-head\\build\\output\\jboss-5.0.0.Beta\\server\\default\\lib\\jboss.jar\\schema\\xml.xsd");
+      URL furl = new URL("file:/c:/tmp/parent.jar");
+      System.out.println("urlpath: " + furl.getPath());
       URL url = new URL("vfsfile:/c:/tmp/parent.jar/foo.jar/urlstream.java");
       InputStream is = url.openStream();
+      char curr = 0;
       while (is.available() != 0)
       {
-         System.out.print((char)is.read());
+         curr = (char) is.read();
+         System.out.print(curr);
       }
       is.close();
 
+      // use a .jar file that would NEVER EVER be in my IDE's classpath
+      File fp = new File("c:/jboss/geronimo-1.1.1/lib/geronimo-kernel-1.1.1.jar");
+      JarFile jf = new JarFile(fp);
+      Enumeration<JarEntry> entries = jf.entries();
+      HashSet<String> set = new HashSet<String>();
+      while (entries.hasMoreElements())
+      {
+         String name = entries.nextElement().getName();
+         if (name.endsWith(".class")) set.add(name.replace('/', '.').substring(0, name.length() - 6));
+      }
+      jf.close();
+      /*
+URL[] urls = {new URL("vfsfile:/c:/tmp/webinf-classes.jar/classes/"),
+      new URL("file:/c:/jboss/geronimo-1.1.1/lib/xstream-1.1.3.jar")};
+      */
+      // use a .jar file that would NEVER EVER be in my IDE's classpath
+      URL[] urls = {new URL("vfsfile:/c:/tmp/wrap.jar/geronimo-kernel-1.1.1.jar"),
+              new URL("file:/c:/jboss/geronimo-1.1.1/lib/xstream-1.1.3.jar")};
+      URLClassLoader loader = new URLClassLoader(urls);
+      for (String name : set)
+      {
+         System.out.println("loading: " + name);
+         loader.loadClass(name);
+      }
    }
+
 }

Deleted: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/VirtualFileURLConnection.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/net/protocol/vfsfile/VirtualFileURLConnection.java	2006-12-07 19:26:38 UTC (rev 58907)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/VirtualFileURLConnection.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -1,61 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.net.protocol.vfsfile;
-
-import org.jboss.virtual.VirtualFile;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.URL;
-import java.net.URLConnection;
-
-/**
- * Implements basic URLConnection for a VirtualFile
- *
- * @author <a href="bill at jboss.com">Bill Burke</a>
- * @version $Revision: 1.1 $
- */
-public class VirtualFileURLConnection extends URLConnection
-{
-   protected VirtualFile file;
-
-   public VirtualFileURLConnection(URL url, VirtualFile file)
-   {
-      super(url);
-      this.file = file;
-   }
-
-   public void connect() throws IOException
-   {
-   }
-
-   public VirtualFile getVirtualFile()
-   {
-      return file;
-   }
-
-
-   public InputStream getInputStream() throws IOException
-   {
-      return file.openStream();
-   }
-}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.virtual.protocol.vfsjar;
+
+import org.jboss.virtual.VFS;
+import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
+
+import java.net.URLStreamHandler;
+import java.net.URLConnection;
+import java.net.URL;
+import java.net.URISyntaxException;
+import java.io.IOException;
+import java.io.File;
+import java.io.InputStream;
+
+/**
+ * URLStreamHandler for VFS
+ *
+ * @author <a href="bill at jboss.com">Bill Burke</a>
+ * @version $Revision: 1.1 $
+ */
+public class Handler extends URLStreamHandler
+{
+   protected URLConnection openConnection(URL u) throws IOException
+   {
+      String urlString = u.toString();
+      int index = urlString.indexOf("!/");
+      String file = urlString.substring(3, index + 2); // strip out vfs
+      String path = urlString.substring(index + 2);
+      URL url = new URL(file);
+      return new VirtualFileURLConnection(u, url, path);
+   }
+   public static void main(String[] args) throws Exception
+   {
+      System.setProperty("java.protocol.handler.pkgs", "org.jboss.virtual.protocol");
+      //URL url = new URL("vfsfile:/c:/tmp/urlstream.java");
+      //URL url = new URL("vfsfile:/C:\\jboss\\jboss-head\\build\\output\\jboss-5.0.0.Beta\\server\\default\\lib\\jboss.jar\\schema\\xml.xsd");
+      URL url = new URL("vfsjar:file:/c:/tmp/parent.jar!/foo.jar/urlstream.java");
+      InputStream is = url.openStream();
+      while (is.available() != 0)
+      {
+         System.out.print((char)is.read());
+      }
+      is.close();
+
+   }
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VFSContextFactoryLocator.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VFSContextFactoryLocator.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VFSContextFactoryLocator.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -39,6 +39,8 @@
 import org.jboss.logging.Logger;
 import org.jboss.virtual.plugins.context.file.FileSystemContextFactory;
 import org.jboss.virtual.plugins.context.jar.JarContextFactory;
+import org.jboss.virtual.plugins.context.VfsArchiveBrowserFactory;
+import org.jboss.util.file.ArchiveBrowser;
 
 /**
  * A singleton factory for locating VFSContextFactory instances given VFS root URIs.
@@ -64,6 +66,24 @@
    /** Has the default initialzation been performed */
    private static boolean initialized;
 
+   static
+   {
+      String pkgs = System.getProperty("java.protocol.handler.pkgs");
+      if (pkgs == null || pkgs.trim().length() == 0)
+      {
+         pkgs = "org.jboss.virtual.protocol";
+         System.setProperty("java.protocol.handler.pkgs", pkgs);
+      }
+      else if (!pkgs.contains("org.jboss.virtual.protocol"))
+      {
+         pkgs += "|org.jboss.virtual.protocol";
+         System.setProperty("java.protocol.handler.pkgs", pkgs);
+      }
+      // keep this until AOP and HEM uses VFS internally instead of the stupid ArchiveBrowser crap.
+      ArchiveBrowser.factoryFinder.put("vfsfile", new VfsArchiveBrowserFactory());
+   }
+
+
    /**
     * Register a new VFSContextFactory
     * 

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -56,6 +56,16 @@
    String getPathName();
 
    /**
+    * Get a VFS-based URL
+    *
+    * @return
+    * @throws MalformedURLException
+    * @throws URISyntaxException
+    */
+   URL toVfsUrl() throws MalformedURLException, URISyntaxException;
+   
+
+   /**
     * Get the VF URI (file://root/org/jboss/X.java)
     * 
     * @return the full URI to the VF in the VFS.

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/support/AbstractMockVirtualFileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/support/AbstractMockVirtualFileHandler.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/support/AbstractMockVirtualFileHandler.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -244,6 +244,12 @@
       return uri;
    }
 
+
+   public URL toVfsUrl() throws MalformedURLException, URISyntaxException
+   {
+      return toURL();
+   }
+
    @Override
    public URL toURL() throws MalformedURLException, URISyntaxException
    {

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVFSContextTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVFSContextTest.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVFSContextTest.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -61,7 +61,7 @@
       VFS vfs = context.getVFS();
       VirtualFile rootFile = vfs.getRoot();
       
-      assertEquals(rootURI, rootFile.toURI());
+      assertEquals(new URI("vfs" + rootURI), rootFile.toURI());
    }
    
    public void testGetRoot() throws Exception

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/AbstractVirtualFileHandlerTest.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -587,8 +587,10 @@
       assertEquals(handler.isLeaf(), file.isLeaf());
       assertEquals(handler.getLastModified(), file.getLastModified());
       assertEquals(handler.getSize(), file.getSize());
-      assertEquals(handler.toURI(), file.toURI());
-      assertEquals(handler.toURL(), file.toURL());
+
+      // can't do this anymore as VirtualFile.toURL() returns a vfs based url
+      //assertEquals(handler.toURI(), file.toURI());
+      //assertEquals(handler.toURL(), file.toURL());
       
       VirtualFileHandler parent = handler.getParent();
       if (parent == null)

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -625,7 +625,7 @@
       String name = tmp.getName();
       String vfsPath = tmp.getPath();
       vfsPath = vfsPath.substring(tmpRoot.getPath().length()+1);
-      URL url = tmp.toURL();
+      URL url = new URL("vfs" + tmp.toURL());
       log.debug("name: "+name);
       log.debug("vfsPath: "+vfsPath);
       log.debug("url: "+url);
@@ -693,7 +693,7 @@
       String name = tmpJar.getName();
       String vfsPath = tmpJar.getPath();
       vfsPath = vfsPath.substring(tmpRoot.getPath().length()+1);
-      URL url = tmpJar.toURL();
+      URL url = new URL("vfs" + tmpJar.toURL());
       //url = JarUtils.createJarURL(url);
       log.debug("name: "+name);
       log.debug("vfsPath: "+vfsPath);
@@ -1042,10 +1042,19 @@
       VirtualFile tstjar = vfs.findChild("path with spaces/tst.jar");
       assertNotNull("tstjar != null", tstjar);
       URI uri = tstjar.toURI();
-      URI expectedURI = new URI(rootURL.toString()+"/path%20with%20spaces/tst.jar");
+      URI expectedURI = new URI("vfs"+rootURL.toString()+"/path%20with%20spaces/tst.jar");
       assertEquals(uri, expectedURI);
    }
 
+   public static void main(String[] args) throws Exception
+   {
+      File file = new File("C:\\Documents and Settings");
+      System.out.println(file.toURI());
+      System.out.println(file.toURL().getHost());
+      URI uri = new URI("file", null, "/Document and Settings", null);
+      System.out.println(uri);
+   }
+
    /**
     * Validate accessing an unpacked jar vf and its uri when the vfs path
     * contains spaces
@@ -1059,7 +1068,7 @@
       VirtualFile tstjar = vfs.findChild("path with spaces/unpacked-tst.jar");
       assertNotNull("tstjar != null", tstjar);
       URI uri = tstjar.toURI();
-      URI expectedURI = new URI(rootURL.toString()+"/path%20with%20spaces/unpacked-tst.jar/");
+      URI expectedURI = new URI("vfs" + rootURL.toString()+"/path%20with%20spaces/unpacked-tst.jar/");
       assertEquals(uri, expectedURI);
    }
 

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java	2006-12-07 22:33:10 UTC (rev 58919)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java	2006-12-08 01:43:14 UTC (rev 58920)
@@ -29,8 +29,7 @@
       log.info(mf);
       
       URL expected = new URL(url, "jar1.jar");
-      expected = JarUtils.createJarURL(expected);
-      expected = new URL(expected, "META-INF/MANIFEST.MF");
+      expected = new URL("vfs" + expected + "/META-INF/MANIFEST.MF");
       assertEquals(expected, mf);
 
       Class c = cl.loadClass("org.jboss.test.vfs.support.jar1.ClassInJar1");



From norman.richards at jboss.com  Thu Dec  7 20:58:38 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 20:58:38 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GsV0Y-000871-5I@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 20:58:38

  Modified:    doc/reference/en/modules  controls.xml
  Log:
  document selectDate
  
  Revision  Changes    Path
  1.9       +300 -279  jboss-seam/doc/reference/en/modules/controls.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: controls.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/controls.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- controls.xml	20 Nov 2006 20:16:14 -0000	1.8
  +++ controls.xml	8 Dec 2006 01:58:38 -0000	1.9
  @@ -202,6 +202,27 @@
                  </itemizedlist>
              </listitem>
          </varlistentry>
  +        
  +        <varlistentry>
  +            <term><literal>&lt;s:selectDate&gt;</literal></term>
  +            <listitem>
  +                <para>
  +                    Displays a dynamic date picker component that selects a date 
  +                    for the specified input field.  The body of the selectDate element should
  +                    contain HTML elements (that indicate 
  +                </para>
  +                
  +                <itemizedlist>
  +                    <listitem><para><literal>for</literal> &mdash;
  +                        The id of the input field that the date picker will insert the
  +                        selected date into.
  +                    </para></listitem>
  +                </itemizedlist>
  +                
  +                
  +            </listitem>
  +        </varlistentry>
  +        
          <varlistentry>
              <term><literal>&lt;s:conversationPropagation&gt;</literal></term>
              <listitem>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 21:12:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 21:12:14 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1724 -
	branches/Branch_Client_Failover_Experiment/tests/bin
Message-ID: <E1GsVDi-00006w-H0@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-07 21:12:13 -0500 (Thu, 07 Dec 2006)
New Revision: 1724

Modified:
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
Log:
enabling debugging for clustered tests

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-08 01:08:12 UTC (rev 1723)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-08 02:12:13 UTC (rev 1724)
@@ -95,8 +95,11 @@
         REMOTE_TEST="-Dremote=true"
     fi
     if [ "$1" = "-remotedebug" ]; then
-        REMOTE_DEBUG_FLAG="-debug"
+        remote_debug=true
     fi
+    if [ "$1" = "0" -o "$1" = "1" -o "$1" = "2" ]; then
+        remote_debug_index=$1
+    fi
     if [ "$1" = "-clustered" ]; then
         TEST_CLUSTERED=true
     fi
@@ -109,20 +112,32 @@
    TARGET_TEST="-t $TARGET_TEST"
 fi
 
+if [ "$remote_debug" = "true" ]; then
+   if [ "$remote_debug_index" = "" ]; then
+      REMOTE_DEBUG_FLAG_0="-debug"
+   elif [ "$remote_debug_index" = "1" ]; then
+      REMOTE_DEBUG_FLAG_1="-debug"
+   elif [ "$remote_debug_index" = "2" ]; then
+      REMOTE_DEBUG_FLAG_2="-debug"
+   else
+      echo "Invalid argument: $remote_debug_index"
+      exit 1
+   fi
+fi
+
 if [ "$isRemote" = "true" ]; then
 
   export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED
 
-  #$reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file
-  $reldir/start-rmi-server -use-existent-test-classpath-file -index 0
+  $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_0 -use-existent-test-classpath-file -index 0
 
   if [ "$TEST_CLUSTERED" = "true" ]; then
 
      # start the second remote server
-     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file -index 1
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_1 -use-existent-test-classpath-file -index 1
 
      # start the third remote server
-     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file -index 2
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_2 -use-existent-test-classpath-file -index 2
   fi
 
 fi



From norman.richards at jboss.com  Thu Dec  7 22:01:02 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 07 Dec 2006 22:01:02 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules   ...
Message-ID: <E1GsVyw-0000jz-BG@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/07 22:01:02

  Modified:    doc/reference/en/modules   controls.xml xml.xml
  Log:
  explicitly list the namespaces
  
  Revision  Changes    Path
  1.10      +2 -1      jboss-seam/doc/reference/en/modules/controls.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: controls.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/controls.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- controls.xml	8 Dec 2006 01:58:38 -0000	1.9
  +++ controls.xml	8 Dec 2006 03:01:02 -0000	1.10
  @@ -209,7 +209,8 @@
                   <para>
                       Displays a dynamic date picker component that selects a date 
                       for the specified input field.  The body of the selectDate element should
  -                    contain HTML elements (that indicate 
  +                    contain HTML elements, such as text or an image, that prompt the user to click
  +                    to display the date picker. 
                   </para>
                   
                   <itemizedlist>
  
  
  
  1.2       +489 -465  jboss-seam/doc/reference/en/modules/xml.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: xml.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/xml.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- xml.xml	29 Nov 2006 21:53:11 -0000	1.1
  +++ xml.xml	8 Dec 2006 03:01:02 -0000	1.2
  @@ -459,6 +459,30 @@
                   be used for guidance.   
               </para>
               
  +            <para>The following are the the namespaces used by Seam:</para>
  +        <itemizedlist>
  +            <listitem>
  +                <para>components &mdash; <literal>http://jboss.com/products/seam/components</literal></para>
  +            </listitem>
  +            <listitem>
  +                <para>core &mdash; <literal>http://jboss.com/products/seam/core</literal></para>
  +            </listitem>
  +            <listitem>
  +                <para>drools &mdash; <literal>http://jboss.com/products/seam/drools</literal></para>
  +            </listitem>
  +            <listitem>
  +                <para>framework &mdash; <literal>http://jboss.com/products/seam/framework</literal></para>
  +            </listitem>
  +            <listitem>
  +                <para>jms &mdash; <literal>http://jboss.com/products/seam/jms</literal></para>
  +            </listitem>
  +            <listitem>
  +                <para>remoting &mdash; <literal>http://jboss.com/products/seam/remoting</literal></para>
  +            </listitem>
  +            <listitem>
  +                <para>theme &mdash; <literal>http://jboss.com/products/seam/theme</literal></para>
  +            </listitem>
  +        </itemizedlist>
           </sect1>
   
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec  7 22:07:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 07 Dec 2006 22:07:41 -0500
Subject: [jboss-cvs] JBossAS SVN: r58921 - in branches/JBoss_4_0_3_SP1_CP:
	testsuite/imports testsuite/src/main/org/jboss/test
	testsuite/src/main/org/jboss/test/web/test
	testsuite/src/resources/test-configs/tomcat-sso/deploy/jbossweb-tomcat55.sar
	testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar
	testsuite/src/resources/web/sso/war
	tomcat/src/main/org/jboss/web/tomcat/tc5/session
	tomcat/src/main/org/jboss/web/tomcat/tc5/sso
Message-ID: <E1GsW5N-0000zj-Mq@committer01.frg.pub.inap.atl.jboss.com>

Author: vivekl at redhat.com
Date: 2006-12-07 22:07:36 -0500 (Thu, 07 Dec 2006)
New Revision: 58921

Removed:
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/context.xml
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso/deploy/jbossweb-tomcat55.sar/context.xml
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/index.jsp
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/isValid.jsp
Modified:
   branches/JBoss_4_0_3_SP1_CP/testsuite/imports/test-jars.xml
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossClusteredTestCase.java
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossTestClusteredServices.java
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/server.xml
   branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/web-sso-expire.xml
   branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossManager.java
   branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/ClusteredSingleSignOn.java
   branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/TreeCacheSSOClusterManager.java
   branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/mbeans-descriptors.xml
Log:
ASPATCH129: JBAS-3808: Port JBAS-3096 Fix to 4.0.3.SP1
Revision 58722 reverted since this is not meant for a CP release.



Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/imports/test-jars.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/imports/test-jars.xml	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/imports/test-jars.xml	2006-12-08 03:07:36 UTC (rev 58921)
@@ -5086,7 +5086,6 @@
       </classes>
       <fileset dir="${build.resources}/web/sso/war">
         <include name="**/*.html"/>
-        <include name="**/*.jsp"/>
       </fileset>
     </war>
     <war destfile="${build.lib}/sso-expire.war"
@@ -5100,7 +5099,6 @@
       </classes>
       <fileset dir="${build.resources}/web/sso/war">
         <include name="**/*.html"/>
-        <include name="**/*.jsp"/>
       </fileset>
     </war>
     <zip destfile="${build.lib}/web-sso.ear">

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossClusteredTestCase.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossClusteredTestCase.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossClusteredTestCase.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -63,16 +63,6 @@
       return clusterServices.getHttpURLs();
    }
 
-   protected void deploy(RMIAdaptor server, String name) throws Exception
-   {
-      clusterServices.deploy(server, name);
-   }
-
-   protected void undeploy(RMIAdaptor server, String name) throws Exception
-   {
-      clusterServices.undeploy(server, name);
-   }
-
    public static Test getDeploySetup(final Test test, final String jarName)
       throws Exception
    {

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossTestClusteredServices.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossTestClusteredServices.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/JBossTestClusteredServices.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -6,7 +6,6 @@
  */
 package org.jboss.test;
 
-import java.net.URL;
 import java.util.ArrayList;
 import java.util.Hashtable;
 
@@ -134,53 +133,6 @@
 
    }
 
-   /**
-    * Deploy a package on the given server with the main deployer. The supplied 
-    * name is interpreted as a url, or as a filename in jbosstest.deploy.lib or 
-    * ../lib.
-    *
-    * @param server         server on which the package should be deployed
-    * @param name           filename/url of package to deploy.
-    * @exception Exception  Description of Exception
-    */
-   public void deploy(RMIAdaptor server, String name) throws Exception
-   {
-      if (Boolean.getBoolean("jbosstest.nodeploy") == true)
-      {
-         log.debug("Skipping deployment of: " + name);
-         return;
-      }
-
-      URL deployURL = new URL(getDeployURL(name));
-      log.debug("Deploying " + name + ", url=" + deployURL  + " to " + server);
-      invoke(server,
-            getDeployerName(),
-            "deploy",
-            new Object[]{deployURL},
-            new String[]{"java.net.URL"});
-   }
-
-   /**
-    * Undeploy a package from the given server with the main deployer. 
-    * The supplied name is interpreted as a url, or as a filename in 
-    * jbosstest.deploy.lib or ../lib.
-    *
-    * @param server         server on which the package should be deployed
-    * @param name           filename/url of package to undeploy.
-    * @exception Exception  Description of Exception
-    */
-   public void undeploy(RMIAdaptor server, String name) throws Exception
-   {
-      if (Boolean.getBoolean("jbosstest.nodeploy") == true)
-         return;
-
-      URL deployURL = new URL(getDeployURL(name));
-      log.debug("Undeploying " + name + ", url=" + deployURL);
-      Object[] args = {deployURL};
-      String[] sig = {"java.net.URL"};
-      invoke(server, getDeployerName(), "undeploy", args, sig);
-   }
-
    public void init() throws Exception
    {
       if (initialContext == null)

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,37 +1,23 @@
 /*
-* JBoss, a division of Red Hat
-* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+
 package org.jboss.test.web.test;
 
-import java.util.Set;
+import java.net.HttpURLConnection;
 
-import javax.management.ObjectName;
-
 import junit.framework.Test;
-import junit.framework.TestSuite;
 
+import org.apache.commons.httpclient.Cookie;
+import org.apache.commons.httpclient.Header;
 import org.apache.commons.httpclient.HttpClient;
 import org.apache.commons.httpclient.HttpState;
-import org.jboss.cache.Fqn;
-import org.jboss.jmx.adaptor.rmi.RMIAdaptor;
+import org.apache.commons.httpclient.methods.GetMethod;
+import org.apache.commons.httpclient.methods.PostMethod;
+import org.apache.log4j.Category;
 import org.jboss.test.JBossClusteredTestCase;
 
 
@@ -43,13 +29,6 @@
 public class ClusteredSingleSignOnUnitTestCase 
       extends JBossClusteredTestCase
 {   
-   // NOTE: these variables must be static as apparently a separate instance
-   // of this class is created for each test
-   private static boolean deployed0 = true;
-   private static boolean deployed1 = true;
-   
-   private RMIAdaptor[] adaptors = null;
-   
    public ClusteredSingleSignOnUnitTestCase(String name)
    {
       super(name);
@@ -59,119 +38,11 @@
     */
    public static Test suite() throws Exception
    {
-      // Have to build the suite in detail, as testSessionExpiration must come first
-      TestSuite suite = new TestSuite();
-      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testSessionExpiration"));
-      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testFormAuthSingleSignOn"));
-      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testWebappUndeploy"));
-      
-//      return JBossClusteredTestCase.getDeploySetup(suite, "web-sso-clustered.ear");
-      
-      return JBossClusteredTestCase.getDeploySetup(suite, "web-sso.ear");
+      Test t1 = JBossClusteredTestCase.getDeploySetup(ClusteredSingleSignOnUnitTestCase.class,
+            "web-sso.ear");
+      return t1;
    }
 
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-      
-      log.debug("deployed0 = " + deployed0);
-      log.debug("deployed1 = " + deployed1);
-      
-      adaptors = getAdaptors(); 
-      if (!deployed0)
-      {
-//         deploy(adaptors[0], "web-sso-clustered.ear");
-         deploy(adaptors[0], "web-sso.ear");
-         deployed0 = true;
-      }
-      if (!deployed1)
-      {
-//         deploy(adaptors[1], "web-sso-clustered.ear");
-         deploy(adaptors[1], "web-sso.ear");
-         deployed1 = true;
-      }
-   }
-   
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-      
-      log.debug("deployed0 = " + deployed0);
-      log.debug("deployed1 = " + deployed1);
-   }
-   
-   /**
-    * Tests that undeploying a webapp on one server doesn't kill an sso
-    * that also has a session from another webapp associated with it.
-    * See JBAS-2429.
-    * 
-    * TODO create an independently deployable war so we can test this in
-    *      a non-clustered environment as well; this isn't a clustering issue 
-    *
-    * @throws Exception
-    */
-   public void testWebappUndeploy() throws Exception
-   {
-      log.info("+++ testWebappUndeploy");
-      
-      String[] httpURLs  = super.getHttpURLs();
-
-      String serverA = httpURLs[0];
-      String serverB = httpURLs[1];
-      
-      String warA1 = serverA + "/war1/";
-      String warB1 = serverB + "/war1/";
-      String warB2 = serverB + "/war2/";
-      
-      // Start by accessing the secured index.html of war1
-      HttpClient httpConn = new HttpClient();
-      SSOBaseCase.checkAccessDenied(httpConn,  warA1 + "index.html");
-
-      HttpState state = httpConn.getState();
-      
-      String sessionID = SSOBaseCase.getSessionIdFromState(state);
-      log.debug("Saw JSESSIONID="+sessionID);
-      
-      // Submit the login form
-      SSOBaseCase.executeFormLogin(httpConn, warA1);
-
-      String ssoID = SSOBaseCase.processSSOCookie(state, serverA, serverB);
-      log.debug("Saw JSESSIONIDSSO="+ssoID);
-
-      // Pause a moment before switching wars to better simulate real life
-      // use cases.  Otherwise, the test case can "outrun" the async
-      // replication in the TreeCache used by the clustered SSO
-      // 500 ms is a long time, but this isn't a test of replication speed
-      // and we don't want spurious failures.
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
-
-      // Now try getting the war2 index using the JSESSIONIDSSO cookie 
-      log.debug("Prepare /war2/index.html get");
-      SSOBaseCase.checkAccessAllowed(httpConn, warB2 + "index.html");
-
-      // Sleep some more to allow the updated sso to propagate back to serverA
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
-      
-      // We now have a clustered sso context, plus a war1 session on
-      // serverA and a war2 session on serverB. No war1 session on serverB,
-      // so the only way to access war1 on B without a login is through sso.
-      
-      //Undeploy the ear from serverA and confirm that it doesn't kill the sso
-//      undeploy(adaptors[0], "web-sso-clustered.ear");
-      undeploy(adaptors[0], "web-sso.ear");
-      deployed0 = false;
-
-      // Sleep some more to allow the updated sso to propagate back to serverB
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
-      
-      // Now try getting the war1 index using the JSESSIONIDSSO cookie 
-      log.debug("Prepare /war1/index.html get");
-      SSOBaseCase.checkAccessAllowed(httpConn, warB1 + "index.html");
-   }
-
    /** Test single sign-on across two web apps using form based auth
     * 
     * @throws Exception
@@ -193,83 +64,81 @@
     * Tests that use of transactions in ClusteredSSO does not interfere 
     * with session expiration thread.  See JBAS-2212.
     * 
+    * TODO  this is a quick-and-dirty test to get JBoss 4.0.3 out;
+    *       clearly needs to be refactored
+    * 
     * @throws Exception
     */ 
    public void testSessionExpiration() 
          throws Exception
    {
-      log.info("+++ testSessionExpiration");
+      log.info("+++ testFormAuthSingleSignOn");
       String[] httpURLs  = super.getHttpURLs();
 
       String serverA = httpURLs[0];
-      String serverB = httpURLs[1];
       log.info(System.getProperties());
       log.info("serverA: "+serverA);
-      log.info("serverB: "+serverB);
       
-      String warA3 = serverA + "/war3/";
-      String warB3 = serverB + "/war3/";
-      
-      // First create an SSO that we won't use again -- we later test that it
-      // gets cleaned up from the cache
-      HttpClient httpConn1 = new HttpClient();
-      SSOBaseCase.checkAccessDenied(httpConn1, warA3 + "index.jsp");
-      SSOBaseCase.executeFormLogin(httpConn1, warA3);
-      
-      // Now the standard SSO tests
+      // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();
-      SSOBaseCase.checkAccessDenied(httpConn, warA3 + "index.jsp");
-      HttpState state = httpConn.getState();      
-      String sessionID = SSOBaseCase.getSessionIdFromState(state);
-      log.debug("Saw JSESSIONID="+sessionID);
-      SSOBaseCase.executeFormLogin(httpConn, warA3);
-      String ssoID = SSOBaseCase.processSSOCookie(state, serverA, serverB);
-      log.debug("Saw JSESSIONIDSSO="+ssoID);
+      GetMethod indexGet = new GetMethod(serverA+"/war3/index.html");
+      int responseCode = httpConn.executeMethod(indexGet);
+      String body = indexGet.getResponseBodyAsString();
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
 
-      // Wait more than 15 secs to let session time out
-      // It's life is 5 secs and the processor runs every 10
-      try {
-         Thread.sleep(15500);
-      }
-      catch (InterruptedException ie)
+      HttpState state = httpConn.getState();
+      Cookie[] cookies = state.getCookies();
+      String sessionID = null;
+      for(int c = 0; c < cookies.length; c ++)
       {
-         log.debug("Interrupted while waiting for session expiration");
+         Cookie k = cookies[c];
+         if( k.getName().equalsIgnoreCase("JSESSIONID") )
+            sessionID = k.getValue();
       }
-      
-      // Try accessing war3 again on both nodes -- should succeed
-      SSOBaseCase.checkAccessAllowed(httpConn, warA3 + "index.jsp");
-      SSOBaseCase.checkAccessAllowed(httpConn, warB3 + "index.jsp");
+      log.debug("Saw JSESSIONID="+sessionID);
 
-      // Wait more than 30 secs to let SSO time out -- 15 for the sessions
-      // (as above) and 15 for the SSOs maxEmptyLife
+      // Submit the login form
+      PostMethod formPost = new PostMethod(serverA+"/war3/j_security_check");
+      formPost.addRequestHeader("Referer", serverA+"/war3/login.html");
+      formPost.addParameter("j_username", "jduke");
+      formPost.addParameter("j_password", "theduke");
+      responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
+         formPost, state);
+      String response = formPost.getStatusText();
+      log.debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Saw HTTP_MOVED_TEMP("+responseCode+")",
+         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
+
+      //  Follow the redirect to the index.html page
+      Header location = formPost.getResponseHeader("Location");
+      String indexURI = location.getValue();
+      GetMethod war1Index = new GetMethod(indexURI);
+      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
+         war1Index, state);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war1Index.getResponseBodyAsString();
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of "+indexURI+" redirected to login page");
+
+      // Wait more than 1 minute to let session time out
       try {
-         Thread.sleep(30500);
+         Thread.sleep(75000);
       }
       catch (InterruptedException ie)
       {
-         log.debug("Interrupted while waiting for SSO expiration");
+         log.debug("Interrupted while waiting for session expiration");
       }
       
-      // Try accessing war3 again on both nodes -- should fail
-      SSOBaseCase.checkAccessDenied(httpConn, warA3 + "index.jsp");
-      SSOBaseCase.checkAccessDenied(httpConn, warB3 + "index.jsp");
+      // Try accessing war1 again
+      war1Index = new GetMethod(serverA+"/war3/index.html");
+      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
+         war1Index, state);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war1Index.getResponseBodyAsString();
+      log.debug("body: " + body);
+      if( body.indexOf("j_security_check") < 0 )
+         fail("get of /war1/index.html not redirected to login page");
       
-      // Confirm that the SSO we created at the start was removed from
-      // the cache
-      Set ssoIds = getSSOIds(adaptors[0]);
-      log.info("node0 sso ids are " + ssoIds);
-      assertEquals("node0 cache has no SSOs", 0, ssoIds.size());
-      ssoIds = getSSOIds(adaptors[1]);
-      log.info("node1 sso ids are " + ssoIds);
-      assertEquals("node1 cache has no SSOs", 0, ssoIds.size());
    }
-   
-   private Set getSSOIds(RMIAdaptor adaptor) throws Exception
- {
-    Fqn ssoRoot = new Fqn(new Object[] {"SSO"});
-    ObjectName oname = new ObjectName("jboss.cache:service=TomcatClusteringCache");
-    return (Set) adaptor.invoke(oname, "getChildrenNames", 
-                               new Object[]{ ssoRoot }, 
-                               new String[]{ Fqn.class.getName() });
- }
 }

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,34 +1,18 @@
 /*
-* JBoss, a division of Red Hat
-* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+
 package org.jboss.test.web.test;
 
-import java.io.IOException;
 import java.net.HttpURLConnection;
 
 import junit.framework.TestCase;
 import org.apache.commons.httpclient.Cookie;
 import org.apache.commons.httpclient.Header;
 import org.apache.commons.httpclient.HttpClient;
-import org.apache.commons.httpclient.HttpException;
 import org.apache.commons.httpclient.HttpState;
 import org.apache.commons.httpclient.methods.GetMethod;
 import org.apache.commons.httpclient.methods.PostMethod;
@@ -51,137 +35,132 @@
                                                   Category log) 
          throws Exception
    {
-      String warA1 = serverA + "/war1/";
-      String warB2 = serverB + "/war2/";
-      
       // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();
-      
-      checkAccessDenied(httpConn, warA1 + "index.html");
+      GetMethod indexGet = new GetMethod(serverA+"/war1/index.html");
+      int responseCode = httpConn.executeMethod(indexGet);
+      String body = indexGet.getResponseBodyAsString();
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
 
       HttpState state = httpConn.getState();
-      
-      String sessionID = getSessionIdFromState(state);
+      Cookie[] cookies = state.getCookies();
+      String sessionID = null;
+      for(int c = 0; c < cookies.length; c ++)
+      {
+         Cookie k = cookies[c];
+         if( k.getName().equalsIgnoreCase("JSESSIONID") )
+            sessionID = k.getValue();
+      }
       log.debug("Saw JSESSIONID="+sessionID);
 
       // Submit the login form
-      executeFormLogin(httpConn, warA1);
-
-      String ssoID = processSSOCookie(state, serverA, serverB);
-      log.debug("Saw JSESSIONIDSSO="+ssoID);
-
-      // Pause a moment before switching wars to better simulate real life
-      // use cases.  Otherwise, the test case can "outrun" the async
-      // replication in the TreeCache used by the clustered SSO
-      // 500 ms is a long time, but this isn't a test of replication speed
-      // and we don't want spurious failures.
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
-
-      // Now try getting the war2 index using the JSESSIONIDSSO cookie 
-      log.debug("Prepare /war2/index.html get");
-      checkAccessAllowed(httpConn, warB2 + "index.html");
-
-      /* Access a secured servlet that calls a secured ejb in war2 to test
-      propagation of the SSO identity to the ejb container. */
-      checkAccessAllowed(httpConn, warB2 + "EJBServlet");
-
-      // Now try logging out of war2 
-      executeLogout(httpConn, warB2);
-      
-      // Again, pause before switching wars
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
-      
-      // Try accessing war1 again      
-      checkAccessDenied(httpConn, warA1 + "index.html");
-      
-      // Try accessing war2 again      
-      checkAccessDenied(httpConn, warB2 + "index.html");      
-      
-   }
-
-   public static void executeLogout(HttpClient httpConn, String warURL) throws IOException, HttpException
-   {
-      GetMethod logout = new GetMethod(warURL + "Logout");
-      logout.setFollowRedirects(false);
-      int responseCode = httpConn.executeMethod(logout.getHostConfiguration(),
-         logout, httpConn.getState());
-      assertTrue("Logout: Saw HTTP_MOVED_TEMP("+responseCode+")",
-         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
-      Header location = logout.getResponseHeader("Location");
-      String indexURI = location.getValue();
-      if( indexURI.indexOf("index.html") < 0 )
-         fail("get of " + warURL + "Logout not redirected to login page");
-   }
-
-   public static void checkAccessAllowed(HttpClient httpConn, String url) throws IOException, HttpException
-   {
-      GetMethod war2Index = new GetMethod(url);
-      int responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
-         war2Index, httpConn.getState());
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      String body = war2Index.getResponseBodyAsString();
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of " + url + " redirected to login page");
-   }
-
-   public static void executeFormLogin(HttpClient httpConn, String warURL) throws IOException, HttpException
-   {      
-      PostMethod formPost = new PostMethod(warURL + "j_security_check");
-      formPost.addRequestHeader("Referer", warURL + "login.html");
+      PostMethod formPost = new PostMethod(serverA+"/war1/j_security_check");
+      formPost.addRequestHeader("Referer", serverA+"/war1/login.html");
       formPost.addParameter("j_username", "jduke");
       formPost.addParameter("j_password", "theduke");
-      int responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
-         formPost, httpConn.getState());
+      responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
+         formPost, state);
+      String response = formPost.getStatusText();
+      log.debug("responseCode="+responseCode+", response="+response);
       assertTrue("Saw HTTP_MOVED_TEMP("+responseCode+")",
          responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
 
       //  Follow the redirect to the index.html page
       Header location = formPost.getResponseHeader("Location");
       String indexURI = location.getValue();
-      GetMethod warIndex = new GetMethod(indexURI);
-      responseCode = httpConn.executeMethod(warIndex.getHostConfiguration(),
-         warIndex, httpConn.getState());
+      GetMethod war1Index = new GetMethod(indexURI);
+      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
+         war1Index, state);
       assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      String body = warIndex.getResponseBodyAsString();
+      body = war1Index.getResponseBodyAsString();
       if( body.indexOf("j_security_check") > 0 )
          fail("get of "+indexURI+" redirected to login page");
-   }
 
-   public static void checkAccessDenied(HttpClient httpConn, String url) throws IOException, HttpException
-   {
-      GetMethod indexGet = new GetMethod(url);
-      int responseCode = httpConn.executeMethod(indexGet);
-      String body = indexGet.getResponseBodyAsString();
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
-   }
-
-   public static String processSSOCookie(HttpState state, String serverA, String serverB)
-   {
-      Cookie[] cookies = state.getCookies();
+      cookies = state.getCookies();
       String ssoID = null;
       for(int c = 0; c < cookies.length; c ++)
       {
-         if( "JSESSIONIDSSO".equalsIgnoreCase(cookies[c].getName()) )
+         Cookie k = cookies[c];
+         if( k.getName().equalsIgnoreCase("JSESSIONIDSSO") )
          {
-            ssoID = cookies[c].getValue();
+            ssoID = k.getValue();
             if (serverA.equals(serverB) == false) 
             {
                // Make an sso cookie to send to serverB
-               Cookie copy = copyCookie(cookies[c], serverB);
+               Cookie copy = copyCookie(k, serverB);
                state.addCookie(copy);
+               log.debug("Added state cookie: "+copy);
             }
          }
       }
+      assertTrue("Saw JSESSIONIDSSO", ssoID != null);
+      log.debug("Saw JSESSIONIDSSO="+ssoID);
+
+      // Now try getting the war2 index using the JSESSIONIDSSO cookie 
+      log.debug("Prepare /war2/index.html get");
+      GetMethod war2Index = new GetMethod(serverB+"/war2/index.html");
+      responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
+         war2Index, state);
+      response = war2Index.getStatusText();
+      log.debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war2Index.getResponseBodyAsString();
+      log.debug("body: "+body);
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of /war2/index.html redirected to login page");
+
+      /* Access a secured servlet that calls a secured ejb in war2 to test
+      propagation of the SSO identity to the ejb container.
+      */
+      GetMethod war2Servlet = new GetMethod(serverB+"/war2/EJBServlet");
+      responseCode = httpConn.executeMethod(war2Servlet.getHostConfiguration(),
+         war2Servlet, state);
+      response = war2Servlet.getStatusText();
+      log.debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war2Servlet.getResponseBodyAsString();
+      log.debug("body: "+body);
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of /war2/EJBServlet redirected to login page");
+
+      // Now try logging out of war2 
+      GetMethod war2Logout = new GetMethod(serverB+"/war2/Logout");
+      war2Logout.setFollowRedirects(false);
+      responseCode = httpConn.executeMethod(war2Logout.getHostConfiguration(),
+         war2Logout, state);
+      response = war2Logout.getStatusText();
+      log.debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Logout: Saw HTTP_MOVED_TEMP("+responseCode+")",
+         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
+      location = war2Logout.getResponseHeader("Location");
+      indexURI = location.getValue();
+      if( indexURI.indexOf("index.html") < 0 )
+         fail("get of /war2/Logout not redirected to login page");
       
-      assertNotNull("Saw JSESSIONIDSSO", ssoID);
+      // Try accessing war1 again
+      war1Index = new GetMethod(serverA+"/war1/index.html");
+      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
+         war1Index, state);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war1Index.getResponseBodyAsString();
+      log.debug("body: " + body);
+      if( body.indexOf("j_security_check") < 0 )
+         fail("get of /war1/index.html not redirected to login page");
       
-      return ssoID;
+      // Try accessing war2 again
+      war2Index = new GetMethod(serverB+"/war2/index.html");
+      responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
+         war2Index, state);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war2Index.getResponseBodyAsString();
+      log.debug("body: " + body);
+      if( body.indexOf("j_security_check") < 0 )
+         fail("get of /war2/index.html not redirected to login page");      
+      
    }
    
-   public static Cookie copyCookie(Cookie toCopy, String targetServer)
+   private static Cookie copyCookie(Cookie toCopy, String targetServer)
    {
       // Parse the target server down to a domain name
       int index = targetServer.indexOf("://");
@@ -208,17 +187,4 @@
                                false);
       return copy;
    }
-   
-   public static String getSessionIdFromState(HttpState state)
-   {
-      Cookie[] cookies = state.getCookies();
-      String sessionID = null;
-      for(int c = 0; c < cookies.length; c ++)
-      {
-         if( "JSESSIONID".equalsIgnoreCase(cookies[c].getName()) )
-            sessionID = cookies[c].getName();
-      }
-      return sessionID;
-      
-   }
 }

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,26 +1,20 @@
 /*
-* JBoss, a division of Red Hat
-* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, the OpenSource J2EE webOS
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+
 package org.jboss.test.web.test;
 
+import java.net.HttpURLConnection;
+
+import org.apache.commons.httpclient.Cookie;
+import org.apache.commons.httpclient.Header;
+import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.HttpState;
+import org.apache.commons.httpclient.methods.PostMethod;
+import org.apache.commons.httpclient.methods.GetMethod;
 import org.jboss.test.JBossTestCase;
 import org.jboss.test.JBossTestSetup;
 import junit.framework.Test;
@@ -33,7 +27,7 @@
  */
 public class SingleSignOnUnitTestCase extends JBossTestCase
 {
-   private String baseURLNoAuth = "http://" + getServerHost() + ":" + Integer.getInteger("web.port", 8080); 
+   private String baseURLNoAuth = "http://" + getServerHost() + ":" + Integer.getInteger("web.port", 8080) + "/"; 
 
    public SingleSignOnUnitTestCase(String name)
    {
@@ -46,12 +40,86 @@
     */ 
    public void testFormAuthSingleSignOn() throws Exception
    {
-      log.info("+++ testFormAuthSingleSignOn");
+      // Start by accessing the secured index.html of war1
+      HttpClient httpConn = new HttpClient();
+      GetMethod indexGet = new GetMethod(baseURLNoAuth+"war1/index.html");
+      int responseCode = httpConn.executeMethod(indexGet);
+      String body = indexGet.getResponseBodyAsString();
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
 
-      SSOBaseCase.executeFormAuthSingleSignOnTest(baseURLNoAuth, baseURLNoAuth, getLog());
+      HttpState state = httpConn.getState();
+      Cookie[] cookies = state.getCookies();
+      String sessionID = null;
+      for(int c = 0; c < cookies.length; c ++)
+      {
+         Cookie k = cookies[c];
+         if( k.getName().equalsIgnoreCase("JSESSIONID") )
+            sessionID = k.getValue();
+      }
+      getLog().debug("Saw JSESSIONID="+sessionID);
 
+      // Submit the login form
+      PostMethod formPost = new PostMethod(baseURLNoAuth+"war1/j_security_check");
+      formPost.addRequestHeader("Referer", baseURLNoAuth+"war1/login.html");
+      formPost.addParameter("j_username", "jduke");
+      formPost.addParameter("j_password", "theduke");
+      responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
+         formPost, state);
+      String response = formPost.getStatusText();
+      getLog().debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Saw HTTP_MOVED_TEMP("+responseCode+")",
+         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
+
+      //  Follow the redirect to the index.html page
+      Header location = formPost.getResponseHeader("Location");
+      String indexURI = location.getValue();
+      GetMethod war1Index = new GetMethod(indexURI);
+      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
+         war1Index, state);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war1Index.getResponseBodyAsString();
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of "+indexURI+" redirected to login page");
+
+      cookies = state.getCookies();
+      String ssoID = null;
+      for(int c = 0; c < cookies.length; c ++)
+      {
+         Cookie k = cookies[c];
+         if( k.getName().equalsIgnoreCase("JSESSIONIDSSO") )
+            ssoID = k.getValue();
       }
+      assertTrue("Saw JSESSIONIDSSO", ssoID != null);
+      getLog().debug("Saw JSESSIONIDSSO="+ssoID);
 
+      // Now try getting the war2 index using the JSESSIONIDSSO cookie 
+      GetMethod war2Index = new GetMethod(baseURLNoAuth+"war2/index.html");
+      responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
+         war2Index, state);
+      response = war2Index.getStatusText();
+      getLog().debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war2Index.getResponseBodyAsString();
+      getLog().debug("body: "+body);
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of /war2/index.html redirected to login page");
+
+      /* Access a secured servlet that calls a secured ejb in war2 to test
+      propagation of the SSO identity to the ejb container.
+      */
+      GetMethod war2Servlet = new GetMethod(baseURLNoAuth+"war2/EJBServlet");
+      responseCode = httpConn.executeMethod(war2Servlet.getHostConfiguration(),
+         war2Servlet, state);
+      response = war2Servlet.getStatusText();
+      getLog().debug("responseCode="+responseCode+", response="+response);
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      body = war2Servlet.getResponseBodyAsString();
+      getLog().debug("body: "+body);
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of /war2/EJBServlet redirected to login page");
+   }
+
    /** One time setup for all SingleSignOnUnitTestCase unit tests
     */
    public static Test suite() throws Exception

Deleted: branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso/deploy/jbossweb-tomcat55.sar/context.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso/deploy/jbossweb-tomcat55.sar/context.xml	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso/deploy/jbossweb-tomcat55.sar/context.xml	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,13 +0,0 @@
-<!-- The contents of this file will be loaded for each web application -->
-<Context cookies="true" crossContext="true">
-   
-   <!-- We want a low processExpiresFrequency so we can have 
-        fast turnaround of expiration tests -->
-   <Manager pathname="" processExpiresFrequency="1"/>
-
-   <!-- Install an InstanceListener to handle the establishment of the run-as
-   role for servlet init/destroy events.
-   -->
-   <InstanceListener>org.jboss.web.tomcat.security.RunAsListener</InstanceListener>
-   
-</Context>

Deleted: branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/context.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/context.xml	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/context.xml	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,13 +0,0 @@
-<!-- The contents of this file will be loaded for each web application -->
-<Context cookies="true" crossContext="true">
-   
-   <!-- We want a low processExpiresFrequency so we can have 
-        fast turnaround of expiration tests -->
-   <Manager pathname="" processExpiresFrequency="1"/>
-
-   <!-- Install an InstanceListener to handle the establishment of the run-as
-   role for servlet init/destroy events.
-   -->
-   <InstanceListener>org.jboss.web.tomcat.security.RunAsListener</InstanceListener>
-   
-</Context>

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/server.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/server.xml	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/jbossweb-tomcat55.sar/server.xml	2006-12-08 03:07:36 UTC (rev 58921)
@@ -14,7 +14,7 @@
          enableLookups="false" redirectPort="8443" acceptCount="100"
          connectionTimeout="20000" disableUploadTimeout="true"/>
 
-      <Engine name="jboss.web" defaultHost="localhost" backgroundProcessorDelay="10">
+      <Engine name="jboss.web" defaultHost="localhost">
 
          <!-- The JAAS based authentication and authorization realm implementation
             - certificatePrincipal : the class name of the
@@ -32,7 +32,7 @@
                deployed to this host. Provides SSO across a cluster.
             -->
             <Valve className="org.jboss.web.tomcat.tc5.sso.ClusteredSingleSignOn"
-               debug="2" maxEmptyLife="11" processExpiresInterval="5"/>
+               debug="2" />
          
             <!-- Default context parameters -->
             <DefaultContext cookies="true" crossContext="true" override="true"/>

Deleted: branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/index.jsp
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/index.jsp	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/index.jsp	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,15 +0,0 @@
-<%
-   // Give the session a quick timeout so the timeout test can be short
-	session.setMaxInactiveInterval(5);
-%>
-
-<!doctype html public "-//w3c//dtd html 4.0 transitional//en">
-<html>
-<head>
-   <title>A Secure Web App</title>
-</head>
-
-<body>
-<h1>A Secure Web App</h1>
-</body>
-</html>

Deleted: branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/isValid.jsp
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/isValid.jsp	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/isValid.jsp	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1 +0,0 @@
-<% response.setHeader("X-SessionValid", session.isValid()); %>
\ No newline at end of file

Modified: branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/web-sso-expire.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/web-sso-expire.xml	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/testsuite/src/resources/web/sso/war/web-sso-expire.xml	2006-12-08 03:07:36 UTC (rev 58921)
@@ -5,7 +5,7 @@
 
 <web-app>
    <description>WebApp Integration Tests</description>
-	<!--distributable/-->
+	<distributable/>
    <servlet>
       <servlet-name>LogoutServlet</servlet-name>
       <servlet-class>org.jboss.test.web.servlets.LogoutServlet</servlet-class>
@@ -16,10 +16,6 @@
       <url-pattern>/Logout</url-pattern>
    </servlet-mapping>
 
-   <session-config>
-      <session-timeout>1</session-timeout>
-   </session-config>
-
    <security-constraint>
       <web-resource-collection>
          <web-resource-name>Restricted</web-resource-name>
@@ -32,6 +28,10 @@
       </auth-constraint>
    </security-constraint>
 
+   <session-config>
+      <session-timeout>1</session-timeout>
+   </session-config>
+
    <login-config>
       <auth-method>FORM</auth-method>
       <form-login-config>

Modified: branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossManager.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossManager.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossManager.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -208,15 +208,6 @@
       return sessionIDGenerator_.getSessionId();
    }
 
-   /**
-    * Gets the JMX <code>ObjectName</code> under
-    * which our <code>TreeCache</code> is registered. 
-    */
-   public ObjectName getObjectName()
-   {
-      return objectName_;
-   }
-
    public boolean isUseLocalCache()
    {
       return useLocalCache_;

Modified: branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/ClusteredSingleSignOn.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/ClusteredSingleSignOn.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/ClusteredSingleSignOn.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -8,36 +8,22 @@
 
 
 import org.jboss.web.tomcat.tc5.Tomcat5;
-import org.jboss.web.tomcat.tc5.session.JBossManager;
 
 import java.io.IOException;
 import java.security.Principal;
-import java.util.Collections;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
 
-import javax.management.ObjectName;
 import javax.servlet.ServletException;
 import javax.servlet.http.Cookie;
 
-import org.apache.catalina.Lifecycle;
-import org.apache.catalina.LifecycleEvent;
 import org.apache.catalina.LifecycleException;
-import org.apache.catalina.LifecycleListener;
-import org.apache.catalina.Manager;
 import org.apache.catalina.Session;
 import org.apache.catalina.Realm;
 import org.apache.catalina.SessionEvent;
 import org.apache.catalina.authenticator.Constants;
 import org.apache.catalina.connector.Request;
 import org.apache.catalina.connector.Response;
-import org.apache.catalina.session.ManagerBase;
 
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
 
-
 /**
  * A <strong>Valve</strong> that supports a "single sign on" user experience,
  * where the security identity of a user who successfully authenticates to one
@@ -60,13 +46,8 @@
  */
 public class ClusteredSingleSignOn
    extends org.apache.catalina.authenticator.SingleSignOn
-   implements LifecycleListener
 {
-   /** By default we process expired SSOs no more often than once per minute */
-   public static final int DEFAULT_PROCESS_EXPIRES_INTERVAL = 60;
-   /** By default we let SSOs without active sessions live for 30 mins */
-   public static final int DEFAULT_MAX_EMPTY_LIFE = 1800;
-   
+
    // Override the superclass value
    static
    {
@@ -96,30 +77,6 @@
     */
    private String treeCacheName = Tomcat5.DEFAULT_CACHE_NAME;
 
-   /** Currently started Managers that have associated as session with an SSO */
-   private Set activeManagers = Collections.synchronizedSet(new HashSet());
-   
-   /** Max number of ms an SSO with no active sessions will be usable by a request */
-   private int maxEmptyLife = DEFAULT_MAX_EMPTY_LIFE * 1000;
-   
-   /** 
-    * Minimum number of ms since the last processExpires() run 
-    * before a new run is allowed.
-    */
-   private int processExpiresInterval = DEFAULT_PROCESS_EXPIRES_INTERVAL * 1000;
-   
-   /** Timestamp of the last processExpires() run */
-   private long lastProcessExpires = System.currentTimeMillis();
-   
-   /** 
-    * Map<String, Long> containing the ids of SSOs with no active sessions
-    * and the time at which they entered that state
-    */
-   private Map emptySSOs = new ConcurrentHashMap();
-   
-   /** Used for sync locking of processExpires runs */
-   private final Object mutex = new Object();
-
    // ------------------------------------------------------------- Properties
 
    /**
@@ -238,105 +195,7 @@
       }
    }
 
-   /**
-    * Gets the max number of seconds an SSO with no active sessions will be 
-    * usable by a request.
-    * 
-    * @return a non-negative number
-    * 
-    * @see #DEFAULT_MAX_EMPTY_LIFE    * 
-    * @see #setMaxEmptyLife() 
-    */
-   public int getMaxEmptyLife()
-   {
-      return (maxEmptyLife / 1000);
-   }
 
-
-   /**
-    * Sets the maximum number of seconds an SSO with no active sessions will be 
-    * usable by a request.
-    * <p>
-    * A positive value for this property allows a user to continue to use an SSO
-    * even after all the sessions associated with it have been expired. It does not
-    * keep an SSO alive if a session associated with it has been invalidated due to 
-    * an <code>HttpSession.invalidate()</code> call.
-    * </p>
-    * <p>
-    * The primary purpose of this property is to avoid the situation where a server
-    * on which all of an SSO's sessions lives is shutdown, thus expiring all the
-    * sessions and causing the invalidation of the SSO. A positive value for this
-    * property would give the user an opportunity to fail over to another server
-    * and maintain the SSO.
-    * </p>
-    * 
-    * @param maxEmptyLife a non-negative number
-    * 
-    * @throws IllegalArgumentException if <code>maxEmptyLife < 0</code>
-    */
-   public void setMaxEmptyLife(int maxEmptyLife)
-   {
-      if (maxEmptyLife < 0)
-         throw new IllegalArgumentException("maxEmptyLife must be >= 0");
-      
-      this.maxEmptyLife = maxEmptyLife * 1000;
-   }
-
-
-   /**
-    * Gets the minimum number of seconds since the start of the last check for overaged
-    * SSO's with no active sessions before a new run is allowed.
-    * 
-    * @return a positive number
-    * 
-    * @see #DEFAULT_PROCESS_EXPIRES_INTERVAL
-    * @see #setMaxEmptyLife() 
-    * @see #setProcessExpiresInterval(int)
-    */
-   public int getProcessExpiresInterval()
-   {
-      return processExpiresInterval / 1000;
-   }
-
-   /**
-    * Sets the minimum number of seconds since the start of the last check for overaged
-    * SSO's with no active sessions before a new run is allowed.  During this check,
-    * any such overaged SSOs will be invalidated. 
-    * <p>
-    * Note that setting this value does not imply that a check will be performed
-    * every <code>processExpiresInterval</code> seconds, only that it will not
-    * be performed more often than that.
-    * </p>
-    * 
-    * @param processExpiresInterval a non-negative number. <code>0</code> means
-    *                               the overage check can be performed whenever
-    *                               the container wishes to.
-    *                               
-    * @throws IllegalArgumentException if <code>processExpiresInterval < 1</code>
-    * 
-    * @see #setMaxEmptyLife()
-    */
-   public void setProcessExpiresInterval(int processExpiresInterval)
-   {
-      if (processExpiresInterval < 0)
-         throw new IllegalArgumentException("processExpiresInterval must be >= 0");
-      
-      this.processExpiresInterval = processExpiresInterval * 1000;
-   }
-
-
-   /**
-    * Gets the timestamp of the start of the last check for overaged
-    * SSO's with no active sessions.
-    * 
-    * @see #setProcessExpiresInterval(int)
-    */
-   public long getLastProcessExpires()
-   {
-      return lastProcessExpires;
-   }
-
-
    // ------------------------------------------------------ Lifecycle Methods
 
 
@@ -433,112 +292,25 @@
       if (ssoId == null)
          return;
 
-      try
+      // Was the session destroyed as the result of a timeout?
+      // If so, we'll just remove the expired session from the
+      // SSO.  If the session was logged out, we'll log out
+      // of all sessions associated with the SSO.
+      if ((session.getMaxInactiveInterval() > 0)
+         && (System.currentTimeMillis() - session.getLastAccessedTime() >=
+         session.getMaxInactiveInterval() * 1000))
       {
-         // Was the session destroyed as the result of a timeout or
-         // the undeployment of the containing webapp?
-         // If so, we'll just remove the expired session from the
-         // SSO.  If the session was logged out, we'll log out
-         // of all sessions associated with the SSO.
-         if (isSessionTimedOut(session) || isManagerStopped(session))
-         {
-            removeSession(ssoId, session);
-
-            // Quite poor.  We hijack the caller thread (the Tomcat background thread)
-            // to do our cleanup of expired sessions
-            processExpires();
-         }
-         else
-         {
-            // The session was logged out.
-            logout(ssoId);
-         }
+         removeSession(ssoId, session);
       }
-      catch (Exception e)
+      else
       {
-         // Don't propagate back to the webapp; we don't want to disrupt
-         // the session expiration process
-         getContainer().getLogger().error("Caught exception updating SSO " + ssoId +
-                                          " following destruction of session " +
-                                          session.getId(), e);
+         // The session was logged out.
+         logout(ssoId);
       }
-   }
 
-   private boolean isSessionTimedOut(Session session)
-   {
-      return (session.getMaxInactiveInterval() > 0)
-               && (System.currentTimeMillis() - session.getLastAccessedTime() >=
-                  session.getMaxInactiveInterval() * 1000);
    }
 
-   private boolean isManagerStopped(Session session)
-   {
-      boolean stopped = false;
-      
-      Manager manager = session.getManager();
-      
-      if (manager instanceof ManagerBase)
-      {
-         ObjectName mgrName = ((ManagerBase)manager).getObjectName();
-         stopped = (!activeManagers.contains(mgrName));
-      }
-      else if (manager instanceof JBossManager)
-      {
-         ObjectName mgrName = ((JBossManager)manager).getObjectName();
-         stopped = (!activeManagers.contains(mgrName));
-      }
-      else if (manager instanceof Lifecycle)
-      {
-         stopped = (!activeManagers.contains(manager));
-      }
-      // else we have no way to tell, so assume not
-      
-      return stopped;
-   }
 
-   // ----------------------------------------------  LifecycleListener Methods
-
-
-   public void lifecycleEvent(LifecycleEvent event)
-   {
-      String type = event.getType();
-      if (Lifecycle.BEFORE_STOP_EVENT.equals(type) 
-            || Lifecycle.STOP_EVENT.equals(type) 
-            || Lifecycle.AFTER_STOP_EVENT.equals(type))
-      {
-         Lifecycle source = event.getLifecycle();
-         boolean removed;
-         if (source instanceof ManagerBase)
-         {
-            removed = activeManagers.remove(((ManagerBase)source).getObjectName());
-         }
-         else if (source instanceof JBossManager)
-         {
-            removed = activeManagers.remove(((JBossManager)source).getObjectName());
-         }
-         else
-         {
-            removed = activeManagers.remove(source);
-         }
-         
-         if (removed)
-         {
-            source.removeLifecycleListener(this);
-            
-            if (getContainer().getLogger().isDebugEnabled())
-            {
-                getContainer().getLogger().debug("ClusteredSSO: removed " +
-                        "stopped manager " + source.toString());
-            }
-         }
-         
-         // TODO consider getting the sessions and removing any from our sso's
-         // Idea is to cleanup after managers that don't destroy sessions
-         
-      }      
-   }
-   
-
    // ---------------------------------------------------------- Valve Methods
 
 
@@ -596,11 +368,10 @@
       }
 
       // Look up the cached Principal associated with this cookie value
-      String ssoId = cookie.getValue();
       if (getContainer().getLogger().isDebugEnabled())
-          getContainer().getLogger().debug(" Checking for cached principal for " + ssoId);
+          getContainer().getLogger().debug(" Checking for cached principal for " + cookie.getValue());
       SingleSignOnEntry entry = getSingleSignOnEntry(cookie.getValue());
-      if (entry != null && isValid(ssoId, entry))
+      if (entry != null)
       {
          Principal ssoPrinc = entry.getPrincipal();
          // have to deal with the fact that the entry may not have an
@@ -662,48 +433,9 @@
          reverse.put(session, ssoId);
       }
 
-      // If we made a change, track the manager and notify any cluster
-      if (added)
-      {
-         Manager manager = session.getManager();
-         
-         // Prefer to cache an ObjectName to avoid risk of leaking a manager,
-         // so if the manager exposes one, use it
-         Object mgrKey = null;
-         if (manager instanceof ManagerBase)
-         {            
-            mgrKey = ((ManagerBase)manager).getObjectName();
-         }
-         else if (manager instanceof JBossManager)
-         {
-            mgrKey = ((JBossManager)manager).getObjectName();
-         }
-         else if (manager instanceof Lifecycle)
-         {
-            mgrKey = manager;
-         }
-         else {
-            getContainer().getLogger().warn("Manager for session " + 
-                      session.getId() +
-                      " does not implement Lifecycle; web app shutdown may " +
-                      " lead to incorrect SSO invalidations");
-         }
-         
-         if (mgrKey != null)
-         {
-            synchronized (activeManagers)
-            {
-               if (!activeManagers.contains(mgrKey))
-               {
-                  activeManagers.add(mgrKey);
-                  ((Lifecycle) manager).addLifecycleListener(this);
-               }
-            }
-         }
-         
-         if (ssoClusterManager != null)         
-            ssoClusterManager.addSession(ssoId, session);
-      }
+      // If we made a change, notify any cluster
+      if (added && ssoClusterManager != null)
+         ssoClusterManager.addSession(ssoId, session);
    }
 
 
@@ -758,11 +490,6 @@
       if (getContainer().getLogger().isDebugEnabled())
           getContainer().getLogger().debug("Deregistering sso id '" + ssoId + "'");
 
-      
-      // It's possible we don't have the SSO locally but it's in
-      // the emptySSOs map; if so remove it
-      emptySSOs.remove(ssoId);
-      
       // Look up and remove the corresponding SingleSignOnEntry
       SingleSignOnEntry sso = null;
       synchronized (cache)
@@ -777,8 +504,8 @@
       Session sessions[] = sso.findSessions();
       for (int i = 0; i < sessions.length; i++)
       {
-         if (getContainer().getLogger().isDebugEnabled())
-             getContainer().getLogger().debug(" Invalidating session " + sessions[i]);
+         if (getContainer().getLogger().isTraceEnabled())
+             getContainer().getLogger().trace(" Invalidating session " + sessions[i]);
          // Remove from reverse cache first to avoid recursion
          synchronized (reverse)
          {
@@ -950,12 +677,12 @@
          reverse.remove(session);
       }
 
-//      // If there are no sessions left in the SingleSignOnEntry,
-//      // deregister the entry.
-//      if (entry.getSessionCount() == 0)
-//      {
-//         deregister(ssoId);
-//      }
+      // If there are no sessions left in the SingleSignOnEntry,
+      // deregister the entry.
+      if (entry.getSessionCount() == 0)
+      {
+         deregister(ssoId);
+      }
    }
 
 
@@ -1119,35 +846,6 @@
       }
 
    }
-   
-   /**
-    * Callback from the SSOManager when it detects an SSO without
-    * any active sessions across the cluster
-    */
-   void notifySSOEmpty(String ssoId)
-   {
-      Object obj = emptySSOs.put(ssoId, new Long(System.currentTimeMillis()));
-      
-      if (obj == null && getContainer().getLogger().isDebugEnabled())
-      {
-         getContainer().getLogger().debug("Notified that SSO " + ssoId + " is empty");
-      }
-   }
-   
-   /**
-    * Callback from the SSOManager when it detects an SSO that
-    * has active sessions across the cluster
-    */
-   void notifySSONotEmpty(String ssoId)
-   {
-      Object obj = emptySSOs.remove(ssoId);
-      
-      if (obj != null && getContainer().getLogger().isDebugEnabled())
-      {
-         getContainer().getLogger().debug("Notified that SSO " + ssoId + 
-                                          " is no longer empty");
-      }
-   }
 
    
    // -------------------------------------------------------  Private Methods
@@ -1203,66 +901,5 @@
          }
       }
    }
-   
-   
-   private void processExpires()
-   {
-      long now = 0L;
-      synchronized (mutex)
-      {
-         now = System.currentTimeMillis();
-      
-         if (now - lastProcessExpires > processExpiresInterval)
-         {
-            lastProcessExpires = now;
-         }
-         else
-         {
-             return;
-         }
-      }
-      
-      clearExpiredSSOs(now);
-   }
-   
-   private synchronized void clearExpiredSSOs(long now)
-   {      
-      for (Iterator iter = emptySSOs.entrySet().iterator(); iter.hasNext();)
-      {
-         Map.Entry entry = (Map.Entry) iter.next();
-         if ( (now - ((Long) entry.getValue()).longValue()) > maxEmptyLife)
-         {
-            String ssoId = (String) entry.getKey();
-            if (getContainer().getLogger().isDebugEnabled())
-            {
-               getContainer().getLogger().debug("Invalidating expired SSO " + ssoId);
-            }
-            logout(ssoId);
-         }
-      }      
-   }
-   
-   private boolean isValid(String ssoId, SingleSignOnEntry entry)
-   {
-      boolean valid = true;
-      if (entry.getSessionCount() == 0)
-      {
-         Long expired = (Long) emptySSOs.get(ssoId);
-         if (expired != null 
-               && (System.currentTimeMillis() - expired.longValue()) > maxEmptyLife)
-         {
-            valid = false;
-            
-            if (getContainer().getLogger().isDebugEnabled())
-            {
-               getContainer().getLogger().debug("Invalidating expired SSO " + ssoId);
-            }
-            
-            logout(ssoId);
-         }
-      }
-      
-      return valid;
-   }
 
 }
\ No newline at end of file

Modified: branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/TreeCacheSSOClusterManager.java
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/TreeCacheSSOClusterManager.java	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/TreeCacheSSOClusterManager.java	2006-12-08 03:07:36 UTC (rev 58921)
@@ -1,29 +1,15 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
+ * JBoss, the OpenSource WebOS
  *
- * 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.
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
  */
 package org.jboss.web.tomcat.tc5.sso;
 
 import java.io.Serializable;
 import java.security.Principal;
 import java.util.HashSet;
+import java.util.LinkedList;
 import java.util.Set;
 
 import javax.management.MBeanServer;
@@ -105,19 +91,20 @@
    // -------------------------------------------------------  Instance Fields
    
    /**
-    * SSO id which the thread is currently storing to the cache
+    * List of SSO ids which this object is currently storing to the cache
     */
-   private ThreadLocal beingLocallyAdded = new ThreadLocal();
+   private LinkedList beingLocallyAdded = new LinkedList();
 
    /**
-    * SSO id which a thread is currently removing from the cache
+    * List of SSO ids which this object is currently removing from the cache
     */
-   private ThreadLocal beingLocallyRemoved = new ThreadLocal();
+   private LinkedList beingLocallyRemoved = new LinkedList();
 
    /**
-    * SSO id which the thread is deregistering due to removal on another node
+    * List of SSO ids which are being deregistered due to removal on another
+    * node
     */
-   private ThreadLocal beingRemotelyRemoved = new ThreadLocal();
+   private LinkedList beingRemotelyRemoved = new LinkedList();
 
    /**
     * ObjectName of the TreeCache
@@ -130,6 +117,12 @@
    private String cacheName = null;
 
    /**
+    * CredentialUpdater used to allow asynchronous updates of
+    * SSO credentials
+    */
+   private CredentialUpdater credentialUpdater = null;
+
+   /**
     * Transaction Manager
     */
    private TransactionManager tm = null;
@@ -174,11 +167,6 @@
     */
    private boolean missingCacheErrorLogged = false;
    
-   /**
-    * Our node's address in the cluster.
-    */
-   private Serializable localAddress = null;
-   
    // ----------------------------------------------------------  Constructors
 
    
@@ -189,21 +177,9 @@
    {
       // Find our MBeanServer
       server = MBeanServerLocator.locateJBoss();
-      if (server == null)
-         server = MBeanServerLocator.locate();
    }
-
    
-   /**
-    * Creates a new TreeCacheSSOClusterManager that works with the given
-    * MBeanServer.  This constructor is only intended for use in unit testing.
-    */
-   public TreeCacheSSOClusterManager(MBeanServer server)
-   {
-      this.server = server;
-   }
    
-   
    // ------------------------------------------------------------  Properties
   
    public String getCacheName()
@@ -240,7 +216,7 @@
          return;
       }
 
-      removeAsTreeCacheListener();
+      removeAsTreeCacheListener(cacheObjectName);
       this.tm = null;
       
       this.cacheObjectName = objectName;
@@ -262,11 +238,16 @@
                "before ClusteredSingleSignOn can handle requests");
          }
       }
+      else if (started)
+      {
+         // Confirm the cache has a transaction manager
+         // and fail if not found
+         findTransactionManager();
+      }
    }
    
    // -----------------------------------------------------  SSOClusterManager
 
-
    /**
     * Notify the cluster of the addition of a Session to an SSO session.
     *
@@ -280,8 +261,9 @@
          return;
       }
 
-      if (!checkTreeCacheAvailable())
+      if (false == isTreeCacheAvailable(false))
       {
+         logMissingCacheError();
          return;
       }
 
@@ -295,11 +277,6 @@
       boolean doTx = false;
       try
       {
-         // Confirm we have a transaction manager; if not get it from TreeCache
-         // failure to find will throw an IllegalStateException
-         if (tm == null)
-            configureFromCache();
-         
          // Don't do anything if there is already a transaction 
          // context associated with this thread.
          if(tm.getTransaction() == null)
@@ -309,7 +286,7 @@
             tm.begin();
          
          Set sessions = getSessionSet(fqn, true);
-         sessions.add(new SessionAddress(session.getId(), localAddress));
+         sessions.add(session.getId());
          putInTreeCache(fqn, sessions);
       }
       catch (Exception e)
@@ -319,7 +296,7 @@
             if(doTx)
                tm.setRollbackOnly();
          }
-         catch (Exception ignored)
+         catch (Exception x)
          {
          }
          String sessId = (session == null ? "NULL" : session.getId());
@@ -368,20 +345,23 @@
     */
    public void logout(String ssoId)
    {
-      if (!checkTreeCacheAvailable())
+      if (false == isTreeCacheAvailable(false))
       {
+         logMissingCacheError();
          return;
       }
       
       // Check whether we are already handling this removal 
-      if (ssoId.equals(beingLocallyRemoved.get()))
+      //synchronized (beingLocallyRemoved)
       {
-         return;
-      }         
-      
-      // Add this SSO to our list of in-process local removals so
-      // this.nodeRemoved() will ignore the removal
-      beingLocallyRemoved.set(ssoId);
+         if (beingLocallyRemoved.contains(ssoId))
+         {
+            return;
+         }         
+         // Add this SSO to our list of in-process local removals so
+         // this.nodeRemoved() will ignore the removal
+         beingLocallyRemoved.add(ssoId);
+      }
 
       if (log.isTraceEnabled())
       {
@@ -402,7 +382,10 @@
       }
       finally
       {
-         beingLocallyRemoved.set(null);
+         //synchronized (beingLocallyRemoved)
+         {
+            beingLocallyRemoved.remove(ssoId);
+         }
       }
    }
 
@@ -418,16 +401,20 @@
     */
    public SingleSignOnEntry lookup(String ssoId)
    {
-      if (!checkTreeCacheAvailable())
+      if (false == isTreeCacheAvailable(false))
       {
+         logMissingCacheError();
          return null;
       }
 
       SingleSignOnEntry entry = null;
       // Find the latest credential info from the cluster
       Fqn fqn = getCredentialsFqn(ssoId);
+      //UserTransaction tx = null;
       try
       {
+         //tx = getNewTransaction();
+         //tx.begin();
          SSOCredentials data = (SSOCredentials) getFromTreeCache(fqn);
          if (data != null)
          {
@@ -436,9 +423,20 @@
                data.getUsername(),
                data.getPassword());
          }
+         //tx.commit();
       }
       catch (Exception e)
       {
+         /*
+         if (tx != null)
+         {
+            try
+            {
+               tx.rollback();
+            }
+            catch (Exception x) {}
+         }
+         */
          log.error("caught exception looking up SSOCredentials for SSO id " +
             ssoId, e);
       }
@@ -458,8 +456,9 @@
    public void register(String ssoId, String authType,
       String username, String password)
    {
-      if (!checkTreeCacheAvailable())
+      if (false == isTreeCacheAvailable(false))
       {
+         logMissingCacheError();
          return;
       }
 
@@ -480,32 +479,33 @@
     */
    public void removeSession(String ssoId, Session session)
    {
-      if (ssoId == null || session == null)
+      if (false == isTreeCacheAvailable(false))
       {
+         logMissingCacheError();
          return;
       }
       
-      if (!checkTreeCacheAvailable())
-      {
-         return;
-      }
-      
       // Check that this session removal is not due to our own deregistration
       // of an SSO following receipt of a nodeRemoved() call
-      if (ssoId.equals(beingRemotelyRemoved.get()))
+      //synchronized(beingRemotelyRemoved)
       {
-         return;
+         if (beingRemotelyRemoved.contains(ssoId))
+         {
+            return;
+         }
       }
-      
+
+      if (log.isTraceEnabled())
+      {
+         log.trace("removeSession(): removing Session " + session.getId() +
+            " from cached session set for SSO " + ssoId);
+      }
+
       Fqn fqn = getSessionsFqn(ssoId);
       boolean doTx = false;
-//      boolean removing = false;
+      boolean removing = false;
       try
       {
-         // Confirm we have a transaction manager; if not get it from TreeCache
-         // failure to find will throw an IllegalStateException
-         if (tm == null)
-            configureFromCache();
 
          // Don't do anything if there is already a transaction 
          // context associated with this thread.
@@ -518,29 +518,23 @@
          Set sessions = getSessionSet(fqn, false);
          if (sessions != null)
          {
-            sessions.remove(new SessionAddress(session.getId(), localAddress));
-
-            if (log.isTraceEnabled())
+            sessions.remove(session.getId());
+            if (sessions.size() == 0)
             {
-               log.trace("removed session " + session.getId() +
-                  " from cached session set for SSO " + ssoId + " -- " +
-                  sessions.size() + " sessions remain");
+               // Add this SSO to our list of in-process local removals so
+               // this.nodeRemoved() will ignore the removal
+               //synchronized (beingLocallyRemoved)
+               {
+                  beingLocallyRemoved.add(ssoId);
+               }
+               removing = true;
+               // No sessions left; remove node
+               removeFromTreeCache(getSingleSignOnFqn(ssoId));
             }
-            
-//            if (sessions.size() == 0)
-//            {               
-//               // No sessions left; remove node
-//               
-//               // Add this SSO to our list of in-process local removals so
-//               // this.nodeRemoved() will ignore the removal
-//               removing = true;
-//               beingLocallyRemoved.set(ssoId);
-//               removeFromTreeCache(getSingleSignOnFqn(ssoId));
-//            }
-//            else
-//            {
+            else
+            {
                putInTreeCache(fqn, sessions);
-//            }
+            }
          }
       }
       catch (Exception e)
@@ -560,18 +554,21 @@
       }
       finally
       {
-//         try
-//         {
-//            if (removing)
-//            {
-//               beingLocallyRemoved.set(null);
-//            }
-//         }
-//         finally
-//         {
+         try
+         {
+            if (removing)
+            {
+               //synchronized (beingLocallyRemoved)
+               {
+                  beingLocallyRemoved.remove(ssoId);
+               }
+            }
+         }
+         finally
+         {
             if (doTx)
                endTransaction();
-//         }
+         }
       }
    }
 
@@ -589,8 +586,9 @@
    public void updateCredentials(String ssoId, String authType,
       String username, String password)
    {
-      if (!checkTreeCacheAvailable())
+      if (false == isTreeCacheAvailable(false))
       {
+         logMissingCacheError();
          return;
       }
 
@@ -662,17 +660,20 @@
    public void nodeRemoved(Fqn fqn)
    {
       String ssoId = getIdFromFqn(fqn);
-      
-      if (ssoId == null)
-         return;
 
       // Ignore messages generated by our own activity
-      if (ssoId.equals(beingLocallyRemoved.get()))
+      //synchronized(beingLocallyRemoved)
       {
-         return;
+         if (beingLocallyRemoved.contains(ssoId))
+         {
+            return;
+         }
       }
       
-      beingRemotelyRemoved.set(ssoId);
+      //synchronized (beingRemotelyRemoved)
+      {
+         beingRemotelyRemoved.add(ssoId);
+      }
 
       try
       {
@@ -685,7 +686,10 @@
       }
       finally
       {
-         beingRemotelyRemoved.set(null);
+         //synchronized(beingRemotelyRemoved)
+         {
+            beingRemotelyRemoved.remove(ssoId);
+         }
       }
 
    }
@@ -708,30 +712,21 @@
     */
    public void nodeModified(Fqn fqn)
    {
-      String type = getTypeFromFqn(fqn);
-      if (CREDENTIALS.equals(type))
+      // We are only interested in changes to the CREDENTIALS node
+      if (CREDENTIALS.equals(getTypeFromFqn(fqn)) == false)
       {
-         handleCredentialUpdate(fqn);
+         return;
       }
-      else if (SESSIONS.equals(type))
-      {
-         handleSessionSetChange(fqn);
-      }
-   }
 
+      String ssoId = getIdFromFqn(fqn);
 
-   /**
-    *  
-    * @param fqn an Fqn that points to the CREDENTIALS node of an SSO
-    */
-   private void handleCredentialUpdate(Fqn fqn)
-   {
-      String ssoId = getIdFromFqn(fqn); // won't be null per the API contract
-
       // Ignore invocations that come as a result of our additions
-      if (ssoId.equals(beingLocallyAdded.get()))
+      //synchronized(beingLocallyAdded)
       {
-         return;
+         if (beingLocallyAdded.contains(ssoId))
+         {
+            return;
+         }
       }
 
       SingleSignOnEntry sso = ssoValve.localLookup(ssoId);
@@ -747,72 +742,11 @@
       }
 
       // Put this SSO in the queue of those to be updated
-//      credentialUpdater.enqueue(sso, ssoId);
-      try
-      {
-         SSOCredentials data = (SSOCredentials) getFromTreeCache(fqn);
-         if (data != null)
-         {
-            // We want to release our read lock quickly, so get the needed
-            // data from the cache, commit the tx, and then use the data
-            String authType = data.getAuthType();
-            String username = data.getUsername();
-            String password = data.getPassword();
+      credentialUpdater.enqueue(sso, ssoId);
+   }
 
-            if (log.isTraceEnabled())
-            {
-               log.trace("CredentialUpdater: Updating credentials for SSO " + sso);
-            }
 
-            synchronized (sso)
-            {
-               // Use the existing principal
-               Principal p = sso.getPrincipal();
-               sso.updateCredentials(p, authType, username, password);
-            }
-         }
-      }
-      catch (Exception e)
-      {
-         log.error("failed to update credentials for SSO " + ssoId, e);
-      }
-   }
-   
    /**
-    *  
-    * @param fqn an Fqn that points to the SESSIONS node of an SSO
-    */
-   private void handleSessionSetChange(Fqn fqn)
-   {
-      // Here we *want* to handle local activity as well as remote,
-      // as the distributed cache set of sessions is the only
-      // complete representation
-      
-      String ssoId = getIdFromFqn(fqn);
-      try      
-      {
-         Set sessions = (Set) getFromTreeCache(fqn);
-         if (sessions == null)
-         {
-            // don't think we'd get this event; 
-            // in any case we don't deal with this
-         }
-         else if (sessions.size() == 0)
-         {
-            ssoValve.notifySSOEmpty(ssoId);            
-         }
-         else
-         {
-            ssoValve.notifySSONotEmpty(ssoId);
-         }
-      }
-      catch (Exception e)
-      {
-         log.error("failed in check for empty SSO " + ssoId, e);
-      }
-   }
-
-   /**
     * Does nothing
     */
    public void viewChange(View new_view)
@@ -884,12 +818,15 @@
          throw new LifecycleException
             ("TreeCacheSSOClusterManager already Started");
       }
+      
+      // Start the thread we use to clear nodeModified events
+      credentialUpdater = new CredentialUpdater();
 
       try 
       {
-         if (isTreeCacheAvailable(true))
+         if (tm == null && isTreeCacheAvailable(true))
          {
-            integrateWithCache();
+            findTransactionManager();
          }
       }
       catch (Exception e)
@@ -922,7 +859,9 @@
          throw new LifecycleException
             ("TreeCacheSSOClusterManager not Started");
       }
-      
+
+      credentialUpdater.stop();
+
       started = false;
 
       // Notify our interested LifecycleListeners
@@ -964,12 +903,7 @@
     */
    private String getIdFromFqn(Fqn fqn)
    {
-      String id = null;
-      if (fqn.size() > 1 && SSO.equals(fqn.get(0)))
-      {
-         id = (String) fqn.get(1);
-      }
-      return id;
+      return (String) fqn.get(1);
    }
 
    private Set getSessionSet(Fqn fqn, boolean create)
@@ -988,30 +922,25 @@
     * object.
     *
     * @param fqn the Fully Qualified Name used by TreeCache
-    * @return the 3rd in the Fqn -- either
-    *         {@link #CREDENTIALS CREDENTIALS} or {@link #SESSIONS SESSIONS},
-    *         or <code>null</code> if <code>fqn</code> is not for an SSO.
+    * @return the last element in the Fqn -- either
+    *         {@link #CREDENTIALS CREDENTIALS} or {@link #SESSIONS SESSIONS}.
     */
    private String getTypeFromFqn(Fqn fqn)
    {
-      String type = null;
-      if (fqn.size() > 2 && SSO.equals(fqn.get(0)))
-         type = (String) fqn.get(2);
-      return type;
+      return (String) fqn.get(fqn.size() - 1);
    }
    
    /**
-    * Obtains needed configuration information from the tree cache.
     * Invokes "getTransactionManager" on the tree cache, caching the
     * result or throwing an IllegalStateException if one is not found.
-    * Also get our cluster-wide unique local address from the cache.
     * 
     * @throws Exception
     */
-   private void configureFromCache() throws Exception
-   {  
-      tm = (TransactionManager) server.getAttribute(getCacheObjectName(), 
-                                                    "TransactionManager");
+   private void findTransactionManager() throws Exception
+   {
+      tm = (TransactionManager) server.invoke(getCacheObjectName(), 
+                                              "getTransactionManager", 
+                                              null, new String[] {});                  
 
       if (tm == null) 
       {
@@ -1020,15 +949,6 @@
                                          "configure a valid " +
                                          "TransactionManagerLookupClass");
       }
-      
-      // Find out our address
-      Object address = server.getAttribute(cacheObjectName, "LocalAddress");
-      // In reality this is a JGroups IpAddress, but the API says
-      // "Object" so we have to be sure its Serializable
-      if (address instanceof Serializable)
-         localAddress = (Serializable) address;
-      else
-         localAddress = address.toString();
    }
    
 
@@ -1074,19 +994,13 @@
             {
                try
                {
-                  // If Tomcat5 overrides the default cache name, it will do so
-                  // after we are started. So we need to configure ourself here
-                  // and throw an exception if there is a problem. Having this
-                  // here also allows us to recover if our cache is started
-                  // after we are
-                  if (started)
-                     integrateWithCache();
+                  registerAsTreeCacheListener(cacheObjectName);
                   setMissingCacheErrorLogged(false);
                }
                catch (Exception e)
                {
-                  log.error("Caught exception configuring from cache " +
-                            cacheObjectName, e);
+                  log.error("Caught exception registering as listener to " +
+                     cacheObjectName, e);
                   available = false;
                }
             }
@@ -1095,14 +1009,6 @@
       }
       return treeCacheAvailable;
    }
-   
-   private boolean checkTreeCacheAvailable()
-   {
-      boolean avail = isTreeCacheAvailable(false);
-      if (!avail)
-         logMissingCacheError();
-      return avail;
-   }
 
    private void putInTreeCache(Fqn fqn, Object data) throws Exception
    {
@@ -1110,26 +1016,16 @@
       server.invoke(getCacheObjectName(), "put", args, PUT_SIGNATURE);
    }
 
-   private void integrateWithCache() throws Exception
-   {
-      // Ensure we have a transaction manager and a cluster-wide unique address
-      configureFromCache();
-      
-      registerAsTreeCacheListener();
-      
-      log.debug("Successfully integrated with cache service " + cacheObjectName);
-   }
-
-
    /**
     * Invokes an operation on the JMX server to register ourself as a
     * listener on the TreeCache service.
     *
     * @throws Exception
     */
-   private void registerAsTreeCacheListener() throws Exception
+   private void registerAsTreeCacheListener(ObjectName listenTo)
+      throws Exception
    {
-      server.invoke(cacheObjectName, "addTreeCacheListener",
+      server.invoke(listenTo, "addTreeCacheListener",
          new Object[]{this},
          new String[]{TreeCacheListener.class.getName()});
       registeredAsListener = true;
@@ -1142,11 +1038,12 @@
     *
     * @throws Exception
     */
-   private void removeAsTreeCacheListener() throws Exception
+   private void removeAsTreeCacheListener(ObjectName removeFrom)
+      throws Exception
    {
-      if (registeredAsListener && cacheObjectName != null)
+      if (registeredAsListener && removeFrom != null)
       {
-         server.invoke(cacheObjectName, "removeTreeCacheListener",
+         server.invoke(removeFrom, "removeTreeCacheListener",
             new Object[]{this},
             new String[]{TreeCacheListener.class.getName()});
       }
@@ -1179,23 +1076,41 @@
       String password)
    {
       SSOCredentials data = new SSOCredentials(authType, username, password);
-      
       // Add this SSO to our list of in-process local adds so
       // this.nodeModified() will ignore the addition
-      beingLocallyAdded.set(ssoId);
-      
+      //synchronized (beingLocallyAdded)
+      {
+         beingLocallyAdded.add(ssoId);
+      }
+      //UserTransaction tx = null;
       try
       {
+         //tx = getNewTransaction();
+         //tx.begin();
          putInTreeCache(getCredentialsFqn(ssoId), data);
+         //tx.commit();
       }
       catch (Exception e)
       {
+         /*
+         if (tx != null)
+         {
+            try
+            {
+               tx.rollback();
+            }
+            catch (Exception x) {}
+         }
+         */
          log.error("Exception attempting to add TreeCache nodes for SSO " +
             ssoId, e);
       }
       finally
       {
-         beingLocallyAdded.set(null);
+         //synchronized (beingLocallyAdded)
+         {
+            beingLocallyAdded.remove(ssoId);
+         }
       }
    }
 
@@ -1229,6 +1144,219 @@
       }
    }
 
+   // ---------------------------------------------------------  Inner Classes
+
+   /**
+    * Spawns a thread to handle updates of credentials
+    * 
+    * TODO  This was added in the early days of JBossCache when invoking
+    *       a get() on a node in the middle of a TreeCacheListener 
+    *       notification would cause a deadlock.  Should not be necessary now.
+    */
+   private class CredentialUpdater
+      implements Runnable
+   {
+      private HashSet awaitingUpdate = new HashSet();
+      private Thread updateThread;
+      private boolean updateThreadSleeping = false;
+      private boolean queueEmpty = true;
+      private boolean stopped = false;
+
+      private CredentialUpdater()
+      {
+         updateThread =
+            new Thread(this, "SSOClusterManager.CredentialUpdater");
+         updateThread.setDaemon(true);
+         updateThread.start();
+      }
+
+      // ------------------------------------------------------  Runnable
+
+      public void run()
+      {
+         while (!stopped)
+         {
+            // Ensure that no runtime exceptions kill this thread
+            try
+            {
+               updateThreadSleeping = false;
+               // Get the current list of ids awaiting processing
+               SSOWrapper[] ssos = null;
+               synchronized (awaitingUpdate)
+               {
+                  ssos = new SSOWrapper[awaitingUpdate.size()];
+                  ssos = (SSOWrapper[]) awaitingUpdate.toArray(ssos);
+                  awaitingUpdate.clear();
+                  queueEmpty = true;
+               }
+
+               // Handle the credential update
+               for (int i = 0; i < ssos.length; i++)
+               {
+                  processUpdate(ssos[i]);
+               }
+
+               // Wait for another invocation of enqueue().  But,
+               // first have to check in case it was invoked while we
+               // were processing the previous bunch
+               if (queueEmpty)
+               {
+                  try
+                  {
+                     // There is a slight possibility here of a race condition
+                     // between the above check for queueEmpty and another 
+                     // thread accessing enqueue()'s check of 
+                     // updateThreadSleeping.  If this happens, the update
+                     // will not be processed by the local node until the
+                     // updateThread wakes up (30 secs) or is interrupted by 
+                     // another update.  This situation is quite unlikely,
+                     // as updates only happen 1) in odd configurations where
+                     // CLIENT-CERT authentication is used for some apps and 
+                     // FORM or BASIC are used for others and 2) the user has
+                     // first logged in to a CLIENT-CERT app and later logs in
+                     // to a FORM/BASIC app.  If such a race condition were to 
+                     // occur, the only downside would be that if the user 
+                     // accessed a FORM/BASIC app on this node before the local
+                     // update is processed, they would have to log in again.
+                     updateThreadSleeping = true;
+                     updateThread.sleep(30000);
+                  }
+                  catch (InterruptedException e)
+                  {
+                     if (log.isTraceEnabled())
+                     {
+                        log.trace("CredentialUpdater: interrupted");
+                     }
+                     // process the next bunch
+                  }
+               }
+               else if (log.isTraceEnabled())
+               {
+                  log.trace("CredentialUpdater: more updates added while " +
+                     "handling existing updates");
+               }
+            }
+            catch (Exception e)
+            {
+               log.error("CredentialUpdater thread caught an exception", e);
+            }
+         }
+      }
+
+      // -------------------------------------------------  Private Methods
+
+      /**
+       * Adds an SSO id to the set of those awaiting credential updating, and
+       * interrupts the update handler thread to notify it of the addition.
+       *
+       * @param sso the id of the SSO session whose local credentials
+       *            are to be updated
+       */
+      private void enqueue(SingleSignOnEntry sso, String ssoId)
+      {
+         synchronized (awaitingUpdate)
+         {
+            awaitingUpdate.add(new SSOWrapper(sso, ssoId));
+            queueEmpty = false;
+         }
+         // Interrupt the update thread so it wakes up to process
+         // the enqueued update.  Only do this if its "sleeping" flag
+         // is set so we don't inadvertently interrupt it while its
+         // blocked waiting for a TreeCache lock to clear
+         if (updateThreadSleeping)
+         {
+            updateThread.interrupt();
+         }
+      }
+
+      private void processUpdate(SSOWrapper wrapper)
+      {
+         if (wrapper.sso.getCanReauthenticate())
+         {
+            // No need to update
+            return;
+         }
+
+         Fqn fqn = getCredentialsFqn(wrapper.id);
+         //UserTransaction tx = null;
+         try
+         {
+            //tx = getNewTransaction();
+            //tx.begin();
+            SSOCredentials data = (SSOCredentials) getFromTreeCache(fqn);
+            if (data != null)
+            {
+               // We want to release our read lock quickly, so get the needed
+               // data from the cache, commit the tx, and then use the data
+               String authType = data.getAuthType();
+               String username = data.getUsername();
+               String password = data.getPassword();
+               //tx.commit();
+
+               if (log.isTraceEnabled())
+               {
+                  log.trace("CredentialUpdater: Updating credentials for SSO " +
+                     wrapper.sso);
+               }
+
+               synchronized (wrapper.sso)
+               {
+                  // Use the existing principal
+                  Principal p = wrapper.sso.getPrincipal();
+                  wrapper.sso.updateCredentials(p, authType, username, password);
+               }
+            }
+            /*
+            else
+            {
+               tx.commit();
+            }
+            */
+
+         }
+         catch (Exception e)
+         {
+            /*
+            if (tx != null)
+            {
+               try
+               {
+                  tx.rollback();
+               }
+               catch (Exception x) {}
+            }
+            */
+            log.error("Exception attempting to get SSOCredentials from " +
+               "TreeCache node " + fqn.toString(), e);
+         }
+      }
+
+      /**
+       * Stops the update handler thread.
+       */
+      private void stop()
+      {
+         stopped = true;
+      }
+
+   }  // end CredentialUpdater
+
+
+   /**
+    * Wrapper class that holds a SingleSignOnEntry and its id
+    */
+   private class SSOWrapper
+   {
+      private SingleSignOnEntry sso = null;
+      private String id = null;
+
+      private SSOWrapper(SingleSignOnEntry entry, String ssoId)
+      {
+         this.sso = entry;
+         this.id = ssoId;
+      }
+   }
+
    // ---------------------------------------------------------  Outer Classes
 
    /**
@@ -1293,135 +1421,6 @@
       }
 
    } // end SSOCredentials
-   
-   static class SessionAddress implements Serializable
-   {
-      /** The serialVersionUID */
-      private static final long serialVersionUID = -3702932999380140004L;
-      
-      Serializable address;
-      String sessionId;
-      
-      SessionAddress(String sessionId, Serializable address)
-      {
-         this.sessionId = sessionId;
-         this.address   = address;
-      }
 
-      public boolean equals(Object obj)
-      {
-         if (this == obj)
-            return true;
-         
-         if (!(obj instanceof SessionAddress))
-            return false;
-         
-         SessionAddress other = (SessionAddress) obj;
-         
-         return (sessionId.equals(other.sessionId) 
-                 && address.equals(other.address));
-      }
-
-      public int hashCode()
-      {
-         int total = (19 * 43) + sessionId.hashCode();
-         return ((total * 43) + address.hashCode());
-      }
-      
-      
-   }
-
-// DISABLED UNTIL 4.0.6.CR1
-//   /**
-//    * Runnable that's run when the removal of a node from the cluster has been detected. 
-//    * Removes any SessionAddress objects associated with dead members from the
-//    * session set of each SSO.  Operates locally only so each node can independently clean
-//    * its SSOs without concern about replication lock conflicts.
-//    */
-//   private class DeadMemberCleaner implements Runnable
-//   {    
-//      public void run()
-//      {
-//         synchronized (cleanupMutex)
-//         {
-//            try
-//            {      
-//               // Ensure we have a TransactionManager
-//               if (tm == null)
-//                  configureFromCache();
-//               
-//               Set ids = getSSOIds();
-//               
-//               for (Iterator iter = ids.iterator(); iter.hasNext();)
-//               {
-//                  cleanDeadMembersFromSSO((String) iter.next());
-//                  
-//               }
-//            }
-//            catch (Exception e)
-//            {
-//               log.error("Caught exception cleaning sessions from dead cluster members from SSOs ", e);
-//            }
-//         }
-//      }
-//      
-//      private void cleanDeadMembersFromSSO(String ssoId)
-//      {
-//         Fqn fqn = getSessionsFqn(ssoId);
-//         boolean doTx = false;
-//         try
-//         {
-//            // Don't start tx if there is already one associated with this thread.
-//            if(tm.getTransaction() == null)
-//               doTx = true;
-//
-//            if(doTx)
-//               tm.begin();
-//            
-//            Set sessions = getSessionSet(fqn, false, true);
-//            if (sessions != null && sessions.size() > 0)
-//            {
-//               boolean changed = false;
-//               for (Iterator iter = sessions.iterator(); iter.hasNext();)
-//               {
-//                  SessionAddress session = (SessionAddress) iter.next();
-//                  if (!currentView.containsMember((Address) session.address))
-//                  {
-//                     iter.remove();
-//                     changed = true;
-//                  }
-//               }
-//               
-//               if (changed)
-//               {                  
-//                  if (sessions.size() == 0)
-//                  {
-//                     ssoValve.notifySSOEmpty(ssoId);
-//                  }
-//                  
-//                  putInTreeCache(fqn, sessions, true);
-//               }
-//            }
-//         }
-//         catch (Exception e)
-//         {
-//            try
-//            {
-//               if(doTx)
-//                  tm.setRollbackOnly();
-//            }
-//            catch (Exception ignored)
-//            {
-//            }
-//            log.error("caught exception cleaning dead members from SSO " + ssoId, e);
-//         }
-//         finally
-//         {
-//            if (doTx)
-//               endTransaction();
-//         }         
-//      }
-//   }
-
 } // end TreeCacheSSOClusterManager
 

Modified: branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/mbeans-descriptors.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/mbeans-descriptors.xml	2006-12-08 01:43:14 UTC (rev 58920)
+++ branches/JBoss_4_0_3_SP1_CP/tomcat/src/main/org/jboss/web/tomcat/tc5/sso/mbeans-descriptors.xml	2006-12-08 03:07:36 UTC (rev 58921)
@@ -20,19 +20,6 @@
          description="Should we attempt to reauthenticate each request against the security Realm?"
          type="boolean"/>
 
-      <attribute name="maxEmptyLife"
-         description="The maximum number of seconds an SSO with no active sessions will be usable by a request"
-         type="int"/>
-
-      <attribute name="processExpiresInterval"
-         description="The maximum number of seconds an SSO with no active sessions will be usable by a request"
-         type="int"/>
-
-      <attribute name="lastProcessExpires"
-         writeable="false"
-         description="The timestamp of the start of the last check for overaged SSO's with no active sessions."
-         type="long"/>
-
       <attribute name="clusterManager"
          description="SSOClusterManager to use for cluster support"
          type="org.jboss.web.tomcat.tc5.sso.SSOClusterManager"/>



From vladimir.blagojevic at jboss.com  Thu Dec  7 22:39:00 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 07 Dec 2006 22:39:00 -0500
Subject: [jboss-cvs] JBossCache/lib  ...
Message-ID: <E1GsWZg-0001PB-9H@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/07 22:39:00

  Modified:    lib      Tag: Branch_JBossCache_1_4_0 jgroups.jar
  Log:
  prerelease 2.4.1 (in JChannelFactory invoke start|stopFlush only if we have FLUSH in stack)
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.3   +1546 -1538JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From brian.stansberry at jboss.com  Thu Dec  7 22:49:28 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 07 Dec 2006 22:49:28 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GsWjo-0001Yg-8N@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/07 22:49:28

  Modified:    src/org/jboss/cache  TransactionEntry.java
  Log:
  [JBCACHE-874] Store locks in a LinkedHashSet
  
  Revision  Changes    Path
  1.16      +22 -24    JBossCache/src/org/jboss/cache/TransactionEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionEntry.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- TransactionEntry.java	7 Dec 2006 20:03:23 -0000	1.15
  +++ TransactionEntry.java	8 Dec 2006 03:49:28 -0000	1.16
  @@ -32,7 +32,7 @@
    * </ul>
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.15 $
  + * @version $Revision: 1.16 $
    */
   public class TransactionEntry {
   
  @@ -59,9 +59,12 @@
      private List undo_list=new LinkedList();
   
      /**
  -    * List<IdentityLock> of locks acquired by the transaction ({@link IdentityLock})
  +    * LinkedHashSet<IdentityLock> of locks acquired by the transaction. We use
  +    * a LinkedHashSet because we need efficient Set semantics (same lock can
  +    * be added multiple times) but also need guaranteed ordering for use
  +    * by lock release code (see JBCCACHE-874).
       */
  -   private List locks = new LinkedList();
  +   private LinkedHashSet locks = new LinkedHashSet();
   
      /**
       * A list of dummy uninitialised nodes created by the cache loader interceptor to load data for a
  @@ -132,18 +135,15 @@
      }
   
      /**
  -    * Adds a lock to the end of the lock list.
  +    * Adds a lock to the end of the lock list, if it isn't already present.
       */
      public void addLock(NodeLock l) {
         if(l != null) {
            synchronized(locks) {
  -             if (!locks.contains(l))
  -             {
                    locks.add(l);
                }
            }
         }
  -   }
   
      /**
       * Add multiple locks to the lock list.
  @@ -151,25 +151,22 @@
       */
      public void addLocks(Collection newLocks) {
         if(newLocks != null) {
  -         IdentityLock tmp;
            synchronized(locks) {
  -            for(Iterator it=newLocks.iterator(); it.hasNext();) {
  -               tmp=(IdentityLock)it.next();
  -                if (!locks.contains(tmp))
  -                {
  -                    locks.add(tmp);
  -                }
  -            }
  +            locks.addAll(newLocks);
            }
         }
      }
   
      /**
       * Returns the locks in use.
  -    * Note:  This list may be concurrently modified.
  +    * 
  +    * @return a defensive copy of the internal data structure.
       */
      public List getLocks() {
  -      return locks;
  +      synchronized(locks)
  +      {
  +         return new ArrayList(locks);
  +      }
      }
   
      /**
  @@ -188,16 +185,17 @@
       * Clears the list of locks held.
       */
      public void releaseAllLocksLIFO(Object owner) {
  -      // I guess a copy would work as well
  -      // This seems fairly safe though
  +
         synchronized (locks) {
  -         for (ListIterator i = locks.listIterator(locks.size()); i.hasPrevious();) {
  -            IdentityLock lock = (IdentityLock)i.previous();
  +         // Copying out to an array is faster than creating an ArrayList and iterating,
  +         // since list creation will just copy out to an array internally
  +         IdentityLock[] lockArray = (IdentityLock[]) locks.toArray(new IdentityLock[locks.size()]);
  +         for (int i = lockArray.length -1; i >= 0; i--) {
                if (log.isTraceEnabled())
                {
  -                 log.trace("releasing lock for " + lock.getFqn() + " (" + lock + ")");
  +                 log.trace("releasing lock for " + lockArray[i].getFqn() + " (" + lockArray[i] + ")");
                }
  -             lock.release(owner);
  +             lockArray[i].release(owner);
            }
            locks.clear();
         }
  
  
  


From scott.stark at jboss.com  Thu Dec  7 23:34:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:34:39 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/aop - New directory ...
Message-ID: <E1GsXRX-0002MY-HI@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:34:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/aop added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:34:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:34:49 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/aop/2.0.0.alpha2 - New
	directory ...
Message-ID: <E1GsXRh-0002Mh-RN@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:34:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/aop/2.0.0.alpha2 added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:35:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:35:53 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/aop/2.0.0.alpha2   ...
Message-ID: <E1GsXSj-0002QP-0P@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:35:53

  Added:       maven2/jboss/aop/2.0.0.alpha2   jboss-aop-2.0.0.alpha2.jar
                        jboss-aop-2.0.0.alpha2.pom
  Log:
  Add aop 2.0.0.alpha2 to maven
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 04:35:52;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:35:52;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.pom
  
  Index: jboss-aop-2.0.0.alpha2.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>aop</artifactId>
    <name>JBoss AOP</name>
    <version>2.0.0.alpha2</version>
    <description>JBoss AOP</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  
  


From scott.stark at jboss.com  Thu Dec  7 23:47:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:02 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-aop-mc-int - New
	directory ...
Message-ID: <E1GsXdW-0002Zn-CJ@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:02

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-aop-mc-int added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:47:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:02 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-container - New
	directory ...
Message-ID: <E1GsXdW-0002Zr-FA@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:02

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-container added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:47:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:02 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-dependency - New
	directory ...
Message-ID: <E1GsXdW-0002Zv-JR@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:02

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-dependency added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:47:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:02 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-deployers - New
	directory ...
Message-ID: <E1GsXdW-0002Zz-Mw@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:02

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-deployers added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:47:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:02 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-kernel - New
	directory ...
Message-ID: <E1GsXdW-0002a3-Qi@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:02

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-kernel added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:47:19 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:19 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta -
	New directory ...
Message-ID: <E1GsXdn-0002aF-H7@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:19

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:47:52 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:47:52 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-container/2.0.0.Beta -
	New directory ...
Message-ID: <E1GsXeK-0002aT-64@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:47:52

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-container/2.0.0.Beta added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:48:10 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:48:10 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-dependency/2.0.0.Beta -
	New directory ...
Message-ID: <E1GsXec-0002ah-Oq@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:48:10

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-dependency/2.0.0.Beta added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:48:32 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:48:32 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-deployers/2.0.0.Beta -
	New directory ...
Message-ID: <E1GsXey-0002av-3q@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:48:32

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-deployers/2.0.0.Beta added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:48:48 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:48:48 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-kernel/2.0.0.Beta
	- New directory ...
Message-ID: <E1GsXfE-0002b9-1K@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:48:48

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-kernel/2.0.0.Beta added to the repository


From scott.stark at jboss.com  Thu Dec  7 23:51:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:51:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta ...
Message-ID: <E1GsXhz-0002fk-AK@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:51:39

  Added:       maven2/jboss/jboss-aop-mc-int/2.0.0.Beta    
                        jboss-aop-mc-int-2.0.0.Beta-sources.jar
                        jboss-aop-mc-int-2.0.0.Beta.jar
                        jboss-aop-mc-int-2.0.0.Beta.pom
                        jboss-aop-mc-int-2.0.0.Beta.pom~
  Log:
  Add the 2.0.0.Beta mc jars to the maven repository
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom
  
  Index: jboss-aop-mc-int-2.0.0.Beta.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-aop-mc-int</artifactId>
    <name>JBoss AOP/Microcontainer Integration</name>
    <version>2.0.0.Beta</version>
    <description>JBoss AOP/Microcontainer Integration</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>aop</artifactId>
        <version>2.0.0.alpha2</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jbossxb</artifactId>
        <version>1.0.0.CR8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-container</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-dependency</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-microcontainer</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom~
  
  Index: jboss-aop-mc-int-2.0.0.Beta.pom~
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-aop-mc-int</artifactId>
    <name>JBoss AOP/Microcontainer Integration</name>
    <version>2.0.0.Beta</version>
    <description>JBoss AOP/Microcontainer Integration</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jbossxb</artifactId>
        <version>1.0.0.CR8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-container</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-dependency</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-microcontainer</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From scott.stark at jboss.com  Thu Dec  7 23:51:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:51:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-container/2.0.0.Beta ...
Message-ID: <E1GsXhz-0002fv-Ee@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:51:39

  Added:       maven2/jboss/jboss-container/2.0.0.Beta   
                        jboss-container-2.0.0.Beta-sources.jar
                        jboss-container-2.0.0.Beta.jar
                        jboss-container-2.0.0.Beta.pom
  Log:
  Add the 2.0.0.Beta mc jars to the maven repository
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-container/2.0.0.Beta/jboss-container-2.0.0.Beta-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-container/2.0.0.Beta/jboss-container-2.0.0.Beta.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-container/2.0.0.Beta/jboss-container-2.0.0.Beta.pom
  
  Index: jboss-container-2.0.0.Beta.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-container</artifactId>
    <name>JBoss Container</name>
    <version>2.0.0.Beta</version>
    <description>JBoss microcontainer utility classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>javassist</groupId>
        <artifactId>javassist</artifactId>
        <version>3.4.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>concurrent</groupId>
        <artifactId>concurrent</artifactId>
        <version>1.3.4</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From scott.stark at jboss.com  Thu Dec  7 23:51:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:51:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-dependency/2.0.0.Beta ...
Message-ID: <E1GsXhz-0002g6-Jj@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:51:39

  Added:       maven2/jboss/jboss-dependency/2.0.0.Beta   
                        jboss-dependency-2.0.0.Beta-sources.jar
                        jboss-dependency-2.0.0.Beta.jar
                        jboss-dependency-2.0.0.Beta.pom
  Log:
  Add the 2.0.0.Beta mc jars to the maven repository
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-dependency/2.0.0.Beta/jboss-dependency-2.0.0.Beta-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-dependency/2.0.0.Beta/jboss-dependency-2.0.0.Beta.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-dependency/2.0.0.Beta/jboss-dependency-2.0.0.Beta.pom
  
  Index: jboss-dependency-2.0.0.Beta.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-dependency</artifactId>
    <name>JBoss Dependency</name>
    <version>2.0.0.Beta</version>
    <description>JBoss microcontainer dependency classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>concurrent</groupId>
        <artifactId>concurrent</artifactId>
        <version>1.3.4</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From scott.stark at jboss.com  Thu Dec  7 23:51:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:51:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-deployers/2.0.0.Beta ...
Message-ID: <E1GsXhz-0002gG-Oe@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:51:39

  Added:       maven2/jboss/jboss-deployers/2.0.0.Beta  
                        jboss-deployers-2.0.0.Beta.pom
                        jboss-deployers-2.0.0.Beta.pom~
  Log:
  Add the 2.0.0.Beta mc jars to the maven repository
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-deployers/2.0.0.Beta/jboss-deployers-2.0.0.Beta.pom
  
  Index: jboss-deployers-2.0.0.Beta.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-deployers</artifactId>
    <name>JBoss Deployers</name>
    <version>2.0.0.Beta</version>
    <description>JBoss virtual deployer framework</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jbossxb</artifactId>
        <version>1.0.0.CR8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-dependency</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-kernel</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>concurrent</groupId>
        <artifactId>concurrent</artifactId>
        <version>1.3.4</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-deployers/2.0.0.Beta/jboss-deployers-2.0.0.Beta.pom~
  
  Index: jboss-deployers-2.0.0.Beta.pom~
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-dependency</artifactId>
    <name>JBoss Dependency</name>
    <version>2.0.0.Beta</version>
    <description>JBoss microcontainer dependency classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>concurrent</groupId>
        <artifactId>concurrent</artifactId>
        <version>1.3.4</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From scott.stark at jboss.com  Thu Dec  7 23:51:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Thu, 07 Dec 2006 23:51:39 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-kernel/2.0.0.Beta
	...
Message-ID: <E1GsXhz-0002gR-VC@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/07 23:51:39

  Added:       maven2/jboss/jboss-kernel/2.0.0.Beta   
                        jboss-kernel-2.0.0.Beta-sources.jar
                        jboss-kernel-2.0.0.Beta.jar
                        jboss-kernel-2.0.0.Beta.pom
  Log:
  Add the 2.0.0.Beta mc jars to the maven repository
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-kernel/2.0.0.Beta/jboss-kernel-2.0.0.Beta-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-kernel/2.0.0.Beta/jboss-kernel-2.0.0.Beta.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 04:51:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-kernel/2.0.0.Beta/jboss-kernel-2.0.0.Beta.pom
  
  Index: jboss-kernel-2.0.0.Beta.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-kernel</artifactId>
    <name>JBoss Kernel</name>
    <version>2.0.0.Beta</version>
    <description>JBoss Microcontainer Kernel</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.2.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.2.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jbossxb</artifactId>
        <version>1.0.0.CR8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-container</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-dependency</artifactId>
        <version>2.0.0.Beta</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>concurrent</groupId>
        <artifactId>concurrent</artifactId>
        <version>1.3.4</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From norman.richards at jboss.com  Fri Dec  8 00:14:20 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 08 Dec 2006 00:14:20 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools/resources/WEB-INF  ...
Message-ID: <E1GsY3w-00039R-U7@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/08 00:14:20

  Modified:    examples/drools/resources/WEB-INF  components.xml
  Log:
  usage namespaced xml
  
  Revision  Changes    Path
  1.5       +15 -26    jboss-seam/examples/drools/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/resources/WEB-INF/components.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- components.xml	10 Nov 2006 19:07:54 -0000	1.4
  +++ components.xml	8 Dec 2006 05:14:20 -0000	1.5
  @@ -1,26 +1,15 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  -
  -<components>
  -
  -    <component name="ruleBase" class="org.jboss.seam.drools.RuleBase">
  -        <property name="ruleFiles">numberguess.drl</property>
  -    </component>
  -    
  -    <component name="workingMemory" class="org.jboss.seam.drools.ManagedWorkingMemory">
  -        <property name="ruleBase">#{ruleBase}</property>
  -    </component>
  -
  -    <component name="org.jboss.seam.core.init">
  -        <property name="debug">true</property>
  -    </component>
  -    
  -    <component class="org.jboss.seam.core.Jbpm">
  -        <property name="pageflowDefinitions">pageflow.jpdl.xml</property>
  -    </component>
  -
  -    <component class="org.jboss.seam.core.Microcontainer" 
  -           installed="@microcontainer@"/>
  +<components xmlns="http://jboss.com/products/seam/components" 
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:drools="http://jboss.com/products/seam/drools">
  +    <drools:rule-base name="ruleBase" rule-files="numberguess.drl"/>
  +    <drools:managed-working-memory name="workingMemory" rule-base="#{ruleBase}"/>
  +
  +    <core:jbpm>
  +        <core:pageflow-definitions>
  +            <value>pageflow.jpdl.xml</value>
  +        </core:pageflow-definitions>
  +    </core:jbpm>
       
  +    <core:init debug="true"/>
  +    <core:microcontainer installed="@microcontainer@"/>
   </components>
  \ No newline at end of file
  
  
  


From forge-admin at jboss.com  Fri Dec  8 01:00:33 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Fri, 08 Dec 2006 01:00:33 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GsYmf-0003mC-3U@committer01.frg.pub.inap.atl.jboss.com>

Commit from tdiesler (2006-12-07 10:41 EST)
--------------------

reorganised package structure

  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml                  1.33
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar                1.28
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar                 1.27
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar                  1.28
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar              1.39
+ repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar   1.1
+ repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar  1.1
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar                     1.39


Commit from jmazzitelli (2006-12-07 10:44 EST)
-----------------------

add the i18nlog 1.0.6 version - jboss-on uses it

+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.jar       1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.jar.md5   1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.jar.sha1  1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.pom       1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.pom.md5   1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.6/i18nlog-1.0.6.pom.sha1  1.1


Commit from bstansberry (2006-12-07 15:01 EST)
-----------------------

Remove javadoc link to internal field

  JBossCache  src/org/jboss/cache/TreeCache.java  1.289


Commit from bstansberry (2006-12-07 15:03 EST)
-----------------------

Make internal fields private

  JBossCache  src/org/jboss/cache/TransactionEntry.java  1.15


Commit from rsigal (2006-12-07 15:44 EST)
------------------

JBREM-647:  Initialize configuration to empty HashMap.

  JBossRemoting  src/main/org/jboss/remoting/Client.java  1.60


Commit from rsigal on branch remoting_2_x (2006-12-07 15:45 EST)
-----------------------------------------

JBREM-647:  Initialize configuration to empty HashMap.

  JBossRemoting  src/main/org/jboss/remoting/Client.java  1.53.2.8


Commit from myuan (2006-12-07 16:04 EST)
-----------------

move libs and use s:selectDate

  jboss-seam  examples/glassfish/build.xml                           1.4
- jboss-seam  examples/glassfish/lib/el-api.jar                      1.3
- jboss-seam  examples/glassfish/lib/el-ri.jar                       1.3
- jboss-seam  examples/glassfish/lib/jsf-facelets.jar                1.2
  jboss-seam  examples/glassfish/resources/META-INF/application.xml  1.3
  jboss-seam  examples/glassfish/view/book.xhtml                     1.2


Commit from myuan (2006-12-07 16:35 EST)
-----------------

move libs and use s:selectDate

  jboss-seam  examples/jpa/build.xml              1.8
- jboss-seam  examples/jpa/lib/el-api.jar         1.3
- jboss-seam  examples/jpa/lib/el-ri.jar          1.3
- jboss-seam  examples/jpa/lib/jsf-facelets.jar   1.2
- jboss-seam  examples/jpa/lib/note.txt           1.2
  jboss-seam  examples/jpa/view/book.xhtml        1.6
- jboss-seam  examples/jpa/view/js/datePicker.js  1.2


Commit from rsigal (2006-12-07 16:43 EST)
------------------

JBREM-635:  (1) Test for EOFException in read(). (2) No longer throws exception from isBinaryData().

  JBossRemoting  src/main/org/jboss/remoting/marshal/http/HTTPUnMarshaller.java  1.12


Commit from rsigal on branch remoting_2_x (2006-12-07 16:44 EST)
-----------------------------------------

JBREM-635:  (1) Test for EOFException in read(). (2) No longer throws exception from isBinaryData()

  JBossRemoting  src/main/org/jboss/remoting/marshal/http/HTTPUnMarshaller.java  1.10.2.1


Commit from myuan (2006-12-07 16:44 EST)
-----------------

move libs and use s:selectDate

  jboss-seam  examples/hibernate2/build.xml              1.7
- jboss-seam  examples/hibernate2/lib/el-api.jar         1.3
- jboss-seam  examples/hibernate2/lib/el-ri.jar          1.3
- jboss-seam  examples/hibernate2/lib/jsf-facelets.jar   1.2
- jboss-seam  examples/hibernate2/lib/note.txt           1.2
  jboss-seam  examples/hibernate2/view/book.xhtml        1.6
- jboss-seam  examples/hibernate2/view/js/datePicker.js  1.2


Commit from bill (2006-12-07 16:49 EST)
----------------

refactor ArchiveBrowser so we can plug in vfs urls separately

+ repository.jboss.com  jboss/common-core/2.0.3.GA/component-info.xml                 1.1
+ repository.jboss.com  jboss/common-core/2.0.3.GA/lib/jboss-common-core-sources.jar  1.1
+ repository.jboss.com  jboss/common-core/2.0.3.GA/lib/jboss-common-core.jar          1.1


Commit from vblagojevic (2006-12-07 17:20 EST)
-----------------------

[JBCACHE-315] work in progress (JGroups block event passed to interceptors)

  JBossCache  src/org/jboss/cache/marshall/MethodDeclarations.java  1.25
  JBossCache  src/org/jboss/cache/TreeCache.java                    1.290


Commit from vblagojevic (2006-12-07 17:21 EST)
-----------------------

bypass interceptor chain while state is being integrated

  JBossCache  src/org/jboss/cache/statetransfer/StateTransferManager.java  1.16


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-07 17:35 EST)
---------------------------------------------------------

Add mux config docs
General cleanup, alphabetize

  JBossCache  docs/TreeCache/en/modules/configuration.xml  1.10.2.3


Commit from bstansberry (2006-12-07 17:36 EST)
-----------------------

General cleanup, alphabetize

  JBossCache  docs/TreeCache/en/modules/configuration.xml  1.14


Commit from myuan (2006-12-07 17:42 EST)
-----------------

minor fix

  jboss-seam  examples/glassfish/resources/META-INF/persistence.xml               1.3
  jboss-seam  examples/glassfish/src/org/jboss/seam/example/booking/Booking.java  1.2
- jboss-seam  examples/glassfish/view/js/datePicker.js                            1.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-07 19:19 EST)
------------------------------------------------------

Added a delay

  JBossCache  tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java  1.1.2.3


Commit from nrichards (2006-12-07 19:37 EST)
---------------------

update selectDate css

  jboss-seam  src/ui/org/jboss/seam/ui/selectDate.js  1.2
  jboss-seam  seam-gen/view/stylesheet/theme.css      1.5


Commit from nrichards (2006-12-07 19:38 EST)
---------------------

selectDate css

  jboss-seam  examples/booking/view/css/screen.css  1.8
+ jboss-seam  examples/booking/view/css/date.css    1.1
  jboss-seam  examples/booking/view/template.xhtml  1.9
  jboss-seam  examples/seampay/view/date.css        1.2


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-07 20:24 EST)
---------------------------------------------------------

Don't refer to internal field in Javadoc
Default mux stack should be udp

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.29


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-07 20:26 EST)
---------------------------------------------------------

[JBCACHE-874] Store locks in a LinkedHashSet

  JBossCache  src/org/jboss/cache/TransactionEntry.java  1.8.2.2


Commit from nrichards (2006-12-07 20:58 EST)
---------------------

document selectDate

  jboss-seam  doc/reference/en/modules/controls.xml  1.9


Commit from nrichards (2006-12-07 22:01 EST)
---------------------

explicitly list the namespaces

  jboss-seam  doc/reference/en/modules/controls.xml  1.10
  jboss-seam  doc/reference/en/modules/xml.xml       1.2


Commit from vblagojevic on branch Branch_JBossCache_1_4_0 (2006-12-07 22:39 EST)
---------------------------------------------------------

prerelease 2.4.1 (in JChannelFactory invoke start|stopFlush only if we have FLUSH in stack)

  JBossCache  lib/jgroups.jar  1.4.2.3


Commit from bstansberry (2006-12-07 22:49 EST)
-----------------------

[JBCACHE-874] Store locks in a LinkedHashSet

  JBossCache  src/org/jboss/cache/TransactionEntry.java  1.16


Commit from starksm (2006-12-07 23:35 EST)
-------------------

Add aop 2.0.0.alpha2 to maven

+ repository.jboss.com  maven2/jboss/aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.jar  1.1
+ repository.jboss.com  maven2/jboss/aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.pom  1.1


Commit from starksm (2006-12-07 23:51 EST)
-------------------

Add the 2.0.0.Beta mc jars to the maven repository

+ repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta-sources.jar  1.1
+ repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.jar          1.1
+ repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom          1.1
+ repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom~         1.1
+ repository.jboss.com  maven2/jboss/jboss-container/2.0.0.Beta/jboss-container-2.0.0.Beta-sources.jar    1.1
+ repository.jboss.com  maven2/jboss/jboss-container/2.0.0.Beta/jboss-container-2.0.0.Beta.jar            1.1
+ repository.jboss.com  maven2/jboss/jboss-container/2.0.0.Beta/jboss-container-2.0.0.Beta.pom            1.1
+ repository.jboss.com  maven2/jboss/jboss-dependency/2.0.0.Beta/jboss-dependency-2.0.0.Beta-sources.jar  1.1
+ repository.jboss.com  maven2/jboss/jboss-dependency/2.0.0.Beta/jboss-dependency-2.0.0.Beta.jar          1.1
+ repository.jboss.com  maven2/jboss/jboss-dependency/2.0.0.Beta/jboss-dependency-2.0.0.Beta.pom          1.1
+ repository.jboss.com  maven2/jboss/jboss-deployers/2.0.0.Beta/jboss-deployers-2.0.0.Beta.pom            1.1
+ repository.jboss.com  maven2/jboss/jboss-deployers/2.0.0.Beta/jboss-deployers-2.0.0.Beta.pom~           1.1
+ repository.jboss.com  maven2/jboss/jboss-kernel/2.0.0.Beta/jboss-kernel-2.0.0.Beta-sources.jar          1.1
+ repository.jboss.com  maven2/jboss/jboss-kernel/2.0.0.Beta/jboss-kernel-2.0.0.Beta.jar                  1.1
+ repository.jboss.com  maven2/jboss/jboss-kernel/2.0.0.Beta/jboss-kernel-2.0.0.Beta.pom                  1.1


Commit from nrichards (2006-12-08 00:14 EST)
---------------------

usage namespaced xml

  jboss-seam  examples/drools/resources/WEB-INF/components.xml  1.5
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061208/29a38a21/attachment.html 

From norman.richards at jboss.com  Fri Dec  8 01:34:17 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 08 Dec 2006 01:34:17 -0500
Subject: [jboss-cvs] jboss-seam/examples/portal  ...
Message-ID: <E1GsZJJ-0004O4-8i@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/08 01:34:17

  Modified:    examples/portal  build.xml
  Log:
  use new build
  
  Revision  Changes    Path
  1.10      +34 -79    jboss-seam/examples/portal/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/portal/build.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- build.xml	23 Oct 2006 19:31:19 -0000	1.9
  +++ build.xml	8 Dec 2006 06:34:17 -0000	1.10
  @@ -6,89 +6,58 @@
       <property name="Name"                   value="Seam on JBoss Portal/Hibernate3 Example"/>
       <property name="example.name"           value="jboss-seam-portal"/>
       
  -    <!-- WAR -->
  -    <zipfileset id="example.war.docroot"
  -               dir="view">
  -        <include name="**/*"/>
  -    </zipfileset>
  +    <!-- Overrides -->
  +    <property name="unit.ext"                value="war" />
  +    <property name="example.seam.ui.lib"     value="yes"/>
  +    <property name="example.seam.debug.lib"  value="yes"/>
  +    <property name="example.facelets.lib"    value="yes"/>
  +    <property name="example.ds"              value="portal-ds.xml"/>
  +    <property name="src.java.dir"            value="src"/>
  +    <property name="src.test.dir"            value="src"/>
  +    <property name="test.classpath"          value="test.eejb.classpath"/>
  +    <property name="tomcat.conf"             value="eejb.conf"/>
   	
  -    <zipfileset id="example.war.webinf"
  -            prefix="WEB-INF"
  -               dir="resources/WEB-INF" >
  -        <include name="**/*"/>
  -        <exclude name="lib/**/*"/>
  -    </zipfileset>
  +    <property name="example.webinf.lib.dir" value="" />
   
  -    <zipfileset id="example.war.webinf.lib.extra" 
  -    	    prefix="WEB-INF/lib"
  -    	     refid="ui.seam.jar"/>
  -    
  -    <!-- EJB3 -->
  -    <fileset id="example.ejb3.root" dir=".">
  -        <include name="_NONE_"/>
  -    </fileset>
  +    <import file="../../build.xml"/>
   
  -    <fileset id="example.ejb3.lib" dir="../../lib">
  -        <include name="_NONE_"/>
  -    </fileset>
  +    <target name="ear" depends="ejb3, war" />
     
  -    <!-- EAR -->
  -    <zipfileset id="example.ear.resources" dir=".">
  -        <include name="_NONE_"/>
  -    </zipfileset>
   
  -    <!-- Test -->
  -    <fileset id="example.resources" dir="resources">
  -        <include name="**/*.*"/>
  -    </fileset>
       
  -    <!-- Deploy -->
  -    <fileset id="example.deploy"
  -            dir="resources">
  -        <include name="portal-ds.xml"/>
  +    <target name="war" depends="compile">
  +        <jar jarfile="${build.dir}/${example.name}.jar">
  +            <fileset refid="example.classes"/>
  +            <fileset dir="resources">
  +                <include name="seam.properties"/>
  +                <include name="import.sql"/>
  +                <include name="hibernate.cfg.xml"/>
       </fileset>
  +        </jar>
   
  -    <!-- Undeploy -->
  -    <patternset id="example.undeploy">
  -        <include name="portal-ds.xml"/>
  -    </patternset>
  -
  -    <!-- Overrides -->
  -    <property name="src.java.dir" value="src"/>
  -    <property name="src.test.dir" value="src"/>
  -    <property name="test.classpath" value="test.mc.classpath"/>
  -    <property name="tomcat.conf" value="mc.conf"/>
  -
  -    <import file="../../build.xml"/>
  -
  -    <!-- Redefine targets -->
  -    <target name="war" depends="compile">
   
           <copy todir="${build.dir}/resources/WEB-INF">
               <fileset refid="example.war.webinf"/>
  -            <filterset filtersfile="resources/WEB-INF/web.xml">
  +            <filterset>
                   <filter token="jndiPattern" value="${example.name}/#{ejbName}/local"/>
                   <filter token="embeddedEjb" value="false"/>
                   <filter token="microcontainer" value="false"/>
               </filterset>
           </copy>
           
  -    	<jar jarfile="${build.dir}/${example.name}.jar">
  -          <fileset refid="example.classes"/>
  -          <fileset dir="resources">
  -            <include name="seam.properties"/>
  -            <include name="import.sql"/>
  -            <include name="hibernate.cfg.xml"/>
  -          </fileset>
  -        </jar>
       	
           <jar destfile="${build.dir}/${example.name}.war">
  +            <zipfileset refid="example.tomcat.seam.jar"/>
               <zipfileset refid="example.war.docroot"/>
  -            <zipfileset refid="example.war.webinf.lib.extra"/>
  +            <zipfileset refid="example.war.webinf.lib"/>
  +            <zipfileset refid="example.facelets.jar"/>
  +            <zipfileset refid="example.extra.jar"/>
  +            <zipfileset dir="${lib.dir}" prefix="WEB-INF/lib">
  +                <include name="el-*.jar"/>
  +            </zipfileset>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
               </zipfileset>
  -            <zipfileset refid="example.tomcat.seam.jar"/>
               <zipfileset dir="${build.dir}" prefix="WEB-INF/lib">
                   <include name="${example.name}.jar"/>
               </zipfileset>
  @@ -96,18 +65,4 @@
       	
       </target>
       
  -    <target name="deploy" depends="war"
  -            description="Deploy the example war to JBoss">
  -        <fail unless="jboss.home">jboss.home MUST be set. Update build.properties to point to a valid JBoss installation.</fail>
  -        <copy todir="${deploy.dir}">
  -            <fileset refid="example.deploy"/>
  -        </copy>
  -        <copy file="${build.dir}/${example.name}.war" todir="${deploy.dir}"/>
  -    </target>
  -
  -    <target name="undeploy"
  -    	    description="Undeploy the example war from JBoss">
  -        <antcall target="Seam.undeploy"><param name="unit.ext" value="war"/></antcall>
  -    </target>
  -
   </project>
  
  
  


From chiba at is.titech.ac.jp  Fri Dec  8 02:00:36 2006
From: chiba at is.titech.ac.jp (Shigeru Chiba)
Date: Fri, 08 Dec 2006 02:00:36 -0500
Subject: [jboss-cvs] javassist/src/main/javassist/expr  ...
Message-ID: <E1GsZim-0004jh-W3@committer01.frg.pub.inap.atl.jboss.com>

  User: chiba   
  Date: 06/12/08 02:00:36

  Modified:    src/main/javassist/expr  ExprEditor.java
  Log:
  minor bug fix
  
  Revision  Changes    Path
  1.11      +5 -1      javassist/src/main/javassist/expr/ExprEditor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExprEditor.java
  ===================================================================
  RCS file: /cvsroot/jboss/javassist/src/main/javassist/expr/ExprEditor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ExprEditor.java	9 Apr 2006 15:07:41 -0000	1.10
  +++ ExprEditor.java	8 Dec 2006 07:00:36 -0000	1.11
  @@ -101,7 +101,11 @@
               }
           }
   
  +        // codeAttr might be modified by other partys
  +        // so I check the current value of max-locals.
  +        if (codeAttr.getMaxLocals() < context.maxLocals)
           codeAttr.setMaxLocals(context.maxLocals);
  +
           codeAttr.setMaxStack(codeAttr.getMaxStack() + context.maxStack);
           return edited;
       }
  
  
  


From scott.stark at jboss.com  Fri Dec  8 02:09:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Fri, 08 Dec 2006 02:09:14 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-aop/2.0.0.alpha2
	- New directory ...
Message-ID: <E1GsZr8-00051s-Ej@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/08 02:09:14

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-aop/2.0.0.alpha2 added to the repository


From scott.stark at jboss.com  Fri Dec  8 02:11:10 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Fri, 08 Dec 2006 02:11:10 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-aop/2.0.0.alpha2
	...
Message-ID: <E1GsZt0-00056O-1p@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/08 02:11:10

  Added:       maven2/jboss/jboss-aop/2.0.0.alpha2  
                        jboss-aop-2.0.0.alpha2.jar
                        jboss-aop-2.0.0.alpha2.pom
  Log:
  Rename aop jboss-aop to be consistent with the artifact names
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 07:11:10;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 07:11:10;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.pom
  
  Index: jboss-aop-2.0.0.alpha2.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-aop</artifactId>
    <name>JBoss AOP</name>
    <version>2.0.0.alpha2</version>
    <description>JBoss AOP</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
  
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  
  


From scott.stark at jboss.com  Fri Dec  8 02:11:10 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Fri, 08 Dec 2006 02:11:10 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta ...
Message-ID: <E1GsZt0-00056Y-4p@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/08 02:11:10

  Modified:    maven2/jboss/jboss-aop-mc-int/2.0.0.Beta  
                        jboss-aop-mc-int-2.0.0.Beta.pom
                        jboss-aop-mc-int-2.0.0.Beta.pom~
  Log:
  Rename aop jboss-aop to be consistent with the artifact names
  
  Revision  Changes    Path
  1.2       +1 -1      repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-aop-mc-int-2.0.0.Beta.pom
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- jboss-aop-mc-int-2.0.0.Beta.pom	8 Dec 2006 04:51:39 -0000	1.1
  +++ jboss-aop-mc-int-2.0.0.Beta.pom	8 Dec 2006 07:11:10 -0000	1.2
  @@ -20,7 +20,7 @@
     <dependencies>
       <dependency>
         <groupId>jboss</groupId>
  -      <artifactId>aop</artifactId>
  +      <artifactId>jboss-aop</artifactId>
         <version>2.0.0.alpha2</version>
       </dependency>
       <dependency>
  
  
  
  1.2       +5 -0      repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom~
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-aop-mc-int-2.0.0.Beta.pom~
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom~,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- jboss-aop-mc-int-2.0.0.Beta.pom~	8 Dec 2006 04:51:39 -0000	1.1
  +++ jboss-aop-mc-int-2.0.0.Beta.pom~	8 Dec 2006 07:11:10 -0000	1.2
  @@ -20,6 +20,11 @@
     <dependencies>
       <dependency>
         <groupId>jboss</groupId>
  +      <artifactId>aop</artifactId>
  +      <version>2.0.0.alpha2</version>
  +    </dependency>
  +    <dependency>
  +      <groupId>jboss</groupId>
         <artifactId>jboss-logging-spi</artifactId>
         <version>2.0.2.GA</version>
       </dependency>
  
  
  


From scott.stark at jboss.com  Fri Dec  8 03:21:32 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Fri, 08 Dec 2006 03:21:32 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta ...
Message-ID: <E1Gsaz6-0006Il-EP@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/08 03:21:32

  Modified:    maven2/jboss/jboss-aop-mc-int/2.0.0.Beta 
                        jboss-aop-mc-int-2.0.0.Beta.pom
  Log:
  Change the dependency from jboss-microcontainer to jboss-kernel
  
  Revision  Changes    Path
  1.3       +1 -1      repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-aop-mc-int-2.0.0.Beta.pom
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- jboss-aop-mc-int-2.0.0.Beta.pom	8 Dec 2006 07:11:10 -0000	1.2
  +++ jboss-aop-mc-int-2.0.0.Beta.pom	8 Dec 2006 08:21:32 -0000	1.3
  @@ -54,7 +54,7 @@
       </dependency>
       <dependency>
         <groupId>jboss</groupId>
  -      <artifactId>jboss-microcontainer</artifactId>
  +      <artifactId>jboss-kernel</artifactId>
         <version>2.0.0.Beta</version>
         <scope>compile</scope>
       </dependency>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 04:22:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 04:22:18 -0500
Subject: [jboss-cvs] JBossAS SVN: r58922 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session
Message-ID: <E1Gsbvu-0007Hn-Rj@committer01.frg.pub.inap.atl.jboss.com>

Author: jfrederic.clere at jboss.com
Date: 2006-12-08 04:22:17 -0500 (Fri, 08 Dec 2006)
New Revision: 58922

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JvmRouteValve.java
Log:
Make sure to use the received sessionid string.
See http://jira.jboss.com/jira/browse/JBAS-3829


Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JvmRouteValve.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JvmRouteValve.java	2006-12-08 03:07:36 UTC (rev 58921)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/session/JvmRouteValve.java	2006-12-08 09:22:17 UTC (rev 58922)
@@ -87,6 +87,7 @@
    public void checkJvmRoute(Request req, Response res)
       throws IOException, ServletException
    {
+      String oldsessionId = req.getRequestedSessionId();
       HttpSession session = req.getSession(false);
       if (session != null)
       {
@@ -108,25 +109,33 @@
 
          // Check if incoming session id has JvmRoute appended. If not, append it.
          boolean setCookie = !req.isRequestedSessionIdFromURL();
-         handleJvmRoute(sessionId, jvmRoute, res, setCookie);
+         handleJvmRoute(oldsessionId, sessionId, jvmRoute, res, setCookie);
       }
    }
 
-   protected void handleJvmRoute(String sessionId, 
+   protected void handleJvmRoute(String oldsessionId,
+                                 String sessionId, 
                                  String jvmRoute, 
                                  HttpServletResponse response,
                                  boolean setCookie)
    {
       // Get requested jvmRoute.
       // TODO. The current format is assumed to be id.jvmRoute. Can be generalized later.
+      String receivedJvmRoute = null;
+      int index = oldsessionId.lastIndexOf(".");
+      if (index > 0)
+      {
+         receivedJvmRoute = oldsessionId.substring(index + 1, sessionId.length());
+      }
+
       String requestedJvmRoute = null;
-      int index = sessionId.lastIndexOf(".");
+      index = sessionId.lastIndexOf(".");
       if (index > 0)
       {
          requestedJvmRoute = sessionId.substring(index + 1, sessionId.length());
       }
 
-      String newId = sessionId;
+      String newId = null;
       if (!jvmRoute.equals(requestedJvmRoute))
       {
          if (requestedJvmRoute == null)
@@ -151,9 +160,22 @@
          
          resetSessionId(sessionId, newId);
          
-         if (setCookie)
-            manager_.setNewSessionCookie(newId, response);
       }
+      /* Also check the jvmRoute received (via req.getRequestedSessionId()) */
+      if (!jvmRoute.equals(receivedJvmRoute))
+      {
+            if (log_.isDebugEnabled())
+            {
+               log_.debug("handleJvmRoute(): We have detected a failover with different jvmRoute." +
+                  " received one: " + receivedJvmRoute + " new one: " + jvmRoute + ". Will resent the session id.");
+            }
+            String base = sessionId.substring(0, index);
+            newId = base + "." + jvmRoute;
+      }
+
+      /* Change the sessionid cookie if needed */
+      if (setCookie && newId != null)
+         manager_.setNewSessionCookie(newId, response);
    }
    
    private void resetSessionId(String oldId, String newId)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 05:28:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 05:28:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r58923 - in trunk/ejb3/src:
	main/org/jboss/ejb3/metamodel resources/test/appclient
	test/org/jboss/ejb3/test/appclient/client
	test/org/jboss/ejb3/test/appclient/unit
Message-ID: <E1GscyG-0008M2-BT@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-08 05:28:33 -0500 (Fri, 08 Dec 2006)
New Revision: 58923

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/ApplicationClientDDObjectFactory.java
   trunk/ejb3/src/resources/test/appclient/application-client.xml
   trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/client/HelloWorldClient.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/unit/AppClientUnitTestCase.java
Log:
EJBTHREE-803: application-client id

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/ApplicationClientDDObjectFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/ApplicationClientDDObjectFactory.java	2006-12-08 09:22:17 UTC (rev 58922)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/ApplicationClientDDObjectFactory.java	2006-12-08 10:28:33 UTC (rev 58923)
@@ -133,6 +133,10 @@
             {
                // ignore
             }
+            else if(attrs.getLocalName(i).equals("id"))
+            {
+               // ignore
+            }
             else
                throw new IllegalArgumentException(attrs.getLocalName(i));
          }

Modified: trunk/ejb3/src/resources/test/appclient/application-client.xml
===================================================================
--- trunk/ejb3/src/resources/test/appclient/application-client.xml	2006-12-08 09:22:17 UTC (rev 58922)
+++ trunk/ejb3/src/resources/test/appclient/application-client.xml	2006-12-08 10:28:33 UTC (rev 58923)
@@ -3,7 +3,7 @@
                     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                     xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
                     http://java.sun.com/xml/ns/javaee/application-client_5.xsd"
-                    version="5">
+                    version="5" id="appclient-test">
 	<display-name>appclient-test-client</display-name>
 	<description>application client unit test</description>
 

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/client/HelloWorldClient.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/client/HelloWorldClient.java	2006-12-08 09:22:17 UTC (rev 58922)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/client/HelloWorldClient.java	2006-12-08 10:28:33 UTC (rev 58923)
@@ -56,6 +56,13 @@
    @Resource(name="messageReplier")
    private static Destination destination;
    
+   private static int postConstructCalls = 0;
+   
+   public static int getPostConstructCalls()
+   {
+      return postConstructCalls;
+   }
+   
    public static String getResult()
    {
       return result;
@@ -114,4 +121,9 @@
          throw new RuntimeException(e);
       }
    }
+   
+   public static void postConstruct()
+   {
+      postConstructCalls++;
+   }
 }

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/unit/AppClientUnitTestCase.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/unit/AppClientUnitTestCase.java	2006-12-08 09:22:17 UTC (rev 58922)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/appclient/unit/AppClientUnitTestCase.java	2006-12-08 10:28:33 UTC (rev 58923)
@@ -57,9 +57,17 @@
       
       ClientLauncher.launch(xml, mainClassName, applicationClientName, args);
       
-      String actual = HelloWorldClient.getResult();
-      String expected = "Hi " + name + ", how are you?";
-      assertEquals(expected, actual);
+      {
+         String actual = HelloWorldClient.getResult();
+         String expected = "Hi " + name + ", how are you?";
+         assertEquals(expected, actual);
+      }
+      
+      {
+         int actual = HelloWorldClient.getPostConstructCalls();
+         int expected = 1;
+         assertEquals("postConstruct should be called once", expected, actual);
+      }
    }
    
    public static Test suite() throws Exception



From msurtani at jboss.com  Fri Dec  8 07:04:04 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 07:04:04 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GseSS-0001bp-EV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 07:04:04

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        OptimisticValidatorInterceptor.java
  Log:
  More informative logging/error msgs
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.25.2.8  +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.25.2.7
  retrieving revision 1.25.2.8
  diff -u -b -r1.25.2.7 -r1.25.2.8
  --- OptimisticValidatorInterceptor.java	6 Dec 2006 16:00:14 -0000	1.25.2.7
  +++ OptimisticValidatorInterceptor.java	8 Dec 2006 12:04:04 -0000	1.25.2.8
  @@ -141,7 +141,7 @@
                  // test that the 2 DataVersion types match up
                  if (!realNode.getVersion().getClass().equals(workspaceNode.getVersion().getClass()) && checkNotInitialRootVersion(realNode))
                  {
  -                  throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node that already contains version of type " + realNode.getVersion().getClass());                  
  +                  throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node [fqn = "+realNode.getFqn()+"] that already contains version of type " + realNode.getVersion().getClass());                  
                  }
                  if ((workspaceNode.isDeleted() || workspaceNode.isDirty()) && realNode.getVersion().newerThan( workspaceNode.getVersion() ))
                  {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 07:15:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 07:15:53 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1725 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/bin tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1Gsedt-0001on-MN@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-08 07:15:43 -0500 (Fri, 08 Dec 2006)
New Revision: 1725

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
Get ManualClusteringTest to run



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -81,6 +81,8 @@
    {
       if (getServers(invocation) != null)
       {         
+         log.info("Clustered createConnection");
+                  
          //In a clustered configuration we create connections in a round-robin fashion
          //from the available servers
          
@@ -168,7 +170,7 @@
       
       ConnectionState state = (ConnectionState)((DelegateSupport)connDelegate).getState();
       
-      state.getRemotingConnection().getInvokingClient().addConnectionListener(new Listener(connDelegate));
+      //state.getRemotingConnection().getInvokingClient().addConnectionListener(new Listener(connDelegate));
       
       return connDelegate;   
    }
@@ -427,6 +429,8 @@
       Listener(ClientConnectionDelegate connection)
       {
          this.connection = connection;
+         
+         log.info("************* CREATING LISTENER");
       }
       
       public void handleConnectionException(Throwable throwable, Client client)
@@ -439,6 +443,7 @@
          }
          catch (Throwable e)
          {
+            log.error("Caught exception in handling failure", e);
             e.printStackTrace();
          }
       }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -40,6 +40,8 @@
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
+
+import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
 import org.jboss.jms.server.QueuedExecutorPool;
@@ -417,6 +419,18 @@
          log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx);
       }
       
+      //debug
+      try
+      {
+         TextMessage tm = (TextMessage)ref.getMessage();
+         
+         log.info(this.currentNodeId + " *********** Routing ref: " + tm.getText() + " with condition " + condition + " and transaction " + tx);
+      }
+      catch (Exception e)
+      {
+         e.printStackTrace();
+      }
+      
       if (ref == null)
       {
          throw new IllegalArgumentException("Message reference is null");
@@ -488,9 +502,13 @@
                   if (trace)
                   {
                      log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
-                               queue.getNodeId() +" local:" + queue.isLocal());
+                               queue.getNodeId() + " local:" + queue.isLocal());
+                     
                   }
                   
+                  log.info(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
+                           queue.getNodeId() + " local:" + queue.isLocal());
+                  
                   if (router.numberOfReceivers() > 1)
                   {
                      //We have now chosen which one will receive the message so we need to add this
@@ -820,6 +838,11 @@
          log.trace(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
                   routingKey + " map " + queueNameNodeIdMap);
       }
+      
+      log.info(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
+               routingKey + " map " + queueNameNodeIdMap);
+      
+      
             
       lock.readLock().acquire();  
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -21,6 +21,12 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import java.util.ArrayList;
+import java.util.Iterator;
+import java.util.List;
+
+import javax.jms.TextMessage;
+
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
@@ -28,10 +34,6 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.tx.Transaction;
 
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-
 /**
  * 
  * A DefaultRouter
@@ -166,15 +168,15 @@
    {
       if (trace) { log.trace(this + " routing ref " + reference); }
 
-      //Favour the local queue or the failedOver queue in round robbin
+      //Favour the local queue or the failedOver queue in round robin
 
       if (!failedOverQueues.isEmpty())
       {
-
-         if (trace) { log.trace("Round robbing on FailedOver queue, currentTarget=" + target);}
+         if (trace) { log.trace("Round robin on FailedOver queue, currentTarget=" + target);}
+         
          LocalClusteredQueue queueToUse = null;
 
-         if (target==-1)
+         if (target == -1)
          {
             queueToUse = (LocalClusteredQueue)this.localQueue; 
          }
@@ -185,18 +187,30 @@
 
          incTargetFailedOver();
          
+         log.info("***************** Routing to failed over queue");
          Delivery del = queueToUse.handle(observer, reference, tx);
 
          if (trace) { log.trace(this+" routed to failed queue, using failedOver round robbing, returned " + del); }
          
          return del;
       }
-      else
-      if (localQueue != null)
+      else if (localQueue != null)
       {
          //The only time the local queue won't accept is if the selector doesn't
          //match - in which case it won't match at any other nodes too so no point
          //in trying them
+         
+         //debug
+         try
+         {
+            TextMessage tm = (TextMessage)reference.getMessage();
+            
+            log.info("*********** Routing to local queue: " + tm.getText() + " id:" + System.identityHashCode(localQueue) );
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
 
          Delivery del = localQueue.handle(observer, reference, tx);
 
@@ -215,6 +229,7 @@
 
             queue = (ClusteredQueue)nonLocalQueues.get(target);
 
+            log.info("************ Routing to non local queue");
             Delivery del = queue.handle(observer, reference, tx);
 
             if (trace) { log.trace(this + " routed to remote queue, it returned " + del); }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -148,6 +148,8 @@
    {
       if (trace) { log.trace("Handling ref from cluster: " + ref); }
       
+      log.info("********** Handling ref from cluster: " + ref);
+      
       if (filter != null && !filter.accept(ref))
       {
          Delivery del = new SimpleDelivery(this, ref, true, false);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -107,6 +107,8 @@
       {
          Delivery del = new SimpleDelivery(this, reference, false, false);
          
+         log.info("********** doesn't match filter");
+         
          return del;
       }
       
@@ -126,6 +128,8 @@
             return null;
          }
       }
+      
+      log.info("*********** accepting message:" + reference);
   
       return new SimpleDelivery(this, reference, false);      
    }

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-08 12:15:43 UTC (rev 1725)
@@ -42,8 +42,6 @@
    TEST_CLUSTERED=$ENV_TEST_CLUSTERED
 fi
 
-TEST_DATABASE=mysql
-
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get
 # it from there.

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -21,10 +21,20 @@
  */
 package org.jboss.test.messaging.jms.clustering;
 
+import javax.jms.Connection;
+import javax.jms.DeliveryMode;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageListener;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 
-import javax.jms.*;
-
 /**
  * 
  * A ManualClusteringTest
@@ -57,8 +67,7 @@
 
    public void testClusteredQueueLocalConsumerNonPersistent() throws Exception
    {
-      System.out.println("xxxxxxxxxxxx");
-//      clusteredQueueLocalConsumer(false);
+      clusteredQueueLocalConsumer(false);
    }
 
    public void testClusteredQueueLocalConsumerPersistent() throws Exception
@@ -127,8 +136,34 @@
 
    protected void tearDown() throws Exception
    {
-         super.tearDown();
+      super.tearDown();
    }
+   
+   private void checkConnectionsDifferentServers(Connection conn, Connection conn1, Connection conn2)
+   {
+      ConnectionState state = (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
+      
+      ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+      
+      ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+      
+      int serverID = state.getServerID();
+      
+      int serverID1 = state1.getServerID();
+      
+      int serverID2 = state2.getServerID();
+      
+      log.info("Server id:" + serverID);
+      
+      log.info("Server id1:" + serverID1);
+      
+      log.info("Server id2:" + serverID2);
+      
+      
+      assertTrue(serverID != serverID1);
+      
+      assertTrue(serverID1 != serverID2);
+   }
 
    /*
     * Create a consumer on each queue on each node.
@@ -143,17 +178,27 @@
 
       try
       {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn, conn1, conn2);
 
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.info("Created sessions");
 
          MessageConsumer cons = sess.createConsumer(queue);
          MessageConsumer cons1 = sess1.createConsumer(queue1);
          MessageConsumer cons2 = sess2.createConsumer(queue2);
+         
+         log.info("Created consumers");
 
          conn.start();
          conn1.start();
@@ -173,15 +218,19 @@
 
             prod.send(tm);
          }
+         
+         log.info("Sent messages");
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons.receive(1000);
 
             assertNotNull(tm);
-
+            
+            log.info("1 GOT MESSAGE: " + tm.getText());
+            
             assertEquals("message" + i, tm.getText());
-         }
+         }                 
 
          Message m = cons1.receive(2000);
 
@@ -283,9 +332,15 @@
       Connection conn2 = null;
       try
       {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn, conn1, conn2);
 
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -395,9 +450,15 @@
 
       try
       {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn, conn1, conn2);
 
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -529,9 +590,15 @@
       Connection conn2 = null;
       try
       {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn, conn1, conn2);
 
          conn.setClientID("wib1");
          conn1.setClientID("wib1");
@@ -683,10 +750,15 @@
       try
 
       {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
-
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn, conn1, conn2);
          conn.setClientID("wib1");
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
@@ -855,10 +927,16 @@
 
       try
       {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
-
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn, conn1, conn2);
+         
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -61,8 +61,8 @@
    protected Topic topic2;
 
    protected ConnectionFactory cf;
-   protected ConnectionFactory cf1;
-   protected ConnectionFactory cf2;
+  // protected ConnectionFactory cf1;
+  // protected ConnectionFactory cf2;
 
    // Constructors --------------------------------------------------
 
@@ -99,10 +99,10 @@
          ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
          ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
 
+         //We only need to lookup one connection factory since it will be a clustered cf
+         //so we will actually create connections on different servers (round robin)
          cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
-         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-
+                  
          queue = (Queue)ic.lookup("queue/testDistributedQueue");
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
@@ -124,15 +124,15 @@
    {
       try
       {
-         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 0");
+         ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0");
          ServerManagement.undeployQueue("testDistributedQueue", 0);
          ServerManagement.undeployTopic("testDistributedTopic", 0);
 
-         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 1");
+         ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1");
          ServerManagement.undeployQueue("testDistributedQueue", 1);
          ServerManagement.undeployTopic("testDistributedTopic", 1);
 
-         ServerManagement.log(ServerManagement.INFO,"Undeploying Server 2");
+         ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2");
          ServerManagement.undeployQueue("testDistributedQueue", 2);
          ServerManagement.undeployTopic("testDistributedTopic", 2);
 
@@ -157,9 +157,11 @@
 
       try
       {
+         //Since the cf is clustered, this will create connections on 3 different nodes
+         //(round robin)
          conn = cf.createConnection();
-         conn1 = cf1.createConnection();
-         conn2 = cf2.createConnection();
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
 
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -178,18 +180,21 @@
          do
          {
             msg = cons.receive(1000);
+            log.info("1 Drained message " + msg);
          }
          while (msg != null);
 
          do
          {
             msg = cons1.receive(1000);
+            log.info("2 Drained message " + msg);
          }
          while (msg != null);
 
          do
          {
             msg = cons2.receive(1000);
+            log.info("3 Drained message " + msg);
          }
          while (msg != null);
       }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-08 02:12:13 UTC (rev 1724)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-08 12:15:43 UTC (rev 1725)
@@ -256,7 +256,7 @@
    {
       try
       {
-         log.info(" Server peer ID ........... " + serverPeerID);
+         log.info(" Server peer ID ........... " + serverPeerID + " clustered: " + clustered);
          
          log.debug("creating ServerPeer instance");
    



From msurtani at jboss.com  Fri Dec  8 07:17:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 07:17:58 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gsefu-0001s8-Ol@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 07:17:58

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Anycast test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.30 +13 -2     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.29
  retrieving revision 1.195.2.30
  diff -u -b -r1.195.2.29 -r1.195.2.30
  --- TreeCache.java	8 Dec 2006 01:24:59 -0000	1.195.2.29
  +++ TreeCache.java	8 Dec 2006 12:17:58 -0000	1.195.2.30
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.29 2006/12/08 01:24:59 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.30 2006/12/08 12:17:58 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -110,6 +110,7 @@
      private static final String JBOSS_SERVER_DOMAIN = "jboss";
   
      private static final String REMOVAL_MARKER = "__JBOSS_MARKED_FOR_REMOVAL";
  +   private boolean forceAnycast = false;
      /**
       * Default replication version, from {@link Version#getVersionShort}.
       */
  @@ -561,6 +562,16 @@
         return using_mux;
      }
   
  +   public boolean isForceAnycast()
  +   {
  +      return forceAnycast;
  +   }
  +
  +   public void setForceAnycast(boolean b)
  +   {
  +      forceAnycast = b;
  +   }
  +
      /**
       * Returns the transaction table.
       */
  @@ -4315,7 +4326,7 @@
   
   
         // if we are using buddy replication, all calls should use ANYCAST.  Otherwise, use the default (multicast).
  -      rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout, buddyManager != null && buddyManager.isEnabled());
  +      rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
   
   
         // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
  
  
  


From msurtani at jboss.com  Fri Dec  8 07:17:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 07:17:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1Gsefu-0001sJ-Su@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 07:17:58

  Added:       tests/functional/org/jboss/cache/replicated  Tag:
                        Branch_JBossCache_1_4_0 AnycastTest.java
  Log:
  Anycast test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +68 -0     JBossCache/tests/functional/org/jboss/cache/replicated/Attic/AnycastTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AnycastTest.java
  ===================================================================
  RCS file: AnycastTest.java
  diff -N AnycastTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ AnycastTest.java	8 Dec 2006 12:17:58 -0000	1.1.2.1
  @@ -0,0 +1,68 @@
  +package org.jboss.cache.replicated;
  +
  +import junit.framework.TestCase;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.misc.TestingUtil;
  +
  +
  +public class AnycastTest extends TestCase
  +{
  +   TreeCache[] caches;
  +   Fqn fqn = Fqn.fromString("/test");
  +
  +   protected void setUp() throws Exception
  +   {
  +      caches = new TreeCache[3];
  +      caches[0] = createCache();
  +      caches[1] = createCache();
  +      caches[2] = createCache();
  +
  +      TestingUtil.blockUntilViewsReceived(caches, 10000);
  +   }
  +
  +   protected void tearDown()
  +   {
  +      if (caches != null)
  +      {
  +         for (int i=0; i<caches.length; i++) caches[i].stopService();
  +      }
  +      caches = null;
  +   }
  +
  +   private TreeCache createCache() throws Exception
  +   {
  +      TreeCache c = new TreeCache();
  +      c.setCacheMode("REPL_SYNC");
  +      c.startService();
  +      return c;
  +   }
  +
  +   public void testMCastReplication() throws Exception
  +   {
  +      assertNull(caches[0].get(fqn));
  +      assertNull(caches[1].get(fqn));
  +      assertNull(caches[2].get(fqn));
  +      
  +      caches[0].put(fqn, "k", "v");
  +
  +      assertEquals("v", caches[0].get(fqn, "k"));
  +      assertEquals("v", caches[1].get(fqn, "k"));
  +      assertEquals("v", caches[2].get(fqn, "k"));
  +   }
  +
  +   public void testAnycastReplication() throws Exception
  +   {
  +      assertNull(caches[0].get(fqn));
  +      assertNull(caches[1].get(fqn));
  +      assertNull(caches[2].get(fqn));
  +
  +      caches[0].setForceAnycast(true);
  +      caches[0].put(fqn, "k", "v");
  +
  +      assertEquals("v", caches[0].get(fqn, "k"));
  +      assertEquals("v", caches[1].get(fqn, "k"));
  +      assertEquals("v", caches[2].get(fqn, "k"));
  +   }
  +
  +}
  
  
  


From msurtani at jboss.com  Fri Dec  8 07:35:35 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 07:35:35 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1Gsewx-00028e-RV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 07:35:35

  Modified:    tests/functional/org/jboss/cache/replicated  Tag:
                        Branch_JBossCache_1_4_0 AnycastTest.java
  Log:
  Anycast should use reflection
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +9 -18     JBossCache/tests/functional/org/jboss/cache/replicated/Attic/AnycastTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AnycastTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/Attic/AnycastTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- AnycastTest.java	8 Dec 2006 12:17:58 -0000	1.1.2.1
  +++ AnycastTest.java	8 Dec 2006 12:35:35 -0000	1.1.2.2
  @@ -8,15 +8,14 @@
   
   public class AnycastTest extends TestCase
   {
  +   int numCaches = 5;
      TreeCache[] caches;
      Fqn fqn = Fqn.fromString("/test");
   
      protected void setUp() throws Exception
      {
  -      caches = new TreeCache[3];
  -      caches[0] = createCache();
  -      caches[1] = createCache();
  -      caches[2] = createCache();
  +      caches = new TreeCache[numCaches];
  +      for (int i=0; i<caches.length; i++) caches[i] = createCache();
   
         TestingUtil.blockUntilViewsReceived(caches, 10000);
      }
  @@ -40,29 +39,21 @@
   
      public void testMCastReplication() throws Exception
      {
  -      assertNull(caches[0].get(fqn));
  -      assertNull(caches[1].get(fqn));
  -      assertNull(caches[2].get(fqn));
  +      for (int i=0; i<caches.length; i++) assertNull(caches[i].get(fqn));
         
         caches[0].put(fqn, "k", "v");
   
  -      assertEquals("v", caches[0].get(fqn, "k"));
  -      assertEquals("v", caches[1].get(fqn, "k"));
  -      assertEquals("v", caches[2].get(fqn, "k"));
  +      for (int i=0; i<caches.length; i++)  assertEquals("v", caches[i].get(fqn, "k"));
      }
   
      public void testAnycastReplication() throws Exception
      {
  -      assertNull(caches[0].get(fqn));
  -      assertNull(caches[1].get(fqn));
  -      assertNull(caches[2].get(fqn));
  +      for (int i=0; i<caches.length; i++) assertNull(caches[i].get(fqn));
   
         caches[0].setForceAnycast(true);
         caches[0].put(fqn, "k", "v");
   
  -      assertEquals("v", caches[0].get(fqn, "k"));
  -      assertEquals("v", caches[1].get(fqn, "k"));
  -      assertEquals("v", caches[2].get(fqn, "k"));
  +      for (int i=0; i<caches.length; i++)  assertEquals("v", caches[i].get(fqn, "k"));
      }
   
   }
  
  
  


From msurtani at jboss.com  Fri Dec  8 07:35:36 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 07:35:36 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gsewy-00028q-4F@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 07:35:36

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Anycast should use reflection
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.31 +14 -5     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.30
  retrieving revision 1.195.2.31
  diff -u -b -r1.195.2.30 -r1.195.2.31
  --- TreeCache.java	8 Dec 2006 12:17:58 -0000	1.195.2.30
  +++ TreeCache.java	8 Dec 2006 12:35:35 -0000	1.195.2.31
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.30 2006/12/08 12:17:58 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.31 2006/12/08 12:35:35 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -4324,10 +4324,8 @@
         if (log.isTraceEnabled())
            log.trace("callRemoteMethods(): valid members are " + validMembers + " method: " + method_call);
   
  -
  -      // if we are using buddy replication, all calls should use ANYCAST.  Otherwise, use the default (multicast).
  -      rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
  -
  +      // if we are using buddy replication, all calls should use ANYCAST.  Otherwise, use the default (multicast).  Unless anycast is forced
  +      rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
   
         // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
         // JGroups supports http://jira.jboss.com/jira/browse/JGRP-193
  @@ -4366,6 +4364,17 @@
         return retval;
      }
   
  +   private RspList callRemoteMethodsViaReflection(Vector validMembers, MethodCall method_call, int mode, long timeout, boolean anycast) throws Exception
  +   {
  +      if (anycast && org.jgroups.Version.version >= 241)
  +      {
  +         // now consider using reflection since we need JGroups >= 2.4.1 for this.
  +         Method m = disp.getClass().getMethod("callRemoteMethods", new Class[]{Vector.class, MethodCall.class, int.class, long.class, boolean.class});
  +         return (RspList) m.invoke(disp, new Object[]{validMembers, method_call, new Integer(mode), new Long(timeout), Boolean.valueOf(anycast)});
  +      }
  +      else return disp.callRemoteMethods(validMembers, method_call, mode, timeout);
  +   }
  +
      /**
       * @param members
       * @param method
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 07:44:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 07:44:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1726 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
Message-ID: <E1Gsf62-0002FR-JP@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-08 07:44:52 -0500 (Fri, 08 Dec 2006)
New Revision: 1726

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Log:
tweaks



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-08 12:15:43 UTC (rev 1725)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-08 12:44:52 UTC (rev 1726)
@@ -25,7 +25,9 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+
 import javax.jms.JMSException;
+
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
@@ -437,6 +439,9 @@
       {
          try
          {
+            log.info("handleConnectionException: ", throwable);
+            
+            
             log.info("Caught connection exception for connection: " + connection);
             
             handleFailure(connection);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 12:15:43 UTC (rev 1725)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 12:44:52 UTC (rev 1726)
@@ -70,7 +70,7 @@
    {
       try
       {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
          ClusteredClientConnectionFactoryDelegate delegate =
                       (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
          log.info ("number of delegates = " + delegate.getDelegates().length);
@@ -99,7 +99,7 @@
 
          ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
 
-         factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
          delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 
          assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
@@ -121,14 +121,14 @@
          log.info("++testTopicSubscriber");
 
 
-         JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf1;
+         JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf;
          assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
 
          log.info(">>Lookup Queue");
-         Destination destination = (Destination) ic1.lookup("topic/testDistributedTopic");
+         Destination destination = (Destination) ic2.lookup("topic/testDistributedTopic");
 
          log.info("Creating connection server1");
-         JBossConnection conn = (JBossConnection) cf1.createConnection();
+         JBossConnection conn = (JBossConnection) cf.createConnection();
          conn.setClientID("testClient");
          conn.start();
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 12:15:43 UTC (rev 1725)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 12:44:52 UTC (rev 1726)
@@ -138,32 +138,7 @@
    {
       super.tearDown();
    }
-   
-   private void checkConnectionsDifferentServers(Connection conn, Connection conn1, Connection conn2)
-   {
-      ConnectionState state = (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
-      
-      ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-      
-      ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-      
-      int serverID = state.getServerID();
-      
-      int serverID1 = state1.getServerID();
-      
-      int serverID2 = state2.getServerID();
-      
-      log.info("Server id:" + serverID);
-      
-      log.info("Server id1:" + serverID1);
-      
-      log.info("Server id2:" + serverID2);
-      
-      
-      assertTrue(serverID != serverID1);
-      
-      assertTrue(serverID1 != serverID2);
-   }
+  
 
    /*
     * Create a consumer on each queue on each node.
@@ -172,41 +147,41 @@
     */
    protected void clusteredQueueLocalConsumer(boolean persistent) throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
 
       try
       {
          //This will create 3 different connection on 3 different nodes, since
          //the cf is clustered
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn, conn1, conn2);
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
          log.info("Created sessions");
 
-         MessageConsumer cons = sess.createConsumer(queue);
          MessageConsumer cons1 = sess1.createConsumer(queue1);
          MessageConsumer cons2 = sess2.createConsumer(queue2);
+         MessageConsumer cons3 = sess3.createConsumer(queue3);
          
          log.info("Created consumers");
 
-         conn.start();
          conn1.start();
          conn2.start();
+         conn3.start();
 
          // Send at node 0
 
-         MessageProducer prod = sess.createProducer(queue);
+         MessageProducer prod = sess1.createProducer(queue1);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -214,7 +189,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess.createTextMessage("message" + i);
+            TextMessage tm = sess1.createTextMessage("message" + i);
 
             prod.send(tm);
          }
@@ -223,90 +198,83 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
             
-            log.info("1 GOT MESSAGE: " + tm.getText());
-            
             assertEquals("message" + i, tm.getText());
          }                 
 
-         Message m = cons1.receive(2000);
+         Message m = cons2.receive(2000);
 
          assertNull(m);
 
-         m = cons2.receive(2000);
+         m = cons3.receive(2000);
 
          assertNull(m);
 
          // Send at node 1
 
-         MessageProducer prod1 = sess1.createProducer(queue1);
+         MessageProducer prod1 = sess2.createProducer(queue2);
 
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess2.createTextMessage("message" + i);
 
             prod1.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons.receive(2000);
+         m = cons1.receive(2000);
 
          assertNull(m);
 
-         m = cons2.receive(2000);
+         m = cons3.receive(2000);
 
          assertNull(m);
 
          // Send at node 2
 
-         MessageProducer prod2 = sess2.createProducer(queue2);
+         MessageProducer prod2 = sess3.createProducer(queue3);
 
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess2.createTextMessage("message" + i);
+            TextMessage tm = sess3.createTextMessage("message" + i);
 
             prod2.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons.receive(2000);
+         m = cons1.receive(2000);
 
          assertNull(m);
 
-         m = cons1.receive(2000);
+         m = cons2.receive(2000);
 
          assertNull(m);
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -316,6 +284,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 
@@ -327,40 +300,40 @@
     */
    private void clusteredTopicNonDurable(boolean persistent) throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
       try
       {
          //This will create 3 different connection on 3 different nodes, since
          //the cf is clustered
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn, conn1, conn2);
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons = sess.createConsumer(topic);
          MessageConsumer cons1 = sess1.createConsumer(topic1);
          MessageConsumer cons2 = sess2.createConsumer(topic2);
+         MessageConsumer cons3 = sess3.createConsumer(topic3);
 
-         MessageConsumer cons3 = sess.createConsumer(topic);
-
          MessageConsumer cons4 = sess1.createConsumer(topic1);
 
-         conn.start();
+         MessageConsumer cons5 = sess2.createConsumer(topic2);
+
          conn1.start();
          conn2.start();
+         conn3.start();
 
          // Send at node 0
 
-         MessageProducer prod = sess.createProducer(topic);
+         MessageProducer prod = sess1.createProducer(topic1);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -368,14 +341,14 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess.createTextMessage("message" + i);
+            TextMessage tm = sess1.createTextMessage("message" + i);
 
             prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -384,7 +357,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
@@ -393,7 +366,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
@@ -402,7 +375,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons4.receive(1000);
 
             assertNotNull(tm);
 
@@ -411,7 +384,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
+            TextMessage tm = (TextMessage)cons5.receive(1000);
 
             assertNotNull(tm);
 
@@ -420,11 +393,6 @@
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -434,6 +402,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 
@@ -444,41 +417,41 @@
     */
    private void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
 
       try
       {
          //This will create 3 different connection on 3 different nodes, since
          //the cf is clustered
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn, conn1, conn2);
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons = sess.createConsumer(topic);
          MessageConsumer cons1 = sess1.createConsumer(topic1);
          MessageConsumer cons2 = sess2.createConsumer(topic2);
+         MessageConsumer cons3 = sess3.createConsumer(topic3);
 
-         MessageConsumer cons3 = sess.createConsumer(topic, "COLOUR='red'");
+         MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='red'");
 
-         MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='blue'");
+         MessageConsumer cons5 = sess2.createConsumer(topic2, "COLOUR='blue'");
 
-         conn.start();
          conn1.start();
          conn2.start();
+         conn3.start();
 
          // Send at node 0
 
-         MessageProducer prod = sess.createProducer(topic);
+         MessageProducer prod = sess1.createProducer(topic1);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -486,7 +459,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess.createTextMessage("message" + i);
+            TextMessage tm = sess1.createTextMessage("message" + i);
 
             int c = i % 3;
             if (c == 0)
@@ -503,7 +476,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -512,7 +485,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
@@ -521,7 +494,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
@@ -534,7 +507,7 @@
 
             if (c == 0)
             {
-               TextMessage tm = (TextMessage)cons3.receive(1000);
+               TextMessage tm = (TextMessage)cons4.receive(1000);
 
                assertNotNull(tm);
 
@@ -548,7 +521,7 @@
 
             if (c == 1)
             {
-               TextMessage tm = (TextMessage)cons4.receive(1000);
+               TextMessage tm = (TextMessage)cons5.receive(1000);
 
                assertNotNull(tm);
 
@@ -558,11 +531,6 @@
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -572,6 +540,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 
@@ -585,68 +558,68 @@
     */
    private void clusteredTopicDurable(boolean persistent) throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
       try
       {
          //This will create 3 different connection on 3 different nodes, since
          //the cf is clustered
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn, conn1, conn2);
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
 
-         conn.setClientID("wib1");
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
+         conn3.setClientID("wib1");
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
          try
          {
-            sess.unsubscribe("sub");
+            sess1.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess1.unsubscribe("sub1");
+            sess2.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub2");
+            sess3.unsubscribe("sub2");
          }
          catch (Exception ignore) {}
          try
          {
-            sess.unsubscribe("sub3");
+            sess1.unsubscribe("sub3");
          }
          catch (Exception ignore) {}
          try
          {
-            sess1.unsubscribe("sub4");
+            sess2.unsubscribe("sub4");
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons = sess.createDurableSubscriber(topic, "sub");
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub2");
-         MessageConsumer cons3 = sess.createDurableSubscriber(topic, "sub3");
-         MessageConsumer cons4 = sess1.createDurableSubscriber(topic1, "sub4");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub2");
+         MessageConsumer cons4 = sess1.createDurableSubscriber(topic1, "sub3");
+         MessageConsumer cons5 = sess2.createDurableSubscriber(topic2, "sub4");
 
-         conn.start();
          conn1.start();
          conn2.start();
+         conn3.start();
 
          // Send at node 0
 
-         MessageProducer prod = sess.createProducer(topic);
+         MessageProducer prod = sess1.createProducer(topic1);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -654,14 +627,14 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
+            TextMessage tm = sess2.createTextMessage("message" + i);
 
             prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
@@ -670,7 +643,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
@@ -679,7 +652,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
@@ -688,7 +661,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
+            TextMessage tm = (TextMessage)cons4.receive(1000);
 
             assertNotNull(tm);
 
@@ -697,33 +670,28 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
+            TextMessage tm = (TextMessage)cons5.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         cons.close();
          cons1.close();
          cons2.close();
          cons3.close();
          cons4.close();
+         cons5.close();
 
-         sess.unsubscribe("sub");
-         sess1.unsubscribe("sub1");
-         sess2.unsubscribe("sub2");
-         sess.unsubscribe("sub3");
-         sess1.unsubscribe("sub4");
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub1");
+         sess3.unsubscribe("sub2");
+         sess1.unsubscribe("sub3");
+         sess2.unsubscribe("sub4");
 
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -733,6 +701,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 
@@ -744,56 +717,56 @@
     */
    protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
       try
 
       {
          //This will create 3 different connection on 3 different nodes, since
          //the cf is clustered
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn, conn1, conn2);
-         conn.setClientID("wib1");
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
+         conn3.setClientID("wib1");
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
          try
          {
-            sess.unsubscribe("sub");
+            sess1.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess1.unsubscribe("sub");
+            sess2.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub");
+            sess3.unsubscribe("sub");
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons = sess.createDurableSubscriber(topic, "sub");
          MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
          MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub");
 
-         conn.start();
          conn1.start();
          conn2.start();
+         conn3.start();
 
          // Send at node 0
 
-         MessageProducer prod = sess.createProducer(topic);
+         MessageProducer prod = sess1.createProducer(topic1);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -801,105 +774,100 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess.createTextMessage("message" + i);
+            TextMessage tm = sess1.createTextMessage("message" + i);
 
             prod.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            TextMessage tm = (TextMessage)cons1.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         Message m = cons1.receive(2000);
+         Message m = cons2.receive(2000);
 
          assertNull(m);
 
-         m = cons2.receive(2000);
+         m = cons3.receive(2000);
 
          assertNull(m);
 
          // Send at node 1
 
-         MessageProducer prod1 = sess1.createProducer(topic1);
+         MessageProducer prod1 = sess2.createProducer(topic2);
 
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess2.createTextMessage("message" + i);
+            TextMessage tm = sess3.createTextMessage("message" + i);
 
             prod1.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
+            TextMessage tm = (TextMessage)cons2.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons.receive(2000);
+         m = cons1.receive(2000);
 
          assertNull(m);
 
-         m = cons2.receive(2000);
+         m = cons3.receive(2000);
 
          assertNull(m);
 
          // Send at node 2
 
-         MessageProducer prod2 = sess2.createProducer(topic2);
+         MessageProducer prod2 = sess3.createProducer(topic3);
 
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess2.createTextMessage("message" + i);
+            TextMessage tm = sess3.createTextMessage("message" + i);
 
             prod2.send(tm);
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
+            TextMessage tm = (TextMessage)cons3.receive(1000);
 
             assertNotNull(tm);
 
             assertEquals("message" + i, tm.getText());
          }
 
-         m = cons.receive(2000);
+         m = cons1.receive(2000);
 
          assertNull(m);
 
-         m = cons1.receive(2000);
+         m = cons2.receive(2000);
 
          assertNull(m);
 
-         cons.close();
          cons1.close();
          cons2.close();
+         cons3.close();
 
          // Need to unsubscribe on any node that the durable sub was created on
 
-         sess.unsubscribe("sub");
          sess1.unsubscribe("sub");
          sess2.unsubscribe("sub");
+         sess3.unsubscribe("sub");
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -909,6 +877,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 
@@ -921,51 +894,51 @@
     */
    protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
 
       try
       {
          //This will create 3 different connection on 3 different nodes, since
          //the cf is clustered
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn, conn1, conn2);
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
          
-         conn1.setClientID("wib1");
          conn2.setClientID("wib1");
+         conn3.setClientID("wib1");
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
          try
          {
-            sess1.unsubscribe("sub");
+            sess2.unsubscribe("sub");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub");
+            sess3.unsubscribe("sub");
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub");
+         MessageConsumer cons1 = sess2.createDurableSubscriber(topic2, "sub");
+         MessageConsumer cons2 = sess3.createDurableSubscriber(topic3, "sub");
 
-         conn1.start();
          conn2.start();
+         conn3.start();
 
          // Send at node 0
 
          //Should round robin between the other 2 since there is no active consumer on sub  on node 0
 
-         MessageProducer prod = sess.createProducer(topic);
+         MessageProducer prod = sess1.createProducer(topic1);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -973,7 +946,7 @@
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess.createTextMessage("message" + i);
+            TextMessage tm = sess1.createTextMessage("message" + i);
 
             prod.send(tm);
          }
@@ -999,17 +972,12 @@
          cons1.close();
          cons2.close();
 
-         sess1.unsubscribe("sub");
          sess2.unsubscribe("sub");
+         sess3.unsubscribe("sub");
 
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -1019,6 +987,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 12:15:43 UTC (rev 1725)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 12:44:52 UTC (rev 1726)
@@ -59,15 +59,15 @@
          SimpleMessageListener ml1 = new SimpleMessageListener();
          SimpleMessageListener ml2 = new SimpleMessageListener();
 
-         s.createConsumer(topic).setMessageListener(ml);
-         s1.createConsumer(topic).setMessageListener(ml1);
-         s2.createConsumer(topic).setMessageListener(ml2);
+         s.createConsumer(topic1).setMessageListener(ml);
+         s1.createConsumer(topic1).setMessageListener(ml1);
+         s2.createConsumer(topic1).setMessageListener(ml2);
 
          conn.start();
          conn1.start();
          conn2.start();
 
-         s.createProducer(topic).send(s.createTextMessage("boom"));
+         s.createProducer(topic1).send(s.createTextMessage("boom"));
 
          TextMessage rm = null;
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 12:15:43 UTC (rev 1725)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 12:44:52 UTC (rev 1726)
@@ -31,6 +31,10 @@
 import javax.jms.Topic;
 import javax.naming.Context;
 import javax.naming.InitialContext;
+
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
@@ -48,21 +52,21 @@
 
    // Attributes ----------------------------------------------------
 
-   protected Context ic;
    protected Context ic1;
    protected Context ic2;
+   protected Context ic3;
 
-   protected Queue queue;
    protected Queue queue1;
    protected Queue queue2;
+   protected Queue queue3;
 
-   protected Topic topic;
    protected Topic topic1;
    protected Topic topic2;
+   protected Topic topic3;
 
+   //No need to have 3 conncetion factories since a clustered connection factory
+   //will create connections in a round robin fashion on different servers
    protected ConnectionFactory cf;
-  // protected ConnectionFactory cf1;
-  // protected ConnectionFactory cf2;
 
    // Constructors --------------------------------------------------
 
@@ -95,21 +99,21 @@
 
          log.info("Deployed destinations ok");
 
-         ic = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
 
          //We only need to lookup one connection factory since it will be a clustered cf
          //so we will actually create connections on different servers (round robin)
-         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+         cf = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
                   
-         queue = (Queue)ic.lookup("queue/testDistributedQueue");
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
+         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
 
-         topic = (Topic)ic.lookup("topic/testDistributedTopic");
          topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
          topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
+         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
 
          drainQueues();
       }
@@ -136,9 +140,9 @@
          ServerManagement.undeployQueue("testDistributedQueue", 2);
          ServerManagement.undeployTopic("testDistributedTopic", 2);
 
-         ic.close();
          ic1.close();
          ic2.close();
+         ic3.close();
 
          super.tearDown();
       }
@@ -148,63 +152,86 @@
          throw e;
       }
    }
+   
+   protected void checkConnectionsDifferentServers(Connection conn, Connection conn1, Connection conn2)
+   {
+      ConnectionState state = (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
+      
+      ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+      
+      ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+      
+      int serverID = state.getServerID();
+      
+      int serverID1 = state1.getServerID();
+      
+      int serverID2 = state2.getServerID();
+      
+      log.info("Server id:" + serverID);
+      
+      log.info("Server id1:" + serverID1);
+      
+      log.info("Server id2:" + serverID2);
+      
+      
+      assertTrue(serverID != serverID1);
+      
+      assertTrue(serverID1 != serverID2);
+   }
 
    protected void drainQueues() throws Exception
    {
-      Connection conn = null;
       Connection conn1 = null;
       Connection conn2 = null;
+      Connection conn3 = null;
 
       try
       {
          //Since the cf is clustered, this will create connections on 3 different nodes
          //(round robin)
-         conn = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
 
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons = sess.createConsumer(queue);
          MessageConsumer cons1 = sess1.createConsumer(queue1);
          MessageConsumer cons2 = sess2.createConsumer(queue2);
+         MessageConsumer cons3 = sess3.createConsumer(queue3);
 
-         conn.start();
          conn1.start();
          conn2.start();
+         conn3.start();
 
          Message msg = null;
 
          do
          {
-            msg = cons.receive(1000);
+            msg = cons1.receive(1000);
             log.info("1 Drained message " + msg);
          }
          while (msg != null);
 
          do
          {
-            msg = cons1.receive(1000);
+            msg = cons2.receive(1000);
             log.info("2 Drained message " + msg);
          }
          while (msg != null);
 
          do
          {
-            msg = cons2.receive(1000);
+            msg = cons3.receive(1000);
             log.info("3 Drained message " + msg);
          }
          while (msg != null);
       }
       finally
       {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
          if (conn1 != null)
          {
             conn1.close();
@@ -214,6 +241,11 @@
          {
             conn2.close();
          }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 



From msurtani at jboss.com  Fri Dec  8 08:10:42 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 08:10:42 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1GsfUw-0002pn-10@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 08:10:42

  Modified:    tests/functional/org/jboss/cache/replicated  Tag:
                        Branch_JBossCache_1_4_0 SyncReplTxTest.java
  Log:
  Fixed broken test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.9.2.3   +59 -14    JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java,v
  retrieving revision 1.9.2.2
  retrieving revision 1.9.2.3
  diff -u -b -r1.9.2.2 -r1.9.2.3
  --- SyncReplTxTest.java	4 Nov 2006 04:29:58 -0000	1.9.2.2
  +++ SyncReplTxTest.java	8 Dec 2006 13:10:41 -0000	1.9.2.3
  @@ -18,19 +18,27 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.TreeCacheMBean;
  -import org.jboss.cache.aop.AOPInstance;
   import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.TimeoutException;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
  -import javax.transaction.*;
  +import javax.transaction.NotSupportedException;
  +import javax.transaction.RollbackException;
  +import javax.transaction.Status;
  +import javax.transaction.Synchronization;
  +import javax.transaction.SystemException;
  +import javax.transaction.Transaction;
  +import javax.transaction.TransactionManager;
  +import java.util.List;
  +import java.util.ArrayList;
   
   /**
    * Replicated unit test for sync transactional TreeCache
    * Note: we use DummyTransactionManager for Tx purpose instead of relying on
    * jta.
    *
  - * @version $Revision: 1.9.2.2 $
  + * @version $Revision: 1.9.2.3 $
    */
   public class SyncReplTxTest extends TestCase {
       private static Log log = LogFactory.getLog(SyncReplTxTest.class);
  @@ -158,7 +166,7 @@
         cache1.releaseAllLocks("/");
         Transaction tx=beginTransaction();
         cache1.put("/bela/ban", "name", "Bela Ban");
  -      assertEquals(2, cache1.getNumberOfLocksHeld());
  +      assertEquals(3, cache1.getNumberOfLocksHeld());
         assertEquals(0, cache2.getNumberOfLocksHeld());
         tx.commit();
         assertEquals(0, cache1.getNumberOfLocksHeld());
  @@ -259,15 +267,19 @@
       }
    }
   
  +
        public void testSyncReplWithModficationsOnBothCaches() throws Exception {
           Integer age;
           Transaction tx;
           final Fqn NODE1=Fqn.fromString("/one/two/three");
           final Fqn NODE2=Fqn.fromString("/eins/zwei/drei");
   
  -      try {
            initCaches(TreeCache.REPL_SYNC);
   
  +         // create roots first
  +        cache1.put("/one/two", null);
  +        cache2.put("/eins/zwei", null);
  +
            cache1.setSyncCommitPhase(true);
            cache2.setSyncCommitPhase(true);
   
  @@ -281,11 +293,20 @@
            System.out.println("cache1 before commit:\n" + cache1.printLockInfo());
            System.out.println("cache2 before commit:\n" + cache2.printLockInfo());
   
  +        try
  +        {
            tx.commit();
  +           fail("Should not succeed with SERIALIZABLE semantics");
  +        }
  +        catch (Exception e)
  +        {
  +           //should be a classic deadlock here.
  +        }
   
            System.out.println("cache1 after commit:\n" + cache1.printLockInfo());
            System.out.println("cache2 after commit:\n" + cache2.printLockInfo());
   
  +        /*
            assertTrue(cache1.exists(NODE1));
            assertTrue(cache1.exists(NODE2));
            assertTrue(cache1.exists(NODE1));
  @@ -306,16 +327,13 @@
            age=(Integer)cache2.get(NODE2, "age");
            assertNotNull("\"age\" obtained from cache2 for " + NODE2 + " must be non-null ", age);
            assertTrue("\"age\" must be 39", age.intValue() == 39);
  +         */
   
            assertEquals(0, cache1.getNumberOfLocksHeld());
            assertEquals(0, cache2.getNumberOfLocksHeld());
            System.out.println("TransactionTable for cache1:\n" + cache1.getTransactionTable().toString(true));
            System.out.println("TransactionTable for cache2:\n" + cache2.getTransactionTable().toString(true));
         }
  -      catch(Exception e) {
  -         fail(e.toString());
  -      }
  -   }
   
      public void testSyncReplWithModficationsOnBothCachesSameData() throws Exception {
         Transaction tx;
  @@ -323,6 +341,13 @@
   
         try {
            initCaches(TreeCache.REPL_SYNC);
  +
  +         // sync commit + rollback?
  +         cache1.setSyncCommitPhase(true);
  +         cache1.setSyncRollbackPhase(true);
  +         cache2.setSyncCommitPhase(true);
  +         cache2.setSyncRollbackPhase(true);
  +
            tx=beginTransaction();
            cache1.put(NODE, "age", new Integer(38));
            System.out.println("TransactionTable for cache1 after cache1.put():\n" + cache1.getTransactionTable().toString(true));
  @@ -757,6 +782,8 @@
         c2.setCacheMode(TreeCache.REPL_SYNC);
         c1.setSyncCommitPhase(true);
         c2.setSyncCommitPhase(true);
  +      c1.setSyncRollbackPhase(true);
  +      c2.setSyncRollbackPhase(true);
         c1.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         c2.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         c1.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -765,6 +792,7 @@
         c2.setLockAcquisitionTimeout(5000);
         c1.start();
         c2.start();
  +      final List exceptions = new ArrayList();
   
         class MyThread extends Thread {
            Object mutex;
  @@ -775,7 +803,7 @@
            }
   
            public void run() {
  -            Transaction tx;
  +            Transaction tx = null;
   
               try {
                  tx=beginTransaction();
  @@ -790,7 +818,17 @@
                  System.out.println("Thread " + getName() + " committed successfully");
               }
               catch(Exception e) {
  -               ex=e;
  +               exceptions.add(e);
  +            }
  +            finally {
  +               try
  +               {
  +                  if (tx != null) tx.rollback();
  +               }
  +               catch (Exception e)
  +               {
  +
  +               }
               }
            }
         }
  @@ -831,8 +869,15 @@
         c1.stop();
         c2.stop();
   
  -      if(ex != null)
  -         fail("Thread failed: " + ex);
  +//      if(ex != null)
  +//      {
  +//         ex.printStackTrace();
  +//         fail("Thread failed: " + ex);
  +//      }
  +
  +      // we can only expect 1 thread to succeed.  The others will fail.  So, threads.length -1 exceptions.
  +      assertEquals(threads.length - 1, exceptions.size());
  +      for (int i=0; i<exceptions.size(); i++) assertEquals(TimeoutException.class, exceptions.get(i).getClass());
      }
   
   
  
  
  


From msurtani at jboss.com  Fri Dec  8 08:18:15 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 08 Dec 2006 08:18:15 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GsfcF-0002wK-Tq@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/08 08:18:15

  Modified:    tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_4_0 SuspendTxTest.java
  Log:
  Fixed broken test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +6 -2      JBossCache/tests/functional/org/jboss/cache/transaction/SuspendTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuspendTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/SuspendTxTest.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- SuspendTxTest.java	11 Oct 2006 13:49:25 -0000	1.1.2.2
  +++ SuspendTxTest.java	8 Dec 2006 13:18:15 -0000	1.1.2.3
  @@ -3,10 +3,9 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.Fqn;
  +import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Option;
  -import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  @@ -46,6 +45,11 @@
       * from the transaction.
       */
      public void testSuspendedLocks() throws Exception {
  +
  +      // create /one first
  +      cache.put("/one", null);
  +      cache.put("/a", null);
  +
         mgr.begin();
   	   
         cache.put("/one/two", "key1", "val1");
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 08:22:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 08:22:21 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1727 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GsfgD-00030e-D7@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-08 08:22:15 -0500 (Fri, 08 Dec 2006)
New Revision: 1727

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
A couple of HA tests



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 12:44:52 UTC (rev 1726)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 13:22:15 UTC (rev 1727)
@@ -710,7 +710,7 @@
          
          if (m == null)
          {
-            m = new HashMap();
+            m = new LinkedHashMap();
             
             replicatedData.put(key, m);
          }

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 12:44:52 UTC (rev 1726)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 13:22:15 UTC (rev 1727)
@@ -715,10 +715,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/ManualClusteringTest.class"/>
-               <!--
-               <include name="**/jms/clustering/SimpleClusteringTest.class"/>
-               -->
+               <include name="**/jms/clustering/*Test.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 12:44:52 UTC (rev 1726)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 13:22:15 UTC (rev 1727)
@@ -22,31 +22,30 @@
 
 package org.jboss.test.messaging.jms.clustering;
 
-import javax.jms.Destination;
-import javax.jms.Message;
+import javax.jms.Connection;
 import javax.jms.MessageConsumer;
-import javax.jms.MessageProducer;
-import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.jms.Topic;
+
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
-import org.jboss.jms.client.JBossMessageConsumer;
-import org.jboss.jms.client.JBossSession;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
+import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.state.ConsumerState;
-import org.jboss.jms.client.state.SessionState;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageProxy;
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 
 /**
+ * 
+ * A HATest
+ *
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
  *
- * $Id:$
+ * $Id$
+ *
  */
 public class HATest extends ClusteringTestBase
 {
@@ -65,146 +64,299 @@
    }
 
    // Public --------------------------------------------------------
-
-   public void testConnectionFactoryConnect() throws Exception
+   
+   /*
+    * Test that connections created using a clustered connection factory are created round robin on
+    * different servers
+    */
+   public void testRoundRobinConnectionCreation() throws Exception
    {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+       (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      log.info ("number of delegates = " + delegate.getDelegates().length);
+      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      assertEquals(3, delegate.getDelegates().length);
+      
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
+      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      Connection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      Connection conn4 = null;
+      
+      Connection conn5 = null;
+      
       try
+      {         
+         conn1 = factory.createConnection();
+         
+         conn2 = factory.createConnection();
+         
+         conn3 = factory.createConnection();
+         
+         conn4 = factory.createConnection();
+         
+         conn5 = factory.createConnection();
+         
+         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+         
+         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+         
+         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+         
+         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+         
+         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+         
+         int serverID1 = state1.getServerID();
+         
+         int serverID2 = state2.getServerID();
+        
+         int serverID3 = state3.getServerID();
+         
+         int serverID4 = state4.getServerID();
+         
+         int serverID5 = state5.getServerID();
+         
+         log.info("server id 1: " + serverID1);
+         
+         log.info("server id 2: " + serverID2);
+         
+         log.info("server id 3: " + serverID3);
+         
+         log.info("server id 4: " + serverID4);
+         
+         log.info("server id 5: " + serverID5);
+         
+         assertEquals(0, serverID1);
+         
+         assertEquals(1, serverID2);
+         
+         assertEquals(2, serverID3);
+         
+         assertEquals(0, serverID4);
+         
+         assertEquals(1, serverID5);
+      }
+      finally
       {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         ClusteredClientConnectionFactoryDelegate delegate =
-                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         log.info ("number of delegates = " + delegate.getDelegates().length);
-         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-
-         delegate.init();
-
-         for (int i = 0; i < 3; i++)
+         if (conn1 != null)
          {
-            int failNode = delegate.getDelegates()[0].getFailoverNode(i);
-            log.info("Failover node for server" + i + " = " + failNode);
-            log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
-
-            assertEquals("Server1 should have the same failoverMapping",
-                         failNode, delegate.getDelegates()[1].getFailoverNode(i));
-            assertEquals("Server2 should have the same failoverMapping",
-                         failNode, delegate.getDelegates()[2].getFailoverNode(i));
+            conn1.close();
          }
-
-         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         assertEquals(3, delegate.getDelegates().length);
-
-
-         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
-         ServerManagement.stop(2,true);
-
-         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
-
-         factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         assertEquals(2, delegate.getDelegates().length);
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+         
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+         
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
       }
-      finally
-      {
-         ServerManagement.start("all", 2);
-      }
-
-
+      
    }
-
-
-   public void testTopicSubscriber() throws Exception
+   
+   /*
+    * Test that the failover mapping is created correctly
+    */
+   public void testDefaultFailoverMap() throws Exception
    {
-      try
-      {
-         log.info("++testTopicSubscriber");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+       (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 
+      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      int[] failoverIndexes = delegate.getFailoverIndexes();
+      
+      assertEquals(3, delegates.length);
+      
+      assertEquals(3, failoverIndexes.length);
+      
+      // Default failover policy just chooses the node to the right
+      
+      assertEquals(1, failoverIndexes[0]);
+      
+      assertEquals(2, failoverIndexes[1]);
+      
+      assertEquals(0, failoverIndexes[2]);
+      
+   }
+   
 
-         JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf;
-         assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
+//   public void testConnectionFactoryConnect() throws Exception
+//   {
+//      try
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         log.info ("number of delegates = " + delegate.getDelegates().length);
+//         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//
+//         delegate.init();
+//
+//         for (int i = 0; i < 3; i++)
+//         {
+//            int failNode = delegate.getDelegates()[0].getFailoverNode(i);
+//            log.info("Failover node for server" + i + " = " + failNode);
+//            log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
+//
+//            assertEquals("Server1 should have the same failoverMapping",
+//                         failNode, delegate.getDelegates()[1].getFailoverNode(i));
+//            assertEquals("Server2 should have the same failoverMapping",
+//                         failNode, delegate.getDelegates()[2].getFailoverNode(i));
+//         }
+//
+//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         assertEquals(3, delegate.getDelegates().length);
+//
+//
+//         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
+//         ServerManagement.stop(2,true);
+//
+//         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
+//
+//         factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         assertEquals(2, delegate.getDelegates().length);
+//      }
+//      finally
+//      {
+//         ServerManagement.start("all", 2);
+//      }
+//
+//
+//   }
 
-         log.info(">>Lookup Queue");
-         Destination destination = (Destination) ic2.lookup("topic/testDistributedTopic");
 
-         log.info("Creating connection server1");
-         JBossConnection conn = (JBossConnection) cf.createConnection();
-         conn.setClientID("testClient");
-         conn.start();
+//   public void testTopicSubscriber() throws Exception
+//   {
+//      try
+//      {
+//         log.info("++testTopicSubscriber");
+//
+//
+//         JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf;
+//         assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
+//
+//         log.info(">>Lookup Queue");
+//         Destination destination = (Destination) ic2.lookup("topic/testDistributedTopic");
+//
+//         log.info("Creating connection server1");
+//         JBossConnection conn = (JBossConnection) cf.createConnection();
+//         conn.setClientID("testClient");
+//         conn.start();
+//
+//         JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+//         ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
+//         SessionState sessionState = (SessionState) clientSessionDelegate.getState();
+//
+//         MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
+//         JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
+//
+//         org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
+//         ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
+//
+//         log.info("subscriptionName=" + consumerState.getSubscriptionName());
+//
+//
+//         log.info(">>Creating Producer");
+//         MessageProducer producer = session.createProducer(destination);
+//         log.info(">>creating Message");
+//         Message message = session.createTextMessage("Hello Before");
+//         log.info(">>sending Message");
+//         producer.send(message);
+//         session.commit();
+//
+//         receiveMessage("consumerHA", consumerHA, true, false);
+//
+//         session.commit();
+//         //if (true) return;
+//
+//         Object txID = sessionState.getCurrentTxId();
+//
+//         producer.send(session.createTextMessage("Hello again before failover"));
+//
+//         ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
+//
+//         ServerManagement.stop(0, false);
+//
+//         Thread.sleep(25000);
+//
+//         //System.out.println("Kill server1"); Thread.sleep(10000);
+//
+//         message = session.createTextMessage("Hello After");
+//         log.info(">>Sending new message");
+//         producer.send(message);
+//
+//         assertEquals(txID, sessionState.getCurrentTxId());
+//         System.out.println("TransactionID on client = " + txID);
+//         log.info(">>Final commit");
+//
+//         /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
+//          connSecondServer.start();
+//          JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
+//          MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
+//
+//         session.commit();
+//
+//         /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+//        receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+//        receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
+//
+//         log.info("Calling alternate receiver");
+//         receiveMessage("consumerHA", consumerHA, true, false);
+//         receiveMessage("consumerHA", consumerHA, true, false);
+//         receiveMessage("consumerHA", consumerHA, true, true);
+//
+//
+//         session.commit();
+//
+//      }
+//      finally
+//      {
+//         // restart the server as it was probably stopped (tearDown will need that)
+//         ServerManagement.start("all", 0);
+//      }
+//   }
 
-         JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
-         ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
-         SessionState sessionState = (SessionState) clientSessionDelegate.getState();
-
-         MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
-         JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
-
-         org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
-         ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
-
-         log.info("subscriptionName=" + consumerState.getSubscriptionName());
-
-
-         log.info(">>Creating Producer");
-         MessageProducer producer = session.createProducer(destination);
-         log.info(">>creating Message");
-         Message message = session.createTextMessage("Hello Before");
-         log.info(">>sending Message");
-         producer.send(message);
-         session.commit();
-
-         receiveMessage("consumerHA", consumerHA, true, false);
-
-         session.commit();
-         //if (true) return;
-
-         Object txID = sessionState.getCurrentTxId();
-
-         producer.send(session.createTextMessage("Hello again before failover"));
-
-         ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
-
-         ServerManagement.stop(0, false);
-
-         Thread.sleep(25000);
-
-         //System.out.println("Kill server1"); Thread.sleep(10000);
-
-         message = session.createTextMessage("Hello After");
-         log.info(">>Sending new message");
-         producer.send(message);
-
-         assertEquals(txID, sessionState.getCurrentTxId());
-         System.out.println("TransactionID on client = " + txID);
-         log.info(">>Final commit");
-
-         /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-          connSecondServer.start();
-          JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-          MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
-
-         session.commit();
-
-         /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-        receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-        receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
-
-         log.info("Calling alternate receiver");
-         receiveMessage("consumerHA", consumerHA, true, false);
-         receiveMessage("consumerHA", consumerHA, true, false);
-         receiveMessage("consumerHA", consumerHA, true, true);
-
-
-         session.commit();
-
-      }
-      finally
-      {
-         // restart the server as it was probably stopped (tearDown will need that)
-         ServerManagement.start("all", 0);
-      }
-   }
-
 //
 //   public void testQueueHA() throws Exception
 //   {



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 09:07:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 09:07:09 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1728 - in
	branches/Branch_Client_Failover_Experiment/tests: .
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/jms/clustering/base
	src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GsgNZ-0003r8-TG@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-08 09:07:04 -0500 (Fri, 08 Dec 2006)
New Revision: 1728

Modified:
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
More HA tweaks



Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 13:22:15 UTC (rev 1727)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 14:07:04 UTC (rev 1728)
@@ -715,7 +715,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 13:22:15 UTC (rev 1727)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 14:07:04 UTC (rev 1728)
@@ -1,37 +1,33 @@
 /*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.
-   */
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
 
-import javax.jms.Connection;
 import javax.jms.MessageConsumer;
 import javax.jms.TextMessage;
 
-import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -49,20 +45,20 @@
  */
 public class HATest extends ClusteringTestBase
 {
-
+   
    // Constants -----------------------------------------------------
-
+   
    // Static --------------------------------------------------------
-
+   
    // Attributes ----------------------------------------------------
-
+   
    // Constructors --------------------------------------------------
-
+   
    public HATest(String name)
    {
       super(name);
    }
-
+   
    // Public --------------------------------------------------------
    
    /*
@@ -74,7 +70,7 @@
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
-       (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
       
       log.info ("number of delegates = " + delegate.getDelegates().length);
       log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
@@ -130,7 +126,7 @@
          int serverID1 = state1.getServerID();
          
          int serverID2 = state2.getServerID();
-        
+         
          int serverID3 = state3.getServerID();
          
          int serverID4 = state4.getServerID();
@@ -186,21 +182,33 @@
       }
       
    }
-   
+ 
    /*
     * Test that the failover mapping is created correctly
     */
    public void testDefaultFailoverMap() throws Exception
-   {
+   {     
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
-       (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
       assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
       
       ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
       
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
       int[] failoverIndexes = delegate.getFailoverIndexes();
       
       assertEquals(3, delegates.length);
@@ -215,256 +223,323 @@
       
       assertEquals(0, failoverIndexes[2]);
       
+      //Now cleanly stop one of the servers
+      
+      ServerManagement.stop(0, true);
+      
+      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+      
+      //Lookup another connection factory
+      
+      JBossConnectionFactory factory2 =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate2 =
+         (ClusteredClientConnectionFactoryDelegate)factory2.getDelegate();
+      
+      ClientConnectionFactoryDelegate[] delegates2 = delegate2.getDelegates();
+      
+      int[] failoverIndexes2 = delegate2.getFailoverIndexes();
+      
+      assertEquals(2, delegates2.length);
+      
+      cf1 = delegate2.getDelegates()[0];
+      
+      cf2 = delegate2.getDelegates()[1];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      
+      
+      assertEquals(2, failoverIndexes2.length);
+      
+      assertEquals(1, failoverIndexes2[0]);
+      
+      assertEquals(0, failoverIndexes2[1]);
+      
+      //Cleanly stop another server
+      
+      ServerManagement.stop(1, true);
+      
+      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
+      
+      //Lookup another connection factory
+      
+      JBossConnectionFactory factory3 =  (JBossConnectionFactory )ic3.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate3 =
+         (ClusteredClientConnectionFactoryDelegate)factory3.getDelegate();
+      
+      ClientConnectionFactoryDelegate[] delegates3 = delegate3.getDelegates();
+      
+      int[] failoverIndexes3 = delegate3.getFailoverIndexes();
+      
+      assertEquals(1, delegates3.length);
+      
+      cf1 = delegate3.getDelegates()[0];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      
+      assertEquals(1, failoverIndexes3.length);
+      
+      assertEquals(0, failoverIndexes3[0]);
+      
+      
+      //TODO - Add nodes back into the cluster - test framework currently does not support this
+      
+      
    }
    
-
-//   public void testConnectionFactoryConnect() throws Exception
-//   {
-//      try
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//                      (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         log.info ("number of delegates = " + delegate.getDelegates().length);
-//         log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//
-//         delegate.init();
-//
-//         for (int i = 0; i < 3; i++)
-//         {
-//            int failNode = delegate.getDelegates()[0].getFailoverNode(i);
-//            log.info("Failover node for server" + i + " = " + failNode);
-//            log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
-//
-//            assertEquals("Server1 should have the same failoverMapping",
-//                         failNode, delegate.getDelegates()[1].getFailoverNode(i));
-//            assertEquals("Server2 should have the same failoverMapping",
-//                         failNode, delegate.getDelegates()[2].getFailoverNode(i));
-//         }
-//
-//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         assertEquals(3, delegate.getDelegates().length);
-//
-//
-//         ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
-//         ServerManagement.stop(2,true);
-//
-//         ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
-//
-//         factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//         assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         assertEquals(2, delegate.getDelegates().length);
-//      }
-//      finally
-//      {
-//         ServerManagement.start("all", 2);
-//      }
-//
-//
-//   }
-
-
-//   public void testTopicSubscriber() throws Exception
-//   {
-//      try
-//      {
-//         log.info("++testTopicSubscriber");
-//
-//
-//         JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf;
-//         assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
-//
-//         log.info(">>Lookup Queue");
-//         Destination destination = (Destination) ic2.lookup("topic/testDistributedTopic");
-//
-//         log.info("Creating connection server1");
-//         JBossConnection conn = (JBossConnection) cf.createConnection();
-//         conn.setClientID("testClient");
-//         conn.start();
-//
-//         JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
-//         ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
-//         SessionState sessionState = (SessionState) clientSessionDelegate.getState();
-//
-//         MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
-//         JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
-//
-//         org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
-//         ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
-//
-//         log.info("subscriptionName=" + consumerState.getSubscriptionName());
-//
-//
-//         log.info(">>Creating Producer");
-//         MessageProducer producer = session.createProducer(destination);
-//         log.info(">>creating Message");
-//         Message message = session.createTextMessage("Hello Before");
-//         log.info(">>sending Message");
-//         producer.send(message);
-//         session.commit();
-//
-//         receiveMessage("consumerHA", consumerHA, true, false);
-//
-//         session.commit();
-//         //if (true) return;
-//
-//         Object txID = sessionState.getCurrentTxId();
-//
-//         producer.send(session.createTextMessage("Hello again before failover"));
-//
-//         ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
-//
-//         ServerManagement.stop(0, false);
-//
-//         Thread.sleep(25000);
-//
-//         //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//         message = session.createTextMessage("Hello After");
-//         log.info(">>Sending new message");
-//         producer.send(message);
-//
-//         assertEquals(txID, sessionState.getCurrentTxId());
-//         System.out.println("TransactionID on client = " + txID);
-//         log.info(">>Final commit");
-//
-//         /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//          connSecondServer.start();
-//          JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//          MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
-//
-//         session.commit();
-//
-//         /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-//        receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-//        receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
-//
-//         log.info("Calling alternate receiver");
-//         receiveMessage("consumerHA", consumerHA, true, false);
-//         receiveMessage("consumerHA", consumerHA, true, false);
-//         receiveMessage("consumerHA", consumerHA, true, true);
-//
-//
-//         session.commit();
-//
-//      }
-//      finally
-//      {
-//         // restart the server as it was probably stopped (tearDown will need that)
-//         ServerManagement.start("all", 0);
-//      }
-//   }
-
-//
-//   public void testQueueHA() throws Exception
-//   {
-//      log.info("++testTopicSubscriber");
-//
-//      log.info(">>Lookup Queue");
-//      Destination destination = (Destination) ic1.lookup("queue/testDistributedQueue");
-//
-//      log.info("Creating connection server1");
-//      JBossConnection conn = (JBossConnection) cf1.createConnection();
-//      conn.setClientID("testClient");
-//      conn.start();
-//
-//      JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
-//      ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
-//      SessionState sessionState = (SessionState) clientSessionDelegate.getState();
-//
-//      MessageConsumer consumerHA = session.createConsumer(destination);
-//      JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
-//
-//      org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
-//      ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
-//
-//      log.info("subscriptionName=" + consumerState.getSubscriptionName());
-//
-//
-//      log.info(">>Creating Producer");
-//      MessageProducer producer = session.createProducer(destination);
-//      log.info(">>creating Message");
-//      Message message = session.createTextMessage("Hello Before");
-//      log.info(">>sending Message");
-//      producer.send(message);
-//      session.commit();
-//
-//      session.commit();
-//      //if (true) return;
-//
-//      Object txID = sessionState.getCurrentTxId();
-//
-//      ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
-//
-//      JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//
-//      log.info(">>Creating alternate connection");
-//      JBossConnection conn2 = (JBossConnection) cf2.createConnection();
-//      log.info("NewConnectionCreated=" + conn2);
-//
-//      log.info(">>Failling over");
-//      assertSame(originalRemoting, delegate.getRemotingConnection());
-//      conn.getDelegate().failOver(conn2.getDelegate());
-//
-//      try
-//      {
-//         originalRemoting.stop();
-//      } catch (Throwable throwable)
-//      {
-//         throwable.printStackTrace();
-//      }
-//
-//
-//      assertNotSame(originalRemoting, delegate.getRemotingConnection());
-//
-//      //System.out.println("Kill server1"); Thread.sleep(10000);
-//      assertEquals(txID, sessionState.getCurrentTxId());
-//      System.out.println("TransactionID on client = " + txID);
-//      log.info(">>Final commit");
-//
-//      session.commit();
-//
-//      log.info("Calling alternate receiver");
-//      receiveMessage("consumerHA", consumerHA, true, false);
-//      receiveMessage("consumerHA", consumerHA, true, true);
-//
-//      session.commit();
-//
-//      for (int i = 0; i < 30; i++)
-//      {
-//         log.info("Message Sent " + i);
-//         producer.send(session.createTextMessage("Message " + i));
-//      }
-//      session.commit();
-//
-//      Thread.sleep(5000);
-//
-//      TextMessage messageLoop = null;
-//      while (!((messageLoop = (TextMessage) consumerHA.receive(5000)) == null))
-//      {
-//         log.info("Message received = " + messageLoop.getText());
-//      }
-//
-//   }
-
+   
+// public void testConnectionFactoryConnect() throws Exception
+// {
+// try
+// {
+// JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+// ClusteredClientConnectionFactoryDelegate delegate =
+// (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+// log.info ("number of delegates = " + delegate.getDelegates().length);
+// log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+// 
+// delegate.init();
+// 
+// for (int i = 0; i < 3; i++)
+// {
+// int failNode = delegate.getDelegates()[0].getFailoverNode(i);
+// log.info("Failover node for server" + i + " = " + failNode);
+// log.info("InvokerLocator for server " + i + " = " + delegate.getDelegates()[i].getServerLocatorURI());
+// 
+// assertEquals("Server1 should have the same failoverMapping",
+// failNode, delegate.getDelegates()[1].getFailoverNode(i));
+// assertEquals("Server2 should have the same failoverMapping",
+// failNode, delegate.getDelegates()[2].getFailoverNode(i));
+// }
+// 
+// assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+// assertEquals(3, delegate.getDelegates().length);
+// 
+// 
+// ServerManagement.log(ServerManagement.INFO,"Stopping server 2 as part of testConnectionFactoryConnect");
+// ServerManagement.stop(2,true);
+// 
+// ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
+// 
+// factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+// delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+// 
+// assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+// assertEquals(2, delegate.getDelegates().length);
+// }
+// finally
+// {
+// ServerManagement.start("all", 2);
+// }
+// 
+// 
+// }
+   
+   
+// public void testTopicSubscriber() throws Exception
+// {
+// try
+// {
+// log.info("++testTopicSubscriber");
+// 
+// 
+// JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf;
+// assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
+// 
+// log.info(">>Lookup Queue");
+// Destination destination = (Destination) ic2.lookup("topic/testDistributedTopic");
+// 
+// log.info("Creating connection server1");
+// JBossConnection conn = (JBossConnection) cf.createConnection();
+// conn.setClientID("testClient");
+// conn.start();
+// 
+// JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+// ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
+// SessionState sessionState = (SessionState) clientSessionDelegate.getState();
+// 
+// MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
+// JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
+// 
+// org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
+// ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
+// 
+// log.info("subscriptionName=" + consumerState.getSubscriptionName());
+// 
+// 
+// log.info(">>Creating Producer");
+// MessageProducer producer = session.createProducer(destination);
+// log.info(">>creating Message");
+// Message message = session.createTextMessage("Hello Before");
+// log.info(">>sending Message");
+// producer.send(message);
+// session.commit();
+// 
+// receiveMessage("consumerHA", consumerHA, true, false);
+// 
+// session.commit();
+// //if (true) return;
+// 
+// Object txID = sessionState.getCurrentTxId();
+// 
+// producer.send(session.createTextMessage("Hello again before failover"));
+// 
+// ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
+// 
+// ServerManagement.stop(0, false);
+// 
+// Thread.sleep(25000);
+// 
+// //System.out.println("Kill server1"); Thread.sleep(10000);
+// 
+// message = session.createTextMessage("Hello After");
+// log.info(">>Sending new message");
+// producer.send(message);
+// 
+// assertEquals(txID, sessionState.getCurrentTxId());
+// System.out.println("TransactionID on client = " + txID);
+// log.info(">>Final commit");
+// 
+// /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
+// connSecondServer.start();
+// JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
+// MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
+// 
+// session.commit();
+// 
+// /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+// receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+// receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
+// 
+// log.info("Calling alternate receiver");
+// receiveMessage("consumerHA", consumerHA, true, false);
+// receiveMessage("consumerHA", consumerHA, true, false);
+// receiveMessage("consumerHA", consumerHA, true, true);
+// 
+// 
+// session.commit();
+// 
+// }
+// finally
+// {
+// // restart the server as it was probably stopped (tearDown will need that)
+// ServerManagement.start("all", 0);
+// }
+// }
+   
+// 
+// public void testQueueHA() throws Exception
+// {
+// log.info("++testTopicSubscriber");
+// 
+// log.info(">>Lookup Queue");
+// Destination destination = (Destination) ic1.lookup("queue/testDistributedQueue");
+// 
+// log.info("Creating connection server1");
+// JBossConnection conn = (JBossConnection) cf1.createConnection();
+// conn.setClientID("testClient");
+// conn.start();
+// 
+// JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+// ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
+// SessionState sessionState = (SessionState) clientSessionDelegate.getState();
+// 
+// MessageConsumer consumerHA = session.createConsumer(destination);
+// JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
+// 
+// org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
+// ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
+// 
+// log.info("subscriptionName=" + consumerState.getSubscriptionName());
+// 
+// 
+// log.info(">>Creating Producer");
+// MessageProducer producer = session.createProducer(destination);
+// log.info(">>creating Message");
+// Message message = session.createTextMessage("Hello Before");
+// log.info(">>sending Message");
+// producer.send(message);
+// session.commit();
+// 
+// session.commit();
+// //if (true) return;
+// 
+// Object txID = sessionState.getCurrentTxId();
+// 
+// ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
+// 
+// JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
+// 
+// log.info(">>Creating alternate connection");
+// JBossConnection conn2 = (JBossConnection) cf2.createConnection();
+// log.info("NewConnectionCreated=" + conn2);
+// 
+// log.info(">>Failling over");
+// assertSame(originalRemoting, delegate.getRemotingConnection());
+// conn.getDelegate().failOver(conn2.getDelegate());
+// 
+// try
+// {
+// originalRemoting.stop();
+// } catch (Throwable throwable)
+// {
+// throwable.printStackTrace();
+// }
+// 
+// 
+// assertNotSame(originalRemoting, delegate.getRemotingConnection());
+// 
+// //System.out.println("Kill server1"); Thread.sleep(10000);
+// assertEquals(txID, sessionState.getCurrentTxId());
+// System.out.println("TransactionID on client = " + txID);
+// log.info(">>Final commit");
+// 
+// session.commit();
+// 
+// log.info("Calling alternate receiver");
+// receiveMessage("consumerHA", consumerHA, true, false);
+// receiveMessage("consumerHA", consumerHA, true, true);
+// 
+// session.commit();
+// 
+// for (int i = 0; i < 30; i++)
+// {
+// log.info("Message Sent " + i);
+// producer.send(session.createTextMessage("Message " + i));
+// }
+// session.commit();
+// 
+// Thread.sleep(5000);
+// 
+// TextMessage messageLoop = null;
+// while (!((messageLoop = (TextMessage) consumerHA.receive(5000)) == null))
+// {
+// log.info("Message received = " + messageLoop.getText());
+// }
+// 
+// }
+   
    // Package protected ---------------------------------------------
-
+   
    // Protected -----------------------------------------------------
-
+   
    protected void setUp() throws Exception
    {
       super.setUp();
    }
-
+   
    protected void tearDown() throws Exception
    {
       super.tearDown();
    }
-
+   
    // Private -------------------------------------------------------
-
+   
    private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
    {
       MessageProxy message = (MessageProxy) consumer.receive(3000);
@@ -487,7 +562,7 @@
          }
       }
    }
-
+   
    // Inner classes -------------------------------------------------
-
+   
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 13:22:15 UTC (rev 1727)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 14:07:04 UTC (rev 1728)
@@ -129,16 +129,26 @@
       try
       {
          ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0");
-         ServerManagement.undeployQueue("testDistributedQueue", 0);
-         ServerManagement.undeployTopic("testDistributedTopic", 0);
+         
+         if (ServerManagement.getServer(0).isStarted())
+         {         
+            ServerManagement.undeployQueue("testDistributedQueue", 0);
+            ServerManagement.undeployTopic("testDistributedTopic", 0);
+         }
 
-         ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1");
-         ServerManagement.undeployQueue("testDistributedQueue", 1);
-         ServerManagement.undeployTopic("testDistributedTopic", 1);
+         if (ServerManagement.getServer(1).isStarted())
+         {  
+            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1");
+            ServerManagement.undeployQueue("testDistributedQueue", 1);
+            ServerManagement.undeployTopic("testDistributedTopic", 1);
+         }
 
-         ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2");
-         ServerManagement.undeployQueue("testDistributedQueue", 2);
-         ServerManagement.undeployTopic("testDistributedTopic", 2);
+         if (ServerManagement.getServer(2).isStarted())
+         {  
+            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2");
+            ServerManagement.undeployQueue("testDistributedQueue", 2);
+            ServerManagement.undeployTopic("testDistributedTopic", 2);
+         }
 
          ic1.close();
          ic2.close();

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-08 13:22:15 UTC (rev 1727)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-08 14:07:04 UTC (rev 1728)
@@ -450,7 +450,10 @@
    
          try
          {
-            sc.invoke(serverPeerObjectName, "stop", new Object[]{new Boolean(sendNotification)}, new String[]{"boolean"});
+            //Huh?? Where's the method on the server peer???
+            //sc.invoke(serverPeerObjectName, "stop", new Object[]{new Boolean(sendNotification)}, new String[]{"boolean"});
+            
+            sc.invoke(serverPeerObjectName, "stop", new Object[0], new String[0]);
             sc.invoke(serverPeerObjectName, "destroy", new Object[0], new String[0]);
             sc.unregisterService(serverPeerObjectName);
          }



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 10:24:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 10:24:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r58924 -
	trunk/ejb3/src/main/org/jboss/ejb3/metamodel
Message-ID: <E1GshaY-00056R-4E@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-08 10:24:34 -0500 (Fri, 08 Dec 2006)
New Revision: 58924

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java
Log:
support for business-local and business-remote

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java	2006-12-08 10:28:33 UTC (rev 58923)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java	2006-12-08 15:24:34 UTC (rev 58924)
@@ -1271,7 +1271,7 @@
          ejb.setHome(getValue(localName, value));
          return true;
       }
-      else if (localName.equals("remote"))
+      else if (localName.equals("remote") || localName.equals("business-remote"))
       {
          ejb.setRemote(getValue(localName, value));
          return true;
@@ -1281,7 +1281,7 @@
          ejb.setLocalHome(getValue(localName, value));
          return true;
       }
-      else if (localName.equals("local"))
+      else if (localName.equals("local") || localName.equals("business-local"))
       {
          ejb.setLocal(getValue(localName, value));
          return true;



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 10:29:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 10:29:29 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1729 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GshfF-0005Cw-W6@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-08 10:29:23 -0500 (Fri, 08 Dec 2006)
New Revision: 1729

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
More HA



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-08 14:07:04 UTC (rev 1728)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-08 15:29:23 UTC (rev 1729)
@@ -226,7 +226,10 @@
          if (replicator != null)
          {         
             //There may be no clustered post office deployed
-            replicator.remove(CF_PREFIX + uniqueName);
+            if (!replicator.remove(CF_PREFIX + uniqueName))
+            {
+               throw new IllegalStateException("Cannot find replicant to remove: " + CF_PREFIX + uniqueName);
+            }
          }
          
       }
@@ -288,17 +291,21 @@
             
             ClusteredClientConnectionFactoryDelegate clusteredDelegate = createClusteredDelegate(updatedReplicantMap);
             
-            // Now rebind ...
-            
-            ServerConnectionFactoryEndpoint endpoint =
-               (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
-            
-            if (endpoint == null)
-            {
-               throw new IllegalStateException("Cannot find endpoint " + uniqueName );
+            //It could be null if the cf is being undeployed
+            if (clusteredDelegate != null)
+            {               
+               // Now rebind ...
+               
+               ServerConnectionFactoryEndpoint endpoint =
+                  (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
+               
+               if (endpoint == null)
+               {
+                  throw new IllegalStateException("Cannot find endpoint " + uniqueName );
+               }
+   
+               rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), clusteredDelegate);
             }
-
-            rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), clusteredDelegate);
          }
       }
       catch (NamingException e)
@@ -333,12 +340,9 @@
     */
    private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates)
    {
-
-
       //TODO: make it trace after the code is stable
       log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
 
-
       int s = localDelegates.size();
 
       int[] nodesIDs = new int[s];
@@ -350,7 +354,7 @@
 
       int idx = 0;
 
-      for(Iterator i = localDelegates.entrySet().iterator(); i.hasNext(); )
+      for(Iterator i = localDelegates.entrySet().iterator(); i.hasNext();)
       {
          Map.Entry entry = (Map.Entry)i.next();
 
@@ -365,7 +369,6 @@
 
          if (delegates[idx].getServerId() == this.serverPeer.getServerPeerID())
          {
-
             // sanity check
             if (mainDelegate != null)
             {
@@ -377,41 +380,43 @@
          idx++;
       }
       // sanity check
-      if (mainDelegate == null)
-      {
-         throw new IllegalStateException("Couldn't find a delegate for this serverID=" + this.serverPeer.getServerPeerID());
-      }
-
       
       // Generate the failover indexes. This could probably be optimised if need be.
       
-      int[] failoverIndexes = new int[s];
+      //MainDelegate would be null in the case the cf is being undeployed locally
       
-      for (int i = 0; i < s; i++)
-      {
-         int failoverNode = failoverNodeIDs[i];
-         int failoverIndex = -1;
+      ClusteredClientConnectionFactoryDelegate clusteredDelegate = null;
+      
+      if (mainDelegate != null)
+      {         
+         int[] failoverIndexes = new int[s];
          
-         for (int j = 0; j < s; j++)
+         for (int i = 0; i < s; i++)
          {
-            if (nodesIDs[j] == failoverNode)
+            int failoverNode = failoverNodeIDs[i];
+            int failoverIndex = -1;
+            
+            for (int j = 0; j < s; j++)
             {
-               failoverIndex = j;
-               break;
+               if (nodesIDs[j] == failoverNode)
+               {
+                  failoverIndex = j;
+                  break;
+               }
             }
+            
+            if (failoverIndex == -1)
+            {
+               throw new IllegalStateException("Failover node " + failoverNode + " is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
+            }
+            
+            failoverIndexes[i] = failoverIndex;
          }
-         
-         if (failoverIndex == -1)
-         {
-            throw new IllegalStateException("Failover node " + failoverNode + " is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
-         }
-         
-         failoverIndexes[i] = failoverIndex;
+   
+         clusteredDelegate =
+            new ClusteredClientConnectionFactoryDelegate(mainDelegate, delegates, failoverIndexes);
       }
 
-      ClusteredClientConnectionFactoryDelegate clusteredDelegate =
-         new ClusteredClientConnectionFactoryDelegate(mainDelegate,delegates,failoverIndexes);
-
       return clusteredDelegate;
    }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 14:07:04 UTC (rev 1728)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 15:29:23 UTC (rev 1729)
@@ -21,7 +21,6 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
@@ -44,6 +43,7 @@
 import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
+
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -76,6 +76,8 @@
 import org.jgroups.blocks.RequestHandler;
 import org.w3c.dom.Element;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * 
  * A DefaultClusteredPostOffice
@@ -1887,7 +1889,7 @@
     *        the given key.
     */
    private void notifyListeners(Serializable key, Map updatedReplicantMap)
-   {
+   { 
       synchronized (replicationListeners)
       {         
          for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
@@ -2189,8 +2191,7 @@
 
       log.info(this.currentNodeId + " Node with address: " + address + " joined");
       
-      // We need to regenerate the failover map
-      //generateFailoverMap(currentView);
+      //Currently does nothing
    }
 
    /*
@@ -2238,6 +2239,7 @@
          failOver(theNodeId.intValue());
       }
    }
+         
 
    // Inner classes -------------------------------------------------------------------
     

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java	2006-12-08 14:07:04 UTC (rev 1728)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java	2006-12-08 15:29:23 UTC (rev 1729)
@@ -48,7 +48,10 @@
    
    Object execute(PostOfficeInternal office) throws Exception
    {
-      office.removeReplicantLocally(nodeId, key);
+      if (!office.removeReplicantLocally(nodeId, key))
+      {
+         throw new IllegalStateException("Failed to remove replicant locally: " + nodeId + " key: "+ key);
+      }
       
       return null;
    }

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 14:07:04 UTC (rev 1728)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 15:29:23 UTC (rev 1729)
@@ -715,7 +715,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/HATest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 14:07:04 UTC (rev 1728)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 15:29:23 UTC (rev 1729)
@@ -22,12 +22,16 @@
 
 package org.jboss.test.messaging.jms.clustering;
 
+import javax.jms.Connection;
 import javax.jms.MessageConsumer;
 import javax.jms.TextMessage;
 
+import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -217,6 +221,10 @@
       
       // Default failover policy just chooses the node to the right
       
+      log.info("failoverindex[0]:" + failoverIndexes[0]);
+      log.info("failoverindex[1]:" + failoverIndexes[1]);
+      log.info("failoverindex[2]:" + failoverIndexes[2]);
+      
       assertEquals(1, failoverIndexes[0]);
       
       assertEquals(2, failoverIndexes[1]);



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 10:48:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 10:48:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r58925 - in projects/microcontainer/trunk:
	dependency kernel
Message-ID: <E1Gshxy-0005Xf-9g@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-08 10:48:47 -0500 (Fri, 08 Dec 2006)
New Revision: 58925

Modified:
   projects/microcontainer/trunk/dependency/build-test14.xml
   projects/microcontainer/trunk/kernel/build-test14.xml
Log:
Missed some jboss.common.classpath references in the 14 tests.

Modified: projects/microcontainer/trunk/dependency/build-test14.xml
===================================================================
--- projects/microcontainer/trunk/dependency/build-test14.xml	2006-12-08 15:24:34 UTC (rev 58924)
+++ projects/microcontainer/trunk/dependency/build-test14.xml	2006-12-08 15:48:47 UTC (rev 58925)
@@ -129,7 +129,9 @@
 	      <include name="*.jar"/>
 	   </fileset>
       <path refid="jboss.test14.classpath"/>
-      <path refid="jboss.common.classpath"/>
+      <path refid="jboss.common.core.classpath"/>
+      <path refid="jboss.common.logging.spi.classpath"/>
+      <path refid="jboss.common.logging.log4j.classpath"/>
       <path refid="apache.log4j.classpath"/>
       <path refid="javassist.classpath"/>
       <path refid="oswego.concurrent.classpath"/>

Modified: projects/microcontainer/trunk/kernel/build-test14.xml
===================================================================
--- projects/microcontainer/trunk/kernel/build-test14.xml	2006-12-08 15:24:34 UTC (rev 58924)
+++ projects/microcontainer/trunk/kernel/build-test14.xml	2006-12-08 15:48:47 UTC (rev 58925)
@@ -162,7 +162,9 @@
       <path refid="jboss.container14.classpath"/>
       <path refid="jboss.dependency14.classpath"/>
       <path refid="jboss.test14.classpath"/>
-      <path refid="jboss.common.classpath"/>
+      <path refid="jboss.common.core.classpath"/>
+      <path refid="jboss.common.logging.spi.classpath"/>
+      <path refid="jboss.common.logging.log4j.classpath"/>
       <path refid="apache.log4j.classpath"/>
       <path refid="javassist.classpath"/>
       <path refid="oswego.concurrent.classpath"/>



From norman.richards at jboss.com  Fri Dec  8 10:52:59 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 08 Dec 2006 10:52:59 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1Gsi1z-0005e1-CO@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/08 10:52:59

  Modified:    doc/reference/en/modules  drools.xml
  Log:
  fix typo
  
  Revision  Changes    Path
  1.13      +2 -2      jboss-seam/doc/reference/en/modules/drools.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: drools.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/drools.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- drools.xml	27 Nov 2006 03:28:16 -0000	1.12
  +++ drools.xml	8 Dec 2006 15:52:59 -0000	1.13
  @@ -51,7 +51,7 @@
                accumulates facts relating to the current conversation.)
            </para>
   
  -         <programlisting><![CDATA[<drools:managed-working-memory name="policyPricingMemory" auto-create="true" rule-base="#{policyPricingRules}"/>]]></programlisting>
  +         <programlisting><![CDATA[<drools:managed-working-memory name="policyPricingWorkingMemory" auto-create="true" rule-base="#{policyPricingRules}"/>]]></programlisting>
   
            <para>
                Notice that we gave the <literal>policyPricingWorkingMemory</literal> a
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:01:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:01:51 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58926 - tags
Message-ID: <E1GsiAZ-0005qJ-C8@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-08 11:01:51 -0500 (Fri, 08 Dec 2006)
New Revision: 58926

Removed:
   tags/JBoss_4_0_3_SP1_CP03/
Log:
remove tag, ASPATCH-129 was reverted



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:03:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:03:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r58927 - in
	trunk/server/src/main/org/jboss/metadata: . web
Message-ID: <E1GsiCX-00061F-6l@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-08 11:03:49 -0500 (Fri, 08 Dec 2006)
New Revision: 58927

Added:
   trunk/server/src/main/org/jboss/metadata/web/LocaleEncodingMapping.java
   trunk/server/src/main/org/jboss/metadata/web/MimeMapping.java
   trunk/server/src/main/org/jboss/metadata/web/Taglib.java
Modified:
   trunk/server/src/main/org/jboss/metadata/WebMetaData.java
Log:
- Add fields and utility objects.

Modified: trunk/server/src/main/org/jboss/metadata/WebMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-08 16:01:51 UTC (rev 58926)
+++ trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-08 16:03:49 UTC (rev 58927)
@@ -38,13 +38,16 @@
 import org.jboss.metadata.web.ErrorPage;
 import org.jboss.metadata.web.Filter;
 import org.jboss.metadata.web.FilterMapping;
+import org.jboss.metadata.web.LocaleEncodingMapping;
 import org.jboss.metadata.web.LoginConfig;
+import org.jboss.metadata.web.MimeMapping;
 import org.jboss.metadata.web.ParamValue;
 import org.jboss.metadata.web.PassivationConfig;
 import org.jboss.metadata.web.ReplicationConfig;
 import org.jboss.metadata.web.Servlet;
 import org.jboss.metadata.web.ServletMapping;
 import org.jboss.metadata.web.SessionConfig;
+import org.jboss.metadata.web.Taglib;
 import org.jboss.mx.loading.LoaderRepositoryFactory;
 import org.jboss.mx.loading.LoaderRepositoryFactory.LoaderRepositoryConfig;
 import org.jboss.mx.util.ObjectNameFactory;
@@ -157,6 +160,19 @@
    /** Flag to check for metadata in webapps **/
    private boolean metadataComplete = false;
 
+   /** web-app/mime-mapping */
+   private List<MimeMapping> mimeMappings = new ArrayList<MimeMapping>();
+   /** web-app/locale-encoding-mapping */
+   private List<LocaleEncodingMapping> localeEncodingMappings = new ArrayList<LocaleEncodingMapping>();
+   /** web-app/welcome-file */
+   private List<String> welcomeFiles = new ArrayList<String>();
+   /** web-app/web-app/jsp-config/jsp-property-group/url-pattern */
+   private List<String> jspMappings = new ArrayList<String>();
+   /** web-app/session-config/session-timeout */
+   private int sessionTimeout = -1;
+   /** web-app/taglib */
+   private List<Taglib> taglibs = new ArrayList<Taglib>();
+
    /**
     * this is really a hack for new injection code  so that we can reparse web.xml/jbossweb.xml for JavaEE 5 injections
     * todo remove this when we clean up
@@ -368,6 +384,66 @@
       securityConstraints.add(constraint);
    }
    
+   public Collection<MimeMapping> getMimeMappings()
+   {
+      return mimeMappings;
+   }
+
+   public void addMimeMapping(MimeMapping mimeMapping)
+   {
+      mimeMappings.add(mimeMapping);
+   }
+
+   public Collection<LocaleEncodingMapping> getLocaleEncodingMappings()
+   {
+      return localeEncodingMappings;
+   }
+
+   public void addLocaleEncodingMapping(LocaleEncodingMapping localeEncodingMapping)
+   {
+      localeEncodingMappings.add(localeEncodingMapping);
+   }
+
+   public Collection<String> getWelcomeFiles()
+   {
+      return welcomeFiles;
+   }
+
+   public void addWelcomeFile(String welcomeFile)
+   {
+      welcomeFiles.add(welcomeFile);
+   }
+
+   public Collection<String> getJspMappings()
+   {
+      return jspMappings;
+   }
+
+   public void addJspMapping(String jspMapping)
+   {
+      jspMappings.add(jspMapping);
+   }
+
+   public int getSessionTimeout()
+   {
+      return sessionTimeout;
+   }
+
+   public void setSessionTimeout(int sessionTimeout)
+   {
+      this.sessionTimeout = sessionTimeout;
+   }
+
+   public Collection<Taglib> getTaglibs()
+   {
+      return taglibs;
+   }
+
+   public void addTaglib(Taglib taglib)
+   {
+      taglibs.add(taglib);
+   }
+
    public LoginConfig getLoginConfig()
    {
       return loginConfig;

Added: trunk/server/src/main/org/jboss/metadata/web/LocaleEncodingMapping.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/web/LocaleEncodingMapping.java	2006-12-08 16:01:51 UTC (rev 58926)
+++ trunk/server/src/main/org/jboss/metadata/web/LocaleEncodingMapping.java	2006-12-08 16:03:49 UTC (rev 58927)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.web;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Represents a <locale-encoding-mapping> element of the web.xml deployment descriptor for the
+ * 2.5 schema
+ *
+ * @version <tt>$Revision: 45409 $</tt>
+ */
+public class LocaleEncodingMapping
+{
+   private static final Logger log = Logger.getLogger(LocaleEncodingMapping.class);
+   
+   protected String locale;
+   protected String encoding;
+   
+   public String getLocale()
+   {
+      return locale;
+   }
+   
+   public void setLocale(String locale)
+   {
+      this.locale = locale;
+   }
+   
+   public String getEncoding()
+   {
+      return encoding;
+   }
+   
+   public void setEncoding(String encoding)
+   {
+      this.encoding = encoding;
+   }
+   
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer(100);
+      return sb.toString();
+   }
+}


Property changes on: trunk/server/src/main/org/jboss/metadata/web/LocaleEncodingMapping.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: trunk/server/src/main/org/jboss/metadata/web/MimeMapping.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/web/MimeMapping.java	2006-12-08 16:01:51 UTC (rev 58926)
+++ trunk/server/src/main/org/jboss/metadata/web/MimeMapping.java	2006-12-08 16:03:49 UTC (rev 58927)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.web;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Represents a <mime-mapping> element of the web.xml deployment descriptor for the
+ * 2.5 schema
+ *
+ * @version <tt>$Revision: 45409 $</tt>
+ */
+public class MimeMapping
+{
+   private static final Logger log = Logger.getLogger(MimeMapping.class);
+   
+   protected String extension;
+   protected String mimeType;
+   
+   public String getExtension()
+   {
+      return extension;
+   }
+   
+   public void setExtension(String extension)
+   {
+      this.extension = extension;
+   }
+   
+   public String getMimeType()
+   {
+      return mimeType;
+   }
+   
+   public void setMimeType(String mimeType)
+   {
+      this.mimeType = mimeType;
+   }
+   
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer(100);
+      return sb.toString();
+   }
+}


Property changes on: trunk/server/src/main/org/jboss/metadata/web/MimeMapping.java
___________________________________________________________________
Name: svn:eol-style
   + native

Added: trunk/server/src/main/org/jboss/metadata/web/Taglib.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/web/Taglib.java	2006-12-08 16:01:51 UTC (rev 58926)
+++ trunk/server/src/main/org/jboss/metadata/web/Taglib.java	2006-12-08 16:03:49 UTC (rev 58927)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.web;
+
+import org.jboss.logging.Logger;
+
+/**
+ * Represents a <taglib> element of the web.xml deployment descriptor for the
+ * 2.5 schema
+ *
+ * @version <tt>$Revision: 45409 $</tt>
+ */
+public class Taglib
+{
+   private static final Logger log = Logger.getLogger(Taglib.class);
+   
+   protected String location;
+   protected String uri;
+   
+   public String getLocation()
+   {
+      return location;
+   }
+   
+   public void setLocation(String location)
+   {
+      this.location = location;
+   }
+   
+   public String getUri()
+   {
+      return uri;
+   }
+   
+   public void setUri(String uri)
+   {
+      this.uri = uri;
+   }
+   
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer(100);
+      return sb.toString();
+   }
+}


Property changes on: trunk/server/src/main/org/jboss/metadata/web/Taglib.java
___________________________________________________________________
Name: svn:eol-style
   + native



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:04:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:04:41 -0500
Subject: [jboss-cvs] JBossAS SVN: r58928 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1GsiDJ-00061Y-8l@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-08 11:04:39 -0500 (Fri, 08 Dec 2006)
New Revision: 58928

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
Log:
- Use the new meta data fields.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-08 16:03:49 UTC (rev 58927)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-08 16:04:39 UTC (rev 58928)
@@ -21,6 +21,7 @@
  */
 package org.jboss.web.tomcat.tc6.deployers;
 
+import java.util.Collection;
 import java.util.Iterator;
 
 import org.apache.catalina.core.StandardContext;
@@ -34,7 +35,9 @@
 import org.jboss.metadata.web.ErrorPage;
 import org.jboss.metadata.web.Filter;
 import org.jboss.metadata.web.FilterMapping;
+import org.jboss.metadata.web.LocaleEncodingMapping;
 import org.jboss.metadata.web.LoginConfig;
+import org.jboss.metadata.web.MimeMapping;
 import org.jboss.metadata.web.ParamValue;
 import org.jboss.metadata.web.Servlet;
 import org.jboss.metadata.web.ServletMapping;
@@ -125,7 +128,11 @@
     		context.addApplicationListener(value.getListenerClass());
     	}
     	
-    	// FIXME: handling jsp-config for jsp-property-group/url-pattern and listener-class is needed
+      // JSP mappings
+      Iterator<String> iterator10 = metaData.getJspMappings().iterator();
+      while (iterator10.hasNext()) {
+         context.addJspMapping(iterator10.next());
+      }
     	
     	// Login configuration
     	LoginConfig loginConfig = metaData.getLoginConfig();
@@ -141,7 +148,12 @@
     		context.setLoginConfig(loginConfig2);
     	}
     	
-    	// FIXME: mime mappings parsing
+      // MIME mappings
+      Iterator<MimeMapping> iterator11 = metaData.getMimeMappings().iterator();
+      while (iterator11.hasNext()) {
+         MimeMapping value = iterator11.next();
+         context.addMimeMapping(value.getExtension(), value.getMimeType());
+      }
     	
     	// Security constraints
     	Iterator<WebSecurityMetaData> iterator6 = metaData.getSecurityContraints();
@@ -152,7 +164,6 @@
     		constraint.setUserConstraint(value.getTransportGuarantee());
     		constraint.setAuthConstraint(value.getAuthConstraint() != null);
     		if (value.getAuthConstraint() != null) {
-    			// FIXME: there's a duplicate roles field on the WebSecurityMetaData itself
     			Iterator<String> roles = value.getAuthConstraint().getRoleNames().iterator();
     			while (roles.hasNext()) {
     				constraint.addAuthRole(roles.next());
@@ -220,11 +231,23 @@
          }
     	}
     	
-    	// FIXME: locale-encoding-mapping-list
+      // Locale encoding mapping
+      Iterator<LocaleEncodingMapping> iterator12 = metaData.getLocaleEncodingMappings().iterator();
+      while (iterator12.hasNext()) {
+         LocaleEncodingMapping value = iterator12.next();
+         context.addLocaleEncodingMappingParameter(value.getLocale(), value.getEncoding());
+      }
     	
-    	// FIXME: welcome-file-list
+    	// Welcome files
+      Iterator<String> iterator13 = metaData.getWelcomeFiles().iterator();
+      while (iterator13.hasNext()) {
+         context.addWelcomeFile(iterator13.next());
+      }
 
-      // FIXME: session-config
+      // Session timeout
+      if (metaData.getSessionTimeout() > 0) {
+         context.setSessionTimeout(metaData.getSessionTimeout());
+      }
         
 	}
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:07:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:07:06 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58929 - tags
Message-ID: <E1GsiFe-00066z-G5@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-08 11:07:06 -0500 (Fri, 08 Dec 2006)
New Revision: 58929

Added:
   tags/JBoss_4_0_3_SP1_CP03/
Log:
cut the 4.0.3.SP1_CP03 release

Copied: tags/JBoss_4_0_3_SP1_CP03 (from rev 58928, branches/JBoss_4_0_3_SP1_CP)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:17:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:17:31 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58930 - in trunk: ejb3 j2ee server
Message-ID: <E1GsiPj-0006JF-HG@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-08 11:17:27 -0500 (Fri, 08 Dec 2006)
New Revision: 58930

Modified:
   trunk/ejb3/.classpath
   trunk/j2ee/.classpath
   trunk/server/.classpath
Log:
Fix the eclipse build

Modified: trunk/ejb3/.classpath
===================================================================
--- trunk/ejb3/.classpath	2006-12-08 16:07:06 UTC (rev 58929)
+++ trunk/ejb3/.classpath	2006-12-08 16:17:27 UTC (rev 58930)
@@ -81,6 +81,7 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-microcontainer.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/quartz/lib/quartz-all-1.5.2.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jbossws-client.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jboss-jaxrpc.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/connector"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/iiop"/>

Modified: trunk/j2ee/.classpath
===================================================================
--- trunk/j2ee/.classpath	2006-12-08 16:07:06 UTC (rev 58929)
+++ trunk/j2ee/.classpath	2006-12-08 16:17:27 UTC (rev 58930)
@@ -7,5 +7,6 @@
  <classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
  <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
  <classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jboss-jaxrpc.jar"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: trunk/server/.classpath
===================================================================
--- trunk/server/.classpath	2006-12-08 16:07:06 UTC (rev 58929)
+++ trunk/server/.classpath	2006-12-08 16:17:27 UTC (rev 58930)
@@ -32,5 +32,7 @@
 	<classpathentry combineaccessrules="false" kind="src" path="/transaction"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar" sourcepath="/thirdparty/jboss/microcontainer/lib/jboss-container-src.zip"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-dependency.jar" sourcepath="/thirdparty/jboss/microcontainer/lib/jboss-dependency-src.zip"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jboss-jaxrpc.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jboss-saaj.jar"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:24:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:24:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r58931 -
	trunk/ejb3/src/test/org/jboss/ejb3/test/webservices/unit
Message-ID: <E1GsiWl-0006PR-C8@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-08 11:24:45 -0500 (Fri, 08 Dec 2006)
New Revision: 58931

Modified:
   trunk/ejb3/src/test/org/jboss/ejb3/test/webservices/unit/JSR181TestCase.java
Log:
Make this compile.

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/webservices/unit/JSR181TestCase.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/webservices/unit/JSR181TestCase.java	2006-12-08 16:17:27 UTC (rev 58930)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/webservices/unit/JSR181TestCase.java	2006-12-08 16:24:45 UTC (rev 58931)
@@ -35,7 +35,7 @@
 
 import org.jboss.test.JBossTestCase;
 import org.jboss.ws.metadata.wsdl.WSDLDefinitions;
-import org.jboss.ws.metadata.wsdl.WSDLDefinitionsFactory;
+import org.jboss.ws.tools.wsdl.WSDLDefinitionsFactory;
 
 import org.jboss.ejb3.test.webservices.jsr181.EndpointInterface;
 import org.jboss.ejb3.test.webservices.jsr181.EJB3RemoteInterface;



From mculpepper at jboss.com  Fri Dec  8 11:29:40 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Fri, 08 Dec 2006 11:29:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal
	...
Message-ID: <E1GsibU-0006VV-HE@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/08 11:29:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal 
                        PackagesModel.java
  Log:
  attempting to fix an endless loop when a project is registered that fires an event to UI that causes another register.. etc..
  
  Revision  Changes    Path
  1.9       +9 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- PackagesModel.java	6 Dec 2006 17:47:33 -0000	1.8
  +++ PackagesModel.java	8 Dec 2006 16:29:40 -0000	1.9
  @@ -70,6 +70,7 @@
   	private Hashtable xbPackages;
   	private ArrayList buildListeners;
   	private ArrayList modelListeners;
  +	private IProject projectBeingRegistered;
   	
   	private PackagesModel ()
   	{
  @@ -79,6 +80,7 @@
   		packageTypes = new Hashtable();
   		buildListeners = new ArrayList();
   		modelListeners = new ArrayList();
  +		projectBeingRegistered = null;
   		
   		loadPackageTypes();
   	}
  @@ -93,6 +95,7 @@
   	
   	public void registerProject(IProject project, IProgressMonitor monitor)
   	{
  +		projectBeingRegistered = project;
   		monitor.beginTask("Loading configuration...", XMLBinding.NUM_UNMARSHAL_MONITOR_STEPS + 2);
   		
   		IFile packagesFile = project.getFile(PROJECT_PACKAGES_FILE);
  @@ -113,6 +116,7 @@
   				Trace.trace(PackagesModel.class, e);
   			}
   		}
  +		projectBeingRegistered = null;
   	}
   	
   	public IPackage createPackage(IProject project, boolean isTopLevel)
  @@ -434,12 +438,16 @@
   		if (!force && !modelBridge.containsKey(source)) //not registered in the model, no event should be broadcast
   			return;
   		
  +		if (projectBeingRegistered != null && source.getProject().equals(projectBeingRegistered))
  +			return;
  +		
   		PackageNodeImpl nodeImpl = (PackageNodeImpl) source;
   		if (!nodeImpl.isWorkingCopy())
   		{
   			runnable.run();
   		}
   	}
  +	
   	protected void fireEvent (IPackageNode source, Runnable runnable)
   	{
   		fireEvent(source, false, runnable);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 11:29:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 11:29:58 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58932 - trunk/testsuite
Message-ID: <E1Gsibm-0006Vg-6D@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-08 11:29:56 -0500 (Fri, 08 Dec 2006)
New Revision: 58932

Modified:
   trunk/testsuite/.classpath
Log:
Fix the eclipse build

Modified: trunk/testsuite/.classpath
===================================================================
--- trunk/testsuite/.classpath	2006-12-08 16:24:45 UTC (rev 58931)
+++ trunk/testsuite/.classpath	2006-12-08 16:29:56 UTC (rev 58932)
@@ -48,6 +48,8 @@
 	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/apache-logging/lib/commons-logging.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jbossws-client.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jboss-jaxrpc.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossws/lib/jboss-saaj.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/sun-xacml/lib/sunxacml.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/sun-xacml/lib/sunxacml-support.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>



From mculpepper at jboss.com  Fri Dec  8 11:45:50 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Fri, 08 Dec 2006 11:45:50 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal
	...
Message-ID: <E1Gsir8-0006nr-Ld@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/08 11:45:50

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal 
                        PackagesModel.java
  Log:
  only register a project if it isn't being registered already... 
  
  Revision  Changes    Path
  1.10      +21 -18    jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- PackagesModel.java	8 Dec 2006 16:29:40 -0000	1.9
  +++ PackagesModel.java	8 Dec 2006 16:45:50 -0000	1.10
  @@ -95,6 +95,8 @@
   	
   	public void registerProject(IProject project, IProgressMonitor monitor)
   	{
  +		if (projectBeingRegistered == null)
  +		{
   		projectBeingRegistered = project;
   		monitor.beginTask("Loading configuration...", XMLBinding.NUM_UNMARSHAL_MONITOR_STEPS + 2);
   		
  @@ -118,6 +120,7 @@
   		}
   		projectBeingRegistered = null;
   	}
  +	}
   	
   	public IPackage createPackage(IProject project, boolean isTopLevel)
   	{
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 12:01:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 12:01:39 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1730 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster
Message-ID: <E1Gsj6R-00073d-VC@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-08 12:01:38 -0500 (Fri, 08 Dec 2006)
New Revision: 1730

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
applying ordering into listeners

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 15:29:23 UTC (rev 1729)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 17:01:38 UTC (rev 1730)
@@ -21,6 +21,7 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
@@ -35,15 +36,14 @@
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
+import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
-
 import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
-
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -76,8 +76,6 @@
 import org.jgroups.blocks.RequestHandler;
 import org.w3c.dom.Element;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
  * 
  * A DefaultClusteredPostOffice
@@ -268,7 +266,7 @@
       
       replicatedData = new HashMap();      
       
-      replicationListeners = new HashSet();
+      replicationListeners = new LinkedHashSet();
       
       failoverMap = new LinkedHashMap();
       



From david.lloyd at jboss.com  Fri Dec  8 12:49:38 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 12:49:38 -0500
Subject: [jboss-cvs] repository.jboss.com/ajax4jsf/1.0.4MR2 - New directory ...
Message-ID: <E1Gsjqs-0007sB-Eh@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 12:49:38

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/ajax4jsf/1.0.4MR2 added to the repository


From david.lloyd at jboss.com  Fri Dec  8 12:49:45 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 12:49:45 -0500
Subject: [jboss-cvs] repository.jboss.com/ajax4jsf/1.0.4MR2/lib - New
	directory ...
Message-ID: <E1Gsjqz-0007sK-Fw@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 12:49:45

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/ajax4jsf/1.0.4MR2/lib added to the repository


From david.lloyd at jboss.com  Fri Dec  8 12:50:26 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 12:50:26 -0500
Subject: [jboss-cvs] repository.jboss.com/ajax4jsf/1.0.4MR2  ...
Message-ID: <E1Gsjre-0007uI-8m@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 12:50:26

  Added:       ajax4jsf/1.0.4MR2  component-info.xml
  Log:
  Add ajax4jsf 1.0.4MR2
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 17:50:26;  author: dlloyd;  state: Exp;repository.jboss.com/ajax4jsf/1.0.4MR2/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="ajax4jsf-component-info">
  
  	<component id="ajax4jsf" 
  	 licenseType="cddl"
  	 version="1.0.4MR2"
  	 projectHome="https://ajax4jsf.dev.java.net/"
  	 description="AJAX interface for JSF">
  	 
  	<artifact id="ajax4jsf.jar"/>
  
  	<export>
  		<include input="ajax4jsf.jar"/>
  	</export>
  </component>
  </project>
  
  
  


From david.lloyd at jboss.com  Fri Dec  8 12:50:26 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 12:50:26 -0500
Subject: [jboss-cvs] repository.jboss.com/ajax4jsf/1.0.4MR2/lib  ...
Message-ID: <E1Gsjre-0007uO-Cv@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 12:50:26

  Added:       ajax4jsf/1.0.4MR2/lib  ajax4jsf.jar
  Log:
  Add ajax4jsf 1.0.4MR2
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 17:50:26;  author: dlloyd;  state: Exp;repository.jboss.com/ajax4jsf/1.0.4MR2/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 13:25:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 13:25:49 -0500
Subject: [jboss-cvs] JBossAS SVN: r58933 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test
Message-ID: <E1GskPt-0000DE-Ea@committer01.frg.pub.inap.atl.jboss.com>

Author: jerrygauth
Date: 2006-12-08 13:25:48 -0500 (Fri, 08 Dec 2006)
New Revision: 58933

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/DRMTestCase.java
Log:
JBAS-2560, JBAS-2470 - use GossipRouter to simulate merges

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/DRMTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/DRMTestCase.java	2006-12-08 16:29:56 UTC (rev 58932)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/DRMTestCase.java	2006-12-08 18:25:48 UTC (rev 58933)
@@ -26,19 +26,20 @@
 import java.security.SecureRandom;
 import java.util.ArrayList;
 import java.util.HashMap;
+import java.util.HashSet;
 import java.util.Iterator;
+import java.util.List;
 import java.util.Vector;
-import java.util.List;
-import java.util.HashSet;
 
 import javax.management.MBeanServer;
 import javax.management.MBeanServerFactory;
 import javax.management.MBeanServerInvocationHandler;
+import javax.management.Notification;
 import javax.management.ObjectName;
-import javax.management.Notification;
 
 import junit.framework.Test;
 
+import org.apache.log4j.Logger;
 import org.jboss.test.JBossClusteredTestCase;
 import org.jboss.test.cluster.drm.IReplicants;
 import org.jboss.test.cluster.drm.MockHAPartition;
@@ -46,11 +47,14 @@
 import org.jboss.ha.framework.interfaces.DistributedReplicantManager;
 import org.jboss.ha.framework.interfaces.DistributedReplicantManager.ReplicantListener;
 import org.jboss.ha.framework.server.DistributedReplicantManagerImpl;
+import org.jboss.ha.framework.server.HAPartitionImpl;
 import org.jboss.jmx.adaptor.rmi.RMIAdaptor;
 import org.jboss.jmx.adaptor.rmi.RMIAdaptorExt;
 import org.jboss.jmx.adaptor.rmi.RMINotificationListener;
+import org.jgroups.Channel;
+import org.jgroups.JChannel;
+import org.jgroups.stack.GossipRouter;
 import org.jgroups.stack.IpAddress;
-import org.apache.log4j.Logger;
 
 import EDU.oswego.cs.dl.util.concurrent.Semaphore;
 
@@ -62,6 +66,21 @@
  */
 public class DRMTestCase extends JBossClusteredTestCase
 {
+   private static final String SERVICEA = "serviceA";
+   private static final String SERVICEB = "serviceB";
+	
+   protected static final String CHANNEL_PROPS =
+	      "TUNNEL(router_port=4747;router_host=localhost;loopback=true):" +
+	      "PING(timeout=1000;num_initial_members=2;gossip_host=localhost;gossip_port=4747):" +
+	      "MERGE2(min_interval=3000;max_interval=5000):" +
+	      "FD(timeout=1000;max_tries=2;shun=false):" +
+	      "pbcast.NAKACK(gc_lag=50;retransmit_timeout=600,1200,2400,4800):" +
+	      "UNICAST(timeout=600,1200,2400):" +
+	      "pbcast.STABLE(desired_avg_gossip=20000):" +
+	      "pbcast.GMS(join_timeout=5000;join_retry_timeout=2000;" +
+	      "print_local_addr=false;shun=false):" +
+	      "pbcast.STATE_TRANSFER";
+   
    static class TestListener extends UnicastRemoteObject
       implements RMINotificationListener
    {
@@ -583,7 +602,9 @@
    
    /**
     * Tests the functionality of isMasterReplica(), also testing merge
-    * handling.
+    * handling.  This test creates and manipulates two HAPartition instances in memory 
+    * so it doesn't require a server deployment.  The partition instances communicate via
+    * a GossipRouter.  The router is stopped and restarted to simulate a merge condition.
     * 
     * TODO move this test out of the testsuite and into the cluster module
     *      itself, since it doesn't rely on the container.
@@ -592,116 +613,148 @@
     */
    public void testIsMasterReplica() throws Exception
    {
+	  MBeanServer mbeanServer1 = null;
+	  MBeanServer mbeanServer2 = null;
+	  JChannel channel1 = null;
+	  JChannel channel2 = null;
+	  GossipRouter router = null;
       log.debug("+++ testIsMasterReplica()");
-      
-      MBeanServer mbeanServer = 
-         MBeanServerFactory.createMBeanServer("mockPartition");
-      try {
-         ClusterNode localAddress = new ClusterNode(new IpAddress("127.0.0.1", 12345));
-         MockHAPartition partition = new MockHAPartition(localAddress);
-      
-         DistributedReplicantManagerImpl drm = 
-               new DistributedReplicantManagerImpl(partition, mbeanServer);
 
-         drm.init();
+      try
+      {  
+         String partitionName = "DRMTestCasePartition";
+         log.info("DRMTestCase.testIsMasterReplica() - starting GossipRouter");
+         router = new GossipRouter(4747, "localhost");
+    	 router.start();
          
-         // Create a fake view for the MockHAPartition
+	     mbeanServer1 = MBeanServerFactory.createMBeanServer("DRMTestCaseServer1");	      
+	     channel1 = createTestChannel(CHANNEL_PROPS);
+	     HAPartitionImpl partition1 = createTestPartition(partitionName, channel1, mbeanServer1, "DRMTestCaseNode1");
+	     
+	     mbeanServer2 = MBeanServerFactory.createMBeanServer("DRMTestCaseServer2");	      
+	     channel2 = createTestChannel(CHANNEL_PROPS);
+	     HAPartitionImpl partition2 = createTestPartition(partitionName, channel2, mbeanServer2, "DRMTestCaseNode2");
+	   
+         DistributedReplicantManager drm1 = partition1.getDistributedReplicantManager();
+         DistributedReplicantManager drm2 = partition2.getDistributedReplicantManager();
          
-         Vector remoteAddresses = new Vector();
-         for (int i = 1; i < 5; i++)
-            remoteAddresses.add(new ClusterNode(new IpAddress("127.0.0.1", 12340 + i)));
+         // confirm that each partition contains two nodes   
+         assertEquals("Partition1 should contain two nodes; ", 2, partition1.getCurrentView().size());
+         assertEquals("Partition2 should contain two nodes; ", 2, partition2.getCurrentView().size());
          
-         Vector allNodes = new Vector(remoteAddresses);
-         allNodes.add(localAddress);
-         partition.setCurrentViewClusterNodes(allNodes);
+	     drm1.add(SERVICEA, "valueA1");
+	     drm2.add(SERVICEA, "valueA2");
+	     drm2.add(SERVICEB, "valueB2");
+	     
+	     // test that only one node is the master replica for serviceA
+         assertTrue("ServiceA must have a master replica", 
+        		 drm1.isMasterReplica(SERVICEA) || drm2.isMasterReplica(SERVICEA));
+         assertTrue("ServiceA must have a single master replica", 
+        		 drm1.isMasterReplica(SERVICEA) != drm2.isMasterReplica(SERVICEA));
+ 
+         // ServiceB should only be a master replica on partition2
+         assertFalse("ServiceB should not be a master replica on partition1", 
+        		 drm1.isMasterReplica(SERVICEB));
+         assertTrue("ServiceB must have a master replica on partition2", 
+        		 drm2.isMasterReplica(SERVICEB));
          
-         // Pass fake state to DRMImpl
-      
-         HashMap replicants = new HashMap();
-         ArrayList remoteResponses = new ArrayList();
-         for (int i = 0; i < remoteAddresses.size(); i++)
-         {
-            ClusterNode node = (ClusterNode) remoteAddresses.elementAt(i);
-            Integer replicant = new Integer(i + 1);
-            replicants.put(node.getName(), replicant);
-            HashMap localReplicant = new HashMap();
-            localReplicant.put("Mock", replicant);
-            remoteResponses.add(new Object[] {node.getName(), localReplicant});
-         }
-         HashMap services = new HashMap();
-         services.put("Mock", replicants);
+         // confirm that each partition contains correct DRM replicants for services A and B  
+         assertEquals("Partition1 should contain two DRM replicants for serviceA; ", 
+        		 2, drm1.lookupReplicants(SERVICEA).size());
+         assertEquals("Partition2 should contain two DRM replicants for serviceA; ", 
+        		 2, drm2.lookupReplicants(SERVICEA).size());
+         assertEquals("Partition1 should contain one DRM replicant for serviceB; ", 
+        		 1, drm1.lookupReplicants(SERVICEB).size());
+         assertEquals("Partition2 should contain one DRM replicant for serviceB; ", 
+        		 1, drm2.lookupReplicants(SERVICEB).size());
+
+         // simulate a split of the partition
+         router.stop();
+         sleepThread(10000);
          
-         int hash = 0;
-         for (int i = 1; i < 5; i++)
-            hash += (new Integer(i)).hashCode();
+         // confirm that each partition contains one node   
+         assertEquals("Partition1 should contain one node after split; ", 
+        		 1, partition1.getCurrentView().size());
+         assertEquals("Partition2 should contain one node after split; ", 
+        		 1, partition2.getCurrentView().size());
+        
+         // confirm that each node is a master replica for serviceA after the split
+         assertTrue("ServiceA should be a master replica on partition1 after split", 
+        		 drm1.isMasterReplica(SERVICEA));
+         assertTrue("ServiceA should be a master replica on partition2 after split", 
+        		 drm2.isMasterReplica(SERVICEA));
          
-         HashMap intraviewIds = new HashMap();
-         intraviewIds.put("Mock", new Integer(hash));
-      
-         partition.setRemoteReplicants(remoteResponses);
+         // ServiceB should still only be a master replica on partition2 after split
+         assertFalse("ServiceB should not be a master replica on partition1 after split", 
+        		 drm1.isMasterReplica(SERVICEB));
+         assertTrue("ServiceB must have a master replica on partition2 after split", 
+        		 drm2.isMasterReplica(SERVICEB));
          
-         drm.setCurrentState(new Object[] {services, intraviewIds });
+         // Remove ServiceA replicant from partition1         
+         drm1.remove(SERVICEA);
          
-         drm.start();
+         // test that this node is not the master replica         
+         assertFalse("partition1 is not master replica after dropping ServiceA replicant", 
+        		 drm1.isMasterReplica(SERVICEA));
          
-         // add a local replicant
+         //Restore the local replicant         
+         drm1.add(SERVICEA, "valueA1a");
          
-         drm.add("Mock", new Integer(5));
-         
-         // test that this node is not the master replica
-         
-         assertFalse("Local node is not master after startup", 
-                     drm.isMasterReplica("Mock")); 
-      
-         // simulate a split where this node is the coord
-         
-         Vector localOnly = new Vector();
-         localOnly.add(localAddress);
-         
-         partition.setCurrentViewClusterNodes(localOnly);
-         partition.setRemoteReplicants(new ArrayList());
-         
-         drm.membershipChanged(remoteAddresses, new Vector(), localOnly);
-         
-         // test that this node is the master replica
-         
-         assertTrue("Local node is master after split", drm.isMasterReplica("Mock"));
-         
-         // Remove our local replicant
-         
-         drm.remove("Mock");
-         
-         // test that this node is not the master replica
-         
-         assertFalse("Local node is not master after dropping replicant", 
-                     drm.isMasterReplica("Mock"));
-         
-         // Restore the local replicant 
-         
-         drm.add("Mock", new Integer(5));
-         
          // simulate a merge
+         router.start();
+         // it seems to take more than 10 seconds for the merge to take effect
+         sleepThread(15000);
          
-         Vector mergeGroups = new Vector();
-         mergeGroups.add(remoteAddresses);
-         mergeGroups.add(localOnly);
+         // confirm that each partition contains two nodes again   
+         assertEquals("Partition1 should contain two nodes after merge; ", 
+        		 2, partition1.getCurrentView().size());
+         assertEquals("Partition2 should contain two nodes after merge; ", 
+        		 2, partition2.getCurrentView().size());
          
-         partition.setCurrentViewClusterNodes(allNodes);
-         partition.setRemoteReplicants(remoteResponses);
+	     // test that only one node is the master replica for serviceA after merge
+         assertTrue("ServiceA must have a master replica after merge", 
+        		 drm1.isMasterReplica(SERVICEA) || drm2.isMasterReplica(SERVICEA));
+         assertTrue("ServiceA must have a single master replica after merge", 
+        		 drm1.isMasterReplica(SERVICEA) != drm2.isMasterReplica(SERVICEA));
+ 
+         // ServiceB should only be a master replica on partition2 after merge
+         assertFalse("ServiceB should not be a master replica on partition1 after merge", 
+        		 drm1.isMasterReplica(SERVICEB));
+         assertTrue("ServiceB must have a master replica on partition2 after merge", 
+        		 drm2.isMasterReplica(SERVICEB));
          
-         drm.membershipChangedDuringMerge(new Vector(), remoteAddresses, 
-                                          allNodes, mergeGroups);         
+         // confirm that each partition contains correct DRM replicants for services A and B after merge 
+         assertEquals("Partition1 should contain two DRM replicants for serviceA after merge; ", 
+        		 2, drm1.lookupReplicants(SERVICEA).size());
+         assertEquals("Partition2 should contain two DRM replicants for serviceA after merge; ", 
+        		 2, drm2.lookupReplicants(SERVICEA).size());
+         assertEquals("Partition1 should contain one DRM replicant for serviceB after merge; ", 
+        		 1, drm1.lookupReplicants(SERVICEB).size());
+         assertEquals("Partition2 should contain one DRM replicant for serviceB after merge; ", 
+        		 1, drm2.lookupReplicants(SERVICEB).size());
          
-         // Merge processing is done asynchronously, so pause a bit
-         sleepThread(100);
-         
-         // test that this node is not the master replica
-         
-         assertFalse("Local node is not master after merge", 
-                     drm.isMasterReplica("Mock")); 
+         partition1.closePartition();
+         partition2.closePartition();
       }
-      finally {
-         MBeanServerFactory.releaseMBeanServer(mbeanServer);
+      finally
+      {
+         log.info("DRMTestCase.testIsMasterReplica() - cleaning up resources");
+         if (mbeanServer1 != null)
+    	    MBeanServerFactory.releaseMBeanServer(mbeanServer1);
+    	 if (mbeanServer2 != null)
+    	    MBeanServerFactory.releaseMBeanServer(mbeanServer2);
+    	 if (channel1 != null)
+    	 {
+    		 channel1.disconnect();
+    		 channel1.close();
+    	 }
+    	 if (channel2 != null)
+    	 {
+    		 channel2.disconnect();
+    		 channel2.close();
+    	 }
+         if (router != null)
+            router.stop();
       }
    }
    
@@ -1214,6 +1267,31 @@
       else
          return new ArrayList(toMask);
    }
+   
+   private JChannel createTestChannel(String props) throws Exception
+   {
+      JChannel channel = new JChannel(props);
+	  channel.setOpt(Channel.AUTO_RECONNECT, Boolean.TRUE);
+	  channel.setOpt(Channel.AUTO_GETSTATE, Boolean.TRUE);
+	  return channel;
+   }
+   
+   private HAPartitionImpl createTestPartition(String partitionName, JChannel channel, 
+		   									   MBeanServer server, String nodeName) throws Exception
+   {
+      // initialize HAPartition replicating logic from org.jboss.ha.framework.server.ClusterPartition
+      HAPartitionImpl partition = new HAPartitionImpl(partitionName, channel, false, server);
+	  // suppress JNDI binding else second instance will fail with NameAlreadyBound exception
+	  partition.setBindIntoJndi(false);
+	  partition.init();
+	  HashMap staticNodeName = new java.util.HashMap();
+	  staticNodeName.put("additional_data", nodeName.getBytes());
+	  channel.down(new org.jgroups.Event(org.jgroups.Event.CONFIG, staticNodeName));
+	  channel.getProtocolStack().flushEvents();
+	  channel.connect(partitionName);
+	  partition.startPartition();
+      return partition;
+   }
 
    private static void sleepThread(long millis)
    {



From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:05 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:05 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-entitymanager/3.2.1.GA -
	New directory ...
Message-ID: <E1Gskan-0000RI-74@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:05

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-entitymanager/3.2.1.GA added to the repository


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:07 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:07 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-entitymanager/3.2.1.GA/lib
	- New directory ...
Message-ID: <E1Gskap-0000RX-C4@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-entitymanager/3.2.1.GA/lib added to the repository


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:23 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:23 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-entitymanager/3.2.1.GA ...
Message-ID: <E1Gskb5-0000SG-Pg@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:23

  Added:       hibernate-entitymanager/3.2.1.GA  component-info.xml
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 18:37:23;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-entitymanager/3.2.1.GA/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="hibernate-entitymanager-component-info">
     <component id="hibernate-entitymanager"
                version="3.2.1.GA"
                licenseType="lgpl"
                projectHome="http://entitymanager.hibernate.org/"
                description="Hibernate EntityManager for EJB3"
        >
        <artifact id="hibernate-entitymanager.jar"/>
        <artifact id="ejb3-persistence.jar"/>
        <import componentref="hibernate">
  	     <compatible version="3.2.0.GA"/>
           <compatible version="3.2.1.GA"/>
        </import>
        <import componentref="hibernate-annotations">
           <compatible version="3.2.1.GA"/>
        </import>
        <export>
           <include input="hibernate-entitymanager.jar"/>
           <include input="ejb3-persistence.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:23 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:23 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-entitymanager/3.2.1.GA/lib
	...
Message-ID: <E1Gskb5-0000SO-Uh@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:23

  Added:       hibernate-entitymanager/3.2.1.GA/lib   ejb3-persistence.jar
                        hibernate-entitymanager.jar
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 18:37:23;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-entitymanager/3.2.1.GA/lib/ejb3-persistence.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 18:37:23;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-entitymanager/3.2.1.GA/lib/hibernate-entitymanager.jar
  
  	<<Binary file>>
  
  


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:29 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:29 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-annotations/3.2.1.GA - New
	directory ...
Message-ID: <E1GskbB-0000SX-Kk@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:29

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-annotations/3.2.1.GA added to the repository


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:32 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:32 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-annotations/3.2.1.GA/lib -
	New directory ...
Message-ID: <E1GskbE-0000Sg-DD@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:32

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/hibernate-annotations/3.2.1.GA/lib added to the repository


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:56 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:56 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-annotations/3.2.1.GA  ...
Message-ID: <E1Gskbc-0000Sz-SM@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:56

  Added:       hibernate-annotations/3.2.1.GA  component-info.xml
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 18:37:56;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-annotations/3.2.1.GA/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="hibernate-annotations-component-info">
     <component id="hibernate-annotations"
                 licenseType="lgpl"
                 version="3.2.1.GA"
                 projectHome="http://annotations.hibernate.org"
        description="Annotations for Hibernate/EJB3"
      >
        <artifact id="hibernate-annotations.jar"/>
        <import componentref="hibernate">
           <compatible version="3.2.0.GA"/>
  		 <compatible version="3.2.1.GA"/>
        </import>
        <export>
           <include input="hibernate-annotations.jar"/>         
        </export>
        
     </component>
  
  </project>
  
  
  


From emmanuel.bernard at jboss.com  Fri Dec  8 13:37:56 2006
From: emmanuel.bernard at jboss.com (Emmanuel Bernard)
Date: Fri, 08 Dec 2006 13:37:56 -0500
Subject: [jboss-cvs] repository.jboss.com/hibernate-annotations/3.2.1.GA/lib
	...
Message-ID: <E1Gskbc-0000T5-VV@committer01.frg.pub.inap.atl.jboss.com>

  User: ebernard
  Date: 06/12/08 13:37:56

  Added:       hibernate-annotations/3.2.1.GA/lib 
                        hibernate-annotations.jar
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 18:37:56;  author: ebernard;  state: Exp;repository.jboss.com/hibernate-annotations/3.2.1.GA/lib/hibernate-annotations.jar
  
  	<<Binary file>>
  
  


From genman at noderunner.net  Fri Dec  8 13:49:17 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:17 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader   ...
Message-ID: <E1Gskmb-0000eg-41@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:17

  Modified:    src/org/jboss/cache/loader   FileCacheLoader.java
                        AsyncCacheLoader.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.27      +3 -3      JBossCache/src/org/jboss/cache/loader/FileCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FileCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/FileCacheLoader.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- FileCacheLoader.java	23 Nov 2006 16:07:38 -0000	1.26
  +++ FileCacheLoader.java	8 Dec 2006 18:49:17 -0000	1.27
  @@ -1,6 +1,5 @@
   package org.jboss.cache.loader;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
  @@ -20,12 +19,13 @@
   import java.util.Set;
   import java.util.regex.Pattern;
   import java.util.regex.Matcher;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Simple file-based CacheLoader implementation. Nodes are directories, attributes of a node is a file in the directory
    *
    * @author Bela Ban
  - * @version $Id: FileCacheLoader.java,v 1.26 2006/11/23 16:07:38 gzamarreno Exp $
  + * @version $Id: FileCacheLoader.java,v 1.27 2006/12/08 18:49:17 genman Exp $
    */
   public class FileCacheLoader extends AbstractCacheLoader
   {
  @@ -372,7 +372,7 @@
         {
            if (config.isCheckCharacterPortability())
            {
  -            /* Check whether the entire file path (root + fqn + data file name), is lenght portable */
  +            /* Check whether the entire file path (root + fqn + data file name), is length portable */
               isLengthPortablePath(child.getAbsolutePath());
               /* Check whether the fqn tree we're trying to store could contain non portable characters */
               isCharacterPortableTree(fqn);            
  
  
  
  1.24      +12 -10    JBossCache/src/org/jboss/cache/loader/AsyncCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/AsyncCacheLoader.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- AsyncCacheLoader.java	20 Nov 2006 07:33:14 -0000	1.23
  +++ AsyncCacheLoader.java	8 Dec 2006 18:49:17 -0000	1.24
  @@ -3,9 +3,6 @@
    */
   package org.jboss.cache.loader;
   
  -import EDU.oswego.cs.dl.util.concurrent.BoundedLinkedQueue;
  -import EDU.oswego.cs.dl.util.concurrent.SynchronizedBoolean;
  -import EDU.oswego.cs.dl.util.concurrent.SynchronizedInt;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  @@ -20,6 +17,11 @@
   import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
  +import java.util.concurrent.BlockingQueue;
  +import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.atomic.AtomicInteger;
  +import java.util.concurrent.atomic.AtomicBoolean;
   
   /**
    * The AsyncCacheLoader is a delegating cache loader that extends
  @@ -81,7 +83,7 @@
   
      private static final Log log = LogFactory.getLog(AsyncCacheLoader.class);
   
  -   private static SynchronizedInt threadId = new SynchronizedInt(0);
  +   private static AtomicInteger threadId = new AtomicInteger(0);
      
   
      /**
  @@ -91,8 +93,8 @@
   
      private AsynchCacheLoaderConfig config;
      private AsyncProcessor processor;
  -   private SynchronizedBoolean stopped = new SynchronizedBoolean(true);
  -   private BoundedLinkedQueue queue = new BoundedLinkedQueue(DEFAULT_QUEUE_SIZE);
  +   private AtomicBoolean stopped = new AtomicBoolean(true);
  +   private BlockingQueue<Modification> queue = new LinkedBlockingQueue(DEFAULT_QUEUE_SIZE);
   
   
      public AsyncCacheLoader()
  @@ -118,7 +120,7 @@
   
         if (config.getQueueSize() > 0)
         {
  -         queue = new BoundedLinkedQueue(config.getQueueSize());
  +         queue = new LinkedBlockingQueue(config.getQueueSize());
         }
   
         super.setConfig(base);
  @@ -270,7 +272,7 @@
         {
            if (t == null || !t.isAlive())
            {
  -            t = new Thread(this, "AsyncCacheLoader-" + threadId.increment());
  +            t = new Thread(this, "AsyncCacheLoader-" + threadId.getAndIncrement());
               //t.setDaemon(true);
               t.start();
            }
  @@ -332,7 +334,7 @@
            addTaken(o);
            while (mods.size() < config.getBatchSize())
            {
  -            o = queue.poll(config.getPollWait());
  +            o = queue.poll(config.getPollWait(), TimeUnit.MILLISECONDS);
               if (o == null)
               {
                  break;
  @@ -390,7 +392,7 @@
                " pollWait=" + config.getPollWait() +
                " returnOld=" + config.getReturnOld() +
                " asyncPut=" + config.getUseAsyncPut() +
  -             " queue.capacity()=" + queue.capacity() +
  +             " queue.remainingCapacity()=" + queue.remainingCapacity() +
                " queue.peek()=" + queue.peek();
      }
   
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:17 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:17 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors         ...
Message-ID: <E1Gskmb-0000f8-B8@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:17

  Modified:    src/org/jboss/cache/interceptors        
                        CreateIfNotExistsInterceptor.java
                        PassivationInterceptor.java
                        CacheStoreInterceptor.java
                        DataGravitatorInterceptor.java
                        ActivationInterceptor.java
                        OptimisticReplicationInterceptor.java
                        CacheMgmtInterceptor.java TxInterceptor.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.20      +28 -28    JBossCache/src/org/jboss/cache/interceptors/CreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CreateIfNotExistsInterceptor.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- CreateIfNotExistsInterceptor.java	30 Aug 2006 17:08:18 -0000	1.19
  +++ CreateIfNotExistsInterceptor.java	8 Dec 2006 18:49:17 -0000	1.20
  @@ -1,6 +1,5 @@
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.ReentrantLock;
   import org.jboss.cache.CacheException;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  @@ -10,6 +9,7 @@
   import org.jboss.cache.marshall.MethodCallFactory;
   import org.jboss.cache.marshall.MethodDeclarations;
   
  +import java.util.concurrent.locks.ReentrantLock;
   import java.util.ArrayList;
   import java.util.Iterator;
   
  @@ -18,8 +18,8 @@
    * (depending on the create_if_not_exists argument)
    *
    * @author Bela Ban
  - * @version $Id: CreateIfNotExistsInterceptor.java,v 1.19 2006/08/30 17:08:18 msurtani Exp $
  - * @deprecated This code is not used anymore and will be removed in a future release
  + * @version $Id: CreateIfNotExistsInterceptor.java,v 1.20 2006/12/08 18:49:17 genman Exp $
  + * @deprecated This code is not used anymore and will be removed in a future unlock
    */
   public class CreateIfNotExistsInterceptor extends Interceptor
   {
  @@ -79,7 +79,7 @@
   //            if(fqn == null)
   //               throw new CacheException("failed extracting FQN from method " + m);
   //
  -//            lock.acquire();
  +//            lock.lockInterruptibly();
   //            if(isPut) { // lock needs to be held across puts()
   //               if(!cache.exists(fqn)) {
   //                  GlobalTransaction gtx=cache.getCurrentTransaction();
  @@ -89,13 +89,13 @@
   //                  // lock(fqn, DataNode.LOCK_TYPE_WRITE, false);
   //               }
   //               else
  -//                  lock.release();
  +//                  lock.unlock();
   //            }
   //            return super.invoke(m);
   //         }
   //         finally {
   //            if(lock.holds() > 0)
  -//               lock.release();  // release lock for put()
  +//               lock.unlock();  // unlock lock for put()
   //         }
   //      }
   //      return super.invoke(m); // no locks held for non put()/remove()/evict() methods (e.g. for get() methods)
  @@ -148,16 +148,16 @@
            { // remove() or evict(): wait until all puts() that work on the same subtree have completed
               try
               {
  -               findAndBlockOnPut(fqn, put_lock);  // does NOT release put_lock !
  +               findAndBlockOnPut(fqn, put_lock);  // does NOT unlock put_lock !
                  addFqnToRemoveList(fqn, remove_lock);
  -               put_lock.release();
  -               // we only release now because waiting on the put-list and adding to remove-list need to be atomic ! 
  +               put_lock.unlock();
  +               // we only unlock now because waiting on the put-list and adding to remove-list need to be atomic ! 
                  return super.invoke(m);
               }
               finally
               {
  -               if (put_lock.holds() > 0)
  -                  put_lock.release();
  +               if (put_lock.isHeldByCurrentThread())
  +                  put_lock.unlock();
                  removeFqnFromRemoveList(fqn, remove_lock);
               }
            }
  @@ -169,7 +169,7 @@
      /**
       * Finds all FQNs in the put_list form which <code>fqn</code> is a parent (or equals), and waits on them.
       * Loops until no more matching FQNs are found or the list is empty.<p/>
  -    * <em>Don't</em> release the lock, the caller will release it !
  +    * <em>Don't</em> unlock the lock, the caller will unlock it !
       *
       * @param fqn
       * @param lock
  @@ -181,7 +181,7 @@
         while (true)
         {
            //try {
  -         lock.acquire();
  +         lock.lockInterruptibly();
            tmp = findFqnInPutList(fqn);
            if (tmp == null) // put_list is empty, or fqn has not been found
               return;
  @@ -189,7 +189,7 @@
               log.trace("found " + tmp + " in put-list, waiting");
            synchronized (tmp)
            {
  -            lock.release();
  +            lock.unlock();
               tmp.wait();
            }
            if (log.isTraceEnabled())
  @@ -197,7 +197,7 @@
            //}
            //finally {
            // if(lock.holds() > 0)
  -         //  lock.release();
  +         //  lock.unlock();
            //}
         }
      }
  @@ -215,7 +215,7 @@
         Fqn tmp;
         while (true)
         {
  -         lock.acquire();
  +         lock.lockInterruptibly();
            try
            {
               tmp = findFqnInRemoveList(fqn);
  @@ -225,7 +225,7 @@
                  log.trace("found " + tmp + " in remove-list, waiting");
               synchronized (tmp)
               {
  -               lock.release();
  +               lock.unlock();
                  tmp.wait();
               }
               if (log.isTraceEnabled())
  @@ -233,7 +233,7 @@
            }
            finally
            {
  -            lock.release();
  +            lock.unlock();
            }
         }
      }
  @@ -266,7 +266,7 @@
      private void addFqnToPutList(Fqn fqn, ReentrantLock lock)
              throws InterruptedException
      {
  -      lock.acquire();
  +      lock.lockInterruptibly();
         try
         {
            if (!put_list.contains(fqn))
  @@ -278,14 +278,14 @@
         }
         finally
         {
  -         lock.release();
  +         lock.unlock();
         }
      }
   
      private void addFqnToRemoveList(Fqn fqn, ReentrantLock lock)
              throws InterruptedException
      {
  -      lock.acquire();
  +      lock.lockInterruptibly();
         try
         {
            if (!remove_list.contains(fqn))
  @@ -297,7 +297,7 @@
         }
         finally
         {
  -         lock.release();
  +         lock.unlock();
         }
      }
   
  @@ -305,13 +305,13 @@
      private void removeFqnFromPutList(Fqn fqn, ReentrantLock lock)
              throws InterruptedException
      {
  -      lock.acquire();
  +      lock.lockInterruptibly();
         try
         {
            if (log.isTraceEnabled())
               log.trace("removing " + fqn + " from put-list (size=" + put_list.size() + ")");
            put_list.remove(fqn);
  -         lock.release();
  +         lock.unlock();
            synchronized (fqn)
            {
               fqn.notifyAll();
  @@ -319,20 +319,20 @@
         }
         finally
         {
  -         lock.release();
  +         lock.unlock();
         }
      }
   
      private void removeFqnFromRemoveList(Fqn fqn, ReentrantLock lock)
              throws InterruptedException
      {
  -      lock.acquire();
  +      lock.lockInterruptibly();
         try
         {
            if (log.isTraceEnabled())
               log.trace("removing " + fqn + " from remove-list (size=" + remove_list.size() + ")");
            remove_list.remove(fqn);
  -         lock.release();
  +         lock.unlock();
            synchronized (fqn)
            {
               fqn.notifyAll();
  @@ -340,7 +340,7 @@
         }
         finally
         {
  -         lock.release();
  +         lock.unlock();
         }
      }
   
  
  
  
  1.34      +4 -6      JBossCache/src/org/jboss/cache/interceptors/PassivationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PassivationInterceptor.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- PassivationInterceptor.java	29 Nov 2006 22:10:22 -0000	1.33
  +++ PassivationInterceptor.java	8 Dec 2006 18:49:17 -0000	1.34
  @@ -1,11 +1,9 @@
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.SynchronizedLong;
  +import java.util.concurrent.atomic.AtomicLong;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
  @@ -18,13 +16,13 @@
    * CacheLoader, either before each method call (no TXs), or at TX commit.
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationInterceptor.java,v 1.33 2006/11/29 22:10:22 genman Exp $
  + * @version $Id: PassivationInterceptor.java,v 1.34 2006/12/08 18:49:17 genman Exp $
    */
   public class PassivationInterceptor extends Interceptor implements PassivationInterceptorMBean
   {
      
      protected CacheLoader loader = null;
  -   private SynchronizedLong m_passivations = new SynchronizedLong(0);
  +   private AtomicLong m_passivations = new AtomicLong(0);
   
      public synchronized void setCache(CacheSPI cache)
      {
  @@ -68,7 +66,7 @@
               
               if (getStatisticsEnabled() && configuration.getExposeManagementStatistics())
               {
  -               m_passivations.increment();
  +               m_passivations.getAndIncrement();
               }
            }
            catch (NodeNotLoadedException e)
  
  
  
  1.39      +2 -2      JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheStoreInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -b -r1.38 -r1.39
  --- CacheStoreInterceptor.java	16 Nov 2006 15:40:44 -0000	1.38
  +++ CacheStoreInterceptor.java	8 Dec 2006 18:49:17 -0000	1.39
  @@ -1,6 +1,5 @@
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.jboss.cache.CacheException;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  @@ -21,13 +20,14 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Writes modifications back to the store on the way out: stores modifications back
    * through the CacheLoader, either after each method call (no TXs), or at TX commit.
    *
    * @author Bela Ban
  - * @version $Id: CacheStoreInterceptor.java,v 1.38 2006/11/16 15:40:44 msurtani Exp $
  + * @version $Id: CacheStoreInterceptor.java,v 1.39 2006/12/08 18:49:17 genman Exp $
    */
   public class CacheStoreInterceptor extends BaseCacheLoaderInterceptor implements CacheStoreInterceptorMBean
   {
  
  
  
  1.30      +11 -9     JBossCache/src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataGravitatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- DataGravitatorInterceptor.java	20 Nov 2006 03:53:54 -0000	1.29
  +++ DataGravitatorInterceptor.java	8 Dec 2006 18:49:17 -0000	1.30
  @@ -6,7 +6,6 @@
    */
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  @@ -17,7 +16,6 @@
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
   import org.jboss.cache.TransactionEntry;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.buddyreplication.BuddyManager;
   import org.jboss.cache.buddyreplication.GravitateResult;
   import org.jboss.cache.config.Configuration;
  @@ -35,16 +33,20 @@
   import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
  - * The Data Gravitator interceptor intercepts cache misses and attempts t gravitate data from other parts of the cluster.
  + * The Data Gravitator interceptor intercepts cache misses and attempts t
  + * gravitate data from other parts of the cluster.
    * <p/>
  - * Only used if Buddy Replication is enabled.  Also, the interceptor only kicks in if an {@link org.jboss.cache.config.Option} is passed in to
  - * force Data Gravitation for a specific invocation or if <b>autoDataGravitation</b> is set to <b>true</b> when configuring
  - * Buddy Replication.
  + * Only used if Buddy Replication is enabled.  Also, the interceptor only kicks
  + * in if an {@link org.jboss.cache.config.Option} is passed in to force Data
  + * Gravitation for a specific invocation or if <b>autoDataGravitation</b> is
  + * set to <b>true</b> when configuring Buddy Replication.
    * <p/>
  - * See the JBoss Cache User Guide for more details on configuration options.  There is a section dedicated to Buddy Replication
  - * in the Replication chapter.
  + * See the JBoss Cache User Guide for more details on configuration options.
  + * There is a section dedicated to Buddy Replication in the Replication
  + * chapter.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  
  
  
  1.43      +2 -4      JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActivationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- ActivationInterceptor.java	29 Nov 2006 22:10:22 -0000	1.42
  +++ ActivationInterceptor.java	8 Dec 2006 18:49:17 -0000	1.43
  @@ -1,14 +1,11 @@
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Modification;
   import org.jboss.cache.Node;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
   
  @@ -20,6 +17,7 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Loads nodes that don't exist at the time of the call into memory from the CacheLoader.
  @@ -27,7 +25,7 @@
    * their attributes have been initialized and their children have been loaded in memory.
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: ActivationInterceptor.java,v 1.42 2006/11/29 22:10:22 genman Exp $
  + * @version $Id: ActivationInterceptor.java,v 1.43 2006/12/08 18:49:17 genman Exp $
    */
   public class ActivationInterceptor extends CacheLoaderInterceptor implements ActivationInterceptorMBean
   {
  
  
  
  1.31      +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticReplicationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- OptimisticReplicationInterceptor.java	6 Dec 2006 16:28:37 -0000	1.30
  +++ OptimisticReplicationInterceptor.java	8 Dec 2006 18:49:17 -0000	1.31
  @@ -6,7 +6,6 @@
    */
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.jboss.cache.CacheException;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
  @@ -26,6 +25,7 @@
   import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Replication interceptor for the optimistically locked interceptor chain
  
  
  
  1.24      +4 -4      JBossCache/src/org/jboss/cache/interceptors/CacheMgmtInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheMgmtInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheMgmtInterceptor.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- CacheMgmtInterceptor.java	18 Oct 2006 11:07:55 -0000	1.23
  +++ CacheMgmtInterceptor.java	8 Dec 2006 18:49:17 -0000	1.24
  @@ -21,7 +21,6 @@
    */
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.SynchronizedLong;
   import org.jboss.cache.CacheListener;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  @@ -38,12 +37,13 @@
   import javax.management.NotificationListener;
   import java.util.HashMap;
   import java.util.Map;
  +import java.util.concurrent.atomic.AtomicLong;
   
   /**
    * Captures cache management statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: CacheMgmtInterceptor.java,v 1.23 2006/10/18 11:07:55 msurtani Exp $
  + * @version $Id: CacheMgmtInterceptor.java,v 1.24 2006/12/08 18:49:17 genman Exp $
    */
   public class CacheMgmtInterceptor extends Interceptor implements CacheMgmtInterceptorMBean, NotificationBroadcaster
   {
  @@ -80,7 +80,7 @@
      private static final String NOTIFICATION_NAME = Notification.class.getName();
      private static final String NOTIFICATION_DESCR = "JBossCache event notifications";
   
  -   private SynchronizedLong m_seq = new SynchronizedLong(0);
  +   private AtomicLong m_seq = new AtomicLong(0);
      private int m_listeners = 0;
      private long m_hit_times = 0;
      private long m_miss_times = 0;
  @@ -343,7 +343,7 @@
      {
         private long seq()
         {
  -         return m_seq.increment();
  +         return m_seq.getAndIncrement();
         }
   
         public void cacheStarted(CacheSPI cache)
  
  
  
  1.67      +1 -2      JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java,v
  retrieving revision 1.66
  retrieving revision 1.67
  diff -u -b -r1.66 -r1.67
  --- TxInterceptor.java	20 Nov 2006 03:53:54 -0000	1.66
  +++ TxInterceptor.java	8 Dec 2006 18:49:17 -0000	1.67
  @@ -6,7 +6,6 @@
    */
   package org.jboss.cache.interceptors;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.jboss.cache.CacheException;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.GlobalTransaction;
  @@ -14,7 +13,6 @@
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.ReplicationException;
   import org.jboss.cache.TransactionEntry;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.marshall.MethodCall;
  @@ -30,6 +28,7 @@
   import java.util.HashMap;
   import java.util.List;
   import java.util.Map;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * This interceptor is the new default at the head of all interceptor chains,
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:17 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:17 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache     ...
Message-ID: <E1Gskmb-0000fO-JI@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:17

  Modified:    src/org/jboss/cache     TransactionTable.java
                        RegionImpl.java Region.java TreeCache.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.11      +2 -4      JBossCache/src/org/jboss/cache/TransactionTable.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTable.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionTable.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- TransactionTable.java	20 Nov 2006 03:53:54 -0000	1.10
  +++ TransactionTable.java	8 Dec 2006 18:49:17 -0000	1.11
  @@ -7,10 +7,8 @@
   package org.jboss.cache;
   
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.lock.IdentityLock;
   import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.marshall.MethodCall;
   
  @@ -18,7 +16,7 @@
   import java.util.Collection;
   import java.util.Iterator;
   import java.util.Map;
  -
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Maintains the mapping between local (Transaction) and global transactions
  @@ -26,7 +24,7 @@
    * given TX.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public class TransactionTable {
   
  
  
  
  1.15      +35 -61    JBossCache/src/org/jboss/cache/RegionImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/RegionImpl.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- RegionImpl.java	16 Nov 2006 18:15:26 -0000	1.14
  +++ RegionImpl.java	8 Dec 2006 18:49:17 -0000	1.15
  @@ -6,7 +6,10 @@
    */
   package org.jboss.cache;
   
  -import EDU.oswego.cs.dl.util.concurrent.BoundedLinkedQueue;
  +import java.util.concurrent.BlockingQueue;
  +import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.TimeUnit;
  +
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.config.EvictionRegionConfig;
  @@ -25,20 +28,17 @@
   {
      private static final Log log = LogFactory.getLog(RegionImpl.class);
   
  -   RegionManager regionManager;
  -   Fqn fqn;
  -   boolean active;
  -   ClassLoader classLoader;
  -   BoundedLinkedQueue nodeEventQueue_;
  -   int checkCapacityCount = 0;
  -   int capacityWarnThreshold = 0;
  -   EvictionRegionConfig configuration = new EvictionRegionConfig();
  -   EvictionPolicy policy;
  +   private RegionManager regionManager;
  +   private Fqn fqn;
  +   private boolean active;
  +   private ClassLoader classLoader;
  +   private BlockingQueue<EvictedEventNode> nodeEventQueue = null;
  +   private int capacityWarnThreshold = 0;
  +   private EvictionRegionConfig configuration = new EvictionRegionConfig();
  +   private EvictionPolicy policy;
   
      /**
  -    * Creates a MarshRegion from an fqn and registers the region in the region registry.
  -    *
  -    * @param fqn
  +    * Constructs a marshalling region from an fqn and region manager.
       */
      public RegionImpl(Fqn fqn, RegionManager regionManager)
      {
  @@ -48,17 +48,13 @@
      }
   
      /**
  -    * Constructor that creates an eviction region
  -    *
  -    * @param policy
  -    * @param config
  +    * Constructs an eviction region from a policy and configuration, defined by an fqn and region manager.
       */
      public RegionImpl(EvictionPolicy policy, EvictionRegionConfig config, Fqn fqn, RegionManager regionManager)
      {
         this(fqn, regionManager);
         this.configuration = config;
         this.policy = policy;
  -
         createQueue();
      }
   
  @@ -129,33 +125,23 @@
                 '}';
      }
   
  -   public int compareTo(Object o)
  -   {
  -      if (o instanceof Region)
  +   public int compareTo(Region other)
         {
  -         Region other = (Region) o;
            return getFqn().compareTo(other.getFqn());
         }
  -      return 1;
  -   }
   
      public void putNodeEvent(EvictedEventNode event)
      {
  -      if (nodeEventQueue_ == null) createQueue();
         try
         {
  -         // Don't check capacity every time as this is an expensive operation for
  -         // bounded buffer type objects in this situation
  -         if (++checkCapacityCount > 100)
  -         {
  -            checkCapacityCount = 0;
  -            if (nodeEventQueue_.size() > capacityWarnThreshold)
  +         if (nodeEventQueue.size() > capacityWarnThreshold)
               {
  -               log.warn("putNodeEvent(): eviction node event queue size is at 98% threshold value of capacity: " + configuration.getEventQueueSize() + " You will need to reduce the wakeUpIntervalSeconds parameter.");
  -            }
  +            log.warn("putNodeEvent(): eviction node event queue size is at 98% threshold value of capacity: " + configuration.getEventQueueSize() +
  +                  " Region: " + fqn +
  +                  " You will need to reduce the wakeUpIntervalSeconds parameter.");
            }
   
  -         nodeEventQueue_.put(event);
  +         nodeEventQueue.put(event);
         }
         catch (InterruptedException e)
         {
  @@ -164,16 +150,14 @@
      }
   
      /**
  -    * Take the last node from node queue. It will also
  -    * remove it from the queue.
  -    *
  -    * @return The EvictedEventNode
  +    * Returns and removes the last event from event queue.
  +    * If no more events exists, returns null. May also return null if interrupted.
       */
      public EvictedEventNode takeLastEventNode()
      {
         try
         {
  -         return (EvictedEventNode) nodeEventQueue_.poll(0);
  +         return nodeEventQueue.poll(0, TimeUnit.SECONDS);
         }
         catch (InterruptedException e)
         {
  @@ -184,37 +168,25 @@
   
      public int nodeEventQueueSize()
      {
  -      return nodeEventQueue_.size();
  +      return nodeEventQueue.size();
      }
   
      public void resetEvictionQueues()
      {
  -      BoundedLinkedQueue q1 = nodeEventQueue_;
  -      log.info("reseteEvictionQueues(): node queue size: " + q1.size() +
  -              " region name: " + getFqn());
  -      createQueue();
  -      // Help to recycle
  -      for (int i = 0; i < q1.size(); i++)
  -      {
  -         try
  -         {
  -            q1.take();
  -         }
  -         catch (InterruptedException e)
  -         {
  -            e.printStackTrace();
  -         }
  -      }
  +      nodeEventQueue.clear();
      }
   
      private void createQueue()
      {
  -      capacityWarnThreshold = (98 * configuration.getEventQueueSize()) / 100 - 100;
  +      if (configuration == null)
  +         throw new IllegalArgumentException("null eviction configuration");
  +      int size = configuration.getEventQueueSize();
  +      capacityWarnThreshold = (98 * size) / 100 - 100;
         if (capacityWarnThreshold <= 0)
         {
            throw new RuntimeException("Capacity warn threshold used in eviction is smaller than 1.");
         }
  -      nodeEventQueue_ = new BoundedLinkedQueue(configuration.getEventQueueSize());
  +      nodeEventQueue = new LinkedBlockingQueue<EvictedEventNode>(size);
      }
   
      public EvictionRegionConfig getEvictionRegionConfig()
  @@ -237,11 +209,13 @@
         configuration.setEvictionPolicyConfig(evictionPolicyConfig);
         policy = createPolicy(evictionPolicyConfig.getEvictionPolicyClass());
         regionManager.getEvictionTimerTask().addRegionToProcess(this);
  -      if (nodeEventQueue_ == null) createQueue();
  +      if (nodeEventQueue == null) createQueue();
      }
   
      private EvictionPolicy createPolicy(String className)
      {
  +      if (className == null)
  +         throw new IllegalArgumentException("null className");
         try
         {
            if (log.isTraceEnabled()) log.trace("Instantiating " + className);
  
  
  
  1.9       +1 -1      JBossCache/src/org/jboss/cache/Region.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Region.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Region.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- Region.java	15 Nov 2006 23:48:31 -0000	1.8
  +++ Region.java	8 Dec 2006 18:49:17 -0000	1.9
  @@ -17,7 +17,7 @@
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  -public interface Region extends Comparable
  +public interface Region extends Comparable<Region>
   {
      /**
       * Registers a specific {@link ClassLoader} (rather than the default) for a region, represented by a {@link Fqn}.
  
  
  
  1.291     +46 -38    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.290
  retrieving revision 1.291
  diff -u -b -r1.290 -r1.291
  --- TreeCache.java	7 Dec 2006 22:20:23 -0000	1.290
  +++ TreeCache.java	8 Dec 2006 18:49:17 -0000	1.291
  @@ -94,7 +94,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.290 2006/12/07 22:20:23 vblagojevic Exp $
  + * @version $Id: TreeCache.java,v 1.291 2006/12/08 18:49:17 genman Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -145,7 +145,7 @@
      /**
       * JGroups message listener.
       */
  -   protected MessageListener ml = new MessageListenerAdaptor(log);
  +   protected MessageListenerAdaptor ml = new MessageListenerAdaptor(log);
   
      /**
       * Maintains mapping of transactions (keys) and Modifications/Undo-Operations
  @@ -168,12 +168,6 @@
       */
      protected boolean isStateSet = false;
   
  -   /**
  -    * An exception occuring upon fetch state.
  -    */
  -   protected Exception setStateException;
  -   private final Object stateLock = new Object();
  -
      protected String evictionInterceptorClass = "org.jboss.cache.interceptors.EvictionInterceptor";
   
      /**
  @@ -193,31 +187,24 @@
       */
      protected TransactionManagerLookup tm_lookup = null;
   
  -
      /**
       * Used to get the Transaction associated with the current thread
       */
      protected TransactionManager tm = null;
   
  -
      protected CacheLoaderManager cacheLoaderManager;
  +
      /**
       * for legacy use *
       */
      protected CacheLoaderConfig cloaderConfig;
   
  -
      /**
       * Queue used to replicate updates when mode is repl-async
       */
      protected ReplicationQueue repl_queue = null;
   
      /**
  -    * Determines whether to use optimistic locking or not.  Disabled by default.
  -    */
  -   protected boolean nodeLockingOptimistic = false;
  -
  -   /**
       * create was called.
       */
      protected boolean useCreateService = false;
  @@ -1208,24 +1195,7 @@
         boolean rc = channel.getState(null, stateFetchTimeout);
         if (rc)
         {
  -         synchronized (stateLock)
  -         {
  -            while (!isStateSet)
  -            {
  -               if (setStateException != null)
  -               {
  -                  throw setStateException;
  -               }
  -
  -               try
  -               {
  -                  stateLock.wait();
  -               }
  -               catch (InterruptedException iex)
  -               {
  -               }
  -            }
  -         }
  +         ml.waitForState();
            stop = System.currentTimeMillis();
            if (log.isDebugEnabled())
            {
  @@ -3000,7 +2970,7 @@
               log.error("releaseAllLocks(): node " + fqn + " not found");
               return;
            }
  -         n.releaseAllForce();
  +         releaseAll(n);
         }
         catch (Throwable t)
         {
  @@ -3008,6 +2978,16 @@
         }
      }
   
  +   private void releaseAll(Node n)
  +   {
  +      for (Node child : n.getChildren())
  +      {
  +         releaseAll(child);
  +      }
  +      n.getNodeSPI().getLock().releaseAll();
  +   }
  +
  +   
      /**
       * Finds and returns the {@link org.jboss.cache.DataNode#toString()} value for the Fqn.
       * Returns null if not found or upon error.
  @@ -3211,12 +3191,40 @@
         final Log my_log;   // Need this to run under jdk1.3
         final boolean trace;
   
  +      /**
  +       * An exception occuring upon fetch state.
  +       */
  +      protected Exception setStateException;
  +      private final Object stateLock = new Object();
  +
         MessageListenerAdaptor(Log log)
         {
            this.my_log = log;
            this.trace = my_log.isTraceEnabled();
         }
   
  +      public void waitForState() throws Exception
  +      {
  +         synchronized (stateLock)
  +         {
  +            while (!isStateSet)
  +            {
  +               if (setStateException != null)
  +               {
  +                  throw setStateException;
  +               }
  +
  +               try
  +               {
  +                  stateLock.wait();
  +               }
  +               catch (InterruptedException iex)
  +               {
  +               }
  +            }
  +         }
  +      }
  +
         /**
          * Callback, does nothing.
          */
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:17 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:17 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction  ...
Message-ID: <E1Gskmb-0000fV-MW@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:17

  Modified:    src/org/jboss/cache/eviction  BaseEvictionAlgorithm.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.17      +6 -5      JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BaseEvictionAlgorithm.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- BaseEvictionAlgorithm.java	27 Nov 2006 04:49:46 -0000	1.16
  +++ BaseEvictionAlgorithm.java	8 Dec 2006 18:49:17 -0000	1.17
  @@ -6,12 +6,13 @@
    */
   package org.jboss.cache.eviction;
   
  -import EDU.oswego.cs.dl.util.concurrent.BoundedBuffer;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.lock.TimeoutException;
  +import java.util.concurrent.BlockingQueue;
  +import java.util.concurrent.LinkedBlockingQueue;
   
   /**
    * Abstract Event Processing Eviction Algorithm.
  @@ -20,7 +21,7 @@
    * abstract methods and a policy.
    *
    * @author Daniel Huang - dhuang at jboss.org 10/2005
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    */
   public abstract class BaseEvictionAlgorithm implements EvictionAlgorithm
   {
  @@ -34,7 +35,7 @@
      /**
       * Contains Fqn instances.
       */
  -   protected BoundedBuffer recycleQueue;
  +   protected BlockingQueue recycleQueue;
   
      /**
       * Contains NodeEntry instances.
  @@ -61,7 +62,7 @@
   
      protected BaseEvictionAlgorithm()
      {
  -      recycleQueue = new BoundedBuffer();
  +      recycleQueue = new LinkedBlockingQueue();
      }
   
      protected void initialize(Region region) throws EvictionException
  @@ -438,7 +439,7 @@
   
            try
            {
  -            fqn = (Fqn) recycleQueue.poll(0);
  +            fqn = (Fqn) recycleQueue.take();
            }
            catch (InterruptedException e)
            {
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:17 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:17 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/bdbje  ...
Message-ID: <E1Gskmb-0000fc-R4@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:17

  Modified:    src/org/jboss/cache/loader/bdbje  BdbjeCacheLoader.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.23      +2 -3      JBossCache/src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BdbjeCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- BdbjeCacheLoader.java	20 Nov 2006 18:04:08 -0000	1.22
  +++ BdbjeCacheLoader.java	8 Dec 2006 18:49:17 -0000	1.23
  @@ -1,6 +1,5 @@
   package org.jboss.cache.loader.bdbje;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import com.sleepycat.bind.serial.SerialBinding;
   import com.sleepycat.bind.serial.StoredClassCatalog;
   import com.sleepycat.bind.tuple.TupleBinding;
  @@ -24,7 +23,7 @@
   import org.jboss.cache.Modification;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   import org.jboss.cache.loader.AbstractCacheLoader;
  -import org.jboss.cache.util.MapCopy;
  +import java.util.concurrent.ConcurrentHashMap;
   
   import java.io.File;
   import java.io.IOException;
  @@ -51,7 +50,7 @@
    *
    * @author Mark Hayes May 16, 2004
    * @author Bela Ban
  - * @version $Id: BdbjeCacheLoader.java,v 1.22 2006/11/20 18:04:08 genman Exp $
  + * @version $Id: BdbjeCacheLoader.java,v 1.23 2006/12/08 18:49:17 genman Exp $
    */
   public class BdbjeCacheLoader extends AbstractCacheLoader
   {
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:18 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:18 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/util  ...
Message-ID: <E1Gskmc-0000fj-0A@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:18

  Modified:    src/org/jboss/cache/util  MapCopy.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.4       +1 -1      JBossCache/src/org/jboss/cache/util/MapCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MapCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/util/MapCopy.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MapCopy.java	20 Nov 2006 18:04:08 -0000	1.3
  +++ MapCopy.java	8 Dec 2006 18:49:17 -0000	1.4
  @@ -28,7 +28,7 @@
      {
         data = new Map.Entry[m.size()];
         int i = 0;
  -      for (Map.Entry<K, V> me : (Set<Map.Entry<K, V>>) m.entrySet())
  +      for (Map.Entry<K, V> me : m.entrySet())
         {
            if (me == null)
               throw new NullPointerException();
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:18 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:18 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1Gskmc-0000fq-4D@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:18

  Modified:    src/org/jboss/cache/optimistic 
                        TransactionWorkspaceImpl.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.14      +2 -16     JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspaceImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionWorkspaceImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspaceImpl.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- TransactionWorkspaceImpl.java	20 Sep 2006 16:28:58 -0000	1.13
  +++ TransactionWorkspaceImpl.java	8 Dec 2006 18:49:18 -0000	1.14
  @@ -6,13 +6,12 @@
    */
   package org.jboss.cache.optimistic;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import java.util.Map;
   import java.util.SortedMap;
   import java.util.TreeMap;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Contains a mapping of Fqn to {@link WorkspaceNode}s.
  @@ -24,10 +23,7 @@
   public class TransactionWorkspaceImpl implements TransactionWorkspace
   {
   
  -   private static FqnComparator fqnComparator = new FqnComparator();
  -
      private Map nodes;
  -   private TreeCache cache;
      private boolean versioningImplicit = true;
   
      public TransactionWorkspaceImpl()
  @@ -35,16 +31,6 @@
         nodes = new ConcurrentHashMap();
      }
   
  -   public void setCache(TreeCache cache)
  -   {
  -      this.cache = cache;
  -   }
  -
  -   public TreeCache getCache()
  -   {
  -      return cache;
  -   }
  -
      /**
       * Returns the nodes.
       */
  @@ -78,7 +64,7 @@
   
      public SortedMap getNodesAfter(Fqn fqn)
      {
  -      SortedMap sm = new TreeMap(fqnComparator);
  +      SortedMap sm = new TreeMap();
         sm.putAll(nodes);
         return sm.tailMap(fqn);
      }
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:18 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:18 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1Gskmc-0000fx-9l@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:18

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.49      +24 -13    JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -b -r1.48 -r1.49
  --- BuddyManager.java	10 Nov 2006 20:32:52 -0000	1.48
  +++ BuddyManager.java	8 Dec 2006 18:49:18 -0000	1.49
  @@ -6,9 +6,6 @@
    */
   package org.jboss.cache.buddyreplication;
   
  -import EDU.oswego.cs.dl.util.concurrent.BoundedLinkedQueue;
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
  -import EDU.oswego.cs.dl.util.concurrent.SynchronizedInt;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractCacheListener;
  @@ -36,6 +33,10 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Vector;
  +import java.util.concurrent.atomic.AtomicInteger;
  +import java.util.concurrent.BlockingQueue;
  +import java.util.concurrent.ConcurrentHashMap;
  +import java.util.concurrent.LinkedBlockingQueue;
   
   /**
    * Class that manages buddy replication groups.
  @@ -69,26 +70,25 @@
      /**
       * Map of buddy pools received from broadcasts
       */
  -   Map buddyPool;
  +   Map<IpAddress, String> buddyPool;
   
      /**
       * Map of bddy groups the current instance participates in as a backup node.
       * Keyed on String group name, values are BuddyGroup objects.
       * Needs to deal with concurrent access - concurrent assignTo/removeFrom buddy grp
       */
  -   Map buddyGroupsIParticipateIn = new ConcurrentReaderHashMap();
  -//    Map buddyGroupsIParticipateIn = new HashMap();
  +   Map<String, BuddyGroup> buddyGroupsIParticipateIn = new ConcurrentHashMap();
   
      /**
       * Queue to deal with queued up view change requests - which are handled asynchronously
       */
  -   private final BoundedLinkedQueue queue = new BoundedLinkedQueue();
  +   private final BlockingQueue<MembershipChange> queue = new LinkedBlockingQueue();
   
      /**
       * Async thread that handles items on the view change queue
       */
      private AsyncViewChangeHandlerThread asyncViewChangeHandler = new AsyncViewChangeHandlerThread();
  -   private static SynchronizedInt threadId = new SynchronizedInt(0);
  +   private static AtomicInteger threadId = new AtomicInteger(0);
   
      /**
       * Constants representng the buddy backup subtree
  @@ -116,7 +116,7 @@
         this.config = config;
   
         if (config.getBuddyPoolName() != null)
  -         buddyPool = new ConcurrentReaderHashMap();
  +         buddyPool = new ConcurrentHashMap();
   
         BuddyLocatorConfig blc = config.getBuddyLocatorConfig();
         try
  @@ -241,12 +241,22 @@
   
      // -------------- methods to be called by the tree cache listener --------------------
   
  +   static class MembershipChange {
  +      List oldMembers;
  +      List newMembers;
  +      public MembershipChange(List oldMembers, List newMembers)
  +      {
  +         this.oldMembers = oldMembers;
  +         this.newMembers = newMembers;
  +      }
  +   }
  +   
      private void enqueueViewChange(List oldMembers, List newMembers)
      {
         // put this on a queue
         try
         {
  -         queue.put(new List[]{oldMembers, newMembers});
  +         queue.put(new MembershipChange(oldMembers, newMembers));
         }
         catch (InterruptedException e)
         {
  @@ -786,7 +796,8 @@
         {
            if (t == null || !t.isAlive())
            {
  -            t = new Thread(this, "AsyncViewChangeHandlerThread-" + threadId.increment());
  +            t = new Thread(this);
  +            t.setName("AsyncViewChangeHandlerThread-" + threadId.getAndIncrement());
               t.setDaemon(true);
               t.start();
            }
  @@ -818,10 +829,10 @@
         private void handleEnqueuedViewChange() throws Exception
         {
            log.trace("Handling queued view change");
  -         List[] members = (List[]) queue.take(); // 2 element array - 0 - oldMembers, 1 - newMembers
  +         MembershipChange members = queue.take();
   
            // always refresh buddy list.
  -         reassignBuddies(members[1]);
  +         reassignBuddies(members.newMembers);
   
            if (config.getBuddyPoolName() != null)
            {
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:18 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:18 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1Gskmc-0000g4-EP@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:18

  Modified:    src/org/jboss/cache/marshall  Marshaller.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.6       +1 -1      JBossCache/src/org/jboss/cache/marshall/Marshaller.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Marshaller.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/Marshaller.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- Marshaller.java	12 Oct 2006 23:03:57 -0000	1.5
  +++ Marshaller.java	8 Dec 2006 18:49:18 -0000	1.6
  @@ -6,7 +6,6 @@
    */
   package org.jboss.cache.marshall;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
  @@ -17,6 +16,7 @@
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
   import java.util.List;
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * Abstract Marshaller for JBoss Cache.
  
  
  


From genman at noderunner.net  Fri Dec  8 13:49:18 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:49:18 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/jdbm  ...
Message-ID: <E1Gskmc-0000gB-KC@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:49:18

  Modified:    src/org/jboss/cache/loader/jdbm  JdbmCacheLoader.java
  Log:
  JBCACHE-892 Use JDK1.5 concurrent classes
  
  Revision  Changes    Path
  1.18      +2 -3      JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JdbmCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- JdbmCacheLoader.java	26 Oct 2006 19:30:21 -0000	1.17
  +++ JdbmCacheLoader.java	8 Dec 2006 18:49:18 -0000	1.18
  @@ -1,6 +1,5 @@
   package org.jboss.cache.loader.jdbm;
   
  -import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import jdbm.RecordManager;
   import jdbm.RecordManagerFactory;
   import jdbm.btree.BTree;
  @@ -25,7 +24,7 @@
   import java.util.Map;
   import java.util.Properties;
   import java.util.Set;
  -
  +import java.util.concurrent.ConcurrentHashMap;
   
   /**
    * A persistent <code>CacheLoader</code> based on the JDBM project.
  @@ -56,7 +55,7 @@
    * plans to fix this.
    *
    * @author Elias Ross
  - * @version $Id: JdbmCacheLoader.java,v 1.17 2006/10/26 19:30:21 bstansberry Exp $
  + * @version $Id: JdbmCacheLoader.java,v 1.18 2006/12/08 18:49:18 genman Exp $
    */
   public class JdbmCacheLoader extends AbstractCacheLoader
   {
  
  
  


From genman at noderunner.net  Fri Dec  8 13:50:49 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:50:49 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock ...
Message-ID: <E1Gsko5-0000jU-MJ@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:50:49

  Modified:    tests/functional/org/jboss/cache/lock     
                        ReentrantWriterPreferenceReadWriteLockTest.java
                        ReentrantWriterPreference2Readers1WriterLockTest.java
                        ReadWriteLockWithUpgradeTest.java
                        NonBlockingWriterLockTest.java LockTest.java
  Log:
  JBCACHE-891 Use JDK 1.5 lock classes
  
  Revision  Changes    Path
  1.4       +48 -42    JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreferenceReadWriteLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReentrantWriterPreferenceReadWriteLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreferenceReadWriteLockTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ReentrantWriterPreferenceReadWriteLockTest.java	5 May 2006 12:06:58 -0000	1.3
  +++ ReentrantWriterPreferenceReadWriteLockTest.java	8 Dec 2006 18:50:49 -0000	1.4
  @@ -1,6 +1,8 @@
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
  +
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  @@ -9,12 +11,12 @@
   /**
    * Tests ReentrantWriterPreferenceReadWriteLock
    * @author Bela Ban
  - * @version $Id: ReentrantWriterPreferenceReadWriteLockTest.java,v 1.3 2006/05/05 12:06:58 msurtani Exp $
  + * @version $Id: ReentrantWriterPreferenceReadWriteLockTest.java,v 1.4 2006/12/08 18:50:49 genman Exp $
    */
   public class ReentrantWriterPreferenceReadWriteLockTest extends TestCase {
      // ReentrantWriterPreferenceReadWriteLock lock;
      SimpleReadWriteLock lock;
  -   Sync rl, wl;
  +   Lock rl, wl;
      Exception thread_ex=null;
   
      protected void setUp() throws Exception {
  @@ -34,78 +36,82 @@
      }
   
      public void testMultipleReadLockAcquisitions() throws InterruptedException {
  -      rl.acquire();
  -      rl.acquire();
  +      rl.lock();
  +      rl.lock();
      }
   
      public void testInterruptedLockAcquisition() {
         Thread.currentThread().interrupt();
         try {
  -         rl.acquire();
  +         rl.lockInterruptibly();
            fail("thread should be in interrupted status");
         }
         catch(InterruptedException e) {
         }
         finally {
            try {
  -            rl.release();
  -            fail("release() should throw an IllegalStateException");
  +            rl.unlock();
  +            fail("unlock() should throw an IllegalStateException");
            }
  -         catch(IllegalStateException illegalStateEx) {
  +         catch(IllegalMonitorStateException illegalStateEx) {
               assertTrue(true);
            }
         }
      }
   
      public void testMultipleWriteLockAcquisitions() throws InterruptedException {
  -      wl.acquire();
  -      wl.acquire();
  +      wl.lock();
  +      wl.lock();
      }
   
      public void testMultipleReadLockReleases() throws InterruptedException {
  -      rl.acquire();
  -      rl.release();
  +      rl.lock();
  +      rl.unlock();
         try {
  -         rl.release();
  -         fail("we should not get here, cannot acquire RL once but release twice");
  +         rl.unlock();
  +         fail("we should not get here, cannot lock RL once but unlock twice");
         }
  -      catch(IllegalStateException illegalState) {
  +      catch(IllegalMonitorStateException illegalState) {
            // this is as expected
         }
      }
   
   
      public void acquireReadAndWriteLocks() throws InterruptedException {
  -      rl.acquire();
  -      rl.acquire();
  -      boolean fl=wl.attempt(4000);
  +      rl.lock();
  +      rl.lock();
  +      boolean fl=wl.tryLock(4000, TimeUnit.MILLISECONDS);
         assertTrue(fl);
      }
   
   
      public void acquireWriteThenReadLock() throws InterruptedException {
  -      wl.acquire();
  -      rl.acquire();
  -      wl.release();
  -      rl.release();
  +      wl.lock();
  +      rl.lock();
  +      wl.unlock();
  +      rl.unlock();
      }
   
      public void testMultipleWriteLockReleases() throws InterruptedException {
  -      wl.acquire();
  -      wl.release();
  -      wl.release();
  +      wl.lock();
  +      wl.unlock();
  +      try {
  +         wl.unlock();
  +         fail("expected");
  +      } catch (IllegalMonitorStateException e) {}
      }
   
      public void testAcquireWriteLockAfterReadLock() throws InterruptedException {
  -      rl.acquire();
  -      wl.acquire();
  +      rl.lock();
  +      rl.unlock();
  +      wl.lock();
      }
   
   
      public void testAcquiringReadLockedLockWithRead() throws InterruptedException {
         new Thread() {
            public void run() {
  -            try {rl.acquire();}
  +            try {rl.lockInterruptibly();}
               catch(InterruptedException e) {}
            }
         }.start();
  @@ -114,16 +120,16 @@
   
         // now we have a RL by another thread
   
  -      boolean flag=rl.attempt(3000);
  +      boolean flag=rl.tryLock(3000, TimeUnit.MILLISECONDS);
         assertTrue(flag);
  -      flag=wl.attempt(3000);
  +      flag=wl.tryLock(3000, TimeUnit.MILLISECONDS);
         assertFalse(flag);
      }
   
      public void testAcquiringReadLockedLock() throws InterruptedException {
         new Thread() {
            public void run() {
  -            try {rl.acquire();}
  +            try {rl.lockInterruptibly();}
               catch(InterruptedException e) {}
            }
         }.start();
  @@ -131,7 +137,7 @@
         TestingUtil.sleepThread(500);
   
         // now we have a RL by another thread
  -      boolean flag=wl.attempt(3000);
  +      boolean flag=wl.tryLock(3000, TimeUnit.MILLISECONDS);
         assertFalse(flag);
      }
   
  @@ -193,13 +199,13 @@
         public void run() {
            try {
               log("acquiring RL");
  -            rl.acquire();
  +            rl.lock();
               log("acquired RL");
               synchronized(this) {
                  this.wait();
               }
               log("releasing RL");
  -            rl.release();
  +            rl.unlock();
               log("released RL");
            }
            catch(InterruptedException e) {
  @@ -218,13 +224,13 @@
         public void run() {
            try {
               log("acquiring WL");
  -            wl.acquire();
  +            wl.lock();
               log("acquired WL");
               synchronized(this) {
                  this.wait();
               }
               log("releasing WL");
  -            wl.release();
  +            wl.unlock();
               log("released WL");
            }
            catch(InterruptedException e) {
  @@ -248,18 +254,18 @@
         public void run() {
            try {
               log("acquiring RL");
  -            rl.acquire();
  +            rl.lock();
               log("acquired RL");
               synchronized(this) {
                  this.wait();
               }
  -            log("attempting to acquire WL");
  -            // rl.release();
  -            wl.acquire();
  +            log("attempting to lock WL");
  +            // rl.unlock();
  +            wl.lock();
               upgradeSuccessful=true;
               log("acquired WL");
               log("releasing WL/RL");
  -            wl.release();
  +            wl.unlock();
               log("released WL/RL");
            }
            catch(InterruptedException e) {
  
  
  
  1.6       +1 -2      JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReentrantWriterPreference2Readers1WriterLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ReentrantWriterPreference2Readers1WriterLockTest.java	4 Dec 2006 12:33:40 -0000	1.5
  +++ ReentrantWriterPreference2Readers1WriterLockTest.java	8 Dec 2006 18:50:49 -0000	1.6
  @@ -13,11 +13,10 @@
   import java.util.concurrent.locks.ReentrantReadWriteLock;
   import java.util.concurrent.TimeUnit;
   
  -
   /**
    * Tests ReentrantWriterPreferenceReadWriteLock
    * @author Bela Ban
  - * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.5 2006/12/04 12:33:40 bela Exp $
  + * @version $Id: ReentrantWriterPreference2Readers1WriterLockTest.java,v 1.6 2006/12/08 18:50:49 genman Exp $
    */
   public class ReentrantWriterPreference2Readers1WriterLockTest extends TestCase {
      ReentrantReadWriteLock lock;
  
  
  
  1.3       +21 -20    JBossCache/tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReadWriteLockWithUpgradeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ReadWriteLockWithUpgradeTest.java	5 May 2006 12:06:58 -0000	1.2
  +++ ReadWriteLockWithUpgradeTest.java	8 Dec 2006 18:50:49 -0000	1.3
  @@ -1,6 +1,5 @@
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  @@ -10,6 +9,8 @@
   import java.io.IOException;
   import java.io.Writer;
   import java.util.Vector;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * NonBlockingWriterLock is a read/write lock (with upgrade) that has
  @@ -150,9 +151,9 @@
         {
            public void run()
            {
  -               Sync rlock = lock_.readLock();
  +               Lock rlock = lock_.readLock();
               try {
  -               if (! rlock.attempt(msecs)) {
  +               if (! rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting read lock failed!\n");
                     String str = caseNum + "-" + name + "-RL-0";
                     postLockingResult(str);
  @@ -171,7 +172,7 @@
                  else if (secondOP == INVOKE_UPGRADE)
                      acquireUpgradeLock(caseNum, name, msecs, errMsg);
                    
  -               rlock.release();
  +               rlock.unlock();
                  logX(caseNum+"-"+name+" releasing read lock.\n");
               } catch (Exception ex) {
               }
  @@ -194,8 +195,8 @@
            public void run()
            {
               try {
  -               Sync wlock = lock_.writeLock();
  -               if (! wlock.attempt(msecs)) {
  +               Lock wlock = lock_.writeLock();
  +               if (! wlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting write lock failed!\n");
                     String str = caseNum + "-" + name + "-WL-0";
                     postLockingResult(str);
  @@ -214,7 +215,7 @@
                  else if (secondOP == INVOKE_UPGRADE)
                      acquireUpgradeLock(caseNum, name, msecs, errMsg);
   
  -               wlock.release();
  +               wlock.unlock();
                  logX(caseNum+"-"+name+" releasing write lock.\n");
               } catch (Exception ex) {
               }
  @@ -237,9 +238,9 @@
            public void run()
            {
               try {
  -               Sync rlock = lock_.readLock();
  -               Sync wlock = null;
  -               if (! rlock.attempt(msecs)) {
  +               Lock rlock = lock_.readLock();
  +               Lock wlock = null;
  +               if (! rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting read lock failed!\n");
                     String str = caseNum + "-" + name + "-RL-0";
                     postLockingResult(str);
  @@ -264,10 +265,10 @@
                  TestingUtil.sleepThread(SLEEP_MSECS);
                  if (wlock != null)
                  {
  -                 wlock.release();
  +                 wlock.unlock();
                    logX(caseNum+"-"+name+" releasing upgrade lock.\n");
                  }
  -               rlock.release();
  +               rlock.unlock();
               } catch (Exception ex) {
               }
            }
  @@ -288,8 +289,8 @@
                                     final long msecs, final String errMsg)
      {
               try {
  -               Sync rlock = lock_.readLock();
  -               if (! rlock.attempt(msecs)) {
  +               Lock rlock = lock_.readLock();
  +               if (! rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting read lock failed!\n");
                     String str = caseNum + "-" + name + "-RL-0";
                     postLockingResult(str);
  @@ -300,7 +301,7 @@
                  String str = caseNum + "-" + name + "-RL-1";
                  postLockingResult(str);
                  TestingUtil.sleepThread(SLEEP_MSECS);
  -               rlock.release();
  +               rlock.unlock();
                  logX(caseNum+"-"+name+" releasing read lock.\n");
               } catch (Exception ex) {
               }
  @@ -314,8 +315,8 @@
                                      final long msecs, final String errMsg)
      {
               try {
  -               Sync wlock = lock_.writeLock();
  -               if (! wlock.attempt(msecs)) {
  +               Lock wlock = lock_.writeLock();
  +               if (! wlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting write lock failed!\n");
                     String str = caseNum + "-" + name + "-WL-0";
                     postLockingResult(str);
  @@ -326,7 +327,7 @@
                  String str = caseNum + "-" + name + "-WL-1";
                  postLockingResult(str);
                  TestingUtil.sleepThread(SLEEP_MSECS);
  -               wlock.release();
  +               wlock.unlock();
                  logX(caseNum+"-"+name+" releasing write lock.\n");
               } catch (Exception ex) {
               }
  @@ -340,7 +341,7 @@
                                        final long msecs, final String errMsg)
      {
               try {
  -               Sync ulock = null;
  +               Lock ulock = null;
                  if ((ulock = lock_.upgradeLockAttempt(msecs)) == null) {
                     logX(caseNum+"-"+name+" requesting upgrade lock failed!\n");
                     String str = caseNum + "-" + name + "-UL-0";
  @@ -352,7 +353,7 @@
                  String str = caseNum + "-" + name + "-UL-1";
                  postLockingResult(str);
                  TestingUtil.sleepThread(SLEEP_MSECS);
  -               ulock.release();
  +               ulock.unlock();
                  logX(caseNum+"-"+name+" releasing upgrade lock.\n");
               } catch (Exception ex) {
               }
  
  
  
  1.3       +21 -20    JBossCache/tests/functional/org/jboss/cache/lock/NonBlockingWriterLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NonBlockingWriterLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/NonBlockingWriterLockTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- NonBlockingWriterLockTest.java	5 May 2006 12:06:58 -0000	1.2
  +++ NonBlockingWriterLockTest.java	8 Dec 2006 18:50:49 -0000	1.3
  @@ -1,6 +1,7 @@
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  @@ -150,9 +151,9 @@
         {
            public void run()
            {
  -               Sync rlock = lock_.readLock();
  +               Lock rlock = lock_.readLock();
               try {
  -               if (! rlock.attempt(msecs)) {
  +               if (! rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting read lock failed!\n");
                     String str = caseNum + "-" + name + "-RL-0";
                     postLockingResult(str);
  @@ -171,7 +172,7 @@
                  else if (secondOP == INVOKE_UPGRADE)
                      acquireUpgradeLock(caseNum, name, msecs, errMsg);
                    
  -               rlock.release();
  +               rlock.unlock();
                  logX(caseNum+"-"+name+" releasing read lock.\n");
               } catch (Exception ex) {
               }
  @@ -194,8 +195,8 @@
            public void run()
            {
               try {
  -               Sync wlock = lock_.writeLock();
  -               if (! wlock.attempt(msecs)) {
  +               Lock wlock = lock_.writeLock();
  +               if (! wlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting write lock failed!\n");
                     String str = caseNum + "-" + name + "-WL-0";
                     postLockingResult(str);
  @@ -214,7 +215,7 @@
                  else if (secondOP == INVOKE_UPGRADE)
                      acquireUpgradeLock(caseNum, name, msecs, errMsg);
   
  -               wlock.release();
  +               wlock.unlock();
                  logX(caseNum+"-"+name+" releasing write lock.\n");
               } catch (Exception ex) {
               }
  @@ -237,9 +238,9 @@
            public void run()
            {
               try {
  -               Sync rlock = lock_.readLock();
  -               Sync wlock = null;
  -               if (! rlock.attempt(msecs)) {
  +               Lock rlock = lock_.readLock();
  +               Lock wlock = null;
  +               if (! rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting read lock failed!\n");
                     String str = caseNum + "-" + name + "-RL-0";
                     postLockingResult(str);
  @@ -264,10 +265,10 @@
                  TestingUtil.sleepThread(SLEEP_MSECS);
                  if (wlock != null)
                  {
  -                 wlock.release();
  +                 wlock.unlock();
                    logX(caseNum+"-"+name+" releasing upgrade lock.\n");
                  }
  -               rlock.release();
  +               rlock.unlock();
               } catch (Exception ex) {
               }
            }
  @@ -288,8 +289,8 @@
                                     final long msecs, final String errMsg)
      {
               try {
  -               Sync rlock = lock_.readLock();
  -               if (! rlock.attempt(msecs)) {
  +               Lock rlock = lock_.readLock();
  +               if (! rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting read lock failed!\n");
                     String str = caseNum + "-" + name + "-RL-0";
                     postLockingResult(str);
  @@ -300,7 +301,7 @@
                  String str = caseNum + "-" + name + "-RL-1";
                  postLockingResult(str);
                  TestingUtil.sleepThread(SLEEP_MSECS);
  -               rlock.release();
  +               rlock.unlock();
                  logX(caseNum+"-"+name+" releasing read lock.\n");
               } catch (Exception ex) {
               }
  @@ -314,8 +315,8 @@
                                      final long msecs, final String errMsg)
      {
               try {
  -               Sync wlock = lock_.writeLock();
  -               if (! wlock.attempt(msecs)) {
  +               Lock wlock = lock_.writeLock();
  +               if (! wlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     logX(caseNum+"-"+name+" requesting write lock failed!\n");
                     String str = caseNum + "-" + name + "-WL-0";
                     postLockingResult(str);
  @@ -326,7 +327,7 @@
                  String str = caseNum + "-" + name + "-WL-1";
                  postLockingResult(str);
                  TestingUtil.sleepThread(SLEEP_MSECS);
  -               wlock.release();
  +               wlock.unlock();
                  logX(caseNum+"-"+name+" releasing write lock.\n");
               } catch (Exception ex) {
               }
  @@ -340,7 +341,7 @@
                                        final long msecs, final String errMsg)
      {
               try {
  -               Sync ulock = null;
  +               Lock ulock = null;
                  if ((ulock = lock_.upgradeLockAttempt(msecs)) == null) {
                     logX(caseNum+"-"+name+" requesting upgrade lock failed!\n");
                     String str = caseNum + "-" + name + "-UL-0";
  @@ -352,7 +353,7 @@
                  String str = caseNum + "-" + name + "-UL-1";
                  postLockingResult(str);
                  TestingUtil.sleepThread(SLEEP_MSECS);
  -               ulock.release();
  +               ulock.unlock();
                  logX(caseNum+"-"+name+" releasing upgrade lock.\n");
               } catch (Exception ex) {
               }
  
  
  
  1.9       +47 -46    JBossCache/tests/functional/org/jboss/cache/lock/LockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/LockTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- LockTest.java	5 May 2006 12:06:58 -0000	1.8
  +++ LockTest.java	8 Dec 2006 18:50:49 -0000	1.9
  @@ -1,8 +1,9 @@
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.CyclicBarrier;
  -import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.CyclicBarrier;
  +import java.util.concurrent.Semaphore;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  @@ -12,7 +13,7 @@
    * Various tests that test isolation level semantics provided by locks
    *
    * @author Bela Ban
  - * @version $Id: LockTest.java,v 1.8 2006/05/05 12:06:58 msurtani Exp $
  + * @version $Id: LockTest.java,v 1.9 2006/12/08 18:50:49 genman Exp $
    */
   public class LockTest extends TestCase {
      int  value=10;
  @@ -36,9 +37,9 @@
      }
   
   
  -   static class MyFIFOSemaphore extends FIFOSemaphore {
  -      public MyFIFOSemaphore(long l) {
  -         super(l);
  +   static class MyFIFOSemaphore extends Semaphore {
  +      public MyFIFOSemaphore(int permits) {
  +         super(permits);
         }
   
         public void acquire() throws InterruptedException {
  @@ -64,21 +65,21 @@
       */
      public void testReadUncommitted() throws Throwable {
         final LockStrategy s=new LockStrategyReadUncommitted();
  -      final FIFOSemaphore sem=new MyFIFOSemaphore(1);
  +      final Semaphore sem=new MyFIFOSemaphore(1);
         final CyclicBarrier barrier=new CyclicBarrier(2);
   
         Thread t1=new Thread("t1") {
  -         Sync lock=null;
  +         Lock lock=null;
   
            public void run() {
               try {
                  sem.acquire(); // we're first to the semaphore
   
                  // log("waiting on barrier");
  -               barrier.barrier(); // wait until t2 joins us
  +               barrier.await(); // wait until t2 joins us
                  // log("passed barrier");
                  lock=s.readLock();
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("1st read: value is " + value);
                  assertEquals(10, value);
                  sem.release(); // give t2 time to make the modification
  @@ -99,7 +100,7 @@
               }
               finally {
                  if(lock != null)
  -                  lock.release();
  +                  lock.unlock();
                  sem.release();
               }
            }
  @@ -107,30 +108,30 @@
   
   
         Thread t2=new Thread("t2") {
  -         Sync lock=null;
  +         Lock lock=null;
   
            public void run() {
               try {
                  TestingUtil.sleepThread(100);
  -               barrier.barrier();
  +               barrier.await();
                  sem.acquire();
                  lock=s.writeLock();
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("changing value from " + value + " to 20");
                  value=20;
                  sem.release(); // now t1 can read the uncommitted modification
                  TestingUtil.sleepThread(100);
   
  -               sem.acquire(); // to release the lock
  +               sem.acquire(); // to unlock the lock
                  log("committing the TX");
  -               lock.release();
  +               lock.unlock();
               }
               catch(Throwable ex) {
                  t2_ex=ex;
               }
               finally {
                  if(lock != null)
  -                  lock.release();
  +                  lock.unlock();
                  sem.release();
               }
            }
  @@ -192,7 +193,7 @@
                  t1_ex=ex;
               }
               finally {
  -               identity_lock.release(this);
  +               identity_lock.unlock(this);
               }
            }
         };
  @@ -209,13 +210,13 @@
                  TestingUtil.sleepThread(SLEEP * 2);
   
                  log("committing the TX");
  -               identity_lock.release(this);
  +               identity_lock.unlock(this);
               }
               catch(Throwable ex) {
                  t2_ex=ex;
               }
               finally {
  -               identity_lock.release(this);
  +               identity_lock.unlock(this);
               }
            }
         };
  @@ -236,13 +237,13 @@
          final LockStrategy s=new LockStrategyReadCommitted();
   
          Thread t1=new Thread("t1") {
  -          Sync lock=null;
  +          Lock lock=null;
   
             public void run() {
                try {
                   TestingUtil.sleepThread(100);
                   lock=s.readLock();
  -                lock.attempt(TIMEOUT);
  +                lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                   log("1st read: value is " + value);
                   assertEquals(20, value);
                   TestingUtil.sleepThread(SLEEP);
  @@ -255,31 +256,31 @@
                   t1_ex=ex;
                }
                finally {
  -                lock.release();
  +                lock.unlock();
                }
             }
          };
   
   
          Thread t2=new Thread("t2") {
  -          Sync lock=null;
  +          Lock lock=null;
   
             public void run() {
                try {
                   lock=s.writeLock();
  -                lock.attempt(TIMEOUT);
  +                lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                   log("changing value from " + value + " to 20");
                   value=20;
                   TestingUtil.sleepThread(SLEEP);
   
                   log("committing the TX");
  -                lock.release();
  +                lock.unlock();
                }
                catch(Throwable ex) {
                   t2_ex=ex;
                }
                finally {
  -                lock.release();
  +                lock.unlock();
                }
             }
          };
  @@ -318,12 +319,12 @@
         final LockStrategy s=new LockStrategyRepeatableRead();
   
         Thread t1=new Thread("t1") {
  -         Sync lock=null;
  +         Lock lock=null;
   
            public void run() {
               try {
                  lock=s.readLock();
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("1st read: value is " + value);
                  assertEquals(10, value);
                  TestingUtil.sleepThread(SLEEP);
  @@ -334,10 +335,10 @@
   
                  log("3rd read: value is still " + value + "; we should not see t2's committed change");
                  assertEquals(10, value);
  -               lock.release();
  +               lock.unlock();
   
                  TestingUtil.sleepThread(SLEEP);
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("4th read: value is now " + value + "; we should see t2's committed change in our new TX");
                  assertEquals(20, value);
               }
  @@ -345,32 +346,32 @@
                  t1_ex=ex;
               }
               finally {
  -               lock.release();
  +               lock.unlock();
               }
            }
         };
   
   
         Thread t2=new Thread("t2") {
  -         Sync lock=null;
  +         Lock lock=null;
   
            public void run() {
               try {
                  TestingUtil.sleepThread(100);
                  lock=s.writeLock();
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("changing value from " + value + " to 20");
                  value=20;
                  TestingUtil.sleepThread(SLEEP);
   
                  log("committing the TX");
  -               lock.release();
  +               lock.unlock();
               }
               catch(Throwable ex) {
                  t2_ex=ex;
               }
               finally {
  -               lock.release();
  +               lock.unlock();
               }
            }
         };
  @@ -403,18 +404,18 @@
         final LockStrategy s=new LockStrategySerializable();
   
         Thread t1=new Thread("t1") {
  -         Sync lock=null;
  +         Lock lock=null;
   
            public void run() {
               try {
                  lock=s.readLock();
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("1st read: value is " + value);
                  assertEquals(10, value);
  -               lock.release();
  +               lock.unlock();
                  TestingUtil.sleepThread(SLEEP);
   
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("2nd read: value is " + value + "; we should see t2's committed change (20)");
                  assertEquals(20, value);
               }
  @@ -422,30 +423,30 @@
                  t1_ex=ex;
               }
               finally {
  -               lock.release();
  +               lock.unlock();
               }
            }
         };
   
   
         Thread t2=new Thread("t2") {
  -         Sync lock=null;
  +         Lock lock=null;
   
            public void run() {
               try {
                  TestingUtil.sleepThread(100);
                  lock=s.writeLock();
  -               lock.attempt(TIMEOUT);
  +               lock.tryLock(TIMEOUT, TimeUnit.MILLISECONDS);
                  log("changing value from " + value + " to 20");
                  value=20;
                  log("committing the TX");
  -               lock.release();
  +               lock.unlock();
               }
               catch(Throwable ex) {
                  t2_ex=ex;
               }
               finally {
  -               lock.release();
  +               lock.unlock();
               }
            }
         };
  
  
  


From genman at noderunner.net  Fri Dec  8 13:50:49 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 13:50:49 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/lock                 ...
Message-ID: <E1Gsko5-0000j9-GS@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 13:50:49

  Modified:    src/org/jboss/cache/lock                
                        LockStrategyReadUncommitted.java
                        ReadWriteLockWithUpgrade.java
                        LockStrategyRepeatableRead.java
                        SimpleReadWriteLock.java IsolationLevel.java
                        LockStrategyReadCommitted.java LockMap.java
                        LockStrategyNone.java SimpleLock.java LockUtil.java
                        IdentityLock.java LockStrategy.java
                        LockStrategyFactory.java
                        LockStrategySerializable.java
  Added:       src/org/jboss/cache/lock                 NullLock.java
                        SemaphoreLock.java
  Log:
  JBCACHE-891 Use JDK 1.5 lock classes
  
  Revision  Changes    Path
  1.2       +12 -13    JBossCache/src/org/jboss/cache/lock/LockStrategyReadUncommitted.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategyReadUncommitted.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategyReadUncommitted.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LockStrategyReadUncommitted.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ LockStrategyReadUncommitted.java	8 Dec 2006 18:50:49 -0000	1.2
  @@ -6,32 +6,31 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
  -import EDU.oswego.cs.dl.util.concurrent.NullSync;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Transaction isolation level of READ-UNCOMMITTED. Reads always succeed (NullLock), whereas writes are exclusive.
    * It prevents none of the dirty read, non-repeatable read, or phantom read.
    *
    * @author Ben Wang
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class LockStrategyReadUncommitted implements LockStrategy
   {
  -   private FIFOSemaphore wLock_;
  -   private NullSync rLock_; // Null lock will always return true
  +   private SemaphoreLock wLock_;
  +   private Lock rLock_; // Null lock will always return true
   
      public LockStrategyReadUncommitted()
      {
  -      wLock_ = new FIFOSemaphore(1);
  -      rLock_ = new NullSync();
  +      wLock_ = new SemaphoreLock(1);
  +      rLock_ = new NullLock();
      }
   
      /**
       * @see org.jboss.cache.lock.LockStrategy#readLock()
       */
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return rLock_;
      }
  @@ -39,12 +38,12 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#upgradeLockAttempt(long)
       */
  -   public Sync upgradeLockAttempt(long msecs) throws UpgradeException
  +   public Lock upgradeLockAttempt(long msecs) throws UpgradeException
      {
         // Since write is exclusive, we need to obtain the write lock first
         // before we can return the upgrade
         try {
  -         wLock_.attempt(msecs);
  +         wLock_.tryLock(msecs, TimeUnit.MILLISECONDS);
         } catch (InterruptedException e) {
            throw new UpgradeException("Upgrade failed in " + msecs + " msecs", e);
         }
  @@ -54,7 +53,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#writeLock()
       */
  -   public Sync writeLock()
  +   public Lock writeLock()
      {
         return wLock_;
      }
  
  
  
  1.4       +54 -23    JBossCache/src/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReadWriteLockWithUpgrade.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ReadWriteLockWithUpgrade.java	22 Jun 2005 14:33:06 -0000	1.3
  +++ ReadWriteLockWithUpgrade.java	8 Dec 2006 18:50:49 -0000	1.4
  @@ -12,8 +12,10 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   
  -import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Condition;
  +import java.util.concurrent.locks.ReadWriteLock;
  +import java.util.concurrent.locks.Lock;
   
   /*
    * <p> This class is similar to PreferredWriterReadWriteLock except that
  @@ -77,12 +79,12 @@
      }
   
   
  -   public Sync writeLock()
  +   public Lock writeLock()
      {
         return writerLock_;
      }
   
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return readerLock_;
      }
  @@ -94,7 +96,7 @@
       * @param msecs Time to wait in millisecons.
       * @return Sync object. Null if not successful or timeout.
       */
  -   public Sync upgradeLockAttempt(long msecs) throws UpgradeException
  +   public Lock upgradeLockAttempt(long msecs) throws UpgradeException
      {
         if (activeReaders_ == 0)
            throw new RuntimeException("No reader lock available for upgrade");
  @@ -118,13 +120,13 @@
            resetWaitingUpgrader();
            return changeLock();
         } else {
  -         readerLock_.release();
  +         readerLock_.unlock();
            try {
  -            if (!writerLock_.attempt(msecs)) {
  +            if (!writerLock_.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                  log_.error("upgradeLock(): failed");
                  resetWaitingUpgrader();
   
  -               if(!readerLock_.attempt(msecs)) {
  +               if(!readerLock_.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                     String errStr="ReadWriteLockWithUpgrade.upgradeLockAttempt():" +
                           " failed to upgrade to write lock and also failed to re-obtain the read lock";
                     log_.error(errStr);
  @@ -149,7 +151,7 @@
         }
      }
   
  -   protected synchronized Sync changeLock()
  +   protected synchronized Lock changeLock()
      {
         --activeReaders_;
   
  @@ -277,15 +279,47 @@
         void signalWaiters();
      }
   
  -   protected class ReaderLock implements Signaller, Sync
  +   static abstract class LockBase implements Lock
      {
   
  -      public void acquire() throws InterruptedException
  +      public void lock()
         {
  -         throw new RuntimeException("acquire(): Operation currently not supported.");
  +         throw new UnsupportedOperationException();
         }
   
  -      public void release()
  +      public void lockInterruptibly() throws InterruptedException
  +      {
  +         throw new UnsupportedOperationException();
  +      }
  +
  +      public Condition newCondition()
  +      {
  +         throw new UnsupportedOperationException();
  +      }
  +
  +      public boolean tryLock()
  +      {
  +         throw new UnsupportedOperationException();
  +      }
  +
  +      /*
  +      public boolean tryLock(long time, TimeUnit unit) throws InterruptedException
  +      {
  +         throw new UnsupportedOperationException();
  +      }
  +
  +      public void unlock()
  +      {
  +         throw new UnsupportedOperationException();
  +      }
  +      */
  +   
  +   }
  +
  +   protected class ReaderLock extends LockBase implements Signaller, Lock
  +   {
  +
  +      public void unlock()
         {
            Signaller s = endRead();
            if (s != null) {
  @@ -298,9 +332,10 @@
            ReaderLock.this.notifyAll();
         }
   
  -      public boolean attempt(long msecs) throws InterruptedException
  +      public boolean tryLock(long time, TimeUnit unit) throws InterruptedException
         {
            if (Thread.interrupted()) throw new InterruptedException();
  +         long msecs = unit.toMillis(time);
            InterruptedException ie = null;
            synchronized (this) {
               if (msecs <= 0)
  @@ -341,15 +376,10 @@
   
      }
   
  -   protected class WriterLock implements Signaller, Sync
  +   protected class WriterLock extends LockBase implements Signaller, Lock
      {
   
  -      public void acquire() throws InterruptedException
  -      {
  -         throw new RuntimeException("acquire(): Operation currently not supported.");
  -      }
  -
  -      public void release()
  +      public void unlock()
         {
            Signaller s = endWrite();
            if (s != null) s.signalWaiters();
  @@ -362,10 +392,11 @@
            WriterLock.this.notifyAll();
         }
   
  -      public boolean attempt(long msecs) throws InterruptedException
  +      public boolean tryLock(long time, TimeUnit unit) throws InterruptedException
         {
            if (Thread.interrupted()) throw new InterruptedException();
            InterruptedException ie = null;
  +         long msecs = unit.toMillis(time);
   
            synchronized (WriterLock.this) {
               if (msecs <= 0) {
  
  
  
  1.2       +5 -5      JBossCache/src/org/jboss/cache/lock/LockStrategyRepeatableRead.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategyRepeatableRead.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategyRepeatableRead.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LockStrategyRepeatableRead.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ LockStrategyRepeatableRead.java	8 Dec 2006 18:50:49 -0000	1.2
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Transaction isolation level of Repeatable_Read. It prevents dirty read and non-repeatable read.
  @@ -16,7 +16,7 @@
    * transaction commit. </p>
    *
    * @author Ben Wang
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class LockStrategyRepeatableRead implements LockStrategy
   {
  @@ -30,7 +30,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#readLock()
       */
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return lock_.readLock();
      }
  @@ -38,7 +38,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#upgradeLockAttempt(long)
       */
  -   public Sync upgradeLockAttempt(long msecs)  throws UpgradeException
  +   public Lock upgradeLockAttempt(long msecs)  throws UpgradeException
      {
         return lock_.upgradeLockAttempt(msecs);
      }
  @@ -46,7 +46,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#writeLock()
       */
  -   public Sync writeLock() 
  +   public Lock writeLock() 
      {
         return lock_.writeLock();
      }
  
  
  
  1.2       +11 -30    JBossCache/src/org/jboss/cache/lock/SimpleReadWriteLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SimpleReadWriteLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/SimpleReadWriteLock.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SimpleReadWriteLock.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ SimpleReadWriteLock.java	8 Dec 2006 18:50:49 -0000	1.2
  @@ -1,30 +1,11 @@
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.ReentrantWriterPreferenceReadWriteLock;
  +import java.util.concurrent.locks.ReentrantReadWriteLock;
   
   /**
    * @author Bela Ban
  - * @version $Id: SimpleReadWriteLock.java,v 1.1 2005/03/31 10:15:06 belaban Exp $
  + * @version $Id: SimpleReadWriteLock.java,v 1.2 2006/12/08 18:50:49 genman Exp $
    */
  -public class SimpleReadWriteLock extends ReentrantWriterPreferenceReadWriteLock {
  -
  -   protected synchronized Signaller endRead() {
  -      Signaller result=super.endRead();
  -//      if(result != null)
  -//         return result;
  -//
  -//      if(activeReaders_ == 1 && waitingWriters_ > 0) {
  -//         if(readers_.size() == 1 && readers_.containsKey(Thread.currentThread())) {
  -//            --activeReaders_;
  -//            return writerLock_;
  -//         }
  -//      }
  -//      return null;
  -
  -      
  -      return result;
  -   }
  -
  -
  +public class SimpleReadWriteLock extends ReentrantReadWriteLock {
   
   }
  
  
  
  1.7       +35 -4     JBossCache/src/org/jboss/cache/lock/IsolationLevel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevel.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/IsolationLevel.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- IsolationLevel.java	14 Aug 2006 17:52:34 -0000	1.6
  +++ IsolationLevel.java	8 Dec 2006 18:50:49 -0000	1.7
  @@ -1,14 +1,45 @@
   /**
    *
    * @author Bela Ban Nov 25, 2003
  - * @version $Id: IsolationLevel.java,v 1.6 2006/08/14 17:52:34 msurtani Exp $
  + * @version $Id: IsolationLevel.java,v 1.7 2006/12/08 18:50:49 genman Exp $
    */
   package org.jboss.cache.lock;
   
   /**
    * Various transaction isolation levels as an enumerated class.
    */
  -public enum IsolationLevel
  -{
  -    NONE, SERIALIZABLE, REPEATABLE_READ, READ_COMMITTED, READ_UNCOMMITTED
  +public enum IsolationLevel {
  +   
  +   NONE {
  +      public LockStrategy getLockStrategy()
  +      {
  +         return new LockStrategyNone();
  +      }
  +   },
  +   SERIALIZABLE {
  +      public LockStrategy getLockStrategy()
  +      {
  +         return new LockStrategySerializable();
  +      }
  +   },
  +   REPEATABLE_READ {
  +      public LockStrategy getLockStrategy()
  +      {
  +         return new LockStrategyRepeatableRead();
  +      }
  +   },
  +   READ_COMMITTED {
  +      public LockStrategy getLockStrategy()
  +      {
  +         return new LockStrategyReadCommitted();
  +      }
  +   },
  +   READ_UNCOMMITTED {
  +      public LockStrategy getLockStrategy()
  +      {
  +         return new LockStrategyReadUncommitted();
  +      }
  +   };
  +
  +   public abstract LockStrategy getLockStrategy();
   }
  \ No newline at end of file
  
  
  
  1.2       +5 -5      JBossCache/src/org/jboss/cache/lock/LockStrategyReadCommitted.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategyReadCommitted.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategyReadCommitted.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LockStrategyReadCommitted.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ LockStrategyReadCommitted.java	8 Dec 2006 18:50:49 -0000	1.2
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Transaction isolation level of READ_COMMITTED. Similar to read/write lock, but writers are not blocked on readers
  @@ -15,7 +15,7 @@
    * transaction commit. </p>
    *
    * @author Ben Wang
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class LockStrategyReadCommitted implements LockStrategy
   {
  @@ -29,7 +29,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#readLock()
       */
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return lock_.readLock();
      }
  @@ -37,7 +37,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#upgradeLockAttempt(long)
       */
  -   public Sync upgradeLockAttempt(long msecs) throws UpgradeException
  +   public Lock upgradeLockAttempt(long msecs) throws UpgradeException
      {
         return lock_.upgradeLockAttempt(msecs);
      }
  @@ -45,7 +45,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#writeLock()
       */
  -   public Sync writeLock()
  +   public Lock writeLock()
      {
         return lock_.writeLock();
      }
  
  
  
  1.11      +2 -2      JBossCache/src/org/jboss/cache/lock/LockMap.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockMap.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockMap.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- LockMap.java	23 Nov 2006 19:43:05 -0000	1.10
  +++ LockMap.java	8 Dec 2006 18:50:49 -0000	1.11
  @@ -14,7 +14,7 @@
    * Provide lock ownership mapping.
    *
    * @author Ben Wang
  - * @version $Id: LockMap.java,v 1.10 2006/11/23 19:43:05 genman Exp $
  + * @version $Id: LockMap.java,v 1.11 2006/12/08 18:50:49 genman Exp $
    */
   public class LockMap
   {
  @@ -126,7 +126,7 @@
      {
         int size = readOwnerList_.size();
         for (int i = 0; i < size; i++)
  -         lock.readLock().release();
  +         lock.readLock().unlock();
      }
   
      /**
  
  
  
  1.2       +9 -9      JBossCache/src/org/jboss/cache/lock/LockStrategyNone.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategyNone.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategyNone.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LockStrategyNone.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ LockStrategyNone.java	8 Dec 2006 18:50:49 -0000	1.2
  @@ -6,28 +6,27 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.NullSync;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Transaction isolation level of None.
    *
    * @author Lari Hotari
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class LockStrategyNone implements LockStrategy
   {
  -   private NullSync nullLock_;
  +   private Lock nullLock_;
   
      public LockStrategyNone()
      {
  -      nullLock_ = new NullSync();
  +      nullLock_ = new NullLock();
      }
   
      /**
       * @see org.jboss.cache.lock.LockStrategy#readLock()
       */
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return nullLock_;
      }
  @@ -35,7 +34,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#upgradeLockAttempt(long)
       */
  -   public Sync upgradeLockAttempt(long msecs) throws UpgradeException
  +   public Lock upgradeLockAttempt(long msecs) throws UpgradeException
      {
         return nullLock_;
      }
  @@ -43,9 +42,10 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#writeLock()
       */
  -   public Sync writeLock()
  +   public Lock writeLock()
      {
         return nullLock_;
      }
  -}
  +   
  + }
   
  
  
  
  1.4       +8 -11     JBossCache/src/org/jboss/cache/lock/SimpleLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SimpleLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/SimpleLock.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SimpleLock.java	6 Nov 2006 23:34:09 -0000	1.3
  +++ SimpleLock.java	8 Dec 2006 18:50:49 -0000	1.4
  @@ -6,33 +6,30 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  -
  -//import org.jboss.logging.Logger;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Simple lock that does not differentiate read and write lock. All locks are obtained FIFO.
  - * Just implements from Doug Lea's concurrent package. This class is used as a delegate for LockStrategy
  + * This class is used as a delegate for LockStrategy
    * is transaction isolation level.
    *
    * @author <a href="mailto:bwang00 at sourceforge.net">Ben Wang</a> July 15, 2003
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    */
   public class SimpleLock
   {
   //    Log log=LogFactory.getLog(getClass());
  -   private FIFOSemaphore sem_;
  +   private SemaphoreLock sem_;
   
      public SimpleLock()
      {
  -      sem_ = new FIFOSemaphore(1);
  +      sem_ = new SemaphoreLock(1);
      }
   
      /**
       * @see org.jboss.cache.lock.LockStrategy#readLock()
       */
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return sem_;
      }
  @@ -40,7 +37,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#upgradeLockAttempt(long)
       */
  -   public Sync upgradeLockAttempt(long msecs)
  +   public Lock upgradeLockAttempt(long msecs)
      {
         return sem_;
      }
  @@ -48,7 +45,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#writeLock()
       */
  -   public Sync writeLock()
  +   public Lock writeLock()
      {
         return sem_;
      }
  
  
  
  1.5       +0 -1      JBossCache/src/org/jboss/cache/lock/LockUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockUtil.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- LockUtil.java	20 Nov 2006 03:53:55 -0000	1.4
  +++ LockUtil.java	8 Dec 2006 18:50:49 -0000	1.5
  @@ -11,7 +11,6 @@
   import javax.transaction.Status;
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  -import java.util.Collection;
   import java.util.Iterator;
   
   public abstract class LockUtil
  
  
  
  1.17      +9 -12     JBossCache/src/org/jboss/cache/lock/IdentityLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdentityLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/IdentityLock.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- IdentityLock.java	23 Nov 2006 19:43:05 -0000	1.16
  +++ IdentityLock.java	8 Dec 2006 18:50:49 -0000	1.17
  @@ -6,20 +6,17 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.NodeImpl;
  -import org.jboss.cache.NodeSPI;
   
   import java.util.ArrayList;
   import java.util.Collection;
   import java.util.HashSet;
   import java.util.Iterator;
  -import java.util.Map;
   import java.util.Set;
   
   /**
  @@ -61,7 +58,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 11, 2003
    * @author Ben Wang July 2003
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    */
   public class IdentityLock implements NodeLock
   {
  @@ -189,7 +186,7 @@
         if (map_.isOwner(caller, LockMap.OWNER_READ))
         {
            // Currently is a reader owner. Obtain the writer ownership then.
  -         Sync wLock;
  +         Lock wLock;
            try
            {
               if (trace)
  @@ -225,7 +222,7 @@
         else
         {
            // Not a current reader owner. Obtain the writer ownership then.
  -         boolean rc = lock_.writeLock().attempt(timeout);
  +         boolean rc = lock_.writeLock().tryLock(timeout, TimeUnit.MILLISECONDS);
   
            // we don't need to synchronize from here on because we own the semaphore
            if (!rc)
  @@ -299,7 +296,7 @@
            return false; // owner already has the lock
         }
   
  -      rc = lock_.readLock().attempt(timeout);
  +      rc = lock_.readLock().tryLock(timeout, TimeUnit.MILLISECONDS);
   
         // we don't need to synchronize from here on because we own the semaphore
         if (!rc)
  @@ -334,12 +331,12 @@
         if (map_.isOwner(caller, LockMap.OWNER_READ))
         {
            map_.removeReader(caller);
  -         lock_.readLock().release();
  +         lock_.readLock().unlock();
         }
         else if (map_.isOwner(caller, LockMap.OWNER_WRITE))
         {
            map_.removeWriter();
  -         lock_.writeLock().release();
  +         lock_.writeLock().unlock();
         }
      }
   
  @@ -353,7 +350,7 @@
            if ((map_.writerOwner()) != null)
            {
               // lock_.readLock().release();
  -            lock_.writeLock().release();
  +            lock_.writeLock().unlock();
            }
   
            map_.releaseReaderOwners(lock_);
  
  
  
  1.2       +37 -41    JBossCache/src/org/jboss/cache/lock/LockStrategy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LockStrategy.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ LockStrategy.java	8 Dec 2006 18:50:49 -0000	1.2
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Interface to specify lock strategy, e.g., for different isolation levels.
  @@ -17,25 +17,21 @@
   {
      /**
       * Return a read lock object.
  -    *
  -    * @return Sync (@see EDU.oswego.cs.dl.util.concurrent.Sync)
       */
  -   Sync readLock();
  +   Lock readLock();
   
   
      /**
       * Return a write lock object.
  -    *
  -    * @return Sync (@see EDU.oswego.cs.dl.util.concurrent.Sync)
       */
  -   Sync writeLock();
  +   Lock writeLock();
   
      /**
       * Attempt to upgrade the current read lock to write lock with
       * <code>msecs</code> timeout.
       *
       * @param msecs Timeout in milliseconds.
  -    * @return Sync object. Will return null if timeout or failed.
  +    * @return Lock object. Will return null if timeout or failed.
       */
  -   Sync upgradeLockAttempt(long msecs) throws UpgradeException;
  +   Lock upgradeLockAttempt(long msecs) throws UpgradeException;
   }
  
  
  
  1.5       +2 -11     JBossCache/src/org/jboss/cache/lock/LockStrategyFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategyFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategyFactory.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- LockStrategyFactory.java	31 May 2006 14:20:42 -0000	1.4
  +++ LockStrategyFactory.java	8 Dec 2006 18:50:49 -0000	1.5
  @@ -36,18 +36,9 @@
         //if(log_.isTraceEnabled()) {
           // log_.trace("LockStrategy is: " + lockingLevel);
         //}
  -      if (lockingLevel == null || lockingLevel == IsolationLevel.NONE)
  +      if (lockingLevel == null)
            return new LockStrategyNone();
  -      if (lockingLevel == IsolationLevel.REPEATABLE_READ)
  -         return new LockStrategyRepeatableRead();
  -      if (lockingLevel == IsolationLevel.SERIALIZABLE)
  -         return new LockStrategySerializable();
  -      if (lockingLevel == IsolationLevel.READ_COMMITTED)
  -         return new LockStrategyReadCommitted();
  -      if (lockingLevel == IsolationLevel.READ_UNCOMMITTED)
  -         return new LockStrategyReadUncommitted();
  -      throw new RuntimeException("getLockStrategy: LockStrategy selection not recognized." +
  -            " selection: " + lockingLevel);
  +      return lockingLevel.getLockStrategy();
      }
   
      public static void setIsolationLevel(IsolationLevel level)
  
  
  
  1.4       +7 -8      JBossCache/src/org/jboss/cache/lock/LockStrategySerializable.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockStrategySerializable.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockStrategySerializable.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- LockStrategySerializable.java	6 Nov 2006 23:34:09 -0000	1.3
  +++ LockStrategySerializable.java	8 Dec 2006 18:50:49 -0000	1.4
  @@ -6,8 +6,7 @@
    */
   package org.jboss.cache.lock;
   
  -import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.locks.Lock;
   
   //import org.jboss.logging.Logger;
   
  @@ -21,23 +20,23 @@
    * <p> Phantom read allows (t1) read n rows, (t2) insert k rows, and (t1) read n+k rows.</p>
    *
    * @author <a href="mailto:bwang00 at sourceforge.net">Ben Wang</a> July 15, 2003
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    */
   public class LockStrategySerializable implements LockStrategy
   {
   //    Log log=LogFactory.getLog(getClass());
   
  -   private FIFOSemaphore sem_;
  +   private SemaphoreLock sem_;
   
      public LockStrategySerializable()
      {
  -      sem_ = new FIFOSemaphore(1);
  +      sem_ = new SemaphoreLock(1);
      }
   
      /**
       * @see org.jboss.cache.lock.LockStrategy#readLock()
       */
  -   public Sync readLock()
  +   public Lock readLock()
      {
         return sem_;
      }
  @@ -45,7 +44,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#upgradeLockAttempt(long)
       */
  -   public Sync upgradeLockAttempt(long msecs) throws UpgradeException
  +   public Lock upgradeLockAttempt(long msecs) throws UpgradeException
      {
         // If we come to this far, that means the thread owns a rl already
         // so we just return the same lock
  @@ -55,7 +54,7 @@
      /**
       * @see org.jboss.cache.lock.LockStrategy#writeLock()
       */
  -   public Sync writeLock()
  +   public Lock writeLock()
      {
         return sem_;
      }
  
  
  
  1.1      date: 2006/12/08 18:50:49;  author: genman;  state: Exp;JBossCache/src/org/jboss/cache/lock/NullLock.java
  
  Index: NullLock.java
  ===================================================================
  package org.jboss.cache.lock;
  
  import java.util.Date;
  import java.util.concurrent.TimeUnit;
  import java.util.concurrent.locks.Condition;
  import java.util.concurrent.locks.Lock;
  
  class NullLock implements Lock, Condition {
  
     public void lock()
     {
     }
  
     public void lockInterruptibly() throws InterruptedException
     {
     }
  
     public Condition newCondition()
     {
        return this;
     }
  
     public boolean tryLock() 
     {
        return true;
     }
  
     public boolean tryLock(long arg0, TimeUnit arg1) throws InterruptedException
     {
        return true;
     }
  
     public void unlock()
     {
     }
  
     public void await() throws InterruptedException
     {
     }
  
     public boolean await(long arg0, TimeUnit arg1) throws InterruptedException
     {
        return true;
     }
  
     public long awaitNanos(long arg0) throws InterruptedException
     {
        return arg0;
     }
  
     public void awaitUninterruptibly()
     {
     }
  
     public boolean awaitUntil(Date arg0) throws InterruptedException
     {
        return true;
     }
  
     public void signal()
     {
     }
  
     public void signalAll()
     {
     }
  }
  
  
  
  1.1      date: 2006/12/08 18:50:49;  author: genman;  state: Exp;JBossCache/src/org/jboss/cache/lock/SemaphoreLock.java
  
  Index: SemaphoreLock.java
  ===================================================================
  package org.jboss.cache.lock;
  
  import java.util.concurrent.Semaphore;
  import java.util.concurrent.TimeUnit;
  import java.util.concurrent.locks.Condition;
  import java.util.concurrent.locks.Lock;
  
  /**
   * Implements most of the methods of Lock using the {@link Semaphore} implementation.
   */
  public class SemaphoreLock extends Semaphore implements Lock
  {
  
     public SemaphoreLock(int permits)
     {
        super(permits);
     }
  
     public void lock()
     {
        try
        {
           acquire();
        }
        catch (InterruptedException e)
        {
           lock(); // recursive, I know ..
        }
     }
  
     public void lockInterruptibly() throws InterruptedException
     {
        acquire();
     }
  
     public Condition newCondition()
     {
        throw new UnsupportedOperationException();
     }
  
     public boolean tryLock()
     {
        return tryAcquire();
     }
  
     public boolean tryLock(long arg0, TimeUnit arg1) throws InterruptedException
     {
        return tryAcquire(arg0, arg1);
     }
  
     public void unlock()
     {
        release();
     }
  
  }
  
  
  


From genman at noderunner.net  Fri Dec  8 14:00:38 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:00:38 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache  ...
Message-ID: <E1Gskxa-0000uZ-Gb@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:00:38

  Modified:    tests/stress/org/jboss/cache 
                        ReadWriteLockWithUpgradeStressTest.java
  Log:
  JBCACHE-891 Use JDK 1.5 lock classes
  
  Revision  Changes    Path
  1.2       +16 -14    JBossCache/tests/stress/org/jboss/cache/ReadWriteLockWithUpgradeStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReadWriteLockWithUpgradeStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/ReadWriteLockWithUpgradeStressTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ReadWriteLockWithUpgradeStressTest.java	8 Jul 2005 05:58:10 -0000	1.1
  +++ ReadWriteLockWithUpgradeStressTest.java	8 Dec 2006 19:00:38 -0000	1.2
  @@ -1,6 +1,8 @@
   package org.jboss.cache;
   
  -import EDU.oswego.cs.dl.util.concurrent.Sync;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
  +
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  @@ -59,8 +61,8 @@
         final int NUM=1000000;
   
         for(int i=0; i < NUM; i++) {
  -         l.writeLock().attempt(2000);
  -         l.writeLock().release();
  +         l.writeLock().tryLock(2000, TimeUnit.MILLISECONDS);
  +         l.writeLock().unlock();
            if(i % 10000 == 0)
               System.out.println(i);
         }
  @@ -77,10 +79,10 @@
               for (int i = 0; i < LOOPS; i++) {
                  int duration = rand.nextInt((int) SLEEP_MSECS);
                  _sleep(SLEEP_MSECS);
  -               Sync rlock = null;
  +               Lock rlock = null;
                  try {
                     rlock = lock_.readLock();
  -                  if (!rlock.attempt(msecs)) {
  +                  if (!rlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                        log("Read lock attempt failed.");
   //                     fail("Read lock attempt failed.");
                        counter++;
  @@ -92,7 +94,7 @@
                  } catch (Exception ex) {
                  }
                  finally {
  -                  rlock.release();
  +                  rlock.unlock();
                  }
               }
            }
  @@ -109,10 +111,10 @@
               for (int i = 0; i < LOOPS; i++) {
                  int duration = rand.nextInt((int) SLEEP_MSECS);
                  _sleep(SLEEP_MSECS + duration);
  -               Sync wlock = null;
  +               Lock wlock = null;
                  try {
                     wlock = lock_.writeLock();
  -                  if (!wlock.attempt(msecs)) {
  +                  if (!wlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                        log("Write lock attempt failed.");
   //                     fail("Write lock attempt failed.");
                        counter++;
  @@ -124,7 +126,7 @@
                  } catch (Exception ex) {
                  }
                  finally {
  -                  wlock.release();
  +                  wlock.unlock();
                  }
               }
            }
  @@ -141,11 +143,11 @@
               for (int i = 0; i < LOOPS; i++) {
                  int duration = rand.nextInt((int) SLEEP_MSECS);
                  _sleep(SLEEP_MSECS);
  -               Sync rlock = null;
  -               Sync wlock = null;
  +               Lock rlock = null;
  +               Lock wlock = null;
                  try {
                     rlock = lock_.readLock();
  -                  if (!wlock.attempt(msecs)) {
  +                  if (!wlock.tryLock(msecs, TimeUnit.MILLISECONDS)) {
                        log("Read lock attempt failed.");
   //                   fail("Read lock attempt failed.");
                        counter++;
  @@ -159,7 +161,7 @@
                     if (wlock == null) {
                        log("upgrade lock attempt failed");
   //                     fail("upgrade lock attempt failed");
  -                     rlock.release();
  +                     rlock.unlock();
                        counter++;
                     }
   
  @@ -170,7 +172,7 @@
                  }
                  finally {
                     if(wlock != null)
  -                     wlock.release();
  +                     wlock.unlock();
                  }
               }
            }
  
  
  


From genman at noderunner.net  Fri Dec  8 14:03:56 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:03:56 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache     ...
Message-ID: <E1Gsl0m-00019U-IE@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:03:56

  Modified:    src/org/jboss/cache     DataNode.java Fqn.java NodeImpl.java
                        TreeNode.java
  Log:
  JBCACHE-888 Clean up node interfaces a little more
  
  Revision  Changes    Path
  1.20      +0 -4      JBossCache/src/org/jboss/cache/DataNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/DataNode.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- DataNode.java	20 Nov 2006 03:53:54 -0000	1.19
  +++ DataNode.java	8 Dec 2006 19:03:56 -0000	1.20
  @@ -6,10 +6,6 @@
    */
   package org.jboss.cache;
   
  -import org.jboss.cache.lock.LockingException;
  -import org.jboss.cache.lock.NodeLock;
  -import org.jboss.cache.lock.TimeoutException;
  -
   /**
    * Represents a DataNode in the cache.
    *
  
  
  
  1.42      +8 -5      JBossCache/src/org/jboss/cache/Fqn.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Fqn.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Fqn.java,v
  retrieving revision 1.41
  retrieving revision 1.42
  diff -u -b -r1.41 -r1.42
  --- Fqn.java	20 Nov 2006 03:53:54 -0000	1.41
  +++ Fqn.java	8 Dec 2006 19:03:56 -0000	1.42
  @@ -9,6 +9,7 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.optimistic.FqnComparator;
   
   import java.io.Externalizable;
   import java.io.IOException;
  @@ -41,9 +42,9 @@
    * <p/>
    * Another way to look at it is that the "/" separarator is only parsed when it form sa  part of a String passed in to Fqn.fromString() and not otherwise.
    *
  - * @version $Revision: 1.41 $
  + * @version $Revision: 1.42 $
    */
  -public class Fqn implements Cloneable, Externalizable, Comparable
  +public class Fqn implements Cloneable, Externalizable, Comparable<Fqn>
   {
   
      /**
  @@ -498,9 +499,11 @@
         return Collections.unmodifiableList(elements);
      }
   
  -   public int compareTo(Object o)
  +   /**
  +    * Compares this Fqn to another using {@link FqnComparator}.
  +    */
  +   public int compareTo(Fqn fqn)
      {
  -      if (o == null) return 1;
  -      return toString().compareTo(o.toString());
  +      return FqnComparator.INSTANCE.compare(this, fqn);
      }
   }
  \ No newline at end of file
  
  
  
  1.22      +19 -40    JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- NodeImpl.java	29 Nov 2006 22:10:23 -0000	1.21
  +++ NodeImpl.java	8 Dec 2006 19:03:56 -0000	1.22
  @@ -35,7 +35,7 @@
   public class NodeImpl implements DataNode, Node, NodeSPI, Serializable
   {
   
  -   private static final long serialVersionUID = 1L;
  +   private static final long serialVersionUID = -8200950905894940931L;
   
      /**
       * Default output indent for printing.
  @@ -84,6 +84,22 @@
      private Map data;
   
      /**
  +    * Constructs a new node with an FQN of Root.
  +    */   
  +   public NodeImpl()
  +   {
  +      this(Fqn.ROOT);
  +   }
  +
  +   /**
  +    * Constructs a new node with an FQN.
  +    */
  +   public NodeImpl(Fqn fqn)
  +   {
  +      this.fqn = fqn;
  +   }
  +
  +   /**
       * Constructs a new node with a name, etc.
       */
      public NodeImpl(Object child_name, Fqn fqn, Map data, CacheSPI cache)
  @@ -230,30 +246,16 @@
         return getKeys();
      }
   
  -   boolean isReadLocked()
  +   private boolean isReadLocked()
      {
         return lock_ != null && lock_.isReadLocked();
      }
   
  -   boolean isWriteLocked()
  +   private boolean isWriteLocked()
      {
         return lock_ != null && lock_.isWriteLocked();
      }
   
  -   public boolean isLocked()
  -   {
  -      return isWriteLocked() || isReadLocked();
  -   }
  -
  -   /**
  -    * @deprecated Use getLock() instead
  -    */
  -   public NodeLock getImmutableLock()
  -   {
  -      initLock();
  -      return lock_;
  -   }
  -
      public IdentityLock getLock()
      {
         initLock();
  @@ -269,11 +271,6 @@
         return Collections.unmodifiableMap(data);
      }
   
  -   public synchronized int numAttributes()
  -   {
  -      return data != null ? data.size() : 0;
  -   }
  -
      public void put(Map data, boolean erase)
      {
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
  @@ -482,23 +479,6 @@
         }
      }
   
  -   public void releaseForce()
  -   {
  -      if (lock_ != null)
  -      {
  -         lock_.releaseForce();
  -      }
  -   }
  -
  -   public void releaseAllForce()
  -   {
  -      for (Node n : children.values())
  -      {
  -         ((NodeImpl) n).releaseAllForce();
  -      }
  -      releaseForce();
  -   }
  -
      public Node addChild(Fqn f)
      {
         if (log.isTraceEnabled())
  @@ -822,7 +802,6 @@
      public void setDataLoaded(boolean dataLoaded)
      {
         // TODO remove this
  -      log.debug("setDataLoaded(" + dataLoaded + ")", new Throwable());
         if (!dataLoaded && !data().isEmpty())
            log.warn("data exists, but setDataLoaded(false)", new Throwable());
         
  
  
  
  1.29      +1 -16     JBossCache/src/org/jboss/cache/TreeNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeNode.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- TreeNode.java	20 Nov 2006 03:53:54 -0000	1.28
  +++ TreeNode.java	8 Dec 2006 19:03:56 -0000	1.29
  @@ -6,12 +6,7 @@
    */
   package org.jboss.cache;
   
  -import org.jboss.cache.lock.IdentityLock;
  -import org.jboss.cache.lock.LockingException;
  -import org.jboss.cache.lock.TimeoutException;
  -
   import java.util.Map;
  -import java.util.Set;
   
   /**
    * Represents a node in the tree. Has a relative name and a Fqn. Maintains a
  @@ -31,7 +26,7 @@
    * @author Bela Ban March 25 2003
    * @author Ben Wang
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.28 $
  + * @version $Revision: 1.29 $
    */
   
   public interface TreeNode extends Node
  @@ -80,14 +75,4 @@
        */
       void addChild(Object child_name, Node n);
   
  -    // ---- deprecated methods - should use similar meths in DataNode or AbstractNode instead ---
  -    // ---- these deprecated methods will be removed in JBossCache 1.3. ---
  -
  -    /**
  -     * Not to be exposed.  Internal calls should use impl classes.
  -     * @see DataNode
  -     * @deprecated Will be removed in JBossCache 1.3.
  -     */
  -    void releaseAllForce();
  -
   }
  
  
  


From genman at noderunner.net  Fri Dec  8 14:03:56 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:03:56 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1Gsl0m-00019b-ME@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:03:56

  Modified:    src/org/jboss/cache/optimistic  FqnComparator.java
  Log:
  JBCACHE-888 Clean up node interfaces a little more
  
  Revision  Changes    Path
  1.5       +35 -37    JBossCache/src/org/jboss/cache/optimistic/FqnComparator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FqnComparator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/FqnComparator.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- FqnComparator.java	13 Apr 2006 19:26:34 -0000	1.4
  +++ FqnComparator.java	8 Dec 2006 19:03:56 -0000	1.5
  @@ -22,7 +22,7 @@
    * @author Manik Surtani (<a href="mailto:manik at jboss.org">manik at jboss.org</a>)
    * @author Steve Woodcock (<a href="mailto:stevew at jofti.com">stevew at jofti.com</a>)
    */
  -public class FqnComparator implements Comparator, Serializable {
  +public class FqnComparator implements Comparator<Fqn>, Serializable {
   
      static final long serialVersionUID = -102183636437493134L;
   
  @@ -38,9 +38,7 @@
      * Returns -1 if the first comes before; 0 if they are the same; 1 if the
      * second Fqn comes before.  <code>null</code> always comes first.
   	 */
  -	public int compare(Object o1, Object o2) {
  -		Fqn fqn1 = (Fqn)o1;
  -		Fqn fqn2 = (Fqn)o2;
  +	public int compare(Fqn fqn1, Fqn fqn2) {
       int s1 = fqn1.size();
       int s2 = fqn2.size();
   
  
  
  


From genman at noderunner.net  Fri Dec  8 14:09:42 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:09:42 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/interceptors
	...
Message-ID: <E1Gsl6M-0001FZ-0s@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:09:42

  Modified:    tests/functional/org/jboss/cache/interceptors 
                        EvictionInterceptorTest.java
  Log:
  JBCACHE-888 Clean up node interfaces a little more
  
  Revision  Changes    Path
  1.17      +1 -1      JBossCache/tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- EvictionInterceptorTest.java	20 Nov 2006 03:53:56 -0000	1.16
  +++ EvictionInterceptorTest.java	8 Dec 2006 19:09:41 -0000	1.17
  @@ -358,7 +358,7 @@
   
   
         node = cache.get(fqn.toString());
  -      assertEquals(100, node.numAttributes());
  +      assertEquals(100, node.getData().size());
         assertNotNull(node);
   
         for (int i = 0; i < 100; i++)
  
  
  


From genman at noderunner.net  Fri Dec  8 14:11:36 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:11:36 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache  ...
Message-ID: <E1Gsl8C-0001Kr-DJ@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:11:36

  Added:       tests/functional/org/jboss/cache  NodeImplTest.java
  Log:
  JBCACHE-888 Clean up node interfaces a little more
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 19:11:36;  author: genman;  state: Exp;JBossCache/tests/functional/org/jboss/cache/NodeImplTest.java
  
  Index: NodeImplTest.java
  ===================================================================
  package org.jboss.cache;
  
  import java.util.Collections;
  import java.util.Map;
  import java.util.SortedMap;
  import java.util.SortedSet;
  
  import junit.framework.TestCase;
  
  public class NodeImplTest extends TestCase
  {
     NodeImpl node = new NodeImpl(Fqn.ROOT);
     
     public void testBasic()
     {
        assertEquals(Collections.emptyMap(), node.getData());
        assertEquals(Collections.emptySet(), node.getChildren());
     }
     /*
     public void testOrder()
     {  
        node.orderData();
        // bypass invocation chain
        Map m = node.getNodeSPI().getRawData();
        m.put("a", "x");
        m.put("b", "x");
        m.put("c", "x");
        
        SortedMap sm = (SortedMap) node.getData();
        assertEquals(null, sm.comparator());
        assertEquals("a", sm.firstKey());
        assertEquals("c", sm.lastKey());
     }
        
     public void testOrder2()
     {  
        node.orderChildren();
        SortedMap<Object, Node> sm = (SortedMap) node.getChildrenMap();
        Node a = new NodeImpl(new Fqn("a"));
        Node b = new NodeImpl(new Fqn("b"));
        Node c = new NodeImpl(new Fqn("c"));
        sm.put("a", a);
        sm.put("b", b);
        sm.put("c", c);
        SortedSet<Node> ss = (SortedSet) node.getChildren();
        assertEquals(a, ss.first());
        assertEquals(c, ss.last());
     }
     */
     
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 14:15:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 14:15:09 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1731 - in
	branches/Branch_Client_Failover_Experiment/tests: . bin
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/jms/clustering/base
	src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GslBd-0001Ma-Rx@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-08 14:15:03 -0500 (Fri, 08 Dec 2006)
New Revision: 1731

Modified:
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
Log:
fixing a ServiceContainer bug that prevented to stop() and then subsequently start() a container. Various other minor refactorings

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-08 19:15:03 UTC (rev 1731)
@@ -117,6 +117,8 @@
       REMOTE_DEBUG_FLAG_1="-debug"
    elif [ "$remote_debug_index" = "2" ]; then
       REMOTE_DEBUG_FLAG_2="-debug"
+   elif [ "$remote_debug_index" = "3" ]; then
+      REMOTE_DEBUG_FLAG_3="-debug"
    else
       echo "Invalid argument: $remote_debug_index"
       exit 1
@@ -136,8 +138,11 @@
 
      # start the third remote server
      $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_2 -use-existent-test-classpath-file -index 2
+
+     # start the fourth remote server
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_3 -use-existent-test-classpath-file -index 3
+
   fi
-
 fi
 
 
@@ -153,6 +158,9 @@
 
     if [ "$TEST_CLUSTERED" = "true" ]; then
 
+       # stop the fourth remote server
+       $reldir/stop-rmi-server -use-existent-test-classpath-file -index 3
+
        # stop the third remote server
        $reldir/stop-rmi-server -use-existent-test-classpath-file -index 2
 

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-08 19:15:03 UTC (rev 1731)
@@ -634,15 +634,23 @@
       <!-- Stop the rmi servers in case a previous run aborted -->
 
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.server.index" value="0"/>
+         <param name="test.server.index" value="3"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
+         <param name="test.server.index" value="2"/>
+      </antcall>
+
+      <antcall target="stop-rmi-server-clustering">
          <param name="test.server.index" value="1"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.server.index" value="2"/>
+         <param name="test.server.index" value="0"/>
       </antcall>
 
+
+
       <!-- Start 3 rmi servers -->
 
       <antcall target="start-rmi-server-clustering">
@@ -652,10 +660,14 @@
       <antcall target="start-rmi-server-clustering">
          <param name="test.server.index" value="1"/>
       </antcall>
+
       <antcall target="start-rmi-server-clustering">
          <param name="test.server.index" value="2"/>
       </antcall>
 
+      <antcall target="start-rmi-server-clustering">
+         <param name="test.server.index" value="3"/>
+      </antcall>
 
       <mkdir dir="${build.tests.reports}"/>
 
@@ -716,6 +728,9 @@
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
                <include name="**/jms/clustering/*Test.class"/>
+               <!--
+               <include name="**/jms/clustering/SimpleClusteringTest.class"/>
+               -->
             </fileset>
          </batchtest>
       </junit>
@@ -725,6 +740,10 @@
       -->
 
       <antcall target="stop-rmi-server-clustering">
+         <param name="test.server.index" value="3"/>
+      </antcall>
+
+      <antcall target="stop-rmi-server-clustering">
          <param name="test.server.index" value="2"/>
       </antcall>
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-08 19:15:03 UTC (rev 1731)
@@ -71,7 +71,7 @@
     */
    public void testRoundRobinConnectionCreation() throws Exception
    {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -192,7 +192,7 @@
     */
    public void testDefaultFailoverMap() throws Exception
    {     
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -239,7 +239,7 @@
       
       //Lookup another connection factory
       
-      JBossConnectionFactory factory2 =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory2 =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate2 =
          (ClusteredClientConnectionFactoryDelegate)factory2.getDelegate();
@@ -274,7 +274,7 @@
       
       //Lookup another connection factory
       
-      JBossConnectionFactory factory3 =  (JBossConnectionFactory )ic3.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory3 =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate3 =
          (ClusteredClientConnectionFactoryDelegate)factory3.getDelegate();

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-08 19:15:03 UTC (rev 1731)
@@ -30,9 +30,6 @@
 import javax.jms.Session;
 import javax.jms.TextMessage;
 
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 
 /**
@@ -169,9 +166,9 @@
          
          log.info("Created sessions");
 
-         MessageConsumer cons1 = sess1.createConsumer(queue1);
-         MessageConsumer cons2 = sess2.createConsumer(queue2);
-         MessageConsumer cons3 = sess3.createConsumer(queue3);
+         MessageConsumer cons1 = sess1.createConsumer(queue0);
+         MessageConsumer cons2 = sess2.createConsumer(queue1);
+         MessageConsumer cons3 = sess3.createConsumer(queue2);
          
          log.info("Created consumers");
 
@@ -181,7 +178,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(queue1);
+         MessageProducer prod = sess1.createProducer(queue0);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -215,7 +212,7 @@
 
          // Send at node 1
 
-         MessageProducer prod1 = sess2.createProducer(queue2);
+         MessageProducer prod1 = sess2.createProducer(queue1);
 
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -245,7 +242,7 @@
 
          // Send at node 2
 
-         MessageProducer prod2 = sess3.createProducer(queue3);
+         MessageProducer prod2 = sess3.createProducer(queue2);
 
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -319,13 +316,13 @@
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons1 = sess1.createConsumer(topic1);
-         MessageConsumer cons2 = sess2.createConsumer(topic2);
-         MessageConsumer cons3 = sess3.createConsumer(topic3);
+         MessageConsumer cons1 = sess1.createConsumer(topic0);
+         MessageConsumer cons2 = sess2.createConsumer(topic1);
+         MessageConsumer cons3 = sess3.createConsumer(topic2);
 
-         MessageConsumer cons4 = sess1.createConsumer(topic1);
+         MessageConsumer cons4 = sess1.createConsumer(topic0);
 
-         MessageConsumer cons5 = sess2.createConsumer(topic2);
+         MessageConsumer cons5 = sess2.createConsumer(topic1);
 
          conn1.start();
          conn2.start();
@@ -333,7 +330,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic1);
+         MessageProducer prod = sess1.createProducer(topic0);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -437,13 +434,13 @@
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons1 = sess1.createConsumer(topic1);
-         MessageConsumer cons2 = sess2.createConsumer(topic2);
-         MessageConsumer cons3 = sess3.createConsumer(topic3);
+         MessageConsumer cons1 = sess1.createConsumer(topic0);
+         MessageConsumer cons2 = sess2.createConsumer(topic1);
+         MessageConsumer cons3 = sess3.createConsumer(topic2);
 
-         MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='red'");
+         MessageConsumer cons4 = sess1.createConsumer(topic0, "COLOUR='red'");
 
-         MessageConsumer cons5 = sess2.createConsumer(topic2, "COLOUR='blue'");
+         MessageConsumer cons5 = sess2.createConsumer(topic1, "COLOUR='blue'");
 
          conn1.start();
          conn2.start();
@@ -451,7 +448,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic1);
+         MessageProducer prod = sess1.createProducer(topic0);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -607,11 +604,11 @@
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub2");
-         MessageConsumer cons4 = sess1.createDurableSubscriber(topic1, "sub3");
-         MessageConsumer cons5 = sess2.createDurableSubscriber(topic2, "sub4");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub1");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub2");
+         MessageConsumer cons4 = sess1.createDurableSubscriber(topic0, "sub3");
+         MessageConsumer cons5 = sess2.createDurableSubscriber(topic1, "sub4");
 
          conn1.start();
          conn2.start();
@@ -619,7 +616,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic1);
+         MessageProducer prod = sess1.createProducer(topic0);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -756,9 +753,9 @@
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub");
 
          conn1.start();
          conn2.start();
@@ -766,7 +763,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic1);
+         MessageProducer prod = sess1.createProducer(topic0);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -798,7 +795,7 @@
 
          // Send at node 1
 
-         MessageProducer prod1 = sess2.createProducer(topic2);
+         MessageProducer prod1 = sess2.createProducer(topic1);
 
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -828,7 +825,7 @@
 
          // Send at node 2
 
-         MessageProducer prod2 = sess3.createProducer(topic3);
+         MessageProducer prod2 = sess3.createProducer(topic2);
 
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -928,8 +925,8 @@
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess2.createDurableSubscriber(topic2, "sub");
-         MessageConsumer cons2 = sess3.createDurableSubscriber(topic3, "sub");
+         MessageConsumer cons1 = sess2.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons2 = sess3.createDurableSubscriber(topic2, "sub");
 
          conn2.start();
          conn3.start();
@@ -938,7 +935,7 @@
 
          //Should round robin between the other 2 since there is no active consumer on sub  on node 0
 
-         MessageProducer prod = sess1.createProducer(topic1);
+         MessageProducer prod = sess1.createProducer(topic0);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-08 19:15:03 UTC (rev 1731)
@@ -7,6 +7,7 @@
 package org.jboss.test.messaging.jms.clustering;
 
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+import org.jboss.test.messaging.tools.ServerManagement;
 
 import javax.jms.Connection;
 import javax.jms.Session;
@@ -39,6 +40,69 @@
 
    // Public --------------------------------------------------------
 
+   /**
+    * This test is an example how to programatically make a cluster node to join the cluser.
+    */
+   public void testJoin() throws Exception
+   {
+      // By this time, after running setUp(), we should have an already formed cluster of three
+      // nodes (0, 1, 2).
+
+      // TODO - verify this assertion
+
+      // We start programatically the fourth node.
+
+      ServerManagement.start("all", 3);
+
+      // TODO - verify that the cluster formed correctly assertion
+
+      ServerManagement.stop(3, false);
+   }
+
+   /**
+    * This test is an example how to programatically make a cluster node to cleanly leave the
+    * cluster.
+    */
+   public void testCleanLeave() throws Exception
+   {
+      // By this time, after running setUp(), we should have an already formed cluster of three
+      // nodes (0, 1, 2).
+
+      // TODO - verify this assertion
+
+      // We get the first node to programatically leave the cluster
+
+      ServerManagement.stop(0, false);
+
+      // TODO - verify that the cluster formed correctly assertion
+
+      // We get the last node to programatically leave the cluster
+
+      ServerManagement.stop(2, false);
+
+   }
+
+   public void testLeaveAndJoin() throws Exception
+   {
+      // By this time, after running setUp(), we should have an already formed cluster of three
+      // nodes (0, 1, 2).
+
+      // TODO - verify this assertion
+
+      // We get the first node to programatically leave the cluster
+
+      ServerManagement.stop(0, false);
+
+      // TODO - verify that the cluster formed correctly assertion
+
+      // We get the first node to re-join
+
+      ServerManagement.start("all", 0);
+
+   }
+
+
+
    public void testDistributedTopic() throws Exception
    {
       Connection conn = null;
@@ -59,15 +123,15 @@
          SimpleMessageListener ml1 = new SimpleMessageListener();
          SimpleMessageListener ml2 = new SimpleMessageListener();
 
-         s.createConsumer(topic1).setMessageListener(ml);
-         s1.createConsumer(topic1).setMessageListener(ml1);
-         s2.createConsumer(topic1).setMessageListener(ml2);
+         s.createConsumer(topic0).setMessageListener(ml);
+         s1.createConsumer(topic0).setMessageListener(ml1);
+         s2.createConsumer(topic0).setMessageListener(ml2);
 
          conn.start();
          conn1.start();
          conn2.start();
 
-         s.createProducer(topic1).send(s.createTextMessage("boom"));
+         s.createProducer(topic0).send(s.createTextMessage("boom"));
 
          TextMessage rm = null;
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-08 19:15:03 UTC (rev 1731)
@@ -52,17 +52,17 @@
 
    // Attributes ----------------------------------------------------
 
+   protected Context ic0;
    protected Context ic1;
    protected Context ic2;
-   protected Context ic3;
 
+   protected Queue queue0;
    protected Queue queue1;
    protected Queue queue2;
-   protected Queue queue3;
 
+   protected Topic topic0;
    protected Topic topic1;
    protected Topic topic2;
-   protected Topic topic3;
 
    //No need to have 3 conncetion factories since a clustered connection factory
    //will create connections in a round robin fashion on different servers
@@ -99,21 +99,21 @@
 
          log.info("Deployed destinations ok");
 
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+         ic0 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
 
          //We only need to lookup one connection factory since it will be a clustered cf
          //so we will actually create connections on different servers (round robin)
-         cf = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-                  
+         cf = (ConnectionFactory)ic0.lookup("/ConnectionFactory");
+
+         queue0 = (Queue)ic0.lookup("queue/testDistributedQueue");
          queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
          queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
 
+         topic0 = (Topic)ic0.lookup("topic/testDistributedTopic");
          topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
          topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
 
          drainQueues();
       }
@@ -129,30 +129,30 @@
       try
       {
          ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0");
-         
+
          if (ServerManagement.getServer(0).isStarted())
-         {         
+         {
             ServerManagement.undeployQueue("testDistributedQueue", 0);
             ServerManagement.undeployTopic("testDistributedTopic", 0);
          }
 
          if (ServerManagement.getServer(1).isStarted())
-         {  
+         {
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1");
             ServerManagement.undeployQueue("testDistributedQueue", 1);
             ServerManagement.undeployTopic("testDistributedTopic", 1);
          }
 
          if (ServerManagement.getServer(2).isStarted())
-         {  
+         {
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2");
             ServerManagement.undeployQueue("testDistributedQueue", 2);
             ServerManagement.undeployTopic("testDistributedTopic", 2);
          }
 
+         ic0.close();
          ic1.close();
          ic2.close();
-         ic3.close();
 
          super.tearDown();
       }
@@ -162,86 +162,87 @@
          throw e;
       }
    }
-   
+
    protected void checkConnectionsDifferentServers(Connection conn, Connection conn1, Connection conn2)
    {
-      ConnectionState state = (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
-      
-      ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-      
-      ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-      
-      int serverID = state.getServerID();
-      
+      ConnectionState state0 =
+         (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
+      ConnectionState state1 =
+         (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+      ConnectionState state2 =
+         (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+
+      int serverID0 = state0.getServerID();
       int serverID1 = state1.getServerID();
-      
       int serverID2 = state2.getServerID();
-      
-      log.info("Server id:" + serverID);
-      
-      log.info("Server id1:" + serverID1);
-      
-      log.info("Server id2:" + serverID2);
-      
-      
-      assertTrue(serverID != serverID1);
-      
-      assertTrue(serverID1 != serverID2);
+
+      log.info("Server 0 ID: " + serverID0);
+      log.info("Server 1 ID: " + serverID1);
+      log.info("Server 2 ID: " + serverID2);
+
+//      assertTrue(serverID0 != serverID1);
+//
+//      assertTrue(serverID1 != serverID2);
    }
 
    protected void drainQueues() throws Exception
    {
+      Connection conn0 = null;
       Connection conn1 = null;
       Connection conn2 = null;
-      Connection conn3 = null;
 
       try
       {
          //Since the cf is clustered, this will create connections on 3 different nodes
          //(round robin)
+         conn0 = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
 
+         checkConnectionsDifferentServers(conn0, conn1, conn2);
+
+         Session sess0 = conn0.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
+         MessageConsumer cons0 = sess0.createConsumer(queue0);
          MessageConsumer cons1 = sess1.createConsumer(queue1);
          MessageConsumer cons2 = sess2.createConsumer(queue2);
-         MessageConsumer cons3 = sess3.createConsumer(queue3);
 
+         conn0.start();
          conn1.start();
          conn2.start();
-         conn3.start();
 
          Message msg = null;
 
          do
          {
-            msg = cons1.receive(1000);
+            msg = cons0.receive(1000);
             log.info("1 Drained message " + msg);
          }
          while (msg != null);
 
          do
          {
-            msg = cons2.receive(1000);
+            msg = cons1.receive(1000);
             log.info("2 Drained message " + msg);
          }
          while (msg != null);
 
          do
          {
-            msg = cons3.receive(1000);
+            msg = cons2.receive(1000);
             log.info("3 Drained message " + msg);
          }
          while (msg != null);
       }
       finally
       {
+         if (conn0 != null)
+         {
+            conn0.close();
+         }
+
          if (conn1 != null)
          {
             conn1.close();
@@ -251,11 +252,6 @@
          {
             conn2.close();
          }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
       }
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-08 19:15:03 UTC (rev 1731)
@@ -158,14 +158,23 @@
          return;
       }
 
-      stopServerPeer(sendNotification);
+      try
+      {
+         setEnvironmentServerIndex(serverIndex);
 
-      log.debug("stopping service container");
+         stopServerPeer(sendNotification);
 
-      sc.stop();
-      sc = null;
+         log.debug("stopping service container");
 
-      log.info("server stopped");
+         sc.stop();
+         sc = null;
+
+         log.info("server stopped");
+      }
+      finally
+      {
+         clearEnvironmentServerIndex();
+      }
    }
 
    public synchronized void destroy() throws Exception
@@ -257,26 +266,26 @@
       try
       {
          log.info(" Server peer ID ........... " + serverPeerID + " clustered: " + clustered);
-         
+
          log.debug("creating ServerPeer instance");
-   
+
          // we are using the "default" service deployment descriptors available in
          // src/etc/server/default/deploy. This will allow to test the default parameters we ship.
-   
+
          String mainConfigFile = "server/default/deploy/messaging-service.xml";
          URL mainConfigFileURL = getClass().getClassLoader().getResource(mainConfigFile);
          if (mainConfigFileURL == null)
          {
             throw new Exception("Cannot find " + mainConfigFile + " in the classpath");
          }
-   
+
          String databaseType = sc.getDatabaseType();
          String persistenceConfigFile;
 
          if (clustered && !databaseType.equals("hsqldb"))
          {
             //HSQL can't be used for clustered server peer - since it's not a shared database
-            
+
             persistenceConfigFile =
                "server/default/deploy/clustered-" + databaseType + "-persistence-service.xml";
          }
@@ -293,37 +302,37 @@
          {
             throw new Exception("Cannot find " + persistenceConfigFile + " in the classpath");
          }
-   
+
          String connFactoryConfigFile = "server/default/deploy/connection-factories-service.xml";
          URL connFactoryConfigFileURL = getClass().getClassLoader().getResource(connFactoryConfigFile);
          if (connFactoryConfigFileURL == null)
          {
             throw new Exception("Cannot find " + connFactoryConfigFile + " in the classpath");
          }
-   
+
          ServiceDeploymentDescriptor mdd = new ServiceDeploymentDescriptor(mainConfigFileURL);
          ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
          ServiceDeploymentDescriptor cfdd = new ServiceDeploymentDescriptor(connFactoryConfigFileURL);
-   
+
          MBeanConfigurationElement persistenceManagerConfig =
             (MBeanConfigurationElement)pdd.query("service", "PersistenceManager").iterator().next();
          persistenceManagerObjectName = sc.registerAndConfigureService(persistenceManagerConfig);
          sc.invoke(persistenceManagerObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(persistenceManagerObjectName, "start", new Object[0], new String[0]);    
-              
+         sc.invoke(persistenceManagerObjectName, "start", new Object[0], new String[0]);
+
          MBeanConfigurationElement jmsUserManagerConfig =
             (MBeanConfigurationElement)pdd.query("service", "JMSUserManager").iterator().next();
          jmsUserManagerObjectName = sc.registerAndConfigureService(jmsUserManagerConfig);
          sc.invoke(jmsUserManagerObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(jmsUserManagerObjectName, "start", new Object[0], new String[0]);  
-         
+         sc.invoke(jmsUserManagerObjectName, "start", new Object[0], new String[0]);
+
          // register server peer as a service, dependencies are injected automatically
          MBeanConfigurationElement serverPeerConfig =
             (MBeanConfigurationElement)mdd.query("service", "ServerPeer").iterator().next();
-   
+
          // overwrite the file configuration, if needed
          serverPeerConfig.setConstructorArgumentValue(0, 0, String.valueOf(serverPeerID));
-         
+
          if (defaultQueueJNDIContext != null)
          {
             serverPeerConfig.setConstructorArgumentValue(0, 1, defaultQueueJNDIContext);
@@ -332,32 +341,32 @@
          {
             serverPeerConfig.setConstructorArgumentValue(0, 2, defaultTopicJNDIContext);
          }
-   
+
          serverPeerObjectName = sc.registerAndConfigureService(serverPeerConfig);
-   
+
          // overwrite the config file security domain
          sc.setAttribute(serverPeerObjectName, "SecurityDomain",
                          MockJBossSecurityManager.TEST_SECURITY_DOMAIN);
-   
+
          log.debug("starting JMS server");
-   
+
          sc.invoke(serverPeerObjectName, "create", new Object[0], new String[0]);
          sc.invoke(serverPeerObjectName, "start", new Object[0], new String[0]);
-          
+
          MBeanConfigurationElement queuePostOfficeConfig =
             (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
          queuePostOfficeObjectName = sc.registerAndConfigureService(queuePostOfficeConfig);
          sc.invoke(queuePostOfficeObjectName, "create", new Object[0], new String[0]);
          sc.invoke(queuePostOfficeObjectName, "start", new Object[0], new String[0]);
-         
+
          MBeanConfigurationElement topicPostOfficeConfig =
             (MBeanConfigurationElement)pdd.query("service", "TopicPostOffice").iterator().next();
          topicPostOfficeObjectName = sc.registerAndConfigureService(topicPostOfficeConfig);
          sc.invoke(topicPostOfficeObjectName, "create", new Object[0], new String[0]);
          sc.invoke(topicPostOfficeObjectName, "start", new Object[0], new String[0]);
-         
+
          log.debug("deploying connection factories");
-   
+
          List connFactoryElements = cfdd.query("service", "ConnectionFactory");
          connFactoryObjectNames.clear();
          for(Iterator i = connFactoryElements.iterator(); i.hasNext(); )
@@ -369,7 +378,7 @@
             sc.invoke(on, "start", new Object[0], new String[0]);
             connFactoryObjectNames.add(on);
          }
-   
+
          // bind the default JMS provider
          sc.bindDefaultJMSProvider();
          // bind the JCA ConnectionFactory
@@ -386,7 +395,7 @@
    {
       stopServerPeer(true);
    }
-   
+
    public void stopServerPeer(boolean sendNotification) throws Exception
    {
       try
@@ -398,13 +407,13 @@
             log.warn("ServerPeer already stopped");
             return;
          }
-   
+
          // unbind the JCA ConnectionFactory; nothing happens if no connection factory is bound
          sc.unbindJCAJMSConnectionFactory();
          sc.unbindDefaultJMSProvider();
-   
+
          log.debug("stopping connection factories");
-   
+
          for(Iterator i = connFactoryObjectNames.iterator(); i.hasNext(); )
          {
             try
@@ -423,11 +432,11 @@
             }
          }
          connFactoryObjectNames.clear();
-   
+
          log.debug("stopping all destinations");
-   
+
          Set destinations = (Set)sc.getAttribute(serverPeerObjectName, "Destinations");
-   
+
          for(Iterator i = destinations.iterator(); i.hasNext(); )
          {
             String name;
@@ -442,17 +451,17 @@
                isQueue = false;
                name = ((Topic)d).getTopicName();
             }
-   
+
             undeployDestination(isQueue, name);
          }
-   
+
          log.debug("stopping JMS server");
-   
+
          try
          {
             //Huh?? Where's the method on the server peer???
             //sc.invoke(serverPeerObjectName, "stop", new Object[]{new Boolean(sendNotification)}, new String[]{"boolean"});
-            
+
             sc.invoke(serverPeerObjectName, "stop", new Object[0], new String[0]);
             sc.invoke(serverPeerObjectName, "destroy", new Object[0], new String[0]);
             sc.unregisterService(serverPeerObjectName);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-08 17:01:38 UTC (rev 1730)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-08 19:15:03 UTC (rev 1731)
@@ -24,7 +24,6 @@
 import java.rmi.registry.LocateRegistry;
 import java.rmi.registry.Registry;
 import java.rmi.server.UnicastRemoteObject;
-import java.rmi.RemoteException;
 import java.util.Set;
 import javax.management.ObjectName;
 import javax.transaction.UserTransaction;



From genman at noderunner.net  Fri Dec  8 14:19:05 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:19:05 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction    ...
Message-ID: <E1GslFR-0001SQ-7l@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:19:05

  Modified:    src/org/jboss/cache/eviction    ExpirationPolicy.java
                        ExpirationConfiguration.java
                        ExpirationAlgorithm.java
  Log:
  JBCACHE-880 - clean up expiration policy (still a work in progress)
  
  Revision  Changes    Path
  1.2       +35 -26    JBossCache/src/org/jboss/cache/eviction/ExpirationPolicy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationPolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/ExpirationPolicy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ExpirationPolicy.java	27 Nov 2006 04:51:24 -0000	1.1
  +++ ExpirationPolicy.java	8 Dec 2006 19:19:05 -0000	1.2
  @@ -1,5 +1,7 @@
   package org.jboss.cache.eviction;
   
  +import org.jboss.cache.Fqn;
  +
   /**
    * Returns the {@link ExpirationAlgorithm} as the policy's algorithm.
    * @author rosse
  @@ -23,4 +25,11 @@
         return ExpirationConfiguration.class;
      }
   
  +   /**
  +    * Returns true if it's a visit node event. 
  +    */
  +   @Override
  +   public boolean canIgnoreEvent(Fqn fqn, NodeEventType eventType) {
  +      return (eventType == NodeEventType.VISIT_NODE_EVENT);
  +   }
   }
  
  
  
  1.2       +82 -69    JBossCache/src/org/jboss/cache/eviction/ExpirationConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/ExpirationConfiguration.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ExpirationConfiguration.java	27 Nov 2006 04:51:24 -0000	1.1
  +++ ExpirationConfiguration.java	8 Dec 2006 19:19:05 -0000	1.2
  @@ -22,6 +22,9 @@
      @Dynamic
      private boolean warnNoExpirationKey = true;
   
  +   @Dynamic
  +   private int timeToLiveSeconds = 0;
  +
      public ExpirationConfiguration()
      {
         setEvictionPolicyClassName();
  @@ -66,4 +69,14 @@
         this.warnNoExpirationKey = warnNoExpirationKey;
      }
   
  +   public int getTimeToLiveSeconds()
  +   {
  +      return timeToLiveSeconds;
  +   }
  +
  +   public void setTimeToLiveSeconds(int timeToLiveSeconds)
  +   {
  +      this.timeToLiveSeconds = timeToLiveSeconds;
  +   }   
  +
   }
  
  
  
  1.3       +68 -8     JBossCache/src/org/jboss/cache/eviction/ExpirationAlgorithm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationAlgorithm.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/ExpirationAlgorithm.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ExpirationAlgorithm.java	27 Nov 2006 19:59:11 -0000	1.2
  +++ ExpirationAlgorithm.java	8 Dec 2006 19:19:05 -0000	1.3
  @@ -11,12 +11,53 @@
   import org.jboss.cache.optimistic.FqnComparator;
   
   /**
  - * Eviction algorithm that uses a key in the Node data that indicates the time the node should
  - * be evicted.
  - * This algorithm also considers {@link ExpirationConfiguration#getMaxNodes()}, and 
  - * will remove the most soon to expire entires first.
  + * Eviction algorithm that uses a key in the Node data that indicates the time
  + * the node should be evicted.  The key must be a java.lang.Long object, with
  + * the time to expire as milliseconds past midnight January 1st, 1970 UTC (the
  + * same relative time as provided by {@link
  + * java.lang.System#currentTimeMillis()}).
    * <p/>
  - * Note that if the expiration key is absent, the node will not be evicted.
  + * Alternatively to setting the Node expiration key value, calling {@link
  + * Region#markNodeCurrentlyInUse} will cause the node to expire once the
  + * timeout is reached. Note that, because the expiration value is not stored on
  + * the node, the expiration time cannot be persisted or replicated.  Calling
  + * {@link Region#unmarkNodeCurrentlyInUse} unsets the expiration value.
  + * <p/>
  + * This algorithm also obeys the configuration key {@link
  + * ExpirationConfiguration#getMaxNodes()}, and will evict the soonest to
  + * expire entires first to reduce the region size.  If there are not enough
  + * nodes with expiration keys set, a warning is logged.
  + * <p/>
  + * If a node in the eviction region does not have an expiration value, then
  + * {@link ExpirationConfiguration#getTimeToLiveSeconds} (if set) will be used.
  + * The expiration is updated when a node is added or updated.
  + * <p/>
  + * If there is no time-to-live set, and a node in the eviction region does not
  + * have an expiration value, then that node will never be evicted.  As
  + * forgetting to indicate an expiration value is likely a mistake, a warning
  + * message is logged by this class. This warning, however, can be disabled
  + * through {@link ExpirationConfiguration#setWarnNoExpirationKey(boolean)}/
  + * <p/>
  + * A node's expiration time can be changed by setting a new value in the node.
  + * <p/>
  + * Example usage:
  + <pre>
  + Cache cache;
  + Fqn fqn1 = Fqn.fromString("/node/1");
  + Long future = Long.valueOf(System.currentTimeMillis() + 2000);
  + cache.put(fqn1, ExpirationConfiguration.DEFAULT_EXPIRATION_KEY, future);
  + cache.put(fqn1, "foo");
  + assertTrue(cache.get(fqn1) != null);
  + 
  + Thread.sleep(5000); // 5 seconds
  + assertTrue(cache.get(fqn1) == null);
  +
  + // Alternatively, this expires a node in one second
  + cache.put(fqn1, "foo");
  + cache.getRegion(fqn1, false).markNodeCurrentlyInUse(fqn1, 1000);
  + Thread.sleep(2000); // 5 seconds
  + assertTrue(cache.get(fqn1) == null);
  + </pre>
    */
   public class ExpirationAlgorithm extends BaseEvictionAlgorithm
   {
  @@ -53,8 +94,15 @@
               log.warn("No expiration key '" + config.getExpirationKeyName() + "' for Node: " + fqn);
            else if (log.isDebugEnabled())
               log.debug("No expiration key for Node: " + fqn);
  -         return;
         }
  +      else
  +      {
  +         setExpiration(fqn, l);
  +      }
  +   }
  +   
  +   private void setExpiration(Fqn fqn, Long l)
  +   {
         boolean found = set.remove(new ExpirationEntry(fqn));
         if (found && log.isTraceEnabled())
            log.trace("removed old expiration for " + fqn);
  @@ -88,12 +136,14 @@
                  break;
               case REMOVE_ELEMENT_EVENT :
               case REMOVE_NODE_EVENT :
  +            case UNMARK_USE_EVENT :
                  removeEvictionEntry(node);
                  break;
               case VISIT_NODE_EVENT :
  +               // unused
  +               break;
               case MARK_IN_USE_EVENT :
  -            case UNMARK_USE_EVENT :
  -               // TODO
  +               markInUse(node);
                  break;
               default :
                  throw new RuntimeException("Illegal Eviction Event type " + node.getEventType());
  @@ -106,6 +156,12 @@
         }
      }
   
  +   private void markInUse(EvictedEventNode node)
  +   {
  +      long expiration = node.getInUseTimeout() + System.currentTimeMillis();
  +      setExpiration(node.getFqn(), new Long(expiration));
  +   }
  +
      @Override
      protected void prune() throws EvictionException
      {
  @@ -126,6 +182,10 @@
               break;
            }
         }
  +	  if (max != 0 && max > set.size())
  +		  log.warn("Unable to remove nodes to reduce region size below " + 
  +				  config.getMaxNodes() + ".  " +
  +				  "Set expiration for nodes in this region");
      }
   
      private void removeEvictionEntry(EvictedEventNode node)
  
  
  


From genman at noderunner.net  Fri Dec  8 14:19:05 2006
From: genman at noderunner.net (Elias Ross)
Date: Fri, 08 Dec 2006 14:19:05 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1GslFR-0001SX-Bb@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/08 14:19:05

  Modified:    tests/functional/org/jboss/cache/eviction 
                        ExpirationPolicyTest.java
  Log:
  JBCACHE-880 - clean up expiration policy (still a work in progress)
  
  Revision  Changes    Path
  1.3       +2 -19     JBossCache/tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ExpirationPolicyTest.java	27 Nov 2006 19:59:10 -0000	1.2
  +++ ExpirationPolicyTest.java	8 Dec 2006 19:19:05 -0000	1.3
  @@ -14,43 +14,26 @@
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.EvictionConfig;
  -import org.jboss.cache.factories.XmlConfigurationParser;
  -import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.misc.TestingUtil;
  -import org.jboss.util.property.Configurable;
   
   /**
    * Unit tests for {@link ExpirationPolicy}.
    *
    * @author Elias Ross
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public class ExpirationPolicyTest extends TestCase
   {
      private static final Log log = LogFactory.getLog(ExpirationPolicyTest.class);
   
  -   TreeCache cache;
  -
  -   int wakeupIntervalMillis = 0;
  -
  -   final String ROOT_STR = "/test";
  -
  -   Throwable t1_ex, t2_ex;
  -
  -   final long DURATION = 10000;
  -
  -   boolean isTrue;
  +   private TreeCache cache;
   
      Fqn fqn1 = Fqn.fromString("/node/1");
  -
      Fqn fqn2 = Fqn.fromString("/node/2");
  -
      Fqn fqn3 = Fqn.fromString("/node/3");
  -
      Fqn fqn4 = Fqn.fromString("/node/4");
   
      Long future;
  -
      Long past;
   
      public void setUp() throws Exception
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 15:23:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 15:23:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r58934 - in branches/Branch_4_2: build
	varia/src/resources/services
	varia/src/resources/services/entityresolver
Message-ID: <E1GsmG6-0002Y8-C2@committer01.frg.pub.inap.atl.jboss.com>

Author: amit.bhayani at jboss.com
Date: 2006-12-08 15:23:43 -0500 (Fri, 08 Dec 2006)
New Revision: 58934

Added:
   branches/Branch_4_2/varia/src/resources/services/entityresolver/
   branches/Branch_4_2/varia/src/resources/services/entityresolver/xmlresolver-service.xml
Modified:
   branches/Branch_4_2/build/build-distr.xml
   branches/Branch_4_2/build/build.xml
Log:
Added JBossEntityResolverMgr Mbean example. To fix JBAS-3922

Modified: branches/Branch_4_2/build/build-distr.xml
===================================================================
--- branches/Branch_4_2/build/build-distr.xml	2006-12-08 18:25:48 UTC (rev 58933)
+++ branches/Branch_4_2/build/build-distr.xml	2006-12-08 20:23:43 UTC (rev 58934)
@@ -881,10 +881,14 @@
          <include name="bsf.jar"/>
       </fileset>
     </copy>
-
+      
      <!-- copy the xmlentitymgr.jar to lib -->
      <copy file="${_module.output}/lib/xmlentitymgr.jar"
        todir="${install.server}/all/lib"/>
+       
+    <mkdir dir="${install.examples.entity-resolver-manager}"/>
+    <copy file="${project.root}/varia/src/resources/services/entityresolver/xmlresolver-service.xml"
+      todir="${install.examples.entity-resolver-manager}"/>       
 
   </target>
 

Modified: branches/Branch_4_2/build/build.xml
===================================================================
--- branches/Branch_4_2/build/build.xml	2006-12-08 18:25:48 UTC (rev 58933)
+++ branches/Branch_4_2/build/build.xml	2006-12-08 20:23:43 UTC (rev 58934)
@@ -231,6 +231,7 @@
     <property name="install.examples.jbossweb" value="${install.examples}/jbossweb"/>
     <property name="install.examples.netboot" value="${install.examples}/netboot"/>
     <property name="install.examples.binding-manager" value="${install.examples}/binding-manager"/>
+    <property name="install.examples.entity-resolver-manager" value="${install.examples}/entity-resolver-manager"/>
     <property name="install.examples.varia" value="${install.examples}/varia"/>
     <property name="install.dtd" value="${install.docs}/dtd"/>
     <property name="install.schema" value="${install.docs}/schema"/>

Added: branches/Branch_4_2/varia/src/resources/services/entityresolver/xmlresolver-service.xml
===================================================================
--- branches/Branch_4_2/varia/src/resources/services/entityresolver/xmlresolver-service.xml	2006-12-08 18:25:48 UTC (rev 58933)
+++ branches/Branch_4_2/varia/src/resources/services/entityresolver/xmlresolver-service.xml	2006-12-08 20:23:43 UTC (rev 58934)
@@ -0,0 +1,12 @@
+<!-- The JBossEntityResolver mbean service which allows customization of the
+xml parser entity resolver publicID/systemID to dtd/schema file mapping.
+See, http://wiki.jboss.org/wiki/Wiki.jsp?page=XMLEntitySchemaResolution
+-->
+<server>
+   <mbean code="org.jboss.services.xml.JBossEntityResolverMgr"
+      name="jboss.xml:service=JBossEntityResolverMgr">
+      <attribute name="WarnOnNonFileURLs">true</attribute>
+      <attribute name="EntityMap">
+      </attribute>
+   </mbean>
+</server>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 16:09:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 16:09:23 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58935 - trunk/testsuite
Message-ID: <E1GsmyB-0003JO-5N@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-08 16:09:21 -0500 (Fri, 08 Dec 2006)
New Revision: 58935

Modified:
   trunk/testsuite/build.xml
Log:
fix broken build, include jboss.jbossws.classpath

Modified: trunk/testsuite/build.xml
===================================================================
--- trunk/testsuite/build.xml	2006-12-08 20:23:43 UTC (rev 58934)
+++ trunk/testsuite/build.xml	2006-12-08 21:09:21 UTC (rev 58935)
@@ -114,6 +114,7 @@
       <path refid="codehaus.stax.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
       <!-- needed for messaging JMS provider tests -->
       <path refid="jboss.messaging.classpath"/>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 16:56:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 16:56:39 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1732 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/server/connectionfactory messaging/core/plugin/contract
	messaging/core/plugin/postoffice/cluster
Message-ID: <E1Gsnhv-0003wj-Gp@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-08 16:56:34 -0500 (Fri, 08 Dec 2006)
New Revision: 1732

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
Log:
HA tweaks



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-08 19:15:03 UTC (rev 1731)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-08 21:56:34 UTC (rev 1732)
@@ -273,7 +273,7 @@
    
    // ReplicationListener interface ----------------------------------
    
-   public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap)
+   public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added)
    {
       log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap);
       try
@@ -285,8 +285,10 @@
          
          String sKey = (String)key;
          
-         if (key instanceof String && sKey.startsWith(CF_PREFIX))
+         if (added && key instanceof String && sKey.startsWith(CF_PREFIX))
          {
+            //We only need to rebind if the cf is being added
+            
             String uniqueName = sKey.substring(CF_PREFIX.length());
             
             ClusteredClientConnectionFactoryDelegate clusteredDelegate = createClusteredDelegate(updatedReplicantMap);
@@ -407,7 +409,13 @@
             
             if (failoverIndex == -1)
             {
-               throw new IllegalStateException("Failover node " + failoverNode + " is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
+               //throw new IllegalStateException("Failover node " + failoverNode + " is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
+               
+               //It is possible that the failover node is not found  - this might happen
+               //if this is executed when a cf is undeployed but the failover node still contains
+               //the old node.
+               
+               //In this case the node leave event will shortly
             }
             
             failoverIndexes[i] = failoverIndex;
@@ -419,7 +427,7 @@
 
       return clusteredDelegate;
    }
-
+   
    private void rebindConnectionFactory(Context ic,
                                         JNDIBindings jndiBindings,
                                         ClientConnectionFactoryDelegate delegate)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java	2006-12-08 19:15:03 UTC (rev 1731)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java	2006-12-08 21:56:34 UTC (rev 1732)
@@ -39,5 +39,5 @@
     * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
     *        the given key.
     */
-   void onReplicationChange(Serializable key, Map updatedReplicantMap);
+   void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 19:15:03 UTC (rev 1731)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 21:56:34 UTC (rev 1732)
@@ -717,7 +717,7 @@
          
          m.put(new Integer(originatorNodeID), replicant);
          
-         notifyListeners(key, m);
+         notifyListeners(key, m, true);
       }
    }
 
@@ -748,7 +748,7 @@
          {
             replicatedData.remove(key);
          } 
-         notifyListeners(key, m);
+         notifyListeners(key, m, false);
       
          return true; 
       }
@@ -1877,7 +1877,7 @@
             }     
             
             // Need to trigger listeners
-            notifyListeners(key, replicants);
+            notifyListeners(key, replicants, false);
          }
       }
    }
@@ -1886,7 +1886,7 @@
     * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
     *        the given key.
     */
-   private void notifyListeners(Serializable key, Map updatedReplicantMap)
+   private void notifyListeners(Serializable key, Map updatedReplicantMap, boolean added)
    { 
       synchronized (replicationListeners)
       {         
@@ -1894,7 +1894,7 @@
          {
             ReplicationListener listener = (ReplicationListener)i.next();
             
-            listener.onReplicationChange(key, updatedReplicantMap);
+            listener.onReplicationChange(key, updatedReplicantMap, added);
          }
       }
    } 
@@ -2456,7 +2456,7 @@
    private class NodeAddressMapListener implements ReplicationListener
    {
 
-      public void onReplicationChange(Serializable key, Map updatedReplicantMap)
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added)
       {
          if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
          {



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 16:57:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 16:57:58 -0500
Subject: [jboss-cvs] JBossAS SVN: r58936 -
	branches/JBoss_4_0_3_SP1_JBAS-3808/tomcat/src/main/org/jboss/web/tomcat/tc5/session
Message-ID: <E1GsnjC-0003xL-LL@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 16:57:57 -0500 (Fri, 08 Dec 2006)
New Revision: 58936

Modified:
   branches/JBoss_4_0_3_SP1_JBAS-3808/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossCacheManager.java
Log:
Don't clear sessions before issuing a BEGIN_STOP_EVENT

Modified: branches/JBoss_4_0_3_SP1_JBAS-3808/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossCacheManager.java
===================================================================
--- branches/JBoss_4_0_3_SP1_JBAS-3808/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossCacheManager.java	2006-12-08 21:09:21 UTC (rev 58935)
+++ branches/JBoss_4_0_3_SP1_JBAS-3808/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JBossCacheManager.java	2006-12-08 21:57:57 UTC (rev 58936)
@@ -253,14 +253,35 @@
 
    public void stop() throws LifecycleException
    {
+      if (!started_)
+      {
+         throw new IllegalStateException("Manager not started");
+      }
+      
+      log_.debug("Stopping");
+      
+      resetStats();
+      
+      // Notify our interested LifecycleListeners
+      lifecycle_.fireLifecycleEvent(BEFORE_STOP_EVENT, this);
+      
       clearSessions();
-      if (embedded_)
+      
+      proxy_.stop();
+      tm = null;
+      
+      started_ = false;
+      
+      // Notify our interested LifecycleListeners
+      lifecycle_.fireLifecycleEvent(AFTER_STOP_EVENT, this);
+      
+      try
       {
-         stopEmbedded();
+         unregisterMBeans();
       }
-      else
+      catch (Exception e)
       {
-         stopUnembedded();
+         log_.error("Could not unregister ManagerMBean from MBeanServer", e);
       }
    }
 
@@ -808,16 +829,6 @@
          throw new LifecycleException(e);
       }
    }
-
-   /**
-    * Stop this Manager when running embedded in JBoss AS.
-    */
-   private void stopEmbedded() throws LifecycleException
-   {
-      super.stop();
-      proxy_.stop();
-      tm = null;
-   }
    
    // -----------------------------------------------  Lifecyle When Unembedded
 
@@ -937,39 +948,6 @@
    }
 
    /**
-    * Stop this Manager when running in standalone Tomcat.
-    */
-   private void stopUnembedded()
-   {
-      resetStats();
-      
-      if (!started_)
-      {
-         throw new IllegalStateException("Manager not started");
-      }
-      
-      // Notify our interested LifecycleListeners
-      lifecycle_.fireLifecycleEvent(BEFORE_STOP_EVENT, this);
-      
-      proxy_.stop();
-      tm = null;
-      
-      started_ = false;
-      
-      // Notify our interested LifecycleListeners
-      lifecycle_.fireLifecycleEvent(AFTER_STOP_EVENT, this);
-      
-      try
-      {
-         unregisterMBeans();
-      }
-      catch (Exception e)
-      {
-         log_.error("Could not unregister ManagerMBean from MBeanServer", e);
-      }
-   }
-
-   /**
     * Register this Manager with JMX.
     */
    private void registerMBeans() 
@@ -1012,13 +990,14 @@
    /**
     * Unregister this Manager from the JMX server.
     */
-   private void unregisterMBeans()
+   private void unregisterMBeans() throws Exception
    {
-      if (mserver_ != null)
+      MBeanServer server = getMBeanServer();
+      if (server != null)
       {
          try
          {
-            mserver_.unregisterMBean(objectName_);
+            server.unregisterMBean(objectName_);
          }
          catch (Exception e)
          {



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 17:00:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 17:00:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r58937 - in
	branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite: imports
	src/main/org/jboss/test/web/test src/resources/web/sso
Message-ID: <E1Gsnlj-0003zm-KJ@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 17:00:33 -0500 (Fri, 08 Dec 2006)
New Revision: 58937

Modified:
   branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/imports/test-jars.xml
   branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
   branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/application.xml
Log:
Test undeploy of both distributed and non-distributed webapps

Modified: branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/imports/test-jars.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/imports/test-jars.xml	2006-12-08 21:57:57 UTC (rev 58936)
+++ branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/imports/test-jars.xml	2006-12-08 22:00:33 UTC (rev 58937)
@@ -5038,6 +5038,21 @@
         <include name="**/*.jsp"/>
       </fileset>
     </war>
+    <war destfile="${build.lib}/sso-form-auth-clustered.war"
+      webxml="${build.resources}/web/sso/war/web-form-auth-clustered.xml">
+      <webinf dir="${build.resources}/web/sso/war">
+        <include name="jboss-web.xml"/>
+      </webinf>
+      <classes dir="${build.classes}">
+        <include name="org/jboss/test/web/servlets/EJBServlet.class"/>
+        <include name="org/jboss/test/web/servlets/LogoutServlet.class"/>
+        <include name="org/jboss/test/web/util/Util*"/>
+      </classes>
+      <fileset dir="${build.resources}/web/sso/war">
+        <include name="**/*.html"/>
+        <include name="**/*.jsp"/>
+      </fileset>
+    </war>
     <war destfile="${build.lib}/sso-expire.war"
       webxml="${build.resources}/web/sso/war/web-sso-expire.xml">
       <webinf dir="${build.resources}/web/sso/war">
@@ -5064,6 +5079,10 @@
         fullpath="sso-form-auth1.war"/>
       <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
         fullpath="sso-form-auth2.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth-clustered.war"
+          fullpath="sso-form-auth4.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth-clustered.war"
+          fullpath="sso-form-auth5.war"/>
       <zipfileset dir="${build.lib}" includes="sso-expire.war"/>
       <zipfileset dir="${build.lib}" includes="jbosstest-web-ejbs.jar"/>
     </zip>

Modified: branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
===================================================================
--- branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 21:57:57 UTC (rev 58936)
+++ branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 22:00:33 UTC (rev 58937)
@@ -63,10 +63,9 @@
       TestSuite suite = new TestSuite();
       suite.addTest(new ClusteredSingleSignOnUnitTestCase("testSessionExpiration"));
       suite.addTest(new ClusteredSingleSignOnUnitTestCase("testFormAuthSingleSignOn"));
-      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testWebappUndeploy"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployNonClusteredWebapp"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployClusteredWebapp"));
       
-//      return JBossClusteredTestCase.getDeploySetup(suite, "web-sso-clustered.ear");
-      
       return JBossClusteredTestCase.getDeploySetup(suite, "web-sso.ear");
    }
 
@@ -100,6 +99,20 @@
       log.debug("deployed1 = " + deployed1);
    }
    
+   public void testUndeployNonClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployNonClusteredWebapp");
+      
+      webappUndeployTest("war1", "war2");
+   }
+   
+   public void testUndeployClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployClusteredWebapp");
+      
+      webappUndeployTest("war4", "war5");
+   }
+   
    /**
     * Tests that undeploying a webapp on one server doesn't kill an sso
     * that also has a session from another webapp associated with it.
@@ -110,7 +123,7 @@
     *
     * @throws Exception
     */
-   public void testWebappUndeploy() throws Exception
+   private void webappUndeployTest(String firstWar, String secondWar) throws Exception
    {
       log.info("+++ testWebappUndeploy");
       
@@ -119,9 +132,9 @@
       String serverA = httpURLs[0];
       String serverB = httpURLs[1];
       
-      String warA1 = serverA + "/war1/";
-      String warB1 = serverB + "/war1/";
-      String warB2 = serverB + "/war2/";
+      String warA1 = serverA + "/" + firstWar +"/";
+      String warB1 = serverB + "/" + firstWar +"/";
+      String warB2 = serverB + "/" + secondWar +"/";
       
       // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();

Modified: branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/application.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/application.xml	2006-12-08 21:57:57 UTC (rev 58936)
+++ branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/application.xml	2006-12-08 22:00:33 UTC (rev 58937)
@@ -25,6 +25,18 @@
       </web>
    </module>
    <module>
+      <web>
+         <web-uri>sso-form-auth4.war</web-uri>
+         <context-root>/war4</context-root>
+      </web>
+   </module>
+   <module>
+      <web>
+         <web-uri>sso-form-auth5.war</web-uri>
+         <context-root>/war5</context-root>
+      </web>
+   </module>
+   <module>
       <ejb>jbosstest-web-ejbs.jar</ejb>
    </module>
 </application>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 17:01:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 17:01:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r58938 -
	branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/war
Message-ID: <E1GsnmS-00040u-7J@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 17:01:19 -0500 (Fri, 08 Dec 2006)
New Revision: 58938

Added:
   branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/war/web-form-auth-clustered.xml
Log:
Test undeploy of both distributed and non-distributed webapps

Added: branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/war/web-form-auth-clustered.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/war/web-form-auth-clustered.xml	2006-12-08 22:00:33 UTC (rev 58937)
+++ branches/JBoss_4_0_3_SP1_JBAS-3808/testsuite/src/resources/web/sso/war/web-form-auth-clustered.xml	2006-12-08 22:01:19 UTC (rev 58938)
@@ -0,0 +1,74 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE web-app PUBLIC
+   "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN"
+   "http://java.sun.com/dtd/web-app_2_3.dtd">
+
+<web-app>
+   <description>WebApp Integration Tests</description>
+
+   <distributable/>
+   
+   <servlet>
+      <servlet-name>LogoutServlet</servlet-name>
+      <servlet-class>org.jboss.test.web.servlets.LogoutServlet</servlet-class>
+   </servlet>
+   
+   <servlet>
+      <servlet-name>EJBServlet</servlet-name>
+      <servlet-class>org.jboss.test.web.servlets.EJBServlet</servlet-class>
+   </servlet>
+
+   <servlet-mapping>
+      <servlet-name>LogoutServlet</servlet-name>
+      <url-pattern>/Logout</url-pattern>
+   </servlet-mapping>
+
+   <servlet-mapping>
+      <servlet-name>EJBServlet</servlet-name>
+      <url-pattern>/EJBServlet</url-pattern>
+   </servlet-mapping>
+
+   <security-constraint>
+      <web-resource-collection>
+         <web-resource-name>Restricted</web-resource-name>
+         <description>Single SignOn Tests</description>
+         <url-pattern>/*</url-pattern>
+      </web-resource-collection>
+      <auth-constraint>
+         <description>Only authenticated users can access secure content</description>
+         <role-name>AuthorizedUser</role-name>
+      </auth-constraint>
+   </security-constraint>
+
+   <session-config>
+      <session-timeout>1</session-timeout>
+   </session-config>
+   
+   <ejb-ref>
+       <ejb-ref-name>ejb/OptimizedEJB</ejb-ref-name>
+       <ejb-ref-type>Session</ejb-ref-type>
+       <home>org.jboss.test.web.interfaces.StatelessSessionHome</home>
+       <remote>org.jboss.test.web.interfaces.StatelessSession</remote>
+       <ejb-link>SecuredEJB</ejb-link>
+   </ejb-ref>
+   <ejb-local-ref>
+      <ejb-ref-name>ejb/local/OptimizedEJB</ejb-ref-name>
+      <ejb-ref-type>Session</ejb-ref-type>
+      <local-home>org.jboss.test.web.interfaces.StatelessSessionLocalHome</local-home>
+      <local>org.jboss.test.web.interfaces.StatelessSessionLocal</local>
+      <ejb-link>jbosstest-web-ejbs.jar#SecuredEJB</ejb-link>
+   </ejb-local-ref>
+
+   <login-config>
+      <auth-method>FORM</auth-method>
+      <form-login-config>
+         <form-login-page>/login.html</form-login-page>
+         <form-error-page>/error.html</form-error-page>
+      </form-login-config>
+   </login-config>
+
+   <security-role>
+      <role-name>AuthorizedUser</role-name>
+   </security-role>
+</web-app>
+



From david.lloyd at jboss.com  Fri Dec  8 17:07:58 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 17:07:58 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jsf/1.2_03 - New directory ...
Message-ID: <E1Gsnss-0004KZ-7u@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 17:07:58

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/sun-jsf/1.2_03 added to the repository


From david.lloyd at jboss.com  Fri Dec  8 17:07:58 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 17:07:58 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jsf/1.2_03/lib - New directory
	...
Message-ID: <E1Gsnss-0004Kd-Ba@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 17:07:58

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/sun-jsf/1.2_03/lib added to the repository


From david.lloyd at jboss.com  Fri Dec  8 17:09:43 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 17:09:43 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jsf/1.2_03  ...
Message-ID: <E1GsnuZ-0004L2-Uh@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 17:09:43

  Added:       sun-jsf/1.2_03  component-info.xml
  Log:
  Add JSF RI 1.2_03
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 22:09:43;  author: dlloyd;  state: Exp;repository.jboss.com/sun-jsf/1.2_03/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="sun-jsf-component-info">
    
    <!-- ============================================================ -->
    <!-- JSF 1.2                                                      -->
    <!-- ============================================================ -->
    
    <component 
      id="sun-jsf" 
      version="1.2_03" 
      licenseType="cddl" 
      projectHome="https://javaserverfaces.dev.java.net/" 
      description="The JSF 1.2 implementation">
      
      <artifact id="jsf-api.jar"/>
      <artifact id="jsf-impl.jar"/>
      
      <export>
        <include input="jsf-api.jar"/>
        <include input="jsf-impl.jar"/>
      </export>
    </component>
    
  </project>
  
  
  


From david.lloyd at jboss.com  Fri Dec  8 17:09:44 2006
From: david.lloyd at jboss.com (David Lloyd)
Date: Fri, 08 Dec 2006 17:09:44 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jsf/1.2_03/lib   ...
Message-ID: <E1Gsnua-0004LA-2L@committer01.frg.pub.inap.atl.jboss.com>

  User: dlloyd  
  Date: 06/12/08 17:09:44

  Added:       sun-jsf/1.2_03/lib   jsf-api.jar jsf-impl.jar
  Log:
  Add JSF RI 1.2_03
  
  Revision  Changes    Path
  1.1      date: 2006/12/08 22:09:44;  author: dlloyd;  state: Exp;repository.jboss.com/sun-jsf/1.2_03/lib/jsf-api.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/08 22:09:44;  author: dlloyd;  state: Exp;repository.jboss.com/sun-jsf/1.2_03/lib/jsf-impl.jar
  
  	<<Binary file>>
  
  


From michael.yuan at jboss.com  Fri Dec  8 17:53:35 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 08 Dec 2006 17:53:35 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gsob1-0004zh-5z@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/08 17:53:35

  Modified:    seam-gen  build.xml
  Log:
  facelets module support in netbeans
  
  Revision  Changes    Path
  1.47      +4 -2      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -b -r1.46 -r1.47
  --- build.xml	7 Dec 2006 04:15:45 -0000	1.46
  +++ build.xml	8 Dec 2006 22:53:35 -0000	1.47
  @@ -106,7 +106,7 @@
           <echo message="Welcome to seam-gen :-)"/>
           <property name="workspace.home" value="C:/Projects"/>
           <input addproperty="workspace.home.new" 
  -                   message="Enter your Java project workspace [${workspace.home}]" 
  +                   message="Enter your Java project workspace (the directory that contains your Seam projects) [${workspace.home}]" 
                 defaultvalue="${workspace.home}"/>
       	<pathFixer property="workspace.home.new" />
           
  @@ -520,7 +520,9 @@
       		<equals arg1="${eclipse.wtp}" arg2="y"/>
       	</condition>
           <echo message="A new Seam project was created in the ${workspace.home} directory"/>
  -    	<echo message="Add the project from inside Eclipse (or type 'seam explode') and go to http://localhost:8080/${project.name}"/>
  +    	<echo message="Type 'seam explode' and go to http://localhost:8080/${project.name}"/>
  +    	<echo message="Eclipse Users: Add the project as a new Java project from inside Eclipse"/>
  +    	<echo message="NetBeans Users: Open the project in NetBeans"/>
       </target>
   
       <target name="update-project" depends="validate-project">
  
  
  


From michael.yuan at jboss.com  Fri Dec  8 17:53:35 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Fri, 08 Dec 2006 17:53:35 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/nbproject  ...
Message-ID: <E1Gsob1-0004zo-9V@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/08 17:53:35

  Modified:    seam-gen/nbproject  project.xml
  Log:
  facelets module support in netbeans
  
  Revision  Changes    Path
  1.7       +13 -0     jboss-seam/seam-gen/nbproject/project.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: project.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/nbproject/project.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- project.xml	6 Dec 2006 22:53:06 -0000	1.6
  +++ project.xml	8 Dec 2006 22:53:35 -0000	1.7
  @@ -12,6 +12,11 @@
                       <type>java</type>
                       <location>src</location>
                   </source-folder>
  +                <source-folder>
  +                    <label>view</label>
  +                    <type>doc_root</type>
  +                    <location>view</location>
  +                </source-folder>
               </folders>
               <ide-actions>
                   <action name="clean">
  @@ -70,5 +75,13 @@
                   <source-level>1.5</source-level>
               </compilation-unit>
           </java-data>
  +        <web-data xmlns="http://www.netbeans.org/ns/freeform-project-web/1">
  +            <web-module>
  +                <doc-root>view</doc-root>
  +                <classpath/>
  +                <context-path/>
  +                <j2ee-spec-level>1.5</j2ee-spec-level>
  +            </web-module>
  +        </web-data>
       </configuration>
   </project>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 18:13:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 18:13:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r58939 - in branches/Branch_4_0/testsuite:
	imports/sections src/main/org/jboss/test/web/test
	src/resources/web/sso
Message-ID: <E1Gsots-0005Ss-02@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 18:13:01 -0500 (Fri, 08 Dec 2006)
New Revision: 58939

Modified:
   branches/Branch_4_0/testsuite/imports/sections/web.xml
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
   branches/Branch_4_0/testsuite/src/resources/web/sso/application.xml
Log:
Test undeploy of both distributed and non-distributed webapps

Modified: branches/Branch_4_0/testsuite/imports/sections/web.xml
===================================================================
--- branches/Branch_4_0/testsuite/imports/sections/web.xml	2006-12-08 22:01:19 UTC (rev 58938)
+++ branches/Branch_4_0/testsuite/imports/sections/web.xml	2006-12-08 23:13:01 UTC (rev 58939)
@@ -358,6 +358,10 @@
          <zipfileset dir="${build.lib}" includes="sso-form-auth-clustered.war"
             fullpath="sso-form-auth2.war"/>
          <zipfileset dir="${build.lib}" includes="sso-expire.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
+           fullpath="sso-form-auth4.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
+           fullpath="sso-form-auth5.war"/>
          <zipfileset dir="${build.lib}" includes="jbosstest-web-ejbs.jar"/>
       </zip>
       

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 22:01:19 UTC (rev 58938)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 23:13:01 UTC (rev 58939)
@@ -63,7 +63,8 @@
       TestSuite suite = new TestSuite();
       suite.addTest(new ClusteredSingleSignOnUnitTestCase("testSessionExpiration"));
       suite.addTest(new ClusteredSingleSignOnUnitTestCase("testFormAuthSingleSignOn"));
-      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testWebappUndeploy"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployNonClusteredWebapp"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployClusteredWebapp"));
       
       return JBossClusteredTestCase.getDeploySetup(suite, "web-sso-clustered.ear");
    }
@@ -96,6 +97,20 @@
       log.debug("deployed1 = " + deployed1);
    }
    
+   public void testUndeployNonClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployNonClusteredWebapp");
+      
+      webappUndeployTest("war4", "war5");
+   }
+   
+   public void testUndeployClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployClusteredWebapp");
+      
+      webappUndeployTest("war1", "war2");
+   }
+   
    /**
     * Tests that undeploying a webapp on one server doesn't kill an sso
     * that also has a session from another webapp associated with it.
@@ -106,7 +121,7 @@
     *
     * @throws Exception
     */
-   public void testWebappUndeploy() throws Exception
+   private void webappUndeployTest(String firstWar, String secondWar) throws Exception
    {
       log.info("+++ testWebappUndeploy");
       
@@ -115,9 +130,9 @@
       String serverA = httpURLs[0];
       String serverB = httpURLs[1];
       
-      String warA1 = serverA + "/war1/";
-      String warB1 = serverB + "/war1/";
-      String warB2 = serverB + "/war2/";
+      String warA1 = serverA + "/" + firstWar +"/";
+      String warB1 = serverB + "/" + firstWar +"/";
+      String warB2 = serverB + "/" + secondWar +"/";
       
       // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();

Modified: branches/Branch_4_0/testsuite/src/resources/web/sso/application.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/web/sso/application.xml	2006-12-08 22:01:19 UTC (rev 58938)
+++ branches/Branch_4_0/testsuite/src/resources/web/sso/application.xml	2006-12-08 23:13:01 UTC (rev 58939)
@@ -25,6 +25,18 @@
       </web>
    </module>
    <module>
+      <web>
+         <web-uri>sso-form-auth4.war</web-uri>
+         <context-root>/war4</context-root>
+      </web>
+   </module>
+   <module>
+      <web>
+         <web-uri>sso-form-auth5.war</web-uri>
+         <context-root>/war5</context-root>
+      </web>
+   </module>
+   <module>
       <ejb>jbosstest-web-ejbs.jar</ejb>
    </module>
 </application>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 20:15:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 20:15:24 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1733 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
Message-ID: <E1GsqoG-0007LD-C9@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-08 20:15:18 -0500 (Fri, 08 Dec 2006)
New Revision: 1733

Added:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
Log:
Changing how the failoverMapping is being calculated

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -275,7 +275,7 @@
    
    public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added)
    {
-      log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap);
+      log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap + " added=");
       try
       {
          // The list of connection factories across the cluster has changed, so we need to update
@@ -285,7 +285,7 @@
          
          String sKey = (String)key;
          
-         if (added && key instanceof String && sKey.startsWith(CF_PREFIX))
+         if (key instanceof String && sKey.startsWith(CF_PREFIX))
          {
             //We only need to rebind if the cf is being added
             
@@ -293,21 +293,17 @@
             
             ClusteredClientConnectionFactoryDelegate clusteredDelegate = createClusteredDelegate(updatedReplicantMap);
             
-            //It could be null if the cf is being undeployed
-            if (clusteredDelegate != null)
-            {               
-               // Now rebind ...
-               
-               ServerConnectionFactoryEndpoint endpoint =
-                  (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
-               
-               if (endpoint == null)
-               {
-                  throw new IllegalStateException("Cannot find endpoint " + uniqueName );
-               }
-   
-               rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), clusteredDelegate);
+            // Now rebind ...
+
+            ServerConnectionFactoryEndpoint endpoint =
+               (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
+
+            if (endpoint == null)
+            {
+               throw new IllegalStateException("Cannot find endpoint " + uniqueName );
             }
+
+            rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), clusteredDelegate);
          }
       }
       catch (NamingException e)
@@ -345,6 +341,9 @@
       //TODO: make it trace after the code is stable
       log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
 
+      // Calculates the failoverMap based on the current list of localDelegates
+      Map failoverMap = replicator.getFailoverMapper().generateMapping(localDelegates.keySet());
+
       int s = localDelegates.size();
 
       int[] nodesIDs = new int[s];
@@ -360,13 +359,13 @@
       {
          Map.Entry entry = (Map.Entry)i.next();
 
-         int nodeID = ((Integer)entry.getKey()).intValue();
-         int failoverNodeID = replicator.getFailoverNodeID(nodeID);
+         Integer nodeID = (Integer)entry.getKey();
+         Integer failoverNodeID = (Integer)failoverMap.get(nodeID); 
 
          log.trace("setFailoverDelegates inside forIterator::nodeID=" + nodeID + " failoverNodeID=" + failoverNodeID);
 
-         nodesIDs[idx] = nodeID;
-         failoverNodeIDs[idx] = failoverNodeID;
+         nodesIDs[idx] = nodeID.intValue();
+         failoverNodeIDs[idx] = failoverNodeID.intValue();
          delegates[idx] = (ClientConnectionFactoryDelegate)entry.getValue();
 
          if (delegates[idx].getServerId() == this.serverPeer.getServerPeerID())
@@ -374,15 +373,13 @@
             // sanity check
             if (mainDelegate != null)
             {
-               throw new IllegalStateException("There are two server with serverID, verify your clustering configuration");
+               throw new IllegalStateException("There are two servers with serverID=" + this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
             }
             mainDelegate = delegates[idx];
          }
 
          idx++;
       }
-      // sanity check
-      
       // Generate the failover indexes. This could probably be optimised if need be.
       
       //MainDelegate would be null in the case the cf is being undeployed locally

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -142,8 +142,11 @@
    {
       try
       {
-         ServerPeer peer = (ServerPeer )serverPeer.getInstance();
-         return peer.getReplicator().getFailoverNodeID(node);
+         //ServerPeer peer = (ServerPeer )serverPeer.getInstance();
+         //return peer.getReplicator().getFailoverNodeID(node);
+
+         // not implemented yet
+         return node;
       }
       catch (Throwable t)
       {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -21,7 +21,8 @@
  */
 package org.jboss.messaging.core.plugin.contract;
 
-import java.util.List;
+import java.util.Collection;
+import java.util.Map;
 
 /**
  * A FailoverMapper
@@ -36,6 +37,12 @@
  */
 public interface FailoverMapper
 {
-   List generateMapping(List nodes);
+   /** This receives a List<Integer> of nodes and returns a Map<Integer,Integer> of nodes to be used on failover logic.
+    *
+    * An implementation of this method should aways sort received nodes first before calculating as the parameter list
+    * might be in a different order, and it should aways return the same result for the same set of nodes whatever is
+    * the order of parameter nodes
+    * */
+   Map generateMapping(Collection nodes);
       
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -78,7 +78,11 @@
     * @return the failover node ID. If there is no failover node (one-node cluster), the method
     *         returns the original nodeID. 
     */
-   int getFailoverNodeID(int nodeID);
+   //int getFailoverNodeID(int nodeID);
 
+   /** TODO - this method doesn't belong here... We should have POJOTized containers updating dependencies
+    *         between ConnectionFActoryJNDIMapper and DefaultClusteredPostOffice */
+   FailoverMapper getFailoverMapper();
 
+
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -626,6 +626,11 @@
       }
    }
 
+   public FailoverMapper getFailoverMapper()
+   {
+      return failoverMapper;
+   }
+
    // Replicator implementation --------------------------------------------------------------------------
    
    public Map get(Serializable key) throws Exception
@@ -1858,24 +1863,24 @@
       {
          lock.writeLock().release();
       }
-         
+
       synchronized (replicatedData)
-      {         
+      {
          // We need to remove any replicant data for the node. This includes the node-address info.
          for(Iterator i = replicatedData.entrySet().iterator(); i.hasNext(); )
          {
             Map.Entry entry = (Map.Entry)i.next();
-            
+
             String key = (String)entry.getKey();
             Map replicants = (Map)entry.getValue();
-            
+
             replicants.remove(nodeID);
-            
+
             if (replicants.isEmpty())
             {
                i.remove();
-            }     
-            
+            }
+
             // Need to trigger listeners
             notifyListeners(key, replicants, false);
          }
@@ -2479,34 +2484,8 @@
       
       private void generateFailoverMap(Map nodeAddressMap)
       {
-         List nodes = new ArrayList(nodeAddressMap.keySet());
-         
-         log.info("generating failover map");
-         
-         log.info("I have " + nodes.size() + " nodes");
-                                
-         List failoverNodes = failoverMapper.generateMapping(nodes);
-         
-         log.info("I generated " + failoverNodes.size() +" failover nodes");
-         
-         // Now put this in the map of node -> failover node
-         
-         synchronized (failoverMap)
-         {            
-            failoverMap.clear();
-   
-            Iterator iter = nodes.iterator();
-            Iterator iter2 = failoverNodes.iterator();
-   
-            while (iter.hasNext())
-            {
-               Integer node = (Integer)iter.next();
-   
-               Integer failoverNode = (Integer)iter2.next();
-   
-               failoverMap.put(node, failoverNode);
-            }
-         }
+
+         failoverMap = failoverMapper.generateMapping(nodeAddressMap.keySet());
       }      
    }
 }
\ No newline at end of file

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -21,9 +21,10 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import java.util.ArrayList;
-import java.util.List;
-
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.LinkedHashMap;
+import java.util.Map;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 
@@ -42,21 +43,23 @@
 public class DefaultFailoverMapper implements FailoverMapper
 {
    private static final Logger log = Logger.getLogger(DefaultFailoverMapper.class);
-   
-   public List generateMapping(List nodes)
+
+   /** This receives a List<Integer> of nodes and returns a Map<Integer,Integer> of nodes to be used on failover logic */
+   public Map generateMapping(Collection nodes)
    {
-      int s = nodes.size();
+
+      Object[] arrayNodes = (Object[])nodes.toArray(new Integer[nodes.size()]);
+      Arrays.sort(arrayNodes);
+
+      int s = arrayNodes.length;
       
       log.info("Genertaing failover mapping, node size="+ s);
-            
-      List failoverNodes = new ArrayList(s);
+
+
+
+
+      Map failoverNodes = new LinkedHashMap(s);
       
-      if (!(nodes instanceof ArrayList))
-      {
-         //So we can ensure fast index based access
-         nodes = new ArrayList(nodes);
-      }
-            
       for (int i = 0; i < s; i++)
       {
          int j = i + 1;
@@ -66,13 +69,9 @@
             j = 0;
          }
          
-         Object failoverNode = nodes.get(j);
-         
-         failoverNodes.add(failoverNode);
+         failoverNodes.put(arrayNodes[i], arrayNodes[j]);
       }
       
-      log.info("Returning " + failoverNodes.size() + " nodes");
-      
       return failoverNodes;
    }
 

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java	2006-12-08 21:56:34 UTC (rev 1732)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java	2006-12-09 01:15:18 UTC (rev 1733)
@@ -0,0 +1,57 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.core.plugin.postoffice.cluster;
+
+import java.util.ArrayList;
+import java.util.Map;
+import junit.framework.TestCase;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
+
+/**
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class FailoverMapperTest extends TestCase
+{
+
+   public void testMapper()
+   {
+      ArrayList list = new ArrayList();
+
+      list.add(new Integer(50));
+      list.add(new Integer(25));
+      list.add(new Integer(15));
+
+      DefaultFailoverMapper mapper = new DefaultFailoverMapper();
+      Map map = mapper.generateMapping(list);
+
+      assertEquals(new Integer(15),map.get(new Integer(50)));
+      assertEquals(new Integer(50),map.get(new Integer(25)));
+      assertEquals(new Integer(25),map.get(new Integer(15)));
+      
+   }
+
+
+}



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 22:40:03 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 22:40:03 -0500
Subject: [jboss-cvs] JBossAS SVN: r58940 -
	branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test
Message-ID: <E1Gst4F-00017I-TA@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 22:40:02 -0500 (Fri, 08 Dec 2006)
New Revision: 58940

Modified:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
Log:
Remove extraneous log entry

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-08 23:13:01 UTC (rev 58939)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-09 03:40:02 UTC (rev 58940)
@@ -123,8 +123,6 @@
     */
    private void webappUndeployTest(String firstWar, String secondWar) throws Exception
    {
-      log.info("+++ testWebappUndeploy");
-      
       String[] httpURLs  = super.getHttpURLs();
 
       String serverA = httpURLs[0];



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 22:44:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 22:44:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r58941 -
	trunk/testsuite/src/main/org/jboss/test/cluster/web
Message-ID: <E1Gst8p-0001Az-BJ@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 22:44:46 -0500 (Fri, 08 Dec 2006)
New Revision: 58941

Modified:
   trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelper.java
   trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelperMBean.java
Log:
Add getSSOIds for use in ClusteredSSO tests

Modified: trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelper.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelper.java	2006-12-09 03:40:02 UTC (rev 58940)
+++ trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelper.java	2006-12-09 03:44:46 UTC (rev 58941)
@@ -137,6 +137,33 @@
       return result;
    }
    
+   public Set getSSOIds() throws Exception
+   {
+      Set result = new HashSet();
+      
+      Fqn fqn = Fqn.fromString("/SSO");
+      Node main = getCache().getChild(fqn);
+      if (main != null)
+      {
+         result.addAll(main.getChildrenNames());
+      }
+      
+      // Check in the buddy backup tree
+      
+      Set buddies = getBuddyBackupRoots();
+      for (Iterator iter = buddies.iterator(); iter.hasNext();)
+      {
+         Node buddy = (Node) iter.next();
+         Node ssoRoot = buddy.getChild(fqn);
+         if (ssoRoot != null)
+         {
+            result.addAll(ssoRoot.getChildrenNames());
+         }
+      }
+      
+      return result;
+   }
+   
    public boolean getLeaveInstalledAfterShutdown()
    {
       return leaveInstalledAfterShutdown;

Modified: trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelperMBean.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelperMBean.java	2006-12-09 03:40:02 UTC (rev 58940)
+++ trunk/testsuite/src/main/org/jboss/test/cluster/web/CacheHelperMBean.java	2006-12-09 03:44:46 UTC (rev 58941)
@@ -10,6 +10,8 @@
 
    Set getSessionIds(String warFqn) throws Exception;
    
+   Set getSSOIds() throws Exception;
+   
    void setLeaveInstalledAfterShutdown();
    
    void uninstall();



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:03:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:03:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r58942 -
	trunk/testsuite/src/resources/test-configs/tomcat-sso
Message-ID: <E1GstQW-0001aR-Er@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:03:03 -0500 (Fri, 08 Dec 2006)
New Revision: 58942

Added:
   trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/
Log:
Move to AS 5 structure

Copied: trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers (from rev 58786, trunk/testsuite/src/resources/test-configs/tomcat-sso/deploy)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:03:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:03:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r58943 -
	trunk/testsuite/src/resources/test-configs/tomcat-sso
Message-ID: <E1GstRE-0001ak-3Q@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:03:47 -0500 (Fri, 08 Dec 2006)
New Revision: 58943

Removed:
   trunk/testsuite/src/resources/test-configs/tomcat-sso/deploy/
Log:
Move to new structure



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:04:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:04:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r58944 -
	trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers
Message-ID: <E1GstRw-0001b3-SS@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:04:32 -0500 (Fri, 08 Dec 2006)
New Revision: 58944

Added:
   trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer/
Removed:
   trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb-tomcat6.sar/
Log:
Move to new structure

Copied: trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer (from rev 58942, trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb-tomcat6.sar)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:07:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:07:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r58945 -
	trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster
Message-ID: <E1GstV1-0001f4-Ti@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:07:43 -0500 (Fri, 08 Dec 2006)
New Revision: 58945

Added:
   trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/
Removed:
   trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy/
Log:
Move to new structure

Copied: trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers (from rev 58786, trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deploy)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:08:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:08:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58946 -
	trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer
Message-ID: <E1GstVV-0001fN-N5@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:08:13 -0500 (Fri, 08 Dec 2006)
New Revision: 58946

Removed:
   trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer/META-INF/
Log:
Drop extraneous config override



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:09:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:09:06 -0500
Subject: [jboss-cvs] JBossAS SVN: r58947 -
	trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers
Message-ID: <E1GstWM-0001fg-8N@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:09:03 -0500 (Fri, 08 Dec 2006)
New Revision: 58947

Added:
   trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb.deployer/
Removed:
   trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb-tomcat6.sar/
Log:
Move to new structure

Copied: trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb.deployer (from rev 58945, trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb-tomcat6.sar)



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:13:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:13:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r58948 - in
	trunk/testsuite/src/resources/test-configs:
	tomcat-sso/deployers/jbossweb.deployer
	tomcat-sso-cluster/deployers/jbossweb.deployer
Message-ID: <E1Gstar-0001kL-Cx@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:13:42 -0500 (Fri, 08 Dec 2006)
New Revision: 58948

Modified:
   trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb.deployer/server.xml
   trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer/server.xml
Log:
Sync up w/ the current standard server.xml

Modified: trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer/server.xml
===================================================================
--- trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer/server.xml	2006-12-09 04:09:03 UTC (rev 58947)
+++ trunk/testsuite/src/resources/test-configs/tomcat-sso/deployers/jbossweb.deployer/server.xml	2006-12-09 04:13:42 UTC (rev 58948)
@@ -17,13 +17,22 @@
       <Engine name="jboss.web" defaultHost="localhost">
 
          <!-- The JAAS based authentication and authorization realm implementation
-            - certificatePrincipal : the class name of the
-            org.jboss.security.auth.certs.CertificatePrincipal impl
-            used for mapping X509[] cert chains to a Princpal.
+         that is compatible with the jboss 3.2.x realm implementation.
+         - certificatePrincipal : the class name of the
+         org.jboss.security.auth.certs.CertificatePrincipal impl
+         used for mapping X509[] cert chains to a Princpal.
+         - allRolesMode : how to handle an auth-constraint with a role-name=*,
+         one of strict, authOnly, strictAuthOnly
+           + strict = Use the strict servlet spec interpretation which requires
+           that the user have one of the web-app/security-role/role-name
+           + authOnly = Allow any authenticated user
+           + strictAuthOnly = Allow any authenticated user only if there are no
+           web-app/security-roles
          -->
-         <Realm className="org.jboss.web.tomcat.security.JBossSecurityMgrRealm"
+         <Realm className="org.jboss.web.tomcat.security.JBossWebRealm"
             certificatePrincipal="org.jboss.security.auth.certs.SubjectDNMapping"
-            />
+            allRolesMode="authOnly"/>
+ 
 
          <Host name="localhost"
             autoDeploy="false" deployOnStartup="false" deployXML="false">

Modified: trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb.deployer/server.xml
===================================================================
--- trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb.deployer/server.xml	2006-12-09 04:09:03 UTC (rev 58947)
+++ trunk/testsuite/src/resources/test-configs/tomcat-sso-cluster/deployers/jbossweb.deployer/server.xml	2006-12-09 04:13:42 UTC (rev 58948)
@@ -17,14 +17,22 @@
       <Engine name="jboss.web" defaultHost="localhost">
 
          <!-- The JAAS based authentication and authorization realm implementation
-            - certificatePrincipal : the class name of the
-            org.jboss.security.auth.certs.CertificatePrincipal impl
-            used for mapping X509[] cert chains to a Princpal.
+         that is compatible with the jboss 3.2.x realm implementation.
+         - certificatePrincipal : the class name of the
+         org.jboss.security.auth.certs.CertificatePrincipal impl
+         used for mapping X509[] cert chains to a Princpal.
+         - allRolesMode : how to handle an auth-constraint with a role-name=*,
+         one of strict, authOnly, strictAuthOnly
+           + strict = Use the strict servlet spec interpretation which requires
+           that the user have one of the web-app/security-role/role-name
+           + authOnly = Allow any authenticated user
+           + strictAuthOnly = Allow any authenticated user only if there are no
+           web-app/security-roles
          -->
-         <Realm className="org.jboss.web.tomcat.security.JBossSecurityMgrRealm"
+         <Realm className="org.jboss.web.tomcat.security.JBossWebRealm"
             certificatePrincipal="org.jboss.security.auth.certs.SubjectDNMapping"
-            />
-
+            allRolesMode="authOnly"/>
+            
          <Host name="localhost"
             autoDeploy="false" deployOnStartup="false" deployXML="false">
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:29:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:29:46 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58949 - trunk/testsuite/imports
Message-ID: <E1GstqM-0001vZ-JI@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:29:45 -0500 (Fri, 08 Dec 2006)
New Revision: 58949

Modified:
   trunk/testsuite/imports/server-config.xml
Log:
Reflect new name of jbossweb.deployer

Modified: trunk/testsuite/imports/server-config.xml
===================================================================
--- trunk/testsuite/imports/server-config.xml	2006-12-09 04:13:42 UTC (rev 58948)
+++ trunk/testsuite/imports/server-config.xml	2006-12-09 04:29:45 UTC (rev 58949)
@@ -670,12 +670,12 @@
       	 <replace file="${jboss.dist}/server/@{conf}/deploy/tc6-cluster.sar/META-INF/tc6-cluster-beans.xml"
       	   token="&lt;property name=&quot;enabled&quot;&gt;true" value="&lt;property name=&quot;enabled&quot;&gt;@{useBuddyRepl}"/>
       	 <!-- Added jvmRoute in server.xml -->
-         <replace file="${jboss.dist}/server/@{conf}/deployers/jbossweb-tomcat6.deployer/server.xml"
+         <replace file="${jboss.dist}/server/@{conf}/deployers/jbossweb.deployer/server.xml"
            token="jvmRoute=&quot;@{conf}&quot;" value=""/>
-          <replace file="${jboss.dist}/server/@{conf}/deployers/jbossweb-tomcat6.deployer/server.xml"
+          <replace file="${jboss.dist}/server/@{conf}/deployers/jbossweb.deployer/server.xml"
             token="defaultHost" value="jvmRoute=&quot;@{conf}&quot; defaultHost"/>
          <!-- Turn on UseJK in jboss-service.xml -->
-          <replace file="${jboss.dist}/server/@{conf}/deployers/jbossweb-tomcat6.deployer/META-INF/war-deployers-beans.xml"
+          <replace file="${jboss.dist}/server/@{conf}/deployers/jbossweb.deployer/META-INF/war-deployers-beans.xml"
             token="&quot;useJK&quot;&gt;false&lt;" value="&quot;useJK&quot;&gt;true&lt;"/>
       </sequential>
    </macrodef>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:31:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:31:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r58950 - in trunk/testsuite:
	imports/sections src/resources/web/sso
Message-ID: <E1GstsH-0001za-Lc@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:31:44 -0500 (Fri, 08 Dec 2006)
New Revision: 58950

Modified:
   trunk/testsuite/imports/sections/web.xml
   trunk/testsuite/src/resources/web/sso/application.xml
Log:
Test SSO after undeploy with both distributed and non-distributed webapps

Modified: trunk/testsuite/imports/sections/web.xml
===================================================================
--- trunk/testsuite/imports/sections/web.xml	2006-12-09 04:29:45 UTC (rev 58949)
+++ trunk/testsuite/imports/sections/web.xml	2006-12-09 04:31:44 UTC (rev 58950)
@@ -413,6 +413,10 @@
          <zipfileset dir="${build.lib}" includes="sso-form-auth-clustered.war"
             fullpath="sso-form-auth2.war"/>
          <zipfileset dir="${build.lib}" includes="sso-expire.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
+           fullpath="sso-form-auth4.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
+           fullpath="sso-form-auth5.war"/>
          <zipfileset dir="${build.lib}" includes="jbosstest-web-ejbs.jar"/>
       </zip>
 

Modified: trunk/testsuite/src/resources/web/sso/application.xml
===================================================================
--- trunk/testsuite/src/resources/web/sso/application.xml	2006-12-09 04:29:45 UTC (rev 58949)
+++ trunk/testsuite/src/resources/web/sso/application.xml	2006-12-09 04:31:44 UTC (rev 58950)
@@ -25,6 +25,18 @@
       </web>
    </module>
    <module>
+      <web>
+         <web-uri>sso-form-auth4.war</web-uri>
+         <context-root>/war4</context-root>
+      </web>
+   </module>
+   <module>
+      <web>
+         <web-uri>sso-form-auth5.war</web-uri>
+         <context-root>/war5</context-root>
+      </web>
+   </module>
+   <module>
       <ejb>jbosstest-web-ejbs.jar</ejb>
    </module>
 </application>



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:32:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:32:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58951 -
	trunk/testsuite/src/main/org/jboss/test/web/test
Message-ID: <E1Gstsj-0001zt-7M@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:32:12 -0500 (Fri, 08 Dec 2006)
New Revision: 58951

Modified:
   trunk/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java
   trunk/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java
Log:
Port refactor from Branch_4_0

Modified: trunk/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java	2006-12-09 04:31:44 UTC (rev 58950)
+++ trunk/testsuite/src/main/org/jboss/test/web/test/SSOBaseCase.java	2006-12-09 04:32:12 UTC (rev 58951)
@@ -1,32 +1,34 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.web.test;
 
+import java.io.IOException;
 import java.net.HttpURLConnection;
 
 import junit.framework.TestCase;
 import org.apache.commons.httpclient.Cookie;
 import org.apache.commons.httpclient.Header;
 import org.apache.commons.httpclient.HttpClient;
+import org.apache.commons.httpclient.HttpException;
 import org.apache.commons.httpclient.HttpState;
 import org.apache.commons.httpclient.methods.GetMethod;
 import org.apache.commons.httpclient.methods.PostMethod;
@@ -49,141 +51,134 @@
                                                   Logger log) 
          throws Exception
    {
+      String warA1 = serverA + "/war1/";
+      String warB2 = serverB + "/war2/";
+      
       // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();
-      GetMethod indexGet = new GetMethod(serverA+"/war1/index.html");
-      int responseCode = httpConn.executeMethod(indexGet);
-      String body = indexGet.getResponseBodyAsString();
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
+      
+      checkAccessDenied(httpConn, warA1 + "index.html");
 
       HttpState state = httpConn.getState();
-      Cookie[] cookies = state.getCookies();
-      String sessionID = null;
-      for(int c = 0; c < cookies.length; c ++)
-      {
-         Cookie k = cookies[c];
-         if( k.getName().equalsIgnoreCase("JSESSIONID") )
-            sessionID = k.getValue();
-      }
+      
+      String sessionID = getSessionIdFromState(state);
       log.debug("Saw JSESSIONID="+sessionID);
 
       // Submit the login form
-      PostMethod formPost = new PostMethod(serverA+"/war1/j_security_check");
-      formPost.addRequestHeader("Referer", serverA+"/war1/login.html");
+      executeFormLogin(httpConn, warA1);
+
+      String ssoID = processSSOCookie(state, serverA, serverB);
+      log.debug("Saw JSESSIONIDSSO="+ssoID);
+
+      // Pause a moment before switching wars to better simulate real life
+      // use cases.  Otherwise, the test case can "outrun" the async
+      // replication in the TreeCache used by the clustered SSO
+      // 500 ms is a long time, but this isn't a test of replication speed
+      // and we don't want spurious failures.
+      if (!serverA.equals(serverB))
+         Thread.sleep(500);
+
+      // Now try getting the war2 index using the JSESSIONIDSSO cookie 
+      log.debug("Prepare /war2/index.html get");
+      checkAccessAllowed(httpConn, warB2 + "index.html");
+
+      /* Access a secured servlet that calls a secured ejb in war2 to test
+      propagation of the SSO identity to the ejb container. */
+      checkAccessAllowed(httpConn, warB2 + "EJBServlet");
+
+      // Now try logging out of war2 
+      executeLogout(httpConn, warB2);
+      
+      // Again, pause before switching wars
+      if (!serverA.equals(serverB))
+         Thread.sleep(500);
+      
+      // Try accessing war1 again      
+      checkAccessDenied(httpConn, warA1 + "index.html");
+      
+      // Try accessing war2 again      
+      checkAccessDenied(httpConn, warB2 + "index.html");      
+      
+   }
+
+   public static void executeLogout(HttpClient httpConn, String warURL) throws IOException, HttpException
+   {
+      GetMethod logout = new GetMethod(warURL + "Logout");
+      logout.setFollowRedirects(false);
+      int responseCode = httpConn.executeMethod(logout.getHostConfiguration(),
+         logout, httpConn.getState());
+      assertTrue("Logout: Saw HTTP_MOVED_TEMP("+responseCode+")",
+         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
+      Header location = logout.getResponseHeader("Location");
+      String indexURI = location.getValue();
+      if( indexURI.indexOf("index.html") < 0 )
+         fail("get of " + warURL + "Logout not redirected to login page");
+   }
+
+   public static void checkAccessAllowed(HttpClient httpConn, String url) throws IOException, HttpException
+   {
+      GetMethod war2Index = new GetMethod(url);
+      int responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
+         war2Index, httpConn.getState());
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      String body = war2Index.getResponseBodyAsString();
+      if( body.indexOf("j_security_check") > 0 )
+         fail("get of " + url + " redirected to login page");
+   }
+
+   public static void executeFormLogin(HttpClient httpConn, String warURL) throws IOException, HttpException
+   {      
+      PostMethod formPost = new PostMethod(warURL + "j_security_check");
+      formPost.addRequestHeader("Referer", warURL + "login.html");
       formPost.addParameter("j_username", "jduke");
       formPost.addParameter("j_password", "theduke");
-      responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
-         formPost, state);
-      String response = formPost.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
+      int responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
+         formPost, httpConn.getState());
       assertTrue("Saw HTTP_MOVED_TEMP("+responseCode+")",
          responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
 
       //  Follow the redirect to the index.html page
       Header location = formPost.getResponseHeader("Location");
       String indexURI = location.getValue();
-      GetMethod war1Index = new GetMethod(indexURI);
-      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
-         war1Index, state);
+      GetMethod warIndex = new GetMethod(indexURI);
+      responseCode = httpConn.executeMethod(warIndex.getHostConfiguration(),
+         warIndex, httpConn.getState());
       assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war1Index.getResponseBodyAsString();
+      String body = warIndex.getResponseBodyAsString();
       if( body.indexOf("j_security_check") > 0 )
          fail("get of "+indexURI+" redirected to login page");
+   }
 
-      cookies = state.getCookies();
+   public static void checkAccessDenied(HttpClient httpConn, String url) throws IOException, HttpException
+   {
+      GetMethod indexGet = new GetMethod(url);
+      int responseCode = httpConn.executeMethod(indexGet);
+      String body = indexGet.getResponseBodyAsString();
+      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
+      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
+   }
+
+   public static String processSSOCookie(HttpState state, String serverA, String serverB)
+   {
+      Cookie[] cookies = state.getCookies();
       String ssoID = null;
       for(int c = 0; c < cookies.length; c ++)
       {
-         Cookie k = cookies[c];
-         if( k.getName().equalsIgnoreCase("JSESSIONIDSSO") )
+         if( "JSESSIONIDSSO".equalsIgnoreCase(cookies[c].getName()) )
          {
-            ssoID = k.getValue();
+            ssoID = cookies[c].getValue();
             if (serverA.equals(serverB) == false) 
             {
                // Make an sso cookie to send to serverB
-               Cookie copy = copyCookie(k, serverB);
+               Cookie copy = copyCookie(cookies[c], serverB);
                state.addCookie(copy);
-               log.debug("Added state cookie: "+copy);
             }
          }
       }
-      assertTrue("Saw JSESSIONIDSSO", ssoID != null);
-      log.debug("Saw JSESSIONIDSSO="+ssoID);
-
-      // Pause a moment before switching wars to better simulate real life
-      // use cases.  Otherwise, the test case can "outrun" the async
-      // replication in the TreeCache used by the clustered SSO
-      // 500 ms is a long time, but this isn't a test of replication speed
-      // and we don't want spurious failures.
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
-
-      // Now try getting the war2 index using the JSESSIONIDSSO cookie 
-      log.debug("Prepare /war2/index.html get");
-      GetMethod war2Index = new GetMethod(serverB+"/war2/index.html");
-      responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
-         war2Index, state);
-      response = war2Index.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war2Index.getResponseBodyAsString();
-      log.debug("body: "+body);
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of /war2/index.html redirected to login page");
-
-      /* Access a secured servlet that calls a secured ejb in war2 to test
-      propagation of the SSO identity to the ejb container.
-      */
-      GetMethod war2Servlet = new GetMethod(serverB+"/war2/EJBServlet");
-      responseCode = httpConn.executeMethod(war2Servlet.getHostConfiguration(),
-         war2Servlet, state);
-      response = war2Servlet.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war2Servlet.getResponseBodyAsString();
-      log.debug("body: "+body);
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of /war2/EJBServlet redirected to login page");
-
-      // Now try logging out of war2 
-      GetMethod war2Logout = new GetMethod(serverB+"/war2/Logout");
-      war2Logout.setFollowRedirects(false);
-      responseCode = httpConn.executeMethod(war2Logout.getHostConfiguration(),
-         war2Logout, state);
-      response = war2Logout.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Logout: Saw HTTP_MOVED_TEMP("+responseCode+")",
-         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
-      location = war2Logout.getResponseHeader("Location");
-      indexURI = location.getValue();
-      if( indexURI.indexOf("index.html") < 0 )
-         fail("get of /war2/Logout not redirected to login page");
       
-      // Again, pause before switching wars
-      if (!serverA.equals(serverB))
-         Thread.sleep(500);
+      assertNotNull("Saw JSESSIONIDSSO", ssoID);
       
-      // Try accessing war1 again
-      war1Index = new GetMethod(serverA+"/war1/index.html");
-      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
-         war1Index, state);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war1Index.getResponseBodyAsString();
-      log.debug("body: " + body);
-      if( body.indexOf("j_security_check") < 0 )
-         fail("get of /war1/index.html not redirected to login page");
-      
-      // Try accessing war2 again
-      war2Index = new GetMethod(serverB+"/war2/index.html");
-      responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
-         war2Index, state);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war2Index.getResponseBodyAsString();
-      log.debug("body: " + body);
-      if( body.indexOf("j_security_check") < 0 )
-         fail("get of /war2/index.html not redirected to login page");      
-      
+      return ssoID;
    }
    
    public static Cookie copyCookie(Cookie toCopy, String targetServer)
@@ -213,4 +208,17 @@
                                false);
       return copy;
    }
+   
+   public static String getSessionIdFromState(HttpState state)
+   {
+      Cookie[] cookies = state.getCookies();
+      String sessionID = null;
+      for(int c = 0; c < cookies.length; c ++)
+      {
+         if( "JSESSIONID".equalsIgnoreCase(cookies[c].getName()) )
+            sessionID = cookies[c].getName();
+      }
+      return sessionID;
+      
+   }
 }

Modified: trunk/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java	2006-12-09 04:31:44 UTC (rev 58950)
+++ trunk/testsuite/src/main/org/jboss/test/web/test/SingleSignOnUnitTestCase.java	2006-12-09 04:32:12 UTC (rev 58951)
@@ -1,24 +1,24 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.web.test;
 
 import org.jboss.test.JBossTestCase;



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:33:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:33:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r58952 -
	trunk/testsuite/src/main/org/jboss/test/web/test
Message-ID: <E1Gsttt-00020C-D8@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:33:24 -0500 (Fri, 08 Dec 2006)
New Revision: 58952

Modified:
   trunk/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
Log:
Test SSO after undeploy with both distributed and non-distributed webapps
Use CacheHelper to test SSO count

Modified: trunk/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-09 04:32:12 UTC (rev 58951)
+++ trunk/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-09 04:33:24 UTC (rev 58952)
@@ -1,45 +1,43 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.web.test;
 
-import java.net.HttpURLConnection;
+import java.util.Set;
 
+import javax.management.ObjectName;
+
 import junit.framework.Test;
+import junit.framework.TestSuite;
 
-import org.apache.commons.httpclient.Cookie;
-import org.apache.commons.httpclient.Header;
 import org.apache.commons.httpclient.HttpClient;
 import org.apache.commons.httpclient.HttpState;
-import org.apache.commons.httpclient.methods.GetMethod;
-import org.apache.commons.httpclient.methods.PostMethod;
-
+import org.jboss.cache.Fqn;
 import org.jboss.jmx.adaptor.rmi.RMIAdaptor;
 import org.jboss.test.JBossClusteredTestCase;
+import org.jboss.test.cluster.web.CacheHelper;
 
 
 /** Tests of web app single sign-on in a clustered environment
  * 
- * TODO general refactoring; a lot of duplicated code here
- * 
  * @author Brian Stansberry
  * @version $Revision$
  */
@@ -62,15 +60,23 @@
     */
    public static Test suite() throws Exception
    {
-      Test t1 = JBossClusteredTestCase.getDeploySetup(ClusteredSingleSignOnUnitTestCase.class,
-            "web-sso-clustered.ear");
-      return t1;
+      // Have to build the suite in detail, as testSessionExpiration must come first
+      TestSuite suite = new TestSuite();
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testSessionExpiration"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testFormAuthSingleSignOn"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployNonClusteredWebapp"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployClusteredWebapp"));
+      
+      return JBossClusteredTestCase.getDeploySetup(suite, "web-sso-clustered.ear");
    }
-   
+
    protected void setUp() throws Exception
    {
       super.setUp();
       
+      log.debug("deployed0 = " + deployed0);
+      log.debug("deployed1 = " + deployed1);
+      
       adaptors = getAdaptors(); 
       if (!deployed0)
       {
@@ -84,6 +90,28 @@
       }
    }
    
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+      
+      log.debug("deployed0 = " + deployed0);
+      log.debug("deployed1 = " + deployed1);
+   }
+   
+   public void testUndeployNonClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployNonClusteredWebapp");
+      
+      webappUndeployTest("war4", "war5");
+   }
+   
+   public void testUndeployClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployClusteredWebapp");
+      
+      webappUndeployTest("war1", "war2");
+   }
+   
    /**
     * Tests that undeploying a webapp on one server doesn't kill an sso
     * that also has a session from another webapp associated with it.
@@ -94,72 +122,30 @@
     *
     * @throws Exception
     */
-   public void testWebappUndeploy() throws Exception
+   private void webappUndeployTest(String firstWar, String secondWar) throws Exception
    {
-      log.info("+++ testWebappUndeploy");
-      
       String[] httpURLs  = super.getHttpURLs();
 
       String serverA = httpURLs[0];
       String serverB = httpURLs[1];
       
+      String warA1 = serverA + "/" + firstWar +"/";
+      String warB1 = serverB + "/" + firstWar +"/";
+      String warB2 = serverB + "/" + secondWar +"/";
+      
       // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();
-      GetMethod indexGet = new GetMethod(serverA+"/war1/index.html");
-      int responseCode = httpConn.executeMethod(indexGet);
-      String body = indexGet.getResponseBodyAsString();
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
+      SSOBaseCase.checkAccessDenied(httpConn,  warA1 + "index.html");
 
       HttpState state = httpConn.getState();
-      Cookie[] cookies = state.getCookies();
-      String sessionID = null;
-      for(int c = 0; c < cookies.length; c ++)
-      {
-         Cookie k = cookies[c];
-         if( k.getName().equalsIgnoreCase("JSESSIONID") )
-            sessionID = k.getValue();
-      }
+      
+      String sessionID = SSOBaseCase.getSessionIdFromState(state);
       log.debug("Saw JSESSIONID="+sessionID);
-
+      
       // Submit the login form
-      PostMethod formPost = new PostMethod(serverA+"/war1/j_security_check");
-      formPost.addRequestHeader("Referer", serverA+"/war1/login.html");
-      formPost.addParameter("j_username", "jduke");
-      formPost.addParameter("j_password", "theduke");
-      responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
-         formPost, state);
-      String response = formPost.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Saw HTTP_MOVED_TEMP("+responseCode+")",
-         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
+      SSOBaseCase.executeFormLogin(httpConn, warA1);
 
-      //  Follow the redirect to the index.html page
-      Header location = formPost.getResponseHeader("Location");
-      String indexURI = location.getValue();
-      GetMethod war1Index = new GetMethod(indexURI);
-      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
-         war1Index, state);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war1Index.getResponseBodyAsString();
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of "+indexURI+" redirected to login page");
-
-      cookies = state.getCookies();
-      String ssoID = null;
-      for(int c = 0; c < cookies.length; c ++)
-      {
-         Cookie k = cookies[c];
-         if( k.getName().equalsIgnoreCase("JSESSIONIDSSO") )
-         {
-            ssoID = k.getValue();
-            // Make an sso cookie to send to serverB
-            Cookie copy = SSOBaseCase.copyCookie(k, serverB);
-            state.addCookie(copy);
-            log.debug("Added state cookie: "+copy);
-         }
-      }
-      assertTrue("Saw JSESSIONIDSSO", ssoID != null);
+      String ssoID = SSOBaseCase.processSSOCookie(state, serverA, serverB);
       log.debug("Saw JSESSIONIDSSO="+ssoID);
 
       // Pause a moment before switching wars to better simulate real life
@@ -172,16 +158,7 @@
 
       // Now try getting the war2 index using the JSESSIONIDSSO cookie 
       log.debug("Prepare /war2/index.html get");
-      GetMethod war2Index = new GetMethod(serverB+"/war2/index.html");
-      responseCode = httpConn.executeMethod(war2Index.getHostConfiguration(),
-         war2Index, state);
-      response = war2Index.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war2Index.getResponseBodyAsString();
-      log.debug("body: "+body);
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of /war2/index.html redirected to login page");
+      SSOBaseCase.checkAccessAllowed(httpConn, warB2 + "index.html");
 
       // Sleep some more to allow the updated sso to propagate back to serverA
       if (!serverA.equals(serverB))
@@ -199,18 +176,9 @@
       if (!serverA.equals(serverB))
          Thread.sleep(500);
       
-      //    Now try getting the war1 index using the JSESSIONIDSSO cookie 
+      // Now try getting the war1 index using the JSESSIONIDSSO cookie 
       log.debug("Prepare /war1/index.html get");
-      war1Index = new GetMethod(serverB+"/war1/index.html");
-      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
-         war1Index, state);
-      response = war1Index.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war1Index.getResponseBodyAsString();
-      log.debug("body: "+body);
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of /war1/index.html redirected to login page");
+      SSOBaseCase.checkAccessAllowed(httpConn, warB1 + "index.html");
    }
 
 
@@ -244,72 +212,71 @@
       String[] httpURLs  = super.getHttpURLs();
 
       String serverA = httpURLs[0];
+      String serverB = httpURLs[1];
       log.info(System.getProperties());
       log.info("serverA: "+serverA);
+      log.info("serverB: "+serverB);
       
-      // Start by accessing the secured index.html of war1
+      String warA3 = serverA + "/war3/";
+      String warB3 = serverB + "/war3/";
+      
+      // First create an SSO that we won't use again -- we later test that it
+      // gets cleaned up from the cache
+      HttpClient httpConn1 = new HttpClient();
+      SSOBaseCase.checkAccessDenied(httpConn1, warA3 + "index.jsp");
+      SSOBaseCase.executeFormLogin(httpConn1, warA3);
+      
+      // Now the standard SSO tests
       HttpClient httpConn = new HttpClient();
-      GetMethod indexGet = new GetMethod(serverA+"/war3/index.jsp");
-      int responseCode = httpConn.executeMethod(indexGet);
-      String body = indexGet.getResponseBodyAsString();
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      assertTrue("Redirected to login page", body.indexOf("j_security_check") > 0 );
+      SSOBaseCase.checkAccessDenied(httpConn, warA3 + "index.jsp");
+      HttpState state = httpConn.getState();      
+      String sessionID = SSOBaseCase.getSessionIdFromState(state);
+      log.debug("Saw JSESSIONID="+sessionID);
+      SSOBaseCase.executeFormLogin(httpConn, warA3);
+      String ssoID = SSOBaseCase.processSSOCookie(state, serverA, serverB);
+      log.debug("Saw JSESSIONIDSSO="+ssoID);
 
-      HttpState state = httpConn.getState();
-      Cookie[] cookies = state.getCookies();
-      String sessionID = null;
-      for(int c = 0; c < cookies.length; c ++)
+      // Wait more than 15 secs to let session time out
+      // It's life is 5 secs and the processor runs every 10
+      try {
+         Thread.sleep(15500);
+      }
+      catch (InterruptedException ie)
       {
-         Cookie k = cookies[c];
-         if( k.getName().equalsIgnoreCase("JSESSIONID") )
-            sessionID = k.getValue();
+         log.debug("Interrupted while waiting for session expiration");
       }
-      log.debug("Saw JSESSIONID="+sessionID);
+      
+      // Try accessing war3 again on both nodes -- should succeed
+      SSOBaseCase.checkAccessAllowed(httpConn, warA3 + "index.jsp");
+      SSOBaseCase.checkAccessAllowed(httpConn, warB3 + "index.jsp");
 
-      // Submit the login form
-      PostMethod formPost = new PostMethod(serverA+"/war3/j_security_check");
-      formPost.addRequestHeader("Referer", serverA+"/war3/login.html");
-      formPost.addParameter("j_username", "jduke");
-      formPost.addParameter("j_password", "theduke");
-      responseCode = httpConn.executeMethod(formPost.getHostConfiguration(),
-         formPost, state);
-      String response = formPost.getStatusText();
-      log.debug("responseCode="+responseCode+", response="+response);
-      assertTrue("Saw HTTP_MOVED_TEMP("+responseCode+")",
-         responseCode == HttpURLConnection.HTTP_MOVED_TEMP);
-
-      //  Follow the redirect to the index.html page
-      Header location = formPost.getResponseHeader("Location");
-      String indexURI = location.getValue();
-      GetMethod war1Index = new GetMethod(indexURI);
-      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
-         war1Index, state);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war1Index.getResponseBodyAsString();
-      if( body.indexOf("j_security_check") > 0 )
-         fail("get of "+indexURI+" redirected to login page");
-
-      // Wait more than 65 secs to let session time out
-      // 5 secs for the session timeout, 2 * 30 secs for the processor thread
-      // TODO for some reason it takes 1 min for processExpires to run ???
-      // (not an sso issue -- a tomcat issue)
+      // Wait more than 30 secs to let SSO time out -- 15 for the sessions
+      // (as above) and 15 for the SSOs maxEmptyLife
       try {
-         Thread.sleep(65500);
+         Thread.sleep(30500);
       }
       catch (InterruptedException ie)
       {
-         log.debug("Interrupted while waiting for session expiration");
+         log.debug("Interrupted while waiting for SSO expiration");
       }
       
-      // Try accessing war1 again
-      war1Index = new GetMethod(serverA+"/war3/index.jsp");
-      responseCode = httpConn.executeMethod(war1Index.getHostConfiguration(),
-         war1Index, state);
-      assertTrue("Get OK", responseCode == HttpURLConnection.HTTP_OK);
-      body = war1Index.getResponseBodyAsString();
-      log.debug("body: " + body);
-      if( body.indexOf("j_security_check") < 0 )
-         fail("get of /war1/index.html not redirected to login page");
+      // Try accessing war3 again on both nodes -- should fail
+      SSOBaseCase.checkAccessDenied(httpConn, warA3 + "index.jsp");
+      SSOBaseCase.checkAccessDenied(httpConn, warB3 + "index.jsp");
       
+      // Confirm that the SSO we created at the start was removed from
+      // the cache
+      Set ssoIds = getSSOIds(adaptors[0]);
+      log.info("node0 sso ids are " + ssoIds);
+      assertEquals("node0 cache has no SSOs", 0, ssoIds.size());
+      ssoIds = getSSOIds(adaptors[1]);
+      log.info("node1 sso ids are " + ssoIds);
+      assertEquals("node1 cache has no SSOs", 0, ssoIds.size());
    }
+   
+   private Set getSSOIds(RMIAdaptor adaptor) throws Exception
+   {
+      return (Set) adaptor.invoke(CacheHelper.OBJECT_NAME, "getChildrenNames", 
+                                  new Object[0], new String[0]);
+   }
 }



From jboss-cvs-commits at lists.jboss.org  Fri Dec  8 23:33:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 08 Dec 2006 23:33:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r58953 -
	trunk/testsuite/src/resources/web/sso/war
Message-ID: <E1GstuB-00020V-VW@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-08 23:33:43 -0500 (Fri, 08 Dec 2006)
New Revision: 58953

Modified:
   trunk/testsuite/src/resources/web/sso/war/web-sso-expire.xml
Log:
Use CacheHelper to test SSO count

Modified: trunk/testsuite/src/resources/web/sso/war/web-sso-expire.xml
===================================================================
--- trunk/testsuite/src/resources/web/sso/war/web-sso-expire.xml	2006-12-09 04:33:24 UTC (rev 58952)
+++ trunk/testsuite/src/resources/web/sso/war/web-sso-expire.xml	2006-12-09 04:33:43 UTC (rev 58953)
@@ -6,7 +6,13 @@
 <web-app>
    <description>WebApp Integration Tests</description>
 	<!--distributable/-->
-   <servlet>
+  
+   <!-- Registers an mbean the test driver can use to check the cache state -->
+   <listener>
+  	  <listener-class>org.jboss.test.cluster.web.CacheHelperServletContextListener</listener-class>
+   </listener>
+  
+  <servlet>
       <servlet-name>LogoutServlet</servlet-name>
       <servlet-class>org.jboss.test.web.servlets.LogoutServlet</servlet-class>
    </servlet>



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 00:37:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 00:37:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r58954 - in branches/Branch_4_2/testsuite:
	imports/sections src/main/org/jboss/test/web/test
	src/resources/web/sso
Message-ID: <E1GsuuH-0002yq-22@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-09 00:37:49 -0500 (Sat, 09 Dec 2006)
New Revision: 58954

Modified:
   branches/Branch_4_2/testsuite/imports/sections/web.xml
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
   branches/Branch_4_2/testsuite/src/resources/web/sso/application.xml
Log:
Clustered SSO test tests both distributed and non-distributed webapps

Modified: branches/Branch_4_2/testsuite/imports/sections/web.xml
===================================================================
--- branches/Branch_4_2/testsuite/imports/sections/web.xml	2006-12-09 04:33:43 UTC (rev 58953)
+++ branches/Branch_4_2/testsuite/imports/sections/web.xml	2006-12-09 05:37:49 UTC (rev 58954)
@@ -358,6 +358,10 @@
          <zipfileset dir="${build.lib}" includes="sso-form-auth-clustered.war"
             fullpath="sso-form-auth2.war"/>
          <zipfileset dir="${build.lib}" includes="sso-expire.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
+           fullpath="sso-form-auth4.war"/>
+        <zipfileset dir="${build.lib}" includes="sso-form-auth.war"
+           fullpath="sso-form-auth5.war"/>
          <zipfileset dir="${build.lib}" includes="jbosstest-web-ejbs.jar"/>
       </zip>
       

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-09 04:33:43 UTC (rev 58953)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/web/test/ClusteredSingleSignOnUnitTestCase.java	2006-12-09 05:37:49 UTC (rev 58954)
@@ -63,7 +63,8 @@
       TestSuite suite = new TestSuite();
       suite.addTest(new ClusteredSingleSignOnUnitTestCase("testSessionExpiration"));
       suite.addTest(new ClusteredSingleSignOnUnitTestCase("testFormAuthSingleSignOn"));
-      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testWebappUndeploy"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployNonClusteredWebapp"));
+      suite.addTest(new ClusteredSingleSignOnUnitTestCase("testUndeployClusteredWebapp"));
       
       return JBossClusteredTestCase.getDeploySetup(suite, "web-sso-clustered.ear");
    }
@@ -96,6 +97,20 @@
       log.debug("deployed1 = " + deployed1);
    }
    
+   public void testUndeployNonClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployNonClusteredWebapp");
+      
+      webappUndeployTest("war4", "war5");
+   }
+   
+   public void testUndeployClusteredWebapp() throws Exception
+   {
+      log.info("+++ testUndeployClusteredWebapp");
+      
+      webappUndeployTest("war1", "war2");
+   }
+   
    /**
     * Tests that undeploying a webapp on one server doesn't kill an sso
     * that also has a session from another webapp associated with it.
@@ -106,18 +121,16 @@
     *
     * @throws Exception
     */
-   public void testWebappUndeploy() throws Exception
+   private void webappUndeployTest(String firstWar, String secondWar) throws Exception
    {
-      log.info("+++ testWebappUndeploy");
-      
       String[] httpURLs  = super.getHttpURLs();
 
       String serverA = httpURLs[0];
       String serverB = httpURLs[1];
       
-      String warA1 = serverA + "/war1/";
-      String warB1 = serverB + "/war1/";
-      String warB2 = serverB + "/war2/";
+      String warA1 = serverA + "/" + firstWar +"/";
+      String warB1 = serverB + "/" + firstWar +"/";
+      String warB2 = serverB + "/" + secondWar +"/";
       
       // Start by accessing the secured index.html of war1
       HttpClient httpConn = new HttpClient();

Modified: branches/Branch_4_2/testsuite/src/resources/web/sso/application.xml
===================================================================
--- branches/Branch_4_2/testsuite/src/resources/web/sso/application.xml	2006-12-09 04:33:43 UTC (rev 58953)
+++ branches/Branch_4_2/testsuite/src/resources/web/sso/application.xml	2006-12-09 05:37:49 UTC (rev 58954)
@@ -25,6 +25,18 @@
       </web>
    </module>
    <module>
+      <web>
+         <web-uri>sso-form-auth4.war</web-uri>
+         <context-root>/war4</context-root>
+      </web>
+   </module>
+   <module>
+      <web>
+         <web-uri>sso-form-auth5.war</web-uri>
+         <context-root>/war5</context-root>
+      </web>
+   </module>
+   <module>
       <ejb>jbosstest-web-ejbs.jar</ejb>
    </module>
 </application>



From forge-admin at jboss.com  Sat Dec  9 01:00:30 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sat, 09 Dec 2006 01:00:30 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GsvGA-0003GJ-MM@committer01.frg.pub.inap.atl.jboss.com>

Commit from nrichards (2006-12-08 01:34 EST)
---------------------

use new build

  jboss-seam  examples/portal/build.xml  1.10


Commit from chiba (2006-12-08 02:00 EST)
-----------------

minor bug fix

  javassist  src/main/javassist/expr/ExprEditor.java  1.11


Commit from starksm (2006-12-08 02:11 EST)
-------------------

Rename aop jboss-aop to be consistent with the artifact names

+ repository.jboss.com  maven2/jboss/jboss-aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.jar             1.1
+ repository.jboss.com  maven2/jboss/jboss-aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.pom             1.1
  repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom   1.2
  repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom~  1.2


Commit from starksm (2006-12-08 03:21 EST)
-------------------

Change the dependency from jboss-microcontainer to jboss-kernel

  repository.jboss.com  maven2/jboss/jboss-aop-mc-int/2.0.0.Beta/jboss-aop-mc-int-2.0.0.Beta.pom  1.3


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-08 07:04 EST)
------------------------------------------------------

More informative logging/error msgs

  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java  1.25.2.8


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-08 07:17 EST)
------------------------------------------------------

Anycast test

  JBossCache  src/org/jboss/cache/TreeCache.java                            1.195.2.30
+ JBossCache  tests/functional/org/jboss/cache/replicated/AnycastTest.java  1.1.2.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-08 07:35 EST)
------------------------------------------------------

Anycast should use reflection

  JBossCache  tests/functional/org/jboss/cache/replicated/AnycastTest.java  1.1.2.2
  JBossCache  src/org/jboss/cache/TreeCache.java                            1.195.2.31


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-08 08:10 EST)
------------------------------------------------------

Fixed broken test

  JBossCache  tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java  1.9.2.3


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-08 08:18 EST)
------------------------------------------------------

Fixed broken test

  JBossCache  tests/functional/org/jboss/cache/transaction/SuspendTxTest.java  1.1.2.3


Commit from nrichards (2006-12-08 10:52 EST)
---------------------

fix typo

  jboss-seam  doc/reference/en/modules/drools.xml  1.13


Commit from mculpepper (2006-12-08 11:29 EST)
----------------------

attempting to fix an endless loop when a project is registered that fires an event to UI that causes another register.. etc..

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java  1.9


Commit from mculpepper (2006-12-08 11:45 EST)
----------------------

only register a project if it isn't being registered already...

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java  1.10


Commit from dlloyd (2006-12-08 12:50 EST)
------------------

Add ajax4jsf 1.0.4MR2

+ repository.jboss.com  ajax4jsf/1.0.4MR2/component-info.xml  1.1
+ repository.jboss.com  ajax4jsf/1.0.4MR2/lib/ajax4jsf.jar    1.1


Commit from ebernard (2006-12-08 13:37 EST)
--------------------

*** empty log message ***

+ repository.jboss.com  hibernate-entitymanager/3.2.1.GA/component-info.xml               1.1
+ repository.jboss.com  hibernate-entitymanager/3.2.1.GA/lib/ejb3-persistence.jar         1.1
+ repository.jboss.com  hibernate-entitymanager/3.2.1.GA/lib/hibernate-entitymanager.jar  1.1
+ repository.jboss.com  hibernate-annotations/3.2.1.GA/component-info.xml                 1.1
+ repository.jboss.com  hibernate-annotations/3.2.1.GA/lib/hibernate-annotations.jar      1.1


Commit from genman (2006-12-08 13:49 EST)
------------------

JBCACHE-892 Use JDK1.5 concurrent classes

  JBossCache  src/org/jboss/cache/loader/FileCacheLoader.java                         1.27
  JBossCache  src/org/jboss/cache/loader/AsyncCacheLoader.java                        1.24
  JBossCache  src/org/jboss/cache/interceptors/CreateIfNotExistsInterceptor.java      1.20
  JBossCache  src/org/jboss/cache/interceptors/PassivationInterceptor.java            1.34
  JBossCache  src/org/jboss/cache/interceptors/CacheStoreInterceptor.java             1.39
  JBossCache  src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java         1.30
  JBossCache  src/org/jboss/cache/interceptors/ActivationInterceptor.java             1.43
  JBossCache  src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java  1.31
  JBossCache  src/org/jboss/cache/interceptors/CacheMgmtInterceptor.java              1.24
  JBossCache  src/org/jboss/cache/interceptors/TxInterceptor.java                     1.67
  JBossCache  src/org/jboss/cache/TransactionTable.java                               1.11
  JBossCache  src/org/jboss/cache/RegionImpl.java                                     1.15
  JBossCache  src/org/jboss/cache/Region.java                                         1.9
  JBossCache  src/org/jboss/cache/TreeCache.java                                      1.291
  JBossCache  src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java                 1.17
  JBossCache  src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java                  1.23
  JBossCache  src/org/jboss/cache/util/MapCopy.java                                   1.4
  JBossCache  src/org/jboss/cache/optimistic/TransactionWorkspaceImpl.java            1.14
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                  1.49
  JBossCache  src/org/jboss/cache/marshall/Marshaller.java                            1.6
  JBossCache  src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java                    1.18


Commit from genman (2006-12-08 13:50 EST)
------------------

JBCACHE-891 Use JDK 1.5 lock classes

  JBossCache  src/org/jboss/cache/lock/LockStrategyReadUncommitted.java                                    1.2
  JBossCache  src/org/jboss/cache/lock/ReadWriteLockWithUpgrade.java                                       1.4
  JBossCache  src/org/jboss/cache/lock/LockStrategyRepeatableRead.java                                     1.2
  JBossCache  src/org/jboss/cache/lock/SimpleReadWriteLock.java                                            1.2
  JBossCache  src/org/jboss/cache/lock/IsolationLevel.java                                                 1.7
  JBossCache  src/org/jboss/cache/lock/LockStrategyReadCommitted.java                                      1.2
  JBossCache  src/org/jboss/cache/lock/LockMap.java                                                        1.11
  JBossCache  src/org/jboss/cache/lock/LockStrategyNone.java                                               1.2
  JBossCache  src/org/jboss/cache/lock/SimpleLock.java                                                     1.4
  JBossCache  src/org/jboss/cache/lock/LockUtil.java                                                       1.5
  JBossCache  src/org/jboss/cache/lock/IdentityLock.java                                                   1.17
  JBossCache  src/org/jboss/cache/lock/LockStrategy.java                                                   1.2
  JBossCache  src/org/jboss/cache/lock/LockStrategyFactory.java                                            1.5
  JBossCache  src/org/jboss/cache/lock/LockStrategySerializable.java                                       1.4
+ JBossCache  src/org/jboss/cache/lock/NullLock.java                                                       1.1
+ JBossCache  src/org/jboss/cache/lock/SemaphoreLock.java                                                  1.1
  JBossCache  tests/functional/org/jboss/cache/lock/ReentrantWriterPreferenceReadWriteLockTest.java        1.4
  JBossCache  tests/functional/org/jboss/cache/lock/ReentrantWriterPreference2Readers1WriterLockTest.java  1.6
  JBossCache  tests/functional/org/jboss/cache/lock/ReadWriteLockWithUpgradeTest.java                      1.3
  JBossCache  tests/functional/org/jboss/cache/lock/NonBlockingWriterLockTest.java                         1.3
  JBossCache  tests/functional/org/jboss/cache/lock/LockTest.java                                          1.9


Commit from genman (2006-12-08 14:00 EST)
------------------

JBCACHE-891 Use JDK 1.5 lock classes

  JBossCache  tests/stress/org/jboss/cache/ReadWriteLockWithUpgradeStressTest.java  1.2


Commit from genman (2006-12-08 14:03 EST)
------------------

JBCACHE-888 Clean up node interfaces a little more

  JBossCache  src/org/jboss/cache/DataNode.java                  1.20
  JBossCache  src/org/jboss/cache/Fqn.java                       1.42
  JBossCache  src/org/jboss/cache/NodeImpl.java                  1.22
  JBossCache  src/org/jboss/cache/TreeNode.java                  1.29
  JBossCache  src/org/jboss/cache/optimistic/FqnComparator.java  1.5


Commit from genman (2006-12-08 14:09 EST)
------------------

JBCACHE-888 Clean up node interfaces a little more

  JBossCache  tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java  1.17
+ JBossCache  tests/functional/org/jboss/cache/NodeImplTest.java                          1.1


Commit from genman (2006-12-08 14:19 EST)
------------------

JBCACHE-880 - clean up expiration policy (still a work in progress)

  JBossCache  src/org/jboss/cache/eviction/ExpirationPolicy.java                   1.2
  JBossCache  src/org/jboss/cache/eviction/ExpirationConfiguration.java            1.2
  JBossCache  src/org/jboss/cache/eviction/ExpirationAlgorithm.java                1.3
  JBossCache  tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java  1.3


Commit from dlloyd (2006-12-08 17:09 EST)
------------------

Add JSF RI 1.2_03

+ repository.jboss.com  sun-jsf/1.2_03/component-info.xml  1.1
+ repository.jboss.com  sun-jsf/1.2_03/lib/jsf-api.jar     1.1
+ repository.jboss.com  sun-jsf/1.2_03/lib/jsf-impl.jar    1.1


Commit from myuan (2006-12-08 17:53 EST)
-----------------

facelets module support in netbeans

  jboss-seam  seam-gen/build.xml              1.47
  jboss-seam  seam-gen/nbproject/project.xml  1.7
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061209/fc65d535/attachment.html 

From mandersen at jboss.com  Sat Dec  9 07:21:20 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Sat, 09 Dec 2006 07:21:20 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/lib  ...
Message-ID: <E1Gt1Ci-0000ya-NH@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/09 07:21:20

  Modified:    seam-gen/lib  hibernate-tools.jar
  Log:
  fix multi named uniqueconstraint gen bug
  
  Revision  Changes    Path
  1.5       +142 -150  jboss-seam/seam-gen/lib/hibernate-tools.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 09:40:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 09:40:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1734 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt3Nc-000366-Gc@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 09:40:30 -0500 (Sat, 09 Dec 2006)
New Revision: 1734

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Fixed HA issue with replicating chnages



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -25,6 +25,7 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Map;
 
 import javax.jms.JMSException;
 
@@ -75,9 +76,9 @@
    //Cache this here
    private ClientConnectionFactoryDelegate[] delegates;
    
-   private int[] failoverIndexes;
+   private Map failoverMap;
    
-   private int current;
+   private int currentRobinIndex;
    
    public Object handleCreateConnectionDelegate(Invocation invocation) throws Throwable
    {
@@ -115,11 +116,11 @@
    //TODO this is currently hardcoded as round-robin, this should be made pluggable
    private synchronized ClientConnectionFactoryDelegate getDelegateRoundRobin()
    {
-      ClientConnectionFactoryDelegate currentDelegate = delegates[current++];
+      ClientConnectionFactoryDelegate currentDelegate = delegates[currentRobinIndex++];
       
-      if (current >= delegates.length)
+      if (currentRobinIndex >= delegates.length)
       {
-         current = 0;
+         currentRobinIndex = 0;
       }
       return currentDelegate;
    }
@@ -150,11 +151,11 @@
          {
             //TODO: Fix this! metadata should contain CF_FAILOVER_INDEXES
             //failoverIndexes = (int[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES);
-            failoverIndexes = (int[])((ClusteredClientConnectionFactoryDelegate)target).getFailoverIndexes();
+            failoverMap = ((ClusteredClientConnectionFactoryDelegate)target).getFailoverMap();
 
-            if (failoverIndexes == null)
+            if (failoverMap == null)
             {
-               throw new IllegalStateException("Cannot find failoverIndexes!");
+               throw new IllegalStateException("Cannot find failoverMap!");
             }
          }
       }
@@ -181,7 +182,7 @@
    //The connection has failed
    private void handleFailure(ClientConnectionDelegate failedConnection) throws Exception
    {
-      ClientConnectionFactoryDelegate newCF = getAlternateDelegate(failedConnection);
+      ClientConnectionFactoryDelegate newCF = getFailoverDelegate(failedConnection);
 
       //TODO implement client side valve to prevent invocations occurring whilst failover is occurring
       
@@ -202,74 +203,69 @@
       }
    }
    
-   private ClientConnectionFactoryDelegate getAlternateDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
+   private ClientConnectionFactoryDelegate getFailoverDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
    {
       //We need to choose which delegate to fail over to
       
-      //This is determined by the failoverIndexes array
-      //The fail over delegate for delegates[i] is given by
-      //delegates[failoverIndexes[i]]
-      
       ConnectionState currentState = (ConnectionState)((DelegateSupport)currentDelegate).getState();
       
-      String currentLocator =
-         currentState.getRemotingConnection().getInvokingClient().getInvoker().getLocator().getLocatorURI();
+      int currentServerID = currentState.getServerID();
       
-      int local = -1;
+      //Lookup in the failover map to see which server to fail over onto
       
+      Integer failoverServerID = (Integer)failoverMap.get(new Integer(currentServerID));
+      
+      if (failoverServerID == null)
+      {
+         throw new IllegalStateException("Cannot find failover node for node " + currentServerID);
+      }
+      
+      //Now find the actual delegate
+      
+      ClientConnectionFactoryDelegate del = null;
+      
       for (int i = 0; i < delegates.length; i++)
       {
-         ConnectionState state = (ConnectionState)((DelegateSupport)delegates[i]).getState();
-         
-         String locator =
-            state.getRemotingConnection().getInvokingClient().getInvoker().getLocator().getLocatorURI();
-         
-         if (currentLocator.equals(locator))
+         if (delegates[i].getServerId() == failoverServerID.intValue())
          {
-            local = i;
+            del = delegates[i];
             
             break;
          }
       }
       
-      //Sanity
-      if (local == -1)
+      if (del == null)
       {
-         throw new IllegalStateException("Cannot find local delegate!");
+         throw new IllegalStateException("Cannot find failover delegate for node " + failoverServerID.intValue());
       }
-      
-      if (delegates.length == 1)
-      {
-         throw new IllegalStateException("Cannot failover connection since no servers to fail over onto");
-      }      
-
-      ClientConnectionFactoryDelegate delegateFound = delegates[failoverIndexes[local]];
-
-
+           
       // Redirect connection routine.
       // Verify the failureMap on the server and if out of sync find the correct delegate
       
-      int failoverNode = delegateFound.getFailoverNode(currentState.getServerID());
-      if (failoverNode!=delegateFound.getServerId())
-      {
-         delegateFound = null;
-         for (int i = 0; i < delegates.length; i++)
-         {
-            if (delegates[i].getServerId() == failoverNode)
-            {
-               delegateFound = delegates[i];
-            }
-         }
+      
+      //THIS IS WRONG - cannot use getFailoverNode method since failover node might change
+      //between getting the result and actually failing over
+      
+//      int failoverNode = delegateFound.getFailoverNode(currentState.getServerID());
+//      if (failoverNode!=delegateFound.getServerId())
+//      {
+//         delegateFound = null;
+//         for (int i = 0; i < delegates.length; i++)
+//         {
+//            if (delegates[i].getServerId() == failoverNode)
+//            {
+//               delegateFound = delegates[i];
+//            }
+//         }
+//
+//         if (delegateFound==null)
+//         {
+//            throw new IllegalStateException("Cannot find failover node on current map for nodeId=" + failoverNode);
+//         }
+//
+//      }
 
-         if (delegateFound==null)
-         {
-            throw new IllegalStateException("Cannot find failover node on current map for nodeId=" + failoverNode);
-         }
-
-      }
-
-      return delegateFound;
-
+      return del;
    }
    
    private void failover(ClientConnectionDelegate failedConnection, ClientConnectionDelegate newConnection) throws Exception

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -21,9 +21,9 @@
  */
 package org.jboss.jms.client.delegate;
 
-import org.jboss.aop.util.PayloadKey;
+import java.util.Map;
+
 import org.jboss.jms.server.Version;
-import org.jboss.jms.server.remoting.MetaDataConstants;
 
 /**
  * A ClusteredClientConnectionFactoryDelegate
@@ -49,24 +49,21 @@
 
    // Attributes ----------------------------------------------------
 
-   /**
-    * If delegates[i] is the current delegate, then the failover delegate is given by
-    * delegates[failoverIndexes[i]]
-    */
    private ClientConnectionFactoryDelegate[] delegates;
 
-   private int[] failoverIndexes;
+   //Map <node Id, failover node id>
+   private Map failoverMap;
 
    // Constructors --------------------------------------------------
 
    public ClusteredClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
                                                    Version serverVersion, boolean clientPing,
                                                    ClientConnectionFactoryDelegate[] delegates,
-                                                   int[] failoverIndexes)
+                                                   Map failoverMap)
    {
       super(objectID, serverId, serverLocatorURI, serverVersion, clientPing);
       this.delegates = delegates;
-      this.failoverIndexes = failoverIndexes;
+      this.failoverMap = failoverMap;
    }
 
    // Some of the properties of ClientConnectionFactoryDelegate are not exposed..
@@ -74,10 +71,10 @@
    // So, I created this Constructor so I could have access into protected members inside an extension class
    public ClusteredClientConnectionFactoryDelegate(ClientConnectionFactoryDelegate mainDelegate,
                                                    ClientConnectionFactoryDelegate[] delegates,
-                                                   int[] failoverIndexes)
+                                                   Map failoverMap)
    {
       this(mainDelegate.getID(), mainDelegate.serverId, mainDelegate.serverLocatorURI,
-         mainDelegate.serverVersion, mainDelegate.clientPing, delegates, failoverIndexes);
+         mainDelegate.serverVersion, mainDelegate.clientPing, delegates, failoverMap);
    }
 
    // DelegateSupport overrides -------------------------------------
@@ -93,15 +90,17 @@
             delegates[i].init();
          }
       }
+      
+      //This doesn't seem to be used so I'm commenting it out
 
-      // We add this to the meta data so the failOver aspect can get access to it
-      getMetaData().addMetaData(MetaDataConstants.JMS,
-                                MetaDataConstants.CF_DELEGATES,
-                                delegates, PayloadKey.TRANSIENT);
-
-      getMetaData().addMetaData(MetaDataConstants.JMS,
-                                MetaDataConstants.CF_FAILOVER_INDEXES,
-                                failoverIndexes, PayloadKey.TRANSIENT);
+//      // We add this to the meta data so the failOver aspect can get access to it
+//      getMetaData().addMetaData(MetaDataConstants.JMS,
+//                                MetaDataConstants.CF_DELEGATES,
+//                                delegates, PayloadKey.TRANSIENT);
+//
+//      getMetaData().addMetaData(MetaDataConstants.JMS,
+//                                MetaDataConstants.FAILOVER_MAP,
+//                                failoverMap, PayloadKey.TRANSIENT);
    }
 
    // Public --------------------------------------------------------
@@ -113,11 +112,21 @@
       return delegates;
    }
 
-   /** As metadata is not working, I'm exposing this temporarily */
-   public int[] getFailoverIndexes()
+   /** TODO As metadata is not working, I'm exposing this temporarily */
+   public Map getFailoverMap()
    {
-      return failoverIndexes;
+      return failoverMap;
    }
+   
+   public void setFailoverMap(Map failoverMap)
+   {
+      this.failoverMap = failoverMap;
+   }
+   
+   public void setDelegates(ClientConnectionFactoryDelegate[] dels)
+   {
+      this.delegates = dels;
+   }
 
    public String toString()
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -22,13 +22,16 @@
 package org.jboss.jms.server.connectionfactory;
 
 import java.io.Serializable;
+import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
+
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
@@ -40,8 +43,10 @@
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.util.JNDIUtil;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.contract.ReplicationListener;
 import org.jboss.messaging.core.plugin.contract.Replicator;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -75,6 +80,13 @@
    
    protected Replicator replicator;
    
+   /*
+   We cache the map of node->failover node in here.
+   This is then updated when node joins or leaves the cluster via the replicationListener
+   When new cfs are deployed we use the cached map
+   */
+   protected Map failoverMap;
+   
    // Constructors --------------------------------------------------
    
    public ConnectionFactoryJNDIMapper(ServerPeer serverPeer) throws Exception
@@ -107,6 +119,7 @@
       }
       
       int id = serverPeer.getNextObjectID();
+      
       Version version = serverPeer.getVersion();
 
       ServerConnectionFactoryEndpoint endpoint =
@@ -128,55 +141,46 @@
          log.info("ConnectionFactoryJNDIMapper is non clustered");
       }
       
-      /* if (clustered)
+      boolean creatingClustered = clustered && replicator != null;
+      
+      ClientConnectionFactoryDelegate localDelegate =
+         new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
+                                             locatorURI, version, clientPing);
+      
+      /*
+       * When registering a new clustered connection factory i should first create it with the available delegates
+       * then send the replication message.
+       * We then listen for connection factories added to global state using the replication listener
+       * and then update their connection factory list.
+       * This will happen locally too, so we will get the replication message locally - to avoid updating it again
+       * we can ignore any "add" replication updates that originate from the current node.
+       */
+      
+      if (creatingClustered)
       {
-         setupReplicator();
+         //Replicate the change - we will ignore this locally
          
-         if (replicator != null)
-         {                                             
-            //Replicator might still be null since we might be deploying a clustered cf in a non clustered
-            //post office (which is ok)
-            delegate = new ClusteredClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(), locatorURI, version, clientPing);
-         }
+         replicator.put(CF_PREFIX + uniqueName, localDelegate);
+         
+         //Create a clustered delegate
+         
+         Map localDelegates = replicator.get(CF_PREFIX + uniqueName);
+         
+         delegate = createClusteredDelegate(localDelegates);
+         
       }
+      else
+      {
+         delegate = localDelegate;
+      }
       
-      if (delegate == null)
-      {
-         //Local
-         delegate = new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
-                                        locatorURI, version, clientPing);
-      } */
-
-      delegate = new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
-                                     locatorURI, version, clientPing);
-
-
-      //delegate = new ClusteredClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(), locatorURI, version, clientPing);
-
-
       log.trace("Adding delegates factory " + uniqueName + " pointing to " + delegate);
+      
       delegates.put(uniqueName, delegate);
 
-
-      // We are clustered, we need to propagate the local delegate across the cluster.
-
-      // ... and then update it (and the clustered delegate on every node, while we're at it) by
-      // replicating the local delegate across the cluster. This way, the clustred delegates on each
-      // node will contain an updated list of local delegates, and all ConnectionFactoryJNDIMapper
-      // will rebind updated ConnectionFactories in JNDI.
-      // This will update the local node too
-
-      log.info("CF_PREFIX=" + CF_PREFIX + " uniqueName=" + uniqueName + " delegate = " + delegate + " replicator = " + replicator);
-      if (replicator != null)
-      {
-         replicator.put(CF_PREFIX + uniqueName, delegate);
-      }
-      else
-      {
-         //Now bind it in JNDI
-         rebindConnectionFactory(initialContext, jndiBindings, delegate);
-      }
-
+      //Now bind it in JNDI
+      rebindConnectionFactory(initialContext, jndiBindings, delegate);
+      
       //Registering with the dispatcher should always be the last thing otherwise a client could use
       //a partially initialised object
       JMSDispatcher.instance.registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
@@ -243,19 +247,6 @@
    {
       initialContext = new InitialContext();
       
-      /*
-
-      ConnectionFActoryJNDIMapper is started in a call of ServerPeer, while replicator is started later
-      when the postoffices are started. So, I'm keeping the registration of replicator lazy on the first connection
-      Allthough this is not a proper design, as we might loose messages when the PostOffice is connected
-
-      replicator = serverPeer.getDataReplicator();
-
-      if (replicator != null)
-      {
-         replicator.registerListener(this);
-      } */
-
       log.debug("started");
    }
    
@@ -273,40 +264,99 @@
    
    // ReplicationListener interface ----------------------------------
    
-   public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added)
+   public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap,
+                                                boolean added, int originatingNodeId)
    {
       log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap + " added=");
       try
-      {
-         // The list of connection factories across the cluster has changed, so we need to update
-         // the clustered connection factories in JNDI with new ones with the up to date list.
-         // Replication can be used for other stuff (not just connection factories) so we check
-         // the prefix.
+      {         
+         if (!(key instanceof String))
+         {
+            return;
+         }
          
          String sKey = (String)key;
-         
-         if (key instanceof String && sKey.startsWith(CF_PREFIX))
+
+         if (sKey.equals(DefaultClusteredPostOffice.ADDRESS_INFO_KEY))
          {
-            //We only need to rebind if the cf is being added
+           /* 
+            We respond to changes in the node-address mapping
+            This will be replicated whan a node joins / leaves the group
+            When this happens we need to recalculate the failoverMap
+            and rebind all connection factories with the new mapping
+            We cannot just reference a single map since the objects are bound in JNDI
+            in serialized form
+            */
+            log.info("responding to node - adress info change. Recalculating mapping and rebinding cfs");
             
+            recalculateFailoverMap(updatedReplicantMap);
+            
+            //rebind
+            Iterator iter = endpoints.entrySet().iterator();
+            
+            while (iter.hasNext())
+            {
+               Map.Entry entry = (Map.Entry)iter.next();
+               
+               String uniqueName = (String)entry.getKey();
+               
+               ServerConnectionFactoryEndpoint endpoint =
+                  (ServerConnectionFactoryEndpoint)entry.getValue();
+               
+               ClusteredClientConnectionFactoryDelegate del = (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+               
+               if (del == null)
+               {
+                  throw new IllegalStateException("Cannot find cf with name " + uniqueName);
+               }
+               
+               del.setFailoverMap(failoverMap);
+               
+               rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
+            }
+            
+         }
+         else if (sKey.startsWith(CF_PREFIX) && originatingNodeId != serverPeer.getServerPeerID())
+         {
+            /*
+            A connection factory has been deployed / undeployed - we need to update the local delegate arrays inside the clustered
+            connection factories with the same name
+            We don't recalculate the failover map since the number of nodes in the group hasn't changed
+            We also ignore any local changes since the cf will already be bound locally with the new
+            local delegate in the array
+            */
+            
             String uniqueName = sKey.substring(CF_PREFIX.length());
             
-            ClusteredClientConnectionFactoryDelegate clusteredDelegate = createClusteredDelegate(updatedReplicantMap);
+            log.info("Connection factory with unique name " + uniqueName + " has been added / removed");
             
-            // Now rebind ...
+            ClusteredClientConnectionFactoryDelegate del = (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+            
+            if (del == null)
+            {
+               throw new IllegalStateException("Cannot find cf with name " + uniqueName);
+            }
+            
+            ClientConnectionFactoryDelegate[] delArr = 
+               (ClientConnectionFactoryDelegate[])updatedReplicantMap.values().toArray(new ClientConnectionFactoryDelegate[updatedReplicantMap.size()]);
 
+            log.info("Updating delsArr with size " + delArr.length);
+            
+            del.setDelegates(delArr);
+            
             ServerConnectionFactoryEndpoint endpoint =
                (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
-
+            
             if (endpoint == null)
             {
-               throw new IllegalStateException("Cannot find endpoint " + uniqueName );
+               throw new IllegalStateException("Cannot find endpoint with name " + uniqueName);
             }
-
-            rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), clusteredDelegate);
-         }
+            
+            rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
+            
+         }            
       }
-      catch (NamingException e)
+      catch (Exception e)
       {
          log.error("Failed to rebind connection factory", e);
       }
@@ -332,96 +382,63 @@
       this.serverPeer.getQueuePostOfficeInstance();
    }
 
-
+   private void recalculateFailoverMap(Map nodeAddressMap) throws Exception
+   {     
+      List nodes = new ArrayList(nodeAddressMap.keySet());
+      
+      FailoverMapper mapper = replicator.getFailoverMapper();
+      
+      failoverMap = mapper.generateMapping(nodes);
+   }
+   
    /**
     * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
     */
-   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates)
+   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates) throws Exception
    {
       //TODO: make it trace after the code is stable
       log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
 
-      // Calculates the failoverMap based on the current list of localDelegates
-      Map failoverMap = replicator.getFailoverMapper().generateMapping(localDelegates.keySet());
+      ClientConnectionFactoryDelegate[] delArr = 
+         (ClientConnectionFactoryDelegate[])localDelegates.values().toArray(new ClientConnectionFactoryDelegate[localDelegates.size()]);
 
-      int s = localDelegates.size();
-
-      int[] nodesIDs = new int[s];
-      int[] failoverNodeIDs = new int[s];
-      ClientConnectionFactoryDelegate[] delegates = new ClientConnectionFactoryDelegate[s];
-      // Ths created ClusteredClientFactoryDelegate will copy the properties from this delegate which is
-      // the delegate on this current serverPeer
-      ClientConnectionFactoryDelegate mainDelegate = null;
-
-      int idx = 0;
-
-      for(Iterator i = localDelegates.entrySet().iterator(); i.hasNext();)
+      //If the map is not cached - generate it now
+      
+      if (failoverMap == null)
       {
-         Map.Entry entry = (Map.Entry)i.next();
-
-         Integer nodeID = (Integer)entry.getKey();
-         Integer failoverNodeID = (Integer)failoverMap.get(nodeID); 
-
-         log.trace("setFailoverDelegates inside forIterator::nodeID=" + nodeID + " failoverNodeID=" + failoverNodeID);
-
-         nodesIDs[idx] = nodeID.intValue();
-         failoverNodeIDs[idx] = failoverNodeID.intValue();
-         delegates[idx] = (ClientConnectionFactoryDelegate)entry.getValue();
-
-         if (delegates[idx].getServerId() == this.serverPeer.getServerPeerID())
+         Map nodeAddressMap = replicator.get(DefaultClusteredPostOffice.ADDRESS_INFO_KEY);
+         
+         if (nodeAddressMap == null)
          {
-            // sanity check
-            if (mainDelegate != null)
-            {
-               throw new IllegalStateException("There are two servers with serverID=" + this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
-            }
-            mainDelegate = delegates[idx];
+            throw new IllegalStateException("Cannot find address node mapping!");
          }
-
-         idx++;
+         
+         recalculateFailoverMap(nodeAddressMap);
       }
-      // Generate the failover indexes. This could probably be optimised if need be.
       
-      //MainDelegate would be null in the case the cf is being undeployed locally
+      //Now we find the "mainDelegate"
+      //TODO - why do we need a "mainDelegate" ????
       
-      ClusteredClientConnectionFactoryDelegate clusteredDelegate = null;
+      ClientConnectionFactoryDelegate mainDelegate = null;
       
-      if (mainDelegate != null)
-      {         
-         int[] failoverIndexes = new int[s];
-         
-         for (int i = 0; i < s; i++)
-         {
-            int failoverNode = failoverNodeIDs[i];
-            int failoverIndex = -1;
+      for(Iterator i = localDelegates.values().iterator(); i.hasNext();)
+      {
+         ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)i.next();
             
-            for (int j = 0; j < s; j++)
-            {
-               if (nodesIDs[j] == failoverNode)
-               {
-                  failoverIndex = j;
-                  break;
-               }
-            }
+          if (del.getServerId() == this.serverPeer.getServerPeerID())
+          {
+             // sanity check
+             if (mainDelegate != null)
+             {
+                throw new IllegalStateException("There are two servers with serverID=" + this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
+             }
+             mainDelegate = del;
+          }
+      }
             
-            if (failoverIndex == -1)
-            {
-               //throw new IllegalStateException("Failover node " + failoverNode + " is not in list of nodes at node " + serverPeer.getServerPeerID() + "!");
-               
-               //It is possible that the failover node is not found  - this might happen
-               //if this is executed when a cf is undeployed but the failover node still contains
-               //the old node.
-               
-               //In this case the node leave event will shortly
-            }
-            
-            failoverIndexes[i] = failoverIndex;
-         }
-   
-         clusteredDelegate =
-            new ClusteredClientConnectionFactoryDelegate(mainDelegate, delegates, failoverIndexes);
-      }
-
+      ClusteredClientConnectionFactoryDelegate clusteredDelegate =
+         new ClusteredClientConnectionFactoryDelegate(mainDelegate, delArr, failoverMap);
+      
       return clusteredDelegate;
    }
    

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -53,7 +53,7 @@
    
    public static final String REMOTING_CONNECTION = "REMOTING_CONNECTION";
    
-   public static final String CF_FAILOVER_INDEXES = "CF_FAIL_IND";
+   public static final String FAILOVER_MAP = "CF_FAIL_IND";
    
    public static final String CONNECTION_VERSION = "CONNECTION_VERSION";
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -21,7 +21,7 @@
  */
 package org.jboss.messaging.core.plugin.contract;
 
-import java.util.Collection;
+import java.util.List;
 import java.util.Map;
 
 /**
@@ -37,12 +37,5 @@
  */
 public interface FailoverMapper
 {
-   /** This receives a List<Integer> of nodes and returns a Map<Integer,Integer> of nodes to be used on failover logic.
-    *
-    * An implementation of this method should aways sort received nodes first before calculating as the parameter list
-    * might be in a different order, and it should aways return the same result for the same set of nodes whatever is
-    * the order of parameter nodes
-    * */
-   Map generateMapping(Collection nodes);
-      
+   Map generateMapping(List nodes);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -39,5 +39,5 @@
     * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
     *        the given key.
     */
-   void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added);
+   void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added, int originatingNodeId);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -67,22 +67,8 @@
    
    void unregisterListener(ReplicationListener listener);
    
-   /**
-    * TODO - this method doesn't belong here, as no semantics should be associated with data at this
-    *        level
-    *
-    * Gets the current failover node ID for the specified node ID.
-    *
-    * @param nodeID - The node to get the failover node id for.
-    *
-    * @return the failover node ID. If there is no failover node (one-node cluster), the method
-    *         returns the original nodeID. 
-    */
-   //int getFailoverNodeID(int nodeID);
-
-   /** TODO - this method doesn't belong here... We should have POJOTized containers updating dependencies
+   /** TODO - this method doesn't belong here... We should have POJOized containers updating dependencies
     *         between ConnectionFActoryJNDIMapper and DefaultClusteredPostOffice */
    FailoverMapper getFailoverMapper();
 
-
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -93,7 +93,7 @@
    private static final Logger log = Logger.getLogger(DefaultClusteredPostOffice.class);
    
    // Key for looking up node id -> address info mapping from replicated data
-   private static final String ADDRESS_INFO_KEY = "address_info";
+   public static final String ADDRESS_INFO_KEY = "address_info";
    
    //Used for failure testing
    private boolean failBeforeCommit;
@@ -722,7 +722,7 @@
          
          m.put(new Integer(originatorNodeID), replicant);
          
-         notifyListeners(key, m, true);
+         notifyListeners(key, m, true, originatorNodeID);
       }
    }
 
@@ -753,7 +753,7 @@
          {
             replicatedData.remove(key);
          } 
-         notifyListeners(key, m, false);
+         notifyListeners(key, m, false, originatorNodeID);
       
          return true; 
       }
@@ -1821,15 +1821,15 @@
    /*
     * Removes all non durable binding data, and any local replicant data for the specified node.
     */
-   private void removeDataForNode(Integer nodeID) throws Exception
+   private void removeDataForNode(Integer nodeToRemove) throws Exception
    {
-      log.info("Node " + nodeID + " requested to leave cluster");
+      log.info("Node " + nodeToRemove + " requested to leave cluster");
       
       lock.writeLock().acquire();
 
       try
       {          
-         Map nameMap = (Map)nameMaps.get(nodeID);
+         Map nameMap = (Map)nameMaps.get(nodeToRemove);
 
          if (nameMap != null)
          {
@@ -1855,7 +1855,7 @@
             {
                Binding binding = (Binding)iter.next();
                
-               removeBinding(nodeID.intValue(), binding.getQueue().getName());
+               removeBinding(nodeToRemove.intValue(), binding.getQueue().getName());
             }
          }         
       }
@@ -1874,7 +1874,7 @@
             String key = (String)entry.getKey();
             Map replicants = (Map)entry.getValue();
 
-            replicants.remove(nodeID);
+            replicants.remove(nodeToRemove);
 
             if (replicants.isEmpty())
             {
@@ -1882,7 +1882,7 @@
             }
 
             // Need to trigger listeners
-            notifyListeners(key, replicants, false);
+            notifyListeners(key, replicants, false, nodeToRemove.intValue());
          }
       }
    }
@@ -1891,7 +1891,8 @@
     * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
     *        the given key.
     */
-   private void notifyListeners(Serializable key, Map updatedReplicantMap, boolean added)
+   private void notifyListeners(Serializable key, Map updatedReplicantMap, boolean added,
+                                int originatorNodeId)
    { 
       synchronized (replicationListeners)
       {         
@@ -1899,7 +1900,7 @@
          {
             ReplicationListener listener = (ReplicationListener)i.next();
             
-            listener.onReplicationChange(key, updatedReplicantMap, added);
+            listener.onReplicationChange(key, updatedReplicantMap, added, originatorNodeId);
          }
       }
    } 
@@ -2115,7 +2116,7 @@
          
          Map replicants = (Map)entry.getValue();
          
-         Map m = new HashMap();
+         Map m = new LinkedHashMap();
          
          m.putAll(replicants);
          
@@ -2461,7 +2462,8 @@
    private class NodeAddressMapListener implements ReplicationListener
    {
 
-      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added)
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added,
+                                      int originatorNodeId)
       {
          if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
          {
@@ -2484,8 +2486,7 @@
       
       private void generateFailoverMap(Map nodeAddressMap)
       {
-
-         failoverMap = failoverMapper.generateMapping(nodeAddressMap.keySet());
+         failoverMap = failoverMapper.generateMapping(new ArrayList(nodeAddressMap.keySet()));
       }      
    }
 }
\ No newline at end of file

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -21,10 +21,11 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import java.util.Arrays;
-import java.util.Collection;
-import java.util.LinkedHashMap;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
 import java.util.Map;
+
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 
@@ -45,20 +46,20 @@
    private static final Logger log = Logger.getLogger(DefaultFailoverMapper.class);
 
    /** This receives a List<Integer> of nodes and returns a Map<Integer,Integer> of nodes to be used on failover logic */
-   public Map generateMapping(Collection nodes)
+   public Map generateMapping(List nodes)
    {
-
-      Object[] arrayNodes = (Object[])nodes.toArray(new Integer[nodes.size()]);
-      Arrays.sort(arrayNodes);
-
-      int s = arrayNodes.length;
+      if (!(nodes instanceof ArrayList))
+      {
+         //Convert to array list for fast index access
+         nodes = new ArrayList(nodes);
+      }
       
-      log.info("Genertaing failover mapping, node size="+ s);
+      int s = nodes.size();
+      
+      log.info("Generating failover mapping, node size= "+ s);
 
-
-
-
-      Map failoverNodes = new LinkedHashMap(s);
+      //There is no need for the map to be linked
+      Map failoverNodes = new HashMap(s);
       
       for (int i = 0; i < s; i++)
       {
@@ -69,7 +70,7 @@
             j = 0;
          }
          
-         failoverNodes.put(arrayNodes[i], arrayNodes[j]);
+         failoverNodes.put(nodes.get(i), nodes.get(j));
       }
       
       return failoverNodes;

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 01:15:18 UTC (rev 1733)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 14:40:30 UTC (rev 1734)
@@ -22,6 +22,8 @@
 
 package org.jboss.test.messaging.jms.clustering;
 
+import java.util.Map;
+
 import javax.jms.Connection;
 import javax.jms.MessageConsumer;
 import javax.jms.TextMessage;
@@ -187,6 +189,23 @@
       
    }
  
+   public void testStartStopProblem() throws Exception
+   {
+      //Three nodes should be running now
+      
+      //Stop one of them
+      
+      ServerManagement.stop(0, true);
+      
+      //Stop another
+      
+      ServerManagement.stop(1, true);
+      
+      
+      
+   }
+   
+   
    /*
     * Test that the failover mapping is created correctly
     */
@@ -207,67 +226,89 @@
       
       ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
       
+      //The order here depends on the order the servers were started in
+      
+      log.info("cf1 serverid=" + cf1.getServerId());
+      
+      log.info("cf2 serverid=" + cf2.getServerId());
+      
+      log.info("cf3 serverid=" + cf3.getServerId());
+      
+      
       assertEquals(0, cf1.getServerId());
       
       assertEquals(1, cf2.getServerId());
       
       assertEquals(2, cf3.getServerId());
       
-      int[] failoverIndexes = delegate.getFailoverIndexes();
+      Map failoverMap = delegate.getFailoverMap();
       
       assertEquals(3, delegates.length);
       
-      assertEquals(3, failoverIndexes.length);
+      assertEquals(3, failoverMap.size());
       
       // Default failover policy just chooses the node to the right
       
-      log.info("failoverindex[0]:" + failoverIndexes[0]);
-      log.info("failoverindex[1]:" + failoverIndexes[1]);
-      log.info("failoverindex[2]:" + failoverIndexes[2]);
+      assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
       
-      assertEquals(1, failoverIndexes[0]);
+      assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
       
-      assertEquals(2, failoverIndexes[1]);
+      assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
       
-      assertEquals(0, failoverIndexes[2]);
+      assertEquals(2, ((Integer)failoverMap.get(new Integer(1))).intValue());
       
       //Now cleanly stop one of the servers
       
+      
+      log.info("************** STOPPING SERVER 0");
       ServerManagement.stop(0, true);
       
+      log.info("server stopped");
+      
       assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
       
       //Lookup another connection factory
       
       JBossConnectionFactory factory2 =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
       
+      log.info("Got connection factory");
+      
       ClusteredClientConnectionFactoryDelegate delegate2 =
          (ClusteredClientConnectionFactoryDelegate)factory2.getDelegate();
       
       ClientConnectionFactoryDelegate[] delegates2 = delegate2.getDelegates();
       
-      int[] failoverIndexes2 = delegate2.getFailoverIndexes();
+      Map failoverMap2 = delegate2.getFailoverMap();
       
+      log.info("Got failover map");
+      
       assertEquals(2, delegates2.length);
       
       cf1 = delegate2.getDelegates()[0];
       
       cf2 = delegate2.getDelegates()[1];
       
-      assertEquals(0, cf1.getServerId());
+      //Order here depends on order servers were started in
       
-      assertEquals(1, cf2.getServerId());
+      log.info("cf1 serverid=" + cf1.getServerId());
       
+      log.info("cf2 serverid=" + cf2.getServerId());
       
+      assertEquals(1, cf1.getServerId());
       
-      assertEquals(2, failoverIndexes2.length);
+      assertEquals(2, cf2.getServerId());
       
-      assertEquals(1, failoverIndexes2[0]);
       
-      assertEquals(0, failoverIndexes2[1]);
+      assertEquals(2, failoverMap2.size());
       
+      assertEquals(cf2.getServerId(), ((Integer)failoverMap2.get(new Integer(cf1.getServerId()))).intValue());
+      
+      assertEquals(cf1.getServerId(), ((Integer)failoverMap2.get(new Integer(cf2.getServerId()))).intValue());
+      
       //Cleanly stop another server
       
+      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+      
       ServerManagement.stop(1, true);
       
       assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
@@ -281,7 +322,7 @@
       
       ClientConnectionFactoryDelegate[] delegates3 = delegate3.getDelegates();
       
-      int[] failoverIndexes3 = delegate3.getFailoverIndexes();
+      Map failoverMap3 = delegate3.getFailoverMap();
       
       assertEquals(1, delegates3.length);
       
@@ -290,11 +331,10 @@
       assertEquals(0, cf1.getServerId());
       
       
-      assertEquals(1, failoverIndexes3.length);
+      assertEquals(1, failoverMap3.size());
       
-      assertEquals(0, failoverIndexes3[0]);
-      
-      
+      assertEquals(cf1.getServerId(), ((Integer)failoverMap3.get(new Integer(cf1.getServerId()))).intValue());
+            
       //TODO - Add nodes back into the cluster - test framework currently does not support this
       
       



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 09:54:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 09:54:50 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1735 - in
	branches/Branch_Client_Failover_Experiment/tests: .
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/tools
Message-ID: <E1Gt3bG-0003EP-S8@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 09:54:47 -0500 (Sat, 09 Dec 2006)
New Revision: 1735

Modified:
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
Log:
Fixed problem in server start/stopping



Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-09 14:40:30 UTC (rev 1734)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-09 14:54:47 UTC (rev 1735)
@@ -727,7 +727,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 14:40:30 UTC (rev 1734)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 14:54:47 UTC (rev 1735)
@@ -199,10 +199,7 @@
       
       //Stop another
       
-      ServerManagement.stop(1, true);
-      
-      
-      
+      ServerManagement.stop(1, true);                 
    }
    
    

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-09 14:40:30 UTC (rev 1734)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-09 14:54:47 UTC (rev 1735)
@@ -173,7 +173,7 @@
 
    public static synchronized void stop(int index, boolean sendNotification) throws Exception
    {
-      insureStarted();
+      insureStarted(index);
 
       servers[index].stop(sendNotification);
    }



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 10:11:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 10:11:34 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1736 - in
	branches/Branch_Client_Failover_Experiment/tests: .
	src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt3rS-0003eZ-AR@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 10:11:31 -0500 (Sat, 09 Dec 2006)
New Revision: 1736

Modified:
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
All tests now pass



Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-09 14:54:47 UTC (rev 1735)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-09 15:11:31 UTC (rev 1736)
@@ -727,7 +727,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/HATest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 14:54:47 UTC (rev 1735)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 15:11:31 UTC (rev 1736)
@@ -189,20 +189,6 @@
       
    }
  
-   public void testStartStopProblem() throws Exception
-   {
-      //Three nodes should be running now
-      
-      //Stop one of them
-      
-      ServerManagement.stop(0, true);
-      
-      //Stop another
-      
-      ServerManagement.stop(1, true);                 
-   }
-   
-   
    /*
     * Test that the failover mapping is created correctly
     */
@@ -225,6 +211,8 @@
       
       //The order here depends on the order the servers were started in
       
+      //If any servers get stopped and then started then the order will change
+ 
       log.info("cf1 serverid=" + cf1.getServerId());
       
       log.info("cf2 serverid=" + cf2.getServerId());
@@ -325,7 +313,7 @@
       
       cf1 = delegate3.getDelegates()[0];
       
-      assertEquals(0, cf1.getServerId());
+      assertEquals(2, cf1.getServerId());
       
       
       assertEquals(1, failoverMap3.size());



From msurtani at jboss.com  Sat Dec  9 10:14:26 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 09 Dec 2006 10:14:26 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gt3uE-0003gO-Ln@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/09 10:14:26

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Temporarily disabled anycast
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.32 +23 -12    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.31
  retrieving revision 1.195.2.32
  diff -u -b -r1.195.2.31 -r1.195.2.32
  --- TreeCache.java	8 Dec 2006 12:35:35 -0000	1.195.2.31
  +++ TreeCache.java	9 Dec 2006 15:14:26 -0000	1.195.2.32
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.31 2006/12/08 12:35:35 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.32 2006/12/09 15:14:26 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1461,6 +1461,8 @@
            cacheLoaderManager.startCacheLoader();
         }
   
  +      boolean startBuddyManager = false;
  +
         switch (cache_mode)
         {
            case LOCAL:
  @@ -1487,16 +1489,7 @@
                     throw e;
                  }
               }
  -            if (buddyManager != null)
  -            {
  -               buddyManager.init(this);
  -               if (use_repl_queue)
  -               {
  -                  log.warn("Replication queue not supported when using buddy replication.  Disabling repliction queue.");
  -                  use_repl_queue = false;
  -                  repl_queue = null;
  -               }
  -            }
  +            startBuddyManager = true;
               break;
            default:
               throw new IllegalArgumentException("cache mode " + cache_mode + " is invalid");
  @@ -1508,10 +1501,23 @@
            cacheLoaderManager.preloadCache();
         }
   
  +
         // Find out if we are coordinator (blocks until view is received)
         // TODO should this be moved above the buddy manager code??
         determineCoordinator();
   
  +      if (buddyManager != null && startBuddyManager)
  +      {
  +         buddyManager.init(this);
  +         if (use_repl_queue)
  +         {
  +            log.warn("Replication queue not supported when using buddy replication.  Disabling repliction queue.");
  +            use_repl_queue = false;
  +            repl_queue = null;
  +         }
  +      }
  +
  +
         notifyCacheStarted();
      }
   
  @@ -4325,7 +4331,11 @@
            log.trace("callRemoteMethods(): valid members are " + validMembers + " method: " + method_call);
   
         // if we are using buddy replication, all calls should use ANYCAST.  Otherwise, use the default (multicast).  Unless anycast is forced
  -      rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
  +
  +      // TODO; Disabling anycast for now.  Fix once this bug is fixed in JGroups.
  +
  +      rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, false);//forceAnycast || buddyManager != null && buddyManager.isEnabled());
  +      //rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
   
         // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
         // JGroups supports http://jira.jboss.com/jira/browse/JGRP-193
  @@ -5066,6 +5076,7 @@
       */
      public Object _replicate(MethodCall method_call) throws Throwable
      {
  +      if (log.isTraceEnabled()) log.trace(getLocalAddress() + " received call " + method_call);
         JBCMethodCall jbcCall = (JBCMethodCall) method_call;
         try
         {
  
  
  


From msurtani at jboss.com  Sat Dec  9 10:14:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 09 Dec 2006 10:14:46 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1Gt3uY-0003gf-B1@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/09 10:14:46

  Modified:    src/org/jboss/cache/buddyreplication  Tag:
                        Branch_JBossCache_1_4_0 BuddyManager.java
  Log:
  Refactored for more correct behaviour
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.33.2.8  +848 -814  JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.33.2.7
  retrieving revision 1.33.2.8
  diff -u -b -r1.33.2.7 -r1.33.2.8
  --- BuddyManager.java	10 Nov 2006 20:30:24 -0000	1.33.2.7
  +++ BuddyManager.java	9 Dec 2006 15:14:46 -0000	1.33.2.8
  @@ -32,10 +32,12 @@
   import java.util.ArrayList;
   import java.util.Arrays;
   import java.util.HashMap;
  +import java.util.HashSet;
   import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
   import java.util.Properties;
  +import java.util.Set;
   import java.util.Vector;
   
   /**
  @@ -72,6 +74,10 @@
        */
       Map buddyPool;
       /**
  +    * The nullBuddyPool is a set of addresses that have not specified buddy pools.
  +    */
  +   Set nullBuddyPool;
  +   /**
        * Name of the buddy pool for current instance.  May be null if buddy pooling is not used.
        */
       String buddyPoolName;
  @@ -86,7 +92,6 @@
        * Needs to deal with concurrent access - concurrent assignTo/removeFrom buddy grp
        */
       Map buddyGroupsIParticipateIn = new ConcurrentReaderHashMap();
  -//    Map buddyGroupsIParticipateIn = new HashMap();
   
       /**
        * Queue to deal with queued up view change requests - which are handled asynchronously
  @@ -119,7 +124,11 @@
        * Flag to prevent us receiving and processing remote calls before we've started
        */
       private boolean initialised = false;
  -//    private Latch initLatch = new Latch();
  +
  +   /**
  +    * Lock to synchronise on to ensure buddy pool info is received before buddies are assigned to groups.
  +    */
  +   private final Object poolInfoNotifierLock = new Object();
   
       public BuddyManager(Element element)
       {
  @@ -138,16 +147,17 @@
           }
           finally
           {
  -            if (log.isDebugEnabled()) log.debug("Using buddy communication timeout of " + buddyCommunicationTimeout + " millis");
  +         if (log.isDebugEnabled())
  +            log.debug("Using buddy communication timeout of " + buddyCommunicationTimeout + " millis");
           }
           buddyPoolName = XmlHelper.readStringContents(element, "buddyPoolName");
           if (buddyPoolName != null && buddyPoolName.equals("")) buddyPoolName = null;
   
           // initialise buddy pool map
  -        if (buddyPoolName != null) buddyPool = new ConcurrentReaderHashMap();
  +      buddyPool = new ConcurrentReaderHashMap();
  +      nullBuddyPool = new HashSet();
   
           // now read the buddy locator details and create accordingly.
  -
           String buddyLocatorClass = null;
           Properties buddyLocatorProperties = null;
           try
  @@ -206,21 +216,23 @@
   
       public void init(TreeCache cache) throws Exception
       {
  -        log.debug("Starting buddy manager");
           this.cache = cache;
  +      final Object localAddress = cache.getLocalAddress();
           buddyGroup = new BuddyGroup();
  -        buddyGroup.setDataOwner((IpAddress) cache.getLocalAddress());
  -        buddyGroup.setGroupName(getGroupNameFromAddress(cache.getLocalAddress()));
  +      buddyGroup.setDataOwner((IpAddress) localAddress);
  +      buddyGroup.setGroupName(getGroupNameFromAddress(localAddress));
  +      log.debug("Starting buddy manager for data owner " + buddyGroup.getDataOwner());
  +
   
           if (buddyPoolName != null)
           {
               buddyPool.put(buddyGroup.getDataOwner(), buddyPoolName);
           }
   
  +      broadcastBuddyPoolMembership();
  +
           // allow waiting threads to process.
           initialised = true;
  -        broadcastBuddyPoolMembership();
  -//        initLatch.release();
   
           // register a TreeCache Listener to reassign buddies as and when view changes occur
   
  @@ -264,19 +276,11 @@
               {
                   Vector newMembers = newView.getMembers();
   
  -                // the whole 'oldMembers' concept is only used for buddy pool announcements.
  -                if (buddyPoolName == null)
  -                {
  -                   enqueueViewChange(null, newMembers);
  -                }
  -                else
  -                {
                       enqueueViewChange(oldMembers == null ? null : new Vector(oldMembers), new Vector(newMembers));
                       if (oldMembers == null) oldMembers = new Vector();
                       oldMembers.clear();
                       oldMembers.addAll(newMembers);
                   }
  -            }
           });
   
           // assign buddies based on what we know now
  @@ -389,9 +393,19 @@
       {
           if (log.isDebugEnabled())
           {
  -            log.debug("Received announcement that cache instance " + address + " is in buddy pool " + poolName);
  +         log.debug(buddyGroup.getDataOwner() + ": received announcement that cache instance " + address + " is in buddy pool " + poolName);
  +      }
  +      if (poolName != null)
  +         buddyPool.put(address, poolName);
  +      else
  +         nullBuddyPool.add(address);
  +
  +      // notify any waiting view change threads that buddy pool info has been received.
  +      synchronized (poolInfoNotifierLock)
  +      {
  +         log.trace("Notifying any waiting view change threads that we have received buddy pool info.");
  +         poolInfoNotifierLock.notifyAll();
           }
  -        if (poolName != null) buddyPool.put(address, poolName);
       }
   
       /**
  @@ -400,7 +414,6 @@
        */
       public void handleRemoveFromBuddyGroup(String groupName) throws BuddyNotInitException
       {
  -        //waitForInit();
          if (!initialised) throw new BuddyNotInitException("Not yet initialised");
           if (log.isInfoEnabled()) log.info("Removing self from buddy group " + groupName);
           buddyGroupsIParticipateIn.remove(groupName);
  @@ -427,6 +440,8 @@
        */
       public void handleAssignToBuddyGroup(BuddyGroup newGroup, Map state) throws Exception
       {
  +      if (log.isTraceEnabled())
  +         log.trace("Handling assign to buddy grp.  Sender: " + newGroup.getGroupName() + "; My instance: " + buddyGroup.getDataOwner());
          // if we haven't initialised, throw an exception.
          if (!initialised) throw new BuddyNotInitException("Not yet initialised");
   
  @@ -442,7 +457,7 @@
              marshaller = cache.getMarshaller();
           }
   
  -        for (Iterator it = state.entrySet().iterator(); it.hasNext(); )
  +      for (Iterator it = state.entrySet().iterator(); it.hasNext();)
           {
              Map.Entry entry = (Map.Entry) it.next();
              Fqn fqn = (Fqn) entry.getKey();
  @@ -510,14 +525,12 @@
       {
           return transformFqns(call, call.getMethodId() != MethodDeclarations.dataGravitationCleanupMethod_id);
       }
  +
       public JBCMethodCall transformFqns(JBCMethodCall call, boolean transformForCurrentCall)
       {
           if (call != null && call.getArgs() != null)
           {
               JBCMethodCall call2 = new JBCMethodCall(call.getMethod(), (Object[]) call.getArgs().clone(), call.getMethodId());
  -//            call2.setId(call.getId());
  -//            call2.setMethod(call.getMethod());
  -//            call2.setArgs((Object[]) call.getArgs().clone());
               handleArgs(call2.getArgs(), transformForCurrentCall);
               return call2;
           }
  @@ -547,7 +560,7 @@
        {
            try
            {
  -            makeRemoteCall(buddies, replicateCall);
  +            makeRemoteCall(buddies, replicateCall, true);
               break;
            }
            catch (Exception e)
  @@ -576,12 +589,6 @@
   
       private void addBuddies(List buddies) throws Exception
       {
  -        // this check is redundant - if buddies is empty this method will not be called. - Manik
  -
  -//       if (buddies.size() == 0)
  -//          return;
  -
  -
           if (log.isInfoEnabled())
           {
               log.info("Assigning new buddies to buddy group [" + buddyGroup.getGroupName() + "].  New buddies are " + buddies);
  @@ -638,7 +645,7 @@
          {
              try
              {
  -              makeRemoteCall(buddies, replicateCall);
  +            makeRemoteCall(buddies, replicateCall, true);
                 break;
              }
              catch (Exception e)
  @@ -663,7 +670,8 @@
          }
   
   
  -        log.trace("addToGroup notification complete");
  +      if (log.isTraceEnabled())
  +         log.trace("addToGroup notification complete (data owner " + buddyGroup.getDataOwner() + ")");
       }
   
       private byte[] acquireState(Fqn fqn) throws Exception
  @@ -746,7 +754,7 @@
   
           try
           {
  -            makeRemoteCall(recipients, replicateCall);
  +         makeRemoteCall(recipients, replicateCall, true);
           }
           catch (Exception e)
           {
  @@ -754,7 +762,7 @@
           }
       }
   
  -    private void makeRemoteCall(List recipients, MethodCall call) throws Exception
  +   private void makeRemoteCall(List recipients, MethodCall call, boolean sync) throws Exception
       {
           // remove non-members from dest list
           if (recipients != null)
  @@ -771,7 +779,7 @@
               }
           }
   
  -        cache.callRemoteMethods(recipients, call, true, true, buddyCommunicationTimeout);
  +      cache.callRemoteMethods(recipients, call, sync, true, buddyCommunicationTimeout);
       }
   
   
  @@ -812,6 +820,7 @@
   
       /**
        * Assumes the backup Fqn if the current instance is the data owner
  +    *
        * @param originalFqn
        * @return backup fqn
        */
  @@ -892,24 +901,49 @@
   
           private void handleEnqueuedViewChange() throws Exception
           {
  -            log.trace("Handling queued view change");
  +         log.trace("Waiting for enqueued view change events");
               List[] members = (List[]) queue.take(); // 2 element array - 0 - oldMembers, 1 - newMembers
   
  +         // make sure new buddies have broadcast their pool memberships.
  +         while (!buddyPoolInfoAvailable(members[1]))
  +         {
  +            synchronized (poolInfoNotifierLock)
  +            {
  +               log.trace("Not received necessary buddy pool info for all new members yet; waiting on poolInfoNotifierLock.");
  +               poolInfoNotifierLock.wait();
  +            }
  +         }
  +
  +         log.trace("Broadcasting pool membership details, triggered by view change.");
  +         if (members[0] == null)
  +            broadcastBuddyPoolMembership();
  +         else
  +         {
  +            List delta = new ArrayList();
  +            delta.addAll(members[1]);
  +            delta.removeAll(members[0]);
  +            broadcastBuddyPoolMembership(delta);
  +         }
  +
               // always refresh buddy list.
               reassignBuddies(members[1]);
  +      }
   
  -            if (buddyPoolName != null)
  +      private boolean buddyPoolInfoAvailable(List newMembers)
               {
  -                log.trace("Broadcasting pool membership details, triggered by view change.");
  -                broadcastBuddyPoolMembership();
  -//                if (members[0] == null)
  -//                    broadcastBuddyPoolMembership();
  -//                else
  -//                {
  -//                    members[1].removeAll(members[0]);
  -//                    broadcastBuddyPoolMembership(members[1]);
  -//                }
  +         boolean infoReceived = true;
  +         Iterator i = newMembers.iterator();
  +         while (i.hasNext())
  +         {
  +            Object address = i.next();
  +            infoReceived = infoReceived && (address.equals(cache.getLocalAddress()) || buddyPool.keySet().contains(address) || nullBuddyPool.contains(address));
               }
  +
  +         log.trace(buddyGroup.getDataOwner() + " received buddy pool info for new members " + newMembers + "?  " + infoReceived);
  +
  +         return infoReceived;
           }
  +
       }
   }
  +
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 10:22:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 10:22:53 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1737 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt42P-0003qj-UU@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 10:22:51 -0500 (Sat, 09 Dec 2006)
New Revision: 1737

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Extended test



Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 15:11:31 UTC (rev 1736)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 15:22:51 UTC (rev 1737)
@@ -190,58 +190,61 @@
    }
  
    /*
-    * Test that the failover mapping is created correctly
+    * Test that the failover mapping is created correctly and updated properly when nodes leave
+    * or join
     */
    public void testDefaultFailoverMap() throws Exception
    {     
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         //The order here depends on the order the servers were started in
+         
+         //If any servers get stopped and then started then the order will change
+    
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         
+         assertEquals(0, cf1.getServerId());
+         
+         assertEquals(1, cf2.getServerId());
+         
+         assertEquals(2, cf3.getServerId());
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(3, delegates.length);
+         
+         assertEquals(3, failoverMap.size());
+         
+         // Default failover policy just chooses the node to the right
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+         
+         assertEquals(2, ((Integer)failoverMap.get(new Integer(1))).intValue());
+      }
       
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      //The order here depends on the order the servers were started in
-      
-      //If any servers get stopped and then started then the order will change
- 
-      log.info("cf1 serverid=" + cf1.getServerId());
-      
-      log.info("cf2 serverid=" + cf2.getServerId());
-      
-      log.info("cf3 serverid=" + cf3.getServerId());
-      
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      Map failoverMap = delegate.getFailoverMap();
-      
-      assertEquals(3, delegates.length);
-      
-      assertEquals(3, failoverMap.size());
-      
-      // Default failover policy just chooses the node to the right
-      
-      assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      
-      assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      
-      assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      
-      assertEquals(2, ((Integer)failoverMap.get(new Integer(1))).intValue());
-      
       //Now cleanly stop one of the servers
       
       
@@ -252,44 +255,46 @@
       
       assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
       
-      //Lookup another connection factory
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         //Order here depends on order servers were started in
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(1, cf1.getServerId());
+         
+         assertEquals(2, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
       
-      JBossConnectionFactory factory2 =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-      
-      log.info("Got connection factory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate2 =
-         (ClusteredClientConnectionFactoryDelegate)factory2.getDelegate();
-      
-      ClientConnectionFactoryDelegate[] delegates2 = delegate2.getDelegates();
-      
-      Map failoverMap2 = delegate2.getFailoverMap();
-      
-      log.info("Got failover map");
-      
-      assertEquals(2, delegates2.length);
-      
-      cf1 = delegate2.getDelegates()[0];
-      
-      cf2 = delegate2.getDelegates()[1];
-      
-      //Order here depends on order servers were started in
-      
-      log.info("cf1 serverid=" + cf1.getServerId());
-      
-      log.info("cf2 serverid=" + cf2.getServerId());
-      
-      assertEquals(1, cf1.getServerId());
-      
-      assertEquals(2, cf2.getServerId());
-      
-      
-      assertEquals(2, failoverMap2.size());
-      
-      assertEquals(cf2.getServerId(), ((Integer)failoverMap2.get(new Integer(cf1.getServerId()))).intValue());
-      
-      assertEquals(cf1.getServerId(), ((Integer)failoverMap2.get(new Integer(cf2.getServerId()))).intValue());
-      
       //Cleanly stop another server
       
       log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
@@ -298,31 +303,123 @@
       
       assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
       
-      //Lookup another connection factory
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(1, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         assertEquals(2, cf1.getServerId());
+         
+         
+         assertEquals(1, failoverMap.size());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+      }
+            
+      //Restart server 0
       
-      JBossConnectionFactory factory3 =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+      ServerManagement.start("all", 0);
       
-      ClusteredClientConnectionFactoryDelegate delegate3 =
-         (ClusteredClientConnectionFactoryDelegate)factory3.getDelegate();
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
       
-      ClientConnectionFactoryDelegate[] delegates3 = delegate3.getDelegates();
       
-      Map failoverMap3 = delegate3.getFailoverMap();
+      //Restart server 1
       
-      assertEquals(1, delegates3.length);
+      ServerManagement.start("all", 1);
       
-      cf1 = delegate3.getDelegates()[0];
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(3, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         assertEquals(1, cf3.getServerId());
+         
+         
+         assertEquals(3, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }            
+   }
+   
+   public void testSimpleFailover() throws Exception
+   {
       
-      assertEquals(2, cf1.getServerId());
-      
-      
-      assertEquals(1, failoverMap3.size());
-      
-      assertEquals(cf1.getServerId(), ((Integer)failoverMap3.get(new Integer(cf1.getServerId()))).intValue());
-            
-      //TODO - Add nodes back into the cluster - test framework currently does not support this
-      
-      
    }
    
    



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 11:15:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 11:15:24 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1738 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory
Message-ID: <E1Gt4rE-0004i2-32@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-09 11:15:23 -0500 (Sat, 09 Dec 2006)
New Revision: 1738

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
Log:
Just adding a simple comment

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-09 15:22:51 UTC (rev 1737)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-09 16:15:23 UTC (rev 1738)
@@ -27,11 +27,9 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
-
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
@@ -415,10 +413,13 @@
          
          recalculateFailoverMap(nodeAddressMap);
       }
-      
-      //Now we find the "mainDelegate"
-      //TODO - why do we need a "mainDelegate" ????
-      
+
+      // The main delegated is needed for the construction of ClusteredClientConnectionFactoryDelegate
+      // ClusteredClientConnectionFactoryDelegate extends ClientConnectionFactoryDelegate and it will
+      // need the current server's delegate properties to be bound to ObjectId, ServerLocator and
+      // other connection properties.
+      //
+      // The ClusteredCFDelegate will copy these properties on its contructor defined bellow after this loop
       ClientConnectionFactoryDelegate mainDelegate = null;
       
       for(Iterator i = localDelegates.values().iterator(); i.hasNext();)



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 12:38:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 12:38:01 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1739 - in
	branches/Branch_1_0/tests/src/org/jboss/test/messaging: . jms
Message-ID: <E1Gt69B-000601-Rt@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-09 12:37:56 -0500 (Sat, 09 Dec 2006)
New Revision: 1739

Modified:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
Log:
Switch back to JBossTS again with better timeout management in tests to see if the QA machine likes it better

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java	2006-12-09 16:15:23 UTC (rev 1738)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java	2006-12-09 17:37:56 UTC (rev 1739)
@@ -39,6 +39,8 @@
  *
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ *
  * @version <tt>$Revision$</tt>
  * $Id$
  */
@@ -46,6 +48,11 @@
 {
    // Constants -----------------------------------------------------
 
+   public final static int MAX_TIMEOUT = 1000 * 60 /* seconds */;
+
+   public final static int MIN_TIMEOUT = 1000 * 5 /* seconds */;
+   
+
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-09 16:15:23 UTC (rev 1738)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-09 17:37:56 UTC (rev 1739)
@@ -21,18 +21,18 @@
   */
 package org.jboss.test.messaging.jms;
 
+import javax.jms.Connection;
 import javax.jms.Destination;
-import javax.jms.TextMessage;
 import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
 import javax.jms.Session;
-import javax.jms.Connection;
-import javax.jms.MessageProducer;
+import javax.jms.TextMessage;
 import javax.jms.XAConnection;
 import javax.jms.XASession;
 import javax.naming.InitialContext;
 import javax.transaction.TransactionManager;
+import javax.transaction.xa.XAResource;
 import javax.transaction.xa.Xid;
-import javax.transaction.xa.XAResource;
 
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.messaging.core.tx.XidImpl;
@@ -40,8 +40,8 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.tm.TransactionManagerLocator;
 
+import com.arjuna.ats.jta.xa.XidImple;
 import com.arjuna.ats.arjuna.common.Uid;
-import com.arjuna.ats.jta.xa.XidImple;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -51,9 +51,6 @@
 {
    // Constants -----------------------------------------------------
 
-   private final static int MAX_TIMEOUT = 1000 * 60 /* seconds */;
-
-
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------
@@ -61,7 +58,7 @@
    protected InitialContext initialContext;
    
    protected JBossConnectionFactory cf;
-   protected Destination queue;
+   protected Destination queue, queueA, queueB, queueTX;
 
    TransactionManager tm;
 
@@ -88,22 +85,36 @@
       
       ServerManagement.undeployQueue("Queue");
       ServerManagement.deployQueue("Queue");
-      queue = (Destination)initialContext.lookup("/queue/Queue"); 
 
+      ServerManagement.undeployQueue("QA");
+      ServerManagement.deployQueue("QA");
+
+      ServerManagement.undeployQueue("QB");
+      ServerManagement.deployQueue("QB");
+
+      ServerManagement.undeployQueue("TXQ");
+      ServerManagement.deployQueue("TXQ");
+
+      queue = (Destination)initialContext.lookup("/queue/Queue");
+      queueA = (Destination)initialContext.lookup("/queue/QA");
+      queueB = (Destination)initialContext.lookup("/queue/QB");
+      queueTX = (Destination)initialContext.lookup("/queue/TXQ");
    }
 
    public void tearDown() throws Exception
    {
       ServerManagement.undeployQueue("Queue");
-      
+      ServerManagement.undeployQueue("QA");
+      ServerManagement.undeployQueue("QB");
+      ServerManagement.undeployQueue("TXQ");
+
       super.tearDown();
    }
 
 
    // Public --------------------------------------------------------
 
-
-   /*
+/*
    public void testJBossTSCoordinator() throws Exception
    {
       UserTransaction ut = com.arjuna.ats.jta.UserTransaction.userTransaction();
@@ -113,7 +124,7 @@
 
       ut.commit();
    }
-   */
+*/
 
 
    public void testTransactionalDeliveryRecovery() throws Exception
@@ -132,14 +143,14 @@
       XAResource res2 = sess2.getXAResource();
 
       //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
-      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+      Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 42, "frigtard".getBytes());
 
       //    Send a message in each tx
 
       res1.start(xid1, XAResource.TMNOFLAGS);
 
-      MessageProducer prod1 = sess1.createProducer(queue);
+      MessageProducer prod1 = sess1.createProducer(queueTX);
 
       TextMessage tm1 = sess1.createTextMessage("tm1");
 
@@ -154,7 +165,7 @@
 
       res2.start(xid2, XAResource.TMNOFLAGS);
 
-      MessageProducer prod2 = sess2.createProducer(queue);
+      MessageProducer prod2 = sess2.createProducer(queueTX);
 
       TextMessage tm3 = sess2.createTextMessage("tm3");
 
@@ -178,7 +189,10 @@
 
       ServerManagement.startServerPeer();
 
+      ServerManagement.deployQueue("TXQ");
 
+
+
       XAResource res = cf.createXAConnection().createXASession().getXAResource();
 
       Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
@@ -194,30 +208,70 @@
 
       res.commit(xid2, false);
 
-      ServerManagement.deployQueue("Queue");
 
       Connection conn3 = cf.createConnection();
 
       Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageConsumer cons = sessRec.createConsumer(queue);
+      MessageConsumer cons = sessRec.createConsumer(queueTX);
       conn3.start();
 
       TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m1);
-      assertEquals("tm1", m1.getText());
 
+      assertTrue(tm1.getText().equals("tm1") ||
+                 tm1.getText().equals("tm2") ||
+                 tm1.getText().equals("tm3") ||
+                 tm1.getText().equals("tm4"));
+
+      //assertEquals("tm1", m1.getText());
+
       TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m2);
 
-      assertEquals("tm2", m2.getText());
+      assertTrue(tm2.getText().equals("tm1") ||
+                 tm2.getText().equals("tm2") ||
+                 tm2.getText().equals("tm3") ||
+                 tm2.getText().equals("tm4"));
+      assertTrue(!tm1.getText().equals(tm2.getText()));
 
-      // TODO
+//      assertEquals("tm2", m2.getText());
 
+      TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
+      assertNotNull(m3);
+
+      assertTrue(tm3.getText().equals("tm1") ||
+                 tm3.getText().equals("tm2") ||
+                 tm3.getText().equals("tm3") ||
+                 tm3.getText().equals("tm4"));
+
+      assertTrue(!tm3.getText().equals(tm2.getText()));
+      assertTrue(!tm3.getText().equals(tm1.getText()));
+
+//      assertEquals("tm3", m3.getText());
+
+      TextMessage m4 = (TextMessage)cons.receive(MAX_TIMEOUT);
+      assertNotNull(m4);
+
+      assertTrue(tm4.getText().equals("tm1") ||
+                 tm4.getText().equals("tm2") ||
+                 tm4.getText().equals("tm3") ||
+                 tm4.getText().equals("tm4"));
+
+      assertTrue(!tm4.getText().equals(tm3.getText()));
+      assertTrue(!tm4.getText().equals(tm2.getText()));
+      assertTrue(!tm4.getText().equals(tm1.getText()));
+
+//      assertEquals("tm4", m4.getText());
+
+      TextMessage nullMessage = (TextMessage)cons.receive(1000);
+
+      assertTrue(nullMessage == null);
+
       conn3.close();
-
    }
 
 
+
    public void testMockCoordinatorRecovery() throws Exception
    {
 
@@ -234,8 +288,8 @@
       XAResource res2 = sess2.getXAResource();
 
       //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
-      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+      Xid xid1 = new XidImpl("bq1".getBytes(), 42, "aapeli".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 42, "belsebub".getBytes());
 
       //    Send a message in each tx
 
@@ -272,7 +326,9 @@
 
       ServerManagement.startServerPeer();
 
+      ServerManagement.deployQueue("Queue");
 
+
       XAResource res = cf.createXAConnection().createXASession().getXAResource();
 
       Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
@@ -288,7 +344,6 @@
 
       res.commit(xid2, false);
 
-      ServerManagement.deployQueue("Queue");
 
       Connection conn3 = cf.createConnection();
 
@@ -325,8 +380,8 @@
       XAResource res2 = sess2.getXAResource();
 
       //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImple(new Uid("gbtxid1"), new Uid("bq1"), 123);
-      Xid xid2 = new XidImple(new Uid("gbtxid2"), new Uid("bq2"), 124);
+      Xid xid1 = new XidImple(new Uid("cadaver"), new Uid("bq1"), 666);
+      Xid xid2 = new XidImple(new Uid("dalidom"), new Uid("bq2"), 661);   // TODO
 
 
       //    Send a message in each tx
@@ -364,7 +419,9 @@
 
       ServerManagement.startServerPeer();
 
+      ServerManagement.deployQueue("Queue");
 
+
       XAResource res = cf.createXAConnection().createXASession().getXAResource();
 
       Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
@@ -381,7 +438,6 @@
 
       res.commit(xid2, false);
 
-      ServerManagement.deployQueue("Queue");
 
       Connection conn3 = cf.createConnection();
 
@@ -402,7 +458,7 @@
 
    }
 
-/*
+
    public void testMockCoordinatorRecovery3() throws Exception
    {
 
@@ -457,6 +513,10 @@
 
       ServerManagement.startServerPeer();
 
+      ServerManagement.deployQueue("Queue");
+
+
+
       XAResource res = cf.createXAConnection().createXASession().getXAResource();
 
       Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
@@ -472,7 +532,6 @@
 
       res.commit(xids[1], false);
 
-      ServerManagement.deployQueue("Queue");
 
       Connection conn3 = cf.createConnection();
 
@@ -492,20 +551,112 @@
       conn3.close();
 
    }
-*/
-   public void testXidEquals()
+
+
+   public void testMultiChannelRecovery() throws Exception
    {
-      Xid xid1 = new XidImple(new Uid("gbtxid1"), new Uid("bq1"), 123);
-      Xid xid2 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
 
-      try
-      {
-         assertEquals(xid1, xid2);
-      }
-      catch (Throwable t)
-      {
-         // different xid impls are not expected to equal
-      }
+      XAConnection conn1 = cf.createXAConnection();
+
+      XAConnection conn2 = cf.createXAConnection();
+
+      XASession sess1 = conn1.createXASession();
+
+      XASession sess2 = conn2.createXASession();
+
+      XAResource res1 = sess1.getXAResource();
+
+      XAResource res2 = sess2.getXAResource();
+
+      //Pretend to be a transaction manager by interacting through the XAResources
+      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+
+      //    Send a message in each tx
+
+      res1.start(xid1, XAResource.TMNOFLAGS);
+
+      MessageProducer prod1 = sess1.createProducer(queueA);
+      MessageProducer prod2 = sess1.createProducer(queueB);
+
+      TextMessage tm1 = sess1.createTextMessage("testing1");
+      TextMessage tm2 = sess1.createTextMessage("testing2");
+
+      prod1.send(tm1);
+      prod2.send(tm2);
+
+      res1.end(xid1, XAResource.TMSUCCESS);
+
+
+      res2.start(xid2, XAResource.TMNOFLAGS);
+
+      MessageProducer prod3 = sess2.createProducer(queue);
+
+      TextMessage tm3 = sess2.createTextMessage("testing3");
+
+      prod3.send(tm3);
+
+      res2.end(xid2, XAResource.TMSUCCESS);
+
+      //prepare both txs
+
+
+      res1.prepare(xid1);
+      res2.prepare(xid2);
+
+      //Now "crash" the server
+
+      ServerManagement.stopServerPeer();
+
+      ServerManagement.startServerPeer();
+
+      ServerManagement.deployQueue("Queue");
+      ServerManagement.deployQueue("QA");
+      ServerManagement.deployQueue("QB");
+
+
+
+      XAResource res = cf.createXAConnection().createXASession().getXAResource();
+
+      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+      assertEquals(2, xids.length);
+
+      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+      assertEquals(0, xids2.length);
+
+      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+
+      res.commit(xids[0], false);
+
+      res.commit(xids[1], false);
+
+
+      Connection conn3 = cf.createConnection();
+
+      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+      MessageConsumer cons1 = sessRec.createConsumer(queueA);
+      MessageConsumer cons2 = sessRec.createConsumer(queueB);
+      MessageConsumer cons3 = sessRec.createConsumer(queue);
+
+      conn3.start();
+
+      TextMessage m1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+      assertNotNull(m1);
+      assertEquals("testing1", m1.getText());
+
+      TextMessage m2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+      assertNotNull(m2);
+      assertEquals("testing2", m2.getText());
+
+      TextMessage m3 = (TextMessage)cons3.receive(MAX_TIMEOUT);
+      assertNotNull(m3);
+      assertEquals("testing3", m3.getText());
+
+      conn3.close();
+
    }
+
 }
 

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-09 16:15:23 UTC (rev 1738)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-09 17:37:56 UTC (rev 1739)
@@ -41,9 +41,9 @@
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.tx.MessagingXAResource;
 import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.util.TransactionManagerLocator;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.tm.TxUtils;
-import org.jboss.tm.TransactionManagerLocator;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -234,10 +234,10 @@
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
       }
@@ -292,7 +292,7 @@
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
 
       }
@@ -360,7 +360,7 @@
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
 
       }
@@ -414,7 +414,7 @@
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
 
       }
@@ -468,12 +468,12 @@
          MessageConsumer cons = sess.createConsumer(queue);
 
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
 
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
@@ -486,7 +486,7 @@
          tx.enlistResource(res);
          tx.enlistResource(res2);
 
-         Message m3 = cons.receive(1000);
+         Message m3 = cons.receive(MIN_TIMEOUT);
 
          assertNull(m3);
 
@@ -544,12 +544,12 @@
          MessageConsumer cons = sess.createConsumer(queue);
 
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
 
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
@@ -562,7 +562,7 @@
          tx.enlistResource(res);
          tx.enlistResource(res2);
 
-         Message m3 = cons.receive(1000);
+         Message m3 = cons.receive(MIN_TIMEOUT);
 
          assertNull(m3);
 
@@ -622,10 +622,10 @@
          MessageConsumer cons = sess.createConsumer(queue);
 
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
@@ -639,10 +639,10 @@
          tx.enlistResource(res);
          tx.enlistResource(res2);
 
-         TextMessage m3 = (TextMessage)cons.receive(1000);
+         TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         m3 = (TextMessage)cons.receive(1000);
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
 
@@ -702,10 +702,10 @@
          MessageConsumer cons = sess.createConsumer(queue);
 
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
 
@@ -719,10 +719,10 @@
          tx.enlistResource(res);
          tx.enlistResource(res2);
 
-         TextMessage m3 = (TextMessage)cons.receive(1000);
+         TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         m3 = (TextMessage)cons.receive(1000);
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
 
@@ -781,10 +781,10 @@
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
       }
@@ -834,7 +834,7 @@
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
 
       }
@@ -883,11 +883,11 @@
          MessageConsumer cons = sess.createConsumer(queue);
 
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
@@ -899,7 +899,7 @@
          tx = tm.getTransaction();
          tx.enlistResource(res);
 
-         Message m3 = cons.receive(1000);
+         Message m3 = cons.receive(MIN_TIMEOUT);
 
          assertNull(m3);
 
@@ -953,12 +953,12 @@
          MessageConsumer cons = sess.createConsumer(queue);
 
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
 
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
@@ -972,12 +972,12 @@
          tx = tm.getTransaction();
          tx.enlistResource(res);
 
-         TextMessage m3 = (TextMessage)cons.receive(1000);
+         TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
 
-         m3 = (TextMessage)cons.receive(1000);
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
@@ -1039,7 +1039,7 @@
 
          //Receive the messages, one on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
@@ -1047,7 +1047,7 @@
          cons1.close();
 
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
 
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
@@ -1059,7 +1059,7 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
 
 
@@ -1117,7 +1117,7 @@
 
          //Receive the messages, one on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
@@ -1125,7 +1125,7 @@
          cons1.close();
 
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
 
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
@@ -1137,7 +1137,7 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
 
       }
@@ -1198,12 +1198,12 @@
 
          //Receive the messages, two on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
 
-         r1 = (TextMessage)cons1.receive(1000);
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
@@ -1211,12 +1211,12 @@
          cons1.close();
 
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
 
          assertNotNull(r2);
          assertEquals("jellyfish3", r2.getText());
 
-         r2 = (TextMessage)cons2.receive(1000);
+         r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
 
          assertNotNull(r2);
          assertEquals("jellyfish4", r2.getText());
@@ -1231,19 +1231,19 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
 
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish2", r3.getText());
 
-         TextMessage r4 = (TextMessage)cons.receive(1000);
+         TextMessage r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r4);
          assertEquals("jellyfish3", r4.getText());
 
-         r4 = (TextMessage)cons.receive(1000);
+         r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r4);
          assertEquals("jellyfish4", r4.getText());
 
@@ -1305,12 +1305,12 @@
 
          //Receive the messages, two on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
 
-         r1 = (TextMessage)cons1.receive(1000);
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
@@ -1318,12 +1318,12 @@
          cons1.close();
 
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
 
          assertNotNull(r2);
          assertEquals("jellyfish3", r2.getText());
 
-         r2 = (TextMessage)cons2.receive(1000);
+         r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
 
          assertNotNull(r2);
          assertEquals("jellyfish4", r2.getText());
@@ -1344,19 +1344,19 @@
          //or res2 determines the order the messages are put back in the queue
          //This test assumes it is called in order res1, res2
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish3", r3.getText());
 
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish4", r3.getText());
 
-         TextMessage r4 = (TextMessage)cons.receive(1000);
+         TextMessage r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r4);
          assertEquals("jellyfish1", r4.getText());
 
-         r4 = (TextMessage)cons.receive(1000);
+         r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r4);
          assertEquals("jellyfish2", r4.getText());
 
@@ -1414,22 +1414,22 @@
          tx.enlistResource(res2);
 
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
 
-         r1 = (TextMessage)cons1.receive(1000);
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
 
-         r1 = (TextMessage)cons1.receive(1000);
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish3", r1.getText());
 
-         r1 = (TextMessage)cons1.receive(1000);
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
 
          assertNotNull(r1);
          assertEquals("jellyfish4", r1.getText());
@@ -1454,19 +1454,19 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
 
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish2", r3.getText());
 
-         TextMessage r4 = (TextMessage)cons.receive(1000);
+         TextMessage r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r4);
          assertEquals("jellyfish3", r4.getText());
 
-         r4 = (TextMessage)cons.receive(1000);
+         r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r4);
          assertEquals("jellyfish4", r4.getText());
 
@@ -1532,11 +1532,11 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("echidna1", r1.getText());
 
-         TextMessage r2 = (TextMessage)cons.receive(1000);
+         TextMessage r2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("echidna2", r2.getText());
 
@@ -1604,11 +1604,11 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("echidna1", r1.getText());
 
-         TextMessage r2 = (TextMessage)cons.receive(1000);
+         TextMessage r2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("echidna2", r2.getText());
 
@@ -1675,7 +1675,7 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r1);
 
 
@@ -1741,7 +1741,7 @@
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r1);
 
 
@@ -1797,7 +1797,7 @@
 
          //Receive one message in one tx
 
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
 
@@ -1810,7 +1810,7 @@
          tx2.enlistResource(res1);
 
          //Receive 2nd message in a different tx
-         TextMessage r2 = (TextMessage)cons1.receive(1000);
+         TextMessage r2 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
 
@@ -1822,7 +1822,7 @@
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
 
          //now resume the first tx and then commit it
@@ -1882,7 +1882,7 @@
 
          //Receive one message in one tx
 
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
 
@@ -1895,7 +1895,7 @@
          tx2.enlistResource(res1);
 
          //Receive 2nd message in a different tx
-         TextMessage r2 = (TextMessage)cons1.receive(1000);
+         TextMessage r2 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
 
@@ -1910,11 +1910,11 @@
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(r3);
          assertEquals("jellyfish2", r3.getText());
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
 
 
@@ -1923,10 +1923,10 @@
          tm.rollback();
 
          //Verify the first message is now available
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
 
       }
@@ -1993,10 +1993,10 @@
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("kangaroo2", r1.getText());
-         TextMessage r2 = (TextMessage)cons.receive(1000);
+         TextMessage r2 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r2);
 
          //now resume the first tx and then commit it
@@ -2004,7 +2004,7 @@
          tm.commit();
 
          //verify that the first text message is received
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("kangaroo1", r3.getText());
 
@@ -2072,7 +2072,7 @@
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MIN_TIMEOUT);
 
          assertNull(r1);
 
@@ -2082,7 +2082,7 @@
          tm.commit();
 
          //verify that the first text message is received
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("kangaroo1", r3.getText());
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:17:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:17:17 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1740 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt6lB-0006j9-LP@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 13:17:15 -0500 (Sat, 09 Dec 2006)
New Revision: 1740

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
Log:
More test tweaks


Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 17:37:56 UTC (rev 1739)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 18:17:15 UTC (rev 1740)
@@ -26,10 +26,13 @@
 
 import javax.jms.Connection;
 import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
 import javax.jms.TextMessage;
 
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
@@ -241,8 +244,6 @@
          assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
          
          assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-         
-         assertEquals(2, ((Integer)failoverMap.get(new Integer(1))).intValue());
       }
       
       //Now cleanly stop one of the servers
@@ -419,7 +420,124 @@
    
    public void testSimpleFailover() throws Exception
    {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
       
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      int server0Id = cf1.getServerId();
+      
+      int server1Id = cf2.getServerId();
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      int server0FailoverId = ((Integer)failoverMap.get(new Integer(server0Id))).intValue();
+      
+      // server 0 should failover onto server 1
+      
+      assertEquals(server1Id, server0FailoverId);
+      
+      Connection conn = null;
+      
+      try
+      {
+      
+         //Send a message into a queue on server 0
+         
+         conn = factory.createConnection();
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(0, initialServerID);
+         
+         
+         
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess.createProducer(queue0);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         //So now, messages should be in queue0 on server 0
+         //So we now kill server 0
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 0");
+         
+         ServerManagement.getServer(0).destroy();
+         
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(3000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 1
+         
+         assertEquals(1, finalServerID);
+         
+         log.info("here 2");
+         
+         //I should now be able to create a consumer on the same connection and consume the messages
+         
+         MessageConsumer cons = sess.createConsumer(queue0);
+         
+         conn.start();
+         
+         log.info("here 3");
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(1000);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         log.info("here 4");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+      }
+      
    }
    
    

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-09 17:37:56 UTC (rev 1739)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-09 18:17:15 UTC (rev 1740)
@@ -100,6 +100,11 @@
       ServerManagement.start("all", 0);
 
    }
+   
+   public void testKill() throws Exception
+   {
+      ServerManagement.getServer(0).destroy();
+   }
 
 
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:46:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:46:51 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1741 -
	branches/Branch_1_0/src/main/org/jboss/messaging/core/tx
Message-ID: <E1Gt7Dn-00076H-Pa@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-09 13:46:50 -0500 (Sat, 09 Dec 2006)
New Revision: 1741

Modified:
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
Log:
Rewrite of the patch JBMESSAGING-407. Unhandled messages should now be correctly handled wrt the ongoing transaction and underlying channels. Methods getRefs and getChannel from the original patch removed.

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-09 18:17:15 UTC (rev 1740)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-09 18:46:50 UTC (rev 1741)
@@ -28,7 +28,6 @@
 import javax.transaction.xa.Xid;
 
 import org.jboss.jms.destination.JBossDestination;
-import org.jboss.jms.server.plugin.JDBCChannelMapper;
 import org.jboss.jms.server.plugin.contract.ChannelMapper;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -97,7 +96,13 @@
    {
    }
 
-	public List getPreparedTransactions()
+   /**
+    * Attempts to recover existing prepared transactions by redelivering unhandled messages and acknowledgements
+    * on the appropriate channels.
+    *
+    * @return  List of Xid instances
+    */
+	public List recoverPreparedTransactions()
    {
 		ArrayList prepared = new ArrayList();
 
@@ -111,15 +116,14 @@
          {
             try
             {
-               if(trace)
-                  log.trace("Loading and handling refs and acks to the Tx "+tx);
+               if(trace) log.trace("Loading and handling refs and acks to the Tx "+tx);
 
-               handleReferences(tx, tx.getId());
-               handleAcks(tx, tx.getId());
+               handleReferences(tx);
+               handleAcks(tx);
             }
             catch (Exception e)
             {
-               log.debug("Exception in replaying a prepared transaction.", e);
+               log.warn("Failed to replay transaction (XID: " + tx.getXid() + ", LocalID: " + tx.getId() + ") during recovery.", e);
             }
 
 				prepared.add(tx.getXid());
@@ -135,30 +139,24 @@
 	 */
 	public void loadPreparedTransactions() throws Exception
    {
+      if (trace) log.trace("load prepared transactions...");
+
 		List prepared = null;
 
 		prepared = persistenceManager.retrievePreparedTransactions();
 
+      if (trace) log.trace ("Found " + prepared.size() + " transactions in prepared state:");
+
 		if (prepared != null) {
 			Iterator iter = prepared.iterator();
 
 			while (iter.hasNext()) {
 				PreparedTxInfo txInfo = (PreparedTxInfo) iter.next();
 
+            if (trace) log.trace("Reinstating TX(XID: " + txInfo.getXid() + ", LocalId " + txInfo.getTxId() +")");
+            
 				Transaction tx = createTransaction(txInfo);
 				tx.state = Transaction.STATE_PREPARED;
-
-				// // we have to associate a callback to the prepared
-				// transaction
-				// // --MK
-				persistenceManager.associateTxCallbackToPreparedTx(tx);
-				// log.info(">>>ASSOCIATING THE MEMCALLBACK <<<");
-
-            // TODO: [JPL] needs to be completed.
-
-            // associateInMemoryCallbackToPreparedTx(tx);
-				// Load the references for this transaction
-
 			}
 		}
 	}
@@ -236,42 +234,55 @@
 	/**
 	 * Load the references and invoke the channel to handle those refs
 	 */
-	private void handleReferences(Transaction tx, long txId) throws Exception {
+	private void handleReferences(Transaction tx) throws Exception {
 
-		long messageId = persistenceManager.getMessageIdForRef(txId);
+      if (trace) log.trace("Handle references for TX(XID: " + tx.getXid() + ", LocalID: " + tx.getId()+ "):");
 
-		List refsList = getRefs(messageId);
+      long txId = tx.getId();
 
-		// now we got all the refs
-		// for each ref loaded, we'll invoke channel.handle
-		for (Iterator iter = refsList.iterator(); iter.hasNext();)
-		{
-			CoreDestination d = getChannel(persistenceManager.getChannelId(txId), txId);
+		Map messageChannelPair = persistenceManager.getMessageChannelPairForTx(txId);
 
-         if (trace)
-			   log.trace("Handling the channel");
+      if (trace) log.trace("Found " + messageChannelPair.size() + " unhandled messages.");
 
-         d.handle(null, (MessageReference) iter.next(), tx);
+      for (Iterator iter = messageChannelPair.keySet().iterator(); iter.hasNext();)
+      {
+         Message msg = (Message)iter.next();
+         MessageReference ref = messageStore.reference(msg);
+
+         long channelID = ((Long)messageChannelPair.get(msg)).longValue();
+
+         ChannelMapper mapper = persistenceManager.getChannels();
+         JBossDestination destn = mapper.getJBossDestination(channelID);
+
+         CoreDestination d = mapper.getCoreDestination(destn);
+
+         if (trace) log.trace("Destination for message[ID=" + ref.getMessageID() + "] is: " + d);
+
+         d.handle(null, ref, tx);
 		}
 	}
 
 	/**
 	 * Load the acks and acknowledge them
 	 */
-	private void handleAcks(Transaction tx, long txId) throws Exception {
+	private void handleAcks(Transaction tx) throws Exception {
 
-		long messageId = persistenceManager.getMessageIdForAck(txId);
+      long txId = tx.getId();
 
-		List refsList = getRefs(messageId);
+		List messages = persistenceManager.getAcksForTx(txId);
 
-		for (Iterator iter = refsList.iterator(); iter.hasNext();)
-		{
-			Delivery del = new SimpleDelivery(null, (MessageReference) iter.next());
+      if (trace) log.trace("Found " + messages.size() + " unhandled acks.");
 
+      for (Iterator iter = messages.iterator(); iter.hasNext();)
+      {
+         Message msg = (Message)iter.next();
+         MessageReference ref = messageStore.reference(msg);
+
+			Delivery del = new SimpleDelivery(null, ref);
+
 			try
          {
-				if(trace)
-					log.trace("Acknowledging..");
+				if(trace) log.trace("Acknowledging..");
 
 				((DeliveryObserver)del).acknowledge(del, tx);
 			}
@@ -282,62 +293,8 @@
 		}
 	}
 
-	/**
-	 * Get the message references based on the messageId from database
-	 */
-	private List getRefs(long messageId) throws Exception
-	{
-		List noRefsList = new ArrayList();
-		List refsList = new ArrayList();
 
-		// and message reference from store
-		MessageReference ref = messageStore.reference(messageId);
-
-		// Store, sometime, does'nt know about the message referece
-		// and the above ref may be null. Hence we need to load actual message
-		// by goind back to the database and loading them based on id
-
-		if (ref == null)
-		{
-			noRefsList.add(new Long(messageId));
-		}
-		else
-		{
-			refsList.add(ref);
-		}
-
-		// ask the pm to get the messages from messageId list
-		List messagesList = persistenceManager.getMessages(noRefsList);
-
-		for (Iterator iter = messagesList.iterator(); iter.hasNext();)
-		{
-			Message m = (Message) iter.next();
-			MessageReference r = messageStore.reference(m);
-			refsList.add(r);
-		}
-
-		return refsList;
-	}
-
 	/**
-	 * This method returns a core destination representation based on
-	 * the channel id and transaction id
-	 */
-	private CoreDestination getChannel(long channelId, long txId)
-			throws Exception {
-
-		// first get the reference to the channel mapper
-		ChannelMapper mapper = persistenceManager.getChannelMapperReference();
-
-		// find out the destination from channelId
-		JBossDestination destn = ((JDBCChannelMapper)mapper).getJBossDestination(channelId);
-
-		// get the core destination from jbossdestination
-		return mapper.getCoreDestination(destn);
-
-	}
-
-	/**
 	 * Creates a prepared transaction
 	 *
 	 * @param txInfo



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:48:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:48:55 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1742 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt7Fn-00076c-Os@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 13:48:50 -0500 (Sat, 09 Dec 2006)
New Revision: 1742

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Put connection listener back in



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 18:46:50 UTC (rev 1741)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 18:48:50 UTC (rev 1742)
@@ -173,7 +173,7 @@
       
       ConnectionState state = (ConnectionState)((DelegateSupport)connDelegate).getState();
       
-      //state.getRemotingConnection().getInvokingClient().addConnectionListener(new Listener(connDelegate));
+      state.getRemotingConnection().getInvokingClient().addConnectionListener(new Listener(connDelegate));
       
       return connDelegate;   
    }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 18:46:50 UTC (rev 1741)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 18:48:50 UTC (rev 1742)
@@ -74,349 +74,349 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-   public void testRoundRobinConnectionCreation() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      log.info ("number of delegates = " + delegate.getDelegates().length);
-      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      assertEquals(3, delegate.getDelegates().length);
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-      
-      Connection conn4 = null;
-      
-      Connection conn5 = null;
-      
-      try
-      {         
-         conn1 = factory.createConnection();
-         
-         conn2 = factory.createConnection();
-         
-         conn3 = factory.createConnection();
-         
-         conn4 = factory.createConnection();
-         
-         conn5 = factory.createConnection();
-         
-         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
-         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
-         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
-         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
-         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
-         int serverID1 = state1.getServerID();
-         
-         int serverID2 = state2.getServerID();
-         
-         int serverID3 = state3.getServerID();
-         
-         int serverID4 = state4.getServerID();
-         
-         int serverID5 = state5.getServerID();
-         
-         log.info("server id 1: " + serverID1);
-         
-         log.info("server id 2: " + serverID2);
-         
-         log.info("server id 3: " + serverID3);
-         
-         log.info("server id 4: " + serverID4);
-         
-         log.info("server id 5: " + serverID5);
-         
-         assertEquals(0, serverID1);
-         
-         assertEquals(1, serverID2);
-         
-         assertEquals(2, serverID3);
-         
-         assertEquals(0, serverID4);
-         
-         assertEquals(1, serverID5);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-         
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-         
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-         
-         if (conn4 != null)
-         {
-            conn4.close();
-         }
-         
-         if (conn5 != null)
-         {
-            conn5.close();
-         }
-      }
-      
-   }
- 
-   /*
-    * Test that the failover mapping is created correctly and updated properly when nodes leave
-    * or join
-    */
-   public void testDefaultFailoverMap() throws Exception
-   {     
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         //The order here depends on the order the servers were started in
-         
-         //If any servers get stopped and then started then the order will change
-    
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         
-         assertEquals(0, cf1.getServerId());
-         
-         assertEquals(1, cf2.getServerId());
-         
-         assertEquals(2, cf3.getServerId());
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(3, delegates.length);
-         
-         assertEquals(3, failoverMap.size());
-         
-         // Default failover policy just chooses the node to the right
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }
-      
-      //Now cleanly stop one of the servers
-      
-      
-      log.info("************** STOPPING SERVER 0");
-      ServerManagement.stop(0, true);
-      
-      log.info("server stopped");
-      
-      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         //Order here depends on order servers were started in
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(1, cf1.getServerId());
-         
-         assertEquals(2, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      //Cleanly stop another server
-      
-      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
-      ServerManagement.stop(1, true);
-      
-      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(1, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         assertEquals(2, cf1.getServerId());
-         
-         
-         assertEquals(1, failoverMap.size());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      }
-            
-      //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      
-      //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(3, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         assertEquals(1, cf3.getServerId());
-         
-         
-         assertEquals(3, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }            
-   }
+//   public void testRoundRobinConnectionCreation() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//      
+//      log.info ("number of delegates = " + delegate.getDelegates().length);
+//      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//      
+//      assertEquals(3, delegate.getDelegates().length);
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//      
+//      assertEquals(0, cf1.getServerId());
+//      
+//      assertEquals(1, cf2.getServerId());
+//      
+//      assertEquals(2, cf3.getServerId());
+//      
+//      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//      
+//      Connection conn1 = null;
+//      
+//      Connection conn2 = null;
+//      
+//      Connection conn3 = null;
+//      
+//      Connection conn4 = null;
+//      
+//      Connection conn5 = null;
+//      
+//      try
+//      {         
+//         conn1 = factory.createConnection();
+//         
+//         conn2 = factory.createConnection();
+//         
+//         conn3 = factory.createConnection();
+//         
+//         conn4 = factory.createConnection();
+//         
+//         conn5 = factory.createConnection();
+//         
+//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+//         
+//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+//         
+//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+//         
+//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+//         
+//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+//         
+//         int serverID1 = state1.getServerID();
+//         
+//         int serverID2 = state2.getServerID();
+//         
+//         int serverID3 = state3.getServerID();
+//         
+//         int serverID4 = state4.getServerID();
+//         
+//         int serverID5 = state5.getServerID();
+//         
+//         log.info("server id 1: " + serverID1);
+//         
+//         log.info("server id 2: " + serverID2);
+//         
+//         log.info("server id 3: " + serverID3);
+//         
+//         log.info("server id 4: " + serverID4);
+//         
+//         log.info("server id 5: " + serverID5);
+//         
+//         assertEquals(0, serverID1);
+//         
+//         assertEquals(1, serverID2);
+//         
+//         assertEquals(2, serverID3);
+//         
+//         assertEquals(0, serverID4);
+//         
+//         assertEquals(1, serverID5);
+//      }
+//      finally
+//      {
+//         if (conn1 != null)
+//         {
+//            conn1.close();
+//         }
+//         
+//         if (conn2 != null)
+//         {
+//            conn2.close();
+//         }
+//         
+//         if (conn3 != null)
+//         {
+//            conn3.close();
+//         }
+//         
+//         if (conn4 != null)
+//         {
+//            conn4.close();
+//         }
+//         
+//         if (conn5 != null)
+//         {
+//            conn5.close();
+//         }
+//      }
+//      
+//   }
+// 
+//   /*
+//    * Test that the failover mapping is created correctly and updated properly when nodes leave
+//    * or join
+//    */
+//   public void testDefaultFailoverMap() throws Exception
+//   {     
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         //The order here depends on the order the servers were started in
+//         
+//         //If any servers get stopped and then started then the order will change
+//    
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         
+//         assertEquals(0, cf1.getServerId());
+//         
+//         assertEquals(1, cf2.getServerId());
+//         
+//         assertEquals(2, cf3.getServerId());
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         // Default failover policy just chooses the node to the right
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }
+//      
+//      //Now cleanly stop one of the servers
+//      
+//      
+//      log.info("************** STOPPING SERVER 0");
+//      ServerManagement.stop(0, true);
+//      
+//      log.info("server stopped");
+//      
+//      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         //Order here depends on order servers were started in
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(1, cf1.getServerId());
+//         
+//         assertEquals(2, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      //Cleanly stop another server
+//      
+//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+//      
+//      ServerManagement.stop(1, true);
+//      
+//      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(1, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         
+//         assertEquals(1, failoverMap.size());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//      }
+//            
+//      //Restart server 0
+//      
+//      ServerManagement.start("all", 0);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      
+//      //Restart server 1
+//      
+//      ServerManagement.start("all", 1);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         assertEquals(1, cf3.getServerId());
+//         
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }            
+//   }
    
    public void testSimpleFailover() throws Exception
    {



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:50:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:50:12 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1743 -
	branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract
Message-ID: <E1Gt7H2-000788-LT@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-09 13:50:10 -0500 (Sat, 09 Dec 2006)
New Revision: 1743

Modified:
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
Log:
Rewrite of patch JBMESSAGING-407. Simplifying requirements to PersistenceManager interface and removing unneeded methods.

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-09 18:48:50 UTC (rev 1742)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-09 18:50:10 UTC (rev 1743)
@@ -22,6 +22,7 @@
 package org.jboss.messaging.core.plugin.contract;
 
 import java.util.List;
+import java.util.Map;
 
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.tx.Transaction;
@@ -33,6 +34,7 @@
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  *
  * @version <tt>1.1</tt>
  *
@@ -42,16 +44,12 @@
 {
    List retrievePreparedTransactions() throws Exception;
 
-   ChannelMapper getChannelMapperReference();
+   ChannelMapper getChannels();
 
-   long getMessageIdForRef(long transactionId) throws Exception;
+   Map getMessageChannelPairForTx(long transactionId) throws Exception;
 
-   long getMessageIdForAck(long transactionId) throws Exception;
+   List getAcksForTx(long transactionId) throws Exception;
 
-   long getChannelId(long transactionId) throws Exception;
-
-	void associateTxCallbackToPreparedTx(Transaction tx);
-
    void resetLoadedStatus(long channelID) throws Exception;
       
    void addReference(long channelID, MessageReference ref, Transaction tx) throws Exception;
@@ -125,5 +123,4 @@
          return reliable;
       }
    }
-   
 }



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:53:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:53:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1744 -
	branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin
Message-ID: <E1Gt7Kg-0007B3-40@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-09 13:53:48 -0500 (Sat, 09 Dec 2006)
New Revision: 1744

Modified:
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
Log:
Rewrite of patch JBMESSAGING-407. Simplifying requirements to PersistenceManager interface and removing unneeded methods.

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-09 18:50:10 UTC (rev 1743)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-09 18:53:48 UTC (rev 1744)
@@ -214,15 +214,16 @@
    protected String selectAllChannels = "SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE";
    
    //RECOVERY --MK
-   protected String selectMessageIdForRef = "SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE "
+   protected String selectMessageIdForRef = "SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE "
 	      + "WHERE TRANSACTIONID = ? AND STATE = '+' ";
 
-   protected String selectMessageIdForAck = "SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE "
+   protected String selectMessageIdForAck = "SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE "
 	      + "WHERE TRANSACTIONID = ? AND STATE = '-' ";
 
-   protected String selectChannelId = "SELECT CHANNELLID FROM JMS_MESSAGE_REFERENCE "
-	      + "WHERE TRANSACTIONID = ?";
 
+
+
+
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------
@@ -252,7 +253,8 @@
    protected int minOrdering;
    
    protected Map channelMultipliers;
-   
+
+
    // Constructors --------------------------------------------------
    
    public JDBCPersistenceManager() throws Exception
@@ -283,6 +285,7 @@
       channelMultipliers = new ConcurrentReaderHashMap();
    }
 
+
    // ServiceMBeanSupport overrides ---------------------------------
    
    protected void startService() throws Exception
@@ -347,7 +350,8 @@
    {
       log.debug(this + " stopped");
    }
-   
+
+
    // PersistenceManager implementation -------------------------
    
    public Object getInstance()
@@ -605,117 +609,21 @@
       }
    }
    
-   public ChannelMapper getChannelMapperReference()
+   public ChannelMapper getChannels()
    {
 	   return cm;
    }
 
-   public long getMessageIdForRef(long transactionId) throws Exception
+   public Map getMessageChannelPairForTx(long transactionId) throws Exception
    {
-	   return getId(selectMessageIdForRef, transactionId, 1);
+	   return getMessageChannelPair(selectMessageIdForRef, transactionId);
    }
-   public long getMessageIdForAck(long transactionId) throws Exception
+   public List getAcksForTx(long transactionId) throws Exception
    {
-	   return getId(selectMessageIdForAck, transactionId, 1);
+	   return new ArrayList(getMessageChannelPair(selectMessageIdForAck, transactionId).keySet());
    }
 
-   public long getChannelId(long transactionId) throws Exception
-   {
-	   return getId(selectChannelId, transactionId, 1);
-   }
 
-
-   /**
-    * This method associates a TransactionCallback to the
-    * resurrected transaction. This method is called from
-    * the TransactionRepository once a transaction object
-    * is resurrected.
-    */
-   public void associateTxCallbackToPreparedTx(Transaction tx)
-   {
-	  TransactionCallback callback = (TransactionCallback) tx.getKeyedCallback(this);
-
-      if (callback == null)
-      {
-         callback = new TransactionCallback(tx);
-
-         tx.addKeyedCallback(callback, this);
-      }
-   }
-
-   /**
-    * MK
-    * Load the message refs for the corresponding tx id
-    */
-   public long getId(String sqlQuery, long transactionId, int index) throws Exception
-   {
-      if (trace) { log.trace("loading references for tx [" + transactionId + "]"); }
-
-      Connection conn = null;
-      PreparedStatement ps = null;
-      ResultSet rs = null;
-      TransactionWrapper wrap = new TransactionWrapper();
-      long messageId = 0;
-
-      try
-      {
-         conn = ds.getConnection();
-
-         ps = conn.prepareStatement(sqlQuery);
-
-         ps.setLong(1, transactionId);
-
-         rs = ps.executeQuery();
-
-         while(rs.next())
-         {
-        	   messageId = rs.getLong(index);
-         }
-
-         return messageId;
-      }
-      catch (Exception e)
-      {
-         wrap.exceptionOccurred();
-         throw e;
-      }
-      finally
-      {
-         if (rs != null)
-         {
-            try
-            {
-               rs.close();
-            }
-            catch (Throwable e)
-            {
-            }
-         }
-         if (ps != null)
-         {
-            try
-            {
-               ps.close();
-            }
-            catch (Throwable e)
-            {
-            }
-         }
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Throwable e)
-            {
-            }
-         }
-         wrap.end();
-      }
-   }
-
-
    /*
     * Retrieve a List of messages corresponding to the specified List of message ids.
     * The implementation here for HSQLDB does this by using a PreparedStatment with an IN clause
@@ -2602,9 +2510,12 @@
       selectAllChannels = sqlProperties.getProperty("SELECT_ALL_CHANNELS", selectAllChannels);
 
       //recovery
-      selectMessageIdForRef = sqlProperties.getProperty("SELECT_MESSAGEID_FOR_REFS",selectMessageIdForRef);
-      selectMessageIdForAck = sqlProperties.getProperty("SELECT_MESSAGEID_FOR_ACKS",selectMessageIdForAck);
-      selectChannelId  = sqlProperties.getProperty("SELECT_CHANNEL_ID",selectChannelId );
+
+      // TODO: add props to config files [JPL]
+      selectMessageIdForRef = sqlProperties.getProperty("SELECT_MESSAGEID_FOR_REFS", selectMessageIdForRef);
+      selectMessageIdForAck = sqlProperties.getProperty("SELECT_MESSAGEID_FOR_ACKS", selectMessageIdForAck);
+
+
    }
    
    protected TransactionCallback getCallback(Transaction tx)
@@ -4570,7 +4481,94 @@
 
       return tm;
    }
-   
+
+
+   private Map getMessageChannelPair(String sqlQuery, long transactionId) throws Exception
+   {
+      if (trace) log.trace("loading message and channel ids for tx [" + transactionId + "]");
+
+      Connection conn = null;
+      PreparedStatement ps = null;
+      ResultSet rs = null;
+      TransactionWrapper wrap = new TransactionWrapper();
+
+      try
+      {
+         conn = ds.getConnection();
+
+         ps = conn.prepareStatement(sqlQuery);
+
+         ps.setLong(1, transactionId);
+
+         rs = ps.executeQuery();
+
+         Map messageChannelPair = new HashMap();
+
+
+         while(rs.next())
+         {
+        	   long messageId = rs.getLong(1);
+            long channelId = rs.getLong(2);
+
+            messageChannelPair.put(new Long(messageId), new Long(channelId));
+
+            if (trace) log.trace("Loaded MsgID: " + messageId + " and ChannelID: " + channelId);
+         }
+
+         List messages = getMessages(new ArrayList(messageChannelPair.keySet()));
+
+         Map returnSet = new HashMap();
+
+         for (Iterator iter = messages.iterator(); iter.hasNext(); )
+         {
+            Message msg = (Message)iter.next();
+            returnSet.put(msg, messageChannelPair.get(new Long(msg.getMessageID())));
+         }
+
+         return returnSet;
+      }
+      catch (Exception e)
+      {
+         wrap.exceptionOccurred();
+         throw e;
+      }
+      finally
+      {
+         if (rs != null)
+         {
+            try
+            {
+               rs.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (ps != null)
+         {
+            try
+            {
+               ps.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         wrap.end();
+      }
+   }
+
+
    // Inner classes -------------------------------------------------
    
    private class TransactionWrapper



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:55:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:55:55 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1745 -
	branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint
Message-ID: <E1Gt7MZ-0007DY-IZ@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-09 13:55:52 -0500 (Sat, 09 Dec 2006)
New Revision: 1745

Modified:
   branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
Log:
rewrite of patch JBMESSAGING-407

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-09 18:53:48 UTC (rev 1744)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-09 18:55:52 UTC (rev 1745)
@@ -70,6 +70,8 @@
  * 
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.com">Juha Lindfors</a>
+ *
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -450,21 +452,25 @@
    }
    
    /**
-    * Get array of XA transactions in prepared state-
+    * Get array of XA transactions in prepared state. <p>
+    *
     * This would be used by the transaction manager in recovery or by a tool to apply
-    * heuristic decisions to commit or rollback particular transactions
+    * heuristic decisions to commit or rollback particular transactions. <p>
+    *
+    * Notice that before returning the Xids this method attemps to recover existing
+    * prepared transactions by delivering any unhandled messages or acks.
     */
    public Xid[] getPreparedTransactions() throws JMSException
    {
       try
       {
-         List xids = tr.getPreparedTransactions();
+         List xids = tr.recoverPreparedTransactions();
          
          return (Xid[])xids.toArray(new Xid[xids.size()]);
       }
       catch (Throwable t)
       {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " getPreparedTransactions");
+         throw ExceptionUtil.handleJMSInvocation(t, this + " recoverPreparedTransactions");
       }
    }
   



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 13:57:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 13:57:12 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1746 -
	branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1Gt7No-0007G8-5U@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-09 13:57:09 -0500 (Sat, 09 Dec 2006)
New Revision: 1746

Modified:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
Log:


Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-09 18:55:52 UTC (rev 1745)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-09 18:57:09 UTC (rev 1746)
@@ -223,7 +223,6 @@
                  tm1.getText().equals("tm3") ||
                  tm1.getText().equals("tm4"));
 
-      //assertEquals("tm1", m1.getText());
 
       TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m2);
@@ -234,7 +233,6 @@
                  tm2.getText().equals("tm4"));
       assertTrue(!tm1.getText().equals(tm2.getText()));
 
-//      assertEquals("tm2", m2.getText());
 
       TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m3);
@@ -247,7 +245,6 @@
       assertTrue(!tm3.getText().equals(tm2.getText()));
       assertTrue(!tm3.getText().equals(tm1.getText()));
 
-//      assertEquals("tm3", m3.getText());
 
       TextMessage m4 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m4);
@@ -261,9 +258,8 @@
       assertTrue(!tm4.getText().equals(tm2.getText()));
       assertTrue(!tm4.getText().equals(tm1.getText()));
 
-//      assertEquals("tm4", m4.getText());
 
-      TextMessage nullMessage = (TextMessage)cons.receive(1000);
+      TextMessage nullMessage = (TextMessage)cons.receive(MIN_TIMEOUT);
 
       assertTrue(nullMessage == null);
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 15:00:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 15:00:31 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1747 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/state
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt8N5-0008Ik-Dv@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 15:00:24 -0500 (Sat, 09 Dec 2006)
New Revision: 1747

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
connection close now automatically closes exceptionlistener



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-09 18:57:09 UTC (rev 1746)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-09 20:00:24 UTC (rev 1747)
@@ -24,11 +24,13 @@
 import javax.jms.ExceptionListener;
 import javax.jms.IllegalStateException;
 import javax.jms.JMSException;
+
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.JBossConnectionMetaData;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
@@ -184,6 +186,16 @@
    {
       Object ret = invocation.invokeNext();
       
+      //Remove any exception listener
+      ConnectionState currentState = getConnectionState(invocation);
+      
+      Client client = getConnectionState(invocation).getRemotingConnection().getInvokingClient();
+      
+      if (currentState.isListenerAdded())
+      {
+         client.removeConnectionListener(this);
+      }
+            
       ConnectionState state = getConnectionState(invocation);
       
       // Finished with the connection - we need to shutdown callback server

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 18:57:09 UTC (rev 1746)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 20:00:24 UTC (rev 1747)
@@ -111,7 +111,7 @@
          
          return invocation.invokeNext();
       }
-   }
+   }   
    
    //TODO this is currently hardcoded as round-robin, this should be made pluggable
    private synchronized ClientConnectionFactoryDelegate getDelegateRoundRobin()
@@ -173,8 +173,10 @@
       
       ConnectionState state = (ConnectionState)((DelegateSupport)connDelegate).getState();
       
-      state.getRemotingConnection().getInvokingClient().addConnectionListener(new Listener(connDelegate));
+      ConnectionListener listener = new Listener(connDelegate);
       
+      state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
+      
       return connDelegate;   
    }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-09 18:57:09 UTC (rev 1746)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-09 20:00:24 UTC (rev 1747)
@@ -21,10 +21,10 @@
   */
 package org.jboss.jms.client.state;
 
-import EDU.oswego.cs.dl.util.concurrent.SyncSet;
-import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
 import java.util.HashSet;
+
 import javax.jms.ExceptionListener;
+
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.delegate.ConnectionDelegate;
@@ -32,7 +32,11 @@
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
+import org.jboss.remoting.ConnectionListener;
 
+import EDU.oswego.cs.dl.util.concurrent.SyncSet;
+import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
+
 /**
  * 
  * State corresponding to a connection. This state is acessible inside aspects/interceptors.
@@ -79,9 +83,8 @@
 
     /** This property used to be delcared on ConnectionAspect */
    private boolean listenerAdded;
-
-
-
+   
+   
    public ConnectionState(int serverID, ConnectionDelegate delegate,
                           JMSRemotingConnection remotingConnection, Version versionToUse,
                           ResourceManager rm, MessageIdGenerator gen)
@@ -221,7 +224,7 @@
     public void setListenerAdded(boolean listenerAdded)
     {
         this.listenerAdded = listenerAdded;
-    }
+    }    
 
     /** Connection doesn't have a parent */
     public HierarchicalState getParent()

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-09 18:57:09 UTC (rev 1746)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-09 20:00:24 UTC (rev 1747)
@@ -379,7 +379,30 @@
       conn.close();
 
    }
-
+   
+   /*
+    * See http://jira.jboss.com/jira/browse/JBMESSAGING-635
+    * 
+    * This needs to be run remotely to see the exception
+    */
+   public void testConnectionListenerBug() throws Exception
+   {
+      for (int i = 0; i < 500; i++)
+      {
+         Connection conn = cf.createConnection();
+         
+         MyExceptionListener listener = new MyExceptionListener();
+         
+         conn.setExceptionListener(listener);
+         
+         conn.close();        
+         
+         //The problem with this test is I would need to capture the output and search
+         //for NullPointerException!!!
+                  
+      } 
+   }
+   
    // TODO - Decide if valid and uncomment or get rid of it!
 
 //   Commented out for now, since how can i make the server fail from a test?   

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 18:57:09 UTC (rev 1746)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 20:00:24 UTC (rev 1747)
@@ -74,349 +74,349 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-//   public void testRoundRobinConnectionCreation() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//      
-//      log.info ("number of delegates = " + delegate.getDelegates().length);
-//      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//      
-//      assertEquals(3, delegate.getDelegates().length);
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//      
-//      assertEquals(0, cf1.getServerId());
-//      
-//      assertEquals(1, cf2.getServerId());
-//      
-//      assertEquals(2, cf3.getServerId());
-//      
-//      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//      
-//      Connection conn1 = null;
-//      
-//      Connection conn2 = null;
-//      
-//      Connection conn3 = null;
-//      
-//      Connection conn4 = null;
-//      
-//      Connection conn5 = null;
-//      
-//      try
-//      {         
-//         conn1 = factory.createConnection();
-//         
-//         conn2 = factory.createConnection();
-//         
-//         conn3 = factory.createConnection();
-//         
-//         conn4 = factory.createConnection();
-//         
-//         conn5 = factory.createConnection();
-//         
-//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-//         
-//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-//         
-//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-//         
-//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-//         
-//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-//         
-//         int serverID1 = state1.getServerID();
-//         
-//         int serverID2 = state2.getServerID();
-//         
-//         int serverID3 = state3.getServerID();
-//         
-//         int serverID4 = state4.getServerID();
-//         
-//         int serverID5 = state5.getServerID();
-//         
-//         log.info("server id 1: " + serverID1);
-//         
-//         log.info("server id 2: " + serverID2);
-//         
-//         log.info("server id 3: " + serverID3);
-//         
-//         log.info("server id 4: " + serverID4);
-//         
-//         log.info("server id 5: " + serverID5);
-//         
-//         assertEquals(0, serverID1);
-//         
-//         assertEquals(1, serverID2);
-//         
-//         assertEquals(2, serverID3);
-//         
-//         assertEquals(0, serverID4);
-//         
-//         assertEquals(1, serverID5);
-//      }
-//      finally
-//      {
-//         if (conn1 != null)
-//         {
-//            conn1.close();
-//         }
-//         
-//         if (conn2 != null)
-//         {
-//            conn2.close();
-//         }
-//         
-//         if (conn3 != null)
-//         {
-//            conn3.close();
-//         }
-//         
-//         if (conn4 != null)
-//         {
-//            conn4.close();
-//         }
-//         
-//         if (conn5 != null)
-//         {
-//            conn5.close();
-//         }
-//      }
-//      
-//   }
-// 
-//   /*
-//    * Test that the failover mapping is created correctly and updated properly when nodes leave
-//    * or join
-//    */
-//   public void testDefaultFailoverMap() throws Exception
-//   {     
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         //The order here depends on the order the servers were started in
-//         
-//         //If any servers get stopped and then started then the order will change
-//    
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         
-//         assertEquals(0, cf1.getServerId());
-//         
-//         assertEquals(1, cf2.getServerId());
-//         
-//         assertEquals(2, cf3.getServerId());
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         // Default failover policy just chooses the node to the right
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }
-//      
-//      //Now cleanly stop one of the servers
-//      
-//      
-//      log.info("************** STOPPING SERVER 0");
-//      ServerManagement.stop(0, true);
-//      
-//      log.info("server stopped");
-//      
-//      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         //Order here depends on order servers were started in
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(1, cf1.getServerId());
-//         
-//         assertEquals(2, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      //Cleanly stop another server
-//      
-//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-//      
-//      ServerManagement.stop(1, true);
-//      
-//      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(1, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         
-//         assertEquals(1, failoverMap.size());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//      }
-//            
-//      //Restart server 0
-//      
-//      ServerManagement.start("all", 0);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      
-//      //Restart server 1
-//      
-//      ServerManagement.start("all", 1);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         assertEquals(1, cf3.getServerId());
-//         
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }            
-//   }
+   public void testRoundRobinConnectionCreation() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      log.info ("number of delegates = " + delegate.getDelegates().length);
+      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      assertEquals(3, delegate.getDelegates().length);
+      
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
+      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      Connection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      Connection conn4 = null;
+      
+      Connection conn5 = null;
+      
+      try
+      {         
+         conn1 = factory.createConnection();
+         
+         conn2 = factory.createConnection();
+         
+         conn3 = factory.createConnection();
+         
+         conn4 = factory.createConnection();
+         
+         conn5 = factory.createConnection();
+         
+         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+         
+         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+         
+         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+         
+         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+         
+         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+         
+         int serverID1 = state1.getServerID();
+         
+         int serverID2 = state2.getServerID();
+         
+         int serverID3 = state3.getServerID();
+         
+         int serverID4 = state4.getServerID();
+         
+         int serverID5 = state5.getServerID();
+         
+         log.info("server id 1: " + serverID1);
+         
+         log.info("server id 2: " + serverID2);
+         
+         log.info("server id 3: " + serverID3);
+         
+         log.info("server id 4: " + serverID4);
+         
+         log.info("server id 5: " + serverID5);
+         
+         assertEquals(0, serverID1);
+         
+         assertEquals(1, serverID2);
+         
+         assertEquals(2, serverID3);
+         
+         assertEquals(0, serverID4);
+         
+         assertEquals(1, serverID5);
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+         
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+         
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
+      }
+      
+   }
+ 
+   /*
+    * Test that the failover mapping is created correctly and updated properly when nodes leave
+    * or join
+    */
+   public void testDefaultFailoverMap() throws Exception
+   {     
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         //The order here depends on the order the servers were started in
+         
+         //If any servers get stopped and then started then the order will change
+    
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         
+         assertEquals(0, cf1.getServerId());
+         
+         assertEquals(1, cf2.getServerId());
+         
+         assertEquals(2, cf3.getServerId());
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(3, delegates.length);
+         
+         assertEquals(3, failoverMap.size());
+         
+         // Default failover policy just chooses the node to the right
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }
+      
+      //Now cleanly stop one of the servers
+      
+      
+      log.info("************** STOPPING SERVER 0");
+      ServerManagement.stop(0, true);
+      
+      log.info("server stopped");
+      
+      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         //Order here depends on order servers were started in
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(1, cf1.getServerId());
+         
+         assertEquals(2, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      //Cleanly stop another server
+      
+      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+      
+      ServerManagement.stop(1, true);
+      
+      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(1, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         assertEquals(2, cf1.getServerId());
+         
+         
+         assertEquals(1, failoverMap.size());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+      }
+            
+      //Restart server 0
+      
+      ServerManagement.start("all", 0);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      
+      //Restart server 1
+      
+      ServerManagement.start("all", 1);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(3, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         assertEquals(1, cf3.getServerId());
+         
+         
+         assertEquals(3, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }            
+   }
    
    public void testSimpleFailover() throws Exception
    {
@@ -489,7 +489,7 @@
          
          log.info("killed server, now waiting");
          
-         Thread.sleep(3000);
+         Thread.sleep(300000);
          
          log.info("done wait");
          



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 15:26:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 15:26:37 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1748 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gt8mL-0000LT-7N@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 15:26:32 -0500 (Sat, 09 Dec 2006)
New Revision: 1748

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Failover finally!



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 20:00:24 UTC (rev 1747)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 20:26:32 UTC (rev 1748)
@@ -184,25 +184,29 @@
    //The connection has failed
    private void handleFailure(ClientConnectionDelegate failedConnection) throws Exception
    {
+      log.info("Handling failure");
+      
       ClientConnectionFactoryDelegate newCF = getFailoverDelegate(failedConnection);
 
       //TODO implement client side valve to prevent invocations occurring whilst failover is occurring
       
       ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
 
+      log.info("Creating new connection");
       ClientConnectionDelegate newConnection = createConnection(newCF, state.getUser(), state.getPassword());
+      log.info("Created new connection");
       
-      try
-      {
+//      try
+//      {
          failover(failedConnection, newConnection);
-      }
-      catch (Throwable t)
-      {
-         //TODO
-         //If failover itself fails, we shouldn't give up, we should try the next one in the list
-         //etc until we find one that works
-         //TODO
-      }
+//      }
+//      catch (Throwable t)
+//      {
+//         //TODO
+//         //If failover itself fails, we shouldn't give up, we should try the next one in the list
+//         //etc until we find one that works
+//         //TODO
+//      }
    }
    
    private ClientConnectionFactoryDelegate getFailoverDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
@@ -342,6 +346,7 @@
             }
          }
       }
+      log.info("Failedover done");
    }
 
    private void handleFailoverOnConsumer(ClientConnectionDelegate connectionDelegate,
@@ -437,6 +442,8 @@
       {
          try
          {
+            log.info("********* EXCEPTION DETECTED");
+            
             log.info("handleConnectionException: ", throwable);
             
             

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 20:00:24 UTC (rev 1747)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 20:26:32 UTC (rev 1748)
@@ -74,349 +74,349 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-   public void testRoundRobinConnectionCreation() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      log.info ("number of delegates = " + delegate.getDelegates().length);
-      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      assertEquals(3, delegate.getDelegates().length);
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-      
-      Connection conn4 = null;
-      
-      Connection conn5 = null;
-      
-      try
-      {         
-         conn1 = factory.createConnection();
-         
-         conn2 = factory.createConnection();
-         
-         conn3 = factory.createConnection();
-         
-         conn4 = factory.createConnection();
-         
-         conn5 = factory.createConnection();
-         
-         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
-         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
-         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
-         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
-         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
-         int serverID1 = state1.getServerID();
-         
-         int serverID2 = state2.getServerID();
-         
-         int serverID3 = state3.getServerID();
-         
-         int serverID4 = state4.getServerID();
-         
-         int serverID5 = state5.getServerID();
-         
-         log.info("server id 1: " + serverID1);
-         
-         log.info("server id 2: " + serverID2);
-         
-         log.info("server id 3: " + serverID3);
-         
-         log.info("server id 4: " + serverID4);
-         
-         log.info("server id 5: " + serverID5);
-         
-         assertEquals(0, serverID1);
-         
-         assertEquals(1, serverID2);
-         
-         assertEquals(2, serverID3);
-         
-         assertEquals(0, serverID4);
-         
-         assertEquals(1, serverID5);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-         
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-         
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-         
-         if (conn4 != null)
-         {
-            conn4.close();
-         }
-         
-         if (conn5 != null)
-         {
-            conn5.close();
-         }
-      }
-      
-   }
- 
-   /*
-    * Test that the failover mapping is created correctly and updated properly when nodes leave
-    * or join
-    */
-   public void testDefaultFailoverMap() throws Exception
-   {     
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         //The order here depends on the order the servers were started in
-         
-         //If any servers get stopped and then started then the order will change
-    
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         
-         assertEquals(0, cf1.getServerId());
-         
-         assertEquals(1, cf2.getServerId());
-         
-         assertEquals(2, cf3.getServerId());
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(3, delegates.length);
-         
-         assertEquals(3, failoverMap.size());
-         
-         // Default failover policy just chooses the node to the right
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }
-      
-      //Now cleanly stop one of the servers
-      
-      
-      log.info("************** STOPPING SERVER 0");
-      ServerManagement.stop(0, true);
-      
-      log.info("server stopped");
-      
-      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         //Order here depends on order servers were started in
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(1, cf1.getServerId());
-         
-         assertEquals(2, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      //Cleanly stop another server
-      
-      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
-      ServerManagement.stop(1, true);
-      
-      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(1, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         assertEquals(2, cf1.getServerId());
-         
-         
-         assertEquals(1, failoverMap.size());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      }
-            
-      //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      
-      //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(3, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         assertEquals(1, cf3.getServerId());
-         
-         
-         assertEquals(3, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }            
-   }
+//   public void testRoundRobinConnectionCreation() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//      
+//      log.info ("number of delegates = " + delegate.getDelegates().length);
+//      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//      
+//      assertEquals(3, delegate.getDelegates().length);
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//      
+//      assertEquals(0, cf1.getServerId());
+//      
+//      assertEquals(1, cf2.getServerId());
+//      
+//      assertEquals(2, cf3.getServerId());
+//      
+//      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//      
+//      Connection conn1 = null;
+//      
+//      Connection conn2 = null;
+//      
+//      Connection conn3 = null;
+//      
+//      Connection conn4 = null;
+//      
+//      Connection conn5 = null;
+//      
+//      try
+//      {         
+//         conn1 = factory.createConnection();
+//         
+//         conn2 = factory.createConnection();
+//         
+//         conn3 = factory.createConnection();
+//         
+//         conn4 = factory.createConnection();
+//         
+//         conn5 = factory.createConnection();
+//         
+//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+//         
+//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+//         
+//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+//         
+//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+//         
+//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+//         
+//         int serverID1 = state1.getServerID();
+//         
+//         int serverID2 = state2.getServerID();
+//         
+//         int serverID3 = state3.getServerID();
+//         
+//         int serverID4 = state4.getServerID();
+//         
+//         int serverID5 = state5.getServerID();
+//         
+//         log.info("server id 1: " + serverID1);
+//         
+//         log.info("server id 2: " + serverID2);
+//         
+//         log.info("server id 3: " + serverID3);
+//         
+//         log.info("server id 4: " + serverID4);
+//         
+//         log.info("server id 5: " + serverID5);
+//         
+//         assertEquals(0, serverID1);
+//         
+//         assertEquals(1, serverID2);
+//         
+//         assertEquals(2, serverID3);
+//         
+//         assertEquals(0, serverID4);
+//         
+//         assertEquals(1, serverID5);
+//      }
+//      finally
+//      {
+//         if (conn1 != null)
+//         {
+//            conn1.close();
+//         }
+//         
+//         if (conn2 != null)
+//         {
+//            conn2.close();
+//         }
+//         
+//         if (conn3 != null)
+//         {
+//            conn3.close();
+//         }
+//         
+//         if (conn4 != null)
+//         {
+//            conn4.close();
+//         }
+//         
+//         if (conn5 != null)
+//         {
+//            conn5.close();
+//         }
+//      }
+//      
+//   }
+// 
+//   /*
+//    * Test that the failover mapping is created correctly and updated properly when nodes leave
+//    * or join
+//    */
+//   public void testDefaultFailoverMap() throws Exception
+//   {     
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         //The order here depends on the order the servers were started in
+//         
+//         //If any servers get stopped and then started then the order will change
+//    
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         
+//         assertEquals(0, cf1.getServerId());
+//         
+//         assertEquals(1, cf2.getServerId());
+//         
+//         assertEquals(2, cf3.getServerId());
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         // Default failover policy just chooses the node to the right
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }
+//      
+//      //Now cleanly stop one of the servers
+//      
+//      
+//      log.info("************** STOPPING SERVER 0");
+//      ServerManagement.stop(0, true);
+//      
+//      log.info("server stopped");
+//      
+//      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         //Order here depends on order servers were started in
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(1, cf1.getServerId());
+//         
+//         assertEquals(2, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      //Cleanly stop another server
+//      
+//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+//      
+//      ServerManagement.stop(1, true);
+//      
+//      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(1, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         
+//         assertEquals(1, failoverMap.size());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//      }
+//            
+//      //Restart server 0
+//      
+//      ServerManagement.start("all", 0);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      
+//      //Restart server 1
+//      
+//      ServerManagement.start("all", 1);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         assertEquals(1, cf3.getServerId());
+//         
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }            
+//   }
    
    public void testSimpleFailover() throws Exception
    {
@@ -489,7 +489,7 @@
          
          log.info("killed server, now waiting");
          
-         Thread.sleep(300000);
+         Thread.sleep(30000);
          
          log.info("done wait");
          



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 15:45:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 15:45:47 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1749 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container
Message-ID: <E1Gt94t-0000dt-QN@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-09 15:45:46 -0500 (Sat, 09 Dec 2006)
New Revision: 1749

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
just adding a TODO

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 20:26:32 UTC (rev 1748)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 20:45:46 UTC (rev 1749)
@@ -26,9 +26,7 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-
 import javax.jms.JMSException;
-
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
@@ -83,7 +81,9 @@
    public Object handleCreateConnectionDelegate(Invocation invocation) throws Throwable
    {
       if (getServers(invocation) != null)
-      {         
+      {
+         // TODO: this should be in loop while we get exceptions creating connections, always trying
+         //       the next Delegate when we get an exception.
          log.info("Clustered createConnection");
                   
          //In a clustered configuration we create connections in a round-robin fashion



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 15:58:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 15:58:28 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1750 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base
Message-ID: <E1Gt9HA-0000sO-Np@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-09 15:58:24 -0500 (Sat, 09 Dec 2006)
New Revision: 1750

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Log:
Testing for log

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-09 20:45:46 UTC (rev 1749)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-09 20:58:24 UTC (rev 1750)
@@ -31,7 +31,6 @@
 import javax.jms.Topic;
 import javax.naming.Context;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
@@ -128,24 +127,24 @@
    {
       try
       {
-         ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0");
 
          if (ServerManagement.getServer(0).isStarted())
          {
+            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0", 0);
             ServerManagement.undeployQueue("testDistributedQueue", 0);
             ServerManagement.undeployTopic("testDistributedTopic", 0);
          }
 
          if (ServerManagement.getServer(1).isStarted())
          {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1");
+            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1", 1);
             ServerManagement.undeployQueue("testDistributedQueue", 1);
             ServerManagement.undeployTopic("testDistributedTopic", 1);
          }
 
          if (ServerManagement.getServer(2).isStarted())
          {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2");
+            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2", 2);
             ServerManagement.undeployQueue("testDistributedQueue", 2);
             ServerManagement.undeployTopic("testDistributedTopic", 2);
          }



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 18:14:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 18:14:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r58955 -
	branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument
Message-ID: <E1GtBOt-0003Fv-Np@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-09 18:14:30 -0500 (Sat, 09 Dec 2006)
New Revision: 58955

Modified:
   branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
   branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/OptimizedMethodExecutionTransformer.java
Log:
[JBAOP-318] Temporary approach to solve the issue on OptimizedMethodExecutionTransformer only.

Modified: branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-09 05:37:49 UTC (rev 58954)
+++ branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-09 23:14:30 UTC (rev 58955)
@@ -379,5 +379,13 @@
       {
          return instrumentor;
       }
+      
+      /**
+       * @param wmethod2
+       */
+      public void setMethod(CtMethod method)
+      {
+         this.method = method;
+      }
    }
 }
\ No newline at end of file

Modified: branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/OptimizedMethodExecutionTransformer.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/OptimizedMethodExecutionTransformer.java	2006-12-09 05:37:49 UTC (rev 58954)
+++ branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/OptimizedMethodExecutionTransformer.java	2006-12-09 23:14:30 UTC (rev 58955)
@@ -52,22 +52,28 @@
       CtMethod wmethod = CtNewMethod.copy(trans.getMethod(), trans.getClazz(), null);
 
       // generate Wrapper
+      /* TODO FLAVIA COMMENTED THIS TEMPORARILY */
       String originalName = trans.getOriginalName();
       wmethod.setName(wrappedName);
       trans.getClazz().addMethod(wmethod);
-      moveAnnotations(trans.getMethod(), wmethod);
+      //moveAnnotations(trans.getMethod(), wmethod);
       String optimizedInvocation = OptimizedMethodInvocations.createOptimizedInvocationClass(trans.getInstrumentor(), trans.getClazz(), trans.getMethod());
-      trans.getMethod().setName(wrappedName);
-      wmethod.setName(originalName);
+      //trans.getMethod().setName(wrappedName);
+      //wmethod.setName(originalName);
 
-      trans.setWMethod(wmethod, wrappedName);
+      //trans.setWMethod(wmethod, wrappedName);
+      
+      /* TERMPORARY NEW CODE LINES */
+      trans.setWMethod(trans.getMethod(), wrappedName);
+      trans.setMethod(wmethod);
+      
       // prepareForWrapping
-      getWrapper().prepareForWrapping(wmethod, WrapperTransformer.SINGLE_TRANSFORMATION_INDEX);
+      getWrapper().prepareForWrapping(trans.getWMethod(), WrapperTransformer.SINGLE_TRANSFORMATION_INDEX);
 
       if (wrap)
       {
          // wrap
-         getWrapper().wrap(wmethod, WrapperTransformer.SINGLE_TRANSFORMATION_INDEX);
+         getWrapper().wrap(trans.getWMethod(), WrapperTransformer.SINGLE_TRANSFORMATION_INDEX);
          // executeWrapping
          setWrapperBody(trans, methodInfoField, optimizedInvocation);
       }



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 18:29:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 18:29:11 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1751 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GtBd1-0003Ss-KU@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-09 18:28:59 -0500 (Sat, 09 Dec 2006)
New Revision: 1751

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/TxState.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/PagingChannelSupport.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
Log:
More progress on failover



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -130,23 +130,17 @@
       if (delegates == null)
       {
          log.info("Looking for delegates");
-         SimpleMetaData metaData = invocation.getMetaData();
 
-         //delegates = (ClientConnectionFactoryDelegate[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES);
-
          MethodInvocation methodInvoke = (MethodInvocation)invocation;
-         //delegates = (ClientConnectionFactoryDelegate[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_DELEGATES);
 
-
-         // this is a hack, but I couldn't get this working through metaData
          // TODO: FIX THIS! metaData should contain CF_DELEGATES
          Object target = methodInvoke.getTargetObject();
+         
          if (target instanceof ClusteredClientConnectionFactoryDelegate)
          {
             delegates = ((ClusteredClientConnectionFactoryDelegate)target).getDelegates();
          }
 
-
          if (delegates != null)
          {
             //TODO: Fix this! metadata should contain CF_FAILOVER_INDEXES
@@ -191,6 +185,12 @@
       //TODO implement client side valve to prevent invocations occurring whilst failover is occurring
       
       ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
+      
+      log.info("*** about to failover - waiting for server to finish");
+      
+      //FIXME - this is only temporarily necessary since we need to give the server enough time to
+      //failover before we reconnect - this would be handled by the server side valve
+      Thread.sleep(10000);
 
       log.info("Creating new connection");
       ClientConnectionDelegate newConnection = createConnection(newCF, state.getUser(), state.getPassword());
@@ -357,6 +357,8 @@
                                          int oldServerID)
       throws JMSException
    {
+      log.info("Failing over consumer");
+      
       ClientConsumerDelegate failedConsumerDelegate =
          (ClientConsumerDelegate)failedConsumerState.getDelegate();
 
@@ -379,10 +381,17 @@
       ConsumerState newState = (ConsumerState)newConsumerDelegate.getState();
       failedConsumerState.copy(newState);
 
-      failedConnectionState.getResourceManager().
-         handleFailover(failedSessionState.getCurrentTxId(),
-                        oldConsumerID,
-                        failedConsumerState.getConsumerID());
+      if (failedSessionState.isTransacted())
+      {
+         //Replace the old consumer id with the new consumer id
+         
+         //TODO what about XA?? - may have done work in many transactions - so need to replace all
+         
+         failedConnectionState.getResourceManager().
+            handleFailover(failedSessionState.getCurrentTxId(),
+                           oldConsumerID,
+                           failedConsumerState.getConsumerID());
+      }
 
       CallbackManager cm = failedConnectionState.getRemotingConnection().getCallbackManager();
 
@@ -392,7 +401,10 @@
       cm.registerHandler(failedConnectionState.getServerID(),
                          failedConsumerState.getConsumerID(),
                          handler);
+      
       failedSessionState.addCallbackHandler(handler);
+      
+      log.info("failed over consumer");
 
    }
 
@@ -444,11 +456,6 @@
          {
             log.info("********* EXCEPTION DETECTED");
             
-            log.info("handleConnectionException: ", throwable);
-            
-            
-            log.info("Caught connection exception for connection: " + connection);
-            
             handleFailure(connection);
          }
          catch (Throwable e)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -149,11 +149,6 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
-   public int getFailoverNode(int node) throws JMSException
-   {
-      throw new IllegalStateException("This invocation should not be handled here!");
-   }
-
    // Public --------------------------------------------------------
 
    public synchronized Object invoke(Invocation invocation) throws Throwable

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -43,9 +43,5 @@
    byte[] getClientAOPConfig() throws JMSException;
 
    IdBlock getIdBlock(int size) throws JMSException;
-
-   /** Return the node that should take over a given node */
-   int getFailoverNode(int node) throws JMSException;
-
 }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -137,24 +137,6 @@
       }
    }
 
-
-   public int getFailoverNode(int node) throws JMSException
-   {
-      try
-      {
-         //ServerPeer peer = (ServerPeer )serverPeer.getInstance();
-         //return peer.getReplicator().getFailoverNodeID(node);
-
-         // not implemented yet
-         return node;
-      }
-      catch (Throwable t)
-      {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " getFailoverNode");
-      }
-   }
-
-
    public byte[] getClientAOPConfig() throws JMSException
    {
       try

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -73,11 +73,6 @@
       return endpoint.getIdBlock(size);
    }
 
-   public int getFailoverNode(int node) throws JMSException
-   {
-      return endpoint.getFailoverNode(node);
-   }
-
    // AdvisedSupport override ---------------------------------------
 
    public Object getEndpoint()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -121,14 +121,15 @@
    }
 
     /**
-     * Navigate on ACK and change clientIDs on every ACK not sent yet.
+     * Navigate on ACK and change consumer ids on every ACK not sent yet.
      */
-    public void handleFailover(Object xid, int oldClientId, int newClientId)
+    public void handleFailover(Object xid, int oldConsumerID, int newConsumerID)
     {
-        if (trace) { log.trace("handleFailover:: Transfering clientIds on ACKs from  " + oldClientId + " to " + newClientId); }
+        if (trace) { log.trace("handleFailover:: Transfering consumer id on ACKs from  " + oldConsumerID + " to " + newConsumerID); }
 
         TxState tx = getTx(xid);
-        tx.handleFailover(oldClientId, newClientId);
+        
+        tx.handleFailover(oldConsumerID, newConsumerID);
     }
 
    

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/TxState.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/TxState.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/TxState.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -97,15 +97,16 @@
    }
 
 
-   /** Navigate on ACK and change clientIDs on every ACK not sent yet */
-   public void handleFailover(int oldClientId, int newClientId)
+   /** Navigate on ACK and change consumer ids on every ACK not sent yet */
+   public void handleFailover(int oldConsumerID, int newConsumerID)
    {
-       for (Iterator ackIterator = acks.iterator();ackIterator.hasNext();)
+       for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
        {
            AckInfo ackInfo = (AckInfo)ackIterator.next();
-           if (ackInfo.getConsumerID()==oldClientId)
+           
+           if (ackInfo.getConsumerID() == oldConsumerID)
            {
-               ackInfo.setConsumerID(newClientId);
+               ackInfo.setConsumerID(newConsumerID);
            }
        }
    }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/PagingChannelSupport.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -235,7 +235,7 @@
          
          //Load the unpaged references
          InitialLoadInfo ili = pm.getInitialReferenceInfos(channelID, fullSize);
-
+         
          if (ili.getMaxPageOrdering() != null)            
          {
             firstPagingOrder = ili.getMinPageOrdering().longValue();
@@ -248,67 +248,25 @@
          {
             firstPagingOrder = nextPagingOrder = 0;
          }
-
-          pushReferences(ili);
-
-          //Maybe we need to load some paged refs
          
+         log.info("Channel " + this.channelID + " loading " + ili.getRefInfos().size() + " references");
+         
+         Map refMap = processReferences(ili.getRefInfos());
+         
+         Iterator iter = ili.getRefInfos().iterator();
+         while (iter.hasNext())
+         {
+            ReferenceInfo info = (ReferenceInfo)iter.next();
+            
+            addFromRefInfo(info, refMap);
+         }
+         
+         //Maybe we need to load some paged refs
+         
          while (checkLoad()) {}
       }
    }
-
-    /** We extracted this as a method fro mload, as transferChannel (for HA recovery) also needs the same routine. */
-    private Map pushReferences(InitialLoadInfo ili) throws Exception {
-        Map refMap = processReferences(ili.getRefInfos());
-
-        Iterator iter = ili.getRefInfos().iterator();
-        while (iter.hasNext())
-        {
-           ReferenceInfo info = (ReferenceInfo)iter.next();
-
-           addFromRefInfo(info, refMap);
-        }
-        return refMap;
-    }
-
-    /** Transfer messages for an old channel to a new channel.
-     *  This is used during HA failoever when a connection fail and messages will need to be transfered to a new node */
-    public void transferChannel(long oldchannelID) throws Exception
-    {
-        log.info("Transfering state from " + oldchannelID +" into " + this.getChannelID());
-        synchronized (refLock)
-        {
-            while(true)
-            {
-                InitialLoadInfo ili =pm.getInitialReferenceInfos(oldchannelID,fullSize);
-                if (ili.getRefInfos().size()==0)
-                {
-                    break;
-                }
-
-                log.info("got " + ili.getRefInfos().size() + " references to move");
-
-
-
-                Map refMap = pushReferences(ili);
-                Iterator referencesIterator = ili.getRefInfos().iterator();
-                while (referencesIterator.hasNext())
-                {
-                    ReferenceInfo info = (ReferenceInfo)referencesIterator.next();
-                    log.info("transfering reference " + info.getMessageId() + " from " + oldchannelID + " into " + this.getChannelID());
-                    MessageReference messageReference = (MessageReference )refMap.get(new Long(info.getMessageId()));
-
-                    ///// BIG TODOS:
-                    ///// What to do with transaction here?
-                    ///// Do we need to remove from old channel? (Consider the case of the Old Server coming back... I guess we should.. bu we have to check this)
-                    pm.addReference(this.getChannelID(),messageReference,null);
-                    pm.removeReference(oldchannelID,messageReference, null);
-                }
-            }
-        }
-        log.info("transfer state done");
-    }
-    
+   
       
    public void unload() throws Exception
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -1357,8 +1357,6 @@
          }
       }
    }
-
-
    
    /**
     * This method fails over all the queues from node <nodeId> onto this node
@@ -1424,6 +1422,8 @@
             namesToRemove.add(entry);
          }
 
+         log.info("Deleting " + namesToRemove.size() + " bindings from old node");
+         
          for (Iterator iterNames = namesToRemove.iterator(); iterNames.hasNext();)
          {
             Map.Entry entry = (Map.Entry)iterNames.next();
@@ -1439,6 +1439,8 @@
 
             //Then deleted from the database
             this.deleteBinding(nodeId, queueName);
+            
+            log.info("deleted binding for " + queueName);
 
             //Then an unbind request is sent - this cause other nodes to also remove it from the in memory
             //condition and name maps
@@ -1461,11 +1463,17 @@
             {
                log.info("The current node didn't have a queue " + queueName + " so it's assuming the queue as a regular queue");
             }
+            else
+            {
+               log.info("There is already a queue with that name so adding to failed map");
+            }
            
             //Create a new binding
             Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
                                                     stub.getName(), stub.getChannelID(),
                                                     stub.getFilter(), stub.isRecoverable(), failed);
+            
+            log.info("Created new binding");
 
             //Insert it into the database
             insertBinding(newBinding);
@@ -1476,6 +1484,8 @@
             clusteredQueue.load();
             clusteredQueue.activate();
             
+            log.info("Loaded queue");
+            
             //Add the new binding in memory
             addBinding(newBinding);
             
@@ -2223,11 +2233,11 @@
 
       //Need to evaluate this before we regenerate the failover map
       boolean isFailover = isFailoverNodeForNode(theNodeId.intValue());
+      
+      log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
+      
+      log.info("Crashed: " + crashed);
 
-      //Now we recalculate the failover mapping - this needs to be done before removeDataForNode is called
-      //since that may cause connection factories to be rebound
-      //generateFailoverMap(currentView);
-
       //Remove any replicant data and non durable bindings for the node - again we need to do this
       //irrespective of whether we crashed
       //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
@@ -2341,8 +2351,6 @@
       
       public void viewAccepted(View newView)
       {
-         //if (trace) { log.trace(DefaultClusteredPostOffice.this  + " got new view: " + newView
-         // + DefaultClusteredPostOffice.this.getOfficeName()); }
          //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
          //TODO:     can't we do the same since this is pretty useful?
          log.info(currentNodeId  + " got new view: " + newView + " postOffice:"

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -74,349 +74,349 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-//   public void testRoundRobinConnectionCreation() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//      
-//      log.info ("number of delegates = " + delegate.getDelegates().length);
-//      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//      
-//      assertEquals(3, delegate.getDelegates().length);
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//      
-//      assertEquals(0, cf1.getServerId());
-//      
-//      assertEquals(1, cf2.getServerId());
-//      
-//      assertEquals(2, cf3.getServerId());
-//      
-//      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//      
-//      Connection conn1 = null;
-//      
-//      Connection conn2 = null;
-//      
-//      Connection conn3 = null;
-//      
-//      Connection conn4 = null;
-//      
-//      Connection conn5 = null;
-//      
-//      try
-//      {         
-//         conn1 = factory.createConnection();
-//         
-//         conn2 = factory.createConnection();
-//         
-//         conn3 = factory.createConnection();
-//         
-//         conn4 = factory.createConnection();
-//         
-//         conn5 = factory.createConnection();
-//         
-//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-//         
-//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-//         
-//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-//         
-//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-//         
-//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-//         
-//         int serverID1 = state1.getServerID();
-//         
-//         int serverID2 = state2.getServerID();
-//         
-//         int serverID3 = state3.getServerID();
-//         
-//         int serverID4 = state4.getServerID();
-//         
-//         int serverID5 = state5.getServerID();
-//         
-//         log.info("server id 1: " + serverID1);
-//         
-//         log.info("server id 2: " + serverID2);
-//         
-//         log.info("server id 3: " + serverID3);
-//         
-//         log.info("server id 4: " + serverID4);
-//         
-//         log.info("server id 5: " + serverID5);
-//         
-//         assertEquals(0, serverID1);
-//         
-//         assertEquals(1, serverID2);
-//         
-//         assertEquals(2, serverID3);
-//         
-//         assertEquals(0, serverID4);
-//         
-//         assertEquals(1, serverID5);
-//      }
-//      finally
-//      {
-//         if (conn1 != null)
-//         {
-//            conn1.close();
-//         }
-//         
-//         if (conn2 != null)
-//         {
-//            conn2.close();
-//         }
-//         
-//         if (conn3 != null)
-//         {
-//            conn3.close();
-//         }
-//         
-//         if (conn4 != null)
-//         {
-//            conn4.close();
-//         }
-//         
-//         if (conn5 != null)
-//         {
-//            conn5.close();
-//         }
-//      }
-//      
-//   }
-// 
-//   /*
-//    * Test that the failover mapping is created correctly and updated properly when nodes leave
-//    * or join
-//    */
-//   public void testDefaultFailoverMap() throws Exception
-//   {     
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         //The order here depends on the order the servers were started in
-//         
-//         //If any servers get stopped and then started then the order will change
-//    
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         
-//         assertEquals(0, cf1.getServerId());
-//         
-//         assertEquals(1, cf2.getServerId());
-//         
-//         assertEquals(2, cf3.getServerId());
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         // Default failover policy just chooses the node to the right
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }
-//      
-//      //Now cleanly stop one of the servers
-//      
-//      
-//      log.info("************** STOPPING SERVER 0");
-//      ServerManagement.stop(0, true);
-//      
-//      log.info("server stopped");
-//      
-//      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         //Order here depends on order servers were started in
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(1, cf1.getServerId());
-//         
-//         assertEquals(2, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      //Cleanly stop another server
-//      
-//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-//      
-//      ServerManagement.stop(1, true);
-//      
-//      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(1, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         
-//         assertEquals(1, failoverMap.size());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//      }
-//            
-//      //Restart server 0
-//      
-//      ServerManagement.start("all", 0);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      
-//      //Restart server 1
-//      
-//      ServerManagement.start("all", 1);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         assertEquals(1, cf3.getServerId());
-//         
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }            
-//   }
+   public void testRoundRobinConnectionCreation() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      log.info ("number of delegates = " + delegate.getDelegates().length);
+      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      assertEquals(3, delegate.getDelegates().length);
+      
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
+      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+      
+      Connection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      Connection conn4 = null;
+      
+      Connection conn5 = null;
+      
+      try
+      {         
+         conn1 = factory.createConnection();
+         
+         conn2 = factory.createConnection();
+         
+         conn3 = factory.createConnection();
+         
+         conn4 = factory.createConnection();
+         
+         conn5 = factory.createConnection();
+         
+         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+         
+         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+         
+         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+         
+         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+         
+         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+         
+         int serverID1 = state1.getServerID();
+         
+         int serverID2 = state2.getServerID();
+         
+         int serverID3 = state3.getServerID();
+         
+         int serverID4 = state4.getServerID();
+         
+         int serverID5 = state5.getServerID();
+         
+         log.info("server id 1: " + serverID1);
+         
+         log.info("server id 2: " + serverID2);
+         
+         log.info("server id 3: " + serverID3);
+         
+         log.info("server id 4: " + serverID4);
+         
+         log.info("server id 5: " + serverID5);
+         
+         assertEquals(0, serverID1);
+         
+         assertEquals(1, serverID2);
+         
+         assertEquals(2, serverID3);
+         
+         assertEquals(0, serverID4);
+         
+         assertEquals(1, serverID5);
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+         
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+         
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
+      }
+      
+   }
+ 
+   /*
+    * Test that the failover mapping is created correctly and updated properly when nodes leave
+    * or join
+    */
+   public void testDefaultFailoverMap() throws Exception
+   {     
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         //The order here depends on the order the servers were started in
+         
+         //If any servers get stopped and then started then the order will change
+    
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         
+         assertEquals(0, cf1.getServerId());
+         
+         assertEquals(1, cf2.getServerId());
+         
+         assertEquals(2, cf3.getServerId());
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(3, delegates.length);
+         
+         assertEquals(3, failoverMap.size());
+         
+         // Default failover policy just chooses the node to the right
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }
+      
+      //Now cleanly stop one of the servers
+      
+      
+      log.info("************** STOPPING SERVER 0");
+      ServerManagement.stop(0, true);
+      
+      log.info("server stopped");
+      
+      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         //Order here depends on order servers were started in
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(1, cf1.getServerId());
+         
+         assertEquals(2, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      //Cleanly stop another server
+      
+      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+      
+      ServerManagement.stop(1, true);
+      
+      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(1, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         assertEquals(2, cf1.getServerId());
+         
+         
+         assertEquals(1, failoverMap.size());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+      }
+            
+      //Restart server 0
+      
+      ServerManagement.start("all", 0);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      
+      //Restart server 1
+      
+      ServerManagement.start("all", 1);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(3, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         assertEquals(1, cf3.getServerId());
+         
+         
+         assertEquals(3, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }            
+   }
    
    public void testSimpleFailover() throws Exception
    {
@@ -463,13 +463,13 @@
          int initialServerID = state.getServerID();
          
          assertEquals(0, initialServerID);
-         
-         
-         
+                           
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
          MessageProducer prod = sess.createProducer(queue0);
          
+         MessageConsumer cons = sess.createConsumer(queue0);
+         
          final int NUM_MESSAGES = 100;
          
          for (int i = 0; i < NUM_MESSAGES; i++)
@@ -489,7 +489,7 @@
          
          log.info("killed server, now waiting");
          
-         Thread.sleep(30000);
+         Thread.sleep(25000);
          
          log.info("done wait");
          
@@ -505,10 +505,6 @@
          
          log.info("here 2");
          
-         //I should now be able to create a consumer on the same connection and consume the messages
-         
-         MessageConsumer cons = sess.createConsumer(queue0);
-         
          conn.start();
          
          log.info("here 3");
@@ -517,6 +513,8 @@
          {
             TextMessage tm = (TextMessage)cons.receive(1000);
             
+            log.info("message is " + tm);
+            
             assertNotNull(tm);
             
             assertEquals("message:" + i, tm.getText());
@@ -533,14 +531,51 @@
             }
             catch (Exception e)
             {
-               //Ignore
+               e.printStackTrace();
             }
          }
       }
       
    }
    
+   public void testEvenSimplerFailover() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+                  
+      Connection conn = null;
+      
+      try
+      {
+         conn = factory.createConnection();
+                           
+         log.info("************ KILLING (CRASHING) SERVER 0");
+         
+         ServerManagement.getServer(0).destroy();
+         
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(25000);
+         
+         log.info("done wait");                
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+      }
+      
+   }
    
+   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -106,8 +106,6 @@
       ServerManagement.getServer(0).destroy();
    }
 
-
-
    public void testDistributedTopic() throws Exception
    {
       Connection conn = null;

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-09 20:58:24 UTC (rev 1750)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-09 23:28:59 UTC (rev 1751)
@@ -222,15 +222,10 @@
 
    public synchronized void destroy() throws Exception
    {
-      server.destroy();
-
-      registry.unbind(RMI_SERVER_PREFIX + index);
-      registry.unbind(NAMING_SERVER_PREFIX + index);
+      //Kill the server without doing any graceful shutdown
       
-      // Now shutdown the process. The registry will be taken out with the last RMI server standing
+      //For graceful shutdown use stop()
       
-      //TODO - we should shutdown cleanly - let main() exit - not kill the process
-      
       new Thread(new VMKiller(), "VM Killer").start();
    }
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec  9 20:12:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 09 Dec 2006 20:12:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r58956 -
	branches/Branch_4_2/server/src/etc/conf/default
Message-ID: <E1GtDFH-00055m-70@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-09 20:12:45 -0500 (Sat, 09 Dec 2006)
New Revision: 58956

Modified:
   branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml
Log:
Add the DeepCopySubjectMode attribute to JaasSecurityManagerService

Modified: branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml	2006-12-09 23:14:30 UTC (rev 58955)
+++ branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml	2006-12-10 01:12:45 UTC (rev 58956)
@@ -291,6 +291,15 @@
       AuthenticationCacheJndiName has been changed from the default value.
       -->
       <attribute name="DefaultCacheResolution">60</attribute>
+      <!-- DeepCopySubjectMode: This set the copy mode of subjects done by the
+      security managers to be deep copies that makes copies of the subject
+      principals and credentials if they are cloneable. It should be set to
+      true if subject include mutable content that can be corrupted when
+      multiple threads have the same identity and cache flushes/logout clearing
+      the subject in one thread results in subject references affecting other
+      threads.
+      -->
+      <attribute name="DeepCopySubjectMode">false</attribute>
    </mbean>
 
    <!-- ==================================================================== -->



From mandersen at jboss.com  Sat Dec  9 20:59:03 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Sat, 09 Dec 2006 20:59:03 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards
	...
Message-ID: <E1GtDy3-0005ke-7Y@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/09 20:59:03

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards 
                        ConsoleConfigurationWizardPage.java
  Log:
  HBX-834 NullPointerException in EclipseConsoleConfigurationPreferences
  
  Revision  Changes    Path
  1.26      +10 -0     jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationWizardPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfigurationWizardPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationWizardPage.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- ConsoleConfigurationWizardPage.java	16 Nov 2006 17:30:06 -0000	1.25
  +++ ConsoleConfigurationWizardPage.java	10 Dec 2006 01:59:03 -0000	1.26
  @@ -689,6 +689,16 @@
   			//return;
   		}
   		
  +		if((useProjectClassPath() && StringHelper.isEmpty( getProjectName() )) && classPathViewer.getTable().getItemCount()==0) {
  +			updateStatus( "Need to specify a project or setup a classpath" );
  +			return;
  +		}
  +		
  +		if((!useProjectClassPath() && classPathViewer.getTable().getItemCount()==0)) {
  +			updateStatus( "Need to specify a classpath when not using a project classpath" );
  +			return;
  +		}
  +		
   		updateStatus(null);
   	}
   
  
  
  


From mandersen at jboss.com  Sat Dec  9 20:59:03 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Sat, 09 Dec 2006 20:59:03 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console
	...
Message-ID: <E1GtDy3-0005kl-Be@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/09 20:59:03

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console 
                        EclipseConsoleConfigurationPreferences.java
  Log:
  HBX-834 NullPointerException in EclipseConsoleConfigurationPreferences
  
  Revision  Changes    Path
  1.10      +1 -1      jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/EclipseConsoleConfigurationPreferences.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EclipseConsoleConfigurationPreferences.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/EclipseConsoleConfigurationPreferences.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- EclipseConsoleConfigurationPreferences.java	15 Nov 2006 16:12:09 -0000	1.9
  +++ EclipseConsoleConfigurationPreferences.java	10 Dec 2006 01:59:03 -0000	1.10
  @@ -104,7 +104,7 @@
   		try {
   			IJavaProject project = ProjectUtils.findJavaProject( getProjectName() );
   			String[] additonal = new String[0];
  -			if(useProjectClasspath() && project.exists()) {
  +			if(project != null && useProjectClasspath() && project.exists()) {
   				try {
   					additonal = JavaRuntime.computeDefaultRuntimeClassPath(project);
   				}
  
  
  


From scott.stark at jboss.com  Sat Dec  9 22:34:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:34:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity - New directory ...
Message-ID: <E1GtFSc-0007W0-S2@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:34:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/velocity added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:34:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:34:50 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity/velocity - New
	directory ...
Message-ID: <E1GtFSk-0007W9-Th@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:34:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/velocity/velocity added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:34:57 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:34:57 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity/velocity-dep - New
	directory ...
Message-ID: <E1GtFSr-0007WI-Dp@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:34:57

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/velocity/velocity-dep added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:35:07 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:35:07 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity/velocity-dep/1.4 -
	New directory ...
Message-ID: <E1GtFT1-0007XD-8J@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:35:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/velocity/velocity-dep/1.4 added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:35:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:35:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity/velocity/1.4 - New
	directory ...
Message-ID: <E1GtFTa-0007YO-ED@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:35:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/velocity/velocity/1.4 added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:40:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:40:09 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity/velocity/1.4 ...
Message-ID: <E1GtFXt-0007dI-Da@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:40:09

  Added:       maven2/velocity/velocity/1.4     velocity-1.4.jar
                        velocity-1.4.jar.sha1 velocity-1.4.pom
                        velocity-1.4.pom.sha1
  Log:
  Add velocity to the maven rep
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity/1.4/velocity-1.4.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity/1.4/velocity-1.4.jar.sha1
  
  Index: velocity-1.4.jar.sha1
  ===================================================================
  936d56c82103644ef042139d9e796cc0cf8edc32
  
  
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity/1.4/velocity-1.4.pom
  
  Index: velocity-1.4.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>velocity</groupId>
    <artifactId>velocity</artifactId>
    <name>Velocity</name>
    <version>1.4</version>
    <description>Velocity is a Java-based template engine. It permits anyone to use the
      simple yet powerful template language to reference objects defined in Java
      code.</description>
    <url>http://jakarta.apache.org/velocity/</url>
    <issueManagement>
      <url>http://nagoya.apache.org/scarab/servlet/scarab/</url>
    </issueManagement>
    <inceptionYear>2000</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven User List</name>
        <subscribe>velocity-user-subscribe at jakarta.apache.org</subscribe>
        <unsubscribe>velocity-user-unsubscribe at jakarta.apache.org</unsubscribe>
        <archive>http://www.mail-archive.com/velocity-user at jakarta.apache.org/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Developer List</name>
        <subscribe>velocity-dev-subscribe at jakarta.apache.org</subscribe>
        <unsubscribe>velocity-dev-unsubscribe at jakarta.apache.org</unsubscribe>
        <archive>http://www.mail-archive.com/velocity-dev at jakarta.apache.org/</archive>
      </mailingList>
    </mailingLists>
    <scm>
      <connection>scm:cvs:pserver:anoncvs at cvs.apache.org:/home/cvspublic:jakarta-velocity</connection>
      <url>http://cvs.apache.org/viewcvs/jakarta-turbine-maven/</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://jakarta.apache.org/</url>
    </organization>
    <dependencies>
      <dependency>
        <groupId>velocity</groupId>
        <artifactId>velocity-dep</artifactId>
        <version>1.4</version>
        <scope>runtime</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <repository>
        <id>default</id>
        <name>Default Repository</name>
        <url>file:///www/jakarta.apache.org/builds/jakarta-velocity/</url>
      </repository>
      <site>
        <id>default</id>
        <name>Default Site</name>
        <url>scp://jakarta.apache.org//www/jakarta.apache.org/velocity/</url>
      </site>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity/1.4/velocity-1.4.pom.sha1
  
  Index: velocity-1.4.pom.sha1
  ===================================================================
  f830f9e77a84c1d46e9f29865a46a52791eb583b  /home/projects/maven/repository-staging/to-ibiblio/maven2/velocity/velocity/1.4/velocity-1.4.pom
  
  
  


From scott.stark at jboss.com  Sat Dec  9 22:40:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:40:09 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/velocity/velocity-dep/1.4 ...
Message-ID: <E1GtFXt-0007dc-HC@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:40:09

  Added:       maven2/velocity/velocity-dep/1.4     velocity-dep-1.4.jar
                        velocity-dep-1.4.jar.sha1 velocity-dep-1.4.pom
                        velocity-dep-1.4.pom.sha1
  Log:
  Add velocity to the maven rep
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.jar.sha1
  
  Index: velocity-dep-1.4.jar.sha1
  ===================================================================
  b1df5193d3dd66a310b32828c547cd9e163b98df
  
  
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.pom
  
  Index: velocity-dep-1.4.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>velocity</groupId>
    <artifactId>velocity-dep</artifactId>
    <name>Velocity</name>
    <version>1.4</version>
    <description>Velocity is a Java-based template engine. It permits anyone to use the
      simple yet powerful template language to reference objects defined in Java
      code.</description>
    <url>http://jakarta.apache.org/velocity/</url>
    <issueManagement>
      <url>http://nagoya.apache.org/scarab/servlet/scarab/</url>
    </issueManagement>
    <inceptionYear>2000</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven User List</name>
        <subscribe>velocity-user-subscribe at jakarta.apache.org</subscribe>
        <unsubscribe>velocity-user-unsubscribe at jakarta.apache.org</unsubscribe>
        <archive>http://www.mail-archive.com/velocity-user at jakarta.apache.org/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Developer List</name>
        <subscribe>velocity-dev-subscribe at jakarta.apache.org</subscribe>
        <unsubscribe>velocity-dev-unsubscribe at jakarta.apache.org</unsubscribe>
        <archive>http://www.mail-archive.com/velocity-dev at jakarta.apache.org/</archive>
      </mailingList>
    </mailingLists>
    <scm>
      <connection>scm:cvs:pserver:anoncvs at cvs.apache.org:/home/cvspublic:jakarta-velocity</connection>
      <url>http://cvs.apache.org/viewcvs/jakarta-turbine-maven/</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://jakarta.apache.org/</url>
    </organization>
    <distributionManagement>
      <repository>
        <id>default</id>
        <name>Default Repository</name>
        <url>file:///www/jakarta.apache.org/builds/jakarta-velocity/</url>
      </repository>
      <site>
        <id>default</id>
        <name>Default Site</name>
        <url>scp://jakarta.apache.org//www/jakarta.apache.org/velocity/</url>
      </site>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 03:40:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.pom.sha1
  
  Index: velocity-dep-1.4.pom.sha1
  ===================================================================
  67a0b19882a361a3a8bc7b2e8896ed48715ffb9c  /home/projects/maven/repository-staging/to-ibiblio/maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.pom
  
  
  


From scott.stark at jboss.com  Sat Dec  9 22:40:36 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:40:36 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/classworlds - New directory
	...
Message-ID: <E1GtFYK-0007eP-ON@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:40:36

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/classworlds added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:40:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:40:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/classworlds/classworlds - New
	directory ...
Message-ID: <E1GtFYQ-0007ee-7w@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:40:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/classworlds/classworlds added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:40:48 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:40:48 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/classworlds/classworlds/1.1-alpha-2
	- New directory ...
Message-ID: <E1GtFYW-0007et-Fe@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:40:48

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/classworlds/classworlds/1.1-alpha-2 added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:41:20 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:41:20 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/classworlds/classworlds/1.1-alpha-2 ...
Message-ID: <E1GtFZ2-0007gO-K0@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:41:20

  Added:       maven2/classworlds/classworlds/1.1-alpha-2  
                        classworlds-1.1-alpha-2.pom
                        classworlds-1.1-alpha-2.pom.sha1
  Log:
  Add classworlds to the maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 03:41:20;  author: starksm;  state: Exp;repository.jboss.com/maven2/classworlds/classworlds/1.1-alpha-2/classworlds-1.1-alpha-2.pom
  
  Index: classworlds-1.1-alpha-2.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>classworlds</groupId>
    <artifactId>classworlds</artifactId>
    <name>classworlds</name>
    <version>1.1-alpha-2</version>
    <description></description>
    <url>http://classworlds.codehaus.org/</url>
    <ciManagement>
      <notifiers>
        <notifier>
          <address>classworlds-scm at lists.codehaus.org</address>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2002</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>classworlds users</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/classworlds-user</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/classworlds-user</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/classworlds-user/</archive>
      </mailingList>
      <mailingList>
        <name>classworlds developers</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/classworlds-dev</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/classworlds-dev</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/classworlds-dev/</archive>
      </mailingList>
      <mailingList>
        <name>classworlds commit messages</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/classworlds-scm</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/classworlds-scm</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/classworlds-scm/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>bob</id>
        <name>bob mcwhirter</name>
        <email>bob at werken.com</email>
        <organization>The Werken Company</organization>
        <roles>
          <role>Founder</role>
        </roles>
      </developer>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at zenplex.com</email>
        <organization>Zenplex</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>bwalding</id>
        <name>Ben Walding</name>
        <email>ben at walding.com</email>
        <organization>Walding Consulting Services</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <scm>
      <connection>scm:cvs:pserver:anonymous at cvs.codehaus.org:/scm/cvspublic/:classworlds</connection>
      <url>http://cvs.classworlds.codehaus.org/</url>
    </scm>
    <organization>
      <name>The Codehaus</name>
      <url>http://codehaus.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/java/main</sourceDirectory>
      <testSourceDirectory>src/java/test</testSourceDirectory>
      <plugins>
        <plugin>
          <artifactId>maven-surefire-plugin</artifactId>
          <configuration>
            <includes>
              <include>**/*Test.java</include>
            </includes>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <distributionManagement>
      <site>
        <id>default</id>
        <name>Default Site</name>
        <url>scp://classworlds.codehaus.org//www/classworlds.codehaus.org</url>
      </site>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 03:41:20;  author: starksm;  state: Exp;repository.jboss.com/maven2/classworlds/classworlds/1.1-alpha-2/classworlds-1.1-alpha-2.pom.sha1
  
  Index: classworlds-1.1-alpha-2.pom.sha1
  ===================================================================
  8c8ad6a96a8c1168f8b12ec8a227b8261b160b26  /home/projects/maven/repository-staging/to-ibiblio/maven2/classworlds/classworlds/1.1-alpha-2/classworlds-1.1-alpha-2.pom
  
  
  


From scott.stark at jboss.com  Sat Dec  9 22:41:51 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:41:51 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/oro - New directory ...
Message-ID: <E1GtFZX-0007hx-9o@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:41:51

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/oro added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:42:03 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:42:03 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/oro/oro - New directory ...
Message-ID: <E1GtFZj-0007i6-BP@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:42:03

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/oro/oro added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:42:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:42:09 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/oro/oro/2.0.7 - New directory
	...
Message-ID: <E1GtFZp-0007iF-Ay@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:42:09

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/oro/oro/2.0.7 added to the repository


From scott.stark at jboss.com  Sat Dec  9 22:42:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:42:40 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/oro/oro/2.0.7     ...
Message-ID: <E1GtFaK-0007ig-1u@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:42:40

  Added:       maven2/oro/oro/2.0.7     oro-2.0.7.jar oro-2.0.7.jar.sha1
                        oro-2.0.7.pom oro-2.0.7.pom.sha1
  Log:
  Add oro to the maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 03:42:40;  author: starksm;  state: Exp;repository.jboss.com/maven2/oro/oro/2.0.7/oro-2.0.7.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 03:42:40;  author: starksm;  state: Exp;repository.jboss.com/maven2/oro/oro/2.0.7/oro-2.0.7.jar.sha1
  
  Index: oro-2.0.7.jar.sha1
  ===================================================================
  f91d4528652d713faa54039b26af468a1229328b
  
  
  1.1      date: 2006/12/10 03:42:40;  author: starksm;  state: Exp;repository.jboss.com/maven2/oro/oro/2.0.7/oro-2.0.7.pom
  
  Index: oro-2.0.7.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>oro</groupId>
    <artifactId>oro</artifactId>
    <version>2.0.7</version>
  </project>
  
  
  
  1.1      date: 2006/12/10 03:42:40;  author: starksm;  state: Exp;repository.jboss.com/maven2/oro/oro/2.0.7/oro-2.0.7.pom.sha1
  
  Index: oro-2.0.7.pom.sha1
  ===================================================================
  78fe2b1a1ea27c33f84863be980ca1398f341696  /home/projects/maven/repository-staging/to-ibiblio/maven2/oro/oro/2.0.7/oro-2.0.7.pom
  
  
  


From scott.stark at jboss.com  Sat Dec  9 22:44:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 22:44:49 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/junit/junit/3.8.1   ...
Message-ID: <E1GtFcP-0007jI-8c@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 22:44:49

  Added:       maven2/junit/junit/3.8.1   junit-3.8.1.jar.md5
                        junit-3.8.1.pom.md5
  Log:
  Add junit to the maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 03:44:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/junit/junit/3.8.1/junit-3.8.1.jar.md5
  
  Index: junit-3.8.1.jar.md5
  ===================================================================
  1f40fb782a4f2cf78f161d32670f7a3a  ./maven2/junit/junit/3.8.1/junit-3.8.1.jar
  
  
  
  1.1      date: 2006/12/10 03:44:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/junit/junit/3.8.1/junit-3.8.1.pom.md5
  
  Index: junit-3.8.1.pom.md5
  ===================================================================
  c507d8ea44f2eebfc8106e03416f8fae  ./maven2/junit/junit/3.8.1/junit-3.8.1.pom
  
  
  


From scott.stark at jboss.com  Sat Dec  9 23:27:38 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 23:27:38 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/com/jcraft - New directory ...
Message-ID: <E1GtGHq-00006T-NJ@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 23:27:38

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/com/jcraft added to the repository


From scott.stark at jboss.com  Sat Dec  9 23:31:31 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 23:31:31 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/doxia - New directory ...
Message-ID: <E1GtGLb-00009r-Ji@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 23:31:31

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/doxia added to the repository


From scott.stark at jboss.com  Sat Dec  9 23:33:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 23:33:50 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/commons-cli - New directory
	...
Message-ID: <E1GtGNq-0000Bx-2t@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 23:33:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/commons-cli added to the repository


From scott.stark at jboss.com  Sat Dec  9 23:33:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 23:33:50 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/commons-collections - New
	directory ...
Message-ID: <E1GtGNq-0000C2-5Q@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 23:33:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/commons-collections added to the repository


From scott.stark at jboss.com  Sat Dec  9 23:33:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sat, 09 Dec 2006 23:33:50 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/commons-lang - New directory
	...
Message-ID: <E1GtGNq-0000C8-9W@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/09 23:33:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/commons-lang added to the repository


From scott.stark at jboss.com  Sun Dec 10 00:00:17 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 00:00:17 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA -
	New directory ...
Message-ID: <E1GtGnR-0000Zn-C0@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 00:00:17

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA added to the repository


From scott.stark at jboss.com  Sun Dec 10 00:00:34 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 00:00:34 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA -
	New directory ...
Message-ID: <E1GtGni-0000aZ-P9@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 00:00:34

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA added to the repository


From scott.stark at jboss.com  Sun Dec 10 00:01:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 00:01:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA
	- New directory ...
Message-ID: <E1GtGo8-0000bV-Ik@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 00:01:00

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA added to the repository


From scott.stark at jboss.com  Sun Dec 10 00:01:22 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 00:01:22 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA -
	New directory ...
Message-ID: <E1GtGoU-0000cU-IF@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 00:01:22

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA added to the repository


From scott.stark at jboss.com  Sun Dec 10 00:12:36 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 00:12:36 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/common-core/2.0.3.GA/lib ...
Message-ID: <E1GtGzM-0000zy-Hb@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 00:12:36

  Modified:    jboss/common-core/2.0.3.GA/lib  
                        jboss-common-core-sources.jar jboss-common-core.jar
  Log:
  Create a proper 2.0.3.GA release from the https://svn.jboss.org/repos/common/common-core/tags/2.0.3.GA/
  
  Revision  Changes    Path
  1.2       +2310 -2286repository.jboss.com/jboss/common-core/2.0.3.GA/lib/jboss-common-core-sources.jar
  
  	<<Binary file>>
  
  
  1.2       +743 -739  repository.jboss.com/jboss/common-core/2.0.3.GA/lib/jboss-common-core.jar
  
  	<<Binary file>>
  
  


From forge-admin at jboss.com  Sun Dec 10 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sun, 10 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GtHjg-0001id-5X@committer01.frg.pub.inap.atl.jboss.com>

Commit from mandersen (2006-12-09 07:21 EST)
---------------------

fix multi named uniqueconstraint gen bug

  jboss-seam  seam-gen/lib/hibernate-tools.jar  1.5


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-09 10:14 EST)
------------------------------------------------------

Temporarily disabled anycast

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.32


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-09 10:14 EST)
------------------------------------------------------

Refactored for more correct behaviour

  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java  1.33.2.8


Commit from mandersen (2006-12-09 20:59 EST)
---------------------

HBX-834 NullPointerException in EclipseConsoleConfigurationPreferences

  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationWizardPage.java  1.26
  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/EclipseConsoleConfigurationPreferences.java  1.10


Commit from starksm (2006-12-09 22:40 EST)
-------------------

Add velocity to the maven rep

+ repository.jboss.com  maven2/velocity/velocity/1.4/velocity-1.4.jar               1.1
+ repository.jboss.com  maven2/velocity/velocity/1.4/velocity-1.4.jar.sha1          1.1
+ repository.jboss.com  maven2/velocity/velocity/1.4/velocity-1.4.pom               1.1
+ repository.jboss.com  maven2/velocity/velocity/1.4/velocity-1.4.pom.sha1          1.1
+ repository.jboss.com  maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.jar       1.1
+ repository.jboss.com  maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.jar.sha1  1.1
+ repository.jboss.com  maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.pom       1.1
+ repository.jboss.com  maven2/velocity/velocity-dep/1.4/velocity-dep-1.4.pom.sha1  1.1


Commit from starksm (2006-12-09 22:41 EST)
-------------------

Add classworlds to the maven repo

+ repository.jboss.com  maven2/classworlds/classworlds/1.1-alpha-2/classworlds-1.1-alpha-2.pom       1.1
+ repository.jboss.com  maven2/classworlds/classworlds/1.1-alpha-2/classworlds-1.1-alpha-2.pom.sha1  1.1


Commit from starksm (2006-12-09 22:42 EST)
-------------------

Add oro to the maven repo

+ repository.jboss.com  maven2/oro/oro/2.0.7/oro-2.0.7.jar       1.1
+ repository.jboss.com  maven2/oro/oro/2.0.7/oro-2.0.7.jar.sha1  1.1
+ repository.jboss.com  maven2/oro/oro/2.0.7/oro-2.0.7.pom       1.1
+ repository.jboss.com  maven2/oro/oro/2.0.7/oro-2.0.7.pom.sha1  1.1


Commit from starksm (2006-12-09 22:44 EST)
-------------------

Add junit to the maven repo

+ repository.jboss.com  maven2/junit/junit/3.8.1/junit-3.8.1.jar.md5  1.1
+ repository.jboss.com  maven2/junit/junit/3.8.1/junit-3.8.1.pom.md5  1.1


Commit from starksm (2006-12-10 00:12 EST)
-------------------

Create a proper 2.0.3.GA release from the https://svn.jboss.org/repos/common/common-core/tags/2.0.3.GA/

  repository.jboss.com  jboss/common-core/2.0.3.GA/lib/jboss-common-core-sources.jar  1.2
  repository.jboss.com  jboss/common-core/2.0.3.GA/lib/jboss-common-core.jar          1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061210/b0128fa3/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 07:14:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 07:14:06 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1752 - branches
Message-ID: <E1GtNZG-0008Rb-QU@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-10 07:14:05 -0500 (Sun, 10 Dec 2006)
New Revision: 1752

Removed:
   branches/Branch_1_0_XARecovery/
Log:
end of branch



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 07:38:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 07:38:07 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1753 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GtNwV-0000NO-Ao@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-10 07:37:08 -0500 (Sun, 10 Dec 2006)
New Revision: 1753

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Server side valve



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -26,10 +26,11 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+
 import javax.jms.JMSException;
+
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.aop.metadata.SimpleMetaData;
 import org.jboss.jms.client.delegate.ClientBrowserDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
@@ -47,6 +48,7 @@
 import org.jboss.jms.client.state.ProducerState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.destination.JBossDestination;
+import org.jboss.jms.server.endpoint.ConnectionStatus;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -67,7 +69,7 @@
  */
 public class HAAspect
 {
-   private static final Logger log = Logger.getLogger(ConnectionAspect.class);
+   private static final Logger log = Logger.getLogger(HAAspect.class);
    
    private static boolean trace = log.isTraceEnabled();
    
@@ -161,8 +163,16 @@
       throws Exception
    {
       log.info("createConnection");
-      ClientConnectionDelegate connDelegate = (ClientConnectionDelegate)cf.createConnectionDelegate(username, password);
+      ClientConnectionDelegate connDelegate =
+         (ClientConnectionDelegate)cf.createConnectionDelegate(username, password);
       
+      initialiseConnection(connDelegate);
+      
+      return connDelegate;   
+   }
+   
+   private void initialiseConnection(ClientConnectionDelegate connDelegate)
+   {
       //Add a connection listener
       
       ConnectionState state = (ConnectionState)((DelegateSupport)connDelegate).getState();
@@ -170,8 +180,6 @@
       ConnectionListener listener = new Listener(connDelegate);
       
       state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
-      
-      return connDelegate;   
    }
 
    
@@ -186,27 +194,46 @@
       
       ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
       
-      log.info("*** about to failover - waiting for server to finish");
+      log.info("Failing over connection");
       
-      //FIXME - this is only temporarily necessary since we need to give the server enough time to
-      //failover before we reconnect - this would be handled by the server side valve
-      Thread.sleep(10000);
-
-      log.info("Creating new connection");
-      ClientConnectionDelegate newConnection = createConnection(newCF, state.getUser(), state.getPassword());
-      log.info("Created new connection");
+      ConnectionStatus status =
+         newCF.createFailoverConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
       
-//      try
-//      {
+      log.info("returned from createFailoverConnectionDelegate");
+                  
+      if (status.getDelegate() != null)
+      {
+         log.info("Got connection");
+         
+         ClientConnectionDelegate newConnection = (ClientConnectionDelegate)state.getDelegate();
+         
+         //We got the right server and created a new connection
+         
          failover(failedConnection, newConnection);
-//      }
-//      catch (Throwable t)
-//      {
-//         //TODO
-//         //If failover itself fails, we shouldn't give up, we should try the next one in the list
-//         //etc until we find one that works
-//         //TODO
-//      }
+      }
+      else
+      {
+         if (status.getActualFailoverNode() == -1)
+         {
+            //No trace of failover was detected on the server side - this might happen if the client side
+            //network fails temporarily so the client connection breaks but the server side network is still
+            //up and running - in this case we want to retry back on the original server
+            
+            //TODO TODO TODO
+            
+            log.info("No failover is occurring on server side");
+                        
+         }
+         else
+         {
+            //Server side failover has occurred / is occurring but we tried the wrong node
+            //Now we must try the correct node
+            
+            //TODO TODO TODO
+            
+            log.info("*** Got wrong server!");
+         }
+      }
    }
    
    private ClientConnectionFactoryDelegate getFailoverDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
@@ -277,6 +304,8 @@
    private void failover(ClientConnectionDelegate failedConnection, ClientConnectionDelegate newConnection) throws Exception
    {
       if (trace) { log.trace("calling handleFailover"); }
+      
+      log.info("performing failover");
 
       ConnectionState failedState = (ConnectionState)failedConnection.getState();
 
@@ -346,7 +375,7 @@
             }
          }
       }
-      log.info("Failedover done");
+      log.info("Failover done");
    }
 
    private void handleFailoverOnConsumer(ClientConnectionDelegate connectionDelegate,

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -36,6 +36,7 @@
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
+import org.jboss.jms.server.endpoint.ConnectionStatus;
 import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.server.remoting.MetaDataConstants;
@@ -128,6 +129,16 @@
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
+   
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
+      throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
 
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -21,15 +21,18 @@
   */
 package org.jboss.jms.server;
 
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
 import java.io.ByteArrayOutputStream;
 import java.io.InputStream;
+import java.io.Serializable;
 import java.net.URL;
+import java.util.Iterator;
 import java.util.Map;
 import java.util.Set;
+
 import javax.management.Attribute;
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
+
 import org.jboss.aop.AspectXmlLoader;
 import org.jboss.jms.server.connectionfactory.ConnectionFactoryJNDIMapper;
 import org.jboss.jms.server.connectionmanager.SimpleConnectionManager;
@@ -47,7 +50,10 @@
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
+import org.jboss.messaging.core.plugin.contract.ReplicationListener;
 import org.jboss.messaging.core.plugin.contract.Replicator;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.FailoverStatus;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.Util;
 import org.jboss.mx.loading.UnifiedClassLoader3;
@@ -57,6 +63,8 @@
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
 
+import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
+
 /**
  * A JMS server peer.
  *
@@ -95,6 +103,8 @@
 
    private int objectIDSequence = 1;
    
+   private Object failoverStatusLock;
+      
    // wired components
 
    private DestinationJNDIMapper destinationJNDIMapper;
@@ -150,6 +160,8 @@
       consumers = new ConcurrentReaderHashMap();
 
       version = Version.instance();
+      
+      failoverStatusLock = new Object();
 
       started = false;
    }
@@ -610,10 +622,14 @@
          //We also inject the replicator dependency into the ConnectionFactoryJNDIMapper
          //This is a bit messy but we have a circular dependency
          //POJOContainer should be able to help us here
+         //Yes, this is nasty
          
          if (!queuePostOffice.isLocal())
          {
-            connFactoryJNDIMapper.injectReplicator((Replicator)queuePostOffice);
+            Replicator rep = (Replicator)queuePostOffice;
+            connFactoryJNDIMapper.injectReplicator(rep);
+            rep.registerListener(new FailoverListener());
+            
          }
       }
       return queuePostOffice;
@@ -656,7 +672,131 @@
    {
       return queuedExecutorPool;
    }
-
+   
+   /*
+    * Wait for failover from the specified node to complete
+    */
+   public int waitForFailover(int failedNodeId) throws Exception
+   {
+      //This node may be failing over for another node - in which case we must wait for that to be complete
+      
+      log.info("Waiting for failover for failedNodeId: " + failedNodeId);
+      
+      Replicator replicator = getReplicator();
+      
+      //TODO - these must be configurable
+      final long FAILOVER_START_TIMEOUT = 15000;
+      
+      final long FAILOVER_COMPLETE_TIMEOUT = 25000;
+      
+      long startToWait = FAILOVER_START_TIMEOUT;
+      
+      long completeToWait = FAILOVER_COMPLETE_TIMEOUT;
+                     
+      //Must lock here
+      synchronized (failoverStatusLock)
+      {         
+         while (true)
+         {         
+            //TODO we shouldn't have a dependency on DefaultClusteredPostOffice - where should we put the constants?
+            Map replicants = replicator.get(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY);
+            
+            log.info("Got replicants");
+            
+            boolean foundEntry = false;
+                        
+            if (replicants != null)
+            {
+               Iterator iter = replicants.entrySet().iterator();
+               
+               while (iter.hasNext())
+               {
+                  Map.Entry entry = (Map.Entry)iter.next();
+                  
+                  Integer nid = (Integer)entry.getKey();
+                  
+                  FailoverStatus status = (FailoverStatus)entry.getValue();
+                  
+                  if (status.isFailedOverForNode(failedNodeId))
+                  {
+                     log.info("Fail over is complete on node " + nid);
+                     //Got the node - failover has completed
+                     return nid.intValue();  
+                  }
+                  else if (status.isFailingOverForNode(failedNodeId))
+                  {
+                     log.info("Fail over is in progress on node " + nid);
+                     
+                     //A server has started failing over for the failed node, but not completed
+                     //if it's not this node then we immediately return so the connection can be redirected to
+                     //another node
+                     if (nid.intValue() != this.getServerPeerID())
+                     {
+                        return nid.intValue();
+                     }
+                     
+                     //Otherwise we wait for failover to complete
+                     
+                     if (completeToWait <= 0)
+                     {
+                        //Give up now
+                        log.info("Already waited long enough for failover to complete, giving up");
+                        return -1;
+                     }
+                     
+                     //Note - we have to count the time since other unrelated nodes may fail and wake
+                     //up the lock - in this case we don't want to give up too early
+                     long start = System.currentTimeMillis();       
+                     try
+                     {
+                        log.info("Waiting for failover to complete");
+                        failoverStatusLock.wait(completeToWait);
+                     }
+                     catch (InterruptedException ignore)
+                     {                  
+                     }
+                     completeToWait -= System.currentTimeMillis() - start;
+                    
+                     foundEntry = true;
+                  }
+               }        
+            }
+            
+            if (!foundEntry)
+            {              
+               //No trace of failover happening
+               //so we wait a maximum of FAILOVER_START_TIMEOUT for some replicated data to arrive
+               //This should arrive fairly quickly since this is added at the beginning of the failover process
+               //If it doesn't arrive it would imply that no failover has actually happened on the server
+               //or the timeout is too short.
+               //It is possible that no failover has actually happened on the server, if for example there
+               //is a problem with the client side network but the server side network is ok.
+   
+               if (startToWait <= 0)
+               {
+                  //Don't want to wait again
+                  log.info("Already waited long enough for failover to start, giving up");
+                  return -1;
+               }
+               
+               //Note - we have to count the time since other unrelated nodes may fail and wake
+               //up the lock - in this case we don't want to give up too early
+               long start = System.currentTimeMillis(); 
+               try
+               {
+                  log.info("Waiting for failover to start");
+                  failoverStatusLock.wait(startToWait);
+                  log.info("Finished waiting for failover to start");
+               }
+               catch (InterruptedException ignore)
+               {                  
+               }
+               startToWait -= System.currentTimeMillis() - start;              
+            }
+         }        
+      }
+   }
+   
    public String toString()
    {
       return "ServerPeer [" + getServerPeerID() + "]";
@@ -907,5 +1047,23 @@
    }
 
    // Inner classes -------------------------------------------------
+   
+   private class FailoverListener implements ReplicationListener
+   {
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added, int originatingNodeId)
+      {
+         if (key.equals(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY))
+         {
+            //We have a failover status change - notify anyone waiting
+            
+            log.info("Got replication change on failed over map, notifying those waiting on lock");
+            
+            synchronized (failoverStatusLock)
+            {
+               failoverStatusLock.notifyAll();
+            }
+         }
+      }      
+   }
 
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -40,6 +40,9 @@
    ConnectionDelegate createConnectionDelegate(String username, String password)
       throws JMSException;
    
+   ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
+      throws JMSException;
+   
    byte[] getClientAOPConfig() throws JMSException;
 
    IdBlock getIdBlock(int size) throws JMSException;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -93,43 +93,81 @@
    }
 
    // ConnectionFactoryDelegate implementation ----------------------
-
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
-      throws JMSException
+   
+   /**
+    * Called when a new connection is to be created for failover
+    * The ConnectionStatus instance returns either contains the delegate or the node id of the actual node
+    * Note we cannot query the failover node in a separate call since that might change between
+    * querying it and actually creating the delegate
+    */
+   public ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
+      throws JMSException      
    {
       try
       {
-         log.debug("creating a new connection for user " + username);
+         //Wait for server side failover to complete
+         int failoverNodeId = serverPeer.waitForFailover(failedNodeId);
+         
+         if (failoverNodeId == -1 || failoverNodeId != serverPeer.getServerPeerID())
+         {
+            //We are on the wrong node - or no failover has occurred
+            return new ConnectionStatus(failoverNodeId);
+         }
+         else
+         {
+            //We are on the right node, and failover has completed
+            //we can now create a connection delegate
+            return new ConnectionStatus(createConnectionDelegateInternal(username, password));
+         }
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " createFailoverConnectionDelegate");
+      }
+      
+   }
+   
+   private ConnectionDelegate createConnectionDelegateInternal(String username, String password) throws Exception
+   {
+      log.debug("creating a new connection for user " + username);        
 
-         // authenticate the user
-         serverPeer.getSecurityManager().authenticate(username, password);
+      // authenticate the user
+      serverPeer.getSecurityManager().authenticate(username, password);
 
-         // see if there is a preconfigured client id for the user
-         if (username != null)
+      // see if there is a preconfigured client id for the user
+      if (username != null)
+      {
+         String preconfClientID =
+            serverPeer.getJmsUserManagerInstance().getPreConfiguredClientID(username);
+
+         if (preconfClientID != null)
          {
-            String preconfClientID =
-               serverPeer.getJmsUserManagerInstance().getPreConfiguredClientID(username);
-
-            if (preconfClientID != null)
-            {
-               clientID = preconfClientID;
-            }
+            clientID = preconfClientID;
          }
+      }
 
-         // create the corresponding "server-side" connection endpoint and register it with the
-         // server peer's ClientManager
-         ServerConnectionEndpoint endpoint =
-            new ServerConnectionEndpoint(serverPeer, clientID, username, password, prefetchSize,
-                     defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
+      // create the corresponding "server-side" connection endpoint and register it with the
+      // server peer's ClientManager
+      ServerConnectionEndpoint endpoint =
+         new ServerConnectionEndpoint(serverPeer, clientID, username, password, prefetchSize,
+                  defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
 
-         int connectionID = endpoint.getConnectionID();
+      int connectionID = endpoint.getConnectionID();
 
-         ConnectionAdvised connAdvised = new ConnectionAdvised(endpoint);
-         JMSDispatcher.instance.registerTarget(new Integer(connectionID), connAdvised);
+      ConnectionAdvised connAdvised = new ConnectionAdvised(endpoint);
+      JMSDispatcher.instance.registerTarget(new Integer(connectionID), connAdvised);
 
-         log.debug("created and registered " + endpoint);
+      log.debug("created and registered " + endpoint);
 
-         return new ClientConnectionDelegate(connectionID, serverPeer.getServerPeerID());
+      return new ClientConnectionDelegate(connectionID, serverPeer.getServerPeerID());
+   }
+   
+   public ConnectionDelegate createConnectionDelegate(String username, String password)
+      throws JMSException
+   {
+      try
+      {
+         return createConnectionDelegateInternal(username, password);
       }
       catch (Throwable t)
       {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -24,6 +24,7 @@
 import javax.jms.JMSException;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint;
+import org.jboss.jms.server.endpoint.ConnectionStatus;
 import org.jboss.messaging.core.plugin.IdBlock;
 
 /**
@@ -62,6 +63,12 @@
    {
       return endpoint.createConnectionDelegate(username, password);
    }
+   
+   public ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
+      throws JMSException
+   {
+      return endpoint.createFailoverConnectionDelegate(username, password, failedNodeId);
+   }
 
    public byte[] getClientAOPConfig() throws JMSException
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -82,6 +82,7 @@
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -95,6 +96,9 @@
    // Key for looking up node id -> address info mapping from replicated data
    public static final String ADDRESS_INFO_KEY = "address_info";
    
+   // Key for looking up node id -> failed over for node id mapping from replicated data
+   public static final String FAILED_OVER_FOR_KEY = "failed_over_for";
+   
    //Used for failure testing
    private boolean failBeforeCommit;
    
@@ -125,7 +129,7 @@
       
    private Map holdingArea;
    
-   //Map < node, failover node>
+   //Map < node id , failover node id>
    private Map failoverMap;
    
    private Set leftSet;
@@ -1359,31 +1363,56 @@
    }
    
    /**
-    * This method fails over all the queues from node <nodeId> onto this node
+    * This method fails over all the queues from node <failedNodeId> onto this node
     * It is triggered when a JGroups view change occurs due to a member leaving and 
     * it's determined the member didn't leave cleanly
     * 
-    * @param nodeId
+    * @param failedNodeId
     * @throws Exception
     */
-   private void failOver(int nodeId) throws Exception
+   private void failOver(int failedNodeId) throws Exception
    {
-      // todo - remove this log.info before merging into trunk
-      log.info("Preparing failover against node " + nodeId);
-      
       //Need to lock
-      lock.writeLock().acquire();
+      lock.writeLock().acquire();            
 
       try
       {
-         log.info("Preparing failover against node " + nodeId);
+         log.info("Preparing failover against node " + failedNodeId);
          
+         /*
+         We make sure a FailoverStatus object is put in the replicated data for the node
+         The real failover node will always add this in.
+         This means that each node knows which node has really started the failover for another node, and
+         which node did failover for other nodes in the past
+         We cannot rely on the failoverMap for this, since that will regenerated once failover is done,
+         because of the change in membership.
+         And clients may failover after that and need to know if they have the correct node.
+         Since this is the first thing we do after detecting failover, it should be very quick that
+         all nodes know, however there is still a chance that a client tries to failover before
+         the information is replicated.                  
+         */
+         
+         Map replicants = (Map)get(FAILED_OVER_FOR_KEY);
+         
+         FailoverStatus status = (FailoverStatus)replicants.get(new Integer(currentNodeId));
+         
+         if (status == null)
+         {
+            status = new FailoverStatus();            
+         }
+         
+         status.startFailingOverForNode(failedNodeId);
+         
+         put(FAILED_OVER_FOR_KEY, status);
+         
+         log.info("Put into failed over map that starting failover");
+         
          //Get the map of queues for the failed node
          
-         Map subMaps = (Map)nameMaps.get(new Integer(nodeId));
+         Map subMaps = (Map)nameMaps.get(new Integer(failedNodeId));
          if (subMaps==null || subMaps.size()==0)
          {
-            log.warn("Couldn't find any binding to failOver from serverId=" +nodeId);
+            log.warn("Couldn't find any binding to failOver from serverId=" +failedNodeId);
             return;
          }
                   
@@ -1435,16 +1464,16 @@
             String queueName = (String)entry.getKey();
                         
             //First the binding is removed from the in memory condition and name maps
-            this.removeBinding(nodeId, queueName);
+            this.removeBinding(failedNodeId, queueName);
 
             //Then deleted from the database
-            this.deleteBinding(nodeId, queueName);
+            this.deleteBinding(failedNodeId, queueName);
             
             log.info("deleted binding for " + queueName);
 
             //Then an unbind request is sent - this cause other nodes to also remove it from the in memory
             //condition and name maps
-            UnbindRequest unbindRequest = new UnbindRequest(nodeId, queueName);
+            UnbindRequest unbindRequest = new UnbindRequest(failedNodeId, queueName);
             
             syncSendRequest(unbindRequest);
 
@@ -1498,6 +1527,13 @@
             //lost from the database when the server is resurrected.
             //To remedy, both db operations need to be done in the same JBDC tx
          }
+         
+         log.info("Server side fail over is now complete");
+         
+         //TODO - should this be in a finally? I'm not sure
+         status.finishFailingOver();
+         
+         put(FAILED_OVER_FOR_KEY, status);
       }
       finally
       {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-10 12:14:05 UTC (rev 1752)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-10 12:37:08 UTC (rev 1753)
@@ -74,349 +74,349 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-   public void testRoundRobinConnectionCreation() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      log.info ("number of delegates = " + delegate.getDelegates().length);
-      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      assertEquals(3, delegate.getDelegates().length);
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-      
-      Connection conn4 = null;
-      
-      Connection conn5 = null;
-      
-      try
-      {         
-         conn1 = factory.createConnection();
-         
-         conn2 = factory.createConnection();
-         
-         conn3 = factory.createConnection();
-         
-         conn4 = factory.createConnection();
-         
-         conn5 = factory.createConnection();
-         
-         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
-         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
-         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
-         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
-         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
-         int serverID1 = state1.getServerID();
-         
-         int serverID2 = state2.getServerID();
-         
-         int serverID3 = state3.getServerID();
-         
-         int serverID4 = state4.getServerID();
-         
-         int serverID5 = state5.getServerID();
-         
-         log.info("server id 1: " + serverID1);
-         
-         log.info("server id 2: " + serverID2);
-         
-         log.info("server id 3: " + serverID3);
-         
-         log.info("server id 4: " + serverID4);
-         
-         log.info("server id 5: " + serverID5);
-         
-         assertEquals(0, serverID1);
-         
-         assertEquals(1, serverID2);
-         
-         assertEquals(2, serverID3);
-         
-         assertEquals(0, serverID4);
-         
-         assertEquals(1, serverID5);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-         
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-         
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-         
-         if (conn4 != null)
-         {
-            conn4.close();
-         }
-         
-         if (conn5 != null)
-         {
-            conn5.close();
-         }
-      }
-      
-   }
- 
-   /*
-    * Test that the failover mapping is created correctly and updated properly when nodes leave
-    * or join
-    */
-   public void testDefaultFailoverMap() throws Exception
-   {     
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         //The order here depends on the order the servers were started in
-         
-         //If any servers get stopped and then started then the order will change
-    
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         
-         assertEquals(0, cf1.getServerId());
-         
-         assertEquals(1, cf2.getServerId());
-         
-         assertEquals(2, cf3.getServerId());
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(3, delegates.length);
-         
-         assertEquals(3, failoverMap.size());
-         
-         // Default failover policy just chooses the node to the right
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }
-      
-      //Now cleanly stop one of the servers
-      
-      
-      log.info("************** STOPPING SERVER 0");
-      ServerManagement.stop(0, true);
-      
-      log.info("server stopped");
-      
-      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         //Order here depends on order servers were started in
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(1, cf1.getServerId());
-         
-         assertEquals(2, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      //Cleanly stop another server
-      
-      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
-      ServerManagement.stop(1, true);
-      
-      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(1, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         assertEquals(2, cf1.getServerId());
-         
-         
-         assertEquals(1, failoverMap.size());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      }
-            
-      //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      
-      //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(3, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         assertEquals(1, cf3.getServerId());
-         
-         
-         assertEquals(3, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }            
-   }
+//   public void testRoundRobinConnectionCreation() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//      
+//      log.info ("number of delegates = " + delegate.getDelegates().length);
+//      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//      
+//      assertEquals(3, delegate.getDelegates().length);
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//      
+//      assertEquals(0, cf1.getServerId());
+//      
+//      assertEquals(1, cf2.getServerId());
+//      
+//      assertEquals(2, cf3.getServerId());
+//      
+//      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//      
+//      Connection conn1 = null;
+//      
+//      Connection conn2 = null;
+//      
+//      Connection conn3 = null;
+//      
+//      Connection conn4 = null;
+//      
+//      Connection conn5 = null;
+//      
+//      try
+//      {         
+//         conn1 = factory.createConnection();
+//         
+//         conn2 = factory.createConnection();
+//         
+//         conn3 = factory.createConnection();
+//         
+//         conn4 = factory.createConnection();
+//         
+//         conn5 = factory.createConnection();
+//         
+//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+//         
+//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+//         
+//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+//         
+//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+//         
+//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+//         
+//         int serverID1 = state1.getServerID();
+//         
+//         int serverID2 = state2.getServerID();
+//         
+//         int serverID3 = state3.getServerID();
+//         
+//         int serverID4 = state4.getServerID();
+//         
+//         int serverID5 = state5.getServerID();
+//         
+//         log.info("server id 1: " + serverID1);
+//         
+//         log.info("server id 2: " + serverID2);
+//         
+//         log.info("server id 3: " + serverID3);
+//         
+//         log.info("server id 4: " + serverID4);
+//         
+//         log.info("server id 5: " + serverID5);
+//         
+//         assertEquals(0, serverID1);
+//         
+//         assertEquals(1, serverID2);
+//         
+//         assertEquals(2, serverID3);
+//         
+//         assertEquals(0, serverID4);
+//         
+//         assertEquals(1, serverID5);
+//      }
+//      finally
+//      {
+//         if (conn1 != null)
+//         {
+//            conn1.close();
+//         }
+//         
+//         if (conn2 != null)
+//         {
+//            conn2.close();
+//         }
+//         
+//         if (conn3 != null)
+//         {
+//            conn3.close();
+//         }
+//         
+//         if (conn4 != null)
+//         {
+//            conn4.close();
+//         }
+//         
+//         if (conn5 != null)
+//         {
+//            conn5.close();
+//         }
+//      }
+//      
+//   }
+// 
+//   /*
+//    * Test that the failover mapping is created correctly and updated properly when nodes leave
+//    * or join
+//    */
+//   public void testDefaultFailoverMap() throws Exception
+//   {     
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         //The order here depends on the order the servers were started in
+//         
+//         //If any servers get stopped and then started then the order will change
+//    
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         
+//         assertEquals(0, cf1.getServerId());
+//         
+//         assertEquals(1, cf2.getServerId());
+//         
+//         assertEquals(2, cf3.getServerId());
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         // Default failover policy just chooses the node to the right
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }
+//      
+//      //Now cleanly stop one of the servers
+//      
+//      
+//      log.info("************** STOPPING SERVER 0");
+//      ServerManagement.stop(0, true);
+//      
+//      log.info("server stopped");
+//      
+//      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         //Order here depends on order servers were started in
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(1, cf1.getServerId());
+//         
+//         assertEquals(2, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      //Cleanly stop another server
+//      
+//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+//      
+//      ServerManagement.stop(1, true);
+//      
+//      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(1, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         
+//         assertEquals(1, failoverMap.size());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//      }
+//            
+//      //Restart server 0
+//      
+//      ServerManagement.start("all", 0);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      
+//      //Restart server 1
+//      
+//      ServerManagement.start("all", 1);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         assertEquals(1, cf3.getServerId());
+//         
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }            
+//   }
    
    public void testSimpleFailover() throws Exception
    {
@@ -537,45 +537,45 @@
       }
       
    }
+//   
+//   public void testEvenSimplerFailover() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//                  
+//      Connection conn = null;
+//      
+//      try
+//      {
+//         conn = factory.createConnection();
+//                           
+//         log.info("************ KILLING (CRASHING) SERVER 0");
+//         
+//         ServerManagement.getServer(0).destroy();
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(25000);
+//         
+//         log.info("done wait");                
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
    
-   public void testEvenSimplerFailover() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-                  
-      Connection conn = null;
-      
-      try
-      {
-         conn = factory.createConnection();
-                           
-         log.info("************ KILLING (CRASHING) SERVER 0");
-         
-         ServerManagement.getServer(0).destroy();
-         
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(25000);
-         
-         log.info("done wait");                
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-      }
-      
-   }
    
-   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try



From gavin.king at jboss.com  Sun Dec 10 09:22:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 09:22:28 -0500
Subject: [jboss-cvs] jboss-seam/src/gen/org/jboss/seam/tool  ...
Message-ID: <E1GtPZU-0002JZ-G6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 09:22:28

  Modified:    src/gen/org/jboss/seam/tool  Util.java
  Log:
  JBSEAM-577 page params with no value binding
  
  Revision  Changes    Path
  1.2       +4 -1      jboss-seam/src/gen/org/jboss/seam/tool/Util.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Util.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/gen/org/jboss/seam/tool/Util.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Util.java	8 Nov 2006 03:55:28 -0000	1.1
  +++ Util.java	10 Dec 2006 14:22:28 -0000	1.2
  @@ -6,5 +6,8 @@
      {
         return name.substring(0, 1).toLowerCase() + name.substring(1);
      }
  -
  +   public String upper(String name)
  +   {
  +      return name.substring(0, 1).toUpperCase() + name.substring(1);
  +   }
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 10 09:22:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 09:22:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GtPZU-0002Jg-L0@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 09:22:28

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  JBSEAM-577 page params with no value binding
  
  Revision  Changes    Path
  1.5       +2 -2      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- pages-1.1.dtd	20 Nov 2006 20:31:16 -0000	1.4
  +++ pages-1.1.dtd	10 Dec 2006 14:22:28 -0000	1.5
  @@ -18,8 +18,8 @@
   <!ATTLIST page bundle CDATA #IMPLIED>
   
   <!ELEMENT param EMPTY>
  -<!ATTLIST param name CDATA #REQUIRED>
  -<!ATTLIST param value CDATA #REQUIRED>
  +<!ATTLIST param name CDATA #IMPLIED>
  +<!ATTLIST param value CDATA #IMPLIED>
   <!ATTLIST param converter CDATA #IMPLIED>
   <!ATTLIST param converterId CDATA #IMPLIED>
   
  
  
  


From gavin.king at jboss.com  Sun Dec 10 09:22:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 09:22:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GtPZU-0002Jq-Q7@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 09:22:28

  Modified:    src/main/org/jboss/seam/core   Page.java Pages.java
  Log:
  JBSEAM-577 page params with no value binding
  
  Revision  Changes    Path
  1.7       +4 -0      jboss-seam/src/main/org/jboss/seam/core/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Page.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- Page.java	27 Nov 2006 03:28:03 -0000	1.6
  +++ Page.java	10 Dec 2006 14:22:28 -0000	1.7
  @@ -39,6 +39,10 @@
            {
               return (Converter) converterValueBinding.getValue();
            }
  +         else if (valueBinding==null)
  +         {
  +            return null;
  +         }
            else
            {
               Class<?> type = valueBinding.getType();
  
  
  
  1.57      +63 -24    jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.56
  retrieving revision 1.57
  diff -u -b -r1.56 -r1.57
  --- Pages.java	27 Nov 2006 03:28:03 -0000	1.56
  +++ Pages.java	10 Dec 2006 14:22:28 -0000	1.57
  @@ -35,6 +35,7 @@
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions.MethodBinding;
  +import org.jboss.seam.core.Expressions.ValueBinding;
   import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Parameters;
   import org.jboss.seam.util.Resources;
  @@ -196,17 +197,20 @@
         for (Element param: children)
         {
            String valueExpression = param.attributeValue("value");
  -         if (valueExpression==null)
  -         {
  -            throw new IllegalArgumentException("must specify value for page <param/> declaration");
  -         }
            String name = param.attributeValue("name");
            if (name==null)
            {
  +            if (valueExpression==null)
  +            {
  +               throw new IllegalArgumentException("must specify name or value for page <param/> declaration");
  +            }
               name = valueExpression.substring(2, valueExpression.length()-1);
            }
            Page.PageParameter pageParameter = new Page.PageParameter(name);
  +         if (valueExpression!=null)
  +         {
            pageParameter.setValueBinding(Expressions.instance().createValueBinding(valueExpression));
  +         }
            pageParameter.setConverterId(param.attributeValue("converterId"));
            String converterExpression = param.attributeValue("converter");
            if (converterExpression!=null)
  @@ -430,10 +434,19 @@
         {
            for ( Page.PageParameter pageParameter: page.getPageParameters() )
            {
  -            Object value = pageParameter.getValueBinding().getValue();
  +            ValueBinding valueBinding = pageParameter.getValueBinding();
  +            Object value;
  +            if (valueBinding==null)
  +            {
  +               value = Contexts.getPageContext().get( pageParameter.getName() );
  +            }
  +            else
  +            {
  +               value = valueBinding.getValue();
  +            }
               if (value!=null)
               {
  -               parameters.put(pageParameter.getName(), value);
  +               parameters.put( pageParameter.getName(), value );
               }
            }
         }
  @@ -447,9 +460,20 @@
         {
            for ( Page.PageParameter pageParameter: page.getPageParameters() )
            {
  -            if ( !overridden.contains(pageParameter.getName()) )
  +            if ( !overridden.contains( pageParameter.getName() ) )
  +            {
  +               ValueBinding valueBinding = pageParameter.getValueBinding();
  +               if (valueBinding==null)
  +               {
  +                  Object value = Contexts.getPageContext().get( pageParameter.getName() );
  +                  if (value!=null) 
  +                  {
  +                     parameters.put( pageParameter.getName(), value );
  +                  }
  +               }
  +               else
               {
  -               Object value = pageParameter.getValueBinding().getValue();
  +                  Object value = valueBinding.getValue();
                  if (value!=null)
                  {
                     Converter converter;
  @@ -464,7 +488,8 @@
                     }
                     Object convertedValue = converter==null ? 
                           value : converter.getAsString( facesContext, facesContext.getViewRoot(), value );
  -                  parameters.put(pageParameter.getName(), convertedValue);
  +                     parameters.put( pageParameter.getName(), convertedValue );
  +                  }
                  }
               }
            }
  @@ -480,6 +505,7 @@
         {
            for ( Page.PageParameter pageParameter: page.getPageParameters() )
            {         
  +            
               String[] parameterValues = requestParameters.get(pageParameter.getName());
               if (parameterValues==null || parameterValues.length==0)
               {
  @@ -505,7 +531,16 @@
               Object value = converter==null ? 
                     stringValue :
                     converter.getAsObject( facesContext, facesContext.getViewRoot(), stringValue );
  -            pageParameter.getValueBinding().setValue(value);
  +
  +            ValueBinding valueBinding = pageParameter.getValueBinding();
  +            if (valueBinding==null)
  +            {
  +               Contexts.getPageContext().set( pageParameter.getName(), value );
  +            }
  +            else
  +            {
  +               valueBinding.setValue(value);
  +            }
            }
         }
      }
  @@ -517,10 +552,14 @@
         {
            for ( Page.PageParameter pageParameter: page.getPageParameters() )
            {         
  -            Object object = Contexts.getPageContext().get(pageParameter.getName());
  +            ValueBinding valueBinding = pageParameter.getValueBinding();
  +            if (valueBinding!=null)
  +            {
  +               Object object = Contexts.getPageContext().get( pageParameter.getName() );
               if (object!=null)
               {
  -               pageParameter.getValueBinding().setValue(object);
  +                  valueBinding.setValue(object);
  +               }
               }
            }
         }
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:42:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:42:02 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1GtQoU-0003lf-O1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:42:02

  Modified:    seam-gen  build.xml
  Log:
  make the Done buttons work nicely
  
  Revision  Changes    Path
  1.48      +6 -0      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -b -r1.47 -r1.48
  --- build.xml	8 Dec 2006 22:53:35 -0000	1.47
  +++ build.xml	10 Dec 2006 15:42:02 -0000	1.48
  @@ -676,9 +676,15 @@
           	<hbmtemplate filepattern="{class-name}.xhtml"
           	                template="view/view.xhtml.ftl" 
           		             destdir="${project.home}/view"/>
  +        	<hbmtemplate filepattern="{class-name}.page.xml"
  +        	                template="view/edit.page.xml.ftl" 
  +        		             destdir="${project.home}/view"/>
           	<hbmtemplate filepattern="{class-name}Edit.xhtml"
           	                template="view/edit.xhtml.ftl" 
           		             destdir="${project.home}/view"/>
  +        	<hbmtemplate filepattern="{class-name}Edit.page.xml"
  +        	                template="view/edit.page.xml.ftl" 
  +        		             destdir="${project.home}/view"/>
           	<hbmtemplate filepattern="{package-name}/{class-name}List.java"
           	                template="src/EntityList.java.ftl" 
           		             destdir="${project.home}/src"/>
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:42:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:42:02 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/src  ...
Message-ID: <E1GtQoU-0003lm-R0@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:42:02

  Modified:    seam-gen/src  EntityHome.java.ftl
  Log:
  make the Done buttons work nicely
  
  Revision  Changes    Path
  1.5       +22 -30    jboss-seam/seam-gen/src/EntityHome.java.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityHome.java.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/src/EntityHome.java.ftl,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- EntityHome.java.ftl	10 Nov 2006 05:48:27 -0000	1.4
  +++ EntityHome.java.ftl	10 Dec 2006 15:42:02 -0000	1.5
  @@ -1,43 +1,31 @@
  +${pojo.packageDeclaration}
  +<#assign classbody>
   <#assign entityName = pojo.shortName>
   <#assign componentName = util.lower(entityName)>
   <#assign homeName = componentName + "Home">
  -${pojo.packageDeclaration}
  -
  -import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.annotations.In;
  -import org.jboss.seam.annotations.RequestParameter;
  -import org.jboss.seam.framework.EntityHome;
  -
  -import java.util.List;
  -import java.util.ArrayList;
  -
  - at Name("${homeName}")
  -public class ${entityName}Home extends EntityHome<${entityName}>
  +@${pojo.importType("org.jboss.seam.annotations.Name")}("${homeName}")
  +public class ${entityName}Home extends ${pojo.importType("org.jboss.seam.framework.EntityHome")}<${entityName}>
   {
   
  -    @RequestParameter 
  -    ${pojo.identifierProperty.type.returnedClass.name} ${componentName}Id;
  -    
   <#foreach property in pojo.allPropertiesIterator>
   <#if c2h.isManyToOne(property)>
   <#assign parentPojo = c2j.getPOJOClass(cfg.getClassMapping(property.value.referencedEntityName))>
   <#assign parentHomeName = util.lower(parentPojo.shortName) + "Home">
  -    @In(value="${'#'}{${parentHomeName}.instance}", required=false)
  +    @${pojo.importType("org.jboss.seam.annotations.In")}(value="${'#'}{${parentHomeName}.instance}", required=false)
       ${parentPojo.shortName} ${property.name};
   </#if>
   </#foreach>
   
  -    @Override
  -    public Object getId() 
  -    { 
  -        if (${componentName}Id==null)
  +<#assign idName = entityName + util.upper(pojo.identifierProperty.name)>
  +<#assign idType = pojo.importType(pojo.identifierProperty.type.returnedClass.name)>
  +    public void set${idName}(${idType} id)
           {
  -            return super.getId();
  +        setId(id);
           }
  -        else
  +
  +    public ${idType} get${idName}()
           {
  -            return ${componentName}Id;
  -        }
  +        return (${idType}) getId();
       }
       
       @Override
  @@ -57,11 +45,15 @@
   <#assign getter = "get" + pojo.getPropertyName(property)>
   <#if c2h.isOneToManyCollection(property)>
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
  -    public List<${childPojo.shortName}> ${getter}() {
  +    public ${pojo.importType("java.util.List")}<${childPojo.shortName}> ${getter}() {
           return getInstance() == null ? 
  -            null : new ArrayList<${childPojo.shortName}>( getInstance().${getter}() );
  +            null : new ${pojo.importType("java.util.ArrayList")}<${childPojo.shortName}>( getInstance().${getter}() );
       }
   </#if>
   </#foreach>
   
   }
  +</#assign>
  +
  +${pojo.generateImports()}
  +${classbody}
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:42:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:42:03 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view      ...
Message-ID: <E1GtQoV-0003m5-0O@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:42:03

  Modified:    seam-gen/view      edit.xhtml.ftl list.xhtml.ftl
                        view.xhtml.ftl
  Added:       seam-gen/view      edit.page.xml.ftl param.xml.ftl
  Log:
  make the Done buttons work nicely
  
  Revision  Changes    Path
  1.18      +5 -3      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- edit.xhtml.ftl	7 Dec 2006 04:15:45 -0000	1.17
  +++ edit.xhtml.ftl	10 Dec 2006 15:42:02 -0000	1.18
  @@ -220,7 +220,7 @@
                            id="view${parentName}" 
                         value="View" 
                   propagation="end">
  -                    <f:param name="${parentName}Id" 
  +                    <f:param name="${parentName}${util.upper(parentPojo.identifierProperty.name)}" 
                               value="${'#'}{${parentName}.${parentPojo.identifierProperty.name}}"/>
                   </s:link>
               </h:column>
  @@ -262,8 +262,9 @@
                                 id="select${childName}" 
                              value="Select"
                        propagation="end">
  -                        <f:param name="${childName}Id" 
  +                        <f:param name="${childName}${util.upper(childPojo.identifierProperty.name)}" 
                                   value="${'#'}{${childName}.${childPojo.identifierProperty.name}}"/>
  +                        <f:param name="${childName}From" value="${entityName}"/>
                       </s:link>
                   </h:column>
               </h:dataTable>
  @@ -275,8 +276,9 @@
                      value="Add ${childName}"
                       view="/${childEditPageName}.xhtml" 
                propagation="begin">
  -                 <f:param name="${componentName}Id" 
  +                 <f:param name="${componentName}${util.upper(pojo.identifierProperty.name)}" 
                           value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
  +                 <f:param name="${childName}From" value="${entityName}"/>
               </s:button>
           </div>
           
  
  
  
  1.7       +2 -2      jboss-seam/seam-gen/view/list.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.xhtml.ftl,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- list.xhtml.ftl	4 Dec 2006 03:36:03 -0000	1.6
  +++ list.xhtml.ftl	10 Dec 2006 15:42:02 -0000	1.7
  @@ -48,7 +48,7 @@
               <s:link view="/${pageName}.xhtml" 
                      value="Select" 
                         id="${componentName}">
  -                <f:param name="${componentName}Id" 
  +                <f:param name="${componentName}${util.upper(pojo.identifierProperty.name)}" 
                           value="${'#'}{${componentName}.${pojo.identifierProperty.name}}"/>
               </s:link>
           </h:column>
  
  
  
  1.7       +28 -24    jboss-seam/seam-gen/view/view.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: view.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/view.xhtml.ftl,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- view.xhtml.ftl	4 Dec 2006 03:36:03 -0000	1.6
  +++ view.xhtml.ftl	10 Dec 2006 15:42:02 -0000	1.7
  @@ -63,20 +63,14 @@
       
       <div class="actionButtons">
              
  -        <s:button id="edit" value="Edit" 
  -                view="/${editPageName}.xhtml" 
  -         propagation="begin">
  -            <f:param name="${componentName}Id" 
  -                    value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
  -        </s:button>
  -        
  -        <s:button id="delete" value="Delete" 
  -              action="${'#'}{${homeName}.remove}"
  -            rendered="${'#'}{${homeName}.managed}"
  -                view="/${masterPageName}.xhtml">
  -            <f:param name="${componentName}Id" 
  -                    value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
  -        </s:button>
  +        <s:button view="/${editPageName}.xhtml" 
  +                    id="edit" 
  +                 value="Edit"     
  +           propagation="begin"/>
  +
  +        <s:button view="/${'#'}{empty ${componentName}From ? '${masterPageName}' : ${componentName}From}.xhtml"
  +                    id="done"
  +                 value="Done"/>
           
       </div>
   <#foreach property in pojo.allPropertiesIterator>
  @@ -114,8 +108,11 @@
   </#foreach>
               <h:column>
                   <f:facet name="header">action</f:facet>
  -                <s:link id="view${parentName}" value="View" view="/${parentPageName}.xhtml">
  -                    <f:param name="${parentName}Id" value="${'#'}{${parentName}.${parentPojo.identifierProperty.name}}"/>
  +                <s:link id="view${parentName}" 
  +                     value="View" 
  +                      view="/${parentPageName}.xhtml">
  +                    <f:param name="${parentName}${util.upper(parentPojo.identifierProperty.name)}" 
  +                           value="${'#'}{${parentName}.${parentPojo.identifierProperty.name}}"/>
                   </s:link>
               </h:column>
           </h:dataTable>
  @@ -151,8 +148,12 @@
   </#foreach>
               <h:column>
                   <f:facet name="header">action</f:facet>
  -                <s:link id="select${childName}" value="Select" view="/${childPageName}.xhtml">
  -                    <f:param name="${childName}Id" value="${'#'}{${childName}.${childPojo.identifierProperty.name}}"/>
  +                <s:link id="select${childName}" 
  +                     value="Select" 
  +                      view="/${childPageName}.xhtml">
  +                    <f:param name="${childName}${util.upper(childPojo.identifierProperty.name)}" 
  +                            value="${'#'}{${childName}.${childPojo.identifierProperty.name}}"/>
  +                    <f:param name="${childName}From" value="${entityName}"/>
                   </s:link>
               </h:column>
           </h:dataTable>
  @@ -160,10 +161,13 @@
       </div>
   
       <div class="actionButtons">
  -        <s:button id="add${childName}" value="Add ${childName}"
  -                view="/${childEditPageName}.xhtml" propagation="begin">
  -            <f:param name="${componentName}Id" 
  +        <s:button id="add${childName}" 
  +               value="Add ${childName}"
  +                view="/${childEditPageName}.xhtml" 
  +         propagation="begin">
  +            <f:param name="${componentName}${util.upper(pojo.identifierProperty.name)}" 
                       value="${'#'}{${homeName}.instance.${pojo.identifierProperty.name}}"/>
  +            <f:param name="${childName}From" value="${entityName}"/>
           </s:button>
       </div>        
   </#if>
  
  
  
  1.1      date: 2006/12/10 15:42:02;  author: gavin;  state: Exp;jboss-seam/seam-gen/view/edit.page.xml.ftl
  
  Index: edit.page.xml.ftl
  ===================================================================
  <!DOCTYPE page PUBLIC
            "-//JBoss/Seam Pages Configuration DTD 1.1//EN"
            "http://jboss.com/products/seam/pages-1.1.dtd">
  
  <#assign entityName = pojo.shortName>
  <#assign componentName = util.lower(entityName)>
  <#assign homeName = componentName + "Home">
  <#assign idName = componentName + util.upper(pojo.identifierProperty.name)>
  <page>
     <param name="${componentName}From"/>
     <param name="${idName}"
           value="${'#'}{${homeName}.${idName}}"/>
  <#include "param.xml.ftl">
  </page>
  
  
  1.1      date: 2006/12/10 15:42:02;  author: gavin;  state: Exp;jboss-seam/seam-gen/view/param.xml.ftl
  
  Index: param.xml.ftl
  ===================================================================
  <#foreach property in pojo.allPropertiesIterator>
  <#if c2h.isManyToOne(property)>
  <#assign parentPojo = c2j.getPOJOClass(cfg.getClassMapping(property.value.referencedEntityName))>
  <#assign componentName = util.lower(parentPojo.shortName)>
  <#assign homeName = componentName + "Home">
  <#assign idName = componentName + util.upper(parentPojo.identifierProperty.name)>
     <param name="${componentName}From"/>
     <param name="${idName}"
           value="${'#'}{${homeName}.${idName}}"/>
  <#assign p = pojo>
  <#assign pojo = parentPojo>
  <#include "param.xml.ftl">
  <#assign pojo = p>
  </#if>
  </#foreach>
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:42:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:42:03 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/layout  ...
Message-ID: <E1GtQoV-0003mC-4N@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:42:03

  Modified:    seam-gen/view/layout  template.xhtml
  Log:
  make the Done buttons work nicely
  
  Revision  Changes    Path
  1.6       +1 -0      jboss-seam/seam-gen/view/layout/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/layout/template.xhtml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- template.xhtml	25 Nov 2006 00:16:35 -0000	1.5
  +++ template.xhtml	10 Dec 2006 15:42:03 -0000	1.6
  @@ -9,6 +9,7 @@
       <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
       <title>@projectName@</title>
       <link href="stylesheet/theme.css" rel="stylesheet" type="text/css" />
  +    <link href="stylesheet/date.css" rel="stylesheet" type="text/css" />
   </head>
   
   <body>
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:42:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:42:03 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/stylesheet  ...
Message-ID: <E1GtQoV-0003mJ-87@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:42:03

  Modified:    seam-gen/view/stylesheet  theme.css
  Log:
  make the Done buttons work nicely
  
  Revision  Changes    Path
  1.6       +4 -2      jboss-seam/seam-gen/view/stylesheet/theme.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: theme.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/stylesheet/theme.css,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- theme.css	8 Dec 2006 00:37:05 -0000	1.5
  +++ theme.css	10 Dec 2006 15:42:03 -0000	1.6
  @@ -143,7 +143,7 @@
   
   /* the div that holds the date picker calendar */
   .seam-date {
  -
  +    width: 300px;
   }
   
   
  @@ -200,6 +200,7 @@
       background-color: #CCCCCC;
       border: 1px solid #AAAAAA;
       color: white;
  +    width: 14%;
   }
   
   
  @@ -207,6 +208,7 @@
   /* a table cell that holds a date number (either blank or 1-31) */
   .seam-date-week td.seam-date-day {
       border: 1px solid #ece9d8;	
  +    width: 14%;
   }
   
   /* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:54:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:54:24 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/framework  ...
Message-ID: <E1GtR0S-0003xW-CY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:54:24

  Modified:    src/main/org/jboss/seam/framework  Query.java
  Log:
  fix JBSEAM-576
  
  Revision  Changes    Path
  1.12      +1 -1      jboss-seam/src/main/org/jboss/seam/framework/Query.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Query.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/Query.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- Query.java	8 Nov 2006 22:03:17 -0000	1.11
  +++ Query.java	10 Dec 2006 15:54:24 -0000	1.12
  @@ -97,7 +97,7 @@
   
      public int getPreviousFirstResult()
      {
  -      if ( getMaxResults() > getFirstResult() ) 
  +      if ( getMaxResults() > ( getFirstResult()==null ? 0 : getFirstResult() ) ) 
         {
            return 0;
         }
  
  
  


From gavin.king at jboss.com  Sun Dec 10 10:59:59 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 10:59:59 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1GtR5r-00043M-JI@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 10:59:59

  Modified:    seam-gen/view  edit.xhtml.ftl
  Log:
  ws
  
  Revision  Changes    Path
  1.19      +1 -1      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  
  
  


From gavin.king at jboss.com  Sun Dec 10 11:01:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 11:01:58 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools/resources/WEB-INF  ...
Message-ID: <E1GtR7m-00046y-3H@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 11:01:58

  Modified:    examples/drools/resources/WEB-INF  components.xml
  Log:
  ws
  
  Revision  Changes    Path
  1.6       +4 -2      jboss-seam/examples/drools/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/resources/WEB-INF/components.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- components.xml	8 Dec 2006 05:14:20 -0000	1.5
  +++ components.xml	10 Dec 2006 16:01:58 -0000	1.6
  @@ -1,6 +1,7 @@
   <components xmlns="http://jboss.com/products/seam/components" 
               xmlns:core="http://jboss.com/products/seam/core"
               xmlns:drools="http://jboss.com/products/seam/drools">
  +            
       <drools:rule-base name="ruleBase" rule-files="numberguess.drl"/>
       <drools:managed-working-memory name="workingMemory" rule-base="#{ruleBase}"/>
   
  @@ -12,4 +13,5 @@
   
       <core:init debug="true"/>
       <core:microcontainer installed="@microcontainer@"/>
  +    
   </components>
  
  
  


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-project -
	New directory ...
Message-ID: <E1GtRI9-0004Ui-FL@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-project added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata
	- New directory ...
Message-ID: <E1GtRI9-0004Um-JP@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-profile -
	New directory ...
Message-ID: <E1GtRI9-0004Ue-Bc@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-profile added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-settings -
	New directory ...
Message-ID: <E1GtRI9-0004Uq-N8@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-settings added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/reporting -
	New directory ...
Message-ID: <E1GtRI9-0004Uu-Qz@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/shared - New
	directory ...
Message-ID: <E1GtRIA-0004Uy-0B@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/shared added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/surefire -
	New directory ...
Message-ID: <E1GtRIA-0004V2-5E@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/wagon - New
	directory ...
Message-ID: <E1GtRIA-0004V6-8v@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:39 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/doxia - New
	directory ...
Message-ID: <E1GtRI7-0004Tk-Kn@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven-model
	- New directory ...
Message-ID: <E1GtRI8-0004UC-Fu@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-model added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven-core -
	New directory ...
Message-ID: <E1GtRI8-0004U4-85@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-core added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics
	- New directory ...
Message-ID: <E1GtRI8-0004U8-C3@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-monitor -
	New directory ...
Message-ID: <E1GtRI8-0004UG-Je@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-monitor added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry
	- New directory ...
Message-ID: <E1GtRI9-0004Ua-6w@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:45 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:45 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/doxia/doxia
	- New directory ...
Message-ID: <E1GtRID-0004VF-M3@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:45

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:39 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven - New
	directory ...
Message-ID: <E1GtRI7-0004To-Nf@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:45 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:45 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core -
	New directory ...
Message-ID: <E1GtRID-0004VJ-QK@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:45

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-archiver -
	New directory ...
Message-ID: <E1GtRI7-0004Ts-Rj@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-archiver added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:45 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:45 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model
	- New directory ...
Message-ID: <E1GtRID-0004VN-UE@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:45

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact -
	New directory ...
Message-ID: <E1GtRI7-0004Tw-Vs@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-artifact added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:46 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:46 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api
	- New directory ...
Message-ID: <E1GtRIE-0004VR-1U@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:46

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:46 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:46 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer
	- New directory ...
Message-ID: <E1GtRIE-0004VX-5X@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:46

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager
	- New directory ...
Message-ID: <E1GtRI8-0004U0-3v@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven-parent
	- New directory ...
Message-ID: <E1GtRI8-0004UK-NW@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-parent added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-api -
	New directory ...
Message-ID: <E1GtRI8-0004UO-Rb@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-api added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor
	- New directory ...
Message-ID: <E1GtRI8-0004US-VG@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter
	- New directory ...
Message-ID: <E1GtRI9-0004UW-2p@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:41

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-7
	- New directory ...
Message-ID: <E1GtRIH-0004Vg-AW@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-7 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-8
	- New directory ...
Message-ID: <E1GtRIH-0004Vk-Dv@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-8 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:12:58 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:12:58 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8
	- New directory ...
Message-ID: <E1GtRIQ-0004W3-Rs@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:12:58

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8
	- New directory ...
Message-ID: <E1GtRIa-0004WM-QU@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:18 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:18 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7
	- New directory ...
Message-ID: <E1GtRIk-0004Wf-Pi@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:18

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:18 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:18 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8
	- New directory ...
Message-ID: <E1GtRIk-0004Wj-Tl@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:18

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:29 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:29 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8
	- New directory ...
Message-ID: <E1GtRIv-0004X2-RF@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:29

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:39 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven/2.0 -
	New directory ...
Message-ID: <E1GtRJ5-0004XL-R2@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:39 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven/2.0.2
	- New directory ...
Message-ID: <E1GtRJ5-0004XP-Um@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven/2.0.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2
	- New directory ...
Message-ID: <E1GtRJF-0004Xi-QR@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:13:59 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:13:59 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0
	- New directory ...
Message-ID: <E1GtRJP-0004Y1-Tt@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:13:59

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0.2
	- New directory ...
Message-ID: <E1GtRJQ-0004Y5-0r@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:00

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:09 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager/2.0
	- New directory ...
Message-ID: <E1GtRJZ-0004YO-Ug@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:09

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:16 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:16 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-core/2.0 -
	New directory ...
Message-ID: <E1GtRJg-0004Yc-Ut@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:16

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-core/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:23 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:23 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics/2.0
	- New directory ...
Message-ID: <E1GtRJn-0004Yq-TQ@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:23

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:30 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:30 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-model/2.0 -
	New directory ...
Message-ID: <E1GtRJu-0004Z4-RX@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:30

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-model/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-monitor/2.0
	- New directory ...
Message-ID: <E1GtRK1-0004ZI-PY@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:37

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-monitor/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:43 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:43 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-parent/1 -
	New directory ...
Message-ID: <E1GtRK7-0004ZW-Tg@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:43

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-parent/1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:44 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:44 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-parent/4 -
	New directory ...
Message-ID: <E1GtRK8-0004Za-0S@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:44

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-parent/4 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:14:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:14:53 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-api/2.0
	- New directory ...
Message-ID: <E1GtRKH-0004Zt-TV@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:14:53

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-api/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor/2.0
	- New directory ...
Message-ID: <E1GtRKO-0004a7-Rl@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:00

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:07 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:07 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0
	- New directory ...
Message-ID: <E1GtRKV-0004bE-Qr@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry/2.0
	- New directory ...
Message-ID: <E1GtRKc-0004bu-PC@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:14

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:21 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:21 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-profile/2.0
	- New directory ...
Message-ID: <E1GtRKj-0004cT-Tj@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:21

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-profile/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:28 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:28 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-project/2.0
	- New directory ...
Message-ID: <E1GtRKq-0004cr-UK@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:28

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-project/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:35 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:35 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata/2.0
	- New directory ...
Message-ID: <E1GtRKx-0004dD-Rs@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:35

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:42 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-settings/2.0
	- New directory ...
Message-ID: <E1GtRL4-0004dc-Qz@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/maven-settings/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting
	- New directory ...
Message-ID: <E1GtRLB-0004e3-3D@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api
	- New directory ...
Message-ID: <E1GtRLB-0004e7-6Z@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:52 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:52 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0
	- New directory ...
Message-ID: <E1GtRLE-0004eR-BR@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:52

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:15:52 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:15:52 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0.2
	- New directory ...
Message-ID: <E1GtRLE-0004eV-E8@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:15:52

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:01 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:01 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0
	- New directory ...
Message-ID: <E1GtRLN-0004fP-T3@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:01

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:01 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:01 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2
	- New directory ...
Message-ID: <E1GtRLN-0004fU-W7@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:01

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:12 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:12 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness
	- New directory ...
Message-ID: <E1GtRLY-0004gH-S4@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:12

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:12 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:12 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components
	- New directory ...
Message-ID: <E1GtRLY-0004gL-Vf@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:12

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:16 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:16 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1
	- New directory ...
Message-ID: <E1GtRLc-0004gg-9L@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:16

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/1
	- New directory ...
Message-ID: <E1GtRLm-0004h7-1H@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/3
	- New directory ...
Message-ID: <E1GtRLm-0004hB-4J@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/3 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire
	- New directory ...
Message-ID: <E1GtRLx-0004hU-1E@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:37

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api
	- New directory ...
Message-ID: <E1GtRLx-0004hY-5i@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:37

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter
	- New directory ...
Message-ID: <E1GtRLx-0004hc-9V@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:37

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit
	- New directory ...
Message-ID: <E1GtRLx-0004hg-G7@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:37

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers
	- New directory ...
Message-ID: <E1GtRLx-0004hk-LA@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:37

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire/2.0
	- New directory ...
Message-ID: <E1GtRM0-0004ht-QD@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:47 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:47 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0
	- New directory ...
Message-ID: <E1GtRM7-0004i7-PO@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:47

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:16:59 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:16:59 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0
	- New directory ...
Message-ID: <E1GtRMJ-0004iQ-8C@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:16:59

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0
	- New directory ...
Message-ID: <E1GtRMS-0004il-Rn@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:18 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:18 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers/2.0
	- New directory ...
Message-ID: <E1GtRMc-0004j4-Su@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:18

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file -
	New directory ...
Message-ID: <E1GtRMk-0004jI-2n@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight
	- New directory ...
Message-ID: <E1GtRMk-0004jM-5m@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api
	- New directory ...
Message-ID: <E1GtRMk-0004jQ-AB@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh -
	New directory ...
Message-ID: <E1GtRMk-0004jU-EA@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:29 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:29 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5
	- New directory ...
Message-ID: <E1GtRMn-0004jd-L9@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:29

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:35 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:35 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5
	- New directory ...
Message-ID: <E1GtRMt-0004jr-Rv@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:35

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:42 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5
	- New directory ...
Message-ID: <E1GtRN0-0004k5-RP@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:17:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:17:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5
	- New directory ...
Message-ID: <E1GtRN7-0004kJ-WD@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:17:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:07 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:07 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin
	- New directory ...
Message-ID: <E1GtRON-0004kZ-Hd@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:07 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:07 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin
	- New directory ...
Message-ID: <E1GtRON-0004kd-K9@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:07 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:07 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin
	- New directory ...
Message-ID: <E1GtRON-0004kh-Od@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:07 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:07 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin
	- New directory ...
Message-ID: <E1GtRON-0004kl-SX@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent
	- New directory ...
Message-ID: <E1GtROO-0004kp-09@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins
	- New directory ...
Message-ID: <E1GtROO-0004kt-3r@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin
	- New directory ...
Message-ID: <E1GtROO-0004kx-6x@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin
	- New directory ...
Message-ID: <E1GtROO-0004l1-Ac@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin
	- New directory ...
Message-ID: <E1GtROO-0004l5-El@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin
	- New directory ...
Message-ID: <E1GtROO-0004l9-Ix@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:11 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:11 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0
	- New directory ...
Message-ID: <E1GtROR-0004lI-LC@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:11

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:20 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:20 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1
	- New directory ...
Message-ID: <E1GtROa-0004lb-QW@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:20

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:31 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:31 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1
	- New directory ...
Message-ID: <E1GtROl-0004lu-S6@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:31

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:42 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1
	- New directory ...
Message-ID: <E1GtROw-0004mD-Qy@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:19:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:19:53 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent/2.0
	- New directory ...
Message-ID: <E1GtRP7-0004mW-SD@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:19:53

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent/2.0 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:20:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:20:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/1
	- New directory ...
Message-ID: <E1GtRPE-0004mk-SN@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:20:00

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:20:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:20:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/3
	- New directory ...
Message-ID: <E1GtRPE-0004mo-Vw@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:20:00

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/3 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:20:10 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:20:10 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2
	- New directory ...
Message-ID: <E1GtRPO-0004o4-QM@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:20:10

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:20:21 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:20:21 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5
	- New directory ...
Message-ID: <E1GtRPZ-0004ov-Pf@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:20:21

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:20:34 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:20:34 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1
	- New directory ...
Message-ID: <E1GtRPm-0004pr-OK@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:20:34

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 11:20:45 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 11:20:45 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2
	- New directory ...
Message-ID: <E1GtRPx-0004qj-Qg@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 11:20:45

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2 added to the repository


From msurtani at jboss.com  Sun Dec 10 11:42:18 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 10 Dec 2006 11:42:18 -0500
Subject: [jboss-cvs] JBossCache/lib  ...
Message-ID: <E1GtRko-00058l-WF@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/10 11:42:18

  Modified:    lib      jgroups.jar
  Log:
  Updated JGroups snapshot
  
  Revision  Changes    Path
  1.9       +2183 -5916JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Sun Dec 10 11:42:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 10 Dec 2006 11:42:57 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GtRlR-000591-4j@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/10 11:42:57

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Updated JGroups lib with anycast bug fixed.  TreeCache modified to take advantage of this.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.33 +3 -5      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.32
  retrieving revision 1.195.2.33
  diff -u -b -r1.195.2.32 -r1.195.2.33
  --- TreeCache.java	9 Dec 2006 15:14:26 -0000	1.195.2.32
  +++ TreeCache.java	10 Dec 2006 16:42:56 -0000	1.195.2.33
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.32 2006/12/09 15:14:26 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.33 2006/12/10 16:42:56 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -4332,10 +4332,8 @@
   
         // if we are using buddy replication, all calls should use ANYCAST.  Otherwise, use the default (multicast).  Unless anycast is forced
   
  -      // TODO; Disabling anycast for now.  Fix once this bug is fixed in JGroups.
  -
  -      rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, false);//forceAnycast || buddyManager != null && buddyManager.isEnabled());
  -      //rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
  +//      rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, false);//forceAnycast || buddyManager != null && buddyManager.isEnabled());
  +      rsps = callRemoteMethodsViaReflection(validMembers, method_call, mode, timeout, forceAnycast || buddyManager != null && buddyManager.isEnabled());
   
         // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
         // JGroups supports http://jira.jboss.com/jira/browse/JGRP-193
  
  
  


From msurtani at jboss.com  Sun Dec 10 11:42:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 10 Dec 2006 11:42:57 -0500
Subject: [jboss-cvs] JBossCache/lib  ...
Message-ID: <E1GtRlR-00059B-NB@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/10 11:42:57

  Modified:    lib      Tag: Branch_JBossCache_1_4_0 jgroups.jar
  Log:
  Updated JGroups lib with anycast bug fixed.  TreeCache modified to take advantage of this.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.4   +1712 -1656JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sun Dec 10 11:53:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 11:53:28 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1GtRvc-0005Hc-FW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 11:53:28

  Modified:    seam-gen  build.xml
  Log:
  get rid of @RequestParameter
  fix bug in conversation model
  
  Revision  Changes    Path
  1.49      +3 -0      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -b -r1.48 -r1.49
  --- build.xml	10 Dec 2006 15:42:02 -0000	1.48
  +++ build.xml	10 Dec 2006 16:53:28 -0000	1.49
  @@ -688,6 +688,9 @@
           	<hbmtemplate filepattern="{package-name}/{class-name}List.java"
           	                template="src/EntityList.java.ftl" 
           		             destdir="${project.home}/src"/>
  +        	<hbmtemplate filepattern="{class-name}List.page.xml"
  +        	                template="view/list.page.xml.ftl" 
  +        		             destdir="${project.home}/view"/>
           	<hbmtemplate filepattern="{package-name}/{class-name}Home.java"
           	                template="src/EntityHome.java.ftl" 
           		             destdir="${project.home}/src"/>
  
  
  


From gavin.king at jboss.com  Sun Dec 10 11:53:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 11:53:28 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/src  ...
Message-ID: <E1GtRvc-0005Hj-IN@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 11:53:28

  Modified:    seam-gen/src  EntityList.java.ftl
  Log:
  get rid of @RequestParameter
  fix bug in conversation model
  
  Revision  Changes    Path
  1.3       +2 -8      jboss-seam/seam-gen/src/EntityList.java.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityList.java.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/src/EntityList.java.ftl,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- EntityList.java.ftl	8 Nov 2006 22:46:58 -0000	1.2
  +++ EntityList.java.ftl	10 Dec 2006 16:53:28 -0000	1.3
  @@ -4,28 +4,22 @@
   ${pojo.packageDeclaration}
   
   import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.annotations.RequestParameter;
   import org.jboss.seam.framework.EntityQuery;
   
   @Name("${listName}")
   public class ${entityName}List extends EntityQuery
   {
  +
       @Override
       public String getEjbql() 
       { 
           return "select ${componentName} from ${entityName} ${componentName}";
       }
       
  -    @RequestParameter
  -    @Override
  -    public void setFirstResult(Integer firstResult)
  -    {
  -    	super.setFirstResult(firstResult);
  -    }
  -    
       @Override
       public Integer getMaxResults()
       {
       	return 25;
       }
  +    
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 10 11:53:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 10 Dec 2006 11:53:28 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view     ...
Message-ID: <E1GtRvc-0005Hz-NI@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/10 11:53:28

  Modified:    seam-gen/view     edit.page.xml.ftl edit.xhtml.ftl
                        param.xml.ftl
  Added:       seam-gen/view     list.page.xml.ftl
  Log:
  get rid of @RequestParameter
  fix bug in conversation model
  
  Revision  Changes    Path
  1.2       +1 -2      jboss-seam/seam-gen/view/edit.page.xml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.page.xml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.page.xml.ftl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- edit.page.xml.ftl	10 Dec 2006 15:42:02 -0000	1.1
  +++ edit.page.xml.ftl	10 Dec 2006 16:53:28 -0000	1.2
  @@ -8,7 +8,6 @@
   <#assign idName = componentName + util.upper(pojo.identifierProperty.name)>
   <page>
      <param name="${componentName}From"/>
  -   <param name="${idName}"
  -         value="${'#'}{${homeName}.${idName}}"/>
  +   <param name="${idName}" value="${'#'}{${homeName}.${idName}}"/>
   <#include "param.xml.ftl">
   </page>
  \ No newline at end of file
  
  
  
  1.20      +2 -2      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- edit.xhtml.ftl	10 Dec 2006 15:59:59 -0000	1.19
  +++ edit.xhtml.ftl	10 Dec 2006 16:53:28 -0000	1.20
  @@ -219,7 +219,7 @@
                   <s:link view="/${parentPageName}.xhtml" 
                            id="view${parentName}" 
                         value="View" 
  -                propagation="end">
  +                propagation="none">
                       <f:param name="${parentName}${util.upper(parentPojo.identifierProperty.name)}" 
                               value="${'#'}{${parentName}.${parentPojo.identifierProperty.name}}"/>
                   </s:link>
  @@ -261,7 +261,7 @@
                       <s:link view="/${childPageName}.xhtml" 
                                 id="select${childName}" 
                              value="Select"
  -                     propagation="end">
  +                     propagation="none">
                           <f:param name="${childName}${util.upper(childPojo.identifierProperty.name)}" 
                                   value="${'#'}{${childName}.${childPojo.identifierProperty.name}}"/>
                           <f:param name="${childName}From" value="${entityName}"/>
  
  
  
  1.2       +1 -2      jboss-seam/seam-gen/view/param.xml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: param.xml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/param.xml.ftl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- param.xml.ftl	10 Dec 2006 15:42:02 -0000	1.1
  +++ param.xml.ftl	10 Dec 2006 16:53:28 -0000	1.2
  @@ -5,8 +5,7 @@
   <#assign homeName = componentName + "Home">
   <#assign idName = componentName + util.upper(parentPojo.identifierProperty.name)>
      <param name="${componentName}From"/>
  -   <param name="${idName}"
  -         value="${'#'}{${homeName}.${idName}}"/>
  +   <param name="${idName}" value="${'#'}{${homeName}.${idName}}"/>
   <#assign p = pojo>
   <#assign pojo = parentPojo>
   <#include "param.xml.ftl">
  
  
  
  1.1      date: 2006/12/10 16:53:28;  author: gavin;  state: Exp;jboss-seam/seam-gen/view/list.page.xml.ftl
  
  Index: list.page.xml.ftl
  ===================================================================
  <!DOCTYPE page PUBLIC
            "-//JBoss/Seam Pages Configuration DTD 1.1//EN"
            "http://jboss.com/products/seam/pages-1.1.dtd">
  
  <#assign entityName = pojo.shortName>
  <#assign componentName = util.lower(entityName)>
  <#assign listName = componentName + "List">
  <page>
     <param name="firstResult" value="${'#'}{${listName}.firstResult}"/>
  </page>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:25 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:25 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8
	...
Message-ID: <E1GtS2L-0005O4-Lw@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:25

  Added:       maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8    
                        doxia-core-1.0-alpha-8.jar
                        doxia-core-1.0-alpha-8.jar.sha1
                        doxia-core-1.0-alpha-8.pom
                        doxia-core-1.0-alpha-8.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:25;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:00:25;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.jar.sha1
  
  Index: doxia-core-1.0-alpha-8.jar.sha1
  ===================================================================
  d3f4514ab8813a8cf879b947b477e4ed78dc6275
  
  
  1.1      date: 2006/12/10 17:00:25;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.pom
  
  Index: doxia-core-1.0-alpha-8.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>doxia</artifactId>
      <groupId>org.apache.maven.doxia</groupId>
      <version>1.0-alpha-8</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>doxia-core</artifactId>
    <name>Doxia Core</name>
    <version>1.0-alpha-8</version>
    <build>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <configuration>
            <source>1.4</source>
            <target>1.4</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-jar-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>test-jar</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>oro</groupId>
        <artifactId>oro</artifactId>
        <version>2.0.7</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.doxia</groupId>
        <artifactId>doxia-sink-api</artifactId>
        <version>1.0-alpha-8</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>runtime</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:25;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.pom.sha1
  
  Index: doxia-core-1.0-alpha-8.pom.sha1
  ===================================================================
  0b5ab623ba8310131e80abdf447100181b2116fa
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:30 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:30 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8
	...
Message-ID: <E1GtS2Q-0005OY-01@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:29

  Added:       maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8    
                        doxia-decoration-model-1.0-alpha-8.jar
                        doxia-decoration-model-1.0-alpha-8.jar.sha1
                        doxia-decoration-model-1.0-alpha-8.pom
                        doxia-decoration-model-1.0-alpha-8.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:00:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.jar.sha1
  
  Index: doxia-decoration-model-1.0-alpha-8.jar.sha1
  ===================================================================
  831bbaf463d4594782d78415eb96980f638de477
  
  
  1.1      date: 2006/12/10 17:00:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.pom
  
  Index: doxia-decoration-model-1.0-alpha-8.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>doxia</artifactId>
      <groupId>org.apache.maven.doxia</groupId>
      <version>1.0-alpha-8</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>doxia-decoration-model</artifactId>
    <name>Doxia Decoration Model</name>
    <version>1.0-alpha-8</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <version>1.0-alpha-8</version>
          <executions>
            <execution>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
                <goal>xsd</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <version>1.0.0</version>
            <model>src/main/mdo/decoration.mdo</model>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.pom.sha1
  
  Index: doxia-decoration-model-1.0-alpha-8.pom.sha1
  ===================================================================
  2e1fe38b8b482e08e50c7b7c41a608e96df26052
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:33 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:33 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7
	...
Message-ID: <E1GtS2T-0005P7-I8@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:33

  Added:       maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7  
                        doxia-sink-api-1.0-alpha-7.pom
                        doxia-sink-api-1.0-alpha-7.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7/doxia-sink-api-1.0-alpha-7.pom
  
  Index: doxia-sink-api-1.0-alpha-7.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>doxia</artifactId>
      <groupId>org.apache.maven.doxia</groupId>
      <version>1.0-alpha-7</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>doxia-sink-api</artifactId>
    <name>Doxia Sink API</name>
    <version>1.0-alpha-7</version>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7/doxia-sink-api-1.0-alpha-7.pom.sha1
  
  Index: doxia-sink-api-1.0-alpha-7.pom.sha1
  ===================================================================
  d8e08f33563f684917311978da2ff03a9d0022ab
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:33 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:33 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8
	...
Message-ID: <E1GtS2T-0005PH-LV@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:33

  Added:       maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8  
                        doxia-sink-api-1.0-alpha-8.pom
                        doxia-sink-api-1.0-alpha-8.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8/doxia-sink-api-1.0-alpha-8.pom
  
  Index: doxia-sink-api-1.0-alpha-8.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>doxia</artifactId>
      <groupId>org.apache.maven.doxia</groupId>
      <version>1.0-alpha-8</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>doxia-sink-api</artifactId>
    <name>Doxia Sink API</name>
    <version>1.0-alpha-8</version>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8/doxia-sink-api-1.0-alpha-8.pom.sha1
  
  Index: doxia-sink-api-1.0-alpha-8.pom.sha1
  ===================================================================
  73509124ff585f6f5d620df9e7d92525d9aeec7a
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8
	...
Message-ID: <E1GtS2X-0005Pp-PX@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:37

  Added:       maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8    
                        doxia-site-renderer-1.0-alpha-8.jar
                        doxia-site-renderer-1.0-alpha-8.jar.sha1
                        doxia-site-renderer-1.0-alpha-8.pom
                        doxia-site-renderer-1.0-alpha-8.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:00:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.jar.sha1
  
  Index: doxia-site-renderer-1.0-alpha-8.jar.sha1
  ===================================================================
  8fbe309e77b0daf8ad1ebdda0ab9d776f9707bce
  
  
  1.1      date: 2006/12/10 17:00:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.pom
  
  Index: doxia-site-renderer-1.0-alpha-8.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>doxia</artifactId>
      <groupId>org.apache.maven.doxia</groupId>
      <version>1.0-alpha-8</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>doxia-site-renderer</artifactId>
    <name>Doxia Site Renderer Component</name>
    <version>1.0-alpha-8</version>
    <contributors>
      <contributor>
        <name>Vincent Siveton</name>
        <email>vsiveton at apache.org</email>
        <organization>Apache Software Foundation</organization>
        <roles>
          <role>Java Developer</role>
        </roles>
        <timezone>-5</timezone>
      </contributor>
    </contributors>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven.doxia</groupId>
        <artifactId>doxia-core</artifactId>
        <version>1.0-alpha-8</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-i18n</artifactId>
        <version>1.0-beta-6</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-velocity</artifactId>
        <version>1.1.3</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.doxia</groupId>
        <artifactId>doxia-decoration-model</artifactId>
        <version>1.0-alpha-8</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.pom.sha1
  
  Index: doxia-site-renderer-1.0-alpha-8.pom.sha1
  ===================================================================
  802f1f0bc325072e09cbaffe3118370395a425d5  doxia-site-renderer-1.0-alpha-8.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:44 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:44 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-7
	...
Message-ID: <E1GtS2e-0005QK-FX@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:44

  Added:       maven2/org/apache/maven/doxia/doxia/1.0-alpha-7  
                        doxia-1.0-alpha-7.pom doxia-1.0-alpha-7.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:44;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-7/doxia-1.0-alpha-7.pom
  
  Index: doxia-1.0-alpha-7.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.doxia</groupId>
    <artifactId>doxia</artifactId>
    <packaging>pom</packaging>
    <name>Doxia</name>
    <version>1.0-alpha-7</version>
    <url>http://maven.apache.org/doxia</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/DOXIA</url>
    </issueManagement>
    <ciManagement>
      <system>continuum</system>
      <notifiers>
        <notifier>
          <address>doxia-dev at maven.apache.org</address>
        </notifier>
      </notifiers>
    </ciManagement>
    <mailingLists>
      <mailingList>
        <name>Doxia Developer List</name>
        <subscribe>doxia-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>doxia-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-doxia-dev/</archive>
      </mailingList>
      <mailingList>
        <name>Doxia User List</name>
        <subscribe>doxia-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>doxia-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-doxia-users/</archive>
      </mailingList>
      <mailingList>
        <name>Doxia Commits List</name>
        <subscribe>doxia-commits-subscribe at maven.apache.org</subscribe>
        <unsubscribe>doxia-commits-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-doxia-commits/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <name>Emmanuel Venisse</name>
        <email>emmanuel at venisse.net</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>1</timezone>
      </developer>
    </developers>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/doxia/tags/doxia-1.0-alpha-7</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/doxia/tags/doxia-1.0-alpha-7</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/doxia/tags/doxia-1.0-alpha-7</url>
    </scm>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>descriptor</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <modules>
      <module>doxia-core</module>
      <module>doxia-sink-api</module>
      <module>doxia-site-renderer</module>
      <module>doxia-decoration-model</module>
    </modules>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/doxia/</url>
      </site>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:44;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-7/doxia-1.0-alpha-7.pom.sha1
  
  Index: doxia-1.0-alpha-7.pom.sha1
  ===================================================================
  fff8727b6ff366d624669f4b8dc4d4c7316bbb0c
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:44 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:44 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-8
	...
Message-ID: <E1GtS2e-0005QU-J9@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:44

  Added:       maven2/org/apache/maven/doxia/doxia/1.0-alpha-8  
                        doxia-1.0-alpha-8.pom doxia-1.0-alpha-8.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:44;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-8/doxia-1.0-alpha-8.pom
  
  Index: doxia-1.0-alpha-8.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-parent</artifactId>
      <version>1</version>
      <relativePath>../pom/maven/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven.doxia</groupId>
    <artifactId>doxia</artifactId>
    <packaging>pom</packaging>
    <name>Doxia</name>
    <version>1.0-alpha-8</version>
    <url>http://maven.apache.org/doxia</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/DOXIA</url>
    </issueManagement>
    <mailingLists>
      <mailingList>
        <name>Doxia Developer List</name>
        <subscribe>doxia-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>doxia-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-doxia-dev/</archive>
      </mailingList>
      <mailingList>
        <name>Doxia User List</name>
        <subscribe>doxia-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>doxia-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-doxia-users/</archive>
      </mailingList>
      <mailingList>
        <name>Doxia Commits List</name>
        <subscribe>doxia-commits-subscribe at maven.apache.org</subscribe>
        <unsubscribe>doxia-commits-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-doxia-commits/</archive>
      </mailingList>
    </mailingLists>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/doxia/tags/doxia-1.0-alpha-8</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/doxia/tags/doxia-1.0-alpha-8</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/doxia/tags/doxia-1.0-alpha-8</url>
    </scm>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>descriptor</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <modules>
      <module>doxia-core</module>
      <module>doxia-sink-api</module>
      <module>doxia-site-renderer</module>
      <module>doxia-decoration-model</module>
      <module>doxia-modules</module>
    </modules>
    <distributionManagement>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/doxia/</url>
      </site>
    </distributionManagement>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:00:44;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/doxia/doxia/1.0-alpha-8/doxia-1.0-alpha-8.pom.sha1
  
  Index: doxia-1.0-alpha-8.pom.sha1
  ===================================================================
  4edce801192959fab36b5712bd3531b4ef70efef
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:47 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:47 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2 ...
Message-ID: <E1GtS2h-0005R4-Vf@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:47

  Added:       maven2/org/apache/maven/maven-archiver/2.2    
                        maven-archiver-2.2.jar maven-archiver-2.2.jar.sha1
                        maven-archiver-2.2.pom maven-archiver-2.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:00:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.jar.sha1
  
  Index: maven-archiver-2.2.jar.sha1
  ===================================================================
  0bb63bbfcc2ef3614e8e9cadb413970988ad2f51
  
  
  1.1      date: 2006/12/10 17:00:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.pom
  
  Index: maven-archiver-2.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>maven-shared-components</artifactId>
      <groupId>org.apache.maven.shared</groupId>
      <version>3</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-archiver</artifactId>
    <name>Maven Archiver</name>
    <version>2.2</version>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/shared/tags/maven-archiver-2.2</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/shared/tags/maven-archiver-2.2</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/shared/tags/maven-archiver-2.2</url>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-archiver</artifactId>
        <version>1.0-alpha-7</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.pom.sha1
  
  Index: maven-archiver-2.2.pom.sha1
  ===================================================================
  6511e81aebe0367389d148bd164d861baa11d900
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:51 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:51 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager/2.0
	...
Message-ID: <E1GtS2l-0005RR-M5@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:51

  Added:       maven2/org/apache/maven/maven-artifact-manager/2.0  
                        maven-artifact-manager-2.0.pom
                        maven-artifact-manager-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:51;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager/2.0/maven-artifact-manager-2.0.pom
  
  Index: maven-artifact-manager-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-artifact-manager</artifactId>
    <name>Maven Artifact Manager</name>
    <version>2.0</version>
    <url>http://maven.apache.org</url>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-repository-metadata</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-file</artifactId>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-api</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:51;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-artifact-manager/2.0/maven-artifact-manager-2.0.pom.sha1
  
  Index: maven-artifact-manager-2.0.pom.sha1
  ===================================================================
  83294af9cf17a6779bbc585079ff6e9920297d37  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-artifact-manager/2.0/maven-artifact-manager-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:54 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:54 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0.2 ...
Message-ID: <E1GtS2o-0005Ru-KD@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:54

  Added:       maven2/org/apache/maven/maven-artifact/2.0.2  
                        maven-artifact-2.0.2.pom
                        maven-artifact-2.0.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:54;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0.2/maven-artifact-2.0.2.pom
  
  Index: maven-artifact-2.0.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0.2</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-artifact</artifactId>
    <name>Maven Artifact</name>
    <version>2.0.2</version>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:54;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0.2/maven-artifact-2.0.2.pom.sha1
  
  Index: maven-artifact-2.0.2.pom.sha1
  ===================================================================
  a8b0aa4f932e948f979c872326a5ac9d7f4e123c
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:54 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:54 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0 ...
Message-ID: <E1GtS2o-0005S4-O7@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:54

  Added:       maven2/org/apache/maven/maven-artifact/2.0  
                        maven-artifact-2.0.pom maven-artifact-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:54;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0/maven-artifact-2.0.pom
  
  Index: maven-artifact-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-artifact</artifactId>
    <name>Maven Artifact</name>
    <version>2.0</version>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:54;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-artifact/2.0/maven-artifact-2.0.pom.sha1
  
  Index: maven-artifact-2.0.pom.sha1
  ===================================================================
  92cf1ca37284b0a7d88406ca32f9f6619948344e  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-artifact/2.0/maven-artifact-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:00:57 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:00:57 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-core/2.0 ...
Message-ID: <E1GtS2r-0005SQ-J7@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:00:57

  Added:       maven2/org/apache/maven/maven-core/2.0   maven-core-2.0.pom
                        maven-core-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:00:57;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-core/2.0/maven-core-2.0.pom
  
  Index: maven-core-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-core</artifactId>
    <name>Maven</name>
    <version>2.0</version>
    <build>
      <plugins>
        <plugin>
          <artifactId>maven-assembly-plugin</artifactId>
          <version>2.0-beta-1</version>
          <configuration>
            <descriptor>src/assemble/bin.xml</descriptor>
            <finalName>maven-${version}</finalName>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-settings</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-file</artifactId>
        <scope>runtime</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-parameter-documenter</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-http-lightweight</artifactId>
        <scope>runtime</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.reporting</groupId>
        <artifactId>maven-reporting-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-profile</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-model</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-api</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-repository-metadata</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-error-diagnostics</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-registry</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>commons-cli</groupId>
        <artifactId>commons-cli</artifactId>
        <version>1.0</version>
        <exclusions>
          <exclusion>
            <artifactId>commons-lang</artifactId>
            <groupId>commons-lang</groupId>
          </exclusion>
          <exclusion>
            <artifactId>commons-logging</artifactId>
            <groupId>commons-logging</groupId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-descriptor</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-interactivity-api</artifactId>
        <version>1.0-alpha-4</version>
        <exclusions>
          <exclusion>
            <artifactId>plexus-utils</artifactId>
            <groupId>plexus</groupId>
          </exclusion>
          <exclusion>
            <artifactId>plexus-container-default</artifactId>
            <groupId>org.codehaus.plexus</groupId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-manager</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-monitor</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-ssh</artifactId>
        <scope>runtime</scope>
        <exclusions>
          <exclusion>
            <artifactId>plexus-utils</artifactId>
            <groupId>plexus</groupId>
          </exclusion>
          <exclusion>
            <artifactId>plexus-container-default</artifactId>
            <groupId>org.codehaus.plexus</groupId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
    </dependencies>
    <reporting>
      <plugins>
        <plugin>
          <artifactId>maven-checkstyle-plugin</artifactId>
        </plugin>
        <plugin>
          <artifactId>maven-clover-plugin</artifactId>
        </plugin>
        <plugin>
          <artifactId>maven-pmd-plugin</artifactId>
        </plugin>
        <plugin>
          <artifactId>maven-project-info-reports-plugin</artifactId>
        </plugin>
      </plugins>
    </reporting>
    <distributionManagement>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org//www/maven.apache.org/m2</url>
      </site>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:00:57;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-core/2.0/maven-core-2.0.pom.sha1
  
  Index: maven-core-2.0.pom.sha1
  ===================================================================
  c696da34f8a5d1af3a9b7a7d9da2e2d3faca8119  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-core/2.0/maven-core-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics/2.0
	...
Message-ID: <E1GtS2u-0005Ss-Mc@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:00

  Added:       maven2/org/apache/maven/maven-error-diagnostics/2.0  
                        maven-error-diagnostics-2.0.pom
                        maven-error-diagnostics-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:00;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics/2.0/maven-error-diagnostics-2.0.pom
  
  Index: maven-error-diagnostics-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-error-diagnostics</artifactId>
    <name>Maven Error Diagnostics</name>
    <version>2.0</version>
    <description>Provides a manager component which will process a given Throwable instance through a set of diagnostic
      sub-components, and return a String message with user-friendly information about the error and possibly
      how to fix it.</description>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:00;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-error-diagnostics/2.0/maven-error-diagnostics-2.0.pom.sha1
  
  Index: maven-error-diagnostics-2.0.pom.sha1
  ===================================================================
  c56a37e3ace52650a9a8c811a9f1247adb6d5bd9  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-error-diagnostics/2.0/maven-error-diagnostics-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:03 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:03 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-model/2.0 ...
Message-ID: <E1GtS2x-0005TE-KP@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:03

  Added:       maven2/org/apache/maven/maven-model/2.0  
                        maven-model-2.0.pom maven-model-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:03;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-model/2.0/maven-model-2.0.pom
  
  Index: maven-model-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-model</artifactId>
    <name>Maven Model</name>
    <version>2.0</version>
    <description>Maven Model</description>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
                <goal>xsd</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <version>4.0.0</version>
            <model>maven.mdo</model>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <profiles>
      <profile>
        <id>all-models</id>
        <build>
          <plugins>
            <plugin>
              <groupId>org.codehaus.modello</groupId>
              <artifactId>modello-maven-plugin</artifactId>
              <executions>
                <execution>
                  <id>v3</id>
                  <goals>
                    <goal>xpp3-writer</goal>
                    <goal>java</goal>
                    <goal>xpp3-reader</goal>
                    <goal>xsd</goal>
                  </goals>
                  <configuration>
                    <version>3.0.0</version>
                    <packageWithVersion>true</packageWithVersion>
                  </configuration>
                </execution>
              </executions>
            </plugin>
            <plugin>
              <artifactId>maven-jar-plugin</artifactId>
              <executions>
                <execution>
                  <phase>package</phase>
                  <goals>
                    <goal>jar</goal>
                  </goals>
                  <configuration>
                    <classifier>all</classifier>
                  </configuration>
                </execution>
              </executions>
            </plugin>
          </plugins>
        </build>
      </profile>
    </profiles>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:03;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-model/2.0/maven-model-2.0.pom.sha1
  
  Index: maven-model-2.0.pom.sha1
  ===================================================================
  a02c0796d872bc1b8c0cd248b5ede0da32a356d0  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-model/2.0/maven-model-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:06 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:06 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-monitor/2.0 ...
Message-ID: <E1GtS30-0005Tg-Nk@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:06

  Added:       maven2/org/apache/maven/maven-monitor/2.0  
                        maven-monitor-2.0.pom maven-monitor-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:06;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-monitor/2.0/maven-monitor-2.0.pom
  
  Index: maven-monitor-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-monitor</artifactId>
    <name>Maven Monitor</name>
    <version>2.0</version>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:06;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-monitor/2.0/maven-monitor-2.0.pom.sha1
  
  Index: maven-monitor-2.0.pom.sha1
  ===================================================================
  7140f92ccb9931f14b540f34dbc84c35fc33cf91  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-monitor/2.0/maven-monitor-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:09 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-parent/1 ...
Message-ID: <E1GtS33-0005U6-V0@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:09

  Added:       maven2/org/apache/maven/maven-parent/1   maven-parent-1.pom
                        maven-parent-1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-parent/1/maven-parent-1.pom
  
  Index: maven-parent-1.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  
  <!--
    ~ Copyright 2005-2006 The Apache Software Foundation.
    ~
    ~ Licensed under the Apache License, Version 2.0 (the "License");
    ~ you may not use this file except in compliance with the License.
    ~ You may obtain a copy of the License at
    ~
    ~      http://www.apache.org/licenses/LICENSE-2.0
    ~
    ~ Unless required by applicable law or agreed to in writing, software
    ~ distributed under the License is distributed on an "AS IS" BASIS,
    ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    ~ See the License for the specific language governing permissions and
    ~ limitations under the License.
    -->
  
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache</groupId>
      <artifactId>apache</artifactId>
      <version>1</version>
      <relativePath>../asf/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-parent</artifactId>
    <version>1</version>
    <packaging>pom</packaging>
    <name>Apache Maven</name>
    <description>
      Maven is a software project management and comprehension tool. Based on the concept of a project object model
      (POM), Maven can manage a project's build, reporting and documentation from a central piece of information.
    </description>
    <url>http://maven.apache.org/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MPA</url>
    </issueManagement>
    <ciManagement>
      <system>continuum</system>
      <url>http://maven.zones.apache.org:8080/continuum</url>
      <notifiers>
        <notifier>
          <type>mail</type>
          <configuration>
            <address>notifications at maven.apache.org</address>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2002</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven Announcements List</name>
        <post>announce at maven.apache.org</post>
        <subscribe>announce-subscribe at maven.apache.org</subscribe>
        <unsubscribe>announce-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-announce/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Issues List</name>
        <post>issues at maven.apache.org</post>
        <subscribe>issues-subscribe at maven.apache.org</subscribe>
        <unsubscribe>issues-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-issues/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Notifications List</name>
        <post>notifications at maven.apache.org</post>
        <subscribe>notifications-subscribe at maven.apache.org</subscribe>
        <unsubscribe>notifications-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-notifications/</archive>
      </mailingList>
    </mailingLists>
  
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Chair</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at apache.org</email>
        <organization>Neonics</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
      </developer>
      <developer>
        <id>snicoll</id>
        <name>Stephane Nicoll</name>
        <email>snicoll at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vmassol</id>
        <name>Vincent Massol</name>
        <email>vmassol at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>fgiust</id>
        <name>Fabrizio Giustina</name>
        <email>fgiust at apache.org</email>
        <organization>openmind</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>epunzalan</id>
        <name>Edwin Punzalan</name>
        <email>epunzalan at mergere.com</email>
        <organization>Mergere</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>+8</timezone>
      </developer>
      <developer>
        <id>mperham</id>
        <name>Mike Perham</name>
        <email>mperham at gmail.com</email>
        <organization>Webify Solutions</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>-6</timezone>
      </developer>
      <developer>
        <id>jdcasey</id>
        <name>John Casey</name>
        <email>jdcasey at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vsiveton</id>
        <name>Vincent Siveton</name>
        <email>vsiveton at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
    </developers>
  </project>
  
  
  
  
  1.1      date: 2006/12/10 17:01:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-parent/1/maven-parent-1.pom.sha1
  
  Index: maven-parent-1.pom.sha1
  ===================================================================
  56e0447ae4f17f1627ce94a56efe61f36d7046da
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:10 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:10 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-parent/4 ...
Message-ID: <E1GtS34-0005UI-1z@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:10

  Added:       maven2/org/apache/maven/maven-parent/4   maven-parent-4.pom
                        maven-parent-4.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:10;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-parent/4/maven-parent-4.pom
  
  Index: maven-parent-4.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  
  <!--
    ~ Copyright 2005-2006 The Apache Software Foundation.
    ~
    ~ Licensed under the Apache License, Version 2.0 (the "License");
    ~ you may not use this file except in compliance with the License.
    ~ You may obtain a copy of the License at
    ~
    ~      http://www.apache.org/licenses/LICENSE-2.0
    ~
    ~ Unless required by applicable law or agreed to in writing, software
    ~ distributed under the License is distributed on an "AS IS" BASIS,
    ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    ~ See the License for the specific language governing permissions and
    ~ limitations under the License.
    -->
  
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache</groupId>
      <artifactId>apache</artifactId>
      <version>3</version>
      <relativePath>../asf/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-parent</artifactId>
    <version>4</version>
    <packaging>pom</packaging>
    <name>Apache Maven</name>
    <description>
      Maven is a software project management and comprehension tool. Based on the concept of a project object model
      (POM), Maven can manage a project's build, reporting and documentation from a central piece of information.
    </description>
    <url>http://maven.apache.org/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MPA</url>
    </issueManagement>
    <ciManagement>
      <system>continuum</system>
      <url>http://maven.zones.apache.org:8080/continuum</url>
      <notifiers>
        <notifier>
          <type>mail</type>
          <configuration>
            <address>notifications at maven.apache.org</address>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2002</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven Announcements List</name>
        <post>announce at maven.apache.org</post>
        <subscribe>announce-subscribe at maven.apache.org</subscribe>
        <unsubscribe>announce-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-announce/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Issues List</name>
        <post>issues at maven.apache.org</post>
        <subscribe>issues-subscribe at maven.apache.org</subscribe>
        <unsubscribe>issues-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-issues/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Notifications List</name>
        <post>notifications at maven.apache.org</post>
        <subscribe>notifications-subscribe at maven.apache.org</subscribe>
        <unsubscribe>notifications-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-notifications/</archive>
      </mailingList>
    </mailingLists>
  
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Chair</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at apache.org</email>
        <organization>Neonics</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
      </developer>
      <developer>
        <id>snicoll</id>
        <name>Stephane Nicoll</name>
        <email>snicoll at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vmassol</id>
        <name>Vincent Massol</name>
        <email>vmassol at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>fgiust</id>
        <name>Fabrizio Giustina</name>
        <email>fgiust at apache.org</email>
        <organization>openmind</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>epunzalan</id>
        <name>Edwin Punzalan</name>
        <email>epunzalan at mergere.com</email>
        <organization>Mergere</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>+8</timezone>
      </developer>
      <developer>
        <id>mperham</id>
        <name>Mike Perham</name>
        <email>mperham at gmail.com</email>
        <organization>IBM</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>-6</timezone>
      </developer>
      <developer>
        <id>jdcasey</id>
        <name>John Casey</name>
        <email>jdcasey at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vsiveton</id>
        <name>Vincent Siveton</name>
        <email>vsiveton at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>carlos</id>
        <name>Carlos Sanchez</name>
        <email>carlos at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>dennisl</id>
        <name>Dennis Lundberg</name>
        <email>dennisl at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
    </developers>
  
    <distributionManagement>
      <site>
        <id>apache.website</id>
        <url>scp://people.apache.org/www/maven.apache.org</url>
      </site>
    </distributionManagement>
  
  <!-- Disabled until projects have been made to comply
    <build>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-pmd-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>cpd-check</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
  -->
  
    <reporting>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-report-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-checkstyle-plugin</artifactId>
          <configuration>
            <configLocation>http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-checkstyle-plugin/src/main/resources/config/maven_checks.xml</configLocation>
            <headerLocation>http://svn.apache.org/repos/asf/maven/plugins/trunk/maven-checkstyle-plugin/src/main/resources/config/maven-header.txt</headerLocation>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-pmd-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>cobertura-maven-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>taglist-maven-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jxr-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <configuration>
            <links>
              <link>http://java.sun.com/j2ee/1.4/docs/api</link>
              <link>http://java.sun.com/j2se/1.5.0/docs/api</link>
              <link>http://jakarta.apache.org/commons/collections/apidocs-COLLECTIONS_3_0/</link>
              <link>http://jakarta.apache.org/commons/dbcp/apidocs/</link>
              <link>http://jakarta.apache.org/commons/fileupload/apidocs/</link>
              <link>http://jakarta.apache.org/commons/httpclient/apidocs/</link>
              <link>http://jakarta.apache.org/commons/logging/apidocs/</link>
              <link>http://jakarta.apache.org/commons/pool/apidocs/</link>
              <link>http://www.junit.org/junit/javadoc/</link>
              <link>http://logging.apache.org/log4j/docs/api/</link>
              <link>http://jakarta.apache.org/regexp/apidocs/</link>
              <link>http://jakarta.apache.org/velocity/api/</link>
            </links>
          </configuration>
        </plugin>
      </plugins>
    </reporting>
  
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/pom/maven/tags/maven-parent-4</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/pom/maven/tags/maven-parent-4</developerConnection>
      <url>http://svn.apache.org/viewvc/maven/pom/maven/tags/maven-parent-4</url>
    </scm>
  </project>
  
  
  
  
  1.1      date: 2006/12/10 17:01:10;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-parent/4/maven-parent-4.pom.sha1
  
  Index: maven-parent-4.pom.sha1
  ===================================================================
  0fc039b0bd4d17d7c147a30e1d83994629c5297c
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:13 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:13 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-api/2.0 ...
Message-ID: <E1GtS37-0005Uf-TM@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:13

  Added:       maven2/org/apache/maven/maven-plugin-api/2.0  
                        maven-plugin-api-2.0.pom
                        maven-plugin-api-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:13;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.pom
  
  Index: maven-plugin-api-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-plugin-api</artifactId>
    <name>Maven Plugin API</name>
    <version>2.0</version>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:13;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.pom.sha1
  
  Index: maven-plugin-api-2.0.pom.sha1
  ===================================================================
  4712e15fddee58ed471b2758facce36030e21b83  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:17 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:17 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor/2.0
	...
Message-ID: <E1GtS3B-0005V3-Jx@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:17

  Added:       maven2/org/apache/maven/maven-plugin-descriptor/2.0  
                        maven-plugin-descriptor-2.0.pom
                        maven-plugin-descriptor-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:17;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor/2.0/maven-plugin-descriptor-2.0.pom
  
  Index: maven-plugin-descriptor-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-plugin-descriptor</artifactId>
    <name>Maven Plugin Descriptor Model</name>
    <version>2.0</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
                <goal>xpp3-writer</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <model>src/main/mdo/lifecycle.mdo</model>
            <version>1.0.0</version>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:17;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-descriptor/2.0/maven-plugin-descriptor-2.0.pom.sha1
  
  Index: maven-plugin-descriptor-2.0.pom.sha1
  ===================================================================
  7359de4f4f48a32e36b7b61c94cbf550a4694c1a  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-plugin-descriptor/2.0/maven-plugin-descriptor-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:22 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:22 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0
	...
Message-ID: <E1GtS3G-0005VJ-EN@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:22

  Added:       maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0  
                        maven-plugin-parameter-documenter-2.0.pom
                        maven-plugin-parameter-documenter-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:22;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0/maven-plugin-parameter-documenter-2.0.pom
  
  Index: maven-plugin-parameter-documenter-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-plugin-parameter-documenter</artifactId>
    <name>Maven Plugin Parameter Documenter API</name>
    <version>2.0</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <id>base</id>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
              </goals>
            </execution>
            <execution>
              <id>xsd</id>
              <phase>generate-sources</phase>
              <goals>
                <goal>xsd</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <version>1.0.0</version>
            <model>src/main/mdo/paramdoc.mdo</model>
            <packageWithVersion>false</packageWithVersion>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:22;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0/maven-plugin-parameter-documenter-2.0.pom.sha1
  
  Index: maven-plugin-parameter-documenter-2.0.pom.sha1
  ===================================================================
  b6a1ae66a56dfea8531348ed6ed00b2892167a09  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0/maven-plugin-parameter-documenter-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:25 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:25 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry/2.0
	...
Message-ID: <E1GtS3J-0005VZ-Op@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:25

  Added:       maven2/org/apache/maven/maven-plugin-registry/2.0  
                        maven-plugin-registry-2.0.pom
                        maven-plugin-registry-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:25;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry/2.0/maven-plugin-registry-2.0.pom
  
  Index: maven-plugin-registry-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-plugin-registry</artifactId>
    <name>Maven Plugin Registry Model</name>
    <version>2.0</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
              </goals>
              <configuration>
                <version>1.0.0</version>
                <model>plugin-registry.mdo</model>
              </configuration>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:25;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-plugin-registry/2.0/maven-plugin-registry-2.0.pom.sha1
  
  Index: maven-plugin-registry-2.0.pom.sha1
  ===================================================================
  df5235f26d58fbeb0c41759e19dba31d4885e77e  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-plugin-registry/2.0/maven-plugin-registry-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:28 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:28 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-profile/2.0 ...
Message-ID: <E1GtS3M-0005Vp-Pn@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:28

  Added:       maven2/org/apache/maven/maven-profile/2.0  
                        maven-profile-2.0.pom maven-profile-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:28;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-profile/2.0/maven-profile-2.0.pom
  
  Index: maven-profile-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-profile</artifactId>
    <name>Maven Profile Model</name>
    <version>2.0</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
              </goals>
              <configuration>
                <version>1.0.0</version>
                <model>profiles.mdo</model>
              </configuration>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-model</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:28;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-profile/2.0/maven-profile-2.0.pom.sha1
  
  Index: maven-profile-2.0.pom.sha1
  ===================================================================
  b1c9a2e447068d9ac0d7834afcf3f962d24aebff  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-profile/2.0/maven-profile-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:32 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:32 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-project/2.0 ...
Message-ID: <E1GtS3Q-0005W5-Nc@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:32

  Added:       maven2/org/apache/maven/maven-project/2.0  
                        maven-project-2.0.pom maven-project-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:32;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-project/2.0/maven-project-2.0.pom
  
  Index: maven-project-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-project</artifactId>
    <name>Maven Project Builder</name>
    <version>2.0</version>
    <description>This library is used to not only read Maven project object model files, but to assemble inheritence
      and to retrieve remote models as required.</description>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-test</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-profile</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-model</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-manager</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:32;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-project/2.0/maven-project-2.0.pom.sha1
  
  Index: maven-project-2.0.pom.sha1
  ===================================================================
  296a476d8e125fc1d7621c24320d7fedc0019ff1  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-project/2.0/maven-project-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:35 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:35 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata/2.0
	...
Message-ID: <E1GtS3T-0005WL-Nt@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:35

  Added:       maven2/org/apache/maven/maven-repository-metadata/2.0  
                        maven-repository-metadata-2.0.pom
                        maven-repository-metadata-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:35;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata/2.0/maven-repository-metadata-2.0.pom
  
  Index: maven-repository-metadata-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven-repository-metadata</artifactId>
    <name>Maven Repository Metadata Model</name>
    <version>2.0</version>
    <description>Maven Plugin Mapping</description>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
                <goal>xsd</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <version>1.0.0</version>
            <model>src/main/mdo/metadata.mdo</model>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:35;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-repository-metadata/2.0/maven-repository-metadata-2.0.pom.sha1
  
  Index: maven-repository-metadata-2.0.pom.sha1
  ===================================================================
  c8f40fad92bb0e75465e4cf800021264f3024bfa  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-repository-metadata/2.0/maven-repository-metadata-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:38 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:38 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/maven-settings/2.0 ...
Message-ID: <E1GtS3W-0005Wb-Jh@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:38

  Added:       maven2/org/apache/maven/maven-settings/2.0  
                        maven-settings-2.0.pom maven-settings-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:38;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-settings/2.0/maven-settings-2.0.pom
  
  Index: maven-settings-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-settings</artifactId>
    <name>Maven Local Settings Model</name>
    <version>2.0</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.modello</groupId>
          <artifactId>modello-maven-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>xpp3-writer</goal>
                <goal>java</goal>
                <goal>xpp3-reader</goal>
              </goals>
              <configuration>
                <version>1.0.0</version>
                <model>settings.mdo</model>
              </configuration>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-model</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:38;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven-settings/2.0/maven-settings-2.0.pom.sha1
  
  Index: maven-settings-2.0.pom.sha1
  ===================================================================
  76982480c0e25f8ba8e9af7c2d3e743f649553bc  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven-settings/2.0/maven-settings-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:41 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven/2.0.2
	...
Message-ID: <E1GtS3Z-0005Ws-Qd@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:41

  Added:       maven2/org/apache/maven/maven/2.0.2   maven-2.0.2.pom
                        maven-2.0.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven/2.0.2/maven-2.0.2.pom
  
  Index: maven-2.0.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven</artifactId>
    <packaging>pom</packaging>
    <name>Maven</name>
    <version>2.0.2</version>
    <description>Maven is a project development management and comprehension tool. Based on the concept of a project object model: builds, dependency management, documentation creation, site publication, and distribution publication are all controlled from the declarative file. Maven can be extended by plugins to utilise a number of other development tools for reporting or the build process.</description>
    <url>http://maven.apache.org/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MNG</url>
    </issueManagement>
    <ciManagement>
      <system>continuum</system>
      <notifiers>
        <notifier>
          <configuration>
            <address>commits at maven.apache.org</address>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <mailingLists>
      <mailingList>
        <name>Maven User List</name>
        <subscribe>users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>users-unsubscribe at maven.apache.org</unsubscribe>
        <post>users at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-users</archive>
        <otherArchives>
          <otherArchive>http://www.mail-archive.com/users at maven.apache.org/</otherArchive>
          <otherArchive>http://www.nabble.com/Maven---Users-f178.html</otherArchive>
        </otherArchives>
      </mailingList>
      <mailingList>
        <name>Maven Developer List</name>
        <subscribe>dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>dev-unsubscribe at maven.apache.org</unsubscribe>
        <post>dev at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-dev</archive>
      </mailingList>
      <mailingList>
        <name>Maven Commits List</name>
        <subscribe>commits-subscribe at maven.apache.org</subscribe>
        <unsubscribe>commits-unsubscribe at maven.apache.org</unsubscribe>
        <post>commits at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-dev</archive>
      </mailingList>
      <mailingList>
        <name>Apache Announce List</name>
        <subscribe>announce-subscribe at apache.org</subscribe>
        <unsubscribe>announce-unsubscribe at apache.org</unsubscribe>
        <post>announce at apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/www-announce/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Chair</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>jdcasey</id>
        <name>John Casey</name>
        <email>jdcasey at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at apache.org</email>
        <organization>Neonics</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vmassol</id>
        <name>Vincent Massol</name>
        <email>vmassol at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vsiveton</id>
        <name>Vincent Siveton</name>
        <email>vsiveton at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
    </developers>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.2</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/components/tags/maven-2.0.2</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/components/tags/maven-2.0.2</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    <modules>
      <module>maven-archiver</module>
      <module>maven-artifact</module>
      <module>maven-artifact-manager</module>
      <module>maven-artifact-test</module>
      <module>maven-core</module>
      <module>maven-error-diagnostics</module>
      <module>maven-model</module>
      <module>maven-model-converter</module>
      <module>maven-monitor</module>
      <module>maven-plugin-api</module>
      <module>maven-plugin-descriptor</module>
      <module>maven-plugin-parameter-documenter</module>
      <module>maven-plugin-registry</module>
      <module>maven-plugin-tools</module>
      <module>maven-profile</module>
      <module>maven-project</module>
      <module>maven-reporting</module>
      <module>maven-repository-metadata</module>
      <module>maven-script</module>
      <module>maven-settings</module>
    </modules>
    <repositories>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </repository>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>apache.snapshots</id>
        <name>Apache Development Repository</name>
        <url>http://cvs.apache.org/maven-snapshot-repository</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Central Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <reporting>
      <plugins>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>changelog-maven-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>taglist-maven-plugin</artifactId>
        </plugin>
      </plugins>
    </reporting>
    <dependencyManagement>
      <dependencies>
        <dependency>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-container-default</artifactId>
          <version>1.0-alpha-9</version>
        </dependency>
        <dependency>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-utils</artifactId>
          <version>1.1</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-provider-api</artifactId>
          <version>1.0-alpha-6</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-ssh</artifactId>
          <version>1.0-alpha-6</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-ssh-external</artifactId>
          <version>1.0-alpha-6</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-file</artifactId>
          <version>1.0-alpha-6</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-http-lightweight</artifactId>
          <version>1.0-alpha-6</version>
        </dependency>
      </dependencies>
    </dependencyManagement>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>apache.snapshots</id>
        <name>Apache Development Repository</name>
        <url>scp://minotaur.apache.org/www/cvs.apache.org/maven-snapshot-repository</url>
      </snapshotRepository>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/</url>
      </site>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven/2.0.2/maven-2.0.2.pom.sha1
  
  Index: maven-2.0.2.pom.sha1
  ===================================================================
  816e22beec3ee5c4a344959625a824bb6202daeb
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:41 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/maven/maven/2.0 ...
Message-ID: <E1GtS3Z-0005X2-UU@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:41

  Added:       maven2/org/apache/maven/maven/2.0   maven-2.0.pom
                        maven-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven/2.0/maven-2.0.pom
  
  Index: maven-2.0.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven</groupId>
    <artifactId>maven</artifactId>
    <packaging>pom</packaging>
    <name>Maven</name>
    <version>2.0</version>
    <description>Maven is a project development management and comprehension tool. Based on the concept of a project object model: builds, dependency management, documentation creation, site publication, and distribution publication are all controlled from the declarative file. Maven can be extended by plugins to utilise a number of other development tools for reporting or the build process.</description>
    <url>http://maven.apache.org/maven2/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MNG</url>
    </issueManagement>
    <ciManagement>
      <system>continuum</system>
      <notifiers>
        <notifier>
          <configuration>
            <address>commits at maven.apache.org</address>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <mailingLists>
      <mailingList>
        <name>Maven User List</name>
        <subscribe>users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>users-unsubscribe at maven.apache.org</unsubscribe>
        <post>users at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-users</archive>
      </mailingList>
      <mailingList>
        <name>Maven Developer List</name>
        <subscribe>dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>dev-unsubscribe at maven.apache.org</unsubscribe>
        <post>dev at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-dev</archive>
      </mailingList>
      <mailingList>
        <name>Maven Commits List</name>
        <subscribe>commits-subscribe at maven.apache.org</subscribe>
        <unsubscribe>commits-unsubscribe at maven.apache.org</unsubscribe>
        <post>commits at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-dev</archive>
      </mailingList>
      <mailingList>
        <name>Apache Announce List</name>
        <subscribe>announce-subscribe at apache.org</subscribe>
        <unsubscribe>announce-unsubscribe at apache.org</unsubscribe>
        <post>announce at apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/www-announce/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Chair</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>jdcasey</id>
        <name>John Casey</name>
        <email>jdcasey at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at apache.org</email>
        <organization>Neonics</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vmassol</id>
        <name>Vincent Massol</name>
        <email>vmassol at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vsiveton</id>
        <name>Vincent Siveton</name>
        <email>vsiveton at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
    </developers>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/components/tags/maven-2.0</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/components/tags/maven-2.0</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/components/tags/maven-2.0</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    <modules>
      <module>maven-archiver</module>
      <module>maven-artifact</module>
      <module>maven-artifact-manager</module>
      <module>maven-artifact-ant</module>
      <module>maven-artifact-test</module>
      <module>maven-core</module>
      <module>maven-error-diagnostics</module>
      <module>maven-model</module>
      <module>maven-monitor</module>
      <module>maven-plugin-api</module>
      <module>maven-plugin-descriptor</module>
      <module>maven-plugin-parameter-documenter</module>
      <module>maven-plugin-registry</module>
      <module>maven-plugin-tools</module>
      <module>maven-profile</module>
      <module>maven-project</module>
      <module>maven-reporting</module>
      <module>maven-repository-metadata</module>
      <module>maven-script</module>
      <module>maven-settings</module>
    </modules>
    <repositories>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Central Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <dependencyManagement>
      <dependencies>
        <dependency>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-container-default</artifactId>
          <version>1.0-alpha-8</version>
        </dependency>
        <dependency>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-utils</artifactId>
          <version>1.0.4</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-provider-api</artifactId>
          <version>1.0-alpha-5</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-ssh</artifactId>
          <version>1.0-alpha-5</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-file</artifactId>
          <version>1.0-alpha-5</version>
        </dependency>
        <dependency>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-http-lightweight</artifactId>
          <version>1.0-alpha-5</version>
        </dependency>
      </dependencies>
    </dependencyManagement>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/maven2/</url>
      </site>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/maven/2.0/maven-2.0.pom.sha1
  
  Index: maven-2.0.pom.sha1
  ===================================================================
  39ab6e95d88924b2ff950099a5ba7040b2280e84  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/maven/2.0/maven-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:46 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:46 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0
	...
Message-ID: <E1GtS3e-0005XN-04@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:45

  Added:       maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0    
                        maven-compiler-plugin-2.0.jar
                        maven-compiler-plugin-2.0.jar.sha1
                        maven-compiler-plugin-2.0.pom
                        maven-compiler-plugin-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:01:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.jar.sha1
  
  Index: maven-compiler-plugin-2.0.jar.sha1
  ===================================================================
  149c489f48e489366cf354933adb7ef49facfb2f
  
  
  1.1      date: 2006/12/10 17:01:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.pom
  
  Index: maven-compiler-plugin-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven-plugin-parent</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-compiler-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Compiler Plugin</name>
    <version>2.0</version>
    <inceptionYear>2001</inceptionYear>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-compiler-api</artifactId>
        <version>1.5.1</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-compiler-manager</artifactId>
        <version>1.5.1</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-compiler-javac</artifactId>
        <version>1.5.1</version>
        <scope>runtime</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.pom.sha1
  
  Index: maven-compiler-plugin-2.0.pom.sha1
  ===================================================================
  1a91c9cccd059c740ebd79426d7c331f4c519039  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1
	...
Message-ID: <E1GtS3h-0005Xj-SE@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:49

  Added:       maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1    
                        maven-deploy-plugin-2.2.1.jar
                        maven-deploy-plugin-2.2.1.jar.sha1
                        maven-deploy-plugin-2.2.1.pom
                        maven-deploy-plugin-2.2.1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:01:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.jar.sha1
  
  Index: maven-deploy-plugin-2.2.1.jar.sha1
  ===================================================================
  fc159b5f56ff34a1f83b4de54afbb9d313a64eab
  
  
  1.1      date: 2006/12/10 17:01:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.pom
  
  Index: maven-deploy-plugin-2.2.1.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>maven-plugins</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-deploy-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Deploy Plugin</name>
    <version>2.2.1</version>
    <inceptionYear>2004</inceptionYear>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-deploy-plugin-2.2.1</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-deploy-plugin-2.2.1</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/plugins/tags/maven-deploy-plugin-2.2.1</url>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-core</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-manager</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.shared</groupId>
        <artifactId>maven-plugin-testing-harness</artifactId>
        <version>1.0-beta-1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.pom.sha1
  
  Index: maven-deploy-plugin-2.2.1.pom.sha1
  ===================================================================
  7c4f0078101fc06ac658f6f6712c4e52d44bfc4a
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin
	...
Message-ID: <E1GtS3h-0005Xt-Vm@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:49

  Added:       maven2/org/apache/maven/plugins/maven-deploy-plugin  
                        maven-metadata-central.xml
                        maven-metadata-jbosspluginrepo.xml
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-deploy-plugin</artifactId>
    <versioning>
      <latest>2.2.1</latest>
      <release>2.2.1</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0</version>
        <version>2.1</version>
        <version>2.2</version>
        <version>2.2.1</version>
      </versions>
      <lastUpdated>20060627142250</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:01:49;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata-jbosspluginrepo.xml
  
  Index: maven-metadata-jbosspluginrepo.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-deploy-plugin</artifactId>
    <version>LATEST</version>
  </metadata>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:53 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1
	...
Message-ID: <E1GtS3l-0005YF-PU@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:53

  Added:       maven2/org/apache/maven/plugins/maven-install-plugin/2.1    
                        maven-install-plugin-2.1.jar
                        maven-install-plugin-2.1.jar.sha1
                        maven-install-plugin-2.1.pom
                        maven-install-plugin-2.1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.jar.sha1
  
  Index: maven-install-plugin-2.1.jar.sha1
  ===================================================================
  f6aa3f17c5702fed4b0f7a015233cc3bdc369b01
  
  
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.pom
  
  Index: maven-install-plugin-2.1.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>maven-plugin-parent</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-install-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Install Plugin</name>
    <version>2.1</version>
    <inceptionYear>2004</inceptionYear>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-manager</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.pom.sha1
  
  Index: maven-install-plugin-2.1.pom.sha1
  ===================================================================
  56573551545c267883f5bd095f328daeea741846
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:53 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin
	...
Message-ID: <E1GtS3l-0005YS-UX@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:53

  Added:       maven2/org/apache/maven/plugins/maven-install-plugin   
                        maven-metadata-central.xml
                        maven-metadata-central.xml.sha1
                        maven-metadata-jbosspluginrepo.xml
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-install-plugin</artifactId>
    <versioning>
      <latest>2.1</latest>
      <release>2.1</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0</version>
        <version>2.1</version>
      </versions>
      <lastUpdated>20060111214838</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/maven-metadata-central.xml.sha1
  
  Index: maven-metadata-central.xml.sha1
  ===================================================================
  a103e77fae583c08d8c54fe23bf6247ec8e28f6b
  
  
  1.1      date: 2006/12/10 17:01:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-install-plugin/maven-metadata-jbosspluginrepo.xml
  
  Index: maven-metadata-jbosspluginrepo.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-install-plugin</artifactId>
    <version>LATEST</version>
  </metadata>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:58 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:58 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1
	...
Message-ID: <E1GtS3q-0005Yp-D3@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:58

  Added:       maven2/org/apache/maven/plugins/maven-jar-plugin/2.1    
                        maven-jar-plugin-2.1.jar
                        maven-jar-plugin-2.1.jar.sha1
                        maven-jar-plugin-2.1.pom
                        maven-jar-plugin-2.1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.jar.sha1
  
  Index: maven-jar-plugin-2.1.jar.sha1
  ===================================================================
  980129713b81c844b3538bafbd37ff131941d384
  
  
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.pom
  
  Index: maven-jar-plugin-2.1.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>maven-plugins</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>3</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-jar-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Jar Plugin</name>
    <version>2.1</version>
    <prerequisites />
    <issueManagement>
      <system>JIRA</system>
      <url>http://jira.codehaus.org/browse/MJAR</url>
    </issueManagement>
    <contributors>
      <contributor>
        <name>Jerome Lacoste</name>
        <email>jerome at coffeebreaks.org</email>
        <organization>CoffeeBreaks</organization>
        <organizationUrl>http://www.coffeebreaks.org</organizationUrl>
        <roles>
          <role>Java Developer</role>
        </roles>
        <timezone>+1</timezone>
      </contributor>
    </contributors>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-jar-plugin-2.1</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-jar-plugin-2.1</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/plugins/tags/maven-jar-plugin-2.1</url>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-archiver</artifactId>
        <version>2.2</version>
      </dependency>
      <dependency>
        <groupId>commons-lang</groupId>
        <artifactId>commons-lang</artifactId>
        <version>2.1</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.shared</groupId>
        <artifactId>maven-plugin-testing-harness</artifactId>
        <version>1.0-beta-1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.pom.sha1
  
  Index: maven-jar-plugin-2.1.pom.sha1
  ===================================================================
  bcc414740e613ea328f90b2417bbe3e364b95db2
  
  


From scott.stark at jboss.com  Sun Dec 10 12:01:58 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:01:58 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin
	...
Message-ID: <E1GtS3q-0005Z2-HG@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:01:58

  Added:       maven2/org/apache/maven/plugins/maven-jar-plugin   
                        maven-metadata-central.xml
                        maven-metadata-central.xml.sha1
                        maven-metadata-jbosspluginrepo.xml
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-jar-plugin</artifactId>
    <versioning>
      <latest>2.1</latest>
      <release>2.1</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0-rc1</version>
        <version>2.0</version>
        <version>2.1</version>
      </versions>
      <lastUpdated>20060831141752</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata-central.xml.sha1
  
  Index: maven-metadata-central.xml.sha1
  ===================================================================
  f831214fd553401f2d1d3dc64ade0f263e1333e7
  
  
  1.1      date: 2006/12/10 17:01:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata-jbosspluginrepo.xml
  
  Index: maven-metadata-jbosspluginrepo.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-jar-plugin</artifactId>
    <version>LATEST</version>
  </metadata>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:01 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:01 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent/2.0
	...
Message-ID: <E1GtS3t-0005bD-O8@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:01

  Added:       maven2/org/apache/maven/plugins/maven-plugin-parent/2.0  
                        maven-plugin-parent-2.0.pom
                        maven-plugin-parent-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:01;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent/2.0/maven-plugin-parent-2.0.pom
  
  Index: maven-plugin-parent-2.0.pom
  ===================================================================
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-plugin-parent</artifactId>
    <packaging>pom</packaging>
    <version>2.0</version>
    <name>Maven Plugins</name>
    <description>Maven plugin parent</description>
    <url>http://maven.apache.org/maven2/plugins/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MNG</url>
    </issueManagement>
    <ciManagement>
      <system>continuum</system>
      <notifiers>
        <notifier>
          <type>mail</type>
          <configuration>
            <address>commits at maven.apache.org</address>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <organization>Maven</organization>
        <roles>
          <role>PMC Chair</role>
        </roles>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at apache.org</email>
        <organization>Neonics</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
      </developer>
      <developer>
        <id>snicoll</id>
        <name>Stephane Nicoll</name>
        <email>snicoll at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>Committer</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
      <developer>
        <id>vmassol</id>
        <name>Vincent Massol</name>
        <email>vmassol at apache.org</email>
        <organization>ASF</organization>
        <roles>
          <role>PMC Member</role>
        </roles>
        <timezone>+1</timezone>
      </developer>
    </developers>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
    </dependencies>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <distributionManagement>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Plugins Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <repository>
        <id>repo1</id>
        <name>Maven Central Plugins Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/maven2/plugins/</url>
      </site>
    </distributionManagement>
    <repositories>
      <repository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <id>snapshots</id>
        <name>Maven Central Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </pluginRepository>
    </pluginRepositories>
    <dependencyManagement>
      <dependencies>
        <dependency>
          <groupId>org.apache.maven</groupId>
          <artifactId>maven-project</artifactId>
          <version>2.0</version>
        </dependency>
        <dependency>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-container-default</artifactId>
          <version>1.0-alpha-8</version>
        </dependency>
        <dependency>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-utils</artifactId>
          <version>1.0.4</version>
        </dependency>
      </dependencies>
    </dependencyManagement>
    <modules>
      <module>maven-ant-plugin</module>
      <module>maven-antrun-plugin</module>
      <module>maven-assembly-plugin</module>
      <module>maven-checkstyle-plugin</module>
      <module>maven-clean-plugin</module>
      <module>maven-clover-plugin</module>
      <module>maven-compiler-plugin</module>
      <module>maven-deploy-plugin</module>
      <module>maven-eclipse-plugin</module>
      <module>maven-ear-plugin</module>
      <module>maven-ejb-plugin</module>
      <module>maven-idea-plugin</module>
      <module>maven-install-plugin</module>
      <module>maven-jar-plugin</module>
      <module>maven-javadoc-plugin</module>
      <module>maven-plugin-plugin</module>
      <module>maven-pmd-plugin</module>
      <module>maven-projecthelp-plugin</module>
      <module>maven-project-info-reports-plugin</module>
      <module>maven-rar-plugin</module>
      <module>maven-release-plugin</module>
      <module>maven-resources-plugin</module>
      <module>maven-site-plugin</module>
      <module>maven-source-plugin</module>
      <module>maven-surefire-plugin</module>
      <module>maven-war-plugin</module>
      <module>maven-verifier-plugin</module>
    </modules>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/components/trunk/maven-plugins/</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/components/trunk/maven-plugins/</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/components/trunk/maven-plugins/</url>
    </scm>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/components/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    <reporting>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-plugin-plugin</artifactId>
        </plugin>
      </plugins>
    </reporting>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:02:01;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugin-parent/2.0/maven-plugin-parent-2.0.pom.sha1
  
  Index: maven-plugin-parent-2.0.pom.sha1
  ===================================================================
  ad0eeafe2ce2a87b3670112ce4806f4798c42b21  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/plugins/maven-plugin-parent/2.0/maven-plugin-parent-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:04 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:04 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/1
	...
Message-ID: <E1GtS3w-0005kJ-Od@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:04

  Added:       maven2/org/apache/maven/plugins/maven-plugins/1  
                        maven-plugins-1.pom maven-plugins-1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:04;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/1/maven-plugins-1.pom
  
  Index: maven-plugins-1.pom
  ===================================================================
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-parent</artifactId>
      <version>1</version>
      <relativePath>../pom/maven/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-plugins</artifactId>
    <packaging>pom</packaging>
    <version>1</version>
    <name>Maven Plugins</name>
    <description>Maven Plugins</description>
    <url>http://maven.apache.org/plugins/</url>
    <distributionManagement>
      <site>
        <id>apache.website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/plugins/</url>
      </site>
    </distributionManagement>
    <repositories>
      <repository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </repository>
    </repositories>
    <modules>
      <module>maven-ant-plugin</module>
      <module>maven-antrun-plugin</module>
      <module>maven-assembly-plugin</module>
      <module>maven-checkstyle-plugin</module>
      <module>maven-clean-plugin</module>
      <module>maven-clover-plugin</module>
      <module>maven-compiler-plugin</module>
      <module>maven-deploy-plugin</module>
      <module>maven-eclipse-plugin</module>
      <module>maven-ear-plugin</module>
      <module>maven-ejb-plugin</module>
      <module>maven-help-plugin</module>
      <module>maven-idea-plugin</module>
      <module>maven-install-plugin</module>
      <module>maven-jar-plugin</module>
      <module>maven-javadoc-plugin</module>
      <module>maven-plugin-plugin</module>
      <module>maven-pmd-plugin</module>
      <module>maven-project-info-reports-plugin</module>
      <module>maven-rar-plugin</module>
      <module>maven-release-plugin</module>
      <module>maven-repository-plugin</module>    
      <module>maven-resources-plugin</module>
      <module>maven-site-plugin</module>
      <module>maven-source-plugin</module>
      <module>maven-surefire-plugin</module>
      <module>maven-war-plugin</module>
      <module>maven-verifier-plugin</module>
    </modules>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/trunk/</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/plugins/trunk/</url>
    </scm>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/plugins/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    <reporting>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-plugin-plugin</artifactId>
        </plugin>
      </plugins>
    </reporting>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:02:04;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/1/maven-plugins-1.pom.sha1
  
  Index: maven-plugins-1.pom.sha1
  ===================================================================
  7a8fcbb5c906218537c74b78a7b8526e478c9b3b
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:04 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:04 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/3
	...
Message-ID: <E1GtS3w-0005kT-SX@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:04

  Added:       maven2/org/apache/maven/plugins/maven-plugins/3  
                        maven-plugins-3.pom maven-plugins-3.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:04;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/3/maven-plugins-3.pom
  
  Index: maven-plugins-3.pom
  ===================================================================
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-parent</artifactId>
      <version>4</version>
      <relativePath>../pom/maven/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-plugins</artifactId>
    <packaging>pom</packaging>
    <version>3</version>
    <name>Maven Plugins</name>
    <description>Maven Plugins</description>
    <url>http://maven.apache.org/plugins/</url>
    <mailingLists>
      <mailingList>
        <name>Maven User List</name>
        <subscribe>users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>users-unsubscribe at maven.apache.org</unsubscribe>
        <post>users at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-users</archive>
        <otherArchives>
          <otherArchive>http://www.mail-archive.com/users at maven.apache.org/</otherArchive>
          <otherArchive>http://www.nabble.com/Maven---Users-f178.html</otherArchive>
        </otherArchives>
      </mailingList>
      <mailingList>
        <name>Maven Developer List</name>
        <subscribe>dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>dev-unsubscribe at maven.apache.org</unsubscribe>
        <post>dev at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-dev</archive>
      </mailingList>
      <mailingList>
        <name>Maven Commits List</name>
        <subscribe>commits-subscribe at maven.apache.org</subscribe>
        <unsubscribe>commits-unsubscribe at maven.apache.org</unsubscribe>
        <post>commits at maven.apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-dev</archive>
      </mailingList>
      <!-- duplication from parent pom - temporary until they inherit properly -->
      <mailingList>
        <name>Maven Announcements List</name>
        <post>announce at maven.apache.org</post>
        <subscribe>announce-subscribe at maven.apache.org</subscribe>
        <unsubscribe>announce-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-announce/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Issues List</name>
        <post>issues at maven.apache.org</post>
        <subscribe>issues-subscribe at maven.apache.org</subscribe>
        <unsubscribe>issues-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-issues/</archive>
      </mailingList>
      <mailingList>
        <name>Maven Notifications List</name>
        <post>notifications at maven.apache.org</post>
        <subscribe>notifications-subscribe at maven.apache.org</subscribe>
        <unsubscribe>notifications-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-notifications/</archive>
      </mailingList>
    </mailingLists>
    <distributionManagement>
      <site>
        <id>apache.website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/plugins/</url>
      </site>
    </distributionManagement>
    <modules>
      <module>maven-ant-plugin</module>
      <module>maven-antlr-plugin</module>
      <module>maven-antrun-plugin</module>
      <module>maven-assembly-plugin</module>
      <module>maven-changelog-plugin</module>
      <module>maven-changes-plugin</module>
      <module>maven-checkstyle-plugin</module>
      <module>maven-clean-plugin</module>
      <module>maven-clover-plugin</module>
      <module>maven-compiler-plugin</module>
      <module>maven-dependency-plugin</module>
      <module>maven-deploy-plugin</module>
      <module>maven-doap-plugin</module>
      <module>maven-docck-plugin</module>
      <module>maven-ear-plugin</module>
      <module>maven-eclipse-plugin</module>
      <module>maven-ejb-plugin</module>
      <module>maven-help-plugin</module>
      <module>maven-idea-plugin</module>
      <module>maven-install-plugin</module>
      <module>maven-jar-plugin</module>
      <module>maven-javadoc-plugin</module>
      <module>maven-jxr-plugin</module>
      <module>maven-one-plugin</module>
      <module>maven-plugin-plugin</module>
      <module>maven-pmd-plugin</module>
      <module>maven-project-info-reports-plugin</module>
      <module>maven-rar-plugin</module>
      <module>maven-release-plugin</module>
      <module>maven-repository-plugin</module>
      <module>maven-resources-plugin</module>
      <module>maven-site-plugin</module>
      <module>maven-source-plugin</module>
      <module>maven-surefire-plugin</module>
      <module>maven-surefire-report-plugin</module>
      <module>maven-war-plugin</module>
      <module>maven-verifier-plugin</module>
    </modules>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/plugins/trunk/</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/trunk/</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/plugins/trunk/</url>
    </scm>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/plugins/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    <reporting>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-plugin-plugin</artifactId>
          <version>2.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-jxr-plugin</artifactId>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
        </plugin>
      </plugins>
    </reporting>
    <profiles>
      <profile>
        <id>ciProfile</id>
        <activation>
          <property>
            <name>enableCiProfile</name>
            <value>true</value>
          </property>
        </activation>
        <build>
          <plugins>
            <plugin>
              <artifactId>maven-docck-plugin</artifactId>
              <executions>
                <execution>
                  <goals>
                    <goal>check</goal>
                  </goals>
                </execution>
              </executions>
            </plugin>
          </plugins>
        </build>
      </profile>
    </profiles>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:02:04;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-plugins/3/maven-plugins-3.pom.sha1
  
  Index: maven-plugins-3.pom.sha1
  ===================================================================
  5eef2435337ed336286f1d8b3aa9350d341431e4
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:09 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2
	...
Message-ID: <E1GtS41-0005kp-2f@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:09

  Added:       maven2/org/apache/maven/plugins/maven-resources-plugin/2.2    
                        maven-resources-plugin-2.2.jar
                        maven-resources-plugin-2.2.jar.sha1
                        maven-resources-plugin-2.2.pom
                        maven-resources-plugin-2.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:08;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:08;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.jar.sha1
  
  Index: maven-resources-plugin-2.2.jar.sha1
  ===================================================================
  e2cf5e55cba391180e25e60c119c0da3f5ebfaf7
  
  
  1.1      date: 2006/12/10 17:02:08;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.pom
  
  Index: maven-resources-plugin-2.2.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>maven-plugins</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-resources-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Resources Plugin</name>
    <version>2.2</version>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-resources-plugin-2.2</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-resources-plugin-2.2</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/plugins/tags/maven-resources-plugin-2.2</url>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-model</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.shared</groupId>
        <artifactId>maven-plugin-testing-harness</artifactId>
        <version>1.0-beta-1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:08;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.pom.sha1
  
  Index: maven-resources-plugin-2.2.pom.sha1
  ===================================================================
  52f7a68959015d21337eec74f0807d637d0326e7
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:09 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin
	...
Message-ID: <E1GtS41-0005l2-6E@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:09

  Added:       maven2/org/apache/maven/plugins/maven-resources-plugin   
                        maven-metadata-central.xml
                        maven-metadata-central.xml.sha1
                        maven-metadata-jbosspluginrepo.xml
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-resources-plugin</artifactId>
    <versioning>
      <latest>2.2</latest>
      <release>2.2</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0-beta-2</version>
        <version>2.0</version>
        <version>2.1</version>
        <version>2.2</version>
      </versions>
      <lastUpdated>20060514041911</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:02:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/maven-metadata-central.xml.sha1
  
  Index: maven-metadata-central.xml.sha1
  ===================================================================
  a3cfebe482d6f90e4a4e31ef5ebd32770add19df
  
  
  1.1      date: 2006/12/10 17:02:09;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-resources-plugin/maven-metadata-jbosspluginrepo.xml
  
  Index: maven-metadata-jbosspluginrepo.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-resources-plugin</artifactId>
    <version>LATEST</version>
  </metadata>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5
	...
Message-ID: <E1GtS46-0005lO-HL@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:14

  Added:       maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5    
                        maven-site-plugin-2.0-beta-5.jar
                        maven-site-plugin-2.0-beta-5.jar.sha1
                        maven-site-plugin-2.0-beta-5.pom
                        maven-site-plugin-2.0-beta-5.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.jar.sha1
  
  Index: maven-site-plugin-2.0-beta-5.jar.sha1
  ===================================================================
  4c929cb24dcad46e37c3cebfe1095deb77f4b6bb
  
  
  1.1      date: 2006/12/10 17:02:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.pom
  
  Index: maven-site-plugin-2.0-beta-5.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>maven-plugins</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-site-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Site plugin</name>
    <version>2.0-beta-5</version>
    <prerequisites>
      <maven>2.0.2</maven>
    </prerequisites>
    <contributors>
      <contributor>
        <name>Naoki Nose</name>
        <email>ikkoan at mail.goo.ne.jp</email>
        <roles>
          <role>Japanese translator</role>
        </roles>
      </contributor>
      <contributor>
        <name>Michael Wechner</name>
        <email>michael.wechner at wyona.com</email>
        <roles>
          <role>German translator</role>
        </roles>
      </contributor>
      <contributor>
        <name>Piotr Bzdyl</name>
        <email>piotr at bzdyl.net</email>
        <roles>
          <role>Polish translator</role>
        </roles>
      </contributor>
      <contributor>
        <name>Domingos Creado</name>
        <email>dcreado at users.sf.net</email>
        <roles>
          <role>Brazilian Portuguese translator</role>
        </roles>
      </contributor>
      <contributor>
        <name>John Allen</name>
        <email>john_h_allen at hotmail.com</email>
      </contributor>
    </contributors>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-site-plugin-2.0-beta-5</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-site-plugin-2.0-beta-5</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/plugins/tags/maven-site-plugin-2.0-beta-5</url>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0.2</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-settings</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.doxia</groupId>
        <artifactId>doxia-site-renderer</artifactId>
        <version>1.0-alpha-8</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.reporting</groupId>
        <artifactId>maven-reporting-api</artifactId>
        <version>2.0.2</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.1</version>
      </dependency>
      <dependency>
        <groupId>org.mortbay.jetty</groupId>
        <artifactId>jetty</artifactId>
        <version>6.0.0beta12</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.pom.sha1
  
  Index: maven-site-plugin-2.0-beta-5.pom.sha1
  ===================================================================
  f75ae5991918151cbdeed05599c1d685720b0bcf
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin
	...
Message-ID: <E1GtS46-0005lY-KB@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:14

  Added:       maven2/org/apache/maven/plugins/maven-site-plugin  
                        maven-metadata-central.xml
                        maven-metadata-central.xml.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-site-plugin</artifactId>
    <versioning>
      <latest>2.0-beta-5</latest>
      <release>2.0-beta-5</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0-beta-2</version>
        <version>2.0-beta-3</version>
        <version>2.0-beta-4</version>
        <version>2.0-beta-5</version>
      </versions>
      <lastUpdated>20060514043812</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:02:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-site-plugin/maven-metadata-central.xml.sha1
  
  Index: maven-metadata-central.xml.sha1
  ===================================================================
  f2c5bb62201b8f748f0a2afa7ed7c6791ef3e7e7
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:18 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:18 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1
	...
Message-ID: <E1GtS4A-0005lu-Re@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:18

  Added:       maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1    
                        maven-source-plugin-2.0.1.jar
                        maven-source-plugin-2.0.1.jar.sha1
                        maven-source-plugin-2.0.1.pom
                        maven-source-plugin-2.0.1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.jar.sha1
  
  Index: maven-source-plugin-2.0.1.jar.sha1
  ===================================================================
  0ec11dafdd70072b3e06260652c9570900be0c9e
  
  
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.pom
  
  Index: maven-source-plugin-2.0.1.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>maven-plugins</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-source-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Source Plug-In</name>
    <version>2.0.1</version>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-archiver</artifactId>
        <version>1.0-alpha-3</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-9</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.shared</groupId>
        <artifactId>maven-plugin-testing-harness</artifactId>
        <version>1.0-beta-1</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.pom.sha1
  
  Index: maven-source-plugin-2.0.1.pom.sha1
  ===================================================================
  9cce3ecd335243cd433c2ae7e5dcbc62d4fffb57
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:18 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:18 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin
	...
Message-ID: <E1GtS4A-0005m7-Vb@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:18

  Added:       maven2/org/apache/maven/plugins/maven-source-plugin   
                        maven-metadata-central.xml
                        maven-metadata-central.xml.sha1
                        maven-metadata-jbosspluginrepo.xml
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-source-plugin</artifactId>
    <versioning>
      <latest>2.0.1</latest>
      <release>2.0.1</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0-rc1</version>
        <version>2.0</version>
        <version>2.0.1</version>
      </versions>
      <lastUpdated>20060507031448</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata-central.xml.sha1
  
  Index: maven-metadata-central.xml.sha1
  ===================================================================
  d5bc0479b8eec8aca6ce4c9a648dcd19a52b8805
  
  
  1.1      date: 2006/12/10 17:02:18;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata-jbosspluginrepo.xml
  
  Index: maven-metadata-jbosspluginrepo.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-source-plugin</artifactId>
    <version>LATEST</version>
  </metadata>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:23 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:23 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2
	...
Message-ID: <E1GtS4F-0005mT-1Q@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:23

  Added:       maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2    
                        maven-surefire-plugin-2.2.jar
                        maven-surefire-plugin-2.2.jar.sha1
                        maven-surefire-plugin-2.2.pom
                        maven-surefire-plugin-2.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.jar.sha1
  
  Index: maven-surefire-plugin-2.2.jar.sha1
  ===================================================================
  08a0946195cf488a4f20776f601a59ec19e18361
  
  
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.pom
  
  Index: maven-surefire-plugin-2.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>maven-plugins</artifactId>
      <groupId>org.apache.maven.plugins</groupId>
      <version>1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-surefire-plugin</artifactId>
    <packaging>maven-plugin</packaging>
    <name>Maven Surefire Plugin</name>
    <version>2.2</version>
    <contributors>
      <contributor>
        <name>Joakim Erdfelt</name>
        <email>joakim at erdfelt.com</email>
      </contributor>
    </contributors>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-surefire-plugin-2.2</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-surefire-plugin-2.2</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/plugins/tags/maven-surefire-plugin-2.2</url>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-plugin-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.surefire</groupId>
        <artifactId>surefire-booter</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.1</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.pom.sha1
  
  Index: maven-surefire-plugin-2.2.pom.sha1
  ===================================================================
  0cfe800ef40a439da0d73584540d906d88b2ed4c
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:23 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:23 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin
	...
Message-ID: <E1GtS4F-0005mg-4o@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:23

  Added:       maven2/org/apache/maven/plugins/maven-surefire-plugin   
                        maven-metadata-central.xml
                        maven-metadata-central.xml.sha1
                        maven-metadata-jbosspluginrepo.xml
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata-central.xml
  
  Index: maven-metadata-central.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-surefire-plugin</artifactId>
    <version>2.1.3</version>
    <versioning>
      <latest>2.2</latest>
      <release>2.2</release>
      <versions>
        <version>2.0-beta-1</version>
        <version>2.0</version>
        <version>2.1</version>
        <version>2.1.1</version>
        <version>2.1.2</version>
        <version>2.1.3</version>
        <version>2.2</version>
      </versions>
      <lastUpdated>20060514041238</lastUpdated>
    </versioning>
  </metadata>
  
  
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata-central.xml.sha1
  
  Index: maven-metadata-central.xml.sha1
  ===================================================================
  9a12073e8470a8c815dc645c4e76087d25fcfc01
  
  
  1.1      date: 2006/12/10 17:02:23;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata-jbosspluginrepo.xml
  
  Index: maven-metadata-jbosspluginrepo.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><metadata>
    <groupId>org.apache.maven.plugins</groupId>
    <artifactId>maven-surefire-plugin</artifactId>
    <version>LATEST</version>
  </metadata>
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2
	...
Message-ID: <E1GtS4I-0005mx-MC@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:26

  Added:       maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2  
                        maven-reporting-api-2.0.2.pom
                        maven-reporting-api-2.0.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2/maven-reporting-api-2.0.2.pom
  
  Index: maven-reporting-api-2.0.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>maven-reporting</artifactId>
      <groupId>org.apache.maven.reporting</groupId>
      <version>2.0.2</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-reporting-api</artifactId>
    <name>Maven Reporting API</name>
    <version>2.0.2</version>
    <developers>
      <developer>
        <id>vsiveton</id>
        <name>Vincent Siveton</name>
        <email>vincent.siveton at gmail.com</email>
        <roles>
          <role>Java Developer</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
    </developers>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven.doxia</groupId>
        <artifactId>doxia-sink-api</artifactId>
        <version>1.0-alpha-7</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2/maven-reporting-api-2.0.2.pom.sha1
  
  Index: maven-reporting-api-2.0.2.pom.sha1
  ===================================================================
  d82e392f17b1006f712163a75e1c9d8265d043e6
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0
	...
Message-ID: <E1GtS4I-0005n7-Qg@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:26

  Added:       maven2/org/apache/maven/reporting/maven-reporting-api/2.0  
                        maven-reporting-api-2.0.pom
                        maven-reporting-api-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0/maven-reporting-api-2.0.pom
  
  Index: maven-reporting-api-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven-reporting</artifactId>
      <groupId>org.apache.maven.reporting</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-reporting-api</artifactId>
    <version>2.0</version>
    <developers>
      <developer>
        <id>vsiveton</id>
        <name>Vincent Siveton</name>
        <email>vincent.siveton at gmail.com</email>
        <roles>
          <role>Java Developer</role>
        </roles>
        <timezone>-5</timezone>
      </developer>
    </developers>
    <dependencies>
      <dependency>
        <groupId>doxia</groupId>
        <artifactId>doxia-sink-api</artifactId>
        <version>1.0-alpha-4</version>
        <exclusions>
          <exclusion>
            <artifactId>plexus-container-default</artifactId>
            <groupId>plexus</groupId>
          </exclusion>
          <exclusion>
            <artifactId>plexus-utils</artifactId>
            <groupId>plexus</groupId>
          </exclusion>
        </exclusions>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting-api/2.0/maven-reporting-api-2.0.pom.sha1
  
  Index: maven-reporting-api-2.0.pom.sha1
  ===================================================================
  6c503051f089ab7bb3c93b0ff8b528d32e1869f8  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/reporting/maven-reporting-api/2.0/maven-reporting-api-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:29 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:29 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0.2
	...
Message-ID: <E1GtS4L-0005nO-Oz@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:29

  Added:       maven2/org/apache/maven/reporting/maven-reporting/2.0.2  
                        maven-reporting-2.0.2.pom
                        maven-reporting-2.0.2.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0.2/maven-reporting-2.0.2.pom
  
  Index: maven-reporting-2.0.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0.2</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.reporting</groupId>
    <artifactId>maven-reporting</artifactId>
    <packaging>pom</packaging>
    <name>Maven Reporting</name>
    <version>2.0.2</version>
    <inceptionYear>2005</inceptionYear>
    <modules>
      <module>maven-reporting-api</module>
      <module>maven-reporting-impl</module>
    </modules>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0.2/maven-reporting-2.0.2.pom.sha1
  
  Index: maven-reporting-2.0.2.pom.sha1
  ===================================================================
  2ec4c50d6575abad0c499cf257b8606037b09674
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:29 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:29 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0
	...
Message-ID: <E1GtS4L-0005nY-S9@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:29

  Added:       maven2/org/apache/maven/reporting/maven-reporting/2.0  
                        maven-reporting-2.0.pom
                        maven-reporting-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0/maven-reporting-2.0.pom
  
  Index: maven-reporting-2.0.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>maven</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.reporting</groupId>
    <artifactId>maven-reporting</artifactId>
    <packaging>pom</packaging>
    <name>Maven Reporting</name>
    <version>2.0</version>
    <inceptionYear>2005</inceptionYear>
    <modules>
      <module>maven-reporting-api</module>
      <module>maven-reporting-impl</module>
    </modules>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:29;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/reporting/maven-reporting/2.0/maven-reporting-2.0.pom.sha1
  
  Index: maven-reporting-2.0.pom.sha1
  ===================================================================
  629c69205b4c6c516f8a853fe8e1ab2e697df8ba  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/reporting/maven-reporting/2.0/maven-reporting-2.0.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:34 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:34 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1
	...
Message-ID: <E1GtS4Q-0005nt-9e@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:34

  Added:       maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1    
                        maven-plugin-testing-harness-1.0-beta-1.jar
                        maven-plugin-testing-harness-1.0-beta-1.jar.sha1
                        maven-plugin-testing-harness-1.0-beta-1.pom
                        maven-plugin-testing-harness-1.0-beta-1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:34;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:34;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.jar.sha1
  
  Index: maven-plugin-testing-harness-1.0-beta-1.jar.sha1
  ===================================================================
  53758be7cb5e82d8256d8d809f23eb0a53343f09
  
  
  1.1      date: 2006/12/10 17:02:34;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.pom
  
  Index: maven-plugin-testing-harness-1.0-beta-1.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>maven-shared-components</artifactId>
      <groupId>org.apache.maven.shared</groupId>
      <version>1</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>maven-plugin-testing-harness</artifactId>
    <name>Maven Plugin Testing Mechanism</name>
    <version>1.0-beta-1</version>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-project</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-core</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.1</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:34;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.pom.sha1
  
  Index: maven-plugin-testing-harness-1.0-beta-1.pom.sha1
  ===================================================================
  c9e952876dc9641a7afabcc6242b72abe0c7e07b
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/1
	...
Message-ID: <E1GtS4T-0005oC-Je@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:37

  Added:       maven2/org/apache/maven/shared/maven-shared-components/1  
                        maven-shared-components-1.pom
                        maven-shared-components-1.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/1/maven-shared-components-1.pom
  
  Index: maven-shared-components-1.pom
  ===================================================================
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
    xsi:noNamespaceSchemaLocation="http://maven.apache.org/maven-v4_0_0.xsd">
  
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-parent</artifactId>
      <version>1</version>
      <relativePath>../pom/maven/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven.shared</groupId>
    <artifactId>maven-shared-components</artifactId>
    <packaging>pom</packaging>
    <version>1</version>
    <name>Maven Shared Components</name>
    <description>Maven shared components</description>
    <url>http://maven.apache.org/shared/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MNG</url>
    </issueManagement>
    <distributionManagement>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/shared/</url>
      </site>
    </distributionManagement>
    <modules>
      <module>maven-shared-io</module>
      <module>maven-shared-monitor</module>
      <module>file-management</module>
    </modules>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/shared/trunk/</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/shared/trunk/</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/shared/trunk/</url>
    </scm>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/shared/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:02:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/1/maven-shared-components-1.pom.sha1
  
  Index: maven-shared-components-1.pom.sha1
  ===================================================================
  b3c6c63cae51520c89a16fed67c7d2aa75f75fc0
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/3
	...
Message-ID: <E1GtS4T-0005oN-NZ@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:37

  Added:       maven2/org/apache/maven/shared/maven-shared-components/3  
                        maven-shared-components-3.pom
                        maven-shared-components-3.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/3/maven-shared-components-3.pom
  
  Index: maven-shared-components-3.pom
  ===================================================================
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"
    xsi:noNamespaceSchemaLocation="http://maven.apache.org/maven-v4_0_0.xsd">
  
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-parent</artifactId>
      <version>4</version>
      <relativePath>../pom/maven/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven.shared</groupId>
    <artifactId>maven-shared-components</artifactId>
    <packaging>pom</packaging>
    <version>3</version>
    <name>Maven Shared Components</name>
    <description>Maven shared components</description>
    <url>http://maven.apache.org/shared/</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/MNG</url>
    </issueManagement>
    <distributionManagement>
      <site>
        <id>website</id>
        <url>scp://minotaur.apache.org/www/maven.apache.org/shared/</url>
      </site>
    </distributionManagement>
    <modules>
      <module>maven-archiver</module>
      <module>maven-model-converter</module>
      <module>maven-shared-io</module>
      <module>maven-shared-monitor</module>
      <module>file-management</module>
      <module>maven-plugin-testing-harness</module>
    </modules>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/shared/trunk/</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/shared/trunk/</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/shared/trunk/</url>
    </scm>
    <build>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/shared/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:02:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/shared/maven-shared-components/3/maven-shared-components-3.pom.sha1
  
  Index: maven-shared-components-3.pom.sha1
  ===================================================================
  074a59d89aa2107fe1eb241ff784b9722e516032
  
  


From msurtani at jboss.com  Sun Dec 10 12:02:38 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 10 Dec 2006 12:02:38 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GtS4U-0005oc-TX@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/10 12:02:38

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        OptimisticValidatorInterceptor.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.25.2.9  +2 -2      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.25.2.8
  retrieving revision 1.25.2.9
  diff -u -b -r1.25.2.8 -r1.25.2.9
  --- OptimisticValidatorInterceptor.java	8 Dec 2006 12:04:04 -0000	1.25.2.8
  +++ OptimisticValidatorInterceptor.java	10 Dec 2006 17:02:38 -0000	1.25.2.9
  @@ -136,14 +136,14 @@
                 throw new DataVersioningException("Tx attempted to create " + fqn + " anew.  It has already been created since this tx started by another (possibly remote) tx.");
              }
   
  -            if (!workspaceNode.isCreated() )
  +            if (!workspaceNode.isCreated() && (workspaceNode.isDeleted() || workspaceNode.isDirty()))
               {
                  // test that the 2 DataVersion types match up
                  if (!realNode.getVersion().getClass().equals(workspaceNode.getVersion().getClass()) && checkNotInitialRootVersion(realNode))
                  {
                     throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node [fqn = "+realNode.getFqn()+"] that already contains version of type " + realNode.getVersion().getClass());                  
                  }
  -               if ((workspaceNode.isDeleted() || workspaceNode.isDirty()) && realNode.getVersion().newerThan( workspaceNode.getVersion() ))
  +               if (realNode.getVersion().newerThan( workspaceNode.getVersion() ))
                  {
                      // we have an out of date node here
                     throw new DataVersioningException("DataNode [" + fqn + "] version " + ((OptimisticTreeNode)workspaceNode.getNode()).getVersion() + " is newer than workspace node " + workspaceNode.getVersion());
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:42 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:42 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0
	...
Message-ID: <E1GtS4Y-0005ow-DS@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:42

  Added:       maven2/org/apache/maven/surefire/surefire-api/2.0    
                        surefire-api-2.0.jar surefire-api-2.0.jar.sha1
                        surefire-api-2.0.pom surefire-api-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:42;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:42;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.jar.sha1
  
  Index: surefire-api-2.0.jar.sha1
  ===================================================================
  f3cc7f70a23e343d05fbfa07a42fd66e6be4f946
  
  
  1.1      date: 2006/12/10 17:02:42;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.pom
  
  Index: surefire-api-2.0.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>surefire</artifactId>
      <groupId>org.apache.maven.surefire</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>surefire-api</artifactId>
    <name>SureFire API</name>
    <version>2.0</version>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.1</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:42;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.pom.sha1
  
  Index: surefire-api-2.0.pom.sha1
  ===================================================================
  a4613b26306174201a951b93215c1ad8854d4229
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:46 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:46 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0
	...
Message-ID: <E1GtS4c-0005pH-Aj@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:46

  Added:       maven2/org/apache/maven/surefire/surefire-booter/2.0    
                        surefire-booter-2.0.jar
                        surefire-booter-2.0.jar.sha1
                        surefire-booter-2.0.pom
                        surefire-booter-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:46;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:46;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.jar.sha1
  
  Index: surefire-booter-2.0.jar.sha1
  ===================================================================
  3c2d1abc4540130ff4c7b39134e8afe4999a7131
  
  
  1.1      date: 2006/12/10 17:02:46;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.pom
  
  Index: surefire-booter-2.0.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>surefire</artifactId>
      <groupId>org.apache.maven.surefire</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>surefire-booter</artifactId>
    <name>SureFire Booter</name>
    <version>2.0</version>
    <dependencies>
      <dependency>
        <groupId>org.apache.maven.surefire</groupId>
        <artifactId>surefire-api</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:46;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.pom.sha1
  
  Index: surefire-booter-2.0.pom.sha1
  ===================================================================
  600e61f3c00a4473be3ef940997e79995180eeae
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:50 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0
	...
Message-ID: <E1GtS4g-0005pc-28@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:50

  Added:       maven2/org/apache/maven/surefire/surefire-junit/2.0    
                        surefire-junit-2.0.jar surefire-junit-2.0.jar.sha1
                        surefire-junit-2.0.pom surefire-junit-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:50;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:02:50;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.jar.sha1
  
  Index: surefire-junit-2.0.jar.sha1
  ===================================================================
  ebef14a35f4d01c3f72443fb390df103fcc74c34
  
  
  1.1      date: 2006/12/10 17:02:50;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.pom
  
  Index: surefire-junit-2.0.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>surefire-providers</artifactId>
      <groupId>org.apache.maven.surefire</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>surefire-junit</artifactId>
    <name>SureFire JUnit Runner</name>
    <version>2.0</version>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:50;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.pom.sha1
  
  Index: surefire-junit-2.0.pom.sha1
  ===================================================================
  79002674cb343de980dfe4c1ad4dddd53785cf98
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:53 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers/2.0
	...
Message-ID: <E1GtS4j-0005ps-It@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:53

  Added:       maven2/org/apache/maven/surefire/surefire-providers/2.0  
                        surefire-providers-2.0.pom
                        surefire-providers-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers/2.0/surefire-providers-2.0.pom
  
  Index: surefire-providers-2.0.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!--
    ~ Copyright 2001-2006 The Apache Software Foundation.
    ~
    ~ Licensed under the Apache License, Version 2.0 (the "License");
    ~ you may not use this file except in compliance with the License.
    ~ You may obtain a copy of the License at
    ~
    ~      http://www.apache.org/licenses/LICENSE-2.0
    ~
    ~ Unless required by applicable law or agreed to in writing, software
    ~ distributed under the License is distributed on an "AS IS" BASIS,
    ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    ~ See the License for the specific language governing permissions and
    ~ limitations under the License.
    -->
  
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <parent>
      <artifactId>surefire</artifactId>
      <groupId>org.apache.maven.surefire</groupId>
      <version>2.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>surefire-providers</artifactId>
    <packaging>pom</packaging>
    <name>SureFire Providers</name>
    <modules>
      <module>surefire-junit</module>
      <module>surefire-testng</module>
    </modules>
    <dependencies>
      <dependency>
        <groupId>${project.groupId}</groupId>
        <artifactId>surefire-api</artifactId>
        <version>2.0</version>
      </dependency>
    </dependencies>
  </project>
  
  
  
  
  1.1      date: 2006/12/10 17:02:53;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire-providers/2.0/surefire-providers-2.0.pom.sha1
  
  Index: surefire-providers-2.0.pom.sha1
  ===================================================================
  0e7abda11e7aa94e3ba5ad1f1a052ebeb3d0f1a6  -
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:56 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:56 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/surefire/surefire/2.0 ...
Message-ID: <E1GtS4m-0005q8-L9@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:56

  Added:       maven2/org/apache/maven/surefire/surefire/2.0  
                        surefire-2.0.pom surefire-2.0.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:56;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire/2.0/surefire-2.0.pom
  
  Index: surefire-2.0.pom
  ===================================================================
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <artifactId>maven-parent</artifactId>
      <groupId>org.apache.maven</groupId>
      <version>1</version>
      <relativePath>../pom/maven/pom.xml</relativePath>
    </parent>
    <groupId>org.apache.maven.surefire</groupId>
    <artifactId>surefire</artifactId>
    <packaging>pom</packaging>
    <name>SureFire</name>
    <version>2.0</version>
    <description>Surefire is a test framework project.</description>
    <url>http://maven.apache.org/surefire</url>
    <issueManagement>
      <system>jira</system>
      <url>http://jira.codehaus.org/browse/SUREFIRE</url>
    </issueManagement>
    <inceptionYear>2004</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Surefire User List</name>
        <subscribe>surefire-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>surefire-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-surefire-users/</archive>
      </mailingList>
      <mailingList>
        <name>Surefire Developer List</name>
        <subscribe>surefire-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>surfire-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-surefire-dev/</archive>
      </mailingList>
      <mailingList>
        <name>Surefire Commits List</name>
        <subscribe>surefire-commits-subscribe at maven.apache.org</subscribe>
        <unsubscribe>surefire-commits-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://mail-archives.apache.org/mod_mbox/maven-surefire-commits/</archive>
      </mailingList>
    </mailingLists>
    <contributors>
      <contributor>
        <name>Jesse Kuhnert</name>
      </contributor>
      <contributor>
        <name>Vincent Siveton</name>
        <email>vincent.siveton at gmail.com</email>
        <organization>ASF</organization>
        <roles>
          <role>Java Developer</role>
        </roles>
      </contributor>
    </contributors>
    <scm>
      <connection>scm:svn:https://svn.apache.org/repos/asf/maven/surefire/tags/surefire-2.0</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/surefire/tags/surefire-2.0</developerConnection>
      <url>https://svn.apache.org/repos/asf/maven/surefire/tags/surefire-2.0</url>
    </scm>
    <build>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <configuration>
            <source>1.3</source>
            <target>1.3</target>
          </configuration>
        </plugin>
      </plugins>
      <pluginManagement>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <tagBase>https://svn.apache.org/repos/asf/maven/surefire/tags</tagBase>
            </configuration>
          </plugin>
        </plugins>
      </pluginManagement>
    </build>
    <modules>
      <module>surefire-api</module>
      <module>surefire-booter</module>
      <module>surefire-providers</module>
    </modules>
  
    <profiles>
      <!-- use preinstalled JDK 1.3 to build and test -->
      <profile>
        <id>jdk1.3</id>
        <build>
          <plugins>
            <plugin>
              <artifactId>maven-compiler-plugin</artifactId>
              <configuration>
                <fork>true</fork>
                <compilerVersion>1.3</compilerVersion>
                <executable>${JAVA_1_3_HOME}/bin/javac</executable>
              </configuration>
            </plugin>
            <plugin>
              <artifactId>maven-surefire-plugin</artifactId>
              <configuration>
                <forkMode>once</forkMode>
                <jvm>${JAVA_1_3_HOME}/bin/java</jvm>
              </configuration>
            </plugin>
          </plugins>
        </build>
      </profile>
    </profiles>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:56;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/surefire/surefire/2.0/surefire-2.0.pom.sha1
  
  Index: surefire-2.0.pom.sha1
  ===================================================================
  aaaec28e535c69625b176821b427a35343308b13
  
  


From scott.stark at jboss.com  Sun Dec 10 12:02:59 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:02:59 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5
	...
Message-ID: <E1GtS4p-0005qO-KK@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:02:59

  Added:       maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5  
                        wagon-file-1.0-alpha-5.pom
                        wagon-file-1.0-alpha-5.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:02:59;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5/wagon-file-1.0-alpha-5.pom
  
  Index: wagon-file-1.0-alpha-5.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.wagon</groupId>
    <artifactId>wagon-file</artifactId>
    <name>Maven Wagon File Provider</name>
    <version>1.0-alpha-5</version>
    <description>Tools to manage artifacts and deployment</description>
    <ciManagement>
      <system>wagon-dev at maven.apache.org</system>
      <notifiers>
        <notifier>
          <address>wagon-dev at maven.apache.org</address>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2003</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven Wagon User List</name>
        <subscribe>wagon-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-users at maven.apache.org</archive>
      </mailingList>
      <mailingList>
        <name>Maven Wagon Developer List</name>
        <subscribe>wagon-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-dev at maven.apache.org</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>michal at codehaus.com</email>
        <organization>Codehaus</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-providers/wagon-file</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-providers/wagon-file</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/wagon/wagon-providers/wagon-file</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
    </build>
    <repositories>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://repo1.maven.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://repo1.maven.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-api</artifactId>
        <version>1.0-alpha-5</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-test</artifactId>
        <version>1.0-alpha-5</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:02:59;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5/wagon-file-1.0-alpha-5.pom.sha1
  
  Index: wagon-file-1.0-alpha-5.pom.sha1
  ===================================================================
  9f516a352f07d760f240c87bd63f403ed07df26c  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5/wagon-file-1.0-alpha-5.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:03:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:03:02 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5
	...
Message-ID: <E1GtS4s-0005qe-Jo@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:03:02

  Added:       maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5  
                        wagon-http-lightweight-1.0-alpha-5.pom
                        wagon-http-lightweight-1.0-alpha-5.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:03:02;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5/wagon-http-lightweight-1.0-alpha-5.pom
  
  Index: wagon-http-lightweight-1.0-alpha-5.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.wagon</groupId>
    <artifactId>wagon-http-lightweight</artifactId>
    <name>Maven Wagon Lightweight HTTP Provider</name>
    <version>1.0-alpha-5</version>
    <description>Tools to manage artifacts and deployment</description>
    <ciManagement>
      <system>wagon-dev at maven.apache.org</system>
      <notifiers>
        <notifier>
          <address>wagon-dev at maven.apache.org</address>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2003</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven Wagon User List</name>
        <subscribe>wagon-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-users at maven.apache.org</archive>
      </mailingList>
      <mailingList>
        <name>Maven Wagon Developer List</name>
        <subscribe>wagon-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-dev at maven.apache.org</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>michal at codehaus.com</email>
        <organization>Codehaus</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-providers/wagon-http-lightweight</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-providers/wagon-http-lightweight</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/wagon/wagon-providers/wagon-http-lightweight</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
    </build>
    <repositories>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://repo1.maven.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://repo1.maven.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-api</artifactId>
        <version>1.0-alpha-5</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>servletapi</groupId>
        <artifactId>servletapi</artifactId>
        <version>2.3</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>jetty</groupId>
        <artifactId>jetty</artifactId>
        <version>4.2.10</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>plexus</groupId>
        <artifactId>plexus-jetty-httpd</artifactId>
        <version>1.0-beta-1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-test</artifactId>
        <version>1.0-alpha-5</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:03:02;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5/wagon-http-lightweight-1.0-alpha-5.pom.sha1
  
  Index: wagon-http-lightweight-1.0-alpha-5.pom.sha1
  ===================================================================
  8b9a84710244f8164e6c80e07008367bd5282df5  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5/wagon-http-lightweight-1.0-alpha-5.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:03:05 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:03:05 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5
	...
Message-ID: <E1GtS4v-0005qu-Jp@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:03:05

  Added:       maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5  
                        wagon-provider-api-1.0-alpha-5.pom
                        wagon-provider-api-1.0-alpha-5.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:03:05;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5/wagon-provider-api-1.0-alpha-5.pom
  
  Index: wagon-provider-api-1.0-alpha-5.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.wagon</groupId>
    <artifactId>wagon-provider-api</artifactId>
    <name>Maven Wagon API</name>
    <version>1.0-alpha-5</version>
    <description>Tools to manage artifacts and deployment</description>
    <ciManagement>
      <system>wagon-dev at maven.apache.org</system>
      <notifiers>
        <notifier>
          <address>wagon-dev at maven.apache.org</address>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2003</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven Wagon User List</name>
        <subscribe>wagon-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-users at maven.apache.org</archive>
      </mailingList>
      <mailingList>
        <name>Maven Wagon Developer List</name>
        <subscribe>wagon-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-dev at maven.apache.org</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>michal at codehaus.com</email>
        <organization>Codehaus</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-provider-api</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-provider-api</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/wagon/wagon-provider-api</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
    </build>
    <repositories>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://repo1.maven.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://repo1.maven.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:03:05;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5/wagon-provider-api-1.0-alpha-5.pom.sha1
  
  Index: wagon-provider-api-1.0-alpha-5.pom.sha1
  ===================================================================
  4d2d9d58a93e3a54e60b695728118bc5028f7793  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5/wagon-provider-api-1.0-alpha-5.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:03:08 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:03:08 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5
	...
Message-ID: <E1GtS4y-0005rA-KR@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:03:08

  Added:       maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5  
                        wagon-ssh-1.0-alpha-5.pom
                        wagon-ssh-1.0-alpha-5.pom.sha1
  Log:
  Add the maven plugins
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:03:08;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5/wagon-ssh-1.0-alpha-5.pom
  
  Index: wagon-ssh-1.0-alpha-5.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.apache.maven.wagon</groupId>
    <artifactId>wagon-ssh</artifactId>
    <name>Maven Wagon SSH Provider</name>
    <version>1.0-alpha-5</version>
    <description>Tools to manage artifacts and deployment</description>
    <ciManagement>
      <system>wagon-dev at maven.apache.org</system>
      <notifiers>
        <notifier>
          <address>wagon-dev at maven.apache.org</address>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2003</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Maven Wagon User List</name>
        <subscribe>wagon-users-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-users-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-users at maven.apache.org</archive>
      </mailingList>
      <mailingList>
        <name>Maven Wagon Developer List</name>
        <subscribe>wagon-dev-subscribe at maven.apache.org</subscribe>
        <unsubscribe>wagon-dev-unsubscribe at maven.apache.org</unsubscribe>
        <archive>http://nagoya.apache.org/eyebrowse/SummarizeList?listName=wagon-dev at maven.apache.org</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>michal at codehaus.com</email>
        <organization>Codehaus</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>brett</id>
        <name>Brett Porter</name>
        <email>brett at apache.org</email>
        <roles>
          <role>Developer</role>
        </roles>
        <timezone>+10</timezone>
      </developer>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <scm>
      <connection>scm:svn:http://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-providers/wagon-ssh</connection>
      <developerConnection>scm:svn:https://svn.apache.org/repos/asf/maven/wagon/trunk/wagon-providers/wagon-ssh</developerConnection>
      <url>http://svn.apache.org/viewcvs.cgi/maven/wagon/wagon-providers/wagon-ssh</url>
    </scm>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
      <plugins>
        <plugin>
          <artifactId>maven-surefire-plugin</artifactId>
          <configuration>
            <excludes>
              <exclude>**/ScpWagon*Test.*</exclude>
              <exclude>**/SftpWagonTest.*</exclude>
              <exclude>**/SshCommandExecutorTest.*</exclude>
              <exclude>**/knownhost/**</exclude>
            </excludes>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://repo1.maven.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://repo1.maven.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>com.jcraft</groupId>
        <artifactId>jsch</artifactId>
        <version>0.1.23</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-api</artifactId>
        <version>1.0-alpha-5</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.2</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-interactivity-api</artifactId>
        <version>1.0-alpha-4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-test</artifactId>
        <version>1.0-alpha-5</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <url>scp://beaver.codehaus.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:03:08;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5/wagon-ssh-1.0-alpha-5.pom.sha1
  
  Index: wagon-ssh-1.0-alpha-5.pom.sha1
  ===================================================================
  7512d3992e339b9e0f224a44b82574ba97815ca2  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5/wagon-ssh-1.0-alpha-5.pom
  
  
  


From msurtani at jboss.com  Sun Dec 10 12:15:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sun, 10 Dec 2006 12:15:46 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GtSHC-00065z-Ra@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/10 12:15:46

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  fixed order of remove for non tx call, to ensure proper notifications
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.5  +4 -2      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.4
  retrieving revision 1.20.2.5
  diff -u -b -r1.20.2.4 -r1.20.2.5
  --- PessimisticLockInterceptor.java	6 Dec 2006 11:44:22 -0000	1.20.2.4
  +++ PessimisticLockInterceptor.java	10 Dec 2006 17:15:46 -0000	1.20.2.5
  @@ -36,7 +36,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.4 2006/12/06 11:44:22 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.5 2006/12/10 17:15:46 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -185,6 +185,8 @@
         if (m.getMethodId() == MethodDeclarations.lockMethodLocal_id)
            return null;
   
  +      Object o = super.invoke(m);
  +
         // FIXME this should be done in UnlockInterceptor, but I didn't want
         // to add the removedNodes map to TreeCache
         if (storeLockedNode && ctx.getGlobalTransaction() == null)
  @@ -195,7 +197,7 @@
            cache.realRemove(fqn, true);
         }
   
  -      return super.invoke(m);
  +      return o;
      }
   
   
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:19:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:19:26 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/apache/3 - New
	directory ...
Message-ID: <E1GtSKk-00069D-7t@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:19:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/apache/apache/3 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:19:45 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:19:45 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/apache/apache/3   ...
Message-ID: <E1GtSL3-00069Y-HK@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:19:45

  Added:       maven2/org/apache/apache/3   apache-3.pom apache-3.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:19:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/apache/3/apache-3.pom
  
  Index: apache-3.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  
  <!--
    ~ Copyright 2005-2006 The Apache Software Foundation.
    ~
    ~ Licensed under the Apache License, Version 2.0 (the "License");
    ~ you may not use this file except in compliance with the License.
    ~ You may obtain a copy of the License at
    ~
    ~      http://www.apache.org/licenses/LICENSE-2.0
    ~
    ~ Unless required by applicable law or agreed to in writing, software
    ~ distributed under the License is distributed on an "AS IS" BASIS,
    ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    ~ See the License for the specific language governing permissions and
    ~ limitations under the License.
    -->
  
  <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
  
    <!-- Shared parent. Doesn't define a lot of things about Apache like general mailing lists, but does
         define the settings common to all projects at Apache -->
    <groupId>org.apache</groupId>
    <artifactId>apache</artifactId>
    <version>3</version>
    <packaging>pom</packaging>
    <name>The Apache Software Foundation</name>
    <description>
      The Apache Software Foundation provides support for the Apache community of open-source software projects.
      The Apache projects are characterized by a collaborative, consensus based development process, an open and
      pragmatic software license, and a desire to create high quality software that leads the way in its field.
      We consider ourselves not simply a group of projects sharing a server, but rather a community of developers
      and users.
    </description>
    <licenses>
      <license>
        <name>The Apache Software License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
        <distribution>repo</distribution>
      </license>
    </licenses>
    <organization>
      <name>Apache Software Foundation</name>
      <url>http://www.apache.org/</url>
    </organization>
    <url>http://www.apache.org/</url>
    <repositories>
      <repository>
        <id>apache.snapshots</id>
        <name>Apache Snapshot Repository</name>
        <url>http://people.apache.org/repo/m2-snapshot-repository</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </repository>
    </repositories>
    <distributionManagement>
      <!-- Site omitted - each project must provide their own -->
      <repository>
        <id>apache.releases</id>
        <name>Apache Release Distribution Repository</name>
        <url>scp://people.apache.org/www/people.apache.org/repo/m2-ibiblio-rsync-repository</url>
      </repository>
      <snapshotRepository>
        <id>apache.snapshots</id>
        <name>Apache Development Snapshot Repository</name>
        <url>scp://people.apache.org/www/people.apache.org/repo/m2-snapshot-repository</url>
      </snapshotRepository>
    </distributionManagement>
    <mailingLists>
      <mailingList>
        <name>Apache Announce List</name>
        <subscribe>announce-subscribe at apache.org</subscribe>
        <unsubscribe>announce-unsubscribe at apache.org</unsubscribe>
        <post>announce at apache.org</post>
        <archive>http://mail-archives.apache.org/mod_mbox/www-announce/</archive>
      </mailingList>
    </mailingLists>
  </project>
  
  
  
  
  1.1      date: 2006/12/10 17:19:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/apache/apache/3/apache-3.pom.sha1
  
  Index: apache-3.pom.sha1
  ===================================================================
  1bc0010136a890e2fd38d901a0b7ecdf0e3f9871 *./apache-3.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:37:40 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:37:40 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1
	- New directory ...
Message-ID: <E1GtScO-0006Uc-Gg@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:37:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:00 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:00 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1
	...
Message-ID: <E1GtSci-0006V7-Cd@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:00

  Added:       maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1    
                        plexus-compiler-api-1.5.1.jar
                        plexus-compiler-api-1.5.1.jar.sha1
                        plexus-compiler-api-1.5.1.pom
                        plexus-compiler-api-1.5.1.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:38:00;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:38:00;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.jar.sha1
  
  Index: plexus-compiler-api-1.5.1.jar.sha1
  ===================================================================
  98b2add411a076ad442aa809dbcd302d0b8d4898
  
  
  1.1      date: 2006/12/10 17:38:00;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.pom
  
  Index: plexus-compiler-api-1.5.1.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.codehaus.plexus</groupId>
    <artifactId>plexus-compiler-api</artifactId>
    <name>Plexus Compiler Api</name>
    <version>1.5.1</version>
    <ciManagement>
      <notifiers>
        <notifier>
          <configuration>
            <address>dev at plexus.codehaus.org</address>
          </configuration>
        </notifier>
        <notifier>
          <type>irc</type>
          <configuration>
            <port>6667</port>
            <channel>#plexus</channel>
            <host>irc.codehaus.org</host>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2001</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Plexus Developer List</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/plexus-dev/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at zenplex.com</email>
        <organization>Zenplex</organization>
        <roles>
          <role>Developer</role>
          <role>Release Manager</role>
        </roles>
      </developer>
      <developer>
        <id>kaz</id>
        <name>Pete Kazmier</name>
        <email></email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>jtaylor</id>
        <name>James Taylor</name>
        <email>james at jamestaylor.org</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>dandiep</id>
        <name>Dan Diephouse</name>
        <email>dan at envoisolutions.com</email>
        <organization>Envoi solutions</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kasper</id>
        <name>Kasper Nielsen</name>
        <email>apache at kav.dk</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>bwalding</id>
        <name>Ben Walding</name>
        <email>bwalding at codehaus.org</email>
        <organization>Walding Consulting Services</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>mhw</id>
        <name>Mark Wilkinson</name>
        <email>mhw at kremvax.net</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>mmaczka at interia.pl</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <scm>
      <connection>scm:svn:svn://svn.codehaus.org/plexus/scm/trunk/plexus-components/plexus-compiler/plexus-compiler-api</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/trunk/plexus-components/plexus-compiler/plexus-compiler-api</developerConnection>
    </scm>
    <organization>
      <name>Codehaus</name>
      <url>http://www.codehaus.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
      <plugins>
        <plugin>
          <artifactId>maven-release-plugin</artifactId>
          <configuration>
            <tagBase>https://svn.codehaus.org/plexus/tags</tagBase>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Snapshot Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </repository>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://www.ibiblio.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots-plugins</id>
        <name>Maven Snapshot Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://www.ibiblio.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:38:00;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.pom.sha1
  
  Index: plexus-compiler-api-1.5.1.pom.sha1
  ===================================================================
  e0aa1496584b1fe5227d4ee875966caeec65d894  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:38:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n -
	New directory ...
Message-ID: <E1GtSd8-0006VG-JW@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api
	- New directory ...
Message-ID: <E1GtSd8-0006VK-Ng@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity
	- New directory ...
Message-ID: <E1GtSd8-0006VO-Rl@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:26

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:30 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:30 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus/1.0.8 -
	New directory ...
Message-ID: <E1GtSdC-0006VX-4V@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:30

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus/1.0.8 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:36 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:36 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7
	- New directory ...
Message-ID: <E1GtSdI-0006Vl-RW@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:36

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:47 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:47 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1
	- New directory ...
Message-ID: <E1GtSdT-0006W4-Rl@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:47

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:38:58 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:38:58 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1
	- New directory ...
Message-ID: <E1GtSde-0006WN-SU@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:38:58

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:39:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:39:09 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-components/1.1.6
	- New directory ...
Message-ID: <E1GtSdp-0006Wg-S8@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:39:09

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-components/1.1.6 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:39:16 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:39:16 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6
	- New directory ...
Message-ID: <E1GtSdw-0006Wu-Qs@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:39:16

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:39:28 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:39:28 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4
	- New directory ...
Message-ID: <E1GtSe8-0006XD-0o@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:39:28

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:39:34 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:39:34 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.2
	- New directory ...
Message-ID: <E1GtSeE-0006XR-UV@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:39:34

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.2 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:39:49 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:39:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3
	- New directory ...
Message-ID: <E1GtSeT-0006Xp-WB@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:39:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:40:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7
	...
Message-ID: <E1GtSf4-0006Zl-EW@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:26

  Added:       maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7    
                        plexus-archiver-1.0-alpha-7.jar
                        plexus-archiver-1.0-alpha-7.jar.sha1
                        plexus-archiver-1.0-alpha-7.pom
                        plexus-archiver-1.0-alpha-7.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar.sha1
  
  Index: plexus-archiver-1.0-alpha-7.jar.sha1
  ===================================================================
  c6c57e85cae417534e77a15dd3f6406ccb3b586c
  
  
  1.1      date: 2006/12/10 17:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.pom
  
  Index: plexus-archiver-1.0-alpha-7.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>plexus-components</artifactId>
      <groupId>org.codehaus.plexus</groupId>
      <version>1.1.6</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>plexus-archiver</artifactId>
    <name>Plexus Archiver Component</name>
    <version>1.0-alpha-7</version>
    <contributors>
      <contributor>
        <name>Dan Tran</name>
      </contributor>
      <contributor>
        <name>Richard van der Hoff</name>
      </contributor>
    </contributors>
    <scm>
      <connection>scm:svn:https://svn.codehaus.org/plexus/tags/plexus-archiver-1.0-alpha-7</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/tags/plexus-archiver-1.0-alpha-7</developerConnection>
    </scm>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.2</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.pom.sha1
  
  Index: plexus-archiver-1.0-alpha-7.pom.sha1
  ===================================================================
  97b8b183d53cae882067c76b9448c92460040bf0
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:30 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:30 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1
	...
Message-ID: <E1GtSf8-0006aA-42@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:30

  Added:       maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1    
                        plexus-compiler-javac-1.5.1.jar
                        plexus-compiler-javac-1.5.1.jar.sha1
                        plexus-compiler-javac-1.5.1.pom
                        plexus-compiler-javac-1.5.1.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:30;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:40:30;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.jar.sha1
  
  Index: plexus-compiler-javac-1.5.1.jar.sha1
  ===================================================================
  38fe17b7349f849e00af730f0126c63b552cb20f
  
  
  1.1      date: 2006/12/10 17:40:30;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.pom
  
  Index: plexus-compiler-javac-1.5.1.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.codehaus.plexus</groupId>
    <artifactId>plexus-compiler-javac</artifactId>
    <name>Plexus Javac Component</name>
    <version>1.5.1</version>
    <ciManagement>
      <notifiers>
        <notifier>
          <configuration>
            <address>dev at plexus.codehaus.org</address>
          </configuration>
        </notifier>
        <notifier>
          <type>irc</type>
          <configuration>
            <port>6667</port>
            <channel>#plexus</channel>
            <host>irc.codehaus.org</host>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2001</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Plexus Developer List</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/plexus-dev/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at zenplex.com</email>
        <organization>Zenplex</organization>
        <roles>
          <role>Developer</role>
          <role>Release Manager</role>
        </roles>
      </developer>
      <developer>
        <id>kaz</id>
        <name>Pete Kazmier</name>
        <email></email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>jtaylor</id>
        <name>James Taylor</name>
        <email>james at jamestaylor.org</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>dandiep</id>
        <name>Dan Diephouse</name>
        <email>dan at envoisolutions.com</email>
        <organization>Envoi solutions</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kasper</id>
        <name>Kasper Nielsen</name>
        <email>apache at kav.dk</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>bwalding</id>
        <name>Ben Walding</name>
        <email>bwalding at codehaus.org</email>
        <organization>Walding Consulting Services</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>mhw</id>
        <name>Mark Wilkinson</name>
        <email>mhw at kremvax.net</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>mmaczka at interia.pl</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <scm>
      <connection>scm:svn:svn://svn.codehaus.org/plexus/scm/trunk/plexus-components/plexus-compiler/plexus-compilers/plexus-compiler-javac</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/trunk/plexus-components/plexus-compiler/plexus-compilers/plexus-compiler-javac</developerConnection>
    </scm>
    <organization>
      <name>Codehaus</name>
      <url>http://www.codehaus.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
      <plugins>
        <plugin>
          <artifactId>maven-release-plugin</artifactId>
          <configuration>
            <tagBase>https://svn.codehaus.org/plexus/tags</tagBase>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Snapshot Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </repository>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://www.ibiblio.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots-plugins</id>
        <name>Maven Snapshot Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://www.ibiblio.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-model</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-compiler-api</artifactId>
        <version>1.5.1</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-repository-metadata</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-compiler-test</artifactId>
        <version>1.5.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-settings</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-manager</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven.wagon</groupId>
        <artifactId>wagon-provider-api</artifactId>
        <version>1.0-alpha-5</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact-test</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.maven</groupId>
        <artifactId>maven-artifact</artifactId>
        <version>2.0</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:30;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.pom.sha1
  
  Index: plexus-compiler-javac-1.5.1.pom.sha1
  ===================================================================
  82b6beefea9c8e26ccac1534af38e5a33bd4d5d8  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:33 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:33 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1
	...
Message-ID: <E1GtSfB-0006aZ-TH@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:33

  Added:       maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1    
                        plexus-compiler-manager-1.5.1.jar
                        plexus-compiler-manager-1.5.1.jar.sha1
                        plexus-compiler-manager-1.5.1.pom
                        plexus-compiler-manager-1.5.1.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:40:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.jar.sha1
  
  Index: plexus-compiler-manager-1.5.1.jar.sha1
  ===================================================================
  12fff4c8a02f2f9bf7899682227cd98aa7cd6266
  
  
  1.1      date: 2006/12/10 17:40:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.pom
  
  Index: plexus-compiler-manager-1.5.1.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.codehaus.plexus</groupId>
    <artifactId>plexus-compiler-manager</artifactId>
    <name>Plexus Compiler Manager</name>
    <version>1.5.1</version>
    <ciManagement>
      <notifiers>
        <notifier>
          <configuration>
            <address>dev at plexus.codehaus.org</address>
          </configuration>
        </notifier>
        <notifier>
          <type>irc</type>
          <configuration>
            <port>6667</port>
            <channel>#plexus</channel>
            <host>irc.codehaus.org</host>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2001</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Plexus Developer List</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/plexus-dev/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at zenplex.com</email>
        <organization>Zenplex</organization>
        <roles>
          <role>Developer</role>
          <role>Release Manager</role>
        </roles>
      </developer>
      <developer>
        <id>kaz</id>
        <name>Pete Kazmier</name>
        <email></email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>jtaylor</id>
        <name>James Taylor</name>
        <email>james at jamestaylor.org</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>dandiep</id>
        <name>Dan Diephouse</name>
        <email>dan at envoisolutions.com</email>
        <organization>Envoi solutions</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kasper</id>
        <name>Kasper Nielsen</name>
        <email>apache at kav.dk</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>bwalding</id>
        <name>Ben Walding</name>
        <email>bwalding at codehaus.org</email>
        <organization>Walding Consulting Services</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>mhw</id>
        <name>Mark Wilkinson</name>
        <email>mhw at kremvax.net</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>mmaczka at interia.pl</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <scm>
      <connection>scm:svn:svn://svn.codehaus.org/plexus/scm/trunk/plexus-components/plexus-compiler/plexus-compiler-manager</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/trunk/plexus-components/plexus-compiler/plexus-compiler-manager</developerConnection>
    </scm>
    <organization>
      <name>Codehaus</name>
      <url>http://www.codehaus.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
      <plugins>
        <plugin>
          <artifactId>maven-release-plugin</artifactId>
          <configuration>
            <tagBase>https://svn.codehaus.org/plexus/tags</tagBase>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Snapshot Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </repository>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://www.ibiblio.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots-plugins</id>
        <name>Maven Snapshot Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://www.ibiblio.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.4</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-compiler-api</artifactId>
        <version>1.5.1</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:33;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.pom.sha1
  
  Index: plexus-compiler-manager-1.5.1.pom.sha1
  ===================================================================
  ffe8463de3b7f40cce3f35673c569f17c4ed0b76  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:37 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:37 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-components/1.1.6
	...
Message-ID: <E1GtSfF-0006ar-Ix@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:37

  Added:       maven2/org/codehaus/plexus/plexus-components/1.1.6  
                        plexus-components-1.1.6.pom
                        plexus-components-1.1.6.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-components/1.1.6/plexus-components-1.1.6.pom
  
  Index: plexus-components-1.1.6.pom
  ===================================================================
  <!--
  
   !!!
  
   NOTE: If you change this file, you MUST bump the version up from 1.0. That is the version of the POM, and was
   used for releases of plexus-compiler and plexus-archiver in the past.
  
   !!!
  
  -->
  
  <project>
    <modelVersion>4.0.0</modelVersion>
    <parent>
      <artifactId>plexus</artifactId>
      <groupId>org.codehaus.plexus</groupId>
      <version>1.0.8</version>
    </parent>
    <groupId>org.codehaus.plexus</groupId>
    <artifactId>plexus-components</artifactId>
    <packaging>pom</packaging>
    <version>1.1.6</version>
    <name>Plexus Components Parent Project</name>
    <!-- 
      TODO: should this be pushed down to all the dependencies?
        - a more stable API JAR may be useful, for the interfaces and classes such as AbstractLogEnabled
    -->
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-8</version>
      </dependency>
    </dependencies>
    <modules>
      <module>plexus-action</module>
      <module>plexus-archiver</module>
      <module>plexus-bayesian</module>  
      <module>plexus-command</module>
      <module>plexus-compiler</module>
      <module>plexus-drools</module>        
      <module>plexus-formica</module>
      <module>plexus-formica-web</module>
      <module>plexus-hibernate</module>
      <module>plexus-i18n</module>            
      <module>plexus-interactivity</module>        
      <module>plexus-ircbot</module>    
      <module>plexus-jdo</module>
      <module>plexus-jetty-httpd</module>    
      <module>plexus-jetty</module>
      <module>plexus-mimetyper</module>    
      <module>plexus-notification</module>
      <module>plexus-resource</module>
      <module>plexus-security</module>
      <module>plexus-summit</module>
      <module>plexus-taskqueue</module>    
      <module>plexus-velocity</module>
      <module>plexus-xmlrpc</module>
    </modules>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:40:37;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-components/1.1.6/plexus-components-1.1.6.pom.sha1
  
  Index: plexus-components-1.1.6.pom.sha1
  ===================================================================
  682713aa402653d0ea5e224870dc899803734519
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:41 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:41 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6
	...
Message-ID: <E1GtSfJ-0006bI-Uk@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:41

  Added:       maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6    
                        plexus-i18n-1.0-beta-6.jar
                        plexus-i18n-1.0-beta-6.jar.sha1
                        plexus-i18n-1.0-beta-6.pom
                        plexus-i18n-1.0-beta-6.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:40:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.jar.sha1
  
  Index: plexus-i18n-1.0-beta-6.jar.sha1
  ===================================================================
  0de20e1eea680fc277fddb66bc24ba40d449168b
  
  
  1.1      date: 2006/12/10 17:40:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.pom
  
  Index: plexus-i18n-1.0-beta-6.pom
  ===================================================================
  <project>
    <parent>
      <artifactId>plexus-components</artifactId>
      <groupId>org.codehaus.plexus</groupId>
      <version>1.1.4</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>plexus-i18n</artifactId>
    <name>Plexus I18N Component</name>
    <version>1.0-beta-6</version>
    <build>
      <plugins>
        <plugin>
          <groupId>org.codehaus.plexus</groupId>
          <artifactId>plexus-maven-plugin</artifactId>
          <version>1.1</version>
          <executions>
            <execution>
              <goals>
                <goal>descriptor</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </build>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:41;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.pom.sha1
  
  Index: plexus-i18n-1.0-beta-6.pom.sha1
  ===================================================================
  13316ac895a5b48193582f06273e7f447c9cfd58  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:45 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:45 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4
	...
Message-ID: <E1GtSfN-0006ba-NI@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:45

  Added:       maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4  
                        plexus-interactivity-api-1.0-alpha-4.pom
                        plexus-interactivity-api-1.0-alpha-4.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4/plexus-interactivity-api-1.0-alpha-4.pom
  
  Index: plexus-interactivity-api-1.0-alpha-4.pom
  ===================================================================
  <project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.codehaus.plexus</groupId>
    <artifactId>plexus-interactivity-api</artifactId>
    <name>Plexus Default Interactivity Handler</name>
    <version>1.0-alpha-4</version>
    <ciManagement>
      <notifiers>
        <notifier>
          <configuration>
            <address>dev at plexus.codehaus.org</address>
          </configuration>
        </notifier>
        <notifier>
          <type>irc</type>
          <configuration>
            <port>6667</port>
            <channel>#plexus</channel>
            <host>irc.codehaus.org</host>
          </configuration>
        </notifier>
      </notifiers>
    </ciManagement>
    <inceptionYear>2001</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Plexus Developer List</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/plexus-dev/</archive>
      </mailingList>
    </mailingLists>
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at zenplex.com</email>
        <organization>Zenplex</organization>
        <roles>
          <role>Developer</role>
          <role>Release Manager</role>
        </roles>
      </developer>
      <developer>
        <id>kaz</id>
        <name>Pete Kazmier</name>
        <email></email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>jtaylor</id>
        <name>James Taylor</name>
        <email>james at jamestaylor.org</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>dandiep</id>
        <name>Dan Diephouse</name>
        <email>dan at envoisolutions.com</email>
        <organization>Envoi solutions</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kasper</id>
        <name>Kasper Nielsen</name>
        <email>apache at kav.dk</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>bwalding</id>
        <name>Ben Walding</name>
        <email>bwalding at codehaus.org</email>
        <organization>Walding Consulting Services</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>mhw</id>
        <name>Mark Wilkinson</name>
        <email>mhw at kremvax.net</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>mmaczka at interia.pl</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>trygvis</id>
        <name>Trygve Laugstol</name>
        <email>trygvis at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kenney</id>
        <name>Kenney Westerhof</name>
        <email>kenney at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <scm>
      <connection>scm:svn:svn://svn.codehaus.org/plexus/scm/trunk/plexus-components/plexus-interactivity/plexus-interactivity-api</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/trunk/plexus-components/plexus-interactivity/plexus-interactivity-api</developerConnection>
    </scm>
    <organization>
      <name>Codehaus</name>
      <url>http://www.codehaus.org/</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <scriptSourceDirectory>src/main/scripts</scriptSourceDirectory>
      <testSourceDirectory>src/test/java</testSourceDirectory>
      <outputDirectory>target/classes</outputDirectory>
      <testOutputDirectory>target/test-classes</testOutputDirectory>
      <resources>
        <resource>
          <directory>src/main/resources</directory>
        </resource>
      </resources>
      <testResources>
        <testResource>
          <directory>src/test/resources</directory>
        </testResource>
      </testResources>
      <directory>target</directory>
      <plugins>
        <plugin>
          <artifactId>maven-release-plugin</artifactId>
          <configuration>
            <tagBase>https://svn.codehaus.org/plexus/tags</tagBase>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots</id>
        <name>Maven Snapshot Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </repository>
      <repository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Repository Switchboard</name>
        <url>http://repo1.maven.org/maven2</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <releases>
          <enabled>false</enabled>
        </releases>
        <id>snapshots-plugins</id>
        <name>Maven Snapshot Plugins Development Repository</name>
        <url>http://snapshots.maven.codehaus.org/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
        </snapshots>
        <id>central</id>
        <name>Maven Plugin Repository</name>
        <url>http://repo1.maven.org/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-container-default</artifactId>
        <version>1.0-alpha-7</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>classworlds</groupId>
        <artifactId>classworlds</artifactId>
        <version>1.1-alpha-2</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>plexus</groupId>
        <artifactId>plexus-utils</artifactId>
        <version>1.0.2</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <reporting>
      <outputDirectory>target/site</outputDirectory>
    </reporting>
    <distributionManagement>
      <repository>
        <id>repo1</id>
        <name>Maven Central Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/to-ibiblio/maven2</url>
      </repository>
      <snapshotRepository>
        <id>snapshots</id>
        <name>Maven Central Development Repository</name>
        <url>scp://repo1.maven.org/home/projects/maven/repository-staging/snapshots/maven2</url>
      </snapshotRepository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:45;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4/plexus-interactivity-api-1.0-alpha-4.pom.sha1
  
  Index: plexus-interactivity-api-1.0-alpha-4.pom.sha1
  ===================================================================
  1376ffcc4a8d46dee6c1a9096d0dcad3be01f838  /home/projects/maven/repository-staging/to-ibiblio/maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4/plexus-interactivity-api-1.0-alpha-4.pom
  
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:55 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:55 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.1 ...
Message-ID: <E1GtSfX-0006c0-0E@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:54

  Added:       maven2/org/codehaus/plexus/plexus-utils/1.1  
                        plexus-utils-1.1.jar plexus-utils-1.1.jar.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:54;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:40:54;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar.sha1
  
  Index: plexus-utils-1.1.jar.sha1
  ===================================================================
  fa632b7f1cb7c50963d0fb7d818ca93c75c10127
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:55 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:55 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.2 ...
Message-ID: <E1GtSfX-0006cA-42@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:55

  Added:       maven2/org/codehaus/plexus/plexus-utils/1.2  
                        plexus-utils-1.2.pom plexus-utils-1.2.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:55;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.2/plexus-utils-1.2.pom
  
  Index: plexus-utils-1.2.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <parent>
      <artifactId>plexus</artifactId>
      <groupId>org.codehaus.plexus</groupId>
      <version>1.0.5</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>plexus-utils</artifactId>
    <name>Plexus Common Utilities</name>
    <version>1.2</version>
    <build>
      <plugins>
        <plugin>
          <artifactId>maven-surefire-plugin</artifactId>
          <configuration>
            <excludes>
              <exclude>org/codehaus/plexus/util/FileBasedTestCase.java</exclude>
              <exclude>**/Test*.java</exclude>
            </excludes>
          </configuration>
        </plugin>
      </plugins>
    </build>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:55;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-utils/1.2/plexus-utils-1.2.pom.sha1
  
  Index: plexus-utils-1.2.pom.sha1
  ===================================================================
  f7c4dcf1d7602d7cefff308510c67316b215ce28
  
  


From scott.stark at jboss.com  Sun Dec 10 12:40:58 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:40:58 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3
	...
Message-ID: <E1GtSfa-0006ca-TB@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:40:58

  Added:       maven2/org/codehaus/plexus/plexus-velocity/1.1.3    
                        plexus-velocity-1.1.3.jar
                        plexus-velocity-1.1.3.jar.sha1
                        plexus-velocity-1.1.3.pom
                        plexus-velocity-1.1.3.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:40:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 17:40:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.jar.sha1
  
  Index: plexus-velocity-1.1.3.jar.sha1
  ===================================================================
  b0784af8b5cd2d5b7082b5faf774228218fdcb13
  
  
  1.1      date: 2006/12/10 17:40:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.pom
  
  Index: plexus-velocity-1.1.3.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <parent>
      <artifactId>plexus-components</artifactId>
      <groupId>org.codehaus.plexus</groupId>
      <version>1.1.5</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>
    <artifactId>plexus-velocity</artifactId>
    <name>Plexus Velocity Component</name>
    <version>1.1.3</version>
    <scm>
      <connection>scm:svn:https://svn.codehaus.org/plexus/tags/plexus-velocity-1.1.3</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/tags/plexus-velocity-1.1.3</developerConnection>
    </scm>
    <dependencies>
      <dependency>
        <groupId>commons-collections</groupId>
        <artifactId>commons-collections</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>velocity</groupId>
        <artifactId>velocity</artifactId>
        <version>1.4</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/10 17:40:58;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.pom.sha1
  
  Index: plexus-velocity-1.1.3.pom.sha1
  ===================================================================
  8c6a45df984d99c15f421a911ce241148f34b451
  
  


From scott.stark at jboss.com  Sun Dec 10 12:41:02 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:41:02 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/codehaus/plexus/plexus/1.0.8 ...
Message-ID: <E1GtSfe-0006cx-M0@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:41:02

  Added:       maven2/org/codehaus/plexus/plexus/1.0.8   plexus-1.0.8.pom
                        plexus-1.0.8.pom.sha1
  Log:
  
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 17:41:02;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus/1.0.8/plexus-1.0.8.pom
  
  Index: plexus-1.0.8.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <project xmlns="http://maven.apache.org/POM/4.0.0"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>
    <groupId>org.codehaus.plexus</groupId>
    <artifactId>plexus</artifactId>
    <packaging>pom</packaging>
    <name>Plexus</name>
    <version>1.0.8</version>
    <ciManagement>
      <notifiers>
        <notifier>
          <type>mail</type>
          <configuration>
            <address>dev at plexus.codehaus.org</address>
          </configuration>
        </notifier>
        <notifier>
          <type>irc</type>
          <configuration>
            <host>irc.codehaus.org</host>
            <port>6667</port>
            <channel>#plexus</channel>
          </configuration>
        </notifier>      
      </notifiers>
    </ciManagement>
    <inceptionYear>2001</inceptionYear>
    <mailingLists>
      <mailingList>
        <name>Plexus Developer List</name>
        <subscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</subscribe>
        <unsubscribe>http://lists.codehaus.org/mailman/listinfo/plexus-dev</unsubscribe>
        <archive>http://lists.codehaus.org/pipermail/plexus-dev/</archive>
      </mailingList>
    </mailingLists>
    <issueManagement>
      <system>JIRA</system>
      <url>http://jira.codehaus.org/browse/PLX</url>
    </issueManagement>
  
    <distributionManagement>
      <repository>
        <id>codehaus.org</id>
        <name>Plexus Central Repository</name>
        <url>dav:https://dav.codehaus.org/repository/plexus</url>
      </repository>
      <snapshotRepository>
        <id>codehaus.org</id>
        <name>Plexus Central Development Repository</name>
        <url>dav:https://dav.codehaus.org/snapshots.repository/plexus</url>
      </snapshotRepository>
      <site>
        <id>codehaus.org</id>
        <url>dav:https://dav.codehaus.org/plexus</url>
      </site>
    </distributionManagement>
    <repositories>
      <repository>
        <id>apache-snapshots</id>
        <name>Snapshot repository</name>
        <url>http://people.apache.org/maven-snapshot-repository</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </repository>
      <repository>
        <id>codehaus-snapshots</id>
        <name>Codehaus Snapshot Development Repository</name>
        <url>http://snapshots.repository.codehaus.org</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <id>codehaus-snapshots</id>
        <name>Codehaus Snapshot Development Repository</name>
        <url>http://snapshots.repository.codehaus.org</url>
        <releases>
          <enabled>false</enabled>
        </releases>
      </pluginRepository>
    </pluginRepositories>
  
    <developers>
      <developer>
        <id>jvanzyl</id>
        <name>Jason van Zyl</name>
        <email>jason at maven.org</email>
        <roles>
          <role>Developer</role>
          <role>Release Manager</role>
        </roles>
      </developer>
      <developer>
        <id>kaz</id>
        <name>Pete Kazmier</name>
        <email></email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>jtaylor</id>
        <name>James Taylor</name>
        <email>james at jamestaylor.org</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>dandiep</id>
        <name>Dan Diephouse</name>
        <email>dan at envoisolutions.com</email>
        <organization>Envoi solutions</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>kasper</id>
        <name>Kasper Nielsen</name>
        <email>apache at kav.dk</email>
        <organization></organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>bwalding</id>
        <name>Ben Walding</name>
        <email>bwalding at codehaus.org</email>
        <organization>Walding Consulting Services</organization>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>mhw</id>
        <name>Mark Wilkinson</name>
        <email>mhw at kremvax.net</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>michal</id>
        <name>Michal Maczka</name>
        <email>mmaczka at interia.pl</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <id>evenisse</id>
        <name>Emmanuel Venisse</name>
        <email>evenisse at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <name>Trygve Laugstol</name>
        <id>trygvis</id>
        <email>trygvis at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <name>Kenney Westerhof</name>
        <id>kenney</id>
        <email>kenney at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <name>Carlos Sanchez</name>
        <id>carlos</id>
        <email>carlos at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <name>Brett Porter</name>
        <id>brett</id>
        <email>brett at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
      <developer>
        <name>John Casey</name>
        <id>jdcasey</id>
        <email>jdcasey at codehaus.org</email>
        <roles>
          <role>Developer</role>
        </roles>
      </developer>
    </developers>
    <dependencies>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <scm>
      <connection>scm:svn:http://svn.codehaus.org/plexus/trunk/</connection>
      <developerConnection>scm:svn:https://svn.codehaus.org/plexus/trunk</developerConnection>
    </scm>
    <organization>
      <name>Codehaus</name>
      <url>http://www.codehaus.org/</url>
    </organization>
    <modules>
      <!--
      
      Until the bug is fixed in Maven which is pulling in the trunk to the
      appserver build.
      <module>plexus-appserver</module>
      -->
      <module>plexus-archetypes</module>
      <module>plexus-examples</module>
      <module>plexus-components</module>
      <module>plexus-component-factories</module>
      <module>plexus-containers</module>
      <module>plexus-logging</module>
      <module>plexus-maven-plugin</module>
      <module>plexus-tools</module>
      <module>plexus-utils</module>
    </modules>
    <build>
      <extensions>
        <extension>
          <groupId>org.apache.maven.wagon</groupId>
          <artifactId>wagon-webdav</artifactId>
          <version>1.0-beta-1</version>
        </extension>
      </extensions>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <configuration>
            <tagBase>https://svn.codehaus.org/plexus/tags</tagBase>
          </configuration>
        </plugin>
      </plugins>
    </build>
  </project>
  
  
  
  1.1      date: 2006/12/10 17:41:02;  author: starksm;  state: Exp;repository.jboss.com/maven2/org/codehaus/plexus/plexus/1.0.8/plexus-1.0.8.pom.sha1
  
  Index: plexus-1.0.8.pom.sha1
  ===================================================================
  9e7c8432829962afe796b32587c1bfa841a317d5
  
  


From scott.stark at jboss.com  Sun Dec 10 12:53:43 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:53:43 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/mortbay - New directory
	...
Message-ID: <E1GtSrv-0006qx-Oc@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:53:43

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:53:46 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:53:46 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/mortbay/jetty - New
	directory ...
Message-ID: <E1GtSry-0006r6-Vi@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:53:46

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:53:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:53:50 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/mortbay/jetty/jetty - New
	directory ...
Message-ID: <E1GtSs2-0006rF-7b@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:53:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty/jetty added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:53:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:53:50 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/org/mortbay/jetty/project -
	New directory ...
Message-ID: <E1GtSs2-0006rJ-B2@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:53:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty/project added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:53:50 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:53:50 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/mortbay/jetty/servlet-api-2.5 -
	New directory ...
Message-ID: <E1GtSs2-0006rN-FN@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:53:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty/servlet-api-2.5 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:53:53 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:53:53 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/mortbay/jetty/jetty/6.0.0beta12
	- New directory ...
Message-ID: <E1GtSs5-0006rW-M5@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:53:53

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty/jetty/6.0.0beta12 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:54:04 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:54:04 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/mortbay/jetty/project/6.0.0beta12
	- New directory ...
Message-ID: <E1GtSsG-0006rp-2F@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:54:04

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty/project/6.0.0beta12 added to the repository


From scott.stark at jboss.com  Sun Dec 10 12:54:10 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 10 Dec 2006 12:54:10 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/org/mortbay/jetty/servlet-api-2.5/6.0.0beta12
	- New directory ...
Message-ID: <E1GtSsM-0006s3-VO@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/10 12:54:10

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/org/mortbay/jetty/servlet-api-2.5/6.0.0beta12 added to the repository


From validimir.ralev at jboss.com  Sun Dec 10 16:32:04 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sun, 10 Dec 2006 16:32:04 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3 - New
	directory ...
Message-ID: <E1GtWHE-0002SB-Et@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/10 16:32:04

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/izpack/3.9.0.jboss.patch3 added to the repository


From validimir.ralev at jboss.com  Sun Dec 10 16:32:04 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sun, 10 Dec 2006 16:32:04 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib - New
	directory ...
Message-ID: <E1GtWHE-0002SF-Ig@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/10 16:32:04

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/izpack/3.9.0.jboss.patch3/lib added to the repository


From validimir.ralev at jboss.com  Sun Dec 10 16:47:07 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sun, 10 Dec 2006 16:47:07 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib ...
Message-ID: <E1GtWVn-0002gY-9r@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/10 16:47:07

  Added:       repository.jboss.com/izpack/3.9.0.jboss.patch3/lib             
                        installer.jar izevent.jar kunststoff.jar
                        standalone-compiler.jar uninstaller.jar
                        compiler.jar uninstaller-ext.jar ant.jar bin.zip
                        jakarta-regexp-1.3.jar liquidlnf.jar looks.jar
                        metouia.jar
  Log:
  http://jira.jboss.com/jira/browse/JBINSTALL-125
  http://jira.jboss.com/jira/browse/JBINSTALL-144
  http://jira.jboss.com/jira/browse/JBINSTALL-147
  http://jira.jboss.com/jira/browse/JBINSTALL-46
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/installer.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/izevent.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/kunststoff.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/compiler.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller-ext.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/ant.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/bin.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/jakarta-regexp-1.3.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/liquidlnf.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/looks.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/metouia.jar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Sun Dec 10 16:47:07 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sun, 10 Dec 2006 16:47:07 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3  ...
Message-ID: <E1GtWVn-0002gf-DP@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/10 16:47:07

  Added:       repository.jboss.com/izpack/3.9.0.jboss.patch3 
                        component-info.xml
  Log:
  http://jira.jboss.com/jira/browse/JBINSTALL-125
  http://jira.jboss.com/jira/browse/JBINSTALL-144
  http://jira.jboss.com/jira/browse/JBINSTALL-147
  http://jira.jboss.com/jira/browse/JBINSTALL-46
  
  Revision  Changes    Path
  1.1      date: 2006/12/10 21:47:07;  author: vralev;  state: Exp;/repository.jboss.com/izpack/3.9.0.jboss.patch3/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="izpack">
  
     <component id="izpack"
                licenseType="apache-2.0"
                version="3.9.0.jboss.patch3"
                projectHome="http://www.izforge.com/izpack"
                description="IzPack is a Java software installer builder with custom install group panels, and -installGroup based command line install"
        >
  
        <artifact id="standalone-compiler.jar"/>
        <artifact id="compiler.jar"/>
        <artifact id="izevent.jar"/>
        <artifact id="installer.jar"/>
        <artifact id="jakarta-regexp-1.3.jar"/>
        <artifact id="kunststoff.jar" />
        <artifact id="liquidlnf.jar" />
        <artifact id="looks.jar" />
        <artifact id="metouia.jar" />
        <artifact id="uninstaller-ext.jar" />
        <artifact id="uninstaller.jar" />
        <artifact id="bin.zip"/>
  
        <export>
           <include input="standalone-compiler.jar"/>
           <include input="izevent.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From validimir.ralev at jboss.com  Sun Dec 10 16:47:55 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sun, 10 Dec 2006 16:47:55 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss/izpack-listeners/1.0.1.GA ...
Message-ID: <E1GtWWZ-0002gr-3B@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/10 16:47:55

  Modified:    repository.jboss.com/jboss/izpack-listeners/1.0.1.GA 
                        component-info.xml
  Log:
  support for izpack jboss patch3
  
  Revision  Changes    Path
  1.5       +1 -0      /repository.jboss.com/jboss/izpack-listeners/1.0.1.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss//repository.jboss.com/jboss/izpack-listeners/1.0.1.GA/component-info.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- component-info.xml	30 Nov 2006 16:29:31 -0000	1.4
  +++ component-info.xml	10 Dec 2006 21:47:55 -0000	1.5
  @@ -13,6 +13,7 @@
         	<compatible version="3.9.0.jboss.2"/>
         	<compatible version="3.9.0.jboss.patch1"/>
         	<compatible version="3.9.0.jboss.patch2"/>
  +      	<compatible version="3.9.0.jboss.patch3"/>
         </import>
   
         <export>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 17:06:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 17:06:27 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1754 - in
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss:
	jms/server/endpoint messaging/core/plugin/postoffice/cluster
Message-ID: <E1GtWoV-00038W-5S@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-10 17:06:23 -0500 (Sun, 10 Dec 2006)
New Revision: 1754

Added:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java
Log:
Missing files


Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java	2006-12-10 12:37:08 UTC (rev 1753)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java	2006-12-10 22:06:23 UTC (rev 1754)
@@ -0,0 +1,65 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+import java.io.Serializable;
+
+import org.jboss.jms.delegate.ConnectionDelegate;
+
+/**
+ * A ConnectionStatus
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class ConnectionStatus implements Serializable
+{
+   private static final long serialVersionUID = 4311863642735135167L;
+   
+   private ConnectionDelegate delegate;
+   
+   private int actualFailoverNodeId;
+   
+   public ConnectionStatus(ConnectionDelegate del)
+   {
+      this.delegate = del;
+   }
+   
+   public ConnectionStatus(int actualFailoverNode)
+   {
+      this.actualFailoverNodeId = actualFailoverNode;
+   }
+   
+   public ConnectionDelegate getDelegate()
+   {
+      return delegate;
+   }
+   
+   public int getActualFailoverNode()
+   {
+      return actualFailoverNodeId;
+   }
+
+}

Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java	2006-12-10 12:37:08 UTC (rev 1753)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java	2006-12-10 22:06:23 UTC (rev 1754)
@@ -0,0 +1,98 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.messaging.core.plugin.postoffice.cluster;
+
+import java.io.Serializable;
+import java.util.Collections;
+import java.util.LinkedHashSet;
+import java.util.List;
+import java.util.Set;
+
+/**
+ * A FailoverStatus
+ *
+ * This class is a state machine for failover state for a node
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class FailoverStatus implements Serializable
+{
+   private static final long serialVersionUID = -2668162690753929133L;
+
+   //The set of nodes the server has completed failover for since it was last restarted
+   private Set failedOverForNodes;
+   
+   //The node the server is currently failing over for (if any)
+   private int currentlyFailingOverForNode;
+   
+   //Is the server currently failing over?
+   private boolean failingOver;
+   
+   public FailoverStatus()
+   {      
+      failedOverForNodes = new LinkedHashSet();
+   }
+   
+   public void startFailingOverForNode(int nodeId)
+   {
+      if (failingOver)
+      {
+         throw new IllegalStateException("Already failing over for node " + currentlyFailingOverForNode);
+      }
+      
+      currentlyFailingOverForNode = nodeId;
+      
+      failingOver = true;
+   }
+   
+   public void finishFailingOver()
+   {
+      if (!failingOver)
+      {
+         throw new IllegalStateException("The node is not currently failing over");
+      }
+      
+      failedOverForNodes.add(new Integer(currentlyFailingOverForNode));
+      
+      failingOver = false;
+   }
+   
+   public Set getFailedOverForNodes()
+   {
+      return Collections.unmodifiableSet(failedOverForNodes);
+   }
+   
+   public boolean isFailedOverForNode(int nodeId)
+   {
+      return failedOverForNodes.contains(new Integer(nodeId));
+   }
+   
+   public boolean isFailingOverForNode(int nodeId)
+   {
+      return failingOver && currentlyFailingOverForNode == nodeId;
+   }
+   
+}



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 17:16:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 17:16:20 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1755 - in
	branches/Branch_Client_Failover_Experiment: src/etc/xmdesc
	src/main/org/jboss/jms/client/state
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core/plugin
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GtWy4-0003Jv-U6@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-10 17:16:12 -0500 (Sun, 10 Dec 2006)
New Revision: 1755

Added:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
Modified:
   branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
introducing a group management interface (Peer)

Modified: branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml	2006-12-10 22:16:12 UTC (rev 1755)
@@ -17,6 +17,12 @@
       <type>org.jboss.messaging.core.plugin.contract.MessagingComponent</type>
    </attribute>
 
+   <attribute access="read-only" getMethod="getNodeIDView">
+      <description>The set containing cluster group members' node IDs</description>
+      <name>NodeIDView</name>
+      <type>java.util.Set</type>
+   </attribute>
+
    <attribute access="read-write" getMethod="getDataSource" setMethod="setDataSource">
       <description>The JNDI name of the DataSource used by this ChannelMapper instance</description>
       <name>DataSource</name>

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -32,7 +32,6 @@
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
-import org.jboss.remoting.ConnectionListener;
 
 import EDU.oswego.cs.dl.util.concurrent.SyncSet;
 import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -40,7 +40,9 @@
    ConnectionDelegate createConnectionDelegate(String username, String password)
       throws JMSException;
    
-   ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
+   ConnectionStatus createFailoverConnectionDelegate(String username,
+                                                     String password, 
+                                                     int failedNodeId)
       throws JMSException;
    
    byte[] getClientAOPConfig() throws JMSException;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -36,66 +36,78 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
+import org.jboss.messaging.core.plugin.postoffice.cluster.Peer;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.w3c.dom.Element;
 
+import java.util.Set;
+import java.util.Collections;
+
 /**
  * A ClusteredPostOfficeService
  * 
  * MBean wrapper for a clustered post office
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
  *
  */
-public class ClusteredPostOfficeService extends JDBCServiceSupport
+public class ClusteredPostOfficeService extends JDBCServiceSupport implements Peer
 {
-   private DefaultClusteredPostOffice postOffice;
-   
-   private ObjectName serverPeerObjectName;
-   
-   private String officeName;
-   
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private boolean started;
-   
+
    private Element syncChannelConfig;
-   
    private Element asyncChannelConfig;
-   
+
+   private ObjectName serverPeerObjectName;
+
+   private String officeName;
    private long stateTimeout = 5000;
-   
    private long castTimeout = 5000;
-     
    private String groupName;
-   
    private long statsSendPeriod = 1000;
-   
    private String clusterRouterFactory;
-   
    private String messagePullPolicy;
-   
-   // Constructors --------------------------------------------------------
-   
-   public ClusteredPostOfficeService()
-   {      
-   }
-   
-   // ServerPlugin implementation ------------------------------------------
-   
+
+   private DefaultClusteredPostOffice postOffice;
+
+   // Constructors --------------------------------------------------
+
+   // ServerPlugin implementation -----------------------------------
+
    public MessagingComponent getInstance()
    {
       return postOffice;
    }
-   
-   // MBean attributes -----------------------------------------------------
-   
+
+   // Peer implementation -------------------------------------------
+
+   public Set getNodeIDView()
+   {
+      if (postOffice == null)
+      {
+         return Collections.EMPTY_SET;
+      }
+
+      return postOffice.getNodeIDView();
+   }
+
+   // MBean attributes ----------------------------------------------
+
    public synchronized ObjectName getServerPeer()
    {
       return serverPeerObjectName;
    }
-   
+
    public synchronized void setServerPeer(ObjectName on)
    {
       if (started)
@@ -105,12 +117,12 @@
       }
       this.serverPeerObjectName = on;
    }
-   
+
    public synchronized String getPostOfficeName()
    {
       return officeName;
    }
-   
+
    public synchronized void setPostOfficeName(String name)
    {
       if (started)
@@ -120,7 +132,7 @@
       }
       this.officeName = name;
    }
-   
+
    public void setSyncChannelConfig(Element config) throws Exception
    {
       syncChannelConfig = config;
@@ -130,7 +142,7 @@
    {
       return syncChannelConfig;
    }
-   
+
    public void setAsyncChannelConfig(Element config) throws Exception
    {
       asyncChannelConfig = config;
@@ -140,62 +152,62 @@
    {
       return asyncChannelConfig;
    }
-   
+
    public void setStateTimeout(long timeout)
    {
       this.stateTimeout = timeout;
    }
-   
+
    public long getStateTimeout()
    {
       return stateTimeout;
    }
-   
+
    public void setCastTimeout(long timeout)
    {
       this.castTimeout = timeout;
    }
-   
+
    public long getCastTimeout()
    {
       return castTimeout;
    }
-   
+
    public void setGroupName(String groupName)
    {
       this.groupName = groupName;
    }
-   
+
    public String getGroupName()
    {
       return groupName;
    }
-   
+
    public void setStatsSendPeriod(long period)
    {
       this.statsSendPeriod = period;
    }
-   
+
    public long getStatsSendPeriod()
    {
       return statsSendPeriod;
    }
-   
+
    public String getClusterRouterFactory()
    {
       return clusterRouterFactory;
    }
-   
+
    public String getMessagePullPolicy()
    {
       return messagePullPolicy;
    }
-   
+
    public void setClusterRouterFactory(String clusterRouterFactory)
    {
       this.clusterRouterFactory = clusterRouterFactory;
    }
-   
+
    public void setMessagePullPolicy(String messagePullPolicy)
    {
       this.messagePullPolicy = messagePullPolicy;
@@ -205,90 +217,94 @@
    {
       return postOffice.printBindingInformation();
    }
-   
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
    // ServiceMBeanSupport overrides ---------------------------------
-   
+
    protected synchronized void startService() throws Exception
    {
       if (started)
       {
          throw new IllegalStateException("Service is already started");
       }
-      
+
       super.startService();
-      
+
       try
-      {  
+      {
          TransactionManager tm = getTransactionManagerReference();
-                           
+
          ServerPeer serverPeer = (ServerPeer)server.getAttribute(serverPeerObjectName, "Instance");
-         
          MessageStore ms = serverPeer.getMessageStore();
-         
          TransactionRepository tr = serverPeer.getTxRepository();
-         
          PersistenceManager pm = serverPeer.getPersistenceManagerInstance();
-         
          QueuedExecutorPool pool = serverPeer.getQueuedExecutorPool();
-                  
          int nodeId = serverPeer.getServerPeerID();
-         
+
          Class clazz = Class.forName(messagePullPolicy);
-         
          MessagePullPolicy pullPolicy = (MessagePullPolicy)clazz.newInstance();
-         
          clazz = Class.forName(clusterRouterFactory);
-         
+
          ClusterRouterFactory rf = (ClusterRouterFactory)clazz.newInstance();
-         
+
          FilterFactory ff = new SelectorFactory();
-         
          FailoverMapper mapper = new DefaultFailoverMapper();
 
-         postOffice =  new DefaultClusteredPostOffice(ds, tm, sqlProperties, createTablesOnStartup,
+         postOffice =  new DefaultClusteredPostOffice(ds, tm, sqlProperties,
+                                                      createTablesOnStartup,
                                                       nodeId, officeName, ms,
                                                       pm, tr, ff, pool,
                                                       groupName,
-                                                      syncChannelConfig, asyncChannelConfig,
+                                                      syncChannelConfig,
+                                                      asyncChannelConfig,
                                                       stateTimeout, castTimeout,
                                                       pullPolicy, rf,
                                                       mapper,
                                                       statsSendPeriod);
-         
+
          postOffice.start();
-         
-         started = true;         
+
+         started = true;
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " startService");
-      } 
+      }
    }
-   
+
    protected void stopService() throws Exception
    {
       if (!started)
       {
          throw new IllegalStateException("Service is not started");
       }
-      
-      super.stopService();      
-      
+
+      super.stopService();
+
       try
-      {      
+      {
          postOffice.stop();
-         
+
          postOffice = null;
-               
+
          started = false;
-         
+
          log.debug(this + " stopped");
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " startService");
-      } 
+      }
    }
-      
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -25,6 +25,7 @@
 
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
+import org.jboss.messaging.core.plugin.postoffice.cluster.Peer;
 
 /**
  * 
@@ -37,7 +38,7 @@
  * $Id$
  *
  */
-public interface ClusteredPostOffice extends PostOffice
+public interface ClusteredPostOffice extends PostOffice, Peer
 {
    /**
     * Bind a queue to the post office under a specific condition

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -92,64 +92,64 @@
    implements ClusteredPostOffice, PostOfficeInternal, Replicator
 {
    private static final Logger log = Logger.getLogger(DefaultClusteredPostOffice.class);
-   
+
    // Key for looking up node id -> address info mapping from replicated data
    public static final String ADDRESS_INFO_KEY = "address_info";
-   
+
    // Key for looking up node id -> failed over for node id mapping from replicated data
    public static final String FAILED_OVER_FOR_KEY = "failed_over_for";
-   
+
    //Used for failure testing
    private boolean failBeforeCommit;
-   
+
    private boolean failAfterCommit;
-   
+
    private boolean failHandleResult;
    //End of failure testing attributes
-     
+
    private boolean trace = log.isTraceEnabled();
 
    private Channel syncChannel;
-   
+
    private Channel asyncChannel;
-   
+
    private String groupName;
-   
+
    private MessageDispatcher controlMessageDispatcher;
-   
+
    private Object setStateLock = new Object();
-   
+
    private boolean stateSet;
-   
+
    private View currentView;
-   
-   private Map replicatedData;   
-   
+
+   private Map replicatedData;
+
    private Set replicationListeners;
-      
+
    private Map holdingArea;
-   
+
    //Map < node id , failover node id>
    private Map failoverMap;
-   
+
    private Set leftSet;
-   
+
    private Element syncChannelConfigElement;
-   
+
    private Element asyncChannelConfigElement;
-   
+
    private String syncChannelConfig;
-   
+
    private String asyncChannelConfig;
-   
+
    private long stateTimeout;
-   
+
    private long castTimeout;
-   
+
    private MessagePullPolicy messagePullPolicy;
-   
+
    private ClusterRouterFactory routerFactory;
-   
+
    private FailoverMapper failoverMapper;
 
    private Map routerMap;
@@ -159,11 +159,11 @@
    private Map failedBindings;
 
    private StatsSender statsSender;
-   
+
    private ReplicationListener nodeAddressMapListener;
 
    private boolean started;
-     
+
    /*
     * Constructor using Element for configuration
     */
@@ -191,11 +191,11 @@
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
            pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
            rf, failoverMapper, statsSendPeriod);
-      
+
       this.syncChannelConfigElement = syncChannelConfig;
       this.asyncChannelConfigElement = asyncChannelConfig;
    }
-     
+
    /*
     * Constructor using String for configuration
     */
@@ -218,7 +218,7 @@
                                      ClusterRouterFactory rf,
                                      FailoverMapper failoverMapper,
                                      long statsSendPeriod) throws Exception
-   {            
+   {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
            pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
            rf, failoverMapper, statsSendPeriod);
@@ -247,50 +247,50 @@
    {
       super (ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms, pm, tr,
              filterFactory, pool);
-                   
+
       this.groupName = groupName;
-      
+
       this.stateTimeout = stateTimeout;
-      
+
       this.castTimeout = castTimeout;
-      
+
       this.messagePullPolicy = redistributionPolicy;
-      
+
       this.routerFactory = rf;
-      
+
       this.failoverMapper = failoverMapper;
-      
+
       routerMap = new HashMap();
 
       failedBindings = new LinkedHashMap();
-      
+
       statsSender = new StatsSender(this, statsSendPeriod);
-      
+
       holdingArea = new HashMap();
-      
-      replicatedData = new HashMap();      
-      
+
+      replicatedData = new HashMap();
+
       replicationListeners = new LinkedHashSet();
-      
+
       failoverMap = new LinkedHashMap();
-      
+
       leftSet = new HashSet();
    }
 
    // MessagingComponent overrides
    // --------------------------------------------------------------
-   
+
    public synchronized void start() throws Exception
-   {    
+   {
       if (started)
       {
          log.warn("Attempt to start() but " + this + " is already started");
       }
 
       if (trace) { log.trace(this + " starting"); }
-      
+
       if (syncChannelConfigElement != null)
-      {        
+      {
          this.syncChannel = new JChannel(syncChannelConfigElement);
          this.asyncChannel = new JChannel(asyncChannelConfigElement);
       }
@@ -299,48 +299,48 @@
          this.syncChannel = new JChannel(syncChannelConfig);
          this.asyncChannel = new JChannel(asyncChannelConfig);
       }
-      
+
       // We don't want to receive local messages on any of the channels
       syncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
-      
+
       asyncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
-      
+
       MessageListener cml = new ControlMessageListener();
       MembershipListener ml = new ControlMembershipListener();
       RequestHandler rh = new PostOfficeRequestHandler();
-      
+
       //Register as a listener for nodeid-adress mapping events
       nodeAddressMapListener = new NodeAddressMapListener();
-      
+
       registerListener(nodeAddressMapListener);
 
       this.controlMessageDispatcher = new MessageDispatcher(syncChannel, cml, ml, rh, true);
 
       Receiver r = new DataReceiver();
-      
+
       asyncChannel.setReceiver(r);
 
       syncChannel.connect(groupName);
-      
+
       asyncChannel.connect(groupName);
-      
+
       super.start();
-            
+
       Address syncAddress = syncChannel.getLocalAddress();
-      
+
       Address asyncAddress = asyncChannel.getLocalAddress();
 
       PostOfficeAddressInfo info = new PostOfficeAddressInfo(syncAddress, asyncAddress);
-      
+
       put(ADDRESS_INFO_KEY, info);
 
       statsSender.start();
-      
+
       started = true;
 
       log.debug(this + " started");
    }
-   
+
    public synchronized void stop(boolean sendNotification) throws Exception
    {
       if (!started)
@@ -348,41 +348,82 @@
          log.warn("Attempt to stop() but " + this + " is not started");
       }
       else
-      {   
+      {
          syncSendRequest(new LeaveClusterRequest(this.getNodeId()));
-         
+
          super.stop(sendNotification);
-         
+
          unregisterListener(nodeAddressMapListener);
-         
+
          statsSender.stop();
-            
+
          syncChannel.close();
-         
+
          asyncChannel.close();
-         
+
          started = false;
-         
+
          if (trace) { log.trace("Stopped " + this); }
       }
-   }  
-   
-   // PostOffice implementation ---------------------------------------        
+   }
 
+   // Peer implementation -------------------------------------------
+
+   public Set getNodeIDView()
+   {
+      if (syncChannel == null)
+      {
+         return Collections.EMPTY_SET;
+      }
+
+      Map addressInfo = null;
+
+      synchronized(replicatedData)
+      {
+         addressInfo = new HashMap((Map)replicatedData.get(ADDRESS_INFO_KEY));
+      }
+
+      Set nodeIDView = null;
+
+      for (Iterator i = syncChannel.getView().getMembers().iterator(); i.hasNext(); )
+      {
+         if (nodeIDView == null)
+         {
+            nodeIDView = new HashSet();
+         }
+
+         Address addr = (Address)i.next();
+
+         for(Iterator j = addressInfo.entrySet().iterator(); j.hasNext(); )
+         {
+            Map.Entry entry = (Map.Entry)j.next();
+
+            if (((PostOfficeAddressInfo)(entry.getValue())).getSyncChannelAddress().equals(addr))
+            {
+               nodeIDView.add(entry.getKey());
+            }
+         }
+      }
+
+      return nodeIDView;
+   }
+
+   // ClusteredPostOffice implementation ----------------------------
+
    public Binding bindClusteredQueue(String condition, LocalClusteredQueue queue) throws Exception
    {
       if (trace)
       {
          log.trace(this.currentNodeId + " binding clustered queue: " + queue + " with condition: " + condition);
       }
-        
+
       if (queue.getNodeId() != this.currentNodeId)
       {
           log.warn("queue.getNodeId is not this node");
          //throw new IllegalArgumentException("Queue node id does not match office node id");
          // todo what to do when HA failing?
       }
-      
+
       Binding binding = (Binding)super.bindQueue(condition, queue);
 
       sendBindRequest(condition, queue, binding);
@@ -406,64 +447,64 @@
       {
          log.trace(this.currentNodeId + " unbind clustered queue: " + queueName);
       }
-      
+
       Binding binding = (Binding)super.unbindQueue(queueName);
-      
+
       UnbindRequest request = new UnbindRequest(this.currentNodeId, queueName);
-      
+
       syncSendRequest(request);
-      
+
       return binding;
    }
-   
+
    public boolean route(MessageReference ref, String condition, Transaction tx) throws Exception
    {
       if (trace)
       {
          log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx);
       }
-      
+
       //debug
       try
       {
          TextMessage tm = (TextMessage)ref.getMessage();
-         
+
          log.info(this.currentNodeId + " *********** Routing ref: " + tm.getText() + " with condition " + condition + " and transaction " + tx);
       }
       catch (Exception e)
       {
          e.printStackTrace();
       }
-      
+
       if (ref == null)
       {
          throw new IllegalArgumentException("Message reference is null");
       }
-      
+
       if (condition == null)
       {
          throw new IllegalArgumentException("Condition is null");
       }
-      
+
       boolean routed = false;
-      
+
       lock.readLock().acquire();
-   
+
       try
-      {      
+      {
          ClusteredBindings cb = (ClusteredBindings)conditionMap.get(condition);
-         
+
          boolean startInternalTx = false;
-         
+
          int lastNodeId = -1;
-         
+
          if (cb != null)
          {
             if (tx == null && ref.isReliable())
-            {                
+            {
                if (!(cb.getDurableCount() == 0 || (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
                {
-                  // When routing a persistent message without a transaction then we may need to start an 
+                  // When routing a persistent message without a transaction then we may need to start an
                   // internal transaction in order to route it.
                   // This is so we can guarantee the message is delivered to all or none of the subscriptions.
                   // We need to do this if there is anything other than
@@ -474,45 +515,45 @@
                      log.trace(this.currentNodeId + " Starting internal transaction since more than one durable sub or remote durable subs");
                   }
                }
-            }                        
-            
+            }
+
             if (startInternalTx)
             {
                tx = tr.createTransaction();
             }
-                
+
             int numberRemote = 0;
-            
+
             Map queueNameNodeIdMap = null;
-            
+
             long lastChannelId = -1;
-            
+
             Collection routers = cb.getRouters();
 
             Iterator iter = routers.iterator();
-                     
+
             while (iter.hasNext())
             {
                ClusterRouter router = (ClusterRouter)iter.next();
-               
+
                Delivery del = router.handle(null, ref, tx);
-               
+
                if (del != null && del.isSelectorAccepted())
                {
                   routed = true;
-               
+
                   ClusteredQueue queue = (ClusteredQueue)del.getObserver();
-                  
+
                   if (trace)
                   {
                      log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
                                queue.getNodeId() + " local:" + queue.isLocal());
-                     
+
                   }
-                  
+
                   log.info(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
                            queue.getNodeId() + " local:" + queue.isLocal());
-                  
+
                   if (router.numberOfReceivers() > 1)
                   {
                      //We have now chosen which one will receive the message so we need to add this
@@ -522,26 +563,26 @@
                      {
                         queueNameNodeIdMap = new HashMap();
                      }
-                     
+
                      queueNameNodeIdMap.put(queue.getName(), new Integer(queue.getNodeId()));
                   }
-                  
+
                   if (!queue.isLocal())
                   {
                      //We need to send the message remotely
                      numberRemote++;
-                     
-                     lastNodeId = queue.getNodeId();                                                               
-                                          
+
+                     lastNodeId = queue.getNodeId();
+
                      lastChannelId = queue.getChannelID();
                   }
                }
             }
-            
+
             //Now we've sent the message to any local queues, we might also need
             //to send the message to the other office instances on the cluster if there are
             //queues on those nodes that need to receive the message
-            
+
             //TODO - there is an innefficiency here, numberRemote does not take into account that more than one
             //of the number remote may be on the same node, so we could end up multicasting
             //when unicast would do
@@ -552,28 +593,28 @@
                   if (numberRemote == 1)
                   {
                      if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
-                     
-                     //Unicast - only one node is interested in the message                                        
+
+                     //Unicast - only one node is interested in the message
                      asyncSendRequest(new MessageRequest(condition, ref.getMessage(), null), lastNodeId);
                   }
                   else
                   {
                      if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
-                     
+
                      //Multicast - more than one node is interested
                      asyncSendRequest(new MessageRequest(condition, ref.getMessage(), queueNameNodeIdMap));
-                  }                                 
+                  }
                }
                else
                {
                   CastMessagesCallback callback = (CastMessagesCallback)tx.getCallback(this);
-                  
+
                   if (callback == null)
                   {
                      callback = new CastMessagesCallback(currentNodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
-                     
+
                      //This callback MUST be executed first
-                     
+
                      //Execution order is as follows:
                      //Before commit:
                      //1. Cast messages across network - get added to holding area (if persistent) on receiving
@@ -583,49 +624,49 @@
                      //1. Cast commit message across network
                      tx.addFirstCallback(callback, this);
                   }
-                      
+
                   callback.addMessage(condition, ref.getMessage(), queueNameNodeIdMap,
                                       numberRemote == 1 ? lastNodeId : -1,
-                                      lastChannelId);    
+                                      lastChannelId);
                }
             }
-                                                
+
             if (startInternalTx)
-            {               
+            {
                tx.commit();
                if (trace) { log.trace("Committed internal transaction"); }
             }
          }
       }
       finally
-      {                  
+      {
          lock.readLock().release();
       }
-         
-      return routed; 
+
+      return routed;
    }
-   
+
    public boolean isLocal()
    {
       return false;
    }
-   
+
    public Collection listAllBindingsForCondition(String condition) throws Exception
    {
       return listBindingsForConditionInternal(condition, false);
    }
-   
+
    public int getFailoverNodeID(int nodeId)
    {
       synchronized (failoverMap)
-      {         
+      {
          Integer failoverNode = (Integer)failoverMap.get(new Integer(nodeId));
-         
+
          if (failoverNode == null)
          {
             return nodeId;
          }
-         
+
          return failoverNode.intValue();
       }
    }
@@ -636,13 +677,13 @@
    }
 
    // Replicator implementation --------------------------------------------------------------------------
-   
+
    public Map get(Serializable key) throws Exception
    {
       synchronized (replicatedData)
-      {         
+      {
          Map m = (Map)replicatedData.get(key);
-            
+
          return m == null ? Collections.EMPTY_MAP : Collections.unmodifiableMap(m);
       }
    }
@@ -650,20 +691,20 @@
    public void put(Serializable key, Serializable replicant) throws Exception
    {
       putReplicantLocally(currentNodeId, key, replicant);
-      
+
       PutReplicantRequest request = new PutReplicantRequest(currentNodeId, key, replicant);
-      
+
       syncSendRequest(request);
    }
-   
+
    public boolean remove(Serializable key) throws Exception
    {
       if (removeReplicantLocally(this.currentNodeId, key))
-      {      
+      {
          RemoveReplicantRequest request = new RemoveReplicantRequest(this.currentNodeId, key);
-         
+
          syncSendRequest(request);
-         
+
          return true;
       }
       else
@@ -671,7 +712,7 @@
          return false;
       }
    }
-   
+
    public void registerListener(ReplicationListener listener)
    {
       synchronized (replicationListeners)
@@ -683,22 +724,22 @@
          replicationListeners.add(listener);
       }
    }
-   
+
    public void unregisterListener(ReplicationListener listener)
    {
       synchronized (replicationListeners)
       {
          boolean removed = replicationListeners.remove(listener);
-         
+
          if (!removed)
          {
             throw new IllegalArgumentException("Cannot find listener " + listener + " to remove");
          }
       }
    }
-    
+
    // PostOfficeInternal implementation ------------------------------------------------------------------
-   
+
    public void handleNodeLeft(int nodeId) throws Exception
    {
       synchronized (leftSet)
@@ -714,18 +755,18 @@
       throws Exception
    {
       synchronized (replicatedData)
-      {         
+      {
          Map m = (Map)replicatedData.get(key);
-         
+
          if (m == null)
          {
             m = new LinkedHashMap();
-            
+
             replicatedData.put(key, m);
          }
-         
+
          m.put(new Integer(originatorNodeID), replicant);
-         
+
          notifyListeners(key, m, true, originatorNodeID);
       }
    }
@@ -738,31 +779,31 @@
       synchronized (replicatedData)
       {
          log.info(this.currentNodeId + " removing key " + key + " from node " + originatorNodeID);
-         
+
          Map m = (Map)replicatedData.get(key);
-         
+
          if (m == null)
          {
             return false;
          }
-         
+
          Object obj = m.remove(new Integer(originatorNodeID));
-         
+
          if (obj == null)
          {
             return false;
          }
-         
+
          if (m.isEmpty())
          {
             replicatedData.remove(key);
-         } 
+         }
          notifyListeners(key, m, false, originatorNodeID);
-      
-         return true; 
+
+         return true;
       }
    }
-     
+
    /*
     * Called when another node adds a binding
     */
@@ -771,74 +812,74 @@
       throws Exception
    {
       lock.writeLock().acquire();
-    
+
       if (trace)
       {
          log.info(this.currentNodeId + " adding binding from node: " + nodeId + " queue: " + queueName + " with condition: " + condition);
       }
-            
+
       try
-      {                     
+      {
          //Sanity
 
          if (!knowAboutNodeId(nodeId))
          {
             throw new IllegalStateException("Don't know about node id: " + nodeId);
          }
-         
+
          // We currently only allow one binding per name per node
          Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-         
+
          Binding binding = null;
-         
+
          if (nameMap != null)
          {
             binding = (Binding)nameMap.get(queueName);
          }
-         
+
          if (binding != null && failed)
          {
             throw new IllegalArgumentException(this.currentNodeId + " Binding already exists for node Id " + nodeId + " queue name " + queueName);
          }
-            
+
          binding = this.createBinding(nodeId, condition, queueName, channelID, filterString, durable, failed);
-         
-         addBinding(binding);         
+
+         addBinding(binding);
       }
       finally
       {
          lock.writeLock().release();
       }
    }
-   
+
    /*
     * Called when another node removes a binding
     */
    public void removeBindingFromCluster(int nodeId, String queueName) throws Exception
    {
       lock.writeLock().acquire();
-      
+
       if (trace)
       {
-         log.trace(this.currentNodeId + " removing binding from node: " + nodeId + " queue: " + queueName);        
+         log.trace(this.currentNodeId + " removing binding from node: " + nodeId + " queue: " + queueName);
       }
-      
+
       try
-      {         
+      {
          // Sanity
          if (!knowAboutNodeId(nodeId))
          {
             throw new IllegalStateException("Don't know about node id: " + nodeId);
          }
-         
-         removeBinding(nodeId, queueName);         
+
+         removeBinding(nodeId, queueName);
       }
       finally
       {
          lock.writeLock().release();
       }
    }
-   
+
    public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKey,
                                 Map queueNameNodeIdMap) throws Exception
    {
@@ -847,14 +888,14 @@
          log.trace(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
                   routingKey + " map " + queueNameNodeIdMap);
       }
-      
+
       log.info(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
                routingKey + " map " + queueNameNodeIdMap);
-      
-      
-            
-      lock.readLock().acquire();  
 
+
+
+      lock.readLock().acquire();
+
       // Need to reference the message
       MessageReference ref = null;
       try
@@ -864,54 +905,54 @@
             // It will already have been persisted on the sender's side
             message.setPersisted(true);
          }
-         
+
          ref = ms.reference(message);
-              
+
          // We route on the condition
          DefaultClusteredBindings cb = (DefaultClusteredBindings)conditionMap.get(routingKey);
-         
+
          if (cb != null)
-         {                      
+         {
             Collection bindings = cb.getAllBindings();
-            
+
             Iterator iter = bindings.iterator();
-            
+
             while (iter.hasNext())
             {
                Binding binding = (Binding)iter.next();
-                                                     
+
                if (binding.getNodeId() == this.currentNodeId)
-               {  
+               {
                   boolean handle = true;
-                  
+
                   if (queueNameNodeIdMap != null)
-                  {           
+                  {
                      Integer in = (Integer)queueNameNodeIdMap.get(binding.getQueue().getName());
-                     
+
                      //When there are more than one queues with the same name across the cluster we only
                      //want to chose one of them
-                     
+
                      if (in != null)
                      {
                         handle = in.intValue() == currentNodeId;
                      }
                   }
-                  
+
                   if (handle)
-                  {                     
+                  {
                      //It's a local binding so we pass the message on to the subscription
-                     
+
                      LocalClusteredQueue queue = (LocalClusteredQueue)binding.getQueue();
-                     
-                     Delivery del = queue.handleFromCluster(ref);    
-                     
+
+                     Delivery del = queue.handleFromCluster(ref);
+
                      if (trace)
                      {
                         log.trace(this.currentNodeId + " queue " + queue.getName() + " handled reference from cluster " + del);
                      }
                   }
                }
-            }                          
+            }
          }
       }
       finally
@@ -923,42 +964,42 @@
          lock.readLock().release();
       }
    }
-   
+
    /*
     * Multicast a message to all members of the group
     */
    public void asyncSendRequest(ClusterRequest request) throws Exception
-   {     
+   {
       if (trace) { log.trace(this.currentNodeId + " sending asynch request to group, request: " + request); }
-      
+
       byte[] bytes = writeRequest(request);
-              
+
       asyncChannel.send(new Message(null, null, bytes));
    }
-   
+
    /*
     * Unicast a message to one member of the group
     */
    public void asyncSendRequest(ClusterRequest request, int nodeId) throws Exception
-   {               
+   {
       if (trace) { log.trace(this.currentNodeId + " sending asynch request to single node, request: " + request + " node " + nodeId); }
-      
+
       Address address = this.getAddressForNodeId(nodeId, false);
-      
+
       if (trace) { log.trace(this.currentNodeId + " sending to address " + address); }
-      
+
       if (address == null)
       {
          throw new IllegalArgumentException("Cannot find address for node " + nodeId);
       }
-      
+
       byte[] bytes = writeRequest(request);
-            
+
       Message m = new Message(address, null, bytes);
-      
-      asyncChannel.send(m);      
+
+      asyncChannel.send(m);
    }
-   
+
    /*
     * We put the transaction in the holding area
     */
@@ -967,82 +1008,82 @@
       synchronized (holdingArea)
       {
          holdingArea.put(id, tx);
-         
+
          if (trace) { log.trace(this.currentNodeId + " added transaction " + tx + " to holding area with id " + id); }
-      } 
+      }
    }
-   
+
    public void commitTransaction(TransactionId id) throws Throwable
    {
       if (trace) { log.trace(this.currentNodeId + " committing transaction " + id ); }
-      
+
       ClusterTransaction tx = null;
-        
+
       synchronized (holdingArea)
       {
-         tx = (ClusterTransaction)holdingArea.remove(id);                
+         tx = (ClusterTransaction)holdingArea.remove(id);
       }
-      
+
       if (tx == null)
       {
          throw new IllegalStateException("Cannot find transaction transaction id: " + id);
       }
-      
+
       tx.commit(this);
-      
+
       if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
-   
+
    public void rollbackTransaction(TransactionId id) throws Throwable
    {
       if (trace) { log.trace(this.currentNodeId + " rolling back transaction " + id ); }
-      
+
       ClusterTransaction tx = null;
-        
+
       synchronized (holdingArea)
       {
-         tx = (ClusterTransaction)holdingArea.remove(id);                
+         tx = (ClusterTransaction)holdingArea.remove(id);
       }
-      
+
       if (tx == null)
       {
          throw new IllegalStateException("Cannot find transaction transaction id: " + id);
       }
-      
+
       tx.rollback(this);
-      
+
       if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
-   
+
    /**
     * Check for any transactions that need to be committed or rolled back
     */
    public void check(Integer nodeId) throws Throwable
    {
       if (trace) { log.trace(this.currentNodeId + " checking for any stranded transactions for node " + nodeId); }
-      
+
       synchronized (holdingArea)
       {
          Iterator iter = holdingArea.entrySet().iterator();
-         
+
          List toRemove = new ArrayList();
-         
+
          while (iter.hasNext())
          {
             Map.Entry entry = (Map.Entry)iter.next();
-            
+
             TransactionId id = (TransactionId)entry.getKey();
-            
+
             if (id.getNodeId() == nodeId.intValue())
             {
                ClusterTransaction tx = (ClusterTransaction)entry.getValue();
-               
+
                if (trace) { log.trace("Found transaction " + tx + " in holding area"); }
-                
+
                boolean commit = tx.check(this);
-               
+
                if (trace) { log.trace(this.currentNodeId + " transaction " + tx + " will be committed?: " + commit); }
-               
+
                if (commit)
                {
                   tx.commit(this);
@@ -1051,56 +1092,56 @@
                {
                   tx.rollback(this);
                }
-               
+
                toRemove.add(id);
-               
+
                if (trace) { log.trace(this.currentNodeId + " resolved " + tx); }
             }
          }
-         
+
          //Remove the transactions from the holding area
-         
+
          iter = toRemove.iterator();
-         
+
          while (iter.hasNext())
          {
             TransactionId id = (TransactionId)iter.next();
-            
+
             holdingArea.remove(id);
          }
       }
       if (trace) { log.trace(this.currentNodeId + " check complete"); }
    }
-   
+
    public void sendQueueStats() throws Exception
    {
       if (!started)
       {
          return;
       }
-      
+
       lock.readLock().acquire();
- 
-      List statsList = null;      
-      
+
+      List statsList = null;
+
       try
-      {         
+      {
          Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
-         
+
          if (nameMap != null)
-         {            
+         {
             Iterator iter = nameMap.values().iterator();
-                     
+
             while (iter.hasNext())
             {
                Binding bb = (Binding)iter.next();
-               
+
                LocalClusteredQueue q = (LocalClusteredQueue)bb.getQueue();
-                             
+
                if (q.isActive())
-               {                                                      
+               {
                   QueueStats stats = q.getStats();
-                                              
+
                   if (stats != null)
                   {
                      if (statsList == null)
@@ -1109,9 +1150,9 @@
                      }
 
                      statsList.add(stats);
-                     
+
                      if (trace) { log.trace(this.currentNodeId + " adding stat for send " + stats); }
-                  } 
+                  }
                }
             }
          }
@@ -1120,64 +1161,64 @@
       {
          lock.readLock().release();
       }
-      
+
       if (statsList != null)
       {
          ClusterRequest req = new QueueStatsRequest(currentNodeId, statsList);
-         
+
          asyncSendRequest(req);
-         
+
          if (trace) { log.trace(this.currentNodeId + " Sent stats"); }
       }
    }
-   
+
    public void updateQueueStats(int nodeId, List statsList) throws Exception
    {
       lock.readLock().acquire();
 
       if (trace) { log.trace(this.currentNodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
-      
+
       try
-      {      
+      {
          if (nodeId == this.currentNodeId)
          {
             //Sanity check
             throw new IllegalStateException("Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!");
          }
-         
+
          Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-         
+
          if (nameMap == null)
          {
             //This is ok, the node might have left
             if (trace) { log.trace(this.currentNodeId + " cannot find node in name map, i guess the node might have left?"); }
          }
          else
-         {     
+         {
             Iterator iter = statsList.iterator();
-            
+
             while (iter.hasNext())
             {
                QueueStats st = (QueueStats)iter.next();
-               
+
                Binding bb = (Binding)nameMap.get(st.getQueueName());
-               
+
                if (bb == null)
                {
                   //I guess this is possible if the queue was unbound
                   if (trace) { log.trace(this.currentNodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
                }
                else
-               {                  
+               {
                   RemoteQueueStub stub = (RemoteQueueStub)bb.getQueue();
-                  
+
                   stub.setStats(st);
-                  
+
                   if (trace) { log.trace(this.currentNodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
-                  
+
                   ClusterRouter router = (ClusterRouter)routerMap.get(st.getQueueName());
-                  
-                  //Maybe the local queue now wants to pull message(s) from the remote queue given that the 
+
+                  //Maybe the local queue now wants to pull message(s) from the remote queue given that the
                   //stats for the remote queue have changed
                   LocalClusteredQueue localQueue = (LocalClusteredQueue)router.getLocalQueue();
 
@@ -1185,79 +1226,79 @@
                   {
                      //TODO - the call to getQueues is too slow since it creates a new list and adds the local queue!!!
                      RemoteQueueStub toQueue = (RemoteQueueStub)messagePullPolicy.chooseQueue(router.getQueues());
-                     
+
                      if (trace) { log.trace(this.currentNodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
-                                    
+
                      localQueue.setPullQueue(toQueue);
-                     
+
                      if (toQueue != null && localQueue.getRefCount() == 0)
                      {
-                        //We now trigger delivery - this may cause a pull event                                                
+                        //We now trigger delivery - this may cause a pull event
                         //We only do this if there are no refs in the local queue
-                        
+
                         localQueue.deliver(false);
-                                                                    
+
                         if (trace) { log.trace(this.currentNodeId + " triggered delivery for " + localQueue.getName()); }
                      }
-                  } 
+                  }
                }
-            }         
-         }         
+            }
+         }
       }
       finally
       {
-         lock.readLock().release();      
+         lock.readLock().release();
       }
-   }      
-   
+   }
+
    public boolean referenceExistsInStorage(long channelID, long messageID) throws Exception
    {
       return pm.referenceExists(channelID, messageID);
-   } 
-  
-   
+   }
+
+
    public void handleMessagePullResult(int remoteNodeId, long holdingTxId,
                                        String queueName, org.jboss.messaging.core.Message message) throws Throwable
    {
       if (trace) { log.trace(this.currentNodeId + " handling pull result " + message + " for " + queueName); }
-               
+
       Binding binding = getBindingForQueueName(queueName);
-      
+
       //The binding might be null if the queue was unbound
-      
+
       boolean handled = false;
-      
+
       if (!failHandleResult && binding != null)
-      {                     
+      {
          LocalClusteredQueue localQueue = (LocalClusteredQueue)binding.getQueue();
-              
+
          RemoteQueueStub remoteQueue = localQueue.getPullQueue();
-         
+
          if (remoteNodeId != remoteQueue.getNodeId())
          {
             //It might have changed since the request was sent
             Map bindings = (Map)nameMaps.get(new Integer(remoteNodeId));
-            
+
             if (bindings != null)
             {
                binding = (Binding)bindings.get(queueName);
-               
+
                if (binding != null)
-               {                     
-                 remoteQueue = (RemoteQueueStub)binding.getQueue();                              
+               {
+                 remoteQueue = (RemoteQueueStub)binding.getQueue();
                }
             }
          }
-         
+
          if (remoteQueue != null)
          {
             localQueue.handlePullMessagesResult(remoteQueue, message, holdingTxId,
                                                 failBeforeCommit, failAfterCommit);
-            
+
             handled = true;
-         }     
+         }
       }
-      
+
       if (!handled)
       {
          //If we didn't handle it for what ever reason, then we might have to send a rollback
@@ -1267,12 +1308,12 @@
          {
             //Only reliable messages will be in holding area
             this.asyncSendRequest(new RollbackPullRequest(this.currentNodeId, holdingTxId), remoteNodeId);
-            
+
             if (trace) { log.trace(this.currentNodeId + " send rollback pull request"); }
          }
-      }      
+      }
    }
-   
+
    public int getNodeId()
    {
       return currentNodeId;
@@ -1303,9 +1344,9 @@
       sb.append("]");
       return sb.toString();
    }
-                        
+
    // Public ------------------------------------------------------------------------------------------
-      
+
    //MUST ONLY be used for testing
    public int getNumberOfNodesInCluster()
    {
@@ -1318,7 +1359,7 @@
          return 0;
       }
    }
-   
+
    //MUST ONLY be used for testing
    public void setFail(boolean beforeCommit, boolean afterCommit, boolean handleResult)
    {
@@ -1326,7 +1367,7 @@
       this.failAfterCommit = afterCommit;
       this.failHandleResult = handleResult;
    }
-   
+
    //MUST ONLY be used for testing
    public Collection getHoldingTransactions()
    {
@@ -1361,24 +1402,24 @@
          }
       }
    }
-   
+
    /**
     * This method fails over all the queues from node <failedNodeId> onto this node
-    * It is triggered when a JGroups view change occurs due to a member leaving and 
+    * It is triggered when a JGroups view change occurs due to a member leaving and
     * it's determined the member didn't leave cleanly
-    * 
+    *
     * @param failedNodeId
     * @throws Exception
     */
    private void failOver(int failedNodeId) throws Exception
    {
       //Need to lock
-      lock.writeLock().acquire();            
+      lock.writeLock().acquire();
 
       try
       {
          log.info("Preparing failover against node " + failedNodeId);
-         
+
          /*
          We make sure a FailoverStatus object is put in the replicated data for the node
          The real failover node will always add this in.
@@ -1389,60 +1430,60 @@
          And clients may failover after that and need to know if they have the correct node.
          Since this is the first thing we do after detecting failover, it should be very quick that
          all nodes know, however there is still a chance that a client tries to failover before
-         the information is replicated.                  
+         the information is replicated.
          */
-         
+
          Map replicants = (Map)get(FAILED_OVER_FOR_KEY);
-         
+
          FailoverStatus status = (FailoverStatus)replicants.get(new Integer(currentNodeId));
-         
+
          if (status == null)
          {
-            status = new FailoverStatus();            
+            status = new FailoverStatus();
          }
-         
+
          status.startFailingOverForNode(failedNodeId);
-         
+
          put(FAILED_OVER_FOR_KEY, status);
-         
+
          log.info("Put into failed over map that starting failover");
-         
+
          //Get the map of queues for the failed node
-         
+
          Map subMaps = (Map)nameMaps.get(new Integer(failedNodeId));
          if (subMaps==null || subMaps.size()==0)
          {
             log.warn("Couldn't find any binding to failOver from serverId=" +failedNodeId);
             return;
          }
-                  
+
          //Compile a list of the queue names to remove
          //Note that any non durable bindings will already have been removed (in removeDataForNode()) when the
          //node leave was detected, so if there are any non durable bindings left here then
          //this is an error
-         
+
          //We iterate through twice to avoid ConcurrentModificationException
          ArrayList namesToRemove = new ArrayList();
          for (Iterator iterNames = subMaps.entrySet().iterator(); iterNames.hasNext();)
          {
             Map.Entry entry = (Map.Entry)iterNames.next();
-            
+
             Binding binding = (Binding )entry.getValue();
-            
+
             //Sanity check
             if (!binding.getQueue().isRecoverable())
             {
                throw new IllegalStateException("Find non recoverable queue in map, these should have been removed!");
             }
-            
+
             //Sanity check
             if (!binding.getQueue().isClustered())
             {
                throw new IllegalStateException("Queue is not clustered!: " + binding.getQueue().getName());
             }
-            
+
             ClusteredQueue queue = (ClusteredQueue) binding.getQueue();
-            
+
             //Sanity check
             if (queue.isLocal())
             {
@@ -1452,29 +1493,29 @@
          }
 
          log.info("Deleting " + namesToRemove.size() + " bindings from old node");
-         
+
          for (Iterator iterNames = namesToRemove.iterator(); iterNames.hasNext();)
          {
             Map.Entry entry = (Map.Entry)iterNames.next();
-                        
+
             Binding binding = (Binding)entry.getValue();
-            
+
             RemoteQueueStub stub = (RemoteQueueStub)binding.getQueue();
-            
+
             String queueName = (String)entry.getKey();
-                        
+
             //First the binding is removed from the in memory condition and name maps
             this.removeBinding(failedNodeId, queueName);
 
             //Then deleted from the database
             this.deleteBinding(failedNodeId, queueName);
-            
+
             log.info("deleted binding for " + queueName);
 
             //Then an unbind request is sent - this cause other nodes to also remove it from the in memory
             //condition and name maps
             UnbindRequest unbindRequest = new UnbindRequest(failedNodeId, queueName);
-            
+
             syncSendRequest(unbindRequest);
 
             //If there is already a queue registered with the same name, then we set a flag "failed" on the
@@ -1496,43 +1537,43 @@
             {
                log.info("There is already a queue with that name so adding to failed map");
             }
-           
+
             //Create a new binding
             Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
                                                     stub.getName(), stub.getChannelID(),
                                                     stub.getFilter(), stub.isRecoverable(), failed);
-            
+
             log.info("Created new binding");
 
             //Insert it into the database
             insertBinding(newBinding);
 
             LocalClusteredQueue clusteredQueue = (LocalClusteredQueue )newBinding.getQueue();
-            
+
             clusteredQueue.deactivate();
             clusteredQueue.load();
             clusteredQueue.activate();
-            
+
             log.info("Loaded queue");
-            
+
             //Add the new binding in memory
             addBinding(newBinding);
-            
+
             //Send a bind request so other nodes add it too
             sendBindRequest(binding.getCondition(), clusteredQueue,newBinding);
-            
+
             //FIXME there is a problem in the above code.
             //If the server crashes between deleting the binding from the database
             //and creating the new binding in the database, then the binding will be completely
             //lost from the database when the server is resurrected.
             //To remedy, both db operations need to be done in the same JBDC tx
          }
-         
+
          log.info("Server side fail over is now complete");
-         
+
          //TODO - should this be in a finally? I'm not sure
          status.finishFailingOver();
-         
+
          put(FAILED_OVER_FOR_KEY, status);
       }
       finally
@@ -1667,7 +1708,7 @@
       {
          Map.Entry entry = (Map.Entry) iter.next();
          Map subMap = (Map)entry.getValue();
-         boolean firstTime=true;
+
          for (Iterator subIterator = subMap.entrySet().iterator(); subIterator.hasNext();)
          {
             Map.Entry subValue = (Map.Entry) subIterator.next();
@@ -1802,25 +1843,25 @@
          routerMap.remove(queueName);
       }
    }
-   
+
    protected void loadBindings() throws Exception
    {
       if (trace) { log.trace(this + " loading bindings"); }
-      
+
       boolean isState = syncChannel.getState(null, stateTimeout);
 
       if (!isState)
       {
          //Must be first member in group or non clustered- we load the state ourself from the database
-         
+
          if (trace) { log.trace(this + " is the first member of group, so will load bindings from database"); }
-         
+
          super.loadBindings();
       }
       else
       {
          //The state will be set in due course via the MessageListener - we must wait until this happens
-         
+
          if (trace) { log.trace(this.currentNodeId + " Not first member of group- so waiting for state to arrive...."); }
 
       synchronized (setStateLock)
@@ -1842,7 +1883,7 @@
       if (nodeId == this.currentNodeId)
       {
          QueuedExecutor executor = (QueuedExecutor)pool.get();
-         
+
          queue = new LocalClusteredQueue(this, nodeId, queueName, channelId, ms, pm, true,
                   durable, executor, filter, tr);
       }
@@ -1850,12 +1891,12 @@
       {
          queue = new RemoteQueueStub(nodeId, queueName, channelId, durable, pm, filter);
       }
-      
+
       return new DefaultBinding(nodeId, condition, queue, failed);
    }
-   
+
    // Private ------------------------------------------------------------------------------------------
-   
+
    private boolean leaveMessageReceived(Integer nodeId) throws Exception
    {
       synchronized (leftSet)
@@ -1863,30 +1904,30 @@
          return leftSet.remove(nodeId);
       }
    }
-   
+
    /*
     * Removes all non durable binding data, and any local replicant data for the specified node.
     */
    private void removeDataForNode(Integer nodeToRemove) throws Exception
    {
       log.info("Node " + nodeToRemove + " requested to leave cluster");
-      
+
       lock.writeLock().acquire();
 
       try
-      {          
+      {
          Map nameMap = (Map)nameMaps.get(nodeToRemove);
 
          if (nameMap != null)
          {
             List toRemove = new ArrayList();
-            
+
             Iterator iter = nameMap.values().iterator();
-            
+
             while (iter.hasNext())
             {
                Binding binding = (Binding)iter.next();
-               
+
                if (!binding.getQueue().isRecoverable())
                {
                   //We only remove the non durable bindings - we still need to be able to handle
@@ -1894,16 +1935,16 @@
                   toRemove.add(binding);
                }
             }
-            
+
             iter = toRemove.iterator();
-            
+
             while (iter.hasNext())
             {
                Binding binding = (Binding)iter.next();
-               
+
                removeBinding(nodeToRemove.intValue(), binding.getQueue().getName());
             }
-         }         
+         }
       }
       finally
       {
@@ -1939,18 +1980,18 @@
     */
    private void notifyListeners(Serializable key, Map updatedReplicantMap, boolean added,
                                 int originatorNodeId)
-   { 
+   {
       synchronized (replicationListeners)
-      {         
+      {
          for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
          {
             ReplicationListener listener = (ReplicationListener)i.next();
-            
+
             listener.onReplicationChange(key, updatedReplicantMap, added, originatorNodeId);
          }
       }
-   } 
-   
+   }
+
    /*
     * Multicast a sync request
     */
@@ -1966,56 +2007,56 @@
 
       if (trace) { log.trace(this + " request sent OK"); }
    }
-   
+
    //DEBUG ONLY - remove this
-   private void dumpNodeIdAddressMap(Map map) throws Exception   
+   private void dumpNodeIdAddressMap(Map map) throws Exception
    {
       log.info("** DUMPING NODE ADDRESS MAPPING");
-      
+
       Iterator iter = map.entrySet().iterator();
-      
+
       while (iter.hasNext())
       {
          Map.Entry entry = (Map.Entry)iter.next();
-         
+
          Integer theNodeId = (Integer)entry.getKey();
-         
+
          PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
-         
+
          log.info("node id: " + theNodeId +" --------->(async:sync) " + info.getAsyncChannelAddress() + ":" + info.getSyncChannelAddress());
       }
-      
-      log.info("** END DUMP");      
+
+      log.info("** END DUMP");
    }
-   
 
+
    //TODO - this is a bit tortuous - needs optimising
    private Integer getNodeIdForSyncAddress(Address address) throws Exception
    {
       synchronized (replicatedData)
       {
          Map map = get(ADDRESS_INFO_KEY);
-         
+
          if (map == null)
          {
             throw new IllegalStateException("Cannot find node id -> address mapping");
          }
-         
+
          this.dumpNodeIdAddressMap(map);
-         
+
          Iterator iter = map.entrySet().iterator();
-         
+
          log.info("iterating, looking for " + address);
-         
+
          Integer theNodeId = null;
          while (iter.hasNext())
          {
             Map.Entry entry = (Map.Entry)iter.next();
-            
+
             PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
-            
+
             log.info("info synch channel address: " + info.getSyncChannelAddress());
-            
+
             if (info.getSyncChannelAddress().equals(address))
             {
                log.info("equal");
@@ -2030,15 +2071,15 @@
          return theNodeId;
       }
    }
-   
+
    private boolean knowAboutNodeId(int nodeId)
    {
       //The nodeid->Address info mapping is stored in the replicated data
-      
+
       synchronized (replicatedData)
-      {         
+      {
          Map nodeIdAddressMapping = (Map)replicatedData.get(ADDRESS_INFO_KEY);
-         
+
          if (nodeIdAddressMapping == null)
          {
             return false;
@@ -2046,7 +2087,7 @@
          else
          {
             Object obj = nodeIdAddressMapping.get(new Integer(nodeId));
-            
+
             return obj != null;
          }
       }
@@ -2060,25 +2101,25 @@
    {
       return this.currentNodeId == getFailoverNodeID(nodeId);
    }
-      
+
    private byte[] getStateAsBytes() throws Exception
    {
       List bindings = new ArrayList();
-      
+
       Iterator iter = nameMaps.values().iterator();
-      
+
       while (iter.hasNext())
       {
          Map map  = (Map)iter.next();
-         
+
          Iterator iter2 = map.values().iterator();
-         
+
          while (iter2.hasNext())
          {
             Binding binding = (Binding)iter2.next();
-                      
-            Queue queue = binding.getQueue();        
-            
+
+            Queue queue = binding.getQueue();
+
             BindingInfo info = new BindingInfo(binding.getNodeId(), queue.getName(),
                                                binding.getCondition(),
                                                queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
@@ -2088,130 +2129,130 @@
             bindings.add(info);
          }
       }
-      
+
       //Need to copy
-      
+
       Map copy;
-      
+
       synchronized (replicatedData)
       {
          copy = copyReplicatedData(replicatedData);
       }
-      
+
       SharedState state = new SharedState(bindings, copy);
-      
+
       return StreamUtils.toBytes(state);
    }
-   
+
    private void processStateBytes(byte[] bytes) throws Exception
    {
       if (trace) { log.trace(this + " received state from group"); }
-      
+
       SharedState state = new SharedState();
-      
+
       StreamUtils.fromBytes(state, bytes);
-      
+
       if (trace) { log.trace(this + " received " + state.getBindings().size() + " bindings and map " + state.getReplicatedData()); }
-      
+
       nameMaps.clear();
-      
+
       conditionMap.clear();
-                 
+
       List bindings = state.getBindings();
-      
+
       Iterator iter = bindings.iterator();
-      
+
       while (iter.hasNext())
       {
          BindingInfo info = (BindingInfo)iter.next();
-         
+
          Binding binding = this.createBinding(info.getNodeId(), info.getCondition(), info.getQueueName(), info.getChannelId(),
                                               info.getFilterString(), info.isDurable(),info.isFailed());
-         
+
          if (binding.getNodeId() == this.currentNodeId)
          {
             //We deactivate if this is one of our own bindings - it can only
             //be one of our own durable bindings - and since state is retrieved before we are fully started
             //then the sub hasn't been deployed so must be deactivated
-            
-            binding.getQueue().deactivate();            
+
+            binding.getQueue().deactivate();
          }
-            
-         addBinding(binding);         
+
+         addBinding(binding);
       }
-      
+
       //Update the replicated data
-      
+
       synchronized (replicatedData)
       {
          replicatedData = copyReplicatedData(state.getReplicatedData());
       }
    }
-   
+
    private Map copyReplicatedData(Map toCopy)
    {
       Map copy = new HashMap();
-      
+
       Iterator iter = toCopy.entrySet().iterator();
-      
+
       while (iter.hasNext())
       {
          Map.Entry entry = (Map.Entry)iter.next();
-         
+
          Serializable key = (Serializable)entry.getKey();
-         
+
          Map replicants = (Map)entry.getValue();
-         
+
          Map m = new LinkedHashMap();
-         
+
          m.putAll(replicants);
-         
+
          copy.put(key, m);
       }
-      
+
       return copy;
    }
-   
 
+
    private byte[] writeRequest(ClusterRequest request) throws Exception
    {
       ByteArrayOutputStream baos = new ByteArrayOutputStream(2048);
-      
+
       DataOutputStream daos = new DataOutputStream(baos);
-      
+
       ClusterRequest.writeToStream(daos, request);
-            
+
       daos.flush();
-      
+
       return baos.toByteArray();
    }
-   
+
    private ClusterRequest readRequest(byte[] bytes) throws Exception
    {
       ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
-      
+
       DataInputStream dais = new DataInputStream(bais);
-      
+
       ClusterRequest request = ClusterRequest.createFromStream(dais);
-      
+
       dais.close();
-      
-      return request;            
+
+      return request;
    }
-   
+
    private Address getAddressForNodeId(int nodeId, boolean sync) throws Exception
-   {  
+   {
       synchronized (replicatedData)
       {
          Map map = this.get(ADDRESS_INFO_KEY);
-         
+
          if (map == null)
          {
             throw new IllegalStateException("Cannot find address mapping");
          }
-         
+
          PostOfficeAddressInfo info = (PostOfficeAddressInfo)map.get(new Integer(nodeId));
-         
+
          if (info != null)
          {
             if (sync)
@@ -2227,11 +2268,11 @@
          {
             return null;
          }
-      }      
+      }
    }
-   
-   
 
+
+
    /*
     * A new node has joined the group
     */
@@ -2240,7 +2281,7 @@
       if (trace) { log.trace(this + ": " + address + " joined"); }
 
       log.info(this.currentNodeId + " Node with address: " + address + " joined");
-      
+
       //Currently does nothing
    }
 
@@ -2250,7 +2291,7 @@
    private void nodeLeft(Address address) throws Throwable
    {
       if (trace) { log.trace(this + ": " + address + " left"); }
-      
+
       log.info(this.currentNodeId + " Node with address: " + address + " left");
 
       Integer theNodeId = getNodeIdForSyncAddress(address);
@@ -2269,9 +2310,9 @@
 
       //Need to evaluate this before we regenerate the failover map
       boolean isFailover = isFailoverNodeForNode(theNodeId.intValue());
-      
+
       log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
-      
+
       log.info("Crashed: " + crashed);
 
       //Remove any replicant data and non durable bindings for the node - again we need to do this
@@ -2289,17 +2330,17 @@
          failOver(theNodeId.intValue());
       }
    }
-         
 
+
    // Inner classes -------------------------------------------------------------------
-    
+
    /*
     * This class is used to manage state on the control channel
     */
    private class ControlMessageListener implements MessageListener
    {
       public byte[] getState()
-      {     
+      {
          try
          {
             lock.writeLock().acquire();
@@ -2320,24 +2361,24 @@
             IllegalStateException e2 = new IllegalStateException(e.getMessage());
             e2.setStackTrace(e.getStackTrace());
             throw e2;
-         }     
+         }
          finally
          {
             lock.writeLock().release();
          }
       }
-      
+
       public void receive(Message message)
-      {         
+      {
       }
-      
+
       public void setState(byte[] bytes)
-      { 
+      {
          if (bytes != null)
-         {            
+         {
             try
             {
-               lock.writeLock().acquire();         
+               lock.writeLock().acquire();
             }
             catch (InterruptedException e)
             {
@@ -2361,15 +2402,15 @@
                lock.writeLock().release();
             }
          }
-               
+
          synchronized (setStateLock)
          {
             stateSet = true;
             setStateLock.notify();
          }
-      }      
+      }
    }
-   
+
    /*
     * We use this class so we notice when members leave the group
     */
@@ -2384,7 +2425,7 @@
       {
          //NOOP
       }
-      
+
       public void viewAccepted(View newView)
       {
          //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
@@ -2393,7 +2434,7 @@
                   + DefaultClusteredPostOffice.this.getOfficeName());
 
          // JGroups will make sure this method is never called by more than one thread concurrently
-         
+
          View oldView = currentView;
          currentView = newView;
 
@@ -2411,10 +2452,10 @@
       }
 
       public byte[] getState()
-      {        
+      {
          //NOOP
          return null;
-      }     
+      }
    }
 
 
@@ -2425,37 +2466,37 @@
    private class DataReceiver implements Receiver
    {
       public void block()
-      {   
+      {
          //NOOP
       }
 
       public void suspect(Address address)
-      { 
+      {
          //NOOP
       }
 
       public void viewAccepted(View view)
-      { 
+      {
          //NOOP
       }
 
       public byte[] getState()
-      {         
+      {
          //NOOP
          return null;
       }
-      
+
       public void receive(Message message)
       {
          if (trace) { log.trace(currentNodeId + " received message " + message + " on async channel"); }
-         
+
          try
          {
             byte[] bytes = message.getBuffer();
-            
+
             ClusterRequest request = readRequest(bytes);
-            
-            request.execute(DefaultClusteredPostOffice.this);            
+
+            request.execute(DefaultClusteredPostOffice.this);
          }
          catch (Throwable e)
          {
@@ -2463,13 +2504,13 @@
             IllegalStateException e2 = new IllegalStateException(e.getMessage());
             e2.setStackTrace(e.getStackTrace());
             throw e2;
-         }         
+         }
       }
-      
+
       public void setState(byte[] bytes)
       {
-         //NOOP         
-      }      
+         //NOOP
+      }
    }
 
    /*
@@ -2481,11 +2522,11 @@
       {
          if (trace) { log.info(currentNodeId + " received message " + message + " on sync channel"); }
          try
-         {   
+         {
             byte[] bytes = message.getBuffer();
-            
+
             ClusterRequest request = readRequest(bytes);
-            
+
             return request.execute(DefaultClusteredPostOffice.this);
          }
          catch (Throwable e)
@@ -2494,14 +2535,14 @@
             IllegalStateException e2 = new IllegalStateException(e.getMessage());
             e2.setStackTrace(e.getStackTrace());
             throw e2;
-         }         
-      }      
+         }
+      }
    }
-   
+
    /*
     * We use this class to respond to node address mappings being added or removed from the cluster
     * and then recalculate the node->failover node mapping
-    * 
+    *
     */
    private class NodeAddressMapListener implements ReplicationListener
    {
@@ -2512,22 +2553,22 @@
          if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
          {
             log.info(currentNodeId + " got node address change");
-            
+
             try
             {
                //DEBUG only
                dumpNodeIdAddressMap(updatedReplicantMap);
             }
             catch (Exception ignore)
-            {               
+            {
             }
-            
+
             //A node-address mapping has been added/removed from global state-
             //We need to update the failover map
             generateFailoverMap(updatedReplicantMap);
          }
       }
-      
+
       private void generateFailoverMap(Map nodeAddressMap)
       {
          failoverMap = failoverMapper.generateMapping(new ArrayList(nodeAddressMap.keySet()));

Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -0,0 +1,24 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.messaging.core.plugin.postoffice.cluster;
+
+import java.util.Set;
+
+/**
+ * Group management interface.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public interface Peer
+{
+   /**
+    * Returns a set of nodeIDs (integers) representing the IDs of cluster's nodes.
+    */
+   Set getNodeIDView();
+}

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -0,0 +1,69 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+import javax.management.ObjectName;
+import java.util.Set;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class GroupManagementTest extends MessagingTestCase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public GroupManagementTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testOneNodeCluster() throws Exception
+   {
+
+      ServerManagement.start("all", 0);
+
+      ObjectName on = new ObjectName("jboss.messaging:service=QueuePostOffice");
+      Set view = (Set)ServerManagement.getAttribute(on, "NodeIDView");
+
+      assertEquals(1, view.size());
+      assertTrue(view.contains(new Integer(0)));
+
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -179,9 +179,8 @@
       log.info("Server 1 ID: " + serverID1);
       log.info("Server 2 ID: " + serverID2);
 
-//      assertTrue(serverID0 != serverID1);
-//
-//      assertTrue(serverID1 != serverID2);
+      assertTrue(serverID0 != serverID1);
+      assertTrue(serverID1 != serverID2);
    }
 
    protected void drainQueues() throws Exception

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-10 22:06:23 UTC (rev 1754)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-10 22:16:12 UTC (rev 1755)
@@ -265,7 +265,7 @@
    {
       try
       {
-         log.info(" Server peer ID ........... " + serverPeerID + " clustered: " + clustered);
+         log.info(" Server peer ID ........... " + serverPeerID);
 
          log.debug("creating ServerPeer instance");
 



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 17:52:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 17:52:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r58957 - in
	projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers:
	. metadata/test structure/jar/test
Message-ID: <E1GtXWu-0003q9-NC@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 17:52:16 -0500 (Sun, 10 Dec 2006)
New Revision: 58957

Modified:
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/metadata/test/MetaDataUnitTestCase.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java
Log:
Update the expected urls for the changes to the vfsurl changes

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java	2006-12-10 01:12:45 UTC (rev 58956)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java	2006-12-10 22:52:16 UTC (rev 58957)
@@ -95,8 +95,20 @@
       URL url = getResource(path);
       return url.toString();
    }
-   
    /**
+    * Get a vfs url string from a path
+    * 
+    * @param path
+    * @return
+    * @throws Exception
+    */
+   protected String getVfsURL(String path) throws Exception
+   {
+      URL url = getResource(path);
+      return "vfs"+url.toString();
+   }
+
+   /**
     * Get a jar url string from a path
     * 
     * @param path the path

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/metadata/test/MetaDataUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/metadata/test/MetaDataUnitTestCase.java	2006-12-10 01:12:45 UTC (rev 58956)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/metadata/test/MetaDataUnitTestCase.java	2006-12-10 22:52:16 UTC (rev 58957)
@@ -53,7 +53,7 @@
    public void testExactMatchTopLevel() throws Exception
    {
       DeploymentContext context = createDeploymentContext("/metadata", "toplevel/exact/jboss-service.xml");
-      String expected = getURL("/metadata/toplevel/exact/jboss-service.xml");
+      String expected = getVfsURL("/metadata/toplevel/exact/jboss-service.xml");
       assertMetaDataMatch(context, expected, "jboss-service.xml");
    }
 
@@ -67,7 +67,7 @@
    {
       DeploymentContext context = createDeploymentContext("/metadata", "toplevel/partial/mydb-ds.xml");
       Set<String> expected = new HashSet<String>();
-      expected.add(getURL("/metadata/toplevel/partial/mydb-ds.xml"));
+      expected.add(getVfsURL("/metadata/toplevel/partial/mydb-ds.xml"));
       assertMetaDataMatch(context, expected, null, "-ds.xml");
    }
 
@@ -81,7 +81,7 @@
    {
       DeploymentContext context = createDeploymentContext("/metadata", "toplevel/metadata.jar");
       context.setMetaDataPath("META-INF");
-      String expected = getURL("/metadata/toplevel/metadata.jar/META-INF/jboss-service.xml");
+      String expected = getVfsURL("/metadata/toplevel/metadata.jar/META-INF/jboss-service.xml");
       assertMetaDataMatch(context, expected, "jboss-service.xml");
    }
 
@@ -111,8 +111,8 @@
       DeploymentContext context = createDeploymentContext("/metadata", "toplevel/metadata.jar");
       context.setMetaDataPath("META-INF");
       Set<String> expected = new HashSet<String>();
-      expected.add(getURL("/metadata/toplevel/metadata.jar/META-INF/1-ds.xml"));
-      expected.add(getURL("/metadata/toplevel/metadata.jar/META-INF/2-ds.xml"));
+      expected.add(getVfsURL("/metadata/toplevel/metadata.jar/META-INF/1-ds.xml"));
+      expected.add(getVfsURL("/metadata/toplevel/metadata.jar/META-INF/2-ds.xml"));
       assertMetaDataMatch(context, expected, null, "-ds.xml");
    }
 
@@ -142,9 +142,9 @@
       DeploymentContext context = createDeploymentContext("/metadata", "toplevel/metadata.jar");
       context.setMetaDataPath("META-INF");
       Set<String> expected = new HashSet<String>();
-      expected.add(getURL("/metadata/toplevel/metadata.jar/META-INF/jboss-service.xml"));
-      expected.add(getURL("/metadata/toplevel/metadata.jar/META-INF/1-ds.xml"));
-      expected.add(getURL("/metadata/toplevel/metadata.jar/META-INF/2-ds.xml"));
+      expected.add(getVfsURL("/metadata/toplevel/metadata.jar/META-INF/jboss-service.xml"));
+      expected.add(getVfsURL("/metadata/toplevel/metadata.jar/META-INF/1-ds.xml"));
+      expected.add(getVfsURL("/metadata/toplevel/metadata.jar/META-INF/2-ds.xml"));
       assertMetaDataMatch(context, expected, "jboss-service.xml", "-ds.xml");
    }
 

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java	2006-12-10 01:12:45 UTC (rev 58956)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/jar/test/JARStructureUnitTestCase.java	2006-12-10 22:52:16 UTC (rev 58957)
@@ -154,8 +154,8 @@
       expected.put(getJarURL("/structure/jar/indirectory/archive.jar"), true);
       expected.put(getJarURL("/structure/jar/indirectory/archive.zip"), true);
       */
-      expected.put(getURL("/structure/jar/indirectory/archive.jar"), true);
-      expected.put(getURL("/structure/jar/indirectory/archive.zip"), true);
+      expected.put(getVfsURL("/structure/jar/indirectory/archive.jar"), true);
+      expected.put(getVfsURL("/structure/jar/indirectory/archive.zip"), true);
       assertContexts(expected, context.getChildren());
       
       assertCandidatesValid(context);
@@ -180,7 +180,7 @@
       
       // Test it got all the candidates
       Map<String, Boolean> expected = new HashMap<String, Boolean>();
-      expected.put(getURL("/structure/jar/subdirisajar/sub.jar/"), true);
+      expected.put(getVfsURL("/structure/jar/subdirisajar/sub.jar/"), true);
       assertContexts(expected, context.getChildren());
       
       assertCandidatesValid(context);



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 17:54:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 17:54:05 -0500
Subject: [jboss-cvs] JBossAS SVN: r58958 -
	projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test
Message-ID: <E1GtXYb-0003rL-A4@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 17:54:03 -0500 (Sun, 10 Dec 2006)
New Revision: 58958

Modified:
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
Log:
Add a testDirURIs

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-10 22:52:16 UTC (rev 58957)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-10 22:54:03 UTC (rev 58958)
@@ -897,6 +897,36 @@
    }
 
    /**
+    * Test that the URI of a VFS corresponding to a directory ends in '/' so that
+    * URIs created relative to it are under the directory. This requires that
+    * build-test.xml artifacts exist.
+    * 
+    * @throws Exception
+    */
+   public void testDirURIs() throws Exception
+   {
+      URL rootURL = getResource("/vfs/test");
+      VFS vfs = VFS.getVFS(rootURL);
+
+      VirtualFile outerJar = vfs.findChild("unpacked-outer.jar");
+      URI outerURI = outerJar.toURI();
+      log.debug("outerURI: "+outerURI);
+      assertTrue(outerURI+" ends in '/'", outerURI.getPath().endsWith("/"));
+      // Validate that jar1 is under unpacked-outer.jar
+      URI jar1URI = new URI(outerURI+"jar1.jar");
+      log.debug("jar1URI: "+jar1URI+", path="+jar1URI.getPath());
+      assertTrue("jar1URI path ends in unpacked-outer.jar/jar1.jar!/",
+            jar1URI.getPath().endsWith("unpacked-outer.jar/jar1.jar"));
+      VirtualFile jar1 = outerJar.findChild("jar1.jar");
+      assertEquals(jar1URI, jar1.toURI());
+
+      VirtualFile packedJar = vfs.findChild("jar1.jar");
+      jar1URI = packedJar.findChild("org/jboss/test/vfs/support").toURI();
+      assertTrue("Jar directory entry URLs must end in /: " + jar1URI.toString(),
+            jar1URI.toString().endsWith("/"));
+   }
+
+   /**
     * Test copying a jar
     * 
     * @throws Exception



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 17:54:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 17:54:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r58959 -
	projects/microcontainer/trunk/container/src/main/org/jboss/virtual
Message-ID: <E1GtXZ0-0003re-7J@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 17:54:28 -0500 (Sun, 10 Dec 2006)
New Revision: 58959

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
Log:
Drop the unused import

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-10 22:54:03 UTC (rev 58958)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-10 22:54:28 UTC (rev 58959)
@@ -24,12 +24,10 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.Serializable;
-import java.io.File;
 import java.net.MalformedURLException;
 import java.net.URI;
 import java.net.URISyntaxException;
 import java.net.URL;
-import java.net.URLEncoder;
 import java.util.Collections;
 import java.util.List;
 import java.util.Set;



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 18:03:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 18:03:34 -0500
Subject: [jboss-cvs] JBossAS SVN: r58960 -
	branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx
Message-ID: <E1GtXhm-0004EP-F7@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 18:03:32 -0500 (Sun, 10 Dec 2006)
New Revision: 58960

Modified:
   branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/UserTransactionImpl.java
Log:
Fix the log level and add the missing serialVersionUID

Modified: branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/UserTransactionImpl.java
===================================================================
--- branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/UserTransactionImpl.java	2006-12-10 22:54:28 UTC (rev 58959)
+++ branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/tx/UserTransactionImpl.java	2006-12-10 23:03:32 UTC (rev 58960)
@@ -42,6 +42,7 @@
  */
 public final class UserTransactionImpl implements UserTransaction, java.io.Externalizable
 {
+   private static final long serialVersionUID = 2403204397187452430L;
    protected static Logger log = Logger.getLogger(UserTransactionImpl.class);
 
    /**
@@ -52,8 +53,8 @@
 
    public UserTransactionImpl()
    {
-      if (log.isDebugEnabled())
-         log.debug("new UserTx: " + this);
+      if (log.isTraceEnabled())
+         log.trace("new UserTx: " + this);
       this.tm = TxUtil.getTransactionManager();
    }
 
@@ -64,8 +65,8 @@
       tm.begin();
 
       Transaction tx = tm.getTransaction();
-      if (log.isDebugEnabled())
-         log.debug("UserTx begin: " + tx);
+      if (log.isTraceEnabled())
+         log.trace("UserTx begin: " + tx);
 
    }
 
@@ -74,8 +75,8 @@
                   SecurityException, IllegalStateException, SystemException
    {
       Transaction tx = tm.getTransaction();
-      if (log.isDebugEnabled())
-         log.debug("UserTx commit: " + tx);
+      if (log.isTraceEnabled())
+         log.trace("UserTx commit: " + tx);
 
       tm.commit();
    }
@@ -84,8 +85,8 @@
            throws IllegalStateException, SecurityException, SystemException
    {
       Transaction tx = tm.getTransaction();
-      if (log.isDebugEnabled())
-         log.debug("UserTx rollback: " + tx);
+      if (log.isTraceEnabled())
+         log.trace("UserTx rollback: " + tx);
       tm.rollback();
    }
 
@@ -93,8 +94,8 @@
            throws IllegalStateException, SystemException
    {
       Transaction tx = tm.getTransaction();
-      if (log.isDebugEnabled())
-         log.debug("UserTx setRollbackOnly: " + tx);
+      if (log.isTraceEnabled())
+         log.trace("UserTx setRollbackOnly: " + tx);
 
       tm.setRollbackOnly();
    }



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 18:21:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 18:21:07 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58961 - trunk/ejb3
Message-ID: <E1GtXyl-0004YS-1J@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 18:21:05 -0500 (Sun, 10 Dec 2006)
New Revision: 58961

Modified:
   trunk/ejb3/.classpath
Log:
Use the thirdparty source

Modified: trunk/ejb3/.classpath
===================================================================
--- trunk/ejb3/.classpath	2006-12-10 23:03:32 UTC (rev 58960)
+++ trunk/ejb3/.classpath	2006-12-10 23:21:05 UTC (rev 58961)
@@ -2,7 +2,7 @@
 <classpath>
 	<classpathentry kind="src" path="src/main"/>
 	<classpathentry kind="src" path="docs/tutorial/ssl/src"/>
-	<classpathentry excluding="org/jboss/ejb3/test/clusteredentity/|org/jboss/ejb3/test/clusteredsession/" output="output/eclipse-test-classes" kind="src" path="src/test"/>
+	<classpathentry excluding="org/jboss/ejb3/test/clusteredentity/|org/jboss/ejb3/test/clusteredsession/" kind="src" output="output/eclipse-test-classes" path="src/test"/>
 	<classpathentry kind="src" path="docs/embedded-tutorial/advanced-deployment/archive/src"/>
 	<classpathentry kind="src" path="docs/embedded-tutorial/advanced-deployment/archive-by-resource/src"/>
 	<classpathentry kind="src" path="docs/embedded-tutorial/advanced-deployment/deploy-dir/src"/>
@@ -86,11 +86,12 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/iiop"/>
 	<classpathentry kind="lib" path="/thirdparty/jacorb/lib/jacorb.jar"/>
-	<classpathentry sourcepath="/thirdparty/jboss/test/lib/jboss-test-src.zip" kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar" sourcepath="/thirdparty/jboss/test/lib/jboss-test-src.zip"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/security/lib/jbosssx.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/security-spi/lib/jboss-security-spi.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/system-jmx"/>
-	<classpathentry sourcepath="/home/tdiesler/svn/jbossmc/trunk/deployers/src/main" kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers.jar" sourcepath="/home/tdiesler/svn/jbossmc/trunk/deployers/src/main"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/aop/lib/jboss-aop-jdk50.jar"/>
+	<classpathentry kind="lib" path="src/resources/test"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 18:43:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 18:43:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r58962 -
	trunk/testsuite/src/main/org/jboss/test/client/test
Message-ID: <E1GtYKd-0004r0-4N@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 18:43:41 -0500 (Sun, 10 Dec 2006)
New Revision: 58962

Modified:
   trunk/testsuite/src/main/org/jboss/test/client/test/AppClientUnitTestCase.java
Log:
Correct the test of the anotherQueue2 value

Modified: trunk/testsuite/src/main/org/jboss/test/client/test/AppClientUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/client/test/AppClientUnitTestCase.java	2006-12-10 23:21:05 UTC (rev 58961)
+++ trunk/testsuite/src/main/org/jboss/test/client/test/AppClientUnitTestCase.java	2006-12-10 23:43:41 UTC (rev 58962)
@@ -83,7 +83,7 @@
       assertTrue("jms/anotherQueue isa Queue", anotherQueue != null);
 
       Queue anotherQueue2 = (Queue) enc.lookup("jms/anotherQueue2");
-      assertTrue("jms/anotherQueue2 isa Queue", anotherQueue != null);
+      assertTrue("jms/anotherQueue2 isa Queue", anotherQueue2 != null);
    }
 
    /** Test access to EJBs located through the java:comp/env context



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 19:17:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 19:17:26 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1756 -
	branches/Branch_Client_Failover_Experiment/tests/lib
Message-ID: <E1GtYrG-0005ZA-Co@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-10 19:17:21 -0500 (Sun, 10 Dec 2006)
New Revision: 1756

Modified:
   branches/Branch_Client_Failover_Experiment/tests/lib/README
   branches/Branch_Client_Failover_Experiment/tests/lib/jboss-common-jdbc-wrapper.jar
   branches/Branch_Client_Failover_Experiment/tests/lib/jboss-jca.jar
   branches/Branch_Client_Failover_Experiment/tests/lib/jboss-local-jdbc.jar
Log:
upgraded testing dependecies to 4.0.4.GA

Modified: branches/Branch_Client_Failover_Experiment/tests/lib/README
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/lib/README	2006-12-10 22:16:12 UTC (rev 1755)
+++ branches/Branch_Client_Failover_Experiment/tests/lib/README	2006-12-11 00:17:21 UTC (rev 1756)
@@ -1 +1,6 @@
-jms-ra.jar      JBoss 4.0.4.GA
\ No newline at end of file
+jms-ra.jar                     JBoss 4.0.4.GA
+jboss-jca.jar                  JBoss 4.0.4.GA
+jboss-common-jdbc-wrapper.jar  JBoss 4.0.4.GA
+jboss-local-jdbc.jar           JBoss 4.0.4.GA 
+
+

Modified: branches/Branch_Client_Failover_Experiment/tests/lib/jboss-common-jdbc-wrapper.jar
===================================================================
(Binary files differ)

Modified: branches/Branch_Client_Failover_Experiment/tests/lib/jboss-jca.jar
===================================================================
(Binary files differ)

Modified: branches/Branch_Client_Failover_Experiment/tests/lib/jboss-local-jdbc.jar
===================================================================
(Binary files differ)



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 19:18:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 19:18:01 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1757 - in
	branches/Branch_Client_Failover_Experiment: . tools/lib
Message-ID: <E1GtYrp-0005ZX-0B@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-10 19:17:58 -0500 (Sun, 10 Dec 2006)
New Revision: 1757

Modified:
   branches/Branch_Client_Failover_Experiment/build-messaging.xml
   branches/Branch_Client_Failover_Experiment/build-thirdparty.xml
   branches/Branch_Client_Failover_Experiment/tools/lib/jbossbuild.jar
Log:
upgraded jboss-common from snapshot to 2.0.2.GA

Modified: branches/Branch_Client_Failover_Experiment/build-messaging.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/build-messaging.xml	2006-12-11 00:17:21 UTC (rev 1756)
+++ branches/Branch_Client_Failover_Experiment/build-messaging.xml	2006-12-11 00:17:58 UTC (rev 1757)
@@ -149,7 +149,9 @@
               present in ./lib, it will take precedence over the corresponding repository instance.
     -->
    <path id="jboss.dependencies.classpath">
-      <path refid="jboss.common.classpath"/>
+      <path refid="jboss.common.core.classpath"/>
+      <path refid="jboss.common.logging.log4j.classpath"/>
+      <path refid="jboss.common.logging.spi.classpath"/>
       <path refid="jboss.aop.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
@@ -464,7 +466,7 @@
            We need org/jboss/util/collection.SoftValueHashMap which was moved. See
            http://jira.jboss.org/jira/browse/JBMESSAGING-281 for more details.
       -->
-      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.lib}/jboss-common.jar" >
+      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.core.lib}/jboss-common-core.jar" >
          <patternset>
             <include name="org/jboss/util/collection/SoftValueHashMap*.class"/>
             <!--
@@ -485,7 +487,7 @@
       <!--
            I also need org.jboss.util.stream.*
       -->
-      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.lib}/jboss-common.jar">
+      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.core.lib}/jboss-common-core.jar">
          <patternset>
             <include name="org/jboss/util/stream/**"/>
          </patternset>
@@ -570,7 +572,9 @@
       <unjar dest="${project.output}/jboss-messaging-client" src="${javassist.javassist.lib}/javassist.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${trove.trove.lib}/trove.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${build.scoped-sar}/jboss-common-softvaluehashmap.jar"/>
-      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.lib}/jboss-common-client.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.core.lib}/jboss-common-core.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.logging.log4j.lib}/jboss-logging-log4j.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.logging.spi.lib}/jboss-logging-spi.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.j2ee.lib}/jboss-j2ee.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.j2se.lib}/jboss-j2se.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.naming.lib}/jnp-client.jar"/>

Modified: branches/Branch_Client_Failover_Experiment/build-thirdparty.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/build-thirdparty.xml	2006-12-11 00:17:21 UTC (rev 1756)
+++ branches/Branch_Client_Failover_Experiment/build-thirdparty.xml	2006-12-11 00:17:58 UTC (rev 1757)
@@ -87,13 +87,15 @@
       <componentref name="javassist" version="3.2.0.GA"/>
       <componentref name="jgroups" version="2.4"/>
       <componentref name="trove" version="1.0.2"/>
-      <componentref name="jboss/common" version="snapshot"/>
+      <componentref name="jboss/common-core" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
       <componentref name="jboss/aop" version="1.5.0.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
       <componentref name="jboss/remoting" version="2.2.0.Alpha2"/>
 
       <!-- Need this otherwise project doesn't build in Eclipse -->
-      <componentref name="apache-logging" version="1.0.5.GA-jboss"/>
+      <componentref name="apache-logging" version="1.0.4.1jboss"/>
 
       <!--
            Dependencies required to test the project.

Modified: branches/Branch_Client_Failover_Experiment/tools/lib/jbossbuild.jar
===================================================================
(Binary files differ)



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 19:20:02 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 19:20:02 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1758 - in
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging:
	jms/clustering tools/jmx/rmi
Message-ID: <E1GtYtm-0005aJ-Fc@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-10 19:19:59 -0500 (Sun, 10 Dec 2006)
New Revision: 1758

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
cleaned the testing interfaces a little bit, based on the new Peer.getNodeIDView()

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 00:17:58 UTC (rev 1757)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 00:19:59 UTC (rev 1758)
@@ -9,7 +9,6 @@
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
-import javax.management.ObjectName;
 import java.util.Set;
 
 /**
@@ -37,17 +36,56 @@
 
    public void testOneNodeCluster() throws Exception
    {
+      try
+      {
+         ServerManagement.start("all", 0);
 
-      ServerManagement.start("all", 0);
+         Set view = ServerManagement.getServer(0).getNodeIDView();
 
-      ObjectName on = new ObjectName("jboss.messaging:service=QueuePostOffice");
-      Set view = (Set)ServerManagement.getAttribute(on, "NodeIDView");
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(0)));
+      }
+      finally
+      {
+         ServerManagement.stop(0, false);
+      }
+   }
 
-      assertEquals(1, view.size());
-      assertTrue(view.contains(new Integer(0)));
+   public void testTwoNodesCluster() throws Exception
+   {
+      try
+      {
+         ServerManagement.start("all", 0);
 
+         Set view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(0)));
+
+         ServerManagement.start("all", 1);
+
+         view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+         log.info("testTwoNodesCluster sucessful");
+      }
+      finally
+      {
+         ServerManagement.stop(1, false);
+         ServerManagement.stop(0, false);
+      }
    }
 
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 00:17:58 UTC (rev 1757)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 00:19:59 UTC (rev 1758)
@@ -23,6 +23,7 @@
 package org.jboss.test.messaging.jms.clustering;
 
 import java.util.Map;
+import java.util.Set;
 
 import javax.jms.Connection;
 import javax.jms.MessageConsumer;
@@ -35,7 +36,6 @@
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
@@ -424,9 +424,10 @@
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
       
-      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-      
       ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
       
       ClientConnectionFactoryDelegate cf1 = delegates[0];

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 00:17:58 UTC (rev 1757)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 00:19:59 UTC (rev 1758)
@@ -38,7 +38,6 @@
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
-import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
@@ -857,14 +856,9 @@
       return sc.getUserTransaction();
    }
 
-
-   public int getNumberOfNodesOnCluster() throws Exception
+   public Set getNodeIDView() throws Exception
    {
-      log.info("getNumberOfNodesOnCluster being called:: sc=" + sc);
-      DefaultClusteredPostOffice postOffice = (DefaultClusteredPostOffice)
-            sc.getAttribute(queuePostOfficeObjectName, "Instance");
-      
-      return postOffice.getNumberOfNodesInCluster();
+      return (Set)sc.getAttribute(queuePostOfficeObjectName, "NodeIDView");
    }
 
    // Public --------------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 00:17:58 UTC (rev 1757)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 00:19:59 UTC (rev 1758)
@@ -57,14 +57,13 @@
    protected RemoteTestServer server;
 
    private RMINamingDelegate namingDelegate;
-   private int index;
 
 
    public static final String RMI_SERVER_PREFIX = "messaging_rmi_server_";
    public static final String NAMING_SERVER_PREFIX = "naming_rmi_server_";
 
    private static Registry registry;
-   
+
    public static void main(String[] args) throws Exception
    {
       log.debug("initializing RMI runtime");
@@ -137,7 +136,6 @@
 
    public RMITestServer(int index) throws Exception
    {
-      this.index = index;
       namingDelegate = new RMINamingDelegate(index);
       server = new RemoteTestServer(index);
    }
@@ -384,9 +382,9 @@
       return server.getUserTransaction();
    }
 
-   public int getNumberOfNodesOnCluster() throws Exception
+   public Set getNodeIDView() throws Exception
    {
-      return server.getNumberOfNodesOnCluster();
+      return server.getNodeIDView();
    }
 
    private RMINamingDelegate getNamingDelegate()

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 00:17:58 UTC (rev 1757)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 00:19:59 UTC (rev 1758)
@@ -218,7 +218,12 @@
 
    UserTransaction getUserTransaction() throws Exception;
 
-   /** use only on Clustering tests */
-   int getNumberOfNodesOnCluster() throws Exception;
+   /**
+    * Returns a Set containing the nodeID (as Integers) of all cluster members at the time of the
+    * call.
+    *
+    * USE IT ONLY FOR CLUSTERING TESTS!
+    */
+   Set getNodeIDView() throws Exception;
 
 }



From bwang at jboss.com  Sun Dec 10 19:37:35 2006
From: bwang at jboss.com (Ben Wang)
Date: Sun, 10 Dec 2006 19:37:35 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/util  ...
Message-ID: <E1GtZAl-0005u8-1Q@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/10 19:37:35

  Modified:    src-50/org/jboss/cache/pojo/util  CacheApiUtil.java
  Log:
  Check for existence of PojoInstance correctly.
  
  Revision  Changes    Path
  1.3       +2 -2      JBossCache/src-50/org/jboss/cache/pojo/util/CacheApiUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheApiUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/util/CacheApiUtil.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- CacheApiUtil.java	7 Nov 2006 03:57:03 -0000	1.2
  +++ CacheApiUtil.java	11 Dec 2006 00:37:34 -0000	1.3
  @@ -17,7 +17,7 @@
   /** Utility for the 2.0 Cache API
    *
    * @author Ben Wang
  - * @version $Id: CacheApiUtil.java,v 1.2 2006/11/07 03:57:03 bwang Exp $
  + * @version $Id: CacheApiUtil.java,v 1.3 2006/12/11 00:37:34 bwang Exp $
    */
   public class CacheApiUtil
   {
  @@ -42,6 +42,6 @@
         Node node = cache.getRoot().getChild(fqn);
         if(node == null) return false;
         Map map = node.getData();
  -      return (map.values().contains(key)) ? true: false;
  +      return (map.keySet().contains(key)) ? true: false;
      }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec 10 19:54:38 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 10 Dec 2006 19:54:38 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/rules - New
	directory ...
Message-ID: <E1GtZRG-00067M-7R@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/10 19:54:38

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/rules added to the repository


From Shane_Bryzak at symantec.com  Sun Dec 10 19:56:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 10 Dec 2006 19:56:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GtZT4-0006As-7n@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/10 19:56:30

  Modified:    src/main/org/jboss/seam/interceptors 
                        SecurityInterceptor.java
  Log:
  rule-based permission check
  
  Revision  Changes    Path
  1.13      +5 -2      jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- SecurityInterceptor.java	4 Dec 2006 01:06:50 -0000	1.12
  +++ SecurityInterceptor.java	11 Dec 2006 00:56:30 -0000	1.13
  @@ -9,6 +9,7 @@
   import org.jboss.seam.annotations.security.Restrict;
   import org.jboss.seam.intercept.InvocationContext;
   import org.jboss.seam.security.Identity;
  +import org.jboss.seam.security.SeamSecurityManager;
   
   /**
    * Provides authorization services for component invocations.
  @@ -41,7 +42,9 @@
         if (!identity.isValid())
           throw new SecurityException("Invalid identity");
         
  -      /** todo perform restriction check here */
  +      if (!SeamSecurityManager.instance().evaluateExpression(r.value()))
  +        throw new SecurityException(String.format(
  +          "Authorization check failed for expression [%s]", r.value()));
       }
   
       return invocation.proceed();
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec 10 19:56:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 10 Dec 2006 19:56:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security   ...
Message-ID: <E1GtZT4-0006Az-D3@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/10 19:56:30

  Modified:    src/main/org/jboss/seam/security   SeamSecurityManager.java
  Removed:     src/main/org/jboss/seam/security   PermissionHandler.java
  Log:
  rule-based permission check
  
  Revision  Changes    Path
  1.22      +124 -96   jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- SeamSecurityManager.java	4 Dec 2006 04:23:51 -0000	1.21
  +++ SeamSecurityManager.java	11 Dec 2006 00:56:30 -0000	1.22
  @@ -1,26 +1,34 @@
   package org.jboss.seam.security;
   
  -import static org.jboss.seam.ScopeType.APPLICATION;
  -import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
  -import java.security.Permissions;
  +import java.io.InputStreamReader;
   import java.security.acl.Permission;
  +import java.util.ArrayList;
   import java.util.HashMap;
  +import java.util.List;
   import java.util.Map;
   import java.util.Set;
   
  +import org.drools.FactHandle;
  +import org.drools.RuleBase;
  +import org.drools.RuleBaseFactory;
  +import org.drools.WorkingMemory;
  +import org.drools.compiler.PackageBuilder;
  +import org.drools.compiler.PackageBuilderConfiguration;
  +import static org.jboss.seam.ScopeType.APPLICATION;
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptionType;
   import org.jboss.seam.ScopeType;
  +import static org.jboss.seam.annotations.Install.BUILT_IN;
  +import org.jboss.seam.annotations.Create;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  +import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.security.acl.AclProvider;
  -import org.jboss.seam.security.acl.IdentityGenerator;
  -import org.jboss.seam.security.acl.JPAIdentityGenerator;
  -import org.jboss.seam.annotations.Create;
  +import org.jboss.seam.core.Expressions;
  +import org.jboss.seam.security.rules.PermissionCheck;
  +import org.jboss.seam.util.Resources;
   
   /**
    * Holds configuration settings and provides functionality for the security API
  @@ -33,17 +41,12 @@
   @Intercept(InterceptionType.NEVER)
   public class SeamSecurityManager
   {
  -  /**
  -   * An action code that directs the user to a login page.
  -   */
  -  private String loginAction = "login";
  +  private static final String SECURITY_CONFIG_FILENAME = "/META-INF/security-config.xml";
  +  private static final String SECURITY_RULES_FILENAME = "/META-INF/security-rules.drl";
   
  -  /**
  -   * An action code that directs the user to a security error page.
  -   */
  -  private String securityErrorAction = "securityError";
  +  private static final String SECURITY_CONTEXT_NAME = "org.jboss.seam.security.securityContext";
   
  -  private IdentityGenerator identityGenerator = new JPAIdentityGenerator();
  +  private RuleBase securityRules;
   
     /**
      * Map roles to permissions
  @@ -51,16 +54,37 @@
     private Map<String,Set<Permission>> rolePermissions = new HashMap<String,Set<Permission>>();
   
     /**
  +   * Initialise the security manager
      *
  +   * @throws Exception
      */
  -  private Map<Class,PermissionHandler> permissionHandlers = new HashMap<Class,PermissionHandler>();
  -
     @Create
     public void initSecurityManager()
  +      throws Exception
     {
  +    /** @todo Load the security configuration */
  +//     SAXReader saxReader = new SAXReader();
  +//     saxReader.setEntityResolver(new DTDEntityResolver());
  +//     saxReader.setMergeAdjacentText(true);
  +//     Document doc = saxReader.read(stream);
  +
  +    // Create the security rule base
  +    PackageBuilderConfiguration conf = new PackageBuilderConfiguration();
  +    conf.setCompiler(PackageBuilderConfiguration.JANINO);
  +
  +    PackageBuilder builder = new PackageBuilder(conf);
  +    builder.addPackageFromDrl(new InputStreamReader(
  +        Resources.getResourceAsStream(SECURITY_RULES_FILENAME)));
   
  +    securityRules = RuleBaseFactory.newRuleBase();
  +    securityRules.addPackage(builder.getPackage());
     }
   
  +  /**
  +   * Returns the application-scoped instance of the security manager
  +   *
  +   * @return SeamSecurityManager
  +   */
     public static SeamSecurityManager instance()
     {
       if (!Contexts.isApplicationContextActive())
  @@ -78,109 +102,113 @@
       return instance;
     }
   
  -  public String getLoginAction()
  +  /**
  +   * Evaluates the specified security expression, which must return a boolean value.
  +   *
  +   * @param expr String
  +   * @return boolean
  +   */
  +  public boolean evaluateExpression(String expr)
     {
  -    return loginAction;
  +    return ((Boolean) Expressions.instance().createValueBinding(expr).getValue());
     }
   
  -  public void setLoginAction(String loginAction)
  +  /**
  +   * Checks if the authenticated Identity is a member of the specified role.
  +   *
  +   * @param name String
  +   * @return boolean
  +   */
  +  public static boolean hasRole(String name)
     {
  -    this.loginAction = loginAction;
  +    return Identity.instance().isUserInRole(name);
     }
   
  -  public String getSecurityErrorAction()
  +  /**
  +   * Performs a permission check for the specified name and action
  +   *
  +   * @param name String
  +   * @param action String
  +   * @param args Object[]
  +   * @return boolean
  +   */
  +  public static boolean hasPermission(String name, String action, Object ... args)
     {
  -    return securityErrorAction;
  -  }
  +    SeamSecurityManager mgr = instance();
   
  -  public IdentityGenerator getIdentityGenerator()
  -  {
  -    return identityGenerator;
  -  }
  +    List<FactHandle> handles = new ArrayList<FactHandle>();
   
  -  public void setIdentityGenerator(IdentityGenerator identityGenerator)
  -  {
  -    this.identityGenerator = identityGenerator;
  -  }
  +    PermissionCheck check = new PermissionCheck(name, action);
   
  -  public void setSecurityErrorAction(String securityErrorAction)
  -  {
  -    this.securityErrorAction = securityErrorAction;
  -  }
  +    WorkingMemory wm = mgr.getWorkingMemoryForSession();
  +    handles.add(wm.assertObject(check));
   
  -  public void checkPermission(String permissionName, String action)
  -  {
  -    checkRolePermissions(permissionName, action);
  -  }
  +    for (Object o : args)
  +      handles.add(wm.assertObject(o));
   
  -  public void checkPermission(Object obj, String action)
  -  {
  -    PermissionHandler handler = getPermissionHandler(obj.getClass());
  +    wm.fireAllRules();
   
  -    if (handler.supportsAclCheck(action))
  -      handler.aclCheck(obj, action);
  -    else
  -      checkRolePermissions(handler.getPermissionName(), action);
  +    for (FactHandle handle : handles)
  +      wm.retractObject(handle);
  +
  +    return check.isGranted();
     }
   
     /**
  +   * Returns the security working memory for the current session
      *
  -   * @param permissionName
  -   * @param action
  +   * @return WorkingMemory
      */
  -  private void checkRolePermissions(String permissionName, String action)
  -  {
  -    Permission required = new SeamPermission(permissionName, action);
  -    for (Role role : Identity.instance().getRoles())
  +  private WorkingMemory getWorkingMemoryForSession()
       {
  -      Set<Permission> permissions = rolePermissions.get(role);
  -      if (permissions != null && permissions.contains(required))
  -        return;
  -    }
  -  }
  +    if (!Contexts.isSessionContextActive())
  +      throw new IllegalStateException("No active session context found.");
   
  -  protected PermissionHandler getPermissionHandler(Class cls)
  -  {
  -    if (!permissionHandlers.containsKey(cls))
  -    {
  -      synchronized(permissionHandlers)
  -      {
  -        if (!permissionHandlers.containsKey(cls))
  +    Context session = Contexts.getSessionContext();
  +
  +    if (!session.isSet(SECURITY_CONTEXT_NAME))
           {
  -          PermissionHandler handler = new PermissionHandler(cls);
  -          permissionHandlers.put(cls, handler);
  -          return handler;
  -        }
  -      }
  -    }
  +      if (!Identity.instance().isValid())
  +        throw new IllegalStateException("Authenticated Identity is not valid");
   
  -    return permissionHandlers.get(cls);
  -  }
  +      WorkingMemory wm = securityRules.newWorkingMemory();
  +      wm.assertObject(Identity.instance());
   
  -  public Permissions getPermissions(Object value)
  -  {
  -    return null;
  -  }
  +      for (Role r : Identity.instance().getRoles())
  +        wm.assertObject(r);
   
  -  public Permissions getPermissions(Object value, Identity ident)
  -  {
  -    return null;
  -  }
  +      /** @todo Assert the Identity's explicit permissions also? */
   
  -  public String getObjectIdentity(Object obj)
  -  {
  -    return identityGenerator.generateIdentity(obj);
  +      session.set(SECURITY_CONTEXT_NAME, wm);
  +      return wm;
     }
   
  -  public void grantPermission(Object target, String action, String recipient,
  -                               AclProvider.RecipientType recipientType)
  -  {
  -    /** @todo  */
  +    return (WorkingMemory) session.get(SECURITY_CONTEXT_NAME);
     }
   
  -  public void revokePermission(Object target, String action, String recipient,
  -                               AclProvider.RecipientType recipientType)
  -  {
  -    /** @todo  */
  -  }
  +//  public void checkPermission(String permissionName, String action)
  +//  {
  +//    checkRolePermissions(permissionName, action);
  +//  }
  +
  +//  public void checkPermission(Object obj, String action)
  +//  {
  +//    checkRolePermissions(Seam.getComponentName(obj.getClass()), action);
  +//  }
  +
  +  /**
  +   *
  +   * @param permissionName
  +   * @param action
  +   */
  +//  private void checkRolePermissions(String permissionName, String action)
  +//  {
  +//    Permission required = new SeamPermission(permissionName, action);
  +//    for (Role role : Identity.instance().getRoles())
  +//    {
  +//      Set<Permission> permissions = rolePermissions.get(role);
  +//      if (permissions != null && permissions.contains(required))
  +//        return;
  +//    }
  +//  }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec 10 19:56:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 10 Dec 2006 19:56:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl  ...
Message-ID: <E1GtZT4-0006B6-Ia@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/10 19:56:30

  Modified:    src/main/org/jboss/seam/security/acl 
                        PersistentAclProvider.java
  Log:
  rule-based permission check
  
  Revision  Changes    Path
  1.15      +15 -19    jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PersistentAclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/PersistentAclProvider.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- PersistentAclProvider.java	4 Dec 2006 04:23:51 -0000	1.14
  +++ PersistentAclProvider.java	11 Dec 2006 00:56:30 -0000	1.15
  @@ -1,8 +1,5 @@
   package org.jboss.seam.security.acl;
   
  -import static org.jboss.seam.InterceptionType.NEVER;
  -import static org.jboss.seam.ScopeType.APPLICATION;
  -
   import java.security.Principal;
   import java.security.acl.Permission;
   import java.util.ArrayList;
  @@ -10,21 +7,20 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  -
   import javax.naming.NamingException;
   import javax.persistence.EntityManager;
   import javax.persistence.EntityManagerFactory;
   import javax.persistence.Query;
   
  +import static org.jboss.seam.InterceptionType.NEVER;
  +import static org.jboss.seam.ScopeType.APPLICATION;
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.core.ManagedHibernateSession;
   import org.jboss.seam.core.ManagedPersistenceContext;
   import org.jboss.seam.security.Identity;
  -import org.jboss.seam.security.SeamPermission;
  -import org.jboss.seam.security.SeamSecurityManager;
  -import org.jboss.seam.util.Naming;
   import org.jboss.seam.security.Role;
  +import org.jboss.seam.util.Naming;
   
   /**
    * Persistent Acl provider.
  @@ -133,18 +129,18 @@
         }
       }
   
  -    switch (persistenceType)
  -    {
  -      case managedPersistenceContext:
  -      case entityManagerFactory:
  -        ((Query) query).setParameter("identity",
  -            SeamSecurityManager.instance().getObjectIdentity(target));
  -        break;
  -      case managedHibernateSession:
  -        ((org.hibernate.Query) query).setParameter("identity",
  -            SeamSecurityManager.instance().getObjectIdentity(target));
  -        break;
  -    }
  +//    switch (persistenceType)
  +//    {
  +//      case managedPersistenceContext:
  +//      case entityManagerFactory:
  +//        ((Query) query).setParameter("identity",
  +//            SeamSecurityManager.instance().getObjectIdentity(target));
  +//        break;
  +//      case managedHibernateSession:
  +//        ((org.hibernate.Query) query).setParameter("identity",
  +//            SeamSecurityManager.instance().getObjectIdentity(target));
  +//        break;
  +//    }
     }
   
     protected Object executeQuery(Object query)
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec 10 19:56:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 10 Dec 2006 19:56:30 -0500
Subject: [jboss-cvs] jboss-seam/src/test/misc/org/jboss/seam/test  ...
Message-ID: <E1GtZT4-0006BD-Nr@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/10 19:56:30

  Modified:    src/test/misc/org/jboss/seam/test  SecurityTest.java
  Log:
  rule-based permission check
  
  Revision  Changes    Path
  1.10      +4 -3      jboss-seam/src/test/misc/org/jboss/seam/test/SecurityTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/SecurityTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- SecurityTest.java	27 Nov 2006 03:53:49 -0000	1.9
  +++ SecurityTest.java	11 Dec 2006 00:56:30 -0000	1.10
  @@ -19,6 +19,7 @@
   import org.jboss.seam.mock.MockServletContext;
   import org.jboss.seam.security.UsernamePasswordToken;
   import org.jboss.seam.security.acl.JPAIdentityGenerator;
  +import org.jboss.seam.security.acl.AclProvider;
   import org.jboss.seam.security.acl.PersistentAclProvider;
   import org.jboss.seam.security.acl.AclProvider.RecipientType;
   import org.testng.annotations.Test;
  @@ -79,7 +80,7 @@
       ac.setProperty("hibernate.connection.username", "sa");
       ac.setProperty("hibernate.dialect", "org.hibernate.dialect.HSQLDialect");
       ac.setProperty("hibernate.hbm2ddl.auto", "create");
  -    ac.setProperty("hibernate.show_sql", "true");
  +    //ac.setProperty("hibernate.show_sql", "true");
       ac.setProperty("hibernate.cache.use_second_level_cache", "false");
   
       ac.addAnnotatedClass(MockAclPermission.class);
  @@ -126,9 +127,9 @@
                                        new UsernamePasswordToken("testUser", "",
                                        new String[] {}));
   
  -    Component aclProviderComp = new Component(PersistentAclProvider.class,
  +    Component aclProviderComp = new Component(PersistentAclManager.class,
                                                 "persistentAclProvider");
  -    PersistentAclProvider aclProvider = (PersistentAclProvider) aclProviderComp.newInstance();
  +    PersistentAclManager aclProvider = (PersistentAclManager) aclProviderComp.newInstance();
       aclProvider.setPersistenceContextManager(factory);
       aclProvider.setAclQuery("select p.mask, p.recipient, p.recipientType from MockAclPermission p " +
           "where p.identity.objectIdentity = :identity");
  
  
  


From Shane_Bryzak at symantec.com  Sun Dec 10 19:56:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sun, 10 Dec 2006 19:56:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/rules  ...
Message-ID: <E1GtZT4-0006BK-Ra@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/10 19:56:30

  Added:       src/main/org/jboss/seam/security/rules  PermissionCheck.java
  Log:
  rule-based permission check
  
  Revision  Changes    Path
  1.1      date: 2006/12/11 00:56:30;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/security/rules/PermissionCheck.java
  
  Index: PermissionCheck.java
  ===================================================================
  package org.jboss.seam.security.rules;
  
  /**
   * Used to assert permission requirements into a WorkingMemory when evaluating
   * a @Restrict expression.  The consequence of the rule is responsible for
   * granting the permission.
   *
   * @author Shane Bryzak
   */
  public class PermissionCheck
  {
    private String name;
    private String action;
    private boolean granted;
  
    public PermissionCheck(String name, String action)
    {
      this.name = name;
      this.action = action;
      this.granted = false;
    }
  
    public String getName()
    {
      return name;
    }
  
    public String getAction()
    {
      return action;
    }
  
    public void grant()
    {
      this.granted = true;
    }
  
    public boolean isGranted()
    {
      return granted;
    }
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 19:57:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 19:57:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1759 -
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GtZUG-0006Da-Mx@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-10 19:57:43 -0500 (Sun, 10 Dec 2006)
New Revision: 1759

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
Log:
more group management tests

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 00:19:59 UTC (rev 1758)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 00:57:43 UTC (rev 1759)
@@ -85,7 +85,72 @@
       }
    }
 
+   public void testThreeNodesCluster() throws Exception
+   {
+      try
+      {
+         ServerManagement.start("all", 0);
 
+         Set view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(0)));
+
+         ServerManagement.start("all", 1);
+
+         view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+         ServerManagement.start("all", 3);
+
+         view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(3, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(3)));
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(3, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(3)));
+
+         view = ServerManagement.getServer(3).getNodeIDView();
+
+         assertEquals(3, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(3)));
+
+         log.info("testThreeNodesCluster sucessful");
+      }
+      finally
+      {
+         ServerManagement.stop(3, false);
+         ServerManagement.stop(1, false);
+         ServerManagement.stop(0, false);
+      }
+   }
+
+
+   public void testCleanLeave() throws Exception
+   {
+
+   }
+
+
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 19:58:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 19:58:28 -0500
Subject: [jboss-cvs] JBossAS SVN: r58963 -
	trunk/system-jmx/src/main/org/jboss/system/server/jmx
Message-ID: <E1GtZUy-0006EE-1Z@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 19:58:26 -0500 (Sun, 10 Dec 2006)
New Revision: 58963

Modified:
   trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
Log:
JBAS-3560, the jmx kernel must delegate shutdown to the injected serverImpl.

Modified: trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
===================================================================
--- trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java	2006-12-10 23:43:41 UTC (rev 58962)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java	2006-12-11 00:58:26 UTC (rev 58963)
@@ -199,17 +199,11 @@
          throw new IllegalStateException("Server not started");
 
       isInShutdown = true;
-      // start in new thread to give positive
-      // feedback to requesting client of success.
-      new Thread()
-      {
-         public void run()
-         {
-            // just run the hook, don't call System.exit, as we may
-            // be embeded in a vm that would not like that very much
-            shutdown();
-         }
-      }.start();
+      log.debug("Shutting down all services");
+      shutdownServices();
+
+      // Make sure all mbeans are unregistered
+      removeMBeans();
    }
 
    ///////////////////////////////////////////////////////////////////////////
@@ -341,33 +335,7 @@
    {
       if (log.isTraceEnabled())
          log.trace("Shutdown caller:", new Throwable("Here"));
-      
-      // Execute the jdk JBossJDKLogManager doReset
-      LogManager lm = LogManager.getLogManager();
-      if (lm instanceof JBossJDKLogManager)
-      {
-         JBossJDKLogManager jbosslm = (JBossJDKLogManager)lm;
-         jbosslm.doReset();
-      } 
-
-      // avoid entering twice; may happen when called directly
-      // from ServerImpl.shutdown(), then called again when all
-      // non-daemon threads have exited and the ShutdownHook runs. 
-      if (isInShutdown)
-         return;
-      else
-         isInShutdown = true;
-      
-      // ServiceController.shutdown()
-      log.debug("Shutting down all services");
-      shutdownServices();
-
-      // Make sure all mbeans are unregistered
-      removeMBeans();
-
-      // Done
-      log.info("Legacy kernel shutdown complete");
-      System.out.println("Legacy kernel shutdown complete");
+      serverImpl.shutdown();
    }
 
    /**



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 19:59:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 19:59:15 -0500
Subject: [jboss-cvs] JBossAS SVN: r58964 -
	trunk/system-jmx/src/main/org/jboss/system/server/jmx
Message-ID: <E1GtZVj-0006Eq-Vx@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 19:59:14 -0500 (Sun, 10 Dec 2006)
New Revision: 58964

Modified:
   trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
Log:
Cleanup unused imports

Modified: trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java
===================================================================
--- trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java	2006-12-11 00:58:26 UTC (rev 58963)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/JMXKernel.java	2006-12-11 00:59:14 UTC (rev 58964)
@@ -29,7 +29,6 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Properties;
-import java.util.logging.LogManager;
 
 import javax.management.ListenerNotFoundException;
 import javax.management.MBeanNotificationInfo;
@@ -42,7 +41,6 @@
 import javax.management.ObjectName;
 
 import org.jboss.kernel.Kernel;
-import org.jboss.logging.JBossJDKLogManager;
 import org.jboss.mx.loading.RepositoryClassLoader;
 import org.jboss.mx.server.ServerConstants;
 import org.jboss.mx.util.JMXExceptionDecoder;
@@ -85,8 +83,6 @@
    /** The bootstrap UCL class loader ObjectName */
    private ObjectName bootstrapUCLName;
    private boolean started;
-   /** A flag indicating if shutdown has been called */
-   private boolean isInShutdown;
 
    public Server getServerImpl()
    {
@@ -198,7 +194,6 @@
       if (!started)
          throw new IllegalStateException("Server not started");
 
-      isInShutdown = true;
       log.debug("Shutting down all services");
       shutdownServices();
 



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 20:01:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 20:01:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r58965 -
	trunk/system/src/main/org/jboss/system/server/profileservice
Message-ID: <E1GtZXU-0006HZ-SG@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 20:01:03 -0500 (Sun, 10 Dec 2006)
New Revision: 58965

Modified:
   trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java
Log:
JBAS-3560, move the jdk log manager reset to shutdown and update the shutdown logging

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java	2006-12-11 00:59:14 UTC (rev 58964)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java	2006-12-11 01:01:03 UTC (rev 58965)
@@ -26,6 +26,7 @@
 import java.net.URL;
 import java.util.Date;
 import java.util.Properties;
+import java.util.logging.LogManager;
 
 import javax.management.Notification;
 import javax.management.NotificationBroadcasterSupport;
@@ -37,6 +38,7 @@
 import org.jboss.kernel.plugins.deployment.BasicKernelDeployer;
 import org.jboss.kernel.spi.event.KernelEvent;
 import org.jboss.logging.Logger;
+import org.jboss.logging.jdk.JBossJDKLogManager;
 import org.jboss.net.protocol.URLStreamHandlerFactory;
 import org.jboss.system.server.Server;
 import org.jboss.system.server.ServerConfig;
@@ -457,10 +459,12 @@
 
       if (exitOnShutdown)
       {
+         log.debug("Calling server.exit(0)");
          server.exit(0);
       }
       else if (blockingShutdown)
       {
+         log.debug("Invoking shutdownHook in calling thread");
          shutdownHook.shutdown();
       } // end of if ()
       else
@@ -473,6 +477,7 @@
             {
                // just run the hook, don't call System.exit, as we may
                // be embeded in a vm that would not like that very much
+               log.debug("Invoking shutdownHook in background thread");
                shutdownHook.shutdown();
             }
          }.start();
@@ -715,6 +720,17 @@
       {
          // Send a notification that mbeanServer stop is initiated
          log.info("JBoss SHUTDOWN");
+         if (log.isTraceEnabled())
+            log.trace("Shutdown caller:", new Throwable("Here"));
+
+         // Execute the jdk JBossJDKLogManager doReset
+         LogManager lm = LogManager.getLogManager();
+         if (lm instanceof JBossJDKLogManager)
+         {
+            JBossJDKLogManager jbosslm = (JBossJDKLogManager)lm;
+            jbosslm.doReset();
+         } 
+
          Notification msg = new Notification(Server.STOP_NOTIFICATION_TYPE, this, 2);
          sendNotification(msg);
          log.info("Undeploying all packages");



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 20:02:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 20:02:34 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58966 - trunk/build
Message-ID: <E1GtZYw-0006UZ-Ss@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 20:02:32 -0500 (Sun, 10 Dec 2006)
New Revision: 58966

Modified:
   trunk/build/build-distr.xml
   trunk/build/build.xml
Log:
JBAS-3560, update the jbossall-client.jar classes to fix CNFE seen by shutdown command

Modified: trunk/build/build-distr.xml
===================================================================
--- trunk/build/build-distr.xml	2006-12-11 01:01:03 UTC (rev 58965)
+++ trunk/build/build-distr.xml	2006-12-11 01:02:32 UTC (rev 58966)
@@ -418,6 +418,11 @@
         <include name="jboss-system-jmx.jar"/>
       </fileset>
     </copy>
+    <copy todir="${install.client}" filtering="no">
+      <fileset dir="${_module.output}/lib">
+         <include name="jboss-system-jmx-client.jar"/>
+      </fileset>
+    </copy>
   </target>
   <target name="_module-system-jmx-all" depends="_module-system-jmx-most">
   </target>

Modified: trunk/build/build.xml
===================================================================
--- trunk/build/build.xml	2006-12-11 01:01:03 UTC (rev 58965)
+++ trunk/build/build.xml	2006-12-11 01:02:32 UTC (rev 58966)
@@ -772,7 +772,8 @@
         <include name="hibernate-annotations.jar"/>
         <include name="jboss-auth.jar"/>
         <include name="jboss-annotations-ejb3.jar"/>
-        <include name="jboss-common.jar"/>
+        <include name="jboss-common*.jar"/>
+        <include name="jboss-logging*.jar"/>
         <include name="jboss-deployment.jar"/>
         <include name="jboss-ejb3x.jar"/>
         <include name="jboss-j2ee.jar"/>
@@ -812,7 +813,8 @@
         <include name="hibernate-annotations.jar"/>
         <include name="jboss-annotations-ejb3.jar"/>
         <include name="jboss-auth.jar"/>
-        <include name="jboss-common.jar"/>
+        <include name="jboss-common*.jar"/>
+        <include name="jboss-logging*.jar"/>
         <include name="jboss-deployment.jar"/>
         <include name="jboss-ejb3x.jar"/>
         <include name="jboss-j2ee.jar"/>



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 20:05:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 20:05:16 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1760 - in
	branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging:
	jms/clustering tools tools/jmx/rmi
Message-ID: <E1GtZbY-0006XX-9F@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-10 20:05:12 -0500 (Sun, 10 Dec 2006)
New Revision: 1760

Modified:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
cleaned up server management interfaces by getting rid of unused 'sendNotification' flag on start()/stop()

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 00:57:43 UTC (rev 1759)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 01:05:12 UTC (rev 1760)
@@ -47,7 +47,7 @@
       }
       finally
       {
-         ServerManagement.stop(0, false);
+         ServerManagement.stop(0);
       }
    }
 
@@ -80,8 +80,8 @@
       }
       finally
       {
-         ServerManagement.stop(1, false);
-         ServerManagement.stop(0, false);
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
       }
    }
 
@@ -137,9 +137,9 @@
       }
       finally
       {
-         ServerManagement.stop(3, false);
-         ServerManagement.stop(1, false);
-         ServerManagement.stop(0, false);
+         ServerManagement.stop(3);
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
       }
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-11 00:57:43 UTC (rev 1759)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-11 01:05:12 UTC (rev 1760)
@@ -56,7 +56,7 @@
 
       // TODO - verify that the cluster formed correctly assertion
 
-      ServerManagement.stop(3, false);
+      ServerManagement.stop(3);
    }
 
    /**
@@ -72,13 +72,13 @@
 
       // We get the first node to programatically leave the cluster
 
-      ServerManagement.stop(0, false);
+      ServerManagement.stop(0);
 
       // TODO - verify that the cluster formed correctly assertion
 
       // We get the last node to programatically leave the cluster
 
-      ServerManagement.stop(2, false);
+      ServerManagement.stop(2);
 
    }
 
@@ -91,7 +91,7 @@
 
       // We get the first node to programatically leave the cluster
 
-      ServerManagement.stop(0, false);
+      ServerManagement.stop(0);
 
       // TODO - verify that the cluster formed correctly assertion
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-11 00:57:43 UTC (rev 1759)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-11 01:05:12 UTC (rev 1760)
@@ -166,16 +166,13 @@
 
    public static synchronized void stop() throws Exception
    {
-      insureStarted();
-
-      servers[0].stop();
+      stop(0);
    }
 
-   public static synchronized void stop(int index, boolean sendNotification) throws Exception
+   public static synchronized void stop(int index) throws Exception
    {
       insureStarted(index);
-
-      servers[index].stop(sendNotification);
+      servers[index].stop();
    }
 
    public static synchronized void destroy() throws Exception

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 00:57:43 UTC (rev 1759)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 01:05:12 UTC (rev 1760)
@@ -147,11 +147,6 @@
 
    public synchronized void stop() throws Exception
    {
-      stop(true);
-   }
-
-   public synchronized void stop(boolean sendNotification) throws Exception
-   {
       if (!isStarted())
       {
          return;
@@ -161,7 +156,7 @@
       {
          setEnvironmentServerIndex(serverIndex);
 
-         stopServerPeer(sendNotification);
+         stopServerPeer();
 
          log.debug("stopping service container");
 
@@ -392,11 +387,6 @@
 
    public void stopServerPeer() throws Exception
    {
-      stopServerPeer(true);
-   }
-
-   public void stopServerPeer(boolean sendNotification) throws Exception
-   {
       try
       {
          // if we don't find a ServerPeer instance registered under the serverPeerObjectName
@@ -458,9 +448,6 @@
 
          try
          {
-            //Huh?? Where's the method on the server peer???
-            //sc.invoke(serverPeerObjectName, "stop", new Object[]{new Boolean(sendNotification)}, new String[]{"boolean"});
-
             sc.invoke(serverPeerObjectName, "stop", new Object[0], new String[0]);
             sc.invoke(serverPeerObjectName, "destroy", new Object[0], new String[0]);
             sc.unregisterService(serverPeerObjectName);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 00:57:43 UTC (rev 1759)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 01:05:12 UTC (rev 1760)
@@ -334,16 +334,9 @@
       server.startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, clustered);
    }
 
-   public void stop(boolean sendNotification) throws Exception
-   {
-      server.stop(sendNotification);
-      namingDelegate.reset();
-   }
-
    public void stop() throws Exception
    {
       server.stop();
-
       namingDelegate.reset();
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 00:57:43 UTC (rev 1759)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 01:05:12 UTC (rev 1760)
@@ -43,7 +43,6 @@
 public interface Server extends Remote
 {
    void start(String containerConfig) throws Exception;
-   void stop(boolean sendNotification) throws Exception;
    void stop() throws Exception;
    void destroy() throws Exception;
 



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 20:06:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 20:06:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r58967 -
	trunk/system/src/main/org/jboss/system/server/profileservice
Message-ID: <E1GtZd4-0006b9-IC@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 20:06:48 -0500 (Sun, 10 Dec 2006)
New Revision: 58967

Modified:
   trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java
Log:
Use reflection to reset the log manager to avoid compile time dependencies

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java	2006-12-11 01:02:32 UTC (rev 58966)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ServerImpl.java	2006-12-11 01:06:48 UTC (rev 58967)
@@ -23,6 +23,7 @@
 package org.jboss.system.server.profileservice;
 
 import java.io.File;
+import java.lang.reflect.Method;
 import java.net.URL;
 import java.util.Date;
 import java.util.Properties;
@@ -38,7 +39,6 @@
 import org.jboss.kernel.plugins.deployment.BasicKernelDeployer;
 import org.jboss.kernel.spi.event.KernelEvent;
 import org.jboss.logging.Logger;
-import org.jboss.logging.jdk.JBossJDKLogManager;
 import org.jboss.net.protocol.URLStreamHandlerFactory;
 import org.jboss.system.server.Server;
 import org.jboss.system.server.ServerConfig;
@@ -723,13 +723,20 @@
          if (log.isTraceEnabled())
             log.trace("Shutdown caller:", new Throwable("Here"));
 
-         // Execute the jdk JBossJDKLogManager doReset
+         // Execute the jdk JBossJDKLogManager doReset via reflection
          LogManager lm = LogManager.getLogManager();
-         if (lm instanceof JBossJDKLogManager)
+         try
          {
-            JBossJDKLogManager jbosslm = (JBossJDKLogManager)lm;
-            jbosslm.doReset();
-         } 
+            Class[] sig = {};
+            Method doReset = lm.getClass().getDeclaredMethod("doReset", sig);
+            Object[] args = {};
+            doReset.invoke(lm, args);
+         }
+         catch(Exception e)
+         {
+            if(log.isTraceEnabled())
+               log.trace("No doReset found?", e);
+         }
 
          Notification msg = new Notification(Server.STOP_NOTIFICATION_TYPE, this, 2);
          sendNotification(msg);



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 20:13:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 20:13:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r58968 - in branches/JBoss_4_0_4_GA_CP:
	build tools/etc/buildmagic
Message-ID: <E1GtZji-0006gq-HM@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-10 20:13:41 -0500 (Sun, 10 Dec 2006)
New Revision: 58968

Modified:
   branches/JBoss_4_0_4_GA_CP/build/build.xml
   branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent
   branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml
Log:
updated version string info

Modified: branches/JBoss_4_0_4_GA_CP/build/build.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/build/build.xml	2006-12-11 01:06:48 UTC (rev 58967)
+++ branches/JBoss_4_0_4_GA_CP/build/build.xml	2006-12-11 01:13:41 UTC (rev 58968)
@@ -63,7 +63,7 @@
     <!-- Module name(s) & version -->
     <property name="module.name" value="jboss"/>
     <property name="module.Name" value="JBoss Build"/>
-    <property name="module.version" value="${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+    <property name="module.version" value="${version.major}.${version.minor}.${version.revision}${version.tag}"/>
 
 
 

Modified: branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent
===================================================================
--- branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-11 01:06:48 UTC (rev 58967)
+++ branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/buildmagic.ent	2006-12-11 01:13:41 UTC (rev 58968)
@@ -106,13 +106,13 @@
 
   <!-- Manifest version info -->
   <property name="specification.title" value="JBoss"/>
-  <property name="specification.version" value="${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+  <property name="specification.version" value="${version.major}.${version.minor}.${version.revision}${version.tag}"/>
   <property name="specification.vendor" value="JBoss (http://www.jboss.org/)"/>
 
   <property name="implementation.title" value="JBoss [${version.name}]"/>
   <property name="implementation.url" value="http://www.jboss.org/"/>
   <property name="implementation.version"
-    value="${version.major}.${version.minor}.${version.revision}.${version.tag} (build: CVSTag=${version.cvstag} date=${build.id})"/>
+    value="${version.major}.${version.minor}.${version.revision}${version.tag} (build: CVSTag=${version.cvstag} date=${build.id})"/>
   <property name="implementation.vendor" value="JBoss.org"/>
   <property name="implementation.vendor.id" value="${implementation.url}"/>
 

Modified: branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml	2006-12-11 01:06:48 UTC (rev 58967)
+++ branches/JBoss_4_0_4_GA_CP/tools/etc/buildmagic/version-info.xml	2006-12-11 01:13:41 UTC (rev 58968)
@@ -24,13 +24,13 @@
 
     <!-- Manifest version info -->
     <property name="specification.title" value="JBoss"/>
-    <property name="specification.version" value="${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+    <property name="specification.version" value="${version.major}.${version.minor}.${version.revision}${version.tag}"/>
     <property name="specification.vendor" value="JBoss (http://www.jboss.org/)"/>
 
     <property name="implementation.title" value="JBoss [${version.name}]"/>
     <property name="implementation.url" value="http://www.jboss.org/"/>
     <property name="implementation.version" 
-         value="${version.major}.${version.minor}.${version.revision}.${version.tag} (build: CVSTag=${version.cvstag} date=${build.id})"/>
+         value="${version.major}.${version.minor}.${version.revision}${version.tag} (build: CVSTag=${version.cvstag} date=${build.id})"/>
     <property name="implementation.vendor" value="JBoss Inc."/>
     <property name="implementation.vendor.id" value="${implementation.url}"/>
 



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 20:17:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 20:17:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r58969 - trunk/server/src/etc/conf/default
Message-ID: <E1GtZna-0006l7-VR@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 20:17:41 -0500 (Sun, 10 Dec 2006)
New Revision: 58969

Modified:
   trunk/server/src/etc/conf/default/jboss-service.xml
Log:
Add the JaasSecurityManagerService DeepCopySubjectMode attribute default to the config

Modified: trunk/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- trunk/server/src/etc/conf/default/jboss-service.xml	2006-12-11 01:13:41 UTC (rev 58968)
+++ trunk/server/src/etc/conf/default/jboss-service.xml	2006-12-11 01:17:41 UTC (rev 58969)
@@ -290,6 +290,15 @@
       AuthenticationCacheJndiName has been changed from the default value.
       -->
       <attribute name="DefaultCacheResolution">60</attribute>
+      <!-- DeepCopySubjectMode: This set the copy mode of subjects done by the
+      security managers to be deep copies that makes copies of the subject
+      principals and credentials if they are cloneable. It should be set to
+      true if subject include mutable content that can be corrupted when
+      multiple threads have the same identity and cache flushes/logout clearing
+      the subject in one thread results in subject references affecting other
+      threads.
+      -->
+      <attribute name="DeepCopySubjectMode">false</attribute>
    </mbean> 
 
    <!-- Authorization manager-->



From jboss-cvs-commits at lists.jboss.org  Sun Dec 10 22:39:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 10 Dec 2006 22:39:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58970 -
	trunk/server/src/main/org/jboss/ejb/deployers
Message-ID: <E1Gtc0X-0000h5-2H@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-10 22:39:11 -0500 (Sun, 10 Dec 2006)
New Revision: 58970

Modified:
   trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java
Log:
The ccm dependency was being overwritten by the timer service dependency

Modified: trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java	2006-12-11 01:17:41 UTC (rev 58969)
+++ trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java	2006-12-11 03:39:11 UTC (rev 58970)
@@ -171,26 +171,24 @@
       attrs.add(ws);
       ejbModule.setAttributes(attrs);
 
+      List<ServiceDependencyMetaData> dependencies = new ArrayList<ServiceDependencyMetaData>();
       // CCM for CachedConnectionInterceptor dependency
       // TODO: this should be injected directly to the interceptor
       if( ccmServiceName != null && ccmServiceName.length() > 0 )
       {
-         List<ServiceDependencyMetaData> dependencies = new ArrayList<ServiceDependencyMetaData>();
          ServiceDependencyMetaData ccm = new ServiceDependencyMetaData();
          ccm.setIDependOn(ccmServiceName);
          dependencies.add(ccm);
-         ejbModule.setDependencies(dependencies);
       }
       // Dependency on the timer service
       // TODO: this should be injected directly to the ejb container
       if( timerServiceName != null && timerServiceName.length() > 0 )
       {
-         List<ServiceDependencyMetaData> dependencies = new ArrayList<ServiceDependencyMetaData>();
-         ServiceDependencyMetaData ccm = new ServiceDependencyMetaData();
-         ccm.setIDependOn(timerServiceName);
-         dependencies.add(ccm);
-         ejbModule.setDependencies(dependencies);
+         ServiceDependencyMetaData tms = new ServiceDependencyMetaData();
+         tms.setIDependOn(timerServiceName);
+         dependencies.add(tms);
       }
+      ejbModule.setDependencies(dependencies);
 
       unit.addAttachment(ServiceMetaData.class, ejbModule);
    }



From forge-admin at jboss.com  Mon Dec 11 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Mon, 11 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GteDE-0003DD-Q7@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-10 09:22 EST)
-----------------

JBSEAM-577 page params with no value binding

  jboss-seam  src/gen/org/jboss/seam/tool/Util.java    1.2
  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd    1.5
  jboss-seam  src/main/org/jboss/seam/core/Page.java   1.7
  jboss-seam  src/main/org/jboss/seam/core/Pages.java  1.57


Commit from gavin (2006-12-10 10:42 EST)
-----------------

make the Done buttons work nicely

  jboss-seam  seam-gen/build.xml                   1.48
  jboss-seam  seam-gen/src/EntityHome.java.ftl     1.5
+ jboss-seam  seam-gen/view/edit.page.xml.ftl      1.1
  jboss-seam  seam-gen/view/edit.xhtml.ftl         1.18
  jboss-seam  seam-gen/view/list.xhtml.ftl         1.7
+ jboss-seam  seam-gen/view/param.xml.ftl          1.1
  jboss-seam  seam-gen/view/view.xhtml.ftl         1.7
  jboss-seam  seam-gen/view/layout/template.xhtml  1.6
  jboss-seam  seam-gen/view/stylesheet/theme.css   1.6


Commit from gavin (2006-12-10 10:54 EST)
-----------------

fix JBSEAM-576

  jboss-seam  src/main/org/jboss/seam/framework/Query.java  1.12


Commit from gavin (2006-12-10 10:59 EST)
-----------------

ws

  jboss-seam  seam-gen/view/edit.xhtml.ftl                      1.19
  jboss-seam  examples/drools/resources/WEB-INF/components.xml  1.6


Commit from msurtani (2006-12-10 11:42 EST)
--------------------

Updated JGroups snapshot

  JBossCache  lib/jgroups.jar  1.9


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-10 11:42 EST)
------------------------------------------------------

Updated JGroups lib with anycast bug fixed.  TreeCache modified to take advantage of this.

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.33
  JBossCache  lib/jgroups.jar                     1.4.2.4


Commit from gavin (2006-12-10 11:53 EST)
-----------------

get rid of @RequestParameter
fix bug in conversation model

  jboss-seam  seam-gen/build.xml                1.49
  jboss-seam  seam-gen/src/EntityList.java.ftl  1.3
  jboss-seam  seam-gen/view/edit.page.xml.ftl   1.2
  jboss-seam  seam-gen/view/edit.xhtml.ftl      1.20
+ jboss-seam  seam-gen/view/list.page.xml.ftl   1.1
  jboss-seam  seam-gen/view/param.xml.ftl       1.2


Commit from starksm (2006-12-10 12:00 EST)
-------------------

Add the maven plugins

+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.jar                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.jar.sha1                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.pom                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-core/1.0-alpha-8/doxia-core-1.0-alpha-8.pom.sha1                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.jar                  1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.jar.sha1             1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.pom                  1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-decoration-model/1.0-alpha-8/doxia-decoration-model-1.0-alpha-8.pom.sha1             1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7/doxia-sink-api-1.0-alpha-7.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7/doxia-sink-api-1.0-alpha-7.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8/doxia-sink-api-1.0-alpha-8.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-8/doxia-sink-api-1.0-alpha-8.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.jar                        1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.jar.sha1                   1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.pom                        1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia-site-renderer/1.0-alpha-8/doxia-site-renderer-1.0-alpha-8.pom.sha1                   1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia/1.0-alpha-7/doxia-1.0-alpha-7.pom                                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia/1.0-alpha-7/doxia-1.0-alpha-7.pom.sha1                                               1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia/1.0-alpha-8/doxia-1.0-alpha-8.pom                                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/doxia/doxia/1.0-alpha-8/doxia-1.0-alpha-8.pom.sha1                                               1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.jar                                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.jar.sha1                                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.pom                                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-archiver/2.2/maven-archiver-2.2.pom.sha1                                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-artifact-manager/2.0/maven-artifact-manager-2.0.pom                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-artifact-manager/2.0/maven-artifact-manager-2.0.pom.sha1                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-artifact/2.0.2/maven-artifact-2.0.2.pom                                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-artifact/2.0.2/maven-artifact-2.0.2.pom.sha1                                               1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-artifact/2.0/maven-artifact-2.0.pom                                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-artifact/2.0/maven-artifact-2.0.pom.sha1                                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-core/2.0/maven-core-2.0.pom                                                                1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-core/2.0/maven-core-2.0.pom.sha1                                                           1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-error-diagnostics/2.0/maven-error-diagnostics-2.0.pom                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-error-diagnostics/2.0/maven-error-diagnostics-2.0.pom.sha1                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-model/2.0/maven-model-2.0.pom                                                              1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-model/2.0/maven-model-2.0.pom.sha1                                                         1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-monitor/2.0/maven-monitor-2.0.pom                                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-monitor/2.0/maven-monitor-2.0.pom.sha1                                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-parent/1/maven-parent-1.pom                                                                1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-parent/1/maven-parent-1.pom.sha1                                                           1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-parent/4/maven-parent-4.pom                                                                1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-parent/4/maven-parent-4.pom.sha1                                                           1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.pom                                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-api/2.0/maven-plugin-api-2.0.pom.sha1                                               1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-descriptor/2.0/maven-plugin-descriptor-2.0.pom                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-descriptor/2.0/maven-plugin-descriptor-2.0.pom.sha1                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0/maven-plugin-parameter-documenter-2.0.pom                  1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-parameter-documenter/2.0/maven-plugin-parameter-documenter-2.0.pom.sha1             1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-registry/2.0/maven-plugin-registry-2.0.pom                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-plugin-registry/2.0/maven-plugin-registry-2.0.pom.sha1                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-profile/2.0/maven-profile-2.0.pom                                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-profile/2.0/maven-profile-2.0.pom.sha1                                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-project/2.0/maven-project-2.0.pom                                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-project/2.0/maven-project-2.0.pom.sha1                                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-repository-metadata/2.0/maven-repository-metadata-2.0.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-repository-metadata/2.0/maven-repository-metadata-2.0.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-settings/2.0/maven-settings-2.0.pom                                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/maven-settings/2.0/maven-settings-2.0.pom.sha1                                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/maven/2.0.2/maven-2.0.2.pom                                                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/maven/2.0.2/maven-2.0.2.pom.sha1                                                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/maven/2.0/maven-2.0.pom                                                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/maven/2.0/maven-2.0.pom.sha1                                                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.jar                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.jar.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-compiler-plugin/2.0/maven-compiler-plugin-2.0.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.jar                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.jar.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-deploy-plugin/2.2.1/maven-deploy-plugin-2.2.1.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata-central.xml                                           1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata-jbosspluginrepo.xml                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.jar                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.jar.sha1                               1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.pom                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/2.1/maven-install-plugin-2.1.pom.sha1                               1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/maven-metadata-central.xml                                          1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/maven-metadata-central.xml.sha1                                     1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-install-plugin/maven-metadata-jbosspluginrepo.xml                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.jar                                            1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.jar.sha1                                       1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.pom                                            1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/2.1/maven-jar-plugin-2.1.pom.sha1                                       1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata-central.xml                                              1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata-central.xml.sha1                                         1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-jar-plugin/maven-metadata-jbosspluginrepo.xml                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-plugin-parent/2.0/maven-plugin-parent-2.0.pom                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-plugin-parent/2.0/maven-plugin-parent-2.0.pom.sha1                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-plugins/1/maven-plugins-1.pom                                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-plugins/1/maven-plugins-1.pom.sha1                                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-plugins/3/maven-plugins-3.pom                                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-plugins/3/maven-plugins-3.pom.sha1                                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.jar                                1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.jar.sha1                           1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.pom                                1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/2.2/maven-resources-plugin-2.2.pom.sha1                           1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/maven-metadata-central.xml                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/maven-metadata-central.xml.sha1                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-resources-plugin/maven-metadata-jbosspluginrepo.xml                                1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.jar                            1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.jar.sha1                       1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.pom                            1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-site-plugin/2.0-beta-5/maven-site-plugin-2.0-beta-5.pom.sha1                       1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-site-plugin/maven-metadata-central.xml                                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-site-plugin/maven-metadata-central.xml.sha1                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.jar                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.jar.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/2.0.1/maven-source-plugin-2.0.1.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata-central.xml                                           1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata-central.xml.sha1                                      1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-source-plugin/maven-metadata-jbosspluginrepo.xml                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.jar                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.jar.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/2.2/maven-surefire-plugin-2.2.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata-central.xml                                         1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata-central.xml.sha1                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/plugins/maven-surefire-plugin/maven-metadata-jbosspluginrepo.xml                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2/maven-reporting-api-2.0.2.pom                                1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting-api/2.0.2/maven-reporting-api-2.0.2.pom.sha1                           1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting-api/2.0/maven-reporting-api-2.0.pom                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting-api/2.0/maven-reporting-api-2.0.pom.sha1                               1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting/2.0.2/maven-reporting-2.0.2.pom                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting/2.0.2/maven-reporting-2.0.2.pom.sha1                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting/2.0/maven-reporting-2.0.pom                                            1.1
+ repository.jboss.com  maven2/org/apache/maven/reporting/maven-reporting/2.0/maven-reporting-2.0.pom.sha1                                       1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.jar       1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.jar.sha1  1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.pom       1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-plugin-testing-harness/1.0-beta-1/maven-plugin-testing-harness-1.0-beta-1.pom.sha1  1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-shared-components/1/maven-shared-components-1.pom                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-shared-components/1/maven-shared-components-1.pom.sha1                              1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-shared-components/3/maven-shared-components-3.pom                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/shared/maven-shared-components/3/maven-shared-components-3.pom.sha1                              1.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-10 12:02 EST)
------------------------------------------------------

JBCACHE-894

  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java  1.25.2.9


Commit from starksm (2006-12-10 12:02 EST)
-------------------

Add the maven plugins

+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.jar                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.jar.sha1                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.pom                                        1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-api/2.0/surefire-api-2.0.pom.sha1                                   1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.jar                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.jar.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.pom                                  1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-booter/2.0/surefire-booter-2.0.pom.sha1                             1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.jar                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.jar.sha1                               1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.pom                                    1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-junit/2.0/surefire-junit-2.0.pom.sha1                               1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-providers/2.0/surefire-providers-2.0.pom                            1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire-providers/2.0/surefire-providers-2.0.pom.sha1                       1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire/2.0/surefire-2.0.pom                                                1.1
+ repository.jboss.com  maven2/org/apache/maven/surefire/surefire/2.0/surefire-2.0.pom.sha1                                           1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5/wagon-file-1.0-alpha-5.pom                               1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-file/1.0-alpha-5/wagon-file-1.0-alpha-5.pom.sha1                          1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5/wagon-http-lightweight-1.0-alpha-5.pom       1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-http-lightweight/1.0-alpha-5/wagon-http-lightweight-1.0-alpha-5.pom.sha1  1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5/wagon-provider-api-1.0-alpha-5.pom               1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-provider-api/1.0-alpha-5/wagon-provider-api-1.0-alpha-5.pom.sha1          1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5/wagon-ssh-1.0-alpha-5.pom                                 1.1
+ repository.jboss.com  maven2/org/apache/maven/wagon/wagon-ssh/1.0-alpha-5/wagon-ssh-1.0-alpha-5.pom.sha1                            1.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-10 12:15 EST)
------------------------------------------------------

fixed order of remove for non tx call, to ensure proper notifications

  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.20.2.5


Commit from starksm (2006-12-10 12:19 EST)
-------------------

*** empty log message ***

+ repository.jboss.com  maven2/org/apache/apache/3/apache-3.pom       1.1
+ repository.jboss.com  maven2/org/apache/apache/3/apache-3.pom.sha1  1.1


Commit from starksm (2006-12-10 12:38 EST)
-------------------

*** empty log message ***

+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.jar                             1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.jar.sha1                        1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.pom                             1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-api/1.5.1/plexus-compiler-api-1.5.1.pom.sha1                        1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar                         1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.jar.sha1                    1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.pom                         1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-archiver/1.0-alpha-7/plexus-archiver-1.0-alpha-7.pom.sha1                    1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.jar                         1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.jar.sha1                    1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.pom                         1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-javac/1.5.1/plexus-compiler-javac-1.5.1.pom.sha1                    1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.jar                     1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.jar.sha1                1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.pom                     1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-compiler-manager/1.5.1/plexus-compiler-manager-1.5.1.pom.sha1                1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-components/1.1.6/plexus-components-1.1.6.pom                                 1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-components/1.1.6/plexus-components-1.1.6.pom.sha1                            1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.jar                                   1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.jar.sha1                              1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.pom                                   1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-i18n/1.0-beta-6/plexus-i18n-1.0-beta-6.pom.sha1                              1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4/plexus-interactivity-api-1.0-alpha-4.pom       1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-interactivity-api/1.0-alpha-4/plexus-interactivity-api-1.0-alpha-4.pom.sha1  1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar                                               1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar.sha1                                          1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-utils/1.2/plexus-utils-1.2.pom                                               1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-utils/1.2/plexus-utils-1.2.pom.sha1                                          1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.jar                                     1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.jar.sha1                                1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.pom                                     1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus-velocity/1.1.3/plexus-velocity-1.1.3.pom.sha1                                1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus/1.0.8/plexus-1.0.8.pom                                                       1.1
+ repository.jboss.com  maven2/org/codehaus/plexus/plexus/1.0.8/plexus-1.0.8.pom.sha1                                                  1.1


Commit from vralev (2006-12-10 16:47 EST)
------------------

http://jira.jboss.com/jira/browse/JBINSTALL-125
http://jira.jboss.com/jira/browse/JBINSTALL-144
http://jira.jboss.com/jira/browse/JBINSTALL-147
http://jira.jboss.com/jira/browse/JBINSTALL-46

+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/installer.jar            1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/izevent.jar              1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/kunststoff.jar           1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar  1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller.jar          1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/compiler.jar             1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller-ext.jar      1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/ant.jar                  1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/bin.zip                  1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/jakarta-regexp-1.3.jar   1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/liquidlnf.jar            1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/looks.jar                1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/metouia.jar              1.1
+   repository.jboss.com/izpack/3.9.0.jboss.patch3/component-info.xml           1.1


Commit from vralev (2006-12-10 16:47 EST)
------------------

support for izpack jboss patch3

    repository.jboss.com/jboss/izpack-listeners/1.0.1.GA/component-info.xml  1.5


Commit from bwang (2006-12-10 19:37 EST)
-----------------

Check for existence of PojoInstance correctly.

  JBossCache  src-50/org/jboss/cache/pojo/util/CacheApiUtil.java  1.3


Commit from sbryzak2 (2006-12-10 19:56 EST)
--------------------

rule-based permission check

  jboss-seam  src/main/org/jboss/seam/interceptors/SecurityInterceptor.java    1.13
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java        1.22
- jboss-seam  src/main/org/jboss/seam/security/PermissionHandler.java          1.6
  jboss-seam  src/main/org/jboss/seam/security/acl/PersistentAclProvider.java  1.15
  jboss-seam  src/test/misc/org/jboss/seam/test/SecurityTest.java              1.10
+ jboss-seam  src/main/org/jboss/seam/security/rules/PermissionCheck.java      1.1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061211/56f4d02e/attachment.html 

From msurtani at jboss.com  Mon Dec 11 04:02:26 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:02:26 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1Gth3K-0006cy-LA@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:02:26

  Modified:    tests/functional/org/jboss/cache/replicated  Tag:
                        Branch_JBossCache_1_4_0 SyncReplTxTest.java
  Log:
  fixed timing issue
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.9.2.4   +5 -3      JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java,v
  retrieving revision 1.9.2.3
  retrieving revision 1.9.2.4
  diff -u -b -r1.9.2.3 -r1.9.2.4
  --- SyncReplTxTest.java	8 Dec 2006 13:10:41 -0000	1.9.2.3
  +++ SyncReplTxTest.java	11 Dec 2006 09:02:25 -0000	1.9.2.4
  @@ -30,15 +30,15 @@
   import javax.transaction.SystemException;
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  -import java.util.List;
   import java.util.ArrayList;
  +import java.util.List;
   
   /**
    * Replicated unit test for sync transactional TreeCache
    * Note: we use DummyTransactionManager for Tx purpose instead of relying on
    * jta.
    *
  - * @version $Revision: 1.9.2.3 $
  + * @version $Revision: 1.9.2.4 $
    */
   public class SyncReplTxTest extends TestCase {
       private static Log log = LogFactory.getLog(SyncReplTxTest.class);
  @@ -876,7 +876,9 @@
   //      }
   
         // we can only expect 1 thread to succeed.  The others will fail.  So, threads.length -1 exceptions.
  -      assertEquals(threads.length - 1, exceptions.size());
  +      // this is a timing issue - 2 threads still may succeed on a multi cpu system
  +      // assertEquals(threads.length - 1, exceptions.size());
  +      
         for (int i=0; i<exceptions.size(); i++) assertEquals(TimeoutException.class, exceptions.get(i).getClass());
      }
   
  
  
  


From msurtani at jboss.com  Mon Dec 11 04:04:37 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:04:37 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1Gth5R-0006dR-Ea@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:04:37

  Modified:    tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_4_0 PrepareTxTest.java
  Log:
  fixed broken test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.20.1  +10 -3     JBossCache/tests/functional/org/jboss/cache/transaction/PrepareTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PrepareTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/PrepareTxTest.java,v
  retrieving revision 1.1
  retrieving revision 1.1.20.1
  diff -u -b -r1.1 -r1.1.20.1
  --- PrepareTxTest.java	8 Jul 2005 05:58:10 -0000	1.1
  +++ PrepareTxTest.java	11 Dec 2006 09:04:36 -0000	1.1.20.1
  @@ -6,7 +6,6 @@
   import org.jboss.cache.CacheException;
   import org.jboss.cache.TransactionTable;
   import org.jboss.cache.TreeCache;
  -import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.Synchronization;
  @@ -32,6 +31,14 @@
   
      protected void tearDown() throws Exception {
         super.tearDown();
  +      Transaction t = cache.getTransactionManager().getTransaction();
  +      try
  +      {
  +         if ( t != null ) t.rollback();
  +      }
  +      catch (Exception e)
  +      {
  +      }
         cache.stopService();
         cache.destroyService();
      }
  @@ -54,7 +61,7 @@
         cache.put("/one/two/three", "key1", "val1");
         System.out.println("before commit:\n" + cache.printLockInfo());
         numLocks=cache.getNumberOfLocksHeld();
  -      assertEquals(3, numLocks);
  +      assertEquals(4, numLocks);
   
         // we register *second*
         tx.registerSynchronization(new Synchronization() {
  @@ -105,7 +112,7 @@
          cache.put("/one/two/three", "key1", "val1");
          System.out.println("before commit:\n" + cache.printLockInfo());
          numLocks=cache.getNumberOfLocksHeld();
  -       assertEquals(3, numLocks);
  +       assertEquals(4, numLocks);
   
          // we register *second*
          tx.registerSynchronization(new Synchronization() {
  
  
  


From msurtani at jboss.com  Mon Dec 11 04:17:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:17:03 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1GthHT-0006p8-E2@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:17:03

  Modified:    tests/functional/org/jboss/cache/marshall  Tag:
                        Branch_JBossCache_1_4_0 JBossSerializationTest.java
  Log:
  added gc in setup
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.5.2.2   +8 -0      JBossCache/tests/functional/org/jboss/cache/marshall/JBossSerializationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossSerializationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/JBossSerializationTest.java,v
  retrieving revision 1.5.2.1
  retrieving revision 1.5.2.2
  diff -u -b -r1.5.2.1 -r1.5.2.2
  --- JBossSerializationTest.java	2 Nov 2006 09:33:49 -0000	1.5.2.1
  +++ JBossSerializationTest.java	11 Dec 2006 09:17:02 -0000	1.5.2.2
  @@ -7,6 +7,7 @@
   package org.jboss.cache.marshall;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.misc.TestingUtil;
   
   import java.io.ByteArrayOutputStream;
   import java.io.File;
  @@ -28,6 +29,13 @@
      public static boolean SAVE_FILE = false;
      public static boolean USE_STRING = false;
   
  +   protected void setUp()
  +   {
  +      // do a GC and wait for it to kick in - useful when running as a part of the test suite.
  +      System.gc();
  +      TestingUtil.sleepThread(1000);
  +   }
  +
      static class DummyObject implements java.io.Serializable
      {
         private static final long serialVersionUID = -1374365296408936578L;
  
  
  


From msurtani at jboss.com  Mon Dec 11 04:17:23 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:17:23 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GthHn-0006pP-1V@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:17:23

  Modified:    tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_4_0 DeadlockTest.java
  Log:
  commented out classic deadlock test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.1   +6 -3      JBossCache/tests/functional/org/jboss/cache/transaction/DeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/DeadlockTest.java,v
  retrieving revision 1.4
  retrieving revision 1.4.2.1
  diff -u -b -r1.4 -r1.4.2.1
  --- DeadlockTest.java	5 May 2006 12:06:59 -0000	1.4
  +++ DeadlockTest.java	11 Dec 2006 09:17:22 -0000	1.4.2.1
  @@ -16,10 +16,10 @@
   import org.jboss.cache.CacheException;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
  -import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
   import org.jboss.cache.lock.UpgradeException;
  +import org.jboss.cache.misc.TestingUtil;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.SystemException;
  @@ -29,7 +29,7 @@
    * Tests transactional access to a local TreeCache, with concurrent (deadlock-prone) access.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: DeadlockTest.java,v 1.4 2006/05/05 12:06:59 msurtani Exp $
  + * @version $Id: DeadlockTest.java,v 1.4.2.1 2006/12/11 09:17:22 msurtani Exp $
    */
   public class DeadlockTest extends TestCase {
      TreeCache   cache=null;
  @@ -125,6 +125,9 @@
         t2.join();
      }
   
  + /*
  +
  + Commented out since JBCACHE-875 onwards, this will end up in a classic deadlock since we lock parent when removing a child.
   
      public void testCreateIfNotExistsLogic() throws CacheException, InterruptedException {
         cache.put(NODE, null);
  @@ -180,7 +183,7 @@
         t0.join();
         t1.join();
      }
  -
  +            */
   
      public void testMoreThanOneUpgrader() throws Exception {
         final int NUM=2;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 04:32:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 04:32:26 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1761 - in
	branches/Branch_Client_Failover_Experiment:
	src/etc/server/default/deploy src/etc/xmdesc
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/destination
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core/plugin
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/core
	tests/src/org/jboss/test/messaging/core/plugin/base
	tests/src/org/jboss/test/messaging/core/plugin/postoffice
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GthWM-00071N-4L@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-11 04:31:53 -0500 (Mon, 11 Dec 2006)
New Revision: 1761

Added:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSCondition.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSConditionFactory.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleCondition.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java
Modified:
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/hsqldb-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedQueue.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedTopic.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/QueueService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/TopicService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
Merge postoffices into one



Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -58,12 +58,12 @@
    </mbean>
 
    <mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
-      name="jboss.messaging:service=QueuePostOffice"
+      name="jboss.messaging:service=PostOffice"
       xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Clustered Queue</attribute>
+      <attribute name="PostOfficeName">Clustered JMS</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
       <attribute name="SqlProperties"><![CDATA[
@@ -121,70 +121,6 @@
       </attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
-      name="jboss.messaging:service=TopicPostOffice"
-      xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
-      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Clustered Topic</attribute>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER VARCHAR(1))
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-      ]]></attribute>
-      <attribute name="GroupName">Topic</attribute>
-      <attribute name="StateTimeout">5000</attribute>
-      <attribute name="CastTimeout">5000</attribute>
-      <attribute name="StatsSendPeriod">10000</attribute>
-      <attribute name="MessagePullPolicy">org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy</attribute>
-      <attribute name="ClusterRouterFactory">org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory</attribute>
-
-      <attribute name="AsyncChannelConfig">
-         <config>
-            <UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
-           mcast_port="45569" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
-           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/>
-            <AUTOCONF down_thread="false" up_thread="false"/>
-            <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
-            <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
-            <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
-            <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
-                         retransmit_timeout="100,200,600,1200,2400,4800"/>
-            <UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/>
-            <pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/>
-            <FRAG frag_size="8192" down_thread="false" up_thread="false"/>
-            <VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" />
-            <pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/>
-         </config>
-      </attribute>
-
-      <attribute name="SyncChannelConfig">
-         <config>
-            <UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
-           mcast_port="45570" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
-           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/>
-            <AUTOCONF down_thread="false" up_thread="false"/>
-            <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
-            <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
-            <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
-            <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
-                         retransmit_timeout="100,200,600,1200,2400,4800"/>
-            <UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/>
-            <pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/>
-            <FRAG frag_size="8192" down_thread="false" up_thread="false"/>
-            <VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" />
-            <pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/>
-            <pbcast.STATE_TRANSFER down_thread="false" up_thread="false"/>
-         </config>
-      </attribute>
-   </mbean>
-
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/hsqldb-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/hsqldb-persistence-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/hsqldb-persistence-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -22,27 +22,16 @@
    <!-- Note that Hypersonic CANNOT be used for clustered post offices -->
 
    <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=QueuePostOffice"
+      name="jboss.messaging:service=PostOffice"
       xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Queue</attribute>
+      <attribute name="PostOfficeName">JMS</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=TopicPostOffice"
-      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
-      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Topic</attribute>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-   </mbean>
-
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -25,8 +25,7 @@
       <depends optional-attribute-name="JMSUserManager">jboss.messaging:service=JMSUserManager</depends>
       <depends>jboss.messaging:service=Connector,transport=socket</depends>
 
-	   <attribute name="QueuePostOffice">jboss.messaging:service=QueuePostOffice</attribute>
-	   <attribute name="TopicPostOffice">jboss.messaging:service=TopicPostOffice</attribute>
+	   <attribute name="PostOffice">jboss.messaging:service=PostOffice</attribute>
 
       <attribute name="SecurityDomain">java:/jaas/messaging</attribute>
       <attribute name="DefaultSecurityConfig">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -58,12 +58,12 @@
    </mbean>
 
    <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=QueuePostOffice"
+      name="jboss.messaging:service=PostOffice"
       xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Queue</attribute>
+      <attribute name="PostOfficeName">JMS</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
       <attribute name="SqlProperties"><![CDATA[
@@ -74,23 +74,6 @@
       ]]></attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=TopicPostOffice"
-      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
-      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Topic</attribute>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-      ]]></attribute>
-   </mbean>
-   
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -61,46 +61,7 @@
       <attribute name="MaxParams">500</attribute>
    </mbean>      
       
-   <mbean code="org.jboss.messaging.core.plugin.DirectExchange"
-      name="jboss.messaging:service=DirectExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR2(32) NOT NULL, PASSWD VARCHAR2(32) NOT NULL, CLIENTID VARCHAR2(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR2(32) NOT NULL, USERID VARCHAR2(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))      
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1), JMS_DEST_NAME VARCHAR2(1024), JMS_SUB_NAME VARCHAR2(1024), CLIENT_ID VARCHAR2(128), SELECTOR VARCHAR2(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))      
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?            
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]></attribute>
-   </mbean>
    
-   <mbean code="org.jboss.messaging.core.plugin.TopicExchange"
-      name="jboss.messaging:service=TopicExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR2(32) NOT NULL, PASSWD VARCHAR2(32) NOT NULL, CLIENTID VARCHAR2(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR2(32) NOT NULL, USERID VARCHAR2(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))      
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1), JMS_DEST_NAME VARCHAR2(1024), JMS_SUB_NAME VARCHAR2(1024), CLIENT_ID VARCHAR2(128), SELECTOR VARCHAR2(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))      
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?            
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]></attribute>
-   </mbean>   
-   
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManager"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -61,46 +61,6 @@
       <attribute name="MaxParams">500</attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DirectExchange"
-      name="jboss.messaging:service=DirectExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID BIGINT, TYPE CHAR(1), JMS_DEST_NAME VARCHAR(1024), JMS_SUB_NAME VARCHAR(1024), CLIENT_ID VARCHAR(128), SELECTOR VARCHAR(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?
-           ]]></attribute>
-   </mbean>
-   
-   <mbean code="org.jboss.messaging.core.plugin.TopicExchange"
-      name="jboss.messaging:service=TopicExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID BIGINT, TYPE CHAR(1), JMS_DEST_NAME VARCHAR(1024), JMS_SUB_NAME VARCHAR(1024), CLIENT_ID VARCHAR(128), SELECTOR VARCHAR(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?
-           ]]></attribute>
-   </mbean>   
-   
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManager"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -69,56 +69,7 @@
 		</attribute>
 	</mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DirectExchange"
-      name="jboss.messaging:service=DirectExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-		<!-- TODO this insures the fact that dependency exists. However I need to redundantly specifiy
-           the DataSource JNDI name in order to actually get a reference to it. Fix this.
-      -->
-		<depends>jboss.jca:service=DataSourceBinding,name=SybaseDS</depends>
-		<depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-		<attribute name="DataSource">SybaseDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128) NULL, PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1) NULL, JMS_DEST_NAME VARCHAR(1024) NULL, JMS_SUB_NAME VARCHAR(1024) NULL, CLIENT_ID VARCHAR(128) NULL, SELECTOR VARCHAR(1024) NULL, NO_LOCAL CHAR(1) NULL, PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]>
-		</attribute>
-	</mbean>
 	
-	<mbean code="org.jboss.messaging.core.plugin.TopicExchange"
-      name="jboss.messaging:service=TopicExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-		<!-- TODO this insures the fact that dependency exists. However I need to redundantly specifiy
-           the DataSource JNDI name in order to actually get a reference to it. Fix this.
-      -->
-		<depends>jboss.jca:service=DataSourceBinding,name=SybaseDS</depends>
-		<depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-		<attribute name="DataSource">SybaseDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128) NULL, PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1) NULL, JMS_DEST_NAME VARCHAR(1024) NULL, JMS_SUB_NAME VARCHAR(1024) NULL, CLIENT_ID VARCHAR(128) NULL, SELECTOR VARCHAR(1024) NULL, NO_LOCAL CHAR(1) NULL, PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]>
-		</attribute>
-	</mbean>
-	
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManager"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-11 09:31:53 UTC (rev 1761)
@@ -34,24 +34,12 @@
       <type>javax.management.ObjectName</type>
    </attribute>
 
-   <attribute access="read-write" getMethod="getQueuePostOffice" setMethod="setQueuePostOffice">
-      <description>The ObjectName of the queue post office</description>
-      <name>QueuePostOffice</name>
+   <attribute access="read-write" getMethod="getPostOffice" setMethod="setPostOffice">
+      <description>The ObjectName of the post office</description>
+      <name>PostOffice</name>
       <type>javax.management.ObjectName</type>
-   </attribute>
+   </attribute>        
    
-   <attribute access="read-write" getMethod="getTopicPostOffice" setMethod="setTopicPostOffice">
-      <description>The ObjectName of the topic post office</description>
-      <name>TopicPostOffice</name>
-      <type>javax.management.ObjectName</type>
-   </attribute>   
-   
-   <attribute access="read-write" getMethod="getClusteredTopicPostOffice" setMethod="setClusteredTopicPostOffice">
-      <description>The ObjectName of the clustered topic post office</description>
-      <name>ClusteredTopicPostOffice</name>
-      <type>javax.management.ObjectName</type>
-   </attribute>    
-   
    <attribute access="read-write" getMethod="getJMSUserManager" setMethod="setJMSUserManager">
       <description>The ObjectName of the jms user manager</description>
       <name>JMSUserManager</name>

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -483,7 +483,7 @@
       {
          try
          {
-            log.info("********* EXCEPTION DETECTED");
+            log.info("********* EXCEPTION DETECTED", throwable);
             
             handleFailure(connection);
          }

Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSCondition.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSCondition.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSCondition.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -0,0 +1,128 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server;
+
+import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.plugin.contract.Condition;
+
+/**
+ * A JMSCondition
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class JMSCondition implements Condition
+{
+   private boolean queue;
+   
+   private String name;
+   
+   private static final String QUEUE_PREFIX = "queue.";
+   
+   private static final String TOPIC_PREFIX = "topic.";
+   
+   //Cache the hash code
+   private int hash = -1;
+   
+   public JMSCondition(boolean queue, String name)
+   {
+      this.queue = queue;
+      
+      this.name = name;
+   }
+   
+   public JMSCondition(String text)
+   {
+      if (text.startsWith(QUEUE_PREFIX))
+      {
+         queue = true;
+         
+         name = text.substring(QUEUE_PREFIX.length());
+      }
+      else if (text.startsWith(TOPIC_PREFIX))
+      {
+         queue = false;
+         
+         name = text.substring(TOPIC_PREFIX.length());
+      }
+      else
+      {
+         throw new IllegalArgumentException("Illegal text: " + text);
+      }
+         
+   }
+   
+   public boolean isQueue()
+   {
+      return queue;
+   }
+   
+   public String getName()
+   {
+      return name;
+   }
+
+   public boolean matches(Condition routingCondition, MessageReference ref)
+   {
+      return equals(routingCondition);
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (!(other instanceof JMSCondition))
+      {
+         return false;
+      }
+      
+      JMSCondition jmsCond = (JMSCondition)other;
+      
+      return ((jmsCond.queue == this.queue) && (jmsCond.name.equals(this.name)));
+   }
+   
+   public int hashCode()
+   {
+      if (hash == -1)
+      {               
+         hash = 17;
+         
+         hash = 37 * hash + (queue ? 0 : 1);
+         
+         hash = 37 * hash + name.hashCode();
+      }
+      
+      return hash;      
+   }
+
+   public String toText()
+   {      
+      return (queue ? QUEUE_PREFIX : TOPIC_PREFIX) + name;
+   }
+   
+   public String toString()
+   {
+      return toText();
+   }
+
+}

Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSConditionFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSConditionFactory.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSConditionFactory.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server;
+
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+
+/**
+ * 
+ * A JMSConditionFactory
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class JMSConditionFactory implements ConditionFactory
+{
+
+   public Condition createCondition(String text) throws Exception
+   {
+      return new JMSCondition(text);
+   }
+
+}

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -125,11 +125,11 @@
    protected ObjectName persistenceManagerObjectName;
    protected PersistenceManager persistenceManager;
    
-   protected ObjectName queuePostOfficeObjectName;
-   protected PostOffice queuePostOffice;
+   protected ObjectName postOfficeObjectName;
+   protected PostOffice postOffice;
    
-   protected ObjectName topicPostOfficeObjectName;
-   protected PostOffice topicPostOffice;
+//   protected ObjectName topicPostOfficeObjectName;
+//   protected PostOffice topicPostOffice;
      
    protected ObjectName jmsUserManagerObjectName;
    protected JMSUserManager jmsUserManager;
@@ -312,25 +312,25 @@
       persistenceManagerObjectName = on;
    }
    
-   public ObjectName getQueuePostOffice()
+   public ObjectName getPostOffice()
    {
-      return queuePostOfficeObjectName;
+      return postOfficeObjectName;
    }
 
-   public void setQueuePostOffice(ObjectName on)
+   public void setPostOffice(ObjectName on)
    {
-      queuePostOfficeObjectName = on;
+      postOfficeObjectName = on;
    }
    
-   public ObjectName getTopicPostOffice()
-   {
-      return topicPostOfficeObjectName;
-   }
-
-   public void setTopicPostOffice(ObjectName on)
-   {
-      topicPostOfficeObjectName = on;
-   }
+//   public ObjectName getTopicPostOffice()
+//   {
+//      return topicPostOfficeObjectName;
+//   }
+//
+//   public void setTopicPostOffice(ObjectName on)
+//   {
+//      topicPostOfficeObjectName = on;
+//   }
    
    public ObjectName getJmsUserManager()
    {
@@ -603,7 +603,7 @@
 
    public Replicator getReplicator() throws Exception
    {
-      PostOffice postOffice = getQueuePostOfficeInstance();
+      PostOffice postOffice = getPostOfficeInstance();
       if (!(postOffice instanceof Replicator))
       {
          throw new  IllegalAccessException("This operations is only legal on clustering configurations");
@@ -611,40 +611,40 @@
       return (Replicator)postOffice;
    }
    
-   public PostOffice getQueuePostOfficeInstance() throws Exception
+   public PostOffice getPostOfficeInstance() throws Exception
    {
       // We get the reference lazily to avoid problems with MBean circular dependencies
-      if (queuePostOffice == null)
+      if (postOffice == null)
       {
-         queuePostOffice = (PostOffice)getServer().
-            getAttribute(queuePostOfficeObjectName, "Instance");
+         postOffice = (PostOffice)getServer().
+            getAttribute(postOfficeObjectName, "Instance");
          
          //We also inject the replicator dependency into the ConnectionFactoryJNDIMapper
          //This is a bit messy but we have a circular dependency
          //POJOContainer should be able to help us here
          //Yes, this is nasty
          
-         if (!queuePostOffice.isLocal())
+         if (!postOffice.isLocal())
          {
-            Replicator rep = (Replicator)queuePostOffice;
+            Replicator rep = (Replicator)postOffice;
             connFactoryJNDIMapper.injectReplicator(rep);
             rep.registerListener(new FailoverListener());
             
          }
       }
-      return queuePostOffice;
+      return postOffice;
    }
       
-   public PostOffice getTopicPostOfficeInstance() throws Exception
-   {
-      // We get the reference lazily to avoid problems with MBean circular dependencies
-      if (topicPostOffice == null)
-      {
-         topicPostOffice = (PostOffice)getServer().
-            getAttribute(topicPostOfficeObjectName, "Instance");
-      }
-      return topicPostOffice;        
-   }
+//   public PostOffice getTopicPostOfficeInstance() throws Exception
+//   {
+//      // We get the reference lazily to avoid problems with MBean circular dependencies
+//      if (topicPostOffice == null)
+//      {
+//         topicPostOffice = (PostOffice)getServer().
+//            getAttribute(topicPostOfficeObjectName, "Instance");
+//      }
+//      return topicPostOffice;        
+//   }
    
    public synchronized int getNextObjectID()
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -377,7 +377,7 @@
    
    private void setupReplicator() throws Exception
    {
-      this.serverPeer.getQueuePostOfficeInstance();
+      this.serverPeer.getPostOfficeInstance();
    }
 
    private void recalculateFailoverMap(Map nodeAddressMap) throws Exception

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedQueue.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedQueue.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedQueue.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -27,6 +27,7 @@
 import javax.jms.JMSException;
 
 import org.jboss.jms.selector.Selector;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 
@@ -54,8 +55,10 @@
 
    public int getMessageCount() throws Exception
    {
-      Binding binding = (Binding)postOffice.listBindingsForCondition(name).iterator().next();
+      JMSCondition queueCond = new JMSCondition(true, name);
       
+      Binding binding = (Binding)postOffice.listBindingsForCondition(queueCond).iterator().next();
+      
       if (binding == null)
       {
          throw new IllegalStateException("Cannot find binding for queue:" + name);
@@ -68,8 +71,10 @@
    
    public void removeAllMessages() throws Throwable
    {
-      Binding binding = (Binding)postOffice.listBindingsForCondition(name).iterator().next();
+      JMSCondition queueCond = new JMSCondition(true, name);
       
+      Binding binding = (Binding)postOffice.listBindingsForCondition(queueCond).iterator().next();
+      
       if (binding == null)
       {
          throw new IllegalStateException("Cannot find binding for queue:" + name);
@@ -91,8 +96,10 @@
          }
       }
       
-      Binding binding = (Binding)postOffice.listBindingsForCondition(name).iterator().next();
+      JMSCondition queueCond = new JMSCondition(true, name);
       
+      Binding binding = (Binding)postOffice.listBindingsForCondition(queueCond).iterator().next();
+      
       if (binding == null)
       {
          throw new IllegalStateException("Cannot find binding for queue:" + name);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedTopic.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedTopic.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/ManagedTopic.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -29,6 +29,7 @@
 import javax.jms.InvalidSelectorException;
 
 import org.jboss.jms.selector.Selector;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.util.MessageQueueNameHelper;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
@@ -52,13 +53,15 @@
    
    public ManagedTopic(String name, int fullSize, int pageSize, int downCacheSize)
    {
-      super(name, fullSize, pageSize, downCacheSize);
+      super(name, fullSize, pageSize, downCacheSize);           
    }
 
    public void removeAllMessages() throws Throwable
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       //XXX How to lock down all subscriptions?
       Iterator iter = subs.iterator();
       while (iter.hasNext())
@@ -71,15 +74,19 @@
    
    public int subscriptionCount() throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return subs.size();         
    }
    
    public int subscriptionCount(boolean durable) throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       Iterator iter = subs.iterator();
       
       int count = 0;
@@ -99,31 +106,39 @@
    
    public String listSubscriptionsAsText() throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getSubscriptionsAsText(subs, true) + getSubscriptionsAsText(subs, false);
    }
    
    public String listSubscriptionsAsText(boolean durable) throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getSubscriptionsAsText(subs, durable);
    }
    
    public List listMessagesDurableSub(String subName, String clientID, String selector)
       throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getMessagesFromDurableSub(subs, subName, clientID, trimSelector(selector));
    }
    
    public List listMessagesNonDurableSub(long channelID, String selector)
       throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getMessagesFromNonDurableSub(subs, channelID, trimSelector(selector));
    }
    

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/QueueService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/QueueService.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/QueueService.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -9,6 +9,7 @@
 import java.util.ArrayList;
 import java.util.List;
 
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.XMLUtil;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
@@ -78,7 +79,7 @@
       
       try
       {                           
-         postOffice = serverPeer.getQueuePostOfficeInstance();
+         postOffice = serverPeer.getPostOfficeInstance();
          
          destination.setPostOffice(postOffice);
 
@@ -106,13 +107,17 @@
             
             PagingFilteredQueue queue;
             
+            JMSCondition queueCond = new JMSCondition(true, destination.getName());
+            
             if (postOffice.isLocal())
             {
                queue = new PagingFilteredQueue(destination.getName(), idm.getId(), ms, pm, true, true,                        
                                                executor, null,
                                                destination.getFullSize(), destination.getPageSize(), destination.getDownCacheSize());
                
-               postOffice.bindQueue(destination.getName(), queue);
+               
+               
+               postOffice.bindQueue(queueCond, queue);
             }
             else
             {               
@@ -124,11 +129,11 @@
                
                if (destination.isClustered())
                {               
-                  cpo.bindClusteredQueue(destination.getName(), (LocalClusteredQueue)queue);
+                  cpo.bindClusteredQueue(queueCond, (LocalClusteredQueue)queue);
                }
                else
                {
-                  cpo.bindQueue(destination.getName(), (LocalClusteredQueue)queue);
+                  cpo.bindQueue(queueCond, (LocalClusteredQueue)queue);
                }
             }                        
          }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/TopicService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/TopicService.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/TopicService.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -13,12 +13,11 @@
 
 import javax.jms.JMSException;
 
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.XMLUtil;
-import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
-import org.jboss.messaging.core.plugin.postoffice.cluster.ClusteredQueue;
 
 /**
  * A deployable JBoss Messaging topic.
@@ -64,15 +63,17 @@
       
       try
       {
-         postOffice = serverPeer.getTopicPostOfficeInstance();
+         postOffice = serverPeer.getPostOfficeInstance();
 
          if (postOffice == null)
           throw new IllegalArgumentException("Post Office instance not found. Check your destination configuration.");
 
          destination.setPostOffice(postOffice);
-           
+         
+         JMSCondition topicCond = new JMSCondition(false, destination.getName());
+                    
          // We deploy any queues corresponding to pre-existing durable subscriptions
-         Collection bindings = postOffice.listBindingsForCondition(destination.getName());
+         Collection bindings = postOffice.listBindingsForCondition(topicCond);
          Iterator iter = bindings.iterator();
          while (iter.hasNext())
          {
@@ -113,8 +114,10 @@
          //First we remove any data for a non durable sub - a non durable sub might have data in the
          //database since it might have paged
          
-         Collection bindings = postOffice.listBindingsForCondition(destination.getName());
+         JMSCondition topicCond = new JMSCondition(false, destination.getName());         
          
+         Collection bindings = postOffice.listBindingsForCondition(topicCond);
+         
          Iterator iter = bindings.iterator();
          while (iter.hasNext())            
          {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -38,6 +38,7 @@
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ConnectionManager;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.server.SecurityManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.endpoint.advised.SessionAdvised;
@@ -106,10 +107,8 @@
    private ServerPeer serverPeer;
 
    // access to server's extensions
-   private PostOffice queuePostOffice;
+   private PostOffice postOffice;
    
-   private PostOffice topicPostOffice;
-   
    private SecurityManager sm;
    
    private ConnectionManager cm;
@@ -144,9 +143,8 @@
       tr = serverPeer.getTxRepository();
       cm = serverPeer.getConnectionManager();
       ms = serverPeer.getMessageStore();
-      queuePostOffice = serverPeer.getQueuePostOfficeInstance();
-      topicPostOffice = serverPeer.getTopicPostOfficeInstance();
-      
+      postOffice = serverPeer.getPostOfficeInstance();
+ 
       started = false;
 
       this.connectionID = serverPeer.getNextObjectID();
@@ -307,7 +305,7 @@
 
             if (dest.isQueue())
             {     
-               queuePostOffice.unbindQueue(dest.getName());               
+               postOffice.unbindQueue(dest.getName());               
             }
             else
             {
@@ -599,14 +597,14 @@
          
          if (dest.isQueue())
          {
-            if (!queuePostOffice.route(ref, dest.getName(), tx))
+            if (!postOffice.route(ref, new JMSCondition(true, dest.getName()), tx))
             {
                throw new JMSException("Failed to route message");
             }
          }
          else
          {
-            topicPostOffice.route(ref, dest.getName(), tx);   
+            postOffice.route(ref, new JMSCondition(false, dest.getName()), tx);   
          }
       }
       finally

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -365,10 +365,10 @@
 
             if (destination.isTopic())
             {
-               PostOffice topicPostOffice = 
-                  sessionEndpoint.getConnectionEndpoint().getServerPeer().getTopicPostOfficeInstance();
+               PostOffice postOffice = 
+                  sessionEndpoint.getConnectionEndpoint().getServerPeer().getPostOfficeInstance();
                
-               Binding binding = topicPostOffice.getBindingForQueueName(queueName);
+               Binding binding = postOffice.getBindingForQueueName(queueName);
 
                //Note binding can be null since there can many competing subscribers for the subscription  - 
                //in which case the first will have removed the subscription and subsequently
@@ -376,7 +376,7 @@
                
                if (binding != null && !binding.getQueue().isRecoverable())
                {
-                  topicPostOffice.unbindQueue(queueName);
+                  postOffice.unbindQueue(queueName);
                }
             }
                         

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,7 +21,18 @@
   */
 package org.jboss.jms.server.endpoint;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import javax.jms.IllegalStateException;
+import javax.jms.InvalidDestinationException;
+import javax.jms.JMSException;
+
 import org.jboss.jms.client.delegate.ClientBrowserDelegate;
 import org.jboss.jms.client.delegate.ClientConsumerDelegate;
 import org.jboss.jms.delegate.BrowserDelegate;
@@ -32,6 +43,7 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.selector.Selector;
 import org.jboss.jms.server.DestinationManager;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.destination.ManagedDestination;
@@ -57,10 +69,7 @@
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.util.id.GUID;
 
-import javax.jms.IllegalStateException;
-import javax.jms.InvalidDestinationException;
-import javax.jms.JMSException;
-import java.util.*;
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
 /**
  * Concrete implementation of SessionEndpoint.
@@ -99,8 +108,7 @@
    private IdManager idm;
    private QueuedExecutorPool pool;
    private TransactionRepository tr;
-   private PostOffice topicPostOffice;
-   private PostOffice queuePostOffice;
+   private PostOffice postOffice;
    private int nodeId;
 
 
@@ -118,8 +126,7 @@
       pm = sp.getPersistenceManagerInstance();
       ms = sp.getMessageStore();
       dm = sp.getDestinationManager();
-      topicPostOffice = sp.getTopicPostOfficeInstance();
-      queuePostOffice = sp.getQueuePostOfficeInstance();
+      postOffice = sp.getPostOfficeInstance();     
       idm = sp.getChannelIdManager();
       pool = sp.getQueuedExecutorPool();
       nodeId = sp.getServerPeerID();
@@ -143,23 +150,13 @@
       try
       {
          // fail over channel
-         PostOffice postOfficeToUse = null;
-         if (jmsDestination.isTopic())
+         if (postOffice.isLocal())
          {
-            postOfficeToUse = topicPostOffice;
-         }
-         else
-         {
-            postOfficeToUse = queuePostOffice;
-         }
-
-         if (postOfficeToUse.isLocal())
-         {
             throw new IllegalStateException("Cannot failover on a non clustered post office!");
          }
 
          // this is a Clustered operation... so postOffice here must be Clustered
-         Binding binding = ((ClusteredPostOffice)postOfficeToUse).getBindingforChannelId(oldChannelID);
+         Binding binding = ((ClusteredPostOffice)postOffice).getBindingforChannelId(oldChannelID);
          if (binding == null)
          {
             throw new IllegalStateException("Can't find failed over channel " + oldChannelID);
@@ -254,6 +251,8 @@
 
          if (jmsDestination.isTopic())
          {
+            JMSCondition topicCond = new JMSCondition(false, jmsDestination.getName());
+            
             if (subscriptionName == null)
             {
                // non-durable subscription
@@ -264,7 +263,7 @@
 
                PagingFilteredQueue q;
 
-               if (topicPostOffice.isLocal())
+               if (postOffice.isLocal())
                {
                   q = new PagingFilteredQueue(new GUID().toString(), idm.getId(), ms, pm, true, false,
                                               executor, selector,
@@ -272,25 +271,25 @@
                                               mDest.getPageSize(),
                                               mDest.getDownCacheSize());
 
-                  binding = topicPostOffice.bindQueue(jmsDestination.getName(), q);
+                  binding = postOffice.bindQueue(topicCond, q);
                }
                else
                {
-                  q = new LocalClusteredQueue(topicPostOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
+                  q = new LocalClusteredQueue(postOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
                                               executor, selector, tr,
                                               mDest.getFullSize(),
                                               mDest.getPageSize(),
                                               mDest.getDownCacheSize());
 
-                  ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                  ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                   if (mDest.isClustered())
                   {
-                     binding = cpo.bindClusteredQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                     binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
                   }
                   else
                   {
-                     binding = cpo.bindQueue(jmsDestination.getName(), q);
+                     binding = cpo.bindQueue(topicCond, q);
                   }
                }
             }
@@ -312,7 +311,7 @@
 
                String name = MessageQueueNameHelper.createSubscriptionName(clientID, subscriptionName);
 
-               binding = topicPostOffice.getBindingForQueueName(name);
+               binding = postOffice.getBindingForQueueName(name);
 
                if (binding == null)
                {
@@ -323,7 +322,7 @@
                   QueuedExecutor executor = (QueuedExecutor)pool.get();
                   PagingFilteredQueue q;
 
-                  if (topicPostOffice.isLocal())
+                  if (postOffice.isLocal())
                   {
                      q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
                                                  executor, selector,
@@ -331,25 +330,25 @@
                                                  mDest.getPageSize(),
                                                  mDest.getDownCacheSize());
 
-                     binding = topicPostOffice.bindQueue(jmsDestination.getName(), q);
+                     binding = postOffice.bindQueue(topicCond, q);
                   }
                   else
                   {
-                     q = new LocalClusteredQueue(topicPostOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                     q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
                                                  executor, selector, tr,
                                                  mDest.getFullSize(),
                                                  mDest.getPageSize(),
                                                  mDest.getDownCacheSize());
 
-                     ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                     ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                      if (mDest.isClustered())
                      {
-                        binding = cpo.bindClusteredQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                        binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
                      }
                      else
                      {
-                        binding = cpo.bindQueue(jmsDestination.getName(), q);
+                        binding = cpo.bindQueue(topicCond, q);
                      }
                   }
                }
@@ -385,15 +384,15 @@
 
                      // Unbind the durable subscription
 
-                     if (mDest.isClustered() && !topicPostOffice.isLocal())
+                     if (mDest.isClustered() && !postOffice.isLocal())
                      {
-                        ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                        ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                         cpo.unbindClusteredQueue(name);
                      }
                      else
                      {
-                        topicPostOffice.unbindQueue(name);
+                        postOffice.unbindQueue(name);
                      }
 
                      // create a fresh new subscription
@@ -401,32 +400,32 @@
                      QueuedExecutor executor = (QueuedExecutor)pool.get();
                      PagingFilteredQueue q;
 
-                     if (topicPostOffice.isLocal())
+                     if (postOffice.isLocal())
                      {
                         q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
                                                     executor, selector,
                                                     mDest.getFullSize(),
                                                     mDest.getPageSize(),
                                                     mDest.getDownCacheSize());
-                        binding = topicPostOffice.bindQueue(jmsDestination.getName(), q);
+                        binding = postOffice.bindQueue(topicCond, q);
                      }
                      else
                      {
-                        q = new LocalClusteredQueue(topicPostOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                        q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
                                                     executor, selector, tr,
                                                     mDest.getFullSize(),
                                                     mDest.getPageSize(),
                                                     mDest.getDownCacheSize());
 
-                        ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                        ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                         if (mDest.isClustered())
                         {
-                           binding = cpo.bindClusteredQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                           binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
                         }
                         else
                         {
-                           binding = cpo.bindQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                           binding = cpo.bindQueue(topicCond, (LocalClusteredQueue)q);
                         }
                      }
                   }
@@ -438,7 +437,7 @@
             //Consumer on a jms queue
 
             //Let's find the binding
-            binding = queuePostOffice.getBindingForQueueName(jmsDestination.getName());
+            binding = postOffice.getBindingForQueueName(jmsDestination.getName());
 
             if (binding == null)
             {
@@ -495,7 +494,7 @@
             throw new InvalidDestinationException("No such destination: " + jmsDestination);
          }
          
-         Binding binding = queuePostOffice.getBindingForQueueName(jmsDestination.getName()); // todo
+         Binding binding = postOffice.getBindingForQueueName(jmsDestination.getName()); // todo
          
    	   int browserID = connectionEndpoint.getServerPeer().getNextObjectID();
    	   
@@ -729,12 +728,10 @@
             
             PagingFilteredQueue q = 
                new PagingFilteredQueue(dest.getName(), idm.getId(), ms, pm, true, false,
-                                       executor, null, fullSize, pageSize, downCacheSize);
+                                       executor, null, fullSize, pageSize, downCacheSize);                        
             
-            
-            
             //Make a binding for this queue
-            queuePostOffice.bindQueue(dest.getName(), q);
+            postOffice.bindQueue(new JMSCondition(true, dest.getName()), q);
          }         
       }
       catch (Throwable t)
@@ -767,12 +764,12 @@
          if (dest.isQueue())
          {
             //Unbind
-            queuePostOffice.unbindQueue(dest.getName());
+            postOffice.unbindQueue(dest.getName());
          }
          else
          {
             //Topic            
-            Collection bindings = topicPostOffice.listBindingsForCondition(dest.getName());
+            Collection bindings = postOffice.listBindingsForCondition(new JMSCondition(false, dest.getName()));
             
             if (!bindings.isEmpty())
             {
@@ -814,7 +811,7 @@
          
          String queueName = MessageQueueNameHelper.createSubscriptionName(clientID, subscriptionName);
          
-         Binding binding = topicPostOffice.getBindingForQueueName(queueName);
+         Binding binding = postOffice.getBindingForQueueName(queueName);
          
          if (binding == null)
          {
@@ -836,19 +833,24 @@
          }
          
          //Look up the topic
-         ManagedDestination mDest = dm.getDestination(binding.getCondition(), false);
          
+         JMSCondition topicCond = (JMSCondition)binding.getCondition();
+         
+         String topicName = topicCond.getName();
+         
+         ManagedDestination mDest = dm.getDestination(topicName, false);
+         
          //Unbind it
     
-         if (mDest.isClustered() && !topicPostOffice.isLocal())
+         if (mDest.isClustered() && !postOffice.isLocal())
          {
-            ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+            ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
             
             cpo.unbindClusteredQueue(queueName);
          }
          else
          {         
-            topicPostOffice.unbindQueue(queueName);
+            postOffice.unbindQueue(queueName);
          }
       }
       catch (Throwable t)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -24,10 +24,12 @@
 import javax.management.ObjectName;
 import javax.transaction.TransactionManager;
 import org.jboss.jms.selector.SelectorFactory;
+import org.jboss.jms.server.JMSConditionFactory;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.messaging.core.FilterFactory;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.MessagingComponent;
@@ -250,13 +252,15 @@
 
          ClusterRouterFactory rf = (ClusterRouterFactory)clazz.newInstance();
 
+         ConditionFactory cf = new JMSConditionFactory();
+                  
          FilterFactory ff = new SelectorFactory();
          FailoverMapper mapper = new DefaultFailoverMapper();
 
          postOffice =  new DefaultClusteredPostOffice(ds, tm, sqlProperties,
                                                       createTablesOnStartup,
                                                       nodeId, officeName, ms,
-                                                      pm, tr, ff, pool,
+                                                      pm, tr, ff, cf, pool,
                                                       groupName,
                                                       syncChannelConfig,
                                                       asyncChannelConfig,

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -25,10 +25,12 @@
 import javax.transaction.TransactionManager;
 
 import org.jboss.jms.selector.SelectorFactory;
+import org.jboss.jms.server.JMSConditionFactory;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.messaging.core.FilterFactory;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -135,10 +137,12 @@
          int nodeId = serverPeer.getServerPeerID();
          
          FilterFactory ff = new SelectorFactory();
+         
+         ConditionFactory cf = new JMSConditionFactory();
                
          postOffice = new DefaultPostOffice(ds, tm, sqlProperties,
                                          createTablesOnStartup,
-                                         nodeId, officeName, ms, pm, tr, ff, pool);
+                                         nodeId, officeName, ms, pm, tr, ff, cf, pool);
          
          postOffice.start();
          

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -48,7 +48,7 @@
     * @return
     * @throws Exception
     */
-   Binding bindClusteredQueue(String condition, LocalClusteredQueue queue) throws Exception;
+   Binding bindClusteredQueue(Condition condition, LocalClusteredQueue queue) throws Exception;
 
    /**
     * Unbind a clustered queue from the post office
@@ -58,7 +58,7 @@
     */
    Binding unbindClusteredQueue(String queueName) throws Throwable;
 
-   Collection listAllBindingsForCondition(String condition) throws Exception;
+   Collection listAllBindingsForCondition(Condition condition) throws Exception;
 
    Binding getBindingforChannelId(long channelId) throws Exception;
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -51,10 +51,9 @@
 public interface PostOffice extends MessagingComponent
 {
    String getOfficeName();
+   
+   Binding bindQueue(Condition condition, Queue queue) throws Exception;
 
-   Binding bindQueue(String condition, Queue queue) throws Exception;
-
-
    Binding unbindQueue(String queueName) throws Throwable;
 
    /**
@@ -63,7 +62,7 @@
     * @return
     * @throws Exception
     */
-   Collection listBindingsForCondition(String condition) throws Exception;
+   Collection listBindingsForCondition(Condition condition) throws Exception;
    
    /**
     * Get the binding for the specified queue name
@@ -83,7 +82,11 @@
     * @return true if ref was accepted by at least one queue
     * @throws Exception
     */
-   boolean route(MessageReference ref, String condition, Transaction tx) throws Exception;   
+   boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception; 
    
+   /**
+    * 
+    * @return true if it is a non clustered post office
+    */
    boolean isLocal();
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -22,6 +22,7 @@
 package org.jboss.messaging.core.plugin.postoffice;
 
 import org.jboss.messaging.core.Queue;
+import org.jboss.messaging.core.plugin.contract.Condition;
 
 /**
  * A Binding
@@ -36,7 +37,7 @@
 {
    public int getNodeId();
    
-   public String getCondition();
+   public Condition getCondition();
    
    public Queue getQueue();
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -22,6 +22,7 @@
 package org.jboss.messaging.core.plugin.postoffice;
 
 import org.jboss.messaging.core.Queue;
+import org.jboss.messaging.core.plugin.contract.Condition;
 
 /**
  * 
@@ -37,7 +38,7 @@
 {
    private int nodeId;
    
-   private String condition;
+   private Condition condition;
    
    private Queue queue;
 
@@ -47,7 +48,7 @@
    {
    }
 
-   public DefaultBinding(int nodeId, String condition, Queue queue, boolean failed)
+   public DefaultBinding(int nodeId, Condition condition, Queue queue, boolean failed)
    {
       this.nodeId = nodeId;
 
@@ -63,7 +64,7 @@
       return nodeId;
    }
 
-   public String getCondition()
+   public Condition getCondition()
    {
       return condition;
    }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,30 +21,45 @@
  */
 package org.jboss.messaging.core.plugin.postoffice;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
-import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
 import java.io.PrintWriter;
 import java.io.StringWriter;
 import java.sql.Connection;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
 import java.sql.Types;
-import java.util.*;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
+
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.*;
+import org.jboss.messaging.core.Delivery;
+import org.jboss.messaging.core.Filter;
+import org.jboss.messaging.core.FilterFactory;
+import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.JDBCSupport;
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
+
 /**
  * 
  * A DefaultPostOffice
@@ -84,6 +99,8 @@
    
    protected FilterFactory filterFactory;
    
+   protected ConditionFactory conditionFactory;
+   
    protected QueuedExecutorPool pool;
    
    public DefaultPostOffice()
@@ -95,6 +112,7 @@
                          int nodeId, String officeName, MessageStore ms,
                          PersistenceManager pm,
                          TransactionRepository tr, FilterFactory filterFactory,
+                         ConditionFactory conditionFactory,
                          QueuedExecutorPool pool)
    {            
       super (ds, tm, sqlProperties, createTablesOnStartup);
@@ -117,6 +135,8 @@
       
       this.filterFactory = filterFactory;
       
+      this.conditionFactory = conditionFactory;
+      
       this.pool = pool;
    }
    
@@ -154,7 +174,7 @@
       return officeName;
    }
          
-   public Binding bindQueue(String condition, Queue queue) throws Exception
+   public Binding bindQueue(Condition condition, Queue queue) throws Exception
    {
       if (trace) { log.trace(this + " binding queue " + queue.getName() + " with condition " + condition); }
       
@@ -237,15 +257,12 @@
       }
    }   
    
-   public Collection listBindingsForCondition(String condition) throws Exception
+   public Collection listBindingsForCondition(Condition condition) throws Exception
    {
       return listBindingsForConditionInternal(condition, true);
    }  
    
-   
-         
-   
-    public Binding getBindingForQueueName(String queueName) throws Exception
+   public Binding getBindingForQueueName(String queueName) throws Exception
    {
       if (queueName == null)
       {
@@ -283,13 +300,8 @@
       return binding;
    }
 
-   public void recover() throws Exception
+   public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
    {
-      //NOOP
-   }
-   
-   public boolean route(MessageReference ref, String condition, Transaction tx) throws Exception
-   {
       if (trace) { log.trace(this + "  routing ref " + ref + " with condition " + condition + " and transaction " + tx); }
             
       if (ref == null)
@@ -377,7 +389,7 @@
      
    // Protected -----------------------------------------------------
    
-   protected Collection listBindingsForConditionInternal(String condition, boolean localOnly) throws Exception
+   protected Collection listBindingsForConditionInternal(Condition condition, boolean localOnly) throws Exception
    {
       if (condition == null)
       {
@@ -448,7 +460,7 @@
             
             String queueName = rs.getString(2);
             
-            String condition = rs.getString(3);
+            String conditionText = rs.getString(3);
             
             String selector = rs.getString(4);
             
@@ -461,9 +473,12 @@
 
             boolean failed = rs.getString(6).equals("Y");
 
-            log.info("PostOffice " + this.officeName + " nodeId=" + nodeId + " condition=" + condition + " queueName=" + queueName + " channelId=" + channelId + " selector=" + selector);
+            log.info("PostOffice " + this.officeName + " nodeId=" + nodeId + " condition=" + conditionText + " queueName=" + queueName + " channelId=" + channelId + " selector=" + selector);
                                              
+            Condition condition = conditionFactory.createCondition(conditionText);
+            
             Binding binding = this.createBinding(nodeId, condition, queueName, channelId, selector, true, failed);
+            
             binding.getQueue().deactivate();
             
             addBinding(binding);
@@ -489,35 +504,35 @@
       }
    }
    
-   protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, String filterString, boolean durable, boolean failed) throws Exception
+   protected Binding createBinding(int nodeId, Condition condition, String queueName, long channelId, String filterString, boolean durable, boolean failed) throws Exception
    {      
       
       Filter filter = filterFactory.createFilter(filterString);
-
-       return createBinding(nodeId, condition, queueName, channelId, filter, durable, failed);
+      
+      return createBinding(nodeId, condition, queueName, channelId, filter, durable, failed);
    }
-
-    protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
-    {
-        Queue queue;
-        if (nodeId == this.currentNodeId)
-        {
-           QueuedExecutor executor = (QueuedExecutor)pool.get();
-
-           queue = new PagingFilteredQueue(queueName, channelId, ms, pm, true,
-                                           true, executor, filter);
-        }
-        else
-        {
-           throw new IllegalStateException("This is a non clustered post office - should not have bindings from different nodes!");
-        }
-
-        Binding binding = new DefaultBinding(nodeId, condition, queue, failed);
-
-        return binding;
-
-    }
-          
+   
+   protected Binding createBinding(int nodeId, Condition condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
+   {
+      Queue queue;
+      if (nodeId == this.currentNodeId)
+      {
+         QueuedExecutor executor = (QueuedExecutor)pool.get();
+         
+         queue = new PagingFilteredQueue(queueName, channelId, ms, pm, true,
+                  true, executor, filter);
+      }
+      else
+      {
+         throw new IllegalStateException("This is a non clustered post office - should not have bindings from different nodes!");
+      }
+      
+      Binding binding = new DefaultBinding(nodeId, condition, queue, failed);
+      
+      return binding;
+      
+   }
+   
    protected void insertBinding(Binding binding) throws Exception
    {
       Connection conn = null;
@@ -535,7 +550,7 @@
          ps.setString(1, this.officeName);
          ps.setInt(2, this.currentNodeId);
          ps.setString(3, binding.getQueue().getName());
-         ps.setString(4, binding.getCondition());         
+         ps.setString(4, binding.getCondition().toText());         
          if (filterString != null)
          {
             ps.setString(5, filterString);
@@ -711,7 +726,7 @@
    
    protected void addToConditionMap(Binding binding)
    {
-      String condition = binding.getCondition();
+      Condition condition = binding.getCondition();
       
       Bindings bindings = (Bindings)conditionMap.get(condition);
       

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -43,16 +43,16 @@
    {      
    }
    
-   BindRequest(int nodeId, String queueName, String condition, String filterString,
+   BindRequest(int nodeId, String queueName, String conditionText, String filterString,
                long channelId, boolean durable, boolean failed)
    {
-      bindingInfo = new BindingInfo(nodeId, queueName, condition, filterString,
+      bindingInfo = new BindingInfo(nodeId, queueName, conditionText, filterString,
                                     channelId, durable, failed);
    }
 
    Object execute(PostOfficeInternal office) throws Exception
    {
-      office.addBindingFromCluster(bindingInfo.getNodeId(), bindingInfo.getQueueName(), bindingInfo.getCondition(),
+      office.addBindingFromCluster(bindingInfo.getNodeId(), bindingInfo.getQueueName(), bindingInfo.getConditionText(),
                                    bindingInfo.getFilterString(), bindingInfo.getChannelId(), bindingInfo.isDurable(),
                                    bindingInfo.isFailed());
       return null;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -42,7 +42,7 @@
    
    private String queueName;   
    
-   private String condition;   
+   private String conditionText;   
    
    private String filterString; 
    
@@ -56,14 +56,14 @@
    {      
    }
    
-   BindingInfo(int nodeId, String queueName, String condition, String filterString,
+   BindingInfo(int nodeId, String queueName, String conditionText, String filterString,
                long channelId, boolean durable, boolean failed)
    {
       this.nodeId = nodeId;
       
       this.queueName = queueName;
       
-      this.condition = condition;
+      this.conditionText = conditionText;
       
       this.filterString = filterString;
       
@@ -76,7 +76,7 @@
 
    public void execute(PostOfficeInternal office) throws Exception
    {
-      office.addBindingFromCluster(nodeId, queueName, condition,
+      office.addBindingFromCluster(nodeId, queueName, conditionText,
                                    filterString, channelId, durable, failed);
       
    }
@@ -87,7 +87,7 @@
       
       queueName = in.readUTF();
       
-      condition = in.readUTF();
+      conditionText = in.readUTF();
       
       filterString = (String)StreamUtils.readObject(in, false);   
       
@@ -102,7 +102,7 @@
       
       out.writeUTF(queueName);
       
-      out.writeUTF(condition);
+      out.writeUTF(conditionText);
       
       StreamUtils.writeObject(out, filterString, false, false);
       
@@ -116,9 +116,9 @@
       return channelId;
    }
 
-   String getCondition()
+   String getConditionText()
    {
-      return condition;
+      return conditionText;
    }
 
    boolean isDurable()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -27,6 +27,7 @@
 
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Message;
+import org.jboss.messaging.core.plugin.contract.Condition;
 import org.jboss.messaging.core.tx.TransactionException;
 import org.jboss.messaging.core.tx.TxCallback;
 
@@ -120,7 +121,7 @@
     */
    private long checkChannelID;
    
-   void addMessage(String routingKey, Message message, Map queueNameToNodeIdMap,
+   void addMessage(Condition routingKey, Message message, Map queueNameToNodeIdMap,
                    int lastNodeId, long channelID)
    {
       //If we only ever send messages to the same node for this tx, then we can unicast rather than multicast
@@ -141,7 +142,7 @@
          }
       }
       
-      MessageHolder holder = new MessageHolder(routingKey, message, queueNameToNodeIdMap);
+      MessageHolder holder = new MessageHolder(routingKey.toText(), message, queueNameToNodeIdMap);
       
       if (message.isReliable())
       {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,7 +21,6 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.io.ByteArrayInputStream;
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
@@ -41,9 +40,11 @@
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
+
 import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
+
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
@@ -52,6 +53,8 @@
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -76,6 +79,8 @@
 import org.jgroups.blocks.RequestHandler;
 import org.w3c.dom.Element;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * 
  * A DefaultClusteredPostOffice
@@ -177,6 +182,7 @@
                                      PersistenceManager pm,
                                      TransactionRepository tr,
                                      FilterFactory filterFactory,
+                                     ConditionFactory conditionFactory,
                                      QueuedExecutorPool pool,
                                      String groupName,
                                      Element syncChannelConfig,
@@ -189,7 +195,7 @@
       throws Exception
    {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
-           pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
+           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
            rf, failoverMapper, statsSendPeriod);
 
       this.syncChannelConfigElement = syncChannelConfig;
@@ -209,6 +215,7 @@
                                      PersistenceManager pm,
                                      TransactionRepository tr,
                                      FilterFactory filterFactory,
+                                     ConditionFactory conditionFactory,
                                      QueuedExecutorPool pool,
                                      String groupName,
                                      String syncChannelConfig,
@@ -220,7 +227,7 @@
                                      long statsSendPeriod) throws Exception
    {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
-           pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
+           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
            rf, failoverMapper, statsSendPeriod);
 
       this.syncChannelConfig = syncChannelConfig;
@@ -237,6 +244,7 @@
                                       PersistenceManager pm,
                                       TransactionRepository tr,
                                       FilterFactory filterFactory,
+                                      ConditionFactory conditionFactory,
                                       QueuedExecutorPool pool,
                                       String groupName,
                                       long stateTimeout, long castTimeout,
@@ -246,7 +254,7 @@
                                       long statsSendPeriod)
    {
       super (ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms, pm, tr,
-             filterFactory, pool);
+             filterFactory, conditionFactory, pool);
 
       this.groupName = groupName;
 
@@ -410,7 +418,7 @@
 
    // ClusteredPostOffice implementation ----------------------------
 
-   public Binding bindClusteredQueue(String condition, LocalClusteredQueue queue) throws Exception
+   public Binding bindClusteredQueue(Condition condition, LocalClusteredQueue queue) throws Exception
    {
       if (trace)
       {
@@ -431,11 +439,11 @@
       return binding;
    }
 
-   private void sendBindRequest(String condition, LocalClusteredQueue queue, Binding binding)
+   private void sendBindRequest(Condition condition, LocalClusteredQueue queue, Binding binding)
       throws Exception
    {
       BindRequest request =
-         new BindRequest(this.currentNodeId, queue.getName(), condition, queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
+         new BindRequest(this.currentNodeId, queue.getName(), condition.toText(), queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
                          binding.getQueue().getChannelID(), queue.isRecoverable(), binding.isFailed());
 
       syncSendRequest(request);
@@ -457,7 +465,7 @@
       return binding;
    }
 
-   public boolean route(MessageReference ref, String condition, Transaction tx) throws Exception
+   public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
    {
       if (trace)
       {
@@ -595,14 +603,14 @@
                      if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
 
                      //Unicast - only one node is interested in the message
-                     asyncSendRequest(new MessageRequest(condition, ref.getMessage(), null), lastNodeId);
+                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), null), lastNodeId);
                   }
                   else
                   {
                      if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
 
                      //Multicast - more than one node is interested
-                     asyncSendRequest(new MessageRequest(condition, ref.getMessage(), queueNameNodeIdMap));
+                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), queueNameNodeIdMap));
                   }
                }
                else
@@ -651,7 +659,7 @@
       return false;
    }
 
-   public Collection listAllBindingsForCondition(String condition) throws Exception
+   public Collection listAllBindingsForCondition(Condition condition) throws Exception
    {
       return listBindingsForConditionInternal(condition, false);
    }
@@ -807,7 +815,7 @@
    /*
     * Called when another node adds a binding
     */
-   public void addBindingFromCluster(int nodeId, String queueName, String condition,
+   public void addBindingFromCluster(int nodeId, String queueName, String conditionText,
                                      String filterString, long channelID, boolean durable, boolean failed)
       throws Exception
    {
@@ -815,9 +823,12 @@
 
       if (trace)
       {
-         log.info(this.currentNodeId + " adding binding from node: " + nodeId + " queue: " + queueName + " with condition: " + condition);
+         log.info(this.currentNodeId + " adding binding from node: " + nodeId +
+                  " queue: " + queueName + " with condition: " + conditionText);
       }
 
+      Condition condition = conditionFactory.createCondition(conditionText);
+            
       try
       {
          //Sanity
@@ -839,7 +850,8 @@
 
          if (binding != null && failed)
          {
-            throw new IllegalArgumentException(this.currentNodeId + " Binding already exists for node Id " + nodeId + " queue name " + queueName);
+            throw new IllegalArgumentException(this.currentNodeId +
+                     " Binding already exists for node Id " + nodeId + " queue name " + queueName);
          }
 
          binding = this.createBinding(nodeId, condition, queueName, channelID, filterString, durable, failed);
@@ -880,22 +892,22 @@
       }
    }
 
-   public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKey,
+   public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKeyText,
                                 Map queueNameNodeIdMap) throws Exception
    {
       if (trace)
       {
          log.trace(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
-                  routingKey + " map " + queueNameNodeIdMap);
+                  routingKeyText + " map " + queueNameNodeIdMap);
       }
 
       log.info(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
-               routingKey + " map " + queueNameNodeIdMap);
+               routingKeyText + " map " + queueNameNodeIdMap);
 
+      Condition routingKey = conditionFactory.createCondition(routingKeyText);
+            
+      lock.readLock().acquire();  
 
-
-      lock.readLock().acquire();
-
       // Need to reference the message
       MessageReference ref = null;
       try
@@ -1771,7 +1783,7 @@
 
    protected void addToConditionMap(Binding binding)
    {
-      String condition = binding.getCondition();
+      Condition condition = binding.getCondition();
 
       ClusteredBindings bindings = (ClusteredBindings)conditionMap.get(condition);
 
@@ -1877,7 +1889,7 @@
       }
    }
 
-   protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
+   protected Binding createBinding(int nodeId, Condition condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
    {
       Queue queue;
       if (nodeId == this.currentNodeId)
@@ -2121,7 +2133,7 @@
             Queue queue = binding.getQueue();
 
             BindingInfo info = new BindingInfo(binding.getNodeId(), queue.getName(),
-                                               binding.getCondition(),
+                                               binding.getCondition().toText(),
                                                queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
                                                queue.getChannelID(),
                                                queue.isRecoverable(),
@@ -2166,7 +2178,9 @@
       {
          BindingInfo info = (BindingInfo)iter.next();
 
-         Binding binding = this.createBinding(info.getNodeId(), info.getCondition(), info.getQueueName(), info.getChannelId(),
+         Condition condition = conditionFactory.createCondition(info.getConditionText());
+         
+         Binding binding = this.createBinding(info.getNodeId(), condition, info.getQueueName(), info.getChannelId(),
                                               info.getFilterString(), info.isDurable(),info.isFailed());
 
          if (binding.getNodeId() == this.currentNodeId)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -41,7 +41,7 @@
  */
 class MessageHolder implements Streamable
 {
-   private String routingKey;
+   private String routingKeyText;
    
    private Message message;
    
@@ -51,9 +51,9 @@
    {      
    }
    
-   MessageHolder(String routingKey, Message message, Map queueNameToNodeIdMap)
+   MessageHolder(String routingKeyText, Message message, Map queueNameToNodeIdMap)
    {
-      this.routingKey = routingKey;
+      this.routingKeyText = routingKeyText;
       
       this.message = message;
       
@@ -62,7 +62,7 @@
    
    String getRoutingKey()
    {
-      return routingKey;
+      return routingKeyText;
    }
    
    Message getMessage()
@@ -77,7 +77,7 @@
 
    public void read(DataInputStream in) throws Exception
    {
-      routingKey = in.readUTF();
+      routingKeyText = in.readUTF();
       
       byte type = in.readByte();
         
@@ -89,7 +89,7 @@
 
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeUTF(routingKey);
+      out.writeUTF(routingKeyText);
       
       out.writeByte(message.getType());      
       message.write(out);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -44,7 +44,7 @@
 {
    static final int TYPE = 3;
    
-   private String routingKey;   
+   private String routingConditionText;   
    
    private Message message;
    
@@ -54,9 +54,9 @@
    {      
    }
    
-   MessageRequest(String routingKey, Message message, Map queueNameNodeIdMap)
+   MessageRequest(String routingConditionText, Message message, Map queueNameNodeIdMap)
    {
-      this.routingKey = routingKey;
+      this.routingConditionText = routingConditionText;
       
       this.message = message;
       
@@ -65,7 +65,7 @@
    
    Object execute(PostOfficeInternal office) throws Exception
    {
-      office.routeFromCluster(message, routingKey, queueNameNodeIdMap);      
+      office.routeFromCluster(message, routingConditionText, queueNameNodeIdMap);      
       return null;
    }  
    
@@ -76,7 +76,7 @@
    
    public void read(DataInputStream in) throws Exception
    {
-      routingKey = in.readUTF();
+      routingConditionText = in.readUTF();
       
       byte type = in.readByte();
       message = MessageFactory.createMessage(type);
@@ -87,7 +87,7 @@
 
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeUTF(routingKey);
+      out.writeUTF(routingConditionText);
       
       out.writeByte(message.getType());      
       message.write(out);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -43,7 +43,7 @@
  */
 interface PostOfficeInternal extends ClusteredPostOffice
 {
-   void addBindingFromCluster(int nodeId, String queueName, String condition,
+   void addBindingFromCluster(int nodeId, String queueName, String conditionText,
                               String filterString, long channelId, boolean durable, boolean failed)
       throws Exception;
    
@@ -56,7 +56,7 @@
    
    boolean removeReplicantLocally(int nodeId, Serializable key) throws Exception;
    
-   void routeFromCluster(Message message, String routingKey, Map queueNameNodeIdMap) throws Exception;
+   void routeFromCluster(Message message, String routingKeyText, Map queueNameNodeIdMap) throws Exception;
    
    void asyncSendRequest(ClusterRequest request) throws Exception;
    

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleCondition.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleCondition.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleCondition.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -0,0 +1,72 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.messaging.core;
+
+import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.plugin.contract.Condition;
+
+/**
+ * A SimpleCondition
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class SimpleCondition implements Condition
+{
+   private String name;
+   
+   public SimpleCondition(String name)
+   {
+      this.name = name;
+   }
+
+   public boolean matches(Condition routingCondition, MessageReference ref)
+   {
+      return equals(routingCondition);            
+   }
+
+   public String toText()
+   {
+      return name;
+   }
+   
+   public boolean equals(Object other)
+   {
+      if (!(other instanceof SimpleCondition))
+      {
+         return false;
+      }
+      
+      SimpleCondition sother = (SimpleCondition)other;
+      
+      return sother.name.equals(this.name);
+   }
+   
+   public int hashCode()
+   {
+      return name.hashCode();
+   }
+
+}

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -0,0 +1,44 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.messaging.core;
+
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+
+/**
+ * A SimpleConditionFactory
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class SimpleConditionFactory implements ConditionFactory
+{
+
+   public Condition createCondition(String text) throws Exception
+   {
+      return new SimpleCondition(text);
+   }
+
+}

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -39,6 +39,8 @@
 import org.jboss.messaging.core.plugin.IdManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
@@ -46,6 +48,7 @@
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -85,6 +88,8 @@
    
    protected QueuedExecutorPool pool;
    
+   protected ConditionFactory conditionFactory;
+   
    // Constructors --------------------------------------------------
 
    public PostOfficeTestBase(String name)
@@ -121,6 +126,8 @@
       
       channelIdManager = new IdManager("CHANNEL_ID", 10, pm);
       channelIdManager.start();
+      
+      conditionFactory = new SimpleConditionFactory();
             
       log.debug("setup done");
    }
@@ -147,9 +154,11 @@
    {
       FilterFactory ff = new SimpleFilterFactory();
       
+      ConditionFactory cf= new SimpleConditionFactory();
+      
       DefaultPostOffice postOffice = 
          new DefaultPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                            sc.getPostOfficeSQLProperties(), true, 1, "Simple", ms, pm, tr, ff, pool);
+                            sc.getPostOfficeSQLProperties(), true, 1, "Simple", ms, pm, tr, ff, cf, pool);
       
       postOffice.start();      
       
@@ -261,7 +270,7 @@
    
    private static long msgCount;
    
-   protected List sendMessages(String condition, boolean persistent, PostOffice office, int num, Transaction tx) throws Exception
+   protected List sendMessages(String conditionText, boolean persistent, PostOffice office, int num, Transaction tx) throws Exception
    {
       List list = new ArrayList();
       
@@ -271,6 +280,8 @@
          
          MessageReference ref = ms.reference(msg);         
          
+         Condition condition = conditionFactory.createCondition(conditionText);
+         
          boolean routed = office.route(ref, condition, null);         
          
          assertTrue(routed);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,44 +21,23 @@
   */
 package org.jboss.test.messaging.core.plugin.postoffice;
 
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Iterator;
 import java.util.List;
 
-import javax.naming.InitialContext;
-import javax.sql.DataSource;
-import javax.transaction.TransactionManager;
-
 import org.jboss.jms.selector.Selector;
-import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.messaging.core.Filter;
-import org.jboss.messaging.core.FilterFactory;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
-import org.jboss.messaging.core.plugin.IdManager;
-import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
-import org.jboss.messaging.core.plugin.SimpleMessageStore;
-import org.jboss.messaging.core.plugin.contract.MessageStore;
-import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
-import org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice;
 import org.jboss.messaging.core.tx.Transaction;
-import org.jboss.messaging.core.tx.TransactionRepository;
-import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.core.SimpleCondition;
 import org.jboss.test.messaging.core.SimpleFilter;
-import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
-import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.test.messaging.tools.jmx.ServiceContainer;
 import org.jboss.test.messaging.util.CoreMessageFactory;
-import org.jboss.tm.TransactionManagerService;
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
@@ -124,12 +103,12 @@
          
          
          Binding binding1 =
-            office1.bindQueue("condition1", queue1);
+            office1.bindQueue(new SimpleCondition("condition1"), queue1);
          
          //Binding twice with the same name should fail      
          try
          {
-            Binding bindFail = office1.bindQueue("condition1", queue1);
+            Binding bindFail = office1.bindQueue(new SimpleCondition("condition1"), queue1);
             fail();
          }
          catch (IllegalArgumentException e)
@@ -141,7 +120,7 @@
          PagingFilteredQueue queue2 = new PagingFilteredQueue("nonDurableQueue", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
-            office1.bindQueue("condition2", queue2);
+            office1.bindQueue(new SimpleCondition("condition2"), queue2);
          
          //Check they're there
          
@@ -231,60 +210,60 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
-            office.bindQueue("condition1", queue1);
+            office.bindQueue(new SimpleCondition("condition1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            office.bindQueue("condition1", queue2);
+            office.bindQueue(new SimpleCondition("condition1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            office.bindQueue("condition1", queue3);
+            office.bindQueue(new SimpleCondition("condition1"), queue3);
          
          PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding4 =
-            office.bindQueue("condition1", queue4);
+            office.bindQueue(new SimpleCondition("condition1"), queue4);
          
          PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding5 =
-            office.bindQueue("condition2", queue5);
+            office.bindQueue(new SimpleCondition("condition2"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding6 =
-            office.bindQueue("condition2", queue6);
+            office.bindQueue(new SimpleCondition("condition2"), queue6);
          
          PagingFilteredQueue queue7 = new PagingFilteredQueue("queue7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding7 =
-            office.bindQueue("condition2", queue7);
+            office.bindQueue(new SimpleCondition("condition2"), queue7);
          
          PagingFilteredQueue queue8 = new PagingFilteredQueue("queue8", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding8 =
-            office.bindQueue("condition2", queue8);
+            office.bindQueue(new SimpleCondition("condition2"), queue8);
          
          
-         Collection bindings = office.listBindingsForCondition("dummy");
+         Collection bindings = office.listBindingsForCondition(new SimpleCondition("dummy"));
          assertNotNull(bindings);
          assertTrue(bindings.isEmpty());
          
          //We don't match on substrings
-         bindings = office.listBindingsForCondition("condition123");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition123"));
          assertNotNull(bindings);
          assertTrue(bindings.isEmpty());
          
          //We don't currently support hierarchies
-         bindings = office.listBindingsForCondition("condition1.subcondition");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition1.subcondition"));
          assertNotNull(bindings);
          assertTrue(bindings.isEmpty());
          
          //We currently just do an exact match
-         bindings = office.listBindingsForCondition("condition1");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -294,7 +273,7 @@
          assertEquivalent((Binding)iter.next(), binding3);
          assertEquivalent((Binding)iter.next(), binding4);
          
-         bindings = office.listBindingsForCondition("condition2");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition2"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -357,32 +336,32 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            postOffice.bindQueue("topic1", queue3);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
          PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding4 =
-            postOffice.bindQueue("topic2", queue4);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
          PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding5 =
-            postOffice.bindQueue("topic2", queue5);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding6 =
-            postOffice.bindQueue("topic2", queue6);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
       
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -412,7 +391,7 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, "topic1", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          List msgs = receiver1.getMessages();
@@ -450,7 +429,7 @@
          Message msg2 = CoreMessageFactory.createCoreMessage(2);      
          MessageReference ref2 = ms.reference(msg2);
          
-         routed = postOffice.route(ref2, "topic2", null);      
+         routed = postOffice.route(ref2, new SimpleCondition("topic2"), null);      
          assertTrue(routed);
          
          msgs = receiver1.getMessages();
@@ -509,7 +488,7 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding1 =
-            postOffice.bindQueue("condition1", queue1);
+            postOffice.bindQueue(new SimpleCondition("condition1"), queue1);
               
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -519,7 +498,7 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, "this won't match anything", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("this won't match anything"), null);      
          
          assertFalse(routed);
                
@@ -561,17 +540,17 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), filter);         
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            postOffice.bindQueue("topic1", queue3);   
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);   
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -582,15 +561,15 @@
          
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);         
-         boolean routed = postOffice.route(ref1, "topic1", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          Message msg2 = CoreMessageFactory.createCoreMessage(2);      
          MessageReference ref2 = ms.reference(msg2);         
-         routed = postOffice.route(ref2, "topic1", null);      
+         routed = postOffice.route(ref2, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          Message msg3 = CoreMessageFactory.createCoreMessage(3);      
          MessageReference ref3 = ms.reference(msg3);         
-         routed = postOffice.route(ref3, "topic1", null);      
+         routed = postOffice.route(ref3, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          List msgs = receiver1.getMessages();
@@ -663,32 +642,32 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            postOffice.bindQueue("topic1", queue3);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
          PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
          
          Binding binding4 =
-            postOffice.bindQueue("topic2", queue4);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
          PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
          
          Binding binding5 =
-            postOffice.bindQueue("topic2", queue5);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
          
          Binding binding6 =
-            postOffice.bindQueue("topic2", queue6);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
       
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -713,7 +692,7 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, "topic1", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          List msgs = receiver1.getMessages();
@@ -766,7 +745,7 @@
          Message msg2 = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);      
          MessageReference ref2 = ms.reference(msg2);
          
-         routed = postOffice.route(ref2, "topic2", null);      
+         routed = postOffice.route(ref2, new SimpleCondition("topic2"), null);      
          assertTrue(routed);
          
          msgs = receiver4.getMessages();
@@ -837,12 +816,12 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
           
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -861,9 +840,9 @@
          
          Transaction tx = tr.createTransaction();
          
-         boolean routed = postOffice.route(ref1, "topic1", tx);            
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
-         routed = postOffice.route(ref2, "topic1", tx);            
+         routed = postOffice.route(ref2, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
                
          List msgs = queue1.browse();
@@ -919,9 +898,9 @@
          
          tx = tr.createTransaction();
          
-         routed = postOffice.route(ref3, "topic1", tx);            
+         routed = postOffice.route(ref3, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
-         routed = postOffice.route(ref4, "topic1", tx);            
+         routed = postOffice.route(ref4, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
                
          msgs = queue1.browse();
@@ -953,9 +932,9 @@
          Message msg6 = CoreMessageFactory.createCoreMessage(6, persistentMessage, null);      
          MessageReference ref6 = ms.reference(msg6);
                
-         routed = postOffice.route(ref5, "topic1", null);            
+         routed = postOffice.route(ref5, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
-         routed = postOffice.route(ref6, "topic1", null);            
+         routed = postOffice.route(ref6, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
          
          msgs = receiver1.getMessages();
@@ -1020,9 +999,9 @@
          Message msg8 = CoreMessageFactory.createCoreMessage(8, persistentMessage, null);      
          MessageReference ref8 = ms.reference(msg8);
                
-         routed = postOffice.route(ref7, "topic1", null);            
+         routed = postOffice.route(ref7, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
-         routed = postOffice.route(ref8, "topic1", null);            
+         routed = postOffice.route(ref8, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
          
          msgs = receiver1.getMessages();

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -30,6 +30,7 @@
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
@@ -40,6 +41,8 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilter;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
@@ -157,17 +160,17 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);        
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
-            office1.bindClusteredQueue("topic1", queue2);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          //Start another office - make sure it picks up the bindings from the first node
          
          office2 = createClusteredPostOffice(2, "testgroup");
          
-         Collection bindings = office2.listAllBindingsForCondition("topic1");
+         Collection bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -180,11 +183,11 @@
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
 
          Binding binding3 =
-            office2.bindClusteredQueue("topic1", queue3);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
   
          //Make sure both nodes pick it up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -193,7 +196,7 @@
          assertEquivalent(binding2, (Binding)iter.next());
          assertEquivalent(binding3, (Binding)iter.next());
 
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -206,11 +209,11 @@
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 =
-            office2.bindClusteredQueue("topic1", queue4);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue4);
          
          // Make sure both nodes pick it up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -220,7 +223,7 @@
          assertEquivalent(binding3, (Binding)iter.next());
          assertEquivalent(binding4, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -236,7 +239,7 @@
          
          //Make sure bindings are not longer available on either node
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -244,7 +247,7 @@
          assertEquivalent(binding3, (Binding)iter.next());
          assertEquivalent(binding4, (Binding)iter.next());
    
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -258,7 +261,7 @@
          
          //Maks sure it picks up the bindings
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -271,11 +274,11 @@
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office3, 3, "sub5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding5 =
-            office3.bindClusteredQueue("topic1", queue5);
+            office3.bindClusteredQueue(new SimpleCondition("topic1"), queue5);
          
          // Make sure all nodes pick it up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -284,7 +287,7 @@
          assertEquivalent(binding4, (Binding)iter.next());
          assertEquivalent(binding5, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -293,7 +296,7 @@
          assertEquivalent(binding4, (Binding)iter.next());
          assertEquivalent(binding5, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -307,16 +310,16 @@
          LocalClusteredQueue queue6 = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          
          Binding binding6 =
-            office1.bindClusteredQueue("topic1", queue6);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue6);
          
          LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
          
          Binding binding7 =
-            office1.bindClusteredQueue("topic1", queue7);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue7);
          
          // Make sure all nodes pick them up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(5, bindings.size());
          
@@ -327,7 +330,7 @@
          assertEquivalent(binding6, (Binding)iter.next());
          assertEquivalent(binding7, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(5, bindings.size());
          
@@ -338,7 +341,7 @@
          assertEquivalent(binding6, (Binding)iter.next());
          assertEquivalent(binding7, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(5, bindings.size());
          
@@ -360,7 +363,7 @@
          //All it's non durable bindings should be removed from the other nodes
          //Durable bindings should remain
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -370,7 +373,7 @@
          assertEquivalent(binding5, (Binding)iter.next());
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -383,7 +386,7 @@
          //Stop office 2
          office2.stop();
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -396,7 +399,7 @@
          
          office2 = createClusteredPostOffice(2, "testgroup");
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -404,7 +407,7 @@
          assertEquivalent(binding5, (Binding)iter.next());
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -412,7 +415,7 @@
          assertEquivalent(binding5, (Binding)iter.next());
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -433,21 +436,21 @@
          
          //Only the durable queue should survive
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(1, bindings.size());
          
          iter = bindings.iterator();
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(1, bindings.size());
          
          iter = bindings.iterator();
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(1, bindings.size());
          
@@ -597,17 +600,17 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
 
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
 
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
 
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          try
          {
-            Binding binding3 = office1.bindClusteredQueue("queue1", queue3);
+            Binding binding3 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue3);
             fail();
          }
          catch (Exception e)
@@ -618,7 +621,7 @@
          
          try
          {
-            Binding binding4 = office2.bindClusteredQueue("queue1", queue4);
+            Binding binding4 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
             fail();
          }
          catch (Exception e)
@@ -632,12 +635,12 @@
 
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
-         Binding binding5 = office1.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);       
          try
          {
-            Binding binding6 = office1.bindQueue("queue1", queue6);
+            Binding binding6 = office1.bindQueue(new SimpleCondition("queue1"), queue6);
             fail();
          }
          catch (Exception e)
@@ -649,15 +652,15 @@
          
          //It should be possible to bind queues locally into a clustered post office
          LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding7 = office1.bindQueue("queue1", queue7);
+         Binding binding7 = office1.bindQueue(new SimpleCondition("queue1"), queue7);
          
          LocalClusteredQueue queue8 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);       
-         Binding binding8 = office2.bindQueue("queue1", queue8);
+         Binding binding8 = office2.bindQueue(new SimpleCondition("queue1"), queue8);
          
          LocalClusteredQueue queue9 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);       
          try
          {
-            Binding binding9 = office1.bindQueue("queue1", queue9);
+            Binding binding9 = office1.bindQueue(new SimpleCondition("queue1"), queue9);
             fail();
          }
          catch (Exception e)
@@ -700,15 +703,15 @@
       
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter1, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter2, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("topic1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "queue3", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding3 =
-            office2.bindClusteredQueue("topic1", queue3);   
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue3);   
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -719,17 +722,17 @@
          
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);  
-         boolean routed = office1.route(ref1, "topic1", null);   
+         boolean routed = office1.route(ref1, new SimpleCondition("topic1"), null);   
          assertTrue(routed);
          
          
          Message msg2 = CoreMessageFactory.createCoreMessage(2);      
          MessageReference ref2 = ms.reference(msg2);         
-         routed = office1.route(ref2, "topic1", null);      
+         routed = office1.route(ref2, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          Message msg3 = CoreMessageFactory.createCoreMessage(3);      
          MessageReference ref3 = ms.reference(msg3);         
-         routed = office1.route(ref3, "topic1", null);      
+         routed = office1.route(ref3, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -808,52 +811,52 @@
          Binding[] bindings = new Binding[16];
          
          queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[0] = office1.bindClusteredQueue("topic1", queues[0]);
+         bindings[0] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[0]);
          
          queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[1] = office1.bindClusteredQueue("topic1", queues[1]);
+         bindings[1] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[1]);
          
          queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[2] = office2.bindClusteredQueue("topic1", queues[2]);
+         bindings[2] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[2]);
          
          queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[3] = office2.bindClusteredQueue("topic1", queues[3]);
+         bindings[3] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[3]);
          
          queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[4] = office2.bindClusteredQueue("topic1", queues[4]);
+         bindings[4] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[4]);
          
          queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[5] = office1.bindClusteredQueue("topic1", queues[5]);
+         bindings[5] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[5]);
          
          queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[6] = office1.bindClusteredQueue("topic1", queues[6]);
+         bindings[6] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[6]);
          
          queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[7] = office1.bindClusteredQueue("topic1", queues[7]);
+         bindings[7] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[7]);
          
          queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[8] = office1.bindClusteredQueue("topic2", queues[8]);
+         bindings[8] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[8]);
          
          queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[9] = office1.bindClusteredQueue("topic2", queues[9]);
+         bindings[9] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[9]);
          
          queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[10] = office2.bindClusteredQueue("topic2", queues[10]);
+         bindings[10] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[10]);
          
          queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[11] = office2.bindClusteredQueue("topic2", queues[11]);
+         bindings[11] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[11]);
          
          queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[12] = office2.bindClusteredQueue("topic2", queues[12]);
+         bindings[12] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[12]);
          
          queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[13] = office1.bindClusteredQueue("topic2", queues[13]);
+         bindings[13] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[13]);
          
          queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[14] = office1.bindClusteredQueue("topic2", queues[14]);
+         bindings[14] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[14]);
          
          queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[15] = office1.bindClusteredQueue("topic2", queues[15]);
+         bindings[15] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[15]);
        
          SimpleReceiver[] receivers = new SimpleReceiver[16];
          
@@ -866,7 +869,7 @@
          Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref = ms.reference(msg);         
 
-         boolean routed = office1.route(ref, "topic1", null);         
+         boolean routed = office1.route(ref, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
          
          //Messages are sent asych so may take some finite time to arrive
@@ -901,7 +904,7 @@
          msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);;      
          ref = ms.reference(msg);         
 
-         routed = office1.route(ref, "topic2", null);         
+         routed = office1.route(ref, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
          //Messages are sent asych so may take some finite time to arrive
          Thread.sleep(1000);
@@ -998,27 +1001,27 @@
          //We don't deploy on node 6
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2); 
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2); 
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding3 = office3.bindClusteredQueue("queue1", queue3);
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding4 = office4.bindClusteredQueue("queue1", queue4); 
+         Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4); 
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding5 = office5.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
         
@@ -1026,7 +1029,7 @@
                           
          Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref = ms.reference(msg);         
-         boolean routed = office1.route(ref, "queue1", null);         
+         boolean routed = office1.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          checkContainsAndAcknowledge(msg, receiver1, queue1);
          this.checkEmpty(receiver2);
@@ -1036,7 +1039,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office2.route(ref, "queue1", null);         
+         routed = office2.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          checkContainsAndAcknowledge(msg, receiver2, queue2);
@@ -1046,7 +1049,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office3.route(ref, "queue1", null);         
+         routed = office3.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          this.checkEmpty(receiver2);
@@ -1056,7 +1059,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office4.route(ref, "queue1", null);         
+         routed = office4.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          this.checkEmpty(receiver2);
@@ -1066,7 +1069,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office5.route(ref, "queue1", null);         
+         routed = office5.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          this.checkEmpty(receiver2);         
@@ -1076,7 +1079,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office6.route(ref, "queue1", null);         
+         routed = office6.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          
          //The actual queue that receives the mesage is determined by the routing policy
@@ -1151,17 +1154,17 @@
          office3 = createClusteredPostOffice(3, "testgroup");
 
          LocalClusteredQueue sub1 = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding1 = office1.bindQueue("topic", sub1);
+         Binding binding1 = office1.bindQueue(new SimpleCondition("topic"), sub1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub1.add(receiver1);
          
          LocalClusteredQueue sub2 = new LocalClusteredQueue(office2, 2, "sub2", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding2 = office2.bindQueue("topic", sub2); 
+         Binding binding2 = office2.bindQueue(new SimpleCondition("topic"), sub2); 
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub2.add(receiver2);
          
          LocalClusteredQueue sub3 = new LocalClusteredQueue(office3, 3, "sub3", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding3 = office3.bindQueue("topic", sub3);
+         Binding binding3 = office3.bindQueue(new SimpleCondition("topic"), sub3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub3.add(receiver3);
          
@@ -1169,7 +1172,7 @@
          
          Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref = ms.reference(msg);         
-         boolean routed = office1.route(ref, "topic", null);         
+         boolean routed = office1.route(ref, new SimpleCondition("topic"), null);         
          assertTrue(routed);         
          Thread.sleep(500);         
          checkContainsAndAcknowledge(msg, receiver1, sub1);
@@ -1178,7 +1181,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office2.route(ref, "topic", null);         
+         routed = office2.route(ref, new SimpleCondition("topic"), null);         
          assertTrue(routed);                  
          Thread.sleep(500);
          this.checkEmpty(receiver1);
@@ -1187,7 +1190,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(3, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office3.route(ref, "topic", null);           
+         routed = office3.route(ref, new SimpleCondition("topic"), null);           
          assertTrue(routed);         
          Thread.sleep(500);
          this.checkEmpty(receiver1);         
@@ -1268,13 +1271,13 @@
          
          //Non durable 1 on node 2
          LocalClusteredQueue nonDurable1 = new LocalClusteredQueue(office2, 2, "nondurable1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding1 = office2.bindClusteredQueue("topic", nonDurable1);
+         Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), nonDurable1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable1.add(receiver1);
          
          //Non durable 2 on node 2
          LocalClusteredQueue nonDurable2 = new LocalClusteredQueue(office2, 2, "nondurable2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding2 = office2.bindClusteredQueue("topic", nonDurable2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("topic"), nonDurable2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable2.add(receiver2);
          
@@ -1283,13 +1286,13 @@
          
          //Non shared durable
          LocalClusteredQueue nonSharedDurable1 = new LocalClusteredQueue(office3, 3, "nonshareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding3 = office3.bindClusteredQueue("topic", nonSharedDurable1);
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("topic"), nonSharedDurable1);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonSharedDurable1.add(receiver3);
          
          //Non durable
          LocalClusteredQueue nonDurable3 = new LocalClusteredQueue(office3, 3, "nondurable3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding4 = office3.bindClusteredQueue("topic", nonDurable3);
+         Binding binding4 = office3.bindClusteredQueue(new SimpleCondition("topic"), nonDurable3);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable3.add(receiver4);
          
@@ -1298,31 +1301,31 @@
          
          //Shared durable
          LocalClusteredQueue sharedDurable1 = new LocalClusteredQueue(office4, 4, "shareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding5 = office4.bindClusteredQueue("topic", sharedDurable1);
+         Binding binding5 = office4.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable1);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable1.add(receiver5);
          
          //Non shared durable
          LocalClusteredQueue nonSharedDurable2 = new LocalClusteredQueue(office4, 4, "nonshareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding6 = office4.bindClusteredQueue("topic", nonSharedDurable2);
+         Binding binding6 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonSharedDurable2);
          SimpleReceiver receiver6 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonSharedDurable2.add(receiver6);
          
          //Non durable
          LocalClusteredQueue nonDurable4 = new LocalClusteredQueue(office4, 4, "nondurable4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding7 = office4.bindClusteredQueue("topic", nonDurable4);
+         Binding binding7 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable4);
          SimpleReceiver receiver7 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable4.add(receiver7);
          
          // Non durable
          LocalClusteredQueue nonDurable5 = new LocalClusteredQueue(office4, 4, "nondurable5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding8 = office4.bindClusteredQueue("topic", nonDurable5);
+         Binding binding8 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable5);
          SimpleReceiver receiver8 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable5.add(receiver8);
          
          //Non durable
          LocalClusteredQueue nonDurable6 = new LocalClusteredQueue(office4, 4, "nondurable6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding9 = office4.bindClusteredQueue("topic", nonDurable6);
+         Binding binding9 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable6);
          SimpleReceiver receiver9 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable6.add(receiver9);
          
@@ -1330,32 +1333,32 @@
          //=======
          //Shared durable
          LocalClusteredQueue sharedDurable2 = new LocalClusteredQueue(office5, 5, "shareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding10 = office5.bindClusteredQueue("topic", sharedDurable2);
+         Binding binding10 = office5.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable2);
          SimpleReceiver receiver10 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable2.add(receiver10);
          
          //Shared durable
          LocalClusteredQueue sharedDurable3 = new LocalClusteredQueue(office5, 5, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding11 = office5.bindClusteredQueue("topic", sharedDurable3);
+         Binding binding11 = office5.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable3);
          SimpleReceiver receiver11 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable3.add(receiver11);
          
          // Node 6
          //=========
          LocalClusteredQueue sharedDurable4 = new LocalClusteredQueue(office6, 6, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding12 = office6.bindClusteredQueue("topic", sharedDurable4);
+         Binding binding12 = office6.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable4);
          SimpleReceiver receiver12 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable4.add(receiver12);
          
          LocalClusteredQueue nonDurable7 = new LocalClusteredQueue(office6, 6, "nondurable7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding13 = office6.bindClusteredQueue("topic", nonDurable7);
+         Binding binding13 = office6.bindClusteredQueue(new SimpleCondition("topic"), nonDurable7);
          SimpleReceiver receiver13 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable7.add(receiver13);
          
          //Node 7
          //=======
          LocalClusteredQueue sharedDurable5 = new LocalClusteredQueue(office7, 7, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding14 = office7.bindClusteredQueue("topic", sharedDurable5);
+         Binding binding14 = office7.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable5);
          SimpleReceiver receiver14 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable5.add(receiver14);
          
@@ -1687,52 +1690,52 @@
          Binding[] bindings = new Binding[16];
          
          queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[0] = office1.bindClusteredQueue("topic1", queues[0]);
+         bindings[0] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[0]);
          
          queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[1] = office1.bindClusteredQueue("topic1", queues[1]);
+         bindings[1] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[1]);
          
          queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[2] = office2.bindClusteredQueue("topic1", queues[2]);
+         bindings[2] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[2]);
          
          queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[3] = office2.bindClusteredQueue("topic1", queues[3]);
+         bindings[3] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[3]);
          
          queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[4] = office2.bindClusteredQueue("topic1", queues[4]);
+         bindings[4] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[4]);
          
          queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[5] = office1.bindClusteredQueue("topic1", queues[5]);
+         bindings[5] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[5]);
          
          queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[6] = office1.bindClusteredQueue("topic1", queues[6]);
+         bindings[6] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[6]);
          
          queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[7] = office1.bindClusteredQueue("topic1", queues[7]);
+         bindings[7] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[7]);
          
          queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[8] = office1.bindClusteredQueue("topic2", queues[8]);
+         bindings[8] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[8]);
          
          queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[9] = office1.bindClusteredQueue("topic2", queues[9]);
+         bindings[9] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[9]);
          
          queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[10] = office2.bindClusteredQueue("topic2", queues[10]);
+         bindings[10] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[10]);
          
          queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[11] = office2.bindClusteredQueue("topic2", queues[11]);
+         bindings[11] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[11]);
          
          queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[12] = office2.bindClusteredQueue("topic2", queues[12]);
+         bindings[12] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[12]);
          
          queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[13] = office1.bindClusteredQueue("topic2", queues[13]);
+         bindings[13] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[13]);
          
          queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[14] = office1.bindClusteredQueue("topic2", queues[14]);
+         bindings[14] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[14]);
          
          queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[15] = office1.bindClusteredQueue("topic2", queues[15]);
+         bindings[15] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[15]);
 
          SimpleReceiver[] receivers = new SimpleReceiver[16];
          
@@ -1752,9 +1755,9 @@
          
          Transaction tx = tr.createTransaction();
 
-         boolean routed = office1.route(ref1, "topic1", tx);         
+         boolean routed = office1.route(ref1, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
 
          
@@ -1808,9 +1811,9 @@
          
          tx = tr.createTransaction();
 
-         routed = office1.route(ref1, "topic1", tx);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
          
          //Messages are sent asych so may take some finite time to arrive
@@ -1846,9 +1849,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic1", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
          
          //Messages are sent asych so may take some finite time to arrive
@@ -1914,9 +1917,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);;      
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic1", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -2005,9 +2008,9 @@
          
          tx = tr.createTransaction();
 
-         routed = office1.route(ref1, "topic2", tx);         
+         routed = office1.route(ref1, new SimpleCondition("topic2"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic2", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic2"), tx);         
          assertTrue(routed);
          
          
@@ -2062,9 +2065,9 @@
          
          tx = tr.createTransaction();
 
-         routed = office1.route(ref1, "topic1", tx);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
          
          for (int i = 0; i < 16; i++)
@@ -2097,9 +2100,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);      
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic2", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic2", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -2166,9 +2169,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);;      
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic2", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic2", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -2300,9 +2303,12 @@
       
       FailoverMapper mapper = new DefaultFailoverMapper();
       
+      ConditionFactory cf = new SimpleConditionFactory();
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId,
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,10 +21,11 @@
   */
 package org.jboss.test.messaging.core.plugin.postoffice.cluster;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.util.List;
+
 import org.jboss.messaging.core.FilterFactory;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
@@ -34,10 +35,14 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * 
  * A DefaultClusteredPostOfficeWithDefaultRouterTest
@@ -124,27 +129,27 @@
          office6 = createClusteredPostOffice(6, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office2.bindClusteredQueue("topic", queue1);
+         Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office3.bindClusteredQueue("topic", queue2);
+         Binding binding2 = office3.bindClusteredQueue(new SimpleCondition("topic"), queue2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office4.bindClusteredQueue("topic", queue3);
+         Binding binding3 = office4.bindClusteredQueue(new SimpleCondition("topic"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office5.bindClusteredQueue("topic", queue4);
+         Binding binding4 = office5.bindClusteredQueue(new SimpleCondition("topic"), queue4);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office6.bindClusteredQueue("topic", queue5);
+         Binding binding5 = office6.bindClusteredQueue(new SimpleCondition("topic"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
                
@@ -265,27 +270,27 @@
          office6 = createClusteredPostOffice(6, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office2.bindClusteredQueue("topic", queue1);
+         Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office3.bindClusteredQueue("topic", queue2);
+         Binding binding2 = office3.bindClusteredQueue(new SimpleCondition("topic"), queue2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office4.bindClusteredQueue("topic", queue3);
+         Binding binding3 = office4.bindClusteredQueue(new SimpleCondition("topic"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office5.bindClusteredQueue("topic", queue4);
+         Binding binding4 = office5.bindClusteredQueue(new SimpleCondition("topic"), queue4);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office6.bindClusteredQueue("topic", queue5);
+         Binding binding5 = office6.bindClusteredQueue(new SimpleCondition("topic"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
                
@@ -380,9 +385,12 @@
       
       FailoverMapper mapper = new DefaultFailoverMapper();
       
+      ConditionFactory cf = new SimpleConditionFactory();      
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId,
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -34,6 +34,7 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouter;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
@@ -46,6 +47,7 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.QueueStats;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
@@ -356,9 +358,12 @@
       
       FailoverMapper mapper = new DefaultFailoverMapper();
       
+      ConditionFactory cf = new SimpleConditionFactory();      
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, 
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,12 +21,13 @@
   */
 package org.jboss.test.messaging.core.plugin.postoffice.cluster;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.util.List;
+
 import org.jboss.messaging.core.FilterFactory;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
@@ -38,11 +39,15 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionException;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
 import org.jboss.test.messaging.util.CoreMessageFactory;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * 
  * A RecoveryTest
@@ -98,15 +103,15 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("topic1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding3 =
-            office3.bindClusteredQueue("topic1", queue3);
+            office3.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -129,7 +134,7 @@
             
             MessageReference ref = ms.reference(msg);  
             
-            office1.route(ref, "topic1", tx);
+            office1.route(ref, new SimpleCondition("topic1"), tx);
          }
          
          Thread.sleep(1000);
@@ -233,15 +238,15 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("topic1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding3 =
-            office3.bindClusteredQueue("topic1", queue3);
+            office3.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -264,7 +269,7 @@
             
             MessageReference ref = ms.reference(msg);  
             
-            office1.route(ref, "topic1", tx);
+            office1.route(ref, new SimpleCondition("topic1"), tx);
          }
          
          Thread.sleep(1000);
@@ -357,9 +362,12 @@
       
       FailoverMapper mapper = new DefaultFailoverMapper();
       
+      ConditionFactory cf = new SimpleConditionFactory();            
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered",
+                                 ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -21,11 +21,10 @@
   */
 package org.jboss.test.messaging.core.plugin.postoffice.cluster;
 
-import EDU.oswego.cs.dl.util.concurrent.Executor;
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+
 import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
@@ -35,6 +34,7 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
@@ -45,11 +45,16 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
 import org.jboss.test.messaging.util.CoreMessageFactory;
 
+import EDU.oswego.cs.dl.util.concurrent.Executor;
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * 
  * A RedistributionWithDefaultMessagePullPolicyTest
@@ -141,18 +146,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -235,18 +240,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -335,18 +340,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -431,18 +436,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -529,19 +534,19 @@
          office5 = (DefaultClusteredPostOffice)createClusteredPostOffice(5, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
                   
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                   
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office3.bindClusteredQueue("queue1", queue3);         
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);         
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office4.bindClusteredQueue("queue1", queue4);
+         Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
                   
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office5.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
                    
          final int NUM_MESSAGES = 100;
          
@@ -689,19 +694,19 @@
          office5 = (DefaultClusteredPostOffice)createClusteredPostOffice(5, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
                   
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                   
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office3.bindClusteredQueue("queue1", queue3);         
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);         
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office4.bindClusteredQueue("queue1", queue4);
+         Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
                   
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office5.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
                   
          final int NUM_MESSAGES = 100;
           
@@ -1148,9 +1153,12 @@
       
       FailoverMapper mapper = new DefaultFailoverMapper();
       
+      ConditionFactory cf = new SimpleConditionFactory();           
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId,
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -133,12 +133,15 @@
 
       conn.start();
 
-      TextMessage tm = (TextMessage)durable.receive();
+      TextMessage tm = (TextMessage)durable.receive(1000);
       assertEquals("k", tm.getText());
 
       Message m = durable.receive(1000);
       assertNull(m);
+      
+      conn.close();
    }
+      
 
    /**
     * JMS 1.1 6.11.1: A client can change an existing durable subscription by creating a durable
@@ -184,6 +187,8 @@
 
       ServerManagement.undeployTopic("CompletelyNewTopic");
       ServerManagement.undeployTopic("CompletelyNewTopic2");
+      
+      conn.close();
    }
 
    /**
@@ -258,6 +263,8 @@
       assertNull(m);
       
       ServerManagement.undeployTopic("CompletelyNewTopic2");
+      
+      conn.close();
    }
 
    /**
@@ -462,6 +469,8 @@
       {
          // OK
       }
+      
+      c.close();
    }
 
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -36,6 +36,7 @@
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
@@ -74,349 +75,348 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-//   public void testRoundRobinConnectionCreation() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//      
-//      log.info ("number of delegates = " + delegate.getDelegates().length);
-//      log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//      
-//      assertEquals(3, delegate.getDelegates().length);
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//      
-//      assertEquals(0, cf1.getServerId());
-//      
-//      assertEquals(1, cf2.getServerId());
-//      
-//      assertEquals(2, cf3.getServerId());
-//      
-//      assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//      
-//      Connection conn1 = null;
-//      
-//      Connection conn2 = null;
-//      
-//      Connection conn3 = null;
-//      
-//      Connection conn4 = null;
-//      
-//      Connection conn5 = null;
-//      
-//      try
-//      {         
-//         conn1 = factory.createConnection();
-//         
-//         conn2 = factory.createConnection();
-//         
-//         conn3 = factory.createConnection();
-//         
-//         conn4 = factory.createConnection();
-//         
-//         conn5 = factory.createConnection();
-//         
-//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-//         
-//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-//         
-//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-//         
-//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-//         
-//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-//         
-//         int serverID1 = state1.getServerID();
-//         
-//         int serverID2 = state2.getServerID();
-//         
-//         int serverID3 = state3.getServerID();
-//         
-//         int serverID4 = state4.getServerID();
-//         
-//         int serverID5 = state5.getServerID();
-//         
-//         log.info("server id 1: " + serverID1);
-//         
-//         log.info("server id 2: " + serverID2);
-//         
-//         log.info("server id 3: " + serverID3);
-//         
-//         log.info("server id 4: " + serverID4);
-//         
-//         log.info("server id 5: " + serverID5);
-//         
-//         assertEquals(0, serverID1);
-//         
-//         assertEquals(1, serverID2);
-//         
-//         assertEquals(2, serverID3);
-//         
-//         assertEquals(0, serverID4);
-//         
-//         assertEquals(1, serverID5);
-//      }
-//      finally
-//      {
-//         if (conn1 != null)
-//         {
-//            conn1.close();
-//         }
-//         
-//         if (conn2 != null)
-//         {
-//            conn2.close();
-//         }
-//         
-//         if (conn3 != null)
-//         {
-//            conn3.close();
-//         }
-//         
-//         if (conn4 != null)
-//         {
-//            conn4.close();
-//         }
-//         
-//         if (conn5 != null)
-//         {
-//            conn5.close();
-//         }
-//      }
-//      
-//   }
-// 
-//   /*
-//    * Test that the failover mapping is created correctly and updated properly when nodes leave
-//    * or join
-//    */
-//   public void testDefaultFailoverMap() throws Exception
-//   {     
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         assertEquals(3, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         //The order here depends on the order the servers were started in
-//         
-//         //If any servers get stopped and then started then the order will change
-//    
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         
-//         assertEquals(0, cf1.getServerId());
-//         
-//         assertEquals(1, cf2.getServerId());
-//         
-//         assertEquals(2, cf3.getServerId());
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         // Default failover policy just chooses the node to the right
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }
-//      
-//      //Now cleanly stop one of the servers
-//      
-//      
-//      log.info("************** STOPPING SERVER 0");
-//      ServerManagement.stop(0, true);
-//      
-//      log.info("server stopped");
-//      
-//      assertEquals(2, ServerManagement.getServer(1).getNumberOfNodesOnCluster());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         //Order here depends on order servers were started in
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(1, cf1.getServerId());
-//         
-//         assertEquals(2, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      //Cleanly stop another server
-//      
-//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-//      
-//      ServerManagement.stop(1, true);
-//      
-//      assertEquals(1, ServerManagement.getServer(2).getNumberOfNodesOnCluster());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(1, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         
-//         assertEquals(1, failoverMap.size());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//      }
-//            
-//      //Restart server 0
-//      
-//      ServerManagement.start("all", 0);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      
-//      //Restart server 1
-//      
-//      ServerManagement.start("all", 1);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         assertEquals(1, cf3.getServerId());
-//         
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }            
-//   }
+   public void testRoundRobinConnectionCreation() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      log.info ("number of delegates = " + delegate.getDelegates().length);
+      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
+      
+      assertEquals(3, delegate.getDelegates().length);
+      
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
+      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+      
+      Connection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      Connection conn4 = null;
+      
+      Connection conn5 = null;
+      
+      try
+      {         
+         conn1 = factory.createConnection();
+         
+         conn2 = factory.createConnection();
+         
+         conn3 = factory.createConnection();
+         
+         conn4 = factory.createConnection();
+         
+         conn5 = factory.createConnection();
+         
+         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+         
+         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+         
+         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+         
+         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+         
+         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+         
+         int serverID1 = state1.getServerID();
+         
+         int serverID2 = state2.getServerID();
+         
+         int serverID3 = state3.getServerID();
+         
+         int serverID4 = state4.getServerID();
+         
+         int serverID5 = state5.getServerID();
+         
+         log.info("server id 1: " + serverID1);
+         
+         log.info("server id 2: " + serverID2);
+         
+         log.info("server id 3: " + serverID3);
+         
+         log.info("server id 4: " + serverID4);
+         
+         log.info("server id 5: " + serverID5);
+         
+         assertEquals(0, serverID1);
+         
+         assertEquals(1, serverID2);
+         
+         assertEquals(2, serverID3);
+         
+         assertEquals(0, serverID4);
+         
+         assertEquals(1, serverID5);
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+         
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+         
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
+      }
+      
+   }
+ 
+   /*
+    * Test that the failover mapping is created correctly and updated properly when nodes leave
+    * or join
+    */
+   public void testDefaultFailoverMap() throws Exception
+   {     
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         //The order here depends on the order the servers were started in
+         
+         //If any servers get stopped and then started then the order will change
+    
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         
+         assertEquals(0, cf1.getServerId());
+         
+         assertEquals(1, cf2.getServerId());
+         
+         assertEquals(2, cf3.getServerId());
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(3, delegates.length);
+         
+         assertEquals(3, failoverMap.size());
+         
+         // Default failover policy just chooses the node to the right
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }
+      
+      //Now cleanly stop one of the servers
+            
+      log.info("************** STOPPING SERVER 0");
+      ServerManagement.stop(0);
+      
+      log.info("server stopped");
+      
+      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         //Order here depends on order servers were started in
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(1, cf1.getServerId());
+         
+         assertEquals(2, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      //Cleanly stop another server
+      
+      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+      
+      ServerManagement.stop(1);
+      
+      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(1, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         assertEquals(2, cf1.getServerId());
+         
+         
+         assertEquals(1, failoverMap.size());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+      }
+            
+      //Restart server 0
+      
+      ServerManagement.start("all", 0);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      
+      //Restart server 1
+      
+      ServerManagement.start("all", 1);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(3, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         assertEquals(1, cf3.getServerId());
+         
+         
+         assertEquals(3, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }            
+   }
    
    public void testSimpleFailover() throws Exception
    {
@@ -538,45 +538,45 @@
       }
       
    }
-//   
-//   public void testEvenSimplerFailover() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//                  
-//      Connection conn = null;
-//      
-//      try
-//      {
-//         conn = factory.createConnection();
-//                           
-//         log.info("************ KILLING (CRASHING) SERVER 0");
-//         
-//         ServerManagement.getServer(0).destroy();
-//         
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(25000);
-//         
-//         log.info("done wait");                
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//      }
-//      
-//   }
    
+   public void testEvenSimplerFailover() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+                  
+      Connection conn = null;
+      
+      try
+      {
+         conn = factory.createConnection();
+                           
+         log.info("************ KILLING (CRASHING) SERVER 0");
+         
+         ServerManagement.getServer(0).destroy();
+         
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(25000);
+         
+         log.info("done wait");                
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+      }
+      
+   }
    
+   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -101,10 +101,10 @@
 
    }
    
-   public void testKill() throws Exception
-   {
-      ServerManagement.getServer(0).destroy();
-   }
+//   public void testKill() throws Exception
+//   {
+//      ServerManagement.getServer(0).destroy();
+//   }
 
    public void testDistributedTopic() throws Exception
    {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -79,8 +79,7 @@
 
    // service dependencies   
    private ObjectName persistenceManagerObjectName;
-   private ObjectName queuePostOfficeObjectName;
-   private ObjectName topicPostOfficeObjectName;
+   private ObjectName postOfficeObjectName;
    private ObjectName jmsUserManagerObjectName;
 
    // the server MBean itself
@@ -347,18 +346,12 @@
          sc.invoke(serverPeerObjectName, "create", new Object[0], new String[0]);
          sc.invoke(serverPeerObjectName, "start", new Object[0], new String[0]);
 
-         MBeanConfigurationElement queuePostOfficeConfig =
-            (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
-         queuePostOfficeObjectName = sc.registerAndConfigureService(queuePostOfficeConfig);
-         sc.invoke(queuePostOfficeObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(queuePostOfficeObjectName, "start", new Object[0], new String[0]);
+         MBeanConfigurationElement postOfficeConfig =
+            (MBeanConfigurationElement)pdd.query("service", "PostOffice").iterator().next();
+         postOfficeObjectName = sc.registerAndConfigureService(postOfficeConfig);
+         sc.invoke(postOfficeObjectName, "create", new Object[0], new String[0]);
+         sc.invoke(postOfficeObjectName, "start", new Object[0], new String[0]);
 
-         MBeanConfigurationElement topicPostOfficeConfig =
-            (MBeanConfigurationElement)pdd.query("service", "TopicPostOffice").iterator().next();
-         topicPostOfficeObjectName = sc.registerAndConfigureService(topicPostOfficeConfig);
-         sc.invoke(topicPostOfficeObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(topicPostOfficeObjectName, "start", new Object[0], new String[0]);
-
          log.debug("deploying connection factories");
 
          List connFactoryElements = cfdd.query("service", "ConnectionFactory");
@@ -478,9 +471,9 @@
    
          try
          {
-            sc.invoke(queuePostOfficeObjectName, "stop", new Object[0], new String[0]);
-            sc.invoke(queuePostOfficeObjectName, "destroy", new Object[0], new String[0]);
-            sc.unregisterService(queuePostOfficeObjectName);
+            sc.invoke(postOfficeObjectName, "stop", new Object[0], new String[0]);
+            sc.invoke(postOfficeObjectName, "destroy", new Object[0], new String[0]);
+            sc.unregisterService(postOfficeObjectName);
          }
          catch (Exception ignore)
          {
@@ -488,21 +481,7 @@
             //services may be started. The ones that didn't start will fail when attempting to shut
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
-         }
-         
-         try
-         {
-            sc.invoke(topicPostOfficeObjectName, "stop", new Object[0], new String[0]);
-            sc.invoke(topicPostOfficeObjectName, "destroy", new Object[0], new String[0]);
-            sc.unregisterService(topicPostOfficeObjectName);
-         }
-         catch (Exception ignore)
-         {
-            //If the serverpeer failed when starting up previously, then only some of the
-            //services may be started. The ones that didn't start will fail when attempting to shut
-            //them down.
-            //Hence we must catch and ignore or we won't shut everything down
-         }
+         }         
    
          try
          {
@@ -588,25 +567,6 @@
       return serverPeer.getPersistenceManagerInstance();
    }
    
-   public PostOffice getQueuePostOffice() throws Exception
-   {
-      return (PostOffice)sc.
-         getAttribute(queuePostOfficeObjectName, "Instance");
-   }
-
-   public PostOffice internalGetQueuePostOffice() throws Exception
-   {
-      return (PostOffice)sc.
-         getAttribute(queuePostOfficeObjectName, "Instance");
-   }
-
-   public PostOffice getTopicPostOffice() throws Exception
-   {
-      return (PostOffice)sc.
-         getAttribute(topicPostOfficeObjectName, "Instance");
-   }
-
-   
    /**
     * Only for in-VM use!
     */
@@ -845,7 +805,7 @@
 
    public Set getNodeIDView() throws Exception
    {
-      return (Set)sc.getAttribute(queuePostOfficeObjectName, "NodeIDView");
+      return (Set)sc.getAttribute(postOfficeObjectName, "NodeIDView");
    }
 
    // Public --------------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -268,16 +268,6 @@
       return server.getPersistenceManager();
    }
    
-   public PostOffice getQueuePostOffice() throws Exception
-   {
-      return server.getQueuePostOffice();
-   }
-   
-   public PostOffice getTopicPostOffice() throws Exception
-   {
-      return server.getTopicPostOffice();
-   }
-
    public ObjectName getServerPeerObjectName() throws Exception
    {
       return server.getServerPeerObjectName();

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 09:31:53 UTC (rev 1761)
@@ -118,13 +118,6 @@
    PersistenceManager getPersistenceManager() throws Exception;
 
    /**
-    * Only for in-VM use!
-    */
-   PostOffice getQueuePostOffice() throws Exception;
-   
-   PostOffice getTopicPostOffice() throws Exception;
-
-   /**
     * Only for in-VM use
     */
    ServerPeer getServerPeer() throws Exception;



From msurtani at jboss.com  Mon Dec 11 04:40:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:40:53 -0500
Subject: [jboss-cvs] JBossCache/etc/resources - New directory ...
Message-ID: <E1GtheX-00078Q-8I@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:40:53

  Log:
  Directory /cvsroot/jboss/JBossCache/etc/resources added to the repository


From msurtani at jboss.com  Mon Dec 11 04:41:38 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:41:38 -0500
Subject: [jboss-cvs] JBossCache/etc/test-resources - New directory ...
Message-ID: <E1GthfG-0007Aa-Lj@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:41:38

  Log:
  Directory /cvsroot/jboss/JBossCache/etc/test-resources added to the repository


From msurtani at jboss.com  Mon Dec 11 04:48:43 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:48:43 -0500
Subject: [jboss-cvs] JBossCache/etc/test - New directory ...
Message-ID: <E1Gthm7-0007Fn-UW@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:48:43

  Log:
  Directory /cvsroot/jboss/JBossCache/etc/test added to the repository


From msurtani at jboss.com  Mon Dec 11 04:48:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 04:48:49 -0500
Subject: [jboss-cvs] JBossCache/etc/test/resources - New directory ...
Message-ID: <E1GthmD-0007Fw-8T@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 04:48:49

  Log:
  Directory /cvsroot/jboss/JBossCache/etc/test/resources added to the repository


From msurtani at jboss.com  Mon Dec 11 05:08:14 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 05:08:14 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1Gti50-0007kT-Vd@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 05:08:14

  Added:       tests/functional/org/jboss/cache/marshall  Tag:
                        Branch_JBossCache_1_4_0 Foo.clazz
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +0 -0      JBossCache/tests/functional/org/jboss/cache/marshall/Foo.clazz
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Mon Dec 11 05:09:02 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 05:09:02 -0500
Subject: [jboss-cvs] JBossCache/etc  ...
Message-ID: <E1Gti5m-0007l0-UV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 05:09:02

  Modified:    etc      Tag: Branch_JBossCache_1_4_0 log4j.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.15.2.1  +4 -4      JBossCache/etc/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/log4j.xml,v
  retrieving revision 1.15
  retrieving revision 1.15.2.1
  diff -u -b -r1.15 -r1.15.2.1
  --- log4j.xml	1 May 2006 09:30:35 -0000	1.15
  +++ log4j.xml	11 Dec 2006 10:09:02 -0000	1.15.2.1
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.15 2006/05/01 09:30:35 bwang Exp $ -->
  +<!-- $Id: log4j.xml,v 1.15.2.1 2006/12/11 10:09:02 msurtani Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -79,7 +79,7 @@
     -->
   
     <category name="org.jboss.cache">
  -    <priority value="INFO" class="org.jboss.logging.XLevel"/>
  +    <priority value="TRACE" class="org.jboss.logging.XLevel"/>
     </category>
   
       <category name="org.jboss.jrunit">
  @@ -108,8 +108,8 @@
     <!-- ======================= -->
   
     <root>
  -    <!--appender-ref ref="CONSOLE"/-->
  -    <appender-ref ref="FILE"/>
  +    <appender-ref ref="CONSOLE"/>
  +    <!--<appender-ref ref="FILE"/>-->
     </root>
     
   </log4j:configuration>
  
  
  


From msurtani at jboss.com  Mon Dec 11 05:07:56 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 05:07:56 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1Gti4i-0007k1-2X@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 05:07:56

  Removed:     tests/functional/org/jboss/cache/marshall   Tag:
                        Branch_JBossCache_1_4_0 Foo.clazz Foo.notjava
  Log:
  


From msurtani at jboss.com  Mon Dec 11 05:10:33 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 05:10:33 -0500
Subject: [jboss-cvs] JBossCache/etc  ...
Message-ID: <E1Gti7F-0007nX-NE@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 05:10:33

  Modified:    etc      Tag: Branch_JBossCache_1_4_0 log4j.xml
  Log:
  commented out classic deadlock test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.15.2.2  +9 -22     JBossCache/etc/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/log4j.xml,v
  retrieving revision 1.15.2.1
  retrieving revision 1.15.2.2
  diff -u -b -r1.15.2.1 -r1.15.2.2
  --- log4j.xml	11 Dec 2006 10:09:02 -0000	1.15.2.1
  +++ log4j.xml	11 Dec 2006 10:10:33 -0000	1.15.2.2
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.15.2.1 2006/12/11 10:09:02 msurtani Exp $ -->
  +<!-- $Id: log4j.xml,v 1.15.2.2 2006/12/11 10:10:33 msurtani Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -79,37 +79,24 @@
     -->
   
     <category name="org.jboss.cache">
  -    <priority value="TRACE" class="org.jboss.logging.XLevel"/>
  -  </category>
  -
  -    <category name="org.jboss.jrunit">
  -        <priority value="FATAL" class="org.jboss.logging.XLevel"/>
  -    </category>
  -
  -   <category name="org.jboss.serial">
  -      <priority value="FATAL" class="org.jboss.logging.XLevel"/>
  +    <priority value="INFO" class="org.jboss.logging.XLevel"/>
      </category>
   
       <category name="org.jboss.tm">
  -    <priority value="FATAL" class="org.jboss.logging.XLevel"/>
  +    <priority value="WARN" class="org.jboss.logging.XLevel"/>
       </category>
   
      <category name="org.jgroups">
  -      <priority value="FATAL"/>
  -   </category>
  -
  -    <category name="test">
  -        <priority value="FATAL"/>
  +      <priority value="WARN"/>
       </category>
   
  -
  -    <!-- ======================= -->
  -  <!-- Setup the Root category -->
  -  <!-- ======================= -->
  +<!-- ======================= -->
  +<!-- Setup the Root category -->
  +<!-- ======================= -->
   
     <root>
  -    <appender-ref ref="CONSOLE"/>
  -    <!--<appender-ref ref="FILE"/>-->
  +    <!--<appender-ref ref="CONSOLE"/>-->
  +    <appender-ref ref="FILE"/>
     </root>
     
   </log4j:configuration>
  
  
  


From msurtani at jboss.com  Mon Dec 11 05:11:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 05:11:20 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1Gti80-0007og-MT@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 05:11:20

  Modified:    JBossCache  Tag: Branch_JBossCache_1_4_0 build.xml
  Log:
  added tests/functional to the test classpaths
  added preferIPv4 to test targets
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.119.2.16 +15 -2     JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.119.2.15
  retrieving revision 1.119.2.16
  diff -u -b -r1.119.2.15 -r1.119.2.16
  --- build.xml	29 Nov 2006 17:23:07 -0000	1.119.2.15
  +++ build.xml	11 Dec 2006 10:11:20 -0000	1.119.2.16
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.119.2.15 2006/11/29 17:23:07 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.119.2.16 2006/12/11 10:11:20 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -107,6 +107,7 @@
         <pathelement location="${compile.dir}"/>
         <pathelement location="${output.etc.dir}"/>
         <pathelement location="${compiletest.dir}"/>
  +      <pathelement location="${functional.tests.dir}" />
      </path>
   
      <path id="output.classpath.50">
  @@ -359,6 +360,8 @@
      <target name="one-test" depends="compile,unittests-init" description="Runs a single unit test">
         <junit printsummary="yes" timeout="${junit.timeout.stresstest}" fork="yes">
            <sysproperty key="log4j.configuration" value="file:${etc.dir}/log4j.xml"/>
  +         <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <classpath refid="library.classpath"/>
            <classpath refid="output.classpath"/>
            <formatter type="xml" usefile="true"/>
  @@ -393,7 +396,8 @@
                   <jvmarg value="-Djava.compiler=NONE"/>
                   <jvmarg value="-Xrunjdwp:transport=dt_socket,server=n,suspend=n,address=localhost:2401"/>
            -->
  -         <!-- jvmarg value="-Dbind.address=${bind.address}"/ -->
  +         <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <sysproperty key="log4j.configuration" value="file:${etc.dir}/log4j.xml"/>
            <classpath refid="library.classpath"/>
            <classpath refid="output.classpath"/>
  @@ -515,6 +519,7 @@
            <classpath refid="library.classpath"/>
            <classpath refid="output.classpath"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <jvmarg value="-Dtest.jar.dir=${output.dir}"/>
            <formatter type="xml" usefile="true"/>
            <batchtest todir="${build.reports}">
  @@ -567,6 +572,7 @@
            <formatter type="xml" usefile="true"/>
            <jvmarg value="-Djboss.aop.path=${output.resources.dir}/jboss-aop.xml"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <batchtest todir="${build.reports}">
               <fileset dir="${functional.tests.dir}">
                  <include name="**/aop/**/*Test.*"/>
  @@ -585,6 +591,7 @@
            <formatter type="xml" usefile="true"/>
            <jvmarg value="-Djboss.aop.path=${output.etc.dir}/jboss-aop.xml"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <sysproperty key="log4j.configuration" value="file:${etc.dir}/log4j.xml"/>
            <batchtest todir="${build.reports}">
               <fileset dir="${functional.tests.dir}">
  @@ -625,6 +632,7 @@
            <classpath refid="library.classpath"/>
            <formatter type="xml" usefile="true"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <sysproperty key="log4j.configuration" value="file:${etc.dir}/log4j.xml"/>
            <batchtest todir="${build.reports}">
               <fileset dir="${functional.tests.dir}">
  @@ -669,6 +677,7 @@
            <jvmarg value="-Djboss.aop.path=${output.etc.dir}/jboss-aop.xml"/>
            <jvmarg value="-Xbootclasspath/p:${bootclasspath}"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <batchtest todir="${build.reports}">
               <fileset dir="${functional.tests.dir}">
                  <include name="**/aop/**/*Test.*"/>
  @@ -685,6 +694,7 @@
            <formatter type="xml" usefile="true"/>
            <jvmarg value="-Djboss.aop.path=${output.etc.dir}/jboss-aop.xml"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <batchtest todir="${build.reports}">
               <fileset dir="${perf.tests.dir}">
                  <include name="**/aop/**/*AopTest.*"/>
  @@ -701,6 +711,7 @@
            <formatter type="xml" usefile="true"/>
            <jvmarg value="-Djboss.aop.path=${output.etc.dir}/jboss-aop.xml"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <batchtest todir="${build.reports}">
               <fileset dir="${stress.tests.dir}">
                  <include name="**/aop/**/*AopTest.*"/>
  @@ -719,6 +730,7 @@
            <classpath refid="library.classpath"/>
            <classpath refid="output.classpath"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <formatter type="xml" usefile="true"/>
            <batchtest todir="${build.reports}">
               <fileset dir="${perf.tests.dir}">
  @@ -744,6 +756,7 @@
            <classpath refid="library.classpath"/>
            <classpath refid="output.classpath"/>
            <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true" />
            <formatter type="xml" usefile="true"/>
            <batchtest todir="${build.reports}">
               <fileset dir="${stress.tests.dir}">
  
  
  


From msurtani at jboss.com  Mon Dec 11 05:50:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 05:50:03 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/buddyreplication ...
Message-ID: <E1GtijT-0008S2-Sc@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 05:50:03

  Modified:    tests/functional/org/jboss/cache/buddyreplication  Tag:
                        Branch_JBossCache_1_4_0 BuddyPoolBroadcastTest.java
  Log:
  reduced concurrency test to 5 instances from 10
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.12.2.1  +1 -1      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyPoolBroadcastTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java,v
  retrieving revision 1.12
  retrieving revision 1.12.2.1
  diff -u -b -r1.12 -r1.12.2.1
  --- BuddyPoolBroadcastTest.java	11 May 2006 12:28:10 -0000	1.12
  +++ BuddyPoolBroadcastTest.java	11 Dec 2006 10:50:03 -0000	1.12.2.1
  @@ -135,7 +135,7 @@
   
       public void testConcurrency() throws Exception
       {
  -        int numCaches = 10;
  +        int numCaches = 5;
           TreeCache[] caches = new TreeCache[numCaches];
           try
           {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 06:50:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 06:50:58 -0500
Subject: [jboss-cvs] JBossAS SVN: r58971 -
	trunk/server/src/main/org/jboss/deployment
Message-ID: <E1GtjgQ-0001Cq-Qm@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-11 06:50:57 -0500 (Mon, 11 Dec 2006)
New Revision: 58971

Modified:
   trunk/server/src/main/org/jboss/deployment/J2eeApplicationMetaData.java
Log:
fix getModule fallback logic

Modified: trunk/server/src/main/org/jboss/deployment/J2eeApplicationMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/J2eeApplicationMetaData.java	2006-12-11 03:39:11 UTC (rev 58970)
+++ trunk/server/src/main/org/jboss/deployment/J2eeApplicationMetaData.java	2006-12-11 11:50:57 UTC (rev 58971)
@@ -130,7 +130,7 @@
    public J2eeModuleMetaData getModule(String path)
    {
       J2eeModuleMetaData module = modules.get(path);
-      if( path.startsWith("/") )
+      if( module == null && path.startsWith("/") )
       {
          // try a non-absolute path
          path = path.substring(1);



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 06:52:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 06:52:24 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1762 -
	branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract
Message-ID: <E1Gtjho-0001GA-Ng@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-11 06:52:22 -0500 (Mon, 11 Dec 2006)
New Revision: 1762

Added:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Condition.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java
Log:
Missing files

Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Condition.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Condition.java	2006-12-11 09:31:53 UTC (rev 1761)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Condition.java	2006-12-11 11:52:22 UTC (rev 1762)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.messaging.core.plugin.contract;
+
+import org.jboss.messaging.core.MessageReference;
+
+/**
+ * A Condition
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public interface Condition
+{
+   boolean matches(Condition routingCondition, MessageReference ref);
+   
+   String toText();
+}

Added: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java	2006-12-11 09:31:53 UTC (rev 1761)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java	2006-12-11 11:52:22 UTC (rev 1762)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.messaging.core.plugin.contract;
+
+/**
+ * A ConditionFactory
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public interface ConditionFactory
+{
+   Condition createCondition(String text) throws Exception;
+}



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 08:00:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 08:00:12 -0500
Subject: [jboss-cvs] JBossAS SVN: r58972 -
	trunk/server/src/main/org/jboss/deployment
Message-ID: <E1GtklQ-0002V9-FT@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-11 08:00:10 -0500 (Mon, 11 Dec 2006)
New Revision: 58972

Modified:
   trunk/server/src/main/org/jboss/deployment/JBossApplicationObjectFactory.java
Log:
Add <web-uri>, <context-root> processing

Modified: trunk/server/src/main/org/jboss/deployment/JBossApplicationObjectFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/JBossApplicationObjectFactory.java	2006-12-11 11:50:57 UTC (rev 58971)
+++ trunk/server/src/main/org/jboss/deployment/JBossApplicationObjectFactory.java	2006-12-11 13:00:10 UTC (rev 58972)
@@ -111,6 +111,16 @@
          module.setType(J2eeModuleMetaData.HAR);
          module.setFileName(value);
       }
+      else if( localName.equals("web-uri") )
+      {
+         module.setType(J2eeModuleMetaData.WEB);
+         module.setFileName(value);
+      }
+      else if( localName.equals("context-root") )
+      {
+         module.setType(J2eeModuleMetaData.WEB);
+         module.setWebContext(value);
+      }
    }
 
    public void addChild(J2eeApplicationMetaData parent, J2eeModuleMetaData module,



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 08:08:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 08:08:11 -0500
Subject: [jboss-cvs] JBossAS SVN: r58973 - in trunk/ejb3/src:
	main/org/jboss/injection main/org/jboss/injection/lang/reflect
	resources/test/ejbthree712
Message-ID: <E1Gtkt9-0002oL-4N@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-11 08:07:59 -0500 (Mon, 11 Dec 2006)
New Revision: 58973

Added:
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanPropertyFactory.java
Modified:
   trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java
   trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java
   trunk/ejb3/src/resources/test/ejbthree712/ejb-jar.xml
Log:
EJBTHREE-712: inject EJBContext via xml

Modified: trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java	2006-12-11 13:00:10 UTC (rev 58972)
+++ trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java	2006-12-11 13:07:59 UTC (rev 58973)
@@ -23,6 +23,7 @@
 
 import org.jboss.ejb3.Container;
 import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.injection.lang.reflect.BeanPropertyFactory;
 import org.jboss.injection.lang.reflect.FieldBeanProperty;
 import org.jboss.injection.lang.reflect.MethodBeanProperty;
 import org.jboss.logging.Logger;
@@ -36,6 +37,7 @@
 import javax.annotation.Resource;
 import javax.annotation.Resources;
 import javax.ejb.EJBContext;
+import javax.ejb.EJBException;
 import javax.ejb.TimerService;
 import javax.transaction.UserTransaction;
 import javax.xml.ws.WebServiceContext;
@@ -104,6 +106,27 @@
    {
       for (ResourceEnvRef envRef : refs)
       {
+         // EJBTHREE-712
+         // TODO: refactor with handlePropertyAnnotation
+         String resTypeName = envRef.getResType();
+         try
+         {
+            if(resTypeName != null)
+            {
+               Class<?> resType = Class.forName(resTypeName);
+               if(EJBContext.class.isAssignableFrom(resType))
+               {
+                  AccessibleObject ao = InjectionUtil.findInjectionTarget(container.getClassloader(), envRef.getInjectionTarget());
+                  container.getInjectors().add(new EJBContextPropertyInjector(BeanPropertyFactory.create(ao)));
+                  continue;
+               }
+            }
+         }
+         catch(ClassNotFoundException e)
+         {
+            throw new EJBException(e);
+         }
+         
          String encName = "env/" + envRef.getResRefName();
          if (container.getEncInjectors().containsKey(encName)) continue;
          if (envRef.getMappedName() == null || envRef.getMappedName().equals(""))

Modified: trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-11 13:00:10 UTC (rev 58972)
+++ trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-11 13:07:59 UTC (rev 58973)
@@ -32,6 +32,7 @@
  */
 public interface BeanProperty
 {
+   // TODO: should not be exposed
    AccessibleObject getAccessibleObject();
    
    Class<?> getDeclaringClass();

Added: trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanPropertyFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanPropertyFactory.java	2006-12-11 13:00:10 UTC (rev 58972)
+++ trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanPropertyFactory.java	2006-12-11 13:07:59 UTC (rev 58973)
@@ -0,0 +1,50 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.lang.reflect;
+
+import java.lang.reflect.AccessibleObject;
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+
+/**
+ * BeanProperty factory.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class BeanPropertyFactory
+{
+   private BeanPropertyFactory()
+   {
+      // do not instantiate
+   }
+   
+   public static BeanProperty create(AccessibleObject ao)
+   {
+      if(ao instanceof Field)
+         return new FieldBeanProperty((Field) ao);
+      if(ao instanceof Method)
+         return new MethodBeanProperty((Method) ao);
+      
+      throw new IllegalArgumentException("can't handle " + ao.getClass().getName());
+   }
+}

Modified: trunk/ejb3/src/resources/test/ejbthree712/ejb-jar.xml
===================================================================
--- trunk/ejb3/src/resources/test/ejbthree712/ejb-jar.xml	2006-12-11 13:00:10 UTC (rev 58972)
+++ trunk/ejb3/src/resources/test/ejbthree712/ejb-jar.xml	2006-12-11 13:07:59 UTC (rev 58973)
@@ -15,6 +15,7 @@
 			<resource-env-ref>
 				<resource-env-ref-name>ctx</resource-env-ref-name>
 				<resource-env-ref-type>javax.ejb.SessionContext</resource-env-ref-type>
+				<!--mapped-name>java:comp/EJBContext</mapped-name-->
 				<injection-target>
 					<injection-target-class>org.jboss.ejb3.test.ejbthree712.InjectionTesterBean</injection-target-class>
 					<injection-target-name>ctx</injection-target-name>



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 08:42:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 08:42:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r58974 - in projects/ejb3/trunk: .
	injection injection/src injection/src/main
	injection/src/main/java injection/src/main/java/org
	injection/src/main/java/org/jboss
	injection/src/main/java/org/jboss/injection
	injection/src/main/java/org/jboss/injection/aop
	injection/src/main/java/org/jboss/injection/lang/reflect
Message-ID: <E1GtlQ5-0003O6-Su@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-11 08:42:04 -0500 (Mon, 11 Dec 2006)
New Revision: 58974

Added:
   projects/ejb3/trunk/injection/
   projects/ejb3/trunk/injection/src/
   projects/ejb3/trunk/injection/src/main/
   projects/ejb3/trunk/injection/src/main/java/
   projects/ejb3/trunk/injection/src/main/java/org/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanPropertyFactory.java
Removed:
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java
Log:



Property changes on: projects/ejb3/trunk/injection
___________________________________________________________________
Name: svn:ignore
   + target


Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java	2006-12-11 13:07:59 UTC (rev 58973)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java	2006-12-11 13:42:04 UTC (rev 58974)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+/**
+ * Processes instances by injecting their properties and calling their postconstructs.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class InjectorProcessor
+{
+   public static void process(Object instance)
+   {
+      
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java	2006-12-11 13:07:59 UTC (rev 58973)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java	2006-12-11 13:42:04 UTC (rev 58974)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.aop;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.injection.InjectorProcessor;
+
+/**
+ * Intercepts construction of new objects and fires up injection.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class ConstructorInterceptor implements Interceptor
+{
+   public String getName()
+   {
+      return "ConstructorInterceptor";
+   }
+
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+      InjectorProcessor.process(invocation.getTargetObject());
+      return invocation.invokeNext();
+   }
+}

Copied: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang (from rev 58873, trunk/ejb3/src/main/org/jboss/injection/lang)

Deleted: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-06 18:05:12 UTC (rev 58873)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-11 13:42:04 UTC (rev 58974)
@@ -1,44 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.injection.lang.reflect;
-
-import java.lang.reflect.AccessibleObject;
-
-/**
- * A bean property defines a propery of a pojo from the EJB3 point of view.
- * It can be used to inject values into it.
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public interface BeanProperty
-{
-   AccessibleObject getAccessibleObject();
-   
-   Class<?> getDeclaringClass();
-   
-   String getName();
-   
-   Class<?> getType();
-   
-   void set(Object instance, Object value);
-}

Copied: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java (from rev 58973, trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanProperty.java)

Copied: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanPropertyFactory.java (from rev 58973, trunk/ejb3/src/main/org/jboss/injection/lang/reflect/BeanPropertyFactory.java)



From msurtani at jboss.com  Mon Dec 11 09:46:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 09:46:54 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options  ...
Message-ID: <E1GtmQg-0004Zy-3H@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 09:46:54

  Modified:    tests/functional/org/jboss/cache/options  Tag:
                        Branch_JBossCache_1_4_0 ExplicitVersionsTest.java
  Log:
  Fixed weird bugs
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.4.2   +16 -0     JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java,v
  retrieving revision 1.3.4.1
  retrieving revision 1.3.4.2
  diff -u -b -r1.3.4.1 -r1.3.4.2
  --- ExplicitVersionsTest.java	11 Nov 2006 17:50:03 -0000	1.3.4.1
  +++ ExplicitVersionsTest.java	11 Dec 2006 14:46:54 -0000	1.3.4.2
  @@ -111,8 +111,24 @@
           }
       }
   
  +   public void testExplicitVersionOnLeaf() throws Exception
  +   {
  +      cache.put("/org/domain/Entity", null);
  +      assertEquals(1, ((DefaultDataVersion)((OptimisticTreeNode)cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  +
  +      TestVersion v = new TestVersion("Arse");
  +      Option o = new Option();
  +      o.setDataVersion(v);
  +
  +      cache.put(Fqn.fromString("/org/domain/Entity/EntityInstance#1"), "k", "v", o);
  +
  +      assertEquals(2, ((DefaultDataVersion)((OptimisticTreeNode)cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((OptimisticTreeNode)cache.get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +   }
   }
   
  +
  +
   class TestVersion implements DataVersion
   {
       private String myVersion;
  
  
  


From msurtani at jboss.com  Mon Dec 11 09:46:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 09:46:54 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic   ...
Message-ID: <E1GtmQg-0004aC-77@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 09:46:54

  Modified:    src/org/jboss/cache/optimistic   Tag:
                        Branch_JBossCache_1_4_0 DefaultDataVersion.java
                        WorkspaceNodeImpl.java
  Log:
  Fixed weird bugs
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.2   +21 -2     JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.3.2.1
  retrieving revision 1.3.2.2
  diff -u -b -r1.3.2.1 -r1.3.2.2
  --- DefaultDataVersion.java	6 Dec 2006 16:00:14 -0000	1.3.2.1
  +++ DefaultDataVersion.java	11 Dec 2006 14:46:54 -0000	1.3.2.2
  @@ -6,14 +6,24 @@
    */
   package org.jboss.cache.optimistic;
   
  +import java.io.Externalizable;
  +import java.io.ObjectOutput;
  +import java.io.IOException;
  +import java.io.ObjectInput;
  +
   /**
    * The default implementation of a DataVersion, uses a <code>long</code> to
    * compare versions.
  + *
    * This class is immutable.
    *
  + * Also note that this is meant to control implicit, internal versioning.  Do not attempt to instantiate or use instances
  + * of this class explicitly, via the {@link org.jboss.cache.config.Option#setDataVersion(DataVersion)} API, as it WILL
  + * break things.
  + *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  -public class DefaultDataVersion implements DataVersion
  +public class DefaultDataVersion implements DataVersion, Externalizable
   {
   
       /**
  @@ -36,7 +46,6 @@
   
       /**
        * Constructs with version 0.
  -     * @deprecated use {@link #ZERO} constant
        */
       public DefaultDataVersion()
       {
  @@ -95,4 +104,14 @@
      {
         return version;
      }
  +
  +   public void writeExternal(ObjectOutput objectOutput) throws IOException
  +   {
  +      objectOutput.writeLong(version);
  +   }
  +
  +   public void readExternal(ObjectInput objectInput) throws IOException, ClassNotFoundException
  +   {
  +      version = objectInput.readLong();
  +   }
   }
  
  
  
  1.21.2.3  +4 -6      JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.21.2.2
  retrieving revision 1.21.2.3
  diff -u -b -r1.21.2.2 -r1.21.2.3
  --- WorkspaceNodeImpl.java	13 Nov 2006 13:00:04 -0000	1.21.2.2
  +++ WorkspaceNodeImpl.java	11 Dec 2006 14:46:54 -0000	1.21.2.3
  @@ -210,12 +210,10 @@
                   optimisticChildNodeMap = new ConcurrentReaderHashMap();
               optimisticChildNodeMap.put(child_name, child);
           }
  -        if (log.isTraceEnabled())
  -        {
  -            log.trace("createChild: fqn=" + fqn);
  -        }
           // TODO: MANIK: Remove dirty=true, implement merging on child mods instead.
           dirty = true;
  +
  +        if (log.isTraceEnabled()) log.trace("createChild: fqn=" + fqn + " for node " + this);
           return child;
   
       }
  
  
  


From msurtani at jboss.com  Mon Dec 11 09:46:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 09:46:54 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors   ...
Message-ID: <E1GtmQg-0004aQ-DP@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 09:46:54

  Modified:    src/org/jboss/cache/interceptors   Tag:
                        Branch_JBossCache_1_4_0
                        OptimisticValidatorInterceptor.java
                        OptimisticCreateIfNotExistsInterceptor.java
  Log:
  Fixed weird bugs
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.25.2.10 +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.25.2.9
  retrieving revision 1.25.2.10
  diff -u -b -r1.25.2.9 -r1.25.2.10
  --- OptimisticValidatorInterceptor.java	10 Dec 2006 17:02:38 -0000	1.25.2.9
  +++ OptimisticValidatorInterceptor.java	11 Dec 2006 14:46:54 -0000	1.25.2.10
  @@ -216,7 +216,7 @@
                       if (log.isTraceEnabled()) log.trace("inserting merged data " + wrappedNode.getMergedData());
                       Map mergedData = wrappedNode.getMergedData();
                       current.put(mergedData, true);
  -                    if (workspace.isVersioningImplicit())
  +                    if (workspace.isVersioningImplicit() || wrappedNode.getVersion() instanceof DefaultDataVersion)
                       {
                           current.setVersion(((DefaultDataVersion)wrappedNode.getVersion()).increment());
                       }
  
  
  
  1.21.2.2  +11 -11    JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticCreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java,v
  retrieving revision 1.21.2.1
  retrieving revision 1.21.2.2
  diff -u -b -r1.21.2.1 -r1.21.2.2
  --- OptimisticCreateIfNotExistsInterceptor.java	11 Nov 2006 17:50:03 -0000	1.21.2.1
  +++ OptimisticCreateIfNotExistsInterceptor.java	11 Dec 2006 14:46:54 -0000	1.21.2.2
  @@ -147,26 +147,26 @@
                   // current workspace node canot be null.
                   // try and get the child of current node
   
  -                log.debug(" Entering synchronized nodewrapper access  for gtx " + gtx);
  -                TreeNode tempchildNode = workspaceNode.getChild(childName);
  +                if (log.isTraceEnabled()) log.trace(" Entering synchronized nodewrapper access  for gtx " + gtx);
  +                TreeNode tempChildNode = workspaceNode.getChild(childName);
   
   //                if (log.isDebugEnabled()) log.debug(" Entered synchronized workspaceNode " + workspaceNode + " access  for gtx " + gtx);
   
                   // no child exists with this name
  -                if (tempchildNode == null)
  +                if (tempChildNode == null)
                   {
  -                    if (log.isDebugEnabled()) log.debug("Child node "+childName+" doesn't exist.  Creating new node.");
  +                    if (log.isTraceEnabled()) log.trace("Child node "+childName+" doesn't exist.  Creating new node.");
                       // we put the parent node into the workspace as we are changing it's children
                       WorkspaceNode tempCheckWrapper = workspace.getNode(workspaceNode.getFqn());
                       if (tempCheckWrapper == null || tempCheckWrapper.isDeleted())
                       {
                           //add a new one or overwrite an existing one that has been deleted
  -                        if (log.isDebugEnabled()) log.debug("Parent node doesn't exist in workspace or has been deleted.  Adding to workspace in gtx " + gtx);
  +                        if (log.isTraceEnabled()) log.trace("Parent node "+workspaceNode.getFqn()+" doesn't exist in workspace or has been deleted.  Adding to workspace in gtx " + gtx);
                           workspace.addNode(workspaceNode);
                       }
                       else
                       {
  -                        if (log.isDebugEnabled()) log.debug(" Parent node " + workspaceNode.getFqn() + " exists in workspace " + gtx);
  +                        if (log.isTraceEnabled()) log.trace(" Parent node " + workspaceNode.getFqn() + " exists in workspace " + gtx);
                       }
                       copy = (Fqn) tmpFqn.clone();
                       // this does not add it into the real child nodes - but in its
  @@ -194,17 +194,17 @@
                   else
                   {
                       // node does exist but might not be in the workspace
  -                    childWorkspaceNode = workspace.getNode(tempchildNode.getFqn());
  +                    childWorkspaceNode = workspace.getNode(tempChildNode.getFqn());
                       // wrap it up so we can put it in later if we need to
                       if (childWorkspaceNode == null || childWorkspaceNode.isDeleted())
                       {
  -                        if (log.isDebugEnabled()) log.debug("Child node doesn't exist in workspace or has been deleted.  Adding to workspace in gtx " + gtx);
  -                        childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempchildNode, workspace);
  -                        if (!workspace.isVersioningImplicit()) childWorkspaceNode.setVersion(version);
  +                        if (log.isDebugEnabled()) log.debug("Child node "+tempChildNode.getFqn()+" doesn't exist in workspace or has been deleted.  Adding to workspace in gtx " + gtx);
  +                        childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempChildNode, workspace);
  +                        if (isTargetFqn && !workspace.isVersioningImplicit()) childWorkspaceNode.setVersion(version);
                       }
                       else
                       {
  -                        if (log.isDebugEnabled()) log.debug(" Already found " + tempchildNode.getFqn() + " node in workspace " + gtx);
  +                        if (log.isDebugEnabled()) log.debug(" Already found " + tempChildNode.getFqn() + " node in workspace " + gtx);
   
                       }
                   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 10:27:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 10:27:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1763 - in
	branches/Branch_Client_Failover_Experiment: src/etc
	src/etc/server/default/deploy src/main/org/jboss/jms/client
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/container
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/etc
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gtn4C-0005OP-28@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-11 10:27:26 -0500 (Mon, 11 Dec 2006)
New Revision: 1763

Added:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java
Removed:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java
Modified:
   branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml
   branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-server.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionFactory.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/SecurityAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
   branches/Branch_Client_Failover_Experiment/tests/etc/log4j.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
More HA fixes. 



Modified: branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml	2006-12-11 15:27:26 UTC (rev 1763)
@@ -28,7 +28,7 @@
    </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
       <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
-   </bind>
+   </bind>  
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
       <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.HAAspect"/>
    </bind>

Modified: branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-server.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-server.xml	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-server.xml	2006-12-11 15:27:26 UTC (rev 1763)
@@ -37,13 +37,8 @@
    <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.ConsumerAdvised->$implementing{org.jboss.jms.server.endpoint.ConsumerEndpoint}(..))">
       <interceptor-ref name="org.jboss.jms.server.container.ServerLogInterceptor"/>
    </bind>
-   <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.ConsumerAdvised->activate(..))">
-      <advice name="handleActivate" aspect="org.jboss.jms.server.container.SecurityAspect"/>
-   </bind>
-   <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.ConsumerAdvised->getMessageNow(..))">
-      <advice name="handleGetMessageNow" aspect="org.jboss.jms.server.container.SecurityAspect"/>
-   </bind>
 
+
    <!-- Browser -->
    <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.BrowserAdvised->$implementing{org.jboss.jms.server.endpoint.BrowserEndpoint}(..))">
       <interceptor-ref name="org.jboss.jms.server.container.ServerLogInterceptor"/>

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 15:27:26 UTC (rev 1763)
@@ -87,7 +87,8 @@
             <AUTOCONF down_thread="false" up_thread="false"/>
             <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
             <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
+            <FD_SOCK down_thread="false" up_thread="false"/>
+            <FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>            
             <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
             <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
                          retransmit_timeout="100,200,600,1200,2400,4800"/>
@@ -107,7 +108,8 @@
             <AUTOCONF down_thread="false" up_thread="false"/>
             <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
             <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
+            <FD_SOCK down_thread="false" up_thread="false"/>
+            <FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>            
             <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
             <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
                          retransmit_timeout="100,200,600,1200,2400,4800"/>

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionFactory.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionFactory.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -42,9 +42,9 @@
 import org.jboss.aop.Advised;
 import org.jboss.jms.client.container.JmsClientAspectXMLLoader;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.referenceable.SerializableObjectRefAddr;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.util.ThreadContextClassLoaderChanger;
 import org.jboss.logging.Logger;
 
@@ -199,9 +199,9 @@
          // The version used by the connection is the minimum of the server version for the
          // connection factory and the client code version
          
-         ConnectionDelegate cd = delegate.createConnectionDelegate(username, password);        
+         CreateConnectionResult res = delegate.createConnectionDelegate(username, password, -1);        
          
-         return new JBossConnection(cd, type);
+         return new JBossConnection(res.getDelegate(), type);
       }
       finally
       {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -48,7 +48,7 @@
 import org.jboss.jms.client.state.ProducerState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.destination.JBossDestination;
-import org.jboss.jms.server.endpoint.ConnectionStatus;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -103,7 +103,7 @@
          
          ClientConnectionDelegate connDelegate = createConnection(cfDelegate, username, password);
          
-         return connDelegate;   
+         return new CreateConnectionResult(connDelegate);
       }
       else
       {
@@ -163,8 +163,11 @@
       throws Exception
    {
       log.info("createConnection");
+      
+      CreateConnectionResult res = (CreateConnectionResult)cf.createConnectionDelegate(username, password, -1);
+      
       ClientConnectionDelegate connDelegate =
-         (ClientConnectionDelegate)cf.createConnectionDelegate(username, password);
+         (ClientConnectionDelegate)res.getDelegate();
       
       initialiseConnection(connDelegate);
       
@@ -194,26 +197,28 @@
       
       ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
       
-      log.info("Failing over connection");
+      log.info("calling createFailoverConnectionDelegate");
       
-      ConnectionStatus status =
-         newCF.createFailoverConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
+      CreateConnectionResult res =
+         newCF.createConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
       
       log.info("returned from createFailoverConnectionDelegate");
                   
-      if (status.getDelegate() != null)
+      if (res.getDelegate() != null)
       {
          log.info("Got connection");
          
-         ClientConnectionDelegate newConnection = (ClientConnectionDelegate)state.getDelegate();
+         ClientConnectionDelegate newConnection = (ClientConnectionDelegate)res.getDelegate();
          
+         log.info("newconnection is " + newConnection);
+         
          //We got the right server and created a new connection
          
          failover(failedConnection, newConnection);
       }
       else
       {
-         if (status.getActualFailoverNode() == -1)
+         if (res.getActualFailoverNode() == -1)
          {
             //No trace of failover was detected on the server side - this might happen if the client side
             //network fails temporarily so the client connection breaks but the server side network is still
@@ -272,32 +277,6 @@
          throw new IllegalStateException("Cannot find failover delegate for node " + failoverServerID.intValue());
       }
            
-      // Redirect connection routine.
-      // Verify the failureMap on the server and if out of sync find the correct delegate
-      
-      
-      //THIS IS WRONG - cannot use getFailoverNode method since failover node might change
-      //between getting the result and actually failing over
-      
-//      int failoverNode = delegateFound.getFailoverNode(currentState.getServerID());
-//      if (failoverNode!=delegateFound.getServerId())
-//      {
-//         delegateFound = null;
-//         for (int i = 0; i < delegates.length; i++)
-//         {
-//            if (delegates[i].getServerId() == failoverNode)
-//            {
-//               delegateFound = delegates[i];
-//            }
-//         }
-//
-//         if (delegateFound==null)
-//         {
-//            throw new IllegalStateException("Cannot find failover node on current map for nodeId=" + failoverNode);
-//         }
-//
-//      }
-
       return del;
    }
    
@@ -312,12 +291,14 @@
       int oldServerID = failedState.getServerID();
 
       ConnectionState newState = (ConnectionState)newConnection.getState();
+      
+      log.info("new state is: " + newState);
 
       failedState.copy(newState);
 
       // this is necessary so the connection will start "talking" to the new server instead
       failedState.setRemotingConnection(newState.getRemotingConnection());
-
+      
       if (failedState.getClientID() != null)
       {
          newConnection.setClientID(failedState.getClientID());
@@ -325,26 +306,30 @@
 
       // Transfering state from newDelegate to currentDelegate
       failedConnection.copyState(newConnection);
+      
+      log.info("failing over children");
 
-      if (failedState.isStarted())
-      {
-         failedConnection.start();
-      }
-
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
 
+         log.info("Creating session");
+         
          ClientSessionDelegate newSessionDelegate = (ClientSessionDelegate)newConnection.
             createSessionDelegate(failedSessionState.isTransacted(),
                                   failedSessionState.getAcknowledgeMode(),
                                   failedSessionState.isXA());
-
+         
+         log.info("Created session");
+                  
          ClientSessionDelegate failedSessionDelegate =
             (ClientSessionDelegate)failedSessionState.getDelegate();
 
          failedSessionDelegate.copyState(newSessionDelegate);
+         
+         log.info("copied state");
 
+
          if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
 
          //TODO Clebert please add comment as to why this clone is necessary
@@ -375,6 +360,13 @@
             }
          }
       }
+      
+      //We must not start the connection until the end
+      if (failedState.isStarted())
+      {
+         failedConnection.start();
+      }
+      
       log.info("Failover done");
    }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -28,7 +28,6 @@
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClientProducerDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
@@ -39,6 +38,7 @@
 import org.jboss.jms.client.state.ProducerState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.BrowserDelegate;
+import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.ProducerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
@@ -46,6 +46,7 @@
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.Version;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.server.remoting.MetaDataConstants;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.jms.tx.ResourceManagerFactory;
@@ -81,40 +82,49 @@
 
    public Object handleCreateConnectionDelegate(Invocation inv) throws Throwable
    {
-      ClientConnectionFactoryDelegate cfd = (ClientConnectionFactoryDelegate)inv.getTargetObject();
-      ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)inv.invokeNext();
-      connectionDelegate.init();
-
-      SimpleMetaData md = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
+      ConnectionFactoryDelegate cfd = (ConnectionFactoryDelegate)inv.getTargetObject();
       
-      int serverID =
-         ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID)).intValue();
+      CreateConnectionResult res = (CreateConnectionResult)inv.invokeNext();
       
-      Version connectionVersion = 
-         (Version)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION);
+      ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
       
-      JMSRemotingConnection connection = 
-         (JMSRemotingConnection)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION);
-      
-      if (connectionVersion == null)
+      if (connectionDelegate != null)
       {
-         throw new IllegalStateException("Connection version is null");
+         
+         connectionDelegate.init();
+         
+         SimpleMetaData md = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
+         
+         int serverID =
+            ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID)).intValue();
+         
+         Version connectionVersion = 
+            (Version)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION);
+         
+         JMSRemotingConnection connection = 
+            (JMSRemotingConnection)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION);
+         
+         if (connectionVersion == null)
+         {
+            throw new IllegalStateException("Connection version is null");
+         }
+         
+         // We have one resource manager per unique server
+         ResourceManager rm = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
+         
+         //We have one message id generator per unique server
+         MessageIdGenerator gen =
+            MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
+         
+         ConnectionState connectionState =
+            new ConnectionState(serverID, connectionDelegate,
+                     connection,
+                     connectionVersion, rm, gen);
+         
+         connectionDelegate.setState(connectionState);
       }
-           
-      //We have one resource manager per unique server
-      ResourceManager rm = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
       
-      //We have one message id generator per unique server
-      MessageIdGenerator gen =
-         MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
-
-      ConnectionState connectionState =
-         new ConnectionState(serverID, connectionDelegate,
-                             connection,
-                             connectionVersion, rm, gen);
-
-      connectionDelegate.setState(connectionState);
-      return connectionDelegate;
+      return res;
    }
    
    public Object handleCreateSessionDelegate(Invocation invocation) throws Throwable

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -23,7 +23,9 @@
 
 import java.util.HashMap;
 import java.util.Map;
+
 import javax.jms.JMSException;
+
 import org.jboss.aop.Advised;
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.Invocation;
@@ -32,11 +34,10 @@
 import org.jboss.aop.util.PayloadKey;
 import org.jboss.jms.client.container.JMSClientVMIdentifier;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
-import org.jboss.jms.server.endpoint.ConnectionStatus;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.server.remoting.MetaDataConstants;
@@ -117,28 +118,16 @@
    }
 
    // ConnectionFactoryDelegateImplementation -----------------------
-
+ 
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
-    * @see org.jboss.jms.client.container.StateCreationAspect#handleCreateConnectionDelegate(org.jboss.aop.joinpoint.Invocation)
-    * @see org.jboss.jms.server.endpoint.ServerConnectionFactoryEndpoint#createConnectionDelegate(String, String) 
     */
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
+   public CreateConnectionResult createConnectionDelegate(String username, String password, int failedNodeId)
       throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
-   
-   /**
-    * This invocation should either be handled by the client-side interceptor chain or by the
-    * server-side endpoint.
-    */
-   public ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
-      throws JMSException
-   {
-      throw new IllegalStateException("This invocation should not be handled here!");
-   }
 
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
@@ -268,19 +257,37 @@
       if (remotingConnection != null)
       {
          // It was a call to createConnectionDelegate - set the remoting connection to use
-         ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)ret;
+         
+         CreateConnectionResult res = (CreateConnectionResult)ret;
+         
+         ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
+         
+         if (connectionDelegate != null)
+         {
+            //We set the version for the connection and the remoting connection on the meta-data
+            //this is so the StateCreationAspect can pick it up
+   
+            SimpleMetaData metaData = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
+   
+            metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION,
+                                 remotingConnection, PayloadKey.TRANSIENT);
+   
+            metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
+                                 version, PayloadKey.TRANSIENT);
+         }
+         else
+         {
+            //Wrong server redirect on failure
+            //close the remoting connection
+            try
+            {
+               remotingConnection.stop();
+            }
+            catch (Throwable ignore)
+            {
+            }
+         }
 
-         //We set the version for the connection and the remoting connection on the meta-data
-         //this is so the StateCreationAspect can pick it up
-
-         SimpleMetaData metaData = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
-
-         metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION,
-                              remotingConnection, PayloadKey.TRANSIENT);
-
-         metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
-                              version, PayloadKey.TRANSIENT);
-
       }
 
       return ret;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -83,6 +83,7 @@
       // Enable client pinging. Server leasing is enabled separately on the server side
 
       Map config = new HashMap();
+      
       config.put(Client.ENABLE_LEASE, String.valueOf(clientPing));
 
       client = new Client(serverLocator, config);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -22,14 +22,15 @@
 package org.jboss.jms.server.connectionfactory;
 
 import java.io.Serializable;
-import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
+
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
@@ -382,11 +383,9 @@
 
    private void recalculateFailoverMap(Map nodeAddressMap) throws Exception
    {     
-      List nodes = new ArrayList(nodeAddressMap.keySet());
-      
       FailoverMapper mapper = replicator.getFailoverMapper();
       
-      failoverMap = mapper.generateMapping(nodes);
+      failoverMap = mapper.generateMapping(nodeAddressMap.keySet());
    }
    
    /**

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -24,6 +24,7 @@
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.server.endpoint.ServerConnectionEndpoint;
 import org.jboss.jms.server.endpoint.advised.ConnectionAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
@@ -66,51 +67,56 @@
           throw new IllegalStateException("Can't find handler");
        }
        
-       ClientConnectionDelegate del = (ClientConnectionDelegate)invocation.invokeNext();
+       CreateConnectionResult res = (CreateConnectionResult)invocation.invokeNext();
        
-       ConnectionAdvised advised = 
-          (ConnectionAdvised)JMSDispatcher.instance.getRegistered(new Integer(del.getID()));
+       ClientConnectionDelegate del = (ClientConnectionDelegate)res.getDelegate();
        
-       ServerConnectionEndpoint endpoint = (ServerConnectionEndpoint)advised.getEndpoint();
-       
-       endpoint.setCallbackClient(handler.getCallbackClient());
-       
-       // Then we inject the remoting session id of the client
-       String sessionId =
-          (String)mi.getMetaData(MetaDataConstants.JMS,
-                                 MetaDataConstants.REMOTING_SESSION_ID);
-       
-       if (sessionId == null)
-       {
-          throw new IllegalStateException("Can't find session id");
+       if (del != null)
+       {          
+          ConnectionAdvised advised = 
+             (ConnectionAdvised)JMSDispatcher.instance.getRegistered(new Integer(del.getID()));
+          
+          ServerConnectionEndpoint endpoint = (ServerConnectionEndpoint)advised.getEndpoint();
+          
+          endpoint.setCallbackClient(handler.getCallbackClient());
+          
+          // Then we inject the remoting session id of the client
+          String sessionId =
+             (String)mi.getMetaData(MetaDataConstants.JMS,
+                                    MetaDataConstants.REMOTING_SESSION_ID);
+          
+          if (sessionId == null)
+          {
+             throw new IllegalStateException("Can't find session id");
+          }
+          
+          // Then we inject the unique id of the client VM
+          String jmsClientVMID =
+             (String)mi.getMetaData(MetaDataConstants.JMS,
+                                    MetaDataConstants.JMS_CLIENT_VM_ID);
+          
+          if (jmsClientVMID == null)
+          {
+             throw new IllegalStateException("Can't find jms client id");
+          }
+          
+          endpoint.setRemotingInformation(jmsClientVMID, sessionId);       
+          
+          // Then we inject the version number from to be used
+          
+          Byte ver =
+             (Byte)mi.getMetaData(MetaDataConstants.JMS,
+                                  MetaDataConstants.VERSION_NUMBER);
+          
+          if (ver == null)
+          {
+             throw new IllegalStateException("Can't find version");
+          }
+          
+          endpoint.setUsingVersion(ver.byteValue());
        }
        
-       // Then we inject the unique id of the client VM
-       String jmsClientVMID =
-          (String)mi.getMetaData(MetaDataConstants.JMS,
-                                 MetaDataConstants.JMS_CLIENT_VM_ID);
-       
-       if (jmsClientVMID == null)
-       {
-          throw new IllegalStateException("Can't find jms client id");
-       }
-       
-       endpoint.setRemotingInformation(jmsClientVMID, sessionId);       
-       
-       // Then we inject the version number from to be used
-       
-       Byte ver =
-          (Byte)mi.getMetaData(MetaDataConstants.JMS,
-                               MetaDataConstants.VERSION_NUMBER);
-       
-       if (ver == null)
-       {
-          throw new IllegalStateException("Can't find version");
-       }
-       
-       endpoint.setUsingVersion(ver.byteValue());
-       
-       return del;
+       return res;
     }
     
     // Package protected ---------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/SecurityAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/SecurityAspect.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/SecurityAspect.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -150,20 +150,6 @@
       return invocation.invokeNext();
    }   
    
-   public Object handleGetMessageNow(Invocation invocation) throws Throwable
-   {           
-      checkConsumerAccess(invocation);
-            
-      return invocation.invokeNext();
-   }   
-   
-   public Object handleActivate(Invocation invocation) throws Throwable
-   {           
-      checkConsumerAccess(invocation);
-      
-      return invocation.invokeNext();
-   } 
-   
    protected void checkConsumerAccess(Invocation invocation) throws Throwable
    {
       ConsumerAdvised del = (ConsumerAdvised)invocation.getTargetObject();

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -22,7 +22,7 @@
 package org.jboss.jms.server.endpoint;
 
 import javax.jms.JMSException;
-import org.jboss.jms.delegate.ConnectionDelegate;
+
 import org.jboss.messaging.core.plugin.IdBlock;
 
 /**
@@ -36,15 +36,12 @@
  * $Id$
  */
 public interface ConnectionFactoryEndpoint
-{
-   ConnectionDelegate createConnectionDelegate(String username, String password)
+{ 
+   CreateConnectionResult createConnectionDelegate(String username,
+                                                   String password, 
+                                                   int failedNodeId)
       throws JMSException;
    
-   ConnectionStatus createFailoverConnectionDelegate(String username,
-                                                     String password, 
-                                                     int failedNodeId)
-      throws JMSException;
-   
    byte[] getClientAOPConfig() throws JMSException;
 
    IdBlock getIdBlock(int size) throws JMSException;

Deleted: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -1,65 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
-
-import java.io.Serializable;
-
-import org.jboss.jms.delegate.ConnectionDelegate;
-
-/**
- * A ConnectionStatus
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-public class ConnectionStatus implements Serializable
-{
-   private static final long serialVersionUID = 4311863642735135167L;
-   
-   private ConnectionDelegate delegate;
-   
-   private int actualFailoverNodeId;
-   
-   public ConnectionStatus(ConnectionDelegate del)
-   {
-      this.delegate = del;
-   }
-   
-   public ConnectionStatus(int actualFailoverNode)
-   {
-      this.actualFailoverNodeId = actualFailoverNode;
-   }
-   
-   public ConnectionDelegate getDelegate()
-   {
-      return delegate;
-   }
-   
-   public int getActualFailoverNode()
-   {
-      return actualFailoverNodeId;
-   }
-
-}

Copied: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java (from rev 1760, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java)
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConnectionStatus.java	2006-12-11 01:05:12 UTC (rev 1760)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -0,0 +1,66 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+import java.io.Serializable;
+
+import org.jboss.jms.delegate.ConnectionDelegate;
+
+/**
+ * 
+ * A CreateConnectionResult
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class CreateConnectionResult implements Serializable
+{
+   private static final long serialVersionUID = 4311863642735135167L;
+   
+   private ConnectionDelegate delegate;
+   
+   private int actualFailoverNodeId;
+   
+   public CreateConnectionResult(ConnectionDelegate del)
+   {
+      this.delegate = del;
+   }
+   
+   public CreateConnectionResult(int actualFailoverNode)
+   {
+      this.actualFailoverNodeId = actualFailoverNode;
+   }
+   
+   public ConnectionDelegate getDelegate()
+   {
+      return delegate;
+   }
+   
+   public int getActualFailoverNode()
+   {
+      return actualFailoverNodeId;
+   }
+
+}

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -173,6 +173,8 @@
       {
          log.debug("creating session " + (transacted ? "transacted" :"non transacted")+ ", " + ToString.acknowledgmentMode(acknowledgmentMode) + ", " + (isXA ? "XA": "non XA"));
 
+         log.info("********** CREATING NEW SESSION");
+         
          if (closed)
          {
             throw new IllegalStateException("Connection is closed");

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -94,30 +94,33 @@
 
    // ConnectionFactoryDelegate implementation ----------------------
    
-   /**
-    * Called when a new connection is to be created for failover
-    * The ConnectionStatus instance returns either contains the delegate or the node id of the actual node
-    * Note we cannot query the failover node in a separate call since that might change between
-    * querying it and actually creating the delegate
-    */
-   public ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
+   public CreateConnectionResult createConnectionDelegate(String username, String password, int failedNodeId)
       throws JMSException      
    {
       try
       {
-         //Wait for server side failover to complete
-         int failoverNodeId = serverPeer.waitForFailover(failedNodeId);
-         
-         if (failoverNodeId == -1 || failoverNodeId != serverPeer.getServerPeerID())
+         if (failedNodeId == -1)
          {
-            //We are on the wrong node - or no failover has occurred
-            return new ConnectionStatus(failoverNodeId);
+            //Just a standard createConnection
+            return new CreateConnectionResult(createConnectionDelegateInternal(username, password));            
          }
          else
          {
-            //We are on the right node, and failover has completed
-            //we can now create a connection delegate
-            return new ConnectionStatus(createConnectionDelegateInternal(username, password));
+            //Failover
+            //Wait for server side failover to complete
+            int failoverNodeId = serverPeer.waitForFailover(failedNodeId);
+            
+            if (failoverNodeId == -1 || failoverNodeId != serverPeer.getServerPeerID())
+            {
+               //We are on the wrong node - or no failover has occurred
+               return new CreateConnectionResult(failoverNodeId);
+            }
+            else
+            {
+               //We are on the right node, and failover has completed
+               //we can now create a connection delegate
+               return new CreateConnectionResult(createConnectionDelegateInternal(username, password));
+            }
          }
       }
       catch (Throwable t)
@@ -162,19 +165,6 @@
       return new ClientConnectionDelegate(connectionID, serverPeer.getServerPeerID());
    }
    
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
-      throws JMSException
-   {
-      try
-      {
-         return createConnectionDelegateInternal(username, password);
-      }
-      catch (Throwable t)
-      {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " createConnectionDelegate");
-      }
-   }
-
    public byte[] getClientAOPConfig() throws JMSException
    {
       try

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -24,7 +24,7 @@
 import javax.jms.JMSException;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint;
-import org.jboss.jms.server.endpoint.ConnectionStatus;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.messaging.core.plugin.IdBlock;
 
 /**
@@ -58,17 +58,11 @@
 
    // ConnectionFactoryEndpoint implementation -----------------------
 
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
+   public CreateConnectionResult createConnectionDelegate(String username, String password, int failedNodeId)
       throws JMSException
    {
-      return endpoint.createConnectionDelegate(username, password);
+      return endpoint.createConnectionDelegate(username, password, failedNodeId);
    }
-   
-   public ConnectionStatus createFailoverConnectionDelegate(String username, String password, int failedNodeId)
-      throws JMSException
-   {
-      return endpoint.createFailoverConnectionDelegate(username, password, failedNodeId);
-   }
 
    public byte[] getClientAOPConfig() throws JMSException
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -21,8 +21,8 @@
  */
 package org.jboss.messaging.core.plugin.contract;
 
-import java.util.List;
 import java.util.Map;
+import java.util.Set;
 
 /**
  * A FailoverMapper
@@ -37,5 +37,5 @@
  */
 public interface FailoverMapper
 {
-   Map generateMapping(List nodes);
+   Map generateMapping(Set nodes);
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -627,7 +627,6 @@
            Map valuesOnNode = (Map)entry.getValue();
 
            out.println("<tr><td>Key</td><td>Value</td><td>Class of Value</td></tr>");
-           int bindingCount=0;
            for (Iterator valuesIterator=valuesOnNode.entrySet().iterator();valuesIterator.hasNext();)
            {
                Map.Entry entry2 = (Map.Entry)valuesIterator.next();

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -168,6 +168,8 @@
    private ReplicationListener nodeAddressMapListener;
 
    private boolean started;
+   
+   private QueuedExecutor viewExecutor;         
 
    /*
     * Constructor using Element for configuration
@@ -283,6 +285,8 @@
       failoverMap = new LinkedHashMap();
 
       leftSet = new HashSet();
+      
+      viewExecutor = new QueuedExecutor();
    }
 
    // MessagingComponent overrides
@@ -664,21 +668,6 @@
       return listBindingsForConditionInternal(condition, false);
    }
 
-   public int getFailoverNodeID(int nodeId)
-   {
-      synchronized (failoverMap)
-      {
-         Integer failoverNode = (Integer)failoverMap.get(new Integer(nodeId));
-
-         if (failoverNode == null)
-         {
-            return nodeId;
-         }
-
-         return failoverNode.intValue();
-      }
-   }
-
    public FailoverMapper getFailoverMapper()
    {
       return failoverMapper;
@@ -762,8 +751,11 @@
    public void putReplicantLocally(int originatorNodeID, Serializable key, Serializable replicant)
       throws Exception
    {
+      log.info("##########putReplicantLocally received, before lock");
+      
       synchronized (replicatedData)
       {
+         log.info("putReplicantLocally received, after lock");
          Map m = (Map)replicatedData.get(key);
 
          if (m == null)
@@ -777,6 +769,8 @@
 
          notifyListeners(key, m, true, originatorNodeID);
       }
+      
+      log.info("putReplicantLocally, completed");
    }
 
    /**
@@ -862,6 +856,8 @@
       {
          lock.writeLock().release();
       }
+      
+      log.info("****** binding added");
    }
 
    /*
@@ -1430,7 +1426,7 @@
 
       try
       {
-         log.info("Preparing failover against node " + failedNodeId);
+         log.info(this.currentNodeId + " is performing failover for node " + failedNodeId);
 
          /*
          We make sure a FailoverStatus object is put in the replicated data for the node
@@ -1456,9 +1452,11 @@
 
          status.startFailingOverForNode(failedNodeId);
 
+         log.info("Putting state that failover is starting");
+         
          put(FAILED_OVER_FOR_KEY, status);
 
-         log.info("Put into failed over map that starting failover");
+         log.info("Put state that failover is starting");
 
          //Get the map of queues for the failed node
 
@@ -1523,13 +1521,11 @@
             this.deleteBinding(failedNodeId, queueName);
 
             log.info("deleted binding for " + queueName);
+            
+            //Note we do not need to send an unbind request across the cluster - this is because
+            //when the node crashes a view change will hit the other nodes and that will cause
+            //all binding data for that node to be removed anyway
 
-            //Then an unbind request is sent - this cause other nodes to also remove it from the in memory
-            //condition and name maps
-            UnbindRequest unbindRequest = new UnbindRequest(failedNodeId, queueName);
-
-            syncSendRequest(unbindRequest);
-
             //If there is already a queue registered with the same name, then we set a flag "failed" on the
             //binding and then the queue will go into a special list of failed bindings
             //otherwise we treat at as a normal queue
@@ -1586,7 +1582,9 @@
          //TODO - should this be in a finally? I'm not sure
          status.finishFailingOver();
 
+         log.info("Putting state that failover has completed");
          put(FAILED_OVER_FOR_KEY, status);
+         log.info("Put state that failover has completed");
       }
       finally
       {
@@ -2105,15 +2103,6 @@
       }
    }
 
-   /**
-    * Is the current node the failover node for node <nodeId>?
-    * @param nodeId
-    */
-   private boolean isFailoverNodeForNode(int nodeId)
-   {
-      return this.currentNodeId == getFailoverNodeID(nodeId);
-   }
-
    private byte[] getStateAsBytes() throws Exception
    {
       List bindings = new ArrayList();
@@ -2322,26 +2311,55 @@
       //Cleanup any hanging transactions - we do this irrespective of whether we crashed
       check(theNodeId);
 
-      //Need to evaluate this before we regenerate the failover map
-      boolean isFailover = isFailoverNodeForNode(theNodeId.intValue());
-
-      log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
-
-      log.info("Crashed: " + crashed);
-
-      //Remove any replicant data and non durable bindings for the node - again we need to do this
-      //irrespective of whether we crashed
-      //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
-      removeDataForNode(theNodeId);
-
-      if (crashed && isFailover)
-      {
-         //The node crashed and we are the failover node
-         //so let's perform failover
-
-         //TODO server side valve
-
-         failOver(theNodeId.intValue());
+      synchronized (failoverMap)
+      {         
+         //Need to evaluate this before we regenerate the failover map
+         Integer failoverNode = (Integer)failoverMap.get(theNodeId);                  
+    
+         if (failoverNode == null)
+         {
+            throw new IllegalStateException("Cannot find failover node for node " + theNodeId);
+         }
+         
+         //debug dump failover map
+         
+         Iterator iter = failoverMap.entrySet().iterator();
+         
+         log.info("Dumping failover map");
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+            
+            Integer nodeId = (Integer)entry.getKey();
+            
+            Integer failoverNodeId = (Integer)entry.getValue();
+            
+            log.info("node->failover node: " + nodeId + " --> " + failoverNodeId);
+         }
+         log.info("end dump");
+         
+         //end debug
+         
+         boolean isFailover = failoverNode.intValue() == this.currentNodeId;
+            
+         log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
+   
+         log.info("Crashed: " + crashed);
+   
+         //Remove any replicant data and non durable bindings for the node - again we need to do this
+         //irrespective of whether we crashed
+         //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
+         removeDataForNode(theNodeId);
+   
+         if (crashed && isFailover)
+         {
+            //The node crashed and we are the failover node
+            //so let's perform failover
+   
+            //TODO server side valve
+   
+            failOver(theNodeId.intValue());
+         }
       }
    }
 
@@ -2442,26 +2460,17 @@
 
       public void viewAccepted(View newView)
       {
-         //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
-         //TODO:     can't we do the same since this is pretty useful?
-         log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
-                  + DefaultClusteredPostOffice.this.getOfficeName());
-
-         // JGroups will make sure this method is never called by more than one thread concurrently
-
-         View oldView = currentView;
-         currentView = newView;
-
          try
          {
-            verifyMembership(oldView, newView);
+            //We queue up changes and execute them asynchronously.
+            //This is because JGroups will not let us do stuff like send synch messages
+            //using the same thread that delivered the view change and this is what we need to
+            //do in failover, for example.
+            viewExecutor.execute(new HandleViewAcceptedRunnable(newView));
          }
-         catch (Throwable e)
+         catch (InterruptedException e)
          {
-            log.error("Caught Exception in MembershipListener", e);
-            IllegalStateException e2 = new IllegalStateException(e.getMessage());
-            e2.setStackTrace(e.getStackTrace());
-            throw e2;
+            log.warn("Caught InterruptedException", e);
          }
       }
 
@@ -2471,9 +2480,47 @@
          return null;
       }
    }
+   
+   private void handleViewAccepted(View newView)
+   {
+      //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
+      //TODO:     can't we do the same since this is pretty useful?
+      log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
+               + DefaultClusteredPostOffice.this.getOfficeName());
 
+      // JGroups will make sure this method is never called by more than one thread concurrently
 
+      View oldView = currentView;
+      currentView = newView;
 
+      try
+      {
+         verifyMembership(oldView, newView);
+      }
+      catch (Throwable e)
+      {
+         log.error("Caught Exception in MembershipListener", e);
+         IllegalStateException e2 = new IllegalStateException(e.getMessage());
+         e2.setStackTrace(e.getStackTrace());
+         throw e2;
+      }
+   }
+
+   private class HandleViewAcceptedRunnable implements Runnable
+   {
+      private View newView;
+      
+      HandleViewAcceptedRunnable(View newView)
+      {
+         this.newView = newView;
+      }
+      
+      public void run()
+      {
+         handleViewAccepted(newView);
+      }
+   }
+
    /*
     * This class is used to listen for messages on the async channel
     */
@@ -2585,7 +2632,7 @@
 
       private void generateFailoverMap(Map nodeAddressMap)
       {
-         failoverMap = failoverMapper.generateMapping(new ArrayList(nodeAddressMap.keySet()));
+         failoverMap = failoverMapper.generateMapping(nodeAddressMap.keySet());
       }      
    }
 }
\ No newline at end of file

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -21,10 +21,10 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import java.util.ArrayList;
+import java.util.Arrays;
 import java.util.HashMap;
-import java.util.List;
 import java.util.Map;
+import java.util.Set;
 
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.FailoverMapper;
@@ -45,15 +45,17 @@
 {
    private static final Logger log = Logger.getLogger(DefaultFailoverMapper.class);
 
-   /** This receives a List<Integer> of nodes and returns a Map<Integer,Integer> of nodes to be used on failover logic */
-   public Map generateMapping(List nodes)
+   /*
+    * Generate a mapping given a set of nodes - nodes will be sorted by the method
+    * @see org.jboss.messaging.core.plugin.contract.FailoverMapper#generateMapping(java.util.Set)
+    */
+   public Map generateMapping(Set nodes)
    {
-      if (!(nodes instanceof ArrayList))
-      {
-         //Convert to array list for fast index access
-         nodes = new ArrayList(nodes);
-      }
+      Integer[] nodesArr = (Integer[])nodes.toArray(new Integer[nodes.size()]);
       
+      //First sort them so every node has a consistent view
+      Arrays.sort(nodesArr);
+      
       int s = nodes.size();
       
       log.info("Generating failover mapping, node size= "+ s);
@@ -70,7 +72,7 @@
             j = 0;
          }
          
-         failoverNodes.put(nodes.get(i), nodes.get(j));
+         failoverNodes.put(nodesArr[i], nodesArr[j]);
       }
       
       return failoverNodes;

Modified: branches/Branch_Client_Failover_Experiment/tests/etc/log4j.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/etc/log4j.xml	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/tests/etc/log4j.xml	2006-12-11 15:27:26 UTC (rev 1763)
@@ -37,9 +37,13 @@
    </category>
 
    <category name="org.jgroups">
-      <priority value="WARN"/>
+      <priority value="TRACE"/>
    </category>
 
+   <category name="org.jboss.remoting">
+         <priority value="TRACE"/>
+   </category>
+
    <category name="org.jboss">
       <priority value="INFO"/>
    </category>

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -22,9 +22,12 @@
 
 package org.jboss.test.messaging.core.plugin.postoffice.cluster;
 
-import java.util.ArrayList;
+import java.util.HashSet;
 import java.util.Map;
+import java.util.Set;
+
 import junit.framework.TestCase;
+
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 
 /**
@@ -38,18 +41,18 @@
 
    public void testMapper()
    {
-      ArrayList list = new ArrayList();
+      Set set = new HashSet();
 
-      list.add(new Integer(50));
-      list.add(new Integer(25));
-      list.add(new Integer(15));
+      set.add(new Integer(50));
+      set.add(new Integer(25));
+      set.add(new Integer(15));
 
       DefaultFailoverMapper mapper = new DefaultFailoverMapper();
-      Map map = mapper.generateMapping(list);
+      Map map = mapper.generateMapping(set);
 
-      assertEquals(new Integer(15),map.get(new Integer(50)));
-      assertEquals(new Integer(50),map.get(new Integer(25)));
-      assertEquals(new Integer(25),map.get(new Integer(15)));
+      assertEquals(new Integer(15),map.get(new Integer(25)));
+      assertEquals(new Integer(50),map.get(new Integer(15)));
+      assertEquals(new Integer(25),map.get(new Integer(50)));
       
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 11:52:22 UTC (rev 1762)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 15:27:26 UTC (rev 1763)
@@ -434,27 +434,44 @@
       
       ClientConnectionFactoryDelegate cf2 = delegates[1];
       
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
       int server0Id = cf1.getServerId();
       
       int server1Id = cf2.getServerId();
+      
+      int server2Id = cf3.getServerId();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
                   
       Map failoverMap = delegate.getFailoverMap();
       
-      int server0FailoverId = ((Integer)failoverMap.get(new Integer(server0Id))).intValue();
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
       
-      // server 0 should failover onto server 1
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
       
-      assertEquals(server1Id, server0FailoverId);
+      // server 1 should failover onto server 2
       
+      assertEquals(server2Id, server1FailoverId);
+      
       Connection conn = null;
       
       try
       {
       
-         //Send a message into a queue on server 0
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
          
-         conn = factory.createConnection();
+         conn.close();
          
+         conn = factory.createConnection(); //connection on server 1
+         
          JBossConnection jbc = (JBossConnection)conn;
          
          ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
@@ -463,13 +480,13 @@
          
          int initialServerID = state.getServerID();
          
-         assertEquals(0, initialServerID);
+         assertEquals(1, initialServerID);
                            
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
-         MessageProducer prod = sess.createProducer(queue0);
+         MessageProducer prod = sess.createProducer(queue1);
          
-         MessageConsumer cons = sess.createConsumer(queue0);
+         MessageConsumer cons = sess.createConsumer(queue1);
          
          final int NUM_MESSAGES = 100;
          
@@ -480,17 +497,17 @@
             prod.send(tm);
          }
          
-         //So now, messages should be in queue0 on server 0
-         //So we now kill server 0
+         //So now, messages should be in queue1 on server 1
+         //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
          
-         log.info("************ KILLING (CRASHING) SERVER 0");
+         log.info("************ KILLING (CRASHING) SERVER 1");
          
-         ServerManagement.getServer(0).destroy();
+         ServerManagement.getServer(1).destroy();
          
          log.info("killed server, now waiting");
          
-         Thread.sleep(25000);
+         Thread.sleep(5000);
          
          log.info("done wait");
          
@@ -500,16 +517,12 @@
          
          log.info("final server id= " + finalServerID);
          
-         //server id should now be 1
+         //server id should now be 2
          
-         assertEquals(1, finalServerID);
+         assertEquals(2, finalServerID);
          
-         log.info("here 2");
-         
          conn.start();
          
-         log.info("here 3");
-         
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons.receive(1000);
@@ -520,7 +533,7 @@
             
             assertEquals("message:" + i, tm.getText());
          }
-         log.info("here 4");
+         log.info("done");
       }
       finally
       {         
@@ -539,42 +552,42 @@
       
    }
    
-   public void testEvenSimplerFailover() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-                  
-      Connection conn = null;
-      
-      try
-      {
-         conn = factory.createConnection();
-                           
-         log.info("************ KILLING (CRASHING) SERVER 0");
-         
-         ServerManagement.getServer(0).destroy();
-         
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(25000);
-         
-         log.info("done wait");                
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-      }
-      
-   }
+//   public void testEvenSimplerFailover() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//                  
+//      Connection conn = null;
+//      
+//      try
+//      {
+//         conn = factory.createConnection();
+//                           
+//         log.info("************ KILLING (CRASHING) SERVER 0");
+//         
+//         ServerManagement.getServer(0).destroy();
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(25000);
+//         
+//         log.info("done wait");                
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
    
    
 // public void testConnectionFactoryConnect() throws Exception



From rawblem at gmail.com  Mon Dec 11 10:43:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 10:43:39 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server
	...
Message-ID: <E1GtnJb-0005c6-Lv@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 10:43:39

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server 
                        JBossServerBehavior.java
  Log:
  Switched publishing for JST artifacts to a JSTPackagesePublisher, which uses the packages infrastructure to build the project. 
  
  Revision  Changes    Path
  1.17      +10 -10    jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerBehavior.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- JBossServerBehavior.java	30 Nov 2006 16:14:32 -0000	1.16
  +++ JBossServerBehavior.java	11 Dec 2006 15:43:39 -0000	1.17
  @@ -21,7 +21,7 @@
    */
   package org.jboss.ide.eclipse.as.core.server;
   
  -import org.eclipse.core.internal.resources.WorkspaceRoot;
  +import org.eclipse.core.resources.IProject;
   import org.eclipse.core.resources.ResourcesPlugin;
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IProgressMonitor;
  @@ -43,15 +43,13 @@
   import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
   import org.jboss.ide.eclipse.as.core.module.PathModuleFactory;
   import org.jboss.ide.eclipse.as.core.publishers.IJBossServerPublisher;
  -import org.jboss.ide.eclipse.as.core.publishers.JstPublisher;
  +import org.jboss.ide.eclipse.as.core.publishers.JstPackagesPublisher;
   import org.jboss.ide.eclipse.as.core.publishers.NullPublisher;
   import org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher;
   import org.jboss.ide.eclipse.as.core.publishers.PathPublisher;
   import org.jboss.ide.eclipse.as.core.runtime.server.IServerStatePoller;
   import org.jboss.ide.eclipse.as.core.runtime.server.polling.PollThread;
   import org.jboss.ide.eclipse.as.core.runtime.server.polling.TwiddlePoller;
  -import org.jboss.ide.eclipse.as.core.runtime.server.polling.TwiddlePoller.TwiddlePollerEvent;
  -import org.jboss.ide.eclipse.as.core.util.SimpleTreeItem;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   
   public class JBossServerBehavior extends ServerBehaviourDelegate {
  @@ -177,18 +175,19 @@
   		if( module.length == 0 ) return;
   		IJBossServerPublisher publisher;
   
  -		int modulePublishState = getServer().getModulePublishState(module);
  +		int modulePublishState = getServer().getModulePublishState(module) + 0;
   		
   		/**
   		 * If our modules are already packaged as ejb jars, wars, aop files, 
   		 * then go ahead and publish
   		 */
  -		if( hasPackagingConfiguration(module) ) {
  -			publisher = new PackagesPublisher(JBossServerCore.getServer(getServer()));
  -		} else if( arePathModules(module)) {
  +		if( arePathModules(module)) {
   			publisher = new PathPublisher(JBossServerCore.getServer(getServer()), this);
  +		} else if( hasPackagingConfiguration(module) ) {
  +			publisher = new PackagesPublisher(JBossServerCore.getServer(getServer()));
   		} else if( areJstModules(module)){
  -			publisher = new JstPublisher(JBossServerCore.getServer(getServer()));
  +			//publisher = new JstPublisher(JBossServerCore.getServer(getServer()));
  +			publisher = new JstPackagesPublisher(JBossServerCore.getServer(getServer()));
   		} else {
   			publisher = new NullPublisher();
   		}
  @@ -224,7 +223,8 @@
   	protected boolean hasPackagingConfiguration(IModule[] module) {
   		try {
   			String projectName = module[0].getName();
  -			return PackagesCore.projectHasPackages(ResourcesPlugin.getWorkspace().getRoot().getProject(projectName));
  +			IProject proj = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
  +			return PackagesCore.getProjectPackages(proj, new NullProgressMonitor()).length == 0 ? false : true;
   		} catch( Exception e ) {} 
   		return false;
   	}
  
  
  


From rawblem at gmail.com  Mon Dec 11 10:43:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 10:43:39 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers
	...
Message-ID: <E1GtnJb-0005cD-Pd@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 10:43:39

  Added:       as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers 
                        JstPackagesPublisher.java
  Log:
  Switched publishing for JST artifacts to a JSTPackagesePublisher, which uses the packages infrastructure to build the project. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/11 15:43:39;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java
  
  Index: JstPackagesPublisher.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.core.publishers;
  
  import org.eclipse.core.resources.IContainer;
  import org.eclipse.core.resources.IProject;
  import org.eclipse.core.runtime.Assert;
  import org.eclipse.core.runtime.CoreException;
  import org.eclipse.core.runtime.IPath;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.core.runtime.IStatus;
  import org.eclipse.core.runtime.NullProgressMonitor;
  import org.eclipse.core.runtime.Path;
  import org.eclipse.core.runtime.Status;
  import org.eclipse.jdt.core.IJavaProject;
  import org.eclipse.jdt.core.JavaCore;
  import org.eclipse.jdt.core.JavaModelException;
  import org.eclipse.jst.server.core.IEnterpriseApplication;
  import org.eclipse.jst.server.core.IWebModule;
  import org.eclipse.wst.server.core.IModule;
  import org.eclipse.wst.server.core.IServer;
  import org.eclipse.wst.server.core.internal.DeletedModule;
  import org.eclipse.wst.server.core.model.ServerBehaviourDelegate;
  import org.jboss.ide.eclipse.as.core.JBossServerCorePlugin;
  import org.jboss.ide.eclipse.as.core.server.JBossServer;
  import org.jboss.ide.eclipse.packages.core.Trace;
  import org.jboss.ide.eclipse.packages.core.model.IPackage;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFileSetWorkingCopy;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFolderWorkingCopy;
  import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
  import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  import org.jboss.ide.eclipse.packages.core.model.internal.PackagesModel;
  import org.jboss.ide.eclipse.packages.core.model.types.JARPackageType;
  
  /**
   *  This class provides a default implementation for packaging different types of projects
   * @author rob.stryker at jboss.com
   */
  public class JstPackagesPublisher implements IJBossServerPublisher {
  
  	private static final String METAINF = "META-INF";
  	private static final String WEBINF = "WEB-INF";
  	private static final String LIB = "lib";
  	private static final String WEBCONTENT = "WebContent";
  	private static final String EARCONTENT = "EarContent";
  	
  	private int state;
  	private JBossServer server;
  	
  	public JstPackagesPublisher(JBossServer server) {
  		this.server = server;
  		state = IServer.PUBLISH_STATE_NONE;
  	}
  	public int getPublishState() {
  		return state;
  	}
  
  
  	public void publishModule(int kind, int deltaKind, int modulePublishState,
  			IModule[] module, IProgressMonitor monitor) throws CoreException {
      	checkClosed(module);
          if(ServerBehaviourDelegate.REMOVED == deltaKind){
          	JstPackagesAssembler publisher = new JstPackagesAssembler();
              publisher.initialize(module,server);
              publisher.unpublish(monitor);
          } else if( ServerBehaviourDelegate.NO_CHANGE != deltaKind || kind == IServer.PUBLISH_FULL || kind == IServer.PUBLISH_CLEAN ){
          	// if there's no change, do nothing. Otherwise, on change or add, re-publish
          	JstPackagesAssembler publisher = new JstPackagesAssembler();
              publisher.initialize(module,server);
              publisher.publish(monitor);
          }
  	}
      private void checkClosed(IModule[] module) throws CoreException {
      	for(int i=0;i<module.length;i++) {
      		if(module[i] instanceof DeletedModule) {	
                  IStatus status = new Status(IStatus.ERROR,JBossServerCorePlugin.PLUGIN_ID,0, "Failure", null);
                  throw new CoreException(status);
      		}
      	}
      }
      
      public static class JstPackagesAssembler {
  		public static final int WAR = 1;
  		public static final int EAR = 2;
  		public static final int SAR = 3;
  		public static final int OTHER = 4;
  		
  		
  		private IModule[] module;
  		private JBossServer jbServer;
  
  		private int assembleType;
  				
  	    public void initialize(IModule[] module, JBossServer server) {
  			this.module = module;
  			this.jbServer = server;
  			if( module.length == 1 ) {
  				if(isModuleType(module[0], "jst.web")) {
  					assembleType = WAR;
  				} else if(isModuleType(module[0], "jst.ear")) {
  					assembleType = EAR;
  				} else {
  					assembleType = OTHER;
  				}
  			}
  	    }
  	    
  		private boolean isModuleType(IModule module, String moduleTypeId){	
  			if(module.getModuleType()!=null && moduleTypeId.equals(module.getModuleType().getId()))
  				return true;
  			return false;
  		}
  
  		public IPackage[] getPackages() {
  			IProject proj = module[0].getProject();
  			if( proj != null) {
  				IPackage[] projPackages = PackagesCore.getProjectPackages(proj, new NullProgressMonitor());
  				if( projPackages.length > 0 ) {
  					return projPackages;
  				}
  			}
  			
  			return new IPackage[] { createTopPackage(new NullProgressMonitor())};
  		}
  		
  		public IPackage createTopPackage(IProgressMonitor monitor) {
  			IPackage topLevel = null;
  			switch( assembleType ) {
  			case WAR:
  				topLevel = createWarPackages(module[0], monitor); break;
  			case EAR:
  				topLevel = createEarPackages(module[0], monitor); break;
  			case OTHER:
  				topLevel = createOtherPackages(module[0], monitor); break;
  			default: break;
  			}
  			return topLevel;
  		}
  		
  		public IStatus[] publish(IProgressMonitor monitor) throws CoreException {
  			IPackage topLevel = createTopPackage(monitor);
  			if( topLevel != null ) {
  				PackagesCore.buildPackage(topLevel, new NullProgressMonitor());
  				PackagesModel.instance().removePackage((IPackage)topLevel);
  			}
  			return null;
  		}
  		
  		public static IPackage createGenericIPackage(IModule module, String deployDirectory, String packageName) {
  			try {
  
  				IProject project = module.getProject();
  				Assert.isNotNull(project);
  				
  				IJavaProject javaProject = JavaCore.create(project);
  				Assert.isNotNull(javaProject);
  				
  				IPath outputPath;
  				try {
  					outputPath = javaProject.getOutputLocation();
  				} catch (JavaModelException e) {
  					e.printStackTrace();
  					return null;
  				}
  				outputPath = outputPath.removeFirstSegments(1);
  				IContainer outputContainer = project.getFolder(outputPath);
  				return createGenericIPackage(module, deployDirectory, packageName, outputContainer);
  			} catch( Exception e ) {
  				e.printStackTrace();
  			}
  			return null;
  		} 
  		
  		public static IPackage createGenericIPackage(IModule module, String deployDirectory, String packageName, IContainer sourceContainer) {
  			IProject project = module.getProject();
  			Assert.isNotNull(project);
  			IPackage jar = PackagesCore.createPackage(project, true);
  			IPackageWorkingCopy jarWC = jar.createPackageWorkingCopy();
  				
  			if( deployDirectory != null ) {
  				jarWC.setDestinationFolder(new Path(deployDirectory));
  				jarWC.setExploded(false);
  			}
  			jarWC.setName(packageName);
  			jar = jarWC.savePackage();
  				
  			IPackageFileSet classes = PackagesCore.createPackageFileSet(project);
  			IPackageFileSetWorkingCopy classesWC = classes.createFileSetWorkingCopy();
  			classesWC.setIncludesPattern("**/*");
  			classesWC.setSourceContainer(sourceContainer);
  			classes = classesWC.saveFileSet();
  			jar.addChild(classes);
  			return jar;
  		}
  		
  		public IPackage createWarPackages(IModule module, IProgressMonitor monitor) {
  			try {
  				IProject proj = module.getProject();
  				IPackage topLevel = createGenericIPackage(module, jbServer.getDeployDirectory(), proj.getName() + ".war");
  				IPackageFolder webinf = addFolder(proj, topLevel, WEBINF);
  				IPackageFolder metainf = addFolder(proj, topLevel, METAINF);
  				IPackageFolder lib = addFolder(proj, metainf, LIB);
  				addFileset(proj, metainf, WEBCONTENT + Path.SEPARATOR + METAINF, null);
  				addFileset(proj, webinf, WEBCONTENT + Path.SEPARATOR + WEBINF, null);
  				
  				IWebModule webModule = (IWebModule)module.loadAdapter(IWebModule.class, monitor);
  				IModule[] childModules = webModule.getModules();
  				
  				for (int i = 0; i < childModules.length; i++) {
  					IModule child = childModules[i];
  					JstPackagesAssembler assembler = new JstPackagesAssembler();
  					assembler.initialize(new IModule[] {child}, jbServer);
  					IPackage[] childPackages = assembler.getPackages();
  					if( childPackages.length > 0 ) {
  						for( int j = 0; j < childPackages.length; j++ ) {
  							lib.addChild(childPackages[j]);
  						}
  					} else {
  						lib.addChild(createGenericIPackage(child, null, child.getProject().getName() + ".jar"));
  					}
  				}
  				return topLevel;
  			} catch( Exception e ) {
  				e.printStackTrace();
  			}
  			return null;
  		}
  		public IPackage createEarPackages(IModule module, IProgressMonitor monitor) {
  			IProject proj = module.getProject();
  			IContainer outputContainer = proj.getFolder(EARCONTENT);
  
  			IPackage topLevel = createGenericIPackage(module, jbServer.getDeployDirectory(), proj.getName() + ".ear", outputContainer);
  			addFileset(proj, topLevel, EARCONTENT, "**/*.*");
  			
  			// now add children
  			IEnterpriseApplication earModule = (IEnterpriseApplication)module.loadAdapter(IEnterpriseApplication.class, monitor);
  			IModule[] childModules = earModule.getModules();
  			for( int i = 0; i < childModules.length; i++ ) {
  				IModule child = childModules[i];
  				JstPackagesAssembler assembler = new JstPackagesAssembler();
  				assembler.initialize(new IModule[] {child}, jbServer);
  				IPackage[] childPackages = assembler.getPackages();
  				if( childPackages.length > 0 ) {
  					for( int j = 0; j < childPackages.length; j++ ) {
  						topLevel.addChild(childPackages[j]);
  					}
  				} else {
  					topLevel.addChild(createGenericIPackage(child, null, child.getProject().getName() + ".jar"));
  				}
  			}
  			
  			PackagesCore.buildPackage(topLevel, new NullProgressMonitor());
  			PackagesModel.instance().removePackage((IPackage)topLevel);
  			return null;
  		}
  		public IPackage createOtherPackages(IModule module, IProgressMonitor monitor) {
  			return null;
  		}
  
  		public IStatus[] unpublish(IProgressMonitor monitor) throws CoreException {
  			String deployDir = jbServer.getDeployDirectory();
  			String fileName = module[0].getProject().getName();
  			String ext = ".jar";
  			switch( assembleType ) {
  				case WAR: ext = ".war"; break;
  				case EAR: ext = ".ear"; break;
  				case SAR: ext = ".sar"; break;
  				case OTHER: ext = ".jar"; break;
  				default: ext = ".jar"; break;
  			}
  			
  			IPath filePath = new Path(deployDir).append(fileName + ext);
  			filePath.toFile().delete();
  			return null;
  		}
  		
  		
  		protected static IPackageFolder addFolder(IProject project, IPackageNode parent, String name) {
  			IPackageFolder folder = PackagesCore.createPackageFolder(project);
  			IPackageFolderWorkingCopy folderWC = folder.createFolderWorkingCopy();
  			folderWC.setName(name);
  			folder = folderWC.saveFolder();
  			parent.addChild(folder);
  			return folder;
  		}
  		protected static IPackageFileSet addFileset(IProject project, IPackageNode parent, String sourcePath, String includePattern) {
  			IPackageFileSet fs = PackagesCore.createPackageFileSet(project);
  			IPackageFileSetWorkingCopy fswc = fs.createFileSetWorkingCopy();
  			Assert.isNotNull(project);
  			IJavaProject javaProject = JavaCore.create(project);
  			Assert.isNotNull(javaProject);
  			IContainer sourceContainer = project.getFolder(new Path(sourcePath));
  
  			fswc.setSourceContainer(sourceContainer);
  			fswc.setIncludesPattern(  includePattern == null ?  "**/*" : includePattern );
  			fs = fswc.saveFileSet();
  			parent.addChild(fs);
  			return fs;
  		}
  }
  
  
  }
  
  
  


From rawblem at gmail.com  Mon Dec 11 10:49:06 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 10:49:06 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers
	...
Message-ID: <E1GtnOs-0005ho-M5@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 10:49:06

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers 
                        PackagesPublisher.java
  Log:
  Splendid! (added removal / undeployment of module)
  
  Revision  Changes    Path
  1.3       +23 -12    jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesPublisher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackagesPublisher.java	30 Nov 2006 16:14:59 -0000	1.2
  +++ PackagesPublisher.java	11 Dec 2006 15:49:06 -0000	1.3
  @@ -68,7 +68,7 @@
       	
       	if( kind == IServer.PUBLISH_INCREMENTAL ) {
       		boolean incremental = false;
  -    		if( modulePublishState == IServer.PUBLISH_STATE_NONE ) return;
  +    		if( modulePublishState == IServer.PUBLISH_STATE_NONE ) incremental = false;
       		if( modulePublishState == IServer.PUBLISH_STATE_INCREMENTAL ) incremental = true;
       		publishModule(incremental, module, monitor);
       		return;
  @@ -87,17 +87,25 @@
   		
   		String projectName = module[0].getName();
   		IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
  -		PackagesCore.buildProject(project, monitor);
  +		if( project.exists() ) {
   		IPackage[] packages = PackagesCore.getProjectPackages(project, new NullProgressMonitor());
   		for( int i = 0; i < packages.length; i++ ) {
   			if( packages[i].isDestinationInWorkspace()) {
   				IFile file = packages[i].getPackageFile();
   				IPath sourcePath = file.getLocation();
   				IPath destPath = new Path(server.getDeployDirectory(true)).append(sourcePath.lastSegment());
  -				boolean deleted = destPath.toFile().delete();
  +					destPath.toFile().delete();
   			} else {
  -				IFile file = packages[i].getPackageFile();
  -				boolean deleted = file.getLocation().toFile().delete();
  +					IPath path = packages[i].getPackageFilePath();
  +					Path deployDir = new Path(server.getDeployDirectory(true));
  +					if( path.toOSString().startsWith(deployDir.toOSString())) {
  +						try {
  +						path.toFile().delete();
  +						} catch( Exception e ) {
  +							e.printStackTrace();
  +						}
  +					}
  +				}
   			}
   		}
   	}
  @@ -108,6 +116,7 @@
   		int inc2 = incremental ? IncrementalProjectBuilder.INCREMENTAL_BUILD : IncrementalProjectBuilder.FULL_BUILD;
   		String projectName = module[0].getName();
   		IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
  +		try {
   		PackagesCore.buildProject(project, inc2, monitor);
   		IPackage[] packages = PackagesCore.getProjectPackages(project, new NullProgressMonitor());
   		for( int i = 0; i < packages.length; i++ ) {
  @@ -123,5 +132,7 @@
   				}
   			}
   		}
  +		}catch( Exception ce ) {
  +		}
   	}
   }
  
  
  


From rawblem at gmail.com  Mon Dec 11 10:51:54 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 10:51:54 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.core  ...
Message-ID: <E1GtnRa-0005lZ-5X@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 10:51:54

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core  plugin.xml
  Log:
  Made the packaged adapter "heavier" so that we are less likely to get multiple modules for the same project. (In other words, a WTP module will not have a corresponding PackagedModule, whereas a regular java project will)
  
  Revision  Changes    Path
  1.22      +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- plugin.xml	28 Nov 2006 17:41:54 -0000	1.21
  +++ plugin.xml	11 Dec 2006 15:51:54 -0000	1.22
  @@ -171,7 +171,7 @@
         <moduleArtifactAdapter
               class="org.jboss.ide.eclipse.as.core.module.PackagedArtifactAdapter"
               id="org.jboss.ide.eclipse.as.core.PackagedArtifactAdapter"
  -            priority="20">
  +            priority="0">
            <enablement>
               <or>
                  <instanceof value="org.eclipse.core.resources.IProject"/>
  
  
  


From rawblem at gmail.com  Mon Dec 11 10:53:03 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 10:53:03 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers
	...
Message-ID: <E1GtnSh-0005nD-8M@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 10:53:03

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers 
                        EventLogViewProvider.java
  Log:
  Added null checks. They came up in testing but not consistantly, so really I'm not sure they need to be there. They might have only shown up in testing due to some crazy breakpoint locations. I don't know. 
  
  Revision  Changes    Path
  1.5       +2 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EventLogViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- EventLogViewProvider.java	30 Nov 2006 16:13:52 -0000	1.4
  +++ EventLogViewProvider.java	11 Dec 2006 15:53:03 -0000	1.5
  @@ -131,7 +131,7 @@
   				for( int i = 0; i < children.length; i++ ) {
   					if( children[i] instanceof EventLogTreeItem ) {
   						String type = ((EventLogTreeItem)children[i]).getEventClass();
  -						if( type.equals(parentElement))
  +						if( type != null && type.equals(parentElement))
   							items.add(children[i]);
   					}
   				}
  @@ -208,6 +208,7 @@
   	    }
   
   	    public String getText(Object element) {
  +	    	if( element == null ) return "NULL, ERROR";
   	    	String suffix = getShowTimestamp() ? createTimestamp(element) : "";
   	    	if( labelProviderDelegates == null )
   	    		loadLabelProviderDelegates();
  
  
  


From rawblem at gmail.com  Mon Dec 11 10:55:16 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 10:55:16 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui  ...
Message-ID: <E1GtnUq-0005od-L5@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 10:55:16

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui  plugin.xml
  Log:
  I didnt like the idea of that extension anyway...  (timeout listener)
  
  Revision  Changes    Path
  1.27      +2 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- plugin.xml	4 Dec 2006 17:47:08 -0000	1.26
  +++ plugin.xml	11 Dec 2006 15:55:16 -0000	1.27
  @@ -172,13 +172,14 @@
               providerClass="org.jboss.ide.eclipse.as.ui.viewproviders.DescriptorXPathViewProvider"/>
               -->
      </extension>
  +   <!--
         <extension
               point="org.jboss.ide.eclipse.as.core.pollerTimeoutListener">
            <pollerTimeoutListener
                  listener="org.jboss.ide.eclipse.as.ui.views.server.TwiddlePollerListener"
                  pollerType="org.jboss.ide.eclipse.as.core.runtime.server.internal.TwiddlePoller"/>
         </extension>
  -   
  +	-->   
   
      <extension
            point="org.eclipse.ui.perspectiveExtensions">
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 11:10:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 11:10:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r58975 - in projects/microcontainer/trunk:
	. kernel/src/main/org/jboss/kernel/plugins/deployment/xml
	spring-int spring-int/src spring-int/src/main
	spring-int/src/main/org spring-int/src/main/org/jboss
	spring-int/src/main/org/jboss/spring
	spring-int/src/main/org/jboss/spring/deployment
	spring-int/src/main/org/jboss/spring/deployment/xml
	spring-int/src/resources spring-int/src/resources/schema
Message-ID: <E1Gtnjn-0006Et-Gc@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-11 11:10:29 -0500 (Mon, 11 Dec 2006)
New Revision: 58975

Added:
   projects/microcontainer/trunk/spring-int/
   projects/microcontainer/trunk/spring-int/src/
   projects/microcontainer/trunk/spring-int/src/main/
   projects/microcontainer/trunk/spring-int/src/main/org/
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaInitializer.java
   projects/microcontainer/trunk/spring-int/src/resources/
   projects/microcontainer/trunk/spring-int/src/resources/schema/
   projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
   projects/microcontainer/trunk/spring-int/src/tests/
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java
Log:
JBMICROCONT-26; initial code commit, missing build and tests

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -359,7 +359,7 @@
       // value can take characters
       valueType.setSimpleType(ValueCharactersHandler.HANDLER);
       
-      BeanSchemaBindingHelper.configureValueBindings(valueType);
+      configureValueBindings(valueType);
    }
 
    /**

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,47 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment;
+
+import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+import org.jboss.beans.metadata.spi.LifecycleMetaData;
+import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
+import org.jboss.dependency.spi.ControllerState;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class AbstractConstructorArg extends AbstractParameterMetaData
+{
+   private boolean explicitIndex;
+
+   public void setIndex(int index)
+   {
+      explicitIndex = true;
+      super.setIndex(index);
+   }
+
+   public boolean isExplicitIndex()
+   {
+      return explicitIndex;
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment;
+
+import org.jboss.beans.metadata.spi.LifecycleMetaData;
+import org.jboss.dependency.spi.ControllerState;
+import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class AbstractSpringDeployment extends AbstractKernelDeployment
+{
+   /* default init lifecycle method */
+   protected LifecycleMetaData create;
+
+   /* default destroy lifecycle method */
+   protected LifecycleMetaData destroy;
+
+   public LifecycleMetaData getCreate()
+   {
+      return create;
+   }
+
+   public void setCreate(LifecycleMetaData create)
+   {
+      create.setState(ControllerState.CREATE);
+      this.create = create;
+   }
+
+   public LifecycleMetaData getDestroy()
+   {
+      return destroy;
+   }
+
+   public void setDestroy(LifecycleMetaData destroy)
+   {
+      destroy.setState(ControllerState.CREATE);
+      this.destroy = destroy;
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,62 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.jboss.spring.deployment.AbstractConstructorArg;
+import org.xml.sax.Attributes;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ConstructorArgHandler extends DefaultElementHandler
+{
+   /**
+    * The beans handler
+    */
+   public static final ConstructorArgHandler HANDLER = new ConstructorArgHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractConstructorArg();
+   }
+
+   public void attributes(Object object, QName qName, ElementBinding elementBinding, Attributes attrs, NamespaceContext namespaceContext)
+   {
+      AbstractParameterMetaData value = (AbstractParameterMetaData) object;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("index".equals(localName))
+            value.setIndex(Integer.parseInt(attrs.getValue(i)));
+         else if ("type".equals(localName))
+            value.setType(attrs.getValue(i));
+         // todo ref + value
+      }
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
+import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
+import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
+import org.jboss.beans.metadata.spi.ConstructorMetaData;
+import org.jboss.beans.metadata.spi.ParameterMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
+import org.jboss.spring.deployment.AbstractConstructorArg;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ConstructorArgInterceptor extends DefaultElementInterceptor
+{
+   /**
+    * The interceptor
+    */
+   public static final ConstructorArgInterceptor INTERCEPTOR = new ConstructorArgInterceptor();
+
+   public void add(Object parent, Object child, QName name)
+   {
+      AbstractBeanMetaData bean = (AbstractBeanMetaData) parent;
+      ConstructorMetaData constructor = bean.getConstructor();
+      if (constructor == null) {
+         AbstractConstructorMetaData tmpConstructor = new AbstractConstructorMetaData();
+         tmpConstructor.setParameters(new ArrayList<ParameterMetaData>());
+         constructor = tmpConstructor;
+         bean.setConstructor(constructor);
+      }
+      AbstractParameterMetaData parameter = (AbstractParameterMetaData) child;
+      // should not be null, since we are the only one creating constructor
+      List<ParameterMetaData> parameters = constructor.getParameters();
+      if (parameter instanceof AbstractConstructorArg && ((AbstractConstructorArg)parameter).isExplicitIndex() == false)
+      {
+         parameter.setIndex(parameters.size());
+      }
+      parameters.add(parameter);
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractDependencyValueMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.xml.sax.Attributes;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class RefHandler extends DefaultElementHandler
+{
+   /**
+    * The beans handler
+    */
+   public static final RefHandler HANDLER = new RefHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractDependencyValueMetaData();
+   }
+
+   public void attributes(Object object, QName qName, ElementBinding elementBinding, Attributes attrs, NamespaceContext namespaceContext)
+   {
+      AbstractDependencyValueMetaData value = (AbstractDependencyValueMetaData) object;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("bean".equals(localName))
+            value.setValue(attrs.getValue(i));
+      }
+   }
+
+   public Object endElement(Object o, QName qName, ElementBinding element)
+   {
+      AbstractDependencyValueMetaData x = (AbstractDependencyValueMetaData) o;
+      String name = (String) x.getUnderlyingValue();
+      if (name == null || name.trim().length() == 0)
+         throw new IllegalArgumentException("Null or empty bean in ref.");
+      return o;
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,60 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.xml.sax.Attributes;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringBeanHandler extends DefaultElementHandler
+{
+   /**
+    * The beans handler
+    */
+   public static final SpringBeanHandler HANDLER = new SpringBeanHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractBeanMetaData();
+   }
+
+   public void attributes(Object o, QName elementName, ElementBinding element, Attributes attrs, NamespaceContext nsCtx)
+   {
+      AbstractBeanMetaData bean = (AbstractBeanMetaData) o;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("id".equals(localName))
+            bean.setName(attrs.getValue(i));
+         else if ("class".equals(localName))
+            bean.setBean(attrs.getValue(i));
+      }
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,69 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractLifecycleMetaData;
+import org.jboss.spring.deployment.AbstractSpringDeployment;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.xml.sax.Attributes;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringBeansHandler extends DefaultElementHandler
+{
+   /**
+    * The beans handler
+    */
+   public static final SpringBeansHandler HANDLER = new SpringBeansHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractSpringDeployment();
+   }
+
+   public void attributes(Object object, QName qName, ElementBinding elementBinding, Attributes attrs, NamespaceContext namespaceContext)
+   {
+      AbstractSpringDeployment deployment = (AbstractSpringDeployment) object;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("default-init-method".equals(localName))
+         {
+            AbstractLifecycleMetaData create = new AbstractLifecycleMetaData();
+            create.setMethodName(attrs.getValue(i));
+            deployment.setCreate(create);
+         }
+         else if ("default-destroy-method".equals(localName))
+         {
+            AbstractLifecycleMetaData destroy = new AbstractLifecycleMetaData();
+            destroy.setMethodName(attrs.getValue(i));
+            deployment.setDestroy(destroy);
+         }
+      }
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,56 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.QName;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
+import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringBeansInterceptor extends DefaultElementInterceptor
+{
+   /**
+    * The interceptor
+    */
+   public static final SpringBeansInterceptor INTERCEPTOR = new SpringBeansInterceptor();
+
+   public void add(Object parent, Object child, QName name)
+   {
+      AbstractKernelDeployment deployment = (AbstractKernelDeployment) parent;
+      AbstractBeanMetaData bean = (AbstractBeanMetaData) child;
+      List<BeanMetaDataFactory> beans = deployment.getBeanFactories();
+      if (beans == null)
+      {
+         beans = new ArrayList<BeanMetaDataFactory>();
+         deployment.setBeanFactories(beans);
+      }
+      beans.add(bean);
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractCollectionMetaData;
+import org.jboss.beans.metadata.plugins.AbstractListMetaData;
+import org.jboss.beans.metadata.plugins.AbstractSetMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.xml.sax.Attributes;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringCollectionHandler extends DefaultElementHandler
+{
+   /**
+    * The handler
+    */
+   public static final SpringCollectionHandler HANDLER = new SpringCollectionHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      String typeName = element.getQName().getLocalPart();
+      // todo - does this work?
+      if ("list".equals(typeName))
+         return new AbstractListMetaData();
+      else if ("set".equals(typeName))
+         return new AbstractSetMetaData();
+      else
+         throw new IllegalArgumentException("Unsupported collection type=" + typeName);
+   }
+
+   public void attributes(Object o, QName elementName, ElementBinding element, Attributes attrs, NamespaceContext nsCtx)
+   {
+      AbstractCollectionMetaData collection = (AbstractCollectionMetaData) o;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("value-type".equals(localName))
+            collection.setElementType(attrs.getValue(i));
+      }
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,212 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
+import org.jboss.xb.binding.sunday.unmarshalling.TypeBinding;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringSchemaBinding
+{
+
+   /**
+    * The namespace
+    */
+   public static final String SPRING_DEPLOYER_NS = "http://www.springframework.org/schema/beans";
+
+   /**
+    * The beans binding
+    */
+   public static final QName beansTypeQName = new QName(SPRING_DEPLOYER_NS, "beansType");
+
+   /**
+    * The beans element name
+    */
+   public static final QName beansQName = new QName(SPRING_DEPLOYER_NS, "beans");
+
+   /**
+    * The bean binding
+    */
+   public static final QName beanTypeQName = new QName(SPRING_DEPLOYER_NS, "beanType");
+
+   /**
+    * The bean element name
+    */
+   public static final QName beanQName = new QName(SPRING_DEPLOYER_NS, "bean");
+
+   /**
+    * The ref binding
+    */
+   public static final QName refTypeQName = new QName(SPRING_DEPLOYER_NS, "refType");
+
+   /**
+    * The ref element name
+    */
+   public static final QName refQName = new QName(SPRING_DEPLOYER_NS, "ref");
+
+   /**
+    * The constructor arg binding
+    */
+   public static final QName constructorTypeQName = new QName(SPRING_DEPLOYER_NS, "constructorArgType");
+
+   /**
+    * The constructor arg element name
+    */
+   public static final QName constructorQName = new QName(SPRING_DEPLOYER_NS, "constructor-arg");
+
+   /**
+    * The property binding
+    */
+   public static final QName propertyTypeQName = new QName(SPRING_DEPLOYER_NS, "propertyType");
+
+   /**
+    * The property element name
+    */
+   public static final QName propertyQName = new QName(SPRING_DEPLOYER_NS, "property");
+
+   /**
+    * The value binding
+    */
+   public static final QName valueTypeQName = new QName(SPRING_DEPLOYER_NS, "valueType");
+
+   /**
+    * The value element name
+    */
+   public static final QName valueQName = new QName(SPRING_DEPLOYER_NS, "value");
+
+   /**
+    * The null element name
+    */
+   public static final QName nullQName = new QName(SPRING_DEPLOYER_NS, "null");
+
+   /**
+    * The list binding
+    */
+   public static final QName listTypeQName = new QName(SPRING_DEPLOYER_NS, "listOrSetType");
+
+   /**
+    * The list element name
+    */
+   public static final QName listQName = new QName(SPRING_DEPLOYER_NS, "list");
+
+   /**
+    * The set element name
+    */
+   public static final QName setQName = new QName(SPRING_DEPLOYER_NS, "set");
+
+   /**
+    * The map binding
+    */
+   public static final QName mapTypeQName = new QName(SPRING_DEPLOYER_NS, "mapType");
+
+   /**
+    * The map element name
+    */
+   public static final QName mapQName = new QName(SPRING_DEPLOYER_NS, "map");
+
+   /**
+    * The entry binding
+    */
+   public static final QName entryTypeQName = new QName(SPRING_DEPLOYER_NS, "entryType");
+
+   /**
+    * The entry element name
+    */
+   public static final QName entryQName = new QName(SPRING_DEPLOYER_NS, "entry");
+
+   /**
+    * The key element name
+    */
+   public static final QName keyQName = new QName(SPRING_DEPLOYER_NS, "key");
+
+   public static void init(SchemaBinding schemaBinding)
+   {
+      initDeployment(schemaBinding);
+      initBean(schemaBinding);
+      initArtifacts(schemaBinding);
+   }
+
+   /**
+    * Initialize beans part of the schema binding
+    *
+    * @param schemaBinding the schema binding
+    */
+   public static void initDeployment(SchemaBinding schemaBinding)
+   {
+      // beans binding
+      TypeBinding beansType = schemaBinding.getType(beansTypeQName);
+      SpringSchemaBindingHelper.initBeansHandler(beansType);
+   }
+
+   /**
+    * Initialize single bean part of the schema binding
+    *
+    * @param schemaBinding the schema binding
+    */
+   private static void initBean(SchemaBinding schemaBinding)
+   {
+      // bean binding
+      TypeBinding beanType = schemaBinding.getType(beanTypeQName);
+      SpringSchemaBindingHelper.initBeanHandler(beanType);
+   }
+
+   /**
+    * Initialize other parts of the schema binding
+    *
+    * @param schemaBinding the schema binding
+    */
+   private static void initArtifacts(SchemaBinding schemaBinding)
+   {
+      // ref / injection
+      TypeBinding refType = schemaBinding.getType(refTypeQName);
+      SpringSchemaBindingHelper.initRefHandler(refType);
+
+      // constructor arg
+      TypeBinding constructorArgType = schemaBinding.getType(constructorTypeQName);
+      SpringSchemaBindingHelper.initConstructorArgHandler(constructorArgType);
+
+      // property binding
+      TypeBinding propertyType = schemaBinding.getType(propertyTypeQName);
+      SpringSchemaBindingHelper.initPropertyHandler(propertyType);
+
+      // value binding
+      TypeBinding valueType = schemaBinding.getType(valueTypeQName);
+      SpringSchemaBindingHelper.initValueHandler(valueType);
+
+      // list or set
+      TypeBinding collectionType = schemaBinding.getType(listTypeQName);
+      SpringSchemaBindingHelper.initCollectionHandler(collectionType);
+
+      // map
+      TypeBinding mapType = schemaBinding.getType(mapTypeQName);
+      SpringSchemaBindingHelper.initMapHandler(mapType);
+
+      // entry type
+      TypeBinding entryType = schemaBinding.getType(entryTypeQName);
+      SpringSchemaBindingHelper.initEntryHandler(entryType);
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,109 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import org.jboss.xb.binding.sunday.unmarshalling.TypeBinding;
+import org.jboss.kernel.plugins.deployment.xml.*;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringSchemaBindingHelper
+{
+
+   public static void initBeansHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(SpringBeansHandler.HANDLER);
+      // handle beans
+      typeBinding.pushInterceptor(SpringSchemaBinding.beansQName, SpringBeansInterceptor.INTERCEPTOR);
+      // todo alias
+      // todo import
+   }
+
+   public static void initBeanHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(SpringBeanHandler.HANDLER);
+      // handle constructor-arg
+      typeBinding.pushInterceptor(SpringSchemaBinding.constructorQName, ConstructorArgInterceptor.INTERCEPTOR);
+      // handle properties
+      typeBinding.pushInterceptor(SpringSchemaBinding.propertyQName, BeanPropertyInterceptor.INTERCEPTOR);
+      // todo lookup-method
+      // todo replaced method
+   }
+
+   public static void initRefHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(RefHandler.HANDLER);
+   }
+
+   public static void initConstructorArgHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(ConstructorArgHandler.HANDLER);
+   }
+
+   public static void initPropertyHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(PropertyHandler.HANDLER);
+      // property can take characters
+      typeBinding.setSimpleType(PropertyCharactersHandler.HANDLER);
+      // configure
+      configureValueBindings(typeBinding);
+   }
+
+   public static void initValueHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(ValueHandler.HANDLER);
+      // value can take characters
+      typeBinding.setSimpleType(ValueCharactersHandler.HANDLER);
+      // configure
+      configureValueBindings(typeBinding);
+   }
+
+   public static void initCollectionHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(CollectionHandler.HANDLER);
+      // configure
+      configureValueBindings(typeBinding);
+   }
+
+   public static void initMapHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(MapHandler.HANDLER);
+      // entry has an entry
+      typeBinding.pushInterceptor(SpringSchemaBinding.entryQName, MapEntryInterceptor.INTERCEPTOR);
+   }
+
+   public static void initEntryHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(EntryHandler.HANDLER);
+      // entry has a key
+      typeBinding.pushInterceptor(SpringSchemaBinding.keyQName, EntryKeyInterceptor.INTERCEPTOR);
+      // entry has a value
+      typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, EntryValueInterceptor.INTERCEPTOR);
+   }
+
+   public static void configureValueBindings(TypeBinding typeBinding)
+   {
+      //todo
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaInitializer.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaInitializer.java	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaInitializer.java	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,39 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import org.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
+import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingInitializer;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringSchemaInitializer implements SchemaBindingInitializer
+{
+
+   public SchemaBinding init(SchemaBinding schema)
+   {
+      SpringSchemaBinding.init(schema);
+      return schema;
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-11 13:42:04 UTC (rev 58974)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-11 16:10:29 UTC (rev 58975)
@@ -0,0 +1,1150 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- A prototype Spring xsd schema for the pojoserver xml deployer
+$Id: mc-spring-beans_2_0.xsd 56471 2006-08-31 10:44:05 +0200 (Pon, 11 dec 2006) alesj $
+ -->
+<xsd:schema xmlns="http://www.springframework.org/schema/beans"
+            xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+            targetNamespace="http://www.springframework.org/schema/beans">
+
+   <xsd:import namespace="http://www.w3.org/XML/1998/namespace"/>
+
+   <xsd:annotation>
+      <xsd:documentation><![CDATA[
+	Spring XML Beans Schema, version 2.0
+	Authors: Rob Harrop, Juergen Hoeller
+
+	This defines a simple and consistent way of creating a namespace
+	of JavaBeans objects, managed by a Spring BeanFactory, read by
+	XmlBeanDefinitionReader (with DefaultBeanDefinitionDocumentReader).
+
+	This document type is used by most Spring functionality, including
+	web application contexts, which are based on bean factories.
+
+	Each "bean" element in this document defines a JavaBean.
+	Typically the bean class is specified, along with JavaBean properties
+	and/or constructor arguments.
+
+	A bean instance can be a "singleton" (shared instance) or a "prototype"
+	(independent instance). Further scopes can be provided by extended
+	bean factories, for example in a web environment.
+
+	References among beans are supported, that is, setting a JavaBean property
+	or a constructor argument to refer to another bean in the same factory
+	(or an ancestor factory).
+
+	As alternative to bean references, "inner bean definitions" can be used.
+	Singleton flags of such inner bean definitions are effectively ignored:
+	inner beans are typically anonymous prototypes.
+
+	There is also support for lists, sets, maps, and java.util.Properties
+	as bean property types or constructor argument types.
+
+	Some complex types are pulled out of the element definitions - becoming named
+	types to be used with JBossXB binding.
+
+		]]></xsd:documentation>
+   </xsd:annotation>
+
+   <!-- base types -->
+   <xsd:complexType name="identifiedType" abstract="true">
+
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	The unique identifier for a bean. The scope of the identifier
+	is the enclosing bean factory.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:attribute name="id" type="xsd:ID">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The unique identifier for a bean.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <!-- Top-level <beans> tag -->
+   <xsd:element name="beans" type="beansType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	The top level (typically root) element. Allows the definition
+	of default values for all nested bean definitions.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+
+   <xsd:complexType name="beansType">
+      <xsd:sequence>
+         <xsd:element ref="description" minOccurs="0"/>
+
+         <xsd:choice minOccurs="0" maxOccurs="unbounded">
+            <xsd:element ref="import"/>
+            <xsd:element ref="alias"/>
+            <xsd:element ref="bean"/>
+            <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+         </xsd:choice>
+      </xsd:sequence>
+      <xsd:attribute name="default-lazy-init" default="false" type="xsd:boolean">
+         <xsd:annotation>
+
+            <xsd:documentation><![CDATA[
+The default 'lazy-init' value; see the documentation for the
+'lazy-init' attribute of the '<bean>/' element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="default-merge" default="false" type="xsd:boolean">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The default 'merge' value; see the documentation for the
+'merge' attribute of the various collection elements.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="default-dependency-check" default="none">
+
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The default 'dependency-check' value; see the documentation for the
+'dependency-check' attribute of the '<bean>/' element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+         <xsd:simpleType>
+            <xsd:restriction base="xsd:NMTOKEN">
+               <xsd:enumeration value="none"/>
+               <xsd:enumeration value="all"/>
+               <xsd:enumeration value="objects"/>
+               <xsd:enumeration value="simple"/>
+
+            </xsd:restriction>
+         </xsd:simpleType>
+      </xsd:attribute>
+      <xsd:attribute name="default-autowire" default="no">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The default 'autowire' value; see the documentation for the
+'autowire' attribute of the '<bean>/' element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+         <xsd:simpleType>
+            <xsd:restriction base="xsd:NMTOKEN">
+
+               <xsd:enumeration value="byType"/>
+               <xsd:enumeration value="byName"/>
+               <xsd:enumeration value="no"/>
+               <xsd:enumeration value="autodetect"/>
+               <xsd:enumeration value="constructor"/>
+            </xsd:restriction>
+         </xsd:simpleType>
+      </xsd:attribute>
+      <xsd:attribute name="default-init-method" type="xsd:string">
+
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The default 'init-method' value; see the documentation for the
+'init-method' attribute of the '<bean>/' element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="default-destroy-method" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The default 'destroy-method' value; see the documentation for the
+'destroy-method' attribute of the '<bean>/' element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+
+   </xsd:complexType>
+
+   <xsd:element name="description">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Contains informative text describing the purpose of the enclosing
+	element.
+	Used primarily for user documentation of XML bean definition documents.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType mixed="true">
+         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:element name="import">
+      <xsd:annotation>
+         <xsd:documentation source="java:org.springframework.core.io.Resource"><![CDATA[
+	Specifies an XML bean definition resource to import.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType>
+         <xsd:complexContent>
+
+            <xsd:restriction base="xsd:anyType">
+               <xsd:attribute name="resource" type="xsd:string" use="required">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The relative resource location of the XML (bean definition) file to import,
+	for example "myImport.xml" or "includes/myImport.xml" or "../myImport.xml".
+							]]></xsd:documentation>
+                  </xsd:annotation>
+               </xsd:attribute>
+            </xsd:restriction>
+         </xsd:complexContent>
+      </xsd:complexType>
+
+   </xsd:element>
+
+   <xsd:element name="alias">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Defines an alias for a bean (which can reside in a different definition
+	resource).
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType>
+         <xsd:complexContent>
+            <xsd:restriction base="xsd:anyType">
+
+               <xsd:attribute name="name" type="xsd:string" use="required">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The name of the bean to define an alias for.
+							]]></xsd:documentation>
+                  </xsd:annotation>
+               </xsd:attribute>
+               <xsd:attribute name="alias" type="xsd:string" use="required">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The alias name to define for the bean.
+							]]></xsd:documentation>
+                  </xsd:annotation>
+
+               </xsd:attribute>
+            </xsd:restriction>
+         </xsd:complexContent>
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:group name="beanElements">
+      <xsd:sequence>
+         <xsd:element ref="description" minOccurs="0"/>
+
+         <xsd:choice minOccurs="0" maxOccurs="unbounded">
+            <xsd:element ref="meta"/>
+            <xsd:element ref="constructor-arg"/>
+            <xsd:element ref="property"/>
+            <xsd:element ref="lookup-method"/>
+            <xsd:element ref="replaced-method"/>
+            <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+         </xsd:choice>
+      </xsd:sequence>
+
+   </xsd:group>
+
+   <xsd:attributeGroup name="beanAttributes">
+      <xsd:attribute name="name" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Can be used to create one or more aliases illegal in an (XML) id.
+	Multiple aliases can be separated by any number of spaces, commas,
+	or semi-colons (or indeed any mixture of the three).
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="class" type="xsd:string">
+
+         <xsd:annotation>
+            <xsd:documentation source="java:java.lang.Class"><![CDATA[
+	The fully qualified name of the bean's class, except if it pure serves as parent for child bean definitions.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="parent" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The name of the parent bean definition.
+
+	Will use the bean class of the parent if none is specified, but can
+	also override it. In the latter case, the child bean class must be
+	compatible with the parent, i.e. accept the parent's property values
+	and constructor argument values, if any.
+
+	A child bean definition will inherit constructor argument values,
+	property values and method overrides from the parent, with the option
+	to add new values. If init method, destroy method, factory bean and/or
+	factory method are specified, they will override the corresponding
+	parent settings.
+
+	The remaining settings will always be taken from the child definition:
+	depends on, autowire mode, dependency check, scope, lazy init.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+
+      <xsd:attribute name="scope" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The scope of this bean: typically "singleton" (one shared instance,
+	which will be returned by all calls to getBean() with the id),
+	or "prototype" (independent instance resulting from each call to
+	getBean(). Default is "singleton".
+
+	Singletons are most commonly used, and are ideal for multi-threaded
+	service objects. Further scopes, such as "request" or "session",
+	might be supported by extended bean factories (for example, in a
+	web environment).
+
+	Note: This attribute will not be inherited by child bean definitions.
+	Hence, it needs to be specified per concrete bean definition.
+
+	Inner bean definitions inherit the singleton status of their containing
+	bean definition, unless explicitly specified: The inner bean will be a
+	singleton if the containing bean is a singleton, and a prototype if
+	the containing bean has any other scope.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="abstract" type="xsd:boolean">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Is this bean "abstract", that is, not meant to be instantiated itself
+	but rather just serving as parent for concrete child bean definitions?
+	The default is "false". Specify "true" to tell the bean factory to not
+	try to instantiate that particular bean in any case.
+
+	Note: This attribute will not be inherited by child bean definitions.
+	Hence, it needs to be specified per abstract bean definition.
+				]]></xsd:documentation>
+         </xsd:annotation>
+
+      </xsd:attribute>
+      <xsd:attribute name="lazy-init" default="default" type="defaultable-boolean">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Indicates whether or not this bean is to be lazily initialized.
+	If false, it will be instantiated on startup by bean factories
+	that perform eager initialization of singletons. The default is
+	"false".
+
+	Note: This attribute will not be inherited by child bean definitions.
+	Hence, it needs to be specified per concrete bean definition.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="autowire" default="default">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Controls whether bean properties are "autowired".
+	This is an automagical process in which bean references don't need
+	to be coded explicitly in the XML bean definition file, but rather the
+	Spring container works out dependencies.
+
+	There are 5 modes:
+
+	1. "no"
+	The traditional Spring default. No automagical wiring. Bean references
+	must be defined in the XML file via the <ref/> element (or "ref"
+	attribute). We recommend this in most cases as it makes documentation
+	more explicit.
+
+	2. "byName"
+	Autowiring by property name. If a bean of class Cat exposes a dog
+	property, Spring will try to set this to the value of the bean "dog"
+	in the current container. If there is no matching bean by name, nothing
+	special happens; use dependency-check="objects" to raise an error in
+	that case.
+
+	3. "byType"
+	Autowiring if there is exactly one bean of the property type in the
+	container. If there is more than one, a fatal error is raised, and
+	you cannot use byType autowiring for that bean. If there is none,
+	nothing special happens; use dependency-check="objects" to raise an
+	error in that case.
+
+	4. "constructor"
+	Analogous to "byType" for constructor arguments. If there is not exactly
+	one bean of the constructor argument type in the bean factory, a fatal
+	error is raised.
+
+	5. "autodetect"
+	Chooses "constructor" or "byType" through introspection of the bean
+	class. If a default constructor is found, "byType" gets applied.
+
+	Note that explicit dependencies, i.e. "property" and "constructor-arg"
+	elements, always override autowiring. Autowire behavior can be combined
+	with dependency checking, which will be performed after all autowiring
+	has been completed.
+
+	Note: This attribute will not be inherited by child bean definitions.
+	Hence, it needs to be specified per concrete bean definition.
+				]]></xsd:documentation>
+
+         </xsd:annotation>
+         <xsd:simpleType>
+            <xsd:restriction base="xsd:NMTOKEN">
+               <xsd:enumeration value="byType"/>
+               <xsd:enumeration value="byName"/>
+               <xsd:enumeration value="default"/>
+               <xsd:enumeration value="no"/>
+               <xsd:enumeration value="autodetect"/>
+               <xsd:enumeration value="constructor"/>
+
+            </xsd:restriction>
+         </xsd:simpleType>
+      </xsd:attribute>
+      <xsd:attribute name="dependency-check" default="default">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Controls whether or not to check whether all of this
+	beans dependencies, expressed in its properties, are satisfied.
+	The default is to perform no dependency checking.
+
+	"simple" type dependency checking includes primitives and String
+	"object" includes collaborators (other beans in the factory)
+	"all" includes both types of dependency checking
+
+	Note: This attribute will not be inherited by child bean definitions.
+	Hence, it needs to be specified per concrete bean definition.
+				]]></xsd:documentation>
+         </xsd:annotation>
+         <xsd:simpleType>
+            <xsd:restriction base="xsd:NMTOKEN">
+
+               <xsd:enumeration value="default"/>
+               <xsd:enumeration value="none"/>
+               <xsd:enumeration value="all"/>
+               <xsd:enumeration value="objects"/>
+               <xsd:enumeration value="simple"/>
+            </xsd:restriction>
+         </xsd:simpleType>
+      </xsd:attribute>
+      <xsd:attribute name="depends-on" type="xsd:string">
+
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The names of the beans that this bean depends on being initialized.
+	The bean factory will guarantee that these beans get initialized
+	before this bean.
+
+	Note that dependencies are normally expressed through bean properties
+	or constructor arguments. This property should just be necessary for
+	other kinds of dependencies like statics (*ugh*) or database preparation
+	on startup.
+
+	Note: This attribute will not be inherited by child bean definitions.
+	Hence, it needs to be specified per concrete bean definition.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="init-method" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The name of the custom initialization method to invoke after setting
+	bean properties. The method must have no arguments, but may throw any
+	exception.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+
+      <xsd:attribute name="destroy-method" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The name of the custom destroy method to invoke on bean factory
+	shutdown. The method must have no arguments, but may throw any
+	exception.
+
+	Note: Only invoked on beans whose lifecycle is under the full
+	control of the factory - which is always the case for singletons,
+	but not guaranteed for any other scope.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="factory-method" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The name of a factory method to use to create this object. Use
+	constructor-arg elements to specify arguments to the factory method,
+	if it takes arguments. Autowiring does not apply to factory methods.
+
+	If the "class" attribute is present, the factory method will be a static
+	method on the class specified by the "class" attribute on this bean
+	definition. Often this will be the same class as that of the constructed
+	object - for example, when the factory method is used as an alternative
+	to a constructor. However, it may be on a different class. In that case,
+	the created object will *not* be of the class specified in the "class"
+	attribute. This is analogous to FactoryBean behavior.
+
+	If the "factory-bean" attribute is present, the "class" attribute is not
+	used, and the factory method will be an instance method on the object
+	returned from a getBean call with the specified bean name. The factory
+	bean may be defined as a singleton or a prototype.
+
+	The factory method can have any number of arguments. Autowiring is not
+	supported. Use indexed constructor-arg elements in conjunction with the
+	factory-method attribute.
+
+	Setter Injection can be used in conjunction with a factory method.
+	Method Injection cannot, as the factory method returns an instance,
+	which will be used when the container creates the bean.
+				]]></xsd:documentation>
+         </xsd:annotation>
+
+      </xsd:attribute>
+      <xsd:attribute name="factory-bean" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Alternative to class attribute for factory-method usage.
+	If this is specified, no class attribute should be used.
+	This must be set to the name of a bean in the current or
+	ancestor factories that contains the relevant factory method.
+	This allows the factory itself to be configured using Dependency
+	Injection, and an instance (rather than static) method to be used.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="autowire-candidate" type="xsd:boolean">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Indicates whether or not this bean should be considered when looking
+	for candidates to satisfy another beans autowiring requirements.
+				]]></xsd:documentation>
+
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:anyAttribute namespace="##other" processContents="lax"/>
+   </xsd:attributeGroup>
+
+   <xsd:element name="meta" type="metaType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Arbitrary metadata attached to a bean definition.
+			]]></xsd:documentation>
+      </xsd:annotation>
+
+   </xsd:element>
+
+   <xsd:complexType name="metaType">
+      <xsd:attribute name="key" type="xsd:string" use="required">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The key name of the metadata parameter being defined.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="value" type="xsd:string" use="required">
+
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The value of the metadata parameter being defined (as a simple String).
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <xsd:element name="bean" type="beanType">
+      <xsd:annotation>
+         <xsd:documentation source="java:org.springframework.beans.factory.config.BeanDefinition"><![CDATA[
+	Defines a single (usually named) bean.
+
+	A bean definition may contain nested tags for constructor arguments,
+	property values, lookup methods, and replaced methods. Mixing constructor
+	injection and setter injection on the same bean is explicitly supported.
+			]]></xsd:documentation>
+
+      </xsd:annotation>
+   </xsd:element>
+
+   <xsd:complexType name="beanType">
+      <xsd:complexContent>
+         <xsd:extension base="identifiedType">
+            <xsd:group ref="beanElements"/>
+            <xsd:attributeGroup ref="beanAttributes"/>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:element name="constructor-arg" type="constructorArgType">
+      <xsd:annotation>
+         <xsd:documentation source="java:org.springframework.beans.factory.config.ConstructorArgumentValues">
+            <![CDATA[
+	Bean definitions can specify zero or more constructor arguments.
+	This is an alternative to "autowire constructor".
+	Arguments correspond to either a specific index of the constructor
+	argument list or are supposed to be matched generically by type.
+
+	Note: A single generic argument value will just be used once, rather
+	than potentially matched multiple times (as of Spring 1.1).
+
+	constructor-arg elements are also used in conjunction with the
+	factory-method element to construct beans using static or instance
+	factory methods.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+
+   <xsd:complexType name="constructorArgType">
+      <xsd:sequence>
+
+         <xsd:element ref="description" minOccurs="0"/>
+         <xsd:choice minOccurs="0" maxOccurs="1">
+            <xsd:element ref="bean"/>
+            <xsd:element ref="ref"/>
+            <xsd:element ref="idref"/>
+            <xsd:element ref="value"/>
+            <xsd:element ref="null"/>
+            <xsd:element ref="list"/>
+            <xsd:element ref="set"/>
+
+            <xsd:element ref="map"/>
+            <xsd:element ref="props"/>
+            <xsd:any namespace="##other" processContents="strict"/>
+         </xsd:choice>
+      </xsd:sequence>
+      <xsd:attribute name="index" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The exact index of thr argument in the constructor argument list.
+Only needed to avoid ambiguities, e.g. in case of 2 arguments of
+the exact same type.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+
+      </xsd:attribute>
+      <xsd:attribute name="type" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The exact type of the constructor argument. Only needed to avoid
+ambiguities, e.g. in case of 2 single argument constructors
+that can both be converted from a String.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="ref" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+A short-cut alternative to a nested "<ref bean='...'/>" element.
+            ]]></xsd:documentation>
+
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="value" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+A short-cut alternative to a nested "<value>...<value/>"
+element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <xsd:element name="property" type="propertyType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Bean definitions can have zero or more properties.
+	Property elements correspond to JavaBean setter methods exposed
+	by the bean classes. Spring supports primitives, references to other
+	beans in the same or related factories, lists, maps and properties.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+
+   <xsd:element name="lookup-method">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	A lookup method causes the IoC container to override the given method
+	and return the bean with the name given in the bean attribute. This is
+	a form of Method Injection. It is particularly useful as an alternative
+	to implementing the BeanFactoryAware interface, in order to be able to
+	make getBean() calls for non-singleton instances at runtime. In this
+	case, Method Injection is a less invasive alternative.
+			]]></xsd:documentation>
+
+      </xsd:annotation>
+      <xsd:complexType>
+         <xsd:complexContent>
+            <xsd:restriction base="xsd:anyType">
+               <xsd:attribute name="name" type="xsd:string">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The name of the lookup method. This method must take no arguments.
+							]]></xsd:documentation>
+                  </xsd:annotation>
+               </xsd:attribute>
+
+               <xsd:attribute name="bean" type="xsd:string">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The name of the bean in the current or ancestor factories that
+	the lookup method should resolve to. Often this bean will be a
+	prototype, in which case the lookup method will return a distinct
+	instance on every invocation. This is useful for single-threaded objects.
+							]]></xsd:documentation>
+                  </xsd:annotation>
+               </xsd:attribute>
+            </xsd:restriction>
+         </xsd:complexContent>
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:element name="replaced-method">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Similar to the lookup method mechanism, the replaced-method element
+	is used to control IoC container method overriding: Method Injection.
+	This mechanism allows the overriding of a method with arbitrary code.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType>
+         <xsd:sequence>
+            <xsd:choice minOccurs="0" maxOccurs="unbounded">
+               <xsd:element ref="arg-type"/>
+
+            </xsd:choice>
+         </xsd:sequence>
+         <xsd:attribute name="name" type="xsd:string">
+            <xsd:annotation>
+               <xsd:documentation><![CDATA[
+	The name of the method whose implementation must be replaced by the
+	IoC container. If this method is not overloaded, there is no need
+	to use arg-type subelements. If this method is overloaded, arg-type
+	subelements must be used for all override definitions for the method.
+					]]></xsd:documentation>
+            </xsd:annotation>
+         </xsd:attribute>
+         <xsd:attribute name="replacer" type="xsd:string">
+            <xsd:annotation>
+
+               <xsd:documentation source="java:org.springframework.beans.factory.support.MethodReplacer"><![CDATA[
+	Bean name of an implementation of the MethodReplacer interface in the
+	current or ancestor factories. This may be a singleton or prototype
+	bean. If it is a prototype, a new instance will be used for each
+	method replacement. Singleton usage is the norm.
+					]]></xsd:documentation>
+            </xsd:annotation>
+         </xsd:attribute>
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:element name="arg-type">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Identifies an argument for a replaced method in the event of
+	method overloading.
+			]]></xsd:documentation>
+
+      </xsd:annotation>
+      <xsd:complexType mixed="true">
+         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:attribute name="match" type="xsd:string">
+            <xsd:annotation>
+               <xsd:documentation><![CDATA[
+	Specification of the type of an overloaded method argument as a String.
+	For convenience, this may be a substring of the FQN. E.g. all the
+	following would match "java.lang.String":
+	- java.lang.String
+	- String
+	- Str
+
+	As the number of arguments will be checked also, this convenience
+	can often be used to save typing.
+					]]></xsd:documentation>
+            </xsd:annotation>
+         </xsd:attribute>
+      </xsd:complexType>
+
+   </xsd:element>
+
+   <xsd:element name="ref" type="refType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Defines a reference to another bean in this factory or an external
+	factory (parent or included factory).
+			]]></xsd:documentation>
+      </xsd:annotation>
+
+   </xsd:element>
+
+   <xsd:complexType name="refType">
+      <xsd:complexContent>
+         <xsd:restriction base="xsd:anyType">
+
+            <xsd:attribute name="bean" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the referenced bean.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+            <xsd:attribute name="local" type="xsd:IDREF">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the referenced bean. The value must be a bean ID,
+and thus can be checked by the XML parser, thus should be preferred
+for references within the same bean factory XML file.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+
+            </xsd:attribute>
+            <xsd:attribute name="parent" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the referenced bean *in a parent factory*.
+               ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+         </xsd:restriction>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:element name="idref">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	The id of another bean in this factory or an external factory
+	(parent or included factory).
+	While a regular 'value' element could instead be used for the
+	same effect, using idref in this case allows validation of local
+	bean ids by the XML parser, and name completion by supporting tools.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType>
+         <xsd:complexContent>
+            <xsd:restriction base="xsd:anyType">
+
+               <xsd:attribute name="bean" type="xsd:string">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The name of the referenced bean.
+							]]></xsd:documentation>
+                  </xsd:annotation>
+               </xsd:attribute>
+               <xsd:attribute name="local" type="xsd:IDREF">
+                  <xsd:annotation>
+                     <xsd:documentation><![CDATA[
+	The name of the referenced bean. The value must be a bean ID,
+	and thus can be checked by the XML parser, thus should be preferred
+	for references within the same bean factory XML file.
+							]]></xsd:documentation>
+                  </xsd:annotation>
+
+               </xsd:attribute>
+            </xsd:restriction>
+         </xsd:complexContent>
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:element name="value" type="valueType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Contains a string representation of a property value.
+	The property may be a string, or may be converted to the required
+	type using the JavaBeans PropertyEditor machinery. This makes it
+	possible for application developers to write custom PropertyEditor
+	implementations that can convert strings to arbitrary target objects.
+
+	Note that this is recommended for simple objects only. Configure
+	more complex objects by populating JavaBean properties with
+	references to other beans.
+			]]></xsd:documentation>
+
+      </xsd:annotation>
+
+   </xsd:element>
+
+   <xsd:complexType name="valueType" mixed="true">
+      <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:attribute name="type" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The exact type that the value should be converted to. Only needed
+if the type of the target property or constructor argument is
+too generic: for example, in case of a collection element.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <xsd:element name="null">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Denotes a Java null value. Necessary because an empty "value" tag
+	will resolve to an empty String, which will not be resolved to a
+	null value unless a special PropertyEditor does so.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType mixed="true">
+         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+      </xsd:complexType>
+
+   </xsd:element>
+
+   <!-- Collection Elements -->
+   <xsd:group name="collectionElements">
+      <xsd:sequence>
+         <xsd:choice minOccurs="0" maxOccurs="unbounded">
+            <xsd:element ref="bean"/>
+            <xsd:element ref="ref"/>
+            <xsd:element ref="idref"/>
+
+            <xsd:element ref="value"/>
+            <xsd:element ref="null"/>
+            <xsd:element ref="list"/>
+            <xsd:element ref="set"/>
+            <xsd:element ref="map"/>
+            <xsd:element ref="props"/>
+            <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
+         </xsd:choice>
+      </xsd:sequence>
+
+   </xsd:group>
+
+   <xsd:element name="list" type="listOrSetType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	A list can contain multiple inner bean, ref, collection, or value
+	elements. Java lists are untyped, pending generics support in Java5,
+	although references will be strongly typed. A list can also map to
+	an array type. The necessary conversion is automatically performed
+	by the BeanFactory.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+   <xsd:element name="set" type="listOrSetType">
+      <xsd:annotation>
+
+         <xsd:documentation><![CDATA[
+	A set can contain multiple inner bean, ref, collection, or value
+	elements. Java sets are untyped, pending generics support in Java5,
+	although references will be strongly typed.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+   <xsd:element name="map" type="mapType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	A mapping from a key to an object. Maps may be empty.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+   <xsd:element name="entry" type="entryType">
+
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	A map entry can be an inner bean, ref, value, or collection.
+	The key of the entry is given by the "key" attribute or child element.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+   <xsd:element name="props" type="propsType">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	Props elements differ from map elements in that values must be strings.
+	Props may be empty.
+			]]></xsd:documentation>
+      </xsd:annotation>
+   </xsd:element>
+
+   <xsd:element name="key">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	A key element can contain an inner bean, ref, value, or collection.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType>
+         <xsd:group ref="collectionElements"/>
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:element name="prop">
+      <xsd:annotation>
+         <xsd:documentation><![CDATA[
+	The string value of the property. Note that whitespace is trimmed
+	off to avoid unwanted whitespace caused by typical XML formatting.
+			]]></xsd:documentation>
+      </xsd:annotation>
+      <xsd:complexType mixed="true">
+         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+         <xsd:attribute name="key" type="xsd:string" use="required">
+            <xsd:annotation>
+
+               <xsd:documentation><![CDATA[
+	The key of the property entry.
+					]]></xsd:documentation>
+            </xsd:annotation>
+         </xsd:attribute>
+      </xsd:complexType>
+   </xsd:element>
+
+   <xsd:complexType name="propertyType">
+      <xsd:sequence>
+         <xsd:element ref="description" minOccurs="0"/>
+
+         <xsd:choice minOccurs="0" maxOccurs="1">
+            <xsd:element ref="meta"/>
+            <xsd:element ref="bean"/>
+            <xsd:element ref="ref"/>
+            <xsd:element ref="idref"/>
+            <xsd:element ref="value"/>
+            <xsd:element ref="null"/>
+            <xsd:element ref="list"/>
+            <xsd:element ref="set"/>
+
+            <xsd:element ref="map"/>
+            <xsd:element ref="props"/>
+            <xsd:any namespace="##other" processContents="strict"/>
+         </xsd:choice>
+      </xsd:sequence>
+      <xsd:attribute name="name" type="xsd:string" use="required">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	The name of the property, following JavaBean naming conventions.
+				]]></xsd:documentation>
+         </xsd:annotation>
+
+      </xsd:attribute>
+      <xsd:attribute name="ref" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	A short-cut alternative to a nested "<ref bean='...'/>".
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="value" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	A short-cut alternative to a nested "<value>...</value>"
+	element.
+				]]></xsd:documentation>
+
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <!-- Collection Types -->
+
+   <!-- base collection type -->
+   <xsd:complexType name="baseCollectionType">
+      <xsd:attribute name="merge" type="defaultable-boolean">
+         <xsd:annotation>
+
+            <xsd:documentation><![CDATA[
+	Enables/disables merging for collections when using parent/child beans.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <!-- base type for collections that have (possibly) typed nested values -->
+   <xsd:complexType name="typedCollectionType">
+      <xsd:complexContent>
+         <xsd:extension base="baseCollectionType">
+
+            <xsd:attribute name="value-type" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation source="java:java.lang.Class"><![CDATA[
+	The default Java type for nested values. Must be a fully qualified
+	class name.
+						]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <!-- 'map' element type -->
+   <xsd:complexType name="mapType">
+      <xsd:complexContent>
+         <xsd:extension base="typedCollectionType">
+            <xsd:sequence>
+               <xsd:choice minOccurs="0" maxOccurs="unbounded">
+                  <xsd:element ref="entry"/>
+               </xsd:choice>
+            </xsd:sequence>
+
+            <xsd:attribute name="key-type" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation source="java:java.lang.Class"><![CDATA[
+	The default Java type for nested entry keys. Must be a fully qualified
+	class name.
+						]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <!-- 'entry' element type -->
+   <xsd:complexType name="entryType">
+      <xsd:sequence>
+         <xsd:element ref="key" minOccurs="0"/>
+         <xsd:group ref="collectionElements"/>
+      </xsd:sequence>
+      <xsd:attribute name="key" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	Each map element must specify its key as attribute or as child element.
+	A key attribute is always a String value.
+				]]></xsd:documentation>
+
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="key-ref" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	A short-cut alternative to a to a "key" element with a nested
+	"<ref bean='...'/>".
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="value" type="xsd:string">
+         <xsd:annotation>
+
+            <xsd:documentation><![CDATA[
+	A short-cut alternative to a nested "<value>...</value>"
+	element.
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="value-ref" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+	A short-cut alternative to a nested "<ref bean='...'/>".
+				]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <!-- 'list' and 'set' collection type -->
+   <xsd:complexType name="listOrSetType">
+      <xsd:complexContent>
+         <xsd:extension base="typedCollectionType">
+            <xsd:group ref="collectionElements"/>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <!-- 'props' collection type -->
+   <xsd:complexType name="propsType">
+      <xsd:complexContent>
+         <xsd:extension base="baseCollectionType">
+            <xsd:sequence>
+               <xsd:choice minOccurs="0" maxOccurs="unbounded">
+                  <xsd:element ref="prop"/>
+               </xsd:choice>
+
+            </xsd:sequence>
+         </xsd:extension>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <!-- simple internal types -->
+   <xsd:simpleType name="defaultable-boolean">
+      <xsd:restriction base="xsd:NMTOKEN">
+         <xsd:enumeration value="default"/>
+
+         <xsd:enumeration value="true"/>
+         <xsd:enumeration value="false"/>
+      </xsd:restriction>
+   </xsd:simpleType>
+
+</xsd:schema>



From rawblem at gmail.com  Mon Dec 11 11:55:28 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Mon, 11 Dec 2006 11:55:28 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF
	...
Message-ID: <E1GtoR6-00071a-Jo@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/11 11:55:28

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/META-INF  MANIFEST.MF
  Log:
  dependence on ui
  
  Revision  Changes    Path
  1.12      +2 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- MANIFEST.MF	4 Dec 2006 18:13:08 -0000	1.11
  +++ MANIFEST.MF	11 Dec 2006 16:55:28 -0000	1.12
  @@ -53,7 +53,8 @@
    org.eclipse.wst.ws,
    org.eclipse.wst.ws.ui,
    org.jboss.ide.eclipse.firstrun,
  - org.jboss.ide.eclipse.as.ui.mbeans
  + org.jboss.ide.eclipse.as.ui.mbeans,
  + org.jboss.ide.eclipse.ui
   Eclipse-LazyStart: true
   Export-Package: org.jboss.ide.eclipse.as.ui,
    org.jboss.ide.eclipse.as.ui.wizards
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 11:56:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 11:56:16 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1764 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/messaging/core/plugin
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/crash
	tests/src/org/jboss/test/messaging/tools
	tests/src/org/jboss/test/messaging/tools/jmx
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GtoRs-00072Z-Oj@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-11 11:56:06 -0500 (Mon, 11 Dec 2006)
New Revision: 1764

Added:
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java
Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
Log:
added a cluster event notification mechanism, various other tests and tweaks

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -22,6 +22,10 @@
 package org.jboss.messaging.core.plugin;
 
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
+import javax.management.NotificationFilter;
+import javax.management.ListenerNotFoundException;
+import javax.management.MBeanNotificationInfo;
 import javax.transaction.TransactionManager;
 import org.jboss.jms.selector.SelectorFactory;
 import org.jboss.jms.server.JMSConditionFactory;
@@ -103,6 +107,27 @@
       return postOffice.getNodeIDView();
    }
 
+   // NotificationBroadcaster implementation ------------------------
+
+   public void addNotificationListener(NotificationListener listener,
+                                       NotificationFilter filter,
+                                       Object object) throws IllegalArgumentException
+   {
+      postOffice.addNotificationListener(listener, filter, object);
+   }
+
+   public void removeNotificationListener(NotificationListener listener)
+      throws ListenerNotFoundException
+   {
+      postOffice.removeNotificationListener(listener);
+   }
+
+   public MBeanNotificationInfo[] getNotificationInfo()
+   {
+      return postOffice.getNotificationInfo();
+   }
+
+
    // MBean attributes ----------------------------------------------
 
    public synchronized ObjectName getServerPeer()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -40,6 +40,8 @@
  */
 public interface ClusteredPostOffice extends PostOffice, Peer
 {
+   public static final String VIEW_CHANGED_NOTIFICATION = "VIEW_CHANGED";
+
    /**
     * Bind a queue to the post office under a specific condition
     * such that it is available across the cluster

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -44,6 +44,12 @@
 import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
+import javax.management.NotificationBroadcasterSupport;
+import javax.management.NotificationListener;
+import javax.management.MBeanNotificationInfo;
+import javax.management.NotificationFilter;
+import javax.management.ListenerNotFoundException;
+import javax.management.Notification;
 
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
@@ -82,7 +88,7 @@
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
 /**
- * 
+ *
  * A DefaultClusteredPostOffice
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -96,6 +102,8 @@
 public class DefaultClusteredPostOffice extends DefaultPostOffice
    implements ClusteredPostOffice, PostOfficeInternal, Replicator
 {
+   // Constants -----------------------------------------------------
+
    private static final Logger log = Logger.getLogger(DefaultClusteredPostOffice.class);
 
    // Key for looking up node id -> address info mapping from replicated data
@@ -104,22 +112,32 @@
    // Key for looking up node id -> failed over for node id mapping from replicated data
    public static final String FAILED_OVER_FOR_KEY = "failed_over_for";
 
-   //Used for failure testing
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Used for failure testing
+
    private boolean failBeforeCommit;
-
    private boolean failAfterCommit;
-
    private boolean failHandleResult;
-   //End of failure testing attributes
 
+   // End of failure testing attributes
+
    private boolean trace = log.isTraceEnabled();
 
+   private String groupName;
+
+   private boolean started;
+
+   private Element syncChannelConfigElement;
+   private String syncChannelConfig;
    private Channel syncChannel;
 
+   private Element asyncChannelConfigElement;
+   private String asyncChannelConfig;
    private Channel asyncChannel;
 
-   private String groupName;
-
    private MessageDispatcher controlMessageDispatcher;
 
    private Object setStateLock = new Object();
@@ -139,14 +157,6 @@
 
    private Set leftSet;
 
-   private Element syncChannelConfigElement;
-
-   private Element asyncChannelConfigElement;
-
-   private String syncChannelConfig;
-
-   private String asyncChannelConfig;
-
    private long stateTimeout;
 
    private long castTimeout;
@@ -167,10 +177,13 @@
 
    private ReplicationListener nodeAddressMapListener;
 
-   private boolean started;
-   
-   private QueuedExecutor viewExecutor;         
+   private NotificationBroadcasterSupport nbSupport;
 
+   private QueuedExecutor viewExecutor;
+
+
+   // Constructors --------------------------------------------------
+
    /*
     * Constructor using Element for configuration
     */
@@ -197,8 +210,8 @@
       throws Exception
    {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
-           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
-           rf, failoverMapper, statsSendPeriod);
+           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout,
+           redistributionPolicy, rf, failoverMapper, statsSendPeriod);
 
       this.syncChannelConfigElement = syncChannelConfig;
       this.asyncChannelConfigElement = asyncChannelConfig;
@@ -229,8 +242,8 @@
                                      long statsSendPeriod) throws Exception
    {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
-           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
-           rf, failoverMapper, statsSendPeriod);
+           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout,
+           redistributionPolicy, rf, failoverMapper, statsSendPeriod);
 
       this.syncChannelConfig = syncChannelConfig;
       this.asyncChannelConfig = asyncChannelConfig;
@@ -285,12 +298,13 @@
       failoverMap = new LinkedHashMap();
 
       leftSet = new HashSet();
-      
+
+      nbSupport = new NotificationBroadcasterSupport();
+
       viewExecutor = new QueuedExecutor();
    }
 
-   // MessagingComponent overrides
-   // --------------------------------------------------------------
+   // MessagingComponent overrides ----------------------------------
 
    public synchronized void start() throws Exception
    {
@@ -379,6 +393,26 @@
       }
    }
 
+   // NotificationBroadcaster implementation ------------------------
+
+   public void addNotificationListener(NotificationListener listener,
+                                       NotificationFilter filter,
+                                       Object object) throws IllegalArgumentException
+   {
+      nbSupport.addNotificationListener(listener, filter, object);
+   }
+
+   public void removeNotificationListener(NotificationListener listener)
+      throws ListenerNotFoundException
+   {
+      nbSupport.removeNotificationListener(listener);
+   }
+
+   public MBeanNotificationInfo[] getNotificationInfo()
+   {
+      return new MBeanNotificationInfo[0];
+   }
+
    // Peer implementation -------------------------------------------
 
    public Set getNodeIDView()
@@ -424,10 +458,7 @@
 
    public Binding bindClusteredQueue(Condition condition, LocalClusteredQueue queue) throws Exception
    {
-      if (trace)
-      {
-         log.trace(this.currentNodeId + " binding clustered queue: " + queue + " with condition: " + condition);
-      }
+      if (trace) { log.trace(this.currentNodeId + " binding clustered queue: " + queue + " with condition: " + condition); }
 
       if (queue.getNodeId() != this.currentNodeId)
       {
@@ -443,22 +474,9 @@
       return binding;
    }
 
-   private void sendBindRequest(Condition condition, LocalClusteredQueue queue, Binding binding)
-      throws Exception
-   {
-      BindRequest request =
-         new BindRequest(this.currentNodeId, queue.getName(), condition.toText(), queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
-                         binding.getQueue().getChannelID(), queue.isRecoverable(), binding.isFailed());
-
-      syncSendRequest(request);
-   }
-
    public Binding unbindClusteredQueue(String queueName) throws Throwable
    {
-      if (trace)
-      {
-         log.trace(this.currentNodeId + " unbind clustered queue: " + queueName);
-      }
+      if (trace) { log.trace(this.currentNodeId + " unbind clustered queue: " + queueName); }
 
       Binding binding = (Binding)super.unbindQueue(queueName);
 
@@ -469,274 +487,140 @@
       return binding;
    }
 
-   public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
+   public Collection listAllBindingsForCondition(Condition condition) throws Exception
    {
-      if (trace)
-      {
-         log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx);
-      }
+      return listBindingsForConditionInternal(condition, false);
+   }
 
-      //debug
-      try
-      {
-         TextMessage tm = (TextMessage)ref.getMessage();
-
-         log.info(this.currentNodeId + " *********** Routing ref: " + tm.getText() + " with condition " + condition + " and transaction " + tx);
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-      }
-
-      if (ref == null)
-      {
-         throw new IllegalArgumentException("Message reference is null");
-      }
-
-      if (condition == null)
-      {
-         throw new IllegalArgumentException("Condition is null");
-      }
-
-      boolean routed = false;
-
+   public Binding getBindingforChannelId(long channelId) throws Exception
+   {
       lock.readLock().acquire();
 
       try
       {
-         ClusteredBindings cb = (ClusteredBindings)conditionMap.get(condition);
+         //First look in the failed map
+         //Failed bindings are stored in the failed map by channel id
+         Map channelMap = (Map)failedBindings.get(new Integer(currentNodeId));
+         Binding binding = null;
+         if (channelMap != null)
+         {
+            binding = (Binding)channelMap.get(new Long(channelId));
+         }
 
-         boolean startInternalTx = false;
-
-         int lastNodeId = -1;
-
-         if (cb != null)
+         if (binding == null)
          {
-            if (tx == null && ref.isReliable())
-            {
-               if (!(cb.getDurableCount() == 0 || (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
-               {
-                  // When routing a persistent message without a transaction then we may need to start an
-                  // internal transaction in order to route it.
-                  // This is so we can guarantee the message is delivered to all or none of the subscriptions.
-                  // We need to do this if there is anything other than
-                  // No durable subs or exactly one local durable sub
-                  startInternalTx = true;
-                  if (trace)
-                  {
-                     log.trace(this.currentNodeId + " Starting internal transaction since more than one durable sub or remote durable subs");
-                  }
-               }
-            }
+            //Not found in the failed map - look in the name map
+            Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
 
-            if (startInternalTx)
+            if (nameMap != null)
             {
-               tx = tr.createTransaction();
-            }
-
-            int numberRemote = 0;
-
-            Map queueNameNodeIdMap = null;
-
-            long lastChannelId = -1;
-
-            Collection routers = cb.getRouters();
-
-            Iterator iter = routers.iterator();
-
-            while (iter.hasNext())
-            {
-               ClusterRouter router = (ClusterRouter)iter.next();
-
-               Delivery del = router.handle(null, ref, tx);
-
-               if (del != null && del.isSelectorAccepted())
+               for (Iterator iterbindings = nameMap.values().iterator(); iterbindings.hasNext();)
                {
-                  routed = true;
-
-                  ClusteredQueue queue = (ClusteredQueue)del.getObserver();
-
-                  if (trace)
+                  Binding itemBinding = (Binding)iterbindings.next();
+                  if (itemBinding.getQueue().getChannelID() == channelId)
                   {
-                     log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
-                               queue.getNodeId() + " local:" + queue.isLocal());
-
+                     binding = itemBinding;
+                     break;
                   }
-
-                  log.info(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
-                           queue.getNodeId() + " local:" + queue.isLocal());
-
-                  if (router.numberOfReceivers() > 1)
-                  {
-                     //We have now chosen which one will receive the message so we need to add this
-                     //information to a map which will get sent when casting - so the the queue
-                     //on the receiving node knows whether to receive the message
-                     if (queueNameNodeIdMap == null)
-                     {
-                        queueNameNodeIdMap = new HashMap();
-                     }
-
-                     queueNameNodeIdMap.put(queue.getName(), new Integer(queue.getNodeId()));
-                  }
-
-                  if (!queue.isLocal())
-                  {
-                     //We need to send the message remotely
-                     numberRemote++;
-
-                     lastNodeId = queue.getNodeId();
-
-                     lastChannelId = queue.getChannelID();
-                  }
                }
             }
-
-            //Now we've sent the message to any local queues, we might also need
-            //to send the message to the other office instances on the cluster if there are
-            //queues on those nodes that need to receive the message
-
-            //TODO - there is an innefficiency here, numberRemote does not take into account that more than one
-            //of the number remote may be on the same node, so we could end up multicasting
-            //when unicast would do
-            if (numberRemote > 0)
+            else
             {
-               if (tx == null)
-               {
-                  if (numberRemote == 1)
-                  {
-                     if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
-
-                     //Unicast - only one node is interested in the message
-                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), null), lastNodeId);
-                  }
-                  else
-                  {
-                     if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
-
-                     //Multicast - more than one node is interested
-                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), queueNameNodeIdMap));
-                  }
-               }
-               else
-               {
-                  CastMessagesCallback callback = (CastMessagesCallback)tx.getCallback(this);
-
-                  if (callback == null)
-                  {
-                     callback = new CastMessagesCallback(currentNodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
-
-                     //This callback MUST be executed first
-
-                     //Execution order is as follows:
-                     //Before commit:
-                     //1. Cast messages across network - get added to holding area (if persistent) on receiving
-                     //nodes
-                     //2. Persist messages in persistent store
-                     //After commit
-                     //1. Cast commit message across network
-                     tx.addFirstCallback(callback, this);
-                  }
-
-                  callback.addMessage(condition, ref.getMessage(), queueNameNodeIdMap,
-                                      numberRemote == 1 ? lastNodeId : -1,
-                                      lastChannelId);
-               }
+               log.info("nameMap is null");
             }
-
-            if (startInternalTx)
-            {
-               tx.commit();
-               if (trace) { log.trace("Committed internal transaction"); }
-            }
          }
+         log.info("Returned " + binding);
+         return binding;
       }
       finally
       {
          lock.readLock().release();
       }
-
-      return routed;
    }
 
-   public boolean isLocal()
-   {
-      return false;
-   }
+   // PostOfficeInternal implementation -----------------------------
 
-   public Collection listAllBindingsForCondition(Condition condition) throws Exception
+   /*
+    * Called when another node adds a binding
+    */
+   public void addBindingFromCluster(int nodeId, String queueName, String conditionText,
+                                     String filterString, long channelID, boolean durable,
+                                     boolean failed)
+      throws Exception
    {
-      return listBindingsForConditionInternal(condition, false);
-   }
+      lock.writeLock().acquire();
 
-   public FailoverMapper getFailoverMapper()
-   {
-      return failoverMapper;
-   }
+      if (trace)
+      {
+         log.info(this.currentNodeId + " adding binding from node: " + nodeId +
+                  " queue: " + queueName + " with condition: " + conditionText);
+      }
 
-   // Replicator implementation --------------------------------------------------------------------------
+      Condition condition = conditionFactory.createCondition(conditionText);
 
-   public Map get(Serializable key) throws Exception
-   {
-      synchronized (replicatedData)
+      try
       {
-         Map m = (Map)replicatedData.get(key);
+         //Sanity
 
-         return m == null ? Collections.EMPTY_MAP : Collections.unmodifiableMap(m);
-      }
-   }
+         if (!knowAboutNodeId(nodeId))
+         {
+            throw new IllegalStateException("Don't know about node id: " + nodeId);
+         }
 
-   public void put(Serializable key, Serializable replicant) throws Exception
-   {
-      putReplicantLocally(currentNodeId, key, replicant);
+         // We currently only allow one binding per name per node
+         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
 
-      PutReplicantRequest request = new PutReplicantRequest(currentNodeId, key, replicant);
+         Binding binding = null;
 
-      syncSendRequest(request);
-   }
+         if (nameMap != null)
+         {
+            binding = (Binding)nameMap.get(queueName);
+         }
 
-   public boolean remove(Serializable key) throws Exception
-   {
-      if (removeReplicantLocally(this.currentNodeId, key))
-      {
-         RemoveReplicantRequest request = new RemoveReplicantRequest(this.currentNodeId, key);
+         if (binding != null && failed)
+         {
+            throw new IllegalArgumentException(this.currentNodeId +
+                     " Binding already exists for node Id " + nodeId + " queue name " + queueName);
+         }
 
-         syncSendRequest(request);
+         binding = this.createBinding(nodeId, condition, queueName, channelID, filterString,
+                                      durable, failed);
 
-         return true;
+         addBinding(binding);
       }
-      else
+      finally
       {
-         return false;
+         lock.writeLock().release();
       }
+
+      log.info("****** binding added");
    }
 
-   public void registerListener(ReplicationListener listener)
+   /*
+    * Called when another node removes a binding
+    */
+   public void removeBindingFromCluster(int nodeId, String queueName) throws Exception
    {
-      synchronized (replicationListeners)
+      lock.writeLock().acquire();
+
+      if (trace) { log.trace(this.currentNodeId + " removing binding from node: " + nodeId + " queue: " + queueName); }
+
+      try
       {
-         if (replicationListeners.contains(listener))
+         // Sanity
+         if (!knowAboutNodeId(nodeId))
          {
-            throw new IllegalArgumentException("Listener " + listener + " is already registered");
+            throw new IllegalStateException("Don't know about node id: " + nodeId);
          }
-         replicationListeners.add(listener);
+
+         removeBinding(nodeId, queueName);
       }
-   }
-
-   public void unregisterListener(ReplicationListener listener)
-   {
-      synchronized (replicationListeners)
+      finally
       {
-         boolean removed = replicationListeners.remove(listener);
-
-         if (!removed)
-         {
-            throw new IllegalArgumentException("Cannot find listener " + listener + " to remove");
-         }
+         lock.writeLock().release();
       }
    }
 
-   // PostOfficeInternal implementation ------------------------------------------------------------------
-
    public void handleNodeLeft(int nodeId) throws Exception
    {
       synchronized (leftSet)
@@ -752,7 +636,7 @@
       throws Exception
    {
       log.info("##########putReplicantLocally received, before lock");
-      
+
       synchronized (replicatedData)
       {
          log.info("putReplicantLocally received, after lock");
@@ -769,7 +653,7 @@
 
          notifyListeners(key, m, true, originatorNodeID);
       }
-      
+
       log.info("putReplicantLocally, completed");
    }
 
@@ -806,88 +690,6 @@
       }
    }
 
-   /*
-    * Called when another node adds a binding
-    */
-   public void addBindingFromCluster(int nodeId, String queueName, String conditionText,
-                                     String filterString, long channelID, boolean durable, boolean failed)
-      throws Exception
-   {
-      lock.writeLock().acquire();
-
-      if (trace)
-      {
-         log.info(this.currentNodeId + " adding binding from node: " + nodeId +
-                  " queue: " + queueName + " with condition: " + conditionText);
-      }
-
-      Condition condition = conditionFactory.createCondition(conditionText);
-            
-      try
-      {
-         //Sanity
-
-         if (!knowAboutNodeId(nodeId))
-         {
-            throw new IllegalStateException("Don't know about node id: " + nodeId);
-         }
-
-         // We currently only allow one binding per name per node
-         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-
-         Binding binding = null;
-
-         if (nameMap != null)
-         {
-            binding = (Binding)nameMap.get(queueName);
-         }
-
-         if (binding != null && failed)
-         {
-            throw new IllegalArgumentException(this.currentNodeId +
-                     " Binding already exists for node Id " + nodeId + " queue name " + queueName);
-         }
-
-         binding = this.createBinding(nodeId, condition, queueName, channelID, filterString, durable, failed);
-
-         addBinding(binding);
-      }
-      finally
-      {
-         lock.writeLock().release();
-      }
-      
-      log.info("****** binding added");
-   }
-
-   /*
-    * Called when another node removes a binding
-    */
-   public void removeBindingFromCluster(int nodeId, String queueName) throws Exception
-   {
-      lock.writeLock().acquire();
-
-      if (trace)
-      {
-         log.trace(this.currentNodeId + " removing binding from node: " + nodeId + " queue: " + queueName);
-      }
-
-      try
-      {
-         // Sanity
-         if (!knowAboutNodeId(nodeId))
-         {
-            throw new IllegalStateException("Don't know about node id: " + nodeId);
-         }
-
-         removeBinding(nodeId, queueName);
-      }
-      finally
-      {
-         lock.writeLock().release();
-      }
-   }
-
    public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKeyText,
                                 Map queueNameNodeIdMap) throws Exception
    {
@@ -901,9 +703,9 @@
                routingKeyText + " map " + queueNameNodeIdMap);
 
       Condition routingKey = conditionFactory.createCondition(routingKeyText);
-            
-      lock.readLock().acquire();  
 
+      lock.readLock().acquire();
+
       // Need to reference the message
       MessageReference ref = null;
       try
@@ -1063,62 +865,83 @@
       if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
 
-   /**
-    * Check for any transactions that need to be committed or rolled back
-    */
-   public void check(Integer nodeId) throws Throwable
+   public void updateQueueStats(int nodeId, List statsList) throws Exception
    {
-      if (trace) { log.trace(this.currentNodeId + " checking for any stranded transactions for node " + nodeId); }
+      lock.readLock().acquire();
 
-      synchronized (holdingArea)
+      if (trace) { log.trace(this.currentNodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
+
+      try
       {
-         Iterator iter = holdingArea.entrySet().iterator();
+         if (nodeId == this.currentNodeId)
+         {
+            //Sanity check
+            throw new IllegalStateException("Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!");
+         }
 
-         List toRemove = new ArrayList();
+         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
 
-         while (iter.hasNext())
+         if (nameMap == null)
          {
-            Map.Entry entry = (Map.Entry)iter.next();
+            //This is ok, the node might have left
+            if (trace) { log.trace(this.currentNodeId + " cannot find node in name map, i guess the node might have left?"); }
+         }
+         else
+         {
+            Iterator iter = statsList.iterator();
 
-            TransactionId id = (TransactionId)entry.getKey();
-
-            if (id.getNodeId() == nodeId.intValue())
+            while (iter.hasNext())
             {
-               ClusterTransaction tx = (ClusterTransaction)entry.getValue();
+               QueueStats st = (QueueStats)iter.next();
 
-               if (trace) { log.trace("Found transaction " + tx + " in holding area"); }
+               Binding bb = (Binding)nameMap.get(st.getQueueName());
 
-               boolean commit = tx.check(this);
-
-               if (trace) { log.trace(this.currentNodeId + " transaction " + tx + " will be committed?: " + commit); }
-
-               if (commit)
+               if (bb == null)
                {
-                  tx.commit(this);
+                  //I guess this is possible if the queue was unbound
+                  if (trace) { log.trace(this.currentNodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
                }
                else
                {
-                  tx.rollback(this);
-               }
+                  RemoteQueueStub stub = (RemoteQueueStub)bb.getQueue();
 
-               toRemove.add(id);
+                  stub.setStats(st);
 
-               if (trace) { log.trace(this.currentNodeId + " resolved " + tx); }
-            }
-         }
+                  if (trace) { log.trace(this.currentNodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
 
-         //Remove the transactions from the holding area
+                  ClusterRouter router = (ClusterRouter)routerMap.get(st.getQueueName());
 
-         iter = toRemove.iterator();
+                  //Maybe the local queue now wants to pull message(s) from the remote queue given that the
+                  //stats for the remote queue have changed
+                  LocalClusteredQueue localQueue = (LocalClusteredQueue)router.getLocalQueue();
 
-         while (iter.hasNext())
-         {
-            TransactionId id = (TransactionId)iter.next();
+                  if (localQueue!=null)
+                  {
+                     //TODO - the call to getQueues is too slow since it creates a new list and adds the local queue!!!
+                     RemoteQueueStub toQueue = (RemoteQueueStub)messagePullPolicy.chooseQueue(router.getQueues());
 
-            holdingArea.remove(id);
+                     if (trace) { log.trace(this.currentNodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
+
+                     localQueue.setPullQueue(toQueue);
+
+                     if (toQueue != null && localQueue.getRefCount() == 0)
+                     {
+                        //We now trigger delivery - this may cause a pull event
+                        //We only do this if there are no refs in the local queue
+
+                        localQueue.deliver(false);
+
+                        if (trace) { log.trace(this.currentNodeId + " triggered delivery for " + localQueue.getName()); }
+                     }
+                  }
+               }
+            }
          }
       }
-      if (trace) { log.trace(this.currentNodeId + " check complete"); }
+      finally
+      {
+         lock.readLock().release();
+      }
    }
 
    public void sendQueueStats() throws Exception
@@ -1180,91 +1003,11 @@
       }
    }
 
-   public void updateQueueStats(int nodeId, List statsList) throws Exception
-   {
-      lock.readLock().acquire();
-
-      if (trace) { log.trace(this.currentNodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
-
-      try
-      {
-         if (nodeId == this.currentNodeId)
-         {
-            //Sanity check
-            throw new IllegalStateException("Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!");
-         }
-
-         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-
-         if (nameMap == null)
-         {
-            //This is ok, the node might have left
-            if (trace) { log.trace(this.currentNodeId + " cannot find node in name map, i guess the node might have left?"); }
-         }
-         else
-         {
-            Iterator iter = statsList.iterator();
-
-            while (iter.hasNext())
-            {
-               QueueStats st = (QueueStats)iter.next();
-
-               Binding bb = (Binding)nameMap.get(st.getQueueName());
-
-               if (bb == null)
-               {
-                  //I guess this is possible if the queue was unbound
-                  if (trace) { log.trace(this.currentNodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
-               }
-               else
-               {
-                  RemoteQueueStub stub = (RemoteQueueStub)bb.getQueue();
-
-                  stub.setStats(st);
-
-                  if (trace) { log.trace(this.currentNodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
-
-                  ClusterRouter router = (ClusterRouter)routerMap.get(st.getQueueName());
-
-                  //Maybe the local queue now wants to pull message(s) from the remote queue given that the
-                  //stats for the remote queue have changed
-                  LocalClusteredQueue localQueue = (LocalClusteredQueue)router.getLocalQueue();
-
-                  if (localQueue!=null)
-                  {
-                     //TODO - the call to getQueues is too slow since it creates a new list and adds the local queue!!!
-                     RemoteQueueStub toQueue = (RemoteQueueStub)messagePullPolicy.chooseQueue(router.getQueues());
-
-                     if (trace) { log.trace(this.currentNodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
-
-                     localQueue.setPullQueue(toQueue);
-
-                     if (toQueue != null && localQueue.getRefCount() == 0)
-                     {
-                        //We now trigger delivery - this may cause a pull event
-                        //We only do this if there are no refs in the local queue
-
-                        localQueue.deliver(false);
-
-                        if (trace) { log.trace(this.currentNodeId + " triggered delivery for " + localQueue.getName()); }
-                     }
-                  }
-               }
-            }
-         }
-      }
-      finally
-      {
-         lock.readLock().release();
-      }
-   }
-
    public boolean referenceExistsInStorage(long channelID, long messageID) throws Exception
    {
       return pm.referenceExists(channelID, messageID);
    }
 
-
    public void handleMessagePullResult(int remoteNodeId, long holdingTxId,
                                        String queueName, org.jboss.messaging.core.Message message) throws Throwable
    {
@@ -1322,320 +1065,348 @@
       }
    }
 
-   public int getNodeId()
+   // Replicator implementation -------------------------------------
+
+   public void put(Serializable key, Serializable replicant) throws Exception
    {
-      return currentNodeId;
+      putReplicantLocally(currentNodeId, key, replicant);
+
+      PutReplicantRequest request = new PutReplicantRequest(currentNodeId, key, replicant);
+
+      syncSendRequest(request);
    }
 
-   public String toString()
+   public Map get(Serializable key) throws Exception
    {
-      StringBuffer sb = new StringBuffer("ClusteredPostOffice[");
-      sb.append(currentNodeId).append(":").append(getOfficeName()).append(":");
+      synchronized (replicatedData)
+      {
+         Map m = (Map)replicatedData.get(key);
 
-      if (syncChannel == null)
-      {
-         sb.append("UNINITIALIZED");
+         return m == null ? Collections.EMPTY_MAP : Collections.unmodifiableMap(m);
       }
-      else
-      {
-         Address addr = syncChannel.getLocalAddress();
-         if (addr == null)
-         {
-            sb.append("UNCONNECTED");
-         }
-         else
-         {
-            sb.append(addr);
-         }
-      }
-
-      sb.append("]");
-      return sb.toString();
    }
 
-   // Public ------------------------------------------------------------------------------------------
-
-   //MUST ONLY be used for testing
-   public int getNumberOfNodesInCluster()
+   public boolean remove(Serializable key) throws Exception
    {
-      if (currentView != null)
+      if (removeReplicantLocally(this.currentNodeId, key))
       {
-         return currentView.size();
+         RemoveReplicantRequest request = new RemoveReplicantRequest(this.currentNodeId, key);
+
+         syncSendRequest(request);
+
+         return true;
       }
       else
       {
-         return 0;
+         return false;
       }
    }
 
-   //MUST ONLY be used for testing
-   public void setFail(boolean beforeCommit, boolean afterCommit, boolean handleResult)
+   public void registerListener(ReplicationListener listener)
    {
-      this.failBeforeCommit = beforeCommit;
-      this.failAfterCommit = afterCommit;
-      this.failHandleResult = handleResult;
-   }
-
-   //MUST ONLY be used for testing
-   public Collection getHoldingTransactions()
-   {
-      return holdingArea.values();
-   }
-
-
-   /**
-    *  Verifies changes on the View deciding if a node joined or left the cluster
-    *
-    * */
-   private void verifyMembership(View oldView, View newView) throws Throwable
-   {
-      if (oldView != null)
+      synchronized (replicationListeners)
       {
-         for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+         if (replicationListeners.contains(listener))
          {
-            Address address = (Address)i.next();
-            if (!newView.containsMember(address))
-            {
-               nodeLeft(address);
-            }
+            throw new IllegalArgumentException("Listener " + listener + " is already registered");
          }
+         replicationListeners.add(listener);
       }
+   }
 
-      for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+   public void unregisterListener(ReplicationListener listener)
+   {
+      synchronized (replicationListeners)
       {
-         Address address = (Address)i.next();
-         if (oldView == null || !oldView.containsMember(address))
+         boolean removed = replicationListeners.remove(listener);
+
+         if (!removed)
          {
-            nodeJoined(address);
+            throw new IllegalArgumentException("Cannot find listener " + listener + " to remove");
          }
       }
    }
 
-   /**
-    * This method fails over all the queues from node <failedNodeId> onto this node
-    * It is triggered when a JGroups view change occurs due to a member leaving and
-    * it's determined the member didn't leave cleanly
-    *
-    * @param failedNodeId
-    * @throws Exception
-    */
-   private void failOver(int failedNodeId) throws Exception
+   public FailoverMapper getFailoverMapper()
    {
-      //Need to lock
-      lock.writeLock().acquire();
+      return failoverMapper;
+   }
 
+   // Public --------------------------------------------------------
+
+   public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
+   {
+      if (trace) { log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx); }
+
+      //debug
       try
       {
-         log.info(this.currentNodeId + " is performing failover for node " + failedNodeId);
+         TextMessage tm = (TextMessage)ref.getMessage();
 
-         /*
-         We make sure a FailoverStatus object is put in the replicated data for the node
-         The real failover node will always add this in.
-         This means that each node knows which node has really started the failover for another node, and
-         which node did failover for other nodes in the past
-         We cannot rely on the failoverMap for this, since that will regenerated once failover is done,
-         because of the change in membership.
-         And clients may failover after that and need to know if they have the correct node.
-         Since this is the first thing we do after detecting failover, it should be very quick that
-         all nodes know, however there is still a chance that a client tries to failover before
-         the information is replicated.
-         */
+         log.info(this.currentNodeId + " *********** Routing ref: " + tm.getText() + " with condition " + condition + " and transaction " + tx);
+      }
+      catch (Exception e)
+      {
+         e.printStackTrace();
+      }
 
-         Map replicants = (Map)get(FAILED_OVER_FOR_KEY);
+      if (ref == null)
+      {
+         throw new IllegalArgumentException("Message reference is null");
+      }
 
-         FailoverStatus status = (FailoverStatus)replicants.get(new Integer(currentNodeId));
+      if (condition == null)
+      {
+         throw new IllegalArgumentException("Condition is null");
+      }
 
-         if (status == null)
-         {
-            status = new FailoverStatus();
-         }
+      boolean routed = false;
 
-         status.startFailingOverForNode(failedNodeId);
+      lock.readLock().acquire();
 
-         log.info("Putting state that failover is starting");
-         
-         put(FAILED_OVER_FOR_KEY, status);
+      try
+      {
+         ClusteredBindings cb = (ClusteredBindings)conditionMap.get(condition);
 
-         log.info("Put state that failover is starting");
+         boolean startInternalTx = false;
 
-         //Get the map of queues for the failed node
+         int lastNodeId = -1;
 
-         Map subMaps = (Map)nameMaps.get(new Integer(failedNodeId));
-         if (subMaps==null || subMaps.size()==0)
+         if (cb != null)
          {
-            log.warn("Couldn't find any binding to failOver from serverId=" +failedNodeId);
-            return;
-         }
+            if (tx == null && ref.isReliable())
+            {
+               if (!(cb.getDurableCount() == 0 || (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
+               {
+                  // When routing a persistent message without a transaction then we may need to
+                  // start an internal transaction in order to route it. This is so we can guarantee
+                  // the message is delivered to all or none of the subscriptions. We need to do
+                  // this if there is anything other than. No durable subs or exactly one local
+                  // durable sub.
 
-         //Compile a list of the queue names to remove
-         //Note that any non durable bindings will already have been removed (in removeDataForNode()) when the
-         //node leave was detected, so if there are any non durable bindings left here then
-         //this is an error
+                  startInternalTx = true;
 
-         //We iterate through twice to avoid ConcurrentModificationException
-         ArrayList namesToRemove = new ArrayList();
-         for (Iterator iterNames = subMaps.entrySet().iterator(); iterNames.hasNext();)
-         {
-            Map.Entry entry = (Map.Entry)iterNames.next();
-
-            Binding binding = (Binding )entry.getValue();
-
-            //Sanity check
-            if (!binding.getQueue().isRecoverable())
-            {
-               throw new IllegalStateException("Find non recoverable queue in map, these should have been removed!");
+                  if (trace) { log.trace(this.currentNodeId + " Starting internal transaction since more than one durable sub or remote durable subs"); }
+               }
             }
 
-            //Sanity check
-            if (!binding.getQueue().isClustered())
+            if (startInternalTx)
             {
-               throw new IllegalStateException("Queue is not clustered!: " + binding.getQueue().getName());
+               tx = tr.createTransaction();
             }
 
-            ClusteredQueue queue = (ClusteredQueue) binding.getQueue();
+            int numberRemote = 0;
 
-            //Sanity check
-            if (queue.isLocal())
+            Map queueNameNodeIdMap = null;
+
+            long lastChannelId = -1;
+
+            Collection routers = cb.getRouters();
+
+            Iterator iter = routers.iterator();
+
+            while (iter.hasNext())
             {
-               throw new IllegalStateException("Queue is local!: " + binding.getQueue().getName());
-            }
-            namesToRemove.add(entry);
-         }
+               ClusterRouter router = (ClusterRouter)iter.next();
 
-         log.info("Deleting " + namesToRemove.size() + " bindings from old node");
+               Delivery del = router.handle(null, ref, tx);
 
-         for (Iterator iterNames = namesToRemove.iterator(); iterNames.hasNext();)
-         {
-            Map.Entry entry = (Map.Entry)iterNames.next();
+               if (del != null && del.isSelectorAccepted())
+               {
+                  routed = true;
 
-            Binding binding = (Binding)entry.getValue();
+                  ClusteredQueue queue = (ClusteredQueue)del.getObserver();
 
-            RemoteQueueStub stub = (RemoteQueueStub)binding.getQueue();
+                  if (trace) { log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " + queue.getNodeId() + " local:" + queue.isLocal()); }
 
-            String queueName = (String)entry.getKey();
+                  log.info(this.currentNodeId + " Routing message to queue or stub:" +
+                           queue.getName() + " on node " + queue.getNodeId() + " local:" +
+                           queue.isLocal());
 
-            //First the binding is removed from the in memory condition and name maps
-            this.removeBinding(failedNodeId, queueName);
+                  if (router.numberOfReceivers() > 1)
+                  {
+                     //We have now chosen which one will receive the message so we need to add this
+                     //information to a map which will get sent when casting - so the the queue
+                     //on the receiving node knows whether to receive the message
+                     if (queueNameNodeIdMap == null)
+                     {
+                        queueNameNodeIdMap = new HashMap();
+                     }
 
-            //Then deleted from the database
-            this.deleteBinding(failedNodeId, queueName);
+                     queueNameNodeIdMap.put(queue.getName(), new Integer(queue.getNodeId()));
+                  }
 
-            log.info("deleted binding for " + queueName);
-            
-            //Note we do not need to send an unbind request across the cluster - this is because
-            //when the node crashes a view change will hit the other nodes and that will cause
-            //all binding data for that node to be removed anyway
+                  if (!queue.isLocal())
+                  {
+                     //We need to send the message remotely
+                     numberRemote++;
 
-            //If there is already a queue registered with the same name, then we set a flag "failed" on the
-            //binding and then the queue will go into a special list of failed bindings
-            //otherwise we treat at as a normal queue
-            //This is because we cannot deal with more than one queue with the same name
-            //Any new consumers will always only connect to queues in the main name map
-            //This may mean that queues in the failed map have messages stranded in them if consumers
-            //disconnect (since no more can reconnect)
-            //However we message redistribution activated other queues will be able to consume from them.
-            //TODO allow message redistribution for queues in the failed list
-            boolean failed = this.internalGetBindingForQueueName(queueName) != null;
+                     lastNodeId = queue.getNodeId();
 
-            if (!failed)
-            {
-               log.info("The current node didn't have a queue " + queueName + " so it's assuming the queue as a regular queue");
+                     lastChannelId = queue.getChannelID();
+                  }
+               }
             }
-            else
-            {
-               log.info("There is already a queue with that name so adding to failed map");
-            }
 
-            //Create a new binding
-            Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
-                                                    stub.getName(), stub.getChannelID(),
-                                                    stub.getFilter(), stub.isRecoverable(), failed);
+            //Now we've sent the message to any local queues, we might also need
+            //to send the message to the other office instances on the cluster if there are
+            //queues on those nodes that need to receive the message
 
-            log.info("Created new binding");
+            //TODO - there is an innefficiency here, numberRemote does not take into account that more than one
+            //of the number remote may be on the same node, so we could end up multicasting
+            //when unicast would do
+            if (numberRemote > 0)
+            {
+               if (tx == null)
+               {
+                  if (numberRemote == 1)
+                  {
+                     if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
 
-            //Insert it into the database
-            insertBinding(newBinding);
+                     //Unicast - only one node is interested in the message
+                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), null), lastNodeId);
+                  }
+                  else
+                  {
+                     if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
 
-            LocalClusteredQueue clusteredQueue = (LocalClusteredQueue )newBinding.getQueue();
+                     //Multicast - more than one node is interested
+                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), queueNameNodeIdMap));
+                  }
+               }
+               else
+               {
+                  CastMessagesCallback callback = (CastMessagesCallback)tx.getCallback(this);
 
-            clusteredQueue.deactivate();
-            clusteredQueue.load();
-            clusteredQueue.activate();
+                  if (callback == null)
+                  {
+                     callback = new CastMessagesCallback(currentNodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
 
-            log.info("Loaded queue");
+                     //This callback MUST be executed first
 
-            //Add the new binding in memory
-            addBinding(newBinding);
+                     //Execution order is as follows:
+                     //Before commit:
+                     //1. Cast messages across network - get added to holding area (if persistent) on receiving
+                     //nodes
+                     //2. Persist messages in persistent store
+                     //After commit
+                     //1. Cast commit message across network
+                     tx.addFirstCallback(callback, this);
+                  }
 
-            //Send a bind request so other nodes add it too
-            sendBindRequest(binding.getCondition(), clusteredQueue,newBinding);
+                  callback.addMessage(condition, ref.getMessage(), queueNameNodeIdMap,
+                                      numberRemote == 1 ? lastNodeId : -1,
+                                      lastChannelId);
+               }
+            }
 
-            //FIXME there is a problem in the above code.
-            //If the server crashes between deleting the binding from the database
-            //and creating the new binding in the database, then the binding will be completely
-            //lost from the database when the server is resurrected.
-            //To remedy, both db operations need to be done in the same JBDC tx
+            if (startInternalTx)
+            {
+               tx.commit();
+               if (trace) { log.trace("Committed internal transaction"); }
+            }
          }
-
-         log.info("Server side fail over is now complete");
-
-         //TODO - should this be in a finally? I'm not sure
-         status.finishFailingOver();
-
-         log.info("Putting state that failover has completed");
-         put(FAILED_OVER_FOR_KEY, status);
-         log.info("Put state that failover has completed");
       }
       finally
       {
-         lock.writeLock().release();
+         lock.readLock().release();
       }
+
+      return routed;
    }
 
-   public Binding getBindingforChannelId(long channelId) throws Exception
+   public boolean isLocal()
    {
-      lock.readLock().acquire();
+      return false;
+   }
 
-      try
+   /**
+    * Check for any transactions that need to be committed or rolled back
+    */
+   public void check(Integer nodeId) throws Throwable
+   {
+      if (trace) { log.trace(this.currentNodeId + " checking for any stranded transactions for node " + nodeId); }
+
+      synchronized (holdingArea)
       {
-         //First look in the failed map
-         //Failed bindings are stored in the failed map by channel id
-         Map channelMap = (Map)failedBindings.get(new Integer(currentNodeId));
-         Binding binding = null;
-         if (channelMap != null)
-         {
-            binding = (Binding)channelMap.get(new Long(channelId));
-         }
+         Iterator iter = holdingArea.entrySet().iterator();
 
-         if (binding == null)
+         List toRemove = new ArrayList();
+
+         while (iter.hasNext())
          {
-            //Not found in the failed map - look in the name map
-            Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
+            Map.Entry entry = (Map.Entry)iter.next();
 
-            if (nameMap != null)
+            TransactionId id = (TransactionId)entry.getKey();
+
+            if (id.getNodeId() == nodeId.intValue())
             {
-               for (Iterator iterbindings = nameMap.values().iterator(); iterbindings.hasNext();)
+               ClusterTransaction tx = (ClusterTransaction)entry.getValue();
+
+               if (trace) { log.trace("Found transaction " + tx + " in holding area"); }
+
+               boolean commit = tx.check(this);
+
+               if (trace) { log.trace(this.currentNodeId + " transaction " + tx + " will be committed?: " + commit); }
+
+               if (commit)
                {
-                  Binding itemBinding = (Binding)iterbindings.next();
-                  if (itemBinding.getQueue().getChannelID() == channelId)
-                  {
-                     binding = itemBinding;
-                     break;
-                  }
+                  tx.commit(this);
                }
+               else
+               {
+                  tx.rollback(this);
+               }
+
+               toRemove.add(id);
+
+               if (trace) { log.trace(this.currentNodeId + " resolved " + tx); }
             }
-            else
-            {
-               log.info("nameMap is null");
-            }
          }
-         log.info("Returned " + binding);
-         return binding;
+
+         //Remove the transactions from the holding area
+
+         iter = toRemove.iterator();
+
+         while (iter.hasNext())
+         {
+            TransactionId id = (TransactionId)iter.next();
+
+            holdingArea.remove(id);
+         }
       }
-      finally
+      if (trace) { log.trace(this.currentNodeId + " check complete"); }
+   }
+
+   public int getNodeId()
+   {
+      return currentNodeId;
+   }
+
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer("ClusteredPostOffice[");
+      sb.append(currentNodeId).append(":").append(getOfficeName()).append(":");
+
+      if (syncChannel == null)
       {
-         lock.readLock().release();
+         sb.append("UNINITIALIZED");
       }
+      else
+      {
+         Address addr = syncChannel.getLocalAddress();
+         if (addr == null)
+         {
+            sb.append("UNCONNECTED");
+         }
+         else
+         {
+            sb.append(addr);
+         }
+      }
+
+      sb.append("]");
+      return sb.toString();
    }
 
    public String printBindingInformation()
@@ -1747,10 +1518,27 @@
       return buffer.toString();
    }
 
+   /**
+    * MUST ONLY be used for testing!
+    */
+   public void setFail(boolean beforeCommit, boolean afterCommit, boolean handleResult)
+   {
+      this.failBeforeCommit = beforeCommit;
+      this.failAfterCommit = afterCommit;
+      this.failHandleResult = handleResult;
+   }
 
+   /**
+    * MUST ONLY be used for testing!
+    */
+   public Collection getHoldingTransactions()
+   {
+      return holdingArea.values();
+   }
 
-   // Protected ---------------------------------------------------------------------------------------
+   // Package protected ---------------------------------------------
 
+   // Protected -----------------------------------------------------
 
    protected void addToNameMap(Binding binding)
    {
@@ -1764,21 +1552,6 @@
       }
    }
 
-   private void addIntoFailedMaps(Binding binding)
-   {
-      Map channelMap = (Map)failedBindings.get(new Integer(binding.getNodeId()));
-
-      if (channelMap == null)
-      {
-         channelMap = new LinkedHashMap();
-
-         failedBindings.put(new Integer(binding.getNodeId()), channelMap);
-      }
-
-      channelMap.put(new Long(binding.getQueue().getChannelID()), binding);
-   }
-
-
    protected void addToConditionMap(Binding binding)
    {
       Condition condition = binding.getCondition();
@@ -1905,8 +1678,18 @@
       return new DefaultBinding(nodeId, condition, queue, failed);
    }
 
-   // Private ------------------------------------------------------------------------------------------
+   // Private -------------------------------------------------------
 
+   private void sendBindRequest(Condition condition, LocalClusteredQueue queue, Binding binding)
+      throws Exception
+   {
+      BindRequest request =
+         new BindRequest(this.currentNodeId, queue.getName(), condition.toText(), queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
+                         binding.getQueue().getChannelID(), queue.isRecoverable(), binding.isFailed());
+
+      syncSendRequest(request);
+   }
+
    private boolean leaveMessageReceived(Integer nodeId) throws Exception
    {
       synchronized (leftSet)
@@ -2168,7 +1951,7 @@
          BindingInfo info = (BindingInfo)iter.next();
 
          Condition condition = conditionFactory.createCondition(info.getConditionText());
-         
+
          Binding binding = this.createBinding(info.getNodeId(), condition, info.getQueueName(), info.getChannelId(),
                                               info.getFilterString(), info.isDurable(),info.isFailed());
 
@@ -2273,9 +2056,6 @@
          }
       }
    }
-
-
-
    /*
     * A new node has joined the group
     */
@@ -2312,58 +2092,311 @@
       check(theNodeId);
 
       synchronized (failoverMap)
-      {         
+      {
          //Need to evaluate this before we regenerate the failover map
-         Integer failoverNode = (Integer)failoverMap.get(theNodeId);                  
-    
+         Integer failoverNode = (Integer)failoverMap.get(theNodeId);
+
          if (failoverNode == null)
          {
             throw new IllegalStateException("Cannot find failover node for node " + theNodeId);
          }
-         
+
          //debug dump failover map
-         
+
          Iterator iter = failoverMap.entrySet().iterator();
-         
+
          log.info("Dumping failover map");
          while (iter.hasNext())
          {
             Map.Entry entry = (Map.Entry)iter.next();
-            
+
             Integer nodeId = (Integer)entry.getKey();
-            
+
             Integer failoverNodeId = (Integer)entry.getValue();
-            
+
             log.info("node->failover node: " + nodeId + " --> " + failoverNodeId);
          }
          log.info("end dump");
-         
+
          //end debug
-         
+
          boolean isFailover = failoverNode.intValue() == this.currentNodeId;
-            
+
          log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
-   
+
          log.info("Crashed: " + crashed);
-   
+
          //Remove any replicant data and non durable bindings for the node - again we need to do this
          //irrespective of whether we crashed
          //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
          removeDataForNode(theNodeId);
-   
+
          if (crashed && isFailover)
          {
             //The node crashed and we are the failover node
             //so let's perform failover
-   
+
             //TODO server side valve
-   
+
             failOver(theNodeId.intValue());
          }
       }
    }
 
+   /**
+    *  Verifies changes on the View deciding if a node joined or left the cluster.
+    */
+   private void verifyMembership(View oldView, View newView) throws Throwable
+   {
+      if (oldView != null)
+      {
+         for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+         {
+            Address address = (Address)i.next();
+            if (!newView.containsMember(address))
+            {
+               nodeLeft(address);
+            }
+         }
+      }
 
+      for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+      {
+         Address address = (Address)i.next();
+         if (oldView == null || !oldView.containsMember(address))
+         {
+            nodeJoined(address);
+         }
+      }
+   }
+
+   /**
+    * This method fails over all the queues from node <failedNodeId> onto this node
+    * It is triggered when a JGroups view change occurs due to a member leaving and
+    * it's determined the member didn't leave cleanly
+    *
+    * @param failedNodeId
+    * @throws Exception
+    */
+   private void failOver(int failedNodeId) throws Exception
+   {
+      //Need to lock
+      lock.writeLock().acquire();
+
+      try
+      {
+         log.info(this.currentNodeId + " is performing failover for node " + failedNodeId);
+
+         /*
+         We make sure a FailoverStatus object is put in the replicated data for the node
+         The real failover node will always add this in.
+         This means that each node knows which node has really started the failover for another node, and
+         which node did failover for other nodes in the past
+         We cannot rely on the failoverMap for this, since that will regenerated once failover is done,
+         because of the change in membership.
+         And clients may failover after that and need to know if they have the correct node.
+         Since this is the first thing we do after detecting failover, it should be very quick that
+         all nodes know, however there is still a chance that a client tries to failover before
+         the information is replicated.
+         */
+
+         Map replicants = (Map)get(FAILED_OVER_FOR_KEY);
+
+         FailoverStatus status = (FailoverStatus)replicants.get(new Integer(currentNodeId));
+
+         if (status == null)
+         {
+            status = new FailoverStatus();
+         }
+
+         status.startFailingOverForNode(failedNodeId);
+
+         log.info("Putting state that failover is starting");
+
+         put(FAILED_OVER_FOR_KEY, status);
+
+         log.info("Put state that failover is starting");
+
+         //Get the map of queues for the failed node
+
+         Map subMaps = (Map)nameMaps.get(new Integer(failedNodeId));
+         if (subMaps==null || subMaps.size()==0)
+         {
+            log.warn("Couldn't find any binding to failOver from serverId=" +failedNodeId);
+            return;
+         }
+
+         //Compile a list of the queue names to remove
+         //Note that any non durable bindings will already have been removed (in removeDataForNode()) when the
+         //node leave was detected, so if there are any non durable bindings left here then
+         //this is an error
+
+         //We iterate through twice to avoid ConcurrentModificationException
+         ArrayList namesToRemove = new ArrayList();
+         for (Iterator iterNames = subMaps.entrySet().iterator(); iterNames.hasNext();)
+         {
+            Map.Entry entry = (Map.Entry)iterNames.next();
+
+            Binding binding = (Binding )entry.getValue();
+
+            //Sanity check
+            if (!binding.getQueue().isRecoverable())
+            {
+               throw new IllegalStateException("Find non recoverable queue in map, these should have been removed!");
+            }
+
+            //Sanity check
+            if (!binding.getQueue().isClustered())
+            {
+               throw new IllegalStateException("Queue is not clustered!: " + binding.getQueue().getName());
+            }
+
+            ClusteredQueue queue = (ClusteredQueue) binding.getQueue();
+
+            //Sanity check
+            if (queue.isLocal())
+            {
+               throw new IllegalStateException("Queue is local!: " + binding.getQueue().getName());
+            }
+            namesToRemove.add(entry);
+         }
+
+         log.info("Deleting " + namesToRemove.size() + " bindings from old node");
+
+         for (Iterator iterNames = namesToRemove.iterator(); iterNames.hasNext();)
+         {
+            Map.Entry entry = (Map.Entry)iterNames.next();
+
+            Binding binding = (Binding)entry.getValue();
+
+            RemoteQueueStub stub = (RemoteQueueStub)binding.getQueue();
+
+            String queueName = (String)entry.getKey();
+
+            //First the binding is removed from the in memory condition and name maps
+            this.removeBinding(failedNodeId, queueName);
+
+            //Then deleted from the database
+            this.deleteBinding(failedNodeId, queueName);
+
+            log.info("deleted binding for " + queueName);
+
+            //Note we do not need to send an unbind request across the cluster - this is because
+            //when the node crashes a view change will hit the other nodes and that will cause
+            //all binding data for that node to be removed anyway
+
+            //If there is already a queue registered with the same name, then we set a flag "failed" on the
+            //binding and then the queue will go into a special list of failed bindings
+            //otherwise we treat at as a normal queue
+            //This is because we cannot deal with more than one queue with the same name
+            //Any new consumers will always only connect to queues in the main name map
+            //This may mean that queues in the failed map have messages stranded in them if consumers
+            //disconnect (since no more can reconnect)
+            //However we message redistribution activated other queues will be able to consume from them.
+            //TODO allow message redistribution for queues in the failed list
+            boolean failed = this.internalGetBindingForQueueName(queueName) != null;
+
+            if (!failed)
+            {
+               log.info("The current node didn't have a queue " + queueName + " so it's assuming the queue as a regular queue");
+            }
+            else
+            {
+               log.info("There is already a queue with that name so adding to failed map");
+            }
+
+            //Create a new binding
+            Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
+                                                    stub.getName(), stub.getChannelID(),
+                                                    stub.getFilter(), stub.isRecoverable(), failed);
+
+            log.info("Created new binding");
+
+            //Insert it into the database
+            insertBinding(newBinding);
+
+            LocalClusteredQueue clusteredQueue = (LocalClusteredQueue )newBinding.getQueue();
+
+            clusteredQueue.deactivate();
+            clusteredQueue.load();
+            clusteredQueue.activate();
+
+            log.info("Loaded queue");
+
+            //Add the new binding in memory
+            addBinding(newBinding);
+
+            //Send a bind request so other nodes add it too
+            sendBindRequest(binding.getCondition(), clusteredQueue,newBinding);
+
+            //FIXME there is a problem in the above code.
+            //If the server crashes between deleting the binding from the database
+            //and creating the new binding in the database, then the binding will be completely
+            //lost from the database when the server is resurrected.
+            //To remedy, both db operations need to be done in the same JBDC tx
+         }
+
+         log.info("Server side fail over is now complete");
+
+         //TODO - should this be in a finally? I'm not sure
+         status.finishFailingOver();
+
+         log.info("Putting state that failover has completed");
+         put(FAILED_OVER_FOR_KEY, status);
+         log.info("Put state that failover has completed");
+      }
+      finally
+      {
+         lock.writeLock().release();
+      }
+   }
+
+   private void addIntoFailedMaps(Binding binding)
+   {
+      Map channelMap = (Map)failedBindings.get(new Integer(binding.getNodeId()));
+
+      if (channelMap == null)
+      {
+         channelMap = new LinkedHashMap();
+
+         failedBindings.put(new Integer(binding.getNodeId()), channelMap);
+      }
+
+      channelMap.put(new Long(binding.getQueue().getChannelID()), binding);
+   }
+
+   private void sendJMXNotification(String notificationType)
+   {
+      Notification n = new Notification(notificationType, "", 0l);
+      nbSupport.sendNotification(n);
+   }
+
+   private void handleViewAccepted(View newView)
+   {
+      //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
+      //TODO:     can't we do the same since this is pretty useful?
+      log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
+               + DefaultClusteredPostOffice.this.getOfficeName());
+
+      // JGroups will make sure this method is never called by more than one thread concurrently
+
+      View oldView = currentView;
+      currentView = newView;
+
+      try
+      {
+         verifyMembership(oldView, newView);
+         sendJMXNotification(VIEW_CHANGED_NOTIFICATION);
+      }
+      catch (Throwable e)
+      {
+         log.error("Caught Exception in MembershipListener", e);
+         IllegalStateException e2 = new IllegalStateException(e.getMessage());
+         e2.setStackTrace(e.getStackTrace());
+         throw e2;
+      }
+   }
+
    // Inner classes -------------------------------------------------------------------
 
    /*
@@ -2462,10 +2495,11 @@
       {
          try
          {
-            //We queue up changes and execute them asynchronously.
-            //This is because JGroups will not let us do stuff like send synch messages
-            //using the same thread that delivered the view change and this is what we need to
-            //do in failover, for example.
+            // We queue up changes and execute them asynchronously.
+            // This is because JGroups will not let us do stuff like send synch messages using the
+            // same thread that delivered the view change and this is what we need to do in
+            // failover, for example.
+
             viewExecutor.execute(new HandleViewAcceptedRunnable(newView));
          }
          catch (InterruptedException e)
@@ -2480,41 +2514,16 @@
          return null;
       }
    }
-   
-   private void handleViewAccepted(View newView)
-   {
-      //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
-      //TODO:     can't we do the same since this is pretty useful?
-      log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
-               + DefaultClusteredPostOffice.this.getOfficeName());
 
-      // JGroups will make sure this method is never called by more than one thread concurrently
-
-      View oldView = currentView;
-      currentView = newView;
-
-      try
-      {
-         verifyMembership(oldView, newView);
-      }
-      catch (Throwable e)
-      {
-         log.error("Caught Exception in MembershipListener", e);
-         IllegalStateException e2 = new IllegalStateException(e.getMessage());
-         e2.setStackTrace(e.getStackTrace());
-         throw e2;
-      }
-   }
-
    private class HandleViewAcceptedRunnable implements Runnable
    {
       private View newView;
-      
+
       HandleViewAcceptedRunnable(View newView)
       {
          this.newView = newView;
       }
-      
+
       public void run()
       {
          handleViewAccepted(newView);

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -6,8 +6,10 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import javax.management.NotificationBroadcaster;
 import java.util.Set;
 
+
 /**
  * Group management interface.
  *
@@ -15,10 +17,12 @@
  * @version <tt>$Revision$</tt>
  * $Id$
  */
-public interface Peer
+public interface Peer extends NotificationBroadcaster
 {
    /**
     * Returns a set of nodeIDs (integers) representing the IDs of cluster's nodes.
     */
    Set getNodeIDView();
+
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -8,9 +8,15 @@
 
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
 
+import javax.management.NotificationListener;
+import javax.management.Notification;
+import javax.management.ObjectName;
 import java.util.Set;
 
+import EDU.oswego.cs.dl.util.concurrent.Slot;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
@@ -51,6 +57,44 @@
       }
    }
 
+   public void testJoinNotification() throws Exception
+   {
+      ViewChangeNotificationListener listener = new ViewChangeNotificationListener();
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
+
+      try
+      {
+         ServerManagement.start("all", 0);
+
+         log.info("Server 0 started");
+
+         ServerManagement.addNotificationListener(0, postOfficeObjectName, listener);
+
+         log.info("NotificationListener added to server 0");
+
+         ServerManagement.start("all", 1);
+
+         log.info("Blocking to receive notification ...");
+
+         if (!listener.viewChanged(120000))
+         {
+            fail("Did not receive view change!");
+         }
+
+         Set view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+      }
+      finally
+      {
+         ServerManagement.removeNotificationListener(0, postOfficeObjectName, listener);
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
+      }
+   }
+
    public void testTwoNodesCluster() throws Exception
    {
       try
@@ -146,11 +190,196 @@
 
    public void testCleanLeave() throws Exception
    {
+      try
+      {
+         // Start with a 3 node cluster
 
+         ServerManagement.start("all", 0);
+         ServerManagement.start("all", 1);
+         ServerManagement.start("all", 2);
+
+         Set view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(3, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(2)));
+
+         // Make node 0 to "cleanly" leave the cluster
+
+         ServerManagement.stop(0);
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(2)));
+
+         // Make node 2 to "cleanly" leave the cluster
+
+         ServerManagement.stop(2);
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(1)));
+
+         // Reuse the "hollow" RMI server 0 to start another cluster node
+
+         ServerManagement.start("all", 0);
+
+         view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+
+         // Reuse the "hollow" RMI server 2 to start another cluster node
+
+         ServerManagement.start("all", 2);
+
+         view = ServerManagement.getServer(2).getNodeIDView();
+
+         assertEquals(3, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(2)));
+
+      }
+      finally
+      {
+         ServerManagement.stop(2);
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
+      }
    }
 
+   public void testDirtyLeaveOneNode() throws Exception
+   {
+      ViewChangeNotificationListener viewChange = new ViewChangeNotificationListener();
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
 
+      try
+      {
+         // Start with a 2 node cluster
 
+         ServerManagement.start("all", 0);
+         ServerManagement.start("all", 1);
+
+         Set view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+         ServerManagement.addNotificationListener(0, postOfficeObjectName, viewChange);
+
+         // Make node 1 to "dirty" leave the cluster, by killing the VM running it.
+
+         ServerManagement.kill(1);
+
+         log.info("########");
+         log.info("######## KILLED 1");
+         log.info("########");
+
+         // Wait for membership change notification
+
+         if (!viewChange.viewChanged(120000))
+         {
+            fail("Did not receive view change after killing server 2!");
+         }
+
+         view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(0)));
+      }
+      finally
+      {
+         ServerManagement.removeNotificationListener(0, postOfficeObjectName, viewChange);
+
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
+      }
+   }
+
+   public void testDirtyLeaveTwoNodes() throws Exception
+   {
+      ViewChangeNotificationListener viewChange = new ViewChangeNotificationListener();
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
+
+      try
+      {
+         // Start with a 3 node cluster
+
+         ServerManagement.start("all", 0);
+         ServerManagement.start("all", 1);
+         ServerManagement.start("all", 2);
+
+         Set view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(3, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+         assertTrue(view.contains(new Integer(2)));
+
+         ServerManagement.addNotificationListener(0, postOfficeObjectName, viewChange);
+
+         // Make node 2 to "dirty" leave the cluster, by killing the VM running it.
+
+         ServerManagement.kill(2);
+
+         log.info("########");
+         log.info("######## KILLED 2");
+         log.info("########");
+
+         // Wait for membership change notification
+
+         if (!viewChange.viewChanged(120000))
+         {
+            fail("Did not receive view change after killing server 2!");
+         }
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(1)));
+
+         // Make node 1 to "dirty" leave the cluster, by killing the VM running it.
+
+         ServerManagement.kill(1);
+
+         log.info("########");
+         log.info("######## KILLED 1");
+         log.info("########");
+
+         // Wait for membership change notification
+
+         if (!viewChange.viewChanged(120000))
+         {
+            fail("Did not receive view change after killing server 1!");
+         }
+
+         view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(0)));
+
+      }
+      finally
+      {
+         ServerManagement.removeNotificationListener(0, postOfficeObjectName, viewChange);
+
+         ServerManagement.stop(2);
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
+      }
+   }
+
+
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -169,4 +398,45 @@
 
    // Inner classes -------------------------------------------------
 
+   private class ViewChangeNotificationListener implements NotificationListener
+   {
+      private Slot slot;
+
+      ViewChangeNotificationListener()
+      {
+         slot = new Slot();
+      }
+
+      public void handleNotification(Notification notification, Object object)
+      {
+
+         if (!ClusteredPostOffice.VIEW_CHANGED_NOTIFICATION.equals(notification.getType()))
+         {
+            // ignore it
+            return;
+         }
+
+         log.info("received VIEW_CHANGED notification");
+
+         try
+         {
+            slot.put(Boolean.TRUE);
+         }
+         catch(InterruptedException e)
+         {
+            log.error(e);
+         }
+      }
+
+      public boolean viewChanged(long timeout) throws InterruptedException
+      {
+         Boolean result = (Boolean)slot.poll(timeout);
+         if (result == null)
+         {
+            return false;
+         }
+         return result.booleanValue();
+      }
+   }
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -38,7 +38,6 @@
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
@@ -503,8 +502,8 @@
          
          log.info("************ KILLING (CRASHING) SERVER 1");
          
-         ServerManagement.getServer(1).destroy();
-         
+         ServerManagement.getServer(1).kill();
+
          log.info("killed server, now waiting");
          
          Thread.sleep(5000);
@@ -837,28 +836,28 @@
    
    // Private -------------------------------------------------------
    
-   private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
-   {
-      MessageProxy message = (MessageProxy) consumer.receive(3000);
-      TextMessage txtMessage = (TextMessage) message;
-      if (message != null)
-      {
-         log.info(text + ": messageID from messageReceived=" + message.getMessage().getMessageID() + " message = " + message + " content=" + txtMessage.getText());
-      } else
-      {
-         log.info(text + ": Message received was null");
-      }
-      if (shouldAssert)
-      {
-         if (shouldBeNull)
-         {
-            assertNull(message);
-         } else
-         {
-            assertNotNull(message);
-         }
-      }
-   }
+//   private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
+//   {
+//      MessageProxy message = (MessageProxy) consumer.receive(3000);
+//      TextMessage txtMessage = (TextMessage) message;
+//      if (message != null)
+//      {
+//         log.info(text + ": messageID from messageReceived=" + message.getMessage().getMessageID() + " message = " + message + " content=" + txtMessage.getText());
+//      } else
+//      {
+//         log.info(text + ": Message received was null");
+//      }
+//      if (shouldAssert)
+//      {
+//         if (shouldBeNull)
+//         {
+//            assertNull(message);
+//         } else
+//         {
+//            assertNotNull(message);
+//         }
+//      }
+//   }
    
    // Inner classes -------------------------------------------------
    

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -103,7 +103,7 @@
    
 //   public void testKill() throws Exception
 //   {
-//      ServerManagement.getServer(0).destroy();
+//      ServerManagement.getServer(0).kill();
 //   }
 
    public void testDistributedTopic() throws Exception

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -116,7 +116,7 @@
       
       String remotingSessionId = (String)remoteServer.executeCommand(command);
       
-      remoteServer.destroy();
+      remoteServer.kill();
         
       //we have removed the exception listener so the server side resouces shouldn't be cleared up
       

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -115,7 +115,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -117,7 +117,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -119,7 +119,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -121,7 +121,7 @@
       log.info("we have = " + ((SimpleConnectionManager)cm).getClients().size() + " clients registered on SimpleconnectionManager");
       
       // Now we should have a client connection from the remote server to the local server
-      remoteServer.destroy();
+      remoteServer.kill();
       log.info("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -117,7 +117,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -24,7 +24,13 @@
 import java.rmi.Naming;
 import java.util.Hashtable;
 import java.util.Set;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.List;
+import java.util.Iterator;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
+import javax.management.Notification;
 import javax.transaction.UserTransaction;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.DestinationManager;
@@ -35,6 +41,7 @@
 import org.jboss.test.messaging.tools.jmx.rmi.LocalTestServer;
 import org.jboss.test.messaging.tools.jmx.rmi.RMITestServer;
 import org.jboss.test.messaging.tools.jmx.rmi.Server;
+import org.jboss.test.messaging.tools.jmx.rmi.NotificationListenerID;
 import org.jboss.test.messaging.tools.jndi.InVMInitialContextFactory;
 import org.jboss.test.messaging.tools.jndi.RemoteInitialContextFactory;
 
@@ -73,6 +80,9 @@
 
    private static Server[] servers = new Server[MAX_SERVER_COUNT];
 
+   // Map<NotificationListener - NotificationListenerPoller>
+   private static Map notificationListenerPollers = new HashMap();
+
    public static boolean isLocal()
    {
       return !"true".equals(System.getProperty("remote"));
@@ -171,17 +181,45 @@
 
    public static synchronized void stop(int index) throws Exception
    {
-      insureStarted(index);
+      if (servers[index] == null)
+      {
+         log.warn("Server " + index + " has not been created, so it cannot be stopped");
+         return;
+      }
+
+      if (!servers[index].isStarted())
+      {
+         log.warn("Server " + index + " either has not been started, or it is stopped already");
+         return;
+      }
+
       servers[index].stop();
    }
 
+   /**
+    * TODO - this methods should be removed, to not be confused with kill(index)
+    * @deprecated
+    */
    public static synchronized void destroy() throws Exception
    {
       stop();
+      servers[0].kill();
+      servers[0] = null;
+   }
 
-      servers[0].destroy();
+   /**
+    * Abruptly kills the VM running the specified server.
+    */
+   public static synchronized void kill(int index) throws Exception
+   {
+      if (servers[index] == null)
+      {
+         log.warn("Server " + index + " has not been created, so it cannot be killed");
+         return;
+      }
 
-      servers[0] = null;
+      servers[index].kill();
+      servers[index] = null;
    }
 
    public static void disconnect() throws Exception
@@ -224,6 +262,59 @@
       return servers[0].invoke(on, operationName, params, signature);
    }
 
+   public static void addNotificationListener(int serverIndex, ObjectName on,
+                                              NotificationListener listener) throws Exception
+   {
+      insureStarted(serverIndex);
+
+      if (isLocal())
+      {
+         // add the listener directly to the server
+         servers[serverIndex].addNotificationListener(on, listener);
+      }
+      else
+      {
+         // is remote, need to poll
+         NotificationListenerPoller p =
+            new NotificationListenerPoller((Server)servers[serverIndex], on, listener);
+
+         synchronized(notificationListenerPollers)
+         {
+            notificationListenerPollers.put(listener, p);
+         }
+
+         new Thread(p, "Poller for " + Integer.toHexString(p.hashCode())).start();
+      }
+   }
+
+   public static void removeNotificationListener(int serverIndex, ObjectName on,
+                                                 NotificationListener listener) throws Exception
+   {
+      insureStarted(serverIndex);
+
+      if (isLocal())
+      {
+         // remove the listener directly
+         servers[serverIndex].removeNotificationListener(on, listener);
+      }
+      else
+      {
+         // is remote
+
+         NotificationListenerPoller p = null;
+         synchronized(notificationListenerPollers)
+         {
+            p = (NotificationListenerPoller)notificationListenerPollers.remove(listener);
+         }
+
+         if (p != null)
+         {
+            // stop the polling thread
+            p.stop();
+         }
+      }
+   }
+
    public static Set query(ObjectName pattern) throws Exception
    {
       insureStarted();
@@ -645,7 +736,9 @@
          {
             log.info("trying to connect to the remote RMI server " + index + 
                      (attempt == 1 ? "" : ", attempt " + attempt));
+
             s = (Server)Naming.lookup(name);
+
             log.info("connected to the remote server");
          }
          catch(Exception e)
@@ -805,4 +898,63 @@
 //         }
 //      }
 //   }
+
+   private static long listenerIDCounter = 0;
+
+   static class NotificationListenerPoller implements Runnable
+   {
+      public static final int POLL_INTERVAL = 500;
+
+      private long id;
+      private Server server;
+      private NotificationListener listener;
+      private volatile boolean running;
+
+      private synchronized static long generateID()
+      {
+         return listenerIDCounter++;
+      }
+
+      NotificationListenerPoller(Server server, ObjectName on, NotificationListener listener)
+         throws Exception
+      {
+         id = generateID();
+         this.server = server;
+
+         server.addNotificationListener(on, new NotificationListenerID(id));
+
+         this.listener = listener;
+         this.running = true;
+      }
+
+      public void run()
+      {
+         while(running)
+         {
+            try
+            {
+               List notifications = server.pollNotificationListener(id);
+
+               for(Iterator i = notifications.iterator(); i.hasNext(); )
+               {
+                  Notification n = (Notification)i.next();
+                  listener.handleNotification(n, null);
+               }
+
+               Thread.sleep(POLL_INTERVAL);
+            }
+            catch(Exception e)
+            {
+               log.error(e);
+               stop();
+            }
+         }
+      }
+
+      public void stop()
+      {
+         running = false;
+      }
+   }
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -45,6 +45,7 @@
 import javax.management.MBeanServer;
 import javax.management.MBeanServerFactory;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
@@ -704,6 +705,18 @@
       return mbeanServer.getAttribute(on, name);
    }
 
+   public void addNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      mbeanServer.addNotificationListener(on, listener, null, null);
+   }
+
+   public void removeNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      mbeanServer.removeNotificationListener(on, listener);
+   }
+
    public void bindDefaultJMSProvider() throws Exception
    {
       JNDIProviderAdapter pa = new JNDIProviderAdapter();

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -30,6 +30,7 @@
 import javax.jms.Queue;
 import javax.jms.Topic;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
@@ -170,9 +171,9 @@
       }
    }
 
-   public synchronized void destroy() throws Exception
+   public synchronized void kill() throws Exception
    {
-      stop();
+      throw new IllegalStateException("Cannot KILL a local server. Consider using stop() instead.");
    }
 
    public ObjectName deploy(String mbeanConfiguration) throws Exception
@@ -203,6 +204,18 @@
       return sc.invoke(on, operationName, params, signature);
    }
 
+   public void addNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      sc.addNotificationListener(on, listener);
+   }
+
+   public void removeNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      sc.removeNotificationListener(on, listener);
+   }
+
    public Set query(ObjectName pattern) throws Exception
    {
       return sc.query(pattern);
@@ -808,6 +821,12 @@
       return (Set)sc.getAttribute(postOfficeObjectName, "NodeIDView");
    }
 
+   public List pollNotificationListener(long listenerID) throws Exception
+   {
+      throw new IllegalStateException("Poll doesn't make sense on a local server. " +
+                                      "Register listeners directly instead.");
+   }
+
    // Public --------------------------------------------------------
 
    // Package protected ---------------------------------------------

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -0,0 +1,58 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.tools.jmx.rmi;
+
+import javax.management.NotificationListener;
+import javax.management.Notification;
+import java.io.Serializable;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class NotificationListenerID implements Serializable, NotificationListener
+{
+   // Constants -----------------------------------------------------
+
+   private static final long serialVersionUID = -39839086486546L;
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private long id;
+
+   // Constructors --------------------------------------------------
+
+   public NotificationListenerID(long id)
+   {
+      this.id = id;
+   }
+
+   // NotificationListener implementation ---------------------------
+
+   public void handleNotification(Notification notification, Object object)
+   {
+      throw new IllegalStateException("Do not use this method directly!");
+   }
+
+   // Public --------------------------------------------------------
+
+   public long getID()
+   {
+      return id;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Added: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -0,0 +1,67 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.tools.jmx.rmi;
+
+import javax.management.NotificationListener;
+import javax.management.Notification;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Collections;
+
+/**
+ * Stores notifications until they're transferred to the remote client.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class ProxyNotificationListener implements NotificationListener
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private List notifications;
+
+   // Constructors --------------------------------------------------
+
+   ProxyNotificationListener()
+   {
+      notifications = new ArrayList();
+   }
+
+   // NotificationListener implementation ---------------------------
+
+   public synchronized void handleNotification(Notification notification, Object object)
+   {
+      notifications.add(notification);
+   }
+
+   // Public --------------------------------------------------------
+
+   public synchronized List drain()
+   {
+      if (notifications.size() == 0)
+      {
+         return Collections.EMPTY_LIST;
+      }
+
+      List old = notifications;
+      notifications = new ArrayList();
+      return old;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -25,7 +25,12 @@
 import java.rmi.registry.Registry;
 import java.rmi.server.UnicastRemoteObject;
 import java.util.Set;
+import java.util.List;
+import java.util.Map;
+import java.util.HashMap;
+import java.util.Collections;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
@@ -46,24 +51,20 @@
  */
 public class RMITestServer extends UnicastRemoteObject implements Server
 {
-   private static final long serialVersionUID = -368445344011004778L;
+   // Constants -----------------------------------------------------
 
+   public static final String RMI_SERVER_PREFIX = "messaging_rmi_server_";
+   public static final String NAMING_SERVER_PREFIX = "naming_rmi_server_";
+
    public static final int DEFAULT_REGISTRY_PORT = 22555;
    public static final int DEFAULT_SERVER_INDEX = 0;
    public static final String DEFAULT_SERVER_HOST = "localhost";
 
+   private static final long serialVersionUID = -368445344011004778L;
    private static final Logger log = Logger.getLogger(RMITestServer.class);
 
-   protected RemoteTestServer server;
+   // Static --------------------------------------------------------
 
-   private RMINamingDelegate namingDelegate;
-
-
-   public static final String RMI_SERVER_PREFIX = "messaging_rmi_server_";
-   public static final String NAMING_SERVER_PREFIX = "naming_rmi_server_";
-
-   private static Registry registry;
-
    public static void main(String[] args) throws Exception
    {
       log.debug("initializing RMI runtime");
@@ -92,6 +93,7 @@
       // let RMI know the bind address
       System.setProperty("java.rmi.server.hostname", host);
 
+      Registry registry;
 
       // try to bind first
       try
@@ -115,123 +117,150 @@
       log.info("RMI server " + serverIndex + " bound");
    }
 
-   public class VMKiller implements Runnable
-   {
-      public void run()
-      {
-         log.info("shutting down the VM");
+   // Attributes ----------------------------------------------------
 
-         try
-         {
-            Thread.sleep(250);
-         }
-         catch(Exception e)
-         {
-            log.warn("interrupted while sleeping", e);
-         }
+   protected RemoteTestServer server;
+   private RMINamingDelegate namingDelegate;
+   // Map<Long-ProxyNotificationListener>
+   private Map proxyListeners;
 
-         System.exit(0);
-      }
-   }
+   // Constructors --------------------------------------------------
 
    public RMITestServer(int index) throws Exception
    {
       namingDelegate = new RMINamingDelegate(index);
       server = new RemoteTestServer(index);
+      proxyListeners = new HashMap();
    }
 
-   public void configureSecurityForDestination(String destName, String config) throws Exception
+   // Server implementation -----------------------------------------
+
+   public void start(String containerConfig) throws Exception
    {
-      server.configureSecurityForDestination(destName, config);
+      server.start(containerConfig);
    }
 
-   public ObjectName deploy(String mbeanConfiguration) throws Exception
+   public void stop() throws Exception
    {
-      return server.deploy(mbeanConfiguration);
+      server.stop();
+      namingDelegate.reset();
    }
 
-   public void deployQueue(String name, String jndiName, boolean clustered) throws Exception
+   public synchronized void kill() throws Exception
    {
-      server.deployQueue(name, jndiName, clustered);
+      // Kills the server without doing any graceful shutdown. For graceful shutdown use stop().
+      new Thread(new VMKiller(), "VM Killer").start();
    }
 
-   public void deployTopic(String name, String jndiName, boolean clustered) throws Exception
+   public ObjectName deploy(String mbeanConfiguration) throws Exception
    {
-      server.deployTopic(name, jndiName, clustered);
+      return server.deploy(mbeanConfiguration);
    }
-   
-   public void deployQueue(String name,
-                           String jndiName,
-                           int fullSize,
-                           int pageSize,
-                           int downCacheSize,
-                           boolean clustered) throws Exception
+
+   public void undeploy(ObjectName on) throws Exception
    {
-      server.deployQueue(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
+      server.undeploy(on);
    }
 
-   public void createQueue(String name, String jndiName) throws Exception
+   public Object getAttribute(ObjectName on, String attribute) throws Exception
    {
-      server.createQueue(name, jndiName);
+      return server.getAttribute(on, attribute);
    }
 
-   public void deployTopic(String name,
-                           String jndiName,
-                           int fullSize,
-                           int pageSize,
-                           int downCacheSize,
-                           boolean clustered) throws Exception
+   public void setAttribute(ObjectName on, String name, String valueAsString) throws Exception
    {
-      server.deployTopic(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
+      server.setAttribute(on, name, valueAsString);
    }
 
-   public void createTopic(String name, String jndiName) throws Exception
+   public Object invoke(ObjectName on, String operationName, Object[] params, String[] signature)
+      throws Exception
    {
-      server.createTopic(name, jndiName);
+      return server.invoke(on, operationName, params, signature);
    }
 
-   public void deployConnectionFactory(String objectName, String[] jndiBindings)
+   public void addNotificationListener(ObjectName on, NotificationListener listener)
       throws Exception
    {
-      server.deployConnectionFactory(objectName, jndiBindings);
+      if (!(listener instanceof NotificationListenerID))
+      {
+         throw new IllegalArgumentException("A RMITestServer can only handle NotificationListenerIDs!");
+      }
+
+      long id = ((NotificationListenerID)listener).getID();
+
+      ProxyNotificationListener pl = new ProxyNotificationListener();
+
+      synchronized(proxyListeners)
+      {
+         proxyListeners.put(new Long(id), pl);
+      }
+
+      server.addNotificationListener(on, pl);
    }
-   
-   public void deployConnectionFactory(String objectName, String[] jndiBindings, int prefetchSize)
+
+   public void removeNotificationListener(ObjectName on, NotificationListener listener)
       throws Exception
    {
-      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize);
+
+      if (!(listener instanceof NotificationListenerID))
+      {
+         throw new IllegalArgumentException("A RMITestServer can only handle NotificationListenerIDs!");
+      }
+
+      long id = ((NotificationListenerID)listener).getID();
+
+      ProxyNotificationListener pl = null;
+
+      synchronized(proxyListeners)
+      {
+         pl = (ProxyNotificationListener)proxyListeners.remove(new Long(id));
+      }
+
+      server.removeNotificationListener(on, pl);
    }
 
-   public void deployConnectionFactory(String objectName,
-                                       String[] jndiBindings,
-                                       int prefetchSize,
-                                       int defaultTempQueueFullSize,
-                                       int defaultTempQueuePageSize,
-                                       int defaultTempQueueDownCacheSize) throws Exception
+   public Set query(ObjectName pattern) throws Exception
    {
-      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize,
-               defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
+      return server.query(pattern);
    }
 
-   public void undeployConnectionFactory(ObjectName objectName) throws Exception
+   public String getDatabaseType()
    {
-      server.undeployConnectionFactory(objectName);
+      return server.getDatabaseType();
    }
 
-   public synchronized void destroy() throws Exception
+   public void log(int level, String text) throws Exception
    {
-      //Kill the server without doing any graceful shutdown
-      
-      //For graceful shutdown use stop()
-      
-      new Thread(new VMKiller(), "VM Killer").start();
+      server.log(level, text);
    }
 
-   public Object getAttribute(ObjectName on, String attribute) throws Exception
+   public void startServerPeer(int serverPeerID, String defaultQueueJNDIContext,
+                               String defaultTopicJNDIContext, boolean clustered) throws Exception
    {
-      return server.getAttribute(on, attribute);
+      server.
+         startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, clustered);
    }
 
+   public void stopServerPeer() throws Exception
+   {
+      server.stopServerPeer();
+   }
+
+   public boolean isServerPeerStarted() throws Exception
+   {
+      return server.isServerPeerStarted();
+   }
+
+   public ObjectName getServerPeerObjectName() throws Exception
+   {
+      return server.getServerPeerObjectName();
+   }
+
+   public boolean isStarted() throws Exception
+   {
+      return server.isStarted();
+   }
+
    public Set getConnectorSubsystems() throws Exception
    {
       return server.getConnectorSubsystems();
@@ -248,9 +277,9 @@
       server.removeServerInvocationHandler(subsystem);
    }
 
-   public String getDefaultSecurityConfig() throws Exception
+   public MessageStore getMessageStore() throws Exception
    {
-      return server.getDefaultSecurityConfig();
+      return server.getMessageStore();
    }
 
    public DestinationManager getDestinationManager() throws Exception
@@ -258,106 +287,122 @@
       return server.getDestinationManager();
    }
 
-   public MessageStore getMessageStore() throws Exception
+   public PersistenceManager getPersistenceManager() throws Exception
    {
-      return server.getMessageStore();
+      return server.getPersistenceManager();
    }
 
-   public PersistenceManager getPersistenceManager() throws Exception
+   public PostOffice getQueuePostOffice() throws Exception
    {
-      return server.getPersistenceManager();
+      return server.getQueuePostOffice();
    }
-   
-   public ObjectName getServerPeerObjectName() throws Exception
+
+   public PostOffice getTopicPostOffice() throws Exception
    {
-      return server.getServerPeerObjectName();
+      return server.getTopicPostOffice();
    }
 
-   public Object invoke(ObjectName on, String operationName, Object[] params, String[] signature) throws Exception
+   public ServerPeer getServerPeer() throws Exception
    {
-      return server.invoke(on, operationName, params, signature);
+      return server.getServerPeer();
    }
 
-   public boolean isServerPeerStarted() throws Exception
+   public void deployTopic(String name, String jndiName, boolean clustered) throws Exception
    {
-      return server.isServerPeerStarted();
+      server.deployTopic(name, jndiName, clustered);
    }
 
-   public boolean isStarted() throws Exception
+   public void deployTopic(String name,
+                           String jndiName,
+                           int fullSize,
+                           int pageSize,
+                           int downCacheSize,
+                           boolean clustered) throws Exception
    {
-      return server.isStarted();
+      server.deployTopic(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
    }
 
-   public void log(int level, String text) throws Exception
+   public void createTopic(String name, String jndiName) throws Exception
    {
-      server.log(level, text);
+      server.createTopic(name, jndiName);
    }
 
-   public Set query(ObjectName pattern) throws Exception
+   public void deployQueue(String name, String jndiName, boolean clustered) throws Exception
    {
-      return server.query(pattern);
+      server.deployQueue(name, jndiName, clustered);
    }
 
-   public String getDatabaseType()
+   public void deployQueue(String name,
+                           String jndiName,
+                           int fullSize,
+                           int pageSize,
+                           int downCacheSize,
+                           boolean clustered) throws Exception
    {
-      return server.getDatabaseType();
+      server.deployQueue(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
    }
 
-   public void setAttribute(ObjectName on, String name, String valueAsString) throws Exception
+   public void createQueue(String name, String jndiName) throws Exception
    {
-      server.setAttribute(on, name, valueAsString);
+      server.createQueue(name, jndiName);
    }
 
-   public void setDefaultSecurityConfig(String config) throws Exception
+   public void undeployDestination(boolean isQueue, String name) throws Exception
    {
-      server.setDefaultSecurityConfig(config);
+      server.undeployDestination(isQueue, name);
    }
 
-   public void start(String containerConfig) throws Exception
+   public boolean destroyDestination(boolean isQueue, String name) throws Exception
    {
-      server.start(containerConfig);
+      return server.destroyDestination(isQueue, name);
    }
 
-   public void startServerPeer(int serverPeerID, String defaultQueueJNDIContext,
-                               String defaultTopicJNDIContext, boolean clustered) throws Exception
+   public void deployConnectionFactory(String objectName, String[] jndiBindings)
+      throws Exception
    {
-      server.startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, clustered);
+      server.deployConnectionFactory(objectName, jndiBindings);
    }
 
-   public void stop() throws Exception
+   public void deployConnectionFactory(String objectName, String[] jndiBindings, int prefetchSize)
+      throws Exception
    {
-      server.stop();
-      namingDelegate.reset();
+      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize);
    }
 
-   public void stopServerPeer() throws Exception
+   public void deployConnectionFactory(String objectName,
+                                       String[] jndiBindings,
+                                       int prefetchSize,
+                                       int defaultTempQueueFullSize,
+                                       int defaultTempQueuePageSize,
+                                       int defaultTempQueueDownCacheSize) throws Exception
    {
-      server.stopServerPeer();
+      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize,
+               defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
    }
 
-   public void undeploy(ObjectName on) throws Exception
+   public void undeployConnectionFactory(ObjectName objectName) throws Exception
    {
-      server.undeploy(on);
+      server.undeployConnectionFactory(objectName);
    }
 
-   public void undeployDestination(boolean isQueue, String name) throws Exception
+   public void configureSecurityForDestination(String destName, String config) throws Exception
    {
-      server.undeployDestination(isQueue, name);
+      server.configureSecurityForDestination(destName, config);
    }
 
-   public boolean destroyDestination(boolean isQueue, String name) throws Exception
+   public void setDefaultSecurityConfig(String config) throws Exception
    {
-      return server.destroyDestination(isQueue, name);
+      server.setDefaultSecurityConfig(config);
    }
 
-   public Object executeCommand(Command command) throws Exception
+   public String getDefaultSecurityConfig() throws Exception
    {
-      return server.executeCommand(command);
+      return server.getDefaultSecurityConfig();
    }
 
-   public ServerPeer getServerPeer() throws Exception
+   public Object executeCommand(Command command) throws Exception
    {
-      return server.getServerPeer();
+      return server.executeCommand(command);
    }
 
    public UserTransaction getUserTransaction() throws Exception
@@ -370,9 +415,54 @@
       return server.getNodeIDView();
    }
 
+   public List pollNotificationListener(long listenerID) throws Exception
+   {
+      ProxyNotificationListener pl = null;
+
+      synchronized(proxyListeners)
+      {
+         pl = (ProxyNotificationListener)proxyListeners.get(new Long(listenerID));
+      }
+
+      if (pl == null)
+      {
+         return Collections.EMPTY_LIST;
+      }
+
+      return pl.drain();
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
    private RMINamingDelegate getNamingDelegate()
    {
       return namingDelegate;
    }
 
+   // Inner classes -------------------------------------------------
+
+   public class VMKiller implements Runnable
+   {
+      public void run()
+      {
+         log.info("shutting down the VM");
+
+         try
+         {
+            Thread.sleep(250);
+         }
+         catch(Exception e)
+         {
+            log.warn("interrupted while sleeping", e);
+         }
+
+         System.exit(0);
+      }
+   }
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -23,7 +23,9 @@
 
 import java.rmi.Remote;
 import java.util.Set;
+import java.util.List;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
@@ -43,21 +45,36 @@
 public interface Server extends Remote
 {
    void start(String containerConfig) throws Exception;
+
    void stop() throws Exception;
-   void destroy() throws Exception;
 
    /**
+    * For a remote server, it "abruptly" kills the VM running the server. For a local server
+    * it just stops the server.
+    */
+   void kill() throws Exception;
+
+   /**
     * Deploys and registers a service based on the MBean service descriptor element, specified as
     * a String. Supports XMBeans. The implementing class and the ObjectName are inferred from the
     * mbean element. If there are configuration attributed specified in the deployment descriptor,
     * they are applied to the service instance.
     */
    ObjectName deploy(String mbeanConfiguration) throws Exception;
+
    void undeploy(ObjectName on) throws Exception;
+
    Object getAttribute(ObjectName on, String attribute) throws Exception;
+
    void setAttribute(ObjectName on, String name, String valueAsString) throws Exception;
+
    Object invoke(ObjectName on, String operationName, Object[] params, String[] signature)
       throws Exception;
+
+   void addNotificationListener(ObjectName on, NotificationListener listener) throws Exception;
+
+   void removeNotificationListener(ObjectName on, NotificationListener listener) throws Exception;
+
    /**
     * Returns a set of ObjectNames corresponding to installed services.
     */
@@ -218,4 +235,9 @@
     */
    Set getNodeIDView() throws Exception;
 
+   /**
+    * @return List<Notification>
+    */
+   List pollNotificationListener(long listenerID) throws Exception;
+
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-11 15:27:26 UTC (rev 1763)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-11 16:56:06 UTC (rev 1764)
@@ -81,7 +81,7 @@
 
       // We should shut down cleanly - not kill the process like we are currently doing
       
-      server.destroy();
+      server.kill();
 
       // The last RMI server will take with it the registry too
 



From msurtani at jboss.com  Mon Dec 11 12:29:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:29:44 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors     ...
Message-ID: <E1GtoyG-0007jz-7e@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:29:44

  Modified:    src/org/jboss/cache/interceptors     Tag:
                        Branch_JBossCache_1_4_0
                        OptimisticValidatorInterceptor.java
                        OptimisticCreateIfNotExistsInterceptor.java
                        OptimisticNodeInterceptor.java
                        OptimisticReplicationInterceptor.java
  Log:
  Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
  Updated logging libs JBCACHE-901
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.25.2.11 +8 -5      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.25.2.10
  retrieving revision 1.25.2.11
  diff -u -b -r1.25.2.10 -r1.25.2.11
  --- OptimisticValidatorInterceptor.java	11 Dec 2006 14:46:54 -0000	1.25.2.10
  +++ OptimisticValidatorInterceptor.java	11 Dec 2006 17:29:44 -0000	1.25.2.11
  @@ -179,12 +179,13 @@
           for (Iterator it = nodes.iterator(); it.hasNext();)
           {
               WorkspaceNode wrappedNode = (WorkspaceNode) it.next();
  +           if (trace) log.trace("Analysing node " + wrappedNode.getFqn() + " in workspace.");
               // short circuit if this node is deleted?
               if (wrappedNode.isDeleted())
               {
                   // handle notifications
   
  -                if (trace) log.trace("Workspace node " + wrappedNode.getFqn() + " deleted; removing");
  +                if (trace) log.trace("Node's been deleted; removing");
                   DataNode dNode = wrappedNode.getNode();
                   cache.notifyNodeRemove(dNode.getFqn(), true);
   
  @@ -213,11 +214,13 @@
                       // this could be done better to account for more subtle merges
                       current.setChildren(mergedChildren);
   
  -                    if (log.isTraceEnabled()) log.trace("inserting merged data " + wrappedNode.getMergedData());
  +                    if (trace) log.trace("inserting merged data " + wrappedNode.getMergedData());
                       Map mergedData = wrappedNode.getMergedData();
                       current.put(mergedData, true);
  -                    if (workspace.isVersioningImplicit() || wrappedNode.getVersion() instanceof DefaultDataVersion)
  +
  +                    if (wrappedNode.isVersioningImplicit())
                       {
  +                        if (trace) log.trace("Versioning is implicit; incrementing.");
                           current.setVersion(((DefaultDataVersion)wrappedNode.getVersion()).increment());
                       }
                       else
  @@ -225,13 +228,13 @@
                           if (trace) log.trace("Versioning is explicit; not attempting an increment.");
                           current.setVersion(wrappedNode.getVersion());
                       }
  -                    if (trace) log.trace("Setting version of node " + current.getName() + " from " + wrappedNode.getVersion() + " to " + current.getVersion());
  +                    if (trace) log.trace("Setting version of node from " + wrappedNode.getVersion() + " to " + current.getVersion());
                       cache.notifyNodeModified(wrappedNode.getFqn());
                       cache.notifyNodeModify(wrappedNode.getFqn(), false);
                   }
                   else
                   {
  -                    if (trace) log.trace("Merging node " + wrappedNode.getFqn() + " not necessary since the node is not dirty");
  +                    if (trace) log.trace("Merging not necessary since the node is not dirty");
                       cache.notifyNodeVisited(wrappedNode.getFqn());
                   }
               }
  
  
  
  1.21.2.3  +15 -6     JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticCreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java,v
  retrieving revision 1.21.2.2
  retrieving revision 1.21.2.3
  diff -u -b -r1.21.2.2 -r1.21.2.3
  --- OptimisticCreateIfNotExistsInterceptor.java	11 Dec 2006 14:46:54 -0000	1.21.2.2
  +++ OptimisticCreateIfNotExistsInterceptor.java	11 Dec 2006 17:29:44 -0000	1.21.2.3
  @@ -174,14 +174,13 @@
   
                       // get the version passed in, if we need to use explicit versioning.
                       DataVersion versionToPassIn = null;
  -                    if (isTargetFqn && !workspace.isVersioningImplicit())
  -                    {
  -                        versionToPassIn = version;
  -                    }
  +                    if (isTargetFqn && !workspace.isVersioningImplicit()) versionToPassIn = version;
   
                       DataNode tempNode = (DataNode) workspaceNode.createChild(childName, copy, workspaceNode.getNode(), cache, versionToPassIn);
   
                       childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempNode, workspace);
  +                   childWorkspaceNode.setVersioningImplicit(versionToPassIn == null || !isTargetFqn);
  +                   if (log.isTraceEnabled()) log.trace("setting versioning of " + childWorkspaceNode.getFqn() + " to be " + (childWorkspaceNode.isVersioningImplicit() ? "implicit" : "explicit"));
   
                       // now add the wrapped child node into the transaction space
                       workspace.addNode(childWorkspaceNode);
  @@ -200,7 +199,17 @@
                       {
                           if (log.isDebugEnabled()) log.debug("Child node "+tempChildNode.getFqn()+" doesn't exist in workspace or has been deleted.  Adding to workspace in gtx " + gtx);
                           childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempChildNode, workspace);
  -                        if (isTargetFqn && !workspace.isVersioningImplicit()) childWorkspaceNode.setVersion(version);
  +                        if (isTargetFqn && !workspace.isVersioningImplicit())
  +                        {
  +                           childWorkspaceNode.setVersion(version);
  +                           childWorkspaceNode.setVersioningImplicit(false);
  +                        }
  +                       else
  +                        {
  +                           childWorkspaceNode.setVersioningImplicit(true);
  +                        }
  +                       if (log.isTraceEnabled()) log.trace("setting versioning of " + childWorkspaceNode.getFqn() + " to be " + (childWorkspaceNode.isVersioningImplicit() ? "implicit" : "explicit"));
  +                       
                       }
                       else
                       {
  @@ -211,7 +220,7 @@
                   workspaceNode = childWorkspaceNode;
               }
   
  -            if (log.isDebugEnabled()) log.debug("left synchronized nodewrapper access  for gtx " + gtx);
  +            if (log.isTraceEnabled()) log.trace("left synchronized nodewrapper access  for gtx " + gtx);
           } // end sync block
           // run the notify outside the synch block as we do not know what that
           // code might do
  
  
  
  1.21.2.7  +19 -16    JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.21.2.6
  retrieving revision 1.21.2.7
  diff -u -b -r1.21.2.6 -r1.21.2.7
  --- OptimisticNodeInterceptor.java	13 Nov 2006 14:06:23 -0000	1.21.2.6
  +++ OptimisticNodeInterceptor.java	11 Dec 2006 17:29:44 -0000	1.21.2.7
  @@ -66,31 +66,34 @@
               throw new CacheException("Must be in a valid transaction " + m);
            }
   
  -         // assign a global transaction here if we need to - should do all
  -         // this in the transaction interceptor
            WorkspaceNode workspaceNode = getOrCreateWorkspaceNode(getFqn(args), workspace, cache);
   
  +
  +         if (workspaceNode != null)
  +         {
            // use explicit versioning
            if (ctx.getOptionOverrides() != null && ctx.getOptionOverrides().getDataVersion() != null)
            {
               workspace.setVersioningImplicit(false);
               DataVersion version = ctx.getOptionOverrides().getDataVersion();
  -            // "fail-more-silently" patch thanks to Owen Taylor - JBCACHE-767
   
  -            // also, if this is a "remove", do we care if the node didn't exist?
  -
  -            if (workspaceNode != null)
  -            {
                  workspaceNode.setVersion(version);
  +               if (log.isTraceEnabled()) log.trace("Setting versioning for node " + workspaceNode.getFqn() + " to explicit");
  +               workspaceNode.setVersioningImplicit(false);
               }
               else
               {
  +               if (log.isTraceEnabled()) log.trace("Setting versioning for node " + workspaceNode.getFqn() + " to implicit");
  +               workspaceNode.setVersioningImplicit(true);
  +            }
  +         }
  +         else
  +         {
  +            // "fail-more-silently" patch thanks to Owen Taylor - JBCACHE-767
                  if ((ctx.getOptionOverrides() == null || !ctx.getOptionOverrides().isFailSilently()) && MethodDeclarations.isOptimisticPutMethod(meth))
                     throw new CacheException("Unable to set node version for " + getFqn(args) + ", node is null.");
               }
   
  -         }
  -
            switch (m.getMethodId())
            {
               case MethodDeclarations.putDataMethodLocal_id:
  @@ -114,7 +117,7 @@
                  break;
               case MethodDeclarations.dataGravitationCleanupMethod_id:
                  result = super.invoke(m);
  -            default :
  +            default:
                  if (log.isInfoEnabled()) log.info("Cannot Handle Method " + m);
                  break;
            }
  
  
  
  1.21.2.5  +8 -2      JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticReplicationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java,v
  retrieving revision 1.21.2.4
  retrieving revision 1.21.2.5
  diff -u -b -r1.21.2.4 -r1.21.2.5
  --- OptimisticReplicationInterceptor.java	6 Dec 2006 16:00:14 -0000	1.21.2.4
  +++ OptimisticReplicationInterceptor.java	11 Dec 2006 17:29:44 -0000	1.21.2.5
  @@ -243,14 +243,20 @@
      private DataVersion getVersionToBroadcast(TransactionWorkspace w, Fqn f)
      {
         WorkspaceNode n = w.getNode(f);
  -      if (n == null) return null;
  -      if (w.isVersioningImplicit())
  +      if (n == null)
  +      {
  +         if (log.isTraceEnabled()) log.trace("Fqn " + f + " not found in workspace; not using a data version.");
  +         return null;
  +      }
  +      if (n.isVersioningImplicit())
         {
            DefaultDataVersion v = (DefaultDataVersion) n.getVersion();
  +         if (log.isTraceEnabled()) log.trace("Fqn " + f + " has implicit versioning.  Broadcasting an incremented version.");
            return v.increment();
         }
         else
         {
  +         if (log.isTraceEnabled()) log.trace("Fqn " + f + " has explicit versioning.  Broadcasting the version as-is.");
            return n.getVersion();
         }
      }
  
  
  


From msurtani at jboss.com  Mon Dec 11 12:29:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:29:45 -0500
Subject: [jboss-cvs] JBossCache/lib    ...
Message-ID: <E1GtoyH-0007kD-8X@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:29:45

  Modified:    lib      Tag: Branch_JBossCache_1_4_0 commons-logging.jar
                        log4j.jar jgroups.jar
  Log:
  Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
  Updated logging libs JBCACHE-901
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.1.1.24.1 +281 -111  JBossCache/lib/Attic/commons-logging.jar
  
  	<<Binary file>>
  
  
  1.1.1.1.24.1 +1876 -1309JBossCache/lib/Attic/log4j.jar
  
  	<<Binary file>>
  
  
  1.4.2.5   +1387 -1367JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Mon Dec 11 12:29:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:29:45 -0500
Subject: [jboss-cvs] JBossCache/etc  ...
Message-ID: <E1GtoyH-0007kO-DU@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:29:45

  Modified:    etc      Tag: Branch_JBossCache_1_4_0 log4j.xml
  Log:
  Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
  Updated logging libs JBCACHE-901
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.15.2.3  +5 -5      JBossCache/etc/log4j.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: log4j.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/log4j.xml,v
  retrieving revision 1.15.2.2
  retrieving revision 1.15.2.3
  diff -u -b -r1.15.2.2 -r1.15.2.3
  --- log4j.xml	11 Dec 2006 10:10:33 -0000	1.15.2.2
  +++ log4j.xml	11 Dec 2006 17:29:45 -0000	1.15.2.3
  @@ -7,7 +7,7 @@
   <!--                                                                       -->
   <!-- ===================================================================== -->
   
  -<!-- $Id: log4j.xml,v 1.15.2.2 2006/12/11 10:10:33 msurtani Exp $ -->
  +<!-- $Id: log4j.xml,v 1.15.2.3 2006/12/11 17:29:45 msurtani Exp $ -->
   
   <!--
      | For more configuration infromation and examples see the Jakarta Log4j
  @@ -79,11 +79,11 @@
     -->
   
     <category name="org.jboss.cache">
  -    <priority value="INFO" class="org.jboss.logging.XLevel"/>
  +    <priority value="WARN"/>
     </category>
   
       <category name="org.jboss.tm">
  -    <priority value="WARN" class="org.jboss.logging.XLevel"/>
  +    <priority value="WARN"/>
       </category>
   
      <category name="org.jgroups">
  @@ -95,8 +95,8 @@
   <!-- ======================= -->
   
     <root>
  -    <!--<appender-ref ref="CONSOLE"/>-->
  -    <appender-ref ref="FILE"/>
  +    <appender-ref ref="CONSOLE"/>
  +    <!--<appender-ref ref="FILE"/>-->
     </root>
     
   </log4j:configuration>
  
  
  


From msurtani at jboss.com  Mon Dec 11 12:29:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:29:45 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options  ...
Message-ID: <E1GtoyH-0007kZ-Il@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:29:45

  Modified:    tests/functional/org/jboss/cache/options  Tag:
                        Branch_JBossCache_1_4_0
                        ExplicitVersionsReplTest.java
  Log:
  Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
  Updated logging libs JBCACHE-901
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +17 -0     JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- ExplicitVersionsReplTest.java	6 Dec 2006 16:00:14 -0000	1.1.2.2
  +++ ExplicitVersionsReplTest.java	11 Dec 2006 17:29:45 -0000	1.1.2.3
  @@ -301,5 +301,22 @@
         cache[0].getTransactionManager().commit();
      }
   
  +   public void testExplicitVersionOnLeaf() throws Exception
  +   {
  +      cache[0].put("/org/domain/Entity", null);
  +      assertEquals(1, ((DefaultDataVersion)((OptimisticTreeNode)cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(1, ((DefaultDataVersion)((OptimisticTreeNode)cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
   
  +      TestVersion v = new TestVersion("Arse");
  +      Option o = new Option();
  +      o.setDataVersion(v);
  +
  +      cache[0].put(Fqn.fromString("/org/domain/Entity/EntityInstance#1"), "k", "v", o);
  +
  +      assertEquals(2, ((DefaultDataVersion)((OptimisticTreeNode)cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((OptimisticTreeNode)cache[0].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +      assertEquals(2, ((DefaultDataVersion)((OptimisticTreeNode)cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((OptimisticTreeNode)cache[1].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +
  +   }
   }
  
  
  


From msurtani at jboss.com  Mon Dec 11 12:29:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:29:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic    ...
Message-ID: <E1GtoyH-0007kq-P1@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:29:45

  Modified:    src/org/jboss/cache/optimistic    Tag:
                        Branch_JBossCache_1_4_0 DefaultDataVersion.java
                        WorkspaceNodeImpl.java WorkspaceNode.java
  Log:
  Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
  Updated logging libs JBCACHE-901
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.3   +2 -2      JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.3.2.2
  retrieving revision 1.3.2.3
  diff -u -b -r1.3.2.2 -r1.3.2.3
  --- DefaultDataVersion.java	11 Dec 2006 14:46:54 -0000	1.3.2.2
  +++ DefaultDataVersion.java	11 Dec 2006 17:29:45 -0000	1.3.2.3
  @@ -7,9 +7,9 @@
   package org.jboss.cache.optimistic;
   
   import java.io.Externalizable;
  -import java.io.ObjectOutput;
   import java.io.IOException;
   import java.io.ObjectInput;
  +import java.io.ObjectOutput;
   
   /**
    * The default implementation of a DataVersion, uses a <code>long</code> to
  @@ -25,7 +25,7 @@
    */
   public class DefaultDataVersion implements DataVersion, Externalizable
   {
  -
  +    private static final long serialVersionUID = -6896315742831861046L;
       /**
        * Version zero.
        * Assign this as the first version to your data.
  
  
  
  1.21.2.4  +12 -1     JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.21.2.3
  retrieving revision 1.21.2.4
  diff -u -b -r1.21.2.3 -r1.21.2.4
  --- WorkspaceNodeImpl.java	11 Dec 2006 14:46:54 -0000	1.21.2.3
  +++ WorkspaceNodeImpl.java	11 Dec 2006 17:29:45 -0000	1.21.2.4
  @@ -45,6 +45,7 @@
       private boolean created;
       private Map optimisticChildNodeMap;
       private Map optimisticDataMap;
  +   private boolean versioningImplicit;
   
       public WorkspaceNodeImpl() {
           this(new OptimisticTreeNode(), null);
  @@ -218,6 +219,16 @@
   
       }
   
  +   public boolean isVersioningImplicit()
  +   {
  +      return versioningImplicit;
  +   }
  +
  +   public void setVersioningImplicit(boolean b)
  +   {
  +      versioningImplicit = b;
  +   }
  +
       //this needs to be changed to return wrapped node
       public TreeNode getChild(Object childName)
       {
  
  
  
  1.12.2.1  +5 -1      JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java,v
  retrieving revision 1.12
  retrieving revision 1.12.2.1
  diff -u -b -r1.12 -r1.12.2.1
  --- WorkspaceNode.java	31 May 2006 14:08:39 -0000	1.12
  +++ WorkspaceNode.java	11 Dec 2006 17:29:45 -0000	1.12.2.1
  @@ -7,9 +7,9 @@
   package org.jboss.cache.optimistic;
   
   import org.jboss.cache.DataNode;
  -import org.jboss.cache.TreeNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.TreeNode;
   
   import java.util.Map;
   import java.util.Set;
  @@ -50,4 +50,8 @@
       public void markAsCreated();
   
       public TreeNode createChild(Object child_name, Fqn fqn, TreeNode parent, TreeCache cache, DataVersion version);
  +
  +   boolean isVersioningImplicit();
  +
  +   void setVersioningImplicit(boolean b);
   }
  
  
  


From msurtani at jboss.com  Mon Dec 11 12:29:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:29:45 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache  ...
Message-ID: <E1GtoyH-0007l1-Sr@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:29:45

  Modified:    tests/perf/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        ConcurrentEvictAndRemoveTest.java
  Log:
  Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
  Updated logging libs JBCACHE-901
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.4.1   +5 -4      JBossCache/tests/perf/org/jboss/cache/ConcurrentEvictAndRemoveTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentEvictAndRemoveTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ConcurrentEvictAndRemoveTest.java,v
  retrieving revision 1.3
  retrieving revision 1.3.4.1
  diff -u -b -r1.3 -r1.3.4.1
  --- ConcurrentEvictAndRemoveTest.java	5 Dec 2005 03:17:14 -0000	1.3
  +++ ConcurrentEvictAndRemoveTest.java	11 Dec 2006 17:29:45 -0000	1.3.4.1
  @@ -11,16 +11,16 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.eviction.RegionManager;
   
   import java.util.Random;
  +
   /**
    * Local mode test for concurrent EvictionTimerTask evicting nodes and Client removing nodes from TreeCache.
    *
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.3.4.1 $
    * @author <a href="mailto:uwe.lamprecht at gmx.de">Uwe Lamprecht</a> July 29 2004
    */
   public final class ConcurrentEvictAndRemoveTest extends TestCase
  @@ -125,14 +125,15 @@
               log("create put/remove events");
               final int SEQUENCE_SIZE = 10000; // number of nodes processed by a single thread
               final long TIMEOUT_DEFAULT = 100000;
  -            final int MAX_TIMEOUT_FACTOR = 10;
  +            final int MAX_TIMEOUT_FACTOR = 100;
   
               for(int i = 0; i < RegionManager.CAPACITY; i = i + SEQUENCE_SIZE) {
                   final int sequenceStart = i;
                   final int sequenceEnd = i + SEQUENCE_SIZE -1;
   
                   Thread thread = new Thread(
  -                        new HelperThread(cache, sequenceStart, sequenceEnd)
  +                        new HelperThread(cache, sequenceStart, sequenceEnd),
  +                        "HelperThread processing sequence " + sequenceStart
                   );
   
                   long timeout = (HelperThread.getTime()==HelperThread.EXECUTION_TIME_NOT_INITIALIZED)?
  
  
  


From msurtani at jboss.com  Mon Dec 11 12:31:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:31:06 -0500
Subject: [jboss-cvs] JBossCache/lib    ...
Message-ID: <E1Gtoza-0007nk-3Y@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:31:06

  Removed:     lib      Tag: Branch_JBossCache_1_4_0 jrunit.jar
                        jcommon-1.0.0-rc1.jar jfreechart-1.0.0-rc1.jar
  Log:
  removed unnecessary jars


From msurtani at jboss.com  Mon Dec 11 12:35:21 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:35:21 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache/benchmark/support
	...
Message-ID: <E1Gtp3h-0007ur-5P@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:35:21

  Removed:     tests/perf/org/jboss/cache/benchmark/support      Tag:
                        Branch_JBossCache_1_4_0 Read50PercentTest.java
                        Read75PercentTest.java Read90PercentTest.java
                        BaseTest.java TreeCacheConfigurator.java
  Log:
  removed unnecessary files


From msurtani at jboss.com  Mon Dec 11 12:35:21 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:35:21 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache/benchmark/tests ...
Message-ID: <E1Gtp3h-0007uv-8h@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:35:21

  Removed:     tests/perf/org/jboss/cache/benchmark/tests               
                        Tag: Branch_JBossCache_1_4_0
                        ReplAsyncPessRead75JRunitTest.java
                        ReplSyncPessRead90JRunitTest.java
                        LocalPessIsoRRRead50JRunitTest.java
                        HashMapRead50JRunitTest.java
                        LocalPessIsoNoneRead75JRunitTest.java
                        ReplAsyncPessRead50JRunitTest.java
                        LocalPessIsoNoneRead90JRunitTest.java
                        LocalPessIsoRRRead90JRunitTest.java
                        ReplSyncPessRead50JRunitTest.java
                        LocalPessIsoNoneRead50JRunitTest.java
                        ReplSyncPessRead75JRunitTest.java
                        HashMapRead75JRunitTest.java
                        HashMapRead90JRunitTest.java
                        LocalPessIsoRRRead75JRunitTest.java
                        ReplAsyncPessRead90JRunitTest.java
  Log:
  removed unnecessary files


From msurtani at jboss.com  Mon Dec 11 12:39:10 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 12:39:10 -0500
Subject: [jboss-cvs] JBossCache/lib   ...
Message-ID: <E1Gtp7O-0007zd-MF@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 12:39:10

  Added:       lib      log4j-1.2.14.jar
  Removed:     lib      log4j-1.2.13.jar
  Log:
  Updated jars
  
  Revision  Changes    Path
  1.1      date: 2006/12/11 17:39:10;  author: msurtani;  state: Exp;JBossCache/lib/log4j-1.2.14.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Mon Dec 11 13:00:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 11 Dec 2006 13:00:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GtpSK-0008LY-DK@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/11 13:00:48

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  fixed pojocache oddities
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.6  +8 -1      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.5
  retrieving revision 1.20.2.6
  diff -u -b -r1.20.2.5 -r1.20.2.6
  --- PessimisticLockInterceptor.java	10 Dec 2006 17:15:46 -0000	1.20.2.5
  +++ PessimisticLockInterceptor.java	11 Dec 2006 18:00:48 -0000	1.20.2.6
  @@ -36,7 +36,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.5 2006/12/10 17:15:46 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.6 2006/12/11 18:00:48 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -387,6 +387,13 @@
         {
            Object child_name = fqn.get(i);
            DataNode child_node = (DataNode) n.getOrCreateChild(child_name, gtx, true);
  +         // test if this node needs to be 'undeleted'
  +         // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  +         if (gtx != null && needToReverseRemove(child_node, tx_table.get(gtx), DataNode.LOCK_TYPE_WRITE, false, true))
  +         {
  +            reverseRemove(child_node);
  +         }
  +
            if (child_node == null)
            {
               if (log.isTraceEnabled())
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 14:19:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 14:19:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r58976 - in branches/Branch_4_0:
 server/src/main/org/jboss/invocation/pooled/interfaces testsuite/imports
 testsuite/imports/sections testsuite/src/main/org/jboss/test
 testsuite/src/main/org/jboss/test/scoped
 testsuite/src/main/org/jboss/test/scoped/ejb
 testsuite/src/main/org/jboss/test/scoped/ejb/a
 testsuite/src/main/org/jboss/test/scoped/ejb/b
 testsuite/src/main/org/jboss/test/scoped/interfaces
 testsuite/src/main/org/jboss/test/scoped/interfaces/a
 testsuite/src/main/org/jboss/test/scoped/interfaces/b
 testsuite/src/main/org/jboss/test/scoped/interfaces/dto
 testsuite/src/main/org/jboss/test/scoped/test testsuite/src/resources
 testsuite/src/resources/scoped testsuite/src/resources/scoped/a
 testsuite/src/resources/scoped/a/ear
 testsuite/src/resources/scoped/a/ear/META-INF
 testsuite/src/resources/scoped/a/ejb
 testsuite/src/resources/scoped/a/ejb/META-INF
 testsuite/src/resources/scoped/b testsuite/src/resources/scoped/b/ear
 testsuite/src/resources/scoped/b/!
 ear/META-INF testsuite/src/resources/scoped/b/ejb
 testsuite/src/resources/scoped/b/ejb/META-INF
Message-ID: <E1Gtqgr-0001UR-I8@committer01.frg.pub.inap.atl.jboss.com>

Author: tom.elrod at jboss.com
Date: 2006-12-11 14:19:48 -0500 (Mon, 11 Dec 2006)
New Revision: 58976

Added:
   branches/Branch_4_0/testsuite/imports/sections/scoped.xml
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/a/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/a/SessionAEJB.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/b/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/b/SessionBEJB.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionA.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionAHome.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionB.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionBHome.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleRequestDTO.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleResponseDTO.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
   branches/Branch_4_0/testsuite/src/resources/scoped/
   branches/Branch_4_0/testsuite/src/resources/scoped/a/
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/application.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/jboss-app.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/ejb-jar.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/jboss.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/b/
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/application.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/jboss-app.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/ejb-jar.xml
   branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/jboss.xml
Modified:
   branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/OptimizedObjectInputStream.java
   branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/PooledMarshalledInvocation.java
   branches/Branch_4_0/testsuite/imports/test-jars.xml
Log:
JBAS-3198 - fix for pooled invoker scoped deployments class caching.

Modified: branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/OptimizedObjectInputStream.java
===================================================================
--- branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/OptimizedObjectInputStream.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/OptimizedObjectInputStream.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -1,24 +1,24 @@
 /*
- * JBoss, Home of Professional Open Source.
- * Copyright 2006, 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.
- */
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.invocation.pooled.interfaces;
 
 import java.io.IOException;
@@ -28,7 +28,11 @@
 import java.lang.ref.WeakReference;
 import java.lang.reflect.Method;
 import java.lang.reflect.Proxy;
+import java.util.Collections;
+import java.util.Map;
+import java.util.WeakHashMap;
 
+import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
 import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
 
 /**
@@ -44,7 +48,7 @@
         extends ObjectInputStream
 {
    /** A class wide cache of proxy classes populated by resolveProxyClass */
-   private static ConcurrentReaderHashMap classCache;
+   private static Map classCache;
    private static ConcurrentReaderHashMap objectStreamClassCache;
    private static Method lookupStreamClass = null;
 
@@ -71,7 +75,7 @@
    {
       if (flag == true)
       {
-         classCache = new ConcurrentReaderHashMap();
+         classCache = Collections.synchronizedMap(new WeakHashMap());
          objectStreamClassCache = new ConcurrentReaderHashMap();
       }
       else
@@ -93,13 +97,22 @@
    private static Class forName(String className) throws ClassNotFoundException
    {
       Class clazz = null;
+
       if (classCache != null)
       {
-         WeakReference ref = (WeakReference) classCache.get(className);
+
+    	 ConcurrentHashMap subCache = (ConcurrentHashMap )classCache.get(Thread.currentThread().getContextClassLoader());
+    	 if (subCache==null)
+    	 {
+    		 classCache.put(Thread.currentThread().getContextClassLoader(), new ConcurrentHashMap());
+    		 subCache = (ConcurrentHashMap )classCache.get(Thread.currentThread().getContextClassLoader());
+    	 }
+
+         WeakReference ref = (WeakReference) subCache.get(className);
          if (ref != null) clazz = (Class) ref.get();
          if (clazz == null)
          {
-            if (ref != null) classCache.remove(className);
+            if (ref != null) subCache.remove(className);
             ClassLoader loader = Thread.currentThread().getContextClassLoader();
             try
             {
@@ -113,7 +126,7 @@
                */
                clazz = Class.forName(className, false, loader);
             }
-            classCache.put(className, new WeakReference(clazz));
+            subCache.put(className, new WeakReference(clazz));
          }
       }
       else

Modified: branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/PooledMarshalledInvocation.java
===================================================================
--- branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/PooledMarshalledInvocation.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/server/src/main/org/jboss/invocation/pooled/interfaces/PooledMarshalledInvocation.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -44,7 +44,7 @@
  * distribution purposes as well as the "hash" for the methods that we send, as
  * opposed to sending Method objects. Serialization "optimizations" should be
  * coded here in the externalization implementation of the class
- * 
+ *
  * @author <a href="mailto:marc at jboss.org">Marc Fleury</a>
  * @version $Revision$
  */

Added: branches/Branch_4_0/testsuite/imports/sections/scoped.xml
===================================================================
--- branches/Branch_4_0/testsuite/imports/sections/scoped.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/imports/sections/scoped.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,51 @@
+<project name="tests-scoped-jars">
+   <!-- isolation test -->
+   <target name="_jars-scoped">
+      <mkdir dir="${build.lib}"/>
+
+      <!-- build scopedA.jar -->
+      <jar destfile="${build.lib}/scopedA.jar">
+         <fileset dir="${build.classes}">
+            <include name="org/jboss/test/scoped/ejb/a/**"/>
+            <include name="org/jboss/test/scoped/interfaces/**"/>
+            <include name="org/jboss/test/util/Debug.class"/>
+         </fileset>
+         <fileset dir="${build.resources}/scoped/a/ejb">
+            <include name="META-INF/*.xml"/>
+         </fileset>
+      </jar>
+
+      <!-- build scopedB.jar -->
+      <jar destfile="${build.lib}/scopedB.jar">
+         <fileset dir="${build.classes}">
+            <include name="org/jboss/test/scoped/ejb/b/**"/>
+            <include name="org/jboss/test/scoped/interfaces/**"/>
+            <include name="org/jboss/test/util/Debug.class"/>
+         </fileset>
+         <fileset dir="${build.resources}/scoped/b/ejb">
+            <include name="META-INF/*.xml"/>
+         </fileset>
+      </jar>
+
+      <!-- build scopedA.ear -->
+      <jar destfile="${build.lib}/scopedA.ear">
+         <fileset dir="${build.lib}">
+            <include name="scopedA.jar"/>
+         </fileset>
+         <fileset dir="${build.resources}/scoped/a/ear">
+            <include name="META-INF/*.xml"/>
+         </fileset>
+      </jar>
+
+      <!-- build scopedB.ear -->
+      <jar destfile="${build.lib}/scopedB.ear">
+         <fileset dir="${build.lib}">
+            <include name="scopedB.jar"/>
+         </fileset>
+         <fileset dir="${build.resources}/scoped/b/ear">
+            <include name="META-INF/*.xml"/>
+         </fileset>
+      </jar>
+
+   </target>
+</project>

Modified: branches/Branch_4_0/testsuite/imports/test-jars.xml
===================================================================
--- branches/Branch_4_0/testsuite/imports/test-jars.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/imports/test-jars.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -54,6 +54,7 @@
 	<import file="sections/proxycompiler.xml"/>
 	<import file="sections/readahead.xml"/>
 	<import file="sections/retry.xml"/>
+	<import file="sections/scoped.xml"/>
     <import file="sections/security.xml"/>
     <import file="sections/securitymgr.xml"/>
 	<import file="sections/session.xml"/>
@@ -132,6 +133,7 @@
       _jars-proxycompiler,
       _jars-readahead,
       _jars-retry,
+      _jars-scoped,
       _jars-security,
       _jars-securitymgr,
       _jars-session,

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/a/SessionAEJB.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/a/SessionAEJB.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/a/SessionAEJB.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,96 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.ejb.a;
+
+import org.jboss.logging.Logger;
+import org.jboss.test.util.Debug;
+import org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO;
+import org.jboss.test.scoped.interfaces.dto.SimpleRequestDTO;
+
+import javax.ejb.SessionBean;
+import javax.ejb.EJBException;
+import javax.ejb.CreateException;
+import javax.ejb.SessionContext;
+import javax.naming.InitialContext;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
+ */
+public class SessionAEJB implements SessionBean
+{
+   private static final long serialVersionUID = 1L;
+
+   public SessionAEJB()
+   {
+       super();
+   }
+
+
+   public SimpleResponseDTO runSimpleTest(SimpleRequestDTO requestDTO)
+   {
+
+       try
+       {
+          SimpleResponseDTO rsDTO = new SimpleResponseDTO();
+          rsDTO.setFirstName(requestDTO.getFirstName().toUpperCase());
+          rsDTO.setLastName(requestDTO.getLastName().toUpperCase());
+          System.out.println("Got firstname: " + requestDTO.getFirstName());
+          System.out.println("Got lastname:" + requestDTO.getLastName());
+           return rsDTO;
+       }
+       catch (Throwable t)
+       {
+           Logger logger=Logger.getLogger(this.getClass());
+           logger.error(t);
+
+           SimpleResponseDTO rsDTO =  new SimpleResponseDTO();
+
+           return rsDTO;
+       }
+   }
+
+   public String stringTest(String request) throws java.rmi.RemoteException
+   {
+       return request.toUpperCase();
+   }
+
+   public void setSessionContext(SessionContext arg0) throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbCreate() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbRemove() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbActivate() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbPassivate() throws EJBException, RemoteException
+   {
+   }
+ }

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/b/SessionBEJB.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/b/SessionBEJB.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/ejb/b/SessionBEJB.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,93 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.ejb.b;
+
+import org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO;
+import org.jboss.test.scoped.interfaces.dto.SimpleRequestDTO;
+import org.jboss.logging.Logger;
+
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+import javax.ejb.EJBException;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
+ */
+public class SessionBEJB implements SessionBean
+{
+   private static final long serialVersionUID = 2L;
+
+   public SessionBEJB()
+   {
+       super();
+   }
+
+
+   public SimpleResponseDTO runSimpleTest(SimpleRequestDTO requestDTO)
+   {
+
+       try
+       {
+          SimpleResponseDTO rsDTO = new SimpleResponseDTO();
+          rsDTO.setFirstName(requestDTO.getFirstName().toUpperCase());
+          rsDTO.setLastName(requestDTO.getLastName().toUpperCase());
+          System.out.println("Got firstname: " + requestDTO.getFirstName());
+          System.out.println("Got lastname:" + requestDTO.getLastName());
+           return rsDTO;
+       }
+       catch (Throwable t)
+       {
+           Logger logger=Logger.getLogger(this.getClass());
+           logger.error(t);
+
+           SimpleResponseDTO rsDTO =  new SimpleResponseDTO();
+
+           return rsDTO;
+       }
+   }
+
+   public String stringTest(String request) throws java.rmi.RemoteException
+   {
+       return request.toUpperCase();
+   }
+
+   public void setSessionContext(SessionContext arg0) throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbCreate() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbRemove() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbActivate() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbPassivate() throws EJBException, RemoteException
+   {
+   }
+ }

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionA.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionA.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionA.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,36 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.interfaces.a;
+
+import org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO;
+import org.jboss.test.scoped.interfaces.dto.SimpleRequestDTO;
+
+import javax.ejb.EJBObject;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
+ */
+public interface SessionA extends EJBObject
+{
+   public SimpleResponseDTO runSimpleTest(SimpleRequestDTO requestDTO) throws RemoteException;
+}
\ No newline at end of file

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionAHome.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionAHome.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/a/SessionAHome.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,35 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.interfaces.a;
+
+
+import javax.ejb.EJBHome;
+import javax.ejb.CreateException;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
+ */
+public interface SessionAHome extends EJBHome
+{
+   SessionA create() throws CreateException, RemoteException;
+}

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionB.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionB.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionB.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,36 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.interfaces.b;
+
+import org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO;
+import org.jboss.test.scoped.interfaces.dto.SimpleRequestDTO;
+
+import javax.ejb.EJBObject;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
+ */
+public interface SessionB extends EJBObject
+{
+   public SimpleResponseDTO runSimpleTest(SimpleRequestDTO requestDTO) throws RemoteException;
+}
\ No newline at end of file

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionBHome.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionBHome.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/b/SessionBHome.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,36 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.interfaces.b;
+
+import org.jboss.test.scoped.interfaces.a.SessionA;
+
+import javax.ejb.CreateException;
+import javax.ejb.EJBHome;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
+ */
+public interface SessionBHome extends EJBHome
+{
+   SessionB create() throws CreateException, RemoteException;
+}

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleRequestDTO.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleRequestDTO.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleRequestDTO.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,61 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.interfaces.dto;
+
+import java.io.Serializable;
+import java.util.Random;
+
+/**
+ * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
+ */
+public class SimpleRequestDTO implements Serializable
+{
+   private static final long serialVersionUID = 2L;
+
+   private String firstName;
+   private String lastName;
+
+   public SimpleRequestDTO()
+   {
+   }
+
+
+   public String getFirstName()
+   {
+      return firstName;
+   }
+
+   public String getLastName()
+   {
+      return lastName;
+   }
+
+   public void setFirstName(String firstName)
+   {
+      this.firstName = firstName;
+   }
+
+   public void setLastName(String lastName)
+   {
+      this.lastName = lastName;
+   }
+}

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleResponseDTO.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleResponseDTO.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/interfaces/dto/SimpleResponseDTO.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,41 @@
+package org.jboss.test.scoped.interfaces.dto;
+
+import java.io.Serializable;
+import java.util.Random;
+
+public class SimpleResponseDTO implements Serializable
+{
+   private static final long serialVersionUID = 2L;
+//   private static final long serialVersionUID = new Random().nextLong();
+
+   private String firstName;
+   private String lastName;
+
+   public String getFirstName()
+   {
+      return firstName;
+   }
+
+   public String getLastName()
+   {
+      return lastName;
+   }
+
+   public void setFirstName(String firstName)
+   {
+      this.firstName = firstName;
+   }
+
+   public void setLastName(String lastName)
+   {
+      this.lastName = lastName;
+   }
+
+   public SimpleResponseDTO()
+   {
+
+
+   }
+
+
+}
\ No newline at end of file

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,123 @@
+/*
+* JBoss, a division of Red Hat
+* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.scoped.test;
+
+import org.jboss.deployment.EARDeployerMBean;
+import org.jboss.test.JBossTestCase;
+import org.jboss.test.scoped.interfaces.a.SessionA;
+import org.jboss.test.scoped.interfaces.a.SessionAHome;
+import org.jboss.test.scoped.interfaces.dto.SimpleRequestDTO;
+import org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO;
+import org.jboss.test.scoped.interfaces.b.SessionBHome;
+import org.jboss.test.scoped.interfaces.b.SessionB;
+
+import javax.management.Attribute;
+
+/**
+ * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
+ */
+public class ScopedUnitTestCase extends JBossTestCase
+{
+   public ScopedUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testScoped() throws Exception
+   {
+      isolateDeployments(Boolean.TRUE);
+      try
+      {
+         deploy("scopedA.ear");
+         try
+         {
+            // Run the test
+            deploy("scopedB.ear");
+            try
+            {
+               doTest();
+            }
+            finally
+            {
+               undeploy("scopedB.ear");
+            }
+
+            // Run the test after a redeployment
+//            deploy("scopedB.ear");
+//            try
+//            {
+//               doTest();
+//            }
+//            finally
+//            {
+//               undeploy("scopedB.ear");
+//            }
+         }
+         finally
+         {
+            undeploy("scopedA.ear");
+         }
+      }
+      finally
+      {
+         isolateDeployments(Boolean.FALSE);
+      }
+   }
+
+   private void doTest() throws Exception
+   {
+//      Properties env = new Properties();
+//      env.put("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
+//      //env.put("java.naming.provider.url", "localhost:1099");
+//      env.put("java.naming.provider.url", "localhost:1100");
+//      env.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
+//
+//      Context ic = new InitialContext(env);
+
+      SessionAHome home = (SessionAHome) getInitialContext().lookup("SessionA");
+      SessionA session = home.create();
+
+
+         SimpleRequestDTO requestDTO = new SimpleRequestDTO();
+         requestDTO.setFirstName("Daffy");
+         requestDTO.setLastName("Duck");
+         SimpleResponseDTO result = session.runSimpleTest(requestDTO);
+
+         System.out.println(result.getFirstName() + " " + result.getLastName());
+
+      SessionBHome homeB = (SessionBHome)getInitialContext().lookup("SessionB");
+      SessionB sessionB = homeB.create();
+
+      result = sessionB.runSimpleTest(requestDTO);
+
+      System.out.println(result.getFirstName() + " " + result.getLastName());
+
+
+
+   }
+
+   private void isolateDeployments(Boolean value) throws Exception
+   {
+      //getServer().setAttribute(EARDeployerMBean.OBJECT_NAME, new Attribute("Isolated", value));
+      getServer().setAttribute(EARDeployerMBean.OBJECT_NAME, new Attribute("CallByValue", value));
+   }
+}

Added: branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/application.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/application.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/application.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
+<application>
+    <display-name>scopedA</display-name>
+	<module>
+		<ejb>scopedA.jar</ejb>
+	</module>
+</application>
+

Added: branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/jboss-app.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/jboss-app.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/a/ear/META-INF/jboss-app.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,5 @@
+<jboss-app>
+   <loader-repository>jboss.test:loader=sessionA.ear
+      <loader-repository-config>java2ParentDelegation=false</loader-repository-config>
+   </loader-repository>
+</jboss-app>
\ No newline at end of file

Added: branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/ejb-jar.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/ejb-jar.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/ejb-jar.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE ejb-jar PUBLIC
+   "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
+   "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
+
+<ejb-jar>
+   <enterprise-beans>
+      <session>
+         <ejb-name>SessionA</ejb-name>
+         <home>org.jboss.test.scoped.interfaces.a.SessionAHome</home>
+         <remote>org.jboss.test.scoped.interfaces.a.SessionA</remote>
+         <ejb-class>org.jboss.test.scoped.ejb.a.SessionAEJB</ejb-class>
+         <session-type>Stateless</session-type>
+         <transaction-type>Container</transaction-type>
+      </session>
+   </enterprise-beans>
+</ejb-jar>

Added: branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/jboss.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/jboss.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/a/ejb/META-INF/jboss.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<jboss>
+   <enterprise-beans>
+      <session>
+         <ejb-name>SessionA</ejb-name>
+         <configuration-name>Pooled Stateless SessionBean</configuration-name>
+         <invoker-bindings>
+            <invoker>
+               <invoker-proxy-binding-name>stateless-pooled-invoker</invoker-proxy-binding-name>
+               <jndi-name>SessionA</jndi-name>
+            </invoker>
+         </invoker-bindings>
+      </session>
+   </enterprise-beans>
+
+   <invoker-proxy-bindings>
+      <!--<invoker-proxy-binding>-->
+         <!--<name>stateless-pooled-invoker</name>-->
+         <!--<invoker-mbean>jboss:service=invoker,type=pooled</invoker-mbean>-->
+         <!--<proxy-factory>org.jboss.proxy.ejb.ProxyFactory</proxy-factory>-->
+         <!--<proxy-factory-config>-->
+            <!--<client-interceptors>-->
+               <!--<home>-->
+                  <!--<interceptor>org.jboss.proxy.ejb.HomeInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>-->
+               <!--</home>-->
+               <!--<bean>-->
+                  <!--<interceptor>org.jboss.proxy.ejb.StatelessSessionInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>-->
+               <!--</bean>-->
+            <!--</client-interceptors>-->
+         <!--</proxy-factory-config>-->
+      <!--</invoker-proxy-binding>-->
+
+      <invoker-proxy-binding>
+        <name>stateless-pooled-invoker</name>
+        <invoker-mbean>jboss:service=invoker,type=pooled</invoker-mbean>
+        <proxy-factory>org.jboss.proxy.ejb.ProxyFactory</proxy-factory>
+        <proxy-factory-config>
+          <client-interceptors>
+            <home>
+              <interceptor>org.jboss.proxy.ejb.HomeInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>
+               <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
+              <!--<interceptor call-by-value="false">org.jboss.invocation.InvokerInterceptor</interceptor>-->
+              <!--<interceptor call-by-value="true">org.jboss.invocation.MarshallingInvokerInterceptor</interceptor>-->
+            </home>
+            <bean>
+              <interceptor>org.jboss.proxy.ejb.StatelessSessionInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>
+               <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
+              <!--<interceptor call-by-value="false">org.jboss.invocation.InvokerInterceptor</interceptor>-->
+              <!--<interceptor call-by-value="true">org.jboss.invocation.MarshallingInvokerInterceptor</interceptor>-->
+            </bean>
+          </client-interceptors>
+        </proxy-factory-config>
+      </invoker-proxy-binding>
+
+   </invoker-proxy-bindings>
+
+   <container-configurations>
+     <container-configuration extends="Standard Stateless SessionBean">
+        <container-name>Pooled Stateless SessionBean</container-name>
+        <invoker-proxy-binding-name>stateless-pooled-invoker</invoker-proxy-binding-name>
+     </container-configuration>
+   </container-configurations>
+
+
+</jboss>

Added: branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/application.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/application.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/application.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="ISO-8859-1"?>
+
+<application>
+    <display-name>scopedB</display-name>
+	<module>
+		<ejb>scopedB.jar</ejb>
+	</module>
+</application>
+

Added: branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/jboss-app.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/jboss-app.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/b/ear/META-INF/jboss-app.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,5 @@
+<jboss-app>
+   <loader-repository>jboss.test:loader=sessionB.ear
+      <loader-repository-config>java2ParentDelegation=false</loader-repository-config>
+   </loader-repository>
+</jboss-app>
\ No newline at end of file

Added: branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/ejb-jar.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/ejb-jar.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/ejb-jar.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE ejb-jar PUBLIC
+   "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
+   "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
+
+<ejb-jar>
+   <enterprise-beans>
+      <session>
+         <ejb-name>SessionB</ejb-name>
+         <home>org.jboss.test.scoped.interfaces.b.SessionBHome</home>
+         <remote>org.jboss.test.scoped.interfaces.b.SessionB</remote>
+         <ejb-class>org.jboss.test.scoped.ejb.b.SessionBEJB</ejb-class>
+         <session-type>Stateless</session-type>
+         <transaction-type>Container</transaction-type>
+      </session>
+   </enterprise-beans>
+</ejb-jar>

Added: branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/jboss.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/jboss.xml	2006-12-11 16:10:29 UTC (rev 58975)
+++ branches/Branch_4_0/testsuite/src/resources/scoped/b/ejb/META-INF/jboss.xml	2006-12-11 19:19:48 UTC (rev 58976)
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<jboss>
+   <enterprise-beans>
+      <session>
+         <ejb-name>SessionB</ejb-name>
+         <configuration-name>Pooled Stateless SessionBean</configuration-name>
+         <invoker-bindings>
+            <invoker>
+               <invoker-proxy-binding-name>stateless-pooled-invoker</invoker-proxy-binding-name>
+               <jndi-name>SessionB</jndi-name>
+            </invoker>
+         </invoker-bindings>
+      </session>
+   </enterprise-beans>
+
+   <invoker-proxy-bindings>
+      <!--<invoker-proxy-binding>-->
+         <!--<name>stateless-pooled-invoker</name>-->
+         <!--<invoker-mbean>jboss:service=invoker,type=pooled</invoker-mbean>-->
+         <!--<proxy-factory>org.jboss.proxy.ejb.ProxyFactory</proxy-factory>-->
+         <!--<proxy-factory-config>-->
+            <!--<client-interceptors>-->
+               <!--<home>-->
+                  <!--<interceptor>org.jboss.proxy.ejb.HomeInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>-->
+               <!--</home>-->
+               <!--<bean>-->
+                  <!--<interceptor>org.jboss.proxy.ejb.StatelessSessionInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>-->
+                  <!--<interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>-->
+               <!--</bean>-->
+            <!--</client-interceptors>-->
+         <!--</proxy-factory-config>-->
+      <!--</invoker-proxy-binding>-->
+
+      <invoker-proxy-binding>
+        <name>stateless-pooled-invoker</name>
+        <invoker-mbean>jboss:service=invoker,type=pooled</invoker-mbean>
+        <proxy-factory>org.jboss.proxy.ejb.ProxyFactory</proxy-factory>
+        <proxy-factory-config>
+          <client-interceptors>
+            <home>
+              <interceptor>org.jboss.proxy.ejb.HomeInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>
+               <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
+              <!--<interceptor call-by-value="false">org.jboss.invocation.InvokerInterceptor</interceptor>-->
+              <!--<interceptor call-by-value="true">org.jboss.invocation.MarshallingInvokerInterceptor</interceptor>-->
+            </home>
+            <bean>
+              <interceptor>org.jboss.proxy.ejb.StatelessSessionInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.SecurityInterceptor</interceptor>
+              <interceptor>org.jboss.proxy.TransactionInterceptor</interceptor>
+               <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
+              <!--<interceptor call-by-value="false">org.jboss.invocation.InvokerInterceptor</interceptor>-->
+              <!--<interceptor call-by-value="true">org.jboss.invocation.MarshallingInvokerInterceptor</interceptor>-->
+            </bean>
+          </client-interceptors>
+        </proxy-factory-config>
+      </invoker-proxy-binding>
+
+   </invoker-proxy-bindings>
+
+   <container-configurations>
+     <container-configuration extends="Standard Stateless SessionBean">
+        <container-name>Pooled Stateless SessionBean</container-name>
+        <invoker-proxy-binding-name>stateless-pooled-invoker</invoker-proxy-binding-name>
+     </container-configuration>
+   </container-configurations>
+
+
+</jboss>



From dimitris.andreadis at jboss.com  Mon Dec 11 14:20:49 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 11 Dec 2006 14:20:49 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-Branch_AOP_1_5 ...
Message-ID: <E1Gtqhl-0001Wb-7S@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/11 14:20:49

  Modified:    jboss/aop/snapshot-Branch_AOP_1_5  component-info.xml
  Log:
  Mark JBossAOP 1.5.x compatible with javassist 3.4
  
  Revision  Changes    Path
  1.3       +1 -0      repository.jboss.com/jboss/aop/snapshot-Branch_AOP_1_5/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/aop/snapshot-Branch_AOP_1_5/component-info.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- component-info.xml	30 Oct 2006 11:11:54 -0000	1.2
  +++ component-info.xml	11 Dec 2006 19:20:49 -0000	1.3
  @@ -18,6 +18,7 @@
            <compatible version="3.2.0.CR2"/>
            <compatible version="3.2.0.GA"/>
            <compatible version="3.3.0.GA"/>
  +         <compatible version="3.4.GA"/>
         </import>
         <export>
            <include input="jboss-aop.jar"/>
  
  
  


From dimitris.andreadis at jboss.com  Mon Dec 11 15:00:02 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 11 Dec 2006 15:00:02 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/1.0.4.GA  ...
Message-ID: <E1GtrJi-00029r-OG@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/11 15:00:02

  Modified:    jboss/jbossws/1.0.4.GA  component-info.xml
  Log:
  Mark compatible with javassist 3.4.GA
  
  Revision  Changes    Path
  1.2       +1 -0      repository.jboss.com/jboss/jbossws/1.0.4.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/1.0.4.GA/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	15 Nov 2006 00:58:00 -0000	1.1
  +++ component-info.xml	11 Dec 2006 20:00:02 -0000	1.2
  @@ -16,6 +16,7 @@
         </import>
         <import componentref="javassist">
         	<compatible version="3.3.0.GA"/>
  +      	<compatible version="3.4.GA"/>
         </import>
         <import componentref="ibm-wsdl4j">
         	<compatible version="1.5.2jboss"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 15:13:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 15:13:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r58977 -
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1GtrWP-0002Yi-Ii@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-11 15:13:05 -0500 (Mon, 11 Dec 2006)
New Revision: 58977

Removed:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
JBMICROCONT-26; initial code commit, missing build and tests

Deleted: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-11 19:19:48 UTC (rev 58976)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-11 20:13:05 UTC (rev 58977)
@@ -1,56 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
-
-import javax.xml.namespace.QName;
-import java.util.ArrayList;
-import java.util.List;
-
-import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
-import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
-import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
-import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- */
-public class SpringBeansInterceptor extends DefaultElementInterceptor
-{
-   /**
-    * The interceptor
-    */
-   public static final SpringBeansInterceptor INTERCEPTOR = new SpringBeansInterceptor();
-
-   public void add(Object parent, Object child, QName name)
-   {
-      AbstractKernelDeployment deployment = (AbstractKernelDeployment) parent;
-      AbstractBeanMetaData bean = (AbstractBeanMetaData) child;
-      List<BeanMetaDataFactory> beans = deployment.getBeanFactories();
-      if (beans == null)
-      {
-         beans = new ArrayList<BeanMetaDataFactory>();
-         deployment.setBeanFactories(beans);
-      }
-      beans.add(bean);
-   }
-
-}

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-11 19:19:48 UTC (rev 58976)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-11 20:13:05 UTC (rev 58977)
@@ -34,7 +34,7 @@
    {
       typeBinding.setHandler(SpringBeansHandler.HANDLER);
       // handle beans
-      typeBinding.pushInterceptor(SpringSchemaBinding.beansQName, SpringBeansInterceptor.INTERCEPTOR);
+      typeBinding.pushInterceptor(SpringSchemaBinding.beansQName, DeploymentBeanInterceptor.INTERCEPTOR);
       // todo alias
       // todo import
    }



From dimitris.andreadis at jboss.com  Mon Dec 11 15:25:53 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 11 Dec 2006 15:25:53 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws14/1.0.4.GA  ...
Message-ID: <E1Gtrij-0002kI-53@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/11 15:25:53

  Modified:    jboss/jbossws14/1.0.4.GA  component-info.xml
  Log:
  Mark compatible with javassist 3.4.GA
  
  Revision  Changes    Path
  1.2       +1 -0      repository.jboss.com/jboss/jbossws14/1.0.4.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws14/1.0.4.GA/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	15 Nov 2006 00:58:00 -0000	1.1
  +++ component-info.xml	11 Dec 2006 20:25:53 -0000	1.2
  @@ -16,6 +16,7 @@
         </import>
         <import componentref="javassist">
         	<compatible version="3.3.0.GA"/>
  +      	<compatible version="3.4.GA"/>
         </import>
         <import componentref="ibm-wsdl4j">
         	<compatible version="1.5.2jboss"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 15:35:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 15:35:00 -0500
Subject: [jboss-cvs] JBossAS SVN: r58978 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1GtrrY-0002sm-At@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-11 15:34:58 -0500 (Mon, 11 Dec 2006)
New Revision: 58978

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
Log:
- Session config was already parsed.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-11 20:13:05 UTC (rev 58977)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-11 20:34:58 UTC (rev 58978)
@@ -41,6 +41,7 @@
 import org.jboss.metadata.web.ParamValue;
 import org.jboss.metadata.web.Servlet;
 import org.jboss.metadata.web.ServletMapping;
+import org.jboss.metadata.web.SessionConfig;
 
 public class JBossContextConfig extends ContextConfig {
 
@@ -245,8 +246,13 @@
       }
 
       // Session timeout
-      if (metaData.getSessionTimeout() > 0) {
-         context.setSessionTimeout(metaData.getSessionTimeout());
+      Iterator iterator14 = metaData.getSessionConfigs().iterator();
+      if (iterator14.hasNext()) {
+         SessionConfig value = (SessionConfig) iterator14.next();
+         if (value.getSessionTimeout() != null) {
+            int i = Integer.decode(value.getSessionTimeout());
+            context.setSessionTimeout(i);
+         }
       }
         
 	}



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 15:35:59 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 15:35:59 -0500
Subject: [jboss-cvs] JBossAS SVN: r58979 -
	trunk/server/src/main/org/jboss/metadata
Message-ID: <E1GtrsV-0002v9-Sr@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-11 15:35:58 -0500 (Mon, 11 Dec 2006)
New Revision: 58979

Modified:
   trunk/server/src/main/org/jboss/metadata/WebMetaData.java
Log:
- Remove useless field.

Modified: trunk/server/src/main/org/jboss/metadata/WebMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-11 20:34:58 UTC (rev 58978)
+++ trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-11 20:35:58 UTC (rev 58979)
@@ -168,8 +168,6 @@
    private List<String> welcomeFiles = new ArrayList<String>();
    /** web-app/web-app/jsp-config/jsp-property-group/url-pattern */
    private List<String> jspMappings = new ArrayList<String>();
-   /** web-app/session-config/session-timeout */
-   private int sessionTimeout = -1;
    /** web-app/taglib */
    private List<Taglib> taglibs = new ArrayList<Taglib>();
 
@@ -424,16 +422,6 @@
       jspMappings.add(jspMapping);
    }
 
-   public int getSessionTimeout()
-   {
-      return sessionTimeout;
-   }
-
-   public void setSessionTimeout(int sessionTimeout)
-   {
-      this.sessionTimeout = sessionTimeout;
-   }
-
    public Collection<Taglib> getTaglibs()
    {
       return taglibs;



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 15:51:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 15:51:08 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1765 - in
 branches/Branch_Client_Failover_Experiment: . docs/examples/http/etc
 docs/examples/queue docs/examples/secure-socket/etc src/etc
 src/etc/server/default/deploy src/etc/xmdesc src/main/org/jboss/jms/client
 src/main/org/jboss/jms/client/container
 src/main/org/jboss/jms/client/delegate
 src/main/org/jboss/jms/client/remoting src/main/org/jboss/jms/client/state
 src/main/org/jboss/jms/delegate src/main/org/jboss/jms/message
 src/main/org/jboss/jms/server
 src/main/org/jboss/jms/server/connectionfactory
 src/main/org/jboss/jms/server/container
 src/main/org/jboss/jms/server/destination
 src/main/org/jboss/jms/server/endpoint
 src/main/org/jboss/jms/server/endpoint/advised
 src/main/org/jboss/jms/server/remoting src/main/org/jboss/jms/tx
 src/main/org/jboss/jms/util src/main/org/jboss/messaging/core
 src/main/org/jboss/messaging/core/message
 src/main/org/jboss/messaging/core/plugin
 src/main/org/jboss/messaging/core/plugin/contract src/main/org/jboss/m!
 essaging/core/tx tests tests/bin tests/etc tests/smoke
 tests/src/org/jboss/test/messaging/core/plugin
 tests/src/org/jboss/test/messaging/core/plugin/base
 tests/src/org/jboss/test/messaging/jms
 tests/src/org/jboss/test/messaging/jms/message
 tests/src/org/jboss/test/messaging/tools/jmx
 tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1Gts7A-0003BW-7C@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-11 15:50:25 -0500 (Mon, 11 Dec 2006)
New Revision: 1765

Added:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/ClientSocketWrapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/ServerSocketWrapper.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConsumerClosedTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/DLQTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java
Removed:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackServerFactory.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/DummyCallbackHandler.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectInputStream.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectOutputStream.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingSerializationManager.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/CallbackServerFactoryTest.java
Modified:
   branches/Branch_Client_Failover_Experiment/
   branches/Branch_Client_Failover_Experiment/build-messaging.xml
   branches/Branch_Client_Failover_Experiment/build-thirdparty.xml
   branches/Branch_Client_Failover_Experiment/docs/examples/http/etc/messaging-http-service.xml
   branches/Branch_Client_Failover_Experiment/docs/examples/queue/do-not-distribute.properties
   branches/Branch_Client_Failover_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml
   branches/Branch_Client_Failover_Experiment/messaging.iml
   branches/Branch_Client_Failover_Experiment/messaging.ipr
   branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/jms-ds.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mssql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/remoting-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml
   branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml
   branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/Topic-xmbean.xml
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossSession.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/AsfAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/SessionAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/TransactionAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConsumerState.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/delegate/SessionDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/JBossMessage.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/MessageProxy.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/XMLUtil.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Routable.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/message/RoutableSupport.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/SimpleMessageReference.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example
   branches/Branch_Client_Failover_Experiment/tests/bin/runtest
   branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
   branches/Branch_Client_Failover_Experiment/tests/smoke/build.xml
   branches/Branch_Client_Failover_Experiment/tests/smoke/smoke.properties.example
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/MessageStoreTestBase.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionFactoryTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/SessionTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/TransactedSessionTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/message/JMSXDeliveryCountTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
merging the trunk into this branch, preparing for reverse merge (svn merge -r1540:HEAD https://svn.jboss.org/repos/messaging/trunk)


Property changes on: branches/Branch_Client_Failover_Experiment
___________________________________________________________________
Name: svn:ignore
   - output
thirdparty
messaging.iws
messaging-Branch_Client_Failover_Experiment.ipr
messaging-Branch_Client_Failover_Experiment.iws
messaging-Branch_Client_Failover_Experiment.iml

   + output
thirdparty
messaging.iws



Modified: branches/Branch_Client_Failover_Experiment/build-messaging.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/build-messaging.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/build-messaging.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -50,7 +50,7 @@
    <property name="messaging.version.revision" value="0"/>
    <property name="messaging.version.incrementing" value="8"/>
    <property name="messaging.version.tag" value="Beta1"/>
-   <property name="messaging.version.name" value=""/>
+   <property name="messaging.version.name" value="Berlin"/>
    <property name="messaging.version.cvstag" value="JBossMessaging_1_2_0_Beta1"/>
    <property name="module.name" value="messaging"/>
    <property name="module.Name" value="JBoss Messaging"/>
@@ -459,6 +459,9 @@
       <copy todir="${build.scoped-sar}" file="${jboss.aop.lib}/jboss-aop.jar"/>
       <copy todir="${build.scoped-sar}" file="${javassist.javassist.lib}/javassist.jar"/>
       <copy todir="${build.scoped-sar}" file="${trove.trove.lib}/trove.jar"/>
+      <copy todir="${build.scoped-sar}" file="${apache.tomcat.lib}/tomcat-coyote.jar"/>
+      <copy todir="${build.scoped-sar}" file="${apache.tomcat.lib}/tomcat-http.jar"/>
+      <copy todir="${build.scoped-sar}" file="${apache.tomcat.lib}/tomcat-util.jar"/>
 
       <mkdir dir="${build.scoped-sar}/tmp"/>
 
@@ -580,6 +583,10 @@
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.naming.lib}/jnp-client.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${oswego.concurrent.lib}/concurrent.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${apache.log4j.lib}/log4j.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${apache.logging.lib}/commons-logging.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${apache.tomcat.lib}/tomcat-coyote.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${apache.tomcat.lib}/tomcat-http.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${apache.tomcat.lib}/tomcat-util.jar"/>
       <jar jarfile="${build.lib}/jboss-messaging-client.jar">
          <fileset dir="${build.classes}">
             <include name="org/jboss/**"/>

Modified: branches/Branch_Client_Failover_Experiment/build-thirdparty.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/build-thirdparty.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/build-thirdparty.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -92,7 +92,7 @@
       <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
       <componentref name="jboss/aop" version="1.5.0.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
-      <componentref name="jboss/remoting" version="2.2.0.Alpha2"/>
+      <componentref name="jboss/remoting" version="2.2.0.Alpha4"/>
 
       <!-- Need this otherwise project doesn't build in Eclipse -->
       <componentref name="apache-logging" version="1.0.4.1jboss"/>
@@ -107,7 +107,6 @@
       <componentref name="jboss/profiler/jvmti" version="1.0.0.CR5"/>
       <componentref name="jboss/jbossxb" version="1.0.0.CR6"/>
 
-
    </build>
 
    <synchronizeinfo/>

Modified: branches/Branch_Client_Failover_Experiment/docs/examples/http/etc/messaging-http-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/docs/examples/http/etc/messaging-http-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/docs/examples/http/etc/messaging-http-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -16,30 +16,34 @@
         This Connector will basically run as a standalone http server
    -->
    <mbean code="org.jboss.remoting.transport.Connector"
-      name="jboss.messaging:service=Connector,transport=HTTP"
-      display-name="Messaging HTTP transport Connector">
-
-      <!--
-           Since there are no special configuration properties for this invoker, will just use
-           the following to declare the invoker and not within the 'invoker' element within the
-           'Configuration' attribute below. IMPORTANT to note can only be either 'InvokerLocator'
-           attribute OR 'invoker' element, not both.
-      -->
-      <attribute name="InvokerLocator">http://${jboss.bind.address}:7488</attribute>
+          name="jboss.messaging:service=Connector,transport=http"
+          display-name="HTTP transport Connector">
       <attribute name="Configuration">
          <config>
+            <invoker transport="http">
+               <attribute name="marshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
+               <attribute name="unmarshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
+               <attribute name="serializationtype" isParam="true">jms</attribute>
+               <attribute name="dataType" isParam="true">jms</attribute>
+               <attribute name="serverBindAddress">${jboss.bind.address}</attribute>
+               <attribute name="serverBindPort">4458</attribute>
+               <attribute name="leasePeriod">20000</attribute>
+               <attribute name="callbackStore">org.jboss.remoting.callback.CallbackStore</attribute>
+               <attribute name="callbackPollPeriod" isParam="true">100</attribute>
+            </invoker>
             <handlers>
                <handler subsystem="JMS">org.jboss.jms.server.remoting.JMSServerInvocationHandler</handler>
             </handlers>
          </config>
       </attribute>
+      <depends>jboss.messaging:service=NetworkRegistry</depends>
    </mbean>
-
+   
    <mbean code="org.jboss.jms.server.connectionfactory.ConnectionFactory"
       name="jboss.messaging.destination:service=SecureConnectionFactory"
       xmbean-dd="xmdesc/ConnectionFactory-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends optional-attribute-name="Connector">jboss.messaging:service=Connector,transport=HTTP</depends>
+      <depends optional-attribute-name="Connector">jboss.messaging:service=Connector,transport=http</depends>
       <attribute name="JNDIBindings">
          <bindings>
             <binding>/HttpConnectionFactory</binding>

Modified: branches/Branch_Client_Failover_Experiment/docs/examples/queue/do-not-distribute.properties
===================================================================
--- branches/Branch_Client_Failover_Experiment/docs/examples/queue/do-not-distribute.properties	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/docs/examples/queue/do-not-distribute.properties	2006-12-11 20:50:25 UTC (rev 1765)
@@ -4,4 +4,4 @@
 #
 messaging.client.jar.path=../../../output/lib
 messaging.client.jar.name=jboss-messaging-client.jar
-jboss.configuration=current-version-server
+jboss.configuration=messaging

Modified: branches/Branch_Client_Failover_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -29,6 +29,8 @@
                <attribute name="serverBindPort">5457</attribute>
                <attribute name="leasePeriod">20000</attribute>
                <attribute name="serverSocketFactory">jboss.messaging:service=ServerSocketFactory,type=SSL</attribute>
+               <attribute name="clientSocketClass" isParam="true">org.jboss.jms.client.remoting.ClientSocketWrapper</attribute>
+               <attribute name="serverSocketClass">org.jboss.jms.server.remoting.ServerSocketWrapper</attribute>
             </invoker>
             <handlers>
                <handler subsystem="JMS">org.jboss.jms.server.remoting.JMSServerInvocationHandler</handler>

Modified: branches/Branch_Client_Failover_Experiment/messaging.iml
===================================================================
--- branches/Branch_Client_Failover_Experiment/messaging.iml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/messaging.iml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,739 +1,739 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<module version="4" relativePaths="true" type="JAVA_MODULE">
-  <component name="ModuleRootManager" />
-  <component name="NewModuleRootManager" inherit-compiler-output="false">
-    <output url="file://$MODULE_DIR$/classes" />
-    <exclude-output />
-    <content url="file://$MODULE_DIR$">
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/common/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/distributed-topic/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/http/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/mdb/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/queue/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/secure-socket/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/stateless/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/topic/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/output/gen-parsers" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/perf/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/perf/tests" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/src/main" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/src/test" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/tests/src" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/output/classes" />
-      <excludeFolder url="file://$MODULE_DIR$/output/etc" />
-      <excludeFolder url="file://$MODULE_DIR$/output/jar" />
-      <excludeFolder url="file://$MODULE_DIR$/output/lib" />
-      <excludeFolder url="file://$MODULE_DIR$/output/scoped-sar" />
-    </content>
-    <orderEntry type="inheritedJdk" />
-    <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jbosssx.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-transaction.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-system.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-j2se.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-jmx.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jnp-client.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-j2ee.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jgroups/lib/jgroups.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/javassist/lib/javassist.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/retrotranslator/lib/retrotranslator-transformer.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/pluggable-instrumentor.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/serialization/lib/jboss-serialization.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/remoting/lib/jboss-remoting.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/apache-xerces/lib/xercesImpl.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop-jdk50-client.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/apache-logging/lib/commons-logging.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/dom4j/lib/dom4j.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-archive-browsing.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/apache-xerces/lib/resolver.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/apache-log4j/lib/snmpTrapAppender.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/apache-xerces/lib/xml-apis.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/namespace.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/sun-javacc/lib/javacc.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/retrotranslator/lib/backport-util-concurrent.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/common-softvaluehashmap.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aspect-jdk50-client.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/junit/lib/junit.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-common-client.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/apache-log4j/lib/log4j.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/trove/lib/trove.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jdk14-pluggable-instrumentor.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/retrotranslator/lib/retrotranslator-runtime.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jrockit-pluggable-instrumentor.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/oswego-concurrent/lib/concurrent.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/hsqldb/lib/hsqldb.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-common.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop-jdk50.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-jca.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-common-jdbc-wrapper.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jms-ra.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-mbeans.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/mysql-connector-java-3.1.13-bin.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-local-jdbc.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-junit.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jai.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-starteam.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/xml-apis.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-commons-logging.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jmf.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-antlr.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jsch.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-trax.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-netrexx.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-vaj.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-commons-net.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-weblogic.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-regexp.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-bsf.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/junit.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-swing.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-nodeps.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-stylebook.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-oro.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-xalan1.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-icontract.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-javamail.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jdepend.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-log4j.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-bcel.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-xslp.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-launcher.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/xercesImpl.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-resolver.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntryProperties />
-  </component>
-  <component name="VcsManagerConfiguration">
-    <option name="ACTIVE_VCS_NAME" value="svn" />
-    <option name="USE_PROJECT_VCS" value="false" />
-  </component>
-</module>
-
+<?xml version="1.0" encoding="UTF-8"?>
+<module version="4" relativePaths="true" type="JAVA_MODULE">
+  <component name="ModuleRootManager" />
+  <component name="NewModuleRootManager" inherit-compiler-output="false">
+    <output url="file://$MODULE_DIR$/classes" />
+    <exclude-output />
+    <content url="file://$MODULE_DIR$">
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/common/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/distributed-topic/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/http/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/mdb/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/queue/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/secure-socket/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/stateless/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/topic/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/output/gen-parsers" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/perf/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/perf/tests" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/src/main" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/src/test" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/tests/src" isTestSource="false" />
+      <excludeFolder url="file://$MODULE_DIR$/output/classes" />
+      <excludeFolder url="file://$MODULE_DIR$/output/etc" />
+      <excludeFolder url="file://$MODULE_DIR$/output/jar" />
+      <excludeFolder url="file://$MODULE_DIR$/output/lib" />
+      <excludeFolder url="file://$MODULE_DIR$/output/scoped-sar" />
+    </content>
+    <orderEntry type="inheritedJdk" />
+    <orderEntry type="sourceFolder" forTests="false" />
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jbosssx.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jboss-transaction.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jboss-system.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jboss.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jboss-j2se.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jboss-jmx.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jnp-client.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/lib/jboss-j2ee.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jgroups/lib/jgroups.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/javassist/lib/javassist.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/retrotranslator/lib/retrotranslator-transformer.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/pluggable-instrumentor.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/serialization/lib/jboss-serialization.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/remoting/lib/jboss-remoting.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/apache-xerces/lib/xercesImpl.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop-jdk50-client.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/apache-logging/lib/commons-logging.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/dom4j/lib/dom4j.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-archive-browsing.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/apache-xerces/lib/resolver.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/apache-log4j/lib/snmpTrapAppender.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/apache-xerces/lib/xml-apis.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/namespace.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/sun-javacc/lib/javacc.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/retrotranslator/lib/backport-util-concurrent.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/common-softvaluehashmap.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aspect-jdk50-client.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/junit/lib/junit.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-common-client.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/apache-log4j/lib/log4j.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/trove/lib/trove.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jdk14-pluggable-instrumentor.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/retrotranslator/lib/retrotranslator-runtime.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jrockit-pluggable-instrumentor.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/oswego-concurrent/lib/concurrent.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/hsqldb/lib/hsqldb.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-common.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop-jdk50.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/tests/lib/jboss-jca.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/tests/lib/jboss-common-jdbc-wrapper.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/tests/lib/jms-ra.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/tests/lib/jboss-mbeans.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/tests/lib/mysql-connector-java-3.1.13-bin.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/tests/lib/jboss-local-jdbc.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-junit.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jai.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-starteam.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/xml-apis.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-commons-logging.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jmf.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-antlr.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jsch.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-trax.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-netrexx.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-vaj.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-commons-net.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-weblogic.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-regexp.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-bsf.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/junit.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-swing.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-nodeps.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-stylebook.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-oro.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-xalan1.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-icontract.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-javamail.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-jdepend.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-log4j.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-bcel.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-xslp.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-launcher.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/xercesImpl.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntry type="module-library">
+      <library>
+        <CLASSES>
+          <root url="jar://$MODULE_DIR$/../../apache-ant-1.6.5/lib/ant-apache-resolver.jar!/" />
+        </CLASSES>
+        <JAVADOC />
+        <SOURCES />
+      </library>
+    </orderEntry>
+    <orderEntryProperties />
+  </component>
+  <component name="VcsManagerConfiguration">
+    <option name="ACTIVE_VCS_NAME" value="svn" />
+    <option name="USE_PROJECT_VCS" value="false" />
+  </component>
+</module>
+

Modified: branches/Branch_Client_Failover_Experiment/messaging.ipr
===================================================================
--- branches/Branch_Client_Failover_Experiment/messaging.ipr	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/messaging.ipr	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,293 +1,293 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project version="4" relativePaths="true">
-  <component name="AntConfiguration">
-    <defaultAnt bundledAnt="true" />
-    <buildFile url="file://$PROJECT_DIR$/tests/build.xml">
-      <additionalClassPath>
-        <entry path="file://$PROJECT_DIR$/thirdparty/junit/lib/junit.jar" />
-      </additionalClassPath>
-      <antReference projectDefault="true" />
-      <customJdkName value="" />
-      <maximumHeapSize value="128" />
-      <properties />
-    </buildFile>
-  </component>
-  <component name="BuildJarProjectSettings">
-    <option name="BUILD_JARS_ON_MAKE" value="false" />
-  </component>
-  <component name="CodeStyleProjectProfileManger">
-    <option name="PROJECT_PROFILE" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-  </component>
-  <component name="CodeStyleSettingsManager">
-    <option name="PER_PROJECT_SETTINGS" />
-    <option name="USE_PER_PROJECT_SETTINGS" value="false" />
-  </component>
-  <component name="CompilerConfiguration">
-    <option name="DEFAULT_COMPILER" value="Javac" />
-    <option name="DEPLOY_AFTER_MAKE" value="0" />
-    <resourceExtensions>
-      <entry name=".+\.(properties|xml|html|dtd|tld)" />
-      <entry name=".+\.(gif|png|jpeg|jpg)" />
-    </resourceExtensions>
-    <wildcardResourcePatterns>
-      <entry name="?*.properties" />
-      <entry name="?*.xml" />
-      <entry name="?*.gif" />
-      <entry name="?*.png" />
-      <entry name="?*.jpeg" />
-      <entry name="?*.jpg" />
-      <entry name="?*.html" />
-      <entry name="?*.dtd" />
-      <entry name="?*.tld" />
-    </wildcardResourcePatterns>
-  </component>
-  <component name="DataSourceManagerImpl" />
-  <component name="DependenciesAnalyzeManager">
-    <option name="myForwardDirection" value="false" />
-  </component>
-  <component name="DependencyValidationManager" />
-  <component name="EclipseCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EclipseEmbeddedCompilerSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="true" />
-    <option name="DEPRECATION" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="EntryPointsManager">
-    <entry_points />
-  </component>
-  <component name="ExportToHTMLSettings">
-    <option name="PRINT_LINE_NUMBERS" value="false" />
-    <option name="OPEN_IN_BROWSER" value="false" />
-    <option name="OUTPUT_DIRECTORY" />
-  </component>
-  <component name="GUI Designer component loader factory" />
-  <component name="IdProvider" IDEtalkID="598BFEB0C246A693943DB46D674F660C" />
-  <component name="InspectionProjectProfileManager">
-    <option name="PROJECT_PROFILE" value="Project Default" />
-    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
-    <scopes />
-    <profiles>
-      <profile version="1.0" is_locked="false">
-        <option name="myName" value="Project Default" />
-        <option name="myLocal" value="false" />
-        <used_levels>
-          <error>
-            <option name="myName" value="ERROR" />
-            <option name="myVal" value="400" />
-          </error>
-          <warning>
-            <option name="myName" value="WARNING" />
-            <option name="myVal" value="300" />
-          </warning>
-          <information>
-            <option name="myName" value="INFO" />
-            <option name="myVal" value="200" />
-          </information>
-          <server>
-            <option name="myName" value="SERVER PROBLEM" />
-            <option name="myVal" value="100" />
-          </server>
-        </used_levels>
-      </profile>
-    </profiles>
-  </component>
-  <component name="JavacSettings">
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="DEPRECATION" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-    <option name="MAXIMUM_HEAP_SIZE" value="128" />
-  </component>
-  <component name="JavadocGenerationManager">
-    <option name="OUTPUT_DIRECTORY" />
-    <option name="OPTION_SCOPE" value="protected" />
-    <option name="OPTION_HIERARCHY" value="true" />
-    <option name="OPTION_NAVIGATOR" value="true" />
-    <option name="OPTION_INDEX" value="true" />
-    <option name="OPTION_SEPARATE_INDEX" value="true" />
-    <option name="OPTION_DOCUMENT_TAG_USE" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_AUTHOR" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_VERSION" value="false" />
-    <option name="OPTION_DOCUMENT_TAG_DEPRECATED" value="true" />
-    <option name="OPTION_DEPRECATED_LIST" value="true" />
-    <option name="OTHER_OPTIONS" value="" />
-    <option name="HEAP_SIZE" />
-    <option name="LOCALE" />
-    <option name="OPEN_IN_BROWSER" value="true" />
-  </component>
-  <component name="JikesSettings">
-    <option name="JIKES_PATH" value="" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="DEPRECATION" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="IS_EMACS_ERRORS_MODE" value="true" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="LogConsolePreferences">
-    <option name="FILTER_ERRORS" value="false" />
-    <option name="FILTER_WARNINGS" value="false" />
-    <option name="FILTER_INFO" value="true" />
-    <option name="CUSTOM_FILTER" />
-  </component>
-  <component name="Palette2">
-    <group name="Swing">
-      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
-      </item>
-      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
-        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
-        <initial-values>
-          <property name="text" value="Button" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="RadioButton" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="CheckBox" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
-        <initial-values>
-          <property name="text" value="Label" />
-        </initial-values>
-      </item>
-      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
-          <preferred-size width="150" height="-1" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
-          <preferred-size width="150" height="50" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
-          <preferred-size width="200" height="200" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
-      </item>
-      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
-      </item>
-      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
-          <preferred-size width="-1" height="20" />
-        </default-constraints>
-      </item>
-      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
-        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
-      </item>
-      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
-        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
-      </item>
-    </group>
-  </component>
-  <component name="ProjectModuleManager">
-    <modules>
-      <module fileurl="file://$PROJECT_DIR$/messaging.iml" filepath="$PROJECT_DIR$/messaging.iml" />
-    </modules>
-  </component>
-  <component name="ProjectRootManager" version="2" assert-keyword="true" jdk-15="true" project-jdk-name="1.5" />
-  <component name="ProjectRunConfigurationManager" />
-  <component name="RmicSettings">
-    <option name="IS_EANABLED" value="false" />
-    <option name="DEBUGGING_INFO" value="true" />
-    <option name="GENERATE_NO_WARNINGS" value="false" />
-    <option name="GENERATE_IIOP_STUBS" value="false" />
-    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
-  </component>
-  <component name="StarteamVcsAdapter" />
-  <component name="VssVcs" />
-  <component name="com.intellij.jsf.UserDefinedFacesConfigs">
-    <option name="USER_DEFINED_CONFIGS">
-      <value>
-        <list size="0" />
-      </value>
-    </option>
-  </component>
-  <component name="libraryTable" />
-  <component name="uidesigner-configuration">
-    <option name="INSTRUMENT_CLASSES" value="true" />
-    <option name="COPY_FORMS_RUNTIME_TO_OUTPUT" value="true" />
-    <option name="DEFAULT_LAYOUT_MANAGER" value="GridLayoutManager" />
-  </component>
-  <UsedPathMacros />
-</project>
-
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4" relativePaths="true">
+  <component name="AntConfiguration">
+    <defaultAnt bundledAnt="true" />
+    <buildFile url="file://$PROJECT_DIR$/tests/build.xml">
+      <additionalClassPath>
+        <entry path="file://$PROJECT_DIR$/thirdparty/junit/lib/junit.jar" />
+      </additionalClassPath>
+      <antReference projectDefault="true" />
+      <customJdkName value="" />
+      <maximumHeapSize value="128" />
+      <properties />
+    </buildFile>
+  </component>
+  <component name="BuildJarProjectSettings">
+    <option name="BUILD_JARS_ON_MAKE" value="false" />
+  </component>
+  <component name="CodeStyleProjectProfileManger">
+    <option name="PROJECT_PROFILE" />
+    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
+  </component>
+  <component name="CodeStyleSettingsManager">
+    <option name="PER_PROJECT_SETTINGS" />
+    <option name="USE_PER_PROJECT_SETTINGS" value="false" />
+  </component>
+  <component name="CompilerConfiguration">
+    <option name="DEFAULT_COMPILER" value="Javac" />
+    <option name="DEPLOY_AFTER_MAKE" value="0" />
+    <resourceExtensions>
+      <entry name=".+\.(properties|xml|html|dtd|tld)" />
+      <entry name=".+\.(gif|png|jpeg|jpg)" />
+    </resourceExtensions>
+    <wildcardResourcePatterns>
+      <entry name="?*.properties" />
+      <entry name="?*.xml" />
+      <entry name="?*.gif" />
+      <entry name="?*.png" />
+      <entry name="?*.jpeg" />
+      <entry name="?*.jpg" />
+      <entry name="?*.html" />
+      <entry name="?*.dtd" />
+      <entry name="?*.tld" />
+    </wildcardResourcePatterns>
+  </component>
+  <component name="DataSourceManagerImpl" />
+  <component name="DependenciesAnalyzeManager">
+    <option name="myForwardDirection" value="false" />
+  </component>
+  <component name="DependencyValidationManager" />
+  <component name="EclipseCompilerSettings">
+    <option name="DEBUGGING_INFO" value="true" />
+    <option name="GENERATE_NO_WARNINGS" value="true" />
+    <option name="DEPRECATION" value="false" />
+    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
+    <option name="MAXIMUM_HEAP_SIZE" value="128" />
+  </component>
+  <component name="EclipseEmbeddedCompilerSettings">
+    <option name="DEBUGGING_INFO" value="true" />
+    <option name="GENERATE_NO_WARNINGS" value="true" />
+    <option name="DEPRECATION" value="false" />
+    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
+    <option name="MAXIMUM_HEAP_SIZE" value="128" />
+  </component>
+  <component name="EntryPointsManager">
+    <entry_points />
+  </component>
+  <component name="ExportToHTMLSettings">
+    <option name="PRINT_LINE_NUMBERS" value="false" />
+    <option name="OPEN_IN_BROWSER" value="false" />
+    <option name="OUTPUT_DIRECTORY" />
+  </component>
+  <component name="GUI Designer component loader factory" />
+  <component name="IdProvider" IDEtalkID="598BFEB0C246A693943DB46D674F660C" />
+  <component name="InspectionProjectProfileManager">
+    <option name="PROJECT_PROFILE" value="Project Default" />
+    <option name="USE_PROJECT_LEVEL_SETTINGS" value="false" />
+    <scopes />
+    <profiles>
+      <profile version="1.0" is_locked="false">
+        <option name="myName" value="Project Default" />
+        <option name="myLocal" value="false" />
+        <used_levels>
+          <error>
+            <option name="myName" value="ERROR" />
+            <option name="myVal" value="400" />
+          </error>
+          <warning>
+            <option name="myName" value="WARNING" />
+            <option name="myVal" value="300" />
+          </warning>
+          <information>
+            <option name="myName" value="INFO" />
+            <option name="myVal" value="200" />
+          </information>
+          <server>
+            <option name="myName" value="SERVER PROBLEM" />
+            <option name="myVal" value="100" />
+          </server>
+        </used_levels>
+      </profile>
+    </profiles>
+  </component>
+  <component name="JavacSettings">
+    <option name="DEBUGGING_INFO" value="true" />
+    <option name="GENERATE_NO_WARNINGS" value="false" />
+    <option name="DEPRECATION" value="true" />
+    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
+    <option name="MAXIMUM_HEAP_SIZE" value="128" />
+  </component>
+  <component name="JavadocGenerationManager">
+    <option name="OUTPUT_DIRECTORY" />
+    <option name="OPTION_SCOPE" value="protected" />
+    <option name="OPTION_HIERARCHY" value="true" />
+    <option name="OPTION_NAVIGATOR" value="true" />
+    <option name="OPTION_INDEX" value="true" />
+    <option name="OPTION_SEPARATE_INDEX" value="true" />
+    <option name="OPTION_DOCUMENT_TAG_USE" value="false" />
+    <option name="OPTION_DOCUMENT_TAG_AUTHOR" value="false" />
+    <option name="OPTION_DOCUMENT_TAG_VERSION" value="false" />
+    <option name="OPTION_DOCUMENT_TAG_DEPRECATED" value="true" />
+    <option name="OPTION_DEPRECATED_LIST" value="true" />
+    <option name="OTHER_OPTIONS" value="" />
+    <option name="HEAP_SIZE" />
+    <option name="LOCALE" />
+    <option name="OPEN_IN_BROWSER" value="true" />
+  </component>
+  <component name="JikesSettings">
+    <option name="JIKES_PATH" value="" />
+    <option name="DEBUGGING_INFO" value="true" />
+    <option name="DEPRECATION" value="true" />
+    <option name="GENERATE_NO_WARNINGS" value="false" />
+    <option name="IS_EMACS_ERRORS_MODE" value="true" />
+    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
+  </component>
+  <component name="LogConsolePreferences">
+    <option name="FILTER_ERRORS" value="false" />
+    <option name="FILTER_WARNINGS" value="false" />
+    <option name="FILTER_INFO" value="true" />
+    <option name="CUSTOM_FILTER" />
+  </component>
+  <component name="Palette2">
+    <group name="Swing">
+      <item class="com.intellij.uiDesigner.HSpacer" tooltip-text="Horizontal Spacer" icon="/com/intellij/uiDesigner/icons/hspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="1" hsize-policy="6" anchor="0" fill="1" />
+      </item>
+      <item class="com.intellij.uiDesigner.VSpacer" tooltip-text="Vertical Spacer" icon="/com/intellij/uiDesigner/icons/vspacer.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="6" hsize-policy="1" anchor="0" fill="2" />
+      </item>
+      <item class="javax.swing.JPanel" icon="/com/intellij/uiDesigner/icons/panel.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3" />
+      </item>
+      <item class="javax.swing.JScrollPane" icon="/com/intellij/uiDesigner/icons/scrollPane.png" removable="false" auto-create-binding="false" can-attach-label="true">
+        <default-constraints vsize-policy="7" hsize-policy="7" anchor="0" fill="3" />
+      </item>
+      <item class="javax.swing.JButton" icon="/com/intellij/uiDesigner/icons/button.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="0" fill="1" />
+        <initial-values>
+          <property name="text" value="Button" />
+        </initial-values>
+      </item>
+      <item class="javax.swing.JRadioButton" icon="/com/intellij/uiDesigner/icons/radioButton.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
+        <initial-values>
+          <property name="text" value="RadioButton" />
+        </initial-values>
+      </item>
+      <item class="javax.swing.JCheckBox" icon="/com/intellij/uiDesigner/icons/checkBox.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="3" anchor="8" fill="0" />
+        <initial-values>
+          <property name="text" value="CheckBox" />
+        </initial-values>
+      </item>
+      <item class="javax.swing.JLabel" icon="/com/intellij/uiDesigner/icons/label.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="0" anchor="8" fill="0" />
+        <initial-values>
+          <property name="text" value="Label" />
+        </initial-values>
+      </item>
+      <item class="javax.swing.JTextField" icon="/com/intellij/uiDesigner/icons/textField.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
+          <preferred-size width="150" height="-1" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JPasswordField" icon="/com/intellij/uiDesigner/icons/passwordField.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
+          <preferred-size width="150" height="-1" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JFormattedTextField" icon="/com/intellij/uiDesigner/icons/formattedTextField.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1">
+          <preferred-size width="150" height="-1" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JTextArea" icon="/com/intellij/uiDesigner/icons/textArea.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
+          <preferred-size width="150" height="50" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JTextPane" icon="/com/intellij/uiDesigner/icons/textPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
+          <preferred-size width="150" height="50" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JEditorPane" icon="/com/intellij/uiDesigner/icons/editorPane.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
+          <preferred-size width="150" height="50" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JComboBox" icon="/com/intellij/uiDesigner/icons/comboBox.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="0" hsize-policy="2" anchor="8" fill="1" />
+      </item>
+      <item class="javax.swing.JTable" icon="/com/intellij/uiDesigner/icons/table.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
+          <preferred-size width="150" height="50" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JList" icon="/com/intellij/uiDesigner/icons/list.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="6" hsize-policy="2" anchor="0" fill="3">
+          <preferred-size width="150" height="50" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JTree" icon="/com/intellij/uiDesigner/icons/tree.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3">
+          <preferred-size width="150" height="50" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JTabbedPane" icon="/com/intellij/uiDesigner/icons/tabbedPane.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
+          <preferred-size width="200" height="200" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JSplitPane" icon="/com/intellij/uiDesigner/icons/splitPane.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="3" hsize-policy="3" anchor="0" fill="3">
+          <preferred-size width="200" height="200" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JSpinner" icon="/com/intellij/uiDesigner/icons/spinner.png" removable="false" auto-create-binding="true" can-attach-label="true">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
+      </item>
+      <item class="javax.swing.JSlider" icon="/com/intellij/uiDesigner/icons/slider.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="8" fill="1" />
+      </item>
+      <item class="javax.swing.JSeparator" icon="/com/intellij/uiDesigner/icons/separator.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="6" hsize-policy="6" anchor="0" fill="3" />
+      </item>
+      <item class="javax.swing.JProgressBar" icon="/com/intellij/uiDesigner/icons/progressbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1" />
+      </item>
+      <item class="javax.swing.JToolBar" icon="/com/intellij/uiDesigner/icons/toolbar.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="6" anchor="0" fill="1">
+          <preferred-size width="-1" height="20" />
+        </default-constraints>
+      </item>
+      <item class="javax.swing.JToolBar$Separator" icon="/com/intellij/uiDesigner/icons/toolbarSeparator.png" removable="false" auto-create-binding="false" can-attach-label="false">
+        <default-constraints vsize-policy="0" hsize-policy="0" anchor="0" fill="1" />
+      </item>
+      <item class="javax.swing.JScrollBar" icon="/com/intellij/uiDesigner/icons/scrollbar.png" removable="false" auto-create-binding="true" can-attach-label="false">
+        <default-constraints vsize-policy="6" hsize-policy="0" anchor="0" fill="2" />
+      </item>
+    </group>
+  </component>
+  <component name="ProjectModuleManager">
+    <modules>
+      <module fileurl="file://$PROJECT_DIR$/messaging.iml" filepath="$PROJECT_DIR$/messaging.iml" />
+    </modules>
+  </component>
+  <component name="ProjectRootManager" version="2" assert-keyword="true" jdk-15="true" project-jdk-name="1.5" />
+  <component name="ProjectRunConfigurationManager" />
+  <component name="RmicSettings">
+    <option name="IS_EANABLED" value="false" />
+    <option name="DEBUGGING_INFO" value="true" />
+    <option name="GENERATE_NO_WARNINGS" value="false" />
+    <option name="GENERATE_IIOP_STUBS" value="false" />
+    <option name="ADDITIONAL_OPTIONS_STRING" value="" />
+  </component>
+  <component name="StarteamVcsAdapter" />
+  <component name="VssVcs" />
+  <component name="com.intellij.jsf.UserDefinedFacesConfigs">
+    <option name="USER_DEFINED_CONFIGS">
+      <value>
+        <list size="0" />
+      </value>
+    </option>
+  </component>
+  <component name="libraryTable" />
+  <component name="uidesigner-configuration">
+    <option name="INSTRUMENT_CLASSES" value="true" />
+    <option name="COPY_FORMS_RUNTIME_TO_OUTPUT" value="true" />
+    <option name="DEFAULT_LAYOUT_MANAGER" value="GridLayoutManager" />
+  </component>
+  <UsedPathMacros />
+</project>
+

Modified: branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/aop-messaging-client.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -122,7 +122,7 @@
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->preDeliver(..))">
       <advice name="handlePreDeliver" aspect="org.jboss.jms.client.container.SessionAspect"/>
    </bind>
-   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->postDeliver())">
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->postDeliver(..))">
       <advice name="handlePostDeliver" aspect="org.jboss.jms.client.container.SessionAspect"/>
    </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->acknowledgeAll(..))">

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/jms-ds.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/jms-ds.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/jms-ds.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -8,7 +8,7 @@
 
   <!-- The JMS provider loader -->
    <mbean code="org.jboss.jms.jndi.JMSProviderLoader"
-          name="jboss.mq:service=JMSProviderLoader,name=JMSProvider">
+          name="jboss.messaging:service=JMSProviderLoader,name=JMSProvider">
       <attribute name="ProviderName">DefaultJMSProvider</attribute>
       <attribute name="ProviderAdapterClass">org.jboss.jms.jndi.JNDIProviderAdapter</attribute>
       <attribute name="FactoryRef">java:/XAConnectionFactory</attribute>

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/messaging-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -33,6 +33,8 @@
             <role name="guest" read="true" write="true" create="true"/>
         </security>
       </attribute>
+      <attribute name="MaxDeliveryAttempts">10</attribute>
+      <attribute name="DLQName">DLQ</attribute>
    </mbean>
 
 </server>
\ No newline at end of file

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mssql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mssql-persistence-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/mssql-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -38,6 +38,7 @@
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?
 SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
+UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY TINYINT, COREHEADERS IMAGE, PAYLOAD IMAGE, CHANNELCOUNT INTEGER, TYPE TINYINT, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES IMAGE, DESTINATION_ID BIGINT, REPLYTO_ID BIGINT, JMSPROPERTIES IMAGE, PRIMARY KEY (MESSAGEID))
 LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES FROM JMS_MESSAGE
 INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -38,6 +38,7 @@
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?   
 SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'             
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
+UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID INTEGER, RELIABLE CHAR(1), EXPIRATION INTEGER, TIMESTAMP INTEGER, PRIORITY INTEGER, COREHEADERS BLOB, PAYLOAD BLOB, CHANNELCOUNT INTEGER, TYPE INTEGER, JMSTYPE VARCHAR2(255), CORRELATIONID VARCHAR2(255), CORRELATIONID_BYTES RAW(254), DESTINATION_ID INTEGER, REPLYTO_ID INTEGER, JMSPROPERTIES BLOB, PRIMARY KEY (MESSAGEID))
 LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES FROM JMS_MESSAGE
 INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -38,6 +38,7 @@
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?
 SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
+UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY int2, COREHEADERS BYTEA, PAYLOAD BYTEA, CHANNELCOUNT INTEGER, TYPE int2, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES BYTEA, DESTINATION_ID BIGINT, REPLYTO_ID BIGINT, JMSPROPERTIES BYTEA, PRIMARY KEY (MESSAGEID))
 LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES FROM JMS_MESSAGE
 INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/remoting-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/remoting-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/remoting-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -24,6 +24,9 @@
                <attribute name="serverBindAddress">${jboss.bind.address}</attribute>
                <attribute name="serverBindPort">4457</attribute>
                <attribute name="leasePeriod">20000</attribute>
+               <attribute name="callbackStore">org.jboss.remoting.callback.CallbackStore</attribute>
+               <attribute name="clientSocketClass" isParam="true">org.jboss.jms.client.remoting.ClientSocketWrapper</attribute>
+               <attribute name="serverSocketClass">org.jboss.jms.server.remoting.ServerSocketWrapper</attribute>
             </invoker>
             <handlers>
                <handler subsystem="JMS">org.jboss.jms.server.remoting.JMSServerInvocationHandler</handler>
@@ -33,6 +36,37 @@
       <depends>jboss.messaging:service=NetworkRegistry</depends>
    </mbean>
 
+   <!--
+        HTTP Connector example
+   -->
+   <!--
+   <mbean code="org.jboss.remoting.transport.Connector"
+          name="jboss.messaging:service=Connector,transport=http"
+          display-name="HTTP transport Connector">
+      <attribute name="Configuration">
+         <config>
+            <invoker transport="http">
+               <attribute name="marshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
+               <attribute name="unmarshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
+               <!== Serialization type must be jms - do not change! ==>
+               <attribute name="serializationtype" isParam="true">jms</attribute>
+               <attribute name="dataType" isParam="true">jms</attribute>
+               <attribute name="serverBindAddress">${jboss.bind.address}</attribute>
+               <attribute name="serverBindPort">4458</attribute>
+               <attribute name="leasePeriod">20000</attribute>
+               <attribute name="callbackStore">org.jboss.remoting.callback.CallbackStore</attribute>
+               <attribute name="callbackPollPeriod" isParam="true">100</attribute>
+            </invoker>
+            <handlers>
+               <handler subsystem="JMS">org.jboss.jms.server.remoting.JMSServerInvocationHandler</handler>
+            </handlers>
+         </config>
+      </attribute>
+      <depends>jboss.messaging:service=NetworkRegistry</depends>
+   </mbean>
+   -->
+
+
    <!-- TODO: Do I need this> -->
    <mbean code="org.jboss.remoting.network.NetworkRegistry"
           name="jboss.messaging:service=NetworkRegistry"/>

Modified: branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -47,6 +47,7 @@
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?
 SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
+UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID INTEGER, RELIABLE CHAR(1) NULL, EXPIRATION INTEGER NULL, TIMESTAMP NUMERIC(20,0) NULL, PRIORITY INTEGER NULL, COREHEADERS IMAGE NULL, PAYLOAD IMAGE NULL, CHANNELCOUNT INTEGER NULL, TYPE INTEGER NULL, JMSTYPE VARCHAR(255) NULL, CORRELATIONID VARCHAR(255) NULL, CORRELATIONID_BYTES VARBINARY(254) NULL, DESTINATION_ID INTEGER NULL, REPLYTO_ID INTEGER NULL, JMSPROPERTIES IMAGE NULL, PRIMARY KEY (MESSAGEID))
 LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES FROM JMS_MESSAGE
 INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)

Modified: branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -139,6 +139,18 @@
       <name>QueuedExecutorPoolSize</name>
       <type>int</type>
    </attribute>
+   
+   <attribute access="read-write" getMethod="getMaxDeliveryAttempts" setMethod="setMaxDeliveryAttempts">
+      <description>The maximum delivery attempts for destinations</description>
+      <name>MaxDeliveryAttempts</name>
+      <type>int</type>
+   </attribute>  
+   
+   <attribute access="read-write" getMethod="getDLQName" setMethod="setDLQName">
+      <description>The JNDI name of the DLQ</description>
+      <name>DLQName</name>
+      <type>java.lang.String</type>
+   </attribute>     
 
    <!-- Managed operations -->
 

Modified: branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/Topic-xmbean.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/Topic-xmbean.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/etc/xmdesc/Topic-xmbean.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -87,7 +87,7 @@
       <name>DownCacheSize</name>
       <type>int</type>
    </attribute>
-   
+
    <attribute access="read-write" getMethod="isClustered" setMethod="setClustered">
       <description>Is this a clustered destination?</description>
       <name>Clustered</name>

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -102,6 +102,8 @@
    
    protected Object closeLock = new Object();      
    
+   protected int maxDeliveries;
+   
    // Static --------------------------------------------------------
    
    // Constructors --------------------------------------------------
@@ -151,6 +153,8 @@
       ConsumerState state = (ConsumerState)((DelegateSupport)cons).getState();
 
       this.consumerID = state.getConsumerID();      
+      
+      this.maxDeliveries = state.getMaxDeliveries();
 
       id = threadId.increment();
       internalThread = new Thread(this, "Connection Consumer for dest " + destination + " id=" + id);
@@ -298,7 +302,7 @@
                for (int i = 0; i < mesList.size(); i++)
                {
                   MessageProxy m = (MessageProxy)mesList.get(i);
-                  session.addAsfMessage(m, consumerID, cons);
+                  session.addAsfMessage(m, consumerID, cons, maxDeliveries);
                   if (trace) { log.trace("added " + m + " to session"); }
                }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossSession.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossSession.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/JBossSession.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -502,9 +502,9 @@
     * This method is used by the JBossConnectionConsumer to load up the session
     * with messages to be processed by the session's run() method
     */
-   void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons)
+   void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons, int maxDeliveries)
    {
-      delegate.addAsfMessage(m, consumerID, cons);
+      delegate.addAsfMessage(m, consumerID, cons, maxDeliveries);
    }
       
    // Protected -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/AsfAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/AsfAspect.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/AsfAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -130,6 +130,7 @@
       MessageProxy m = (MessageProxy)mi.getArguments()[0];
       int theConsumerID = ((Integer)mi.getArguments()[1]).intValue();
       ConsumerDelegate cons = (ConsumerDelegate)mi.getArguments()[2];
+      int maxDeliveries = ((Integer)mi.getArguments()[3]).intValue();
       
       if (m == null)
       {
@@ -140,6 +141,7 @@
       holder.msg = m;
       holder.consumerID = theConsumerID;
       holder.consumerDelegate = cons;
+      holder.maxDeliveries = maxDeliveries;
       
       msgs.add(holder);
 
@@ -163,7 +165,7 @@
          if (trace) { log.trace("sending " + holder.msg + " to the message listener" ); }
          
          MessageCallbackHandler.callOnMessage(del, sessionListener, holder.consumerID, false,
-                                              holder.msg, ackMode);                          
+                                              holder.msg, ackMode, holder.maxDeliveries);                          
       }
       
       return null;
@@ -187,5 +189,6 @@
       MessageProxy msg;
       int consumerID;
       ConsumerDelegate consumerDelegate;
+      int maxDeliveries;
    }
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -76,11 +76,12 @@
       int consumerID = consumerState.getConsumerID();
       int prefetchSize = consumerState.getPrefetchSize();
       QueuedExecutor sessionExecutor = sessionState.getExecutor();
+      int maxDeliveries = consumerState.getMaxDeliveries();
       
       MessageCallbackHandler messageHandler =
          new MessageCallbackHandler(isCC, sessionState.getAcknowledgeMode(),
                                     sessionDelegate, consumerDelegate, consumerID,
-                                    prefetchSize, sessionExecutor);
+                                    prefetchSize, sessionExecutor, maxDeliveries);
       
       sessionState.addCallbackHandler(messageHandler);
       

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -21,14 +21,13 @@
   */
 package org.jboss.jms.client.container;
 
+import java.util.ArrayList;
+import java.util.Iterator;
 import java.util.LinkedList;
 import java.util.List;
-import java.util.Iterator;
-import java.util.ArrayList;
 
 import javax.jms.IllegalStateException;
 import javax.jms.Session;
-import javax.jms.JMSException;
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
@@ -69,10 +68,45 @@
 
    public Object handleClosing(Invocation invocation) throws Throwable
    {
-      // Send to the server all acknowledgments accumulated in toAck. This is useful, for example,
-      // when a message listener close the session from its onMessage().
-      acknowledgeOnClosing(invocation);
+      MethodInvocation mi = (MethodInvocation)invocation;
+      SessionState state = getState(invocation);
+      SessionDelegate del = (SessionDelegate)mi.getTargetObject();
+      
+      int ackMode = state.getAcknowledgeMode();
 
+      // select eligible acknowledgments
+      List acks = new ArrayList();
+      List cancels = new ArrayList();
+      for(Iterator i = state.getToAck().iterator(); i.hasNext(); )
+      {
+         AckInfo ack = (AckInfo)i.next();
+         if (ackMode == Session.AUTO_ACKNOWLEDGE ||
+             ackMode == Session.DUPS_OK_ACKNOWLEDGE)
+         {
+            acks.add(ack);            
+         }
+         else
+         {
+            cancels.add(ack);
+         }
+         i.remove();
+      }
+      
+      // On closing we acknowlege any AUTO_ACKNOWLEDGE or DUPS_OK_ACKNOWLEDGE, since the session
+      // might have closed before the onMessage had finished executing.
+      // We cancel any client ack or transactional, we do this explicitly so we can pass the updated
+      // delivery count information from client to server. We could just do this on the server but
+      // we would lose delivery count info.
+
+      if (!acks.isEmpty())
+      {
+         del.acknowledgeBatch(acks);
+      }
+      if (!cancels.isEmpty())
+      {
+         del.cancelDeliveries(cancels);
+      }
+
       return invocation.invokeNext();
    }
 
@@ -111,7 +145,7 @@
          Object[] args = mi.getArguments();
          MessageProxy mp = (MessageProxy)args[0];
          int consumerID = ((Integer)args[1]).intValue();
-         AckInfo info = new AckInfo(mp, consumerID, ackMode);
+         AckInfo info = new AckInfo(mp, consumerID);
          
          state.getToAck().add(info);
          
@@ -144,6 +178,13 @@
       
       int ackMode = state.getAcknowledgeMode();
       
+      boolean cancel = ((Boolean)mi.getArguments()[0]).booleanValue();
+      
+      if (cancel && ackMode != Session.AUTO_ACKNOWLEDGE && ackMode != Session.DUPS_OK_ACKNOWLEDGE)
+      {
+         throw new IllegalStateException("Ack mode must be AUTO_ACKNOWLEDGE or DUPS_OK_ACKNOWLEDGE");
+      }
+      
       if (ackMode == Session.AUTO_ACKNOWLEDGE ||
           ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
           ackMode != Session.CLIENT_ACKNOWLEDGE && state.getCurrentTxId() == null)
@@ -156,10 +197,26 @@
          if (!state.isRecoverCalled())
          {
             if (trace) { log.trace("acknowledging NON-transactionally"); }
-
+                        
             List acks = state.getToAck();
+            
+            // Sanity check
+            if (acks.size() != 1)
+            {
+               throw new IllegalStateException("Should only be one entry in list. " +
+                                               "There are " + acks.size());
+            }
+            
             AckInfo ack = (AckInfo)acks.get(0);
-            sd.acknowledge(ack);
+            
+            if (cancel)
+            {
+               sd.cancelDeliveries(acks);
+            }
+            else
+            {
+               sd.acknowledge(ack);
+            }
             state.getToAck().clear();
          }
          else
@@ -246,13 +303,8 @@
       for (int i = toRedeliver.size() - 1; i >= 0; i--)
       {
          AckInfo info = (AckInfo)toRedeliver.get(i);
-         MessageProxy proxy = info.getMessage();
-         proxy.setJMSRedelivered(true);
+         MessageProxy proxy = info.getMessage();        
          
-         //TODO delivery count although optional should be global so we need to send it back to the
-         //     server but this has performance hit so perhaps we just don't support it?
-         proxy.incDeliveryCount();
-         
          MessageCallbackHandler handler = state.getCallbackHandler(info.getConsumerID());
               
          if (handler == null)
@@ -307,35 +359,6 @@
       return (SessionState)((DelegateSupport)inv.getTargetObject()).getState();
    }
 
-   /**
-    * The method sends to server all eligible acknowlegments (those that are NOT CLIIENT_ACKNOWLEDGE
-    * for example)
-    */
-   private void acknowledgeOnClosing(Invocation invocation) throws JMSException
-   {
-      MethodInvocation mi = (MethodInvocation)invocation;
-      SessionState state = getState(invocation);
-      SessionDelegate del = (SessionDelegate)mi.getTargetObject();
-
-      // select eligible acknowledgments
-      List acks = new ArrayList();
-      for(Iterator i = state.getToAck().iterator(); i.hasNext(); )
-      {
-         AckInfo ack = (AckInfo)i.next();
-         if (ack.getAckMode() == Session.AUTO_ACKNOWLEDGE ||
-             ack.getAckMode() == Session.DUPS_OK_ACKNOWLEDGE)
-         {
-            acks.add(ack);
-            i.remove();
-         }
-      }
-
-      if (!acks.isEmpty())
-      {
-         del.acknowledgeBatch(acks);
-      }
-   }
-    
    // Inner Classes -------------------------------------------------
    
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -172,10 +172,14 @@
       int prefetchSize =
          ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.PREFETCH_SIZE)).intValue();
       
+      int maxDeliveries = 
+         ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.MAX_DELIVERIES)).intValue();
+      
       ConsumerState consumerState =
-         new ConsumerState(sessionState, consumerDelegate, dest, selector,
-                           noLocal,subscriptionName, consumerID, connectionConsumer, prefetchSize);
-      
+         new ConsumerState(sessionState, consumerDelegate, dest, selector, noLocal,
+                           subscriptionName, consumerID, connectionConsumer, prefetchSize,
+                           maxDeliveries);
+
       delegate.setState(consumerState);
       return consumerDelegate;
    }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/TransactionAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -24,7 +24,6 @@
 import javax.jms.IllegalStateException;
 import javax.jms.Message;
 import javax.jms.TransactionInProgressException;
-import javax.jms.Session;
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
@@ -190,7 +189,7 @@
          MethodInvocation mi = (MethodInvocation)invocation;
          MessageProxy proxy = (MessageProxy)mi.getArguments()[0];
          int consumerID = ((Integer)mi.getArguments()[1]).intValue();
-         AckInfo info = new AckInfo(proxy, consumerID, Session.SESSION_TRANSACTED);
+         AckInfo info = new AckInfo(proxy, consumerID);
          ConnectionState connState = (ConnectionState)state.getParent();
 
          if (trace) { log.trace("sending acknowlegment transactionally, queueing on resource manager"); }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -30,6 +30,7 @@
 
 import org.jboss.aop.util.PayloadKey;
 import org.jboss.jms.client.JBossConnectionConsumer;
+import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
@@ -58,6 +59,8 @@
 
    // This should not be exposed other than through meta data
    private int serverId;
+
+   private transient JMSRemotingConnection remotingConnection;
    
    // Static --------------------------------------------------------
 
@@ -216,7 +219,7 @@
    {
       return "ConnectionDelegate[" + id + "]";
    }
-   
+
    public void init()
    {
       super.init();
@@ -224,6 +227,16 @@
                                 new Integer(serverId), PayloadKey.TRANSIENT);
    }
 
+   public void setRemotingConnection(JMSRemotingConnection conn)
+   {
+      this.remotingConnection = conn;
+   }
+
+   public JMSRemotingConnection getRemotingConnection()
+   {
+      return remotingConnection;
+   }
+
    // Protected -----------------------------------------------------
 
    protected Client getClient()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -201,8 +201,6 @@
       }
       else
       {
-         //getClientAOPConfig or getIDBlock
-
          // Create a client - make sure pinging is off
 
          Map configuration = new HashMap();
@@ -251,7 +249,16 @@
 
          throw t;
       }
+      finally
+      {
+         if (remotingConnection == null)
+         {
+            //Not a call to createConnectionDelegate - disconnect the client
 
+            //client.disconnect();
+         }
+      }
+
       Object ret = response.getLoad();
 
       if (remotingConnection != null)
@@ -274,6 +281,8 @@
    
             metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
                                  version, PayloadKey.TRANSIENT);
+
+            connectionDelegate.setRemotingConnection(remotingConnection);
          }
          else
          {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -52,6 +52,7 @@
    
    // This should not be exposed other than through meta data
    private int bufferSize;
+   protected int maxDeliveries;
 
    // This should not be exposed other than through meta data
    private long channelId;
@@ -60,11 +61,12 @@
 
    // Constructors --------------------------------------------------
 
-   public ClientConsumerDelegate(int objectID, long channelId, int bufferSize)
+   public ClientConsumerDelegate(int objectID, long channelId, int bufferSize, int maxDeliveries)
    {
       super(objectID);
       this.bufferSize = bufferSize;
       this.channelId = channelId;
+      this.maxDeliveries = maxDeliveries;
    }
    
    public ClientConsumerDelegate()
@@ -168,6 +170,16 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void confirmDelivery(int count)
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+
    // Public --------------------------------------------------------
 
    public void init()
@@ -177,6 +189,8 @@
                                 new Integer(id), PayloadKey.TRANSIENT);
       getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.PREFETCH_SIZE,
                                 new Integer(bufferSize), PayloadKey.TRANSIENT);
+      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.MAX_DELIVERIES,
+                                new Integer(maxDeliveries), PayloadKey.TRANSIENT);
    }
 
    public String toString()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -317,7 +317,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void postDeliver() throws JMSException
+   public void postDeliver(boolean cancel) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -417,7 +417,8 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons)
+   public void addAsfMessage(MessageProxy m, int consumerID,
+                             ConsumerDelegate cons, int maxDeliveries)
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -38,7 +38,7 @@
 
 /**
  * Base class for all client-side delegate classes.
- * 
+ *
  * Client-side delegate classes provide an empty implementation of the appropriate delegate
  * interface. The classes are advised using JBoss AOP to provide the client side advice stack.
  * The methods in the delegate class will never actually be invoked since they will either be
@@ -47,7 +47,7 @@
  * The delegates are created on the server and serialized back to the client. When they arrive on
  * the client, the init() method is called which causes the advices to be bound to the advised
  * class.
- * 
+ *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  *
@@ -69,25 +69,25 @@
 
    //This is set on the server
    protected int id;
-   
+
    //This is set on the client
    //The reason we don't use the meta-data to store the state for the delegate is to avoid
    //the extra HashMap lookup that would entail.
    //This can be significant since the state could be queried for many aspects
    //in an a single invocation
    protected transient HierarchicalState state;
-   
+
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
 
    public DelegateSupport(int objectID)
    {
-      this.id = objectID;    
+      this.id = objectID;
    }
-   
+
    public DelegateSupport()
-   {      
+   {
    }
 
    // Interceptor implementation ------------------------------------
@@ -109,7 +109,7 @@
                                            Dispatcher.OID,
                                            new Integer(id),
                                            PayloadKey.AS_IS);
-      
+
       byte version = getState().getVersionToUse().getProviderIncrementingVersion();
 
       MessagingMarshallable request = new MessagingMarshallable(version, invocation);
@@ -126,17 +126,17 @@
    {
       return state;
    }
-   
+
    public void setState(HierarchicalState state)
    {
       this.state = state;
    }
-   
+
    /**
     *  Add Invoking interceptor and prepare the stack for invocations.
     */
    public void init()
-   {          
+   {
       ((Advised)this)._getInstanceAdvisor().appendInterceptor(this);
 
       checkMarshallers();
@@ -165,7 +165,7 @@
    {
       return ((Advised)this)._getInstanceAdvisor().getMetaData();
    }
-   
+
    protected abstract Client getClient() throws Exception;
 
 
@@ -183,21 +183,7 @@
       {
          return;
       }
-      
-      //We explicitly associate the datatype "jms" with our custom SerializationManager
-      //This is vital for performance reasons.
-      try
-      {
-//         SerializationStreamFactory.setManagerClassName(
-//            "jms", "org.jboss.remoting.serialization.impl.jboss.JBossSerializationManager");
-         SerializationStreamFactory.setManagerClassName(
-                  "jms", "org.jboss.jms.server.remoting.MessagingSerializationManager");
-      }
-      catch (Exception e)
-      {
-         log.error("Failed to set SerializationManager, e");
-      }
-      
+
       checked = true;
    }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -24,13 +24,11 @@
 import java.util.List;
 import java.util.Map;
 
-import javax.management.MBeanServer;
-
 import org.jboss.jms.server.endpoint.ClientDelivery;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
-import org.jboss.remoting.InvocationRequest;
-import org.jboss.remoting.ServerInvocationHandler;
-import org.jboss.remoting.ServerInvoker;
+import org.jboss.logging.Logger;
+import org.jboss.remoting.callback.Callback;
+import org.jboss.remoting.callback.HandleCallbackException;
 import org.jboss.remoting.callback.InvokerCallbackHandler;
 
 import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
@@ -39,85 +37,92 @@
  * 
  * A CallbackManager.
  * 
- * The CallbackManager is an InvocationHandler used for handling callbacks to message consumers
- * The callback is received and dispatched off to the relevant consumer
+ * The CallbackManager is an InvocationHandler used for handling callbacks to message consumers.
+ * The callback is received and dispatched off to the relevant consumer.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version 1.1
  *
  * CallbackManager.java,v 1.1 2006/02/01 17:38:30 timfox Exp
  */
-public class CallbackManager implements ServerInvocationHandler
+public class CallbackManager implements InvokerCallbackHandler
 {
+   // Constants -----------------------------------------------------
+
+   protected static final Logger log = Logger.getLogger(CallbackManager.class);
+
+   public static final String JMS_CALLBACK_SUBSYSTEM = "CALLBACK";
+
+   // Static --------------------------------------------------------
+
+   protected static CallbackManager theManager;
+
+   // Attributes ----------------------------------------------------
+
+   // Map<Long(lookup)-MessageCallbackHandler>
    protected Map callbackHandlers;
 
+   // Constructors --------------------------------------------------
+
    public CallbackManager()
    {
       callbackHandlers = new ConcurrentReaderHashMap();
    }
-   
-   public void registerHandler(int serverId, int consumerId, MessageCallbackHandler handler)
-   {
-      Long lookup = calcLookup(serverId, consumerId);
-      
-      callbackHandlers.put(lookup, handler);
-   }
-   
-   public MessageCallbackHandler unregisterHandler(int serverId, int consumerId)
-   {
-      Long lookup = calcLookup(serverId, consumerId);
-      
-      return (MessageCallbackHandler)callbackHandlers.remove(lookup);
-   }
-   
-   private Long calcLookup(int serverId, int consumerId)
-   {
-      long id1 = serverId;
-      
-      id1 <<= 32;
-       
-      long id2 = consumerId;
-      
-      long lookup = id1 | id2;
-      
-      return new Long(lookup);
-   }
-   
-   public void addListener(InvokerCallbackHandler arg0)
-   { 
-   }
 
-   public Object invoke(InvocationRequest ir) throws Throwable
+   // InvokerCallbackHandler implementation -------------------------
+
+   public void handleCallback(Callback callback) throws HandleCallbackException
    {
-      MessagingMarshallable mm = (MessagingMarshallable)ir.getParameter();
-      
+      MessagingMarshallable mm = (MessagingMarshallable)callback.getParameter();
       ClientDelivery dr = (ClientDelivery)mm.getLoad();
-        
-      Long lookup = calcLookup(dr.getServerId(), dr.getConsumerId());
-         
+      Long lookup = computeLookup(dr.getServerId(), dr.getConsumerId());
       List msgs = dr.getMessages();
 
-      MessageCallbackHandler handler =
-         (MessageCallbackHandler)callbackHandlers.get(lookup);
-      
+      MessageCallbackHandler handler = (MessageCallbackHandler)callbackHandlers.get(lookup);
+
       if (handler == null)
       {
-         throw new IllegalStateException("Cannot find handler for consumer: " + dr.getConsumerId() +  " and server " + dr.getServerId());
+         throw new IllegalStateException("Cannot find handler for consumer: " + dr.getConsumerId() +
+                                         " and server " + dr.getServerId());
       }
-      
-      return new MessagingMarshallable(mm.getVersion(), handler.handleMessage(msgs));
+
+      handler.handleMessage(msgs);
    }
 
-   public void removeListener(InvokerCallbackHandler arg0)
+   // Public --------------------------------------------------------
+
+   public void registerHandler(int serverID, int consumerID, MessageCallbackHandler handler)
    {
+      Long lookup = computeLookup(serverID, consumerID);
+
+      callbackHandlers.put(lookup, handler);
    }
 
-   public void setInvoker(ServerInvoker arg0)
-   { 
+   public MessageCallbackHandler unregisterHandler(int serverID, int consumerID)
+   {
+      Long lookup = computeLookup(serverID, consumerID);
+
+      return (MessageCallbackHandler)callbackHandlers.remove(lookup);
    }
 
-   public void setMBeanServer(MBeanServer arg0)
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   private Long computeLookup(int serverID, int consumerID)
    {
+      long id1 = serverID;
+
+      id1 <<= 32;
+
+      long lookup = id1 | consumerID;
+
+      return new Long(lookup);
    }
 
+   // Inner classes -------------------------------------------------
+
 }

Deleted: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackServerFactory.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackServerFactory.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/CallbackServerFactory.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,256 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.client.remoting;
-
-import java.net.InetAddress;
-import java.util.HashMap;
-import java.util.Map;
-
-import org.jboss.jms.util.MessagingJMSException;
-import org.jboss.logging.Logger;
-import org.jboss.remoting.InvokerLocator;
-import org.jboss.remoting.security.SSLSocketBuilder;
-import org.jboss.remoting.transport.Connector;
-import org.jboss.remoting.transport.PortUtil;
-
-/**
- *
- * A CallbackServerFactory.
- *
- * We maintain only one callbackserver per transport per client VM.
- * This is to avoid having too many resources e.g. server sockets in use on the client
- * E.g. in the case of a socket transport, if we had one callbackserver per connection then
- * we would have one server socket listening per connection, so we could run out of available
- * ports with a lot of connections.
- *
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- * @version $Revision$
- *
- * $Id$
- */
-public class CallbackServerFactory
-{
-   private static final Logger log = Logger.getLogger(CallbackServerFactory.class);
-
-   private static final String CALLBACK_SERVER_PARAMS =
-      "/?marshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
-      "unmarshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
-      "dataType=jms&" +
-      "timeout=0&" +
-      "socket.check_connection=false";
-
-   public static final String JMS_CALLBACK_SUBSYSTEM = "CALLBACK";
-
-   public static final String CLIENT_HOST =
-      System.getProperty("jboss.messaging.callback.bind.address");
-   
-   public static final int CLIENT_PORT = getPort();
-   
-   private static int getPort()
-   {
-	   String propertyPort = System.getProperty("jboss.messaging.callback.bind.port");
-	   
-	   try
-	   {
-		   if (propertyPort!=null)
-		   {
-			   return Integer.parseInt(propertyPort);
-		   }
-		   else
-		   {
-			   return -1;
-		   }
-	   }
-	   catch (Exception e)
-	   {
-		   log.warn("Error during parsing jboss.messaging.callback.bind.port", e);
-		   return -1;
-	   }
-	   
-   }
-
-   public static CallbackServerFactory instance = new CallbackServerFactory();
-
-   private Map holders;
-
-   private CallbackServerFactory()
-   {
-      holders = new HashMap();
-   }
-
-   public synchronized boolean containsCallbackServer(String protocol)
-   {
-      return holders.containsKey(protocol);
-   }
-
-   public synchronized Connector getCallbackServer(InvokerLocator serverLocator) throws Exception
-   {
-      String protocol = serverLocator.getProtocol();
-
-      Holder h = (Holder)holders.get(protocol);
-
-      if (h == null)
-      {
-         h = new Holder();
-
-         h.server = startCallbackServer(serverLocator);
-
-         holders.put(protocol, h);
-      }
-      else
-      {
-         h.refCount++;
-      }
-
-      return h.server;
-   }
-
-   public synchronized void stopCallbackServer(String protocol)
-   {
-      Holder h = (Holder)holders.get(protocol);
-
-      if (h == null)
-      {
-         throw new IllegalArgumentException("Cannot find callback server for protocol: " + protocol);
-      }
-
-      h.refCount--;
-
-      if (h.refCount == 0)
-      {
-         stopCallbackServer(h.server);
-
-         holders.remove(protocol);
-      }
-   }
-
-   protected Connector startCallbackServer(InvokerLocator serverLocator) throws Exception
-   {
-      if (log.isTraceEnabled()) { log.trace(this + " setting up connection to " + serverLocator); }
-
-      final int MAX_RETRIES = 50;
-      boolean completed = false;
-      Connector server = null;
-      String serializationType = null;
-      int count = 0;
-
-      String thisAddress = CLIENT_HOST;
-      
-      if (thisAddress==null)
-      {
-    	  thisAddress = InetAddress.getLocalHost().getHostAddress();
-      }
-    	  
-      boolean isSSL = serverLocator.getProtocol().equals("sslsocket");
-      Map params = serverLocator.getParameters();
-
-      if (params != null)
-      {
-         //serializationType = (String)params.get("serializationtype");
-         
-         //Always use jms
-         serializationType = "jms";
-      }
-            
-      while (!completed && count < MAX_RETRIES)
-      {
-         try
-         {      
-            int bindPort = CLIENT_PORT;
-            if (bindPort<=0)
-            {
-            	bindPort=PortUtil.findFreePort(thisAddress);
-            }
-            
-            String callbackServerURI;
-      
-            if (isSSL)
-            {
-               // See http://jira.jboss.com/jira/browse/JBREM-470
-               callbackServerURI =
-                  "sslsocket://" + thisAddress + ":" +  bindPort + CALLBACK_SERVER_PARAMS +
-                  "&" + SSLSocketBuilder.REMOTING_SERVER_SOCKET_USE_CLIENT_MODE + "=true";
-            }
-            else
-            {
-               callbackServerURI = serverLocator.getProtocol() + "://" + thisAddress +
-                                   ":" + bindPort + CALLBACK_SERVER_PARAMS;
-            }           
-      
-            if (serializationType != null)
-            {
-               callbackServerURI += "&serializationType=" + serializationType;
-            }
-      
-            InvokerLocator callbackServerLocator = new InvokerLocator(callbackServerURI);
-      
-            log.debug(this + " starting callback server " + callbackServerLocator.getLocatorURI());
-      
-            server = new Connector();
-            server.setInvokerLocator(callbackServerLocator.getLocatorURI());
-            server.create();
-            server.addInvocationHandler(JMS_CALLBACK_SUBSYSTEM, new CallbackManager());
-            server.start();
-      
-            if (log.isTraceEnabled()) { log.trace("callback server started"); }
-            
-            completed = true;
-         }
-         catch (Exception e)
-         {
-            log.warn("Failed to start connection. Will retry", e);
-
-            // Intermittently we can fail to open a socket on the address since it's already in use
-            // This is despite remoting having checked the port is free. This is probably because
-            // of the small window between remoting checking the port is free and getting the
-            // port number and actually opening the connection during which some one else can use
-            // that port. Therefore we catch this and retry.
-
-            count++;
-            
-            if (count == MAX_RETRIES)
-            {
-               final String msg = "Cannot start callbackserver after " + MAX_RETRIES + " retries";
-               log.error(msg, e);
-               throw new MessagingJMSException(msg, e);
-            }
-         }
-      }
-      
-      return server;
-   }
-   
-   protected void stopCallbackServer(Connector server)
-   {
-      log.debug("Stopping and destroying callback server " + server.getLocator().getLocatorURI());
-      server.stop();
-      server.destroy();
-   }
-   
-   private class Holder
-   {
-      Connector server;
-      int refCount = 1;
-   }
-  
-}
-

Copied: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/ClientSocketWrapper.java (from rev 1764, trunk/src/main/org/jboss/jms/client/remoting/ClientSocketWrapper.java)

Deleted: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/DummyCallbackHandler.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/DummyCallbackHandler.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/DummyCallbackHandler.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,48 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.client.remoting;
-
-import org.jboss.remoting.callback.Callback;
-import org.jboss.remoting.callback.HandleCallbackException;
-import org.jboss.remoting.callback.InvokerCallbackHandler;
-
-/**
- * 
- * A DummyCallbackHandler.
- * 
- * This class is only used to trigger the addListener method on the JMSServerInvocationHandler
- * to be called, which allows the server to get hold of a reference to the callback client
- * so it can make callbacks
- * 
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- * @version 1.1
- *
- * DummyCallbackHandler.java,v 1.1 2006/02/01 17:38:30 timfox Exp
- */
-public class DummyCallbackHandler implements InvokerCallbackHandler
-{
-
-   public void handleCallback(Callback cb) throws HandleCallbackException
-   {
-   }
-
-}

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -29,18 +29,15 @@
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.InvokerLocator;
-import org.jboss.remoting.callback.InvokerCallbackHandler;
-import org.jboss.remoting.transport.Connector;
+import org.jboss.remoting.callback.CallbackPoller;
+import org.jboss.remoting.transport.socket.MicroSocketClientInvoker;
+import org.jboss.remoting.transport.socket.SocketServerInvoker;
 
 
 /**
  * Encapsulates the state and behaviour from jboss remoting needed for a JMS connection.
  * 
- * Each JMS connection maintains a single Client instance for invoking on the server, and a
- * Connector instance that represents the callback server used to receive push callbacks from the
- * server.
- * Only Connector is maintained per protocol
- * 
+ * Each JMS connection maintains a single Client instance for invoking on the server
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version 1.1
@@ -51,6 +48,8 @@
 {
    // Constants -----------------------------------------------------
 
+   public static final String CALLBACK_POLL_PERIOD_DEFAULT = "100";
+
    private static final Logger log = Logger.getLogger(JMSRemotingConnection.class);
 
    // Static --------------------------------------------------------
@@ -59,19 +58,15 @@
 
    protected Client client;
    protected boolean clientPing;
-   protected Connector callbackServer;
    protected InvokerLocator serverLocator;
    protected CallbackManager callbackManager;
 
-   private InvokerCallbackHandler dummyCallbackHandler;
-
    // Constructors --------------------------------------------------
 
    public JMSRemotingConnection(String serverLocatorURI, boolean clientPing) throws Throwable
-   { 
+   {
       serverLocator = new InvokerLocator(serverLocatorURI);
       this.clientPing = clientPing;
-      dummyCallbackHandler = new DummyCallbackHandler();
 
       log.debug(this + " created");
    }
@@ -92,11 +87,7 @@
 
       if (log.isTraceEnabled()) { log.trace(this + " created client"); }
 
-      // Get the callback server
-
-      callbackServer = CallbackServerFactory.instance.getCallbackServer(serverLocator);
-      callbackManager = (CallbackManager)callbackServer.getInvocationHandlers()[0];
-
+      callbackManager = new CallbackManager();
       client.connect();
 
       // We explicitly set the Marshaller since otherwise remoting tries to resolve the marshaller
@@ -107,12 +98,64 @@
       client.setMarshaller(new JMSWireFormat());
       client.setUnMarshaller(new JMSWireFormat());
 
-      // We add a dummy callback handler only to trigger the addListener method on the
-      // JMSServerInvocationHandler to be called, which allows the server to get hold of a reference
-      // to the callback client so it can make callbacks
+      // For socket transport allow true push callbacks, with callback Connector.
+      // For http transport, simulate push callbacks.
+      boolean doPushCallbacks = "socket".equals(serverLocator.getProtocol());
+      if (doPushCallbacks)
+      {
+         if (log.isTraceEnabled()) log.trace("doing push callbacks");
+         HashMap metadata = new HashMap();
+         metadata.put(InvokerLocator.DATATYPE, "jms");
+         metadata.put(InvokerLocator.SERIALIZATIONTYPE, "jms"); //Not actually used at present - but it does no harm         
+         metadata.put(MicroSocketClientInvoker.CLIENT_SOCKET_CLASS_FLAG, "org.jboss.jms.client.remoting.ClientSocketWrapper");
+         metadata.put(SocketServerInvoker.SERVER_SOCKET_CLASS_FLAG, "org.jboss.jms.server.remoting.ServerSocketWrapper");
+         
+         String bindAddress = System.getProperty("jboss.messaging.callback.bind.address");
+         if (bindAddress != null)
+         {
+            metadata.put(Client.CALLBACK_SERVER_HOST, bindAddress);
+         }
 
-      client.addListener(dummyCallbackHandler, callbackServer.getLocator());
+         String propertyPort = System.getProperty("jboss.messaging.callback.bind.port");
+         if (propertyPort != null)
+         {
+            metadata.put(Client.CALLBACK_SERVER_PORT, propertyPort);
+         }
 
+         client.addListener(callbackManager, metadata, null, true);
+      }
+      else
+      {
+         if (log.isTraceEnabled()) log.trace("simulating push callbacks");
+
+         HashMap metadata = new HashMap();
+
+         // "jboss.messaging.callback.pollPeriod" system property, if set, has the highest priority ...
+         String callbackPollPeriod = System.getProperty("jboss.messaging.callback.pollPeriod");
+         if (callbackPollPeriod == null)
+         {
+            // followed by the value configured on the HTTP connector ("callbackPollPeriod") ...
+            callbackPollPeriod = (String)serverLocator.getParameters().get("callbackPollPeriod");
+            if (callbackPollPeriod == null)
+            {
+               // followed by the hardcoded value.
+               callbackPollPeriod = CALLBACK_POLL_PERIOD_DEFAULT;
+            }
+         }
+
+         metadata.put(CallbackPoller.CALLBACK_POLL_PERIOD, callbackPollPeriod);
+
+         String reportPollingStatistics =
+            System.getProperty("jboss.messaging.callback.reportPollingStatistics");
+
+         if (reportPollingStatistics != null)
+         {
+            metadata.put(CallbackPoller.REPORT_STATISTICS, reportPollingStatistics);
+         }
+
+         client.addListener(callbackManager, metadata);
+      }
+
       log.debug(this + " started");
    }
 
@@ -123,16 +166,11 @@
       // explicitly remove the callback listener, to avoid race conditions on server
       // (http://jira.jboss.org/jira/browse/JBMESSAGING-535)
 
-      client.removeListener(dummyCallbackHandler);
-      dummyCallbackHandler = null;
-      
-      CallbackServerFactory.instance.stopCallbackServer(serverLocator.getProtocol());
-      
+      client.removeListener(callbackManager);
       client.disconnect();
 
       client=null;
-      
-      log.debug(this + " closed");      
+      log.debug(this + " closed");
    }
 
    public Client getInvokingClient()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -56,7 +56,7 @@
    
    // Static --------------------------------------------------------
    
-   private static boolean trace;
+   private static boolean trace;      
    
    static
    {
@@ -64,27 +64,29 @@
       trace = log.isTraceEnabled();
    }
      
-   // Hardcoded for now
-   private static final int MAX_REDELIVERIES = 10;
-      
    public static void callOnMessage(SessionDelegate sess,
                                     MessageListener listener,
                                     int consumerID,
                                     boolean isConnectionConsumer,
                                     MessageProxy m,
-                                    int ackMode)
+                                    int ackMode,
+                                    int maxDeliveries)
       throws JMSException
    {
       preDeliver(sess, consumerID, m, isConnectionConsumer);
                   
       int tries = 0;
       
+      boolean cancel = false;
+      
       while (true)
       {
          try
          {
             if (trace) { log.trace("calling listener's onMessage(" + m + ")"); }
-
+            
+            m.incDeliveryCount();
+            
             listener.onMessage(m);
 
             if (trace) { log.trace("listener's onMessage() finished"); }
@@ -101,24 +103,20 @@
    
             if (ackMode == Session.AUTO_ACKNOWLEDGE || ackMode == Session.DUPS_OK_ACKNOWLEDGE)
             {
-               // We redeliver at certain number of times
-               if (tries < MAX_REDELIVERIES)
-               {
-                  m.setJMSRedelivered(true);
-                  
-                  // TODO delivery count although optional should be global so we need to send it
-                  // back to the server but this has performance hit so perhaps we just don't
-                  // support it?
-                  m.incDeliveryCount();
-                  
+               // We redeliver a certain number of times
+               if (tries < maxDeliveries)
+               {                            
                   tries++;
                }
                else
                {
                   log.error("Max redeliveries has occurred for message: " + m.getJMSMessageID());
                   
-                  //TODO - Send to DLQ
+                  // postdeliver will do a cancel rather than an ack which will cause the mesage
+                  // to end up in the DLQ
                   
+                  cancel = true;
+                  
                   break;
                }
             }
@@ -136,7 +134,7 @@
       if (!sess.isClosed())
       {
          // postDeliver only if the session is not closed
-         postDeliver(sess, isConnectionConsumer);
+         postDeliver(sess, isConnectionConsumer, cancel);
       }
    }
    
@@ -154,52 +152,41 @@
       }         
    }
    
-   protected static void postDeliver(SessionDelegate sess, boolean isConnectionConsumer)
-      throws JMSException
+   protected static void postDeliver(SessionDelegate sess, boolean isConnectionConsumer,
+                                     boolean cancel) throws JMSException
    {
       // If this is the callback-handler for a connection consumer we don't want to acknowledge or
       // add anything to the tx for this session
       if (!isConnectionConsumer)
       {
-         sess.postDeliver();
+         sess.postDeliver(cancel);
       }         
    }
    
    // Attributes ----------------------------------------------------
       
    private LinkedList buffer;
-   
    private SessionDelegate sessionDelegate;
-   
    private ConsumerDelegate consumerDelegate;
-   
    private int consumerID;
-   
    private boolean isConnectionConsumer;
-   
    private volatile Thread receiverThread;
-   
    private MessageListener listener;
-    
    private int ackMode;
-      
    private boolean closed;
-   
    private Object mainLock;
-   
    private boolean serverSending;
-   
    private int bufferSize;
-   
    private QueuedExecutor sessionExecutor;
-   
    private boolean listenerRunning;
+   private int maxDeliveries;
         
    // Constructors --------------------------------------------------
 
    public MessageCallbackHandler(boolean isCC, int ackMode,                                
                                  SessionDelegate sess, ConsumerDelegate cons, int consumerID,
-                                 int bufferSize, QueuedExecutor sessionExecutor)
+                                 int bufferSize, QueuedExecutor sessionExecutor,
+                                 int maxDeliveries)
    {
       if (bufferSize < 1)
       {
@@ -207,24 +194,16 @@
       }
               
       this.bufferSize = bufferSize;
-
       buffer = new LinkedList();
-
       isConnectionConsumer = isCC;
-      
       this.ackMode = ackMode;
-
       this.sessionDelegate = sess;
-
       this.consumerDelegate = cons;
-      
       this.consumerID = consumerID;
-      
       this.serverSending = true;
-      
-      mainLock = new Object();                  
-      
+      mainLock = new Object();
       this.sessionExecutor = sessionExecutor;
+      this.maxDeliveries = maxDeliveries;
    }
         
    // Public --------------------------------------------------------
@@ -247,7 +226,18 @@
             // Ignore
             return new HandleMessageResponse(false, 0);
          }
-                                      
+
+         // Asynchronously confirm delivery on client
+
+         try
+         {
+            sessionExecutor.execute(new ConfirmDelivery(msgs.size()));
+         }
+         catch (InterruptedException e)
+         {
+            log.warn("Thread interrupted", e);
+         }
+
          // Put the messages in the buffer and notify any waiting receive()
          
          processMessages(msgs);
@@ -453,7 +443,7 @@
                // message is acknowledged so it gets removed from the queue/subscription.
                preDeliver(sessionDelegate, consumerID, m, isConnectionConsumer);
                
-               postDeliver(sessionDelegate, isConnectionConsumer);
+               postDeliver(sessionDelegate, isConnectionConsumer, false);
                
                if (!m.getMessage().isExpired())
                {
@@ -488,6 +478,8 @@
          consumerDelegate.more();
       }
       
+      m.incDeliveryCount();
+      
       return m;
    }    
    
@@ -730,7 +722,7 @@
          {
             try
             {
-               callOnMessage(sessionDelegate, listener, consumerID, false, mp, ackMode);
+               callOnMessage(sessionDelegate, listener, consumerID, false, mp, ackMode, maxDeliveries);
             }
             catch (JMSException e)
             {
@@ -761,6 +753,26 @@
          }
       }
    }
+
+   /*
+    * Used to asynchronously confirm to the server message arrival (delivery) on client.
+    */
+   private class ConfirmDelivery implements Runnable
+   {
+      int count;
+
+      ConfirmDelivery(int count)
+      {
+         this.count = count;
+      }
+
+      public void run()
+      {
+         if (trace) { log.trace("confirming delivery on client of " + count + " message(s)"); }
+         consumerDelegate.confirmDelivery(count);
+      }
+   }
+
 }
 
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConsumerState.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,32 +1,32 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.client.state;
 
 import java.util.Collections;
 
 import javax.jms.Destination;
 
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
-import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.server.Version;
 
@@ -56,14 +56,16 @@
    private MessageCallbackHandler messageCallbackHandler;
 
    private int prefetchSize;
-
+   
    private SessionState parent;
-
+   
    private ConsumerDelegate delegate;
-
+   
+   private int maxDeliveries;
+   
    public ConsumerState(SessionState parent, ConsumerDelegate delegate, Destination dest,
-                        String selector,  boolean noLocal, String subscriptionName,
-                        int consumerID, boolean isCC, int prefetchSize)
+                        String selector, boolean noLocal, String subscriptionName, int consumerID,
+                        boolean isCC, int prefetchSize, int maxDeliveries)
    {
       super(parent, (DelegateSupport)delegate);
       children = Collections.EMPTY_SET;
@@ -74,9 +76,9 @@
       this.isConnectionConsumer = isCC;
       this.prefetchSize = prefetchSize;
       this.subscriptionName=subscriptionName;
+      this.maxDeliveries = maxDeliveries;
    }
 
-
    public DelegateSupport getDelegate()
    {
       return (DelegateSupport)delegate;
@@ -157,6 +159,10 @@
    {
       this.consumerID = newState.consumerID;
    }
-}
 
+   public int getMaxDeliveries()
+   {
+      return maxDeliveries;
+   }
 
+}

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/delegate/SessionDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -67,7 +67,7 @@
    
    void preDeliver(MessageProxy proxy, int consumerID) throws JMSException;
    
-   void postDeliver() throws JMSException;
+   void postDeliver(boolean cancel) throws JMSException;
    
    MessageListener getMessageListener() throws JMSException;
    
@@ -77,7 +77,7 @@
    
    XAResource getXAResource();
    
-   void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons);
+   void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons, int maxDeliveries);
    
    boolean getTransacted();
    
@@ -94,6 +94,4 @@
    ProducerDelegate createProducerDelegate(JBossDestination destination) throws JMSException;
    
    void acknowledgeAll() throws JMSException;
-
-
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/JBossMessage.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/JBossMessage.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/JBossMessage.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -188,7 +188,7 @@
             sb.append(name).append(" - ").append(m.headers.get(name)).append('\n');
          }
       }
-      sb.append("              redelivered:   ").append(m.redelivered).append('\n');
+      sb.append("              redelivered:   ").append(m.deliveryCount >= 1).append('\n');
       sb.append("              priority:      ").append(m.priority).append('\n');
       sb.append("              deliveryCount: ").append(m.deliveryCount).append('\n');
 
@@ -336,7 +336,7 @@
          setJMSDestination(foreign.getJMSDestination());
       }
       setJMSDeliveryMode(foreign.getJMSDeliveryMode());
-      setJMSRedelivered(foreign.getJMSRedelivered());
+      setDeliveryCount(foreign.getJMSRedelivered() ? 1 : 0);
       setJMSExpiration(foreign.getJMSExpiration());
       setJMSPriority(foreign.getJMSPriority());
       setJMSType(foreign.getJMSType());
@@ -480,12 +480,19 @@
 
    public boolean getJMSRedelivered() throws JMSException
    {
-      return isRedelivered();
+      return deliveryCount >= 2;
    }
 
    public void setJMSRedelivered(boolean redelivered) throws JMSException
    {
-      setRedelivered(redelivered);
+      if (deliveryCount == 1)
+      {
+         deliveryCount++;
+      }
+      else
+      {
+         //do nothing
+      }
    }
 
    /**

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/MessageProxy.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/MessageProxy.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/message/MessageProxy.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -80,7 +80,6 @@
    protected transient boolean bodyReadOnly;
 
    protected int deliveryCount;
-   protected transient boolean jmsRedelivered;
 
    // Constructors --------------------------------------------------
 
@@ -177,13 +176,24 @@
    public boolean getJMSRedelivered() throws JMSException
    {
       //Always handled in the delegate
-      return jmsRedelivered;
+      //This is because when sending a message to a topic (for instance)
+      //with multiple subscriptions all in the same VM, then we don't copy the original
+      //message for performance reasons, unless necessary, but each reference might have
+      //it's own value for delivery count
+      return deliveryCount >= 2;
    }
 
    public void setJMSRedelivered(boolean redelivered) throws JMSException
    {
       //Always handled in the delegate
-      jmsRedelivered = redelivered;
+      if (deliveryCount == 1)
+      {
+         deliveryCount++;
+      }
+      else
+      {
+         //do nothing
+      }
    }
 
    public String getJMSType() throws JMSException
@@ -407,8 +417,6 @@
       propertiesReadOnly = true;
 
       bodyReadOnly = true;
-
-      this.jmsRedelivered = deliveryCount > 1;
    }
 
    public JBossMessage getMessage()
@@ -423,7 +431,7 @@
    
    public void incDeliveryCount()
    {
-      this.deliveryCount++;
+      this.deliveryCount++;            
    }
 
    public String toString()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -40,9 +40,11 @@
 import org.jboss.jms.server.endpoint.ServerConsumerEndpoint;
 import org.jboss.jms.server.plugin.contract.JMSUserManager;
 import org.jboss.jms.server.remoting.JMSWireFormat;
+import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
 import org.jboss.jms.server.security.SecurityMetadataStore;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.memory.MemoryManager;
 import org.jboss.messaging.core.memory.SimpleMemoryManager;
 import org.jboss.messaging.core.plugin.IdManager;
@@ -54,11 +56,12 @@
 import org.jboss.messaging.core.plugin.contract.Replicator;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 import org.jboss.messaging.core.plugin.postoffice.cluster.FailoverStatus;
+import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.Util;
 import org.jboss.mx.loading.UnifiedClassLoader3;
 import org.jboss.remoting.marshal.MarshalFactory;
-import org.jboss.remoting.serialization.SerializationStreamFactory;
+import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.system.ServiceCreator;
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
@@ -96,13 +99,17 @@
 
    private String defaultQueueJNDIContext;
    private String defaultTopicJNDIContext;
-   
+
    private int queuedExecutorPoolSize = 200;
 
    private boolean started;
 
    private int objectIDSequence = 1;
-   
+
+   private int maxDeliveryAttempts = 10;
+
+   private String dlqName;
+
    private Object failoverStatusLock;
       
    // wired components
@@ -118,24 +125,26 @@
    private IdManager transactionIdManager;
    private MemoryManager memoryManager;
    private QueuedExecutorPool queuedExecutorPool;
-   private MessageStore messageStore;   
+   private MessageStore messageStore;
 
    // plugins
 
    protected ObjectName persistenceManagerObjectName;
    protected PersistenceManager persistenceManager;
-   
+
    protected ObjectName postOfficeObjectName;
    protected PostOffice postOffice;
-   
+
 //   protected ObjectName topicPostOfficeObjectName;
 //   protected PostOffice topicPostOffice;
-     
+
    protected ObjectName jmsUserManagerObjectName;
    protected JMSUserManager jmsUserManager;
-   
+
    //Other stuff
 
+   private JMSServerInvocationHandler handler;
+
    // We keep a map of consumers to prevent us to recurse through the attached session in order to
    // find the ServerConsumerDelegate so we can acknowledge the message. Originally, this map was
    // maintained per-connection, but with the http://jira.jboss.org/jira/browse/JBMESSAGING-211 bug
@@ -156,7 +165,7 @@
 
       // Some wired components need to be started here
       securityStore = new SecurityMetadataStore();
-      
+
       consumers = new ConcurrentReaderHashMap();
 
       version = Version.instance();
@@ -172,38 +181,40 @@
    {
       try
       {
+         log.debug("starting ServerPeer");
+
          if (started)
          {
             return;
          }
-         
+
          log.debug(this + " starting");
-         
+
          if (queuedExecutorPoolSize < 1)
          {
             throw new IllegalArgumentException("queuedExecutorPoolSize must be > 0");
          }
          queuedExecutorPool = new QueuedExecutorPool(queuedExecutorPoolSize);
-            
+
          loadClientAOPConfig();
-   
+
          loadServerAOPConfig();
-   
+
          MBeanServer mbeanServer = getServer();
-   
+
          // Acquire references to plugins. Each plug-in will be accessed directly via a reference
          // circumventing the MBeanServer. However, they are installed as services to take advantage
          // of their automatically-creating management interface.
-   
+
          persistenceManager = (PersistenceManager)mbeanServer.
             getAttribute(persistenceManagerObjectName, "Instance");
 
          jmsUserManager = (JMSUserManager)mbeanServer.
             getAttribute(jmsUserManagerObjectName, "Instance");
-         
+
          //We get references to some plugins lazily to avoid problems with circular
          //MBean dependencies
-            
+
          // Create the wired components
          messageIdManager = new IdManager("MESSAGE_ID", 4096, persistenceManager);
          channelIdManager = new IdManager("CHANNEL_ID", 10, persistenceManager);
@@ -213,36 +224,36 @@
          connectionManager = new SimpleConnectionManager();
          connectorManager = new SimpleConnectorManager();
          memoryManager = new SimpleMemoryManager();
-         messageStore = new SimpleMessageStore();         
+         messageStore = new SimpleMessageStore();
          txRepository = new TransactionRepository(persistenceManager, transactionIdManager);
- 
+
          // Start the wired components
-   
+
          messageIdManager.start();
          channelIdManager.start();
          transactionIdManager.start();
          destinationJNDIMapper.start();
          connFactoryJNDIMapper.start();
          connectionManager.start();
-         connectorManager.start();         
+         connectorManager.start();
          memoryManager.start();
          messageStore.start();
          securityStore.start();
          txRepository.start();
-         
+
          initializeRemoting(mbeanServer);
-   
+
          //createRecoverable();
-   
+
          started = true;
-   
+
          log.info("JBoss Messaging " + getVersion().getProviderVersion() + " server [" +
-            getServerPeerID()+ "] started");      
+            getServerPeerID()+ "] started");
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " startService");
-      } 
+      }
    }
 
    public synchronized void stopService() throws Exception
@@ -253,15 +264,15 @@
          {
             return;
          }
-   
+
          log.debug(this + " stopping");
-   
+
          started = false;
-   
+
          //removeRecoverable();
-        
-         // Stop the wired components         
-         
+
+         // Stop the wired components
+
          messageIdManager.stop();
          messageIdManager = null;
          channelIdManager.stop();
@@ -274,7 +285,7 @@
          connFactoryJNDIMapper = null;
          connectionManager.stop();
          connectionManager = null;
-         connectorManager.start(); 
+         connectorManager.start();
          connectorManager = null;
          memoryManager.stop();
          memoryManager = null;
@@ -284,24 +295,43 @@
          securityStore = null;
          txRepository.stop();
          txRepository = null;
-   
+
          unloadServerAOPConfig();
-   
+
          // TODO unloadClientAOPConfig();
-         
+
          queuedExecutorPool.shutdown();
-                  
+
          log.info("JMS " + this + " stopped");
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " stopService");
-      } 
+      }
    }
 
    // JMX Attributes ------------------------------------------------
 
+   public String getDLQName()
+   {
+      return dlqName;
+   }
 
+   public void setDLQName(String dlqName)
+   {
+      this.dlqName = dlqName;
+   }
+
+   public int getMaxDeliveryAttempts()
+   {
+      return maxDeliveryAttempts;
+   }
+
+   public void setMaxDeliveryAttempts(int attempts)
+   {
+      this.maxDeliveryAttempts = attempts;
+   }
+
    public ObjectName getPersistenceManager()
    {
       return persistenceManagerObjectName;
@@ -311,7 +341,7 @@
    {
       persistenceManagerObjectName = on;
    }
-   
+
    public ObjectName getPostOffice()
    {
       return postOfficeObjectName;
@@ -321,7 +351,7 @@
    {
       postOfficeObjectName = on;
    }
-   
+
 //   public ObjectName getTopicPostOffice()
 //   {
 //      return topicPostOfficeObjectName;
@@ -331,7 +361,7 @@
 //   {
 //      topicPostOfficeObjectName = on;
 //   }
-   
+
    public ObjectName getJmsUserManager()
    {
       return jmsUserManagerObjectName;
@@ -341,7 +371,7 @@
    {
       jmsUserManagerObjectName = on;
    }
-   
+
    public Object getInstance()
    {
       return this;
@@ -401,12 +431,12 @@
    {
       try
       {
-         securityStore.setSecurityDomain(securityDomain);      
+         securityStore.setSecurityDomain(securityDomain);
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " setSecurityDomain");
-      } 
+      }
    }
 
    public String getSecurityDomain()
@@ -428,22 +458,27 @@
    {
       return messageIdManager;
    }
-   
+
    public IdManager getChannelIdManager()
    {
       return channelIdManager;
    }
 
+   public ServerInvocationHandler getInvocationHandler()
+   {
+      return handler;
+   }
+
    public int getQueuedExecutorPoolSize()
    {
       return queuedExecutorPoolSize;
    }
-   
+
    public void setQueuedExecutorPoolSize(int poolSize)
    {
       this.queuedExecutorPoolSize = poolSize;
    }
-   
+
    // JMX Operations ------------------------------------------------
 
    public String createQueue(String name, String jndiName) throws Exception
@@ -455,7 +490,7 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " createQueue");
-      } 
+      }
    }
 
    public String createQueue(String name, String jndiName, int fullSize, int pageSize, int downCacheSize) throws Exception
@@ -467,7 +502,7 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " createQueue(2)");
-      } 
+      }
    }
 
    public boolean destroyQueue(String name) throws Exception
@@ -479,7 +514,7 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " destroyQueue");
-      } 
+      }
    }
 
    public String createTopic(String name, String jndiName) throws Exception
@@ -491,7 +526,7 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " createTopic");
-      } 
+      }
    }
 
    public String createTopic(String name, String jndiName, int fullSize, int pageSize, int downCacheSize) throws Exception
@@ -503,7 +538,7 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " createTopic(2)");
-      } 
+      }
    }
 
    public boolean destroyTopic(String name) throws Exception
@@ -515,7 +550,7 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " destroyTopic");
-      } 
+      }
    }
 
    public Set getDestinations() throws Exception
@@ -527,11 +562,33 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " getDestinations");
-      } 
+      }
    }
 
-   // Public --------------------------------------------------------     
+   // Public --------------------------------------------------------
 
+   public Queue getDLQ() throws Exception
+   {
+      if (dlqName == null)
+      {
+         //No DLQ name specified so there is no DLQ
+         return null;
+      }
+
+      PostOffice postOffice = getPostOfficeInstance();
+
+      Binding binding = postOffice.getBindingForQueueName(dlqName);
+      
+      if (binding != null && binding.getQueue().isActive())
+      {
+         return binding.getQueue();
+      }
+      else
+      {
+         return null;
+      }   
+   }
+
    public TransactionRepository getTxRepository()
    {
       return txRepository;
@@ -551,7 +608,7 @@
    {
       return version;
    }
-   
+
    // access to hard-wired server extensions
 
    public SecurityManager getSecurityManager()
@@ -578,12 +635,12 @@
    {
       return connectorManager;
    }
-   
+
    public MessageStore getMessageStore()
    {
       return messageStore;
    }
-   
+
    public MemoryManager getMemoryManager()
    {
       return memoryManager;
@@ -595,22 +652,12 @@
    {
       return persistenceManager;
    }
-   
+
    public JMSUserManager getJmsUserManagerInstance()
    {
       return jmsUserManager;
    }
 
-   public Replicator getReplicator() throws Exception
-   {
-      PostOffice postOffice = getPostOfficeInstance();
-      if (!(postOffice instanceof Replicator))
-      {
-         throw new  IllegalAccessException("This operations is only legal on clustering configurations");
-      }
-      return (Replicator)postOffice;
-   }
-   
    public PostOffice getPostOfficeInstance() throws Exception
    {
       // We get the reference lazily to avoid problems with MBean circular dependencies
@@ -618,34 +665,32 @@
       {
          postOffice = (PostOffice)getServer().
             getAttribute(postOfficeObjectName, "Instance");
-         
-         //We also inject the replicator dependency into the ConnectionFactoryJNDIMapper
-         //This is a bit messy but we have a circular dependency
-         //POJOContainer should be able to help us here
-         //Yes, this is nasty
-         
+
+         // We also inject the replicator dependency into the ConnectionFactoryJNDIMapper. This is
+         // a bit messy but we have a circular dependency POJOContainer should be able to help us
+         // here. Yes, this is nasty.
+
          if (!postOffice.isLocal())
          {
             Replicator rep = (Replicator)postOffice;
             connFactoryJNDIMapper.injectReplicator(rep);
             rep.registerListener(new FailoverListener());
-            
+
          }
       }
       return postOffice;
    }
-      
-//   public PostOffice getTopicPostOfficeInstance() throws Exception
-//   {
-//      // We get the reference lazily to avoid problems with MBean circular dependencies
-//      if (topicPostOffice == null)
-//      {
-//         topicPostOffice = (PostOffice)getServer().
-//            getAttribute(topicPostOfficeObjectName, "Instance");
-//      }
-//      return topicPostOffice;        
-//   }
-   
+
+   public Replicator getReplicator() throws Exception
+   {
+      PostOffice postOffice = getPostOfficeInstance();
+      if (!(postOffice instanceof Replicator))
+      {
+         throw new  IllegalAccessException("This operations is only legal on clustering configurations");
+      }
+      return (Replicator)postOffice;
+   }
+
    public synchronized int getNextObjectID()
    {
       return objectIDSequence++;
@@ -667,7 +712,7 @@
       log.debug(this + " removing consumer " + consumerID + " from the cache");
       return (ServerConsumerEndpoint)consumers.remove(consumerID);
    }
-   
+
    public QueuedExecutorPool getQueuedExecutorPool()
    {
       return queuedExecutorPool;
@@ -864,17 +909,11 @@
 
    private void initializeRemoting(MBeanServer mbeanServer) throws Exception
    {
-      // We explicitly associate the datatype "jms" with the java SerializationManager
-      // This is vital for performance reasons.
-//      SerializationStreamFactory.setManagerClassName(
-//         "jms", "org.jboss.remoting.serialization.impl.jboss.JBossSerializationManager");
-      SerializationStreamFactory.setManagerClassName(
-             "jms", "org.jboss.jms.server.remoting.MessagingSerializationManager");
-      
-
       JMSWireFormat wf = new JMSWireFormat();
 
       MarshalFactory.addMarshaller("jms", wf, wf);
+
+      handler = new JMSServerInvocationHandler();
    }
 
    private void loadServerAOPConfig() throws Exception
@@ -1001,7 +1040,7 @@
 
       String destType = isQueue ? "Queue" : "Topic";
       String className = "org.jboss.jms.server.destination." + destType + "Service";
-      
+
       String ons ="jboss.messaging.destination:service="+ destType + ",name=" + name;
       ObjectName on = new ObjectName(ons);
 
@@ -1016,7 +1055,7 @@
          "    <attribute name=\"PageSize\">" + pageSize + "</attribute>" +
          "    <attribute name=\"DownCacheSize\">" + downCacheSize + "</attribute>" +
          "</mbean>";
-      
+
       return createDestinationInternal(destinationMBeanConfig, on, jndiName, true, fullSize,
                                        pageSize, downCacheSize);
    }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -127,7 +127,7 @@
                                              defaultTempQueueFullSize,
                                              defaultTempQueuePageSize,
                                              defaultTempQueueDownCacheSize);
-      endpoints.put(uniqueName, endpoint);   
+      endpoints.put(uniqueName, endpoint);
       
       ClientConnectionFactoryDelegate delegate = null;
 
@@ -436,10 +436,7 @@
           }
       }
             
-      ClusteredClientConnectionFactoryDelegate clusteredDelegate =
-         new ClusteredClientConnectionFactoryDelegate(mainDelegate, delArr, failoverMap);
-      
-      return clusteredDelegate;
+      return new ClusteredClientConnectionFactoryDelegate(mainDelegate, delArr, failoverMap);
    }
    
    private void rebindConnectionFactory(Context ic,

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/container/InjectionAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -56,7 +56,7 @@
     {
        MethodInvocation mi = (MethodInvocation)invocation;
        
-       // First we inject the callback client for the connection
+       // First we inject the callback handler for the connection
        
        ServerInvokerCallbackHandler handler =
           (ServerInvokerCallbackHandler)mi.getMetaData(MetaDataConstants.JMS,
@@ -68,7 +68,6 @@
        }
        
        CreateConnectionResult res = (CreateConnectionResult)invocation.invokeNext();
-       
        ClientConnectionDelegate del = (ClientConnectionDelegate)res.getDelegate();
        
        if (del != null)
@@ -78,7 +77,7 @@
           
           ServerConnectionEndpoint endpoint = (ServerConnectionEndpoint)advised.getEndpoint();
           
-          endpoint.setCallbackClient(handler.getCallbackClient());
+          endpoint.setCallbackHandler(handler);
           
           // Then we inject the remoting session id of the client
           String sessionId =

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -118,7 +118,7 @@
             throw new IllegalStateException( "The " + (isQueue() ? "queue" : "topic") + " " +
                                              "name was not properly set in the service's" +
                                              "ObjectName");
-         }
+         }                  
          
          destination.setName(name);                   
       }
@@ -134,7 +134,7 @@
    }
    
    // JMX managed attributes ----------------------------------------
-
+   
    public String getJNDIName()
    {
       return destination.getJndiName();

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -30,6 +30,8 @@
  * The rest of the methods are handled in the advice stack.
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ *
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -37,11 +39,23 @@
 public interface ConsumerEndpoint extends Closeable
 {  
    /**
-    * If the client buffer has previously become full because the server was sending at a faster rate than the
-    * client could consume, then the server will stop sending messages.
-    * When the client has emptied the buffer it then needs to inform the server that it can receive more messages
-    * by calling this method
+    * If the client buffer has previously become full because the server was sending at a faster
+    * rate than the client could consume, then the server will stop sending messages. When the
+    * client has emptied the buffer it then needs to inform the server that it can receive more
+    * messages by calling this method.
+    *
     * @throws JMSException
     */
-   void more() throws JMSException;   
+   void more() throws JMSException;
+
+   /**
+    * The server consumer endpoint needs to know at any time how messages are in transit between
+    * server and client. That is why it needs to receive confirmations every time the client
+    * received one (or more) messages. The confirmation is sent asynchronously from client to server.
+    * This is NOT a consumption acknowledgment.
+    *
+    * @param count - the number of messages received by the client in one batch.
+    */
+   void confirmDelivery(int count);
+
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -33,7 +33,7 @@
 import javax.transaction.xa.Xid;
 
 import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.client.remoting.CallbackServerFactory;
+import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.JBossMessage;
@@ -57,6 +57,7 @@
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.ConcurrentReaderHashSet;
 import org.jboss.remoting.Client;
+import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
 import org.jboss.util.id.GUID;
 
 import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
@@ -117,7 +118,7 @@
    
    private MessageStore ms;
    
-   private Client callbackClient;
+   private ServerInvokerCallbackHandler callbackHandler;
    
    private byte usingVersion;
    
@@ -427,21 +428,31 @@
    }
    
    //IOC
-   public void setCallbackClient(Client client)
+   public void setCallbackHandler(ServerInvokerCallbackHandler handler)
    {
-      callbackClient = client;
-
-      // TODO not sure if this is the best way to do this, but the callbackClient needs to have
-      //      its "subsystem" set, otherwise remoting cannot find the associated
-      //      ServerInvocationHandler on the callback server
-      callbackClient.setSubsystem(CallbackServerFactory.JMS_CALLBACK_SUBSYSTEM);
-
-      // We explictly set the Marshaller since otherwise remoting tries to resolve the marshaller
-      // every time which is very slow - see org.jboss.remoting.transport.socket.ProcessInvocation
-      // This can make a massive difference on performance. We also do this in
-      // JMSRemotingConnection.setupConnection
-      callbackClient.setMarshaller(new JMSWireFormat());
-      callbackClient.setUnMarshaller(new JMSWireFormat());
+      callbackHandler = handler;
+      Client callbackClient = callbackHandler.getCallbackClient();
+      
+      if (callbackClient != null)
+      {
+         // TODO not sure if this is the best way to do this, but the callbackClient needs to have
+         //      its "subsystem" set, otherwise remoting cannot find the associated
+         //      ServerInvocationHandler on the callback server
+         callbackClient.setSubsystem(CallbackManager.JMS_CALLBACK_SUBSYSTEM);
+         
+         // We explictly set the Marshaller since otherwise remoting tries to resolve the marshaller
+         // every time which is very slow - see org.jboss.remoting.transport.socket.ProcessInvocation
+         // This can make a massive difference on performance. We also do this in
+         // JMSRemotingConnection.setupConnection
+         
+         callbackClient.setMarshaller(new JMSWireFormat());
+         callbackClient.setUnMarshaller(new JMSWireFormat());
+      }
+      else
+      {
+         log.debug("ServerInvokerCallbackHandler callback Client is not available: " +
+                   "must be using pull callbacks");
+      }
    }
    
    // IOC
@@ -494,9 +505,9 @@
    
    // Protected -----------------------------------------------------
    
-   protected Client getCallbackClient()
+   protected ServerInvokerCallbackHandler getCallbackHandler()
    {
-      return callbackClient;
+      return callbackHandler;
    }   
    
    protected int getConnectionID()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -32,7 +32,6 @@
 import javax.jms.InvalidSelectorException;
 import javax.jms.JMSException;
 
-import org.jboss.jms.client.remoting.HandleMessageResponse;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
@@ -46,6 +45,7 @@
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.Routable;
 import org.jboss.messaging.core.SimpleDelivery;
@@ -56,6 +56,7 @@
 import org.jboss.messaging.core.tx.TransactionException;
 import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.util.Future;
+import org.jboss.remoting.callback.Callback;
 
 import EDU.oswego.cs.dl.util.concurrent.Executor;
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
@@ -76,9 +77,9 @@
 
    private static final Logger log = Logger.getLogger(ServerConsumerEndpoint.class);
 
-   // Static --------------------------------------------------------
+   // Static --------------------------------------------------------  
 
-   private static final int MAX_DELIVERY_ATTEMPTS = 10;
+   private static final int MESSAGES_IN_TRANSIT_WAIT_COUNT = 100;
 
    // Attributes ----------------------------------------------------
 
@@ -123,13 +124,18 @@
 
    private Map deliveries;
    
+   private Queue dlq;
+   
+   private Object messagesInTransitLock;
+   private int messagesInTransitCount; // access only from a region guarded by messagesInTransitLock
+   
    // Constructors --------------------------------------------------
 
    protected ServerConsumerEndpoint(int id, PagingFilteredQueue messageQueue, String queueName,
                                     ServerSessionEndpoint sessionEndpoint,
                                     String selector, boolean noLocal, JBossDestination dest,
-                                    int prefetchSize)
-                                    throws InvalidSelectorException
+                                    int prefetchSize, Queue dlq)
+      throws InvalidSelectorException
    {
       if (trace) { log.trace("constructing consumer endpoint " + id); }
 
@@ -138,6 +144,7 @@
       this.queueName = queueName;
       this.sessionEndpoint = sessionEndpoint;
       this.prefetchSize = prefetchSize;
+      this.dlq = dlq;
 
       // We always created with clientConsumerFull = true. This prevents the SCD sending messages to
       // the client before the client has fully finished creating the MessageCallbackHandler.
@@ -193,6 +200,9 @@
       
       // prompt delivery
       messageQueue.deliver(false);
+
+      messagesInTransitLock = new Object();
+      messagesInTransitCount = 0;
       
       log.debug(this + " constructed");
    }
@@ -247,16 +257,14 @@
          {
             return delivery;
          }
-            
-         checkDeliveryCount(delivery);
-         
+                 
          if (delivery.isDone())
          {
             return delivery;
          }
+
+         deliveries.put(new Long(ref.getMessageID()), delivery);
    
-         deliveries.put(new Long(ref.getMessageID()), delivery);                 
-   
          // We don't send the message as-is, instead we create a MessageProxy instance. This allows
          // local fields such as deliveryCount to be handled by the proxy but global data to be
          // fielded by the same underlying Message instance. This allows us to avoid expensive
@@ -404,34 +412,39 @@
    {           
       try
       {
-         /*
-         Set clientConsumerFull to false
-         NOTE! This must be done using a Runnable on the delivery executor - this is to
-         prevent the following race condition:
-         1) Messages are delivered to the client, causing it to be full
-         2) The messages are consumed very quickly on the client causing more to be called()
-         3) more() hits the server BEFORE the deliverer thread has returned from delivering to the client
-         causing clientConsumerFull to be set to false and adding a deliverer to the queue.
-         4) The deliverer thread returns and sets clientConsumerFull to true
-         5) The next deliverer runs but doesn't do anything since clientConsumerFull = true even
-         though the client needs messages
-         */
-         this.executor.execute(new Runnable() { public void run() { clientConsumerFull = false; } });         
+         // Set clientConsumerFull to false.
+         //
+         // NOTE! This must be done using a Runnable on the delivery executor - this is to prevent
+         // the following race condition:
+         //  1) Messages are delivered to the client, causing it to be full.
+         //  2) The messages are consumed very quickly on the client causing more() to be called.
+         //  3) more() hits the server BEFORE the deliverer thread has returned from delivering to
+         //     the client causing clientConsumerFull to be set to false and adding a deliverer to
+         //     the queue.
+         //  4) The deliverer thread returns and sets clientConsumerFull to true.
+         //  5) The next deliverer runs but doesn't do anything since clientConsumerFull = true even
+         //     though the client needs messages.
+
+         executor.execute(new Runnable()
+         {
+            public void run()
+            {
+               if (trace) { log.trace(ServerConsumerEndpoint.this + " is notified that client wants more() messages"); }
+               clientConsumerFull = false;
+            }
+         });
                            
-         //Run a deliverer to deliver any existing ones
-         this.executor.execute(new Deliverer());
+         // Run a deliverer to deliver any existing ones
+         executor.execute(new Deliverer());
          
-         //TODO Why do we need to wait for it to execute??
-         //Why not just return immediately?
+         // TODO Why do we need to wait for it to execute? Why not just return immediately?
          
-         //Now wait for it to execute
+         // Now wait for it to execute
          Future result = new Future();
-         
          this.executor.execute(new Waiter(result));
-         
          result.getResult();
                   
-         //Now we know the deliverer has delivered any outstanding messages to the client buffer
+         // Now we know the deliverer has delivered any outstanding messages to the client buffer
          
          messageQueue.deliver(false);
       }
@@ -444,8 +457,25 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " more");
       }
    }
-   
-   
+
+   public void confirmDelivery(int count)
+   {
+      synchronized(messagesInTransitLock)
+      {
+         messagesInTransitCount -= count;
+
+         if (trace) { log.trace("confirming delivery of " + count + " message(s), messages in transit " + messagesInTransitCount); }
+
+         if (messagesInTransitCount < 0)
+         {
+            log.error(this + " has an invalid messages in transit count (" +
+                      messagesInTransitCount + ")");
+         }
+
+         messagesInTransitLock.notifyAll();
+      }
+   }
+
    // Public --------------------------------------------------------
    
    public String toString()
@@ -573,18 +603,56 @@
       messageQueue.deliver(false);
    }
    
-   protected void cancelDelivery(Long messageID) throws Throwable
+   protected void sendToDLQ(Long messageID, Transaction tx) throws Throwable
    {
       Delivery del = (Delivery)deliveries.remove(messageID);
+      
       if (del != null)
-      {     
-          del.cancel();
+      { 
+         log.warn(del.getReference() + " has exceed maximum delivery attempts and will be sent to the DLQ");
+         
+         if (dlq != null)
+         {         
+            //reset delivery count to zero
+            del.getReference().setDeliveryCount(0);
+            
+            dlq.handle(null, del.getReference(), tx);
+            
+            del.acknowledge(tx);           
+         }
+         else
+         {
+            log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
+            
+            del.acknowledge(tx);
+         }
       }
       else
       {
-          throw new IllegalStateException("Cannot find delivery to cancel:" + id);
+         throw new IllegalStateException("Cannot find delivery to send to DLQ:" + id);
       }
+      
    }
+   
+   protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
+   {
+      Delivery del = (Delivery)deliveries.remove(messageID);
+      
+      if (del != null)
+      {                               
+         //Cancel back to the queue
+         
+         //Update the delivery count
+           
+         del.getReference().setDeliveryCount(deliveryCount);
+              
+         del.cancel();         
+      }
+      else
+      {
+         throw new IllegalStateException("Cannot find delivery to cancel:" + id);
+      }
+   }
                
    protected void start()
    {             
@@ -635,18 +703,37 @@
          // Flush any messages waiting to be sent to the client.
          this.executor.execute(new Deliverer());
          
-         // Now wait for it to execute.
-         Future result = new Future();
-         this.executor.execute(new Waiter(result));
-         result.getResult();
-             
+         if (trace) { log.trace(this + " flushed all remaining messages (if any) to the client"); }
+
          // Now we know any deliverer has delivered any outstanding messages to the client buffer.
       }
       catch (InterruptedException e)
       {
          log.warn("Thread interrupted", e);
       }
-            
+
+      // Make sure there are no messages in transit between server and client
+
+      synchronized(messagesInTransitLock)
+      {
+         int loopCount = 0;
+         while(messagesInTransitCount > 0 && loopCount < MESSAGES_IN_TRANSIT_WAIT_COUNT)
+         {
+            log.debug(this + " waiting for " + messagesInTransitCount + " message(s) in transit " +
+                      "to reach the client, " + (loopCount + 1) + " lock grab attempts.");
+            messagesInTransitLock.wait(500);
+            loopCount ++;
+         }
+
+         if (loopCount >= MESSAGES_IN_TRANSIT_WAIT_COUNT)
+         {
+            throw new IllegalStateException("Maximum number of lock grab attempts exceeded, " +
+                                            "giving up to wait for messages in transit");
+         }
+
+         if (trace) { log.trace(this + " has no messages in transit"); }
+      }
+
       // Now we know that there are no in flight messages on the way to the client consumer, but
       // there may be messages still in the toDeliver list since the client consumer might be full,
       // so we need to cancel these.
@@ -659,7 +746,7 @@
             {
                MessageProxy proxy = (MessageProxy)toDeliver.get(i);
                long id = proxy.getMessage().getMessageID();
-               cancelDelivery(new Long(id));
+               cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
             }
          }
                  
@@ -684,27 +771,7 @@
          if (trace) { log.trace(this + " removed from the queue"); }
       }
    }
-     
-   private void checkDeliveryCount(SimpleDelivery del)
-   {
-      //TODO - We need to put the message in a DLQ
-      // For now we just ack it otherwise the message will keep being retried and we'll never get
-      // anywhere
-      if (del.getReference().getDeliveryCount() > MAX_DELIVERY_ATTEMPTS)
-      {
-         log.warn(del.getReference() + " has exceed maximum delivery attempts and will be removed");
-         
-         try
-         {
-            del.acknowledge(null);
-         }
-         catch (Throwable t)
-         {
-            log.error("Failed to acknowledge delivery", t);
-         }
-      }                 
-   }
-   
+
    // Inner classes -------------------------------------------------   
    
    /*
@@ -718,8 +785,7 @@
    {
       public void run()
       {
-         // Is there anything to deliver?
-         // This is ok outside lock - is volatile.
+         // Is there anything to deliver? This is ok outside lock - is volatile.
          if (clientConsumerFull)
          {
             if (trace) { log.trace(this + " client consumer full, do nothing"); }
@@ -751,30 +817,33 @@
          
          int serverId = connection.getServerPeer().getServerPeerID();
 
+         // TODO How can we ensure that messages for the same consumer aren't delivered
+         // concurrently to the same consumer on different threads?
+
+         ClientDelivery del = new ClientDelivery(list, serverId, id);
+         MessagingMarshallable mm = new MessagingMarshallable(connection.getUsingVersion(), del);
+         Callback callback = new Callback(mm);
+
          try
          {
             if (trace) { log.trace(ServerConsumerEndpoint.this + " handing " + list.size() + " message(s) over to the remoting layer"); }
 
-            ClientDelivery del = new ClientDelivery(list, serverId, id);
+            synchronized(messagesInTransitLock)
+            {
+               connection.getCallbackHandler().handleCallback(callback);
+               messagesInTransitCount += list.size();
+            }
 
-            // TODO How can we ensure that messages for the same consumer aren't delivered
-            // concurrently to the same consumer on different threads?
-            MessagingMarshallable mm = new MessagingMarshallable(connection.getUsingVersion(), del);
-
-            MessagingMarshallable resp = (MessagingMarshallable)connection.getCallbackClient().invoke(mm);
-
             if (trace) { log.trace(ServerConsumerEndpoint.this + " handed messages over to the remoting layer"); }
 
-            HandleMessageResponse result = (HandleMessageResponse)resp.getLoad();
+            // We are NOT using Remoting's facility of acknowledging callbacks. A callback is sent
+            // asynchronously, and there is no confirmation that the callback reached the client or
+            // not.
 
-            // For now we don't look at how many messages are accepted since they all will be.
-            // The field is a placeholder for the future.
-            if (result.clientIsFull())
-            {
-               // Stop the server sending any more messages to the client.
-               // This is ok outside lock.
-               clientConsumerFull = true;
-            }
+            // TODO Previously, synchronous server-to-client invocations were used by the client
+            // to report back whether is full or not. This cannot be achieved with asynchronous
+            // callbacks, so the client must explicitely sent this information to the server,
+            // with an invocation on its own.
          }
          catch(Throwable t)
          {
@@ -872,5 +941,4 @@
          delList.add(new Long(messageID));
       }
    }
-   
 }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -21,6 +21,8 @@
   */
 package org.jboss.jms.server.endpoint;
 
+
+import java.util.ArrayList;
 import java.util.Collection;
 import java.util.HashMap;
 import java.util.HashSet;
@@ -66,6 +68,7 @@
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.RemoteQueueStub;
+import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.util.id.GUID;
 
@@ -104,14 +107,16 @@
 
    private PersistenceManager pm;
    private MessageStore ms;
+
    private DestinationManager dm;
    private IdManager idm;
    private QueuedExecutorPool pool;
    private TransactionRepository tr;
    private PostOffice postOffice;
    private int nodeId;
+   private int maxDeliveryAttempts;
+   private Queue dlq;
 
-
    // Constructors --------------------------------------------------
 
    protected ServerSessionEndpoint(int sessionID, ServerConnectionEndpoint connectionEndpoint)
@@ -134,6 +139,10 @@
 
       consumers = new HashMap();
 		browsers = new HashMap();
+      
+      dlq = sp.getDLQ();
+      tr = sp.getTxRepository();
+      maxDeliveryAttempts = sp.getMaxDeliveryAttempts();
    }
 
    // SessionDelegate implementation --------------------------------
@@ -177,12 +186,17 @@
          int prefetchSize = connectionEndpoint.getPrefetchSize();
          
          ServerConsumerEndpoint ep =
-            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(), binding.getQueue().getName(),
-                     this, selectorString, noLocal, jmsDestination, prefetchSize);
+            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+                                       binding.getQueue().getName(), this, selectorString, noLocal,
+                                       jmsDestination, prefetchSize, dlq);
+
          
          JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
          
-         ClientConsumerDelegate stub = new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(), prefetchSize);
+         ClientConsumerDelegate stub =
+            new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
+                                       prefetchSize, maxDeliveryAttempts);
+
          
          putConsumerEndpoint(consumerID, ep); // caching consumer locally
          
@@ -448,12 +462,15 @@
          int prefetchSize = connectionEndpoint.getPrefetchSize();
 
          ServerConsumerEndpoint ep =
-            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(), binding.getQueue().getName(),
-                                       this, selectorString, noLocal, jmsDestination, prefetchSize);
+            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+                                       binding.getQueue().getName(), this, selectorString, noLocal,
+                                       jmsDestination, prefetchSize, dlq);
           
          JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
-                     
-         ClientConsumerDelegate stub = new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(), prefetchSize);
+
+         ClientConsumerDelegate stub =
+            new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
+                                       prefetchSize, maxDeliveryAttempts);
                        
          putConsumerEndpoint(consumerID, ep); // caching consumer locally
          
@@ -648,8 +665,8 @@
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledge");
       }
-   }      
-         
+   }
+
    public void cancelDeliveries(List ackInfos) throws JMSException
    {
       try
@@ -658,6 +675,8 @@
           
          Set consumers = new HashSet();
          
+         List forDLQ = null;
+         
          for (int i = ackInfos.size() - 1; i >= 0; i--)
          {
             AckInfo ack = (AckInfo)ackInfos.get(i);
@@ -671,10 +690,58 @@
                throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
             }
             
-            consumer.cancelDelivery(new Long(ack.getMessageID()));
+            if (ack.getDeliveryCount() >= maxDeliveryAttempts)
+            {
+               if (forDLQ == null)
+               {
+                  forDLQ = new ArrayList();
+               }
+               
+               forDLQ.add(ack);
+            }
+            else
+            {            
+               consumer.cancelDelivery(new Long(ack.getMessageID()), ack.getDeliveryCount());
+            }
+            
             consumers.add(consumer);
          }
          
+         //Send stuff to DLQ
+         
+         if (forDLQ != null)
+         {
+            //We do this in a tx so we don't end up with the message in both the original queue
+            //and the dlq if it fails half way through
+            Transaction tx = tr.createTransaction();
+            
+            try
+            {               
+               for (int i = forDLQ.size() - 1; i >= 0; i--)
+               {
+                  AckInfo ack = (AckInfo)forDLQ.get(i);
+                  
+                  ServerConsumerEndpoint consumer =
+                     this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
+         
+                  if (consumer == null)
+                  {
+                     throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
+                  }
+                  
+                  consumer.sendToDLQ(new Long(ack.getMessageID()), tx);                              
+               }
+               
+               tx.commit();
+            }
+            catch (Throwable t)
+            {
+               tx.rollback();
+               
+               throw t;
+            }
+         }
+         
          // need to prompt delivery for all consumers
          
          for(Iterator i = consumers.iterator(); i.hasNext(); )

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -73,6 +73,12 @@
    {
       endpoint.more();
    }
+
+   public void confirmDelivery(int count)
+   {
+      endpoint.confirmDelivery(count);
+   }
+
   
    // AdvisedSupport overrides --------------------------------------
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -37,8 +37,8 @@
 
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.jms.client.remoting.CallbackServerFactory;
 import org.jboss.jms.client.remoting.HandleMessageResponse;
+import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
@@ -50,6 +50,8 @@
 import org.jboss.messaging.core.plugin.IdBlock;
 import org.jboss.remoting.InvocationRequest;
 import org.jboss.remoting.InvocationResponse;
+import org.jboss.remoting.callback.Callback;
+import org.jboss.remoting.invocation.InternalInvocation;
 import org.jboss.remoting.marshal.Marshaller;
 import org.jboss.remoting.marshal.UnMarshaller;
 import org.jboss.serial.io.JBossObjectInputStream;
@@ -81,7 +83,7 @@
 
    private static final Logger log = Logger.getLogger(JMSWireFormat.class);
    
-   private static boolean usingJBossSerialization;
+   private static boolean usingJBossSerialization = true;
 
    // The request codes  - start from zero
 
@@ -103,6 +105,7 @@
    protected static final byte HANDLE_MESSAGE_RESPONSE = 103;
    protected static final byte BROWSE_MESSAGE_RESPONSE = 104;
    protected static final byte BROWSE_MESSAGES_RESPONSE = 105;
+   protected static final byte CALLBACK_LIST = 106;
 
 
    // Static --------------------------------------------------------
@@ -122,21 +125,33 @@
    {
       trace = log.isTraceEnabled();
    }
-   
-   
 
    // Marshaller implementation -------------------------------------
 
    public void write(Object obj, OutputStream out) throws IOException
    {          
-      //Sanity check
-      if (!(out instanceof MessagingObjectOutputStream))
+      DataOutputStream dos;
+      
+      if (out instanceof DataOutputStream)
       {
-         throw new IllegalStateException("Must be MessagingObjectOutputStream");
+         dos = (DataOutputStream)out;
       }
-      
-      DataOutputStream dos = (DataOutputStream)(((MessagingObjectOutputStream)out).getUnderlyingStream());
-            
+      else
+      {
+         //Further sanity check
+         if (out instanceof ObjectOutputStream)
+         {
+            throw new IllegalArgumentException("Invalid stream - are you sure you have configured socket wrappers?");
+         }
+         
+         //This would be the case for the HTTP transport for example
+         //Wrap the stream
+         
+         //TODO Ideally remoting would let us wrap this before invoking the marshaller
+         //but this does not appear to be possible
+         dos = new DataOutputStream(out);
+      }
+                  
       handleVersion(obj, dos);
 
       try
@@ -148,9 +163,26 @@
             InvocationRequest req = (InvocationRequest)obj;
    
             Object param;
-   
-            if (req.getParameter() instanceof MessagingMarshallable)
+            
+            // Unwrap Callback.
+            if (req.getParameter() instanceof InternalInvocation)
             {
+               InternalInvocation ii = (InternalInvocation) req.getParameter();
+               Object[] params = ii.getParameters();
+               
+               if (params != null && params.length > 0 && params[0] instanceof Callback)
+               {
+                  Callback callback = (Callback) params[0];
+                  MessagingMarshallable mm = (MessagingMarshallable)callback.getParameter();
+                  param = mm.getLoad();
+               }
+               else
+               {
+                  param = req.getParameter();
+               }
+            }
+            else if (req.getParameter() instanceof MessagingMarshallable)
+            {
                param = ((MessagingMarshallable)req.getParameter()).getLoad();
             }
             else
@@ -299,6 +331,8 @@
                ClientDelivery dr = (ClientDelivery)param;
    
                dos.writeByte(CALLBACK);
+               
+               dos.writeUTF(req.getSessionId());
    
                dr.write(dos);
    
@@ -409,6 +443,37 @@
                
                if (trace) { log.trace("wrote browse message response"); }
             }
+            else if (res instanceof ArrayList &&
+                     ((ArrayList) res).size() > 0 &&
+                     ((ArrayList) res).get(0) instanceof Callback)
+            {
+               // Comes from polled Callbacks.
+               ArrayList callbackList = (ArrayList)res;
+               dos.write(CALLBACK_LIST);
+               dos.writeUTF(resp.getSessionId());
+               dos.writeInt(callbackList.size());
+               
+               Iterator it = callbackList.iterator();
+               while (it.hasNext())
+               {
+                  Callback callback = (Callback)it.next();
+
+                  // We don't use acknowledgeable push callbacks
+
+//                  Map payload = callback.getReturnPayload();
+//                  String guid = (String)payload.get(ServerInvokerCallbackHandler.CALLBACK_ID);
+//                  dos.writeUTF(guid);
+//                  String listenerId = (String)payload.get(Client.LISTENER_ID_KEY);
+//                  dos.writeUTF(listenerId);
+//                  String acks = (String)payload.get(ServerInvokerCallbackHandler.REMOTING_ACKNOWLEDGES_PUSH_CALLBACKS);
+//                  dos.writeUTF(acks);
+                  
+                  MessagingMarshallable mm = (MessagingMarshallable)callback.getParameter();
+                  ClientDelivery delivery = (ClientDelivery)mm.getLoad();
+                  delivery.write(dos);
+                  dos.flush();
+               }
+            }
             else
             {
                dos.write(SERIALIZED);
@@ -440,15 +505,29 @@
    // UnMarshaller implementation -----------------------------------
 
    public Object read(InputStream in, Map map) throws IOException, ClassNotFoundException
-   {      
-      // Sanity check
-      if (!(in instanceof MessagingObjectInputStream))
+   {            
+      DataInputStream dis;
+      
+      if (in instanceof DataInputStream)
       {
-         throw new IllegalStateException("Must be MessagingObjectInputStream");
+         dis = (DataInputStream)in;         
       }
+      else
+      {        
+         //Further sanity check
+         if (in instanceof ObjectInputStream)
+         {
+            throw new IllegalArgumentException("Invalid stream - are you sure you have configured socket wrappers?");
+         }
+         
+         //This would be the case for the HTTP transport for example
+         //Wrap the stream
+         
+         //TODO Ideally remoting would let us wrap this before invoking the marshaller
+         //but this does not appear to be possible
+         dis = new DataInputStream(in);
+      }
       
-      DataInputStream dis = (DataInputStream)(((MessagingObjectInputStream)in).getUnderlyingStream());
-
       // First byte read is always version
 
       byte version = dis.readByte();
@@ -693,18 +772,51 @@
             }
             case CALLBACK:
             {
+               String sessionId = dis.readUTF();
                ClientDelivery dr = new ClientDelivery();
                
                dr.read(dis);
+
+               // Recreate Callback.
+               MessagingMarshallable mm = new MessagingMarshallable(version, dr);
+               Callback callback = new Callback(mm);
+               InternalInvocation ii
+                  = new InternalInvocation(InternalInvocation.HANDLECALLBACK, new Object[]{callback});
+               InvocationRequest request
+                  = new InvocationRequest(sessionId, CallbackManager.JMS_CALLBACK_SUBSYSTEM,
+                                          ii, null, null, null);
    
-               InvocationRequest request =
-                  new InvocationRequest(null, CallbackServerFactory.JMS_CALLBACK_SUBSYSTEM,
-                                        new MessagingMarshallable(version, dr), null, null, null);
-   
                if (trace) { log.trace("read callback()"); }
    
                return request;
             }
+            case CALLBACK_LIST:
+            {
+               // Recreate ArrayList of Callbacks (for Callback polling).
+               String sessionId = dis.readUTF();
+               int size = dis.readInt();
+               ArrayList callbackList = new ArrayList(size);
+               for (int i = 0; i < size; i++)
+               {
+                  // We don't use acknowledgeable push callbacks
+
+//                  String guid = dis.readUTF();
+//                  String listenerId = dis.readUTF();
+//                  String acks = dis.readUTF();
+                  ClientDelivery delivery = new ClientDelivery();
+                  delivery.read(dis);
+                  MessagingMarshallable mm = new MessagingMarshallable(version, delivery);
+                  Callback callback = new Callback(mm);
+//                  HashMap payload = new HashMap();
+//                  payload.put(ServerInvokerCallbackHandler.CALLBACK_ID, guid);
+//                  payload.put(Client.LISTENER_ID_KEY, listenerId);
+//                  payload.put(ServerInvokerCallbackHandler.REMOTING_ACKNOWLEDGES_PUSH_CALLBACKS, acks);
+//                  callback.setReturnPayload(payload);
+                  callbackList.add(callback);
+               }
+
+               return new InvocationResponse(sessionId, callbackList, false, null);
+            }
             default:
             {
                throw new IllegalStateException("Invalid format type " + formatType);
@@ -823,9 +935,7 @@
          ois = new ObjectInputStream(is);
       }
       
-      Object obj = ois.readObject();
-      
-      return obj;
+      return ois.readObject();
    }
 
    // Inner classes -------------------------------------------------

Deleted: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectInputStream.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectInputStream.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectInputStream.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,201 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.server.remoting;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InvalidObjectException;
-import java.io.NotActiveException;
-import java.io.ObjectInputStream;
-import java.io.ObjectInputValidation;
-
-/**
- * A MessagingObjectInputStream
- * 
- * See comment in MessagingSerializationManager
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-public class MessagingObjectInputStream extends ObjectInputStream
-{
-   private InputStream in;
-
-   public MessagingObjectInputStream(InputStream in) throws IOException, SecurityException
-   {
-      this.in = in;     
-   }
-   
-   public InputStream getUnderlyingStream()
-   {
-      return in;
-   }
-
-   public int available() throws IOException
-   {
-      return in.available();
-   }
-
-   public void close() throws IOException
-   {
-      in.close();
-   }
-
-   public boolean equals(Object obj)
-   {
-      return in.equals(obj);
-   }
-
-   public int hashCode()
-   {
-      return in.hashCode();
-   }
-
-   public void mark(int readlimit)
-   {
-      in.mark(readlimit);
-   }
-
-   public boolean markSupported()
-   {
-      return in.markSupported();
-   }
-
-   public int read() throws IOException
-   {
-      return in.read();
-   }
-
-   public int read(byte[] b, int off, int len) throws IOException
-   {
-      return in.read(b, off, len);
-   }
-
-   public int read(byte[] b) throws IOException
-   {
-      return in.read(b);
-   }
-
-   public void reset() throws IOException
-   {
-      in.reset();
-   }
-
-   public long skip(long n) throws IOException
-   {
-      return in.skip(n);
-   }
-
-   public String toString()
-   {
-      return in.toString();
-   }
-
-   public void defaultReadObject() throws IOException, ClassNotFoundException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public boolean readBoolean() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public byte readByte() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public char readChar() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public double readDouble() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public GetField readFields() throws IOException, ClassNotFoundException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public float readFloat() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void readFully(byte[] buf, int off, int len) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void readFully(byte[] buf) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public int readInt() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public long readLong() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public short readShort() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public Object readUnshared() throws IOException, ClassNotFoundException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public int readUnsignedByte() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public int readUnsignedShort() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public String readUTF() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void registerValidation(ObjectInputValidation obj, int prio) throws NotActiveException, InvalidObjectException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-}

Deleted: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectOutputStream.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectOutputStream.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingObjectOutputStream.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,168 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.server.remoting;
-
-import java.io.IOException;
-import java.io.ObjectOutputStream;
-import java.io.OutputStream;
-
-/**
- * A MessagingObjectOutputStream
- * 
- * See comment in MessagingSerializationManager
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-public class MessagingObjectOutputStream extends ObjectOutputStream
-{
-   private OutputStream out;
-   
-   public MessagingObjectOutputStream(OutputStream out) throws IOException
-   {
-      this.out = out;
-   }
-   
-   public OutputStream getUnderlyingStream()
-   {
-      return out;
-   }
-
-   public void close() throws IOException
-   {
-      out.close();
-   }
-
-   public boolean equals(Object obj)
-   {
-      return out.equals(obj);
-   }
-
-   public void flush() throws IOException
-   {
-      out.flush();
-   }
-
-   public void write(byte[] b, int off, int len) throws IOException
-   {
-      out.write(b, off, len);
-   }
-
-   public void write(byte[] b) throws IOException
-   {
-      out.write(b);
-   }
-
-   public void write(int b) throws IOException
-   {
-      out.write(b);
-   }
-
-   public void defaultWriteObject() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public PutField putFields() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void reset() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void useProtocolVersion(int version) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeBoolean(boolean val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeByte(int val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeBytes(String str) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeChar(int val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeChars(String str) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeDouble(double val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeFields() throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeFloat(float val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeInt(int val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeLong(long val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeShort(int val) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeUnshared(Object obj) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void writeUTF(String str) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-}

Deleted: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingSerializationManager.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingSerializationManager.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MessagingSerializationManager.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,83 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.server.remoting;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.ObjectInputStream;
-import java.io.ObjectOutputStream;
-import java.io.OutputStream;
-
-import org.jboss.remoting.serialization.IMarshalledValue;
-import org.jboss.remoting.serialization.SerializationManager;
-
-/**
- * A MessagingSerializationManager
- * 
- * This class and the related ObjectInputStream and ObjectOutputStream classes
- * are a hack to work around a limitiation of JBoss remoting whereby it always assumes
- * the createInput and createOutput methods always return an ObjectInput/OutputStream
- * For the purposes of messaging we want the marshaller and the server and client invokers
- * to use the underlying stream instead, since we do not want all the extra crap that the object input/output
- * streams add to the stream (headers)
- * This should really be fixed properly in remoting
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-public class MessagingSerializationManager extends SerializationManager
-{
-   public IMarshalledValue createdMarshalledValue(Object arg0) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public ObjectInputStream createInput(InputStream in, ClassLoader cl) throws IOException
-   {
-      return new MessagingObjectInputStream(new DataInputStream(in));
-   }
-   
-   public ObjectOutputStream createOutput(OutputStream out) throws IOException
-   {
-      return new MessagingObjectOutputStream(new DataOutputStream(out));
-   }
-
-   public IMarshalledValue createMarshalledValueForClone(Object arg0) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-  
-   public Object receiveObject(InputStream arg0, ClassLoader arg1) throws IOException, ClassNotFoundException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void sendObject(ObjectOutputStream arg0, Object arg1) throws IOException
-   {
-      throw new UnsupportedOperationException();
-   }
-}

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -46,7 +46,7 @@
    public static final String VERSION_NUMBER = "VERSION_NUMBER";
    
    public static final String JMS_CLIENT_VM_ID = "JMS_CLIENT_VM_ID";
-   
+
    public static final String CF_DELEGATES = "CF_DELEGATES";
    
    public static final String SERVER_ID = "SERVER_ID";
@@ -56,4 +56,6 @@
    public static final String FAILOVER_MAP = "CF_FAIL_IND";
    
    public static final String CONNECTION_VERSION = "CONNECTION_VERSION";
+
+   public static final String MAX_DELIVERIES = "MAX_DELS";
 }

Copied: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/ServerSocketWrapper.java (from rev 1764, trunk/src/main/org/jboss/jms/server/remoting/ServerSocketWrapper.java)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -44,10 +44,8 @@
    
    protected long messageID;
    protected int consumerID;
+   protected int deliveryCount;
 
-   // One of Session.AUTO_ACKNOWLEDGE, Session.CLIENT_ACKNOWLEDGE, etc.
-   private int ackMode;
-   
    protected MessageProxy msg;
    
    // Static --------------------------------------------------------
@@ -60,28 +58,17 @@
 
    public AckInfo(MessageProxy proxy, int consumerID)
    {
-      this(proxy, consumerID, -1);
-   }
-
-   /**
-    * @param ackMode - one of Session.AUTO_ACKNOWLEDGE, Session.CLIENT_ACKNOWLEDGE, etc.
-    */
-   public AckInfo(MessageProxy proxy, int consumerID, int ackMode)
-   {
       this.msg = proxy;
       this.messageID = proxy.getMessage().getMessageID();
       this.consumerID = consumerID;
-      this.ackMode = ackMode;
    }
    
-   /**
-    * @param ackMode - one of Session.AUTO_ACKNOWLEDGE, Session.CLIENT_ACKNOWLEDGE, etc.
-    */
-   public AckInfo(long messageID, int consumerID, int ackMode)
+   //Only used for testing
+   public AckInfo(long messageID, int consumerID, int deliveryCount)
    {
       this.messageID = messageID;
       this.consumerID = consumerID;
-      this.ackMode = ackMode;
+      this.deliveryCount = deliveryCount;
    }
 
    // Public --------------------------------------------------------
@@ -106,15 +93,17 @@
    {
       return msg;
    }
-
-   /**
-    *
-    * @return one of Session.AUTO_ACKNOWLEDGE, Session.CLIENT_ACKNOWLEDGE ..., or -1 if it has not
-    *         previously set
-    */
-   public int getAckMode()
+   
+   public int getDeliveryCount()
    {
-      return ackMode;
+      if (msg == null)
+      {
+         return deliveryCount;
+      }
+      else
+      {
+         return msg.getDeliveryCount();
+      }
    }
 
    public String toString()
@@ -128,12 +117,21 @@
    {
      out.writeLong(messageID);
      out.writeInt(consumerID);
+     if (msg != null)
+     {
+        out.writeInt(msg.getDeliveryCount());
+     }
+     else
+     {
+        out.writeInt(deliveryCount);
+     }
    }
 
    public void read(DataInputStream in) throws Exception
    {
       messageID = in.readLong();
       consumerID = in.readInt();
+      deliveryCount = in.readInt();
    }
    
    // Class YYY overrides -------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -345,6 +345,11 @@
          sess.redeliver(acks);
       }  
    }
+   
+   public int size()
+   {
+      return transactions.size();
+   }
 
    // Protected ------------------------------------------------------
    

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/XMLUtil.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/XMLUtil.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/util/XMLUtil.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -64,7 +64,8 @@
 
       if (Node.CDATA_SECTION_NODE == type)
       {
-         return  n.getNodeValue();
+         //return "<![CDATA[" + n.getNodeValue() + "]]>";
+         return n.getNodeValue();
       }
 
       if (name.startsWith("#"))

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -555,8 +555,7 @@
                {
                   // Reference is not expired
 
-                  // Attempt to push the ref to a receiver, so increment the delivery count
-                  ref.incrementDeliveryCount();
+                  // Attempt to push the ref to a receiver
 
                   Delivery del = router.handle(this, ref, null);
 
@@ -564,23 +563,17 @@
                   
                   if (del == null)
                   {
-                     // No receiver, broken receiver or full receiver so we stop delivering; also
-                     // we need to decrement the delivery count, as no real delivery has been actually performed
-
+                     // No receiver, broken receiver or full receiver so we stop delivering
                      if (trace) { log.trace(this + ": no delivery returned for message" + ref + " so no receiver got the message. Delivery is now complete"); }
 
-                     ref.decrementDeliveryCount();
-                     
                      break;
                   }
                   else if (!del.isSelectorAccepted())
                   {
                      // No receiver accepted the message because no selectors matched, so we create
                      // an iterator (if we haven't already created it) to iterate through the refs
-                     // in the channel. No delivery was really performed, so we decrement the delivery count
-
-                     ref.decrementDeliveryCount();
-
+                     // in the channel. No delivery was really performed
+                     
                      if (iter == null)
                      {
                         iter = messageRefs.iterator();
@@ -788,8 +781,8 @@
       if (trace) { log.trace(this + " removed " + d + " from memory:" + removed); }
       
       return removed;
-   }     
-
+   }    
+   
    protected InMemoryCallback getCallback(Transaction tx, boolean synchronous)
    {
       InMemoryCallback callback = (InMemoryCallback) tx.getCallback(this);            
@@ -811,7 +804,9 @@
 
       return callback;
    }
+
    
+   
    protected boolean cancelInternal(Delivery del) throws Exception
    {
       if (trace) { log.trace(this + " cancelling " + del + " in memory"); }
@@ -829,9 +824,17 @@
       }
       else
       {
-         messageRefs.addFirst(del.getReference(), del.getReference().getPriority());
+         MessageReference ref = del.getReference();
          
-         if (trace) { log.trace(this + " added " + del.getReference() + " back into state"); }
+         messageRefs.addFirst(ref, ref.getPriority());
+         
+         //We may need to update the delivery count in the database
+         if (ref.isReliable())
+         {
+            pm.updateDeliveryCount(this.channelID, ref);
+         }
+         
+         if (trace) { log.trace(this + " added " + ref + " back into state"); }
       }
       
       return removed;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Routable.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Routable.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Routable.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -83,23 +83,12 @@
    void setPriority(byte priority);
 
    /**
-    * @return true if the delivery of this message had to be repeated at least once.
-    */
-   boolean isRedelivered();
-
-   void setRedelivered(boolean redelivered);
-   
-   /**
     * @return the number of times delivery has been attempted for this routable
     */
    int getDeliveryCount();
    
    void setDeliveryCount(int deliveryCount);
    
-   void incrementDeliveryCount();
-   
-   void decrementDeliveryCount();
-   
    /**
     * Binds a header. If the header map previously contained a mapping for this name, the old value
     * is replaced by the specified value.

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/message/RoutableSupport.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/message/RoutableSupport.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/message/RoutableSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -57,7 +57,6 @@
    protected long expiration;
    protected long timestamp;
    protected Map headers;
-   protected boolean redelivered;
    protected byte priority;
    protected int deliveryCount;   
 
@@ -111,7 +110,6 @@
       this.timestamp = timestamp;
       this.priority = priority;
       this.deliveryCount = deliveryCount;
-      this.redelivered = deliveryCount >= 2;
       if (headers == null)
       {
          this.headers = new HashMap();
@@ -129,7 +127,6 @@
       this.expiration = other.expiration;
       this.timestamp = other.timestamp;
       this.headers = new HashMap(other.headers);
-      this.redelivered = other.redelivered;
       this.deliveryCount = other.deliveryCount;
       this.priority = other.priority;  
    }
@@ -155,17 +152,7 @@
    {
       return timestamp;
    }
-
-   public boolean isRedelivered()
-   {
-      return redelivered;
-   }
-
-   public void setRedelivered(boolean redelivered)
-   {
-      this.redelivered = redelivered;      
-   }
-   
+ 
    public void setReliable(boolean reliable)
    {
       this.reliable = reliable;
@@ -189,10 +176,6 @@
    public void setDeliveryCount(int deliveryCount)
    {
       this.deliveryCount = deliveryCount;
-      if (deliveryCount > 0)
-      {
-         this.redelivered = true;
-      }
    }
 
    public Serializable putHeader(String name, Serializable value)
@@ -244,7 +227,7 @@
       out.writeLong(expiration);
       out.writeLong(timestamp);
       StreamUtils.writeMap(out, headers, true);
-      out.writeBoolean(redelivered);
+    //  out.writeBoolean(redelivered);
       out.writeByte(priority);
       out.writeInt(deliveryCount);
    }
@@ -264,7 +247,7 @@
       {
          headers = (HashMap)m;
       }
-      redelivered = in.readBoolean();
+     // redelivered = in.readBoolean();
       priority = in.readByte();
       deliveryCount = in.readInt();
    }

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -82,7 +82,7 @@
    // Constants -----------------------------------------------------
    
    private static final Logger log = Logger.getLogger(JDBCPersistenceManager.class); 
-   
+
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------
@@ -1402,6 +1402,57 @@
       }
    }
    
+   public void updateDeliveryCount(long channelID, MessageReference ref) throws Exception
+   {
+      TransactionWrapper wrap = new TransactionWrapper();
+      
+      PreparedStatement psReference = null;
+      
+      Connection conn = ds.getConnection();
+       
+      try
+      {                                    
+         psReference = conn.prepareStatement(getSQLStatement("UPDATE_DELIVERYCOUNT"));
+         
+         psReference.setInt(1, ref.getDeliveryCount());
+         
+         psReference.setLong(2, channelID);
+         
+         psReference.setLong(3, ref.getMessageID());
+         
+         int rows = psReference.executeUpdate();                         
+      }
+      catch (Exception e)
+      {
+         wrap.exceptionOccurred();
+         throw e;
+      }
+      finally
+      {
+         if (psReference != null)
+         {
+            try
+            {
+               psReference.close();
+            }
+            catch (Throwable t)
+            {
+            }
+         }         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Throwable t)
+            {
+            }
+         }
+         wrap.end();                        
+      }  
+   }
+   
    public void removeReference(long channelID, MessageReference ref, Transaction tx) throws Exception
    {      
       if (tx != null)
@@ -1668,7 +1719,7 @@
    public String toString()
    {
       return "JDBCPersistenceManager[" + Integer.toHexString(hashCode()) + "]";
-   }
+   }   
    
    // Package protected ---------------------------------------------
    
@@ -3229,6 +3280,7 @@
       map.put("UPDATE_RELIABLE_REFS_NOT_PAGED", "UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?");       
       map.put("SELECT_MIN_MAX_PAGE_ORD", "SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?");
       map.put("SELECT_EXISTS_REF", "SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?");
+      map.put("UPDATE_DELIVERYCOUNT", "UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?");
       //Message
       map.put("LOAD_MESSAGES",
               "SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, " +

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/SimpleMessageReference.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/SimpleMessageReference.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/SimpleMessageReference.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -74,7 +74,7 @@
    {
       this(holder.getMessage().getMessageID(), holder.getMessage().isReliable(),
            holder.getMessage().getExpiration(), holder.getMessage().getTimestamp(),
-           holder.getMessage().getHeaders(), holder.getMessage().isRedelivered(),
+           holder.getMessage().getHeaders(), holder.getMessage().getDeliveryCount(),
            holder.getMessage().getPriority(), ms);
 
       this.holder = holder;
@@ -88,7 +88,7 @@
    public SimpleMessageReference(SimpleMessageReference other)
    {
       this(other.getMessageID(), other.isReliable(), other.getExpiration(),
-           other.getTimestamp(), other.getHeaders(), other.isRedelivered(),
+           other.getTimestamp(), other.getHeaders(), other.getDeliveryCount(),
            other.getPriority(), other.ms);
       
       this.headers = other.headers;
@@ -96,11 +96,11 @@
    }
    
    protected SimpleMessageReference(long messageID, boolean reliable, long expiration,
-                                    long timestamp, Map headers, boolean redelivered,
+                                    long timestamp, Map headers, int deliveryCount,
                                     byte priority, MessageStore ms)
    {
       super(messageID, reliable, expiration, timestamp, priority, 0, headers);
-      this.redelivered = redelivered;
+      this.deliveryCount = deliveryCount;
       this.ms = ms;
    }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -40,13 +40,16 @@
    void addReference(long channelID, MessageReference ref, Transaction tx) throws Exception;
 
    void removeReference(long channelID, MessageReference ref, Transaction tx) throws Exception;
-    
+   
+   void updateDeliveryCount(long channelID, MessageReference ref) throws Exception;
+   
+
    // XA Recovery functionality
    
    List retrievePreparedTransactions() throws Exception;
       
    // Paging functionality - TODO we should split this out into its own interface
-   
+
    void pageReferences(long channelID, List references, boolean paged) throws Exception;
    
    void removeDepagedReferences(long channelID, List refs) throws Exception;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -90,10 +90,13 @@
    public List getPreparedTransactions()
    {
       ArrayList prepared = new ArrayList();
+      
       Iterator iter = globalToLocalMap.values().iterator();
+      
       while (iter.hasNext())
       {
          Transaction tx = (Transaction)iter.next();
+         
          if (tx.xid != null && tx.getState() == Transaction.STATE_PREPARED)
          {
             prepared.add(tx.getXid());
@@ -118,7 +121,9 @@
          while (iter.hasNext())
          {
             Xid xid = (Xid)iter.next();
-            Transaction tx = createTransaction(xid);            
+            
+            Transaction tx = createTransaction(xid);   
+            
             tx.state = Transaction.STATE_PREPARED;
             
             //Load the references for this transaction
@@ -145,20 +150,17 @@
 	   final Xid id = transaction.getXid();
 	   final int state = transaction.getState();
 	   
-	   if (id==null)
+	   if (id == null)
 	   {
-		   Exception ex = new Exception();
-		   log.warn("DeleteTransaction was called for non XA transaction",ex);
-		   return;
+		   throw new IllegalArgumentException("DeleteTransaction was called for non XA transaction");
 	   }
 
-	   if (state!=Transaction.STATE_COMMITTED && state!=Transaction.STATE_ROLLEDBACK)
+	   if (state != Transaction.STATE_COMMITTED && state != Transaction.STATE_ROLLEDBACK)
 	   {
 		   throw new TransactionException("Transaction with xid " + id + " can't be removed as it's not yet commited or rolledback: (Current state is " + Transaction.stateToString(state));
 	   }
 	   
-	   globalToLocalMap.remove(id);
-	   
+	   globalToLocalMap.remove(id);	   
    }
    
    public Transaction createTransaction(Xid xid) throws Exception

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/.testrc.example	2006-12-11 20:50:25 UTC (rev 1765)
@@ -15,11 +15,17 @@
 TEST_DATABASE=hsqldb
 
 #
+# The transport to run tests with. Valid values: "socket", "http". The value specified here
+# overrides the value specified in container.xml.
+#
+
+TEST_REMOTING=socket
+
+#
 # Each test can be run in clustered or non-clustered mode. However, setting CLUSTERED to "true"
 # doesn't guarantee that the test will be actually run in clustered mode, the test database must
 # be also permitting sharing over a LAN. "mysql" allows this, "hsqldb" doesn't. The test will
 # quickly fail in such a situation.
-#
 # It is also possible to configure a test to run in clustered mode by using the "-clustered"
 # switch.
 #

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/runtest
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/runtest	2006-12-11 20:50:25 UTC (rev 1765)
@@ -22,6 +22,7 @@
 ENV_TEST_DATABASE=$TEST_DATABASE
 ENV_TEST_SERIALIZATION=$TEST_SERIALIZATION
 ENV_TEST_CLUSTERED=$TEST_CLUSTERED
+ENV_TEST_REMOTING=$TEST_REMOTING
 
 if [ -z "$TARGET_CLASS" -a -f $reldir/.testrc ]; then
    . $reldir/.testrc
@@ -35,6 +36,7 @@
 if [ "$ENV_TEST_DATABASE" != "" ]; then
    TEST_DATABASE=$ENV_TEST_DATABASE
 fi
+
 if [ "$ENV_TEST_SERIALIZATION" != "" ]; then
    TEST_SERIALIZATION=$ENV_TEST_SERIALIZATION
 fi
@@ -42,6 +44,12 @@
    TEST_CLUSTERED=$ENV_TEST_CLUSTERED
 fi
 
+if [ "$ENV_TEST_REMOTING" != "" ]; then
+   TEST_REMOTING=$ENV_TEST_REMOTING
+fi
+
+TEST_REMOTING=http
+
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get
 # it from there.
@@ -104,7 +112,7 @@
     shift
 done
 
-JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.clustered=$TEST_CLUSTERED -Dbuild.lib=../../output/lib"
+JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.clustered=$TEST_CLUSTERED -Dtest.remoting=$TEST_REMOTING -Dbuild.lib=../../output/lib"
 
 if [ "$TARGET_TEST" != "" ]; then
    TARGET_TEST="-t $TARGET_TEST"
@@ -127,7 +135,7 @@
 
 if [ "$isRemote" = "true" ]; then
 
-  export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED
+  export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED TEST_REMOTING
 
   $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_0 -use-existent-test-classpath-file -index 0
 

Modified: branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/bin/start-rmi-server	2006-12-11 20:50:25 UTC (rev 1765)
@@ -66,6 +66,10 @@
    JAVA_OPTS="$JAVA_OPTS -Dtest.server.index=$index"
 fi
 
+if [ "$TEST_REMOTING" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.remoting=$TEST_REMOTING"
+fi
+
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
 else

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -71,6 +71,11 @@
    <property name="clustering.tests.database" value="mysql"/>
 
    <!--
+        Default remoting configuration (must be overrided by tasks that need it set otherwise).
+   -->
+   <property name="test.remoting" value="socket"/>
+
+   <!--
         Project paths.
    -->
 
@@ -188,6 +193,8 @@
       <path refid="mysql.jdbc.driver.classpath"/>
       <path refid="oracle.jdbc.driver.classpath"/>
       <path refid="postgres.jdbc.driver.classpath"/>
+      <path refid="apache.tomcat.classpath"/>
+      <path refid="apache.logging.classpath"/>
    </path>
 
    <path id="stress.test.execution.classpath">
@@ -270,6 +277,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.remoting" value="${test.remoting}"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=rmiserver"/>
          -->
@@ -305,6 +313,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${stress.tests.database}"/>
          <sysproperty key="test.serialization" value="${stress.tests.serialization}"/>
+         <sysproperty key="test.remoting" value="${test.remoting}"/>
          <!-- <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=rmiserver"/> -->
          <classpath refid="stress.test.execution.classpath"/>
       </java>
@@ -331,12 +340,18 @@
    <target name="tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
       <antcall target="crash-tests"/>
       <antcall target="invm-tests"/>
-      <antcall target="remote-tests"/>
+      <antcall target="remote-tests"/>  <!-- default remoting configuration (socket) -->
+      <antcall target="remote-tests">
+         <param name="test.remoting" value="http"/>
+      </antcall>
    </target>
 
    <target name="stress-tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
       <antcall target="invm-stress-tests"/>
-      <antcall target="remote-stress-tests"/>
+      <antcall target="remote-stress-tests"/>  <!-- default remoting configuration (socket) -->
+      <antcall target="remote-stress-tests">
+         <param name="test.remoting" value="http"/>
+      </antcall>
    </target>
 
    <target name="invm-tests" depends="tests-jar, prepare-testdirs, clear-test-logs"
@@ -379,6 +394,7 @@
                <exclude name="**/jms/MemLeakTest.class"/>
                <exclude name="**/jms/manual/**/*Test.class"/>
                <exclude name="**/jms/clustering/*Test.class"/>
+               <exclude name="**/jms/RemotingConnectionConfigurationTest.class"/>
             </fileset>
          </batchtest>
       </junit>
@@ -506,7 +522,7 @@
       <mkdir dir="${build.tests.reports}"/>
 
       <echo message=""/>
-      <echo message="Running remote tests, fork=${junit.fork}, junit.batchtest.fork=${junit.batchtest.fork}"/>
+      <echo message="Running remote tests, fork=${junit.fork}, junit.batchtest.fork=${junit.batchtest.fork}, remoting=${test.remoting}"/>
       <echo message=""/>
 
       <junit printsummary="${junit.printsummary}"
@@ -522,6 +538,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.remoting" value="${test.remoting}"/>
          <jvmarg value="-Xmx512M"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
@@ -542,9 +559,9 @@
             usefile="${junit.formatter.usefile}" extension="-Remote.xml"/>
          -->
 
-         <sysproperty key="messaging-test-configuration" value="Remote"/>
+         <sysproperty key="messaging-test-configuration" value="Remote-${test.remoting}"/>
          <formatter classname="org.jboss.test.messaging.tools.ant.XMLJUnitMultipleResultFormatter"
-                    usefile="${junit.formatter.usefile}" extension="-Remote.xml"/>
+                    usefile="${junit.formatter.usefile}" extension="-Remote-${test.remoting}.xml"/>
 
          <batchtest fork="${junit.batchtest.fork}"
                     todir="${junit.batchtest.todir}"
@@ -592,6 +609,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${stress.tests.database}"/>
          <sysproperty key="test.serialization" value="${stress.tests.serialization}"/>
+         <sysproperty key="test.remoting" value="${test.remoting}"/>
          <jvmarg value="-Xmx512M"/>
          <!-- <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=unittest"/> -->
          <classpath>
@@ -609,9 +627,9 @@
             usefile="${junit.formatter.usefile}" extension="-Remote.xml"/>
          -->
 
-         <sysproperty key="messaging-test-configuration" value="StressRemote"/>
+         <sysproperty key="messaging-test-configuration" value="StressRemote-${test.remoting}"/>
          <formatter classname="org.jboss.test.messaging.tools.ant.XMLJUnitMultipleResultFormatter"
-                    usefile="${junit.formatter.usefile}" extension="-StressRemote.xml"/>
+                    usefile="${junit.formatter.usefile}" extension="-StressRemote-${test.remoting}.xml"/>
 
          <batchtest fork="${junit.batchtest.fork}"
                     todir="${junit.batchtest.todir}"
@@ -762,42 +780,136 @@
       description="Runs crash tests">
 
       <antcall target="stop-rmi-server"/>
+
+      <!--
+          ClientCrashTest over "socket"
+      -->
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">
          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTest"/>
       </antcall>
 
+      <!--
+          ClientCrashTest over "http"
+      -->
+
+      <antcall target="start-rmi-server">
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <antcall target="crash-test">
+         <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTest"/>
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <!--
+          ClientCrashTwoConnectionsTest over "socket"
+      -->
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">
          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTwoConnectionsTest"/>
       </antcall>
 
+      <!--
+          ClientCrashTwoConnectionsTest over "http"
+      -->
+
+      <antcall target="start-rmi-server">
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <antcall target="crash-test">
+         <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTwoConnectionsTest"/>
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <!--
+          ClientCrashNegativeLeaseTest over "socket"
+      -->
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">
-          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashNegativeLeaseTest"/>
+         <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashNegativeLeaseTest"/>
       </antcall>
 
+      <!--
+          ClientCrashNegativeLeaseTest over "http"
+      -->
+
+      <antcall target="start-rmi-server">
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <antcall target="crash-test">
+         <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashNegativeLeaseTest"/>
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <!--
+          ClientCrashZeroLeaseTest over "socket"
+      -->
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">
           <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashZeroLeaseTest"/>
       </antcall>
 
+      <!--
+          ClientCrashZeroLeaseTest over "http"
+      -->
+
+      <antcall target="start-rmi-server">
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <antcall target="crash-test">
+         <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashZeroLeaseTest"/>
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <!--
+          ClientCrashLargeLeaseTest over "socket"
+      -->
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">
           <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashLargeLeaseTest"/>
       </antcall>
 
+      <!--
+          ClientCrashLargeLeaseTest over "http"
+      -->
+
+      <antcall target="start-rmi-server">
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <antcall target="crash-test">
+          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashLargeLeaseTest"/>
+         <param name="test.remoting" value="http"/>
+      </antcall>
+
+      <!--
+          CallbackFailureTest over "socket"
+      -->
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">
           <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.CallbackFailureTest"/>
       </antcall>
 
+      <!--
+          CallbackFailureTest over "http" does not make sense
+      -->
+
    </target>
 
 
@@ -816,6 +928,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.remoting" value="${test.remoting}"/>
          <jvmarg value="-Xmx512M"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
@@ -836,9 +949,9 @@
             usefile="${junit.formatter.usefile}" extension="-Remote.xml"/>
          -->
 
-         <sysproperty key="messaging-test-configuration" value="Crash"/>
+         <sysproperty key="messaging-test-configuration" value="Crash-${test.remoting}"/>
          <formatter classname="org.jboss.test.messaging.tools.ant.XMLJUnitMultipleResultFormatter"
-                    usefile="${junit.formatter.usefile}" extension="-Crash.xml"/>
+                    usefile="${junit.formatter.usefile}" extension="-Crash-${test.remoting}.xml"/>
 
          <test name="${crash.test.name}"
                fork="true"

Modified: branches/Branch_Client_Failover_Experiment/tests/etc/container.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/etc/container.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -68,6 +68,10 @@
 
    <serialization-type>jms</serialization-type>
 
+   <!--
+       Supported values: "socket", "http"
+   -->
+   <remoting-transport>socket</remoting-transport>
 
    <!--
       Specifies whether to start a clustered messaging server or not. If "test.clustered" is set,

Modified: branches/Branch_Client_Failover_Experiment/tests/smoke/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/smoke/build.xml	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/smoke/build.xml	2006-12-11 20:50:25 UTC (rev 1765)
@@ -29,6 +29,7 @@
    <property name="run.queue.example" value="true"/>
    <property name="run.topic.example" value="true"/>
    <property name="run.mdb.example" value="true"/>
+   <property name="run.http.example" value="true"/>
    <property name="run.stateless.example" value="true"/>
    <property name="run.ejb3mdb.example" value="false"/>
    <property name="run.secure-socket.example" value="true"/>
@@ -76,12 +77,13 @@
 
       <!-- 4.0.0, 4.0.1 NOT SUPPORTED -->
 
+      <!--
+          Note on installer versions.
+          When installing versions to test via the JBoss installer, make sure call by value is *not*
+          selected in the installation process. The reason for testing installer versions is to test
+          the arrangement where JBoss is configured for all pass by reference
+      -->
 
-      <!-- Note on installer versions.
-      When installing versions to test via the JBoss installer, make sure call by value is *not*
-      selected in the installation process. The reason for testing installer versions is to test
-      the arrangement where JBoss is configured for all pass by reference -->
-
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss401sp1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
@@ -311,6 +313,12 @@
          <param name="jboss.home" value="${jboss.home}"/>
       </antcall>
 
+      <antcall target="run-example">
+         <param name="example.name" value="http"/>
+         <param name="example.queue.name" value="SmokeTestQueue"/>
+         <param name="jboss.home" value="${jboss.home}"/>
+      </antcall>
+
       <!-- ====================================================  -->
       <!--                                                       -->
       <!--  End of example list                                  -->
@@ -451,6 +459,10 @@
                <equals arg1="${example.name}" arg2="secure-socket"/>
                <istrue value="${run.secure-socket.example}"/>
             </and>
+            <and>
+               <equals arg1="${example.name}" arg2="http"/>
+               <istrue value="${run.http.example}"/>
+            </and>
          </or>
       </condition>
       <antcall target="run-example-internal"/>

Modified: branches/Branch_Client_Failover_Experiment/tests/smoke/smoke.properties.example
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/smoke/smoke.properties.example	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/smoke/smoke.properties.example	2006-12-11 20:50:25 UTC (rev 1765)
@@ -4,17 +4,20 @@
 
 #JBoss AS 4.0.0 and 4.0.1 are not supported
 
-jboss401sp1.home=C:\\dev\jboss-4.0.1sp1-src\\build\\output\\jboss-4.0.1sp1
-jboss402.home=C:\\dev\\jboss-4.0.2-src\\build\\output\\jboss-4.0.2
-jboss403SP1.home=C:\\dev\\jboss-4.0.3SP1-src\\build\\output\\jboss-4.0.3SP1
-jboss403SP1-installer.home=C:\\dev\\jboss-4.0.3SP1-installer
-jboss404GA.home=C:\\dev\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
-jboss404GA-installer.home=C:\\dev\\jboss-4.0.4.GA0-installer
-jboss405GA.home=C:\\dev\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA
-jboss405GA-installer.home=C:\\dev\\jboss-4.0.5.GA-installer
-jboss405GAejb3.home=C:\\dev\\jboss-4.0.5.GA-installer-ejb3
+jboss401sp1.home=C:\\work\\src\\jboss-4.0.1sp1-src\\build\\output\\jboss-4.0.1sp1
+jboss402.home=C:\\work\\src\\jboss-4.0.2-src\\build\\output\\jboss-4.0.2
+jboss403.home=C:\\work\\src\\jboss-4.0.3-src\\build\\output\\jboss-4.0.3
+jboss403-installer.home=C:\\work\\jnlp\\jboss-4.0.3
+jboss403SP1.home=C:\\work\\src\\jboss-4.0.3SP1-src\\build\\output\\jboss-4.0.3SP1
+jboss403SP1-installer.home=C:\\work\\jnlp\\jboss-4.0.3SP1
+jboss404GA.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
+jboss404GA-installer.home=C:\\work\\jnlp\\jboss-4.0.4.GA
+jboss405GA.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA
+jboss405GA-installer.home=C:\\work\\jnlp\\jboss-4.0.5.GA
 
+jboss500Alpha.home=C:\\work\\src\\cvs\\jboss-head\\build\\output\\jboss-5.0.0.Alpha
+
 #
 # Compatibility test configuration
 #
-jboss.compatibility.home=C:\\work\\messaging-compatibility\\jboss-4.0.4.GA
+jboss.compatibility.home=C:\\work\\messaging-compatibility\\jboss-4.0.5.GA

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -884,7 +884,7 @@
       assertEquals(m1.isExpired(), m2.isExpired());
       assertEquals(m1.getTimestamp(), m2.getTimestamp());
       assertEquals(m1.getPriority(), m2.getPriority());
-      assertEquals(m1.isRedelivered(), m2.isRedelivered());
+      assertEquals(m1.getDeliveryCount(), m2.getDeliveryCount());
       Map m1Headers = m1.getHeaders();
       Map m2Headers = m2.getHeaders();
       checkMapsEquivalent(m1Headers, m2Headers);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/MessageStoreTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/MessageStoreTestBase.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/base/MessageStoreTestBase.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -72,7 +72,7 @@
       assertEquals(m.getExpiration(), ref.getExpiration());
       assertEquals(m.getTimestamp(), ref.getTimestamp());
       assertEquals(m.getPriority(), ref.getPriority());
-      assertFalse(ref.isRedelivered());
+      assertEquals(0, ref.getDeliveryCount());
 
       Map messageHeaders = m.getHeaders();
       Map refHeaders = ref.getHeaders();

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -157,14 +157,20 @@
          pub.publish(m);
          sess.commit();
          
+         log.info("sent messages");
+         
          //receive but rollback
          TextMessage m2 = (TextMessage)sub.receive(3000);
+         
+         log.info("received");
             
          assertNotNull(m2);
          assertEquals("testing123", m2.getText());
          
          sess.rollback();
          
+         log.info("rolled back");
+         
          conn.close();
          conn = cf.createTopicConnection();
          conn.start();

Deleted: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/CallbackServerFactoryTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/CallbackServerFactoryTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/CallbackServerFactoryTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1,115 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.messaging.jms;
-
-import org.jboss.jms.client.remoting.CallbackServerFactory;
-import org.jboss.remoting.InvokerLocator;
-import org.jboss.remoting.transport.Connector;
-import org.jboss.test.messaging.MessagingTestCase;
-
-/**
- * 
- * A CallbackServerFactoryTest.
- * 
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- * @version $Revision$
- *
- * $Id$
- */
-public class CallbackServerFactoryTest extends MessagingTestCase
-{
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-   
-   // Attributes ----------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public CallbackServerFactoryTest(String name)
-   {
-      super(name);
-   }
-
-   // Public --------------------------------------------------------
-   
-   public void testCallbackServer() throws Exception
-   {
-      String locatorURI1 = "socket://localhost:1234";
-      
-      String locatorURI2 = "sslsocket://localhost:4321";
-      
-      InvokerLocator locator1 = new InvokerLocator(locatorURI1);
-      
-      InvokerLocator locator2 = new InvokerLocator(locatorURI2);
-      
-      Connector server1 = CallbackServerFactory.instance.getCallbackServer(locator1);
-      
-      assertTrue(server1.isStarted());
-      
-      assertTrue(CallbackServerFactory.instance.containsCallbackServer(locator1.getProtocol()));
-      
-      Connector server2 = CallbackServerFactory.instance.getCallbackServer(locator1);
-      
-      assertTrue(server1 == server2);
-      
-      Connector server3 = CallbackServerFactory.instance.getCallbackServer(locator2);
-      
-      assertTrue(server3.isStarted());
-      
-      assertTrue(CallbackServerFactory.instance.containsCallbackServer(locator2.getProtocol()));
-      
-      Connector server4 = CallbackServerFactory.instance.getCallbackServer(locator2);
-      
-      assertTrue(server3 == server4);
-      
-      assertFalse(server1 == server3);
-      
-      
-      CallbackServerFactory.instance.stopCallbackServer(locator1.getProtocol());
-      
-      assertTrue(CallbackServerFactory.instance.containsCallbackServer(locator1.getProtocol()));
-      
-      CallbackServerFactory.instance.stopCallbackServer(locator2.getProtocol());
-      
-      assertTrue(CallbackServerFactory.instance.containsCallbackServer(locator2.getProtocol()));
-      
-      CallbackServerFactory.instance.stopCallbackServer(locator1.getProtocol());
-      
-      assertFalse(CallbackServerFactory.instance.containsCallbackServer(locator1.getProtocol()));
-      
-      CallbackServerFactory.instance.stopCallbackServer(locator2.getProtocol());
-      
-      assertFalse(CallbackServerFactory.instance.containsCallbackServer(locator2.getProtocol()));
-      
-      assertFalse(server1.isStarted());
-      
-      assertFalse(server3.isStarted());
-      
-      
-   }
-
-   
-   // Inner classes -------------------------------------------------
-
-}
-

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionFactoryTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionFactoryTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConnectionFactoryTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -266,6 +266,8 @@
                "<attribute name=\"timeout\">0</attribute>\n" +
                "<attribute name=\"serverBindAddress\">localhost</attribute>\n" +
                "<attribute name=\"leasePeriod\">20000</attribute>\n" +  
+               "<attribute name=\"clientSocketClass\" isParam=\"true\">org.jboss.jms.client.remoting.ClientSocketWrapper</attribute>\n" +
+               "<attribute name=\"serverSocketClass\">org.jboss.jms.server.remoting.ServerSocketWrapper</attribute>\n" +
             "</invoker>\n" +
             "<handlers>\n" +
                "<handler subsystem=\"JMS\">org.jboss.jms.server.remoting.JMSServerInvocationHandler</handler>\n" +

Copied: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/ConsumerClosedTest.java (from rev 1764, trunk/tests/src/org/jboss/test/messaging/jms/ConsumerClosedTest.java)

Copied: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/DLQTest.java (from rev 1764, trunk/tests/src/org/jboss/test/messaging/jms/DLQTest.java)

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -24,18 +24,19 @@
 import javax.jms.Connection;
 import javax.jms.ConnectionFactory;
 import javax.jms.DeliveryMode;
+import javax.jms.Message;
 import javax.jms.MessageConsumer;
+import javax.jms.MessageListener;
 import javax.jms.MessageProducer;
 import javax.jms.Queue;
 import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.jms.Message;
-import javax.jms.MessageListener;
+import javax.management.ObjectName;
 import javax.naming.InitialContext;
-import javax.management.ObjectName;
 
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
+
 import EDU.oswego.cs.dl.util.concurrent.Slot;
 
 /**
@@ -86,7 +87,7 @@
 
       super.tearDown();
    }
-
+   
    public void testNoop() throws Exception
    {
       log.info("noop");

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -1104,10 +1104,16 @@
 
           MessageConsumer cons1 = sess.createConsumer(queue);
 
+          log.trace("closing cons1");
+
           cons1.close();
 
+          log.trace("cons1 closed");
+
           MessageConsumer cons2 = sess.createConsumer(queue);
 
+          log.trace("cons2 created");
+
           Message r1 = cons2.receive();
           Message r2 = cons2.receive();
           Message r3 = cons2.receive();
@@ -2999,14 +3005,12 @@
       //don't acknowledge it
       sess1.close();
 
-      log.debug("sess1 closed");
-
       Session sess2 = consumerConnection.createSession(false, Session.CLIENT_ACKNOWLEDGE);
       MessageConsumer cons2 = sess2.createConsumer(queue);
       TextMessage tm3 = (TextMessage)cons2.receive(3000);
       assertNotNull(tm3);
       assertEquals("testRedeliveredDifferentSessions", tm3.getText());
-
+      
       assertTrue(tm3.getJMSRedelivered());
    }
 

Copied: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java (from rev 1764, trunk/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java)

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/SessionTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/SessionTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/SessionTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -37,8 +37,8 @@
 import javax.jms.TopicSession;
 import javax.jms.XAConnection;
 import javax.jms.XASession;
+import javax.management.ObjectName;
 import javax.naming.InitialContext;
-import javax.management.ObjectName;
 
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.JBossSession;
@@ -143,6 +143,7 @@
       
       conn.close();
       
+      assertEquals(0, cState.getResourceManager().size());
    }
 
    public void testCreateProducer() throws Exception
@@ -535,7 +536,7 @@
       conn.start();
       TextMessage rm = (TextMessage)s.createConsumer(queue).receive(1000);
 
-      assertEquals("bex", m.getText());
+      assertEquals("bex", rm.getText());
 
       conn.close();
    }

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/TransactedSessionTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/TransactedSessionTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/TransactedSessionTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -28,8 +28,8 @@
 import javax.jms.MessageProducer;
 import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.naming.InitialContext;
 import javax.management.ObjectName;
+import javax.naming.InitialContext;
 
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -589,11 +589,10 @@
          tm = (TextMessage)cons.receive();
 
          assertEquals("a message", tm.getText());
-         
-         log.info("del count2:" + tm.getIntProperty("JMSXDeliveryCount"));
+ 
+         assertEquals(2, tm.getIntProperty("JMSXDeliveryCount"));
 
          assertTrue(tm.getJMSRedelivered());
-         assertEquals(2, tm.getIntProperty("JMSXDeliveryCount"));
       }
       finally
       {

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -26,7 +26,8 @@
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
 import java.io.EOFException;
-import java.io.ObjectInputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
 import java.io.Serializable;
 import java.lang.reflect.Method;
 import java.util.ArrayList;
@@ -45,8 +46,6 @@
 import org.jboss.jms.server.endpoint.ClientDelivery;
 import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
-import org.jboss.jms.server.remoting.MessagingObjectInputStream;
-import org.jboss.jms.server.remoting.MessagingObjectOutputStream;
 import org.jboss.jms.tx.AckInfo;
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.jms.tx.TxState;
@@ -55,6 +54,8 @@
 import org.jboss.remoting.InvocationRequest;
 import org.jboss.remoting.InvocationResponse;
 import org.jboss.remoting.InvokerLocator;
+import org.jboss.remoting.callback.Callback;
+import org.jboss.remoting.invocation.InternalInvocation;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.jms.message.MessageTest;
 import org.jboss.util.id.GUID;
@@ -75,7 +76,7 @@
    private static final Logger log = Logger.getLogger(WireFormatTest.class);
 
    // TODO - replace with a dynamic value
-   private static final byte CURRENT_VERSION = 7;
+   private static final byte CURRENT_VERSION = 8;
 
    // Static --------------------------------------------------------
       
@@ -264,7 +265,8 @@
          
          long messageID = 123456;
          int consumerID = 65432;
-         AckInfo ack = new AckInfo(messageID, consumerID, -1);
+         int deliveryCount = 765;
+         AckInfo ack = new AckInfo(messageID, consumerID, deliveryCount);
          
          Object[] args = new Object[] { ack };
          
@@ -276,7 +278,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
                   
          wf.write(ir, oos);
          
@@ -309,6 +311,7 @@
          
          assertEquals(ack.getMessageID(), ack2.getMessageID());
          assertEquals(ack.getConsumerID(), ack2.getConsumerID());
+         assertEquals(ack.getDeliveryCount(), ack2.getDeliveryCount());
          
          //Now eos
          try
@@ -323,7 +326,7 @@
          
          bis.reset();
          
-         ObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
@@ -354,9 +357,9 @@
          
          mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
          
-         AckInfo ackA = new AckInfo(1524, 71627, -1);
-         AckInfo ackB = new AckInfo(987987, 45354, -1);
-         AckInfo ackC = new AckInfo(32423, 4533, -1);
+         AckInfo ackA = new AckInfo(1524, 71627, 32);
+         AckInfo ackB = new AckInfo(987987, 45354, 21);
+         AckInfo ackC = new AckInfo(32423, 4533, 6);
          
          List acks = new ArrayList();
          acks.add(ackA);
@@ -373,7 +376,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
                   
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
       
          wf.write(ir, oos);
          
@@ -409,6 +412,7 @@
          
          assertEquals(ackA.getMessageID(), ack.getMessageID());
          assertEquals(ackA.getConsumerID(), ack.getConsumerID());
+         assertEquals(ackA.getDeliveryCount(), ack.getDeliveryCount());
          
          ack = new AckInfo();
          
@@ -416,6 +420,7 @@
          
          assertEquals(ackB.getMessageID(), ack.getMessageID());
          assertEquals(ackB.getConsumerID(), ack.getConsumerID());
+         assertEquals(ackB.getDeliveryCount(), ack.getDeliveryCount());
          
          ack = new AckInfo();
          
@@ -423,6 +428,7 @@
          
          assertEquals(ackC.getMessageID(), ack.getMessageID());
          assertEquals(ackC.getConsumerID(), ack.getConsumerID());
+         assertEquals(ackC.getDeliveryCount(), ack.getDeliveryCount());
          
          
          //Now eos
@@ -438,7 +444,7 @@
          
          bis.reset();
          
-         ObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
@@ -496,7 +502,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          wf.write(ir, oos);
          
@@ -515,7 +521,7 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
                                  
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
@@ -557,7 +563,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          wf.write(ir, oos);
          
@@ -574,7 +580,7 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
             
          InvocationResponse ir2 = (InvocationResponse)wf.read(ois, null);
          
@@ -601,7 +607,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          wf.write(ir, oos);
          
@@ -618,7 +624,7 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
                   
          InvocationResponse ir2 = (InvocationResponse)wf.read(ois, null);
          
@@ -656,7 +662,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
                   
          wf.write(ir, oos);
          
@@ -707,8 +713,9 @@
          MessageTest.ensureEquivalent(m, m2);
          
          bis.reset();
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
          
+         InputStream ois = new DataInputStream(bis);
+         
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
          mm = (MessagingMarshallable)ir2.getParameter();
@@ -732,7 +739,7 @@
          JBossMessage m = new JBossMessage(123);
          MessageTest.configureMessage(m);
          
-         AckInfo info = new AckInfo(123, 456, -1);
+         AckInfo info = new AckInfo(123, 456, 66);
          
          TxState state = new TxState();
          state.getMessages().add(m);
@@ -756,7 +763,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
                   
          wf.write(ir, oos);
         
@@ -810,10 +817,11 @@
          
          assertEquals(info.getConsumerID(), info2.getConsumerID());
          assertEquals(info.getMessageID(), info2.getMessageID());
+         assertEquals(info.getDeliveryCount(), info2.getDeliveryCount());
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
@@ -851,8 +859,8 @@
          
          List ids = new ArrayList();
          
-         AckInfo ack1 = new AckInfo(1254, 78123, -1);
-         AckInfo ack2 = new AckInfo(786, 8979, -1);
+         AckInfo ack1 = new AckInfo(1254, 78123, 22);
+         AckInfo ack2 = new AckInfo(786, 8979, 461);
          ids.add(ack1);
          ids.add(ack2);
          
@@ -868,7 +876,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
                   
          wf.write(ir, oos);
         
@@ -913,9 +921,14 @@
          
          assertEquals(ack1.getMessageID(), rack1.getMessageID());
          
+         assertEquals(ack1.getDeliveryCount(), rack1.getDeliveryCount());
+         
          assertEquals(ack2.getConsumerID(), rack2.getConsumerID());
          
          assertEquals(ack2.getMessageID(), rack2.getMessageID());
+         
+         assertEquals(ack2.getDeliveryCount(), rack2.getDeliveryCount());
+         
           
          //should be eos
                 
@@ -932,7 +945,7 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
@@ -968,7 +981,7 @@
          InvocationResponse resp = new InvocationResponse(null, mm, false, null);
 
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          wf.write(resp, oos);
          oos.flush();
@@ -998,7 +1011,7 @@
          
          bis.reset();
 
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
 
          InvocationResponse ir2 = (InvocationResponse)wf.read(ois, null);
          
@@ -1028,7 +1041,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
                   
          wf.write(ir, oos);
          
@@ -1066,7 +1079,7 @@
          }
          
          bis.reset();
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
@@ -1111,11 +1124,11 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          MessagingMarshallable mm = new MessagingMarshallable((byte)77, dr);
          
-         InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null);
+         InvocationRequest ir = new InvocationRequest("dummySessionId", null, mm, null, null, null);
          
          wf.write(ir, oos);
          
@@ -1133,6 +1146,9 @@
          //Second byte should be CALLBACK
          assertEquals(JMSWireFormat.CALLBACK, dis.readByte());
          
+         //Next should be sessionID
+         assertEquals("dummySessionId", dis.readUTF());
+         
          //Next int should be server id
          assertEquals(76543, dis.readInt());
          
@@ -1196,12 +1212,20 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
          
-         mm = (MessagingMarshallable)ir2.getParameter();
+         InternalInvocation ii = (InternalInvocation) ir2.getParameter();
          
+         Object[] parameters = ii.getParameters();
+         
+         assertNotNull(parameters);
+         
+         Callback callback = (Callback) parameters[0];
+         
+         mm = (MessagingMarshallable)callback.getParameter();
+         
          assertEquals(77, mm.getVersion());
                   
          ClientDelivery dr2 = (ClientDelivery)mm.getLoad();
@@ -1239,7 +1263,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          wf.write(ir, oos);
          
@@ -1276,7 +1300,7 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationResponse ir2 = (InvocationResponse)wf.read(ois, null);
          
@@ -1300,7 +1324,7 @@
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
-         MessagingObjectOutputStream oos = new MessagingObjectOutputStream(new DataOutputStream(bos));
+         OutputStream oos = new DataOutputStream(bos);
          
          wf.write(ir, oos);
          
@@ -1337,7 +1361,7 @@
          
          bis.reset();
          
-         MessagingObjectInputStream ois = new MessagingObjectInputStream(new DataInputStream(bis));
+         InputStream ois = new DataInputStream(bis);
          
          InvocationResponse ir2 = (InvocationResponse)wf.read(ois, null);
          

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/message/JMSXDeliveryCountTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/message/JMSXDeliveryCountTest.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/message/JMSXDeliveryCountTest.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -93,7 +93,7 @@
       super.tearDown();
    }
 
-   public void testSimpleJMSXDeliverCount() throws Exception
+   public void testSimpleJMSXDeliveryCount() throws Exception
    {
       Connection conn = cf.createConnection();
       Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -127,6 +127,8 @@
    public static String USER_TRANSACTION_JNDI_NAME = "UserTransaction";
    public static String JCA_JMS_CONNECTION_FACTORY_JNDI_NAME = "java:/JCAConnectionFactory";
 
+   public static long HTTP_CONNECTOR_CALLBACK_POLL_PERIOD = 102;
+
    static
    {
       try
@@ -182,15 +184,14 @@
    private boolean transaction;
    private boolean database;
    private boolean jca;
-   private boolean remotingSocket;
-   private boolean remotingMultiplex;
+   private boolean remoting;
    private boolean security;
 
    private List toUnbindAtExit;
    private String ipAddressOrHostName;
-   
-   //There may be many service containers on the same machine, so we need to distinguish them
-   //so we don't start up multiple servers with services running on the same port
+
+   // There may be many service containers on the same machine, so we need to distinguish them
+   // so we don't start up multiple servers with services running on the same port
    private int serverIndex;
 
    // Static --------------------------------------------------------
@@ -255,7 +256,7 @@
    {
       this(servicesToStart, null);
    }
-   
+
    public ServiceContainer(String sevicesToStart, int serverIndex) throws Exception
    {
       this(sevicesToStart, null, serverIndex);
@@ -276,7 +277,7 @@
       toUnbindAtExit = new ArrayList();
       this.serverIndex = 0;
    }
-   
+
    public ServiceContainer(String sevicesToStart, TransactionManager tm, int serverIndex) throws Exception
    {
       this.tm = tm;
@@ -368,14 +369,12 @@
                                    DEFAULTDS_MANAGED_CONNECTION_POOL_OBJECT_NAME);
             startWrapperDataSourceService();
          }
-         if (remotingSocket)
+
+         if (remoting)
          {
-            startRemoting(false);
+            startRemoting();
          }
-         if (remotingMultiplex)
-         {
-            startRemoting(true);
-         }
+
          if (security)
          {
             startSecurityManager();
@@ -398,8 +397,9 @@
 
          loadJNDIContexts();
 
-         log.info("Remoting type: ........... " +
-            (remotingSocket ? "socket" : (remotingMultiplex ? "multiplex" : "disabled")));
+         String transport = config.getRemotingTransport();
+
+         log.info("Remoting type: ........... " + (remoting ? transport : "DISABLED"));
          log.info("Serialization type: ...... " + config.getSerializationType());
          log.info("Database: ................ " + config.getDatabaseType());
          log.info("Clustering mode: ......... " +
@@ -498,37 +498,37 @@
    {
       return mbeanServer.invoke(on, "getInstance", new Object[0], new String[0]);
    }
-   
+
    public Properties getPersistenceManagerSQLProperties() throws Exception
    {
       String databaseType = getDatabaseType();
 
       String persistenceConfigFile =
          "server/default/deploy/" + databaseType + "-persistence-service.xml";
-      
+
       log.info("********* Using config file: " + persistenceConfigFile);
-      
+
       URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
       if (persistenceConfigFileURL == null)
       {
          throw new Exception("Cannot find " + persistenceConfigFile + " in the classpath");
       }
-      
+
       ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
-      
+
       MBeanConfigurationElement persistenceManagerConfig =
          (MBeanConfigurationElement)pdd.query("service", "PersistenceManager").iterator().next();
-      
+
       String props = persistenceManagerConfig.getAttributeValue("SqlProperties");
-      
+
       if (props != null)
-      {         
+      {
          ByteArrayInputStream is = new ByteArrayInputStream(props.getBytes());
-         
+
          Properties sqlProperties = new Properties();
-         
-         sqlProperties.load(is);      
-         
+
+         sqlProperties.load(is);
+
          return sqlProperties;
       }
       else
@@ -536,37 +536,37 @@
          return null;
       }
    }
-   
+
    public Properties getPostOfficeSQLProperties() throws Exception
    {
       String databaseType = getDatabaseType();
-      
+
       String persistenceConfigFile =
          "server/default/deploy/" + databaseType + "-persistence-service.xml";
-      
+
       log.info("********* Using config file: " + persistenceConfigFile);
-      
+
       URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
       if (persistenceConfigFileURL == null)
       {
          throw new Exception("Cannot find " + persistenceConfigFile + " in the classpath");
       }
-      
+
       ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
-      
+
       MBeanConfigurationElement postOfficeConfig =
          (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
-      
+
       String props = postOfficeConfig.getAttributeValue("SqlProperties");
-      
+
       if (props != null)
-      {         
+      {
          ByteArrayInputStream is = new ByteArrayInputStream(props.getBytes());
-         
+
          Properties sqlProperties = new Properties();
-         
-         sqlProperties.load(is);      
-         
+
+         sqlProperties.load(is);
+
          return sqlProperties;
       }
       else
@@ -574,11 +574,11 @@
          return null;
       }
    }
-   
+
    public Properties getClusteredPostOfficeSQLProperties() throws Exception
    {
       String databaseType = getDatabaseType();
-      
+
       String persistenceConfigFile;
       if (databaseType.equals("hsqldb"))
       {
@@ -590,30 +590,30 @@
          persistenceConfigFile =
             "server/default/deploy/clustered-" + databaseType + "-persistence-service.xml";
       }
-      
+
       log.info("********* Using config file: " + persistenceConfigFile);
-      
+
       URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
       if (persistenceConfigFileURL == null)
       {
          throw new Exception("Cannot find " + persistenceConfigFile + " in the classpath");
       }
-      
+
       ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
-      
+
       MBeanConfigurationElement postOfficeConfig =
          (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
-      
+
       String props = postOfficeConfig.getAttributeValue("SqlProperties");
-      
+
       if (props != null)
-      {         
+      {
          ByteArrayInputStream is = new ByteArrayInputStream(props.getBytes());
-         
+
          Properties sqlProperties = new Properties();
-         
-         sqlProperties.load(is);      
-         
+
+         sqlProperties.load(is);
+
          return sqlProperties;
       }
       else
@@ -633,7 +633,7 @@
       }
       return mbeanServer.queryNames(pattern, null);
    }
-  
+
    /**
     * Creates and registers a service based on the MBean service descriptor element. Supports
     * XMBeans. The implementing class and the ObjectName are inferred from the mbean element. If
@@ -803,7 +803,7 @@
    // Protected -----------------------------------------------------
 
    // Private -------------------------------------------------------
-   
+
    /**
     * Note that this method makes no assumption on whether the service was created or started, nor
     * does it attempt to create/start the service.
@@ -814,7 +814,7 @@
    {
       mbeanServer.registerMBean(service, on);
       log.debug(service + " registered as " + on);
-   }  
+   }
 
    private void readConfigurationFile() throws Exception
    {
@@ -1139,39 +1139,49 @@
       stopService(managedConnFactoryObjectName);
    }
 
-   private void startRemoting(boolean multiplex) throws Exception
+   private void startRemoting() throws Exception
    {
-      SerializationStreamFactory.setManagerClassName(
-               "jms", "org.jboss.jms.server.remoting.MessagingSerializationManager");
-              
       RemotingJMXWrapper mbean;
 
-      //String serializationType = config.getSerializationType();
-      
-      String serializationType = "jms";
-      
+      // TODO - use remoting-service.xml parameters, not these ...
+
+      String serializationType = config.getSerializationType();
+
+      //TODO - Actually serializationType is irrelevant since we pass a
+      //DataOutput/InputStream into the marshaller and don't use serialization apart
+      //from one specific case with a JMS ObjectMessage in which case Java serialization
+      //is always currently used - (we could make this configurable)
+
+      String transport = config.getRemotingTransport();
+
       String params = "/?marshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
                       "unmarshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
                       "serializationtype=" + serializationType + "&" +
                       "dataType=jms&" +
-                      "timeout=0&" +
                       "socket.check_connection=false&" +
-                      "leasePeriod=20000";
+                      "clientLeasePeriod=20000&" +
+                      "callbackStore=org.jboss.remoting.callback.BlockingCallbackStore&" +
+                      "clientSocketClass=org.jboss.jms.client.remoting.ClientSocketWrapper&" +
+                      "serverSocketClass=org.jboss.jms.server.remoting.ServerSocketWrapper";
 
-      int portNumber = 9111 + serverIndex;
-      
-      String locatorURI;
-      if (multiplex)
+      // specific parameters per transport
+
+      if ("http".equals(transport))
       {
-         locatorURI = "multiplex://" + ipAddressOrHostName + ":" + portNumber + params;
+         params += "&callbackPollPeriod=" + HTTP_CONNECTOR_CALLBACK_POLL_PERIOD;
       }
       else
       {
-         locatorURI = "socket://" + ipAddressOrHostName + ":" + portNumber + params;
+         params += "&timeout=0";
       }
 
-      log.debug("Using the following locator uri:" + locatorURI);
+//      int freePort = PortUtil.findFreePort(ipAddressOrHostName);
 
+      int freePort = 9111;
+      String locatorURI = transport + "://" + ipAddressOrHostName + ":" + freePort + params;
+
+      log.debug("Using locator uri: " + locatorURI);
+
       InvokerLocator locator = new InvokerLocator(locatorURI);
 
       log.debug("Started remoting connector on uri:" + locator.getLocatorURI());
@@ -1226,7 +1236,7 @@
       try
       {
          log.info("DELETING ALL DATA FROM DATABASE!");
-         
+
          InitialContext ctx = new InitialContext();
 
          TransactionManager mgr = (TransactionManager)ctx.lookup(TransactionManagerService.JNDI_NAME);
@@ -1299,7 +1309,7 @@
       }
       catch (SQLException e)
       {
-         //Ignore - tables might not exist      
+         //Ignore - tables might not exist
       }
    }
 
@@ -1322,7 +1332,7 @@
             transaction = true;
             database = true;
             jca = true;
-            remotingSocket = true;
+            remoting = true;
             security = true;
          }
          else if ("transaction".equals(tok))
@@ -1351,22 +1361,13 @@
          }
          else if ("remoting".equals(tok))
          {
-            remotingSocket = true;
+            remoting = true;
             if (minus)
             {
-               remotingSocket = false;
+               remoting = false;
             }
 
          }
-         else if ("remoting-multiplex".equals(tok))
-         {
-            remotingMultiplex = true;
-            if (minus)
-            {
-               remotingMultiplex = false;
-            }
-
-         }
          else if ("security".equals(tok))
          {
             security = true;
@@ -1380,7 +1381,7 @@
             transaction = false;
             database = false;
             jca = false;
-            remotingSocket = false;
+            remoting = false;
             security = false;
          }
          else

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -76,6 +76,7 @@
    private String database;
    private Map dbConfigurations;
    private String serializationType;
+   private String remotingTransport;
    private Boolean clusteredMode;
 
    // Constructors --------------------------------------------------
@@ -142,6 +143,14 @@
    {
       return serializationType;
    }
+   
+   /**
+    * @return the transport the container wants the Remoting Connector to use.
+    */
+   public String getRemotingTransport()
+   {
+      return remotingTransport;
+   }
 
    /**
     * @return the clustered mode in which the container should run an individual test.
@@ -162,6 +171,7 @@
       Reader reader = new InputStreamReader(is);
       String currentDatabase = null;
       String currentSerializationType = null;
+      String currentRemotingTransport = null;
       boolean currentClusteredMode = DEFAULT_CLUSTERED_MODE;
 
       try
@@ -201,6 +211,10 @@
                {
                   currentSerializationType = XMLUtil.getTextContent(n);
                }
+               else if ("remoting-transport".equals(name))
+               {
+                  currentRemotingTransport = XMLUtil.getTextContent(n);
+               }
                else if ("clustered".equals(name))
                {
                   currentClusteredMode = Boolean.getBoolean(XMLUtil.getTextContent(n));
@@ -215,6 +229,7 @@
 
          setCurrentDatabase(currentDatabase);
          setCurrentSerializationType(currentSerializationType);
+         setCurrentRemotingTransport(currentRemotingTransport);
          setCurrentClusteredMode(currentClusteredMode);
       }
       finally
@@ -248,6 +263,16 @@
          serializationType = xmlConfigSerializationType;
       }
    }
+   
+   private void setCurrentRemotingTransport(String xmlRemotingTransport)
+   {
+      remotingTransport = System.getProperty("test.remoting");
+      if (remotingTransport == null)
+      {
+         remotingTransport = xmlRemotingTransport;
+      }
+   }
+   
 
    /**
     * Always the value of "test.clustered" system property takes precedence over the configuration

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 16:56:06 UTC (rev 1764)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 20:50:25 UTC (rev 1765)
@@ -38,7 +38,6 @@
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
-import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
@@ -88,7 +87,7 @@
 
    // List<ObjectName>
    private List connFactoryObjectNames;
-   
+
    private int serverIndex;
 
    // Constructors --------------------------------------------------
@@ -99,11 +98,11 @@
 
       connFactoryObjectNames = new ArrayList();
    }
-   
+
    public LocalTestServer(int serverIndex)
    {
       this();
-      
+
       this.serverIndex = serverIndex;
    }
 
@@ -115,7 +114,7 @@
       {
          return;
       }
-      
+
       log.debug("starting service container");
 
       try
@@ -257,7 +256,7 @@
          // log everything else as INFO
          log.info(text);
       }
-   }   
+   }
 
    public synchronized boolean isStarted() throws Exception
    {
@@ -465,9 +464,9 @@
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
          }
-   
+
          log.debug("stopping ServerPeer's plug-in dependencies");
-               
+
          try
          {
             sc.invoke(jmsUserManagerObjectName, "stop", new Object[0], new String[0]);
@@ -481,7 +480,7 @@
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
          }
-   
+
          try
          {
             sc.invoke(postOfficeObjectName, "stop", new Object[0], new String[0]);
@@ -494,8 +493,8 @@
             //services may be started. The ones that didn't start will fail when attempting to shut
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
-         }         
-   
+         }
+
          try
          {
             sc.invoke(persistenceManagerObjectName, "stop", new Object[0], new String[0]);
@@ -573,13 +572,13 @@
       ServerPeer serverPeer = (ServerPeer)sc.getAttribute(serverPeerObjectName, "Instance");
       return serverPeer.getDestinationManager();
    }
-   
+
    public PersistenceManager getPersistenceManager() throws Exception
    {
       ServerPeer serverPeer = (ServerPeer)sc.getAttribute(serverPeerObjectName, "Instance");
       return serverPeer.getPersistenceManagerInstance();
    }
-   
+
    /**
     * Only for in-VM use!
     */
@@ -611,7 +610,7 @@
    {
       deployDestination(true, name, jndiName, clustered);
    }
-   
+
    public void deployQueue(String name, String jndiName, int fullSize, int pageSize,
                            int downCacheSize, boolean clustered) throws Exception
    {
@@ -642,7 +641,7 @@
       sc.invoke(deston, "create", new Object[0], new String[0]);
       sc.invoke(deston, "start", new Object[0], new String[0]);
    }
-   
+
    public void deployDestination(boolean isQueue,
                                  String name,
                                  String jndiName,
@@ -652,7 +651,7 @@
                                  boolean clustered) throws Exception
    {
       log.info("deploying queue, fullsize:" + fullSize + ", ps:" + pageSize + " dc size:" + downCacheSize);
-      
+
       String config =
          "<mbean code=\"org.jboss.jms.server.destination." + (isQueue ? "QueueService" : "TopicService") + "\"" +
          "       name=\"jboss.messaging.destination:service=" + (isQueue ? "Queue" : "Topic") + ",name=" + name + "\"" +
@@ -715,7 +714,7 @@
    {
       deployConnectionFactory(objectName, jndiBindings, prefetchSize, -1, -1, -1);
    }
-   
+
    public void deployConnectionFactory(String objectName,
                                        String[] jndiBindings) throws Exception
    {
@@ -736,27 +735,27 @@
          "<depends optional-attribute-name=\"ServerPeer\">jboss.messaging:service=ServerPeer</depends>\n" +
          "<depends optional-attribute-name=\"Connector\">" + ServiceContainer.REMOTING_OBJECT_NAME +
          "</depends>\n";
-      
+
       if (defaultTempQueueFullSize != -1)
       {
          config += "<attribute name=\"DefaultTempQueueFullSize\">" + defaultTempQueueFullSize + "</attribute>\n";
       }
-      
+
       if (defaultTempQueuePageSize != -1)
       {
          config += "<attribute name=\"DefaultTempQueuePageSize\">" + defaultTempQueuePageSize + "</attribute>\n";
       }
-      
+
       if (defaultTempQueueDownCacheSize != -1)
       {
          config += "<attribute name=\"DefaultTempQueueDownCacheSize\">" + defaultTempQueueDownCacheSize + "</attribute>\n";
       }
-      
+
       if (prefetchSize != -1)
       {
          config += "<attribute name=\"PrefetchSize\">" + prefetchSize + "</attribute>";
       }
-      
+
       config += "<attribute name=\"JNDIBindings\"><bindings>";
 
       for(int i = 0; i < jndiBindings.length; i++)
@@ -805,9 +804,9 @@
       Element element = (Element)sc.getAttribute(serverPeerObjectName, "DefaultSecurityConfig");
       return XMLUtil.elementToString(element);
    }
-   
+
    public Object executeCommand(Command command) throws Exception
-   { 
+   {
       return command.execute();
    }
 



From genman at noderunner.net  Mon Dec 11 16:14:34 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:34 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache       ...
Message-ID: <E1GtsTq-0003io-6c@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:34

  Modified:    src/org/jboss/cache       CacheException.java
                        Modification.java NodeImpl.java
                        NodeNotExistsException.java
                        ReplicationException.java SuspectException.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.5       +4 -2      JBossCache/src/org/jboss/cache/CacheException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/CacheException.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- CacheException.java	31 Oct 2006 15:00:15 -0000	1.4
  +++ CacheException.java	11 Dec 2006 21:14:34 -0000	1.5
  @@ -1,4 +1,4 @@
  -// $Id: CacheException.java,v 1.4 2006/10/31 15:00:15 msurtani Exp $
  +// $Id: CacheException.java,v 1.5 2006/12/11 21:14:34 genman Exp $
   
   /*
    * JBoss, the OpenSource J2EE webOS
  @@ -14,7 +14,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a>
    * @author <a href="mailto:manik at jboss.org">Manik Surtani</a>
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    *          <p/>
    *          <p><b>Revisions:</b>
    *          <p/>
  @@ -25,6 +25,8 @@
   public class CacheException extends RuntimeException
   {
   
  +   private static final long serialVersionUID = -4386393072593859164L;
  +
      public CacheException()
      {
         super();
  
  
  
  1.7       +3 -2      JBossCache/src/org/jboss/cache/Modification.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Modification.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Modification.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- Modification.java	22 Sep 2006 16:27:56 -0000	1.6
  +++ Modification.java	11 Dec 2006 21:14:34 -0000	1.7
  @@ -23,11 +23,13 @@
    * applying the changes in a modification listin reverse order.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 12, 2003
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class Modification implements Externalizable
   {
   
  +   private static final long serialVersionUID = 7463314130283897197L;
  +
      public enum ModificationType
      {
         PUT_KEY_VALUE,
  @@ -48,7 +50,6 @@
      private Object old_value = null;
      private Map data = null;
   
  -
      /**
       * Constructs a new modification.
       */
  
  
  
  1.23      +6 -2      JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- NodeImpl.java	8 Dec 2006 19:03:56 -0000	1.22
  +++ NodeImpl.java	11 Dec 2006 21:14:34 -0000	1.23
  @@ -18,7 +18,6 @@
   import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.util.MapCopy;
   
  -import java.io.ObjectStreamException;
   import java.io.Serializable;
   import java.util.AbstractSet;
   import java.util.Collections;
  @@ -825,6 +824,11 @@
      private class ChildrenNames extends AbstractSet implements Serializable
      {
   
  +      /**
  +       * Since writeReplace() returns a different class, this isn't really necessary. 
  +       */
  +      private static final long serialVersionUID = 5468697840097489795L;
  +
         @Override
         public Iterator iterator()
         {
  @@ -855,7 +859,7 @@
            return children.size();
         }
   
  -      private Object writeReplace() throws ObjectStreamException
  +      private Object writeReplace()
         {
            if (children == null)
            {
  
  
  
  1.2       +4 -2      JBossCache/src/org/jboss/cache/NodeNotExistsException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeNotExistsException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeNotExistsException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- NodeNotExistsException.java	31 Mar 2005 10:15:00 -0000	1.1
  +++ NodeNotExistsException.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -1,4 +1,4 @@
  -// $Id: NodeNotExistsException.java,v 1.1 2005/03/31 10:15:00 belaban Exp $
  +// $Id: NodeNotExistsException.java,v 1.2 2006/12/11 21:14:34 genman Exp $
   
   /*
    * JBoss, the OpenSource J2EE webOS
  @@ -16,11 +16,13 @@
    * Thrown when an operation is attempted on a non-existing node in the cache
    *
    * @author <a href="mailto:bela at jboss.com">Bela Ban</a>.
  - * @version $Id: NodeNotExistsException.java,v 1.1 2005/03/31 10:15:00 belaban Exp $
  + * @version $Id: NodeNotExistsException.java,v 1.2 2006/12/11 21:14:34 genman Exp $
    */
   
   public class NodeNotExistsException extends CacheException {
   
  +   private static final long serialVersionUID = 779376138690777440L;
  +
      public NodeNotExistsException() {
         super();
      }
  
  
  
  1.5       +3 -1      JBossCache/src/org/jboss/cache/ReplicationException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicationException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/ReplicationException.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ReplicationException.java	31 Oct 2006 14:59:58 -0000	1.4
  +++ ReplicationException.java	11 Dec 2006 21:14:34 -0000	1.5
  @@ -1,4 +1,4 @@
  -// $Id: ReplicationException.java,v 1.4 2006/10/31 14:59:58 msurtani Exp $
  +// $Id: ReplicationException.java,v 1.5 2006/12/11 21:14:34 genman Exp $
   
   /*
    * JBoss, the OpenSource J2EE webOS
  @@ -15,6 +15,8 @@
   public class ReplicationException extends CacheException
   {
   
  +   private static final long serialVersionUID = 33172388691879866L;
  +
      public ReplicationException()
      {
         super();
  
  
  
  1.2       +5 -2      JBossCache/src/org/jboss/cache/SuspectException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuspectException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/SuspectException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SuspectException.java	13 Feb 2006 08:40:05 -0000	1.1
  +++ SuspectException.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -3,9 +3,12 @@
   /**
    * Thrown when a member is suspected during remote method invocation
    * @author Bela Ban
  - * @version $Id: SuspectException.java,v 1.1 2006/02/13 08:40:05 bela Exp $
  + * @version $Id: SuspectException.java,v 1.2 2006/12/11 21:14:34 genman Exp $
    */
  -public class SuspectException extends CacheException {
  +public class SuspectException extends CacheException
  +{
  +
  +   private static final long serialVersionUID = -2965599037371850141L;
   
      public SuspectException() {
         super();
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:34 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:34 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication   ...
Message-ID: <E1GtsTq-0003iy-CT@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:34

  Modified:    src/org/jboss/cache/buddyreplication   BuddyGroup.java
                        BuddyNotInitException.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.8       +68 -60    JBossCache/src/org/jboss/cache/buddyreplication/BuddyGroup.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyGroup.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyGroup.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- BuddyGroup.java	10 May 2006 11:48:15 -0000	1.7
  +++ BuddyGroup.java	11 Dec 2006 21:14:34 -0000	1.8
  @@ -20,13 +20,21 @@
    */
   public class BuddyGroup implements Serializable //Externalizable
   {
  +   /**
  +    * Serial version.
  +    */
  +   private static final long serialVersionUID = 5391883716108410301L;
  +
       private String groupName;
  +
       private IpAddress dataOwner;
  +
       /**
        * Vector<Address> - a list of JGroups addresses
        */
       List buddies = Collections.synchronizedList(new ArrayList());
  -//    List buddies = new ArrayList();
  +
  +   //    List buddies = new ArrayList();
   
       public String getGroupName()
       {
  @@ -58,19 +66,19 @@
           this.buddies = buddies;
       }
   
  -//    public void writeExternal(ObjectOutput out) throws IOException
  -//    {
  -//        out.writeObject(groupName);
  -//        out.writeObject(dataOwner);
  -//        out.writeObject(buddies);
  -//    }
  -//
  -//    public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
  -//    {
  -//        groupName = (String) in.readObject();
  -//        dataOwner = (IpAddress) in.readObject();
  -//        buddies = (List) in.readObject();
  -//    }
  +   //    public void writeExternal(ObjectOutput out) throws IOException
  +   //    {
  +   //        out.writeObject(groupName);
  +   //        out.writeObject(dataOwner);
  +   //        out.writeObject(buddies);
  +   //    }
  +   //
  +   //    public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
  +   //    {
  +   //        groupName = (String) in.readObject();
  +   //        dataOwner = (IpAddress) in.readObject();
  +   //        buddies = (List) in.readObject();
  +   //    }
   
       public String toString()
       {
  
  
  
  1.3       +2 -0      JBossCache/src/org/jboss/cache/buddyreplication/BuddyNotInitException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyNotInitException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyNotInitException.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- BuddyNotInitException.java	10 Nov 2006 20:32:52 -0000	1.2
  +++ BuddyNotInitException.java	11 Dec 2006 21:14:34 -0000	1.3
  @@ -11,6 +11,8 @@
   public class BuddyNotInitException extends CacheException
   {
   
  +   private static final long serialVersionUID = 8968506912780922157L;
  +
      public BuddyNotInitException()
      {
      }
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:34 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:34 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/config  ...
Message-ID: <E1GtsTq-0003j5-Gs@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:34

  Modified:    src/org/jboss/cache/config  ConfigurationException.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.4       +4 -1      JBossCache/src/org/jboss/cache/config/ConfigurationException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConfigurationException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/ConfigurationException.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ConfigurationException.java	27 Nov 2006 04:49:46 -0000	1.3
  +++ ConfigurationException.java	11 Dec 2006 21:14:34 -0000	1.4
  @@ -18,6 +18,9 @@
    */
   public class ConfigurationException extends CacheException
   {
  +   
  +   private static final long serialVersionUID = -5576382839360927955L;
  + 
       private List<String> erroneousAttributes = new ArrayList<String>();
   
       public ConfigurationException(Exception e)
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:34 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:34 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction     ...
Message-ID: <E1GtsTq-0003jL-Lv@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:34

  Modified:    src/org/jboss/cache/eviction     EvictionException.java
                        ExpirationConfiguration.java NodeEntry.java
                        RegionNameConflictException.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.4       +3 -0      JBossCache/src/org/jboss/cache/eviction/EvictionException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/EvictionException.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- EvictionException.java	13 Feb 2006 16:22:07 -0000	1.3
  +++ EvictionException.java	11 Dec 2006 21:14:34 -0000	1.4
  @@ -5,6 +5,9 @@
    */
   public class EvictionException extends Exception
   {
  + 
  +   private static final long serialVersionUID = 4006783737166646935L;
  +
      public EvictionException()
      {
         super();
  
  
  
  1.3       +2 -0      JBossCache/src/org/jboss/cache/eviction/ExpirationConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/ExpirationConfiguration.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ExpirationConfiguration.java	8 Dec 2006 19:19:05 -0000	1.2
  +++ ExpirationConfiguration.java	11 Dec 2006 21:14:34 -0000	1.3
  @@ -8,6 +8,8 @@
   public class ExpirationConfiguration extends EvictionPolicyConfigBase
   {
   
  +   private static final long serialVersionUID = 47338798734219507L;
  +
      /**
       * Default key name for indicating expiration time. 
       */
  
  
  
  1.11      +2 -0      JBossCache/src/org/jboss/cache/eviction/NodeEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/NodeEntry.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeEntry.java	8 Jun 2006 17:37:39 -0000	1.10
  +++ NodeEntry.java	11 Dec 2006 21:14:34 -0000	1.11
  @@ -138,6 +138,8 @@
   
      public boolean equals(Object o)
      {
  +      if (!(o instanceof NodeEntry))
  +         return false;
         NodeEntry ne = (NodeEntry) o;
         return fqn.equals(ne.getFqn());
      }
  
  
  
  1.4       +3 -0      JBossCache/src/org/jboss/cache/eviction/RegionNameConflictException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionNameConflictException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/RegionNameConflictException.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- RegionNameConflictException.java	12 Oct 2006 23:03:58 -0000	1.3
  +++ RegionNameConflictException.java	11 Dec 2006 21:14:34 -0000	1.4
  @@ -7,6 +7,9 @@
    */
   public class RegionNameConflictException extends Exception
   {
  +
  +   private static final long serialVersionUID = -6796150029431162837L;
  +
      public RegionNameConflictException()
      {
         super();
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:34 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:34 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader   ...
Message-ID: <E1GtsTq-0003jV-QI@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:34

  Modified:    src/org/jboss/cache/loader   NodeDataExceptionMarker.java
                        NodeDataMarker.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.3       +4 -2      JBossCache/src/org/jboss/cache/loader/NodeDataExceptionMarker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeDataExceptionMarker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/NodeDataExceptionMarker.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- NodeDataExceptionMarker.java	22 Sep 2006 18:16:31 -0000	1.2
  +++ NodeDataExceptionMarker.java	11 Dec 2006 21:14:34 -0000	1.3
  @@ -6,8 +6,10 @@
   
   public class NodeDataExceptionMarker extends NodeData
   {
  -   Throwable cause;
  -   Object cacheNodeIdentity;  
  +
  +   private static final long serialVersionUID = 240199474174502551L;
  +   private Throwable cause;
  +   private Object cacheNodeIdentity;  
   
      public NodeDataExceptionMarker()
      {
  
  
  
  1.2       +3 -0      JBossCache/src/org/jboss/cache/loader/NodeDataMarker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeDataMarker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/NodeDataMarker.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- NodeDataMarker.java	31 Aug 2006 14:56:45 -0000	1.1
  +++ NodeDataMarker.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -2,6 +2,9 @@
   
   public class NodeDataMarker extends NodeData
   {
  +   
  +   private static final long serialVersionUID = 4851793846346021014L;
  +
      public NodeDataMarker()
      {
         super();      
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:34 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:34 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/lock        ...
Message-ID: <E1GtsTq-0003ju-W7@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:34

  Modified:    src/org/jboss/cache/lock        DeadlockException.java
                        LockingException.java NonBlockingWriterLock.java
                        OwnerNotExistedException.java SemaphoreLock.java
                        SimpleReadWriteLock.java UpgradeException.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.2       +4 -2      JBossCache/src/org/jboss/cache/lock/DeadlockException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DeadlockException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/DeadlockException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- DeadlockException.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ DeadlockException.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -1,4 +1,4 @@
  -// $Id: DeadlockException.java,v 1.1 2005/03/31 10:15:06 belaban Exp $
  +// $Id: DeadlockException.java,v 1.2 2006/12/11 21:14:34 genman Exp $
   
   /*
    * JBoss, the OpenSource J2EE webOS
  @@ -15,11 +15,13 @@
    * once deadlock detection is in place.
    *
    * @author Bela Ban
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class DeadlockException extends LockingException
   {
   
  +   private static final long serialVersionUID = 8651993450626741020L;
  +
      /**
       * Constructor for DeadlockException.
       *
  
  
  
  1.2       +4 -2      JBossCache/src/org/jboss/cache/lock/LockingException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockingException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockingException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LockingException.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ LockingException.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -1,4 +1,4 @@
  -// $Id: LockingException.java,v 1.1 2005/03/31 10:15:06 belaban Exp $
  +// $Id: LockingException.java,v 1.2 2006/12/11 21:14:34 genman Exp $
   
   /*
    * JBoss, the OpenSource J2EE webOS
  @@ -19,7 +19,7 @@
    * acquired within the timeout, or when a deadlock was detected.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a>.
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    *          <p/>
    *          <p><b>Revisions:</b>
    *          <p/>
  @@ -29,6 +29,8 @@
   public class LockingException extends CacheException
   {
   
  +   private static final long serialVersionUID = 5551396474793902133L;
  +   
      /**
       * A list of all nodes that failed to acquire a lock
       */
  
  
  
  1.3       +1 -7      JBossCache/src/org/jboss/cache/lock/NonBlockingWriterLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NonBlockingWriterLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/NonBlockingWriterLock.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- NonBlockingWriterLock.java	5 Apr 2005 17:19:28 -0000	1.2
  +++ NonBlockingWriterLock.java	11 Dec 2006 21:14:34 -0000	1.3
  @@ -7,12 +7,6 @@
   
   package org.jboss.cache.lock;
   
  -//import EDU.oswego.cs.dl.util.concurrent.Sync;
  -//import EDU.oswego.cs.dl.util.concurrent.Semaphore;
  -//import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
  -
  -
  -
   /**
    * NonBlockingWriterLock is a read/write lock (with upgrade) that has
    * non-blocking write lock acquisition on existing read lock(s).
  @@ -26,7 +20,7 @@
    * granted.
    *
    * @author Ben Wang
  - * @version $Id: NonBlockingWriterLock.java,v 1.2 2005/04/05 17:19:28 belaban Exp $
  + * @version $Id: NonBlockingWriterLock.java,v 1.3 2006/12/11 21:14:34 genman Exp $
    */
   public class NonBlockingWriterLock extends ReadWriteLockWithUpgrade
   {
  
  
  
  1.4       +2 -0      JBossCache/src/org/jboss/cache/lock/OwnerNotExistedException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OwnerNotExistedException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/OwnerNotExistedException.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- OwnerNotExistedException.java	13 Feb 2006 16:22:07 -0000	1.3
  +++ OwnerNotExistedException.java	11 Dec 2006 21:14:34 -0000	1.4
  @@ -11,6 +11,8 @@
   public class OwnerNotExistedException extends Exception
   {
   
  +   private static final long serialVersionUID = 2837393571654438480L;
  +
      /**
       *
       */
  
  
  
  1.2       +5 -0      JBossCache/src/org/jboss/cache/lock/SemaphoreLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SemaphoreLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/SemaphoreLock.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SemaphoreLock.java	8 Dec 2006 18:50:49 -0000	1.1
  +++ SemaphoreLock.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -11,6 +11,11 @@
   public class SemaphoreLock extends Semaphore implements Lock
   {
   
  +   /**
  +    * It's unclear why this class would be serialized. 
  +    */
  +   private static final long serialVersionUID = -15293253129957476L;
  +
      public SemaphoreLock(int permits)
      {
         super(permits);
  
  
  
  1.3       +6 -1      JBossCache/src/org/jboss/cache/lock/SimpleReadWriteLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SimpleReadWriteLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/SimpleReadWriteLock.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SimpleReadWriteLock.java	8 Dec 2006 18:50:49 -0000	1.2
  +++ SimpleReadWriteLock.java	11 Dec 2006 21:14:34 -0000	1.3
  @@ -4,8 +4,13 @@
   
   /**
    * @author Bela Ban
  - * @version $Id: SimpleReadWriteLock.java,v 1.2 2006/12/08 18:50:49 genman Exp $
  + * @version $Id: SimpleReadWriteLock.java,v 1.3 2006/12/11 21:14:34 genman Exp $
    */
   public class SimpleReadWriteLock extends ReentrantReadWriteLock {
   
  +   /**
  +    * It's unclear why this class should be serializable.
  +    */
  +   private static final long serialVersionUID = 6317491956891614462L;
  +
   }
  
  
  
  1.2       +4 -2      JBossCache/src/org/jboss/cache/lock/UpgradeException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UpgradeException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/UpgradeException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UpgradeException.java	31 Mar 2005 10:15:06 -0000	1.1
  +++ UpgradeException.java	11 Dec 2006 21:14:34 -0000	1.2
  @@ -1,4 +1,4 @@
  -// $Id: UpgradeException.java,v 1.1 2005/03/31 10:15:06 belaban Exp $
  +// $Id: UpgradeException.java,v 1.2 2006/12/11 21:14:34 genman Exp $
   
   /*
    * JBoss, the OpenSource J2EE webOS
  @@ -14,11 +14,13 @@
    * Used when a read-lock cannot be upgraded to a write-lock
    *
    * @author Bela Ban
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public class UpgradeException extends LockingException
   {
   
  +   private static final long serialVersionUID = -5683212651728276028L;
  +
      /**
       * Constructor for UpgradeException.
       *
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:35 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:35 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall      ...
Message-ID: <E1GtsTr-0003kD-57@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:35

  Modified:    src/org/jboss/cache/marshall     
                        InactiveRegionException.java
                        MarshallingException.java MethodCall.java
                        RegionNameConflictException.java
                        RegionNotFoundException.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.2       +3 -0      JBossCache/src/org/jboss/cache/marshall/InactiveRegionException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InactiveRegionException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/InactiveRegionException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- InactiveRegionException.java	13 Oct 2006 14:53:28 -0000	1.1
  +++ InactiveRegionException.java	11 Dec 2006 21:14:35 -0000	1.2
  @@ -10,6 +10,9 @@
    */
   public class InactiveRegionException extends CacheException
   {
  +   
  +   private static final long serialVersionUID = -5672201755094521936L;
  +
      public InactiveRegionException()
      {
         super();
  
  
  
  1.4       +15 -12    JBossCache/src/org/jboss/cache/marshall/MarshallingException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MarshallingException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/MarshallingException.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MarshallingException.java	7 Jun 2006 22:28:08 -0000	1.3
  +++ MarshallingException.java	11 Dec 2006 21:14:35 -0000	1.4
  @@ -7,6 +7,9 @@
    */
   public class MarshallingException extends Exception
   {
  +
  +   private static final long serialVersionUID = -5991339859063633060L;
  +
       public MarshallingException()
       {
           super();
  
  
  
  1.3       +5 -0      JBossCache/src/org/jboss/cache/marshall/MethodCall.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodCall.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/MethodCall.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MethodCall.java	30 Aug 2006 10:51:47 -0000	1.2
  +++ MethodCall.java	11 Dec 2006 21:14:35 -0000	1.3
  @@ -25,6 +25,11 @@
    */
   public class MethodCall extends org.jgroups.blocks.MethodCall
   {
  +   /**
  +    * It's unclear why this class would be serialized. 
  +    */
  +   private static final long serialVersionUID = -5316198032742449998L;
  +   
      private int methodIdInteger = -1;
   
      public MethodCall()
  
  
  
  1.5       +3 -0      JBossCache/src/org/jboss/cache/marshall/RegionNameConflictException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionNameConflictException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/RegionNameConflictException.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- RegionNameConflictException.java	12 Oct 2006 23:03:57 -0000	1.4
  +++ RegionNameConflictException.java	11 Dec 2006 21:14:35 -0000	1.5
  @@ -8,6 +8,9 @@
    */
   public class RegionNameConflictException extends Exception
   {
  +
  +   private static final long serialVersionUID = -7719282503234213209L;
  +
      public RegionNameConflictException()
      {
         super();
  
  
  
  1.5       +3 -0      JBossCache/src/org/jboss/cache/marshall/RegionNotFoundException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionNotFoundException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/RegionNotFoundException.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- RegionNotFoundException.java	12 Oct 2006 23:03:57 -0000	1.4
  +++ RegionNotFoundException.java	11 Dec 2006 21:14:35 -0000	1.5
  @@ -7,6 +7,9 @@
    */
   public class RegionNotFoundException extends Exception
   {
  + 
  +   private static final long serialVersionUID = 7321547249627414140L;
  +
      public RegionNotFoundException()
      {
         super();
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:35 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:35 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic   ...
Message-ID: <E1GtsTr-0003kN-8b@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:35

  Modified:    src/org/jboss/cache/optimistic  
                        DataVersioningException.java
                        DefaultDataVersion.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.3       +2 -0      JBossCache/src/org/jboss/cache/optimistic/DataVersioningException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataVersioningException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DataVersioningException.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- DataVersioningException.java	11 Nov 2006 19:55:19 -0000	1.2
  +++ DataVersioningException.java	11 Dec 2006 21:14:35 -0000	1.3
  @@ -11,6 +11,8 @@
   public class DataVersioningException extends CacheException
   {
   
  +   private static final long serialVersionUID = 7234086816998964356L;
  +
      public DataVersioningException()
      {
      }
  
  
  
  1.5       +5 -0      JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- DefaultDataVersion.java	6 Dec 2006 16:28:37 -0000	1.4
  +++ DefaultDataVersion.java	11 Dec 2006 21:14:35 -0000	1.5
  @@ -17,6 +17,11 @@
   {
   
      /**
  +    * Since it's serializable...
  +    */
  +   private static final long serialVersionUID = 6556186205712692626L;
  +
  +   /**
       * Version zero.
       * Assign this as the first version to your data.
       */
  
  
  


From genman at noderunner.net  Mon Dec 11 16:14:35 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:14:35 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/util  ...
Message-ID: <E1GtsTr-0003kU-Cu@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:14:35

  Modified:    src/org/jboss/cache/util  MapCopy.java
  Log:
  JBCACHE-902 - Add serialver
  
  Revision  Changes    Path
  1.5       +4 -0      JBossCache/src/org/jboss/cache/util/MapCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MapCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/util/MapCopy.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- MapCopy.java	8 Dec 2006 18:49:17 -0000	1.4
  +++ MapCopy.java	11 Dec 2006 21:14:35 -0000	1.5
  @@ -17,6 +17,8 @@
   public class MapCopy<K, V> extends AbstractMap implements Serializable
   {
   
  +   private static final long serialVersionUID = -958813082188242956L;
  +
      private Map.Entry<K, V> data[];
   
      private transient Set<Map.Entry<K, V>> entrySet;
  @@ -78,6 +80,8 @@
       */
      private static class SimpleEntry<K, V> implements Map.Entry<K, V>, Serializable
      {
  +      private static final long serialVersionUID = -6092752114794052323L;
  +
         private K key;
   
         private V value;
  
  
  


From genman at noderunner.net  Mon Dec 11 16:17:51 2006
From: genman at noderunner.net (Elias Ross)
Date: Mon, 11 Dec 2006 16:17:51 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GtsX1-0003qE-L9@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/11 16:17:51

  Modified:    src/org/jboss/cache  TreeCacheView.java
  Log:
  Still doesn't work 100% but starts.
  App should probably be removed or rewritten.
  
  Revision  Changes    Path
  1.17      +100 -144  JBossCache/src/org/jboss/cache/TreeCacheView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheView.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCacheView.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- TreeCacheView.java	18 Oct 2006 11:07:54 -0000	1.16
  +++ TreeCacheView.java	11 Dec 2006 21:17:51 -0000	1.17
  @@ -8,15 +8,36 @@
   package org.jboss.cache;
   
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.config.Configuration;
  -import org.jgroups.View;
  +import java.awt.BorderLayout;
  +import java.awt.event.ActionEvent;
  +import java.awt.event.MouseAdapter;
  +import java.awt.event.MouseEvent;
  +import java.awt.event.MouseListener;
  +import java.awt.event.WindowEvent;
  +import java.awt.event.WindowListener;
  +import java.io.File;
  +import java.util.ArrayList;
  +import java.util.HashMap;
  +import java.util.Iterator;
  +import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
  +import java.util.Vector;
   
   import javax.management.MBeanServer;
   import javax.management.MBeanServerFactory;
   import javax.management.ObjectName;
  -import javax.swing.*;
  +import javax.swing.AbstractAction;
  +import javax.swing.JFrame;
  +import javax.swing.JMenu;
  +import javax.swing.JMenuBar;
  +import javax.swing.JOptionPane;
  +import javax.swing.JPanel;
  +import javax.swing.JPopupMenu;
  +import javax.swing.JScrollPane;
  +import javax.swing.JTable;
  +import javax.swing.JTextField;
  +import javax.swing.JTree;
   import javax.swing.event.TableModelEvent;
   import javax.swing.event.TableModelListener;
   import javax.swing.event.TreeSelectionEvent;
  @@ -28,21 +49,11 @@
   import javax.swing.tree.TreeNode;
   import javax.swing.tree.TreePath;
   import javax.swing.tree.TreeSelectionModel;
  -import java.awt.*;
  -import java.awt.event.ActionEvent;
  -import java.awt.event.MouseAdapter;
  -import java.awt.event.MouseEvent;
  -import java.awt.event.MouseListener;
  -import java.awt.event.WindowEvent;
  -import java.awt.event.WindowListener;
  -import java.io.File;
  -import java.util.HashMap;
  -import java.util.Iterator;
  -import java.util.List;
  -import java.util.Map;
  -import java.util.Set;
  -import java.util.StringTokenizer;
  -import java.util.Vector;
  +
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.config.Configuration;
  +import org.jgroups.View;
   
   
   /**
  @@ -53,7 +64,7 @@
    * The view itself caches only the nodes, but doesn't cache any of the data (HashMap) associated with it. When
    * data needs to be displayed, the underlying tree will be accessed directly.
    *
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    * @author<a href="mailto:bela at jboss.org">Bela Ban</a> March 27 2003
    */
   public class TreeCacheView implements TreeCacheViewMBean
  @@ -63,7 +74,7 @@
       */
      ObjectName cache_service = null;
      TreeCacheGui gui = null;
  -   TreeCache cache;
  +   CacheSPI cache;
      Log log = LogFactory.getLog(TreeCacheView.class);
   
   
  @@ -138,11 +149,9 @@
            throw new Exception("TreeCacheView.init(): no MBeanServers found");
         srv = (MBeanServer) servers.get(0);
         log.info("init(): found MBeanServer " + srv);
  -      //cache = (TreeCacheMBean) MBeanProxyExt.create(TreeCacheMBean.class, cache_service, srv);
  -
  -      // TODO: Sort out proper JMX lookup
  -      throw new RuntimeException("Sort out proper JMX lookup");
  -
  +      cache = (CacheSPI)srv.getAttribute(this.cache_service, "Cache");
  +      System.out.println("Cache " + cache);
  +      TreeCacheGui gui = new TreeCacheGui(cache);
      }
   
   
  @@ -152,7 +161,7 @@
   
         if (!file.exists()) return;
   
  -      put(dir, null);
  +      put(Fqn.fromString(dir), null);
   
         if (file.isDirectory())
         {
  @@ -165,7 +174,7 @@
         }
      }
   
  -   void put(String fqn, Map m)
  +   void put(Fqn fqn, Map m)
      {
         try
         {
  @@ -258,7 +267,7 @@
            tree.getNotifier().addCacheListener(new MyListener());
   
            log.info("registering the tree as " + mbean_name);
  -         srv.registerMBean(tree, new ObjectName(mbean_name));
  +         srv.registerMBean(tree.getCacheMBeanInterface(), new ObjectName(mbean_name));
   
            tree.start();
   
  @@ -342,24 +351,24 @@
           TreeSelectionListener, TableModelListener
   {
      private static final long serialVersionUID = 8576324868563647538L;
  -   TreeCache cache;
  +   CacheSPI cache;
      DefaultTreeModel tree_model = null;
      Log log = LogFactory.getLog(getClass());
      JTree jtree = null;
      DefaultTableModel table_model = new DefaultTableModel();
      JTable table = new JTable(table_model);
  -   MyNode root = new MyNode(SEP);
  -   String selected_node = null;
  +   MyNode root = new MyNode(SEP.getName());
  +   Fqn selected_node = null;
      JPanel tablePanel = null;
      JMenu operationsMenu = null;
      JPopupMenu operationsPopup = null;
      JMenuBar menubar = null;
  -   static final String SEP = Fqn.SEPARATOR;
  +   static final Fqn SEP = Fqn.ROOT;
      private static final int KEY_COL_WIDTH = 20;
      private static final int VAL_COL_WIDTH = 300;
   
   
  -   public TreeCacheGui(TreeCache cache) throws Exception
  +   public TreeCacheGui(CacheSPI cache) throws Exception
      {
         this.cache = cache;
   
  @@ -499,7 +508,7 @@
               val = (String) table.getValueAt(row, col);
               if (key != null && val != null)
               {
  -               put(selected_node, key, val);
  +               cache.put(selected_node, key, val);
               }
            }
         }
  @@ -509,19 +518,16 @@
      public void valueChanged(TreeSelectionEvent evt)
      {
         TreePath path = evt.getPath();
  -      String fqn = SEP;
  -      String component_name;
  +      Fqn fqn = SEP;
  +      Object component_name;
         Map data = null;
   
         for (int i = 0; i < path.getPathCount(); i++)
         {
            component_name = ((MyNode) path.getPathComponent(i)).name;
  -         if (component_name.equals(SEP))
  +         if (component_name.equals("/"))
               continue;
  -         if (fqn.equals(SEP))
  -            fqn += component_name;
  -         else
  -            fqn = fqn + SEP + component_name;
  +         fqn = new Fqn(fqn, component_name);
         }
         data = getData(fqn);
         if (data != null)
  @@ -546,7 +552,7 @@
         {
            MyNode n, p;
   
  -         n = root.add(fqn.toString());
  +         n = root.add(fqn);
            if (n != null)
            {
               p = (MyNode) n.getParent();
  @@ -563,7 +569,7 @@
            MyNode n;
            TreeNode par;
   
  -         n = root.findNode(fqn.toString());
  +         n = root.findNode(fqn);
            if (n != null)
            {
               n.removeAllChildren();
  @@ -631,8 +637,8 @@
               Vector mbrship;
               if (new_view != null && (mbrship = new_view.getMembers()) != null)
               {
  -               _put(SEP, "members", mbrship);
  -               _put(SEP, "coordinator", mbrship.firstElement());
  +               put(SEP, "members", mbrship);
  +               put(SEP, "coordinator", mbrship.firstElement());
               }
            }
         }.start();
  @@ -661,8 +667,8 @@
         mbrship = getMembers() != null ? (Vector) getMembers().clone() : null;
         if (mbrship != null && mbrship.size() > 0)
         {
  -         _put(SEP, "members", mbrship);
  -         _put(SEP, "coordinator", mbrship.firstElement());
  +         put(SEP, "members", mbrship);
  +         put(SEP, "coordinator", mbrship.firstElement());
         }
      }
   
  @@ -679,10 +685,9 @@
      /**
       * Recursively adds GUI nodes starting from fqn
       */
  -   void addGuiNode(String fqn)
  +   void addGuiNode(Fqn fqn)
      {
         Set children;
  -      String child_name;
   
         if (fqn == null) return;
   
  @@ -691,36 +696,24 @@
   
         // 2. Then add my children
         children = getChildrenNames(fqn);
  -      if (children != null)
  -      {
  -         for (Iterator it = children.iterator(); it.hasNext();)
  -         {
  -            child_name = it.next().toString();
  -            addGuiNode(fqn + SEP + child_name);
  -         }
  +      for (Object o : children) {
  +        addGuiNode(new Fqn(fqn, o));
         }
      }
   
   
  -   String makeFQN(Object[] path)
  -   {
  -      StringBuffer sb = new StringBuffer("");
  -      String tmp_name;
  -
  -      if (path == null) return null;
  -      for (int i = 0; i < path.length; i++)
  +   Fqn makeFQN(Object[] opath)
         {
  -         tmp_name = ((MyNode) path[i]).name;
  -         if (tmp_name.equals(SEP))
  +      List l = new ArrayList();
  +      for (Object o : opath) {
  +         MyNode node = (MyNode)o;
  +         Object name = node.name;
  +         if (name.equals(Fqn.SEPARATOR))
               continue;
  -         else
  -            sb.append(SEP + tmp_name);
  +         l.add(name);
         }
  -      tmp_name = sb.toString();
  -      if (tmp_name.length() == 0)
  -         return SEP;
  -      else
  -         return tmp_name;
  +      System.out.println(" L " + l);
  +      return new Fqn(l);
      }
   
      void clearTable()
  @@ -818,29 +811,17 @@
         }
      }
   
  -   Map getData(String fqn)
  +   Map getData(Fqn fqn)
      {
  -      Map data;
  -      Set keys;
  -      String key;
  -      Object value;
  -
  -      if (fqn == null) return null;
  -      keys = getKeys(fqn);
  -      if (keys == null) return null;
  -      data = new HashMap();
  -      for (Iterator it = keys.iterator(); it.hasNext();)
  -      {
  -         key = (String) it.next();
  -         value = get(fqn, key);
  -         if (value != null)
  -            data.put(key, value);
  +      Node n = cache.getChild(fqn);
  +      if (n == null) {
  +         return null;
         }
  -      return data;
  +      return n.getData();
      }
   
   
  -   void put(String fqn, Map m)
  +   void put(Fqn fqn, Map m)
      {
         try
         {
  @@ -853,7 +834,7 @@
      }
   
   
  -   void put(String fqn, String key, Object value)
  +   void put(Fqn fqn, String key, Object value)
      {
         try
         {
  @@ -865,23 +846,11 @@
         }
      }
   
  -   void _put(String fqn, String key, Object value)
  +   Set getKeys(Fqn fqn)
      {
         try
         {
  -         cache._put(null, fqn, key, value, false);
  -      }
  -      catch (Throwable t)
  -      {
  -         log.error("TreeCacheGui._put(): " + t);
  -      }
  -   }
  -
  -   Set getKeys(String fqn)
  -   {
  -      try
  -      {
  -         return cache.getKeys(fqn);
  +         return cache.getChild(fqn).getKeys();
         }
         catch (Throwable t)
         {
  @@ -890,11 +859,11 @@
         }
      }
   
  -   Object get(String fqn, String key)
  +   Object get(Fqn fqn, String key)
      {
         try
         {
  -         return cache.get(fqn, key);
  +         return cache.getChild(fqn).getData().get(key);
         }
         catch (Throwable t)
         {
  @@ -903,11 +872,12 @@
         }
      }
   
  -   Set getChildrenNames(String fqn)
  +   Set getChildrenNames(Fqn fqn)
      {
         try
         {
  -         return cache.getChildrenNames(fqn);
  +         Node n = cache.getChild(fqn);
  +         return n.getChildrenNames();
         }
         catch (Throwable t)
         {
  @@ -920,7 +890,8 @@
      {
         try
         {
  -         return cache.getMembers();
  +         return new Vector();
  +         // return cache.getMembers();
         }
         catch (Throwable t)
         {
  @@ -951,7 +922,7 @@
         {
            JTextField fqnTextField = new JTextField();
            if (selected_node != null)
  -            fqnTextField.setText(selected_node);
  +            fqnTextField.setText(selected_node.toString());
            Object[] information = {"Enter fully qualified name",
                    fqnTextField};
            final String btnString1 = "OK";
  @@ -968,7 +939,7 @@
            if (userChoice == 0)
            {
               String userInput = fqnTextField.getText();
  -            put(userInput, null);
  +            put(Fqn.fromString(userInput), null);
            }
         }
      }
  @@ -980,7 +951,7 @@
   
         public void actionPerformed(ActionEvent e)
         {
  -         System.out.println("\n*** lock information ****\n" + cache.printLockInfo());
  +         System.out.println("\n*** lock information ****\n" + cache.getLockTable());
         }
      }
   
  @@ -990,7 +961,7 @@
   
         public void actionPerformed(ActionEvent e)
         {
  -         cache.releaseAllLocks("/");
  +         System.out.println("TODO :-)");
         }
      }
   
  @@ -1000,13 +971,9 @@
   
         public void actionPerformed(ActionEvent e)
         {
  -         //remove(selected_node);
            try
            {
  -            //server.invoke(cache_service, "remove",
  -            //            new Object[]{selected_node},
  -            //          new String[]{STRING});
  -            cache.remove(selected_node);
  +            cache.removeChild(selected_node);
            }
            catch (Throwable t)
            {
  @@ -1043,10 +1010,10 @@
      class MyNode extends DefaultMutableTreeNode
      {
         private static final long serialVersionUID = 1578599138419577069L;
  -      String name = "<unnamed>";
  +      Object name = "<unnamed>";
   
   
  -      MyNode(String name)
  +      MyNode(Object name)
         {
            this.name = name;
         }
  @@ -1056,23 +1023,17 @@
          * Adds a new node to the view. Intermediary nodes will be created if they don't yet exist.
          * Returns the first node that was created or null if node already existed
          */
  -      public MyNode add(String fqn)
  +      public MyNode add(Fqn fqn)
         {
            MyNode curr, n, ret = null;
  -         StringTokenizer tok;
  -         String child_name;
   
            if (fqn == null) return null;
            curr = this;
  -         tok = new StringTokenizer(fqn, TreeCacheGui.SEP);
  -
  -         while (tok.hasMoreTokens())
  -         {
  -            child_name = tok.nextToken();
  -            n = curr.findChild(child_name);
  +         for (Object o : fqn.peekElements()) {
  +            n = curr.findChild(o);
               if (n == null)
               {
  -               n = new MyNode(child_name);
  +               n = new MyNode(o.toString());
                  if (ret == null) ret = n;
                  curr.add(n);
               }
  @@ -1091,20 +1052,15 @@
         }
   
   
  -      MyNode findNode(String fqn)
  +      MyNode findNode(Fqn fqn)
         {
            MyNode curr, n;
  -         StringTokenizer tok;
  -         String child_name;
   
            if (fqn == null) return null;
            curr = this;
  -         tok = new StringTokenizer(fqn, TreeCacheGui.SEP);
  -
  -         while (tok.hasMoreTokens())
  +         for (Object o : fqn.peekElements())
            {
  -            child_name = tok.nextToken();
  -            n = curr.findChild(child_name);
  +            n = curr.findChild(o);
               if (n == null)
                  return null;
               curr = n;
  @@ -1113,7 +1069,7 @@
         }
   
   
  -      MyNode findChild(String relative_name)
  +      MyNode findChild(Object relative_name)
         {
            MyNode child;
   
  @@ -1146,7 +1102,7 @@
                  sb.append("/<unnamed>");
               else
               {
  -               sb.append(TreeCacheGui.SEP + name);
  +               sb.append(TreeCacheGui.SEP.toString() + name);
               }
            }
            sb.append("\n");
  @@ -1165,7 +1121,7 @@
   
         public String toString()
         {
  -         return name;
  +         return name.toString();
         }
   
      }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 16:35:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 16:35:28 -0500
Subject: [jboss-cvs] JBossAS SVN: r58980 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1Gtso4-00048C-5D@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-11 16:35:26 -0500 (Mon, 11 Dec 2006)
New Revision: 58980

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
Log:
- Forgot taglib field.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-11 20:35:58 UTC (rev 58979)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-11 21:35:26 UTC (rev 58980)
@@ -21,7 +21,6 @@
  */
 package org.jboss.web.tomcat.tc6.deployers;
 
-import java.util.Collection;
 import java.util.Iterator;
 
 import org.apache.catalina.core.StandardContext;
@@ -42,6 +41,7 @@
 import org.jboss.metadata.web.Servlet;
 import org.jboss.metadata.web.ServletMapping;
 import org.jboss.metadata.web.SessionConfig;
+import org.jboss.metadata.web.Taglib;
 
 public class JBossContextConfig extends ContextConfig {
 
@@ -132,7 +132,8 @@
       // JSP mappings
       Iterator<String> iterator10 = metaData.getJspMappings().iterator();
       while (iterator10.hasNext()) {
-         context.addJspMapping(iterator10.next());
+         String value = iterator10.next();
+         context.addJspMapping(value);
       }
     	
     	// Login configuration
@@ -242,7 +243,8 @@
     	// Welcome files
       Iterator<String> iterator13 = metaData.getWelcomeFiles().iterator();
       while (iterator13.hasNext()) {
-         context.addWelcomeFile(iterator13.next());
+         String value = iterator13.next();
+         context.addWelcomeFile(value);
       }
 
       // Session timeout
@@ -254,7 +256,14 @@
             context.setSessionTimeout(i);
          }
       }
-        
+
+      // Taglib
+      Iterator<Taglib> iterator15 = metaData.getTaglibs().iterator();
+      while (iterator15.hasNext()) {
+         Taglib value = iterator15.next();
+         context.addTaglib(value.getUri(), value.getLocation());
+      }
+      
 	}
 
 }



From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 16:36:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 16:36:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r58981 -
	trunk/server/src/main/org/jboss/metadata/web
Message-ID: <E1Gtsp4-0004AY-Mn@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-11 16:36:29 -0500 (Mon, 11 Dec 2006)
New Revision: 58981

Modified:
   trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java
Log:
- Parse the remaining web.xml elements. With a few small hacks to avoid creating useless object structures.

Modified: trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java	2006-12-11 21:35:26 UTC (rev 58980)
+++ trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java	2006-12-11 21:36:29 UTC (rev 58981)
@@ -154,6 +154,35 @@
       {
          child = new MessageDestinationMetaData();
       }
+      else if (localName.equals("mime-mapping"))
+      {
+         child = new MimeMapping();
+      }
+      else if (localName.equals("locale-encoding-mapping-list"))
+      {
+         child = dd;
+      }
+      else if (localName.equals("locale-encoding-mapping"))
+      {
+         child = new LocaleEncodingMapping();
+      }
+      else if (localName.equals("welcome-file-list"))
+      {
+         child = dd;
+      }
+      else if (localName.equals("jsp-config"))
+      {
+         child = dd;
+      }
+      else if (localName.equals("jsp-property-group"))
+      {
+         child = dd;
+      }
+      else if (localName.equals("taglib"))
+      {
+         child = new Taglib();
+      }
+
       /*
        * Currently unhandled web-app child elements: mime-mapping
        * welcome-file-list jsp-config locale-encoding-mapping-list
@@ -248,6 +277,24 @@
       parent.addFilterMapping(mapping);
    }
 
+   public void addChild(WebMetaData parent, MimeMapping mapping,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   {
+      parent.addMimeMapping(mapping);
+   }
+
+   public void addChild(WebMetaData parent, Taglib taglib,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   {
+      parent.addTaglib(taglib);
+   }
+
+   public void addChild(WebMetaData parent, LocaleEncodingMapping mapping,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   {
+      parent.addLocaleEncodingMapping(mapping);
+   }
+
    public void addChild(WebMetaData parent, Listener listener,
          UnmarshallingContext navigator, String namespaceURI, String localName)
    {
@@ -405,6 +452,14 @@
             wmd.setMetadataComplete(true);
          }
       }
+      else if(localName.equals("welcome-file"))
+      {
+         wmd.addWelcomeFile(value);
+      }
+      else if(localName.equals("url-pattern"))
+      {
+         wmd.addJspMapping(value);
+      }
    }
 
    public void setValue(ParamValue pv, UnmarshallingContext navigator,
@@ -458,6 +513,45 @@
       }
    }
 
+   public void setValue(MimeMapping mapping, UnmarshallingContext navigator,
+         String namespaceURI, String localName, String value)
+   {
+      if (localName.equals("extension"))
+      {
+         mapping.setExtension(value);
+      }
+      else if (localName.equals("mime-type"))
+      {
+         mapping.setMimeType(value);
+      }
+   }
+
+   public void setValue(Taglib taglib, UnmarshallingContext navigator,
+         String namespaceURI, String localName, String value)
+   {
+      if (localName.equals("taglib-location"))
+      {
+         taglib.setLocation(value);
+      }
+      else if (localName.equals("taglib-uri"))
+      {
+         taglib.setUri(value);
+      }
+   }
+
+   public void setValue(LocaleEncodingMapping mapping, UnmarshallingContext navigator,
+         String namespaceURI, String localName, String value)
+   {
+      if (localName.equals("locale"))
+      {
+         mapping.setLocale(value);
+      }
+      else if (localName.equals("encoding"))
+      {
+         mapping.setEncoding(value);
+      }
+   }
+
    public void setValue(ServletMapping mapping, UnmarshallingContext navigator,
          String namespaceURI, String localName, String value)
    {



From mandersen at jboss.com  Mon Dec 11 17:21:58 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Mon, 11 Dec 2006 17:21:58 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/execution
	...
Message-ID: <E1GttX4-000526-HV@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/11 17:21:58

  Modified:    hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/execution 
                        DefaultExecutionContext.java
  Log:
  HBX-830  Database errors should not be displayed in Log Error view
  HBX-837 Have seperate logs per configuration
  
  Revision  Changes    Path
  1.3       +13 -3     jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/execution/DefaultExecutionContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultExecutionContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/execution/DefaultExecutionContext.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- DefaultExecutionContext.java	7 Jul 2006 13:50:57 -0000	1.2
  +++ DefaultExecutionContext.java	11 Dec 2006 22:21:58 -0000	1.3
  @@ -22,18 +22,25 @@
   package org.hibernate.console.execution;
   
   import java.net.URLClassLoader;
  +import java.util.ArrayList;
  +import java.util.List;
   import java.util.Map;
   import java.util.WeakHashMap;
   
  -public class DefaultExecutionContext implements ExecutionContext {
  +import org.apache.log4j.NDC;
  +import org.hibernate.eclipse.logging.CurrentContext;
   
  +public class DefaultExecutionContext implements ExecutionContext {
   	
   	final private URLClassLoader configurationClassLoader;	
   	private volatile int installs;
   	private Map previousLoaders = new WeakHashMap();
   	
  -	public DefaultExecutionContext(URLClassLoader loader) {
  +	final String key;
  +	
  +	public DefaultExecutionContext(String key, URLClassLoader loader) {
   		configurationClassLoader = loader;
  +		this.key = key;
   	}
   
   	/* (non-Javadoc)
  @@ -45,6 +52,7 @@
   			previousLoaders.put(Thread.currentThread(), Thread.currentThread().getContextClassLoader() );
   			Thread.currentThread().setContextClassLoader(configurationClassLoader);
   		}		
  +		
   	}
   	
   	/* (non-Javadoc)
  @@ -52,11 +60,13 @@
   	 */
   	public Object execute(Command c) {
   		try {
  +			CurrentContext.push( key );
   			installLoader();
   			return c.execute();
   		} 
   		finally {
   			uninstallLoader();
  +			CurrentContext.pop();
   		}
   	}
   	
  
  
  


From mandersen at jboss.com  Mon Dec 11 17:22:01 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Mon, 11 Dec 2006 17:22:01 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console
	...
Message-ID: <E1GttX7-00052G-AR@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/11 17:22:00

  Modified:    hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console  
                        KnownConfigurations.java ConsoleConfiguration.java
  Log:
  HBX-830  Database errors should not be displayed in Log Error view
  HBX-837 Have seperate logs per configuration
  
  Revision  Changes    Path
  1.8       +44 -0     jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/KnownConfigurations.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: KnownConfigurations.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/KnownConfigurations.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- KnownConfigurations.java	27 Oct 2006 13:35:27 -0000	1.7
  +++ KnownConfigurations.java	11 Dec 2006 22:21:59 -0000	1.8
  @@ -22,7 +22,10 @@
   package org.hibernate.console;
   
   import java.io.File;
  +import java.io.IOException;
  +import java.io.OutputStream;
   import java.util.ArrayList;
  +import java.util.HashMap;
   import java.util.List;
   import java.util.Map;
   import java.util.TreeMap;
  @@ -41,6 +44,11 @@
   import javax.xml.transform.dom.DOMSource;
   import javax.xml.transform.stream.StreamResult;
   
  +import org.eclipse.ui.console.ConsolePlugin;
  +import org.eclipse.ui.console.IConsole;
  +import org.eclipse.ui.console.IConsoleManager;
  +import org.eclipse.ui.console.MessageConsole;
  +import org.eclipse.ui.console.MessageConsoleStream;
   import org.hibernate.SessionFactory;
   import org.hibernate.console.node.BaseNode;
   import org.hibernate.console.node.ConfigurationListNode;
  @@ -91,6 +99,8 @@
   		return instance;
   	}
   	
  +	
  +	
   	private abstract class Notification {
   	
   		public void run(KnownConfigurationsListener listener) {
  @@ -168,9 +178,13 @@
   				}
   			});
   			oldConfig.reset();
  +			removeLoggingStream( oldConfig );
   		}
  +		
  +		
   	}
   
  +	
   	/**
   	 * Answer whether the provided configuration name is known by the provider or not.
   	 * The name string corresponds to the Strin returned by ConsoleConfiguration#getName()
  @@ -220,6 +234,34 @@
   		return rootNode;		
   	}
   
  +	// TODO: decouple this logging from Eclipse platform!
  +	private Map loggingStreams = new HashMap();
  +	public MessageConsoleStream findLoggingStream(String name) {
  +		Object[] console = (Object[]) loggingStreams.get(name); 
  +		if(console==null) {
  +			console = new Object[2];
  +			String secondaryId = "Hibernate Log - " + (name==null?"<unknown>":name);
  +        	console[0] = new MessageConsole(secondaryId, null);
  +        	IConsoleManager consoleManager = ConsolePlugin.getDefault().getConsoleManager();
  +        	consoleManager.addConsoles(new IConsole[] { (IConsole) console[0] });
  +        	console[1] = ((MessageConsole)console[0]).newMessageStream();
  +        	loggingStreams.put(name, console);
  +		} 
  +		return (MessageConsoleStream) console[1];
  +	}
  +	
  +	private void removeLoggingStream(ConsoleConfiguration oldConfig) {
  +		Object[] object = (Object[]) loggingStreams.remove( oldConfig.getName() );
  +		if(object!=null) {
  +			MessageConsole mc = (MessageConsole)object[0];
  +			MessageConsoleStream stream = (MessageConsoleStream)object[1];
  +			try { stream.close(); } catch(IOException ie) { /* ignore */ };
  +			IConsoleManager consoleManager = ConsolePlugin.getDefault().getConsoleManager();
  +			consoleManager.removeConsoles( new IConsole[] { mc } );			
  +		}
  +	}
  +
  +	
   	public ConsoleConfiguration find(String lastUsedName) {
   		if(configurations==null) return null;
   		if(lastUsedName==null) return null;
  @@ -280,4 +322,6 @@
   	public List getQueryParameterList() {
   		return queryParameters;
   	}	
  +	
  +	
   }
  
  
  
  1.14      +1 -4      jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/ConsoleConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/ConsoleConfiguration.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ConsoleConfiguration.java	27 Nov 2006 15:30:22 -0000	1.13
  +++ ConsoleConfiguration.java	11 Dec 2006 22:21:59 -0000	1.14
  @@ -26,8 +26,6 @@
   import java.io.FileNotFoundException;
   import java.io.IOException;
   import java.io.InputStream;
  -import java.io.Serializable;
  -import java.lang.reflect.InvocationTargetException;
   import java.lang.reflect.Method;
   import java.net.URL;
   import java.net.URLClassLoader;
  @@ -44,7 +42,6 @@
   import org.dom4j.DocumentException;
   import org.dom4j.Node;
   import org.dom4j.io.DOMWriter;
  -import org.hibernate.EntityMode;
   import org.hibernate.HibernateException;
   import org.hibernate.MappingException;
   import org.hibernate.Session;
  @@ -153,7 +150,7 @@
   	 */
   	public Configuration buildWith(final Configuration cfg, final boolean includeMappings) {
   			URL[] customClassPathURLS = prefs.getCustomClassPathURLS();
  -			executionContext = new DefaultExecutionContext( new URLClassLoader( customClassPathURLS, getParentClassLoader() ) );							
  +			executionContext = new DefaultExecutionContext( getName(), new URLClassLoader( customClassPathURLS, getParentClassLoader() ) );							
   			
   			Configuration result = (Configuration) executionContext.execute(new ExecutionContext.Command() {
   			
  
  
  


From mandersen at jboss.com  Mon Dec 11 17:22:01 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Mon, 11 Dec 2006 17:22:01 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging
	...
Message-ID: <E1GttX7-00052Q-VE@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/11 17:22:01

  Modified:    hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging  
                        PluginLogAppender.java
  Added:       hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging  
                        CurrentContext.java
  Log:
  HBX-830  Database errors should not be displayed in Log Error view
  HBX-837 Have seperate logs per configuration
  
  Revision  Changes    Path
  1.4       +35 -5     jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging/PluginLogAppender.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PluginLogAppender.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging/PluginLogAppender.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PluginLogAppender.java	7 Jul 2006 13:50:57 -0000	1.3
  +++ PluginLogAppender.java	11 Dec 2006 22:22:01 -0000	1.4
  @@ -21,6 +21,13 @@
    */
   package org.hibernate.eclipse.logging;
   
  +import java.io.OutputStream;
  +import java.io.PrintWriter;
  +import java.io.StringWriter;
  +import java.util.HashMap;
  +import java.util.Map;
  +import java.util.WeakHashMap;
  +
   import org.apache.log4j.AppenderSkeleton;
   import org.apache.log4j.Level;
   import org.apache.log4j.Priority;
  @@ -30,6 +37,12 @@
   import org.eclipse.core.runtime.ILog;
   import org.eclipse.core.runtime.IStatus;
   import org.eclipse.core.runtime.Status;
  +import org.eclipse.ui.console.ConsolePlugin;
  +import org.eclipse.ui.console.IConsole;
  +import org.eclipse.ui.console.IConsoleManager;
  +import org.eclipse.ui.console.MessageConsole;
  +import org.eclipse.ui.console.MessageConsoleStream;
  +import org.hibernate.console.KnownConfigurations;
   
   /**
    * PluginLogAppender
  @@ -40,6 +53,8 @@
   public class PluginLogAppender extends AppenderSkeleton {
   
   	private ILog pluginLog;
  +	private Map streams = new HashMap();
  +	
   	
   	/**
   	 * Sets the Eclipse log instance
  @@ -74,7 +89,7 @@
   			if (info != null)
   				thrown = info.getThrowable(); 
   		}
  -				
  +		/*		
   		Level level = event.getLevel();
   		int severity = IStatus.OK;
   		
  @@ -87,10 +102,25 @@
   		if (level.toInt() >= Priority.DEBUG_INT) 
   			severity = IStatus.INFO;
   			
  +		
   		this.pluginLog.log(new Status(severity,
   		         this.pluginLog.getBundle().getSymbolicName(),
  -				 level.toInt(),text,thrown));
  +				 level.toInt(),text,thrown));*/
  +
  +		Object peek = CurrentContext.peek();
  +		MessageConsoleStream stream = KnownConfigurations.getInstance().findLoggingStream( (String)peek );
  +		if(stream!=null) {
  +			stream.println(text);
  +			if(thrown!=null) {
  +				StringWriter stringWriter = new StringWriter();
  +				thrown.printStackTrace( new PrintWriter(stringWriter) );
  +				stream.println(stringWriter.getBuffer().toString());
   	}
  +		}
  +		
  +		}
  +		
  +    	
   	
   	/**
   	 * Closes this appender
  
  
  
  1.1      date: 2006/12/11 22:22:01;  author: mandersen;  state: Exp;jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging/CurrentContext.java
  
  Index: CurrentContext.java
  ===================================================================
  package org.hibernate.eclipse.logging;
  
  import java.util.Hashtable;
  import java.util.Stack;
  
  /**
   * CurrentContext is here to have one place where we can keep track on the
   * "current" console configuration to allow logging to be seperated per config.
   * 
   */
  
  public class CurrentContext {
  
  	static Hashtable map = new Hashtable();
  
  	private CurrentContext() {
  	}
  
  	public static int getDepth() {
  		Stack stack = (Stack) map.get( Thread.currentThread() );
  		if ( stack == null )
  			return 0;
  		else
  			return stack.size();
  	}
  
  	public static Object pop() {
  		Thread key = Thread.currentThread();
  		Stack stack = (Stack) map.get( key );
  		if ( stack != null && !stack.isEmpty() )
  			return (stack.pop() );
  		else
  			return null;
  	}
  
  	public static Object peek() {
  		Thread key = Thread.currentThread();
  		Stack stack = (Stack) map.get( key );
  		if ( stack != null && !stack.isEmpty() )
  			return stack.peek();
  		else
  			return null;
  	}
  
  	public static void push(Object message) {
  		Thread key = Thread.currentThread();
  		Stack stack = (Stack) map.get( key );
  
  		if ( stack == null ) {
  			stack = new Stack();
  			map.put( key, stack );
  			stack.push( message );
  		}
  		else if ( stack.isEmpty() ) {
  			stack.push( message );
  		}
  		else {
  			stack.push( message );
  		}
  	}
  
  	static public void remove() {
  		map.remove( Thread.currentThread() );
  	}
  }
  
  
  


From mandersen at jboss.com  Mon Dec 11 17:22:03 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Mon, 11 Dec 2006 17:22:03 -0500
Subject: [jboss-cvs] jbosside/hibernatetools/plugins/org.hibernate.eclipse ...
Message-ID: <E1GttX9-00052X-O1@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/11 17:22:03

  Modified:    hibernatetools/plugins/org.hibernate.eclipse 
                        hibernate-log4j.properties
  Log:
  HBX-830  Database errors should not be displayed in Log Error view
  HBX-837 Have seperate logs per configuration
  
  Revision  Changes    Path
  1.5       +1 -1      jbosside/hibernatetools/plugins/org.hibernate.eclipse/hibernate-log4j.properties
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: hibernate-log4j.properties
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/hibernate-log4j.properties,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- hibernate-log4j.properties	1 Jun 2006 22:47:45 -0000	1.4
  +++ hibernate-log4j.properties	11 Dec 2006 22:22:03 -0000	1.5
  @@ -4,7 +4,7 @@
   ### Direct messages to Eclipse logging system (will be shown in Error Log)
   log4j.appender.eclipselog=org.hibernate.eclipse.logging.PluginLogAppender
   log4j.appender.eclipselog.layout=org.apache.log4j.PatternLayout
  -log4j.appender.eclipselog.layout.ConversionPattern=%p %t %c - %m
  +log4j.appender.eclipselog.layout.ConversionPattern=%d{ISO8601} %p %t %c - %m
   
   ### Direct messages from Eclipse loggin system to .metadata/plugins/org.hibernate.eclipse/hibernate-tools.log 
   log4j.appender.pluginlog=org.hibernate.eclipse.logging.PluginFileAppender
  
  
  


From mandersen at jboss.com  Mon Dec 11 17:22:04 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Mon, 11 Dec 2006 17:22:04 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse/META-INF ...
Message-ID: <E1GttXA-00052e-KJ@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/11 17:22:04

  Modified:    hibernatetools/plugins/org.hibernate.eclipse/META-INF 
                        MANIFEST.MF
  Log:
  HBX-830  Database errors should not be displayed in Log Error view
  HBX-837 Have seperate logs per configuration
  
  Revision  Changes    Path
  1.48      +3 -1      jbosside/hibernatetools/plugins/org.hibernate.eclipse/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/META-INF/MANIFEST.MF,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -b -r1.47 -r1.48
  --- MANIFEST.MF	27 Nov 2006 15:30:22 -0000	1.47
  +++ MANIFEST.MF	11 Dec 2006 22:22:04 -0000	1.48
  @@ -465,6 +465,8 @@
    org.objectweb.asm.attrs,
    org.w3c.tidy,
    org.w3c.tidy.ant
  -Require-Bundle: org.eclipse.core.runtime
  +Require-Bundle: org.eclipse.core.runtime,
  + org.eclipse.ui.console,
  + org.eclipse.jface
   Eclipse-LazyStart: true
   Eclipse-BuddyPolicy: registered
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 17:31:02 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 17:31:02 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1766 - in trunk: .
 docs/examples/stateless/src/org/jboss/example/jms/stateless/bean
 docs/examples/stateless/src/org/jboss/example/jms/stateless/client src/etc
 src/etc/server/default/deploy src/etc/xmdesc src/main/org/jboss/jms/client
 src/main/org/jboss/jms/client/container
 src/main/org/jboss/jms/client/delegate
 src/main/org/jboss/jms/client/remoting src/main/org/jboss/jms/client/state
 src/main/org/jboss/jms/delegate src/main/org/jboss/jms/message
 src/main/org/jboss/jms/server
 src/main/org/jboss/jms/server/connectionfactory
 src/main/org/jboss/jms/server/container
 src/main/org/jboss/jms/server/destination
 src/main/org/jboss/jms/server/endpoint
 src/main/org/jboss/jms/server/endpoint/advised
 src/main/org/jboss/jms/server/remoting src/main/org/jboss/jms/tx
 src/main/org/jboss/jms/util src/main/org/jboss/messaging/core
 src/main/org/jboss/messaging/core/local
 src/main/org/jboss/messaging/core/plugin
 src/main/org/jboss/messaging/core/plugin/contract sr!
 c/main/org/jboss/messaging/core/plugin/postoffice
 src/main/org/jboss/messaging/core/plugin/postoffice/cluster tests tests/bin
 tests/etc tests/lib tests/src/org/jboss/test/messaging/core
 tests/src/org/jboss/test/messaging/core/ha
 tests/src/org/jboss/test/messaging/core/local/base
 tests/src/org/jboss/test/messaging/core/plugin/base
 tests/src/org/jboss/test/messaging/core/plugin/postoffice
 tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
 tests/src/org/jboss/test/messaging/jms
 tests/src/org/jboss/test/messaging/jms/clustering
 tests/src/org/jboss/test/messaging/jms/clustering/base
 tests/src/org/jboss/test/messaging/jms/crash
 tests/src/org/jboss/test/messaging/jms/server
 tests/src/org/jboss/test/messaging/jms/server/destination
 tests/src/org/jboss/test/messaging/tools
 tests/src/org/jboss/test/messaging/tools/jmx
 tests/src/org/jboss/test/messaging/tools/jmx/rmi
 tests/src/org/jboss/test/messaging/tools/jndi tools/lib util
Message-ID: <E1Gttfq-00059b-QU@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-11 17:29:27 -0500 (Mon, 11 Dec 2006)
New Revision: 1766

Added:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/server/JMSCondition.java
   trunk/src/main/org/jboss/jms/server/JMSConditionFactory.java
   trunk/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/Condition.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java
   trunk/tests/src/org/jboss/test/messaging/core/SimpleCondition.java
   trunk/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/
   trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java
Removed:
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/NodeAddressInfo.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendNodeIdRequest.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Modified:
   trunk/
   trunk/build-messaging.xml
   trunk/build-thirdparty.xml
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java
   trunk/messaging.iml
   trunk/messaging.ipr
   trunk/src/etc/aop-messaging-client.xml
   trunk/src/etc/aop-messaging-server.xml
   trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
   trunk/src/etc/server/default/deploy/connection-factories-service.xml
   trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml
   trunk/src/etc/server/default/deploy/messaging-service.xml
   trunk/src/etc/server/default/deploy/mysql-persistence-service.xml
   trunk/src/etc/server/default/deploy/oracle-persistence-service.xml
   trunk/src/etc/server/default/deploy/postgresql-persistence-service.xml
   trunk/src/etc/server/default/deploy/sybase-persistence-service.xml
   trunk/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml
   trunk/src/etc/xmdesc/ConnectionFactory-xmbean.xml
   trunk/src/etc/xmdesc/ServerPeer-xmbean.xml
   trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java
   trunk/src/main/org/jboss/jms/client/JBossMessageConsumer.java
   trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
   trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/BrowserState.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java
   trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java
   trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java
   trunk/src/main/org/jboss/jms/server/DestinationJNDIMapper.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/src/main/org/jboss/jms/server/container/InjectionAspect.java
   trunk/src/main/org/jboss/jms/server/container/SecurityAspect.java
   trunk/src/main/org/jboss/jms/server/destination/ManagedQueue.java
   trunk/src/main/org/jboss/jms/server/destination/ManagedTopic.java
   trunk/src/main/org/jboss/jms/server/destination/QueueService.java
   trunk/src/main/org/jboss/jms/server/destination/TopicService.java
   trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSServerInvocationHandler.java
   trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
   trunk/src/main/org/jboss/jms/tx/AckInfo.java
   trunk/src/main/org/jboss/jms/tx/ResourceManager.java
   trunk/src/main/org/jboss/jms/tx/TxState.java
   trunk/src/main/org/jboss/jms/util/JNDIUtil.java
   trunk/src/main/org/jboss/jms/util/MessagingJMSException.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/local/PagingFilteredQueue.java
   trunk/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
   trunk/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRequest.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRouter.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicy.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PullMessagesRequest.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SharedState.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/UnbindRequest.java
   trunk/tests/bin/.testrc.example
   trunk/tests/bin/runtest
   trunk/tests/bin/start-rmi-server
   trunk/tests/bin/stop-rmi-server
   trunk/tests/build.xml
   trunk/tests/etc/container.xml
   trunk/tests/etc/log4j.xml
   trunk/tests/lib/README
   trunk/tests/lib/jboss-common-jdbc-wrapper.jar
   trunk/tests/lib/jboss-jca.jar
   trunk/tests/lib/jboss-local-jdbc.jar
   trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/server/DestinationManagerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/server/ServerPeerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
   trunk/tools/lib/jbossbuild.jar
   trunk/util/do-not-distribute.properties
Log:
First check in attempt after merging Branch_Client_Failover_Experiment into the trunk.
I don't expect all functional tests to pass, but working on it.

DO NOT use Branch_Client_Failover_Experiment anymore, all failover changes
have been merged into the trunk

Branch_Client_Failover_Experiment IS DEAD!



Property changes on: trunk
___________________________________________________________________
Name: svn:ignore
   - output
thirdparty
messaging.iws
jboss-head-partial-messaging-1-0.iml

   + output
thirdparty
messaging.iws



Modified: trunk/build-messaging.xml
===================================================================
--- trunk/build-messaging.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/build-messaging.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -149,7 +149,9 @@
               present in ./lib, it will take precedence over the corresponding repository instance.
     -->
    <path id="jboss.dependencies.classpath">
-      <path refid="jboss.common.classpath"/>
+      <path refid="jboss.common.core.classpath"/>
+      <path refid="jboss.common.logging.log4j.classpath"/>
+      <path refid="jboss.common.logging.spi.classpath"/>
       <path refid="jboss.aop.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
@@ -467,7 +469,7 @@
            We need org/jboss/util/collection.SoftValueHashMap which was moved. See
            http://jira.jboss.org/jira/browse/JBMESSAGING-281 for more details.
       -->
-      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.lib}/jboss-common.jar" >
+      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.core.lib}/jboss-common-core.jar" >
          <patternset>
             <include name="org/jboss/util/collection/SoftValueHashMap*.class"/>
             <!--
@@ -488,7 +490,7 @@
       <!--
            I also need org.jboss.util.stream.*
       -->
-      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.lib}/jboss-common.jar">
+      <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.core.lib}/jboss-common-core.jar">
          <patternset>
             <include name="org/jboss/util/stream/**"/>
          </patternset>
@@ -573,7 +575,9 @@
       <unjar dest="${project.output}/jboss-messaging-client" src="${javassist.javassist.lib}/javassist.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${trove.trove.lib}/trove.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${build.scoped-sar}/jboss-common-softvaluehashmap.jar"/>
-      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.lib}/jboss-common-client.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.core.lib}/jboss-common-core.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.logging.log4j.lib}/jboss-logging-log4j.jar"/>
+      <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.common.logging.spi.lib}/jboss-logging-spi.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.j2ee.lib}/jboss-j2ee.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.j2se.lib}/jboss-j2se.jar"/>
       <unjar dest="${project.output}/jboss-messaging-client" src="${jboss.naming.lib}/jnp-client.jar"/>

Modified: trunk/build-thirdparty.xml
===================================================================
--- trunk/build-thirdparty.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/build-thirdparty.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -87,13 +87,15 @@
       <componentref name="javassist" version="3.2.0.GA"/>
       <componentref name="jgroups" version="2.4"/>
       <componentref name="trove" version="1.0.2"/>
-      <componentref name="jboss/common" version="snapshot"/>
+      <componentref name="jboss/common-core" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>
+      <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
       <componentref name="jboss/aop" version="1.5.0.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
       <componentref name="jboss/remoting" version="2.2.0.Alpha4"/>
 
       <!-- Need this otherwise project doesn't build in Eclipse -->
-      <componentref name="apache-logging" version="1.0.5.GA-jboss"/>
+      <componentref name="apache-logging" version="1.0.4.1jboss"/>
 
       <!--
            Dependencies required to test the project.

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -6,9 +6,8 @@
  */
 package org.jboss.example.jms.stateless.bean;
 
-import javax.ejb.EJBObject;
-import java.util.List;
 import java.rmi.RemoteException;
+import javax.ejb.EJBObject;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -6,15 +6,14 @@
  */
 package org.jboss.example.jms.stateless.bean;
 
-import javax.jms.*;
+import java.rmi.RemoteException;
+import java.util.ArrayList;
+import java.util.Enumeration;
 import javax.ejb.EJBException;
 import javax.ejb.SessionBean;
 import javax.ejb.SessionContext;
+import javax.jms.*;
 import javax.naming.InitialContext;
-import java.rmi.RemoteException;
-import java.util.List;
-import java.util.Enumeration;
-import java.util.ArrayList;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,14 +21,11 @@
 */
 package org.jboss.example.jms.stateless.client;
 
+import javax.naming.InitialContext;
 import org.jboss.example.jms.common.ExampleSupport;
-import org.jboss.example.jms.stateless.bean.StatelessSessionExampleHome;
 import org.jboss.example.jms.stateless.bean.StatelessSessionExample;
+import org.jboss.example.jms.stateless.bean.StatelessSessionExampleHome;
 
-import javax.naming.InitialContext;
-import javax.jms.TextMessage;
-import java.util.List;
-
 /**
  * This example deploys a simple Stateless Session Bean that is used as a proxy to send and receive
  * JMS messages in a managed environment.

Modified: trunk/messaging.iml
===================================================================
--- trunk/messaging.iml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/messaging.iml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -7,7 +7,6 @@
     <content url="file://$MODULE_DIR$">
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/common/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/distributed-topic/src" isTestSource="false" />
-      <sourceFolder url="file://$MODULE_DIR$/docs/examples/ejb3mdb/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/http/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/mdb/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/queue/src" isTestSource="false" />
@@ -15,178 +14,37 @@
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/stateless/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/topic/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/output/gen-parsers" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/perf/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/perf/tests" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/src/main" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/src/test" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/tests/src" isTestSource="false" />
-      <excludeFolder url="file://$MODULE_DIR$/output" />
+      <excludeFolder url="file://$MODULE_DIR$/output/classes" />
+      <excludeFolder url="file://$MODULE_DIR$/output/etc" />
+      <excludeFolder url="file://$MODULE_DIR$/output/jar" />
+      <excludeFolder url="file://$MODULE_DIR$/output/lib" />
+      <excludeFolder url="file://$MODULE_DIR$/output/scoped-sar" />
     </content>
     <orderEntry type="inheritedJdk" />
     <orderEntry type="sourceFolder" forTests="false" />
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-j2ee.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/common/lib/jboss-common.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../common/src/main" />
-        </SOURCES>
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/javassist/lib/javassist.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../../javassist-3.2/src/main" />
-        </SOURCES>
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-j2se.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/hsqldb/lib/hsqldb.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-transaction.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss-system.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-jca.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-local-jdbc.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jms-ra.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../../jboss-4.0.4.GA-src/connector/src/main" />
-        </SOURCES>
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/tests/lib/jboss-common-jdbc-wrapper.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/lib/jboss.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/junit/lib/junit.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/oswego-concurrent/lib/concurrent.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../../concurrent-1.3.4/src" />
-        </SOURCES>
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/aop/lib/jboss-aop.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../../jboss-aop_1.5.0.GA/src/aspect-framework/main" />
-        </SOURCES>
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/serialization/lib/jboss-serialization.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES />
-      </library>
-    </orderEntry>
-    <orderEntry type="module-library">
-      <library>
-        <CLASSES>
-          <root url="jar://$MODULE_DIR$/thirdparty/jboss/remoting/lib/jboss-remoting.jar!/" />
-        </CLASSES>
-        <JAVADOC />
-        <SOURCES>
-          <root url="file://$MODULE_DIR$/../../cvs/JBossRemoting-2.2.0.Alpha4/src/main" />
-        </SOURCES>
-      </library>
-    </orderEntry>
+    <orderEntry type="library" name="concurrent" level="project" />
+    <orderEntry type="library" name="hsqldb" level="project" />
+    <orderEntry type="library" name="javassist" level="project" />
+    <orderEntry type="library" name="jboss-aop" level="project" />
+    <orderEntry type="library" name="jboss-common-core" level="project" />
+    <orderEntry type="library" name="jboss-j2ee" level="project" />
+    <orderEntry type="library" name="jboss-j2se" level="project" />
+    <orderEntry type="library" name="jboss-logging-log4j" level="project" />
+    <orderEntry type="library" name="jboss-logging-spi" level="project" />
+    <orderEntry type="library" name="jboss-remoting" level="project" />
+    <orderEntry type="library" name="jboss-serialization" level="project" />
+    <orderEntry type="library" name="jgroups" level="project" />
+    <orderEntry type="library" name="junit" level="project" />
     <orderEntryProperties />
   </component>
+  <component name="VcsManagerConfiguration">
+    <option name="ACTIVE_VCS_NAME" value="svn" />
+    <option name="USE_PROJECT_VCS" value="false" />
+  </component>
 </module>
 

Modified: trunk/messaging.ipr
===================================================================
--- trunk/messaging.ipr	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/messaging.ipr	2006-12-11 22:29:27 UTC (rev 1766)
@@ -201,7 +201,107 @@
     <option name="GENERATE_IIOP_STUBS" value="false" />
     <option name="ADDITIONAL_OPTIONS_STRING" value="" />
   </component>
-  <component name="libraryTable" />
+  <component name="libraryTable">
+    <library name="jboss-common-core">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/common-core/lib/jboss-common-core.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/common-core/lib/jboss-common-core-sources.jar!/" />
+      </SOURCES>
+    </library>
+    <library name="jboss-logging-log4j">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j-sources.jar!/" />
+      </SOURCES>
+    </library>
+    <library name="jboss-logging-spi">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi-sources.jar!/" />
+      </SOURCES>
+    </library>
+    <library name="jboss-aop">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/aop/lib/jboss-aop.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jboss-remoting">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/remoting/lib/jboss-remoting.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/remoting/lib/jboss-remoting-src.zip!/" />
+      </SOURCES>
+    </library>
+    <library name="jboss-serialization">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jboss/serialization/lib/jboss-serialization.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jgroups">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/jgroups/lib/jgroups.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="junit">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/junit/lib/junit.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="hsqldb">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/hsqldb/lib/hsqldb.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="javassist">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/javassist/lib/javassist.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="concurrent">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/thirdparty/oswego-concurrent/lib/concurrent.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jboss-j2ee">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/lib/jboss-j2ee.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jboss-j2se">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/lib/jboss-j2se.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+  </component>
   <component name="uidesigner-configuration">
     <option name="INSTRUMENT_CLASSES" value="true" />
     <option name="COPY_FORMS_RUNTIME_TO_OUTPUT" value="true" />

Modified: trunk/src/etc/aop-messaging-client.xml
===================================================================
--- trunk/src/etc/aop-messaging-client.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/aop-messaging-client.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -18,6 +18,7 @@
    <aspect class="org.jboss.jms.client.container.AsfAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.BrowserAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.ConnectionAspect" scope="PER_INSTANCE"/>
+   <aspect class="org.jboss.jms.client.container.HAAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.FactoryAspect" scope="PER_INSTANCE"/>
 
    <!-- ConnectionFactory Stack-->        
@@ -27,6 +28,9 @@
    </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
       <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
+   </bind>  
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
+      <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.HAAspect"/>
    </bind>
                
    <!-- Connection Stack -->   
@@ -35,6 +39,12 @@
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>      
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>               
    </bind>  
+    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->start())">
+       <advice name="handleStart" aspect="org.jboss.jms.client.container.ConnectionAspect"/>
+    </bind>
+    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->stop())">
+       <advice name="handleStop" aspect="org.jboss.jms.client.container.ConnectionAspect"/>
+    </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->createConnectionConsumer(..))">
       <advice name="handleCreateConnectionConsumer" aspect="org.jboss.jms.client.container.AsfAspect"/>
    </bind>
@@ -61,8 +71,9 @@
    </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->createSessionDelegate(..))">
       <advice name="handleCreateSessionDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
-   </bind>   
-   
+   </bind>
+    
+
    <!-- Session Stack -->   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->$implementing{org.jboss.jms.delegate.SessionDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
@@ -147,9 +158,15 @@
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->createConsumerDelegate(..))">
       <advice name="handleCreateConsumerDelegate" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         
    </bind>   
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->failOverConsumer(..))">
+      <advice name="handleCreateConsumerDelegate" aspect="org.jboss.jms.client.container.ConsumerAspect"/>
+   </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->createConsumerDelegate(..))">
       <advice name="handleCreateConsumerDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
    </bind>
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->failOverConsumer(..))">
+      <advice name="handleCreateConsumerDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
+   </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->createProducerDelegate(..))">
       <advice name="handleCreateProducerDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
    </bind>

Modified: trunk/src/etc/aop-messaging-server.xml
===================================================================
--- trunk/src/etc/aop-messaging-server.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/aop-messaging-server.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -37,13 +37,8 @@
    <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.ConsumerAdvised->$implementing{org.jboss.jms.server.endpoint.ConsumerEndpoint}(..))">
       <interceptor-ref name="org.jboss.jms.server.container.ServerLogInterceptor"/>
    </bind>
-   <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.ConsumerAdvised->activate(..))">
-      <advice name="handleActivate" aspect="org.jboss.jms.server.container.SecurityAspect"/>
-   </bind>
-   <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.ConsumerAdvised->getMessageNow(..))">
-      <advice name="handleGetMessageNow" aspect="org.jboss.jms.server.container.SecurityAspect"/>
-   </bind>
 
+
    <!-- Browser -->
    <bind pointcut="execution(* org.jboss.jms.server.endpoint.advised.BrowserAdvised->$implementing{org.jboss.jms.server.endpoint.BrowserEndpoint}(..))">
       <interceptor-ref name="org.jboss.jms.server.container.ServerLogInterceptor"/>

Modified: trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -58,19 +58,19 @@
    </mbean>
 
    <mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
-      name="jboss.messaging:service=QueuePostOffice"
+      name="jboss.messaging:service=PostOffice"
       xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Clustered Queue</attribute>
+      <attribute name="PostOfficeName">Clustered JMS</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
       <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID) VALUES (?, ?, ?, ?, ?, ?)
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER VARCHAR(1))
+INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
 DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
+LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
       ]]></attribute>
       <attribute name="GroupName">Queue</attribute>
       <attribute name="StateTimeout">5000</attribute>
@@ -87,7 +87,8 @@
             <AUTOCONF down_thread="false" up_thread="false"/>
             <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
             <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
+            <FD_SOCK down_thread="false" up_thread="false"/>
+            <FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>            
             <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
             <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
                          retransmit_timeout="100,200,600,1200,2400,4800"/>
@@ -107,7 +108,8 @@
             <AUTOCONF down_thread="false" up_thread="false"/>
             <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
             <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
+            <FD_SOCK down_thread="false" up_thread="false"/>
+            <FD timeout="20000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>            
             <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
             <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
                          retransmit_timeout="100,200,600,1200,2400,4800"/>
@@ -121,70 +123,6 @@
       </attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
-      name="jboss.messaging:service=TopicPostOffice"
-      xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml">
-      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Clustered Topic</attribute>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID) VALUES (?, ?, ?, ?, ?, ?)
-DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-      ]]></attribute>
-      <attribute name="GroupName">Topic</attribute>
-      <attribute name="StateTimeout">5000</attribute>
-      <attribute name="CastTimeout">5000</attribute>
-      <attribute name="StatsSendPeriod">10000</attribute>
-      <attribute name="MessagePullPolicy">org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy</attribute>
-      <attribute name="ClusterRouterFactory">org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory</attribute>
-
-      <attribute name="AsyncChannelConfig">
-         <config>
-            <UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
-           mcast_port="45569" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
-           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/>
-            <AUTOCONF down_thread="false" up_thread="false"/>
-            <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
-            <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
-            <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
-            <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
-                         retransmit_timeout="100,200,600,1200,2400,4800"/>
-            <UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/>
-            <pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/>
-            <FRAG frag_size="8192" down_thread="false" up_thread="false"/>
-            <VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" />
-            <pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/>
-         </config>
-      </attribute>
-
-      <attribute name="SyncChannelConfig">
-         <config>
-            <UDP mcast_recv_buf_size="500000" down_thread="false" ip_mcast="true" mcast_send_buf_size="32000"
-           mcast_port="45570" ucast_recv_buf_size="500000" use_incoming_packet_handler="false"
-           mcast_addr="228.8.8.8" use_outgoing_packet_handler="true" loopback="true" ucast_send_buf_size="32000" ip_ttl="32" bind_addr="127.0.0.1"/>
-            <AUTOCONF down_thread="false" up_thread="false"/>
-            <PING timeout="2000" down_thread="false" num_initial_members="3" up_thread="false"/>
-            <MERGE2 max_interval="10000" down_thread="false" min_interval="5000" up_thread="false"/>
-            <FD timeout="2000" max_tries="3" down_thread="false" up_thread="false" shun="true"/>
-            <VERIFY_SUSPECT timeout="1500" down_thread="false" up_thread="false"/>
-            <pbcast.NAKACK max_xmit_size="8192" down_thread="false" use_mcast_xmit="true" gc_lag="50" up_thread="false"
-                         retransmit_timeout="100,200,600,1200,2400,4800"/>
-            <UNICAST timeout="1200,2400,3600" down_thread="false" up_thread="false"/>
-            <pbcast.STABLE stability_delay="1000" desired_avg_gossip="20000" down_thread="false" max_bytes="0" up_thread="false"/>
-            <FRAG frag_size="8192" down_thread="false" up_thread="false"/>
-            <VIEW_SYNC avg_send_interval="60000" down_thread="false" up_thread="false" />
-            <pbcast.GMS print_local_addr="true" join_timeout="3000" down_thread="false" join_retry_timeout="2000" up_thread="false" shun="true"/>
-            <pbcast.STATE_TRANSFER down_thread="false" up_thread="false"/>
-         </config>
-      </attribute>
-   </mbean>
-
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: trunk/src/etc/server/default/deploy/connection-factories-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/connection-factories-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/connection-factories-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -13,6 +13,8 @@
       xmbean-dd="xmdesc/ConnectionFactory-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends optional-attribute-name="Connector">jboss.messaging:service=Connector,transport=socket</depends>
+      <depends>jboss.messaging:service=QueuePostOffice</depends>
+
       <attribute name="JNDIBindings">
          <bindings>
             <binding>/ConnectionFactory</binding>
@@ -21,6 +23,8 @@
             <binding>java:/XAConnectionFactory</binding>
          </bindings>
       </attribute>
+      
+      <attribute name="Clustered">true</attribute>
    </mbean>
 
 </server>
\ No newline at end of file

Modified: trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,27 +22,16 @@
    <!-- Note that Hypersonic CANNOT be used for clustered post offices -->
 
    <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=QueuePostOffice"
+      name="jboss.messaging:service=PostOffice"
       xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Queue</attribute>
+      <attribute name="PostOfficeName">JMS</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=TopicPostOffice"
-      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
-      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Topic</attribute>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-   </mbean>
-
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: trunk/src/etc/server/default/deploy/messaging-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/messaging-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/messaging-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,9 +23,9 @@
 
       <depends optional-attribute-name="PersistenceManager">jboss.messaging:service=PersistenceManager</depends>    
       <depends optional-attribute-name="JMSUserManager">jboss.messaging:service=JMSUserManager</depends>
+      <depends>jboss.messaging:service=Connector,transport=socket</depends>
 
-	   <attribute name="QueuePostOffice">jboss.messaging:service=QueuePostOffice</attribute>
-	   <attribute name="TopicPostOffice">jboss.messaging:service=TopicPostOffice</attribute>
+	   <attribute name="PostOffice">jboss.messaging:service=PostOffice</attribute>
 
       <attribute name="SecurityDomain">java:/jaas/messaging</attribute>
       <attribute name="DefaultSecurityConfig">

Modified: trunk/src/etc/server/default/deploy/mysql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -58,82 +58,22 @@
    </mbean>
 
    <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=QueuePostOffice"
+      name="jboss.messaging:service=PostOffice"
       xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Queue</attribute>
+      <attribute name="PostOfficeName">JMS</attribute>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
       <attribute name="SqlProperties"><![CDATA[
-<<<<<<< .working
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID) VALUES (?, ?, ?, ?, ?, ?)
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))
+INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
 DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
 LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-=======
-CREATE_MESSAGE_REF=CREATE TABLE JMS_MESSAGE_REFERENCE (CHANNELID BIGINT, MESSAGEID BIGINT, TRANSACTIONID BIGINT, STATE CHAR(1), ORD BIGINT, DELIVERYCOUNT INTEGER, RELIABLE CHAR(1), LOADED CHAR(1), PRIMARY KEY(CHANNELID, MESSAGEID)) 
-CREATE_IDX_MESSAGE_REF_TX=CREATE INDEX JMS_MESSAGE_REF_TX ON JMS_MESSAGE_REFERENCE (TRANSACTIONID)         
-CREATE_IDX_MESSAGE_REF_ORD=CREATE INDEX JMS_MESSAGE_REF_ORD ON JMS_MESSAGE_REFERENCE (ORD)
-CREATE_IDX_MESSAGE_REF_MESSAGEID=CREATE INDEX JMS_MESSAGE_REF_MESSAGEID ON JMS_MESSAGE_REFERENCE (MESSAGEID)
-CREATE_IDX_MESSAGE_REF_LOADED=CREATE INDEX JMS_MESSAGE_REF_LOADED ON JMS_MESSAGE_REFERENCE (LOADED)
-CREATE_IDX_MESSAGE_REF_RELIABLE=CREATE INDEX JMS_MESSAGE_REF_RELIABLE ON JMS_MESSAGE_REFERENCE (RELIABLE)
-INSERT_MESSAGE_REF=INSERT INTO JMS_MESSAGE_REFERENCE (CHANNELID, MESSAGEID, TRANSACTIONID, STATE, ORD, DELIVERYCOUNT, RELIABLE, LOADED) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
-DELETE_MESSAGE_REF=DELETE FROM JMS_MESSAGE_REFERENCE WHERE MESSAGEID=? AND CHANNELID=? AND STATE='C'
-UPDATE_MESSAGE_REF=UPDATE JMS_MESSAGE_REFERENCE SET TRANSACTIONID=?, STATE='-' WHERE MESSAGEID=? AND CHANNELID=? AND STATE='C'
-UPDATE_MESSAGE_REF_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE MESSAGEID=? AND CHANNELID=?
-COMMIT_MESSAGE_REF1=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='+'
-COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
-ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
-ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
-LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
-SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'      
-UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'      
-UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?  
-SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'          
-DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
-UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
-CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY TINYINT, COREHEADERS MEDIUMBLOB, PAYLOAD LONGBLOB, CHANNELCOUNT INTEGER, TYPE TINYINT, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES VARBINARY(254), DESTINATION_ID BIGINT, REPLYTO_ID BIGINT, JMSPROPERTIES MEDIUMBLOB, PRIMARY KEY (MESSAGEID))
-LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES FROM JMS_MESSAGE
-INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION_ID, REPLYTO_ID, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
-UPDATE_MESSAGE_CHANNELCOUNT=UPDATE JMS_MESSAGE SET CHANNELCOUNT=? WHERE MESSAGEID=?
-DELETE_MESSAGE=DELETE FROM JMS_MESSAGE WHERE MESSAGEID=?
-MESSAGEID_COLUMN=MESSAGEID    
-UPDATE_UNRELIABLE_CHANNELCOUNT=UPDATE JMS_MESSAGE M SET M.CHANNELCOUNT = M.CHANNELCOUNT - 1 WHERE M.MESSAGEID IN (SELECT MR.MESSAGEID FROM JMS_MESSAGE_REFERENCE MR WHERE MR.RELIABLE = 'N' AND MR.CHANNELID = ?)
-DELETE_UNREFFED_MESSAGES=DELETE FROM JMS_MESSAGE WHERE CHANNELCOUNT = 0    
-CREATE_TRANSACTION=CREATE TABLE JMS_TRANSACTION (TRANSACTIONID BIGINT, BRANCH_QUAL VARBINARY(254), FORMAT_ID INTEGER, GLOBAL_TXID VARBINARY(254), PRIMARY KEY (TRANSACTIONID))
-INSERT_TRANSACTION=INSERT INTO JMS_TRANSACTION (TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID) VALUES(?, ?, ?, ?)
-DELETE_TRANSACTION=DELETE FROM JMS_TRANSACTION WHERE TRANSACTIONID = ?
-SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JMS_TRANSACTION         
-DELETE_ALL_TRANSACTIONS=DELETE FROM JMS_TRANSACTION
-CREATE_COUNTER=CREATE TABLE JMS_COUNTER (NAME VARCHAR(255), NEXT_ID BIGINT, PRIMARY KEY(NAME))
-UPDATE_COUNTER=UPDATE JMS_COUNTER SET NEXT_ID = ? WHERE NAME=?
-SELECT_COUNTER=SELECT NEXT_ID FROM JMS_COUNTER WHERE NAME=?
-INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
-DELETE_ALL_COUNTERS=DELETE FROM JMS_COUNTER
-SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
->>>>>>> .merge-right.r1631
       ]]></attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
-      name="jboss.messaging:service=TopicPostOffice"
-      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
-      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="PostOfficeName">Topic</attribute>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)
-INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID) VALUES (?, ?, ?, ?, ?, ?)
-DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
-      ]]></attribute>
-   </mbean>
-   
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: trunk/src/etc/server/default/deploy/oracle-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -62,46 +62,7 @@
       <attribute name="MaxParams">500</attribute>
    </mbean>      
       
-   <mbean code="org.jboss.messaging.core.plugin.DirectExchange"
-      name="jboss.messaging:service=DirectExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR2(32) NOT NULL, PASSWD VARCHAR2(32) NOT NULL, CLIENTID VARCHAR2(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR2(32) NOT NULL, USERID VARCHAR2(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))      
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1), JMS_DEST_NAME VARCHAR2(1024), JMS_SUB_NAME VARCHAR2(1024), CLIENT_ID VARCHAR2(128), SELECTOR VARCHAR2(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))      
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?            
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]></attribute>
-   </mbean>
    
-   <mbean code="org.jboss.messaging.core.plugin.TopicExchange"
-      name="jboss.messaging:service=TopicExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR2(32) NOT NULL, PASSWD VARCHAR2(32) NOT NULL, CLIENTID VARCHAR2(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR2(32) NOT NULL, USERID VARCHAR2(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))      
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1), JMS_DEST_NAME VARCHAR2(1024), JMS_SUB_NAME VARCHAR2(1024), CLIENT_ID VARCHAR2(128), SELECTOR VARCHAR2(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))      
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?            
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]></attribute>
-   </mbean>   
-   
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManager"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: trunk/src/etc/server/default/deploy/postgresql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -62,46 +62,6 @@
       <attribute name="MaxParams">500</attribute>
    </mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DirectExchange"
-      name="jboss.messaging:service=DirectExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID BIGINT, TYPE CHAR(1), JMS_DEST_NAME VARCHAR(1024), JMS_SUB_NAME VARCHAR(1024), CLIENT_ID VARCHAR(128), SELECTOR VARCHAR(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?
-           ]]></attribute>
-   </mbean>
-   
-   <mbean code="org.jboss.messaging.core.plugin.TopicExchange"
-      name="jboss.messaging:service=TopicExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
-      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-      <attribute name="DataSource">java:/DefaultDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID BIGINT, TYPE CHAR(1), JMS_DEST_NAME VARCHAR(1024), JMS_SUB_NAME VARCHAR(1024), CLIENT_ID VARCHAR(128), SELECTOR VARCHAR(1024), NO_LOCAL CHAR(1), PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?
-           ]]></attribute>
-   </mbean>   
-   
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManager"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: trunk/src/etc/server/default/deploy/sybase-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -70,56 +70,7 @@
 		</attribute>
 	</mbean>
 
-   <mbean code="org.jboss.messaging.core.plugin.DirectExchange"
-      name="jboss.messaging:service=DirectExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-		<!-- TODO this insures the fact that dependency exists. However I need to redundantly specifiy
-           the DataSource JNDI name in order to actually get a reference to it. Fix this.
-      -->
-		<depends>jboss.jca:service=DataSourceBinding,name=SybaseDS</depends>
-		<depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-		<attribute name="DataSource">SybaseDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128) NULL, PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1) NULL, JMS_DEST_NAME VARCHAR(1024) NULL, JMS_SUB_NAME VARCHAR(1024) NULL, CLIENT_ID VARCHAR(128) NULL, SELECTOR VARCHAR(1024) NULL, NO_LOCAL CHAR(1) NULL, PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]>
-		</attribute>
-	</mbean>
 	
-	<mbean code="org.jboss.messaging.core.plugin.TopicExchange"
-      name="jboss.messaging:service=TopicExchange"
-      xmbean-dd="xmdesc/Exchange-xmbean.xml">
-		<!-- TODO this insures the fact that dependency exists. However I need to redundantly specifiy
-           the DataSource JNDI name in order to actually get a reference to it. Fix this.
-      -->
-		<depends>jboss.jca:service=DataSourceBinding,name=SybaseDS</depends>
-		<depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
-		<attribute name="DataSource">SybaseDS</attribute>
-      <attribute name="CreateTablesOnStartup">true</attribute>
-
-      <attribute name="SqlProperties"><![CDATA[
-CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128) NULL, PRIMARY KEY(USERID))
-CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
-SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
-CREATE_MAPPING_TABLE=CREATE TABLE JMS_CHANNEL_MAPPING (ID INTEGER, TYPE CHAR(1) NULL, JMS_DEST_NAME VARCHAR(1024) NULL, JMS_SUB_NAME VARCHAR(1024) NULL, CLIENT_ID VARCHAR(128) NULL, SELECTOR VARCHAR(1024) NULL, NO_LOCAL CHAR(1) NULL, PRIMARY KEY(ID))
-INSERT_MAPPING=INSERT INTO JMS_CHANNEL_MAPPING (ID, TYPE, JMS_DEST_NAME, JMS_SUB_NAME, CLIENT_ID, SELECTOR, NO_LOCAL) VALUES (?, ?, ?, ?, ?, ?, ?)
-DELETE_MAPPING=DELETE FROM JMS_CHANNEL_MAPPING WHERE ID = ?
-SELECT_ID_FOR_DESTINATION=SELECT ID FROM JMS_CHANNEL_MAPPING WHERE TYPE=? AND JMS_DEST_NAME=?
-SELECT_DURABLE_SUB=SELECT JMS_DEST_NAME, ID, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE CLIENT_ID=? AND JMS_SUB_NAME=?
-SELECT_SUBSCRIPTIONS_FOR_TOPIC=SELECT ID, CLIENT_ID, JMS_SUB_NAME, SELECTOR, NO_LOCAL FROM JMS_CHANNEL_MAPPING WHERE TYPE='D' AND JMS_DEST_NAME=?      
-      ]]>
-		</attribute>
-	</mbean>
-	
    <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManager"
       name="jboss.messaging:service=JMSUserManager"
       xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">

Modified: trunk/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/xmdesc/ClusteredPostOffice-xmbean.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -17,6 +17,12 @@
       <type>org.jboss.messaging.core.plugin.contract.MessagingComponent</type>
    </attribute>
 
+   <attribute access="read-only" getMethod="getNodeIDView">
+      <description>The set containing cluster group members' node IDs</description>
+      <name>NodeIDView</name>
+      <type>java.util.Set</type>
+   </attribute>
+
    <attribute access="read-write" getMethod="getDataSource" setMethod="setDataSource">
       <description>The JNDI name of the DataSource used by this ChannelMapper instance</description>
       <name>DataSource</name>
@@ -109,19 +115,46 @@
 
    <!-- Managed operations -->
 
+    <operation>
+       <description>JBoss Service lifecycle operation</description>
+       <name>create</name>
+    </operation>
+
+    <operation>
+       <description>Prepares a failover from a given node</description>
+       <name>failOver</name>
+        <parameter>
+          <description>The Failed ID </description>
+          <name>failedId</name>
+          <type>int</type>
+        </parameter>
+
+    </operation>
+
+    <operation>
+       <description>List Defined Bindings</description>
+       <name>listBindings</name>
+       <return-type>java.lang.String</return-type>
+    </operation>
+
    <operation>
       <description>JBoss Service lifecycle operation</description>
-      <name>create</name>
+      <name>start</name>
    </operation>
 
    <operation>
       <description>JBoss Service lifecycle operation</description>
-      <name>start</name>
+      <name>stop</name>
    </operation>
 
    <operation>
-      <description>JBoss Service lifecycle operation</description>
+      <description></description>
       <name>stop</name>
+      <parameter>
+        <description>Should we send a notification about leaving cluster</description>
+        <name>sendNotification</name>
+        <type>boolean</type>
+      </parameter>
    </operation>
 
    <operation>

Modified: trunk/src/etc/xmdesc/ConnectionFactory-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/ConnectionFactory-xmbean.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/xmdesc/ConnectionFactory-xmbean.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -81,6 +81,12 @@
       <name>Connector</name>
       <type>javax.management.ObjectName</type>
    </attribute>
+   
+   <attribute access="read-write" getMethod="isClustered" setMethod="setClustered">
+      <description>Is this a clustered connection factory?</description>
+      <name>Clustered</name>
+      <type>boolean</type>
+   </attribute>    
 
    <!-- Managed operations -->
 

Modified: trunk/src/etc/xmdesc/ServerPeer-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -34,24 +34,12 @@
       <type>javax.management.ObjectName</type>
    </attribute>
 
-   <attribute access="read-write" getMethod="getQueuePostOffice" setMethod="setQueuePostOffice">
-      <description>The ObjectName of the queue post office</description>
-      <name>QueuePostOffice</name>
+   <attribute access="read-write" getMethod="getPostOffice" setMethod="setPostOffice">
+      <description>The ObjectName of the post office</description>
+      <name>PostOffice</name>
       <type>javax.management.ObjectName</type>
-   </attribute>
+   </attribute>        
    
-   <attribute access="read-write" getMethod="getTopicPostOffice" setMethod="setTopicPostOffice">
-      <description>The ObjectName of the topic post office</description>
-      <name>TopicPostOffice</name>
-      <type>javax.management.ObjectName</type>
-   </attribute>   
-   
-   <attribute access="read-write" getMethod="getClusteredTopicPostOffice" setMethod="setClusteredTopicPostOffice">
-      <description>The ObjectName of the clustered topic post office</description>
-      <name>ClusteredTopicPostOffice</name>
-      <type>javax.management.ObjectName</type>
-   </attribute>    
-   
    <attribute access="read-write" getMethod="getJMSUserManager" setMethod="setJMSUserManager">
       <description>The ObjectName of the jms user manager</description>
       <name>JMSUserManager</name>

Modified: trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,24 +1,24 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.client;
 
 import java.io.Serializable;
@@ -42,9 +42,9 @@
 import org.jboss.aop.Advised;
 import org.jboss.jms.client.container.JmsClientAspectXMLLoader;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.referenceable.SerializableObjectRefAddr;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.util.ThreadContextClassLoaderChanger;
 import org.jboss.logging.Logger;
 
@@ -56,89 +56,89 @@
  * $Id$
  */
 public class JBossConnectionFactory implements
-    ConnectionFactory, QueueConnectionFactory, TopicConnectionFactory,
-    XAConnectionFactory, XAQueueConnectionFactory, XATopicConnectionFactory,
-    Serializable/*, Referenceable http://jira.jboss.org/jira/browse/JBMESSAGING-395*/
+               ConnectionFactory, QueueConnectionFactory, TopicConnectionFactory,
+               XAConnectionFactory, XAQueueConnectionFactory, XATopicConnectionFactory,
+               Serializable/*, Referenceable http://jira.jboss.org/jira/browse/JBMESSAGING-395*/
 {
    // Constants -----------------------------------------------------
-
+   
    private final static long serialVersionUID = -2810634789345348326L;
    
    private static final Logger log = Logger.getLogger(JBossConnectionFactory.class);
    
-
+   
    // Static --------------------------------------------------------
    
    private static boolean configLoaded;
-
+   
    // Attributes ----------------------------------------------------
-
+   
    protected ConnectionFactoryDelegate delegate;
    
    private boolean initialised;
-     
+   
    // Constructors --------------------------------------------------
-
+   
    public JBossConnectionFactory(ConnectionFactoryDelegate delegate)
    {
       this.delegate = delegate;      
    }
-
+   
    // ConnectionFactory implementation ------------------------------
-
+   
    public Connection createConnection() throws JMSException
    {
       return createConnection(null, null);
    }
-
+   
    public Connection createConnection(String username, String password) throws JMSException
    {
       return createConnectionInternal(username, password, false, JBossConnection.TYPE_GENERIC_CONNECTION);
    }
    
    // QueueConnectionFactory implementation -------------------------
-
+   
    public QueueConnection createQueueConnection() throws JMSException
    {
       return createQueueConnection(null, null);
    }
-
+   
    public QueueConnection createQueueConnection(String username, String password) throws JMSException
    {
-       return createConnectionInternal(username, password, false, JBossConnection.TYPE_QUEUE_CONNECTION);
+      return createConnectionInternal(username, password, false, JBossConnection.TYPE_QUEUE_CONNECTION);
    }
    
    // TopicConnectionFactory implementation -------------------------
-
+   
    public TopicConnection createTopicConnection() throws JMSException
    {
       return createTopicConnection(null, null);
    }
-
+   
    public TopicConnection createTopicConnection(String username, String password) throws JMSException
    {
       return createConnectionInternal(username, password, false, JBossConnection.TYPE_TOPIC_CONNECTION);
    }
    
    // XAConnectionFactory implementation ------------------------------
-
+   
    public XAConnection createXAConnection() throws JMSException
    {
       return createXAConnection(null, null);
    }
-
+   
    public XAConnection createXAConnection(String username, String password) throws JMSException
    {
       return createConnectionInternal(username, password, true, JBossConnection.TYPE_GENERIC_CONNECTION);   
    }
    
    // XAQueueConnectionFactory implementation -------------------------
-
+   
    public XAQueueConnection createXAQueueConnection() throws JMSException
    {
-       return createXAQueueConnection(null, null);
+      return createXAQueueConnection(null, null);
    }
-
+   
    public XAQueueConnection createXAQueueConnection(String username, String password) throws JMSException
    {
       return createConnectionInternal(username, password, true, JBossConnection.TYPE_QUEUE_CONNECTION);   
@@ -150,7 +150,7 @@
    {
       return createXATopicConnection(null, null);
    }
-
+   
    public XATopicConnection createXATopicConnection(String username, String password) throws JMSException
    {
       return createConnectionInternal(username, password, true, JBossConnection.TYPE_TOPIC_CONNECTION);   
@@ -161,13 +161,13 @@
    public Reference getReference() throws NamingException
    {
       return new Reference("org.jboss.jms.client.JBossConnectionFactory",
-                           new SerializableObjectRefAddr("JBM-CF", this),
-                           "org.jboss.jms.referenceable.ConnectionFactoryObjectFactory",
-                           null);
+               new SerializableObjectRefAddr("JBM-CF", this),
+               "org.jboss.jms.referenceable.ConnectionFactoryObjectFactory",
+               null);
    }
-
+   
    // Public --------------------------------------------------------
-
+   
    public String toString()
    {
       return "JBossConnectionFactory->" + delegate;
@@ -179,29 +179,29 @@
    }
    
    // Package protected ---------------------------------------------
-
+   
    // Protected -----------------------------------------------------
-
+   
    protected JBossConnection createConnectionInternal(String username, String password,
-                                                      boolean isXA, int type)
+            boolean isXA, int type)
       throws JMSException
    {
-
+      
       ThreadContextClassLoaderChanger tccc = new ThreadContextClassLoaderChanger();
-
+      
       try
       {
          tccc.set(getClass().getClassLoader());
-
+         
          ensureAOPConfigLoaded((ClientConnectionFactoryDelegate)delegate);
          initDelegate();
-           
+         
          // The version used by the connection is the minimum of the server version for the
          // connection factory and the client code version
          
-         ConnectionDelegate cd = delegate.createConnectionDelegate(username, password);        
-          
-         return new JBossConnection(cd, type);
+         CreateConnectionResult res = delegate.createConnectionDelegate(username, password, -1);        
+         
+         return new JBossConnection(res.getDelegate(), type);
       }
       finally
       {
@@ -229,7 +229,7 @@
                // Load the client side aspect stack configuration from the server and apply it
                
                delegate.init();
-                           
+               
                byte[] clientAOPConfig = delegate.getClientAOPConfig();
                
                // Remove interceptor since we don't want it on the front of the stack
@@ -251,8 +251,8 @@
          throw new RuntimeException(msg, e);
       }
    }
-
+   
    // Private -------------------------------------------------------
-
+      
    // Inner classes -------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/client/JBossMessageConsumer.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossMessageConsumer.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/JBossMessageConsumer.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -40,7 +40,7 @@
  *
  * $Id$
  */
-class JBossMessageConsumer implements MessageConsumer, QueueReceiver, TopicSubscriber, Serializable
+public class JBossMessageConsumer implements MessageConsumer, QueueReceiver, TopicSubscriber, Serializable
 {   
    // Constants -----------------------------------------------------  
    
@@ -118,6 +118,11 @@
       return delegate.getNoLocal();
    }
 
+   public ConsumerDelegate getDelegate()
+   {
+       return delegate;
+   }
+
    // Public --------------------------------------------------------
 
    public String toString()

Modified: trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,27 +1,26 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.client.container;
 
-import javax.jms.ConnectionMetaData;
 import javax.jms.ExceptionListener;
 import javax.jms.IllegalStateException;
 import javax.jms.JMSException;
@@ -30,8 +29,8 @@
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.JBossConnectionMetaData;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
@@ -40,11 +39,12 @@
 
 /**
  * Handles operations related to the connection
- * 
+ *
  * This aspect is PER_INSTANCE.
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -52,57 +52,57 @@
 public class ConnectionAspect implements ConnectionListener
 {
    // Constants -----------------------------------------------------
-
+   
    // Static --------------------------------------------------------
    
    private static final Logger log = Logger.getLogger(ConnectionAspect.class);
-
+   private static boolean trace = log.isTraceEnabled();
+   
    // Attributes ----------------------------------------------------
    
-   protected String clientID;
    
-   protected ExceptionListener exceptionListener;
+   protected JBossConnectionMetaData connMetaData;
    
-   protected ConnectionMetaData connMetaData;
+   protected ConnectionState state;
    
-   boolean justCreated = true;
-   
-   protected boolean listenerAdded;
-   
    // Constructors --------------------------------------------------
    
    // Public --------------------------------------------------------
-
+   
    // Interceptor implementation ------------------------------------
-
+   
    public Object handleGetClientID(Invocation invocation) throws Throwable
    {
-      justCreated = false;
+      ConnectionState currentState = getConnectionState(invocation);
       
-      if (clientID == null)          
+      currentState.setJustCreated(false);
+      
+      if (currentState.getClientID() == null)
       {
          //Get from the server
-         clientID = (String)invocation.invokeNext();
+         currentState.setClientID((String)invocation.invokeNext());
       }
-      return clientID;
+      return currentState.getClientID();
    }
    
    public Object handleSetClientID(Invocation invocation) throws Throwable
    {
-      if (clientID != null)
+      ConnectionState currentState = getConnectionState(invocation);
+      
+      if (currentState.getClientID() != null)
       {
          throw new IllegalStateException("Client id has already been set");
       }
-      if (!justCreated)
+      if (!currentState.isJustCreated())
       {
          throw new IllegalStateException("setClientID can only be called directly after the connection is created");
       }
       
       MethodInvocation mi = (MethodInvocation)invocation;
       
-      clientID = (String)mi.getArguments()[0];
+      currentState.setClientID((String)mi.getArguments()[0]);
       
-      justCreated = false;
+      currentState.setJustCreated(false);
       
       // this gets invoked on the server too
       return invocation.invokeNext();
@@ -110,34 +110,36 @@
    
    public Object handleGetExceptionListener(Invocation invocation) throws Throwable
    {
-      justCreated = false;
+      ConnectionState currentState = getConnectionState(invocation);
+      currentState.setJustCreated(false);
       
-      return exceptionListener;
+      return currentState.getExceptionListener();
    }
    
    public Object handleSetExceptionListener(Invocation invocation) throws Throwable
    {
-      justCreated = false;
+      ConnectionState currentState = getConnectionState(invocation);
+      currentState.setJustCreated(false);
       
       MethodInvocation mi = (MethodInvocation)invocation;
       
-      exceptionListener = (ExceptionListener)mi.getArguments()[0];            
+      currentState.setExceptionListener((ExceptionListener)mi.getArguments()[0]);
       
-      Client client = getState(invocation).getRemotingConnection().getInvokingClient();
+      Client client = getConnectionState(invocation).getRemotingConnection().getInvokingClient();
       
       if (client == null)
       {
          throw new java.lang.IllegalStateException("Cannot find remoting client");
       }
       
-      if (exceptionListener != null)
+      if (currentState.getExceptionListener() != null)
       {
          client.addConnectionListener(this);
-         listenerAdded = true;
+         currentState.setListenerAdded(true);
       }
       else
-      {            
-         if (listenerAdded)
+      {
+         if (currentState.isListenerAdded())
          {
             client.removeConnectionListener(this);
          }
@@ -147,20 +149,36 @@
    
    public Object handleGetConnectionMetaData(Invocation invocation) throws Throwable
    {
-      justCreated = false;
-
+      ConnectionState currentState = getConnectionState(invocation);
+      currentState.setJustCreated(false);
+      
       if (connMetaData == null)
       {
          ClientConnectionDelegate delegate = (ClientConnectionDelegate)invocation.getTargetObject();
          connMetaData = new JBossConnectionMetaData(((ConnectionState)delegate.getState()).getVersionToUse());
       }
-
+      
       return connMetaData;
    }
    
+   public Object handleStart(Invocation invocation) throws Throwable
+   {
+      ConnectionState currentState = getConnectionState(invocation);
+      currentState.setStarted(true);
+      return invocation.invokeNext();
+   }
+   
+   public Object handleStop(Invocation invocation) throws Throwable
+   {
+      ConnectionState currentState = getConnectionState(invocation);
+      currentState.setStarted(false);
+      return invocation.invokeNext();
+   }
+   
    public Object handleCreateSessionDelegate(Invocation invocation) throws Throwable
    {
-      justCreated = false;
+      ConnectionState currentState = getConnectionState(invocation);
+      currentState.setJustCreated(false);
       return invocation.invokeNext();
    }
    
@@ -168,8 +186,18 @@
    {
       Object ret = invocation.invokeNext();
       
-      ConnectionState state = getState(invocation);
+      //Remove any exception listener
+      ConnectionState currentState = getConnectionState(invocation);
       
+      Client client = getConnectionState(invocation).getRemotingConnection().getInvokingClient();
+      
+      if (currentState.isListenerAdded())
+      {
+         client.removeConnectionListener(this);
+      }
+            
+      ConnectionState state = getConnectionState(invocation);
+      
       // Finished with the connection - we need to shutdown callback server
       state.getRemotingConnection().stop();
       
@@ -182,13 +210,14 @@
       return ret;
    }
    
+   
    // ConnectionListener implementation -----------------------------------------------------------
    
    public void handleConnectionException(Throwable t, Client c)
    {
       log.error("Caught exception from connection", t);
-
-      if (exceptionListener != null)
+      
+      if (state.getExceptionListener()!= null)
       {
          JMSException j = null;
          if (t instanceof Error)
@@ -201,7 +230,7 @@
          {
             Exception e =(Exception)t;
             j = new JMSException("Throwable received from underlying connection");
-            j.setLinkedException(e);            
+            j.setLinkedException(e);
          }
          else
          {
@@ -210,23 +239,31 @@
             log.error(msg, t);
             j = new JMSException(msg + ": " + t.getMessage());
          }
-         synchronized (exceptionListener)
+         synchronized (state.getExceptionListener())
          {
-            exceptionListener.onException(j);
+            state.getExceptionListener().onException(j);
          }
-      }      
+      }
    }
-
+   
    // Package protected ---------------------------------------------
-
+   
    // Protected -----------------------------------------------------
-
+   
    // Private -------------------------------------------------------
    
-   private ConnectionState getState(Invocation inv)
+   private ConnectionState getConnectionState(Invocation invocation)
    {
-      return (ConnectionState)((DelegateSupport)inv.getTargetObject()).getState();
+      if (state==null)
+      {
+         ClientConnectionDelegate currentDelegate =
+            ((ClientConnectionDelegate)invocation.getTargetObject());
+         
+         state = (ConnectionState)currentDelegate.getState();
+      }
+      return state;
    }
    
+   
    // Inner classes -------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -93,7 +93,7 @@
       //Now we have finished creating the client consumer, we can tell the SCD
       //we are ready
       consumerDelegate.more();
-      
+
       return consumerDelegate;
    }
    

Copied: trunk/src/main/org/jboss/jms/client/container/HAAspect.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java)

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -28,9 +28,9 @@
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClientProducerDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.state.BrowserState;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.client.state.ConsumerState;
@@ -38,11 +38,15 @@
 import org.jboss.jms.client.state.ProducerState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.BrowserDelegate;
+import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.ProducerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
+import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
+import org.jboss.jms.server.Version;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.server.remoting.MetaDataConstants;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.jms.tx.ResourceManagerFactory;
@@ -58,6 +62,7 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com>Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org>Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org>Clebert Suconic</a>
  *
  * $Id$
  */
@@ -77,23 +82,49 @@
 
    public Object handleCreateConnectionDelegate(Invocation inv) throws Throwable
    {
-      ClientConnectionFactoryDelegate cfd = (ClientConnectionFactoryDelegate)inv.getTargetObject();
-      ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)inv.invokeNext();
-      connectionDelegate.init();
-
-      int serverID = cfd.getServerID();
-
-      ResourceManager rm = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
-      MessageIdGenerator gen =
-         MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
-
-      ConnectionState connectionState =
-         new ConnectionState(serverID, connectionDelegate,
-                             connectionDelegate.getRemotingConnection(),
-                             cfd.getVersionToUse(), rm, gen);
-
-      connectionDelegate.setState(connectionState);
-      return connectionDelegate;
+      ConnectionFactoryDelegate cfd = (ConnectionFactoryDelegate)inv.getTargetObject();
+      
+      CreateConnectionResult res = (CreateConnectionResult)inv.invokeNext();
+      
+      ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
+      
+      if (connectionDelegate != null)
+      {
+         
+         connectionDelegate.init();
+         
+         SimpleMetaData md = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
+         
+         int serverID =
+            ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID)).intValue();
+         
+         Version connectionVersion = 
+            (Version)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION);
+         
+         JMSRemotingConnection connection = 
+            (JMSRemotingConnection)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION);
+         
+         if (connectionVersion == null)
+         {
+            throw new IllegalStateException("Connection version is null");
+         }
+         
+         // We have one resource manager per unique server
+         ResourceManager rm = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
+         
+         //We have one message id generator per unique server
+         MessageIdGenerator gen =
+            MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
+         
+         ConnectionState connectionState =
+            new ConnectionState(serverID, connectionDelegate,
+                     connection,
+                     connectionVersion, rm, gen);
+         
+         connectionDelegate.setState(connectionState);
+      }
+      
+      return res;
    }
    
    public Object handleCreateSessionDelegate(Invocation invocation) throws Throwable
@@ -129,7 +160,8 @@
       MethodInvocation mi = (MethodInvocation)invocation;
       Destination dest = (Destination)mi.getArguments()[0];
       String selector = (String)mi.getArguments()[1];
-      boolean noLocal = ((Boolean)mi.getArguments()[2]).booleanValue();    
+      boolean noLocal = ((Boolean)mi.getArguments()[2]).booleanValue();
+      String subscriptionName = (String)mi.getArguments()[3];
       boolean connectionConsumer = ((Boolean)mi.getArguments()[4]).booleanValue();
 
       SimpleMetaData md = ((Advised)consumerDelegate)._getInstanceAdvisor().getMetaData();
@@ -144,9 +176,10 @@
          ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.MAX_DELIVERIES)).intValue();
       
       ConsumerState consumerState =
-         new ConsumerState(sessionState, consumerDelegate, dest, selector,
-                           noLocal, consumerID, connectionConsumer, prefetchSize, maxDeliveries);
-      
+         new ConsumerState(sessionState, consumerDelegate, dest, selector, noLocal,
+                           subscriptionName, consumerID, connectionConsumer, prefetchSize,
+                           maxDeliveries);
+
       delegate.setState(consumerState);
       return consumerDelegate;
    }
@@ -178,15 +211,20 @@
    
    public Object handleCreateBrowserDelegate(Invocation invocation) throws Throwable
    {
+      MethodInvocation mi = (MethodInvocation)invocation;
+
       BrowserDelegate browserDelegate = (BrowserDelegate)invocation.invokeNext();
       DelegateSupport delegate = (DelegateSupport)browserDelegate;
       
       delegate.init();
       
       SessionState sessionState = (SessionState)getState(invocation);
+
+      JBossDestination destination = (JBossDestination)mi.getArguments()[0];
+      String selector = (String)mi.getArguments()[1];
+
+      BrowserState state = new BrowserState(sessionState, browserDelegate, destination, selector);
       
-      BrowserState state = new BrowserState(sessionState, browserDelegate);
-      
       delegate.setState(state);
       return browserDelegate;
    }

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -28,11 +28,13 @@
 import javax.jms.ServerSessionPool;
 import javax.transaction.xa.Xid;
 
+import org.jboss.aop.util.PayloadKey;
 import org.jboss.jms.client.JBossConnectionConsumer;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
+import org.jboss.jms.server.remoting.MetaDataConstants;
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.remoting.Client;
 
@@ -41,6 +43,7 @@
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  *
  * @version <tt>$Revision$</tt>
  *
@@ -54,15 +57,20 @@
 
    // Attributes ----------------------------------------------------
 
+   // This should not be exposed other than through meta data
+   private int serverId;
+
    private transient JMSRemotingConnection remotingConnection;
-
+   
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
 
-   public ClientConnectionDelegate(int objectID)
+   public ClientConnectionDelegate(int objectID, int serverId)
    {
       super(objectID);
+      
+      this.serverId = serverId;
    }
 
    public ClientConnectionDelegate()
@@ -115,6 +123,7 @@
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
+    * @see org.jboss.jms.server.endpoint.advised.ConnectionAdvised#createSessionDelegate(boolean, int, boolean)
     */
    public SessionDelegate createSessionDelegate(boolean transacted,
                                                 int acknowledgmentMode,
@@ -211,6 +220,13 @@
       return "ConnectionDelegate[" + id + "]";
    }
 
+   public void init()
+   {
+      super.init();
+      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID,
+                                new Integer(serverId), PayloadKey.TRANSIENT);
+   }
+
    public void setRemotingConnection(JMSRemotingConnection conn)
    {
       this.remotingConnection = conn;

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -26,6 +26,7 @@
 
 import javax.jms.JMSException;
 
+import org.jboss.aop.Advised;
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
@@ -33,10 +34,10 @@
 import org.jboss.aop.util.PayloadKey;
 import org.jboss.jms.client.container.JMSClientVMIdentifier;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.server.remoting.MetaDataConstants;
@@ -66,39 +67,63 @@
 
    // Attributes ----------------------------------------------------
 
+   //This data is needed in order to create a connection
    protected String serverLocatorURI;
    protected Version serverVersion;
-   protected int serverID;
+
+   // This property is used on redirect on failover logic (verify if a new delegate could be used during a failover)
+   protected int serverId;
    protected boolean clientPing;
+   
+   private transient boolean trace;
 
-   private boolean trace;
-
    // Static --------------------------------------------------------
+   
+   /*
+    * Calculate what version to use.
+    * The client itself has a version, but we also support other versions of servers lower if the
+    * connection version is lower (backwards compatibility)
+    */
+   public static Version getVersionToUse(Version connectionVersion)
+   {
+      Version clientVersion = Version.instance();
 
+      Version versionToUse;
+
+      if (connectionVersion.getProviderIncrementingVersion() <= clientVersion.getProviderIncrementingVersion())
+      {
+         versionToUse = connectionVersion;
+      }
+      else
+      {
+         versionToUse = clientVersion;
+      }
+
+      return versionToUse;
+   }
+
    // Constructors --------------------------------------------------
 
-   public ClientConnectionFactoryDelegate(int objectID, String serverLocatorURI,
-                                          Version serverVersion, int serverID,
+   public ClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
+                                          Version serverVersion,
                                           boolean clientPing)
    {
       super(objectID);
 
+      this.serverId = serverId;
       this.serverLocatorURI = serverLocatorURI;
       this.serverVersion = serverVersion;
-      this.serverID = serverID;
       this.clientPing = clientPing;
       trace = log.isTraceEnabled();
    }
 
    // ConnectionFactoryDelegateImplementation -----------------------
-
+ 
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
-    * @see org.jboss.jms.client.container.StateCreationAspect#handleCreateConnectionDelegate(org.jboss.aop.joinpoint.Invocation)
-    * @see org.jboss.jms.server.endpoint.ServerConnectionFactoryEndpoint#createConnectionDelegate(String, String) 
     */
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
+   public CreateConnectionResult createConnectionDelegate(String username, String password, int failedNodeId)
       throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
@@ -139,7 +164,7 @@
                      Dispatcher.OID,
                      new Integer(id),
                      PayloadKey.AS_IS);
-      
+
       /*
        * If the method being invoked is createConnectionDelegate then we must invoke it on the same
        * remoting client subsequently used by the connection.
@@ -151,19 +176,19 @@
        * difficulties in knowing when to close it.
        */
 
-      Client client; 
-      
+      Client client;
+
       JMSRemotingConnection remotingConnection = null;
 
       if ("createConnectionDelegate".equals(methodName))
       {
          // Create a new connection
-         
+
          remotingConnection = new JMSRemotingConnection(serverLocatorURI, clientPing);
          remotingConnection.start();
-         
+
          client = remotingConnection.getInvokingClient();
-         
+
          md.addMetaData(MetaDataConstants.JMS,
                         MetaDataConstants.REMOTING_SESSION_ID,
                         client.getSessionId(),
@@ -177,38 +202,40 @@
       else
       {
          // Create a client - make sure pinging is off
-         
+
          Map configuration = new HashMap();
 
          configuration.put(Client.ENABLE_LEASE, String.valueOf(false));
-         
-         client = new Client(new InvokerLocator(serverLocatorURI), configuration);     
-         
+
+         client = new Client(new InvokerLocator(serverLocatorURI), configuration);
+
          client.setSubsystem(ServerPeer.REMOTING_JMS_SUBSYSTEM);
-         
-         client.connect();         
-         
+
+         client.connect();
+
          client.setMarshaller(new JMSWireFormat());
-         client.setUnMarshaller(new JMSWireFormat());         
+         client.setUnMarshaller(new JMSWireFormat());
       }
 
-      byte v = getVersionToUse().getProviderIncrementingVersion();
-      
+      //What version should we use for invocations on this connection factory?
+      Version version = getVersionToUse(serverVersion);
+      byte v = version.getProviderIncrementingVersion();
+
       MessagingMarshallable request = new MessagingMarshallable(v, mi);
-      
+
       MessagingMarshallable response;
 
       try
       {
          response = (MessagingMarshallable)client.invoke(request, null);
-         
+
          if (trace) { log.trace("got server response for " + methodName); }
       }
       catch (Throwable t)
       {
          //If we were invoking createConnectionDelegate and failure occurs then we need to clear
          //up the JMSRemotingConnection
-         
+
          if (remotingConnection != null)
          {
             try
@@ -219,7 +246,7 @@
             {
             }
          }
-         
+
          throw t;
       }
       finally
@@ -227,60 +254,68 @@
          if (remotingConnection == null)
          {
             //Not a call to createConnectionDelegate - disconnect the client
-            
-            // client.disconnect();
+
+            //client.disconnect();
          }
       }
 
       Object ret = response.getLoad();
-      
+
       if (remotingConnection != null)
       {
          // It was a call to createConnectionDelegate - set the remoting connection to use
-         ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)ret;
          
-         connectionDelegate.setRemotingConnection(remotingConnection);
+         CreateConnectionResult res = (CreateConnectionResult)ret;
+         
+         ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
+         
+         if (connectionDelegate != null)
+         {
+            //We set the version for the connection and the remoting connection on the meta-data
+            //this is so the StateCreationAspect can pick it up
+   
+            SimpleMetaData metaData = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
+   
+            metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION,
+                                 remotingConnection, PayloadKey.TRANSIENT);
+   
+            metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
+                                 version, PayloadKey.TRANSIENT);
+
+            connectionDelegate.setRemotingConnection(remotingConnection);
+         }
+         else
+         {
+            //Wrong server redirect on failure
+            //close the remoting connection
+            try
+            {
+               remotingConnection.stop();
+            }
+            catch (Throwable ignore)
+            {
+            }
+         }
+
       }
 
       return ret;
    }
 
-   public Version getServerVersion()
+   public String toString()
    {
-      return serverVersion;
+      return "ClientConnectionFactoryDelegate[" + id + "]";
    }
-
-   public int getServerID()
-   {
-      return serverID;
-   }
-
-   public Version getVersionToUse()
-   {
-      Version clientVersion = Version.instance();
-
-      Version versionToUse;
-
-      if (serverVersion.getProviderIncrementingVersion() <= clientVersion.getProviderIncrementingVersion())
-      {
-         versionToUse = serverVersion;
-      }
-      else
-      {
-         versionToUse = clientVersion;
-      }
-
-      return versionToUse;
-   }
-
+   
+   //This MUST ONLY be used in testing
    public String getServerLocatorURI()
    {
       return serverLocatorURI;
    }
 
-   public String toString()
+   public int getServerId()
    {
-      return "ConnectionFactoryDelegate[" + id + "]";
+      return serverId;
    }
 
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -50,17 +50,22 @@
 
    // Attributes ----------------------------------------------------
    
-   protected int bufferSize;
+   // This should not be exposed other than through meta data
+   private int bufferSize;
    protected int maxDeliveries;
 
+   // This should not be exposed other than through meta data
+   private long channelId;
+
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
 
-   public ClientConsumerDelegate(int objectID, int bufferSize, int maxDeliveries)
+   public ClientConsumerDelegate(int objectID, long channelId, int bufferSize, int maxDeliveries)
    {
       super(objectID);
       this.bufferSize = bufferSize;
+      this.channelId = channelId;
       this.maxDeliveries = maxDeliveries;
    }
    
@@ -68,6 +73,11 @@
    {      
    }
 
+   public long getChannelId()
+   {
+       return channelId;
+   }
+
    // ConsumerDelegate implementation -------------------------------
 
    /**
@@ -185,7 +195,7 @@
 
    public String toString()
    {
-      return "ConsumerDelegate[" + id + "]";
+      return "ConsumerDelegate[" + id + "](ChannelId=" + this.channelId+")" ;
    }
 
    // Protected -----------------------------------------------------
@@ -197,6 +207,20 @@
          getInvokingClient();
    }
 
+   public void copyState(DelegateSupport newDelegate)
+   {
+      super.copyState(newDelegate);
+      this.channelId = ((ClientConsumerDelegate)newDelegate).channelId;
+      this.getMetaData().removeMetaData(MetaDataConstants.JMS, MetaDataConstants.CONSUMER_ID);
+      this.getMetaData().addMetaData(MetaDataConstants.JMS,
+                                     MetaDataConstants.CONSUMER_ID,
+                                     newDelegate.getMetaData().
+                                        getMetaData(MetaDataConstants.JMS,
+                                                    MetaDataConstants.CONSUMER_ID),
+                                     PayloadKey.TRANSIENT);
+   }
+
+
    // Package Private -----------------------------------------------
 
    // Private -------------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -51,6 +51,7 @@
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  *
  * @version <tt>$Revision$</tt>
  *
@@ -192,6 +193,19 @@
    }
 
    /**
+    * @see org.jboss.jms.server.endpoint.ServerSessionEndpoint#failOverConsumer(org.jboss.jms.destination.JBossDestination, String, boolean, String, boolean, long, int) 
+    * @see org.jboss.jms.client.container.StateCreationAspect#handleCreateConsumerDelegate(org.jboss.aop.joinpoint.Invocation)
+    * */
+   public ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
+                                            String selectorString,
+                                            boolean noLocal,  String subscriptionName,
+                                            boolean connectionConsumer,
+                                            long oldChannelID) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */

Copied: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java)

Modified: trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -63,14 +63,20 @@
 
    private static final Logger log = Logger.getLogger(DelegateSupport.class);
 
+   private static boolean trace = log.isTraceEnabled();
+
    // Attributes ----------------------------------------------------
 
+   //This is set on the server
    protected int id;
 
-   protected HierarchicalState state;
+   //This is set on the client
+   //The reason we don't use the meta-data to store the state for the delegate is to avoid
+   //the extra HashMap lookup that would entail.
+   //This can be significant since the state could be queried for many aspects
+   //in an a single invocation
+   protected transient HierarchicalState state;
 
-   private boolean trace;
-
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
@@ -78,7 +84,6 @@
    public DelegateSupport(int objectID)
    {
       this.id = objectID;
-      trace = log.isTraceEnabled();
    }
 
    public DelegateSupport()
@@ -137,11 +142,21 @@
       checkMarshallers();
    }
 
-   public int getID()
-   {
-      return id;
-   }
+    public int getID()
+    {
+       return id;
+    }
 
+    /**
+     * During HA events, a new object is created on the new server and the state on that new object
+     * has to be transfered to this actual object. For example, a Connection will have to assume the
+     * ObjectID of the new connection endpoint and the new RemotingConnection.
+     */
+    public void copyState(DelegateSupport newDelegate)
+    {
+        id = newDelegate.getID();
+    }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -60,6 +60,7 @@
 
    // Attributes ----------------------------------------------------
 
+   // Map<Long(lookup)-MessageCallbackHandler>
    protected Map callbackHandlers;
 
    // Constructors --------------------------------------------------
@@ -98,11 +99,11 @@
       callbackHandlers.put(lookup, handler);
    }
 
-   public void unregisterHandler(int serverID, int consumerID)
+   public MessageCallbackHandler unregisterHandler(int serverID, int consumerID)
    {
       Long lookup = computeLookup(serverID, consumerID);
 
-      callbackHandlers.remove(lookup);
+      return (MessageCallbackHandler)callbackHandlers.remove(lookup);
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -78,6 +78,7 @@
       // Enable client pinging. Server leasing is enabled separately on the server side
 
       Map config = new HashMap();
+      
       config.put(Client.ENABLE_LEASE, String.valueOf(clientPing));
 
       client = new Client(serverLocator, config);
@@ -168,6 +169,7 @@
       client.removeListener(callbackManager);
       client.disconnect();
 
+      client=null;
       log.debug(this + " closed");
    }
 

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -498,6 +498,11 @@
    {
       return consumerID;
    }
+
+   public void setConsumerId(int consumerId)
+   {
+       this.consumerID=consumerId;
+   }
    
    public void addToFrontOfBuffer(MessageProxy proxy)
    {

Modified: trunk/src/main/org/jboss/jms/client/state/BrowserState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,9 +21,10 @@
   */
 package org.jboss.jms.client.state;
 
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.delegate.BrowserDelegate;
+import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.Version;
-import org.jboss.jms.client.delegate.DelegateSupport;
 
 /**
  * State corresponding to a browser
@@ -41,36 +42,50 @@
    private SessionState parent;
    private BrowserDelegate delegate;
 
-   public BrowserState(SessionState parent, BrowserDelegate delegate)
+   // Data used to recreate the Browser in case of failover
+   private JBossDestination jmsDestination;
+   private String messageSelector;
+
+   public BrowserState(SessionState parent, BrowserDelegate delegate, JBossDestination jmsDestination, String selector)
    {
       super(parent, (DelegateSupport)delegate);
+      this.jmsDestination=jmsDestination;
+      this.messageSelector=selector;
    }
 
+   public DelegateSupport getDelegate()
+   {
+      return (DelegateSupport)delegate;
+   }
+   public void setDelegate(DelegateSupport delegate)
+   {
+      this.delegate=(BrowserDelegate)delegate;
+   }
 
+   public Version getVersionToUse()
+   {
+      return parent.getVersionToUse();
+   }
 
-    public DelegateSupport getDelegate()
-    {
-        return (DelegateSupport)delegate;
-    }
-    public void setDelegate(DelegateSupport delegate)
-    {
-        this.delegate=(BrowserDelegate)delegate;
-    }
 
+   public org.jboss.jms.destination.JBossDestination getJmsDestination()
+   {
+      return jmsDestination;
+   }
 
-   public Version getVersionToUse()
+   public String getMessageSelector()
    {
-      return parent.getVersionToUse();
+      return messageSelector;
    }
 
-    public void setParent(HierarchicalState parent)
-    {
-        this.parent=(SessionState)parent;
-    }
-    public HierarchicalState getParent()
-    {
-        return parent;
-    }
+   public void setParent(HierarchicalState parent)
+   {
+      this.parent=(SessionState)parent;
+   }
+   public HierarchicalState getParent()
+   {
+      return parent;
+   }
 
 }
 

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,8 +23,10 @@
 
 import java.util.HashSet;
 
+import javax.jms.ExceptionListener;
+
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.server.Version;
@@ -47,87 +49,193 @@
 public class ConnectionState extends HierarchicalStateSupport
 {
    private static final Logger log = Logger.getLogger(ConnectionState.class);
-   
+
    private JMSRemotingConnection remotingConnection;
-   
+
    private ResourceManager resourceManager;
-   
+
    private MessageIdGenerator idGenerator;
-   
+
    private int serverID;
-   
+
    private Version versionToUse;
 
    private ConnectionDelegate delegate;
-    
+
+   // This is filled from and for the HA interceptors only
+   private transient String user;
+
+   // This is filled from and for the HA interceptors only
+   private transient String password;
+
+   protected boolean started;
+
+
+   /** This property used to be delcared on ConnectionAspect */
+   private String clientID;
+
+    /** This property used to be delcared on ConnectionAspect */
+   private ExceptionListener exceptionListener;
+
+    /** This property used to be delcared on ConnectionAspect */
+   private boolean justCreated = true;
+
+    /** This property used to be delcared on ConnectionAspect */
+   private boolean listenerAdded;
+   
+   
    public ConnectionState(int serverID, ConnectionDelegate delegate,
                           JMSRemotingConnection remotingConnection, Version versionToUse,
                           ResourceManager rm, MessageIdGenerator gen)
       throws Exception
    {
       super(null, (DelegateSupport)delegate);
-      
+
       if (log.isTraceEnabled()) { log.trace("Creating connection state"); }
-      
+
       children = new SyncSet(new HashSet(), new WriterPreferenceReadWriteLock());
-            
+
       this.remotingConnection = remotingConnection;
-      
+
       this.versionToUse = versionToUse;
-      
+
       this.resourceManager = rm;
-      
+
       this.idGenerator = gen;
-      
+
       this.serverID = serverID;
    }
-    
+
    public ResourceManager getResourceManager()
    {
       return resourceManager;
    }
-   
+
    public MessageIdGenerator getIdGenerator()
    {
       return idGenerator;
    }
-   
+
    public JMSRemotingConnection getRemotingConnection()
    {
       return remotingConnection;
    }
-   
+
+   public void setRemotingConnection(JMSRemotingConnection remotingConnection)
+   {
+       this.remotingConnection=remotingConnection;
+   }
+
    public Version getVersionToUse()
    {
       return versionToUse;
    }
-   
+
    public int getServerID()
    {
       return serverID;
    }
 
 
-    public DelegateSupport getDelegate()
+   public DelegateSupport getDelegate()
+   {
+      return (DelegateSupport) delegate;
+   }
+
+   public void setDelegate(DelegateSupport delegate)
+   {
+      this.delegate = (ConnectionDelegate) delegate;
+   }
+
+   /**
+    * Connection doesn't have a parent
+    */
+   public void setParent(HierarchicalState parent)
+   {
+   }
+
+   public boolean isStarted()
+   {
+      return started;
+   }
+
+   public void setStarted(boolean started)
+   {
+      this.started = started;
+   }
+
+
+   public String getPassword()
+   {
+      return password;
+   }
+
+   public void setPassword(String password)
+   {
+      this.password = password;
+   }
+
+   public String getUser()
+   {
+      return user;
+   }
+
+   public void setUser(String user)
+   {
+      this.user = user;
+   }
+
+   public String getClientID()
     {
-        return (DelegateSupport)delegate;
+        return clientID;
     }
 
-    public void setDelegate(DelegateSupport delegate)
+    public void setClientID(String clientID)
     {
-        this.delegate=(ConnectionDelegate)delegate;
+        this.clientID = clientID;
     }
 
-    /** Connection doesn't have a parent */
-    public void setParent(HierarchicalState parent)
+    public ExceptionListener getExceptionListener()
     {
+        return exceptionListener;
     }
 
+    public void setExceptionListener(ExceptionListener exceptionListener)
+    {
+        this.exceptionListener = exceptionListener;
+    }
+
+    public boolean isJustCreated()
+    {
+        return justCreated;
+    }
+
+    public void setJustCreated(boolean justCreated)
+    {
+        this.justCreated = justCreated;
+    }
+
+    public boolean isListenerAdded()
+    {
+        return listenerAdded;
+    }
+
+    public void setListenerAdded(boolean listenerAdded)
+    {
+        this.listenerAdded = listenerAdded;
+    }    
+
     /** Connection doesn't have a parent */
     public HierarchicalState getParent()
     {
         return null;
     }
 
-    
+    public void copy(ConnectionState newState)
+    {
+        this.serverID = newState.serverID;
+        this.idGenerator = newState.idGenerator;
+    }
+
+
 }

Modified: trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -42,17 +42,19 @@
 public class ConsumerState extends HierarchicalStateSupport
 {
    private Destination destination;
-   
+
    private String selector;
-   
+
+   String subscriptionName;
+
    private boolean noLocal;
-   
+
    private int consumerID;
-   
+
    private boolean isConnectionConsumer;
-   
+
    private MessageCallbackHandler messageCallbackHandler;
-   
+
    private int prefetchSize;
    
    private SessionState parent;
@@ -62,92 +64,105 @@
    private int maxDeliveries;
    
    public ConsumerState(SessionState parent, ConsumerDelegate delegate, Destination dest,
-            String selector, boolean noLocal, int consumerID, boolean isCC,
-            int prefetchSize, int maxDeliveries)
+                        String selector, boolean noLocal, String subscriptionName, int consumerID,
+                        boolean isCC, int prefetchSize, int maxDeliveries)
    {
       super(parent, (DelegateSupport)delegate);
       children = Collections.EMPTY_SET;
       this.destination = dest;
       this.selector = selector;
-      this.noLocal = noLocal;      
+      this.noLocal = noLocal;
       this.consumerID = consumerID;
       this.isConnectionConsumer = isCC;
       this.prefetchSize = prefetchSize;
+      this.subscriptionName=subscriptionName;
       this.maxDeliveries = maxDeliveries;
    }
-   
-   
+
    public DelegateSupport getDelegate()
    {
       return (DelegateSupport)delegate;
    }
-   
+
    public void setDelegate(DelegateSupport delegate)
    {
       this.delegate = (ConsumerDelegate)delegate;
    }
-   
-   
+
+
    public Destination getDestination()
    {
       return destination;
    }
-   
+
    public String getSelector()
    {
       return selector;
    }
-   
+
    public boolean isNoLocal()
    {
       return noLocal;
    }
-   
+
    public int getConsumerID()
    {
       return consumerID;
    }
-   
+
    public boolean isConnectionConsumer()
    {
       return isConnectionConsumer;
    }
-   
+
    public void setMessageCallbackHandler(MessageCallbackHandler handler)
    {
       this.messageCallbackHandler = handler;
    }
-   
+
    public MessageCallbackHandler getMessageCallbackHandler()
    {
       return messageCallbackHandler;
    }
-   
+
    public Version getVersionToUse()
    {
       return parent.getVersionToUse();
    }
-   
+
    public int getPrefetchSize()
    {
       return prefetchSize;
    }
-   
+
    public HierarchicalState getParent()
    {
       return parent;
    }
-   
+
    public void setParent(HierarchicalState parent)
    {
       this.parent=(SessionState)parent;
    }
-   
+
+   public String getSubscriptionName()
+   {
+      return subscriptionName;
+   }
+
+   public void setSubscriptionName(String subscriptionName)
+   {
+      this.subscriptionName = subscriptionName;
+   }
+
+   public void copy(ConsumerState newState)
+   {
+      this.consumerID = newState.consumerID;
+   }
+
    public int getMaxDeliveries()
    {
       return maxDeliveries;
    }
-   
+
 }
-
-

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -32,6 +32,7 @@
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.MessagingXAResource;
+import org.jboss.logging.Logger;
 
 import EDU.oswego.cs.dl.util.concurrent.LinkedQueue;
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
@@ -47,6 +48,9 @@
  */
 public class SessionState extends HierarchicalStateSupport
 {
+
+   protected static Logger log = Logger.getLogger(SessionState.class);
+
    private int acknowledgeMode;
    
    private boolean transacted;
@@ -202,5 +206,15 @@
       return new ArrayList(callbackHandlers.values());
    }
 
+   /*** used for HA Handling */
+   public void cleanCallBackHandlers()
+   {
+       if (log.isTraceEnabled())
+       {
+           log.trace("Clearing callBackHandlers size=" + callbackHandlers.size());
+       }
+       callbackHandlers.clear();
+   }
+
 }
 

Modified: trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -53,5 +53,10 @@
                                                     String messageSelector,
                                                     ServerSessionPool sessionPool,
                                                     int maxMessages) throws JMSException;
-   
+
+   /**
+    * Reconnects the current connection hierarchy using newConnection's properties.
+    */
+    //void failOver(ConnectionDelegate newConnection);
+
 }

Modified: trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -55,6 +55,11 @@
 
    protected ConnectionFactoryDelegate cfd;
 
+   public ConnectionFactoryDelegate getDelegate()
+   {
+       return cfd;
+   }
+
    // Constructors --------------------------------------------------
 
    public MessageIdGenerator(ConnectionFactoryDelegate cfd, int blockSize)  throws JMSException

Modified: trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -28,8 +28,8 @@
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision$</tt>
- *
- * $Id$
+ *          <p/>
+ *          $Id$
  */
 public interface ConnectionFactoryManager extends MessagingComponent
 {
@@ -39,14 +39,13 @@
     *
     * @return an identifier that uniques identifies the registered ConnectionFactory.
     */
-   int registerConnectionFactory(String clientID, JNDIBindings jndiBindings,
+   void registerConnectionFactory(String uniqueName, String clientID, JNDIBindings jndiBindings,
                                  String locatorURI, boolean clientPing,
                                  int prefetchSize,
                                  int defaultTempQueueFullSize,
                                  int defaultTempQueuePageSize,
-                                 int defaultTempQueueDownCacheSize) throws Exception;
+                                 int defaultTempQueueDownCacheSize,
+                                 boolean clustered) throws Exception;
 
-   void unregisterConnectionFactory(int connectionFactoryID) throws Exception;
-
-   javax.jms.ConnectionFactory getConnectionFactory(int connectionFactoryID);
+   void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception;
 }

Modified: trunk/src/main/org/jboss/jms/server/DestinationJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/DestinationJNDIMapper.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/DestinationJNDIMapper.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,22 +21,12 @@
   */
 package org.jboss.jms.server;
 
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.Set;
-
+import java.util.*;
 import javax.jms.InvalidDestinationException;
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
-
-import org.jboss.jms.destination.JBossDestination;
-import org.jboss.jms.destination.JBossQueue;
-import org.jboss.jms.destination.JBossTemporaryQueue;
-import org.jboss.jms.destination.JBossTemporaryTopic;
-import org.jboss.jms.destination.JBossTopic;
+import org.jboss.jms.destination.*;
 import org.jboss.jms.server.destination.ManagedDestination;
 import org.jboss.jms.util.JNDIUtil;
 import org.jboss.jms.util.MessagingJMSException;

Copied: trunk/src/main/org/jboss/jms/server/JMSCondition.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSCondition.java)

Copied: trunk/src/main/org/jboss/jms/server/JMSConditionFactory.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/JMSConditionFactory.java)

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,7 +23,9 @@
 
 import java.io.ByteArrayOutputStream;
 import java.io.InputStream;
+import java.io.Serializable;
 import java.net.URL;
+import java.util.Iterator;
 import java.util.Map;
 import java.util.Set;
 
@@ -37,8 +39,8 @@
 import org.jboss.jms.server.connectormanager.SimpleConnectorManager;
 import org.jboss.jms.server.endpoint.ServerConsumerEndpoint;
 import org.jboss.jms.server.plugin.contract.JMSUserManager;
+import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
-import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.security.SecurityMetadataStore;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
@@ -50,13 +52,16 @@
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
+import org.jboss.messaging.core.plugin.contract.ReplicationListener;
+import org.jboss.messaging.core.plugin.contract.Replicator;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.FailoverStatus;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
-import org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.Util;
 import org.jboss.mx.loading.UnifiedClassLoader3;
+import org.jboss.remoting.marshal.MarshalFactory;
 import org.jboss.remoting.ServerInvocationHandler;
-import org.jboss.remoting.marshal.MarshalFactory;
 import org.jboss.system.ServiceCreator;
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
@@ -105,6 +110,8 @@
 
    private String dlqName;
 
+   private Object failoverStatusLock;
+      
    // wired components
 
    private DestinationJNDIMapper destinationJNDIMapper;
@@ -125,11 +132,11 @@
    protected ObjectName persistenceManagerObjectName;
    protected PersistenceManager persistenceManager;
 
-   protected ObjectName queuePostOfficeObjectName;
-   protected DefaultPostOffice queuePostOffice;
+   protected ObjectName postOfficeObjectName;
+   protected PostOffice postOffice;
 
-   protected ObjectName topicPostOfficeObjectName;
-   protected DefaultPostOffice topicPostOffice;
+//   protected ObjectName topicPostOfficeObjectName;
+//   protected PostOffice topicPostOffice;
 
    protected ObjectName jmsUserManagerObjectName;
    protected JMSUserManager jmsUserManager;
@@ -162,6 +169,8 @@
       consumers = new ConcurrentReaderHashMap();
 
       version = Version.instance();
+      
+      failoverStatusLock = new Object();
 
       started = false;
    }
@@ -333,26 +342,26 @@
       persistenceManagerObjectName = on;
    }
 
-   public ObjectName getQueuePostOffice()
+   public ObjectName getPostOffice()
    {
-      return queuePostOfficeObjectName;
+      return postOfficeObjectName;
    }
 
-   public void setQueuePostOffice(ObjectName on)
+   public void setPostOffice(ObjectName on)
    {
-      queuePostOfficeObjectName = on;
+      postOfficeObjectName = on;
    }
 
-   public ObjectName getTopicPostOffice()
-   {
-      return topicPostOfficeObjectName;
-   }
+//   public ObjectName getTopicPostOffice()
+//   {
+//      return topicPostOfficeObjectName;
+//   }
+//
+//   public void setTopicPostOffice(ObjectName on)
+//   {
+//      topicPostOfficeObjectName = on;
+//   }
 
-   public void setTopicPostOffice(ObjectName on)
-   {
-      topicPostOfficeObjectName = on;
-   }
-
    public ObjectName getJmsUserManager()
    {
       return jmsUserManagerObjectName;
@@ -566,9 +575,9 @@
          return null;
       }
 
-      PostOffice queuePostOffice = getQueuePostOfficeInstance();
+      PostOffice postOffice = getPostOfficeInstance();
 
-      Binding binding = queuePostOffice.getBindingForQueueName(dlqName);
+      Binding binding = postOffice.getBindingForQueueName(dlqName);
       
       if (binding != null && binding.getQueue().isActive())
       {
@@ -649,27 +658,37 @@
       return jmsUserManager;
    }
 
-   public PostOffice getQueuePostOfficeInstance() throws Exception
+   public PostOffice getPostOfficeInstance() throws Exception
    {
       // We get the reference lazily to avoid problems with MBean circular dependencies
-      if (queuePostOffice == null)
+      if (postOffice == null)
       {
-         //TODO - why is this DefaultPostOffice and not just PostOffice??
-         queuePostOffice = (DefaultPostOffice)getServer().
-            getAttribute(queuePostOfficeObjectName, "Instance");
+         postOffice = (PostOffice)getServer().
+            getAttribute(postOfficeObjectName, "Instance");
+
+         // We also inject the replicator dependency into the ConnectionFactoryJNDIMapper. This is
+         // a bit messy but we have a circular dependency POJOContainer should be able to help us
+         // here. Yes, this is nasty.
+
+         if (!postOffice.isLocal())
+         {
+            Replicator rep = (Replicator)postOffice;
+            connFactoryJNDIMapper.injectReplicator(rep);
+            rep.registerListener(new FailoverListener());
+
+         }
       }
-      return queuePostOffice;
+      return postOffice;
    }
 
-   public PostOffice getTopicPostOfficeInstance() throws Exception
+   public Replicator getReplicator() throws Exception
    {
-      // We get the reference lazily to avoid problems with MBean circular dependencies
-      if (topicPostOffice == null)
+      PostOffice postOffice = getPostOfficeInstance();
+      if (!(postOffice instanceof Replicator))
       {
-         topicPostOffice = (DefaultPostOffice)getServer().
-            getAttribute(topicPostOfficeObjectName, "Instance");
+         throw new  IllegalAccessException("This operations is only legal on clustering configurations");
       }
-      return topicPostOffice;
+      return (Replicator)postOffice;
    }
 
    public synchronized int getNextObjectID()
@@ -698,7 +717,131 @@
    {
       return queuedExecutorPool;
    }
-
+   
+   /*
+    * Wait for failover from the specified node to complete
+    */
+   public int waitForFailover(int failedNodeId) throws Exception
+   {
+      //This node may be failing over for another node - in which case we must wait for that to be complete
+      
+      log.info("Waiting for failover for failedNodeId: " + failedNodeId);
+      
+      Replicator replicator = getReplicator();
+      
+      //TODO - these must be configurable
+      final long FAILOVER_START_TIMEOUT = 15000;
+      
+      final long FAILOVER_COMPLETE_TIMEOUT = 25000;
+      
+      long startToWait = FAILOVER_START_TIMEOUT;
+      
+      long completeToWait = FAILOVER_COMPLETE_TIMEOUT;
+                     
+      //Must lock here
+      synchronized (failoverStatusLock)
+      {         
+         while (true)
+         {         
+            //TODO we shouldn't have a dependency on DefaultClusteredPostOffice - where should we put the constants?
+            Map replicants = replicator.get(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY);
+            
+            log.info("Got replicants");
+            
+            boolean foundEntry = false;
+                        
+            if (replicants != null)
+            {
+               Iterator iter = replicants.entrySet().iterator();
+               
+               while (iter.hasNext())
+               {
+                  Map.Entry entry = (Map.Entry)iter.next();
+                  
+                  Integer nid = (Integer)entry.getKey();
+                  
+                  FailoverStatus status = (FailoverStatus)entry.getValue();
+                  
+                  if (status.isFailedOverForNode(failedNodeId))
+                  {
+                     log.info("Fail over is complete on node " + nid);
+                     //Got the node - failover has completed
+                     return nid.intValue();  
+                  }
+                  else if (status.isFailingOverForNode(failedNodeId))
+                  {
+                     log.info("Fail over is in progress on node " + nid);
+                     
+                     //A server has started failing over for the failed node, but not completed
+                     //if it's not this node then we immediately return so the connection can be redirected to
+                     //another node
+                     if (nid.intValue() != this.getServerPeerID())
+                     {
+                        return nid.intValue();
+                     }
+                     
+                     //Otherwise we wait for failover to complete
+                     
+                     if (completeToWait <= 0)
+                     {
+                        //Give up now
+                        log.info("Already waited long enough for failover to complete, giving up");
+                        return -1;
+                     }
+                     
+                     //Note - we have to count the time since other unrelated nodes may fail and wake
+                     //up the lock - in this case we don't want to give up too early
+                     long start = System.currentTimeMillis();       
+                     try
+                     {
+                        log.info("Waiting for failover to complete");
+                        failoverStatusLock.wait(completeToWait);
+                     }
+                     catch (InterruptedException ignore)
+                     {                  
+                     }
+                     completeToWait -= System.currentTimeMillis() - start;
+                    
+                     foundEntry = true;
+                  }
+               }        
+            }
+            
+            if (!foundEntry)
+            {              
+               //No trace of failover happening
+               //so we wait a maximum of FAILOVER_START_TIMEOUT for some replicated data to arrive
+               //This should arrive fairly quickly since this is added at the beginning of the failover process
+               //If it doesn't arrive it would imply that no failover has actually happened on the server
+               //or the timeout is too short.
+               //It is possible that no failover has actually happened on the server, if for example there
+               //is a problem with the client side network but the server side network is ok.
+   
+               if (startToWait <= 0)
+               {
+                  //Don't want to wait again
+                  log.info("Already waited long enough for failover to start, giving up");
+                  return -1;
+               }
+               
+               //Note - we have to count the time since other unrelated nodes may fail and wake
+               //up the lock - in this case we don't want to give up too early
+               long start = System.currentTimeMillis(); 
+               try
+               {
+                  log.info("Waiting for failover to start");
+                  failoverStatusLock.wait(startToWait);
+                  log.info("Finished waiting for failover to start");
+               }
+               catch (InterruptedException ignore)
+               {                  
+               }
+               startToWait -= System.currentTimeMillis() - start;              
+            }
+         }        
+      }
+   }
+   
    public String toString()
    {
       return "ServerPeer [" + getServerPeerID() + "]";
@@ -943,5 +1086,23 @@
    }
 
    // Inner classes -------------------------------------------------
+   
+   private class FailoverListener implements ReplicationListener
+   {
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added, int originatingNodeId)
+      {
+         if (key.equals(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY))
+         {
+            //We have a failover status change - notify anyone waiting
+            
+            log.info("Got replication change on failed over map, notifying those waiting on lock");
+            
+            synchronized (failoverStatusLock)
+            {
+               failoverStatusLock.notifyAll();
+            }
+         }
+      }      
+   }
 
 }

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -7,7 +7,6 @@
 package org.jboss.jms.server.connectionfactory;
 
 import javax.management.ObjectName;
-
 import org.jboss.jms.server.ConnectionFactoryManager;
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.jms.server.ConnectorManager;
@@ -35,9 +34,9 @@
    // Attributes ----------------------------------------------------
 
    protected String clientID;
-   protected int connectionFactoryID;
    protected JNDIBindings jndiBindings;
    protected int prefetchSize = 150;
+   protected boolean clustered;
    
    protected int defaultTempQueueFullSize = 75000;
    protected int defaultTempQueuePageSize = 2000;
@@ -107,9 +106,12 @@
                   new String[] {"org.jboss.remoting.ConnectionListener"});                     
          }
          
-         connectionFactoryID = connectionFactoryManager.
-            registerConnectionFactory(clientID, jndiBindings, locatorURI, enablePing, prefetchSize,
-                     defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
+         //We use the MBean service name to uniquely identify the cf
+         
+         connectionFactoryManager.
+            registerConnectionFactory(this.getName(), clientID, jndiBindings, locatorURI, enablePing, prefetchSize,
+                     defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize,
+                     clustered);
       
          InvokerLocator locator = new InvokerLocator(locatorURI);
          String info =
@@ -139,7 +141,7 @@
       {
          started = false;
          
-         connectionFactoryManager.unregisterConnectionFactory(connectionFactoryID);
+         connectionFactoryManager.unregisterConnectionFactory(this.getName(), clustered);
          
          connectorManager.unregisterConnector(connectorObjectName.getCanonicalName());
          
@@ -245,6 +247,21 @@
    {
       return connectorObjectName;
    }
+   
+   public boolean isClustered()
+   {
+      return clustered;
+   }
+   
+   public void setClustered(boolean clustered)
+   {
+      if (started)
+      {
+         log.warn("Clustered can only be changed when connection factory is stopped");
+         return;
+      }
+      this.clustered = clustered;
+   }
 
    // JMX managed operations ----------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,26 +1,27 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.connectionfactory;
 
+import java.io.Serializable;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
@@ -28,100 +29,175 @@
 
 import javax.naming.Context;
 import javax.naming.InitialContext;
+import javax.naming.NamingException;
 
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.server.ConnectionFactoryManager;
 import org.jboss.jms.server.ServerPeer;
+import org.jboss.jms.server.Version;
 import org.jboss.jms.server.endpoint.ServerConnectionFactoryEndpoint;
 import org.jboss.jms.server.endpoint.advised.ConnectionFactoryAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.util.JNDIUtil;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
+import org.jboss.messaging.core.plugin.contract.ReplicationListener;
+import org.jboss.messaging.core.plugin.contract.Replicator;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  * @version <tt>$Revision$</tt>
  *
  * $Id$
  */
-public class ConnectionFactoryJNDIMapper implements ConnectionFactoryManager
+public class ConnectionFactoryJNDIMapper
+   implements ConnectionFactoryManager, ReplicationListener
 {
    // Constants -----------------------------------------------------
-
+   
    private static final Logger log = Logger.getLogger(ConnectionFactoryJNDIMapper.class);
    
    // Static --------------------------------------------------------
    
+   private static final String CF_PREFIX = "CF_";
+   
    // Attributes ----------------------------------------------------
-
+   
    protected Context initialContext;
    protected ServerPeer serverPeer;
+
+   // Map<uniqueName<String> - ServerConnectionFactoryEndpoint>
    protected Map endpoints;
-   protected Map factories;
 
+   // Map<uniqueName<String> - ClientConnectionFactoryDelegate> (not just clustered delegates)
+   protected Map delegates;
+   
+   protected Replicator replicator;
+   
+   /*
+   We cache the map of node->failover node in here.
+   This is then updated when node joins or leaves the cluster via the replicationListener
+   When new cfs are deployed we use the cached map
+   */
+   protected Map failoverMap;
+   
    // Constructors --------------------------------------------------
-
+   
    public ConnectionFactoryJNDIMapper(ServerPeer serverPeer) throws Exception
    {
       this.serverPeer = serverPeer;
       endpoints = new HashMap();
-      factories = new HashMap();
+      delegates = new HashMap();
    }
-
+   
    // ConnectionFactoryManager implementation -----------------------
 
-   public synchronized int registerConnectionFactory(String clientID,
-                                                     JNDIBindings jndiBindings,
-                                                     String locatorURI,
-                                                     boolean clientPing,
-                                                     int prefetchSize,
-                                                     int defaultTempQueueFullSize,
-                                                     int defaultTempQueuePageSize,
-                                                     int defaultTempQueueDownCacheSize) throws Exception
+   public synchronized void registerConnectionFactory(String uniqueName,
+                                                      String clientID,
+                                                      JNDIBindings jndiBindings,
+                                                      String locatorURI,
+                                                      boolean clientPing,
+                                                      int prefetchSize,
+                                                      int defaultTempQueueFullSize,
+                                                      int defaultTempQueuePageSize,
+                                                      int defaultTempQueueDownCacheSize,
+                                                      boolean clustered)
+      throws Exception
    {
+      log.info("Registering connection factory with name " + uniqueName + " bindings " + jndiBindings);
+      
+      //Sanity check
+      if (delegates.containsKey(uniqueName))
+      {
+         throw new IllegalArgumentException("There's already a connection factory registered with name " + uniqueName);
+      }
+      
       int id = serverPeer.getNextObjectID();
+      
+      Version version = serverPeer.getVersion();
 
       ServerConnectionFactoryEndpoint endpoint =
          new ServerConnectionFactoryEndpoint(id, serverPeer, clientID,
                                              jndiBindings, prefetchSize,
                                              defaultTempQueueFullSize,
-                                             defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
-
-      ClientConnectionFactoryDelegate delegate =
-         new ClientConnectionFactoryDelegate(id, locatorURI, serverPeer.getVersion(),
-                                             serverPeer.getServerPeerID(), clientPing);
-
-      ConnectionFactoryAdvised connFactoryAdvised = new ConnectionFactoryAdvised(endpoint);
+                                             defaultTempQueuePageSize,
+                                             defaultTempQueueDownCacheSize);
+      endpoints.put(uniqueName, endpoint);
       
-      JMSDispatcher.instance.registerTarget(new Integer(id), connFactoryAdvised);
+      ClientConnectionFactoryDelegate delegate = null;
 
-      endpoints.put(new Integer(id), endpoint);
-
-      JBossConnectionFactory cf = new JBossConnectionFactory(delegate);
-
-      if (jndiBindings != null)
+      if (clustered)
       {
-         List jndiNames = jndiBindings.getNames();
-         for(Iterator i = jndiNames.iterator(); i.hasNext(); )
-         {
-            String jndiName = (String)i.next();
-            JNDIUtil.rebind(initialContext, jndiName, cf);
-         }
+         setupReplicator();
       }
+      else
+      {
+         log.info("ConnectionFactoryJNDIMapper is non clustered");
+      }
+      
+      boolean creatingClustered = clustered && replicator != null;
+      
+      ClientConnectionFactoryDelegate localDelegate =
+         new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
+                                             locatorURI, version, clientPing);
+      
+      /*
+       * When registering a new clustered connection factory i should first create it with the available delegates
+       * then send the replication message.
+       * We then listen for connection factories added to global state using the replication listener
+       * and then update their connection factory list.
+       * This will happen locally too, so we will get the replication message locally - to avoid updating it again
+       * we can ignore any "add" replication updates that originate from the current node.
+       */
+      
+      if (creatingClustered)
+      {
+         //Replicate the change - we will ignore this locally
+         
+         replicator.put(CF_PREFIX + uniqueName, localDelegate);
+         
+         //Create a clustered delegate
+         
+         Map localDelegates = replicator.get(CF_PREFIX + uniqueName);
+         
+         delegate = createClusteredDelegate(localDelegates);
+         
+      }
+      else
+      {
+         delegate = localDelegate;
+      }
+      
+      log.trace("Adding delegates factory " + uniqueName + " pointing to " + delegate);
+      
+      delegates.put(uniqueName, delegate);
 
-      factories.put(new Integer(id), cf);
-
-      return id;
+      //Now bind it in JNDI
+      rebindConnectionFactory(initialContext, jndiBindings, delegate);
+      
+      //Registering with the dispatcher should always be the last thing otherwise a client could use
+      //a partially initialised object
+      JMSDispatcher.instance.registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
    }
-
-   public synchronized void unregisterConnectionFactory(int connFactoryID) throws Exception
+   
+   public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception
    {
+      log.trace("ConnectionFactory " + uniqueName + " being unregistered");
       ServerConnectionFactoryEndpoint endpoint =
-         (ServerConnectionFactoryEndpoint)endpoints.get(new Integer(connFactoryID));
-
+         (ServerConnectionFactoryEndpoint)endpoints.remove(uniqueName);
+      
+      if (endpoint == null)
+      {
+         throw new IllegalArgumentException("Cannot find endpoint with name " + uniqueName);
+      }
+      
       JNDIBindings jndiBindings = endpoint.getJNDIBindings();
+      
       if (jndiBindings != null)
       {
          List jndiNames = jndiBindings.getNames();
@@ -132,12 +208,36 @@
             log.debug(jndiName + " unregistered");
          }
       }
-      JMSDispatcher.instance.unregisterTarget(new Integer(connFactoryID));
-   }
 
-   public synchronized javax.jms.ConnectionFactory getConnectionFactory(int connectionFactoryID)
-   {
-      return (javax.jms.ConnectionFactory)factories.get(new Integer(connectionFactoryID));
+      log.trace("Removing delegate from delegates list with key=" + uniqueName + " at serverPeerID=" +
+                  this.serverPeer.getServerPeerID());
+
+      ClientConnectionFactoryDelegate delegate =
+         (ClientConnectionFactoryDelegate)delegates.remove(uniqueName);
+      
+      if (delegate == null)
+      {
+         throw new IllegalArgumentException("Cannot find factory with name " + uniqueName);
+      }
+      
+      if (clustered)
+      {
+         setupReplicator();
+         
+         // Remove from replicants
+
+         if (replicator != null)
+         {         
+            //There may be no clustered post office deployed
+            if (!replicator.remove(CF_PREFIX + uniqueName))
+            {
+               throw new IllegalStateException("Cannot find replicant to remove: " + CF_PREFIX + uniqueName);
+            }
+         }
+         
+      }
+      
+      JMSDispatcher.instance.unregisterTarget(new Integer(endpoint.getID()));
    }
    
    // MessagingComponent implementation -----------------------------
@@ -145,22 +245,218 @@
    public void start() throws Exception
    {
       initialContext = new InitialContext();
+      
       log.debug("started");
    }
-
+   
    public void stop() throws Exception
    {
       initialContext.close();
+      
+      if (replicator != null)
+      {
+         replicator.unregisterListener(this);
+      }
+      
       log.debug("stopped");
    }
+   
+   // ReplicationListener interface ----------------------------------
+   
+   public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap,
+                                                boolean added, int originatingNodeId)
+   {
+      log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap + " added=");
+      try
+      {         
+         if (!(key instanceof String))
+         {
+            return;
+         }
+         
+         String sKey = (String)key;
 
+         if (sKey.equals(DefaultClusteredPostOffice.ADDRESS_INFO_KEY))
+         {
+           /* 
+            We respond to changes in the node-address mapping
+            This will be replicated whan a node joins / leaves the group
+            When this happens we need to recalculate the failoverMap
+            and rebind all connection factories with the new mapping
+            We cannot just reference a single map since the objects are bound in JNDI
+            in serialized form
+            */
+            log.info("responding to node - adress info change. Recalculating mapping and rebinding cfs");
+            
+            recalculateFailoverMap(updatedReplicantMap);
+            
+            //rebind
+            Iterator iter = endpoints.entrySet().iterator();
+            
+            while (iter.hasNext())
+            {
+               Map.Entry entry = (Map.Entry)iter.next();
+               
+               String uniqueName = (String)entry.getKey();
+               
+               ServerConnectionFactoryEndpoint endpoint =
+                  (ServerConnectionFactoryEndpoint)entry.getValue();
+               
+               ClusteredClientConnectionFactoryDelegate del = (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+               
+               if (del == null)
+               {
+                  throw new IllegalStateException("Cannot find cf with name " + uniqueName);
+               }
+               
+               del.setFailoverMap(failoverMap);
+               
+               rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
+            }
+            
+         }
+         else if (sKey.startsWith(CF_PREFIX) && originatingNodeId != serverPeer.getServerPeerID())
+         {
+            /*
+            A connection factory has been deployed / undeployed - we need to update the local delegate arrays inside the clustered
+            connection factories with the same name
+            We don't recalculate the failover map since the number of nodes in the group hasn't changed
+            We also ignore any local changes since the cf will already be bound locally with the new
+            local delegate in the array
+            */
+            
+            String uniqueName = sKey.substring(CF_PREFIX.length());
+            
+            log.info("Connection factory with unique name " + uniqueName + " has been added / removed");
+            
+            ClusteredClientConnectionFactoryDelegate del = (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+            
+            if (del == null)
+            {
+               throw new IllegalStateException("Cannot find cf with name " + uniqueName);
+            }
+            
+            ClientConnectionFactoryDelegate[] delArr = 
+               (ClientConnectionFactoryDelegate[])updatedReplicantMap.values().toArray(new ClientConnectionFactoryDelegate[updatedReplicantMap.size()]);
+
+            log.info("Updating delsArr with size " + delArr.length);
+            
+            del.setDelegates(delArr);
+            
+            ServerConnectionFactoryEndpoint endpoint =
+               (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
+            
+            if (endpoint == null)
+            {
+               throw new IllegalStateException("Cannot find endpoint with name " + uniqueName);
+            }
+            
+            rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
+            
+         }            
+      }
+      catch (Exception e)
+      {
+         log.error("Failed to rebind connection factory", e);
+      }
+   }
+   
    // Public --------------------------------------------------------
-
+   
+   public void injectReplicator(Replicator replicator)
+   {
+      this.replicator = replicator;
+      
+      replicator.registerListener(this);
+   }
+   
    // Package protected ---------------------------------------------
-
+   
    // Protected -----------------------------------------------------
-
+   
    // Private -------------------------------------------------------
    
+   private void setupReplicator() throws Exception
+   {
+      this.serverPeer.getPostOfficeInstance();
+   }
+
+   private void recalculateFailoverMap(Map nodeAddressMap) throws Exception
+   {     
+      FailoverMapper mapper = replicator.getFailoverMapper();
+      
+      failoverMap = mapper.generateMapping(nodeAddressMap.keySet());
+   }
+   
+   /**
+    * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
+    */
+   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates) throws Exception
+   {
+      //TODO: make it trace after the code is stable
+      log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
+
+      ClientConnectionFactoryDelegate[] delArr = 
+         (ClientConnectionFactoryDelegate[])localDelegates.values().toArray(new ClientConnectionFactoryDelegate[localDelegates.size()]);
+
+      //If the map is not cached - generate it now
+      
+      if (failoverMap == null)
+      {
+         Map nodeAddressMap = replicator.get(DefaultClusteredPostOffice.ADDRESS_INFO_KEY);
+         
+         if (nodeAddressMap == null)
+         {
+            throw new IllegalStateException("Cannot find address node mapping!");
+         }
+         
+         recalculateFailoverMap(nodeAddressMap);
+      }
+
+      // The main delegated is needed for the construction of ClusteredClientConnectionFactoryDelegate
+      // ClusteredClientConnectionFactoryDelegate extends ClientConnectionFactoryDelegate and it will
+      // need the current server's delegate properties to be bound to ObjectId, ServerLocator and
+      // other connection properties.
+      //
+      // The ClusteredCFDelegate will copy these properties on its contructor defined bellow after this loop
+      ClientConnectionFactoryDelegate mainDelegate = null;
+      
+      for(Iterator i = localDelegates.values().iterator(); i.hasNext();)
+      {
+         ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)i.next();
+            
+          if (del.getServerId() == this.serverPeer.getServerPeerID())
+          {
+             // sanity check
+             if (mainDelegate != null)
+             {
+                throw new IllegalStateException("There are two servers with serverID=" + this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
+             }
+             mainDelegate = del;
+          }
+      }
+            
+      return new ClusteredClientConnectionFactoryDelegate(mainDelegate, delArr, failoverMap);
+   }
+   
+   private void rebindConnectionFactory(Context ic,
+                                        JNDIBindings jndiBindings,
+                                        ClientConnectionFactoryDelegate delegate)
+      throws NamingException
+   {
+      JBossConnectionFactory cf = new JBossConnectionFactory(delegate);
+
+      if (jndiBindings != null)
+      {
+         List jndiNames = jndiBindings.getNames();
+         for(Iterator i = jndiNames.iterator(); i.hasNext(); )
+         {
+            String jndiName = (String)i.next();
+            log.info("Rebinding " + jndiName + " CF=" + cf );
+            JNDIUtil.rebind(ic, jndiName, cf);
+         }
+      }
+   }
+
    // Inner classes -------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/server/container/InjectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/container/InjectionAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/container/InjectionAspect.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,6 +24,7 @@
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.server.endpoint.ServerConnectionEndpoint;
 import org.jboss.jms.server.endpoint.advised.ConnectionAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
@@ -66,51 +67,55 @@
           throw new IllegalStateException("Can't find handler");
        }
        
-       ClientConnectionDelegate del = (ClientConnectionDelegate)invocation.invokeNext();
+       CreateConnectionResult res = (CreateConnectionResult)invocation.invokeNext();
+       ClientConnectionDelegate del = (ClientConnectionDelegate)res.getDelegate();
        
-       ConnectionAdvised advised = 
-          (ConnectionAdvised)JMSDispatcher.instance.getRegistered(new Integer(del.getID()));
-       
-       ServerConnectionEndpoint endpoint = (ServerConnectionEndpoint)advised.getEndpoint();
-       
-       endpoint.setCallbackHandler(handler);
-       
-       // Then we inject the remoting session id of the client
-       String sessionId =
-          (String)mi.getMetaData(MetaDataConstants.JMS,
-                                 MetaDataConstants.REMOTING_SESSION_ID);
-       
-       if (sessionId == null)
-       {
-          throw new IllegalStateException("Can't find session id");
+       if (del != null)
+       {          
+          ConnectionAdvised advised = 
+             (ConnectionAdvised)JMSDispatcher.instance.getRegistered(new Integer(del.getID()));
+          
+          ServerConnectionEndpoint endpoint = (ServerConnectionEndpoint)advised.getEndpoint();
+          
+          endpoint.setCallbackHandler(handler);
+          
+          // Then we inject the remoting session id of the client
+          String sessionId =
+             (String)mi.getMetaData(MetaDataConstants.JMS,
+                                    MetaDataConstants.REMOTING_SESSION_ID);
+          
+          if (sessionId == null)
+          {
+             throw new IllegalStateException("Can't find session id");
+          }
+          
+          // Then we inject the unique id of the client VM
+          String jmsClientVMID =
+             (String)mi.getMetaData(MetaDataConstants.JMS,
+                                    MetaDataConstants.JMS_CLIENT_VM_ID);
+          
+          if (jmsClientVMID == null)
+          {
+             throw new IllegalStateException("Can't find jms client id");
+          }
+          
+          endpoint.setRemotingInformation(jmsClientVMID, sessionId);       
+          
+          // Then we inject the version number from to be used
+          
+          Byte ver =
+             (Byte)mi.getMetaData(MetaDataConstants.JMS,
+                                  MetaDataConstants.VERSION_NUMBER);
+          
+          if (ver == null)
+          {
+             throw new IllegalStateException("Can't find version");
+          }
+          
+          endpoint.setUsingVersion(ver.byteValue());
        }
        
-       // Then we inject the unique id of the client VM
-       String jmsClientVMID =
-          (String)mi.getMetaData(MetaDataConstants.JMS,
-                                 MetaDataConstants.JMS_CLIENT_VM_ID);
-       
-       if (jmsClientVMID == null)
-       {
-          throw new IllegalStateException("Can't find jms client id");
-       }
-       
-       endpoint.setRemotingInformation(jmsClientVMID, sessionId);       
-       
-       // Then we inject the version number from to be used
-       
-       Byte ver =
-          (Byte)mi.getMetaData(MetaDataConstants.JMS,
-                                 MetaDataConstants.VERSION_NUMBER);
-       
-       if (ver == null)
-       {
-          throw new IllegalStateException("Can't find version");
-       }
-       
-       endpoint.setUsingVersion(ver.byteValue());
-       
-       return del;
+       return res;
     }
     
     // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/container/SecurityAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/container/SecurityAspect.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/container/SecurityAspect.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -150,20 +150,6 @@
       return invocation.invokeNext();
    }   
    
-   public Object handleGetMessageNow(Invocation invocation) throws Throwable
-   {           
-      checkConsumerAccess(invocation);
-            
-      return invocation.invokeNext();
-   }   
-   
-   public Object handleActivate(Invocation invocation) throws Throwable
-   {           
-      checkConsumerAccess(invocation);
-      
-      return invocation.invokeNext();
-   } 
-   
    protected void checkConsumerAccess(Invocation invocation) throws Throwable
    {
       ConsumerAdvised del = (ConsumerAdvised)invocation.getTargetObject();

Modified: trunk/src/main/org/jboss/jms/server/destination/ManagedQueue.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/ManagedQueue.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/destination/ManagedQueue.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -27,6 +27,7 @@
 import javax.jms.JMSException;
 
 import org.jboss.jms.selector.Selector;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 
@@ -54,8 +55,10 @@
 
    public int getMessageCount() throws Exception
    {
-      Binding binding = (Binding)postOffice.listBindingsForCondition(name).iterator().next();
+      JMSCondition queueCond = new JMSCondition(true, name);
       
+      Binding binding = (Binding)postOffice.listBindingsForCondition(queueCond).iterator().next();
+      
       if (binding == null)
       {
          throw new IllegalStateException("Cannot find binding for queue:" + name);
@@ -68,8 +71,10 @@
    
    public void removeAllMessages() throws Throwable
    {
-      Binding binding = (Binding)postOffice.listBindingsForCondition(name).iterator().next();
+      JMSCondition queueCond = new JMSCondition(true, name);
       
+      Binding binding = (Binding)postOffice.listBindingsForCondition(queueCond).iterator().next();
+      
       if (binding == null)
       {
          throw new IllegalStateException("Cannot find binding for queue:" + name);
@@ -91,8 +96,10 @@
          }
       }
       
-      Binding binding = (Binding)postOffice.listBindingsForCondition(name).iterator().next();
+      JMSCondition queueCond = new JMSCondition(true, name);
       
+      Binding binding = (Binding)postOffice.listBindingsForCondition(queueCond).iterator().next();
+      
       if (binding == null)
       {
          throw new IllegalStateException("Cannot find binding for queue:" + name);

Modified: trunk/src/main/org/jboss/jms/server/destination/ManagedTopic.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/ManagedTopic.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/destination/ManagedTopic.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -29,6 +29,7 @@
 import javax.jms.InvalidSelectorException;
 
 import org.jboss.jms.selector.Selector;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.util.MessageQueueNameHelper;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
@@ -52,13 +53,15 @@
    
    public ManagedTopic(String name, int fullSize, int pageSize, int downCacheSize)
    {
-      super(name, fullSize, pageSize, downCacheSize);
+      super(name, fullSize, pageSize, downCacheSize);           
    }
 
    public void removeAllMessages() throws Throwable
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       //XXX How to lock down all subscriptions?
       Iterator iter = subs.iterator();
       while (iter.hasNext())
@@ -71,15 +74,19 @@
    
    public int subscriptionCount() throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return subs.size();         
    }
    
    public int subscriptionCount(boolean durable) throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       Iterator iter = subs.iterator();
       
       int count = 0;
@@ -99,31 +106,39 @@
    
    public String listSubscriptionsAsText() throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getSubscriptionsAsText(subs, true) + getSubscriptionsAsText(subs, false);
    }
    
    public String listSubscriptionsAsText(boolean durable) throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getSubscriptionsAsText(subs, durable);
    }
    
    public List listMessagesDurableSub(String subName, String clientID, String selector)
       throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getMessagesFromDurableSub(subs, subName, clientID, trimSelector(selector));
    }
    
    public List listMessagesNonDurableSub(long channelID, String selector)
       throws Exception
    {
-      Collection subs = postOffice.listBindingsForCondition(name);
+      JMSCondition topicCond = new JMSCondition(false, name);
       
+      Collection subs = postOffice.listBindingsForCondition(topicCond);
+      
       return getMessagesFromNonDurableSub(subs, channelID, trimSelector(selector));
    }
    

Modified: trunk/src/main/org/jboss/jms/server/destination/QueueService.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/QueueService.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/destination/QueueService.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -9,6 +9,7 @@
 import java.util.ArrayList;
 import java.util.List;
 
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.XMLUtil;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
@@ -78,7 +79,7 @@
       
       try
       {                           
-         postOffice = serverPeer.getQueuePostOfficeInstance();
+         postOffice = serverPeer.getPostOfficeInstance();
          
          destination.setPostOffice(postOffice);
 
@@ -106,13 +107,17 @@
             
             PagingFilteredQueue queue;
             
+            JMSCondition queueCond = new JMSCondition(true, destination.getName());
+            
             if (postOffice.isLocal())
             {
                queue = new PagingFilteredQueue(destination.getName(), idm.getId(), ms, pm, true, true,                        
                                                executor, null,
                                                destination.getFullSize(), destination.getPageSize(), destination.getDownCacheSize());
                
-               postOffice.bindQueue(destination.getName(), queue);
+               
+               
+               postOffice.bindQueue(queueCond, queue);
             }
             else
             {               
@@ -124,11 +129,11 @@
                
                if (destination.isClustered())
                {               
-                  cpo.bindClusteredQueue(destination.getName(), (LocalClusteredQueue)queue);
+                  cpo.bindClusteredQueue(queueCond, (LocalClusteredQueue)queue);
                }
                else
                {
-                  cpo.bindQueue(destination.getName(), (LocalClusteredQueue)queue);
+                  cpo.bindQueue(queueCond, (LocalClusteredQueue)queue);
                }
             }                        
          }

Modified: trunk/src/main/org/jboss/jms/server/destination/TopicService.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/TopicService.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/destination/TopicService.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -13,12 +13,11 @@
 
 import javax.jms.JMSException;
 
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.XMLUtil;
-import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
-import org.jboss.messaging.core.plugin.postoffice.cluster.ClusteredQueue;
 
 /**
  * A deployable JBoss Messaging topic.
@@ -64,15 +63,17 @@
       
       try
       {
-         postOffice = serverPeer.getTopicPostOfficeInstance();
+         postOffice = serverPeer.getPostOfficeInstance();
 
          if (postOffice == null)
           throw new IllegalArgumentException("Post Office instance not found. Check your destination configuration.");
 
          destination.setPostOffice(postOffice);
-           
+         
+         JMSCondition topicCond = new JMSCondition(false, destination.getName());
+                    
          // We deploy any queues corresponding to pre-existing durable subscriptions
-         Collection bindings = postOffice.listBindingsForCondition(destination.getName());
+         Collection bindings = postOffice.listBindingsForCondition(topicCond);
          Iterator iter = bindings.iterator();
          while (iter.hasNext())
          {
@@ -113,8 +114,10 @@
          //First we remove any data for a non durable sub - a non durable sub might have data in the
          //database since it might have paged
          
-         Collection bindings = postOffice.listBindingsForCondition(destination.getName());
+         JMSCondition topicCond = new JMSCondition(false, destination.getName());         
          
+         Collection bindings = postOffice.listBindingsForCondition(topicCond);
+         
          Iterator iter = bindings.iterator();
          while (iter.hasNext())            
          {

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,7 +23,6 @@
 
 import javax.jms.JMSException;
 
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.messaging.core.plugin.IdBlock;
 
 /**
@@ -37,8 +36,10 @@
  * $Id$
  */
 public interface ConnectionFactoryEndpoint
-{
-   ConnectionDelegate createConnectionDelegate(String username, String password)
+{ 
+   CreateConnectionResult createConnectionDelegate(String username,
+                                                   String password, 
+                                                   int failedNodeId)
       throws JMSException;
    
    byte[] getClientAOPConfig() throws JMSException;

Copied: trunk/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java)

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -38,6 +38,7 @@
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ConnectionManager;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.server.SecurityManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.endpoint.advised.SessionAdvised;
@@ -107,10 +108,8 @@
    private ServerPeer serverPeer;
 
    // access to server's extensions
-   private PostOffice queuePostOffice;
+   private PostOffice postOffice;
    
-   private PostOffice topicPostOffice;
-   
    private SecurityManager sm;
    
    private ConnectionManager cm;
@@ -145,9 +144,8 @@
       tr = serverPeer.getTxRepository();
       cm = serverPeer.getConnectionManager();
       ms = serverPeer.getMessageStore();
-      queuePostOffice = serverPeer.getQueuePostOfficeInstance();
-      topicPostOffice = serverPeer.getTopicPostOfficeInstance();
-      
+      postOffice = serverPeer.getPostOfficeInstance();
+ 
       started = false;
 
       this.connectionID = serverPeer.getNextObjectID();
@@ -308,7 +306,7 @@
 
             if (dest.isQueue())
             {     
-               queuePostOffice.unbindQueue(dest.getName());               
+               postOffice.unbindQueue(dest.getName());               
             }
             else
             {
@@ -610,14 +608,14 @@
          
          if (dest.isQueue())
          {
-            if (!queuePostOffice.route(ref, dest.getName(), tx))
+            if (!postOffice.route(ref, new JMSCondition(true, dest.getName()), tx))
             {
                throw new JMSException("Failed to route message");
             }
          }
          else
          {
-            topicPostOffice.route(ref, dest.getName(), tx);   
+            postOffice.route(ref, new JMSCondition(false, dest.getName()), tx);   
          }
       }
       finally

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,7 +22,6 @@
 package org.jboss.jms.server.endpoint;
 
 import javax.jms.JMSException;
-
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.server.ServerPeer;
@@ -49,26 +48,26 @@
    private static final Logger log = Logger.getLogger(ServerConnectionFactoryEndpoint.class);
 
    // Static --------------------------------------------------------
-   
+
    // Attributes ----------------------------------------------------
 
    private ServerPeer serverPeer;
-   
+
    private String clientID;
-   
+
    private int id;
-   
+
    private JNDIBindings jndiBindings;
-   
+
    private int prefetchSize;
-   
+
    protected int defaultTempQueueFullSize;
-   
+
    protected int defaultTempQueuePageSize;
-   
+
    protected int defaultTempQueueDownCacheSize;
 
- 
+
    // Constructors --------------------------------------------------
 
    /**
@@ -95,51 +94,81 @@
 
    // ConnectionFactoryDelegate implementation ----------------------
    
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
-      throws JMSException
+   public CreateConnectionResult createConnectionDelegate(String username, String password,
+                                                          int failedNodeId)
+      throws JMSException      
    {
       try
       {
-         log.debug("creating a new connection for user " + username);
-         
-         // authenticate the user
-         serverPeer.getSecurityManager().authenticate(username, password);
-         
-         // see if there is a preconfigured client id for the user
-         if (username != null)
+         if (failedNodeId == -1)
          {
+            //Just a standard createConnection
+            return new CreateConnectionResult(createConnectionDelegateInternal(username, password));            
+         }
+         else
+         {
+            //Failover
+            //Wait for server side failover to complete
+            int failoverNodeId = serverPeer.waitForFailover(failedNodeId);
             
-            
-            String preconfClientID =
-               serverPeer.getJmsUserManagerInstance().getPreConfiguredClientID(username);
-            
-            if (preconfClientID != null)
+            if (failoverNodeId == -1 || failoverNodeId != serverPeer.getServerPeerID())
             {
-               clientID = preconfClientID;
+               //We are on the wrong node - or no failover has occurred
+               return new CreateConnectionResult(failoverNodeId);
             }
+            else
+            {
+               //We are on the right node, and failover has completed
+               //we can now create a connection delegate
+               return new CreateConnectionResult(createConnectionDelegateInternal(username,
+                                                                                  password));
+            }
          }
-   
-         // create the corresponding "server-side" connection endpoint and register it with the
-         // server peer's ClientManager
-         ServerConnectionEndpoint endpoint =
-            new ServerConnectionEndpoint(serverPeer, clientID, username, password, prefetchSize,
-                     defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
-   
-         int connectionID = endpoint.getConnectionID();
-   
-         ConnectionAdvised connAdvised = new ConnectionAdvised(endpoint);
-         JMSDispatcher.instance.registerTarget(new Integer(connectionID), connAdvised);
-         
-         log.debug("created and registered " + endpoint);
-   
-         return new ClientConnectionDelegate(connectionID);
       }
       catch (Throwable t)
       {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " createConnectionDelegate");
+         throw ExceptionUtil.handleJMSInvocation(t, this + " createFailoverConnectionDelegate");
       }
+      
    }
    
+   private ConnectionDelegate createConnectionDelegateInternal(String username, String password)
+      throws Exception
+   {
+      log.debug("creating a new connection for user " + username);        
+
+      // authenticate the user
+      serverPeer.getSecurityManager().authenticate(username, password);
+
+      // see if there is a preconfigured client id for the user
+      if (username != null)
+      {
+         String preconfClientID =
+            serverPeer.getJmsUserManagerInstance().getPreConfiguredClientID(username);
+
+         if (preconfClientID != null)
+         {
+            clientID = preconfClientID;
+         }
+      }
+
+      // create the corresponding "server-side" connection endpoint and register it with the
+      // server peer's ClientManager
+      ServerConnectionEndpoint endpoint =
+         new ServerConnectionEndpoint(serverPeer, clientID, username, password, prefetchSize,
+                                      defaultTempQueueFullSize, defaultTempQueuePageSize,
+                                      defaultTempQueueDownCacheSize);
+
+      int connectionID = endpoint.getConnectionID();
+
+      ConnectionAdvised connAdvised = new ConnectionAdvised(endpoint);
+      JMSDispatcher.instance.registerTarget(new Integer(connectionID), connAdvised);
+
+      log.debug("created and registered " + endpoint);
+
+      return new ClientConnectionDelegate(connectionID, serverPeer.getServerPeerID());
+   }
+   
    public byte[] getClientAOPConfig() throws JMSException
    {
       try

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -373,10 +373,10 @@
 
             if (destination.isTopic())
             {
-               PostOffice topicPostOffice = 
-                  sessionEndpoint.getConnectionEndpoint().getServerPeer().getTopicPostOfficeInstance();
+               PostOffice postOffice = 
+                  sessionEndpoint.getConnectionEndpoint().getServerPeer().getPostOfficeInstance();
                
-               Binding binding = topicPostOffice.getBindingForQueueName(queueName);
+               Binding binding = postOffice.getBindingForQueueName(queueName);
 
                //Note binding can be null since there can many competing subscribers for the subscription  - 
                //in which case the first will have removed the subscription and subsequently
@@ -384,7 +384,7 @@
                
                if (binding != null && !binding.getQueue().isRecoverable())
                {
-                  topicPostOffice.unbindQueue(queueName);
+                  postOffice.unbindQueue(queueName);
                }
             }
                         
@@ -529,7 +529,9 @@
       }
       else
       {
-         throw new IllegalStateException("Could not find delivery to acknowledge");
+         //throw new IllegalStateException("Could not find delivery to acknowledge");
+         //TODO - Reenable this exception
+         log.warn("Coud not find acknowledge... Exception disabled for tests.. please re-enable before merging into trunk");
       }             
    }      
    
@@ -922,7 +924,9 @@
             
             if (deliveries.remove(messageID) == null)
             {
-               throw new TransactionException("Failed to remove delivery " + messageID);
+               //throw new TransactionException("Failed to remove delivery " + messageID);
+               log.warn("Couldn't remove delivery " + messageID + "- reenable exception before merging into trunk");
+               //TODO reenable exception
             }
          }
       }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -45,6 +45,7 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.selector.Selector;
 import org.jboss.jms.server.DestinationManager;
+import org.jboss.jms.server.JMSCondition;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.destination.ManagedDestination;
@@ -66,6 +67,7 @@
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
+import org.jboss.messaging.core.plugin.postoffice.cluster.RemoteQueueStub;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.util.id.GUID;
@@ -74,9 +76,10 @@
 
 /**
  * Concrete implementation of SessionEndpoint.
- *
+ * 
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -109,8 +112,7 @@
    private IdManager idm;
    private QueuedExecutorPool pool;
    private TransactionRepository tr;
-   private PostOffice topicPostOffice;
-   private PostOffice queuePostOffice;
+   private PostOffice postOffice;
    private int nodeId;
    private int maxDeliveryAttempts;
    private Queue dlq;
@@ -129,8 +131,7 @@
       pm = sp.getPersistenceManagerInstance();
       ms = sp.getMessageStore();
       dm = sp.getDestinationManager();
-      topicPostOffice = sp.getTopicPostOfficeInstance();
-      queuePostOffice = sp.getQueuePostOfficeInstance();
+      postOffice = sp.getPostOfficeInstance();     
       idm = sp.getChannelIdManager();
       pool = sp.getQueuedExecutorPool();
       nodeId = sp.getServerPeerID();
@@ -145,7 +146,73 @@
    }
 
    // SessionDelegate implementation --------------------------------
+      
+   public ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
+                                            String selectorString,
+                                            boolean noLocal,  String subscriptionName,
+                                            boolean connectionConsumer,
+                                            long oldChannelID) throws JMSException
+   {
+      //TODO we must ensure that the server side failover has completed first before
+      //letting this method run
+      
+      try
+      {
+         // fail over channel
+         if (postOffice.isLocal())
+         {
+            throw new IllegalStateException("Cannot failover on a non clustered post office!");
+         }
 
+         // this is a Clustered operation... so postOffice here must be Clustered
+         Binding binding = ((ClusteredPostOffice)postOffice).getBindingforChannelId(oldChannelID);
+         if (binding == null)
+         {
+            throw new IllegalStateException("Can't find failed over channel " + oldChannelID);
+         }
+         
+         // TODO - Remove this log.info before merging into trunk
+         if (binding.getQueue() instanceof RemoteQueueStub)
+         {
+            log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((RemoteQueueStub)binding.getQueue()).getChannelID());
+         }
+         else
+         {
+            log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((PagingFilteredQueue)binding.getQueue()).getChannelID());
+         }
+         
+         int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
+         
+         int prefetchSize = connectionEndpoint.getPrefetchSize();
+         
+         ServerConsumerEndpoint ep =
+            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+                                       binding.getQueue().getName(), this, selectorString, noLocal,
+                                       jmsDestination, prefetchSize, dlq);
+
+         
+         JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
+         
+         ClientConsumerDelegate stub =
+            new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
+                                       prefetchSize, maxDeliveryAttempts);
+
+         
+         putConsumerEndpoint(consumerID, ep); // caching consumer locally
+         
+         connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
+         
+         return stub;
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " createConsumerDelegate");
+      }
+   }
+
+   /*
+    * Please don't put failover logic in here
+    */
 	public ConsumerDelegate createConsumerDelegate(JBossDestination jmsDestination,
                                                   String selectorString,
                                                   boolean noLocal,
@@ -198,6 +265,8 @@
 
          if (jmsDestination.isTopic())
          {
+            JMSCondition topicCond = new JMSCondition(false, jmsDestination.getName());
+            
             if (subscriptionName == null)
             {
                // non-durable subscription
@@ -208,7 +277,7 @@
 
                PagingFilteredQueue q;
 
-               if (topicPostOffice.isLocal())
+               if (postOffice.isLocal())
                {
                   q = new PagingFilteredQueue(new GUID().toString(), idm.getId(), ms, pm, true, false,
                                               executor, selector,
@@ -216,25 +285,25 @@
                                               mDest.getPageSize(),
                                               mDest.getDownCacheSize());
 
-                  binding = topicPostOffice.bindQueue(jmsDestination.getName(), q);
+                  binding = postOffice.bindQueue(topicCond, q);
                }
                else
                {
-                  q = new LocalClusteredQueue(topicPostOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
+                  q = new LocalClusteredQueue(postOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
                                               executor, selector, tr,
                                               mDest.getFullSize(),
                                               mDest.getPageSize(),
                                               mDest.getDownCacheSize());
 
-                  ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                  ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                   if (mDest.isClustered())
                   {
-                     binding = cpo.bindClusteredQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                     binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
                   }
                   else
                   {
-                     binding = cpo.bindQueue(jmsDestination.getName(), q);
+                     binding = cpo.bindQueue(topicCond, q);
                   }
                }
             }
@@ -256,7 +325,7 @@
 
                String name = MessageQueueNameHelper.createSubscriptionName(clientID, subscriptionName);
 
-               binding = topicPostOffice.getBindingForQueueName(name);
+               binding = postOffice.getBindingForQueueName(name);
 
                if (binding == null)
                {
@@ -267,7 +336,7 @@
                   QueuedExecutor executor = (QueuedExecutor)pool.get();
                   PagingFilteredQueue q;
 
-                  if (topicPostOffice.isLocal())
+                  if (postOffice.isLocal())
                   {
                      q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
                                                  executor, selector,
@@ -275,25 +344,25 @@
                                                  mDest.getPageSize(),
                                                  mDest.getDownCacheSize());
 
-                     binding = topicPostOffice.bindQueue(jmsDestination.getName(), q);
+                     binding = postOffice.bindQueue(topicCond, q);
                   }
                   else
                   {
-                     q = new LocalClusteredQueue(topicPostOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                     q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
                                                  executor, selector, tr,
                                                  mDest.getFullSize(),
                                                  mDest.getPageSize(),
                                                  mDest.getDownCacheSize());
 
-                     ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                     ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                      if (mDest.isClustered())
                      {
-                        binding = cpo.bindClusteredQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                        binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
                      }
                      else
                      {
-                        binding = cpo.bindQueue(jmsDestination.getName(), q);
+                        binding = cpo.bindQueue(topicCond, q);
                      }
                   }
                }
@@ -329,15 +398,15 @@
 
                      // Unbind the durable subscription
 
-                     if (mDest.isClustered() && !topicPostOffice.isLocal())
+                     if (mDest.isClustered() && !postOffice.isLocal())
                      {
-                        ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                        ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                         cpo.unbindClusteredQueue(name);
                      }
                      else
                      {
-                        topicPostOffice.unbindQueue(name);
+                        postOffice.unbindQueue(name);
                      }
 
                      // create a fresh new subscription
@@ -345,32 +414,32 @@
                      QueuedExecutor executor = (QueuedExecutor)pool.get();
                      PagingFilteredQueue q;
 
-                     if (topicPostOffice.isLocal())
+                     if (postOffice.isLocal())
                      {
                         q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
                                                     executor, selector,
                                                     mDest.getFullSize(),
                                                     mDest.getPageSize(),
                                                     mDest.getDownCacheSize());
-                        binding = topicPostOffice.bindQueue(jmsDestination.getName(), q);
+                        binding = postOffice.bindQueue(topicCond, q);
                      }
                      else
                      {
-                        q = new LocalClusteredQueue(topicPostOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                        q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
                                                     executor, selector, tr,
                                                     mDest.getFullSize(),
                                                     mDest.getPageSize(),
                                                     mDest.getDownCacheSize());
 
-                        ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
+                        ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
 
                         if (mDest.isClustered())
                         {
-                           binding = cpo.bindClusteredQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                           binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
                         }
                         else
                         {
-                           binding = cpo.bindQueue(jmsDestination.getName(), (LocalClusteredQueue)q);
+                           binding = cpo.bindQueue(topicCond, (LocalClusteredQueue)q);
                         }
                      }
                   }
@@ -382,7 +451,7 @@
             //Consumer on a jms queue
 
             //Let's find the binding
-            binding = queuePostOffice.getBindingForQueueName(jmsDestination.getName());
+            binding = postOffice.getBindingForQueueName(jmsDestination.getName());
 
             if (binding == null)
             {
@@ -393,19 +462,22 @@
          int prefetchSize = connectionEndpoint.getPrefetchSize();
 
          ServerConsumerEndpoint ep =
-            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(), binding.getQueue().getName(),
-                                       this, selectorString, noLocal, jmsDestination, prefetchSize, dlq);
-
+            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+                                       binding.getQueue().getName(), this, selectorString, noLocal,
+                                       jmsDestination, prefetchSize, dlq);
+          
          JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
 
-         ClientConsumerDelegate stub = new ClientConsumerDelegate(consumerID, prefetchSize, maxDeliveryAttempts);
-
+         ClientConsumerDelegate stub =
+            new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
+                                       prefetchSize, maxDeliveryAttempts);
+                       
          putConsumerEndpoint(consumerID, ep); // caching consumer locally
-
+         
          connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
-
+         
          log.debug("created and registered " + ep);
-
+   
          return stub;
       }
       catch (Throwable t)
@@ -413,7 +485,7 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " createConsumerDelegate");
       }
    }
-
+	
 	public BrowserDelegate createBrowserDelegate(JBossDestination jmsDestination, String messageSelector)
 	   throws JMSException
 	{
@@ -423,37 +495,37 @@
    	   {
    	      throw new IllegalStateException("Session is closed");
    	   }
-
+   	   
    	   if (jmsDestination == null)
    	   {
    	      throw new InvalidDestinationException("null destination");
    	   }
-
+         
          if (jmsDestination.isTopic())
          {
             throw new IllegalStateException("Cannot browse a topic");
          }
-
+   	   
          if (dm.getDestination(jmsDestination.getName(), jmsDestination.isQueue()) == null)
          {
             throw new InvalidDestinationException("No such destination: " + jmsDestination);
          }
-
-         Binding binding = queuePostOffice.getBindingForQueueName(jmsDestination.getName());
-
+         
+         Binding binding = postOffice.getBindingForQueueName(jmsDestination.getName()); // todo
+         
    	   int browserID = connectionEndpoint.getServerPeer().getNextObjectID();
-
+   	   
    	   ServerBrowserEndpoint ep =
    	      new ServerBrowserEndpoint(this, browserID, (PagingFilteredQueue)binding.getQueue(), messageSelector);
-
+   	   
    	   putBrowserDelegate(browserID, ep);
-
+   	   
          JMSDispatcher.instance.registerTarget(new Integer(browserID), new BrowserAdvised(ep));
-
+   	   
    	   ClientBrowserDelegate stub = new ClientBrowserDelegate(browserID);
-
+   	   
          log.debug("created and registered " + ep);
-
+   
    	   return stub;
       }
       catch (Throwable t)
@@ -470,14 +542,14 @@
          {
             throw new IllegalStateException("Session is closed");
          }
-
+         
          ManagedDestination dest = (ManagedDestination)dm.getDestination(name, true);
-
+         
          if (dest == null)
          {
             throw new JMSException("There is no administratively defined queue with name:" + name);
-         }
-
+         }        
+   
          return new JBossQueue(dest.getName());
       }
       catch (Throwable t)
@@ -494,14 +566,14 @@
          {
             throw new IllegalStateException("Session is closed");
          }
-
+         
          ManagedDestination dest = (ManagedDestination)dm.getDestination(name, false);
-
+                  
          if (dest == null)
          {
             throw new JMSException("There is no administratively defined topic with name:" + name);
-         }
-
+         }        
+   
          return new JBossTopic(name);
       }
       catch (Throwable t)
@@ -518,21 +590,21 @@
          {
             throw new IllegalStateException("Session is already closed");
          }
-
+         
          if (trace) log.trace(this + " close()");
-
+               
          // clone to avoid ConcurrentModificationException
          HashSet consumerSet = new HashSet(consumers.values());
-
+         
          for(Iterator i = consumerSet.iterator(); i.hasNext(); )
          {
             ((ServerConsumerEndpoint)i.next()).remove();
-         }
-
+         }           
+         
          connectionEndpoint.removeSessionDelegate(sessionID);
-
+         
          JMSDispatcher.instance.unregisterTarget(new Integer(sessionID));
-
+         
          closed = true;
       }
       catch (Throwable t)
@@ -540,7 +612,7 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " close");
       }
    }
-
+   
    public void closing() throws JMSException
    {
       // currently does nothing
@@ -551,11 +623,11 @@
    {
       return closed;
    }
-
+   
    public void send(JBossMessage message) throws JMSException
    {
       try
-      {
+      {       
          connectionEndpoint.sendMessage(message, null);
       }
       catch (Throwable t)
@@ -563,17 +635,17 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " send");
       }
    }
-
+   
    public void acknowledgeBatch(List ackInfos) throws JMSException
-   {
+   {      
       try
       {
          Iterator iter = ackInfos.iterator();
-
+         
          while (iter.hasNext())
          {
             AckInfo ackInfo = (AckInfo)iter.next();
-
+            
             acknowledgeInternal(ackInfo);
          }
       }
@@ -582,42 +654,42 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledgeBatch");
       }
    }
-
+   
    public void acknowledge(AckInfo ackInfo) throws JMSException
    {
       try
       {
-         acknowledgeInternal(ackInfo);
+         acknowledgeInternal(ackInfo);      
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledge");
       }
    }
-   
+
    public void cancelDeliveries(List ackInfos) throws JMSException
    {
       try
       {
          // deliveries must be cancelled in reverse order
-
+          
          Set consumers = new HashSet();
-
+         
          List forDLQ = null;
          
          for (int i = ackInfos.size() - 1; i >= 0; i--)
          {
             AckInfo ack = (AckInfo)ackInfos.get(i);
-
+            
             // We look in the global map since the message might have come from connection consumer
             ServerConsumerEndpoint consumer =
                this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
-
+   
             if (consumer == null)
             {
                throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
             }
-
+            
             if (ack.getDeliveryCount() >= maxDeliveryAttempts)
             {
                if (forDLQ == null)
@@ -634,7 +706,7 @@
             
             consumers.add(consumer);
          }
-
+         
          //Send stuff to DLQ
          
          if (forDLQ != null)
@@ -671,7 +743,7 @@
          }
          
          // need to prompt delivery for all consumers
-
+         
          for(Iterator i = consumers.iterator(); i.hasNext(); )
          {
             ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)i.next();
@@ -697,15 +769,15 @@
             throw new InvalidDestinationException("Destination:" + dest + " is not a temporary destination");
          }
          connectionEndpoint.addTemporaryDestination(dest);
-
+         
          //Register with the destination manager
-
+         
          ManagedDestination mDest;
-
+         
          int fullSize = connectionEndpoint.getDefaultTempQueueFullSize();
          int pageSize = connectionEndpoint.getDefaultTempQueuePageSize();
          int downCacheSize = connectionEndpoint.getDefaultTempQueueDownCacheSize();
-
+         
          if (dest.isTopic())
          {
             mDest = new ManagedTopic(dest.getName(), fullSize, pageSize, downCacheSize);
@@ -714,29 +786,27 @@
          {
             mDest = new ManagedQueue(dest.getName(), fullSize, pageSize, downCacheSize);
          }
-
+         
          dm.registerDestination(mDest);
-
+         
          if (dest.isQueue())
          {
             QueuedExecutor executor = (QueuedExecutor)pool.get();
-
-            PagingFilteredQueue q =
+            
+            PagingFilteredQueue q = 
                new PagingFilteredQueue(dest.getName(), idm.getId(), ms, pm, true, false,
-                                       executor, null, fullSize, pageSize, downCacheSize);
-
-
-
+                                       executor, null, fullSize, pageSize, downCacheSize);                        
+            
             //Make a binding for this queue
-            queuePostOffice.bindQueue(dest.getName(), q);
-         }
+            postOffice.bindQueue(new JMSCondition(true, dest.getName()), q);
+         }         
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " addTemporaryDestination");
       }
    }
-
+   
    public void deleteTemporaryDestination(JBossDestination dest) throws JMSException
    {
       try
@@ -745,37 +815,37 @@
          {
             throw new IllegalStateException("Session is closed");
          }
-
+   
          if (!dest.isTemporary())
          {
             throw new InvalidDestinationException("Destination:" + dest + " is not a temporary destination");
          }
-
+         
          ManagedDestination mDest = dm.getDestination(dest.getName(), dest.isQueue());
-
+         
          if (mDest == null)
          {
             throw new InvalidDestinationException("No such destination: " + dest);
          }
-
+                  
          if (dest.isQueue())
          {
             //Unbind
-            queuePostOffice.unbindQueue(dest.getName());
+            postOffice.unbindQueue(dest.getName());
          }
          else
          {
-            //Topic
-            Collection bindings = topicPostOffice.listBindingsForCondition(dest.getName());
-
+            //Topic            
+            Collection bindings = postOffice.listBindingsForCondition(new JMSCondition(false, dest.getName()));
+            
             if (!bindings.isEmpty())
             {
                throw new IllegalStateException("Cannot delete temporary destination, since it has active consumer(s)");
             }
          }
-
-         dm.unregisterDestination(mDest);
-
+         
+         dm.unregisterDestination(mDest);         
+            
          connectionEndpoint.removeTemporaryDestination(dest);
       }
       catch (Throwable t)
@@ -783,11 +853,11 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " deleteTemporaryDestination");
       }
    }
-
+   
    public void unsubscribe(String subscriptionName) throws JMSException
    {
       log.debug(this + " unsubscribing " + subscriptionName);
-
+      
       try
       {
          if (closed)
@@ -798,51 +868,56 @@
          {
             throw new InvalidDestinationException("Destination is null");
          }
-
+   
          String clientID = connectionEndpoint.getClientID();
-
+   
          if (clientID == null)
          {
             throw new JMSException("null clientID on connection");
          }
-
+         
          String queueName = MessageQueueNameHelper.createSubscriptionName(clientID, subscriptionName);
-
-         Binding binding = topicPostOffice.getBindingForQueueName(queueName);
-
+         
+         Binding binding = postOffice.getBindingForQueueName(queueName);
+         
          if (binding == null)
          {
             throw new InvalidDestinationException("Cannot find durable subscription with name " +
                                                   subscriptionName + " to unsubscribe");
          }
-
+         
          // Section 6.11. JMS 1.1.
          // "It is erroneous for a client to delete a durable subscription while it has an active
          // TopicSubscriber for it or while a message received by it is part of a current
          // transaction or has not been acknowledged in the session."
-
+         
          Queue sub = binding.getQueue();
-
+         
          if (sub.numberOfReceivers() != 0)
          {
             throw new IllegalStateException("Cannot unsubscribe durable subscription " +
                                             subscriptionName + " since it has active subscribers");
          }
-
+         
          //Look up the topic
-         ManagedDestination mDest = dm.getDestination(binding.getCondition(), false);
-
+         
+         JMSCondition topicCond = (JMSCondition)binding.getCondition();
+         
+         String topicName = topicCond.getName();
+         
+         ManagedDestination mDest = dm.getDestination(topicName, false);
+         
          //Unbind it
-
-         if (mDest.isClustered() && !topicPostOffice.isLocal())
+    
+         if (mDest.isClustered() && !postOffice.isLocal())
          {
-            ClusteredPostOffice cpo = (ClusteredPostOffice)topicPostOffice;
-
+            ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
+            
             cpo.unbindClusteredQueue(queueName);
          }
          else
-         {
-            topicPostOffice.unbindQueue(queueName);
+         {         
+            postOffice.unbindQueue(queueName);
          }
       }
       catch (Throwable t)
@@ -850,9 +925,9 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " unsubscribe");
       }
    }
-
+    
    // Public --------------------------------------------------------
-
+   
    public ServerConnectionEndpoint getConnectionEndpoint()
    {
       return connectionEndpoint;
@@ -872,9 +947,9 @@
    {
       return consumers.keySet();
    }
-
+   
    // Protected -----------------------------------------------------
-
+   
    protected void acknowledgeInternal(AckInfo ackInfo) throws Throwable
    {
       //If the message was delivered via a connection consumer then the message needs to be acked
@@ -887,10 +962,10 @@
       {
          throw new IllegalArgumentException("Cannot find consumer id: " + ackInfo.getConsumerID());
       }
-
+      
       consumer.acknowledge(ackInfo.getMessageID());
    }
-
+   
    protected ServerConsumerEndpoint putConsumerEndpoint(int consumerID, ServerConsumerEndpoint d)
    {
       if (trace) { log.trace(this + " caching consumer " + consumerID); }
@@ -901,23 +976,23 @@
    {
       return (ServerConsumerEndpoint)consumers.get(new Integer(consumerID));
    }
-
+   
    protected ServerConsumerEndpoint removeConsumerEndpoint(int consumerID)
    {
       if (trace) { log.trace(this + " removing consumer " + consumerID + " from cache"); }
       return (ServerConsumerEndpoint)consumers.remove(new Integer(consumerID));
    }
-
+   
    protected ServerBrowserEndpoint putBrowserDelegate(int browserID, ServerBrowserEndpoint sbd)
    {
       return (ServerBrowserEndpoint)browsers.put(new Integer(browserID), sbd);
    }
-
+   
    protected ServerBrowserEndpoint getBrowserDelegate(int browserID)
    {
       return (ServerBrowserEndpoint)browsers.get(new Integer(browserID));
    }
-
+   
    protected ServerBrowserEndpoint removeBrowserDelegate(int browserID)
    {
       return (ServerBrowserEndpoint)browsers.remove(new Integer(browserID));
@@ -943,7 +1018,7 @@
             }
          }
       }
-   }
+   }   
 
    // Private -------------------------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -38,16 +38,23 @@
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
- * 
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+   *
  * @version <tt>$Revision$</tt>
  *
  * $Id$
  */
 public interface SessionEndpoint extends Closeable
-{ 
+{
+   ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
+                                     String selectorString,
+                                     boolean noLocal,  String subscriptionName,
+                                     boolean connectionConsumer,
+                                     long oldchannelID) throws JMSException;
+
    ConsumerDelegate createConsumerDelegate(JBossDestination destination, String selector,
                                            boolean noLocal, String subscriptionName,
-                                           boolean connectionConsumer) throws JMSException;   
+                                           boolean connectionConsumer) throws JMSException;
    
    BrowserDelegate createBrowserDelegate(JBossDestination queue, String messageSelector)
       throws JMSException;

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,9 +22,8 @@
 package org.jboss.jms.server.endpoint.advised;
 
 import javax.jms.JMSException;
-
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.messaging.core.plugin.IdBlock;
 
 /**
@@ -58,10 +57,12 @@
 
    // ConnectionFactoryEndpoint implementation -----------------------
 
-   public ConnectionDelegate createConnectionDelegate(String username, String password)
+   public CreateConnectionResult createConnectionDelegate(String username,
+                                                          String password,
+                                                          int failedNodeId)
       throws JMSException
    {
-      return endpoint.createConnectionDelegate(username, password);
+      return endpoint.createConnectionDelegate(username, password, failedNodeId);
    }
 
    public byte[] getClientAOPConfig() throws JMSException
@@ -96,8 +97,4 @@
 
    // Inner classes -------------------------------------------------
 
-
-
-
-
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -40,6 +40,7 @@
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -89,6 +90,17 @@
    {
       return endpoint.createConsumerDelegate(destination, selector, noLocal, subscriptionName, connectionConsumer);
    }
+   
+   public ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
+                                            String selectorString,
+                                            boolean noLocal,  String subscriptionName,
+                                            boolean connectionConsumer,
+                                            long oldChannelID) throws JMSException
+   {
+      return endpoint.failOverConsumer(jmsDestination, selectorString, noLocal,
+                                       subscriptionName, connectionConsumer,
+                                       oldChannelID);
+   }
 
    public BrowserDelegate createBrowserDelegate(JBossDestination queue, String messageSelector)
       throws JMSException

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSServerInvocationHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSServerInvocationHandler.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSServerInvocationHandler.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,13 +21,6 @@
   */
 package org.jboss.jms.server.remoting;
 
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-
-import javax.management.MBeanServer;
-
 import org.jboss.aop.joinpoint.InvocationResponse;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.util.PayloadKey;
@@ -39,6 +32,12 @@
 import org.jboss.remoting.callback.InvokerCallbackHandler;
 import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
 
+import javax.management.MBeanServer;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.Map;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -79,6 +78,11 @@
       log.debug("set MBeanServer to " + this.server);
    }
 
+   public ServerInvoker getInvoker()
+   {
+      return invoker;
+   }
+
    public void setInvoker(ServerInvoker invoker)
    {
       this.invoker = invoker;

Modified: trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -46,6 +46,16 @@
    public static final String VERSION_NUMBER = "VERSION_NUMBER";
    
    public static final String JMS_CLIENT_VM_ID = "JMS_CLIENT_VM_ID";
+
+   public static final String CF_DELEGATES = "CF_DELEGATES";
    
+   public static final String SERVER_ID = "SERVER_ID";
+   
+   public static final String REMOTING_CONNECTION = "REMOTING_CONNECTION";
+   
+   public static final String FAILOVER_MAP = "CF_FAIL_IND";
+   
+   public static final String CONNECTION_VERSION = "CONNECTION_VERSION";
+
    public static final String MAX_DELIVERIES = "MAX_DELS";
 }

Modified: trunk/src/main/org/jboss/jms/tx/AckInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -82,6 +82,12 @@
    {
       return consumerID;
    }
+
+   /** Used to change ack's id during failover */
+   public void setConsumerID(int consumerID)
+   {
+       this.consumerID=consumerID;
+   }
    
    public MessageProxy getMessage()
    {

Modified: trunk/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -119,6 +119,19 @@
       
       tx.getMessages().add(m);
    }
+
+    /**
+     * Navigate on ACK and change consumer ids on every ACK not sent yet.
+     */
+    public void handleFailover(Object xid, int oldConsumerID, int newConsumerID)
+    {
+        if (trace) { log.trace("handleFailover:: Transfering consumer id on ACKs from  " + oldConsumerID + " to " + newConsumerID); }
+
+        TxState tx = getTx(xid);
+        
+        tx.handleFailover(oldConsumerID, newConsumerID);
+    }
+
    
    /**
     * Add an acknowledgement to the transaction
@@ -171,6 +184,7 @@
          rollbackLocal(xid, connection);
          
          JMSException e = new MessagingTransactionRolledBackException(t.getMessage());
+         e.initCause(t);
          
          throw e;         
       }

Modified: trunk/src/main/org/jboss/jms/tx/TxState.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -95,6 +95,21 @@
    {
       this.state = state;
    }
+
+
+   /** Navigate on ACK and change consumer ids on every ACK not sent yet */
+   public void handleFailover(int oldConsumerID, int newConsumerID)
+   {
+       for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
+       {
+           AckInfo ackInfo = (AckInfo)ackIterator.next();
+           
+           if (ackInfo.getConsumerID() == oldConsumerID)
+           {
+               ackInfo.setConsumerID(newConsumerID);
+           }
+       }
+   }
     
    // Streamable implementation ---------------------------------
    

Modified: trunk/src/main/org/jboss/jms/util/JNDIUtil.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/JNDIUtil.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/util/JNDIUtil.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,12 +21,12 @@
   */
 package org.jboss.jms.util;
 
+import java.util.StringTokenizer;
+import javax.naming.Binding;
 import javax.naming.Context;
 import javax.naming.NameNotFoundException;
+import javax.naming.NamingEnumeration;
 import javax.naming.NamingException;
-import javax.naming.NamingEnumeration;
-import javax.naming.Binding;
-import java.util.StringTokenizer;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -101,7 +101,19 @@
          context = createContext(c, jndiName.substring(0, idx));
          name = jndiName.substring(idx + 1);
       }
-      context.bind(name, o);
+      boolean failed=false;
+      try
+      {
+         context.rebind(name,o);
+      }
+      catch (Exception ignored)
+      {
+         failed=true;
+      }
+      if (failed)
+      {
+         context.bind(name, o);
+      }
    }
 
    // Attributes ----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/util/MessagingJMSException.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/MessagingJMSException.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/jms/util/MessagingJMSException.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -72,6 +72,8 @@
          {
             setLinkedException(new Exception(cause));
          }
+
+         this.initCause(cause);
       }
    }
 

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -537,7 +537,7 @@
          ListIterator iter = null;
          
          MessageReference ref = null;
-         
+
          while (true)
          {           
             synchronized (deliveryLock)

Modified: trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -235,7 +235,7 @@
          
          //Load the unpaged references
          InitialLoadInfo ili = pm.getInitialReferenceInfos(channelID, fullSize);
-
+         
          if (ili.getMaxPageOrdering() != null)            
          {
             firstPagingOrder = ili.getMinPageOrdering().longValue();
@@ -249,22 +249,24 @@
             firstPagingOrder = nextPagingOrder = 0;
          }
          
-         Map refMap = processReferences(ili.getRefInfos()); 
-        
+         log.info("Channel " + this.channelID + " loading " + ili.getRefInfos().size() + " references");
+         
+         Map refMap = processReferences(ili.getRefInfos());
+         
          Iterator iter = ili.getRefInfos().iterator();
          while (iter.hasNext())
          {
             ReferenceInfo info = (ReferenceInfo)iter.next();
-
+            
             addFromRefInfo(info, refMap);
-         }                    
+         }
          
          //Maybe we need to load some paged refs
          
          while (checkLoad()) {}
       }
-   }      
-    
+   }
+   
       
    public void unload() throws Exception
    {

Modified: trunk/src/main/org/jboss/messaging/core/local/PagingFilteredQueue.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/local/PagingFilteredQueue.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/local/PagingFilteredQueue.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,20 +21,13 @@
   */
 package org.jboss.messaging.core.local;
 
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.Delivery;
-import org.jboss.messaging.core.DeliveryObserver;
-import org.jboss.messaging.core.Filter;
-import org.jboss.messaging.core.MessageReference;
-import org.jboss.messaging.core.PagingChannelSupport;
-import org.jboss.messaging.core.Queue;
-import org.jboss.messaging.core.SimpleDelivery;
+import org.jboss.messaging.core.*;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.tx.Transaction;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
  * 
  * A PagingFilteredQueue
@@ -137,7 +130,7 @@
    
    public String toString()
    {
-      return "Queue[" + getChannelID() + "]";
+      return "Queue[" + getChannelID() + "/" + this.getName() +  "]";
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/ClusteredPostOfficeService.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,79 +22,119 @@
 package org.jboss.messaging.core.plugin;
 
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
+import javax.management.NotificationFilter;
+import javax.management.ListenerNotFoundException;
+import javax.management.MBeanNotificationInfo;
 import javax.transaction.TransactionManager;
-
 import org.jboss.jms.selector.SelectorFactory;
+import org.jboss.jms.server.JMSConditionFactory;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.messaging.core.FilterFactory;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
+import org.jboss.messaging.core.plugin.postoffice.cluster.Peer;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.w3c.dom.Element;
 
+import java.util.Set;
+import java.util.Collections;
+
 /**
  * A ClusteredPostOfficeService
  * 
  * MBean wrapper for a clustered post office
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
  *
  */
-public class ClusteredPostOfficeService extends JDBCServiceSupport
+public class ClusteredPostOfficeService extends JDBCServiceSupport implements Peer
 {
-   private DefaultClusteredPostOffice postOffice;
-   
-   private ObjectName serverPeerObjectName;
-   
-   private String officeName;
-   
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private boolean started;
-   
+
    private Element syncChannelConfig;
-   
    private Element asyncChannelConfig;
-   
+
+   private ObjectName serverPeerObjectName;
+
+   private String officeName;
    private long stateTimeout = 5000;
-   
    private long castTimeout = 5000;
-     
    private String groupName;
-   
    private long statsSendPeriod = 1000;
-   
    private String clusterRouterFactory;
-   
    private String messagePullPolicy;
-   
-   // Constructors --------------------------------------------------------
-   
-   public ClusteredPostOfficeService()
-   {      
-   }
-   
-   // ServerPlugin implementation ------------------------------------------
-   
+
+   private DefaultClusteredPostOffice postOffice;
+
+   // Constructors --------------------------------------------------
+
+   // ServerPlugin implementation -----------------------------------
+
    public MessagingComponent getInstance()
    {
       return postOffice;
    }
-   
-   // MBean attributes -----------------------------------------------------
-   
+
+   // Peer implementation -------------------------------------------
+
+   public Set getNodeIDView()
+   {
+      if (postOffice == null)
+      {
+         return Collections.EMPTY_SET;
+      }
+
+      return postOffice.getNodeIDView();
+   }
+
+   // NotificationBroadcaster implementation ------------------------
+
+   public void addNotificationListener(NotificationListener listener,
+                                       NotificationFilter filter,
+                                       Object object) throws IllegalArgumentException
+   {
+      postOffice.addNotificationListener(listener, filter, object);
+   }
+
+   public void removeNotificationListener(NotificationListener listener)
+      throws ListenerNotFoundException
+   {
+      postOffice.removeNotificationListener(listener);
+   }
+
+   public MBeanNotificationInfo[] getNotificationInfo()
+   {
+      return postOffice.getNotificationInfo();
+   }
+
+
+   // MBean attributes ----------------------------------------------
+
    public synchronized ObjectName getServerPeer()
    {
       return serverPeerObjectName;
    }
-   
+
    public synchronized void setServerPeer(ObjectName on)
    {
       if (started)
@@ -104,12 +144,12 @@
       }
       this.serverPeerObjectName = on;
    }
-   
+
    public synchronized String getPostOfficeName()
    {
       return officeName;
    }
-   
+
    public synchronized void setPostOfficeName(String name)
    {
       if (started)
@@ -119,7 +159,7 @@
       }
       this.officeName = name;
    }
-   
+
    public void setSyncChannelConfig(Element config) throws Exception
    {
       syncChannelConfig = config;
@@ -129,7 +169,7 @@
    {
       return syncChannelConfig;
    }
-   
+
    public void setAsyncChannelConfig(Element config) throws Exception
    {
       asyncChannelConfig = config;
@@ -139,147 +179,161 @@
    {
       return asyncChannelConfig;
    }
-   
+
    public void setStateTimeout(long timeout)
    {
       this.stateTimeout = timeout;
    }
-   
+
    public long getStateTimeout()
    {
       return stateTimeout;
    }
-   
+
    public void setCastTimeout(long timeout)
    {
       this.castTimeout = timeout;
    }
-   
+
    public long getCastTimeout()
    {
       return castTimeout;
    }
-   
+
    public void setGroupName(String groupName)
    {
       this.groupName = groupName;
    }
-   
+
    public String getGroupName()
    {
       return groupName;
    }
-   
+
    public void setStatsSendPeriod(long period)
    {
       this.statsSendPeriod = period;
    }
-   
+
    public long getStatsSendPeriod()
    {
       return statsSendPeriod;
    }
-   
+
    public String getClusterRouterFactory()
    {
       return clusterRouterFactory;
    }
-   
+
    public String getMessagePullPolicy()
    {
       return messagePullPolicy;
    }
-   
+
    public void setClusterRouterFactory(String clusterRouterFactory)
    {
       this.clusterRouterFactory = clusterRouterFactory;
    }
-   
+
    public void setMessagePullPolicy(String messagePullPolicy)
    {
       this.messagePullPolicy = messagePullPolicy;
    }
-   
+
+   public String listBindings()
+   {
+      return postOffice.printBindingInformation();
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
    // ServiceMBeanSupport overrides ---------------------------------
-   
+
    protected synchronized void startService() throws Exception
    {
       if (started)
       {
          throw new IllegalStateException("Service is already started");
       }
-      
+
       super.startService();
-      
+
       try
-      {  
+      {
          TransactionManager tm = getTransactionManagerReference();
-                           
+
          ServerPeer serverPeer = (ServerPeer)server.getAttribute(serverPeerObjectName, "Instance");
-         
          MessageStore ms = serverPeer.getMessageStore();
-         
          TransactionRepository tr = serverPeer.getTxRepository();
-         
          PersistenceManager pm = serverPeer.getPersistenceManagerInstance();
-         
          QueuedExecutorPool pool = serverPeer.getQueuedExecutorPool();
-                  
          int nodeId = serverPeer.getServerPeerID();
-         
+
          Class clazz = Class.forName(messagePullPolicy);
-         
          MessagePullPolicy pullPolicy = (MessagePullPolicy)clazz.newInstance();
-         
          clazz = Class.forName(clusterRouterFactory);
-         
+
          ClusterRouterFactory rf = (ClusterRouterFactory)clazz.newInstance();
-         
+
+         ConditionFactory cf = new JMSConditionFactory();
+                  
          FilterFactory ff = new SelectorFactory();
-            
-         postOffice =  new DefaultClusteredPostOffice(ds, tm, sqlProperties, createTablesOnStartup,
-                                               nodeId, officeName, ms,
-                                               pm, tr, ff, pool, 
-                                               groupName,
-                                               syncChannelConfig, asyncChannelConfig,
-                                               stateTimeout, castTimeout,
-                                               pullPolicy, rf,
-                                               statsSendPeriod);
-         
+         FailoverMapper mapper = new DefaultFailoverMapper();
+
+         postOffice =  new DefaultClusteredPostOffice(ds, tm, sqlProperties,
+                                                      createTablesOnStartup,
+                                                      nodeId, officeName, ms,
+                                                      pm, tr, ff, cf, pool,
+                                                      groupName,
+                                                      syncChannelConfig,
+                                                      asyncChannelConfig,
+                                                      stateTimeout, castTimeout,
+                                                      pullPolicy, rf,
+                                                      mapper,
+                                                      statsSendPeriod);
+
          postOffice.start();
-         
-         started = true;         
+
+         started = true;
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " startService");
-      } 
+      }
    }
-   
+
    protected void stopService() throws Exception
    {
       if (!started)
       {
          throw new IllegalStateException("Service is not started");
       }
-      
-      super.stopService();      
-      
+
+      super.stopService();
+
       try
-      {      
+      {
          postOffice.stop();
-         
+
          postOffice = null;
-               
+
          started = false;
-         
+
          log.debug(this + " stopped");
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMXInvocation(t, this + " startService");
-      } 
+      }
    }
-      
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }
 

Modified: trunk/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/DefaultPostOfficeService.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,10 +25,12 @@
 import javax.transaction.TransactionManager;
 
 import org.jboss.jms.selector.SelectorFactory;
+import org.jboss.jms.server.JMSConditionFactory;
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.messaging.core.FilterFactory;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -100,6 +102,12 @@
       }
       this.officeName = name;
    }
+
+    public String listBindings()
+    {
+        return postOffice.printBindingInformation();
+    }
+
    
    // ServiceMBeanSupport overrides ---------------------------------
    
@@ -129,10 +137,12 @@
          int nodeId = serverPeer.getServerPeerID();
          
          FilterFactory ff = new SelectorFactory();
+         
+         ConditionFactory cf = new JMSConditionFactory();
                
          postOffice = new DefaultPostOffice(ds, tm, sqlProperties,
                                          createTablesOnStartup,
-                                         nodeId, officeName, ms, pm, tr, ff, pool);
+                                         nodeId, officeName, ms, pm, tr, ff, cf, pool);
          
          postOffice.start();
          

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,19 +25,23 @@
 
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
+import org.jboss.messaging.core.plugin.postoffice.cluster.Peer;
 
 /**
  * 
  * A ClusteredPostOffice
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
  *
  */
-public interface ClusteredPostOffice extends PostOffice
+public interface ClusteredPostOffice extends PostOffice, Peer
 {
+   public static final String VIEW_CHANGED_NOTIFICATION = "VIEW_CHANGED";
+
    /**
     * Bind a queue to the post office under a specific condition
     * such that it is available across the cluster
@@ -46,15 +50,17 @@
     * @return
     * @throws Exception
     */
-   Binding bindClusteredQueue(String condition, LocalClusteredQueue queue) throws Exception;
-   
+   Binding bindClusteredQueue(Condition condition, LocalClusteredQueue queue) throws Exception;
+
    /**
     * Unbind a clustered queue from the post office
     * @param queueName The unique name of the queue
     * @return
     * @throws Throwable
     */
-   Binding unbindClusteredQueue(String queueName) throws Throwable;         
-   
-   Collection listAllBindingsForCondition(String condition) throws Exception;
+   Binding unbindClusteredQueue(String queueName) throws Throwable;
+
+   Collection listAllBindingsForCondition(Condition condition) throws Exception;
+
+   Binding getBindingforChannelId(long channelId) throws Exception;
 }

Copied: trunk/src/main/org/jboss/messaging/core/plugin/contract/Condition.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Condition.java)

Copied: trunk/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ConditionFactory.java)

Copied: trunk/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -41,25 +41,28 @@
  * there is a single binding per queue.
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
  *
  */
 public interface PostOffice extends MessagingComponent
-{   
-   Binding bindQueue(String condition, Queue queue) throws Exception;
+{
+   String getOfficeName();
    
+   Binding bindQueue(Condition condition, Queue queue) throws Exception;
 
    Binding unbindQueue(String queueName) throws Throwable;
-   
+
    /**
     * List the bindings that match the specified condition
     * @param condition
     * @return
     * @throws Exception
     */
-   Collection listBindingsForCondition(String condition) throws Exception;
+   Collection listBindingsForCondition(Condition condition) throws Exception;
    
    /**
     * Get the binding for the specified queue name
@@ -68,7 +71,7 @@
     * @throws Exception
     */
    Binding getBindingForQueueName(String queueName) throws Exception;
-   
+
    /**
     * Route a reference.
     * @param ref
@@ -79,7 +82,11 @@
     * @return true if ref was accepted by at least one queue
     * @throws Exception
     */
-   boolean route(MessageReference ref, String condition, Transaction tx) throws Exception;   
+   boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception; 
    
+   /**
+    * 
+    * @return true if it is a non clustered post office
+    */
    boolean isLocal();
 }

Copied: trunk/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/ReplicationListener.java)

Copied: trunk/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/contract/Replicator.java)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,6 +22,7 @@
 package org.jboss.messaging.core.plugin.postoffice;
 
 import org.jboss.messaging.core.Queue;
+import org.jboss.messaging.core.plugin.contract.Condition;
 
 /**
  * A Binding
@@ -36,7 +37,12 @@
 {
    public int getNodeId();
    
-   public String getCondition();
+   public Condition getCondition();
    
    public Queue getQueue();
+
+   public boolean isFailed();
+
+   public void setFailed(boolean failed);
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,6 +22,7 @@
 package org.jboss.messaging.core.plugin.postoffice;
 
 import org.jboss.messaging.core.Queue;
+import org.jboss.messaging.core.plugin.contract.Condition;
 
 /**
  * 
@@ -37,36 +38,55 @@
 {
    private int nodeId;
    
-   private String condition;
+   private Condition condition;
    
    private Queue queue;
-       
+
+   private boolean failed;
+
    public DefaultBinding()
-   {      
+   {
    }
 
-   public DefaultBinding(int nodeId, String condition, Queue queue)
+   public DefaultBinding(int nodeId, Condition condition, Queue queue, boolean failed)
    {
       this.nodeId = nodeId;
-      
-      this.condition = condition;     
-      
+
+      this.condition = condition;
+
       this.queue = queue;
+
+      this.failed = failed;
    }
-   
+
    public int getNodeId()
    {
       return nodeId;
    }
-      
-   public String getCondition()
+
+   public Condition getCondition()
    {
       return condition;
    }
-   
+
    public Queue getQueue()
    {
       return queue;
    }
+
+   public boolean isFailed()
+   {
+      return failed;
+   }
+
+   public void setFailed(boolean failed)
+   {
+      this.failed = failed;
+   }
+
+   public String toString()
+   {
+       return "Node" + nodeId + " condition=" + condition + " queue=" + queue + " queueClass=" + queue.getClass().getName();
+   }
    
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,6 +21,8 @@
  */
 package org.jboss.messaging.core.plugin.postoffice;
 
+import java.io.PrintWriter;
+import java.io.StringWriter;
 import java.sql.Connection;
 import java.sql.PreparedStatement;
 import java.sql.ResultSet;
@@ -46,6 +48,8 @@
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.JDBCSupport;
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
@@ -61,6 +65,8 @@
  * A DefaultPostOffice
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -74,6 +80,7 @@
           
    private String officeName;
    
+   //This lock protects the condition and name maps
    protected ReadWriteLock lock;
    
    protected MessageStore ms;     
@@ -82,7 +89,7 @@
    
    protected TransactionRepository tr;
    
-   protected int nodeId;
+   protected int currentNodeId;
    
    //Map <node id, Map < queue name, binding > >
    protected Map nameMaps;
@@ -92,6 +99,8 @@
    
    protected FilterFactory filterFactory;
    
+   protected ConditionFactory conditionFactory;
+   
    protected QueuedExecutorPool pool;
    
    public DefaultPostOffice()
@@ -103,6 +112,7 @@
                          int nodeId, String officeName, MessageStore ms,
                          PersistenceManager pm,
                          TransactionRepository tr, FilterFactory filterFactory,
+                         ConditionFactory conditionFactory,
                          QueuedExecutorPool pool)
    {            
       super (ds, tm, sqlProperties, createTablesOnStartup);
@@ -113,7 +123,7 @@
        
       conditionMap = new LinkedHashMap(); 
       
-      this.nodeId = nodeId;
+      this.currentNodeId = nodeId;
       
       this.officeName = officeName;
       
@@ -125,6 +135,8 @@
       
       this.filterFactory = filterFactory;
       
+      this.conditionFactory = conditionFactory;
+      
       this.pool = pool;
    }
    
@@ -138,21 +150,31 @@
       
       loadBindings();
       
-      if (trace) { log.trace(this + " started"); }
+      log.debug(this + " started");
    }
-   
+
    public void stop() throws Exception
    {
+      stop(true);
+   }
+
+   public void stop(boolean sendNotification) throws Exception
+   {
       if (trace) { log.trace(this + " stopping"); }
       
       super.stop();
       
-      if (trace) { log.trace(this + " stopped"); }
+      log.debug(this + " stopped");
    }
      
-   // PostOffice implementation ---------------------------------------        
+   // PostOffice implementation ---------------------------------------
+
+   public String getOfficeName()
+   {
+      return officeName;
+   }
          
-   public Binding bindQueue(String condition, Queue queue) throws Exception
+   public Binding bindQueue(Condition condition, Queue queue) throws Exception
    {
       if (trace) { log.trace(this + " binding queue " + queue.getName() + " with condition " + condition); }
       
@@ -171,7 +193,7 @@
       try
       {         
          //We currently only allow one binding per name per node
-         Map nameMap = (Map)nameMaps.get(new Integer(this.nodeId));
+         Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
          
          Binding binding = null;
          
@@ -185,7 +207,7 @@
             throw new IllegalArgumentException("Binding already exists for name " + queue.getName());
          }
                  
-         binding = new DefaultBinding(this.nodeId, condition, queue); 
+         binding = new DefaultBinding(currentNodeId, condition, queue, false);
          
          addBinding(binding);
                
@@ -203,7 +225,7 @@
       }
    }   
             
-   public Binding unbindQueue(String queueName) throws Throwable
+   public Binding unbindQueue( String queueName) throws Throwable
    {
       if (trace) { log.trace(this + " unbinding queue " + queueName); }
              
@@ -216,13 +238,13 @@
 
       try
       {         
-         Binding binding = removeBinding(this.nodeId, queueName);
+         Binding binding = removeBinding(currentNodeId,queueName);
       
          if (binding.getQueue().isRecoverable())
          {
             //Need to remove from db too
             
-            deleteBinding(binding.getQueue().getName());    
+            deleteBinding(currentNodeId, binding.getQueue().getName());
          }
          
          binding.getQueue().removeAllReferences();         
@@ -235,16 +257,13 @@
       }
    }   
    
-   public Collection listBindingsForCondition(String condition) throws Exception
+   public Collection listBindingsForCondition(Condition condition) throws Exception
    {
       return listBindingsForConditionInternal(condition, true);
    }  
    
-   
-         
-   
    public Binding getBindingForQueueName(String queueName) throws Exception
-   {    
+   {
       if (queueName == null)
       {
          throw new IllegalArgumentException("Queue name is null");
@@ -254,29 +273,34 @@
 
       try
       {
-         Map nameMap = (Map)nameMaps.get(new Integer(this.nodeId));
-         
-         Binding binding = null;
-         
-         if (nameMap != null)
-         {
-            binding = (Binding)nameMap.get(queueName);
-         }
-         
-         return binding;
+         return internalGetBindingForQueueName(queueName);
       }
       finally
       {
          lock.readLock().release();
       }
    }
-   
-   public void recover() throws Exception
+
+   /**
+    * Internal methods (e.g. failOver) will already hold a lock and will need to call
+    * getBindingForQueueNames without a lock. (Also... I dind't move this method to the protected
+    * section of the code as this is related to getBindingForQueueNames).
+    */
+   protected Binding internalGetBindingForQueueName(String queueName)
    {
-      //NOOP
+      Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
+
+      Binding binding = null;
+
+      if (nameMap != null)
+      {
+         binding = (Binding)nameMap.get(queueName);
+      }
+
+      return binding;
    }
-   
-   public boolean route(MessageReference ref, String condition, Transaction tx) throws Exception
+
+   public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
    {
       if (trace) { log.trace(this + "  routing ref " + ref + " with condition " + condition + " and transaction " + tx); }
             
@@ -328,7 +352,7 @@
                Binding binding = (Binding)iter.next();
                
                //Sanity check
-               if (binding.getNodeId() != this.nodeId)
+               if (binding.getNodeId() != this.currentNodeId)
                {
                   throw new IllegalStateException("Local post office has foreign bindings!");
                }
@@ -365,7 +389,7 @@
      
    // Protected -----------------------------------------------------
    
-   protected Collection listBindingsForConditionInternal(String condition, boolean localOnly) throws Exception
+   protected Collection listBindingsForConditionInternal(Condition condition, boolean localOnly) throws Exception
    {
       if (condition == null)
       {
@@ -396,7 +420,7 @@
             {
                Binding binding = (Binding)iter.next();
                
-               if (!localOnly || (binding.getNodeId() == this.nodeId))
+               if (!localOnly || (binding.getNodeId() == this.currentNodeId))
                {
                   list.add(binding);
                }
@@ -436,7 +460,7 @@
             
             String queueName = rs.getString(2);
             
-            String condition = rs.getString(3);
+            String conditionText = rs.getString(3);
             
             String selector = rs.getString(4);
             
@@ -446,8 +470,15 @@
             }
             
             long channelId = rs.getLong(5);
+
+            boolean failed = rs.getString(6).equals("Y");
+
+            log.info("PostOffice " + this.officeName + " nodeId=" + nodeId + " condition=" + conditionText + " queueName=" + queueName + " channelId=" + channelId + " selector=" + selector);
                                              
-            Binding binding = this.createBinding(nodeId, condition, queueName, channelId, selector, true);
+            Condition condition = conditionFactory.createCondition(conditionText);
+            
+            Binding binding = this.createBinding(nodeId, condition, queueName, channelId, selector, true, failed);
+            
             binding.getQueue().deactivate();
             
             addBinding(binding);
@@ -473,29 +504,35 @@
       }
    }
    
-   protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, String filterString, boolean durable) throws Exception
+   protected Binding createBinding(int nodeId, Condition condition, String queueName, long channelId, String filterString, boolean durable, boolean failed) throws Exception
    {      
       
       Filter filter = filterFactory.createFilter(filterString);
       
+      return createBinding(nodeId, condition, queueName, channelId, filter, durable, failed);
+   }
+   
+   protected Binding createBinding(int nodeId, Condition condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
+   {
       Queue queue;
-      if (nodeId == this.nodeId)
+      if (nodeId == this.currentNodeId)
       {
          QueuedExecutor executor = (QueuedExecutor)pool.get();
          
          queue = new PagingFilteredQueue(queueName, channelId, ms, pm, true,
-                                         true, executor, filter);
+                  true, executor, filter);
       }
       else
       {
          throw new IllegalStateException("This is a non clustered post office - should not have bindings from different nodes!");
       }
       
-      Binding binding = new DefaultBinding(nodeId, condition, queue);
+      Binding binding = new DefaultBinding(nodeId, condition, queue, failed);
       
       return binding;
+      
    }
-          
+   
    protected void insertBinding(Binding binding) throws Exception
    {
       Connection conn = null;
@@ -511,9 +548,9 @@
          String filterString = binding.getQueue().getFilter() == null ? null : binding.getQueue().getFilter().getFilterString();
                   
          ps.setString(1, this.officeName);
-         ps.setInt(2, this.nodeId);
+         ps.setInt(2, this.currentNodeId);
          ps.setString(3, binding.getQueue().getName());
-         ps.setString(4, binding.getCondition());         
+         ps.setString(4, binding.getCondition().toText());         
          if (filterString != null)
          {
             ps.setString(5, filterString);
@@ -523,6 +560,7 @@
             ps.setNull(5, Types.VARCHAR);
          }
          ps.setLong(6, binding.getQueue().getChannelID());
+         ps.setString(7,binding.isFailed() ? "Y":"N");
 
          ps.executeUpdate();
       }
@@ -540,8 +578,9 @@
       }     
    }
    
-   protected boolean deleteBinding(String queueName) throws Exception
+   protected boolean deleteBinding(int parameterNodeId, String queueName) throws Exception
    {
+      if (parameterNodeId<0) parameterNodeId=this.currentNodeId;
       Connection conn = null;
       PreparedStatement ps  = null;
       TransactionWrapper wrap = new TransactionWrapper();
@@ -553,7 +592,7 @@
          ps = conn.prepareStatement(getSQLStatement("DELETE_BINDING"));
          
          ps.setString(1, this.officeName);
-         ps.setInt(2, this.nodeId);
+         ps.setInt(2, parameterNodeId);
          ps.setString(3, queueName);
 
          int rows = ps.executeUpdate();
@@ -574,6 +613,86 @@
       }     
    }
 
+   public String printBindingInformation()
+   {
+       StringWriter buffer = new StringWriter();
+       PrintWriter out = new PrintWriter(buffer);
+
+       out.println("Ocurrencies of nameMaps:");
+       out.println("<table border=1>");
+       for (Iterator mapIterator = nameMaps.entrySet().iterator();mapIterator.hasNext();)
+       {
+           Map.Entry entry = (Map.Entry)mapIterator.next();
+           out.println("<tr><td colspan=3><b>Map on node " + entry.getKey() + "</b></td></tr>");
+           Map valuesOnNode = (Map)entry.getValue();
+
+           out.println("<tr><td>Key</td><td>Value</td><td>Class of Value</td></tr>");
+           for (Iterator valuesIterator=valuesOnNode.entrySet().iterator();valuesIterator.hasNext();)
+           {
+               Map.Entry entry2 = (Map.Entry)valuesIterator.next();
+
+               out.println("<tr>");
+               out.println("<td>" + entry2.getKey() + "</td><td>" + entry2.getValue()+ "</td><td>" + entry2.getValue().getClass().getName() + "</td>");
+               out.println("</tr>");
+
+               if (entry2.getValue() instanceof Binding && ((Binding)entry2.getValue()).getQueue() instanceof PagingFilteredQueue)
+               {
+                   PagingFilteredQueue queue = (PagingFilteredQueue)((Binding)entry2.getValue()).getQueue();
+                   List undelivered = queue.undelivered(null);
+                   if (!undelivered.isEmpty())
+                   {
+                       out.println("<tr><td>List of undelivered messages on Paging</td>");
+
+                       out.println("<td colspan=2><table border=1>");
+                       out.println("<tr><td>Reference#</td><td>Message</td></tr>");
+                       for (Iterator iterUndelivered = undelivered.iterator();iterUndelivered.hasNext();)
+                       {
+                           MessageReference reference = (MessageReference)iterUndelivered.next();
+                           out.println("<tr><td>" + reference.getInMemoryChannelCount() + "</td><td>" + reference.getMessage() +"</td></tr>");
+                       }
+                       out.println("</table></td>");
+                       out.println("</tr>");
+                   }
+               }
+               //out.println("   bindingName=" +entry2.getKey() + " value = " + entry2.getValue() + " valueClass=" + entry2.getValue().getClass().getName());
+           }
+       }
+       out.println("</table>");
+
+
+
+       out.println("<br>Ocurrencies of conditionMap:");
+
+       out.println("<table border=1>");
+       out.println("<tr><td>EntryName</td><td>Value</td>");
+       for (Iterator iterConditions = conditionMap.entrySet().iterator();iterConditions.hasNext();)
+       {
+           Map.Entry entry = (Map.Entry)iterConditions.next();
+           out.println("<tr><td>" + entry.getKey() + "</td><td>" + entry.getValue() + "</td></tr>");
+
+           if (entry.getValue() instanceof Bindings)
+           {
+               out.println("<tr><td>Binding Information:</td><td>");
+               out.println("<table border=1>");
+               out.println("<tr><td>Binding</td><td>Queue</td></tr>");
+               Bindings bindings = (Bindings)entry.getValue();
+               for (Iterator iterBindings = bindings.getAllBindings().iterator();iterBindings.hasNext();)
+               {
+
+                   Binding binding = (Binding)iterBindings.next();
+                   out.println("<tr><td>" + binding + "</td><td>" + binding.getQueue() + "</td></tr>");
+               }
+               out.println("</table></td></tr>");
+           }
+       }
+       out.println("</table>");
+
+
+       return buffer.toString();
+
+
+   }
+
    protected void addBinding(Binding binding)
    {
       addToNameMap(binding);
@@ -593,20 +712,20 @@
    protected void addToNameMap(Binding binding)
    {
       Map nameMap = (Map)nameMaps.get(new Integer(binding.getNodeId()));
-      
+
       if (nameMap == null)
       {
          nameMap = new LinkedHashMap();
-         
+
          nameMaps.put(new Integer(binding.getNodeId()), nameMap);
       }
-      
-      nameMap.put(binding.getQueue().getName(), binding);      
+
+      nameMap.put(binding.getQueue().getName(), binding);
    }
    
    protected void addToConditionMap(Binding binding)
    {
-      String condition = binding.getCondition();
+      Condition condition = binding.getCondition();
       
       Bindings bindings = (Bindings)conditionMap.get(condition);
       
@@ -680,12 +799,12 @@
    {                
       Map map = new LinkedHashMap();
       map.put("INSERT_BINDING",
-              "INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, CONDITION, SELECTOR, CHANNEL_ID) " +
-              "VALUES (?, ?, ?, ?, ?, ?)");
+              "INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, CONDITION, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) " +
+              "VALUES (?, ?, ?, ?, ?, ?, ?)");
       map.put("DELETE_BINDING",
               "DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?");
       map.put("LOAD_BINDINGS",
-              "SELECT NODE_ID, QUEUE_NAME, CONDITION, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE " +
+              "SELECT NODE_ID, QUEUE_NAME, CONDITION, SELECTOR, CHANNEL_ID, IS_FAILED_OVER FROM JMS_POSTOFFICE " +
               "WHERE POSTOFFICE_NAME  = ?");
       return map;
    }
@@ -696,7 +815,7 @@
       map.put("CREATE_POSTOFFICE_TABLE",
               "CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER," +
               "QUEUE_NAME VARCHAR(1023), CONDITION VARCHAR(1023), " +
-              "SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT)");
+              "SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))");
       return map;
    }
    

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindRequest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -43,17 +43,18 @@
    {      
    }
    
-   BindRequest(int nodeId, String queueName, String condition, String filterString,
-               long channelId, boolean durable)
+   BindRequest(int nodeId, String queueName, String conditionText, String filterString,
+               long channelId, boolean durable, boolean failed)
    {
-      bindingInfo = new BindingInfo(nodeId, queueName, condition, filterString,
-                                    channelId, durable);
+      bindingInfo = new BindingInfo(nodeId, queueName, conditionText, filterString,
+                                    channelId, durable, failed);
    }
 
    Object execute(PostOfficeInternal office) throws Exception
    {
-      office.addBindingFromCluster(bindingInfo.getNodeId(), bindingInfo.getQueueName(), bindingInfo.getCondition(),
-                                   bindingInfo.getFilterString(), bindingInfo.getChannelId(), bindingInfo.isDurable());
+      office.addBindingFromCluster(bindingInfo.getNodeId(), bindingInfo.getQueueName(), bindingInfo.getConditionText(),
+                                   bindingInfo.getFilterString(), bindingInfo.getChannelId(), bindingInfo.isDurable(),
+                                   bindingInfo.isFailed());
       return null;
    }
    

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/BindingInfo.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -42,38 +42,42 @@
    
    private String queueName;   
    
-   private String condition;   
+   private String conditionText;   
    
    private String filterString; 
    
    private long channelId;   
    
    private boolean durable;
+
+   private boolean failed;
    
    BindingInfo()
    {      
    }
    
-   BindingInfo(int nodeId, String queueName, String condition, String filterString,
-               long channelId, boolean durable)
+   BindingInfo(int nodeId, String queueName, String conditionText, String filterString,
+               long channelId, boolean durable, boolean failed)
    {
       this.nodeId = nodeId;
       
       this.queueName = queueName;
       
-      this.condition = condition;
+      this.conditionText = conditionText;
       
       this.filterString = filterString;
       
       this.channelId = channelId;
       
       this.durable = durable;
+
+      this.failed = failed;
    }
 
    public void execute(PostOfficeInternal office) throws Exception
    {
-      office.addBindingFromCluster(nodeId, queueName, condition,
-                                   filterString, channelId, durable);
+      office.addBindingFromCluster(nodeId, queueName, conditionText,
+                                   filterString, channelId, durable, failed);
       
    }
    
@@ -83,7 +87,7 @@
       
       queueName = in.readUTF();
       
-      condition = in.readUTF();
+      conditionText = in.readUTF();
       
       filterString = (String)StreamUtils.readObject(in, false);   
       
@@ -98,7 +102,7 @@
       
       out.writeUTF(queueName);
       
-      out.writeUTF(condition);
+      out.writeUTF(conditionText);
       
       StreamUtils.writeObject(out, filterString, false, false);
       
@@ -112,9 +116,9 @@
       return channelId;
    }
 
-   String getCondition()
+   String getConditionText()
    {
-      return condition;
+      return conditionText;
    }
 
    boolean isDurable()
@@ -136,4 +140,14 @@
    {
       return queueName;
    }
+
+   public boolean isFailed()
+   {
+      return failed;
+   }
+
+   public void setFailed(boolean failed)
+   {
+      this.failed = failed;
+   }
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/CastMessagesCallback.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -27,6 +27,7 @@
 
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Message;
+import org.jboss.messaging.core.plugin.contract.Condition;
 import org.jboss.messaging.core.tx.TransactionException;
 import org.jboss.messaging.core.tx.TxCallback;
 
@@ -120,7 +121,7 @@
     */
    private long checkChannelID;
    
-   void addMessage(String routingKey, Message message, Map queueNameToNodeIdMap,
+   void addMessage(Condition routingKey, Message message, Map queueNameToNodeIdMap,
                    int lastNodeId, long channelID)
    {
       //If we only ever send messages to the same node for this tx, then we can unicast rather than multicast
@@ -141,7 +142,7 @@
          }
       }
       
-      MessageHolder holder = new MessageHolder(routingKey, message, queueNameToNodeIdMap);
+      MessageHolder holder = new MessageHolder(routingKey.toText(), message, queueNameToNodeIdMap);
       
       if (message.isReliable())
       {

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRequest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRequest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,7 +23,6 @@
 
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
-
 import org.jboss.messaging.util.Streamable;
 
 /**
@@ -79,11 +78,6 @@
             request = new QueueStatsRequest();
             break;
          }
-         case SendNodeIdRequest.TYPE:
-         {
-            request = new SendNodeIdRequest();
-            break;
-         }
          case SendTransactionRequest.TYPE:
          {
             request = new SendTransactionRequest();
@@ -99,6 +93,21 @@
             request = new RollbackPullRequest();
             break;
          }
+         case LeaveClusterRequest.TYPE:
+         {
+            request = new LeaveClusterRequest();
+            break;
+         }
+         case PutReplicantRequest.TYPE:
+         {
+            request = new PutReplicantRequest();
+            break;
+         }
+         case RemoveReplicantRequest.TYPE:
+         {
+            request = new RemoveReplicantRequest();
+            break;
+         }
          default:
          {
             throw new IllegalArgumentException("Invalid type: " + type);

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRouter.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRouter.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/ClusterRouter.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,10 +21,11 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import org.jboss.messaging.core.Receiver;
+import org.jboss.messaging.core.Router;
+
 import java.util.List;
 
-import org.jboss.messaging.core.Router;
-
 /**
  * A ClusterRouter
  *
@@ -37,6 +38,11 @@
 public interface ClusterRouter extends Router
 {
    List getQueues();
-   
+
+   List getFailedQueues();
+
    ClusteredQueue getLocalQueue();
+
+   boolean add(Receiver receiver, boolean failedOver);
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,16 +25,31 @@
 import java.io.ByteArrayOutputStream;
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
+import java.io.PrintWriter;
+import java.io.Serializable;
+import java.io.StringWriter;
 import java.util.ArrayList;
 import java.util.Collection;
+import java.util.Collections;
 import java.util.HashMap;
+import java.util.HashSet;
 import java.util.Iterator;
+import java.util.LinkedHashMap;
+import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
+import java.util.Set;
 
+import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
+import javax.management.NotificationBroadcasterSupport;
+import javax.management.NotificationListener;
+import javax.management.MBeanNotificationInfo;
+import javax.management.NotificationFilter;
+import javax.management.ListenerNotFoundException;
+import javax.management.Notification;
 
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.logging.Logger;
@@ -44,8 +59,13 @@
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
+import org.jboss.messaging.core.plugin.contract.ReplicationListener;
+import org.jboss.messaging.core.plugin.contract.Replicator;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.DefaultBinding;
 import org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice;
@@ -68,589 +88,624 @@
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
 /**
- * 
+ *
  * A DefaultClusteredPostOffice
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
  *
  */
-public class DefaultClusteredPostOffice extends DefaultPostOffice implements ClusteredPostOffice, PostOfficeInternal
+public class DefaultClusteredPostOffice extends DefaultPostOffice
+   implements ClusteredPostOffice, PostOfficeInternal, Replicator
 {
+   // Constants -----------------------------------------------------
+
    private static final Logger log = Logger.getLogger(DefaultClusteredPostOffice.class);
-   
-   //Used for failure testing
+
+   // Key for looking up node id -> address info mapping from replicated data
+   public static final String ADDRESS_INFO_KEY = "address_info";
+
+   // Key for looking up node id -> failed over for node id mapping from replicated data
+   public static final String FAILED_OVER_FOR_KEY = "failed_over_for";
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Used for failure testing
+
    private boolean failBeforeCommit;
    private boolean failAfterCommit;
    private boolean failHandleResult;
-     
+
+   // End of failure testing attributes
+
    private boolean trace = log.isTraceEnabled();
-                        
+
+   private String groupName;
+
+   private boolean started;
+
+   private Element syncChannelConfigElement;
+   private String syncChannelConfig;
    private Channel syncChannel;
-   
+
+   private Element asyncChannelConfigElement;
+   private String asyncChannelConfig;
    private Channel asyncChannel;
-   
-   private String groupName;
-   
+
    private MessageDispatcher controlMessageDispatcher;
-   
-   private MessageListener controlMessageListener;
-   
-   private Receiver dataReceiver;
-   
-   private MembershipListener controlMembershipListener;
-   
-   private RequestHandler requestHandler;
-   
+
    private Object setStateLock = new Object();
-   
+
    private boolean stateSet;
-   
+
    private View currentView;
-   
-   //Map < Address, NodeAddressInfo>
-   private Map nodeIdAddressesMap;
-   
+
+   private Map replicatedData;
+
+   private Set replicationListeners;
+
    private Map holdingArea;
-   
-   private Element syncChannelConfigE;
-   
-   private Element asyncChannelConfigE;
-   
-   private String syncChannelConfigS;
-   
-   private String asyncChannelConfigS;
-   
+
+   //Map < node id , failover node id>
+   private Map failoverMap;
+
+   private Set leftSet;
+
    private long stateTimeout;
-   
+
    private long castTimeout;
-   
+
    private MessagePullPolicy messagePullPolicy;
-   
+
    private ClusterRouterFactory routerFactory;
-   
+
+   private FailoverMapper failoverMapper;
+
    private Map routerMap;
-   
+
+   /** List of failed over bindings.
+    *  Map<int nodeId, Map<channelId,Binding>>*/
+   private Map failedBindings;
+
    private StatsSender statsSender;
-   
-   private boolean started;
-      
-   public DefaultClusteredPostOffice()
-   {        
-      init();
-   }
-   
-   private void init()
-   {
-      this.nodeIdAddressesMap = new HashMap();
-      
-      this.holdingArea = new HashMap();
-   }
-   
+
+   private ReplicationListener nodeAddressMapListener;
+
+   private NotificationBroadcasterSupport nbSupport;
+
+   private QueuedExecutor viewExecutor;
+
+
+   // Constructors --------------------------------------------------
+
    /*
     * Constructor using Element for configuration
     */
-   public DefaultClusteredPostOffice(DataSource ds, TransactionManager tm, Properties sqlProperties,
-            boolean createTablesOnStartup,
-            int nodeId, String officeName, MessageStore ms,
-            PersistenceManager pm,
-            TransactionRepository tr,
-            FilterFactory filterFactory,
-            QueuedExecutorPool pool,                              
-            String groupName,
-            Element syncChannelConfig,
-            Element asyncChannelConfig,
-            long stateTimeout, long castTimeout,
-            MessagePullPolicy redistributionPolicy,
-            ClusterRouterFactory rf,
-            long statsSendPeriod) throws Exception
-   {            
+   public DefaultClusteredPostOffice(DataSource ds,
+                                     TransactionManager tm,
+                                     Properties sqlProperties,
+                                     boolean createTablesOnStartup,
+                                     int nodeId,
+                                     String officeName,
+                                     MessageStore ms,
+                                     PersistenceManager pm,
+                                     TransactionRepository tr,
+                                     FilterFactory filterFactory,
+                                     ConditionFactory conditionFactory,
+                                     QueuedExecutorPool pool,
+                                     String groupName,
+                                     Element syncChannelConfig,
+                                     Element asyncChannelConfig,
+                                     long stateTimeout, long castTimeout,
+                                     MessagePullPolicy redistributionPolicy,
+                                     ClusterRouterFactory rf,
+                                     FailoverMapper failoverMapper,
+                                     long statsSendPeriod)
+      throws Exception
+   {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
-           pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
-           rf, statsSendPeriod);
-      
-      this.syncChannelConfigE = syncChannelConfig;      
-      this.asyncChannelConfigE = asyncChannelConfig;     
+           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout,
+           redistributionPolicy, rf, failoverMapper, statsSendPeriod);
+
+      this.syncChannelConfigElement = syncChannelConfig;
+      this.asyncChannelConfigElement = asyncChannelConfig;
    }
-     
+
    /*
     * Constructor using String for configuration
     */
-   public DefaultClusteredPostOffice(DataSource ds, TransactionManager tm, Properties sqlProperties,
-                              boolean createTablesOnStartup,
-                              int nodeId, String officeName, MessageStore ms,
-                              PersistenceManager pm,
-                              TransactionRepository tr,
-                              FilterFactory filterFactory,
-                              QueuedExecutorPool pool,                              
-                              String groupName,
-                              String syncChannelConfig,
-                              String asyncChannelConfig,
-                              long stateTimeout, long castTimeout,
-                              MessagePullPolicy redistributionPolicy,                      
-                              ClusterRouterFactory rf,
-                              long statsSendPeriod) throws Exception
-   {            
+   public DefaultClusteredPostOffice(DataSource ds,
+                                     TransactionManager tm,
+                                     Properties sqlProperties,
+                                     boolean createTablesOnStartup,
+                                     int nodeId,
+                                     String officeName,
+                                     MessageStore ms,
+                                     PersistenceManager pm,
+                                     TransactionRepository tr,
+                                     FilterFactory filterFactory,
+                                     ConditionFactory conditionFactory,
+                                     QueuedExecutorPool pool,
+                                     String groupName,
+                                     String syncChannelConfig,
+                                     String asyncChannelConfig,
+                                     long stateTimeout, long castTimeout,
+                                     MessagePullPolicy redistributionPolicy,
+                                     ClusterRouterFactory rf,
+                                     FailoverMapper failoverMapper,
+                                     long statsSendPeriod) throws Exception
+   {
       this(ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms,
-           pm, tr, filterFactory, pool, groupName, stateTimeout, castTimeout, redistributionPolicy,
-           rf, statsSendPeriod);
+           pm, tr, filterFactory, conditionFactory, pool, groupName, stateTimeout, castTimeout,
+           redistributionPolicy, rf, failoverMapper, statsSendPeriod);
 
-      this.syncChannelConfigS = syncChannelConfig;      
-      this.asyncChannelConfigS = asyncChannelConfig;     
+      this.syncChannelConfig = syncChannelConfig;
+      this.asyncChannelConfig = asyncChannelConfig;
    }
-   
-   private DefaultClusteredPostOffice(DataSource ds, TransactionManager tm, Properties sqlProperties,
-                               boolean createTablesOnStartup,
-                               int nodeId, String officeName, MessageStore ms,
-                               PersistenceManager pm,                               
-                               TransactionRepository tr,
-                               FilterFactory filterFactory,
-                               QueuedExecutorPool pool,
-                               String groupName,
-                               long stateTimeout, long castTimeout,                             
-                               MessagePullPolicy redistributionPolicy,                               
-                               ClusterRouterFactory rf,
-                               long statsSendPeriod)
+
+   private DefaultClusteredPostOffice(DataSource ds,
+                                      TransactionManager tm,
+                                      Properties sqlProperties,
+                                      boolean createTablesOnStartup,
+                                      int nodeId,
+                                      String officeName,
+                                      MessageStore ms,
+                                      PersistenceManager pm,
+                                      TransactionRepository tr,
+                                      FilterFactory filterFactory,
+                                      ConditionFactory conditionFactory,
+                                      QueuedExecutorPool pool,
+                                      String groupName,
+                                      long stateTimeout, long castTimeout,
+                                      MessagePullPolicy redistributionPolicy,
+                                      ClusterRouterFactory rf,
+                                      FailoverMapper failoverMapper,
+                                      long statsSendPeriod)
    {
-      super (ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms, pm, tr, filterFactory,
-             pool);
-                   
-      this.pm = pm;
-      
+      super (ds, tm, sqlProperties, createTablesOnStartup, nodeId, officeName, ms, pm, tr,
+             filterFactory, conditionFactory, pool);
+
       this.groupName = groupName;
-      
+
       this.stateTimeout = stateTimeout;
-      
+
       this.castTimeout = castTimeout;
-      
+
       this.messagePullPolicy = redistributionPolicy;
-      
+
       this.routerFactory = rf;
-      
+
+      this.failoverMapper = failoverMapper;
+
       routerMap = new HashMap();
-      
+
+      failedBindings = new LinkedHashMap();
+
       statsSender = new StatsSender(this, statsSendPeriod);
-      
-      init();
+
+      holdingArea = new HashMap();
+
+      replicatedData = new HashMap();
+
+      replicationListeners = new LinkedHashSet();
+
+      failoverMap = new LinkedHashMap();
+
+      leftSet = new HashSet();
+
+      nbSupport = new NotificationBroadcasterSupport();
+
+      viewExecutor = new QueuedExecutor();
    }
 
-   // MessagingComponent overrides
-   // --------------------------------------------------------------
-   
+   // MessagingComponent overrides ----------------------------------
+
    public synchronized void start() throws Exception
-   {    
+   {
       if (started)
       {
          log.warn("Attempt to start() but " + this + " is already started");
       }
-      
-      if (syncChannelConfigE != null)
-      {        
-         this.syncChannel = new JChannel(syncChannelConfigE);
-         this.asyncChannel = new JChannel(asyncChannelConfigE); 
+
+      if (trace) { log.trace(this + " starting"); }
+
+      if (syncChannelConfigElement != null)
+      {
+         this.syncChannel = new JChannel(syncChannelConfigElement);
+         this.asyncChannel = new JChannel(asyncChannelConfigElement);
       }
       else
       {
-         this.syncChannel = new JChannel(syncChannelConfigS);
-         this.asyncChannel = new JChannel(asyncChannelConfigS); 
+         this.syncChannel = new JChannel(syncChannelConfig);
+         this.asyncChannel = new JChannel(asyncChannelConfig);
       }
-      
-      //We don't want to receive local messages on any of the channels
+
+      // We don't want to receive local messages on any of the channels
       syncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
-      
+
       asyncChannel.setOpt(Channel.LOCAL, Boolean.FALSE);
-      
-      this.controlMessageListener = new ControlMessageListener();
-      
-      this.requestHandler = new PostOfficeRequestHandler();
-      
-      this.controlMembershipListener = new ControlMembershipListener();
-      
-      this.controlMessageDispatcher = new MessageDispatcher(syncChannel, controlMessageListener,
-                                                            controlMembershipListener, requestHandler, true);      
-      this.dataReceiver = new DataReceiver();
-      
-      asyncChannel.setReceiver(dataReceiver);    
-             
+
+      MessageListener cml = new ControlMessageListener();
+      MembershipListener ml = new ControlMembershipListener();
+      RequestHandler rh = new PostOfficeRequestHandler();
+
+      //Register as a listener for nodeid-adress mapping events
+      nodeAddressMapListener = new NodeAddressMapListener();
+
+      registerListener(nodeAddressMapListener);
+
+      this.controlMessageDispatcher = new MessageDispatcher(syncChannel, cml, ml, rh, true);
+
+      Receiver r = new DataReceiver();
+
+      asyncChannel.setReceiver(r);
+
       syncChannel.connect(groupName);
-      
+
       asyncChannel.connect(groupName);
-      
+
       super.start();
-                  
+
       Address syncAddress = syncChannel.getLocalAddress();
-      
+
       Address asyncAddress = asyncChannel.getLocalAddress();
-                     
-      NodeAddressInfo info = new NodeAddressInfo(syncAddress, asyncAddress);
-      
-      handleAddressNodeMapping(info, nodeId);
-      
-      syncSendRequest(new SendNodeIdRequest(info, nodeId));           
-      
+
+      PostOfficeAddressInfo info = new PostOfficeAddressInfo(syncAddress, asyncAddress);
+
+      put(ADDRESS_INFO_KEY, info);
+
       statsSender.start();
-      
-      started = true;   
-      
-      if (trace) { log.trace("Started " + this + " with sync address " + syncAddress +
-                             " async address " + asyncAddress); }
+
+      started = true;
+
+      log.debug(this + " started");
    }
 
-   public synchronized void stop() throws Exception
+   public synchronized void stop(boolean sendNotification) throws Exception
    {
       if (!started)
       {
          log.warn("Attempt to stop() but " + this + " is not started");
       }
-      
-      super.stop();
-      
-      statsSender.stop();
-         
-      syncChannel.close();
-      
-      asyncChannel.close();
-      
-      started = false;
-      
-      if (trace) { log.trace("Stopped " + this); }
-   }  
-   
-   // PostOffice implementation ---------------------------------------        
+      else
+      {
+         syncSendRequest(new LeaveClusterRequest(this.getNodeId()));
 
-   public Binding bindClusteredQueue(String condition, LocalClusteredQueue queue) throws Exception
-   {           
-      if (trace)
+         super.stop(sendNotification);
+
+         unregisterListener(nodeAddressMapListener);
+
+         statsSender.stop();
+
+         syncChannel.close();
+
+         asyncChannel.close();
+
+         started = false;
+
+         if (trace) { log.trace("Stopped " + this); }
+      }
+   }
+
+   // NotificationBroadcaster implementation ------------------------
+
+   public void addNotificationListener(NotificationListener listener,
+                                       NotificationFilter filter,
+                                       Object object) throws IllegalArgumentException
+   {
+      nbSupport.addNotificationListener(listener, filter, object);
+   }
+
+   public void removeNotificationListener(NotificationListener listener)
+      throws ListenerNotFoundException
+   {
+      nbSupport.removeNotificationListener(listener);
+   }
+
+   public MBeanNotificationInfo[] getNotificationInfo()
+   {
+      return new MBeanNotificationInfo[0];
+   }
+
+   // Peer implementation -------------------------------------------
+
+   public Set getNodeIDView()
+   {
+      if (syncChannel == null)
       {
-         log.trace(this.nodeId + " binding clustered queue: " + queue + " with condition: " + condition);
+         return Collections.EMPTY_SET;
       }
-        
-      if (queue.getNodeId() != this.nodeId)
+
+      Map addressInfo = null;
+
+      synchronized(replicatedData)
       {
-         throw new IllegalArgumentException("Queue node id does not match office node id");
+         addressInfo = new HashMap((Map)replicatedData.get(ADDRESS_INFO_KEY));
       }
-      
+
+      Set nodeIDView = null;
+
+      for (Iterator i = syncChannel.getView().getMembers().iterator(); i.hasNext(); )
+      {
+         if (nodeIDView == null)
+         {
+            nodeIDView = new HashSet();
+         }
+
+         Address addr = (Address)i.next();
+
+         for(Iterator j = addressInfo.entrySet().iterator(); j.hasNext(); )
+         {
+            Map.Entry entry = (Map.Entry)j.next();
+
+            if (((PostOfficeAddressInfo)(entry.getValue())).getSyncChannelAddress().equals(addr))
+            {
+               nodeIDView.add(entry.getKey());
+            }
+         }
+      }
+
+      return nodeIDView;
+   }
+
+   // ClusteredPostOffice implementation ----------------------------
+
+   public Binding bindClusteredQueue(Condition condition, LocalClusteredQueue queue) throws Exception
+   {
+      if (trace) { log.trace(this.currentNodeId + " binding clustered queue: " + queue + " with condition: " + condition); }
+
+      if (queue.getNodeId() != this.currentNodeId)
+      {
+          log.warn("queue.getNodeId is not this node");
+         //throw new IllegalArgumentException("Queue node id does not match office node id");
+         // todo what to do when HA failing?
+      }
+
       Binding binding = (Binding)super.bindQueue(condition, queue);
-      
-      BindRequest request =
-         new BindRequest(nodeId, queue.getName(), condition, queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
-                         binding.getQueue().getChannelID(), queue.isRecoverable());
-      
-      syncSendRequest(request);
-        
+
+      sendBindRequest(condition, queue, binding);
+
       return binding;
    }
-   
+
    public Binding unbindClusteredQueue(String queueName) throws Throwable
    {
-      if (trace)
-      {
-         log.trace(this.nodeId + " unbind clustered queue: " + queueName);
-      }
-        
+      if (trace) { log.trace(this.currentNodeId + " unbind clustered queue: " + queueName); }
+
       Binding binding = (Binding)super.unbindQueue(queueName);
-      
-      UnbindRequest request = new UnbindRequest(nodeId, queueName);
-      
+
+      UnbindRequest request = new UnbindRequest(this.currentNodeId, queueName);
+
       syncSendRequest(request);
-      
+
       return binding;
    }
-   
-   public boolean route(MessageReference ref, String condition, Transaction tx) throws Exception
+
+   public Collection listAllBindingsForCondition(Condition condition) throws Exception
    {
-      if (trace)
-      {
-         log.trace(this.nodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx);
-      }
-      
-      if (ref == null)
-      {
-         throw new IllegalArgumentException("Message reference is null");
-      }
-      
-      if (condition == null)
-      {
-         throw new IllegalArgumentException("Condition is null");
-      }
-      
-      boolean routed = false;
-      
+      return listBindingsForConditionInternal(condition, false);
+   }
+
+   public Binding getBindingforChannelId(long channelId) throws Exception
+   {
       lock.readLock().acquire();
-   
+
       try
-      {      
-         ClusteredBindings cb = (ClusteredBindings)conditionMap.get(condition);
-         
-         boolean startInternalTx = false;
-         
-         int lastNodeId = -1;
-         
-         if (cb != null)
+      {
+         //First look in the failed map
+         //Failed bindings are stored in the failed map by channel id
+         Map channelMap = (Map)failedBindings.get(new Integer(currentNodeId));
+         Binding binding = null;
+         if (channelMap != null)
          {
-            if (tx == null && ref.isReliable())
-            {                
-               if (!(cb.getDurableCount() == 0 || (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
-               {
-                  // When routing a persistent message without a transaction then we may need to start an 
-                  // internal transaction in order to route it.
-                  // This is so we can guarantee the message is delivered to all or none of the subscriptions.
-                  // We need to do this if there is anything other than
-                  // No durable subs or exactly one local durable sub
-                  startInternalTx = true;
-                  if (trace)
-                  {
-                     log.trace(this.nodeId + " Starting internal transaction since more than one durable sub or remote durable subs");
-                  }
-               }
-            }                        
-            
-            if (startInternalTx)
-            {
-               tx = tr.createTransaction();
-            }
-                
-            int numberRemote = 0;
-            
-            Map queueNameNodeIdMap = null;
-            
-            long lastChannelId = -1;
-            
-            Collection routers = cb.getRouters();
+            binding = (Binding)channelMap.get(new Long(channelId));
+         }
 
-            Iterator iter = routers.iterator();
-                     
-            while (iter.hasNext())
+         if (binding == null)
+         {
+            //Not found in the failed map - look in the name map
+            Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
+
+            if (nameMap != null)
             {
-               ClusterRouter router = (ClusterRouter)iter.next();
-               
-               Delivery del = router.handle(null, ref, tx);
-               
-               if (del != null && del.isSelectorAccepted())
+               for (Iterator iterbindings = nameMap.values().iterator(); iterbindings.hasNext();)
                {
-                  routed = true;
-               
-                  ClusteredQueue queue = (ClusteredQueue)del.getObserver();
-                  
-                  if (trace)
+                  Binding itemBinding = (Binding)iterbindings.next();
+                  if (itemBinding.getQueue().getChannelID() == channelId)
                   {
-                     log.trace(this.nodeId + " Routing message to queue or stub:" + queue.getName() + " on node " +
-                               queue.getNodeId() +" local:" + queue.isLocal());
+                     binding = itemBinding;
+                     break;
                   }
-                  
-                  if (router.numberOfReceivers() > 1)
-                  {
-                     //We have now chosen which one will receive the message so we need to add this
-                     //information to a map which will get sent when casting - so the the queue
-                     //on the receiving node knows whether to receive the message
-                     if (queueNameNodeIdMap == null)
-                     {
-                        queueNameNodeIdMap = new HashMap();
-                     }
-                     
-                     queueNameNodeIdMap.put(queue.getName(), new Integer(queue.getNodeId()));
-                  }
-                  
-                  if (!queue.isLocal())
-                  {
-                     //We need to send the message remotely
-                     numberRemote++;
-                     
-                     lastNodeId = queue.getNodeId();                                                               
-                                          
-                     lastChannelId = queue.getChannelID();
-                  }
                }
             }
-            
-            //Now we've sent the message to any local queues, we might also need
-            //to send the message to the other office instances on the cluster if there are
-            //queues on those nodes that need to receive the message
-            
-            //TODO - there is an innefficiency here, numberRemote does not take into account that more than one
-            //of the number remote may be on the same node, so we could end up multicasting
-            //when unicast would do
-            if (numberRemote > 0)
+            else
             {
-               if (tx == null)
-               {
-                  if (numberRemote == 1)
-                  {
-                     if (trace) { log.trace(this.nodeId + " unicasting message to " + lastNodeId); }
-                     
-                     //Unicast - only one node is interested in the message                                        
-                     asyncSendRequest(new MessageRequest(condition, ref.getMessage(), null), lastNodeId);
-                  }
-                  else
-                  {
-                     if (trace) { log.trace(this.nodeId + " multicasting message to group"); }
-                     
-                     //Multicast - more than one node is interested
-                     asyncSendRequest(new MessageRequest(condition, ref.getMessage(), queueNameNodeIdMap));
-                  }                                 
-               }
-               else
-               {
-                  CastMessagesCallback callback = (CastMessagesCallback)tx.getCallback(this);
-                  
-                  if (callback == null)
-                  {
-                     callback = new CastMessagesCallback(nodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
-                     
-                     //This callback MUST be executed first
-                     
-                     //Execution order is as follows:
-                     //Before commit:
-                     //1. Cast messages across network - get added to holding area (if persistent) on receiving
-                     //nodes
-                     //2. Persist messages in persistent store
-                     //After commit
-                     //1. Cast commit message across network
-                     tx.addFirstCallback(callback, this);
-                  }
-                      
-                  callback.addMessage(condition, ref.getMessage(), queueNameNodeIdMap,
-                                      numberRemote == 1 ? lastNodeId : -1,
-                                      lastChannelId);    
-               }
+               log.info("nameMap is null");
             }
-                                                
-            if (startInternalTx)
-            {               
-               tx.commit();
-               if (trace) { log.trace("Committed internal transaction"); }
-            }
          }
+         log.info("Returned " + binding);
+         return binding;
       }
       finally
-      {                  
+      {
          lock.readLock().release();
       }
-         
-      return routed; 
    }
-   
-   public boolean isLocal()
-   {
-      return false;
-   }
-   
-   public Collection listAllBindingsForCondition(String condition) throws Exception
-   {
-      return listBindingsForConditionInternal(condition, false);
-   }
-   
-   // PostOfficeInternal implementation ------------------------------------------------------------------
-   
+
+   // PostOfficeInternal implementation -----------------------------
+
    /*
     * Called when another node adds a binding
     */
-   public void addBindingFromCluster(int nodeId, String queueName, String condition,
-                                     String filterString, long channelID, boolean durable)
+   public void addBindingFromCluster(int nodeId, String queueName, String conditionText,
+                                     String filterString, long channelID, boolean durable,
+                                     boolean failed)
       throws Exception
    {
       lock.writeLock().acquire();
-    
+
       if (trace)
       {
-         log.trace(this.nodeId + " adding binding from node: " + nodeId + " queue: " + queueName + " with condition: " + condition);        
+         log.info(this.currentNodeId + " adding binding from node: " + nodeId +
+                  " queue: " + queueName + " with condition: " + conditionText);
       }
-            
+
+      Condition condition = conditionFactory.createCondition(conditionText);
+
       try
-      {                     
+      {
          //Sanity
 
-         if (!nodeIdAddressesMap.containsKey(new Integer(nodeId)))
+         if (!knowAboutNodeId(nodeId))
          {
-            throw new IllegalStateException("Cannot find address for node: " + nodeId);
+            throw new IllegalStateException("Don't know about node id: " + nodeId);
          }
-         
+
          // We currently only allow one binding per name per node
          Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-         
+
          Binding binding = null;
-         
+
          if (nameMap != null)
          {
             binding = (Binding)nameMap.get(queueName);
          }
-         
-         if (binding != null)
+
+         if (binding != null && failed)
          {
-            throw new IllegalArgumentException(this.nodeId + " Binding already exists for node Id " + nodeId + " queue name " + queueName);
+            throw new IllegalArgumentException(this.currentNodeId +
+                     " Binding already exists for node Id " + nodeId + " queue name " + queueName);
          }
-            
-         binding = this.createBinding(nodeId, condition, queueName, channelID, filterString, durable);
-         
-         addBinding(binding);         
+
+         binding = this.createBinding(nodeId, condition, queueName, channelID, filterString,
+                                      durable, failed);
+
+         addBinding(binding);
       }
       finally
       {
          lock.writeLock().release();
       }
+
+      log.info("****** binding added");
    }
-   
+
    /*
     * Called when another node removes a binding
     */
    public void removeBindingFromCluster(int nodeId, String queueName) throws Exception
    {
       lock.writeLock().acquire();
-      
-      if (trace)
+
+      if (trace) { log.trace(this.currentNodeId + " removing binding from node: " + nodeId + " queue: " + queueName); }
+
+      try
       {
-         log.trace(this.nodeId + " removing binding from node: " + nodeId + " queue: " + queueName);        
-      }
-      
-      try
-      {         
          // Sanity
-         if (!nodeIdAddressesMap.containsKey(new Integer(nodeId)))
+         if (!knowAboutNodeId(nodeId))
          {
-            throw new IllegalStateException("Cannot find address for node: " + nodeId);
+            throw new IllegalStateException("Don't know about node id: " + nodeId);
          }
-         
-         removeBinding(nodeId, queueName);         
+
+         removeBinding(nodeId, queueName);
       }
       finally
       {
          lock.writeLock().release();
       }
    }
-   
-   public void handleAddressNodeMapping(NodeAddressInfo info, int nodeId) throws Exception
+
+   public void handleNodeLeft(int nodeId) throws Exception
    {
-      lock.writeLock().acquire();
+      synchronized (leftSet)
+      {
+         leftSet.add(new Integer(nodeId));
+      }
+   }
 
-      if (trace)
+   /**
+    * @param originatorNodeID - the ID of the node that initiated the modification.
+    */
+   public void putReplicantLocally(int originatorNodeID, Serializable key, Serializable replicant)
+      throws Exception
+   {
+      log.info("##########putReplicantLocally received, before lock");
+
+      synchronized (replicatedData)
       {
-         log.trace(this.nodeId + " Adding address node mapping for " + info.getSyncChannelAddress() +
-                   "," + info.getAsyncChannelAddress() + " and " + nodeId);
+         log.info("putReplicantLocally received, after lock");
+         Map m = (Map)replicatedData.get(key);
+
+         if (m == null)
+         {
+            m = new LinkedHashMap();
+
+            replicatedData.put(key, m);
+         }
+
+         m.put(new Integer(originatorNodeID), replicant);
+
+         notifyListeners(key, m, true, originatorNodeID);
       }
-      
-      try
-      { 
-         nodeIdAddressesMap.put(new Integer(nodeId), info);
-      }
-      finally
+
+      log.info("putReplicantLocally, completed");
+   }
+
+   /**
+    * @param originatorNodeID - the ID of the node that initiated the modification.
+    */
+   public boolean removeReplicantLocally(int originatorNodeID, Serializable key) throws Exception
+   {
+      synchronized (replicatedData)
       {
-         lock.writeLock().release();
+         log.info(this.currentNodeId + " removing key " + key + " from node " + originatorNodeID);
+
+         Map m = (Map)replicatedData.get(key);
+
+         if (m == null)
+         {
+            return false;
+         }
+
+         Object obj = m.remove(new Integer(originatorNodeID));
+
+         if (obj == null)
+         {
+            return false;
+         }
+
+         if (m.isEmpty())
+         {
+            replicatedData.remove(key);
+         }
+         notifyListeners(key, m, false, originatorNodeID);
+
+         return true;
       }
    }
-   
-   public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKey,
+
+   public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKeyText,
                                 Map queueNameNodeIdMap) throws Exception
    {
       if (trace)
       {
-         log.trace(this.nodeId + " routing from cluster, message: " + message + " routing key " +
-                  routingKey + " map " + queueNameNodeIdMap);
+         log.trace(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
+                  routingKeyText + " map " + queueNameNodeIdMap);
       }
-            
-      lock.readLock().acquire();  
 
+      log.info(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
+               routingKeyText + " map " + queueNameNodeIdMap);
+
+      Condition routingKey = conditionFactory.createCondition(routingKeyText);
+
+      lock.readLock().acquire();
+
       // Need to reference the message
       MessageReference ref = null;
       try
@@ -660,54 +715,54 @@
             // It will already have been persisted on the sender's side
             message.setPersisted(true);
          }
-         
+
          ref = ms.reference(message);
-              
+
          // We route on the condition
          DefaultClusteredBindings cb = (DefaultClusteredBindings)conditionMap.get(routingKey);
-         
+
          if (cb != null)
-         {                      
+         {
             Collection bindings = cb.getAllBindings();
-            
+
             Iterator iter = bindings.iterator();
-            
+
             while (iter.hasNext())
             {
                Binding binding = (Binding)iter.next();
-                                                     
-               if (binding.getNodeId() == this.nodeId)
-               {  
+
+               if (binding.getNodeId() == this.currentNodeId)
+               {
                   boolean handle = true;
-                  
+
                   if (queueNameNodeIdMap != null)
-                  {           
+                  {
                      Integer in = (Integer)queueNameNodeIdMap.get(binding.getQueue().getName());
-                     
+
                      //When there are more than one queues with the same name across the cluster we only
                      //want to chose one of them
-                     
+
                      if (in != null)
                      {
-                        handle = in.intValue() == nodeId;
+                        handle = in.intValue() == currentNodeId;
                      }
                   }
-                  
+
                   if (handle)
-                  {                     
+                  {
                      //It's a local binding so we pass the message on to the subscription
-                     
+
                      LocalClusteredQueue queue = (LocalClusteredQueue)binding.getQueue();
-                     
-                     Delivery del = queue.handleFromCluster(ref);    
-                     
+
+                     Delivery del = queue.handleFromCluster(ref);
+
                      if (trace)
                      {
-                        log.trace(this.nodeId + " queue " + queue.getName() + " handled reference from cluster " + del);
+                        log.trace(this.currentNodeId + " queue " + queue.getName() + " handled reference from cluster " + del);
                      }
                   }
                }
-            }                          
+            }
          }
       }
       finally
@@ -719,42 +774,42 @@
          lock.readLock().release();
       }
    }
-   
+
    /*
     * Multicast a message to all members of the group
     */
    public void asyncSendRequest(ClusterRequest request) throws Exception
-   {     
-      if (trace) { log.trace(this.nodeId + " sending asynch request to group, request: " + request); }
-      
+   {
+      if (trace) { log.trace(this.currentNodeId + " sending asynch request to group, request: " + request); }
+
       byte[] bytes = writeRequest(request);
-              
+
       asyncChannel.send(new Message(null, null, bytes));
    }
-   
+
    /*
     * Unicast a message to one member of the group
     */
    public void asyncSendRequest(ClusterRequest request, int nodeId) throws Exception
-   {               
-      if (trace) { log.trace(this.nodeId + " sending asynch request to single node, request: " + request + " node " + nodeId); }
-      
+   {
+      if (trace) { log.trace(this.currentNodeId + " sending asynch request to single node, request: " + request + " node " + nodeId); }
+
       Address address = this.getAddressForNodeId(nodeId, false);
-      
-      if (trace) { log.trace(this.nodeId + " sending to address " + address); }
-      
+
+      if (trace) { log.trace(this.currentNodeId + " sending to address " + address); }
+
       if (address == null)
       {
          throw new IllegalArgumentException("Cannot find address for node " + nodeId);
       }
-      
+
       byte[] bytes = writeRequest(request);
-            
+
       Message m = new Message(address, null, bytes);
-      
-      asyncChannel.send(m);      
+
+      asyncChannel.send(m);
    }
-   
+
    /*
     * We put the transaction in the holding area
     */
@@ -763,140 +818,161 @@
       synchronized (holdingArea)
       {
          holdingArea.put(id, tx);
-         
-         if (trace) { log.trace(this.nodeId + " added transaction " + tx + " to holding area with id " + id); }
-      } 
+
+         if (trace) { log.trace(this.currentNodeId + " added transaction " + tx + " to holding area with id " + id); }
+      }
    }
-   
+
    public void commitTransaction(TransactionId id) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " committing transaction " + id ); }
-      
+      if (trace) { log.trace(this.currentNodeId + " committing transaction " + id ); }
+
       ClusterTransaction tx = null;
-        
+
       synchronized (holdingArea)
       {
-         tx = (ClusterTransaction)holdingArea.remove(id);                
+         tx = (ClusterTransaction)holdingArea.remove(id);
       }
-      
+
       if (tx == null)
       {
          throw new IllegalStateException("Cannot find transaction transaction id: " + id);
       }
-      
+
       tx.commit(this);
-      
-      if (trace) { log.trace(this.nodeId + " committed transaction " + id ); }
+
+      if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
-   
+
    public void rollbackTransaction(TransactionId id) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " rolling back transaction " + id ); }
-      
+      if (trace) { log.trace(this.currentNodeId + " rolling back transaction " + id ); }
+
       ClusterTransaction tx = null;
-        
+
       synchronized (holdingArea)
       {
-         tx = (ClusterTransaction)holdingArea.remove(id);                
+         tx = (ClusterTransaction)holdingArea.remove(id);
       }
-      
+
       if (tx == null)
       {
          throw new IllegalStateException("Cannot find transaction transaction id: " + id);
       }
-      
+
       tx.rollback(this);
-      
-      if (trace) { log.trace(this.nodeId + " committed transaction " + id ); }
+
+      if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
    }
-   
-   /**
-    * Check for any transactions that need to be committed or rolled back
-    */
-   public void check(Integer nodeId) throws Throwable
+
+   public void updateQueueStats(int nodeId, List statsList) throws Exception
    {
-      if (trace) { log.trace(this.nodeId + " checking for any stranded transactions for node " + nodeId); }
-      
-      synchronized (holdingArea)
+      lock.readLock().acquire();
+
+      if (trace) { log.trace(this.currentNodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
+
+      try
       {
-         Iterator iter = holdingArea.entrySet().iterator();
-         
-         List toRemove = new ArrayList();
-         
-         while (iter.hasNext())
+         if (nodeId == this.currentNodeId)
          {
-            Map.Entry entry = (Map.Entry)iter.next();
-            
-            TransactionId id = (TransactionId)entry.getKey();
-            
-            if (id.getNodeId() == nodeId.intValue())
+            //Sanity check
+            throw new IllegalStateException("Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!");
+         }
+
+         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
+
+         if (nameMap == null)
+         {
+            //This is ok, the node might have left
+            if (trace) { log.trace(this.currentNodeId + " cannot find node in name map, i guess the node might have left?"); }
+         }
+         else
+         {
+            Iterator iter = statsList.iterator();
+
+            while (iter.hasNext())
             {
-               ClusterTransaction tx = (ClusterTransaction)entry.getValue();
-               
-               if (trace) { log.trace("Found transaction " + tx + " in holding area"); }
-                
-               boolean commit = tx.check(this);
-               
-               if (trace) { log.trace(this.nodeId + " transaction " + tx + " will be committed?: " + commit); }
-               
-               if (commit)
+               QueueStats st = (QueueStats)iter.next();
+
+               Binding bb = (Binding)nameMap.get(st.getQueueName());
+
+               if (bb == null)
                {
-                  tx.commit(this);
+                  //I guess this is possible if the queue was unbound
+                  if (trace) { log.trace(this.currentNodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
                }
                else
                {
-                  tx.rollback(this);
+                  RemoteQueueStub stub = (RemoteQueueStub)bb.getQueue();
+
+                  stub.setStats(st);
+
+                  if (trace) { log.trace(this.currentNodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
+
+                  ClusterRouter router = (ClusterRouter)routerMap.get(st.getQueueName());
+
+                  //Maybe the local queue now wants to pull message(s) from the remote queue given that the
+                  //stats for the remote queue have changed
+                  LocalClusteredQueue localQueue = (LocalClusteredQueue)router.getLocalQueue();
+
+                  if (localQueue!=null)
+                  {
+                     //TODO - the call to getQueues is too slow since it creates a new list and adds the local queue!!!
+                     RemoteQueueStub toQueue = (RemoteQueueStub)messagePullPolicy.chooseQueue(router.getQueues());
+
+                     if (trace) { log.trace(this.currentNodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
+
+                     localQueue.setPullQueue(toQueue);
+
+                     if (toQueue != null && localQueue.getRefCount() == 0)
+                     {
+                        //We now trigger delivery - this may cause a pull event
+                        //We only do this if there are no refs in the local queue
+
+                        localQueue.deliver(false);
+
+                        if (trace) { log.trace(this.currentNodeId + " triggered delivery for " + localQueue.getName()); }
+                     }
+                  }
                }
-               
-               toRemove.add(id);
-               
-               if (trace) { log.trace(this.nodeId + " resolved " + tx); }
             }
          }
-         
-         //Remove the transactions from the holding area
-         
-         iter = toRemove.iterator();
-         
-         while (iter.hasNext())
-         {
-            TransactionId id = (TransactionId)iter.next();
-            
-            holdingArea.remove(id);
-         }
       }
-      if (trace) { log.trace(this.nodeId + " check complete"); }
+      finally
+      {
+         lock.readLock().release();
+      }
    }
-   
+
    public void sendQueueStats() throws Exception
    {
       if (!started)
       {
          return;
       }
-      
+
       lock.readLock().acquire();
- 
-      List statsList = null;      
-      
+
+      List statsList = null;
+
       try
-      {         
-         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-         
+      {
+         Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
+
          if (nameMap != null)
-         {            
+         {
             Iterator iter = nameMap.values().iterator();
-                     
+
             while (iter.hasNext())
             {
                Binding bb = (Binding)iter.next();
-               
+
                LocalClusteredQueue q = (LocalClusteredQueue)bb.getQueue();
-                             
+
                if (q.isActive())
-               {                                                      
+               {
                   QueueStats stats = q.getStats();
-                                              
+
                   if (stats != null)
                   {
                      if (statsList == null)
@@ -905,9 +981,9 @@
                      }
 
                      statsList.add(stats);
-                     
-                     if (trace) { log.trace(this.nodeId + " adding stat for send " + stats); }
-                  } 
+
+                     if (trace) { log.trace(this.currentNodeId + " adding stat for send " + stats); }
+                  }
                }
             }
          }
@@ -916,144 +992,64 @@
       {
          lock.readLock().release();
       }
-      
+
       if (statsList != null)
       {
-         ClusterRequest req = new QueueStatsRequest(nodeId, statsList);
-         
+         ClusterRequest req = new QueueStatsRequest(currentNodeId, statsList);
+
          asyncSendRequest(req);
-         
-         if (trace) { log.trace(this.nodeId + " Sent stats"); }
+
+         if (trace) { log.trace(this.currentNodeId + " Sent stats"); }
       }
    }
-   
-   public void updateQueueStats(int nodeId, List statsList) throws Exception
-   {
-      lock.readLock().acquire();
 
-      if (trace) { log.trace(this.nodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
-      
-      try
-      {      
-         if (nodeId == this.nodeId)
-         {
-            //Sanity check
-            throw new IllegalStateException("Received stats from node with id that matches this nodes id. You may have started two or more nodes with the same node id!");
-         }
-         
-         Map nameMap = (Map)nameMaps.get(new Integer(nodeId));
-         
-         if (nameMap == null)
-         {
-            //This is ok, the node might have left
-            if (trace) { log.trace(this.nodeId + " cannot find node in name map, i guess the node might have left?"); }
-         }
-         else
-         {     
-            Iterator iter = statsList.iterator();
-            
-            while (iter.hasNext())
-            {
-               QueueStats st = (QueueStats)iter.next();
-               
-               Binding bb = (Binding)nameMap.get(st.getQueueName());
-               
-               if (bb == null)
-               {
-                  //I guess this is possible if the queue was unbound
-                  if (trace) { log.trace(this.nodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
-               }
-               else
-               {                  
-                  RemoteQueueStub stub = (RemoteQueueStub)bb.getQueue();
-                  
-                  stub.setStats(st);
-                  
-                  if (trace) { log.trace(this.nodeId + " setting stats: " + st + " on remote stub " + stub.getName()); }
-                  
-                  ClusterRouter router = (ClusterRouter)routerMap.get(st.getQueueName());
-                  
-                  //Maybe the local queue now wants to pull message(s) from the remote queue given that the 
-                  //stats for the remote queue have changed
-                  LocalClusteredQueue localQueue = (LocalClusteredQueue)router.getLocalQueue();
-                  
-                  if (localQueue != null)
-                  {               
-                     //TODO - the call to getQueues is too slow since it creates a new list and adds the local queue!!!
-                     RemoteQueueStub toQueue = (RemoteQueueStub)messagePullPolicy.chooseQueue(router.getQueues());
-                     
-                     if (trace) { log.trace(this.nodeId + " recalculated pull queue for queue " + st.getQueueName() + " to be " + toQueue); }
-                                    
-                     localQueue.setPullQueue(toQueue);
-                     
-                     if (toQueue != null && localQueue.getRefCount() == 0)
-                     {
-                        //We now trigger delivery - this may cause a pull event                                                
-                        //We only do this if there are no refs in the local queue
-                        
-                        localQueue.deliver(false);
-                                                                    
-                        if (trace) { log.trace(this.nodeId + " triggered delivery for " + localQueue.getName()); }
-                     }
-                  } 
-               }
-            }         
-         }         
-      }
-      finally
-      {
-         lock.readLock().release();      
-      }
-   }      
-   
    public boolean referenceExistsInStorage(long channelID, long messageID) throws Exception
    {
       return pm.referenceExists(channelID, messageID);
-   } 
-  
-   
+   }
+
    public void handleMessagePullResult(int remoteNodeId, long holdingTxId,
                                        String queueName, org.jboss.messaging.core.Message message) throws Throwable
    {
-      if (trace) { log.trace(this.nodeId + " handling pull result " + message + " for " + queueName); }
-               
+      if (trace) { log.trace(this.currentNodeId + " handling pull result " + message + " for " + queueName); }
+
       Binding binding = getBindingForQueueName(queueName);
-      
+
       //The binding might be null if the queue was unbound
-      
+
       boolean handled = false;
-      
+
       if (!failHandleResult && binding != null)
-      {                     
+      {
          LocalClusteredQueue localQueue = (LocalClusteredQueue)binding.getQueue();
-              
+
          RemoteQueueStub remoteQueue = localQueue.getPullQueue();
-         
+
          if (remoteNodeId != remoteQueue.getNodeId())
          {
             //It might have changed since the request was sent
             Map bindings = (Map)nameMaps.get(new Integer(remoteNodeId));
-            
+
             if (bindings != null)
             {
                binding = (Binding)bindings.get(queueName);
-               
+
                if (binding != null)
-               {                     
-                 remoteQueue = (RemoteQueueStub)binding.getQueue();                              
+               {
+                 remoteQueue = (RemoteQueueStub)binding.getQueue();
                }
             }
          }
-         
+
          if (remoteQueue != null)
          {
             localQueue.handlePullMessagesResult(remoteQueue, message, holdingTxId,
                                                 failBeforeCommit, failAfterCommit);
-            
+
             handled = true;
-         }     
+         }
       }
-      
+
       if (!handled)
       {
          //If we didn't handle it for what ever reason, then we might have to send a rollback
@@ -1062,231 +1058,669 @@
          if (message.isReliable())
          {
             //Only reliable messages will be in holding area
-            this.asyncSendRequest(new RollbackPullRequest(this.nodeId, holdingTxId), remoteNodeId);
-            
-            if (trace) { log.trace(this.nodeId + " send rollback pull request"); }
+            this.asyncSendRequest(new RollbackPullRequest(this.currentNodeId, holdingTxId), remoteNodeId);
+
+            if (trace) { log.trace(this.currentNodeId + " send rollback pull request"); }
          }
-      }      
+      }
    }
-   
-   
+
+   // Replicator implementation -------------------------------------
+
+   public void put(Serializable key, Serializable replicant) throws Exception
+   {
+      putReplicantLocally(currentNodeId, key, replicant);
+
+      PutReplicantRequest request = new PutReplicantRequest(currentNodeId, key, replicant);
+
+      syncSendRequest(request);
+   }
+
+   public Map get(Serializable key) throws Exception
+   {
+      synchronized (replicatedData)
+      {
+         Map m = (Map)replicatedData.get(key);
+
+         return m == null ? Collections.EMPTY_MAP : Collections.unmodifiableMap(m);
+      }
+   }
+
+   public boolean remove(Serializable key) throws Exception
+   {
+      if (removeReplicantLocally(this.currentNodeId, key))
+      {
+         RemoveReplicantRequest request = new RemoveReplicantRequest(this.currentNodeId, key);
+
+         syncSendRequest(request);
+
+         return true;
+      }
+      else
+      {
+         return false;
+      }
+   }
+
+   public void registerListener(ReplicationListener listener)
+   {
+      synchronized (replicationListeners)
+      {
+         if (replicationListeners.contains(listener))
+         {
+            throw new IllegalArgumentException("Listener " + listener + " is already registered");
+         }
+         replicationListeners.add(listener);
+      }
+   }
+
+   public void unregisterListener(ReplicationListener listener)
+   {
+      synchronized (replicationListeners)
+      {
+         boolean removed = replicationListeners.remove(listener);
+
+         if (!removed)
+         {
+            throw new IllegalArgumentException("Cannot find listener " + listener + " to remove");
+         }
+      }
+   }
+
+   public FailoverMapper getFailoverMapper()
+   {
+      return failoverMapper;
+   }
+
+   // Public --------------------------------------------------------
+
+   public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
+   {
+      if (trace) { log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx); }
+
+      //debug
+      try
+      {
+         TextMessage tm = (TextMessage)ref.getMessage();
+
+         log.info(this.currentNodeId + " *********** Routing ref: " + tm.getText() + " with condition " + condition + " and transaction " + tx);
+      }
+      catch (Exception e)
+      {
+         e.printStackTrace();
+      }
+
+      if (ref == null)
+      {
+         throw new IllegalArgumentException("Message reference is null");
+      }
+
+      if (condition == null)
+      {
+         throw new IllegalArgumentException("Condition is null");
+      }
+
+      boolean routed = false;
+
+      lock.readLock().acquire();
+
+      try
+      {
+         ClusteredBindings cb = (ClusteredBindings)conditionMap.get(condition);
+
+         boolean startInternalTx = false;
+
+         int lastNodeId = -1;
+
+         if (cb != null)
+         {
+            if (tx == null && ref.isReliable())
+            {
+               if (!(cb.getDurableCount() == 0 || (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
+               {
+                  // When routing a persistent message without a transaction then we may need to
+                  // start an internal transaction in order to route it. This is so we can guarantee
+                  // the message is delivered to all or none of the subscriptions. We need to do
+                  // this if there is anything other than. No durable subs or exactly one local
+                  // durable sub.
+
+                  startInternalTx = true;
+
+                  if (trace) { log.trace(this.currentNodeId + " Starting internal transaction since more than one durable sub or remote durable subs"); }
+               }
+            }
+
+            if (startInternalTx)
+            {
+               tx = tr.createTransaction();
+            }
+
+            int numberRemote = 0;
+
+            Map queueNameNodeIdMap = null;
+
+            long lastChannelId = -1;
+
+            Collection routers = cb.getRouters();
+
+            Iterator iter = routers.iterator();
+
+            while (iter.hasNext())
+            {
+               ClusterRouter router = (ClusterRouter)iter.next();
+
+               Delivery del = router.handle(null, ref, tx);
+
+               if (del != null && del.isSelectorAccepted())
+               {
+                  routed = true;
+
+                  ClusteredQueue queue = (ClusteredQueue)del.getObserver();
+
+                  if (trace) { log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " + queue.getNodeId() + " local:" + queue.isLocal()); }
+
+                  log.info(this.currentNodeId + " Routing message to queue or stub:" +
+                           queue.getName() + " on node " + queue.getNodeId() + " local:" +
+                           queue.isLocal());
+
+                  if (router.numberOfReceivers() > 1)
+                  {
+                     //We have now chosen which one will receive the message so we need to add this
+                     //information to a map which will get sent when casting - so the the queue
+                     //on the receiving node knows whether to receive the message
+                     if (queueNameNodeIdMap == null)
+                     {
+                        queueNameNodeIdMap = new HashMap();
+                     }
+
+                     queueNameNodeIdMap.put(queue.getName(), new Integer(queue.getNodeId()));
+                  }
+
+                  if (!queue.isLocal())
+                  {
+                     //We need to send the message remotely
+                     numberRemote++;
+
+                     lastNodeId = queue.getNodeId();
+
+                     lastChannelId = queue.getChannelID();
+                  }
+               }
+            }
+
+            //Now we've sent the message to any local queues, we might also need
+            //to send the message to the other office instances on the cluster if there are
+            //queues on those nodes that need to receive the message
+
+            //TODO - there is an innefficiency here, numberRemote does not take into account that more than one
+            //of the number remote may be on the same node, so we could end up multicasting
+            //when unicast would do
+            if (numberRemote > 0)
+            {
+               if (tx == null)
+               {
+                  if (numberRemote == 1)
+                  {
+                     if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
+
+                     //Unicast - only one node is interested in the message
+                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), null), lastNodeId);
+                  }
+                  else
+                  {
+                     if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
+
+                     //Multicast - more than one node is interested
+                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), queueNameNodeIdMap));
+                  }
+               }
+               else
+               {
+                  CastMessagesCallback callback = (CastMessagesCallback)tx.getCallback(this);
+
+                  if (callback == null)
+                  {
+                     callback = new CastMessagesCallback(currentNodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
+
+                     //This callback MUST be executed first
+
+                     //Execution order is as follows:
+                     //Before commit:
+                     //1. Cast messages across network - get added to holding area (if persistent) on receiving
+                     //nodes
+                     //2. Persist messages in persistent store
+                     //After commit
+                     //1. Cast commit message across network
+                     tx.addFirstCallback(callback, this);
+                  }
+
+                  callback.addMessage(condition, ref.getMessage(), queueNameNodeIdMap,
+                                      numberRemote == 1 ? lastNodeId : -1,
+                                      lastChannelId);
+               }
+            }
+
+            if (startInternalTx)
+            {
+               tx.commit();
+               if (trace) { log.trace("Committed internal transaction"); }
+            }
+         }
+      }
+      finally
+      {
+         lock.readLock().release();
+      }
+
+      return routed;
+   }
+
+   public boolean isLocal()
+   {
+      return false;
+   }
+
+   /**
+    * Check for any transactions that need to be committed or rolled back
+    */
+   public void check(Integer nodeId) throws Throwable
+   {
+      if (trace) { log.trace(this.currentNodeId + " checking for any stranded transactions for node " + nodeId); }
+
+      synchronized (holdingArea)
+      {
+         Iterator iter = holdingArea.entrySet().iterator();
+
+         List toRemove = new ArrayList();
+
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+
+            TransactionId id = (TransactionId)entry.getKey();
+
+            if (id.getNodeId() == nodeId.intValue())
+            {
+               ClusterTransaction tx = (ClusterTransaction)entry.getValue();
+
+               if (trace) { log.trace("Found transaction " + tx + " in holding area"); }
+
+               boolean commit = tx.check(this);
+
+               if (trace) { log.trace(this.currentNodeId + " transaction " + tx + " will be committed?: " + commit); }
+
+               if (commit)
+               {
+                  tx.commit(this);
+               }
+               else
+               {
+                  tx.rollback(this);
+               }
+
+               toRemove.add(id);
+
+               if (trace) { log.trace(this.currentNodeId + " resolved " + tx); }
+            }
+         }
+
+         //Remove the transactions from the holding area
+
+         iter = toRemove.iterator();
+
+         while (iter.hasNext())
+         {
+            TransactionId id = (TransactionId)iter.next();
+
+            holdingArea.remove(id);
+         }
+      }
+      if (trace) { log.trace(this.currentNodeId + " check complete"); }
+   }
+
    public int getNodeId()
    {
-      return nodeId;
+      return currentNodeId;
    }
-                        
-   // Public ------------------------------------------------------------------------------------------
-      
-   //Used for testing only
+
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer("ClusteredPostOffice[");
+      sb.append(currentNodeId).append(":").append(getOfficeName()).append(":");
+
+      if (syncChannel == null)
+      {
+         sb.append("UNINITIALIZED");
+      }
+      else
+      {
+         Address addr = syncChannel.getLocalAddress();
+         if (addr == null)
+         {
+            sb.append("UNCONNECTED");
+         }
+         else
+         {
+            sb.append(addr);
+         }
+      }
+
+      sb.append("]");
+      return sb.toString();
+   }
+
+   public String printBindingInformation()
+   {
+      StringWriter buffer = new StringWriter();
+      PrintWriter out = new PrintWriter(buffer);
+      out.print(super.printBindingInformation());
+
+      out.println("<br>FailOver bindings");
+      out.println("<table border=1><tr><td>Node</td><td>ChannelID</td><td>Binding</td>");
+
+      for (Iterator iter = this.failedBindings.entrySet().iterator(); iter.hasNext();)
+      {
+         Map.Entry entry = (Map.Entry)iter.next();
+
+         int count=0;
+         Map bindings = (Map)entry.getValue();
+         for (Iterator iterValues = bindings.entrySet().iterator();iterValues.hasNext();)
+         {
+            Map.Entry entry2 = (Map.Entry)iterValues.next();
+            if ( count++ == 0 )
+            {
+               out.print("<tr><td>" + entry.getKey() + "</td>");
+            }
+            else
+            {
+               out.print("<tr><td>&nbsp;</td>");
+            }
+            out.println("<td>" + entry2.getKey() + "</td><td>" + entry2.getValue() + "</td></tr>");
+         }
+      }
+
+      out.println("</table>");
+
+      out.println("<br>Router Information");
+
+      out.println("<table border=1><tr><td>Queue Route</td><td>Local Queue</td><td>Elements</td></tr>");
+
+      for (Iterator iterRouter = routerMap.entrySet().iterator();iterRouter.hasNext();)
+      {
+         Map.Entry entry = (Map.Entry)iterRouter.next();
+         ClusterRouter router = (ClusterRouter)entry.getValue();
+         out.println("<tr><td>" + entry.getKey() + "</td><td>" + router.getLocalQueue() + "</td>");
+
+         out.println("<td>");
+
+         out.println("<table border=1>");
+
+         if (!router.getFailedQueues().isEmpty())
+         {
+            out.println("<tr><td><b>Failed Over Queues</b></td><</tr>");
+            for (Iterator queuesIterator = router.getFailedQueues().iterator();queuesIterator.hasNext();)
+            {
+               Object queue = queuesIterator.next();
+               out.println("<tr><td>" + queue + "</td></tr>");
+            }
+         }
+
+         out.println("<tr><td><b>Queues</b></td><</tr>");
+
+         for (Iterator queuesIterator = router.getQueues().iterator();queuesIterator.hasNext();)
+         {
+            Object queueRouted = queuesIterator.next();
+            out.println("<tr><td>" + queueRouted + "</td></tr>");
+         }
+
+         out.println("</table>");
+
+         out.println("</td></tr>");
+
+      }
+
+      out.println("</table>");
+
+      out.println("Replicator's Information");
+
+      out.println("<table border=1><tr><td>Node</td><td>Key</td><td>Value</td></tr>");
+
+      for (Iterator iter = replicatedData.entrySet().iterator(); iter.hasNext();)
+      {
+         Map.Entry entry = (Map.Entry) iter.next();
+         Map subMap = (Map)entry.getValue();
+
+         for (Iterator subIterator = subMap.entrySet().iterator(); subIterator.hasNext();)
+         {
+            Map.Entry subValue = (Map.Entry) subIterator.next();
+            out.println("<tr><td>" + entry.getKey() + "</td>");
+            out.println("<td>" + subValue.getKey() + "</td><td>" + subValue.getValue() + "</td></tr>" );
+         }
+
+      }
+
+      out.println("</table>");
+
+
+      out.println("View Information");
+
+      out.println("<table border=1><tr><td>Members</td></tr>");
+
+
+      for (Iterator iterMembers = currentView.getMembers().iterator(); iterMembers.hasNext();)
+      {
+         Address address = (Address) iterMembers.next();
+         out.println("<tr><td>" + address + "</td></tr>");
+      }
+
+      out.println("</table>");
+
+      return buffer.toString();
+   }
+
+   /**
+    * MUST ONLY be used for testing!
+    */
    public void setFail(boolean beforeCommit, boolean afterCommit, boolean handleResult)
    {
       this.failBeforeCommit = beforeCommit;
       this.failAfterCommit = afterCommit;
       this.failHandleResult = handleResult;
    }
-   
-   //Used for testing only
+
+   /**
+    * MUST ONLY be used for testing!
+    */
    public Collection getHoldingTransactions()
    {
       return holdingArea.values();
    }
-     
-   // Protected ---------------------------------------------------------------------------------------
-        
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void addToNameMap(Binding binding)
+   {
+      if (!binding.isFailed())
+      {
+         super.addToNameMap(binding);
+      }
+      else
+      {
+         addIntoFailedMaps(binding);
+      }
+   }
+
    protected void addToConditionMap(Binding binding)
    {
-      String condition = binding.getCondition();
-      
+      Condition condition = binding.getCondition();
+
       ClusteredBindings bindings = (ClusteredBindings)conditionMap.get(condition);
-      
+
       if (bindings == null)
       {
-         bindings = new DefaultClusteredBindings(nodeId);
-         
+         bindings = new DefaultClusteredBindings(currentNodeId);
+
          conditionMap.put(condition, bindings);
       }
-      
+
       bindings.addBinding(binding);
-      
+
       String queueName = binding.getQueue().getName();
-      
+
       ClusterRouter router = (ClusterRouter)routerMap.get(queueName);
-      
+
       if (router == null)
       {
          router = routerFactory.createRouter();
-         
+
          routerMap.put(queueName, router);
-         
+
          bindings.addRouter(queueName, router);
       }
-      
-      router.add(binding.getQueue());                
+
+      // todo: Maybe we should have isFailed as a property of Queue instead of Binding, so we won't need to change this signature.
+      router.add(binding.getQueue(),binding.isFailed());
    }
 
    protected void removeFromConditionMap(Binding binding)
    {
       ClusteredBindings bindings = (ClusteredBindings)conditionMap.get(binding.getCondition());
-      
+
       if (bindings == null)
       {
          throw new IllegalStateException("Cannot find condition bindings for " + binding.getCondition());
       }
-      
+
       boolean removed = bindings.removeBinding(binding);
-      
+
       if (!removed)
       {
          throw new IllegalStateException("Cannot find binding in condition binding list");
-      }           
-      
+      }
+
       if (bindings.isEmpty())
       {
          conditionMap.remove(binding.getCondition());
-      }        
-      
+      }
+
       String queueName = binding.getQueue().getName();
-      
+
       ClusterRouter router = (ClusterRouter)routerMap.get(queueName);
-      
+
       if (router == null)
       {
          throw new IllegalStateException("Cannot find router with name " + queueName);
       }
-      
+
       removed = router.remove(binding.getQueue());
-      
+
       if (!removed)
       {
          throw new IllegalStateException("Cannot find router in map");
       }
-      
+
       if (router.getQueues().isEmpty())
       {
          routerMap.remove(queueName);
-      }      
+      }
    }
 
    protected void loadBindings() throws Exception
    {
-      if (trace) { log.trace(this.nodeId + " loading bindings"); }
-      
+      if (trace) { log.trace(this + " loading bindings"); }
+
       boolean isState = syncChannel.getState(null, stateTimeout);
-                              
+
       if (!isState)
-      {       
+      {
          //Must be first member in group or non clustered- we load the state ourself from the database
-         
-         if (trace) { log.trace(this.nodeId + " First member of group- so loading bindings from db"); }
-         
-         super.loadBindings();      
+
+         if (trace) { log.trace(this + " is the first member of group, so will load bindings from database"); }
+
+         super.loadBindings();
       }
       else
       {
          //The state will be set in due course via the MessageListener - we must wait until this happens
-         
-         if (trace) { log.trace(this.nodeId + " Not first member of group- so waiting for state to arrive...."); }
-         
-         synchronized (setStateLock)
+
+         if (trace) { log.trace(this.currentNodeId + " Not first member of group- so waiting for state to arrive...."); }
+
+      synchronized (setStateLock)
+      {
+         //TODO we should implement a timeout on this
+         while (!stateSet)
          {
-            //TODO we should implement a timeout on this
-            while (!stateSet)
-            {
-               setStateLock.wait();
-            } 
+            setStateLock.wait();
          }
-         
-         if (trace) { log.trace(this.nodeId + " Received state"); }
       }
+
+         if (trace) { log.trace(this.currentNodeId + " Received state"); }
+      }
    }
-   
-   protected Binding createBinding(int nodeId, String condition, String queueName, long channelId, String filterString, boolean durable) throws Exception
-   {            
-      Filter filter = filterFactory.createFilter(filterString);
-         
+
+   protected Binding createBinding(int nodeId, Condition condition, String queueName, long channelId, Filter filter, boolean durable, boolean failed)
+   {
       Queue queue;
-      if (nodeId == this.nodeId)
+      if (nodeId == this.currentNodeId)
       {
          QueuedExecutor executor = (QueuedExecutor)pool.get();
-         
+
          queue = new LocalClusteredQueue(this, nodeId, queueName, channelId, ms, pm, true,
-                                         durable, executor, filter, tr);
+                  durable, executor, filter, tr);
       }
       else
       {
          queue = new RemoteQueueStub(nodeId, queueName, channelId, durable, pm, filter);
       }
-      
-      Binding binding = new DefaultBinding(nodeId, condition, queue);
-      
-      return binding;
+
+      return new DefaultBinding(nodeId, condition, queue, failed);
    }
-   
-    
-   // Private ------------------------------------------------------------------------------------------
-           
-   /*
-    * Multicast a sync request
-    */
-   private void syncSendRequest(ClusterRequest request) throws Exception
-   {         
-      if (trace) { log.trace(this.nodeId + " sending synch request to group, request: " + request); }
-      
-      byte[] bytes = writeRequest(request);
-            
-      Message message = new Message(null, null, bytes);      
-      
-      controlMessageDispatcher.castMessage(null, message, GroupRequest.GET_ALL, castTimeout);
-      
-      if (trace) { log.trace(this.nodeId + " sent and executed ok"); }
+
+   // Private -------------------------------------------------------
+
+   private void sendBindRequest(Condition condition, LocalClusteredQueue queue, Binding binding)
+      throws Exception
+   {
+      BindRequest request =
+         new BindRequest(this.currentNodeId, queue.getName(), condition.toText(), queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
+                         binding.getQueue().getChannelID(), queue.isRecoverable(), binding.isFailed());
+
+      syncSendRequest(request);
    }
-   
 
-   private Integer getNodeIdForSyncAddress(Address address) throws Exception
+   private boolean leaveMessageReceived(Integer nodeId) throws Exception
    {
-      lock.readLock().acquire();
-      try
-      { 
-         Iterator iter = nodeIdAddressesMap.entrySet().iterator();
-         
-         Integer nodeId = null;
-         while (iter.hasNext())
-         {
-            Map.Entry entry = (Map.Entry)iter.next();
-            
-            NodeAddressInfo info = (NodeAddressInfo)entry.getValue();
-            
-            if (info.getSyncChannelAddress().equals(address))
-            {
-               nodeId = (Integer)entry.getKey();
-            }
-         }
-         return nodeId;
-      }
-      finally
+      synchronized (leftSet)
       {
-         lock.readLock().release();
+         return leftSet.remove(nodeId);
       }
    }
-       
-   private void removeBindingsForAddress(Integer nodeId) throws Exception
+
+   /*
+    * Removes all non durable binding data, and any local replicant data for the specified node.
+    */
+   private void removeDataForNode(Integer nodeToRemove) throws Exception
    {
+      log.info("Node " + nodeToRemove + " requested to leave cluster");
+
       lock.writeLock().acquire();
 
       try
-      {          
-         Map nameMap = (Map)nameMaps.get(nodeId);
+      {
+         Map nameMap = (Map)nameMaps.get(nodeToRemove);
 
          if (nameMap != null)
          {
             List toRemove = new ArrayList();
-            
+
             Iterator iter = nameMap.values().iterator();
-            
+
             while (iter.hasNext())
             {
                Binding binding = (Binding)iter.next();
-               
+
                if (!binding.getQueue().isRecoverable())
                {
                   //We only remove the non durable bindings - we still need to be able to handle
@@ -1294,137 +1728,317 @@
                   toRemove.add(binding);
                }
             }
-            
+
             iter = toRemove.iterator();
-            
+
             while (iter.hasNext())
             {
                Binding binding = (Binding)iter.next();
-               
-               removeBinding(nodeId.intValue(), binding.getQueue().getName());
+
+               removeBinding(nodeToRemove.intValue(), binding.getQueue().getName());
             }
          }
-         
-         //Remove the address mapping
-         nodeIdAddressesMap.remove(nodeId);
       }
       finally
       {
          lock.writeLock().release();
       }
+
+      synchronized (replicatedData)
+      {
+         // We need to remove any replicant data for the node. This includes the node-address info.
+         for(Iterator i = replicatedData.entrySet().iterator(); i.hasNext(); )
+         {
+            Map.Entry entry = (Map.Entry)i.next();
+
+            String key = (String)entry.getKey();
+            Map replicants = (Map)entry.getValue();
+
+            replicants.remove(nodeToRemove);
+
+            if (replicants.isEmpty())
+            {
+               i.remove();
+            }
+
+            // Need to trigger listeners
+            notifyListeners(key, replicants, false, nodeToRemove.intValue());
+         }
+      }
    }
-      
+
+   /**
+    * @param updatedReplicantMap - the updated replicant map. It contains ALL current replicants for
+    *        the given key.
+    */
+   private void notifyListeners(Serializable key, Map updatedReplicantMap, boolean added,
+                                int originatorNodeId)
+   {
+      synchronized (replicationListeners)
+      {
+         for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
+         {
+            ReplicationListener listener = (ReplicationListener)i.next();
+
+            listener.onReplicationChange(key, updatedReplicantMap, added, originatorNodeId);
+         }
+      }
+   }
+
+   /*
+    * Multicast a sync request
+    */
+   private void syncSendRequest(ClusterRequest request) throws Exception
+   {
+      if (trace) { log.trace(this + " sending synch request " + request); }
+
+      byte[] bytes = writeRequest(request);
+
+      Message message = new Message(null, null, bytes);
+
+      controlMessageDispatcher.castMessage(null, message, GroupRequest.GET_ALL, castTimeout);
+
+      if (trace) { log.trace(this + " request sent OK"); }
+   }
+
+   //DEBUG ONLY - remove this
+   private void dumpNodeIdAddressMap(Map map) throws Exception
+   {
+      log.info("** DUMPING NODE ADDRESS MAPPING");
+
+      Iterator iter = map.entrySet().iterator();
+
+      while (iter.hasNext())
+      {
+         Map.Entry entry = (Map.Entry)iter.next();
+
+         Integer theNodeId = (Integer)entry.getKey();
+
+         PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
+
+         log.info("node id: " + theNodeId +" --------->(async:sync) " + info.getAsyncChannelAddress() + ":" + info.getSyncChannelAddress());
+      }
+
+      log.info("** END DUMP");
+   }
+
+
+   //TODO - this is a bit tortuous - needs optimising
+   private Integer getNodeIdForSyncAddress(Address address) throws Exception
+   {
+      synchronized (replicatedData)
+      {
+         Map map = get(ADDRESS_INFO_KEY);
+
+         if (map == null)
+         {
+            throw new IllegalStateException("Cannot find node id -> address mapping");
+         }
+
+         this.dumpNodeIdAddressMap(map);
+
+         Iterator iter = map.entrySet().iterator();
+
+         log.info("iterating, looking for " + address);
+
+         Integer theNodeId = null;
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+
+            PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
+
+            log.info("info synch channel address: " + info.getSyncChannelAddress());
+
+            if (info.getSyncChannelAddress().equals(address))
+            {
+               log.info("equal");
+               theNodeId = (Integer)entry.getKey();
+               break;
+            }
+            else
+            {
+               log.info("Not equal");
+            }
+         }
+         return theNodeId;
+      }
+   }
+
+   private boolean knowAboutNodeId(int nodeId)
+   {
+      //The nodeid->Address info mapping is stored in the replicated data
+
+      synchronized (replicatedData)
+      {
+         Map nodeIdAddressMapping = (Map)replicatedData.get(ADDRESS_INFO_KEY);
+
+         if (nodeIdAddressMapping == null)
+         {
+            return false;
+         }
+         else
+         {
+            Object obj = nodeIdAddressMapping.get(new Integer(nodeId));
+
+            return obj != null;
+         }
+      }
+   }
+
    private byte[] getStateAsBytes() throws Exception
    {
       List bindings = new ArrayList();
-      
+
       Iterator iter = nameMaps.values().iterator();
-      
+
       while (iter.hasNext())
       {
          Map map  = (Map)iter.next();
-         
+
          Iterator iter2 = map.values().iterator();
-         
+
          while (iter2.hasNext())
          {
             Binding binding = (Binding)iter2.next();
-                      
-            Queue queue = binding.getQueue();        
-            
+
+            Queue queue = binding.getQueue();
+
             BindingInfo info = new BindingInfo(binding.getNodeId(), queue.getName(),
-                                               binding.getCondition(),
+                                               binding.getCondition().toText(),
                                                queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
                                                queue.getChannelID(),
-                                               queue.isRecoverable());    
+                                               queue.isRecoverable(),
+                                               binding.isFailed());
             bindings.add(info);
          }
       }
-      
-      SharedState state = new SharedState(bindings, nodeIdAddressesMap);
-      
-      byte[] bytes = StreamUtils.toBytes(state); 
-           
-      return bytes;
+
+      //Need to copy
+
+      Map copy;
+
+      synchronized (replicatedData)
+      {
+         copy = copyReplicatedData(replicatedData);
+      }
+
+      SharedState state = new SharedState(bindings, copy);
+
+      return StreamUtils.toBytes(state);
    }
-   
+
    private void processStateBytes(byte[] bytes) throws Exception
    {
-      if (trace) { log.trace(this.nodeId + " received state from group"); }
-      
+      if (trace) { log.trace(this + " received state from group"); }
+
       SharedState state = new SharedState();
-      
+
       StreamUtils.fromBytes(state, bytes);
-      
-      if (trace) { log.trace(this.nodeId + " received " + state.getBindings().size() + " bindings and map " + state.getNodeIdAddressMap()); }
-      
+
+      if (trace) { log.trace(this + " received " + state.getBindings().size() + " bindings and map " + state.getReplicatedData()); }
+
       nameMaps.clear();
-      
+
       conditionMap.clear();
-                 
+
       List bindings = state.getBindings();
-      
+
       Iterator iter = bindings.iterator();
-      
+
       while (iter.hasNext())
       {
          BindingInfo info = (BindingInfo)iter.next();
-         
-         Binding binding = this.createBinding(info.getNodeId(), info.getCondition(), info.getQueueName(), info.getChannelId(), info.getFilterString(), info.isDurable());
-         
-         if (binding.getNodeId() == this.nodeId)
+
+         Condition condition = conditionFactory.createCondition(info.getConditionText());
+
+         Binding binding = this.createBinding(info.getNodeId(), condition, info.getQueueName(), info.getChannelId(),
+                                              info.getFilterString(), info.isDurable(),info.isFailed());
+
+         if (binding.getNodeId() == this.currentNodeId)
          {
             //We deactivate if this is one of our own bindings - it can only
             //be one of our own durable bindings - and since state is retrieved before we are fully started
             //then the sub hasn't been deployed so must be deactivated
-            
-            binding.getQueue().deactivate();            
+
+            binding.getQueue().deactivate();
          }
-            
-         addBinding(binding);         
+
+         addBinding(binding);
       }
-      
-      this.nodeIdAddressesMap.clear();
-      
-      this.nodeIdAddressesMap.putAll(state.getNodeIdAddressMap());
+
+      //Update the replicated data
+
+      synchronized (replicatedData)
+      {
+         replicatedData = copyReplicatedData(state.getReplicatedData());
+      }
    }
-   
-   
-   
+
+   private Map copyReplicatedData(Map toCopy)
+   {
+      Map copy = new HashMap();
+
+      Iterator iter = toCopy.entrySet().iterator();
+
+      while (iter.hasNext())
+      {
+         Map.Entry entry = (Map.Entry)iter.next();
+
+         Serializable key = (Serializable)entry.getKey();
+
+         Map replicants = (Map)entry.getValue();
+
+         Map m = new LinkedHashMap();
+
+         m.putAll(replicants);
+
+         copy.put(key, m);
+      }
+
+      return copy;
+   }
+
+
    private byte[] writeRequest(ClusterRequest request) throws Exception
    {
       ByteArrayOutputStream baos = new ByteArrayOutputStream(2048);
-      
+
       DataOutputStream daos = new DataOutputStream(baos);
-      
+
       ClusterRequest.writeToStream(daos, request);
-            
+
       daos.flush();
-      
+
       return baos.toByteArray();
    }
-   
+
    private ClusterRequest readRequest(byte[] bytes) throws Exception
    {
       ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
-      
+
       DataInputStream dais = new DataInputStream(bais);
-      
+
       ClusterRequest request = ClusterRequest.createFromStream(dais);
-      
+
       dais.close();
-      
-      return request;            
+
+      return request;
    }
-   
+
    private Address getAddressForNodeId(int nodeId, boolean sync) throws Exception
-   {  
-      lock.readLock().acquire();
+   {
+      synchronized (replicatedData)
+      {
+         Map map = this.get(ADDRESS_INFO_KEY);
 
-      try
-      {
-         NodeAddressInfo info = (NodeAddressInfo)nodeIdAddressesMap.get(new Integer(nodeId));
-         
+         if (map == null)
+         {
+            throw new IllegalStateException("Cannot find address mapping");
+         }
+
+         PostOfficeAddressInfo info = (PostOfficeAddressInfo)map.get(new Integer(nodeId));
+
          if (info != null)
          {
             if (sync)
@@ -1441,21 +2055,357 @@
             return null;
          }
       }
+   }
+   /*
+    * A new node has joined the group
+    */
+   private void nodeJoined(Address address) throws Exception
+   {
+      if (trace) { log.trace(this + ": " + address + " joined"); }
+
+      log.info(this.currentNodeId + " Node with address: " + address + " joined");
+
+      //Currently does nothing
+   }
+
+   /*
+    * A node has left the group
+    */
+   private void nodeLeft(Address address) throws Throwable
+   {
+      if (trace) { log.trace(this + ": " + address + " left"); }
+
+      log.info(this.currentNodeId + " Node with address: " + address + " left");
+
+      Integer theNodeId = getNodeIdForSyncAddress(address);
+
+      if (theNodeId == null)
+      {
+         throw new IllegalStateException(this.currentNodeId + " Cannot find node id for address " + address);
+      }
+
+      boolean crashed = !this.leaveMessageReceived(theNodeId);
+
+      if (trace) { log.trace("Node " + address + " id: " + theNodeId +" has left the group, crashed = " + crashed); }
+
+      //Cleanup any hanging transactions - we do this irrespective of whether we crashed
+      check(theNodeId);
+
+      synchronized (failoverMap)
+      {
+         //Need to evaluate this before we regenerate the failover map
+         Integer failoverNode = (Integer)failoverMap.get(theNodeId);
+
+         if (failoverNode == null)
+         {
+            throw new IllegalStateException("Cannot find failover node for node " + theNodeId);
+         }
+
+         //debug dump failover map
+
+         Iterator iter = failoverMap.entrySet().iterator();
+
+         log.info("Dumping failover map");
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+
+            Integer nodeId = (Integer)entry.getKey();
+
+            Integer failoverNodeId = (Integer)entry.getValue();
+
+            log.info("node->failover node: " + nodeId + " --> " + failoverNodeId);
+         }
+         log.info("end dump");
+
+         //end debug
+
+         boolean isFailover = failoverNode.intValue() == this.currentNodeId;
+
+         log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
+
+         log.info("Crashed: " + crashed);
+
+         //Remove any replicant data and non durable bindings for the node - again we need to do this
+         //irrespective of whether we crashed
+         //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
+         removeDataForNode(theNodeId);
+
+         if (crashed && isFailover)
+         {
+            //The node crashed and we are the failover node
+            //so let's perform failover
+
+            //TODO server side valve
+
+            failOver(theNodeId.intValue());
+         }
+      }
+   }
+
+   /**
+    *  Verifies changes on the View deciding if a node joined or left the cluster.
+    */
+   private void verifyMembership(View oldView, View newView) throws Throwable
+   {
+      if (oldView != null)
+      {
+         for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+         {
+            Address address = (Address)i.next();
+            if (!newView.containsMember(address))
+            {
+               nodeLeft(address);
+            }
+         }
+      }
+
+      for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+      {
+         Address address = (Address)i.next();
+         if (oldView == null || !oldView.containsMember(address))
+         {
+            nodeJoined(address);
+         }
+      }
+   }
+
+   /**
+    * This method fails over all the queues from node <failedNodeId> onto this node
+    * It is triggered when a JGroups view change occurs due to a member leaving and
+    * it's determined the member didn't leave cleanly
+    *
+    * @param failedNodeId
+    * @throws Exception
+    */
+   private void failOver(int failedNodeId) throws Exception
+   {
+      //Need to lock
+      lock.writeLock().acquire();
+
+      try
+      {
+         log.info(this.currentNodeId + " is performing failover for node " + failedNodeId);
+
+         /*
+         We make sure a FailoverStatus object is put in the replicated data for the node
+         The real failover node will always add this in.
+         This means that each node knows which node has really started the failover for another node, and
+         which node did failover for other nodes in the past
+         We cannot rely on the failoverMap for this, since that will regenerated once failover is done,
+         because of the change in membership.
+         And clients may failover after that and need to know if they have the correct node.
+         Since this is the first thing we do after detecting failover, it should be very quick that
+         all nodes know, however there is still a chance that a client tries to failover before
+         the information is replicated.
+         */
+
+         Map replicants = (Map)get(FAILED_OVER_FOR_KEY);
+
+         FailoverStatus status = (FailoverStatus)replicants.get(new Integer(currentNodeId));
+
+         if (status == null)
+         {
+            status = new FailoverStatus();
+         }
+
+         status.startFailingOverForNode(failedNodeId);
+
+         log.info("Putting state that failover is starting");
+
+         put(FAILED_OVER_FOR_KEY, status);
+
+         log.info("Put state that failover is starting");
+
+         //Get the map of queues for the failed node
+
+         Map subMaps = (Map)nameMaps.get(new Integer(failedNodeId));
+         if (subMaps==null || subMaps.size()==0)
+         {
+            log.warn("Couldn't find any binding to failOver from serverId=" +failedNodeId);
+            return;
+         }
+
+         //Compile a list of the queue names to remove
+         //Note that any non durable bindings will already have been removed (in removeDataForNode()) when the
+         //node leave was detected, so if there are any non durable bindings left here then
+         //this is an error
+
+         //We iterate through twice to avoid ConcurrentModificationException
+         ArrayList namesToRemove = new ArrayList();
+         for (Iterator iterNames = subMaps.entrySet().iterator(); iterNames.hasNext();)
+         {
+            Map.Entry entry = (Map.Entry)iterNames.next();
+
+            Binding binding = (Binding )entry.getValue();
+
+            //Sanity check
+            if (!binding.getQueue().isRecoverable())
+            {
+               throw new IllegalStateException("Find non recoverable queue in map, these should have been removed!");
+            }
+
+            //Sanity check
+            if (!binding.getQueue().isClustered())
+            {
+               throw new IllegalStateException("Queue is not clustered!: " + binding.getQueue().getName());
+            }
+
+            ClusteredQueue queue = (ClusteredQueue) binding.getQueue();
+
+            //Sanity check
+            if (queue.isLocal())
+            {
+               throw new IllegalStateException("Queue is local!: " + binding.getQueue().getName());
+            }
+            namesToRemove.add(entry);
+         }
+
+         log.info("Deleting " + namesToRemove.size() + " bindings from old node");
+
+         for (Iterator iterNames = namesToRemove.iterator(); iterNames.hasNext();)
+         {
+            Map.Entry entry = (Map.Entry)iterNames.next();
+
+            Binding binding = (Binding)entry.getValue();
+
+            RemoteQueueStub stub = (RemoteQueueStub)binding.getQueue();
+
+            String queueName = (String)entry.getKey();
+
+            //First the binding is removed from the in memory condition and name maps
+            this.removeBinding(failedNodeId, queueName);
+
+            //Then deleted from the database
+            this.deleteBinding(failedNodeId, queueName);
+
+            log.info("deleted binding for " + queueName);
+
+            //Note we do not need to send an unbind request across the cluster - this is because
+            //when the node crashes a view change will hit the other nodes and that will cause
+            //all binding data for that node to be removed anyway
+
+            //If there is already a queue registered with the same name, then we set a flag "failed" on the
+            //binding and then the queue will go into a special list of failed bindings
+            //otherwise we treat at as a normal queue
+            //This is because we cannot deal with more than one queue with the same name
+            //Any new consumers will always only connect to queues in the main name map
+            //This may mean that queues in the failed map have messages stranded in them if consumers
+            //disconnect (since no more can reconnect)
+            //However we message redistribution activated other queues will be able to consume from them.
+            //TODO allow message redistribution for queues in the failed list
+            boolean failed = this.internalGetBindingForQueueName(queueName) != null;
+
+            if (!failed)
+            {
+               log.info("The current node didn't have a queue " + queueName + " so it's assuming the queue as a regular queue");
+            }
+            else
+            {
+               log.info("There is already a queue with that name so adding to failed map");
+            }
+
+            //Create a new binding
+            Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
+                                                    stub.getName(), stub.getChannelID(),
+                                                    stub.getFilter(), stub.isRecoverable(), failed);
+
+            log.info("Created new binding");
+
+            //Insert it into the database
+            insertBinding(newBinding);
+
+            LocalClusteredQueue clusteredQueue = (LocalClusteredQueue )newBinding.getQueue();
+
+            clusteredQueue.deactivate();
+            clusteredQueue.load();
+            clusteredQueue.activate();
+
+            log.info("Loaded queue");
+
+            //Add the new binding in memory
+            addBinding(newBinding);
+
+            //Send a bind request so other nodes add it too
+            sendBindRequest(binding.getCondition(), clusteredQueue,newBinding);
+
+            //FIXME there is a problem in the above code.
+            //If the server crashes between deleting the binding from the database
+            //and creating the new binding in the database, then the binding will be completely
+            //lost from the database when the server is resurrected.
+            //To remedy, both db operations need to be done in the same JBDC tx
+         }
+
+         log.info("Server side fail over is now complete");
+
+         //TODO - should this be in a finally? I'm not sure
+         status.finishFailingOver();
+
+         log.info("Putting state that failover has completed");
+         put(FAILED_OVER_FOR_KEY, status);
+         log.info("Put state that failover has completed");
+      }
       finally
       {
-         lock.readLock().release();      
+         lock.writeLock().release();
       }
    }
-   
+
+   private void addIntoFailedMaps(Binding binding)
+   {
+      Map channelMap = (Map)failedBindings.get(new Integer(binding.getNodeId()));
+
+      if (channelMap == null)
+      {
+         channelMap = new LinkedHashMap();
+
+         failedBindings.put(new Integer(binding.getNodeId()), channelMap);
+      }
+
+      channelMap.put(new Long(binding.getQueue().getChannelID()), binding);
+   }
+
+   private void sendJMXNotification(String notificationType)
+   {
+      Notification n = new Notification(notificationType, "", 0l);
+      nbSupport.sendNotification(n);
+   }
+
+   private void handleViewAccepted(View newView)
+   {
+      //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
+      //TODO:     can't we do the same since this is pretty useful?
+      log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
+               + DefaultClusteredPostOffice.this.getOfficeName());
+
+      // JGroups will make sure this method is never called by more than one thread concurrently
+
+      View oldView = currentView;
+      currentView = newView;
+
+      try
+      {
+         verifyMembership(oldView, newView);
+         sendJMXNotification(VIEW_CHANGED_NOTIFICATION);
+      }
+      catch (Throwable e)
+      {
+         log.error("Caught Exception in MembershipListener", e);
+         IllegalStateException e2 = new IllegalStateException(e.getMessage());
+         e2.setStackTrace(e.getStackTrace());
+         throw e2;
+      }
+   }
+
    // Inner classes -------------------------------------------------------------------
-    
+
    /*
     * This class is used to manage state on the control channel
     */
    private class ControlMessageListener implements MessageListener
    {
       public byte[] getState()
-      {     
+      {
          try
          {
             lock.writeLock().acquire();
@@ -1466,6 +2416,8 @@
          }
          try
          {
+            // TODO: Make it trace
+            log.info("getState:" + DefaultClusteredPostOffice.this.getOfficeName());
             return getStateAsBytes();
          }
          catch (Exception e)
@@ -1474,25 +2426,24 @@
             IllegalStateException e2 = new IllegalStateException(e.getMessage());
             e2.setStackTrace(e.getStackTrace());
             throw e2;
-         }     
+         }
          finally
          {
             lock.writeLock().release();
          }
       }
-      
+
       public void receive(Message message)
-      {         
+      {
       }
-      
+
       public void setState(byte[] bytes)
-      { 
+      {
          if (bytes != null)
          {
-            
             try
             {
-               lock.writeLock().acquire();         
+               lock.writeLock().acquire();
             }
             catch (InterruptedException e)
             {
@@ -1500,7 +2451,9 @@
             }
             try
             {
-               processStateBytes(bytes);               
+               // TODO: Make it trace
+               log.info("setState:" + DefaultClusteredPostOffice.this.getOfficeName());
+               processStateBytes(bytes);
             }
             catch (Exception e)
             {
@@ -1514,15 +2467,15 @@
                lock.writeLock().release();
             }
          }
-               
+
          synchronized (setStateLock)
          {
             stateSet = true;
             setStateLock.notify();
          }
-      }      
+      }
    }
-   
+
    /*
     * We use this class so we notice when members leave the group
     */
@@ -1538,108 +2491,82 @@
          //NOOP
       }
 
-      public void viewAccepted(View view)
+      public void viewAccepted(View newView)
       {
-         if (trace) { log.trace(nodeId + " Got new view, size=" + view.size()); }
-         
-         if (currentView != null)
+         try
          {
-            Iterator iter = currentView.getMembers().iterator();
-            
-            while (iter.hasNext())
-            {
-               Address address = (Address)iter.next();
-               
-               if (!view.containsMember(address))
-               {
-                  //Member must have left                  
-                  //We don't remove bindings for ourself
-                  
-                  if (trace) { log.trace(nodeId + " it seems that member " + address + " has left the group"); }
-                  
-                  Address currentAddress = syncChannel.getLocalAddress();
-                  
-                  if (!address.equals(currentAddress))
-                  {                  
-                     try
-                     {
-                        Integer nodeId = getNodeIdForSyncAddress(address);
-                        
-                        if (nodeId == null)
-                        {
-                           throw new IllegalStateException("Cannot find node id for address: " + address);
-                        }
-                        
-                        if (trace) { log.trace(DefaultClusteredPostOffice.this.nodeId + " Performing cleanup for node " + nodeId); }
-                        
-                        //Perform a check - the member might have crashed and left uncommitted transactions
-                        //we need to resolve this
-                        check(nodeId);
-                                                                        
-                        removeBindingsForAddress(nodeId);
-                        
-                        if (trace) { log.trace(DefaultClusteredPostOffice.this.nodeId + " cleanup complete"); }
-                     }               
-                     catch (Throwable e)
-                     {
-                        log.error("Caught Exception in MembershipListener", e);
-                        IllegalStateException e2 = new IllegalStateException(e.getMessage());
-                        e2.setStackTrace(e.getStackTrace());
-                        throw e2;
-                     }
-                  }
-               }
-            }
+            // We queue up changes and execute them asynchronously.
+            // This is because JGroups will not let us do stuff like send synch messages using the
+            // same thread that delivered the view change and this is what we need to do in
+            // failover, for example.
+
+            viewExecutor.execute(new HandleViewAcceptedRunnable(newView));
          }
-         
-         currentView = view;
+         catch (InterruptedException e)
+         {
+            log.warn("Caught InterruptedException", e);
+         }
       }
 
       public byte[] getState()
-      {        
+      {
          //NOOP
          return null;
-      }     
+      }
    }
-   
-   
+
+   private class HandleViewAcceptedRunnable implements Runnable
+   {
+      private View newView;
+
+      HandleViewAcceptedRunnable(View newView)
+      {
+         this.newView = newView;
+      }
+
+      public void run()
+      {
+         handleViewAccepted(newView);
+      }
+   }
+
    /*
     * This class is used to listen for messages on the async channel
     */
    private class DataReceiver implements Receiver
    {
       public void block()
-      {   
+      {
          //NOOP
       }
 
       public void suspect(Address address)
-      { 
+      {
          //NOOP
       }
 
       public void viewAccepted(View view)
-      { 
+      {
          //NOOP
       }
 
       public byte[] getState()
-      {         
+      {
          //NOOP
          return null;
       }
-      
+
       public void receive(Message message)
       {
-         if (trace) { log.trace(nodeId + " received message " + message + " on async channel"); }
-         
+         if (trace) { log.trace(currentNodeId + " received message " + message + " on async channel"); }
+
          try
          {
             byte[] bytes = message.getBuffer();
-            
+
             ClusterRequest request = readRequest(bytes);
-            
-            request.execute(DefaultClusteredPostOffice.this);            
+
+            request.execute(DefaultClusteredPostOffice.this);
          }
          catch (Throwable e)
          {
@@ -1647,32 +2574,30 @@
             IllegalStateException e2 = new IllegalStateException(e.getMessage());
             e2.setStackTrace(e.getStackTrace());
             throw e2;
-         }         
+         }
       }
-      
+
       public void setState(byte[] bytes)
       {
-         //NOOP         
-      }      
+         //NOOP
+      }
    }
-          
+
    /*
     * This class is used to handle synchronous requests
     */
    private class PostOfficeRequestHandler implements RequestHandler
    {
       public Object handle(Message message)
-      {                
-         if (trace) { log.trace(nodeId + " received message " + message + " on sync channel"); }
+      {
+         if (trace) { log.info(currentNodeId + " received message " + message + " on sync channel"); }
          try
-         {   
+         {
             byte[] bytes = message.getBuffer();
-            
+
             ClusterRequest request = readRequest(bytes);
-            
-            Object result = request.execute(DefaultClusteredPostOffice.this);
-            
-            return result;
+
+            return request.execute(DefaultClusteredPostOffice.this);
          }
          catch (Throwable e)
          {
@@ -1680,7 +2605,43 @@
             IllegalStateException e2 = new IllegalStateException(e.getMessage());
             e2.setStackTrace(e.getStackTrace());
             throw e2;
-         }         
+         }
+      }
+   }
+
+   /*
+    * We use this class to respond to node address mappings being added or removed from the cluster
+    * and then recalculate the node->failover node mapping
+    *
+    */
+   private class NodeAddressMapListener implements ReplicationListener
+   {
+
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added,
+                                      int originatorNodeId)
+      {
+         if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
+         {
+            log.info(currentNodeId + " got node address change");
+
+            try
+            {
+               //DEBUG only
+               dumpNodeIdAddressMap(updatedReplicantMap);
+            }
+            catch (Exception ignore)
+            {
+            }
+
+            //A node-address mapping has been added/removed from global state-
+            //We need to update the failover map
+            generateFailoverMap(updatedReplicantMap);
+         }
+      }
+
+      private void generateFailoverMap(Map nodeAddressMap)
+      {
+         failoverMap = failoverMapper.generateMapping(nodeAddressMap.keySet());
       }      
    }
 }
\ No newline at end of file

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicy.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicy.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicy.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -41,7 +41,6 @@
 {
    private static final Logger log = Logger.getLogger(DefaultMessagePullPolicy.class);
    
-   
    public ClusteredQueue chooseQueue(List queues)
    {
       Iterator iter = queues.iterator();

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,6 +25,8 @@
 import java.util.Iterator;
 import java.util.List;
 
+import javax.jms.TextMessage;
+
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
@@ -54,21 +56,24 @@
       
    //MUST be an arraylist for fast index access
    private ArrayList nonLocalQueues;
-   
+
+   private ArrayList failedOverQueues;
+
    private ClusteredQueue localQueue;
-   
+
    private int target;
-   
+
    public DefaultRouter()
    {
       nonLocalQueues = new ArrayList();
+      failedOverQueues = new ArrayList();
    }
-   
+
    public int size()
    {
       return nonLocalQueues.size() + (localQueue == null ? 0 : 1);
    }
-   
+
    public ClusteredQueue getLocalQueue()
    {
       return localQueue;
@@ -76,30 +81,42 @@
 
    public boolean add(Receiver receiver)
    {
+      return add(receiver,false);
+   }
+
+   public boolean add(Receiver receiver, boolean failedOver)
+   {
       ClusteredQueue queue = (ClusteredQueue)receiver;
-      
+
       if (queue.isLocal())
       {
-         if (localQueue != null)
+         if (failedOver)
          {
-            throw new IllegalStateException("Already has local queue");
+            failedOverQueues.add(receiver);
          }
-         localQueue = queue;
+         else
+         {
+            if (localQueue != null)
+            {
+               throw new IllegalStateException("Already has local queue");
+            }
+            localQueue = queue;
+         }
       }
       else
       {
-         nonLocalQueues.add(queue); 
+         nonLocalQueues.add(queue);
       }
-      
+
       return true;
    }
 
    public void clear()
    {
       nonLocalQueues.clear();
-      
+
       localQueue = null;
-      
+
       target = 0;
    }
 
@@ -111,23 +128,23 @@
    public Iterator iterator()
    {
       List queues = new ArrayList();
-      
+
       if (localQueue != null)
       {
          queues.add(localQueue);
       }
-      
+
       queues.addAll(nonLocalQueues);
-      
+
       return queues.iterator();
    }
 
    public boolean remove(Receiver queue)
-   {      
+   {
       if (localQueue == queue)
       {
          localQueue = null;
-         
+
          return true;
       }
       else
@@ -144,75 +161,129 @@
          {
             return false;
          }
-      }      
+      }
    }
 
    public Delivery handle(DeliveryObserver observer, MessageReference reference, Transaction tx)
    {
       if (trace) { log.trace(this + " routing ref " + reference); }
-      
-      //Favour the local queue
-          
-      if (localQueue != null)
+
+      //Favour the local queue or the failedOver queue in round robin
+
+      if (!failedOverQueues.isEmpty())
       {
+         if (trace) { log.trace("Round robin on FailedOver queue, currentTarget=" + target);}
+         
+         LocalClusteredQueue queueToUse = null;
+
+         if (target == -1)
+         {
+            queueToUse = (LocalClusteredQueue)this.localQueue; 
+         }
+         else
+         {
+            queueToUse = (LocalClusteredQueue)failedOverQueues.get(target);
+         }
+
+         incTargetFailedOver();
+         
+         log.info("***************** Routing to failed over queue");
+         Delivery del = queueToUse.handle(observer, reference, tx);
+
+         if (trace) { log.trace(this+" routed to failed queue, using failedOver round robbing, returned " + del); }
+         
+         return del;
+      }
+      else if (localQueue != null)
+      {
          //The only time the local queue won't accept is if the selector doesn't
          //match - in which case it won't match at any other nodes too so no point
          //in trying them
          
+         //debug
+         try
+         {
+            TextMessage tm = (TextMessage)reference.getMessage();
+            
+            log.info("*********** Routing to local queue: " + tm.getText() + " id:" + System.identityHashCode(localQueue) );
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
+
          Delivery del = localQueue.handle(observer, reference, tx);
-         
+
          if (trace) { log.trace(this + " routed to local queue, it returned " + del); }
-         
+
          return del;
       }
       else
       {
-         //There is no local shared queue 
+         //There is no local shared queue
          //We round robin among the rest
-         
+
          if (!nonLocalQueues.isEmpty())
          {
             ClusteredQueue queue = (ClusteredQueue)nonLocalQueues.get(target);
-            
+
             queue = (ClusteredQueue)nonLocalQueues.get(target);
-            
+
+            log.info("************ Routing to non local queue");
             Delivery del = queue.handle(observer, reference, tx);
-             
+
             if (trace) { log.trace(this + " routed to remote queue, it returned " + del); }
-                        
+
             incTarget();
 
             //Again, if the selector doesn't match then it won't on any others so no point trying them
             return del;
-         }                  
+         }
       }
-      
+
       if (trace) { log.trace(this + " no queues to route to so return null"); }
-      
+
       return null;
    }
-   
+
+   private void incTargetFailedOver()
+   {
+      target++;
+
+      if (target == failedOverQueues.size())
+      {
+         target = -1; // use the local queue
+      }
+   }
+
+
    private void incTarget()
    {
       target++;
-      
+
       if (target == nonLocalQueues.size())
       {
          target = 0;
       }
    }
-   
+
+
+   public java.util.List getFailedQueues()
+   {
+      return failedOverQueues;
+   }
+
    public List getQueues()
    {
       List queues = new ArrayList();
-      
+
       if (localQueue != null)
       {
          queues.add(localQueue);
       }
-      
+
       queues.addAll(nonLocalQueues);
-      
+
       return queues;
    }
 

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java)

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LeaveClusterRequest.java)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,17 +21,9 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.Delivery;
-import org.jboss.messaging.core.Filter;
-import org.jboss.messaging.core.Message;
-import org.jboss.messaging.core.MessageReference;
-import org.jboss.messaging.core.SimpleDelivery;
+import org.jboss.messaging.core.*;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -40,8 +32,6 @@
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.Future;
 
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
  * 
  * A LocalClusteredQueue
@@ -141,6 +131,12 @@
    {
       return nodeId;
    }
+
+
+   public String toString()
+   {
+      return "LocalClusteredQueue[" + this.getChannelID() + "/" + this.getName() +"]"; 
+   }
    
    /*
     * This is the same as the normal handle() method on the Channel except it doesn't
@@ -152,6 +148,8 @@
    {
       if (trace) { log.trace("Handling ref from cluster: " + ref); }
       
+      log.info("********** Handling ref from cluster: " + ref);
+      
       if (filter != null && !filter.accept(ref))
       {
          Delivery del = new SimpleDelivery(this, ref, true, false);

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageHolder.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -41,7 +41,7 @@
  */
 class MessageHolder implements Streamable
 {
-   private String routingKey;
+   private String routingKeyText;
    
    private Message message;
    
@@ -51,9 +51,9 @@
    {      
    }
    
-   MessageHolder(String routingKey, Message message, Map queueNameToNodeIdMap)
+   MessageHolder(String routingKeyText, Message message, Map queueNameToNodeIdMap)
    {
-      this.routingKey = routingKey;
+      this.routingKeyText = routingKeyText;
       
       this.message = message;
       
@@ -62,7 +62,7 @@
    
    String getRoutingKey()
    {
-      return routingKey;
+      return routingKeyText;
    }
    
    Message getMessage()
@@ -77,7 +77,7 @@
 
    public void read(DataInputStream in) throws Exception
    {
-      routingKey = in.readUTF();
+      routingKeyText = in.readUTF();
       
       byte type = in.readByte();
         
@@ -89,7 +89,7 @@
 
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeUTF(routingKey);
+      out.writeUTF(routingKeyText);
       
       out.writeByte(message.getType());      
       message.write(out);

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/MessageRequest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -44,7 +44,7 @@
 {
    static final int TYPE = 3;
    
-   private String routingKey;   
+   private String routingConditionText;   
    
    private Message message;
    
@@ -54,9 +54,9 @@
    {      
    }
    
-   MessageRequest(String routingKey, Message message, Map queueNameNodeIdMap)
+   MessageRequest(String routingConditionText, Message message, Map queueNameNodeIdMap)
    {
-      this.routingKey = routingKey;
+      this.routingConditionText = routingConditionText;
       
       this.message = message;
       
@@ -65,7 +65,7 @@
    
    Object execute(PostOfficeInternal office) throws Exception
    {
-      office.routeFromCluster(message, routingKey, queueNameNodeIdMap);      
+      office.routeFromCluster(message, routingConditionText, queueNameNodeIdMap);      
       return null;
    }  
    
@@ -76,7 +76,7 @@
    
    public void read(DataInputStream in) throws Exception
    {
-      routingKey = in.readUTF();
+      routingConditionText = in.readUTF();
       
       byte type = in.readByte();
       message = MessageFactory.createMessage(type);
@@ -87,7 +87,7 @@
 
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeUTF(routingKey);
+      out.writeUTF(routingConditionText);
       
       out.writeByte(message.getType());      
       message.write(out);

Deleted: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/NodeAddressInfo.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/NodeAddressInfo.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/NodeAddressInfo.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,95 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.messaging.core.plugin.postoffice.cluster;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-
-import org.jboss.messaging.util.Streamable;
-import org.jgroups.Address;
-import org.jgroups.stack.IpAddress;
-
-/**
- * A NodeAddressInfo
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-class NodeAddressInfo implements Streamable
-{
-   private Address syncChannelAddress;
-   
-   private Address asyncChannelAddress;
-   
-   public NodeAddressInfo()
-   {     
-   }
-   
-   NodeAddressInfo(Address syncChannelAddress, Address asyncChannelAddress)
-   {
-      this.syncChannelAddress = syncChannelAddress;
-      
-      this.asyncChannelAddress = asyncChannelAddress;
-   }
-   
-   Address getSyncChannelAddress()
-   {
-      return syncChannelAddress;
-   }
-   
-   Address getAsyncChannelAddress()
-   {
-      return asyncChannelAddress;
-   }
-   
-   public void read(DataInputStream in) throws Exception
-   {
-      syncChannelAddress = new IpAddress();
-      
-      syncChannelAddress.readFrom(in);
-      
-      asyncChannelAddress = new IpAddress();
-      
-      asyncChannelAddress.readFrom(in);
-   }
-
-   public void write(DataOutputStream out) throws Exception
-   {
-      if (!(syncChannelAddress instanceof IpAddress))
-      {
-         throw new IllegalStateException("Address must be IpAddress");
-      }
-      
-      if (!(asyncChannelAddress instanceof IpAddress))
-      {
-         throw new IllegalStateException("Address must be IpAddress");
-      }
-      
-      syncChannelAddress.writeTo(out);
-      
-      asyncChannelAddress.writeTo(out);  
-   }
-
-}

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/Peer.java)

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeAddressInfo.java)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PostOfficeInternal.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,6 +21,7 @@
  */
 package org.jboss.messaging.core.plugin.postoffice.cluster;
 
+import java.io.Serializable;
 import java.util.List;
 import java.util.Map;
 
@@ -42,18 +43,21 @@
  */
 interface PostOfficeInternal extends ClusteredPostOffice
 {
-   void addBindingFromCluster(int nodeId, String queueName, String condition,
-                              String filterString, long channelId, boolean durable)
+   void addBindingFromCluster(int nodeId, String queueName, String conditionText,
+                              String filterString, long channelId, boolean durable, boolean failed)
       throws Exception;
    
    void removeBindingFromCluster(int nodeId, String queueName)
       throws Exception;
+ 
+   void handleNodeLeft(int nodeId) throws Exception;
    
-   void handleAddressNodeMapping(NodeAddressInfo info, int nodeId)
-      throws Exception;
+   void putReplicantLocally(int nodeId, Serializable key, Serializable replicant) throws Exception;
    
-   void routeFromCluster(Message message, String routingKey, Map queueNameNodeIdMap) throws Exception;
+   boolean removeReplicantLocally(int nodeId, Serializable key) throws Exception;
    
+   void routeFromCluster(Message message, String routingKeyText, Map queueNameNodeIdMap) throws Exception;
+   
    void asyncSendRequest(ClusterRequest request) throws Exception;
    
    void asyncSendRequest(ClusterRequest request, int nodeId) throws Exception;

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PullMessagesRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PullMessagesRequest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PullMessagesRequest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,8 +23,6 @@
 
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
-import java.util.Iterator;
-import java.util.List;
 
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/PutReplicantRequest.java)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -107,6 +107,8 @@
       {
          Delivery del = new SimpleDelivery(this, reference, false, false);
          
+         log.info("********** doesn't match filter");
+         
          return del;
       }
       
@@ -126,6 +128,8 @@
             return null;
          }
       }
+      
+      log.info("*********** accepting message:" + reference);
   
       return new SimpleDelivery(this, reference, false);      
    }
@@ -263,5 +267,9 @@
    {
       return true;
    }
-   
+
+   public String toString()
+   {
+      return "RemoteQueueStub(node=" + this.nodeId + " name=" + this.name + " channelId=" + this.id + ")";
+   }
 }

Copied: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoveReplicantRequest.java)

Deleted: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendNodeIdRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendNodeIdRequest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendNodeIdRequest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,83 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.messaging.core.plugin.postoffice.cluster;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-
-/**
- * A SendNodeIdRequest
- * 
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-class SendNodeIdRequest extends ClusterRequest
-{
-   static final int TYPE = 7;
-
-   private NodeAddressInfo info;
-   
-   private int nodeId;
-   
-   SendNodeIdRequest()
-   {      
-   }
-   
-   SendNodeIdRequest(NodeAddressInfo info, int nodeId)
-   {
-      this.info = info;
-      
-      this.nodeId = nodeId;      
-   }
-   
-   Object execute(PostOfficeInternal office) throws Exception
-   {
-      office.handleAddressNodeMapping(info, nodeId);
-      
-      return null;
-   }
-   
-   byte getType()
-   {
-      return TYPE;
-   }
-
-   public void read(DataInputStream in) throws Exception
-   {
-      info = new NodeAddressInfo();
-      
-      info.read(in);
-      
-      nodeId = in.readInt();
-   }
-
-   public void write(DataOutputStream out) throws Exception
-   {
-      info.write(out);
-      
-      out.writeInt(nodeId);   
-   }
-}

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SharedState.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SharedState.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SharedState.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,16 +23,21 @@
 
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
+import java.io.Serializable;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 
+import org.jboss.messaging.util.StreamUtils;
 import org.jboss.messaging.util.Streamable;
 
 /**
  * A SharedState
+ * 
+ * This encapsulates the shared state maintained across the cluster
+ * This comprise the bindings, and the arbitrary replicated data
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision: 1.1 $</tt>
@@ -44,17 +49,17 @@
 {  
    private List bindings;
    
-   private Map nodeIdAddressMap;
+   private Map replicatedData;
    
    SharedState()
    {      
    }
    
-   SharedState(List bindings, Map nodeIdAddressMap)
+   SharedState(List bindings, Map replicatedData)
    {
       this.bindings = bindings;
       
-      this.nodeIdAddressMap = nodeIdAddressMap;
+      this.replicatedData = replicatedData;
    }
    
    List getBindings()
@@ -62,42 +67,46 @@
       return bindings;
    }
    
-   Map getNodeIdAddressMap()
+   Map getReplicatedData()
    {
-      return nodeIdAddressMap;
+      return replicatedData;
    }
 
    public void read(DataInputStream in) throws Exception
    {
       int size = in.readInt();      
+      
       bindings = new ArrayList(size);
+      
       for (int i = 0; i < size; i++)
       {
          BindingInfo bb = new BindingInfo();
+         
          bb.read(in);
+         
          bindings.add(bb);
       }
       
       size = in.readInt();
       
-      nodeIdAddressMap = new HashMap(size);
+      replicatedData = new HashMap(size);
       
       for (int i = 0; i < size; i++)
       {
-         int nodeId = in.readInt();
+         Serializable key = (Serializable)StreamUtils.readObject(in, true);
          
-         NodeAddressInfo info = new NodeAddressInfo();
+         HashMap replicants = StreamUtils.readMap(in, false);
          
-         info.read(in);
-         
-         nodeIdAddressMap.put(new Integer(nodeId), info);
+         replicatedData.put(key, replicants);
       }
    }
 
    public void write(DataOutputStream out) throws Exception
    {
       out.writeInt(bindings.size());
+      
       Iterator iter = bindings.iterator();
+      
       while (iter.hasNext())
       {
          BindingInfo info = (BindingInfo)iter.next();
@@ -105,21 +114,21 @@
          info.write(out);
       }
       
-      out.writeInt(nodeIdAddressMap.size());
+      out.writeInt(replicatedData.size());
       
-      iter = nodeIdAddressMap.entrySet().iterator();
+      iter = replicatedData.entrySet().iterator();
       
       while (iter.hasNext())
       {
          Map.Entry entry = (Map.Entry)iter.next();
          
-         Integer nodeId = (Integer)entry.getKey();
+         Serializable key = (Serializable)entry.getKey();         
          
-         out.writeInt(nodeId.intValue());
+         StreamUtils.writeObject(out, key, true, true);
          
-         NodeAddressInfo info = (NodeAddressInfo)entry.getValue();
+         Map replicants = (Map)entry.getValue();
          
-         info.write(out);
+         StreamUtils.writeMap(out, replicants, false);
       }
    }
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/UnbindRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/UnbindRequest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/UnbindRequest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -54,6 +54,8 @@
 
    Object execute(PostOfficeInternal office) throws Exception
    {
+      // TODO: Due to failoever we can't guarantee unique key by nodeId and queueName any more.
+      // We might need to revist this
       office.removeBindingFromCluster(nodeId, queueName);
       
       return null;

Modified: trunk/tests/bin/.testrc.example
===================================================================
--- trunk/tests/bin/.testrc.example	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/bin/.testrc.example	2006-12-11 22:29:27 UTC (rev 1766)
@@ -13,15 +13,25 @@
 # (the database configuration definition MUST exist in tests/etc/container.xml)
 #
 TEST_DATABASE=hsqldb
+
 #
 # The transport to run tests with. Valid values: "socket", "http". The value specified here
 # overrides the value specified in container.xml.
 #
+
 TEST_REMOTING=socket
 
-
 #
+# Each test can be run in clustered or non-clustered mode. However, setting CLUSTERED to "true"
+# doesn't guarantee that the test will be actually run in clustered mode, the test database must
+# be also permitting sharing over a LAN. "mysql" allows this, "hsqldb" doesn't. The test will
+# quickly fail in such a situation.
+# It is also possible to configure a test to run in clustered mode by using the "-clustered"
+# switch.
 #
+CLUSTERED=true
+#
+#
 # util
 #
 #TARGET_CLASS=org.jboss.test.messaging.util.SelectiveIteratorTest

Modified: trunk/tests/bin/runtest
===================================================================
--- trunk/tests/bin/runtest	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/bin/runtest	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,6 +21,7 @@
 
 ENV_TEST_DATABASE=$TEST_DATABASE
 ENV_TEST_SERIALIZATION=$TEST_SERIALIZATION
+ENV_TEST_CLUSTERED=$TEST_CLUSTERED
 ENV_TEST_REMOTING=$TEST_REMOTING
 
 if [ -z "$TARGET_CLASS" -a -f $reldir/.testrc ]; then
@@ -39,6 +40,9 @@
 if [ "$ENV_TEST_SERIALIZATION" != "" ]; then
    TEST_SERIALIZATION=$ENV_TEST_SERIALIZATION
 fi
+if [ "$ENV_TEST_CLUSTERED" != "" ]; then
+   TEST_CLUSTERED=$ENV_TEST_CLUSTERED
+fi
 
 if [ "$ENV_TEST_REMOTING" != "" ]; then
    TEST_REMOTING=$ENV_TEST_REMOTING
@@ -51,7 +55,7 @@
 # it from there.
 #
 
-ant -Dtest.execution.classpath.file=bin/.test.execution.classpath -f $reldir/../build.xml get-test-execution-classpath
+ant -Dtest.execution.classpath.file=bin/.test.execution.classpath -f $reldir/../build.xml compile get-test-execution-classpath
 CLASSPATH=`cat $reldir/.test.execution.classpath`
 
 outputdir="$reldir/../output"
@@ -97,27 +101,83 @@
         REMOTE_TEST="-Dremote=true"
     fi
     if [ "$1" = "-remotedebug" ]; then
-        REMOTE_DEBUG_FLAG="-debug"
+        remote_debug=true
     fi
+    if [ "$1" = "0" -o "$1" = "1" -o "$1" = "2" ]; then
+        remote_debug_index=$1
+    fi
+    if [ "$1" = "-clustered" ]; then
+        TEST_CLUSTERED=true
+    fi
     shift
 done
 
-JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.remoting=$TEST_REMOTING -Dbuild.lib=../../output/lib"
+JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.clustered=$TEST_CLUSTERED -Dtest.remoting=$TEST_REMOTING -Dbuild.lib=../../output/lib"
 
 if [ "$TARGET_TEST" != "" ]; then
    TARGET_TEST="-t $TARGET_TEST"
 fi
 
+if [ "$remote_debug" = "true" ]; then
+   if [ "$remote_debug_index" = "" ]; then
+      REMOTE_DEBUG_FLAG_0="-debug"
+   elif [ "$remote_debug_index" = "1" ]; then
+      REMOTE_DEBUG_FLAG_1="-debug"
+   elif [ "$remote_debug_index" = "2" ]; then
+      REMOTE_DEBUG_FLAG_2="-debug"
+   elif [ "$remote_debug_index" = "3" ]; then
+      REMOTE_DEBUG_FLAG_3="-debug"
+   else
+      echo "Invalid argument: $remote_debug_index"
+      exit 1
+   fi
+fi
+
 if [ "$isRemote" = "true" ]; then
-  export TEST_DATABASE TEST_SERIALIZATION TEST_REMOTING
-  $reldir/start-rmi-server $REMOTE_DEBUG_FLAG -use-existent-test-classpath-file
+
+  export TEST_DATABASE TEST_SERIALIZATION TEST_CLUSTERED TEST_REMOTING
+
+  $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_0 -use-existent-test-classpath-file -index 0
+
+  if [ "$TEST_CLUSTERED" = "true" ]; then
+
+     # start the second remote server
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_1 -use-existent-test-classpath-file -index 1
+
+     # start the third remote server
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_2 -use-existent-test-classpath-file -index 2
+
+     # start the fourth remote server
+     $reldir/start-rmi-server $REMOTE_DEBUG_FLAG_3 -use-existent-test-classpath-file -index 3
+
+  fi
 fi
 
 
 $JAVA_HOME/bin/java $JAVA_OPTS -cp "$CLASSPATH" \
 org.jboss.test.messaging.tools.junit.SelectiveTestRunner $TARGET_CLASS $TARGET_TEST
 
+
+#
+# stop the servers in the reverse order
+#
+
 if [ "$isRemote" = "true" ]; then
-  $reldir/stop-rmi-server -use-existent-test-classpath-file
+
+    if [ "$TEST_CLUSTERED" = "true" ]; then
+
+       # stop the fourth remote server
+       $reldir/stop-rmi-server -use-existent-test-classpath-file -index 3
+
+       # stop the third remote server
+       $reldir/stop-rmi-server -use-existent-test-classpath-file -index 2
+
+       # stop the second remote server
+       $reldir/stop-rmi-server -use-existent-test-classpath-file -index 1
+
+    fi
+
+  $reldir/stop-rmi-server -use-existent-test-classpath-file -index 0
+
 fi
 

Modified: trunk/tests/bin/start-rmi-server
===================================================================
--- trunk/tests/bin/start-rmi-server	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/bin/start-rmi-server	2006-12-11 22:29:27 UTC (rev 1766)
@@ -20,22 +20,35 @@
     SEP=":"
 fi
 
+index=0
+
 while [ "$1" != "" ]; do
     if [ "$1" = "-debug" ]; then
-        if [ $cygwin = false ]; then
-            JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=12348"
-        else
-            JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=y,address=rmiserver"
-        fi
+         debug=true
+    elif [ "$1" = "-index" ]; then
+        shift
+        index=$1
     elif [ "$1" = "-use-existent-test-classpath-file" ]; then
         USE_EXISTENT_TEST_CLASSPATH_FILE=true;
     fi
     shift
 done
 
+echo
+echo "Starting remoting server $index ..."
+echo
+
+if [ "$debug" = true ]; then
+    if [ $cygwin = false ]; then
+        JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=12348"
+    else
+        JAVA_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=n,address=rmiserver_$index"
+    fi
+fi
+
 mkdir -p $reldir/../output/logs
 
-JAVA_OPTS="$JAVA_OPTS -Xmx768M -Dmodule.output=$reldir/../output -Dremote.test.suffix=-remote"
+JAVA_OPTS="$JAVA_OPTS -Xmx768M -Dmodule.output=$reldir/../output -Dremote.test.suffix=-remote-$index"
 
 if [ "$TEST_DATABASE" != "" ]; then
    JAVA_OPTS="$JAVA_OPTS -Dtest.database=$TEST_DATABASE"
@@ -45,11 +58,18 @@
    JAVA_OPTS="$JAVA_OPTS -Dtest.serialization=$TEST_SERIALIZATION"
 fi
 
+if [ "$TEST_CLUSTERED" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.clustered=$TEST_CLUSTERED"
+fi
+
+if [ "$index" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.server.index=$index"
+fi
+
 if [ "$TEST_REMOTING" != "" ]; then
    JAVA_OPTS="$JAVA_OPTS -Dtest.remoting=$TEST_REMOTING"
 fi
 
-
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
 else
@@ -68,4 +88,4 @@
 JAVA_OPTS="$JAVA_OPTS -Xmx768M"
 
 java $JAVA_OPTS -cp $CLASSPATH -Dtest.bind.address=localhost \
-org.jboss.test.messaging.tools.jmx.rmi.RMITestServer &
+org.jboss.test.messaging.tools.jmx.rmi.RMITestServer $port &

Modified: trunk/tests/bin/stop-rmi-server
===================================================================
--- trunk/tests/bin/stop-rmi-server	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/bin/stop-rmi-server	2006-12-11 22:29:27 UTC (rev 1766)
@@ -27,10 +27,17 @@
         fi
     elif [ "$1" = "-use-existent-test-classpath-file" ]; then
         USE_EXISTENT_TEST_CLASSPATH_FILE=true;
+    elif [ "$1" = "-index" ]; then
+        shift
+        index=$1
     fi
     shift
 done
 
+if [ "$index" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.server.index=$index"
+fi
+
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
 else

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/build.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -289,12 +289,13 @@
            description="Starts the RMI server used by clustering tests">
 
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
-         <sysproperty key="test.registry.index" value="${test.registry.index}"/>
+         <sysproperty key="test.server.index" value="${test.server.index}"/>
          <sysproperty key="module.output" value="${tests.output}"/>
-         <sysproperty key="remote.test.suffix" value="-remote"/>
+         <sysproperty key="remote.test.suffix" value="-remote-${test.server.index}"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${clustering.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.clustered" value="true"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=rmiserver"/>
          -->
@@ -328,7 +329,7 @@
            description="Stops the RMI server used by clustering tests">
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.StopRMIServer"
             classpathref="test.execution.classpath">
-         <sysproperty key="test.registry.index" value="${test.registry.index}"/>
+         <sysproperty key="test.server.index" value="${test.server.index}"/>
       </java>
    </target>
 
@@ -651,33 +652,54 @@
       <!-- Stop the rmi servers in case a previous run aborted -->
 
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="0"/>
+         <param name="test.server.index" value="3"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="1"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="2"/>
+         <param name="test.server.index" value="1"/>
       </antcall>
 
+      <antcall target="stop-rmi-server-clustering">
+         <param name="test.server.index" value="0"/>
+      </antcall>
+
+
+
       <!-- Start 3 rmi servers -->
 
       <antcall target="start-rmi-server-clustering">
-         <param name="test.registry.index" value="0"/>
+         <param name="test.server.index" value="0"/>
       </antcall>
+
       <antcall target="start-rmi-server-clustering">
-         <param name="test.registry.index" value="1"/>
+         <param name="test.server.index" value="1"/>
       </antcall>
+
       <antcall target="start-rmi-server-clustering">
-         <param name="test.registry.index" value="2"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
 
+      <antcall target="start-rmi-server-clustering">
+         <param name="test.server.index" value="3"/>
+      </antcall>
+
       <mkdir dir="${build.tests.reports}"/>
 
       <echo message=""/>
       <echo message="Running clustering tests, fork=${junit.fork}, junit.batchtest.fork=${junit.batchtest.fork}"/>
       <echo message=""/>
 
+      <!--
+
+           By default, clustered tests are run in a "remote" configuration (the clustered
+           nodes physically live in different VMs. If you want to test a co-located clustered
+           configuration, use bin/runtest -clustered
+      -->
+
       <junit printsummary="${junit.printsummary}"
              fork="${junit.fork}"
              includeantruntime="yes"
@@ -691,21 +713,23 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${clustering.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.clustered" value="true"/>
          <jvmarg value="-Xmx512M"/>
-         <!--
-         <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
-         -->
+
          <classpath>
             <path refid="test.execution.classpath"/>
-
-            <!-- Add this when http://jira.jboss.org/jira/browse/JBAS-2554 is done -->
             <!--
-            <path refid="jboss.test.classpath"/>
+                Add this when http://jira.jboss.org/jira/browse/JBAS-2554 is done
             -->
+            <!--
+                 <path refid="jboss.test.classpath"/>
+            -->
          </classpath>
 
-         <!-- Use this when http://jira.jboss.org/jira/browse/JBAS-2554 is done -->
          <!--
+              Use this when http://jira.jboss.org/jira/browse/JBAS-2554 is done
+         -->
+         <!--
          <sysproperty key="jboss-junit-configuration" value="Remote"/>
          <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter"
             usefile="${junit.formatter.usefile}" extension="-Remote.xml"/>
@@ -722,20 +746,33 @@
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
                <include name="**/jms/clustering/*Test.class"/>
+               <!--
+               <include name="**/jms/clustering/SimpleClusteringTest.class"/>
+               -->
             </fileset>
          </batchtest>
       </junit>
 
+      <!--
+          Stop the servers in the reverse order, so the VM that runs the RMI registry dies last.
+      -->
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="0"/>
+         <param name="test.server.index" value="3"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="1"/>
+         <param name="test.server.index" value="2"/>
       </antcall>
+
       <antcall target="stop-rmi-server-clustering">
-         <param name="test.registry.index" value="2"/>
+         <param name="test.server.index" value="1"/>
       </antcall>
 
+      <antcall target="stop-rmi-server-clustering">
+         <param name="test.server.index" value="0"/>
+      </antcall>
+
    </target>
 
 

Modified: trunk/tests/etc/container.xml
===================================================================
--- trunk/tests/etc/container.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/etc/container.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -73,6 +73,19 @@
    -->
    <remoting-transport>socket</remoting-transport>
 
+   <!--
+      Specifies whether to start a clustered messaging server or not. If "test.clustered" is set,
+      the value of the system property takes precedence. Supported values are "true" or "false".
+
+      Setting "clustered" to "true" doesn't guarantee that the test will be actually run in
+      clustered mode, the test database must be also permitting sharing over a LAN. "mysql" allows
+      this, "hsqldb" doesn't. The test will quickly fail in such a situation.
+   -->
+
+   <!--
+   <clustered>true</clustered>
+   -->
+
 </container>
 
 

Modified: trunk/tests/etc/log4j.xml
===================================================================
--- trunk/tests/etc/log4j.xml	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/etc/log4j.xml	2006-12-11 22:29:27 UTC (rev 1766)
@@ -37,9 +37,13 @@
    </category>
 
    <category name="org.jgroups">
-      <priority value="WARN"/>
+      <priority value="TRACE"/>
    </category>
 
+   <category name="org.jboss.remoting">
+         <priority value="TRACE"/>
+   </category>
+
    <category name="org.jboss">
       <priority value="INFO"/>
    </category>

Modified: trunk/tests/lib/README
===================================================================
--- trunk/tests/lib/README	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/lib/README	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1 +1,6 @@
-jms-ra.jar      JBoss 4.0.4.GA
\ No newline at end of file
+jms-ra.jar                     JBoss 4.0.4.GA
+jboss-jca.jar                  JBoss 4.0.4.GA
+jboss-common-jdbc-wrapper.jar  JBoss 4.0.4.GA
+jboss-local-jdbc.jar           JBoss 4.0.4.GA 
+
+

Modified: trunk/tests/lib/jboss-common-jdbc-wrapper.jar
===================================================================
(Binary files differ)

Modified: trunk/tests/lib/jboss-jca.jar
===================================================================
(Binary files differ)

Modified: trunk/tests/lib/jboss-local-jdbc.jar
===================================================================
(Binary files differ)

Copied: trunk/tests/src/org/jboss/test/messaging/core/SimpleCondition.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleCondition.java)

Copied: trunk/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleConditionFactory.java)

Copied: trunk/tests/src/org/jboss/test/messaging/core/ha (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha)

Deleted: trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,53 +0,0 @@
-package org.jboss.test.messaging.core.ha;
-
-import javax.jms.Destination;
-import javax.jms.MessageProducer;
-import javax.jms.Session;
-
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.JBossConnectionFactory;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.state.ConnectionState;
-
-/**
- * Start two JBoss instances (clustered) to run these tests.
- */
-public class ClusterecConnectionTest extends HATestBase
-{
-
-
-   public void setup() throws Exception
-   {
-      super.setUp("/HAConnectionFactory");
-   }
-
-   public void testSimpleConnection() throws Exception
-   {
-      JBossConnectionFactory factory = (JBossConnectionFactory)this.ctx1.lookup("/HAConnectionFactory");
-      JBossConnection conn = (JBossConnection) factory.createConnection();
-
-      ClusteredClientConnectionFactoryDelegate delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-      assertEquals(2,delegate.getDelegates().length);
-
-      Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-
-      for (int i=0;i<100;i++)
-      {
-         JBossConnection conn2 = (JBossConnection)factory.createConnection();
-         conn2.setClientID("client" + i);
-         conn2.start();
-         Session session = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageProducer producer = session.createProducer(destination); 
-         ConnectionState state = (ConnectionState) ((ClientConnectionDelegate)conn2.getDelegate()).getState();
-         log.info("state.serverId=" + state.getServerID());
-         //conn2.close();
-      }
-
-      System.out.println("****************** finish *********************");
-
-
-      Thread.sleep(120000);
-   }
-}

Copied: trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java)

Deleted: trunk/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,113 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.messaging.core.ha;
-
-import java.util.Properties;
-import javax.jms.ConnectionFactory;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import junit.framework.TestCase;
-import org.jboss.logging.Logger;
-
-/**
- * Define HOST1 and HOST2 as System variable (java -DHOST1=YourHost -DHOST2=YourHost2) pointing to a JBoss instance
- * with JBossMessaging installed.
- * This can usually be done using util scripts to deploy a JBoss instance.
- *
- * @author Clebert Suconic
- */
-public abstract class HATestBase extends TestCase
-{
-
-    protected Logger log = Logger.getLogger(getClass());
-
-    protected ConnectionFactory factoryServer1;
-    protected ConnectionFactory factoryServer2;
-
-    protected Context ctx1;
-    protected Context ctx2;
-
-
-    protected String NODE1 =System.getProperty("NODE1","localhost:1199");
-    protected String NODE2 =System.getProperty("NODE2","localhost:1299");
-
-
-   public void setUp(String jndiFactory) throws Exception
-   {
-      super.setUp();
-
-      System.out.println("Server1=" + NODE1);
-      System.out.println("Server2=" + NODE2);
-
-      ctx1 = getContext(NODE1);
-      ctx2 = getContext(NODE2);
-
-      factoryServer1 = (ConnectionFactory) ctx1.lookup(jndiFactory);
-      factoryServer2 = (ConnectionFactory) ctx2.lookup(jndiFactory);
-   }
-
-   public void setUp() throws Exception
-   {
-      this.setUp("/ConnectionFactory");
-   }
-
-   protected Context getContext(String host) throws Exception
-    {
-        // don't worry about this yet, we will put this in more generic way.
-        // This is for test purposes only.
-        String jndiProviderClass = "org.jnp.interfaces.NamingContextFactory";
-        Properties contextProperties = new Properties();
-        contextProperties.put(Context.INITIAL_CONTEXT_FACTORY,
-            jndiProviderClass);
-        contextProperties.put(Context.PROVIDER_URL,
-            "jnp://"+ host);
-        return new InitialContext(contextProperties);
-
-    }
-
-
-    protected ConnectionFactory getFactoryServer1() {
-        return factoryServer1;
-    }
-
-    protected ConnectionFactory getFactoryServer2() {
-        return factoryServer2;
-    }
-
-    protected String getNODE1() {
-        return NODE1;
-    }
-
-    protected String getNODE2() {
-        return NODE2;
-    }
-
-    public Context getCtx1() {
-        return ctx1;
-    }
-
-    public Context getCtx2() {
-        return ctx2;
-    }
-
-}

Copied: trunk/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/HATestBase.java)

Deleted: trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,413 +0,0 @@
-package org.jboss.test.messaging.core.ha;
-
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.JBossMessageConsumer;
-import org.jboss.jms.client.JBossSession;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.client.state.ConsumerState;
-import org.jboss.jms.client.state.SessionState;
-import org.jboss.jms.message.MessageProxy;
-
-import javax.jms.*;
-
-/** Start two JBoss instances (clustered) to run these tests.
- *  */
-public class ReconnectClusteredTest extends HATestBase
-{
-
-//    public void testSimpleReconnect() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        assertFalse(state.isStarted());
-//        conn.start();
-//        assertTrue(state.isStarted());
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        conn.stop();
-//        assertFalse(state.isStarted());
-//
-//    }
-//
-//    public void testSimpleReconnectWithClientID() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.setClientID("someClient");
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        assertFalse(state.isStarted());
-//        conn.start();
-//        assertTrue(state.isStarted());
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        // force recovering the clientID from server
-//        state.setClientID(null);
-//        assertEquals ("someClient",conn.getClientID());
-//
-//        conn.stop();
-//        assertFalse(state.isStarted());
-//
-//    }
-//
-//    public void testWithSession() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//    }
-//
-//    public void testSimpleWithOneProducerOnTopic() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//        MessageProducer producer = session.createProducer(destination);
-//
-//        Message message = session.createTextMessage("Hello Before");
-//        producer.send(message);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        message = session.createTextMessage("Hello After");
-//        producer.send(message);
-//    }
-//
-//    public void testSimpleWithOneProducerOnQueue() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        Destination destination = (Destination)getCtx1().lookup("queue/testQueue");
-//        MessageProducer producer = session.createProducer(destination);
-//
-//        Message message = session.createTextMessage("Hello Before");
-//        producer.send(message);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        message = session.createTextMessage("Hello After");
-//        producer.send(message);
-//    }
-//
-//    public void testTopicCluster() throws Exception
-//    {
-//        log.info("++testTopicCluster");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testDistributedTopic");
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//
-//
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//
-//        MessageProducer producer = sessionFirstServer.createProducer(destination);
-//
-//        MessageConsumer consumer = sessionSecondServer.createConsumer(destination);
-//
-//        producer.send(sessionFirstServer.createTextMessage("Hello"));
-//
-//        assertNotNull(consumer.receive(2000));
-//    }
-//
-//    public void testTopicSubscriber() throws Exception
-//    {
-//        log.info("++testTopicSubscriber");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testDistributedTopic");
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.setClientID("testClient");
-//        conn.start();
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//
-//        MessageConsumer consumerHA = session.createDurableSubscriber((Topic)destination,"T1");
-//        JBossMessageConsumer jbossConsumerHA =(JBossMessageConsumer)consumerHA;
-//
-//        org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate)jbossConsumerHA.getDelegate();
-//        ConsumerState consumerState = (ConsumerState)clientDelegate.getState();
-//
-//        log.info("subscriptionName=" + consumerState.getSubscriptionName());
-//
-//
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//        session.commit();
-//
-//        receiveMessage("consumerHA",consumerHA,true,false);
-//
-//        session.commit();
-//        //if (true) return;
-//
-//        Object txID = sessionState.getCurrentTxId();
-//
-//        producer.send(session.createTextMessage("Hello again before failover"));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//
-//        log.info(">>Creating alternate connection");
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        log.info("NewConnectionCreated=" + conn2);
-//
-//        log.info(">>Failling over");
-//        assertSame(originalRemoting,delegate.getRemotingConnection());
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        try {
-//            originalRemoting.stop();
-//        } catch (Throwable throwable) {
-//            throwable.printStackTrace();
-//        }
-//
-//
-//        assertNotSame(originalRemoting,delegate.getRemotingConnection());
-//
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//
-//       /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
-//
-//        session.commit();
-//
-//        /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-//        receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-//        receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
-//
-//        log.info("Calling alternate receiver");
-//        receiveMessage("consumerHA",consumerHA,true,false);
-//        receiveMessage("consumerHA",consumerHA,true,false);
-//        receiveMessage("consumerHA",consumerHA,true,true);
-//
-//
-//        session.commit();
-//
-//    }
-//
-//   public void testQueueHA() throws Exception
-//   {
-//       log.info("++testTopicSubscriber");
-//
-//       log.info(">>Lookup Queue");
-//       Destination destination = (Destination)getCtx1().lookup("queue/testDistributedQueue");
-//
-//       log.info("Creating connection server1");
-//       JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//       conn.setClientID("testClient");
-//       conn.start();
-//
-//       JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//       ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//       SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//
-//       MessageConsumer consumerHA = session.createConsumer(destination);
-//       JBossMessageConsumer jbossConsumerHA =(JBossMessageConsumer)consumerHA;
-//
-//       org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate)jbossConsumerHA.getDelegate();
-//       ConsumerState consumerState = (ConsumerState)clientDelegate.getState();
-//
-//       log.info("subscriptionName=" + consumerState.getSubscriptionName());
-//
-//
-//       log.info(">>Creating Producer");
-//       MessageProducer producer = session.createProducer(destination);
-//       log.info(">>creating Message");
-//       Message message = session.createTextMessage("Hello Before");
-//       log.info(">>sending Message");
-//       producer.send(message);
-//       session.commit();
-//
-//       session.commit();
-//       //if (true) return;
-//
-//       Object txID = sessionState.getCurrentTxId();
-//
-//       ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//       JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//
-//       log.info(">>Creating alternate connection");
-//       JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//       log.info("NewConnectionCreated=" + conn2);
-//
-//       log.info(">>Failling over");
-//       assertSame(originalRemoting,delegate.getRemotingConnection());
-//       conn.getDelegate().failOver(conn2.getDelegate());
-//
-//       try {
-//           originalRemoting.stop();
-//       } catch (Throwable throwable) {
-//           throwable.printStackTrace();
-//       }
-//
-//
-//       assertNotSame(originalRemoting,delegate.getRemotingConnection());
-//
-//       //System.out.println("Kill server1"); Thread.sleep(10000);
-//       assertEquals(txID,sessionState.getCurrentTxId());
-//       System.out.println("TransactionID on client = " + txID);
-//       log.info(">>Final commit");
-//
-//       session.commit();
-//
-//       log.info("Calling alternate receiver");
-//       receiveMessage("consumerHA",consumerHA,true,false);
-//       receiveMessage("consumerHA",consumerHA,true,true);
-//
-//       session.commit();
-//
-//       for (int i=0;i<30;i++)
-//       {
-//          log.info("Message Sent " + i);
-//          producer.send(session.createTextMessage("Message " + i));
-//       }
-//      session.commit();
-//
-//      Thread.sleep(5000);
-//
-//       TextMessage messageLoop = null;
-//       while (!((messageLoop = (TextMessage) consumerHA.receive(5000)) == null))
-//       {
-//          log.info("Message received = " + messageLoop.getText());
-//       }
-//
-//   }
-//
-//
-//    private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
-//    {
-//        MessageProxy message = (MessageProxy)consumer.receive(3000);
-//        TextMessage txtMessage = (TextMessage)message;
-//        if (message!=null)
-//        {
-//            log.info(text + ": messageID from messageReceived=" + message.getMessage().getMessageID() + " message = " + message + " content=" + txtMessage.getText());
-//        }
-//        else
-//        {
-//            log.info(text + ": Message received was null");
-//        }
-//        if (shouldAssert)
-//        {
-//            if (shouldBeNull)
-//            {
-//                assertNull(message);
-//            }
-//            else
-//            {
-//                assertNotNull(message);
-//            }
-//        }
-//    }
-//
-//   public void testSimplestDurableSubscription() throws Exception
-//   {
-//      ConnectionFactory cf = factoryServer1;
-//      Topic topic = (Topic)getCtx1().lookup("topic/testDistributedTopic");
-//
-//      Connection conn = cf.createConnection();
-//
-//      conn.setClientID("brookeburke");
-//
-//      conn.start();
-//
-//      Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//      MessageProducer prod = s.createProducer(topic);
-//      prod.setDeliveryMode(DeliveryMode.PERSISTENT);
-//
-//      log.info("      ******************                       s.createDurableSubscriber(topic, \"monicabelucci\")                 ****************************");
-//      MessageConsumer firstconsumer = (MessageConsumer)s.createDurableSubscriber(topic, "monicabelucci");
-//
-//
-//      System.out.println("\n\n****************************************   consumer=" + firstconsumer.toString() + "\n\n");
-//      Object message=firstconsumer.receive(2000);
-//
-//      log.info(" \n\n*******************************                          message Received=" + message + "\n\n");
-//
-//      prod.send(s.createTextMessage("k"));
-//
-//      conn.close();
-//
-//      conn = cf.createConnection();
-//      conn.setClientID("brookeburke");
-//
-//      log.info("      ******************                       conn.createSession(...);                                                       ****************************");
-//      s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//
-//
-//      log.info("      ******************                       s.createDurableSubscriber(topic, \"monicabelucci\")                 ****************************");
-//      MessageConsumer durable = s.createDurableSubscriber(topic, "monicabelucci");
-//
-//       log.info("      ******************                       conn.start();                                                       ****************************");
-//       conn.start();
-//
-//      log.info("      ******************                       TextMessage tm = (TextMessage)durable.receive();                    ****************************");
-//      TextMessage tm = (TextMessage)durable.receive();
-//      assertEquals("k", tm.getText());
-//
-//      log.info("      ******************                       Message m = durable.receive(1000); (expected to be null)            ****************************");
-//      Message m = durable.receive(1000);
-//
-//       prod = s.createProducer(topic);
-//       prod.setDeliveryMode(DeliveryMode.PERSISTENT);
-//       prod.send(s.createTextMessage("Hello"));
-//
-//       Connection conn2 = factoryServer2.createConnection();
-//       conn2.setClientID("clientTest");
-//
-//       Session session = conn2.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//       conn2.start();
-//
-//       MessageConsumer consumer2 = session.createDurableSubscriber(topic,"spongebog");
-//       System.out.println("Consumer2=" + consumer2);
-//
-//
-//   }
-
-
-}

Copied: trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/ReconnectClusteredTest.java)

Deleted: trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,390 +0,0 @@
-package org.jboss.test.messaging.core.ha;
-
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.JBossSession;
-import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.client.state.SessionState;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.message.JBossMessage;
-import org.jboss.jms.message.TextMessageProxy;
-
-import javax.jms.*;
-
-
-/** Start two JBoss instances (non clustered) to run these tests.
- *  */
-public class ReconnectNonClusteredTest extends HATestBase
-{
-
-//    public void testSimpleReconnect() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        assertFalse(state.isStarted());
-//        conn.start();
-//        assertTrue(state.isStarted());
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        conn.stop();
-//        assertFalse(state.isStarted());
-//
-//    }
-//
-//    public void testSimpleReconnectWithClientID() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.setClientID("someClient");
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        assertFalse(state.isStarted());
-//        conn.start();
-//        assertTrue(state.isStarted());
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        // force recovering the clientID from server
-//        state.setClientID(null);
-//        assertEquals ("someClient",conn.getClientID());
-//
-//        conn.stop();
-//        assertFalse(state.isStarted());
-//
-//    }
-//
-//    public void testWithSession() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//    }
-//
-//    public void testSimpleWithOneProducerOnTopic() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//        MessageProducer producer = session.createProducer(destination);
-//
-//        Message message = session.createTextMessage("Hello Before");
-//        producer.send(message);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        System.out.println("Kill server1");
-//        Thread.sleep(10000);
-//
-//
-//        message = session.createTextMessage("Hello After");
-//        producer.send(message);
-//    }
-//
-//    public void testSimpleWithOneProducerOnQueue() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        Destination destination = (Destination)getCtx1().lookup("queue/testQueue");
-//        MessageProducer producer = session.createProducer(destination);
-//
-//        Message message = session.createTextMessage("Hello Before");
-//        producer.send(message);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        System.out.println("Kill server1");
-//        Thread.sleep(10000);
-//
-//
-//        message = session.createTextMessage("Hello After");
-//        producer.send(message);
-//    }
-//
-//    public void testSimpleWithOneProducerTransacted() throws Exception
-//    {
-//        log.info("++testSimpleWithOneProducerTransacted");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//
-//        log.info("Creating connections used for assertion (not failed over)");
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination);
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerFirstServer = sessionFirstServer.createConsumer(destination);
-//
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//
-//        log.info("ConnectionCreated=" + conn);
-//        log.info(">>Creating Sessions");
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>Creating Producer - ");
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        log.info("sending first commit");
-//        session.commit();
-//        Object txID = sessionState.getCurrentTxId();
-//
-//        assertNotNull(consumerFirstServer.receive(2000));
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        producer.send(session.createTextMessage("Hello again before failover"));
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        log.info(">>Creating alternate connection");
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        log.info("NewConnectionCreated=" + conn2);
-//
-//        log.info(">>Failling over");
-//        assertSame(originalRemoting,delegate.getRemotingConnection());
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//        /*try {
-//            originalRemoting.stop();
-//        } catch (Throwable throwable) {
-//            throwable.printStackTrace();  //To change body of catch statement use File | Settings | File Templates.
-//        } */
-//
-//        assertNotSame(originalRemoting,delegate.getRemotingConnection());
-//
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//        session.commit();
-//
-//        log.info("Checking receive on second server");
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        log.info("Checking receive on first server");
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//    }
-//
-//    public void testSimpleWithOneProducerTransactedWithoutHA() throws Exception
-//    {
-//        log.info("++testSimpleWithOneProducerTransacted");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//
-//        log.info("Creating connections used for assertion (not failed over)");
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination);
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerFirstServer = sessionFirstServer.createConsumer(destination);
-//
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer2.createConnection();
-//
-//        log.info("ConnectionCreated=" + conn);
-//        log.info(">>Creating Sessions");
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//        System.out.println("Size of callbackHandlers=" + sessionState.getCallbackHandlers().size());
-//        Object txID = sessionState.getCurrentTxId();
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>Creating Producer - ");
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        log.info("sending first commit");
-//        //session.commit();
-//
-//        assertNull(consumerFirstServer.receive(2000));
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        TextMessageProxy messagetxt = (TextMessageProxy)session.createTextMessage("Hello again before failover");
-//        producer.send(messagetxt);
-//        System.out.println("Id=" + messagetxt.getMessage().getConnectionID());
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        log.info(">>Failling over");
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//        session.commit();
-//
-//        log.info("Checking receive on second server");
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNotNull(consumerSecondServer.receive(3000));
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        log.info("Checking receive on first server");
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//    }
-//
-//    public void testTopicSubscriber() throws Exception
-//    {
-//        log.info("++testSimpleWithOneProducerTransacted");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.start();
-//
-//        log.info("ConnectionCreated=" + conn);
-//        log.info(">>Creating Sessions");
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//        MessageConsumer consumerHA = session.createConsumer(destination);
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//        session.commit();
-//
-//        assertNotNull(consumerHA.receive(3000));
-//        session.commit();
-//
-//        Object txID = sessionState.getCurrentTxId();
-//
-//        producer.send(session.createTextMessage("Hello again before failover"));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        log.info(">>Creating alternate connection");
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        log.info("NewConnectionCreated=" + conn2);
-//
-//        log.info(">>Failling over");
-//        assertSame(originalRemoting,delegate.getRemotingConnection());
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        try {
-//            originalRemoting.stop();
-//        } catch (Throwable throwable) {
-//            throwable.printStackTrace();
-//        }
-//
-//
-//        assertNotSame(originalRemoting,delegate.getRemotingConnection());
-//
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination);
-//
-//        session.commit();
-//
-//        //assertNotNull(consumerSecondServer.receive(3000));
-//        assertNotNull(consumerSecondServer.receive(3000));
-//        assertNotNull(consumerSecondServer.receive(3000));
-//        assertNull(consumerSecondServer.receive(3000));
-//
-//        log.info("Calling alternate receiver");
-//        //assertNotNull(consumerHA.receive(1000));
-//        assertNotNull(consumerHA.receive(1000));
-//        assertNotNull(consumerHA.receive(1000));
-//        assertNull(consumerHA.receive(1000));
-//
-//    }
-}

Copied: trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java)

Modified: trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -114,10 +114,9 @@
       sc = new ServiceContainer("all,-remoting,-security");
       sc.start();
 
-      pm =
-         new JDBCPersistenceManager(sc.getDataSource(), sc.getTransactionManager(),
-                  sc.getPersistenceManagerSQLProperties(),
-                  true, true, true, 100);
+      pm = new JDBCPersistenceManager(sc.getDataSource(), sc.getTransactionManager(),
+                                      sc.getPersistenceManagerSQLProperties(),
+                                      true, true, true, 100);
       pm.start();
       
       idm = new IdManager("TRANSACTION_ID", 10, pm);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -39,6 +39,8 @@
 import org.jboss.messaging.core.plugin.IdManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
+import org.jboss.messaging.core.plugin.contract.Condition;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
@@ -46,6 +48,7 @@
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -85,6 +88,8 @@
    
    protected QueuedExecutorPool pool;
    
+   protected ConditionFactory conditionFactory;
+   
    // Constructors --------------------------------------------------
 
    public PostOfficeTestBase(String name)
@@ -121,6 +126,8 @@
       
       channelIdManager = new IdManager("CHANNEL_ID", 10, pm);
       channelIdManager.start();
+      
+      conditionFactory = new SimpleConditionFactory();
             
       log.debug("setup done");
    }
@@ -147,9 +154,11 @@
    {
       FilterFactory ff = new SimpleFilterFactory();
       
+      ConditionFactory cf= new SimpleConditionFactory();
+      
       DefaultPostOffice postOffice = 
          new DefaultPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                            sc.getPostOfficeSQLProperties(), true, 1, "Simple", ms, pm, tr, ff, pool);
+                            sc.getPostOfficeSQLProperties(), true, 1, "Simple", ms, pm, tr, ff, cf, pool);
       
       postOffice.start();      
       
@@ -261,7 +270,7 @@
    
    private static long msgCount;
    
-   protected List sendMessages(String condition, boolean persistent, PostOffice office, int num, Transaction tx) throws Exception
+   protected List sendMessages(String conditionText, boolean persistent, PostOffice office, int num, Transaction tx) throws Exception
    {
       List list = new ArrayList();
       
@@ -271,6 +280,8 @@
          
          MessageReference ref = ms.reference(msg);         
          
+         Condition condition = conditionFactory.createCondition(conditionText);
+         
          boolean routed = office.route(ref, condition, null);         
          
          assertTrue(routed);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,44 +21,23 @@
   */
 package org.jboss.test.messaging.core.plugin.postoffice;
 
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
-import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Iterator;
 import java.util.List;
 
-import javax.naming.InitialContext;
-import javax.sql.DataSource;
-import javax.transaction.TransactionManager;
-
 import org.jboss.jms.selector.Selector;
-import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.messaging.core.Filter;
-import org.jboss.messaging.core.FilterFactory;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
-import org.jboss.messaging.core.plugin.IdManager;
-import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
-import org.jboss.messaging.core.plugin.SimpleMessageStore;
-import org.jboss.messaging.core.plugin.contract.MessageStore;
-import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
-import org.jboss.messaging.core.plugin.postoffice.DefaultPostOffice;
 import org.jboss.messaging.core.tx.Transaction;
-import org.jboss.messaging.core.tx.TransactionRepository;
-import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.core.SimpleCondition;
 import org.jboss.test.messaging.core.SimpleFilter;
-import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
-import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.test.messaging.tools.jmx.ServiceContainer;
 import org.jboss.test.messaging.util.CoreMessageFactory;
-import org.jboss.tm.TransactionManagerService;
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
@@ -124,12 +103,12 @@
          
          
          Binding binding1 =
-            office1.bindQueue("condition1", queue1);
+            office1.bindQueue(new SimpleCondition("condition1"), queue1);
          
          //Binding twice with the same name should fail      
          try
          {
-            Binding bindFail = office1.bindQueue("condition1", queue1);
+            Binding bindFail = office1.bindQueue(new SimpleCondition("condition1"), queue1);
             fail();
          }
          catch (IllegalArgumentException e)
@@ -141,7 +120,7 @@
          PagingFilteredQueue queue2 = new PagingFilteredQueue("nonDurableQueue", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
-            office1.bindQueue("condition2", queue2);
+            office1.bindQueue(new SimpleCondition("condition2"), queue2);
          
          //Check they're there
          
@@ -231,60 +210,60 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
-            office.bindQueue("condition1", queue1);
+            office.bindQueue(new SimpleCondition("condition1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            office.bindQueue("condition1", queue2);
+            office.bindQueue(new SimpleCondition("condition1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            office.bindQueue("condition1", queue3);
+            office.bindQueue(new SimpleCondition("condition1"), queue3);
          
          PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding4 =
-            office.bindQueue("condition1", queue4);
+            office.bindQueue(new SimpleCondition("condition1"), queue4);
          
          PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding5 =
-            office.bindQueue("condition2", queue5);
+            office.bindQueue(new SimpleCondition("condition2"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding6 =
-            office.bindQueue("condition2", queue6);
+            office.bindQueue(new SimpleCondition("condition2"), queue6);
          
          PagingFilteredQueue queue7 = new PagingFilteredQueue("queue7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding7 =
-            office.bindQueue("condition2", queue7);
+            office.bindQueue(new SimpleCondition("condition2"), queue7);
          
          PagingFilteredQueue queue8 = new PagingFilteredQueue("queue8", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding8 =
-            office.bindQueue("condition2", queue8);
+            office.bindQueue(new SimpleCondition("condition2"), queue8);
          
          
-         Collection bindings = office.listBindingsForCondition("dummy");
+         Collection bindings = office.listBindingsForCondition(new SimpleCondition("dummy"));
          assertNotNull(bindings);
          assertTrue(bindings.isEmpty());
          
          //We don't match on substrings
-         bindings = office.listBindingsForCondition("condition123");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition123"));
          assertNotNull(bindings);
          assertTrue(bindings.isEmpty());
          
          //We don't currently support hierarchies
-         bindings = office.listBindingsForCondition("condition1.subcondition");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition1.subcondition"));
          assertNotNull(bindings);
          assertTrue(bindings.isEmpty());
          
          //We currently just do an exact match
-         bindings = office.listBindingsForCondition("condition1");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -294,7 +273,7 @@
          assertEquivalent((Binding)iter.next(), binding3);
          assertEquivalent((Binding)iter.next(), binding4);
          
-         bindings = office.listBindingsForCondition("condition2");
+         bindings = office.listBindingsForCondition(new SimpleCondition("condition2"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -357,32 +336,32 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            postOffice.bindQueue("topic1", queue3);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
          PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding4 =
-            postOffice.bindQueue("topic2", queue4);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
          PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding5 =
-            postOffice.bindQueue("topic2", queue5);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding6 =
-            postOffice.bindQueue("topic2", queue6);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
       
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -412,7 +391,7 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, "topic1", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          List msgs = receiver1.getMessages();
@@ -450,7 +429,7 @@
          Message msg2 = CoreMessageFactory.createCoreMessage(2);      
          MessageReference ref2 = ms.reference(msg2);
          
-         routed = postOffice.route(ref2, "topic2", null);      
+         routed = postOffice.route(ref2, new SimpleCondition("topic2"), null);      
          assertTrue(routed);
          
          msgs = receiver1.getMessages();
@@ -509,7 +488,7 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding1 =
-            postOffice.bindQueue("condition1", queue1);
+            postOffice.bindQueue(new SimpleCondition("condition1"), queue1);
               
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -519,7 +498,7 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, "this won't match anything", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("this won't match anything"), null);      
          
          assertFalse(routed);
                
@@ -561,17 +540,17 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), filter);         
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            postOffice.bindQueue("topic1", queue3);   
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);   
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -582,15 +561,15 @@
          
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);         
-         boolean routed = postOffice.route(ref1, "topic1", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          Message msg2 = CoreMessageFactory.createCoreMessage(2);      
          MessageReference ref2 = ms.reference(msg2);         
-         routed = postOffice.route(ref2, "topic1", null);      
+         routed = postOffice.route(ref2, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          Message msg3 = CoreMessageFactory.createCoreMessage(3);      
          MessageReference ref3 = ms.reference(msg3);         
-         routed = postOffice.route(ref3, "topic1", null);      
+         routed = postOffice.route(ref3, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          List msgs = receiver1.getMessages();
@@ -663,32 +642,32 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
          PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
          
          Binding binding3 =
-            postOffice.bindQueue("topic1", queue3);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
          PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
          
          Binding binding4 =
-            postOffice.bindQueue("topic2", queue4);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
          PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
          
          Binding binding5 =
-            postOffice.bindQueue("topic2", queue5);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
          
          Binding binding6 =
-            postOffice.bindQueue("topic2", queue6);
+            postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
       
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -713,7 +692,7 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, "topic1", null);      
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          List msgs = receiver1.getMessages();
@@ -766,7 +745,7 @@
          Message msg2 = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);      
          MessageReference ref2 = ms.reference(msg2);
          
-         routed = postOffice.route(ref2, "topic2", null);      
+         routed = postOffice.route(ref2, new SimpleCondition("topic2"), null);      
          assertTrue(routed);
          
          msgs = receiver4.getMessages();
@@ -837,12 +816,12 @@
          PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
-            postOffice.bindQueue("topic1", queue1);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
          PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
-            postOffice.bindQueue("topic1", queue2);
+            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
           
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -861,9 +840,9 @@
          
          Transaction tx = tr.createTransaction();
          
-         boolean routed = postOffice.route(ref1, "topic1", tx);            
+         boolean routed = postOffice.route(ref1, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
-         routed = postOffice.route(ref2, "topic1", tx);            
+         routed = postOffice.route(ref2, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
                
          List msgs = queue1.browse();
@@ -919,9 +898,9 @@
          
          tx = tr.createTransaction();
          
-         routed = postOffice.route(ref3, "topic1", tx);            
+         routed = postOffice.route(ref3, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
-         routed = postOffice.route(ref4, "topic1", tx);            
+         routed = postOffice.route(ref4, new SimpleCondition("topic1"), tx);            
          assertTrue(routed);
                
          msgs = queue1.browse();
@@ -953,9 +932,9 @@
          Message msg6 = CoreMessageFactory.createCoreMessage(6, persistentMessage, null);      
          MessageReference ref6 = ms.reference(msg6);
                
-         routed = postOffice.route(ref5, "topic1", null);            
+         routed = postOffice.route(ref5, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
-         routed = postOffice.route(ref6, "topic1", null);            
+         routed = postOffice.route(ref6, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
          
          msgs = receiver1.getMessages();
@@ -1020,9 +999,9 @@
          Message msg8 = CoreMessageFactory.createCoreMessage(8, persistentMessage, null);      
          MessageReference ref8 = ms.reference(msg8);
                
-         routed = postOffice.route(ref7, "topic1", null);            
+         routed = postOffice.route(ref7, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
-         routed = postOffice.route(ref8, "topic1", null);            
+         routed = postOffice.route(ref8, new SimpleCondition("topic1"), null);            
          assertTrue(routed);
          
          msgs = receiver1.getMessages();

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -30,14 +30,19 @@
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilter;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
@@ -83,6 +88,60 @@
       super.tearDown();
    }
    
+   public final void testSimpleJoinLeave() throws Throwable
+   {
+      ClusteredPostOffice office1 = null;
+      
+      ClusteredPostOffice office2 = null;
+      
+      //ClusteredPostOffice office3 = null;
+      
+      try
+      {         
+         log.info("Starting office 1");
+         office1 = createClusteredPostOffice(1, "testgroup");
+         
+         log.info("starting office 2");
+         office2 = createClusteredPostOffice(2, "testgroup");
+                  
+         //office3 = createClusteredPostOffice(3, "testgroup");
+         
+         Thread.sleep(2000);
+         
+         office1.stop();
+         office1 = null;
+         
+         office2.stop();
+         office2 = null;
+         
+//         office3.stop();
+//         office3 = null;
+      }
+      finally
+      {
+         if (office1 != null)
+         {
+            office1.stop();
+         }
+         
+         if (office2 != null)
+         {
+            office2.stop();
+         }
+         
+//         if (office3 != null)
+//         {
+//            office3.stop();
+//         }
+         
+         if (checkNoBindingData())
+         {
+            fail("data still in database");
+         }
+      }
+         
+   }
+   
    public final void testClusteredBindUnbind() throws Throwable
    {
       ClusteredPostOffice office1 = null;
@@ -101,17 +160,17 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);        
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
-            office1.bindClusteredQueue("topic1", queue2);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          //Start another office - make sure it picks up the bindings from the first node
          
          office2 = createClusteredPostOffice(2, "testgroup");
          
-         Collection bindings = office2.listAllBindingsForCondition("topic1");
+         Collection bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -124,11 +183,11 @@
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
 
          Binding binding3 =
-            office2.bindClusteredQueue("topic1", queue3);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
   
          //Make sure both nodes pick it up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -137,7 +196,7 @@
          assertEquivalent(binding2, (Binding)iter.next());
          assertEquivalent(binding3, (Binding)iter.next());
 
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -150,11 +209,11 @@
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 =
-            office2.bindClusteredQueue("topic1", queue4);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue4);
          
          // Make sure both nodes pick it up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -164,7 +223,7 @@
          assertEquivalent(binding3, (Binding)iter.next());
          assertEquivalent(binding4, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -180,7 +239,7 @@
          
          //Make sure bindings are not longer available on either node
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -188,7 +247,7 @@
          assertEquivalent(binding3, (Binding)iter.next());
          assertEquivalent(binding4, (Binding)iter.next());
    
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -202,7 +261,7 @@
          
          //Maks sure it picks up the bindings
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -215,11 +274,11 @@
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office3, 3, "sub5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding5 =
-            office3.bindClusteredQueue("topic1", queue5);
+            office3.bindClusteredQueue(new SimpleCondition("topic1"), queue5);
          
          // Make sure all nodes pick it up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -228,7 +287,7 @@
          assertEquivalent(binding4, (Binding)iter.next());
          assertEquivalent(binding5, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -237,7 +296,7 @@
          assertEquivalent(binding4, (Binding)iter.next());
          assertEquivalent(binding5, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(3, bindings.size());
          
@@ -251,16 +310,16 @@
          LocalClusteredQueue queue6 = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          
          Binding binding6 =
-            office1.bindClusteredQueue("topic1", queue6);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue6);
          
          LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
          
          Binding binding7 =
-            office1.bindClusteredQueue("topic1", queue7);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue7);
          
          // Make sure all nodes pick them up
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(5, bindings.size());
          
@@ -271,7 +330,7 @@
          assertEquivalent(binding6, (Binding)iter.next());
          assertEquivalent(binding7, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(5, bindings.size());
          
@@ -282,7 +341,7 @@
          assertEquivalent(binding6, (Binding)iter.next());
          assertEquivalent(binding7, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(5, bindings.size());
          
@@ -304,7 +363,7 @@
          //All it's non durable bindings should be removed from the other nodes
          //Durable bindings should remain
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -314,7 +373,7 @@
          assertEquivalent(binding5, (Binding)iter.next());
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(4, bindings.size());
          
@@ -327,7 +386,7 @@
          //Stop office 2
          office2.stop();
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -340,7 +399,7 @@
          
          office2 = createClusteredPostOffice(2, "testgroup");
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -348,7 +407,7 @@
          assertEquivalent(binding5, (Binding)iter.next());
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -356,7 +415,7 @@
          assertEquivalent(binding5, (Binding)iter.next());
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(2, bindings.size());
          
@@ -377,21 +436,21 @@
          
          //Only the durable queue should survive
          
-         bindings = office1.listAllBindingsForCondition("topic1");
+         bindings = office1.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(1, bindings.size());
          
          iter = bindings.iterator();
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office2.listAllBindingsForCondition("topic1");
+         bindings = office2.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(1, bindings.size());
          
          iter = bindings.iterator();
          assertEquivalent(binding6, (Binding)iter.next());
          
-         bindings = office3.listAllBindingsForCondition("topic1");
+         bindings = office3.listAllBindingsForCondition(new SimpleCondition("topic1"));
          assertNotNull(bindings);
          assertEquals(1, bindings.size());
          
@@ -541,17 +600,17 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
 
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
 
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
 
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          try
          {
-            Binding binding3 = office1.bindClusteredQueue("queue1", queue3);
+            Binding binding3 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue3);
             fail();
          }
          catch (Exception e)
@@ -562,7 +621,7 @@
          
          try
          {
-            Binding binding4 = office2.bindClusteredQueue("queue1", queue4);
+            Binding binding4 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
             fail();
          }
          catch (Exception e)
@@ -576,12 +635,12 @@
 
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
-         Binding binding5 = office1.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
          
          PagingFilteredQueue queue6 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);       
          try
          {
-            Binding binding6 = office1.bindQueue("queue1", queue6);
+            Binding binding6 = office1.bindQueue(new SimpleCondition("queue1"), queue6);
             fail();
          }
          catch (Exception e)
@@ -593,15 +652,15 @@
          
          //It should be possible to bind queues locally into a clustered post office
          LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding7 = office1.bindQueue("queue1", queue7);
+         Binding binding7 = office1.bindQueue(new SimpleCondition("queue1"), queue7);
          
          LocalClusteredQueue queue8 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);       
-         Binding binding8 = office2.bindQueue("queue1", queue8);
+         Binding binding8 = office2.bindQueue(new SimpleCondition("queue1"), queue8);
          
          LocalClusteredQueue queue9 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);       
          try
          {
-            Binding binding9 = office1.bindQueue("queue1", queue9);
+            Binding binding9 = office1.bindQueue(new SimpleCondition("queue1"), queue9);
             fail();
          }
          catch (Exception e)
@@ -644,15 +703,15 @@
       
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter1, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter2, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("topic1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "queue3", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding3 =
-            office2.bindClusteredQueue("topic1", queue3);   
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue3);   
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -663,17 +722,17 @@
          
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);  
-         boolean routed = office1.route(ref1, "topic1", null);   
+         boolean routed = office1.route(ref1, new SimpleCondition("topic1"), null);   
          assertTrue(routed);
          
          
          Message msg2 = CoreMessageFactory.createCoreMessage(2);      
          MessageReference ref2 = ms.reference(msg2);         
-         routed = office1.route(ref2, "topic1", null);      
+         routed = office1.route(ref2, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          Message msg3 = CoreMessageFactory.createCoreMessage(3);      
          MessageReference ref3 = ms.reference(msg3);         
-         routed = office1.route(ref3, "topic1", null);      
+         routed = office1.route(ref3, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -752,52 +811,52 @@
          Binding[] bindings = new Binding[16];
          
          queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[0] = office1.bindClusteredQueue("topic1", queues[0]);
+         bindings[0] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[0]);
          
          queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[1] = office1.bindClusteredQueue("topic1", queues[1]);
+         bindings[1] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[1]);
          
          queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[2] = office2.bindClusteredQueue("topic1", queues[2]);
+         bindings[2] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[2]);
          
          queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[3] = office2.bindClusteredQueue("topic1", queues[3]);
+         bindings[3] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[3]);
          
          queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[4] = office2.bindClusteredQueue("topic1", queues[4]);
+         bindings[4] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[4]);
          
          queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[5] = office1.bindClusteredQueue("topic1", queues[5]);
+         bindings[5] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[5]);
          
          queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[6] = office1.bindClusteredQueue("topic1", queues[6]);
+         bindings[6] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[6]);
          
          queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[7] = office1.bindClusteredQueue("topic1", queues[7]);
+         bindings[7] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[7]);
          
          queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[8] = office1.bindClusteredQueue("topic2", queues[8]);
+         bindings[8] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[8]);
          
          queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[9] = office1.bindClusteredQueue("topic2", queues[9]);
+         bindings[9] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[9]);
          
          queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[10] = office2.bindClusteredQueue("topic2", queues[10]);
+         bindings[10] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[10]);
          
          queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[11] = office2.bindClusteredQueue("topic2", queues[11]);
+         bindings[11] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[11]);
          
          queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[12] = office2.bindClusteredQueue("topic2", queues[12]);
+         bindings[12] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[12]);
          
          queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[13] = office1.bindClusteredQueue("topic2", queues[13]);
+         bindings[13] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[13]);
          
          queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[14] = office1.bindClusteredQueue("topic2", queues[14]);
+         bindings[14] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[14]);
          
          queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[15] = office1.bindClusteredQueue("topic2", queues[15]);
+         bindings[15] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[15]);
        
          SimpleReceiver[] receivers = new SimpleReceiver[16];
          
@@ -810,7 +869,7 @@
          Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref = ms.reference(msg);         
 
-         boolean routed = office1.route(ref, "topic1", null);         
+         boolean routed = office1.route(ref, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
          
          //Messages are sent asych so may take some finite time to arrive
@@ -845,7 +904,7 @@
          msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);;      
          ref = ms.reference(msg);         
 
-         routed = office1.route(ref, "topic2", null);         
+         routed = office1.route(ref, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
          //Messages are sent asych so may take some finite time to arrive
          Thread.sleep(1000);
@@ -942,27 +1001,27 @@
          //We don't deploy on node 6
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2); 
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2); 
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding3 = office3.bindClusteredQueue("queue1", queue3);
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding4 = office4.bindClusteredQueue("queue1", queue4); 
+         Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4); 
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding5 = office5.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
         
@@ -970,7 +1029,7 @@
                           
          Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref = ms.reference(msg);         
-         boolean routed = office1.route(ref, "queue1", null);         
+         boolean routed = office1.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          checkContainsAndAcknowledge(msg, receiver1, queue1);
          this.checkEmpty(receiver2);
@@ -980,7 +1039,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office2.route(ref, "queue1", null);         
+         routed = office2.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          checkContainsAndAcknowledge(msg, receiver2, queue2);
@@ -990,7 +1049,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office3.route(ref, "queue1", null);         
+         routed = office3.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          this.checkEmpty(receiver2);
@@ -1000,7 +1059,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office4.route(ref, "queue1", null);         
+         routed = office4.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          this.checkEmpty(receiver2);
@@ -1010,7 +1069,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office5.route(ref, "queue1", null);         
+         routed = office5.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          this.checkEmpty(receiver1);
          this.checkEmpty(receiver2);         
@@ -1020,7 +1079,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office6.route(ref, "queue1", null);         
+         routed = office6.route(ref, new SimpleCondition("queue1"), null);         
          assertTrue(routed);
          
          //The actual queue that receives the mesage is determined by the routing policy
@@ -1095,17 +1154,17 @@
          office3 = createClusteredPostOffice(3, "testgroup");
 
          LocalClusteredQueue sub1 = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding1 = office1.bindQueue("topic", sub1);
+         Binding binding1 = office1.bindQueue(new SimpleCondition("topic"), sub1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub1.add(receiver1);
          
          LocalClusteredQueue sub2 = new LocalClusteredQueue(office2, 2, "sub2", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding2 = office2.bindQueue("topic", sub2); 
+         Binding binding2 = office2.bindQueue(new SimpleCondition("topic"), sub2); 
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub2.add(receiver2);
          
          LocalClusteredQueue sub3 = new LocalClusteredQueue(office3, 3, "sub3", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding3 = office3.bindQueue("topic", sub3);
+         Binding binding3 = office3.bindQueue(new SimpleCondition("topic"), sub3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub3.add(receiver3);
          
@@ -1113,7 +1172,7 @@
          
          Message msg = CoreMessageFactory.createCoreMessage(1, persistentMessage, null);      
          MessageReference ref = ms.reference(msg);         
-         boolean routed = office1.route(ref, "topic", null);         
+         boolean routed = office1.route(ref, new SimpleCondition("topic"), null);         
          assertTrue(routed);         
          Thread.sleep(500);         
          checkContainsAndAcknowledge(msg, receiver1, sub1);
@@ -1122,7 +1181,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(2, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office2.route(ref, "topic", null);         
+         routed = office2.route(ref, new SimpleCondition("topic"), null);         
          assertTrue(routed);                  
          Thread.sleep(500);
          this.checkEmpty(receiver1);
@@ -1131,7 +1190,7 @@
          
          msg = CoreMessageFactory.createCoreMessage(3, persistentMessage, null);      
          ref = ms.reference(msg);         
-         routed = office3.route(ref, "topic", null);           
+         routed = office3.route(ref, new SimpleCondition("topic"), null);           
          assertTrue(routed);         
          Thread.sleep(500);
          this.checkEmpty(receiver1);         
@@ -1212,13 +1271,13 @@
          
          //Non durable 1 on node 2
          LocalClusteredQueue nonDurable1 = new LocalClusteredQueue(office2, 2, "nondurable1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding1 = office2.bindClusteredQueue("topic", nonDurable1);
+         Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), nonDurable1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable1.add(receiver1);
          
          //Non durable 2 on node 2
          LocalClusteredQueue nonDurable2 = new LocalClusteredQueue(office2, 2, "nondurable2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding2 = office2.bindClusteredQueue("topic", nonDurable2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("topic"), nonDurable2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable2.add(receiver2);
          
@@ -1227,13 +1286,13 @@
          
          //Non shared durable
          LocalClusteredQueue nonSharedDurable1 = new LocalClusteredQueue(office3, 3, "nonshareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding3 = office3.bindClusteredQueue("topic", nonSharedDurable1);
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("topic"), nonSharedDurable1);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonSharedDurable1.add(receiver3);
          
          //Non durable
          LocalClusteredQueue nonDurable3 = new LocalClusteredQueue(office3, 3, "nondurable3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding4 = office3.bindClusteredQueue("topic", nonDurable3);
+         Binding binding4 = office3.bindClusteredQueue(new SimpleCondition("topic"), nonDurable3);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable3.add(receiver4);
          
@@ -1242,31 +1301,31 @@
          
          //Shared durable
          LocalClusteredQueue sharedDurable1 = new LocalClusteredQueue(office4, 4, "shareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding5 = office4.bindClusteredQueue("topic", sharedDurable1);
+         Binding binding5 = office4.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable1);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable1.add(receiver5);
          
          //Non shared durable
          LocalClusteredQueue nonSharedDurable2 = new LocalClusteredQueue(office4, 4, "nonshareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding6 = office4.bindClusteredQueue("topic", nonSharedDurable2);
+         Binding binding6 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonSharedDurable2);
          SimpleReceiver receiver6 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonSharedDurable2.add(receiver6);
          
          //Non durable
          LocalClusteredQueue nonDurable4 = new LocalClusteredQueue(office4, 4, "nondurable4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding7 = office4.bindClusteredQueue("topic", nonDurable4);
+         Binding binding7 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable4);
          SimpleReceiver receiver7 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable4.add(receiver7);
          
          // Non durable
          LocalClusteredQueue nonDurable5 = new LocalClusteredQueue(office4, 4, "nondurable5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding8 = office4.bindClusteredQueue("topic", nonDurable5);
+         Binding binding8 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable5);
          SimpleReceiver receiver8 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable5.add(receiver8);
          
          //Non durable
          LocalClusteredQueue nonDurable6 = new LocalClusteredQueue(office4, 4, "nondurable6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding9 = office4.bindClusteredQueue("topic", nonDurable6);
+         Binding binding9 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable6);
          SimpleReceiver receiver9 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable6.add(receiver9);
          
@@ -1274,32 +1333,32 @@
          //=======
          //Shared durable
          LocalClusteredQueue sharedDurable2 = new LocalClusteredQueue(office5, 5, "shareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding10 = office5.bindClusteredQueue("topic", sharedDurable2);
+         Binding binding10 = office5.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable2);
          SimpleReceiver receiver10 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable2.add(receiver10);
          
          //Shared durable
          LocalClusteredQueue sharedDurable3 = new LocalClusteredQueue(office5, 5, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding11 = office5.bindClusteredQueue("topic", sharedDurable3);
+         Binding binding11 = office5.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable3);
          SimpleReceiver receiver11 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable3.add(receiver11);
          
          // Node 6
          //=========
          LocalClusteredQueue sharedDurable4 = new LocalClusteredQueue(office6, 6, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding12 = office6.bindClusteredQueue("topic", sharedDurable4);
+         Binding binding12 = office6.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable4);
          SimpleReceiver receiver12 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable4.add(receiver12);
          
          LocalClusteredQueue nonDurable7 = new LocalClusteredQueue(office6, 6, "nondurable7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding13 = office6.bindClusteredQueue("topic", nonDurable7);
+         Binding binding13 = office6.bindClusteredQueue(new SimpleCondition("topic"), nonDurable7);
          SimpleReceiver receiver13 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable7.add(receiver13);
          
          //Node 7
          //=======
          LocalClusteredQueue sharedDurable5 = new LocalClusteredQueue(office7, 7, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
-         Binding binding14 = office7.bindClusteredQueue("topic", sharedDurable5);
+         Binding binding14 = office7.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable5);
          SimpleReceiver receiver14 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable5.add(receiver14);
          
@@ -1631,52 +1690,52 @@
          Binding[] bindings = new Binding[16];
          
          queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[0] = office1.bindClusteredQueue("topic1", queues[0]);
+         bindings[0] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[0]);
          
          queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[1] = office1.bindClusteredQueue("topic1", queues[1]);
+         bindings[1] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[1]);
          
          queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[2] = office2.bindClusteredQueue("topic1", queues[2]);
+         bindings[2] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[2]);
          
          queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[3] = office2.bindClusteredQueue("topic1", queues[3]);
+         bindings[3] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[3]);
          
          queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[4] = office2.bindClusteredQueue("topic1", queues[4]);
+         bindings[4] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[4]);
          
          queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[5] = office1.bindClusteredQueue("topic1", queues[5]);
+         bindings[5] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[5]);
          
          queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[6] = office1.bindClusteredQueue("topic1", queues[6]);
+         bindings[6] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[6]);
          
          queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[7] = office1.bindClusteredQueue("topic1", queues[7]);
+         bindings[7] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[7]);
          
          queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[8] = office1.bindClusteredQueue("topic2", queues[8]);
+         bindings[8] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[8]);
          
          queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[9] = office1.bindClusteredQueue("topic2", queues[9]);
+         bindings[9] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[9]);
          
          queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[10] = office2.bindClusteredQueue("topic2", queues[10]);
+         bindings[10] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[10]);
          
          queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[11] = office2.bindClusteredQueue("topic2", queues[11]);
+         bindings[11] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[11]);
          
          queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[12] = office2.bindClusteredQueue("topic2", queues[12]);
+         bindings[12] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[12]);
          
          queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[13] = office1.bindClusteredQueue("topic2", queues[13]);
+         bindings[13] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[13]);
          
          queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[14] = office1.bindClusteredQueue("topic2", queues[14]);
+         bindings[14] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[14]);
          
          queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
-         bindings[15] = office1.bindClusteredQueue("topic2", queues[15]);
+         bindings[15] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[15]);
 
          SimpleReceiver[] receivers = new SimpleReceiver[16];
          
@@ -1696,9 +1755,9 @@
          
          Transaction tx = tr.createTransaction();
 
-         boolean routed = office1.route(ref1, "topic1", tx);         
+         boolean routed = office1.route(ref1, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
 
          
@@ -1752,9 +1811,9 @@
          
          tx = tr.createTransaction();
 
-         routed = office1.route(ref1, "topic1", tx);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
          
          //Messages are sent asych so may take some finite time to arrive
@@ -1790,9 +1849,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic1", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
          
          //Messages are sent asych so may take some finite time to arrive
@@ -1858,9 +1917,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);;      
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic1", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), null);         
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -1949,9 +2008,9 @@
          
          tx = tr.createTransaction();
 
-         routed = office1.route(ref1, "topic2", tx);         
+         routed = office1.route(ref1, new SimpleCondition("topic2"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic2", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic2"), tx);         
          assertTrue(routed);
          
          
@@ -2006,9 +2065,9 @@
          
          tx = tr.createTransaction();
 
-         routed = office1.route(ref1, "topic1", tx);         
+         routed = office1.route(ref1, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic1", tx);         
+         routed = office1.route(ref2, new SimpleCondition("topic1"), tx);         
          assertTrue(routed);
          
          for (int i = 0; i < 16; i++)
@@ -2041,9 +2100,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);      
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic2", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic2", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -2110,9 +2169,9 @@
          msg2 = CoreMessageFactory.createCoreMessage(2, persistent, null);;      
          ref2 = ms.reference(msg2);
          
-         routed = office1.route(ref1, "topic2", null);         
+         routed = office1.route(ref1, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
-         routed = office1.route(ref2, "topic2", null);         
+         routed = office1.route(ref2, new SimpleCondition("topic2"), null);         
          assertTrue(routed);
          
          Thread.sleep(1000);
@@ -2242,13 +2301,18 @@
       
       ClusterRouterFactory rf = new DefaultRouterFactory();
       
+      FailoverMapper mapper = new DefaultFailoverMapper();
+      
+      ConditionFactory cf = new SimpleConditionFactory();
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId,
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),
-                                 5000, 5000, pullPolicy, rf, 1000);
+                                 5000, 5000, pullPolicy, rf, mapper, 1000);
       
       postOffice.start();      
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,13 +25,18 @@
 
 import org.jboss.messaging.core.FilterFactory;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
@@ -124,27 +129,27 @@
          office6 = createClusteredPostOffice(6, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office2.bindClusteredQueue("topic", queue1);
+         Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office3.bindClusteredQueue("topic", queue2);
+         Binding binding2 = office3.bindClusteredQueue(new SimpleCondition("topic"), queue2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office4.bindClusteredQueue("topic", queue3);
+         Binding binding3 = office4.bindClusteredQueue(new SimpleCondition("topic"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office5.bindClusteredQueue("topic", queue4);
+         Binding binding4 = office5.bindClusteredQueue(new SimpleCondition("topic"), queue4);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office6.bindClusteredQueue("topic", queue5);
+         Binding binding5 = office6.bindClusteredQueue(new SimpleCondition("topic"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
                
@@ -265,27 +270,27 @@
          office6 = createClusteredPostOffice(6, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office2.bindClusteredQueue("topic", queue1);
+         Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office3.bindClusteredQueue("topic", queue2);
+         Binding binding2 = office3.bindClusteredQueue(new SimpleCondition("topic"), queue2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office4.bindClusteredQueue("topic", queue3);
+         Binding binding3 = office4.bindClusteredQueue(new SimpleCondition("topic"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office5.bindClusteredQueue("topic", queue4);
+         Binding binding4 = office5.bindClusteredQueue(new SimpleCondition("topic"), queue4);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office6.bindClusteredQueue("topic", queue5);
+         Binding binding5 = office6.bindClusteredQueue(new SimpleCondition("topic"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
                
@@ -378,13 +383,18 @@
       
       ClusterRouterFactory rf = new DefaultRouterFactory();
       
+      FailoverMapper mapper = new DefaultFailoverMapper();
+      
+      ConditionFactory cf = new SimpleConditionFactory();      
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId,
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),
-                                 5000, 5000, redistPolicy, rf, 1000);
+                                 5000, 5000, redistPolicy, rf, mapper, 1000);
       
       postOffice.start();      
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,7 +24,6 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
-
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.Filter;
@@ -35,16 +34,20 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouter;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouter;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.QueueStats;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
@@ -353,13 +356,18 @@
       
       ClusterRouterFactory rf = new DefaultRouterFactory();
       
+      FailoverMapper mapper = new DefaultFailoverMapper();
+      
+      ConditionFactory cf = new SimpleConditionFactory();      
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, 
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),
-                                 5000, 5000, redistPolicy, rf, 1000);
+                                 5000, 5000, redistPolicy, rf, mapper, 1000);
       
       postOffice.start();      
       

Copied: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java)

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -27,15 +27,20 @@
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.NullMessagePullPolicy;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionException;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
@@ -98,15 +103,15 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("topic1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding3 =
-            office3.bindClusteredQueue("topic1", queue3);
+            office3.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -129,7 +134,7 @@
             
             MessageReference ref = ms.reference(msg);  
             
-            office1.route(ref, "topic1", tx);
+            office1.route(ref, new SimpleCondition("topic1"), tx);
          }
          
          Thread.sleep(1000);
@@ -233,15 +238,15 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("topic1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("topic1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding3 =
-            office3.bindClusteredQueue("topic1", queue3);
+            office3.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -264,7 +269,7 @@
             
             MessageReference ref = ms.reference(msg);  
             
-            office1.route(ref, "topic1", tx);
+            office1.route(ref, new SimpleCondition("topic1"), tx);
          }
          
          Thread.sleep(1000);
@@ -355,13 +360,18 @@
       
       ClusterRouterFactory rf = new DefaultRouterFactory();
       
+      FailoverMapper mapper = new DefaultFailoverMapper();
+      
+      ConditionFactory cf = new SimpleConditionFactory();            
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered",
+                                 ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),
-                                 5000, 5000, redistPolicy, rf, 1000);
+                                 5000, 5000, redistPolicy, rf, mapper, 1000);
       
       postOffice.start();      
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -34,14 +34,19 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.messaging.core.plugin.contract.ConditionFactory;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.ClusterRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
+import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultFailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultMessagePullPolicy;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultRouterFactory;
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.MessagePullPolicy;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.test.messaging.core.SimpleCondition;
+import org.jboss.test.messaging.core.SimpleConditionFactory;
 import org.jboss.test.messaging.core.SimpleFilterFactory;
 import org.jboss.test.messaging.core.SimpleReceiver;
 import org.jboss.test.messaging.core.plugin.base.PostOfficeTestBase;
@@ -141,18 +146,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -235,18 +240,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -335,18 +340,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -431,18 +436,18 @@
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding1 =
-            office1.bindClusteredQueue("queue1", queue1);
+            office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
          Binding binding2 =
-            office2.bindClusteredQueue("queue1", queue2);
+            office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
          Message msg = CoreMessageFactory.createCoreMessage(1);   
          msg.setReliable(true);
          
          MessageReference ref = ms.reference(msg);  
          
-         office1.route(ref, "queue1", null);
+         office1.route(ref, new SimpleCondition("queue1"), null);
                   
          Thread.sleep(2000);
          
@@ -529,19 +534,19 @@
          office5 = (DefaultClusteredPostOffice)createClusteredPostOffice(5, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
                   
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                   
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office3.bindClusteredQueue("queue1", queue3);         
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);         
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office4.bindClusteredQueue("queue1", queue4);
+         Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
                   
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office5.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
                    
          final int NUM_MESSAGES = 100;
          
@@ -689,19 +694,19 @@
          office5 = (DefaultClusteredPostOffice)createClusteredPostOffice(5, "testgroup");
          
          LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding1 = office1.bindClusteredQueue("queue1", queue1);
+         Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
                   
          LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding2 = office2.bindClusteredQueue("queue1", queue2);
+         Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                   
          LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding3 = office3.bindClusteredQueue("queue1", queue3);         
+         Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);         
          
          LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding4 = office4.bindClusteredQueue("queue1", queue4);
+         Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
                   
          LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
-         Binding binding5 = office5.bindClusteredQueue("queue1", queue5);
+         Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
                   
          final int NUM_MESSAGES = 100;
           
@@ -1146,13 +1151,18 @@
       
       ClusterRouterFactory rf = new DefaultRouterFactory();
       
+      FailoverMapper mapper = new DefaultFailoverMapper();
+      
+      ConditionFactory cf = new SimpleConditionFactory();           
+      
       DefaultClusteredPostOffice postOffice = 
          new DefaultClusteredPostOffice(sc.getDataSource(), sc.getTransactionManager(),
-                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId, "Clustered", ms, pm, tr, ff, pool,
+                                 sc.getClusteredPostOfficeSQLProperties(), true, nodeId,
+                                 "Clustered", ms, pm, tr, ff, cf, pool,
                                  groupName,
                                  JGroupsUtil.getControlStackProperties(),
                                  JGroupsUtil.getDataStackProperties(),
-                                 10000, 10000, pullPolicy, rf, 1000);
+                                 10000, 10000, pullPolicy, rf, mapper, 1000);
       
       postOffice.start();      
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,6 +21,7 @@
   */
 package org.jboss.test.messaging.jms;
 
+import EDU.oswego.cs.dl.util.concurrent.Latch;
 import javax.jms.Connection;
 import javax.jms.DeliveryMode;
 import javax.jms.Destination;
@@ -37,13 +38,10 @@
 import javax.jms.TopicSubscriber;
 import javax.management.ObjectName;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
-import EDU.oswego.cs.dl.util.concurrent.Latch;
-
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  *
@@ -113,6 +111,7 @@
       try
       {
          conn = cf.createTopicConnection();
+         System.out.println("******   ClientID = " + conn.getClientID());
          TopicSession sess = conn.createTopicSession(true, 0);
          TopicPublisher pub = sess.createPublisher(topic);
          pub.setDeliveryMode(DeliveryMode.PERSISTENT);
@@ -437,9 +436,11 @@
 	public void testIndividualClientAcknowledge() throws Exception
    {
 		
-		Connection conn = cf.createConnection();     
-		
-		Session producerSess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+		Connection conn = cf.createConnection();
+      for (int i=0; i<20; i++) System.out.println("*******************************************");
+      System.out.println("clientID = " + conn.getClientID());
+
+      Session producerSess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
 		MessageProducer producer = producerSess.createProducer(queue);
 		
 		Session consumerSess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -379,7 +379,30 @@
       conn.close();
 
    }
-
+   
+   /*
+    * See http://jira.jboss.com/jira/browse/JBMESSAGING-635
+    * 
+    * This needs to be run remotely to see the exception
+    */
+   public void testConnectionListenerBug() throws Exception
+   {
+      for (int i = 0; i < 500; i++)
+      {
+         Connection conn = cf.createConnection();
+         
+         MyExceptionListener listener = new MyExceptionListener();
+         
+         conn.setExceptionListener(listener);
+         
+         conn.close();        
+         
+         //The problem with this test is I would need to capture the output and search
+         //for NullPointerException!!!
+                  
+      } 
+   }
+   
    // TODO - Decide if valid and uncomment or get rid of it!
 
 //   Commented out for now, since how can i make the server fail from a test?   

Modified: trunk/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/DurableSubscriberTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -133,12 +133,15 @@
 
       conn.start();
 
-      TextMessage tm = (TextMessage)durable.receive();
+      TextMessage tm = (TextMessage)durable.receive(1000);
       assertEquals("k", tm.getText());
 
       Message m = durable.receive(1000);
       assertNull(m);
+      
+      conn.close();
    }
+      
 
    /**
     * JMS 1.1 6.11.1: A client can change an existing durable subscription by creating a durable
@@ -184,6 +187,8 @@
 
       ServerManagement.undeployTopic("CompletelyNewTopic");
       ServerManagement.undeployTopic("CompletelyNewTopic2");
+      
+      conn.close();
    }
 
    /**
@@ -258,6 +263,8 @@
       assertNull(m);
       
       ServerManagement.undeployTopic("CompletelyNewTopic2");
+      
+      conn.close();
    }
 
    /**
@@ -462,6 +469,8 @@
       {
          // OK
       }
+      
+      c.close();
    }
 
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -88,6 +88,11 @@
       super.tearDown();
    }
    
+   public void testNoop() throws Exception
+   {
+      log.info("noop");
+   }
+
    public void test_NonPersistent_NonTransactional() throws Exception
    {
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");

Modified: trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,38 +21,17 @@
   */
 package org.jboss.test.messaging.jms;
 
+import EDU.oswego.cs.dl.util.concurrent.Latch;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
-
-import javax.jms.BytesMessage;
-import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
-import javax.jms.DeliveryMode;
-import javax.jms.InvalidDestinationException;
-import javax.jms.JMSException;
-import javax.jms.MapMessage;
-import javax.jms.Message;
-import javax.jms.MessageConsumer;
-import javax.jms.MessageListener;
-import javax.jms.MessageProducer;
-import javax.jms.ObjectMessage;
-import javax.jms.Queue;
-import javax.jms.QueueReceiver;
-import javax.jms.Session;
-import javax.jms.StreamMessage;
-import javax.jms.TextMessage;
-import javax.jms.Topic;
-import javax.jms.TopicSubscriber;
+import javax.jms.*;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.destination.JBossTopic;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
-import EDU.oswego.cs.dl.util.concurrent.Latch;
-
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java)

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java)

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,21 +22,15 @@
 package org.jboss.test.messaging.jms.clustering;
 
 import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
 import javax.jms.DeliveryMode;
 import javax.jms.Message;
 import javax.jms.MessageConsumer;
 import javax.jms.MessageListener;
 import javax.jms.MessageProducer;
-import javax.jms.Queue;
 import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.jms.Topic;
-import javax.naming.Context;
-import javax.naming.InitialContext;
 
-import org.jboss.test.messaging.MessagingTestCase;
-import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 
 /**
  * 
@@ -50,249 +44,99 @@
  * $Id$
  *
  */
-public class ManualClusteringTest extends MessagingTestCase
+public class ManualClusteringTest extends ClusteringTestBase
 {
-   protected Context ic1;
-   
-   protected Context ic2;
-   
-   protected Context ic3;
-   
-   protected Queue queue1;
-   
-   protected Topic topic1;
-   
-   protected Queue queue2;
-   
-   protected Topic topic2;
-   
-   protected Queue queue3;
-   
-   protected Topic topic3;
-   
-   protected ConnectionFactory cf1;
-   
-   protected ConnectionFactory cf2;
-   
-   protected ConnectionFactory cf3;
-     
+
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
    public ManualClusteringTest(String name)
    {
       super(name);
    }
-   
 
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-      
-      try
-      {
-                     
-         ServerManagement.start("all", 0, true);
-         
-         ServerManagement.start("all", 1, true);
-         
-         ServerManagement.start("all", 2, true);
-         
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 0);         
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 0);
-         
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 1);         
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 1);
-         
-         ServerManagement.deployClusteredQueue("testDistributedQueue", 2);         
-         ServerManagement.deployClusteredTopic("testDistributedTopic", 2);
-               
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         
-         ic3 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-               
-         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
-         
-         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-         
-         queue3 = (Queue)ic3.lookup("queue/testDistributedQueue");
-               
-         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
-         
-         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-         
-         topic3 = (Topic)ic3.lookup("topic/testDistributedTopic");
-         
-         cf1 = (ConnectionFactory)ic1.lookup("/ConnectionFactory");
-         
-         cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
-         
-         cf3 = (ConnectionFactory)ic3.lookup("/ConnectionFactory");
-         
-         drainQueues();
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
-   }
+   // Public --------------------------------------------------------
 
-   protected void tearDown() throws Exception
-   {
-      try
-      {
-         super.tearDown();
-         
-         ServerManagement.undeployQueue("testDistributedQueue", 0);         
-         ServerManagement.undeployTopic("testDistributedTopic", 0);
-         
-         ServerManagement.undeployQueue("testDistributedQueue", 1);         
-         ServerManagement.undeployTopic("testDistributedTopic", 1);
-         
-         ServerManagement.undeployQueue("testDistributedQueue", 2);         
-         ServerManagement.undeployTopic("testDistributedTopic", 2);
-         
-         ic1.close();
-         
-         ic2.close();
-         
-         ic3.close();                  
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
-   }
-   
-   protected void drainQueues() throws Exception
-   {
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-            
-      try
-      {
-         conn1 = cf1.createConnection();
-         
-         conn2 = cf2.createConnection();
-         
-         conn3 = cf3.createConnection();
-           
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         MessageConsumer cons1 = sess1.createConsumer(queue1);
-         
-         MessageConsumer cons2 = sess2.createConsumer(queue2);
-         
-         MessageConsumer cons3 = sess3.createConsumer(queue3);
-         
-         conn1.start();
-         
-         conn2.start();
-         
-         conn3.start();
-         
-         Message msg = null;
-         
-         do
-         {
-            msg = cons1.receive(1000);
-         }
-         while (msg != null);
-         
-         do
-         {
-            msg = cons2.receive(1000);
-         }
-         while (msg != null);
-         
-         do
-         {
-            msg = cons3.receive(1000);
-         }
-         while (msg != null);
-      }
-      finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
-      }
-   }
-    
-   
    public void testClusteredQueueLocalConsumerNonPersistent() throws Exception
    {
       clusteredQueueLocalConsumer(false);
    }
-   
+
    public void testClusteredQueueLocalConsumerPersistent() throws Exception
    {
       clusteredQueueLocalConsumer(true);
    }
-        
+
    public void testClusteredTopicNonDurableNonPersistent() throws Exception
    {
       clusteredTopicNonDurable(false);
    }
-   
+
    public void testClusteredTopicNonDurablePersistent() throws Exception
    {
       clusteredTopicNonDurable(true);
    }
-      
+
    public void testClusteredTopicNonDurableWithSelectorsNonPersistent() throws Exception
    {
       clusteredTopicNonDurableWithSelectors(false);
    }
-   
+
    public void testClusteredTopicNonDurableWithSelectorsPersistent() throws Exception
    {
       clusteredTopicNonDurableWithSelectors(true);
    }
-   
+
    public void testClusteredTopicDurableNonPersistent() throws Exception
    {
       clusteredTopicDurable(false);
    }
-   
+
    public void testClusteredTopicDurablePersistent() throws Exception
    {
       clusteredTopicDurable(true);
    }
-   
+
    public void testClusteredTopicSharedDurableLocalConsumerNonPersistent() throws Exception
    {
       clusteredTopicSharedDurableLocalConsumer(false);
    }
-   
+
    public void testClusteredTopicSharedDurableLocalConsumerPersistent() throws Exception
    {
       clusteredTopicSharedDurableLocalConsumer(true);
    }
-   
+
    public void testClusteredTopicSharedDurableNoLocalSubNonPersistent() throws Exception
    {
       clusteredTopicSharedDurableNoLocalSub(false);
    }
-   
+
    public void testClusteredTopicSharedDurableNoLocalSubPersistent() throws Exception
    {
       clusteredTopicSharedDurableNoLocalSub(true);
    }
-   
-   
-   
-   
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+  
+
    /*
     * Create a consumer on each queue on each node.
     * Send messages in turn from all nodes.
@@ -301,307 +145,319 @@
    protected void clusteredQueueLocalConsumer(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
       Connection conn2 = null;
-      
       Connection conn3 = null;
+
       try
       {
-         conn1 = cf1.createConnection();
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
-         conn2 = cf2.createConnection();
+         log.info("Created connections");
          
-         conn3 = cf3.createConnection();
-           
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
-         MessageConsumer cons1 = sess1.createConsumer(queue1);
+         log.info("Created sessions");
+
+         MessageConsumer cons1 = sess1.createConsumer(queue0);
+         MessageConsumer cons2 = sess2.createConsumer(queue1);
+         MessageConsumer cons3 = sess3.createConsumer(queue2);
          
-         MessageConsumer cons2 = sess2.createConsumer(queue2);
-         
-         MessageConsumer cons3 = sess3.createConsumer(queue3);
-         
+         log.info("Created consumers");
+
          conn1.start();
-         
          conn2.start();
-         
          conn3.start();
-         
-         //Send at node1
-         
-         MessageProducer prod1 = sess1.createProducer(queue1);
-         
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(queue0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
-            prod1.send(tm);
+
+            prod.send(tm);
          }
          
+         log.info("Sent messages");
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
             
             assertEquals("message" + i, tm.getText());
-         }
-         
+         }                 
+
          Message m = cons2.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
-         // Send at node2
-         
-         MessageProducer prod2 = sess2.createProducer(queue2);
-         
-         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 1
+
+         MessageProducer prod1 = sess2.createProducer(queue1);
+
+         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess2.createTextMessage("message" + i);
-            
-            prod2.send(tm);
+
+            prod1.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
-         // Send at node3
-         
-         MessageProducer prod3 = sess3.createProducer(queue3);
-         
-         prod3.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 2
+
+         MessageProducer prod2 = sess3.createProducer(queue2);
+
+         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess3.createTextMessage("message" + i);
-            
-            prod3.send(tm);
+
+            prod2.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons2.receive(2000);
-         
-         assertNull(m);         
+
+         assertNull(m);
       }
       finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
-   
-   
+
+   // Private -------------------------------------------------------
+
    /*
     * Create non durable subscriptions on all nodes of the cluster.
     * Ensure all messages are receive as appropriate
     */
-   public void clusteredTopicNonDurable(boolean persistent) throws Exception
+   private void clusteredTopicNonDurable(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
       Connection conn2 = null;
-      
       Connection conn3 = null;
       try
       {
-         conn1 = cf1.createConnection();
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
-         conn2 = cf2.createConnection();
+         log.info("Created connections");
          
-         conn3 = cf3.createConnection();
-           
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         MessageConsumer cons1 = sess1.createConsumer(topic1);
-         
-         MessageConsumer cons2 = sess2.createConsumer(topic2);
-         
-         MessageConsumer cons3 = sess3.createConsumer(topic3);
-         
-         MessageConsumer cons4 = sess1.createConsumer(topic1);
-         
-         MessageConsumer cons5 = sess2.createConsumer(topic2);
-            
+
+         MessageConsumer cons1 = sess1.createConsumer(topic0);
+         MessageConsumer cons2 = sess2.createConsumer(topic1);
+         MessageConsumer cons3 = sess3.createConsumer(topic2);
+
+         MessageConsumer cons4 = sess1.createConsumer(topic0);
+
+         MessageConsumer cons5 = sess2.createConsumer(topic1);
+
          conn1.start();
-         
          conn2.start();
-         
          conn3.start();
-         
-         //Send at node1
-         
-         MessageProducer prod1 = sess1.createProducer(topic1);
-         
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
-            prod1.send(tm);
+
+            prod.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-                        
-            assertEquals("message" + i, tm.getText());                        
+
+            assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-                      
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons4.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons5.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
+         }
       }
       finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
-   
-   
-   
-   
+
    /*
     * Create non durable subscriptions on all nodes of the cluster.
     * Include some with selectors
     * Ensure all messages are receive as appropriate
     */
-   public void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
+   private void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
       Connection conn2 = null;
-      
       Connection conn3 = null;
+
       try
       {
-         conn1 = cf1.createConnection();
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
-         conn2 = cf2.createConnection();
+         log.info("Created connections");
          
-         conn3 = cf3.createConnection();
-                             
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         MessageConsumer cons1 = sess1.createConsumer(topic1);
-         
-         MessageConsumer cons2 = sess2.createConsumer(topic2);
-         
-         MessageConsumer cons3 = sess3.createConsumer(topic3);
-         
-         MessageConsumer cons4 = sess1.createConsumer(topic1, "COLOUR='red'");
-         
-         MessageConsumer cons5 = sess2.createConsumer(topic2, "COLOUR='blue'");
-            
+
+         MessageConsumer cons1 = sess1.createConsumer(topic0);
+         MessageConsumer cons2 = sess2.createConsumer(topic1);
+         MessageConsumer cons3 = sess3.createConsumer(topic2);
+
+         MessageConsumer cons4 = sess1.createConsumer(topic0, "COLOUR='red'");
+
+         MessageConsumer cons5 = sess2.createConsumer(topic1, "COLOUR='blue'");
+
          conn1.start();
-         
          conn2.start();
-         
          conn3.start();
-         
-         //Send at node1
-         
-         MessageProducer prod1 = sess1.createProducer(topic1);
-         
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
+
             int c = i % 3;
             if (c == 0)
             {
@@ -611,422 +467,423 @@
             {
                tm.setStringProperty("COLOUR", "blue");
             }
-            
-            prod1.send(tm);
+
+            prod.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-                        
-            assertEquals("message" + i, tm.getText());                        
+
+            assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-                      
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             int c = i % 3;
-            
+
             if (c == 0)
             {
                TextMessage tm = (TextMessage)cons4.receive(1000);
-                           
+
                assertNotNull(tm);
-                
+
                assertEquals("message" + i, tm.getText());
             }
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             int c = i % 3;
-            
+
             if (c == 1)
             {
                TextMessage tm = (TextMessage)cons5.receive(1000);
-                           
+
                assertNotNull(tm);
-                
+
                assertEquals("message" + i, tm.getText());
             }
-         } 
+         }
       }
       finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
-   
-   
-   
+
+
+
    /*
     * Create durable subscriptions on all nodes of the cluster.
     * Include a couple with selectors
     * Ensure all messages are receive as appropriate
     * None of the durable subs are shared
     */
-   public void clusteredTopicDurable(boolean persistent) throws Exception
+   private void clusteredTopicDurable(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
       Connection conn2 = null;
-      
       Connection conn3 = null;
       try
       {
-         conn1 = cf1.createConnection();
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
-         conn2 = cf2.createConnection();
+         log.info("Created connections");
          
-         conn3 = cf3.createConnection();
-         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
          conn1.setClientID("wib1");
-         
          conn2.setClientID("wib1");
-         
          conn3.setClientID("wib1");
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-                  
-         try         
+
+         try
          {
-            sess1.unsubscribe("sub1");
+            sess1.unsubscribe("sub");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess2.unsubscribe("sub2");
+            sess2.unsubscribe("sub1");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess3.unsubscribe("sub3");
+            sess3.unsubscribe("sub2");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess1.unsubscribe("sub4");
+            sess1.unsubscribe("sub3");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess2.unsubscribe("sub5");
+            sess2.unsubscribe("sub4");
          }
          catch (Exception ignore) {}
-         
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
-         
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub2");
-         
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub3");
-         
-         MessageConsumer cons4 = sess1.createDurableSubscriber(topic1, "sub4");
-         
-         MessageConsumer cons5 = sess2.createDurableSubscriber(topic2, "sub5");
-            
+
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub1");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub2");
+         MessageConsumer cons4 = sess1.createDurableSubscriber(topic0, "sub3");
+         MessageConsumer cons5 = sess2.createDurableSubscriber(topic1, "sub4");
+
          conn1.start();
-         
          conn2.start();
-         
          conn3.start();
-         
-         //Send at node1
-         
-         MessageProducer prod1 = sess1.createProducer(topic1);
-         
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess1.createTextMessage("message" + i);
-            
-            prod1.send(tm);
+            TextMessage tm = sess2.createTextMessage("message" + i);
+
+            prod.send(tm);
          }
-            
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-                        
-            assertEquals("message" + i, tm.getText());                        
+
+            assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-                      
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons4.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons5.receive(1000);
-                        
+
             assertNotNull(tm);
-             
+
             assertEquals("message" + i, tm.getText());
-         } 
-         
+         }
+
          cons1.close();
-         
          cons2.close();
-         
          cons3.close();
-         
          cons4.close();
-         
          cons5.close();
-         
-         sess1.unsubscribe("sub1");
-         
-         sess2.unsubscribe("sub2");
-         
-         sess3.unsubscribe("sub3");
-         
-         sess1.unsubscribe("sub4");
-         
-         sess2.unsubscribe("sub5");
-         
+
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub1");
+         sess3.unsubscribe("sub2");
+         sess1.unsubscribe("sub3");
+         sess2.unsubscribe("sub4");
+
       }
       finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
-   
-   
-   
-   
+
+
+
+
    /*
     * Create shared durable subs on multiple nodes, the local instance should always get the message
     */
    protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
       Connection conn2 = null;
-      
       Connection conn3 = null;
       try
+
       {
-         conn1 = cf1.createConnection();
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
-         conn2 = cf2.createConnection();
+         log.info("Created connections");
          
-         conn3 = cf3.createConnection();
-         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
          conn1.setClientID("wib1");
-         
          conn2.setClientID("wib1");
-         
          conn3.setClientID("wib1");
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         try         
+
+         try
          {
-            sess1.unsubscribe("sub1");
+            sess1.unsubscribe("sub");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess2.unsubscribe("sub1");
+            sess2.unsubscribe("sub");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess3.unsubscribe("sub1");
+            sess3.unsubscribe("sub");
          }
          catch (Exception ignore) {}
-         
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic1, "sub1");
-         
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
-         
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub1");
-         
+
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub");
+
          conn1.start();
-         
          conn2.start();
-         
          conn3.start();
-         
-         //Send at node1
-         
-         MessageProducer prod1 = sess1.createProducer(topic1);
-         
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
-            prod1.send(tm);
+
+            prod.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons1.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          Message m = cons2.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
-         // Send at node2
-         
-         MessageProducer prod2 = sess2.createProducer(topic2);
-         
-         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 1
+
+         MessageProducer prod1 = sess2.createProducer(topic1);
+
+         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess2.createTextMessage("message" + i);
-            
-            prod2.send(tm);
+            TextMessage tm = sess3.createTextMessage("message" + i);
+
+            prod1.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons2.receive(1000);
-            
+
             assertNotNull(tm);
-               
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons3.receive(2000);
-         
+
          assertNull(m);
-         
-         // Send at node3
-         
-         MessageProducer prod3 = sess3.createProducer(topic3);
-         
-         prod3.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 2
+
+         MessageProducer prod2 = sess3.createProducer(topic2);
+
+         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess3.createTextMessage("message" + i);
-            
-            prod3.send(tm);
+
+            prod2.send(tm);
          }
-           
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons3.receive(1000);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i, tm.getText());
          }
-         
+
          m = cons1.receive(2000);
-         
+
          assertNull(m);
-         
+
          m = cons2.receive(2000);
-         
-         assertNull(m);         
-         
+
+         assertNull(m);
+
          cons1.close();
-         
          cons2.close();
-         
          cons3.close();
-         
-         //Need to unsubscribe on any node that the durable sub was created on
-         
-         sess1.unsubscribe("sub1");
-         
-         sess2.unsubscribe("sub1");
-         
-         sess3.unsubscribe("sub1");
+
+         // Need to unsubscribe on any node that the durable sub was created on
+
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub");
+         sess3.unsubscribe("sub");
       }
       finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
-   
-   
-   
+
+
+
    /*
     * Create shared durable subs on multiple nodes, but without sub on local node
     * should round robin
@@ -1035,105 +892,110 @@
    protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
    {
       Connection conn1 = null;
-      
       Connection conn2 = null;
-      
       Connection conn3 = null;
+
       try
       {
-         conn1 = cf1.createConnection();
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
          
-         conn2 = cf2.createConnection();
+         log.info("Created connections");
          
-         conn3 = cf3.createConnection();
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
          
          conn2.setClientID("wib1");
-         
          conn3.setClientID("wib1");
-           
+
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         try         
+
+         try
          {
-            sess2.unsubscribe("sub1");
+            sess2.unsubscribe("sub");
          }
          catch (Exception ignore) {}
-         try         
+         try
          {
-            sess3.unsubscribe("sub1");
+            sess3.unsubscribe("sub");
          }
          catch (Exception ignore) {}
-                  
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic2, "sub1");
-         
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic3, "sub1");
-         
+
+         MessageConsumer cons1 = sess2.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons2 = sess3.createDurableSubscriber(topic2, "sub");
+
          conn2.start();
-         
          conn3.start();
-         
-         //Send at node1
-         
-         //Should round robin between the other 2 since there is no active consumer on sub1 on node1
-         
-         MessageProducer prod1 = sess1.createProducer(topic1);
-         
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-         
+
+         // Send at node 0
+
+         //Should round robin between the other 2 since there is no active consumer on sub  on node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess1.createTextMessage("message" + i);
-            
-            prod1.send(tm);
+
+            prod.send(tm);
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-            
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + i * 2, tm.getText());
          }
-         
+
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-            
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
             assertNotNull(tm);
-            
+
             assertEquals("message" + (i * 2 + 1), tm.getText());
          }
-         
+
+         cons1.close();
          cons2.close();
-         
-         cons3.close();
-         
-         sess2.unsubscribe("sub1");
-         
-         sess3.unsubscribe("sub1");
-      
+
+         sess2.unsubscribe("sub");
+         sess3.unsubscribe("sub");
+
       }
       finally
-      {      
-         if (conn1 != null) conn1.close();
-         
-         if (conn2 != null) conn2.close();
-         
-         if (conn3 != null) conn3.close();
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
       }
    }
 
    class MyListener implements MessageListener
    {
       private int i;
-      
+
       MyListener(int i)
       {
          this.i = i;
@@ -1144,7 +1006,7 @@
          try
          {
             int count = m.getIntProperty("count");
-            
+
             log.info("Listener " + i + " received message " + count);
          }
          catch (Exception e)
@@ -1152,7 +1014,12 @@
             e.printStackTrace();
          }
       }
-      
+
    }
+
+
+   // Inner classes -------------------------------------------------
+
    
+
 }

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java)

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base)

Deleted: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -1,267 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering.base;
-
-import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
-import javax.jms.Message;
-import javax.jms.MessageConsumer;
-import javax.jms.Queue;
-import javax.jms.Session;
-import javax.jms.Topic;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.test.messaging.MessagingTestCase;
-import org.jboss.test.messaging.tools.ServerManagement;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- * $Id:$
- */
-public class ClusteringTestBase extends MessagingTestCase
-{
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   protected Context ic0;
-   protected Context ic1;
-   protected Context ic2;
-
-   protected Queue queue0;
-   protected Queue queue1;
-   protected Queue queue2;
-
-   protected Topic topic0;
-   protected Topic topic1;
-   protected Topic topic2;
-
-   //No need to have 3 conncetion factories since a clustered connection factory
-   //will create connections in a round robin fashion on different servers
-   protected ConnectionFactory cf;
-
-   // Constructors --------------------------------------------------
-
-   public ClusteringTestBase(String name)
-   {
-      super(name);
-   }
-
-   // Public --------------------------------------------------------
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-
-      String banner =
-         "####################################################### Start " +
-         (isRemote() ? "REMOTE" : "IN-VM") + " test: " + getName();
-
-      ServerManagement.log(ServerManagement.INFO,banner);
-
-      try
-      {
-         startServer(0);
-         startServer(1);
-         startServer(2);
-
-         log.info("Deployed destinations ok");
-
-         ic0 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
-
-         //We only need to lookup one connection factory since it will be a clustered cf
-         //so we will actually create connections on different servers (round robin)
-         cf = (ConnectionFactory)ic0.lookup("/ConnectionFactory");
-
-         queue0 = (Queue)ic0.lookup("queue/testDistributedQueue");
-         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
-         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-
-         topic0 = (Topic)ic0.lookup("topic/testDistributedTopic");
-         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
-         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-
-         drainQueues();
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
-   }
-
-   protected void tearDown() throws Exception
-   {
-      try
-      {
-
-         if (ServerManagement.getServer(0).isStarted())
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0", 0);
-            ServerManagement.undeployQueue("testDistributedQueue", 0);
-            ServerManagement.undeployTopic("testDistributedTopic", 0);
-         }
-
-         if (ServerManagement.getServer(1).isStarted())
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1", 1);
-            ServerManagement.undeployQueue("testDistributedQueue", 1);
-            ServerManagement.undeployTopic("testDistributedTopic", 1);
-         }
-
-         if (ServerManagement.getServer(2).isStarted())
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2", 2);
-            ServerManagement.undeployQueue("testDistributedQueue", 2);
-            ServerManagement.undeployTopic("testDistributedTopic", 2);
-         }
-
-         ic0.close();
-         ic1.close();
-         ic2.close();
-
-         super.tearDown();
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
-   }
-
-   protected void checkConnectionsDifferentServers(Connection conn, Connection conn1, Connection conn2)
-   {
-      ConnectionState state0 =
-         (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
-      ConnectionState state1 =
-         (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-      ConnectionState state2 =
-         (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-
-      int serverID0 = state0.getServerID();
-      int serverID1 = state1.getServerID();
-      int serverID2 = state2.getServerID();
-
-      log.info("Server 0 ID: " + serverID0);
-      log.info("Server 1 ID: " + serverID1);
-      log.info("Server 2 ID: " + serverID2);
-
-      assertTrue(serverID0 != serverID1);
-      assertTrue(serverID1 != serverID2);
-   }
-
-   protected void drainQueues() throws Exception
-   {
-      Connection conn0 = null;
-      Connection conn1 = null;
-      Connection conn2 = null;
-
-      try
-      {
-         //Since the cf is clustered, this will create connections on 3 different nodes
-         //(round robin)
-         conn0 = cf.createConnection();
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-
-         checkConnectionsDifferentServers(conn0, conn1, conn2);
-
-         Session sess0 = conn0.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         MessageConsumer cons0 = sess0.createConsumer(queue0);
-         MessageConsumer cons1 = sess1.createConsumer(queue1);
-         MessageConsumer cons2 = sess2.createConsumer(queue2);
-
-         conn0.start();
-         conn1.start();
-         conn2.start();
-
-         Message msg = null;
-
-         do
-         {
-            msg = cons0.receive(1000);
-            log.info("1 Drained message " + msg);
-         }
-         while (msg != null);
-
-         do
-         {
-            msg = cons1.receive(1000);
-            log.info("2 Drained message " + msg);
-         }
-         while (msg != null);
-
-         do
-         {
-            msg = cons2.receive(1000);
-            log.info("3 Drained message " + msg);
-         }
-         while (msg != null);
-      }
-      finally
-      {
-         if (conn0 != null)
-         {
-            conn0.close();
-         }
-
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-      }
-   }
-
-   // Private -------------------------------------------------------
-
-   private void startServer(int serverIndex) throws Exception
-   {
-      ServerManagement.start("all", serverIndex);
-      ServerManagement.deployClusteredQueue("testDistributedQueue", serverIndex);
-      ServerManagement.deployClusteredTopic("testDistributedTopic", serverIndex);
-   }
-
-   // Inner classes -------------------------------------------------
-
-}

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java)

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,14 +21,9 @@
   */
 package org.jboss.test.messaging.jms.crash;
 
-import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
-import javax.jms.MessageProducer;
-import javax.jms.Queue;
-import javax.jms.Session;
+import javax.jms.*;
 import javax.management.ObjectName;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -78,7 +73,7 @@
       localServer = new LocalTestServer();
       
       //Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
             
       localServer.deployQueue("Queue", null, false);
            
@@ -121,7 +116,7 @@
       
       String remotingSessionId = (String)remoteServer.executeCommand(command);
       
-      remoteServer.destroy();
+      remoteServer.kill();
         
       //we have removed the exception listener so the server side resouces shouldn't be cleared up
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,7 +24,6 @@
 import javax.jms.ConnectionFactory;
 import javax.jms.Queue;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -74,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       localServer.setAttribute(ServiceContainer.REMOTING_OBJECT_NAME, "LeasePeriod", "30000");
        
@@ -116,7 +115,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,7 +24,6 @@
 import javax.jms.ConnectionFactory;
 import javax.jms.Queue;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -74,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       //Set lease period to -1 --> this should disable leasing so the state won't be cleared up
       
@@ -118,7 +117,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,7 +24,6 @@
 import javax.jms.ConnectionFactory;
 import javax.jms.Queue;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -74,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
       // the default, whatever that is ...
@@ -120,7 +119,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,7 +24,6 @@
 import javax.jms.ConnectionFactory;
 import javax.jms.Topic;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.jms.server.connectionmanager.SimpleConnectionManager;
 import org.jboss.logging.Logger;
@@ -76,7 +75,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
       // the default, whatever that is ...
@@ -122,7 +121,7 @@
       log.info("we have = " + ((SimpleConnectionManager)cm).getClients().size() + " clients registered on SimpleconnectionManager");
       
       // Now we should have a client connection from the remote server to the local server
-      remoteServer.destroy();
+      remoteServer.kill();
       log.info("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,7 +24,6 @@
 import javax.jms.ConnectionFactory;
 import javax.jms.Queue;
 import javax.naming.InitialContext;
-
 import org.jboss.jms.server.ConnectionManager;
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -74,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all", false);
+      localServer.start("all");
 
       //Set lease period to 0 --> this should disable leasing so the state won't be cleared up
       
@@ -118,7 +117,7 @@
       
       // Now we should have a client connection from the remote server to the local server
       
-      remoteServer.destroy();
+      remoteServer.kill();
       log.trace("killed remote server");
         
       // Wait for connection resources to be cleared up

Modified: trunk/tests/src/org/jboss/test/messaging/jms/server/DestinationManagerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/server/DestinationManagerTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/server/DestinationManagerTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,13 +21,10 @@
   */
 package org.jboss.test.messaging.jms.server;
 
-import java.util.Set;
-
 import javax.jms.Queue;
 import javax.jms.Topic;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
-
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.destination.ManagedDestination;

Modified: trunk/tests/src/org/jboss/test/messaging/jms/server/ServerPeerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/server/ServerPeerTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/server/ServerPeerTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,15 +21,14 @@
   */
 package org.jboss.test.messaging.jms.server;
 
-import javax.naming.InitialContext;
-import javax.naming.Context;
-import javax.naming.NameNotFoundException;
 import javax.jms.Queue;
 import javax.jms.Topic;
-
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NameNotFoundException;
+import org.jboss.jms.util.MessagingJMSException;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.jms.util.MessagingJMSException;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,18 +22,9 @@
 package org.jboss.test.messaging.jms.server.destination;
 
 import java.util.List;
-
-import javax.jms.Connection;
-import javax.jms.ConnectionFactory;
-import javax.jms.DeliveryMode;
-import javax.jms.MessageConsumer;
-import javax.jms.MessageProducer;
-import javax.jms.Queue;
-import javax.jms.Session;
-import javax.jms.TextMessage;
+import javax.jms.*;
 import javax.management.ObjectName;
 import javax.naming.InitialContext;
-
 import org.jboss.test.messaging.jms.server.destination.base.DestinationManagementTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -24,10 +24,14 @@
 import java.rmi.Naming;
 import java.util.Hashtable;
 import java.util.Set;
-
+import java.util.HashMap;
+import java.util.Map;
+import java.util.List;
+import java.util.Iterator;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
+import javax.management.Notification;
 import javax.transaction.UserTransaction;
-
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.logging.Logger;
@@ -37,6 +41,7 @@
 import org.jboss.test.messaging.tools.jmx.rmi.LocalTestServer;
 import org.jboss.test.messaging.tools.jmx.rmi.RMITestServer;
 import org.jboss.test.messaging.tools.jmx.rmi.Server;
+import org.jboss.test.messaging.tools.jmx.rmi.NotificationListenerID;
 import org.jboss.test.messaging.tools.jndi.InVMInitialContextFactory;
 import org.jboss.test.messaging.tools.jndi.RemoteInitialContextFactory;
 
@@ -54,6 +59,8 @@
 {
    // Constants -----------------------------------------------------
 
+   public static final int MAX_SERVER_COUNT = 10;
+
    // logging levels used by the remote client to forward log output on a remote server
    public static int FATAL = 0;
    public static int ERROR = 1;
@@ -71,8 +78,11 @@
 
    private static final int RMI_SERVER_LOOKUP_RETRIES = 10;
 
-   private static Server[] servers = new Server[RMITestServer.RMI_REGISTRY_PORTS.length];
+   private static Server[] servers = new Server[MAX_SERVER_COUNT];
 
+   // Map<NotificationListener - NotificationListenerPoller>
+   private static Map notificationListenerPollers = new HashMap();
+
    public static boolean isLocal()
    {
       return !"true".equals(System.getProperty("remote"));
@@ -114,7 +124,7 @@
 
       if (isLocal())
       {
-         servers[index] = new LocalTestServer();
+         servers[index] = new LocalTestServer(index);
          return;
       }
 
@@ -140,10 +150,10 @@
    
    public static synchronized void start(String config) throws Exception
    {
-      start(config, 0, false);
+      start(config, 0);
    }
 
-   public static synchronized void start(String config, int index, boolean clustered) throws Exception
+   public static synchronized void start(String config, int index) throws Exception
    {
       create(index);
 
@@ -158,26 +168,58 @@
       
       MessageIdGeneratorFactory.instance.clear();      
 
-      //Now start the server
-      servers[index].start(config, clustered);
+      // Now start the server
+      servers[index].start(config);
 
       log.debug("server started");
    }
 
    public static synchronized void stop() throws Exception
    {
-      insureStarted();
-      
-      servers[0].stop();      
+      stop(0);
    }
 
+   public static synchronized void stop(int index) throws Exception
+   {
+      if (servers[index] == null)
+      {
+         log.warn("Server " + index + " has not been created, so it cannot be stopped");
+         return;
+      }
+
+      if (!servers[index].isStarted())
+      {
+         log.warn("Server " + index + " either has not been started, or it is stopped already");
+         return;
+      }
+
+      servers[index].stop();
+   }
+
+   /**
+    * TODO - this methods should be removed, to not be confused with kill(index)
+    * @deprecated
+    */
    public static synchronized void destroy() throws Exception
    {
       stop();
+      servers[0].kill();
+      servers[0] = null;
+   }
 
-      servers[0].destroy();
+   /**
+    * Abruptly kills the VM running the specified server.
+    */
+   public static synchronized void kill(int index) throws Exception
+   {
+      if (servers[index] == null)
+      {
+         log.warn("Server " + index + " has not been created, so it cannot be killed");
+         return;
+      }
 
-      servers[0] = null;
+      servers[index].kill();
+      servers[index] = null;
    }
 
    public static void disconnect() throws Exception
@@ -220,6 +262,59 @@
       return servers[0].invoke(on, operationName, params, signature);
    }
 
+   public static void addNotificationListener(int serverIndex, ObjectName on,
+                                              NotificationListener listener) throws Exception
+   {
+      insureStarted(serverIndex);
+
+      if (isLocal())
+      {
+         // add the listener directly to the server
+         servers[serverIndex].addNotificationListener(on, listener);
+      }
+      else
+      {
+         // is remote, need to poll
+         NotificationListenerPoller p =
+            new NotificationListenerPoller((Server)servers[serverIndex], on, listener);
+
+         synchronized(notificationListenerPollers)
+         {
+            notificationListenerPollers.put(listener, p);
+         }
+
+         new Thread(p, "Poller for " + Integer.toHexString(p.hashCode())).start();
+      }
+   }
+
+   public static void removeNotificationListener(int serverIndex, ObjectName on,
+                                                 NotificationListener listener) throws Exception
+   {
+      insureStarted(serverIndex);
+
+      if (isLocal())
+      {
+         // remove the listener directly
+         servers[serverIndex].removeNotificationListener(on, listener);
+      }
+      else
+      {
+         // is remote
+
+         NotificationListenerPoller p = null;
+         synchronized(notificationListenerPollers)
+         {
+            p = (NotificationListenerPoller)notificationListenerPollers.remove(listener);
+         }
+
+         if (p != null)
+         {
+            // stop the polling thread
+            p.stop();
+         }
+      }
+   }
+
    public static Set query(ObjectName pattern) throws Exception
    {
       insureStarted();
@@ -536,12 +631,13 @@
     * Simulates a destination un-deployment (deleting the destination descriptor from the deploy
     * directory).
     */
-   private static void undeployDestination(boolean isQueue, String name, int serverIndex) throws Exception
+   private static void undeployDestination(boolean isQueue, String name, int serverIndex)
+      throws Exception
    {
       insureStarted(serverIndex);
       servers[serverIndex].undeployDestination(isQueue, name);
    }
-
+                                                                                                                
    public static void deployConnectionFactory(String objectName,
                                               String[] jndiBindings,
                                               int prefetchSize,
@@ -580,20 +676,20 @@
 
    public static Hashtable getJNDIEnvironment()
    {
+      return getJNDIEnvironment(0);
+   }
+   
+   public static Hashtable getJNDIEnvironment(int serverIndex)
+   {
       if (isLocal())
       {
-         return InVMInitialContextFactory.getJNDIEnvironment();
+         return InVMInitialContextFactory.getJNDIEnvironment(serverIndex);
       }
       else
       {
-         return getJNDIEnvironment(0);
+         return RemoteInitialContextFactory.getJNDIEnvironment(serverIndex);
       }
    }
-   
-   public static Hashtable getJNDIEnvironment(int index)
-   {
-      return RemoteInitialContextFactory.getJNDIEnvironment(index);      
-   }
 
    // Attributes ----------------------------------------------------
 
@@ -626,17 +722,23 @@
 
    private static Server acquireRemote(int initialRetries, int index)
    {
-      String name = "//localhost:" + RMITestServer.RMI_REGISTRY_PORTS[index] + "/" + RMITestServer.RMI_SERVER_NAME;
+      String name =
+         "//localhost:" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
+         RMITestServer.RMI_SERVER_PREFIX + index;
+
       Server s = null;
       int retries = initialRetries;
+
       while(s == null && retries > 0)
       {
          int attempt = initialRetries - retries + 1;
          try
          {
-            log.info("trying to connect to the remote RMI server" +
+            log.info("trying to connect to the remote RMI server " + index + 
                      (attempt == 1 ? "" : ", attempt " + attempt));
+
             s = (Server)Naming.lookup(name);
+
             log.info("connected to the remote server");
          }
          catch(Exception e)
@@ -796,4 +898,63 @@
 //         }
 //      }
 //   }
+
+   private static long listenerIDCounter = 0;
+
+   static class NotificationListenerPoller implements Runnable
+   {
+      public static final int POLL_INTERVAL = 500;
+
+      private long id;
+      private Server server;
+      private NotificationListener listener;
+      private volatile boolean running;
+
+      private synchronized static long generateID()
+      {
+         return listenerIDCounter++;
+      }
+
+      NotificationListenerPoller(Server server, ObjectName on, NotificationListener listener)
+         throws Exception
+      {
+         id = generateID();
+         this.server = server;
+
+         server.addNotificationListener(on, new NotificationListenerID(id));
+
+         this.listener = listener;
+         this.running = true;
+      }
+
+      public void run()
+      {
+         while(running)
+         {
+            try
+            {
+               List notifications = server.pollNotificationListener(id);
+
+               for(Iterator i = notifications.iterator(); i.hasNext(); )
+               {
+                  Notification n = (Notification)i.next();
+                  listener.handleNotification(n, null);
+               }
+
+               Thread.sleep(POLL_INTERVAL);
+            }
+            catch(Exception e)
+            {
+               log.error(e);
+               stop();
+            }
+         }
+      }
+
+      public void stop()
+      {
+         running = false;
+      }
+   }
+
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -22,12 +22,14 @@
 package org.jboss.test.messaging.tools.jmx;
 
 
+import java.io.ByteArrayInputStream;
+import java.io.InputStream;
 import java.net.URL;
 import java.sql.Connection;
 import java.sql.DriverManager;
-import java.sql.Statement;
 import java.sql.PreparedStatement;
 import java.sql.SQLException;
+import java.sql.Statement;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Hashtable;
@@ -36,9 +38,6 @@
 import java.util.Properties;
 import java.util.Set;
 import java.util.StringTokenizer;
-import java.io.ByteArrayInputStream;
-import java.io.InputStream;
-
 import javax.management.Attribute;
 import javax.management.MBeanAttributeInfo;
 import javax.management.MBeanException;
@@ -46,6 +45,7 @@
 import javax.management.MBeanServer;
 import javax.management.MBeanServerFactory;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
@@ -53,15 +53,17 @@
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
 import javax.transaction.UserTransaction;
-
 import org.hsqldb.Server;
 import org.hsqldb.persist.HsqlProperties;
 import org.jboss.jms.jndi.JNDIProviderAdapter;
+import org.jboss.jms.server.ServerPeer;
+import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
 import org.jboss.jms.util.JNDIUtil;
 import org.jboss.jms.util.XMLUtil;
-import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
-import org.jboss.jms.server.ServerPeer;
 import org.jboss.logging.Logger;
+import org.jboss.remoting.InvokerLocator;
+import org.jboss.remoting.ServerInvocationHandler;
+import org.jboss.remoting.serialization.SerializationStreamFactory;
 import org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory;
 import org.jboss.resource.adapter.jdbc.remote.WrapperDataSourceService;
 import org.jboss.resource.adapter.jms.JmsManagedConnectionFactory;
@@ -76,14 +78,12 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
 import org.jboss.test.messaging.tools.jboss.ServiceDeploymentDescriptor;
+import org.jboss.test.messaging.tools.jndi.Constants;
 import org.jboss.test.messaging.tools.jndi.InVMInitialContextFactory;
 import org.jboss.test.messaging.tools.jndi.InVMInitialContextFactoryBuilder;
 import org.jboss.tm.TransactionManagerLocator;
 import org.jboss.tm.TransactionManagerService;
 import org.jboss.tm.usertx.client.ServerVMClientUserTransaction;
-import org.jboss.remoting.InvokerLocator;
-import org.jboss.remoting.ServerInvocationHandler;
-import org.jboss.remoting.serialization.SerializationStreamFactory;
 
 
 /**
@@ -303,16 +303,19 @@
          //TODO: need to think more about this; if I don't do it, though, bind() fails because it tries to use "java.naming.provider.url"
          try
          {
-            NamingManager.setInitialContextFactoryBuilder(new InVMInitialContextFactoryBuilder());
+            NamingManager.
+               setInitialContextFactoryBuilder(new InVMInitialContextFactoryBuilder());
          }
          catch(IllegalStateException e)
          {
             // OK
          }
 
-         Hashtable t = InVMInitialContextFactory.getJNDIEnvironment();
+         Hashtable t = InVMInitialContextFactory.getJNDIEnvironment(serverIndex);
          System.setProperty("java.naming.factory.initial",
                             (String)t.get("java.naming.factory.initial"));
+         System.setProperty(Constants.SERVER_INDEX_PROPERTY_NAME,
+                            Integer.toString(serverIndex));
 
          initialContext = new InitialContext();
 
@@ -395,10 +398,13 @@
          loadJNDIContexts();
 
          String transport = config.getRemotingTransport();
-         log.info("remoting = \"" +
-            (remoting ? transport : "disabled") + "\", " +
-            "serialization = \"" + config.getSerializationType() + "\", " +
-            "database = \"" + getDatabaseType() + "\"");
+
+         log.info("Remoting type: ........... " + (remoting ? transport : "DISABLED"));
+         log.info("Serialization type: ...... " + config.getSerializationType());
+         log.info("Database: ................ " + config.getDatabaseType());
+         log.info("Clustering mode: ......... " +
+            (this.isClustered() ? "CLUSTERED" : "NON-CLUSTERED"));
+
          log.debug(this + " started");
       }
       catch(Throwable e)
@@ -699,6 +705,18 @@
       return mbeanServer.getAttribute(on, name);
    }
 
+   public void addNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      mbeanServer.addNotificationListener(on, listener, null, null);
+   }
+
+   public void removeNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      mbeanServer.removeNotificationListener(on, listener);
+   }
+
    public void bindDefaultJMSProvider() throws Exception
    {
       JNDIProviderAdapter pa = new JNDIProviderAdapter();
@@ -770,6 +788,11 @@
       return config.getDatabaseType();
    }
 
+   public boolean isClustered()
+   {
+      return config.isClustered();
+   }
+
    public String toString()
    {
       return "ServiceContainer[" + Integer.toHexString(hashCode()) + "]";
@@ -1123,12 +1146,12 @@
       // TODO - use remoting-service.xml parameters, not these ...
 
       String serializationType = config.getSerializationType();
-      
+
       //TODO - Actually serializationType is irrelevant since we pass a
       //DataOutput/InputStream into the marshaller and don't use serialization apart
       //from one specific case with a JMS ObjectMessage in which case Java serialization
       //is always currently used - (we could make this configurable)
-                  
+
       String transport = config.getRemotingTransport();
 
       String params = "/?marshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
@@ -1212,7 +1235,7 @@
    {
       try
       {
-         log.info("************************** Deleting all data from database");
+         log.info("DELETING ALL DATA FROM DATABASE!");
 
          InitialContext ctx = new InitialContext();
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainerConfiguration.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -6,19 +6,18 @@
  */
 package org.jboss.test.messaging.tools.jmx;
 
-import org.w3c.dom.Element;
-import org.w3c.dom.NodeList;
-import org.w3c.dom.Node;
-import org.w3c.dom.NamedNodeMap;
-import org.jboss.jms.util.XMLUtil;
-import org.jboss.jms.util.XMLException;
-
 import java.io.InputStream;
+import java.io.InputStreamReader;
 import java.io.Reader;
-import java.io.InputStreamReader;
+import java.util.HashMap;
+import java.util.Map;
 import java.util.StringTokenizer;
-import java.util.Map;
-import java.util.HashMap;
+import org.jboss.jms.util.XMLException;
+import org.jboss.jms.util.XMLUtil;
+import org.w3c.dom.Element;
+import org.w3c.dom.NamedNodeMap;
+import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -30,6 +29,8 @@
 {
    // Constants -----------------------------------------------------
 
+   public static final boolean DEFAULT_CLUSTERED_MODE = false;
+
    // Static --------------------------------------------------------
 
    public static String getHypersonicDatabase(String connectionURL)
@@ -76,6 +77,7 @@
    private Map dbConfigurations;
    private String serializationType;
    private String remotingTransport;
+   private Boolean clusteredMode;
 
    // Constructors --------------------------------------------------
 
@@ -101,7 +103,7 @@
       {
     	  databaseType="mssql";
       }
-      return databaseType; 
+      return databaseType;
    }
 
    public String getDatabaseConnectionURL()
@@ -150,6 +152,14 @@
       return remotingTransport;
    }
 
+   /**
+    * @return the clustered mode in which the container should run an individual test.
+    */
+   public boolean isClustered()
+   {
+      return clusteredMode.booleanValue();
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -162,6 +172,7 @@
       String currentDatabase = null;
       String currentSerializationType = null;
       String currentRemotingTransport = null;
+      boolean currentClusteredMode = DEFAULT_CLUSTERED_MODE;
 
       try
       {
@@ -204,6 +215,10 @@
                {
                   currentRemotingTransport = XMLUtil.getTextContent(n);
                }
+               else if ("clustered".equals(name))
+               {
+                  currentClusteredMode = Boolean.getBoolean(XMLUtil.getTextContent(n));
+               }
                else
                {
                   throw new Exception("Unexpected child <" + name + "> of node " +
@@ -215,6 +230,7 @@
          setCurrentDatabase(currentDatabase);
          setCurrentSerializationType(currentSerializationType);
          setCurrentRemotingTransport(currentRemotingTransport);
+         setCurrentClusteredMode(currentClusteredMode);
       }
       finally
       {
@@ -236,8 +252,8 @@
    }
 
    /**
-    * Always the value of "test.serialization" system property takes precedence over the c
-    * onfiguration file value.
+    * Always the value of "test.serialization" system property takes precedence over the
+    * configuration file value.
     */
    private void setCurrentSerializationType(String xmlConfigSerializationType)
    {
@@ -258,6 +274,24 @@
    }
    
 
+   /**
+    * Always the value of "test.clustered" system property takes precedence over the configuration
+    * file value.
+    */
+   private void setCurrentClusteredMode(boolean xmlClusteredMode) throws Exception
+   {
+      String s = System.getProperty("test.clustered");
+      if (s != null)
+      {
+         clusteredMode = Boolean.valueOf(s);
+      }
+
+      if (clusteredMode == null)
+      {
+         clusteredMode = new Boolean(xmlClusteredMode);
+      }
+   }
+
    private void validate() throws Exception
    {
       // make sure that I have a corresponding "database-configuration"

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -26,20 +26,18 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Set;
-
 import javax.jms.Destination;
 import javax.jms.Queue;
 import javax.jms.Topic;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
-
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.XMLUtil;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
-import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.tools.jboss.MBeanConfigurationElement;
@@ -47,6 +45,7 @@
 import org.jboss.test.messaging.tools.jmx.MockJBossSecurityManager;
 import org.jboss.test.messaging.tools.jmx.RemotingJMXWrapper;
 import org.jboss.test.messaging.tools.jmx.ServiceContainer;
+import org.jboss.test.messaging.tools.jndi.Constants;
 import org.w3c.dom.Element;
 
 /**
@@ -63,15 +62,24 @@
    private static final Logger log = Logger.getLogger(LocalTestServer.class);
 
    // Static --------------------------------------------------------
-  
+
+   public static void setEnvironmentServerIndex(int serverIndex)
+   {
+      System.setProperty(Constants.SERVER_INDEX_PROPERTY_NAME, Integer.toString(serverIndex));
+   }
+
+   public static void clearEnvironmentServerIndex()
+   {
+      System.getProperty(Constants.SERVER_INDEX_PROPERTY_NAME, null);
+   }
+
    // Attributes ----------------------------------------------------
 
    private ServiceContainer sc;
 
    // service dependencies   
    private ObjectName persistenceManagerObjectName;
-   private ObjectName queuePostOfficeObjectName;
-   private ObjectName topicPostOfficeObjectName;
+   private ObjectName postOfficeObjectName;
    private ObjectName jmsUserManagerObjectName;
 
    // the server MBean itself
@@ -79,7 +87,7 @@
 
    // List<ObjectName>
    private List connFactoryObjectNames;
-   
+
    private int serverIndex;
 
    // Constructors --------------------------------------------------
@@ -90,43 +98,50 @@
 
       connFactoryObjectNames = new ArrayList();
    }
-   
+
    public LocalTestServer(int serverIndex)
    {
       this();
-      
+
       this.serverIndex = serverIndex;
    }
 
    // Server implementation -----------------------------------------
 
-   public synchronized void start(String containerConfig, boolean clustered) throws Exception
+   public synchronized void start(String containerConfig) throws Exception
    {
       if (isStarted())
       {
          return;
       }
-      
+
       log.debug("starting service container");
 
-      sc = new ServiceContainer(containerConfig, null, serverIndex);
-      sc.start();
-      
-      log.info("********* STARTING SERVER DATABASE TYPE IS " + sc.getDatabaseType());
-      
-      if (this.getDatabaseType().equals("hsqldb") && clustered)
+      try
       {
-         throw new IllegalStateException("The test server cannot be started in clustered mode with hsqldb as a database - must use a shared database");
+         setEnvironmentServerIndex(serverIndex);
+
+         sc = new ServiceContainer(containerConfig, null, serverIndex);
+         sc.start();
+
+         if (this.getDatabaseType().equals("hsqldb") && sc.isClustered())
+         {
+            throw new IllegalStateException("The test server cannot be started in clustered mode with hsqldb as a database - must use a shared database");
+         }
+
+         if ("none".equals(containerConfig))
+         {
+            return;
+         }
+
+         startServerPeer(serverIndex, null, null, sc.isClustered());
+
+         log.info("server started");
       }
-
-      if ("none".equals(containerConfig))
+      finally
       {
-         return;
+         clearEnvironmentServerIndex();
       }
-
-      startServerPeer(serverIndex, null, null, clustered);
-
-      log.info("server started");
    }
 
    public synchronized void stop() throws Exception
@@ -136,19 +151,28 @@
          return;
       }
 
-      stopServerPeer();
+      try
+      {
+         setEnvironmentServerIndex(serverIndex);
 
-      log.debug("stopping service container");
+         stopServerPeer();
 
-      sc.stop();
-      sc = null;
+         log.debug("stopping service container");
 
-      log.info("server stopped");
+         sc.stop();
+         sc = null;
+
+         log.info("server stopped");
+      }
+      finally
+      {
+         clearEnvironmentServerIndex();
+      }
    }
 
-   public synchronized void destroy() throws Exception
+   public synchronized void kill() throws Exception
    {
-      stop();
+      throw new IllegalStateException("Cannot KILL a local server. Consider using stop() instead.");
    }
 
    public ObjectName deploy(String mbeanConfiguration) throws Exception
@@ -179,6 +203,18 @@
       return sc.invoke(on, operationName, params, signature);
    }
 
+   public void addNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      sc.addNotificationListener(on, listener);
+   }
+
+   public void removeNotificationListener(ObjectName on, NotificationListener listener)
+      throws Exception
+   {
+      sc.removeNotificationListener(on, listener);
+   }
+
    public Set query(ObjectName pattern) throws Exception
    {
       return sc.query(pattern);
@@ -220,7 +256,7 @@
          // log everything else as INFO
          log.info(text);
       }
-   }   
+   }
 
    public synchronized boolean isStarted() throws Exception
    {
@@ -233,28 +269,28 @@
                                boolean clustered) throws Exception
    {
       try
-      {         
-         log.info("******* STARTING SERVER PEER WITH ID " + serverPeerID);
-         
+      {
+         log.info(" Server peer ID ........... " + serverPeerID);
+
          log.debug("creating ServerPeer instance");
-   
+
          // we are using the "default" service deployment descriptors available in
          // src/etc/server/default/deploy. This will allow to test the default parameters we ship.
-   
+
          String mainConfigFile = "server/default/deploy/messaging-service.xml";
          URL mainConfigFileURL = getClass().getClassLoader().getResource(mainConfigFile);
          if (mainConfigFileURL == null)
          {
             throw new Exception("Cannot find " + mainConfigFile + " in the classpath");
          }
-   
+
          String databaseType = sc.getDatabaseType();
          String persistenceConfigFile;
-         
+
          if (clustered && !databaseType.equals("hsqldb"))
          {
             //HSQL can't be used for clustered server peer - since it's not a shared database
-            
+
             persistenceConfigFile =
                "server/default/deploy/clustered-" + databaseType + "-persistence-service.xml";
          }
@@ -263,45 +299,45 @@
             persistenceConfigFile  =
                "server/default/deploy/" + databaseType + "-persistence-service.xml";
          }
-         
-         log.info("Loading persistence configuration file " + persistenceConfigFile);
 
+         log.info(" Persistence config file .. " + persistenceConfigFile);
+
          URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
          if (persistenceConfigFileURL == null)
          {
             throw new Exception("Cannot find " + persistenceConfigFile + " in the classpath");
          }
-   
+
          String connFactoryConfigFile = "server/default/deploy/connection-factories-service.xml";
          URL connFactoryConfigFileURL = getClass().getClassLoader().getResource(connFactoryConfigFile);
          if (connFactoryConfigFileURL == null)
          {
             throw new Exception("Cannot find " + connFactoryConfigFile + " in the classpath");
          }
-   
+
          ServiceDeploymentDescriptor mdd = new ServiceDeploymentDescriptor(mainConfigFileURL);
          ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
          ServiceDeploymentDescriptor cfdd = new ServiceDeploymentDescriptor(connFactoryConfigFileURL);
-   
+
          MBeanConfigurationElement persistenceManagerConfig =
             (MBeanConfigurationElement)pdd.query("service", "PersistenceManager").iterator().next();
          persistenceManagerObjectName = sc.registerAndConfigureService(persistenceManagerConfig);
          sc.invoke(persistenceManagerObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(persistenceManagerObjectName, "start", new Object[0], new String[0]);    
-              
+         sc.invoke(persistenceManagerObjectName, "start", new Object[0], new String[0]);
+
          MBeanConfigurationElement jmsUserManagerConfig =
             (MBeanConfigurationElement)pdd.query("service", "JMSUserManager").iterator().next();
          jmsUserManagerObjectName = sc.registerAndConfigureService(jmsUserManagerConfig);
          sc.invoke(jmsUserManagerObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(jmsUserManagerObjectName, "start", new Object[0], new String[0]);  
-         
+         sc.invoke(jmsUserManagerObjectName, "start", new Object[0], new String[0]);
+
          // register server peer as a service, dependencies are injected automatically
          MBeanConfigurationElement serverPeerConfig =
             (MBeanConfigurationElement)mdd.query("service", "ServerPeer").iterator().next();
-   
+
          // overwrite the file configuration, if needed
          serverPeerConfig.setConstructorArgumentValue(0, 0, String.valueOf(serverPeerID));
-         
+
          if (defaultQueueJNDIContext != null)
          {
             serverPeerConfig.setConstructorArgumentValue(0, 1, defaultQueueJNDIContext);
@@ -310,32 +346,26 @@
          {
             serverPeerConfig.setConstructorArgumentValue(0, 2, defaultTopicJNDIContext);
          }
-   
+
          serverPeerObjectName = sc.registerAndConfigureService(serverPeerConfig);
-   
+
          // overwrite the config file security domain
          sc.setAttribute(serverPeerObjectName, "SecurityDomain",
                          MockJBossSecurityManager.TEST_SECURITY_DOMAIN);
-   
+
          log.debug("starting JMS server");
-   
+
          sc.invoke(serverPeerObjectName, "create", new Object[0], new String[0]);
          sc.invoke(serverPeerObjectName, "start", new Object[0], new String[0]);
-          
-         MBeanConfigurationElement queuePostOfficeConfig =
-            (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
-         queuePostOfficeObjectName = sc.registerAndConfigureService(queuePostOfficeConfig);
-         sc.invoke(queuePostOfficeObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(queuePostOfficeObjectName, "start", new Object[0], new String[0]);
-         
-         MBeanConfigurationElement topicPostOfficeConfig =
-            (MBeanConfigurationElement)pdd.query("service", "TopicPostOffice").iterator().next();
-         topicPostOfficeObjectName = sc.registerAndConfigureService(topicPostOfficeConfig);
-         sc.invoke(topicPostOfficeObjectName, "create", new Object[0], new String[0]);
-         sc.invoke(topicPostOfficeObjectName, "start", new Object[0], new String[0]);
-         
+
+         MBeanConfigurationElement postOfficeConfig =
+            (MBeanConfigurationElement)pdd.query("service", "PostOffice").iterator().next();
+         postOfficeObjectName = sc.registerAndConfigureService(postOfficeConfig);
+         sc.invoke(postOfficeObjectName, "create", new Object[0], new String[0]);
+         sc.invoke(postOfficeObjectName, "start", new Object[0], new String[0]);
+
          log.debug("deploying connection factories");
-   
+
          List connFactoryElements = cfdd.query("service", "ConnectionFactory");
          connFactoryObjectNames.clear();
          for(Iterator i = connFactoryElements.iterator(); i.hasNext(); )
@@ -347,7 +377,7 @@
             sc.invoke(on, "start", new Object[0], new String[0]);
             connFactoryObjectNames.add(on);
          }
-   
+
          // bind the default JMS provider
          sc.bindDefaultJMSProvider();
          // bind the JCA ConnectionFactory
@@ -371,13 +401,13 @@
             log.warn("ServerPeer already stopped");
             return;
          }
-   
+
          // unbind the JCA ConnectionFactory; nothing happens if no connection factory is bound
          sc.unbindJCAJMSConnectionFactory();
          sc.unbindDefaultJMSProvider();
-   
+
          log.debug("stopping connection factories");
-   
+
          for(Iterator i = connFactoryObjectNames.iterator(); i.hasNext(); )
          {
             try
@@ -396,11 +426,11 @@
             }
          }
          connFactoryObjectNames.clear();
-   
+
          log.debug("stopping all destinations");
-   
+
          Set destinations = (Set)sc.getAttribute(serverPeerObjectName, "Destinations");
-   
+
          for(Iterator i = destinations.iterator(); i.hasNext(); )
          {
             String name;
@@ -415,12 +445,12 @@
                isQueue = false;
                name = ((Topic)d).getTopicName();
             }
-   
+
             undeployDestination(isQueue, name);
          }
-   
+
          log.debug("stopping JMS server");
-   
+
          try
          {
             sc.invoke(serverPeerObjectName, "stop", new Object[0], new String[0]);
@@ -434,9 +464,9 @@
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
          }
-   
+
          log.debug("stopping ServerPeer's plug-in dependencies");
-               
+
          try
          {
             sc.invoke(jmsUserManagerObjectName, "stop", new Object[0], new String[0]);
@@ -450,12 +480,12 @@
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
          }
-   
+
          try
          {
-            sc.invoke(queuePostOfficeObjectName, "stop", new Object[0], new String[0]);
-            sc.invoke(queuePostOfficeObjectName, "destroy", new Object[0], new String[0]);
-            sc.unregisterService(queuePostOfficeObjectName);
+            sc.invoke(postOfficeObjectName, "stop", new Object[0], new String[0]);
+            sc.invoke(postOfficeObjectName, "destroy", new Object[0], new String[0]);
+            sc.unregisterService(postOfficeObjectName);
          }
          catch (Exception ignore)
          {
@@ -464,23 +494,9 @@
             //them down.
             //Hence we must catch and ignore or we won't shut everything down
          }
-         
+
          try
          {
-            sc.invoke(topicPostOfficeObjectName, "stop", new Object[0], new String[0]);
-            sc.invoke(topicPostOfficeObjectName, "destroy", new Object[0], new String[0]);
-            sc.unregisterService(topicPostOfficeObjectName);
-         }
-         catch (Exception ignore)
-         {
-            //If the serverpeer failed when starting up previously, then only some of the
-            //services may be started. The ones that didn't start will fail when attempting to shut
-            //them down.
-            //Hence we must catch and ignore or we won't shut everything down
-         }
-   
-         try
-         {
             sc.invoke(persistenceManagerObjectName, "stop", new Object[0], new String[0]);
             sc.invoke(persistenceManagerObjectName, "destroy", new Object[0], new String[0]);
             sc.unregisterService(persistenceManagerObjectName);
@@ -556,26 +572,13 @@
       ServerPeer serverPeer = (ServerPeer)sc.getAttribute(serverPeerObjectName, "Instance");
       return serverPeer.getDestinationManager();
    }
-   
+
    public PersistenceManager getPersistenceManager() throws Exception
    {
       ServerPeer serverPeer = (ServerPeer)sc.getAttribute(serverPeerObjectName, "Instance");
       return serverPeer.getPersistenceManagerInstance();
    }
-   
-   public PostOffice getQueuePostOffice() throws Exception
-   {
-      return (PostOffice)sc.
-         getAttribute(queuePostOfficeObjectName, "Instance");
-   }
-   
-   public PostOffice getTopicPostOffice() throws Exception
-   {
-      return (PostOffice)sc.
-         getAttribute(topicPostOfficeObjectName, "Instance");
-   }
 
-   
    /**
     * Only for in-VM use!
     */
@@ -607,7 +610,7 @@
    {
       deployDestination(true, name, jndiName, clustered);
    }
-   
+
    public void deployQueue(String name, String jndiName, int fullSize, int pageSize,
                            int downCacheSize, boolean clustered) throws Exception
    {
@@ -638,7 +641,7 @@
       sc.invoke(deston, "create", new Object[0], new String[0]);
       sc.invoke(deston, "start", new Object[0], new String[0]);
    }
-   
+
    public void deployDestination(boolean isQueue,
                                  String name,
                                  String jndiName,
@@ -648,7 +651,7 @@
                                  boolean clustered) throws Exception
    {
       log.info("deploying queue, fullsize:" + fullSize + ", ps:" + pageSize + " dc size:" + downCacheSize);
-      
+
       String config =
          "<mbean code=\"org.jboss.jms.server.destination." + (isQueue ? "QueueService" : "TopicService") + "\"" +
          "       name=\"jboss.messaging.destination:service=" + (isQueue ? "Queue" : "Topic") + ",name=" + name + "\"" +
@@ -711,7 +714,7 @@
    {
       deployConnectionFactory(objectName, jndiBindings, prefetchSize, -1, -1, -1);
    }
-   
+
    public void deployConnectionFactory(String objectName,
                                        String[] jndiBindings) throws Exception
    {
@@ -732,27 +735,27 @@
          "<depends optional-attribute-name=\"ServerPeer\">jboss.messaging:service=ServerPeer</depends>\n" +
          "<depends optional-attribute-name=\"Connector\">" + ServiceContainer.REMOTING_OBJECT_NAME +
          "</depends>\n";
-      
+
       if (defaultTempQueueFullSize != -1)
       {
          config += "<attribute name=\"DefaultTempQueueFullSize\">" + defaultTempQueueFullSize + "</attribute>\n";
       }
-      
+
       if (defaultTempQueuePageSize != -1)
       {
          config += "<attribute name=\"DefaultTempQueuePageSize\">" + defaultTempQueuePageSize + "</attribute>\n";
       }
-      
+
       if (defaultTempQueueDownCacheSize != -1)
       {
          config += "<attribute name=\"DefaultTempQueueDownCacheSize\">" + defaultTempQueueDownCacheSize + "</attribute>\n";
       }
-      
+
       if (prefetchSize != -1)
       {
          config += "<attribute name=\"PrefetchSize\">" + prefetchSize + "</attribute>";
       }
-      
+
       config += "<attribute name=\"JNDIBindings\"><bindings>";
 
       for(int i = 0; i < jndiBindings.length; i++)
@@ -801,9 +804,9 @@
       Element element = (Element)sc.getAttribute(serverPeerObjectName, "DefaultSecurityConfig");
       return XMLUtil.elementToString(element);
    }
-   
+
    public Object executeCommand(Command command) throws Exception
-   { 
+   {
       return command.execute();
    }
 
@@ -812,6 +815,17 @@
       return sc.getUserTransaction();
    }
 
+   public Set getNodeIDView() throws Exception
+   {
+      return (Set)sc.getAttribute(postOfficeObjectName, "NodeIDView");
+   }
+
+   public List pollNotificationListener(long listenerID) throws Exception
+   {
+      throw new IllegalStateException("Poll doesn't make sense on a local server. " +
+                                      "Register listeners directly instead.");
+   }
+
    // Public --------------------------------------------------------
 
    // Package protected ---------------------------------------------

Copied: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NotificationListenerID.java)

Copied: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/rmi/ProxyNotificationListener.java)

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -43,12 +43,14 @@
    // Attributes ----------------------------------------------------
 
    private InitialContextAccess ica;
+   private int serverIndex;
 
    // Constructors --------------------------------------------------
 
-   public RMINamingDelegate() throws Exception
+   public RMINamingDelegate(int serverIndex) throws Exception
    {
       super();
+      this.serverIndex = serverIndex;
       ica = new InitialContextAccess();
    }
 
@@ -87,7 +89,7 @@
       {
          if (ic == null)
          {
-            ic = new InitialContext(InVMInitialContextFactory.getJNDIEnvironment());
+            ic = new InitialContext(InVMInitialContextFactory.getJNDIEnvironment(serverIndex));
          }
          return ic;
       }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,10 +25,13 @@
 import java.rmi.registry.Registry;
 import java.rmi.server.UnicastRemoteObject;
 import java.util.Set;
-
+import java.util.List;
+import java.util.Map;
+import java.util.HashMap;
+import java.util.Collections;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
-
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.logging.Logger;
@@ -48,188 +51,216 @@
  */
 public class RMITestServer extends UnicastRemoteObject implements Server
 {
-   private static final long serialVersionUID = -368445344011004778L;
+   // Constants -----------------------------------------------------
 
-   private static final Logger log = Logger.getLogger(RMITestServer.class);
+   public static final String RMI_SERVER_PREFIX = "messaging_rmi_server_";
+   public static final String NAMING_SERVER_PREFIX = "naming_rmi_server_";
 
-   protected RemoteTestServer server;
+   public static final int DEFAULT_REGISTRY_PORT = 22555;
+   public static final int DEFAULT_SERVER_INDEX = 0;
+   public static final String DEFAULT_SERVER_HOST = "localhost";
 
-   private RMINamingDelegate namingDelegate;
+   private static final long serialVersionUID = -368445344011004778L;
+   private static final Logger log = Logger.getLogger(RMITestServer.class);
 
-   //public static final int RMI_REGISTRY_PORT = 25989;
-   
-   //We allow for up to 5 rmi test servers running simultaneously
-   public static final int[] RMI_REGISTRY_PORTS = 
-      new int[] {25989, 25990, 25991, 25992, 25993};
-   
-   public static final String RMI_SERVER_NAME = "messaging-rmi-server";
-   public static final String NAMING_SERVER_NAME = "naming-rmi-server";
+   // Static --------------------------------------------------------
 
-   private static Registry registry;
-   
    public static void main(String[] args) throws Exception
    {
       log.debug("initializing RMI runtime");
 
       String host = System.getProperty("test.bind.address");
+
       if (host == null)
       {
-         host = "localhost";
+         host = DEFAULT_SERVER_HOST;
       }
 
-      log.info("bind address: " + host);
-      
-      int index;
-      String registryIndex = System.getProperty("test.registry.index");
-      if (registryIndex == null)
+      int serverIndex = DEFAULT_SERVER_INDEX;
+
+      String s = System.getProperty("test.server.index");
+
+      if (s != null)
       {
-         //Use the 0th port
-         index = 0;
+         serverIndex = Integer.parseInt(s);
       }
-      else
-      {
-         index = Integer.parseInt(registryIndex);         
-      }
-      int port = RMI_REGISTRY_PORTS[index];
 
+      log.info("RMI server " + serverIndex + ", bind address " + host);
+
+      RMITestServer testServer = new RMITestServer(serverIndex);
+      log.debug("RMI server " + serverIndex + " created");
+
       // let RMI know the bind address
       System.setProperty("java.rmi.server.hostname", host);
 
-      registry = LocateRegistry.createRegistry(port);
-      log.debug("registry created at port: " + port);
+      Registry registry;
 
-      RMITestServer testServer = new RMITestServer(index);
-      log.debug("RMI server created");
+      // try to bind first
+      try
+      {
+         registry = LocateRegistry.getRegistry(DEFAULT_REGISTRY_PORT);
+         registry.bind(RMI_SERVER_PREFIX + serverIndex, testServer);
+         registry.bind(NAMING_SERVER_PREFIX + serverIndex, testServer.getNamingDelegate());
 
-      registry.bind(RMI_SERVER_NAME, testServer);
-      registry.bind(NAMING_SERVER_NAME, testServer.getNamingDelegate());
-
-      log.info("RMI server bound");
-   }
-
-   public class VMKiller implements Runnable
-   {
-      public void run()
+      }
+      catch(Exception e)
       {
-         log.info("shutting down the VM");
+         log.info("Failure using an existing registry, trying creating it");
 
-         try
-         {
-            Thread.sleep(250);
-         }
-         catch(Exception e)
-         {
-            log.warn("interrupted while sleeping", e);
-         }
+         // try to create it
+         registry = LocateRegistry.createRegistry(DEFAULT_REGISTRY_PORT);
 
-         System.exit(0);
+         registry.bind(RMI_SERVER_PREFIX + serverIndex, testServer);
+         registry.bind(NAMING_SERVER_PREFIX + serverIndex, testServer.getNamingDelegate());
       }
+
+      log.info("RMI server " + serverIndex + " bound");
    }
 
+   // Attributes ----------------------------------------------------
+
+   protected RemoteTestServer server;
+   private RMINamingDelegate namingDelegate;
+   // Map<Long-ProxyNotificationListener>
+   private Map proxyListeners;
+
+   // Constructors --------------------------------------------------
+
    public RMITestServer(int index) throws Exception
    {
-      namingDelegate = new RMINamingDelegate();
-
+      namingDelegate = new RMINamingDelegate(index);
       server = new RemoteTestServer(index);
+      proxyListeners = new HashMap();
    }
 
-   public void configureSecurityForDestination(String destName, String config) throws Exception
+   // Server implementation -----------------------------------------
+
+   public void start(String containerConfig) throws Exception
    {
-      server.configureSecurityForDestination(destName, config);
+      server.start(containerConfig);
    }
 
-   public ObjectName deploy(String mbeanConfiguration) throws Exception
+   public void stop() throws Exception
    {
-      return server.deploy(mbeanConfiguration);
+      server.stop();
+      namingDelegate.reset();
    }
 
-   public void deployQueue(String name, String jndiName, boolean clustered) throws Exception
+   public synchronized void kill() throws Exception
    {
-      server.deployQueue(name, jndiName, clustered);
+      // Kills the server without doing any graceful shutdown. For graceful shutdown use stop().
+      new Thread(new VMKiller(), "VM Killer").start();
    }
 
-   public void deployTopic(String name, String jndiName, boolean clustered) throws Exception
+   public ObjectName deploy(String mbeanConfiguration) throws Exception
    {
-      server.deployTopic(name, jndiName, clustered);
+      return server.deploy(mbeanConfiguration);
    }
-   
-   public void deployQueue(String name,
-                           String jndiName,
-                           int fullSize,
-                           int pageSize,
-                           int downCacheSize,
-                           boolean clustered) throws Exception
+
+   public void undeploy(ObjectName on) throws Exception
    {
-      server.deployQueue(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
+      server.undeploy(on);
    }
 
-   public void createQueue(String name, String jndiName) throws Exception
+   public Object getAttribute(ObjectName on, String attribute) throws Exception
    {
-      server.createQueue(name, jndiName);
+      return server.getAttribute(on, attribute);
    }
 
-   public void deployTopic(String name,
-                           String jndiName,
-                           int fullSize,
-                           int pageSize,
-                           int downCacheSize,
-                           boolean clustered) throws Exception
+   public void setAttribute(ObjectName on, String name, String valueAsString) throws Exception
    {
-      server.deployTopic(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
+      server.setAttribute(on, name, valueAsString);
    }
 
-   public void createTopic(String name, String jndiName) throws Exception
+   public Object invoke(ObjectName on, String operationName, Object[] params, String[] signature)
+      throws Exception
    {
-      server.createTopic(name, jndiName);
+      return server.invoke(on, operationName, params, signature);
    }
 
-   public void deployConnectionFactory(String objectName, String[] jndiBindings)
+   public void addNotificationListener(ObjectName on, NotificationListener listener)
       throws Exception
    {
-      server.deployConnectionFactory(objectName, jndiBindings);
+      if (!(listener instanceof NotificationListenerID))
+      {
+         throw new IllegalArgumentException("A RMITestServer can only handle NotificationListenerIDs!");
+      }
+
+      long id = ((NotificationListenerID)listener).getID();
+
+      ProxyNotificationListener pl = new ProxyNotificationListener();
+
+      synchronized(proxyListeners)
+      {
+         proxyListeners.put(new Long(id), pl);
+      }
+
+      server.addNotificationListener(on, pl);
    }
-   
-   public void deployConnectionFactory(String objectName, String[] jndiBindings, int prefetchSize)
+
+   public void removeNotificationListener(ObjectName on, NotificationListener listener)
       throws Exception
    {
-      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize);
+
+      if (!(listener instanceof NotificationListenerID))
+      {
+         throw new IllegalArgumentException("A RMITestServer can only handle NotificationListenerIDs!");
+      }
+
+      long id = ((NotificationListenerID)listener).getID();
+
+      ProxyNotificationListener pl = null;
+
+      synchronized(proxyListeners)
+      {
+         pl = (ProxyNotificationListener)proxyListeners.remove(new Long(id));
+      }
+
+      server.removeNotificationListener(on, pl);
    }
 
-   public void deployConnectionFactory(String objectName,
-                                       String[] jndiBindings,
-                                       int prefetchSize,
-                                       int defaultTempQueueFullSize,
-                                       int defaultTempQueuePageSize,
-                                       int defaultTempQueueDownCacheSize) throws Exception
+   public Set query(ObjectName pattern) throws Exception
    {
-      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize,
-               defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
+      return server.query(pattern);
    }
 
-   public void undeployConnectionFactory(ObjectName objectName) throws Exception
+   public String getDatabaseType()
    {
-      server.undeployConnectionFactory(objectName);
+      return server.getDatabaseType();
    }
 
-   public synchronized void destroy() throws Exception
+   public void log(int level, String text) throws Exception
    {
-      server.destroy();
+      server.log(level, text);
+   }
 
-      registry.unbind(RMI_SERVER_NAME);
-      registry.unbind(NAMING_SERVER_NAME);
-      
-      //Now shutdown the process
-      
-      //TODO - we should shutdown cleanly - let main() exit - not kill the process
-      
-      new Thread(new VMKiller(), "VM Killer").start();
+   public void startServerPeer(int serverPeerID, String defaultQueueJNDIContext,
+                               String defaultTopicJNDIContext, boolean clustered) throws Exception
+   {
+      server.
+         startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, clustered);
    }
 
-   public Object getAttribute(ObjectName on, String attribute) throws Exception
+   public void stopServerPeer() throws Exception
    {
-      return server.getAttribute(on, attribute);
+      server.stopServerPeer();
    }
 
+   public boolean isServerPeerStarted() throws Exception
+   {
+      return server.isServerPeerStarted();
+   }
+
+   public ObjectName getServerPeerObjectName() throws Exception
+   {
+      return server.getServerPeerObjectName();
+   }
+
+   public boolean isStarted() throws Exception
+   {
+      return server.isStarted();
+   }
+
    public Set getConnectorSubsystems() throws Exception
    {
       return server.getConnectorSubsystems();
@@ -246,9 +277,9 @@
       server.removeServerInvocationHandler(subsystem);
    }
 
-   public String getDefaultSecurityConfig() throws Exception
+   public MessageStore getMessageStore() throws Exception
    {
-      return server.getDefaultSecurityConfig();
+      return server.getMessageStore();
    }
 
    public DestinationManager getDestinationManager() throws Exception
@@ -256,107 +287,117 @@
       return server.getDestinationManager();
    }
 
-   public MessageStore getMessageStore() throws Exception
-   {
-      return server.getMessageStore();
-   }
-
    public PersistenceManager getPersistenceManager() throws Exception
    {
       return server.getPersistenceManager();
    }
-   
+
    public PostOffice getQueuePostOffice() throws Exception
    {
       return server.getQueuePostOffice();
    }
-   
+
    public PostOffice getTopicPostOffice() throws Exception
    {
       return server.getTopicPostOffice();
    }
 
-   public ObjectName getServerPeerObjectName() throws Exception
+   public ServerPeer getServerPeer() throws Exception
    {
-      return server.getServerPeerObjectName();
+      return server.getServerPeer();
    }
 
-   public Object invoke(ObjectName on, String operationName, Object[] params, String[] signature) throws Exception
+   public void deployTopic(String name, String jndiName, boolean clustered) throws Exception
    {
-      return server.invoke(on, operationName, params, signature);
+      server.deployTopic(name, jndiName, clustered);
    }
 
-   public boolean isServerPeerStarted() throws Exception
+   public void deployTopic(String name,
+                           String jndiName,
+                           int fullSize,
+                           int pageSize,
+                           int downCacheSize,
+                           boolean clustered) throws Exception
    {
-      return server.isServerPeerStarted();
+      server.deployTopic(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
    }
 
-   public boolean isStarted() throws Exception
+   public void createTopic(String name, String jndiName) throws Exception
    {
-      return server.isStarted();
+      server.createTopic(name, jndiName);
    }
 
-   public void log(int level, String text) throws Exception
+   public void deployQueue(String name, String jndiName, boolean clustered) throws Exception
    {
-      server.log(level, text);
+      server.deployQueue(name, jndiName, clustered);
    }
 
-   public Set query(ObjectName pattern) throws Exception
+   public void deployQueue(String name,
+                           String jndiName,
+                           int fullSize,
+                           int pageSize,
+                           int downCacheSize,
+                           boolean clustered) throws Exception
    {
-      return server.query(pattern);
+      server.deployQueue(name, jndiName, fullSize, pageSize, downCacheSize, clustered);
    }
 
-   public String getDatabaseType()
+   public void createQueue(String name, String jndiName) throws Exception
    {
-      return server.getDatabaseType();
+      server.createQueue(name, jndiName);
    }
 
-   public void setAttribute(ObjectName on, String name, String valueAsString) throws Exception
+   public void undeployDestination(boolean isQueue, String name) throws Exception
    {
-      server.setAttribute(on, name, valueAsString);
+      server.undeployDestination(isQueue, name);
    }
 
-   public void setDefaultSecurityConfig(String config) throws Exception
+   public boolean destroyDestination(boolean isQueue, String name) throws Exception
    {
-      server.setDefaultSecurityConfig(config);
+      return server.destroyDestination(isQueue, name);
    }
 
-   public void start(String containerConfig, boolean clustered) throws Exception
+   public void deployConnectionFactory(String objectName, String[] jndiBindings)
+      throws Exception
    {
-      server.start(containerConfig, clustered);
+      server.deployConnectionFactory(objectName, jndiBindings);
    }
 
-   public void startServerPeer(int serverPeerID, String defaultQueueJNDIContext,
-                               String defaultTopicJNDIContext, boolean clustered) throws Exception
+   public void deployConnectionFactory(String objectName, String[] jndiBindings, int prefetchSize)
+      throws Exception
    {
-      server.startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, clustered);
+      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize);
    }
 
-   public void stop() throws Exception
+   public void deployConnectionFactory(String objectName,
+                                       String[] jndiBindings,
+                                       int prefetchSize,
+                                       int defaultTempQueueFullSize,
+                                       int defaultTempQueuePageSize,
+                                       int defaultTempQueueDownCacheSize) throws Exception
    {
-      server.stop();
-
-      namingDelegate.reset();
+      server.deployConnectionFactory(objectName, jndiBindings, prefetchSize,
+               defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize);
    }
 
-   public void stopServerPeer() throws Exception
+   public void undeployConnectionFactory(ObjectName objectName) throws Exception
    {
-      server.stopServerPeer();
+      server.undeployConnectionFactory(objectName);
    }
 
-   public void undeploy(ObjectName on) throws Exception
+   public void configureSecurityForDestination(String destName, String config) throws Exception
    {
-      server.undeploy(on);
+      server.configureSecurityForDestination(destName, config);
    }
 
-   public void undeployDestination(boolean isQueue, String name) throws Exception
+   public void setDefaultSecurityConfig(String config) throws Exception
    {
-      server.undeployDestination(isQueue, name);
+      server.setDefaultSecurityConfig(config);
    }
 
-   public boolean destroyDestination(boolean isQueue, String name) throws Exception
+   public String getDefaultSecurityConfig() throws Exception
    {
-      return server.destroyDestination(isQueue, name);
+      return server.getDefaultSecurityConfig();
    }
 
    public Object executeCommand(Command command) throws Exception
@@ -364,18 +405,64 @@
       return server.executeCommand(command);
    }
 
-   public ServerPeer getServerPeer() throws Exception
+   public UserTransaction getUserTransaction() throws Exception
    {
-      return server.getServerPeer();
+      return server.getUserTransaction();
    }
 
-   public UserTransaction getUserTransaction() throws Exception
+   public Set getNodeIDView() throws Exception
    {
-      return server.getUserTransaction();
+      return server.getNodeIDView();
    }
 
+   public List pollNotificationListener(long listenerID) throws Exception
+   {
+      ProxyNotificationListener pl = null;
+
+      synchronized(proxyListeners)
+      {
+         pl = (ProxyNotificationListener)proxyListeners.get(new Long(listenerID));
+      }
+
+      if (pl == null)
+      {
+         return Collections.EMPTY_LIST;
+      }
+
+      return pl.drain();
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
    private RMINamingDelegate getNamingDelegate()
    {
       return namingDelegate;
    }
+
+   // Inner classes -------------------------------------------------
+
+   public class VMKiller implements Runnable
+   {
+      public void run()
+      {
+         log.info("shutting down the VM");
+
+         try
+         {
+            Thread.sleep(250);
+         }
+         catch(Exception e)
+         {
+            log.warn("interrupted while sleeping", e);
+         }
+
+         System.exit(0);
+      }
+   }
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,10 +23,10 @@
 
 import java.rmi.Remote;
 import java.util.Set;
-
+import java.util.List;
 import javax.management.ObjectName;
+import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
-
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
@@ -44,22 +44,37 @@
  */
 public interface Server extends Remote
 {
-   void start(String containerConfig, boolean clustered) throws Exception;
+   void start(String containerConfig) throws Exception;
+
    void stop() throws Exception;
-   void destroy() throws Exception;
 
    /**
+    * For a remote server, it "abruptly" kills the VM running the server. For a local server
+    * it just stops the server.
+    */
+   void kill() throws Exception;
+
+   /**
     * Deploys and registers a service based on the MBean service descriptor element, specified as
     * a String. Supports XMBeans. The implementing class and the ObjectName are inferred from the
     * mbean element. If there are configuration attributed specified in the deployment descriptor,
     * they are applied to the service instance.
     */
    ObjectName deploy(String mbeanConfiguration) throws Exception;
+
    void undeploy(ObjectName on) throws Exception;
+
    Object getAttribute(ObjectName on, String attribute) throws Exception;
+
    void setAttribute(ObjectName on, String name, String valueAsString) throws Exception;
+
    Object invoke(ObjectName on, String operationName, Object[] params, String[] signature)
       throws Exception;
+
+   void addNotificationListener(ObjectName on, NotificationListener listener) throws Exception;
+
+   void removeNotificationListener(ObjectName on, NotificationListener listener) throws Exception;
+
    /**
     * Returns a set of ObjectNames corresponding to installed services.
     */
@@ -120,13 +135,6 @@
    PersistenceManager getPersistenceManager() throws Exception;
 
    /**
-    * Only for in-VM use!
-    */
-   PostOffice getQueuePostOffice() throws Exception;
-   
-   PostOffice getTopicPostOffice() throws Exception;
-
-   /**
     * Only for in-VM use
     */
    ServerPeer getServerPeer() throws Exception;
@@ -219,4 +227,17 @@
 
    UserTransaction getUserTransaction() throws Exception;
 
+   /**
+    * Returns a Set containing the nodeID (as Integers) of all cluster members at the time of the
+    * call.
+    *
+    * USE IT ONLY FOR CLUSTERING TESTS!
+    */
+   Set getNodeIDView() throws Exception;
+
+   /**
+    * @return List<Notification>
+    */
+   List pollNotificationListener(long listenerID) throws Exception;
+
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,11 +21,10 @@
 */
 package org.jboss.test.messaging.tools.jmx.rmi;
 
+import java.rmi.ConnectException;
+import java.rmi.Naming;
 import org.jboss.logging.Logger;
 
-import java.rmi.Naming;
-import java.rmi.ConnectException;
-
 /**
  * A utility to stop runaway rmi servers.
  *
@@ -52,20 +51,20 @@
       }
       
       int index;
-      String registryIndex = System.getProperty("test.registry.index");
-      if (registryIndex == null)
+
+      String serverIndex = System.getProperty("test.server.index");
+      if (serverIndex == null)
       {
-         //Use the 0th port
-         index = 0;
+         index = RMITestServer.DEFAULT_SERVER_INDEX;
       }
       else
       {
-         index = Integer.parseInt(registryIndex);         
+         index = Integer.parseInt(serverIndex);
       }
-      int port = RMITestServer.RMI_REGISTRY_PORTS[index];
 
       String name =
-         "//" + host + ":" + port + "/" + RMITestServer.RMI_SERVER_NAME;
+         "//" + host + ":" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
+         RMITestServer.RMI_SERVER_PREFIX + index;
 
       log.info("Stopping " + name);
 
@@ -80,9 +79,12 @@
          return;
       }
 
-      //We should shut down cleanly - not kill the process like we are currently doing
+      // We should shut down cleanly - not kill the process like we are currently doing
       
-      server.destroy();
+      server.kill();
+
+      // The last RMI server will take with it the registry too
+
       log.info("RMI server stopped");
 
    }

Copied: trunk/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java (from rev 1765, branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/tools/jndi/Constants.java)

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactory.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -25,6 +25,8 @@
 import javax.naming.NamingException;
 import javax.naming.Context;
 import java.util.Hashtable;
+import java.util.List;
+import java.util.ArrayList;
 
 /**
  * An in-VM JNDI InitialContextFactory. Lightweight JNDI implementation used for testing.
@@ -38,44 +40,99 @@
 {
    // Constants -----------------------------------------------------
 
-   private static InVMContext initialContext;
-
    // Static --------------------------------------------------------
 
+   // List<InitialContext>
+   private static List initialContexts;
+
+   static
+   {
+      initialContexts = new ArrayList();
+   }
+
+   public static Hashtable getJNDIEnvironment()
+   {
+      return getJNDIEnvironment(0);
+   }
+
    /**
     * @return the JNDI environment to use to get this InitialContextFactory.
     */
-   public static Hashtable getJNDIEnvironment()
+   public static Hashtable getJNDIEnvironment(int serverIndex)
    {
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial",
               "org.jboss.messaging.tools.jndi.InVMInitialContextFactory");
       env.put("java.naming.provider.url", "");
       env.put("java.naming.factory.url.pkgs", "");
+      env.put(Constants.SERVER_INDEX_PROPERTY_NAME, Integer.toString(serverIndex));
       return env;
    }
 
    // Attributes ----------------------------------------------------
-   
+
    // Constructors --------------------------------------------------
-   
+
    // Public --------------------------------------------------------
 
    public Context getInitialContext(Hashtable environment) throws NamingException
    {
-      if (initialContext == null)
+      // try first in the environment passed as argument ...
+      String s = (String)environment.get(Constants.SERVER_INDEX_PROPERTY_NAME);
+
+      if (s == null)
       {
-         initialContext = new InVMContext();
-         initialContext.bind("java:/", new InVMContext());
+         // ... then in the global environment
+         s = System.getProperty(Constants.SERVER_INDEX_PROPERTY_NAME);
+
+         if (s == null)
+         {
+            throw new NamingException("Cannot figure out server index!");
+         }
       }
-      return initialContext;
+
+      int serverIndex;
+
+      try
+      {
+         serverIndex = Integer.parseInt(s);
+      }
+      catch(Exception e)
+      {
+         throw new NamingException("Failure parsing \"" +
+                                   Constants.SERVER_INDEX_PROPERTY_NAME +"\". " +
+                                   s + " is not an integer");
+      }
+
+      int size = initialContexts.size();
+
+      // pad the list to the right size
+
+      if (size <= serverIndex)
+      {
+         for(int i = 0; i < serverIndex - size + 1; i++)
+         {
+            initialContexts.add(null);
+         }
+      }
+
+      InVMContext ic = (InVMContext)initialContexts.get(serverIndex);
+
+      if (ic == null)
+      {
+         ic = new InVMContext();
+         ic.bind("java:/", new InVMContext());
+         initialContexts.set(serverIndex, ic);
+      }
+
+      return ic;
    }
 
    // Package protected ---------------------------------------------
-   
+
    // Protected -----------------------------------------------------
-   
+
    // Private -------------------------------------------------------
-   
+
    // Inner classes -------------------------------------------------   
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMInitialContextFactoryBuilder.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -35,9 +35,34 @@
  */
 public class InVMInitialContextFactoryBuilder implements InitialContextFactoryBuilder
 {
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public InVMInitialContextFactoryBuilder()
+   {
+   }
+
+   // InitialContextFactoryBuilder implementation -------------------
+
    public InitialContextFactory createInitialContextFactory(Hashtable environment)
          throws NamingException
    {
       return new InVMInitialContextFactory();
    }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -23,13 +23,7 @@
 
 import java.rmi.Naming;
 import java.util.Hashtable;
-
-import javax.naming.Context;
-import javax.naming.Name;
-import javax.naming.NameParser;
-import javax.naming.NamingEnumeration;
-import javax.naming.NamingException;
-
+import javax.naming.*;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.util.NotYetImplementedException;
 import org.jboss.test.messaging.tools.jmx.rmi.NamingDelegate;
@@ -59,7 +53,11 @@
    public RemoteContext(int remoteServerIndex) throws Exception
    {
       String n =
-         "//localhost:" + RMITestServer.RMI_REGISTRY_PORTS[remoteServerIndex] + "/" + RMITestServer.NAMING_SERVER_NAME;
+         "//localhost:" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
+          RMITestServer.NAMING_SERVER_PREFIX + remoteServerIndex;
+      
+      log.info("Using this url for rmi server lookup " + n);
+      
       namingDelegate = (NamingDelegate)Naming.lookup(n);
    }
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-11 22:29:27 UTC (rev 1766)
@@ -21,14 +21,12 @@
 */
 package org.jboss.test.messaging.tools.jndi;
 
-import org.jboss.logging.Logger;
-import org.jboss.test.messaging.tools.jmx.rmi.RMITestServer;
-
 import java.util.Hashtable;
-
 import javax.naming.Context;
 import javax.naming.NamingException;
 import javax.naming.spi.InitialContextFactory;
+import org.jboss.logging.Logger;
+import org.jboss.test.messaging.tools.jmx.rmi.RMITestServer;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -44,21 +42,19 @@
 
    // Static --------------------------------------------------------
 
-   private static RemoteContext[] initialContexts = new RemoteContext[RMITestServer.RMI_REGISTRY_PORTS.length];
-   
-   private static final String REMOTE_SERVER_INDEX_KEY_NAME = "jboss.messaging.test.remoteserverindex";
-
    /**
     * @return the JNDI environment to use to get this InitialContextFactory.
     */
-   public static Hashtable getJNDIEnvironment(int index)
+   public static Hashtable getJNDIEnvironment(int serverIndex)
    {
+      log.info("Returning remote context... server index:" + serverIndex);
+      
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial",
               "org.jboss.test.messaging.tools.jndi.RemoteInitialContextFactory");
       env.put("java.naming.provider.url", "");
       env.put("java.naming.factory.url.pkgs", "");
-      env.put(REMOTE_SERVER_INDEX_KEY_NAME, String.valueOf(index));
+      env.put(Constants.SERVER_INDEX_PROPERTY_NAME, Integer.toString(serverIndex));
       return env;
    }
 
@@ -70,28 +66,28 @@
 
    public Context getInitialContext(Hashtable environment) throws NamingException
    {
-      String s = (String)environment.get(REMOTE_SERVER_INDEX_KEY_NAME);
+      String s = (String)environment.get(Constants.SERVER_INDEX_PROPERTY_NAME);
       
       if (s == null)
       {
-         throw new IllegalArgumentException("Initial context environment must contain entry for " + REMOTE_SERVER_INDEX_KEY_NAME);
+         throw new IllegalArgumentException("Initial context environment must contain " +
+                                            "entry for " + Constants.SERVER_INDEX_PROPERTY_NAME);
       }
-      
+
+      log.info("Created initial context for " + s);
+
       int remoteServerIndex = Integer.parseInt(s);
-      
-      if (initialContexts[remoteServerIndex] == null)
+
+      try
       {
-         try
-         {
-            initialContexts[remoteServerIndex] = new RemoteContext(remoteServerIndex);
-         }
-         catch(Exception e)
-         {
-            log.error("Cannot get the remote context", e);
-            throw new NamingException("Cannot get the remote context");
-         }
+         return new RemoteContext(remoteServerIndex);
       }
-      return initialContexts[remoteServerIndex];
+      catch(Exception e)
+      {
+         log.error("Cannot get the remote context", e);
+         throw new NamingException("Cannot get the remote context");
+      }
+
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/tools/lib/jbossbuild.jar
===================================================================
(Binary files differ)

Modified: trunk/util/do-not-distribute.properties
===================================================================
--- trunk/util/do-not-distribute.properties	2006-12-11 20:50:25 UTC (rev 1765)
+++ trunk/util/do-not-distribute.properties	2006-12-11 22:29:27 UTC (rev 1766)
@@ -2,11 +2,7 @@
 # This file provides values for in-workarea example testing.
 # DO NOT DISTRIBUTE!
 #
-#jboss.home=C:\\work/src/jboss-4.0.1sp1-src/build/output/jboss-4.0.1sp1
-#jboss.home=C:\\work/src/cvs/jboss-head/build/output/jboss-5.0.0.Alpha
-#jboss.home=C:\\work\\src\\jboss-4.0.3SP1-src\\build\\output\\jboss-4.0.3SP1
-#jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
-#jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
+#jboss.home=/home/clebert/workspaces/jboss-4.0-tmp/build/output/jboss-4.0.5.GA
 messaging.config.name=messaging
 main.artifact.location=../output/lib
 auxiliary.artifacts.location=../src/etc/server/default/deploy



From c50 at fullmailmarket.com  Mon Dec 11 18:53:20 2006
From: c50 at fullmailmarket.com (Hostex)
Date: Mon, 11 Dec 2006 20:53:20 -0300
Subject: [jboss-cvs] AUNQUE PAREZCAMOS INSISTENTES NO TODOS LOS WEBHOSTING
	SON IGUALES
Message-ID: <200612112353.kBBNrStM014616@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061211/bf2c332a/attachment.html 

From michael.yuan at jboss.com  Mon Dec 11 19:04:23 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Mon, 11 Dec 2006 19:04:23 -0500
Subject: [jboss-cvs] jboss-seam/hibernate/lib   ...
Message-ID: <E1Gtv8B-0006nX-RB@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/11 19:04:23

  Modified:    hibernate/lib   hibernate-annotations.jar
                        hibernate-entitymanager.jar
  Log:
  update the hibernate libs to GA
  
  Revision  Changes    Path
  1.2       +1608 -1222jboss-seam/hibernate/lib/hibernate-annotations.jar
  
  	<<Binary file>>
  
  
  1.3       +500 -420  jboss-seam/hibernate/lib/hibernate-entitymanager.jar
  
  	<<Binary file>>
  
  


From michael.yuan at jboss.com  Mon Dec 11 19:06:48 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Mon, 11 Dec 2006 19:06:48 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/resources  ...
Message-ID: <E1GtvAW-0006s2-Gb@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/11 19:06:48

  Modified:    examples/jpa/resources  components.xml
  Log:
  reformat the config file
  
  Revision  Changes    Path
  1.2       +19 -34    jboss-seam/examples/jpa/resources/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/components.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- components.xml	29 Nov 2006 03:29:30 -0000	1.1
  +++ components.xml	12 Dec 2006 00:06:47 -0000	1.2
  @@ -1,38 +1,23 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  -
  -<components>
  -  
  -    <component name="org.jboss.seam.core.init">
  -        <property name="debug">true</property>
  -        <!--
  -        <property name="jndiPattern">#{ejbName}/local</property>
  -        -->
  -    </component>
  -    
  -    <component name="org.jboss.seam.core.manager">
  -        <!-- half second wait for conversation lock on concurrent requests -->
  -        <property name="concurrentRequestTimeout">500</property>
  -        <!-- 120 second conversation timeout -->
  -        <property name="conversationTimeout">120000</property>
  -        <property name="conversationIdParameter">cid</property>
  -        <property name="conversationIsLongRunningParameter">clr</property>
  -    </component>
  -    
  -    <component name="org.jboss.seam.core.pages">
  -        <property name="noConversationViewId">/main.xhtml</property>
  -    </component>
  -    
  -    <component name="bookingDatabase" 
  -        class="org.jboss.seam.core.EntityManagerFactory"/>
  -    
  -    <component name="em"
  -          class="org.jboss.seam.core.ManagedPersistenceContext">
  -      <!-- alernative     
  -      <property name="persistenceUnitJndiName">java:/jpaBookingEntityManagerFactory</property>
  -      -->
  -      <property name="entityManagerFactory">#{bookingDatabase}</property>
  -    </component>
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
  +
  +    <core:init debug="true"/>    
  +
  +    <core:pages no-conversation-view-id="/main.xhtml"/>
  +
  +    <core:manager conversation-timeout="120000" 
  +                  concurrent-request-timeout="500"
  +                  conversation-id-parameter="cid"
  +                  conversation-is-long-running-parameter="clr"/>
  +                  
  +    <core:entity-manager-factory name="bookingDatabase"/>
  +    
  +    <core:managed-persistence-context name="em" 
  +        entity-manager-factory="#{bookingDatabase}"/>
   
   </components>
  
  
  


From michael.yuan at jboss.com  Mon Dec 11 19:06:54 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Mon, 11 Dec 2006 19:06:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/resources/tomcat  ...
Message-ID: <E1GtvAc-0006sR-Fu@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/11 19:06:54

  Modified:    examples/jpa/resources/tomcat  components.xml
  Log:
  reformat the config file
  
  Revision  Changes    Path
  1.4       +21 -33    jboss-seam/examples/jpa/resources/tomcat/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/resources/tomcat/components.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- components.xml	29 Nov 2006 03:29:30 -0000	1.3
  +++ components.xml	12 Dec 2006 00:06:54 -0000	1.4
  @@ -1,42 +1,30 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
   
  -<components>
  +    <core:init debug="true"/>    
   
  -    <component name="org.jboss.seam.core.init">
  -        <property name="debug">true</property>
  -        <!--
  -        <property name="jndiPattern">#{ejbName}/local</property>
  -        -->
  -    </component>
  +    <core:pages no-conversation-view-id="/main.xhtml"/>
       
  -    <component name="org.jboss.seam.core.manager">
  -        <!-- half second wait for conversation lock on concurrent requests -->
  -        <property name="concurrentRequestTimeout">500</property>
  -        <!-- 120 second conversation timeout -->
  -        <property name="conversationTimeout">120000</property>
  -        <property name="conversationIdParameter">cid</property>
  -        <property name="conversationIsLongRunningParameter">clr</property>
  -    </component>
  -    
  -    <component name="org.jboss.seam.core.pages">
  -        <property name="noConversationViewId">/main.xhtml</property>
  -    </component>
  -    
  -    
  -    <component name="bookingDatabase" 
  -        class="org.jboss.seam.core.EntityManagerFactory"/>
  -    
  -    <component name="em"
  -          class="org.jboss.seam.core.ManagedPersistenceContext">
  -      <!-- alernative     
  -      <property name="persistenceUnitJndiName">java:/jpaBookingEntityManagerFactory</property>
  -      -->
  -      <property name="entityManagerFactory">#{bookingDatabase}</property>
  -    </component>
  +    <core:manager conversation-timeout="120000" 
  +                  concurrent-request-timeout="500"
  +                  conversation-id-parameter="cid"
  +                  conversation-is-long-running-parameter="clr"/>
  +    
  +    <core:entity-manager-factory name="bookingDatabase"/>
       
  +    <core:managed-persistence-context name="em" 
  +        entity-manager-factory="#{bookingDatabase}"/>
  +    
  +    <core:microcontainer installed="true"/>
  +    
  +    <!--
       <component class="org.jboss.seam.core.Microcontainer"
                  installed="true"/>
  +    -->
   
   </components>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 11 21:16:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 11 Dec 2006 21:16:56 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1767 - in trunk: .
	src/etc/server/default/deploy
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin
	tests/src/org/jboss/test/messaging/tools/jmx
Message-ID: <E1GtxCS-0000We-6Z@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-11 21:16:50 -0500 (Mon, 11 Dec 2006)
New Revision: 1767

Modified:
   trunk/messaging.iml
   trunk/messaging.ipr
   trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
   trunk/src/etc/server/default/deploy/mysql-persistence-service.xml
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/JDBCSupport.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
Log:
post-merge adjustments

Modified: trunk/messaging.iml
===================================================================
--- trunk/messaging.iml	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/messaging.iml	2006-12-12 02:16:50 UTC (rev 1767)
@@ -40,6 +40,7 @@
     <orderEntry type="library" name="jboss-serialization" level="project" />
     <orderEntry type="library" name="jgroups" level="project" />
     <orderEntry type="library" name="junit" level="project" />
+    <orderEntry type="library" name="jboss-system" level="project" />
     <orderEntryProperties />
   </component>
   <component name="VcsManagerConfiguration">

Modified: trunk/messaging.ipr
===================================================================
--- trunk/messaging.ipr	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/messaging.ipr	2006-12-12 02:16:50 UTC (rev 1767)
@@ -301,6 +301,13 @@
       <JAVADOC />
       <SOURCES />
     </library>
+    <library name="jboss-system">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/lib/jboss-system.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
   </component>
   <component name="uidesigner-configuration">
     <option name="INSTRUMENT_CLASSES" value="true" />

Modified: trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-12 02:16:50 UTC (rev 1767)
@@ -39,6 +39,7 @@
 UPDATE_RELIABLE_REFS_NOT_PAGED=UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?
 SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?
 SELECT_EXISTS_REF=SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?
+UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION, REPLYTO, JMSPROPERTIES FROM JMS_MESSAGE
 INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION, REPLYTO, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
 INC_CHANNELCOUNT=UPDATE JMS_MESSAGE SET CHANNELCOUNT = CHANNELCOUNT + 1 WHERE MESSAGEID=?

Modified: trunk/src/etc/server/default/deploy/mysql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-12 02:16:50 UTC (rev 1767)
@@ -39,6 +39,7 @@
    UPDATE_RELIABLE_REFS_NOT_PAGED=UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?
    SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?
    SELECT_EXISTS_REF=SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?
+   UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
    LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION, REPLYTO, JMSPROPERTIES FROM JMS_MESSAGE
    INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION, REPLYTO, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
    INC_CHANNELCOUNT=UPDATE JMS_MESSAGE SET CHANNELCOUNT = CHANNELCOUNT + 1 WHERE MESSAGEID=?

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-12 02:16:50 UTC (rev 1767)
@@ -106,14 +106,16 @@
                   new String[] {"org.jboss.remoting.ConnectionListener"});                     
          }
          
-         //We use the MBean service name to uniquely identify the cf
+         // We use the MBean service name to uniquely identify the connection factory
          
          connectionFactoryManager.
-            registerConnectionFactory(this.getName(), clientID, jndiBindings, locatorURI, enablePing, prefetchSize,
-                     defaultTempQueueFullSize, defaultTempQueuePageSize, defaultTempQueueDownCacheSize,
-                     clustered);
+            registerConnectionFactory(this.getName(), clientID, jndiBindings, locatorURI,
+                                      enablePing, prefetchSize, defaultTempQueueFullSize,
+                                      defaultTempQueuePageSize, defaultTempQueueDownCacheSize,
+                                      clustered);
       
          InvokerLocator locator = new InvokerLocator(locatorURI);
+
          String info =
             "Connector " + locator.getProtocol() + "://" + locator.getHost() + ":" + locator.getPort();
                  

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-12 02:16:50 UTC (rev 1767)
@@ -109,9 +109,10 @@
                                                       boolean clustered)
       throws Exception
    {
-      log.info("Registering connection factory with name " + uniqueName + " bindings " + jndiBindings);
+      log.info("Registering connection factory with name " + uniqueName + " " + 
+               "bindings " + jndiBindings);
       
-      //Sanity check
+      // Sanity check
       if (delegates.containsKey(uniqueName))
       {
          throw new IllegalArgumentException("There's already a connection factory registered with name " + uniqueName);

Modified: trunk/src/main/org/jboss/messaging/core/plugin/JDBCSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/JDBCSupport.java	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/src/main/org/jboss/messaging/core/plugin/JDBCSupport.java	2006-12-12 02:16:50 UTC (rev 1767)
@@ -170,9 +170,7 @@
          throw new IllegalArgumentException("No such SQL statement: " + statementName);
       }
       
-      String statement = sqlProperties.getProperty(statementName, defaultStatement);
-      
-      return statement;
+      return sqlProperties.getProperty(statementName, defaultStatement);
    }
    
    protected Map getDefaultDMLStatements()

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-11 22:29:27 UTC (rev 1766)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-12 02:16:50 UTC (rev 1767)
@@ -63,6 +63,7 @@
 import org.jboss.logging.Logger;
 import org.jboss.remoting.InvokerLocator;
 import org.jboss.remoting.ServerInvocationHandler;
+import org.jboss.remoting.transport.PortUtil;
 import org.jboss.remoting.serialization.SerializationStreamFactory;
 import org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory;
 import org.jboss.resource.adapter.jdbc.remote.WrapperDataSourceService;
@@ -1175,9 +1176,7 @@
          params += "&timeout=0";
       }
 
-//      int freePort = PortUtil.findFreePort(ipAddressOrHostName);
-
-      int freePort = 9111;
+      int freePort = PortUtil.findFreePort(ipAddressOrHostName);
       String locatorURI = transport + "://" + ipAddressOrHostName + ":" + freePort + params;
 
       log.debug("Using locator uri: " + locatorURI);



From tom.elrod at jboss.com  Mon Dec 11 22:48:04 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Mon, 11 Dec 2006 22:48:04 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting   ...
Message-ID: <E1Gtyce-00021H-7a@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/11 22:48:04

  Modified:    src/main/org/jboss/remoting   Tag: remoting_2_x Client.java
                        LeasePinger.java
  Log:
  JBREM-649 - fixed thread sync issue for lease pinging
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.53.2.9  +24 -24    JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.53.2.8
  retrieving revision 1.53.2.9
  diff -u -b -r1.53.2.8 -r1.53.2.9
  --- Client.java	7 Dec 2006 20:45:39 -0000	1.53.2.8
  +++ Client.java	12 Dec 2006 03:48:04 -0000	1.53.2.9
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.53.2.8 $
  + * @version $Revision: 1.53.2.9 $
    */
   public class Client implements Externalizable
   {
  @@ -686,7 +686,7 @@
       * is handled by thread in this pool and user's call returns immediately)
       * Default value is MAX_NUM_ONEWAY_THREADS.
       *
  -    * @param numOfThreads
  +    * @param maxOnewayThreadPoolQueueSize
       */
      public void setMaxOnewayThreadPoolQueueSize(int maxOnewayThreadPoolQueueSize)
      {
  
  
  
  1.8.2.1   +13 -9     JBossRemoting/src/main/org/jboss/remoting/LeasePinger.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LeasePinger.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/LeasePinger.java,v
  retrieving revision 1.8
  retrieving revision 1.8.2.1
  diff -u -b -r1.8 -r1.8.2.1
  --- LeasePinger.java	21 Sep 2006 15:59:04 -0000	1.8
  +++ LeasePinger.java	12 Dec 2006 03:48:04 -0000	1.8.2.1
  @@ -10,6 +10,8 @@
   import java.util.Map;
   import java.util.TimerTask;
   
  +import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
  +
   /**
    * Internal agent class to ping the remote server to keep lease alive.
    *
  @@ -21,7 +23,7 @@
      private long pingPeriod = -1;
      private long defaultPingPeriod = -1;
      private String invokerSessionId = null;
  -   private Map clients = new HashMap();
  +   private Map clients = new ConcurrentHashMap();
      private TimerTask timerTask = null;
   
      private static final Logger log = Logger.getLogger(LeasePinger.class);
  @@ -35,7 +37,7 @@
         this.invokerSessionId = invokerSessionId;
      }
   
  -   public void startPing()
  +   public synchronized void startPing()
      {
         if(isTraceEnabled)
         {
  @@ -45,7 +47,7 @@
         TimerUtil.schedule(timerTask, pingPeriod);
      }
   
  -   public void stopPing()
  +   public synchronized void stopPing()
      {
         if(isTraceEnabled)
         {
  @@ -69,7 +71,7 @@
         }
      }
   
  -   protected void sendClientPing()
  +   protected synchronized void sendClientPing()
      {
         if (client != null)
         {
  @@ -92,9 +94,11 @@
                            "Currently managing lease for following clients:\n" + clientSessionIds);
               } // end trace
   
  -            Map clientsClone = new HashMap();
  -            clientsClone.put(ClientHolder.CLIENT_HOLDER_KEY, clients);
  -            client.invoke(new InvocationRequest(invokerSessionId, null, "$PING$", clientsClone, null, null));
  +            Map clientsClone = new ConcurrentHashMap();
  +            clientsClone.putAll(clients);
  +            Map requestClients = new ConcurrentHashMap();
  +            requestClients.put(ClientHolder.CLIENT_HOLDER_KEY, clientsClone);
  +            client.invoke(new InvocationRequest(invokerSessionId, null, "$PING$", requestClients, null, null));
            }
            catch (Throwable throwable)
            {
  @@ -103,7 +107,7 @@
         }
      }
   
  -   public void addClient(String sessionId, Map configuration, long leasePeriod)
  +   public synchronized void addClient(String sessionId, Map configuration, long leasePeriod)
      {
         if (leasePeriod <= 0)
         {
  @@ -134,7 +138,7 @@
         }
      }
   
  -   public boolean removeClient(String sessionId)
  +   public synchronized boolean removeClient(String sessionId)
      {
         boolean isLastClientLease = false;
   
  
  
  


From tom.elrod at jboss.com  Mon Dec 11 22:48:04 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Mon, 11 Dec 2006 22:48:04 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client
	...
Message-ID: <E1Gtyce-00021S-Bh@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/11 22:48:04

  Modified:    src/tests/org/jboss/test/remoting/callback/multiple/client 
                        Tag: remoting_2_x CallbackTestClient.java
  Log:
  JBREM-649 - fixed thread sync issue for lease pinging
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestClient.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- CallbackTestClient.java	9 Nov 2006 20:33:59 -0000	1.1.2.1
  +++ CallbackTestClient.java	12 Dec 2006 03:48:04 -0000	1.1.2.2
  @@ -183,7 +183,7 @@
               }
               catch (Throwable throwable)
               {
  -
  +               throwable.printStackTrace();
               }
               remotingClient2.disconnect();
            }
  
  
  


From tom.elrod at jboss.com  Mon Dec 11 23:55:30 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Mon, 11 Dec 2006 23:55:30 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting   ...
Message-ID: <E1Gtzfu-0003Fv-LL@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/11 23:55:30

  Modified:    src/main/org/jboss/remoting   Tag: remoting_2_x Client.java
                        ConnectionValidator.java
  Log:
  JBREM-648 - fix for NPE on connection validator after client disconnect.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.53.2.10 +7 -1      JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.53.2.9
  retrieving revision 1.53.2.10
  diff -u -b -r1.53.2.9 -r1.53.2.10
  --- Client.java	12 Dec 2006 03:48:04 -0000	1.53.2.9
  +++ Client.java	12 Dec 2006 04:55:30 -0000	1.53.2.10
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.53.2.9 $
  + * @version $Revision: 1.53.2.10 $
    */
   public class Client implements Externalizable
   {
  @@ -534,6 +534,12 @@
               enableLease = false;
            }
   
  +         if (connectionValidator!=null)
  +         {
  +            connectionValidator.stop();
  +            connectionValidator = null;
  +         }
  +
            /**
             * Need to remove myself from registry so will not keep
             * reference to me since I am of no use now. Will have to create
  
  
  
  1.13.2.1  +10 -5     JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java,v
  retrieving revision 1.13
  retrieving revision 1.13.2.1
  diff -u -b -r1.13 -r1.13.2.1
  --- ConnectionValidator.java	11 Oct 2006 20:22:41 -0000	1.13
  +++ ConnectionValidator.java	12 Dec 2006 04:55:30 -0000	1.13.2.1
  @@ -66,9 +66,13 @@
         TimerUtil.schedule(this, pingPeriod);
      }
   
  -   private void stop()
  +   public void stop()
      {
         cancel();
  +      if (!listeners.isEmpty())
  +      {
  +         listeners.clear();
  +      }
      }
   
   
  @@ -158,10 +162,11 @@
      {
         boolean pingWorked = false;
   
  -      HashMap configMap = new HashMap();
  -      if (config != null)
  -         configMap.putAll(config);
  -      
  +      Map configMap = config;
  +      if (configMap == null)
  +      {
  +         configMap = new HashMap();
  +      }
         configMap.put("connection_checker", "true");
         configMap.put("timeout", "1000");
         configMap.put("NumberOfRetries", "1");
  
  
  


From tom.elrod at jboss.com  Tue Dec 12 00:14:40 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Tue, 12 Dec 2006 00:14:40 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting   ...
Message-ID: <E1GtzyS-0003lb-Ap@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/12 00:14:40

  Modified:    src/main/org/jboss/remoting   ConnectionValidator.java
                        Client.java
  Log:
  JBREM-648 - fixe NPE for connection validator when client disconnects.
  
  Revision  Changes    Path
  1.14      +6 -2      JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ConnectionValidator.java	11 Oct 2006 20:22:41 -0000	1.13
  +++ ConnectionValidator.java	12 Dec 2006 05:14:40 -0000	1.14
  @@ -66,9 +66,13 @@
         TimerUtil.schedule(this, pingPeriod);
      }
   
  -   private void stop()
  +   public void stop()
      {
         cancel();
  +      if (!listeners.isEmpty())
  +      {
  +         listeners.clear();
  +   }
      }
   
   
  
  
  
  1.61      +24 -18    JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.60
  retrieving revision 1.61
  diff -u -b -r1.60 -r1.61
  --- Client.java	7 Dec 2006 20:44:09 -0000	1.60
  +++ Client.java	12 Dec 2006 05:14:40 -0000	1.61
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.60 $
  + * @version $Revision: 1.61 $
    */
   public class Client implements Externalizable
   {
  @@ -534,6 +534,12 @@
               enableLease = false;
            }
   
  +         if (connectionValidator!=null)
  +         {
  +            connectionValidator.stop();
  +            connectionValidator = null;
  +         }
  +
            /**
             * Need to remove myself from registry so will not keep
             * reference to me since I am of no use now. Will have to create
  
  
  


From tom.elrod at jboss.com  Tue Dec 12 00:16:50 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Tue, 12 Dec 2006 00:16:50 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gu00Y-0003pm-Dt@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/12 00:16:50

  Modified:    src/main/org/jboss/remoting  LeasePinger.java
  Log:
  JBREM-649 - fixed thread sync issue for lease pinging
  
  Revision  Changes    Path
  1.9       +12 -9     JBossRemoting/src/main/org/jboss/remoting/LeasePinger.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LeasePinger.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/LeasePinger.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- LeasePinger.java	21 Sep 2006 15:59:04 -0000	1.8
  +++ LeasePinger.java	12 Dec 2006 05:16:50 -0000	1.9
  @@ -1,5 +1,6 @@
   package org.jboss.remoting;
   
  +import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
   import org.jboss.logging.Logger;
   import org.jboss.remoting.transport.ClientInvoker;
   import org.jboss.remoting.util.TimerUtil;
  @@ -21,7 +22,7 @@
      private long pingPeriod = -1;
      private long defaultPingPeriod = -1;
      private String invokerSessionId = null;
  -   private Map clients = new HashMap();
  +   private Map clients = new ConcurrentHashMap();
      private TimerTask timerTask = null;
   
      private static final Logger log = Logger.getLogger(LeasePinger.class);
  @@ -35,7 +36,7 @@
         this.invokerSessionId = invokerSessionId;
      }
   
  -   public void startPing()
  +   public synchronized void startPing()
      {
         if(isTraceEnabled)
         {
  @@ -45,7 +46,7 @@
         TimerUtil.schedule(timerTask, pingPeriod);
      }
   
  -   public void stopPing()
  +   public synchronized void stopPing()
      {
         if(isTraceEnabled)
         {
  @@ -69,7 +70,7 @@
         }
      }
   
  -   protected void sendClientPing()
  +   protected synchronized void sendClientPing()
      {
         if (client != null)
         {
  @@ -92,9 +93,11 @@
                            "Currently managing lease for following clients:\n" + clientSessionIds);
               } // end trace
   
  -            Map clientsClone = new HashMap();
  -            clientsClone.put(ClientHolder.CLIENT_HOLDER_KEY, clients);
  -            client.invoke(new InvocationRequest(invokerSessionId, null, "$PING$", clientsClone, null, null));
  +            Map clientsClone = new ConcurrentHashMap();
  +            clientsClone.putAll(clients);
  +            Map requestClients = new ConcurrentHashMap();
  +            requestClients.put(ClientHolder.CLIENT_HOLDER_KEY, clientsClone);
  +            client.invoke(new InvocationRequest(invokerSessionId, null, "$PING$", requestClients, null, null));
            }
            catch (Throwable throwable)
            {
  @@ -103,7 +106,7 @@
         }
      }
   
  -   public void addClient(String sessionId, Map configuration, long leasePeriod)
  +   public synchronized void addClient(String sessionId, Map configuration, long leasePeriod)
      {
         if (leasePeriod <= 0)
         {
  @@ -134,7 +137,7 @@
         }
      }
   
  -   public boolean removeClient(String sessionId)
  +   public synchronized boolean removeClient(String sessionId)
      {
         boolean isLastClientLease = false;
   
  
  
  


From t2-okada at nri.co.jp  Tue Dec 12 00:40:57 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 00:40:57 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor
	...
Message-ID: <E1Gu0Nt-0004Cq-IV@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 00:40:57

  Modified:    java/src/expansion/org/jboss/profiler/exp/agent/interceptor   
                        Tag: JBossProfiler_Expansion AopInterceptor.java
                        ServletInterceptor.java DriverWrapper.java
  Log:
  Added error messages.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.6   +6 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor/Attic/AopInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AopInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor/Attic/AopInterceptor.java,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -b -r1.1.2.5 -r1.1.2.6
  --- AopInterceptor.java	28 Nov 2006 05:40:11 -0000	1.1.2.5
  +++ AopInterceptor.java	12 Dec 2006 05:40:57 -0000	1.1.2.6
  @@ -26,6 +26,7 @@
   import java.lang.reflect.Method;
   import java.util.Arrays;
   import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.RejectedExecutionException;
   import java.util.concurrent.ThreadPoolExecutor;
   import java.util.concurrent.TimeUnit;
   import java.util.concurrent.atomic.AtomicBoolean;
  @@ -184,7 +185,11 @@
           factory.updateCollector(collector);
           long threadId = RequestSequence.get();
           if(async) {
  +            try {
               asyncExecutor.execute(new InvocationSubmissionWrapper(collector, invocation, threadId));
  +            } catch (RejectedExecutionException e) {
  +                logger.error("A collector was rejected to insert into the collector pool.");
  +            }
           } else {
               processCollection(collector, invocation, threadId);
           }
  
  
  
  1.1.2.6   +6 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor/Attic/ServletInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServletInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor/Attic/ServletInterceptor.java,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -b -r1.1.2.5 -r1.1.2.6
  --- ServletInterceptor.java	28 Nov 2006 02:49:12 -0000	1.1.2.5
  +++ ServletInterceptor.java	12 Dec 2006 05:40:57 -0000	1.1.2.6
  @@ -26,6 +26,7 @@
   import java.lang.reflect.Constructor;
   import java.util.Map;
   import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.RejectedExecutionException;
   import java.util.concurrent.ThreadPoolExecutor;
   import java.util.concurrent.TimeUnit;
   import java.util.concurrent.atomic.AtomicBoolean;
  @@ -152,7 +153,11 @@
   	    if(operationName!=null) {
               factory.updateCollector(collector);
               if(async) {
  +                try {
                   asyncExecutor.execute(new InvocationSubmissionWrapper(collector, retrieveParameter(servletRequest), threadId));
  +                } catch (RejectedExecutionException e) {
  +                    logger.error("A collector was rejected to insert into the collector pool.");
  +                }
               } else {
                   processCollection(collector, retrieveParameter(servletRequest), threadId);
               }
  
  
  
  1.1.2.8   +6 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor/Attic/DriverWrapper.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DriverWrapper.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/interceptor/Attic/DriverWrapper.java,v
  retrieving revision 1.1.2.7
  retrieving revision 1.1.2.8
  diff -u -b -r1.1.2.7 -r1.1.2.8
  --- DriverWrapper.java	28 Nov 2006 05:40:11 -0000	1.1.2.7
  +++ DriverWrapper.java	12 Dec 2006 05:40:57 -0000	1.1.2.8
  @@ -31,6 +31,7 @@
   import java.util.Arrays;
   import java.util.Properties;
   import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.RejectedExecutionException;
   import java.util.concurrent.ThreadPoolExecutor;
   import java.util.concurrent.TimeUnit;
   import java.util.concurrent.atomic.AtomicBoolean;
  @@ -188,7 +189,11 @@
           factory.updateCollector(collector);
           long threadId = RequestSequence.get();
           if(async) {
  +            try {
               asyncExecutor.execute(new InvocationSubmissionWrapper(collector, threadId, method, args));
  +            } catch (RejectedExecutionException e) {
  +                logger.error("A collector was rejected to insert into the collector pool.");
  +            }
           } else {
               processCollection(collector, threadId, method, args);
           }
  
  
  


From forge-admin at jboss.com  Tue Dec 12 01:00:33 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Tue, 12 Dec 2006 01:00:33 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gu0gr-0004VN-5m@committer01.frg.pub.inap.atl.jboss.com>

Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 04:02 EST)
------------------------------------------------------

fixed timing issue

  JBossCache  tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java  1.9.2.4


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 04:04 EST)
------------------------------------------------------

fixed broken test

  JBossCache  tests/functional/org/jboss/cache/transaction/PrepareTxTest.java  1.1.20.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 04:17 EST)
------------------------------------------------------

added gc in setup

  JBossCache  tests/functional/org/jboss/cache/marshall/JBossSerializationTest.java  1.5.2.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 04:17 EST)
------------------------------------------------------

commented out classic deadlock test

  JBossCache  tests/functional/org/jboss/cache/transaction/DeadlockTest.java  1.4.2.1


Commit from msurtani (2006-12-11 05:07 EST)
--------------------

Port JBCACHE-874 tests from 1.4.0 branch

- JBossCache  tests/functional/org/jboss/cache/marshall/Foo.clazz    1.2
- JBossCache  tests/functional/org/jboss/cache/marshall/Foo.notjava  1.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 05:08 EST)
------------------------------------------------------

*** empty log message ***

+ JBossCache  tests/functional/org/jboss/cache/marshall/Foo.clazz  1.1.2.3
  JBossCache  etc/log4j.xml                                        1.15.2.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 05:10 EST)
------------------------------------------------------

commented out classic deadlock test

  JBossCache  etc/log4j.xml  1.15.2.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 05:11 EST)
------------------------------------------------------

added tests/functional to the test classpaths
added preferIPv4 to test targets

  JBossCache  build.xml  1.119.2.16


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 05:50 EST)
------------------------------------------------------

reduced concurrency test to 5 instances from 10

  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java  1.12.2.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 09:46 EST)
------------------------------------------------------

Fixed weird bugs

  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java            1.3.4.2
  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java                        1.3.2.2
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                         1.21.2.3
  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java          1.25.2.10
  JBossCache  src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java  1.21.2.2


Commit from rawb (2006-12-11 10:43 EST)
----------------

Switched publishing for JST artifacts to a JSTPackagesePublisher, which uses the packages infrastructure to build the project.

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java       1.17
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java  1.1


Commit from rawb (2006-12-11 10:49 EST)
----------------

Splendid! (added removal / undeployment of module)

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java  1.3


Commit from rawb (2006-12-11 10:51 EST)
----------------

Made the packaged adapter "heavier" so that we are less likely to get multiple modules for the same project. (In other words, a WTP module will not have a corresponding PackagedModule, whereas a regular java project will)

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml  1.22


Commit from rawb (2006-12-11 10:53 EST)
----------------

Added null checks. They came up in testing but not consistantly, so really I'm not sure they need to be there. They might have only shown up in testing due to some crazy breakpoint locations. I don't know.

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java  1.5


Commit from rawb (2006-12-11 10:55 EST)
----------------

I didnt like the idea of that extension anyway...  (timeout listener)

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml  1.27


Commit from rawb (2006-12-11 11:55 EST)
----------------

dependence on ui

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF  1.12


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 12:29 EST)
------------------------------------------------------

Fixed a bunch of problems with Optimistic data versioning related to JBCACHE-894
Updated logging libs JBCACHE-901

  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java          1.25.2.11
  JBossCache  src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java  1.21.2.3
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java               1.21.2.7
  JBossCache  src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java        1.21.2.5
  JBossCache  lib/commons-logging.jar                                                       1.1.1.1.24.1
  JBossCache  lib/log4j.jar                                                                 1.1.1.1.24.1
  JBossCache  lib/jgroups.jar                                                               1.4.2.5
  JBossCache  etc/log4j.xml                                                                 1.15.2.3
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java        1.1.2.3
  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java                        1.3.2.3
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                         1.21.2.4
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNode.java                             1.12.2.1
  JBossCache  tests/perf/org/jboss/cache/ConcurrentEvictAndRemoveTest.java                  1.3.4.1


Commit from msurtani (2006-12-11 12:31 EST)
--------------------

cleaned up jmx interfaces, fixed tx and gtx allocation problems

- JBossCache  lib/jrunit.jar                1.9
- JBossCache  lib/jcommon-1.0.0-rc1.jar     1.2
- JBossCache  lib/jfreechart-1.0.0-rc1.jar  1.2


Commit from msurtani (2006-12-11 12:35 EST)
--------------------

Fixed some broken UTs to use the new xml parsers, cache factories, etc.

- JBossCache  tests/perf/org/jboss/cache/benchmark/support/Read50PercentTest.java               1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/support/Read75PercentTest.java               1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/support/Read90PercentTest.java               1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/support/BaseTest.java                        1.13
- JBossCache  tests/perf/org/jboss/cache/benchmark/support/TreeCacheConfigurator.java           1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/ReplAsyncPessRead75JRunitTest.java     1.2
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/ReplSyncPessRead90JRunitTest.java      1.2
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/LocalPessIsoRRRead50JRunitTest.java    1.3
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/HashMapRead50JRunitTest.java           1.7
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/LocalPessIsoNoneRead75JRunitTest.java  1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/ReplAsyncPessRead50JRunitTest.java     1.2
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/LocalPessIsoNoneRead90JRunitTest.java  1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/LocalPessIsoRRRead90JRunitTest.java    1.3
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/ReplSyncPessRead50JRunitTest.java      1.2
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/LocalPessIsoNoneRead50JRunitTest.java  1.4
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/ReplSyncPessRead75JRunitTest.java      1.2
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/HashMapRead75JRunitTest.java           1.7
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/HashMapRead90JRunitTest.java           1.8
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/LocalPessIsoRRRead75JRunitTest.java    1.3
- JBossCache  tests/perf/org/jboss/cache/benchmark/tests/ReplAsyncPessRead90JRunitTest.java     1.2


Commit from msurtani (2006-12-11 12:39 EST)
--------------------

Updated jars

- JBossCache  lib/log4j-1.2.13.jar  1.2
+ JBossCache  lib/log4j-1.2.14.jar  1.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-11 13:00 EST)
------------------------------------------------------

fixed pojocache oddities

  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.20.2.6


Commit from dimitris (2006-12-11 14:20 EST)
--------------------

Mark JBossAOP 1.5.x compatible with javassist 3.4

  repository.jboss.com  jboss/aop/snapshot-Branch_AOP_1_5/component-info.xml  1.3


Commit from dimitris (2006-12-11 15:00 EST)
--------------------

Mark compatible with javassist 3.4.GA

  repository.jboss.com  jboss/jbossws/1.0.4.GA/component-info.xml  1.2


Commit from dimitris (2006-12-11 15:25 EST)
--------------------

Mark compatible with javassist 3.4.GA

  repository.jboss.com  jboss/jbossws14/1.0.4.GA/component-info.xml  1.2


Commit from genman (2006-12-11 16:14 EST)
------------------

JBCACHE-902 - Add serialver

  JBossCache  src/org/jboss/cache/CacheException.java                          1.5
  JBossCache  src/org/jboss/cache/Modification.java                            1.7
  JBossCache  src/org/jboss/cache/NodeImpl.java                                1.23
  JBossCache  src/org/jboss/cache/NodeNotExistsException.java                  1.2
  JBossCache  src/org/jboss/cache/ReplicationException.java                    1.5
  JBossCache  src/org/jboss/cache/SuspectException.java                        1.2
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyGroup.java             1.8
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyNotInitException.java  1.3
  JBossCache  src/org/jboss/cache/config/ConfigurationException.java           1.4
  JBossCache  src/org/jboss/cache/eviction/EvictionException.java              1.4
  JBossCache  src/org/jboss/cache/eviction/ExpirationConfiguration.java        1.3
  JBossCache  src/org/jboss/cache/eviction/NodeEntry.java                      1.11
  JBossCache  src/org/jboss/cache/eviction/RegionNameConflictException.java    1.4
  JBossCache  src/org/jboss/cache/loader/NodeDataExceptionMarker.java          1.3
  JBossCache  src/org/jboss/cache/loader/NodeDataMarker.java                   1.2
  JBossCache  src/org/jboss/cache/lock/DeadlockException.java                  1.2
  JBossCache  src/org/jboss/cache/lock/LockingException.java                   1.2
  JBossCache  src/org/jboss/cache/lock/NonBlockingWriterLock.java              1.3
  JBossCache  src/org/jboss/cache/lock/OwnerNotExistedException.java           1.4
  JBossCache  src/org/jboss/cache/lock/SemaphoreLock.java                      1.2
  JBossCache  src/org/jboss/cache/lock/SimpleReadWriteLock.java                1.3
  JBossCache  src/org/jboss/cache/lock/UpgradeException.java                   1.2
  JBossCache  src/org/jboss/cache/marshall/InactiveRegionException.java        1.2
  JBossCache  src/org/jboss/cache/marshall/MarshallingException.java           1.4
  JBossCache  src/org/jboss/cache/marshall/MethodCall.java                     1.3
  JBossCache  src/org/jboss/cache/marshall/RegionNameConflictException.java    1.5
  JBossCache  src/org/jboss/cache/marshall/RegionNotFoundException.java        1.5
  JBossCache  src/org/jboss/cache/optimistic/DataVersioningException.java      1.3
  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java           1.5
  JBossCache  src/org/jboss/cache/util/MapCopy.java                            1.5


Commit from genman (2006-12-11 16:17 EST)
------------------

Still doesn't work 100% but starts.
App should probably be removed or rewritten.

  JBossCache  src/org/jboss/cache/TreeCacheView.java  1.17


Commit from mandersen (2006-12-11 17:21 EST)
---------------------

HBX-830  Database errors should not be displayed in Log Error view
HBX-837 Have seperate logs per configuration

  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/execution/DefaultExecutionContext.java  1.3
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/KnownConfigurations.java                1.8
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/ConsoleConfiguration.java               1.14
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging/PluginLogAppender.java          1.4
+ jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/eclipse/logging/CurrentContext.java             1.1
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/hibernate-log4j.properties                                        1.5
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/META-INF/MANIFEST.MF                                              1.48


Commit from myuan (2006-12-11 19:04 EST)
-----------------

update the hibernate libs to GA

  jboss-seam  hibernate/lib/hibernate-annotations.jar    1.2
  jboss-seam  hibernate/lib/hibernate-entitymanager.jar  1.3


Commit from myuan (2006-12-11 19:06 EST)
-----------------

reformat the config file

  jboss-seam  examples/jpa/resources/components.xml         1.2
  jboss-seam  examples/jpa/resources/tomcat/components.xml  1.4


Commit from telrod on branch remoting_2_x (2006-12-11 22:48 EST)
-----------------------------------------

JBREM-649 - fixed thread sync issue for lease pinging

  JBossRemoting  src/main/org/jboss/remoting/Client.java                                             1.53.2.9
  JBossRemoting  src/main/org/jboss/remoting/LeasePinger.java                                        1.8.2.1
  JBossRemoting  src/tests/org/jboss/test/remoting/callback/multiple/client/CallbackTestClient.java  1.1.2.2


Commit from telrod on branch remoting_2_x (2006-12-11 23:55 EST)
-----------------------------------------

JBREM-648 - fix for NPE on connection validator after client disconnect.

  JBossRemoting  src/main/org/jboss/remoting/Client.java               1.53.2.10
  JBossRemoting  src/main/org/jboss/remoting/ConnectionValidator.java  1.13.2.1


Commit from telrod (2006-12-12 00:14 EST)
------------------

JBREM-648 - fixe NPE for connection validator when client disconnects.

  JBossRemoting  src/main/org/jboss/remoting/ConnectionValidator.java  1.14
  JBossRemoting  src/main/org/jboss/remoting/Client.java               1.61


Commit from telrod (2006-12-12 00:16 EST)
------------------

JBREM-649 - fixed thread sync issue for lease pinging

  JBossRemoting  src/main/org/jboss/remoting/LeasePinger.java  1.9


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 00:40 EST)
----------------------------------------------------

Added error messages.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/interceptor/AopInterceptor.java      1.1.2.6
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/interceptor/ServletInterceptor.java  1.1.2.6
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/interceptor/DriverWrapper.java       1.1.2.8
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061212/e156a674/attachment.html 

From jgreene at jboss.com  Tue Dec 12 02:12:40 2006
From: jgreene at jboss.com (Jason Thomas Greene)
Date: Tue, 12 Dec 2006 02:12:40 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1Gu1oe-0005yM-Vk@committer01.frg.pub.inap.atl.jboss.com>

  User: jgreene 
  Date: 06/12/12 02:12:40

  Modified:    jboss/jbossws/snapshot/lib          jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws-jboss-integration.jar jbossws-src.zip
                        jbossws-tomcat-integration.jar jbossws.sar
  Added:       jboss/jbossws/snapshot/lib          jbossws.deployer
  Log:
  sync snapshot
  
  Revision  Changes    Path
  1.29      +124 -123  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.28      +291 -231  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.29      +70 -69    repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.40      +2598 -2151repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.2       +87 -93    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar
  
  	<<Binary file>>
  
  
  1.2       +2157 -2706repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-src.zip
  
  	<<Binary file>>
  
  
  1.2       +38 -37    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar
  
  	<<Binary file>>
  
  
  1.40      +34 -5194  repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/12 07:12:38;  author: jgreene;  state: Exp;repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.deployer
  
  	<<Binary file>>
  
  


From jgreene at jboss.com  Tue Dec 12 02:14:45 2006
From: jgreene at jboss.com (Jason Thomas Greene)
Date: Tue, 12 Dec 2006 02:14:45 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1Gu1qf-0005yj-BX@committer01.frg.pub.inap.atl.jboss.com>

  User: jgreene 
  Date: 06/12/12 02:14:45

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  sync snapshot
  
  Revision  Changes    Path
  1.34      +1 -0      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- component-info.xml	7 Dec 2006 15:41:14 -0000	1.33
  +++ component-info.xml	12 Dec 2006 07:14:45 -0000	1.34
  @@ -32,6 +32,7 @@
   
         <export>
            <include input="jbossws.sar"/>
  +         <include input="jbossws.deployer"/>
            <include input="jbossws-client.jar"/>
            <include input="jboss-jaxrpc.jar"/>
            <include input="jboss-jaxws.jar"/>
  
  
  


From jgreene at jboss.com  Tue Dec 12 02:41:44 2006
From: jgreene at jboss.com (Jason Thomas Greene)
Date: Tue, 12 Dec 2006 02:41:44 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1Gu2Gm-0006R1-Eg@committer01.frg.pub.inap.atl.jboss.com>

  User: jgreene 
  Date: 06/12/12 02:41:44

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  sync snapshot
  
  Revision  Changes    Path
  1.35      +1 -0      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- component-info.xml	12 Dec 2006 07:14:45 -0000	1.34
  +++ component-info.xml	12 Dec 2006 07:41:44 -0000	1.35
  @@ -6,6 +6,7 @@
                 description="JBossWS an implementation of J2EE Web Services">
   
         <artifact id="jbossws.sar"/>
  +      <artifact id="jbossws.deployer"/>
         <artifact id="jbossws-client.jar"/>
         <artifact id="jboss-jaxrpc.jar"/>
         <artifact id="jboss-jaxws.jar"/>
  
  
  


From michael.yuan at jboss.com  Tue Dec 12 02:42:59 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Tue, 12 Dec 2006 02:42:59 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/weblogic  ...
Message-ID: <E1Gu2Hz-0006Tt-O0@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/12 02:42:59

  Modified:    examples/hibernate2/resources/weblogic  components.xml
  Log:
  simplify the components.xml files
  
  Revision  Changes    Path
  1.2       +26 -5     jboss-seam/examples/hibernate2/resources/weblogic/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/weblogic/components.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- components.xml	30 Nov 2006 04:43:15 -0000	1.1
  +++ components.xml	12 Dec 2006 07:42:59 -0000	1.2
  @@ -1,19 +1,39 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
   
  +    <core:init debug="true"/>    
  +
  +    <core:pages no-conversation-view-id="/main.xhtml"/>
  +
  +    <core:manager conversation-timeout="120000" 
  +                  concurrent-request-timeout="500"
  +                  conversation-id-parameter="cid"
  +                  conversation-is-long-running-parameter="clr"/>
  +                  
  +    <core:hibernate-session-factory name="hibernateSessionFactory"/>
  +    
  +    <core:managed-hibernate-session name="bookingDatabase"
  +                          sessionFactoryJndiName="bookingDatabase"/>
  +    
  +</components>
  +
  +
  +<!--
   <components>
   
       <component name="org.jboss.seam.core.init">
           <property name="debug">true</property>
       </component>
   
  -    <!-- 120 second conversation timeout -->
       <component name="org.jboss.seam.core.manager">
           <property name="conversationTimeout">120000</property>
       </component>
       
  -    <!-- Bootstrap Hibernate -->
       <component name="bookingDatabase" 
                 sessionFactoryJndiName="bookingDatabase"
                 class="org.jboss.seam.core.ManagedHibernateSession"/>
  @@ -21,3 +41,4 @@
                 class="org.jboss.seam.core.HibernateSessionFactory"/> 
       
   </components>
  +-->
  \ No newline at end of file
  
  
  


From michael.yuan at jboss.com  Tue Dec 12 02:42:59 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Tue, 12 Dec 2006 02:42:59 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources  ...
Message-ID: <E1Gu2Hz-0006TY-9U@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/12 02:42:59

  Modified:    examples/hibernate2/resources  components.xml
  Log:
  simplify the components.xml files
  
  Revision  Changes    Path
  1.2       +24 -5     jboss-seam/examples/hibernate2/resources/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/components.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- components.xml	28 Nov 2006 21:35:57 -0000	1.1
  +++ components.xml	12 Dec 2006 07:42:59 -0000	1.2
  @@ -1,22 +1,41 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
   
  +    <core:init debug="true"/>    
  +
  +    <core:pages no-conversation-view-id="/main.xhtml"/>
  +
  +    <core:manager conversation-timeout="120000" 
  +                  concurrent-request-timeout="500"
  +                  conversation-id-parameter="cid"
  +                  conversation-is-long-running-parameter="clr"/>
  +                  
  +    <core:hibernate-session-factory name="hibernateSessionFactory"/>
  +    
  +    <core:managed-hibernate-session name="bookingDatabase"/>
  +    
  +</components>
  +
  +<!--
   <components>
   
       <component name="org.jboss.seam.core.init">
           <property name="debug">true</property>
       </component>
   
  -    <!-- 120 second conversation timeout -->
       <component name="org.jboss.seam.core.manager">
           <property name="conversationTimeout">120000</property>
       </component>
       
  -    <!-- Bootstrap Hibernate -->
       <component name="bookingDatabase" 
                 class="org.jboss.seam.core.ManagedHibernateSession"/>
       <component name="hibernateSessionFactory"
                 class="org.jboss.seam.core.HibernateSessionFactory"/> 
       
   </components>
  +-->
  \ No newline at end of file
  
  
  


From michael.yuan at jboss.com  Tue Dec 12 02:42:59 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Tue, 12 Dec 2006 02:42:59 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/tomcat  ...
Message-ID: <E1Gu2Hz-0006Tm-Jk@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/12 02:42:59

  Modified:    examples/hibernate2/resources/tomcat  components.xml
  Log:
  simplify the components.xml files
  
  Revision  Changes    Path
  1.4       +26 -5     jboss-seam/examples/hibernate2/resources/tomcat/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/tomcat/components.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- components.xml	21 Nov 2006 20:14:08 -0000	1.3
  +++ components.xml	12 Dec 2006 07:42:59 -0000	1.4
  @@ -1,19 +1,39 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
   
  +    <core:init debug="true"/>    
  +
  +    <core:pages no-conversation-view-id="/main.xhtml"/>
  +
  +    <core:manager conversation-timeout="120000" 
  +                  concurrent-request-timeout="500"
  +                  conversation-id-parameter="cid"
  +                  conversation-is-long-running-parameter="clr"/>
  +                  
  +    <core:hibernate-session-factory name="hibernateSessionFactory"/>
  +    
  +    <core:managed-hibernate-session name="bookingDatabase"/>
  +    
  +    <core:microcontainer installed="true"/>
  +    
  +</components>
  +
  +<!--
   <components>
   
       <component name="org.jboss.seam.core.init">
           <property name="debug">true</property>
       </component>
   
  -    <!-- 120 second conversation timeout -->
       <component name="org.jboss.seam.core.manager">
           <property name="conversationTimeout">120000</property>
       </component>
       
  -    <!-- Bootstrap Hibernate -->
       <component name="bookingDatabase" 
                 class="org.jboss.seam.core.ManagedHibernateSession"/>
       <component name="hibernateSessionFactory"
  @@ -22,3 +42,4 @@
       <component class="org.jboss.seam.core.Microcontainer"/>
       
   </components>
  +-->
  \ No newline at end of file
  
  
  


From michael.yuan at jboss.com  Tue Dec 12 02:42:59 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Tue, 12 Dec 2006 02:42:59 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/glassfish  ...
Message-ID: <E1Gu2Hz-0006Tf-D8@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/12 02:42:59

  Modified:    examples/hibernate2/resources/glassfish  components.xml
  Log:
  simplify the components.xml files
  
  Revision  Changes    Path
  1.2       +25 -5     jboss-seam/examples/hibernate2/resources/glassfish/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/glassfish/components.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- components.xml	30 Nov 2006 04:43:15 -0000	1.1
  +++ components.xml	12 Dec 2006 07:42:59 -0000	1.2
  @@ -1,19 +1,38 @@
  -<!DOCTYPE components PUBLIC
  -  "-//JBoss/Seam Component Configuration DTD 1.1//EN"
  -  "http://jboss.com/products/seam/components-1.1.dtd">
  +<?xml version="1.0" encoding="UTF-8"?>
  +<components xmlns="http://jboss.com/products/seam/components"
  +            xmlns:core="http://jboss.com/products/seam/core"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
   
  +    <core:init debug="true"/>    
  +
  +    <core:pages no-conversation-view-id="/main.xhtml"/>
  +
  +    <core:manager conversation-timeout="120000" 
  +                  concurrent-request-timeout="500"
  +                  conversation-id-parameter="cid"
  +                  conversation-is-long-running-parameter="clr"/>
  +                  
  +    <core:hibernate-session-factory name="hibernateSessionFactory"/>
  +    
  +    <core:managed-hibernate-session name="bookingDatabase"
  +                          sessionFactoryJndiName="bookingDatabase"/>
  +    
  +</components>
  +
  +<!--
   <components>
   
       <component name="org.jboss.seam.core.init">
           <property name="debug">true</property>
       </component>
   
  -    <!-- 120 second conversation timeout -->
       <component name="org.jboss.seam.core.manager">
           <property name="conversationTimeout">120000</property>
       </component>
       
  -    <!-- Bootstrap Hibernate -->
       <component name="bookingDatabase" 
                 sessionFactoryJndiName="bookingDatabase"
                 class="org.jboss.seam.core.ManagedHibernateSession"/>
  @@ -21,3 +40,4 @@
                 class="org.jboss.seam.core.HibernateSessionFactory"/> 
       
   </components>
  +-->
  \ No newline at end of file
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 03:12:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 03:12:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1768 - trunk
Message-ID: <E1Gu2l0-00078Q-TP@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-12 03:12:41 -0500 (Tue, 12 Dec 2006)
New Revision: 1768

Added:
   trunk/jboss-remoting-npe-fix.jar
Log:
Temporary jar that fixes bug in connection validation until fixed in remoting - needed for clustering



Added: trunk/jboss-remoting-npe-fix.jar
===================================================================
(Binary files differ)


Property changes on: trunk/jboss-remoting-npe-fix.jar
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream



From t2-okada at nri.co.jp  Tue Dec 12 03:28:43 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 03:28:43 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/lzx    ...
Message-ID: <E1Gu30F-0007Nb-Ns@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 03:28:43

  Modified:    java/webapp/lzx    Tag: JBossProfiler_Expansion treegrid.lzx
                        settingdialog.lzx webapplicationanalyzer.lzx
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +57 -56    jboss-profiler/java/webapp/lzx/Attic/treegrid.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: treegrid.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/treegrid.lzx,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- treegrid.lzx	26 Oct 2006 09:02:25 -0000	1.1.2.1
  +++ treegrid.lzx	12 Dec 2006 08:28:43 -0000	1.1.2.2
  @@ -97,7 +97,9 @@
     
     
     <!-- hierarchical cell component for treegrid -->
  -  <class name="hcell" extends="view">
  +  <class name="hcell" extends="view" clip="true">
  +    
  +    <view name="contents">
       <simplelayout axis="x" spacing="0"/>
       <view width="8"/>
       <view name="expander"
  @@ -106,44 +108,45 @@
             xoffset="6" yoffset="12"
             stretches="both"
             resource="lztree_arrow_rsc"
  -          frame="${parent.nodetype=='m' ? 3 : 1}">
  +            frame="${classroot.nodetype=='m' ? 3 : 1}">
         <animator name="rotator" attribute="rotation"
  -                to="${parent.parent.isexpanded ? 0 : 90}"
  +                  to="${classroot.isexpanded ? 0 : 90}"
                   duration="400" motion="easeout" start="false"/>
         <handler name="onclick">
  -        parent._selectNode();
  +          classroot._selectNode();
         </handler>
       </view>
       <view name="iconfolder"
             x="${this.x-2}" y="4"
             width="12" height="10"
             stretches="both"
  -          visible="${parent.nodetype=='p' ? true : false}"
  +            visible="${classroot.nodetype=='p' ? true : false}"
             resource="lztree_folder_rsc"
  -          frame="${parent.nodetype=='p' ? (parent.isexpanded ? 2 : 1) : 3}" />
  +            frame="${classroot.nodetype=='p' ? (classroot.isexpanded ? 2 : 1) : 3}" />
       <view name="iconleaf"
             x="-12"
  -          visible="${parent.nodetype=='p' ? false : true}"
  -          resource="${parent.nodetype=='c' ? 'icon_class' : 'icon_method'}"/>
  -    <text name="label" width="${parent.width-120}"/>
  +            visible="${classroot.nodetype=='p' ? false : true}"
  +            resource="${classroot.nodetype=='c' ? 'icon_class' : 'icon_method'}"/>
  +      <text name="label" resize="true"/>
  +    </view>
       
       <attribute name="isexpanded" type="boolean" value="false"/>
       <attribute name="nodetype" type="string" value="p"/>
  -    <attribute name="parentGrid"/>
  +    <attribute name="parentGrid" required="true"/>
       <attribute name="key" type="string"/>
       <attribute name="keyDatapath" type="string"/>
       
       <handler name="ondata" args="d">
         <![CDATA[
         // set label
  -      this.label.setText(d);
  +      this.contents.label.setText(d);
         
         var viewDp = parentGrid.viewDs.getPointer();
         var initialized = viewDp.selectChild();
         
         if(!initialized) return;
         
  -      var recordNode = this.parent.parent.contentdatapath;
  +      var recordNode = parentGrid.contentdatapath;
         
         var keyAttr = null;
         if(typeof(keyDatapath)!="undefined" && keyDatapath!=null) {
  @@ -155,14 +158,14 @@
         
         // set depth
         var depth = this.datapath.getNodeAttribute("depth");
  -      this.setAttribute("x", 2 + (16 * (depth)));
  +      this.contents.setAttribute("x", 2 + (16 * (depth)));
         
         // set type
         var type = this.datapath.getNodeAttribute("type");
         if(type=="c" || type=="m") this.setAttribute("nodetype", type);
         else                       this.setAttribute("nodetype", 'p');
         
  -      this.expander.setAttribute("rotation", 0);
  +      this.contents.expander.setAttribute("rotation", 0);
         ]]>
       </handler>
       
  @@ -170,7 +173,7 @@
         <![CDATA[
         var sourceDpClone = parentGrid.sourceDp.dupePointer();
         
  -      var recordNode = this.parent.parent.contentdatapath;
  +      var recordNode = parentGrid.contentdatapath;
         
         var viewDpClone = this.datapath.dupePointer();
         
  @@ -183,9 +186,9 @@
         this.setAttribute("isexpanded", expanded);
         
         // set expander.rotator
  -      if(expanded) this.expander.setAttribute("rotation", 90);
  -      else         this.expander.setAttribute("rotation", 0);
  -      this.expander.rotator.doStart();
  +      if(expanded) this.contents.expander.setAttribute("rotation", 90);
  +      else         this.contents.expander.setAttribute("rotation", 0);
  +      this.contents.expander.rotator.doStart();
         
         // get depth of current node
         var depth = Number(this.datapath.getNodeAttribute("depth"));
  @@ -194,10 +197,11 @@
         var insertFlg = false;
         if(viewDpClone.selectNext()) {
           insertFlg = true;
  +        viewDpClone.selectPrev();
         }
         
  -      var viewDpClone2 = viewDpClone.dupePointer();
  -      viewDpClone.selectParent();
  +      var viewDpRoot = viewDpClone.dupePointer();
  +      viewDpRoot.selectParent();
         
         var keyAttr = null;
         var keyText = null;
  @@ -209,7 +213,6 @@
           keyText = this.key;
         }
         
  -      
         // replace to viewDs from sourceDs
         // # Laszlo does not support RegExp...
         // # and all of XPath specification...
  @@ -222,6 +225,8 @@
             sourceCurrentNodes[0] = temp;
           }
           
  +        if(insertFlg) viewDpClone.selectNext();
  +        
           for(var i in sourceCurrentNodes) {
             sourceDpClone.p = sourceCurrentNodes[i];
             var attr = sourceDpClone.getNodeAttributes();
  @@ -229,28 +234,24 @@
               attr["expanded"] = "false";
               var nn = new LzDataElement(recordNode, attr);
               if(insertFlg) {
  -              viewDpClone.p.insertBefore(nn, viewDpClone2.p);
  +              viewDpRoot.p.insertBefore(nn, viewDpClone.p);
               }else {
  -              viewDpClone.p.appendChild(nn);
  +              viewDpRoot.p.appendChild(nn);
               }
             }
           }
         }else {
  -        var viewCurrentNodes = null;
  -        var viewDpClone2 = viewDpClone.dupePointer();
  -        while((viewCurrentNodes = viewDpClone2.xpathQuery(recordNode + "[@depth='"+(++depth)+"']")) != null) {
  -          if(!(viewCurrentNodes instanceof Array)) {
  -            var temp = viewCurrentNodes;
  -            viewCurrentNodes = new Array();
  -            viewCurrentNodes[0] = temp;
  -          }
  -          
  -          for(var i in viewCurrentNodes) {
  -            viewDpClone.p = viewCurrentNodes[i];
  -            var attr = viewDpClone.getNodeAttributes();
  -              viewDpClone.deleteNode();
  -              viewDpClone.selectParent();
  -          }
  +        var deleteNodes = new Array();
  +        while(viewDpClone.selectNext()) {
  +          if(depth >= new Number(viewDpClone.getNodeAttribute("depth"))) {
  +            break;
  +          }
  +          deleteNodes.push(viewDpClone.p);
  +        }
  +        while(deleteNodes.length>0) {
  +          viewDpRoot.p = deleteNodes.pop();
  +          viewDpRoot.deleteNode();
  +          viewDpRoot.selectParent();
           }
         }
         
  
  
  
  1.1.2.4   +2 -2      jboss-profiler/java/webapp/lzx/Attic/settingdialog.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: settingdialog.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/settingdialog.lzx,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- settingdialog.lzx	7 Nov 2006 06:49:05 -0000	1.1.2.3
  +++ settingdialog.lzx	12 Dec 2006 08:28:43 -0000	1.1.2.4
  @@ -131,10 +131,10 @@
               </checkbox>
               <view name="values" placement="contents">
                 <simplelayout axis="x" spacing="2"/>
  -              <edittext name="fromDate" width="60" height="22"/>
  +              <edittext name="fromDate" width="80" height="22"/>
                 <edittext name="fromTime" width="60" height="22"/>
                 <text fontsize="24" y="${this.y-4}">-</text>
  -              <edittext name="toDate" width="60" height="22"/>
  +              <edittext name="toDate" width="80" height="22"/>
                 <edittext name="toTime" width="60" height="22"/>
               </view>
             </view>
  
  
  
  1.1.2.2   +2 -1      jboss-profiler/java/webapp/lzx/Attic/webapplicationanalyzer.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: webapplicationanalyzer.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/webapplicationanalyzer.lzx,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- webapplicationanalyzer.lzx	26 Oct 2006 09:02:25 -0000	1.1.2.1
  +++ webapplicationanalyzer.lzx	12 Dec 2006 08:28:43 -0000	1.1.2.2
  @@ -63,6 +63,7 @@
         </state>
         <view resource="icon_reload">
           <handler name="onclick">
  +          parent.parent.changeView(0);
           </handler>
         </view>
         <method name="setCategory" args="category">
  @@ -133,7 +134,7 @@
         if(index>1) {
           canvas.executionPassageDetailData.setQueryParam(AppInfo.RPK_CALLER, caller);
         }
  -      canvas.executionPassageDetailData.doRequest();
  +      canvas.executionPassageDetailData.doRequest();Debug.write("!");
         new LzDelegate(this, "onDataLoaded", canvas.executionPassageDetailData, "ondata");
       </method>
       
  
  
  


From dimitris.andreadis at jboss.com  Tue Dec 12 03:37:13 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Tue, 12 Dec 2006 03:37:13 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws14/1.0.4.GA  ...
Message-ID: <E1Gu38T-0007Wm-LR@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/12 03:37:13

  Modified:    jboss/jbossws14/1.0.4.GA  component-info.xml
  Log:
  Mark compatible with jboss-retro-rt 1.0.4.GA
  
  Revision  Changes    Path
  1.3       +1 -0      repository.jboss.com/jboss/jbossws14/1.0.4.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws14/1.0.4.GA/component-info.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- component-info.xml	11 Dec 2006 20:25:53 -0000	1.2
  +++ component-info.xml	12 Dec 2006 08:37:13 -0000	1.3
  @@ -29,6 +29,7 @@
         </import>
         <import componentref="jboss/jbossretro-rt">
         	<compatible version="1.0.2.GA"/>
  +      	<compatible version="1.0.4.GA"/>
         </import>
   
         <export>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 03:55:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 03:55:39 -0500
Subject: [jboss-cvs] JBossAS SVN: r58982 - in projects/microcontainer/trunk:
	kernel/src/main/org/jboss/beans/metadata/plugins
	spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1Gu3QJ-0007qd-Ho@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 03:55:27 -0500 (Tue, 12 Dec 2006)
New Revision: 58982

Added:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractLifecycleMetaData.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
JBMICROCONT-26; initial code commit, minor fixes

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractLifecycleMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractLifecycleMetaData.java	2006-12-11 21:36:29 UTC (rev 58981)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractLifecycleMetaData.java	2006-12-12 08:55:27 UTC (rev 58982)
@@ -63,6 +63,11 @@
    {
    }
 
+   public AbstractLifecycleMetaData(String methodName)
+   {
+      this.methodName = methodName;
+   }
+
    public ControllerState getState()
    {
       return state;

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-11 21:36:29 UTC (rev 58981)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-12 08:55:27 UTC (rev 58982)
@@ -47,16 +47,18 @@
    public void add(Object parent, Object child, QName name)
    {
       AbstractBeanMetaData bean = (AbstractBeanMetaData) parent;
-      ConstructorMetaData constructor = bean.getConstructor();
+      AbstractConstructorMetaData constructor = (AbstractConstructorMetaData) bean.getConstructor();
       if (constructor == null) {
-         AbstractConstructorMetaData tmpConstructor = new AbstractConstructorMetaData();
-         tmpConstructor.setParameters(new ArrayList<ParameterMetaData>());
-         constructor = tmpConstructor;
+         constructor = new AbstractConstructorMetaData();
          bean.setConstructor(constructor);
       }
       AbstractParameterMetaData parameter = (AbstractParameterMetaData) child;
-      // should not be null, since we are the only one creating constructor
       List<ParameterMetaData> parameters = constructor.getParameters();
+      if (parameters == null)
+      {
+         parameters = new ArrayList<ParameterMetaData>();
+         constructor.setParameters(parameters);
+      }
       if (parameter instanceof AbstractConstructorArg && ((AbstractConstructorArg)parameter).isExplicitIndex() == false)
       {
          parameter.setIndex(parameters.size());

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-11 21:36:29 UTC (rev 58981)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-12 08:55:27 UTC (rev 58982)
@@ -25,6 +25,9 @@
 import javax.xml.namespace.QName;
 
 import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.beans.metadata.plugins.AbstractLifecycleMetaData;
+import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
+import org.jboss.beans.metadata.plugins.AbstractDependencyValueMetaData;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
 import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
 import org.xml.sax.Attributes;
@@ -54,6 +57,23 @@
             bean.setName(attrs.getValue(i));
          else if ("class".equals(localName))
             bean.setBean(attrs.getValue(i));
+         else if ("init-method".equals(localName))
+            bean.setCreate(new AbstractLifecycleMetaData(attrs.getValue(i)));
+         else if ("destroy-method".equals(localName))
+            bean.setDestroy(new AbstractLifecycleMetaData(attrs.getValue(i)));
+         else if ("factory-method".equals(localName) || "factory-bean".equals(localName))
+         {
+            AbstractConstructorMetaData constructor = (AbstractConstructorMetaData) bean.getConstructor();
+            if (constructor == null)
+            {
+               constructor = new AbstractConstructorMetaData();
+               bean.setConstructor(constructor);
+            }
+            if ("factory-method".equals(localName))
+               constructor.setFactoryMethod(attrs.getValue(i));
+            if ("factory-bean".equals(localName))
+               constructor.setFactory(new AbstractDependencyValueMetaData(attrs.getValue(i)));
+         }
       }
    }
 

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java	2006-12-11 21:36:29 UTC (rev 58981)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java	2006-12-12 08:55:27 UTC (rev 58982)
@@ -52,17 +52,9 @@
       {
          String localName = attrs.getLocalName(i);
          if ("default-init-method".equals(localName))
-         {
-            AbstractLifecycleMetaData create = new AbstractLifecycleMetaData();
-            create.setMethodName(attrs.getValue(i));
-            deployment.setCreate(create);
-         }
+            deployment.setCreate(new AbstractLifecycleMetaData(attrs.getValue(i)));
          else if ("default-destroy-method".equals(localName))
-         {
-            AbstractLifecycleMetaData destroy = new AbstractLifecycleMetaData();
-            destroy.setMethodName(attrs.getValue(i));
-            deployment.setDestroy(destroy);
-         }
+            deployment.setDestroy(new AbstractLifecycleMetaData(attrs.getValue(i)));
       }
    }
 

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-11 21:36:29 UTC (rev 58981)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-12 08:55:27 UTC (rev 58982)
@@ -0,0 +1,72 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.QName;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
+import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
+import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
+import org.jboss.beans.metadata.spi.ConstructorMetaData;
+import org.jboss.beans.metadata.spi.ParameterMetaData;
+import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
+import org.jboss.spring.deployment.AbstractConstructorArg;
+import org.jboss.spring.deployment.AbstractSpringDeployment;
+import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringBeansInterceptor extends DefaultElementInterceptor
+{
+   /**
+    * The interceptor
+    */
+   public static final SpringBeansInterceptor INTERCEPTOR = new SpringBeansInterceptor();
+
+   public void add(Object parent, Object child, QName name)
+   {
+      AbstractSpringDeployment deployment = (AbstractSpringDeployment) parent;
+      AbstractBeanMetaData bean = (AbstractBeanMetaData) child;
+      List<BeanMetaDataFactory> beans = deployment.getBeanFactories();
+      if (beans == null)
+      {
+         beans = new ArrayList<BeanMetaDataFactory>();
+         deployment.setBeanFactories(beans);
+      }
+      // set deployment defaults, if not already set per bean
+      if (bean.getCreate() == null && deployment.getCreate() != null)
+      {
+         bean.setCreate(deployment.getCreate());
+      }
+      if (bean.getDestroy() == null && deployment.getDestroy() != null)
+      {
+         bean.setDestroy(deployment.getDestroy());
+      }
+      beans.add(bean);
+   }
+
+}

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-11 21:36:29 UTC (rev 58981)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 08:55:27 UTC (rev 58982)
@@ -34,7 +34,7 @@
    {
       typeBinding.setHandler(SpringBeansHandler.HANDLER);
       // handle beans
-      typeBinding.pushInterceptor(SpringSchemaBinding.beansQName, DeploymentBeanInterceptor.INTERCEPTOR);
+      typeBinding.pushInterceptor(SpringSchemaBinding.beansQName, SpringBeansInterceptor.INTERCEPTOR);
       // todo alias
       // todo import
    }
@@ -103,7 +103,20 @@
 
    public static void configureValueBindings(TypeBinding typeBinding)
    {
-      //todo
+      // type has values
+      typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, ValueMetaDataElementInterceptor.VALUES);
+
+      // type can take a list
+      typeBinding.pushInterceptor(SpringSchemaBinding.listQName, ValueMetaDataElementInterceptor.VALUES);
+
+      // type can take a set
+      typeBinding.pushInterceptor(SpringSchemaBinding.setQName, ValueMetaDataElementInterceptor.VALUES);
+
+      // type can take a map
+      typeBinding.pushInterceptor(SpringSchemaBinding.mapQName, ValueMetaDataElementInterceptor.VALUES);
+
+      // type has a null
+      typeBinding.pushInterceptor(SpringSchemaBinding.nullQName, NullValueElementInterceptor.NULLVALUES);
    }
 
 }



From t2-okada at nri.co.jp  Tue Dec 12 04:02:13 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:02:13 -0500
Subject: [jboss-cvs] jboss-profiler/java/mbean  ...
Message-ID: <E1Gu3Wf-0008Bc-Ea@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:02:13

  Modified:    java/mbean  Tag: JBossProfiler_Expansion
                        collector-config.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +8 -4      jboss-profiler/java/mbean/Attic/collector-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: collector-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/mbean/Attic/collector-config.xml,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- collector-config.xml	10 Nov 2006 09:19:54 -0000	1.1.2.1
  +++ collector-config.xml	12 Dec 2006 09:02:13 -0000	1.1.2.2
  @@ -3,7 +3,7 @@
     
     <!-- ##### JDBC Setting ##### -->
     <jdbc>
  -    <!-- ##### The implementation mapping set for the JBoss Application Server ##### -->
  +    <!-- ##### SAMPLE: The implementation mapping set for the JBoss Application Server ##### -->
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrapperDataSource" interface="java.sql.DataSource"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedConnection" interface="java.sql.Connection"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedStatement" interface="java.sql.Statement"/>
  @@ -15,9 +15,13 @@
     <!-- ##### Application Framework Setting ##### -->
     <!-- Add the following setting when the profiling application runs on the framework. -->
     <framework>
  -    <!-- ##### The expression set for the Spring Framework ##### -->
  -    <expression>org.springframework</expression>
  -    <!-- ##### The expression set for the iBATIS ##### -->
  +    <!-- ##### SAMPLE: The expression set for the Spring Framework ##### -->
  +    <expression>org.springframework.aop</expression>
  +    <expression>org.springframework.web</expression>
  +    <expression>org.springframework.dao</expression>
  +    <expression>org.springframework.transaction</expression>
  +    <expression>org.springframework.orm</expression>
  +    <!-- ##### SAMPLE: The expression set for the iBATIS ##### -->
       <expression>com.ibatis</expression>
     </framework>
     
  
  
  


From t2-okada at nri.co.jp  Tue Dec 12 04:06:09 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:06:09 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/WEB-INF  ...
Message-ID: <E1Gu3aT-0008HL-G5@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:06:09

  Modified:    java/webapp/WEB-INF  Tag: JBossProfiler_Expansion web.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +3 -23     jboss-profiler/java/webapp/WEB-INF/Attic/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/WEB-INF/Attic/web.xml,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- web.xml	6 Nov 2006 07:40:25 -0000	1.1.2.2
  +++ web.xml	12 Dec 2006 09:06:09 -0000	1.1.2.3
  @@ -7,14 +7,14 @@
   <web-app>
     
     <!-- ##### OpenLaszlo : LPS ##### -->
  -  <!--
  +  <!-- This description is needed only in the proxy mode.
     <servlet>
       <servlet-name>openlaszlo.LPS</servlet-name>
       <servlet-class>org.openlaszlo.servlets.LZServlet</servlet-class>
     </servlet>
     -->
     
  -  <!-- ##### JBoss Profiler : Agent Controllers ##### -->
  +  <!-- ##### JBoss Profiler : Servlet ##### -->
     <servlet>
       <servlet-name>jboss-profiler.Initializer</servlet-name>
       <servlet-class>org.jboss.profiler.exp.view.servlet.Initializer</servlet-class>
  @@ -35,19 +35,9 @@
       <servlet-name>jboss-profiler.ExecutionPassageDetail</servlet-name>
       <servlet-class>org.jboss.profiler.exp.view.servlet.ExecutionPassageDetail</servlet-class>
     </servlet>
  -  <!--
  -  <servlet>
  -    <servlet-name>jboss-profiler.ExecutionStack</servlet-name>
  -    <servlet-class>org.jboss.profiler.exp.view.servlet.ExecutionStack</servlet-class>
  -  </servlet>
  -  <servlet>
  -    <servlet-name>jboss-profiler.ExecutionPassage</servlet-name>
  -    <servlet-class>org.jboss.profiler.exp.view.servlet.ExecutionPassage</servlet-class>
  -  </servlet>
  -  -->
     
     <!-- ##### OpenLaszlo : Servlet Mapping ##### -->
  -  <!--
  +  <!-- This description is needed only in the proxy mode.
     <servlet-mapping>
       <servlet-name>openlaszlo.LPS</servlet-name>
       <url-pattern>*.lzx</url-pattern>
  @@ -75,15 +65,5 @@
       <servlet-name>jboss-profiler.ExecutionPassageDetail</servlet-name>
       <url-pattern>/ExecutionPassageDetail</url-pattern>
     </servlet-mapping>
  -  <!--
  -  <servlet-mapping>
  -    <servlet-name>jboss-profiler.ExecutionStack</servlet-name>
  -    <url-pattern>/ExecutionStack</url-pattern>
  -  </servlet-mapping>
  -  <servlet-mapping>
  -    <servlet-name>jboss-profiler.ExecutionPassage</servlet-name>
  -    <url-pattern>/ExecutionPassage</url-pattern>
  -  </servlet-mapping>
  -  -->
   
   </web-app>
  \ No newline at end of file
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:11:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:11:54 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1769 - in
	branches/Branch_Client_Failover_Experiment:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests tests/src/org/jboss/test/messaging/core
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gu3g2-0008Ll-Q7@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-12 04:11:39 -0500 (Tue, 12 Dec 2006)
New Revision: 1769

Modified:
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/SessionState.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Channel.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java
   branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   branches/Branch_Client_Failover_Experiment/tests/build.xml
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Final commit on this branch



Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -49,6 +49,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
+import org.jboss.jms.tx.AckInfo;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -328,8 +329,23 @@
          failedSessionDelegate.copyState(newSessionDelegate);
          
          log.info("copied state");
+         
+         //Now we remove any unacked np messages - this is because we don't want to ack them
+         //since the server won't know about them and will barf
+         Iterator iter = failedSessionState.getToAck().iterator();
+         
+         while (iter.hasNext())
+         {
+            AckInfo info = (AckInfo)iter.next();
+            
+            if (!info.getMessage().getMessage().isReliable())
+            {
+               iter.remove();
+            }            
+         }
+         
+         //TODO remove any unacked from the resource manager
 
-
          if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
 
          //TODO Clebert please add comment as to why this clone is necessary
@@ -359,8 +375,32 @@
                 handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
             }
          }
+         
+         /* Now we must sent the list of unacked AckInfos to the server - so the consumers
+          * delivery lists can be repopulated
+          */
+         List ackInfos = null;
+         
+         if (!failedSessionState.isTransacted())
+         {
+            //Get the ack infos from the list in the session state
+            ackInfos = failedSessionState.getToAck();
+         }
+         else
+         {
+            //Transacted session - we need to get the acks
+            //TODO
+         }
+         
+         //TODO for a transacted session the ackinfos will be in the resource manager!!
+         
+         if (!ackInfos.isEmpty())
+         {
+            newSessionDelegate.sendUnackedAckInfos(ackInfos);
+         }
+                  
       }
-      
+            
       //We must not start the connection until the end
       if (failedState.isStarted())
       {
@@ -369,6 +409,8 @@
       
       log.info("Failover done");
    }
+   
+   
 
    private void handleFailoverOnConsumer(ClientConnectionDelegate connectionDelegate,
                                          ConnectionState failedConnectionState,
@@ -387,11 +429,11 @@
 
       ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)failedSessionDelegate.
          failOverConsumer((JBossDestination)failedConsumerState.getDestination(),
-                                failedConsumerState.getSelector(),
-                                failedConsumerState.isNoLocal(),
-                                failedConsumerState.getSubscriptionName(),
-                                failedConsumerState.isConnectionConsumer(),
-                                failedConsumerDelegate.getChannelId());
+                           failedConsumerState.getSelector(),
+                           failedConsumerState.isNoLocal(),
+                           failedConsumerState.getSubscriptionName(),
+                           failedConsumerState.isConnectionConsumer(),
+                           failedConsumerDelegate.getChannelId());
 
       if (trace) { log.trace("handleFailoverOnConsumer: alternate consumer created"); }
 
@@ -418,6 +460,9 @@
 
       MessageCallbackHandler handler = cm.unregisterHandler(oldServerID, oldConsumerID);
       handler.setConsumerId(failedConsumerState.getConsumerID());
+      
+      //Clear the buffer of the handler
+      handler.clearBuffer();
 
       cm.registerHandler(failedConnectionState.getServerID(),
                          failedConsumerState.getConsumerID(),
@@ -426,8 +471,8 @@
       failedSessionState.addCallbackHandler(handler);
       
       log.info("failed over consumer");
-
    }
+   
 
    private void handleFailoverOnProducer(ProducerState failedProducerState,
                                          ClientSessionDelegate failedSessionDelegate)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -441,6 +441,15 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
    
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+   
 
    // Public --------------------------------------------------------
 
@@ -457,6 +466,7 @@
       return ((ConnectionState)state.getParent()).getRemotingConnection().getInvokingClient();
    }
 
+
    // Package Private -----------------------------------------------
 
    // Private -------------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -514,6 +514,11 @@
       }
    }
    
+   public void clearBuffer()
+   {
+      buffer.clear();
+   }
+   
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -48,7 +48,6 @@
  */
 public class SessionState extends HierarchicalStateSupport
 {
-
    protected static Logger log = Logger.getLogger(SessionState.class);
 
    private int acknowledgeMode;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -31,9 +31,9 @@
 import org.jboss.jms.selector.Selector;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Filter;
 import org.jboss.messaging.core.Routable;
-import org.jboss.messaging.core.local.PagingFilteredQueue;
 
 /**
  * Concrete implementation of BrowserEndpoint.
@@ -66,7 +66,7 @@
    // Constructors --------------------------------------------------
 
    protected ServerBrowserEndpoint(ServerSessionEndpoint session, int id,
-                                   PagingFilteredQueue destination, String messageSelector)
+                                   Channel destination, String messageSelector)
       throws JMSException
    {     
       this.session = session;

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -42,6 +42,7 @@
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.MessageReference;
@@ -49,7 +50,6 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.Routable;
 import org.jboss.messaging.core.SimpleDelivery;
-import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.Transaction;
@@ -87,7 +87,7 @@
 
    private int id;
 
-   private PagingFilteredQueue messageQueue;
+   private Channel messageQueue;
    
    private String queueName;
 
@@ -131,7 +131,7 @@
    
    // Constructors --------------------------------------------------
 
-   protected ServerConsumerEndpoint(int id, PagingFilteredQueue messageQueue, String queueName,
+   protected ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
                                     ServerSessionEndpoint sessionEndpoint,
                                     String selector, boolean noLocal, JBossDestination dest,
                                     int prefetchSize, Queue dlq)
@@ -633,7 +633,24 @@
       }
       
    }
-   
+
+   protected void createDeliveries(List messageIds) throws Throwable
+   {
+      List dels = messageQueue.createDeliveries(messageIds);
+            
+      synchronized (lock)
+      {      
+         Iterator iter = dels.iterator();
+         
+         while (iter.hasNext())
+         {
+            Delivery del = (Delivery)iter.next();
+            
+            deliveries.put(new Long(del.getReference().getMessageID()), del);
+         }
+      }
+   }
+
    protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
    {
       Delivery del = (Delivery)deliveries.remove(messageID);
@@ -653,7 +670,7 @@
          throw new IllegalStateException("Cannot find delivery to cancel:" + id);
       }
    }
-               
+           
    protected void start()
    {             
       synchronized (lock)

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -27,6 +27,7 @@
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
+import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
@@ -186,11 +187,11 @@
          int prefetchSize = connectionEndpoint.getPrefetchSize();
          
          ServerConsumerEndpoint ep =
-            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+
+            new ServerConsumerEndpoint(consumerID, binding.getQueue(),
                                        binding.getQueue().getName(), this, selectorString, noLocal,
                                        jmsDestination, prefetchSize, dlq);
 
-         
          JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
          
          ClientConsumerDelegate stub =
@@ -755,6 +756,56 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " cancelDeliveries");
       }
    }
+   
+   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   {
+      try
+      {
+         //Sort into different list for each consumer
+         Map ackMap = new HashMap();
+                  
+         for (int i = ackInfos.size() - 1; i >= 0; i--)
+         {
+            AckInfo ack = (AckInfo)ackInfos.get(i);
+            
+            ServerConsumerEndpoint consumer =
+               this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
+   
+            if (consumer == null)
+            {
+               throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
+            }
+            
+            LinkedList acks = (LinkedList)ackMap.get(consumer);
+            
+            if (acks == null)
+            {
+               acks = new LinkedList();
+               
+               ackMap.put(consumer, acks);
+            }
+            
+            acks.addFirst(new Long(ack.getMessageID()));
+         }  
+         
+         Iterator iter = ackMap.entrySet().iterator();
+         
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+            
+            ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)entry.getKey();
+            
+            List acks = (List)entry.getValue();
+            
+            consumer.createDeliveries(acks);
+         }
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " sendUnackedAckInfos");
+      }
+   }
 
    public void addTemporaryDestination(JBossDestination dest) throws JMSException
    {

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -120,5 +120,14 @@
     * @param ackInfos
     */
    void cancelDeliveries(List ackInfos) throws JMSException;
+   
+   
+   /**
+    * Send a list of unacked ackInfos to the server so the delivery lists can be repopulated
+    * used at failover
+    * @param ackInfos
+    * @throws JMSException
+    */
+   void sendUnackedAckInfos(List ackInfos) throws JMSException;
 }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -147,6 +147,11 @@
    {
       endpoint.cancelDeliveries(ackInfos);
    }
+   
+   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   {
+      endpoint.sendUnackedAckInfos(ackInfos);
+   }
 
 
    // AdvisedSupport overrides --------------------------------------
@@ -161,6 +166,7 @@
       return "SessionAdvised->" + endpoint;
    }
 
+
    // Public --------------------------------------------------------
 
    // Protected -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -37,8 +37,8 @@
 
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.client.remoting.HandleMessageResponse;
-import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
@@ -95,6 +95,7 @@
    protected static final byte MORE = 5;
    protected static final byte SEND_TRANSACTION = 6;
    protected static final byte GET_ID_BLOCK = 7;
+   protected static final byte UNACKED_ACKINFOS = 8;
  
 
    // The response codes - start from 100
@@ -312,6 +313,28 @@
    
                   if (trace) { log.trace("wrote cancelDeliveries()"); }
                }
+               else if ("sendUnackedAckInfos".equals(methodName) && mi.getArguments() != null)
+               {
+                  dos.writeByte(UNACKED_ACKINFOS);
+   
+                  writeHeader(mi, dos);
+   
+                  List ids = (List)mi.getArguments()[0];
+   
+                  dos.writeInt(ids.size());
+   
+                  Iterator iter = ids.iterator();
+   
+                  while (iter.hasNext())
+                  {
+                     AckInfo ack = (AckInfo)iter.next();
+                     ack.write(dos);
+                  }
+   
+                  dos.flush();
+   
+                  if (trace) { log.trace("wrote sendUnackedAckInfos()"); }
+               }
                else
                {
                   dos.write(SERIALIZED);
@@ -700,6 +723,35 @@
    
                return request;
             }
+            case UNACKED_ACKINFOS:
+            {
+               MethodInvocation mi = readHeader(dis);
+   
+               int size = dis.readInt();
+   
+               List acks = new ArrayList(size);
+   
+               for (int i = 0; i < size; i++)
+               {
+                  AckInfo ack = new AckInfo();
+                  
+                  ack.read(dis);
+                  
+                  acks.add(ack);
+               }
+   
+               Object[] args = new Object[] {acks};
+   
+               mi.setArguments(args);
+   
+               InvocationRequest request =
+                  new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
+                                        new MessagingMarshallable(version, mi), null, null, null);
+   
+               if (trace) { log.trace("read unackedAckInfos()"); }
+   
+               return request;
+            }
             case ID_BLOCK_RESPONSE:
             {
                IdBlock block = new IdBlock();

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -86,7 +86,7 @@
    /** Used to change ack's id during failover */
    public void setConsumerID(int consumerID)
    {
-       this.consumerID=consumerID;
+       this.consumerID = consumerID;
    }
    
    public MessageProxy getMessage()

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Channel.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Channel.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/Channel.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -145,6 +145,8 @@
    void deactivate();
    
    boolean isActive();
+   
+   List createDeliveries(List messageIds);
 
 }
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -491,6 +491,58 @@
          }
       }
    }
+   
+   public List createDeliveries(List messageIds)
+   {
+      //debug
+      Iterator iter = messageIds.iterator();
+      
+      log.info("***** createdeliveries");
+      while (iter.hasNext())
+      {
+         Long l = (Long)iter.next();
+         
+         log.info("Creating delivery for " + l);
+      }
+      log.info("**** end dump");
+      
+      iter = messageIds.iterator();
+      
+      List dels = new ArrayList();
+      
+      synchronized (refLock)
+      {
+         ListIterator liter = messageRefs.iterator();
+                           
+         while (iter.hasNext())
+         {
+            Long id = (Long)iter.next();
+            
+            if (!liter.hasNext())
+            {
+               throw new IllegalStateException("Cannot find ref in queue! (Might be paged!)");
+            }
+            
+            MessageReference ref = (MessageReference)liter.next();
+            
+            if (ref.getMessageID() == id.longValue())
+            {
+               liter.remove();
+               
+               Delivery del = new SimpleDelivery(this, ref);
+               
+               dels.add(del);
+                              
+               this.deliveries.add(del);
+               
+            }
+         }                  
+      }
+      
+      //TODO we need to look in paging state too - currently not supported
+      
+      return dels;
+   }
 
    // Public --------------------------------------------------------
 

Modified: branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -272,4 +272,9 @@
    {
       return "RemoteQueueStub(node=" + this.nodeId + " name=" + this.name + " channelId=" + this.id + ")";
    }
+
+   public List createDeliveries(List messageIds)
+   {
+      throw new UnsupportedOperationException();
+   }
 }

Modified: branches/Branch_Client_Failover_Experiment/tests/build.xml
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/tests/build.xml	2006-12-12 09:11:39 UTC (rev 1769)
@@ -745,7 +745,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -216,6 +216,11 @@
       throw new UnsupportedOperationException();
    }
 
+   public List createDeliveries(List messageIds)
+   {
+      throw new UnsupportedOperationException();
+   }
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -369,6 +369,12 @@
          // TODO Auto-generated method stub
          return false;
       }
+
+      public List createDeliveries(List messageIds)
+      {
+         // TODO Auto-generated method stub
+         return null;
+      }
       
    }
 

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -24,6 +24,7 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.Filter;
@@ -608,6 +609,12 @@
          // TODO Auto-generated method stub
          return false;
       }
+
+      public List createDeliveries(List messageIds)
+      {
+         // TODO Auto-generated method stub
+         return null;
+      }
       
    }
    

Modified: branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 08:12:41 UTC (rev 1768)
+++ branches/Branch_Client_Failover_Experiment/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 09:11:39 UTC (rev 1769)
@@ -26,6 +26,7 @@
 import java.util.Set;
 
 import javax.jms.Connection;
+import javax.jms.Message;
 import javax.jms.MessageConsumer;
 import javax.jms.MessageProducer;
 import javax.jms.Session;
@@ -69,355 +70,661 @@
    }
    
    // Public --------------------------------------------------------
+//   
+//   /*
+//    * Test that connections created using a clustered connection factory are created round robin on
+//    * different servers
+//    */
+//   public void testRoundRobinConnectionCreation() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//      
+//      log.info ("number of delegates = " + delegate.getDelegates().length);
+//      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
+//      
+//      assertEquals(3, delegate.getDelegates().length);
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//      
+//      assertEquals(0, cf1.getServerId());
+//      
+//      assertEquals(1, cf2.getServerId());
+//      
+//      assertEquals(2, cf3.getServerId());
+//      
+//      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+//      
+//      Connection conn1 = null;
+//      
+//      Connection conn2 = null;
+//      
+//      Connection conn3 = null;
+//      
+//      Connection conn4 = null;
+//      
+//      Connection conn5 = null;
+//      
+//      try
+//      {         
+//         conn1 = factory.createConnection();
+//         
+//         conn2 = factory.createConnection();
+//         
+//         conn3 = factory.createConnection();
+//         
+//         conn4 = factory.createConnection();
+//         
+//         conn5 = factory.createConnection();
+//         
+//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+//         
+//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+//         
+//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+//         
+//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+//         
+//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+//         
+//         int serverID1 = state1.getServerID();
+//         
+//         int serverID2 = state2.getServerID();
+//         
+//         int serverID3 = state3.getServerID();
+//         
+//         int serverID4 = state4.getServerID();
+//         
+//         int serverID5 = state5.getServerID();
+//         
+//         log.info("server id 1: " + serverID1);
+//         
+//         log.info("server id 2: " + serverID2);
+//         
+//         log.info("server id 3: " + serverID3);
+//         
+//         log.info("server id 4: " + serverID4);
+//         
+//         log.info("server id 5: " + serverID5);
+//         
+//         assertEquals(0, serverID1);
+//         
+//         assertEquals(1, serverID2);
+//         
+//         assertEquals(2, serverID3);
+//         
+//         assertEquals(0, serverID4);
+//         
+//         assertEquals(1, serverID5);
+//      }
+//      finally
+//      {
+//         if (conn1 != null)
+//         {
+//            conn1.close();
+//         }
+//         
+//         if (conn2 != null)
+//         {
+//            conn2.close();
+//         }
+//         
+//         if (conn3 != null)
+//         {
+//            conn3.close();
+//         }
+//         
+//         if (conn4 != null)
+//         {
+//            conn4.close();
+//         }
+//         
+//         if (conn5 != null)
+//         {
+//            conn5.close();
+//         }
+//      }
+//      
+//   }
+// 
+//   /*
+//    * Test that the failover mapping is created correctly and updated properly when nodes leave
+//    * or join
+//    */
+//   public void testDefaultFailoverMap() throws Exception
+//   {     
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         //The order here depends on the order the servers were started in
+//         
+//         //If any servers get stopped and then started then the order will change
+//    
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         
+//         assertEquals(0, cf1.getServerId());
+//         
+//         assertEquals(1, cf2.getServerId());
+//         
+//         assertEquals(2, cf3.getServerId());
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         // Default failover policy just chooses the node to the right
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }
+//      
+//      //Now cleanly stop one of the servers
+//            
+//      log.info("************** STOPPING SERVER 0");
+//      ServerManagement.stop(0);
+//      
+//      log.info("server stopped");
+//      
+//      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         //Order here depends on order servers were started in
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(1, cf1.getServerId());
+//         
+//         assertEquals(2, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      //Cleanly stop another server
+//      
+//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+//      
+//      ServerManagement.stop(1);
+//      
+//      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(1, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         
+//         assertEquals(1, failoverMap.size());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//      }
+//            
+//      //Restart server 0
+//      
+//      ServerManagement.start("all", 0);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      
+//      //Restart server 1
+//      
+//      ServerManagement.start("all", 1);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         assertEquals(1, cf3.getServerId());
+//         
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }            
+//   }
+//   
+//   public void testSimpleFailover() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerId();
+//      
+//      int server1Id = cf2.getServerId();
+//      
+//      int server2Id = cf3.getServerId();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      try
+//      {
+//      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         MessageProducer prod = sess.createProducer(queue1);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue1);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         //So now, messages should be in queue1 on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.getServer(1).destroy();
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(1000);
+//            
+//            log.info("message is " + tm);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         log.info("done");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
    
-   /*
-    * Test that connections created using a clustered connection factory are created round robin on
-    * different servers
-    */
-   public void testRoundRobinConnectionCreation() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      log.info ("number of delegates = " + delegate.getDelegates().length);
-      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
-      
-      assertEquals(3, delegate.getDelegates().length);
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-      
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-      
-      Connection conn4 = null;
-      
-      Connection conn5 = null;
-      
-      try
-      {         
-         conn1 = factory.createConnection();
-         
-         conn2 = factory.createConnection();
-         
-         conn3 = factory.createConnection();
-         
-         conn4 = factory.createConnection();
-         
-         conn5 = factory.createConnection();
-         
-         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
-         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
-         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
-         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
-         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
-         int serverID1 = state1.getServerID();
-         
-         int serverID2 = state2.getServerID();
-         
-         int serverID3 = state3.getServerID();
-         
-         int serverID4 = state4.getServerID();
-         
-         int serverID5 = state5.getServerID();
-         
-         log.info("server id 1: " + serverID1);
-         
-         log.info("server id 2: " + serverID2);
-         
-         log.info("server id 3: " + serverID3);
-         
-         log.info("server id 4: " + serverID4);
-         
-         log.info("server id 5: " + serverID5);
-         
-         assertEquals(0, serverID1);
-         
-         assertEquals(1, serverID2);
-         
-         assertEquals(2, serverID3);
-         
-         assertEquals(0, serverID4);
-         
-         assertEquals(1, serverID5);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-         
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-         
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-         
-         if (conn4 != null)
-         {
-            conn4.close();
-         }
-         
-         if (conn5 != null)
-         {
-            conn5.close();
-         }
-      }
-      
-   }
- 
-   /*
-    * Test that the failover mapping is created correctly and updated properly when nodes leave
-    * or join
-    */
-   public void testDefaultFailoverMap() throws Exception
-   {     
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         //The order here depends on the order the servers were started in
-         
-         //If any servers get stopped and then started then the order will change
-    
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         
-         assertEquals(0, cf1.getServerId());
-         
-         assertEquals(1, cf2.getServerId());
-         
-         assertEquals(2, cf3.getServerId());
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(3, delegates.length);
-         
-         assertEquals(3, failoverMap.size());
-         
-         // Default failover policy just chooses the node to the right
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }
-      
-      //Now cleanly stop one of the servers
-            
-      log.info("************** STOPPING SERVER 0");
-      ServerManagement.stop(0);
-      
-      log.info("server stopped");
-      
-      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         //Order here depends on order servers were started in
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(1, cf1.getServerId());
-         
-         assertEquals(2, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      //Cleanly stop another server
-      
-      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
-      ServerManagement.stop(1);
-      
-      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(1, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         assertEquals(2, cf1.getServerId());
-         
-         
-         assertEquals(1, failoverMap.size());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      }
-            
-      //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      
-      //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(3, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         assertEquals(1, cf3.getServerId());
-         
-         
-         assertEquals(3, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }            
-   }
    
-   public void testSimpleFailover() throws Exception
+//   public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerId();
+//      
+//      int server1Id = cf2.getServerId();
+//      
+//      int server2Id = cf3.getServerId();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      try
+//      {      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+//         
+//         MessageProducer prod = sess.createProducer(queue1);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue1);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         conn.start();
+//         
+//         //Now consume half of the messages but don't ack them these will end up in 
+//         //client side toAck list
+//         
+//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(500);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         //So now, messages should be in queue1 on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.getServer(1).destroy();
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         //Now should be able to consume the rest of the messages
+//         
+//         log.info("here1");
+//         
+//         TextMessage tm = null;
+//         
+//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+//         {
+//            tm = (TextMessage)cons.receive(500);
+//                                    
+//            log.info("message is " + tm.getText());
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         log.info("here2");
+//         
+//         //Now should be able to acknowledge them
+//         
+//         tm.acknowledge();
+//         
+//         //Now check there are no more messages there
+//         sess.close();
+//         
+//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         cons = sess.createConsumer(queue1);
+//         
+//         Message m = cons.receive(500);
+//         
+//         assertNull(m);
+//         
+//         log.info("got to end of test");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
+   
+   public void testFailoverWithUnackedMessagesTransactional() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
       
@@ -462,8 +769,7 @@
       Connection conn = null;
       
       try
-      {
-      
+      {      
          //Get a connection on server 1
          conn = factory.createConnection(); //connection on server 0
          
@@ -481,7 +787,7 @@
          
          assertEquals(1, initialServerID);
                            
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
          
          MessageProducer prod = sess.createProducer(queue1);
          
@@ -496,6 +802,22 @@
             prod.send(tm);
          }
          
+         sess.commit();
+         
+         conn.start();
+         
+         //Now consume half of the messages but don't commit them these will end up in 
+         //client side resource manager
+         
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
          //So now, messages should be in queue1 on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
@@ -522,17 +844,41 @@
          
          conn.start();
          
-         for (int i = 0; i < NUM_MESSAGES; i++)
+         //Now should be able to consume the rest of the messages
+         
+         log.info("here1");
+         
+         TextMessage tm = null;
+         
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            tm = (TextMessage)cons.receive(500);
+                                    
+            log.info("message is " + tm.getText());
             
-            log.info("message is " + tm);
-            
             assertNotNull(tm);
             
             assertEquals("message:" + i, tm.getText());
          }
-         log.info("done");
+         
+         log.info("here2");
+         
+         //Now should be able to commit them
+         
+         sess.commit();
+         
+         //Now check there are no more messages there
+         sess.close();
+         
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons = sess.createConsumer(queue1);
+         
+         Message m = cons.receive(500);
+         
+         assertNull(m);
+         
+         log.info("got to end of test");
       }
       finally
       {         
@@ -551,6 +897,9 @@
       
    }
    
+   
+   
+   
 //   public void testEvenSimplerFailover() throws Exception
 //   {
 //      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");



From t2-okada at nri.co.jp  Tue Dec 12 04:17:36 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:17:36 -0500
Subject: [jboss-cvs] jboss-profiler/exsamples/jboss-profiler.aop/META-INF ...
Message-ID: <E1Gu3lY-0008S8-36@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:17:36

  Modified:    exsamples/jboss-profiler.aop/META-INF  Tag:
                        JBossProfiler_Expansion jboss-aop.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +16 -22    jboss-profiler/exsamples/jboss-profiler.aop/META-INF/Attic/jboss-aop.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-aop.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/exsamples/jboss-profiler.aop/META-INF/Attic/jboss-aop.xml,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- jboss-aop.xml	28 Nov 2006 05:41:14 -0000	1.1.2.3
  +++ jboss-aop.xml	12 Dec 2006 09:17:36 -0000	1.1.2.4
  @@ -17,6 +17,10 @@
           org.jboss.profiler.exp.agent.collector.ExecutionMetricCollectorFactory
         </attribute>
         <attribute name="Category">Beans</attribute>
  +      <!--
  +      <attribute name="CollectorPoolSize">100000</attribute>
  +      <attribute name="CollectorQueueSize">100000</attribute>
  +      -->
       </interceptor>
       <interceptor name="ConcurrentAopInterceptor"
                    class="org.jboss.profiler.exp.agent.interceptor.AopInterceptor"
  @@ -27,6 +31,10 @@
           org.jboss.profiler.exp.agent.collector.ConcurrentMetricCollectorFactory
         </attribute>
         <attribute name="Category">Beans</attribute>
  +      <!--
  +      <attribute name="CollectorPoolSize">100000</attribute>
  +      <attribute name="CollectorQueueSize">100000</attribute>
  +      -->
       </interceptor>
       <interceptor name="MemoryAopInterceptor"
                    class="org.jboss.profiler.exp.agent.interceptor.AopInterceptor"
  @@ -37,6 +45,10 @@
           org.jboss.profiler.exp.agent.collector.MemoryMetricCollectorFactory
         </attribute>
         <attribute name="Category">Beans</attribute>
  +      <!--
  +      <attribute name="CollectorPoolSize">100000</attribute>
  +      <attribute name="CollectorQueueSize">100000</attribute>
  +      -->
       </interceptor>
     </stack>
     
  @@ -49,29 +61,11 @@
         org.jboss.profiler.exp.agent.collector.ThreadMetricCollectorFactory
       </attribute>
       <attribute name="Category">Beans</attribute>
  -  </interceptor>
  -  
     <!--
  -  <interceptor name="StackTraceAopInterceptor"
  -               class="org.jboss.profiler.exp.agent.interceptor.AopInterceptor"
  -               scope="PER_VM">
  -    <attribute name="ProfilerServiceName">jboss.profiler:service=ProfilerService</attribute>
  -    <attribute name="CollectorFactoryName">
  -      org.jboss.profiler.exp.agent.collector.StackTraceMetricCollectorFactory
  -    </attribute>
  -    <attribute name="Category">Beans</attribute>
  -  </interceptor>
  -  
  -  <interceptor name="PassageAopInterceptor"
  -               class="org.jboss.profiler.exp.agent.interceptor.AopInterceptor"
  -               scope="PER_VM">
  -    <attribute name="ProfilerServiceName">jboss.profiler:service=ProfilerService</attribute>
  -    <attribute name="CollectorFactoryName">
  -      org.jboss.profiler.exp.agent.collector.TimeScaleMetricCollectorFactory
  -    </attribute>
  -    <attribute name="Category">Beans</attribute>
  -  </interceptor>
  +    <attribute name="CollectorPoolSize">100000</attribute>
  +    <attribute name="CollectorQueueSize">100000</attribute>
     -->
  +  </interceptor>
     
     
     <!-- ##### JBoss Profiler : Pointcuts ##### -->
  
  
  


From t2-okada at nri.co.jp  Tue Dec 12 04:17:36 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:17:36 -0500
Subject: [jboss-cvs] jboss-profiler/exsamples/jboss-aop-jdk5.deployer/META-INF
	...
Message-ID: <E1Gu3lY-0008SJ-6j@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:17:36

  Modified:    exsamples/jboss-aop-jdk5.deployer/META-INF  Tag:
                        JBossProfiler_Expansion jboss-service.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +1 -1      jboss-profiler/exsamples/jboss-aop-jdk5.deployer/META-INF/Attic/jboss-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/exsamples/jboss-aop-jdk5.deployer/META-INF/Attic/jboss-service.xml,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- jboss-service.xml	26 Oct 2006 09:06:31 -0000	1.1.2.1
  +++ jboss-service.xml	12 Dec 2006 09:17:36 -0000	1.1.2.2
  @@ -21,7 +21,7 @@
         <attribute name="Prune">true</attribute>
         <attribute name="Optimized">true</attribute>
         <attribute name="Verbose">false</attribute>
  -      <attribute name="Exclude">java,javax,org.jboss,org.apache</attribute>
  +      <attribute name="Exclude">java,org,net,com,gnu,EDU,antlr,bsh,javassist,javolution</attribute>
         <!-- Change this attribute for the profiling target. -->
         <attribute name="Include">org.jboss.profiler.exp.test.target</attribute>
      </mbean>
  
  
  


From t2-okada at nri.co.jp  Tue Dec 12 04:17:36 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:17:36 -0500
Subject: [jboss-cvs] jboss-profiler/exsamples/jboss-profiler-test.war/WEB-INF
	...
Message-ID: <E1Gu3lY-0008SW-CC@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:17:36

  Modified:    exsamples/jboss-profiler-test.war/WEB-INF  Tag:
                        JBossProfiler_Expansion web.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +10 -0     jboss-profiler/exsamples/jboss-profiler-test.war/WEB-INF/Attic/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/exsamples/jboss-profiler-test.war/WEB-INF/Attic/web.xml,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- web.xml	28 Nov 2006 05:41:14 -0000	1.1.2.3
  +++ web.xml	12 Dec 2006 09:17:36 -0000	1.1.2.4
  @@ -30,6 +30,16 @@
         <param-name>Category</param-name>
         <param-value>Http Requests</param-value>
       </init-param>
  +    <!--
  +    <init-param>
  +      <param-name>CollectorPoolSize</param-name>
  +      <param-value>100000</param-value>
  +    </init-param>
  +    <init-param>
  +      <param-name>CollectorQueueSize</param-name>
  +      <param-value>100000</param-value>
  +    </init-param>
  +    -->
     </filter>
     
     <!-- ##### Test Application : Servlets ##### -->
  
  
  


From t2-okada at nri.co.jp  Tue Dec 12 04:17:36 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:17:36 -0500
Subject: [jboss-cvs] jboss-profiler/exsamples  ...
Message-ID: <E1Gu3lY-0008Sh-Gi@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:17:36

  Modified:    exsamples  Tag: JBossProfiler_Expansion mysql-ds.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +4 -0      jboss-profiler/exsamples/Attic/mysql-ds.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: mysql-ds.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/exsamples/Attic/mysql-ds.xml,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- mysql-ds.xml	28 Nov 2006 05:41:14 -0000	1.1.2.3
  +++ mysql-ds.xml	12 Dec 2006 09:17:36 -0000	1.1.2.4
  @@ -38,5 +38,9 @@
         java.sql.CallableStatement.set,
         java.sql.CallableStatement.registerOutParameter
       </connection-property>
  +    <!--
  +    <connection-property name="jboss.profiler.CollectorPoolSize">100000</connection-property>
  +    <connection-property name="jboss.profiler.CollectorQueueSize">100000</connection-property>
  +    -->
     </local-tx-datasource>
   </datasources>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:20:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:20:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r58983 -
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1Gu3oN-0008Vu-Hx@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 04:20:29 -0500 (Tue, 12 Dec 2006)
New Revision: 58983

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
JBMICROCONT-26; initial code commit, minor fixes

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 08:55:27 UTC (rev 58982)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 09:20:29 UTC (rev 58983)
@@ -80,7 +80,7 @@
 
    public static void initCollectionHandler(TypeBinding typeBinding)
    {
-      typeBinding.setHandler(CollectionHandler.HANDLER);
+      typeBinding.setHandler(SpringCollectionHandler.HANDLER);
       // configure
       configureValueBindings(typeBinding);
    }



From t2-okada at nri.co.jp  Tue Dec 12 04:23:33 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:23:33 -0500
Subject: [jboss-cvs] jboss-profiler/java/mbean  ...
Message-ID: <E1Gu3rJ-00008k-8H@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:23:33

  Modified:    java/mbean  Tag: JBossProfiler_Expansion jboss-service.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.2.4   +1 -0      jboss-profiler/java/mbean/jboss-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/mbean/jboss-service.xml,v
  retrieving revision 1.3.2.3
  retrieving revision 1.3.2.4
  diff -u -b -r1.3.2.3 -r1.3.2.4
  --- jboss-service.xml	31 Oct 2006 11:34:54 -0000	1.3.2.3
  +++ jboss-service.xml	12 Dec 2006 09:23:33 -0000	1.3.2.4
  @@ -1,6 +1,7 @@
   <?xml version="1.0" encoding="UTF-8"?>
   <server>
     
  +  <!-- ##### JBoss Profiler : Agent ##### -->
     <mbean code="org.jboss.profiler.exp.agent.DefaultProfilerService"
            name="jboss.profiler:service=ProfilerService">
       <!-- Writes log file to /log directory of the JBoss AS. -->
  
  
  


From t2-okada at nri.co.jp  Tue Dec 12 04:28:06 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Tue, 12 Dec 2006 04:28:06 -0500
Subject: [jboss-cvs] jboss-profiler  ...
Message-ID: <E1Gu3vi-0000EU-7F@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/12 04:28:06

  Modified:    jboss-profiler  Tag: JBossProfiler_Expansion build.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.37.2.4  +1 -1      jboss-profiler/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/build.xml,v
  retrieving revision 1.37.2.3
  retrieving revision 1.37.2.4
  diff -u -b -r1.37.2.3 -r1.37.2.4
  --- build.xml	10 Nov 2006 09:17:44 -0000	1.37.2.3
  +++ build.xml	12 Dec 2006 09:28:06 -0000	1.37.2.4
  @@ -66,7 +66,7 @@
     <target name="deploy" depends="jar,war">
       <delete dir="${deploy.dir}/${service.name}.sar"/>
       <mkdir dir="${deploy.dir}/${service.name}.sar"/>
  -    <copy todir="${deploy.dir}/${service.name}.sar">
  +    <copy todir="${jboss.server.lib.dir}">
         <fileset dir="${lib.dir}" includes="*.jar"/>
         <fileset file="${build.dir}/${service.name}.jar"/>
       </copy>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:36:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:36:07 -0500
Subject: [jboss-cvs] JBossAS SVN: r58984 -
	branches/Branch_4_2/transaction/src/main/org/jboss/tm
Message-ID: <E1Gu43T-0000NK-9r@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 04:36:04 -0500 (Tue, 12 Dec 2006)
New Revision: 58984

Modified:
   branches/Branch_4_2/transaction/src/main/org/jboss/tm/TxUtils.java
Log:
JBAS-3847, add simple utility methods to check for rollback status

Modified: branches/Branch_4_2/transaction/src/main/org/jboss/tm/TxUtils.java
===================================================================
--- branches/Branch_4_2/transaction/src/main/org/jboss/tm/TxUtils.java	2006-12-12 09:20:29 UTC (rev 58983)
+++ branches/Branch_4_2/transaction/src/main/org/jboss/tm/TxUtils.java	2006-12-12 09:36:04 UTC (rev 58984)
@@ -37,7 +37,7 @@
  * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $1.0$
+ * @version $Revision:$
  */
 public class TxUtils
 {
@@ -184,6 +184,51 @@
       }
    }
    
+   public static boolean isRollback(Transaction tx)
+   {
+      try
+      {
+         if (tx == null)
+            return false;
+         
+         int status = tx.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+             || status == Status.STATUS_ROLLING_BACK
+             || status == Status.STATUS_ROLLEDBACK;
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+
+   public static boolean isRollback(TransactionManager tm)
+   {
+      try
+      {
+         return isRollback(tm.getTransaction());
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+
+   public static boolean isRollback(UserTransaction ut)
+   {
+      try
+      {
+         int status = ut.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+         	|| status == Status.STATUS_ROLLING_BACK
+         	|| status == Status.STATUS_ROLLEDBACK;
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+   
    /**
     * Converts a tx Status index to a String
     * 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:37:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:37:07 -0500
Subject: [jboss-cvs] JBossAS SVN: r58985 -
	branches/Branch_4_0/transaction/src/main/org/jboss/tm
Message-ID: <E1Gu44R-0000P1-V8@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 04:37:06 -0500 (Tue, 12 Dec 2006)
New Revision: 58985

Modified:
   branches/Branch_4_0/transaction/src/main/org/jboss/tm/TxUtils.java
Log:
JBAS-3847, add simple utility methods to check for rollback status

Modified: branches/Branch_4_0/transaction/src/main/org/jboss/tm/TxUtils.java
===================================================================
--- branches/Branch_4_0/transaction/src/main/org/jboss/tm/TxUtils.java	2006-12-12 09:36:04 UTC (rev 58984)
+++ branches/Branch_4_0/transaction/src/main/org/jboss/tm/TxUtils.java	2006-12-12 09:37:06 UTC (rev 58985)
@@ -37,7 +37,7 @@
  * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $1.0$
+ * @version $Revision$
  */
 public class TxUtils
 {
@@ -184,6 +184,51 @@
       }
    }
    
+   public static boolean isRollback(Transaction tx)
+   {
+      try
+      {
+         if (tx == null)
+            return false;
+         
+         int status = tx.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+             || status == Status.STATUS_ROLLING_BACK
+             || status == Status.STATUS_ROLLEDBACK;
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+
+   public static boolean isRollback(TransactionManager tm)
+   {
+      try
+      {
+         return isRollback(tm.getTransaction());
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+
+   public static boolean isRollback(UserTransaction ut)
+   {
+      try
+      {
+         int status = ut.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+         	|| status == Status.STATUS_ROLLING_BACK
+         	|| status == Status.STATUS_ROLLEDBACK;
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+   
    /**
     * Converts a tx Status index to a String
     * 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:41:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:41:33 -0500
Subject: [jboss-cvs] JBossAS SVN: r58986 -
	trunk/transaction/src/main/org/jboss/tm
Message-ID: <E1Gu48j-0000Ty-2E@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 04:41:30 -0500 (Tue, 12 Dec 2006)
New Revision: 58986

Modified:
   trunk/transaction/src/main/org/jboss/tm/TxUtils.java
Log:
JBAS-3847, add simple utility methods to check for rollback status

Modified: trunk/transaction/src/main/org/jboss/tm/TxUtils.java
===================================================================
--- trunk/transaction/src/main/org/jboss/tm/TxUtils.java	2006-12-12 09:37:06 UTC (rev 58985)
+++ trunk/transaction/src/main/org/jboss/tm/TxUtils.java	2006-12-12 09:41:30 UTC (rev 58986)
@@ -1,24 +1,24 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.tm;
 
 import javax.transaction.Status;
@@ -38,7 +38,7 @@
  * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
  * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
- * @version $1.0$
+ * @version $Revision$
  */
 public class TxUtils
 {
@@ -172,6 +172,51 @@
       }
    }
    
+   public static boolean isRollback(Transaction tx)
+   {
+      try
+      {
+         if (tx == null)
+            return false;
+         
+         int status = tx.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+             || status == Status.STATUS_ROLLING_BACK
+             || status == Status.STATUS_ROLLEDBACK;
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+
+   public static boolean isRollback(TransactionManager tm)
+   {
+      try
+      {
+         return isRollback(tm.getTransaction());
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+
+   public static boolean isRollback(UserTransaction ut)
+   {
+      try
+      {
+         int status = ut.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+         	|| status == Status.STATUS_ROLLING_BACK
+         	|| status == Status.STATUS_ROLLEDBACK;
+      }
+      catch (SystemException error)
+      {
+         throw new NestedRuntimeException(error);
+      }
+   }
+   
    /**
     * Converts a tx Status index to a String
     * 
@@ -289,7 +334,6 @@
          return "XA_RDONLY";
       case XAException.XA_RETRY:
          return "XA_RETRY";
-
       case XAException.XAER_ASYNC:
          return "XAER_ASYNC";
       case XAException.XAER_DUPID:
@@ -310,5 +354,4 @@
          return "XA_UNKNOWN(" + errorCode + ")";
       }
    }
-
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:53:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:53:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r58987 -
	branches/Branch_4_2/server/src/main/org/jboss/ejb
Message-ID: <E1Gu4K9-0000fp-N6@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 04:53:18 -0500 (Tue, 12 Dec 2006)
New Revision: 58987

Modified:
   branches/Branch_4_2/server/src/main/org/jboss/ejb/EnterpriseContext.java
Log:
JBAS-3847, consider an asynchronous rollback due to timeout

Modified: branches/Branch_4_2/server/src/main/org/jboss/ejb/EnterpriseContext.java
===================================================================
--- branches/Branch_4_2/server/src/main/org/jboss/ejb/EnterpriseContext.java	2006-12-12 09:41:30 UTC (rev 58986)
+++ branches/Branch_4_2/server/src/main/org/jboss/ejb/EnterpriseContext.java	2006-12-12 09:53:18 UTC (rev 58987)
@@ -21,15 +21,17 @@
  */
 package org.jboss.ejb;
 
-import org.jboss.logging.Logger;
-import org.jboss.metadata.ApplicationMetaData;
-import org.jboss.metadata.BeanMetaData;
-import org.jboss.metadata.SecurityRoleRefMetaData;
-import org.jboss.security.RealmMapping;
-import org.jboss.security.RunAsIdentity;
-import org.jboss.security.SimplePrincipal;
-import org.jboss.tm.TransactionTimeoutConfiguration;
-import org.jboss.tm.usertx.client.ServerVMClientUserTransaction;
+import java.rmi.RemoteException;
+import java.security.CodeSource;
+import java.security.Identity;
+import java.security.Policy;
+import java.security.Principal;
+import java.security.ProtectionDomain;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Properties;
+import java.util.Set;
+import java.util.Stack;
 
 import javax.ejb.EJBContext;
 import javax.ejb.EJBException;
@@ -52,17 +54,15 @@
 import javax.transaction.TransactionManager;
 import javax.transaction.UserTransaction;
 
-import java.rmi.RemoteException;
-import java.security.CodeSource;
-import java.security.Identity;
-import java.security.Policy;
-import java.security.Principal;
-import java.security.ProtectionDomain;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Properties;
-import java.util.Set;
-import java.util.Stack;
+import org.jboss.logging.Logger;
+import org.jboss.metadata.ApplicationMetaData;
+import org.jboss.metadata.BeanMetaData;
+import org.jboss.metadata.SecurityRoleRefMetaData;
+import org.jboss.security.RealmMapping;
+import org.jboss.security.RunAsIdentity;
+import org.jboss.security.SimplePrincipal;
+import org.jboss.tm.TransactionTimeoutConfiguration;
+import org.jboss.tm.usertx.client.ServerVMClientUserTransaction;
 
 //$Id$
 
@@ -303,8 +303,7 @@
 
    // Inner classes -------------------------------------------------
 
-   protected class EJBContextImpl
-   implements EJBContext
+   protected class EJBContextImpl implements EJBContext
    {
       private InitialContext ctx;
 
@@ -471,7 +470,11 @@
             if (tm.getTransaction() == null)
                throw new IllegalStateException("getRollbackOnly() not allowed without a transaction.");
 
-            return tm.getStatus() == Status.STATUS_MARKED_ROLLBACK;
+            // JBAS-3847, consider an asynchronous rollback due to timeout
+            int status = tm.getStatus();
+            return status == Status.STATUS_MARKED_ROLLBACK
+                || status == Status.STATUS_ROLLING_BACK
+                || status == Status.STATUS_ROLLEDBACK;
          }
          catch (SystemException e)
          {



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 04:54:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 04:54:36 -0500
Subject: [jboss-cvs] JBossAS SVN: r58988 -
	branches/Branch_4_0/server/src/main/org/jboss/ejb
Message-ID: <E1Gu4LM-0000g8-0Y@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 04:54:33 -0500 (Tue, 12 Dec 2006)
New Revision: 58988

Modified:
   branches/Branch_4_0/server/src/main/org/jboss/ejb/EnterpriseContext.java
Log:
JBAS-3847, consider an asynchronous rollback due to timeout

Modified: branches/Branch_4_0/server/src/main/org/jboss/ejb/EnterpriseContext.java
===================================================================
--- branches/Branch_4_0/server/src/main/org/jboss/ejb/EnterpriseContext.java	2006-12-12 09:53:18 UTC (rev 58987)
+++ branches/Branch_4_0/server/src/main/org/jboss/ejb/EnterpriseContext.java	2006-12-12 09:54:33 UTC (rev 58988)
@@ -21,15 +21,17 @@
  */
 package org.jboss.ejb;
 
-import org.jboss.logging.Logger;
-import org.jboss.metadata.ApplicationMetaData;
-import org.jboss.metadata.BeanMetaData;
-import org.jboss.metadata.SecurityRoleRefMetaData;
-import org.jboss.security.RealmMapping;
-import org.jboss.security.RunAsIdentity;
-import org.jboss.security.SimplePrincipal;
-import org.jboss.tm.TransactionTimeoutConfiguration;
-import org.jboss.tm.usertx.client.ServerVMClientUserTransaction;
+import java.rmi.RemoteException;
+import java.security.CodeSource;
+import java.security.Identity;
+import java.security.Policy;
+import java.security.Principal;
+import java.security.ProtectionDomain;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.Properties;
+import java.util.Set;
+import java.util.Stack;
 
 import javax.ejb.EJBContext;
 import javax.ejb.EJBException;
@@ -52,17 +54,15 @@
 import javax.transaction.TransactionManager;
 import javax.transaction.UserTransaction;
 
-import java.rmi.RemoteException;
-import java.security.CodeSource;
-import java.security.Identity;
-import java.security.Policy;
-import java.security.Principal;
-import java.security.ProtectionDomain;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.Properties;
-import java.util.Set;
-import java.util.Stack;
+import org.jboss.logging.Logger;
+import org.jboss.metadata.ApplicationMetaData;
+import org.jboss.metadata.BeanMetaData;
+import org.jboss.metadata.SecurityRoleRefMetaData;
+import org.jboss.security.RealmMapping;
+import org.jboss.security.RunAsIdentity;
+import org.jboss.security.SimplePrincipal;
+import org.jboss.tm.TransactionTimeoutConfiguration;
+import org.jboss.tm.usertx.client.ServerVMClientUserTransaction;
 
 //$Id$
 
@@ -303,8 +303,7 @@
 
    // Inner classes -------------------------------------------------
 
-   protected class EJBContextImpl
-   implements EJBContext
+   protected class EJBContextImpl implements EJBContext
    {
       private InitialContext ctx;
 
@@ -471,7 +470,11 @@
             if (tm.getTransaction() == null)
                throw new IllegalStateException("getRollbackOnly() not allowed without a transaction.");
 
-            return tm.getStatus() == Status.STATUS_MARKED_ROLLBACK;
+            // JBAS-3847, consider an asynchronous rollback due to timeout
+            int status = tm.getStatus();
+            return status == Status.STATUS_MARKED_ROLLBACK
+                || status == Status.STATUS_ROLLING_BACK
+                || status == Status.STATUS_ROLLEDBACK;
          }
          catch (SystemException e)
          {



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 05:16:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 05:16:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r58989 -
	trunk/server/src/main/org/jboss/ejb
Message-ID: <E1Gu4gY-0001Fd-Dr@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 05:16:28 -0500 (Tue, 12 Dec 2006)
New Revision: 58989

Modified:
   trunk/server/src/main/org/jboss/ejb/EnterpriseContext.java
Log:
JBAS-3847, consider an asynchronous rollback due to timeout

Modified: trunk/server/src/main/org/jboss/ejb/EnterpriseContext.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EnterpriseContext.java	2006-12-12 09:54:33 UTC (rev 58988)
+++ trunk/server/src/main/org/jboss/ejb/EnterpriseContext.java	2006-12-12 10:16:28 UTC (rev 58989)
@@ -1,40 +1,43 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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;
 
-import java.rmi.RemoteException; 
-import java.security.Identity; 
-import java.security.Principal; 
+import java.rmi.RemoteException;
+import java.security.Identity;
+import java.security.Principal;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.Properties;
 import java.util.Set;
 import java.util.Stack;
+
 import javax.ejb.EJBContext;
 import javax.ejb.EJBException;
 import javax.ejb.EJBHome;
 import javax.ejb.EJBLocalHome;
-import javax.ejb.TimerService; 
+import javax.ejb.TimerService;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
 import javax.security.jacc.PolicyContextException;
 import javax.transaction.HeuristicMixedException;
 import javax.transaction.HeuristicRollbackException;
@@ -46,21 +49,19 @@
 import javax.transaction.Transaction;
 import javax.transaction.TransactionManager;
 import javax.transaction.UserTransaction;
-import javax.naming.InitialContext;
-import javax.naming.NamingException;
- 
+
 import org.jboss.logging.Logger;
 import org.jboss.metadata.ApplicationMetaData;
 import org.jboss.metadata.BeanMetaData;
-import org.jboss.metadata.SecurityRoleRefMetaData; 
+import org.jboss.metadata.SecurityRoleRefMetaData;
 import org.jboss.security.AuthorizationManager;
 import org.jboss.security.RealmMapping;
 import org.jboss.security.RunAsIdentity;
 import org.jboss.security.SecurityRoleRef;
-import org.jboss.security.SimplePrincipal; 
+import org.jboss.security.SimplePrincipal;
 import org.jboss.security.authorization.AuthorizationContext;
 import org.jboss.security.authorization.EJBResource;
-import org.jboss.security.authorization.ResourceKeys; 
+import org.jboss.security.authorization.ResourceKeys;
 import org.jboss.tm.TransactionTimeoutConfiguration;
 import org.jboss.tm.usertx.client.ServerVMClientUserTransaction;
 
@@ -84,7 +85,7 @@
  * @version $Revision$
  */
 public abstract class EnterpriseContext
-implements AllowedOperationsFlags
+   implements AllowedOperationsFlags
 {
    // Constants -----------------------------------------------------
 
@@ -287,8 +288,7 @@
 
    // Inner classes -------------------------------------------------
 
-   protected class EJBContextImpl
-   implements EJBContext
+   protected class EJBContextImpl implements EJBContext
    {
       /**
        *  A per-bean instance UserTransaction instance cached after the
@@ -455,7 +455,11 @@
             if (tm.getTransaction() == null)
                throw new IllegalStateException("getRollbackOnly() not allowed without a transaction.");
 
-            return tm.getStatus() == Status.STATUS_MARKED_ROLLBACK;
+            // JBAS-3847, consider an asynchronous rollback due to timeout
+            int status = tm.getStatus();
+            return status == Status.STATUS_MARKED_ROLLBACK
+                || status == Status.STATUS_ROLLING_BACK
+                || status == Status.STATUS_ROLLEDBACK;
          }
          catch (SystemException e)
          {



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 05:49:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 05:49:10 -0500
Subject: [jboss-cvs] JBossAS SVN: r58991 -
	branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3
Message-ID: <E1Gu5CA-0001i9-Ot@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 05:49:08 -0500 (Tue, 12 Dec 2006)
New Revision: 58991

Modified:
   branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
Log:
EJBTHREE-805, consider an asynchronous rollback due to timeout

Modified: branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
===================================================================
--- branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-12 10:48:15 UTC (rev 58990)
+++ branches/Branch_4_0/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-12 10:49:08 UTC (rev 58991)
@@ -271,7 +271,8 @@
    {
       // EJB1.1 11.6.1: Must throw IllegalStateException if BMT
       TransactionManagementType type = TxUtil.getTransactionManagementType(((Advisor) getContainer()));
-      if (type != TransactionManagementType.CONTAINER) throw new IllegalStateException("Container " + getContainer().getEjbName() + ": it is illegal to call getRollbackOnly from BMT: " + type);
+      if (type != TransactionManagementType.CONTAINER)
+         throw new IllegalStateException("Container " + getContainer().getEjbName() + ": it is illegal to call getRollbackOnly from BMT: " + type);
 
       try
       {
@@ -280,13 +281,17 @@
          // The getRollbackOnly and setRollBackOnly method of the SessionContext interface should be used
          // only in the session bean methods that execute in the context of a transaction.
          if (tm.getTransaction() == null)
-            throw new IllegalStateException("setRollbackOnly() not allowed without a transaction.");
+            throw new IllegalStateException("getRollbackOnly() not allowed without a transaction.");
 
-         return tm.getStatus() == Status.STATUS_MARKED_ROLLBACK;
+         // EJBTHREE-805, consider an asynchronous rollback due to timeout
+         int status = tm.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+             || status == Status.STATUS_ROLLING_BACK
+             || status == Status.STATUS_ROLLEDBACK;
       }
       catch (SystemException e)
       {
-         log.warn("failed to set rollback only; ignoring", e);
+         log.warn("failed to get tx manager status; ignoring", e);
          return true;
       }
    }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 05:48:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 05:48:18 -0500
Subject: [jboss-cvs] JBossAS SVN: r58990 -
	branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3
Message-ID: <E1Gu5BK-0001hq-0b@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 05:48:15 -0500 (Tue, 12 Dec 2006)
New Revision: 58990

Modified:
   branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
Log:
EJBTHREE-805, consider an asynchronous rollback due to timeout

Modified: branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
===================================================================
--- branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-12 10:16:28 UTC (rev 58989)
+++ branches/Branch_4_2/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-12 10:48:15 UTC (rev 58990)
@@ -271,7 +271,8 @@
    {
       // EJB1.1 11.6.1: Must throw IllegalStateException if BMT
       TransactionManagementType type = TxUtil.getTransactionManagementType(((Advisor) getContainer()));
-      if (type != TransactionManagementType.CONTAINER) throw new IllegalStateException("Container " + getContainer().getEjbName() + ": it is illegal to call getRollbackOnly from BMT: " + type);
+      if (type != TransactionManagementType.CONTAINER)
+         throw new IllegalStateException("Container " + getContainer().getEjbName() + ": it is illegal to call getRollbackOnly from BMT: " + type);
 
       try
       {
@@ -280,13 +281,17 @@
          // The getRollbackOnly and setRollBackOnly method of the SessionContext interface should be used
          // only in the session bean methods that execute in the context of a transaction.
          if (tm.getTransaction() == null)
-            throw new IllegalStateException("setRollbackOnly() not allowed without a transaction.");
+            throw new IllegalStateException("getRollbackOnly() not allowed without a transaction.");
 
-         return tm.getStatus() == Status.STATUS_MARKED_ROLLBACK;
+         // EJBTHREE-805, consider an asynchronous rollback due to timeout
+         int status = tm.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+             || status == Status.STATUS_ROLLING_BACK
+             || status == Status.STATUS_ROLLEDBACK;
       }
       catch (SystemException e)
       {
-         log.warn("failed to set rollback only; ignoring", e);
+         log.warn("failed to get tx manager status; ignoring", e);
          return true;
       }
    }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 05:50:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 05:50:19 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1770 - in trunk: .
	src/etc/server/default/deploy src/etc/xmdesc
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests tests/src/org/jboss/test/messaging/core
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gu5DH-0001jx-2M@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-12 05:49:42 -0500 (Tue, 12 Dec 2006)
New Revision: 1770

Added:
   trunk/jboss-remoting-npe-temp-fix.jar
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java
Removed:
   trunk/jboss-remoting-npe-fix.jar
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
Modified:
   trunk/.classpath
   trunk/src/etc/server/default/deploy/messaging-service.xml
   trunk/src/etc/xmdesc/ServerPeer-xmbean.xml
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/src/main/org/jboss/jms/tx/AckInfo.java
   trunk/src/main/org/jboss/messaging/core/Channel.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
More HA work



Modified: trunk/.classpath
===================================================================
--- trunk/.classpath	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/.classpath	2006-12-12 10:49:42 UTC (rev 1770)
@@ -11,7 +11,6 @@
 	<classpathentry kind="lib" path="lib/jboss-system.jar"/>
 	<classpathentry kind="lib" path="lib/jboss-transaction.jar"/>
 	<classpathentry kind="lib" path="lib/jnp-client.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/jboss-common.jar"/>
 	<classpathentry kind="lib" path="thirdparty/oswego-concurrent/lib/concurrent.jar"/>
 	<classpathentry kind="lib" path="tests/lib/jboss-common-jdbc-wrapper.jar"/>
 	<classpathentry kind="lib" path="tests/lib/jboss-jca.jar"/>
@@ -41,9 +40,6 @@
 	<classpathentry kind="lib" path="thirdparty/jboss/aop/lib/jdk14-pluggable-instrumentor.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/aop/lib/jrockit-pluggable-instrumentor.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/aop/lib/pluggable-instrumentor.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/jboss-archive-browsing.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/jboss-common-client.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/namespace.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
 	<classpathentry kind="lib" path="thirdparty/retrotranslator/lib/backport-util-concurrent.jar"/>
 	<classpathentry kind="lib" path="thirdparty/retrotranslator/lib/retrotranslator-runtime.jar"/>
@@ -51,5 +47,8 @@
 	<classpathentry kind="lib" path="thirdparty/trove/lib/trove.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
 	<classpathentry kind="var" path="ANT_HOME/lib/ant-junit.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
 	<classpathentry kind="output" path="bin"/>
 </classpath>

Deleted: trunk/jboss-remoting-npe-fix.jar
===================================================================
(Binary files differ)

Added: trunk/jboss-remoting-npe-temp-fix.jar
===================================================================
(Binary files differ)


Property changes on: trunk/jboss-remoting-npe-temp-fix.jar
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream

Modified: trunk/src/etc/server/default/deploy/messaging-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/messaging-service.xml	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/etc/server/default/deploy/messaging-service.xml	2006-12-12 10:49:42 UTC (rev 1770)
@@ -35,6 +35,8 @@
       </attribute>
       <attribute name="MaxDeliveryAttempts">10</attribute>
       <attribute name="DLQName">DLQ</attribute>
+      <attribute name="FailoverStartTimeout">3000</attribute>
+      <attribute name="FailoverCompleteTimeout">12000</attribute>
    </mbean>
 
 </server>
\ No newline at end of file

Modified: trunk/src/etc/xmdesc/ServerPeer-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-12 10:49:42 UTC (rev 1770)
@@ -150,7 +150,19 @@
       <description>The JNDI name of the DLQ</description>
       <name>DLQName</name>
       <type>java.lang.String</type>
-   </attribute>     
+   </attribute>  
+   
+   <attribute access="read-write" getMethod="getFailoverStartTimeout" setMethod="setFailoverStartTimeout">
+      <description>The maximum amount of time to wait for failover to begin</description>
+      <name>FailoverStartTimeout</name>
+      <type>long</type>
+   </attribute> 
+   
+   <attribute access="read-write" getMethod="getFailoverCompleteTimeout" setMethod="setFailoverCompleteTimeout">
+      <description>The maximum amount of time to wait for failover to complete</description>
+      <name>FailoverCompleteTimeout</name>
+      <type>long</type>
+   </attribute>      
 
    <!-- Managed operations -->
 

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -49,6 +49,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
+import org.jboss.jms.tx.AckInfo;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -328,8 +329,23 @@
          failedSessionDelegate.copyState(newSessionDelegate);
          
          log.info("copied state");
+         
+         //Now we remove any unacked np messages - this is because we don't want to ack them
+         //since the server won't know about them and will barf
+         Iterator iter = failedSessionState.getToAck().iterator();
+         
+         while (iter.hasNext())
+         {
+            AckInfo info = (AckInfo)iter.next();
+            
+            if (!info.getMessage().getMessage().isReliable())
+            {
+               iter.remove();
+            }            
+         }
+         
+         //TODO remove any unacked from the resource manager
 
-
          if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
 
          //TODO Clebert please add comment as to why this clone is necessary
@@ -359,8 +375,32 @@
                 handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
             }
          }
+         
+         /* Now we must sent the list of unacked AckInfos to the server - so the consumers
+          * delivery lists can be repopulated
+          */
+         List ackInfos = null;
+         
+         if (!failedSessionState.isTransacted())
+         {
+            //Get the ack infos from the list in the session state
+            ackInfos = failedSessionState.getToAck();
+         }
+         else
+         {
+            //Transacted session - we need to get the acks
+            //TODO
+         }
+         
+         //TODO for a transacted session the ackinfos will be in the resource manager!!
+         
+         if (!ackInfos.isEmpty())
+         {
+            newSessionDelegate.sendUnackedAckInfos(ackInfos);
+         }
+                  
       }
-      
+            
       //We must not start the connection until the end
       if (failedState.isStarted())
       {
@@ -369,6 +409,8 @@
       
       log.info("Failover done");
    }
+   
+   
 
    private void handleFailoverOnConsumer(ClientConnectionDelegate connectionDelegate,
                                          ConnectionState failedConnectionState,
@@ -387,11 +429,11 @@
 
       ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)failedSessionDelegate.
          failOverConsumer((JBossDestination)failedConsumerState.getDestination(),
-                                failedConsumerState.getSelector(),
-                                failedConsumerState.isNoLocal(),
-                                failedConsumerState.getSubscriptionName(),
-                                failedConsumerState.isConnectionConsumer(),
-                                failedConsumerDelegate.getChannelId());
+                           failedConsumerState.getSelector(),
+                           failedConsumerState.isNoLocal(),
+                           failedConsumerState.getSubscriptionName(),
+                           failedConsumerState.isConnectionConsumer(),
+                           failedConsumerDelegate.getChannelId());
 
       if (trace) { log.trace("handleFailoverOnConsumer: alternate consumer created"); }
 
@@ -418,6 +460,9 @@
 
       MessageCallbackHandler handler = cm.unregisterHandler(oldServerID, oldConsumerID);
       handler.setConsumerId(failedConsumerState.getConsumerID());
+      
+      //Clear the buffer of the handler
+      handler.clearBuffer();
 
       cm.registerHandler(failedConnectionState.getServerID(),
                          failedConsumerState.getConsumerID(),
@@ -426,8 +471,8 @@
       failedSessionState.addCallbackHandler(handler);
       
       log.info("failed over consumer");
-
    }
+   
 
    private void handleFailoverOnProducer(ProducerState failedProducerState,
                                          ClientSessionDelegate failedSessionDelegate)

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -441,6 +441,15 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
    
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+   
 
    // Public --------------------------------------------------------
 
@@ -457,6 +466,7 @@
       return ((ConnectionState)state.getParent()).getRemotingConnection().getInvokingClient();
    }
 
+
    // Package Private -----------------------------------------------
 
    // Private -------------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -94,6 +94,8 @@
 
    public void registerHandler(int serverID, int consumerID, MessageCallbackHandler handler)
    {
+      log.info(this + " registeringHandler, serverID:" + serverID + " consumerID:" + consumerID);
+      
       Long lookup = computeLookup(serverID, consumerID);
 
       callbackHandlers.put(lookup, handler);
@@ -101,6 +103,8 @@
 
    public MessageCallbackHandler unregisterHandler(int serverID, int consumerID)
    {
+      log.info(this + " unregisteringHandler, serverID:" + serverID + " consumerID:" + consumerID);
+      
       Long lookup = computeLookup(serverID, consumerID);
 
       return (MessageCallbackHandler)callbackHandlers.remove(lookup);

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -316,6 +316,9 @@
          // otherwise the messages wouldn't get cancelled until the corresponding session died.
          // So if another consumer in another session tried to consume from the channel before that
          // session died it wouldn't receive those messages.
+         // We can't just cancel all the messages in the SCE since some of those messages might
+         // have actually been delivered (unlike these) and we may want to acknowledge them
+         // later, after this consumer has been closed
 
          List ackInfos = new ArrayList();
 
@@ -514,6 +517,11 @@
       }
    }
    
+   public void clearBuffer()
+   {
+      buffer.clear();
+   }
+   
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -48,7 +48,6 @@
  */
 public class SessionState extends HierarchicalStateSupport
 {
-
    protected static Logger log = Logger.getLogger(SessionState.class);
 
    private int acknowledgeMode;
@@ -205,16 +204,5 @@
    {
       return new ArrayList(callbackHandlers.values());
    }
-
-   /*** used for HA Handling */
-   public void cleanCallBackHandlers()
-   {
-       if (log.isTraceEnabled())
-       {
-           log.trace("Clearing callBackHandlers size=" + callbackHandlers.size());
-       }
-       callbackHandlers.clear();
-   }
-
 }
 

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -111,6 +111,10 @@
    private String dlqName;
 
    private Object failoverStatusLock;
+   
+   private long failoverStartTimeout = 3000;
+   
+   private long failoverCompleteTimeout = 12000;
       
    // wired components
 
@@ -135,9 +139,6 @@
    protected ObjectName postOfficeObjectName;
    protected PostOffice postOffice;
 
-//   protected ObjectName topicPostOfficeObjectName;
-//   protected PostOffice topicPostOffice;
-
    protected ObjectName jmsUserManagerObjectName;
    protected JMSUserManager jmsUserManager;
 
@@ -352,16 +353,6 @@
       postOfficeObjectName = on;
    }
 
-//   public ObjectName getTopicPostOffice()
-//   {
-//      return topicPostOfficeObjectName;
-//   }
-//
-//   public void setTopicPostOffice(ObjectName on)
-//   {
-//      topicPostOfficeObjectName = on;
-//   }
-
    public ObjectName getJmsUserManager()
    {
       return jmsUserManagerObjectName;
@@ -478,6 +469,28 @@
    {
       this.queuedExecutorPoolSize = poolSize;
    }
+   
+   public long getFailoverStartTimeout()
+   {
+      return this.failoverStartTimeout;
+   }
+   
+   public void setFailoverStartTimeout(long timeout)
+   {
+      this.failoverStartTimeout = timeout;
+   }
+   
+   public long getFailoverCompleteTimeout()
+   {
+      return this.failoverCompleteTimeout;
+   }
+   
+   public void setFailoverCompleteTimeout(long timeout)
+   {
+      this.failoverCompleteTimeout = timeout;
+   }
+   
+   
 
    // JMX Operations ------------------------------------------------
 
@@ -729,14 +742,11 @@
       
       Replicator replicator = getReplicator();
       
-      //TODO - these must be configurable
-      final long FAILOVER_START_TIMEOUT = 15000;
+      //Failover
+
+      long startToWait = failoverStartTimeout;
       
-      final long FAILOVER_COMPLETE_TIMEOUT = 25000;
-      
-      long startToWait = FAILOVER_START_TIMEOUT;
-      
-      long completeToWait = FAILOVER_COMPLETE_TIMEOUT;
+      long completeToWait = failoverCompleteTimeout;
                      
       //Must lock here
       synchronized (failoverStatusLock)
@@ -1104,5 +1114,4 @@
          }
       }      
    }
-
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -31,9 +31,9 @@
 import org.jboss.jms.selector.Selector;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Filter;
 import org.jboss.messaging.core.Routable;
-import org.jboss.messaging.core.local.PagingFilteredQueue;
 
 /**
  * Concrete implementation of BrowserEndpoint.
@@ -66,7 +66,7 @@
    // Constructors --------------------------------------------------
 
    protected ServerBrowserEndpoint(ServerSessionEndpoint session, int id,
-                                   PagingFilteredQueue destination, String messageSelector)
+                                   Channel destination, String messageSelector)
       throws JMSException
    {     
       this.session = session;

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -42,6 +42,7 @@
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.MessageReference;
@@ -49,7 +50,6 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.Routable;
 import org.jboss.messaging.core.SimpleDelivery;
-import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.Transaction;
@@ -87,7 +87,7 @@
 
    private int id;
 
-   private PagingFilteredQueue messageQueue;
+   private Channel messageQueue;
    
    private String queueName;
 
@@ -131,7 +131,7 @@
    
    // Constructors --------------------------------------------------
 
-   protected ServerConsumerEndpoint(int id, PagingFilteredQueue messageQueue, String queueName,
+   protected ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
                                     ServerSessionEndpoint sessionEndpoint,
                                     String selector, boolean noLocal, JBossDestination dest,
                                     int prefetchSize, Queue dlq)
@@ -633,7 +633,24 @@
       }
       
    }
-   
+
+   protected void createDeliveries(List messageIds) throws Throwable
+   {
+      List dels = messageQueue.createDeliveries(messageIds);
+            
+      synchronized (lock)
+      {      
+         Iterator iter = dels.iterator();
+         
+         while (iter.hasNext())
+         {
+            Delivery del = (Delivery)iter.next();
+            
+            deliveries.put(new Long(del.getReference().getMessageID()), del);
+         }
+      }
+   }
+
    protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
    {
       Delivery del = (Delivery)deliveries.remove(messageID);
@@ -653,7 +670,7 @@
          throw new IllegalStateException("Cannot find delivery to cancel:" + id);
       }
    }
-               
+           
    protected void start()
    {             
       synchronized (lock)

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -27,6 +27,7 @@
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
+import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
@@ -186,11 +187,11 @@
          int prefetchSize = connectionEndpoint.getPrefetchSize();
          
          ServerConsumerEndpoint ep =
-            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+
+            new ServerConsumerEndpoint(consumerID, binding.getQueue(),
                                        binding.getQueue().getName(), this, selectorString, noLocal,
                                        jmsDestination, prefetchSize, dlq);
 
-         
          JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
          
          ClientConsumerDelegate stub =
@@ -755,6 +756,56 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " cancelDeliveries");
       }
    }
+   
+   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   {
+      try
+      {
+         //Sort into different list for each consumer
+         Map ackMap = new HashMap();
+                  
+         for (int i = ackInfos.size() - 1; i >= 0; i--)
+         {
+            AckInfo ack = (AckInfo)ackInfos.get(i);
+            
+            ServerConsumerEndpoint consumer =
+               this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
+   
+            if (consumer == null)
+            {
+               throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
+            }
+            
+            LinkedList acks = (LinkedList)ackMap.get(consumer);
+            
+            if (acks == null)
+            {
+               acks = new LinkedList();
+               
+               ackMap.put(consumer, acks);
+            }
+            
+            acks.addFirst(new Long(ack.getMessageID()));
+         }  
+         
+         Iterator iter = ackMap.entrySet().iterator();
+         
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+            
+            ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)entry.getKey();
+            
+            List acks = (List)entry.getValue();
+            
+            consumer.createDeliveries(acks);
+         }
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " sendUnackedAckInfos");
+      }
+   }
 
    public void addTemporaryDestination(JBossDestination dest) throws JMSException
    {

Modified: trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -120,5 +120,14 @@
     * @param ackInfos
     */
    void cancelDeliveries(List ackInfos) throws JMSException;
+   
+   
+   /**
+    * Send a list of unacked ackInfos to the server so the delivery lists can be repopulated
+    * used at failover
+    * @param ackInfos
+    * @throws JMSException
+    */
+   void sendUnackedAckInfos(List ackInfos) throws JMSException;
 }
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -147,6 +147,11 @@
    {
       endpoint.cancelDeliveries(ackInfos);
    }
+   
+   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   {
+      endpoint.sendUnackedAckInfos(ackInfos);
+   }
 
 
    // AdvisedSupport overrides --------------------------------------
@@ -161,6 +166,7 @@
       return "SessionAdvised->" + endpoint;
    }
 
+
    // Public --------------------------------------------------------
 
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -37,8 +37,8 @@
 
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.client.remoting.HandleMessageResponse;
-import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
@@ -95,6 +95,7 @@
    protected static final byte MORE = 5;
    protected static final byte SEND_TRANSACTION = 6;
    protected static final byte GET_ID_BLOCK = 7;
+   protected static final byte UNACKED_ACKINFOS = 8;
  
 
    // The response codes - start from 100
@@ -312,6 +313,28 @@
    
                   if (trace) { log.trace("wrote cancelDeliveries()"); }
                }
+               else if ("sendUnackedAckInfos".equals(methodName) && mi.getArguments() != null)
+               {
+                  dos.writeByte(UNACKED_ACKINFOS);
+   
+                  writeHeader(mi, dos);
+   
+                  List ids = (List)mi.getArguments()[0];
+   
+                  dos.writeInt(ids.size());
+   
+                  Iterator iter = ids.iterator();
+   
+                  while (iter.hasNext())
+                  {
+                     AckInfo ack = (AckInfo)iter.next();
+                     ack.write(dos);
+                  }
+   
+                  dos.flush();
+   
+                  if (trace) { log.trace("wrote sendUnackedAckInfos()"); }
+               }
                else
                {
                   dos.write(SERIALIZED);
@@ -700,6 +723,35 @@
    
                return request;
             }
+            case UNACKED_ACKINFOS:
+            {
+               MethodInvocation mi = readHeader(dis);
+   
+               int size = dis.readInt();
+   
+               List acks = new ArrayList(size);
+   
+               for (int i = 0; i < size; i++)
+               {
+                  AckInfo ack = new AckInfo();
+                  
+                  ack.read(dis);
+                  
+                  acks.add(ack);
+               }
+   
+               Object[] args = new Object[] {acks};
+   
+               mi.setArguments(args);
+   
+               InvocationRequest request =
+                  new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
+                                        new MessagingMarshallable(version, mi), null, null, null);
+   
+               if (trace) { log.trace("read unackedAckInfos()"); }
+   
+               return request;
+            }
             case ID_BLOCK_RESPONSE:
             {
                IdBlock block = new IdBlock();

Modified: trunk/src/main/org/jboss/jms/tx/AckInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -86,7 +86,7 @@
    /** Used to change ack's id during failover */
    public void setConsumerID(int consumerID)
    {
-       this.consumerID=consumerID;
+       this.consumerID = consumerID;
    }
    
    public MessageProxy getMessage()

Modified: trunk/src/main/org/jboss/messaging/core/Channel.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -145,6 +145,8 @@
    void deactivate();
    
    boolean isActive();
+   
+   List createDeliveries(List messageIds);
 
 }
 

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -491,6 +491,66 @@
          }
       }
    }
+   
+   public List createDeliveries(List messageIds)
+   {
+      //debug
+      Iterator iter = messageIds.iterator();
+      
+      log.info("***** createdeliveries");
+      while (iter.hasNext())
+      {
+         Long l = (Long)iter.next();
+         
+         log.info("Creating delivery for " + l);
+      }
+      log.info("**** end dump");
+      
+      iter = messageIds.iterator();
+      
+      List dels = new ArrayList();
+      
+      synchronized (refLock)
+      {
+         synchronized (deliveryLock)
+         {
+            ListIterator liter = messageRefs.iterator();
+                              
+            while (iter.hasNext())
+            {
+               Long id = (Long)iter.next();
+               
+               //Scan the queue
+               while (true)
+               {               
+                  if (!liter.hasNext())
+                  {
+                     // TODO we need to look in paging state too - currently not supported
+                     
+                     throw new IllegalStateException("Cannot find ref in queue! (Might be paged!)");
+                  }
+                  
+                  MessageReference ref = (MessageReference)liter.next();
+                  
+                  if (ref.getMessageID() == id.longValue())
+                  {
+                     liter.remove();
+                     
+                     Delivery del = new SimpleDelivery(this, ref);
+                     
+                     dels.add(del);
+                                    
+                     this.deliveries.add(del);
+                     
+                     break;
+                  }
+               }
+            }  
+         }
+      }
+            
+      return dels;
+   }
 
    // Public --------------------------------------------------------
 

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -272,4 +272,9 @@
    {
       return "RemoteQueueStub(node=" + this.nodeId + " name=" + this.name + " channelId=" + this.id + ")";
    }
+
+   public List createDeliveries(List messageIds)
+   {
+      throw new UnsupportedOperationException();
+   }
 }

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/tests/build.xml	2006-12-12 10:49:42 UTC (rev 1770)
@@ -745,7 +745,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -216,6 +216,11 @@
       throw new UnsupportedOperationException();
    }
 
+   public List createDeliveries(List messageIds)
+   {
+      throw new UnsupportedOperationException();
+   }
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -369,6 +369,12 @@
          // TODO Auto-generated method stub
          return false;
       }
+
+      public List createDeliveries(List messageIds)
+      {
+         // TODO Auto-generated method stub
+         return null;
+      }
       
    }
 

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -24,6 +24,7 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.Filter;
@@ -608,6 +609,12 @@
          // TODO Auto-generated method stub
          return false;
       }
+
+      public List createDeliveries(List messageIds)
+      {
+         // TODO Auto-generated method stub
+         return null;
+      }
       
    }
    

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java (from rev 1767, trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java)
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-12 02:16:50 UTC (rev 1767)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -0,0 +1,1023 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
+
+import javax.jms.Connection;
+import javax.jms.DeliveryMode;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageListener;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+
+/**
+ * 
+ * A DistributedDestinationsTest
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class DistributedDestinationsTest extends ClusteringTestBase
+{
+
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public DistributedDestinationsTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testClusteredQueueLocalConsumerNonPersistent() throws Exception
+   {
+      clusteredQueueLocalConsumer(false);
+   }
+
+   public void testClusteredQueueLocalConsumerPersistent() throws Exception
+   {
+      clusteredQueueLocalConsumer(true);
+   }
+
+   public void testClusteredTopicNonDurableNonPersistent() throws Exception
+   {
+      clusteredTopicNonDurable(false);
+   }
+
+   public void testClusteredTopicNonDurablePersistent() throws Exception
+   {
+      clusteredTopicNonDurable(true);
+   }
+
+   public void testClusteredTopicNonDurableWithSelectorsNonPersistent() throws Exception
+   {
+      clusteredTopicNonDurableWithSelectors(false);
+   }
+
+   public void testClusteredTopicNonDurableWithSelectorsPersistent() throws Exception
+   {
+      clusteredTopicNonDurableWithSelectors(true);
+   }
+
+   public void testClusteredTopicDurableNonPersistent() throws Exception
+   {
+      clusteredTopicDurable(false);
+   }
+
+   public void testClusteredTopicDurablePersistent() throws Exception
+   {
+      clusteredTopicDurable(true);
+   }
+
+   public void testClusteredTopicSharedDurableLocalConsumerNonPersistent() throws Exception
+   {
+      clusteredTopicSharedDurableLocalConsumer(false);
+   }
+
+   public void testClusteredTopicSharedDurableLocalConsumerPersistent() throws Exception
+   {
+      clusteredTopicSharedDurableLocalConsumer(true);
+   }
+
+   public void testClusteredTopicSharedDurableNoLocalSubNonPersistent() throws Exception
+   {
+      clusteredTopicSharedDurableNoLocalSub(false);
+   }
+
+   public void testClusteredTopicSharedDurableNoLocalSubPersistent() throws Exception
+   {
+      clusteredTopicSharedDurableNoLocalSub(true);
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+  
+
+   /*
+    * Create a consumer on each queue on each node.
+    * Send messages in turn from all nodes.
+    * Ensure that the local consumer gets the message
+    */
+   protected void clusteredQueueLocalConsumer(boolean persistent) throws Exception
+   {
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+
+      try
+      {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.info("Created sessions");
+
+         MessageConsumer cons1 = sess1.createConsumer(queue0);
+         MessageConsumer cons2 = sess2.createConsumer(queue1);
+         MessageConsumer cons3 = sess3.createConsumer(queue2);
+         
+         log.info("Created consumers");
+
+         conn1.start();
+         conn2.start();
+         conn3.start();
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(queue0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess1.createTextMessage("message" + i);
+
+            prod.send(tm);
+         }
+         
+         log.info("Sent messages");
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
+            assertNotNull(tm);
+            
+            assertEquals("message" + i, tm.getText());
+         }                 
+
+         Message m = cons2.receive(2000);
+
+         assertNull(m);
+
+         m = cons3.receive(2000);
+
+         assertNull(m);
+
+         // Send at node 1
+
+         MessageProducer prod1 = sess2.createProducer(queue1);
+
+         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess2.createTextMessage("message" + i);
+
+            prod1.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         m = cons1.receive(2000);
+
+         assertNull(m);
+
+         m = cons3.receive(2000);
+
+         assertNull(m);
+
+         // Send at node 2
+
+         MessageProducer prod2 = sess3.createProducer(queue2);
+
+         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess3.createTextMessage("message" + i);
+
+            prod2.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         m = cons1.receive(2000);
+
+         assertNull(m);
+
+         m = cons2.receive(2000);
+
+         assertNull(m);
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+      }
+   }
+
+   // Private -------------------------------------------------------
+
+   /*
+    * Create non durable subscriptions on all nodes of the cluster.
+    * Ensure all messages are receive as appropriate
+    */
+   private void clusteredTopicNonDurable(boolean persistent) throws Exception
+   {
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+      try
+      {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageConsumer cons1 = sess1.createConsumer(topic0);
+         MessageConsumer cons2 = sess2.createConsumer(topic1);
+         MessageConsumer cons3 = sess3.createConsumer(topic2);
+
+         MessageConsumer cons4 = sess1.createConsumer(topic0);
+
+         MessageConsumer cons5 = sess2.createConsumer(topic1);
+
+         conn1.start();
+         conn2.start();
+         conn3.start();
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess1.createTextMessage("message" + i);
+
+            prod.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons4.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons5.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+      }
+   }
+
+   /*
+    * Create non durable subscriptions on all nodes of the cluster.
+    * Include some with selectors
+    * Ensure all messages are receive as appropriate
+    */
+   private void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
+   {
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+
+      try
+      {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageConsumer cons1 = sess1.createConsumer(topic0);
+         MessageConsumer cons2 = sess2.createConsumer(topic1);
+         MessageConsumer cons3 = sess3.createConsumer(topic2);
+
+         MessageConsumer cons4 = sess1.createConsumer(topic0, "COLOUR='red'");
+
+         MessageConsumer cons5 = sess2.createConsumer(topic1, "COLOUR='blue'");
+
+         conn1.start();
+         conn2.start();
+         conn3.start();
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess1.createTextMessage("message" + i);
+
+            int c = i % 3;
+            if (c == 0)
+            {
+               tm.setStringProperty("COLOUR", "red");
+            }
+            else if (c == 1)
+            {
+               tm.setStringProperty("COLOUR", "blue");
+            }
+
+            prod.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            int c = i % 3;
+
+            if (c == 0)
+            {
+               TextMessage tm = (TextMessage)cons4.receive(1000);
+
+               assertNotNull(tm);
+
+               assertEquals("message" + i, tm.getText());
+            }
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            int c = i % 3;
+
+            if (c == 1)
+            {
+               TextMessage tm = (TextMessage)cons5.receive(1000);
+
+               assertNotNull(tm);
+
+               assertEquals("message" + i, tm.getText());
+            }
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+      }
+   }
+
+
+
+   /*
+    * Create durable subscriptions on all nodes of the cluster.
+    * Include a couple with selectors
+    * Ensure all messages are receive as appropriate
+    * None of the durable subs are shared
+    */
+   private void clusteredTopicDurable(boolean persistent) throws Exception
+   {
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+      try
+      {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+
+         conn1.setClientID("wib1");
+         conn2.setClientID("wib1");
+         conn3.setClientID("wib1");
+
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         try
+         {
+            sess1.unsubscribe("sub");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess2.unsubscribe("sub1");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess3.unsubscribe("sub2");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess1.unsubscribe("sub3");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess2.unsubscribe("sub4");
+         }
+         catch (Exception ignore) {}
+
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub1");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub2");
+         MessageConsumer cons4 = sess1.createDurableSubscriber(topic0, "sub3");
+         MessageConsumer cons5 = sess2.createDurableSubscriber(topic1, "sub4");
+
+         conn1.start();
+         conn2.start();
+         conn3.start();
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess2.createTextMessage("message" + i);
+
+            prod.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons4.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons5.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         cons1.close();
+         cons2.close();
+         cons3.close();
+         cons4.close();
+         cons5.close();
+
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub1");
+         sess3.unsubscribe("sub2");
+         sess1.unsubscribe("sub3");
+         sess2.unsubscribe("sub4");
+
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+      }
+   }
+
+
+
+
+   /*
+    * Create shared durable subs on multiple nodes, the local instance should always get the message
+    */
+   protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
+   {
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+      try
+
+      {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         conn1.setClientID("wib1");
+         conn2.setClientID("wib1");
+         conn3.setClientID("wib1");
+
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         try
+         {
+            sess1.unsubscribe("sub");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess2.unsubscribe("sub");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess3.unsubscribe("sub");
+         }
+         catch (Exception ignore) {}
+
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub");
+
+         conn1.start();
+         conn2.start();
+         conn3.start();
+
+         // Send at node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess1.createTextMessage("message" + i);
+
+            prod.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         Message m = cons2.receive(2000);
+
+         assertNull(m);
+
+         m = cons3.receive(2000);
+
+         assertNull(m);
+
+         // Send at node 1
+
+         MessageProducer prod1 = sess2.createProducer(topic1);
+
+         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess3.createTextMessage("message" + i);
+
+            prod1.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         m = cons1.receive(2000);
+
+         assertNull(m);
+
+         m = cons3.receive(2000);
+
+         assertNull(m);
+
+         // Send at node 2
+
+         MessageProducer prod2 = sess3.createProducer(topic2);
+
+         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess3.createTextMessage("message" + i);
+
+            prod2.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i, tm.getText());
+         }
+
+         m = cons1.receive(2000);
+
+         assertNull(m);
+
+         m = cons2.receive(2000);
+
+         assertNull(m);
+
+         cons1.close();
+         cons2.close();
+         cons3.close();
+
+         // Need to unsubscribe on any node that the durable sub was created on
+
+         sess1.unsubscribe("sub");
+         sess2.unsubscribe("sub");
+         sess3.unsubscribe("sub");
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+      }
+   }
+
+
+
+   /*
+    * Create shared durable subs on multiple nodes, but without sub on local node
+    * should round robin
+    * note that this test assumes round robin
+    */
+   protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
+   {
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+
+      try
+      {
+         //This will create 3 different connection on 3 different nodes, since
+         //the cf is clustered
+         conn1 = cf.createConnection();
+         conn2 = cf.createConnection();
+         conn3 = cf.createConnection();
+         
+         log.info("Created connections");
+         
+         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         
+         conn2.setClientID("wib1");
+         conn3.setClientID("wib1");
+
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         try
+         {
+            sess2.unsubscribe("sub");
+         }
+         catch (Exception ignore) {}
+         try
+         {
+            sess3.unsubscribe("sub");
+         }
+         catch (Exception ignore) {}
+
+         MessageConsumer cons1 = sess2.createDurableSubscriber(topic1, "sub");
+         MessageConsumer cons2 = sess3.createDurableSubscriber(topic2, "sub");
+
+         conn2.start();
+         conn3.start();
+
+         // Send at node 0
+
+         //Should round robin between the other 2 since there is no active consumer on sub  on node 0
+
+         MessageProducer prod = sess1.createProducer(topic0);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess1.createTextMessage("message" + i);
+
+            prod.send(tm);
+         }
+
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons1.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + i * 2, tm.getText());
+         }
+
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("message" + (i * 2 + 1), tm.getText());
+         }
+
+         cons1.close();
+         cons2.close();
+
+         sess2.unsubscribe("sub");
+         sess3.unsubscribe("sub");
+
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+      }
+   }
+
+   class MyListener implements MessageListener
+   {
+      private int i;
+
+      MyListener(int i)
+      {
+         this.i = i;
+      }
+
+      public void onMessage(Message m)
+      {
+         try
+         {
+            int count = m.getIntProperty("count");
+
+            log.info("Listener " + i + " received message " + count);
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
+      }
+
+   }
+
+
+   // Inner classes -------------------------------------------------
+
+   
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -26,6 +26,7 @@
 import java.util.Set;
 
 import javax.jms.Connection;
+import javax.jms.Message;
 import javax.jms.MessageConsumer;
 import javax.jms.MessageProducer;
 import javax.jms.Session;
@@ -36,7 +37,6 @@
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -69,355 +69,490 @@
    }
    
    // Public --------------------------------------------------------
+//   
+//   /*
+//    * Test that connections created using a clustered connection factory are created round robin on
+//    * different servers
+//    */
+//   public void testRoundRobinConnectionCreation() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//      
+//      log.info ("number of delegates = " + delegate.getDelegates().length);
+//      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
+//      
+//      assertEquals(3, delegate.getDelegates().length);
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//      
+//      assertEquals(0, cf1.getServerId());
+//      
+//      assertEquals(1, cf2.getServerId());
+//      
+//      assertEquals(2, cf3.getServerId());
+//      
+//      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+//      
+//      Connection conn1 = null;
+//      
+//      Connection conn2 = null;
+//      
+//      Connection conn3 = null;
+//      
+//      Connection conn4 = null;
+//      
+//      Connection conn5 = null;
+//      
+//      try
+//      {         
+//         conn1 = factory.createConnection();
+//         
+//         conn2 = factory.createConnection();
+//         
+//         conn3 = factory.createConnection();
+//         
+//         conn4 = factory.createConnection();
+//         
+//         conn5 = factory.createConnection();
+//         
+//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+//         
+//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+//         
+//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+//         
+//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+//         
+//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+//         
+//         int serverID1 = state1.getServerID();
+//         
+//         int serverID2 = state2.getServerID();
+//         
+//         int serverID3 = state3.getServerID();
+//         
+//         int serverID4 = state4.getServerID();
+//         
+//         int serverID5 = state5.getServerID();
+//         
+//         log.info("server id 1: " + serverID1);
+//         
+//         log.info("server id 2: " + serverID2);
+//         
+//         log.info("server id 3: " + serverID3);
+//         
+//         log.info("server id 4: " + serverID4);
+//         
+//         log.info("server id 5: " + serverID5);
+//         
+//         assertEquals(0, serverID1);
+//         
+//         assertEquals(1, serverID2);
+//         
+//         assertEquals(2, serverID3);
+//         
+//         assertEquals(0, serverID4);
+//         
+//         assertEquals(1, serverID5);
+//      }
+//      finally
+//      {
+//         if (conn1 != null)
+//         {
+//            conn1.close();
+//         }
+//         
+//         if (conn2 != null)
+//         {
+//            conn2.close();
+//         }
+//         
+//         if (conn3 != null)
+//         {
+//            conn3.close();
+//         }
+//         
+//         if (conn4 != null)
+//         {
+//            conn4.close();
+//         }
+//         
+//         if (conn5 != null)
+//         {
+//            conn5.close();
+//         }
+//      }
+//      
+//   }
+// 
+//   /*
+//    * Test that the failover mapping is created correctly and updated properly when nodes leave
+//    * or join
+//    */
+//   public void testDefaultFailoverMap() throws Exception
+//   {     
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         //The order here depends on the order the servers were started in
+//         
+//         //If any servers get stopped and then started then the order will change
+//    
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         
+//         assertEquals(0, cf1.getServerId());
+//         
+//         assertEquals(1, cf2.getServerId());
+//         
+//         assertEquals(2, cf3.getServerId());
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         // Default failover policy just chooses the node to the right
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }
+//      
+//      //Now cleanly stop one of the servers
+//            
+//      log.info("************** STOPPING SERVER 0");
+//      ServerManagement.stop(0);
+//      
+//      log.info("server stopped");
+//      
+//      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         //Order here depends on order servers were started in
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(1, cf1.getServerId());
+//         
+//         assertEquals(2, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      //Cleanly stop another server
+//      
+//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+//      
+//      ServerManagement.stop(1);
+//      
+//      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(1, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         
+//         assertEquals(1, failoverMap.size());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//      }
+//            
+//      //Restart server 0
+//      
+//      ServerManagement.start("all", 0);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      
+//      //Restart server 1
+//      
+//      ServerManagement.start("all", 1);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         assertEquals(1, cf3.getServerId());
+//         
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }            
+//   }
+//   
+//   public void testSimpleFailover() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerId();
+//      
+//      int server1Id = cf2.getServerId();
+//      
+//      int server2Id = cf3.getServerId();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      try
+//      {
+//      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         MessageProducer prod = sess.createProducer(queue1);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue1);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         //So now, messages should be in queue1 on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.getServer(1).destroy();
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(1000);
+//            
+//            log.info("message is " + tm);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         log.info("done");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
    
-   /*
-    * Test that connections created using a clustered connection factory are created round robin on
-    * different servers
-    */
-   public void testRoundRobinConnectionCreation() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      log.info ("number of delegates = " + delegate.getDelegates().length);
-      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
-      
-      assertEquals(3, delegate.getDelegates().length);
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-      
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-      
-      Connection conn4 = null;
-      
-      Connection conn5 = null;
-      
-      try
-      {         
-         conn1 = factory.createConnection();
-         
-         conn2 = factory.createConnection();
-         
-         conn3 = factory.createConnection();
-         
-         conn4 = factory.createConnection();
-         
-         conn5 = factory.createConnection();
-         
-         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
-         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
-         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
-         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
-         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
-         int serverID1 = state1.getServerID();
-         
-         int serverID2 = state2.getServerID();
-         
-         int serverID3 = state3.getServerID();
-         
-         int serverID4 = state4.getServerID();
-         
-         int serverID5 = state5.getServerID();
-         
-         log.info("server id 1: " + serverID1);
-         
-         log.info("server id 2: " + serverID2);
-         
-         log.info("server id 3: " + serverID3);
-         
-         log.info("server id 4: " + serverID4);
-         
-         log.info("server id 5: " + serverID5);
-         
-         assertEquals(0, serverID1);
-         
-         assertEquals(1, serverID2);
-         
-         assertEquals(2, serverID3);
-         
-         assertEquals(0, serverID4);
-         
-         assertEquals(1, serverID5);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-         
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-         
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-         
-         if (conn4 != null)
-         {
-            conn4.close();
-         }
-         
-         if (conn5 != null)
-         {
-            conn5.close();
-         }
-      }
-      
-   }
- 
-   /*
-    * Test that the failover mapping is created correctly and updated properly when nodes leave
-    * or join
-    */
-   public void testDefaultFailoverMap() throws Exception
-   {     
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         //The order here depends on the order the servers were started in
-         
-         //If any servers get stopped and then started then the order will change
-    
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         
-         assertEquals(0, cf1.getServerId());
-         
-         assertEquals(1, cf2.getServerId());
-         
-         assertEquals(2, cf3.getServerId());
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(3, delegates.length);
-         
-         assertEquals(3, failoverMap.size());
-         
-         // Default failover policy just chooses the node to the right
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }
-      
-      //Now cleanly stop one of the servers
-            
-      log.info("************** STOPPING SERVER 0");
-      ServerManagement.stop(0);
-      
-      log.info("server stopped");
-      
-      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         //Order here depends on order servers were started in
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(1, cf1.getServerId());
-         
-         assertEquals(2, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      //Cleanly stop another server
-      
-      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
-      ServerManagement.stop(1);
-      
-      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(1, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         assertEquals(2, cf1.getServerId());
-         
-         
-         assertEquals(1, failoverMap.size());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      }
-            
-      //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      
-      //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(3, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         assertEquals(1, cf3.getServerId());
-         
-         
-         assertEquals(3, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }            
-   }
    
-   public void testSimpleFailover() throws Exception
+   public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
       
@@ -462,8 +597,7 @@
       Connection conn = null;
       
       try
-      {
-      
+      {      
          //Get a connection on server 1
          conn = factory.createConnection(); //connection on server 0
          
@@ -481,7 +615,7 @@
          
          assertEquals(1, initialServerID);
                            
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
          
          MessageProducer prod = sess.createProducer(queue1);
          
@@ -496,6 +630,20 @@
             prod.send(tm);
          }
          
+         conn.start();
+         
+         //Now consume half of the messages but don't ack them these will end up in 
+         //client side toAck list
+         
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
          //So now, messages should be in queue1 on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
@@ -503,7 +651,7 @@
          log.info("************ KILLING (CRASHING) SERVER 1");
          
          ServerManagement.getServer(1).kill();
-
+         
          log.info("killed server, now waiting");
          
          Thread.sleep(5000);
@@ -522,17 +670,41 @@
          
          conn.start();
          
-         for (int i = 0; i < NUM_MESSAGES; i++)
+         //Now should be able to consume the rest of the messages
+         
+         log.info("here1");
+         
+         TextMessage tm = null;
+         
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons.receive(1000);
+            tm = (TextMessage)cons.receive(500);
+                                    
+            log.info("message is " + tm.getText());
             
-            log.info("message is " + tm);
-            
             assertNotNull(tm);
             
             assertEquals("message:" + i, tm.getText());
          }
-         log.info("done");
+         
+         log.info("here2");
+         
+         //Now should be able to acknowledge them
+         
+         tm.acknowledge();
+         
+         //Now check there are no more messages there
+         sess.close();
+         
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons = sess.createConsumer(queue1);
+         
+         Message m = cons.receive(500);
+         
+         assertNull(m);
+         
+         log.info("got to end of test");
       }
       finally
       {         
@@ -551,6 +723,182 @@
       
    }
    
+//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerId();
+//      
+//      int server1Id = cf2.getServerId();
+//      
+//      int server2Id = cf3.getServerId();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      try
+//      {      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+//         
+//         MessageProducer prod = sess.createProducer(queue1);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue1);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         sess.commit();
+//         
+//         conn.start();
+//         
+//         //Now consume half of the messages but don't commit them these will end up in 
+//         //client side resource manager
+//         
+//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(500);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         //So now, messages should be in queue1 on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.getServer(1).kill();
+//
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         //Now should be able to consume the rest of the messages
+//         
+//         log.info("here1");
+//         
+//         TextMessage tm = null;
+//         
+//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+//         {
+//            tm = (TextMessage)cons.receive(500);
+//                                    
+//            log.info("message is " + tm.getText());
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         log.info("here2");
+//         
+//         //Now should be able to commit them
+//         
+//         sess.commit();
+//         
+//         //Now check there are no more messages there
+//         sess.close();
+//         
+//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         cons = sess.createConsumer(queue1);
+//         
+//         Message m = cons.receive(500);
+//         
+//         assertNull(m);
+//         
+//         log.info("got to end of test");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
+   
+   
+   
+   
 //   public void testEvenSimplerFailover() throws Exception
 //   {
 //      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");

Deleted: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-12 09:11:39 UTC (rev 1769)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ManualClusteringTest.java	2006-12-12 10:49:42 UTC (rev 1770)
@@ -1,1025 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
-
-import javax.jms.Connection;
-import javax.jms.DeliveryMode;
-import javax.jms.Message;
-import javax.jms.MessageConsumer;
-import javax.jms.MessageListener;
-import javax.jms.MessageProducer;
-import javax.jms.Session;
-import javax.jms.TextMessage;
-
-import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
-
-/**
- * 
- * A ManualClusteringTest
- * 
- * Nodes must be started up in order node1, node2, node3
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-public class ManualClusteringTest extends ClusteringTestBase
-{
-
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public ManualClusteringTest(String name)
-   {
-      super(name);
-   }
-
-   // Public --------------------------------------------------------
-
-   public void testClusteredQueueLocalConsumerNonPersistent() throws Exception
-   {
-      clusteredQueueLocalConsumer(false);
-   }
-
-   public void testClusteredQueueLocalConsumerPersistent() throws Exception
-   {
-      clusteredQueueLocalConsumer(true);
-   }
-
-   public void testClusteredTopicNonDurableNonPersistent() throws Exception
-   {
-      clusteredTopicNonDurable(false);
-   }
-
-   public void testClusteredTopicNonDurablePersistent() throws Exception
-   {
-      clusteredTopicNonDurable(true);
-   }
-
-   public void testClusteredTopicNonDurableWithSelectorsNonPersistent() throws Exception
-   {
-      clusteredTopicNonDurableWithSelectors(false);
-   }
-
-   public void testClusteredTopicNonDurableWithSelectorsPersistent() throws Exception
-   {
-      clusteredTopicNonDurableWithSelectors(true);
-   }
-
-   public void testClusteredTopicDurableNonPersistent() throws Exception
-   {
-      clusteredTopicDurable(false);
-   }
-
-   public void testClusteredTopicDurablePersistent() throws Exception
-   {
-      clusteredTopicDurable(true);
-   }
-
-   public void testClusteredTopicSharedDurableLocalConsumerNonPersistent() throws Exception
-   {
-      clusteredTopicSharedDurableLocalConsumer(false);
-   }
-
-   public void testClusteredTopicSharedDurableLocalConsumerPersistent() throws Exception
-   {
-      clusteredTopicSharedDurableLocalConsumer(true);
-   }
-
-   public void testClusteredTopicSharedDurableNoLocalSubNonPersistent() throws Exception
-   {
-      clusteredTopicSharedDurableNoLocalSub(false);
-   }
-
-   public void testClusteredTopicSharedDurableNoLocalSubPersistent() throws Exception
-   {
-      clusteredTopicSharedDurableNoLocalSub(true);
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-   }
-
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-   }
-  
-
-   /*
-    * Create a consumer on each queue on each node.
-    * Send messages in turn from all nodes.
-    * Ensure that the local consumer gets the message
-    */
-   protected void clusteredQueueLocalConsumer(boolean persistent) throws Exception
-   {
-      Connection conn1 = null;
-      Connection conn2 = null;
-      Connection conn3 = null;
-
-      try
-      {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         log.info("Created connections");
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
-
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         log.info("Created sessions");
-
-         MessageConsumer cons1 = sess1.createConsumer(queue0);
-         MessageConsumer cons2 = sess2.createConsumer(queue1);
-         MessageConsumer cons3 = sess3.createConsumer(queue2);
-         
-         log.info("Created consumers");
-
-         conn1.start();
-         conn2.start();
-         conn3.start();
-
-         // Send at node 0
-
-         MessageProducer prod = sess1.createProducer(queue0);
-
-         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         final int NUM_MESSAGES = 100;
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess1.createTextMessage("message" + i);
-
-            prod.send(tm);
-         }
-         
-         log.info("Sent messages");
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
-            assertNotNull(tm);
-            
-            assertEquals("message" + i, tm.getText());
-         }                 
-
-         Message m = cons2.receive(2000);
-
-         assertNull(m);
-
-         m = cons3.receive(2000);
-
-         assertNull(m);
-
-         // Send at node 1
-
-         MessageProducer prod1 = sess2.createProducer(queue1);
-
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess2.createTextMessage("message" + i);
-
-            prod1.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         m = cons1.receive(2000);
-
-         assertNull(m);
-
-         m = cons3.receive(2000);
-
-         assertNull(m);
-
-         // Send at node 2
-
-         MessageProducer prod2 = sess3.createProducer(queue2);
-
-         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess3.createTextMessage("message" + i);
-
-            prod2.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         m = cons1.receive(2000);
-
-         assertNull(m);
-
-         m = cons2.receive(2000);
-
-         assertNull(m);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-      }
-   }
-
-   // Private -------------------------------------------------------
-
-   /*
-    * Create non durable subscriptions on all nodes of the cluster.
-    * Ensure all messages are receive as appropriate
-    */
-   private void clusteredTopicNonDurable(boolean persistent) throws Exception
-   {
-      Connection conn1 = null;
-      Connection conn2 = null;
-      Connection conn3 = null;
-      try
-      {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         log.info("Created connections");
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
-
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         MessageConsumer cons1 = sess1.createConsumer(topic0);
-         MessageConsumer cons2 = sess2.createConsumer(topic1);
-         MessageConsumer cons3 = sess3.createConsumer(topic2);
-
-         MessageConsumer cons4 = sess1.createConsumer(topic0);
-
-         MessageConsumer cons5 = sess2.createConsumer(topic1);
-
-         conn1.start();
-         conn2.start();
-         conn3.start();
-
-         // Send at node 0
-
-         MessageProducer prod = sess1.createProducer(topic0);
-
-         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         final int NUM_MESSAGES = 100;
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess1.createTextMessage("message" + i);
-
-            prod.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons5.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-      }
-   }
-
-   /*
-    * Create non durable subscriptions on all nodes of the cluster.
-    * Include some with selectors
-    * Ensure all messages are receive as appropriate
-    */
-   private void clusteredTopicNonDurableWithSelectors(boolean persistent) throws Exception
-   {
-      Connection conn1 = null;
-      Connection conn2 = null;
-      Connection conn3 = null;
-
-      try
-      {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         log.info("Created connections");
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
-
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         MessageConsumer cons1 = sess1.createConsumer(topic0);
-         MessageConsumer cons2 = sess2.createConsumer(topic1);
-         MessageConsumer cons3 = sess3.createConsumer(topic2);
-
-         MessageConsumer cons4 = sess1.createConsumer(topic0, "COLOUR='red'");
-
-         MessageConsumer cons5 = sess2.createConsumer(topic1, "COLOUR='blue'");
-
-         conn1.start();
-         conn2.start();
-         conn3.start();
-
-         // Send at node 0
-
-         MessageProducer prod = sess1.createProducer(topic0);
-
-         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         final int NUM_MESSAGES = 100;
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess1.createTextMessage("message" + i);
-
-            int c = i % 3;
-            if (c == 0)
-            {
-               tm.setStringProperty("COLOUR", "red");
-            }
-            else if (c == 1)
-            {
-               tm.setStringProperty("COLOUR", "blue");
-            }
-
-            prod.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            int c = i % 3;
-
-            if (c == 0)
-            {
-               TextMessage tm = (TextMessage)cons4.receive(1000);
-
-               assertNotNull(tm);
-
-               assertEquals("message" + i, tm.getText());
-            }
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            int c = i % 3;
-
-            if (c == 1)
-            {
-               TextMessage tm = (TextMessage)cons5.receive(1000);
-
-               assertNotNull(tm);
-
-               assertEquals("message" + i, tm.getText());
-            }
-         }
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-      }
-   }
-
-
-
-   /*
-    * Create durable subscriptions on all nodes of the cluster.
-    * Include a couple with selectors
-    * Ensure all messages are receive as appropriate
-    * None of the durable subs are shared
-    */
-   private void clusteredTopicDurable(boolean persistent) throws Exception
-   {
-      Connection conn1 = null;
-      Connection conn2 = null;
-      Connection conn3 = null;
-      try
-      {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         log.info("Created connections");
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
-
-         conn1.setClientID("wib1");
-         conn2.setClientID("wib1");
-         conn3.setClientID("wib1");
-
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         try
-         {
-            sess1.unsubscribe("sub");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess2.unsubscribe("sub1");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess3.unsubscribe("sub2");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess1.unsubscribe("sub3");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess2.unsubscribe("sub4");
-         }
-         catch (Exception ignore) {}
-
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub1");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub2");
-         MessageConsumer cons4 = sess1.createDurableSubscriber(topic0, "sub3");
-         MessageConsumer cons5 = sess2.createDurableSubscriber(topic1, "sub4");
-
-         conn1.start();
-         conn2.start();
-         conn3.start();
-
-         // Send at node 0
-
-         MessageProducer prod = sess1.createProducer(topic0);
-
-         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         final int NUM_MESSAGES = 100;
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess2.createTextMessage("message" + i);
-
-            prod.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons5.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         cons1.close();
-         cons2.close();
-         cons3.close();
-         cons4.close();
-         cons5.close();
-
-         sess1.unsubscribe("sub");
-         sess2.unsubscribe("sub1");
-         sess3.unsubscribe("sub2");
-         sess1.unsubscribe("sub3");
-         sess2.unsubscribe("sub4");
-
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-      }
-   }
-
-
-
-
-   /*
-    * Create shared durable subs on multiple nodes, the local instance should always get the message
-    */
-   protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
-   {
-      Connection conn1 = null;
-      Connection conn2 = null;
-      Connection conn3 = null;
-      try
-
-      {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         log.info("Created connections");
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
-         conn1.setClientID("wib1");
-         conn2.setClientID("wib1");
-         conn3.setClientID("wib1");
-
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         try
-         {
-            sess1.unsubscribe("sub");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess2.unsubscribe("sub");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess3.unsubscribe("sub");
-         }
-         catch (Exception ignore) {}
-
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub");
-
-         conn1.start();
-         conn2.start();
-         conn3.start();
-
-         // Send at node 0
-
-         MessageProducer prod = sess1.createProducer(topic0);
-
-         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         final int NUM_MESSAGES = 100;
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess1.createTextMessage("message" + i);
-
-            prod.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         Message m = cons2.receive(2000);
-
-         assertNull(m);
-
-         m = cons3.receive(2000);
-
-         assertNull(m);
-
-         // Send at node 1
-
-         MessageProducer prod1 = sess2.createProducer(topic1);
-
-         prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess3.createTextMessage("message" + i);
-
-            prod1.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         m = cons1.receive(2000);
-
-         assertNull(m);
-
-         m = cons3.receive(2000);
-
-         assertNull(m);
-
-         // Send at node 2
-
-         MessageProducer prod2 = sess3.createProducer(topic2);
-
-         prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess3.createTextMessage("message" + i);
-
-            prod2.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i, tm.getText());
-         }
-
-         m = cons1.receive(2000);
-
-         assertNull(m);
-
-         m = cons2.receive(2000);
-
-         assertNull(m);
-
-         cons1.close();
-         cons2.close();
-         cons3.close();
-
-         // Need to unsubscribe on any node that the durable sub was created on
-
-         sess1.unsubscribe("sub");
-         sess2.unsubscribe("sub");
-         sess3.unsubscribe("sub");
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-      }
-   }
-
-
-
-   /*
-    * Create shared durable subs on multiple nodes, but without sub on local node
-    * should round robin
-    * note that this test assumes round robin
-    */
-   protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
-   {
-      Connection conn1 = null;
-      Connection conn2 = null;
-      Connection conn3 = null;
-
-      try
-      {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
-         
-         log.info("Created connections");
-         
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
-         
-         conn2.setClientID("wib1");
-         conn3.setClientID("wib1");
-
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         try
-         {
-            sess2.unsubscribe("sub");
-         }
-         catch (Exception ignore) {}
-         try
-         {
-            sess3.unsubscribe("sub");
-         }
-         catch (Exception ignore) {}
-
-         MessageConsumer cons1 = sess2.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons2 = sess3.createDurableSubscriber(topic2, "sub");
-
-         conn2.start();
-         conn3.start();
-
-         // Send at node 0
-
-         //Should round robin between the other 2 since there is no active consumer on sub  on node 0
-
-         MessageProducer prod = sess1.createProducer(topic0);
-
-         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-
-         final int NUM_MESSAGES = 100;
-
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess1.createTextMessage("message" + i);
-
-            prod.send(tm);
-         }
-
-         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-         {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + i * 2, tm.getText());
-         }
-
-         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-         {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
-            assertNotNull(tm);
-
-            assertEquals("message" + (i * 2 + 1), tm.getText());
-         }
-
-         cons1.close();
-         cons2.close();
-
-         sess2.unsubscribe("sub");
-         sess3.unsubscribe("sub");
-
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-      }
-   }
-
-   class MyListener implements MessageListener
-   {
-      private int i;
-
-      MyListener(int i)
-      {
-         this.i = i;
-      }
-
-      public void onMessage(Message m)
-      {
-         try
-         {
-            int count = m.getIntProperty("count");
-
-            log.info("Listener " + i + " received message " + count);
-         }
-         catch (Exception e)
-         {
-            e.printStackTrace();
-         }
-      }
-
-   }
-
-
-   // Inner classes -------------------------------------------------
-
-   
-
-}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 05:50:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 05:50:27 -0500
Subject: [jboss-cvs] JBossAS SVN: r58992 - trunk/ejb3/src/main/org/jboss/ejb3
Message-ID: <E1Gu5DP-0001kS-5B@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 05:50:24 -0500 (Tue, 12 Dec 2006)
New Revision: 58992

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
Log:
EJBTHREE-805, consider an asynchronous rollback due to timeout

Modified: trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-12 10:49:08 UTC (rev 58991)
+++ trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-12 10:50:24 UTC (rev 58992)
@@ -1,24 +1,24 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.ejb3;
 
 import java.io.Externalizable;
@@ -271,7 +271,8 @@
    {
       // EJB1.1 11.6.1: Must throw IllegalStateException if BMT
       TransactionManagementType type = TxUtil.getTransactionManagementType(((Advisor) getContainer()));
-      if (type != TransactionManagementType.CONTAINER) throw new IllegalStateException("Container " + getContainer().getEjbName() + ": it is illegal to call getRollbackOnly from BMT: " + type);
+      if (type != TransactionManagementType.CONTAINER)
+         throw new IllegalStateException("Container " + getContainer().getEjbName() + ": it is illegal to call getRollbackOnly from BMT: " + type);
 
       try
       {
@@ -280,13 +281,17 @@
          // The getRollbackOnly and setRollBackOnly method of the SessionContext interface should be used
          // only in the session bean methods that execute in the context of a transaction.
          if (tm.getTransaction() == null)
-            throw new IllegalStateException("setRollbackOnly() not allowed without a transaction.");
+            throw new IllegalStateException("getRollbackOnly() not allowed without a transaction.");
 
-         return tm.getStatus() == Status.STATUS_MARKED_ROLLBACK;
+         // EJBTHREE-805, consider an asynchronous rollback due to timeout
+         int status = tm.getStatus();
+         return status == Status.STATUS_MARKED_ROLLBACK
+             || status == Status.STATUS_ROLLING_BACK
+             || status == Status.STATUS_ROLLEDBACK;
       }
       catch (SystemException e)
       {
-         log.warn("failed to set rollback only; ignoring", e);
+         log.warn("failed to get tx manager status; ignoring", e);
          return true;
       }
    }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 07:02:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 07:02:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r58993 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1Gu6Kz-0003GX-Ih@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-12 07:02:20 -0500 (Tue, 12 Dec 2006)
New Revision: 58993

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java
Log:
- Switch to the new deployer, for testing.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java	2006-12-12 10:50:24 UTC (rev 58992)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java	2006-12-12 12:02:20 UTC (rev 58993)
@@ -722,7 +722,7 @@
    public AbstractWarDeployment getDeployment(DeploymentUnit unit, WebMetaData metaData)
       throws Exception
    {
-      TomcatDeployment deployment = new TomcatDeployment();
+      TomcatDeployment2 deployment = new TomcatDeployment2();
       DeployerConfig config = new DeployerConfig();
       config.setDefaultSecurityDomain(this.defaultSecurityDomain);
       config.setSubjectAttributeName(this.subjectAttributeName);



From thomas.diesler at jboss.com  Tue Dec 12 07:34:03 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Tue, 12 Dec 2006 07:34:03 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1Gu6pf-0003mW-45@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/12 07:34:03

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  URL: https://svn.jboss.org/repos/jbossws/trunk
  Repository Root: https://svn.jboss.org/repos/jbossws
  Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
  Revision: 1630
  Node Kind: directory
  Schedule: normal
  Last Changed Author: thomas.diesler at jboss.com
  Last Changed Rev: 1630
  Last Changed Date: 2006-12-12 13:23:36 +0100 (Tue, 12 Dec 2006)
  
  Revision  Changes    Path
  1.36      +0 -2      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -b -r1.35 -r1.36
  --- component-info.xml	12 Dec 2006 07:41:44 -0000	1.35
  +++ component-info.xml	12 Dec 2006 12:34:03 -0000	1.36
  @@ -6,7 +6,6 @@
                 description="JBossWS an implementation of J2EE Web Services">
   
         <artifact id="jbossws.sar"/>
  -      <artifact id="jbossws.deployer"/>
         <artifact id="jbossws-client.jar"/>
         <artifact id="jboss-jaxrpc.jar"/>
         <artifact id="jboss-jaxws.jar"/>
  @@ -33,7 +32,6 @@
   
         <export>
            <include input="jbossws.sar"/>
  -         <include input="jbossws.deployer"/>
            <include input="jbossws-client.jar"/>
            <include input="jboss-jaxrpc.jar"/>
            <include input="jboss-jaxws.jar"/>
  
  
  


From thomas.diesler at jboss.com  Tue Dec 12 07:34:07 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Tue, 12 Dec 2006 07:34:07 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1Gu6pj-0003mq-7d@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/12 07:34:07

  Modified:    jboss/jbossws/snapshot/lib          jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws-jboss-integration.jar
                        jbossws-tomcat-integration.jar jbossws.deployer
                        jbossws.sar
  Removed:     jboss/jbossws/snapshot/lib          jbossws-src.zip
  Log:
  URL: https://svn.jboss.org/repos/jbossws/trunk
  Repository Root: https://svn.jboss.org/repos/jbossws
  Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
  Revision: 1630
  Node Kind: directory
  Schedule: normal
  Last Changed Author: thomas.diesler at jboss.com
  Last Changed Rev: 1630
  Last Changed Date: 2006-12-12 13:23:36 +0100 (Tue, 12 Dec 2006)
  
  Revision  Changes    Path
  1.30      +125 -125  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.29      +224 -224  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.30      +72 -72    repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.41      +2154 -2131repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.3       +70 -70    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar
  
  	<<Binary file>>
  
  
  1.3       +39 -39    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar
  
  	<<Binary file>>
  
  
  1.2       +4226 -4181repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.deployer
  
  	<<Binary file>>
  
  
  1.41      +36 -34    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  


From thomas.diesler at jboss.com  Tue Dec 12 07:52:18 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Tue, 12 Dec 2006 07:52:18 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot  ...
Message-ID: <E1Gu77K-00044q-UK@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/12 07:52:18

  Modified:    jboss/jbossws/snapshot  component-info.xml
  Log:
  add jbossws.deployer
  
  Revision  Changes    Path
  1.37      +1 -0      repository.jboss.com/jboss/jbossws/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/snapshot/component-info.xml,v
  retrieving revision 1.36
  retrieving revision 1.37
  diff -u -b -r1.36 -r1.37
  --- component-info.xml	12 Dec 2006 12:34:03 -0000	1.36
  +++ component-info.xml	12 Dec 2006 12:52:18 -0000	1.37
  @@ -6,6 +6,7 @@
                 description="JBossWS an implementation of J2EE Web Services">
   
         <artifact id="jbossws.sar"/>
  +      <artifact id="jbossws.deployer"/>
         <artifact id="jbossws-client.jar"/>
         <artifact id="jboss-jaxrpc.jar"/>
         <artifact id="jboss-jaxws.jar"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 07:54:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 07:54:20 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58994 - trunk/build
Message-ID: <E1Gu79I-00045R-Ty@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-12 07:54:18 -0500 (Tue, 12 Dec 2006)
New Revision: 58994

Modified:
   trunk/build/build-distr.xml
Log:
Install jbossws.deployer

Modified: trunk/build/build-distr.xml
===================================================================
--- trunk/build/build-distr.xml	2006-12-12 12:02:20 UTC (rev 58993)
+++ trunk/build/build-distr.xml	2006-12-12 12:54:18 UTC (rev 58994)
@@ -4,196 +4,187 @@
 ]>
 
 <project name="JBoss/Build">
-
+  
   &libraries;
-
-
+  
   <!-- ================================================================== -->
   <!-- Module Pass-through Hooks                                          -->
   <!-- ================================================================== -->
-
+  
   <!--
-     | These hooks are executed after the above pass-through targets have
-     | finished with a given module.
-   -->
-
-   <!-- ======== -->
-   <!-- Test     -->
-   <!-- ======== -->
-
-   <target name="_module-test-most">
-     <property name="_module.name" value="test" override="true"/>
-     <property name="_module.output" override="true"
-           value="${project.root}/${_module.name}/output"/>
-   </target>
-
-   <target name="_module-test-all" depends="_module-test-most">
-     <!-- Copy the generated javadocs -->
-     <mkdir dir="${install.api}/${_module.name}"/>
-     <copy todir="${install.api}/${_module.name}" filtering="no">
-       <fileset dir="${_module.output}/api">
-          <include name="**/*"/>
-       </fileset>
-     </copy>
-
-   </target>
-
+  | These hooks are executed after the above pass-through targets have
+  | finished with a given module.
+  -->
+  
   <!-- ======== -->
+  <!-- Test     -->
+  <!-- ======== -->
+  
+  <target name="_module-test-most">
+    <property name="_module.name" value="test" override="true"/>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+  </target>
+  
+  <target name="_module-test-all" depends="_module-test-most">
+    <!-- Copy the generated javadocs -->
+    <mkdir dir="${install.api}/${_module.name}"/>
+    <copy todir="${install.api}/${_module.name}" filtering="no">
+      <fileset dir="${_module.output}/api">
+        <include name="**/*"/>
+      </fileset>
+    </copy>
+    
+  </target>
+  
+  <!-- ======== -->
   <!-- Remoting -->
   <!-- ======== -->
-
+  
   <target name="_module-jbossas/remoting-most">
     <property name="_module.name" value="remoting" override="true"/>
-    <property name="_module.output" override="true"
-          value="${project.root}/jbossas/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/jbossas/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jbossas-remoting.jar"/>
+        <include name="jbossas-remoting.jar"/>
       </fileset>
     </copy>
-
-     <!-- Copy the third party libraries -->
-     <mkdir dir="${install.all.lib}"/>
-     <copy todir="${install.all.lib}" filtering="no">
-        <fileset dir="${jboss.remoting.lib}">
-          <include name="jboss-remoting.jar"/>
-        </fileset>
-     </copy>
-     <copy todir="${install.all.lib}" filtering="no">
-        <fileset dir="${jboss.serialization.lib}">
-          <include name="jboss-serialization.jar"/>
-        </fileset>
-     </copy>
-     <copy todir="${install.all.lib}" filtering="no">
-        <fileset dir="${apache.httpclient.lib}">
-          <include name="commons-httpclient.jar"/>
-        </fileset>
-     </copy>
+    
+    <!-- Copy the third party libraries -->
+    <mkdir dir="${install.all.lib}"/>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${jboss.remoting.lib}">
+        <include name="jboss-remoting.jar"/>
+      </fileset>
+    </copy>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${jboss.serialization.lib}">
+        <include name="jboss-serialization.jar"/>
+      </fileset>
+    </copy>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${apache.httpclient.lib}">
+        <include name="commons-httpclient.jar"/>
+      </fileset>
+    </copy>
   </target>
-
+  
   <target name="_module-remoting-all" depends="_module-jbossas/remoting-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
+    
   </target>
-
+  
   <!-- ============ -->
   <!-- JMX Remoting -->
   <!-- ============ -->
-
-   <target name="_module-jmx-remoting-most">
-      <property name="_module.name" value="jmx-remoting" override="true"/>
-      <property name="_module.output" override="true"
-         value="${project.root}/${_module.name}/output"/>
-
-      <!-- Copy the generated libraries -->
-      <mkdir dir="${install.all.lib}"/>
-      <copy todir="${install.all.lib}" filtering="no">
-         <fileset dir="${_module.output}/lib">
-            <include name="jboss-jmx-remoting.jar"/>
-         </fileset>
-      </copy>
-   </target>
-
-   <target name="_module-jmx-remoting-all" depends="_module-jmx-remoting-most">
-      <!-- Copy the generated javadocs -->
-      <mkdir dir="${install.api}/${_module.name}"/>
-      <copy todir="${install.api}/${_module.name}" filtering="no">
-         <fileset dir="${_module.output}/api">
-            <include name="**/*"/>
-         </fileset>
-      </copy>
-
-   </target>
-
-   <target name="_module-jbossas/jmx-remoting-all" depends="_module-jbossas/jmx-remoting-most">
-      <!-- Copy the generated javadocs -->
-      <mkdir dir="${install.api}/${_module.name}"/>
-      <copy todir="${install.api}/${_module.name}" filtering="no">
-         <fileset dir="${_module.output}/api">
-            <include name="**/*"/>
-         </fileset>
-      </copy>
-
-   </target>
-
-   <target name="_module-jbossas/jmx-remoting-most">
-      <property name="_module.name" value="jbossas/jmx-remoting" override="true"/>
-      <property name="_module.output" override="true"
-         value="${project.root}/${_module.name}/output"/>
-
-      <unjar src="${project.root}/${_module.name}/output/lib/jmx-remoting.sar"
-         dest="${install.default}/deploy/jmx-remoting.sar"/>
-      <unjar src="${project.root}/${_module.name}/output/lib/jmx-remoting.sar"
-         dest="${install.all}/deploy/jmx-remoting.sar"/>
-
-
-   </target>
-
-   <!-- ======== -->
-   <!-- EJB3X  -->
-   <!-- ======== -->
-
-   <target name="_module-ejb3x-most">
-     <property name="_module.name" value="ejb3x" override="true"/>
-     <property name="_module.output" override="true"
-           value="${project.root}/${_module.name}/output"/>
-
-   <!-- Copy across client jars -->
+  
+  <target name="_module-jmx-remoting-most">
+    <property name="_module.name" value="jmx-remoting" override="true"/>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <!-- Copy the generated libraries -->
+    <mkdir dir="${install.all.lib}"/>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${_module.output}/lib">
+        <include name="jboss-jmx-remoting.jar"/>
+      </fileset>
+    </copy>
+  </target>
+  
+  <target name="_module-jmx-remoting-all" depends="_module-jmx-remoting-most">
+    <!-- Copy the generated javadocs -->
+    <mkdir dir="${install.api}/${_module.name}"/>
+    <copy todir="${install.api}/${_module.name}" filtering="no">
+      <fileset dir="${_module.output}/api">
+        <include name="**/*"/>
+      </fileset>
+    </copy>
+    
+  </target>
+  
+  <target name="_module-jbossas/jmx-remoting-all" depends="_module-jbossas/jmx-remoting-most">
+    <!-- Copy the generated javadocs -->
+    <mkdir dir="${install.api}/${_module.name}"/>
+    <copy todir="${install.api}/${_module.name}" filtering="no">
+      <fileset dir="${_module.output}/api">
+        <include name="**/*"/>
+      </fileset>
+    </copy>
+    
+  </target>
+  
+  <target name="_module-jbossas/jmx-remoting-most">
+    <property name="_module.name" value="jbossas/jmx-remoting" override="true"/>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <unjar src="${project.root}/${_module.name}/output/lib/jmx-remoting.sar" dest="${install.default}/deploy/jmx-remoting.sar"/>
+    <unjar src="${project.root}/${_module.name}/output/lib/jmx-remoting.sar" dest="${install.all}/deploy/jmx-remoting.sar"/>
+    
+  </target>
+  
+  <!-- ======== -->
+  <!-- EJB3X  -->
+  <!-- ======== -->
+  
+  <target name="_module-ejb3x-most">
+    <property name="_module.name" value="ejb3x" override="true"/>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <!-- Copy across client jars -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
         <include name="jboss-ejb3x.jar"/>
       </fileset>
     </copy>
-
+    
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${hibernate.entitymanager.lib}" includes="*.jar" />
-      <fileset dir="${hibernate.annotations.lib}" includes="*.jar" />
+      <fileset dir="${hibernate.entitymanager.lib}" includes="*.jar"/>
+      <fileset dir="${hibernate.annotations.lib}" includes="*.jar"/>
     </copy>
-
-   </target>
-
-   <!-- ======== -->
-   <!-- EJB 3.0 -->
-   <!-- ======== -->
-
-   <target name="_module-ejb3-most">
-     <property name="_module.name" value="ejb3" override="true"/>
-     <property name="_module.output" override="true"
-           value="${project.root}/${_module.name}/output"/>
-
-      <copy todir="${install.server}/all/deploy" filtering="no">
-        <fileset dir="${_module.output}/lib">
-           <include name="ejb3-interceptors-aop.xml"/>
-           <include name="ejb3-entity-cache-beans.xml"/>
-           <include name="ejb3-clustered-sfsbcache-beans.xml"/>
-           <include name="ejb3-timer-service.xml"/>
-           <include name="ejb3-connectors-service.xml"/>
-        </fileset>
-      </copy>
-
-      <copy todir="${install.server}/all/deployers" filtering="no">
-        <fileset dir="${_module.output}/lib">
-           <include name="ejb3.deployer/**"/>
-        </fileset>
-      </copy>
-   <!-- Copy the third party libraries -->
-   <copy todir="${install.all.lib}" filtering="no">
-     <fileset dir="${hibernate.entitymanager.lib}">
-       <include name="ejb3-persistence.jar"/>
-     </fileset>
-   </copy>
-
-   <!-- Copy across client jars -->
+    
+  </target>
+  
+  <!-- ======== -->
+  <!-- EJB 3.0 -->
+  <!-- ======== -->
+  
+  <target name="_module-ejb3-most">
+    <property name="_module.name" value="ejb3" override="true"/>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <copy todir="${install.server}/all/deploy" filtering="no">
+      <fileset dir="${_module.output}/lib">
+        <include name="ejb3-interceptors-aop.xml"/>
+        <include name="ejb3-entity-cache-beans.xml"/>
+        <include name="ejb3-clustered-sfsbcache-beans.xml"/>
+        <include name="ejb3-timer-service.xml"/>
+        <include name="ejb3-connectors-service.xml"/>
+      </fileset>
+    </copy>
+    
+    <copy todir="${install.server}/all/deployers" filtering="no">
+      <fileset dir="${_module.output}/lib">
+        <include name="ejb3.deployer/**"/>
+      </fileset>
+    </copy>
+    
+    <!-- Copy the third party libraries -->
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${hibernate.entitymanager.lib}">
+        <include name="ejb3-persistence.jar"/>
+      </fileset>
+    </copy>
+    
+    <!-- Copy across client jars -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
@@ -212,57 +203,55 @@
         <include name="jboss-aop-jdk50-client.jar"/>
       </fileset>
     </copy>
-   </target>
-
-   <target name="_module-ejb3-all" depends="_module-ejb3-most">
-     <!-- Copy the generated javadocs -->
-     <mkdir dir="${install.api}/${_module.name}"/>
-     <copy todir="${install.api}/${_module.name}" filtering="no">
-       <fileset dir="${_module.output}/api">
-          <include name="**/*"/>
-       </fileset>
-     </copy>
-
-   </target>
-
+  </target>
+  
+  <target name="_module-ejb3-all" depends="_module-ejb3-most">
+    <!-- Copy the generated javadocs -->
+    <mkdir dir="${install.api}/${_module.name}"/>
+    <copy todir="${install.api}/${_module.name}" filtering="no">
+      <fileset dir="${_module.output}/api">
+        <include name="**/*"/>
+      </fileset>
+    </copy>
+    
+  </target>
+  
   <!-- ======== -->
   <!-- ASPECTS -->
   <!-- ======== -->
-
+  
   <target name="_module-aspects-most">
     <property name="_module.name" value="aspects" override="true"/>
-    <property name="_module.output" override="true"
-          value="${project.root}/${_module.name}/output"/>
-
-     <!--
-     <condition property="aop.deployer" value="jboss-aop-jdk50.deployer">
-        <isset property="HAVE_JDK_1.5"/>
-     </condition>
-
-      <condition property="aop.deployer" value="jboss-aop.deployer">
-         <not>
-            <isset property="HAVE_JDK_1.5"/>
-         </not>
-      </condition>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <!--
+    <condition property="aop.deployer" value="jboss-aop-jdk50.deployer">
+    <isset property="HAVE_JDK_1.5"/>
+    </condition>
+    
+    <condition property="aop.deployer" value="jboss-aop.deployer">
+    <not>
+    <isset property="HAVE_JDK_1.5"/>
+    </not>
+    </condition>
     -->
-	<property name="aop.deployer" value="jboss-aop-jboss5.deployer"/>    
+    <property name="aop.deployer" value="jboss-aop-jboss5.deployer"/>
     <!-- Copy the generated libraries -->
-    <unjar src="${_module.output}/lib/${aop.deployer}"
-       dest="${install.server}/all/deployers/${aop.deployer}" />
-
+    <unjar src="${_module.output}/lib/${aop.deployer}" dest="${install.server}/all/deployers/${aop.deployer}"/>
+    
     <copy todir="${install.server}/all/deployers" filtering="no">
       <fileset dir="${project.root}/${_module.name}/src/resources/META-INF">
         <include name="aop-mc-int-aspect-beans.xml"/>
       </fileset>
     </copy>
-
+    
     <copy todir="${install.server}/all/deployers/${aop.deployer}" filtering="no">
       <fileset dir="${jboss.microcontainer.lib}">
         <include name="jboss-aop-mc-int-deployer.jar"/>
       </fileset>
-   </copy>
-   
-   <!-- Copy across client jars -->
+    </copy>
+    
+    <!-- Copy across client jars -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
@@ -270,27 +259,26 @@
       </fileset>
     </copy>
   </target>
-
+  
   <target name="_module-aspects-all" depends="_module-aspects-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
+    
   </target>
-
+  
   <!-- ==== -->
   <!-- J2EE -->
   <!-- ==== -->
-
+  
   <target name="_module-j2ee-most">
     <property name="_module.name" value="j2ee" override="true"/>
-    <property name="_module.output" override="true"
-      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
@@ -298,7 +286,7 @@
         <include name="jboss-j2ee.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
@@ -313,26 +301,25 @@
       </fileset>
     </copy>
   </target>
-
+  
   <target name="_module-j2ee-all" depends="_module-j2ee-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ====== -->
   <!-- System -->
   <!-- ====== -->
-
+  
   <target name="_module-system-most">
     <property name="_module.name" value="system" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.lib}"/>
     <copy todir="${install.lib}" filtering="no">
@@ -341,7 +328,7 @@
         <include name="jboss-system.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
@@ -349,23 +336,23 @@
         <include name="*-client.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated scripts & runnable jars -->
     <mkdir dir="${install.bin}"/>
     <copy todir="${install.bin}" filtering="no">
       <fileset dir="${_module.output}/bin">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
       <fileset dir="${_module.output}/lib">
-         <include name="run.jar"/>
+        <include name="run.jar"/>
       </fileset>
     </copy>
     <chmod perm="+x">
       <fileset dir="${install.bin}">
-         <include name="**/*.sh"/>
+        <include name="**/*.sh"/>
       </fileset>
     </chmod>
-
+    
     <!-- Copy thirdparty code -->
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${gnu.getopt.lib}">
@@ -377,10 +364,9 @@
         <include name="log4j.jar"/>
       </fileset>
     </copy>
-    <copy file="${apache.log4j.lib}/snmpTrapAppender.jar"
-        tofile="${install.all.lib}/log4j-snmp-appender.jar">
+    <copy file="${apache.log4j.lib}/snmpTrapAppender.jar" tofile="${install.all.lib}/log4j-snmp-appender.jar">
     </copy>
-
+    
     <!-- Copy thirdparty client code -->
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${apache.log4j.lib}">
@@ -390,29 +376,28 @@
         <include name="getopt.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the DTDs -->
     <mkdir dir="${install.dtd}"/>
     <copy todir="${install.dtd}" filtering="no">
-      <fileset dir="${project.root}/${_module.name}/src/resources/dtd" />
+      <fileset dir="${project.root}/${_module.name}/src/resources/dtd"/>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-system-all" depends="_module-system-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
   <target name="_module-system-jmx-most">
     <property name="_module.name" value="system-jmx" override="true"/>
-    <property name="_module.output" override="true"
-      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
         <include name="jboss-system-jmx.jar"/>
@@ -420,59 +405,57 @@
     </copy>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-system-jmx-client.jar"/>
+        <include name="jboss-system-jmx-client.jar"/>
       </fileset>
     </copy>
   </target>
   <target name="_module-system-jmx-all" depends="_module-system-jmx-most">
   </target>
-
+  
   <!-- ====== -->
   <!-- Naming -->
   <!-- ====== -->
-
+  
   <target name="_module-naming-most">
     <property name="_module.name" value="naming" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jnpserver.jar"/>
+        <include name="jnpserver.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jnp-client.jar"/>
+        <include name="jnp-client.jar"/>
       </fileset>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-naming-all" depends="_module-naming-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ====== -->
   <!-- Server -->
   <!-- ====== -->
-
+  
   <target name="_module-server-most">
     <property name="_module.name" value="server" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
@@ -482,32 +465,32 @@
         <include name="jmx-adaptor-plugin.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="*-client.jar"/>
+        <include name="*-client.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated scripts & runnable jars -->
     <mkdir dir="${install.bin}"/>
     <copy todir="${install.bin}" filtering="no">
       <fileset dir="${_module.output}/bin">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
       <fileset dir="${_module.output}/lib">
-         <include name="deployer.jar"/>
-         <include name="shutdown.jar"/>
+        <include name="deployer.jar"/>
+        <include name="shutdown.jar"/>
       </fileset>
     </copy>
     <chmod perm="+x">
       <fileset dir="${install.bin}">
-         <include name="**/*.sh"/>
+        <include name="**/*.sh"/>
       </fileset>
     </chmod>
-
+    
     <!-- Copy thirdparty code -->
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${oswego.concurrent.lib}">
@@ -522,126 +505,124 @@
         <include name="bcel.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty client code -->
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${oswego.concurrent.lib}">
         <include name="concurrent.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Default server config -->
-
+    
     <mkdir dir="${install.server}/all/deploy"/>
     <copy todir="${install.server}/all/deploy" filtering="no">
       <!-- Deployable xml snipets -->
       <fileset dir="${_module.output}/etc/deploy">
-         <include name="**"/>
+        <include name="**"/>
       </fileset>
-
+      
       <!-- Deployable archives -->
       <fileset dir="${_module.output}/lib">
-         <include name="uuid-key-generator.sar/**"/>
-         <include name="sqlexception-service.xml"/>
-         <include name="client-deployer-service.xml"/>
+        <include name="uuid-key-generator.sar/**"/>
+        <include name="sqlexception-service.xml"/>
+        <include name="client-deployer-service.xml"/>
       </fileset>
     </copy>
-	  
-	<!-- Copy the deployers -->  
+    
+    <!-- Copy the deployers -->
     <copy todir="${install.server}/all/deployers" filtering="no">
-       <fileset dir="${_module.output}/etc/deployers">
-         <include name="**"/>
+      <fileset dir="${_module.output}/etc/deployers">
+        <include name="**"/>
       </fileset>
     </copy>
-	  
-    <copy file="${_module.output}/resources/jmx-invoker-adaptor/META-INF/jboss-service.xml"
-          tofile="${install.all.deploy}/jmx-invoker-service.xml"/>
-
+    
+    <copy file="${_module.output}/resources/jmx-invoker-adaptor/META-INF/jboss-service.xml" tofile="${install.all.deploy}/jmx-invoker-service.xml"/>
+    
     <!-- Copy the default configuration files -->
     <mkdir dir="${install.server}/all/conf"/>
     <copy todir="${install.server}/all/conf" filtering="no">
       <fileset dir="${_module.output}/etc/conf/default">
-         <include name="**"/>
+        <include name="**"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the DTDs -->
     <mkdir dir="${install.dtd}"/>
     <copy todir="${install.dtd}" filtering="no">
-      <fileset dir="${project.root}/${_module.name}/src/resources/dtd" />
+      <fileset dir="${project.root}/${_module.name}/src/resources/dtd"/>
     </copy>
-
+    
     <!-- Copy the XML Schemas -->
     <mkdir dir="${install.schema}"/>
     <copy todir="${install.schema}" filtering="no">
-      <fileset dir="${project.root}/${_module.name}/src/resources/schema" />
+      <fileset dir="${project.root}/${_module.name}/src/resources/schema"/>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-server-all" depends="_module-server-most">
-
+    
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ========= -->
   <!-- Connector -->
   <!-- ========= -->
-
+  
   <target name="_module-connector-most">
     <property name="_module.name" value="connector" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <mkdir dir="${install.server}/all/deployers"/>
     <copy todir="${install.server}/all/deployers" filtering="no">
       <fileset dir="${_module.output}/resources/deployers">
-         <include name="jca-deployers-beans.xml"/>
+        <include name="jca-deployers-beans.xml"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated deployment libraries -->
     <mkdir dir="${install.server}/all/deploy"/>
     <copy todir="${install.server}/all/deploy" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="*.rar"/>
-         <exclude name="jms-ra.rar"/>
+        <include name="*.rar"/>
+        <exclude name="jms-ra.rar"/>
       </fileset>
       <fileset dir="${_module.output}/resources/jca-sar">
-         <include name="jbossjca-service.xml"/>
+        <include name="jbossjca-service.xml"/>
       </fileset>
     </copy>
     <copy todir="${install.all.deploy}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jms-ra.rar"/>
+        <include name="jms-ra.rar"/>
       </fileset>
     </copy>
-
+    
     <mkdir dir="${install.server}/all/lib"/>
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-common-jdbc-wrapper.jar"/>
-         <include name="jboss-jca.jar"/>
+        <include name="jboss-common-jdbc-wrapper.jar"/>
+        <include name="jboss-jca.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the dtds -->
-     <mkdir dir="${install.dtd}"/>
-     <copy todir="${install.dtd}" filtering="no">
-       <fileset dir="${project.root}/${_module.name}/output/resources/dtd" />
-     </copy>
-
+    <mkdir dir="${install.dtd}"/>
+    <copy todir="${install.dtd}" filtering="no">
+      <fileset dir="${project.root}/${_module.name}/output/resources/dtd"/>
+    </copy>
+    
     <!-- Copy example db configs -->
     <mkdir dir="${install.examples.jca}"/>
     <copy todir="${install.examples.jca}" filtering="no">
       <fileset dir="${_module.output}/etc/example-config">
-         <include name="*.xml"/>
+        <include name="*.xml"/>
       </fileset>
       <fileset dir="${_module.output}/lib">
         <include name="jboss-ha-local-jdbc.rar"/>
@@ -650,428 +631,416 @@
     </copy>
     <copy todir="${install.server}/all/deploy" filtering="no">
       <fileset dir="${_module.output}/etc/example-config">
-         <!--include name="firebird-service.xml"/-->
-         <include name="hsqldb-ds.xml"/>
-         <!--include name="mysql-service.xml"/-->
-         <!--include name="oracle-service.xml"/-->
-         <!--include name="postgres-service.xml"/-->
+        <!--include name="firebird-service.xml"/-->
+        <include name="hsqldb-ds.xml"/>
+        <!--include name="mysql-service.xml"/-->
+        <!--include name="oracle-service.xml"/-->
+        <!--include name="postgres-service.xml"/-->
       </fileset>
     </copy>
-
+    
     <!--
     <mkdir dir="${install.all.deploy}/jms"/>
     <copy todir="${install.all.deploy}/jms" filtering="no">
-      <fileset dir="${_module.output}/etc/example-config">
-         <include name="hajndi-jms-ds.xml"/>
-      </fileset>
+    <fileset dir="${_module.output}/etc/example-config">
+    <include name="hajndi-jms-ds.xml"/>
+    </fileset>
     </copy>
     -->
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jbosscx-client.jar"/>
+        <include name="jbosscx-client.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- QUARTZ jar -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${quartz.quartz.lib}" includes="*.jar"/>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-connector-all" depends="_module-connector-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
+    
     <!--Copy generated jmx documentation -->
     <mkdir dir="${install.jmx-api}"/>
     <copy todir="${install.jmx-api}" filtering="no" failonerror="false">
       <fileset dir="${_module.output}/jmx-api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ========= -->
   <!-- Legacy JBossMQ -->
   <!-- ========= -->
-
+  
   <target name="_module-jbossmq-most">
     <property name="_module.name" value="jbossmq" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy example jms configs -->
     <mkdir dir="${install.examples.jms}"/>
     <copy todir="${install.examples.jms}" filtering="no">
       <fileset dir="${_module.output}/etc/server/examples/deploy">
-         <include name="*.xml"/>
-         <include name="conf/*.xml"/>
-         <include name="standalone/*.xml"/>
+        <include name="*.xml"/>
+        <include name="conf/*.xml"/>
+        <include name="standalone/*.xml"/>
       </fileset>
     </copy>
     <!-- TODO: include legacy deploy contents as an example -->
   </target>
   <target name="_module-jbossmq-all" depends="_module-jbossmq-most">
   </target>
-
-
+  
   <!-- ========= -->
   <!-- Messaging -->
   <!-- ========= -->
-
-   <target name="_module-messaging-most">
-      <property name="_module.name" value="messaging" override="true"/>
-      <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
-
-      <!-- Copy the jboss-messaging libraries -->
-      <mkdir dir="${install.all.lib}"/>
-      <copy todir="${install.all.lib}" filtering="no">
-         <fileset dir="${jboss.messaging.lib}">
-            <include name="jboss-messaging.jar"/>
-         </fileset>
-         <fileset dir="${_module.output}/lib">
-            <include name="jboss-messaging-int.jar"/>
-         </fileset>
-      </copy>
-
-      <!-- messaging descriptors, unscoped deployment -->
-      <mkdir dir="${install.all.deploy}/messaging"/>
-      <copy todir="${install.all.deploy}/messaging">
-         <fileset dir="${_module.output}/etc/deploy/">
-            <include name="*-service.xml"/>
-         </fileset>
-      </copy>
-
-      <!-- security metadata -->
-      <mkdir dir="${install.all.conf}/props"/>
-      <copy todir="${install.all.conf}/props">
-         <fileset dir="${_module.output}/etc/deploy/">
-            <include name="messaging-*.properties"/>
-         </fileset>
-      </copy>
-
-      <!-- the JCA connection factory -->
-      <copy todir="${install.all.deploy}" file="${_module.output}/etc/deploy/jms-ds.xml"/>
-
-      <!-- Copy the generated client libraries -->
-      <mkdir dir="${install.client}"/>
-      <copy todir="${install.client}" file="${jboss.messaging.lib}/jboss-messaging.jar" filtering="no"/>
-   </target>
-
-   <target name="_module-messaging-all" depends="_module-messaging-most">
-
-      <!-- Copy the generated javadocs -->
-      <mkdir dir="${install.api}/${_module.name}"/>
-      <copy todir="${install.api}/${_module.name}" filtering="no">
-         <fileset dir="${_module.output}/api">
-            <include name="**/*"/>
-         </fileset>
-      </copy>
-   </target>
-
+  
+  <target name="_module-messaging-most">
+    <property name="_module.name" value="messaging" override="true"/>
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <!-- Copy the jboss-messaging libraries -->
+    <mkdir dir="${install.all.lib}"/>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${jboss.messaging.lib}">
+        <include name="jboss-messaging.jar"/>
+      </fileset>
+      <fileset dir="${_module.output}/lib">
+        <include name="jboss-messaging-int.jar"/>
+      </fileset>
+    </copy>
+    
+    <!-- messaging descriptors, unscoped deployment -->
+    <mkdir dir="${install.all.deploy}/messaging"/>
+    <copy todir="${install.all.deploy}/messaging">
+      <fileset dir="${_module.output}/etc/deploy/">
+        <include name="*-service.xml"/>
+      </fileset>
+    </copy>
+    
+    <!-- security metadata -->
+    <mkdir dir="${install.all.conf}/props"/>
+    <copy todir="${install.all.conf}/props">
+      <fileset dir="${_module.output}/etc/deploy/">
+        <include name="messaging-*.properties"/>
+      </fileset>
+    </copy>
+    
+    <!-- the JCA connection factory -->
+    <copy todir="${install.all.deploy}" file="${_module.output}/etc/deploy/jms-ds.xml"/>
+    
+    <!-- Copy the generated client libraries -->
+    <mkdir dir="${install.client}"/>
+    <copy todir="${install.client}" file="${jboss.messaging.lib}/jboss-messaging.jar" filtering="no"/>
+  </target>
+  
+  <target name="_module-messaging-all" depends="_module-messaging-most">
+    
+    <!-- Copy the generated javadocs -->
+    <mkdir dir="${install.api}/${_module.name}"/>
+    <copy todir="${install.api}/${_module.name}" filtering="no">
+      <fileset dir="${_module.output}/api">
+        <include name="**/*"/>
+      </fileset>
+    </copy>
+  </target>
+  
   <!-- ==== -->
   <!-- J2SE -->
   <!-- ==== -->
-
+  
   <target name="_module-j2se-most">
     <property name="_module.name" value="j2se" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.lib}"/>
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-j2se.jar"/>
+        <include name="jboss-j2se.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
-    <copy tofile="${install.client}/jboss-j2se.jar"
-          file="${_module.output}/lib/jboss-j2se.jar"/>
-
+    <copy tofile="${install.client}/jboss-j2se.jar" file="${_module.output}/lib/jboss-j2se.jar"/>
+    
   </target>
-
+  
   <target name="_module-j2se-all" depends="_module-j2se-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
- </target>
-
+    
+  </target>
+  
   <!-- ====== -->
   <!-- MBeans -->
   <!-- ====== -->
-
+  
   <target name="_module-mbeans-most">
     <property name="_module.name" value="mbeans" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.lib}"/>
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-mbeans.jar"/>
+        <include name="jboss-mbeans.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the DTDs -->
     <mkdir dir="${install.dtd}"/>
     <copy todir="${install.dtd}" filtering="no">
-      <fileset dir="${project.root}/${_module.name}/src/resources/dtd" />
+      <fileset dir="${project.root}/${_module.name}/src/resources/dtd"/>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-mbeans-all" depends="_module-mbeans-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
- </target>
-
+    
+  </target>
+  
   <!-- === -->
   <!-- JMX -->
   <!-- === -->
-
+  
   <target name="_module-jmx-most">
     <property name="_module.name" value="jmx" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.lib}"/>
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-jmx.jar"/>
+        <include name="jboss-jmx.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty code -->
     <copy todir="${install.lib}" filtering="no">
       <fileset dir="${oswego.concurrent.lib}">
         <include name="concurrent.jar"/>
       </fileset>
       <fileset dir="${dom4j.dom4j.lib}">
-          <include name="dom4j.jar"/>
+        <include name="dom4j.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
-    <copy tofile="${install.client}/jmx-client.jar"
-      file="${_module.output}/lib/jboss-jmx.jar" />
-
+    <copy tofile="${install.client}/jmx-client.jar" file="${_module.output}/lib/jboss-jmx.jar"/>
+    
   </target>
-
+  
   <target name="_module-jmx-all" depends="_module-jmx-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
- </target>
-
+    
+  </target>
+  
   <!-- ======== -->
   <!-- Security -->
   <!-- ======== -->
-
+  
   <target name="_module-security-most">
     <property name="_module.name" value="security" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the security-policies-service.xml -->
     <copy todir="${install.server}/all/deploy" filtering="no">
       <fileset dir="${_module.output}/resources">
-         <include name="security-policies-service.xml"/>
+        <include name="security-policies-service.xml"/>
       </fileset>
     </copy>
   </target>
-
+  
   <target name="_module-security-all" depends="_module-security-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ======= -->
   <!-- Cluster -->
   <!-- ======= -->
-
+  
   <target name="_module-cluster-most">
     <property name="_module.name" value="cluster" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jbossha.jar"/>
-         <include name="jbossmqha.jar"/>
+        <include name="jbossha.jar"/>
+        <include name="jbossmqha.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jbossha-client.jar"/>
-         <include name="jbossmqha.jar"/>
+        <include name="jbossha-client.jar"/>
+        <include name="jbossmqha.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty code -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${jgroups.jgroups.lib}">
         <include name="jgroups.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Default server config -->
-
+    
     <!-- Copy the deployables -->
     <mkdir dir="${install.server}/all/deploy"/>
     <copy todir="${install.server}/all/deploy" filtering="no">
       <fileset dir="${_module.output}/etc">
-         <include name="cluster-beans.xml"/>
-         <include name="deploy-hasingleton-beans.xml"/>
+        <include name="cluster-beans.xml"/>
+        <include name="deploy-hasingleton-beans.xml"/>
       </fileset>
     </copy>
     <mkdir dir="${install.server}/all/deploy/jgroups-multiplexer.sar"/>
     <copy todir="${install.server}/all/deploy/jgroups-multiplexer.sar" filtering="no">
       <fileset dir="${_module.output}/resources/jgroups-multiplexer.sar">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
     <mkdir dir="${install.server}/all/deploy/deploy.last"/>
-<!--
+    <!--
     <copy todir="${install.server}/all/deploy/deploy.last" filtering="no">
-      <fileset dir="${_module.output}/etc">
-         <include name="farm-beans.xml"/>
-      </fileset>
+    <fileset dir="${_module.output}/etc">
+    <include name="farm-beans.xml"/>
+    </fileset>
     </copy>
-
+    
     <!- - Copy the farmed deployables - ->
     <mkdir dir="${install.server}/all/farm"/>
     <copy todir="${install.server}/all/farm" filtering="no">
-      <fileset dir="${_module.output}/etc">
-         <include name="cluster-examples-service.xml"/>
-      </fileset>
+    <fileset dir="${_module.output}/etc">
+    <include name="cluster-examples-service.xml"/>
+    </fileset>
     </copy>
--->
-
+    -->
+    
   </target>
-
+  
   <target name="_module-cluster-all" depends="_module-cluster-most">
     <!-- Copy the examples -->
     <mkdir dir="${install.docs}/${module}"/>
     <copy todir="${install.docs}/${module}" filtering="no">
       <fileset dir="${_module.output}">
-         <include name="examples/*"/>
+        <include name="examples/*"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ===== -->
   <!-- Varia -->
   <!-- ===== -->
-
+  
   <target name="_module-varia-most">
     <property name="_module.name" value="varia" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="mail-plugin.jar"/>
-         <include name="scheduler-plugin.jar"/>
-         <include name="scheduler-plugin-example.jar"/>
-         <include name="hsqldb.jar"/>
-         <include name="hsqldb-plugin.jar"/>
-         <include name="autonumber-plugin.jar"/>
-         <include name="properties-plugin.jar"/>
-         <include name="bindingservice-plugin.jar"/>
-         <include name="jboss-monitoring.jar"/>
-         <include name="jboss-srp.jar" />
+        <include name="mail-plugin.jar"/>
+        <include name="scheduler-plugin.jar"/>
+        <include name="scheduler-plugin-example.jar"/>
+        <include name="hsqldb.jar"/>
+        <include name="hsqldb-plugin.jar"/>
+        <include name="autonumber-plugin.jar"/>
+        <include name="properties-plugin.jar"/>
+        <include name="bindingservice-plugin.jar"/>
+        <include name="jboss-monitoring.jar"/>
+        <include name="jboss-srp.jar"/>
       </fileset>
     </copy>
-
+    
     <mkdir dir="${install.examples.varia}"/>
     <copy todir="${install.examples.varia}" filtering="no">
       <fileset dir="${project.root}/testsuite/src/etc/cluster-test">
-         <include name="jboss-bindings.xml" />
+        <include name="jboss-bindings.xml"/>
       </fileset>
     </copy>
-   <mkdir dir="${install.examples}/jmx/persistent-service.sar"/>
-   <unjar src="${_module.output}/lib/persistent-service.sar"
-         dest="${install.examples}/jmx/persistent-service.sar"/>
-
-   <mkdir dir="${install.examples.varia}/deployment-service"/>
-   <copy todir="${install.examples.varia}/deployment-service">
-     <fileset dir="${_module.output}/lib">
-       <include name="deployment-service.sar"/>
-     </fileset>
-     <fileset dir="${_module.output}/resources/services/deployment">
-       <exclude name="META-INF/**"/>
-     </fileset>
-   </copy>
-
-   <!-- MBean Configurator sar for setting mbean attributes when registered -->
-   <mkdir dir="${install.examples}/jmx/mbean-configurator.sar"/>
-   <unjar src="${_module.output}/lib/mbean-configurator.sar"
-         dest="${install.examples}/jmx/mbean-configurator.sar"/>
-
-     <!-- Client jars -->
-     <mkdir dir="${install.client}"/>
-     <copy todir="${install.client}" filtering="no">
-       <fileset dir="${apache.scout.lib}">
-          <include name="scout.jar"/>
-       </fileset>
-       <fileset dir="${_module.output}/lib">
-          <include name="jbossjmx-ant.jar"/>
-          <include name="jboss-srp-client.jar"/>
-          <include name="juddisaaj.jar"/>
-       </fileset>
-     </copy>
-
+    <mkdir dir="${install.examples}/jmx/persistent-service.sar"/>
+    <unjar src="${_module.output}/lib/persistent-service.sar" dest="${install.examples}/jmx/persistent-service.sar"/>
+    
+    <mkdir dir="${install.examples.varia}/deployment-service"/>
+    <copy todir="${install.examples.varia}/deployment-service">
+      <fileset dir="${_module.output}/lib">
+        <include name="deployment-service.sar"/>
+      </fileset>
+      <fileset dir="${_module.output}/resources/services/deployment">
+        <exclude name="META-INF/**"/>
+      </fileset>
+    </copy>
+    
+    <!-- MBean Configurator sar for setting mbean attributes when registered -->
+    <mkdir dir="${install.examples}/jmx/mbean-configurator.sar"/>
+    <unjar src="${_module.output}/lib/mbean-configurator.sar" dest="${install.examples}/jmx/mbean-configurator.sar"/>
+    
+    <!-- Client jars -->
+    <mkdir dir="${install.client}"/>
+    <copy todir="${install.client}" filtering="no">
+      <fileset dir="${apache.scout.lib}">
+        <include name="scout.jar"/>
+      </fileset>
+      <fileset dir="${_module.output}/lib">
+        <include name="jbossjmx-ant.jar"/>
+        <include name="jboss-srp-client.jar"/>
+        <include name="juddisaaj.jar"/>
+      </fileset>
+    </copy>
+    
     <!-- Copy thirdparty code -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${sun.jaf.lib}">
@@ -1081,145 +1050,133 @@
         <include name="mail.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Default server config -->
-
+    
     <!-- Copy the deployables -->
     <mkdir dir="${install.server}/all/deploy"/>
     <copy todir="${install.server}/all/deploy" filtering="no">
       <!-- Deployable configuration -->
       <fileset dir="${_module.output}/etc">
-         <!-- These should move to example/deploy -->
-         <include name="monitoring-service.xml"/>
-         <include name="mail-service.xml"/>
-         <include name="schedule-manager-service.xml"/>
-         <include name="scheduler-service.xml"/>
-         <include name="properties-service.xml"/>
+        <!-- These should move to example/deploy -->
+        <include name="monitoring-service.xml"/>
+        <include name="mail-service.xml"/>
+        <include name="schedule-manager-service.xml"/>
+        <include name="scheduler-service.xml"/>
+        <include name="properties-service.xml"/>
       </fileset>
     </copy>
-
+    
     <!-- copy snmp-adaptor.sar unpacked to deploy -->
     <!-- and the used joesnmp.jar library to lib -->
     <mkdir dir="${install.server}/all/deploy/snmp-adaptor.sar"/>
-    <unjar src="${_module.output}/lib/snmp-adaptor.sar"
-      dest="${install.server}/all/deploy/snmp-adaptor.sar"/>
+    <unjar src="${_module.output}/lib/snmp-adaptor.sar" dest="${install.server}/all/deploy/snmp-adaptor.sar"/>
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${opennms.joesnmp.lib}">
-         <include name="joesnmp.jar"/>
+        <include name="joesnmp.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Include the JMX console war unpacked -->
     <mkdir dir="${install.server}/all/deploy/jmx-console.war"/>
-    <unjar src="${_module.output}/lib/jmx-console.war"
-       dest="${install.server}/all/deploy/jmx-console.war"/>
-
+    <unjar src="${_module.output}/lib/jmx-console.war" dest="${install.server}/all/deploy/jmx-console.war"/>
+    
     <!-- Include the juddi sar unpacked -->
     <mkdir dir="${install.server}/all/deploy/juddi-service.sar"/>
-    <delete dir="${install.server}/all/deploy/juddi-service.sar/juddi.war" quiet="true" />
-    <unjar src="${_module.output}/lib/juddi-service.sar"
-       dest="${install.server}/all/deploy/juddi-service.sar" />
-
-
+    <delete dir="${install.server}/all/deploy/juddi-service.sar/juddi.war" quiet="true"/>
+    <unjar src="${_module.output}/lib/juddi-service.sar" dest="${install.server}/all/deploy/juddi-service.sar"/>
+    
     <mkdir dir="${install.server}/all/deploy/juddi-service.sar/juddiws.war"/>
-    <unjar src="${_module.output}/lib/juddiws.war"
-      dest="${install.server}/all/deploy/juddi-service.sar/juddiws.war"/>
-
+    <unjar src="${_module.output}/lib/juddiws.war" dest="${install.server}/all/deploy/juddi-service.sar/juddiws.war"/>
+    
     <copy todir="${install.server}/all/deploy/juddi-service.sar" filtering="no">
       <fileset dir="${apache.scout.lib}">
-         <include name="scout.jar"/>
+        <include name="scout.jar"/>
       </fileset>
       <fileset dir="${_module.output}/lib">
-         <include name="juddisaaj.jar"/>
+        <include name="juddisaaj.jar"/>
       </fileset>
       <fileset dir="${juddi.juddi.lib}">
-         <include name="juddi.jar"/>
+        <include name="juddi.jar"/>
       </fileset>
     </copy>
-
+    
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${apache.scout.lib}">
-         <include name="scout.jar"/>
+        <include name="scout.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Include StAX (JSR-173) -->
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${codehaus.stax.lib}">
-         <include name="stax-1.1.1.jar"/>
+        <include name="stax-1.1.1.jar"/>
       </fileset>
     </copy>
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${wutka.dtdparser.lib}">
-         <include name="dtdparser121.jar"/>
+        <include name="dtdparser121.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Include the HTTP invoker service unpacked -->
     <mkdir dir="${install.server}/all/deploy/httpha-invoker.sar"/>
-    <unjar src="${_module.output}/lib/httpha-invoker.sar"
-      dest="${install.server}/all/deploy/httpha-invoker.sar"/>
-
+    <unjar src="${_module.output}/lib/httpha-invoker.sar" dest="${install.server}/all/deploy/httpha-invoker.sar"/>
+    
     <!-- copy the ant jmx client -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jbossjmx-ant.jar"/>
+        <include name="jbossjmx-ant.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- copy the netboot war tool -->
     <mkdir dir="${install.examples.netboot}"/>
     <copy todir="${install.examples.netboot}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="netboot.war"/>
+        <include name="netboot.war"/>
       </fileset>
     </copy>
-
+    
     <!-- copy the bsh-deployer lib and its associated beanshell lib from thirdparty
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${_module.output}/lib">
-         <include name="bsh-deployer.jar"/>
-      </fileset>
-      <fileset dir="${beanshell.beanshell.lib}">
-        <include name="*.jar"/>
-      </fileset>
+    <fileset dir="${_module.output}/lib">
+    <include name="bsh-deployer.jar"/>
+    </fileset>
+    <fileset dir="${beanshell.beanshell.lib}">
+    <include name="*.jar"/>
+    </fileset>
     </copy>
--->
-
+    -->
+    
     <!-- Include the HTTP invoker service unpacked -->
     <delete dir="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar"/>
     <mkdir dir="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar"/>
-    <unjar src="${_module.output}/lib/jbossmq-httpil.sar"
-       dest="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar" />
-    <move file="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/jbossmq-httpil.war"
-       tofile="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/tmp.war" />
+    <unjar src="${_module.output}/lib/jbossmq-httpil.sar" dest="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar"/>
+    <move file="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/jbossmq-httpil.war" tofile="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/tmp.war"/>
     <mkdir dir="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/jbossmq-httpil.war"/>
-    <unjar src="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/tmp.war"
-       dest="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/jbossmq-httpil.war" />
-    <delete file="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/tmp.war" />
-
+    <unjar src="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/tmp.war" dest="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/jbossmq-httpil.war"/>
+    <delete file="${install.all.deploy.hasingleton}/jms/jbossmq-httpil.sar/tmp.war"/>
+    
     <!-- copy the jboss-monitoring JAR -->
-    <copy file="${project.root}/varia/output/lib/jboss-monitoring.jar"
-          todir="${install.server}/all/lib"/>
-
+    <copy file="${project.root}/varia/output/lib/jboss-monitoring.jar" todir="${install.server}/all/lib"/>
+    
     <!-- copy the binding-manager sample file and JAR -->
-    <copy file="${project.root}/varia/output/lib/bindingservice-plugin.jar"
-          todir="${install.server}/all/lib"/>
-
+    <copy file="${project.root}/varia/output/lib/bindingservice-plugin.jar" todir="${install.server}/all/lib"/>
+    
     <mkdir dir="${install.examples.binding-manager}"/>
-    <copy file="${project.root}/varia/src/resources/services/binding/sample-bindings.xml"
-          todir="${install.examples.binding-manager}"/>
-
+    <copy file="${project.root}/varia/src/resources/services/binding/sample-bindings.xml" todir="${install.examples.binding-manager}"/>
+    
     <!-- the bean deployer : obsolete in jboss5
     <mkdir dir="${install.all.deploy}/jboss-bean.deployer"/>
     <copy todir="${install.all.deploy}/jboss-bean.deployer" filtering="no">
-      <fileset dir="${_module.output}/lib/kernel/jboss-bean.deployer">
-         <include name="**/*"/>
-      </fileset>
+    <fileset dir="${_module.output}/lib/kernel/jboss-bean.deployer">
+    <include name="**/*"/>
+    </fileset>
     </copy>
-  	-->
-
+    -->
+    
     <!-- copy the logging-monitor service to examples -->
     <mkdir dir="${install.examples}/jmx/logging-monitor/lib"/>
     <copy todir="${install.examples}/jmx/logging-monitor/lib" filtering="no">
@@ -1230,124 +1187,118 @@
     <copy todir="${install.examples}/jmx/logging-monitor" filtering="no">
       <fileset dir="${_module.output}/resources/services/loggingmonitor"/>
     </copy>
-
+    
     <!-- copy bsf.jar used by scripting-listener -->
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${apache.bsf.lib}">
-         <include name="bsf.jar"/>
+        <include name="bsf.jar"/>
       </fileset>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-varia-all" depends="_module-varia-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ===== -->
   <!-- JBoss Web -->
   <!-- ===== -->
-
+  
   <target name="_module-tomcat-most">
     <property name="_module.name" value="tomcat" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-    <property name="_module.ext" override="true"
-	      value="${project.root}/${_module.name}/ext"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    <property name="_module.ext" override="true" value="${project.root}/${_module.name}/ext"/>
+    
     <!-- Copy the thirdparty libraries -->
     <mkdir dir="${install.all.lib}"/>
-    <copy tofile="${install.all.lib}/javax.servlet.jar"
-       file="${jboss.web.lib}/servlet-api.jar" />
-    <copy tofile="${install.all.lib}/javax.servlet.jsp.jar"
-       file="${jboss.web.lib}/jsp-api.jar" />
-    <copy tofile="${install.all.lib}/javax.el.jar"
-       file="${jboss.web.lib}/el-api.jar" />
-
+    <copy tofile="${install.all.lib}/javax.servlet.jar" file="${jboss.web.lib}/servlet-api.jar"/>
+    <copy tofile="${install.all.lib}/javax.servlet.jsp.jar" file="${jboss.web.lib}/jsp-api.jar"/>
+    <copy tofile="${install.all.lib}/javax.el.jar" file="${jboss.web.lib}/el-api.jar"/>
+    
     <!-- Copy the deployables -->
     <mkdir dir="${install.server}/all/deployers/jbossweb.deployer"/>
     <copy todir="${install.server}/all/deployers/jbossweb.deployer">
-      <fileset dir="${_module.output}/deploy/jbossweb.deployer" />
+      <fileset dir="${_module.output}/deploy/jbossweb.deployer"/>
     </copy>
     <!-- Use the all war deployers descriptor -->
     <copy tofile="${install.server}/all/deployers/jbossweb.deployer/META-INF/war-deployers-beans.xml"
       file="${project.root}/${_module.name}/src/resources/war-deployers-all-beans.xml" overwrite="true"/>
-
+    
     <!-- Copy the ROOT.war -->
     <copy todir="${install.server}/all/deploy">
-       <fileset dir="${_module.output}/deploy">
-           <include name="ROOT.war/**"/>
-       </fileset>
+      <fileset dir="${_module.output}/deploy">
+        <include name="ROOT.war/**"/>
+      </fileset>
     </copy>
     <!-- Copy the tc5 clustering service sar -->
     <copy todir="${install.server}/all/deploy">
-       <fileset dir="${_module.output}/deploy">
-           <include name="tc6-cluster.sar/**"/>
-       </fileset>
+      <fileset dir="${_module.output}/deploy">
+        <include name="tc6-cluster.sar/**"/>
+      </fileset>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-tomcat-all" depends="_module-tomcat-most">
   </target>
-
+  
   <!-- ========== -->
   <!-- Webservice -->
   <!-- ========== -->
-
+  
   <target name="_module-webservice-most" depends="module-webservice15">
     <property name="_module.name" value="webservice" override="true"/>
     <property name="_module.output" value="${project.root}/${_module.name}/output" override="true"/>
-
+    
     <!-- copy common client stuff -->
     <mkdir dir="${install.client}"/>
-
+    
     <copy todir="${install.all.lib}" filtering="no">
     </copy>
-
-   </target>
-
+    
+  </target>
+  
   <target name="module-webservice15" if="HAVE_JDK_1.5">
-
+    
     <!-- copy the client stuff -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-webservice-all" depends="_module-webservice-most">
   </target>
-
+  
   <!-- ==== -->
   <!-- IIOP -->
   <!-- ==== -->
-
+  
   <target name="_module-iiop-most">
     <property name="_module.name" value="iiop" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the jboss-iiop.jar -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-iiop.jar"/>
+        <include name="jboss-iiop.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the jboss-iiop-client.jar -->
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-iiop-client.jar"/>
+        <include name="jboss-iiop-client.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty code -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${jacorb.jacorb.lib}">
@@ -1357,7 +1308,7 @@
         <include name="avalon-framework.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty client code -->
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${jacorb.jacorb.lib}">
@@ -1370,7 +1321,7 @@
         <include name="logkit.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty configuration file and jndi.properties file -->
     <mkdir dir="${install.server}/all/conf"/>
     <copy todir="${install.server}/all/conf" filtering="no" overwrite="true">
@@ -1378,180 +1329,173 @@
         <include name="jacorb.properties"/>
       </fileset>
       <fileset dir="${_module.output}/etc/conf">
-         <include name="jndi.properties"/>
+        <include name="jndi.properties"/>
       </fileset>
     </copy>
-
+    
     <mkdir dir="${install.server}/all/deploy"/>
     <copy todir="${install.server}/all/deploy" filtering="no">
       <!-- Deployable service -->
       <fileset dir="${_module.output}/etc">
-         <include name="iiop-service.xml"/>
+        <include name="iiop-service.xml"/>
       </fileset>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-iiop-all" depends="_module-iiop-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ========== -->
   <!-- Management -->
   <!-- ========== -->
-
+  
   <target name="_module-management-most">
     <property name="_module.name" value="management" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-jsr77.jar"/>
-         <include name="jboss-management.jar"/>
+        <include name="jboss-jsr77.jar"/>
+        <include name="jboss-management.jar"/>
       </fileset>
     </copy>
-
+    
     <mkdir dir="${install.examples}/jmx"/>
     <copy todir="${install.examples}/jmx" filtering="no">
       <!-- Deployable archives -->
       <fileset dir="${_module.output}/lib">
-         <include name="ejb-management.jar"/>
+        <include name="ejb-management.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-jsr77-client.jar"/>
+        <include name="jboss-jsr77-client.jar"/>
       </fileset>
     </copy>
   </target>
-
+  
   <target name="_module-management-all" depends="_module-management-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated todo docs -->
     <mkdir dir="${install.todo}/${_module.name}"/>
     <copy todir="${install.todo}/${_module.name}" filtering="no" failonerror="false">
       <fileset dir="${_module.output}/todo">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- =========== -->
   <!-- Transaction -->
   <!-- =========== -->
-
+  
   <target name="_module-transaction-most">
     <property name="_module.name" value="transaction" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.all.lib}"/>
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-transaction.jar"/>
+        <include name="jboss-transaction.jar"/>
       </fileset>
     </copy>
-	<!-- copy binary release of JBossTS from thirdparty repo -->
-	<copy todir="${install.all.lib}" filtering="no">
-		<fileset dir="${project.thirdparty}/jboss/jbossts/lib/">
-			<include name="jbossjta.jar"/>
-			<include name="jbossjta-integration.jar"/>
-			<include name="jbossts-common.jar"/>
-		</fileset>
-	</copy>
-	<copy todir="${install.all.conf}" filtering="no"
-		file="${project.thirdparty}/jboss/jbossts/resources/jbossjta-properties.xml"/>
-
+    <!-- copy binary release of JBossTS from thirdparty repo -->
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${project.thirdparty}/jboss/jbossts/lib/">
+        <include name="jbossjta.jar"/>
+        <include name="jbossjta-integration.jar"/>
+        <include name="jbossts-common.jar"/>
+      </fileset>
+    </copy>
+    <copy todir="${install.all.conf}" filtering="no" file="${project.thirdparty}/jboss/jbossts/resources/jbossjta-properties.xml"/>
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
       <fileset dir="${_module.output}/lib">
-         <include name="jboss-transaction-client.jar"/>
+        <include name="jboss-transaction-client.jar"/>
       </fileset>
     </copy>
   </target>
-
+  
   <target name="_module-transaction-all" depends="_module-transaction-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
+  
   <!-- ======= -->
   <!-- Console -->
   <!-- ======= -->
-
+  
   <target name="_module-console-most">
     <property name="_module.name" value="console" override="true"/>
-    <property name="_module.output" override="true"
-	      value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <!-- Copy the generated scripts & runnable jars -->
     <mkdir dir="${install.bin}"/>
     <copy todir="${install.bin}" filtering="no">
       <fileset dir="${_module.output}/bin">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
       <fileset dir="${_module.output}/lib">
-         <include name="twiddle.jar"/>
+        <include name="twiddle.jar"/>
       </fileset>
     </copy>
     <chmod perm="+x">
       <fileset dir="${install.bin}">
-         <include name="**/*.sh"/>
+        <include name="**/*.sh"/>
       </fileset>
     </chmod>
-
+    
     <!-- Copy the BeanShell JAR -->
     <copy todir="${install.server}/all/lib" filtering="no">
       <fileset dir="${beanshell.beanshell.lib}">
-         <include name="**"/>
+        <include name="**"/>
       </fileset>
     </copy>
-
+    
     <!-- Unpack the plugin manager SAR (embedded) and application WAR -->
-    <unjar src="${_module.output}/lib/console-mgr.sar"
-       dest="${install.all.deploy}/management/console-mgr.sar" />
-     <unjar src="${_module.output}/lib/web-console.war"
-        dest="${install.all.deploy}/management/console-mgr.sar/web-console.war" />
-
+    <unjar src="${_module.output}/lib/console-mgr.sar" dest="${install.all.deploy}/management/console-mgr.sar"/>
+    <unjar src="${_module.output}/lib/web-console.war" dest="${install.all.deploy}/management/console-mgr.sar/web-console.war"/>
+    
   </target>
-
+  
   <target name="_module-console-all" depends="_module-console-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
-
+  
   <!-- ============= -->
   <!-- Compatibility -->
   <!-- ============= -->
@@ -1559,7 +1503,7 @@
     <call target="make-compat"/>
     <call target="check-compat"/>
   </target>
-
+  
   <target name="make-compat" if="compatibility.make">
     <!-- Create serialized versions of contract classes -->
     <mkdir dir="${compatibility.dir}"/>
@@ -1571,11 +1515,10 @@
       </classpath>
     </java>
   </target>
-
+  
   <target name="check-compat" if="compatibility.check">
     <!-- Check compiled contract classes against serialized versions -->
-    <java classname="${compatibility.bin}" fork="true" failonerror="true" dir="${compatibility.dir}"
->
+    <java classname="${compatibility.bin}" fork="true" failonerror="true" dir="${compatibility.dir}">
       <arg value="check"/>
       <arg value="${contract.classes}"/>
       <classpath>
@@ -1583,30 +1526,28 @@
       </classpath>
     </java>
   </target>
-
-
+  
   <!-- ========== -->
   <!-- Deployment -->
   <!-- ========== -->
-
+  
   <target name="_module-deployment-most">
     <property name="_module.name" value="deployment" override="true"/>
-    <property name="_module.output" override="true"
-      value="${project.root}/${_module.name}/output"/>
-
-     <!-- Copy the generated libraries -->
-     <mkdir dir="${install.all.lib}"/>
-     <copy todir="${install.all.lib}" filtering="no">
-       <fileset dir="${_module.output}/lib">
-         <include name="jboss-jsr88.jar"/>
-       </fileset>
-     </copy>
-     <copy todir="${install.all.deploy}" filtering="no">
-       <fileset dir="${_module.output}/etc">
-         <include name="jsr88-service.xml"/>
-       </fileset>
-     </copy>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
+    <!-- Copy the generated libraries -->
+    <mkdir dir="${install.all.lib}"/>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${_module.output}/lib">
+        <include name="jboss-jsr88.jar"/>
+      </fileset>
+    </copy>
+    <copy todir="${install.all.deploy}" filtering="no">
+      <fileset dir="${_module.output}/etc">
+        <include name="jsr88-service.xml"/>
+      </fileset>
+    </copy>
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
@@ -1614,80 +1555,76 @@
         <include name="jboss-deployment.jar"/>
       </fileset>
     </copy>
-
+    
   </target>
-
+  
   <target name="_module-deployment-all" depends="_module-deployment-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
     <copy todir="${install.api}/${_module.name}" filtering="no">
       <fileset dir="${_module.output}/api">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated todo docs -->
     <mkdir dir="${install.todo}/${_module.name}"/>
     <copy todir="${install.todo}/${_module.name}" filtering="no" failonerror="false">
       <fileset dir="${_module.output}/todo">
-         <include name="**/*"/>
+        <include name="**/*"/>
       </fileset>
     </copy>
   </target>
-
-
+  
   <!-- ============ -->
   <!-- Hibernate    -->
   <!-- ============ -->
-
+  
   <target name="_module-hibernate-int-most">
     <property name="_module.name" value="hibernate-int" override="true"/>
-    <property name="_module.output" override="true"
-        value="${project.root}/${_module.name}/output"/>
-
+    <property name="_module.output" override="true" value="${project.root}/${_module.name}/output"/>
+    
     <mkdir dir="${install.all.lib}"/>
-
+    
     <!-- The hibernate-int module output -->
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${_module.output}/lib" includes="*.jar" />
+      <fileset dir="${_module.output}/lib" includes="*.jar"/>
     </copy>
-
+    
     <!-- The hibernate jar -->
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${hibernate.lib}" includes="*.jar" />
+      <fileset dir="${hibernate.lib}" includes="*.jar"/>
     </copy>
-
+    
     <!-- ASM jars (cglib dependency)
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${asm.asm.lib}" includes="*.jar" />
+    <fileset dir="${asm.asm.lib}" includes="*.jar" />
     </copy>
     -->
-
+    
     <!-- ANTLR jar -->
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${antlr.antlr.lib}" includes="*.jar" />
+      <fileset dir="${antlr.antlr.lib}" includes="*.jar"/>
     </copy>
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
-      <fileset dir="${antlr.antlr.lib}" includes="*.jar" />
+      <fileset dir="${antlr.antlr.lib}" includes="*.jar"/>
     </copy>
-
+    
     <!-- CGLIB jar
     <copy todir="${install.all.lib}" filtering="no">
-      <fileset dir="${cglib.lib}" includes="*.jar"/>
+    <fileset dir="${cglib.lib}" includes="*.jar"/>
     </copy>
     -->
-
+    
     <!-- Commons collections jar -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${apache.collections.lib}" includes="*.jar"/>
     </copy>
-
+    
   </target>
-
-
-
+  
   <target name="_module-hibernate-int-all" depends="_module-hibernate-int-most">
     <!-- Copy the generated javadocs -->
     <mkdir dir="${install.api}/${_module.name}"/>
@@ -1697,46 +1634,43 @@
       </fileset>
     </copy>
   </target>
-
-
-    <!-- ============ -->
-    <!--   Spring     -->
-    <!-- ============ -->
-
-<!--
+  
+  <!-- ============ -->
+  <!--   Spring     -->
+  <!-- ============ -->
+  
+  <!--
   <target name="_module-spring-int-most">
-    <property name="_module.name" value="spring-int" override="true"/>
-    <property name="_module.output" override="true"
-              value="${project.root}/${_module.name}/output"/>
-
-    <mkdir dir="${install.server}/all/deploy/jboss-spring-jdk5.deployer"/>
-    <unjar src="${_module.output}/lib/jboss-spring-jdk5.deployer"
-           dest="${install.server}/all/deploy/jboss-spring-jdk5.deployer" />
+  <property name="_module.name" value="spring-int" override="true"/>
+  <property name="_module.output" override="true"
+  value="${project.root}/${_module.name}/output"/>
+  
+  <mkdir dir="${install.server}/all/deploy/jboss-spring-jdk5.deployer"/>
+  <unjar src="${_module.output}/lib/jboss-spring-jdk5.deployer"
+  dest="${install.server}/all/deploy/jboss-spring-jdk5.deployer" />
   </target>
-
+  
   <target name="_module-spring-int-all" depends="_module-spring-int-most">
-    <mkdir dir="${install.api}/${_module.name}"/>
-    <copy todir="${install.api}/${_module.name}" filtering="no">
-      <fileset dir="${_module.output}/api">
-        <include name="**/*"/>
-      </fileset>
-    </copy>
+  <mkdir dir="${install.api}/${_module.name}"/>
+  <copy todir="${install.api}/${_module.name}" filtering="no">
+  <fileset dir="${_module.output}/api">
+  <include name="**/*"/>
+  </fileset>
+  </copy>
   </target>
--->
-
-
-
+  -->
+  
   <target name="thirdparty">
-     <!-- Copy thirdparty libraries -->
-     <mkdir dir="${install.all.lib}"/>
-     <copy todir="${install.all.lib}" filtering="no">
-        <fileset dir="${jboss.cache.lib}">
-           <include name="jbosscache.jar"/>
-           <include name="pojocache.jar"/>
-        </fileset>
-       <fileset dir="${jboss.backport.concurrent.lib}">
-         <include name="jboss-backport-concurrent.jar"/>
-       </fileset>
+    <!-- Copy thirdparty libraries -->
+    <mkdir dir="${install.all.lib}"/>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${jboss.cache.lib}">
+        <include name="jbosscache.jar"/>
+        <include name="pojocache.jar"/>
+      </fileset>
+      <fileset dir="${jboss.backport.concurrent.lib}">
+        <include name="jboss-backport-concurrent.jar"/>
+      </fileset>
       <fileset dir="${jboss.security.spi.lib}">
         <include name="jboss-security-spi.jar"/>
       </fileset>
@@ -1747,15 +1681,14 @@
         <include name="sunxacml.jar"/>
         <include name="sunxacml-support.jar"/>
       </fileset>
-     </copy>
-
-
+    </copy>
+    
     <!-- Copy the generated libraries -->
     <mkdir dir="${install.lib}"/>
     <copy todir="${install.lib}" filtering="no">
-       <fileset dir="${javassist.javassist.lib}">
-         <include name="javassist.jar"/>
-       </fileset>
+      <fileset dir="${javassist.javassist.lib}">
+        <include name="javassist.jar"/>
+      </fileset>
       <fileset dir="${jboss.common.core.lib}">
         <exclude name="*-sources.jar"/>
       </fileset>
@@ -1779,7 +1712,7 @@
         <include name="jboss-deployers.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">
@@ -1835,7 +1768,7 @@
         <include name="jboss-saaj.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty code to lib/endorsed -->
     <mkdir dir="${install.lib}/endorsed"/>
     <copy todir="${install.lib}/endorsed" filtering="no">
@@ -1849,7 +1782,7 @@
         <include name="serializer.jar"/>
       </fileset>
     </copy>
-
+    
     <!-- Copy thirdparty code to server/all/lib -->
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${apache.logging.lib}">
@@ -1860,19 +1793,21 @@
         <include name="jboss-saaj.jar"/>
       </fileset>
     </copy>
-
-
-     <!-- setup webservice sar -->
+    
+    <!-- Install jbossws.deployer -->
+    <mkdir dir="${install.server}/all/deployers/jbossws.deployer"/>
+    <unjar dest="${install.server}/all/deployers/jbossws.deployer" src="${jboss.jbossws.lib}/jbossws.deployer"/>
+    
+    <!-- Install jbossws.sar -->
     <mkdir dir="${install.all.deploy}/jbossws.sar"/>
     <unjar dest="${install.all.deploy}/jbossws.sar" src="${jboss.jbossws.lib}/jbossws.sar"/>
-
+    
     <!-- install wstools shell scripts -->
     <unjar dest="${install.bin}" src="${jboss.jbossws.lib}/jbossws-client.jar">
       <patternset>
         <include name="wstools.*"/>
       </patternset>
     </unjar>
-
+    
   </target>
-
-</project>
+  </project>



From tom.elrod at jboss.com  Tue Dec 12 09:41:16 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Tue, 12 Dec 2006 09:41:16 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gu8om-000660-G4@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/12 09:41:16

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        ConnectionValidator.java
  Log:
  JBREM-648 - fix for NPE on connection validator after client disconnect.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.2  +25 -11    JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java,v
  retrieving revision 1.13.2.1
  retrieving revision 1.13.2.2
  diff -u -b -r1.13.2.1 -r1.13.2.2
  --- ConnectionValidator.java	12 Dec 2006 04:55:30 -0000	1.13.2.1
  +++ ConnectionValidator.java	12 Dec 2006 14:41:16 -0000	1.13.2.2
  @@ -45,6 +45,9 @@
   
      protected static final Logger log = Logger.getLogger(ConnectionValidator.class.getName());
   
  +   private Object lock = new Object();
  +   private boolean stopped = false;
  +
      /**
       * Default ping period.  Value is 2 seconds.
       */
  @@ -64,15 +67,20 @@
      private void start()
      {
         TimerUtil.schedule(this, pingPeriod);
  +      stopped = false;
      }
   
      public void stop()
      {
  +      synchronized(lock)
  +      {
         cancel();
         if (!listeners.isEmpty())
         {
            listeners.clear();
         }
  +         stopped = true;
  +      }
      }
   
   
  @@ -113,6 +121,10 @@
       */
      public void run()
      {
  +      synchronized(lock)
  +      {
  +         if(!stopped)
  +         {
         try
         {
            boolean isValid = checkConnection(client.getInvoker().getLocator(), client.getConfiguration());
  @@ -126,6 +138,8 @@
            notifyListeners(thr);
         }
      }
  +      }
  +   }
   
      private void notifyListeners(Throwable thr)
      {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 09:48:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 09:48:01 -0500
Subject: [jboss-cvs] JBossAS SVN:  r58995 - branches/Branch_4_2/build
Message-ID: <E1Gu8vJ-0006G5-Qs@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-12 09:47:58 -0500 (Tue, 12 Dec 2006)
New Revision: 58995

Modified:
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
Upgrade components

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-12 12:54:18 UTC (rev 58994)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-12 14:47:58 UTC (rev 58995)
@@ -77,24 +77,24 @@
       <componentref name="dom4j" version="1.6.1"/>
       <componentref name="gjt-jpl-util" version="1.0"/>
       <componentref name="gnu-getopt" version="1.0.10"/>
-      <componentref name="hibernate" version="3.2.0.GA"/>
-      <componentref name="hibernate-annotations" version="3.2.0.GA"/>
-      <componentref name="hibernate-entitymanager" version="3.2.0.GA"/>
+      <componentref name="hibernate" version="3.2.1.GA"/>
+      <componentref name="hibernate-annotations" version="3.2.1.GA"/>
+      <componentref name="hibernate-entitymanager" version="3.2.1.GA"/>
       <componentref name="hsqldb" version="1.8.0.2"/>
       <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
       <componentref name="jacorb" version="2.2.4jboss.patch1"/>
-      <componentref name="javassist" version="3.3.0.GA"/>
+      <componentref name="javassist" version="3.4.GA"/>
       <componentref name="jaxen" version="1.1-beta-9"/>      
       <componentref name="jboss/aop" version="snapshot-Branch_AOP_1_5"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/cache" version="1.4.0.SP1"/>
       <componentref name="jboss/common" version="1.0.0.GA"/>
       <componentref name="jboss/dom4j-jarjar" version="1.6.1"/>
-      <componentref name="jboss/jbossretro-rt" version="1.0.3.GA"/>
-      <componentref name="jboss/jbossws" version="1.0.3.SP1"/>
-      <componentref name="jboss/jbossws14" version="1.0.3.SP1"/>
+      <componentref name="jboss/jbossretro-rt" version="1.0.4.GA"/>
+      <componentref name="jboss/jbossws" version="1.0.4.GA"/>
+      <componentref name="jboss/jbossws14" version="1.0.4.GA"/>
       <componentref name="jboss/jboss-ws4ee" version="4.0.4.SP1"/>
-      <componentref name="jboss/jbossxb" version="1.0.0.CR6"/>
+      <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
       <componentref name="jboss/microcontainer" version="1.0.2"/>
       <componentref name="jboss/remoting" version="1.4.3.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>



From tom.elrod at jboss.com  Tue Dec 12 09:49:23 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Tue, 12 Dec 2006 09:49:23 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Gu8wd-0006Gt-0W@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/12 09:49:23

  Modified:    src/main/org/jboss/remoting  ConnectionValidator.java
  Log:
  JBREM-648 - fixe NPE for connection validator when client disconnects.
  
  Revision  Changes    Path
  1.15      +19 -4     JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- ConnectionValidator.java	12 Dec 2006 05:14:40 -0000	1.14
  +++ ConnectionValidator.java	12 Dec 2006 14:49:22 -0000	1.15
  @@ -45,6 +45,9 @@
   
      protected static final Logger log = Logger.getLogger(ConnectionValidator.class.getName());
   
  +   private Object lock = new Object();
  +   private boolean stopped = false;
  +
      /**
       * Default ping period.  Value is 2 seconds.
       */
  @@ -64,15 +67,20 @@
      private void start()
      {
         TimerUtil.schedule(this, pingPeriod);
  +      stopped = false;
      }
   
      public void stop()
      {
  +      synchronized(lock)
  +      {
         cancel();
         if (!listeners.isEmpty())
         {
            listeners.clear();
      }
  +         stopped = true;
  +   }
      }
   
   
  @@ -113,6 +121,10 @@
       */
      public void run()
      {
  +      synchronized(lock)
  +      {
  +         if(!stopped)
  +         {
         try
         {
            boolean isValid = checkConnection(client.getInvoker().getLocator(), client.getConfiguration());
  @@ -126,6 +138,8 @@
            notifyListeners(thr);
         }
      }
  +      }
  +   }
   
      private void notifyListeners(Throwable thr)
      {
  @@ -162,10 +176,11 @@
      {
         boolean pingWorked = false;
   
  -      HashMap configMap = new HashMap();
  -      if (config != null)
  -         configMap.putAll(config);
  -
  +      Map configMap = config;
  +      if (configMap == null)
  +      {
  +         configMap = new HashMap();
  +      }
         configMap.put("connection_checker", "true");
         configMap.put("timeout", "1000");
         configMap.put("NumberOfRetries", "1");
  
  
  


From msurtani at jboss.com  Tue Dec 12 09:51:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 12 Dec 2006 09:51:44 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors       ...
Message-ID: <E1Gu8yu-0006Ki-D6@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/12 09:51:44

  Modified:    src/org/jboss/cache/interceptors      
                        InvocationContextInterceptor.java
                        OptimisticValidatorInterceptor.java
                        OptimisticCreateIfNotExistsInterceptor.java
                        OptimisticNodeInterceptor.java
                        PessimisticLockInterceptor.java
                        OptimisticReplicationInterceptor.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.11      +12 -7     JBossCache/src/org/jboss/cache/interceptors/InvocationContextInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvocationContextInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/InvocationContextInterceptor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- InvocationContextInterceptor.java	20 Nov 2006 03:53:54 -0000	1.10
  +++ InvocationContextInterceptor.java	12 Dec 2006 14:51:44 -0000	1.11
  @@ -8,7 +8,6 @@
   
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
  @@ -30,14 +29,19 @@
         Transaction suspendedTransaction = null;
         boolean resumeSuspended = false;
   
  +      if (log.isTraceEnabled())
  +         log.trace("Invoked on cache instance [" + cache.getLocalAddress() + "] and InvocationContext [" + ctx + "]");
  +
         try
         {
            Transaction tx = getTransaction();
            setTransactionalContext(tx, getGlobalTransaction(tx, call));
   
  -         if (optionOverride != null) {
  +         if (optionOverride != null)
  +         {
               
  -            if (optionOverride.isFailSilently()) {
  +            if (optionOverride.isFailSilently())
  +            {
                  log.debug("FAIL_SILENTLY Option is present - suspending any ongoing transaction.");
                  if (ctx.getTransaction() != null)
                  {
  @@ -54,6 +58,7 @@
               
               if (optionOverride.isBypassInterceptorChain())
               {
  +               log.trace("Interceptor chain bypass option set for call; skipping interceptyor chain and proceeding to last interceptor.");
                  return getLast().invoke(call);
               }
            }
  
  
  
  1.46      +21 -39    JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- OptimisticValidatorInterceptor.java	6 Dec 2006 16:28:37 -0000	1.45
  +++ OptimisticValidatorInterceptor.java	12 Dec 2006 14:51:44 -0000	1.46
  @@ -15,7 +15,6 @@
   import org.jboss.cache.OptimisticTreeNode;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
  -import org.jboss.cache.optimistic.DataVersion;
   import org.jboss.cache.optimistic.DataVersioningException;
   import org.jboss.cache.optimistic.DefaultDataVersion;
   import org.jboss.cache.optimistic.TransactionWorkspace;
  @@ -23,7 +22,6 @@
   
   import javax.transaction.Transaction;
   import java.util.Collection;
  -import java.util.Iterator;
   import java.util.Map;
   
   /**
  @@ -96,7 +94,7 @@
         }
   
         // should be an ordered list - get the set of nodes
  -      Collection nodes = workspace.getNodes().values();
  +      Collection<WorkspaceNode> nodes = workspace.getNodes().values();
   
         //we have all locks here so lets try and validate
         if (log.isDebugEnabled()) log.debug("validating nodes. Num nodes: " + nodes.size());
  @@ -104,53 +102,37 @@
         log.debug("validated nodes");
      }
   
  -   private void simpleValidate(Collection nodes)
  -           throws DataVersioningException
  +   private void simpleValidate(Collection<WorkspaceNode> nodes) throws DataVersioningException
      {
  -      WorkspaceNode workspaceNode;
  -
         boolean trace = log.isTraceEnabled();
  -      for (Object node : nodes)
  +      for (WorkspaceNode workspaceNode : nodes)
         {
  -         workspaceNode = (WorkspaceNode) node;
            Fqn fqn = workspaceNode.getFqn();
  -         if (trace) log.trace("validating version for node " + fqn);
  +         if (trace) log.trace("Validating version for node " + fqn);
   
            OptimisticTreeNode realNode;
            realNode = (OptimisticTreeNode) cache.peek(fqn);
   
  -         if (workspaceNode.isCreated())
  -         {
  -            if (realNode != null)
  -            {
  -               throw new DataVersioningException("Tx attempted to create " + fqn + " anew.  It has already been created since this tx started by another (possibly remote) tx.");
  -            }
  -         }
  -         else
  -         {
  -            if (realNode == null)
  +         // if this is a newly created node then we expect the underlying node to be null.
  +         // if not, we have a problem...
  +         if (realNode == null && !workspaceNode.isCreated())
               {
                  throw new DataVersioningException("Real node for " + fqn + " is null, and this wasn't newly created in this tx!");
               }
   
  -            if (workspaceNode == null)
  +         if (realNode != null && workspaceNode.isCreated())
               {
  -               throw new DataVersioningException("Workspace node for " + fqn + " is null, and this wasn't newly created in this tx!");
  +            throw new DataVersioningException("Tx attempted to create " + fqn + " anew.  It has already been created since this tx started by another (possibly remote) tx.");
               }
   
  -            if (workspaceNode.getVersion() == null)
  +         if (!workspaceNode.isCreated() && (workspaceNode.isDeleted() || workspaceNode.isDirty()))
               {
  -               throw new DataVersioningException("No version for workspace node");
  -            }
  -
  -            DataVersion rnv = realNode.getVersion();
  -            DataVersion wnv = workspaceNode.getVersion();
               // test that the 2 DataVersion types match up
  -            if (!rnv.getClass().equals(wnv.getClass()) && checkNotInitialRootVersion(realNode))
  +            if (!realNode.getVersion().getClass().equals(workspaceNode.getVersion().getClass()) && checkNotInitialRootVersion(realNode))
               {
  -               throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node that already contains version of type " + realNode.getVersion().getClass());
  +               throw new DataVersioningException("Attempting to apply data version of type " + workspaceNode.getVersion().getClass() + " to a node [fqn = " + realNode.getFqn() + "] that already contains version of type " + realNode.getVersion().getClass());
               }
  -            if ((workspaceNode.isDeleted() || workspaceNode.isDirty()) && realNode.getVersion().newerThan(workspaceNode.getVersion()))
  +            if (realNode.getVersion().newerThan(workspaceNode.getVersion()))
               {
                  // we have an out of date node here
                  throw new DataVersioningException("DataNode [" + fqn + "] version " + ((OptimisticTreeNode) workspaceNode.getNode()).getVersion() + " is newer than workspace node " + workspaceNode.getVersion());
  @@ -180,12 +162,11 @@
   
         log.debug("commiting validated changes ");
         // should be an ordered list
  -      Collection nodes = workspace.getNodes().values();
  +      Collection<WorkspaceNode> nodes = workspace.getNodes().values();
   
         boolean trace = log.isTraceEnabled();
  -      for (Iterator it = nodes.iterator(); it.hasNext();)
  +      for (WorkspaceNode wrappedNode : nodes)
         {
  -         WorkspaceNode wrappedNode = (WorkspaceNode) it.next();
            // short circuit if this node is deleted?
            if (wrappedNode.isDeleted())
            {
  @@ -239,8 +220,9 @@
                  Map raw = current.getNodeSPI().getRawData();
                  raw.clear();
                  raw.putAll(mergedData);
  -               if (workspace.isVersioningImplicit())
  +               if (wrappedNode.isVersioningImplicit())
                  {
  +                  if (trace) log.trace("Versioning is implicit; incrementing.");
                     current.setVersion(((DefaultDataVersion) wrappedNode.getVersion()).increment());
                  }
                  else
  
  
  
  1.32      +17 -9     JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticCreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- OptimisticCreateIfNotExistsInterceptor.java	20 Nov 2006 03:53:54 -0000	1.31
  +++ OptimisticCreateIfNotExistsInterceptor.java	12 Dec 2006 14:51:44 -0000	1.32
  @@ -7,16 +7,12 @@
   package org.jboss.cache.interceptors;
   
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
   import org.jboss.cache.OptimisticTransactionEntry;
  -import org.jboss.cache.OptimisticTreeNode;
   import org.jboss.cache.TransactionEntry;
  -import org.jboss.cache.TreeCacheProxyImpl;
  -import org.jboss.cache.TreeNode;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
  @@ -193,6 +189,9 @@
                  Node tempNode = workspaceNode.createChild(childName, copy, workspaceNode.getNode(), cache, versionToPassIn);
   
                  childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempNode, workspace);
  +               childWorkspaceNode.setVersioningImplicit(versionToPassIn == null || !isTargetFqn);
  +               if (log.isTraceEnabled())
  +                  log.trace("setting versioning of " + childWorkspaceNode.getFqn() + " to be " + (childWorkspaceNode.isVersioningImplicit() ? "implicit" : "explicit"));
   
                  // now add the wrapped child node into the transaction space
                  workspace.addNode(childWorkspaceNode);
  @@ -210,11 +209,20 @@
                  if (childWorkspaceNode == null || childWorkspaceNode.isDeleted())
                  {
                     if (debug)
  +                     log.debug("Child node " + tempchildNode.getFqn() + " doesn't exist in workspace or has been deleted.  Adding to workspace in gtx " + gtx);
  +                  childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempchildNode, workspace);
  +                  if (isTargetFqn && !workspace.isVersioningImplicit())
                     {
  -                     log.debug("Child node doesn't exist in workspace or has been deleted");
  +                     childWorkspaceNode.setVersion(version);
  +                     childWorkspaceNode.setVersioningImplicit(false);
                     }
  -                  childWorkspaceNode = NodeFactory.getInstance().createWorkspaceNode(tempchildNode, workspace);
  -                  if (!workspace.isVersioningImplicit()) childWorkspaceNode.setVersion(version);
  +                  else
  +                  {
  +                     childWorkspaceNode.setVersioningImplicit(true);
  +                  }
  +                  if (log.isTraceEnabled())
  +                     log.trace("setting versioning of " + childWorkspaceNode.getFqn() + " to be " + (childWorkspaceNode.isVersioningImplicit() ? "implicit" : "explicit"));
  +
                  }
                  else
                  {
  
  
  
  1.35      +21 -18    JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- OptimisticNodeInterceptor.java	20 Nov 2006 05:09:15 -0000	1.34
  +++ OptimisticNodeInterceptor.java	12 Dec 2006 14:51:44 -0000	1.35
  @@ -7,12 +7,10 @@
   package org.jboss.cache.interceptors;
   
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.TreeNode;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.factories.NodeFactory;
  @@ -65,7 +63,6 @@
            WorkspaceNode parent = getOrCreateWorkspaceNode(parentFqn, workspace);
            WorkspaceNode node = getOrCreateWorkspaceNode(nodeFqn, workspace);
   
  -
            if (log.isTraceEnabled()) log.trace("Parent: " + parent);
            if (log.isTraceEnabled()) log.trace("Node: " + node);
   
  @@ -86,26 +83,32 @@
            // this in the transaction interceptor
            WorkspaceNode workspaceNode = getOrCreateWorkspaceNode(getFqn(args), workspace);
   
  +
  +         if (workspaceNode != null)
  +         {
            // use explicit versioning
            if (ctx.getOptionOverrides() != null && ctx.getOptionOverrides().getDataVersion() != null)
            {
               workspace.setVersioningImplicit(false);
               DataVersion version = ctx.getOptionOverrides().getDataVersion();
  -            // "fail-more-silently" patch thanks to Owen Taylor - JBCACHE-767
   
  -            // also, if this is a "remove", do we care if the node didn't exist?
  -
  -            if (workspaceNode != null)
  -            {
                  workspaceNode.setVersion(version);
  +               if (log.isTraceEnabled())
  +                  log.trace("Setting versioning for node " + workspaceNode.getFqn() + " to explicit");
  +               workspaceNode.setVersioningImplicit(false);
               }
               else
               {
  -               if ((ctx.getOptionOverrides() == null || !ctx.getOptionOverrides().isFailSilently()) && MethodDeclarations.isPutMethod(m.getMethodId()))
  -               {
  -                  throw new CacheException("Unable to set node version for " + getFqn(args) + ", node is null.");
  +               if (log.isTraceEnabled())
  +                  log.trace("Setting versioning for node " + workspaceNode.getFqn() + " to implicit");
  +               workspaceNode.setVersioningImplicit(true);
                  }
               }
  +         else
  +         {
  +            // "fail-more-silently" patch thanks to Owen Taylor - JBCACHE-767
  +            if ((ctx.getOptionOverrides() == null || !ctx.getOptionOverrides().isFailSilently()) && MethodDeclarations.isPutMethod(m.getMethodId()))
  +               throw new CacheException("Unable to set node version for " + getFqn(args) + ", node is null.");
            }
   
            switch (m.getMethodId())
  @@ -431,7 +434,7 @@
            {
               return null;// seems to happen quite a bit
            }
  -         workspaceNode = NodeFactory.getInstance().createWorkspaceNode((TreeNode)node, workspace);
  +         workspaceNode = NodeFactory.getInstance().createWorkspaceNode((TreeNode) node, workspace);
            workspace.addNode(workspaceNode);
         }
         // the node has been deleted dude!
  
  
  
  1.36      +2 -6      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -b -r1.35 -r1.36
  --- PessimisticLockInterceptor.java	20 Nov 2006 12:04:43 -0000	1.35
  +++ PessimisticLockInterceptor.java	12 Dec 2006 14:51:44 -0000	1.36
  @@ -11,14 +11,11 @@
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.NodeImpl;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCacheProxyImpl;
  -import org.jboss.cache.lock.IdentityLock;
   import org.jboss.cache.lock.IsolationLevel;
  -import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.lock.LockingException;
  +import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.lock.TimeoutException;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
  @@ -37,7 +34,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.35 2006/11/20 12:04:43 genman Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.36 2006/12/12 14:51:44 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -366,7 +363,6 @@
         }
      }
   
  -
      /**
       * Remove all locks held by <tt>tx</tt>, remove the transaction from the transaction table
       *
  
  
  
  1.32      +10 -3     JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticReplicationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- OptimisticReplicationInterceptor.java	8 Dec 2006 18:49:17 -0000	1.31
  +++ OptimisticReplicationInterceptor.java	12 Dec 2006 14:51:44 -0000	1.32
  @@ -83,7 +83,7 @@
                     //if we have an exception then the remote methods failed
                     if (retval instanceof Throwable)
                     {
  -                     throw(Throwable) retval;
  +                     throw (Throwable) retval;
                     }
                  }
                  break;
  @@ -297,14 +297,21 @@
      private DataVersion getVersionToBroadcast(TransactionWorkspace w, Fqn f)
      {
         WorkspaceNode n = w.getNode(f);
  -      if (n == null) return null;
  -      if (w.isVersioningImplicit())
  +      if (n == null)
  +      {
  +         if (log.isTraceEnabled()) log.trace("Fqn " + f + " not found in workspace; not using a data version.");
  +         return null;
  +      }
  +      if (n.isVersioningImplicit())
         {
            DefaultDataVersion v = (DefaultDataVersion) n.getVersion();
  +         if (log.isTraceEnabled())
  +            log.trace("Fqn " + f + " has implicit versioning.  Broadcasting an incremented version.");
            return v.increment();
         }
         else
         {
  +         if (log.isTraceEnabled()) log.trace("Fqn " + f + " has explicit versioning.  Broadcasting the version as-is.");
            return n.getVersion();
         }
      }
  
  
  


From msurtani at jboss.com  Tue Dec 12 09:51:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 12 Dec 2006 09:51:44 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic      ...
Message-ID: <E1Gu8yu-0006L1-IQ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/12 09:51:44

  Modified:    src/org/jboss/cache/optimistic      WorkspaceNode.java
                        TransactionWorkspaceImpl.java
                        TransactionWorkspace.java WorkspaceNodeImpl.java
                        DefaultDataVersion.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.16      +21 -18    JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- WorkspaceNode.java	20 Nov 2006 03:53:55 -0000	1.15
  +++ WorkspaceNode.java	12 Dec 2006 14:51:44 -0000	1.16
  @@ -7,10 +7,9 @@
   package org.jboss.cache.optimistic;
   
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.TreeNode;
  -import org.jboss.cache.Node;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.Cache;
  +import org.jboss.cache.Node;
  +import org.jboss.cache.TreeNode;
   
   import java.util.Map;
   import java.util.Set;
  @@ -51,4 +50,8 @@
       public void markAsCreated();
   
       public Node createChild(Object child_name, Fqn fqn, Node parent, CacheSPI cache, DataVersion version);
  +
  +   boolean isVersioningImplicit();
  +
  +   void setVersioningImplicit(boolean b);
   }
  
  
  
  1.15      +7 -7      JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspaceImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionWorkspaceImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspaceImpl.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- TransactionWorkspaceImpl.java	8 Dec 2006 18:49:18 -0000	1.14
  +++ TransactionWorkspaceImpl.java	12 Dec 2006 14:51:44 -0000	1.15
  @@ -23,18 +23,18 @@
   public class TransactionWorkspaceImpl implements TransactionWorkspace
   {
   
  -   private Map nodes;
  +   private Map<Fqn, WorkspaceNode> nodes;
      private boolean versioningImplicit = true;
   
      public TransactionWorkspaceImpl()
      {
  -      nodes = new ConcurrentHashMap();
  +      nodes = new ConcurrentHashMap<Fqn, WorkspaceNode>();
      }
   
      /**
       * Returns the nodes.
       */
  -   public Map getNodes()
  +   public Map<Fqn, WorkspaceNode> getNodes()
      {
         return nodes;
      }
  @@ -42,14 +42,14 @@
      /**
       * Sets the nodes.
       */
  -   public void setNodes(Map nodes)
  +   public void setNodes(Map<Fqn, WorkspaceNode> nodes)
      {
         this.nodes = nodes;
      }
   
      public WorkspaceNode getNode(Fqn fqn)
      {
  -      return (WorkspaceNode) nodes.get(fqn);
  +      return nodes.get(fqn);
      }
   
      public void addNode(WorkspaceNode node)
  @@ -62,9 +62,9 @@
         return nodes.remove(fqn);
      }
   
  -   public SortedMap getNodesAfter(Fqn fqn)
  +   public SortedMap<Fqn, WorkspaceNode> getNodesAfter(Fqn fqn)
      {
  -      SortedMap sm = new TreeMap();
  +      SortedMap<Fqn, WorkspaceNode> sm = new TreeMap<Fqn, WorkspaceNode>();
         sm.putAll(nodes);
         return sm.tailMap(fqn);
      }
  
  
  
  1.12      +2 -2      JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspace.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionWorkspace.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspace.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- TransactionWorkspace.java	20 Sep 2006 16:28:58 -0000	1.11
  +++ TransactionWorkspace.java	12 Dec 2006 14:51:44 -0000	1.12
  @@ -25,12 +25,12 @@
      /**
       * @return Returns a map of {@link WorkspaceNode}s, keyed on {@link Fqn}
       */
  -   public Map getNodes();
  +   public Map<Fqn, WorkspaceNode> getNodes();
   
      /**
       * @param nodes The nodes to set. Takes {@link WorkspaceNode}s.
       */
  -   public void setNodes(Map nodes);
  +   public void setNodes(Map<Fqn, WorkspaceNode> nodes);
   
      public WorkspaceNode getNode(Fqn fqn);
   
  
  
  
  1.30      +24 -14    JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- WorkspaceNodeImpl.java	29 Nov 2006 22:10:22 -0000	1.29
  +++ WorkspaceNodeImpl.java	12 Dec 2006 14:51:44 -0000	1.30
  @@ -8,7 +8,6 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.Cache;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
  @@ -21,8 +20,8 @@
   import org.jboss.cache.TreeNode;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.lock.IdentityLock;
  -import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.lock.LockingException;
  +import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.lock.TimeoutException;
   
   import java.util.Collections;
  @@ -51,6 +50,7 @@
      private boolean created;
      private Map<Object, Node> optimisticChildNodeMap;
      private Map optimisticDataMap;
  +   private boolean versioningImplicit;
   
      /**
       * Constructs with a node and workspace.
  @@ -192,7 +192,7 @@
         // if not we need to create it
         if (child == null)
         {
  -         child = NodeFactory.getInstance().createNodeOfType(parent, child_name, fqn, parent, (Map)null, cache, version);
  +         child = NodeFactory.getInstance().createNodeOfType(parent, child_name, fqn, parent, (Map) null, cache, version);
            optimisticChildNodeMap.put(child_name, child);
         }
         if (log.isTraceEnabled())
  @@ -205,6 +205,16 @@
   
      }
   
  +   public boolean isVersioningImplicit()
  +   {
  +      return versioningImplicit;
  +   }
  +
  +   public void setVersioningImplicit(boolean b)
  +   {
  +      versioningImplicit = b;
  +   }
  +
      //this needs to be changed to return wrapped node
      public Node getChild(Object childName)
      {
  
  
  
  1.6       +20 -9     JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- DefaultDataVersion.java	11 Dec 2006 21:14:35 -0000	1.5
  +++ DefaultDataVersion.java	12 Dec 2006 14:51:44 -0000	1.6
  @@ -6,21 +6,25 @@
    */
   package org.jboss.cache.optimistic;
   
  +import java.io.Externalizable;
  +import java.io.IOException;
  +import java.io.ObjectInput;
  +import java.io.ObjectOutput;
  +
   /**
    * The default implementation of a DataVersion, uses a <code>long</code> to
    * compare versions.
    * This class is immutable.
  + * <p/>
  + * Also note that this is meant to control implicit, internal versioning.  Do not attempt to instantiate or use instances
  + * of this class explicitly, via the {@link org.jboss.cache.config.Option#setDataVersion(DataVersion)} API, as it WILL
  + * break things.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  -public class DefaultDataVersion implements DataVersion
  +public class DefaultDataVersion implements DataVersion, Externalizable
   {
  -
  -   /**
  -    * Since it's serializable...
  -    */
  -   private static final long serialVersionUID = 6556186205712692626L;
  -
  +   private static final long serialVersionUID = -6896315742831861046L;
      /**
       * Version zero.
       * Assign this as the first version to your data.
  @@ -41,8 +45,6 @@
   
      /**
       * Constructs with version 0.
  -    *
  -    * @deprecated use {@link #ZERO} constant
       */
      public DefaultDataVersion()
      {
  @@ -106,4 +108,13 @@
         return version;
      }
   
  +   public void writeExternal(ObjectOutput objectOutput) throws IOException
  +   {
  +      objectOutput.writeLong(version);
  +   }
  +
  +   public void readExternal(ObjectInput objectInput) throws IOException, ClassNotFoundException
  +   {
  +      version = objectInput.readLong();
  +   }
   }
  
  
  


From msurtani at jboss.com  Tue Dec 12 09:51:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 12 Dec 2006 09:51:44 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options ...
Message-ID: <E1Gu8yu-0006LB-N2@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/12 09:51:44

  Modified:    tests/functional/org/jboss/cache/options  
                        ExplicitVersionsTest.java
                        ExplicitVersionsReplTest.java
  Log:
  JBCACHE-894
  
  Revision  Changes    Path
  1.8       +13 -0     JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ExplicitVersionsTest.java	11 Nov 2006 19:55:19 -0000	1.7
  +++ ExplicitVersionsTest.java	12 Dec 2006 14:51:44 -0000	1.8
  @@ -112,6 +112,19 @@
         }
      }
   
  +   public void testExplicitVersionOnLeaf() throws Exception
  +   {
  +      cache.put("/org/domain/Entity", null);
  +      assertEquals(1, ((DefaultDataVersion) ((OptimisticTreeNode) cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  +
  +      TestVersion v = new TestVersion("Arse");
  +      cache.getInvocationContext().getOptionOverrides().setDataVersion(v);
  +      cache.put(Fqn.fromString("/org/domain/Entity/EntityInstance#1"), "k", "v");
  +
  +      assertEquals(2, ((DefaultDataVersion) ((OptimisticTreeNode) cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((OptimisticTreeNode) cache.get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +   }
  +
   }
   
   class TestVersion implements DataVersion
  
  
  
  1.5       +18 -0     JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ExplicitVersionsReplTest.java	6 Dec 2006 16:28:37 -0000	1.4
  +++ ExplicitVersionsReplTest.java	12 Dec 2006 14:51:44 -0000	1.5
  @@ -298,5 +298,23 @@
         cache[0].getTransactionManager().commit();
      }
   
  +   public void testExplicitVersionOnLeaf() throws Exception
  +   {
  +      cache[0].put("/org/domain/Entity", null);
  +      assertEquals(1, ((DefaultDataVersion) ((OptimisticTreeNode) cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(1, ((DefaultDataVersion) ((OptimisticTreeNode) cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +
  +      TestVersion v = new TestVersion("Arse");
  +      cache[0].getInvocationContext().getOptionOverrides().setDataVersion(v);
  +
  +      cache[0].put(Fqn.fromString("/org/domain/Entity/EntityInstance#1"), "k", "v");
  +
  +      assertEquals(2, ((DefaultDataVersion) ((OptimisticTreeNode) cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((OptimisticTreeNode) cache[0].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +      assertEquals(2, ((DefaultDataVersion) ((OptimisticTreeNode) cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((OptimisticTreeNode) cache[1].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +
  +   }
  +
   
   }
  
  
  


From msurtani at jboss.com  Tue Dec 12 10:08:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 12 Dec 2006 10:08:05 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1Gu9Ej-0006l0-O3@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/12 10:08:05

  Modified:    src/org/jboss/cache/interceptors 
                        InvocationContextInterceptor.java
  Log:
  Cleaned up some stuff around resetting bypassInterceptorChain option
  
  Revision  Changes    Path
  1.12      +1 -1      JBossCache/src/org/jboss/cache/interceptors/InvocationContextInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvocationContextInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/InvocationContextInterceptor.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- InvocationContextInterceptor.java	12 Dec 2006 14:51:44 -0000	1.11
  +++ InvocationContextInterceptor.java	12 Dec 2006 15:08:05 -0000	1.12
  @@ -58,7 +58,7 @@
   
               if (optionOverride.isBypassInterceptorChain())
               {
  -               log.trace("Interceptor chain bypass option set for call; skipping interceptyor chain and proceeding to last interceptor.");
  +               log.trace("Interceptor chain bypass option set for call; skipping interceptor chain and proceeding to last interceptor.");
                  return getLast().invoke(call);
               }
            }
  
  
  


From msurtani at jboss.com  Tue Dec 12 10:08:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 12 Dec 2006 10:08:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gu9Ek-0006l7-1s@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/12 10:08:06

  Modified:    src/org/jboss/cache  NodeImpl.java
  Log:
  Cleaned up some stuff around resetting bypassInterceptorChain option
  
  Revision  Changes    Path
  1.24      +85 -48    JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- NodeImpl.java	11 Dec 2006 21:14:34 -0000	1.23
  +++ NodeImpl.java	12 Dec 2006 15:08:05 -0000	1.24
  @@ -274,6 +274,8 @@
      {
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
  +         try
  +         {
            if (data == null)
            {
               return;
  @@ -293,8 +295,12 @@
               }
               data().putAll(data);
            }
  +         }
  +         finally
  +         {
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
         }
  +      }
         else
         {
            // TODO add erase option to Cache (?)
  @@ -311,11 +317,17 @@
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
            Object result;
  +         try
  +         {
            synchronized (this)
            {
               result = data().put(key, value);
            }
  +         }
  +         finally
  +         {
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +         }
            return result;
         }
         else
  @@ -401,6 +413,8 @@
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
            Object result;
  +         try
  +         {
            synchronized (this)
            {
               if (data == null)
  @@ -412,7 +426,11 @@
                  result = data.remove(key);
               }
            }
  +         }
  +         finally
  +         {
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +         }
            return result;
         }
         else
  @@ -487,6 +505,8 @@
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
            Node newNode = this;
  +         try
  +         {
            GlobalTransaction gtx = cache.getInvocationContext().getGlobalTransaction();
   
            if (f.size() == 1)
  @@ -503,8 +523,11 @@
                  currentParent = newNode;
               }
            }
  -
  +         }
  +         finally
  +         {
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +         }
            return newNode;
         }
         else
  @@ -519,6 +542,8 @@
      {
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
  +         try
  +         {
            synchronized (this)
            {
               if (data != null)
  @@ -527,6 +552,11 @@
               }
            }
         }
  +         finally
  +         {
  +            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +         }
  +      }
         else
         {
            ((TreeCacheProxyImpl) cache).treeCache.removeData(getFqn());
  @@ -537,10 +567,17 @@
      {
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
  +         try
  +         {
            Node child = getChild(fqn.getLast());
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
            return child;
         }
  +         finally
  +         {
  +            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +         }
  +      }
         else
         {
            return cache.getChild(new Fqn(getFqn(), fqn));
  
  
  


From reuw987984 at linuxmail.org  Tue Dec 12 10:35:37 2006
From: reuw987984 at linuxmail.org (reuw987984 at linuxmail.org)
Date: Tue, 12 Dec 2006 10:35:37 -0500
Subject: [jboss-cvs] =?utf-8?b?woLDmcKCw7HCgsOGwoLDicKTZMKYYsKCw7DCgsKp?=
	=?utf-8?b?woLCr8KCw4TCgsKtwoLDqsKCw5zCgsK5woLDscKCwqnCgUg=?=
Message-ID: 20061213005117.45532mail@mail.shueknasoeksenksdjsanjaensjeeanfkdk.com

?????????????B???R?????????????B
?????????????????????????????A?????f???????????d?b???????????????????????????????????????H
http://5596.jp/?kiarh
???????????????????????A?????U???????????????????????????????????B
?U????????12???N???B?N?????????????????????????????????????????????A?????S?N?????X???Q?????????B
?????????????????????????????????Y?????????????A?????g?L???L???????????????H
???????????????????????????????????A?????????d?b?????????????v???????[???????????B
?????g???d?b?????????????A???????C?????????????????????v?????B
???d?b?A?????????????B

???R??





From msurtani at jboss.com  Tue Dec 12 11:45:56 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 12 Dec 2006 11:45:56 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/aop/statetransfer ...
Message-ID: <E1GuAlQ-0008Ut-8y@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/12 11:45:56

  Modified:    tests/functional/org/jboss/cache/aop/statetransfer  Tag:
                        Branch_JBossCache_1_4_0
                        StateTransferAopTestBase.java
  Log:
  wc
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.15.2.1  +36 -13    JBossCache/tests/functional/org/jboss/cache/aop/statetransfer/Attic/StateTransferAopTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferAopTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/aop/statetransfer/Attic/StateTransferAopTestBase.java,v
  retrieving revision 1.15
  retrieving revision 1.15.2.1
  diff -u -b -r1.15 -r1.15.2.1
  --- StateTransferAopTestBase.java	5 May 2006 12:06:57 -0000	1.15
  +++ StateTransferAopTestBase.java	12 Dec 2006 16:45:56 -0000	1.15.2.1
  @@ -306,12 +306,16 @@
       * 
       * @throws Exception
       */
  -   public void testConcurrentActivationSync() throws Exception
  -   { 
  -      log.info("Enter testConcurrentActivationSync");
         
  -      concurrentActivationTest(true);
  -   }
  +   // commented out since concurrent activations will cause deadlocks and then timeouts since JBCACHE-875.
  +   // Correctness over performance. - Manik
  +   
  +//   public void testConcurrentActivationSync() throws Exception
  +//   {
  +//      log.info("Enter testConcurrentActivationSync");
  +//
  +//      concurrentActivationTest(true);
  +//   }
      
      /**
       * Tests concurrent activation of the same subtree by multiple nodes in a 
  @@ -418,13 +422,17 @@
       * 
       * @throws Exception
       */
  -   public void testConcurrentUseSync() throws Exception
  -   { 
  -      log.info("Enter testConcurrentUseSync");
         
  -      concurrentUseTest(true);
  -   }
  +   // commented out since concurrent activations will cause deadlocks and then timeouts since JBCACHE-875.
  +   // Correctness over performance. - Manik
      
  +//   public void testConcurrentUseSync() throws Exception
  +//   {
  +//      log.info("Enter testConcurrentUseSync");
  +//
  +//      concurrentUseTest(true);
  +//   }
  +//
      /**
       * Tests partial state transfer under heavy concurrent load and REPL_ASYNC.
       * See <code>concurrentUseTest</code> for details.
  @@ -474,6 +482,10 @@
            {
               stressors[i] = new CacheStressor(semaphore, names[i], sync);
               caches[i + 1] = stressors[i].getTreeCache();
  +            stressors[i].getTreeCache().put("/" + names[i], null);
  +         }
  +         for (int i = 0; i < count; i++)
  +         {
               stressors[i].start();
               // Give each one a chance to stabilize
               TestingUtil.sleepThread(100);
  @@ -774,6 +786,17 @@
         {
            try
            {
  +            TransactionManager m = cache.getTransactionManager();
  +            try
  +            {
  +               if (m!= null && m.getTransaction() != null)
  +               {
  +                  m.rollback();
  +               }
  +            }
  +            catch (Exception e)
  +            {
  +            }
               cache.stopService();
               cache.destroyService();
            }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 11:57:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 11:57:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r58996 - in projects/microcontainer/trunk:
	kernel/src/tests/org/jboss/test kernel/src/tests/org/jboss/test/ioc
	kernel/src/tests/org/jboss/test/ioc/test
	kernel/src/tests/org/jboss/test/javabean/test
	spring-int/src/main/org/jboss/spring/deployment/xml
	spring-int/src/resources spring-int/src/resources/org
	spring-int/src/resources/org/jboss
	spring-int/src/resources/org/jboss/test
	spring-int/src/resources/org/jboss/test/spring
	spring-int/src/resources/org/jboss/test/spring/test
	spring-int/src/resources/schema spring-int/src/tests
	spring-int/src/tests/org spring-int/src/tests/org/jboss
	spring-int/src/tests/org/jboss/test
	spring-int/src/tests/org/jboss/test/spring
	spring-int/src/tests/org/jboss/test/spring/support
	spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GuAwS-0000Dm-Ct@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 11:56:59 -0500 (Tue, 12 Dec 2006)
New Revision: 58996

Added:
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/IoCTestDelegate.java
   projects/microcontainer/trunk/spring-int/src/resources/org/
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTest.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java
Modified:
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AbstractJavaBeanTest.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/InstantiateTestCase.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestDelegate.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
   projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
Log:
JBMICROCONT-26; inital tests - not yet working

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,132 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.ioc.test;
+
+import java.net.URL;
+
+import org.jboss.test.AbstractTestCaseWithSetup;
+import org.jboss.test.AbstractTestDelegate;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public abstract class AbstractIoCTest extends AbstractTestCaseWithSetup
+{
+   protected String rootName = getRootName();
+
+   /**
+    * Create a new AbstractJBossXBTest.
+    *
+    * @param name the name of the test
+    */
+   public AbstractIoCTest(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Unmarshal some xml
+    *
+    * @param name the name
+    * @param expected the expected type
+    * @return the unmarshalled object
+    * @throws Exception for any error
+    */
+   protected <T> T unmarshal(String name, Class<T> expected) throws Exception
+   {
+      Object object = unmarshal(name);
+      if (object == null)
+         fail("No object from " + name);
+      assertTrue("Object '" + object + "' cannot be assigned to " + expected.getName(), expected.isAssignableFrom(object.getClass()));
+      return expected.cast(object);
+   }
+
+   /**
+    * Unmarshal some xml
+    *
+    * @param name the name
+    * @return the unmarshalled object
+    * @throws Exception for any error
+    */
+   protected Object unmarshal(String name) throws Exception
+   {
+      String url = findXML(name);
+      return getJBossXBDelegate().unmarshal(url);
+   }
+
+   /**
+    * Find the xml
+    *
+    * @param name the name
+    * @return the url of the xml
+    */
+   protected String findXML(String name)
+   {
+      URL url = getResource(name);
+      if (url == null)
+         fail(name + " not found");
+      return url.toString();
+   }
+
+   protected IoCTestDelegate getJBossXBDelegate()
+   {
+      return (IoCTestDelegate) getDelegate();
+   }
+
+   /**
+    * Setup the test delegate
+    *
+    * @param clazz the class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      return new IoCTestDelegate(clazz);
+   }
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+      configureLogging();
+   }
+
+   /**
+    * Get the package root name
+    *
+    * @return the root name
+    */
+   protected String getRootName()
+   {
+      String longName = getClass().getName();
+      int dot = longName.lastIndexOf('.');
+      if (dot != -1)
+         return longName.substring(dot + 1);
+      return longName;
+   }
+
+   protected void configureLogging()
+   {
+      //enableTrace("org.jboss.xb");
+   }
+}
+

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/IoCTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/IoCTestDelegate.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/IoCTestDelegate.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,84 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.ioc.test;
+
+import org.jboss.xb.binding.UnmarshallerFactory;
+import org.jboss.xb.binding.Unmarshaller;
+import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
+import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
+import org.jboss.test.AbstractTestDelegate;
+
+/**
+ * Test delegate support for other IoC / XML bindings than MC's.
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class IoCTestDelegate extends AbstractTestDelegate
+{
+   /** The unmarshaller factory */
+   protected UnmarshallerFactory unmarshallerFactory;
+
+   /** The resolver */
+   protected SchemaBindingResolver resolver;
+
+   /**
+    * Create a new JBossXBTestDelegate.
+    *
+    * @param clazz the test class
+    */
+   public IoCTestDelegate(Class clazz)
+   {
+      super(clazz);
+   }
+
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      unmarshallerFactory = UnmarshallerFactory.newInstance();
+      resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
+   }
+
+   /**
+    * Unmarshal an object
+    *
+    * @param url the url
+    * @return the object
+    * @throws Exception for any error
+    */
+   public Object unmarshal(String url) throws Exception
+   {
+      long start = System.currentTimeMillis();
+      Unmarshaller unmarshaller = unmarshallerFactory.newUnmarshaller();
+      log.debug("Initialized parsing in " + (System.currentTimeMillis() - start) + "ms");
+      try
+      {
+         Object result = unmarshaller.unmarshal(url, resolver);
+         log.debug("Total parse for " + url + " took " + (System.currentTimeMillis() - start) + "ms");
+         return result;
+      }
+      catch (Exception e)
+      {
+         log.debug("Error during parsing: " + url, e);
+         throw e;
+      }
+   }
+}

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AbstractJavaBeanTest.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AbstractJavaBeanTest.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AbstractJavaBeanTest.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -21,10 +21,8 @@
 */
 package org.jboss.test.javabean.test;
 
-import java.net.URL;
-
-import org.jboss.test.AbstractTestCaseWithSetup;
 import org.jboss.test.AbstractTestDelegate;
+import org.jboss.test.ioc.test.AbstractIoCTest;
 
 /**
  * AbstractJavaBeanTest.
@@ -32,10 +30,8 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class AbstractJavaBeanTest extends AbstractTestCaseWithSetup
+public class AbstractJavaBeanTest extends AbstractIoCTest
 {
-   protected String rootName = getRootName();
-   
    /**
     * Create a new AbstractJBossXBTest.
     * 
@@ -47,50 +43,6 @@
    }
 
    /**
-    * Unmarshal some xml
-    * 
-    * @param name the name
-    * @param expected the expected type
-    * @return the unmarshalled object
-    * @throws Exception for any error
-    */
-   protected Object unmarshal(String name, Class<?> expected) throws Exception
-   {
-      Object object = unmarshal(name);
-      if (object == null)
-         fail("No object from " + name);
-      assertTrue("Object '" + object + "' cannot be assigned to " + expected.getName(), expected.isAssignableFrom(object.getClass()));
-      return object;
-   }
-   
-   /**
-    * Unmarshal some xml
-    * 
-    * @param name the name
-    * @return the unmarshalled object
-    * @throws Exception for any error
-    */
-   protected Object unmarshal(String name) throws Exception
-   {
-      String url = findXML(name);
-      return getJBossXBDelegate().unmarshal(url);
-   }
-   
-   /**
-    * Find the xml
-    * 
-    * @param name the name
-    * @return the url of the xml
-    */
-   protected String findXML(String name)
-   {
-      URL url = getResource(name);
-      if (url == null)
-         fail(name + " not found");
-      return url.toString();
-   }
-
-   /**
     * Setup the test delegate
     * 
     * @param clazz the class
@@ -102,33 +54,4 @@
       return new JavaBeanTestDelegate(clazz);
    }
 
-   protected JavaBeanTestDelegate getJBossXBDelegate()
-   {
-      return (JavaBeanTestDelegate) getDelegate();
-   }
-   
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-      configureLogging();
-   }
-   
-   /**
-    * Get the package root name
-    * 
-    * @return the root name
-    */
-   protected String getRootName()
-   {
-      String longName = getClass().getName();
-      int dot = longName.lastIndexOf('.');
-      if (dot != -1)
-         return longName.substring(dot + 1);
-      return longName;
-   }
-   
-   protected void configureLogging()
-   {
-      //enableTrace("org.jboss.xb");
-   }
 }

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/InstantiateTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/InstantiateTestCase.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/InstantiateTestCase.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -35,7 +35,7 @@
 {
    public void testInstantiate() throws Exception
    {
-      SimpleBean bean = (SimpleBean) unmarshal("TestInstantiate.xml", SimpleBean.class);
+      SimpleBean bean = unmarshal("TestInstantiate.xml", SimpleBean.class);
       assertEquals("()", bean.getConstructorUsed());
    }
    

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestDelegate.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestDelegate.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -21,11 +21,7 @@
 */
 package org.jboss.test.javabean.test;
 
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
-import org.jboss.xb.binding.Unmarshaller;
-import org.jboss.xb.binding.UnmarshallerFactory;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
+import org.jboss.test.ioc.test.IoCTestDelegate;
 
 /**
  * JavaBeanTestDelegate.
@@ -33,17 +29,11 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class JavaBeanTestDelegate extends AbstractTestDelegate
+public class JavaBeanTestDelegate extends IoCTestDelegate
 {
-   /** The unmarshaller factory */
-   protected UnmarshallerFactory unmarshallerFactory;
-
-   /** The resolver */
-   protected SchemaBindingResolver resolver;
-
    /**
     * Create a new JBossXBTestDelegate.
-    * 
+    *
     * @param clazz the test class
     */
    public JavaBeanTestDelegate(Class clazz)
@@ -51,35 +41,4 @@
       super(clazz);
    }
 
-   public void setUp() throws Exception
-   {
-      super.setUp();
-      unmarshallerFactory = UnmarshallerFactory.newInstance();
-      resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
-   }
-
-   /**
-    * Unmarshal an object
-    * 
-    * @param url the url
-    * @return the object
-    * @throws Exception for any error
-    */
-   public Object unmarshal(String url) throws Exception
-   {
-      long start = System.currentTimeMillis();
-      Unmarshaller unmarshaller = unmarshallerFactory.newUnmarshaller();
-      log.debug("Initialized parsing in " + (System.currentTimeMillis() - start) + "ms");
-      try
-      {
-         Object result = unmarshaller.unmarshal(url, resolver);
-         log.debug("Total parse for " + url + " took " + (System.currentTimeMillis() - start) + "ms");
-         return result;
-      }
-      catch (Exception e)
-      {
-         log.debug("Error during parsing: " + url, e);
-         throw e;
-      }
-   }
 }

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -46,7 +46,7 @@
 {
    private static DateFormat dateFormat = new SimpleDateFormat("EEE MMM d HH:mm:ss z yyyy");
    
-   String stringValue =  new String("StringValue");
+   String stringValue =  "StringValue";
    Byte byteValue = new Byte("12");
    Boolean booleanValue = Boolean.TRUE;
    // TODO character
@@ -62,7 +62,7 @@
 
    public void testConfigure() throws Exception
    {
-      SimpleBean bean = (SimpleBean) unmarshal("TestConfigure.xml", SimpleBean.class);
+      SimpleBean bean = unmarshal("TestConfigure.xml", SimpleBean.class);
       assertEquals("()", bean.getConstructorUsed());
       
       assertEquals(stringValue, bean.getAString());

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -35,7 +35,7 @@
    /**
     * The namespace
     */
-   public static final String SPRING_DEPLOYER_NS = "http://www.springframework.org/schema/beans";
+   public static final String SPRING_DEPLOYER_NS = "urn:jboss:spring-beans:2.0";
 
    /**
     * The beans binding

Added: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<bean xmlns="urn:jboss:spring-beans:2.0" class="org.jboss.test.spring.support.SimpleBean">
+   <constructor-arg index="2">SpringBean</constructor-arg>
+   <constructor-arg index="0">1</constructor-arg>
+   <constructor-arg index="1">3.1415</constructor-arg>
+   <property name="list">
+      <list>
+         <value>one</value>
+         <value>two</value>
+         <value>three</value>
+      </list>
+   </property>
+   <property name="set">
+      <set>
+         <value>one</value>
+         <value>two</value>
+         <value>one</value>
+      </set>
+   </property>
+   <property name="map">
+      <entry>
+         <key>
+            <value>key</value>
+         </key>
+         <value>key</value>
+      </entry>
+   </property>
+</bean>

Modified: projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-12 16:56:59 UTC (rev 58996)
@@ -2,9 +2,13 @@
 <!-- A prototype Spring xsd schema for the pojoserver xml deployer
 $Id: mc-spring-beans_2_0.xsd 56471 2006-08-31 10:44:05 +0200 (Pon, 11 dec 2006) alesj $
  -->
-<xsd:schema xmlns="http://www.springframework.org/schema/beans"
-            xmlns:xsd="http://www.w3.org/2001/XMLSchema"
-            targetNamespace="http://www.springframework.org/schema/beans">
+<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+   targetNamespace="urn:jboss:spring-beans:2.0"
+   xmlns="urn:jboss:spring-beans:2.0"
+   elementFormDefault="qualified"
+   attributeFormDefault="unqualified"
+   version="1.0"
+>
 
    <xsd:import namespace="http://www.w3.org/XML/1998/namespace"/>
 

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,82 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.support;
+
+import java.util.List;
+import java.util.Set;
+import java.util.Map;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SimpleBean
+{
+
+   private int x;
+   private double y;
+   private String s;
+   private List list;
+   private Set set;
+   private Map map;
+
+   public SimpleBean()
+   {
+   }
+
+   public SimpleBean(int x, double y, String s)
+   {
+      this.x = x;
+      this.y = y;
+      this.s = s;
+   }
+
+   public List getList()
+   {
+      return list;
+   }
+
+   public void setList(List list)
+   {
+      this.list = list;
+   }
+
+   public Set getSet()
+   {
+      return set;
+   }
+
+   public void setSet(Set set)
+   {
+      this.set = set;
+   }
+
+   public Map getMap()
+   {
+      return map;
+   }
+
+   public void setMap(Map map)
+   {
+      this.map = map;
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,54 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import junit.framework.Test;
+import org.jboss.test.spring.support.SimpleBean;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class InstantiateSpringTestCase extends TempSpringSchemaTest
+{
+
+   public InstantiateSpringTestCase(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test
+    *
+    * @return the test
+    */
+   public static Test suite()
+   {
+      return suite(InstantiateSpringTestCase.class);
+   }
+
+   public void testInstantiate() throws Exception
+   {
+      SimpleBean simpleBean = unmarshal("TestInstantiate.xml", SimpleBean.class);
+      System.out.println("simpleBean = " + simpleBean);
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,48 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringTestSuite extends TestSuite
+{
+
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("Spring Tests");
+
+      suite.addTest(InstantiateSpringTestCase.suite());
+
+      return suite;
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTest.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTest.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTest.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import org.jboss.test.AbstractTestDelegate;
+import org.jboss.test.ioc.test.AbstractIoCTest;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class TempSpringSchemaTest extends AbstractIoCTest
+{
+
+   public TempSpringSchemaTest(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test delegate
+    *
+    * @param clazz the class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      return new TempSpringSchemaTestDelegate(clazz);
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java	2006-12-12 14:47:58 UTC (rev 58995)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java	2006-12-12 16:56:59 UTC (rev 58996)
@@ -0,0 +1,47 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import org.jboss.test.ioc.test.IoCTestDelegate;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultSchemaResolver;
+import org.jboss.spring.deployment.xml.SpringSchemaInitializer;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class TempSpringSchemaTestDelegate extends IoCTestDelegate
+{
+
+   public TempSpringSchemaTestDelegate(Class clazz)
+   {
+      super(clazz);
+   }
+
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      DefaultSchemaResolver defaultSchemaResolver = ((DefaultSchemaResolver) resolver);
+      defaultSchemaResolver.addSchemaInitializer("urn:jboss:spring-beans:2.0", new SpringSchemaInitializer());
+      defaultSchemaResolver.addSchemaLocation("urn:jboss:spring-beans:2.0", "mc-spring-beans_2_0.xsd");
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 12:03:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 12:03:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r58997 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GuB2k-0000Th-NG@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 12:03:47 -0500 (Tue, 12 Dec 2006)
New Revision: 58997

Modified:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java
Log:
JBMICROCONT-26; inital tests - not yet working

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java	2006-12-12 16:56:59 UTC (rev 58996)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringSchemaTestDelegate.java	2006-12-12 17:03:47 UTC (rev 58997)
@@ -39,7 +39,7 @@
    public void setUp() throws Exception
    {
       super.setUp();
-      DefaultSchemaResolver defaultSchemaResolver = ((DefaultSchemaResolver) resolver);
+      DefaultSchemaResolver defaultSchemaResolver = (DefaultSchemaResolver) resolver;
       defaultSchemaResolver.addSchemaInitializer("urn:jboss:spring-beans:2.0", new SpringSchemaInitializer());
       defaultSchemaResolver.addSchemaLocation("urn:jboss:spring-beans:2.0", "mc-spring-beans_2_0.xsd");
    }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 12:22:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 12:22:40 -0500
Subject: [jboss-cvs] JBossAS SVN: r58998 -
	projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test
Message-ID: <E1GuBKy-0000oH-Gz@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 12:22:38 -0500 (Tue, 12 Dec 2006)
New Revision: 58998

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
Log:
JBMICROCONT-26; inital tests - not yet working

Modified: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 17:03:47 UTC (rev 58997)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 17:22:38 UTC (rev 58998)
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
-<bean xmlns="urn:jboss:spring-beans:2.0" class="org.jboss.test.spring.support.SimpleBean">
+<bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean">
    <constructor-arg index="2">SpringBean</constructor-arg>
    <constructor-arg index="0">1</constructor-arg>
    <constructor-arg index="1">3.1415</constructor-arg>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 12:25:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 12:25:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r58999 -
	projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test
Message-ID: <E1GuBO6-0000sn-AV@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 12:25:52 -0500 (Tue, 12 Dec 2006)
New Revision: 58999

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
Log:
JBMICROCONT-26; inital tests - not yet working

Modified: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 17:22:38 UTC (rev 58998)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 17:25:52 UTC (rev 58999)
@@ -1,9 +1,9 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
-<bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean">
-   <constructor-arg index="2">SpringBean</constructor-arg>
-   <constructor-arg index="0">1</constructor-arg>
-   <constructor-arg index="1">3.1415</constructor-arg>
+<bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean" >
+   <constructor-arg index="2"><value>SpringBean</value></constructor-arg>
+   <constructor-arg index="0"><value>1</value></constructor-arg>
+   <constructor-arg index="1"><value>3.1415</value></constructor-arg>
    <property name="list">
       <list>
          <value>one</value>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 12:32:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 12:32:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r59000 - in projects/microcontainer/trunk:
	kernel/src/main/org/jboss/kernel/plugins/deployment/xml
	spring-int/src/main/org/jboss/spring/deployment/xml
	spring-int/src/resources/org/jboss/test/spring/test
Message-ID: <E1GuBUZ-00010K-6X@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 12:32:21 -0500 (Tue, 12 Dec 2006)
New Revision: 59000

Added:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapHandler.java
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/MapHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
Log:
JBMICROCONT-26; inital code

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/MapHandler.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/MapHandler.java	2006-12-12 17:25:52 UTC (rev 58999)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/MapHandler.java	2006-12-12 17:32:21 UTC (rev 59000)
@@ -47,16 +47,16 @@
 
    public void attributes(Object o, QName elementName, ElementBinding element, Attributes attrs, NamespaceContext nsCtx)
    {
-      AbstractMapMetaData collection = (AbstractMapMetaData) o;
+      AbstractMapMetaData map = (AbstractMapMetaData) o;
       for (int i = 0; i < attrs.getLength(); ++i)
       {
          String localName = attrs.getLocalName(i);
          if ("class".equals(localName))
-            collection.setType(attrs.getValue(i));
+            map.setType(attrs.getValue(i));
          else if ("keyClass".equals(localName))
-            collection.setKeyType(attrs.getValue(i));
+            map.setKeyType(attrs.getValue(i));
          else if ("valueClass".equals(localName))
-            collection.setValueType(attrs.getValue(i));
+            map.setValueType(attrs.getValue(i));
       }
    }
 }

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapHandler.java	2006-12-12 17:25:52 UTC (rev 58999)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapHandler.java	2006-12-12 17:32:21 UTC (rev 59000)
@@ -0,0 +1,58 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractMapMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.xml.sax.Attributes;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringMapHandler extends DefaultElementHandler
+{
+   /**
+    * The handler
+    */
+   public static final SpringMapHandler HANDLER = new SpringMapHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractMapMetaData();
+   }
+
+   public void attributes(Object o, QName elementName, ElementBinding element, Attributes attrs, NamespaceContext nsCtx)
+   {
+      AbstractMapMetaData map = (AbstractMapMetaData) o;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("key-type".equals(localName))
+            map.setKeyType(attrs.getValue(i));
+      }
+   }
+
+}

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 17:25:52 UTC (rev 58999)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 17:32:21 UTC (rev 59000)
@@ -87,7 +87,7 @@
 
    public static void initMapHandler(TypeBinding typeBinding)
    {
-      typeBinding.setHandler(MapHandler.HANDLER);
+      typeBinding.setHandler(SpringMapHandler.HANDLER);
       // entry has an entry
       typeBinding.pushInterceptor(SpringSchemaBinding.entryQName, MapEntryInterceptor.INTERCEPTOR);
    }

Modified: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 17:25:52 UTC (rev 58999)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 17:32:21 UTC (rev 59000)
@@ -5,14 +5,14 @@
    <constructor-arg index="0"><value>1</value></constructor-arg>
    <constructor-arg index="1"><value>3.1415</value></constructor-arg>
    <property name="list">
-      <list>
+      <list value-type="java.lang.String">
          <value>one</value>
          <value>two</value>
          <value>three</value>
       </list>
    </property>
    <property name="set">
-      <set>
+      <set value-type="java.lang.String">
          <value>one</value>
          <value>two</value>
          <value>one</value>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 13:11:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 13:11:12 -0500
Subject: [jboss-cvs] JBossAS SVN: r59001 -
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1GuC5w-0001lV-Vj@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 13:11:10 -0500 (Tue, 12 Dec 2006)
New Revision: 59001

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
JBMICROCONT-26; inital code

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 17:32:21 UTC (rev 59000)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 18:11:10 UTC (rev 59001)
@@ -58,6 +58,8 @@
    public static void initConstructorArgHandler(TypeBinding typeBinding)
    {
       typeBinding.setHandler(ConstructorArgHandler.HANDLER);
+      // configure
+      configureValueBindings(typeBinding);
    }
 
    public static void initPropertyHandler(TypeBinding typeBinding)
@@ -71,9 +73,9 @@
 
    public static void initValueHandler(TypeBinding typeBinding)
    {
-      typeBinding.setHandler(ValueHandler.HANDLER);
+      typeBinding.setHandler(PlainValueHandler.HANDLER);
       // value can take characters
-      typeBinding.setSimpleType(ValueCharactersHandler.HANDLER);
+      typeBinding.setSimpleType(PlainValueCharactersHandler.HANDLER);
       // configure
       configureValueBindings(typeBinding);
    }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 13:26:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 13:26:15 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1771 - in trunk:
	src/main/org/jboss/jms/client
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/jms/tx tests
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GuCKV-00020W-7J@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-12 13:25:55 -0500 (Tue, 12 Dec 2006)
New Revision: 1771

Removed:
   trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
Modified:
   trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
   trunk/src/main/org/jboss/jms/client/JBossSession.java
   trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
   trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/BrowserState.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
   trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java
   trunk/src/main/org/jboss/jms/client/state/ProducerState.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
   trunk/src/main/org/jboss/jms/tx/ResourceManager.java
   trunk/src/main/org/jboss/jms/tx/TxState.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
More HA stuff



Modified: trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -143,7 +143,7 @@
          // call pre or postDeliver so messages won't be acked, or stored in session/tx
          sess = conn.createSessionDelegate(false, Session.CLIENT_ACKNOWLEDGE, false);
 
-         cons = sess.createConsumerDelegate(dest, messageSelector, false, subName, true);
+         cons = sess.createConsumerDelegate(dest, messageSelector, false, subName, true, -1);
       }
       finally
       {

Modified: trunk/src/main/org/jboss/jms/client/JBossSession.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossSession.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/JBossSession.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -252,7 +252,7 @@
          tccc.set(getClass().getClassLoader());
 
          ConsumerDelegate consumerDelegate = delegate.
-            createConsumerDelegate((JBossDestination)d, messageSelector, noLocal, null, false);
+            createConsumerDelegate((JBossDestination)d, messageSelector, noLocal, null, false, -1);
          
          return new JBossMessageConsumer(consumerDelegate);
       }
@@ -305,7 +305,7 @@
          tccc.set(getClass().getClassLoader());
 
          ConsumerDelegate consumerDelegate =
-            delegate.createConsumerDelegate((JBossTopic)topic, null, false, name, false);
+            delegate.createConsumerDelegate((JBossTopic)topic, null, false, name, false, -1);
 
          return new JBossMessageConsumer(consumerDelegate);
       }
@@ -339,7 +339,7 @@
          messageSelector = null;
       }
       ConsumerDelegate consumerDelegate =
-         delegate.createConsumerDelegate((JBossTopic)topic, messageSelector, noLocal, name, false);
+         delegate.createConsumerDelegate((JBossTopic)topic, messageSelector, noLocal, name, false, -1);
       return new JBossMessageConsumer(consumerDelegate);
    }
 

Modified: trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -30,9 +30,7 @@
 import org.jboss.jms.client.JBossConnectionMetaData;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
-import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -200,10 +198,7 @@
       
       // Finished with the connection - we need to shutdown callback server
       state.getRemotingConnection().stop();
-      
-      // Remove reference to resource manager
-      ResourceManagerFactory.instance.checkInResourceManager(state.getServerID());
-      
+       
       // Remove reference to message id generator
       MessageIdGeneratorFactory.instance.checkInGenerator(state.getServerID());
       

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -23,9 +23,11 @@
 package org.jboss.jms.client.container;
 
 import java.util.ArrayList;
+import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+import java.util.Set;
 
 import javax.jms.JMSException;
 
@@ -50,6 +52,7 @@
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -77,6 +80,7 @@
    //Cache this here
    private ClientConnectionFactoryDelegate[] delegates;
    
+   //Cache this here
    private Map failoverMap;
    
    private int currentRobinIndex;
@@ -125,6 +129,7 @@
       {
          currentRobinIndex = 0;
       }
+      
       return currentDelegate;
    }
    
@@ -136,7 +141,6 @@
 
          MethodInvocation methodInvoke = (MethodInvocation)invocation;
 
-         // TODO: FIX THIS! metaData should contain CF_DELEGATES
          Object target = methodInvoke.getTargetObject();
          
          if (target instanceof ClusteredClientConnectionFactoryDelegate)
@@ -146,8 +150,6 @@
 
          if (delegates != null)
          {
-            //TODO: Fix this! metadata should contain CF_FAILOVER_INDEXES
-            //failoverIndexes = (int[])metaData.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CF_FAILOVER_INDEXES);
             failoverMap = ((ClusteredClientConnectionFactoryDelegate)target).getFailoverMap();
 
             if (failoverMap == null)
@@ -167,15 +169,14 @@
       
       CreateConnectionResult res = (CreateConnectionResult)cf.createConnectionDelegate(username, password, -1);
       
-      ClientConnectionDelegate connDelegate =
-         (ClientConnectionDelegate)res.getDelegate();
+      ClientConnectionDelegate connDelegate = (ClientConnectionDelegate)res.getDelegate();
       
-      initialiseConnection(connDelegate);
+      addListener(connDelegate);
       
       return connDelegate;   
    }
    
-   private void initialiseConnection(ClientConnectionDelegate connDelegate)
+   private void addListener(ClientConnectionDelegate connDelegate)
    {
       //Add a connection listener
       
@@ -186,20 +187,19 @@
       state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
    }
 
-   
    //The connection has failed
    private void handleFailure(ClientConnectionDelegate failedConnection) throws Exception
    {
       log.info("Handling failure");
       
+      //Get the connection factory we are going to failover onto
       ClientConnectionFactoryDelegate newCF = getFailoverDelegate(failedConnection);
-
-      //TODO implement client side valve to prevent invocations occurring whilst failover is occurring
-      
+  
       ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
       
       log.info("calling createFailoverConnectionDelegate");
       
+      //Create a connection using that connection factory
       CreateConnectionResult res =
          newCF.createConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
       
@@ -209,12 +209,12 @@
       {
          log.info("Got connection");
          
+         //We got the right server and created a new connection ok
+         
          ClientConnectionDelegate newConnection = (ClientConnectionDelegate)res.getDelegate();
          
          log.info("newconnection is " + newConnection);
          
-         //We got the right server and created a new connection
-         
          failover(failedConnection, newConnection);
       }
       else
@@ -289,71 +289,54 @@
 
       ConnectionState failedState = (ConnectionState)failedConnection.getState();
 
-      int oldServerID = failedState.getServerID();
-
       ConnectionState newState = (ConnectionState)newConnection.getState();
       
-      log.info("new state is: " + newState);
-
-      failedState.copy(newState);
-
-      // this is necessary so the connection will start "talking" to the new server instead
-      failedState.setRemotingConnection(newState.getRemotingConnection());
-      
       if (failedState.getClientID() != null)
       {
          newConnection.setClientID(failedState.getClientID());
       }
 
-      // Transfering state from newDelegate to currentDelegate
-      failedConnection.copyState(newConnection);
+      // Transfer attributes from newDelegate to failedDelegate
+      failedConnection.copyAttributes(newConnection);
       
+      int oldServerId = failedState.getServerID();
+      
+      CallbackManager oldCallbackManager = failedState.getRemotingConnection().getCallbackManager();
+      
+      //We need to update some of the attributes on the state
+      failedState.copyState(newState);
+      
       log.info("failing over children");
 
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
 
-         log.info("Creating session");
-         
+         ClientSessionDelegate failedSessionDelegate =
+            (ClientSessionDelegate)failedSessionState.getDelegate();
+                  
          ClientSessionDelegate newSessionDelegate = (ClientSessionDelegate)newConnection.
             createSessionDelegate(failedSessionState.isTransacted(),
                                   failedSessionState.getAcknowledgeMode(),
                                   failedSessionState.isXA());
          
-         log.info("Created session");
-                  
-         ClientSessionDelegate failedSessionDelegate =
-            (ClientSessionDelegate)failedSessionState.getDelegate();
+         SessionState newSessionState = (SessionState)newSessionDelegate.getState();
 
-         failedSessionDelegate.copyState(newSessionDelegate);
+         failedSessionDelegate.copyAttributes(newSessionDelegate);
          
-         log.info("copied state");
+         //We need to update some of the attributes on the state
+         newSessionState.copyState(newSessionState);                                  
          
-         //Now we remove any unacked np messages - this is because we don't want to ack them
-         //since the server won't know about them and will barf
-         Iterator iter = failedSessionState.getToAck().iterator();
+         if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
          
-         while (iter.hasNext())
-         {
-            AckInfo info = (AckInfo)iter.next();
-            
-            if (!info.getMessage().getMessage().isReliable())
-            {
-               iter.remove();
-            }            
-         }
+         List children = new ArrayList();
          
-         //TODO remove any unacked from the resource manager
-
-         if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
-
-         //TODO Clebert please add comment as to why this clone is necessary
-         //In general, please comment more - there is a serious lack of comments!!
-         List children = new ArrayList();
+         // TODO Why is this clone necessary?
          children.addAll(failedSessionState.getChildren());
+         
+         Set consumerIds = new HashSet();
 
-         for(Iterator j = children.iterator(); j.hasNext(); )
+         for (Iterator j = children.iterator(); j.hasNext(); )
          {
             HierarchicalStateSupport sessionChild = (HierarchicalStateSupport)j.next();
 
@@ -362,45 +345,83 @@
                handleFailoverOnProducer((ProducerState)sessionChild, newSessionDelegate);
             }
             else if (sessionChild instanceof ConsumerState)
-            {
+            {               
                handleFailoverOnConsumer(failedConnection,
                                         failedState,
                                         failedSessionState,
                                         (ConsumerState)sessionChild,
                                         failedSessionDelegate,
-                                        oldServerID);
+                                        oldServerId,
+                                        oldCallbackManager);       
+               
+               // We add the new consumer id to the list of old ids
+               consumerIds.add(new Integer(((ConsumerState)sessionChild).getConsumerID()));
+               
             }
             else if (sessionChild instanceof BrowserState)
             {
                 handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
             }
          }
-         
+                           
          /* Now we must sent the list of unacked AckInfos to the server - so the consumers
           * delivery lists can be repopulated
           */
          List ackInfos = null;
          
-         if (!failedSessionState.isTransacted())
+         if (!failedSessionState.isTransacted() && !failedSessionState.isXA())
          {
+            /*
+            Now we remove any unacked np messages - this is because we don't want to ack them
+            since the server won't know about them and will barf
+            */
+            
+            Iterator iter = newSessionState.getToAck().iterator();
+            
+            while (iter.hasNext())
+            {
+               AckInfo info = (AckInfo)iter.next();
+               
+               if (!info.getMessage().getMessage().isReliable())
+               {
+                  iter.remove();
+               }            
+            }
+            
             //Get the ack infos from the list in the session state
             ackInfos = failedSessionState.getToAck();
          }
          else
-         {
-            //Transacted session - we need to get the acks
-            //TODO
+         {            
+            //Transacted session - we need to get the acks from the resource manager
+            //btw we have kept the old resource manager
+            ResourceManager rm = failedState.getResourceManager();
+            
+            // Remove any non persistent acks - so server doesn't barf on commit
+            
+            rm.removeNonPersistentAcks(consumerIds);
+            
+            ackInfos = rm.getAckInfosForConsumerIds(consumerIds);            
          }
          
-         //TODO for a transacted session the ackinfos will be in the resource manager!!
-         
          if (!ackInfos.isEmpty())
          {
+            log.info("Sending " + ackInfos.size() + " unacked");
             newSessionDelegate.sendUnackedAckInfos(ackInfos);
-         }
-                  
+         }                 
       }
             
+//      problem - what if the consumer has closed - but there are still acks in the session or rm?
+//               
+//      we still need to replace them but with what?
+//               
+//      in this case we can't recreate a consumer on the server since it has closed
+//      
+//      solution here is to store by session id - major reworking!!!!!!!!
+      
+      
+     // todo need to replace consumer id
+      
       //We must not start the connection until the end
       if (failedState.isStarted())
       {
@@ -410,14 +431,13 @@
       log.info("Failover done");
    }
    
-   
-
-   private void handleFailoverOnConsumer(ClientConnectionDelegate connectionDelegate,
+   private void handleFailoverOnConsumer(ClientConnectionDelegate failedConnectionDelegate,
                                          ConnectionState failedConnectionState,
                                          SessionState failedSessionState,
                                          ConsumerState failedConsumerState,
                                          ClientSessionDelegate failedSessionDelegate,
-                                         int oldServerID)
+                                         int oldServerID,
+                                         CallbackManager oldCallbackManager)
       throws JMSException
    {
       log.info("Failing over consumer");
@@ -428,48 +448,63 @@
       if (trace) { log.trace("handleFailoverOnConsumer: creating alternate consumer"); }
 
       ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)failedSessionDelegate.
-         failOverConsumer((JBossDestination)failedConsumerState.getDestination(),
-                           failedConsumerState.getSelector(),
-                           failedConsumerState.isNoLocal(),
-                           failedConsumerState.getSubscriptionName(),
-                           failedConsumerState.isConnectionConsumer(),
-                           failedConsumerDelegate.getChannelId());
+         createConsumerDelegate((JBossDestination)failedConsumerState.getDestination(),
+                                 failedConsumerState.getSelector(),
+                                 failedConsumerState.isNoLocal(),
+                                 failedConsumerState.getSubscriptionName(),
+                                 failedConsumerState.isConnectionConsumer(),
+                                 failedConsumerState.getChannelId());
 
       if (trace) { log.trace("handleFailoverOnConsumer: alternate consumer created"); }
+            
+      //Copy the attributes from the new consumer to the old consumer
+      failedConsumerDelegate.copyAttributes(newConsumerDelegate);
 
-      failedConsumerDelegate.copyState(newConsumerDelegate);
-
+      ConsumerState newState = (ConsumerState)newConsumerDelegate.getState();
+      
       int oldConsumerID = failedConsumerState.getConsumerID();
+      
+      //Update attributes on the old state
+      failedConsumerState.copyState(newState);
 
-      ConsumerState newState = (ConsumerState)newConsumerDelegate.getState();
-      failedConsumerState.copy(newState);
-
-      if (failedSessionState.isTransacted())
+      if (failedSessionState.isTransacted() || failedSessionState.isXA())
       {
          //Replace the old consumer id with the new consumer id
          
-         //TODO what about XA?? - may have done work in many transactions - so need to replace all
+         ResourceManager rm = failedConnectionState.getResourceManager();
          
-         failedConnectionState.getResourceManager().
-            handleFailover(failedSessionState.getCurrentTxId(),
-                           oldConsumerID,
-                           failedConsumerState.getConsumerID());
+         rm.handleFailover(oldConsumerID, failedConsumerState.getConsumerID());
       }
-
-      CallbackManager cm = failedConnectionState.getRemotingConnection().getCallbackManager();
-
-      MessageCallbackHandler handler = cm.unregisterHandler(oldServerID, oldConsumerID);
-      handler.setConsumerId(failedConsumerState.getConsumerID());
+            
+      //We need to re-use the existing message callback handler
+            
+      log.info("Old server id:" + oldServerID + " old consumer id:" + oldConsumerID);
+      MessageCallbackHandler oldHandler = oldCallbackManager.unregisterHandler(oldServerID, oldConsumerID);
       
-      //Clear the buffer of the handler
-      handler.clearBuffer();
-
-      cm.registerHandler(failedConnectionState.getServerID(),
-                         failedConsumerState.getConsumerID(),
-                         handler);
+      ConnectionState newConnectionState = (ConnectionState)failedConnectionDelegate.getState();
       
-      failedSessionState.addCallbackHandler(handler);
+      CallbackManager newCallbackManager = newConnectionState.getRemotingConnection().getCallbackManager();
       
+      log.info("New server id:" + newConnectionState.getServerID() + " new consuer id:" + newState.getConsumerID());
+      
+      //Remove the new handler
+      MessageCallbackHandler newHandler = newCallbackManager.unregisterHandler(newConnectionState.getServerID(),
+                                                                               newState.getConsumerID());
+      
+      log.info("New handler is " + System.identityHashCode(newHandler));
+      
+      //But we need to update some fields from the new one
+      oldHandler.copyState(newHandler);
+      
+      //Now we re-register the old handler with the new callback manager
+            
+      newCallbackManager.registerHandler(newConnectionState.getServerID(),
+                                         newState.getConsumerID(),
+                                         oldHandler);
+      
+      //We don't need to add the handler to the session state since it is already there - we
+      //are re-using the old handler
+      
       log.info("failed over consumer");
    }
    
@@ -484,8 +519,10 @@
       ClientProducerDelegate failedProducerDelegate =
          (ClientProducerDelegate)failedProducerState.getDelegate();
 
-      failedProducerDelegate.copyState(newProducerDelegate);
-
+      failedProducerDelegate.copyAttributes(newProducerDelegate);
+      
+      failedProducerState.copyState((ProducerState)newProducerDelegate.getState());
+      
       if (trace) { log.trace("handling fail over on producerDelegate " + failedProducerDelegate + " destination=" + failedProducerState.getDestination()); }
    }
 
@@ -499,8 +536,10 @@
       ClientBrowserDelegate failedBrowserDelegate =
          (ClientBrowserDelegate)failedBrowserState.getDelegate();
 
-      failedBrowserDelegate.copyState(newBrowserDelegate);
-
+      failedBrowserDelegate.copyAttributes(newBrowserDelegate);
+      
+      failedBrowserState.copyState((BrowserState)newBrowserDelegate.getState());
+      
       if (trace) { log.trace("handling fail over on browserDelegate " + failedBrowserDelegate + " destination=" + failedBrowserState.getJmsDestination() + " selector=" + failedBrowserState.getMessageSelector()); }
 
    }

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -23,11 +23,10 @@
 
 import javax.jms.Destination;
 
-import org.jboss.aop.Advised;
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.aop.metadata.SimpleMetaData;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.delegate.ClientConsumerDelegate;
 import org.jboss.jms.client.delegate.ClientProducerDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
@@ -39,7 +38,6 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.BrowserDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
-import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.ProducerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.destination.JBossDestination;
@@ -47,9 +45,6 @@
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
-import org.jboss.jms.server.remoting.MetaDataConstants;
-import org.jboss.jms.tx.ResourceManager;
-import org.jboss.jms.tx.ResourceManagerFactory;
 
 /**
  * Maintains the hierarchy of parent and child state objects. For each delegate, this interceptor
@@ -89,37 +84,29 @@
       ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
       
       if (connectionDelegate != null)
-      {
-         
+      {         
          connectionDelegate.init();
          
-         SimpleMetaData md = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
+         //SimpleMetaData md = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
          
-         int serverID =
-            ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID)).intValue();
+         int serverID = connectionDelegate.getServerId();
          
-         Version connectionVersion = 
-            (Version)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION);
+         Version versionToUse = connectionDelegate.getVersionToUse();
          
-         JMSRemotingConnection connection = 
-            (JMSRemotingConnection)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION);
+         JMSRemotingConnection connection = connectionDelegate.getRemotingConnection();
          
-         if (connectionVersion == null)
+         if (versionToUse == null)
          {
             throw new IllegalStateException("Connection version is null");
          }
          
-         // We have one resource manager per unique server
-         ResourceManager rm = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
-         
          //We have one message id generator per unique server
          MessageIdGenerator gen =
             MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
          
          ConnectionState connectionState =
             new ConnectionState(serverID, connectionDelegate,
-                     connection,
-                     connectionVersion, rm, gen);
+                                connection, versionToUse, gen);
          
          connectionDelegate.setState(connectionState);
       }
@@ -150,7 +137,7 @@
    
    public Object handleCreateConsumerDelegate(Invocation invocation) throws Throwable
    {
-      ConsumerDelegate consumerDelegate = (ConsumerDelegate)invocation.invokeNext();
+      ClientConsumerDelegate consumerDelegate = (ClientConsumerDelegate)invocation.invokeNext();
       DelegateSupport delegate = (DelegateSupport)consumerDelegate;
       
       delegate.init();
@@ -164,21 +151,18 @@
       String subscriptionName = (String)mi.getArguments()[3];
       boolean connectionConsumer = ((Boolean)mi.getArguments()[4]).booleanValue();
 
-      SimpleMetaData md = ((Advised)consumerDelegate)._getInstanceAdvisor().getMetaData();
+      int consumerID = consumerDelegate.getID();
       
-      int consumerID =
-         ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.CONSUMER_ID)).intValue();
+      int prefetchSize = consumerDelegate.getPrefetchSize();
       
-      int prefetchSize =
-         ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.PREFETCH_SIZE)).intValue();
+      int maxDeliveries = consumerDelegate.getMaxDeliveries();
       
-      int maxDeliveries = 
-         ((Integer)md.getMetaData(MetaDataConstants.JMS, MetaDataConstants.MAX_DELIVERIES)).intValue();
+      long channelId = consumerDelegate.getChannelId();
       
       ConsumerState consumerState =
          new ConsumerState(sessionState, consumerDelegate, dest, selector, noLocal,
                            subscriptionName, consumerID, connectionConsumer, prefetchSize,
-                           maxDeliveries);
+                           maxDeliveries, channelId);
 
       delegate.setState(consumerState);
       return consumerDelegate;

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -28,13 +28,12 @@
 import javax.jms.ServerSessionPool;
 import javax.transaction.xa.Xid;
 
-import org.jboss.aop.util.PayloadKey;
 import org.jboss.jms.client.JBossConnectionConsumer;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
-import org.jboss.jms.server.remoting.MetaDataConstants;
+import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.remoting.Client;
 
@@ -57,11 +56,12 @@
 
    // Attributes ----------------------------------------------------
 
-   // This should not be exposed other than through meta data
    private int serverId;
 
    private transient JMSRemotingConnection remotingConnection;
    
+   private Version versionToUse;
+   
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
@@ -223,8 +223,6 @@
    public void init()
    {
       super.init();
-      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.SERVER_ID,
-                                new Integer(serverId), PayloadKey.TRANSIENT);
    }
 
    public void setRemotingConnection(JMSRemotingConnection conn)
@@ -236,8 +234,32 @@
    {
       return remotingConnection;
    }
+   
+   public int getServerId()
+   {
+      return serverId;
+   }
+   
+   public Version getVersionToUse()
+   {
+      return versionToUse;
+   }
+   
+   public void setVersionToUse(Version versionToUse)
+   {
+      this.versionToUse = versionToUse;
+   }
+   
+   public void copyAttributes(DelegateSupport newDelegate)
+   {
+      super.copyAttributes(newDelegate);
+      
+      this.remotingConnection = ((ClientConnectionDelegate)newDelegate).getRemotingConnection();
+      
+      this.versionToUse = ((ClientConnectionDelegate)newDelegate).getVersionToUse();
+   }
 
-   // Protected -----------------------------------------------------
+   // Protected -----------------------------------------------------   
 
    protected Client getClient()
    {

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -26,7 +26,6 @@
 
 import javax.jms.JMSException;
 
-import org.jboss.aop.Advised;
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
@@ -68,13 +67,14 @@
    // Attributes ----------------------------------------------------
 
    //This data is needed in order to create a connection
-   protected String serverLocatorURI;
-   protected Version serverVersion;
-
-   // This property is used on redirect on failover logic (verify if a new delegate could be used during a failover)
-   protected int serverId;
-   protected boolean clientPing;
+   private String serverLocatorURI;
+ 
+   private Version serverVersion;
+ 
+   private int serverId;
    
+   private boolean clientPing;
+   
    private transient boolean trace;
 
    // Static --------------------------------------------------------
@@ -271,18 +271,9 @@
          
          if (connectionDelegate != null)
          {
-            //We set the version for the connection and the remoting connection on the meta-data
-            //this is so the StateCreationAspect can pick it up
-   
-            SimpleMetaData metaData = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
-   
-            metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.REMOTING_CONNECTION,
-                                 remotingConnection, PayloadKey.TRANSIENT);
-   
-            metaData.addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONNECTION_VERSION,
-                                 version, PayloadKey.TRANSIENT);
-
             connectionDelegate.setRemotingConnection(remotingConnection);
+            
+            connectionDelegate.setVersionToUse(version);
          }
          else
          {
@@ -296,7 +287,6 @@
             {
             }
          }
-
       }
 
       return ret;
@@ -307,7 +297,6 @@
       return "ClientConnectionFactoryDelegate[" + id + "]";
    }
    
-   //This MUST ONLY be used in testing
    public String getServerLocatorURI()
    {
       return serverLocatorURI;
@@ -317,9 +306,26 @@
    {
       return serverId;
    }
+   
+   public boolean getClientPing()
+   {
+      return clientPing;
+   }
+   
+   public Version getServerVersion()
+   {
+      return serverVersion;
+   }
+   
+   public void copyAttributes(DelegateSupport newDelegate)
+   {
+      super.copyAttributes(newDelegate);
+   }
 
    // Protected -----------------------------------------------------
 
+   
+
    protected Client getClient()
    {
       return null;

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -25,11 +25,9 @@
 import javax.jms.Message;
 import javax.jms.MessageListener;
 
-import org.jboss.aop.util.PayloadKey;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.destination.JBossDestination;
-import org.jboss.jms.server.remoting.MetaDataConstants;
 import org.jboss.remoting.Client;
 
 /**
@@ -50,11 +48,10 @@
 
    // Attributes ----------------------------------------------------
    
-   // This should not be exposed other than through meta data
    private int bufferSize;
-   protected int maxDeliveries;
+   
+   private int maxDeliveries;
 
-   // This should not be exposed other than through meta data
    private long channelId;
 
    // Static --------------------------------------------------------
@@ -73,11 +70,6 @@
    {      
    }
 
-   public long getChannelId()
-   {
-       return channelId;
-   }
-
    // ConsumerDelegate implementation -------------------------------
 
    /**
@@ -182,24 +174,41 @@
 
    // Public --------------------------------------------------------
 
-   public void init()
-   {
-      super.init();
-      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.CONSUMER_ID,
-                                new Integer(id), PayloadKey.TRANSIENT);
-      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.PREFETCH_SIZE,
-                                new Integer(bufferSize), PayloadKey.TRANSIENT);
-      getMetaData().addMetaData(MetaDataConstants.JMS, MetaDataConstants.MAX_DELIVERIES,
-                                new Integer(maxDeliveries), PayloadKey.TRANSIENT);
-   }
-
    public String toString()
    {
       return "ConsumerDelegate[" + id + "](ChannelId=" + this.channelId+")" ;
    }
+   
+   public int getPrefetchSize()
+   {
+      return bufferSize;
+   }
+   
+   public int getMaxDeliveries()
+   {
+      return maxDeliveries;
+   }
+   
+   public long getChannelId()
+   {
+      return channelId;
+   }
+   
+   public void copyAttributes(DelegateSupport newDelegate)
+   {
+      super.copyAttributes(newDelegate);
+      
+      this.bufferSize = ((ClientConsumerDelegate)newDelegate).getPrefetchSize();
+      
+      this.maxDeliveries = ((ClientConsumerDelegate)newDelegate).getMaxDeliveries();
+      
+      this.channelId = ((ClientConsumerDelegate)newDelegate).getChannelId();
+   }
 
    // Protected -----------------------------------------------------
    
+
+
    protected Client getClient()
    {
       // Use the Client in the Connection's state
@@ -207,20 +216,7 @@
          getInvokingClient();
    }
 
-   public void copyState(DelegateSupport newDelegate)
-   {
-      super.copyState(newDelegate);
-      this.channelId = ((ClientConsumerDelegate)newDelegate).channelId;
-      this.getMetaData().removeMetaData(MetaDataConstants.JMS, MetaDataConstants.CONSUMER_ID);
-      this.getMetaData().addMetaData(MetaDataConstants.JMS,
-                                     MetaDataConstants.CONSUMER_ID,
-                                     newDelegate.getMetaData().
-                                        getMetaData(MetaDataConstants.JMS,
-                                                    MetaDataConstants.CONSUMER_ID),
-                                     PayloadKey.TRANSIENT);
-   }
 
-
    // Package Private -----------------------------------------------
 
    // Private -------------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -187,25 +187,12 @@
     */
    public ConsumerDelegate createConsumerDelegate(JBossDestination destination, String selector,
                                                   boolean noLocal, String subscriptionName,
-                                                  boolean connectionConsumer) throws JMSException
+                                                  boolean connectionConsumer, long failoverChannelId) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
    /**
-    * @see org.jboss.jms.server.endpoint.ServerSessionEndpoint#failOverConsumer(org.jboss.jms.destination.JBossDestination, String, boolean, String, boolean, long, int) 
-    * @see org.jboss.jms.client.container.StateCreationAspect#handleCreateConsumerDelegate(org.jboss.aop.joinpoint.Invocation)
-    * */
-   public ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
-                                            String selectorString,
-                                            boolean noLocal,  String subscriptionName,
-                                            boolean connectionConsumer,
-                                            long oldChannelID) throws JMSException
-   {
-      throw new IllegalStateException("This invocation should not be handled here!");
-   }
-
-   /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -73,8 +73,8 @@
                                                    ClientConnectionFactoryDelegate[] delegates,
                                                    Map failoverMap)
    {
-      this(mainDelegate.getID(), mainDelegate.serverId, mainDelegate.serverLocatorURI,
-         mainDelegate.serverVersion, mainDelegate.clientPing, delegates, failoverMap);
+      this(mainDelegate.getID(), mainDelegate.getServerId(), mainDelegate.getServerLocatorURI(),
+           mainDelegate.getServerVersion(), mainDelegate.getClientPing(), delegates, failoverMap);
    }
 
    // DelegateSupport overrides -------------------------------------
@@ -89,18 +89,7 @@
          {
             delegates[i].init();
          }
-      }
-      
-      //This doesn't seem to be used so I'm commenting it out
-
-//      // We add this to the meta data so the failOver aspect can get access to it
-//      getMetaData().addMetaData(MetaDataConstants.JMS,
-//                                MetaDataConstants.CF_DELEGATES,
-//                                delegates, PayloadKey.TRANSIENT);
-//
-//      getMetaData().addMetaData(MetaDataConstants.JMS,
-//                                MetaDataConstants.FAILOVER_MAP,
-//                                failoverMap, PayloadKey.TRANSIENT);
+      }      
    }
 
    // Public --------------------------------------------------------
@@ -112,7 +101,6 @@
       return delegates;
    }
 
-   /** TODO As metadata is not working, I'm exposing this temporarily */
    public Map getFailoverMap()
    {
       return failoverMap;

Modified: trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -152,7 +152,7 @@
      * has to be transfered to this actual object. For example, a Connection will have to assume the
      * ObjectID of the new connection endpoint and the new RemotingConnection.
      */
-    public void copyState(DelegateSupport newDelegate)
+    public void copyAttributes(DelegateSupport newDelegate)
     {
         id = newDelegate.getID();
     }

Modified: trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -94,17 +94,13 @@
 
    public void registerHandler(int serverID, int consumerID, MessageCallbackHandler handler)
    {
-      log.info(this + " registeringHandler, serverID:" + serverID + " consumerID:" + consumerID);
-      
       Long lookup = computeLookup(serverID, consumerID);
 
       callbackHandlers.put(lookup, handler);
    }
 
    public MessageCallbackHandler unregisterHandler(int serverID, int consumerID)
-   {
-      log.info(this + " unregisteringHandler, serverID:" + serverID + " consumerID:" + consumerID);
-      
+   { 
       Long lookup = computeLookup(serverID, consumerID);
 
       return (MessageCallbackHandler)callbackHandlers.remove(lookup);

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -36,6 +36,7 @@
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.tx.AckInfo;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Message;
 import org.jboss.messaging.util.Future;
 import org.jboss.remoting.callback.HandleCallbackException;
 
@@ -216,9 +217,9 @@
     *         or -1 if closed
     */
    public HandleMessageResponse handleMessage(List msgs) throws HandleCallbackException
-   {            
+   {                      
       if (trace) { log.trace(this + " receiving " + msgs.size() + " message(s) from the remoting layer"); }
-                      
+            
       synchronized (mainLock)
       {
          if (closed)
@@ -516,12 +517,7 @@
          messagesAdded();
       }
    }
-   
-   public void clearBuffer()
-   {
-      buffer.clear();
-   }
-   
+     
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------
@@ -780,6 +776,22 @@
          consumerDelegate.confirmDelivery(count);
       }
    }
+   
+   public void copyState(MessageCallbackHandler newHandler)
+   {
+      synchronized (mainLock)
+      {
+         this.consumerID = newHandler.consumerID;
+         
+         this.consumerDelegate = newHandler.consumerDelegate;
+         
+         this.sessionDelegate = newHandler.sessionDelegate;
+         
+         this.serverSending = false;
+         
+         this.buffer.clear();
+      }
+   }
 
 }
 

Modified: trunk/src/main/org/jboss/jms/client/state/BrowserState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -67,7 +67,6 @@
       return parent.getVersionToUse();
    }
 
-
    public org.jboss.jms.destination.JBossDestination getJmsDestination()
    {
       return jmsDestination;
@@ -77,15 +76,23 @@
    {
       return messageSelector;
    }
-
+   
    public void setParent(HierarchicalState parent)
    {
       this.parent=(SessionState)parent;
    }
+   
    public HierarchicalState getParent()
    {
       return parent;
    }
-
+   
+   // When failing over a browser, we keep the old browser's state but there are certain fields
+   // we need to update
+   public void copyState(BrowserState newState)
+   {      
+      //Actually only one field
+      this.delegate = newState.delegate;
+   }
 }
 

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -70,7 +70,6 @@
 
    protected boolean started;
 
-
    /** This property used to be delcared on ConnectionAspect */
    private String clientID;
 
@@ -83,10 +82,9 @@
     /** This property used to be delcared on ConnectionAspect */
    private boolean listenerAdded;
    
-   
    public ConnectionState(int serverID, ConnectionDelegate delegate,
                           JMSRemotingConnection remotingConnection, Version versionToUse,
-                          ResourceManager rm, MessageIdGenerator gen)
+                          MessageIdGenerator gen)
       throws Exception
    {
       super(null, (DelegateSupport)delegate);
@@ -99,7 +97,10 @@
 
       this.versionToUse = versionToUse;
 
-      this.resourceManager = rm;
+      //Each connection has it's own resource manager
+      //If we can failover all connections with the same server id at the same time
+      //then we can maintain one rm per unique server as opposed to per connection
+      this.resourceManager = new ResourceManager();
 
       this.idGenerator = gen;
 
@@ -230,12 +231,19 @@
     {
         return null;
     }
-
-    public void copy(ConnectionState newState)
+    
+    //When failing over a connection, we keep the old connection's state but there are certain fields
+    //we need to update
+    public void copyState(ConnectionState newState)
     {
-        this.serverID = newState.serverID;
-        this.idGenerator = newState.idGenerator;
+       this.remotingConnection = newState.remotingConnection;
+       
+       this.idGenerator = newState.idGenerator;
+       
+       this.serverID = newState.serverID;
+       
+       this.versionToUse = newState.versionToUse;
+       
+       this.delegate = newState.delegate;
     }
-
-
 }

Modified: trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -63,9 +63,12 @@
    
    private int maxDeliveries;
    
+   //Needed for failover
+   private long channelId;
+   
    public ConsumerState(SessionState parent, ConsumerDelegate delegate, Destination dest,
                         String selector, boolean noLocal, String subscriptionName, int consumerID,
-                        boolean isCC, int prefetchSize, int maxDeliveries)
+                        boolean isCC, int prefetchSize, int maxDeliveries, long channelId)
    {
       super(parent, (DelegateSupport)delegate);
       children = Collections.EMPTY_SET;
@@ -77,6 +80,7 @@
       this.prefetchSize = prefetchSize;
       this.subscriptionName=subscriptionName;
       this.maxDeliveries = maxDeliveries;
+      this.channelId = channelId;
    }
 
    public DelegateSupport getDelegate()
@@ -155,14 +159,25 @@
       this.subscriptionName = subscriptionName;
    }
 
-   public void copy(ConsumerState newState)
-   {
-      this.consumerID = newState.consumerID;
-   }
-
    public int getMaxDeliveries()
    {
       return maxDeliveries;
    }
+   
+   public long getChannelId()
+   {
+      return channelId;
+   }
+   
+   // When failing over a consumer, we keep the old consumer's state but there are certain fields
+   // we need to update
+   public void copyState(ConsumerState newState)
+   {      
+      this.consumerID = newState.consumerID;
+      
+      this.delegate = newState.delegate;
+      
+      this.channelId = newState.channelId;
+   }
 
 }

Modified: trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -41,9 +41,11 @@
    Set getChildren();
    
    DelegateSupport getDelegate();
+   
    void setDelegate(DelegateSupport delegate);
 
    HierarchicalState getParent();
+   
    void setParent(HierarchicalState parent);
 
    Version getVersionToUse();

Modified: trunk/src/main/org/jboss/jms/client/state/ProducerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ProducerState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/state/ProducerState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -56,102 +56,107 @@
    private SessionState parent;
 
    private ProducerDelegate delegate;
-
+   
    public ProducerState(SessionState parent, ProducerDelegate delegate, Destination dest)
    {
       super(parent, (DelegateSupport)delegate);
       children = Collections.EMPTY_SET;
       this.destination = dest;
    }
-
+   
    public Destination getDestination()
    {
       return destination;
    }
-
-
-    public DelegateSupport getDelegate()
-    {
-        return (DelegateSupport)delegate;
-    }
-
-    public void setDelegate(DelegateSupport delegate)
-    {
-        this.delegate=(ProducerDelegate)delegate;
-    }
-
-
-    public void setParent(HierarchicalState parent)
-    {
-        this.parent = (SessionState)parent;
-    }
-    public HierarchicalState getParent()
-    {
-        return parent;
-    }
-
-
+      
+   public DelegateSupport getDelegate()
+   {
+      return (DelegateSupport)delegate;
+   }
+   
+   public void setDelegate(DelegateSupport delegate)
+   {
+      this.delegate=(ProducerDelegate)delegate;
+   }
+      
+   public void setParent(HierarchicalState parent)
+   {
+      this.parent = (SessionState)parent;
+   }
+   
+   public HierarchicalState getParent()
+   {
+      return parent;
+   }
+      
    public void setDestination(Destination dest)
    {
       this.destination = dest;
-
+      
    }
    public boolean isDisableMessageID()
    {
       return disableMessageID;
    }
-
+   
    public void setDisableMessageID(boolean disableMessageID)
    {
       this.disableMessageID = disableMessageID;
    }
-
+   
    public boolean isDisableMessageTimestamp()
    {
       return disableMessageTimestamp;
    }
-
+   
    public void setDisableMessageTimestamp(boolean disableMessageTimestamp)
    {
       this.disableMessageTimestamp = disableMessageTimestamp;
    }
-
+   
    public int getPriority()
    {
       return priority;
    }
-
+   
    public void setPriority(int priority)
    {
       this.priority = priority;
    }
-
+   
    public long getTimeToLive()
    {
       return timeToLive;
    }
-
+   
    public void setTimeToLive(long timeToLive)
    {
       this.timeToLive = timeToLive;
    }
-
+   
    public int getDeliveryMode()
    {
       return deliveryMode;
    }
-
+   
    public void setDeliveryMode(int deliveryMode)
    {
       this.deliveryMode = deliveryMode;
    }
-
+   
    public Version getVersionToUse()
    {
       return parent.getVersionToUse();
    }
-
-
+   
+   // When failing over a producer, we keep the old producer's state but there are certain fields
+   // we need to update
+   public void copyState(ProducerState newState)
+   {      
+      //Actually only one field
+      this.delegate = newState.delegate;
+   }
+   
 }
 
 

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -69,64 +69,65 @@
    private List toAck;
 
    private ConnectionState parent;
+   
    private SessionDelegate delegate;
    
    private Map callbackHandlers;
    
    public SessionState(ConnectionState parent, SessionDelegate delegate,
-                       boolean transacted, int ackMode, boolean xa)
+            boolean transacted, int ackMode, boolean xa)
    {
       super(parent, (DelegateSupport)delegate);
       children = new HashSet();
       this.acknowledgeMode = ackMode;
       this.transacted = transacted;
       this.xa = xa;
-
+      
       if (xa)
       {
          // Create an XA resource
          xaResource = new MessagingXAResource(parent.getResourceManager(), this);                            
       }
-
+      
       // If session is transacted and XA, the currentTxId will be updated when the XAResource will
       // be enrolled with a global transaction.
-
+      
       if (transacted & !xa)
       {
          // Create a local tx
          currentTxId = parent.getResourceManager().createLocalTx();        
       }
-
+      
       executor = new QueuedExecutor(new LinkedQueue());
       
       toAck = new ArrayList();
-
+      
       // TODO could optimise this to use the same map of callbackmanagers (which holds refs
       // to callbackhandlers) in the connection, instead of maintaining another map
       callbackHandlers = new HashMap();
    }
-
-
-    public void setParent(HierarchicalState parent)
-    {
-        this.parent = (ConnectionState)parent;
-    }
-    public HierarchicalState getParent()
-    {
-        return parent;
-    }
-
-    public DelegateSupport getDelegate()
-    {
-        return (DelegateSupport)delegate;
-    }
-
-    public void setDelegate(DelegateSupport delegate)
-    {
-        this.delegate=(SessionDelegate)delegate;
-    }
-
-
+   
+   
+   public void setParent(HierarchicalState parent)
+   {
+      this.parent = (ConnectionState)parent;
+   }
+   public HierarchicalState getParent()
+   {
+      return parent;
+   }
+   
+   public DelegateSupport getDelegate()
+   {
+      return (DelegateSupport)delegate;
+   }
+   
+   public void setDelegate(DelegateSupport delegate)
+   {
+      this.delegate=(SessionDelegate)delegate;
+   }
+   
+   
    /**
     * @return List<AckInfo>
     */
@@ -134,7 +135,7 @@
    {
       return toAck;
    }
-    
+   
    public int getAcknowledgeMode()
    {
       return acknowledgeMode;
@@ -204,5 +205,13 @@
    {
       return new ArrayList(callbackHandlers.values());
    }
+   
+   // When failing over a session, we keep the old session's state but there are certain fields
+   // we need to update
+   public void copyState(SessionState newState)
+   {      
+      //Actually only one field
+      this.delegate = newState.delegate;
+   }
 }
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -649,6 +649,9 @@
             deliveries.put(new Long(del.getReference().getMessageID()), del);
          }
       }
+      
+      //Prompt delivery
+      messageQueue.deliver(false);
    }
 
    protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -27,6 +27,7 @@
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
+import java.util.LinkedHashMap;
 import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
@@ -59,6 +60,7 @@
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.MessageQueueNameHelper;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.IdManager;
@@ -117,7 +119,7 @@
    private int nodeId;
    private int maxDeliveryAttempts;
    private Queue dlq;
-
+   
    // Constructors --------------------------------------------------
 
    protected ServerSessionEndpoint(int sessionID, ServerConnectionEndpoint connectionEndpoint)
@@ -144,349 +146,41 @@
       dlq = sp.getDLQ();
       tr = sp.getTxRepository();
       maxDeliveryAttempts = sp.getMaxDeliveryAttempts();
+
    }
-
+   
    // SessionDelegate implementation --------------------------------
-      
-   public ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
-                                            String selectorString,
-                                            boolean noLocal,  String subscriptionName,
-                                            boolean connectionConsumer,
-                                            long oldChannelID) throws JMSException
-   {
-      //TODO we must ensure that the server side failover has completed first before
-      //letting this method run
-      
-      try
-      {
-         // fail over channel
-         if (postOffice.isLocal())
-         {
-            throw new IllegalStateException("Cannot failover on a non clustered post office!");
-         }
-
-         // this is a Clustered operation... so postOffice here must be Clustered
-         Binding binding = ((ClusteredPostOffice)postOffice).getBindingforChannelId(oldChannelID);
-         if (binding == null)
-         {
-            throw new IllegalStateException("Can't find failed over channel " + oldChannelID);
-         }
-         
-         // TODO - Remove this log.info before merging into trunk
-         if (binding.getQueue() instanceof RemoteQueueStub)
-         {
-            log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((RemoteQueueStub)binding.getQueue()).getChannelID());
-         }
-         else
-         {
-            log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((PagingFilteredQueue)binding.getQueue()).getChannelID());
-         }
-         
-         int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
-         
-         int prefetchSize = connectionEndpoint.getPrefetchSize();
-         
-         ServerConsumerEndpoint ep =
-
-            new ServerConsumerEndpoint(consumerID, binding.getQueue(),
-                                       binding.getQueue().getName(), this, selectorString, noLocal,
-                                       jmsDestination, prefetchSize, dlq);
-
-         JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
-         
-         ClientConsumerDelegate stub =
-            new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
-                                       prefetchSize, maxDeliveryAttempts);
-
-         
-         putConsumerEndpoint(consumerID, ep); // caching consumer locally
-         
-         connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
-         
-         return stub;
-      }
-      catch (Throwable t)
-      {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " createConsumerDelegate");
-      }
-   }
-
-   /*
-    * Please don't put failover logic in here
-    */
-	public ConsumerDelegate createConsumerDelegate(JBossDestination jmsDestination,
+       
+   public ConsumerDelegate createConsumerDelegate(JBossDestination jmsDestination,
                                                   String selectorString,
                                                   boolean noLocal,
                                                   String subscriptionName,
-                                                  boolean isCC) throws JMSException
+                                                  boolean isCC,
+                                                  long failoverChannelId) throws JMSException
    {
       try
       {
-         if (closed)
+         if (failoverChannelId == -1)
          {
-            throw new IllegalStateException("Session is closed");
-         }
-
-         if ("".equals(selectorString))
-         {
-            selectorString = null;
-         }
-
-         log.debug("creating consumer for " + jmsDestination + ", selector " + selectorString + ", " + (noLocal ? "noLocal, " : "") + "subscription " + subscriptionName);
-
-         ManagedDestination mDest = dm.getDestination(jmsDestination.getName(), jmsDestination.isQueue());
-
-         if (mDest == null)
-         {
-            throw new InvalidDestinationException("No such destination: " + jmsDestination);
-         }
-
-         if (jmsDestination.isTemporary())
-         {
-            // Can only create a consumer for a temporary destination on the same connection
-            // that created it
-            if (!connectionEndpoint.hasTemporaryDestination(jmsDestination))
-            {
-               String msg = "Cannot create a message consumer on a different connection " +
-                            "to that which created the temporary destination";
-               throw new IllegalStateException(msg);
-            }
-         }
-
-         int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
-
-         Binding binding = null;
-
-         // Always validate the selector first
-         Selector selector = null;
-         if (selectorString != null)
-         {
-            selector = new Selector(selectorString);
-         }
-
-         if (jmsDestination.isTopic())
-         {
-            JMSCondition topicCond = new JMSCondition(false, jmsDestination.getName());
+            //Standard createConsumerDelegate
             
-            if (subscriptionName == null)
-            {
-               // non-durable subscription
-               if (log.isTraceEnabled()) { log.trace("creating new non-durable subscription on " + jmsDestination); }
-
-               //Create the non durable sub
-               QueuedExecutor executor = (QueuedExecutor)pool.get();
-
-               PagingFilteredQueue q;
-
-               if (postOffice.isLocal())
-               {
-                  q = new PagingFilteredQueue(new GUID().toString(), idm.getId(), ms, pm, true, false,
-                                              executor, selector,
-                                              mDest.getFullSize(),
-                                              mDest.getPageSize(),
-                                              mDest.getDownCacheSize());
-
-                  binding = postOffice.bindQueue(topicCond, q);
-               }
-               else
-               {
-                  q = new LocalClusteredQueue(postOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
-                                              executor, selector, tr,
-                                              mDest.getFullSize(),
-                                              mDest.getPageSize(),
-                                              mDest.getDownCacheSize());
-
-                  ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
-
-                  if (mDest.isClustered())
-                  {
-                     binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
-                  }
-                  else
-                  {
-                     binding = cpo.bindQueue(topicCond, q);
-                  }
-               }
-            }
-            else
-            {
-               if (jmsDestination.isTemporary())
-               {
-                  throw new InvalidDestinationException("Cannot create a durable subscription on a temporary topic");
-               }
-
-               // we have a durable subscription, look it up
-               String clientID = connectionEndpoint.getClientID();
-               if (clientID == null)
-               {
-                  throw new JMSException("Cannot create durable subscriber without a valid client ID");
-               }
-
-               // See if there any bindings with the same client_id.subscription_name name
-
-               String name = MessageQueueNameHelper.createSubscriptionName(clientID, subscriptionName);
-
-               binding = postOffice.getBindingForQueueName(name);
-
-               if (binding == null)
-               {
-                  //Does not already exist
-
-                  if (trace) { log.trace("creating new durable subscription on " + jmsDestination); }
-
-                  QueuedExecutor executor = (QueuedExecutor)pool.get();
-                  PagingFilteredQueue q;
-
-                  if (postOffice.isLocal())
-                  {
-                     q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
-                                                 executor, selector,
-                                                 mDest.getFullSize(),
-                                                 mDest.getPageSize(),
-                                                 mDest.getDownCacheSize());
-
-                     binding = postOffice.bindQueue(topicCond, q);
-                  }
-                  else
-                  {
-                     q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
-                                                 executor, selector, tr,
-                                                 mDest.getFullSize(),
-                                                 mDest.getPageSize(),
-                                                 mDest.getDownCacheSize());
-
-                     ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
-
-                     if (mDest.isClustered())
-                     {
-                        binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
-                     }
-                     else
-                     {
-                        binding = cpo.bindQueue(topicCond, q);
-                     }
-                  }
-               }
-               else
-               {
-                  //Durable sub already exists
-
-                  if (trace) { log.trace("subscription " + subscriptionName + " already exists"); }
-
-                  // From javax.jms.Session Javadoc (and also JMS 1.1 6.11.1):
-                  // A client can change an existing durable subscription by creating a durable
-                  // TopicSubscriber with the same name and a new topic and/or message selector.
-                  // Changing a durable subscriber is equivalent to unsubscribing (deleting) the old
-                  // one and creating a new one.
-
-                  String filterString = binding.getQueue().getFilter() != null ? binding.getQueue().getFilter().getFilterString() : null;
-
-                  boolean selectorChanged =
-                     (selectorString == null && filterString != null) ||
-                     (filterString == null && selectorString != null) ||
-                     (filterString != null && selectorString != null &&
-                     !filterString.equals(selectorString));
-
-                  if (trace) { log.trace("selector " + (selectorChanged ? "has" : "has NOT") + " changed"); }
-
-                  boolean topicChanged = !binding.getCondition().equals(jmsDestination.getName());
-
-                  if (log.isTraceEnabled()) { log.trace("topic " + (topicChanged ? "has" : "has NOT") + " changed"); }
-
-                  if (selectorChanged || topicChanged)
-                  {
-                     if (trace) { log.trace("topic or selector changed so deleting old subscription"); }
-
-                     // Unbind the durable subscription
-
-                     if (mDest.isClustered() && !postOffice.isLocal())
-                     {
-                        ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
-
-                        cpo.unbindClusteredQueue(name);
-                     }
-                     else
-                     {
-                        postOffice.unbindQueue(name);
-                     }
-
-                     // create a fresh new subscription
-
-                     QueuedExecutor executor = (QueuedExecutor)pool.get();
-                     PagingFilteredQueue q;
-
-                     if (postOffice.isLocal())
-                     {
-                        q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
-                                                    executor, selector,
-                                                    mDest.getFullSize(),
-                                                    mDest.getPageSize(),
-                                                    mDest.getDownCacheSize());
-                        binding = postOffice.bindQueue(topicCond, q);
-                     }
-                     else
-                     {
-                        q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
-                                                    executor, selector, tr,
-                                                    mDest.getFullSize(),
-                                                    mDest.getPageSize(),
-                                                    mDest.getDownCacheSize());
-
-                        ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
-
-                        if (mDest.isClustered())
-                        {
-                           binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
-                        }
-                        else
-                        {
-                           binding = cpo.bindQueue(topicCond, (LocalClusteredQueue)q);
-                        }
-                     }
-                  }
-               }
-            }
+            return createConsumerDelegateInternal(jmsDestination, selectorString, noLocal, subscriptionName,
+                                                  isCC);
          }
          else
          {
-            //Consumer on a jms queue
-
-            //Let's find the binding
-            binding = postOffice.getBindingForQueueName(jmsDestination.getName());
-
-            if (binding == null)
-            {
-               throw new IllegalStateException("Cannot find binding for jms queue: " + jmsDestination.getName());
-            }
-         }
-
-         int prefetchSize = connectionEndpoint.getPrefetchSize();
-
-         ServerConsumerEndpoint ep =
-            new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
-                                       binding.getQueue().getName(), this, selectorString, noLocal,
-                                       jmsDestination, prefetchSize, dlq);
-          
-         JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
-
-         ClientConsumerDelegate stub =
-            new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
-                                       prefetchSize, maxDeliveryAttempts);
-                       
-         putConsumerEndpoint(consumerID, ep); // caching consumer locally
-         
-         connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
-         
-         log.debug("created and registered " + ep);
-   
-         return stub;
+            //Failover of consumer
+            
+            return failoverConsumer(jmsDestination, selectorString, noLocal, subscriptionName,
+                                    isCC, failoverChannelId);
+         }         
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " createConsumerDelegate");
       }
    }
-	
+      
 	public BrowserDelegate createBrowserDelegate(JBossDestination jmsDestination, String messageSelector)
 	   throws JMSException
 	{
@@ -1000,23 +694,7 @@
    }
    
    // Protected -----------------------------------------------------
-   
-   protected void acknowledgeInternal(AckInfo ackInfo) throws Throwable
-   {
-      //If the message was delivered via a connection consumer then the message needs to be acked
-      //via the original consumer that was used to feed the connection consumer - which
-      //won't be one of the consumers of this session
-      //Therefore we always look in the global map of consumers held in the server peer
-      ServerConsumerEndpoint consumer = this.connectionEndpoint.getConsumerEndpoint(ackInfo.getConsumerID());
-
-      if (consumer == null)
-      {
-         throw new IllegalArgumentException("Cannot find consumer id: " + ackInfo.getConsumerID());
-      }
       
-      consumer.acknowledge(ackInfo.getMessageID());
-   }
-   
    protected ServerConsumerEndpoint putConsumerEndpoint(int consumerID, ServerConsumerEndpoint d)
    {
       if (trace) { log.trace(this + " caching consumer " + consumerID); }
@@ -1072,6 +750,341 @@
    }   
 
    // Private -------------------------------------------------------
+   
+   private void acknowledgeInternal(AckInfo ackInfo) throws Throwable
+   {
+      //If the message was delivered via a connection consumer then the message needs to be acked
+      //via the original consumer that was used to feed the connection consumer - which
+      //won't be one of the consumers of this session
+      //Therefore we always look in the global map of consumers held in the server peer
+      ServerConsumerEndpoint consumer = this.connectionEndpoint.getConsumerEndpoint(ackInfo.getConsumerID());
 
+      if (consumer == null)
+      {
+         throw new IllegalArgumentException("Cannot find consumer id: " + ackInfo.getConsumerID());
+      }
+      
+      consumer.acknowledge(ackInfo.getMessageID());
+   }
+   
+   private ConsumerDelegate failoverConsumer(JBossDestination jmsDestination,
+            String selectorString,
+            boolean noLocal,  String subscriptionName,
+            boolean connectionConsumer,
+            long oldChannelID) throws Exception
+   {
+      //fail over channel
+      if (postOffice.isLocal())
+      {
+         throw new IllegalStateException("Cannot failover on a non clustered post office!");
+      }
+      
+      //this is a Clustered operation... so postOffice here must be Clustered
+      Binding binding = ((ClusteredPostOffice)postOffice).getBindingforChannelId(oldChannelID);
+      if (binding == null)
+      {
+         throw new IllegalStateException("Can't find failed over channel " + oldChannelID);
+      }
+      
+      // TODO - Remove this log.info before merging into trunk
+      if (binding.getQueue() instanceof RemoteQueueStub)
+      {
+         log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((RemoteQueueStub)binding.getQueue()).getChannelID());
+      }
+      else
+      {
+         log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((PagingFilteredQueue)binding.getQueue()).getChannelID());
+      }
+      
+      int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
+      
+      int prefetchSize = connectionEndpoint.getPrefetchSize();
+      
+      ServerConsumerEndpoint ep =
+         
+         new ServerConsumerEndpoint(consumerID, binding.getQueue(),
+                  binding.getQueue().getName(), this, selectorString, noLocal,
+                  jmsDestination, prefetchSize, dlq);
+      
+      JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
+      
+      ClientConsumerDelegate stub =
+         new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
+                  prefetchSize, maxDeliveryAttempts);
+      
+      
+      putConsumerEndpoint(consumerID, ep); // caching consumer locally
+      
+      connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
+      
+      return stub;
+   }
+   
+   private ConsumerDelegate createConsumerDelegateInternal(JBossDestination jmsDestination,
+            String selectorString,
+            boolean noLocal,
+            String subscriptionName,
+            boolean isCC) throws Throwable
+   {
+      if (closed)
+      {
+         throw new IllegalStateException("Session is closed");
+      }
+      
+      if ("".equals(selectorString))
+      {
+         selectorString = null;
+      }
+      
+      log.debug("creating consumer for " + jmsDestination + ", selector " + selectorString + ", " + (noLocal ? "noLocal, " : "") + "subscription " + subscriptionName);
+      
+      ManagedDestination mDest = dm.getDestination(jmsDestination.getName(), jmsDestination.isQueue());
+      
+      if (mDest == null)
+      {
+         throw new InvalidDestinationException("No such destination: " + jmsDestination);
+      }
+      
+      if (jmsDestination.isTemporary())
+      {
+         // Can only create a consumer for a temporary destination on the same connection
+         // that created it
+         if (!connectionEndpoint.hasTemporaryDestination(jmsDestination))
+         {
+            String msg = "Cannot create a message consumer on a different connection " +
+            "to that which created the temporary destination";
+            throw new IllegalStateException(msg);
+         }
+      }
+      
+      int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
+      
+      Binding binding = null;
+      
+      //Always validate the selector first
+      Selector selector = null;
+      if (selectorString != null)
+      {
+         selector = new Selector(selectorString);
+      }
+      
+      if (jmsDestination.isTopic())
+      {
+         JMSCondition topicCond = new JMSCondition(false, jmsDestination.getName());
+         
+         if (subscriptionName == null)
+         {
+            // non-durable subscription
+            if (log.isTraceEnabled()) { log.trace("creating new non-durable subscription on " + jmsDestination); }
+            
+            // Create the non durable sub
+            QueuedExecutor executor = (QueuedExecutor)pool.get();
+            
+            PagingFilteredQueue q;
+            
+            if (postOffice.isLocal())
+            {
+               q = new PagingFilteredQueue(new GUID().toString(), idm.getId(), ms, pm, true, false,
+                        executor, selector,
+                        mDest.getFullSize(),
+                        mDest.getPageSize(),
+                        mDest.getDownCacheSize());
+               
+               binding = postOffice.bindQueue(topicCond, q);
+            }
+            else
+            {
+               q = new LocalClusteredQueue(postOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
+                        executor, selector, tr,
+                        mDest.getFullSize(),
+                        mDest.getPageSize(),
+                        mDest.getDownCacheSize());
+               
+               ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
+               
+               if (mDest.isClustered())
+               {
+                  binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
+               }
+               else
+               {
+                  binding = cpo.bindQueue(topicCond, q);
+               }
+            }
+         }
+         else
+         {
+            if (jmsDestination.isTemporary())
+            {
+               throw new InvalidDestinationException("Cannot create a durable subscription on a temporary topic");
+            }
+            
+            // we have a durable subscription, look it up
+            String clientID = connectionEndpoint.getClientID();
+            if (clientID == null)
+            {
+               throw new JMSException("Cannot create durable subscriber without a valid client ID");
+            }
+            
+            // See if there any bindings with the same client_id.subscription_name name
+            
+            String name = MessageQueueNameHelper.createSubscriptionName(clientID, subscriptionName);
+            
+            binding = postOffice.getBindingForQueueName(name);
+            
+            if (binding == null)
+            {
+               // Does not already exist
+               
+               if (trace) { log.trace("creating new durable subscription on " + jmsDestination); }
+               
+               QueuedExecutor executor = (QueuedExecutor)pool.get();
+               PagingFilteredQueue q;
+               
+               if (postOffice.isLocal())
+               {
+                  q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
+                           executor, selector,
+                           mDest.getFullSize(),
+                           mDest.getPageSize(),
+                           mDest.getDownCacheSize());
+                  
+                  binding = postOffice.bindQueue(topicCond, q);
+               }
+               else
+               {
+                  q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                           executor, selector, tr,
+                           mDest.getFullSize(),
+                           mDest.getPageSize(),
+                           mDest.getDownCacheSize());
+                  
+                  ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
+                  
+                  if (mDest.isClustered())
+                  {
+                     binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
+                  }
+                  else
+                  {
+                     binding = cpo.bindQueue(topicCond, q);
+                  }
+               }
+            }
+            else
+            {
+               //Durable sub already exists
+               
+               if (trace) { log.trace("subscription " + subscriptionName + " already exists"); }
+               
+               // From javax.jms.Session Javadoc (and also JMS 1.1 6.11.1):
+               // A client can change an existing durable subscription by creating a durable
+               // TopicSubscriber with the same name and a new topic and/or message selector.
+               // Changing a durable subscriber is equivalent to unsubscribing (deleting) the old
+               // one and creating a new one.
+               
+               String filterString = binding.getQueue().getFilter() != null ? binding.getQueue().getFilter().getFilterString() : null;
+               
+               boolean selectorChanged =
+                  (selectorString == null && filterString != null) ||
+                  (filterString == null && selectorString != null) ||
+                  (filterString != null && selectorString != null &&
+                           !filterString.equals(selectorString));
+               
+               if (trace) { log.trace("selector " + (selectorChanged ? "has" : "has NOT") + " changed"); }
+               
+               boolean topicChanged = !binding.getCondition().equals(jmsDestination.getName());
+               
+               if (log.isTraceEnabled()) { log.trace("topic " + (topicChanged ? "has" : "has NOT") + " changed"); }
+               
+               if (selectorChanged || topicChanged)
+               {
+                  if (trace) { log.trace("topic or selector changed so deleting old subscription"); }
+                  
+                  // Unbind the durable subscription
+                  
+                  if (mDest.isClustered() && !postOffice.isLocal())
+                  {
+                     ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
+                     
+                     cpo.unbindClusteredQueue(name);
+                  }
+                  else
+                  {
+                     postOffice.unbindQueue(name);
+                  }
+                  
+                  // create a fresh new subscription
+                  
+                  QueuedExecutor executor = (QueuedExecutor)pool.get();
+                  PagingFilteredQueue q;
+                  
+                  if (postOffice.isLocal())
+                  {
+                     q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
+                              executor, selector,
+                              mDest.getFullSize(),
+                              mDest.getPageSize(),
+                              mDest.getDownCacheSize());
+                     binding = postOffice.bindQueue(topicCond, q);
+                  }
+                  else
+                  {
+                     q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                              executor, selector, tr,
+                              mDest.getFullSize(),
+                              mDest.getPageSize(),
+                              mDest.getDownCacheSize());
+                     
+                     ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
+                     
+                     if (mDest.isClustered())
+                     {
+                        binding = cpo.bindClusteredQueue(topicCond, (LocalClusteredQueue)q);
+                     }
+                     else
+                     {
+                        binding = cpo.bindQueue(topicCond, (LocalClusteredQueue)q);
+                     }
+                  }
+               }
+            }
+         }
+      }
+      else
+      {
+         // Consumer on a jms queue
+         
+         // Let's find the binding
+         binding = postOffice.getBindingForQueueName(jmsDestination.getName());
+         
+         if (binding == null)
+         {
+            throw new IllegalStateException("Cannot find binding for jms queue: " + jmsDestination.getName());
+         }
+      }
+      
+      int prefetchSize = connectionEndpoint.getPrefetchSize();
+      
+      ServerConsumerEndpoint ep =
+         new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
+                  binding.getQueue().getName(), this, selectorString, noLocal,
+                  jmsDestination, prefetchSize, dlq);
+      
+      JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
+      
+      ClientConsumerDelegate stub =
+         new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
+                  prefetchSize, maxDeliveryAttempts);
+      
+      putConsumerEndpoint(consumerID, ep); // caching consumer locally
+      
+      connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
+      
+      log.debug("created and registered " + ep);
+      
+      return stub;
+   }
+
    // Inner classes -------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -46,15 +46,10 @@
  */
 public interface SessionEndpoint extends Closeable
 {
-   ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
-                                     String selectorString,
-                                     boolean noLocal,  String subscriptionName,
-                                     boolean connectionConsumer,
-                                     long oldchannelID) throws JMSException;
-
    ConsumerDelegate createConsumerDelegate(JBossDestination destination, String selector,
                                            boolean noLocal, String subscriptionName,
-                                           boolean connectionConsumer) throws JMSException;
+                                           boolean connectionConsumer,
+                                           long failoverChannelID) throws JMSException;
    
    BrowserDelegate createBrowserDelegate(JBossDestination queue, String messageSelector)
       throws JMSException;

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -86,22 +86,11 @@
    
    public ConsumerDelegate createConsumerDelegate(JBossDestination destination, String selector,
                                                   boolean noLocal, String subscriptionName,
-                                                  boolean connectionConsumer) throws JMSException
+                                                  boolean connectionConsumer, long failoverChannelId) throws JMSException
    {
-      return endpoint.createConsumerDelegate(destination, selector, noLocal, subscriptionName, connectionConsumer);
+      return endpoint.createConsumerDelegate(destination, selector, noLocal, subscriptionName, connectionConsumer, failoverChannelId);
    }
    
-   public ConsumerDelegate failOverConsumer(JBossDestination jmsDestination,
-                                            String selectorString,
-                                            boolean noLocal,  String subscriptionName,
-                                            boolean connectionConsumer,
-                                            long oldChannelID) throws JMSException
-   {
-      return endpoint.failOverConsumer(jmsDestination, selectorString, noLocal,
-                                       subscriptionName, connectionConsumer,
-                                       oldChannelID);
-   }
-
    public BrowserDelegate createBrowserDelegate(JBossDestination queue, String messageSelector)
       throws JMSException
    {

Modified: trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/server/remoting/MetaDataConstants.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -36,26 +36,8 @@
    public static final String REMOTING_SESSION_ID = "REMOTING_SESSION_ID";
    
    public static final String CALLBACK_HANDLER = "CALLBACK_HANDLER";
-   
-   public static final String CONSUMER_ID = "CONSUMER_ID";   
-   
-   public static final String PREFETCH_SIZE = "BUFFER_SIZE";
-   
-   public static final String CLIENT_CONNECTION_ID = "CC_ID";
-   
+    
    public static final String VERSION_NUMBER = "VERSION_NUMBER";
    
    public static final String JMS_CLIENT_VM_ID = "JMS_CLIENT_VM_ID";
-
-   public static final String CF_DELEGATES = "CF_DELEGATES";
-   
-   public static final String SERVER_ID = "SERVER_ID";
-   
-   public static final String REMOTING_CONNECTION = "REMOTING_CONNECTION";
-   
-   public static final String FAILOVER_MAP = "CF_FAIL_IND";
-   
-   public static final String CONNECTION_VERSION = "CONNECTION_VERSION";
-
-   public static final String MAX_DELIVERIES = "MAX_DELS";
 }

Modified: trunk/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -27,6 +27,7 @@
 import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
+import java.util.Set;
 
 import javax.jms.IllegalStateException;
 import javax.jms.JMSException;
@@ -72,11 +73,7 @@
    private static final Logger log = Logger.getLogger(ResourceManager.class);
    
    // Constructors --------------------------------------------------
-   
-   protected ResourceManager()
-   {      
-   }
-   
+    
    // Public --------------------------------------------------------
    
    public TxState getTx(Object xid)
@@ -123,14 +120,56 @@
     /**
      * Navigate on ACK and change consumer ids on every ACK not sent yet.
      */
-    public void handleFailover(Object xid, int oldConsumerID, int newConsumerID)
+    public void handleFailover(int oldConsumerID, int newConsumerID)
     {
         if (trace) { log.trace("handleFailover:: Transfering consumer id on ACKs from  " + oldConsumerID + " to " + newConsumerID); }
 
-        TxState tx = getTx(xid);
+        //TODO need to lock the rm while this is happening
         
-        tx.handleFailover(oldConsumerID, newConsumerID);
+        //Note we need to replace ids for *all* transactions - this is because, for XA
+        //the session might have done work in many transactions
+        Iterator iter = this.transactions.values().iterator();
+        
+        while (iter.hasNext())
+        {
+           TxState tx = (TxState)iter.next();
+           
+           tx.handleFailover(oldConsumerID, newConsumerID);
+        }                
     }
+    
+    /*
+     * Get all the ackinfos with a consumer id in the specified set
+     */
+    public List getAckInfosForConsumerIds(Set consumerIds)
+    {
+       Iterator iter = this.transactions.values().iterator();
+       
+       List ackInfos = new ArrayList();
+       
+       while (iter.hasNext())
+       {
+          TxState tx = (TxState)iter.next();
+          
+          tx.getAckInfosForConsumerIds(ackInfos, consumerIds);
+       }
+       
+       return ackInfos;
+    }
+    
+    public void removeNonPersistentAcks(Set consumerIds)
+    {
+       Iterator iter = this.transactions.values().iterator();
+       
+       List ackInfos = new ArrayList();
+       
+       while (iter.hasNext())
+       {
+          TxState tx = (TxState)iter.next();
+          
+          tx.removeNonPersistentAcks(consumerIds);
+       }
+    }
 
    
    /**

Deleted: trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -1,107 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.tx;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * This class manages instances of ResourceManager. It ensures there is one instance per instance
- * of JMS server as specified by the server id.
- * 
- * This allows different JMS connections to the same JMS server (the underlying resource is the JMS server)
- * to use the same resource manager.
- * 
- * This means isSameRM() on XAResource returns true, allowing the Transaction manager to join work in one
- * tx to another thus allowing 1PC optimization which should help performance.
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version $Revision$
- *
- * $Id$
- */
-public class ResourceManagerFactory
-{      
-   public static final ResourceManagerFactory instance = new ResourceManagerFactory();
-   
-   private Map holders;
-   
-   private ResourceManagerFactory()
-   {      
-      holders = new HashMap();
-   }
-      
-   public synchronized boolean containsResourceManager(int serverID)
-   {
-      return holders.containsKey(new Integer(serverID));
-   }
-   
-   /**
-    * @param serverID - server peer ID.
-    */
-   public synchronized ResourceManager checkOutResourceManager(int serverID)
-   {
-      Integer in = new Integer(serverID);
-      
-      Holder h = (Holder)holders.get(in);
-      
-      if (h == null)
-      {
-         h = new Holder();
-         
-         holders.put(in, h);
-      }
-      else
-      {
-         h.refCount++;
-      }
-      
-      return h.rm;
-   }
-   
-   public synchronized void checkInResourceManager(int serverID)
-   {
-      Integer in = new Integer(serverID);
-      
-      Holder h = (Holder)holders.get(in);
-      
-      if (h == null)
-      {
-         throw new IllegalArgumentException("Cannot find resource manager for server: " + serverID);
-      }
-      
-      h.refCount--;
-      
-      if (h.refCount == 0)
-      {
-         holders.remove(in);
-      }      
-   }
-   
-   private static class Holder
-   {
-      ResourceManager rm = new ResourceManager();
-      
-      int refCount = 1;
-   }
-  
-}

Modified: trunk/src/main/org/jboss/jms/tx/TxState.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -26,6 +26,7 @@
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.List;
+import java.util.Set;
 
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.messaging.core.message.MessageFactory;
@@ -110,6 +111,32 @@
            }
        }
    }
+   
+   public void getAckInfosForConsumerIds(List ackInfos, Set consumerIds)
+   {
+      for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
+      {
+          AckInfo ackInfo = (AckInfo)ackIterator.next();
+          
+          if (consumerIds.contains(new Integer(ackInfo.getConsumerID())))
+          {
+              ackInfos.add(ackInfo);
+          }
+      }
+   }
+   
+   public void removeNonPersistentAcks(Set consumerIds)
+   {
+      for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
+      {
+          AckInfo ackInfo = (AckInfo)ackIterator.next();
+          
+          if (!ackInfo.msg.getMessage().isReliable())
+          {
+             ackIterator.remove();
+          }
+      }
+   }
     
    // Streamable implementation ---------------------------------
    

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/tests/build.xml	2006-12-12 18:25:55 UTC (rev 1771)
@@ -387,7 +387,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/messaging/core/**/*Test.class"/>
+               <!-- <include name="**/messaging/core/**/*Test.class"/> -->
                <include name="**/messaging/jms/**/*Test.class"/>
                <exclude name="**/jms/stress/**"/>
                <exclude name="**/jms/crash/*Test.class"/>
@@ -745,7 +745,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/HATest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -44,8 +44,6 @@
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.ServerPeer;
-import org.jboss.jms.tx.ResourceManager;
-import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.InvocationRequest;
 import org.jboss.remoting.ServerInvocationHandler;
@@ -121,42 +119,8 @@
          Connection conn = cf.createConnection();
          conn.close();        
       }
-   }
+   }     
    
-   public void testResourceManagersForSameServer() throws Exception
-   {
-      Connection conn1 = cf.createConnection();      
-            
-      ClientConnectionDelegate del1 = (ClientConnectionDelegate)((JBossConnection)conn1).getDelegate();
-      
-      ConnectionState state1 = (ConnectionState)del1.getState();
-      
-      ResourceManager rm1 = state1.getResourceManager();
-      
-      Connection conn2 = cf.createConnection();      
-      
-      ClientConnectionDelegate del2 = (ClientConnectionDelegate)((JBossConnection)conn2).getDelegate();
-      
-      ConnectionState state2 = (ConnectionState)del2.getState();
-      
-      ResourceManager rm2 = state2.getResourceManager();
-
-      //Two connections for same server should share the same resource manager
-      
-      assertTrue(rm1 == rm2);
-      
-      assertTrue(ResourceManagerFactory.instance.containsResourceManager(state2.getServerID()));
-      
-      conn1.close();
-      
-      //Check reference counting
-      assertTrue(ResourceManagerFactory.instance.containsResourceManager(state2.getServerID()));
-           
-      conn2.close();
-      
-      assertFalse(ResourceManagerFactory.instance.containsResourceManager(state2.getServerID()));     
-   }
-   
    public void testMessageIDGeneratorsForSameServer() throws Exception
    {
       Connection conn1 = cf.createConnection();      

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 10:49:42 UTC (rev 1770)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 18:25:55 UTC (rev 1771)
@@ -37,6 +37,7 @@
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
@@ -69,489 +70,489 @@
    }
    
    // Public --------------------------------------------------------
-//   
-//   /*
-//    * Test that connections created using a clustered connection factory are created round robin on
-//    * different servers
-//    */
-//   public void testRoundRobinConnectionCreation() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//      
-//      log.info ("number of delegates = " + delegate.getDelegates().length);
-//      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
-//      
-//      assertEquals(3, delegate.getDelegates().length);
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//      
-//      assertEquals(0, cf1.getServerId());
-//      
-//      assertEquals(1, cf2.getServerId());
-//      
-//      assertEquals(2, cf3.getServerId());
-//      
-//      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-//      
-//      Connection conn1 = null;
-//      
-//      Connection conn2 = null;
-//      
-//      Connection conn3 = null;
-//      
-//      Connection conn4 = null;
-//      
-//      Connection conn5 = null;
-//      
-//      try
-//      {         
-//         conn1 = factory.createConnection();
-//         
-//         conn2 = factory.createConnection();
-//         
-//         conn3 = factory.createConnection();
-//         
-//         conn4 = factory.createConnection();
-//         
-//         conn5 = factory.createConnection();
-//         
-//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-//         
-//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-//         
-//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-//         
-//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-//         
-//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-//         
-//         int serverID1 = state1.getServerID();
-//         
-//         int serverID2 = state2.getServerID();
-//         
-//         int serverID3 = state3.getServerID();
-//         
-//         int serverID4 = state4.getServerID();
-//         
-//         int serverID5 = state5.getServerID();
-//         
-//         log.info("server id 1: " + serverID1);
-//         
-//         log.info("server id 2: " + serverID2);
-//         
-//         log.info("server id 3: " + serverID3);
-//         
-//         log.info("server id 4: " + serverID4);
-//         
-//         log.info("server id 5: " + serverID5);
-//         
-//         assertEquals(0, serverID1);
-//         
-//         assertEquals(1, serverID2);
-//         
-//         assertEquals(2, serverID3);
-//         
-//         assertEquals(0, serverID4);
-//         
-//         assertEquals(1, serverID5);
-//      }
-//      finally
-//      {
-//         if (conn1 != null)
-//         {
-//            conn1.close();
-//         }
-//         
-//         if (conn2 != null)
-//         {
-//            conn2.close();
-//         }
-//         
-//         if (conn3 != null)
-//         {
-//            conn3.close();
-//         }
-//         
-//         if (conn4 != null)
-//         {
-//            conn4.close();
-//         }
-//         
-//         if (conn5 != null)
-//         {
-//            conn5.close();
-//         }
-//      }
-//      
-//   }
-// 
-//   /*
-//    * Test that the failover mapping is created correctly and updated properly when nodes leave
-//    * or join
-//    */
-//   public void testDefaultFailoverMap() throws Exception
-//   {     
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         //The order here depends on the order the servers were started in
-//         
-//         //If any servers get stopped and then started then the order will change
-//    
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         
-//         assertEquals(0, cf1.getServerId());
-//         
-//         assertEquals(1, cf2.getServerId());
-//         
-//         assertEquals(2, cf3.getServerId());
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         // Default failover policy just chooses the node to the right
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }
-//      
-//      //Now cleanly stop one of the servers
-//            
-//      log.info("************** STOPPING SERVER 0");
-//      ServerManagement.stop(0);
-//      
-//      log.info("server stopped");
-//      
-//      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         //Order here depends on order servers were started in
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(1, cf1.getServerId());
-//         
-//         assertEquals(2, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      //Cleanly stop another server
-//      
-//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-//      
-//      ServerManagement.stop(1);
-//      
-//      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(1, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         
-//         assertEquals(1, failoverMap.size());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//      }
-//            
-//      //Restart server 0
-//      
-//      ServerManagement.start("all", 0);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      
-//      //Restart server 1
-//      
-//      ServerManagement.start("all", 1);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         assertEquals(1, cf3.getServerId());
-//         
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }            
-//   }
-//   
-//   public void testSimpleFailover() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//      
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//      
-//      int server0Id = cf1.getServerId();
-//      
-//      int server1Id = cf2.getServerId();
-//      
-//      int server2Id = cf3.getServerId();
-//      
-//      log.info("server 0 id: " + server0Id);
-//      
-//      log.info("server 1 id: " + server1Id);
-//      
-//      log.info("server 2 id: " + server2Id);
-//                  
-//      Map failoverMap = delegate.getFailoverMap();
-//      
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//      
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//      
-//      // server 1 should failover onto server 2
-//      
-//      assertEquals(server2Id, server1FailoverId);
-//      
-//      Connection conn = null;
-//      
-//      try
-//      {
-//      
-//         //Get a connection on server 1
-//         conn = factory.createConnection(); //connection on server 0
-//         
-//         conn.close();
-//         
-//         conn = factory.createConnection(); //connection on server 1
-//         
-//         JBossConnection jbc = (JBossConnection)conn;
-//         
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//         
-//         ConnectionState state = (ConnectionState)del.getState();
-//         
-//         int initialServerID = state.getServerID();
-//         
-//         assertEquals(1, initialServerID);
-//                           
-//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//         
-//         MessageProducer prod = sess.createProducer(queue1);
-//         
-//         MessageConsumer cons = sess.createConsumer(queue1);
-//         
-//         final int NUM_MESSAGES = 100;
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//            
-//            prod.send(tm);
-//         }
-//         
-//         //So now, messages should be in queue1 on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//         
-//         log.info("************ KILLING (CRASHING) SERVER 1");
-//         
-//         ServerManagement.getServer(1).destroy();
-//         
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(5000);
-//         
-//         log.info("done wait");
-//         
-//         state = (ConnectionState)del.getState();
-//         
-//         int finalServerID = state.getServerID();
-//         
-//         log.info("final server id= " + finalServerID);
-//         
-//         //server id should now be 2
-//         
-//         assertEquals(2, finalServerID);
-//         
-//         conn.start();
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(1000);
-//            
-//            log.info("message is " + tm);
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         log.info("done");
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//      }
-//      
-//   }
    
+   /*
+    * Test that connections created using a clustered connection factory are created round robin on
+    * different servers
+    */
+   public void testRoundRobinConnectionCreation() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      log.info ("number of delegates = " + delegate.getDelegates().length);
+      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
+      
+      assertEquals(3, delegate.getDelegates().length);
+      
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
+      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+      
+      Connection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      Connection conn4 = null;
+      
+      Connection conn5 = null;
+      
+      try
+      {         
+         conn1 = factory.createConnection();
+         
+         conn2 = factory.createConnection();
+         
+         conn3 = factory.createConnection();
+         
+         conn4 = factory.createConnection();
+         
+         conn5 = factory.createConnection();
+         
+         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+         
+         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+         
+         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+         
+         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+         
+         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+         
+         int serverID1 = state1.getServerID();
+         
+         int serverID2 = state2.getServerID();
+         
+         int serverID3 = state3.getServerID();
+         
+         int serverID4 = state4.getServerID();
+         
+         int serverID5 = state5.getServerID();
+         
+         log.info("server id 1: " + serverID1);
+         
+         log.info("server id 2: " + serverID2);
+         
+         log.info("server id 3: " + serverID3);
+         
+         log.info("server id 4: " + serverID4);
+         
+         log.info("server id 5: " + serverID5);
+         
+         assertEquals(0, serverID1);
+         
+         assertEquals(1, serverID2);
+         
+         assertEquals(2, serverID3);
+         
+         assertEquals(0, serverID4);
+         
+         assertEquals(1, serverID5);
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+         
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+         
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
+      }
+      
+   }
+ 
+   /*
+    * Test that the failover mapping is created correctly and updated properly when nodes leave
+    * or join
+    */
+   public void testDefaultFailoverMap() throws Exception
+   {     
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         //The order here depends on the order the servers were started in
+         
+         //If any servers get stopped and then started then the order will change
+    
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         
+         assertEquals(0, cf1.getServerId());
+         
+         assertEquals(1, cf2.getServerId());
+         
+         assertEquals(2, cf3.getServerId());
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(3, delegates.length);
+         
+         assertEquals(3, failoverMap.size());
+         
+         // Default failover policy just chooses the node to the right
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }
+      
+      //Now cleanly stop one of the servers
+            
+      log.info("************** STOPPING SERVER 0");
+      ServerManagement.stop(0);
+      
+      log.info("server stopped");
+      
+      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         //Order here depends on order servers were started in
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(1, cf1.getServerId());
+         
+         assertEquals(2, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      //Cleanly stop another server
+      
+      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+      
+      ServerManagement.stop(1);
+      
+      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(1, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         assertEquals(2, cf1.getServerId());
+         
+         
+         assertEquals(1, failoverMap.size());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+      }
+            
+      //Restart server 0
+      
+      ServerManagement.start("all", 0);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      
+      //Restart server 1
+      
+      ServerManagement.start("all", 1);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(3, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         assertEquals(1, cf3.getServerId());
+         
+         
+         assertEquals(3, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }            
+   }
    
+   public void testSimpleFailover() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
+      int server0Id = cf1.getServerId();
+      
+      int server1Id = cf2.getServerId();
+      
+      int server2Id = cf3.getServerId();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+      
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+      
+      // server 1 should failover onto server 2
+      
+      assertEquals(server2Id, server1FailoverId);
+      
+      Connection conn = null;
+      
+      try
+      {
+      
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
+         
+         conn.close();
+         
+         conn = factory.createConnection(); //connection on server 1
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(1, initialServerID);
+                           
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess.createProducer(queue1);
+         
+         MessageConsumer cons = sess.createConsumer(queue1);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         //So now, messages should be in queue1 on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 1");
+         
+         ServerManagement.getServer(1).kill();
+         
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(5000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 2
+         
+         assertEquals(2, finalServerID);
+         
+         conn.start();
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(1000);
+            
+            log.info("message is " + tm);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         log.info("done");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+      }
+      
+   }
+   
+   
    public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
@@ -723,178 +724,178 @@
       
    }
    
-//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//      
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//      
-//      int server0Id = cf1.getServerId();
-//      
-//      int server1Id = cf2.getServerId();
-//      
-//      int server2Id = cf3.getServerId();
-//      
-//      log.info("server 0 id: " + server0Id);
-//      
-//      log.info("server 1 id: " + server1Id);
-//      
-//      log.info("server 2 id: " + server2Id);
-//                  
-//      Map failoverMap = delegate.getFailoverMap();
-//      
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//      
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//      
-//      // server 1 should failover onto server 2
-//      
-//      assertEquals(server2Id, server1FailoverId);
-//      
-//      Connection conn = null;
-//      
-//      try
-//      {      
-//         //Get a connection on server 1
-//         conn = factory.createConnection(); //connection on server 0
-//         
-//         conn.close();
-//         
-//         conn = factory.createConnection(); //connection on server 1
-//         
-//         JBossConnection jbc = (JBossConnection)conn;
-//         
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//         
-//         ConnectionState state = (ConnectionState)del.getState();
-//         
-//         int initialServerID = state.getServerID();
-//         
-//         assertEquals(1, initialServerID);
-//                           
-//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-//         
-//         MessageProducer prod = sess.createProducer(queue1);
-//         
-//         MessageConsumer cons = sess.createConsumer(queue1);
-//         
-//         final int NUM_MESSAGES = 100;
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//            
-//            prod.send(tm);
-//         }
-//         
-//         sess.commit();
-//         
-//         conn.start();
-//         
-//         //Now consume half of the messages but don't commit them these will end up in 
-//         //client side resource manager
-//         
-//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(500);
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         //So now, messages should be in queue1 on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//         
-//         log.info("************ KILLING (CRASHING) SERVER 1");
-//         
-//         ServerManagement.getServer(1).kill();
-//
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(5000);
-//         
-//         log.info("done wait");
-//         
-//         state = (ConnectionState)del.getState();
-//         
-//         int finalServerID = state.getServerID();
-//         
-//         log.info("final server id= " + finalServerID);
-//         
-//         //server id should now be 2
-//         
-//         assertEquals(2, finalServerID);
-//         
-//         conn.start();
-//         
-//         //Now should be able to consume the rest of the messages
-//         
-//         log.info("here1");
-//         
-//         TextMessage tm = null;
-//         
-//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-//         {
-//            tm = (TextMessage)cons.receive(500);
-//                                    
-//            log.info("message is " + tm.getText());
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         log.info("here2");
-//         
-//         //Now should be able to commit them
-//         
-//         sess.commit();
-//         
-//         //Now check there are no more messages there
-//         sess.close();
-//         
-//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//         
-//         cons = sess.createConsumer(queue1);
-//         
-//         Message m = cons.receive(500);
-//         
-//         assertNull(m);
-//         
-//         log.info("got to end of test");
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//      }
-//      
-//   }
+   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
+      int server0Id = cf1.getServerId();
+      
+      int server1Id = cf2.getServerId();
+      
+      int server2Id = cf3.getServerId();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+      
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+      
+      // server 1 should failover onto server 2
+      
+      assertEquals(server2Id, server1FailoverId);
+      
+      Connection conn = null;
+      
+      try
+      {      
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
+         
+         conn.close();
+         
+         conn = factory.createConnection(); //connection on server 1
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(1, initialServerID);
+                           
+         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+         
+         MessageProducer prod = sess.createProducer(queue1);
+         
+         MessageConsumer cons = sess.createConsumer(queue1);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         sess.commit();
+         
+         conn.start();
+         
+         //Now consume half of the messages but don't commit them these will end up in 
+         //client side resource manager
+         
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         //So now, messages should be in queue1 on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 1");
+         
+         ServerManagement.getServer(1).kill();
+
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(5000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 2
+         
+         assertEquals(2, finalServerID);
+         
+         conn.start();
+         
+         //Now should be able to consume the rest of the messages
+         
+         log.info("here1");
+         
+         TextMessage tm = null;
+         
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+         {
+            tm = (TextMessage)cons.receive(500);
+                                    
+            log.info("message is " + tm.getText());
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         log.info("here2");
+         
+         //Now should be able to commit them
+         
+         sess.commit();
+         
+         //Now check there are no more messages there
+         sess.close();
+         
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons = sess.createConsumer(queue1);
+         
+         Message m = cons.receive(500);
+         
+         assertNull(m);
+         
+         log.info("got to end of test");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+      }
+      
+   }
    
    
    



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 13:30:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 13:30:11 -0500
Subject: [jboss-cvs] JBossAS SVN: r59002 - in
	projects/microcontainer/trunk/spring-int/src:
	main/org/jboss/spring/deployment/xml resources/schema
Message-ID: <E1GuCOJ-00021q-Di@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 13:30:05 -0500 (Tue, 12 Dec 2006)
New Revision: 59002

Added:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapKeyHandler.java
Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
   projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
Log:
JBMICROCONT-26; inital code

Added: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapKeyHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapKeyHandler.java	2006-12-12 18:11:10 UTC (rev 59001)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringMapKeyHandler.java	2006-12-12 18:30:05 UTC (rev 59002)
@@ -0,0 +1,45 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.deployment.xml;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractValueMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SpringMapKeyHandler extends DefaultElementHandler
+{
+   /**
+    * The map key handler
+    */
+   public static final SpringMapKeyHandler HANDLER = new SpringMapKeyHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractValueMetaData();
+   }
+
+}

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-12 18:11:10 UTC (rev 59001)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-12 18:30:05 UTC (rev 59002)
@@ -138,6 +138,11 @@
    public static final QName entryQName = new QName(SPRING_DEPLOYER_NS, "entry");
 
    /**
+    * The key binding
+    */
+   public static final QName keyTypeQName = new QName(SPRING_DEPLOYER_NS, "keyType");
+
+   /**
     * The key element name
     */
    public static final QName keyQName = new QName(SPRING_DEPLOYER_NS, "key");
@@ -207,6 +212,10 @@
       // entry type
       TypeBinding entryType = schemaBinding.getType(entryTypeQName);
       SpringSchemaBindingHelper.initEntryHandler(entryType);
+
+      // key type
+      TypeBinding keyType = schemaBinding.getType(entryTypeQName);
+      SpringSchemaBindingHelper.initKeyHandler(keyType);
    }
 
 }

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 18:11:10 UTC (rev 59001)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-12 18:30:05 UTC (rev 59002)
@@ -103,6 +103,13 @@
       typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, EntryValueInterceptor.INTERCEPTOR);
    }
 
+   public static void initKeyHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(SpringMapKeyHandler.HANDLER);
+      // key has a value
+      typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, ValueMetaDataElementInterceptor.VALUES);
+   }
+
    public static void configureValueBindings(TypeBinding typeBinding)
    {
       // type has values

Modified: projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-12 18:11:10 UTC (rev 59001)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-12 18:30:05 UTC (rev 59002)
@@ -948,17 +948,18 @@
       </xsd:annotation>
    </xsd:element>
 
-   <xsd:element name="key">
+   <xsd:element name="key" type="keyType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	A key element can contain an inner bean, ref, value, or collection.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType>
-         <xsd:group ref="collectionElements"/>
-      </xsd:complexType>
    </xsd:element>
 
+   <xsd:complexType name="keyType">
+      <xsd:group ref="collectionElements"/>
+   </xsd:complexType>
+
    <xsd:element name="prop">
       <xsd:annotation>
          <xsd:documentation><![CDATA[



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 14:03:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 14:03:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r59003 - in
	projects/microcontainer/trunk/spring-int/src:
	main/org/jboss/spring/deployment/xml
	resources/org/jboss/test/spring/test
	tests/org/jboss/test/spring/test
Message-ID: <E1GuCu8-0002ig-UO@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-12 14:02:55 -0500 (Tue, 12 Dec 2006)
New Revision: 59003

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
Log:
JBMICROCONT-26; inital code

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-12 18:30:05 UTC (rev 59002)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-12 19:02:55 UTC (rev 59003)
@@ -28,11 +28,9 @@
 import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
 import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
 import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
-import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
-import org.jboss.beans.metadata.spi.ConstructorMetaData;
 import org.jboss.beans.metadata.spi.ParameterMetaData;
-import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
 import org.jboss.spring.deployment.AbstractConstructorArg;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
 
 /**
  * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
@@ -61,6 +59,7 @@
       }
       if (parameter instanceof AbstractConstructorArg && ((AbstractConstructorArg)parameter).isExplicitIndex() == false)
       {
+         // actual order is done in SpringBeanHandler
          parameter.setIndex(parameters.size());
       }
       parameters.add(parameter);

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-12 18:30:05 UTC (rev 59002)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-12 19:02:55 UTC (rev 59003)
@@ -24,10 +24,16 @@
 import javax.xml.namespace.NamespaceContext;
 import javax.xml.namespace.QName;
 
+import java.util.List;
+import java.util.Collections;
+import java.util.Comparator;
+
 import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
 import org.jboss.beans.metadata.plugins.AbstractLifecycleMetaData;
 import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
 import org.jboss.beans.metadata.plugins.AbstractDependencyValueMetaData;
+import org.jboss.beans.metadata.spi.ConstructorMetaData;
+import org.jboss.beans.metadata.spi.ParameterMetaData;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
 import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
 import org.xml.sax.Attributes;
@@ -77,4 +83,29 @@
       }
    }
 
+   public Object endElement(Object object, QName qName, ElementBinding elementBinding)
+   {
+      AbstractBeanMetaData beanMetaData = (AbstractBeanMetaData) object;
+      ConstructorMetaData constructor = beanMetaData.getConstructor();
+      if (constructor != null)
+      {
+         List<ParameterMetaData> parameters = constructor.getParameters();
+         if (parameters != null && parameters.size() > 1)
+         {
+            Collections.sort(parameters, ParameterIndexComparator.INSTANCE);
+         }
+      }
+      return beanMetaData;
+   }
+
+   private static class ParameterIndexComparator implements Comparator<ParameterMetaData>
+   {
+      static Comparator<ParameterMetaData> INSTANCE = new ParameterIndexComparator();
+
+      public int compare(ParameterMetaData pmd1, ParameterMetaData pmd2)
+      {
+         return 0; // todo
+      }
+   }
+
 }

Modified: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 18:30:05 UTC (rev 59002)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-12 19:02:55 UTC (rev 59003)
@@ -18,6 +18,7 @@
          <value>one</value>
       </set>
    </property>
+<!--
    <property name="map">
       <entry>
          <key>
@@ -26,4 +27,5 @@
          <value>key</value>
       </entry>
    </property>
+-->
 </bean>

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-12 18:30:05 UTC (rev 59002)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-12 19:02:55 UTC (rev 59003)
@@ -22,7 +22,7 @@
 package org.jboss.test.spring.test;
 
 import junit.framework.Test;
-import org.jboss.test.spring.support.SimpleBean;
+import org.jboss.beans.metadata.spi.BeanMetaData;
 
 /**
  * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
@@ -47,8 +47,8 @@
 
    public void testInstantiate() throws Exception
    {
-      SimpleBean simpleBean = unmarshal("TestInstantiate.xml", SimpleBean.class);
-      System.out.println("simpleBean = " + simpleBean);
+      BeanMetaData simpleBeanMD = unmarshal("TestInstantiate.xml", BeanMetaData.class);
+      System.out.println("simpleBean = " + simpleBeanMD);
    }
 
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 14:13:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 14:13:07 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1772 - in trunk/tests: .
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/jms/clustering/base
	src/org/jboss/test/messaging/tools
Message-ID: <E1GuD3r-0002rL-Ji@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-12 14:13:02 -0500 (Tue, 12 Dec 2006)
New Revision: 1772

Modified:
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
Log:
Allowed for clean tearDown of clustering tests after servers are killed



Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-12 18:25:55 UTC (rev 1771)
+++ trunk/tests/build.xml	2006-12-12 19:13:02 UTC (rev 1772)
@@ -745,7 +745,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 18:25:55 UTC (rev 1771)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 19:13:02 UTC (rev 1772)
@@ -75,484 +75,484 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-   public void testRoundRobinConnectionCreation() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
-      log.info ("number of delegates = " + delegate.getDelegates().length);
-      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
-      
-      assertEquals(3, delegate.getDelegates().length);
-      
-      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
-      assertEquals(0, cf1.getServerId());
-      
-      assertEquals(1, cf2.getServerId());
-      
-      assertEquals(2, cf3.getServerId());
-      
-      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-      
-      Connection conn1 = null;
-      
-      Connection conn2 = null;
-      
-      Connection conn3 = null;
-      
-      Connection conn4 = null;
-      
-      Connection conn5 = null;
-      
-      try
-      {         
-         conn1 = factory.createConnection();
-         
-         conn2 = factory.createConnection();
-         
-         conn3 = factory.createConnection();
-         
-         conn4 = factory.createConnection();
-         
-         conn5 = factory.createConnection();
-         
-         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
-         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
-         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
-         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
-         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
-         int serverID1 = state1.getServerID();
-         
-         int serverID2 = state2.getServerID();
-         
-         int serverID3 = state3.getServerID();
-         
-         int serverID4 = state4.getServerID();
-         
-         int serverID5 = state5.getServerID();
-         
-         log.info("server id 1: " + serverID1);
-         
-         log.info("server id 2: " + serverID2);
-         
-         log.info("server id 3: " + serverID3);
-         
-         log.info("server id 4: " + serverID4);
-         
-         log.info("server id 5: " + serverID5);
-         
-         assertEquals(0, serverID1);
-         
-         assertEquals(1, serverID2);
-         
-         assertEquals(2, serverID3);
-         
-         assertEquals(0, serverID4);
-         
-         assertEquals(1, serverID5);
-      }
-      finally
-      {
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-         
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-         
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
-         
-         if (conn4 != null)
-         {
-            conn4.close();
-         }
-         
-         if (conn5 != null)
-         {
-            conn5.close();
-         }
-      }
-      
-   }
- 
-   /*
-    * Test that the failover mapping is created correctly and updated properly when nodes leave
-    * or join
-    */
-   public void testDefaultFailoverMap() throws Exception
-   {     
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         //The order here depends on the order the servers were started in
-         
-         //If any servers get stopped and then started then the order will change
-    
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         
-         assertEquals(0, cf1.getServerId());
-         
-         assertEquals(1, cf2.getServerId());
-         
-         assertEquals(2, cf3.getServerId());
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(3, delegates.length);
-         
-         assertEquals(3, failoverMap.size());
-         
-         // Default failover policy just chooses the node to the right
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }
-      
-      //Now cleanly stop one of the servers
-            
-      log.info("************** STOPPING SERVER 0");
-      ServerManagement.stop(0);
-      
-      log.info("server stopped");
-      
-      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         //Order here depends on order servers were started in
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(1, cf1.getServerId());
-         
-         assertEquals(2, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      //Cleanly stop another server
-      
-      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
-      ServerManagement.stop(1);
-      
-      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
-      
-      {         
-         //Lookup another connection factory
-         
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         assertEquals(1, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         assertEquals(2, cf1.getServerId());
-         
-         
-         assertEquals(1, failoverMap.size());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-      }
-            
-      //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(2, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         
-         assertEquals(2, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-      }
-      
-      
-      //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
-      {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-         
-         log.info("Got connection factory");
-         
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
-         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
-         Map failoverMap = delegate.getFailoverMap();
-         
-         log.info("Got failover map");
-         
-         assertEquals(3, delegates.length);
-         
-         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
-         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
-         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
-         log.info("cf1 serverid=" + cf1.getServerId());
-         
-         log.info("cf2 serverid=" + cf2.getServerId());
-         
-         log.info("cf3 serverid=" + cf3.getServerId());
-         
-         assertEquals(2, cf1.getServerId());
-         
-         assertEquals(0, cf2.getServerId());
-         
-         assertEquals(1, cf3.getServerId());
-         
-         
-         assertEquals(3, failoverMap.size());
-         
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-         
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-         
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-      }            
-   }
+//   public void testRoundRobinConnectionCreation() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//      
+//      log.info ("number of delegates = " + delegate.getDelegates().length);
+//      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
+//      
+//      assertEquals(3, delegate.getDelegates().length);
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//      
+//      assertEquals(0, cf1.getServerId());
+//      
+//      assertEquals(1, cf2.getServerId());
+//      
+//      assertEquals(2, cf3.getServerId());
+//      
+//      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+//      
+//      Connection conn1 = null;
+//      
+//      Connection conn2 = null;
+//      
+//      Connection conn3 = null;
+//      
+//      Connection conn4 = null;
+//      
+//      Connection conn5 = null;
+//      
+//      try
+//      {         
+//         conn1 = factory.createConnection();
+//         
+//         conn2 = factory.createConnection();
+//         
+//         conn3 = factory.createConnection();
+//         
+//         conn4 = factory.createConnection();
+//         
+//         conn5 = factory.createConnection();
+//         
+//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+//         
+//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+//         
+//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+//         
+//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+//         
+//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+//         
+//         int serverID1 = state1.getServerID();
+//         
+//         int serverID2 = state2.getServerID();
+//         
+//         int serverID3 = state3.getServerID();
+//         
+//         int serverID4 = state4.getServerID();
+//         
+//         int serverID5 = state5.getServerID();
+//         
+//         log.info("server id 1: " + serverID1);
+//         
+//         log.info("server id 2: " + serverID2);
+//         
+//         log.info("server id 3: " + serverID3);
+//         
+//         log.info("server id 4: " + serverID4);
+//         
+//         log.info("server id 5: " + serverID5);
+//         
+//         assertEquals(0, serverID1);
+//         
+//         assertEquals(1, serverID2);
+//         
+//         assertEquals(2, serverID3);
+//         
+//         assertEquals(0, serverID4);
+//         
+//         assertEquals(1, serverID5);
+//      }
+//      finally
+//      {
+//         if (conn1 != null)
+//         {
+//            conn1.close();
+//         }
+//         
+//         if (conn2 != null)
+//         {
+//            conn2.close();
+//         }
+//         
+//         if (conn3 != null)
+//         {
+//            conn3.close();
+//         }
+//         
+//         if (conn4 != null)
+//         {
+//            conn4.close();
+//         }
+//         
+//         if (conn5 != null)
+//         {
+//            conn5.close();
+//         }
+//      }
+//      
+//   }
+// 
+//   /*
+//    * Test that the failover mapping is created correctly and updated properly when nodes leave
+//    * or join
+//    */
+//   public void testDefaultFailoverMap() throws Exception
+//   {     
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         //The order here depends on the order the servers were started in
+//         
+//         //If any servers get stopped and then started then the order will change
+//    
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         
+//         assertEquals(0, cf1.getServerId());
+//         
+//         assertEquals(1, cf2.getServerId());
+//         
+//         assertEquals(2, cf3.getServerId());
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         // Default failover policy just chooses the node to the right
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }
+//      
+//      //Now cleanly stop one of the servers
+//            
+//      log.info("************** STOPPING SERVER 0");
+//      ServerManagement.stop(0);
+//      
+//      log.info("server stopped");
+//      
+//      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         //Order here depends on order servers were started in
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(1, cf1.getServerId());
+//         
+//         assertEquals(2, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      //Cleanly stop another server
+//      
+//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+//      
+//      ServerManagement.stop(1);
+//      
+//      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
+//      
+//      {         
+//         //Lookup another connection factory
+//         
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         assertEquals(1, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         
+//         assertEquals(1, failoverMap.size());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//      }
+//            
+//      //Restart server 0
+//      
+//      ServerManagement.start("all", 0);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(2, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         
+//         assertEquals(2, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//      }
+//      
+//      
+//      //Restart server 1
+//      
+//      ServerManagement.start("all", 1);
+//      
+//      {
+//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+//         
+//         log.info("Got connection factory");
+//         
+//         ClusteredClientConnectionFactoryDelegate delegate =
+//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//         
+//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//         
+//         Map failoverMap = delegate.getFailoverMap();
+//         
+//         log.info("Got failover map");
+//         
+//         assertEquals(3, delegates.length);
+//         
+//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+//         
+//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+//         
+//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+//         
+//         log.info("cf1 serverid=" + cf1.getServerId());
+//         
+//         log.info("cf2 serverid=" + cf2.getServerId());
+//         
+//         log.info("cf3 serverid=" + cf3.getServerId());
+//         
+//         assertEquals(2, cf1.getServerId());
+//         
+//         assertEquals(0, cf2.getServerId());
+//         
+//         assertEquals(1, cf3.getServerId());
+//         
+//         
+//         assertEquals(3, failoverMap.size());
+//         
+//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+//         
+//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+//         
+//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+//      }            
+//   }
+//   
+//   public void testSimpleFailover() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerId();
+//      
+//      int server1Id = cf2.getServerId();
+//      
+//      int server2Id = cf3.getServerId();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      try
+//      {
+//      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         MessageProducer prod = sess.createProducer(queue1);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue1);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         //So now, messages should be in queue1 on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.kill(1);
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(1000);
+//            
+//            log.info("message is " + tm);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         log.info("done");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
    
-   public void testSimpleFailover() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-      assertEquals(3, nodeIDView.size());
-      
-      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
-      ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
-      int server0Id = cf1.getServerId();
-      
-      int server1Id = cf2.getServerId();
-      
-      int server2Id = cf3.getServerId();
-      
-      log.info("server 0 id: " + server0Id);
-      
-      log.info("server 1 id: " + server1Id);
-      
-      log.info("server 2 id: " + server2Id);
-                  
-      Map failoverMap = delegate.getFailoverMap();
-      
-      log.info(failoverMap.get(new Integer(server0Id)));
-      log.info(failoverMap.get(new Integer(server1Id)));
-      log.info(failoverMap.get(new Integer(server2Id)));
-      
-      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
-      // server 1 should failover onto server 2
-      
-      assertEquals(server2Id, server1FailoverId);
-      
-      Connection conn = null;
-      
-      try
-      {
-      
-         //Get a connection on server 1
-         conn = factory.createConnection(); //connection on server 0
-         
-         conn.close();
-         
-         conn = factory.createConnection(); //connection on server 1
-         
-         JBossConnection jbc = (JBossConnection)conn;
-         
-         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
-         ConnectionState state = (ConnectionState)del.getState();
-         
-         int initialServerID = state.getServerID();
-         
-         assertEquals(1, initialServerID);
-                           
-         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         MessageProducer prod = sess.createProducer(queue1);
-         
-         MessageConsumer cons = sess.createConsumer(queue1);
-         
-         final int NUM_MESSAGES = 100;
-         
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess.createTextMessage("message:" + i);
-            
-            prod.send(tm);
-         }
-         
-         //So now, messages should be in queue1 on server 1
-         //So we now kill server 1
-         //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
-         ServerManagement.getServer(1).kill();
-         
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(5000);
-         
-         log.info("done wait");
-         
-         state = (ConnectionState)del.getState();
-         
-         int finalServerID = state.getServerID();
-         
-         log.info("final server id= " + finalServerID);
-         
-         //server id should now be 2
-         
-         assertEquals(2, finalServerID);
-         
-         conn.start();
-         
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = (TextMessage)cons.receive(1000);
-            
-            log.info("message is " + tm);
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         log.info("done");
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-      }
-      
-   }
    
-   
    public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
@@ -651,7 +651,7 @@
          
          log.info("************ KILLING (CRASHING) SERVER 1");
          
-         ServerManagement.getServer(1).kill();
+         ServerManagement.kill(1);
          
          log.info("killed server, now waiting");
          
@@ -723,183 +723,183 @@
       }
       
    }
+//   
+//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerId();
+//      
+//      int server1Id = cf2.getServerId();
+//      
+//      int server2Id = cf3.getServerId();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      try
+//      {      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+//         
+//         MessageProducer prod = sess.createProducer(queue1);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue1);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         sess.commit();
+//         
+//         conn.start();
+//         
+//         //Now consume half of the messages but don't commit them these will end up in 
+//         //client side resource manager
+//         
+//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(500);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         //So now, messages should be in queue1 on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.kill(1);
+//
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         //Now should be able to consume the rest of the messages
+//         
+//         log.info("here1");
+//         
+//         TextMessage tm = null;
+//         
+//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+//         {
+//            tm = (TextMessage)cons.receive(500);
+//                                    
+//            log.info("message is " + tm.getText());
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         log.info("here2");
+//         
+//         //Now should be able to commit them
+//         
+//         sess.commit();
+//         
+//         //Now check there are no more messages there
+//         sess.close();
+//         
+//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         cons = sess.createConsumer(queue1);
+//         
+//         Message m = cons.receive(500);
+//         
+//         assertNull(m);
+//         
+//         log.info("got to end of test");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//      }
+//      
+//   }
+//   
    
-   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-      assertEquals(3, nodeIDView.size());
-      
-      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
-      ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
-      int server0Id = cf1.getServerId();
-      
-      int server1Id = cf2.getServerId();
-      
-      int server2Id = cf3.getServerId();
-      
-      log.info("server 0 id: " + server0Id);
-      
-      log.info("server 1 id: " + server1Id);
-      
-      log.info("server 2 id: " + server2Id);
-                  
-      Map failoverMap = delegate.getFailoverMap();
-      
-      log.info(failoverMap.get(new Integer(server0Id)));
-      log.info(failoverMap.get(new Integer(server1Id)));
-      log.info(failoverMap.get(new Integer(server2Id)));
-      
-      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
-      // server 1 should failover onto server 2
-      
-      assertEquals(server2Id, server1FailoverId);
-      
-      Connection conn = null;
-      
-      try
-      {      
-         //Get a connection on server 1
-         conn = factory.createConnection(); //connection on server 0
-         
-         conn.close();
-         
-         conn = factory.createConnection(); //connection on server 1
-         
-         JBossConnection jbc = (JBossConnection)conn;
-         
-         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
-         ConnectionState state = (ConnectionState)del.getState();
-         
-         int initialServerID = state.getServerID();
-         
-         assertEquals(1, initialServerID);
-                           
-         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-         
-         MessageProducer prod = sess.createProducer(queue1);
-         
-         MessageConsumer cons = sess.createConsumer(queue1);
-         
-         final int NUM_MESSAGES = 100;
-         
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess.createTextMessage("message:" + i);
-            
-            prod.send(tm);
-         }
-         
-         sess.commit();
-         
-         conn.start();
-         
-         //Now consume half of the messages but don't commit them these will end up in 
-         //client side resource manager
-         
-         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-         {
-            TextMessage tm = (TextMessage)cons.receive(500);
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         //So now, messages should be in queue1 on server 1
-         //So we now kill server 1
-         //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
-         ServerManagement.getServer(1).kill();
-
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(5000);
-         
-         log.info("done wait");
-         
-         state = (ConnectionState)del.getState();
-         
-         int finalServerID = state.getServerID();
-         
-         log.info("final server id= " + finalServerID);
-         
-         //server id should now be 2
-         
-         assertEquals(2, finalServerID);
-         
-         conn.start();
-         
-         //Now should be able to consume the rest of the messages
-         
-         log.info("here1");
-         
-         TextMessage tm = null;
-         
-         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-         {
-            tm = (TextMessage)cons.receive(500);
-                                    
-            log.info("message is " + tm.getText());
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         log.info("here2");
-         
-         //Now should be able to commit them
-         
-         sess.commit();
-         
-         //Now check there are no more messages there
-         sess.close();
-         
-         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         cons = sess.createConsumer(queue1);
-         
-         Message m = cons.receive(500);
-         
-         assertNull(m);
-         
-         log.info("got to end of test");
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-      }
-      
-   }
    
    
-   
-   
 //   public void testEvenSimplerFailover() throws Exception
 //   {
 //      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-12 18:25:55 UTC (rev 1771)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-12 19:13:02 UTC (rev 1772)
@@ -62,7 +62,7 @@
    protected Topic topic0;
    protected Topic topic1;
    protected Topic topic2;
-
+   
    //No need to have 3 conncetion factories since a clustered connection factory
    //will create connections in a round robin fashion on different servers
    protected ConnectionFactory cf;
@@ -126,23 +126,22 @@
    protected void tearDown() throws Exception
    {
       try
-      {
-
-         if (ServerManagement.getServer(0).isStarted())
+      {                  
+         if (!ServerManagement.isKilled(0) && ServerManagement.getServer(0).isStarted())
          {
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0", 0);
             ServerManagement.undeployQueue("testDistributedQueue", 0);
             ServerManagement.undeployTopic("testDistributedTopic", 0);
          }
 
-         if (ServerManagement.getServer(1).isStarted())
+         if (!ServerManagement.isKilled(1) && ServerManagement.getServer(1).isStarted())
          {
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1", 1);
             ServerManagement.undeployQueue("testDistributedQueue", 1);
             ServerManagement.undeployTopic("testDistributedTopic", 1);
          }
 
-         if (ServerManagement.getServer(2).isStarted())
+         if (!ServerManagement.isKilled(2) && ServerManagement.getServer(2).isStarted())
          {
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2", 2);
             ServerManagement.undeployQueue("testDistributedQueue", 2);

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-12 18:25:55 UTC (rev 1771)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-12 19:13:02 UTC (rev 1772)
@@ -79,7 +79,9 @@
    private static final int RMI_SERVER_LOOKUP_RETRIES = 10;
 
    private static Server[] servers = new Server[MAX_SERVER_COUNT];
-
+   
+   private static boolean[] killed = new boolean[MAX_SERVER_COUNT];
+   
    // Map<NotificationListener - NotificationListenerPoller>
    private static Map notificationListenerPollers = new HashMap();
 
@@ -100,6 +102,11 @@
    
    public static Server getServer(int i)
    {
+      if (killed[i])
+      {
+         log.warn("Server " + i + " cannot be got since it has been killed");
+      }
+      
       Server s = servers[i];
       
       if (s == null)
@@ -117,6 +124,13 @@
 
    public static synchronized void create(int index) throws Exception
    {
+      if (killed[index])
+      {
+         log.warn("Server " + index + " cannot created since it has been killed");
+         
+         return;
+      }
+      
       if (servers[index] != null)
       {
          return;
@@ -155,6 +169,13 @@
 
    public static synchronized void start(String config, int index) throws Exception
    {
+      if (killed[index])
+      {
+         log.warn("Server " + index + " cannot been started since it has been killed");
+         
+         return;
+      }
+      
       create(index);
 
       if (isLocal())
@@ -181,6 +202,13 @@
 
    public static synchronized void stop(int index) throws Exception
    {
+      if (killed[index])
+      {
+         log.warn("Server " + index + " cannot been stopped since it has been killed");
+         
+         return;
+      }
+      
       if (servers[index] == null)
       {
          log.warn("Server " + index + " has not been created, so it cannot be stopped");
@@ -220,7 +248,14 @@
 
       servers[index].kill();
       servers[index] = null;
+      
+      killed[index] = true;
    }
+   
+   public static synchronized boolean isKilled(int index)
+   {
+      return killed[index];
+   }
 
    public static void disconnect() throws Exception
    {
@@ -265,6 +300,13 @@
    public static void addNotificationListener(int serverIndex, ObjectName on,
                                               NotificationListener listener) throws Exception
    {
+      if (killed[serverIndex])
+      {
+         log.warn("Server " + serverIndex + " cannot addNotificationListener it has been killed");
+         
+         return;
+      }
+      
       insureStarted(serverIndex);
 
       if (isLocal())
@@ -290,6 +332,13 @@
    public static void removeNotificationListener(int serverIndex, ObjectName on,
                                                  NotificationListener listener) throws Exception
    {
+      if (killed[serverIndex])
+      {
+         log.warn("Server " + serverIndex + " cannot removeNotificationListener it has been killed");
+         
+         return;
+      }
+      
       insureStarted(serverIndex);
 
       if (isLocal())
@@ -334,6 +383,13 @@
 
    public static void log(int level, String text, int index)
    {
+      if (killed[index])
+      {
+         log.warn("Server " + index + " cannot log it has been killed");
+         
+         return;
+      }
+      
       if (isRemote())
       {
          if (servers[index] == null)
@@ -466,6 +522,11 @@
     */
    public static void deployClusteredTopic(String name, int serverIndex) throws Exception
    {
+      if (killed[serverIndex])
+      {
+         log.warn("Server " + serverIndex + " cannot deployClusteredTopic it has been killed");
+      }
+      
       insureStarted(serverIndex);
       servers[serverIndex].deployTopic(name, null, true);
    }
@@ -519,6 +580,11 @@
     */
    public static void undeployTopic(String name, int serverIndex) throws Exception
    {
+      if (killed[serverIndex])
+      {
+         log.warn("Server " + serverIndex + " cannot undeployTopic it has been killed");
+      }
+      
       undeployDestination(false, name, serverIndex);
    }
 
@@ -544,6 +610,11 @@
     */
    public static void deployClusteredQueue(String name, int serverIndex) throws Exception
    {
+      if (killed[serverIndex])
+      {
+         log.warn("Server " + serverIndex + " cannot deployClusteredQueue it has been killed");
+      }
+      
       insureStarted(serverIndex);
       servers[serverIndex].deployQueue(name, null, true);
    }
@@ -597,6 +668,11 @@
     */
    public static void undeployQueue(String name, int serverIndex) throws Exception
    {
+      if (killed[serverIndex])
+      {
+         log.warn("Server " + serverIndex + " cannot undeplyQueue it has been killed");
+      }
+      
       undeployDestination(true, name, serverIndex);
    }
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 15:04:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 15:04:50 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1773 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GuDru-00045X-Vu@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-12 15:04:43 -0500 (Tue, 12 Dec 2006)
New Revision: 1773

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/StatsSender.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Server hop code



Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 19:13:02 UTC (rev 1772)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-12 20:04:43 UTC (rev 1773)
@@ -199,47 +199,84 @@
       
       log.info("calling createFailoverConnectionDelegate");
       
-      //Create a connection using that connection factory
-      CreateConnectionResult res =
-         newCF.createConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
+      int tries = 0;
       
-      log.info("returned from createFailoverConnectionDelegate");
-                  
-      if (res.getDelegate() != null)
-      {
-         log.info("Got connection");
+      //We try a maximum of 10 hops
+      final int MAX_TRIES = 10;
+      
+      while (tries < MAX_TRIES)
+      {         
+         //Create a connection using that connection factory
+         CreateConnectionResult res =
+            newCF.createConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
          
-         //We got the right server and created a new connection ok
-         
-         ClientConnectionDelegate newConnection = (ClientConnectionDelegate)res.getDelegate();
-         
-         log.info("newconnection is " + newConnection);
-         
-         failover(failedConnection, newConnection);
-      }
-      else
-      {
-         if (res.getActualFailoverNode() == -1)
+         log.info("returned from createFailoverConnectionDelegate");
+                     
+         if (res.getDelegate() != null)
          {
-            //No trace of failover was detected on the server side - this might happen if the client side
-            //network fails temporarily so the client connection breaks but the server side network is still
-            //up and running - in this case we want to retry back on the original server
+            log.info("Got connection");
             
-            //TODO TODO TODO
+            //We got the right server and created a new connection ok
             
-            log.info("No failover is occurring on server side");
-                        
+            ClientConnectionDelegate newConnection = (ClientConnectionDelegate)res.getDelegate();
+            
+            log.info("newconnection is " + newConnection);
+            
+            failover(failedConnection, newConnection);
+            
+            break;
          }
          else
          {
-            //Server side failover has occurred / is occurring but we tried the wrong node
-            //Now we must try the correct node
-            
-            //TODO TODO TODO
-            
-            log.info("*** Got wrong server!");
+            if (res.getActualFailoverNode() == -1)
+            {
+               //No trace of failover was detected on the server side - this might happen if the client side
+               //network fails temporarily so the client connection breaks but the server side network is still
+               //up and running - in this case we don't failover 
+               
+               //TODO Is this the right thing to do?
+               
+               log.trace("Client attempted to failover, but no failover had occurred on the server side");
+               
+               break;
+                           
+            }
+            else
+            {
+               //Server side failover has occurred / is occurring but we tried the wrong node
+               //Now we must try the correct node
+               
+               newCF = null;
+               
+               tries++;
+               
+               for (int i = 0; i < delegates.length; i++)
+               {
+                  ClientConnectionFactoryDelegate del = delegates[i];
+                  
+                  if (del.getServerId() == res.getActualFailoverNode())
+                  {
+                     newCF = del;
+                     
+                     break;
+                  }
+               }
+               
+               if (newCF == null)
+               {
+                  //Houston, we have a problem
+                  
+                  //TODO Could this ever happen? Should we send back the cf, or update it instead of just the id??
+                  throw new JMSException("Cannot find server with id " + res.getActualFailoverNode());
+               }               
+            }
          }
       }
+      
+      if (tries == MAX_TRIES)
+      {
+         throw new JMSException("Cannot find correct server to failover onto");
+      }
    }
    
    private ClientConnectionFactoryDelegate getFailoverDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
@@ -355,8 +392,7 @@
                                         oldCallbackManager);       
                
                // We add the new consumer id to the list of old ids
-               consumerIds.add(new Integer(((ConsumerState)sessionChild).getConsumerID()));
-               
+               consumerIds.add(new Integer(((ConsumerState)sessionChild).getConsumerID()));               
             }
             else if (sessionChild instanceof BrowserState)
             {
@@ -411,17 +447,10 @@
          }                 
       }
             
-//      problem - what if the consumer has closed - but there are still acks in the session or rm?
-//               
-//      we still need to replace them but with what?
-//               
-//      in this case we can't recreate a consumer on the server since it has closed
-//      
-//      solution here is to store by session id - major reworking!!!!!!!!
+      //TODO
+      //If the session had consumers which are now closed then there is no way to recreate them on the server
+      //we need to store with session id
       
-      
-     // todo need to replace consumer id
-      
       //We must not start the connection until the end
       if (failedState.isStarted())
       {

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/StatsSender.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/StatsSender.java	2006-12-12 19:13:02 UTC (rev 1772)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/StatsSender.java	2006-12-12 20:04:43 UTC (rev 1773)
@@ -97,16 +97,8 @@
    
    class SendStatsTimerTask extends TimerTask
    {
-      private boolean stopping;
-      
-      private boolean stopped;
-      
-      private Object stopLock = new Object();
-      
-      public void run()
+      public synchronized void run()
       {
-         checkStop();
-         
          try
          {
             office.sendQueueStats();
@@ -115,45 +107,11 @@
          {
             log.error("Failed to send statistics", e);
          }
-         
-         checkStop();
       }  
-      
-      private void checkStop()
+                        
+      synchronized void stop()
       {
-         synchronized (stopLock)
-         {            
-            if (stopping)
-            {
-               cancel();
-               
-               stopped = true;
-               
-               stopLock.notify();
-               
-               return;
-            }
-         }
+         cancel();
       }
-            
-      void stop()
-      {
-         synchronized (stopLock)
-         {
-            stopping = true;
-            
-            while (!stopped)
-            {
-               try
-               {
-                  stopLock.wait();               
-               }
-               catch (InterruptedException e)
-               {
-                  //Ignore
-               }
-            }
-         }
-      }
    }
 }

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-12 19:13:02 UTC (rev 1772)
+++ trunk/tests/build.xml	2006-12-12 20:04:43 UTC (rev 1773)
@@ -669,7 +669,7 @@
 
 
 
-      <!-- Start 3 rmi servers -->
+      <!-- Start 4 rmi servers -->
 
       <antcall target="start-rmi-server-clustering">
          <param name="test.server.index" value="0"/>
@@ -745,7 +745,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/HATest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 19:13:02 UTC (rev 1772)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-12 20:04:43 UTC (rev 1773)
@@ -75,484 +75,484 @@
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers
     */
-//   public void testRoundRobinConnectionCreation() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//      
-//      log.info ("number of delegates = " + delegate.getDelegates().length);
-//      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
-//      
-//      assertEquals(3, delegate.getDelegates().length);
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//      
-//      assertEquals(0, cf1.getServerId());
-//      
-//      assertEquals(1, cf2.getServerId());
-//      
-//      assertEquals(2, cf3.getServerId());
-//      
-//      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-//      
-//      Connection conn1 = null;
-//      
-//      Connection conn2 = null;
-//      
-//      Connection conn3 = null;
-//      
-//      Connection conn4 = null;
-//      
-//      Connection conn5 = null;
-//      
-//      try
-//      {         
-//         conn1 = factory.createConnection();
-//         
-//         conn2 = factory.createConnection();
-//         
-//         conn3 = factory.createConnection();
-//         
-//         conn4 = factory.createConnection();
-//         
-//         conn5 = factory.createConnection();
-//         
-//         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-//         
-//         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-//         
-//         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-//         
-//         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-//         
-//         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-//         
-//         int serverID1 = state1.getServerID();
-//         
-//         int serverID2 = state2.getServerID();
-//         
-//         int serverID3 = state3.getServerID();
-//         
-//         int serverID4 = state4.getServerID();
-//         
-//         int serverID5 = state5.getServerID();
-//         
-//         log.info("server id 1: " + serverID1);
-//         
-//         log.info("server id 2: " + serverID2);
-//         
-//         log.info("server id 3: " + serverID3);
-//         
-//         log.info("server id 4: " + serverID4);
-//         
-//         log.info("server id 5: " + serverID5);
-//         
-//         assertEquals(0, serverID1);
-//         
-//         assertEquals(1, serverID2);
-//         
-//         assertEquals(2, serverID3);
-//         
-//         assertEquals(0, serverID4);
-//         
-//         assertEquals(1, serverID5);
-//      }
-//      finally
-//      {
-//         if (conn1 != null)
-//         {
-//            conn1.close();
-//         }
-//         
-//         if (conn2 != null)
-//         {
-//            conn2.close();
-//         }
-//         
-//         if (conn3 != null)
-//         {
-//            conn3.close();
-//         }
-//         
-//         if (conn4 != null)
-//         {
-//            conn4.close();
-//         }
-//         
-//         if (conn5 != null)
-//         {
-//            conn5.close();
-//         }
-//      }
-//      
-//   }
-// 
-//   /*
-//    * Test that the failover mapping is created correctly and updated properly when nodes leave
-//    * or join
-//    */
-//   public void testDefaultFailoverMap() throws Exception
-//   {     
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         //The order here depends on the order the servers were started in
-//         
-//         //If any servers get stopped and then started then the order will change
-//    
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         
-//         assertEquals(0, cf1.getServerId());
-//         
-//         assertEquals(1, cf2.getServerId());
-//         
-//         assertEquals(2, cf3.getServerId());
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         // Default failover policy just chooses the node to the right
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }
-//      
-//      //Now cleanly stop one of the servers
-//            
-//      log.info("************** STOPPING SERVER 0");
-//      ServerManagement.stop(0);
-//      
-//      log.info("server stopped");
-//      
-//      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         //Order here depends on order servers were started in
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(1, cf1.getServerId());
-//         
-//         assertEquals(2, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      //Cleanly stop another server
-//      
-//      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-//      
-//      ServerManagement.stop(1);
-//      
-//      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
-//      
-//      {         
-//         //Lookup another connection factory
-//         
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         assertEquals(1, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         
-//         assertEquals(1, failoverMap.size());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//      }
-//            
-//      //Restart server 0
-//      
-//      ServerManagement.start("all", 0);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(2, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         
-//         assertEquals(2, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//      }
-//      
-//      
-//      //Restart server 1
-//      
-//      ServerManagement.start("all", 1);
-//      
-//      {
-//         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
-//         
-//         log.info("Got connection factory");
-//         
-//         ClusteredClientConnectionFactoryDelegate delegate =
-//            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//         
-//         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//         
-//         Map failoverMap = delegate.getFailoverMap();
-//         
-//         log.info("Got failover map");
-//         
-//         assertEquals(3, delegates.length);
-//         
-//         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-//         
-//         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-//         
-//         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-//         
-//         log.info("cf1 serverid=" + cf1.getServerId());
-//         
-//         log.info("cf2 serverid=" + cf2.getServerId());
-//         
-//         log.info("cf3 serverid=" + cf3.getServerId());
-//         
-//         assertEquals(2, cf1.getServerId());
-//         
-//         assertEquals(0, cf2.getServerId());
-//         
-//         assertEquals(1, cf3.getServerId());
-//         
-//         
-//         assertEquals(3, failoverMap.size());
-//         
-//         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
-//         
-//         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
-//         
-//         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
-//      }            
-//   }
-//   
-//   public void testSimpleFailover() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//      
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//      
-//      int server0Id = cf1.getServerId();
-//      
-//      int server1Id = cf2.getServerId();
-//      
-//      int server2Id = cf3.getServerId();
-//      
-//      log.info("server 0 id: " + server0Id);
-//      
-//      log.info("server 1 id: " + server1Id);
-//      
-//      log.info("server 2 id: " + server2Id);
-//                  
-//      Map failoverMap = delegate.getFailoverMap();
-//      
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//      
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//      
-//      // server 1 should failover onto server 2
-//      
-//      assertEquals(server2Id, server1FailoverId);
-//      
-//      Connection conn = null;
-//      
-//      try
-//      {
-//      
-//         //Get a connection on server 1
-//         conn = factory.createConnection(); //connection on server 0
-//         
-//         conn.close();
-//         
-//         conn = factory.createConnection(); //connection on server 1
-//         
-//         JBossConnection jbc = (JBossConnection)conn;
-//         
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//         
-//         ConnectionState state = (ConnectionState)del.getState();
-//         
-//         int initialServerID = state.getServerID();
-//         
-//         assertEquals(1, initialServerID);
-//                           
-//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//         
-//         MessageProducer prod = sess.createProducer(queue1);
-//         
-//         MessageConsumer cons = sess.createConsumer(queue1);
-//         
-//         final int NUM_MESSAGES = 100;
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//            
-//            prod.send(tm);
-//         }
-//         
-//         //So now, messages should be in queue1 on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//         
-//         log.info("************ KILLING (CRASHING) SERVER 1");
-//         
-//         ServerManagement.kill(1);
-//         
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(5000);
-//         
-//         log.info("done wait");
-//         
-//         state = (ConnectionState)del.getState();
-//         
-//         int finalServerID = state.getServerID();
-//         
-//         log.info("final server id= " + finalServerID);
-//         
-//         //server id should now be 2
-//         
-//         assertEquals(2, finalServerID);
-//         
-//         conn.start();
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(1000);
-//            
-//            log.info("message is " + tm);
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         log.info("done");
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//      }
-//      
-//   }
+   public void testRoundRobinConnectionCreation() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      
+      log.info ("number of delegates = " + delegate.getDelegates().length);
+      log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
+      
+      assertEquals(3, delegate.getDelegates().length);
+      
+      ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+      
+      assertEquals(0, cf1.getServerId());
+      
+      assertEquals(1, cf2.getServerId());
+      
+      assertEquals(2, cf3.getServerId());
+      
+      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+      
+      Connection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      Connection conn4 = null;
+      
+      Connection conn5 = null;
+      
+      try
+      {         
+         conn1 = factory.createConnection();
+         
+         conn2 = factory.createConnection();
+         
+         conn3 = factory.createConnection();
+         
+         conn4 = factory.createConnection();
+         
+         conn5 = factory.createConnection();
+         
+         ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
+         
+         ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+         
+         ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
+         
+         ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
+         
+         ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
+         
+         int serverID1 = state1.getServerID();
+         
+         int serverID2 = state2.getServerID();
+         
+         int serverID3 = state3.getServerID();
+         
+         int serverID4 = state4.getServerID();
+         
+         int serverID5 = state5.getServerID();
+         
+         log.info("server id 1: " + serverID1);
+         
+         log.info("server id 2: " + serverID2);
+         
+         log.info("server id 3: " + serverID3);
+         
+         log.info("server id 4: " + serverID4);
+         
+         log.info("server id 5: " + serverID5);
+         
+         assertEquals(0, serverID1);
+         
+         assertEquals(1, serverID2);
+         
+         assertEquals(2, serverID3);
+         
+         assertEquals(0, serverID4);
+         
+         assertEquals(1, serverID5);
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+         
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+         
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
+      }
+      
+   }
+ 
+   /*
+    * Test that the failover mapping is created correctly and updated properly when nodes leave
+    * or join
+    */
+   public void testDefaultFailoverMap() throws Exception
+   {     
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         //The order here depends on the order the servers were started in
+         
+         //If any servers get stopped and then started then the order will change
+    
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         
+         assertEquals(0, cf1.getServerId());
+         
+         assertEquals(1, cf2.getServerId());
+         
+         assertEquals(2, cf3.getServerId());
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(3, delegates.length);
+         
+         assertEquals(3, failoverMap.size());
+         
+         // Default failover policy just chooses the node to the right
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }
+      
+      //Now cleanly stop one of the servers
+            
+      log.info("************** STOPPING SERVER 0");
+      ServerManagement.stop(0);
+      
+      log.info("server stopped");
+      
+      assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         //Order here depends on order servers were started in
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(1, cf1.getServerId());
+         
+         assertEquals(2, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      //Cleanly stop another server
+      
+      log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
+      
+      ServerManagement.stop(1);
+      
+      assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
+      
+      {         
+         //Lookup another connection factory
+         
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         assertEquals(1, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         assertEquals(2, cf1.getServerId());
+         
+         
+         assertEquals(1, failoverMap.size());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+      }
+            
+      //Restart server 0
+      
+      ServerManagement.start("all", 0);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(2, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         
+         assertEquals(2, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+      }
+      
+      
+      //Restart server 1
+      
+      ServerManagement.start("all", 1);
+      
+      {
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         
+         log.info("Got connection factory");
+         
+         ClusteredClientConnectionFactoryDelegate delegate =
+            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         
+         ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+         
+         Map failoverMap = delegate.getFailoverMap();
+         
+         log.info("Got failover map");
+         
+         assertEquals(3, delegates.length);
+         
+         ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
+         
+         ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
+         
+         ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
+         
+         log.info("cf1 serverid=" + cf1.getServerId());
+         
+         log.info("cf2 serverid=" + cf2.getServerId());
+         
+         log.info("cf3 serverid=" + cf3.getServerId());
+         
+         assertEquals(2, cf1.getServerId());
+         
+         assertEquals(0, cf2.getServerId());
+         
+         assertEquals(1, cf3.getServerId());
+         
+         
+         assertEquals(3, failoverMap.size());
+         
+         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         
+         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         
+         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+      }            
+   }
    
+   public void testSimpleFailover() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
+      int server0Id = cf1.getServerId();
+      
+      int server1Id = cf2.getServerId();
+      
+      int server2Id = cf3.getServerId();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+      
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+      
+      // server 1 should failover onto server 2
+      
+      assertEquals(server2Id, server1FailoverId);
+      
+      Connection conn = null;
+      
+      try
+      {
+      
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
+         
+         conn.close();
+         
+         conn = factory.createConnection(); //connection on server 1
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(1, initialServerID);
+                           
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess.createProducer(queue1);
+         
+         MessageConsumer cons = sess.createConsumer(queue1);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         //So now, messages should be in queue1 on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 1");
+         
+         ServerManagement.kill(1);
+         
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(5000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 2
+         
+         assertEquals(2, finalServerID);
+         
+         conn.start();
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(1000);
+            
+            log.info("message is " + tm);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         log.info("done");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+      }
+      
+   }
    
+   
    public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
@@ -723,183 +723,183 @@
       }
       
    }
-//   
-//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//      
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//      
-//      int server0Id = cf1.getServerId();
-//      
-//      int server1Id = cf2.getServerId();
-//      
-//      int server2Id = cf3.getServerId();
-//      
-//      log.info("server 0 id: " + server0Id);
-//      
-//      log.info("server 1 id: " + server1Id);
-//      
-//      log.info("server 2 id: " + server2Id);
-//                  
-//      Map failoverMap = delegate.getFailoverMap();
-//      
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//      
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//      
-//      // server 1 should failover onto server 2
-//      
-//      assertEquals(server2Id, server1FailoverId);
-//      
-//      Connection conn = null;
-//      
-//      try
-//      {      
-//         //Get a connection on server 1
-//         conn = factory.createConnection(); //connection on server 0
-//         
-//         conn.close();
-//         
-//         conn = factory.createConnection(); //connection on server 1
-//         
-//         JBossConnection jbc = (JBossConnection)conn;
-//         
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//         
-//         ConnectionState state = (ConnectionState)del.getState();
-//         
-//         int initialServerID = state.getServerID();
-//         
-//         assertEquals(1, initialServerID);
-//                           
-//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-//         
-//         MessageProducer prod = sess.createProducer(queue1);
-//         
-//         MessageConsumer cons = sess.createConsumer(queue1);
-//         
-//         final int NUM_MESSAGES = 100;
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//            
-//            prod.send(tm);
-//         }
-//         
-//         sess.commit();
-//         
-//         conn.start();
-//         
-//         //Now consume half of the messages but don't commit them these will end up in 
-//         //client side resource manager
-//         
-//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(500);
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         //So now, messages should be in queue1 on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//         
-//         log.info("************ KILLING (CRASHING) SERVER 1");
-//         
-//         ServerManagement.kill(1);
-//
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(5000);
-//         
-//         log.info("done wait");
-//         
-//         state = (ConnectionState)del.getState();
-//         
-//         int finalServerID = state.getServerID();
-//         
-//         log.info("final server id= " + finalServerID);
-//         
-//         //server id should now be 2
-//         
-//         assertEquals(2, finalServerID);
-//         
-//         conn.start();
-//         
-//         //Now should be able to consume the rest of the messages
-//         
-//         log.info("here1");
-//         
-//         TextMessage tm = null;
-//         
-//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-//         {
-//            tm = (TextMessage)cons.receive(500);
-//                                    
-//            log.info("message is " + tm.getText());
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         log.info("here2");
-//         
-//         //Now should be able to commit them
-//         
-//         sess.commit();
-//         
-//         //Now check there are no more messages there
-//         sess.close();
-//         
-//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//         
-//         cons = sess.createConsumer(queue1);
-//         
-//         Message m = cons.receive(500);
-//         
-//         assertNull(m);
-//         
-//         log.info("got to end of test");
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//      }
-//      
-//   }
-//   
    
+   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
+      int server0Id = cf1.getServerId();
+      
+      int server1Id = cf2.getServerId();
+      
+      int server2Id = cf3.getServerId();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+      
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+      
+      // server 1 should failover onto server 2
+      
+      assertEquals(server2Id, server1FailoverId);
+      
+      Connection conn = null;
+      
+      try
+      {      
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
+         
+         conn.close();
+         
+         conn = factory.createConnection(); //connection on server 1
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(1, initialServerID);
+                           
+         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+         
+         MessageProducer prod = sess.createProducer(queue1);
+         
+         MessageConsumer cons = sess.createConsumer(queue1);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         sess.commit();
+         
+         conn.start();
+         
+         //Now consume half of the messages but don't commit them these will end up in 
+         //client side resource manager
+         
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         //So now, messages should be in queue1 on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 1");
+         
+         ServerManagement.kill(1);
+
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(5000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 2
+         
+         assertEquals(2, finalServerID);
+         
+         conn.start();
+         
+         //Now should be able to consume the rest of the messages
+         
+         log.info("here1");
+         
+         TextMessage tm = null;
+         
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+         {
+            tm = (TextMessage)cons.receive(500);
+                                    
+            log.info("message is " + tm.getText());
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         log.info("here2");
+         
+         //Now should be able to commit them
+         
+         sess.commit();
+         
+         //Now check there are no more messages there
+         sess.close();
+         
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons = sess.createConsumer(queue1);
+         
+         Message m = cons.receive(500);
+         
+         assertNull(m);
+         
+         log.info("got to end of test");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+      }
+      
+   }
    
    
+   
+   
 //   public void testEvenSimplerFailover() throws Exception
 //   {
 //      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 15:05:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 15:05:46 -0500
Subject: [jboss-cvs] JBossAS SVN: r59004 -
	trunk/cluster/src/main/org/jboss/ha/framework/server
Message-ID: <E1GuDso-00048j-Ut@committer01.frg.pub.inap.atl.jboss.com>

Author: jerrygauth
Date: 2006-12-12 15:05:44 -0500 (Tue, 12 Dec 2006)
New Revision: 59004

Modified:
   trunk/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java
Log:
Corrected typo in error message

Modified: trunk/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java
===================================================================
--- trunk/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java	2006-12-12 19:02:55 UTC (rev 59003)
+++ trunk/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java	2006-12-12 20:05:44 UTC (rev 59004)
@@ -216,7 +216,7 @@
       }
       catch (Exception e)
       {
-         throw new RuntimeException("Failure creatig multiplexed Channel", e);
+         throw new RuntimeException("Failure creating multiplexed Channel", e);
       }
    }
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 15:56:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 15:56:01 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59005 - branches/Branch_4_0/ejb3
Message-ID: <E1GuEfR-0004x2-BL@committer01.frg.pub.inap.atl.jboss.com>

Author: bdecoste
Date: 2006-12-12 15:55:57 -0500 (Tue, 12 Dec 2006)
New Revision: 59005

Added:
   branches/Branch_4_0/ejb3/install.xml
Modified:
   branches/Branch_4_0/ejb3/INSTALL.html
   branches/Branch_4_0/ejb3/build.xml
Log:
RC9 Patch 1

Modified: branches/Branch_4_0/ejb3/INSTALL.html
===================================================================
--- branches/Branch_4_0/ejb3/INSTALL.html	2006-12-12 20:05:44 UTC (rev 59004)
+++ branches/Branch_4_0/ejb3/INSTALL.html	2006-12-12 20:55:57 UTC (rev 59005)
@@ -1,39 +1,24 @@
 <html>
 <body>
 <p>
-<h2>Installing EJB 3.0 RC7 with JBoss 4.0.4.GA installer</h2>
+<h2>Installing EJB 3.0 Preview RC9 Patch 1- FD</h2>
 <p>
-The EJB 3.0 RC7 implementation is only usable with JBoss 4.0.4.GA.  The EJB 3.0 implementation that comes packaged with the JBoss 4.0.4.GA installer is the same as the standalone EJB 3.0 RC7 distribution with one exception.  The standalone distribution has been patched to fix the <a href="http://jira.jboss.com/jira/browse/EJBTHREE-573">EJBTHREE-573</a> JIRA bug.  Also the JBoss Remoting jar has been patched to fix the SSL problems in the 4.0.4.GA release.  If you don't need these fixes, then installing with the installer is fine.
+The EJB 3.0 RC9 Patch 1 implementation is only usable with JBoss 4.0.5.GA.  The patch has been released to provide  compatibility with the full (non-installer) release for JBossAS 4.0.5. The patch also corrects a problem with the installer version that caused hot redeploys to fail with a classloading issue
 </p>
-<hr>
-<h2>Installing into JBoss AS 4.0.4.GA</h2>
 <p>
-<ol>
-<li> Download <a
-href="http://sourceforge.net/project/showfiles.php?group_id=22866&package_id=16942">JBoss
-4.0.4.GA</a>.</li>
-
-<li> Download <a href="http://sourceforge.net/project/showfiles.php?group_id=22866&package_id=132063">EJB 3.0 RC7</a>.</li>
-<li> Unzip both of these downloads</li>
-
-<li> Copy <tt>ejb3.deployer</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/deploy</tt></li>
-<li> Copy <tt>ejb3-clustered-sfsbcache-service.xml</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/deploy</tt></li>
-<li> Copy <tt>ejb3-entity-cache-service.xml</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/deploy</tt></li>
-<li> Copy <tt>ejb3-interceptors-aop.xml</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/deploy</tt></li>
-<li> Copy <tt>jboss-aop-jdk50.deployer</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/deploy</tt></li>
-<li> Copy <tt>quartz-ra.rar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/deploy</tt></li>
-<li> Copy <tt>jboss-remoting.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/lib</tt></li>
-<li> Copy <tt>hibernate-annotations.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/lib</tt></li>
-<li> Copy <tt>hibernate-entitymanager.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/lib</tt></li>
-<li> Copy <tt>ejb3-persistence.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/lib</tt></li>
-<li> Copy <tt>quartz-all-1.5.2.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/server/all/lib</tt></li>
-<li> Copy <tt>jboss-ejb3-client.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/client</tt></li>
-<li> Copy <tt>jboss-annotations-ejb3.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/client</tt></li>
-<li> Copy <tt>hibernate-client.jar</tt> from the <tt>lib/</tt> directory of the distribution to <tt>jboss-4.0.x/client</tt></li>
-<li> Remove <tt>jboss-aop.deployer/</tt> from <tt>jboss-4.0.x/server/all/deploy</tt></li>
-
-<li> Start jboss up with the <tt>all</tt> configuration <tt>run.sh -c all</tt></li>
-</ol>
+<ul>
+  <li> download ANT from apache.org if you don't have it already </li>
+  <li> set a JBOSS_HOME environment variable to point to the directory JBoss is installed in</li>
+</ul>
 </p>
+<p>
+<pre>
+$ cd jboss-EJB-3.0_RC9_Patch1-FD
+$ ant -f install.xml -Djboss.server.config=[server directory you want to patch]
+</pre>
+</p>
+<p>
+<i>jboss.server.config</i> defaults to <i>all</i>
+</p>
 </body>
 </html>

Modified: branches/Branch_4_0/ejb3/build.xml
===================================================================
--- branches/Branch_4_0/ejb3/build.xml	2006-12-12 20:05:44 UTC (rev 59004)
+++ branches/Branch_4_0/ejb3/build.xml	2006-12-12 20:55:57 UTC (rev 59005)
@@ -68,7 +68,7 @@
       <property name="module.version" value="DEV"/>
 
       <property name="ejb3.title" value="JBoss EJB 3.0"/>
-      <property name="ejb3.version" value="JBoss EJB 3.0 RC7 - FD"/>
+      <property name="ejb3.version" value="JBoss EJB 3.0 RC9 Patch 1"/>
       <property name="ejb3.vendor" value="JBoss"/>
       <property name="ejb3.url" value="http://www.jboss.com/products/ejb3"/>
 
@@ -421,12 +421,13 @@
    </target>
 
    <target name="dist" depends="init, release-docs">
-      <property name="ejb3.zip.version" value="jboss-EJB-3.0_RC7-FD"/>
+      <property name="ejb3.zip.version" value="jboss-EJB-3.0_RC9_Patch_1"/>
       <echo message="${jboss.common.lib}"/>
       <zip zipfile="${ejb3.zip.version}.zip">
          <zipfileset dir="." prefix="${ejb3.zip.version}">
             <include name="INSTALL.html"/>
             <include name="Migrating.html"/>
+            <include name="install.xml"/>
             <include name="RELEASE_NOTES.txt"/>
          </zipfileset>
         <zipfileset dir="${hibernate.entitymanager.lib}" prefix="${ejb3.zip.version}/lib">
@@ -441,8 +442,15 @@
          <zipfileset dir="${jboss.aspects.lib}" prefix="${ejb3.zip.version}/lib">
             <include name="jboss-aop-jdk50.deployer/**"/>
          </zipfileset>
+         <zipfileset dir="${javassist.lib}" prefix="${ejb3.zip.version}/lib">
+            <include name="javassist.jar"/>
+         </zipfileset>
+         <zipfileset dir="../thirdparty/jboss/jbossws/lib" prefix="${ejb3.zip.version}/lib">
+            <include name="jbossws-client.jar"/>
+         </zipfileset>
          <zipfileset dir="../connector/output/lib" prefix="${ejb3.zip.version}/lib">
             <include name="quartz-ra.rar"/>
+            <include name="jms-ra.rar"/>
          </zipfileset>
          <zipfileset dir="${quartz.quartz.lib}" prefix="${ejb3.zip.version}/lib">
             <include name="*.jar"/>
@@ -456,6 +464,8 @@
             <include name="ejb3-interceptors-aop.xml"/>
             <include name="ejb3-clustered-sfsbcache-service.xml"/>
             <include name="ejb3-entity-cache-service.xml"/>
+            <include name="hibernate-client.jar"/>
+            <include name="jboss-ejb3-client.jar"/>
          </zipfileset>
          <zipfileset dir="docs" prefix="${ejb3.zip.version}/docs">
             <include name="**"/>
@@ -467,6 +477,7 @@
       </zip>
    </target>
 
+
   <!-- Build the repository.jboss.com ejb3 deployer contents needed for
   the jems installer
   -->

Added: branches/Branch_4_0/ejb3/install.xml
===================================================================
--- branches/Branch_4_0/ejb3/install.xml	2006-12-12 20:05:44 UTC (rev 59004)
+++ branches/Branch_4_0/ejb3/install.xml	2006-12-12 20:55:57 UTC (rev 59005)
@@ -0,0 +1,72 @@
+<?xml version="1.0"?>
+
+<!-- ======================================================================= -->
+<!-- JBoss build file                                                       -->
+<!-- ======================================================================= -->
+
+<project name="JBoss" default="install" basedir=".">
+
+   <property file="../local.properties"/>  <property environment="env"/>
+   <property name="src.dir" value="${basedir}/src"/>
+   <property name="jboss.home" value="${env.JBOSS_HOME}"/>   
+   <property name="jboss.server.config" value="all"/>
+
+   <target name="install">
+      <delete dir="${jboss.home}/server/${jboss.server.config}/deploy/jboss-aop.deployer"/>
+      <delete dir="${jboss.home}/server/${jboss.server.config}/deploy/jbossws14.sar"/>
+      <delete dir="${jboss.home}/server/${jboss.server.config}/deploy/jboss-aop-jdk50.deployer"/>
+      <delete dir="${jboss.home}/server/${jboss.server.config}/deploy/ejb3.deployer"/>
+      <delete file="${jboss.home}/client/jbossws14-client.jar"/>
+
+      <copy file="lib/jbossws-client.jar" todir="${jboss.home}/client"/>
+      <copy file="lib/hibernate-client.jar" todir="${jboss.home}/client"/>
+      <copy file="lib/jboss-ejb3-client.jar" todir="${jboss.home}/client"/>
+      <copy file="lib/ejb3.deployer/jboss-ejb3x.jar" todir="${jboss.home}/client"/>
+      <copy file="lib/ejb3.deployer/jboss-annotations-ejb3.jar" todir="${jboss.home}/client"/>
+      <copy file="lib/ejb3-persistence.jar" todir="${jboss.home}/server/${jboss.server.config}/lib"/>
+      <copy file="lib/ejb3-persistence.jar" todir="${jboss.home}/client"/>
+      <copy file="lib/hibernate-entitymanager.jar" todir="${jboss.home}/server/${jboss.server.config}/lib"/>
+      <copy file="lib/hibernate-annotations.jar" todir="${jboss.home}/server/${jboss.server.config}/lib"/>
+      <copy file="lib/hibernate3.jar" todir="${jboss.home}/server/${jboss.server.config}/lib"/>
+      <copy file="lib/javassist.jar" todir="${jboss.home}/server/${jboss.server.config}/lib"/>
+      <copy file="lib/quartz-all-1.5.2.jar" todir="${jboss.home}/server/${jboss.server.config}/lib"/>
+      <copy todir="${jboss.home}/server/${jboss.server.config}/deploy">
+         <fileset dir="lib">
+             <include name="ejb3.deployer/**"/>
+             <include name="jboss-aop-jdk50.deployer/**"/>
+             <include name="*.xml"/>
+             <include name="jbossws.sar"/>
+         </fileset>
+      </copy>
+      <copy file="lib/jms-ra.rar" todir="${jboss.home}/server/${jboss.server.config}/deploy/jms"/>
+      <copy file="lib/quartz-ra.rar" todir="${jboss.home}/server/${jboss.server.config}/deploy"/>
+
+      <!-- now we have to unjar and rejar jboss.jar to remove ejbjar and jboss schema files -->
+      <delete dir="tmp"/>
+      <mkdir dir="tmp"/>
+      <unjar src="${jboss.home}/server/${jboss.server.config}/lib/jboss.jar" dest="tmp"/>
+      <jar destfile="${jboss.home}/server/${jboss.server.config}/lib/jboss.jar" update="false">
+         <fileset dir="tmp">
+           <include name="**/*"/>
+           <exclude name="schema/ejb-jar_3_0.xsd"/>
+           <exclude name="schema/jboss_5_0.xsd"/>
+         </fileset>
+      </jar>
+      <delete dir="tmp"/>
+
+      <!-- now we have to unjar and rejar jboss.jar to remove ejbjar and jboss schema files -->
+      <delete dir="tmp"/>
+      <mkdir dir="tmp"/>
+      <unjar src="${jboss.home}/lib/endorsed/xml-apis.jar" dest="tmp"/>
+      <jar destfile="${jboss.home}/lib/endorsed/xml-apis.jar" update="false">
+         <fileset dir="tmp">
+           <include name="**/*"/>
+           <exclude name="javax/xml/namespace/*"/>
+         </fileset>
+      </jar>
+      <delete dir="tmp"/>
+
+   </target>
+
+</project>
+



From norman.richards at jboss.com  Tue Dec 12 17:38:26 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 17:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF    ...
Message-ID: <E1GuGGY-0006kb-6p@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 17:38:26

  Modified:    src/ui/META-INF    faces-config.xml seam.taglib.xml
                        taglib.tld
  Log:
  JBSEAM-574: enum support
  
  Revision  Changes    Path
  1.24      +27 -10    jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- faces-config.xml	7 Dec 2006 04:19:18 -0000	1.23
  +++ faces-config.xml	12 Dec 2006 22:38:26 -0000	1.24
  @@ -450,6 +450,19 @@
           </property>
       </component>
   
  +    <component>
  +        <component-type>org.jboss.seam.ui.EnumItem</component-type>
  +        <component-class>org.jboss.seam.ui.EnumItem</component-class>
  +        <property>
  +            <property-name>enumValue</property-name>
  +            <property-class>java.lang.String</property-class>
  +        </property>
  +        <property>
  +            <property-name>label</property-name>
  +            <property-class>java.lang.String</property-class>
  +        </property>
  +    </component>
  +
   
       <validator>
           <validator-id>org.jboss.seam.ui.ModelValidator</validator-id>
  @@ -476,4 +489,8 @@
           <converter-class>javax.faces.convert.BigIntegerConverter</converter-class>
       </converter>
   
  +    <converter>  
  +        <converter-id>org.jboss.seam.ui.EnumConverter</converter-id> 
  +        <converter-class>org.jboss.seam.ui.EnumConverter</converter-class>    
  +    </converter>
   </faces-config>
  
  
  
  1.20      +14 -1     jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- seam.taglib.xml	7 Dec 2006 00:19:15 -0000	1.19
  +++ seam.taglib.xml	12 Dec 2006 22:38:26 -0000	1.20
  @@ -118,4 +118,17 @@
           </converter>
       </tag>
       
  +    <tag>
  +        <tag-name>enumItem</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.ui.EnumItem</component-type>
  +        </component>
  +    </tag>
  +
  +    <tag>
  +        <tag-name>convertEnum</tag-name>
  +        <converter>
  +            <converter-id>org.jboss.seam.ui.EnumConverter</converter-id>
  +        </converter>
  +    </tag>
   </facelet-taglib>
  
  
  
  1.24      +22 -1     jboss-seam/src/ui/META-INF/taglib.tld
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: taglib.tld
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/taglib.tld,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- taglib.tld	7 Dec 2006 00:19:15 -0000	1.23
  +++ taglib.tld	12 Dec 2006 22:38:26 -0000	1.24
  @@ -920,5 +920,26 @@
       </attribute>
     </tag>
   
  -
  +  <tag>
  +    <name>convertEnum</name>
  +    <tag-class>org.jboss.seam.ui.tag.ConvertEnumTag</tag-class>
  +    <body-content>empty</body-content>
  +  </tag>
  +  <tag>
  +    <name>enumItem</name>
  +    <tag-class>org.jboss.seam.ui.tag.EnumItemTag</tag-class>
  +    <body-content>empty</body-content>
  +    <attribute>
  +      <name>enumValue</name>
  +      <required>true</required>
  +      <rtexprvalue>false</rtexprvalue>
  +      <description>the enum string value</description>
  +    </attribute>
  +    <attribute>
  +      <name>label</name>
  +      <required>false</required>
  +      <rtexprvalue>true</rtexprvalue>
  +      <description>the select item label</description>
  +    </attribute>
  +  </tag>
   </taglib>
  
  
  


From norman.richards at jboss.com  Tue Dec 12 17:38:26 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 17:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui    ...
Message-ID: <E1GuGGY-0006ko-Ak@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 17:38:26

  Modified:    src/ui/org/jboss/seam/ui    SelectDate.java
  Added:       src/ui/org/jboss/seam/ui    EnumConverter.java EnumItem.java
  Log:
  JBSEAM-574: enum support
  
  Revision  Changes    Path
  1.2       +3 -16     jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SelectDate.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SelectDate.java	7 Dec 2006 00:19:15 -0000	1.1
  +++ SelectDate.java	12 Dec 2006 22:38:26 -0000	1.2
  @@ -16,7 +16,6 @@
       
       public static final String SELECTDATE_JS    = "org/jboss/seam/ui/selectDate.js";
   
  -    private String info;
       private String forField;
       
       
  @@ -31,16 +30,6 @@
       }    
   
       
  -    public String getInfo()
  -    {
  -        return info;
  -    }
  -    
  -    public void setInfo(String info)
  -    {
  -        this.info = info;
  -    }    
  -
       @Override
       public String getFamily()
       {
  @@ -57,16 +46,14 @@
      public void restoreState(FacesContext context, Object state) {
         Object[] values = (Object[]) state;
         super.restoreState(context, values[0]);
  -      info = (String) values[1];
  -      forField = (String) values[2];
  +      forField = (String) values[1];
      }
   
      @Override
      public Object saveState(FacesContext context) {
  -      Object[] values = new Object[3];
  +      Object[] values = new Object[2];
         values[0] = super.saveState(context);
  -      values[1] = info;
  -      values[2] = forField;
  +      values[1] = forField;
         return values;
      }
       
  
  
  
  1.1      date: 2006/12/12 22:38:26;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/EnumConverter.java
  
  Index: EnumConverter.java
  ===================================================================
  package org.jboss.seam.ui;
  
  import javax.faces.component.*;
  import javax.faces.context.*;
  import javax.faces.convert.*;
  
  public class EnumConverter
      implements Converter
  {
      public Object getAsObject(FacesContext context,
                                UIComponent comp,
                                String value)
          throws ConverterException
      {
          Class enumType = comp.getValueBinding("value").getType(context);
          return Enum.valueOf(enumType, value);
      }
  
      public String getAsString(FacesContext context,
                                UIComponent component,
                                Object object)
          throws ConverterException
      {
          if (object == null) {
              return null;
          }
  
          return ((Enum) object).toString();
      }
  
  }
  
  
  
  1.1      date: 2006/12/12 22:38:26;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/EnumItem.java
  
  Index: EnumItem.java
  ===================================================================
  package org.jboss.seam.ui;
  
  import javax.faces.model.SelectItem;
  import javax.faces.model.SelectItem;
  import javax.faces.component.UISelectItem;
  import javax.faces.context.FacesContext;
  import javax.faces.el.ValueBinding;
  
  public class EnumItem
      extends UISelectItem
  {
      public static final String COMPONENT_TYPE = "org.jboss.seam.ui.EnumItem";
  
      String enumValue = null;
      String label = null;
  
      public void setEnumValue(String enumValue) {
          this.enumValue = enumValue;
      }
  
      public String getEnumValue() {
          return enumValue;
      }
  
      public void setLabel(String label) {
          this.label = label;
      }
  
      public String getLabel() {
          return label;
      }
  
  
      private String labelValue() {
          ValueBinding valueBinding = getValueBinding("label");
          if (valueBinding!=null) {
              Object labelValue = valueBinding.getValue(getFacesContext());
              if (labelValue != null) {
                  return labelValue.toString();
              }
          }
          return label;
      }
  
      public Object getValue()
      {
          Class c = getParent().getValueBinding("value").getType(getFacesContext());
  
          SelectItem item = new SelectItem();
          Object value = Enum.valueOf(c, enumValue);
  
          item.setValue(value);
  
          String labelValue = labelValue();
          item.setLabel(labelValue==null?enumValue:labelValue);
          
          return item;
      }
      
  
      @Override
      public void restoreState(FacesContext context, Object state) {
          Object[] values = (Object[]) state;
          super.restoreState(context, values[0]);
          enumValue  = (String) values[1];
          label      = (String) values[2];
      }
      
      @Override
      public Object saveState(FacesContext context) {
          Object[] values = new Object[3];
          values[0] = super.saveState(context);
          values[1] = enumValue;
          values[2] = label;
          return values;
      }
  
  
  }
  
  
  


From norman.richards at jboss.com  Tue Dec 12 17:38:26 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 17:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui/tag    ...
Message-ID: <E1GuGGY-0006l1-GF@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 17:38:26

  Modified:    src/ui/org/jboss/seam/ui/tag    SelectDateTag.java
  Added:       src/ui/org/jboss/seam/ui/tag    ConvertEnumTag.java
                        EnumItemTag.java
  Log:
  JBSEAM-574: enum support
  
  Revision  Changes    Path
  1.2       +2 -1      jboss-seam/src/ui/org/jboss/seam/ui/tag/SelectDateTag.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SelectDateTag.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/SelectDateTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SelectDateTag.java	7 Dec 2006 00:19:15 -0000	1.1
  +++ SelectDateTag.java	12 Dec 2006 22:38:26 -0000	1.2
  @@ -27,7 +27,8 @@
   import org.jboss.seam.ui.SelectDate;
   
   
  -public class SelectDateTag extends UIComponentTagBase
  +public class SelectDateTag 
  +    extends UIComponentTagBase
   {
       @Override
       public String getComponentType()
  
  
  
  1.1      date: 2006/12/12 22:38:26;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/tag/ConvertEnumTag.java
  
  Index: ConvertEnumTag.java
  ===================================================================
  package org.jboss.seam.ui.tag;
  
  import javax.faces.convert.Converter;
  import javax.faces.webapp.ConverterTag;
  import javax.servlet.jsp.JspException;
  
  import org.jboss.seam.ui.EnumConverter;
  
  public class ConvertEnumTag
      extends ConverterTag
  {
      private static final String CONVERTER_ID = "org.jboss.seam.ui.EnumConverter";
  
      public ConvertEnumTag() {
          setConverterId(CONVERTER_ID);
      }
      
      @Override
      protected Converter createConverter() 
          throws JspException
      {
          return new EnumConverter();
      }
      
  }
  
  
  
  1.1      date: 2006/12/12 22:38:26;  author: nrichards;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/tag/EnumItemTag.java
  
  Index: EnumItemTag.java
  ===================================================================
  package org.jboss.seam.ui.tag;
  
  import javax.faces.component.UIComponent;
  import javax.servlet.jsp.JspException;
  
  import org.jboss.seam.ui.EnumItem;
  
  public class EnumItemTag
      extends UIComponentTagBase
  {
      String label;
      String enumValue;
  
      @Override
      public String getComponentType()
      {
          return EnumItem.COMPONENT_TYPE;
      }
  
      @Override
      public String getRendererType()
      {
          return null;
      }
  
      
      public void setEnumValue(String enumValue) {
          this.enumValue = enumValue;
      }
  
      public void setLabel(String label) {
          this.label = label;
      }
  
      @Override
      protected void setProperties(UIComponent component)
      {
          super.setProperties(component);
          setStringProperty(component, "label",     label);
          setStringProperty(component, "enumValue", enumValue);
          
          // check for missing values/
      }
  
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 17:58:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 17:58:52 -0500
Subject: [jboss-cvs] JBossAS SVN: r59006 - in
	trunk/system/src/main/org/jboss: profileservice/spi
	system/server/profileservice
Message-ID: <E1GuGaK-00072j-AO@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-12 17:58:46 -0500 (Tue, 12 Dec 2006)
New Revision: 59006

Modified:
   trunk/system/src/main/org/jboss/profileservice/spi/Profile.java
   trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java
   trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java
   trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java
   trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java
Log:
Update the remove operations to throw an exception

Modified: trunk/system/src/main/org/jboss/profileservice/spi/Profile.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/Profile.java	2006-12-12 20:55:57 UTC (rev 59005)
+++ trunk/system/src/main/org/jboss/profileservice/spi/Profile.java	2006-12-12 22:58:46 UTC (rev 59006)
@@ -55,14 +55,14 @@
     * 
     * @param d the bootstrap
     */
-   void addBootstrap(DeploymentContext d);
+   void addBootstrap(DeploymentContext d) throws Exception;
 
    /**
     * Remove a bootstrap
     * 
     * @param name the name
     */
-   void removeBootstrap(String name);
+   void removeBootstrap(String name) throws Exception;
 
    /**
     * Get a named bootstrap.
@@ -85,14 +85,14 @@
     * 
     * @param d the deployer
     */
-   void addDeployer(DeploymentContext d);
+   void addDeployer(DeploymentContext d) throws Exception;
 
    /**
     * Remove a deployer
     * 
     * @param name the name
     */
-   void removeDeployer(String name);
+   void removeDeployer(String name) throws Exception;
 
    /**
     * Get a named deployer.
@@ -115,14 +115,14 @@
     * 
     * @param d the deployment
     */
-   void addDeployment(DeploymentContext d);
+   void addDeployment(DeploymentContext d) throws Exception;
 
    /**
     * Remove a deployment
     * 
     * @param name the name
     */
-   void removeDeployment(String name);
+   void removeDeployment(String name) throws Exception;
 
    /**
     * Get a named deployment.

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java	2006-12-12 20:55:57 UTC (rev 59005)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSBootstrapScannerImpl.java	2006-12-12 22:58:46 UTC (rev 59006)
@@ -42,7 +42,7 @@
       return deployment;
    }
 
-   protected void remove(Profile profile, String name)
+   protected void remove(Profile profile, String name) throws Exception
    {
       profile.removeBootstrap(name);
    }

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java	2006-12-12 20:55:57 UTC (rev 59005)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeployerScannerImpl.java	2006-12-12 22:58:46 UTC (rev 59006)
@@ -42,7 +42,7 @@
       return deployment;
    }
 
-   protected void remove(Profile profile, String name)
+   protected void remove(Profile profile, String name) throws Exception
    {
       profile.removeDeployer(name);
    }

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java	2006-12-12 20:55:57 UTC (rev 59005)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSDeploymentScannerImpl.java	2006-12-12 22:58:46 UTC (rev 59006)
@@ -42,7 +42,7 @@
       return deployment;
    }
 
-   protected void remove(Profile profile, String name)
+   protected void remove(Profile profile, String name) throws Exception
    {
       profile.removeDeployment(name);
    }

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java	2006-12-12 20:55:57 UTC (rev 59005)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java	2006-12-12 22:58:46 UTC (rev 59006)
@@ -643,7 +643,7 @@
     * @param profile the profile
     * @param name the name
     */
-   protected abstract void remove(Profile profile, String name);
+   protected abstract void remove(Profile profile, String name) throws Exception;
    
    /**
     * Helper to get the watchURL for a deployment, if different.



From norman.richards at jboss.com  Tue Dec 12 18:25:08 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 18:25:08 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/resources/WEB-INF   ...
Message-ID: <E1GuGzk-0007ec-Cx@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 18:25:08

  Modified:    examples/seampay/resources/WEB-INF   faces-config.xml
                        web.xml
  Log:
  use new enum support
  
  Revision  Changes    Path
  1.5       +0 -8      jboss-seam/examples/seampay/resources/WEB-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/resources/WEB-INF/faces-config.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- faces-config.xml	4 Nov 2006 01:29:23 -0000	1.4
  +++ faces-config.xml	12 Dec 2006 23:25:08 -0000	1.5
  @@ -3,21 +3,13 @@
                                 "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
   <faces-config>
       <!-- Facelets support -->
  -
       <application>
           <view-handler>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</view-handler>
           <view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
       </application>
   
  -    <converter> 
  -        <converter-for-class>org.jboss.seam.example.seampay.Payment$Frequency</converter-for-class> 
  -        <converter-class>org.jboss.seam.example.seampay.EnumConverter</converter-class> 
  -    </converter> 
  -
       <!-- Phase listener needed for all Seam applications -->
  -    
       <lifecycle>
           <phase-listener>org.jboss.seam.jsf.TransactionalSeamPhaseListener</phase-listener>
       </lifecycle>
  -
   </faces-config>
  
  
  
  1.3       +8 -1      jboss-seam/examples/seampay/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/resources/WEB-INF/web.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- web.xml	23 Oct 2006 22:38:24 -0000	1.2
  +++ web.xml	12 Dec 2006 23:25:08 -0000	1.3
  @@ -18,7 +18,14 @@
           <url-pattern>*.seam</url-pattern>
       </filter-mapping>
   
  -    <!-- Facelets -->
  +    <filter>
  +        <filter-name>Seam Exception Filter</filter-name>
  +        <filter-class>org.jboss.seam.servlet.SeamExceptionFilter</filter-class>
  +    </filter>
  +    <filter-mapping>
  +        <filter-name>Seam Exception Filter</filter-name>
  +        <url-pattern>*.seam</url-pattern>
  +    </filter-mapping>
   
       <context-param>
           <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
  
  
  


From norman.richards at jboss.com  Tue Dec 12 18:25:08 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 18:25:08 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay ...
Message-ID: <E1GuGzk-0007ej-LX@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 18:25:08

  Modified:    examples/seampay/src/org/jboss/seam/example/seampay  
                        Payment.java
  Removed:     examples/seampay/src/org/jboss/seam/example/seampay  
                        EnumConverter.java
  Log:
  use new enum support
  
  Revision  Changes    Path
  1.4       +0 -8      jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Payment.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Payment.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Payment.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- Payment.java	22 Oct 2006 19:40:02 -0000	1.3
  +++ Payment.java	12 Dec 2006 23:25:08 -0000	1.4
  @@ -101,14 +101,6 @@
           this.paymentFrequency = paymentFrequency;
       }
   
  -    public Map<String,Frequency> getFrequencies() {
  -        Map<String,Frequency> result = new HashMap<String,Frequency>();
  -        for (Frequency frequency : Frequency.values()) {
  -            result.put(frequency.toString(), frequency);
  -        }
  -        return result;
  -    }
  -
       public TimerHandle getTimerHandle() {
           return timerHandle;
       }
  
  
  


From norman.richards at jboss.com  Tue Dec 12 18:25:08 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 18:25:08 -0500
Subject: [jboss-cvs] jboss-seam/examples/seampay/view  ...
Message-ID: <E1GuGzk-0007eq-QL@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 18:25:08

  Modified:    examples/seampay/view  search.xhtml
  Log:
  use new enum support
  
  Revision  Changes    Path
  1.8       +13 -3     jboss-seam/examples/seampay/view/search.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: search.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/view/search.xhtml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- search.xhtml	7 Dec 2006 00:24:19 -0000	1.7
  +++ search.xhtml	12 Dec 2006 23:25:08 -0000	1.8
  @@ -22,6 +22,7 @@
           
           <h:messages styleClass="message"/>
           
  +
           <!-- search results -->
           <table class="results">
               <tr>
  @@ -129,9 +130,18 @@
                           <tr>
                               <td>Frequency:</td>
                               <td>
  -                                <h:selectOneRadio id="radioList" layout="lineDirection"
  +                                <h:selectOneRadio id="radioList" 
  +                                                  layout="lineDirection"
                                                     value="#{newPayment.paymentFrequency}">
  +                                    <s:convertEnum />
  +                                    <s:enumItem enumValue="ONCE"         label="Only Once" />
  +                                    <s:enumItem enumValue="EVERY_MINUTE" label="Every Minute (testing)" />
  +                                    <s:enumItem enumValue="HOURLY"       label="Every Hour (testing)" />
  +                                    <s:enumItem enumValue="DAILY"        label="Every Day" />
  +                                    <s:enumItem enumValue="WEEKLY"       label="Every Week" />
  +                                    <ui:remove>
                                       <f:selectItems value="#{newPayment.frequencies}" />
  +                                    </ui:remove>
                                   </h:selectOneRadio>
                               </td>
                           </tr>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 12 18:33:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 12 Dec 2006 18:33:21 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GuH7h-0007oR-S0@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/12 18:33:21

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  added @Install(false)
  
  Revision  Changes    Path
  1.23      +1 -1      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- SeamSecurityManager.java	11 Dec 2006 00:56:30 -0000	1.22
  +++ SeamSecurityManager.java	12 Dec 2006 23:33:21 -0000	1.23
  @@ -37,7 +37,7 @@
    */
   @Scope(APPLICATION)
   @Name("org.jboss.seam.securityManager")
  - at Install(precedence=BUILT_IN)
  + at Install(value = false, precedence=BUILT_IN)
   @Intercept(InterceptionType.NEVER)
   public class SeamSecurityManager
   {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 18:50:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 18:50:34 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59007 - trunk/system/src/main/org/jboss
Message-ID: <E1GuHOM-00084R-Gw@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-12 18:50:32 -0500 (Tue, 12 Dec 2006)
New Revision: 59007

Removed:
   trunk/system/src/main/org/jboss/util/
Log:
Remove the graph util code as it should be in common-core



From erwuidf98435 at fastermail.com  Tue Dec 12 19:43:52 2006
From: erwuidf98435 at fastermail.com (erwuidf98435 at fastermail.com)
Date: Tue, 12 Dec 2006 19:43:52 -0500
Subject: [jboss-cvs] =?utf-8?b?woPCgcKBW8KDwovCgsOwwoJQwpLDisKOw7PCkE0=?=
	=?utf-8?b?woLCtcKCw5zCgsK1woLCvcKBQg==?=
Message-ID: 20061213100658.77348mail@mail.asduiyajsudsbaeuhlsdfnsamn_web.com

???O?F???X?q

?N???F30??

?E???F???w

?????F?U?????O???l????????????????????????????
?@?@?@???????????????U???????????????????????????????????????B
?@?@?@?z?e?????????????????o???????????A???????????????????H

???^?F http://www.freeweb.allfreemail.net.tonderuyo.com/hw/

???M?F http://www.freeweb.allfreemail.net.tonderuyo.com/hw/

????????????????????????????????????????????????????????????????

???T?C?g???l???????S?????????????R?~?
?j?e?B?????B
???????????V????30?????????????????B
?????A?t???????]?????????????o?^?????????????B
?T?C?g???p???????????K???????v?????????B
?S?????S???????????p?????????B
?n???????????????????????????A?????????????D?????????????????????????????B

?T?C?g???? http://www.freeweb.allfreemail.net.tonderuyo.com/hw/




From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 20:02:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 20:02:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1774 -
	trunk/src/main/org/jboss/jms/util
Message-ID: <E1GuIWQ-00017b-M0@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-12 20:02:57 -0500 (Tue, 12 Dec 2006)
New Revision: 1774

Added:
   trunk/src/main/org/jboss/jms/util/Valve.java
Log:
implementing client valve

Added: trunk/src/main/org/jboss/jms/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-12 20:04:43 UTC (rev 1773)
+++ trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-13 01:02:57 UTC (rev 1774)
@@ -0,0 +1,100 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.jms.util;
+
+
+/**
+ * This class is used to guarantee only one thread will be performing a given function, and if any other
+ * thread tries to execute the same functionality it will just ignored
+ * <pre>
+     Valve valve = new Valve();
+        if (valve.open())
+        {
+             try
+             {
+                doSomething();
+             }
+             finally
+             {
+                valve.close();
+             }
+        }
+        else
+        {
+             System.out.println("Nothing to be done
+        }
+  </pre>
+
+   <p>Notice that you can call close only once, so only call close if you were able to open the valve.</p>
+   <p>After its usage if you decide to reset you should just create a new Valve in a safe synchronized block, so
+        if any other thread still using the variable you do it in a safe way </p>
+
+ * @see org.jboss.test.messaging.jms.VeryBasicValveTest
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ *  */
+public class Valve
+{
+   boolean opened;
+   boolean closed;
+
+
+   public boolean open() throws Exception
+   {
+      return open(true);
+   }
+
+   public synchronized boolean open(boolean wait) throws Exception
+   {
+      // already opened? then needs to wait to be closed
+      if (opened)
+      {
+         // if not closed yet, will wait to be closed
+         if (!closed)
+         {
+            if (wait)
+            {
+               this.wait();
+            }
+         }
+         return false;
+      } else
+      {
+         opened = true;
+         return true;
+      }
+   }
+
+   public synchronized void close()
+   {
+      if (!opened)
+      {
+         throw new IllegalStateException("Open must be called first");
+      }
+      if (closed)
+      {
+         throw new IllegalStateException("Valve is already closed");
+      }
+      closed = true;
+      notifyAll();
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 20:04:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 20:04:23 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1775 -
	trunk/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GuIXn-00017u-K1@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-12 20:04:22 -0500 (Tue, 12 Dec 2006)
New Revision: 1775

Added:
   trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java
Log:
implementing client valve

Added: trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java	2006-12-13 01:02:57 UTC (rev 1774)
+++ trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java	2006-12-13 01:04:22 UTC (rev 1775)
@@ -0,0 +1,132 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.jms;
+
+import junit.framework.TestCase;
+import org.jboss.logging.Logger;
+import org.jboss.jms.util.Valve;
+
+/**
+ * This verifies the very basic functionality of ConnectionState.Valve.
+ * Two functions can't enter at the same time, and this will test that routine
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class VeryBasicValveTest extends TestCase
+{
+   private static Logger log = Logger.getLogger(VeryBasicValveTest.class);
+
+   static int counter = 0;
+   static int counterWait = 0;
+
+   static boolean started=false;
+   static Object startSemaphore = new Object();
+   static Valve valve = new Valve();
+
+   // multiple threads opening/closing a thread.
+   // only one should be able to open it
+   public static class SomeThread extends Thread
+   {
+      int threadId;
+      public SomeThread(int threadId)
+      {
+         this.threadId = threadId;
+      }
+      public void run()
+      {
+         try
+         {
+            log.info("Starting Thread " + threadId);
+            synchronized (startSemaphore)
+            {
+               if (!started)
+               {
+                  startSemaphore.wait();
+               }
+            }
+            //log.info("Thread " + threadId + "Opening valve");
+            if (!valve.open())
+            {
+               //log.info("Valve couldn't be opened at thread " + threadId);
+               synchronized (VeryBasicValveTest.class)
+               {
+                  counterWait ++;
+               }
+            } else
+            {
+
+               //log.info("Thread " + threadId + " could open the valve");
+
+               //Thread.sleep(1000);
+
+               synchronized (VeryBasicValveTest.class)
+               {
+                  counter ++;
+               }
+            }
+
+            //log.info("Thread " + threadId + " is now closing the valve");
+            valve.close();
+
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
+      }
+   }
+
+
+   public void testValve() throws Exception
+   {
+      SomeThread thread[] = new SomeThread[2500];
+
+      for (int i=0; i<thread.length; i++)
+      {
+         thread[i] = new SomeThread(i);
+      }
+
+      for (int i=0; i<thread.length; i++)
+      {
+         thread[i].start();
+      }
+
+      synchronized (startSemaphore)
+      {
+         started=true;
+         startSemaphore.notifyAll();
+      }
+
+      for (int i = 0; i < thread.length; i++)
+      {
+         thread[i].join();
+      }
+
+      assertEquals(1, counter);
+      assertEquals(thread.length-1, counterWait);
+
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 20:06:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 20:06:06 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1776 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GuIZS-0001Av-TB@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-12 20:06:05 -0500 (Tue, 12 Dec 2006)
New Revision: 1776

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
implementing client valve

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 01:04:22 UTC (rev 1775)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 01:06:05 UTC (rev 1776)
@@ -53,6 +53,7 @@
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.tx.AckInfo;
 import org.jboss.jms.tx.ResourceManager;
+import org.jboss.jms.util.Valve;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -70,6 +71,8 @@
  *
  * $Id$
  *
+ * TODO: Make some log.info as log.trace after the code is final
+ *
  */
 public class HAAspect
 {
@@ -576,10 +579,12 @@
    private class Listener implements ConnectionListener
    {
       private ClientConnectionDelegate connection;
+      private Valve valve;
       
       Listener(ClientConnectionDelegate connection)
       {
          this.connection = connection;
+         this.valve = new Valve();
          
          log.info("************* CREATING LISTENER");
       }
@@ -589,8 +594,39 @@
          try
          {
             log.info("********* EXCEPTION DETECTED", throwable);
-            
-            handleFailure(connection);
+
+            // it references Valve to a local variable.
+            // Since we reset the valve at the end, we need to guarantee we will have the same Valve instance
+            // from the moment we enter this method.
+            Valve localValve = null;
+            synchronized (this)
+            {
+               localValve = valve;
+            }
+
+            // We can't have more than one exception being caught at the same time.
+            // On that case we will open the valve and any other thread opening the valve
+            // will wait until its completion
+            if (localValve.open())
+            {
+               try
+               {
+                  log.info("********* HANDLING FAILOVER");
+                  handleFailure(connection);
+               }
+               finally
+               {
+                  localValve.close();
+                  synchronized (this)
+                  {
+                     valve = new Valve();
+                  }
+               }
+            }
+            else
+            {
+               log.info("********* ANOTHER THREAD WAS RESPONSIBLE FOR FAILOVER AS THE VALVE WAS CLOSED");
+            }
          }
          catch (Throwable e)
          {



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 20:30:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 20:30:28 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1777 - in trunk:
	src/main/org/jboss/jms/util tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/util
Message-ID: <E1GuIx2-0001ax-US@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-12 20:30:26 -0500 (Tue, 12 Dec 2006)
New Revision: 1777

Added:
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Removed:
   trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java
Modified:
   trunk/src/main/org/jboss/jms/util/Valve.java
Log:
oops.. wrong package for test

Modified: trunk/src/main/org/jboss/jms/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-13 01:06:05 UTC (rev 1776)
+++ trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-13 01:30:26 UTC (rev 1777)
@@ -49,7 +49,7 @@
    <p>After its usage if you decide to reset you should just create a new Valve in a safe synchronized block, so
         if any other thread still using the variable you do it in a safe way </p>
 
- * @see org.jboss.test.messaging.jms.VeryBasicValveTest
+ * @see org.jboss.test.messaging.util.VeryBasicValveTest
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
  *  */
 public class Valve

Deleted: trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java	2006-12-13 01:06:05 UTC (rev 1776)
+++ trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java	2006-12-13 01:30:26 UTC (rev 1777)
@@ -1,132 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.test.messaging.jms;
-
-import junit.framework.TestCase;
-import org.jboss.logging.Logger;
-import org.jboss.jms.util.Valve;
-
-/**
- * This verifies the very basic functionality of ConnectionState.Valve.
- * Two functions can't enter at the same time, and this will test that routine
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
- */
-public class VeryBasicValveTest extends TestCase
-{
-   private static Logger log = Logger.getLogger(VeryBasicValveTest.class);
-
-   static int counter = 0;
-   static int counterWait = 0;
-
-   static boolean started=false;
-   static Object startSemaphore = new Object();
-   static Valve valve = new Valve();
-
-   // multiple threads opening/closing a thread.
-   // only one should be able to open it
-   public static class SomeThread extends Thread
-   {
-      int threadId;
-      public SomeThread(int threadId)
-      {
-         this.threadId = threadId;
-      }
-      public void run()
-      {
-         try
-         {
-            log.info("Starting Thread " + threadId);
-            synchronized (startSemaphore)
-            {
-               if (!started)
-               {
-                  startSemaphore.wait();
-               }
-            }
-            //log.info("Thread " + threadId + "Opening valve");
-            if (!valve.open())
-            {
-               //log.info("Valve couldn't be opened at thread " + threadId);
-               synchronized (VeryBasicValveTest.class)
-               {
-                  counterWait ++;
-               }
-            } else
-            {
-
-               //log.info("Thread " + threadId + " could open the valve");
-
-               //Thread.sleep(1000);
-
-               synchronized (VeryBasicValveTest.class)
-               {
-                  counter ++;
-               }
-            }
-
-            //log.info("Thread " + threadId + " is now closing the valve");
-            valve.close();
-
-         }
-         catch (Exception e)
-         {
-            e.printStackTrace();
-         }
-      }
-   }
-
-
-   public void testValve() throws Exception
-   {
-      SomeThread thread[] = new SomeThread[2500];
-
-      for (int i=0; i<thread.length; i++)
-      {
-         thread[i] = new SomeThread(i);
-      }
-
-      for (int i=0; i<thread.length; i++)
-      {
-         thread[i].start();
-      }
-
-      synchronized (startSemaphore)
-      {
-         started=true;
-         startSemaphore.notifyAll();
-      }
-
-      for (int i = 0; i < thread.length; i++)
-      {
-         thread[i].join();
-      }
-
-      assertEquals(1, counter);
-      assertEquals(thread.length-1, counterWait);
-
-   }
-
-}

Copied: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java (from rev 1775, trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java)
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/VeryBasicValveTest.java	2006-12-13 01:04:22 UTC (rev 1775)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-13 01:30:26 UTC (rev 1777)
@@ -0,0 +1,132 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.util;
+
+import junit.framework.TestCase;
+import org.jboss.logging.Logger;
+import org.jboss.jms.util.Valve;
+
+/**
+ * This verifies the very basic functionality of ConnectionState.Valve.
+ * Two functions can't enter at the same time, and this will test that routine
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class VeryBasicValveTest extends TestCase
+{
+   private static Logger log = Logger.getLogger(VeryBasicValveTest.class);
+
+   static int counter = 0;
+   static int counterWait = 0;
+
+   static boolean started=false;
+   static Object startSemaphore = new Object();
+   static Valve valve = new Valve();
+
+   // multiple threads opening/closing a thread.
+   // only one should be able to open it
+   public static class SomeThread extends Thread
+   {
+      int threadId;
+      public SomeThread(int threadId)
+      {
+         this.threadId = threadId;
+      }
+      public void run()
+      {
+         try
+         {
+            log.info("Starting Thread " + threadId);
+            synchronized (startSemaphore)
+            {
+               if (!started)
+               {
+                  startSemaphore.wait();
+               }
+            }
+            //log.info("Thread " + threadId + "Opening valve");
+            if (!valve.open())
+            {
+               //log.info("Valve couldn't be opened at thread " + threadId);
+               synchronized (VeryBasicValveTest.class)
+               {
+                  counterWait ++;
+               }
+            } else
+            {
+
+               //log.info("Thread " + threadId + " could open the valve");
+
+               //Thread.sleep(1000);
+
+               synchronized (VeryBasicValveTest.class)
+               {
+                  counter ++;
+               }
+            }
+
+            //log.info("Thread " + threadId + " is now closing the valve");
+            valve.close();
+
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
+      }
+   }
+
+
+   public void testValve() throws Exception
+   {
+      SomeThread thread[] = new SomeThread[2500];
+
+      for (int i=0; i<thread.length; i++)
+      {
+         thread[i] = new SomeThread(i);
+      }
+
+      for (int i=0; i<thread.length; i++)
+      {
+         thread[i].start();
+      }
+
+      synchronized (startSemaphore)
+      {
+         started=true;
+         startSemaphore.notifyAll();
+      }
+
+      for (int i = 0; i < thread.length; i++)
+      {
+         thread[i].join();
+      }
+
+      assertEquals(1, counter);
+      assertEquals(thread.length-1, counterWait);
+
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 20:35:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 20:35:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1778 -
	trunk/tests/src/org/jboss/test/messaging/util
Message-ID: <E1GuJ2M-0001gV-Aj@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-12 20:35:57 -0500 (Tue, 12 Dec 2006)
New Revision: 1778

Modified:
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Log:
small fix on test

Modified: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-13 01:30:26 UTC (rev 1777)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-13 01:35:57 UTC (rev 1778)
@@ -85,10 +85,10 @@
                {
                   counter ++;
                }
+               valve.close();
             }
 
             //log.info("Thread " + threadId + " is now closing the valve");
-            valve.close();
 
          }
          catch (Exception e)



From Shane_Bryzak at symantec.com  Tue Dec 12 20:52:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 12 Dec 2006 20:52:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config ...
Message-ID: <E1GuJIM-0001vx-Um@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/12 20:52:30

  Added:       src/main/org/jboss/seam/security/config    
                        SecurityConfiguration.java
  Removed:     src/main/org/jboss/seam/security/config    
                        SecurityConfig.java SecurityConfigFileLoader.java
                        SecurityConfigLoader.java
  Log:
  simplified security config
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 01:52:30;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  Index: SecurityConfiguration.java
  ===================================================================
  package org.jboss.seam.security.config;
  
  import java.io.InputStream;
  import java.util.HashMap;
  import java.util.HashSet;
  import java.util.List;
  import java.util.Map;
  import java.util.Set;
  
  import org.dom4j.Document;
  import org.dom4j.Element;
  import org.dom4j.io.SAXReader;
  import static org.jboss.seam.ScopeType.APPLICATION;
  import org.jboss.seam.InterceptionType;
  import static org.jboss.seam.annotations.Install.BUILT_IN;
  import org.jboss.seam.annotations.Create;
  import org.jboss.seam.annotations.Install;
  import org.jboss.seam.annotations.Intercept;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Scope;
  import org.jboss.seam.security.Role;
  import org.jboss.seam.security.SeamPermission;
  import org.jboss.seam.util.Resources;
  
  /**
   * Security configuration component.
   *
   * @author Shane Bryzak
   */
  @Scope(APPLICATION)
  @Name("org.jboss.seam.security.securityConfiguration")
  @Install(value = false, precedence=BUILT_IN)
  @Intercept(InterceptionType.NEVER)
  public class SecurityConfiguration
  {
    private static final String SECURITY_CONFIG_FILENAME = "/META-INF/security-config.xml";
  
    // <security-constraint>
  //  private static final String SECURITY_CONSTRAINT = "security-constraint";
  //  private static final String WEB_RESOURCE_COLLECTION = "web-resource-collection";
  //  private static final String URL_PATTERN = "url-pattern";
  //  private static final String HTTP_METHOD = "http-method";
  //  private static final String AUTH_CONSTRAINT = "auth-constraint";
  //  private static final String ROLE_NAME = "role-name";
  
    // <login-config>
  //  private static final String LOGIN_CONFIG = "login-config";
  //  private static final String AUTH_METHOD = "auth-method";
  
    // FORM
  //  private static final String FORM_LOGIN_CONFIG = "form-login-config";
  //  private static final String FORM_LOGIN_PAGE = "form-login-page";
  //  private static final String FORM_ERROR_PAGE = "form-error-page";
  //  private static final String FORM_DEFAULT_PAGE = "form-default-page";
  
    // roles
    private static final String SECURITY_ROLES = "roles";
    private static final String SECURITY_ROLE = "role";
    private static final String SECURITY_MEMBERS = "members";
    private static final String SECURITY_PERMISSIONS = "permissions";
    private static final String SECURITY_PERMISSION = "permission";
  
  //  private Set<SecurityConstraint> securityConstraints = new HashSet<SecurityConstraint>();
  
    private Map<String,Role> securityRoles = new HashMap<String,Role>();
  
  //  private AuthMethod authMethod;
  
  //  private Handler authenticator;
  
    /**
     * Initialization
     *
     * @throws SecurityConfigException
     */
    @Create
    public void init()
        throws SecurityConfigException
    {
      loadConfigFromStream(Resources.getResourceAsStream(SECURITY_CONFIG_FILENAME));
    }
  
    /**
     * Loads the security configuration from the specified InputStream.
     *
     * @param config InputStream
     * @throws SecurityConfigException
     */
    protected void loadConfigFromStream(InputStream config)
        throws SecurityConfigException
    {
      try
      {
        // Parse the incoming request as XML
        SAXReader xmlReader = new SAXReader();
        Document doc = xmlReader.read(config);
        Element env = doc.getRootElement();
  
  //      loadSecurityConstraints(env.elements(SECURITY_CONSTRAINT));
  //      loadLoginConfig(env.element(LOGIN_CONFIG));
        loadSecurityRoles(env.element(SECURITY_ROLES));
      }
      catch (Exception ex)
      {
        if (ex instanceof SecurityConfigException)
          throw (SecurityConfigException) ex;
        else
          throw new SecurityConfigException("Error loading security configuration", ex);
      }
    }
  
    /**
     *
     * @return Set
     */
  //  public Set<SecurityConstraint> getSecurityConstraints()
  //  {
  //    return securityConstraints;
  //  }
  
    /**
     *
     * @return AuthMethod
     */
  //  public AuthMethod getAuthMethod()
  //  {
  //    return authMethod;
  //  }
  
    /**
     *
     * @return Authenticator
     */
  //  public Handler getAuthenticator()
  //  {
  //    return authenticator;
  //  }
  
    /**
     *
     * @return Set
     */
    public Set<Role> getSecurityRoles()
    {
      return new HashSet<Role>(securityRoles.values());
    }
  
    /**
     * Load security constraints
     *
     * @param elements List
     * @throws SecurityConfigurationException
     */
  //  private void loadSecurityConstraints(List elements)
  //      throws SecurityConfigException
  //  {
  //    try
  //    {
  //      for (Element element : (List<Element>) elements)
  //      {
  //        SecurityConstraint securityConstraint = new SecurityConstraint();
  //        securityConstraints.add(securityConstraint);
  //
  //        for (Element wrcElement :
  //            (List<Element>) element.elements(WEB_RESOURCE_COLLECTION))
  //        {
  //          WebResourceCollection wrc = new WebResourceCollection();
  //          securityConstraint.getResourceCollections().add(wrc);
  //
  //          for (Element urlPatternElement :
  //              (List<Element>) wrcElement.elements(URL_PATTERN))
  //          {
  //            wrc.getUrlPatterns().add(urlPatternElement.getTextTrim());
  //          }
  //
  //          for (Element httpMethodElement :
  //              (List<Element>) wrcElement.elements(HTTP_METHOD))
  //          {
  //            wrc.getHttpMethods().add(httpMethodElement.getTextTrim());
  //          }
  //        }
  //
  //        securityConstraint.setAuthConstraint(new AuthConstraint());
  //        for (Element roleNameElement :
  //            (List<Element>) element.element(AUTH_CONSTRAINT).elements(ROLE_NAME))
  //        {
  //          securityConstraint.getAuthConstraint().getRoles().add(roleNameElement.
  //              getTextTrim());
  //        }
  //      }
  //    }
  //    catch (Exception ex)
  //    {
  //      throw new SecurityConfigException("Error loading security constraints", ex);
  //    }
  //  }
  
    /**
     * Load login configuration
     *
     * @param loginConfigElement Element
     * @throws SecurityConfigurationException
     */
  //  private void loadLoginConfig(Element loginConfigElement)
  //      throws SecurityConfigException
  //  {
  //    String authMethodText = loginConfigElement.element(AUTH_METHOD).getTextTrim();
  //    try
  //    {
  //      authMethod = AuthMethod.valueOf(authMethodText);
  //    }
  //    catch (Exception ex)
  //    {
  //      StringBuilder sb = new StringBuilder();
  //      for (AuthMethod m : AuthMethod.values())
  //      {
  //        if (sb.length() > 0)
  //          sb.append(',');
  //        sb.append(m.toString());
  //      }
  //
  //      throw new SecurityConfigException(
  //          String.format("Invalid auth-method [%s].  Valid options are: %s",
  //                        authMethodText, sb.toString()));
  //    }
  //
  //    switch (authMethod)
  //    {
  //      case BASIC:
  //        authenticator = new BasicHandler();
  //        break;
  //      case FORM:
  //        Element formConfigElement = loginConfigElement.element(FORM_LOGIN_CONFIG);
  //        String loginPage = formConfigElement.elementText(FORM_LOGIN_PAGE);
  //        String errorPage = formConfigElement.elementText(FORM_ERROR_PAGE);
  //        String defaultPage = formConfigElement.elementText(FORM_DEFAULT_PAGE);
  //        authenticator = new FormHandler(loginPage, errorPage, defaultPage);
  //        break;
  //      case SEAM:
  //        Element seamConfigElement = loginConfigElement.element(SEAM_LOGIN_CONFIG);
  //        loginPage = seamConfigElement.elementText(SEAM_LOGIN_PAGE);
  //        authenticator = new SeamAuthenticator(loginPage);
  //        break;
  //    }
  //
  //    if (authenticator == null)
  //      throw new SecurityConfigException(
  //        String.format("No valid authenticator for auth-method [%s]", authMethod.toString()));
  //
  //  }
  
    /**
     * Load the security roles
     *
     * @param securityRoleElement Element
     * @throws SecurityConfigurationException
     */
    protected void loadSecurityRoles(Element securityRoleElement)
        throws SecurityConfigException
    {
      Map<String,Set<String>> members = new HashMap<String,Set<String>>();
  
      for (Element role : (List<Element>) securityRoleElement.elements(SECURITY_ROLE))
      {
        Role r = new Role(role.attributeValue("name"));
  
        Set<String> mbrs = new HashSet<String>();
        members.put(r.getName(), mbrs);
  
        Element m = role.element(SECURITY_MEMBERS);
        if (m != null)
        {
          for (String member : m.getTextTrim().split("[,]"))
            mbrs.add(member);
        }
  
        Element permissionsElement = role.element(SECURITY_PERMISSIONS);
        if (permissionsElement != null)
        {
          for (Element permission : (List<Element>) permissionsElement.elements(
              SECURITY_PERMISSION))
          {
            r.addPermission(new SeamPermission(permission.attributeValue("name"),
                                               permission.attributeValue("action")));
          }
        }
  
        securityRoles.put(r.getName(), r);
      }
  
      for (String roleName : members.keySet())
      {
        Role r = securityRoles.get(roleName);
        for (String member : members.get(roleName))
          r.addMember(securityRoles.get(member));
      }
    }
  
  }
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 12 20:52:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 12 Dec 2006 20:52:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GuJIM-0001vj-LW@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/12 20:52:30

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  simplified security config
  
  Revision  Changes    Path
  1.24      +0 -7      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- SeamSecurityManager.java	12 Dec 2006 23:33:21 -0000	1.23
  +++ SeamSecurityManager.java	13 Dec 2006 01:52:30 -0000	1.24
  @@ -41,7 +41,6 @@
   @Intercept(InterceptionType.NEVER)
   public class SeamSecurityManager
   {
  -  private static final String SECURITY_CONFIG_FILENAME = "/META-INF/security-config.xml";
     private static final String SECURITY_RULES_FILENAME = "/META-INF/security-rules.drl";
   
     private static final String SECURITY_CONTEXT_NAME = "org.jboss.seam.security.securityContext";
  @@ -62,12 +61,6 @@
     public void initSecurityManager()
         throws Exception
     {
  -    /** @todo Load the security configuration */
  -//     SAXReader saxReader = new SAXReader();
  -//     saxReader.setEntityResolver(new DTDEntityResolver());
  -//     saxReader.setMergeAdjacentText(true);
  -//     Document doc = saxReader.read(stream);
  -
       // Create the security rule base
       PackageBuilderConfiguration conf = new PackageBuilderConfiguration();
       conf.setCompiler(PackageBuilderConfiguration.JANINO);
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 12 20:52:30 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 12 Dec 2006 20:52:30 -0500
Subject: [jboss-cvs] jboss-seam/src/test/misc/org/jboss/seam/test  ...
Message-ID: <E1GuJIM-0001vq-PK@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/12 20:52:30

  Modified:    src/test/misc/org/jboss/seam/test  SecurityTest.java
  Log:
  simplified security config
  
  Revision  Changes    Path
  1.11      +49 -21    jboss-seam/src/test/misc/org/jboss/seam/test/SecurityTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/SecurityTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- SecurityTest.java	11 Dec 2006 00:56:30 -0000	1.10
  +++ SecurityTest.java	13 Dec 2006 01:52:30 -0000	1.11
  @@ -1,31 +1,59 @@
   package org.jboss.seam.test;
   
  -import java.io.Serializable;
  +import java.io.ByteArrayInputStream;
  +import java.io.InputStream;
   
  -import javax.persistence.EntityManager;
  -import javax.persistence.EntityManagerFactory;
  -import javax.persistence.Id;
  -
  -import org.hibernate.ejb.Ejb3Configuration;
  -import org.jboss.seam.Component;
  -import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.contexts.Lifecycle;
  -import org.jboss.seam.init.Initialization;
  -import org.jboss.seam.mock.MockAclObjectIdentity;
  -import org.jboss.seam.mock.MockAclPermission;
  -import org.jboss.seam.mock.MockExternalContext;
  -import org.jboss.seam.mock.MockSecureEntity;
  -import org.jboss.seam.mock.MockServletContext;
  -import org.jboss.seam.security.UsernamePasswordToken;
  -import org.jboss.seam.security.acl.JPAIdentityGenerator;
  -import org.jboss.seam.security.acl.AclProvider;
  -import org.jboss.seam.security.acl.PersistentAclProvider;
  -import org.jboss.seam.security.acl.AclProvider.RecipientType;
  +import org.jboss.seam.security.Role;
  +import org.jboss.seam.security.config.SecurityConfigException;
  +import org.jboss.seam.security.config.SecurityConfiguration;
   import org.testng.annotations.Test;
  +import org.jboss.seam.security.SeamPermission;
  +import java.util.Enumeration;
   
   public class SecurityTest
   {
  +  private static final String ROLES_CONFIG = "<roles><role name=\"admin\">" +
  +      "<members>superuser</members><permissions>" +
  +      "<permission name=\"user\" action=\"create\"/>" +
  +      "</permissions></role><role name=\"superuser\">" +
  +      "<members>user</members><permissions>" +
  +      "<permission name=\"account\" action=\"create\"/>" +
  +      "</permissions></role><role name=\"user\"><permissions>" +
  +      "<permission name=\"customer\" action=\"create\"/>" +
  +      "</permissions></role></roles>";
  +
  +  class CustomSecurityConfiguration extends SecurityConfiguration {
  +    public void loadConfigFromStream(InputStream config)
  +      throws SecurityConfigException {
  +        super.loadConfigFromStream(config);
  +    }
  +  }
  +
  +  @Test
  +  public void testRoleConfiguration()
  +      throws Exception
  +  {
  +    String securityConfig = String.format("<security-config>%s</security-config>",
  +                                          ROLES_CONFIG);
  +
  +    CustomSecurityConfiguration config = new CustomSecurityConfiguration();
  +    config.loadConfigFromStream(new ByteArrayInputStream(securityConfig.getBytes()));
  +
  +    assert config.getSecurityRoles().contains(new Role("admin"));
  +    assert config.getSecurityRoles().contains(new Role("superuser"));
  +    assert config.getSecurityRoles().contains(new Role("user"));
  +
  +    for (Role r : config.getSecurityRoles())
  +    {
  +      if ("admin".equals(r.getName()))
  +      {
  +        assert r.hasPermission(new SeamPermission("user", "create"));
  +        assert r.isMember(new Role("superuser"));
  +        break;
  +      }
  +    }
  +  }
  +
     /*@Name("mock")
     class MockSecureEntityMethodId {
       private Integer id;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 12 21:01:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 12 Dec 2006 21:01:43 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1779 -
	trunk/tests/src/org/jboss/test/messaging/util
Message-ID: <E1GuJRH-00023t-QH@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-12 21:01:42 -0500 (Tue, 12 Dec 2006)
New Revision: 1779

Modified:
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Log:
Adding another sleep before start all the threads

Modified: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-13 01:35:57 UTC (rev 1778)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-13 02:01:42 UTC (rev 1779)
@@ -113,6 +113,8 @@
          thread[i].start();
       }
 
+      Thread.sleep(1000);
+
       synchronized (startSemaphore)
       {
          started=true;



From yrtuir6789 at mail2world.com  Tue Dec 12 21:31:11 2006
From: yrtuir6789 at mail2world.com (yrtuir6789 at mail2world.com)
Date: Tue, 12 Dec 2006 21:31:11 -0500
Subject: [jboss-cvs] =?utf-8?b?woLDpMKCwqvCgsKmwoLCs8KCw7HCgsKpwoLDp8KO?=
	=?utf-8?b?w4rCkF7Cg8KBwoFbwoPCi8KCwqrCk8ONwoLCosKCw4TCgsKiwoLDnMKC?=
	=?utf-8?b?wrfCgUI=?=
Message-ID: 20061213114626.42228mail@mail.pllmkmnhstyetrusksiemsnasnjeyshsaj.com

???^?C?g????
?@?T?|?[?g???????????????????????B

?????b?Z?[?W??
?@???????f?[?g(?L?X?L??)???R???A?z?e???L???????I?v?V???????????????T???o???????B
?@???w???????s?????????????????A?????????????v?????B?????????????o???????????H

?????????????v???t?B?[???i???^?f?????j??
?@http://www.allfree.okusamameet.com.perpl.com/Celeb/

?????????????????????o????
?@http://www.allfree.okusamameet.com.perpl.com/Celeb/







From norman.richards at jboss.com  Tue Dec 12 21:52:15 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 12 Dec 2006 21:52:15 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GuKEB-00035E-OS@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/12 21:52:15

  Modified:    doc/reference/en/modules  controls.xml
  Log:
  add enum tags
  
  Revision  Changes    Path
  1.11      +30 -0     jboss-seam/doc/reference/en/modules/controls.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: controls.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/controls.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- controls.xml	8 Dec 2006 03:01:02 -0000	1.10
  +++ controls.xml	13 Dec 2006 02:52:15 -0000	1.11
  @@ -36,6 +36,36 @@
              </listitem>
          </varlistentry>
          <varlistentry>
  +           <term><literal>&lt;s:convertEnum&gt;</literal></term>
  +           <listitem>
  +               <para>
  +                   Assigns an enum converter to the current component.  This is primarily
  +                   useful for radio button and dropdown controls.
  +               </para>                             
  +           </listitem>
  +       </varlistentry>
  +       <varlistentry>
  +           <term><literal>&lt;s:enumItem&gt;</literal></term>
  +           <listitem>
  +               <para>
  +                   Creates a <literal>SelectItem</literal> from an enum value.  
  +               </para>
  +               <itemizedlist>
  +                   <listitem>
  +                   <para>
  +                       <literal>enumValue</literal> &mdash; the string representation of the enum 
  +                       value.  
  +                   </para>
  +                   </listitem>
  +                   <listitem>
  +                   <para>
  +                       <literal>label</literal> &mdash; the label to be used when rendering the <literal>SelectItem</literal>.
  +                   </para>
  +                   </listitem>
  +                   </itemizedlist>
  +           </listitem>
  +       </varlistentry>   
  +       <varlistentry>
              <term><literal>&lt;s:decorate&gt;</literal></term>
              <listitem>
                  <para>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 12 21:58:57 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 12 Dec 2006 21:58:57 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GuKKf-0003A5-Gj@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/12 21:58:57

  Modified:    jboss-seam  build.xml
  Log:
  JBSEAM-582
  
  Revision  Changes    Path
  1.120     +189 -189  jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.119
  retrieving revision 1.120
  diff -u -b -r1.119 -r1.120
  --- build.xml	6 Dec 2006 06:07:22 -0000	1.119
  +++ build.xml	13 Dec 2006 02:58:57 -0000	1.120
  @@ -749,9 +749,9 @@
                   <include name="numberguess/**/*"/>
                   <include name="portal/**/*"/>
                   <include name="drools/**/*"/>
  -                <include name="remoting/chatroom/*"/>
  -                <include name="remoting/helloworld/*"/>
  -                <include name="remoting/progressbar/*"/>
  +                <include name="remoting/chatroom/**/*"/>
  +                <include name="remoting/helloworld/**/*"/>
  +                <include name="remoting/progressbar/**/*"/>
                   <include name="readme.txt"/>
                   <include name="seam-examples.html"/>
                   <exclude name="*/build"/>
  
  
  


From gavin.king at jboss.com  Tue Dec 12 23:54:19 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 12 Dec 2006 23:54:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GuM8J-0005Iq-9p@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/12 23:54:19

  Modified:    src/main/org/jboss/seam/interceptors 
                        ManagedEntityIdentityInterceptor.java
  Log:
  maintain referential integrity for entity beans in conversation context
  
  Revision  Changes    Path
  1.15      +9 -107    jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedEntityIdentityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- ManagedEntityIdentityInterceptor.java	2 Dec 2006 07:51:33 -0000	1.14
  +++ ManagedEntityIdentityInterceptor.java	13 Dec 2006 04:54:19 -0000	1.15
  @@ -1,23 +1,16 @@
   package org.jboss.seam.interceptors;
   
  -import java.io.Serializable;
   import java.lang.reflect.Field;
   import java.lang.reflect.Modifier;
   import java.util.ArrayList;
   import java.util.List;
  -import java.util.Set;
   
  -import javax.persistence.EntityManager;
  -
  -import org.hibernate.Session;
  -import org.jboss.seam.Component;
  -import org.jboss.seam.Seam;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Interceptor;
  +import org.jboss.seam.contexts.PassivatedEntity;
   import org.jboss.seam.core.PersistenceContexts;
   import org.jboss.seam.intercept.InvocationContext;
  -import org.jboss.seam.persistence.PersistenceProvider;
   import org.jboss.seam.util.Reflections;
   
   /**
  @@ -37,39 +30,6 @@
      
      private List<PassivatedEntity> list = new ArrayList<PassivatedEntity>();
      
  -   static class PassivatedEntity implements Serializable
  -   {
  -      private Object id;
  -      private String persistenceContext;
  -      private String fieldName;
  -      private Class<?> entityClass;
  -      
  -      PassivatedEntity(Object id, Class<?> entityClass, String fieldName, String persistenceContext)
  -      {
  -         super();
  -         this.id = id;
  -         this.persistenceContext = persistenceContext;
  -         this.fieldName = fieldName;
  -         this.entityClass = entityClass;
  -      }
  -      String getPersistenceContext()
  -      {
  -         return persistenceContext;
  -      }
  -      Object getId()
  -      {
  -         return id;
  -      }
  -      String getFieldName()
  -      {
  -         return fieldName;
  -      }
  -      Class<?> getEntityClass()
  -      {
  -         return entityClass;
  -      }
  -   }
  -   
      @AroundInvoke
      public Object aroundInvoke(InvocationContext ctx) throws Exception
      {
  @@ -89,13 +49,12 @@
         PersistenceContexts touchedContexts = PersistenceContexts.instance();
         if ( touchedContexts!=null && touchedContexts.getTouchedContexts().size()>0 )
         {
  -         Set<String> pcs = touchedContexts.getTouchedContexts();
            Object bean = ctx.getTarget();
            Class beanClass = bean.getClass();
            for (; beanClass!=Object.class; beanClass=beanClass.getSuperclass())
            {
               Field[] fields = beanClass.getDeclaredFields();
  -            for (Field field: fields)
  +            for ( Field field: fields )
               {
                  boolean ignoreField = Modifier.isTransient( field.getModifiers() ) || 
                     Modifier.isStatic( field.getModifiers() )
  @@ -106,53 +65,11 @@
                     Object value = Reflections.get(field, bean);
                     if (value!=null)
                     {
  -                     Class entityClass = Seam.getEntityClass( value.getClass() );
  -                     if (entityClass!=null)
  -                     {
  -                        for (String persistenceContextName: pcs)
  -                        {
  -                           Object persistenceContext = Component.getInstance(persistenceContextName);
  -                           boolean managed;
  -                           Object id;
  -                           if (persistenceContext instanceof EntityManager)
  -                           {
  -                              EntityManager em = (EntityManager) persistenceContext;
  -                              try
  -                              {
  -                                 managed = em.isOpen() && em.contains(value);
  -                              }
  -                              catch (RuntimeException re) 
  -                              {
  -                                 //workaround for bug in HEM! //TODO; deleteme
  -                                 managed = false;
  -                              }
  -                              id = managed ? PersistenceProvider.instance().getId(value, em) : null;
  -                           }
  -                           else
  -                           {
  -                              Session session = (Session) persistenceContext;
  -                              try
  -                              {
  -                                 managed = session.isOpen() && session.contains(value);
  -                              }
  -                              catch (RuntimeException re) 
  -                              {
  -                                 //just in case! //TODO; deleteme
  -                                 managed = false;
  -                              }
  -                              id = managed ? session.getIdentifier(value) : null;
  -                           }
  -                           if (managed)
  -                           {
  -                              if (id==null)
  +                     PassivatedEntity pi = PassivatedEntity.createPassivatedEntity( value, field.getName() );
  +                     if (pi!=null)
                                 {
  -                                 throw new IllegalStateException("could not get id of: " + beanClass.getName() + '.' + field.getName());
  -                              }
  -                              list.add( new PassivatedEntity( id, entityClass, field.getName(), persistenceContextName ) );
  +                        list.add(pi);
                                 Reflections.set(field, bean, null);
  -                              break;
  -                           }
  -                        }
                        }
                     }
                  }
  @@ -169,22 +86,8 @@
            Class beanClass = bean.getClass();
            for (PassivatedEntity pe: list)
            {
  -            Object persistenceContext = Component.getInstance( pe.getPersistenceContext() );
  -            if ( persistenceContext!=null )
  -            {
  -               Object reference;
  -               if (persistenceContext instanceof EntityManager)
  -               {
  -                  EntityManager em = (EntityManager) persistenceContext;
  -                  if ( !em.isOpen() ) continue;
  -                  reference = em.getReference( pe.getEntityClass(), pe.getId() );
  -               }
  -               else
  -               {
  -                  Session session = (Session) persistenceContext;
  -                  if ( !session.isOpen() ) continue;
  -                  reference = session.load( pe.getEntityClass(), (Serializable) pe.getId() );
  -               }
  +            Object reference = pe.toEntityReference();
  +            if (reference!=null)
                  for (; beanClass!=Object.class; beanClass=beanClass.getSuperclass())
                  {
                     try
  @@ -200,6 +103,5 @@
            }
            list.clear();
         }
  -   }
      
   }
  
  
  


From gavin.king at jboss.com  Tue Dec 12 23:54:19 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 12 Dec 2006 23:54:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts    ...
Message-ID: <E1GuM8J-0005J3-Et@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/12 23:54:19

  Modified:    src/main/org/jboss/seam/contexts    WebSessionContext.java
                        ServerConversationContext.java Lifecycle.java
  Log:
  maintain referential integrity for entity beans in conversation context
  
  Revision  Changes    Path
  1.27      +4 -2      jboss-seam/src/main/org/jboss/seam/contexts/WebSessionContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WebSessionContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/WebSessionContext.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- WebSessionContext.java	25 Nov 2006 02:56:06 -0000	1.26
  +++ WebSessionContext.java	13 Dec 2006 04:54:19 -0000	1.27
  @@ -16,7 +16,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.26 $
  + * @version $Revision: 1.27 $
    */
   public class WebSessionContext implements Context 
   {
  @@ -93,7 +93,9 @@
         for ( String name: getNames() )
         {
            Object attribute = session.getAttribute(name);
  -         if ( attribute!=null && Lifecycle.isAttributeDirty(attribute) )
  +         boolean dirty = attribute!=null && 
  +               ( Lifecycle.isAttributeDirty(attribute) || Seam.isEntityClass( attribute.getClass() ) );
  +         if ( dirty )
            {
               session.setAttribute(name, attribute);
            }
  
  
  
  1.18      +42 -13    jboss-seam/src/main/org/jboss/seam/contexts/ServerConversationContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerConversationContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/ServerConversationContext.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- ServerConversationContext.java	25 Nov 2006 02:56:06 -0000	1.17
  +++ ServerConversationContext.java	13 Dec 2006 04:54:19 -0000	1.18
  @@ -26,7 +26,7 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class ServerConversationContext implements Context {
   
  @@ -84,12 +84,22 @@
   	public Object get(String name) 
      {
         Object result = additions.get(name);
  -      if (result!=null) return result;
  -      if ( removals.contains(name) ) return null;
  +      if (result!=null)
  +      {
  +         return unwrapEntityBean(result);
  +      }
  +      else
  +      {
  +         if ( removals.contains(name) ) 
  +         {
  +            return null;
  +         }
  +         else
  +         {
         List<String> stack = getIdStack();
         if (stack==null)
         {
  -         return session.getAttribute( getKey(name) );
  +               return unwrapEntityBean( session.getAttribute( getKey(name) ) );
         }
         else
         {
  @@ -99,11 +109,26 @@
               result = session.getAttribute( getKey(name, id) );
               boolean found = result!=null && 
                     ( i==0 || !result.getClass().isAnnotationPresent(PerNestedConversation.class) );
  -            if (found) return result;
  +                  if (found) return unwrapEntityBean(result);
            }
            return null;
         }
   	}
  +      }
  +	}
  +
  +   private Object unwrapEntityBean(Object result)
  +   {
  +      if (result==null) return null;
  +      if ( result instanceof EntityBean )
  +      {
  +         return ( (EntityBean) result ).getInstance();
  +      }
  +      else
  +      {
  +         return result;
  +      }
  +   }
   
      public void set(String name, Object value) 
      {
  @@ -116,6 +141,10 @@
         else
         {
            removals.remove(name);
  +         if ( Seam.isEntityClass( value.getClass() ) )
  +         {
  +            value = new EntityBean(value);
  +         }
            additions.put(name, value);
         }
         if ( Events.exists() ) Events.instance().raiseEvent("org.jboss.seam.postSetVariable." + name);
  
  
  
  1.70      +3 -4      jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.69
  retrieving revision 1.70
  diff -u -b -r1.69 -r1.70
  --- Lifecycle.java	3 Dec 2006 07:01:47 -0000	1.69
  +++ Lifecycle.java	13 Dec 2006 04:54:19 -0000	1.70
  @@ -7,9 +7,9 @@
   package org.jboss.seam.contexts;
   
   import java.util.Set;
  +
   import javax.faces.context.ExternalContext;
   import javax.faces.event.PhaseId;
  -import javax.persistence.Entity;
   import javax.servlet.ServletContext;
   import javax.servlet.ServletRequest;
   import javax.servlet.http.HttpServletRequest;
  @@ -31,7 +31,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.69 $
  + * @version $Revision: 1.70 $
    */
   public class Lifecycle
   {
  @@ -447,8 +447,7 @@
   
      public static boolean isAttributeDirty(Object attribute)
      {
  -      return ( attribute instanceof Mutable && ( (Mutable) attribute ).clearDirty() ) || 
  -            attribute.getClass().isAnnotationPresent(Entity.class);
  +      return attribute instanceof Mutable && ( (Mutable) attribute ).clearDirty();
      }
   
   }
  
  
  


From gavin.king at jboss.com  Tue Dec 12 23:54:19 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 12 Dec 2006 23:54:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam   ...
Message-ID: <E1GuM8J-0005JD-My@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/12 23:54:19

  Modified:    src/main/org/jboss/seam   Component.java Seam.java
  Log:
  maintain referential integrity for entity beans in conversation context
  
  Revision  Changes    Path
  1.218     +2 -2      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.217
  retrieving revision 1.218
  diff -u -b -r1.217 -r1.218
  --- Component.java	6 Dec 2006 07:36:58 -0000	1.217
  +++ Component.java	13 Dec 2006 04:54:19 -0000	1.218
  @@ -121,7 +121,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.217 $
  + * @version $Revision: 1.218 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -771,7 +771,7 @@
         {
            addInterceptor( new Interceptor( new TransactionInterceptor(), this ) );
         }
  -      if ( getScope()!=STATELESS && getScope()!=EVENT )
  +      if ( getScope()==CONVERSATION )
         {
            addInterceptor( new Interceptor( new ManagedEntityIdentityInterceptor(), this ) );
         }
  
  
  
  1.26      +18 -1     jboss-seam/src/main/org/jboss/seam/Seam.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Seam.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Seam.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- Seam.java	1 Nov 2006 01:52:08 -0000	1.25
  +++ Seam.java	13 Dec 2006 04:54:19 -0000	1.26
  @@ -1,4 +1,4 @@
  -//$Id: Seam.java,v 1.25 2006/11/01 01:52:08 gavin Exp $
  +//$Id: Seam.java,v 1.26 2006/12/13 04:54:19 gavin Exp $
   package org.jboss.seam;
   
   import static org.jboss.seam.ComponentType.ENTITY_BEAN;
  @@ -125,6 +125,23 @@
         return null;
      }
      
  +   /**
  +    * Is the class a container-generated proxy class for an 
  +    * entity bean?
  +    */
  +   public static boolean isEntityClass(Class<?> clazz)
  +   {
  +      while ( clazz!=null && !Object.class.equals(clazz) )
  +      {
  +         if ( clazz.isAnnotationPresent(Entity.class) )
  +         {
  +            return true;
  +         }
  +         clazz = clazz.getSuperclass();
  +      }
  +      return false;
  +   }
  +   
      public static String getEjbName(Class<?> clazz)
      {
         switch ( getComponentType(clazz) )
  
  
  


From gavin.king at jboss.com  Tue Dec 12 23:56:56 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 12 Dec 2006 23:56:56 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GuMAq-0005Ns-BC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/12 23:56:56

  Added:       src/main/org/jboss/seam/contexts  EntityBean.java
  Log:
  maintain referential integrity for entity beans in conversation context
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 04:56:56;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java
  
  Index: EntityBean.java
  ===================================================================
  package org.jboss.seam.contexts;
  
  import org.jboss.seam.core.Mutable;
  
  public class EntityBean implements Mutable
  {
     private Object instance;
     private PassivatedEntity passivatedEntity;
  
     public EntityBean(Object instance)
     {
        this.instance = instance;
     }
  
     //TODO: use @Unwrap
     public Object getInstance()
     {
        if (passivatedEntity==null)
        {
           return instance;
        }
        else
        {
           return passivatedEntity.toEntityReference();
        }
     }
     
     public boolean clearDirty()
     {
        passivatedEntity = PassivatedEntity.createPassivatedEntity(instance, null);
        if (passivatedEntity!=null)
        {
           instance = null;
        }
        return true;
     }
  }
  
  
  


From gavin.king at jboss.com  Tue Dec 12 23:57:59 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 12 Dec 2006 23:57:59 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GuMBr-0005OV-LW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/12 23:57:59

  Added:       src/main/org/jboss/seam/contexts  PassivatedEntity.java
  Log:
  maintain referential integrity for entity beans in conversation context
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 04:57:59;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java
  
  Index: PassivatedEntity.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.contexts;
  
  import java.io.Serializable;
  
  import javax.persistence.EntityManager;
  
  import org.hibernate.Session;
  import org.jboss.seam.Component;
  import org.jboss.seam.Seam;
  import org.jboss.seam.core.PersistenceContexts;
  import org.jboss.seam.persistence.PersistenceProvider;
  
  public class PassivatedEntity implements Serializable
  {
     
     private Object id;
     private String persistenceContext;
     private String fieldName;
     private Class<?> entityClass;
     
     private PassivatedEntity(Object id, Class<?> entityClass, String persistenceContext, String fieldName)
     {
        this.id = id;
        this.persistenceContext = persistenceContext;
        this.fieldName = fieldName;
        this.entityClass = entityClass;
     }
     
     public String getPersistenceContext()
     {
        return persistenceContext;
     }
     
     public Object getId()
     {
        return id;
     }
     
     public String getFieldName()
     {
        return fieldName;
     }
     
     public Class<?> getEntityClass()
     {
        return entityClass;
     }
  
     public Object toEntityReference()
     {
        Object persistenceContext = Component.getInstance( getPersistenceContext() );
        if ( persistenceContext==null )
        {
           return null;
        }
        else
        {
           if (persistenceContext instanceof EntityManager)
           {
              EntityManager em = (EntityManager) persistenceContext;
              return em.isOpen() ? 
                       em.getReference( getEntityClass(), getId() ) : null;
           }
           else
           {
              Session session = (Session) persistenceContext;
              return session.isOpen() ? 
                       session.load( getEntityClass(), (Serializable) getId() ) : null;
           }
        }
     }
  
     public static PassivatedEntity createPassivatedEntity(Object value, String fieldName)
     {
        Class entityClass = Seam.getEntityClass( value.getClass() );
        if (entityClass!=null)
        {
           for ( String persistenceContextName: PersistenceContexts.instance().getTouchedContexts() )
           {
              Object persistenceContext = Component.getInstance(persistenceContextName);
              boolean managed;
              Object id;
              if (persistenceContext instanceof EntityManager)
              {
                 EntityManager em = (EntityManager) persistenceContext;
                 try
                 {
                    managed = em.isOpen() && em.contains(value);
                 }
                 catch (RuntimeException re) 
                 {
                    //workaround for bug in HEM! //TODO; deleteme
                    managed = false;
                 }
                 id = managed ? PersistenceProvider.instance().getId(value, em) : null;
              }
              else
              {
                 Session session = (Session) persistenceContext;
                 try
                 {
                    managed = session.isOpen() && session.contains(value);
                 }
                 catch (RuntimeException re) 
                 {
                    //just in case! //TODO; deleteme
                    managed = false;
                 }
                 id = managed ? session.getIdentifier(value) : null;
              }
              if (managed)
              {
                 if (id==null)
                 {
                    throw new IllegalStateException("could not get id of: " + /*beanClass.getName() + '.' +*/ fieldName);
                 }
                 return new PassivatedEntity( id, entityClass, persistenceContextName, fieldName );
              }
           }
        }
        return null;
     }
     
  }
  
  


From gavin.king at jboss.com  Tue Dec 12 23:59:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 12 Dec 2006 23:59:31 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GuMDL-0005Op-2R@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/12 23:59:31

  Modified:    src/main/org/jboss/seam/interceptors 
                        SecurityInterceptor.java
  Log:
  minor
  
  Revision  Changes    Path
  1.14      +0 -3      jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- SecurityInterceptor.java	11 Dec 2006 00:56:30 -0000	1.13
  +++ SecurityInterceptor.java	13 Dec 2006 04:59:31 -0000	1.14
  @@ -2,8 +2,6 @@
   
   import java.lang.reflect.Method;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.annotations.security.Restrict;
  @@ -21,7 +19,6 @@
                within = BijectionInterceptor.class)
   public class SecurityInterceptor extends AbstractInterceptor
   {
  -  private static final Log log = LogFactory.getLog(SecurityInterceptor.class);
   
     @AroundInvoke
     public Object checkSecurity(InvocationContext invocation)
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 13 00:08:53 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 00:08:53 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GuMMP-0005j2-AM@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 00:08:53

  Modified:    src/main/org/jboss/seam/security  Identity.java
  Log:
  added security manager dependencies
  
  Revision  Changes    Path
  1.3       +3 -2      jboss-seam/src/main/org/jboss/seam/security/Identity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Identity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/Identity.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Identity.java	4 Dec 2006 04:23:51 -0000	1.2
  +++ Identity.java	13 Dec 2006 05:08:53 -0000	1.3
  @@ -1,18 +1,19 @@
   package org.jboss.seam.security;
   
  -import static org.jboss.seam.ScopeType.SESSION;
  -
   import java.io.Serializable;
   import java.security.Principal;
   
  +import static org.jboss.seam.ScopeType.SESSION;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
  +import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
   
   @Name("org.jboss.seam.security.identity")
   @Scope(SESSION)
  + at Install(dependencies = "org.jboss.seam.securityManager")
   public abstract class Identity implements Principal, Serializable
   {
     protected boolean authenticated;
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 13 00:08:53 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 00:08:53 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/authenticator
	...
Message-ID: <E1GuMMP-0005j9-Dm@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 00:08:53

  Modified:    src/main/org/jboss/seam/security/authenticator 
                        Authenticator.java
  Log:
  added security manager dependencies
  
  Revision  Changes    Path
  1.16      +3 -4      jboss-seam/src/main/org/jboss/seam/security/authenticator/Authenticator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Authenticator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/authenticator/Authenticator.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- Authenticator.java	4 Dec 2006 01:21:52 -0000	1.15
  +++ Authenticator.java	13 Dec 2006 05:08:53 -0000	1.16
  @@ -1,18 +1,17 @@
   package org.jboss.seam.security.authenticator;
   
  -import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.util.ArrayList;
   import java.util.List;
   
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  +import static org.jboss.seam.annotations.Install.BUILT_IN;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.UsernamePasswordToken;
   import org.jboss.seam.security.adapter.AuthenticationAdapter;
   import org.jboss.seam.util.Reflections;
  @@ -23,7 +22,7 @@
    * @author Shane Bryzak
    */
   @Name("org.jboss.seam.security.authenticator")
  - at Install(value=false, precedence=BUILT_IN)
  + at Install(value=false, precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
   public abstract class Authenticator
   {
     private List<AuthenticationAdapter> adapters = new ArrayList<AuthenticationAdapter>();
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 13 00:08:53 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 00:08:53 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1GuMMP-0005jG-J2@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 00:08:53

  Modified:    src/main/org/jboss/seam/security/config 
                        SecurityConfiguration.java
  Log:
  added security manager dependencies
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SecurityConfiguration.java	13 Dec 2006 01:52:30 -0000	1.1
  +++ SecurityConfiguration.java	13 Dec 2006 05:08:53 -0000	1.2
  @@ -29,7 +29,7 @@
    */
   @Scope(APPLICATION)
   @Name("org.jboss.seam.security.securityConfiguration")
  - at Install(value = false, precedence=BUILT_IN)
  + at Install(value = false, precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
   @Intercept(InterceptionType.NEVER)
   public class SecurityConfiguration
   {
  
  
  


From gavin.king at jboss.com  Wed Dec 13 00:14:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 00:14:45 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GuMS5-0005oy-Qo@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 00:14:45

  Modified:    src/main/org/jboss/seam/contexts  EntityBean.java
  Log:
  oops
  
  Revision  Changes    Path
  1.2       +6 -3      jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- EntityBean.java	13 Dec 2006 04:56:56 -0000	1.1
  +++ EntityBean.java	13 Dec 2006 05:14:45 -0000	1.2
  @@ -27,11 +27,14 @@
      
      public boolean clearDirty()
      {
  +      if (passivatedEntity==null)
  +      {
         passivatedEntity = PassivatedEntity.createPassivatedEntity(instance, null);
         if (passivatedEntity!=null)
         {
            instance = null;
         }
  +      }
         return true;
      }
   }
  
  
  


From gavin.king at jboss.com  Wed Dec 13 00:19:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 00:19:40 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GuMWq-0005u9-C2@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 00:19:40

  Modified:    src/main/org/jboss/seam/security  Identity.java
  Log:
  precedence
  
  Revision  Changes    Path
  1.4       +4 -2      jboss-seam/src/main/org/jboss/seam/security/Identity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Identity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/Identity.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- Identity.java	13 Dec 2006 05:08:53 -0000	1.3
  +++ Identity.java	13 Dec 2006 05:19:40 -0000	1.4
  @@ -1,9 +1,11 @@
   package org.jboss.seam.security;
   
  +import static org.jboss.seam.ScopeType.SESSION;
  +import static org.jboss.seam.annotations.Install.BUILT_IN;
  +
   import java.io.Serializable;
   import java.security.Principal;
   
  -import static org.jboss.seam.ScopeType.SESSION;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -13,7 +15,7 @@
   
   @Name("org.jboss.seam.security.identity")
   @Scope(SESSION)
  - at Install(dependencies = "org.jboss.seam.securityManager")
  + at Install(precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
   public abstract class Identity implements Principal, Serializable
   {
     protected boolean authenticated;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 00:30:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 00:30:43 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1780 - in trunk: .
	src/main/org/jboss/jms/client/delegate src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/bin tests/etc
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GuMhX-00066f-B2@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-13 00:30:32 -0500 (Wed, 13 Dec 2006)
New Revision: 1780

Modified:
   trunk/messaging.iml
   trunk/messaging.ipr
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java
   trunk/tests/bin/runtest
   trunk/tests/etc/log4j.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
Log:
- Fixed a cascade failover bug.
- The PostOffice that completes the failover sends now a JMX FAILOVER_COMPLETED_NOTIFICATION.
- Multiple logging improvments (watch for a logging blog, coming soon).
- Minor refactoring.



Modified: trunk/messaging.iml
===================================================================
--- trunk/messaging.iml	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/messaging.iml	2006-12-13 05:30:32 UTC (rev 1780)
@@ -41,6 +41,10 @@
     <orderEntry type="library" name="jgroups" level="project" />
     <orderEntry type="library" name="junit" level="project" />
     <orderEntry type="library" name="jboss-system" level="project" />
+    <orderEntry type="library" name="jboss-common-jdbc-wrapper" level="project" />
+    <orderEntry type="library" name="jboss-jca" level="project" />
+    <orderEntry type="library" name="jboss-local-jdbc" level="project" />
+    <orderEntry type="library" name="jms-ra" level="project" />
     <orderEntryProperties />
   </component>
   <component name="VcsManagerConfiguration">

Modified: trunk/messaging.ipr
===================================================================
--- trunk/messaging.ipr	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/messaging.ipr	2006-12-13 05:30:32 UTC (rev 1780)
@@ -308,6 +308,34 @@
       <JAVADOC />
       <SOURCES />
     </library>
+    <library name="jboss-common-jdbc-wrapper">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/tests/lib/jboss-common-jdbc-wrapper.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jboss-jca">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/tests/lib/jboss-jca.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jboss-local-jdbc">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/tests/lib/jboss-local-jdbc.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
+    <library name="jms-ra">
+      <CLASSES>
+        <root url="jar://$PROJECT_DIR$/tests/lib/jms-ra.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES />
+    </library>
   </component>
   <component name="uidesigner-configuration">
     <option name="INSTRUMENT_CLASSES" value="true" />

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -294,7 +294,7 @@
 
    public String toString()
    {
-      return "ClientConnectionFactoryDelegate[" + id + "]";
+      return "ClientConnectionFactoryDelegate[ID=" + id + "]";
    }
    
    public String getServerLocatorURI()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -118,7 +118,17 @@
 
    public String toString()
    {
-      return "ClusteredClientConnectionFactoryDelegate[" + id + "] with delegates.length = " + (delegates==null?"null":Integer.toString(delegates.length));
+      StringBuffer sb = new StringBuffer("ClusteredConnFactoryDelegate[ID=");
+      sb.append(id).append("][");
+      if (delegates == null)
+      {
+         sb.append("0]");
+      }
+      else
+      {
+         sb.append(delegates.length).append("]");
+      }
+      return sb.toString();
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -756,8 +756,6 @@
             //TODO we shouldn't have a dependency on DefaultClusteredPostOffice - where should we put the constants?
             Map replicants = replicator.get(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY);
             
-            log.info("Got replicants");
-            
             boolean foundEntry = false;
                         
             if (replicants != null)
@@ -1099,14 +1097,15 @@
    
    private class FailoverListener implements ReplicationListener
    {
-      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added, int originatingNodeId)
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap,
+                                      boolean added, int originatingNodeId)
       {
          if (key.equals(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY))
          {
-            //We have a failover status change - notify anyone waiting
-            
-            log.info("Got replication change on failed over map, notifying those waiting on lock");
-            
+            // We have a failover status change - notify anyone waiting
+
+            log.debug(ServerPeer.this + ".FailoverListener got failover event, notifying those waiting on lock");
+
             synchronized (failoverStatusLock)
             {
                failoverStatusLock.notifyAll();

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -67,6 +67,8 @@
    private static final String CF_PREFIX = "CF_";
    
    // Attributes ----------------------------------------------------
+
+   private boolean trace = log.isTraceEnabled();
    
    protected Context initialContext;
    protected ServerPeer serverPeer;
@@ -109,8 +111,7 @@
                                                       boolean clustered)
       throws Exception
    {
-      log.info("Registering connection factory with name " + uniqueName + " " + 
-               "bindings " + jndiBindings);
+      log.debug(this + " registering connection factory '" + uniqueName + "', bindings: " + jndiBindings);
       
       // Sanity check
       if (delegates.containsKey(uniqueName))
@@ -267,7 +268,6 @@
    public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap,
                                                 boolean added, int originatingNodeId)
    {
-      log.info("Got replication call " + key + " node=" + serverPeer.getServerPeerID() + " replicants=" + updatedReplicantMap + " added=");
       try
       {         
          if (!(key instanceof String))
@@ -279,31 +279,26 @@
 
          if (sKey.equals(DefaultClusteredPostOffice.ADDRESS_INFO_KEY))
          {
-           /* 
-            We respond to changes in the node-address mapping
-            This will be replicated whan a node joins / leaves the group
-            When this happens we need to recalculate the failoverMap
-            and rebind all connection factories with the new mapping
-            We cannot just reference a single map since the objects are bound in JNDI
-            in serialized form
-            */
-            log.info("responding to node - adress info change. Recalculating mapping and rebinding cfs");
-            
+            log.debug(this + " received address mapping change " + updatedReplicantMap);
+
+            // We respond to changes in the node-address mapping. This will be replicated whan a
+            // node joins / leaves the group. When this happens we need to recalculate the
+            // failoverMap and rebind all connection factories with the new mapping. We cannot just
+            // reference a single map since the objects are bound in JNDI in serialized form.
+
             recalculateFailoverMap(updatedReplicantMap);
             
-            //rebind
-            Iterator iter = endpoints.entrySet().iterator();
-            
-            while (iter.hasNext())
+            // Rebind
+
+            for(Iterator i = endpoints.entrySet().iterator(); i.hasNext(); )
             {
-               Map.Entry entry = (Map.Entry)iter.next();
-               
+               Map.Entry entry = (Map.Entry)i.next();
                String uniqueName = (String)entry.getKey();
-               
                ServerConnectionFactoryEndpoint endpoint =
                   (ServerConnectionFactoryEndpoint)entry.getValue();
                
-               ClusteredClientConnectionFactoryDelegate del = (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+               ClusteredClientConnectionFactoryDelegate del =
+                  (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
                
                if (del == null)
                {
@@ -311,37 +306,33 @@
                }
                
                del.setFailoverMap(failoverMap);
-               
                rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
             }
-            
          }
          else if (sKey.startsWith(CF_PREFIX) && originatingNodeId != serverPeer.getServerPeerID())
          {
-            /*
-            A connection factory has been deployed / undeployed - we need to update the local delegate arrays inside the clustered
-            connection factories with the same name
-            We don't recalculate the failover map since the number of nodes in the group hasn't changed
-            We also ignore any local changes since the cf will already be bound locally with the new
-            local delegate in the array
-            */
-            
+            // A connection factory has been deployed / undeployed - we need to update the local
+            // delegate arrays inside the clustered connection factories with the same name. We
+            // don't recalculate the failover map since the number of nodes in the group hasn't
+            // changed. We also ignore any local changes since the cf will already be bound locally
+            // with the new local delegate in the array
+
             String uniqueName = sKey.substring(CF_PREFIX.length());
+
+            log.debug(this + " received '" + uniqueName + "' connection factory update " + updatedReplicantMap);
+
+            ClusteredClientConnectionFactoryDelegate del =
+               (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
             
-            log.info("Connection factory with unique name " + uniqueName + " has been added / removed");
-            
-            ClusteredClientConnectionFactoryDelegate del = (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
-            
             if (del == null)
             {
                throw new IllegalStateException("Cannot find cf with name " + uniqueName);
             }
             
             ClientConnectionFactoryDelegate[] delArr = 
-               (ClientConnectionFactoryDelegate[])updatedReplicantMap.values().toArray(new ClientConnectionFactoryDelegate[updatedReplicantMap.size()]);
+               (ClientConnectionFactoryDelegate[])updatedReplicantMap.values().
+                  toArray(new ClientConnectionFactoryDelegate[updatedReplicantMap.size()]);
 
-            log.info("Updating delsArr with size " + delArr.length);
-            
             del.setDelegates(delArr);
             
             ServerConnectionFactoryEndpoint endpoint =
@@ -353,8 +344,7 @@
             }
             
             rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
-            
-         }            
+         }
       }
       catch (Exception e)
       {
@@ -370,6 +360,11 @@
       
       replicator.registerListener(this);
    }
+
+   public String toString()
+   {
+      return "Server[" + serverPeer.getServerPeerID() + "].ConnFactoryJNDIMapper";
+   }
    
    // Package protected ---------------------------------------------
    
@@ -385,22 +380,22 @@
    private void recalculateFailoverMap(Map nodeAddressMap) throws Exception
    {     
       FailoverMapper mapper = replicator.getFailoverMapper();
-      
       failoverMap = mapper.generateMapping(nodeAddressMap.keySet());
    }
    
    /**
     * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
     */
-   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates) throws Exception
+   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates)
+      throws Exception
    {
-      //TODO: make it trace after the code is stable
-      log.info("Updating FailoverDelegates " + localDelegates.size() + " on serverPeer:" + serverPeer.getServerPeerID());
+      if (trace) { log.trace(this + " updating failover delegates, map size " + localDelegates.size()); }
 
       ClientConnectionFactoryDelegate[] delArr = 
-         (ClientConnectionFactoryDelegate[])localDelegates.values().toArray(new ClientConnectionFactoryDelegate[localDelegates.size()]);
+         (ClientConnectionFactoryDelegate[])localDelegates.values().
+            toArray(new ClientConnectionFactoryDelegate[localDelegates.size()]);
 
-      //If the map is not cached - generate it now
+      // If the map is not cached - generate it now
       
       if (failoverMap == null)
       {
@@ -414,12 +409,13 @@
          recalculateFailoverMap(nodeAddressMap);
       }
 
-      // The main delegated is needed for the construction of ClusteredClientConnectionFactoryDelegate
-      // ClusteredClientConnectionFactoryDelegate extends ClientConnectionFactoryDelegate and it will
-      // need the current server's delegate properties to be bound to ObjectId, ServerLocator and
-      // other connection properties.
-      //
-      // The ClusteredCFDelegate will copy these properties on its contructor defined bellow after this loop
+      // The main delegated is needed for the construction of
+      // ClusteredClientConnectionFactoryDelegate. ClusteredClientConnectionFactoryDelegate extends
+      // ClientConnectionFactoryDelegate and it will need the current server's delegate properties
+      // to be bound to ObjectId, ServerLocator and other connection properties.
+      // The ClusteredCFDelegate will copy these properties on its contructor defined bellow after
+      // this loop.
+
       ClientConnectionFactoryDelegate mainDelegate = null;
       
       for(Iterator i = localDelegates.values().iterator(); i.hasNext();)
@@ -431,7 +427,8 @@
              // sanity check
              if (mainDelegate != null)
              {
-                throw new IllegalStateException("There are two servers with serverID=" + this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
+                throw new IllegalStateException("There are two servers with serverID=" +
+                   this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
              }
              mainDelegate = del;
           }
@@ -453,7 +450,7 @@
          for(Iterator i = jndiNames.iterator(); i.hasNext(); )
          {
             String jndiName = (String)i.next();
-            log.info("Rebinding " + jndiName + " CF=" + cf );
+            log.debug(this + " rebinding " + cf + " as " + jndiName);
             JNDIUtil.rebind(ic, jndiName, cf);
          }
       }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -41,6 +41,7 @@
 public interface ClusteredPostOffice extends PostOffice, Peer
 {
    public static final String VIEW_CHANGED_NOTIFICATION = "VIEW_CHANGED";
+   public static final String FAILOVER_COMPLETED_NOTIFICATION = "FAILOVER_COMPLETED";
 
    /**
     * Bind a queue to the post office under a specific condition

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/FailoverMapper.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -37,5 +37,8 @@
  */
 public interface FailoverMapper
 {
+   /**
+    * @param nodes Set<Integer>.
+    */
    Map generateMapping(Set nodes);
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -635,11 +635,11 @@
    public void putReplicantLocally(int originatorNodeID, Serializable key, Serializable replicant)
       throws Exception
    {
-      log.info("##########putReplicantLocally received, before lock");
 
       synchronized (replicatedData)
       {
-         log.info("putReplicantLocally received, after lock");
+         log.debug(this + " puts replicant locally: " + key + "->" + replicant);
+
          Map m = (Map)replicatedData.get(key);
 
          if (m == null)
@@ -652,9 +652,9 @@
          m.put(new Integer(originatorNodeID), replicant);
 
          notifyListeners(key, m, true, originatorNodeID);
-      }
 
-      log.info("putReplicantLocally, completed");
+         if (trace) { log.trace(this + " putReplicantLocally completed"); }
+      }
    }
 
    /**
@@ -664,7 +664,7 @@
    {
       synchronized (replicatedData)
       {
-         log.info(this.currentNodeId + " removing key " + key + " from node " + originatorNodeID);
+         if (trace) { log.trace(this + " removes " + originatorNodeID + "'s replicant locally for key " + key); }
 
          Map m = (Map)replicatedData.get(key);
 
@@ -1323,9 +1323,9 @@
    /**
     * Check for any transactions that need to be committed or rolled back
     */
-   public void check(Integer nodeId) throws Throwable
+   public void checkTransactions(Integer nodeId) throws Throwable
    {
-      if (trace) { log.trace(this.currentNodeId + " checking for any stranded transactions for node " + nodeId); }
+      if (trace) { log.trace(this + " checking for any stranded transactions for node " + nodeId); }
 
       synchronized (holdingArea)
       {
@@ -1343,11 +1343,11 @@
             {
                ClusterTransaction tx = (ClusterTransaction)entry.getValue();
 
-               if (trace) { log.trace("Found transaction " + tx + " in holding area"); }
+               if (trace) { log.trace("found transaction " + tx + " in holding area"); }
 
                boolean commit = tx.check(this);
 
-               if (trace) { log.trace(this.currentNodeId + " transaction " + tx + " will be committed?: " + commit); }
+               if (trace) { log.trace("transaction " + tx + " will be " + (commit ? "COMMITTED" : "ROLLED BACK")); }
 
                if (commit)
                {
@@ -1360,11 +1360,11 @@
 
                toRemove.add(id);
 
-               if (trace) { log.trace(this.currentNodeId + " resolved " + tx); }
+               if (trace) { log.trace("resolved " + tx); }
             }
          }
 
-         //Remove the transactions from the holding area
+         // Remove the transactions from the holding area
 
          iter = toRemove.iterator();
 
@@ -1375,7 +1375,7 @@
             holdingArea.remove(id);
          }
       }
-      if (trace) { log.trace(this.currentNodeId + " check complete"); }
+      if (trace) { log.trace(this + " transaction check complete"); }
    }
 
    public int getNodeId()
@@ -1703,7 +1703,7 @@
     */
    private void removeDataForNode(Integer nodeToRemove) throws Exception
    {
-      log.info("Node " + nodeToRemove + " requested to leave cluster");
+      log.debug(this + " cleaning local data for node " + nodeToRemove);
 
       lock.writeLock().acquire();
 
@@ -1715,26 +1715,22 @@
          {
             List toRemove = new ArrayList();
 
-            Iterator iter = nameMap.values().iterator();
-
-            while (iter.hasNext())
+            for(Iterator i = nameMap.values().iterator(); i.hasNext(); )
             {
-               Binding binding = (Binding)iter.next();
+               Binding binding = (Binding)i.next();
 
                if (!binding.getQueue().isRecoverable())
                {
-                  //We only remove the non durable bindings - we still need to be able to handle
-                  //messages for a durable subscription "owned" by a node that is not active any more!
+                  // We only remove the non durable bindings - we still need to be able to handle
+                  // messages for a durable subscription "owned" by a node that is not active any
+                  // more!
                   toRemove.add(binding);
                }
             }
 
-            iter = toRemove.iterator();
-
-            while (iter.hasNext())
+            for(Iterator i = toRemove.iterator(); i.hasNext(); )
             {
-               Binding binding = (Binding)iter.next();
-
+               Binding binding = (Binding)i.next();
                removeBinding(nodeToRemove.intValue(), binding.getQueue().getName());
             }
          }
@@ -1750,7 +1746,6 @@
          for(Iterator i = replicatedData.entrySet().iterator(); i.hasNext(); )
          {
             Map.Entry entry = (Map.Entry)i.next();
-
             String key = (String)entry.getKey();
             Map replicants = (Map)entry.getValue();
 
@@ -1761,7 +1756,6 @@
                i.remove();
             }
 
-            // Need to trigger listeners
             notifyListeners(key, replicants, false, nodeToRemove.intValue());
          }
       }
@@ -1779,7 +1773,6 @@
          for (Iterator i = replicationListeners.iterator(); i.hasNext(); )
          {
             ReplicationListener listener = (ReplicationListener)i.next();
-
             listener.onReplicationChange(key, updatedReplicantMap, added, originatorNodeId);
          }
       }
@@ -1792,37 +1785,13 @@
    {
       if (trace) { log.trace(this + " sending synch request " + request); }
 
-      byte[] bytes = writeRequest(request);
+      Message message = new Message(null, null, writeRequest(request));
 
-      Message message = new Message(null, null, bytes);
-
       controlMessageDispatcher.castMessage(null, message, GroupRequest.GET_ALL, castTimeout);
 
       if (trace) { log.trace(this + " request sent OK"); }
    }
 
-   //DEBUG ONLY - remove this
-   private void dumpNodeIdAddressMap(Map map) throws Exception
-   {
-      log.info("** DUMPING NODE ADDRESS MAPPING");
-
-      Iterator iter = map.entrySet().iterator();
-
-      while (iter.hasNext())
-      {
-         Map.Entry entry = (Map.Entry)iter.next();
-
-         Integer theNodeId = (Integer)entry.getKey();
-
-         PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
-
-         log.info("node id: " + theNodeId +" --------->(async:sync) " + info.getAsyncChannelAddress() + ":" + info.getSyncChannelAddress());
-      }
-
-      log.info("** END DUMP");
-   }
-
-
    //TODO - this is a bit tortuous - needs optimising
    private Integer getNodeIdForSyncAddress(Address address) throws Exception
    {
@@ -1835,33 +1804,20 @@
             throw new IllegalStateException("Cannot find node id -> address mapping");
          }
 
-         this.dumpNodeIdAddressMap(map);
+         Integer nid = null;
 
-         Iterator iter = map.entrySet().iterator();
-
-         log.info("iterating, looking for " + address);
-
-         Integer theNodeId = null;
-         while (iter.hasNext())
+         for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
          {
-            Map.Entry entry = (Map.Entry)iter.next();
-
+            Map.Entry entry = (Map.Entry)i.next();
             PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
 
-            log.info("info synch channel address: " + info.getSyncChannelAddress());
-
             if (info.getSyncChannelAddress().equals(address))
             {
-               log.info("equal");
-               theNodeId = (Integer)entry.getKey();
+               nid = (Integer)entry.getKey();
                break;
             }
-            else
-            {
-               log.info("Not equal");
-            }
          }
-         return theNodeId;
+         return nid;
       }
    }
 
@@ -2061,11 +2017,9 @@
     */
    private void nodeJoined(Address address) throws Exception
    {
-      if (trace) { log.trace(this + ": " + address + " joined"); }
+      log.debug(this + ": " + address + " joined");
 
-      log.info(this.currentNodeId + " Node with address: " + address + " joined");
-
-      //Currently does nothing
+      // Currently does nothing
    }
 
    /*
@@ -2073,277 +2027,230 @@
     */
    private void nodeLeft(Address address) throws Throwable
    {
-      if (trace) { log.trace(this + ": " + address + " left"); }
+      log.debug(this + ": " + address + " left");
 
-      log.info(this.currentNodeId + " Node with address: " + address + " left");
+      Integer nid = getNodeIdForSyncAddress(address);
 
-      Integer theNodeId = getNodeIdForSyncAddress(address);
-
-      if (theNodeId == null)
+      if (nid == null)
       {
-         throw new IllegalStateException(this.currentNodeId + " Cannot find node id for address " + address);
+         throw new IllegalStateException(this + " cannot find node ID for address " + address);
       }
 
-      boolean crashed = !this.leaveMessageReceived(theNodeId);
+      boolean crashed = !this.leaveMessageReceived(nid);
 
-      if (trace) { log.trace("Node " + address + " id: " + theNodeId +" has left the group, crashed = " + crashed); }
+      log.debug(this + ": node " + nid + " has " + (crashed ? "crashed" : "cleanly left the group"));
 
-      //Cleanup any hanging transactions - we do this irrespective of whether we crashed
-      check(theNodeId);
+      // Cleanup any hanging transactions - we do this irrespective of whether we crashed
+      checkTransactions(nid);
 
       synchronized (failoverMap)
       {
-         //Need to evaluate this before we regenerate the failover map
-         Integer failoverNode = (Integer)failoverMap.get(theNodeId);
+         // Need to evaluate this before we regenerate the failover map
+         Integer failoverNode = (Integer)failoverMap.get(nid);
 
          if (failoverNode == null)
          {
-            throw new IllegalStateException("Cannot find failover node for node " + theNodeId);
+            throw new IllegalStateException(this + " cannot find failover node for node " + nid);
          }
 
-         //debug dump failover map
+         // Remove any replicant data and non durable bindings for the node - again we need to do
+         // this irrespective of whether we crashed. This will notify any listeners which will
+         // recalculate the connection factory delegates and failover delegates.
 
-         Iterator iter = failoverMap.entrySet().iterator();
+         removeDataForNode(nid);
 
-         log.info("Dumping failover map");
-         while (iter.hasNext())
+         if (currentNodeId == failoverNode.intValue() && crashed)
          {
-            Map.Entry entry = (Map.Entry)iter.next();
+            // The node crashed and we are the failover node so let's perform failover
 
-            Integer nodeId = (Integer)entry.getKey();
+            log.info(this + ": I am the failover node for node " + nid + " that crashed");
 
-            Integer failoverNodeId = (Integer)entry.getValue();
-
-            log.info("node->failover node: " + nodeId + " --> " + failoverNodeId);
-         }
-         log.info("end dump");
-
-         //end debug
-
-         boolean isFailover = failoverNode.intValue() == this.currentNodeId;
-
-         log.info("Am I failover node for node " + theNodeId + "? " + isFailover);
-
-         log.info("Crashed: " + crashed);
-
-         //Remove any replicant data and non durable bindings for the node - again we need to do this
-         //irrespective of whether we crashed
-         //This will notify any listeners which will recalculate the connection factory delegates and failover delegates
-         removeDataForNode(theNodeId);
-
-         if (crashed && isFailover)
-         {
-            //The node crashed and we are the failover node
-            //so let's perform failover
-
             //TODO server side valve
 
-            failOver(theNodeId.intValue());
+            performFailover(nid);
          }
       }
    }
 
    /**
-    *  Verifies changes on the View deciding if a node joined or left the cluster.
-    */
-   private void verifyMembership(View oldView, View newView) throws Throwable
-   {
-      if (oldView != null)
-      {
-         for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
-         {
-            Address address = (Address)i.next();
-            if (!newView.containsMember(address))
-            {
-               nodeLeft(address);
-            }
-         }
-      }
-
-      for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
-      {
-         Address address = (Address)i.next();
-         if (oldView == null || !oldView.containsMember(address))
-         {
-            nodeJoined(address);
-         }
-      }
-   }
-
-   /**
-    * This method fails over all the queues from node <failedNodeId> onto this node
-    * It is triggered when a JGroups view change occurs due to a member leaving and
-    * it's determined the member didn't leave cleanly
+    * This method fails over all the queues from node <failedNodeId> onto this node. It is triggered
+    * when a JGroups view change occurs due to a member leaving and it's determined the member
+    * didn't leave cleanly.
     *
-    * @param failedNodeId
+    * @param failedNodeID
     * @throws Exception
     */
-   private void failOver(int failedNodeId) throws Exception
+   private void performFailover(Integer failedNodeID) throws Exception
    {
-      //Need to lock
+      // Need to lock
       lock.writeLock().acquire();
 
       try
       {
-         log.info(this.currentNodeId + " is performing failover for node " + failedNodeId);
+         log.debug(this + " performing failover for failed node " + failedNodeID);
 
-         /*
-         We make sure a FailoverStatus object is put in the replicated data for the node
-         The real failover node will always add this in.
-         This means that each node knows which node has really started the failover for another node, and
-         which node did failover for other nodes in the past
-         We cannot rely on the failoverMap for this, since that will regenerated once failover is done,
-         because of the change in membership.
-         And clients may failover after that and need to know if they have the correct node.
-         Since this is the first thing we do after detecting failover, it should be very quick that
-         all nodes know, however there is still a chance that a client tries to failover before
-         the information is replicated.
-         */
+         // We make sure a FailoverStatus object is put in the replicated data for the node. The
+         // real failover node will always add this in. This means that each node knows which node
+         // has really started the failover for another node, and which node did failover for other
+         // nodes in the past.
+         // We cannot rely on the failoverMap for this, since that will regenerated once failover is
+         // done, because of the change in membership. And clients may failover after that and need
+         // to know if they have the correct node. Since this is the first thing we do after
+         // detecting failover, it should be very quick that all nodes know, however there is still
+         // a chance that a client tries to failover before the information is replicated.
 
-         Map replicants = (Map)get(FAILED_OVER_FOR_KEY);
+         Map failoverData = (Map)get(FAILED_OVER_FOR_KEY);
+         FailoverStatus status = (FailoverStatus)failoverData.get(new Integer(currentNodeId));
 
-         FailoverStatus status = (FailoverStatus)replicants.get(new Integer(currentNodeId));
-
          if (status == null)
          {
             status = new FailoverStatus();
          }
 
-         status.startFailingOverForNode(failedNodeId);
+         status.startFailingOverForNode(failedNodeID);
 
-         log.info("Putting state that failover is starting");
+         log.debug(this + " announcing the cluster it is starting failover procedure");
 
          put(FAILED_OVER_FOR_KEY, status);
 
-         log.info("Put state that failover is starting");
+         log.debug(this + " announced the cluster it is starting failover procedure");
 
-         //Get the map of queues for the failed node
+         // Get the map of queues for the failed node
 
-         Map subMaps = (Map)nameMaps.get(new Integer(failedNodeId));
-         if (subMaps==null || subMaps.size()==0)
+         Map subMaps = (Map)nameMaps.get(failedNodeID);
+
+         if (subMaps == null || subMaps.size() == 0)
          {
-            log.warn("Couldn't find any binding to failOver from serverId=" +failedNodeId);
-            return;
+            log.warn(this + " couldn't find any binding to fail over from server " + failedNodeID);
          }
-
-         //Compile a list of the queue names to remove
-         //Note that any non durable bindings will already have been removed (in removeDataForNode()) when the
-         //node leave was detected, so if there are any non durable bindings left here then
-         //this is an error
-
-         //We iterate through twice to avoid ConcurrentModificationException
-         ArrayList namesToRemove = new ArrayList();
-         for (Iterator iterNames = subMaps.entrySet().iterator(); iterNames.hasNext();)
+         else
          {
-            Map.Entry entry = (Map.Entry)iterNames.next();
+            // Compile a list of the queue names to remove.
+            // Note that any non durable bindings will already have been removed (in
+            // removeDataForNode()) when the node leave was detected, so if there are any non durable
+            // bindings left here then this is an error.
 
-            Binding binding = (Binding )entry.getValue();
+            // We iterate through twice to avoid ConcurrentModificationException
 
-            //Sanity check
-            if (!binding.getQueue().isRecoverable())
-            {
-               throw new IllegalStateException("Find non recoverable queue in map, these should have been removed!");
-            }
+            ArrayList namesToRemove = new ArrayList();
 
-            //Sanity check
-            if (!binding.getQueue().isClustered())
+            for (Iterator i = subMaps.entrySet().iterator(); i.hasNext();)
             {
-               throw new IllegalStateException("Queue is not clustered!: " + binding.getQueue().getName());
-            }
+               Map.Entry entry = (Map.Entry)i.next();
+               Binding binding = (Binding )entry.getValue();
 
-            ClusteredQueue queue = (ClusteredQueue) binding.getQueue();
+               // Sanity check
+               if (!binding.getQueue().isRecoverable())
+               {
+                  throw new IllegalStateException("Found non recoverable queue in map, " +
+                     "these should have been removed!");
+               }
 
-            //Sanity check
-            if (queue.isLocal())
-            {
-               throw new IllegalStateException("Queue is local!: " + binding.getQueue().getName());
-            }
-            namesToRemove.add(entry);
-         }
+               // Sanity check
+               if (!binding.getQueue().isClustered())
+               {
+                  throw new IllegalStateException("Queue " + binding.getQueue().getName() +
+                     " is not clustered!");
+               }
 
-         log.info("Deleting " + namesToRemove.size() + " bindings from old node");
+               ClusteredQueue queue = (ClusteredQueue)binding.getQueue();
 
-         for (Iterator iterNames = namesToRemove.iterator(); iterNames.hasNext();)
-         {
-            Map.Entry entry = (Map.Entry)iterNames.next();
+               // Sanity check
+               if (queue.isLocal())
+               {
+                  throw new IllegalStateException("Queue " + binding.getQueue().getName() +
+                     " is local!");
+               }
 
-            Binding binding = (Binding)entry.getValue();
+               namesToRemove.add(entry);
+            }
 
-            RemoteQueueStub stub = (RemoteQueueStub)binding.getQueue();
+            if (trace) { log.trace("deleting " + namesToRemove.size() + " bindings from old node"); }
 
-            String queueName = (String)entry.getKey();
+            for (Iterator i = namesToRemove.iterator(); i.hasNext(); )
+            {
+               Map.Entry entry = (Map.Entry)i.next();
+               Binding binding = (Binding)entry.getValue();
+               RemoteQueueStub stub = (RemoteQueueStub)binding.getQueue();
+               String queueName = (String)entry.getKey();
 
-            //First the binding is removed from the in memory condition and name maps
-            this.removeBinding(failedNodeId, queueName);
+               // First the binding is removed from the in memory condition and name maps ...
+               removeBinding(failedNodeID.intValue(), queueName);
 
-            //Then deleted from the database
-            this.deleteBinding(failedNodeId, queueName);
+               // ... then deleted from the database
+               deleteBinding(failedNodeID.intValue(), queueName);
 
-            log.info("deleted binding for " + queueName);
+               log.debug(this + " deleted binding for " + queueName);
 
-            //Note we do not need to send an unbind request across the cluster - this is because
-            //when the node crashes a view change will hit the other nodes and that will cause
-            //all binding data for that node to be removed anyway
+               // Note we do not need to send an unbind request across the cluster - this is because
+               // when the node crashes a view change will hit the other nodes and that will cause all
+               // binding data for that node to be removed anyway.
 
-            //If there is already a queue registered with the same name, then we set a flag "failed" on the
-            //binding and then the queue will go into a special list of failed bindings
-            //otherwise we treat at as a normal queue
-            //This is because we cannot deal with more than one queue with the same name
-            //Any new consumers will always only connect to queues in the main name map
-            //This may mean that queues in the failed map have messages stranded in them if consumers
-            //disconnect (since no more can reconnect)
-            //However we message redistribution activated other queues will be able to consume from them.
-            //TODO allow message redistribution for queues in the failed list
-            boolean failed = this.internalGetBindingForQueueName(queueName) != null;
+               // If there is already a queue registered with the same name, then we set a flag
+               // "failed" on the binding and then the queue will go into a special list of failed
+               // bindings otherwise we treat at as a normal queue.
+               // This is because we cannot deal with more than one queue with the same name. Any new
+               // consumers will always only connect to queues in the main name map. This may mean that
+               // queues in the failed map have messages stranded in them if consumers disconnect
+               // (since no more can reconnect). However we message redistribution activated other
+               // queues will be able to consume from them.
 
-            if (!failed)
-            {
-               log.info("The current node didn't have a queue " + queueName + " so it's assuming the queue as a regular queue");
-            }
-            else
-            {
-               log.info("There is already a queue with that name so adding to failed map");
-            }
+               //TODO allow message redistribution for queues in the failed list
 
-            //Create a new binding
-            Binding newBinding = this.createBinding(this.currentNodeId, binding.getCondition(),
-                                                    stub.getName(), stub.getChannelID(),
-                                                    stub.getFilter(), stub.isRecoverable(), failed);
+               boolean failed = internalGetBindingForQueueName(queueName) != null;
 
-            log.info("Created new binding");
+               if (!failed)
+               {
+                  log.debug(this + " did not have a " + queueName +
+                     " queue so it's assuming it as a regular queue");
+               }
+               else
+               {
+                  log.info(this + " has already a " + queueName + " queue so adding to failed map");
+               }
 
-            //Insert it into the database
-            insertBinding(newBinding);
+               // Create a new binding
+               Binding newBinding = createBinding(currentNodeId, binding.getCondition(),
+                                                  stub.getName(), stub.getChannelID(),
+                                                  stub.getFilter(), stub.isRecoverable(), failed);
 
-            LocalClusteredQueue clusteredQueue = (LocalClusteredQueue )newBinding.getQueue();
+               // Insert it into the database
+               insertBinding(newBinding);
 
-            clusteredQueue.deactivate();
-            clusteredQueue.load();
-            clusteredQueue.activate();
+               LocalClusteredQueue clusteredQueue = (LocalClusteredQueue)newBinding.getQueue();
 
-            log.info("Loaded queue");
+               clusteredQueue.deactivate();
+               clusteredQueue.load();
+               clusteredQueue.activate();
 
-            //Add the new binding in memory
-            addBinding(newBinding);
+               log.debug(this + " loaded " + clusteredQueue);
 
-            //Send a bind request so other nodes add it too
-            sendBindRequest(binding.getCondition(), clusteredQueue,newBinding);
+               // Add the new binding in memory
+               addBinding(newBinding);
 
-            //FIXME there is a problem in the above code.
-            //If the server crashes between deleting the binding from the database
-            //and creating the new binding in the database, then the binding will be completely
-            //lost from the database when the server is resurrected.
-            //To remedy, both db operations need to be done in the same JBDC tx
+               // Send a bind request so other nodes add it too
+               sendBindRequest(binding.getCondition(), clusteredQueue,newBinding);
+
+               //FIXME there is a problem in the above code.
+               //If the server crashes between deleting the binding from the database
+               //and creating the new binding in the database, then the binding will be completely
+               //lost from the database when the server is resurrected.
+               //To remedy, both db operations need to be done in the same JBDC tx
+            }
          }
 
-         log.info("Server side fail over is now complete");
+         log.info(this + ": server side fail over is now complete");
 
          //TODO - should this be in a finally? I'm not sure
          status.finishFailingOver();
 
-         log.info("Putting state that failover has completed");
+         log.debug(this + " announcing the cluster that failover procedure is complete");
+
          put(FAILED_OVER_FOR_KEY, status);
-         log.info("Put state that failover has completed");
+
+         log.debug(this + " announced the cluster that failover procedure is complete");
+
+         sendJMXNotification(FAILOVER_COMPLETED_NOTIFICATION);
       }
       finally
       {
@@ -2369,34 +2276,38 @@
    {
       Notification n = new Notification(notificationType, "", 0l);
       nbSupport.sendNotification(n);
+      log.debug(this + " sent " + notificationType + " JMX notification");
    }
 
-   private void handleViewAccepted(View newView)
+   private String dumpClusterMap(Map map)
    {
-      //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
-      //TODO:     can't we do the same since this is pretty useful?
-      log.info(currentNodeId  + " got new view: " + newView + " postOffice:"
-               + DefaultClusteredPostOffice.this.getOfficeName());
+      StringBuffer sb = new StringBuffer("\n");
 
-      // JGroups will make sure this method is never called by more than one thread concurrently
+      for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
+      {
+         Map.Entry entry = (Map.Entry)i.next();
+         Integer nodeID = (Integer)entry.getKey();
+         PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
+         sb.append("             ").append("nodeID ").append(nodeID).append(" - ").append(info).append("\n");
+      }
+      return sb.toString();
+   }
 
-      View oldView = currentView;
-      currentView = newView;
+   private String dumpFailoverMap(Map map)
+   {
+      StringBuffer sb = new StringBuffer("\n");
 
-      try
+      for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
       {
-         verifyMembership(oldView, newView);
-         sendJMXNotification(VIEW_CHANGED_NOTIFICATION);
+         Map.Entry entry = (Map.Entry)i.next();
+         Integer primary = (Integer)entry.getKey();
+         Integer secondary = (Integer)entry.getValue();
+         sb.append("             ").append(primary).append("->").append(secondary).append("\n");
       }
-      catch (Throwable e)
-      {
-         log.error("Caught Exception in MembershipListener", e);
-         IllegalStateException e2 = new IllegalStateException(e.getMessage());
-         e2.setStackTrace(e.getStackTrace());
-         throw e2;
-      }
+      return sb.toString();
    }
 
+
    // Inner classes -------------------------------------------------------------------
 
    /*
@@ -2416,8 +2327,7 @@
          }
          try
          {
-            // TODO: Make it trace
-            log.info("getState:" + DefaultClusteredPostOffice.this.getOfficeName());
+            if (trace) { log.trace(this + " got state"); }
             return getStateAsBytes();
          }
          catch (Exception e)
@@ -2451,9 +2361,8 @@
             }
             try
             {
-               // TODO: Make it trace
-               log.info("setState:" + DefaultClusteredPostOffice.this.getOfficeName());
                processStateBytes(bytes);
+               if (trace) { log.trace(this + " has set state"); }
             }
             catch (Exception e)
             {
@@ -2526,7 +2435,50 @@
 
       public void run()
       {
-         handleViewAccepted(newView);
+         //TODO: (by Clebert) Most JBoss Services use info on viewAccepted,
+         //TODO:     can't we do the same since this is pretty useful?
+         log.info(DefaultClusteredPostOffice.this  + " got new view: " + newView);
+
+         // JGroups will make sure this method is never called by more than one thread concurrently
+
+         View oldView = currentView;
+         currentView = newView;
+
+         try
+         {
+            // Act on membership change, on both cases when an old member left or a new member joined
+
+            if (oldView != null)
+            {
+               for (Iterator i = oldView.getMembers().iterator(); i.hasNext(); )
+               {
+                  Address address = (Address)i.next();
+                  if (!newView.containsMember(address))
+                  {
+                     // this is where the failover happens, if necessary
+                     nodeLeft(address);
+                  }
+               }
+            }
+
+            for (Iterator i = newView.getMembers().iterator(); i.hasNext(); )
+            {
+               Address address = (Address)i.next();
+               if (oldView == null || !oldView.containsMember(address))
+               {
+                  nodeJoined(address);
+               }
+            }
+
+            sendJMXNotification(VIEW_CHANGED_NOTIFICATION);
+         }
+         catch (Throwable e)
+         {
+            log.error("Caught Exception in MembershipListener", e);
+            IllegalStateException e2 = new IllegalStateException(e.getMessage());
+            e2.setStackTrace(e.getStackTrace());
+            throw e2;
+         }
       }
    }
 
@@ -2558,14 +2510,13 @@
 
       public void receive(Message message)
       {
-         if (trace) { log.trace(currentNodeId + " received message " + message + " on async channel"); }
+         if (trace) { log.trace(this + " received " + message + " on the ASYNC channel"); }
 
          try
          {
             byte[] bytes = message.getBuffer();
 
             ClusterRequest request = readRequest(bytes);
-
             request.execute(DefaultClusteredPostOffice.this);
          }
          catch (Throwable e)
@@ -2590,7 +2541,8 @@
    {
       public Object handle(Message message)
       {
-         if (trace) { log.info(currentNodeId + " received message " + message + " on sync channel"); }
+         if (trace) { log.trace(DefaultClusteredPostOffice.this + ".RequestHandler received " + message + " on the SYNC channel"); }
+
          try
          {
             byte[] bytes = message.getBuffer();
@@ -2611,37 +2563,23 @@
 
    /*
     * We use this class to respond to node address mappings being added or removed from the cluster
-    * and then recalculate the node->failover node mapping
-    *
+    * and then recalculate the node->failover node mapping.
     */
    private class NodeAddressMapListener implements ReplicationListener
    {
-
-      public void onReplicationChange(Serializable key, Map updatedReplicantMap, boolean added,
-                                      int originatorNodeId)
+      public void onReplicationChange(Serializable key, Map updatedReplicantMap,
+                                      boolean added, int originatorNodeId)
       {
          if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
          {
-            log.info(currentNodeId + " got node address change");
+            log.debug("Cluster map:\n" + dumpClusterMap(updatedReplicantMap));
 
-            try
-            {
-               //DEBUG only
-               dumpNodeIdAddressMap(updatedReplicantMap);
-            }
-            catch (Exception ignore)
-            {
-            }
+            // A node-address mapping has been added/removed from global state, we need to update
+            // the failover map.
+            failoverMap = failoverMapper.generateMapping(updatedReplicantMap.keySet());
 
-            //A node-address mapping has been added/removed from global state-
-            //We need to update the failover map
-            generateFailoverMap(updatedReplicantMap);
+            log.debug("Failover map:\n" + dumpFailoverMap(failoverMap));
          }
       }
-
-      private void generateFailoverMap(Map nodeAddressMap)
-      {
-         failoverMap = failoverMapper.generateMapping(nodeAddressMap.keySet());
-      }      
    }
 }
\ No newline at end of file

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultFailoverMapper.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -45,22 +45,21 @@
 {
    private static final Logger log = Logger.getLogger(DefaultFailoverMapper.class);
 
-   /*
-    * Generate a mapping given a set of nodes - nodes will be sorted by the method
+   /**
+    * Generate a mapping given a set of nodes - nodes will be sorted by the method.
+    *
     * @see org.jboss.messaging.core.plugin.contract.FailoverMapper#generateMapping(java.util.Set)
     */
    public Map generateMapping(Set nodes)
    {
       Integer[] nodesArr = (Integer[])nodes.toArray(new Integer[nodes.size()]);
       
-      //First sort them so every node has a consistent view
+      // First sort them so every node has a consistent view
       Arrays.sort(nodesArr);
       
       int s = nodes.size();
       
-      log.info("Generating failover mapping, node size= "+ s);
-
-      //There is no need for the map to be linked
+      // There is no need for the map to be linked
       Map failoverNodes = new HashMap(s);
       
       for (int i = 0; i < s; i++)
@@ -74,7 +73,7 @@
          
          failoverNodes.put(nodesArr[i], nodesArr[j]);
       }
-      
+
       return failoverNodes;
    }
 

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/FailoverStatus.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -24,7 +24,6 @@
 import java.io.Serializable;
 import java.util.Collections;
 import java.util.LinkedHashSet;
-import java.util.List;
 import java.util.Set;
 
 /**
@@ -40,59 +39,81 @@
  */
 public class FailoverStatus implements Serializable
 {
+   // Constants -----------------------------------------------------
+
    private static final long serialVersionUID = -2668162690753929133L;
 
-   //The set of nodes the server has completed failover for since it was last restarted
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // The set of nodes the server has completed failover for since it was last restarted
    private Set failedOverForNodes;
-   
-   //The node the server is currently failing over for (if any)
+
+   // The node the server is currently failing over for (if any)
    private int currentlyFailingOverForNode;
-   
-   //Is the server currently failing over?
+
+   // Is the server currently failing over?
    private boolean failingOver;
-   
+
+   // Constructors --------------------------------------------------
+
    public FailoverStatus()
-   {      
+   {
       failedOverForNodes = new LinkedHashSet();
    }
-   
-   public void startFailingOverForNode(int nodeId)
+
+   // Public --------------------------------------------------------
+
+   public void startFailingOverForNode(Integer nodeID)
    {
       if (failingOver)
       {
          throw new IllegalStateException("Already failing over for node " + currentlyFailingOverForNode);
       }
-      
-      currentlyFailingOverForNode = nodeId;
-      
+
+      currentlyFailingOverForNode = nodeID.intValue();
       failingOver = true;
    }
-   
+
    public void finishFailingOver()
    {
       if (!failingOver)
       {
          throw new IllegalStateException("The node is not currently failing over");
       }
-      
+
       failedOverForNodes.add(new Integer(currentlyFailingOverForNode));
-      
+
       failingOver = false;
    }
-   
+
    public Set getFailedOverForNodes()
    {
       return Collections.unmodifiableSet(failedOverForNodes);
    }
-   
+
    public boolean isFailedOverForNode(int nodeId)
    {
       return failedOverForNodes.contains(new Integer(nodeId));
    }
-   
+
    public boolean isFailingOverForNode(int nodeId)
    {
       return failingOver && currentlyFailingOverForNode == nodeId;
    }
-   
+
+   public String toString()
+   {
+      return "FailoverStatus[" + currentlyFailingOverForNode + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: trunk/tests/bin/runtest
===================================================================
--- trunk/tests/bin/runtest	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/tests/bin/runtest	2006-12-13 05:30:32 UTC (rev 1780)
@@ -48,8 +48,6 @@
    TEST_REMOTING=$ENV_TEST_REMOTING
 fi
 
-TEST_REMOTING=http
-
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get
 # it from there.

Modified: trunk/tests/etc/log4j.xml
===================================================================
--- trunk/tests/etc/log4j.xml	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/tests/etc/log4j.xml	2006-12-13 05:30:32 UTC (rev 1780)
@@ -19,7 +19,7 @@
       <param name="Append" value="true"/>
 
       <layout class="org.apache.log4j.PatternLayout">
-         <param name="ConversionPattern" value="%d %-5r %-5p [%c] @%t %m%n"/>
+         <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p @%t [%c{1}] %m%n"/>
       </layout>
    </appender>
 
@@ -27,8 +27,9 @@
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
       <param name="Target" value="System.out"/>
       <param name="Threshold" value="INFO"/>
+      <!-- <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/> -->
       <layout class="org.apache.log4j.PatternLayout">
-         <param name="ConversionPattern" value="%t %d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
+         <param name="ConversionPattern" value="@%t %d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
       </layout>
    </appender>
 
@@ -37,7 +38,7 @@
    </category>
 
    <category name="org.jgroups">
-      <priority value="TRACE"/>
+      <priority value="WARN"/>
    </category>
 
    <category name="org.jboss.remoting">
@@ -66,6 +67,10 @@
       <priority value="DEBUG"/>
    </category>
 
+   <category name="org.jboss.messaging.core.plugin.JDBCSupport">
+      <priority value="INFO"/>
+   </category>
+
    <category name="org.jboss.test.messaging.tools.jmx.MockJBossSecurityManager">
       <priority value="DEBUG"/>
    </category>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -59,7 +59,7 @@
 
    public void testJoinNotification() throws Exception
    {
-      ViewChangeNotificationListener listener = new ViewChangeNotificationListener();
+      ClusterEventNotificationListener listener = new ClusterEventNotificationListener();
       ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
 
       try
@@ -257,7 +257,7 @@
 
    public void testDirtyLeaveOneNode() throws Exception
    {
-      ViewChangeNotificationListener viewChange = new ViewChangeNotificationListener();
+      ClusterEventNotificationListener clusterEvent = new ClusterEventNotificationListener();
       ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
 
       try
@@ -273,7 +273,7 @@
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
 
-         ServerManagement.addNotificationListener(0, postOfficeObjectName, viewChange);
+         ServerManagement.addNotificationListener(0, postOfficeObjectName, clusterEvent);
 
          // Make node 1 to "dirty" leave the cluster, by killing the VM running it.
 
@@ -285,7 +285,7 @@
 
          // Wait for membership change notification
 
-         if (!viewChange.viewChanged(120000))
+         if (!clusterEvent.viewChanged(120000))
          {
             fail("Did not receive view change after killing server 2!");
          }
@@ -297,7 +297,7 @@
       }
       finally
       {
-         ServerManagement.removeNotificationListener(0, postOfficeObjectName, viewChange);
+         ServerManagement.removeNotificationListener(0, postOfficeObjectName, clusterEvent);
 
          ServerManagement.stop(1);
          ServerManagement.stop(0);
@@ -306,7 +306,7 @@
 
    public void testDirtyLeaveTwoNodes() throws Exception
    {
-      ViewChangeNotificationListener viewChange = new ViewChangeNotificationListener();
+      ClusterEventNotificationListener clusterEvent = new ClusterEventNotificationListener();
       ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
 
       try
@@ -324,7 +324,7 @@
          assertTrue(view.contains(new Integer(1)));
          assertTrue(view.contains(new Integer(2)));
 
-         ServerManagement.addNotificationListener(0, postOfficeObjectName, viewChange);
+         ServerManagement.addNotificationListener(0, postOfficeObjectName, clusterEvent);
 
          // Make node 2 to "dirty" leave the cluster, by killing the VM running it.
 
@@ -334,13 +334,15 @@
          log.info("######## KILLED 2");
          log.info("########");
 
-         // Wait for membership change notification
+         // Wait for FAILOVER_COMPLETED notification
 
-         if (!viewChange.viewChanged(120000))
+         if (!clusterEvent.failoverCompleted(120000))
          {
-            fail("Did not receive view change after killing server 2!");
+            fail("Did not receive a FAILOVER_COMPLETED event after killing server 2!");
          }
 
+         log.info("received FAILOVER_COMPLETED");
+
          view = ServerManagement.getServer(1).getNodeIDView();
 
          assertEquals(2, view.size());
@@ -355,13 +357,15 @@
          log.info("######## KILLED 1");
          log.info("########");
 
-         // Wait for membership change notification
+         // Wait for FAILOVER_COMPLETED notification
 
-         if (!viewChange.viewChanged(120000))
+         if (!clusterEvent.failoverCompleted(120000))
          {
-            fail("Did not receive view change after killing server 1!");
+            fail("Did not receive a FAILOVER_COMPLETED event after killing server 1!");
          }
 
+         log.info("received FAILOVER_COMPLETED");
+
          view = ServerManagement.getServer(0).getNodeIDView();
 
          assertEquals(1, view.size());
@@ -370,7 +374,7 @@
       }
       finally
       {
-         ServerManagement.removeNotificationListener(0, postOfficeObjectName, viewChange);
+         ServerManagement.removeNotificationListener(0, postOfficeObjectName, clusterEvent);
 
          ServerManagement.stop(2);
          ServerManagement.stop(1);
@@ -398,45 +402,71 @@
 
    // Inner classes -------------------------------------------------
 
-   private class ViewChangeNotificationListener implements NotificationListener
+   private class ClusterEventNotificationListener implements NotificationListener
    {
-      private Slot slot;
+      private Slot viewChange;
+      private Slot failoverCompleted;
 
-      ViewChangeNotificationListener()
+      ClusterEventNotificationListener()
       {
-         slot = new Slot();
+         viewChange = new Slot();
+         failoverCompleted = new Slot();
       }
 
       public void handleNotification(Notification notification, Object object)
       {
+         String type = notification.getType();
 
-         if (!ClusteredPostOffice.VIEW_CHANGED_NOTIFICATION.equals(notification.getType()))
+         log.info("received " + type + " notification");
+
+         if (ClusteredPostOffice.VIEW_CHANGED_NOTIFICATION.equals(type))
          {
-            // ignore it
-            return;
+            try
+            {
+               viewChange.put(Boolean.TRUE);
+            }
+            catch(InterruptedException e)
+            {
+               log.error(e);
+            }
          }
-
-         log.info("received VIEW_CHANGED notification");
-
-         try
+         else if (ClusteredPostOffice.FAILOVER_COMPLETED_NOTIFICATION.equals(type))
          {
-            slot.put(Boolean.TRUE);
+            try
+            {
+               failoverCompleted.put(Boolean.TRUE);
+            }
+            catch(InterruptedException e)
+            {
+               log.error(e);
+            }
          }
-         catch(InterruptedException e)
+         else
          {
-            log.error(e);
+            log.info("Ignoring notification " + type);
          }
       }
 
       public boolean viewChanged(long timeout) throws InterruptedException
       {
-         Boolean result = (Boolean)slot.poll(timeout);
+         Boolean result = (Boolean)viewChange.poll(timeout);
          if (result == null)
          {
             return false;
          }
          return result.booleanValue();
       }
+
+      public boolean failoverCompleted(long timeout) throws InterruptedException
+      {
+         Boolean result = (Boolean)failoverCompleted.poll(timeout);
+         if (result == null)
+         {
+            return false;
+         }
+         return result.booleanValue();
+      }
+
    }
 
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -136,7 +136,7 @@
 
          startServerPeer(serverIndex, null, null, sc.isClustered());
 
-         log.info("server started");
+         log.info("Server " + serverIndex + " started");
       }
       finally
       {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-13 02:01:42 UTC (rev 1779)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-13 05:30:32 UTC (rev 1780)
@@ -56,7 +56,7 @@
    public static final String RMI_SERVER_PREFIX = "messaging_rmi_server_";
    public static final String NAMING_SERVER_PREFIX = "naming_rmi_server_";
 
-   public static final int DEFAULT_REGISTRY_PORT = 22555;
+   public static final int DEFAULT_REGISTRY_PORT = 33777;
    public static final int DEFAULT_SERVER_INDEX = 0;
    public static final String DEFAULT_SERVER_HOST = "localhost";
 



From forge-admin at jboss.com  Wed Dec 13 01:00:29 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Wed, 13 Dec 2006 01:00:29 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GuNAL-0006ZS-Nw@committer01.frg.pub.inap.atl.jboss.com>

Commit from jgreene (2006-12-12 02:12 EST)
-------------------

sync snapshot

  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar                1.29
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar                 1.28
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar                  1.29
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar              1.40
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar   1.2
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-src.zip                 1.2
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar  1.2
+ repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.deployer                1.1
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar                     1.40
  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml                  1.34


Commit from jgreene (2006-12-12 02:41 EST)
-------------------

sync snapshot

  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml  1.35


Commit from myuan (2006-12-12 02:42 EST)
-----------------

simplify the components.xml files

  jboss-seam  examples/hibernate2/resources/components.xml            1.2
  jboss-seam  examples/hibernate2/resources/glassfish/components.xml  1.2
  jboss-seam  examples/hibernate2/resources/tomcat/components.xml     1.4
  jboss-seam  examples/hibernate2/resources/weblogic/components.xml   1.2


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 03:28 EST)
----------------------------------------------------

Corrected some bugs.

  jboss-profiler  java/webapp/lzx/treegrid.lzx                1.1.2.2
  jboss-profiler  java/webapp/lzx/settingdialog.lzx           1.1.2.4
  jboss-profiler  java/webapp/lzx/webapplicationanalyzer.lzx  1.1.2.2


Commit from dimitris (2006-12-12 03:37 EST)
--------------------

Mark compatible with jboss-retro-rt 1.0.4.GA

  repository.jboss.com  jboss/jbossws14/1.0.4.GA/component-info.xml  1.3


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 04:02 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  java/mbean/collector-config.xml  1.1.2.2


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 04:06 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  java/webapp/WEB-INF/web.xml  1.1.2.3


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 04:17 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  exsamples/jboss-profiler.aop/META-INF/jboss-aop.xml           1.1.2.4
  jboss-profiler  exsamples/jboss-aop-jdk5.deployer/META-INF/jboss-service.xml  1.1.2.2
  jboss-profiler  exsamples/jboss-profiler-test.war/WEB-INF/web.xml             1.1.2.4
  jboss-profiler  exsamples/mysql-ds.xml                                        1.1.2.4


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 04:23 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  java/mbean/jboss-service.xml  1.3.2.4


Commit from tokada on branch JBossProfiler_Expansion (2006-12-12 04:28 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  build.xml  1.37.2.4


Commit from tdiesler (2006-12-12 07:34 EST)
--------------------

URL: https://svn.jboss.org/repos/jbossws/trunk
Repository Root: https://svn.jboss.org/repos/jbossws
Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
Revision: 1630
Node Kind: directory
Schedule: normal
Last Changed Author: thomas.diesler at jboss.com
Last Changed Rev: 1630
Last Changed Date: 2006-12-12 13:23:36 +0100 (Tue, 12 Dec 2006)

  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml                  1.36
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar                1.30
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar                 1.29
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar                  1.30
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar              1.41
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar   1.3
- repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-src.zip                 1.3
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar  1.3
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.deployer                1.2
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar                     1.41


Commit from tdiesler (2006-12-12 07:52 EST)
--------------------

add jbossws.deployer

  repository.jboss.com  jboss/jbossws/snapshot/component-info.xml  1.37


Commit from telrod on branch remoting_2_x (2006-12-12 09:41 EST)
-----------------------------------------

JBREM-648 - fix for NPE on connection validator after client disconnect.

  JBossRemoting  src/main/org/jboss/remoting/ConnectionValidator.java  1.13.2.2


Commit from telrod (2006-12-12 09:49 EST)
------------------

JBREM-648 - fixe NPE for connection validator when client disconnects.

  JBossRemoting  src/main/org/jboss/remoting/ConnectionValidator.java  1.15


Commit from msurtani (2006-12-12 09:51 EST)
--------------------

JBCACHE-894

  JBossCache  src/org/jboss/cache/interceptors/InvocationContextInterceptor.java            1.11
  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java          1.46
  JBossCache  src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java  1.32
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java               1.35
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java              1.36
  JBossCache  src/org/jboss/cache/interceptors/OptimisticReplicationInterceptor.java        1.32
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNode.java                             1.16
  JBossCache  src/org/jboss/cache/optimistic/TransactionWorkspaceImpl.java                  1.15
  JBossCache  src/org/jboss/cache/optimistic/TransactionWorkspace.java                      1.12
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                         1.30
  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java                        1.6
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java            1.8
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java        1.5


Commit from msurtani (2006-12-12 10:08 EST)
--------------------

Cleaned up some stuff around resetting bypassInterceptorChain option

  JBossCache  src/org/jboss/cache/interceptors/InvocationContextInterceptor.java  1.12
  JBossCache  src/org/jboss/cache/NodeImpl.java                                   1.24


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-12 11:45 EST)
------------------------------------------------------

wc

  JBossCache  tests/functional/org/jboss/cache/aop/statetransfer/StateTransferAopTestBase.java  1.15.2.1


Commit from nrichards (2006-12-12 17:38 EST)
---------------------

JBSEAM-574: enum support

  jboss-seam  src/ui/META-INF/faces-config.xml                  1.24
  jboss-seam  src/ui/META-INF/seam.taglib.xml                   1.20
  jboss-seam  src/ui/META-INF/taglib.tld                        1.24
+ jboss-seam  src/ui/org/jboss/seam/ui/EnumConverter.java       1.1
+ jboss-seam  src/ui/org/jboss/seam/ui/EnumItem.java            1.1
  jboss-seam  src/ui/org/jboss/seam/ui/SelectDate.java          1.2
+ jboss-seam  src/ui/org/jboss/seam/ui/tag/ConvertEnumTag.java  1.1
+ jboss-seam  src/ui/org/jboss/seam/ui/tag/EnumItemTag.java     1.1
  jboss-seam  src/ui/org/jboss/seam/ui/tag/SelectDateTag.java   1.2


Commit from nrichards (2006-12-12 18:25 EST)
---------------------

use new enum support

  jboss-seam  examples/seampay/resources/WEB-INF/faces-config.xml                     1.5
  jboss-seam  examples/seampay/resources/WEB-INF/web.xml                              1.3
- jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/EnumConverter.java  1.2
  jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/Payment.java        1.4
  jboss-seam  examples/seampay/view/search.xhtml                                      1.8


Commit from sbryzak2 (2006-12-12 18:33 EST)
--------------------

added @Install(false)

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java  1.23


Commit from sbryzak2 (2006-12-12 20:52 EST)
--------------------

simplified security config

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java              1.24
  jboss-seam  src/test/misc/org/jboss/seam/test/SecurityTest.java                    1.11
+ jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java     1.1
- jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfig.java            1.8
- jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfigFileLoader.java  1.6
- jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfigLoader.java      1.4


Commit from nrichards (2006-12-12 21:52 EST)
---------------------

add enum tags

  jboss-seam  doc/reference/en/modules/controls.xml  1.11


Commit from sbryzak2 (2006-12-12 21:58 EST)
--------------------

JBSEAM-582

  jboss-seam  build.xml  1.120


Commit from gavin (2006-12-12 23:54 EST)
-----------------

maintain referential integrity for entity beans in conversation context

  jboss-seam  src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java  1.15
  jboss-seam  src/main/org/jboss/seam/contexts/WebSessionContext.java                     1.27
  jboss-seam  src/main/org/jboss/seam/contexts/ServerConversationContext.java             1.18
  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java                             1.70
  jboss-seam  src/main/org/jboss/seam/Component.java                                      1.218
  jboss-seam  src/main/org/jboss/seam/Seam.java                                           1.26
+ jboss-seam  src/main/org/jboss/seam/contexts/EntityBean.java                            1.1
+ jboss-seam  src/main/org/jboss/seam/contexts/PassivatedEntity.java                      1.1


Commit from gavin (2006-12-12 23:59 EST)
-----------------

minor

  jboss-seam  src/main/org/jboss/seam/interceptors/SecurityInterceptor.java  1.14


Commit from sbryzak2 (2006-12-13 00:08 EST)
--------------------

added security manager dependencies

  jboss-seam  src/main/org/jboss/seam/security/Identity.java                      1.3
  jboss-seam  src/main/org/jboss/seam/security/authenticator/Authenticator.java   1.16
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java  1.2


Commit from gavin (2006-12-13 00:14 EST)
-----------------

oops

  jboss-seam  src/main/org/jboss/seam/contexts/EntityBean.java  1.2


Commit from gavin (2006-12-13 00:19 EST)
-----------------

precedence

  jboss-seam  src/main/org/jboss/seam/security/Identity.java  1.4
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061213/db659232/attachment.html 

From michael.yuan at jboss.com  Wed Dec 13 01:10:54 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 13 Dec 2006 01:10:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/view  ...
Message-ID: <E1GuNKQ-0006vI-Fm@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/13 01:10:54

  Modified:    examples/jpa/view  template.xhtml
  Log:
  css support for the s:selectDate tag
  
  Revision  Changes    Path
  1.4       +1 -0      jboss-seam/examples/jpa/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/view/template.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- template.xhtml	23 Nov 2006 22:50:39 -0000	1.3
  +++ template.xhtml	13 Dec 2006 06:10:54 -0000	1.4
  @@ -6,6 +6,7 @@
   	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
   	<title>JBoss Suites: Seam Framework</title>
   	<link href="css/screen.css" rel="stylesheet" type="text/css" />
  +        <link href="css/date.css" rel="stylesheet" type="text/css" />
   </head>
   <body>
   
  
  
  


From michael.yuan at jboss.com  Wed Dec 13 01:10:54 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 13 Dec 2006 01:10:54 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/view/css   ...
Message-ID: <E1GuNKQ-0006vS-J3@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/13 01:10:54

  Modified:    examples/jpa/view/css   screen.css
  Added:       examples/jpa/view/css   date.css
  Log:
  css support for the s:selectDate tag
  
  Revision  Changes    Path
  1.3       +0 -128    jboss-seam/examples/jpa/view/css/screen.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: screen.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/jpa/view/css/screen.css,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- screen.css	14 Nov 2006 05:51:00 -0000	1.2
  +++ screen.css	13 Dec 2006 06:10:54 -0000	1.3
  @@ -263,131 +263,3 @@
   #pgHome input[type="submit"] {
   	height: 30px;
   }
  -/* Date Picker 
  ------------------------------------------------ */
  -body {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: .8em;
  -	}
  -
  -/* the div that holds the date picker calendar */
  -.dpDiv {
  -	}
  -
  -
  -/* the table (within the div) that holds the date picker calendar */
  -.dpTable {
  -	font-family: Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 12px;
  -	text-align: center;
  -	color: #505050;
  -	background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
  -	background-color: #FFFFFF;
  -	border: 1px solid #AAAAAA;
  -	margin-top: 5px;
  -	}
  -
  -
  -/* a table row that holds date numbers (either blank or 1-31) */
  -.dpTR {
  -	}
  -
  -
  -/* the top table row that holds the month, year, and forward/backward buttons */
  -.dpTitleTR {
  -	}
  -
  -
  -/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTR {
  -	}
  -
  -
  -/* the bottom table row, that has the "This Month" and "Close" buttons */
  -.dpTodayButtonTR {
  -	}
  -
  -
  -/* a table cell that holds a date number (either blank or 1-31) */
  -.dpTD {
  -	border: 1px solid #ece9d8;
  -	}
  -
  -
  -/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  -.dpDayHighlightTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  -.dpTDHover {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	cursor: pointer;
  -	color: red;
  -	font-weight: bold;
  -	}
  -
  -
  -/* the table cell that holds the name of the month and the year */
  -.dpTitleTD {
  -	}
  -
  -
  -/* a table cell that holds one of the forward/backward buttons */
  -.dpButtonTD {
  -	}
  -
  -
  -/* the table cell that holds the "This Month" or "Close" button at the bottom */
  -.dpTodayButtonTD {
  -	}
  -
  -
  -/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	color: white;
  -	}
  -
  -
  -/* additional style information for the text that indicates the month and year */
  -.dpTitleText {
  -	font-size: 12px;
  -	color: gray;
  -	font-weight: bold;
  -	}
  -
  -
  -/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  -.dpDayHighlight {
  -	color: CCCCCC;
  -	font-weight: bold;
  -	}
  -
  -
  -/* the forward/backward buttons at the top */
  -.dpButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	padding: 0px;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the "This Month" and "Close" buttons at the bottom */
  -.dpTodayButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	border: 1px solid #AAAAAA;
  -	display:none;
  -	}
  
  
  
  1.1      date: 2006/12/13 06:10:54;  author: myuan;  state: Exp;jboss-seam/examples/jpa/view/css/date.css
  
  Index: date.css
  ===================================================================
  /* Seam Date Picker */
  
  /* the div that holds the date picker calendar */
  .seam-date {
  
  }
  
  
  /* the table (within the div) that holds the date picker calendar */
  .seam-date table {
      font-family: Tahoma, Arial, Helvetica, sans-serif;
      font-size: 12px;
      text-align: center;
      color: #505050;
      background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
      background-color: #FFFFFF;
      border: 1px solid #AAAAAA;
      margin-top: 5px;
  }
  
  
  .seam-date-title div {
      font-size: 12px;
      color: gray;
      font-weight: bold;
  }
  
  
  /* the forward/backward buttons at the top */
  .seam-date-title button{
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      padding: 0px;
      border: 1px solid #AAAAAA;
  }
  
  
  /* the "This Month" and "Close" buttons at the bottom */
  .seam-date-footer {
  	display: none;
  }
  
  .seam-date-footer button {
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      border: 1px solid #AAAAAA;
  }
  
  
  
  /* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  .seam-date-header td {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      color: white;
  }
  
  
  
  /* a table cell that holds a date number (either blank or 1-31) */
  .seam-date-week td.seam-date-day {
      border: 1px solid #ece9d8;	
  }
  
  /* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  .seam-date-week td.seam-date-hover  {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      cursor: pointer;
      color: red;
  }
  
  
  /* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  .seam-date-week td.seam-date-selected {
      background-color: #CCCCCC;        
      border: 1px solid #AAAAAA;
      font-weight: bold;
  }
  
  
  


From michael.yuan at jboss.com  Wed Dec 13 01:26:22 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 13 Dec 2006 01:26:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/view  ...
Message-ID: <E1GuNZO-00079x-PP@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/13 01:26:22

  Modified:    examples/hibernate2/view  template.xhtml
  Log:
  css update for s:selectDate
  
  Revision  Changes    Path
  1.4       +1 -0      jboss-seam/examples/hibernate2/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/view/template.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- template.xhtml	23 Nov 2006 22:50:39 -0000	1.3
  +++ template.xhtml	13 Dec 2006 06:26:22 -0000	1.4
  @@ -6,6 +6,7 @@
   	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
   	<title>JBoss Suites: Seam Framework</title>
   	<link href="css/screen.css" rel="stylesheet" type="text/css" />
  +	<link href="css/date.css" rel="stylesheet" type="text/css" />
   </head>
   <body>
   
  
  
  


From michael.yuan at jboss.com  Wed Dec 13 01:26:22 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 13 Dec 2006 01:26:22 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/view/css    ...
Message-ID: <E1GuNZO-0007AA-Th@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/13 01:26:22

  Modified:    examples/hibernate2/view/css    screen.css
  Added:       examples/hibernate2/view/css    date.css
                        trailblazer_main.css
  Log:
  css update for s:selectDate
  
  Revision  Changes    Path
  1.3       +0 -128    jboss-seam/examples/hibernate2/view/css/screen.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: screen.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/view/css/screen.css,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- screen.css	14 Nov 2006 05:51:00 -0000	1.2
  +++ screen.css	13 Dec 2006 06:26:22 -0000	1.3
  @@ -263,131 +263,3 @@
   #pgHome input[type="submit"] {
   	height: 30px;
   }
  -/* Date Picker 
  ------------------------------------------------ */
  -body {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: .8em;
  -	}
  -
  -/* the div that holds the date picker calendar */
  -.dpDiv {
  -	}
  -
  -
  -/* the table (within the div) that holds the date picker calendar */
  -.dpTable {
  -	font-family: Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 12px;
  -	text-align: center;
  -	color: #505050;
  -	background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
  -	background-color: #FFFFFF;
  -	border: 1px solid #AAAAAA;
  -	margin-top: 5px;
  -	}
  -
  -
  -/* a table row that holds date numbers (either blank or 1-31) */
  -.dpTR {
  -	}
  -
  -
  -/* the top table row that holds the month, year, and forward/backward buttons */
  -.dpTitleTR {
  -	}
  -
  -
  -/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTR {
  -	}
  -
  -
  -/* the bottom table row, that has the "This Month" and "Close" buttons */
  -.dpTodayButtonTR {
  -	}
  -
  -
  -/* a table cell that holds a date number (either blank or 1-31) */
  -.dpTD {
  -	border: 1px solid #ece9d8;
  -	}
  -
  -
  -/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  -.dpDayHighlightTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  -.dpTDHover {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	cursor: pointer;
  -	color: red;
  -	font-weight: bold;
  -	}
  -
  -
  -/* the table cell that holds the name of the month and the year */
  -.dpTitleTD {
  -	}
  -
  -
  -/* a table cell that holds one of the forward/backward buttons */
  -.dpButtonTD {
  -	}
  -
  -
  -/* the table cell that holds the "This Month" or "Close" button at the bottom */
  -.dpTodayButtonTD {
  -	}
  -
  -
  -/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	color: white;
  -	}
  -
  -
  -/* additional style information for the text that indicates the month and year */
  -.dpTitleText {
  -	font-size: 12px;
  -	color: gray;
  -	font-weight: bold;
  -	}
  -
  -
  -/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  -.dpDayHighlight {
  -	color: CCCCCC;
  -	font-weight: bold;
  -	}
  -
  -
  -/* the forward/backward buttons at the top */
  -.dpButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	padding: 0px;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the "This Month" and "Close" buttons at the bottom */
  -.dpTodayButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	border: 1px solid #AAAAAA;
  -	display:none;
  -	}
  
  
  
  1.1      date: 2006/12/13 06:26:22;  author: myuan;  state: Exp;jboss-seam/examples/hibernate2/view/css/date.css
  
  Index: date.css
  ===================================================================
  /* Seam Date Picker */
  
  /* the div that holds the date picker calendar */
  .seam-date {
  
  }
  
  
  /* the table (within the div) that holds the date picker calendar */
  .seam-date table {
      font-family: Tahoma, Arial, Helvetica, sans-serif;
      font-size: 12px;
      text-align: center;
      color: #505050;
      background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
      background-color: #FFFFFF;
      border: 1px solid #AAAAAA;
      margin-top: 5px;
  }
  
  
  .seam-date-title div {
      font-size: 12px;
      color: gray;
      font-weight: bold;
  }
  
  
  /* the forward/backward buttons at the top */
  .seam-date-title button{
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      padding: 0px;
      border: 1px solid #AAAAAA;
  }
  
  
  /* the "This Month" and "Close" buttons at the bottom */
  .seam-date-footer {
  	display: none;
  }
  
  .seam-date-footer button {
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      border: 1px solid #AAAAAA;
  }
  
  
  
  /* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  .seam-date-header td {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      color: white;
  }
  
  
  
  /* a table cell that holds a date number (either blank or 1-31) */
  .seam-date-week td.seam-date-day {
      border: 1px solid #ece9d8;	
  }
  
  /* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  .seam-date-week td.seam-date-hover  {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      cursor: pointer;
      color: red;
  }
  
  
  /* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  .seam-date-week td.seam-date-selected {
      background-color: #CCCCCC;        
      border: 1px solid #AAAAAA;
      font-weight: bold;
  }
  
  
  
  1.1      date: 2006/12/13 06:26:22;  author: myuan;  state: Exp;jboss-seam/examples/hibernate2/view/css/trailblazer_main.css
  
  Index: trailblazer_main.css
  ===================================================================
  * {
      margin:  0px; 
      padding: 0px; 
      border:  none;
  }
  
  body {
      font: 1em verdana, arial, sans-serif;
      background: #CCCCCC;
  }
  
  div#main {
      margin-left:  0px;
      width: 751px;
      background: #ecefdf;
  }
  
  div#top,div#pictures{
  }
  
  div#pictures img {
      float:left;
  }
  
  img#head1 {
      margin-right: 3px;
  } 
  
  img#head2 {
      margin-right: 4px;
  } 
  
  div.trail {
      clear:both;     
      margin-left:  50px;
      margin-top:   0px;
      margin-right: 50px
  }
  
  div.foot {
      margin-left:  50px;
      margin-right: 50px;
      margin-top:   50px;
      text-align:   center;
      font-size:    .5em;
      height: 36px;
  }
  
  div.trail h1 {
      margin-top:   -30px;
      margin-left:  -50px;
      font-size:    1.2em;   
      font-weight:  bold;
      padding-left: .4em;
  }
  
  div.trail h2 { 
      float:        left;
      font-size:    1em;   
      font-weight:  bold;
      padding-left: .4em;
  }
  
  div.trail h3 { 
      float:        left;
      font-size:    .8em;   
      font-weight:  bold;
      margin-left: -1.4em;
      margin-bottom: 1em;
  }
  
  
  div.trail p {
      clear:      both;
      margin-top: 20px;
      font-size: .8em;
      text-decoration: none;
  }
  
  div#next_trail {
      margin-left: 36px;
  }
  
  div.numbox {
      border: thin solid black; 
      margin-left: -.8em;
      float:   left;
      background: #ffffff;
      padding: .2em .35em .3em;
      font-style: normal;
      font-weight: bold;
      font-size: 1.4em;
  }
  
  div.figure {
      text-align: center;
      font-size: .6em;
      margin-top: 30px;
  }
  
  div.figure img {
      display: block;
      margin-right: auto;
      margin-left: auto;
  }
  
  code {
      font: 1.1em "Courier New", Courier, mono;
  }
  
  code.block {
      white-space: pre;
      font: 10pt "Courier New", Courier, mono;
      display: block;
      border-style: dashed;
      border-width: thin;
      padding: .5em;
      background: #ffffff;
      margin: 20px;
  }
  
  div.foot_image {
     float: left;
     height: 86px;
  }
  
  a:active {
      color : #666666;
      text-decoration: none;
  }
  
  a:hover {
      color : #000000;
      background-color : #D6E0FE;
      text-decoration: none;
  }
  
  a:link {
      color : #005EB6;
      text-decoration: none;
  }
  
  a:visited {
      color : #888888;
      text-decoration: none;
  }
  
  
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 01:32:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 01:32:48 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1781 - in
	trunk/tests/src/org/jboss/test/messaging/jms/clustering: . base
Message-ID: <E1GuNfc-0007Hm-Ky@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-13 01:32:45 -0500 (Wed, 13 Dec 2006)
New Revision: 1781

Added:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Log:
Modified ClusteringTestBase to start a variable number of cluster nodes.
Must be set up as 'nodeCount' in the test's setUp().


Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java	2006-12-13 05:30:32 UTC (rev 1780)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java	2006-12-13 06:32:45 UTC (rev 1781)
@@ -126,14 +126,17 @@
 
    protected void setUp() throws Exception
    {
+      nodeCount = 3;
+
       super.setUp();
+
+      log.debug("setup done");
    }
 
    protected void tearDown() throws Exception
    {
       super.tearDown();
    }
-  
 
    /*
     * Create a consumer on each queue on each node.
@@ -156,7 +159,7 @@
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
 
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -164,9 +167,9 @@
          
          log.info("Created sessions");
 
-         MessageConsumer cons1 = sess1.createConsumer(queue0);
-         MessageConsumer cons2 = sess2.createConsumer(queue1);
-         MessageConsumer cons3 = sess3.createConsumer(queue2);
+         MessageConsumer cons1 = sess1.createConsumer(queue[0]);
+         MessageConsumer cons2 = sess2.createConsumer(queue[1]);
+         MessageConsumer cons3 = sess3.createConsumer(queue[2]);
          
          log.info("Created consumers");
 
@@ -176,7 +179,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(queue0);
+         MessageProducer prod = sess1.createProducer(queue[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -210,7 +213,7 @@
 
          // Send at node 1
 
-         MessageProducer prod1 = sess2.createProducer(queue1);
+         MessageProducer prod1 = sess2.createProducer(queue[1]);
 
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -240,7 +243,7 @@
 
          // Send at node 2
 
-         MessageProducer prod2 = sess3.createProducer(queue2);
+         MessageProducer prod2 = sess3.createProducer(queue[2]);
 
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -308,19 +311,19 @@
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
 
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons1 = sess1.createConsumer(topic0);
-         MessageConsumer cons2 = sess2.createConsumer(topic1);
-         MessageConsumer cons3 = sess3.createConsumer(topic2);
+         MessageConsumer cons1 = sess1.createConsumer(topic[0]);
+         MessageConsumer cons2 = sess2.createConsumer(topic[1]);
+         MessageConsumer cons3 = sess3.createConsumer(topic[2]);
 
-         MessageConsumer cons4 = sess1.createConsumer(topic0);
+         MessageConsumer cons4 = sess1.createConsumer(topic[0]);
 
-         MessageConsumer cons5 = sess2.createConsumer(topic1);
+         MessageConsumer cons5 = sess2.createConsumer(topic[1]);
 
          conn1.start();
          conn2.start();
@@ -328,7 +331,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic0);
+         MessageProducer prod = sess1.createProducer(topic[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -426,19 +429,19 @@
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
 
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         MessageConsumer cons1 = sess1.createConsumer(topic0);
-         MessageConsumer cons2 = sess2.createConsumer(topic1);
-         MessageConsumer cons3 = sess3.createConsumer(topic2);
+         MessageConsumer cons1 = sess1.createConsumer(topic[0]);
+         MessageConsumer cons2 = sess2.createConsumer(topic[1]);
+         MessageConsumer cons3 = sess3.createConsumer(topic[2]);
 
-         MessageConsumer cons4 = sess1.createConsumer(topic0, "COLOUR='red'");
+         MessageConsumer cons4 = sess1.createConsumer(topic[0], "COLOUR='red'");
 
-         MessageConsumer cons5 = sess2.createConsumer(topic1, "COLOUR='blue'");
+         MessageConsumer cons5 = sess2.createConsumer(topic[1], "COLOUR='blue'");
 
          conn1.start();
          conn2.start();
@@ -446,7 +449,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic0);
+         MessageProducer prod = sess1.createProducer(topic[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -566,7 +569,7 @@
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
 
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
@@ -602,11 +605,11 @@
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub1");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub2");
-         MessageConsumer cons4 = sess1.createDurableSubscriber(topic0, "sub3");
-         MessageConsumer cons5 = sess2.createDurableSubscriber(topic1, "sub4");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic[0], "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic[1], "sub1");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic[2], "sub2");
+         MessageConsumer cons4 = sess1.createDurableSubscriber(topic[0], "sub3");
+         MessageConsumer cons5 = sess2.createDurableSubscriber(topic[1], "sub4");
 
          conn1.start();
          conn2.start();
@@ -614,7 +617,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic0);
+         MessageProducer prod = sess1.createProducer(topic[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -704,13 +707,10 @@
       }
    }
 
-
-
-
    /*
     * Create shared durable subs on multiple nodes, the local instance should always get the message
     */
-   protected void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
+   private void clusteredTopicSharedDurableLocalConsumer(boolean persistent) throws Exception
    {
       Connection conn1 = null;
       Connection conn2 = null;
@@ -726,7 +726,7 @@
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
          conn3.setClientID("wib1");
@@ -751,9 +751,9 @@
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic0, "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic2, "sub");
+         MessageConsumer cons1 = sess1.createDurableSubscriber(topic[0], "sub");
+         MessageConsumer cons2 = sess2.createDurableSubscriber(topic[1], "sub");
+         MessageConsumer cons3 = sess3.createDurableSubscriber(topic[2], "sub");
 
          conn1.start();
          conn2.start();
@@ -761,7 +761,7 @@
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic0);
+         MessageProducer prod = sess1.createProducer(topic[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -793,7 +793,7 @@
 
          // Send at node 1
 
-         MessageProducer prod1 = sess2.createProducer(topic1);
+         MessageProducer prod1 = sess2.createProducer(topic[1]);
 
          prod1.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -823,7 +823,7 @@
 
          // Send at node 2
 
-         MessageProducer prod2 = sess3.createProducer(topic2);
+         MessageProducer prod2 = sess3.createProducer(topic[2]);
 
          prod2.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
@@ -887,7 +887,7 @@
     * should round robin
     * note that this test assumes round robin
     */
-   protected void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
+   private void clusteredTopicSharedDurableNoLocalSub(boolean persistent) throws Exception
    {
       Connection conn1 = null;
       Connection conn2 = null;
@@ -903,7 +903,7 @@
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(conn1, conn2, conn3);
+         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
          
          conn2.setClientID("wib1");
          conn3.setClientID("wib1");
@@ -923,8 +923,8 @@
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess2.createDurableSubscriber(topic1, "sub");
-         MessageConsumer cons2 = sess3.createDurableSubscriber(topic2, "sub");
+         MessageConsumer cons1 = sess2.createDurableSubscriber(topic[1], "sub");
+         MessageConsumer cons2 = sess3.createDurableSubscriber(topic[2], "sub");
 
          conn2.start();
          conn3.start();
@@ -933,7 +933,7 @@
 
          //Should round robin between the other 2 since there is no active consumer on sub  on node 0
 
-         MessageProducer prod = sess1.createProducer(topic0);
+         MessageProducer prod = sess1.createProducer(topic[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 

Added: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 05:30:32 UTC (rev 1780)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 06:32:45 UTC (rev 1781)
@@ -0,0 +1,57 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class FailoverTest extends ClusteringTestBase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public FailoverTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void simpleFailover() throws Exception
+   {
+
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-13 05:30:32 UTC (rev 1780)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-13 06:32:45 UTC (rev 1781)
@@ -77,7 +77,7 @@
     */
    public void testRoundRobinConnectionCreation() throws Exception
    {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -200,7 +200,7 @@
    public void testDefaultFailoverMap() throws Exception
    {     
       {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
          
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -259,7 +259,7 @@
       {         
          //Lookup another connection factory
          
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic[1].lookup("/ConnectionFactory");
          
          log.info("Got connection factory");
          
@@ -307,7 +307,7 @@
       {         
          //Lookup another connection factory
          
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
          
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -333,7 +333,7 @@
       ServerManagement.start("all", 0);
       
       {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
          
          log.info("Got connection factory");
          
@@ -374,7 +374,7 @@
       ServerManagement.start("all", 1);
       
       {
-         JBossConnectionFactory factory =  (JBossConnectionFactory )ic1.lookup("/ConnectionFactory");
+         JBossConnectionFactory factory =  (JBossConnectionFactory )ic[1].lookup("/ConnectionFactory");
          
          log.info("Got connection factory");
          
@@ -420,7 +420,7 @@
    
    public void testSimpleFailover() throws Exception
    {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -484,9 +484,9 @@
                            
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
-         MessageProducer prod = sess.createProducer(queue1);
+         MessageProducer prod = sess.createProducer(queue[1]);
          
-         MessageConsumer cons = sess.createConsumer(queue1);
+         MessageConsumer cons = sess.createConsumer(queue[1]);
          
          final int NUM_MESSAGES = 100;
          
@@ -497,7 +497,7 @@
             prod.send(tm);
          }
          
-         //So now, messages should be in queue1 on server 1
+         //So now, messages should be in queue[1] on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
          
@@ -555,7 +555,7 @@
    
    public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
    {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -618,9 +618,9 @@
                            
          Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
          
-         MessageProducer prod = sess.createProducer(queue1);
+         MessageProducer prod = sess.createProducer(queue[1]);
          
-         MessageConsumer cons = sess.createConsumer(queue1);
+         MessageConsumer cons = sess.createConsumer(queue[1]);
          
          final int NUM_MESSAGES = 100;
          
@@ -645,7 +645,7 @@
             assertEquals("message:" + i, tm.getText());
          }
          
-         //So now, messages should be in queue1 on server 1
+         //So now, messages should be in queue[1] on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
          
@@ -699,7 +699,7 @@
          
          sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
-         cons = sess.createConsumer(queue1);
+         cons = sess.createConsumer(queue[1]);
          
          Message m = cons.receive(500);
          
@@ -726,7 +726,7 @@
    
    public void testFailoverWithUnackedMessagesTransactional() throws Exception
    {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
       
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
@@ -789,9 +789,9 @@
                            
          Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
          
-         MessageProducer prod = sess.createProducer(queue1);
+         MessageProducer prod = sess.createProducer(queue[1]);
          
-         MessageConsumer cons = sess.createConsumer(queue1);
+         MessageConsumer cons = sess.createConsumer(queue[1]);
          
          final int NUM_MESSAGES = 100;
          
@@ -818,7 +818,7 @@
             assertEquals("message:" + i, tm.getText());
          }
          
-         //So now, messages should be in queue1 on server 1
+         //So now, messages should be in queue[1] on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
          
@@ -872,7 +872,7 @@
          
          sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          
-         cons = sess.createConsumer(queue1);
+         cons = sess.createConsumer(queue[1]);
          
          Message m = cons.receive(500);
          
@@ -902,7 +902,7 @@
    
 //   public void testEvenSimplerFailover() throws Exception
 //   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic0.lookup("/ConnectionFactory");
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
 //                  
 //      Connection conn = null;
 //      
@@ -942,7 +942,7 @@
 // {
 // try
 // {
-// JBossConnectionFactory factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+// JBossConnectionFactory factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
 // ClusteredClientConnectionFactoryDelegate delegate =
 // (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 // log.info ("number of delegates = " + delegate.getDelegates().length);
@@ -971,7 +971,7 @@
 // 
 // ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
 // 
-// factory =  (JBossConnectionFactory )ic2.lookup("/ConnectionFactory");
+// factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
 // delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 // 
 // assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
@@ -997,7 +997,7 @@
 // assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
 // 
 // log.info(">>Lookup Queue");
-// Destination destination = (Destination) ic2.lookup("topic/testDistributedTopic");
+// Destination destination = (Destination) ic[2].lookup("topic/testDistributedTopic");
 // 
 // log.info("Creating connection server1");
 // JBossConnection conn = (JBossConnection) cf.createConnection();
@@ -1083,7 +1083,7 @@
 // log.info("++testTopicSubscriber");
 // 
 // log.info(">>Lookup Queue");
-// Destination destination = (Destination) ic1.lookup("queue/testDistributedQueue");
+// Destination destination = (Destination) ic[1].lookup("queue/testDistributedQueue");
 // 
 // log.info("Creating connection server1");
 // JBossConnection conn = (JBossConnection) cf1.createConnection();
@@ -1175,7 +1175,11 @@
    
    protected void setUp() throws Exception
    {
+      nodeCount = 3;
+
       super.setUp();
+
+      log.debug("setup done");
    }
    
    protected void tearDown() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-13 05:30:32 UTC (rev 1780)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-13 06:32:45 UTC (rev 1781)
@@ -101,11 +101,6 @@
 
    }
    
-//   public void testKill() throws Exception
-//   {
-//      ServerManagement.getServer(0).kill();
-//   }
-
    public void testDistributedTopic() throws Exception
    {
       Connection conn = null;
@@ -126,15 +121,15 @@
          SimpleMessageListener ml1 = new SimpleMessageListener();
          SimpleMessageListener ml2 = new SimpleMessageListener();
 
-         s.createConsumer(topic0).setMessageListener(ml);
-         s1.createConsumer(topic0).setMessageListener(ml1);
-         s2.createConsumer(topic0).setMessageListener(ml2);
+         s.createConsumer(topic[0]).setMessageListener(ml);
+         s1.createConsumer(topic[0]).setMessageListener(ml1);
+         s2.createConsumer(topic[0]).setMessageListener(ml2);
 
          conn.start();
          conn1.start();
          conn2.start();
 
-         s.createProducer(topic0).send(s.createTextMessage("boom"));
+         s.createProducer(topic[0]).send(s.createTextMessage("boom"));
 
          TextMessage rm = null;
 
@@ -163,9 +158,7 @@
          {
             conn2.close();
          }
-
       }
-
    }
 
    // Package protected ---------------------------------------------
@@ -174,6 +167,8 @@
 
    protected void setUp() throws Exception
    {
+      nodeCount = 3;
+
       super.setUp();
 
       log.debug("setup done");

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-13 05:30:32 UTC (rev 1780)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-13 06:32:45 UTC (rev 1781)
@@ -40,6 +40,7 @@
 /**
  * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision:$</tt>
  * $Id:$
  */
@@ -51,20 +52,15 @@
 
    // Attributes ----------------------------------------------------
 
-   protected Context ic0;
-   protected Context ic1;
-   protected Context ic2;
+   protected int nodeCount;
 
-   protected Queue queue0;
-   protected Queue queue1;
-   protected Queue queue2;
+   protected Context[] ic;
+   protected Queue queue[];
+   protected Topic topic[];
 
-   protected Topic topic0;
-   protected Topic topic1;
-   protected Topic topic2;
-   
-   //No need to have 3 conncetion factories since a clustered connection factory
-   //will create connections in a round robin fashion on different servers
+   // No need to have multiple conncetion factories since a clustered connection factory will create
+   // connections in a round robin fashion on different servers.
+
    protected ConnectionFactory cf;
 
    // Constructors --------------------------------------------------
@@ -84,183 +80,128 @@
    {
       super.setUp();
 
-      String banner =
-         "####################################################### Start " +
-         (isRemote() ? "REMOTE" : "IN-VM") + " test: " + getName();
+      if (nodeCount < 1)
+      {
+         throw new Exception("Node count not defined! Initalize nodeCount in the test's setUp()");
+      }
 
-      ServerManagement.log(ServerManagement.INFO,banner);
+      ic = new Context[nodeCount];
+      queue = new Queue[nodeCount];
+      topic = new Topic[nodeCount];
 
-      try
+      for(int i = 0; i < nodeCount; i++)
       {
-         startServer(0);
-         startServer(1);
-         startServer(2);
+         ServerManagement.start("all", i);
+         ServerManagement.deployClusteredQueue("testDistributedQueue", i);
+         ServerManagement.deployClusteredTopic("testDistributedTopic", i);
 
-         log.info("Deployed destinations ok");
+         ic[i] = new InitialContext(ServerManagement.getJNDIEnvironment(i));
+         queue[i] = (Queue)ic[i].lookup("queue/testDistributedQueue");
+         topic[i] = (Topic)ic[i].lookup("topic/testDistributedTopic");
+      }
 
-         ic0 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
-         ic1 = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-         ic2 = new InitialContext(ServerManagement.getJNDIEnvironment(2));
+      // We only need to lookup one connection factory since it will be clustered so we will
+      // actually create connections on different servers (round robin).
+      cf = (ConnectionFactory)ic[0].lookup("/ConnectionFactory");
 
-         //We only need to lookup one connection factory since it will be a clustered cf
-         //so we will actually create connections on different servers (round robin)
-         cf = (ConnectionFactory)ic0.lookup("/ConnectionFactory");
-
-         queue0 = (Queue)ic0.lookup("queue/testDistributedQueue");
-         queue1 = (Queue)ic1.lookup("queue/testDistributedQueue");
-         queue2 = (Queue)ic2.lookup("queue/testDistributedQueue");
-
-         topic0 = (Topic)ic0.lookup("topic/testDistributedTopic");
-         topic1 = (Topic)ic1.lookup("topic/testDistributedTopic");
-         topic2 = (Topic)ic2.lookup("topic/testDistributedTopic");
-
-         drainQueues();
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-         throw e;
-      }
+      drainQueues();
    }
 
    protected void tearDown() throws Exception
    {
-      try
-      {                  
-         if (!ServerManagement.isKilled(0) && ServerManagement.getServer(0).isStarted())
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 0", 0);
-            ServerManagement.undeployQueue("testDistributedQueue", 0);
-            ServerManagement.undeployTopic("testDistributedTopic", 0);
-         }
 
-         if (!ServerManagement.isKilled(1) && ServerManagement.getServer(1).isStarted())
+      for(int i = 0; i < nodeCount; i++)
+      {
+         if (!ServerManagement.isKilled(i) && ServerManagement.getServer(i).isStarted())
          {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 1", 1);
-            ServerManagement.undeployQueue("testDistributedQueue", 1);
-            ServerManagement.undeployTopic("testDistributedTopic", 1);
+            ServerManagement.log(ServerManagement.INFO, "Undeploying Server " + i, i);
+            ServerManagement.undeployQueue("testDistributedQueue", i);
+            ServerManagement.undeployTopic("testDistributedTopic", i);
          }
 
-         if (!ServerManagement.isKilled(2) && ServerManagement.getServer(2).isStarted())
-         {
-            ServerManagement.log(ServerManagement.INFO, "Undeploying Server 2", 2);
-            ServerManagement.undeployQueue("testDistributedQueue", 2);
-            ServerManagement.undeployTopic("testDistributedTopic", 2);
-         }
+         ic[i].close();
+      }
 
-         ic0.close();
-         ic1.close();
-         ic2.close();
+      super.tearDown();
+   }
 
-         super.tearDown();
-      }
-      catch (Exception e)
+   protected void checkConnectionsDifferentServers(Connection[] conn) throws Exception
+   {
+      int[] serverID = new int[conn.length];
+      for(int i = 0; i < conn.length; i++)
       {
-         e.printStackTrace();
-         throw e;
+         ConnectionState state = (ConnectionState)(((DelegateSupport)((JBossConnection)conn[i]).
+            getDelegate()).getState());
+         serverID[i] = state.getServerID();
       }
-   }
 
-   protected void checkConnectionsDifferentServers(Connection conn, Connection conn1, Connection conn2)
-   {
-      ConnectionState state0 =
-         (ConnectionState)(((DelegateSupport)((JBossConnection)conn).getDelegate()).getState());
-      ConnectionState state1 =
-         (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-      ConnectionState state2 =
-         (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
+      for(int i = 0; i < nodeCount; i++)
+      {
+         for(int j = 0; j < nodeCount; j++)
+         {
+            if (i == j)
+            {
+               continue;
+            }
 
-      int serverID0 = state0.getServerID();
-      int serverID1 = state1.getServerID();
-      int serverID2 = state2.getServerID();
-
-      log.info("Server 0 ID: " + serverID0);
-      log.info("Server 1 ID: " + serverID1);
-      log.info("Server 2 ID: " + serverID2);
-
-      assertTrue(serverID0 != serverID1);
-      assertTrue(serverID1 != serverID2);
+            if (serverID[i] == serverID[j])
+            {
+               fail("Connections " + i + " and " + j +
+                  " are pointing to the same physical node (" + serverID[i] + ")");
+            }
+         }
+      }
    }
 
-   protected void drainQueues() throws Exception
+   // Private -------------------------------------------------------
+
+   private void drainQueues() throws Exception
    {
-      Connection conn0 = null;
-      Connection conn1 = null;
-      Connection conn2 = null;
+      Connection[] conn = new Connection[nodeCount];
+      int[] serverID = new int[nodeCount];
 
       try
       {
-         //Since the cf is clustered, this will create connections on 3 different nodes
-         //(round robin)
-         conn0 = cf.createConnection();
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
+         // TODO This is a dangerous hack, relying on an arbitrary distribution algorithm
+         // (round-robin in this case). If we want a connection to a specific node, we should be
+         // able to look up something like "/ConnectionFactory0"
 
-         checkConnectionsDifferentServers(conn0, conn1, conn2);
+         for(int i = 0; i < nodeCount; i++)
+         {
+            conn[i] = cf.createConnection();
+         }
 
-         Session sess0 = conn0.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         // Safety check, making sure we get connections to distinct nodes
 
-         MessageConsumer cons0 = sess0.createConsumer(queue0);
-         MessageConsumer cons1 = sess1.createConsumer(queue1);
-         MessageConsumer cons2 = sess2.createConsumer(queue2);
+         checkConnectionsDifferentServers(conn);
 
-         conn0.start();
-         conn1.start();
-         conn2.start();
-
-         Message msg = null;
-
-         do
+         for(int i = 0; i < nodeCount; i++)
          {
-            msg = cons0.receive(1000);
-            log.info("1 Drained message " + msg);
-         }
-         while (msg != null);
+            Session s = conn[i].createSession(false, Session.AUTO_ACKNOWLEDGE);
+            MessageConsumer c = s.createConsumer(queue[i]);
+            conn[i].start();
 
-         do
-         {
-            msg = cons1.receive(1000);
-            log.info("2 Drained message " + msg);
+            Message msg = null;
+            do
+            {
+               msg = c.receive(1000);
+               log.info("Drained message " + msg + " on node " + i);
+            }
+            while (msg != null);
          }
-         while (msg != null);
-
-         do
-         {
-            msg = cons2.receive(1000);
-            log.info("3 Drained message " + msg);
-         }
-         while (msg != null);
       }
       finally
       {
-         if (conn0 != null)
+         for(int i = 0; i < nodeCount; i++)
          {
-            conn0.close();
+            if (conn[i] != null)
+            {
+               conn[i].close();
+            }
          }
-
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
       }
    }
 
-   // Private -------------------------------------------------------
-
-   private void startServer(int serverIndex) throws Exception
-   {
-      ServerManagement.start("all", serverIndex);
-      ServerManagement.deployClusteredQueue("testDistributedQueue", serverIndex);
-      ServerManagement.deployClusteredTopic("testDistributedTopic", serverIndex);
-   }
-
    // Inner classes -------------------------------------------------
 
 }



From michael.yuan at jboss.com  Wed Dec 13 01:33:49 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 13 Dec 2006 01:33:49 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/view  ...
Message-ID: <E1GuNgb-0007IR-Hb@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/13 01:33:49

  Modified:    examples/glassfish/view  template.xhtml
  Log:
  css support for s:selectDate
  
  Revision  Changes    Path
  1.2       +1 -0      jboss-seam/examples/glassfish/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/view/template.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- template.xhtml	29 Nov 2006 09:30:42 -0000	1.1
  +++ template.xhtml	13 Dec 2006 06:33:49 -0000	1.2
  @@ -6,6 +6,7 @@
   	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
   	<title>JBoss Suites: Seam Framework</title>
   	<link href="css/screen.css" rel="stylesheet" type="text/css" />
  +	<link href="css/date.css" rel="stylesheet" type="text/css" />
   </head>
   <body>
   
  
  
  


From michael.yuan at jboss.com  Wed Dec 13 01:33:49 2006
From: michael.yuan at jboss.com (Michael Yuan)
Date: Wed, 13 Dec 2006 01:33:49 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/view/css   ...
Message-ID: <E1GuNgb-0007Ib-L6@committer01.frg.pub.inap.atl.jboss.com>

  User: myuan   
  Date: 06/12/13 01:33:49

  Modified:    examples/glassfish/view/css   screen.css
  Added:       examples/glassfish/view/css   date.css
  Log:
  css support for s:selectDate
  
  Revision  Changes    Path
  1.2       +0 -128    jboss-seam/examples/glassfish/view/css/screen.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: screen.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/view/css/screen.css,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- screen.css	29 Nov 2006 09:30:43 -0000	1.1
  +++ screen.css	13 Dec 2006 06:33:49 -0000	1.2
  @@ -263,131 +263,3 @@
   #pgHome input[type="submit"] {
   	height: 30px;
   }
  -/* Date Picker 
  ------------------------------------------------ */
  -body {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: .8em;
  -	}
  -
  -/* the div that holds the date picker calendar */
  -.dpDiv {
  -	}
  -
  -
  -/* the table (within the div) that holds the date picker calendar */
  -.dpTable {
  -	font-family: Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 12px;
  -	text-align: center;
  -	color: #505050;
  -	background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
  -	background-color: #FFFFFF;
  -	border: 1px solid #AAAAAA;
  -	margin-top: 5px;
  -	}
  -
  -
  -/* a table row that holds date numbers (either blank or 1-31) */
  -.dpTR {
  -	}
  -
  -
  -/* the top table row that holds the month, year, and forward/backward buttons */
  -.dpTitleTR {
  -	}
  -
  -
  -/* the second table row, that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTR {
  -	}
  -
  -
  -/* the bottom table row, that has the "This Month" and "Close" buttons */
  -.dpTodayButtonTR {
  -	}
  -
  -
  -/* a table cell that holds a date number (either blank or 1-31) */
  -.dpTD {
  -	border: 1px solid #ece9d8;
  -	}
  -
  -
  -/* a table cell that holds a highlighted day (usually either today's date or the current date field value) */
  -.dpDayHighlightTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  -.dpTDHover {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	cursor: pointer;
  -	color: red;
  -	font-weight: bold;
  -	}
  -
  -
  -/* the table cell that holds the name of the month and the year */
  -.dpTitleTD {
  -	}
  -
  -
  -/* a table cell that holds one of the forward/backward buttons */
  -.dpButtonTD {
  -	}
  -
  -
  -/* the table cell that holds the "This Month" or "Close" button at the bottom */
  -.dpTodayButtonTD {
  -	}
  -
  -
  -/* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  -.dpDayTD {
  -	background-color: #CCCCCC;
  -	border: 1px solid #AAAAAA;
  -	color: white;
  -	}
  -
  -
  -/* additional style information for the text that indicates the month and year */
  -.dpTitleText {
  -	font-size: 12px;
  -	color: gray;
  -	font-weight: bold;
  -	}
  -
  -
  -/* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  -.dpDayHighlight {
  -	color: CCCCCC;
  -	font-weight: bold;
  -	}
  -
  -
  -/* the forward/backward buttons at the top */
  -.dpButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	padding: 0px;
  -	border: 1px solid #AAAAAA;
  -	}
  -
  -
  -/* the "This Month" and "Close" buttons at the bottom */
  -.dpTodayButton {
  -	font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
  -	font-size: 10px;
  -	color: gray;
  -	background: #FFFFFF;
  -	font-weight: bold;
  -	border: 1px solid #AAAAAA;
  -	display:none;
  -	}
  
  
  
  1.1      date: 2006/12/13 06:33:49;  author: myuan;  state: Exp;jboss-seam/examples/glassfish/view/css/date.css
  
  Index: date.css
  ===================================================================
  /* Seam Date Picker */
  
  /* the div that holds the date picker calendar */
  .seam-date {
  
  }
  
  
  /* the table (within the div) that holds the date picker calendar */
  .seam-date table {
      font-family: Tahoma, Arial, Helvetica, sans-serif;
      font-size: 12px;
      text-align: center;
      color: #505050;
      background: #fff url(../img/input.bg.gif) 0 0 repeat-x;
      background-color: #FFFFFF;
      border: 1px solid #AAAAAA;
      margin-top: 5px;
  }
  
  
  .seam-date-title div {
      font-size: 12px;
      color: gray;
      font-weight: bold;
  }
  
  
  /* the forward/backward buttons at the top */
  .seam-date-title button{
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      padding: 0px;
      border: 1px solid #AAAAAA;
  }
  
  
  /* the "This Month" and "Close" buttons at the bottom */
  .seam-date-footer {
  	display: none;
  }
  
  .seam-date-footer button {
      font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
      font-size: 10px;
      color: gray;
      background: #FFFFFF;
      font-weight: bold;
      border: 1px solid #AAAAAA;
  }
  
  
  
  /* a table cell that holds the names of days of the week (Mo, Tu, We, etc.) */
  .seam-date-header td {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      color: white;
  }
  
  
  
  /* a table cell that holds a date number (either blank or 1-31) */
  .seam-date-week td.seam-date-day {
      border: 1px solid #ece9d8;	
  }
  
  /* the date number table cell that the mouse pointer is currently over (you can use contrasting colors to make it apparent which cell is being hovered over) */
  .seam-date-week td.seam-date-hover  {
      background-color: #CCCCCC;
      border: 1px solid #AAAAAA;
      cursor: pointer;
      color: red;
  }
  
  
  /* additional style information for the cell that holds a highlighted day (usually either today's date or the current date field value) */ 
  .seam-date-week td.seam-date-selected {
      background-color: #CCCCCC;        
      border: 1px solid #AAAAAA;
      font-weight: bold;
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 02:05:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 02:05:11 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1782 - in
	trunk/tests/src/org/jboss/test/messaging/jms/clustering: . base
Message-ID: <E1GuOAx-0007vi-Mz@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-13 02:05:09 -0500 (Wed, 13 Dec 2006)
New Revision: 1782

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Log:
Added extra failover tests.


Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 06:32:45 UTC (rev 1781)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 07:05:09 UTC (rev 1782)
@@ -7,7 +7,18 @@
 package org.jboss.test.messaging.jms.clustering;
 
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.client.delegate.DelegateSupport;
 
+import javax.jms.Connection;
+import javax.jms.Session;
+import javax.jms.MessageProducer;
+import javax.jms.DeliveryMode;
+import javax.jms.MessageConsumer;
+import javax.jms.TextMessage;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
@@ -31,9 +42,63 @@
 
    // Public --------------------------------------------------------
 
-   public void simpleFailover() throws Exception
+   public void testSimpleFailover() throws Exception
    {
+      Connection conn = null;
 
+      try
+      {
+         conn = cf.createConnection();
+
+         // send a message
+
+         Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer p = s.createProducer(queue[0]);
+         p.setDeliveryMode(DeliveryMode.PERSISTENT);
+         p.send(s.createTextMessage("blip"));
+
+         conn.close();
+
+         // create a connection to a node we'll kill soon
+
+         conn = cf.createConnection();
+         s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer c = s.createConsumer(queue[2]); // TODO What happens if I use queue[1]?
+         conn.start();
+
+         // make sure we're connecting to node 1
+
+         int nodeID =
+            ((ConnectionState)((DelegateSupport)((JBossConnection)conn).getDelegate()).getState()).
+               getServerID();
+
+         assertEquals(1, nodeID);
+
+         // kill node 1
+
+         ServerManagement.kill(1);
+
+         log.info("########");
+         log.info("######## KILLED NODE 1");
+         log.info("########");
+
+         // TODO - this shouldn't be necessary if we have the client valve in place         
+         log.info("Sleeping for 1 min");
+         Thread.sleep(60000);
+
+         // we must receive the message
+
+         TextMessage tm = (TextMessage)c.receive(1000);
+         assertEquals("blip", tm.getText());
+
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
    }
 
    // Package protected ---------------------------------------------
@@ -42,7 +107,11 @@
 
    protected void setUp() throws Exception
    {
+      nodeCount = 3;
+
       super.setUp();
+
+      log.debug("setup done");
    }
 
    protected void tearDown() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-13 06:32:45 UTC (rev 1781)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-13 07:05:09 UTC (rev 1782)
@@ -158,7 +158,6 @@
    private void drainQueues() throws Exception
    {
       Connection[] conn = new Connection[nodeCount];
-      int[] serverID = new int[nodeCount];
 
       try
       {
@@ -185,7 +184,10 @@
             do
             {
                msg = c.receive(1000);
-               log.info("Drained message " + msg + " on node " + i);
+               if (msg != null)
+               {
+                  log.info("Drained message " + msg + " on node " + i);
+               }
             }
             while (msg != null);
          }



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 04:46:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 04:46:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1783 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GuQhI-0002UC-Uu@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-13 04:46:39 -0500 (Wed, 13 Dec 2006)
New Revision: 1783

Added:
   trunk/src/main/org/jboss/jms/client/container/DelegateIdentity.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
Log:
HAAspect delegate refactoring. Added a new failover test (that currently fails)

Modified: trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java	2006-12-13 07:05:09 UTC (rev 1782)
+++ trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java	2006-12-13 09:46:39 UTC (rev 1783)
@@ -72,8 +72,7 @@
    private int inUseCount;
 
    // The identity of the delegate this interceptor is associated with
-   private Integer id;
-   private String delegateType;
+   private DelegateIdentity id;
 
    // Static --------------------------------------------------------
 
@@ -106,7 +105,7 @@
       }
       else
       {
-         sb.append(delegateType).append("[").append(id.intValue()).append("]");
+         sb.append(id.getType()).append("[").append(id.getID()).append("]");
       }
       return sb.toString();
    }
@@ -129,7 +128,7 @@
       // logging purposes. It makes sense, since it's an PER_INSTANCE interceptor
       if (id == null)
       {
-         getIdentity(invocation);
+         id = DelegateIdentity.getIdentity(invocation);
       }
 
       String methodName = ((MethodInvocation) invocation).getMethod().getName();
@@ -319,14 +318,6 @@
 
    // Private --------------------------------------------------------
 
-   private void getIdentity(Invocation i)
-   {
-      DelegateSupport ds = (DelegateSupport)i.getTargetObject();
-      id = new Integer(ds.getID());
-      delegateType = ds.getClass().getName();
-      delegateType = delegateType.substring(delegateType.lastIndexOf('.') + 1);
-   }
-
    // Inner Classes --------------------------------------------------
 
 }

Added: trunk/src/main/org/jboss/jms/client/container/DelegateIdentity.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/DelegateIdentity.java	2006-12-13 07:05:09 UTC (rev 1782)
+++ trunk/src/main/org/jboss/jms/client/container/DelegateIdentity.java	2006-12-13 09:46:39 UTC (rev 1783)
@@ -0,0 +1,67 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.container;
+
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.jms.client.delegate.DelegateSupport;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class DelegateIdentity
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   public static DelegateIdentity getIdentity(Invocation i)
+   {
+      DelegateSupport ds = (DelegateSupport)i.getTargetObject();
+
+      Integer id = new Integer(ds.getID());
+      String type = ds.getClass().getName();
+
+      type = type.substring(type.lastIndexOf('.') + 1);
+
+      return new DelegateIdentity(id, type);
+   }
+
+   // Attributes ----------------------------------------------------
+
+   private Integer id;
+   private String type;
+
+   // Constructors --------------------------------------------------
+
+   public DelegateIdentity(Integer id, String type)
+   {
+      this.id = id;
+      this.type = type;
+   }
+
+   // Public --------------------------------------------------------
+
+   public Integer getID()
+   {
+      return id;
+   }
+
+   public String getType()
+   {
+      return type;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 07:05:09 UTC (rev 1782)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 09:46:39 UTC (rev 1783)
@@ -66,287 +66,288 @@
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * 
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
- *
- * TODO: Make some log.info as log.trace after the code is final
- *
  */
 public class HAAspect
 {
+   // Constants -----------------------------------------------------
+
    private static final Logger log = Logger.getLogger(HAAspect.class);
-   
+
+   public static final int MAX_RECONNECT_HOP_COUNT = 10;
+
+   // Static --------------------------------------------------------
+
    private static boolean trace = log.isTraceEnabled();
-   
-   //Cache this here
+
+   // Attributes ----------------------------------------------------
+
    private ClientConnectionFactoryDelegate[] delegates;
-   
-   //Cache this here
+
    private Map failoverMap;
-   
+
    private int currentRobinIndex;
-   
+
+   // The identity of the delegate this interceptor is associated with
+   private DelegateIdentity id;
+
+   // Constructors --------------------------------------------------
+
+   public HAAspect()
+   {
+      id = null;
+   }
+
+   // Public --------------------------------------------------------
+
    public Object handleCreateConnectionDelegate(Invocation invocation) throws Throwable
    {
-      if (getServers(invocation) != null)
+      // maintain the identity of the delegate that sends invocation through this aspect, for
+      // logging purposes. It makes sense, since it's an PER_INSTANCE aspect.
+      if (id == null)
       {
-         // TODO: this should be in loop while we get exceptions creating connections, always trying
-         //       the next Delegate when we get an exception.
-         log.info("Clustered createConnection");
-                  
-         //In a clustered configuration we create connections in a round-robin fashion
-         //from the available servers
-         
-         ClientConnectionFactoryDelegate cfDelegate = getDelegateRoundRobin();
-         
-         //Now create a connection delegate for this
-         
-         MethodInvocation mi = (MethodInvocation)invocation;
-         
-         String username = (String)mi.getArguments()[0];
-         
-         String password = (String)mi.getArguments()[1];
-         
-         ClientConnectionDelegate connDelegate = createConnection(cfDelegate, username, password);
-         
-         return new CreateConnectionResult(connDelegate);
+         id = DelegateIdentity.getIdentity(invocation);
       }
-      else
+
+      cacheLocalDelegates(invocation);
+
+      if (delegates == null)
       {
-         //Non clustered
-
-         log.info("Assumed non clustered");
-         
+         // not clustered, pass the invocation through
          return invocation.invokeNext();
       }
-   }   
-   
-   //TODO this is currently hardcoded as round-robin, this should be made pluggable
-   private synchronized ClientConnectionFactoryDelegate getDelegateRoundRobin()
+
+      // clustered
+
+      // TODO: this should be in loop while we get exceptions creating connections, always trying
+      //       the next Delegate when we get an exception.
+
+      // In a clustered configuration we create connections in a round-robin fashion, contacting
+      // successively all available servers.
+
+      ClientConnectionFactoryDelegate cfDelegate = getDelegateRoundRobin();
+
+      // Now create a connection delegate for this
+
+      MethodInvocation mi = (MethodInvocation)invocation;
+      String username = (String)mi.getArguments()[0];
+      String password = (String)mi.getArguments()[1];
+
+      ClientConnectionDelegate cd = createConnection(cfDelegate, username, password);
+
+      return new CreateConnectionResult(cd);
+   }
+
+   public String toString()
    {
-      ClientConnectionFactoryDelegate currentDelegate = delegates[currentRobinIndex++];
-      
-      if (currentRobinIndex >= delegates.length)
+      StringBuffer sb = new StringBuffer("HAAspect.");
+      if (id == null)
       {
-         currentRobinIndex = 0;
+         sb.append("UNINITIALIZED");
       }
-      
-      return currentDelegate;
+      else
+      {
+         sb.append(id.getType()).append("[").append(id.getID()).append("]");
+      }
+      return sb.toString();
    }
-   
-   private synchronized ClientConnectionFactoryDelegate[] getServers(Invocation invocation)
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   private synchronized void cacheLocalDelegates(Invocation invocation)
    {
-      if (delegates == null)
+      if (delegates != null)
       {
-         log.info("Looking for delegates");
+         // the first set of delegates is already cached, return
+         return;
+      }
 
-         MethodInvocation methodInvoke = (MethodInvocation)invocation;
+      MethodInvocation mi = (MethodInvocation)invocation;
+      Object target = mi.getTargetObject();
 
-         Object target = methodInvoke.getTargetObject();
-         
-         if (target instanceof ClusteredClientConnectionFactoryDelegate)
-         {
-            delegates = ((ClusteredClientConnectionFactoryDelegate)target).getDelegates();
-         }
+      if (target instanceof ClusteredClientConnectionFactoryDelegate)
+      {
+         ClusteredClientConnectionFactoryDelegate cccfd =
+            (ClusteredClientConnectionFactoryDelegate)target;
 
+         delegates = cccfd.getDelegates();
+
          if (delegates != null)
          {
-            failoverMap = ((ClusteredClientConnectionFactoryDelegate)target).getFailoverMap();
+            failoverMap = cccfd.getFailoverMap();
 
             if (failoverMap == null)
             {
-               throw new IllegalStateException("Cannot find failoverMap!");
+               throw new IllegalStateException("HAAspect cannot find the failover map!");
             }
          }
       }
-      
-      return delegates;
    }
-   
-   private ClientConnectionDelegate createConnection(ClientConnectionFactoryDelegate cf, String username, String password)
-      throws Exception
+
+   //TODO this is currently hardcoded as round-robin, this should be made pluggable
+   private synchronized ClientConnectionFactoryDelegate getDelegateRoundRobin()
    {
-      log.info("createConnection");
-      
-      CreateConnectionResult res = (CreateConnectionResult)cf.createConnectionDelegate(username, password, -1);
-      
-      ClientConnectionDelegate connDelegate = (ClientConnectionDelegate)res.getDelegate();
-      
-      addListener(connDelegate);
-      
-      return connDelegate;   
+      ClientConnectionFactoryDelegate currentDelegate = delegates[currentRobinIndex++];
+
+      if (currentRobinIndex >= delegates.length)
+      {
+         currentRobinIndex = 0;
+      }
+
+      return currentDelegate;
    }
-   
-   private void addListener(ClientConnectionDelegate connDelegate)
+
+   private ClientConnectionDelegate createConnection(ClientConnectionFactoryDelegate cfd,
+                                                     String username,
+                                                     String password)
+      throws Exception
    {
-      //Add a connection listener
-      
-      ConnectionState state = (ConnectionState)((DelegateSupport)connDelegate).getState();
-      
-      ConnectionListener listener = new Listener(connDelegate);
-      
+      CreateConnectionResult res =
+         (CreateConnectionResult)cfd.createConnectionDelegate(username, password, -1);
+
+      ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
+
+      // Add a connection listener to detect failure
+
+      ConnectionListener listener = new ConnectionFailureListener(cd);
+      ConnectionState state = (ConnectionState)((DelegateSupport)cd).getState();
       state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
+
+      return cd;
    }
 
-   //The connection has failed
-   private void handleFailure(ClientConnectionDelegate failedConnection) throws Exception
+   /**
+    * @return a failover ClientConnectionFactoryDelegate or null if a suitable delegate cannot be
+    *         found.
+    */
+   private ClientConnectionFactoryDelegate getFailoverDelegate(int failedServerID)
    {
-      log.info("Handling failure");
-      
-      //Get the connection factory we are going to failover onto
-      ClientConnectionFactoryDelegate newCF = getFailoverDelegate(failedConnection);
-  
-      ConnectionState state = (ConnectionState)((DelegateSupport)failedConnection).getState();
-      
-      log.info("calling createFailoverConnectionDelegate");
-      
-      int tries = 0;
-      
-      //We try a maximum of 10 hops
-      final int MAX_TRIES = 10;
-      
-      while (tries < MAX_TRIES)
-      {         
-         //Create a connection using that connection factory
-         CreateConnectionResult res =
-            newCF.createConnectionDelegate(state.getUser(), state.getPassword(), state.getServerID());
-         
-         log.info("returned from createFailoverConnectionDelegate");
-                     
-         if (res.getDelegate() != null)
+      // Look up the server to failover onto in the failover map
+
+      Integer failoverServerID = (Integer)failoverMap.get(new Integer(failedServerID));
+
+      for (int i = 0; i < delegates.length; i++)
+      {
+         if (delegates[i].getServerId() == failoverServerID.intValue())
          {
-            log.info("Got connection");
-            
-            //We got the right server and created a new connection ok
-            
-            ClientConnectionDelegate newConnection = (ClientConnectionDelegate)res.getDelegate();
-            
-            log.info("newconnection is " + newConnection);
-            
-            failover(failedConnection, newConnection);
-            
-            break;
+            return delegates[i];
          }
-         else
-         {
-            if (res.getActualFailoverNode() == -1)
-            {
-               //No trace of failover was detected on the server side - this might happen if the client side
-               //network fails temporarily so the client connection breaks but the server side network is still
-               //up and running - in this case we don't failover 
-               
-               //TODO Is this the right thing to do?
-               
-               log.trace("Client attempted to failover, but no failover had occurred on the server side");
-               
-               break;
-                           
-            }
-            else
-            {
-               //Server side failover has occurred / is occurring but we tried the wrong node
-               //Now we must try the correct node
-               
-               newCF = null;
-               
-               tries++;
-               
-               for (int i = 0; i < delegates.length; i++)
-               {
-                  ClientConnectionFactoryDelegate del = delegates[i];
-                  
-                  if (del.getServerId() == res.getActualFailoverNode())
-                  {
-                     newCF = del;
-                     
-                     break;
-                  }
-               }
-               
-               if (newCF == null)
-               {
-                  //Houston, we have a problem
-                  
-                  //TODO Could this ever happen? Should we send back the cf, or update it instead of just the id??
-                  throw new JMSException("Cannot find server with id " + res.getActualFailoverNode());
-               }               
-            }
-         }
       }
-      
-      if (tries == MAX_TRIES)
-      {
-         throw new JMSException("Cannot find correct server to failover onto");
-      }
+
+      return null;
    }
-   
-   private ClientConnectionFactoryDelegate getFailoverDelegate(ClientConnectionDelegate currentDelegate) throws JMSException
+
+   private void handleFailure(ClientConnectionDelegate failedConnDelegate) throws Exception
    {
-      //We need to choose which delegate to fail over to
-      
-      ConnectionState currentState = (ConnectionState)((DelegateSupport)currentDelegate).getState();
-      
-      int currentServerID = currentState.getServerID();
-      
-      //Lookup in the failover map to see which server to fail over onto
-      
-      Integer failoverServerID = (Integer)failoverMap.get(new Integer(currentServerID));
-      
-      if (failoverServerID == null)
+      ConnectionState failedConnState =
+         (ConnectionState)((DelegateSupport)failedConnDelegate).getState();
+
+      int failedServerID = failedConnState.getServerID();
+
+      log.debug(this + " handling failure on connection to node " + failedServerID);
+
+      // Get the default connection factory delegate we are going to failover onto
+
+      ClientConnectionFactoryDelegate failoverDelegate = getFailoverDelegate(failedServerID);
+
+      if (failoverDelegate == null)
       {
-         throw new IllegalStateException("Cannot find failover node for node " + currentServerID);
+         throw new IllegalStateException("Cannot find default failover node for server " +
+                                         failedServerID);
       }
-      
-      //Now find the actual delegate
-      
-      ClientConnectionFactoryDelegate del = null;
-      
-      for (int i = 0; i < delegates.length; i++)
+
+      // We attempt to connect to the failover node in a loop, since we might need to go through
+      // multiple hops
+
+      int attemptCount = 0;
+
+      outer: while (attemptCount < MAX_RECONNECT_HOP_COUNT)
       {
-         if (delegates[i].getServerId() == failoverServerID.intValue())
+         // Create a connection using that connection factory
+         CreateConnectionResult r = failoverDelegate.
+            createConnectionDelegate(failedConnState.getUser(),
+                                     failedConnState.getPassword(),
+                                     failedConnState.getServerID());
+
+         if (r.getDelegate() != null)
          {
-            del = delegates[i];
-            
-            break;
+            // We got the right server and created a new connection
+            performClientSideFailover(failedConnDelegate, (ClientConnectionDelegate)r.getDelegate());
+            return;
          }
+
+         // Did not get a valid connection to the node we've just tried
+
+         int actualServerID = r.getActualFailoverNode();
+
+         if (actualServerID == -1)
+         {
+            // No failover attempt was detected on the server side; this might happen if the client
+            // side network fails temporarily so the client connection breaks but the server cluster
+            // is still up and running - in this case we don't perform failover.
+
+            //TODO Is this the right thing to do?
+
+            log.warn("Client attempted failover, but no failover attempt " +
+                     "has been detected on the server side.");
+
+            return;
+         }
+
+         // Server side failover has occurred / is occurring but trying to go to the 'default'
+         // failover node did not succeed. Retry with the node suggested by the cluster.
+
+         attemptCount++;
+
+         for (int i = 0; i < delegates.length; i++)
+         {
+            if (delegates[i].getServerId() == actualServerID)
+            {
+               failoverDelegate = delegates[i];
+               continue outer;
+            }
+         }
+
+         // the delegate corresponding to the actualServerID not found among the cached delegates
+         //TODO Could this ever happen? Should we send back the cf, or update it instead of just the id??
+         throw new JMSException("Cannot find a cached connection factory delegate for " +
+                                "node " + actualServerID);
       }
-      
-      if (del == null)
-      {
-         throw new IllegalStateException("Cannot find failover delegate for node " + failoverServerID.intValue());
-      }
-           
-      return del;
+
+      throw new JMSException("Maximum number of failover attempts exceeded. " +
+                             "Cannot find a server to failover onto.");
    }
-   
-   private void failover(ClientConnectionDelegate failedConnection, ClientConnectionDelegate newConnection) throws Exception
+
+   private void performClientSideFailover(ClientConnectionDelegate failedConnDelegate,
+                                          ClientConnectionDelegate newConnDelegate) throws Exception
    {
-      if (trace) { log.trace("calling handleFailover"); }
-      
-      log.info("performing failover");
+      log.debug(this + " performing client side failover");
 
-      ConnectionState failedState = (ConnectionState)failedConnection.getState();
+      ConnectionState failedState = (ConnectionState)failedConnDelegate.getState();
+      ConnectionState newState = (ConnectionState)newConnDelegate.getState();
 
-      ConnectionState newState = (ConnectionState)newConnection.getState();
-      
       if (failedState.getClientID() != null)
       {
-         newConnection.setClientID(failedState.getClientID());
+         newConnDelegate.setClientID(failedState.getClientID());
       }
 
       // Transfer attributes from newDelegate to failedDelegate
-      failedConnection.copyAttributes(newConnection);
-      
+      failedConnDelegate.copyAttributes(newConnDelegate);
+
       int oldServerId = failedState.getServerID();
-      
+
       CallbackManager oldCallbackManager = failedState.getRemotingConnection().getCallbackManager();
-      
+
       //We need to update some of the attributes on the state
       failedState.copyState(newState);
-      
-      log.info("failing over children");
 
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
@@ -354,26 +355,26 @@
 
          ClientSessionDelegate failedSessionDelegate =
             (ClientSessionDelegate)failedSessionState.getDelegate();
-                  
-         ClientSessionDelegate newSessionDelegate = (ClientSessionDelegate)newConnection.
+
+         ClientSessionDelegate newSessionDelegate = (ClientSessionDelegate)newConnDelegate.
             createSessionDelegate(failedSessionState.isTransacted(),
                                   failedSessionState.getAcknowledgeMode(),
                                   failedSessionState.isXA());
-         
+
          SessionState newSessionState = (SessionState)newSessionDelegate.getState();
 
          failedSessionDelegate.copyAttributes(newSessionDelegate);
-         
+
          //We need to update some of the attributes on the state
-         newSessionState.copyState(newSessionState);                                  
-         
+         newSessionState.copyState(newSessionState);
+
          if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
-         
+
          List children = new ArrayList();
-         
+
          // TODO Why is this clone necessary?
          children.addAll(failedSessionState.getChildren());
-         
+
          Set consumerIds = new HashSet();
 
          for (Iterator j = children.iterator(); j.hasNext(); )
@@ -385,84 +386,84 @@
                handleFailoverOnProducer((ProducerState)sessionChild, newSessionDelegate);
             }
             else if (sessionChild instanceof ConsumerState)
-            {               
-               handleFailoverOnConsumer(failedConnection,
+            {
+               handleFailoverOnConsumer(failedConnDelegate,
                                         failedState,
                                         failedSessionState,
                                         (ConsumerState)sessionChild,
                                         failedSessionDelegate,
                                         oldServerId,
-                                        oldCallbackManager);       
-               
+                                        oldCallbackManager);
+
                // We add the new consumer id to the list of old ids
-               consumerIds.add(new Integer(((ConsumerState)sessionChild).getConsumerID()));               
+               consumerIds.add(new Integer(((ConsumerState)sessionChild).getConsumerID()));
             }
             else if (sessionChild instanceof BrowserState)
             {
                 handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
             }
          }
-                           
+
          /* Now we must sent the list of unacked AckInfos to the server - so the consumers
           * delivery lists can be repopulated
           */
          List ackInfos = null;
-         
+
          if (!failedSessionState.isTransacted() && !failedSessionState.isXA())
          {
             /*
             Now we remove any unacked np messages - this is because we don't want to ack them
             since the server won't know about them and will barf
             */
-            
+
             Iterator iter = newSessionState.getToAck().iterator();
-            
+
             while (iter.hasNext())
             {
                AckInfo info = (AckInfo)iter.next();
-               
+
                if (!info.getMessage().getMessage().isReliable())
                {
                   iter.remove();
-               }            
+               }
             }
-            
+
             //Get the ack infos from the list in the session state
             ackInfos = failedSessionState.getToAck();
          }
          else
-         {            
+         {
             //Transacted session - we need to get the acks from the resource manager
             //btw we have kept the old resource manager
             ResourceManager rm = failedState.getResourceManager();
-            
+
             // Remove any non persistent acks - so server doesn't barf on commit
-            
+
             rm.removeNonPersistentAcks(consumerIds);
-            
-            ackInfos = rm.getAckInfosForConsumerIds(consumerIds);            
+
+            ackInfos = rm.getAckInfosForConsumerIds(consumerIds);
          }
-         
+
          if (!ackInfos.isEmpty())
          {
             log.info("Sending " + ackInfos.size() + " unacked");
             newSessionDelegate.sendUnackedAckInfos(ackInfos);
-         }                 
+         }
       }
-            
+
       //TODO
       //If the session had consumers which are now closed then there is no way to recreate them on the server
       //we need to store with session id
-      
-      //We must not start the connection until the end
+
+      // We must not start the connection until the end
       if (failedState.isStarted())
       {
-         failedConnection.start();
+         failedConnDelegate.start();
       }
-      
-      log.info("Failover done");
+
+      log.info(this + " completed client-side failover");
    }
-   
+
    private void handleFailoverOnConsumer(ClientConnectionDelegate failedConnectionDelegate,
                                          ConnectionState failedConnectionState,
                                          SessionState failedSessionState,
@@ -472,12 +473,12 @@
                                          CallbackManager oldCallbackManager)
       throws JMSException
    {
-      log.info("Failing over consumer");
-      
+      log.debug(this + " failing over consumer " + failedConsumerState);
+
       ClientConsumerDelegate failedConsumerDelegate =
          (ClientConsumerDelegate)failedConsumerState.getDelegate();
 
-      if (trace) { log.trace("handleFailoverOnConsumer: creating alternate consumer"); }
+      if (trace) { log.trace(this + " creating alternate consumer"); }
 
       ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)failedSessionDelegate.
          createConsumerDelegate((JBossDestination)failedConsumerState.getDestination(),
@@ -487,60 +488,59 @@
                                  failedConsumerState.isConnectionConsumer(),
                                  failedConsumerState.getChannelId());
 
-      if (trace) { log.trace("handleFailoverOnConsumer: alternate consumer created"); }
-            
-      //Copy the attributes from the new consumer to the old consumer
+      if (trace) { log.trace(this + " alternate consumer created"); }
+
+      // Copy the attributes from the new consumer to the old consumer
       failedConsumerDelegate.copyAttributes(newConsumerDelegate);
 
       ConsumerState newState = (ConsumerState)newConsumerDelegate.getState();
-      
+
       int oldConsumerID = failedConsumerState.getConsumerID();
-      
-      //Update attributes on the old state
+
+      // Update attributes on the old state
       failedConsumerState.copyState(newState);
 
       if (failedSessionState.isTransacted() || failedSessionState.isXA())
       {
-         //Replace the old consumer id with the new consumer id
-         
+         // Replace the old consumer id with the new consumer id
+
          ResourceManager rm = failedConnectionState.getResourceManager();
-         
+
          rm.handleFailover(oldConsumerID, failedConsumerState.getConsumerID());
       }
-            
-      //We need to re-use the existing message callback handler
-            
-      log.info("Old server id:" + oldServerID + " old consumer id:" + oldConsumerID);
-      MessageCallbackHandler oldHandler = oldCallbackManager.unregisterHandler(oldServerID, oldConsumerID);
-      
+
+      // We need to re-use the existing message callback handler
+
+      MessageCallbackHandler oldHandler =
+         oldCallbackManager.unregisterHandler(oldServerID, oldConsumerID);
+
       ConnectionState newConnectionState = (ConnectionState)failedConnectionDelegate.getState();
-      
-      CallbackManager newCallbackManager = newConnectionState.getRemotingConnection().getCallbackManager();
-      
-      log.info("New server id:" + newConnectionState.getServerID() + " new consuer id:" + newState.getConsumerID());
-      
-      //Remove the new handler
-      MessageCallbackHandler newHandler = newCallbackManager.unregisterHandler(newConnectionState.getServerID(),
-                                                                               newState.getConsumerID());
-      
-      log.info("New handler is " + System.identityHashCode(newHandler));
-      
+
+      CallbackManager newCallbackManager =
+         newConnectionState.getRemotingConnection().getCallbackManager();
+
+      // Remove the new handler
+      MessageCallbackHandler newHandler = newCallbackManager.
+         unregisterHandler(newConnectionState.getServerID(), newState.getConsumerID());
+
+      log.debug("New handler is " + System.identityHashCode(newHandler));
+
       //But we need to update some fields from the new one
       oldHandler.copyState(newHandler);
-      
+
       //Now we re-register the old handler with the new callback manager
-            
+
       newCallbackManager.registerHandler(newConnectionState.getServerID(),
                                          newState.getConsumerID(),
                                          oldHandler);
-      
-      //We don't need to add the handler to the session state since it is already there - we
-      //are re-using the old handler
-      
-      log.info("failed over consumer");
+
+      // We don't need to add the handler to the session state since it is already there - we
+      // are re-using the old handler
+
+      log.debug(this + " failed over consumer");
    }
-   
 
+
    private void handleFailoverOnProducer(ProducerState failedProducerState,
                                          ClientSessionDelegate failedSessionDelegate)
       throws JMSException
@@ -552,9 +552,8 @@
          (ClientProducerDelegate)failedProducerState.getDelegate();
 
       failedProducerDelegate.copyAttributes(newProducerDelegate);
-      
       failedProducerState.copyState((ProducerState)newProducerDelegate.getState());
-      
+
       if (trace) { log.trace("handling fail over on producerDelegate " + failedProducerDelegate + " destination=" + failedProducerState.getDestination()); }
    }
 
@@ -563,56 +562,59 @@
       throws JMSException
    {
       ClientBrowserDelegate newBrowserDelegate = (ClientBrowserDelegate)failedSessionDelegate.
-          createBrowserDelegate(failedBrowserState.getJmsDestination(),failedBrowserState.getMessageSelector());
+         createBrowserDelegate(failedBrowserState.getJmsDestination(),
+                               failedBrowserState.getMessageSelector());
 
       ClientBrowserDelegate failedBrowserDelegate =
          (ClientBrowserDelegate)failedBrowserState.getDelegate();
 
       failedBrowserDelegate.copyAttributes(newBrowserDelegate);
-      
       failedBrowserState.copyState((BrowserState)newBrowserDelegate.getState());
-      
+
       if (trace) { log.trace("handling fail over on browserDelegate " + failedBrowserDelegate + " destination=" + failedBrowserState.getJmsDestination() + " selector=" + failedBrowserState.getMessageSelector()); }
 
    }
-   
-   private class Listener implements ConnectionListener
+
+   // Inner classes -------------------------------------------------
+
+   private class ConnectionFailureListener implements ConnectionListener
    {
-      private ClientConnectionDelegate connection;
+      private ClientConnectionDelegate cd;
       private Valve valve;
-      
-      Listener(ClientConnectionDelegate connection)
+
+      ConnectionFailureListener(ClientConnectionDelegate cd)
       {
-         this.connection = connection;
+         this.cd = cd;
          this.valve = new Valve();
-         
-         log.info("************* CREATING LISTENER");
       }
-      
+
+      // ConnectionListener implementation ---------------------------
+
       public void handleConnectionException(Throwable throwable, Client client)
       {
          try
          {
-            log.info("********* EXCEPTION DETECTED", throwable);
+            log.debug(this + " is being notified of connection failure: " + throwable);
 
-            // it references Valve to a local variable.
-            // Since we reset the valve at the end, we need to guarantee we will have the same Valve instance
-            // from the moment we enter this method.
+            // It references Valve to a local variable. Since we reset the valve at the end, we need
+            // to guarantee we will have the same Valve instance from the moment we entered this
+            // method.
+
             Valve localValve = null;
             synchronized (this)
             {
                localValve = valve;
             }
 
-            // We can't have more than one exception being caught at the same time.
-            // On that case we will open the valve and any other thread opening the valve
-            // will wait until its completion
+            // We can't have more than one exception being caught at the same time. On that case we
+            // will open the valve and any other thread opening the valve will wait until
+            // its completion.
+
             if (localValve.open())
             {
                try
                {
-                  log.info("********* HANDLING FAILOVER");
-                  handleFailure(connection);
+                  handleFailure(cd);
                }
                finally
                {
@@ -625,15 +627,19 @@
             }
             else
             {
-               log.info("********* ANOTHER THREAD WAS RESPONSIBLE FOR FAILOVER AS THE VALVE WAS CLOSED");
+               log.debug(this + ": Another thread was responsible for failover as the valve was closed");
             }
          }
          catch (Throwable e)
          {
             log.error("Caught exception in handling failure", e);
-            e.printStackTrace();
          }
       }
+
+      public String toString()
+      {
+         return "ConnectionFailureListener[" + Integer.toHexString(hashCode()) + "]";
+      }
    }
 }
 

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-13 07:05:09 UTC (rev 1782)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-13 09:46:39 UTC (rev 1783)
@@ -294,7 +294,7 @@
 
    public String toString()
    {
-      return "ClientConnectionFactoryDelegate[ID=" + id + "]";
+      return "ClientConnectionFactoryDelegate[" + id + "]";
    }
    
    public String getServerLocatorURI()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-13 07:05:09 UTC (rev 1782)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-13 09:46:39 UTC (rev 1783)
@@ -118,7 +118,7 @@
 
    public String toString()
    {
-      StringBuffer sb = new StringBuffer("ClusteredConnFactoryDelegate[ID=");
+      StringBuffer sb = new StringBuffer("ClusteredConnFactoryDelegate[");
       sb.append(id).append("][");
       if (delegates == null)
       {

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 07:05:09 UTC (rev 1782)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 09:46:39 UTC (rev 1783)
@@ -82,9 +82,9 @@
          log.info("######## KILLED NODE 1");
          log.info("########");
 
-         // TODO - this shouldn't be necessary if we have the client valve in place         
+         // TODO - this shouldn't be necessary if we have the client valve in place
          log.info("Sleeping for 1 min");
-         Thread.sleep(60000);
+         Thread.sleep(30000);
 
          // we must receive the message
 



From gavin.king at jboss.com  Wed Dec 13 05:09:12 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 05:09:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GuR32-000330-Gu@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 05:09:12

  Modified:    src/main/org/jboss/seam/contexts  EntityBean.java
  Log:
  better dirtychecking
  
  Revision  Changes    Path
  1.3       +5 -1      jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- EntityBean.java	13 Dec 2006 05:14:45 -0000	1.2
  +++ EntityBean.java	13 Dec 2006 10:09:12 -0000	1.3
  @@ -34,7 +34,11 @@
            {
               instance = null;
            }
  -      }
         return true;
      }
  +      else
  +      {
  +         return false;
  +      }
  +   }
   }
  
  
  


From gavin.king at jboss.com  Wed Dec 13 05:10:43 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 05:10:43 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/servlet  ...
Message-ID: <E1GuR4V-00035h-9q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 05:10:43

  Modified:    src/main/org/jboss/seam/servlet  SeamListener.java
  Log:
  GA
  
  Revision  Changes    Path
  1.19      +1 -1      jboss-seam/src/main/org/jboss/seam/servlet/SeamListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/servlet/SeamListener.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- SeamListener.java	27 Nov 2006 03:49:08 -0000	1.18
  +++ SeamListener.java	13 Dec 2006 10:10:43 -0000	1.19
  @@ -28,7 +28,7 @@
      private static final Log log = LogFactory.getLog(ServletContextListener.class);
   
      public void contextInitialized(ServletContextEvent event) {
  -      log.info("Welcome to Seam 1.1.0.CR2");
  +      log.info("Welcome to Seam 1.1.0.GA");
         Lifecycle.setServletContext( event.getServletContext() );
         new Initialization( event.getServletContext() ).init();
      }
  
  
  


From gavin.king at jboss.com  Wed Dec 13 05:10:43 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 05:10:43 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en  ...
Message-ID: <E1GuR4V-00035o-E3@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 05:10:43

  Modified:    doc/reference/en  master.xml
  Log:
  GA
  
  Revision  Changes    Path
  1.46      +1 -1      jboss-seam/doc/reference/en/master.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: master.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/master.xml,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- master.xml	29 Nov 2006 10:28:02 -0000	1.45
  +++ master.xml	13 Dec 2006 10:10:43 -0000	1.46
  @@ -29,7 +29,7 @@
       <bookinfo>
           <title>Seam - Contextual Components</title>
           <subtitle>A Framework for Java EE 5</subtitle>
  -        <releaseinfo>1.1.0.CR2</releaseinfo>
  +        <releaseinfo>1.1.0.GA</releaseinfo>
       </bookinfo>
   
       <toc/>
  
  
  


From gavin.king at jboss.com  Wed Dec 13 05:10:43 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 05:10:43 -0500
Subject: [jboss-cvs] jboss-seam    ...
Message-ID: <E1GuR4V-000361-Jw@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 05:10:43

  Modified:    jboss-seam    build.xml readme.txt changelog.txt
  Log:
  GA
  
  Revision  Changes    Path
  1.121     +1 -1      jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.120
  retrieving revision 1.121
  diff -u -b -r1.120 -r1.121
  --- build.xml	13 Dec 2006 02:58:57 -0000	1.120
  +++ build.xml	13 Dec 2006 10:10:43 -0000	1.121
  @@ -14,7 +14,7 @@
       <property name="Name"                 value="JBoss Seam"/>
       <property name="name"                 value="jboss-seam"/>
       <property name="version"              value="1.1"/>
  -    <property name="patchlevel"           value="0.CR2"/>
  +    <property name="patchlevel"           value="0.GA"/>
   
       <!-- set global properties for this build -->
       <property name="build.dir"            value="build"/>
  
  
  
  1.26      +1 -1      jboss-seam/readme.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: readme.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/readme.txt,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- readme.txt	27 Nov 2006 03:49:08 -0000	1.25
  +++ readme.txt	13 Dec 2006 10:10:43 -0000	1.26
  @@ -1,6 +1,6 @@
   JBoss Seam - Contextual Component framework for Java EE 5
   =========================================================
  -version 1.1.0.CR2, November 2006
  +version 1.1.0.GA, December 2006
   
   This software is distributed under the terms of the FSF Lesser Gnu
   Public License (see lgpl.txt).
  
  
  
  1.32      +31 -0     jboss-seam/changelog.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: changelog.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/changelog.txt,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- changelog.txt	30 Nov 2006 14:01:43 -0000	1.31
  +++ changelog.txt	13 Dec 2006 10:10:43 -0000	1.32
  @@ -1,5 +1,36 @@
   JBoss Seam Changelog
   ====================
  +Changes in version 1.1.0.GA (November 2006)
  +-------------------------------------------
  +** Bug
  +    * [JBSEAM-544] - PropertyNotFoundException from Namespace in test harness
  +    * [JBSEAM-547] - s:button generates multiple onclick attributes
  +    * [JBSEAM-551] - Session scoped SFSB's cannot be destroyed at HTTP session timeout
  +    * [JBSEAM-554] - seam-gen create screens
  +    * [JBSEAM-565] - NPE from @RequestParameter / @Destroy method
  +    * [JBSEAM-573] - Seam-managed persistence contexts and entities in the session
  +    * [JBSEAM-576] - NPE in EntityQuery - getPreviousFirstResult()
  +    * [JBSEAM-582] - Remoting examples are missing files.
  +
  +
  +** Feature Request
  +    * [JBSEAM-512] - Deployable WebLogic example
  +    * [JBSEAM-531] - Add debug project ant task (ide action) in the seam-gen generated project in Netbeans
  +    * [JBSEAM-549] - Throw meaningful exception if user tries to redirect during render phase.
  +    * [JBSEAM-550] - ProcessInstance lists
  +    * [JBSEAM-552] - use new compnents.xml format in seam-gen
  +    * [JBSEAM-553] - auto-add jdbc driver to eclipse classpath in seam-gen
  +    * [JBSEAM-555] - Support more attribute types in seam-gen templates
  +    * [JBSEAM-556] - <s:selectDate for="dateTextField">
  +    * [JBSEAM-557] - Use textarea for long text fields in seam-gen templates
  +    * [JBSEAM-558] - use required=true on not-null attributes in seam-gen templates
  +    * [JBSEAM-561] - Use precision and scale in f:convertNumber in seam-gen template
  +    * [JBSEAM-563] - Allow seam.properties to optionally be packaged in mete-inf directory.
  +    * [JBSEAM-574] - s:convertEnum
  +    * [JBSEAM-577] - Support page parameters with no value binding
  +    * [JBSEAM-584] - better navigation via "Done" button in seam-gen app
  +    * [JBSEAM-585] - use .page.xml files instead of @RequestParameter in seam-gen app 
  +
   Changes in version 1.1.0.CR2 (November 2006)
   --------------------------------------------
   ** Bug
  
  
  


From t2-okada at nri.co.jp  Wed Dec 13 05:11:42 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Wed, 13 Dec 2006 05:11:42 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/util ...
Message-ID: <E1GuR5S-00038F-61@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/13 05:11:42

  Modified:    java/src/expansion/org/jboss/profiler/exp/util  Tag:
                        JBossProfiler_Expansion HierarchicalMap.java
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +9 -0      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/util/Attic/HierarchicalMap.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HierarchicalMap.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/util/Attic/HierarchicalMap.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- HierarchicalMap.java	26 Oct 2006 08:58:57 -0000	1.1.2.1
  +++ HierarchicalMap.java	13 Dec 2006 10:11:42 -0000	1.1.2.2
  @@ -22,6 +22,7 @@
   
   package org.jboss.profiler.exp.util;
   
  +import java.util.Comparator;
   import java.util.SortedMap;
   import java.util.TreeMap;
   
  @@ -35,6 +36,14 @@
    */
   public class HierarchicalMap<K, V> extends TreeMap<K, V> {
       
  +    public HierarchicalMap() {
  +        super();
  +    }
  +
  +    public HierarchicalMap(Comparator<? super K> c) {
  +        super(c);
  +    }
  +
       /**
        * Returns partial map.
        * @param key - key object
  
  
  


From t2-okada at nri.co.jp  Wed Dec 13 05:11:42 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Wed, 13 Dec 2006 05:11:42 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector
	...
Message-ID: <E1GuR5S-00038T-A6@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/13 05:11:42

  Modified:    java/src/expansion/org/jboss/profiler/exp/agent/collector  
                        Tag: JBossProfiler_Expansion
                        ThreadMetricCollector.java CollectorConfig.java
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +9 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/Attic/ThreadMetricCollector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThreadMetricCollector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/Attic/ThreadMetricCollector.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- ThreadMetricCollector.java	10 Nov 2006 09:12:25 -0000	1.1.2.3
  +++ ThreadMetricCollector.java	13 Dec 2006 10:11:42 -0000	1.1.2.4
  @@ -22,6 +22,8 @@
   
   package org.jboss.profiler.exp.agent.collector;
   
  +import java.io.Serializable;
  +import java.util.Comparator;
   import java.util.EnumMap;
   import java.util.HashMap;
   import java.util.Map;
  @@ -136,7 +138,7 @@
               }
           }else {
               mmap = new EnumMap<MetricName, Metric>(MetricName.class);
  -            Map<String, Map<MetricName, Metric>> omap = new HierarchicalMap<String, Map<MetricName, Metric>>();
  +            Map<String, Map<MetricName, Metric>> omap = new HierarchicalMap<String, Map<MetricName, Metric>>(new ThreadIdComparator());
               omap.put(String.valueOf(threadId), mmap);
               metricsMap.put(category, omap);
           }
  @@ -216,4 +218,10 @@
           return result;
       }
   
  +    private class ThreadIdComparator implements Comparator<String>, Serializable {
  +        public int compare(String o1, String o2) {
  +            return Long.valueOf(o1).compareTo(Long.valueOf(o2));
  +        }
  +    }
  +
   }
  
  
  
  1.1.2.2   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/Attic/CollectorConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CollectorConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/Attic/CollectorConfig.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- CollectorConfig.java	10 Nov 2006 09:12:25 -0000	1.1.2.1
  +++ CollectorConfig.java	13 Dec 2006 10:11:42 -0000	1.1.2.2
  @@ -2,6 +2,7 @@
   
   import java.io.IOException;
   import java.io.InputStream;
  +import java.io.Serializable;
   import java.util.Map;
   import java.util.Set;
   
  @@ -14,7 +15,7 @@
   
   import org.apache.log4j.Logger;
   
  -public class CollectorConfig {
  +public class CollectorConfig implements Serializable {
       
       private static Logger logger = Logger.getLogger(CollectorConfig.class);
       
  
  
  


From t2-okada at nri.co.jp  Wed Dec 13 05:13:38 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Wed, 13 Dec 2006 05:13:38 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/lzx      ...
Message-ID: <E1GuR7K-0003A3-5b@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/13 05:13:38

  Modified:    java/webapp/lzx      Tag: JBossProfiler_Expansion
                        notifygridtext.lzx stacktracediagram.lzx
                        httprequeststatistics.lzx dataaccessstatistics.lzx
                        webapplicationanalyzer.lzx
  Log:
  Added some functions.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +9 -6      jboss-profiler/java/webapp/lzx/Attic/notifygridtext.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: notifygridtext.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/notifygridtext.lzx,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- notifygridtext.lzx	7 Nov 2006 06:49:05 -0000	1.1.2.2
  +++ notifygridtext.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  @@ -117,6 +117,9 @@
       <method name="_fireEvent">
         target[targetevent].sendEvent(parent.getSelection());
       </method>
  +    <method name="_inferSortpath">
  +      return this._textxpath;
  +    </method>
     </class>
     
   </library>
  \ No newline at end of file
  
  
  
  1.1.2.3   +28 -5     jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: stacktracediagram.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- stacktracediagram.lzx	13 Nov 2006 07:16:16 -0000	1.1.2.2
  +++ stacktracediagram.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  @@ -33,6 +33,13 @@
     <include href="linedrawview.lzx"/>
     <include href="floatingmessage.lzx"/>
     
  +  <class name="popupmessage" extends="basecomponent" bgcolor="0xffffff">
  +    <text name="_contents" fontsize="9" resize="true"/>
  +    <method name="setMessage" args="message">
  +      this._contents.setText(message);
  +    </method>
  +  </class>
  +  
     <class name="lane" extends="view"
           height="${parent.height}">
       
  @@ -66,9 +73,25 @@
           <method name="strokeLifeline">
             dottedLine(parent._centerPoint, 0, parent._centerPoint, parent.height);
           </method>
  -        <method name="strokeActivation" args="begin, elapsed">
  +        <method name="strokeActivation" args="begin, elapsed, elapsedTime">
             var width = parent.parent.activationwidth;
             offsetLine(parent._centerPoint-width/2, begin, width, elapsed, true);
  +          
  +          // creates a view to handle mouse events
  +          var activation = new LzView(this, {x:parent._centerPoint-width/2, y:begin, width:width, height:elapsed, clickable:true});
  +          activation.setAttribute("value", elapsedTime);
  +          new LzDelegate(this, "focusin", activation, "onmouseover");
  +          new LzDelegate(this, "focusout", activation, "onmouseout");
  +        </method>
  +        <method name="focusin" args="activation">
  +          var attr = {name:"message",
  +                      x:classroot.parent.parent.getMouse("x")+4,
  +                      y:classroot.parent.parent.getMouse("y")-16};
  +          var m = new popupmessage(classroot.parent.parent, attr);
  +          m.setMessage("Elapsed Time : "+activation.value);
  +        </method>
  +        <method name="focusout" args="activation">
  +          classroot.parent.parent.searchSubnodes("name", "message").destroy(true);
           </method>
         </linedrawview>
       </view>
  @@ -83,8 +106,8 @@
         this.objectbox.setWidth(this.objectbox.contents.objectname.width + 16);
         this.activationarea.drawview.strokeLifeline();
       </handler>
  -    <method name="setActivation" args="begin, elapsed">
  -      this.activationarea.drawview.strokeActivation(begin, elapsed);
  +    <method name="setActivation" args="begin, elapsed, elapsedTime">
  +      this.activationarea.drawview.strokeActivation(begin, elapsed, elapsedTime);
       </method>
     </class>
     
  @@ -217,7 +240,7 @@
                                             name,
                                             updateLane.activationwidth);
           }else {
  -          updateLane.setActivation(beginPixel, elapsedPixel);
  +          updateLane.setActivation(beginPixel, elapsedPixel, elapsedTime);
             if(i!=0) {
               messages.push({lane:updateLane, caller:caller, begin:beginPixel, elapsed:elapsedPixel, id:id, method:name});
             }
  
  
  
  1.1.2.3   +12 -0     jboss-profiler/java/webapp/lzx/Attic/httprequeststatistics.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: httprequeststatistics.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/httprequeststatistics.lzx,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- httprequeststatistics.lzx	7 Nov 2006 06:49:05 -0000	1.1.2.2
  +++ httprequeststatistics.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  @@ -77,6 +77,18 @@
                                           webappAnalyzerWarningSettings.subviews[0].color.getValue():null}">
             Elapsed Time
           </notifygridtext>
  +        <handler name="oninit">
  +          var del = new LzDelegate(this, "oncopy");
  +          LzKeys.callOnKeyCombo(del, ["control", "C"]);
  +        </handler>
  +        <method name="oncopy">
  +          var selectionDp = getSelection();
  +          var selectionString = selectionDp.getNodeAttribute("id") + ", ";
  +          selectionString += selectionDp.getNodeAttribute("name") + ", ";
  +          selectionString += selectionDp.getNodeAttribute("args") + ", ";
  +          selectionString += selectionDp.getNodeAttribute("value");
  +          LzBrowser.setClipboard(selectionString);
  +        </method>
         </grid>
         <method name="_applystyle" args="s">
           this.setBGColor(s.bordercolor);
  
  
  
  1.1.2.4   +12 -0     jboss-profiler/java/webapp/lzx/Attic/dataaccessstatistics.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: dataaccessstatistics.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/dataaccessstatistics.lzx,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- dataaccessstatistics.lzx	13 Nov 2006 07:16:16 -0000	1.1.2.3
  +++ dataaccessstatistics.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.4
  @@ -77,6 +77,18 @@
                                           webappAnalyzerWarningSettings.subviews[0].color.getValue():null}">
             Elapsed Time
           </notifygridtext>
  +        <handler name="oninit">
  +          var del = new LzDelegate(this, "oncopy");
  +          LzKeys.callOnKeyCombo(del, ["control", "C"]);
  +        </handler>
  +        <method name="oncopy">
  +          var selectionDp = getSelection();
  +          var selectionString = selectionDp.getNodeAttribute("id") + ", ";
  +          selectionString += selectionDp.getNodeAttribute("name") + ", ";
  +          selectionString += selectionDp.getNodeAttribute("args") + ", ";
  +          selectionString += selectionDp.getNodeAttribute("value");
  +          LzBrowser.setClipboard(selectionString);
  +        </method>
         </grid>
         <method name="_applystyle" args="s">
           this.setBGColor(s.bordercolor);
  
  
  
  1.1.2.3   +1 -1      jboss-profiler/java/webapp/lzx/Attic/webapplicationanalyzer.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: webapplicationanalyzer.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/webapplicationanalyzer.lzx,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- webapplicationanalyzer.lzx	12 Dec 2006 08:28:43 -0000	1.1.2.2
  +++ webapplicationanalyzer.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  @@ -134,7 +134,7 @@
         if(index>1) {
           canvas.executionPassageDetailData.setQueryParam(AppInfo.RPK_CALLER, caller);
         }
  -      canvas.executionPassageDetailData.doRequest();Debug.write("!");
  +      canvas.executionPassageDetailData.doRequest();
         new LzDelegate(this, "onDataLoaded", canvas.executionPassageDetailData, "ondata");
       </method>
       
  
  
  


From gavin.king at jboss.com  Wed Dec 13 05:17:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 05:17:10 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GuRAk-0003Ew-T6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 05:17:10

  Modified:    src/main/org/jboss/seam/core  Manager.java
  Log:
  JBSEAM-549
  
  Revision  Changes    Path
  1.124     +5 -1      jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.123
  retrieving revision 1.124
  diff -u -b -r1.123 -r1.124
  --- Manager.java	27 Nov 2006 03:09:35 -0000	1.123
  +++ Manager.java	13 Dec 2006 10:17:10 -0000	1.124
  @@ -42,7 +42,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.123 $
  + * @version $Revision: 1.124 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -916,6 +916,10 @@
       */
      public void redirect(String viewId, Map<String, Object> parameters, boolean includeConversationId)
      {
  +      if ( Lifecycle.getPhaseId()==PhaseId.RENDER_RESPONSE )
  +      {
  +         throw new IllegalStateException("attempted to redirect during RENDER_RESPONSE phase");
  +      }
         FacesContext context = FacesContext.getCurrentInstance();
         String url = context.getApplication().getViewHandler().getActionURL(context, viewId);
         if (parameters!=null) 
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 05:50:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 05:50:35 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59008 - branches/Branch_4_2/build
Message-ID: <E1GuRh5-0003of-Rm@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-13 05:50:33 -0500 (Wed, 13 Dec 2006)
New Revision: 59008

Modified:
   branches/Branch_4_2/build/build.xml
Log:
JBAS-3922, move entity-resolver-manager dir inside examples/varia

Modified: branches/Branch_4_2/build/build.xml
===================================================================
--- branches/Branch_4_2/build/build.xml	2006-12-12 23:50:32 UTC (rev 59007)
+++ branches/Branch_4_2/build/build.xml	2006-12-13 10:50:33 UTC (rev 59008)
@@ -231,7 +231,7 @@
     <property name="install.examples.jbossweb" value="${install.examples}/jbossweb"/>
     <property name="install.examples.netboot" value="${install.examples}/netboot"/>
     <property name="install.examples.binding-manager" value="${install.examples}/binding-manager"/>
-    <property name="install.examples.entity-resolver-manager" value="${install.examples}/entity-resolver-manager"/>
+    <property name="install.examples.entity-resolver-manager" value="${install.examples}/varia/entity-resolver-manager"/>
     <property name="install.examples.varia" value="${install.examples}/varia"/>
     <property name="install.dtd" value="${install.docs}/dtd"/>
     <property name="install.schema" value="${install.docs}/schema"/>



From gavin.king at jboss.com  Wed Dec 13 06:06:20 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 06:06:20 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GuRwK-0004Gh-DY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 06:06:20

  Modified:    doc/reference/en/modules  concepts.xml
  Log:
  note more efficient impl
  
  Revision  Changes    Path
  1.45      +7 -5      jboss-seam/doc/reference/en/modules/concepts.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: concepts.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/concepts.xml,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- concepts.xml	30 Nov 2006 02:15:22 -0000	1.44
  +++ concepts.xml	13 Dec 2006 11:06:20 -0000	1.45
  @@ -934,9 +934,11 @@
   
           <para> 
               For session or conversation scoped entity bean components, Seam automatically forces replication to occur
  -            by calling <literal>setAttribute()</literal> once in every request. This strategy is not efficient, so
  -            session or conversation scope entity beans should be used with care. You can always write a stateful session
  -            bean or JavaBean component to "manage" the entity bean instance. For example, 
  +            by calling <literal>setAttribute()</literal> once in every request, <emphasis>unless the entity is currently 
  +            associated with a Seam-managed persistence context, in which case no replication is needed</emphasis>. This 
  +            strategy is not necessarily efficient, so session or conversation scope entity beans should be used with care. 
  +            You can always write a stateful session bean or JavaBean component to "manage" the entity bean instance. 
  +            For example, 
           </para>
   
           <programlisting><![CDATA[@Stateful
  @@ -956,8 +958,8 @@
   }]]></programlisting>
   
           <para> 
  -            Note that the <literal>EntityHome</literal> class in the Seam Framework provides a great example of this
  -            pattern. 
  +            Note that the <literal>EntityHome</literal> class in the Seam Application Framework provides a great example 
  +            of this pattern. 
           </para>
   
       </sect1>
  
  
  


From gavin.king at jboss.com  Wed Dec 13 06:07:05 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 06:07:05 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GuRx3-0004II-OW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 06:07:05

  Modified:    doc/reference/en/modules  concepts.xml
  Log:
  note more efficient impl
  
  Revision  Changes    Path
  1.46      +5 -5      jboss-seam/doc/reference/en/modules/concepts.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: concepts.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/concepts.xml,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- concepts.xml	13 Dec 2006 11:06:20 -0000	1.45
  +++ concepts.xml	13 Dec 2006 11:07:05 -0000	1.46
  @@ -934,11 +934,11 @@
   
           <para> 
               For session or conversation scoped entity bean components, Seam automatically forces replication to occur
  -            by calling <literal>setAttribute()</literal> once in every request, <emphasis>unless the entity is currently 
  -            associated with a Seam-managed persistence context, in which case no replication is needed</emphasis>. This 
  -            strategy is not necessarily efficient, so session or conversation scope entity beans should be used with care. 
  -            You can always write a stateful session bean or JavaBean component to "manage" the entity bean instance. 
  -            For example, 
  +            by calling <literal>setAttribute()</literal> once in every request, <emphasis>unless the (conversation-scoped) 
  +            entity is currently associated with a Seam-managed persistence context, in which case no replication is 
  +            needed</emphasis>. This strategy is not necessarily efficient, so session or conversation scope entity beans 
  +            should be used with care. You can always write a stateful session bean or JavaBean component to "manage" the 
  +            entity bean instance. For example, 
           </para>
   
           <programlisting><![CDATA[@Stateful
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 06:12:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 06:12:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59009 - in
	projects/ejb3/trunk/injection/src: . test test/java
	test/java/org test/java/org/jboss test/java/org/jboss/injection
Message-ID: <E1GuS2Q-0004P6-0r@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-13 06:12:34 -0500 (Wed, 13 Dec 2006)
New Revision: 59009

Added:
   projects/ejb3/trunk/injection/src/test/
   projects/ejb3/trunk/injection/src/test/java/
   projects/ejb3/trunk/injection/src/test/java/org/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/
Log:
First prototype



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 06:13:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 06:13:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r59010 - in projects/ejb3/trunk/injection:
	. src/main/java/org/jboss/injection
	src/main/java/org/jboss/injection/aop
	src/main/java/org/jboss/injection/lang/reflect
	src/test/java/org/jboss/injection/test
	src/test/java/org/jboss/injection/test/annotated
	src/test/java/org/jboss/injection/test/annotated/unit
	src/test/java/org/jboss/injection/test/programatically
	src/test/java/org/jboss/injection/test/programatically/unit
Message-ID: <E1GuS36-0004PQ-QV@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-13 06:12:42 -0500 (Wed, 13 Dec 2006)
New Revision: 59010

Added:
   projects/ejb3/trunk/injection/.classpath
   projects/ejb3/trunk/injection/.project
   projects/ejb3/trunk/injection/README.txt
   projects/ejb3/trunk/injection/pom.xml
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractInjector.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injection.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectionProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injector.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorFactory.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiInjectorFactory.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiPropertyInjector.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapInjectorFactory.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapPropertyInjector.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceClassProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceInjectorFactory.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourcePropertyProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/SimpleValueInjector.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/annotation/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/jndi/
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/simple/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Simple.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/SimplePropertyProcessor.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java
Modified:
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/FieldBeanProperty.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/MethodBeanProperty.java
Log:
First prototype

Added: projects/ejb3/trunk/injection/.classpath
===================================================================
--- projects/ejb3/trunk/injection/.classpath	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/.classpath	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src/main/java"/>
+	<classpathentry kind="src" output="target/eclipse-test-classes" path="src/test/java"/>
+	<classpathentry kind="src" output="target/eclipse-test-classes" path="src/test/resources"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="var" path="M2_REPO/apache-slide/webdavlib/2.0/webdavlib-2.0.jar"/>
+	<classpathentry kind="var" path="M2_REPO/trove/trove/2.1.1/trove-2.1.1.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-aop/2.0.0.alpha2/jboss-aop-2.0.0.alpha2.jar"/>
+	<classpathentry kind="var" path="M2_REPO/oswego-concurrent/concurrent/1.3.4/concurrent-1.3.4.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-ejb3x/1.0.0.CR1/jboss-ejb3x-1.0.0.CR1.jar" sourcepath="M2_REPO/jboss/jboss-ejb3x/1.0.0.CR1/jboss-ejb3x-1.0.0.CR1-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/apache-xerces/xml-apis/2.7.1/xml-apis-2.7.1.jar"/>
+	<classpathentry kind="var" path="M2_REPO/javassist/javassist/3.4.GA/javassist-3.4.GA.jar"/>
+	<classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar" sourcepath="M2_REPO/junit/junit/3.8.1/junit-3.8.1-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/apache-httpclient/commons-httpclient/2.0.2/commons-httpclient-2.0.2.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-logging-spi/2.0.2.GA/jboss-logging-spi-2.0.2.GA.jar" sourcepath="M2_REPO/jboss/jboss-logging-spi/2.0.2.GA/jboss-logging-spi-2.0.2.GA-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-j2ee/4.0.2/jboss-j2ee-4.0.2.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-common-core/2.0.2.GA/jboss-common-core-2.0.2.GA.jar" sourcepath="M2_REPO/jboss/jboss-common-core/2.0.2.GA/jboss-common-core-2.0.2.GA-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-logging-log4j/2.0.2.GA/jboss-logging-log4j-2.0.2.GA.jar"/>
+	<classpathentry kind="output" path="target/eclipse-classes"/>
+</classpath>

Added: projects/ejb3/trunk/injection/.project
===================================================================
--- projects/ejb3/trunk/injection/.project	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/.project	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,14 @@
+<projectDescription>
+  <name>injection</name>
+  <comment>JBoss POJO Injection Framework</comment>
+  <projects/>
+  <buildSpec>
+    <buildCommand>
+      <name>org.eclipse.jdt.core.javabuilder</name>
+      <arguments/>
+    </buildCommand>
+  </buildSpec>
+  <natures>
+    <nature>org.eclipse.jdt.core.javanature</nature>
+  </natures>
+</projectDescription>
\ No newline at end of file

Added: projects/ejb3/trunk/injection/README.txt
===================================================================
--- projects/ejb3/trunk/injection/README.txt	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/README.txt	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,23 @@
+Injection Framework
+
+With the injection framework it should be possible to easily inject
+values into beans. Note that the injection framework doesn't specify
+properties of a bean in the same way as JavaBeans does. Any field or
+setter method can constitute a property.
+
+The injection works in two phases:
+1. Setup of the environment
+2. Injection of objects
+
+The environment could be setup in JNDI, but this is not required
+by the injection framework. For JNDI setup an implementation is
+provided.
+
+Injection of objects can be specified programatically. For
+annotation based injection an implementation is provided.
+
+It's not IoC or MC injection, because it doesn't take into
+account dependencies.
+
+Although the injection framework contains annotation processors JSR-269
+is left out of scope.
\ No newline at end of file

Added: projects/ejb3/trunk/injection/pom.xml
===================================================================
--- projects/ejb3/trunk/injection/pom.xml	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/pom.xml	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,156 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>jboss</groupId>
+  <artifactId>injection</artifactId>
+  <packaging>jar</packaging>
+  <version>1.0-SNAPSHOT</version>
+  <name>injection</name>
+  <url>http://www.jboss.org</url>
+  <description>JBoss POJO Injection Framework</description>
+
+  <licenses>
+    <license>
+      <name>lgpl</name>
+      <url>http://repository.jboss.com/licenses/lgpl.txt</url>
+    </license>
+  </licenses>
+
+  <organization>
+    <name>JBoss, Red Hat Middleware LLC</name>
+    <url>http://www.jboss.org</url>
+  </organization>
+
+  <repositories>
+    <repository>
+      <id>jboss</id>
+      <name>JBoss Inc. Repository</name>
+      <layout>default</layout>
+      <url>http://repository.jboss.com/maven2/</url>
+      <snapshots>
+        <enabled>true</enabled>
+      </snapshots>
+    </repository>
+  </repositories>
+
+  <pluginRepositories>
+     <pluginRepository>
+        <id>jbosspluginrepo</id>
+        <name>jboss plugin repository</name>
+        <url>http://repository.jboss.com/maven2</url>
+        <layout>default</layout>
+        <snapshots>
+           <enabled>false</enabled>
+           <updatePolicy>never</updatePolicy>
+        </snapshots>
+     </pluginRepository>
+  </pluginRepositories>
+
+  <build>
+    <!--sourceDirectory>src/main</sourceDirectory-->
+    <!--finalName>${artifactId}</finalName-->
+    <plugins>
+      <!-- define how we want compilation to take place
+           here, we accept most of the defaults but say that we want the
+           optimization flag set, and define the source and target to be 1.4,
+           these setting will be inherited by child projects -->
+      <plugin>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <version>2.0</version>
+          <configuration>
+              <optimize>true</optimize>
+              <source>1.5</source>
+              <target>1.5</target>
+          </configuration>
+      </plugin>  
+
+      <!-- define that we wish to create src jars -->
+      <plugin>
+        <artifactId>maven-source-plugin</artifactId>
+        <inherited>true</inherited>
+        <executions>
+          <execution>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <argLine>-ea</argLine>
+          <!-- doesn't work either
+          <argLine>-Djava.system.class.loader=org.jboss.aop.standalone.SystemClassLoader -cp ${localRepository}</argLine>
+          -->
+          <excludes>
+            <!-- exclude simple because it requires AOP -->
+            <exclude>org/jboss/injection/test/simple/unit/SimpleTestCase.java</exclude>
+          </excludes>
+          <!-- doesn't work
+          <systemProperties>
+            <property>
+              <name>java.system.class.loader</name>
+              <value>org.jboss.aop.standalone.SystemClassLoader</value>
+            </property>
+          </systemProperties>
+          -->
+        </configuration>
+      </plugin>
+      
+    </plugins>
+  </build>
+  
+  <dependencies>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-aop</artifactId>
+      <version>2.0.0.alpha2</version>
+    </dependency>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-ejb3x</artifactId>
+      <version>1.0.0.CR1</version>
+    </dependency>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-logging-log4j</artifactId>
+      <version>2.0.2.GA</version>
+      <scope>test</scope>
+    </dependency>
+    <!-- TODO: or do we want jboss-common-core? -->
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-logging-spi</artifactId>
+      <version>2.0.2.GA</version>
+    </dependency>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+
+    <!-- non-transitive dependencies from aop -->
+    <dependency>
+      <groupId>javassist</groupId>
+      <artifactId>javassist</artifactId>
+      <version>3.4.GA</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-common-core</artifactId>
+      <version>2.0.2.GA</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>trove</groupId>
+      <artifactId>trove</artifactId>
+      <version>2.1.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+</project>

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractInjector.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractInjector.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractInjector.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.logging.Logger;
+
+/**
+ * Injects a single property.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public abstract class AbstractInjector implements Injector
+{
+   private static final Logger log = Logger.getLogger(AbstractInjector.class);
+   
+   private BeanProperty property;
+   
+   protected AbstractInjector(BeanProperty property)
+   {
+      assert property != null;
+      
+      this.property = property;
+   }
+   
+   public void inject(Object instance)
+   {
+      Object value = getValue();
+      if(log.isTraceEnabled())
+         log.trace("injecting property " + property + " with value " + value);
+      property.set(instance, value);
+   }
+   
+   protected abstract Object getValue();
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AbstractProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+/**
+ * Makes it easier to return an empty injector collection.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public abstract class AbstractProcessor<T> implements InjectionProcessor<T>
+{
+   public abstract Injector processOne(T t);
+   
+   public Collection<Injector> process(T t)
+   {
+      Collection<Injector> list = new ArrayList<Injector>();
+      Injector injector = processOne(t);
+      if(injector != null)
+         list.add(injector);
+      return list;
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,54 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.lang.annotation.Annotation;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ * @deprecated NYI
+ */
+public class AnnotatedPropertyProcessor<FactoryType extends InjectorFactory, AnnotationType extends Annotation> extends AbstractProcessor<BeanProperty>
+{
+   private FactoryType factory;
+   
+   protected AnnotatedPropertyProcessor(FactoryType factory)
+   {
+      assert factory != null;
+      
+      this.factory = factory;
+   }
+   
+   public Injector processOne(BeanProperty property)
+   {
+      throw new RuntimeException("NYI");
+//      AnnotationType resource = property.getAnnotation(AnnotationType);
+//      if(resource == null) return null;
+//      
+//      return factory.create(property, resource);
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,81 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Collection;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.injection.lang.reflect.FieldBeanProperty;
+import org.jboss.injection.lang.reflect.MethodBeanProperty;
+
+/**
+ * Processes the properties of a class for injection.
+ * 
+ * Usually used to find annotations on properties.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class ClassPropertyProcessor implements InjectionProcessor<Class<?>>
+{
+   private InjectionProcessor<BeanProperty> propertyProcessor;
+   
+   public ClassPropertyProcessor(InjectionProcessor<BeanProperty> propertyProcessor)
+   {
+      assert propertyProcessor != null;
+      
+      this.propertyProcessor = propertyProcessor;
+   }
+   
+   /**
+    * Find all properties defined in the class and pass
+    * the property to the propertyProcessor.
+    * 
+    * @param cls
+    */
+   public Collection<Injector> process(Class<?> cls)
+   {
+      Collection<Injector> list = new ArrayList<Injector>();
+      
+      Field fields[] = cls.getDeclaredFields();
+      for(Field field : fields)
+      {
+         BeanProperty property = new FieldBeanProperty(field);
+         list.addAll(propertyProcessor.process(property));
+      }
+      
+      Method methods[] = cls.getDeclaredMethods();
+      for(Method method : methods)
+      {
+         if(MethodBeanProperty.isValid(method))
+         {
+            BeanProperty property = new MethodBeanProperty(method);
+            list.addAll(propertyProcessor.process(property));
+         }
+      }
+      
+      return list;
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injection.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injection.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injection.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,65 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.util.ArrayList;
+import java.util.Collection;
+
+/**
+ * The facade for the injection framework.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class Injection
+{
+   /**
+    * Fires of a collection of processors on a given object.
+    * 
+    * @param <T1>   the object type
+    * @param <T2>   the generic type of the resultant collection
+    * @param t      the object on which processing takes place
+    * @param c      the collection of processors
+    * @return       the resultant collection
+    */
+   public static <T1, T2> Collection<T2> doIt(T1 t, Collection<Processor<T1, Collection<T2>>> c)
+   {
+      Collection<T2> list = new ArrayList<T2>();
+      for(Processor<T1, Collection<T2>> processor : c)
+      {
+         list.addAll(processor.process(t));
+      }
+      return list;
+   }
+   
+   /**
+    * Process an object for injection.
+    * Find out which injectors are registered for this object's class and
+    * run them.
+    * 
+    * @param instance
+    */
+   public static void process(Object instance)
+   {
+      
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectionProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectionProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectionProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.util.Collection;
+
+/**
+ * Processes objects to produce injector lists.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface InjectionProcessor<T> extends Processor<T, Collection<Injector>>
+{
+
+}

Copied: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injector.java (from rev 58873, trunk/ejb3/src/main/org/jboss/injection/Injector.java)
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/Injector.java	2006-12-06 18:05:12 UTC (rev 58873)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Injector.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,33 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.injection;
+
+/**
+ * Inject something into an object.
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision$
+ */
+public interface Injector
+{
+   void inject(Object instance);
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorFactory.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorFactory.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorFactory.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Creates injector based on some sort of metaData.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface InjectorFactory<T>
+{
+   Injector create(BeanProperty property, T metaData);
+}

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -21,6 +21,10 @@
  */
 package org.jboss.injection;
 
+import java.lang.reflect.InvocationTargetException;
+import java.lang.reflect.Method;
+import java.util.Collection;
+
 /**
  * Processes instances by injecting their properties and calling their postconstructs.
  *
@@ -29,8 +33,61 @@
  */
 public class InjectorProcessor
 {
-   public static void process(Object instance)
+   public static void process(Object instance, Collection<Injector> injectors, Collection<Method> postConstructs)
    {
+      assert instance != null;
+      assert injectors != null;
+      assert postConstructs != null : "postConstructs is null";
       
+      for(Injector injector : injectors)
+      {
+         injector.inject(instance);
+      }
+      
+      Class<?> cls = instance.getClass();
+      for(Method method : postConstructs)
+      {
+         Object obj;
+         if(cls.isAssignableFrom(method.getDeclaringClass()))
+         {
+            obj = instance;
+         }
+         else
+         {
+            try
+            {
+               // TODO: this is probably a bad idea
+               obj = method.getDeclaringClass().newInstance();
+            }
+            catch (InstantiationException e)
+            {
+               throw new RuntimeException(e);
+            }
+            catch (IllegalAccessException e)
+            {
+               throw new RuntimeException(e);
+            }
+         }
+         Object args[] = null;
+         method.setAccessible(true);
+         try
+         {
+            method.invoke(obj, args);
+         }
+         catch (IllegalAccessException e)
+         {
+            // should not happen
+            throw new RuntimeException(e);
+         }
+         catch (InvocationTargetException e)
+         {
+            Throwable t = e.getCause();
+            if(t instanceof Error)
+               throw (Error) t;
+            if(t instanceof RuntimeException)
+               throw (RuntimeException) t;
+            throw new RuntimeException(t);
+         }
+      }
    }
 }

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiInjectorFactory.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiInjectorFactory.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiInjectorFactory.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,45 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Creates a JNDI property injector based on a Resource annotation.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class JndiInjectorFactory implements InjectorFactory<String>
+{
+   /* (non-Javadoc)
+    * @see org.jboss.injection.InjectorFactory#create(org.jboss.injection.lang.reflect.BeanProperty, java.lang.Object)
+    */
+   public Injector create(BeanProperty property, String name)
+   {
+      assert property != null;
+      assert name != null;
+      
+      return new JndiPropertyInjector(property, name);
+   }
+
+}

Copied: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiPropertyInjector.java (from rev 58873, trunk/ejb3/src/main/org/jboss/injection/JndiPropertyInjector.java)
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/JndiPropertyInjector.java	2006-12-06 18:05:12 UTC (rev 58873)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/JndiPropertyInjector.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,105 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.logging.Logger;
+
+/**
+ * Injects a jndi dependency into a bean property.
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class JndiPropertyInjector implements Injector
+{
+   @SuppressWarnings("unused")
+   private static final Logger log = Logger.getLogger(JndiPropertyInjector.class);
+   
+   private BeanProperty property;
+   private String jndiName;
+   private Context ctx;
+
+   public JndiPropertyInjector(BeanProperty property)
+   {
+      this(property, property.getDeclaringClass().getName() + "/" + property.getName());
+   }
+   
+   public JndiPropertyInjector(BeanProperty property, String relativeJndiName)
+   {
+      this(property, relativeJndiName, getContext("java:comp/env"));
+   }
+   
+   public JndiPropertyInjector(BeanProperty property, String relativeJndiName, Context ctx)
+   {
+      assert property != null;
+      assert relativeJndiName != null;
+      assert ctx != null;
+      
+      this.property = property;
+      this.jndiName = relativeJndiName;
+      this.ctx = ctx;
+   }
+   
+   private static Context getContext(String jndiName)
+   {
+      try
+      {
+         return (Context) new InitialContext().lookup(jndiName);
+      }
+      catch(NamingException e)
+      {
+         throw new RuntimeException(e);
+      }
+   }
+   
+   public Class<?> getInjectionClass()
+   {
+      return property.getType();
+   }
+   
+   protected Object lookup(String jndiName)
+   {
+      Object dependency = null;
+      
+      try
+      {
+         dependency = ctx.lookup(jndiName);
+      }
+      catch (NamingException e)
+      {
+         throw new RuntimeException("Unable to inject jndi dependency: " + jndiName + " into property " + property, e);
+      }
+      return dependency;
+   }
+   
+   public void inject(Object instance)
+   {
+      Object value = lookup(jndiName);
+      property.set(instance, value);
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapInjectorFactory.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapInjectorFactory.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapInjectorFactory.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.util.Map;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class MapInjectorFactory implements InjectorFactory<String>
+{
+   private Map<String, Object> map;
+   
+   public MapInjectorFactory(Map<String, Object> map)
+   {
+      assert map != null;
+      
+      this.map = map;
+   }
+   
+   public Injector create(BeanProperty property, String name)
+   {
+      assert property != null;
+      
+      if(name == null) return null;
+      
+      return new MapPropertyInjector(property, map, name);
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapPropertyInjector.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapPropertyInjector.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/MapPropertyInjector.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.util.Map;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Injects a value from a map.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class MapPropertyInjector extends AbstractInjector
+{
+   private Map<String, Object> map;
+   private String name;
+   
+   public MapPropertyInjector(BeanProperty property, Map<String, Object> map, String name)
+   {
+      super(property);
+      
+      assert map != null;
+      assert name != null;
+      
+      this.map = map;
+      this.name = name;
+   }
+
+   @Override
+   protected Object getValue()
+   {
+      return map.get(name);
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Collection;
+
+import javax.annotation.PostConstruct;
+
+/**
+ * Scans a class for PostConstruct annotations.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class PostConstructProcessor implements Processor<Class<?>, Collection<Method>>
+{
+   public Collection<Method> process(Class<?> cls)
+   {
+      Collection<Method> list = new ArrayList<Method>();
+      if(cls == null) return list;
+      
+      Method methods[] = cls.getDeclaredMethods();
+      for(Method method : methods)
+      {
+         PostConstruct pc = method.getAnnotation(PostConstruct.class);
+         if(pc != null)
+         {
+            list.add(method);
+         }
+      }
+      
+      list.addAll(process(cls.getSuperclass()));
+      
+      return list;
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+/**
+ * Processes an object to produce something.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface Processor<T1, T2>
+{
+   T2 process(T1 t);
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceClassProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceClassProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceClassProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+/**
+ * Processes Resource annotation on classes for injection. 
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class ResourceClassProcessor extends ClassPropertyProcessor
+{
+   public ResourceClassProcessor(InjectorFactory<String> factory)
+   {
+      super(new ResourcePropertyProcessor(factory));
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceInjectorFactory.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceInjectorFactory.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourceInjectorFactory.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import javax.annotation.Resource;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public interface ResourceInjectorFactory extends InjectorFactory<Resource>
+{
+
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourcePropertyProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourcePropertyProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ResourcePropertyProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,56 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import javax.annotation.Resource;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class ResourcePropertyProcessor extends AbstractProcessor<BeanProperty>
+{
+   private InjectorFactory<String> factory;
+   
+   protected ResourcePropertyProcessor(InjectorFactory<String> factory)
+   {
+      assert factory != null;
+      
+      this.factory = factory;
+   }
+   
+   public Injector processOne(BeanProperty property)
+   {
+      Resource resource = property.getAnnotation(Resource.class);
+      if(resource == null) return null;
+      
+      String name = resource.name();
+      if(name.equals(""))
+         name = property.getDeclaringClass().getName() + "/" + property.getName();
+      
+      return factory.create(property, name);
+   }
+}

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/SimpleValueInjector.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/SimpleValueInjector.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/SimpleValueInjector.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,49 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Injects the set value into a property.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class SimpleValueInjector implements Injector
+{
+   private BeanProperty property;
+   private Object value;
+   
+   public SimpleValueInjector(BeanProperty property, Object value)
+   {
+      assert property != null;
+      
+      this.property = property;
+      this.value = value;
+   }
+   
+   public void inject(Object instance)
+   {
+      property.set(instance, value);
+   }
+}

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -40,7 +40,8 @@
 
    public Object invoke(Invocation invocation) throws Throwable
    {
-      InjectorProcessor.process(invocation.getTargetObject());
+      System.err.println("here");
+      //InjectorProcessor.process(invocation.getTargetObject());
       return invocation.invokeNext();
    }
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/AbstractAccessibleObjectBeanProperty.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -21,6 +21,7 @@
  */
 package org.jboss.injection.lang.reflect;
 
+import java.lang.annotation.Annotation;
 import java.lang.reflect.AccessibleObject;
 
 /**
@@ -40,8 +41,13 @@
       obj.setAccessible(true);
    }
    
-   public T getAccessibleObject()
+   protected T getAccessibleObject()
    {
       return obj;
    }
+   
+   public <T1 extends Annotation> T1 getAnnotation(Class<T1> annotationClass)
+   {
+      return obj.getAnnotation(annotationClass);
+   }
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/BeanProperty.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -21,7 +21,7 @@
  */
 package org.jboss.injection.lang.reflect;
 
-import java.lang.reflect.AccessibleObject;
+import java.lang.annotation.Annotation;
 
 /**
  * A bean property defines a propery of a pojo from the EJB3 point of view.
@@ -32,8 +32,7 @@
  */
 public interface BeanProperty
 {
-   // TODO: should not be exposed
-   AccessibleObject getAccessibleObject();
+   <T extends Annotation> T getAnnotation(Class<T> annotationClass);
    
    Class<?> getDeclaringClass();
    

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/FieldBeanProperty.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/FieldBeanProperty.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/FieldBeanProperty.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -85,4 +85,9 @@
          throw new IllegalArgumentException(msg);
       }
    }
+   
+   public String toString()
+   {
+      return super.toString() + "{" + getDeclaringClass() + "/" + getName() + "}";
+   }
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/MethodBeanProperty.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/MethodBeanProperty.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/lang/reflect/MethodBeanProperty.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -46,7 +46,7 @@
       super(method);
       
       assert method.getReturnType() == Void.TYPE;
-      assert method.getParameterTypes().length == 1;
+      assert method.getParameterTypes().length == 1 : "invalid number of parameters on " + method;
       assert method.getName().startsWith("set");
    }
 
@@ -83,6 +83,14 @@
       return getMethod().getParameterTypes()[0];
    }
    
+   public static boolean isValid(Method method)
+   {
+      if(method.getReturnType() != Void.TYPE) return false;
+      if(method.getParameterTypes().length != 1) return false;
+      if(!method.getName().startsWith("set")) return false;
+      return true;
+   }
+   
    /* (non-Javadoc)
     * @see org.jboss.injection.lang.reflect.BeanProperty#set(java.lang.Object, java.lang.Object)
     */
@@ -115,5 +123,9 @@
          throw new RuntimeException(cause);
       }
    }
-
+   
+   public String toString()
+   {
+      return super.toString() + "{" + getDeclaringClass() + "/" + getName() + "}";
+   }
 }

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.annotated;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class Counter
+{
+   public static int postConstructs;
+   public static int preDestroys;
+   
+   public static void reset()
+   {
+      postConstructs = 0;
+      preDestroys = 0;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,81 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.annotated;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.PreDestroy;
+import javax.annotation.Resource;
+
+/**
+ * Do injection based on annotation.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class InjectedBean
+{
+   @Resource
+   private String value;
+   
+   /*
+    * To prove extendibility of annotated injection. 
+    * This should create a SimpleValueInjector.
+    */
+   @Simple(value="Hello world")
+   private String simpleValue;
+   
+   public InjectedBean()
+   {
+      if(value != null)
+         throw new IllegalStateException("value must be null");
+      
+      if(simpleValue != null)
+         throw new IllegalStateException("simpleValue must be null");
+   }
+   
+   public void check()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+      
+      if(simpleValue == null)
+         throw new IllegalStateException("simpleValue must no be null");
+   }
+   
+   @PostConstruct
+   public void postConstruct()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+      
+      if(simpleValue == null)
+         throw new IllegalStateException("simpleValue must no be null");
+      
+      Counter.postConstructs++;
+   }
+   
+   @PreDestroy
+   public void preDestroy()
+   {
+      Counter.preDestroys++;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Simple.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Simple.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Simple.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,43 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.annotated;
+
+import static java.lang.annotation.ElementType.FIELD;
+import static java.lang.annotation.ElementType.METHOD;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+/**
+ * Do a simple value injection.
+ * This annotation is pretty useless, but it should
+ * prove that the injection framework can be extended easily
+ * with new annotations.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+ at Target({FIELD, METHOD})
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface Simple {
+   String value();
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/SimplePropertyProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/SimplePropertyProcessor.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/SimplePropertyProcessor.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.annotated;
+
+import org.jboss.injection.AbstractProcessor;
+import org.jboss.injection.Injector;
+import org.jboss.injection.SimpleValueInjector;
+import org.jboss.injection.lang.reflect.BeanProperty;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class SimplePropertyProcessor extends AbstractProcessor<BeanProperty>
+{
+   @Override
+   public Injector processOne(BeanProperty property)
+   {
+      Simple simple = property.getAnnotation(Simple.class);
+      if(simple == null) return null;
+      
+      // TODO: transform the value
+      return new SimpleValueInjector(property, simple.value());
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,99 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.annotated.unit;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
+
+import junit.framework.TestCase;
+
+import org.jboss.injection.ClassPropertyProcessor;
+import org.jboss.injection.Injection;
+import org.jboss.injection.Injector;
+import org.jboss.injection.InjectorProcessor;
+import org.jboss.injection.MapInjectorFactory;
+import org.jboss.injection.PostConstructProcessor;
+import org.jboss.injection.Processor;
+import org.jboss.injection.ResourceClassProcessor;
+import org.jboss.injection.test.annotated.Counter;
+import org.jboss.injection.test.annotated.InjectedBean;
+import org.jboss.injection.test.annotated.SimplePropertyProcessor;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class AnnotatedTestCase extends TestCase
+{
+   public void test1() throws Exception
+   {
+      Counter.reset();
+      
+      // There are multiple ways to initialize the injectors, annotation
+      // is one of them.
+      
+      //
+      // the environment to use
+      //
+      
+      Map<String, Object> env = new HashMap<String, Object>();
+      env.put(InjectedBean.class.getName() + "/value", "Hello world");
+      
+      //
+      // the setup of injectors
+      //
+      
+      // TODO: weird, shouldn't this work?
+      //Collection<InjectionProcessor<Class<?>>> handlers = new ArrayList<InjectionProcessor<Class<?>>>();
+      Collection<Processor<Class<?>, Collection<Injector>>> handlers = new ArrayList<Processor<Class<?>, Collection<Injector>>>();
+      handlers.add(new ResourceClassProcessor(new MapInjectorFactory(env)));
+      handlers.add(new ClassPropertyProcessor(new SimplePropertyProcessor()));
+      Collection<Injector> injectors = Injection.doIt(InjectedBean.class, handlers);
+      
+      assertEquals("Wrong number of injectors", 2, injectors.size());
+      
+      Collection<Processor<Class<?>, Collection<Method>>> postConstructProcessors = new ArrayList<Processor<Class<?>, Collection<Method>>>();
+      postConstructProcessors.add(new PostConstructProcessor());
+      Collection<Method> postConstructs = Injection.doIt(InjectedBean.class, postConstructProcessors);
+      
+      //
+      // the target
+      //
+      
+      InjectedBean bean = new InjectedBean();
+      
+      //
+      // the injection
+      //
+      
+      InjectorProcessor.process(bean, injectors, postConstructs);
+      
+      bean.check();
+      
+      assertEquals("postConstruct should have been called once", 1, Counter.postConstructs);
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.programatically;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class Counter
+{
+   public static int postConstructs;
+   public static int preDestroys;
+   
+   public static void reset()
+   {
+      postConstructs = 0;
+      preDestroys = 0;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.programatically;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class InjectedBean
+{
+   private String value;
+   
+   public InjectedBean()
+   {
+      if(value != null)
+         throw new IllegalStateException("value must be null");
+   }
+   
+   public void check()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+   }
+   
+   public void postConstruct()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+      Counter.postConstructs++;
+   }
+   
+   public void preDestroy()
+   {
+      Counter.preDestroys++;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java	2006-12-13 11:12:34 UTC (rev 59009)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java	2006-12-13 11:12:42 UTC (rev 59010)
@@ -0,0 +1,66 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.programatically.unit;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.List;
+
+import junit.framework.TestCase;
+
+import org.jboss.injection.Injector;
+import org.jboss.injection.InjectorProcessor;
+import org.jboss.injection.SimpleValueInjector;
+import org.jboss.injection.lang.reflect.BeanProperty;
+import org.jboss.injection.lang.reflect.FieldBeanProperty;
+import org.jboss.injection.test.programatically.Counter;
+import org.jboss.injection.test.programatically.InjectedBean;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class InjectorProcessorTestCase extends TestCase
+{
+   public void test1() throws Exception
+   {
+      Counter.reset();
+      
+      InjectedBean bean = new InjectedBean();
+      
+      BeanProperty property = new FieldBeanProperty(bean.getClass().getDeclaredField("value"));
+      
+      List<Injector> injectors = new ArrayList<Injector>();
+      injectors.add(new SimpleValueInjector(property, "Hello world"));
+      
+      List<Method> postConstructs = new ArrayList<Method>();
+      postConstructs.add(bean.getClass().getDeclaredMethod("postConstruct", new Class[]{}));
+      
+      InjectorProcessor.process(bean, injectors, postConstructs);
+      
+      bean.check();
+      
+      assertEquals(1, Counter.postConstructs);
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 06:15:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 06:15:34 -0500
Subject: [jboss-cvs] JBossAS SVN: r59011 - in projects/ejb3/trunk/injection:
	. .settings src/test src/test/java/org/jboss/injection/test
	src/test/java/org/jboss/injection/test/simple
	src/test/java/org/jboss/injection/test/simple/unit
	src/test/resources src/test/resources/simple
Message-ID: <E1GuS5G-0004Rc-LC@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-13 06:15:26 -0500 (Wed, 13 Dec 2006)
New Revision: 59011

Added:
   projects/ejb3/trunk/injection/.settings/
   projects/ejb3/trunk/injection/.settings/org.eclipse.jdt.core.prefs
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java
   projects/ejb3/trunk/injection/src/test/resources/
   projects/ejb3/trunk/injection/src/test/resources/simple/
   projects/ejb3/trunk/injection/src/test/resources/simple/jboss-aop.xml
Log:
First prototype

Added: projects/ejb3/trunk/injection/.settings/org.eclipse.jdt.core.prefs
===================================================================
--- projects/ejb3/trunk/injection/.settings/org.eclipse.jdt.core.prefs	2006-12-13 11:12:42 UTC (rev 59010)
+++ projects/ejb3/trunk/injection/.settings/org.eclipse.jdt.core.prefs	2006-12-13 11:15:26 UTC (rev 59011)
@@ -0,0 +1,5 @@
+#Mon Dec 11 11:33:01 CET 2006
+org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5
+eclipse.preferences.version=1
+org.eclipse.jdt.core.compiler.source=1.5
+org.eclipse.jdt.core.compiler.compliance=1.5

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java	2006-12-13 11:12:42 UTC (rev 59010)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java	2006-12-13 11:15:26 UTC (rev 59011)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.simple;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class Counter
+{
+   public static int postConstructs;
+   public static int preDestroys;
+   
+   public static void reset()
+   {
+      postConstructs = 0;
+      preDestroys = 0;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java	2006-12-13 11:12:42 UTC (rev 59010)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java	2006-12-13 11:15:26 UTC (rev 59011)
@@ -0,0 +1,57 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.simple;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class InjectedBean
+{
+   private String value;
+   
+   public InjectedBean()
+   {
+      if(value != null)
+         throw new IllegalStateException("value must be null");
+   }
+   
+   public void check()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+   }
+   
+   public void postConstruct()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+      Counter.postConstructs++;
+   }
+   
+   public void preDestroy()
+   {
+      Counter.preDestroys++;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java	2006-12-13 11:12:42 UTC (rev 59010)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java	2006-12-13 11:15:26 UTC (rev 59011)
@@ -0,0 +1,98 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.simple.unit;
+
+import java.net.URL;
+
+import junit.framework.Test;
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+import org.jboss.aop.AspectXmlLoader;
+import org.jboss.injection.test.simple.Counter;
+import org.jboss.injection.test.simple.InjectedBean;
+
+/**
+ * Run with: -Djava.system.class.loader=org.jboss.aop.standalone.SystemClassLoader
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class SimpleTestCase extends TestCase
+{
+   public void test1() throws Exception
+   {
+      Counter.reset();
+      
+//      Class cls = Thread.currentThread().getContextClassLoader().loadClass("org.jboss.injection.test.simple.InjectedBean");
+      
+//      Object bean1 = cls.newInstance();
+      
+      InjectedBean bean = new InjectedBean();
+      
+      bean.check();
+      
+      assertEquals(1, Counter.postConstructs);
+      
+      bean = null;
+      
+      Runtime.getRuntime().gc();
+      Runtime.getRuntime().runFinalization();
+      
+      assertEquals(1, Counter.preDestroys);
+   }
+   
+   public static Test suite() throws Exception
+   {
+//      AspectManager.verbose = true;
+      
+//      AspectManager.debugClasses = true;
+//      AspectManager.classicOrder = true;
+      
+//      System.err.println(Thread.currentThread().getContextClassLoader());
+//      URLClassLoader ucl = (URLClassLoader) Thread.currentThread().getContextClassLoader();
+//      for(URL url : ucl.getURLs())
+//         System.err.println(" - " + url);
+//      
+//      List<URL> urls = new ArrayList<URL>();
+//      for(int i = 0; i < ucl.getURLs().length; i++)
+//      {
+//         System.err.println(ucl.getURLs()[i]);
+//         urls.add(ucl.getURLs()[i]);
+//      }
+      
+      //ClassLoader parent = URLClassLoader.newInstance(urls.toArray(new URL[0]), Thread.currentThread().getContextClassLoader().getParent());
+//      ClassLoader parent = URLClassLoader.newInstance(urls.toArray(new URL[0]), null);
+//      SystemClassLoader cl = new SystemClassLoader(parent);
+//      //AspectManager.instance().registerClassLoader(cl);
+//      Thread.currentThread().setContextClassLoader(cl);
+      
+      URL url = Thread.currentThread().getContextClassLoader().getResource("simple/jboss-aop.xml");
+      System.out.println(url);
+      AspectXmlLoader.deployXML(url);
+      
+//      AspectManager.instance().registerClassLoader(cl);
+//      System.err.println(AspectManager.getRegisteredCLs());
+      
+      return new TestSuite(SimpleTestCase.class);
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/resources/simple/jboss-aop.xml
===================================================================
--- projects/ejb3/trunk/injection/src/test/resources/simple/jboss-aop.xml	2006-12-13 11:12:42 UTC (rev 59010)
+++ projects/ejb3/trunk/injection/src/test/resources/simple/jboss-aop.xml	2006-12-13 11:15:26 UTC (rev 59011)
@@ -0,0 +1,7 @@
+<aop>
+	<interceptor name="ConstructorInterceptor" class="org.jboss.injection.aop.ConstructorInterceptor" scope="PER_VM"/>
+	
+	<bind pointcut="construction(org.jboss.injection.test.*->new(..))">
+		<interceptor-ref name="ConstructorInterceptor"/>
+	</bind>
+</aop>
\ No newline at end of file



From gavin.king at jboss.com  Wed Dec 13 06:20:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 06:20:28 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GuSA0-0004XO-QT@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 06:20:28

  Modified:    jboss-seam  changelog.txt
  Log:
  date
  
  Revision  Changes    Path
  1.33      +1 -1      jboss-seam/changelog.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: changelog.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/changelog.txt,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- changelog.txt	13 Dec 2006 10:10:43 -0000	1.32
  +++ changelog.txt	13 Dec 2006 11:20:28 -0000	1.33
  @@ -1,6 +1,6 @@
   JBoss Seam Changelog
   ====================
  -Changes in version 1.1.0.GA (November 2006)
  +Changes in version 1.1.0.GA (December 2006)
   -------------------------------------------
   ** Bug
       * [JBSEAM-544] - PropertyNotFoundException from Namespace in test harness
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 07:42:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 07:42:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r59012 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1GuTRO-0006Ec-0A@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-13 07:42:28 -0500 (Wed, 13 Dec 2006)
New Revision: 59012

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/VFSDirContext.java
Log:
Either I missed something, or isLeaf isn't behaving the same as it was before, as "my.jar".isLeaf() returns false.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/VFSDirContext.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/VFSDirContext.java	2006-12-13 11:15:26 UTC (rev 59011)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/VFSDirContext.java	2006-12-13 12:42:28 UTC (rev 59012)
@@ -170,10 +170,11 @@
                 (sm.getString("resources.notFound", name));
         
         try {
-            if (!entry.isLeaf())
+            if (!isFile(entry)) {
                 return new VFSDirContext(entry);
-            else
+            } else {
                 return new VFSResource(entry);
+            }
         } catch (IOException e) {
             NamingException ex = new NamingException
                 (sm.getString("resources.notFound", name));
@@ -480,7 +481,7 @@
         try {
             attrs.setCreationDate(new Date(entry.getLastModified()));
             attrs.setName(entry.getName());
-            if (entry.isLeaf())
+            if (isFile(entry))
                 attrs.setResourceType("");
             attrs.setContentLength(entry.getSize());
             attrs.setLastModified(entry.getLastModified());
@@ -744,6 +745,15 @@
 
     // ------------------------------------------------------ Protected Methods
 
+    
+    /**
+     * Check if a VirtualFile is a regular file or a folder.
+     */
+    protected boolean isFile(VirtualFile file)
+       throws IOException {
+       return (file.isLeaf() || (file.getSize() > 0));
+    }
+    
 
     /**
      * Entry tree lookup.
@@ -773,14 +783,14 @@
         throws IOException {
         
         ArrayList<NamingEntry> entries = new ArrayList<NamingEntry>();
-        if (!entry.isLeaf()) {
+        if (!isFile(entry)) {
             Iterator<VirtualFile> children = entry.getChildren().iterator();
             NamingEntry namingEntry = null;
 
             while (children.hasNext()) {
                 VirtualFile current = children.next();
                 Object object = null;
-                if (!current.isLeaf()) {
+                if (!isFile(current)) {
                     object = new VFSDirContext(current);
                 } else {
                     object = new VFSResource(current);



From msurtani at jboss.com  Wed Dec 13 08:32:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 08:32:44 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction  ...
Message-ID: <E1GuUE0-0007Ie-Un@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 08:32:44

  Modified:    src/org/jboss/cache/eviction  Tag: Branch_JBossCache_1_4_0
                        BaseEvictionAlgorithm.java
  Log:
  recycle queue should use the same capacity as the eviction queue - NOT the default 1024
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.11.2.1  +2 -2      JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BaseEvictionAlgorithm.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java,v
  retrieving revision 1.11
  retrieving revision 1.11.2.1
  diff -u -b -r1.11 -r1.11.2.1
  --- BaseEvictionAlgorithm.java	8 Jun 2006 17:37:39 -0000	1.11
  +++ BaseEvictionAlgorithm.java	13 Dec 2006 13:32:44 -0000	1.11.2.1
  @@ -19,7 +19,7 @@
    * abstract methods and a policy.
    *
    * @author Daniel Huang - dhuang at jboss.org 10/2005
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.11.2.1 $
    */
   public abstract class BaseEvictionAlgorithm implements EvictionAlgorithm
   {
  @@ -60,7 +60,7 @@
   
      protected BaseEvictionAlgorithm()
      {
  -      recycleQueue = new BoundedBuffer();
  +      recycleQueue = new BoundedBuffer(RegionManager.CAPACITY);
      }
   
      protected void initialize(Region region) throws EvictionException
  
  
  


From msurtani at jboss.com  Wed Dec 13 08:32:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 08:32:45 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/aop  ...
Message-ID: <E1GuUE1-0007Ip-5S@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 08:32:45

  Modified:    tests/functional/org/jboss/cache/aop  Tag:
                        Branch_JBossCache_1_4_0 LocalConcurrentTest.java
  Log:
  recycle queue should use the same capacity as the eviction queue - NOT the default 1024
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.8.2.1   +6 -2      JBossCache/tests/functional/org/jboss/cache/aop/Attic/LocalConcurrentTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalConcurrentTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/aop/Attic/LocalConcurrentTest.java,v
  retrieving revision 1.8
  retrieving revision 1.8.2.1
  diff -u -b -r1.8 -r1.8.2.1
  --- LocalConcurrentTest.java	1 Jun 2006 02:14:23 -0000	1.8
  +++ LocalConcurrentTest.java	13 Dec 2006 13:32:45 -0000	1.8.2.1
  @@ -34,7 +34,7 @@
    * Local mode stress test for PojoCache. Test getObject and putObject under load
    * and concurrency.
    *
  - * @version $Revision: 1.8 $
  + * @version $Revision: 1.8.2.1 $
    * @author<a href="mailto:bwang at jboss.org">Ben Wang</a> December 2004
    */
   public class LocalConcurrentTest extends TestCase
  @@ -205,6 +205,10 @@
         }
   
         /**
  +       * Note that this operation needs to run under transaction context as a whole. If not, then different
  +       * threads will have the chance to use the same fqn node. While one thread has finished putObject and the
  +       * other thread can the do the same, it will screw up the reference counting (??).
  +       * @throws Exception
          */
         public void _run() throws Exception {
            for (int loop = 0; loop < MAX_LOOP; loop++) {
  @@ -223,7 +227,7 @@
         private void op1() throws CacheException {
            int i = random_.nextInt(nodeList_.size() - 1);
            if(i==0) return; // it is meaningless to test root
  -         String node = (String) nodeList_.get(i) + "/aop";
  +         String node = nodeList_.get(i) + "/aop";
            cache_.putObject(node, person_);
            TestingUtil.sleepThread(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
   // getObject is not thread safe since there is no way to lock the fqn atomically without triggering
  
  
  


From hyew98651 at lycos.com  Wed Dec 13 09:13:54 2006
From: hyew98651 at lycos.com (hyew98651 at lycos.com)
Date: Wed, 13 Dec 2006 09:13:54 -0500
Subject: [jboss-cvs] =?utf-8?b?wpHDpcKVw4/CknjCgsKtwoLDiMKCw6jCgsOcwoI=?=
	=?utf-8?b?wrXCgsK9woFJwoLCscKCwr/CgsOnwoLDhsKCw4jCgsOowoLDnMKCwrc=?=
	=?utf-8?b?woFJ?=
Message-ID: 20061213231124.68626mail@mail.mznxbcvvlaksjshdgfyturieowpq.com

???????l???f???????????????????R???????????????[???????????????????B

???O?F????
?h?c?F155673
?N???F31??
?E???F???w
???b?Z?[?W?F
?u?????????????????[???????????B?????????????????????B
?@???]?????????????[?????????????B?y?????s?????????????????B
?@?????d?b???????????????]???????B?v
???M?F http://freeweb.lovelovesexywoman.tonderuyo.com/dodo/

???O?F????
?h?c?F198725
?N???F22??
?E???F???w??
???b?Z?[?W?F
?u?A?E???????????????R?C???????V??????????
?@?????????????s???????????H?????????????A??????????????????
?@?????v???t???A?h???X???????????????????A?????????????????v
???M?F http://freeweb.lovelovesexywoman.tonderuyo.com/dodo/

???O?F?R???q
?h?c?F200376
?N???F38??
?E???F?p?[?g
???b?Z?[?W?F
?u?????????R?N?o???o?c?C?`?????B
?@40?????????O?????????x?????????????????m?F???????????U???????????B
?@????????30?O???????????????B?A?????????????B?v
???M?F http://freeweb.lovelovesexywoman.tonderuyo.com/dodo/


???L?R?????????????????l???????????????????B
?v???t?B?[?????A???????????????????????????????????????????A
???????????M?????????v???????B

?T?C?g????????????????
http://freeweb.lovelovesexywoman.tonderuyo.com/dodo/





From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 09:14:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 09:14:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59013 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GuUsI-0008EL-CG@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-13 09:14:17 -0500 (Wed, 13 Dec 2006)
New Revision: 59013

Added:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
Removed:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
Modified:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
Log:
JBMICROCONT-26; tests

Copied: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java (from rev 59007, projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java)
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-12 23:50:32 UTC (rev 59007)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-13 14:14:17 UTC (rev 59013)
@@ -0,0 +1,55 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import junit.framework.Test;
+import org.jboss.beans.metadata.spi.BeanMetaData;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class DescribeSpringTestCase extends TempSpringSchemaTest
+{
+
+   public DescribeSpringTestCase(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test
+    *
+    * @return the test
+    */
+   public static Test suite()
+   {
+      return suite(DescribeSpringTestCase.class);
+   }
+
+   public void testDescribe() throws Exception
+   {
+      BeanMetaData simpleBeanMD = unmarshal("TestInstantiate.xml", BeanMetaData.class);
+      // todo - test descriptions
+      System.out.println("simpleBean = " + simpleBeanMD);
+   }
+
+}

Deleted: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-13 12:42:28 UTC (rev 59012)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-13 14:14:17 UTC (rev 59013)
@@ -1,54 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.test.spring.test;
-
-import junit.framework.Test;
-import org.jboss.beans.metadata.spi.BeanMetaData;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- */
-public class InstantiateSpringTestCase extends TempSpringSchemaTest
-{
-
-   public InstantiateSpringTestCase(String name)
-   {
-      super(name);
-   }
-
-   /**
-    * Setup the test
-    *
-    * @return the test
-    */
-   public static Test suite()
-   {
-      return suite(InstantiateSpringTestCase.class);
-   }
-
-   public void testInstantiate() throws Exception
-   {
-      BeanMetaData simpleBeanMD = unmarshal("TestInstantiate.xml", BeanMetaData.class);
-      System.out.println("simpleBean = " + simpleBeanMD);
-   }
-
-}

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-13 12:42:28 UTC (rev 59012)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-13 14:14:17 UTC (rev 59013)
@@ -40,7 +40,7 @@
    {
       TestSuite suite = new TestSuite("Spring Tests");
 
-      suite.addTest(InstantiateSpringTestCase.suite());
+      suite.addTest(DescribeSpringTestCase.suite());
 
       return suite;
    }



From msurtani at jboss.com  Wed Dec 13 11:01:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 11:01:47 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache   ...
Message-ID: <E1GuWYF-00022o-BD@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 11:01:47

  Modified:    src/org/jboss/cache   Tag: Branch_JBossCache_1_4_0
                        TreeCache.java Node.java
  Log:
  optimisations on casting nodes.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.34 +19 -23    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.33
  retrieving revision 1.195.2.34
  diff -u -b -r1.195.2.33 -r1.195.2.34
  --- TreeCache.java	10 Dec 2006 16:42:56 -0000	1.195.2.33
  +++ TreeCache.java	13 Dec 2006 16:01:47 -0000	1.195.2.34
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.33 2006/12/10 16:42:56 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.34 2006/12/13 16:01:47 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -3467,7 +3467,7 @@
       */
      public Node _get(Fqn fqn) throws CacheException
      {
  -      return (Node) findNode(fqn);
  +      return findNode(fqn);
      }
   
      /**
  @@ -3623,9 +3623,9 @@
       *
       * @param fqn
       */
  -   private DataNode findInternal(Fqn fqn, boolean includeNodesMarkedAsRemoved)
  +   private Node findInternal(Fqn fqn, boolean includeNodesMarkedAsRemoved)
      {
  -      if (fqn == null || fqn.size() == 0) return root;
  +      if (fqn == null || fqn.size() == 0) return (Node) root;
         TreeNode n = root;
         int fqnSize = fqn.size();
         for (int i = 0; i < fqnSize; i++)
  @@ -3637,7 +3637,7 @@
            else if (!includeNodesMarkedAsRemoved && isMarkedForRemoval(n))
               return null;
         }
  -      return (DataNode) n;
  +      return (Node) n;
      }
   
   
  @@ -4153,36 +4153,36 @@
         return count;
      }
   
  -    private void markForRemoval(TreeNode n)
  +    private void markForRemoval(Node n)
       {
          n.put(REMOVAL_MARKER, null);
          // mark children as well.
  -       Map children = n.getChildren();
  +       Map children = n.getChildren(true);
          if (children != null && !children.isEmpty())
          {
             // traverse children
             Iterator i = children.values().iterator();
             while (i.hasNext())
             {
  -             markForRemoval((TreeNode) i.next());
  +             markForRemoval((Node) i.next());
             }
          }
       }
   
  -    public void scrubRemoveMarker(TreeNode n, boolean deep)
  +    public void scrubRemoveMarker(Node n, boolean deep)
       {
          n.remove(REMOVAL_MARKER);
          // unmark children as well.
          if (deep)
          {
  -          Map children = n.getChildren();
  +          Map children = n.getChildren(true);
             if (children != null && !children.isEmpty())
             {
                // traverse children
                Iterator i = children.values().iterator();
                while (i.hasNext())
                {
  -                scrubRemoveMarker((TreeNode) i.next(), true);
  +                scrubRemoveMarker((Node) i.next(), true);
                }
             }
          }
  @@ -4199,7 +4199,7 @@
        */
       public void realRemove(Fqn f, boolean skipMarkerCheck)
       {
  -       DataNode n = findInternal(f, true);
  +       Node n = findInternal(f, true);
          if (n == null)
             return;
   
  @@ -4531,7 +4531,7 @@
      public void _put(GlobalTransaction tx, Fqn fqn, Map data, boolean create_undo_ops, boolean erase_contents)
              throws CacheException
      {
  -      DataNode n;
  +      Node n;
         MethodCall undo_op = null;
         Map old_data;
   
  @@ -4606,7 +4606,7 @@
      public Object _put(GlobalTransaction tx, Fqn fqn, Object key, Object value, boolean create_undo_ops)
              throws CacheException
      {
  -      DataNode n = null;
  +      Node n = null;
         MethodCall undo_op = null;
         Object old_value = null;
   
  @@ -4716,7 +4716,7 @@
              throws CacheException
      {
   
  -      DataNode n;
  +      Node n;
         TreeNode parent_node;
         MethodCall undo_op = null;
   
  @@ -5061,7 +5061,7 @@
         }
         tmp.addChild(child_name, old_node);
         // make sure any deleted markers are removed from this child.
  -      scrubRemoveMarker(old_node, true);
  +      scrubRemoveMarker((Node) old_node, true);
         notifyNodeCreated(new Fqn(parent_fqn, child_name));
      }
   
  @@ -5791,7 +5791,7 @@
       * @param fqn Fully qualified name for the corresponding node.
       * @return DataNode
       */
  -   private DataNode findNode(Fqn fqn)
  +   private Node findNode(Fqn fqn)
      {
         try
         {
  @@ -5807,15 +5807,11 @@
      /**
       * Finds a node given a fully qualified name and DataVersion.
       */
  -   private DataNode findNode(Fqn fqn, DataVersion version) throws CacheException
  +   private Node findNode(Fqn fqn, DataVersion version) throws CacheException
      {
  -      TreeNode n, child_node = null;
  -      Object child_name;
  -      int treeNodeSize;
  -
         if (fqn == null) return null;
   
  -      DataNode toReturn = findInternal(fqn, false);
  +      Node toReturn = findInternal(fqn, false);
   
         if (version != null)
         {
  
  
  
  1.38.2.3  +25 -0     JBossCache/src/org/jboss/cache/Node.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Node.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Node.java,v
  retrieving revision 1.38.2.2
  retrieving revision 1.38.2.3
  diff -u -b -r1.38.2.2 -r1.38.2.3
  --- Node.java	27 Nov 2006 16:12:14 -0000	1.38.2.2
  +++ Node.java	13 Dec 2006 16:01:47 -0000	1.38.2.3
  @@ -165,6 +165,31 @@
         this.lock_ = null;
      }
   
  +   public Map getChildren(boolean includeMarkedForRemoval)
  +   {
  +      return includeMarkedForRemoval ? children : getChildren();
  +   }
  +
  +   public Map getChildren()
  +   {
  +      if (children == null) return null;
  +      if (children.isEmpty()) return children;
  +
  +      // make sure we remove all children that are marked for removal ...
  +      Map toReturn = new HashMap();
  +      Iterator c = children.values().iterator();
  +      while (c.hasNext())
  +      {
  +         Node ch = (Node) c.next();
  +         if (!cache.isMarkedForRemoval(ch))
  +         {
  +            toReturn.put(ch.getName(), ch);
  +         }
  +      }
  +
  +      return toReturn;
  +   }
  +
      /**
       * Set the tree cache instance recursively down to the children as well.
       * Note that this method is not currently thread safe.
  
  
  


From msurtani at jboss.com  Wed Dec 13 11:01:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 11:01:47 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GuWYF-00022z-FP@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 11:01:47

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  optimisations on casting nodes.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.7  +3 -2      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.6
  retrieving revision 1.20.2.7
  diff -u -b -r1.20.2.6 -r1.20.2.7
  --- PessimisticLockInterceptor.java	11 Dec 2006 18:00:48 -0000	1.20.2.6
  +++ PessimisticLockInterceptor.java	13 Dec 2006 16:01:47 -0000	1.20.2.7
  @@ -10,6 +10,7 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
  +import org.jboss.cache.Node;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
   import org.jboss.cache.TreeCache;
  @@ -36,7 +37,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.6 2006/12/11 18:00:48 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.7 2006/12/13 16:01:47 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -318,7 +319,7 @@
   
      private void reverseRemove(DataNode n)
      {
  -      cache.scrubRemoveMarker(n, false);
  +      cache.scrubRemoveMarker((Node) n, false);
      }
   
      private boolean writeLockNeeded(int lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
  
  
  


From msurtani at jboss.com  Wed Dec 13 11:05:43 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 11:05:43 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GuWc3-0002Jy-RE@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 11:05:43

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        Version.java
  Log:
  Updated for 1.4.1.CR1
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.18.2.6  +4 -4      JBossCache/src/org/jboss/cache/Version.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Version.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Version.java,v
  retrieving revision 1.18.2.5
  retrieving revision 1.18.2.6
  diff -u -b -r1.18.2.5 -r1.18.2.6
  --- Version.java	1 Nov 2006 00:55:40 -0000	1.18.2.5
  +++ Version.java	13 Dec 2006 16:05:43 -0000	1.18.2.6
  @@ -6,13 +6,13 @@
    * Contains version information about this release of TreeCache.
    *
    * @author Bela Ban
  - * @version $Id: Version.java,v 1.18.2.5 2006/11/01 00:55:40 msurtani Exp $
  + * @version $Id: Version.java,v 1.18.2.6 2006/12/13 16:05:43 msurtani Exp $
    */
   public class Version
   {
  -   public static final String version = "1.4.1.BETA";
  -   public static byte[] version_id = {'0', '1', '4', '1', 'B'};
  -   public static final String cvs = "$Id: Version.java,v 1.18.2.5 2006/11/01 00:55:40 msurtani Exp $";
  +   public static final String version = "1.4.1.CR1";
  +   public static byte[] version_id = {'0', '1', '4', '1', 'C'};
  +   public static final String cvs = "$Id: Version.java,v 1.18.2.6 2006/12/13 16:05:43 msurtani Exp $";
   
      private static final int MAJOR_SHIFT = 11;
      private static final int MINOR_SHIFT = 6;
  
  
  


From msurtani at jboss.com  Wed Dec 13 11:05:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 11:05:44 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GuWc4-0002K9-16@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 11:05:44

  Modified:    JBossCache  Tag: Branch_JBossCache_1_4_0 build.xml
  Log:
  Updated for 1.4.1.CR1
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.119.2.17 +2 -2      JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.119.2.16
  retrieving revision 1.119.2.17
  diff -u -b -r1.119.2.16 -r1.119.2.17
  --- build.xml	11 Dec 2006 10:11:20 -0000	1.119.2.16
  +++ build.xml	13 Dec 2006 16:05:43 -0000	1.119.2.17
  @@ -1,12 +1,12 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.119.2.16 2006/12/11 10:11:20 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.119.2.17 2006/12/13 16:05:43 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
      <property name="module.name" value="JBossCache"/>
      <!--We now requires version to have no white space since Ant+JBossAop will sometime choke. -->
  -   <property name="module.version" value="1.4.1.BETA"/>
  +   <property name="module.version" value="1.4.1.CR1"/>
      <property name="implementation.url" value="http://www.jboss.com/products/jbosscache"/>
      <property file="build.properties"/>
      <property name="root.dir" value="${basedir}"/>
  
  
  


From msurtani at jboss.com  Wed Dec 13 11:05:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 11:05:44 -0500
Subject: [jboss-cvs] JBossCache/docs  ...
Message-ID: <E1GuWc4-0002KM-5E@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 11:05:44

  Modified:    docs     Tag: Branch_JBossCache_1_4_0 Changelog.txt
  Log:
  Updated for 1.4.1.CR1
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.6  +25 -2     JBossCache/docs/Changelog.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Changelog.txt
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/docs/Changelog.txt,v
  retrieving revision 1.20.2.5
  retrieving revision 1.20.2.6
  diff -u -b -r1.20.2.5 -r1.20.2.6
  --- Changelog.txt	14 Nov 2006 08:44:41 -0000	1.20.2.5
  +++ Changelog.txt	13 Dec 2006 16:05:44 -0000	1.20.2.6
  @@ -1,11 +1,16 @@
  -$Id: Changelog.txt,v 1.20.2.5 2006/11/14 08:44:41 msurtani Exp $
  +$Id: Changelog.txt,v 1.20.2.6 2006/12/13 16:05:44 msurtani Exp $
   
  -Release 1.4.1.GA (November 20th, 2006)
  +Release 1.4.1.CR1 (December 13th, 2006)
   ======================================
  +Release Notes for JBoss Cache
  +Includes versions: 1.4.1.GA
   
   ** Feature Request
       *  [ JBCACHE-813 ] BaseRpcInterceptor to call callRemoteMethod() instead of callRemoteMethods() when sending to a single recipient
  +    *  [ JBCACHE-829 ] Add JBoss EULA
       *  [ JBCACHE-842 ] Optimistic Locking improvements - validation on read-only transactions
  +    *  [ JBCACHE-860 ] Clustered Cache Loaders too "noisy" with error level logging when alone in the cluster
  +    *  [ JBCACHE-878 ] Documment SyncCommitPhase
   
   ** Bug
       *  [ JBCACHE-690 ] TcpCacheServer never gets out of STARTING state, and doesn't shut down socket when stop() is called.
  @@ -31,6 +36,14 @@
       *  [ JBCACHE-836 ] TreeCache isCoordinator() returns incorrect value after clean shutdown of coordinator
       *  [ JBCACHE-843 ] Data versions do not replicate properly alongside data
       *  [ JBCACHE-844 ] Correct handling of partial state transfer re-try logic
  +    *  [ JBCACHE-847 ] PojoCache didn't restore the Collection class reference correctly during removeObject()
  +    *  [ JBCACHE-850 ] PojoCache findObjects can produce CCE
  +    *  [ JBCACHE-871 ] Calling remove(FQN) inside a transaction destroys the node before the commit phase
  +    *  [ JBCACHE-872 ] Lock release methods should produce similar log messages to lock acquire methods
  +    *  [ JBCACHE-875 ] Pessimistic lock interceptor does not write-lock parent nodes when creating or deleting children
  +    *  [ JBCACHE-883 ] VersionAwareMarshaller hides true cause of marshalling failures
  +    *  [ JBCACHE-894 ] Exceptions when using optimistic treecache with hibernate 3.2
  +    *  [ JBCACHE-895 ] ClassCastException in GlobalTransaction#equals()
   
   ** Task
       *  [ JBCACHE-680 ] TreeCache demo gui to update view instanteously
  @@ -41,6 +54,16 @@
       *  [ JBCACHE-812 ] Enable JGroups multiplexer integration in a 1.4.x release
       *  [ JBCACHE-815 ] Eliminate need for jboss-serialization.jar if it's not used
       *  [ JBCACHE-824 ] Don't call Channel.getView() in viewAccepted() callback
  +    *  [ JBCACHE-874 ] Use performant ordered collections in TransactionEntry
  +    *  [ JBCACHE-884 ] Upgrade to JGroups 2.4.1
  +    *  [ JBCACHE-886 ] Upgrading from JGroups 2.2.9.2 to JGroups 2.4
  +    *  [ JBCACHE-887 ] Upgrading from JBoss Serialization 1.0.1.GA to JBoss Serialization 1.0.3.GA
  +    *  [ JBCACHE-901 ] Update logging libraries
  +
  +** Patch
  +    *  [ JBCACHE-766 ] Don't return unnecessary values from _replicate, avoiding need for marshalling
  +    *  [ JBCACHE-786 ] errors from "OK" putFailFast replications
  +
   
   Release 1.4.0.SP1 (August 9, 2006)
   ==================================
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 11:14:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 11:14:40 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1784 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GuWki-0002WO-R0@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-13 11:14:39 -0500 (Wed, 13 Dec 2006)
New Revision: 1784

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
Reverting my change

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 09:46:39 UTC (rev 1783)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 16:14:39 UTC (rev 1784)
@@ -53,7 +53,6 @@
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.tx.AckInfo;
 import org.jboss.jms.tx.ResourceManager;
-import org.jboss.jms.util.Valve;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.ConnectionListener;
@@ -580,12 +579,10 @@
    private class ConnectionFailureListener implements ConnectionListener
    {
       private ClientConnectionDelegate cd;
-      private Valve valve;
 
       ConnectionFailureListener(ClientConnectionDelegate cd)
       {
          this.cd = cd;
-         this.valve = new Valve();
       }
 
       // ConnectionListener implementation ---------------------------
@@ -595,40 +592,7 @@
          try
          {
             log.debug(this + " is being notified of connection failure: " + throwable);
-
-            // It references Valve to a local variable. Since we reset the valve at the end, we need
-            // to guarantee we will have the same Valve instance from the moment we entered this
-            // method.
-
-            Valve localValve = null;
-            synchronized (this)
-            {
-               localValve = valve;
-            }
-
-            // We can't have more than one exception being caught at the same time. On that case we
-            // will open the valve and any other thread opening the valve will wait until
-            // its completion.
-
-            if (localValve.open())
-            {
-               try
-               {
-                  handleFailure(cd);
-               }
-               finally
-               {
-                  localValve.close();
-                  synchronized (this)
-                  {
-                     valve = new Valve();
-                  }
-               }
-            }
-            else
-            {
-               log.debug(this + ": Another thread was responsible for failover as the valve was closed");
-            }
+            handleFailure(cd);
          }
          catch (Throwable e)
          {



From gavin.king at jboss.com  Wed Dec 13 11:38:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 11:38:58 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/lib  ...
Message-ID: <E1GuX8E-0002xj-0t@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 11:38:58

  Modified:    examples/jpa/lib  ajax4jsf.jar
  Log:
  upgraded ajax4jsf to 1.0.4 maintenance release 2
  
  Revision  Changes    Path
  1.2       +2727 -2590jboss-seam/examples/jpa/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Wed Dec 13 11:38:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 11:38:58 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/lib  ...
Message-ID: <E1GuX8E-0002xp-6L@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 11:38:58

  Modified:    examples/glassfish/lib  ajax4jsf.jar
  Log:
  upgraded ajax4jsf to 1.0.4 maintenance release 2
  
  Revision  Changes    Path
  1.2       +2727 -2590jboss-seam/examples/glassfish/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Wed Dec 13 11:38:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 11:38:58 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF/lib  ...
Message-ID: <E1GuX8E-0002xv-Fy@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 11:38:58

  Modified:    examples/booking/resources/WEB-INF/lib  ajax4jsf.jar
  Log:
  upgraded ajax4jsf to 1.0.4 maintenance release 2
  
  Revision  Changes    Path
  1.5       +1628 -1670jboss-seam/examples/booking/resources/WEB-INF/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Wed Dec 13 11:38:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 11:38:58 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/lib  ...
Message-ID: <E1GuX8E-0002y1-L4@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 11:38:58

  Modified:    examples/hibernate2/lib  ajax4jsf.jar
  Log:
  upgraded ajax4jsf to 1.0.4 maintenance release 2
  
  Revision  Changes    Path
  1.2       +2727 -2590jboss-seam/examples/hibernate2/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 12:52:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 12:52:05 -0500
Subject: [jboss-cvs] JBossAS SVN: r59014 - in branches/Branch_4_0/testsuite:
	imports/sections src/main/org/jboss/test/scoped/test
Message-ID: <E1GuYGz-0004Ep-4H@committer01.frg.pub.inap.atl.jboss.com>

Author: tom.elrod at jboss.com
Date: 2006-12-13 12:52:02 -0500 (Wed, 13 Dec 2006)
New Revision: 59014

Modified:
   branches/Branch_4_0/testsuite/imports/sections/scoped.xml
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
Log:
JBAS-3198 - fix for pooled invoker scoped deployments class caching.

Modified: branches/Branch_4_0/testsuite/imports/sections/scoped.xml
===================================================================
--- branches/Branch_4_0/testsuite/imports/sections/scoped.xml	2006-12-13 14:14:17 UTC (rev 59013)
+++ branches/Branch_4_0/testsuite/imports/sections/scoped.xml	2006-12-13 17:52:02 UTC (rev 59014)
@@ -3,49 +3,89 @@
    <target name="_jars-scoped">
       <mkdir dir="${build.lib}"/>
 
-      <!-- build scopedA.jar -->
-      <jar destfile="${build.lib}/scopedA.jar">
+      <mkdir dir="${build.lib}/scopedA.ear"/>
+      <mkdir dir="${build.lib}/scopedA.ear/scopedA.jar"/>
+      <copy todir="${build.lib}/scopedA.ear/scopedA.jar">
          <fileset dir="${build.classes}">
             <include name="org/jboss/test/scoped/ejb/a/**"/>
             <include name="org/jboss/test/scoped/interfaces/**"/>
             <include name="org/jboss/test/util/Debug.class"/>
+            <exclude name="**/SimpleResponseDTO*"/>
          </fileset>
          <fileset dir="${build.resources}/scoped/a/ejb">
             <include name="META-INF/*.xml"/>
          </fileset>
-      </jar>
+      </copy>
 
-      <!-- build scopedB.jar -->
-      <jar destfile="${build.lib}/scopedB.jar">
+      <copy todir="${build.lib}/scopedA.ear">
+         <fileset dir="${build.resources}/scoped/a/ear">
+            <include name="META-INF/*.xml"/>
+         </fileset>
+      </copy>
+
+      <mkdir dir="${build.lib}/scopedB.ear"/>
+      <mkdir dir="${build.lib}/scopedB.ear/scopedB.jar"/>
+      <copy todir="${build.lib}/scopedB.ear/scopedB.jar">
          <fileset dir="${build.classes}">
             <include name="org/jboss/test/scoped/ejb/b/**"/>
             <include name="org/jboss/test/scoped/interfaces/**"/>
             <include name="org/jboss/test/util/Debug.class"/>
+            <exclude name="**/SimpleResponseDTO*"/>
          </fileset>
          <fileset dir="${build.resources}/scoped/b/ejb">
             <include name="META-INF/*.xml"/>
          </fileset>
-      </jar>
+      </copy>
 
-      <!-- build scopedA.ear -->
-      <jar destfile="${build.lib}/scopedA.ear">
-         <fileset dir="${build.lib}">
-            <include name="scopedA.jar"/>
-         </fileset>
-         <fileset dir="${build.resources}/scoped/a/ear">
+      <copy todir="${build.lib}/scopedB.ear">
+         <fileset dir="${build.resources}/scoped/b/ear">
             <include name="META-INF/*.xml"/>
          </fileset>
-      </jar>
+      </copy>
 
+      <!-- build scopedA.jar -->
+      <!--<jar destfile="${build.lib}/scopedA.jar">-->
+         <!--<fileset dir="${build.classes}">-->
+            <!--<include name="org/jboss/test/scoped/ejb/a/**"/>-->
+            <!--<include name="org/jboss/test/scoped/interfaces/**"/>-->
+            <!--<include name="org/jboss/test/util/Debug.class"/>-->
+         <!--</fileset>-->
+         <!--<fileset dir="${build.resources}/scoped/a/ejb">-->
+            <!--<include name="META-INF/*.xml"/>-->
+         <!--</fileset>-->
+      <!--</jar>-->
+
+      <!-- build scopedB.jar -->
+      <!--<jar destfile="${build.lib}/scopedB.jar">-->
+         <!--<fileset dir="${build.classes}">-->
+            <!--<include name="org/jboss/test/scoped/ejb/b/**"/>-->
+            <!--<include name="org/jboss/test/scoped/interfaces/**"/>-->
+            <!--<include name="org/jboss/test/util/Debug.class"/>-->
+         <!--</fileset>-->
+         <!--<fileset dir="${build.resources}/scoped/b/ejb">-->
+            <!--<include name="META-INF/*.xml"/>-->
+         <!--</fileset>-->
+      <!--</jar>-->
+
+      <!-- build scopedA.ear -->
+      <!--<jar destfile="${build.lib}/scopedA.ear">-->
+         <!--<fileset dir="${build.lib}">-->
+            <!--<include name="scopedA.jar"/>-->
+         <!--</fileset>-->
+         <!--<fileset dir="${build.resources}/scoped/a/ear">-->
+            <!--<include name="META-INF/*.xml"/>-->
+         <!--</fileset>-->
+      <!--</jar>-->
+
       <!-- build scopedB.ear -->
-      <jar destfile="${build.lib}/scopedB.ear">
-         <fileset dir="${build.lib}">
-            <include name="scopedB.jar"/>
-         </fileset>
-         <fileset dir="${build.resources}/scoped/b/ear">
-            <include name="META-INF/*.xml"/>
-         </fileset>
-      </jar>
+      <!--<jar destfile="${build.lib}/scopedB.ear">-->
+         <!--<fileset dir="${build.lib}">-->
+            <!--<include name="scopedB.jar"/>-->
+         <!--</fileset>-->
+         <!--<fileset dir="${build.resources}/scoped/b/ear">-->
+            <!--<include name="META-INF/*.xml"/>-->
+         <!--</fileset>-->
+      <!--</jar>-->
 
    </target>
 </project>

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-13 14:14:17 UTC (rev 59013)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-13 17:52:02 UTC (rev 59014)
@@ -31,7 +31,26 @@
 import org.jboss.test.scoped.interfaces.b.SessionB;
 
 import javax.management.Attribute;
+import java.io.File;
 
+import java.net.URL;
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+import junit.framework.Test;
+
+import org.jboss.mx.loading.UnifiedLoaderRepository3;
+import org.jboss.mx.loading.RepositoryClassLoader;
+import org.jboss.test.util.ClassMover;
+import org.apache.log4j.Logger;
+import javassist.ClassPool;
+import javassist.CtClass;
+import javassist.CtField;
+import javassist.Modifier;
+
+
 /**
  * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  */
@@ -45,6 +64,55 @@
    public void testScoped() throws Exception
    {
       isolateDeployments(Boolean.TRUE);
+
+      // have to create response classes with different serialVersionUID for each deployment
+      String jbosstestDeployDir = System.getProperty("jbosstest.deploy.dir");
+      System.out.println("jbosstestDeployDir = " + jbosstestDeployDir);
+      String deployADir = "/scopedA.ear/scopedA.jar";
+      File libDir = new File(jbosstestDeployDir, deployADir);
+      System.out.println("libDir = " + libDir.getAbsolutePath());
+      // Create a SimpleResponseDTO class with a static serialVersionUID of 1L
+      //ClassPool defaultPool = ClassPool.getDefault();
+      ClassPool classes1Pool = ClassPool.getDefault();
+      //ClassPool classes1Pool = new ClassPool(defaultPool);
+      CtClass info = classes1Pool.makeClass("org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO");
+      CtClass s = classes1Pool.get("java.lang.String");
+      CtField firstName = new CtField(s, "firstName", info);
+      firstName.setModifiers(Modifier.PUBLIC);
+      CtClass s2 = classes1Pool.get("java.lang.String");
+      CtField lastName = new CtField(s2, "lastName", info);
+      lastName.setModifiers(Modifier.PUBLIC);
+      CtClass s3 = classes1Pool.get("java.lang.Long");
+      CtField serialVersion = new CtField(s3, "serialVersionUID", info);
+      serialVersion.setModifiers(Modifier.PUBLIC | Modifier.STATIC);
+      long serialVerionUID = 1L;
+      info.addField(serialVersion, CtField.Initializer.constant(serialVerionUID));
+
+      info.writeFile(libDir.getAbsolutePath());
+
+      String deployADirB = "/scopedB.ear/scopedB.jar";
+      File libDirB = new File(jbosstestDeployDir, deployADirB);
+      System.out.println("libDirB = " + libDirB.getAbsolutePath());
+      // Create a SimpleResponseDTO class with a static serialVersionUID of 1L
+      //ClassPool defaultPool = ClassPool.getDefault();
+      ClassPool classes1PoolB = ClassPool.getDefault();
+      //ClassPool classes1Pool = new ClassPool(defaultPool);
+      CtClass infoB = classes1PoolB.makeClass("org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO");
+      CtClass sB = classes1PoolB.get("java.lang.String");
+      CtField firstNameB = new CtField(sB, "firstName", infoB);
+      firstNameB.setModifiers(Modifier.PUBLIC);
+      CtClass s2B = classes1PoolB.get("java.lang.String");
+      CtField lastNameB = new CtField(s2B, "lastName", infoB);
+      lastNameB.setModifiers(Modifier.PUBLIC);
+      CtClass s3B = classes1PoolB.get("java.lang.Long");
+      CtField serialVersionB = new CtField(s3B, "serialVersionUID", infoB);
+      serialVersionB.setModifiers(Modifier.PUBLIC | Modifier.STATIC);
+      long serialVerionUIDB = 2L;
+      infoB.addField(serialVersionB, CtField.Initializer.constant(serialVerionUIDB));
+
+      infoB.writeFile(libDirB.getAbsolutePath());
+
+
       try
       {
          deploy("scopedA.ear");
@@ -58,12 +126,12 @@
             }
             finally
             {
-               undeploy("scopedB.ear");
+               //undeploy("scopedB.ear");
             }
 
             // Run the test after a redeployment
 //            deploy("scopedB.ear");
-//            try
+//            try                     x
 //            {
 //               doTest();
 //            }
@@ -74,7 +142,7 @@
          }
          finally
          {
-            undeploy("scopedA.ear");
+            //undeploy("scopedA.ear");
          }
       }
       finally



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 12:55:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 12:55:23 -0500
Subject: [jboss-cvs] JBossAS SVN: r59015 -
	branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test
Message-ID: <E1GuYKB-0004Gh-U3@committer01.frg.pub.inap.atl.jboss.com>

Author: tom.elrod at jboss.com
Date: 2006-12-13 12:55:22 -0500 (Wed, 13 Dec 2006)
New Revision: 59015

Modified:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
Log:
JBAS-3198 - fix for pooled invoker scoped deployments class caching.

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-13 17:52:02 UTC (rev 59014)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-13 17:55:22 UTC (rev 59015)
@@ -65,6 +65,8 @@
    {
       isolateDeployments(Boolean.TRUE);
 
+      // scoped deployment A
+
       // have to create response classes with different serialVersionUID for each deployment
       String jbosstestDeployDir = System.getProperty("jbosstest.deploy.dir");
       System.out.println("jbosstestDeployDir = " + jbosstestDeployDir);
@@ -90,6 +92,8 @@
 
       info.writeFile(libDir.getAbsolutePath());
 
+      // scoped deployment B
+
       String deployADirB = "/scopedB.ear/scopedB.jar";
       File libDirB = new File(jbosstestDeployDir, deployADirB);
       System.out.println("libDirB = " + libDirB.getAbsolutePath());



From msurtani at jboss.com  Wed Dec 13 12:59:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 12:59:03 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GuYNj-0004LZ-5S@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 12:59:03

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        Version.java
  Log:
  Updated for 1.4.1.CR1
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.18.2.7  +7 -6      JBossCache/src/org/jboss/cache/Version.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Version.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Version.java,v
  retrieving revision 1.18.2.6
  retrieving revision 1.18.2.7
  diff -u -b -r1.18.2.6 -r1.18.2.7
  --- Version.java	13 Dec 2006 16:05:43 -0000	1.18.2.6
  +++ Version.java	13 Dec 2006 17:59:03 -0000	1.18.2.7
  @@ -6,13 +6,14 @@
    * Contains version information about this release of TreeCache.
    *
    * @author Bela Ban
  - * @version $Id: Version.java,v 1.18.2.6 2006/12/13 16:05:43 msurtani Exp $
  + * @version $Id: Version.java,v 1.18.2.7 2006/12/13 17:59:03 msurtani Exp $
    */
   public class Version
   {
      public static final String version = "1.4.1.CR1";
  +   public static final String codename = "Habanero";
      public static byte[] version_id = {'0', '1', '4', '1', 'C'};
  -   public static final String cvs = "$Id: Version.java,v 1.18.2.6 2006/12/13 16:05:43 msurtani Exp $";
  +   public static final String cvs = "$Id: Version.java,v 1.18.2.7 2006/12/13 17:59:03 msurtani Exp $";
   
      private static final int MAJOR_SHIFT = 11;
      private static final int MINOR_SHIFT = 6;
  @@ -29,16 +30,16 @@
      public static void main(String[] args)
      {
         System.out.println("\nVersion: \t" + version);
  +      System.out.println("Codename: \t" + codename);
         System.out.println("CVS:      \t" + cvs);
  -      System.out.println("History:  \t(see docs/Changelog.txt for details)\n");
  +      System.out.println("History:  \t(see http://jira.jboss.com/jira/browse/JBCACHE for details)\n");
      }
   
      /**
       * Returns version information as a string.
       */
  -   public static String printVersion()
  -   {
  -      return "JBossCache " + version + "[ " + cvs + "]";
  +    public static String printVersion() {
  +        return "JBossCache '" + codename + "' " + version + "[ " + cvs + "]";
      }
   
      public static String printVersionId(byte[] v, int len)
  
  
  


From msurtani at jboss.com  Wed Dec 13 13:00:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 13:00:00 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GuYOe-0004Ly-Oa@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 13:00:00

  Modified:    src/org/jboss/cache  Version.java
  Log:
  added code name to printout
  
  Revision  Changes    Path
  1.24      +147 -135  JBossCache/src/org/jboss/cache/Version.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Version.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Version.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- Version.java	17 Nov 2006 13:54:21 -0000	1.23
  +++ Version.java	13 Dec 2006 18:00:00 -0000	1.24
  @@ -6,13 +6,14 @@
    * Contains version information about this release of TreeCache.
    *
    * @author Bela Ban
  - * @version $Id: Version.java,v 1.23 2006/11/17 13:54:21 msurtani Exp $
  + * @version $Id: Version.java,v 1.24 2006/12/13 18:00:00 msurtani Exp $
    */
  -public class Version {
  -    public static final String version="2.0.0.ALPHA1";
  +public class Version
  +{
  +   public static final String version = "2.0.0.ALPHA1";
       public static final String codename = "Habanero";
  -    public static byte[] version_id={'0', '2', '0', '0', 'a'};
  -    public static final String cvs="$Id: Version.java,v 1.23 2006/11/17 13:54:21 msurtani Exp $";
  +   public static byte[] version_id = {'0', '2', '0', '0', 'a'};
  +   public static final String cvs = "$Id: Version.java,v 1.24 2006/12/13 18:00:00 msurtani Exp $";
   
       private static final int MAJOR_SHIFT = 11;
       private static final int MINOR_SHIFT = 6;
  @@ -20,14 +21,16 @@
       private static final int MINOR_MASK = 0x0007c0;
       private static final int PATCH_MASK = 0x00003f;
   
  -    private static final short SHORT_1_2_3     = encodeVersion(1,2,3);
  -    private static final short SHORT_1_2_4_SP2 = encodeVersion(1,2,4);
  +   private static final short SHORT_1_2_3 = encodeVersion(1, 2, 3);
  +   private static final short SHORT_1_2_4_SP2 = encodeVersion(1, 2, 4);
   
       /**
        * Prints version information.
        */
  -    public static void main(String[] args) {
  +   public static void main(String[] args)
  +   {
           System.out.println("\nVersion: \t" + version);
  +      System.out.println("Codename: \t" + codename);
           System.out.println("CVS:      \t" + cvs);
           System.out.println("History:  \t(see http://jira.jboss.com/jira/browse/JBCACHE for details)\n");
       }
  @@ -35,44 +38,52 @@
       /**
        * Returns version information as a string.
        */
  -    public static String printVersion() {
  +   public static String printVersion()
  +   {
           return "JBossCache '" + codename + "' " + version + "[ " + cvs + "]";
       }
   
  -    public static String printVersionId(byte[] v, int len) {
  -        StringBuffer sb=new StringBuffer();
  -        if(v != null) {
  -            if(len <= 0)
  -                len=v.length;
  -            for(int i=0; i < len; i++)
  -                sb.append((char)v[i]);
  +   public static String printVersionId(byte[] v, int len)
  +   {
  +      StringBuffer sb = new StringBuffer();
  +      if (v != null)
  +      {
  +         if (len <= 0)
  +            len = v.length;
  +         for (int i = 0; i < len; i++)
  +            sb.append((char) v[i]);
           }
           return sb.toString();
       }
   
  -    public static String printVersionId(byte[] v) {
  -        StringBuffer sb=new StringBuffer();
  -        if(v != null) {
  -            for(int i=0; i < v.length; i++)
  -                sb.append((char)v[i]);
  +   public static String printVersionId(byte[] v)
  +   {
  +      StringBuffer sb = new StringBuffer();
  +      if (v != null)
  +      {
  +         for (int i = 0; i < v.length; i++)
  +            sb.append((char) v[i]);
           }
           return sb.toString();
       }
   
   
  -    public static boolean compareTo(byte[] v) {
  -        if(v == null)
  +   public static boolean compareTo(byte[] v)
  +   {
  +      if (v == null)
               return false;
  -        if(v.length < version_id.length)
  +      if (v.length < version_id.length)
               return false;
  -        for(int i=0; i < version_id.length; i++) {
  -            if(version_id[i] != v[i])
  +      for (int i = 0; i < version_id.length; i++)
  +      {
  +         if (version_id[i] != v[i])
                   return false;
           }
           return true;
       }
   
  -    public static int getLength() {
  +   public static int getLength()
  +   {
           return version_id.length;
       }
   
  @@ -137,7 +148,7 @@
          int major = (version & MAJOR_MASK) >>  MAJOR_SHIFT;
          int minor = (version & MINOR_MASK) >>  MINOR_SHIFT;
          int patch = (version & PATCH_MASK);
  -       String versionString = major +"."+minor+"."+patch;
  +      String versionString = major + "." + minor + "." + patch;
          return versionString;
       }
   
  @@ -151,6 +162,7 @@
         public static void main(String[] args)
         {
            System.out.println("\nVersion: \t" + version + " (Retroweaved for JDK 1.4.x compatibility)");
  +         System.out.println("Codename: \t" + codename);
            System.out.println("CVS:      \t" + cvs);
            System.out.println("History:  \t(see http://jira.jboss.com/jira/browse/JBCACHE for details)\n");
         }
  
  
  


From msurtani at jboss.com  Wed Dec 13 13:07:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 13:07:44 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options  ...
Message-ID: <E1GuYW8-0004h6-5u@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 13:07:44

  Modified:    tests/functional/org/jboss/cache/options  Tag:
                        Branch_JBossCache_1_4_0 FailSilentlyTest.java
  Log:
  Added further tests
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.4.1   +130 -208  JBossCache/tests/functional/org/jboss/cache/options/FailSilentlyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FailSilentlyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/FailSilentlyTest.java,v
  retrieving revision 1.2
  retrieving revision 1.2.4.1
  diff -u -b -r1.2 -r1.2.4.1
  --- FailSilentlyTest.java	28 Nov 2005 15:55:59 -0000	1.2
  +++ FailSilentlyTest.java	13 Dec 2006 18:07:44 -0000	1.2.4.1
  @@ -7,14 +7,14 @@
   package org.jboss.cache.options;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.Fqn;
  +import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Option;
   
  -import javax.transaction.TransactionManager;
   import javax.transaction.Transaction;
  -import java.util.Map;
  +import javax.transaction.TransactionManager;
   import java.util.HashMap;
  +import java.util.Map;
   
   /**
    * Tests passing in the failSilently option in various scenarios.
  @@ -42,11 +42,23 @@
           manager = cache.getTransactionManager();
   
           failSilently = new Option();
  -        failSilently.setFailSilently( true );
  +      failSilently.setFailSilently(true);
       }
   
       protected void tearDown()
       {
  +      if (tx != null)
  +      {
  +         try
  +         {
  +            manager.resume(tx);
  +            manager.rollback();
  +         }
  +         catch (Exception e)
  +         {
  +
  +         }
  +      }
           if (cache != null)
           {
               cache.stopService();
  @@ -56,58 +68,25 @@
   
       public void testPutKeyValue() throws Exception
       {
  -        try
  -        {
               manager.begin();
               cache.put(fqn, key, "value");
               tx = manager.suspend();
               cache.put(fqn, key, "value2", failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  -            {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  -    }
   
       public void testPutData() throws Exception
       {
           Map data = new HashMap();
           data.put(key, "value");
  -        try
  -        {
               manager.begin();
               cache.put(fqn, data);
               tx = manager.suspend();
               cache.put(fqn, data, failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  -            {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  -    }
  -
   
   
       public void testRemoveNode() throws Exception
       {
  -        try
  -        {
               cache.put(fqn, key, "value");
               manager.begin();
               // get a read lock
  @@ -115,24 +94,9 @@
               tx = manager.suspend();
               cache.remove(fqn, failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  -            {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  -    }
   
       public void testRemoveKey() throws Exception
       {
  -        try
  -        {
               cache.put(fqn, key, "value");
               manager.begin();
               // get a read lock
  @@ -140,24 +104,9 @@
               tx = manager.suspend();
               cache.remove(fqn, key, failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  -            {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  -    }
   
       public void testGetNode() throws Exception
       {
  -        try
  -        {
               cache.put(fqn, key, "value");
               manager.begin();
               // get a WL
  @@ -165,24 +114,9 @@
               tx = manager.suspend();
               cache.get(fqn, failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  -            {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  -    }
   
       public void testGetKey() throws Exception
       {
  -        try
  -        {
               cache.put(fqn, key, "value");
               manager.begin();
               // get a WL
  @@ -190,24 +124,9 @@
               tx = manager.suspend();
               cache.get(fqn, key, failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  -            {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  -    }
   
       public void testGetChildrenNames() throws Exception
       {
  -        try
  -        {
               cache.put(fqn, key, "value");
               manager.begin();
               // get a WL
  @@ -215,17 +134,20 @@
               tx = manager.suspend();
               cache.getChildrenNames(fqn, failSilently);
           }
  -        catch (Exception e)
  -        {
  -            throw e;
  -        }
  -        finally
  -        {
  -            if (tx != null)
  +
  +   public void testPutThatWillFail() throws Exception
               {
  -                manager.resume(tx);
  -                manager.rollback();
  -            }
  -        }
  +      manager.begin();
  +      cache.put(fqn, "k", "v"); // this will get WLs on / and /a
  +      tx = manager.suspend();
  +
  +      assertEquals(2, cache.getNumberOfLocksHeld());
  +
  +      // now this call WILL fail, but should fail silently - i.e., not roll back.
  +      manager.begin();
  +      cache.put(fqn, "x", "y", failSilently);
  +
  +      // should not roll back, despite the cache put call failing/timing out.
  +      manager.commit();
       }
   }
  
  
  


From msurtani at jboss.com  Wed Dec 13 13:15:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 13 Dec 2006 13:15:52 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options  ...
Message-ID: <E1GuYe0-0004pH-1W@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/13 13:15:52

  Modified:    tests/functional/org/jboss/cache/options 
                        FailSilentlyTest.java
  Log:
  added tests
  
  Revision  Changes    Path
  1.6       +70 -159   JBossCache/tests/functional/org/jboss/cache/options/FailSilentlyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FailSilentlyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/FailSilentlyTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- FailSilentlyTest.java	7 Sep 2006 15:42:16 -0000	1.5
  +++ FailSilentlyTest.java	13 Dec 2006 18:15:52 -0000	1.6
  @@ -39,24 +39,22 @@
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.start();
         manager = cache.getTransactionManager();
  +   }
   
  -      // kill any ongoing tx's.
  -      if (manager.getTransaction() != null)
  +   protected void tearDown()
  +   {
  +      if (tx != null)
         {
            try
            {
  +            manager.resume(tx);
               manager.rollback();
            }
            catch (Exception e)
            {
  -            // do nothing
  -         }
  +            // who cares
         }
  -
      }
  -
  -   protected void tearDown()
  -   {
         if (cache != null)
         {
            cache.stop();
  @@ -66,59 +64,27 @@
   
      public void testPutKeyValue() throws Exception
      {
  -      try
  -      {
            manager.begin();
            cache.put(fqn, key, "value");
            tx = manager.suspend();
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.put(fqn, key, "value2");
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  -         {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  -   }
   
      public void testPutData() throws Exception
      {
  -      Map data = new HashMap();
  +      Map<String, String> data = new HashMap<String, String>();
         data.put(key, "value");
  -      try
  -      {
            manager.begin();
            cache.put(fqn, data);
            tx = manager.suspend();
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.put(fqn, data);
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  -         {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  -   }
   
   
      public void testRemoveNode() throws Exception
      {
  -      try
  -      {
            cache.put(fqn, key, "value");
            manager.begin();
            // get a read lock
  @@ -127,24 +93,9 @@
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.remove(fqn);
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  -         {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  -   }
   
      public void testRemoveKey() throws Exception
      {
  -      try
  -      {
            cache.put(fqn, key, "value");
            manager.begin();
            // get a read lock
  @@ -153,24 +104,9 @@
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.remove(fqn, key);
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  -         {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  -   }
   
      public void testGetNode() throws Exception
      {
  -      try
  -      {
            cache.put(fqn, key, "value");
            manager.begin();
            // get a WL
  @@ -179,24 +115,9 @@
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.get(fqn);
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  -         {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  -   }
   
      public void testGetKey() throws Exception
      {
  -      try
  -      {
            cache.put(fqn, key, "value");
            manager.begin();
            // get a WL
  @@ -205,24 +126,9 @@
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.get(fqn, key);
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  -         {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  -   }
   
      public void testGetChildrenNames() throws Exception
      {
  -      try
  -      {
            cache.put(fqn, key, "value");
            manager.begin();
            // get a WL
  @@ -230,18 +136,23 @@
            tx = manager.suspend();
            cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
            cache.getChildrenNames(fqn);
  +
         }
  -      catch (Exception e)
  -      {
  -         throw e;
  -      }
  -      finally
  -      {
  -         if (tx != null)
  +
  +   public void testPutThatWillFail() throws Exception
            {
  -            manager.resume(tx);
  -            manager.rollback();
  -         }
  -      }
  +      manager.begin();
  +      cache.put(fqn, "k", "v"); // this will get WLs on / and /a
  +      tx = manager.suspend();
  +
  +      assertEquals(2, cache.getNumberOfLocksHeld());
  +
  +      // now this call WILL fail, but should fail silently - i.e., not roll back.
  +      manager.begin();
  +      cache.getInvocationContext().getOptionOverrides().setFailSilently(true);
  +      cache.put(fqn, "x", "y");
  +
  +      // should not roll back, despite the cache put call failing/timing out.
  +      manager.commit();
      }
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 13:16:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 13:16:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59016 -
	branches/Branch_4_2/server/src/etc/conf/default
Message-ID: <E1GuYeU-0004qR-Qa@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-13 13:16:20 -0500 (Wed, 13 Dec 2006)
New Revision: 59016

Modified:
   branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml
Log:
JBAS-3892, Replace TxManager with JBoss Transactions JTA

Modified: branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml	2006-12-13 17:55:22 UTC (rev 59015)
+++ branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml	2006-12-13 18:16:20 UTC (rev 59016)
@@ -305,6 +305,7 @@
    <!-- ==================================================================== -->
    <!-- Transactions                                                         -->
    <!-- ==================================================================== -->
+
    <!-- The configurable Xid factory.  For use with Oracle, set pad to true -->
    <mbean code="org.jboss.tm.XidFactory"
       name="jboss:service=XidFactory">
@@ -313,23 +314,32 @@
 
    <!--
       | The fast in-memory transaction manager.
-    -->
+      | Deprecated in JBossAS v4.2. Use JBossTS JTA instead.
+    - ->
    <mbean code="org.jboss.tm.TransactionManagerService"
       name="jboss:service=TransactionManager"
       xmbean-dd="resource:xmdesc/TransactionManagerService-xmbean.xml">
       <attribute name="TransactionTimeout">300</attribute>
-      <!-- set to false to disable transaction demarcation over IIOP -->
+      <!- - set to false to disable transaction demarcation over IIOP - ->
       <attribute name="GlobalIdsEnabled">true</attribute>
       <depends optional-attribute-name="XidFactory">jboss:service=XidFactory</depends>
 
-      <!-- Transaction Integrity Checking -->
-      <!-- Force a rollback if another thread is associated with the transaction at commit -->
-      <!--depends optional-attribute-name="TransactionIntegrityFactory" 
+      <!- - Transaction Integrity Checking - ->
+      <!- - Force a rollback if another thread is associated with the transaction at commit - ->
+      <!- - <depends optional-attribute-name="TransactionIntegrityFactory" 
                proxy-type="org.jboss.tm.integrity.TransactionIntegrityFactory">
          <mbean code="org.jboss.tm.integrity.FailIncompleteTransaction"
                 name="jboss:service=TransactionManager,plugin=TransactionIntegrity"/>
-      </depends-->
+      </depends> - ->
    </mbean>
+   -->
+   
+   <!-- JBoss Transactions JTA -->
+   <mbean code="com.arjuna.ats.jbossatx.jta.TransactionManagerService"
+      name="jboss:service=TransactionManager">
+      <attribute name="TransactionTimeout">300</attribute>
+   </mbean>
+   
    <!--
       | UserTransaction support.
     -->



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 13:16:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 13:16:53 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59017 - branches/Branch_4_2/build
Message-ID: <E1GuYez-0004rg-T1@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-13 13:16:51 -0500 (Wed, 13 Dec 2006)
New Revision: 59017

Modified:
   branches/Branch_4_2/build/build-distr.xml
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
JBAS-3892, Replace TxManager with JBoss Transactions JTA

Modified: branches/Branch_4_2/build/build-distr.xml
===================================================================
--- branches/Branch_4_2/build/build-distr.xml	2006-12-13 18:16:20 UTC (rev 59016)
+++ branches/Branch_4_2/build/build-distr.xml	2006-12-13 18:16:51 UTC (rev 59017)
@@ -1104,6 +1104,16 @@
       </fileset>
     </copy>
 
+    <!-- copy binary release of JBossTS from thirdparty repo -->
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${project.thirdparty}/jboss/jbossts/lib/">
+        <include name="jbossjta.jar"/>
+        <include name="jbossjta-integration.jar"/>
+        <include name="jbossts-common.jar"/>
+      </fileset>
+    </copy>
+    <copy todir="${install.all.conf}" filtering="no" file="${project.thirdparty}/jboss/jbossts/resources/jbossjta-properties.xml"/>
+
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-13 18:16:20 UTC (rev 59016)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-13 18:16:51 UTC (rev 59017)
@@ -91,6 +91,7 @@
       <componentref name="jboss/common" version="1.0.0.GA"/>
       <componentref name="jboss/dom4j-jarjar" version="1.6.1"/>
       <componentref name="jboss/jbossretro-rt" version="1.0.4.GA"/>
+      <componentref name="jboss/jbossts" version="4.2.2.GA"/>
       <componentref name="jboss/jbossws" version="1.0.4.GA"/>
       <componentref name="jboss/jbossws14" version="1.0.4.GA"/>
       <componentref name="jboss/jboss-ws4ee" version="4.0.4.SP1"/>



From rawblem at gmail.com  Wed Dec 13 13:30:50 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:30:50 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors
	...
Message-ID: <E1GuYsU-00055g-FU@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:30:50

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors 
                        ServiceXMLOutlineConfiguration.java
  Log:
  Added another extension point to allow actions to be added to the outline view for xml elements. This was done so that the mbeans project does not directly depend on as.ui, and as.ui can extend as.ui.mbeans. 
  
  Not that this matters much.
  
  Revision  Changes    Path
  1.2       +48 -9     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLOutlineConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServiceXMLOutlineConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLOutlineConfiguration.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ServiceXMLOutlineConfiguration.java	16 Nov 2006 22:45:30 -0000	1.1
  +++ ServiceXMLOutlineConfiguration.java	13 Dec 2006 18:30:50 -0000	1.2
  @@ -23,29 +23,29 @@
   
   import java.util.ArrayList;
   
  +import org.eclipse.core.runtime.CoreException;
  +import org.eclipse.core.runtime.IConfigurationElement;
  +import org.eclipse.core.runtime.IExtensionRegistry;
  +import org.eclipse.core.runtime.Platform;
   import org.eclipse.jface.action.IMenuListener;
   import org.eclipse.jface.action.IMenuManager;
  -import org.eclipse.jface.resource.ImageRegistry;
  -import org.eclipse.jface.resource.JFaceResources;
   import org.eclipse.jface.viewers.IContentProvider;
   import org.eclipse.jface.viewers.ILabelProvider;
  +import org.eclipse.jface.viewers.ISelection;
   import org.eclipse.jface.viewers.ITreeContentProvider;
   import org.eclipse.jface.viewers.LabelProvider;
   import org.eclipse.jface.viewers.TreeViewer;
   import org.eclipse.jface.viewers.Viewer;
   import org.eclipse.swt.graphics.Image;
   import org.eclipse.wst.sse.ui.internal.IReleasable;
  -import org.eclipse.wst.xml.core.internal.contentmodel.CMNode;
  -import org.eclipse.wst.xml.core.internal.contentmodel.modelquery.ModelQuery;
   import org.eclipse.wst.xml.core.internal.document.DOMModelImpl;
  -import org.eclipse.wst.xml.core.internal.modelquery.ModelQueryUtil;
   import org.eclipse.wst.xml.core.internal.provisional.document.IDOMModel;
   import org.eclipse.wst.xml.ui.internal.contentoutline.XMLNodeActionManager;
  -import org.eclipse.wst.xml.ui.internal.editor.CMImageUtil;
   import org.eclipse.wst.xml.ui.internal.editor.XMLEditorPluginImageHelper;
   import org.eclipse.wst.xml.ui.internal.editor.XMLEditorPluginImages;
   import org.eclipse.wst.xml.ui.views.contentoutline.XMLContentOutlineConfiguration;
  -import org.w3c.dom.Attr;
  +import org.jboss.ide.eclipse.as.ui.mbeans.Activator;
  +import org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals.IServiceXMLOutlineActionProvider;
   import org.w3c.dom.NamedNodeMap;
   import org.w3c.dom.Node;
   
  @@ -171,16 +171,34 @@
   	
   	private ActionManagerMenuListener fContextMenuFiller = null;
   
  -	
   	/**
   	 * Pilfered from superclass, where it's currently PRIVATE (BOOOO!)
   	 */
   	private class ActionManagerMenuListener implements IMenuListener, IReleasable {
   		private XMLNodeActionManager fActionManager;
   		private TreeViewer fTreeViewer;
  +		private OutlineMenuProvider[] menuProviders = null;
   
   		public ActionManagerMenuListener(TreeViewer viewer) {
   			fTreeViewer = viewer;
  +			
  +		}
  +
  +		public OutlineMenuProvider[] getProviders() {
  +			if( menuProviders == null ) {
  +				ArrayList list = new ArrayList();
  +				IExtensionRegistry registry = Platform.getExtensionRegistry();
  +				IConfigurationElement[] cf = registry.getConfigurationElementsFor(Activator.PLUGIN_ID, "ServiceXMLOutlineMenuProvider");
  +				for( int i = 0; i < cf.length; i++ ) {
  +					try {
  +						list.add(new OutlineMenuProvider(cf[i]));
  +					} catch( CoreException ce ) {
  +						ce.printStackTrace();
  +					}
  +				}
  +				menuProviders = (OutlineMenuProvider[]) list.toArray(new OutlineMenuProvider[list.size()]);
  +			}
  +			return menuProviders;
   		}
   
   		public void menuAboutToShow(IMenuManager manager) {
  @@ -188,6 +206,9 @@
   				fActionManager = createNodeActionManager(fTreeViewer);
   			}
   			fActionManager.fillContextMenu(manager, fTreeViewer.getSelection());
  +			for( int i = 0; i < getProviders().length; i++ ) {
  +				getProviders()[i].menuAboutToShow(manager, fTreeViewer.getSelection());
  +			}
   		}
   
   		public void release() {
  @@ -195,6 +216,24 @@
   			if (fActionManager != null) {
   				fActionManager.setModel(null);
   			}
  +			for( int i = 0; i < getProviders().length; i++ ) {
  +				getProviders()[i].release();
  +			}
  +		}
  +	}
  +	
  +	private static class OutlineMenuProvider {
  +		private IServiceXMLOutlineActionProvider listener;
  +		public OutlineMenuProvider(IConfigurationElement element) throws CoreException {
  +			listener = (IServiceXMLOutlineActionProvider)element.createExecutableExtension("class");
  +		}
  +		public void menuAboutToShow(IMenuManager manager, ISelection selection) {
  +			if( listener != null ) listener.menuAboutToShow(manager, selection);
  +		}
  +		public void release() {
  +			if( listener != null && listener instanceof IReleasable) {
  +				((IReleasable)listener).release();
  +			}
   		}
   	}
   	
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:30:50 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:30:50 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema ...
Message-ID: <E1GuYsU-00055n-JZ@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:30:50

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema 
                        ServiceXMLOutlineMenuProvider.exsd
  Log:
  Added another extension point to allow actions to be added to the outline view for xml elements. This was done so that the mbeans project does not directly depend on as.ui, and as.ui can extend as.ui.mbeans. 
  
  Not that this matters much.
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 18:30:50;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema/ServiceXMLOutlineMenuProvider.exsd
  
  Index: ServiceXMLOutlineMenuProvider.exsd
  ===================================================================
  <?xml version='1.0' encoding='UTF-8'?>
  <!-- Schema file written by PDE -->
  <schema targetNamespace="org.jboss.ide.eclipse.as.ui.mbeans">
  <annotation>
        <appInfo>
           <meta.schema plugin="org.jboss.ide.eclipse.as.ui.mbeans" id="ServiceXMLOutlineMenuProvider" name="org.jboss.ide.eclipse.as.ui.mbeans.serviceXMLOutlineMenuProvider"/>
        </appInfo>
        <documentation>
           [Enter description of this extension point.]
        </documentation>
     </annotation>
  
     <element name="extension">
        <complexType>
           <sequence>
              <element ref="MenuProvider" minOccurs="1" maxOccurs="unbounded"/>
           </sequence>
           <attribute name="point" type="string" use="required">
              <annotation>
                 <documentation>
                    
                 </documentation>
              </annotation>
           </attribute>
           <attribute name="id" type="string">
              <annotation>
                 <documentation>
                    
                 </documentation>
              </annotation>
           </attribute>
           <attribute name="name" type="string">
              <annotation>
                 <documentation>
                    
                 </documentation>
                 <appInfo>
                    <meta.attribute translatable="true"/>
                 </appInfo>
              </annotation>
           </attribute>
        </complexType>
     </element>
  
     <element name="MenuProvider">
        <complexType>
           <attribute name="class" type="string" use="required">
              <annotation>
                 <documentation>
                    
                 </documentation>
                 <appInfo>
                    <meta.attribute kind="java" basedOn="org.eclipse.jface.action.IMenuListener"/>
                 </appInfo>
              </annotation>
           </attribute>
        </complexType>
     </element>
  
     <annotation>
        <appInfo>
           <meta.section type="since"/>
        </appInfo>
        <documentation>
           [Enter the first release in which this extension point appears.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="examples"/>
        </appInfo>
        <documentation>
           [Enter extension point usage example here.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="apiInfo"/>
        </appInfo>
        <documentation>
           [Enter API information here.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="implementation"/>
        </appInfo>
        <documentation>
           [Enter information about supplied implementation of this extension point.]
        </documentation>
     </annotation>
  
     <annotation>
        <appInfo>
           <meta.section type="copyright"/>
        </appInfo>
        <documentation>
           
        </documentation>
     </annotation>
  
  </schema>
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:30:50 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:30:50 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans ...
Message-ID: <E1GuYsU-00055u-OR@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:30:50

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui.mbeans  plugin.xml
  Log:
  Added another extension point to allow actions to be added to the outline view for xml elements. This was done so that the mbeans project does not directly depend on as.ui, and as.ui can extend as.ui.mbeans. 
  
  Not that this matters much.
  
  Revision  Changes    Path
  1.3       +1 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/plugin.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- plugin.xml	4 Dec 2006 17:47:39 -0000	1.2
  +++ plugin.xml	13 Dec 2006 18:30:50 -0000	1.3
  @@ -2,6 +2,7 @@
   <?eclipse version="3.2"?>
   <plugin>
      <extension-point id="ServiceXMLQuickFixProvider" name="org.jboss.ide.eclipse.as.ui.mbeans.serviceXMLQuickFixProvider" schema="schema/ServiceXMLQuickFixProvider.exsd"/>
  +   <extension-point id="ServiceXMLOutlineMenuProvider" name="org.jboss.ide.eclipse.as.ui.mbeans.serviceXMLOutlineMenuProvider" schema="schema/ServiceXMLOutlineMenuProvider.exsd"/>
      <extension
            point="org.eclipse.core.runtime.contentTypes">
         <content-type
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:30:50 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:30:50 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals
	...
Message-ID: <E1GuYsU-000561-Sf@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:30:50

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals 
                        IServiceXMLOutlineActionProvider.java
  Log:
  Added another extension point to allow actions to be added to the outline view for xml elements. This was done so that the mbeans project does not directly depend on as.ui, and as.ui can extend as.ui.mbeans. 
  
  Not that this matters much.
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 18:30:50;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals/IServiceXMLOutlineActionProvider.java
  
  Index: IServiceXMLOutlineActionProvider.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.ui.mbeans.editors.proposals;
  
  import org.eclipse.jface.action.IMenuManager;
  import org.eclipse.jface.viewers.ISelection;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public interface IServiceXMLOutlineActionProvider {
  	public void menuAboutToShow(IMenuManager manager, ISelection selection);
  }
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:32:13 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:32:13 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions
	...
Message-ID: <E1GuYtp-00058K-WB@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:32:13

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions  
                        ServerViewProvider.java
                        JBossServerViewExtension.java
  Log:
  Allowed a mechanism so that if an image path is not given via extension point, the implementing view provider can use one from another location, presumably a shared image from the platform, or wherever it chooses. 
  
  Revision  Changes    Path
  1.3       +5 -4      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/ServerViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/ServerViewProvider.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ServerViewProvider.java	29 Nov 2006 18:39:27 -0000	1.2
  +++ ServerViewProvider.java	13 Dec 2006 18:32:13 -0000	1.3
  @@ -70,9 +70,10 @@
   	public Image getImage() {
   		if( icon == null && iconDescriptor != null ) {
   			icon = iconDescriptor.createImage();
  -		}
  -		if( icon.isDisposed() && iconDescriptor != null ) {
  -			icon = iconDescriptor.createImage(); 
  +		} else if( icon == null && iconDescriptor == null ){
  +			icon = getDelegate().createIcon();
  +		} else if( icon != null && icon.isDisposed()) {
  +			icon = iconDescriptor == null ? getDelegate().createIcon() : iconDescriptor.createImage();
   		}
   		return icon;
   	}
  @@ -118,7 +119,7 @@
   	
   	public void dispose() {
   		getDelegate().dispose();
  -		if( icon != null ) 
  +		if( icon != null && iconDescriptor != null ) 
   			icon.dispose();
   		
   		Preferences prefs = JBossServerUIPlugin.getDefault().getPluginPreferences();
  
  
  
  1.3       +5 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerViewExtension.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JBossServerViewExtension.java	15 Nov 2006 22:26:57 -0000	1.2
  +++ JBossServerViewExtension.java	13 Dec 2006 18:32:13 -0000	1.3
  @@ -3,6 +3,7 @@
   import org.eclipse.jface.action.IMenuManager;
   import org.eclipse.jface.viewers.ITreeContentProvider;
   import org.eclipse.jface.viewers.LabelProvider;
  +import org.eclipse.swt.graphics.Image;
   import org.eclipse.swt.widgets.Composite;
   import org.eclipse.swt.widgets.Shell;
   import org.eclipse.ui.views.properties.IPropertySheetPage;
  @@ -61,6 +62,10 @@
   		return null;
   	}
   	
  +	public Image createIcon() {
  +		return null;
  +	}
  +	
   	protected void refreshViewer() {
   		refreshViewer(null);
   	}
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:32:51 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:32:51 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers
	...
Message-ID: <E1GuYuR-00059Q-Tl@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:32:51

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers 
                        FilesetViewProvider.java
  Log:
  Brand spankin new extension... allows you to browse folders on your HD quickly, set filters, etc
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 18:32:51;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java
  
  Index: FilesetViewProvider.java
  ===================================================================
  package org.jboss.ide.eclipse.as.ui.views.server.providers;
  
  import java.io.File;
  import java.util.ArrayList;
  import java.util.Arrays;
  import java.util.List;
  import java.util.Properties;
  
  import org.eclipse.core.filesystem.EFS;
  import org.eclipse.core.filesystem.IFileStore;
  import org.eclipse.core.runtime.IPath;
  import org.eclipse.core.runtime.NullProgressMonitor;
  import org.eclipse.core.runtime.Path;
  import org.eclipse.core.runtime.Platform;
  import org.eclipse.core.runtime.content.IContentType;
  import org.eclipse.core.runtime.content.IContentTypeManager;
  import org.eclipse.core.runtime.content.IContentTypeMatcher;
  import org.eclipse.jface.action.Action;
  import org.eclipse.jface.action.IMenuManager;
  import org.eclipse.jface.dialogs.Dialog;
  import org.eclipse.jface.resource.ImageDescriptor;
  import org.eclipse.jface.viewers.ITreeContentProvider;
  import org.eclipse.jface.viewers.LabelProvider;
  import org.eclipse.jface.viewers.Viewer;
  import org.eclipse.jface.window.Window;
  import org.eclipse.swt.SWT;
  import org.eclipse.swt.events.ModifyEvent;
  import org.eclipse.swt.events.ModifyListener;
  import org.eclipse.swt.events.SelectionEvent;
  import org.eclipse.swt.events.SelectionListener;
  import org.eclipse.swt.graphics.Image;
  import org.eclipse.swt.layout.GridData;
  import org.eclipse.swt.layout.GridLayout;
  import org.eclipse.swt.widgets.Button;
  import org.eclipse.swt.widgets.Composite;
  import org.eclipse.swt.widgets.Control;
  import org.eclipse.swt.widgets.DirectoryDialog;
  import org.eclipse.swt.widgets.Label;
  import org.eclipse.swt.widgets.Shell;
  import org.eclipse.swt.widgets.Text;
  import org.eclipse.ui.IEditorDescriptor;
  import org.eclipse.ui.IEditorInput;
  import org.eclipse.ui.ISharedImages;
  import org.eclipse.ui.IWorkbench;
  import org.eclipse.ui.IWorkbenchPage;
  import org.eclipse.ui.IWorkbenchWindow;
  import org.eclipse.ui.PlatformUI;
  import org.eclipse.ui.internal.editors.text.JavaFileEditorInput;
  import org.eclipse.ui.internal.util.SWTResourceUtil;
  import org.eclipse.wst.server.core.IServer;
  import org.jboss.ide.eclipse.as.core.server.JBossServer;
  import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper;
  import org.jboss.ide.eclipse.as.ui.views.server.extensions.ServerViewProvider;
  import org.jboss.ide.eclipse.as.ui.views.server.extensions.SimplePropertiesViewExtension;
  import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  
  public class FilesetViewProvider extends SimplePropertiesViewExtension {
  	
  	private static final String FILESET_KEY = "org.jboss.ide.eclipse.as.ui.views.server.providers.FilesetViewProvider.PropertyKey";
  	
  	private Action createFilter, deleteFilter, editFilter, deleteFileAction, editFileAction;
  	
  	private FilesetContentProvider contentProvider;
  	private LabelProvider labelProvider;
  	private Fileset[] filesets;
  	private Object selection;
  
  	public FilesetViewProvider() {
  		contentProvider = new FilesetContentProvider();
  		labelProvider = new FilesetLabelProvider();
  		createActions();
  	}
  	
  	protected void createActions() {
  		createFilter =  new Action() { 
  			public void run() {
  				JBossServer server = (JBossServer)contentProvider.server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  				FilesetDialog d = new FilesetDialog(new Shell(), server);
  				if( d.open() == Window.OK ) {
  					Fileset fs = d.getFileset();
  					Fileset[] filesetsNew = new Fileset[filesets.length + 1];
  					System.arraycopy(filesets, 0, filesetsNew, 0, filesets.length);
  					filesetsNew[filesetsNew.length-1] = fs;
  					filesets = filesetsNew;
  					saveFilesets();
  				}
  			}
  		};
  		createFilter.setText("Create Filter");
  		deleteFilter =  new Action() { 
  			public void run() {
  				if( selection instanceof Fileset ) {
  					try {
  						ArrayList asList = new ArrayList(Arrays.asList(filesets));
  						asList.remove(selection);
  						filesets = (Fileset[]) asList.toArray(new Fileset[asList.size()]);
  						saveFilesets();
  					} catch( Exception e ) {
  						e.printStackTrace();
  					}
  				}
  			}
  		};
  		deleteFilter.setText("Delete Filter");
  		editFilter =  new Action() { 
  			public void run() {
  				Fileset sel = (Fileset)selection;
  				FilesetDialog d = new FilesetDialog(new Shell(), sel);
  				if( d.open() == Window.OK ) {
  					Fileset ret = d.getFileset();
  					sel.setName(ret.getName());
  					sel.setFolder(ret.getFolder());
  					sel.setIncludesPattern(ret.getIncludesPattern());
  					sel.setExcludesPattern(ret.getExcludesPattern());
  					saveFilesets();
  				}
  			}
  		};
  		editFilter.setText("Edit Filter");
  		deleteFileAction =  new Action() { 
  			public void run() {
  				try {
  					PathWrapper wrapper = (PathWrapper)selection;
  					File file = wrapper.getPath().toFile();
  					file.delete();
  				} catch( Exception e ) {
  				}
  			}
  		};
  		deleteFileAction.setText("Delete File");
  		editFileAction =  new Action() { 
  			public void run() {
  				try {
  					PathWrapper wrapper = (PathWrapper)selection;
  					File file = wrapper.getPath().toFile();
  					IWorkbench wb = PlatformUI.getWorkbench();
  					IWorkbenchWindow win = wb.getActiveWorkbenchWindow();
  					IWorkbenchPage page = win.getActivePage();
  					IFileStore fileStore= EFS.getLocalFileSystem().fromLocalFile(file);
  					if( fileStore != null ) {
  						IEditorInput input = new JavaFileEditorInput(fileStore);
  						IEditorDescriptor desc = PlatformUI.getWorkbench().
  							getEditorRegistry().getDefaultEditor(file.getName());
  					   page.openEditor(input, desc.getId());
  					} 
  				} catch( Exception e ) {
  					
  				}
  			}
  		};
  		editFileAction.setText("Edit File");
  	}
  	
  	public static class PathWrapper {
  		private IPath path;
  		private String folder;
  		public PathWrapper(IPath path, String folder) {
  			this.path = path;
  			this.folder = folder;
  		}
  		/**
  		 * @return the folder
  		 */
  		public String getFolder() {
  			return folder;
  		}
  		/**
  		 * @return the path
  		 */
  		public IPath getPath() {
  			return path;
  		}
  		
  		public String getLocalizedResourceName() {
  			return path.toOSString().substring(new Path(folder).toOSString().length());
  		}
  	}
  	public class FilesetContentProvider implements ITreeContentProvider {
  		public IServer server;
  		public Object[] getChildren(Object parentElement) {
  			if( parentElement instanceof ServerViewProvider ) {
  				return filesets;
  			} else if( parentElement instanceof Fileset ) {
  				Fileset fs = (Fileset)parentElement;
  				IPath[] paths = PackagesCore.findMatchingPaths(
  						new Path(fs.getFolder()), fs.getIncludesPattern(), fs.getExcludesPattern());
  				PathWrapper[] wrappers = new PathWrapper[paths.length];
  				for( int i = 0; i < wrappers.length; i++ ) {
  					wrappers[i] = new PathWrapper(paths[i], fs.getFolder());
  				}
  				return wrappers;
  			}
  			return new Object[0];
  		}
  
  		public Object getParent(Object element) {
  			return null;
  		}
  
  		public boolean hasChildren(Object element) {
  			return getChildren(element).length > 0 ? true : false;
  		}
  
  		public Object[] getElements(Object inputElement) {
  			return null;
  		}
  
  		public void dispose() {
  		}
  
  		public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
  			if( newInput instanceof IServer ) {
  				server = (IServer)newInput;
  				loadFilesets();
  			}
  		}
  	}
  
  	public void loadFilesets() {
  		IServer server = contentProvider.server;
  		if( server != null ) {
  			JBossServer jbs = (JBossServer)server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  			ServerAttributeHelper helper = jbs.getAttributeHelper();
  			List tmp = helper.getAttribute(FILESET_KEY, new ArrayList());
  			String[] asStrings = (String[]) tmp.toArray(new String[tmp.size()]);
  			filesets = new Fileset[asStrings.length];
  			for( int i = 0; i < asStrings.length; i++ ) {
  				filesets[i] = new Fileset(asStrings[i]);
  			}
  		}
  	}
  	
  	public void saveFilesets() {
  		IServer server = contentProvider.server;
  		if( server != null ) {
  			ArrayList list = new ArrayList();
  			for( int i = 0; i < filesets.length; i++ ) {
  				list.add(filesets[i].toString());
  			}
  			JBossServer jbs = (JBossServer)server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  			ServerAttributeHelper helper = jbs.getAttributeHelper();
  			helper.setAttribute(FILESET_KEY, list);
  			helper.save();
  		}
  	}
  
  	public class Fileset implements Cloneable {
  		private String name, folder, includesPattern, excludesPattern;
  		public Fileset() {
  		}
  		public Fileset(String string) {
  			try {
  				name = folder = includesPattern =excludesPattern = "";
  				String[] parts = string.split("\n");
  				name = parts[0];
  				folder = parts[1];
  				includesPattern = parts[2];
  				excludesPattern = parts[3];
  			} catch( ArrayIndexOutOfBoundsException aioobe) {}
  		}
  		
  		public Fileset(String name, String folder, String inc, String exc) {
  			this.name = name;
  			this.folder = folder;
  			includesPattern = inc;
  			excludesPattern = exc;
  		}
  		public String toString() {
  			return name + "\n" + folder + "\n" + includesPattern + "\n" + excludesPattern;
  		}
  		/**
  		 * @return the folder
  		 */
  		public String getFolder() {
  			return folder == null ? "" : folder;
  		}
  		/**
  		 * @return the name
  		 */
  		public String getName() {
  			return name == null ? "" : name;
  		}
  		/**
  		 * @return the excludesPattern
  		 */
  		public String getExcludesPattern() {
  			return excludesPattern == null ? "" : excludesPattern;
  		}
  		/**
  		 * @return the includesPattern
  		 */
  		public String getIncludesPattern() {
  			return includesPattern == null ? "" : includesPattern;
  		}
  
  		/**
  		 * @param excludesPattern the excludesPattern to set
  		 */
  		public void setExcludesPattern(String excludesPattern) {
  			this.excludesPattern = excludesPattern;
  		}
  
  		/**
  		 * @param folder the folder to set
  		 */
  		public void setFolder(String folder) {
  			this.folder = folder;
  		}
  
  		/**
  		 * @param includesPattern the includesPattern to set
  		 */
  		public void setIncludesPattern(String includesPattern) {
  			this.includesPattern = includesPattern;
  		}
  
  		/**
  		 * @param name the name to set
  		 */
  		public void setName(String name) {
  			this.name = name;
  		}
  		
  		public Object clone() {
  			try {
  				return super.clone();
  			} catch( Exception e ) {}
  			return null;
  		}
  	}
  	
  	public class FilesetLabelProvider extends LabelProvider {
  	    public Image getImage(Object element) {
  	    	if( element instanceof PathWrapper ) {
  		    	String fileName = ((PathWrapper)element).getPath().toOSString();
  		    	IContentTypeManager manager = Platform.getContentTypeManager();
  		    	IContentTypeMatcher matcher = manager.getMatcher(null, null);
  		    	IContentType contentType = matcher.findContentTypeFor(fileName);
  		        ImageDescriptor descriptor = PlatformUI.getWorkbench().getEditorRegistry()
  		        	.getImageDescriptor(fileName, contentType);
  			    if (descriptor == null) {
  			    	descriptor = PlatformUI.getWorkbench().getSharedImages()
  			                .getImageDescriptor(ISharedImages.IMG_OBJ_FILE);
  				}
  		        Image image = (Image) SWTResourceUtil.getImageTable().get(descriptor);
  		        if (image == null) {
  		            image = descriptor.createImage();
  		            SWTResourceUtil.getImageTable().put(descriptor, image);
  		        }
  		        return image;
  	    	}
  //	    	if( element instanceof Path ) {
  //	    		((Path)element).
  //	    		
  //	    	}
  //			if (resource instanceof IFile) {
  //				contentType = IDE.guessContentType((IFile)resource);
  //			}
  //	        // @issue move IDE specific images
  //	        ImageDescriptor image = PlatformUI.getWorkbench().getEditorRegistry()
  //	                .getImageDescriptor(resource.getName(), contentType);
  //	        if (image == null) {
  //				image = PlatformUI.getWorkbench().getSharedImages()
  //	                    .getImageDescriptor(ISharedImages.IMG_OBJ_FILE);
  //			}
  //	        return image;
  
  	        return null;
  	    }
  
  	    public String getText(Object element) {
  	    	if( element instanceof PathWrapper ) return ((PathWrapper)element).getLocalizedResourceName();
  	    	if( element instanceof Fileset ) return ((Fileset)element).getName();
  	        return element == null ? "" : element.toString();//$NON-NLS-1$
  	    }
  
  	}
  	
  	public Image createIcon() {
  		return PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJ_FILE);
  	}
  
  	
  	public void fillContextMenu(Shell shell, IMenuManager menu, Object selection) {
  		this.selection = selection;
  		if( selection instanceof ServerViewProvider ) {
  			menu.add(createFilter);
  		} else if( selection instanceof Fileset ) {
  			menu.add(editFilter);
  			menu.add(deleteFilter);
  		} else if( selection instanceof PathWrapper ) {
  			menu.add(editFileAction);
  			menu.add(deleteFileAction);
  		}
  	}
  
  	public ITreeContentProvider getContentProvider() {
  		return contentProvider;
  	}
  
  	public LabelProvider getLabelProvider() {
  		return labelProvider;
  	}
  
  	public Properties getProperties(Object selected) {
  		return null;
  	}
  
  	public String[] getPropertyKeys(Object selected) {
  		return null;
  	}
  	
  	
  	
  	protected class FilesetDialog extends Dialog {
  		Fileset fileset;
  		private String name, dir, includes, excludes;
  		private Button browse;
  		private Text includesText, excludesText, folderText, nameText;
  		protected FilesetDialog(Shell parentShell, JBossServer server) {
  			super(parentShell);
  			this.fileset = new Fileset();
  			this.fileset.setFolder(server.getDeployDirectory());
  		}
  		protected FilesetDialog(Shell parentShell, Fileset fileset) {
  			super(parentShell);
  			this.fileset = (Fileset)fileset.clone();
  		}
  		protected Control createDialogArea(Composite parent) {
  			Composite sup = (Composite) super.createDialogArea(parent);
  			Composite main = new Composite(sup, SWT.NONE);
  			main.setLayout(new GridLayout(3, false));
  			
  			fillArea(main);
  			
  			nameText.setText(fileset.getName());
  			folderText.setText(fileset.getFolder());
  			includesText.setText(fileset.getIncludesPattern());
  			excludesText.setText(fileset.getExcludesPattern());
  			
  			addListeners();
  			return sup;
  		}
  
  		protected void addListeners() {
  			ModifyListener mListener = new ModifyListener() {
  				public void modifyText(ModifyEvent e) {
  					textModified();
  				} 
  			};
  			nameText.addModifyListener(mListener);
  			folderText.addModifyListener(mListener);
  			includesText.addModifyListener(mListener);
  			excludesText.addModifyListener(mListener);
  			
  			browse.addSelectionListener(new SelectionListener() {
  				public void widgetDefaultSelected(SelectionEvent e) {
  				}
  				public void widgetSelected(SelectionEvent e) {
  					DirectoryDialog d = new DirectoryDialog(new Shell());
  					d.setFilterPath(folderText.getText());
  					String x = d.open();
  					if( x != null ) 
  						folderText.setText(x);
  				} 
  			});
  		}
  		
  		protected void textModified() {
  			name = nameText.getText();
  			dir = folderText.getText();
  			includes = includesText.getText();
  			excludes = excludesText.getText();
  			fileset.setName(name);
  			fileset.setFolder(dir);
  			fileset.setIncludesPattern(includes);
  			fileset.setExcludesPattern(excludes);
  		}
  		protected void fillArea(Composite main) {
  			Label nameLabel = new Label(main, SWT.NONE);
  			nameLabel.setText("Name");
  			
  			nameText = new Text(main, SWT.BORDER);
  			nameText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 2, 1));
  			
  			Label folderLabel = new Label(main, SWT.NONE);
  			folderLabel.setText("Folder");
  			
  			folderText = new Text(main, SWT.BORDER);
  			browse = new Button(main, SWT.PUSH);
  			browse.setText("Browse...");
  			
  			Label includesLabel = new Label(main, SWT.NONE);
  			includesLabel.setText("Include Pattern");
  			
  			includesText = new Text(main, SWT.BORDER);
  			includesText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 2, 1));
  			
  			Label excludeLabel= new Label(main, SWT.NONE);
  			excludeLabel.setText("Exclude Pattern");
  			
  			excludesText = new Text(main, SWT.BORDER);
  			excludesText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 2, 1));
  
  		}
  		public String getDir() {
  			return dir;
  		}
  		public String getExcludes() {
  			return excludes;
  		}
  		public String getIncludes() {
  			return includes;
  		}
  		public String getName() {
  			return name;
  		}
  		public Fileset getFileset() {
  			return fileset;
  		}
  		
  	}
  
  }
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:33:29 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:33:29 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server
	...
Message-ID: <E1GuYv3-00059e-VA@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:33:29

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server 
                        JBossServerTableViewer.java
  Log:
  Null check
  
  Revision  Changes    Path
  1.2       +2 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- JBossServerTableViewer.java	10 Nov 2006 00:30:23 -0000	1.1
  +++ JBossServerTableViewer.java	13 Dec 2006 18:33:29 -0000	1.2
  @@ -161,6 +161,8 @@
   		}
   
   		public ContentWrapper[] wrap( Object[] elements, ServerViewProvider provider ) {
  +			if( elements == null ) return new ContentWrapper[0];
  +			
   			ContentWrapper[] wrappers = new ContentWrapper[elements.length];
   			for( int i = 0; i < wrappers.length; i++ ) {
   				wrappers[i] = new ContentWrapper(elements[i], provider);
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:34:37 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:34:37 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF
	...
Message-ID: <E1GuYw9-00059t-Ct@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:34:37

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/META-INF  MANIFEST.MF
  Log:
  New View Provider extension (filesets)
  
  Revision  Changes    Path
  1.13      +3 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- MANIFEST.MF	11 Dec 2006 16:55:28 -0000	1.12
  +++ MANIFEST.MF	13 Dec 2006 18:34:37 -0000	1.13
  @@ -54,7 +54,9 @@
    org.eclipse.wst.ws.ui,
    org.jboss.ide.eclipse.firstrun,
    org.jboss.ide.eclipse.as.ui.mbeans,
  - org.jboss.ide.eclipse.ui
  + org.jboss.ide.eclipse.ui,
  + org.jboss.ide.eclipse.packages.core,
  + org.apache.ant
   Eclipse-LazyStart: true
   Export-Package: org.jboss.ide.eclipse.as.ui,
    org.jboss.ide.eclipse.as.ui.wizards
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:34:37 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:34:37 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui  ...
Message-ID: <E1GuYw9-0005A0-GT@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:34:37

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui  plugin.xml
  Log:
  New View Provider extension (filesets)
  
  Revision  Changes    Path
  1.28      +9 -7      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- plugin.xml	11 Dec 2006 15:55:16 -0000	1.27
  +++ plugin.xml	13 Dec 2006 18:34:37 -0000	1.28
  @@ -164,13 +164,11 @@
               id="org.jboss.ide.eclipse.as.ui.XPathDescriptors"
               name="XML XPaths"
               providerClass="org.jboss.ide.eclipse.as.ui.views.server.providers.DescriptorXPathViewProvider"/>
  -<!--      <ViewProvider
  -            description="descriptor xpaths"
  -            icon="icons/xml.gif"
  -            id="org.jboss.ide.eclipse.as.ui.ViewProvider1"
  -            name="Descriptor XPaths"
  -            providerClass="org.jboss.ide.eclipse.as.ui.viewproviders.DescriptorXPathViewProvider"/>
  -            -->
  +      <ViewProvider
  +            description="A front end to open, edit, or view files in your server&apos;s directories."
  +            id="org.jboss.ide.eclipse.as.ui.FilesetViewProvider"
  +            name="Filesets"
  +            providerClass="org.jboss.ide.eclipse.as.ui.views.server.providers.FilesetViewProvider"/>
      </extension>
      <!--
         <extension
  @@ -224,6 +222,10 @@
               point="org.jboss.ide.eclipse.as.ui.mbeans.ServiceXMLQuickFixProvider">
            <QuickFixProvider class="org.jboss.ide.eclipse.as.ui.dialogs.ConvertNodeToXPathDialog$ConvertNodeToXPathDialogProvider"/>
         </extension>
  +      <extension
  +            point="org.jboss.ide.eclipse.as.ui.mbeans.ServiceXMLOutlineMenuProvider">
  +         <MenuProvider class="org.jboss.ide.eclipse.as.ui.dialogs.ConvertNodeToXPathDialog$ConvertNodeToXPathDialogOutlineMenuItemProvider"/>
  +      </extension>
      
      
   </plugin>
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:35:21 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:35:21 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server
	...
Message-ID: <E1GuYwr-0005BV-SY@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:35:21

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server 
                        JBossServer.java
  Log:
  Some .toOSString action for my folder paths
  
  Revision  Changes    Path
  1.17      +5 -4      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServer.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- JBossServer.java	14 Nov 2006 19:30:41 -0000	1.16
  +++ JBossServer.java	13 Dec 2006 18:35:21 -0000	1.17
  @@ -142,11 +142,11 @@
   		if( !f.exists() || !f.canRead() || !f.isDirectory())
   			return getRuntimeConfigDirectory();
   
  -		return configDir;
  +		return new Path(configDir).toOSString();
   	}
   	
   	public String getDeployDirectory(boolean checkLaunchConfig) {
  -		return getConfigDirectory(checkLaunchConfig) + Path.SEPARATOR + DEPLOY;
  +		return new Path(getConfigDirectory(checkLaunchConfig) + Path.SEPARATOR + DEPLOY).toOSString();
   	}
   
   	protected String getLaunchConfigConfigurationDirectory() {
  @@ -178,8 +178,9 @@
   	protected String getRuntimeConfigDirectory() {
   		IJBossServerRuntime runtime = (IJBossServerRuntime)
   			getServer().getRuntime().loadAdapter(IJBossServerRuntime.class, null);
  -		return getServer().getRuntime().getLocation().toOSString() + Path.SEPARATOR + "server" + 
  +		String p = getServer().getRuntime().getLocation().toOSString() + Path.SEPARATOR + "server" + 
   			Path.SEPARATOR + runtime.getJBossConfiguration();
  +		return new Path(p).toOSString();
   	}
   	
   }
  \ No newline at end of file
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:35:49 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:35:49 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers
	...
Message-ID: <E1GuYxJ-0005CV-3c@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:35:49

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers 
                        JstPackagesPublisher.java
  Log:
  New publisher based off Marshall's packaging, new build listener in case I want to use it
  
  Revision  Changes    Path
  1.2       +8 -8      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JstPackagesPublisher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- JstPackagesPublisher.java	11 Dec 2006 15:43:39 -0000	1.1
  +++ JstPackagesPublisher.java	13 Dec 2006 18:35:49 -0000	1.2
  @@ -177,16 +177,16 @@
   				IJavaProject javaProject = JavaCore.create(project);
   				Assert.isNotNull(javaProject);
   				
  -				IPath outputPath;
  +				IPath sourcePath;
   				try {
  -					outputPath = javaProject.getOutputLocation();
  +					sourcePath = javaProject.getOutputLocation();
   				} catch (JavaModelException e) {
   					e.printStackTrace();
   					return null;
   				}
  -				outputPath = outputPath.removeFirstSegments(1);
  -				IContainer outputContainer = project.getFolder(outputPath);
  -				return createGenericIPackage(module, deployDirectory, packageName, outputContainer);
  +				sourcePath = sourcePath.removeFirstSegments(1);
  +				IContainer sourcePathContainer = project.getFolder(sourcePath);
  +				return createGenericIPackage(module, deployDirectory, packageName, sourcePathContainer);
   			} catch( Exception e ) {
   				e.printStackTrace();
   			}
  @@ -249,9 +249,9 @@
   		}
   		public IPackage createEarPackages(IModule module, IProgressMonitor monitor) {
   			IProject proj = module.getProject();
  -			IContainer outputContainer = proj.getFolder(EARCONTENT);
  +			IContainer sourceContainer = proj.getFolder(EARCONTENT);
   
  -			IPackage topLevel = createGenericIPackage(module, jbServer.getDeployDirectory(), proj.getName() + ".ear", outputContainer);
  +			IPackage topLevel = createGenericIPackage(module, jbServer.getDeployDirectory(), proj.getName() + ".ear", sourceContainer);
   			addFileset(proj, topLevel, EARCONTENT, "**/*.*");
   			
   			// now add children
  @@ -276,7 +276,7 @@
   			return null;
   		}
   		public IPackage createOtherPackages(IModule module, IProgressMonitor monitor) {
  -			return null;
  +			return createGenericIPackage(module, null, module.getName() + ".jar");
   		}
   
   		public IStatus[] unpublish(IProgressMonitor monitor) throws CoreException {
  
  
  


From rawblem at gmail.com  Wed Dec 13 13:35:49 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 13:35:49 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model
	...
Message-ID: <E1GuYxJ-0005Cc-6q@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 13:35:49

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model 
                        PackagesBuildListener.java
  Log:
  New publisher based off Marshall's packaging, new build listener in case I want to use it
  
  Revision  Changes    Path
  1.3       +2 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/PackagesBuildListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesBuildListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/PackagesBuildListener.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackagesBuildListener.java	30 Nov 2006 16:16:45 -0000	1.2
  +++ PackagesBuildListener.java	13 Dec 2006 18:35:49 -0000	1.3
  @@ -201,7 +201,8 @@
   	
   	// TODO later
   	protected IServer[] getServersWhoCare(IPackage pack) {
  -		return JBossServerCore.getIServerJBossServers();
  +		return new IServer[] { };
  +		//return JBossServerCore.getIServerJBossServers();
   	}
   	
   	public static final String EVENT_TYPE = "org.jboss.ide.eclipse.as.core.model.Packages";
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 16:14:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 16:14:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r59018 -
	branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test
Message-ID: <E1GubQS-0008Ub-4f@committer01.frg.pub.inap.atl.jboss.com>

Author: tom.elrod at jboss.com
Date: 2006-12-13 16:14:03 -0500 (Wed, 13 Dec 2006)
New Revision: 59018

Added:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedBUnitTestCase.java
Modified:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
Log:
JBAS-3198 - fix for pooled invoker scoped deployments class caching.

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedBUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedBUnitTestCase.java	2006-12-13 18:16:51 UTC (rev 59017)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedBUnitTestCase.java	2006-12-13 21:14:03 UTC (rev 59018)
@@ -0,0 +1,128 @@
+package org.jboss.test.scoped.test;
+
+import org.jboss.test.JBossTestCase;
+import org.jboss.test.scoped.interfaces.a.SessionAHome;
+import org.jboss.test.scoped.interfaces.a.SessionA;
+import org.jboss.test.scoped.interfaces.dto.SimpleRequestDTO;
+import org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO;
+import org.jboss.test.scoped.interfaces.b.SessionBHome;
+import org.jboss.test.scoped.interfaces.b.SessionB;
+import org.jboss.deployment.EARDeployerMBean;
+
+import java.io.File;
+
+import javassist.ClassPool;
+import javassist.CtClass;
+import javassist.CtField;
+import javassist.Modifier;
+
+import javax.management.Attribute;
+
+/**
+ * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
+ */
+public class ScopedBUnitTestCase extends JBossTestCase
+{
+   public ScopedBUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testScoped() throws Exception
+   {
+      isolateDeployments(Boolean.TRUE);
+
+      // scoped deployment B
+
+      // have to create response classes with different serialVersionUID for each deployment
+      String jbosstestDeployDir = System.getProperty("jbosstest.deploy.dir");
+      System.out.println("jbosstestDeployDir = " + jbosstestDeployDir);
+      String deployADir = "/scopedA.ear/scopedB.jar";
+      File libDir = new File(jbosstestDeployDir, deployADir);
+      System.out.println("libDir = " + libDir.getAbsolutePath());
+      // Create a SimpleResponseDTO class with a static serialVersionUID of 1L
+      //ClassPool defaultPool = ClassPool.getDefault();
+      ClassPool classes1Pool = ClassPool.getDefault();
+      //ClassPool classes1Pool = new ClassPool(defaultPool);
+      CtClass info = classes1Pool.makeClass("org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO");
+      CtClass s = classes1Pool.get("java.lang.String");
+      CtField firstName = new CtField(s, "firstName", info);
+      firstName.setModifiers(Modifier.PUBLIC);
+      CtClass s2 = classes1Pool.get("java.lang.String");
+      CtField lastName = new CtField(s2, "lastName", info);
+      lastName.setModifiers(Modifier.PUBLIC);
+      CtClass s3 = classes1Pool.get("java.lang.Long");
+      CtField serialVersion = new CtField(s3, "serialVersionUID", info);
+      serialVersion.setModifiers(Modifier.PUBLIC | Modifier.STATIC);
+      long serialVerionUID = 2L;
+      info.addField(serialVersion, CtField.Initializer.constant(serialVerionUID));
+
+      info.writeFile(libDir.getAbsolutePath());
+
+      try
+      {
+//         deploy("scopedA.ear");
+         try
+         {
+            // Run the test
+            deploy("scopedB.ear");
+            try
+            {
+               doTest();
+            }
+            finally
+            {
+               undeploy("scopedB.ear");
+            }
+
+            // Run the test after a redeployment
+//            deploy("scopedB.ear");
+//            try                     x
+//            {
+//               doTest();
+//            }
+//            finally
+//            {
+//               undeploy("scopedB.ear");
+//            }
+         }
+         finally
+         {
+            //undeploy("scopedA.ear");
+         }
+      }
+      finally
+      {
+         isolateDeployments(Boolean.FALSE);
+      }
+   }
+
+   private void doTest() throws Exception
+   {
+//      Properties env = new Properties();
+//      env.put("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
+//      //env.put("java.naming.provider.url", "localhost:1099");
+//      env.put("java.naming.provider.url", "localhost:1100");
+//      env.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
+//
+//      Context ic = new InitialContext(env);
+
+      SessionBHome home = (SessionBHome) getInitialContext().lookup("SessionB");
+      SessionB session = home.create();
+
+
+         SimpleRequestDTO requestDTO = new SimpleRequestDTO();
+         requestDTO.setFirstName("Daffy");
+         requestDTO.setLastName("Duck");
+         SimpleResponseDTO result = session.runSimpleTest(requestDTO);
+
+         System.out.println(result.getFirstName() + " " + result.getLastName());
+
+   }
+
+   private void isolateDeployments(Boolean value) throws Exception
+   {
+      //getServer().setAttribute(EARDeployerMBean.OBJECT_NAME, new Attribute("Isolated", value));
+      getServer().setAttribute(EARDeployerMBean.OBJECT_NAME, new Attribute("CallByValue", value));
+   }
+}

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-13 18:16:51 UTC (rev 59017)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/scoped/test/ScopedUnitTestCase.java	2006-12-13 21:14:03 UTC (rev 59018)
@@ -92,38 +92,13 @@
 
       info.writeFile(libDir.getAbsolutePath());
 
-      // scoped deployment B
-
-      String deployADirB = "/scopedB.ear/scopedB.jar";
-      File libDirB = new File(jbosstestDeployDir, deployADirB);
-      System.out.println("libDirB = " + libDirB.getAbsolutePath());
-      // Create a SimpleResponseDTO class with a static serialVersionUID of 1L
-      //ClassPool defaultPool = ClassPool.getDefault();
-      ClassPool classes1PoolB = ClassPool.getDefault();
-      //ClassPool classes1Pool = new ClassPool(defaultPool);
-      CtClass infoB = classes1PoolB.makeClass("org.jboss.test.scoped.interfaces.dto.SimpleResponseDTO");
-      CtClass sB = classes1PoolB.get("java.lang.String");
-      CtField firstNameB = new CtField(sB, "firstName", infoB);
-      firstNameB.setModifiers(Modifier.PUBLIC);
-      CtClass s2B = classes1PoolB.get("java.lang.String");
-      CtField lastNameB = new CtField(s2B, "lastName", infoB);
-      lastNameB.setModifiers(Modifier.PUBLIC);
-      CtClass s3B = classes1PoolB.get("java.lang.Long");
-      CtField serialVersionB = new CtField(s3B, "serialVersionUID", infoB);
-      serialVersionB.setModifiers(Modifier.PUBLIC | Modifier.STATIC);
-      long serialVerionUIDB = 2L;
-      infoB.addField(serialVersionB, CtField.Initializer.constant(serialVerionUIDB));
-
-      infoB.writeFile(libDirB.getAbsolutePath());
-
-
       try
       {
          deploy("scopedA.ear");
          try
          {
             // Run the test
-            deploy("scopedB.ear");
+//            deploy("scopedB.ear");
             try
             {
                doTest();
@@ -146,7 +121,7 @@
          }
          finally
          {
-            //undeploy("scopedA.ear");
+            undeploy("scopedA.ear");
          }
       }
       finally
@@ -176,15 +151,6 @@
 
          System.out.println(result.getFirstName() + " " + result.getLastName());
 
-      SessionBHome homeB = (SessionBHome)getInitialContext().lookup("SessionB");
-      SessionB sessionB = homeB.create();
-
-      result = sessionB.runSimpleTest(requestDTO);
-
-      System.out.println(result.getFirstName() + " " + result.getLastName());
-
-
-
    }
 
    private void isolateDeployments(Boolean value) throws Exception



From scott.stark at jboss.com  Wed Dec 13 16:31:54 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 13 Dec 2006 16:31:54 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/web/2.0.0.snapshot  ...
Message-ID: <E1Gubhi-0000Mo-Q1@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/13 16:31:54

  Modified:    jboss/web/2.0.0.snapshot  component-info.xml
  Log:
  Include the jbossweb-src.zip artifact
  
  Revision  Changes    Path
  1.8       +2 -0      repository.jboss.com/jboss/web/2.0.0.snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/web/2.0.0.snapshot/component-info.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- component-info.xml	10 Nov 2006 17:32:11 -0000	1.7
  +++ component-info.xml	13 Dec 2006 21:31:54 -0000	1.8
  @@ -10,6 +10,8 @@
         <artifact id="jbossweb-extras.jar"/>
         <artifact id="jsp-api.jar"/>
         <artifact id="servlet-api.jar"/>
  +      <artifact id="jbossweb-src.zip"/>
  +
         <import componentref="apache-logging">
            <compatible version="1.0.3"/>
            <compatible version="1.0.4jboss"/>
  
  
  


From rawblem at gmail.com  Wed Dec 13 16:48:53 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Wed, 13 Dec 2006 16:48:53 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server
	...
Message-ID: <E1Guby9-0000cD-1a@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/13 16:48:53

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server 
                        JBossServerTableViewer.java
  Log:
  refresh action added
  
  Revision  Changes    Path
  1.3       +13 -4     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JBossServerTableViewer.java	13 Dec 2006 18:33:29 -0000	1.2
  +++ JBossServerTableViewer.java	13 Dec 2006 21:48:53 -0000	1.3
  @@ -46,7 +46,7 @@
   
   	protected TableViewerPropertySheet propertySheet;
   	
  -	protected Action disableCategoryAction;
  +	protected Action disableCategoryAction, refreshAction;
   	public JBossServerTableViewer(Tree tree) {
   		super(tree);
   		setContentProvider(new ContentProviderDelegator());
  @@ -90,6 +90,16 @@
   			}
   		};
   		disableCategoryAction.setText(Messages.DisableCategoryAction);
  +		refreshAction = new Action() { 
  +			public void run() {
  +				Object el = getSelectedElement();
  +				if( el instanceof ServerViewProvider ) 
  +					JBossServerView.getDefault().refreshJBTree(el);
  +				else 
  +					JBossServerView.getDefault().refreshJBTree(((IStructuredSelection)getSelection()).getFirstElement());
  +			}
  +		};
  +		refreshAction.setText("Refresh Item");
   	}
   	
   	public static class ContentWrapper {
  @@ -267,13 +277,12 @@
   
   	
   	protected void fillJBContextMenu(Shell shell, IMenuManager menu) {
  -		
   		Object selected = getSelectedElement();
  -		
  +		menu.add(refreshAction);
   		if( selected instanceof ServerViewProvider ) {
   			menu.add(disableCategoryAction);
  -			menu.add(new Separator());
   		}
  +		menu.add(new Separator());
   	}
   
   	
  
  
  


From adrian.brock at jboss.com  Wed Dec 13 18:16:30 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:16:30 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/microcontainer/snapshot-metadata -
	New directory ...
Message-ID: <E1GudKw-0002PM-R3@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:16:30

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/microcontainer/snapshot-metadata added to the repository


From adrian.brock at jboss.com  Wed Dec 13 18:17:29 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:17:29 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib
	- New directory ...
Message-ID: <E1GudLt-0002RQ-NM@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:17:29

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib added to the repository


From adrian.brock at jboss.com  Wed Dec 13 18:18:45 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:18:45 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/microcontainer/snapshot-metadata ...
Message-ID: <E1GudN7-0002Sk-4B@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:18:45

  Added:       jboss/microcontainer/snapshot-metadata  component-info.xml
  Log:
  Temporary snapshot for MC/AOP metadata integration
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/microcontainer-component-info">
  
     <component id="jboss/microcontainer"
                licenseType="lgpl"
                version="snapshot-metadata"
                >
        <artifact id="jboss-aop-mc-int.jar"/>
        <artifact id="jboss-aop-mc-int-boot.jar"/>
        <artifact id="jboss-aop-mc-int-deployer.jar"/>
        <artifact id="jboss-container.jar"/>
        <artifact id="jboss-dependency.jar"/>
        <artifact id="jboss-microcontainer.jar"/>
        <artifact id="jboss-deployers.jar"/>
        <artifact id="jboss-aop-mc-int-src.zip"/>
        <artifact id="jboss-container-src.zip"/>
        <artifact id="jboss-dependency-src.zip"/>
        <artifact id="jboss-deployers-src.zip"/>
        <artifact id="jboss-microcontainer-src.zip"/>
        <export>
           <include input="jboss-aop-mc-int.jar"/>
           <include input="jboss-aop-mc-int-boot.jar"/>
           <include input="jboss-aop-mc-int-deployer.jar"/>
           <include input="jboss-container.jar"/>
           <include input="jboss-dependency.jar"/>
           <include input="jboss-microcontainer.jar"/>
           <include input="jboss-deployers.jar"/>
        </export>
     </component>
  
  </project>
  
  
  


From adrian.brock at jboss.com  Wed Dec 13 18:18:45 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:18:45 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib ...
Message-ID: <E1GudN7-0002TC-9V@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:18:45

  Added:       jboss/microcontainer/snapshot-metadata/lib            
                        jboss-aop-mc-int-boot.jar
                        jboss-aop-mc-int-deployer.jar
                        jboss-aop-mc-int-src.zip jboss-aop-mc-int.jar
                        jboss-container-src.zip jboss-container.jar
                        jboss-dependency-src.zip jboss-dependency.jar
                        jboss-deployers-src.zip jboss-deployers.jar
                        jboss-microcontainer-src.zip
                        jboss-microcontainer.jar
  Log:
  Temporary snapshot for MC/AOP metadata integration
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int-boot.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int-deployer.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int-src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-container-src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-container.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-dependency-src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-dependency.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-deployers-src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-deployers.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-microcontainer-src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:18:45;  author: adrian;  state: Exp;repository.jboss.com/jboss/microcontainer/snapshot-metadata/lib/jboss-microcontainer.jar
  
  	<<Binary file>>
  
  


From adrian.brock at jboss.com  Wed Dec 13 18:18:58 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:18:58 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata - New
	directory ...
Message-ID: <E1GudNK-0002TL-VT@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:18:58

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/aop/snapshot-metadata added to the repository


From adrian.brock at jboss.com  Wed Dec 13 18:19:10 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:19:10 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata/lib -
	New directory ...
Message-ID: <E1GudNW-0002TU-9P@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:19:10

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/aop/snapshot-metadata/lib added to the repository


From adrian.brock at jboss.com  Wed Dec 13 18:19:48 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:19:48 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata  ...
Message-ID: <E1GudO8-0002Tn-DO@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:19:48

  Added:       jboss/aop/snapshot-metadata  component-info.xml
  Log:
  Temporary snapshot for MC/AOP metadata integration
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 23:19:48;  author: adrian;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-aop-component-info">
  
     <component id="jboss/aop"
        licenseType="lgpl"
        version="snapshot-metadata"
        projectHome="http://www.jboss.org/products/aop"
        description="JBoss Aspect Oriented Programming - snapshot from trunk">
  
        <artifact id="jboss-aop-jdk50.jar"/>
        <artifact id="jboss-aop-jdk50-client.jar"/>
        <artifact id="jrockit-pluggable-instrumentor.jar"/>
        <artifact id="pluggable-instrumentor.jar"/>
        <import componentref="javassist">
           <compatible version="3.4.GA"/>
        </import>
        <export>
           <include input="jboss-aop-jdk50.jar"/>
           <include input="jboss-aop-jdk50-client.jar"/>
           <include input="jrockit-pluggable-instrumentor.jar"/>
           <include input="pluggable-instrumentor.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  
  


From adrian.brock at jboss.com  Wed Dec 13 18:19:48 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:19:48 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata/lib ...
Message-ID: <E1GudO8-0002Tz-H2@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:19:48

  Added:       jboss/aop/snapshot-metadata/lib    
                        jboss-aop-jdk50-client.jar jboss-aop-jdk50.jar
                        jdk14-pluggable-instrumentor.jar
                        pluggable-instrumentor.jar
  Log:
  Temporary snapshot for MC/AOP metadata integration
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 23:19:48;  author: adrian;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/lib/jboss-aop-jdk50-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:19:48;  author: adrian;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/lib/jboss-aop-jdk50.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:19:48;  author: adrian;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/lib/jdk14-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/13 23:19:48;  author: adrian;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/lib/pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 18:27:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 18:27:16 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1785 -
	branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/message
Message-ID: <E1GudVM-0002dc-4R@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-13 18:27:14 -0500 (Wed, 13 Dec 2006)
New Revision: 1785

Modified:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java
Log:
use global timeouts

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java	2006-12-13 16:14:39 UTC (rev 1784)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java	2006-12-13 23:27:14 UTC (rev 1785)
@@ -37,7 +37,10 @@
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
-
+/**
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ */
 public class ObjectMessageDeliveryTest extends MessagingTestCase
 {
    // Constants -----------------------------------------------------
@@ -134,11 +137,11 @@
          
          publisher.send(om3);
          
-         ObjectMessage rm1 = (ObjectMessage)sub.receive(1000);
+         ObjectMessage rm1 = (ObjectMessage)sub.receive(MAX_TIMEOUT);
          
-         ObjectMessage rm2 = (ObjectMessage)sub.receive(1000);
+         ObjectMessage rm2 = (ObjectMessage)sub.receive(MAX_TIMEOUT);
          
-         ObjectMessage rm3 = (ObjectMessage)sub.receive(1000);
+         ObjectMessage rm3 = (ObjectMessage)sub.receive(MAX_TIMEOUT);
          
          assertNotNull(rm1);
          



From jdf845 at graffiti.net  Wed Dec 13 18:27:55 2006
From: jdf845 at graffiti.net (jdf845 at graffiti.net)
Date: Wed, 13 Dec 2006 18:27:55 -0500
Subject: [jboss-cvs] =?utf-8?b?wpbCvsKTw7rCg8KBwoNBwoNowpXDj8KCwqbCgsOm?=
	=?utf-8?b?woLCpMKCw4bCjnbCgsOBwoLDhMKCw6nCgsKpwoLDp8KNwqHCk8O6wpU=?=
	=?utf-8?b?w5TCjsKWwoLCqsKXfsKCwrXCgsKiwoLDjMKBSQ==?=
Message-ID: 20061214084418.26768mail@mail.nearselebwoman_allfree_web45123365488779510.com

?G???q????(??_??)??????O?????f???????A?h???X???????b???????????????H
???????????[???????C???????????????c?B?M???????O???x???l?????????????????????c?B
?????A?????????????????????H?????????????????????????????????c?B
?t?????????????????H?????A???????????????????????v?????????????????????????????????I
?????A?????????????????????????????v???????B?????????N?????????????????????????c?H
?????f???? http://allfreefree.hitodumadeai.jp.ksjer.com/18/ 
???????A?h???X???????????????????????????????????v?????????c?B
?????????????B?A???????????B???????p???????????????B??????????????50???????????????B?????????????c?B




From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 18:29:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 18:29:15 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1786 -
	branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GudXH-0002dw-Qa@committer01.frg.pub.inap.atl.jboss.com>

Author: juha at jboss.org
Date: 2006-12-13 18:29:14 -0500 (Wed, 13 Dec 2006)
New Revision: 1786

Modified:
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
Log:
drain destinations to isolate tests better

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-13 23:27:14 UTC (rev 1785)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-13 23:29:14 UTC (rev 1786)
@@ -29,6 +29,7 @@
 import javax.jms.TextMessage;
 import javax.jms.XAConnection;
 import javax.jms.XASession;
+import javax.jms.Message;
 import javax.naming.InitialContext;
 import javax.transaction.TransactionManager;
 import javax.transaction.xa.XAResource;
@@ -99,6 +100,11 @@
       queueA = (Destination)initialContext.lookup("/queue/QA");
       queueB = (Destination)initialContext.lookup("/queue/QB");
       queueTX = (Destination)initialContext.lookup("/queue/TXQ");
+
+      drainDestination(cf, queue);
+      drainDestination(cf, queueA);
+      drainDestination(cf, queueB);
+      drainDestination(cf, queueTX);
    }
 
    public void tearDown() throws Exception
@@ -108,6 +114,7 @@
       ServerManagement.undeployQueue("QB");
       ServerManagement.undeployQueue("TXQ");
 
+
       super.tearDown();
    }
 
@@ -291,9 +298,9 @@
 
       res1.start(xid1, XAResource.TMNOFLAGS);
 
-      MessageProducer prod1 = sess1.createProducer(queue);
+      MessageProducer prod1 = sess1.createProducer(queueA);
 
-      TextMessage tm1 = sess1.createTextMessage("testing1");
+      TextMessage tm1 = sess1.createTextMessage("alpha");
 
       prod1.send(tm1);
 
@@ -302,9 +309,9 @@
 
       res2.start(xid2, XAResource.TMNOFLAGS);
 
-      MessageProducer prod2 = sess2.createProducer(queue);
+      MessageProducer prod2 = sess2.createProducer(queueA);
 
-      TextMessage tm2 = sess2.createTextMessage("testing2");
+      TextMessage tm2 = sess2.createTextMessage("beta");
 
       prod2.send(tm2);
 
@@ -322,7 +329,7 @@
 
       ServerManagement.startServerPeer();
 
-      ServerManagement.deployQueue("Queue");
+      ServerManagement.deployQueue("QA");
 
 
       XAResource res = cf.createXAConnection().createXASession().getXAResource();
@@ -344,20 +351,29 @@
       Connection conn3 = cf.createConnection();
 
       Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageConsumer cons = sessRec.createConsumer(queue);
+      MessageConsumer cons = sessRec.createConsumer(queueA);
       conn3.start();
 
-      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+      Message msg = cons.receive(MAX_TIMEOUT);
+
+      TextMessage m1 = (TextMessage)msg;
       assertNotNull(m1);
-      assertEquals("testing1", m1.getText());
 
+      assertTrue("alpha".equals(m1.getText()) ||
+                 "beta".equals(m1.getText()));
+
       TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
       assertNotNull(m2);
 
-      assertEquals("testing2", m2.getText());
+      assertTrue("alpha".equals(m2.getText()) ||
+                 "beta".equals(m2.getText()));
 
+      assertTrue(!tm1.getText().equals(tm2.getText()));
+
+      Message nullMessage = cons.receive(MIN_TIMEOUT);
+      assertTrue(nullMessage == null);
+
       conn3.close();
-
    }
 
    public void testMockCoordinatorRecoveryWithJBossTSXids() throws Exception



From adrian.brock at jboss.com  Wed Dec 13 18:42:59 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:42:59 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata/lib ...
Message-ID: <E1GudkZ-0002sG-7W@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:42:59

  Added:       jboss/aop/snapshot-metadata/lib 
                        jrockit-pluggable-instrumentor.jar
  Log:
  Include the jrocket instrumentor rather than jdk14
  
  Revision  Changes    Path
  1.1      date: 2006/12/13 23:42:59;  author: adrian;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/lib/jrockit-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  


From adrian.brock at jboss.com  Wed Dec 13 18:43:59 2006
From: adrian.brock at jboss.com (Adrian Brock)
Date: Wed, 13 Dec 2006 18:43:59 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata/lib ...
Message-ID: <E1GudlX-0002sf-6Q@committer01.frg.pub.inap.atl.jboss.com>

  User: adrian  
  Date: 06/12/13 18:43:59

  Removed:     jboss/aop/snapshot-metadata/lib 
                        jdk14-pluggable-instrumentor.jar
  Log:
  Include the jrocket instrumentor rather than jdk14


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 18:46:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 18:46:05 -0500
Subject: [jboss-cvs] JBossAS SVN: r59019 - in projects/aop/trunk:
	aop/src/main/org/jboss/aop
	aop/src/main/org/jboss/aop/proxy/container build
Message-ID: <E1GudnZ-0002vS-AB@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-13 18:45:58 -0500 (Wed, 13 Dec 2006)
New Revision: 59019

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/Advisor.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/InstanceProxyContainer.java
   projects/aop/trunk/build/build-thirdparty.xml
Log:
[JBMICROCONT-75] - AOP/MC MetaData integration

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/Advisor.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/Advisor.java	2006-12-13 21:14:03 UTC (rev 59018)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/Advisor.java	2006-12-13 23:45:58 UTC (rev 59019)
@@ -43,7 +43,6 @@
 import javassist.CtField;
 import javassist.CtMethod;
 
-import org.jboss.aop.ClassAdvisor.RebuildInterceptorsAction;
 import org.jboss.aop.advice.AdviceBinding;
 import org.jboss.aop.advice.AspectDefinition;
 import org.jboss.aop.advice.CFlowInterceptor;
@@ -68,9 +67,11 @@
 import org.jboss.aop.metadata.MethodMetaData;
 import org.jboss.aop.metadata.SimpleMetaData;
 import org.jboss.aop.pointcut.PointcutMethodMatch;
-import org.jboss.aop.util.MethodHashing;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.signature.MethodSignature;
 import org.jboss.repository.spi.MetaDataContext;
 import org.jboss.util.NestedRuntimeException;
+import org.jboss.util.NotImplementedException;
 
 import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
 import EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArraySet;
@@ -156,8 +157,8 @@
    protected ConstructionInfo[] constructionInfos;
 
 
-   //FIXME - make metaDataContext a MetaDataContext once MC 2.0 is released
-   MetaDataContext metadataContext;
+   /** The meta data */
+   private MetaData metadata;
 
    public Advisor(String name, AspectManager manager)
    {
@@ -332,9 +333,11 @@
 
    public Object resolveAnnotation(Class annotation)
    {
-      if (metadataContext != null)
+      if (metadata != null)
       {
-         Object value = metadataContext.getAnnotation(annotation);
+         Object value = metadata.getAnnotation(annotation);
+         // FIXME The metadata should already include the class annotations
+         //       so we should just return this result
          if (value != null) return value;
       }
 
@@ -371,13 +374,15 @@
 
       try
       {
-         if (metadataContext != null)
+         if (metadata != null)
          {
             if (annotationClass == null)
             {
                annotationClass = Thread.currentThread().getContextClassLoader().loadClass(annotation);
             }
-            if (metadataContext.hasAnnotation(annotationClass)) return true;
+            // FIXME The metadata should already include the class annotations
+            //       so we should just return this result
+            if (metadata.isAnnotationPresent(annotationClass)) return true;
          }
       }
       catch (ClassNotFoundException e)
@@ -409,14 +414,17 @@
 
    public Object resolveAnnotation(long hash, Method m, Class annotation)
    {
-      if (metadataContext != null)
+      if (metadata != null)
       {
-         if (hash == 0)
+         MethodSignature signature = new MethodSignature(m.getName(), m.getParameterTypes());
+         MetaData methodMD = metadata.getComponentMetaData(signature);
+         if (methodMD != null)
          {
-            hash = MethodHashing.calculateHash(m);
+            // FIXME The metadata should already include the class annotations
+            //       so we should just return this result
+            Object val = methodMD.getAnnotation(annotation);
+            if (val != null) return val;
          }
-         Object val = metadataContext.getAnnotationForMethod(hash, annotation);
-         if (val != null) return val;
       }
 
       if (annotations.isDisabled(m,annotation))
@@ -475,18 +483,19 @@
 
       try
       {
-         if (metadataContext != null)
+         if (metadata != null)
          {
-            if (hash == 0)
-            {
-               hash = MethodHashing.methodHash(m);
-            }
             if (annotationClass == null)
+               annotationClass = Thread.currentThread().getContextClassLoader().loadClass(annotation);
+            // FIXME The metadata should already include the class annotations
+            //       so we should just return this result
+            MethodSignature signature = new MethodSignature(m.getName(), m.getParameterTypes());
+            MetaData methodMD = metadata.getComponentMetaData(signature);
+            if (methodMD != null)
             {
-               annotationClass = Thread.currentThread().getContextClassLoader().loadClass(annotation);
+               if (methodMD.isAnnotationPresent(annotationClass))
+                  return true;
             }
-            if (metadataContext.hasAnnotationForMethod(hash, annotationClass))
-               return true;
          }
       }
       catch (ClassNotFoundException e)
@@ -574,16 +583,39 @@
       return AnnotationElement.isAnyAnnotationPresent(member, annotation);
    }
 
+   @Deprecated // use getMetaData
    public MetaDataContext getMetadataContext()
    {
-      return metadataContext;
+      throw new NotImplementedException("getMetaDataContext");
    }
 
+   @Deprecated // use setMetaData
    public void setMetadataContext(/*MetaDataContext*/ Object metadataContext)
    {
-      this.metadataContext = (MetaDataContext)metadataContext;
+      throw new NotImplementedException("setMetaDataContext");
    }
 
+   /**
+    * Get the metadata
+    * 
+    * @return the metadata
+    */
+   public MetaData getMetadata()
+   {
+      return metadata;
+   }
+
+   /**
+    * Set the metadata
+    * 
+    * FIXME why does this have java.lang.Object signature?
+    * @param metadata the metadata
+    */
+   public void setMetadata(/*MetaData*/ Object metadata)
+   {
+      this.metadata = (MetaData) metadata;
+   }
+
    public String getName()
    {
       return name;

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java	2006-12-13 21:14:03 UTC (rev 59018)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java	2006-12-13 23:45:58 UTC (rev 59019)
@@ -36,7 +36,7 @@
    private Class proxiedClass;
    private Object target;
    //FIXME convert back to MetaDataContext once the mc 2.0 has been released 
-   //private MetaDataContext metaDataContext;
+   //private MetaData metaDataContext;
    private Object metaDataContext;
    private Class[] interfaces;
    private AOPProxyFactoryMixin[] mixins; 

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/InstanceProxyContainer.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/InstanceProxyContainer.java	2006-12-13 21:14:03 UTC (rev 59018)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/InstanceProxyContainer.java	2006-12-13 23:45:58 UTC (rev 59019)
@@ -45,12 +45,12 @@
    Advisor classAdvisor;
    InstanceAdvisorDelegate delegate;
    
-   public InstanceProxyContainer(String name, ProxyAdvisorDomain instanceDomain, Advisor classAdvisor, /*MetaDataContext*/ Object metaDataContext)
+   public InstanceProxyContainer(String name, ProxyAdvisorDomain instanceDomain, Advisor classAdvisor, /*MetaData*/ Object metaData)
    {
       super(name, instanceDomain);
       this.classAdvisor = classAdvisor;
       instanceDomain.setAdvisor(this);
-      setMetadataContext(metaDataContext);
+      setMetadata(metaData);
       delegate = new InstanceAdvisorDelegate(classAdvisor, this);
       delegate.initialize();
       initialise(classAdvisor.getClazz());

Modified: projects/aop/trunk/build/build-thirdparty.xml
===================================================================
--- projects/aop/trunk/build/build-thirdparty.xml	2006-12-13 21:14:03 UTC (rev 59018)
+++ projects/aop/trunk/build/build-thirdparty.xml	2006-12-13 23:45:58 UTC (rev 59019)
@@ -52,7 +52,7 @@
       <componentref name="jboss/common-logging-log4j" version="2.0.1.GA"/>
       <componentref name="jboss/common-logging-spi" version="2.0.1.GA"/>
       <componentref name="jboss/jbossretro" version="1.0.4.GA"/>
-      <componentref name="jboss/microcontainer" version="snapshot"/>
+      <componentref name="jboss/microcontainer" version="snapshot-metadata"/>
       <componentref name="jboss/microcontainer14" version="snapshot"/>
       <componentref name="jboss/profiler/jvmti" version="1.0.0.CR5"/>
       <componentref name="jboss/test" version="snapshot"/>



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 18:52:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 18:52:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59020 - in projects/microcontainer/trunk:
 aop-mc-int aop-mc-int/src/main/org/jboss/aop/microcontainer/integration
 aop-mc-int/src/tests/org/jboss/test/microcontainer/test build
 container/src/main/org/jboss
 container/src/main/org/jboss/beans/info/plugins
 container/src/main/org/jboss/beans/info/spi
 container/src/main/org/jboss/classadapter/plugins
 container/src/main/org/jboss/classadapter/plugins/dependency
 container/src/main/org/jboss/classadapter/spi
 container/src/main/org/jboss/config/plugins
 container/src/main/org/jboss/config/plugins/property
 container/src/main/org/jboss/config/spi
 container/src/main/org/jboss/joinpoint/plugins
 container/src/main/org/jboss/joinpoint/spi
 container/src/main/org/jboss/metadata/plugins/context
 container/src/main/org/jboss/metadata/plugins/loader
 container/src/main/org/jboss/metadata/plugins/loader/memory
 container/src/main/org/jboss/metadata/plugins/loader/reflection
 container/src/main/org/jboss/metadata/spi container/s!
 rc/main/org/jboss/metadata/spi/retrieval
 container/src/main/org/jboss/metadata/spi/scope
 container/src/main/org/jboss/metadata/spi/signature
 container/src/main/org/jboss/metadata/spi/stack
 container/src/main/org/jboss/virtual
 container/src/main/org/jboss/virtual/plugins/context
 container/src/main/org/jboss/virtual/plugins/context/file
 container/src/main/org/jboss/virtual/plugins/context/jar
 container/src/main/org/jboss/virtual/protocol/vfsfile
 container/src/main/org/jboss/virtual/protocol/vfsjar
 container/src/main/org/jboss/virtual/spi container/src/tests/org/jboss/test
 container/src/tests/org/jboss/test/joinpoint/test
 container/src/tests/org/jboss/test/metadata/loader/memory/test
 container/src/tests/org/jboss/test/metadata/loader/reflection/support
 container/src/tests/org/jboss/test/metadata/loader/reflection/test
 container/src/tests/org/jboss/test/metadata/retrieval/support
 container/src/tests/org/jboss/test/metadata/shared
 container/src/tests/org/jboss/test/metadata/shar!
 ed/support container/src/tests/org/jboss/test/virtual/test
 kernel/src/main/org/jboss/kernel/plugins/dependency
 kernel/src/main/org/jboss/kernel/plugins/deployment
 kernel/src/main/org/jboss/kernel/plugins/deployment/xml
 kernel/src/main/org/jboss/kernel/plugins/event
 kernel/src/main/org/jboss/kernel/plugins/metadata/basic kern
Message-ID: <E1Gudtu-00031v-0x@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-13 18:51:15 -0500 (Wed, 13 Dec 2006)
New Revision: 59020

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/SimpleMetaDataLoader.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/ComponentMutableMetaData.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/ConstructorSignature.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/FieldSignature.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodParametersSignature.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodSignature.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStack.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStackPermission.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryLoaderComponentBasicAnnotationsUnitTestCase.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/ConstructorBean.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/FieldBean.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodBean.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodParamBean.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/ComponentBasicAnnotationsTest.java
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_New.xml
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NewProperty.xml
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverride.xml
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverrideProperty.xml
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_Override.xml
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_OverrideProperty.xml
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationA.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationB.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationC.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestClassAnnotation.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/AbstractMetaDataTest.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/MetaDataTestSuite.java
Removed:
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPKernelRepository.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContext.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactory.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactoryDelegate.java
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractInstanceBeanInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/repository/
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/MutableMetaDataContext.java
Modified:
   projects/microcontainer/trunk/aop-mc-int/build.xml
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPConstructorJoinpoint.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilder.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilderDelegate.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactory.java
   projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactoryBuilder.java
   projects/microcontainer/trunk/aop-mc-int/src/tests/org/jboss/test/microcontainer/test/InterceptorWithAnnotationDependencyTestCase.java
   projects/microcontainer/trunk/build/build-thirdparty.xml
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/spi/BeanInfo.java
   projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/BasicClassAdapter.java
   projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/dependency/AbstractDependencyBuilder.java
   projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java
   projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/DependencyBuilder.java
   projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/AbstractConfiguration.java
   projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java
   projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfiguration.java
   projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfigurationConstants.java
   projects/microcontainer/trunk/container/src/main/org/jboss/config/spi/Configuration.java
   projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactoryBuilder.java
   projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/spi/JoinpointFactoryBuilder.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/AbstractMetaDataContext.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/BasicMetaDataLoader.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/memory/MemoryMetaDataLoader.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/reflection/AnnotatedElementMetaDataLoader.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/MetaData.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrieval.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrievalToMetaDataBridge.java
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/scope/ScopeKey.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/joinpoint/test/JoinpointTest.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryMetaDataLoaderTestSuite.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/ReflectionMetaDataLoaderTestSuite.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/retrieval/support/TestMetaDataRetrieval.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/support/MetaDataAndMutableMetaDataImpl.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelController.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelControllerContext.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/AbstractKernelDeployment.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/BasicKernelDeployer.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BasicXMLDeployer.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBinding.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryKeyInterceptor.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryValueInterceptor.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/event/AbstractEventEmitter.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/metadata/basic/BasicKernelMetaDataRepository.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/AbstractKernelRegistry.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/basic/BasicKernelRegistryFactory.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/KernelControllerContext.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/KernelMetaDataRepository.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/KernelTestSuite.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomCollection.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomList.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomMap.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomSet.java
Log:
[JBMICROCONT-75] - AOP/MC MetaData integration

Modified: projects/microcontainer/trunk/aop-mc-int/build.xml
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/build.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/build.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -69,6 +69,7 @@
     <!-- The combined library classpath -->
     <path id="library.classpath">
       <path refid="apache.log4j.classpath"/>
+      <path refid="javassist.javassist.classpath"/>
       <path refid="oswego.concurrent.classpath"/>
       <path refid="junit.junit.classpath"/>
       <path refid="jboss.aop.classpath"/>

Modified: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPConstructorJoinpoint.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPConstructorJoinpoint.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPConstructorJoinpoint.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -32,9 +32,10 @@
 import org.jboss.aop.proxy.container.ContainerCache;
 import org.jboss.aop.proxy.container.GeneratedAOPProxyFactory;
 import org.jboss.joinpoint.plugins.BasicConstructorJoinPoint;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.stack.MetaDataStack;
 import org.jboss.reflect.spi.ConstructorInfo;
 import org.jboss.reflect.spi.TypeInfo;
-import org.jboss.repository.spi.MetaDataContext;
 
 /**
  * An AOPConstructorJoinpoint.
@@ -48,18 +49,15 @@
 public class AOPConstructorJoinpoint extends BasicConstructorJoinPoint
 {
    AOPProxyFactory proxyFactory = new GeneratedAOPProxyFactory();
-
-   MetaDataContext metaDataContext;
    
    /**
     * Create a new AOPConstructorJoinpoint.
     *
     * @param constructorInfo the constructor info
     */
-   public AOPConstructorJoinpoint(ConstructorInfo constructorInfo, MetaDataContext metaDataContext)
+   public AOPConstructorJoinpoint(ConstructorInfo constructorInfo)
    {
       super(constructorInfo);
-      this.metaDataContext = metaDataContext;
    }
 
    public Object dispatch() throws Throwable
@@ -70,16 +68,25 @@
       {
          return super.dispatch();
       }
-      ContainerCache cache = ContainerCache.initialise(manager, clazz, metaDataContext);
-      AOPProxyFactoryParameters params = new AOPProxyFactoryParameters();
-      Object target = createTarget(cache, params);
+      MetaData metaData = MetaDataStack.peek();
+      MetaDataStack.mask();
+      try
+      {
+         ContainerCache cache = ContainerCache.initialise(manager, clazz, metaData);
+         AOPProxyFactoryParameters params = new AOPProxyFactoryParameters();
+         Object target = createTarget(cache, params);
 
-      params.setProxiedClass(target.getClass());
-      params.setMetaDataContext(metaDataContext);
-      params.setTarget(target);
-      params.setContainerCache(cache);
-
-      return proxyFactory.createAdvisedProxy(params);
+         params.setProxiedClass(target.getClass());
+         params.setMetaDataContext(metaData);
+         params.setTarget(target);
+         params.setContainerCache(cache);
+         
+         return proxyFactory.createAdvisedProxy(params);
+      }
+      finally
+      {
+         MetaDataStack.unmask();
+      }
    }
 
    private Object createTarget(ContainerCache cache, AOPProxyFactoryParameters params) throws Throwable

Modified: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilder.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilder.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilder.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -26,6 +26,7 @@
 import org.jboss.classadapter.plugins.dependency.AbstractDependencyBuilder;
 import org.jboss.classadapter.spi.ClassAdapter;
 import org.jboss.classadapter.spi.DependencyBuilder;
+import org.jboss.metadata.spi.MetaData;
 
 /**
  * The existence of this class is the signal to the kernel that we want to use the aop-mc integration.
@@ -40,14 +41,14 @@
 {
    DependencyBuilder delegate;
    
-   public List getDependencies(ClassAdapter classAdapter)
+   public List<Object> getDependencies(ClassAdapter classAdapter, MetaData metaData)
    {
       DependencyBuilder builder = getDependencyBuilderDelegate(classAdapter);
       if (builder == null)
       {
-         return super.getDependencies(classAdapter);
+         return super.getDependencies(classAdapter, metaData);
       }
-      return delegate.getDependencies(classAdapter);
+      return delegate.getDependencies(classAdapter, metaData);
    }
    
    private synchronized DependencyBuilder getDependencyBuilderDelegate(ClassAdapter classAdapter)

Modified: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilderDelegate.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilderDelegate.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPDependencyBuilderDelegate.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -40,6 +40,8 @@
 import org.jboss.classadapter.plugins.dependency.AbstractDependencyBuilder;
 import org.jboss.classadapter.spi.ClassAdapter;
 import org.jboss.classadapter.spi.Dependency;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.signature.MethodSignature;
 import org.jboss.reflect.plugins.AnnotationValueFactory;
 import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactoryImpl;
 import org.jboss.reflect.spi.AnnotationInfo;
@@ -51,7 +53,6 @@
 import org.jboss.reflect.spi.StringValue;
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.Value;
-import org.jboss.repository.spi.MetaDataContext;
 
 /**
  * Used by the AOPDependencyBuilder once the AspectManager has been installed. Finds all managed aspects that apply 
@@ -66,7 +67,7 @@
    private static final String DEPENDENCY_NAME_ATTRIBUTE = "name";
    private static final IntrospectionTypeInfoFactoryImpl typeInfoFactory = new IntrospectionTypeInfoFactoryImpl();
 
-   public List getDependencies(ClassAdapter classAdapter)
+   public List<Object> getDependencies(ClassAdapter classAdapter, MetaData metaData)
    {
       AspectManager manager = AspectManager.instance();
       try
@@ -77,10 +78,8 @@
          {
             if (manager.isNonAdvisableClassName(className))
             {
-               return super.getDependencies(classAdapter);
+               return super.getDependencies(classAdapter, metaData);
             }
-            
-            MetaDataContext metaDataContext = classAdapter.getMetaDataContext();
 
             ClassLoader loader = classAdapter.getClassLoader();
             if (loader == null)
@@ -92,7 +91,7 @@
             Advisor advisor;
             synchronized (ContainerCache.mapLock)
             {
-               ContainerCache cache = ContainerCache.initialise(manager, clazz, metaDataContext);
+               ContainerCache cache = ContainerCache.initialise(manager, clazz, metaData);
                advisor = cache.getAdvisor();
             }
             
@@ -113,7 +112,7 @@
                }
             }
             
-            HashSet<Object> annotationDependencies = getAnnotationDependencies(classInfo, metaDataContext);
+            HashSet<Object> annotationDependencies = getAnnotationDependencies(classInfo, metaData);
             depends.addAll(annotationDependencies);
             
             return depends;
@@ -127,13 +126,13 @@
       }
    }
    
-   private HashSet<Object> getAnnotationDependencies(ClassInfo classInfo, MetaDataContext metaDataContext)
+   private HashSet<Object> getAnnotationDependencies(ClassInfo classInfo, MetaData metaData)
    {
       try
       {
          HashSet<Object> dependencies = new HashSet<Object>();
-         getClassAnnotationDependencies(classInfo, metaDataContext, dependencies);
-         getMethodAnnotationDependencies(classInfo, metaDataContext, dependencies);
+         getClassAnnotationDependencies(classInfo, metaData, dependencies);
+         getMethodAnnotationDependencies(classInfo, metaData, dependencies);
          return dependencies;
       }
       catch (RuntimeException e)
@@ -146,12 +145,12 @@
       }
    }
 
-   private void getClassAnnotationDependencies(ClassInfo classInfo, MetaDataContext metaDataContext, HashSet<Object> dependencies) throws Exception
+   private void getClassAnnotationDependencies(ClassInfo classInfo, MetaData metaData, HashSet<Object> dependencies) throws Exception
    {
       HashMap<String, ArrayList<String>> realMap = new HashMap<String, ArrayList<String>>();
       getRealClassAnnotationDependencies(classInfo, realMap);
       HashMap<String, ArrayList<String>> metaMap = new HashMap<String, ArrayList<String>>();
-      getMetaDataContextClassAnnotationDependencies(metaDataContext, metaMap);
+      getMetaDataClassAnnotationDependencies(metaData, metaMap);
       addAllDependenciesToSet(dependencies, realMap, metaMap);
    }
    
@@ -165,19 +164,18 @@
       }
    }
    
-   private void getMetaDataContextClassAnnotationDependencies(MetaDataContext metaDataContext, HashMap<String, ArrayList<String>> dependencies) throws Exception
+   private void getMetaDataClassAnnotationDependencies(MetaData metaData, HashMap<String, ArrayList<String>> dependencies) throws Exception
    {
-      if (metaDataContext != null)
+      if (metaData != null)
       {
-         for (Iterator it = metaDataContext.getAnnotations().iterator() ; it.hasNext() ; )
+         for (Object annotation : metaData.getAnnotations())
          {
-            Object annotation = it.next();
             getDependenciesForMetaDataAnnotation(annotation, dependencies);
          }
       }
    }
    
-   private void getMethodAnnotationDependencies(ClassInfo classInfo, MetaDataContext metaDataContext, HashSet<Object> dependencies) throws Exception
+   private void getMethodAnnotationDependencies(ClassInfo classInfo, MetaData metaData, HashSet<Object> dependencies) throws Exception
    {
       Map methodMap = ClassInfoMethodHashing.getMethodMap(classInfo);
       if (methodMap != null)
@@ -190,7 +188,7 @@
                HashMap<String, ArrayList<String>> classMap = new HashMap<String, ArrayList<String>>();
                getRealMethodAnnotationDependencies(method, classMap);
                HashMap<String, ArrayList<String>> overrideMap = new HashMap<String, ArrayList<String>>();
-               getMetaDataContextMethodAnnotationDependencies(method, metaDataContext, overrideMap);
+               getMetaDataMethodAnnotationDependencies(method, metaData, overrideMap);
                addAllDependenciesToSet(dependencies, classMap, overrideMap);
             }
          }
@@ -209,16 +207,21 @@
       }
    }
    
-   private void getMetaDataContextMethodAnnotationDependencies(MethodInfo method, MetaDataContext metaDataContext, HashMap<String, ArrayList<String>> dependencies) throws Exception
+   private void getMetaDataMethodAnnotationDependencies(MethodInfo method, MetaData metaData, HashMap<String, ArrayList<String>> dependencies) throws Exception
    {
-      if (metaDataContext != null)
+      if (metaData != null)
       {
-         long hash = ClassInfoMethodHashing.methodHash(method);
-         List methodAnnotations = metaDataContext.getAnnotationsForMethod(hash);
-         for (Iterator it = methodAnnotations.iterator() ; it.hasNext() ; )
+         TypeInfo[] typeInfos = method.getParameterTypes();
+         Class[] params = new Class[typeInfos.length];
+         for (int i = 0; i < typeInfos.length; ++i)
+            params[i] = typeInfos[i].getType();
+         MetaData methodMetaData = metaData.getComponentMetaData(new MethodSignature(method.getName(), params));
+         if (methodMetaData != null)
          {
-            Object annotation = it.next();
-            getDependenciesForMetaDataAnnotation(annotation, dependencies);
+            for (Object annotation : methodMetaData.getAnnotations())
+            {
+               getDependenciesForMetaDataAnnotation(annotation, dependencies);
+            }
          }
       }
    }

Modified: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactory.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactory.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactory.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,15 +21,11 @@
 */
 package org.jboss.aop.microcontainer.integration;
 
-import org.jboss.joinpoint.plugins.BasicConstructorJoinPoint;
 import org.jboss.joinpoint.plugins.BasicJoinpointFactory;
 import org.jboss.joinpoint.spi.ConstructorJoinpoint;
 import org.jboss.joinpoint.spi.JoinpointException;
-import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory;
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.ConstructorInfo;
-import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.repository.spi.MetaDataContext;
 
 /**
  * The existence of this class is the signal to the kernel that we want to use the aop-mc integration.
@@ -42,89 +38,18 @@
  */
 public class AOPJoinpointFactory extends BasicJoinpointFactory
 {
-   /** The AOPConstructorJoinpoint constructor one it has been loaded */
-   static volatile ConstructorInfo ctorInfo; 
-   
    /**
     * Create a new AOPJoinpointFactory.
     * 
     * @param classInfo
     */
-   public AOPJoinpointFactory(ClassInfo classInfo, MetaDataContext metaDataContext)
+   public AOPJoinpointFactory(ClassInfo classInfo)
    {
-      super(classInfo, metaDataContext);
+      super(classInfo);
    }
 
    public ConstructorJoinpoint getConstructorJoinpoint(ConstructorInfo constructorInfo) throws JoinpointException
    {
-      ConstructorInfo info = getAOPJoinpointConstructorInfo(constructorInfo);
-      
-      if (info != null)
-      {
-         return createAOPConstructorJoinpoint(info, constructorInfo);
-      }
-      else
-      {
-         return super.getConstructorJoinpoint(constructorInfo);
-      }
+      return new AOPConstructorJoinpoint(constructorInfo);
    }
-   
-   private synchronized ConstructorInfo getAOPJoinpointConstructorInfo(ConstructorInfo currentConstructorInfo) throws JoinpointException
-   {
-      if (ctorInfo != null)
-      {
-         return ctorInfo;
-      }
-      
-      Class clazz = AOPDeployedChecker.getClassIfExists(
-            classInfo.getType().getClassLoader(), 
-            "org.jboss.aop.microcontainer.integration.AOPConstructorJoinpoint");
-      
-      if (clazz == null)
-      {
-         return null;
-      }
-      
-      TypeInfoFactory factory = new IntrospectionTypeInfoFactory();
-      ClassInfo info = (ClassInfo)factory.getTypeInfo(clazz);
-      ConstructorInfo[] ctors = info.getDeclaredConstructors();
-      for (int i = 0 ; i < ctors.length ; i++)
-      {
-         if (ctors[i].getParameterTypes().length == 2)
-         {
-            if (ctors[i].getParameterTypes()[0].getName().equals(ConstructorInfo.class.getName()) == false)
-            {
-               continue;
-            }
-            
-            if (ctors[i].getParameterTypes()[1].getName().equals(MetaDataContext.class.getName()) == false)
-            {
-               continue;
-            }
-            ctorInfo = ctors[i];
-            break;
-         }
-      }
-      
-      if (ctorInfo == null)
-      {
-         throw new JoinpointException("No constructor found with the reqiured signature AOPConstructorJoinpoint(ConstructorInfo, MetadataContext)");
-      }
-      return ctorInfo;
-   }
-   
-   private ConstructorJoinpoint createAOPConstructorJoinpoint(ConstructorInfo info, ConstructorInfo aopCtorInfo) throws JoinpointException
-   {
-      ConstructorJoinpoint jp = new BasicConstructorJoinPoint(info);
-      jp.setArguments(new Object[] {aopCtorInfo, metaDataContext});
-      try
-      {
-         return (ConstructorJoinpoint)jp.dispatch();
-      }
-      catch (Throwable e)
-      {
-         throw new JoinpointException("Error calling AOPConstructorJoinpoint constructor", e);
-      }
-      
-   }
 }

Modified: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactoryBuilder.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactoryBuilder.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPJoinpointFactoryBuilder.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,7 +24,6 @@
 import org.jboss.joinpoint.spi.JoinpointFactory;
 import org.jboss.joinpoint.spi.JoinpointFactoryBuilder;
 import org.jboss.reflect.spi.ClassInfo;
-import org.jboss.repository.spi.MetaDataContext;
 
 /**
  * AOPJoinpointFactoryBuilder.
@@ -34,13 +33,8 @@
  */
 public class AOPJoinpointFactoryBuilder implements JoinpointFactoryBuilder
 {
-   public JoinpointFactory createJoinpointFactory(ClassInfo classInfo, MetaDataContext metaDataContext)
-   {
-      return new AOPJoinpointFactory(classInfo, metaDataContext);
-   }
-
    public JoinpointFactory createJoinpointFactory(ClassInfo classInfo)
    {
-      return createJoinpointFactory(classInfo, null);
+      return new AOPJoinpointFactory(classInfo);
    }
 }

Deleted: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPKernelRepository.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPKernelRepository.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPKernelRepository.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1,68 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.aop.microcontainer.integration;
-
-import org.jboss.repository.plugins.AbstractKernelRepository;
-import org.jboss.repository.plugins.InvocationMetaDataCombiner;
-import org.jboss.repository.plugins.KeyMetaDataCombiner;
-import org.jboss.repository.plugins.ThreadMetaDataCombiner;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision$
- */
-public class AOPKernelRepository extends AbstractKernelRepository
-{
-   private volatile static AOPKernelRepository instance;
-   
-   protected AOPKernelRepository() throws Exception
-   {
-      super(
-            new InvocationMetaDataCombiner
-            (
-               new ThreadMetaDataCombiner
-               (
-                  new KeyMetaDataCombiner()
-               ), null
-            )
-         );
-      
-   }
-   
-   public static AOPKernelRepository instance()
-   {
-      try
-      {
-         if (instance == null)
-         {
-            instance = new AOPKernelRepository();
-         }
-         return instance;
-      }
-      catch (Exception e)
-      {
-         throw new RuntimeException(e);
-      }
-   }
-}
-

Deleted: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContext.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContext.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1,276 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.aop.microcontainer.integration;
-
-import java.lang.annotation.Annotation;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Set;
-
-import org.jboss.aop.Advised;
-import org.jboss.aop.Advisor;
-import org.jboss.aop.proxy.container.AspectManaged;
-import org.jboss.aop.util.ClassInfoMethodHashing;
-import org.jboss.beans.info.spi.PropertyInfo;
-import org.jboss.beans.metadata.spi.AnnotationMetaData;
-import org.jboss.kernel.spi.metadata.MutableMetaDataContext;
-import org.jboss.metadata.plugins.loader.memory.MemoryMetaDataLoader;
-import org.jboss.metadata.spi.repository.MetaDataRepository;
-import org.jboss.metadata.spi.repository.MutableMetaDataRepository;
-import org.jboss.metadata.spi.retrieval.AnnotationItem;
-import org.jboss.metadata.spi.retrieval.AnnotationsItem;
-import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
-import org.jboss.metadata.spi.scope.CommonLevels;
-import org.jboss.metadata.spi.scope.Scope;
-import org.jboss.metadata.spi.scope.ScopeKey;
-import org.jboss.reflect.spi.MethodInfo;
-import org.jboss.repository.spi.MetaDataContext;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision$
- */
-public class AOPMetaDataContext implements MutableMetaDataContext
-{
-   final static List<Annotation> EMPTY_ANNOTATIONS = new ArrayList<Annotation>();
-   Scope scope;
-   Object target;
-   MutableMetaDataRepository repository;
-   String beanName;
-   ScopeKey instanceKey;
-   
-   public AOPMetaDataContext(MutableMetaDataRepository repository, String beanName)
-   {
-      this.repository = repository;
-      this.beanName = beanName;
-      //TODO: This needs linking up with the parent scopes somehow - where will that info come from?
-      scope = new Scope(CommonLevels.INSTANCE, beanName);
-      instanceKey = new ScopeKey(scope);
-   }
-   
-   public <T extends Annotation> boolean hasAnnotation(Class<T> ann)
-   {
-      return getAnnotation(ann) != null;
-   }
-
-   public <T extends Annotation> Annotation getAnnotation(Class<T> ann)
-   {
-      return getAnnotation(instanceKey, ann);
-   }
-
-   public <T extends Annotation> boolean hasAnnotationForMethod(long methodHash, Class<T> ann)
-   {
-      return getAnnotationForMethod(methodHash, ann) != null;
-   }
-
-   public <T extends Annotation> Annotation getAnnotationForMethod(long methodHash, Class<T> ann)
-   {
-      ScopeKey joinpointKey = createHashedJoinpointKey(methodHash);
-      return getAnnotation(joinpointKey, ann);
-   }
-
-   public List<Annotation> getAnnotations()
-   {
-      return getAnnotations(instanceKey);
-   }
-   
-   public List<Annotation> getAnnotationsForMethod(long methodHash)
-   {
-      ScopeKey joinpointKey = createHashedJoinpointKey(methodHash);
-      return getAnnotations(joinpointKey);
-   }
-   
-   public List<Annotation> getAnnotationsForMethods(long[] methodHashes)
-   {
-      ArrayList<Annotation> annotations = new ArrayList<Annotation>();
-      for (long hash : methodHashes)
-      {
-         ScopeKey joinpointKey = createHashedJoinpointKey(hash);
-         List<Annotation> methodAnnotations = getAnnotations(joinpointKey);
-         annotations.addAll(methodAnnotations);
-      }
-      return annotations;
-   }
-   
-   public MetaDataRepository getRepository()
-   {
-      return repository;
-   }
-
-   /**
-    * Add instance-level annotations
-    * @param annotations a Set<AnnotationMetaData>
-    */
-   public void addAnnotations(Set<AnnotationMetaData> annotations)
-   {
-      if (annotations.size() == 0)
-      {
-         return;
-      }
-
-      MemoryMetaDataLoader retrieval = new MemoryMetaDataLoader(instanceKey);
-      for (AnnotationMetaData annotationMetaData : annotations)
-      {
-         Annotation annotation = annotationMetaData.getAnnotationInstance();
-         retrieval.addAnnotation(annotation);
-      }
-      repository.addMetaDataRetrieval(retrieval);
-   }
-   
-   public void addPropertyAnnotations(String propertyName, Set<PropertyInfo> propertyInfos, Set<AnnotationMetaData> annotations)
-   {
-      for (PropertyInfo info : propertyInfos)
-      {
-         if (propertyName.equals(info.getName()))
-         {
-            MemoryMetaDataLoader getterRetrieval = createGetterMetaDataRetrieval(info);
-            MemoryMetaDataLoader setterRetrieval = createSetterMetaDataRetrieval(info);
-            
-            if (getterRetrieval == null && setterRetrieval == null)
-            {
-               continue;
-            }
-            
-            for (AnnotationMetaData annotation : annotations)
-            {
-               if (getterRetrieval != null)
-               {
-                  getterRetrieval.addAnnotation(annotation.getAnnotationInstance());
-               }
-               if (setterRetrieval != null)
-               {
-                  setterRetrieval.addAnnotation(annotation.getAnnotationInstance());
-               }
-            }
-            
-            if (getterRetrieval != null)
-            {
-               repository.addMetaDataRetrieval(getterRetrieval);
-            }
-            if (setterRetrieval != null)
-            {
-               repository.addMetaDataRetrieval(setterRetrieval);
-            }
-         }
-      }
-   }
-
-   public void setTarget(Object tgt)
-   {
-      if (tgt == null)
-      {
-         return;
-      }
-
-      target = tgt;
-      Advisor advisor = null;
-      if (tgt instanceof AspectManaged)
-      {
-         advisor = (Advisor)((AspectManaged)tgt).getInstanceAdvisor();
-      }
-      else if (tgt instanceof Advised)
-      {
-         advisor = (Advisor)((Advised)tgt)._getInstanceAdvisor();
-      }
-      
-      if (advisor != null)
-      {
-         MetaDataContext advCtx = advisor.getMetadataContext();
-         if (advCtx != null && advCtx != this)
-         {
-            throw new RuntimeException("Different context being set in constructed advisor");
-         }
-         if (advCtx == null)
-         {
-            advisor.setMetadataContext(this);
-         }
-      }
-   }
-   
-   private MemoryMetaDataLoader createGetterMetaDataRetrieval(PropertyInfo propertyInfo)
-   {
-      MethodInfo getter = propertyInfo.getGetter();
-      return createMethodMetaDataRetrieval(getter);
-   }
-   
-   private MemoryMetaDataLoader createSetterMetaDataRetrieval(PropertyInfo propertyInfo)
-   {
-      MethodInfo setter = propertyInfo.getSetter();
-      return createMethodMetaDataRetrieval(setter);
-   }
-   
-   private MemoryMetaDataLoader createMethodMetaDataRetrieval(MethodInfo accessor)
-   {
-      if (accessor == null)
-      {
-         return null;
-      }
-      long hash = ClassInfoMethodHashing.methodHash(accessor);
-      ScopeKey joinpointKey = createHashedJoinpointKey(hash);
-      MemoryMetaDataLoader retrieval = new MemoryMetaDataLoader(joinpointKey);
-      return retrieval;
-   }
-   
-   private ScopeKey createHashedJoinpointKey(long hash)
-   {
-      ScopeKey joinpointKey = new ScopeKey(instanceKey.getScopes());
-      joinpointKey.addScope(CommonLevels.JOINPOINT, String.valueOf(hash));
-      return joinpointKey;
-   }
-
-   private <T extends Annotation> Annotation getAnnotation(ScopeKey key, Class<T> ann)
-   {
-      MetaDataRetrieval retrieval = repository.getMetaDataRetrieval(key);
-      
-      if (retrieval != null)
-      {
-         AnnotationItem item = retrieval.retrieveAnnotation(ann);
-         if (item != null)
-         {
-            return item.getAnnotation();
-         }
-      }      
-      return null;
-   }
-
-   private List<Annotation> getAnnotations(ScopeKey key)
-   {
-      MetaDataRetrieval retrieval = repository.getMetaDataRetrieval(key);
-      
-      if (retrieval != null)
-      {
-         AnnotationsItem item = retrieval.retrieveAnnotations();
-         if (item != null)
-         {
-            AnnotationItem[] items = item.getAnnotations();
-            List<Annotation> annotations = new ArrayList<Annotation>();
-            for (AnnotationItem aitem : items)
-            {
-               annotations.add(aitem.getAnnotation());
-            }
-            return annotations;    
-         }
-      }      
-      return EMPTY_ANNOTATIONS;
-   }
-}   

Deleted: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactory.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactory.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactory.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1,80 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.aop.microcontainer.integration;
-
-import org.jboss.metadata.spi.repository.MetaDataRepository;
-import org.jboss.metadata.spi.repository.MutableMetaDataRepository;
-import org.jboss.repository.plugins.basic.BasicMetaDataContextFactory;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision$
- */
-public class AOPMetaDataContextFactory extends BasicMetaDataContextFactory implements MetaDataContextFactory
-{
-   MetaDataContextFactory delegate;
-   public MetaDataContext getMetaDataContext(ClassLoader beanLoader, MetaDataRepository repository, String beanName)
-   {
-      MetaDataContextFactory factoryDelegate = getMetaDataContextFactoryDelegate(beanLoader);
-      if (factoryDelegate == null)
-      {
-         return super.getMetaDataContext(beanLoader, repository, beanName);
-      }
-      else
-      {
-         return factoryDelegate.getMetaDataContext(beanLoader, repository, beanName);
-      }
-   }
-   
-   private synchronized MetaDataContextFactory getMetaDataContextFactoryDelegate(ClassLoader beanLoader)
-   {
-      if (delegate != null)
-      {
-         return delegate;
-      }
-      
-      Class clazz = AOPDeployedChecker.getClassIfExists(
-            beanLoader, 
-            "org.jboss.aop.microcontainer.integration.AOPMetaDataContextFactoryDelegate");
-      
-      if (clazz == null)
-      {
-         return null;
-      }
-      
-      try
-      {
-         delegate = (MetaDataContextFactory)clazz.newInstance();
-      }
-      catch (Exception e)
-      {
-         throw new RuntimeException("Error instantiating AOPMetaDataContextFactoryDelegate", e);
-      }
-      
-      return delegate;
-   }
-   
-   
-}

Deleted: projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactoryDelegate.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactoryDelegate.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/main/org/jboss/aop/microcontainer/integration/AOPMetaDataContextFactoryDelegate.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1,49 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.aop.microcontainer.integration;
-
-import org.jboss.metadata.spi.repository.MetaDataRepository;
-import org.jboss.metadata.spi.repository.MutableMetaDataRepository;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class AOPMetaDataContextFactoryDelegate implements MetaDataContextFactory
-{
-
-   public MetaDataContext getMetaDataContext(ClassLoader beanLoader, MetaDataRepository repository, String beanName)
-   {
-      if (repository instanceof MutableMetaDataRepository)
-
-      {
-         return new AOPMetaDataContext((MutableMetaDataRepository)repository, beanName);
-      }
-      else
-      {
-         throw new RuntimeException("The passed in repository must be of type org.jboss.metadata.spi.repository.MutableMetaDataRepository");
-      }
-   }
-}

Modified: projects/microcontainer/trunk/aop-mc-int/src/tests/org/jboss/test/microcontainer/test/InterceptorWithAnnotationDependencyTestCase.java
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/src/tests/org/jboss/test/microcontainer/test/InterceptorWithAnnotationDependencyTestCase.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/aop-mc-int/src/tests/org/jboss/test/microcontainer/test/InterceptorWithAnnotationDependencyTestCase.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -229,7 +229,7 @@
       SimpleBean bean = (SimpleBean) getBean(name);
       assertNotNull(bean);
       bean.someMethod();
-      assertTrue(dependency == InterceptorWithAnnotationDependency.intercepted);
+      assertTrue(dependency + "==" + InterceptorWithAnnotationDependency.intercepted, dependency == InterceptorWithAnnotationDependency.intercepted);
    }   
 
    private void checkInterceptedAndInjectedMethodAnnotatedXml(SimpleBean dependency)

Modified: projects/microcontainer/trunk/build/build-thirdparty.xml
===================================================================
--- projects/microcontainer/trunk/build/build-thirdparty.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/build/build-thirdparty.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -54,7 +54,7 @@
       <componentref name="jboss/profiler/jvmti" version="1.0.0.CR4"/>
       <componentref name="junit" version="3.8.1"/>
       <componentref name="junit4" version="4.1"/>
-      <componentref name="jboss/aop" version="2.0.0.alpha2" />
+      <componentref name="jboss/aop" version="snapshot-metadata" />
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/jbossretro" version="1.0.4.GA"/>
       <componentref name="jboss/test" version="1.0.0.GA"/>

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfo.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfo.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -31,11 +31,10 @@
 import org.jboss.beans.info.spi.PropertyInfo;
 import org.jboss.classadapter.spi.ClassAdapter;
 import org.jboss.joinpoint.spi.JoinpointFactory;
+import org.jboss.metadata.spi.MetaData;
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.ConstructorInfo;
 import org.jboss.reflect.spi.MethodInfo;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
 import org.jboss.util.JBossObject;
 import org.jboss.util.JBossStringBuilder;
 
@@ -98,17 +97,6 @@
       this.methods = methods;
       this.events = events;
    }
-   
-   protected AbstractBeanInfo(AbstractBeanInfo template)
-   {
-      this.name = template.name;
-      this.classAdapter = template.classAdapter.getInstanceAdapter(template.classAdapter.getClassInfo());
-      this.properties = template.properties;
-      this.constructors = template.constructors;
-      this.methods = template.methods;
-      this.events = template.events;
-      this.beanInfoFactory = template.beanInfoFactory;
-   }
 
    public String getName()
    {
@@ -130,20 +118,10 @@
       return classAdapter.getClassInfo();
    }
 
-   public List<Object> getDependencies()
-   {
-      return classAdapter.getDependencies();
-   }
-
    public JoinpointFactory getJoinpointFactory()
    {
       return classAdapter.getJoinpointFactory();
    }
-   
-   public MetaDataContextFactory getMetaDataContextFactory()
-   {
-      return classAdapter.getMetaDataContextFactory();
-   }
 
    public Set<ConstructorInfo> getConstructors()
    {
@@ -179,15 +157,10 @@
    {
       return beanInfoFactory;
    }
-   
-   public MetaDataContext getMetaDataContext()
-   {
-      return classAdapter.getMetaDataContext();
-   }
 
-   public void setMetaDataContext(MetaDataContext metaCtx)
+   public List<Object> getDependencies(MetaData metaData)
    {
-      classAdapter.setMetaDataContext(metaCtx);
+      return classAdapter.getDependencies(metaData);
    }
 
    public boolean equals(Object object)
@@ -235,10 +208,4 @@
    {
       return name.hashCode();
    }
-
-
-   public BeanInfo getInstanceInfo()
-   {
-      return new AbstractInstanceBeanInfo(this);
-   }
 }

Deleted: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractInstanceBeanInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractInstanceBeanInfo.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractInstanceBeanInfo.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.beans.info.plugins;
-
-import org.jboss.beans.info.spi.BeanInfo;
-
-/**
- * A BeanInfo allowing for overriding of the MetaDataContext for a particular bean
- *  
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision$
- */
-public class AbstractInstanceBeanInfo extends AbstractBeanInfo implements BeanInfo
-{
-   public AbstractInstanceBeanInfo(AbstractBeanInfo template)
-   {
-      super(template);
-   }
-
-   public boolean equals(Object object)
-   {
-      if (object == null || object instanceof AbstractInstanceBeanInfo == false)
-         return false;
-      
-      AbstractInstanceBeanInfo other = (AbstractInstanceBeanInfo) object;
-      if (notEqual(name, other.name))
-         return false;
-      else if (notEqual(classAdapter, other.classAdapter))
-         return false;
-      else if (notEqual(properties, other.properties))
-         return false;
-      else if (notEqual(methods, other.methods))
-         return false;
-      else if (notEqual(constructors, other.constructors))
-         return false;
-      else if (notEqual(events, other.events))
-         return false;
-      return true;
-   }
-   
-   public BeanInfo getInstanceInfo()
-   {
-      return this;
-   }
-}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/spi/BeanInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/spi/BeanInfo.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/spi/BeanInfo.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,11 +25,10 @@
 import java.util.Set;
 
 import org.jboss.joinpoint.spi.JoinpointFactory;
+import org.jboss.metadata.spi.MetaData;
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.ConstructorInfo;
 import org.jboss.reflect.spi.MethodInfo;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
 import org.jboss.util.JBossInterface;
 
 /**
@@ -55,21 +54,6 @@
    ClassInfo getClassInfo();
 
    /**
-    * Return a BeanInfo for this bean instance
-    * 
-    * @return an instance info for this bean
-    */
-   BeanInfo getInstanceInfo();
-
-   /**
-    * Bean may have additional dependencies
-    * that the kernel cannot initially resolve. (currently defined by ClassAdapter)
-    *
-    * @return the list of dependencies
-    */
-   List<Object> getDependencies();
-
-   /**
     * Get the joinpoint factory
     * 
     * @return the joinpoint factory
@@ -77,13 +61,6 @@
    JoinpointFactory getJoinpointFactory();
    
    /**
-    * Get the metadata context factory
-    * 
-    * @return the metadata context factory
-    */
-   MetaDataContextFactory getMetaDataContextFactory();
-   
-   /**
     * Get the property information.
     *
     * @return a Set<PropertyInfo> 
@@ -145,19 +122,13 @@
     * @return the factory
     */
    BeanInfoFactory getBeanInfoFactory();
-   
-   
+
    /**
-    * Get the metadata context
-    * 
-    * @return the metadata context
+    * Bean may have additional dependencies
+    * that the kernel cannot initially resolve. (currently defined by ClassAdapter)
+    *
+    * @param metaData the metadata
+    * @return the list of dependencies
     */
-   MetaDataContext getMetaDataContext();
-   
-   /**
-    * Set the metadata context
-    * 
-    * @param metaCtx a metadata context
-    */
-   void setMetaDataContext(MetaDataContext metaCtx);
+   List<Object> getDependencies(MetaData metaData);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/BasicClassAdapter.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/BasicClassAdapter.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/BasicClassAdapter.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -28,9 +28,8 @@
 import org.jboss.classadapter.spi.DependencyBuilder;
 import org.jboss.joinpoint.spi.JoinpointFactory;
 import org.jboss.joinpoint.spi.JoinpointFactoryBuilder;
+import org.jboss.metadata.spi.MetaData;
 import org.jboss.reflect.spi.ClassInfo;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
 import org.jboss.util.JBossObject;
 
 /**
@@ -45,9 +44,6 @@
    
    /** The class info */
    protected ClassInfo classInfo;
-
-   /** The metadata context */
-   protected MetaDataContext metaDataContext;
    
    /**
     * Create a new reflected class adapter
@@ -66,23 +62,10 @@
       return classInfo;
    }
 
-   public ClassAdapter getInstanceAdapter(ClassInfo classInfo)
-   {
-      BasicClassAdapter clone = (BasicClassAdapter) clone();
-      clone.classInfo = classInfo;
-      return clone;
-   }
-
-   public List<Object> getDependencies()
-   {
-      DependencyBuilder builder = classAdapterFactory.getConfiguration().getDependencyBuilder();
-      return builder.getDependencies(this);
-   }
-
    public JoinpointFactory getJoinpointFactory()
    {
       JoinpointFactoryBuilder builder = classAdapterFactory.getConfiguration().getJoinpointFactoryBuilder();
-      return builder.createJoinpointFactory(classInfo, metaDataContext);
+      return builder.createJoinpointFactory(classInfo);
    }
 
    public ClassLoader getClassLoader()
@@ -90,19 +73,9 @@
       return classInfo.getType().getClassLoader();
    }
 
-   public MetaDataContextFactory getMetaDataContextFactory()
+   public List<Object> getDependencies(MetaData metaData)
    {
-      return classAdapterFactory.getConfiguration().getMetaDataContextFactory();
+      DependencyBuilder builder = classAdapterFactory.getConfiguration().getDependencyBuilder();
+      return builder.getDependencies(this, metaData);
    }
-
-
-   public MetaDataContext getMetaDataContext()
-   {
-      return metaDataContext;
-   }
-
-   public void setMetaDataContext(MetaDataContext metaCtx)
-   {
-      metaDataContext = metaCtx;
-   }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/dependency/AbstractDependencyBuilder.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/dependency/AbstractDependencyBuilder.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/plugins/dependency/AbstractDependencyBuilder.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,6 +25,7 @@
 
 import org.jboss.classadapter.spi.ClassAdapter;
 import org.jboss.classadapter.spi.DependencyBuilder;
+import org.jboss.metadata.spi.MetaData;
 
 /**
  * AbstractDependencyBuilder.
@@ -34,7 +35,7 @@
  */
 public class AbstractDependencyBuilder implements DependencyBuilder
 {
-   public List<Object> getDependencies(ClassAdapter classAdapter)
+   public List<Object> getDependencies(ClassAdapter classAdapter, MetaData metaData)
    {
       return null;
    }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/ClassAdapter.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,9 +24,8 @@
 import java.util.List;
 
 import org.jboss.joinpoint.spi.JoinpointFactory;
+import org.jboss.metadata.spi.MetaData;
 import org.jboss.reflect.spi.ClassInfo;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
 import org.jboss.util.JBossInterface;
 
 /**
@@ -61,21 +60,6 @@
    ClassInfo getClassInfo();
 
    /**
-    * Get an instance adapter.
-    * 
-    * @param classInfo the changed class info
-    * @return instance adapter
-    */
-   ClassAdapter getInstanceAdapter(ClassInfo classInfo);
-
-   /**
-    * Get the dependencies of this adapter
-    *
-    * @return the list of dependencies
-    */
-   List<Object> getDependencies();
-
-   /**
     * Get the Joinpoint Factory for this adapter.
     * 
     * @return the joinpoint factory
@@ -88,25 +72,13 @@
     * @return the classloader
     */
    ClassLoader getClassLoader();
-   
-   /**
-    * Get the MetaDataContextFactory for this adpater
-    * 
-    * @return the metadata context factory
-    */
-   MetaDataContextFactory getMetaDataContextFactory();
 
    /**
-    * Get the metadata context
-    * 
-    * @return the metadata context
+    * Bean may have additional dependencies
+    * that the kernel cannot initially resolve. (currently defined by ClassAdapter)
+    *
+    * @param metaData the metadata
+    * @return the list of dependencies
     */
-   MetaDataContext getMetaDataContext();
-   
-   /**
-    * Set the metadata context
-    * 
-    * @param metaCtx a metadata context
-    */
-   void setMetaDataContext(MetaDataContext metaCtx);
+   List<Object> getDependencies(MetaData metaData);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/DependencyBuilder.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/DependencyBuilder.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/classadapter/spi/DependencyBuilder.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,6 +23,8 @@
 
 import java.util.List;
 
+import org.jboss.metadata.spi.MetaData;
+
 /**
  * DependencyBuilder.
  * 
@@ -35,7 +37,8 @@
     * Get the dependencies for this instance
     *
     * @param classAdapter the class adapter
+    * @param metaData the metadata
     * @return the dependencies
     */
-   List<Object> getDependencies(ClassAdapter classAdapter);
+   List<Object> getDependencies(ClassAdapter classAdapter, MetaData metaData);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/AbstractConfiguration.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/AbstractConfiguration.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/AbstractConfiguration.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -31,7 +31,6 @@
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.repository.spi.MetaDataContextFactory;
 import org.jboss.util.NestedRuntimeException;
 
 /**
@@ -54,9 +53,6 @@
    /** The default type joinpoint factory builder */
    private JoinpointFactoryBuilder joinpointFactoryBuilder;
    
-   /** The default metadata context factory */
-   private MetaDataContextFactory metaDataContextFactory;
-   
    /** The dependency builder */
    private DependencyBuilder dependencyBuilder;
 
@@ -145,30 +141,6 @@
       return joinpointFactoryBuilder;
    }
 
-   public MetaDataContextFactory getMetaDataContextFactory()
-   {
-      if (metaDataContextFactory == null)
-      {
-         try
-         {
-            metaDataContextFactory = createDefaultMetaDataContextFactory();
-         }
-         catch (RuntimeException e)
-         {
-            throw e;
-         }
-         catch (Error e)
-         {
-            throw e;
-         }
-         catch (Throwable t)
-         {
-            throw new NestedRuntimeException("Cannot create MetaDataContextFactory", t);
-         }
-      }
-      return metaDataContextFactory;
-   }
-
    public DependencyBuilder getDependencyBuilder()
    {
       if (dependencyBuilder == null)
@@ -252,14 +224,6 @@
    protected abstract JoinpointFactoryBuilder createDefaultJoinpointFactoryBuilder() throws Throwable;
 
    /**
-    * Create the default metadata context factory
-    * 
-    * @return the metadata context factory
-    * @throws Throwable for any error
-    */
-   protected abstract MetaDataContextFactory createDefaultMetaDataContextFactory() throws Throwable;
-
-   /**
     * Create the default dependency builder
     * 
     * @return the dependency builder

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/BasicConfiguration.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -31,8 +31,6 @@
 import org.jboss.joinpoint.spi.JoinpointFactoryBuilder;
 import org.jboss.reflect.plugins.introspection.IntrospectionTypeInfoFactory;
 import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.repository.plugins.basic.BasicMetaDataContextFactory;
-import org.jboss.repository.spi.MetaDataContextFactory;
 
 /**
  * Basic configuration.
@@ -71,11 +69,6 @@
       return new BasicJoinpointFactoryBuilder();
    }
 
-   protected MetaDataContextFactory createDefaultMetaDataContextFactory() throws Throwable
-   {
-      return new BasicMetaDataContextFactory();
-   }
-
    protected DependencyBuilder createDefaultDependencyBuilder() throws Throwable
    {
       return new AbstractDependencyBuilder();

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfiguration.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfiguration.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfiguration.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -31,7 +31,6 @@
 import org.jboss.joinpoint.spi.JoinpointFactoryBuilder;
 import org.jboss.logging.Logger;
 import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.repository.spi.MetaDataContextFactory;
 
 /**
  * PropertyConfiguration.
@@ -99,11 +98,6 @@
       return (JoinpointFactoryBuilder) loadFromProperties(PropertyConfigurationConstants.JOIN_POINT_FACTORY_BUILDER_NAME, PropertyConfigurationConstants.JOIN_POINT_FACTORY_BUILDER_DEFAULT, JoinpointFactoryBuilder.class);
    }
 
-   protected MetaDataContextFactory createDefaultMetaDataContextFactory() throws Throwable
-   {
-      return (MetaDataContextFactory) loadFromProperties(PropertyConfigurationConstants.META_DATA_CONTEXT_FACTORY_BUILDER_NAME, PropertyConfigurationConstants.META_DATA_CONTEXT_FACTORY_BUILDER_DEFAULT, MetaDataContextFactory.class);
-   }
-
    protected DependencyBuilder createDefaultDependencyBuilder() throws Throwable
    {
       return (DependencyBuilder) loadFromProperties(PropertyConfigurationConstants.DEPENDENCY_BUILDER_NAME, PropertyConfigurationConstants.DEPENDENCY_BUILDER_DEFAULT, DependencyBuilder.class);

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfigurationConstants.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfigurationConstants.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/config/plugins/property/PropertyConfigurationConstants.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -26,7 +26,6 @@
 import org.jboss.classadapter.spi.DependencyBuilder;
 import org.jboss.joinpoint.spi.JoinpointFactoryBuilder;
 import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.repository.spi.MetaDataContextFactory;
 
 /**
  * Constants.
@@ -60,12 +59,6 @@
    /** The JoinpointFactoryBuiylder default value */
    static final String JOIN_POINT_FACTORY_BUILDER_DEFAULT="org.jboss.aop.microcontainer.integration.AOPJoinpointFactoryBuilder:org.jboss.joinpoint.plugins.BasicJoinpointFactoryBuilder";
 
-   /** The MetaDataContextFactory property name */
-   static final String META_DATA_CONTEXT_FACTORY_BUILDER_NAME = MetaDataContextFactory.class.getName();
-   
-   /** The MetaDataContextFactory default value */
-   static final String META_DATA_CONTEXT_FACTORY_BUILDER_DEFAULT="org.jboss.aop.microcontainer.integration.AOPMetaDataContextFactory:org.jboss.repository.plugins.basic.BasicMetaDataContextFactory";
-
    /** The TypeInfoFactory property name */
    static final String TYPE_INFO_FACTORY_NAME = TypeInfoFactory.class.getName();
    

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/config/spi/Configuration.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/config/spi/Configuration.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/config/spi/Configuration.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -27,7 +27,6 @@
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.TypeInfoFactory;
-import org.jboss.repository.spi.MetaDataContextFactory;
 
 /**
  * Configuration.<p>
@@ -106,11 +105,4 @@
     * @return the JoinpointFactoryBuilder
     */
    JoinpointFactoryBuilder getJoinpointFactoryBuilder();
-
-   /**
-    * Get the metadata context factory
-    * 
-    * @return the MetaDataContextFactory
-    */
-   MetaDataContextFactory getMetaDataContextFactory();
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactory.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactory.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -31,7 +31,6 @@
 import org.jboss.reflect.spi.ConstructorInfo;
 import org.jboss.reflect.spi.FieldInfo;
 import org.jboss.reflect.spi.MethodInfo;
-import org.jboss.repository.spi.MetaDataContext;
 import org.jboss.util.JBossObject;
 import org.jboss.util.JBossStringBuilder;
 
@@ -45,13 +44,9 @@
    /** The class info */
    protected ClassInfo classInfo;
    
-   /** The metadata context */
-   protected MetaDataContext metaDataContext;
-   
-   public BasicJoinpointFactory(ClassInfo classInfo, MetaDataContext metaDataContext)
+   public BasicJoinpointFactory(ClassInfo classInfo)
    {
       this.classInfo = classInfo;
-      this.metaDataContext = metaDataContext;
    }
    
    public ClassInfo getClassInfo()

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactoryBuilder.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactoryBuilder.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/BasicJoinpointFactoryBuilder.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,7 +24,6 @@
 import org.jboss.joinpoint.spi.JoinpointFactory;
 import org.jboss.joinpoint.spi.JoinpointFactoryBuilder;
 import org.jboss.reflect.spi.ClassInfo;
-import org.jboss.repository.spi.MetaDataContext;
 
 /**
  * BasicJoinpointFactoryBuilder.
@@ -34,13 +33,8 @@
  */
 public class BasicJoinpointFactoryBuilder implements JoinpointFactoryBuilder
 {
-   public JoinpointFactory createJoinpointFactory(ClassInfo classInfo, MetaDataContext metaDataContext)
-   {
-      return new BasicJoinpointFactory(classInfo, metaDataContext);
-   }
-
    public JoinpointFactory createJoinpointFactory(ClassInfo classInfo)
    {
-      return createJoinpointFactory(classInfo, null);
+      return new BasicJoinpointFactory(classInfo);
    }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/spi/JoinpointFactoryBuilder.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/spi/JoinpointFactoryBuilder.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/spi/JoinpointFactoryBuilder.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -22,7 +22,6 @@
 package org.jboss.joinpoint.spi;
 
 import org.jboss.reflect.spi.ClassInfo;
-import org.jboss.repository.spi.MetaDataContext;
 
 /**
  * JoinpointFactoryBuilder.
@@ -39,13 +38,4 @@
     * @return the joinpoint factory
     */
    JoinpointFactory createJoinpointFactory(ClassInfo classInfo);
-
-   /**
-    * Create a joinpoint factory
-    * 
-    * @param classInfo the class info
-    * @param metaDataContext the metadata context
-    * @return the joinpoint factory
-    */
-   JoinpointFactory createJoinpointFactory(ClassInfo classInfo, MetaDataContext metaDataContext);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/AbstractMetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/AbstractMetaDataContext.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/AbstractMetaDataContext.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -39,6 +39,7 @@
 import org.jboss.metadata.spi.retrieval.cummulative.CummulativeMetaDatasItem;
 import org.jboss.metadata.spi.scope.Scope;
 import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * AbstractMetaDataContext.
@@ -266,4 +267,32 @@
       
       return null;
    }
+
+   public MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature)
+   {
+      if (signature == null)
+         return null;
+      
+      List<MetaDataRetrieval> componentRetrievals = null;
+      for (int i = 0; i < retrievals.size(); ++i)
+      {
+         MetaDataRetrieval retrieval = retrievals.get(i);
+         retrieval = retrieval.getComponentMetaDataRetrieval(signature);
+         if (retrieval != null)
+         {
+            if (componentRetrievals == null)
+               componentRetrievals = new ArrayList<MetaDataRetrieval>();
+            componentRetrievals.add(retrieval);
+         }
+      }
+      
+      MetaDataContext parentComponent = null;
+      if (parent != null)
+         parentComponent = (MetaDataContext) parent.getComponentMetaDataRetrieval(signature);
+
+      if (componentRetrievals == null)
+         return parentComponent;
+      
+      return new AbstractMetaDataContext(parentComponent, componentRetrievals);
+   }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/context/CachingMetaDataContext.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -33,6 +33,7 @@
 import org.jboss.metadata.spi.retrieval.MetaDataItem;
 import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
 import org.jboss.metadata.spi.retrieval.MetaDatasItem;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * CachingMetaDataContext.
@@ -55,6 +56,8 @@
    /** All meta data */
    private volatile MetaDatasItem cachedMetaDatasItem;
 
+   private volatile Map<Signature, MetaDataRetrieval> cachedComponents;
+   
    /** The valid time */
    private volatile long validTime;
    
@@ -221,4 +224,46 @@
       
       return result;
    }
+   
+   public void append(MetaDataRetrieval retrieval)
+   {
+      super.append(retrieval);
+      cachedComponents = null;
+   }
+
+   public void prepend(MetaDataRetrieval retrieval)
+   {
+      super.prepend(retrieval);
+      cachedComponents = null;
+   }
+
+   public void remove(MetaDataRetrieval retrieval)
+   {
+      super.remove(retrieval);
+      cachedComponents = null;
+   }
+
+   public MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature)
+   {
+      if (signature == null)
+         return null;
+
+      if (cachedComponents != null)
+      {
+         MetaDataRetrieval retrieval = cachedComponents.get(signature);
+         if (retrieval != null)
+            return retrieval;
+      }
+      
+      MetaDataRetrieval retrieval = super.getComponentMetaDataRetrieval(signature);
+      
+      if (retrieval != null)
+      {
+         if (cachedComponents == null)
+            cachedComponents = new ConcurrentHashMap<Signature, MetaDataRetrieval>();
+         cachedComponents.put(signature, retrieval);
+      }
+      
+      return retrieval;
+   }
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/BasicMetaDataLoader.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/BasicMetaDataLoader.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/BasicMetaDataLoader.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -27,7 +27,9 @@
 import org.jboss.metadata.generic.GenericMatcher;
 import org.jboss.metadata.spi.retrieval.AnnotationItem;
 import org.jboss.metadata.spi.retrieval.MetaDataItem;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
 import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * BasicMetaDataLoader.
@@ -65,4 +67,9 @@
       MetaDataItem[] metaDatas = retrieveMetaData().getMetaDatas();
       return GenericMatcher.matchMetaDataItem(metaDatas, name);
    }
+
+   public MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature)
+   {
+      return null;
+   }
 }

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/SimpleMetaDataLoader.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/SimpleMetaDataLoader.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/SimpleMetaDataLoader.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.plugins.loader;
+
+import java.lang.annotation.Annotation;
+
+import org.jboss.metadata.spi.retrieval.AnnotationItem;
+import org.jboss.metadata.spi.retrieval.AnnotationsItem;
+import org.jboss.metadata.spi.retrieval.simple.SimpleAnnotationItem;
+import org.jboss.metadata.spi.retrieval.simple.SimpleAnnotationsItem;
+
+/**
+ * SimpleMetaDataLoader.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 46146 $
+ */
+public class SimpleMetaDataLoader extends BasicMetaDataLoader
+{
+   /** The annotations */
+   private AnnotationsItem annotationsItem;
+   
+   /**
+    * Create a new SimpleMetaDataLoader.
+    * 
+    * @param annotations the annoations
+    */
+   @SuppressWarnings("unchecked")
+   public SimpleMetaDataLoader(Annotation[] annotations)
+   {
+      if (annotations == null)
+         throw new IllegalArgumentException("Null annotations");
+      
+      AnnotationItem[] annotationItems = new AnnotationItem[annotations.length];
+      for (int i = 0; i < annotations.length; ++i)
+         annotationItems[i] = new SimpleAnnotationItem(annotations[i]);
+      
+      annotationsItem = new SimpleAnnotationsItem(annotationItems);
+   }
+
+   public AnnotationsItem retrieveAnnotations()
+   {
+      return annotationsItem;
+   }
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/memory/MemoryMetaDataLoader.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/memory/MemoryMetaDataLoader.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/memory/MemoryMetaDataLoader.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -28,16 +28,19 @@
 import java.util.concurrent.ConcurrentHashMap;
 
 import org.jboss.metadata.plugins.loader.AbstractMutableMetaDataLoader;
+import org.jboss.metadata.spi.ComponentMutableMetaData;
 import org.jboss.metadata.spi.retrieval.AnnotationItem;
 import org.jboss.metadata.spi.retrieval.AnnotationsItem;
 import org.jboss.metadata.spi.retrieval.Item;
 import org.jboss.metadata.spi.retrieval.MetaDataItem;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
 import org.jboss.metadata.spi.retrieval.MetaDatasItem;
 import org.jboss.metadata.spi.retrieval.basic.BasicAnnotationItem;
 import org.jboss.metadata.spi.retrieval.basic.BasicAnnotationsItem;
 import org.jboss.metadata.spi.retrieval.basic.BasicMetaDataItem;
 import org.jboss.metadata.spi.retrieval.basic.BasicMetaDatasItem;
 import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * MemoryMetaDataLoader.
@@ -45,7 +48,7 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class MemoryMetaDataLoader extends AbstractMutableMetaDataLoader
+public class MemoryMetaDataLoader extends AbstractMutableMetaDataLoader implements ComponentMutableMetaData
 {
    /** The annotations */
    private volatile Map<String, BasicAnnotationItem> annotations;
@@ -53,12 +56,15 @@
    /** MetaData by name */
    private volatile Map<String, BasicMetaDataItem> metaDataByName;
 
+   /** The component metadata */
+   private volatile Map<Signature, MetaDataRetrieval> components; 
+
    /** All annotations */
    private volatile BasicAnnotationsItem cachedAnnotationsItem;
 
    /** All meta data */
    private volatile BasicMetaDatasItem cachedMetaDatasItem;
-
+   
    /** Whether we should cache items */
    private final boolean cachable;
    
@@ -358,6 +364,36 @@
       return result.getValue();
    }
 
+   public MetaDataRetrieval addComponentMetaDataRetrieval(Signature signature, MetaDataRetrieval component)
+   {
+      if (signature == null)
+         throw new IllegalArgumentException("Null signature");
+      
+      if (components == null)
+         components = new ConcurrentHashMap<Signature, MetaDataRetrieval>();
+      
+      return components.put(signature, component);
+   }
+
+   public MetaDataRetrieval removeComponentMetaDataRetrieval(Signature signature)
+   {
+      if (signature == null)
+         throw new IllegalArgumentException("Null signature");
+      
+      if (components == null)
+         return null;
+      
+      return components.remove(signature);
+   }
+
+   public MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature)
+   {
+      if (components == null)
+         return null;
+      
+      return components.get(signature);
+   }
+
    /**
     * Invalidate the annotations item
     */

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/reflection/AnnotatedElementMetaDataLoader.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/reflection/AnnotatedElementMetaDataLoader.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/plugins/loader/reflection/AnnotatedElementMetaDataLoader.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,16 +23,26 @@
 
 import java.lang.annotation.Annotation;
 import java.lang.reflect.AnnotatedElement;
+import java.lang.reflect.Constructor;
+import java.lang.reflect.Field;
 import java.lang.reflect.Member;
+import java.lang.reflect.Method;
 
 import org.jboss.metadata.plugins.loader.BasicMetaDataLoader;
+import org.jboss.metadata.plugins.loader.SimpleMetaDataLoader;
 import org.jboss.metadata.spi.retrieval.AnnotationItem;
 import org.jboss.metadata.spi.retrieval.AnnotationsItem;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
 import org.jboss.metadata.spi.retrieval.simple.SimpleAnnotationItem;
 import org.jboss.metadata.spi.retrieval.simple.SimpleAnnotationsItem;
 import org.jboss.metadata.spi.scope.CommonLevels;
 import org.jboss.metadata.spi.scope.Scope;
 import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.ConstructorSignature;
+import org.jboss.metadata.spi.signature.FieldSignature;
+import org.jboss.metadata.spi.signature.MethodParametersSignature;
+import org.jboss.metadata.spi.signature.MethodSignature;
+import org.jboss.metadata.spi.signature.Signature;
 import org.jboss.util.JBossStringBuilder;
 import org.jboss.util.Strings;
 
@@ -101,6 +111,69 @@
       return new SimpleAnnotationItem<T>(annotation);
    }
 
+   public MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature)
+   {
+      if (signature == null)
+         return null;
+
+      if (annotated instanceof Class)
+      {
+         Class clazz = (Class) annotated;
+         if (signature instanceof ConstructorSignature)
+         {
+            try
+            {
+               Constructor constructor = clazz.getConstructor(signature.getParametersTypes(clazz));
+               return new AnnotatedElementMetaDataLoader(constructor);
+            }
+            catch (NoSuchMethodException e)
+            {
+               return null;
+            }
+         }
+         else if (signature instanceof MethodSignature)
+         {
+            try
+            {
+               Method method = clazz.getMethod(signature.getName(), signature.getParametersTypes(clazz));
+               return new AnnotatedElementMetaDataLoader(method);
+            }
+            catch (NoSuchMethodException e)
+            {
+               return null;
+            }
+         }
+         else if (signature instanceof MethodParametersSignature)
+         {
+            try
+            {
+               Method method = clazz.getMethod(signature.getName(), signature.getParametersTypes(clazz));
+               Annotation[][] paramAnnotations = method.getParameterAnnotations();
+               MethodParametersSignature sig = (MethodParametersSignature) signature;
+               return new SimpleMetaDataLoader(paramAnnotations[sig.getParam()]);
+            }
+            catch (NoSuchMethodException e)
+            {
+               return null;
+            }
+         }
+         else if (signature instanceof FieldSignature)
+         {
+            try
+            {
+               Field field = clazz.getField(signature.getName());
+               return new AnnotatedElementMetaDataLoader(field);
+            }
+            catch (NoSuchFieldException e)
+            {
+               return null;
+            }
+         }
+      }
+      
+      return null;
+   }
+
    public String toString()
    {
       JBossStringBuilder buffer = new JBossStringBuilder();

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/ComponentMutableMetaData.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/ComponentMutableMetaData.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/ComponentMutableMetaData.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,51 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi;
+
+import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
+import org.jboss.metadata.spi.signature.Signature;
+
+/**
+ * ComponentMutableMetaData.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 57133 $
+ */
+public interface ComponentMutableMetaData
+{
+   /**
+    * Add a component metadata
+    * 
+    * @param signature the signature
+    * @param component the component
+    * @return any previous component at that signature
+    */
+   MetaDataRetrieval addComponentMetaDataRetrieval(Signature signature, MetaDataRetrieval component);
+
+   /**
+    * Remove a component metadata
+    * 
+    * @param signature the signature
+    * @return any previous component at that signature
+    */
+   MetaDataRetrieval removeComponentMetaDataRetrieval(Signature signature);
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/MetaData.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/MetaData.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/MetaData.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,6 +23,8 @@
 
 import java.lang.annotation.Annotation;
 
+import org.jboss.metadata.spi.signature.Signature;
+
 /**
  * MetaData.
  * 
@@ -140,4 +142,12 @@
     * @return true when the metadata is present
     */
    boolean isMetaDataPresent(String name, Class<?> type);
+   
+   /**
+    * Get the component metadata
+    * 
+    * @param signature the signature
+    * @return the component metadata
+    */
+   MetaData getComponentMetaData(Signature signature);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrieval.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrieval.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrieval.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,6 +24,7 @@
 import java.lang.annotation.Annotation;
 
 import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * MetaDataRetrieval.
@@ -100,4 +101,12 @@
     * @return the metadata or null if not present
     */
    MetaDataItem retrieveMetaData(String name);
+   
+   /**
+    * Get the component metadata retrieval
+    * 
+    * @param signature the signature
+    * @return the component metadata retrieval
+    */
+   MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature);
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrievalToMetaDataBridge.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrievalToMetaDataBridge.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/retrieval/MetaDataRetrievalToMetaDataBridge.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,6 +24,7 @@
 import java.lang.annotation.Annotation;
 
 import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * MetaDataRetrievalToMetaDataBridge.
@@ -36,6 +37,11 @@
    /** The meta data retrieval method */
    private MetaDataRetrieval retrieval;
    
+   /**
+    * Create a new MetaDataRetrievalToMetaDataBridge.
+    * 
+    * @param retrieval the retrieval
+    */
    public MetaDataRetrievalToMetaDataBridge(MetaDataRetrieval retrieval)
    {
       if (retrieval == null)
@@ -148,6 +154,35 @@
       return getMetaData(name) != null;
    }
 
+   public MetaData getComponentMetaData(Signature signature)
+   {
+      MetaDataRetrieval component = retrieval.getComponentMetaDataRetrieval(signature);
+      if (component == null)
+         return null;
+      return new MetaDataRetrievalToMetaDataBridge(component);
+   }
+
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null || obj instanceof MetaDataRetrievalToMetaDataBridge == false)
+         return false;
+      
+      MetaDataRetrievalToMetaDataBridge other = (MetaDataRetrievalToMetaDataBridge) obj;
+      return retrieval.equals(other.retrieval);
+   }
+
+   public int hashCode()
+   {
+      return retrieval.hashCode();
+   }
+
+   public String toString()
+   {
+      return super.toString() + "{" + retrieval.getScope() + "}";
+   }
+
    /**
     * Get the meta data retrieval
     * 

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/scope/ScopeKey.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/scope/ScopeKey.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/scope/ScopeKey.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -299,11 +299,14 @@
       return scopes.hashCode();
    }
 
-   protected ScopeKey clone()
+   public ScopeKey clone()
    {
       try
       {
-         return (ScopeKey) super.clone();
+         ScopeKey result = (ScopeKey) super.clone();
+         result.scopes = Collections.synchronizedSortedMap(new TreeMap<ScopeLevel, Scope>(scopes));
+         result.frozen = false;
+         return result;
       }
       catch (CloneNotSupportedException e)
       {

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/ConstructorSignature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/ConstructorSignature.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/ConstructorSignature.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,63 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.signature;
+
+import java.lang.reflect.Constructor;
+
+/**
+ * Constructor Signature.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ConstructorSignature extends Signature
+{
+   /**
+    * Create a new Signature.
+    * 
+    * @param parameters the parameters
+    */
+   public ConstructorSignature(String[] parameters)
+   {
+      super(parameters);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param parameters the parameters
+    */
+   public ConstructorSignature(Class... parameters)
+   {
+      super(parameters);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param constructor the constructor
+    */
+   public ConstructorSignature(Constructor<?> constructor)
+   {
+      super(constructor.getParameterTypes());
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/FieldSignature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/FieldSignature.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/FieldSignature.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,53 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.signature;
+
+import java.lang.reflect.Field;
+
+/**
+ * Field Signature.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class FieldSignature extends Signature
+{
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the name
+    */
+   public FieldSignature(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param field the field
+    */
+   public FieldSignature(Field field)
+   {
+      super(field.getName());
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodParametersSignature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodParametersSignature.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodParametersSignature.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,102 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.signature;
+
+import java.lang.reflect.Method;
+
+/**
+ * Method parameters Signature.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MethodParametersSignature extends Signature
+{
+   /** The parameter number */
+   private int param;
+   
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the name
+    * @param param the parameter number
+    * @param parameters the parameters
+    */
+   public MethodParametersSignature(String name, String[] parameters, int param)
+   {
+      super(name, parameters);
+      this.param = param;
+      checkParam();
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the name
+    * @param param the parameter number
+    * @param parameters the parameters
+    */
+   public MethodParametersSignature(String name, int param, Class... parameters)
+   {
+      super(name, parameters);
+      this.param = param;
+      checkParam();
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param method the method
+    * @param param the parameter number
+    */
+   public MethodParametersSignature(Method method, int param)
+   {
+      super(method.getName(), method.getParameterTypes());
+      this.param = param;
+      checkParam();
+   }
+   
+   /**
+    * Get the param.
+    * 
+    * @return the param.
+    */
+   public int getParam()
+   {
+      return param;
+   }
+
+   /**
+    * Check the param number makes sense
+    */
+   protected void checkParam()
+   {
+      if (param < 0 || param >= getParameters().length)
+         throw new IllegalArgumentException("param must be between 0 and " + getParameters().length);
+   }
+
+   protected void internalToString(StringBuilder builder)
+   {
+      super.internalToString(builder);
+      builder.append("#").append(param);
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodSignature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodSignature.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/MethodSignature.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,65 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.signature;
+
+import java.lang.reflect.Method;
+
+/**
+ * Method Signature.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MethodSignature extends Signature
+{
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the name
+    * @param parameters the parameters
+    */
+   public MethodSignature(String name, String[] parameters)
+   {
+      super(name, parameters);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the name
+    * @param parameters the parameters
+    */
+   public MethodSignature(String name, Class... parameters)
+   {
+      super(name, parameters);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param method the method
+    */
+   public MethodSignature(Method method)
+   {
+      super(method.getName(), method.getParameterTypes());
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,290 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.signature;
+
+import java.util.Arrays;
+
+/**
+ * Signature.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class Signature
+{
+   /** No Name */
+   public static final String NO_NAME = new String("?%NO_NAME%?");
+
+   /** No Parameters */
+   public static final String[] NO_PARAMETERS = new String[0];
+
+   /** No Parameters Types */
+   public static final Class[] NO_PARAMETER_TYPES = new Class[0];
+   
+   /** The name */
+   private String name;
+   
+   /** The parameters */
+   private String[] parameters;
+
+   /** The parameter types */
+   private Class[] parameterTypes;
+   
+   /** The cached hashcode */
+   private transient int cachedHashCode = Integer.MIN_VALUE;
+
+   /**
+    * Convert classes to string
+    * 
+    * @param parameters the parameters as classes
+    * @return the parameters as strings
+    */
+   private static String[] classesToStrings(Class... parameters)
+   {
+      if (parameters == null || parameters.length == 0)
+         return NO_PARAMETERS;
+
+      String[] result = new String[parameters.length];
+      for (int i = 0; i < result.length; ++i)
+      {
+         if (parameters[i] == null)
+            throw new IllegalArgumentException("Null class");
+         result[i] = parameters[i].getName();
+      }
+      return result;
+   }
+
+   /**
+    * Convert classes to string
+    * 
+    * @param clazz the reference class
+    * @param parameters the parameters as strings
+    * @return the parameters as classes
+    */
+   private static Class[] stringstoClasses(Class clazz, String... parameters)
+   {
+      if (clazz == null)
+         throw new IllegalArgumentException("Null clazz");
+      
+      ClassLoader cl = clazz.getClassLoader();
+      if (cl == null)
+         cl = Class.class.getClassLoader();
+      
+      return stringstoClasses(cl, parameters);
+   }
+
+   /**
+    * Convert classes to string
+    * 
+    * @param cl the classloader
+    * @param parameters the parameters as strings
+    * @return the parameters as classes
+    */
+   private static Class[] stringstoClasses(ClassLoader cl, String... parameters)
+   {
+      if (cl == null)
+         throw new IllegalArgumentException("Null classloader");
+
+      if (parameters == null || parameters.length == 0)
+         return NO_PARAMETER_TYPES;
+
+      Class[] result = new Class[parameters.length];
+      for (int i = 0; i < result.length; ++i)
+      {
+         try
+         {
+            result[i] = cl.loadClass(parameters[i]);
+         }
+         catch (ClassNotFoundException e)
+         {
+            throw new IllegalStateException("Class not found: " + parameters[i], e);
+         }
+      }
+      return result;
+   }
+   
+   /**
+    * Create a new Signature.
+    */
+   public Signature()
+   {
+      this(NO_NAME, NO_PARAMETER_TYPES, NO_PARAMETERS);
+   }
+   
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the  name
+    */
+   public Signature(String name)
+   {
+      this(name, null, NO_PARAMETERS);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param parameters the parameters
+    */
+   public Signature(String... parameters)
+   {
+      this(NO_NAME, null, parameters);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param parameters the parameters
+    */
+   public Signature(Class... parameters)
+   {
+      this(NO_NAME, parameters, null);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the  name
+    * @param parameters the parameters
+    */
+   public Signature(String name, Class... parameters)
+   {
+      this(name, parameters, null);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the  name
+    * @param parameters the parameters
+    */
+   public Signature(String name, String... parameters)
+   {
+      this(name, null, parameters);
+   }
+
+   /**
+    * Create a new Signature.
+    * 
+    * @param name the  name
+    * @param parameterTypes the parameterTypes
+    * @param parameters the parameters
+    */
+   private Signature(String name, Class[] parameterTypes, String[] parameters)
+   {
+      this.name = name;
+      this.parameters = parameters;
+      this.parameterTypes = parameterTypes; 
+      if (name == null)
+         this.name = NO_NAME;
+      if (parameters == null)
+         this.parameters = classesToStrings(parameterTypes);
+      for (int i = 0; i < this.parameters.length; ++i)
+      {
+         if (this.parameters[i] == null)
+            throw new IllegalArgumentException("Null parameter");
+      }
+   }
+   
+   /**
+    * Get the name.
+    * 
+    * @return the name.
+    */
+   public String getName()
+   {
+      return name;
+   }
+
+   /**
+    * Get the parameters.
+    * 
+    * @return the parameters.
+    */
+   public String[] getParameters()
+   {
+      return parameters;
+   }
+
+   /**
+    * Get the parameter types.
+    * 
+    * @param clazz the reference class
+    * @return the parameter types.
+    */
+   public Class[] getParametersTypes(Class clazz)
+   {
+      if (parameterTypes == null)
+         return stringstoClasses(clazz, parameters);
+      return parameterTypes;
+   }
+   
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null || obj instanceof Signature == false)
+         return false;
+      
+      Signature other = (Signature) obj;
+      
+      if (getName().equals(other.getName()) == false)
+         return false;
+      
+      if (parameters.length != other.parameters.length)
+         return false;
+      
+      for (int i = 0; i < parameters.length; ++i)
+      {
+         if (parameters[i].equals(other.parameters[i]) == false)
+            return false;
+      }
+      return true;
+   }
+   
+   public int hashCode()
+   {
+      if (cachedHashCode == Integer.MIN_VALUE)
+         cachedHashCode = toString().hashCode();
+      return cachedHashCode;
+   }
+   
+   public String toString()
+   {
+      StringBuilder builder = new StringBuilder();
+      internalToString(builder);
+      return builder.toString();
+   }
+
+   /**
+    * Build the to String
+    * 
+    * @param builder the builder to use
+    */
+   protected void internalToString(StringBuilder builder)
+   {
+      if (name != null)
+         builder.append(name);
+      if (parameters != null)
+         builder.append(Arrays.asList(parameters));
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStack.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStack.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStack.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,124 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.stack;
+
+import java.util.ArrayList;
+
+import org.jboss.metadata.spi.MetaData;
+
+/**
+ * MetaDataStack.
+ * 
+ * TODO add some security to the mutable operations
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public final class MetaDataStack
+{
+   /** The stack */
+   private static ThreadLocal<ArrayList<MetaData>> stack = new ThreadLocal<ArrayList<MetaData>>()
+   {
+      protected ArrayList<MetaData> initialValue()
+      {
+         return new ArrayList<MetaData>();
+      }
+   };
+   
+   /**
+    * Push some meta data
+    * 
+    * @param metaData the meta data
+    */
+   public static void push(MetaData metaData)
+   {
+      /** TODO MetaDataStackPermission
+      if (metaData == null)
+         throw new IllegalArgumentException("Null meta data");
+      */
+      
+      SecurityManager sm = System.getSecurityManager();
+      if (sm != null)
+         sm.checkPermission(MetaDataStackPermission.MODIFY);
+      
+      stack.get().add(metaData);
+   }
+   
+   /**
+    * Pop some meta data
+    */
+   public static void pop()
+   {
+      /** TODO MetaDataStackPermission
+      SecurityManager sm = System.getSecurityManager();
+      if (sm != null)
+         sm.checkPermission(MetaDataStackPermission.MODIFY);
+      */
+
+      ArrayList<MetaData> list = stack.get();
+      if (list.size() == 0)
+         throw new IllegalArgumentException("Empty stack");
+
+      list.remove(list.size()-1);
+   }
+
+   
+   /**
+    * Peek some meta data
+    * 
+    * @return the metadata or null if there isn't one
+    */
+   public static MetaData peek()
+   {
+      /** TODO MetaDataStackPermission
+      SecurityManager sm = System.getSecurityManager();
+      if (sm != null)
+         sm.checkPermission(MetaDataStackPermission.PEEK);
+      */
+
+      ArrayList<MetaData> list = stack.get();
+      if (list.size() == 0)
+         return null;
+      return list.get(list.size()-1);
+   }
+   
+   /**
+    * Mask the metadataa
+    */
+   public static void mask()
+   {
+      /** TODO MetaDataStackPermission
+      SecurityManager sm = System.getSecurityManager();
+      if (sm != null)
+         sm.checkPermission(MetaDataStackPermission.MODIFY);
+      */
+      
+      stack.get().add(null);
+   }
+   
+   /**
+    * Unmask the metadata
+    */
+   public static void unmask()
+   {
+      pop();
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStackPermission.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStackPermission.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/stack/MetaDataStackPermission.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,211 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metadata.spi.stack;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.security.BasicPermission;
+import java.security.Permission;
+import java.security.PermissionCollection;
+import java.util.Enumeration;
+import java.util.HashSet;
+import java.util.Iterator;
+
+/** 
+ * This permission represents "trust" in a signer or codebase.
+ * 
+ * It contains a target name but no actions list. The targets are
+ * <ul>
+ * <li> modify - whether the caller can push/pop onto the stack
+ * <li> peek - whether the caller can peek onto the stack
+ * <li> * - all
+ * </ul>
+ * 
+ * @author adrian at jboss.com
+ * @version $Revision: 57306 $
+ */
+public class MetaDataStackPermission extends BasicPermission
+{
+   /** For serialization */
+   private static final long serialVersionUID = 5661980843569388590L;
+
+   /** The modify permission */
+   static MetaDataStackPermission MODIFY = new MetaDataStackPermission("modify");
+
+   /** The peek permission */
+   static MetaDataStackPermission PEEK = new MetaDataStackPermission("peek");
+   
+   /** Whether we have all names */
+   private transient boolean allNames;
+
+   /** 
+    * Create a new Permission
+    * 
+    * @param name the target
+    * @throws IllegalArgumentException for invalid name 
+    * @throws NullPointerException for null name
+    */ 
+   public MetaDataStackPermission(String name)
+   {
+      this(name, null);
+   }
+
+   /** 
+    * Create a new Permission
+    * 
+    * @param name the target
+    * @param actions the actions
+    * @throws IllegalArgumentException for an invalid name or target 
+    * @throws NullPointerException for null name
+    */ 
+   public MetaDataStackPermission(String name, String actions)
+   {
+      super(name, actions);
+      init(name, actions);
+   }
+
+   /**
+    * @return human readable string.
+    */
+   public String toString()
+   {
+      StringBuffer buffer = new StringBuffer(100);
+      buffer.append(getClass().getName()).append(":");
+      buffer.append(" name=").append(getName());
+      buffer.append(" actions=").append(getActions());
+      return buffer.toString();
+   }
+
+   /**
+    * Checks if this KernelPermission object "implies" the specified
+    * permission. More specifically, this method returns true if:
+    * p is an instance of KernelPermission,
+    * p's target names are a subset of this object's target names
+    * 
+    * The configure permission implies the access permission.
+    * 
+    * @param p the permission
+    * @return true when the permission is implied
+    */ 
+   public boolean implies(Permission p)
+   {
+      if( (p instanceof MetaDataStackPermission) == false)
+         return false;
+
+      return (allNames == true);
+   }
+
+   /** 
+    * Must override to handle the configure implies access relationship.
+    * 
+    * @return the permission collection
+    */ 
+   public PermissionCollection newPermissionCollection()
+   {
+      return new MetaDataStackPermissionCollection();
+   }
+
+   private void readObject(ObjectInputStream ois) throws IOException, ClassNotFoundException
+   {
+      ois.defaultReadObject();
+      init(getName(), getActions());
+   }
+
+   /**
+    * Construct a new KernelPermission for a given name
+    *
+    * @param name the name of the permission to grant
+    * @param actions unused
+    * @exception NullPointerException if the name is null
+    * @exception IllegalArgumentException if the name is not * or one of the
+    * allowed names or a comma-separated list of the allowed names, or if
+    * actions is a non-null non-empty string.
+    */
+   private void init(String name, String actions)
+   {
+      if( name == null )
+         throw new NullPointerException("name cannot be null");
+
+      if( actions != null && actions.length() > 0 )
+         throw new IllegalArgumentException("actions must be null or empty");
+
+      if (name.equals("*") == false &&
+          name.equals("modify") == false &&
+          name.equals("peek") == false)
+         throw new IllegalArgumentException("Unknown name: " + name);
+      allNames = name.equals("*");
+   }
+
+   /**
+    * A MetaDataStackPermissionCollection.
+    */
+   class MetaDataStackPermissionCollection extends PermissionCollection
+   {
+      /** The serialVersionUID */
+      private static final long serialVersionUID = 3256442516797665329L;
+
+      /** The permissions */
+      private HashSet<Permission> permissions = new HashSet<Permission>();
+      
+      /** Whether we have all permissions */
+      private boolean hasAll;
+
+      public void add(Permission p)
+      {
+         if (isReadOnly())
+            throw new SecurityException("Collection is read-only");
+         if (p instanceof MetaDataStackPermission)
+            permissions.add(p);
+         if (p.getName().equals("*"))
+            hasAll = true;
+      }
+
+      public boolean implies(Permission p)
+      {
+         boolean implies = false;
+         if (p instanceof MetaDataStackPermission)
+         {
+            implies = hasAll;
+            if (implies == false)
+               implies = permissions.contains(p);
+         }
+         return implies;
+      }
+
+      public Enumeration<Permission> elements()
+      {
+         final Iterator<Permission> iter = permissions.iterator();
+         return new Enumeration<Permission>()
+         {
+            public boolean hasMoreElements()
+            {
+               return iter.hasNext();
+            }
+
+            public Permission nextElement()
+            {
+               return iter.next();
+            }
+         };
+      }
+   }
+}
\ No newline at end of file

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -34,10 +34,10 @@
 import java.util.concurrent.atomic.AtomicBoolean;
 
 import org.jboss.util.collection.WeakSet;
-import org.jboss.virtual .plugins.vfs.helpers.FilterVirtualFileVisitor;
-import org.jboss.virtual .plugins.vfs.helpers.MatchAllVirtualFileFilter;
-import org.jboss.virtual .spi.VFSContext;
-import org.jboss.virtual .spi.VirtualFileHandler;
+import org.jboss.virtual.plugins.vfs.helpers.FilterVirtualFileVisitor;
+import org.jboss.virtual.plugins.vfs.helpers.MatchAllVirtualFileFilter;
+import org.jboss.virtual.spi.VFSContext;
+import org.jboss.virtual.spi.VirtualFileHandler;
 
 /**
  * A virtual file as seen by the user
@@ -126,6 +126,7 @@
     * @return the full URI to the VF in the VFS.
     * @throws URISyntaxException if a uri cannot be parsed
     * @throws IllegalStateException if the file is closed
+    * @throws MalformedURLException for a bad url
     */
    public URI toURI() throws MalformedURLException, URISyntaxException
    {

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowser.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,19 +21,18 @@
 */
 package org.jboss.virtual.plugins.context;
 
+import java.io.IOException;
+import java.util.Iterator;
+import java.util.List;
+
 import org.jboss.util.file.ArchiveBrowser;
 import org.jboss.virtual.VirtualFile;
 import org.jboss.virtual.VirtualFileFilter;
 import org.jboss.virtual.VisitorAttributes;
+import org.jboss.virtual.plugins.context.jar.JarUtils;
+import org.jboss.virtual.plugins.vfs.helpers.FilterVirtualFileVisitor;
 import org.jboss.virtual.plugins.vfs.helpers.SuffixesExcludeFilter;
-import org.jboss.virtual.plugins.vfs.helpers.FilterVirtualFileVisitor;
-import org.jboss.virtual.plugins.context.jar.JarUtils;
 
-import java.util.Iterator;
-import java.util.List;
-import java.io.InputStream;
-import java.io.IOException;
-
 /**
  * This is a bridge to an older, crappier API written by myself.
  *
@@ -44,6 +43,7 @@
  */
 public class VfsArchiveBrowser implements Iterator
 {
+   /** TODO WHAT DOES THIS DO? It is unused */
    private ArchiveBrowser.Filter filter;
    private VirtualFile vf;
    private Iterator<VirtualFile> it;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/VfsArchiveBrowserFactory.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,16 +21,15 @@
 */
 package org.jboss.virtual.plugins.context;
 
-import org.jboss.util.file.ArchiveBrowserFactory;
+import java.io.IOException;
+import java.net.URL;
+import java.util.Iterator;
+
 import org.jboss.util.file.ArchiveBrowser;
+import org.jboss.util.file.ArchiveBrowserFactory;
 import org.jboss.virtual.VirtualFile;
-import org.jboss.virtual.VFS;
 import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
 
-import java.util.Iterator;
-import java.net.URL;
-import java.io.IOException;
-
 /**
  * This is a bridge to an older, crappier API written by myself.
  *

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,20 +25,19 @@
 import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.io.ObjectInputStream;
-import java.net.URI;
-import java.net.URL;
 import java.net.MalformedURLException;
+import java.net.URI;
 import java.net.URISyntaxException;
+import java.net.URL;
 import java.util.ArrayList;
 import java.util.Collections;
+import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
-import java.util.HashMap;
 
 import org.jboss.virtual.plugins.context.AbstractURLHandler;
 import org.jboss.virtual.plugins.context.StructuredVirtualFileHandler;
 import org.jboss.virtual.spi.VirtualFileHandler;
-import org.jboss.virtual.VFS;
 
 /**
  * FileHandler.

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/AbstractJarHandler.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -392,8 +392,8 @@
    /**
     * Convert a URL into a JarFIle
     *
-    * @param url
-    * @return
+    * @param url the url to convert
+    * @return the jar file
     * @throws IOException
     */
    public static JarFile fromURL(URL url) throws IOException

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,10 +24,8 @@
 import java.io.FileNotFoundException;
 import java.io.IOException;
 import java.io.InputStream;
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.net.URL;
 import java.net.URISyntaxException;
+import java.net.URL;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.HashMap;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,24 +21,20 @@
 */
 package org.jboss.virtual.protocol.vfsfile;
 
-import org.jboss.virtual.VFS;
-import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
-
 import java.io.File;
 import java.io.IOException;
 import java.io.InputStream;
 import java.net.URL;
+import java.net.URLClassLoader;
 import java.net.URLConnection;
 import java.net.URLStreamHandler;
-import java.net.URLClassLoader;
+import java.util.Enumeration;
+import java.util.HashSet;
 import java.util.jar.JarEntry;
 import java.util.jar.JarFile;
-import java.util.HashSet;
-import java.util.Enumeration;
-import java.util.Map;
-import java.util.Collections;
-import java.util.HashMap;
 
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
+
 /**
  * URLStreamHandler for VFS
  *

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsjar/Handler.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,18 +21,14 @@
 */
 package org.jboss.virtual.protocol.vfsjar;
 
-import org.jboss.virtual.VFS;
-import org.jboss.virtual.VirtualFile;
-import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
-
-import java.net.URLStreamHandler;
-import java.net.URLConnection;
-import java.net.URL;
-import java.net.URISyntaxException;
 import java.io.IOException;
-import java.io.File;
 import java.io.InputStream;
+import java.net.URL;
+import java.net.URLConnection;
+import java.net.URLStreamHandler;
 
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
+
 /**
  * URLStreamHandler for VFS
  *

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -58,7 +58,7 @@
    /**
     * Get a VFS-based URL
     *
-    * @return
+    * @return the url
     * @throws MalformedURLException
     * @throws URISyntaxException
     */

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/joinpoint/test/JoinpointTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/joinpoint/test/JoinpointTest.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/joinpoint/test/JoinpointTest.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -117,7 +117,7 @@
    {
       TypeInfoFactory typeFactory = getTypeInfoFactory();
       ClassInfo info = (ClassInfo) typeFactory.getTypeInfo(clazz);
-      return new BasicJoinpointFactory(info, null);
+      return new BasicJoinpointFactory(info);
    }
    
    protected abstract TypeInfoFactory getTypeInfoFactory();

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryLoaderComponentBasicAnnotationsUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryLoaderComponentBasicAnnotationsUnitTestCase.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryLoaderComponentBasicAnnotationsUnitTestCase.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,108 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.loader.memory.test;
+
+import org.jboss.metadata.plugins.loader.memory.MemoryMetaDataLoader;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrievalToMetaDataBridge;
+import org.jboss.metadata.spi.signature.ConstructorSignature;
+import org.jboss.metadata.spi.signature.FieldSignature;
+import org.jboss.metadata.spi.signature.MethodParametersSignature;
+import org.jboss.metadata.spi.signature.MethodSignature;
+import org.jboss.test.metadata.shared.ComponentBasicAnnotationsTest;
+import org.jboss.test.metadata.shared.support.TestAnnotation1Impl;
+import org.jboss.test.metadata.shared.support.TestAnnotation2Impl;
+import org.jboss.test.metadata.shared.support.TestAnnotationImpl;
+
+/**
+ * MemoryLoaderComponentBasicAnnotationsUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MemoryLoaderComponentBasicAnnotationsUnitTestCase extends ComponentBasicAnnotationsTest
+{
+   public MemoryLoaderComponentBasicAnnotationsUnitTestCase(String name)
+   {
+      super(name, true);
+   }
+
+   protected MetaData setupField()
+   {
+      MemoryMetaDataLoader loader = new MemoryMetaDataLoader();
+      MemoryMetaDataLoader component = new MemoryMetaDataLoader();
+      loader.addComponentMetaDataRetrieval(new FieldSignature("empty"), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotationImpl());
+      loader.addComponentMetaDataRetrieval(new FieldSignature("testAnnotation"), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotation1Impl());
+      component.addAnnotation(new TestAnnotation2Impl());
+      loader.addComponentMetaDataRetrieval(new FieldSignature("testAnnotation12"), component);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+
+   protected MetaData setupConstructor()
+   {
+      MemoryMetaDataLoader loader = new MemoryMetaDataLoader();
+      MemoryMetaDataLoader component = new MemoryMetaDataLoader();
+      loader.addComponentMetaDataRetrieval(new ConstructorSignature(), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotationImpl());
+      loader.addComponentMetaDataRetrieval(new ConstructorSignature(String.class), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotation1Impl());
+      component.addAnnotation(new TestAnnotation2Impl());
+      loader.addComponentMetaDataRetrieval(new ConstructorSignature(String.class, Class.class), component);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+
+   protected MetaData setupMethod()
+   {
+      MemoryMetaDataLoader loader = new MemoryMetaDataLoader();
+      MemoryMetaDataLoader component = new MemoryMetaDataLoader();
+      loader.addComponentMetaDataRetrieval(new MethodSignature("empty"), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotationImpl());
+      loader.addComponentMetaDataRetrieval(new MethodSignature("testAnnotation", String.class), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotation1Impl());
+      component.addAnnotation(new TestAnnotation2Impl());
+      loader.addComponentMetaDataRetrieval(new MethodSignature("testAnnotation12", String.class, Class.class), component);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+
+   protected MetaData setupMethodParams()
+   {
+      MemoryMetaDataLoader loader = new MemoryMetaDataLoader();
+      MemoryMetaDataLoader component = new MemoryMetaDataLoader();
+      loader.addComponentMetaDataRetrieval(new MethodParametersSignature("empty", 0, String.class), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotationImpl());
+      loader.addComponentMetaDataRetrieval(new MethodParametersSignature("testAnnotation", 0, String.class), component);
+      component = new MemoryMetaDataLoader();
+      component.addAnnotation(new TestAnnotation1Impl());
+      component.addAnnotation(new TestAnnotation2Impl());
+      loader.addComponentMetaDataRetrieval(new MethodParametersSignature("testAnnotation12", 1, String.class, Class.class), component);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+}

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryMetaDataLoaderTestSuite.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryMetaDataLoaderTestSuite.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/memory/test/MemoryMetaDataLoaderTestSuite.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -43,6 +43,7 @@
       TestSuite suite = new TestSuite("Memory MetaDataLoader Tests");
 
       suite.addTest(new TestSuite(MemoryLoaderBasicAnnotationsUnitTestCase.class));
+      suite.addTest(new TestSuite(MemoryLoaderComponentBasicAnnotationsUnitTestCase.class));
       suite.addTest(new TestSuite(MemoryLoaderMutableAnnotationsUnitTestCase.class));
       suite.addTest(new TestSuite(MemoryLoaderMutableAnnotationsInvalidationUnitTestCase.class));
       suite.addTest(new TestSuite(MemoryLoaderBasicMetaDataUnitTestCase.class));

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/ConstructorBean.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/ConstructorBean.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/ConstructorBean.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.loader.reflection.support;
+
+import org.jboss.test.metadata.shared.support.TestAnnotation;
+import org.jboss.test.metadata.shared.support.TestAnnotation1;
+import org.jboss.test.metadata.shared.support.TestAnnotation2;
+
+/**
+ * ConstructorBean.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 45742 $
+ */
+public class ConstructorBean
+{
+   public ConstructorBean()
+   {
+   }
+
+   @TestAnnotation
+   public ConstructorBean(String p1)
+   {
+   }
+
+   @TestAnnotation1
+   @TestAnnotation2
+   public ConstructorBean(String p1, Class p2)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/FieldBean.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/FieldBean.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/FieldBean.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,44 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.loader.reflection.support;
+
+import org.jboss.test.metadata.shared.support.TestAnnotation;
+import org.jboss.test.metadata.shared.support.TestAnnotation1;
+import org.jboss.test.metadata.shared.support.TestAnnotation2;
+
+/**
+ * FieldBean.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 45742 $
+ */
+public class FieldBean
+{
+   public String empty;
+
+   @TestAnnotation
+   public String testAnnotation;
+
+   @TestAnnotation1
+   @TestAnnotation2
+   public String testAnnotation12;
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodBean.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodBean.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodBean.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.loader.reflection.support;
+
+import org.jboss.test.metadata.shared.support.TestAnnotation;
+import org.jboss.test.metadata.shared.support.TestAnnotation1;
+import org.jboss.test.metadata.shared.support.TestAnnotation2;
+
+/**
+ * MethodBean.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 45742 $
+ */
+public class MethodBean
+{
+   public void empty()
+   {
+   }
+
+   @TestAnnotation
+   public void testAnnotation(String p1)
+   {
+   }
+
+   @TestAnnotation1
+   @TestAnnotation2
+   public void testAnnotation12(String p1, Class p2)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodParamBean.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodParamBean.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/support/MethodParamBean.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,47 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.loader.reflection.support;
+
+import org.jboss.test.metadata.shared.support.TestAnnotation;
+import org.jboss.test.metadata.shared.support.TestAnnotation1;
+import org.jboss.test.metadata.shared.support.TestAnnotation2;
+
+/**
+ * MethodParamBean.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 45742 $
+ */
+public class MethodParamBean
+{
+   public void empty(String p1)
+   {
+   }
+
+   public void testAnnotation(@TestAnnotation String p1)
+   {
+   }
+
+   public void testAnnotation12(String p1, @TestAnnotation1 @TestAnnotation2 Class p2)
+   {
+   }
+}

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,69 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.loader.reflection.test;
+
+import org.jboss.metadata.plugins.loader.reflection.AnnotatedElementMetaDataLoader;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrievalToMetaDataBridge;
+import org.jboss.test.metadata.loader.reflection.support.ConstructorBean;
+import org.jboss.test.metadata.loader.reflection.support.FieldBean;
+import org.jboss.test.metadata.loader.reflection.support.MethodBean;
+import org.jboss.test.metadata.loader.reflection.support.MethodParamBean;
+import org.jboss.test.metadata.shared.ComponentBasicAnnotationsTest;
+
+/**
+ * AnnotatedElementLoaderBasicAnnotationsUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 46146 $
+ */
+public class AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase extends ComponentBasicAnnotationsTest
+{
+   public AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase(String name)
+   {
+      super(name, true);
+   }
+
+   protected MetaData setupField()
+   {
+      AnnotatedElementMetaDataLoader loader = new AnnotatedElementMetaDataLoader(FieldBean.class);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+
+   protected MetaData setupConstructor()
+   {
+      AnnotatedElementMetaDataLoader loader = new AnnotatedElementMetaDataLoader(ConstructorBean.class);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+
+   protected MetaData setupMethod()
+   {
+      AnnotatedElementMetaDataLoader loader = new AnnotatedElementMetaDataLoader(MethodBean.class);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+
+   protected MetaData setupMethodParams()
+   {
+      AnnotatedElementMetaDataLoader loader = new AnnotatedElementMetaDataLoader(MethodParamBean.class);
+      return new MetaDataRetrievalToMetaDataBridge(loader);
+   }
+}

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/ReflectionMetaDataLoaderTestSuite.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/ReflectionMetaDataLoaderTestSuite.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/loader/reflection/test/ReflectionMetaDataLoaderTestSuite.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -43,6 +43,7 @@
       TestSuite suite = new TestSuite("Reflection MetaDataLoader Tests");
 
       suite.addTest(new TestSuite(AnnotatedElementLoaderBasicAnnotationsUnitTestCase.class));
+      suite.addTest(new TestSuite(AnnotatedElementLoaderComponentBasicAnnotationsUnitTestCase.class));
       suite.addTest(new TestSuite(AnnotatedElementLoaderScopeUnitTestCase.class));
       
       return suite;

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/retrieval/support/TestMetaDataRetrieval.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/retrieval/support/TestMetaDataRetrieval.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/retrieval/support/TestMetaDataRetrieval.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -32,6 +32,7 @@
 import org.jboss.metadata.spi.scope.Scope;
 import org.jboss.metadata.spi.scope.ScopeKey;
 import org.jboss.metadata.spi.scope.ScopeLevel;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * TestMetaDataRetrieval.
@@ -98,4 +99,9 @@
       lastMethod = "retrieveMetaData(String)";
       return null;
    }
+
+   public MetaDataRetrieval getComponentMetaDataRetrieval(Signature signature)
+   {
+      return null;
+   }
 }

Added: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/ComponentBasicAnnotationsTest.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/ComponentBasicAnnotationsTest.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/ComponentBasicAnnotationsTest.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,209 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metadata.shared;
+
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.signature.ConstructorSignature;
+import org.jboss.metadata.spi.signature.FieldSignature;
+import org.jboss.metadata.spi.signature.MethodParametersSignature;
+import org.jboss.metadata.spi.signature.MethodSignature;
+import org.jboss.test.metadata.AbstractMetaDataTest;
+import org.jboss.test.metadata.shared.support.ExpectedAnnotations;
+import org.jboss.test.metadata.shared.support.NotPresentAnnotation;
+import org.jboss.test.metadata.shared.support.TestAnnotation;
+import org.jboss.test.metadata.shared.support.TestAnnotation1;
+import org.jboss.test.metadata.shared.support.TestAnnotation2;
+
+/**
+ * ComponentBasicAnnotationsTest.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 46146 $
+ */
+public abstract class ComponentBasicAnnotationsTest extends AbstractMetaDataTest
+{
+   protected boolean local;
+   
+   public ComponentBasicAnnotationsTest(String name, boolean local)
+   {
+      super(name);
+      this.local = local;
+   }
+   
+   protected abstract MetaData setupConstructor();
+   
+   protected abstract MetaData setupField();
+   
+   protected abstract MetaData setupMethod();
+   
+   protected abstract MetaData setupMethodParams();
+   
+   public void testFieldNotFound() throws Exception
+   {
+      MetaData metaData = setupField();
+      metaData = metaData.getComponentMetaData(new FieldSignature("notFound"));
+      assertNull(metaData);
+   }
+   
+   public void testConstructorNotFound() throws Exception
+   {
+      MetaData metaData = setupConstructor();
+      metaData = metaData.getComponentMetaData(new ConstructorSignature(Void.class));
+      assertNull(metaData);
+   }
+   
+   public void testMethodNotFound() throws Exception
+   {
+      MetaData metaData = setupMethod();
+      metaData = metaData.getComponentMetaData(new MethodSignature("notFound"));
+      assertNull(metaData);
+   }
+   
+   public void testMethodParamsNotFound() throws Exception
+   {
+      MetaData metaData = setupMethodParams();
+      metaData = metaData.getComponentMetaData(new MethodParametersSignature("notFound", 0, Void.class));
+      assertNull(metaData);
+   }
+   
+   public void testFieldEmpty() throws Exception
+   {
+      MetaData metaData = setupField();
+      metaData = metaData.getComponentMetaData(new FieldSignature("empty"));
+      testEmpty(metaData);
+   }
+   
+   public void testConstructorEmpty() throws Exception
+   {
+      MetaData metaData = setupConstructor();
+      metaData = metaData.getComponentMetaData(new ConstructorSignature());
+      testEmpty(metaData);
+   }
+   
+   public void testMethodEmpty() throws Exception
+   {
+      MetaData metaData = setupMethod();
+      metaData = metaData.getComponentMetaData(new MethodSignature("empty"));
+      testEmpty(metaData);
+   }
+   
+   public void testMethodParamsEmpty() throws Exception
+   {
+      MetaData metaData = setupMethodParams();
+      metaData = metaData.getComponentMetaData(new MethodParametersSignature("empty", 0, String.class));
+      testEmpty(metaData);
+   }
+      
+   protected void testEmpty(MetaData metaData) throws Exception
+   {
+      assertNotNull(metaData);
+      ExpectedAnnotations expectedAnnotations = emptyExpectedAnnotations();
+
+      assertNoAnnotation(metaData, NotPresentAnnotation.class);
+      
+      assertAllAnnotations(metaData, expectedAnnotations, local);
+   }
+   
+   public void testFieldTestAnnotation() throws Exception
+   {
+      MetaData metaData = setupField();
+      metaData = metaData.getComponentMetaData(new FieldSignature("testAnnotation"));
+      testTestAnnotation(metaData);
+   }
+   
+   public void testConstructorTestAnnotation() throws Exception
+   {
+      MetaData metaData = setupConstructor();
+      metaData = metaData.getComponentMetaData(new ConstructorSignature(String.class));
+      testTestAnnotation(metaData);
+   }
+   
+   public void testMethodTestAnnotation() throws Exception
+   {
+      MetaData metaData = setupMethod();
+      metaData = metaData.getComponentMetaData(new MethodSignature("testAnnotation", String.class));
+      testTestAnnotation(metaData);
+   }
+   
+   public void testMethodParamsTestAnnotation() throws Exception
+   {
+      MetaData metaData = setupMethodParams();
+      metaData = metaData.getComponentMetaData(new MethodParametersSignature("testAnnotation", 0, String.class));
+      testTestAnnotation(metaData);
+   }
+   
+   protected void testTestAnnotation(MetaData metaData) throws Exception
+   {
+      assertNotNull(metaData);
+
+      ExpectedAnnotations expectedAnnotations = emptyExpectedAnnotations();
+
+      assertAnnotation(metaData, TestAnnotation.class);
+      assertNoAnnotation(metaData, NotPresentAnnotation.class);
+      
+      expectedAnnotations.add(TestAnnotation.class);
+      assertAllAnnotations(metaData, expectedAnnotations, local);
+   }
+   
+   public void testFieldTestAnnotation12() throws Exception
+   {
+      MetaData metaData = setupField();
+      metaData = metaData.getComponentMetaData(new FieldSignature("testAnnotation12"));
+      testTestAnnotation12(metaData);
+   }
+   
+   public void testConstructorTestAnnotation12() throws Exception
+   {
+      MetaData metaData = setupConstructor();
+      metaData = metaData.getComponentMetaData(new ConstructorSignature(String.class, Class.class));
+      testTestAnnotation12(metaData);
+   }
+   
+   public void testMethodTestAnnotation12() throws Exception
+   {
+      MetaData metaData = setupMethod();
+      metaData = metaData.getComponentMetaData(new MethodSignature("testAnnotation12", String.class, Class.class));
+      testTestAnnotation12(metaData);
+   }
+   
+   public void testMethodParamTestAnnotation12() throws Exception
+   {
+      MetaData metaData = setupMethodParams();
+      metaData = metaData.getComponentMetaData(new MethodParametersSignature("testAnnotation12", 1, String.class, Class.class));
+      testTestAnnotation12(metaData);
+   }
+
+   protected void testTestAnnotation12(MetaData metaData) throws Exception
+   {
+      assertNotNull(metaData);
+
+      ExpectedAnnotations expectedAnnotations = emptyExpectedAnnotations();
+      
+      assertAnnotation(metaData, TestAnnotation1.class);
+      assertAnnotation(metaData, TestAnnotation2.class);
+      assertNoAnnotation(metaData, NotPresentAnnotation.class);
+      
+      expectedAnnotations.add(TestAnnotation1.class);
+      expectedAnnotations.add(TestAnnotation2.class);
+      assertAllAnnotations(metaData, expectedAnnotations, local);
+   }
+}

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/support/MetaDataAndMutableMetaDataImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/support/MetaDataAndMutableMetaDataImpl.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/metadata/shared/support/MetaDataAndMutableMetaDataImpl.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,6 +25,7 @@
 
 import org.jboss.metadata.spi.MetaData;
 import org.jboss.metadata.spi.MutableMetaData;
+import org.jboss.metadata.spi.signature.Signature;
 
 /**
  * MetaDataAndMutableMetaDataImpl.
@@ -137,4 +138,9 @@
    {
       return mutable.removeMetaData(name, type);
    }
+
+   public MetaData getComponentMetaData(Signature signature)
+   {
+      return metaData.getComponentMetaData(signature);
+   }
 }

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/TestClassLoading.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -5,7 +5,6 @@
 import org.jboss.test.BaseTestCase;
 import org.jboss.virtual.VFS;
 import org.jboss.virtual.classloading.VFSClassLoader;
-import org.jboss.virtual.plugins.context.jar.JarUtils;
 
 public class TestClassLoading extends BaseTestCase
 {

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelController.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelController.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelController.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,6 +25,8 @@
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.CopyOnWriteArrayList;
 
 import org.jboss.beans.metadata.spi.BeanMetaData;
 import org.jboss.beans.metadata.spi.SupplyMetaData;
@@ -41,7 +43,6 @@
 import org.jboss.kernel.spi.registry.KernelRegistry;
 import org.jboss.kernel.spi.registry.KernelRegistryEntry;
 import org.jboss.kernel.spi.registry.KernelRegistryPlugin;
-import org.jboss.util.collection.CollectionsFactory;
 
 /**
  * Abstract Kernel controller.
@@ -58,10 +59,10 @@
    protected AbstractEventEmitter emitterDelegate = new AbstractEventEmitter();
 
    /** The supplies */
-   protected Map<Object, List<KernelControllerContext>> suppliers = CollectionsFactory.createConcurrentReaderMap();
+   protected Map<Object, List<KernelControllerContext>> suppliers = new ConcurrentHashMap<Object, List<KernelControllerContext>>();
 
    /** The contexts by class Map<Class, Set<ControllerContext>> */
-   protected Map<Class, ClassContext> contextsByClass = CollectionsFactory.createConcurrentReaderMap();
+   protected Map<Class, ClassContext> contextsByClass = new ConcurrentHashMap<Class, ClassContext>();
 
    /**
     * Create an abstract kernel controller
@@ -133,7 +134,7 @@
                   List<KernelControllerContext> list = suppliers.get(supply);
                   if (list == null)
                   {
-                     list = CollectionsFactory.createCopyOnWriteList();
+                     list = new CopyOnWriteArrayList<KernelControllerContext>();
                      suppliers.put(supply, list);
                   }
                   list.add(context);

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelControllerContext.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelControllerContext.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/AbstractKernelControllerContext.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -42,8 +42,10 @@
 import org.jboss.kernel.Kernel;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
-import org.jboss.kernel.spi.metadata.MutableMetaDataContext;
-import org.jboss.repository.spi.MetaDataContext;
+import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.repository.MetaDataRepository;
+import org.jboss.metadata.spi.scope.ScopeKey;
 import org.jboss.util.JBossStringBuilder;
 
 /**
@@ -54,36 +56,27 @@
  */
 public class AbstractKernelControllerContext extends AbstractControllerContext implements KernelControllerContext
 {
-   /**
-    * The default actions
-    */
+   /** The default actions */
    private static final KernelControllerContextActions actions = KernelControllerContextActions.getInstance();
 
-   /**
-    * The no instantiate actions
-    */
+   /** The no instantiate actions */
    private static final KernelControllerContextActions noInstantiate = KernelControllerContextActions.getNoInstantiate();
 
-   /**
-    * The BeanInfo
-    */
+   /** The BeanInfo */
    protected BeanInfo info;
 
-   /**
-    * The meta data
-    */
+   /** The meta data */
    protected BeanMetaData metaData;
 
-   /**
-    * The access control context
-    */
+   /** The access control context */
    protected AccessControlContext accessContext;
 
-   /**
-    * Did we do a describeVisit
-    */
+   /** Did we do a describeVisit */
    protected boolean isDescribeProcessed;
 
+   /** The scope */
+   protected ScopeKey scope;
+   
    /**
     * Create an abstract controller context
     *
@@ -133,6 +126,35 @@
       return metaData;
    }
 
+   public MetaData getMetaData()
+   {
+      KernelController controller = (KernelController) getController();
+      if (controller == null)
+         throw new IllegalStateException("Context is not associated with a controller");
+      MetaDataRepository repository = controller.getKernel().getMetaDataRepository().getMetaDataRepository();
+      ScopeKey scope = getScope();
+      return repository.getMetaData(scope);
+   }
+
+   public ScopeKey getScope()
+   {
+      if (scope == null)
+      {
+         // Bootstrap (probably not really a good idea?)
+         KernelController controller = (KernelController) getController();
+         if (controller == null)
+            return null;
+         KernelMetaDataRepository repository = controller.getKernel().getMetaDataRepository();
+         scope = repository.getFullScope(this);
+      }
+      return scope;
+   }
+   
+   public void setScope(ScopeKey key)
+   {
+      this.scope = key;
+   }
+
    public void toString(JBossStringBuilder buffer)
    {
       if (metaData != null)
@@ -173,28 +195,6 @@
       isDescribeProcessed = true;
    }
 
-   public MutableMetaDataContext getMetaDataContext()
-   {
-      if (info != null)
-      {
-         try
-         {
-            return (MutableMetaDataContext)info.getMetaDataContext();
-         }
-         catch (ClassCastException e)
-         {
-            throw new RuntimeException("MetaDataContext must be an instance of MutableMetaDataContext");
-         }
-      }
-      return null;
-   }
-
-   public void setMetaDataContext(MetaDataContext mctx)
-   {
-      info = info.getInstanceInfo();
-      info.setMetaDataContext(mctx);
-   }
-
    /**
     * Get the access control context of the code that created this context.<p>
     * <p/>

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,27 +21,19 @@
 */
 package org.jboss.kernel.plugins.dependency;
 
-import java.util.Iterator;
 import java.util.List;
-import java.util.Set;
 
 import org.jboss.beans.info.spi.BeanInfo;
-import org.jboss.beans.metadata.spi.AnnotationMetaData;
 import org.jboss.beans.metadata.spi.BeanMetaData;
-import org.jboss.beans.metadata.spi.PropertyMetaData;
 import org.jboss.dependency.plugins.AbstractDependencyItem;
-import org.jboss.dependency.spi.ControllerContext;
 import org.jboss.dependency.spi.ControllerState;
 import org.jboss.dependency.spi.DependencyInfo;
 import org.jboss.kernel.Kernel;
 import org.jboss.kernel.spi.config.KernelConfigurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
-import org.jboss.kernel.spi.metadata.MutableMetaDataContext;
-import org.jboss.metadata.spi.repository.MetaDataRepository;
-import org.jboss.repository.spi.KernelRepository;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.repository.spi.MetaDataContextFactory;
+import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
+import org.jboss.metadata.spi.MetaData;
 
 /**
  * DescribeAction.
@@ -63,112 +55,66 @@
          BeanInfo info = configurator.getBeanInfo(metaData);
          context.setBeanInfo(info);
 
-         info = addAnnotations(context, metaData, info);
-
-         DependencyInfo depends = context.getDependencyInfo();
-         // add custom dependencies (e.g. AOP layer).
-         List<Object> dependencies = info.getDependencies();
-         if (dependencies != null)
+         MetaData md = addMetaData(context);
+         try
          {
-            for (Object dependencyName : dependencies)
+            DependencyInfo depends = context.getDependencyInfo();
+            // add custom dependencies (e.g. AOP layer).
+            List<Object> dependencies = info.getDependencies(md);
+            log.trace("Extra dependencies for " + context.getName() + " " + dependencies);
+            if (dependencies != null)
             {
-               AbstractDependencyItem dependency = new AbstractDependencyItem(metaData.getName(), dependencyName, ControllerState.INSTANTIATED, ControllerState.INSTALLED);
-               depends.addIDependOn(dependency);
+               for (Object dependencyName : dependencies)
+               {
+                  AbstractDependencyItem dependency = new AbstractDependencyItem(metaData.getName(), dependencyName, ControllerState.INSTANTIATED, ControllerState.INSTALLED);
+                  depends.addIDependOn(dependency);
+               }
             }
          }
+         catch (Throwable t)
+         {
+            removeMetaData(context);
+            throw t;
+         }
       }
    }
 
    public void uninstallAction(KernelControllerContext context)
    {
-      context.setMetaDataContext(null);
+      removeMetaData(context);
       context.setBeanInfo(null);
    }
 
    /**
-    * Adds annotations to the bean. If annotations are added, returns the bean info for the instance
-    * @return The class bean info if no annotations exist or the instance bean info if annotations exist
+    * Adds annotations to the bean.
+    * 
+    * @param context the context
+    * @return the metadata
     */
-   private BeanInfo addAnnotations(KernelControllerContext context, BeanMetaData beanMetaData, BeanInfo beanInfo)
+   private MetaData addMetaData(KernelControllerContext context)
    {
-      MutableMetaDataContext metaCtx = addClassAnnotations(context, beanMetaData, beanInfo);
-      addPropertyAnnotations(metaCtx, context, beanMetaData, beanInfo);
-      return context.getBeanInfo();
+      KernelController controller = (KernelController) context.getController();
+      KernelMetaDataRepository repository = controller.getKernel().getMetaDataRepository();
+      repository.addMetaData(context);
+      return repository.getMetaData(context);
    }
 
-   private MutableMetaDataContext addClassAnnotations(KernelControllerContext context, BeanMetaData beanMetaData, BeanInfo beanInfo)
+   /**
+    * Remove any previously added metadata
+    * 
+    * @param context the context
+    */
+   private void removeMetaData(KernelControllerContext context)
    {
-      Set<AnnotationMetaData> annotations = beanMetaData.getAnnotations();
-
-      MutableMetaDataContext metaCtx = null;
-
-      if (annotations != null && annotations.size() > 0)
+      try
       {
-         metaCtx = getMetaDataContext(context);
-         if (metaCtx != null)
-         {
-            metaCtx.addAnnotations(annotations);
-         }
+         KernelController controller = (KernelController) context.getController();
+         KernelMetaDataRepository repository = controller.getKernel().getMetaDataRepository();
+         repository.removeMetaData(context);
       }
-
-      return metaCtx;
-   }
-
-   private MutableMetaDataContext addPropertyAnnotations(MutableMetaDataContext metaCtx, KernelControllerContext context, BeanMetaData beanMetaData, BeanInfo beanInfo)
-   {
-      Set properties = beanMetaData.getProperties();
-
-      if (properties != null && properties.size() > 0)
+      catch (Throwable ignored)
       {
-         for (Iterator it = properties.iterator() ; it.hasNext() ; )
-         {
-            PropertyMetaData property = (PropertyMetaData)it.next();
-            Set propertyAnnotations = property.getAnnotations();
-            if (propertyAnnotations != null && propertyAnnotations.size() > 0)
-            {
-               if (metaCtx == null)
-               {
-                  metaCtx = getMetaDataContext(context);
-               }
-               if (metaCtx != null)
-               {
-                  Set propertyInfos = beanInfo.getProperties();
-                  if (propertyInfos != null && propertyInfos.size() > 0)
-                  {
-                     metaCtx.addPropertyAnnotations(property.getName(), beanInfo.getProperties(), propertyAnnotations);
-                  }
-               }
-            }
-         }
+         log.warn("Unexpected error removing metadata: ", ignored);
       }
-
-      return metaCtx;
    }
-
-   private MutableMetaDataContext getMetaDataContext(KernelControllerContext context)
-   {
-      //TODO: Hardcoding this doesn't feel right...
-      ControllerContext repCtx = context.getController().getContext("Repository", ControllerState.INSTALLED);
-
-      if (repCtx == null)
-      {
-         log.warn("You have defined annotations for bean '" + context.getName() + "', but no MetaDataRepository has been installed under the name 'Repository'");
-         return null;
-      }
-
-      MetaDataRepository repository = (MetaDataRepository)repCtx.getTarget();
-      MetaDataContextFactory metaFactory = context.getBeanInfo().getMetaDataContextFactory();
-      ClassLoader beanLoader = context.getBeanInfo().getClassInfo().getType().getClassLoader();
-      MetaDataContext metaCtx = metaFactory.getMetaDataContext(beanLoader, repository, (String)context.getName());
-      
-      if (metaCtx instanceof MutableMetaDataContext == false)
-      {
-         throw new RuntimeException("MetaDataContext must be mutable");
-      }
-         
-      context.setMetaDataContext(metaCtx);
-
-      return (MutableMetaDataContext)metaCtx;
-   }
-
 }
\ No newline at end of file

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -28,8 +28,6 @@
 import org.jboss.kernel.spi.config.KernelConfigurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
-import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
-import org.jboss.kernel.spi.metadata.MutableMetaDataContext;
 
 /**
  * InstantiateAction.
@@ -52,12 +50,6 @@
       Object object = dispatchJoinPoint(context, joinPoint);
       context.setTarget(object);
 
-      MutableMetaDataContext metaCtx = context.getMetaDataContext();
-      if (metaCtx != null)
-      {
-         metaCtx.setTarget(object);
-      }
-
       try
       {
          if (object != null)

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -28,8 +28,12 @@
 import org.jboss.dependency.spi.ControllerContext;
 import org.jboss.joinpoint.spi.Joinpoint;
 import org.jboss.kernel.plugins.config.Configurator;
+import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
 import org.jboss.logging.Logger;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.stack.MetaDataStack;
 
 /**
  * KernelControllerContextAction.
@@ -39,6 +43,10 @@
  */
 public class KernelControllerContextAction implements ControllerContextAction
 {
+   /** Static log */
+   private static final Logger staticLog = Logger.getLogger(KernelControllerContextAction.class);
+   
+   /** The log */
    protected Logger log = Logger.getLogger(getClass());
 
    /** 
@@ -59,37 +67,53 @@
          AbstractKernelControllerContext theContext = (AbstractKernelControllerContext) context;
          access = theContext.getAccessControlContext();
       }
-
-      // Dispatch with the bean class loader if it exists
-      ClassLoader tcl = Thread.currentThread().getContextClassLoader();
+      
+      KernelController controller = (KernelController) context.getController();
+      KernelMetaDataRepository repository = controller.getKernel().getMetaDataRepository();
+      MetaData md = repository.getMetaData(context);
+      if (md != null)
+         MetaDataStack.push(md);
+      else
+         staticLog.warn("NO METADATA! for " + context.getName() + " with scope " + context.getScope());
       try
       {
-         if( cl != null && access == null )
-            Thread.currentThread().setContextClassLoader(cl);
-         if (access == null)
+         
+         // Dispatch with the bean class loader if it exists
+         ClassLoader tcl = Thread.currentThread().getContextClassLoader();
+         try
          {
-            return joinpoint.dispatch();
-         }
-         else
-         {
-            DispatchJoinPoint action = new DispatchJoinPoint(joinpoint);
-            try
+            if( cl != null && access == null )
+               Thread.currentThread().setContextClassLoader(cl);
+            if (access == null)
             {
-               return AccessController.doPrivileged(action, access);
+               return joinpoint.dispatch();
             }
-            catch (PrivilegedActionException e)
+            else
             {
-               throw e.getCause();
+               DispatchJoinPoint action = new DispatchJoinPoint(joinpoint);
+               try
+               {
+                  return AccessController.doPrivileged(action, access);
+               }
+               catch (PrivilegedActionException e)
+               {
+                  throw e.getCause();
+               }
             }
          }
+         finally
+         {
+            if( cl != null && access == null )
+               Thread.currentThread().setContextClassLoader(tcl);
+         }
       }
       finally
       {
-         if( cl != null && access == null )
-            Thread.currentThread().setContextClassLoader(tcl);
+         if (md != null)
+            MetaDataStack.pop();
       }
    }
-
+   
    public void install(final ControllerContext context) throws Throwable
    {
       if (System.getSecurityManager() == null || context instanceof AbstractKernelControllerContext == false)

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -34,8 +34,6 @@
 import org.jboss.kernel.spi.config.KernelConfigurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
-import org.jboss.repository.spi.MetaDataContext;
-import org.jboss.reflect.spi.AnnotationValue;
 import org.jboss.reflect.spi.MethodInfo;
 
 /**
@@ -180,7 +178,7 @@
       }
       catch (Throwable throwable)
       {
-         log.warn("Error during " + method, throwable);
+         log.warn("Error during " + method + " for " + context.getName(), throwable);
       }
    }
 

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/AbstractKernelDeployment.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/AbstractKernelDeployment.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/AbstractKernelDeployment.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,6 +23,7 @@
 
 import java.util.ArrayList;
 import java.util.List;
+import java.util.concurrent.CopyOnWriteArrayList;
 
 import org.jboss.beans.metadata.spi.BeanMetaData;
 import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
@@ -31,7 +32,6 @@
 import org.jboss.kernel.spi.deployment.KernelDeployment;
 import org.jboss.util.JBossObject;
 import org.jboss.util.JBossStringBuilder;
-import org.jboss.util.collection.CollectionsFactory;
 
 /**
  * An abstract kernel deployment.
@@ -48,7 +48,7 @@
    protected boolean installed;
 
    /** The installed contexts */
-   protected List<KernelControllerContext> installedContexts = CollectionsFactory.createCopyOnWriteList();
+   protected List<KernelControllerContext> installedContexts = new CopyOnWriteArrayList<KernelControllerContext>();
 
    /** The beans List<BeanMetaDataFactory> */
    protected List<BeanMetaDataFactory> beanFactories;

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/BasicKernelDeployer.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/BasicKernelDeployer.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/BasicKernelDeployer.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,11 +23,11 @@
 
 import java.util.List;
 import java.util.ListIterator;
+import java.util.concurrent.CopyOnWriteArrayList;
 
 import org.jboss.kernel.Kernel;
 import org.jboss.kernel.spi.deployment.KernelDeployment;
 import org.jboss.logging.Logger;
-import org.jboss.util.collection.CollectionsFactory;
 
 /**
  * BasicKernelDeployer.<p>
@@ -44,7 +44,7 @@
    private static final Logger log = Logger.getLogger(BasicKernelDeployer.class);
 
    /** The deployments */
-   protected List<KernelDeployment> deployments = CollectionsFactory.createCopyOnWriteList();
+   protected List<KernelDeployment> deployments = new CopyOnWriteArrayList<KernelDeployment>();
 
    /**
     * Create a new BasicKernelDeployer.

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BasicXMLDeployer.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BasicXMLDeployer.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BasicXMLDeployer.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,16 +25,16 @@
 import java.net.URL;
 import java.util.Collection;
 import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
 
 import org.jboss.kernel.Kernel;
 import org.jboss.kernel.plugins.deployment.BasicKernelDeployer;
 import org.jboss.kernel.spi.deployment.KernelDeployment;
 import org.jboss.logging.Logger;
-import org.jboss.util.collection.CollectionsFactory;
-import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
 import org.jboss.xb.binding.Unmarshaller;
 import org.jboss.xb.binding.UnmarshallerFactory;
 import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
+import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
 
 /**
  * BasicXMLDeployer.
@@ -54,7 +54,7 @@
    private static final SchemaBindingResolver resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
 
    /** The deployments by url or name */
-   private Map<String, KernelDeployment> deploymentsByName = CollectionsFactory.createConcurrentReaderMap();
+   private Map<String, KernelDeployment> deploymentsByName = new ConcurrentHashMap<String, KernelDeployment>();
 
    /**
     * Create a new XML deployer

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBinding.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBinding.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBinding.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1145,7 +1145,7 @@
          public void add(Object parent, Object child, QName name)
          {
             MapEntry entry = (MapEntry) parent;
-            entry.key = (ValueMetaData) child;
+            entry.key = child;
          }
       });
 
@@ -1155,7 +1155,7 @@
          public void add(Object parent, Object child, QName name)
          {
             MapEntry entry = (MapEntry) parent;
-            entry.value = (ValueMetaData) child;
+            entry.value = child;
          }
       });
    }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryKeyInterceptor.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryKeyInterceptor.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryKeyInterceptor.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,7 +23,6 @@
 
 import javax.xml.namespace.QName;
 
-import org.jboss.beans.metadata.spi.ValueMetaData;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
 
 /**
@@ -40,6 +39,6 @@
    public void add(Object parent, Object child, QName name)
    {
       MapEntry entry = (MapEntry) parent;
-      entry.key = (ValueMetaData) child;
+      entry.key =  child;
    }
 }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryValueInterceptor.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryValueInterceptor.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/EntryValueInterceptor.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -23,7 +23,6 @@
 
 import javax.xml.namespace.QName;
 
-import org.jboss.beans.metadata.spi.ValueMetaData;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
 
 /**
@@ -40,6 +39,6 @@
    public void add(Object parent, Object child, QName name)
    {
       MapEntry entry = (MapEntry) parent;
-      entry.value = (ValueMetaData) child;
+      entry.value = child;
    }
 }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/event/AbstractEventEmitter.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/event/AbstractEventEmitter.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/event/AbstractEventEmitter.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -25,13 +25,14 @@
 import java.util.List;
 import java.util.ListIterator;
 import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
+import java.util.concurrent.CopyOnWriteArrayList;
 
 import org.jboss.kernel.spi.event.KernelEvent;
 import org.jboss.kernel.spi.event.KernelEventEmitter;
 import org.jboss.kernel.spi.event.KernelEventFilter;
 import org.jboss.kernel.spi.event.KernelEventListener;
 import org.jboss.logging.Logger;
-import org.jboss.util.collection.CollectionsFactory;
 
 /**
  * Abstract Event emitter.
@@ -57,7 +58,7 @@
    };
 
    /** The registry Map<filter, Map<handback, List<listener>>>*/
-   protected Map<KernelEventFilter, Map<Object, List<KernelEventListener>>> eventListenerRegistry = CollectionsFactory.createConcurrentReaderMap();
+   protected Map<KernelEventFilter, Map<Object, List<KernelEventListener>>> eventListenerRegistry = new ConcurrentHashMap<KernelEventFilter, Map<Object,List<KernelEventListener>>>();
 
    /** The sequence number of this emitter */
    private long emitterSequence = 0;
@@ -74,6 +75,10 @@
 
    /**
     * Make a new event
+    * 
+    * @param type the event type
+    * @param context the context
+    * @return the event
     */
    public KernelEvent createEvent(String type, Object context)
    {
@@ -90,13 +95,13 @@
          Map<Object, List<KernelEventListener>> handbacks = eventListenerRegistry.get(filterObject);
          if (handbacks == null)
          {
-            handbacks = CollectionsFactory.createConcurrentReaderMap();
+            handbacks = new ConcurrentHashMap<Object, List<KernelEventListener>>();
             eventListenerRegistry.put(filterObject, handbacks);
          }
          List<KernelEventListener> listeners = handbacks.get(handbackObject);
          if (listeners == null)
          {
-            listeners = CollectionsFactory.createCopyOnWriteList();
+            listeners = new CopyOnWriteArrayList<KernelEventListener>();
             handbacks.put(handbackObject, listeners);
          }
          listeners.add(listener);

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/metadata/basic/BasicKernelMetaDataRepository.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/metadata/basic/BasicKernelMetaDataRepository.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/metadata/basic/BasicKernelMetaDataRepository.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -21,8 +21,30 @@
 */
 package org.jboss.kernel.plugins.metadata.basic;
 
+import java.util.ArrayList;
+import java.util.Set;
+
+import org.jboss.beans.info.spi.BeanInfo;
+import org.jboss.beans.info.spi.PropertyInfo;
+import org.jboss.beans.metadata.spi.AnnotationMetaData;
+import org.jboss.beans.metadata.spi.BeanMetaData;
+import org.jboss.beans.metadata.spi.PropertyMetaData;
 import org.jboss.kernel.plugins.metadata.AbstractKernelMetaDataRepository;
+import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.metadata.plugins.context.AbstractMetaDataContext;
+import org.jboss.metadata.plugins.loader.memory.MemoryMetaDataLoader;
+import org.jboss.metadata.plugins.loader.reflection.AnnotatedElementMetaDataLoader;
 import org.jboss.metadata.plugins.repository.basic.BasicMetaDataRepository;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.repository.MutableMetaDataRepository;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
+import org.jboss.metadata.spi.scope.CommonLevels;
+import org.jboss.metadata.spi.scope.Scope;
+import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.MethodSignature;
+import org.jboss.metadata.spi.stack.MetaDataStack;
+import org.jboss.reflect.spi.MethodInfo;
+import org.jboss.reflect.spi.TypeInfo;
 
 /**
  * BasicKernelMetaDataRepository.
@@ -39,4 +61,221 @@
    {
       super(new BasicMetaDataRepository());
    }
+
+   public MetaData getMetaData(KernelControllerContext context)
+   {
+      MutableMetaDataRepository repository = getMetaDataRepository();
+      ScopeKey scope = context.getScope();
+      MetaData metaData = repository.getMetaData(scope);
+      if (metaData == null)
+      {
+         initMetaDataRetrieval(context);
+         metaData = repository.getMetaData(scope);
+      }
+      return metaData;
+   }
+
+   public MetaDataRetrieval getMetaDataRetrieval(KernelControllerContext context)
+   {
+      MutableMetaDataRepository repository = getMetaDataRepository();
+      ScopeKey scope = context.getScope();
+      MetaDataRetrieval metaDataRetrieval = repository.getMetaDataRetrieval(scope);
+      if (metaDataRetrieval == null)
+         metaDataRetrieval = initMetaDataRetrieval(context);
+      return metaDataRetrieval;
+   }
+
+   public void popMetaData(KernelControllerContext context)
+   {
+      MetaDataStack.pop();
+   }
+
+   public void addMetaData(KernelControllerContext context)
+   {
+      MutableMetaDataRepository repository = getMetaDataRepository();
+      ScopeKey scope = getMutableScope(context);
+      MemoryMetaDataLoader mutable = new MemoryMetaDataLoader(scope);
+      repository.addMetaDataRetrieval(mutable);
+      addClassAnnotations(mutable, context);
+      addPropertyAnnotations(mutable, context);
+   }
+
+   public void removeMetaData(KernelControllerContext context)
+   {
+      MutableMetaDataRepository repository = getMetaDataRepository();
+      // Remove the read only/full scope
+      ScopeKey scope = context.getScope();
+      repository.removeMetaDataRetrieval(scope);
+      // Remove the mutable scope
+      scope = getMutableScope(context);
+      repository.removeMetaDataRetrieval(scope);
+   }
+
+   public ScopeKey getFullScope(KernelControllerContext context)
+   {
+      ScopeKey scope = ScopeKey.DEFAULT_SCOPE.clone();
+      scope.addScope(CommonLevels.INSTANCE, context.getName().toString());
+      BeanMetaData beanMetaData = context.getBeanMetaData();
+      if (beanMetaData != null)
+      {
+         String bean = beanMetaData.getBean();
+         if (bean != null)
+            scope.addScope(CommonLevels.CLASS, bean);
+      }
+      return scope;
+   }
+
+   public ScopeKey getMutableScope(KernelControllerContext context)
+   {
+      return new ScopeKey(CommonLevels.INSTANCE, context.getName().toString());
+   }
+
+   /**
+    * Initialise metadata retrieval
+    * 
+    * TODO lots more work
+    * @param context the context
+    * @return the retrieval
+    */
+   protected MetaDataRetrieval initMetaDataRetrieval(KernelControllerContext context)
+   {
+      MutableMetaDataRepository repository = getMetaDataRepository();
+      ScopeKey scopeKey = context.getScope();
+      ArrayList<MetaDataRetrieval> retrievals = new ArrayList<MetaDataRetrieval>();
+      for (Scope scope : scopeKey.getScopes())
+      {
+         ScopeKey thisScope = new ScopeKey(scope);
+         MetaDataRetrieval retrieval = repository.getMetaDataRetrieval(thisScope);
+         if (retrieval == null)
+         {
+            if (scope.getScopeLevel() == CommonLevels.CLASS)
+            {
+               ClassLoader cl = Thread.currentThread().getContextClassLoader();
+               try
+               {
+                  Class clazz = cl.loadClass(scope.getQualifier());
+                  retrieval = new AnnotatedElementMetaDataLoader(clazz);
+               }
+               catch (ClassNotFoundException e)
+               {
+                  throw new RuntimeException("Unable to load class: " + scope.getQualifier(), e);
+               }
+            }
+            else
+            {
+               retrieval = new MemoryMetaDataLoader(thisScope);
+               repository.addMetaDataRetrieval(retrieval);
+            }
+         }
+         retrievals.add(0, retrieval);
+      }
+      AbstractMetaDataContext metaDataContext = new AbstractMetaDataContext(null, retrievals);
+      repository.addMetaDataRetrieval(metaDataContext);
+      return metaDataContext;
+   }
+   
+   /**
+    * Add class annotations
+    * 
+    * @param mutable the mutable metadata
+    * @param context the context
+    */
+   private void addClassAnnotations(MemoryMetaDataLoader mutable, KernelControllerContext context)
+   {
+      BeanMetaData beanMetaData = context.getBeanMetaData();
+      if (beanMetaData != null)
+         addAnnotations(mutable, beanMetaData.getAnnotations());
+   }
+
+   /**
+    * Add property annotations
+    * 
+    * @param mutable the mutable
+    * @param beanMetaData the bean metadata
+    * @param beanInfo the bean info
+    */
+   private void addPropertyAnnotations(MemoryMetaDataLoader mutable, KernelControllerContext context)
+   {
+      BeanMetaData beanMetaData = context.getBeanMetaData();
+      if (beanMetaData == null)
+         return;
+      
+      Set<PropertyMetaData> properties = beanMetaData.getProperties();
+
+      if (properties == null || properties.size() == 0)
+         return;
+
+      BeanInfo beanInfo = context.getBeanInfo();
+      if (beanInfo == null)
+         return;
+      
+      for (PropertyMetaData property : properties)
+         addPropertyAnnotations(mutable, property, beanInfo);
+   }
+
+   /**
+    * Add property annotations
+    * 
+    * @param mutable the mutable
+    * @param propertyMetaData the property
+    * @param beanInfo the bean info
+    */
+   private void addPropertyAnnotations(MemoryMetaDataLoader mutable, PropertyMetaData propertyMetaData, BeanInfo beanInfo)
+   {
+      Set<AnnotationMetaData> propertyAnnotations = propertyMetaData.getAnnotations();
+      if (propertyAnnotations == null || propertyAnnotations.size() == 0)
+         return;
+
+      Set<PropertyInfo> propertyInfos = beanInfo.getProperties();
+      if (propertyInfos != null && propertyInfos.size() > 0)
+      {
+         for (PropertyInfo propertyInfo : propertyInfos)
+         {
+            if (propertyInfo.getName().equals(propertyMetaData.getName()))
+            {
+               MethodInfo methodInfo = propertyInfo.getGetter();
+               if (methodInfo != null)
+                  addAnnotations(mutable, methodInfo, propertyAnnotations);
+               methodInfo = propertyInfo.getSetter();
+               if (methodInfo != null)
+                  addAnnotations(mutable, methodInfo, propertyAnnotations);
+            }
+         }
+      }
+   }
+   
+   /**
+    * Add annotations for a method
+    * 
+    * @param mutable the mutable metadata
+    * @param methodInfo the method info
+    * @param annotations the annotations
+    */
+   private void addAnnotations(MemoryMetaDataLoader mutable, MethodInfo methodInfo, Set<AnnotationMetaData> annotations)
+   {
+      TypeInfo[] typeInfos = methodInfo.getParameterTypes();
+      String[] paramTypes = new String[typeInfos.length];
+      for (int i = 0; i < typeInfos.length; ++i)
+         paramTypes[i] = typeInfos[i].getName();
+
+      ScopeKey scope = new ScopeKey(CommonLevels.JOINPOINT_OVERRIDE, methodInfo.getName());
+      MemoryMetaDataLoader loader = new MemoryMetaDataLoader(scope);
+      addAnnotations(loader, annotations);
+      mutable.addComponentMetaDataRetrieval(new MethodSignature(methodInfo.getName(), paramTypes), loader);
+   }
+   
+   /**
+    * Add annotations to a mutable metadata
+    * 
+    * @param mutable the mutable metadata
+    * @param annotations the annotations
+    */
+   private void addAnnotations(MemoryMetaDataLoader mutable, Set<AnnotationMetaData> annotations)
+   {
+      if (annotations == null || annotations.size() == 0)
+         return;
+
+      for (AnnotationMetaData annotation : annotations)
+         mutable.addAnnotation(annotation.getAnnotationInstance());
+   }
 }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/AbstractKernelRegistry.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/AbstractKernelRegistry.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/AbstractKernelRegistry.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,13 +24,13 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.ListIterator;
+import java.util.concurrent.CopyOnWriteArrayList;
 
 import org.jboss.kernel.plugins.AbstractKernelObject;
 import org.jboss.kernel.spi.registry.KernelRegistry;
 import org.jboss.kernel.spi.registry.KernelRegistryEntry;
 import org.jboss.kernel.spi.registry.KernelRegistryEntryNotFoundException;
 import org.jboss.kernel.spi.registry.KernelRegistryPlugin;
-import org.jboss.util.collection.CollectionsFactory;
 
 /**
  * Abstract Kernel registry.
@@ -42,7 +42,7 @@
 public abstract class AbstractKernelRegistry extends AbstractKernelObject implements KernelRegistry
 {
    /** The registry factories */
-   protected List<KernelRegistryPlugin> factories = CollectionsFactory.createCopyOnWriteList();
+   protected List<KernelRegistryPlugin> factories = new CopyOnWriteArrayList<KernelRegistryPlugin>();
 
    /**
     * Create an abstract kernel registry

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/basic/BasicKernelRegistryFactory.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/basic/BasicKernelRegistryFactory.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/registry/basic/BasicKernelRegistryFactory.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -22,13 +22,13 @@
 package org.jboss.kernel.plugins.registry.basic;
 
 import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
 
 import org.jboss.kernel.spi.registry.KernelRegistryEntry;
 import org.jboss.kernel.spi.registry.KernelRegistryEntryAlreadyRegisteredException;
 import org.jboss.kernel.spi.registry.KernelRegistryEntryNotFoundException;
 import org.jboss.kernel.spi.registry.KernelRegistryPlugin;
 import org.jboss.logging.Logger;
-import org.jboss.util.collection.CollectionsFactory;
 
 /**
  * Basic Kernel registry factory.
@@ -42,7 +42,7 @@
    private static final Logger log = Logger.getLogger(BasicKernelRegistryFactory.class);
 
    /** The registred entries */
-   protected Map<Object, KernelRegistryEntry> entries = CollectionsFactory.createConcurrentReaderMap();
+   protected Map<Object, KernelRegistryEntry> entries = new ConcurrentHashMap<Object, KernelRegistryEntry>();
 
    /**
     * Create a new basic registry factory

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/KernelControllerContext.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/KernelControllerContext.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/KernelControllerContext.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -24,9 +24,9 @@
 import org.jboss.beans.info.spi.BeanInfo;
 import org.jboss.beans.metadata.spi.BeanMetaData;
 import org.jboss.kernel.Kernel;
-import org.jboss.kernel.spi.metadata.MutableMetaDataContext;
 import org.jboss.kernel.spi.registry.KernelRegistryEntry;
-import org.jboss.repository.spi.MetaDataContext;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.scope.ScopeKey;
 /**
  * Information about dependencies and state.
  * 
@@ -71,16 +71,23 @@
    void setTarget(Object target);
    
    /**
-    * Get the metadata context
+    * Get the metadata
     * 
-    * @return the metadata context
+    * @return the metadata
     */
-   MutableMetaDataContext getMetaDataContext();
+   MetaData getMetaData();
    
    /**
-    * Set the metadata context
+    * Get the scope
     * 
-    * @param mctx the metadata context
+    * @return the scope
     */
-   void setMetaDataContext(MetaDataContext mctx);
+   ScopeKey getScope();
+   
+   /**
+    * Set the scope
+    * 
+    * @param key the scope key
+    */
+   void setScope(ScopeKey key);
 }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/KernelMetaDataRepository.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/KernelMetaDataRepository.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/KernelMetaDataRepository.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -22,7 +22,11 @@
 package org.jboss.kernel.spi.metadata;
 
 import org.jboss.kernel.spi.KernelObject;
+import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.metadata.spi.MetaData;
 import org.jboss.metadata.spi.repository.MutableMetaDataRepository;
+import org.jboss.metadata.spi.retrieval.MetaDataRetrieval;
+import org.jboss.metadata.spi.scope.ScopeKey;
 
 /**
  * KernelMetaDataRepository.
@@ -38,4 +42,52 @@
     * @return the meta data repository
     */
    MutableMetaDataRepository getMetaDataRepository();
+
+   /**
+    * Get MetaData
+    * 
+    * @param context the context
+    * @return the metadata
+    */
+   MetaData getMetaData(KernelControllerContext context);
+
+   /**
+    * Get the MetaData retrieval
+    * 
+    * @param context the context
+    * @return the metadata retrieval
+    */
+   MetaDataRetrieval getMetaDataRetrieval(KernelControllerContext context);
+   
+   /**
+    * Add metadata to the bean.
+    * 
+    * @param context the context
+    * @param beanMetaData the bean metadata
+    * @param beanInfo the bean info
+    */
+   void addMetaData(KernelControllerContext context);
+
+   /**
+    * Remove any previously added metadata
+    * 
+    * @param context the context
+    */
+   void removeMetaData(KernelControllerContext context);
+
+   /**
+    * Get the default scope for a context
+    * 
+    * @param context the context
+    * @return the default scope
+    */
+   ScopeKey getFullScope(KernelControllerContext context);
+   
+   /**
+    * Get the mutable scope for a context
+    * 
+    * @param context the context
+    * @return the default scope
+    */
+   ScopeKey getMutableScope(KernelControllerContext context);
 }

Deleted: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/MutableMetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/MutableMetaDataContext.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/metadata/MutableMetaDataContext.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -1,43 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.kernel.spi.metadata;
-
-import java.util.Set;
-
-import org.jboss.beans.info.spi.PropertyInfo;
-import org.jboss.beans.metadata.spi.AnnotationMetaData;
-import org.jboss.repository.spi.MetaDataContext;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public interface MutableMetaDataContext extends MetaDataContext
-{
-   public abstract void addAnnotations(Set<AnnotationMetaData> annotations);
-
-   public abstract void addPropertyAnnotations(String propertyName, Set<PropertyInfo> propertyInfos, Set<AnnotationMetaData> annotations);
-
-   public abstract void setTarget(Object tgt);
-
-}

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -26,6 +26,7 @@
 import org.jboss.dependency.spi.ControllerState;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
 import org.jboss.kernel.spi.deployment.KernelDeployment;
+import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
 import org.jboss.test.AbstractTestCaseWithSetup;
 import org.jboss.test.AbstractTestDelegate;
 
@@ -176,6 +177,17 @@
    {
       getMCDelegate().validate();
    }
+   
+   /**
+    * Get the metadata repository
+    * 
+    * @return the metadata repository
+    * @throws IllegalStateException when the bean does not exist at that state
+    */
+   protected KernelMetaDataRepository getMetaDataRepository()
+   {
+      return getMCDelegate().getMetaDataRepository();
+   }
 
    /**
     * Get the delegate

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -31,6 +31,7 @@
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
 import org.jboss.kernel.spi.deployment.KernelDeployment;
+import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
 import org.jboss.test.AbstractTestDelegate;
 
 /**
@@ -125,6 +126,16 @@
    }
    
    /**
+    * Get the metadata repository
+    * @return the metadata repository
+    * @throws IllegalStateException when the bean does not exist at that state
+    */
+   protected KernelMetaDataRepository getMetaDataRepository()
+   {
+      return kernel.getMetaDataRepository();
+   }
+   
+   /**
     * Get a context
     *
     * @param name the name of the bean

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_New.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_New.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_New.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+   <bean name="Name1" class="org.jboss.test.kernel.metadata.support.TestClassAnnotation">
+      <annotation>@org.jboss.test.kernel.metadata.support.TestAnnotationC</annotation>
+   </bean>
+</deployment>

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NewProperty.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NewProperty.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NewProperty.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+   <bean name="Name1" class="org.jboss.test.kernel.metadata.support.TestClassAnnotation">
+      <property name="something">Hello
+         <annotation>@org.jboss.test.kernel.metadata.support.TestAnnotationC</annotation>
+      </property>
+   </bean>
+</deployment>

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverride.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverride.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverride.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,6 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+   <bean name="Name1" class="org.jboss.test.kernel.metadata.support.TestClassAnnotation">
+   </bean>
+</deployment>

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverrideProperty.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverrideProperty.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_NoOverrideProperty.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+   <bean name="Name1" class="org.jboss.test.kernel.metadata.support.TestClassAnnotation">
+      <property name="something">Hello</property>
+   </bean>
+</deployment>

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_Override.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_Override.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_Override.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+   <bean name="Name1" class="org.jboss.test.kernel.metadata.support.TestClassAnnotation">
+      <annotation>@org.jboss.test.kernel.metadata.support.TestAnnotationA(&quot;Overridden&quot;)</annotation>
+   </bean>
+</deployment>

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_OverrideProperty.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_OverrideProperty.xml	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase_OverrideProperty.xml	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+   <bean name="Name1" class="org.jboss.test.kernel.metadata.support.TestClassAnnotation">
+      <property name="something">Hello
+         <annotation>@org.jboss.test.kernel.metadata.support.TestAnnotationA(&quot;Overridden&quot;)</annotation>
+      </property>
+   </bean>
+</deployment>

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/ioc/test/AbstractIoCTest.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -46,6 +46,7 @@
    /**
     * Unmarshal some xml
     *
+    * @param <T> the expected type
     * @param name the name
     * @param expected the expected type
     * @return the unmarshalled object

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/KernelTestSuite.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/KernelTestSuite.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/KernelTestSuite.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -34,6 +34,7 @@
 import org.jboss.test.kernel.event.test.EventTestSuite;
 import org.jboss.test.kernel.registry.test.RegistryTestSuite;
 import org.jboss.test.kernel.inject.test.ContextualInjectionTestSuite;
+import org.jboss.test.kernel.metadata.test.MetaDataTestSuite;
 
 /**
  * Kernel Test Suite.
@@ -61,6 +62,7 @@
       suite.addTest(DeploymentTestSuite.suite());
       suite.addTest(ContextualInjectionTestSuite.suite());
       suite.addTest(XMLTestSuite.suite());
+      suite.addTest(MetaDataTestSuite.suite());
 
       return suite;
    }

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomCollection.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomCollection.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomCollection.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -29,7 +29,7 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class CustomCollection extends ArrayList
+public class CustomCollection extends ArrayList<String>
 {
    /** The serialVersionUID */
    private static final long serialVersionUID = 3762538897183683896L;

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomList.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomList.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomList.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -29,7 +29,7 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class CustomList extends ArrayList
+public class CustomList extends ArrayList<String>
 {
    /** The serialVersionUID */
    private static final long serialVersionUID = 3762538897183683896L;

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomMap.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomMap.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomMap.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -29,7 +29,7 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class CustomMap extends HashMap
+public class CustomMap extends HashMap<String, String>
 {
    /** The serialVersionUID */
    private static final long serialVersionUID = 3762538897183683896L;

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomSet.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomSet.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/support/CustomSet.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -29,7 +29,7 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
-public class CustomSet extends HashSet
+public class CustomSet extends HashSet<String>
 {
    /** The serialVersionUID */
    private static final long serialVersionUID = 3762538897183683896L;

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationA.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationA.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationA.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.support;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+ * TestAnnotation.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface TestAnnotationA
+{
+   String value();
+}

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationB.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationB.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationB.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.support;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+ * TestOverrideAnnotation.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface TestAnnotationB
+{
+   String value();
+}

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationC.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationC.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestAnnotationC.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.support;
+
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
+/**
+ * TestAnnotation.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface TestAnnotationC
+{
+}

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestClassAnnotation.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestClassAnnotation.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/support/TestClassAnnotation.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,53 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.support;
+
+import org.jboss.test.kernel.metadata.test.AbstractMetaDataTest;
+
+/**
+ * TestClassAnnotation.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+ at TestAnnotationA("NotOverridden")
+ at TestAnnotationB("NotOverridden")
+public class TestClassAnnotation
+{
+   public TestClassAnnotation()
+   {
+      AbstractMetaDataTest.peekMetaData();
+   }
+   
+   @TestAnnotationA("NotOverridden")
+   @TestAnnotationB("NotOverridden")
+   public String getSomething()
+   {
+      return null;
+   }
+   
+   @TestAnnotationA("NotOverridden")
+   @TestAnnotationB("NotOverridden")
+   public void setSomething(String p1)
+   {
+   }
+}

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/AbstractMetaDataTest.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/AbstractMetaDataTest.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/AbstractMetaDataTest.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,116 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.test;
+
+import java.lang.annotation.Annotation;
+
+import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.repository.MetaDataRepository;
+import org.jboss.metadata.spi.scope.CommonLevels;
+import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.stack.MetaDataStack;
+import org.jboss.test.AbstractTestDelegate;
+import org.jboss.test.kernel.junit.MicrocontainerTest;
+
+/**
+ * MetaData Test Case.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 40428 $
+ */
+public class AbstractMetaDataTest extends MicrocontainerTest
+{
+   public AbstractMetaDataTest(String name) throws Throwable
+   {
+      super(name);
+   }
+   
+   private static MetaData peekedMetaData;
+
+   public static void peekMetaData()
+   {
+      peekedMetaData = MetaDataStack.peek();
+   }
+   
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+      peekedMetaData = null;
+   }
+
+   protected MetaData assertPeekedMetaData()
+   {
+      assertNotNull(peekedMetaData);
+      return peekedMetaData;
+   }
+   
+   protected ScopeKey assertRetrievals(String name)
+   {
+      KernelControllerContext context = getControllerContext(name);
+      MetaDataRepository repository = getMetaDataRepository().getMetaDataRepository();
+      ScopeKey result = context.getScope();
+      assertNotNull(repository.getMetaDataRetrieval(result));
+      assertNotNull(repository.getMetaDataRetrieval(new ScopeKey(CommonLevels.INSTANCE, name)));
+      return result;
+   }
+   
+   protected void assertNoRetrievals(String name, ScopeKey scope)
+   {
+      MetaDataRepository repository = getMetaDataRepository().getMetaDataRepository();
+      assertNull(repository.getMetaDataRetrieval(scope));
+      assertNull(repository.getMetaDataRetrieval(new ScopeKey(CommonLevels.INSTANCE, name)));
+   }
+   
+   protected <T extends Annotation> T assertAnnotation(MetaData metaData, Class<T> annotationClass)
+   {
+      T result = metaData.getAnnotation(annotationClass);
+      assertNotNull(result);
+      return  result;
+   }
+   
+   protected <T extends Annotation> void assertNoAnnotation(MetaData metaData, Class<T> annotationClass)
+   {
+      T result = metaData.getAnnotation(annotationClass);
+      assertNull(result);
+   }
+   
+   /**
+    * Default setup with security manager enabled
+    * 
+    * @param clazz the class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      AbstractTestDelegate delegate = MicrocontainerTest.getDelegate(clazz);
+      //delegate.enableSecurity = true;
+      return delegate;
+   }
+
+   protected void configureLogging()
+   {
+      //enableTrace("org.jboss.dependency");
+      //enableTrace("org.jboss.kernel.plugins.dependency");
+   }
+}
\ No newline at end of file

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/ClassAnnotationTestCase.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,204 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.test;
+
+import org.jboss.kernel.spi.deployment.KernelDeployment;
+import org.jboss.metadata.spi.MetaData;
+import org.jboss.metadata.spi.scope.ScopeKey;
+import org.jboss.metadata.spi.signature.MethodSignature;
+import org.jboss.test.kernel.metadata.support.TestAnnotationA;
+import org.jboss.test.kernel.metadata.support.TestAnnotationB;
+import org.jboss.test.kernel.metadata.support.TestAnnotationC;
+
+import junit.framework.Test;
+
+/**
+ * ClassAnnotationTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassAnnotationTestCase extends AbstractMetaDataTest
+{
+   public static Test suite()
+   {
+      return suite(ClassAnnotationTestCase.class);
+   }
+
+   public ClassAnnotationTestCase(String name) throws Throwable
+   {
+      super(name);
+   }
+
+   public void testClassAnnotationNoOverride() throws Throwable
+   {
+      ScopeKey scope = null;
+      KernelDeployment deployment = deploy("ClassAnnotationTestCase_NoOverride.xml");
+      try
+      {
+         scope = assertRetrievals("Name1");
+         MetaData metaData = assertPeekedMetaData();
+         TestAnnotationA a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("NotOverridden", a.value());
+         TestAnnotationB b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertNoAnnotation(metaData, TestAnnotationC.class);
+      }
+      finally
+      {
+         undeploy(deployment);
+         if (scope != null)
+            assertNoRetrievals("Name1", scope);
+      }
+   }
+
+   public void testClassAnnotationOverride() throws Throwable
+   {
+      ScopeKey scope = null;
+      KernelDeployment deployment = deploy("ClassAnnotationTestCase_Override.xml");
+      try
+      {
+         scope = assertRetrievals("Name1");
+         MetaData metaData = assertPeekedMetaData();
+         TestAnnotationA a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("Overridden", a.value());
+         TestAnnotationB b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertNoAnnotation(metaData, TestAnnotationC.class);
+      }
+      finally
+      {
+         undeploy(deployment);
+         if (scope != null)
+            assertNoRetrievals("Name1", scope);
+      }
+   }
+
+   public void testClassAnnotationNew() throws Throwable
+   {
+      ScopeKey scope = null;
+      KernelDeployment deployment = deploy("ClassAnnotationTestCase_New.xml");
+      try
+      {
+         scope = assertRetrievals("Name1");
+         MetaData metaData = assertPeekedMetaData();
+         TestAnnotationA a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("NotOverridden", a.value());
+         TestAnnotationB b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertAnnotation(metaData, TestAnnotationC.class);
+      }
+      finally
+      {
+         undeploy(deployment);
+         if (scope != null)
+            assertNoRetrievals("Name1", scope);
+      }
+   }
+
+   public void testPropertyAnnotationNoOverride() throws Throwable
+   {
+      ScopeKey scope = null;
+      KernelDeployment deployment = deploy("ClassAnnotationTestCase_NoOverrideProperty.xml");
+      try
+      {
+         scope = assertRetrievals("Name1");
+         MetaData classMetaData = assertPeekedMetaData();
+         MetaData metaData = classMetaData.getComponentMetaData(new MethodSignature("getSomething"));
+         TestAnnotationA a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("NotOverridden", a.value());
+         TestAnnotationB b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertNoAnnotation(metaData, TestAnnotationC.class);
+         metaData = classMetaData.getComponentMetaData(new MethodSignature("setSomething", String.class));
+         a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("NotOverridden", a.value());
+         b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertNoAnnotation(metaData, TestAnnotationC.class);
+      }
+      finally
+      {
+         undeploy(deployment);
+         if (scope != null)
+            assertNoRetrievals("Name1", scope);
+      }
+   }
+
+   public void testPropertyAnnotationOverride() throws Throwable
+   {
+      ScopeKey scope = null;
+      KernelDeployment deployment = deploy("ClassAnnotationTestCase_OverrideProperty.xml");
+      try
+      {
+         scope = assertRetrievals("Name1");
+         MetaData classMetaData = assertPeekedMetaData();
+         MetaData metaData = classMetaData.getComponentMetaData(new MethodSignature("getSomething"));
+         TestAnnotationA a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("Overridden", a.value());
+         TestAnnotationB b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertNoAnnotation(metaData, TestAnnotationC.class);
+         metaData = classMetaData.getComponentMetaData(new MethodSignature("setSomething", String.class));
+         a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("Overridden", a.value());
+         b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertNoAnnotation(metaData, TestAnnotationC.class);
+      }
+      finally
+      {
+         undeploy(deployment);
+         if (scope != null)
+            assertNoRetrievals("Name1", scope);
+      }
+   }
+
+   public void testPropertyAnnotationNew() throws Throwable
+   {
+      ScopeKey scope = null;
+      KernelDeployment deployment = deploy("ClassAnnotationTestCase_NewProperty.xml");
+      try
+      {
+         scope = assertRetrievals("Name1");
+         MetaData classMetaData = assertPeekedMetaData();
+         MetaData metaData = classMetaData.getComponentMetaData(new MethodSignature("getSomething"));
+         TestAnnotationA a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("NotOverridden", a.value());
+         TestAnnotationB b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertAnnotation(metaData, TestAnnotationC.class);
+         metaData = classMetaData.getComponentMetaData(new MethodSignature("setSomething", String.class));
+         a = assertAnnotation(metaData, TestAnnotationA.class);
+         assertEquals("NotOverridden", a.value());
+         b = assertAnnotation(metaData, TestAnnotationB.class);
+         assertEquals("NotOverridden", b.value());
+         assertAnnotation(metaData, TestAnnotationC.class);
+      }
+      finally
+      {
+         undeploy(deployment);
+         if (scope != null)
+            assertNoRetrievals("Name1", scope);
+      }
+   }
+}
\ No newline at end of file

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/MetaDataTestSuite.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/MetaDataTestSuite.java	2006-12-13 23:45:58 UTC (rev 59019)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/metadata/test/MetaDataTestSuite.java	2006-12-13 23:51:15 UTC (rev 59020)
@@ -0,0 +1,49 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.metadata.test;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * MetaData Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 55945 $
+ */
+public class MetaDataTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("MetaData Tests");
+
+      suite.addTest(ClassAnnotationTestCase.suite());
+      
+      return suite;
+   }
+}



From genman at noderunner.net  Wed Dec 13 18:57:38 2006
From: genman at noderunner.net (Elias Ross)
Date: Wed, 13 Dec 2006 18:57:38 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/memory  ...
Message-ID: <E1Gudyk-00037n-9S@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/13 18:57:38

  Modified:    src-50/org/jboss/cache/pojo/memory  PersistentReference.java
  Log:
  use Commons Logging not Log4j
  
  Revision  Changes    Path
  1.3       +3 -2      JBossCache/src-50/org/jboss/cache/pojo/memory/PersistentReference.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PersistentReference.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/memory/PersistentReference.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PersistentReference.java	27 Jun 2006 05:25:43 -0000	1.2
  +++ PersistentReference.java	13 Dec 2006 23:57:38 -0000	1.3
  @@ -22,7 +22,8 @@
   
   package org.jboss.cache.pojo.memory;
   
  -import org.apache.log4j.Logger;
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   import org.jboss.serial.classmetamodel.ClassMetaData;
   
   import java.lang.ref.Reference;
  @@ -41,7 +42,7 @@
      static final int REFERENCE_WEAK = 1;
      public static final int REFERENCE_SOFT = 2;
   
  -   private static final Logger log = Logger.getLogger(ClassMetaData.class);
  +   private static final Log log = LogFactory.getLog(ClassMetaData.class);
      private static final boolean isDebug = log.isDebugEnabled();
   
      private WeakReference classReference;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:00:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:00:27 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59021 - trunk/tomcat/src/resources
Message-ID: <E1Gue1T-0003A6-0e@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-13 19:00:24 -0500 (Wed, 13 Dec 2006)
New Revision: 59021

Modified:
   trunk/tomcat/src/resources/war-deployers-beans.xml
Log:
Add a deploymentClass property to control the deployment wrapper

Modified: trunk/tomcat/src/resources/war-deployers-beans.xml
===================================================================
--- trunk/tomcat/src/resources/war-deployers-beans.xml	2006-12-13 23:51:15 UTC (rev 59020)
+++ trunk/tomcat/src/resources/war-deployers-beans.xml	2006-12-14 00:00:24 UTC (rev 59021)
@@ -148,6 +148,9 @@
       -->
       <property name="managerClass">org.jboss.web.tomcat.tc6.session.JBossCacheManager</property>
 
+      <!-- The class used as the deployment wrapper -->
+      <property name="deploymentClass">org.jboss.web.tomcat.tc6.deployers.TomcatDeployment</property>
+
       <!-- The name of the request property under with the authenticated JAAS
       Subject is stored on successful authentication. If null or empty then
       the Subject will not be stored.



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:01:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:01:52 -0500
Subject: [jboss-cvs] JBossAS SVN: r59022 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1Gue2q-0003CE-Qr@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-13 19:01:50 -0500 (Wed, 13 Dec 2006)
New Revision: 59022

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java
Log:
Add a deploymentClass property to control the deployment wrapper

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java	2006-12-14 00:00:24 UTC (rev 59021)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java	2006-12-14 00:01:50 UTC (rev 59022)
@@ -51,7 +51,6 @@
 import org.jboss.web.deployers.AbstractWarDeployer;
 import org.jboss.web.deployers.AbstractWarDeployment;
 import org.jboss.web.tomcat.security.HttpServletRequestPolicyContextHandler;
-import org.jboss.web.tomcat.tc6.TomcatInjectionContainer;
 import org.jboss.web.tomcat.tc6.session.SessionIDGenerator;
 
 
@@ -165,8 +164,10 @@
    private boolean allowSelfPrivilegedWebApps = false;
 
    /** The service used to flush authentication cache on session invalidation. */
-   private JaasSecurityManagerServiceMBean secMgrService;  
-   
+   private JaasSecurityManagerServiceMBean secMgrService;
+   /** The AbstractWarDeployment implementation class */
+   private Class deploymentClass = TomcatDeployment.class;
+
    /** */
    private String[] filteredPackages;
 
@@ -407,6 +408,15 @@
       this.filteredPackages = pkgs;
    }
 
+   public Class getDeploymentClass()
+   {
+      return deploymentClass;
+   }
+   public void setDeploymentClass(Class deploymentClass)
+   {
+      this.deploymentClass = deploymentClass;
+   }
+
    /**
     * Start the deployer. This sets up the tomcat core.
     */
@@ -722,7 +732,8 @@
    public AbstractWarDeployment getDeployment(DeploymentUnit unit, WebMetaData metaData)
       throws Exception
    {
-      TomcatDeployment2 deployment = new TomcatDeployment2();
+      AbstractWarDeployment deployment = (AbstractWarDeployment) deploymentClass.newInstance();
+      
       DeployerConfig config = new DeployerConfig();
       config.setDefaultSecurityDomain(this.defaultSecurityDomain);
       config.setSubjectAttributeName(this.subjectAttributeName);



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:02:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:02:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r59023 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1Gue3H-0003NM-IL@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-13 19:02:16 -0500 (Wed, 13 Dec 2006)
New Revision: 59023

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java
Log:
Ensure WEB-INF/classes is in the web loader path if it exists

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java	2006-12-14 00:01:50 UTC (rev 59022)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment.java	2006-12-14 00:02:16 UTC (rev 59023)
@@ -491,6 +491,25 @@
        * paths to the deployment UCL.
        */
       ArrayList<URL> classpath = (ArrayList<URL>) unit.getAttachment("org.jboss.web.expandedWarClasspath");
+      if( classpath == null )
+      {
+         try
+         {
+            VirtualFile classes = unit.getFile("WEB-INF/classes");
+            // Tomcat can't handle the vfs urls yet
+            URL vfsURL = classes.toURL();
+            String vfsurl = vfsURL.toString();
+            if( vfsurl.startsWith("vfs") )
+               vfsURL = new URL(vfsurl.substring(3));
+            classpath = new ArrayList<URL>();
+            classpath.add(classes.toURL());
+         }
+         catch(Exception e)
+         {
+            
+         }
+      }
+
       if (config.isUseJBossWebLoader())
       {
          WebCtxLoader jbossLoader = new WebCtxLoader(loader, injectionContainer);

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java	2006-12-14 00:01:50 UTC (rev 59022)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java	2006-12-14 00:02:16 UTC (rev 59023)
@@ -485,6 +485,25 @@
        * paths to the deployment UCL.
        */
       ArrayList<URL> classpath = (ArrayList<URL>) unit.getAttachment("org.jboss.web.expandedWarClasspath");
+      if( classpath == null )
+      {
+         try
+         {
+            VirtualFile classes = unit.getFile("WEB-INF/classes");
+            // Tomcat can't handle the vfs urls yet
+            URL vfsURL = classes.toURL();
+            String vfsurl = vfsURL.toString();
+            if( vfsurl.startsWith("vfs") )
+               vfsURL = new URL(vfsurl.substring(3));
+            classpath = new ArrayList<URL>();
+            classpath.add(classes.toURL());
+         }
+         catch(Exception e)
+         {
+            
+         }
+      }
+
       if (config.isUseJBossWebLoader())
       {
          WebCtxLoader jbossLoader = new WebCtxLoader(loader, injectionContainer);



From genman at noderunner.net  Wed Dec 13 19:04:00 2006
From: genman at noderunner.net (Elias Ross)
Date: Wed, 13 Dec 2006 19:04:00 -0500
Subject: [jboss-cvs] JBossCache/docs/tutorial-pojo/en/images    ...
Message-ID: <E1Gue4u-0003Nz-HX@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/13 19:04:00

  Removed:     docs/tutorial-pojo/en/images    demoAddress.PNG
                        demoAddressInternal.PNG demoJoe.PNG
  Log:
  fix PNG -> png


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:13:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:13:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r59024 -
	projects/microcontainer/trunk/container/src/main/org/jboss
Message-ID: <E1GueDx-0003Yt-S4@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-13 19:13:20 -0500 (Wed, 13 Dec 2006)
New Revision: 59024

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/
Log:
[JBMICROCONT-75] - AOP/MC MetaData integration



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:13:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:13:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r59025 -
	projects/microcontainer/trunk/container/src/main/org/jboss/repository
Message-ID: <E1GueE1-0003ZC-4u@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-13 19:13:23 -0500 (Wed, 13 Dec 2006)
New Revision: 59025

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/
Log:
[JBMICROCONT-75] - AOP/MC MetaData integration



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:15:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:15:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59026 -
	projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi
Message-ID: <E1GueGA-0003bH-Dc@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-13 19:15:36 -0500 (Wed, 13 Dec 2006)
New Revision: 59026

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java
Log:
I really hate this buggy SVN client!

Added: projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java	2006-12-14 00:13:23 UTC (rev 59025)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java	2006-12-14 00:15:36 UTC (rev 59026)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.repository.spi;
+
+import java.lang.annotation.Annotation;
+import java.util.List;
+
+import org.jboss.metadata.spi.repository.MetaDataRepository;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 58766 $
+ */
+public interface MetaDataContext
+{
+
+   public abstract <T extends Annotation> boolean hasAnnotation(Class<T> ann);
+
+   public abstract <T extends Annotation> Annotation getAnnotation(Class<T> ann);
+
+   public abstract <T extends Annotation> boolean hasAnnotationForMethod(long methodHash, Class<T> ann);
+
+   public abstract <T extends Annotation> Annotation getAnnotationForMethod(long methodHash, Class<T> ann);
+
+   public abstract List<Annotation> getAnnotations();
+
+   public abstract List<Annotation> getAnnotationsForMethod(long methodHash);
+
+   public abstract List<Annotation> getAnnotationsForMethods(long[] methodHashes);
+
+   public abstract MetaDataRepository getRepository();
+
+}
\ No newline at end of file



From genman at noderunner.net  Wed Dec 13 19:25:08 2006
From: genman at noderunner.net (Elias Ross)
Date: Wed, 13 Dec 2006 19:25:08 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GuePM-0003lY-3j@committer01.frg.pub.inap.atl.jboss.com>

  User: genman  
  Date: 06/12/13 19:25:08

  Modified:    JBossCache  .classpath
  Log:
  Fix the Eclipse classpath
  
  Revision  Changes    Path
  1.13      +41 -39    JBossCache/.classpath
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: .classpath
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/.classpath,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- .classpath	25 Oct 2006 04:56:38 -0000	1.12
  +++ .classpath	14 Dec 2006 00:25:08 -0000	1.13
  @@ -1,11 +1,14 @@
   <?xml version="1.0" encoding="UTF-8"?>
   <classpath>
   	<classpathentry kind="src" path="src"/>
  +	<classpathentry kind="src" path="etc"/>
  +	<classpathentry kind="src" path="src-50"/>
   	<classpathentry kind="src" path="tests/functional"/>
   	<classpathentry kind="src" path="tests/perf"/>
   	<classpathentry kind="src" path="tests/stress"/>
   	<classpathentry kind="src" path="tests/interop"/>
   	<classpathentry kind="src" path="tests-50/functional"/>
  +	<classpathentry kind="src" path="tests-50/perf"/>
   	<classpathentry kind="lib" path="ant-dist/lib/ant.jar"/>
   	<classpathentry kind="lib" path="ant-dist/lib/ant-junit.jar"/>
   	<classpathentry kind="lib" path="ant-dist/lib/ant-launcher.jar"/>
  @@ -27,13 +30,12 @@
   	<classpathentry kind="lib" path="lib/jdbm-1.0.jar"/>
   	<classpathentry kind="lib" path="lib/jgroups.jar"/>
   	<classpathentry kind="lib" path="lib/junit.jar"/>
  -	<classpathentry kind="lib" path="lib/log4j-1.2.13.jar"/>
   	<classpathentry kind="lib" path="lib/qdox.jar"/>
   	<classpathentry kind="lib" path="lib/berkeleydb/je.jar"/>
   	<classpathentry kind="lib" path="lib/trove.jar"/>
  -	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
  -	<classpathentry kind="src" path="etc"/>
  +	<classpathentry kind="lib" path="lib/retro/jboss-backport-concurrent.jar"/>
   	<classpathentry kind="lib" path="lib/jboss-serialization.jar"/>
  -	<classpathentry kind="src" path="src-50"/>
  +	<classpathentry kind="lib" path="lib/log4j-1.2.14.jar"/>
  +    <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
   	<classpathentry kind="output" path="bin"/>
   </classpath>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 19:44:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 19:44:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r59027 -
	trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers
Message-ID: <E1GueiT-00044O-1V@committer01.frg.pub.inap.atl.jboss.com>

Author: remy.maucherat at jboss.com
Date: 2006-12-13 19:44:50 -0500 (Wed, 13 Dec 2006)
New Revision: 59027

Modified:
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/DeployerConfig.java
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java
Log:
- Use a shared WebMetaData object for parsing the shared web.xml configuration.

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/DeployerConfig.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/DeployerConfig.java	2006-12-14 00:15:36 UTC (rev 59026)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/DeployerConfig.java	2006-12-14 00:44:50 UTC (rev 59027)
@@ -25,6 +25,7 @@
 
 import javax.management.ObjectName;
  
+import org.jboss.metadata.WebMetaData;
 import org.jboss.security.plugins.JaasSecurityManagerServiceMBean;
 
 /**
@@ -123,6 +124,11 @@
    private String[] filteredPackages;
 
    /**
+    * Shared WebMetaData.
+    */
+   private WebMetaData sharedMetaData = null;
+   
+   /**
     * Flag indicating whether web-app specific context xmls may set the privileged flag.
     */
    private boolean allowSelfPrivilegedWebApps = false;
@@ -362,5 +368,15 @@
    public void setXacmlPolicyURL(URL xacmlPolicyURL) 
    {
 	 this.xacmlPolicyURL = xacmlPolicyURL;
+   }
+
+   public WebMetaData getSharedMetaData()
+   {
+      return sharedMetaData;
+   }
+
+   public void setSharedMetaData(WebMetaData sharedMetaData)
+   {
+      this.sharedMetaData = sharedMetaData;
    }   
 }

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-14 00:15:36 UTC (rev 59026)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/JBossContextConfig.java	2006-12-14 00:44:50 UTC (rev 59027)
@@ -46,17 +46,28 @@
 public class JBossContextConfig extends ContextConfig {
 
 	public static ThreadLocal<WebMetaData> metaDataLocal = new ThreadLocal<WebMetaData>();
+   public static ThreadLocal<WebMetaData> metaDataShared = new ThreadLocal<WebMetaData>();
 
     @Override
 	protected void applicationWebConfig() {
-    	
+      processWebMetaData(metaDataLocal.get());
+   }
+    
+    
+   @Override
+   protected void defaultWebConfig()
+   {
+      processWebMetaData(metaDataShared.get());
+   }
+
+
+   protected void processWebMetaData(WebMetaData metaData) {   
+   
       if (context instanceof StandardContext) {
          ((StandardContext) context).setReplaceWelcomeFiles(true);
       }
 
-      WebMetaData metaData = metaDataLocal.get();
-    	
-    	// Metadata complete
+      // Metadata complete
       context.setIgnoreAnnotations(metaData.isMetadataComplete());
     	
     	// Context params

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java	2006-12-14 00:15:36 UTC (rev 59026)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployer.java	2006-12-14 00:44:50 UTC (rev 59027)
@@ -43,6 +43,7 @@
 import org.apache.tomcat.util.modeler.Registry;
 import org.jboss.deployers.spi.deployer.DeploymentUnit;
 import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.web.WebMetaDataObjectFactory;
 import org.jboss.mx.util.MBeanServerLocator;
 import org.jboss.security.plugins.JaasSecurityManagerServiceMBean;
 import org.jboss.system.server.Server;
@@ -52,6 +53,8 @@
 import org.jboss.web.deployers.AbstractWarDeployment;
 import org.jboss.web.tomcat.security.HttpServletRequestPolicyContextHandler;
 import org.jboss.web.tomcat.tc6.session.SessionIDGenerator;
+import org.jboss.xb.binding.Unmarshaller;
+import org.jboss.xb.binding.UnmarshallerFactory;
 
 
 /**
@@ -86,6 +89,11 @@
       "org.apache.catalina.core.StandardContext";
 
    /**
+    * Unmarshall factory used for parsing shared web.xml.
+    */
+   private static final UnmarshallerFactory factory = UnmarshallerFactory.newInstance();
+   
+   /**
     * Configurable map of tomcat authenticators
     * Keyed in by the http auth method that gets 
     * plugged into the Context Config and then into the StandardContext 
@@ -146,6 +154,11 @@
     */
    private String httpHeaderForSSOAuth = null;
    private String sessionCookieForSSOAuth = null;
+   
+   /**
+    * Shared metaData.
+    */
+   private WebMetaData sharedMetaData = null;
 
 
    /**
@@ -529,6 +542,15 @@
       PolicyContext.registerHandler(HttpServletRequestPolicyContextHandler.WEB_REQUEST_KEY,
          handler, true);
 
+      // Parse shared web.xml
+      Unmarshaller unmarshaller = factory.newUnmarshaller();
+      URL webXml = this.getClass().getClassLoader().getResource("web.xml");
+      if (webXml == null) {
+         webXml = this.getClass().getClassLoader().getResource("conf/web.xml");;
+      }
+      sharedMetaData = (WebMetaData)
+         unmarshaller.unmarshal(webXml.toString(), new WebMetaDataObjectFactory(), null);
+      
       // If we are hot-deployed *after* the overall server is started
       // we'll never receive Server.START_NOTIFICATION_TYPE, so check
       // with the Server and start the connectors immediately, if this is the case.
@@ -754,6 +776,7 @@
       config.setAllowSelfPrivilegedWebApps(this.allowSelfPrivilegedWebApps); 
       config.setSecurityManagerService(this.secMgrService);
       config.setFilteredPackages(filteredPackages);
+      config.setSharedMetaData(sharedMetaData);
       
       //Check if there are any xacml policy files
       VirtualFile vf = unit.getMetaDataFile("jboss-xacml-policy.xml");

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java	2006-12-14 00:15:36 UTC (rev 59026)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/deployers/TomcatDeployment2.java	2006-12-14 00:44:50 UTC (rev 59027)
@@ -292,6 +292,7 @@
       // Pass the metadata to the RunAsListener via a thread local
       RunAsListener.metaDataLocal.set(metaData);
       JBossContextConfig.metaDataLocal.set(metaData);
+      JBossContextConfig.metaDataShared.set(config.getSharedMetaData());
       try
       {
           // Init the container; this will also start it
@@ -311,6 +312,7 @@
       {
          RunAsListener.metaDataLocal.set(null);
          JBossContextConfig.metaDataLocal.set(null);
+         JBossContextConfig.metaDataShared.set(null);
       }
 
       if (injectionContainer == null)



From ron_sigal at yahoo.com  Wed Dec 13 19:58:39 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 19:58:39 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1Guevn-0004KI-RS@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 19:58:39

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x Client.java
  Log:
  JBREM-650: (1) Create copy of configuration map in constructors, and (2) pass configuration to callback Connector.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.53.2.11 +3 -3      JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.53.2.10
  retrieving revision 1.53.2.11
  diff -u -b -r1.53.2.10 -r1.53.2.11
  --- Client.java	12 Dec 2006 04:55:30 -0000	1.53.2.10
  +++ Client.java	14 Dec 2006 00:58:39 -0000	1.53.2.11
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.53.2.10 $
  + * @version $Revision: 1.53.2.11 $
    */
   public class Client implements Externalizable
   {
  @@ -261,7 +261,7 @@
         this.locator = locator;
         this.subsystem = subsystem == null ? null : subsystem.toUpperCase();
         if (configuration != null)
  -         this.configuration = configuration;
  +         this.configuration = new HashMap(configuration);
         this.sessionId = new GUID().toString();
      }
   
  @@ -987,7 +987,7 @@
                  {
                     callbackLocator = new InvokerLocator(transport, host, port, null, metadata);
                  }
  -               Connector callbackServerConnector = new Connector(callbackLocator);
  +               Connector callbackServerConnector = new Connector(callbackLocator, configuration);
                  callbackConnectors.put(callbackhandler, callbackServerConnector);
                  callbackServerConnector.start();
                  // have to use the locator from the server as can be modified internally
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:00:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:00:09 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1GuexF-0004LY-47@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:00:09

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        ServerInvoker.java
  Log:
  JBREM-650:  Made handleInternalInvocation() protected.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.52.2.5  +12 -3     JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java,v
  retrieving revision 1.52.2.4
  retrieving revision 1.52.2.5
  diff -u -b -r1.52.2.4 -r1.52.2.5
  --- ServerInvoker.java	9 Nov 2006 20:33:58 -0000	1.52.2.4
  +++ ServerInvoker.java	14 Dec 2006 01:00:09 -0000	1.52.2.5
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.52.2.4 $
  + * @version $Revision: 1.52.2.5 $
    */
   public abstract class ServerInvoker extends AbstractInvoker implements ServerInvokerMBean
   {
  @@ -1025,6 +1025,13 @@
         }
         else
         {
  +         log.error(this + ": not started");
  +         log.error("request: " + invocation.getParameter());
  +         if (invocation.getParameter() instanceof InternalInvocation)
  +         {
  +            InternalInvocation ii = (InternalInvocation) invocation.getParameter();
  +            log.error("internal invocation: " + ii.getMethodName());
  +         }
            throw new InvalidStateException("Can not process invocation request since is not in started state.");
         }
      }
  @@ -1155,7 +1162,7 @@
       * @return
       * @throws Throwable
       */
  -   private Object handleInternalInvocation(InternalInvocation param,
  +   protected Object handleInternalInvocation(InternalInvocation param,
                                              InvocationRequest invocation,
                                              ServerInvocationHandler handler)
            throws Throwable
  @@ -1405,7 +1412,7 @@
      public void start() throws IOException
      {
         started = true;
  -      log.debug("Invoker started for locator: " + getLocator());
  +      log.debug(this + ": Invoker started for locator: " + getLocator());
      }
   
      /**
  @@ -1423,6 +1430,7 @@
       */
      public void stop()
      {
  +      log.info(this + ": stopping");
         started = false;
   
         Iterator it = callbackHandlers.values().iterator();
  @@ -1431,6 +1439,7 @@
            ServerInvokerCallbackHandler callbackHandler = (ServerInvokerCallbackHandler) it.next();
            callbackHandler.destroy();
         }
  +      log.info(this + ": stopped");
      }
   
      /**
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:02:16 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:02:16 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/callback  ...
Message-ID: <E1GuezI-0004aO-7g@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:02:16

  Modified:    src/main/org/jboss/remoting/callback  Tag: remoting_2_x
                        ServerInvokerCallbackHandler.java
  Log:
  JBREM-650: In init() pass metadata to callback Client.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.15.2.5  +1 -0      JBossRemoting/src/main/org/jboss/remoting/callback/ServerInvokerCallbackHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvokerCallbackHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/callback/ServerInvokerCallbackHandler.java,v
  retrieving revision 1.15.2.4
  retrieving revision 1.15.2.5
  diff -u -b -r1.15.2.4 -r1.15.2.5
  --- ServerInvokerCallbackHandler.java	28 Nov 2006 16:54:51 -0000	1.15.2.4
  +++ ServerInvokerCallbackHandler.java	14 Dec 2006 01:02:16 -0000	1.15.2.5
  @@ -154,6 +154,7 @@
            if(owner.getConfiguration() != null)
            {
               clientConfig.putAll(owner.getConfiguration());
  +            clientConfig.putAll(metadata);
            }
            // need to configure callback client with ssl config if one exists for server
            configureSocketFactory(clientConfig, owner);
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:03:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:03:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket -
	New directory ...
Message-ID: <E1Guf0r-0004aU-Fg@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:03:53

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Wed Dec 13 20:03:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:03:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1Guf0t-0004aw-C1@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:03:55

  Added:       src/main/org/jboss/remoting/transport/bisocket      Tag:
                        remoting_2_x BisocketServerInvoker.java
                        BisocketClientInvoker.java
                        TransportClientFactory.java
                        TransportServerFactory.java Bisocket.java
  Log:
  JBREM-650: Introducing bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +542 -0    JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketServerInvoker.java
  ===================================================================
  RCS file: BisocketServerInvoker.java
  diff -N BisocketServerInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketServerInvoker.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  @@ -0,0 +1,542 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +import java.io.DataInputStream;
  +import java.io.DataOutputStream;
  +import java.io.IOException;
  +import java.net.InetAddress;
  +import java.net.ServerSocket;
  +import java.net.Socket;
  +import java.util.Collection;
  +import java.util.Collections;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.Map;
  +import java.util.Set;
  +import java.util.TimerTask;
  +
  +import org.apache.commons.logging.Log;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.invocation.InternalInvocation;
  +import org.jboss.remoting.transport.PortUtil;
  +import org.jboss.remoting.transport.socket.ServerThread;
  +import org.jboss.remoting.transport.socket.SocketServerInvoker;
  +import org.jboss.remoting.util.TimerUtil;
  +
  +
  +/**
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 23, 2006
  + * </p>
  + */
  +public class BisocketServerInvoker extends SocketServerInvoker
  +{  
  +   private static Map listenerIdToServerInvokerMap = Collections.synchronizedMap(new HashMap());
  +
  +   private Map listenerIdToInvokerLocatorMap = new HashMap();
  +   private ServerSocket secondaryServerSocket;
  +   private InvokerLocator secondaryLocator;
  +   private SecondaryServerSocketThread secondaryServerSocketThread;
  +   private Map controlConnectionThreadMap = new HashMap();
  +   private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;
  +   private int pingWindow = 2 * pingFrequency;
  +   private ControlMonitorTimerTask controlMonitorTimerTask;
  +   
  +   
  +   public static BisocketServerInvoker getBisocketServerInvoker(String listenerId)
  +   {
  +      return (BisocketServerInvoker) listenerIdToServerInvokerMap.get(listenerId);
  +   }
  +   
  +   
  +//   public static void addBisocketServerInvoker(String listenerId, BisocketServerInvoker invoker)
  +//   {
  +//      listenerIdToServerInvokerMap.put(listenerId, invoker);
  +//   }
  +   
  +   
  +   public BisocketServerInvoker(InvokerLocator locator)
  +   {
  +      super(locator);
  +   }
  +
  +   
  +   public BisocketServerInvoker(InvokerLocator locator, Map configuration)
  +   {
  +      super(locator, configuration);
  +   }
  +   
  +   
  +   public void start() throws IOException
  +   {
  +      super.start();
  +      
  +      boolean startSecondaryPort = false;
  +      Object o = configuration.get(Bisocket.START_SECONDARY_PORT);
  +      
  +      if (o != null)
  +      {
  +         if (o instanceof String)
  +            startSecondaryPort = Boolean.valueOf((String) o).booleanValue();
  +         else if (o instanceof Boolean)
  +            startSecondaryPort = ((Boolean) o).booleanValue();
  +         else
  +            log.error("unrecognized value for configuration key \"" + 
  +                      Bisocket.START_SECONDARY_PORT + "\": " + o);
  +         
  +         if (startSecondaryPort)
  +         {
  +            InetAddress host = getServerSocket().getInetAddress();
  +            int freePort = PortUtil.findFreePort(host.getHostAddress());
  +            secondaryServerSocket = new ServerSocket(freePort, 0, host);
  +            secondaryLocator = new InvokerLocator(null, host.getHostAddress(), freePort, null, null); 
  +            secondaryServerSocketThread = new SecondaryServerSocketThread(secondaryServerSocket);
  +            secondaryServerSocketThread.setName("secondaryServerSocketThread");
  +            secondaryServerSocketThread.setDaemon(true);
  +            secondaryServerSocketThread.start();
  +            log.info("started secondary port: " + host + ":" + freePort);
  +         }
  +      }
  +//      ServerInvocationHandler handler = new InternalInvocationHandler(secondaryServerSocket);
  +//      addInvocationHandler(Bisocket.BISOCKET_INTERNAL_SUBSYSTEM, handler);
  +   }
  +   
  +   
  +   public boolean isTransportBiDirectional()
  +   {
  +      return true;
  +   }
  +   
  +   
  +   public void createControlConnection(String listenerId, InvokerLocator locator)
  +   throws IOException
  +   {
  +      // first connection
  +      if (locator == null)
  +         locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +      // restarted connection
  +      else
  +         listenerIdToInvokerLocatorMap.put(listenerId, locator);
  +      
  +      log.info("creating control connection: " + locator);
  +      Socket socket = new Socket(locator.getHost(), locator.getPort());
  +      DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
  +      dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +      dos.writeUTF(listenerId);
  +      Thread thread = new ControlConnectionThread(socket, listenerId);
  +      thread.setName("control: " + socket.toString());
  +      thread.setDaemon(true);
  +      
  +      synchronized (controlConnectionThreadMap)
  +      {
  +         controlConnectionThreadMap.put(listenerId, thread);
  +      }
  +      
  +      thread.start();
  +      log.info("created control connection: " + locator);
  +      
  +      if (controlMonitorTimerTask == null)
  +      {
  +         controlMonitorTimerTask = new ControlMonitorTimerTask();
  +         TimerUtil.schedule(controlMonitorTimerTask, pingFrequency);
  +         log.info("scheduled ControlMonitorTimerTask: " + controlMonitorTimerTask);
  +      }
  +   }
  +   
  +   
  +   public int getPingFrequency()
  +   {
  +      return pingFrequency;
  +   }
  +   
  +   
  +   public void setPingFrequency(int pingFrequency)
  +   {
  +      this.pingFrequency = pingFrequency;
  +      pingWindow = 2 * pingFrequency;
  +      log.info("set ping frequency: " + pingFrequency);
  +   }
  +   
  +   
  +   protected void cleanup()
  +   {
  +      super.cleanup();
  +      
  +      if (controlMonitorTimerTask != null)
  +      {
  +         controlMonitorTimerTask.shutdown();
  +      }
  +      Iterator it = controlConnectionThreadMap.values().iterator();
  +      while (it.hasNext())
  +      {
  +         ControlConnectionThread t = (ControlConnectionThread) it.next();
  +         t.shutdown();
  +         it.remove();
  +      }
  +      if (secondaryServerSocketThread != null)
  +      {
  +         secondaryServerSocketThread.shutdown();
  +      }
  +      if (secondaryServerSocket != null)
  +      {
  +         try
  +         {
  +            secondaryServerSocket.close();
  +            log.info("closed secondary port: " +
  +                     secondaryServerSocket.getInetAddress() + ":" +
  +                     secondaryServerSocket.getLocalPort());
  +         }
  +         catch (IOException e)
  +         {
  +            log.info("Error closing secondary server socket: " + e.getMessage());
  +         }
  +      }
  +   }
  +   
  +   
  +   protected InvokerLocator getSecondaryLocator()
  +   {
  +      return secondaryLocator;
  +   }
  +   
  +   protected ServerSocket getServerSocket()
  +   {
  +      return serverSocket;
  +   }
  +   
  +   
  +   protected Object handleInternalInvocation(InternalInvocation ii,
  +                                             InvocationRequest ir,
  +                                             ServerInvocationHandler handler)
  +   throws Throwable
  +   {
  +      if(Bisocket.GET_SECONDARY_INVOKER_LOCATOR.equals(ii.getMethodName()))
  +      {
  +         log.info("returning secondaryLocator: " + secondaryLocator); 
  +         return secondaryLocator;
  +      }
  +      
  +      Object response = super.handleInternalInvocation(ii, ir, handler);
  +      
  +      if(InternalInvocation.ADDCLIENTLISTENER.equals(ii.getMethodName()))
  +      {
  +         Map metadata = ir.getRequestPayload();
  +         if(metadata != null)
  +         {
  +            String listenerId = (String) metadata.get(Client.LISTENER_ID_KEY);
  +            if (listenerId != null)
  +            {
  +               listenerIdToServerInvokerMap.put(listenerId, this);
  +               log.info("registered " + listenerId + " -> " + this);
  +            }
  +         }
  +      }
  +      
  +      return response;
  +   }
  +   
  +   
  +   class ControlConnectionThread extends Thread
  +   {
  +      private Socket controlSocket;
  +      private String listenerId;
  +      private DataInputStream dis;
  +      private boolean running;
  +      private int errorCount;
  +      private long lastPing = System.currentTimeMillis();
  +      
  +      ControlConnectionThread(Socket socket, String listenerId) throws IOException
  +      {
  +         controlSocket = socket;
  +         this.listenerId = listenerId;
  +         dis = new DataInputStream(socket.getInputStream());
  +      }
  +      
  +      void shutdown()
  +      {
  +         running = false;
  +         synchronized (controlConnectionThreadMap)
  +         {
  +            controlConnectionThreadMap.remove(this);
  +         }
  +         try
  +         {
  +            controlSocket.close();
  +         }
  +         catch (IOException e)
  +         {
  +            log.warn("unable to close controlSocket");
  +         }
  +         interrupt();
  +      }
  +      
  +      boolean checkConnection()
  +      {
  +         long currentTime = System.currentTimeMillis();
  +         log.info("elapsed: " + (currentTime - lastPing));
  +         log.info("returning: " + ((currentTime - lastPing > pingWindow) ? false : true)); 
  +         return (currentTime - lastPing <= pingWindow);
  +      }
  +      
  +      String getListenerId()
  +      {
  +         return listenerId;
  +      }
  +      
  +      public void run()
  +      {
  +         log.info("starting ControlConnectionThread");
  +         running = true;
  +         while (running)
  +         {
  +            Socket socket = null;
  +            
  +            try
  +            {
  +               int action = dis.read();
  +               lastPing = System.currentTimeMillis();
  +               
  +               switch (action)
  +               {
  +                  case Bisocket.CREATE_ORDINARY_SOCKET:
  +//                     String listenerId = dis.readUTF();
  +//                     dis.readUTF();
  +                     InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +                     socket = new Socket(locator.getHost(), locator.getPort());
  +                     DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
  +                     dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +                     dos.writeUTF(listenerId);
  +                     break;
  +                     
  +                  case Bisocket.PING:
  +                     log.info("got ping");
  +//                     log.info("lastPing: " + lastPing);
  +                     continue;
  +                     
  +                  case -1:
  +                     shutdown();
  +                     return;
  +                     
  +                  default:
  +                     log.error("unrecognized action: " + action);
  +                     continue;
  +               }
  +            }
  +            catch (IOException e)
  +            {
  +               if (running)
  +               {
  +                  if ("socket closed".equals(e.getMessage()))
  +                  {
  +                     shutdown();
  +                     return;
  +                  }
  +                  log.error("Unable to create new Socket: " + e.getMessage());
  +                  e.printStackTrace();
  +                  if (++errorCount > 5)
  +                  {
  +                     shutdown();
  +                     return;
  +                  }
  +                  continue;
  +               }
  +               
  +               return;
  +            }
  +            
  +            synchronized (clientpool)
  +            {
  +               if(clientpool.size() < maxPoolSize)
  +               {
  +                  Thread thread = null;
  +                  try
  +                  {
  +                     thread = new ServerThread(socket, BisocketServerInvoker.this,
  +                                               clientpool, threadpool,
  +                                               getTimeout(), serverSocketClass);
  +                     thread.start();
  +                     log.info("created: " + thread);
  +                  }
  +                  catch (Exception e)
  +                  {
  +                     log.error("Unable to create new ServerThread: " + e.getMessage());
  +                     e.printStackTrace();
  +                  }
  +                  
  +                  synchronized (threadpool)
  +                  {
  +                     threadpool.add(thread);
  +                  }
  +               }
  +            }
  +         }
  +      }
  +   }
  +   
  +   
  +//   protected ServerThread createServerThread(Socket socket) throws Exception
  +//   {
  +//      return new BisocketServerThread(socket, this, clientpool, threadpool, getTimeout(), serverSocketClass);
  +//   }
  +   
  +   
  +   class SecondaryServerSocketThread extends Thread
  +   {
  +      private ServerSocket secondaryServerSocket;
  +      boolean running;
  +      
  +      SecondaryServerSocketThread(ServerSocket secondaryServerSocket) throws IOException
  +      {
  +         this.secondaryServerSocket = secondaryServerSocket;
  +      }
  +      
  +      void shutdown()
  +      {
  +         running = false;
  +         interrupt();
  +      }
  +      
  +      public void run()
  +      {
  +         running = true;
  +         while (running)
  +         {
  +            try
  +            {
  +               Socket socket = secondaryServerSocket.accept();
  +               DataInputStream dis = new DataInputStream(socket.getInputStream());
  +               int action = dis.read();
  +               String listenerId = dis.readUTF();
  +               
  +               switch (action)
  +               {
  +                  case Bisocket.CREATE_CONTROL_SOCKET:
  +                     BisocketClientInvoker invoker;
  +                     invoker =  BisocketClientInvoker.getBisocketClientInvoker(listenerId);
  +                     invoker.replaceControlSocket(socket);
  +                     log.info("SecondaryServerSocketThread: created secondary socket: " + listenerId);
  +                     break;
  +                     
  +                  case Bisocket.CREATE_ORDINARY_SOCKET: 
  +                     BisocketClientInvoker.transferSocket(listenerId, socket);
  +                     log.info("SecondaryServerSocketThread: transferred socket: " + listenerId);
  +                     break;
  +                     
  +                  default:
  +                     log.error("unrecognized action: " + action);
  +               }
  +            }
  +            catch (IOException e)
  +            {
  +               if (running)
  +                  log.error("Failed to accept socket connection", e);
  +               else
  +                  return;
  +                  
  +            }
  +         }
  +      }
  +      
  +      ServerSocket getServerSocket()
  +      {
  +         return secondaryServerSocket;
  +      }
  +   }
  +   
  +   
  +   class ControlMonitorTimerTask extends TimerTask
  +   {
  +      void shutdown()
  +      {
  +         running = false;
  +         cancel();
  +         log.info("shutting down " + this);
  +      }
  +      
  +      public void run()
  +      {
  +         Collection controlConnectionThreads = null;
  +         synchronized (controlConnectionThreadMap)
  +         {
  +            controlConnectionThreads = new HashSet(controlConnectionThreadMap.values());
  +         }
  +         
  +         Iterator it = controlConnectionThreads.iterator();
  +         while (it.hasNext() & running)
  +         {
  +            ControlConnectionThread t = (ControlConnectionThread) it.next();
  +            if (!t.checkConnection())
  +            {
  +               log.info("detected failure on control connection: requesting new control connection");
  +               t.shutdown();
  +               it.remove();
  +               
  +               if (!running)
  +                  return;
  +               
  +               try
  +               {
  +                  createControlConnection(t.getListenerId(), null);
  +               }
  +               catch (IOException e)
  +               {
  +                  InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(t.getListenerId());
  +                  log.error(this + ": " + "Unable to recreate control connection: " + locator, e);
  +                  e.printStackTrace();
  +               }
  +            }
  +         }
  +      }
  +   }
  +   
  +   
  +//   class InternalInvocationHandler implements ServerInvocationHandler
  +//   {
  +//      InvokerLocator locator;
  +//      
  +//      InternalInvocationHandler(ServerSocket ss)
  +//      {
  +//         String host = ss.getInetAddress().getHostAddress();
  +//         int port = ss.getLocalPort();
  +//         locator = new InvokerLocator(null, host, port, null, null);   
  +//      }
  +//      
  +//      public Object invoke(InvocationRequest invocation) throws Throwable
  +//      {
  +//         return locator;
  +//      }
  +//
  +//      public void setMBeanServer(MBeanServer server) {}
  +//      public void setInvoker(ServerInvoker invoker) {}
  +//      public void addListener(InvokerCallbackHandler callbackHandler) {}
  +//      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +//   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +404 -0    JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketClientInvoker.java
  ===================================================================
  RCS file: BisocketClientInvoker.java
  diff -N BisocketClientInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketClientInvoker.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  @@ -0,0 +1,404 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +import java.io.DataOutputStream;
  +import java.io.IOException;
  +import java.io.OutputStream;
  +import java.net.Socket;
  +import java.util.Collections;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.Map;
  +import java.util.Set;
  +import java.util.TimerTask;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.ConnectionFailedException;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.invocation.InternalInvocation;
  +import org.jboss.remoting.marshal.Marshaller;
  +import org.jboss.remoting.marshal.UnMarshaller;
  +import org.jboss.remoting.transport.BidirectionalClientInvoker;
  +import org.jboss.remoting.transport.socket.SocketClientInvoker;
  +import org.jboss.remoting.util.TimerUtil;
  +
  +/**
  + * BisocketClientInvoker uses Sockets to remotely connect to the a remote ServerInvoker,
  + * which must be a BisocketServerInvoker.
  + * 
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketClientInvoker
  +extends SocketClientInvoker
  +implements BidirectionalClientInvoker
  +{  
  +   private static final Logger log = Logger.getLogger(BisocketClientInvoker.class);
  +   private static Map listenerIdToClientInvokerMap = Collections.synchronizedMap(new HashMap());
  +   private static Map listenerIdToSocketsMap = new HashMap();
  + 
  +   private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;;
  +   private String listenerId;
  +   private InvokerLocator secondaryLocator;
  +   private Socket controlSocket;
  +   private OutputStream controlOutputStream;
  +   private PingTimerTask pingTimerTask;
  +
  +   
  +   static BisocketClientInvoker getBisocketClientInvoker(String listenerId)
  +   {
  +      return (BisocketClientInvoker) listenerIdToClientInvokerMap.get(listenerId);
  +   }
  +   
  +   
  +   static void transferSocket(String listenerId, Socket socket)
  +   {
  +      Set sockets = null;
  +      
  +      synchronized (listenerIdToSocketsMap)
  +      {
  +         sockets = (Set) listenerIdToSocketsMap.get(listenerId);
  +         if (sockets == null)
  +         {
  +            sockets = new HashSet();
  +            listenerIdToSocketsMap.put(listenerId, sockets);
  +         }
  +      }
  +      
  +      synchronized (sockets)
  +      {
  +         sockets.add(socket);
  +         sockets.notify();
  +      }
  +   }
  +   
  +   
  +   public BisocketClientInvoker(InvokerLocator locator) throws IOException
  +   {
  +      this(locator, null);
  +   }
  +
  +   
  +   public BisocketClientInvoker(InvokerLocator locator, Map config) throws IOException
  +   {
  +      super(locator, config);
  +      
  +      if (config != null)
  +      {
  +         listenerId = (String) config.get(Client.LISTENER_ID_KEY);
  +         if (listenerId != null)
  +         {
  +            listenerIdToClientInvokerMap.put(listenerId, this);
  +            
  +            synchronized (listenerIdToSocketsMap)
  +            {
  +               if (listenerIdToSocketsMap.get(listenerId) == null)
  +                  listenerIdToSocketsMap.put(listenerId, new HashSet());
  +            }
  +            
  +            log.info("registered " + listenerId + " -> " + this);
  +         }
  +
  +            // look for socketTimeout param
  +            Object val = config.get(Bisocket.PING_FREQUENCY);
  +            if (val != null)
  +            {
  +               try
  +               {
  +                  int nVal = Integer.valueOf((String) val).intValue();
  +                  pingFrequency = nVal;
  +                  log.debug("Setting ping frequency to: " + pingFrequency);
  +               }
  +               catch (Exception e)
  +               {
  +                  log.warn("Could not convert " + Bisocket.PING_FREQUENCY +
  +                           " value of " + val + " to an int value.");
  +               }
  +            }
  +      }
  +   }
  +   
  +   
  +   public int getPingFrequency()
  +   {
  +      return pingFrequency;
  +   }
  +   
  +   
  +   public void setPingFrequency(int pingFrequency)
  +   {
  +      this.pingFrequency = pingFrequency;
  +      log.info("set ping frequency: " + pingFrequency);
  +   }
  +   
  +   
  +   protected void handleConnect() throws ConnectionFailedException
  +   {
  +      super.handleConnect();
  +      
  +      // Callback client on server side.
  +      if (listenerId != null)
  +      {
  +//         pingTimerTask = new PingTimerTask();
  +//         TimerUtil.schedule(pingTimerTask, pingFrequency);
  +//         log.info("scheduled PingTimerTask");
  +         return;
  +      }
  +      
  +      // Client on client side.
  +      try
  +      {
  +         InternalInvocation ii = new InternalInvocation(Bisocket.GET_SECONDARY_INVOKER_LOCATOR, null);
  +         InvocationRequest r = new InvocationRequest(null, null, ii, null, null, null);
  +//         secondaryLocator = (InvokerLocator) invoke(r);
  +         Object o = invoke(r);
  +         log.info("secondary locator: " + o);
  +         secondaryLocator = (InvokerLocator) o;
  +         log.info("got secondary locator: " + secondaryLocator);
  +      }
  +      catch (Throwable e)
  +      {
  +         log.error("Unable to retrieve address/port of secondary server socket", e);
  +         throw new ConnectionFailedException(e.getMessage());
  +      }
  +   }
  +
  +   
  +   protected void handleDisconnect()
  +   {
  +      super.handleDisconnect();
  +      if (listenerId != null)
  +      {
  +         listenerIdToClientInvokerMap.remove(listenerId);
  +         listenerIdToSocketsMap.remove(listenerId);
  +         if (pingTimerTask != null)
  +            pingTimerTask.shutDown();
  +      }
  +   }
  +   
  +   
  +   protected Object transport(String sessionId, Object invocation, Map metadata,
  +                              Marshaller marshaller, UnMarshaller unmarshaller)
  +   throws IOException, ConnectionFailedException, ClassNotFoundException
  +   {  
  +      if (invocation instanceof InvocationRequest)
  +      {
  +         InvocationRequest ir = (InvocationRequest) invocation;
  +         Object o = ir.getParameter();
  +         if (o instanceof InternalInvocation)
  +         {
  +            InternalInvocation ii = (InternalInvocation) o;
  +            if (InternalInvocation.ADDLISTENER.equals(ii.getMethodName()))
  +            {
  +               Map requestPayload = ir.getRequestPayload();
  +               String listenerId = (String) requestPayload.get(Client.LISTENER_ID_KEY);
  +               BisocketServerInvoker callbackServerInvoker;
  +               callbackServerInvoker = BisocketServerInvoker.getBisocketServerInvoker(listenerId);
  +               callbackServerInvoker.createControlConnection(listenerId, secondaryLocator);
  +            }
  +         }
  +      }
  +      
  +      return super.transport(sessionId, invocation, metadata, marshaller, unmarshaller);
  +   }
  +   
  +   
  +   protected Socket createSocket(String address, int port) throws IOException
  +   {
  +      if (listenerId == null)
  +         return super.createSocket(address, port);
  +      
  +      Socket socket = null;
  +      Set sockets = null;
  +      
  +      synchronized (listenerIdToSocketsMap)
  +      {
  +         sockets = (Set) listenerIdToSocketsMap.get(listenerId);
  +      }
  +      
  +      synchronized (sockets)
  +      {
  +         Iterator it = sockets.iterator();
  +         if (it.hasNext())
  +         {
  +            socket = (Socket) it.next();
  +            it.remove();
  +            
  +            if (controlSocket != null)
  +               return socket;
  +            else
  +            {
  +               controlSocket = socket;
  +               controlOutputStream = controlSocket.getOutputStream();
  +               log.info("got control socket");
  +               pingTimerTask = new PingTimerTask();
  +               TimerUtil.schedule(pingTimerTask, pingFrequency);
  +               log.info("scheduled PingTimerTask");
  +               
  +               if (it.hasNext())
  +               {
  +                  socket = (Socket) it.next();
  +                  it.remove();
  +                  return socket;
  +               }
  +            }
  +         }
  +         
  +         if (controlSocket == null)
  +         {
  +            while (true)
  +            {
  +               try
  +               {
  +                  sockets.wait(getTimeout());
  +                  if (sockets.isEmpty())
  +                     throw new IOException("Timed out trying to create control socket");
  +                  break;
  +               }
  +               catch (InterruptedException ignored) {}
  +            }
  +            
  +            it = sockets.iterator();
  +            controlSocket = (Socket) it.next();
  +            controlOutputStream = controlSocket.getOutputStream();
  +            it.remove(); 
  +            log.info("got control socket");
  +            pingTimerTask = new PingTimerTask();
  +            TimerUtil.schedule(pingTimerTask, pingFrequency);
  +            log.info("scheduled PingTimerTask");
  +         }
  +         
  +         log.info("requesting socket");
  +         
  +         synchronized (controlOutputStream)
  +         {
  +            controlOutputStream.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +         }
  +//         controlOutputStream.writeUTF(listenerId);
  +  
  +         while (true)
  +         {
  +            try
  +            {
  +               sockets.wait(getTimeout());
  +               if (sockets.isEmpty())
  +                  throw new IOException("Timed out trying to create socket");
  +               break;
  +            }
  +            catch (InterruptedException ignored) {}
  +         }
  +         
  +         log.info("got socket");
  +         it = sockets.iterator();
  +         socket = (Socket) it.next();
  +         it.remove();
  +         return socket;
  +      }
  +   }
  +   
  +   
  +   void replaceControlSocket(Socket socket) throws IOException
  +   {
  +      synchronized (controlSocket)
  +      {
  +         controlSocket = socket;
  +      }
  +      controlOutputStream = controlSocket.getOutputStream();
  +      
  +      if (pingTimerTask != null)
  +         pingTimerTask.cancel();
  +      
  +      pingTimerTask = new PingTimerTask();
  +      TimerUtil.schedule(pingTimerTask, pingFrequency);
  +      log.info("replaced PingTimerTask");
  +   }
  +   
  +   
  +   protected Object checkType(Object o, Class c) throws IOException
  +   {
  +      if (c.isInstance(o))
  +         return o;
  +      
  +      throw new IOException(o + "is not an instance of " + c);
  +   }
  +   
  +   protected Object checkNull(Object o, String field) throws IOException
  +   {
  +      if (o == null)
  +         throw new IOException(field + " must not be null");
  +      
  +      return o;
  +   }
  +
  +
  +   public InvokerLocator getCallbackLocator(Map metadata)
  +   {
  +      String transport = (String) metadata.get(Client.CALLBACK_SERVER_PROTOCOL);
  +      String host = (String) metadata.get(Client.CALLBACK_SERVER_HOST);
  +      String sPort = (String) metadata.get(Client.CALLBACK_SERVER_PORT);
  +      int port = -1;
  +      if (sPort != null)
  +      {
  +         try
  +         {
  +            port = Integer.parseInt(sPort);
  +         }
  +         catch (NumberFormatException e)
  +         {
  +            throw new RuntimeException("Can not set internal callback server port as configuration value (" + sPort + " is not a number.");
  +         }
  +      }
  +
  +      return new InvokerLocator(transport, host, port, "callback", metadata);
  +   }
  +   
  +   
  +   class PingTimerTask extends TimerTask
  +   {
  +      public void shutDown()
  +      {
  +         cancel();
  +      }
  +      
  +      public void run()
  +      {
  +         synchronized (controlOutputStream)
  +         {
  +            try
  +            {
  +               log.info("sending ping");
  +               controlOutputStream.write(Bisocket.PING);
  +            }
  +            catch (IOException e)
  +            {
  +               log.warn("Unable to send ping: shutting down PingTimerTask");
  +               pingTimerTask = null;
  +               cancel();
  +            }
  +         }
  +      }
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +51 -0     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/TransportClientFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportClientFactory.java
  ===================================================================
  RCS file: TransportClientFactory.java
  diff -N TransportClientFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportClientFactory.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  @@ -0,0 +1,51 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.transport.ClientFactory;
  +import org.jboss.remoting.transport.ClientInvoker;
  +
  +import java.io.IOException;
  +import java.util.Map;
  +
  +/**
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class TransportClientFactory implements ClientFactory
  +{
  +   public ClientInvoker createClientInvoker(InvokerLocator locator, Map config)
  +         throws IOException
  +   {
  +      return new BisocketClientInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return false;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +28 -0     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/TransportServerFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportServerFactory.java
  ===================================================================
  RCS file: TransportServerFactory.java
  diff -N TransportServerFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportServerFactory.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  @@ -0,0 +1,28 @@
  +package org.jboss.remoting.transport.bisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.transport.ServerFactory;
  +
  +import java.util.Map;
  +
  +/**
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class TransportServerFactory implements ServerFactory
  +{
  +   public ServerInvoker createServerInvoker(InvokerLocator locator, Map config)
  +   {
  +      return new BisocketServerInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return false;
  +   }
  +}
  
  
  
  1.1.2.1   +45 -0     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/Bisocket.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Bisocket.java
  ===================================================================
  RCS file: Bisocket.java
  diff -N Bisocket.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ Bisocket.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  @@ -0,0 +1,45 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 22, 2006
  + * </p>
  + */
  +public class Bisocket
  +{
  +   public static final String BISOCKET_INTERNAL_SUBSYSTEM = "bisocketInternalSystem";
  +   public static final String CREATE_CALLBACK_SOCKET = "createCallbackSocket";
  +   public static final String GET_SECONDARY_INVOKER_LOCATOR = "getSecondaryInvokerLocator";
  +
  +   public static final String START_SECONDARY_PORT = "startSecondaryPort";
  +   
  +   public static final byte PING                   = 1;
  +   public static final byte CREATE_CONTROL_SOCKET  = 2;
  +   public static final byte CREATE_ORDINARY_SOCKET = 3;
  +   
  +   public static final String PING_FREQUENCY = "pingFrequency";
  +   public static final int PING_FREQUENCY_DEFAULT = 5000;
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:04:25 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:04:25 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/socket ...
Message-ID: <E1Guf1N-0004bC-Jh@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:04:25

  Modified:    src/main/org/jboss/remoting/transport/socket  Tag:
                        remoting_2_x SocketServerInvoker.java
  Log:
  JBREM-650: Made serverSocketClass protected.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.30.2.3  +2 -2      JBossRemoting/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java,v
  retrieving revision 1.30.2.2
  retrieving revision 1.30.2.3
  diff -u -b -r1.30.2.2 -r1.30.2.3
  --- SocketServerInvoker.java	3 Nov 2006 18:58:40 -0000	1.30.2.2
  +++ SocketServerInvoker.java	14 Dec 2006 01:04:25 -0000	1.30.2.3
  @@ -45,7 +45,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.30.2.2 $
  + * @version $Revision: 1.30.2.3 $
    * @jmx:mbean
    */
   public class SocketServerInvoker extends ServerInvoker implements Runnable, SocketServerInvokerMBean
  @@ -70,7 +70,7 @@
       * Specifies the fully qualified class name for the custom SocketWrapper implementation to use on the server.
       */
      public static final String SERVER_SOCKET_CLASS_FLAG = "serverSocketClass";
  -   private String serverSocketClass = ServerSocketWrapper.class.getName();
  +   protected String serverSocketClass = ServerSocketWrapper.class.getName();
   
      protected ServerSocket serverSocket = null;
      protected boolean running = false;
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:07:21 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:21 -0500
Subject: [jboss-cvs] JBossRemoting/src/tests/org/jboss/test/remoting/callback
	...
Message-ID: <E1Guf4D-0004fF-Sy@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:21

  Modified:    src/tests/org/jboss/test/remoting/callback  Tag:
                        remoting_2_x CallbackTestServer.java
  Log:
  JBREM-650: Made locatorURI and connector protected.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.7.4.1   +3 -3      JBossRemoting/src/tests/org/jboss/test/remoting/callback/CallbackTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/CallbackTestServer.java,v
  retrieving revision 1.7
  retrieving revision 1.7.4.1
  diff -u -b -r1.7 -r1.7.4.1
  --- CallbackTestServer.java	23 May 2006 17:47:51 -0000	1.7
  +++ CallbackTestServer.java	14 Dec 2006 01:07:21 -0000	1.7.4.1
  @@ -50,8 +50,8 @@
      private static String host = "localhost";
      private static int port = 5500;
   
  -   private String locatorURI = transport + "://" + host + ":" + port;
  -   private Connector connector;
  +   protected String locatorURI = transport + "://" + host + ":" + port;
  +   protected Connector connector;
   
      // String to be returned from invocation handler upon client invocation calls.
      public static final String RESPONSE_VALUE = "This is the return to SampleInvocationHandler invocation";
  @@ -111,7 +111,7 @@
      public static class SampleInvocationHandler implements ServerInvocationHandler
      {
   
  -      private List listeners = new ArrayList();
  +      protected List listeners = new ArrayList();
   
   
         /**
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:07:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket
	- New directory ...
Message-ID: <E1Guf4o-0004fL-7O@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:58

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Wed Dec 13 20:07:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration
	- New directory ...
Message-ID: <E1Guf4o-0004fP-Bj@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:58

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration added to the repository


From ron_sigal at yahoo.com  Wed Dec 13 20:07:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load
	- New directory ...
Message-ID: <E1Guf4o-0004fT-Fy@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:58

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load added to the repository


From ron_sigal at yahoo.com  Wed Dec 13 20:07:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress
	- New directory ...
Message-ID: <E1Guf4o-0004fX-Je@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:58

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress added to the repository


From ron_sigal at yahoo.com  Wed Dec 13 20:07:58 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:58 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout
	- New directory ...
Message-ID: <E1Guf4o-0004fb-Uj@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:58

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout added to the repository


From ron_sigal at yahoo.com  Wed Dec 13 20:07:59 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:07:59 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle
	- New directory ...
Message-ID: <E1Guf4p-0004ff-2V@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:07:59

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle added to the repository


From ron_sigal at yahoo.com  Wed Dec 13 20:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load
	...
Message-ID: <E1Guf4s-0004g3-6a@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/load  
                        Tag: remoting_2_x
                        BisocketPooledConnectionTestCase.java
                        BisocketSocketLoadTestCase.java
  Log:
  JBREM-650:  Unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +11 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load/Attic/BisocketPooledConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPooledConnectionTestCase.java
  ===================================================================
  RCS file: BisocketPooledConnectionTestCase.java
  diff -N BisocketPooledConnectionTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPooledConnectionTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,11 @@
  +package org.jboss.test.remoting.transport.bisocket.load;
  +
  +import org.jboss.test.remoting.transport.socket.load.PooledConnectionTestCase;
  +
  +public class BisocketPooledConnectionTestCase extends PooledConnectionTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  
  
  
  1.1.2.1   +32 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load/Attic/BisocketSocketLoadTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketSocketLoadTestCase.java
  ===================================================================
  RCS file: BisocketSocketLoadTestCase.java
  diff -N BisocketSocketLoadTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketSocketLoadTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,32 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.load;
  +
  +import org.jboss.test.remoting.transport.socket.load.SocketLoadTestCase;
  +
  +public class BisocketSocketLoadTestCase extends SocketLoadTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle
	...
Message-ID: <E1Guf4s-0004gT-BZ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle      
                        Tag: remoting_2_x
                        BisocketInactiveIdleTimeoutTestServer.java
                        BisocketInactiveIdleTimeoutClientTest.java
                        BisocketInactiveIdleTimeoutTestCase.java
                        BisocketIdleTimeoutTestServer.java
                        BisocketIdleTimeoutTestCase.java
                        BisocketIdleTimeoutClientTest.java
  Log:
  JBREM-650:  Unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +28 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/Attic/BisocketInactiveIdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInactiveIdleTimeoutTestServer.java
  ===================================================================
  RCS file: BisocketInactiveIdleTimeoutTestServer.java
  diff -N BisocketInactiveIdleTimeoutTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInactiveIdleTimeoutTestServer.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,28 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.InactiveIdleTimeoutTestServer;
  +
  +/**
  + * This is just like IdleTimeoutTestServer except instead of
  + * looking for server threads that are still in read mode waiting for
  + * data from client, want to test for idle server threads that finished with
  + * client/server connection and are just sitting in the thread pool waiting to
  + * be re-used.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketInactiveIdleTimeoutTestServer extends InactiveIdleTimeoutTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   public static void main(String[] args) throws Throwable
  +   {
  +      BisocketInactiveIdleTimeoutTestServer rt = new BisocketInactiveIdleTimeoutTestServer();
  +      rt.setUp();
  +      Thread.sleep(45000);
  +      rt.tearDown();
  +   }
  +}
  
  
  
  1.1.2.1   +14 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/Attic/BisocketInactiveIdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInactiveIdleTimeoutClientTest.java
  ===================================================================
  RCS file: BisocketInactiveIdleTimeoutClientTest.java
  diff -N BisocketInactiveIdleTimeoutClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInactiveIdleTimeoutClientTest.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,14 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.InactiveIdleTimeoutClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketInactiveIdleTimeoutClientTest extends InactiveIdleTimeoutClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  
  
  
  1.1.2.1   +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/Attic/BisocketInactiveIdleTimeoutTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInactiveIdleTimeoutTestCase.java
  ===================================================================
  RCS file: BisocketInactiveIdleTimeoutTestCase.java
  diff -N BisocketInactiveIdleTimeoutTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInactiveIdleTimeoutTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,48 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +public class BisocketInactiveIdleTimeoutTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketInactiveIdleTimeoutClientTest.class.getName(),
  +                     1,
  +                     BisocketInactiveIdleTimeoutTestServer.class.getName());
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +21 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/Attic/BisocketIdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketIdleTimeoutTestServer.java
  ===================================================================
  RCS file: BisocketIdleTimeoutTestServer.java
  diff -N BisocketIdleTimeoutTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketIdleTimeoutTestServer.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,21 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.IdleTimeoutTestServer;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketIdleTimeoutTestServer extends IdleTimeoutTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   public static void main(String[] args) throws Throwable
  +   {
  +      BisocketIdleTimeoutTestServer rt = new BisocketIdleTimeoutTestServer();
  +      rt.startServer();
  +   }
  +}
  +
  
  
  
  1.1.2.1   +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/Attic/BisocketIdleTimeoutTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketIdleTimeoutTestCase.java
  ===================================================================
  RCS file: BisocketIdleTimeoutTestCase.java
  diff -N BisocketIdleTimeoutTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketIdleTimeoutTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,48 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +public class BisocketIdleTimeoutTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketIdleTimeoutClientTest.class.getName(),
  +                     2,
  +                     BisocketIdleTimeoutTestServer.class.getName());
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +14 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/Attic/BisocketIdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketIdleTimeoutClientTest.java
  ===================================================================
  RCS file: BisocketIdleTimeoutClientTest.java
  diff -N BisocketIdleTimeoutClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketIdleTimeoutClientTest.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,14 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.IdleTimeoutClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketIdleTimeoutClientTest extends IdleTimeoutClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress
	...
Message-ID: <E1Guf4s-0004h1-Lj@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/stress   
                        Tag: remoting_2_x BisocketInvokerClientTest.java
                        BisocketInvokerServerTest.java readme.txt
  Log:
  JBREM-650:  Unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +28 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress/Attic/BisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInvokerClientTest.java
  ===================================================================
  RCS file: BisocketInvokerClientTest.java
  diff -N BisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInvokerClientTest.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,28 @@
  +package org.jboss.test.remoting.transport.bisocket.stress;
  +
  +import org.jboss.test.remoting.transport.socket.stress.SocketInvokerClientTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketInvokerClientTest extends SocketInvokerClientTest
  +{
  +
  +   public String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      BisocketInvokerClientTest client = new BisocketInvokerClientTest();
  +      try
  +      {
  +         client.testClientCalls();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +}
  
  
  
  1.1.2.1   +31 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress/Attic/BisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInvokerServerTest.java
  ===================================================================
  RCS file: BisocketInvokerServerTest.java
  diff -N BisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInvokerServerTest.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,31 @@
  +package org.jboss.test.remoting.transport.bisocket.stress;
  +
  +import org.jboss.test.remoting.transport.socket.stress.SocketInvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketInvokerServerTest extends SocketInvokerServerTest
  +{
  +   public String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      BisocketInvokerServerTest server = new BisocketInvokerServerTest();
  +      try
  +      {
  +         server.setUp();
  +//         Thread.currentThread().sleep(300000);
  +         Thread.sleep(7200000);
  +         server.tearDown();
  +         System.out.println("Have torn down test.");
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +}
  
  
  
  1.1.2.1   +6 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress/Attic/readme.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: readme.txt
  ===================================================================
  RCS file: readme.txt
  diff -N readme.txt
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ readme.txt	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,6 @@
  +This package directory contains client/server classes for testing concurrent invocations through the
  +socket transport.  These are not included as part of standard testsuite run and need to be run manually.
  +
  +6/29/06 - Ran with 250 threads on client, each looping 1M times making server invocations.  The test
  +itself finally timed out after two hours of running (per code in test classes), but was able over 35K invocations
  +per thread without error or leak in memory.
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1Guf4s-0004gk-GA@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket    Tag:
                        remoting_2_x BisocketPerformanceTestServer.java
                        BisocketTestCase.java
                        BisocketPerformanceTestClient.java
  Log:
  JBREM-650:  Unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +140 -0    JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketPerformanceTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPerformanceTestServer.java
  ===================================================================
  RCS file: BisocketPerformanceTestServer.java
  diff -N BisocketPerformanceTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPerformanceTestServer.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,140 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket;
  +
  +import java.net.InetAddress;
  +import java.util.HashMap;
  +
  +import javax.management.MBeanServer;
  +
  +import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class BisocketPerformanceTestServer extends TestCase
  +{
  +   public static int port = 5423;
  +   
  +   private static Logger log = Logger.getLogger(BisocketPerformanceTestServer.class);
  +   private static String transport = "bisocket";
  +   
  +   // remoting server connector
  +   private Connector connector;
  +
  +   
  +   /**
  +    * Sets up target remoting server.
  +    */
  +   public void setUp() throws Exception
  +   {
  +      String locatorURI = transport + "://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  +      HashMap config = new HashMap();
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      connector = new Connector(serverLocator, config);
  +      connector.create();
  +      SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
  +      connector.addInvocationHandler("sample", invocationHandler);
  +      connector.start();
  +   }
  +
  +   
  +   /**
  +    * Shuts down the server
  +    */
  +   public void tearDown()
  +   {
  +      if (connector != null)
  +      {
  +         connector.stop();
  +         connector.destroy();
  +      }
  +   }
  +   
  +   
  +   public static void main(String[] args)
  +   {
  +      if (args.length == 1)
  +         transport = args[0];
  +         
  +      BisocketPerformanceTestServer testCase = new BisocketPerformanceTestServer();
  +      try
  +      {
  +         testCase.setUp();
  +         Thread.sleep(600000);
  +         testCase.tearDown();
  +      }
  +      catch(Throwable e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.  When callback client's are registered, will
  +    * generate callbacks periodically.
  +    */
  +   static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +      InvokerCallbackHandler callbackHandler;
  +      
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         System.out.println("Adding callback listener.");
  +         this.callbackHandler = callbackHandler;
  +      }
  +
  +      public Object invoke(InvocationRequest invocation) throws Throwable
  +      {
  +         try
  +         {
  +            callbackHandler.handleCallback(new Callback("callback"));
  +         }
  +         catch (HandleCallbackException e)
  +         {
  +            log.error("Unable to send callback");
  +         }
  +         return null;
  +      }
  +      
  +      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +      public void setMBeanServer(MBeanServer server) {}
  +      public void setInvoker(ServerInvoker invoker) {}
  +   }
  +}
  
  
  
  1.1.2.1   +1338 -0   JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: BisocketTestCase.java
  diff -N BisocketTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,1338 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket;
  +
  +import java.lang.reflect.Field;
  +import java.net.InetAddress;
  +import java.net.Socket;
  +import java.util.Collection;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
  +
  +import javax.management.MBeanServer;
  +
  +import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
  +import org.jboss.remoting.transport.ClientInvoker;
  +import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.PortUtil;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +import org.jboss.remoting.transport.bisocket.BisocketClientInvoker;
  +import org.jboss.remoting.transport.bisocket.BisocketServerInvoker;
  +import org.jboss.remoting.transport.socket.MicroSocketClientInvoker;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class BisocketTestCase extends TestCase
  +{
  +   public static int port = 5413;
  +   
  +   private static Logger log = Logger.getLogger(BisocketTestCase.class);
  +   
  +   private static final String INVOCATION_TEST =     "invocationTest";
  +   private static final String CALLBACK_TEST =       "callbackTest";
  +   private static final String COUNTER =             "counter";
  +   
  +   private static final String TEST_PING_FREQUENCY_STRING = "1000";
  +   private static final int    TEST_PING_FREQUENCY = 1000;
  +   private static final String TEST_MAX_POOL_SIZE_STRING = "5";
  +   private static final int    TEST_MAX_POOL_SIZE = 5;
  +   
  +   // remoting server connector
  +   private Connector connector;
  +   private SampleInvocationHandler invocationHandler;
  +
  +
  +   
  +   /**
  +    * Sets up target remoting server.
  +    */
  +   public void setUp() throws Exception
  +   {
  +      String locatorURI = "bisocket://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      config.put(MicroSocketClientInvoker.MAX_POOL_SIZE_FLAG, TEST_MAX_POOL_SIZE_STRING);
  +      connector = new Connector(serverLocator, config);
  +      connector.create();
  +      invocationHandler = new SampleInvocationHandler();
  +      connector.addInvocationHandler("sample", invocationHandler);
  +      connector.start();
  +   }
  +
  +   
  +   /**
  +    * Shuts down the server
  +    */
  +   public void tearDown()
  +   {
  +      connector.stop();
  +      connector.destroy();
  +   }
  +   
  +   
  +   public void testInvocations() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int invocationCount = 1000;
  +      HashMap metadata = new HashMap(1);
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         response.equals(count);
  +      }
  +      
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testInvocationsThenCallbacksThenInvocations() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int invocationCount = 100;
  +      HashMap metadata = new HashMap(1);
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         assertTrue(response.equals(count));
  +      }
  +      
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         client.invoke(CALLBACK_TEST);
  +      }
  +      
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         assertTrue(response.equals(count));
  +      }
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testAlternatingInvocationsAndCallbacks() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      int invocationCount = 100;
  +      HashMap metadata = new HashMap(1);
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         client.invoke(CALLBACK_TEST);
  +         assertTrue(response.equals(count));
  +      }
  +      
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testMaxSocketPoolSize() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      assertEquals(1, invocationHandler.callbackHandlers.size()); 
  +      log.info("client added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker);
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      assertEquals(0, pool.size());
  +      Long usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      int invocationCount = TEST_MAX_POOL_SIZE;
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         client.invokeOneway(CALLBACK_TEST);
  +      }
  +      
  +      Thread.sleep(100);
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         client.invokeOneway(CALLBACK_TEST);
  +      }
  +      
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      Thread.sleep(1000);
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      Thread.sleep(1500);
  +      assertEquals(2 * invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2 * invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(invocationCount, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testOneClientOneConnectorOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      log.info("client is connected");
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(1, invocationHandler.callbackHandlers.size()); 
  +      log.info("client added callback handler");
  +      
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      Thread.sleep(100);
  +      assertEquals(3, callbackHandler.callbackCounter);
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker);
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      assertEquals(0, pool.size());
  +      Long usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(3, usedPooled.intValue());
  +      
  +      Thread.sleep(3000);
  +      assertEquals(3, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testOneClientOneConnectorTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +  
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      // Same pool because same address
  +      assertSame(pool, pool2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testOneClientTwoConnectorsOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      log.info("client is connected");
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI1));
  +      client.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("client added callback handlers");
  +      
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      Thread.sleep(100);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      assertTrue(callbackClient1.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker1 = (MicroSocketClientInvoker) callbackClient1.getInvoker();
  +      assertTrue(callbackClient2.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker2 = (MicroSocketClientInvoker) callbackClient2.getInvoker();
  +     
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      assertEquals(2, usedPooled1.intValue());
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      Thread.sleep(3000);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      assertEquals(0, usedPooled1.intValue());
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(3000);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      assertEquals(0, usedPooled1.intValue());
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +  
  +   public void testOneClientTwoConnectorsTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI1));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +  
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsOneConnectorOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client1 = new Client(serverLocator, config);
  +      client1.connect();
  +      Client client2 = new Client(serverLocator, config);
  +      client2.connect();
  +      log.info("clients are connected");
  +      assertTrue(client1.getInvoker() instanceof BisocketClientInvoker);
  +      assertTrue(client2.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client1.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI));
  +      client2.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(1, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      ClientInvoker clientInvoker = callbackClient.getInvoker();
  +      assertTrue(clientInvoker instanceof BisocketClientInvoker);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker);
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      Long usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.longValue());
  + 
  +      client1.invokeOneway(CALLBACK_TEST);
  +      client2.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(2, usedPooled.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      assertEquals(2, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      client1.removeListener(callbackHandler);
  +      client1.disconnect();
  +      client2.removeListener(callbackHandler);
  +      client2.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsOneConnectorTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      // Same pool because same address
  +      assertSame(pool, pool2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsTwoConnectorsOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client1 = new Client(serverLocator, config);
  +      client1.connect();
  +      Client client2 = new Client(serverLocator, config);
  +      client2.connect();
  +      log.info("clients are connected");
  +      assertTrue(client1.getInvoker() instanceof BisocketClientInvoker);
  +      assertTrue(client2.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client1.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI1));
  +      client2.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client1.invokeOneway(CALLBACK_TEST);
  +      client2.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(4, callbackHandler.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(4, callbackHandler.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client1.removeListener(callbackHandler);
  +      client1.disconnect();
  +      client2.removeListener(callbackHandler);
  +      client2.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsTwoConnectorsTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      freePort = PortUtil.findFreePort(host);
  +      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI1));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +   
  +   public void testHearbeat() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      client.invoke(CALLBACK_TEST);
  +      client.invoke(CALLBACK_TEST);
  +      
  +      Thread.sleep(100);
  +      assertEquals(3, callbackHandler.callbackCounter);
  +      
  +      Field field = Client.class.getDeclaredField("callbackConnectors");
  +      field.setAccessible(true);
  +      Map callbackConnectors = (Map) field.get(client);
  +      assertEquals(1, callbackConnectors.size());
  +      Connector callbackConnector = (Connector) callbackConnectors.values().iterator().next();
  +      BisocketServerInvoker invoker = (BisocketServerInvoker) callbackConnector.getServerInvoker();
  +      field = BisocketServerInvoker.class.getDeclaredField("controlConnectionThreadMap");
  +      field.setAccessible(true);
  +      Map controlConnectionThreadMap = (Map) field.get(invoker);
  +      assertEquals(1, controlConnectionThreadMap.size());
  +      Thread t = (Thread) controlConnectionThreadMap.values().iterator().next();
  +      Class[] classes = BisocketServerInvoker.class.getDeclaredClasses();
  +      assertEquals(3, classes.length);
  +      Class invokerClass = null;
  +      for (int i = 0; i < classes.length; i++)
  +      {
  +         log.info(classes[i]);
  +         String fqn = classes[i].getName();
  +         String className = fqn.substring(fqn.lastIndexOf('.') + 1);
  +         log.info(className);
  +         if ("BisocketServerInvoker$ControlConnectionThread".equals(className))
  +         {
  +            invokerClass = classes[i];
  +            break;
  +         }
  +      }
  +      
  +      assertTrue(invokerClass != null);
  +      field = invokerClass.getDeclaredField("lastPing");
  +      field.setAccessible(true);
  +      int pingFrequency = Integer.parseInt(TEST_PING_FREQUENCY_STRING);
  +      Thread.sleep(2 * pingFrequency);
  +      Long lastPing = (Long) field.get(t);
  +      log.info("current: " + System.currentTimeMillis() + ", lastPing: " + lastPing);
  +      assertTrue((System.currentTimeMillis() - lastPing.longValue()) < pingFrequency);
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testControlConnectionFailureServerSide() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(1, callbackHandler.callbackCounter);
  +      
  +      ServerInvoker serverInvoker = connector.getServerInvoker();
  +      assertTrue(serverInvoker instanceof BisocketServerInvoker);
  +      Field field = ServerInvoker.class.getDeclaredField("callbackHandlers");
  +      field.setAccessible(true);
  +      Map callbackHandlers = (Map) field.get(serverInvoker);
  +      assertEquals(1, callbackHandlers.size());
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler;
  +      serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) callbackHandlers.values().toArray()[0]; 
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket controlSocket = (Socket) field.get(clientInvoker);
  +      controlSocket.close();
  +      
  +      Thread.sleep(TEST_PING_FREQUENCY * 2);
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testControlConnectionFailureClientSide() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = "bisocket://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(1, callbackHandler.callbackCounter);
  +      
  +      Field field = Client.class.getDeclaredField("callbackConnectors");
  +      field.setAccessible(true);
  +      Map callbackConnectors = (Map) field.get(client);
  +      assertEquals(1, callbackConnectors.size());
  +      Connector callbackConnector = (Connector) callbackConnectors.values().iterator().next();
  +      BisocketServerInvoker invoker = (BisocketServerInvoker) callbackConnector.getServerInvoker();
  +      field = BisocketServerInvoker.class.getDeclaredField("controlConnectionThreadMap");
  +      field.setAccessible(true);
  +      Map controlConnectionThreadMap = (Map) field.get(invoker);
  +      assertEquals(1, controlConnectionThreadMap.size());
  +      Collection controlConnectionThreads = controlConnectionThreadMap.values();
  +      Thread controlConnectionThread = (Thread) controlConnectionThreads.iterator().next();
  +      Class[] classes = BisocketServerInvoker.class.getDeclaredClasses();
  +      assertEquals(3, classes.length);
  +      Class invokerClass = null;
  +      for (int i = 0; i < classes.length; i++)
  +      {
  +         log.info(classes[i]);
  +         String fqn = classes[i].getName();
  +         String className = fqn.substring(fqn.lastIndexOf('.') + 1);
  +         log.info(className);
  +         if ("BisocketServerInvoker$ControlConnectionThread".equals(className))
  +         {
  +            invokerClass = classes[i];
  +            break;
  +         }
  +      }
  +      
  +      assertTrue(invokerClass != null);
  +      field = invokerClass.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket controlSocket = (Socket) field.get(controlConnectionThread);
  +      controlSocket.close();
  +      
  +      Thread.sleep(TEST_PING_FREQUENCY * 2);
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      Thread newControlConnectionThread = (Thread) controlConnectionThreads.iterator().next();
  +      assertTrue(!controlConnectionThread.equals(newControlConnectionThread));
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public static void main(String[] args)
  +   {
  +      BisocketTestCase testCase = new BisocketTestCase();
  +      try
  +      {
  +         testCase.setUp();
  +         Thread.sleep(600000);
  +         testCase.tearDown();
  +      }
  +      catch(Throwable e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.  When callback client's are registered, will
  +    * generate callbacks periodically.
  +    */
  +   static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +      public Set callbackHandlers = new HashSet();
  +      private int counter = 0;
  +      
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         System.out.println("Adding callback listener.");
  +         callbackHandlers.add(callbackHandler);
  +      }
  +
  +      public Object invoke(InvocationRequest invocation) throws Throwable
  +      {
  +         Object payload = invocation.getParameter();
  +         if (INVOCATION_TEST.equals(payload))
  +         {
  +            Map requestMap = invocation.getRequestPayload();
  +            Integer counter = (Integer) requestMap.get(COUNTER);
  +            return counter;
  +         }
  +         else if (CALLBACK_TEST.equals(payload))
  +         {
  +            try
  +            {
  +               Iterator it = callbackHandlers.iterator();
  +               while (it.hasNext())
  +               {
  +                  InvokerCallbackHandler callbackHandler = (InvokerCallbackHandler) it.next();
  +                  log.info("sending callback: " + ++counter);
  +                  callbackHandler.handleCallback(new Callback("callback"));
  +               }
  +               log.info("sent callback");
  +            }
  +            catch (HandleCallbackException e)
  +            {
  +               log.error("Unable to send callback");
  +            }
  +            return null;
  +         }
  +         else
  +         {
  +            throw new Exception("unrecognized invocation: " + payload);
  +         }
  +      }
  +      
  +      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +      public void setMBeanServer(MBeanServer server) {}
  +      public void setInvoker(ServerInvoker invoker) {}
  +   }
  +   
  +   
  +   static class SimpleCallbackHandler implements InvokerCallbackHandler
  +   {
  +      public int callbackCounter;
  +      private Object lock = new Object();
  +      
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         log.debug("received callback: " + callback.getParameter());
  +         synchronized (lock)
  +         {
  +            callbackCounter++;
  +         }
  +      }
  +   }
  +   
  +   
  +   static class DelayedCallbackHandler implements InvokerCallbackHandler
  +   {
  +      public int callbackCounter;
  +      private Object lock = new Object();
  +      
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         log.debug("received callback: " + callback.getParameter());
  +         synchronized (lock)
  +         {
  +            callbackCounter++;
  +         }
  +         try
  +         {
  +            Thread.sleep(2000);
  +         }
  +         catch (InterruptedException e)
  +         {
  +         }
  +      }
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +148 -0    JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketPerformanceTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPerformanceTestClient.java
  ===================================================================
  RCS file: BisocketPerformanceTestClient.java
  diff -N BisocketPerformanceTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPerformanceTestClient.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,148 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket;
  +
  +import java.net.InetAddress;
  +import java.util.HashMap;
  +
  +import javax.management.MBeanServer;
  +
  +import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class BisocketPerformanceTestClient extends TestCase
  +{
  +   private static Logger log = Logger.getLogger(BisocketPerformanceTestClient.class);
  +   private static String transport = "bisocket";
  +   private static int invocations = 1000;
  +   
  +   
  +   public void testBisocket() throws Throwable
  +   {
  +      String host = InetAddress.getLocalHost().getHostAddress();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = transport + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      System.out.println("Connecting to: " + serverLocator);
  +      Client client = new Client(serverLocator);
  +      client.connect();
  +      System.out.println("client is connected");
  +      InvokerCallbackHandler callbackHandler = new SampleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap(), null, true);
  +      System.out.println("client added callback handler");
  +      
  +      long start = System.currentTimeMillis();
  +      for (int i = 0; i < invocations; i++)
  +      {
  +         client.invoke("test");
  +      }
  +      long finish = System.currentTimeMillis();
  +      System.out.println("time to make " + invocations + " invocations: " + (finish - start));
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   /**
  +    * Can pass transport and port to be used as parameters.
  +    *
  +    * @param args
  +    */
  +   public static void main(String[] args)
  +   {
  +      if(args != null && args.length > 0)
  +      {
  +         transport = args[0];
  +         if (args.length > 1)
  +            invocations = Integer.parseInt(args[1]);
  +      }
  +      BisocketPerformanceTestClient testCase = new BisocketPerformanceTestClient();
  +      try
  +      {
  +         testCase.setUp();
  +         testCase.testBisocket();
  +         Thread.sleep(10000);
  +         testCase.tearDown();
  +         System.out.println("done");
  +      }
  +      catch(Throwable e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.  When callback client's are registered, will
  +    * generate callbacks periodically.
  +    */
  +   static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         System.out.println("Adding callback listener.");
  +         try
  +         {
  +            callbackHandler.handleCallback(new Callback("callback"));
  +         }
  +         catch (HandleCallbackException e)
  +         {
  +            log.error("Unable to send callback");
  +         }
  +      }
  +
  +      public Object invoke(InvocationRequest invocation) throws Throwable {return null;}
  +      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +      public void setMBeanServer(MBeanServer server) {}
  +      public void setInvoker(ServerInvoker invoker) {}
  +   }
  +   
  +   
  +   static class SampleCallbackHandler implements InvokerCallbackHandler
  +   {
  +      int counter;
  +      
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         counter++;
  +         if ((counter + 1) % 1000 == 0)
  +         {
  +            System.out.println("received callback " + (counter + 1));
  +         }
  +      }
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout
	...
Message-ID: <E1Guf4s-0004hI-Qt@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/timeout   
                        Tag: remoting_2_x BisocketTimeoutClientTest.java
                        BisocketTimeoutTestCase.java
                        BisocketTimeoutServerTest.java
  Log:
  JBREM-650:  Unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +36 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/Attic/BisocketTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTimeoutClientTest.java
  ===================================================================
  RCS file: BisocketTimeoutClientTest.java
  diff -N BisocketTimeoutClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTimeoutClientTest.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,36 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.timeout;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.TimeoutClientTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketTimeoutClientTest extends TimeoutClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/Attic/BisocketTimeoutTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTimeoutTestCase.java
  ===================================================================
  RCS file: BisocketTimeoutTestCase.java
  diff -N BisocketTimeoutTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTimeoutTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,38 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.timeout;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketTimeoutTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketTimeoutClientTest.class.getName(),
  +                     1,
  +                     BisocketTimeoutServerTest.class.getName());
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +50 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/Attic/BisocketTimeoutServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTimeoutServerTest.java
  ===================================================================
  RCS file: BisocketTimeoutServerTest.java
  diff -N BisocketTimeoutServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTimeoutServerTest.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,50 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.timeout;
  +
  +import org.jboss.jrunit.extensions.ServerTestCase;
  +import org.jboss.test.remoting.transport.socket.timeout.TimeoutServerTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketTimeoutServerTest extends TimeoutServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   public static void main(String[] args)
  +   {
  +      BisocketTimeoutServerTest server = new BisocketTimeoutServerTest();
  +      try
  +      {
  +         server.setUp();
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration
	...
Message-ID: <E1Guf4s-0004hT-Vq@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/configuration 
                        Tag: remoting_2_x FactoryConfigTestCase.java
  Log:
  JBREM-650:  Unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +47 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration/Attic/FactoryConfigTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCase.java
  ===================================================================
  RCS file: FactoryConfigTestCase.java
  diff -N FactoryConfigTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ FactoryConfigTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  @@ -0,0 +1,47 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + * Copyright 2006, JBoss Inc., and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.configuration;
  +
  +import java.util.Map;
  +
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +import org.jboss.test.remoting.transport.config.FactoryConfigTestCaseParent;
  +
  +/**
  + * 
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + * <p>
  + * Copyright (c) May 20, 2006
  + * </p>
  + */
  +public class FactoryConfigTestCase extends FactoryConfigTestCaseParent
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected void configureServer(Map config)
  +   {
  +      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:36:47 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:36:47 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/asynch ...
Message-ID: <E1GufWh-000599-Qn@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:36:47

  Modified:    src/tests/org/jboss/test/remoting/callback/asynch 
                        AsynchCallbackTestClient.java
  Log:
  JBREM-640:  In asynch callback tests, wait 500 ms instead of 100 ms before checking status.
  
  Revision  Changes    Path
  1.5       +3 -3      JBossRemoting/src/tests/org/jboss/test/remoting/callback/asynch/AsynchCallbackTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsynchCallbackTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/asynch/AsynchCallbackTestClient.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- AsynchCallbackTestClient.java	28 Nov 2006 20:41:38 -0000	1.4
  +++ AsynchCallbackTestClient.java	14 Dec 2006 01:36:47 -0000	1.5
  @@ -34,7 +34,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -88,7 +88,7 @@
         client.addListener(callbackHandler, null, null, true);
         log.info("client added callback handler");
         client.invokeOneway(AsynchCallbackTestServer.ASYNCHRONOUS_CLIENT_SIDE_TEST);
  -      Thread.sleep(100);
  +      Thread.sleep(500);
         // Should have returned.
         Boolean done = (Boolean) client.invoke(AsynchCallbackTestServer.GET_STATUS);
         assertTrue(done.booleanValue());
  @@ -114,7 +114,7 @@
         client.addListener(callbackHandler, null, null, true);
         log.info("client added callback handler");
         client.invokeOneway(AsynchCallbackTestServer.ASYNCHRONOUS_SERVER_SIDE_TEST);
  -      Thread.sleep(100);
  +      Thread.sleep(500);
         // Should have returned.
         Boolean done = (Boolean) client.invoke(AsynchCallbackTestServer.GET_STATUS);
         assertTrue(done.booleanValue());
  
  
  


From ron_sigal at yahoo.com  Wed Dec 13 20:38:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 13 Dec 2006 20:38:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/callback/asynch ...
Message-ID: <E1GufY1-00059R-P4@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/13 20:38:09

  Modified:    src/tests/org/jboss/test/remoting/callback/asynch  Tag:
                        remoting_2_x AsynchCallbackTestClient.java
  Log:
  JBREM-640:  In asynch callback tests, wait 500 ms instead of 100 ms before checking status.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +3 -3      JBossRemoting/src/tests/org/jboss/test/remoting/callback/asynch/AsynchCallbackTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsynchCallbackTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/callback/asynch/AsynchCallbackTestClient.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- AsynchCallbackTestClient.java	28 Nov 2006 20:31:02 -0000	1.1.2.3
  +++ AsynchCallbackTestClient.java	14 Dec 2006 01:38:09 -0000	1.1.2.4
  @@ -34,7 +34,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.3 $
  + * @version $Revision: 1.1.2.4 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -88,7 +88,7 @@
         client.addListener(callbackHandler, null, null, true);
         log.info("client added callback handler");
         client.invokeOneway(AsynchCallbackTestServer.ASYNCHRONOUS_CLIENT_SIDE_TEST);
  -      Thread.sleep(100);
  +      Thread.sleep(500);
         // Should have returned.
         Boolean done = (Boolean) client.invoke(AsynchCallbackTestServer.GET_STATUS);
         assertTrue(done.booleanValue());
  @@ -114,7 +114,7 @@
         client.addListener(callbackHandler, null, null, true);
         log.info("client added callback handler");
         client.invokeOneway(AsynchCallbackTestServer.ASYNCHRONOUS_SERVER_SIDE_TEST);
  -      Thread.sleep(100);
  +      Thread.sleep(500);
         // Should have returned.
         Boolean done = (Boolean) client.invoke(AsynchCallbackTestServer.GET_STATUS);
         assertTrue(done.booleanValue());
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 21:29:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 21:29:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59028 -
	trunk/varia/src/main/org/jboss/tools
Message-ID: <E1GugLN-000699-FB@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-13 21:29:07 -0500 (Wed, 13 Dec 2006)
New Revision: 59028

Modified:
   trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java
Log:
Change the default argument to the a non-ri-home and require -rihome dir to specify a javaee class scan.

Modified: trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java
===================================================================
--- trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java	2006-12-14 00:44:50 UTC (rev 59027)
+++ trunk/varia/src/main/org/jboss/tools/SerialVersionUID.java	2006-12-14 02:29:07 UTC (rev 59028)
@@ -54,6 +54,7 @@
    {
       File[] files = dir.listFiles();
       int count = files != null ? files.length : 0;
+      System.out.println("Checking dir: "+dir+", count="+count);
       for(int n = 0; n < count; n ++)
       {
          File child = files[n];
@@ -91,6 +92,7 @@
             {
                log.fine("Creating ClassVersionInfo for: "+classname);
                ClassVersionInfo cvi = new ClassVersionInfo(classname, cl);
+               log.fine(cvi.toString());
                if( cvi.getSerialVersion() != 0 )
                {
                   ClassVersionInfo prevCVI = (ClassVersionInfo)



From gavin.king at jboss.com  Wed Dec 13 22:12:43 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 13 Dec 2006 22:12:43 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web/WEB-INF/incl     ...
Message-ID: <E1Guh1X-00072t-ID@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/13 22:12:43

  Modified:    examples/dvdstore/web/WEB-INF/incl     cart.xhtml
                        login.xhtml processmenu.xhtml searchbox.xhtml
  Log:
  fix bugs in includes
  
  Revision  Changes    Path
  1.7       +1 -1      jboss-seam/examples/dvdstore/web/WEB-INF/incl/cart.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: cart.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/WEB-INF/incl/cart.xhtml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- cart.xhtml	2 Nov 2006 18:26:04 -0000	1.6
  +++ cart.xhtml	14 Dec 2006 03:12:43 -0000	1.7
  @@ -37,7 +37,7 @@
                   <h:form>
                       <dd>
                           <h:commandButton action="checkout" value="#{messages.checkoutButton}" 
  -                                         class="formButton" style="width: 166px;" />
  +                                         styleClass="formButton" style="width: 166px;" />
                       </dd>
                   </h:form>
               </dl>
  
  
  
  1.7       +3 -5      jboss-seam/examples/dvdstore/web/WEB-INF/incl/login.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: login.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/WEB-INF/incl/login.xhtml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- login.xhtml	2 Nov 2006 18:26:04 -0000	1.6
  +++ login.xhtml	14 Dec 2006 03:12:43 -0000	1.7
  @@ -19,7 +19,7 @@
                               
                               <dd>
                                   <h:commandButton action="#{login.login}" value="#{messages.loginPrompt}"
  -                                                 class="formButton" style="width: 166px;"/>
  +                                                 styleClass="formButton" style="width: 166px;"/>
                               </dd>
                               
                           </dl>
  @@ -43,10 +43,8 @@
                           <dl>
                               <dd>Thank you for choosing the DVD Store</dd>
                               <dd>
  -                                <h:form>
                                       <h:commandButton action="#{login.logout}" value="Logout"
  -                                                     class="formButton" style="width: 166px;"/>
  -                                </h:form>
  +                                                 styleClass="formButton" style="width: 166px;"/>
                               </dd>
                           </dl>
                       </h:form>
  
  
  
  1.8       +1 -1      jboss-seam/examples/dvdstore/web/WEB-INF/incl/processmenu.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: processmenu.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/WEB-INF/incl/processmenu.xhtml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- processmenu.xhtml	12 May 2006 04:56:34 -0000	1.7
  +++ processmenu.xhtml	14 Dec 2006 03:12:43 -0000	1.8
  @@ -19,7 +19,7 @@
                           <dd>
                               <h:commandButton action="#{processDefinitionSwitcher.switchProcess}" 
                                                value="Switch Order Process"
  -                                             class="formButton" style="width: 166px;"/>
  +                                             styleClass="formButton" style="width: 166px;"/>
                           </dd>
                       </dl>
                   </h:form>
  
  
  
  1.7       +1 -1      jboss-seam/examples/dvdstore/web/WEB-INF/incl/searchbox.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: searchbox.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/WEB-INF/incl/searchbox.xhtml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- searchbox.xhtml	2 Nov 2006 18:26:04 -0000	1.6
  +++ searchbox.xhtml	14 Dec 2006 03:12:43 -0000	1.7
  @@ -35,7 +35,7 @@
                       <dd>
                           <h:commandButton action="#{search.doSearch}" 
                                            value="#{messages.searchButton}"
  -                                         class="formButton" style="width: 166px;"/>
  +                                         styleClass="formButton" style="width: 166px;"/>
                       </dd>
                   </dl>
               </h:form>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 23:02:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 23:02:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r59029 - in
	trunk/system/src/main/org/jboss/system/server/profileservice:
	. basic
Message-ID: <E1Guhnj-00082F-33@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-13 23:02:28 -0500 (Wed, 13 Dec 2006)
New Revision: 59029

Added:
   trunk/system/src/main/org/jboss/system/server/profileservice/basic/
   trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java
Removed:
   trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java
Log:
Move the initial ProfileServiceImpl to a basic subpackage

Deleted: trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java	2006-12-14 02:29:07 UTC (rev 59028)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java	2006-12-14 04:02:28 UTC (rev 59029)
@@ -1,126 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.system.server.profileservice;
-
-import java.io.IOException;
-
-import org.jboss.deployers.spi.management.ManagementView;
-import org.jboss.profileservice.spi.NoSuchProfileException;
-import org.jboss.profileservice.spi.Profile;
-import org.jboss.profileservice.spi.ProfileKey;
-import org.jboss.profileservice.spi.ProfileService;
-import org.jboss.system.server.profile.basic.ProfileImpl;
-
-
-/**
- * An initial ProfileService impl for loading server deployments.
- * 
- * @author Scott.Stark at jboss.org
- * @version $Revision$
- */
-public class ProfileServiceImpl
-   implements ProfileService
-{
-   private String name;
-   private String profileRoot;
-   private Profile defaultImpl;
-   private ManagementView mgtView;
-
-   public ProfileServiceImpl(String name) throws IOException
-   {
-      this.name = name;
-      mgtView = new ManagementViewImpl(this);
-   }
-   // Properties ------------------------
-   
-   public String getName()
-   {
-      return this.name;
-   }
-   public void setName(String name)
-   {
-      this.name = name;
-   }
-   public String getProfileRoot()
-   {
-      return this.profileRoot;
-   }
-   public void setProfileRoot(String profileRoot)
-   {
-      this.profileRoot = profileRoot;
-   }
-
-   public void start()
-   {
-      defaultImpl = new ProfileImpl(profileRoot, name);
-   }
-
-   // ProfileService implementation --------------------
-   public String[] getDomains()
-   {
-      String[] domains = {ProfileKey.DEFAULT};
-      return domains;
-   }
-
-   public ProfileKey[] getProfileKeys()
-   {
-      ProfileKey[] keys = {new ProfileKey(null)};
-      return keys;
-   }
-
-   /**
-    * Always returns the default profile.
-    */
-   public Profile getProfile(ProfileKey key)
-      throws NoSuchProfileException
-   {
-      return defaultImpl;
-   }
-
-   public String[] getProfileDeploymentNames(ProfileKey key)
-      throws NoSuchProfileException
-   {
-      String[] names = {"default"};
-      return names;
-   }
-
-   public ManagementView getViewManager()
-   {
-      return mgtView;
-   }
-   public void setViewManager(ManagementView mgtView)
-   {
-      this.mgtView = mgtView;
-   }
-
-   // Admin of profiles @todo could be an option plugin
-   public Profile newProfile(ProfileKey key)
-   {
-      return new ProfileImpl(profileRoot, name);
-   }
-
-   public void removeProfile(ProfileKey key)
-      throws NoSuchProfileException
-   {
-   }
-}
-

Copied: trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java (from rev 59017, trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java)
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceImpl.java	2006-12-13 18:16:51 UTC (rev 59017)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java	2006-12-14 04:02:28 UTC (rev 59029)
@@ -0,0 +1,126 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.system.server.profileservice.basic;
+
+import java.io.IOException;
+
+import org.jboss.deployers.spi.management.ManagementView;
+import org.jboss.profileservice.spi.NoSuchProfileException;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.ProfileService;
+import org.jboss.system.server.profile.basic.ProfileImpl;
+
+
+/**
+ * An basic ProfileService impl for loading server deployments
+ * that uses the basic ProfileImpl.
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class ProfileServiceImpl
+   implements ProfileService
+{
+   private String name;
+   private String profileRoot;
+   private Profile defaultImpl;
+   private ManagementView mgtView;
+
+   public ProfileServiceImpl(String name) throws IOException
+   {
+      this.name = name;
+   }
+   // Properties ------------------------
+   
+   public String getName()
+   {
+      return this.name;
+   }
+   public void setName(String name)
+   {
+      this.name = name;
+   }
+   public String getProfileRoot()
+   {
+      return this.profileRoot;
+   }
+   public void setProfileRoot(String profileRoot)
+   {
+      this.profileRoot = profileRoot;
+   }
+
+   public void start()
+   {
+      defaultImpl = new ProfileImpl(profileRoot, name);
+   }
+
+   // ProfileService implementation --------------------
+   public String[] getDomains()
+   {
+      String[] domains = {ProfileKey.DEFAULT};
+      return domains;
+   }
+
+   public ProfileKey[] getProfileKeys()
+   {
+      ProfileKey[] keys = {new ProfileKey(null)};
+      return keys;
+   }
+
+   /**
+    * Always returns the default profile.
+    */
+   public Profile getProfile(ProfileKey key)
+      throws NoSuchProfileException
+   {
+      return defaultImpl;
+   }
+
+   public String[] getProfileDeploymentNames(ProfileKey key)
+      throws NoSuchProfileException
+   {
+      String[] names = {"default"};
+      return names;
+   }
+
+   public ManagementView getViewManager()
+   {
+      return mgtView;
+   }
+   public void setViewManager(ManagementView mgtView)
+   {
+      this.mgtView = mgtView;
+   }
+
+   // Admin of profiles @todo could be an option plugin
+   public Profile newProfile(ProfileKey key)
+   {
+      return new ProfileImpl(profileRoot, name);
+   }
+
+   public void removeProfile(ProfileKey key)
+      throws NoSuchProfileException
+   {
+   }
+}
+



From jboss-cvs-commits at lists.jboss.org  Wed Dec 13 23:02:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 13 Dec 2006 23:02:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r59030 - trunk/server/src/etc/conf/default
Message-ID: <E1Guho3-00082Y-GQ@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-13 23:02:49 -0500 (Wed, 13 Dec 2006)
New Revision: 59030

Modified:
   trunk/server/src/etc/conf/default/bootstrap-beans.xml
Log:
Move the initial ProfileServiceImpl to a basic subpackage

Modified: trunk/server/src/etc/conf/default/bootstrap-beans.xml
===================================================================
--- trunk/server/src/etc/conf/default/bootstrap-beans.xml	2006-12-14 04:02:28 UTC (rev 59029)
+++ trunk/server/src/etc/conf/default/bootstrap-beans.xml	2006-12-14 04:02:49 UTC (rev 59030)
@@ -6,7 +6,7 @@
 <deployment xmlns="urn:jboss:bean-deployer:2.0">
 
    <!-- The profile service -->
-   <bean name="ProfileService" class="org.jboss.system.server.profileservice.ProfileServiceImpl">
+   <bean name="ProfileService" class="org.jboss.system.server.profileservice.basic.ProfileServiceImpl">
       <constructor>
          <parameter>${jboss.server.name}</parameter>
       </constructor>



From Shane_Bryzak at symantec.com  Wed Dec 13 23:12:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 23:12:21 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace  ...
Message-ID: <E1GuhxF-0008DS-FH@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 23:12:21

  Modified:    examples/seamspace  build.xml
  Log:
  fixed compiler errors in security example
  
  Revision  Changes    Path
  1.6       +1 -0      jboss-seam/examples/seamspace/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/build.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- build.xml	6 Dec 2006 03:24:08 -0000	1.5
  +++ build.xml	14 Dec 2006 04:12:21 -0000	1.6
  @@ -10,6 +10,7 @@
   
       <property name="example.webinf.lib.dir"  value="."/>
       <property name="example.facelets.lib"    value="yes"/>
  +    <property name="example.drools.lib"      value="yes"/>    
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
       <property name="test.classpath"          value="test.eejb.classpath"/>
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 13 23:12:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 23:12:21 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GuhxF-0008Dt-Sb@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 23:12:21

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace  
                        AuthenticatorAction.java Member.java
  Log:
  fixed compiler errors in security example
  
  Revision  Changes    Path
  1.2       +6 -5      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AuthenticatorAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AuthenticatorAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AuthenticatorAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- AuthenticatorAction.java	31 Oct 2006 02:54:36 -0000	1.1
  +++ AuthenticatorAction.java	14 Dec 2006 04:12:21 -0000	1.2
  @@ -5,10 +5,11 @@
   
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.security.Authentication;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
   import org.jboss.seam.security.UsernamePasswordToken;
   import org.jboss.seam.security.provider.AuthenticationProvider;
  +import org.jboss.seam.security.Role;
   
   /**
    * Authenticates the member against the database
  @@ -21,7 +22,7 @@
     @In(create=true)
       private EntityManager entityManager;
   
  -  public Authentication authenticate(Authentication authentication)
  +  public Identity authenticate(Identity authentication)
         throws AuthenticationException
     {
       try
  @@ -32,10 +33,10 @@
             .setParameter("password", authentication.getCredentials())
             .getSingleResult();
   
  -      String[] roles = new String[member.getRoles().size()];
  +      Role[] roles = new Role[member.getRoles().size()];
         int idx = 0;
  -      for (Role role : member.getRoles())
  -        roles[idx++] = role.getName();
  +      for (MemberRole mr : member.getRoles())
  +        roles[idx++] = new Role(mr.getName());
   
         return new UsernamePasswordToken(authentication.getPrincipal(),
                                          authentication.getCredentials(), roles);
  
  
  
  1.5       +3 -9      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Member.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- Member.java	9 Nov 2006 00:48:41 -0000	1.4
  +++ Member.java	14 Dec 2006 04:12:21 -0000	1.5
  @@ -7,8 +7,6 @@
   import javax.persistence.JoinTable;
   import javax.persistence.ManyToMany;
   
  -import org.jboss.seam.annotations.security.AclProvider;
  -import org.jboss.seam.annotations.security.DefinePermissions;
   import org.jboss.seam.annotations.Name;
   
   /**
  @@ -18,17 +16,13 @@
    */
   @Entity
   @Name("member")
  - at DefinePermissions(permissions = {
  -  @AclProvider(action = "update", provider = "persistentAclProvider", mask = 0x0002),
  -  @AclProvider(action = "delete", provider = "persistentAclProvider", mask = 0x0004)
  -})
   public class Member implements Serializable
   {
     private Integer memberId;
     private String username;
     private String password;
   
  -  private Set<Role> roles;
  +  private Set<MemberRole> roles;
   
     @Id
     public Integer getMemberId()
  @@ -63,12 +57,12 @@
   
     @ManyToMany
     @JoinTable(name = "MemberRoles")
  -  public Set<Role> getRoles()
  +  public Set<MemberRole> getRoles()
     {
       return roles;
     }
   
  -  public void setRoles(Set<Role> roles)
  +  public void setRoles(Set<MemberRole> roles)
     {
       this.roles = roles;
     }
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 13 23:12:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 23:12:21 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF  ...
Message-ID: <E1GuhxF-0008DZ-Kc@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 23:12:21

  Modified:    examples/seamspace/resources/META-INF  application.xml
  Log:
  fixed compiler errors in security example
  
  Revision  Changes    Path
  1.4       +25 -13    jboss-seam/examples/seamspace/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/application.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- application.xml	6 Dec 2006 03:24:08 -0000	1.3
  +++ application.xml	14 Dec 2006 04:12:21 -0000	1.4
  @@ -12,17 +12,29 @@
   			<context-root>/seam-space</context-root>
   		</web>
   	</module>
  +	
   	<module>
   		<ejb>seam-space.jar</ejb>
   	</module>
  +	
   	<module>
   	    <java>jboss-seam.jar</java>
   	</module>
  +	
       <module>
           <java>el-api.jar</java>
       </module>
  +
       <module>
           <java>el-ri.jar</java>
       </module>
   
  +  <module>
  +    <java>drools-compiler-3.0.5.jar</java>
  +	</module>
  +
  +  <module>
  +	  <java>drools-core-3.0.5.jar</java>
  +	</module>    
  +
   </application>
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 13 23:12:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 13 Dec 2006 23:12:21 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF   ...
Message-ID: <E1GuhxF-0008Dj-OD@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/13 23:12:21

  Modified:    examples/seamspace/resources/WEB-INF   components.xml
                        web.xml
  Log:
  fixed compiler errors in security example
  
  Revision  Changes    Path
  1.7       +12 -8     jboss-seam/examples/seamspace/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/components.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- components.xml	10 Nov 2006 19:07:57 -0000	1.6
  +++ components.xml	14 Dec 2006 04:12:21 -0000	1.7
  @@ -21,7 +21,7 @@
         <property name="providers">#{authenticatorAction}</property>
       </component>
       
  -    <component name="persistentAclProvider" class="org.jboss.seam.security.acl.PersistentAclProvider">
  +    <!--component name="persistentAclProvider" class="org.jboss.seam.security.acl.PersistentAclProvider">
         <property name="aclQuery">
           select p.mask, p.recipient, p.recipientType from AclPermission p
           where p.identity.objectIdentity = :identity
  @@ -29,10 +29,14 @@
         
         <property name="persistenceContextManager">#{entityManager}</property>      
         
  +    </component-->
  +
  +    <component name="org.jboss.seam.securityManager">
  +    
       </component>
   
  -    <!--component class="org.jboss.seam.security.SeamSecurityManager">
  +    <component name="org.jboss.seam.security.securityConfiguration">
       
  -    </component-->
  +    </component>
           
   </components>
  \ No newline at end of file
  
  
  
  1.3       +10 -0     jboss-seam/examples/seamspace/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/web.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- web.xml	5 Dec 2006 23:19:44 -0000	1.2
  +++ web.xml	14 Dec 2006 04:12:21 -0000	1.3
  @@ -24,6 +24,16 @@
           <url-pattern>*.seam</url-pattern>
       </filter-mapping>
   
  +    <filter>
  +      <filter-name>Seam Security Filter</filter-name>
  +      <filter-class>org.jboss.seam.security.filter.SeamSecurityFilter</filter-class>
  +    </filter>
  +    
  +    <filter-mapping>
  +      <filter-name>Seam Security Filter</filter-name>
  +      <url-pattern>*.seam</url-pattern>
  +    </filter-mapping>
  +
       <!-- MyFaces -->
   
       <listener>
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 14 00:18:58 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 00:18:58 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1Guizi-0000zs-Jl@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 00:18:58

  Added:       examples/seamspace/src/org/jboss/seam/example/seamspace  
                        MemberRole.java
  Removed:     examples/seamspace/src/org/jboss/seam/example/seamspace  
                        Role.java
  Log:
  renamed Role to MemberRole
  
  Revision  Changes    Path
  1.1      date: 2006/12/14 05:18:58;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java
  
  Index: MemberRole.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import java.io.Serializable;
  import javax.persistence.Entity;
  import javax.persistence.Id;
  
  import org.jboss.seam.annotations.Name;
  
  /**
   * Represents a security role.
   *
   * @author Shane Bryzak
   */
  @Entity
  @Name("role")
  public class MemberRole implements Serializable
  {
    private Integer roleId;
    private String name;
  
    @Id
    public Integer getRoleId()
    {
      return roleId;
    }
  
    public void setRoleId(Integer roleId)
    {
      this.roleId = roleId;
    }
  
    public String getName()
    {
      return name;
    }
  
    public void setName(String name)
    {
      this.name = name;
    }
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 00:22:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 00:22:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59031 -
	trunk/system/src/main/org/jboss/profileservice/spi
Message-ID: <E1Guj2n-00013t-39@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-14 00:22:07 -0500 (Thu, 14 Dec 2006)
New Revision: 59031

Modified:
   trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java
Log:
Add the domain, server, name accessors

Modified: trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java	2006-12-14 04:02:49 UTC (rev 59030)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ProfileKey.java	2006-12-14 05:22:07 UTC (rev 59031)
@@ -3,10 +3,10 @@
 import java.io.Serializable;
 
 /**
- * The key for a Profile. It consists fo the domain, server and name.
+ * The key for a Profile. It consists of the domain, server and name.
  * 
  * @author Scott.Stark at jboss.org
- * @version $Revision$
+ * @version $Revision:$
  */
 public class ProfileKey
    implements Comparable, Serializable
@@ -52,6 +52,33 @@
       this.name = name;
    }
 
+   public String getName()
+   {
+      return name;
+   }
+   public void setName(String name)
+   {
+      this.name = name;
+   }
+
+   public String getDomain()
+   {
+      return domain;
+   }
+   public void setDomain(String domain)
+   {
+      this.domain = domain;
+   }
+
+   public String getServer()
+   {
+      return server;
+   }
+   public void setServer(String server)
+   {
+      this.server = server;
+   }
+
    /**
     * Compare based on domain, then server and finally name.
     * 
@@ -82,4 +109,18 @@
       int hash = domain.hashCode() + server.hashCode() + name.hashCode();
       return hash;
    }
+
+   public String toString()
+   {
+      StringBuilder tmp = new StringBuilder(super.toString());
+      tmp.append('[');
+      tmp.append("domain=");
+      tmp.append(domain);
+      tmp.append(",server=");
+      tmp.append(server);
+      tmp.append(",name=");
+      tmp.append(name);
+      tmp.append(']');
+      return tmp.toString();
+   }
 }



From Shane_Bryzak at symantec.com  Thu Dec 14 00:39:34 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 00:39:34 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GujJe-0001KK-W8@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 00:39:34

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  added @Startup to security components
  
  Revision  Changes    Path
  1.25      +16 -5     jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- SeamSecurityManager.java	13 Dec 2006 01:52:30 -0000	1.24
  +++ SeamSecurityManager.java	14 Dec 2006 05:39:34 -0000	1.25
  @@ -1,5 +1,6 @@
   package org.jboss.seam.security;
   
  +import java.io.InputStream;
   import java.io.InputStreamReader;
   import java.security.acl.Permission;
   import java.util.ArrayList;
  @@ -8,6 +9,8 @@
   import java.util.Map;
   import java.util.Set;
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   import org.drools.FactHandle;
   import org.drools.RuleBase;
   import org.drools.RuleBaseFactory;
  @@ -24,6 +27,7 @@
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  +import org.jboss.seam.annotations.Startup;
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions;
  @@ -35,6 +39,7 @@
    *
    * @author Shane Bryzak
    */
  + at Startup(depends="org.jboss.seam.security.securityConfiguration")
   @Scope(APPLICATION)
   @Name("org.jboss.seam.securityManager")
   @Install(value = false, precedence=BUILT_IN)
  @@ -45,6 +50,8 @@
   
     private static final String SECURITY_CONTEXT_NAME = "org.jboss.seam.security.securityContext";
   
  +  private static final Log log = LogFactory.getLog(SeamSecurityManager.class);
  +
     private RuleBase securityRules;
   
     /**
  @@ -65,13 +72,17 @@
       PackageBuilderConfiguration conf = new PackageBuilderConfiguration();
       conf.setCompiler(PackageBuilderConfiguration.JANINO);
   
  -    PackageBuilder builder = new PackageBuilder(conf);
  -    builder.addPackageFromDrl(new InputStreamReader(
  -        Resources.getResourceAsStream(SECURITY_RULES_FILENAME)));
  -
       securityRules = RuleBaseFactory.newRuleBase();
  +    InputStream in = Resources.getResourceAsStream(SECURITY_RULES_FILENAME);
  +    if (in != null)
  +    {
  +      PackageBuilder builder = new PackageBuilder(conf);
  +      builder.addPackageFromDrl(new InputStreamReader(in));
       securityRules.addPackage(builder.getPackage());
     }
  +    else
  +      log.warn(String.format("Security rules file %s not found", SECURITY_RULES_FILENAME));
  +  }
   
     /**
      * Returns the application-scoped instance of the security manager
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 14 00:39:35 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 00:39:35 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1GujJf-0001KR-44@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 00:39:35

  Modified:    src/main/org/jboss/seam/security/config 
                        SecurityConfiguration.java
  Log:
  added @Startup to security components
  
  Revision  Changes    Path
  1.3       +11 -1     jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SecurityConfiguration.java	13 Dec 2006 05:08:53 -0000	1.2
  +++ SecurityConfiguration.java	14 Dec 2006 05:39:35 -0000	1.3
  @@ -7,6 +7,8 @@
   import java.util.Map;
   import java.util.Set;
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  @@ -18,6 +20,7 @@
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  +import org.jboss.seam.annotations.Startup;
   import org.jboss.seam.security.Role;
   import org.jboss.seam.security.SeamPermission;
   import org.jboss.seam.util.Resources;
  @@ -27,6 +30,7 @@
    *
    * @author Shane Bryzak
    */
  + at Startup
   @Scope(APPLICATION)
   @Name("org.jboss.seam.security.securityConfiguration")
   @Install(value = false, precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
  @@ -35,6 +39,8 @@
   {
     private static final String SECURITY_CONFIG_FILENAME = "/META-INF/security-config.xml";
   
  +  private static final Log log = LogFactory.getLog(SecurityConfiguration.class);
  +
     // <security-constraint>
   //  private static final String SECURITY_CONSTRAINT = "security-constraint";
   //  private static final String WEB_RESOURCE_COLLECTION = "web-resource-collection";
  @@ -77,7 +83,11 @@
     public void init()
         throws SecurityConfigException
     {
  -    loadConfigFromStream(Resources.getResourceAsStream(SECURITY_CONFIG_FILENAME));
  +    InputStream in = Resources.getResourceAsStream(SECURITY_CONFIG_FILENAME);
  +    if (in != null)
  +      loadConfigFromStream(in);
  +    else
  +      log.warn(String.format("Security configuration file %s not found", SECURITY_CONFIG_FILENAME));
     }
   
     /**
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 14 00:39:35 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 00:39:35 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/filter  ...
Message-ID: <E1GujJf-0001KY-9D@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 00:39:35

  Modified:    src/main/org/jboss/seam/security/filter 
                        SeamSecurityFilter.java
  Log:
  added @Startup to security components
  
  Revision  Changes    Path
  1.12      +7 -12     jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SeamSecurityFilter.java	4 Dec 2006 01:06:51 -0000	1.11
  +++ SeamSecurityFilter.java	14 Dec 2006 05:39:35 -0000	1.12
  @@ -10,6 +10,8 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.security.config.SecurityConfiguration;
  +import org.jboss.seam.contexts.WebApplicationContext;
   
   /**
    * A servlet filter that performs authentication within a Seam application.
  @@ -20,26 +22,19 @@
   {
     private static final Log log = LogFactory.getLog(SeamSecurityFilter.class);
   
  -//  private static final String CONFIG_RESOURCE = "/WEB-INF/seam-security.xml";
  -
     public void init(FilterConfig config)
         throws ServletException
     {
   
   //    try
   //    {
  -      /** @todo beginInitialization is the closest method we have to initialise the application context */
  -//      Lifecycle.beginInitialization(servletContext);
  +      WebApplicationContext ctx = new WebApplicationContext(config.getServletContext());
   
  -//      SecurityConfig.instance().setApplicationContext(
  -//          Contexts.getApplicationContext());
  +      SecurityConfiguration sc = (SecurityConfiguration) ctx.get(
  +          SecurityConfiguration.class);
  +
  +      log.info("**** SecurityConfiguration **** : " + sc);
   
  -//      if (Authenticator.instance() == null)
  -//        throw new ServletException("No Authenticator configured.");
  -//    }
  -//    finally
  -//    {
  -      /** @todo clear the application context */
   //    }
   
   //    try
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 14 00:39:35 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 00:39:35 -0500
Subject: [jboss-cvs] jboss-seam/src/test/misc/org/jboss/seam/test  ...
Message-ID: <E1GujJf-0001Kf-EI@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 00:39:35

  Modified:    src/test/misc/org/jboss/seam/test  SecurityTest.java
  Log:
  added @Startup to security components
  
  Revision  Changes    Path
  1.12      +1 -2      jboss-seam/src/test/misc/org/jboss/seam/test/SecurityTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/SecurityTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SecurityTest.java	13 Dec 2006 01:52:30 -0000	1.11
  +++ SecurityTest.java	14 Dec 2006 05:39:35 -0000	1.12
  @@ -4,11 +4,10 @@
   import java.io.InputStream;
   
   import org.jboss.seam.security.Role;
  +import org.jboss.seam.security.SeamPermission;
   import org.jboss.seam.security.config.SecurityConfigException;
   import org.jboss.seam.security.config.SecurityConfiguration;
   import org.testng.annotations.Test;
  -import org.jboss.seam.security.SeamPermission;
  -import java.util.Enumeration;
   
   public class SecurityTest
   {
  
  
  


From forge-admin at jboss.com  Thu Dec 14 01:00:30 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Thu, 14 Dec 2006 01:00:30 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gujdu-0001eA-2Z@committer01.frg.pub.inap.atl.jboss.com>

Commit from myuan (2006-12-13 01:10 EST)
-----------------

css support for the s:selectDate tag

  jboss-seam  examples/jpa/view/template.xhtml  1.4
+ jboss-seam  examples/jpa/view/css/date.css    1.1
  jboss-seam  examples/jpa/view/css/screen.css  1.3


Commit from myuan (2006-12-13 01:26 EST)
-----------------

css update for s:selectDate

  jboss-seam  examples/hibernate2/view/template.xhtml            1.4
+ jboss-seam  examples/hibernate2/view/css/date.css              1.1
  jboss-seam  examples/hibernate2/view/css/screen.css            1.3
+ jboss-seam  examples/hibernate2/view/css/trailblazer_main.css  1.1


Commit from myuan (2006-12-13 01:33 EST)
-----------------

css support for s:selectDate

  jboss-seam  examples/glassfish/view/template.xhtml  1.2
+ jboss-seam  examples/glassfish/view/css/date.css    1.1
  jboss-seam  examples/glassfish/view/css/screen.css  1.2


Commit from gavin (2006-12-13 05:09 EST)
-----------------

better dirtychecking

  jboss-seam  src/main/org/jboss/seam/contexts/EntityBean.java  1.3


Commit from gavin (2006-12-13 05:10 EST)
-----------------

GA

  jboss-seam  src/main/org/jboss/seam/servlet/SeamListener.java  1.19
  jboss-seam  doc/reference/en/master.xml                        1.46
  jboss-seam  build.xml                                          1.121
  jboss-seam  readme.txt                                         1.26
  jboss-seam  changelog.txt                                      1.32


Commit from tokada on branch JBossProfiler_Expansion (2006-12-13 05:11 EST)
----------------------------------------------------

Corrected some bugs.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/util/HierarchicalMap.java                   1.1.2.2
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/collector/ThreadMetricCollector.java  1.1.2.4
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/collector/CollectorConfig.java        1.1.2.2


Commit from tokada on branch JBossProfiler_Expansion (2006-12-13 05:13 EST)
----------------------------------------------------

Added some functions.

  jboss-profiler  java/webapp/lzx/notifygridtext.lzx          1.1.2.3
  jboss-profiler  java/webapp/lzx/stacktracediagram.lzx       1.1.2.3
  jboss-profiler  java/webapp/lzx/httprequeststatistics.lzx   1.1.2.3
  jboss-profiler  java/webapp/lzx/dataaccessstatistics.lzx    1.1.2.4
  jboss-profiler  java/webapp/lzx/webapplicationanalyzer.lzx  1.1.2.3


Commit from gavin (2006-12-13 05:17 EST)
-----------------

JBSEAM-549

  jboss-seam  src/main/org/jboss/seam/core/Manager.java  1.124


Commit from gavin (2006-12-13 06:06 EST)
-----------------

note more efficient impl

  jboss-seam  doc/reference/en/modules/concepts.xml  1.45


Commit from gavin (2006-12-13 06:07 EST)
-----------------

note more efficient impl

  jboss-seam  doc/reference/en/modules/concepts.xml  1.46


Commit from gavin (2006-12-13 06:20 EST)
-----------------

date

  jboss-seam  changelog.txt  1.33


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-13 08:32 EST)
------------------------------------------------------

recycle queue should use the same capacity as the eviction queue - NOT the default 1024

  JBossCache  src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java        1.11.2.1
  JBossCache  tests/functional/org/jboss/cache/aop/LocalConcurrentTest.java  1.8.2.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-13 11:01 EST)
------------------------------------------------------

optimisations on casting nodes.

  JBossCache  src/org/jboss/cache/TreeCache.java                                1.195.2.34
  JBossCache  src/org/jboss/cache/Node.java                                     1.38.2.3
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.20.2.7


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-13 11:05 EST)
------------------------------------------------------

Updated for 1.4.1.CR1

  JBossCache  src/org/jboss/cache/Version.java  1.18.2.6
  JBossCache  build.xml                         1.119.2.17
  JBossCache  docs/Changelog.txt                1.20.2.6


Commit from gavin (2006-12-13 11:38 EST)
-----------------

upgraded ajax4jsf to 1.0.4 maintenance release 2

  jboss-seam  examples/jpa/lib/ajax4jsf.jar                        1.2
  jboss-seam  examples/glassfish/lib/ajax4jsf.jar                  1.2
  jboss-seam  examples/booking/resources/WEB-INF/lib/ajax4jsf.jar  1.5
  jboss-seam  examples/hibernate2/lib/ajax4jsf.jar                 1.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-13 12:59 EST)
------------------------------------------------------

Updated for 1.4.1.CR1

  JBossCache  src/org/jboss/cache/Version.java  1.18.2.7


Commit from msurtani (2006-12-13 13:00 EST)
--------------------

added code name to printout

  JBossCache  src/org/jboss/cache/Version.java  1.24


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-13 13:07 EST)
------------------------------------------------------

Added further tests

  JBossCache  tests/functional/org/jboss/cache/options/FailSilentlyTest.java  1.2.4.1


Commit from msurtani (2006-12-13 13:15 EST)
--------------------

added tests

  JBossCache  tests/functional/org/jboss/cache/options/FailSilentlyTest.java  1.6


Commit from rawb (2006-12-13 13:30 EST)
----------------

Added another extension point to allow actions to be added to the outline view for xml elements. This was done so that the mbeans project does not directly depend on as.ui, and as.ui can extend as.ui.mbeans.

Not that this matters much.

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/ServiceXMLOutlineConfiguration.java              1.2
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/schema/ServiceXMLOutlineMenuProvider.exsd                                                       1.1
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/plugin.xml                                                                                      1.3
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui.mbeans/src/org/jboss/ide/eclipse/as/ui/mbeans/editors/proposals/IServiceXMLOutlineActionProvider.java  1.1


Commit from rawb (2006-12-13 13:32 EST)
----------------

Allowed a mechanism so that if an image path is not given via extension point, the implementing view provider can use one from another location, presumably a shared image from the platform, or wherever it chooses.

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/ServerViewProvider.java        1.3
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java  1.3


Commit from rawb (2006-12-13 13:32 EST)
----------------

Brand spankin new extension... allows you to browse folders on your HD quickly, set filters, etc

+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java  1.1


Commit from rawb (2006-12-13 13:33 EST)
----------------

Null check

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java  1.2


Commit from rawb (2006-12-13 13:34 EST)
----------------

New View Provider extension (filesets)

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/META-INF/MANIFEST.MF  1.13
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml            1.28


Commit from rawb (2006-12-13 13:35 EST)
----------------

Some .toOSString action for my folder paths

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServer.java  1.17


Commit from rawb (2006-12-13 13:35 EST)
----------------

New publisher based off Marshall's packaging, new build listener in case I want to use it

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java  1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/PackagesBuildListener.java      1.3


Commit from starksm (2006-12-13 16:31 EST)
-------------------

Include the jbossweb-src.zip artifact

  repository.jboss.com  jboss/web/2.0.0.snapshot/component-info.xml  1.8


Commit from rawb (2006-12-13 16:48 EST)
----------------

refresh action added

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java  1.3


Commit from adrian (2006-12-13 18:18 EST)
------------------

Temporary snapshot for MC/AOP metadata integration

+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/component-info.xml                 1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int-boot.jar      1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int-deployer.jar  1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int-src.zip       1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-aop-mc-int.jar           1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-container-src.zip        1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-container.jar            1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-dependency-src.zip       1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-dependency.jar           1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-deployers-src.zip        1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-deployers.jar            1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-microcontainer-src.zip   1.1
+ repository.jboss.com  jboss/microcontainer/snapshot-metadata/lib/jboss-microcontainer.jar       1.1
+ repository.jboss.com  jboss/aop/snapshot-metadata/component-info.xml                            1.1
+ repository.jboss.com  jboss/aop/snapshot-metadata/lib/jboss-aop-jdk50-client.jar                1.1
+ repository.jboss.com  jboss/aop/snapshot-metadata/lib/jboss-aop-jdk50.jar                       1.1
+ repository.jboss.com  jboss/aop/snapshot-metadata/lib/jdk14-pluggable-instrumentor.jar          1.1
+ repository.jboss.com  jboss/aop/snapshot-metadata/lib/pluggable-instrumentor.jar                1.1


Commit from adrian (2006-12-13 18:42 EST)
------------------

Include the jrocket instrumentor rather than jdk14

+ repository.jboss.com  jboss/aop/snapshot-metadata/lib/jrockit-pluggable-instrumentor.jar  1.1
- repository.jboss.com  jboss/aop/snapshot-metadata/lib/jdk14-pluggable-instrumentor.jar    1.2


Commit from genman (2006-12-13 18:57 EST)
------------------

use Commons Logging not Log4j

  JBossCache  src-50/org/jboss/cache/pojo/memory/PersistentReference.java  1.3


Commit from genman (2006-12-13 19:04 EST)
------------------

fix PNG -> png

- JBossCache  docs/tutorial-pojo/en/images/demoAddress.PNG          1.2
- JBossCache  docs/tutorial-pojo/en/images/demoAddressInternal.PNG  1.2
- JBossCache  docs/tutorial-pojo/en/images/demoJoe.PNG              1.2


Commit from genman (2006-12-13 19:25 EST)
------------------

Fix the Eclipse classpath

  JBossCache  .classpath  1.13


Commit from rsigal on branch remoting_2_x (2006-12-13 19:58 EST)
-----------------------------------------

JBREM-650: (1) Create copy of configuration map in constructors, and (2) pass configuration to callback Connector.

  JBossRemoting  src/main/org/jboss/remoting/Client.java  1.53.2.11


Commit from rsigal on branch remoting_2_x (2006-12-13 20:00 EST)
-----------------------------------------

JBREM-650:  Made handleInternalInvocation() protected.

  JBossRemoting  src/main/org/jboss/remoting/ServerInvoker.java  1.52.2.5


Commit from rsigal on branch remoting_2_x (2006-12-13 20:02 EST)
-----------------------------------------

JBREM-650: In init() pass metadata to callback Client.

  JBossRemoting  src/main/org/jboss/remoting/callback/ServerInvokerCallbackHandler.java  1.15.2.5


Commit from rsigal on branch remoting_2_x (2006-12-13 20:03 EST)
-----------------------------------------

JBREM-650: Introducing bisocket transport.

+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java   1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java   1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/TransportClientFactory.java  1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/TransportServerFactory.java  1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/Bisocket.java                1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-13 20:04 EST)
-----------------------------------------

JBREM-650: Made serverSocketClass protected.

  JBossRemoting  src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java  1.30.2.3


Commit from rsigal on branch remoting_2_x (2006-12-13 20:07 EST)
-----------------------------------------

JBREM-650: Made locatorURI and connector protected.

  JBossRemoting  src/tests/org/jboss/test/remoting/callback/CallbackTestServer.java  1.7.4.1


Commit from rsigal on branch remoting_2_x (2006-12-13 20:08 EST)
-----------------------------------------

JBREM-650:  Unit tests for bisocket transport.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/load/BisocketPooledConnectionTestCase.java               1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/load/BisocketSocketLoadTestCase.java                     1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutTestServer.java  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutClientTest.java  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutTestCase.java    1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutTestServer.java          1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutTestCase.java            1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutClientTest.java          1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestServer.java                       1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java                                    1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestClient.java                       1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/stress/BisocketInvokerClientTest.java                    1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/stress/BisocketInvokerServerTest.java                    1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/stress/readme.txt                                        1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutClientTest.java                   1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutTestCase.java                     1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutServerTest.java                   1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/configuration/FactoryConfigTestCase.java                 1.1.2.1


Commit from rsigal (2006-12-13 20:36 EST)
------------------

JBREM-640:  In asynch callback tests, wait 500 ms instead of 100 ms before checking status.

  JBossRemoting  src/tests/org/jboss/test/remoting/callback/asynch/AsynchCallbackTestClient.java  1.5


Commit from rsigal on branch remoting_2_x (2006-12-13 20:38 EST)
-----------------------------------------

JBREM-640:  In asynch callback tests, wait 500 ms instead of 100 ms before checking status.

  JBossRemoting  src/tests/org/jboss/test/remoting/callback/asynch/AsynchCallbackTestClient.java  1.1.2.4


Commit from gavin (2006-12-13 22:12 EST)
-----------------

fix bugs in includes

  jboss-seam  examples/dvdstore/web/WEB-INF/incl/cart.xhtml         1.7
  jboss-seam  examples/dvdstore/web/WEB-INF/incl/login.xhtml        1.7
  jboss-seam  examples/dvdstore/web/WEB-INF/incl/processmenu.xhtml  1.8
  jboss-seam  examples/dvdstore/web/WEB-INF/incl/searchbox.xhtml    1.7


Commit from sbryzak2 (2006-12-13 23:12 EST)
--------------------

fixed compiler errors in security example

  jboss-seam  examples/seamspace/build.xml                                                      1.6
  jboss-seam  examples/seamspace/resources/META-INF/application.xml                             1.4
  jboss-seam  examples/seamspace/resources/WEB-INF/components.xml                               1.7
  jboss-seam  examples/seamspace/resources/WEB-INF/web.xml                                      1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/AuthenticatorAction.java  1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java               1.5


Commit from sbryzak2 (2006-12-14 00:18 EST)
--------------------

renamed Role to MemberRole

+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java  1.1
- jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Role.java        1.2


Commit from sbryzak2 (2006-12-14 00:39 EST)
--------------------

added @Startup to security components

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java           1.25
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java  1.3
  jboss-seam  src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java     1.12
  jboss-seam  src/test/misc/org/jboss/seam/test/SecurityTest.java                 1.12
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061214/ef395222/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 01:09:59 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 01:09:59 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1787 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/state src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/etc tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gujn5-0001zR-Rf@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 01:09:44 -0500 (Thu, 14 Dec 2006)
New Revision: 1787

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
   trunk/tests/etc/log4j.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Refactoring, better logging.


Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -117,10 +117,12 @@
       if (delegates == null)
       {
          // not clustered, pass the invocation through
+         if(trace) { log.trace(this + " detecting non-clustered connection creation request, letting it pass through"); }
+
          return invocation.invokeNext();
       }
 
-      // clustered
+      // clustered, stopping the invocation here and re-send it as non-clustered down the stack
 
       // TODO: this should be in loop while we get exceptions creating connections, always trying
       //       the next Delegate when we get an exception.
@@ -130,15 +132,29 @@
 
       ClientConnectionFactoryDelegate cfDelegate = getDelegateRoundRobin();
 
+      if(trace) { log.trace(this + " detecting clustered connection creation request, choosing " + cfDelegate + " as target"); }
+
       // Now create a connection delegate for this
 
       MethodInvocation mi = (MethodInvocation)invocation;
       String username = (String)mi.getArguments()[0];
       String password = (String)mi.getArguments()[1];
 
-      ClientConnectionDelegate cd = createConnection(cfDelegate, username, password);
+      CreateConnectionResult res = (CreateConnectionResult)cfDelegate.
+         createConnectionDelegate(username, password, -1);
 
-      return new CreateConnectionResult(cd);
+      ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
+
+      if(trace) { log.trace(this + " got local connection delegate " + cd); }
+
+      // Add a connection listener to detect failure
+
+      ConnectionListener listener = new ConnectionFailureListener(cd);
+      ConnectionState state = (ConnectionState)((DelegateSupport)cd).getState();
+      if(trace) { log.trace(this + " registering " + listener + " on " + cd); }
+      state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
+
+      return new CreateConnectionResult(cd); 
    }
 
    public String toString()
@@ -204,25 +220,6 @@
       return currentDelegate;
    }
 
-   private ClientConnectionDelegate createConnection(ClientConnectionFactoryDelegate cfd,
-                                                     String username,
-                                                     String password)
-      throws Exception
-   {
-      CreateConnectionResult res =
-         (CreateConnectionResult)cfd.createConnectionDelegate(username, password, -1);
-
-      ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
-
-      // Add a connection listener to detect failure
-
-      ConnectionListener listener = new ConnectionFailureListener(cd);
-      ConnectionState state = (ConnectionState)((DelegateSupport)cd).getState();
-      state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
-
-      return cd;
-   }
-
    /**
     * @return a failover ClientConnectionFactoryDelegate or null if a suitable delegate cannot be
     *         found.
@@ -235,7 +232,7 @@
 
       for (int i = 0; i < delegates.length; i++)
       {
-         if (delegates[i].getServerId() == failoverServerID.intValue())
+         if (delegates[i].getServerID() == failoverServerID.intValue())
          {
             return delegates[i];
          }
@@ -251,7 +248,7 @@
 
       int failedServerID = failedConnState.getServerID();
 
-      log.debug(this + " handling failure on connection to node " + failedServerID);
+      log.debug(this + " handling failed connection to node " + failedServerID);
 
       // Get the default connection factory delegate we are going to failover onto
 
@@ -308,7 +305,7 @@
 
          for (int i = 0; i < delegates.length; i++)
          {
-            if (delegates[i].getServerId() == actualServerID)
+            if (delegates[i].getServerID() == actualServerID)
             {
                failoverDelegate = delegates[i];
                continue outer;

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -45,6 +45,7 @@
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
+import org.jboss.logging.Logger;
 
 /**
  * Maintains the hierarchy of parent and child state objects. For each delegate, this interceptor
@@ -55,22 +56,26 @@
  * 
  * This interceptor is PER_VM.
  * 
- * @author <a href="mailto:tim.fox at jboss.com>Tim Fox</a>
- * @author <a href="mailto:ovidiu at jboss.org>Ovidiu Feodorov</a>
- * @author <a href="mailto:clebert.suconic at jboss.org>Clebert Suconic</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  *
  * $Id$
  */
 public class StateCreationAspect
 {
    // Constants -----------------------------------------------------
-   
+
+   private static final Logger log = Logger.getLogger(StateCreationAspect.class);
+
    // Attributes ----------------------------------------------------
-   
+
+   private boolean trace = log.isTraceEnabled();
+
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
-   
+
    // Public --------------------------------------------------------
 
    // Interceptor implementation -----------------------------------
@@ -78,72 +83,68 @@
    public Object handleCreateConnectionDelegate(Invocation inv) throws Throwable
    {
       ConnectionFactoryDelegate cfd = (ConnectionFactoryDelegate)inv.getTargetObject();
-      
+
       CreateConnectionResult res = (CreateConnectionResult)inv.invokeNext();
-      
+
+      if(trace) { log.trace("got " + res + " on return"); }
+
       ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
-      
+
       if (connectionDelegate != null)
-      {         
+      {
          connectionDelegate.init();
-         
-         //SimpleMetaData md = ((Advised)connectionDelegate)._getInstanceAdvisor().getMetaData();
-         
-         int serverID = connectionDelegate.getServerId();
-         
+
+         int serverID = connectionDelegate.getServerID();
          Version versionToUse = connectionDelegate.getVersionToUse();
-         
-         JMSRemotingConnection connection = connectionDelegate.getRemotingConnection();
-         
+         JMSRemotingConnection remotingConn = connectionDelegate.getRemotingConnection();
+
          if (versionToUse == null)
          {
             throw new IllegalStateException("Connection version is null");
          }
-         
-         //We have one message id generator per unique server
-         MessageIdGenerator gen =
-            MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
-         
+
+         // We have one message id generator per unique server
+         MessageIdGenerator g = MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
+
          ConnectionState connectionState =
-            new ConnectionState(serverID, connectionDelegate,
-                                connection, versionToUse, gen);
-         
+            new ConnectionState(serverID, connectionDelegate, remotingConn, versionToUse, g);
+
          connectionDelegate.setState(connectionState);
       }
-      
+
       return res;
    }
-   
+
    public Object handleCreateSessionDelegate(Invocation invocation) throws Throwable
    {
       SessionDelegate sessionDelegate = (SessionDelegate)invocation.invokeNext();
       DelegateSupport delegate = (DelegateSupport)sessionDelegate;
-      
+
       delegate.init();
-      
+
       ConnectionState connectionState = (ConnectionState)getState(invocation);
-      
+
       MethodInvocation mi = (MethodInvocation)invocation;
       boolean transacted = ((Boolean)mi.getArguments()[0]).booleanValue();
       int ackMode = ((Integer)mi.getArguments()[1]).intValue();
       boolean xa = ((Boolean)mi.getArguments()[2]).booleanValue();
-      
+
       SessionState sessionState =
          new SessionState(connectionState, sessionDelegate, transacted, ackMode, xa);
-      
+
       delegate.setState(sessionState);
       return delegate;
    }
-   
+
    public Object handleCreateConsumerDelegate(Invocation invocation) throws Throwable
    {
       ClientConsumerDelegate consumerDelegate = (ClientConsumerDelegate)invocation.invokeNext();
       DelegateSupport delegate = (DelegateSupport)consumerDelegate;
-      
+
       delegate.init();
-      
+
       SessionState sessionState = (SessionState)getState(invocation);
-      
+
       MethodInvocation mi = (MethodInvocation)invocation;
       Destination dest = (Destination)mi.getArguments()[0];
       String selector = (String)mi.getArguments()[1];
@@ -152,13 +153,13 @@
       boolean connectionConsumer = ((Boolean)mi.getArguments()[4]).booleanValue();
 
       int consumerID = consumerDelegate.getID();
-      
+
       int prefetchSize = consumerDelegate.getPrefetchSize();
-      
+
       int maxDeliveries = consumerDelegate.getMaxDeliveries();
-      
+
       long channelId = consumerDelegate.getChannelId();
-      
+
       ConsumerState consumerState =
          new ConsumerState(sessionState, consumerDelegate, dest, selector, noLocal,
                            subscriptionName, consumerID, connectionConsumer, prefetchSize,
@@ -167,63 +168,63 @@
       delegate.setState(consumerState);
       return consumerDelegate;
    }
-   
+
    public Object handleCreateProducerDelegate(Invocation invocation) throws Throwable
    {
       // ProducerDelegates are not created on the server
-      
+
       ProducerDelegate producerDelegate = new ClientProducerDelegate();
       DelegateSupport delegate = (DelegateSupport)producerDelegate;
-            
+
       SessionState sessionState = (SessionState)getState(invocation);
-      
+
       MethodInvocation mi = (MethodInvocation)invocation;
       Destination dest = ((Destination)mi.getArguments()[0]);
-      
 
+
       ProducerState producerState = new ProducerState(sessionState, producerDelegate, dest);
-      
+
       delegate.setState(producerState);
 
       // send an arbitrary invocation into the producer delegate, this will trigger AOP stack
       // initialization and AOP aspect class loading, using the "good" class loader, which is set
       // now. This will save us from having to switch the thread context class loader on every send.
       producerDelegate.getDeliveryMode();
-      
+
       return producerDelegate;
    }
-   
+
    public Object handleCreateBrowserDelegate(Invocation invocation) throws Throwable
    {
       MethodInvocation mi = (MethodInvocation)invocation;
 
       BrowserDelegate browserDelegate = (BrowserDelegate)invocation.invokeNext();
       DelegateSupport delegate = (DelegateSupport)browserDelegate;
-      
+
       delegate.init();
-      
+
       SessionState sessionState = (SessionState)getState(invocation);
 
       JBossDestination destination = (JBossDestination)mi.getArguments()[0];
       String selector = (String)mi.getArguments()[1];
 
       BrowserState state = new BrowserState(sessionState, browserDelegate, destination, selector);
-      
+
       delegate.setState(state);
       return browserDelegate;
    }
-      
+
    // Protected ------------------------------------------------------
 
    // Package Private ------------------------------------------------
 
    // Private --------------------------------------------------------
-   
+
    private HierarchicalState getState(Invocation inv)
    {
       return ((DelegateSupport)inv.getTargetObject()).getState();
    }
-   
+
    // Inner Classes --------------------------------------------------
 }
 

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -56,7 +56,7 @@
 
    // Attributes ----------------------------------------------------
 
-   private int serverId;
+   private int serverID;
 
    private transient JMSRemotingConnection remotingConnection;
    
@@ -70,7 +70,7 @@
    {
       super(objectID);
       
-      this.serverId = serverId;
+      this.serverID = serverId;
    }
 
    public ClientConnectionDelegate()
@@ -217,7 +217,7 @@
 
    public String toString()
    {
-      return "ConnectionDelegate[" + id + "]";
+      return "ConnectionDelegate[" + id + ", " + serverID + "]";
    }
 
    public void init()
@@ -235,9 +235,9 @@
       return remotingConnection;
    }
    
-   public int getServerId()
+   public int getServerID()
    {
-      return serverId;
+      return serverID;
    }
    
    public Version getVersionToUse()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -71,7 +71,7 @@
  
    private Version serverVersion;
  
-   private int serverId;
+   private int serverID;
    
    private boolean clientPing;
    
@@ -110,7 +110,7 @@
    {
       super(objectID);
 
-      this.serverId = serverId;
+      this.serverID = serverId;
       this.serverLocatorURI = serverLocatorURI;
       this.serverVersion = serverVersion;
       this.clientPing = clientPing;
@@ -294,7 +294,7 @@
 
    public String toString()
    {
-      return "ClientConnectionFactoryDelegate[" + id + "]";
+      return "ClientConnectionFactoryDelegate[" + id + ", " + serverID + "]";
    }
    
    public String getServerLocatorURI()
@@ -302,9 +302,9 @@
       return serverLocatorURI;
    }
 
-   public int getServerId()
+   public int getServerID()
    {
-      return serverId;
+      return serverID;
    }
    
    public boolean getClientPing()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -56,7 +56,8 @@
 
    // Constructors --------------------------------------------------
 
-   public ClusteredClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
+   public ClusteredClientConnectionFactoryDelegate(int objectID, int serverId,
+                                                   String serverLocatorURI,
                                                    Version serverVersion, boolean clientPing,
                                                    ClientConnectionFactoryDelegate[] delegates,
                                                    Map failoverMap)
@@ -66,14 +67,16 @@
       this.failoverMap = failoverMap;
    }
 
-   // Some of the properties of ClientConnectionFactoryDelegate are not exposed..
+   // Some of the properties of ClientConnectionFactoryDelegate are not exposed.
    // I didn't want to expose then while I needed another delegate's properties to perform a copy.
-   // So, I created this Constructor so I could have access into protected members inside an extension class
+   // So, I created this Constructor so I could have access into protected members inside an
+   // extension class.
+
    public ClusteredClientConnectionFactoryDelegate(ClientConnectionFactoryDelegate mainDelegate,
                                                    ClientConnectionFactoryDelegate[] delegates,
                                                    Map failoverMap)
    {
-      this(mainDelegate.getID(), mainDelegate.getServerId(), mainDelegate.getServerLocatorURI(),
+      this(mainDelegate.getID(), mainDelegate.getServerID(), mainDelegate.getServerLocatorURI(),
            mainDelegate.getServerVersion(), mainDelegate.getClientPing(), delegates, failoverMap);
    }
 
@@ -94,8 +97,6 @@
 
    // Public --------------------------------------------------------
 
-
-   // Only be used in testing
    public ClientConnectionFactoryDelegate[] getDelegates()
    {
       return delegates;
@@ -122,11 +123,19 @@
       sb.append(id).append("][");
       if (delegates == null)
       {
-         sb.append("0]");
+         sb.append("-]");
       }
       else
       {
-         sb.append(delegates.length).append("]");
+         for(int i = 0; i < delegates.length; i++)
+         {
+            sb.append(delegates[i].getServerID());
+            if (i < delegates.length - 1)
+            {
+               sb.append(',');
+            }
+         }
+         sb.append("]");
       }
       return sb.toString();
    }

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -26,6 +26,7 @@
 import javax.jms.ExceptionListener;
 
 import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.message.MessageIdGenerator;
@@ -89,21 +90,19 @@
    {
       super(null, (DelegateSupport)delegate);
 
-      if (log.isTraceEnabled()) { log.trace("Creating connection state"); }
+      if (log.isTraceEnabled()) { log.trace(this + " constructing connection state"); }
 
       children = new SyncSet(new HashSet(), new WriterPreferenceReadWriteLock());
 
       this.remotingConnection = remotingConnection;
-
       this.versionToUse = versionToUse;
 
-      //Each connection has it's own resource manager
-      //If we can failover all connections with the same server id at the same time
-      //then we can maintain one rm per unique server as opposed to per connection
+      // Each connection has its own resource manager. If we can failover all connections with the
+      // same server id at the same time then we can maintain one rm per unique server as opposed to
+      // per connection.
       this.resourceManager = new ResourceManager();
 
       this.idGenerator = gen;
-
       this.serverID = serverID;
    }
 
@@ -246,4 +245,9 @@
        
        this.delegate = newState.delegate;
     }
+
+   public String toString()
+   {
+      return "ConnectionState[" + ((ClientConnectionDelegate)delegate).getID() + "]";
+   }
 }

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -738,11 +738,11 @@
    {
       //This node may be failing over for another node - in which case we must wait for that to be complete
       
-      log.info("Waiting for failover for failedNodeId: " + failedNodeId);
+      log.info(this + " waiting for server-side failover from failed node " + failedNodeId);
       
       Replicator replicator = getReplicator();
       
-      //Failover
+      // Failover
 
       long startToWait = failoverStartTimeout;
       

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -422,7 +422,7 @@
       {
          ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)i.next();
             
-          if (del.getServerId() == this.serverPeer.getServerPeerID())
+          if (del.getServerID() == this.serverPeer.getServerPeerID())
           {
              // sanity check
              if (mainDelegate != null)

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -94,27 +94,30 @@
 
    // ConnectionFactoryDelegate implementation ----------------------
    
-   public CreateConnectionResult createConnectionDelegate(String username, String password,
-                                                          int failedNodeId)
+   public CreateConnectionResult createConnectionDelegate(String username,
+                                                          String password,
+                                                          int failedNodeID)
       throws JMSException      
    {
       try
       {
-         if (failedNodeId == -1)
+         if (failedNodeID == -1)
          {
-            //Just a standard createConnection
+            // Just a standard createConnection
             return new CreateConnectionResult(createConnectionDelegateInternal(username, password));            
          }
          else
          {
-            //Failover
-            //Wait for server side failover to complete
-            int failoverNodeId = serverPeer.waitForFailover(failedNodeId);
+            log.debug(this + " creating a failover connection " +
+                      "to replace connection to failed node " + failedNodeID);
+
+            // Wait for server side failover to complete
+            int failoverNodeID = serverPeer.waitForFailover(failedNodeID);
             
-            if (failoverNodeId == -1 || failoverNodeId != serverPeer.getServerPeerID())
+            if (failoverNodeID == -1 || failoverNodeID != serverPeer.getServerPeerID())
             {
                //We are on the wrong node - or no failover has occurred
-               return new CreateConnectionResult(failoverNodeId);
+               return new CreateConnectionResult(failoverNodeID);
             }
             else
             {
@@ -206,6 +209,11 @@
       return jndiBindings;
    }
 
+   public String toString()
+   {
+      return "ConnectionFactoryEndpoint[" + id + "]";
+   }
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -733,7 +733,7 @@
             if (persist && ref.isReliable() && recoverable)
             {
                // Reliable message in a recoverable state - also add to db
-               if (trace) { log.trace(this + "adding " + ref + " to database non-transactionally"); }
+               if (trace) { log.trace(this + " adding " + ref + " to database non-transactionally"); }
 
                pm.addReference(channelID, ref, null);        
             }
@@ -753,7 +753,7 @@
          }
          else
          {
-            if (trace) { log.trace(this + "adding " + ref + " to state " + (tx == null ? "non-transactionally" : "in transaction: " + tx)); }
+            if (trace) { log.trace(this + " adding " + ref + " to state " + (tx == null ? "non-transactionally" : "in transaction: " + tx)); }
 
             if (ref.isReliable() && !acceptReliableMessages)
             {
@@ -776,7 +776,7 @@
             if (persist && ref.isReliable() && recoverable)
             {
                // Reliable message in a recoverable state - also add to db
-               if (trace) { log.trace(this + "adding " + ref + (tx == null ? " to database non-transactionally" : " in transaction: " + tx)); }
+               if (trace) { log.trace(this + " adding " + ref + (tx == null ? " to database non-transactionally" : " in transaction: " + tx)); }
 
                pm.addReference(channelID, ref, tx);
             }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -41,7 +41,6 @@
 import java.util.Properties;
 import java.util.Set;
 
-import javax.jms.TextMessage;
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
 import javax.management.NotificationBroadcasterSupport;
@@ -693,15 +692,8 @@
    public void routeFromCluster(org.jboss.messaging.core.Message message, String routingKeyText,
                                 Map queueNameNodeIdMap) throws Exception
    {
-      if (trace)
-      {
-         log.trace(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
-                  routingKeyText + " map " + queueNameNodeIdMap);
-      }
+      if (trace) { log.trace(this + " routing from cluster " + message + ", routing key " + routingKeyText + ", map " + queueNameNodeIdMap); }
 
-      log.info(this.currentNodeId + " routing from cluster, message: " + message + " routing key " +
-               routingKeyText + " map " + queueNameNodeIdMap);
-
       Condition routingKey = conditionFactory.createCondition(routingKeyText);
 
       lock.readLock().acquire();
@@ -1136,20 +1128,8 @@
 
    public boolean route(MessageReference ref, Condition condition, Transaction tx) throws Exception
    {
-      if (trace) { log.trace(this.currentNodeId + " Routing " + ref + " with condition " + condition + " and transaction " + tx); }
+      if (trace) { log.trace(this + " routing " + ref + " with condition '" + condition + "'" + (tx == null ? "" : " transactionally in " + tx)); }
 
-      //debug
-      try
-      {
-         TextMessage tm = (TextMessage)ref.getMessage();
-
-         log.info(this.currentNodeId + " *********** Routing ref: " + tm.getText() + " with condition " + condition + " and transaction " + tx);
-      }
-      catch (Exception e)
-      {
-         e.printStackTrace();
-      }
-
       if (ref == null)
       {
          throw new IllegalArgumentException("Message reference is null");
@@ -1174,19 +1154,22 @@
 
          if (cb != null)
          {
+            if (trace) { log.trace(this + " found clustered bindings " + cb); }
+
             if (tx == null && ref.isReliable())
             {
-               if (!(cb.getDurableCount() == 0 || (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
+               if (!(cb.getDurableCount() == 0 ||
+                    (cb.getDurableCount() == 1 && cb.getLocalDurableCount() == 1)))
                {
                   // When routing a persistent message without a transaction then we may need to
                   // start an internal transaction in order to route it. This is so we can guarantee
                   // the message is delivered to all or none of the subscriptions. We need to do
-                  // this if there is anything other than. No durable subs or exactly one local
-                  // durable sub.
+                  // this if there is anything other than. No durable subscriptions or exactly one
+                  // local durable subscription.
 
                   startInternalTx = true;
 
-                  if (trace) { log.trace(this.currentNodeId + " Starting internal transaction since more than one durable sub or remote durable subs"); }
+                  if (trace) { log.trace(this + " starting internal transaction since it needs to deliver persistent message to more than one durable sub or remote durable subs"); }
                }
             }
 
@@ -1217,17 +1200,14 @@
 
                   ClusteredQueue queue = (ClusteredQueue)del.getObserver();
 
-                  if (trace) { log.trace(this.currentNodeId + " Routing message to queue or stub:" + queue.getName() + " on node " + queue.getNodeId() + " local:" + queue.isLocal()); }
+                  if (trace) { log.trace(this + " successfully routed message to " + (queue.isLocal() ? "local"  : "remote")+ " destination '" + queue.getName() + "' on node " + queue.getNodeId()); }
 
-                  log.info(this.currentNodeId + " Routing message to queue or stub:" +
-                           queue.getName() + " on node " + queue.getNodeId() + " local:" +
-                           queue.isLocal());
-
                   if (router.numberOfReceivers() > 1)
                   {
-                     //We have now chosen which one will receive the message so we need to add this
-                     //information to a map which will get sent when casting - so the the queue
-                     //on the receiving node knows whether to receive the message
+                     // We have now chosen which one will receive the message so we need to add this
+                     // information to a map which will get sent when casting - so the the queue on
+                     // the receiving node knows whether to receive the message.
+
                      if (queueNameNodeIdMap == null)
                      {
                         queueNameNodeIdMap = new HashMap();
@@ -1238,40 +1218,42 @@
 
                   if (!queue.isLocal())
                   {
-                     //We need to send the message remotely
+                     // We need to send the message remotely
                      numberRemote++;
 
                      lastNodeId = queue.getNodeId();
-
                      lastChannelId = queue.getChannelID();
                   }
                }
             }
 
-            //Now we've sent the message to any local queues, we might also need
-            //to send the message to the other office instances on the cluster if there are
-            //queues on those nodes that need to receive the message
+            // Now we've sent the message to any local queues, we might also need to send the
+            // message to the other office instances on the cluster if there are queues on those
+            // nodes that need to receive the message.
 
-            //TODO - there is an innefficiency here, numberRemote does not take into account that more than one
-            //of the number remote may be on the same node, so we could end up multicasting
-            //when unicast would do
+            //TODO - there is an innefficiency here, numberRemote does not take into account that
+            //       more than one of the number remote may be on the same node, so we could end up
+            //       multicasting when unicast would do
+
             if (numberRemote > 0)
             {
                if (tx == null)
                {
                   if (numberRemote == 1)
                   {
-                     if (trace) { log.trace(this.currentNodeId + " unicasting message to " + lastNodeId); }
+                     if (trace) { log.trace(this + " unicasting message to " + lastNodeId); }
 
-                     //Unicast - only one node is interested in the message
-                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), null), lastNodeId);
+                     // Unicast - only one node is interested in the message
+                     asyncSendRequest(new MessageRequest(condition.toText(),
+                                                         ref.getMessage(), null), lastNodeId);
                   }
                   else
                   {
-                     if (trace) { log.trace(this.currentNodeId + " multicasting message to group"); }
+                     if (trace) { log.trace(this + " multicasting message to group"); }
 
-                     //Multicast - more than one node is interested
-                     asyncSendRequest(new MessageRequest(condition.toText(), ref.getMessage(), queueNameNodeIdMap));
+                     // Multicast - more than one node is interested
+                     asyncSendRequest(new MessageRequest(condition.toText(),
+                                                         ref.getMessage(), queueNameNodeIdMap));
                   }
                }
                else
@@ -1280,30 +1262,35 @@
 
                   if (callback == null)
                   {
-                     callback = new CastMessagesCallback(currentNodeId, tx.getId(), DefaultClusteredPostOffice.this, failBeforeCommit, failAfterCommit);
+                     callback = new CastMessagesCallback(currentNodeId, tx.getId(),
+                                                         DefaultClusteredPostOffice.this,
+                                                         failBeforeCommit, failAfterCommit);
 
-                     //This callback MUST be executed first
+                     // This callback MUST be executed first
 
-                     //Execution order is as follows:
-                     //Before commit:
-                     //1. Cast messages across network - get added to holding area (if persistent) on receiving
-                     //nodes
-                     //2. Persist messages in persistent store
-                     //After commit
-                     //1. Cast commit message across network
+                     // Execution order is as follows:
+                     //
+                     // Before commit:
+                     // 1. Cast messages across network - get added to holding area (if persistent)
+                     //    on receiving nodes.
+                     // 2. Persist messages in persistent store.
+                     //
+                     // After commit
+                     //
+                     // 1. Cast commit message across network.
+
                      tx.addFirstCallback(callback, this);
                   }
 
                   callback.addMessage(condition, ref.getMessage(), queueNameNodeIdMap,
-                                      numberRemote == 1 ? lastNodeId : -1,
-                                      lastChannelId);
+                                      numberRemote == 1 ? lastNodeId : -1, lastChannelId);
                }
             }
 
             if (startInternalTx)
             {
                tx.commit();
-               if (trace) { log.trace("Committed internal transaction"); }
+               if (trace) { log.trace(this + " committed internal transaction"); }
             }
          }
       }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -25,8 +25,6 @@
 import java.util.Iterator;
 import java.util.List;
 
-import javax.jms.TextMessage;
-
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
@@ -50,11 +48,17 @@
  */
 public class DefaultRouter implements ClusterRouter
 {
+   // Constants -----------------------------------------------------
+
    private static final Logger log = Logger.getLogger(DefaultRouter.class);
-   
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private boolean trace = log.isTraceEnabled();
-      
-   //MUST be an arraylist for fast index access
+
+   // MUST be an arraylist for fast index access
    private ArrayList nonLocalQueues;
 
    private ArrayList failedOverQueues;
@@ -63,63 +67,84 @@
 
    private int target;
 
+   // Constructors --------------------------------------------------
+
    public DefaultRouter()
    {
       nonLocalQueues = new ArrayList();
       failedOverQueues = new ArrayList();
    }
 
-   public int size()
-   {
-      return nonLocalQueues.size() + (localQueue == null ? 0 : 1);
-   }
+   // Receiver implementation ---------------------------------------
 
-   public ClusteredQueue getLocalQueue()
+   public Delivery handle(DeliveryObserver observer, MessageReference reference, Transaction tx)
    {
-      return localQueue;
-   }
+      if (trace) { log.trace(this + " routing " + reference); }
 
-   public boolean add(Receiver receiver)
-   {
-      return add(receiver,false);
-   }
+      // Favour the local queue or the failedOver queue in round robin
 
-   public boolean add(Receiver receiver, boolean failedOver)
-   {
-      ClusteredQueue queue = (ClusteredQueue)receiver;
+      if (!failedOverQueues.isEmpty())
+      {
+         if (trace) { log.trace(this + " round robin on failedover queue, current target " + target);}
 
-      if (queue.isLocal())
-      {
-         if (failedOver)
+         LocalClusteredQueue queueToUse = null;
+
+         if (target == -1)
          {
-            failedOverQueues.add(receiver);
+            queueToUse = (LocalClusteredQueue)this.localQueue;
          }
          else
          {
-            if (localQueue != null)
-            {
-               throw new IllegalStateException("Already has local queue");
-            }
-            localQueue = queue;
+            queueToUse = (LocalClusteredQueue)failedOverQueues.get(target);
          }
+
+         incTargetFailedOver();
+
+         Delivery del = queueToUse.handle(observer, reference, tx);
+
+         if (trace) { log.trace(this + " routed to failed queue, using failedOver round robbing, returned " + del); }
+
+         return del;
       }
+      else if (localQueue != null)
+      {
+         // The only time the local queue won't accept is if the selector doesn't match, in which
+         // case it won't match at any other nodes too so no point in trying them
+
+         Delivery del = localQueue.handle(observer, reference, tx);
+
+         if (trace) { log.trace(this + " routed to local queue, it returned " + del); }
+
+         return del;
+      }
       else
       {
-         nonLocalQueues.add(queue);
-      }
+         // There is no local shared queue. We round robin among the rest.
 
-      return true;
-   }
+         if (!nonLocalQueues.isEmpty())
+         {
+            ClusteredQueue queue = (ClusteredQueue)nonLocalQueues.get(target);
 
-   public void clear()
-   {
-      nonLocalQueues.clear();
+            Delivery del = queue.handle(observer, reference, tx);
 
-      localQueue = null;
+            if (trace) { log.trace(this + " routed to remote queue, it returned " + del); }
 
-      target = 0;
+            incTarget();
+
+            // Again, if the selector doesn't match then it won't on any others so no point trying
+            // them.
+
+            return del;
+         }
+      }
+
+      if (trace) { log.trace(this + " no queues to route to so return null"); }
+
+      return null;
    }
 
+   // Distributor implementation ------------------------------------
+
    public boolean contains(Receiver queue)
    {
       return localQueue == queue || nonLocalQueues.contains(queue);
@@ -139,6 +164,11 @@
       return queues.iterator();
    }
 
+   public boolean add(Receiver receiver)
+   {
+      return add(receiver,false);
+   }
+
    public boolean remove(Receiver queue)
    {
       if (localQueue == queue)
@@ -164,88 +194,90 @@
       }
    }
 
-   public Delivery handle(DeliveryObserver observer, MessageReference reference, Transaction tx)
+   public void clear()
    {
-      if (trace) { log.trace(this + " routing ref " + reference); }
+      nonLocalQueues.clear();
+      localQueue = null;
+      target = 0;
+   }
 
-      //Favour the local queue or the failedOver queue in round robin
+   public int numberOfReceivers()
+   {
+      return nonLocalQueues.size() + (localQueue != null ? 1 : 0);
+   }
 
-      if (!failedOverQueues.isEmpty())
+
+   // ClusterRouter implementation ----------------------------------
+
+   public List getQueues()
+   {
+      List queues = new ArrayList();
+
+      if (localQueue != null)
       {
-         if (trace) { log.trace("Round robin on FailedOver queue, currentTarget=" + target);}
-         
-         LocalClusteredQueue queueToUse = null;
+         queues.add(localQueue);
+      }
 
-         if (target == -1)
-         {
-            queueToUse = (LocalClusteredQueue)this.localQueue; 
-         }
-         else
-         {
-            queueToUse = (LocalClusteredQueue)failedOverQueues.get(target);
-         }
+      queues.addAll(nonLocalQueues);
 
-         incTargetFailedOver();
-         
-         log.info("***************** Routing to failed over queue");
-         Delivery del = queueToUse.handle(observer, reference, tx);
+      return queues;
+   }
 
-         if (trace) { log.trace(this+" routed to failed queue, using failedOver round robbing, returned " + del); }
-         
-         return del;
-      }
-      else if (localQueue != null)
+   public List getFailedQueues()
+   {
+      return failedOverQueues;
+   }
+
+   public ClusteredQueue getLocalQueue()
+   {
+      return localQueue;
+   }
+
+   public boolean add(Receiver receiver, boolean failedOver)
+   {
+      ClusteredQueue queue = (ClusteredQueue)receiver;
+
+      if (queue.isLocal())
       {
-         //The only time the local queue won't accept is if the selector doesn't
-         //match - in which case it won't match at any other nodes too so no point
-         //in trying them
-         
-         //debug
-         try
+         if (failedOver)
          {
-            TextMessage tm = (TextMessage)reference.getMessage();
-            
-            log.info("*********** Routing to local queue: " + tm.getText() + " id:" + System.identityHashCode(localQueue) );
+            failedOverQueues.add(receiver);
          }
-         catch (Exception e)
+         else
          {
-            e.printStackTrace();
+            if (localQueue != null)
+            {
+               throw new IllegalStateException("Already has local queue");
+            }
+            localQueue = queue;
          }
-
-         Delivery del = localQueue.handle(observer, reference, tx);
-
-         if (trace) { log.trace(this + " routed to local queue, it returned " + del); }
-
-         return del;
       }
       else
       {
-         //There is no local shared queue
-         //We round robin among the rest
+         nonLocalQueues.add(queue);
+      }
 
-         if (!nonLocalQueues.isEmpty())
-         {
-            ClusteredQueue queue = (ClusteredQueue)nonLocalQueues.get(target);
+      return true;
+   }
 
-            queue = (ClusteredQueue)nonLocalQueues.get(target);
+   // Public --------------------------------------------------------
 
-            log.info("************ Routing to non local queue");
-            Delivery del = queue.handle(observer, reference, tx);
+   public int size()
+   {
+      return nonLocalQueues.size() + (localQueue == null ? 0 : 1);
+   }
 
-            if (trace) { log.trace(this + " routed to remote queue, it returned " + del); }
+   public String toString()
+   {
+      return "DefaultRouter[" + Integer.toHexString(hashCode()) + "]";
+   }
 
-            incTarget();
+   // Package protected ---------------------------------------------
 
-            //Again, if the selector doesn't match then it won't on any others so no point trying them
-            return del;
-         }
-      }
+   // Protected -----------------------------------------------------
 
-      if (trace) { log.trace(this + " no queues to route to so return null"); }
+   // Private -------------------------------------------------------
 
-      return null;
-   }
-
    private void incTargetFailedOver()
    {
       target++;
@@ -267,30 +299,8 @@
       }
    }
 
+   // Inner classes -------------------------------------------------
 
-   public java.util.List getFailedQueues()
-   {
-      return failedOverQueues;
-   }
-
-   public List getQueues()
-   {
-      List queues = new ArrayList();
-
-      if (localQueue != null)
-      {
-         queues.add(localQueue);
-      }
-
-      queues.addAll(nonLocalQueues);
-
-      return queues;
-   }
-
-   public int numberOfReceivers()
-   {
-      return nonLocalQueues.size() + (localQueue != null ? 1 : 0);
-   }
 }
 
 

Modified: trunk/tests/etc/log4j.xml
===================================================================
--- trunk/tests/etc/log4j.xml	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/tests/etc/log4j.xml	2006-12-14 06:09:44 UTC (rev 1787)
@@ -42,7 +42,7 @@
    </category>
 
    <category name="org.jboss.remoting">
-         <priority value="TRACE"/>
+      <priority value="INFO"/>
    </category>
 
    <category name="org.jboss">

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -59,7 +59,7 @@
 
          conn.close();
 
-         // create a connection to a node we'll kill soon
+         // create a connection to a node we'll kill soon (node 1)
 
          conn = cf.createConnection();
          s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -74,6 +74,8 @@
 
          assertEquals(1, nodeID);
 
+         log.info("consumer created");
+
          // kill node 1
 
          ServerManagement.kill(1);
@@ -84,7 +86,7 @@
 
          // TODO - this shouldn't be necessary if we have the client valve in place
          log.info("Sleeping for 1 min");
-         Thread.sleep(30000);
+         Thread.sleep(20000);
 
          // we must receive the message
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-13 23:29:14 UTC (rev 1786)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 06:09:44 UTC (rev 1787)
@@ -93,11 +93,11 @@
       
       ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
       
-      assertEquals(0, cf1.getServerId());
+      assertEquals(0, cf1.getServerID());
       
-      assertEquals(1, cf2.getServerId());
+      assertEquals(1, cf2.getServerID());
       
-      assertEquals(2, cf3.getServerId());
+      assertEquals(2, cf3.getServerID());
       
       assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
       
@@ -219,18 +219,18 @@
          
          //If any servers get stopped and then started then the order will change
     
-         log.info("cf1 serverid=" + cf1.getServerId());
+         log.info("cf1 serverid=" + cf1.getServerID());
          
-         log.info("cf2 serverid=" + cf2.getServerId());
+         log.info("cf2 serverid=" + cf2.getServerID());
          
-         log.info("cf3 serverid=" + cf3.getServerId());
+         log.info("cf3 serverid=" + cf3.getServerID());
          
          
-         assertEquals(0, cf1.getServerId());
+         assertEquals(0, cf1.getServerID());
          
-         assertEquals(1, cf2.getServerId());
+         assertEquals(1, cf2.getServerID());
          
-         assertEquals(2, cf3.getServerId());
+         assertEquals(2, cf3.getServerID());
          
          Map failoverMap = delegate.getFailoverMap();
          
@@ -240,11 +240,11 @@
          
          // Default failover policy just chooses the node to the right
          
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
          
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         assertEquals(cf3.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
          
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+         assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf3.getServerID()))).intValue());
       }
       
       //Now cleanly stop one of the servers
@@ -280,20 +280,20 @@
          
          //Order here depends on order servers were started in
          
-         log.info("cf1 serverid=" + cf1.getServerId());
+         log.info("cf1 serverid=" + cf1.getServerID());
          
-         log.info("cf2 serverid=" + cf2.getServerId());
+         log.info("cf2 serverid=" + cf2.getServerID());
          
-         assertEquals(1, cf1.getServerId());
+         assertEquals(1, cf1.getServerID());
          
-         assertEquals(2, cf2.getServerId());
+         assertEquals(2, cf2.getServerID());
          
          
          assertEquals(2, failoverMap.size());
          
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
          
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
       }
       
       //Cleanly stop another server
@@ -320,12 +320,12 @@
          
          ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
          
-         assertEquals(2, cf1.getServerId());
+         assertEquals(2, cf1.getServerID());
          
          
          assertEquals(1, failoverMap.size());
          
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
       }
             
       //Restart server 0
@@ -352,20 +352,20 @@
          
          ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
          
-         log.info("cf1 serverid=" + cf1.getServerId());
+         log.info("cf1 serverid=" + cf1.getServerID());
          
-         log.info("cf2 serverid=" + cf2.getServerId());
+         log.info("cf2 serverid=" + cf2.getServerID());
          
-         assertEquals(2, cf1.getServerId());
+         assertEquals(2, cf1.getServerID());
          
-         assertEquals(0, cf2.getServerId());
+         assertEquals(0, cf2.getServerID());
          
          
          assertEquals(2, failoverMap.size());
          
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
          
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
       }
       
       
@@ -395,26 +395,26 @@
          
          ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
          
-         log.info("cf1 serverid=" + cf1.getServerId());
+         log.info("cf1 serverid=" + cf1.getServerID());
          
-         log.info("cf2 serverid=" + cf2.getServerId());
+         log.info("cf2 serverid=" + cf2.getServerID());
          
-         log.info("cf3 serverid=" + cf3.getServerId());
+         log.info("cf3 serverid=" + cf3.getServerID());
          
-         assertEquals(2, cf1.getServerId());
+         assertEquals(2, cf1.getServerID());
          
-         assertEquals(0, cf2.getServerId());
+         assertEquals(0, cf2.getServerID());
          
-         assertEquals(1, cf3.getServerId());
+         assertEquals(1, cf3.getServerID());
          
          
          assertEquals(3, failoverMap.size());
          
-         assertEquals(cf2.getServerId(), ((Integer)failoverMap.get(new Integer(cf1.getServerId()))).intValue());
+         assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
          
-         assertEquals(cf3.getServerId(), ((Integer)failoverMap.get(new Integer(cf2.getServerId()))).intValue());
+         assertEquals(cf3.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
          
-         assertEquals(cf1.getServerId(), ((Integer)failoverMap.get(new Integer(cf3.getServerId()))).intValue());
+         assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf3.getServerID()))).intValue());
       }            
    }
    
@@ -436,11 +436,11 @@
       
       ClientConnectionFactoryDelegate cf3 = delegates[2];
       
-      int server0Id = cf1.getServerId();
+      int server0Id = cf1.getServerID();
       
-      int server1Id = cf2.getServerId();
+      int server1Id = cf2.getServerID();
       
-      int server2Id = cf3.getServerId();
+      int server2Id = cf3.getServerID();
       
       log.info("server 0 id: " + server0Id);
       
@@ -571,11 +571,11 @@
       
       ClientConnectionFactoryDelegate cf3 = delegates[2];
       
-      int server0Id = cf1.getServerId();
+      int server0Id = cf1.getServerID();
       
-      int server1Id = cf2.getServerId();
+      int server1Id = cf2.getServerID();
       
-      int server2Id = cf3.getServerId();
+      int server2Id = cf3.getServerID();
       
       log.info("server 0 id: " + server0Id);
       
@@ -742,11 +742,11 @@
       
       ClientConnectionFactoryDelegate cf3 = delegates[2];
       
-      int server0Id = cf1.getServerId();
+      int server0Id = cf1.getServerID();
       
-      int server1Id = cf2.getServerId();
+      int server1Id = cf2.getServerID();
       
-      int server2Id = cf3.getServerId();
+      int server2Id = cf3.getServerID();
       
       log.info("server 0 id: " + server0Id);
       



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 01:26:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 01:26:49 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1788 - in
	trunk/src/main/org/jboss: jms/client/container
	jms/client/delegate jms/server/endpoint messaging/core/plugin
Message-ID: <E1Guk3N-0002HN-06@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 01:26:45 -0500 (Thu, 14 Dec 2006)
New Revision: 1788

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
   trunk/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java
   trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java
Log:
Fixed StateCreationAspect to prevent double initialization of the ClientConnectionDelegate for the clustered case.


Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 06:09:44 UTC (rev 1787)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 06:26:45 UTC (rev 1788)
@@ -282,7 +282,7 @@
 
          // Did not get a valid connection to the node we've just tried
 
-         int actualServerID = r.getActualFailoverNode();
+         int actualServerID = r.getActualFailoverNodeID();
 
          if (actualServerID == -1)
          {

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 06:09:44 UTC (rev 1787)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 06:26:45 UTC (rev 1788)
@@ -86,12 +86,14 @@
 
       CreateConnectionResult res = (CreateConnectionResult)inv.invokeNext();
 
-      if(trace) { log.trace("got " + res + " on return"); }
-
       ClientConnectionDelegate connectionDelegate = (ClientConnectionDelegate)res.getDelegate();
 
-      if (connectionDelegate != null)
+      if (connectionDelegate != null && connectionDelegate.getState() == null)
       {
+         // no state set yet, initialize and configure it
+
+         if(trace) { log.trace(connectionDelegate + " not configured, configuring ..."); }
+
          connectionDelegate.init();
 
          int serverID = connectionDelegate.getServerID();
@@ -110,6 +112,10 @@
             new ConnectionState(serverID, connectionDelegate, remotingConn, versionToUse, g);
 
          connectionDelegate.setState(connectionState);
+
+         // the delegate is completely configured now; will use this state to avoid redundant
+         // configuration on a double pass through StateCreationAspect, which happens for clustered
+         // connections
       }
 
       return res;

Modified: trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-14 06:09:44 UTC (rev 1787)
+++ trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-14 06:26:45 UTC (rev 1788)
@@ -34,7 +34,6 @@
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
-import org.jboss.remoting.serialization.SerializationStreamFactory;
 
 /**
  * Base class for all client-side delegate classes.
@@ -67,27 +66,28 @@
 
    // Attributes ----------------------------------------------------
 
-   //This is set on the server
+   // This is set on the server.
    protected int id;
 
-   //This is set on the client
-   //The reason we don't use the meta-data to store the state for the delegate is to avoid
-   //the extra HashMap lookup that would entail.
-   //This can be significant since the state could be queried for many aspects
-   //in an a single invocation
+   // This is set on the client.
+   // The reason we don't use the meta-data to store the state for the delegate is to avoid the
+   // extra HashMap lookup that would entail. This can be significant since the state could be
+   // queried for many aspects in an a single invocation.
    protected transient HierarchicalState state;
 
    // Static --------------------------------------------------------
 
    // Constructors --------------------------------------------------
 
-   public DelegateSupport(int objectID)
+   public DelegateSupport(int id)
    {
-      this.id = objectID;
+      this.id = id;
+      this.state = null;
    }
 
    public DelegateSupport()
    {
+      this(Integer.MIN_VALUE);
    }
 
    // Interceptor implementation ------------------------------------
@@ -142,20 +142,20 @@
       checkMarshallers();
    }
 
-    public int getID()
-    {
-       return id;
-    }
+   public int getID()
+   {
+      return id;
+   }
 
-    /**
-     * During HA events, a new object is created on the new server and the state on that new object
-     * has to be transfered to this actual object. For example, a Connection will have to assume the
-     * ObjectID of the new connection endpoint and the new RemotingConnection.
-     */
-    public void copyAttributes(DelegateSupport newDelegate)
-    {
-        id = newDelegate.getID();
-    }
+   /**
+    * During HA events, a new object is created on the new server and the state on that new object
+    * has to be transfered to this actual object. For example, a Connection will have to assume the
+    * ObjectID of the new connection endpoint and the new RemotingConnection.
+    */
+   public void copyAttributes(DelegateSupport newDelegate)
+   {
+      id = newDelegate.getID();
+   }
 
    // Package protected ---------------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java	2006-12-14 06:09:44 UTC (rev 1787)
+++ trunk/src/main/org/jboss/jms/server/endpoint/CreateConnectionResult.java	2006-12-14 06:26:45 UTC (rev 1788)
@@ -37,30 +37,60 @@
  */
 public class CreateConnectionResult implements Serializable
 {
+   // Constants -----------------------------------------------------
+
    private static final long serialVersionUID = 4311863642735135167L;
-   
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private ConnectionDelegate delegate;
-   
-   private int actualFailoverNodeId;
-   
-   public CreateConnectionResult(ConnectionDelegate del)
+
+   private int actualFailoverNodeID;
+
+   // Constructors --------------------------------------------------
+
+   public CreateConnectionResult(ConnectionDelegate delegate)
    {
-      this.delegate = del;
+      this(delegate, Integer.MIN_VALUE);
    }
-   
-   public CreateConnectionResult(int actualFailoverNode)
+
+   public CreateConnectionResult(int actualFailoverNodeID)
    {
-      this.actualFailoverNodeId = actualFailoverNode;
+      this(null, actualFailoverNodeID);
    }
-   
+
+   private CreateConnectionResult(ConnectionDelegate delegate,
+                                  int actualFailoverNodeId)
+   {
+      this.delegate = delegate;
+      this.actualFailoverNodeID = actualFailoverNodeId;
+   }
+
+   // Public --------------------------------------------------------
+
    public ConnectionDelegate getDelegate()
    {
       return delegate;
    }
-   
-   public int getActualFailoverNode()
+
+   public int getActualFailoverNodeID()
    {
-      return actualFailoverNodeId;
+      return actualFailoverNodeID;
    }
 
+   public String toString()
+   {
+      return "CreateConnectionResult[" + delegate + ", failover node " + actualFailoverNodeID + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java	2006-12-14 06:09:44 UTC (rev 1787)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java	2006-12-14 06:26:45 UTC (rev 1788)
@@ -76,4 +76,9 @@
       out.writeLong(high);
    }
 
+   public String toString()
+   {
+      return "IdBlock[" + low + "-" + high + "]";
+   }
+
 }



From t2-okada at nri.co.jp  Thu Dec 14 01:38:17 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 14 Dec 2006 01:38:17 -0500
Subject: [jboss-cvs] jboss-profiler/java/mbean  ...
Message-ID: <E1GukET-0002Rd-3k@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/14 01:38:17

  Modified:    java/mbean  Tag: JBossProfiler_Expansion
                        collector-config.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +9 -3      jboss-profiler/java/mbean/Attic/collector-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: collector-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/mbean/Attic/collector-config.xml,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- collector-config.xml	12 Dec 2006 09:02:13 -0000	1.1.2.2
  +++ collector-config.xml	14 Dec 2006 06:38:17 -0000	1.1.2.3
  @@ -3,26 +3,32 @@
     
     <!-- ##### JDBC Setting ##### -->
     <jdbc>
  -    <!-- ##### SAMPLE: The implementation mapping set for the JBoss Application Server ##### -->
  +    
  +    <!-- SAMPLE: The implementation mapping set for the JBoss Application Server -->
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrapperDataSource" interface="java.sql.DataSource"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedConnection" interface="java.sql.Connection"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedStatement" interface="java.sql.Statement"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedPreparedStatement" interface="java.sql.PreparedStatement"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedCallableStatement" interface="java.sql.CallableStatement"/>
       <impl-mapping impl="org.jboss.resource.adapter.jdbc.WrappedResultSet" interface="java.sql.ResultSet"/>
  +    
     </jdbc>
     
  +  
     <!-- ##### Application Framework Setting ##### -->
     <!-- Add the following setting when the profiling application runs on the framework. -->
     <framework>
  -    <!-- ##### SAMPLE: The expression set for the Spring Framework ##### -->
  +    
  +    <!-- SAMPLE: The expression set for the Spring Framework -->
       <expression>org.springframework.aop</expression>
       <expression>org.springframework.web</expression>
       <expression>org.springframework.dao</expression>
       <expression>org.springframework.transaction</expression>
       <expression>org.springframework.orm</expression>
  -    <!-- ##### SAMPLE: The expression set for the iBATIS ##### -->
  +    
  +    <!-- SAMPLE: The expression set for the iBATIS -->
       <expression>com.ibatis</expression>
  +    
     </framework>
     
   </collector-config>
  
  
  


From t2-okada at nri.co.jp  Thu Dec 14 01:38:16 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 14 Dec 2006 01:38:16 -0500
Subject: [jboss-cvs] jboss-profiler/exsamples/jboss-profiler.aop/META-INF ...
Message-ID: <E1GukES-0002RS-Tn@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/14 01:38:16

  Modified:    exsamples/jboss-profiler.aop/META-INF  Tag:
                        JBossProfiler_Expansion jboss-aop.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.5   +3 -3      jboss-profiler/exsamples/jboss-profiler.aop/META-INF/Attic/jboss-aop.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-aop.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/exsamples/jboss-profiler.aop/META-INF/Attic/jboss-aop.xml,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -b -r1.1.2.4 -r1.1.2.5
  --- jboss-aop.xml	12 Dec 2006 09:17:36 -0000	1.1.2.4
  +++ jboss-aop.xml	14 Dec 2006 06:38:16 -0000	1.1.2.5
  @@ -16,7 +16,7 @@
         <attribute name="CollectorFactoryName">
           org.jboss.profiler.exp.agent.collector.ExecutionMetricCollectorFactory
         </attribute>
  -      <attribute name="Category">Beans</attribute>
  +      <attribute name="Category">Application Components</attribute>
         <!--
         <attribute name="CollectorPoolSize">100000</attribute>
         <attribute name="CollectorQueueSize">100000</attribute>
  @@ -30,7 +30,7 @@
         <attribute name="CollectorFactoryName">
           org.jboss.profiler.exp.agent.collector.ConcurrentMetricCollectorFactory
         </attribute>
  -      <attribute name="Category">Beans</attribute>
  +      <attribute name="Category">Application Components</attribute>
         <!--
         <attribute name="CollectorPoolSize">100000</attribute>
         <attribute name="CollectorQueueSize">100000</attribute>
  @@ -44,7 +44,7 @@
         <attribute name="CollectorFactoryName">
           org.jboss.profiler.exp.agent.collector.MemoryMetricCollectorFactory
         </attribute>
  -      <attribute name="Category">Beans</attribute>
  +      <attribute name="Category">Application Components</attribute>
         <!--
         <attribute name="CollectorPoolSize">100000</attribute>
         <attribute name="CollectorQueueSize">100000</attribute>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 01:47:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 01:47:24 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1789 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/state
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GukNI-0002b6-Av@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 01:47:18 -0500 (Thu, 14 Dec 2006)
New Revision: 1789

Modified:
   trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
Log:
More reformatting


Modified: trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-14 06:26:45 UTC (rev 1788)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-14 06:47:18 UTC (rev 1789)
@@ -184,7 +184,7 @@
    {
       Object ret = invocation.invokeNext();
       
-      //Remove any exception listener
+      // Remove any exception listener
       ConnectionState currentState = getConnectionState(invocation);
       
       Client client = getConnectionState(invocation).getRemotingConnection().getInvokingClient();

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 06:26:45 UTC (rev 1788)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 06:47:18 UTC (rev 1789)
@@ -154,7 +154,7 @@
       if(trace) { log.trace(this + " registering " + listener + " on " + cd); }
       state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
 
-      return new CreateConnectionResult(cd); 
+      return new CreateConnectionResult(cd);
    }
 
    public String toString()
@@ -241,15 +241,16 @@
       return null;
    }
 
-   private void handleFailure(ClientConnectionDelegate failedConnDelegate) throws Exception
+   private void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate)
+      throws Exception
    {
+      log.debug(this + " handling failed connection " + failedConnDelegate);
+
       ConnectionState failedConnState =
          (ConnectionState)((DelegateSupport)failedConnDelegate).getState();
 
       int failedServerID = failedConnState.getServerID();
 
-      log.debug(this + " handling failed connection to node " + failedServerID);
-
       // Get the default connection factory delegate we are going to failover onto
 
       ClientConnectionFactoryDelegate failoverDelegate = getFailoverDelegate(failedServerID);
@@ -589,7 +590,7 @@
          try
          {
             log.debug(this + " is being notified of connection failure: " + throwable);
-            handleFailure(cd);
+            handleConnectionFailure(cd);
          }
          catch (Throwable e)
          {
@@ -599,7 +600,7 @@
 
       public String toString()
       {
-         return "ConnectionFailureListener[" + Integer.toHexString(hashCode()) + "]";
+         return "ConnectionFailureListener[" + cd + "]";
       }
    }
 }

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-14 06:26:45 UTC (rev 1788)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-14 06:47:18 UTC (rev 1789)
@@ -136,7 +136,6 @@
       return serverID;
    }
 
-
    public DelegateSupport getDelegate()
    {
       return (DelegateSupport) delegate;
@@ -164,7 +163,6 @@
       this.started = started;
    }
 
-
    public String getPassword()
    {
       return password;
@@ -186,66 +184,62 @@
    }
 
    public String getClientID()
-    {
-        return clientID;
-    }
+   {
+      return clientID;
+   }
 
-    public void setClientID(String clientID)
-    {
-        this.clientID = clientID;
-    }
+   public void setClientID(String clientID)
+   {
+      this.clientID = clientID;
+   }
 
-    public ExceptionListener getExceptionListener()
-    {
-        return exceptionListener;
-    }
+   public ExceptionListener getExceptionListener()
+   {
+      return exceptionListener;
+   }
 
-    public void setExceptionListener(ExceptionListener exceptionListener)
-    {
-        this.exceptionListener = exceptionListener;
-    }
+   public void setExceptionListener(ExceptionListener exceptionListener)
+   {
+      this.exceptionListener = exceptionListener;
+   }
 
-    public boolean isJustCreated()
-    {
-        return justCreated;
-    }
+   public boolean isJustCreated()
+   {
+      return justCreated;
+   }
 
-    public void setJustCreated(boolean justCreated)
-    {
-        this.justCreated = justCreated;
-    }
+   public void setJustCreated(boolean justCreated)
+   {
+      this.justCreated = justCreated;
+   }
 
-    public boolean isListenerAdded()
-    {
-        return listenerAdded;
-    }
+   public boolean isListenerAdded()
+   {
+      return listenerAdded;
+   }
 
-    public void setListenerAdded(boolean listenerAdded)
-    {
-        this.listenerAdded = listenerAdded;
-    }    
+   public void setListenerAdded(boolean listenerAdded)
+   {
+      this.listenerAdded = listenerAdded;
+   }
 
-    /** Connection doesn't have a parent */
-    public HierarchicalState getParent()
-    {
-        return null;
-    }
-    
-    //When failing over a connection, we keep the old connection's state but there are certain fields
-    //we need to update
-    public void copyState(ConnectionState newState)
-    {
-       this.remotingConnection = newState.remotingConnection;
-       
-       this.idGenerator = newState.idGenerator;
-       
-       this.serverID = newState.serverID;
-       
-       this.versionToUse = newState.versionToUse;
-       
-       this.delegate = newState.delegate;
-    }
+   /** Connection doesn't have a parent */
+   public HierarchicalState getParent()
+   {
+      return null;
+   }
 
+   //When failing over a connection, we keep the old connection's state but there are certain fields
+   //we need to update
+   public void copyState(ConnectionState newState)
+   {
+      this.remotingConnection = newState.remotingConnection;
+      this.idGenerator = newState.idGenerator;
+      this.serverID = newState.serverID;
+      this.versionToUse = newState.versionToUse;
+      this.delegate = newState.delegate;
+   }
+
    public String toString()
    {
       return "ConnectionState[" + ((ClientConnectionDelegate)delegate).getID() + "]";

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-14 06:26:45 UTC (rev 1788)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-14 06:47:18 UTC (rev 1789)
@@ -86,7 +86,7 @@
 
          // TODO - this shouldn't be necessary if we have the client valve in place
          log.info("Sleeping for 1 min");
-         Thread.sleep(20000);
+         Thread.sleep(15000);
 
          // we must receive the message
 



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 02:02:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 02:02:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r59032 - in
	projects/microcontainer/trunk/container/src/main/org/jboss:
	metadata/spi/signature repository/spi
Message-ID: <E1GukcE-00031q-8m@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 02:02:45 -0500 (Thu, 14 Dec 2006)
New Revision: 59032

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java
   projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java
Log:
small fixes

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java	2006-12-14 05:22:07 UTC (rev 59031)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java	2006-12-14 07:02:45 UTC (rev 59032)
@@ -32,7 +32,7 @@
 public class Signature
 {
    /** No Name */
-   public static final String NO_NAME = new String("?%NO_NAME%?");
+   public static final String NO_NAME = "?%NO_NAME%?";
 
    /** No Parameters */
    public static final String[] NO_PARAMETERS = new String[0];
@@ -89,7 +89,7 @@
       if (cl == null)
          cl = Class.class.getClassLoader();
       
-      return stringstoClasses(cl, parameters);
+      return stringsToClasses(cl, parameters);
    }
 
    /**
@@ -99,7 +99,7 @@
     * @param parameters the parameters as strings
     * @return the parameters as classes
     */
-   private static Class[] stringstoClasses(ClassLoader cl, String... parameters)
+   private static Class[] stringsToClasses(ClassLoader cl, String... parameters)
    {
       if (cl == null)
          throw new IllegalArgumentException("Null classloader");

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java	2006-12-14 05:22:07 UTC (rev 59031)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/repository/spi/MetaDataContext.java	2006-12-14 07:02:45 UTC (rev 59032)
@@ -34,20 +34,20 @@
 public interface MetaDataContext
 {
 
-   public abstract <T extends Annotation> boolean hasAnnotation(Class<T> ann);
+   <T extends Annotation> boolean hasAnnotation(Class<T> ann);
 
-   public abstract <T extends Annotation> Annotation getAnnotation(Class<T> ann);
+   <T extends Annotation> Annotation getAnnotation(Class<T> ann);
 
-   public abstract <T extends Annotation> boolean hasAnnotationForMethod(long methodHash, Class<T> ann);
+   <T extends Annotation> boolean hasAnnotationForMethod(long methodHash, Class<T> ann);
 
-   public abstract <T extends Annotation> Annotation getAnnotationForMethod(long methodHash, Class<T> ann);
+   <T extends Annotation> Annotation getAnnotationForMethod(long methodHash, Class<T> ann);
 
-   public abstract List<Annotation> getAnnotations();
+   List<Annotation> getAnnotations();
 
-   public abstract List<Annotation> getAnnotationsForMethod(long methodHash);
+   List<Annotation> getAnnotationsForMethod(long methodHash);
 
-   public abstract List<Annotation> getAnnotationsForMethods(long[] methodHashes);
+   List<Annotation> getAnnotationsForMethods(long[] methodHashes);
 
-   public abstract MetaDataRepository getRepository();
+   MetaDataRepository getRepository();
 
 }
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 02:04:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 02:04:58 -0500
Subject: [jboss-cvs] JBossAS SVN: r59033 -
	projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature
Message-ID: <E1GukeI-000329-46@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 02:04:55 -0500 (Thu, 14 Dec 2006)
New Revision: 59033

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java
Log:
small fixes

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java	2006-12-14 07:02:45 UTC (rev 59032)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/metadata/spi/signature/Signature.java	2006-12-14 07:04:55 UTC (rev 59033)
@@ -80,7 +80,7 @@
     * @param parameters the parameters as strings
     * @return the parameters as classes
     */
-   private static Class[] stringstoClasses(Class clazz, String... parameters)
+   private static Class[] stringsToClasses(Class clazz, String... parameters)
    {
       if (clazz == null)
          throw new IllegalArgumentException("Null clazz");
@@ -234,7 +234,7 @@
    public Class[] getParametersTypes(Class clazz)
    {
       if (parameterTypes == null)
-         return stringstoClasses(clazz, parameters);
+         return stringsToClasses(clazz, parameters);
       return parameterTypes;
    }
    



From gavin.king at jboss.com  Thu Dec 14 02:14:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 02:14:10 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en  ...
Message-ID: <E1GuknC-0003CH-2q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 02:14:10

  Modified:    doc/reference/en  master.xml
  Log:
  JBSEAM-594
  
  Revision  Changes    Path
  1.47      +1 -1      jboss-seam/doc/reference/en/master.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: master.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/master.xml,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -b -r1.46 -r1.47
  --- master.xml	13 Dec 2006 10:10:43 -0000	1.46
  +++ master.xml	14 Dec 2006 07:14:09 -0000	1.47
  @@ -77,7 +77,7 @@
                       <para>
                           Neither of these approaches would work well, were it not for Seam's built-in concurrency 
                           and state management, which ensures that many concurrent fine-grained, asynchronous AJAX 
  -                        requests are handled safely and efficiently on the server side
  +                        requests are handled safely and efficiently on the server side.
                       </para>
                   </listitem>
               </varlistentry>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 02:14:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 02:14:10 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules   ...
Message-ID: <E1GuknC-0003CR-7h@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 02:14:10

  Modified:    doc/reference/en/modules   events.xml framework.xml
  Log:
  JBSEAM-594
  
  Revision  Changes    Path
  1.7       +4 -4      jboss-seam/doc/reference/en/modules/events.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: events.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/events.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- events.xml	16 Nov 2006 17:39:16 -0000	1.6
  +++ events.xml	14 Dec 2006 07:14:10 -0000	1.7
  @@ -212,7 +212,7 @@
       <page view-id="/calculator.jsp" action="#{calculator.calculate}">
           <param name="x" value="#{calculator.lhs}"/>
           <param name="y" value="#{calculator.rhs}"/>
  -        <param name="op" converterId="com.my.calculator.OperatorConverter"/>
  +        <param name="op" converterId="com.my.calculator.OperatorConverter" value="#{calculator.op}"/>
       </page>
   <pages>]]></programlisting>
   
  @@ -220,9 +220,9 @@
       <page view-id="/calculator.jsp" action="#{calculator.calculate}">
           <param name="x" value="#{calculator.lhs}"/>
           <param name="y" value="#{calculator.rhs}"/>
  -        <param name="op" converter="#{operatorConverter}"/>
  +        <param name="op" converter="#{operatorConverter}" value="#{calculator.op}"/>
       </page>
  -<pages>]]></programlisting>
  +</pages>]]></programlisting>
   
           </sect3>
   
  @@ -241,7 +241,7 @@
               <programlisting><![CDATA[<page action="#{calculator.calculate}">
       <param name="x" value="#{calculator.lhs}"/>
       <param name="y" value="#{calculator.rhs}"/>
  -    <param name="op" converter="#{operatorConverter}"/>
  +    <param name="op" converter="#{operatorConverter}" value="#{calculator.op}"/>
   </page>]]></programlisting>
   
           </sect3>
  
  
  
  1.11      +19 -4     jboss-seam/doc/reference/en/modules/framework.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: framework.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/framework.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- framework.xml	29 Nov 2006 10:28:03 -0000	1.10
  +++ framework.xml	14 Dec 2006 07:14:10 -0000	1.11
  @@ -197,7 +197,7 @@
   
           <programlisting><![CDATA[<pages>
       <page viewid="/editPerson.jsp">
  -        <param name="personId">#{personHome.id}</param>
  +        <param name="personId" value="#{personHome.id}"/>
       </page>
   </pages>]]></programlisting>
   
  @@ -359,7 +359,8 @@
               can use a Query object. For example:
           </para>
           
  -        <programlisting><![CDATA[<framework:entity-query name="people" eqbql="select p from Person p"/>]]></programlisting>
  +        <programlisting><![CDATA[<framework:entity-query name="people" 
  +                        eqbql="select p from Person p"/>]]></programlisting>
           
           <para>
               We can use it from a JSF page:
  @@ -378,7 +379,21 @@
               We probably need to support pagination:
           </para>
           
  -        <programlisting><![CDATA[<framework:entity-query name="people" eqbql="select p from Person p" order="lastName" max-results="20"/>]]></programlisting>
  +        <programlisting><![CDATA[<framework:entity-query name="people" 
  +                        eqbql="select p from Person p" 
  +                        order="lastName" 
  +                        max-results="20"/>]]></programlisting>
  +
  +        <para>
  +            We'll use a page parameter to determine the page to display:
  +        </para>
  +
  +
  +        <programlisting><![CDATA[<pages>
  +    <page viewid="/searchPerson.jsp">
  +        <param name="firstResult" value="#{people.firstResult}"/>
  +    </page>
  +</pages>]]></programlisting>
   
           <para>
               The JSF code for a pagination control is a bit verbose, but manageable:
  
  
  


From gavin.king at jboss.com  Thu Dec 14 02:19:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 02:19:04 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1Gukrw-0003HC-NV@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 02:19:04

  Modified:    doc/reference/en/modules  framework.xml
  Log:
  JBSEAM-590
  
  Revision  Changes    Path
  1.12      +6 -3      jboss-seam/doc/reference/en/modules/framework.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: framework.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/framework.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- framework.xml	14 Dec 2006 07:14:10 -0000	1.11
  +++ framework.xml	14 Dec 2006 07:19:04 -0000	1.12
  @@ -360,7 +360,7 @@
           </para>
           
           <programlisting><![CDATA[<framework:entity-query name="people" 
  -                        eqbql="select p from Person p"/>]]></programlisting>
  +                        ejbql="select p from Person p"/>]]></programlisting>
           
           <para>
               We can use it from a JSF page:
  @@ -380,7 +380,7 @@
           </para>
           
           <programlisting><![CDATA[<framework:entity-query name="people" 
  -                        eqbql="select p from Person p" 
  +                        ejbql="select p from Person p" 
                           order="lastName" 
                           max-results="20"/>]]></programlisting>
   
  @@ -432,7 +432,10 @@
   
           <programlisting><![CDATA[<component name="examplePerson" class="Person"/>
           
  -<framework:entity-query name="people" eqbql="select p from Person p" order="lastName" max-results="20">
  +<framework:entity-query name="people" 
  +                        ejbql="select p from Person p" 
  +                        order="lastName" 
  +                        max-results="20">
       <framework:restrictions>
           <value>lower(firstName) like lower( #{examplePerson.firstName} + '%' )</value>
           <value>lower(lastName) like lower( #{examplePerson.lastName} + '%' )</value>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 02:19:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 02:19:04 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1Gukrw-0003HJ-RC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 02:19:04

  Modified:    src/main/org/jboss/seam  framework-1.1.xsd
  Log:
  JBSEAM-590
  
  Revision  Changes    Path
  1.6       +1 -1      jboss-seam/src/main/org/jboss/seam/framework-1.1.xsd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: framework-1.1.xsd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework-1.1.xsd,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- framework-1.1.xsd	29 Nov 2006 10:29:09 -0000	1.5
  +++ framework-1.1.xsd	14 Dec 2006 07:19:04 -0000	1.6
  @@ -15,7 +15,7 @@
       </xs:attributeGroup>
   
       <xs:attributeGroup name="attlist.Query">
  -        <xs:attribute name="eqbql" type="xs:string"/>
  +        <xs:attribute name="ejbql" type="xs:string"/>
           <xs:attribute name="max-results" type="xs:integer"/>
           <xs:attribute name="order" type="xs:string"/>
       </xs:attributeGroup>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 02:32:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 02:32:18 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1Gul4k-0003VA-JF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 02:32:18

  Modified:    jboss-seam  seam.bat
  Log:
  JBSEAM-588
  
  Revision  Changes    Path
  1.17      +1 -1      jboss-seam/seam.bat
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.bat
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam.bat,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- seam.bat	29 Nov 2006 14:23:08 -0000	1.16
  +++ seam.bat	14 Dec 2006 07:32:18 -0000	1.17
  @@ -8,7 +8,7 @@
   set PROGNAME=seam.bat
   if "%OS%" == "Windows_NT" set PROGNAME=%~nx0%
   
  -set SEAMGENDIR=%DIRNAME%\seam-gen
  +set SEAMGENDIR="%DIRNAME%\seam-gen"
   
   set SEAMTASK=%1%
   set ARGS=%ARGS% %*
  
  
  


From gavin.king at jboss.com  Thu Dec 14 03:37:50 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 03:37:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/framework    ...
Message-ID: <E1Gum6A-0004mC-0v@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 03:37:50

  Modified:    src/main/org/jboss/seam/framework    EntityQuery.java
                        HibernateEntityQuery.java Query.java
  Log:
  fix JBSEAM-591
  
  Revision  Changes    Path
  1.6       +14 -11    jboss-seam/src/main/org/jboss/seam/framework/EntityQuery.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityQuery.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/EntityQuery.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- EntityQuery.java	25 Oct 2006 15:14:35 -0000	1.5
  +++ EntityQuery.java	14 Dec 2006 08:37:49 -0000	1.6
  @@ -7,7 +7,6 @@
   
   import org.jboss.seam.Component;
   import org.jboss.seam.annotations.Transactional;
  -import org.jboss.seam.core.Expressions.ValueBinding;
   
   public class EntityQuery extends Query
   {
  @@ -32,7 +31,7 @@
      @Override
      public List getResultList()
      {
  -      if (resultList==null)
  +      if (resultList==null || isAnyParameterDirty())
         {
            javax.persistence.Query query = createQuery();
            resultList = query==null ? null : query.getResultList();
  @@ -44,7 +43,7 @@
      @Override
      public Object getSingleResult()
      {
  -      if (singleResult==null)
  +      if (singleResult==null || isAnyParameterDirty())
         {
            javax.persistence.Query query = createQuery();
            singleResult = query==null ? 
  @@ -57,7 +56,7 @@
      @Override
      public Long getResultCount()
      {
  -      if (resultCount==null)
  +      if (resultCount==null || isAnyParameterDirty())
         {
            javax.persistence.Query query = createCountQuery();
            resultCount = query==null ? 
  @@ -93,10 +92,12 @@
      {
         parseEjbql();
         
  +      evaluateAllParameters();
  +      
         getEntityManager().joinTransaction();
         javax.persistence.Query query = getEntityManager().createQuery( getRenderedEjbql() );
  -      setParameters( query, getQueryParameters(), 0 );
  -      setParameters( query, getRestrictionParameters(), getQueryParameters().size() );
  +      setParameters( query, getQueryParameterValues(), 0 );
  +      setParameters( query, getRestrictionParameterValues(), getQueryParameterValues().size() );
         if ( getFirstResult()!=null) query.setFirstResult( getFirstResult() );
         if ( getMaxResults()!=null) query.setMaxResults( getMaxResults() );
         if ( getHints()!=null )
  @@ -113,18 +114,20 @@
      {
         parseEjbql();
         
  +      evaluateAllParameters();
  +
         getEntityManager().joinTransaction();
         javax.persistence.Query query = getEntityManager().createQuery( getCountEjbql() );
  -      setParameters( query, getQueryParameters(), 0 );
  -      setParameters( query, getRestrictionParameters(), getQueryParameters().size() );
  +      setParameters( query, getQueryParameterValues(), 0 );
  +      setParameters( query, getRestrictionParameterValues(), getQueryParameterValues().size() );
         return query;
      }
   
  -   private void setParameters(javax.persistence.Query query, List<ValueBinding> parameters, int start)
  +   private void setParameters(javax.persistence.Query query, List<Object> parameters, int start)
      {
         for (int i=0; i<parameters.size(); i++)
         {
  -         Object parameterValue = parameters.get(i).getValue();
  +         Object parameterValue = parameters.get(i);
            if (parameterValue!=null)
            {
               query.setParameter( "p" + (start + i), parameterValue );
  
  
  
  1.5       +13 -10    jboss-seam/src/main/org/jboss/seam/framework/HibernateEntityQuery.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HibernateEntityQuery.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/HibernateEntityQuery.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- HibernateEntityQuery.java	15 Oct 2006 21:54:49 -0000	1.4
  +++ HibernateEntityQuery.java	14 Dec 2006 08:37:49 -0000	1.5
  @@ -5,7 +5,6 @@
   import org.hibernate.Session;
   import org.jboss.seam.Component;
   import org.jboss.seam.annotations.Transactional;
  -import org.jboss.seam.core.Expressions.ValueBinding;
   
   public class HibernateEntityQuery extends Query
   {
  @@ -33,7 +32,7 @@
      @Override
      public List getResultList()
      {
  -      if (resultList==null)
  +      if (resultList==null || isAnyParameterDirty())
         {
            org.hibernate.Query query = createQuery();
            resultList = query==null ? null : query.list();
  @@ -45,7 +44,7 @@
      @Override
      public Object getSingleResult()
      {
  -      if (singleResult==null)
  +      if (singleResult==null || isAnyParameterDirty())
         {
            org.hibernate.Query query = createQuery();
            singleResult = query==null ? 
  @@ -58,7 +57,7 @@
      @Override
      public Long getResultCount()
      {
  -      if (resultCount==null)
  +      if (resultCount==null || isAnyParameterDirty())
         {
            org.hibernate.Query query = createCountQuery();
            resultCount = query==null ? 
  @@ -94,9 +93,11 @@
      {
         parseEjbql();
         
  +      evaluateAllParameters();
  +      
         org.hibernate.Query query = getSession().createQuery( getRenderedEjbql() );
  -      setParameters( query, getQueryParameters(), 0 );
  -      setParameters( query, getRestrictionParameters(), getQueryParameters().size() );
  +      setParameters( query, getQueryParameterValues(), 0 );
  +      setParameters( query, getRestrictionParameterValues(), getQueryParameterValues().size() );
         if ( getFirstResult()!=null) query.setFirstResult( getFirstResult() );
         if ( getMaxResults()!=null) query.setMaxResults( getMaxResults() );
         if ( getCacheable()!=null ) query.setCacheable( getCacheable() );
  @@ -109,17 +110,19 @@
      {
         parseEjbql();
         
  +      evaluateAllParameters();
  +      
         org.hibernate.Query query = getSession().createQuery( getCountEjbql() );
  -      setParameters( query, getQueryParameters(), 0 );
  -      setParameters( query, getRestrictionParameters(), getQueryParameters().size() );
  +      setParameters( query, getQueryParameterValues(), 0 );
  +      setParameters( query, getRestrictionParameterValues(), getQueryParameterValues().size() );
         return query;
      }
   
  -   private void setParameters(org.hibernate.Query query, List<ValueBinding> parameters, int start)
  +   private void setParameters(org.hibernate.Query query, List<Object> parameters, int start)
      {
         for (int i=0; i<parameters.size(); i++)
         {
  -         Object parameterValue = parameters.get(i).getValue();
  +         Object parameterValue = parameters.get(i);
            if (parameterValue!=null)
            {
               query.setParameter( "p" + (start + i), parameterValue );
  
  
  
  1.13      +60 -0     jboss-seam/src/main/org/jboss/seam/framework/Query.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Query.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/Query.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- Query.java	10 Dec 2006 15:54:24 -0000	1.12
  +++ Query.java	14 Dec 2006 08:37:49 -0000	1.13
  @@ -27,6 +27,9 @@
      private List<String> parsedRestrictions;
      private List<ValueBinding> restrictionParameters;
      
  +   private List<Object> queryParameterValues;
  +   private List<Object> restrictionParameterValues;
  +   
      public abstract List getResultList();
      public abstract Object getSingleResult();
      public abstract Long getResultCount();
  @@ -276,4 +279,61 @@
         return restrictionParameters;
      }
   
  +   private static boolean isAnyParameterDirty(List<ValueBinding> valueBindings, List<Object> lastParameterValues)
  +   {
  +      if (lastParameterValues==null) return true;
  +      for (int i=0; i<valueBindings.size(); i++)
  +      {
  +         Object parameterValue = valueBindings.get(i).getValue();
  +         Object lastParameterValue = lastParameterValues.get(i);
  +         if ( parameterValue!=lastParameterValue && ( parameterValue==null || !parameterValue.equals(lastParameterValue) ) )
  +         {
  +            return true;
  +         }
  +      }
  +      return false;
  +   }
  +   
  +   private static List<Object> getParameterValues(List<ValueBinding> valueBindings)
  +   {
  +      List<Object> values = new ArrayList<Object>( valueBindings.size() );
  +      for (int i=0; i<valueBindings.size(); i++)
  +      {
  +         values.add( valueBindings.get(i).getValue() );
  +      }
  +      return values;
  +   }
  +   
  +   protected void evaluateAllParameters()
  +   {
  +      setQueryParameterValues( getParameterValues( getQueryParameters() ) );
  +      setRestrictionParameterValues( getParameterValues( getRestrictionParameters() ) );
  +   }
  +   
  +   protected boolean isAnyParameterDirty()
  +   {
  +      return isAnyParameterDirty( getQueryParameters(), getQueryParameterValues() )
  +            || isAnyParameterDirty( getRestrictionParameters(), getRestrictionParameterValues() );
  +   }
  +   
  +   protected List<Object> getQueryParameterValues()
  +   {
  +      return queryParameterValues;
  +   }
  +   
  +   protected void setQueryParameterValues(List<Object> queryParameterValues)
  +   {
  +      this.queryParameterValues = queryParameterValues;
  +   }
  +   
  +   protected List<Object> getRestrictionParameterValues()
  +   {
  +      return restrictionParameterValues;
  +   }
  +   
  +   protected void setRestrictionParameterValues(List<Object> restrictionParameterValues)
  +   {
  +      this.restrictionParameterValues = restrictionParameterValues;
  +   }
  +
   }
  
  
  


From gavin.king at jboss.com  Thu Dec 14 03:52:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 03:52:18 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1GumKA-00051S-7X@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 03:52:18

  Modified:    src/ui/org/jboss/seam/ui   HtmlButton.java HtmlLink.java
  Log:
  fix JBSEAM-592
  
  Revision  Changes    Path
  1.4       +13 -2     jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlButton.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- HtmlButton.java	1 Dec 2006 23:28:25 -0000	1.3
  +++ HtmlButton.java	14 Dec 2006 08:52:18 -0000	1.4
  @@ -30,6 +30,7 @@
      private String pageflow;
      private String propagation = "default";
      private String fragment;
  +   private String outcome;
   
      private UISelection getSelection()
      {
  @@ -128,10 +129,10 @@
            }
         }
         
  -      if (action!=null)
  +      if ( action!=null || outcome!=null )
         {
            UIAction uiAction = new UIAction();
  -         uiAction.setAction( action.getExpressionString() );
  +         uiAction.setAction( action==null ? outcome : action.getExpressionString() );
            encodedUrl += getParameterString(characterEncoding, uiAction, first);
            first = false;
         }
  @@ -330,4 +331,14 @@
         // TODO Auto-generated method stub
      }
   
  +   public String getOutcome()
  +   {
  +      return outcome;
  +   }
  +
  +   public void setOutcome(String outcome)
  +   {
  +      this.outcome = outcome;
  +   }
  +
   }
  
  
  
  1.24      +14 -2     jboss-seam/src/ui/org/jboss/seam/ui/HtmlLink.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlLink.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlLink.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- HtmlLink.java	19 Nov 2006 17:36:11 -0000	1.23
  +++ HtmlLink.java	14 Dec 2006 08:52:18 -0000	1.24
  @@ -32,6 +32,7 @@
      private String propagation = "default";
      private String fragment;
      private boolean disabled;
  +   private String outcome;
   
      private UISelection getSelection()
      {
  @@ -128,10 +129,10 @@
            }
         }
         
  -      if (action!=null)
  +      if ( action!=null || outcome!=null )
         {
            UIAction uiAction = new UIAction();
  -         uiAction.setAction( action.getExpressionString() );
  +         uiAction.setAction( action==null ? outcome : action.getExpressionString() );
            encodedUrl += getParameterString(characterEncoding, uiAction, first);
            first = false;
         }
  @@ -340,4 +341,15 @@
         // TODO Auto-generated method stub
      }
   
  +   public String getOutcome()
  +   {
  +      return outcome;
  +   }
  +
  +   public void setOutcome(String outcome)
  +   {
  +      this.outcome = outcome;
  +   }
  +
  +
   }
  
  
  


From gavin.king at jboss.com  Thu Dec 14 03:52:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 03:52:18 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui/tag   ...
Message-ID: <E1GumKA-00051c-C5@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 03:52:18

  Modified:    src/ui/org/jboss/seam/ui/tag   EnumItemTag.java
                        UIComponentTagBase.java
  Log:
  fix JBSEAM-592
  
  Revision  Changes    Path
  1.2       +0 -1      jboss-seam/src/ui/org/jboss/seam/ui/tag/EnumItemTag.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EnumItemTag.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/EnumItemTag.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- EnumItemTag.java	12 Dec 2006 22:38:26 -0000	1.1
  +++ EnumItemTag.java	14 Dec 2006 08:52:18 -0000	1.2
  @@ -1,7 +1,6 @@
   package org.jboss.seam.ui.tag;
   
   import javax.faces.component.UIComponent;
  -import javax.servlet.jsp.JspException;
   
   import org.jboss.seam.ui.EnumItem;
   
  
  
  
  1.8       +2 -2      jboss-seam/src/ui/org/jboss/seam/ui/tag/UIComponentTagBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIComponentTagBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/UIComponentTagBase.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- UIComponentTagBase.java	19 Nov 2006 17:36:11 -0000	1.7
  +++ UIComponentTagBase.java	14 Dec 2006 08:52:18 -0000	1.8
  @@ -37,7 +37,7 @@
   
   /**
    * @author Manfred Geiler (latest modification by $Author: gavin $)
  - * @version $Revision: 1.7 $ $Date: 2006/11/19 17:36:11 $
  + * @version $Revision: 1.8 $ $Date: 2006/12/14 08:52:18 $
    */
   public abstract class UIComponentTagBase extends UIComponentTag
   {
  @@ -320,7 +320,7 @@
            }
            else
            {
  -            log.error("Invalid expression " + action);
  +            component.getAttributes().put("outcome", action);
            }
         }
      }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 03:58:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 03:58:45 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1790 - in
	trunk/src/main/org/jboss/jms/client: container delegate
	remoting state
Message-ID: <E1GumQP-00057w-V5@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 03:58:42 -0500 (Thu, 14 Dec 2006)
New Revision: 1790

Added:
   trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
Log:
Fixed bug: HAAspect used to add a remoting connection failure listener without 
actually realizing that a connection listener might have already been installed
by the ConnectionAspect (the connection listener is the ConnectionAspect instance
itself). More than that, on connection closing it did not cleanly remove the failure 
listener, leading to all kind of undeterministic behavior on failover.


Modified: trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -23,17 +23,17 @@
 
 import javax.jms.ExceptionListener;
 import javax.jms.IllegalStateException;
-import javax.jms.JMSException;
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.JBossConnectionMetaData;
+import org.jboss.jms.client.remoting.ConsolidatedRemotingConnectionListener;
+import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
-import org.jboss.remoting.ConnectionListener;
 
 /**
  * Handles operations related to the connection
@@ -47,22 +47,23 @@
  *
  * $Id$
  */
-public class ConnectionAspect implements ConnectionListener
+public class ConnectionAspect
 {
    // Constants -----------------------------------------------------
-   
-   // Static --------------------------------------------------------
-   
+
    private static final Logger log = Logger.getLogger(ConnectionAspect.class);
-   private static boolean trace = log.isTraceEnabled();
    
+   // Static --------------------------------------------------------
+
    // Attributes ----------------------------------------------------
-   
-   
+
    protected JBossConnectionMetaData connMetaData;
    
    protected ConnectionState state;
-   
+
+   // The identity of the delegate this interceptor is associated with
+   private Integer id;
+
    // Constructors --------------------------------------------------
    
    // Public --------------------------------------------------------
@@ -108,40 +109,21 @@
    
    public Object handleGetExceptionListener(Invocation invocation) throws Throwable
    {
-      ConnectionState currentState = getConnectionState(invocation);
-      currentState.setJustCreated(false);
+      ConnectionState state = getConnectionState(invocation);
+      state.setJustCreated(false);
       
-      return currentState.getExceptionListener();
+      return state.getRemotingConnectionListener().getJMSExceptionListener();
    }
    
    public Object handleSetExceptionListener(Invocation invocation) throws Throwable
    {
-      ConnectionState currentState = getConnectionState(invocation);
-      currentState.setJustCreated(false);
+      ConnectionState state = getConnectionState(invocation);
+      state.setJustCreated(false);
       
       MethodInvocation mi = (MethodInvocation)invocation;
-      
-      currentState.setExceptionListener((ExceptionListener)mi.getArguments()[0]);
-      
-      Client client = getConnectionState(invocation).getRemotingConnection().getInvokingClient();
-      
-      if (client == null)
-      {
-         throw new java.lang.IllegalStateException("Cannot find remoting client");
-      }
-      
-      if (currentState.getExceptionListener() != null)
-      {
-         client.addConnectionListener(this);
-         currentState.setListenerAdded(true);
-      }
-      else
-      {
-         if (currentState.isListenerAdded())
-         {
-            client.removeConnectionListener(this);
-         }
-      }
+      ExceptionListener exceptionListener = (ExceptionListener)mi.getArguments()[0];
+      state.getRemotingConnectionListener().addJMSExceptionListener(exceptionListener);
+
       return null;
    }
    
@@ -184,63 +166,44 @@
    {
       Object ret = invocation.invokeNext();
       
-      // Remove any exception listener
-      ConnectionState currentState = getConnectionState(invocation);
-      
-      Client client = getConnectionState(invocation).getRemotingConnection().getInvokingClient();
-      
-      if (currentState.isListenerAdded())
-      {
-         client.removeConnectionListener(this);
-      }
-            
       ConnectionState state = getConnectionState(invocation);
-      
+
+      JMSRemotingConnection remotingConnection = state.getRemotingConnection();
+
+      // remove the consolidated remoting connection listener
+      ConsolidatedRemotingConnectionListener listener = state.getRemotingConnectionListener();
+      listener.clear();
+
+      Client client = remotingConnection.getInvokingClient();
+      boolean removed = client.removeConnectionListener(listener);
+
+      log.debug(this + (removed ? " removed " : " failed to remove ") +
+                "the consolidated remoting connection listener from " + client);
+
       // Finished with the connection - we need to shutdown callback server
-      state.getRemotingConnection().stop();
+      remotingConnection.stop();
        
-      // Remove reference to message id generator
+      // Remove reference to message ID generator
       MessageIdGeneratorFactory.instance.checkInGenerator(state.getServerID());
-      
+
       return ret;
    }
-   
-   
-   // ConnectionListener implementation -----------------------------------------------------------
-   
-   public void handleConnectionException(Throwable t, Client c)
+
+   public String toString()
    {
-      log.error("Caught exception from connection", t);
-      
-      if (state.getExceptionListener()!= null)
+      StringBuffer sb = new StringBuffer("ConnectionAspect[");
+
+      if (id == null)
       {
-         JMSException j = null;
-         if (t instanceof Error)
-         {
-            final String msg = "Caught Error on underlying connection";
-            log.error(msg, t);
-            j = new JMSException(msg + ": " + t.getMessage());
-         }
-         else if (t instanceof Exception)
-         {
-            Exception e =(Exception)t;
-            j = new JMSException("Throwable received from underlying connection");
-            j.setLinkedException(e);
-         }
-         else
-         {
-            //Some other Throwable subclass
-            final String msg = "Caught Throwable on underlying connection";
-            log.error(msg, t);
-            j = new JMSException(msg + ": " + t.getMessage());
-         }
-         synchronized (state.getExceptionListener())
-         {
-            state.getExceptionListener().onException(j);
-         }
+         sb.append("UNINITIALIZED]");
       }
+      else
+      {
+         sb.append(id).append("]");
+      }
+      return sb.toString();
    }
-   
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------
@@ -249,12 +212,14 @@
    
    private ConnectionState getConnectionState(Invocation invocation)
    {
-      if (state==null)
+      if (state == null)
       {
          ClientConnectionDelegate currentDelegate =
             ((ClientConnectionDelegate)invocation.getTargetObject());
          
          state = (ConnectionState)currentDelegate.getState();
+         id = new Integer(state.getDelegate().getID());
+
       }
       return state;
    }

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -147,13 +147,14 @@
 
       if(trace) { log.trace(this + " got local connection delegate " + cd); }
 
-      // Add a connection listener to detect failure
+      // Add a connection listener to detect failure; the consolidated remoting connection listener
+      // must be already in place and configured
 
       ConnectionListener listener = new ConnectionFailureListener(cd);
-      ConnectionState state = (ConnectionState)((DelegateSupport)cd).getState();
-      if(trace) { log.trace(this + " registering " + listener + " on " + cd); }
-      state.getRemotingConnection().getInvokingClient().addConnectionListener(listener);
 
+      ((ConnectionState)((DelegateSupport)cd).getState()).
+         getRemotingConnectionListener().addDelegateListener(listener);
+
       return new CreateConnectionResult(cd);
    }
 

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -30,6 +30,7 @@
 import org.jboss.jms.client.delegate.ClientProducerDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
+import org.jboss.jms.client.remoting.ConsolidatedRemotingConnectionListener;
 import org.jboss.jms.client.state.BrowserState;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.client.state.ConsumerState;
@@ -98,18 +99,26 @@
 
          int serverID = connectionDelegate.getServerID();
          Version versionToUse = connectionDelegate.getVersionToUse();
-         JMSRemotingConnection remotingConn = connectionDelegate.getRemotingConnection();
+         JMSRemotingConnection remotingConnection = connectionDelegate.getRemotingConnection();
 
+         // install the consolidated remoting connection listener; it will be de-installed on
+         // connection closing by ConnectionAspect
+
+         ConsolidatedRemotingConnectionListener listener = new ConsolidatedRemotingConnectionListener();
+         remotingConnection.getInvokingClient().addConnectionListener(listener);
+
          if (versionToUse == null)
          {
             throw new IllegalStateException("Connection version is null");
          }
 
          // We have one message id generator per unique server
-         MessageIdGenerator g = MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
+         MessageIdGenerator idGenerator =
+            MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
 
          ConnectionState connectionState =
-            new ConnectionState(serverID, connectionDelegate, remotingConn, versionToUse, g);
+            new ConnectionState(serverID, connectionDelegate, remotingConnection,
+                                listener, versionToUse, idGenerator);
 
          connectionDelegate.setState(connectionState);
 

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -294,7 +294,7 @@
 
    public String toString()
    {
-      return "ClientConnectionFactoryDelegate[" + id + ", " + serverID + "]";
+      return "ConnectionFactoryDelegate[" + id + ", " + serverID + "]";
    }
    
    public String getServerLocatorURI()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -119,7 +119,7 @@
 
    public String toString()
    {
-      StringBuffer sb = new StringBuffer("ClusteredConnFactoryDelegate[");
+      StringBuffer sb = new StringBuffer("ClusteredConnectionFactoryDelegate[");
       sb.append(id).append("][");
       if (delegates == null)
       {

Added: trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -0,0 +1,170 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.remoting;
+
+import org.jboss.remoting.ConnectionListener;
+import org.jboss.remoting.Client;
+import org.jboss.logging.Logger;
+import org.jboss.jms.client.state.ConnectionState;
+
+import javax.jms.ExceptionListener;
+import javax.jms.JMSException;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Iterator;
+
+/**
+ * The ONLY remoting connection listener for a JMS connection's underlying remoting connection.
+ * Added to the remoting connection when the JMS connection is created, and removed when the
+ * JMS connection is closed. Any second tier listeners (the JMS connection ExceptionListener,
+ * and the HA's connection failure detector) are registered with this consolidated listener and not
+ * with the remoting connection directly.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class ConsolidatedRemotingConnectionListener implements ConnectionListener
+{
+   // Constants -----------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(ConsolidatedRemotingConnectionListener.class);
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private ConnectionState state;
+
+   private ExceptionListener jmsExceptionListener;
+
+   // List<ConnectionListener>
+   private List delegateListeners;
+
+   // Constructors --------------------------------------------------
+
+   public ConsolidatedRemotingConnectionListener()
+   {
+      delegateListeners = new ArrayList();
+   }
+
+   // ConnectionListener implementation -----------------------------
+
+   public void handleConnectionException(Throwable throwable, Client client)
+   {
+      // forward the exception to delegate listeners and JMS ExceptionListeners; synchronize and
+      // copy to avoid race conditions
+
+      ExceptionListener jmsExceptionListenerCopy;
+      List delegateListenersCopy = new ArrayList();
+
+      synchronized(this)
+      {
+         jmsExceptionListenerCopy = jmsExceptionListener;
+
+         for(Iterator i = delegateListeners.iterator(); i.hasNext(); )
+         {
+            delegateListenersCopy.add(i.next());
+         }
+      }
+
+      for(Iterator i = delegateListenersCopy.iterator(); i.hasNext(); )
+      {
+         ConnectionListener l = (ConnectionListener)i.next();
+
+         try
+         {
+            log.debug(this + " forwarding remoting failure " + throwable + " to " + l);
+            l.handleConnectionException(throwable, client);
+         }
+         catch(Exception e)
+         {
+            log.warn("Failed to forward " + throwable + " to " + l, e);
+         }
+      }
+
+      if (jmsExceptionListenerCopy != null)
+      {
+         JMSException jmsException = null;
+
+         if (throwable instanceof Error)
+         {
+            final String msg = "Caught Error on underlying remoting connection";
+            log.error(this + ": " + msg, throwable);
+            jmsException = new JMSException(msg + ": " + throwable.getMessage());
+         }
+         else if (throwable instanceof Exception)
+         {
+            Exception e = (Exception)throwable;
+            jmsException = new JMSException("Failure on underlying remoting connection");
+            jmsException.setLinkedException(e);
+         }
+         else
+         {
+            // Some other Throwable subclass
+            final String msg = "Caught Throwable on underlying remoting connection";
+            log.error(this + ": " + msg, throwable);
+            jmsException = new JMSException(msg + ": " + throwable.getMessage());
+         }
+
+         jmsExceptionListenerCopy.onException(jmsException);
+      }
+   }
+
+   // Public --------------------------------------------------------
+
+   public synchronized boolean addDelegateListener(ConnectionListener l)
+   {
+      log.debug(this + " adding delegate listener " + l);
+      return delegateListeners.add(l);
+   }
+
+   public synchronized void addJMSExceptionListener(ExceptionListener jmsExceptionListener)
+   {
+      log.debug(this + " adding JMS exception listener " + jmsExceptionListener);
+      this.jmsExceptionListener = jmsExceptionListener;
+   }
+
+   public synchronized ExceptionListener getJMSExceptionListener()
+   {
+      return jmsExceptionListener;
+   }
+
+   /**
+    * Clears all delegate listeners
+    */
+   public synchronized void clear()
+   {
+      jmsExceptionListener = null;
+      delegateListeners.clear();
+      log.debug(this + " cleared");
+   }
+
+   public void setConnectionState(ConnectionState state)
+   {
+      this.state = state;
+   }
+
+   public String toString()
+   {
+      if (state == null)
+      {
+         return "ConsolidatedRemotingConnectionListener(UNINITIALIZED)";
+      }
+      return state + ".ConsolidatedRemotingConnectionListener";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-14 06:47:18 UTC (rev 1789)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-14 08:58:42 UTC (rev 1790)
@@ -23,11 +23,10 @@
 
 import java.util.HashSet;
 
-import javax.jms.ExceptionListener;
-
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
+import org.jboss.jms.client.remoting.ConsolidatedRemotingConnectionListener;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.server.Version;
@@ -53,6 +52,8 @@
 
    private JMSRemotingConnection remotingConnection;
 
+   private ConsolidatedRemotingConnectionListener remotingConnectionListener;
+
    private ResourceManager resourceManager;
 
    private MessageIdGenerator idGenerator;
@@ -75,16 +76,12 @@
    private String clientID;
 
     /** This property used to be delcared on ConnectionAspect */
-   private ExceptionListener exceptionListener;
-
-    /** This property used to be delcared on ConnectionAspect */
    private boolean justCreated = true;
 
-    /** This property used to be delcared on ConnectionAspect */
-   private boolean listenerAdded;
-   
    public ConnectionState(int serverID, ConnectionDelegate delegate,
-                          JMSRemotingConnection remotingConnection, Version versionToUse,
+                          JMSRemotingConnection remotingConnection,
+                          ConsolidatedRemotingConnectionListener remotingConnectionListener,
+                          Version versionToUse,
                           MessageIdGenerator gen)
       throws Exception
    {
@@ -97,6 +94,9 @@
       this.remotingConnection = remotingConnection;
       this.versionToUse = versionToUse;
 
+      this.remotingConnectionListener = remotingConnectionListener;
+      remotingConnectionListener.setConnectionState(this);
+
       // Each connection has its own resource manager. If we can failover all connections with the
       // same server id at the same time then we can maintain one rm per unique server as opposed to
       // per connection.
@@ -121,9 +121,9 @@
       return remotingConnection;
    }
 
-   public void setRemotingConnection(JMSRemotingConnection remotingConnection)
+   public ConsolidatedRemotingConnectionListener getRemotingConnectionListener()
    {
-       this.remotingConnection=remotingConnection;
+      return remotingConnectionListener;
    }
 
    public Version getVersionToUse()
@@ -193,16 +193,6 @@
       this.clientID = clientID;
    }
 
-   public ExceptionListener getExceptionListener()
-   {
-      return exceptionListener;
-   }
-
-   public void setExceptionListener(ExceptionListener exceptionListener)
-   {
-      this.exceptionListener = exceptionListener;
-   }
-
    public boolean isJustCreated()
    {
       return justCreated;
@@ -213,17 +203,9 @@
       this.justCreated = justCreated;
    }
 
-   public boolean isListenerAdded()
-   {
-      return listenerAdded;
-   }
-
-   public void setListenerAdded(boolean listenerAdded)
-   {
-      this.listenerAdded = listenerAdded;
-   }
-
-   /** Connection doesn't have a parent */
+   /**
+    * Connection doesn't have a parent
+    */
    public HierarchicalState getParent()
    {
       return null;



From gavin.king at jboss.com  Thu Dec 14 04:10:55 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 04:10:55 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1GumcB-0005Vt-GF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 04:10:55

  Modified:    src/ui/org/jboss/seam/ui   EnumItem.java SelectDate.java
  Log:
  warnings
  
  Revision  Changes    Path
  1.2       +2 -2      jboss-seam/src/ui/org/jboss/seam/ui/EnumItem.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EnumItem.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/EnumItem.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- EnumItem.java	12 Dec 2006 22:38:26 -0000	1.1
  +++ EnumItem.java	14 Dec 2006 09:10:55 -0000	1.2
  @@ -1,10 +1,9 @@
   package org.jboss.seam.ui;
   
  -import javax.faces.model.SelectItem;
  -import javax.faces.model.SelectItem;
   import javax.faces.component.UISelectItem;
   import javax.faces.context.FacesContext;
   import javax.faces.el.ValueBinding;
  +import javax.faces.model.SelectItem;
   
   public class EnumItem
       extends UISelectItem
  @@ -42,6 +41,7 @@
           return label;
       }
   
  +    @Override
       public Object getValue()
       {
           Class c = getParent().getValueBinding("value").getType(getFacesContext());
  
  
  
  1.3       +9 -9      jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SelectDate.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SelectDate.java	12 Dec 2006 22:38:26 -0000	1.2
  +++ SelectDate.java	14 Dec 2006 09:10:55 -0000	1.3
  @@ -1,12 +1,14 @@
   package org.jboss.seam.ui;
   
  -import java.io.*;
  -import java.util.*;
  -
  -import javax.faces.application.*;
  -import javax.faces.component.*;
  -import javax.faces.context.*;
  -import javax.faces.el.ValueBinding;
  +import java.io.IOException;
  +import java.io.InputStream;
  +import java.io.InputStreamReader;
  +import java.util.Map;
  +
  +import javax.faces.component.UIComponent;
  +import javax.faces.component.UIComponentBase;
  +import javax.faces.context.FacesContext;
  +import javax.faces.context.ResponseWriter;
   
   public class SelectDate 
       extends UIComponentBase
  @@ -92,8 +94,6 @@
               
           request.put("SELECTDATE_SCRIPT", scriptResource);
           
  -        ViewHandler handler = context.getApplication().getViewHandler();
  -
           ResponseWriter response = context.getResponseWriter();
           response.startElement("script", null);
           response.writeAttribute("type", "text/javascript", null);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 05:14:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 05:14:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r59034 -
	trunk/server/src/main/org/jboss/deployment
Message-ID: <E1GunbX-0006jS-MX@committer01.frg.pub.inap.atl.jboss.com>

Author: alex.loubyansky at jboss.com
Date: 2006-12-14 05:14:18 -0500 (Thu, 14 Dec 2006)
New Revision: 59034

Modified:
   trunk/server/src/main/org/jboss/deployment/ClientDeployer.java
Log:
quick fix to filter javaee namespace

Modified: trunk/server/src/main/org/jboss/deployment/ClientDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/ClientDeployer.java	2006-12-14 07:04:55 UTC (rev 59033)
+++ trunk/server/src/main/org/jboss/deployment/ClientDeployer.java	2006-12-14 10:14:18 UTC (rev 59034)
@@ -95,9 +95,10 @@
          try
          {
             Element root = DOMUtils.parse(dd.openStream());
+            accepts = true;
             String namespaceURI = root.getNamespaceURI();
-            // Accept the J2EE-1.4 namespace
-            accepts = "http://java.sun.com/xml/ns/j2ee".equals(namespaceURI);
+            // If this is javaee, it should be processed by another deployer
+            accepts = !"http://java.sun.com/xml/ns/javaee".equals(namespaceURI);
             if (accepts == false)
                log.debug("Ignore application-client.xml with namespace: " + namespaceURI);
          }



From gavin.king at jboss.com  Thu Dec 14 05:26:59 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:26:59 -0500
Subject: [jboss-cvs] jboss-seam/src/main/META-INF  ...
Message-ID: <E1Gunnn-0006x2-H9@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:26:59

  Modified:    src/main/META-INF  components.xml
  Log:
  introduce METHOD context, and solve   JBSEAM-564
  
  Revision  Changes    Path
  1.8       +1 -0      jboss-seam/src/main/META-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/META-INF/components.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- components.xml	2 Dec 2006 00:54:32 -0000	1.7
  +++ components.xml	14 Dec 2006 10:26:59 -0000	1.8
  @@ -22,6 +22,7 @@
     <factory scope="stateless" auto-create="true" name="locale" value="#{org.jboss.seam.core.locale}"/>
     <factory scope="stateless" auto-create="true" name="localeSelector" value="#{org.jboss.seam.core.localeSelector}"/>
     <factory scope="stateless" auto-create="true" name="messages" value="#{org.jboss.seam.core.messages}"/>
  +  <factory scope="stateless" auto-create="true" name="methodContext" value="#{org.jboss.seam.core.methodContext}"/>
     <factory scope="stateless" auto-create="true" name="jbpmContext" value="#{org.jboss.seam.core.jbpmContext}"/>
     <factory scope="stateless" auto-create="true" name="pageContext" value="#{org.jboss.seam.core.pageContext}"/>
     <factory scope="stateless" auto-create="true" name="pageflow" value="#{org.jboss.seam.core.pageflow}"/>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 05:27:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:27:00 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts   ...
Message-ID: <E1Gunno-0006xO-Ip@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:27:00

  Modified:    src/main/org/jboss/seam/contexts   Contexts.java
                        Lifecycle.java
  Log:
  introduce METHOD context, and solve   JBSEAM-564
  
  Revision  Changes    Path
  1.45      +54 -13    jboss-seam/src/main/org/jboss/seam/contexts/Contexts.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Contexts.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Contexts.java,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- Contexts.java	25 Nov 2006 02:56:06 -0000	1.44
  +++ Contexts.java	14 Dec 2006 10:27:00 -0000	1.45
  @@ -16,74 +16,105 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.44 $
  + * @version $Revision: 1.45 $
    */
   public class Contexts {
   
      private static final Log log = LogFactory.getLog( Contexts.class );
   
      static final ThreadLocal<Context> applicationContext = new ThreadLocal<Context>();
  +   static final ThreadLocal<Context> methodContext = new ThreadLocal<Context>();
      static final ThreadLocal<Context> eventContext = new ThreadLocal<Context>();
      static final ThreadLocal<Context> pageContext = new ThreadLocal<Context>();
      static final ThreadLocal<Context> sessionContext = new ThreadLocal<Context>();
      static final ThreadLocal<Context> conversationContext = new ThreadLocal<Context>();
      static final ThreadLocal<Context> businessProcessContext = new ThreadLocal<Context>();
   
  -	public static Context getEventContext() {
  +	public static Context getEventContext() 
  +   {
   		return eventContext.get();
   	}
   
  -   public static Context getPageContext() {
  +   public static Context getMethodContext() 
  +   {
  +      return methodContext.get();
  +   }
  +
  +   public static Context getPageContext() 
  +   {
         return pageContext.get();
      }
   
  -	public static Context getSessionContext() {
  +	public static Context getSessionContext() 
  +   {
   		return sessionContext.get();
   	}
   
  -	public static Context getApplicationContext() {
  +	public static Context getApplicationContext() 
  +   {
   		return applicationContext.get();
   	}
   
  -	public static Context getConversationContext() {
  +	public static Context getConversationContext() 
  +   {
   		return conversationContext.get();
   	}
   
  -    public static Context getBusinessProcessContext() {
  +    public static Context getBusinessProcessContext() 
  +    {
   	    return businessProcessContext.get();
       }
   
  -	public static boolean isConversationContextActive() {
  +	public static boolean isConversationContextActive() 
  +   {
   		return getConversationContext() != null;
   	}
   
  -	public static boolean isEventContextActive() {
  +	public static boolean isEventContextActive() 
  +   {
   		return eventContext.get() != null;
   	}
   
  -   public static boolean isPageContextActive() {
  +   public static boolean isMethodContextActive() 
  +   {
  +      return methodContext.get() != null;
  +   }
  +
  +   public static boolean isPageContextActive() 
  +   {
         return pageContext.get() != null;
      }
   
  -	public static boolean isSessionContextActive() {
  +	public static boolean isSessionContextActive() 
  +   {
   		return sessionContext.get() != null;
   	}
   
  -	public static boolean isApplicationContextActive() {
  +	public static boolean isApplicationContextActive() 
  +   {
   		return applicationContext.get() != null;
   	}
   
  -    public static boolean isBusinessProcessContextActive() {
  +    public static boolean isBusinessProcessContextActive() 
  +    {
           return businessProcessContext.get() != null;
       }
      
      public static void removeFromAllContexts(String name)
      {
         log.debug("removing from all contexts: " + name);
  +      if (isMethodContextActive())
  +      {
  +         getMethodContext().remove(name);
  +      }
         if (isEventContextActive())
         {
            getEventContext().remove(name);
         }
  +      if (isPageContextActive())
  +      {
  +         getPageContext().remove(name);
  +      }
         if (isConversationContextActive())
         {
            getConversationContext().remove(name);
  @@ -104,6 +135,16 @@
   
      public static Object lookupInStatefulContexts(String name)
      {
  +      if (isMethodContextActive())
  +      {
  +         Object result = getMethodContext().get(name);
  +         if (result!=null)
  +         {
  +            log.debug("found in method context: " + name);
  +            return result;
  +         }
  +      }
  +      
         if (isEventContextActive())
         {
            Object result = getEventContext().get(name);
  
  
  
  1.71      +12 -1     jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.70
  retrieving revision 1.71
  diff -u -b -r1.70 -r1.71
  --- Lifecycle.java	13 Dec 2006 04:54:19 -0000	1.70
  +++ Lifecycle.java	14 Dec 2006 10:27:00 -0000	1.71
  @@ -31,7 +31,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.70 $
  + * @version $Revision: 1.71 $
    */
   public class Lifecycle
   {
  @@ -94,6 +94,17 @@
         Contexts.applicationContext.set(null);
      }
   
  +   public static Context beginMethod()
  +   {
  +      Context result = Contexts.methodContext.get();
  +      Contexts.methodContext.set( new MapContext(ScopeType.METHOD) );
  +      return result;
  +   }
  +
  +   public static void endMethod(Context context)
  +   {
  +      Contexts.methodContext.set(context);
  +   }
   
      public static void beginInitialization(ServletContext servletContext)
      {
  
  
  


From gavin.king at jboss.com  Thu Dec 14 05:27:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:27:00 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam   ...
Message-ID: <E1Gunno-0006xC-0O@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:26:59

  Modified:    src/main/org/jboss/seam   Component.java ScopeType.java
  Log:
  introduce METHOD context, and solve   JBSEAM-564
  
  Revision  Changes    Path
  1.219     +6 -1      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.218
  retrieving revision 1.219
  diff -u -b -r1.218 -r1.219
  --- Component.java	13 Dec 2006 04:54:19 -0000	1.218
  +++ Component.java	14 Dec 2006 10:26:59 -0000	1.219
  @@ -100,6 +100,7 @@
   import org.jboss.seam.interceptors.EventInterceptor;
   import org.jboss.seam.interceptors.ExceptionInterceptor;
   import org.jboss.seam.interceptors.ManagedEntityIdentityInterceptor;
  +import org.jboss.seam.interceptors.MethodContextInterceptor;
   import org.jboss.seam.interceptors.OutcomeInterceptor;
   import org.jboss.seam.interceptors.RemoveInterceptor;
   import org.jboss.seam.interceptors.RollbackInterceptor;
  @@ -121,7 +122,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.218 $
  + * @version $Revision: 1.219 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -738,6 +739,10 @@
         {
            addInterceptor( new Interceptor( new RemoveInterceptor(), this ) );
         }
  +      if ( getType()!=ENTITY_BEAN )
  +      {
  +         addInterceptor( new Interceptor( new MethodContextInterceptor(), this ) );
  +      }
         if ( beanClassHasAnnotation(RaiseEvent.class) )
         {
            addInterceptor( new Interceptor( new EventInterceptor(), this ) );
  
  
  
  1.11      +17 -1     jboss-seam/src/main/org/jboss/seam/ScopeType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ScopeType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/ScopeType.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ScopeType.java	12 Oct 2006 00:09:45 -0000	1.10
  +++ ScopeType.java	14 Dec 2006 10:26:59 -0000	1.11
  @@ -13,7 +13,7 @@
    * The available scopes (contexts).
    * 
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public enum ScopeType 
   {
  @@ -22,6 +22,14 @@
       */
      STATELESS,
      /**
  +    * The method context. Each call to a session bean or 
  +    * JavaBean component puts a new method context onto
  +    * the stack of method contexts associated with the
  +    * current thread. The context is destroyed (and the
  +    * stack popped) when the method returns.
  +    */
  +   METHOD,
  +   /**
       * The event (request) context. Spans a server request,
       * from restore view to render response.
       */
  @@ -68,6 +76,8 @@
         {
            case STATELESS:
               return true;
  +         case METHOD:
  +            return Contexts.isMethodContextActive();
            case EVENT:
               return Contexts.isEventContextActive();
            case PAGE:
  @@ -93,6 +103,12 @@
         {
            case STATELESS: 
               throw new UnsupportedOperationException("Stateless psuedo-scope does not have a Context object");
  +         case METHOD: 
  +            if ( !Contexts.isMethodContextActive() )
  +            {
  +               throw new IllegalStateException("No method context active");
  +            }
  +            return Contexts.getMethodContext();
            case EVENT: 
               if ( !Contexts.isEventContextActive() )
               {
  
  
  


From gavin.king at jboss.com  Thu Dec 14 05:27:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:27:00 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gunno-0006xV-Nt@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:27:00

  Added:       src/main/org/jboss/seam/core  MethodContext.java
  Log:
  introduce METHOD context, and solve   JBSEAM-564
  
  Revision  Changes    Path
  1.1      date: 2006/12/14 10:27:00;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/MethodContext.java
  
  Index: MethodContext.java
  ===================================================================
  //$Id: MethodContext.java,v 1.1 2006/12/14 10:27:00 gavin Exp $
  package org.jboss.seam.core;
  
  import static org.jboss.seam.InterceptionType.NEVER;
  import static org.jboss.seam.annotations.Install.BUILT_IN;
  
  import org.jboss.seam.ScopeType;
  import org.jboss.seam.annotations.Install;
  import org.jboss.seam.annotations.Intercept;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Scope;
  import org.jboss.seam.annotations.Unwrap;
  import org.jboss.seam.contexts.Context;
  import org.jboss.seam.contexts.Contexts;
  
  /**
   * Support for injecting the page context
   * 
   * @author Gavin King
   */
  @Scope(ScopeType.APPLICATION)
  @Intercept(NEVER)
  @Name("org.jboss.seam.core.methodContext")
  @Install(precedence=BUILT_IN)
  public class MethodContext
  {
     @Unwrap
     public Context getContext()
     {
        return Contexts.isMethodContextActive() ? 
              Contexts.getMethodContext() : null;
     }
  }
  
  
  


From gavin.king at jboss.com  Thu Dec 14 05:27:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:27:00 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors   ...
Message-ID: <E1Gunno-0006xf-SV@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:27:00

  Modified:    src/main/org/jboss/seam/interceptors  
                        AsynchronousInterceptor.java
  Added:       src/main/org/jboss/seam/interceptors  
                        MethodContextInterceptor.java
  Log:
  introduce METHOD context, and solve   JBSEAM-564
  
  Revision  Changes    Path
  1.8       +1 -1      jboss-seam/src/main/org/jboss/seam/interceptors/AsynchronousInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsynchronousInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/AsynchronousInterceptor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- AsynchronousInterceptor.java	1 Nov 2006 02:54:02 -0000	1.7
  +++ AsynchronousInterceptor.java	14 Dec 2006 10:27:00 -0000	1.8
  @@ -26,7 +26,7 @@
            {
               throw new IllegalStateException("Dispatcher is not installed in components.xml");
            }
  -         Timer timer = dispatcher.scheduleInvocation(invocation, getComponent());
  +         Timer timer = dispatcher.scheduleInvocation( invocation, getComponent() );
            //if the method returns a Timer, return it to the client
            return invocation.getMethod().getReturnType().equals(Timer.class) ? timer : null;
         }
  
  
  
  1.1      date: 2006/12/14 10:27:00;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java
  
  Index: MethodContextInterceptor.java
  ===================================================================
  package org.jboss.seam.interceptors;
  
  import org.jboss.seam.annotations.AroundInvoke;
  import org.jboss.seam.annotations.Interceptor;
  import org.jboss.seam.contexts.Context;
  import org.jboss.seam.contexts.Contexts;
  import org.jboss.seam.contexts.Lifecycle;
  import org.jboss.seam.intercept.InvocationContext;
  
  /**
   * Unproxies the SFSB for the length of the call.
   * 
   * @author Gavin King
   *
   */
  @Interceptor(stateless=true, around={BijectionInterceptor.class, EventInterceptor.class, SecurityInterceptor.class})
  public class MethodContextInterceptor extends AbstractInterceptor
  {
     @AroundInvoke
     public Object aroundInvoke(InvocationContext ctx) throws Exception
     {
        String name = getComponent().getName();
        Context outerMethodContext = Lifecycle.beginMethod();
        try
        {
           Contexts.getMethodContext().set( name, ctx.getTarget() );
           return ctx.proceed();
        }
        finally
        {
           Lifecycle.endMethod(outerMethodContext);
        }
     }
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 05:33:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 05:33:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r59036 -
	branches/Branch_4_0/tomcat/src/main/org/jboss/web/tomcat/tc5/session
Message-ID: <E1GunuN-00076f-FT@committer01.frg.pub.inap.atl.jboss.com>

Author: jfrederic.clere at jboss.com
Date: 2006-12-14 05:33:45 -0500 (Thu, 14 Dec 2006)
New Revision: 59036

Modified:
   branches/Branch_4_0/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java
Log:
Make sure to use the received sessionid string.
See http://jira.jboss.com/jira/browse/JBAS-3829


Modified: branches/Branch_4_0/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java
===================================================================
--- branches/Branch_4_0/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java	2006-12-14 10:33:36 UTC (rev 59035)
+++ branches/Branch_4_0/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java	2006-12-14 10:33:45 UTC (rev 59036)
@@ -87,6 +87,7 @@
    public void checkJvmRoute(Request req, Response res)
       throws IOException, ServletException
    {
+      String oldsessionId = req.getRequestedSessionId();
       HttpSession session = req.getSession(false);
       if (session != null)
       {
@@ -108,25 +109,33 @@
 
          // Check if incoming session id has JvmRoute appended. If not, append it.
          boolean setCookie = !req.isRequestedSessionIdFromURL();
-         handleJvmRoute(sessionId, jvmRoute, res, setCookie);
+         handleJvmRoute(oldsessionId, sessionId, jvmRoute, res, setCookie);
       }
    }
 
-   protected void handleJvmRoute(String sessionId, 
+   protected void handleJvmRoute(String oldsessionId,
+                                 String sessionId, 
                                  String jvmRoute, 
                                  HttpServletResponse response,
                                  boolean setCookie)
    {
       // Get requested jvmRoute.
       // TODO. The current format is assumed to be id.jvmRoute. Can be generalized later.
+      String receivedJvmRoute = null;
+      int index = oldsessionId.lastIndexOf(".");
+      if (index > 0)
+      {
+         receivedJvmRoute = oldsessionId.substring(index + 1, sessionId.length());
+      }
+
       String requestedJvmRoute = null;
-      int index = sessionId.lastIndexOf(".");
+      index = sessionId.lastIndexOf(".");
       if (index > 0)
       {
          requestedJvmRoute = sessionId.substring(index + 1, sessionId.length());
       }
 
-      String newId = sessionId;
+      String newId = null;
       if (!jvmRoute.equals(requestedJvmRoute))
       {
          if (requestedJvmRoute == null)
@@ -151,9 +160,22 @@
          
          resetSessionId(sessionId, newId);
          
-         if (setCookie)
-            manager_.setNewSessionCookie(newId, response);
       }
+      /* Also check the jvmRoute received (via req.getRequestedSessionId()) */
+      if (!jvmRoute.equals(receivedJvmRoute))
+      {
+            if (log_.isDebugEnabled())
+            {
+               log_.debug("handleJvmRoute(): We have detected a failover with different jvmRoute." +
+                  " received one: " + receivedJvmRoute + " new one: " + jvmRoute + ". Will resent the session id.");
+            }
+            String base = sessionId.substring(0, index);
+            newId = base + "." + jvmRoute;
+      }
+
+      /* Change the sessionid cookie if needed */
+      if (setCookie && newId != null)
+         manager_.setNewSessionCookie(newId, response);
    }
    
    private void resetSessionId(String oldId, String newId)



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 05:33:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 05:33:37 -0500
Subject: [jboss-cvs] JBossAS SVN: r59035 -
	branches/Branch_4_2/tomcat/src/main/org/jboss/web/tomcat/tc5/session
Message-ID: <E1GunuD-000760-MY@committer01.frg.pub.inap.atl.jboss.com>

Author: jfrederic.clere at jboss.com
Date: 2006-12-14 05:33:36 -0500 (Thu, 14 Dec 2006)
New Revision: 59035

Modified:
   branches/Branch_4_2/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java
Log:
Make sure to use the received sessionid string.
See http://jira.jboss.com/jira/browse/JBAS-3829


Modified: branches/Branch_4_2/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java
===================================================================
--- branches/Branch_4_2/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java	2006-12-14 10:14:18 UTC (rev 59034)
+++ branches/Branch_4_2/tomcat/src/main/org/jboss/web/tomcat/tc5/session/JvmRouteValve.java	2006-12-14 10:33:36 UTC (rev 59035)
@@ -87,6 +87,7 @@
    public void checkJvmRoute(Request req, Response res)
       throws IOException, ServletException
    {
+      String oldsessionId = req.getRequestedSessionId();
       HttpSession session = req.getSession(false);
       if (session != null)
       {
@@ -108,25 +109,33 @@
 
          // Check if incoming session id has JvmRoute appended. If not, append it.
          boolean setCookie = !req.isRequestedSessionIdFromURL();
-         handleJvmRoute(sessionId, jvmRoute, res, setCookie);
+         handleJvmRoute(oldsessionId, sessionId, jvmRoute, res, setCookie);
       }
    }
 
-   protected void handleJvmRoute(String sessionId, 
+   protected void handleJvmRoute(String oldsessionId,
+                                 String sessionId, 
                                  String jvmRoute, 
                                  HttpServletResponse response,
                                  boolean setCookie)
    {
       // Get requested jvmRoute.
       // TODO. The current format is assumed to be id.jvmRoute. Can be generalized later.
+      String receivedJvmRoute = null;
+      int index = oldsessionId.lastIndexOf(".");
+      if (index > 0)
+      {
+         receivedJvmRoute = oldsessionId.substring(index + 1, sessionId.length());
+      }
+
       String requestedJvmRoute = null;
-      int index = sessionId.lastIndexOf(".");
+      index = sessionId.lastIndexOf(".");
       if (index > 0)
       {
          requestedJvmRoute = sessionId.substring(index + 1, sessionId.length());
       }
 
-      String newId = sessionId;
+      String newId = null;
       if (!jvmRoute.equals(requestedJvmRoute))
       {
          if (requestedJvmRoute == null)
@@ -151,9 +160,22 @@
          
          resetSessionId(sessionId, newId);
          
-         if (setCookie)
-            manager_.setNewSessionCookie(newId, response);
       }
+      /* Also check the jvmRoute received (via req.getRequestedSessionId()) */
+      if (!jvmRoute.equals(receivedJvmRoute))
+      {
+            if (log_.isDebugEnabled())
+            {
+               log_.debug("handleJvmRoute(): We have detected a failover with different jvmRoute." +
+                  " received one: " + receivedJvmRoute + " new one: " + jvmRoute + ". Will resent the session id.");
+            }
+            String base = sessionId.substring(0, index);
+            newId = base + "." + jvmRoute;
+      }
+
+      /* Change the sessionid cookie if needed */
+      if (setCookie && newId != null)
+         manager_.setNewSessionCookie(newId, response);
    }
    
    private void resetSessionId(String oldId, String newId)



From gavin.king at jboss.com  Thu Dec 14 05:40:09 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:40:09 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1Guo0X-0007Dz-JW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:40:09

  Modified:    examples/booking/src/org/jboss/seam/example/booking  
                        BookingList.java BookingListAction.java
  Log:
  use methodcontext
  
  Revision  Changes    Path
  1.4       +2 -1      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingList.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- BookingList.java	24 Apr 2006 03:50:04 -0000	1.3
  +++ BookingList.java	14 Dec 2006 10:40:09 -0000	1.4
  @@ -1,4 +1,4 @@
  -//$Id: BookingList.java,v 1.3 2006/04/24 03:50:04 gavin Exp $
  +//$Id: BookingList.java,v 1.4 2006/12/14 10:40:09 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -7,6 +7,7 @@
   public interface BookingList
   {
      public void getBookings();
  +   public Booking getBooking();
      public String cancel();
      public void destroy();
   }
  \ No newline at end of file
  
  
  
  1.17      +10 -7     jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingListAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingListAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingListAction.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- BookingListAction.java	12 Oct 2006 02:49:35 -0000	1.16
  +++ BookingListAction.java	14 Dec 2006 10:40:09 -0000	1.17
  @@ -1,4 +1,4 @@
  -//$Id: BookingListAction.java,v 1.16 2006/10/12 02:49:35 gavin Exp $
  +//$Id: BookingListAction.java,v 1.17 2006/12/14 10:40:09 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static javax.ejb.TransactionAttributeType.REQUIRES_NEW;
  @@ -13,13 +13,12 @@
   import javax.persistence.EntityManager;
   import javax.persistence.PersistenceContext;
   
  -import org.jboss.seam.annotations.Logger;
   import org.jboss.seam.annotations.Destroy;
   import org.jboss.seam.annotations.Factory;
   import org.jboss.seam.annotations.In;
  +import org.jboss.seam.annotations.Logger;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Observer;
  -import org.jboss.seam.annotations.Out;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.annotations.datamodel.DataModel;
   import org.jboss.seam.annotations.datamodel.DataModelSelection;
  @@ -43,7 +42,6 @@
      @DataModel
      private List<Booking> bookings;
      @DataModelSelection 
  -   @Out(required=false)
      private Booking booking;
      
      @Logger 
  @@ -60,14 +58,19 @@
      
      public String cancel()
      {
  -      log.info("Cancel booking: #0 for #{user.username}", booking.getId());
  +      log.info("Cancel booking: #{bookingList.booking.id} for #{user.username}");
         Booking cancelled = em.find(Booking.class, booking.getId());
         if (cancelled!=null) em.remove( cancelled );
         getBookings();
  -      FacesMessages.instance().add("Booking cancelled for confirmation number #{booking.id}");
  +      FacesMessages.instance().add("Booking cancelled for confirmation number #{bookingList.booking.id}");
         return "main";
      }
      
  +   public Booking getBooking()
  +   {
  +      return booking;
  +   }
  +   
      @Destroy @Remove
      public void destroy() {}
      
  
  
  


From gavin.king at jboss.com  Thu Dec 14 05:40:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 05:40:33 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/src  ...
Message-ID: <E1Guo0v-0007Ex-TW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 05:40:33

  Modified:    seam-gen/src  FormActionBean.java
  Log:
  use methodcontext
  
  Revision  Changes    Path
  1.3       +2 -2      jboss-seam/seam-gen/src/FormActionBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FormActionBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/src/FormActionBean.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- FormActionBean.java	20 Nov 2006 20:38:53 -0000	1.2
  +++ FormActionBean.java	14 Dec 2006 10:40:33 -0000	1.3
  @@ -25,8 +25,8 @@
   	public String @methodName@()
   	{
   		//implement your business logic here
  -		log.info("@componentName at .@methodName@() action called with: #0", value);
  -		facesMessages.add( "@methodName@ #0", (Object) value );
  +		log.info("@componentName at .@methodName@() action called with: #{@componentName at .value}");
  +		facesMessages.add("@methodName@ #{@componentName at .value}");
   		return "success";
   	}
   	
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 05:47:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 05:47:35 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1791 - in
	trunk/tests/src/org/jboss/test/messaging: jms/clustering
	tools tools/jmx/rmi tools/jndi
Message-ID: <E1Guo7j-0007OH-Pn@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 05:47:31 -0500 (Thu, 14 Dec 2006)
New Revision: 1791

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NamingDelegate.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMContext.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
Log:
Added support for spawning new remote servers (and resurrecting killed remote servers)


Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-14 08:58:42 UTC (rev 1790)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-14 10:47:31 UTC (rev 1791)
@@ -382,8 +382,52 @@
       }
    }
 
+   public void testSpawnServer() throws Exception
+   {
 
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
+      ClusterEventNotificationListener clusterEvent = new ClusterEventNotificationListener();
 
+      try
+      {
+         // Start with a 1 node cluster
+
+         ServerManagement.start("all", 0);
+
+         Set view = ServerManagement.getServer(0).getNodeIDView();
+
+         assertEquals(1, view.size());
+         assertTrue(view.contains(new Integer(0)));
+
+         ServerManagement.addNotificationListener(0, postOfficeObjectName, clusterEvent);
+
+         ServerManagement.spawn(10);
+         ServerManagement.start("all", 10);
+
+         if (!clusterEvent.viewChanged(120000))
+         {
+            fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+         }
+
+         view = ServerManagement.getServer(1).getNodeIDView();
+
+         assertEquals(2, view.size());
+         assertTrue(view.contains(new Integer(0)));
+         assertTrue(view.contains(new Integer(10)));
+
+         //ServerManagement.kill(10);
+
+      }
+      finally
+      {
+         ServerManagement.removeNotificationListener(0, postOfficeObjectName, clusterEvent);
+         ServerManagement.stop(0);
+      }
+   }
+
+
+
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-14 08:58:42 UTC (rev 1790)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-14 10:47:31 UTC (rev 1791)
@@ -236,8 +236,52 @@
    }
 
    /**
-    * Abruptly kills the VM running the specified server.
+    * For a local test, is a noop, but for a remote test, the method call spawns a new VM.
+    * The remote server so created is no different from a server started using start-rmi-server
+    * script.
     */
+   public static synchronized void spawn(int index) throws Exception
+   {
+      if (servers[index] != null)
+      {
+         throw new Exception("The server " + index + " has been created already!");
+      }
+
+      // in the remote case, make sure the VM with the given index isn't already up
+      if (isRemote() && acquireRemote(3, index) != null)
+      {
+         throw new Exception("The remote server " + index + " seems to be already up!");
+      }
+
+
+      StringBuffer sb = new StringBuffer();
+
+      sb.append("java").append(' ');
+
+      sb.append("-Xmx512M").append(' ');
+
+      sb.append("-Dmodule.output=./../output").append(' ');
+
+      sb.append("-Dremote.test.suffix=-remote-").append(index).append(' ');
+
+      sb.append("-Dtest.server.index=").append(index).append(' ');
+
+      sb.append("-Dtest.bind.address=localhost").append(' ');
+
+      sb.append("-cp").append(' ').append(System.getProperty("java.class.path")).append(' ');
+
+      sb.append("org.jboss.test.messaging.tools.jmx.rmi.RMITestServer");
+
+      //System.out.println(sb.toString());
+
+      Runtime.getRuntime().exec(sb.toString());
+
+      log.info("VM for Server " + index + " spawned");
+   }
+
+   /**
+    * Abruptly kills the VM running the specified server, simulating a crash.
+    */
    public static synchronized void kill(int index) throws Exception
    {
       if (servers[index] == null)
@@ -247,8 +291,10 @@
       }
 
       servers[index].kill();
+
+      log.info("Server " + index + " killed");
+
       servers[index] = null;
-      
       killed[index] = true;
    }
    
@@ -279,10 +325,17 @@
 
    public static Object getAttribute(ObjectName on, String attribute) throws Exception
    {
-      insureStarted();
-      return servers[0].getAttribute(on, attribute);
+      return getAttribute(0, on, attribute);
    }
 
+   public static Object getAttribute(int serverIndex, ObjectName on, String attribute)
+      throws Exception
+   {
+      insureStarted(serverIndex);
+      return servers[serverIndex].getAttribute(on, attribute);
+   }
+
+
    public static void setAttribute(ObjectName on, String name, String valueAsString)
       throws Exception
    {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NamingDelegate.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NamingDelegate.java	2006-12-14 08:58:42 UTC (rev 1790)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/NamingDelegate.java	2006-12-14 10:47:31 UTC (rev 1791)
@@ -34,4 +34,6 @@
 public interface NamingDelegate extends Remote
 {
    Object lookup(String name) throws Exception;
+
+   void bind(String name, Object obj) throws Exception;
 }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java	2006-12-14 08:58:42 UTC (rev 1790)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMINamingDelegate.java	2006-12-14 10:47:31 UTC (rev 1791)
@@ -61,6 +61,11 @@
       return getInitialContext().lookup(name);
    }
 
+   public void bind(String name, Object obj) throws Exception
+   {
+      getInitialContext().bind(name, obj);
+   }
+
    // Public --------------------------------------------------------
 
    public void reset()

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMContext.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMContext.java	2006-12-14 08:58:42 UTC (rev 1790)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/InVMContext.java	2006-12-14 10:47:31 UTC (rev 1791)
@@ -41,6 +41,7 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.ArrayList;
+import java.io.Serializable;
 
 
 /**
@@ -49,12 +50,14 @@
  *
  * $Id$
  */
-public class InVMContext implements Context
+public class InVMContext implements Context, Serializable
 {
    // Constants -----------------------------------------------------
 
+   private static final long serialVersionUID = 385743957345L;
+
    // Static --------------------------------------------------------
-   
+
    // Attributes ----------------------------------------------------
 
    protected Map map;
@@ -283,9 +286,9 @@
    // Public --------------------------------------------------------
 
    // Package protected ---------------------------------------------
-   
+
    // Protected -----------------------------------------------------
-   
+
    // Private -------------------------------------------------------
 
    private String trimSlashes(String s)

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-14 08:58:42 UTC (rev 1790)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-14 10:47:31 UTC (rev 1791)
@@ -88,7 +88,15 @@
 
    public void bind(String name, Object obj) throws NamingException
    {
-      throw new NotYetImplementedException();
+      try
+      {
+         namingDelegate.bind(name, obj);
+      }
+      catch(Exception e)
+      {
+         log.error("naming operation failed", e);
+         throw new NamingException(e.getMessage());
+      }
    }
 
    public void rebind(Name name, Object obj) throws NamingException



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 05:50:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 05:50:20 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1792 -
	trunk/tests/src/org/jboss/test/messaging/util
Message-ID: <E1GuoAO-0007QC-Mp@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 05:50:19 -0500 (Thu, 14 Dec 2006)
New Revision: 1792

Added:
   trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
Log:
added an usage example for spawning new remote test servers

Added: trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-14 10:47:31 UTC (rev 1791)
+++ trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-14 10:50:19 UTC (rev 1792)
@@ -0,0 +1,127 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.util;
+
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+import javax.naming.InitialContext;
+import javax.naming.Context;
+import javax.management.ObjectName;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class ServerManagementTest extends MessagingTestCase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public ServerManagementTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testFailureToSpawnStartedServer() throws Exception
+   {
+      try
+      {
+         ServerManagement.start("all", 0);
+
+         try
+         {
+            ServerManagement.spawn(0);
+            fail("It should have failed!");
+         }
+         catch(Exception e)
+         {
+            // OK
+         }
+      }
+      finally
+      {
+         ServerManagement.stop(0);
+      }
+   }
+
+   public void testFailureToSpawnExistingRemoteServer() throws Exception
+   {
+      if (ServerManagement.isLocal())
+      {
+         // irrelevant for a colocated configuration
+         return;
+      }
+
+      // this assumes that the remote server 0 has been started externally by and or by a script
+
+      try
+      {
+         ServerManagement.spawn(0);
+         fail("This should have failed!");
+      }
+      catch(Exception e)
+      {
+         // OK
+      }
+   }
+
+   public void testSimpleSpawn() throws Exception
+   {
+      try
+      {
+         ServerManagement.spawn(7);
+
+         ServerManagement.start("all", 7);
+
+         Integer index = (Integer)ServerManagement.
+            getAttribute(7, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
+
+         assertEquals(7, index.intValue());
+
+         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(7));
+
+         ic.bind("/xxx", "yyy");
+
+         assertEquals("yyy", ic.lookup("/xxx"));
+      }
+      finally
+      {
+         ServerManagement.kill(7);
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}



From mandersen at jboss.com  Thu Dec 14 06:52:52 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Thu, 14 Dec 2006 06:52:52 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences
	...
Message-ID: <E1Gup8u-0000Jl-G3@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/14 06:52:52

  Modified:    hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences   
                        AbstractConsoleConfigurationPreferences.java
                        ConsoleConfigurationPreferences.java
                        StandAloneConsoleConfigurationPreferences.java
  Log:
  HBX-839: Support persistence unit name in eclipse 
  HBX-840: Support namingstrategy in eclipse 
  
  Revision  Changes    Path
  1.8       +13 -4     jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/AbstractConsoleConfigurationPreferences.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractConsoleConfigurationPreferences.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/AbstractConsoleConfigurationPreferences.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- AbstractConsoleConfigurationPreferences.java	27 Nov 2006 15:30:18 -0000	1.7
  +++ AbstractConsoleConfigurationPreferences.java	14 Dec 2006 11:52:52 -0000	1.8
  @@ -27,15 +27,12 @@
   import java.util.Properties;
   
   import org.hibernate.console.HibernateConsoleRuntimeException;
  -import org.hibernate.console.preferences.ConsoleConfigurationPreferences.ConfigurationMode;
   import org.hibernate.util.StringHelper;
   import org.w3c.dom.Document;
   import org.w3c.dom.Element;
   import org.w3c.dom.Node;
   import org.w3c.dom.NodeList;
   
  -import sun.security.action.GetPropertyAction;
  -
   /**
    * @author max
    *
  @@ -53,9 +50,13 @@
   	protected String entityResolverName = null;
   	private boolean useProjectClasspath;
   	private ConfigurationMode configurationMode;
  +	private String persistenceUnitName;
  +	private String namingStrategy;
   	
  -	public AbstractConsoleConfigurationPreferences(String name, ConfigurationMode configurationMode, String projectName, boolean useProjectclassPath, String entityResolver) {
  +	public AbstractConsoleConfigurationPreferences(String name, ConfigurationMode configurationMode, String projectName, boolean useProjectclassPath, String entityResolver, String persistenceUnitName, String namingStrategy) {
   		setName(name);
  +		this.persistenceUnitName = persistenceUnitName;
  +		this.namingStrategy = namingStrategy;
   		this.configurationMode = configurationMode;
   		entityResolverName = entityResolver;
   		this.projectName = projectName;
  @@ -70,6 +71,14 @@
   		return configurationMode;
   	}
   	
  +	public String getPersistenceUnitName() {
  +		return persistenceUnitName;
  +	}
  +	
  +	public String getNamingStrategy() {
  +		return namingStrategy;
  +	}
  +	
   	public void setName(String name) {
   		if(name==null || name.trim().length()==0) {
   			throw new IllegalArgumentException("Name cannot be null or empty");
  
  
  
  1.6       +4 -0      jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/ConsoleConfigurationPreferences.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfigurationPreferences.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/ConsoleConfigurationPreferences.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ConsoleConfigurationPreferences.java	15 Nov 2006 16:12:06 -0000	1.5
  +++ ConsoleConfigurationPreferences.java	14 Dec 2006 11:52:52 -0000	1.6
  @@ -116,4 +116,8 @@
   	public abstract void setName(String name);
   
   	public abstract String getEntityResolverName();
  +
  +	public abstract String getPersistenceUnitName();
  +	
  +	public abstract String getNamingStrategy();
   }
  \ No newline at end of file
  
  
  
  1.7       +1 -1      jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/StandAloneConsoleConfigurationPreferences.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StandAloneConsoleConfigurationPreferences.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/StandAloneConsoleConfigurationPreferences.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- StandAloneConsoleConfigurationPreferences.java	15 Nov 2006 16:12:06 -0000	1.6
  +++ StandAloneConsoleConfigurationPreferences.java	14 Dec 2006 11:52:52 -0000	1.7
  @@ -45,7 +45,7 @@
   	private File[] customClasspath;	
   
   	public StandAloneConsoleConfigurationPreferences(String name, File xmlconfig, File propertiesFile, File[] mappingFiles, File[] customClasspath) {
  -		super(name, ConfigurationMode.CORE, null, false, null);
  +		super(name, ConfigurationMode.CORE, null, false, null, null, null);
   		this.cfgFile = xmlconfig;
   		this.propertyFilename = propertiesFile;
   		this.mappings = mappingFiles;
  
  
  


From mandersen at jboss.com  Thu Dec 14 06:52:54 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Thu, 14 Dec 2006 06:52:54 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards
	...
Message-ID: <E1Gup8w-0000KA-NE@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/14 06:52:54

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards  
                        ConsoleConfigurationWizardPage.java
                        ConsoleConfigurationCreationWizard.java
  Log:
  HBX-839: Support persistence unit name in eclipse 
  HBX-840: Support namingstrategy in eclipse 
  
  Revision  Changes    Path
  1.27      +56 -24    jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationWizardPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfigurationWizardPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationWizardPage.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- ConsoleConfigurationWizardPage.java	10 Dec 2006 01:59:03 -0000	1.26
  +++ ConsoleConfigurationWizardPage.java	14 Dec 2006 11:52:54 -0000	1.27
  @@ -72,6 +72,7 @@
   import org.eclipse.swt.widgets.Table;
   import org.eclipse.swt.widgets.TableItem;
   import org.eclipse.swt.widgets.Text;
  +import org.hibernate.cfg.NamingStrategy;
   import org.hibernate.console.KnownConfigurations;
   import org.hibernate.console.preferences.ConsoleConfigurationPreferences.ConfigurationMode;
   import org.hibernate.eclipse.console.EclipseConsoleConfiguration;
  @@ -82,6 +83,7 @@
   import org.hibernate.util.StringHelper;
   import org.xml.sax.EntityResolver;
   
  +
   /**
    * @author max
    *
  @@ -93,6 +95,9 @@
   	private Text configurationFileText;
   	private Text configurationNameText;
   	private Text projectNameText;
  +	private Text persistenceUnitNameText;
  +	
  +	
   	private EclipseConsoleConfiguration oldConfiguaration = null;
   	//private Button enableAnnotations;
   	Button coreMode;
  @@ -100,6 +105,7 @@
   	Button annotationsMode;
   	
   	private Text entityResolverClassNameText;
  +	private Text namingStrategyClassNameText;
   	
   	private ISelection selection;
   	private UpDownListComposite mappingFilesViewer;
  @@ -108,6 +114,7 @@
   	private Button confbutton;
   	private Button entbutton;
   	private Button useProjectClassPath;
  +	private Button nambutton;
   	
   	/**
   	 * Constructor for SampleNewWizardPage.
  @@ -235,6 +242,32 @@
   		});
   		
   		label = new Label(container, SWT.NULL);
  +		label.setText("&Persistence unit:");
  +		
  +		persistenceUnitNameText = new Text(container, SWT.BORDER | SWT.SINGLE);
  +		gd = new GridData(GridData.FILL_HORIZONTAL);
  +		gd.horizontalSpan = 2;
  +		persistenceUnitNameText.setLayoutData(gd);
  +		persistenceUnitNameText.addModifyListener(modifyListener);
  +		
  +		label = new Label(container, SWT.NULL);
  +		label.setText("&Naming strategy:");
  +		
  +		namingStrategyClassNameText = new Text(container, SWT.BORDER | SWT.SINGLE);
  +		gd = new GridData(GridData.FILL_HORIZONTAL);
  +		gd.horizontalSpan = 1;
  +		namingStrategyClassNameText.setLayoutData(gd);		
  +		namingStrategyClassNameText.addModifyListener(modifyListener);
  +		
  +		nambutton = new Button(container, SWT.PUSH);
  +		nambutton.setText("Browse...");
  +		nambutton.addSelectionListener(new SelectionAdapter() {
  +			public void widgetSelected(SelectionEvent e) {
  +				handleNamingStrategyBrowse();
  +			}
  +		});
  +	
  +		label = new Label(container, SWT.NULL);
   		label.setText("&Entity resolver:");
   		
   		entityResolverClassNameText = new Text(container, SWT.BORDER | SWT.SINGLE);
  @@ -251,23 +284,11 @@
   			}
   		});
   						
  -		//configurationMode.
  -		/*enableAnnotations = new Button(container, SWT.CHECK);
  -		enableAnnotations.setText("Enable hibernate ejb3/annotations (requires running eclipse with a Java 5 runtime)");
  -		enableAnnotations.addSelectionListener(new SelectionListener() {
  -		
  -			public void widgetDefaultSelected(SelectionEvent e) {
  -				dialogChanged();
  -			}
  -		
  -			public void widgetSelected(SelectionEvent e) {
  -				dialogChanged();		
  -			}
  -		});*/
   		
   		return container;
   	}
   
  +	
   	private void createConfigurationMode(Composite container) {
   		SelectionListener sl = new SelectionAdapter() {
   			public void widgetSelected(SelectionEvent e) {
  @@ -300,14 +321,11 @@
   		}
   	}
   
  -	
  -	private GridData createGridData() {
  -		GridData gd;
  -		gd = new GridData(GridData.FILL_HORIZONTAL);
  -		
  -		gd.horizontalSpan = 3;
  -		gd.verticalSpan = 1;
  -		return gd;
  +	protected void handleNamingStrategyBrowse() {
  +		String string = DialogSelectionHelper.chooseImplementation(NamingStrategy.class.getName(), namingStrategyClassNameText.getText(), "Select naming strategy class", getShell());
  +		if(string!=null) {
  +			namingStrategyClassNameText.setText(string);
  +		}		
   	}
   	
   	
  @@ -523,6 +541,8 @@
   				if(prefs.getMappings()!=null) mappingFilesViewer.add(prefs.getMappings(),false);
   				if(prefs.getCustomClasspath()!=null) classPathViewer.add(prefs.getCustomClasspath(),false);
   				if(prefs.getEntityResolverName()!=null) entityResolverClassNameText.setText(prefs.getEntityResolverName());
  +				if(prefs.getNamingStrategy() !=null) namingStrategyClassNameText.setText(prefs.getNamingStrategy());
  +				if(prefs.getPersistenceUnitName()!=null) persistenceUnitNameText.setText( prefs.getPersistenceUnitName() );
   				jpaMode.setSelection( prefs.getConfigurationMode().equals( ConfigurationMode.JPA ) );
   				coreMode.setSelection( prefs.getConfigurationMode().equals( ConfigurationMode.CORE ) );
   				annotationsMode.setSelection( prefs.getConfigurationMode().equals( ConfigurationMode.ANNOTATIONS ) );
  @@ -643,6 +663,8 @@
   		configurationFileText.setEnabled( !configurationFileWillBeCreated && !getConfigurationMode().equals( ConfigurationMode.JPA ) );
   		confbutton.setEnabled( !getConfigurationMode().equals( ConfigurationMode.JPA ) );
   		
  +		persistenceUnitNameText.setEnabled( getConfigurationMode().equals( ConfigurationMode.JPA) );
  +		
   		if(getConfigurationName()==null || getConfigurationName().trim().length() == 0) {
   			updateStatus("A name must be specified");
   			return;
  @@ -776,6 +798,16 @@
   		}
   	}
   
  +	public String getNamingStrategy() {
  +		return namingStrategyClassNameText.getText();
  +	}
  +
  +	public String getPersistenceUnitName() {
  +		return persistenceUnitNameText.getText();
  +	}
  +	
  +	
  +
   }
   
   
  
  
  
  1.13      +8 -3      jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationCreationWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfigurationCreationWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationCreationWizard.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- ConsoleConfigurationCreationWizard.java	17 Nov 2006 19:57:32 -0000	1.12
  +++ ConsoleConfigurationCreationWizard.java	14 Dec 2006 11:52:54 -0000	1.13
  @@ -96,10 +96,12 @@
   		final IPath[] classpaths = confPage.getClassPath();
   		final boolean useProjectClasspath = confPage.useProjectClassPath();
   		final String projectName = confPage.getProjectName();
  +		final String namingStrategy = confPage.getNamingStrategy();
  +		final String persistenceUnitName = confPage.getPersistenceUnitName();
   		IRunnableWithProgress op = new IRunnableWithProgress() {
   			public void run(IProgressMonitor monitor) throws InvocationTargetException {
   				try {
  -					createConsoleConfiguration(confPage.getOldConfiguration(), configName, annotations, projectName, useProjectClasspath, entityResolver, propertyFile, fileName, mappings, classpaths, monitor);
  +					createConsoleConfiguration(confPage.getOldConfiguration(), configName, annotations, projectName, useProjectClasspath, entityResolver, propertyFile, fileName, mappings, classpaths, persistenceUnitName, namingStrategy, monitor);
   				} catch (CoreException e) {
   					throw new InvocationTargetException(e);
   				} finally {
  @@ -131,12 +133,15 @@
   			EclipseConsoleConfiguration oldConfig,
   			String configName,
   			ConfigurationMode cmode, String projectName, boolean useProjectClasspath, String entityResolver, IPath propertyFilename,
  -			IPath cfgFile, IPath[] mappings, IPath[] classpaths, IProgressMonitor monitor)
  +			IPath cfgFile, IPath[] mappings, IPath[] classpaths, String persistenceUnitName, String namingStrategy, IProgressMonitor monitor)
   		throws CoreException {
   
   		monitor.beginTask("Configuring Hibernate Console" + propertyFilename, IProgressMonitor.UNKNOWN);
   								
  -		ConsoleConfigurationPreferences ccp = new EclipseConsoleConfigurationPreferences(configName, cmode, projectName, useProjectClasspath, entityResolver, cfgFile, propertyFilename, mappings, classpaths);
  +		ConsoleConfigurationPreferences ccp = new EclipseConsoleConfigurationPreferences(
  +				configName, cmode, projectName, useProjectClasspath,
  +				entityResolver, cfgFile, propertyFilename, mappings, classpaths,
  +				persistenceUnitName, namingStrategy);
   		
   		
   		final ConsoleConfiguration cfg = new EclipseConsoleConfiguration(ccp);
  
  
  


From mandersen at jboss.com  Thu Dec 14 06:52:54 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Thu, 14 Dec 2006 06:52:54 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console
	...
Message-ID: <E1Gup8w-0000KH-QG@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/14 06:52:54

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console 
                        EclipseConsoleConfigurationPreferences.java
  Log:
  HBX-839: Support persistence unit name in eclipse 
  HBX-840: Support namingstrategy in eclipse 
  
  Revision  Changes    Path
  1.11      +3 -2      jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/EclipseConsoleConfigurationPreferences.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EclipseConsoleConfigurationPreferences.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/EclipseConsoleConfigurationPreferences.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- EclipseConsoleConfigurationPreferences.java	10 Dec 2006 01:59:03 -0000	1.10
  +++ EclipseConsoleConfigurationPreferences.java	14 Dec 2006 11:52:54 -0000	1.11
  @@ -58,8 +58,8 @@
   	private IPath[] customClasspath;
   	
   
  -	public EclipseConsoleConfigurationPreferences(String configName, ConfigurationMode cmode, String projectName, boolean useProjectClasspath, String entityResolver, IPath cfgFile, IPath propertyFilename, IPath[] mappings, IPath[] classpaths) {
  -		super(configName, cmode, projectName, useProjectClasspath, entityResolver);		
  +	public EclipseConsoleConfigurationPreferences(String configName, ConfigurationMode cmode, String projectName, boolean useProjectClasspath, String entityResolver, IPath cfgFile, IPath propertyFilename, IPath[] mappings, IPath[] classpaths, String persistenceUnitName, String namingStrategy) {
  +		super(configName, cmode, projectName, useProjectClasspath, entityResolver, persistenceUnitName, namingStrategy);		
   		this.cfgFile = cfgFile;
   		this.propertyFilename = propertyFilename;
   		this.mappings = mappings;
  @@ -225,4 +225,5 @@
   	
   	
   
  +
   }
  
  
  


From mandersen at jboss.com  Thu Dec 14 06:52:52 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Thu, 14 Dec 2006 06:52:52 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console
	...
Message-ID: <E1Gup8u-0000Js-Ja@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/14 06:52:52

  Modified:    hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console 
                        ConsoleConfiguration.java
  Log:
  HBX-839: Support persistence unit name in eclipse 
  HBX-840: Support namingstrategy in eclipse 
  
  Revision  Changes    Path
  1.15      +17 -1     jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/ConsoleConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/ConsoleConfiguration.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- ConsoleConfiguration.java	11 Dec 2006 22:21:59 -0000	1.14
  +++ ConsoleConfiguration.java	14 Dec 2006 11:52:52 -0000	1.15
  @@ -48,6 +48,7 @@
   import org.hibernate.SessionFactory;
   import org.hibernate.cfg.Configuration;
   import org.hibernate.cfg.Environment;
  +import org.hibernate.cfg.NamingStrategy;
   import org.hibernate.cfg.Settings;
   import org.hibernate.console.execution.DefaultExecutionContext;
   import org.hibernate.console.execution.ExecutionContext;
  @@ -108,11 +109,17 @@
   	}
   
   	private Configuration buildJPAConfiguration(String persistenceUnit, Properties properties, String entityResolver) {
  +		if(StringHelper.isEmpty( persistenceUnit )) {
  +			persistenceUnit = null;
  +		}
   		try {
   			Map overrides = new HashMap();
   			if(properties!=null) {
   				overrides.putAll( properties );
   			}
  +			if(StringHelper.isNotEmpty( prefs.getNamingStrategy())) {
  +				overrides.put( "hibernate.ejb.naming_strategy", prefs.getNamingStrategy() );
  +			}
   			
   			Class clazz = ReflectHelper.classForName("org.hibernate.ejb.Ejb3Configuration", JPAConfigurationTask.class);
   			Object ejb3cfg = clazz.newInstance();
  @@ -447,7 +454,7 @@
   			}
   		} else if(prefs.getConfigurationMode().equals( ConfigurationMode.JPA )) {
   			try {
  -				localCfg = buildJPAConfiguration( null, properties, prefs.getEntityResolverName() );
  +				localCfg = buildJPAConfiguration( getPreferences().getPersistenceUnitName(), properties, prefs.getEntityResolverName() );
   			}
   			catch (Exception e) {
   				throw new HibernateConsoleRuntimeException("Could not load JPA Configuration",e);
  @@ -473,6 +480,15 @@
   		}
   		localCfg.setEntityResolver(entityResolver);
   
  +		if(StringHelper.isNotEmpty( prefs.getNamingStrategy())) {			
  +			try {
  +				NamingStrategy ns = (NamingStrategy) ReflectHelper.classForName(prefs.getNamingStrategy()).newInstance();
  +				localCfg.setNamingStrategy( ns );
  +			} catch (Exception c) {
  +				throw new HibernateConsoleRuntimeException("Could not configure naming strategy " + prefs.getNamingStrategy(), c);
  +			}
  +		}
  +		
   		localCfg = loadConfigurationXML( localCfg, includeMappings, entityResolver );
   		
   		return localCfg;
  
  
  


From msurtani at jboss.com  Thu Dec 14 06:55:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 06:55:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1GupB4-0000LN-II@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 06:55:06

  Modified:    src/org/jboss/cache/marshall  Tag: Branch_JBossCache_1_4_0
                        JBCMethodCall.java
  Log:
  JBCACHE-906
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.1   +58 -35    JBossCache/src/org/jboss/cache/marshall/Attic/JBCMethodCall.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBCMethodCall.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/Attic/JBCMethodCall.java,v
  retrieving revision 1.4
  retrieving revision 1.4.2.1
  diff -u -b -r1.4 -r1.4.2.1
  --- JBCMethodCall.java	8 Jun 2006 22:00:35 -0000	1.4
  +++ JBCMethodCall.java	14 Dec 2006 11:55:06 -0000	1.4.2.1
  @@ -56,4 +56,27 @@
       {
           return super.hashCode() * 10 + methodId;
       }
  +
  +   public String toString()
  +   {
  +      StringBuffer ret = new StringBuffer();
  +      boolean first = true;
  +      ret.append(method_name);
  +      ret.append("; id:");
  +      ret.append(methodId);
  +      ret.append('(');
  +      if (args != null)
  +      {
  +         for (int i = 0; i < args.length; i++)
  +         {
  +            if (first)
  +               first = false;
  +            else
  +               ret.append(", ");
  +            ret.append(args[i]);
  +         }
  +      }
  +      ret.append(')');
  +      return ret.toString();
  +   }
   }
  
  
  


From t2-okada at nri.co.jp  Thu Dec 14 06:58:48 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 14 Dec 2006 06:58:48 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/lzx  ...
Message-ID: <E1GupEe-0000QI-EL@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/14 06:58:48

  Modified:    java/webapp/lzx  Tag: JBossProfiler_Expansion
                        stacktracediagram.lzx
  Log:
  Added some functions.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +65 -27    jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: stacktracediagram.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- stacktracediagram.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  +++ stacktracediagram.lzx	14 Dec 2006 11:58:48 -0000	1.1.2.4
  @@ -34,9 +34,19 @@
     <include href="floatingmessage.lzx"/>
     
     <class name="popupmessage" extends="basecomponent" bgcolor="0xffffff">
  -    <text name="_contents" fontsize="9" resize="true"/>
  +    <simplelayout axis="y"/>
       <method name="setMessage" args="message">
  -      this._contents.setText(message);
  +      <![CDATA[
  +      if(message instanceof Array) {
  +        for(var i=0; i<message.length; i++) {
  +          var text = new LzText(this, {fontsize:9, resize:true});
  +          text.setText(message[i]);
  +          this.subviews.push(text);
  +        }
  +      }else {
  +        this.subnodes.push(message);
  +      }
  +      ]]>
       </method>
     </class>
     
  @@ -73,25 +83,15 @@
           <method name="strokeLifeline">
             dottedLine(parent._centerPoint, 0, parent._centerPoint, parent.height);
           </method>
  -        <method name="strokeActivation" args="begin, elapsed, elapsedTime">
  +        <method name="strokeActivation" args="begin, elapsed, message">
             var width = parent.parent.activationwidth;
             offsetLine(parent._centerPoint-width/2, begin, width, elapsed, true);
             
             // creates a view to handle mouse events
             var activation = new LzView(this, {x:parent._centerPoint-width/2, y:begin, width:width, height:elapsed, clickable:true});
  -          activation.setAttribute("value", elapsedTime);
  -          new LzDelegate(this, "focusin", activation, "onmouseover");
  -          new LzDelegate(this, "focusout", activation, "onmouseout");
  -        </method>
  -        <method name="focusin" args="activation">
  -          var attr = {name:"message",
  -                      x:classroot.parent.parent.getMouse("x")+4,
  -                      y:classroot.parent.parent.getMouse("y")-16};
  -          var m = new popupmessage(classroot.parent.parent, attr);
  -          m.setMessage("Elapsed Time : "+activation.value);
  -        </method>
  -        <method name="focusout" args="activation">
  -          classroot.parent.parent.searchSubnodes("name", "message").destroy(true);
  +          activation.setAttribute("message", message);
  +          new LzDelegate(classroot.parent.parent, "openMessage", activation, "onmouseover");
  +          new LzDelegate(classroot.parent.parent, "closeMessage", activation, "onmouseout");
           </method>
         </linedrawview>
       </view>
  @@ -106,12 +106,12 @@
         this.objectbox.setWidth(this.objectbox.contents.objectname.width + 16);
         this.activationarea.drawview.strokeLifeline();
       </handler>
  -    <method name="setActivation" args="begin, elapsed, elapsedTime">
  -      this.activationarea.drawview.strokeActivation(begin, elapsed, elapsedTime);
  +    <method name="setActivation" args="begin, elapsed, message">
  +      this.activationarea.drawview.strokeActivation(begin, elapsed, message);
       </method>
     </class>
     
  -  <class name="notifytext" extends="text" clickable="true">
  +  <class name="notifytext" extends="text" clickable="true" resize="true">
       <attribute name="target"/>
       <attribute name="targetevent" type="string"/>
       <attribute name="sourceevent" type="string"/>
  @@ -175,7 +175,7 @@
           text.fullname = name;
           ]]>
         </method>
  -      <method name="strokeSelfMessage" args="beginx, beginy, height, id, name, offset">
  +      <method name="strokeSelfMessage" args="beginx, beginy, height, id, name, offset, message">
           <![CDATA[
           //var endy = beginy;
           //if(height>=parent.selfmessageheight) endy = beginy + parent.selfmessageheight;
  @@ -193,6 +193,12 @@
           text.setText(name.substr(name.lastIndexOf('.')+1));
           text.threadid = id;
           text.fullname = name;
  +        
  +        // creates a view to handle mouse events
  +        var activation = new LzView(this, {x:beginx, y:endy, width:offset, height:activationHeight, clickable:true});
  +        activation.setAttribute("message", message);
  +        new LzDelegate(classroot, "openMessage", activation, "onmouseover");
  +        new LzDelegate(classroot, "closeMessage", activation, "onmouseout");
           ]]>
         </method>
       </linedrawview>
  @@ -214,13 +220,16 @@
           var elapsedTime = childNode.getAttr(valueattr);
           if(ignorezerovalue && elapsedTime==0) continue;
           var name = childNode.getAttr(nameattr);
  +        
           var className = null;
  +        var methodName = null;
           if(name.charAt(0)=='/') {
             className = name;
  +          methodName = name.substr(name.lastIndexOf('/')+1);
           }else {
             className = name.substr(0, name.lastIndexOf('.'));
  +          methodName = name.substr(name.lastIndexOf('.')+1);
           }
  -        var methodName =name.substr(name.lastIndexOf('.')+1);
           
           var updateLane = selectLane(className);
           if(updateLane==null) {
  @@ -229,20 +238,40 @@
           
           var beginPixel = ((timestamp-beginTimestamp)/1000) * this.baseheight + baseheightoffset; // msec
           var elapsedPixel = (elapsedTime/1000000000) * this.baseheight; // nsec
  +        
  +        var callerClassName = null;
  +        var callerMethodName = null;
           var caller = childNode.getAttr(callerattr);
  -        var callerIndex = caller.lastIndexOf('.');
  -        if(callerIndex>=0) caller = caller.substring(0, caller.lastIndexOf('.'));
  -        if(caller==updateLane.objectname) {
  +        if(caller!="null") {
  +          var callerMethodIndex = caller.lastIndexOf('.');
  +          if(callerMethodIndex>=0) {
  +            callerClassName = caller.substring(0, callerMethodIndex);
  +            callerMethodName = caller.substr(callerMethodIndex+1);
  +          }else {
  +            callerClassName = caller;
  +          }
  +        }
  +        
  +        var message = new Array();
  +        message.push("ID : "+id);
  +        message.push("Class Name : "+className);
  +        message.push("Method Name : "+methodName);
  +        message.push("Caller Class Name : "+callerClassName);
  +        message.push("Caller Method Name : "+callerMethodName);
  +        message.push("Elapsed Time : "+elapsedTime);
  +        
  +        if(callerClassName==updateLane.objectname) {
             this.drawview.strokeSelfMessage(updateLane.jointpointright,
                                             beginPixel + updateLane.activationarea.y,
                                             elapsedPixel,
                                             id,
                                             name,
  -                                          updateLane.activationwidth);
  +                                          updateLane.activationwidth,
  +                                          message);
           }else {
  -          updateLane.setActivation(beginPixel, elapsedPixel, elapsedTime);
  +          updateLane.setActivation(beginPixel, elapsedPixel, message);
             if(i!=0) {
  -            messages.push({lane:updateLane, caller:caller, begin:beginPixel, elapsed:elapsedPixel, id:id, method:name});
  +            messages.push({lane:updateLane, caller:callerClassName, begin:beginPixel, elapsed:elapsedPixel, id:id, method:name});
             }
           }
         }
  @@ -278,6 +307,15 @@
         ]]>
       </method>
       
  +    <method name="openMessage" args="activation">
  +      var pm = new popupmessage(this, {name:"popupmessage", x:this.getMouse("x")+4, y:this.getMouse("y")-88});
  +      pm.setMessage(activation.message);
  +    </method>
  +    
  +    <method name="closeMessage" args="activation">
  +      this.searchSubnodes("name", "popupmessage").destroy(true);
  +    </method>
  +    
     </class>
     
     <resource name="objectbox_l" src="./images/objectbox_l.png"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 06:59:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 06:59:04 -0500
Subject: [jboss-cvs] JBossAS SVN: r59037 - in projects/microcontainer/trunk:
	kernel/src/main/org/jboss/kernel/plugins/deployment/xml
	kernel/src/resources/schema
	spring-int/src/resources/org/jboss/test/spring/test
	spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GupEu-0000QS-Qw@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 06:58:53 -0500 (Thu, 14 Dec 2006)
New Revision: 59037

Added:
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml
Removed:
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java
   projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
Log:
spring renaming, beans xsd order matching java code order

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java	2006-12-14 10:33:45 UTC (rev 59036)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/BeanSchemaBindingHelper.java	2006-12-14 11:58:53 UTC (rev 59037)
@@ -411,6 +411,12 @@
     */
    public static void configureValueBindings(TypeBinding typeBinding)
    {
+/*
+      TODO - test with inner bean!!
+      // type has bean
+      typeBinding.pushInterceptor(BeanSchemaBinding20.beanQName, ValueMetaDataElementInterceptor.VALUES);
+*/
+
       // type has values
       typeBinding.pushInterceptor(BeanSchemaBinding20.valueQName, ValueMetaDataElementInterceptor.VALUES);
 

Modified: projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd	2006-12-14 10:33:45 UTC (rev 59036)
+++ projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd	2006-12-14 11:58:53 UTC (rev 59037)
@@ -507,12 +507,12 @@
       <xsd:choice>
          <xsd:element name="bean" type="beanType"/>
          <xsd:element name="value" type="plainValueType"/>
+         <xsd:element name="inject" type="injectionType"/>
          <xsd:element name="collection" type="collectionType"/>
          <xsd:element name="list" type="listType"/>
          <xsd:element name="set" type="setType"/>
          <xsd:element name="array" type="arrayType"/>
          <xsd:element name="map" type="mapType"/>
-         <xsd:element name="inject" type="injectionType"/>
          <xsd:element name="null">
             <xsd:complexType/>
          </xsd:element>

Copied: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml (from rev 59036, projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml)
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-14 10:33:45 UTC (rev 59036)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 11:58:53 UTC (rev 59037)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean" >
+   <constructor-arg index="2"><value>SpringBean</value></constructor-arg>
+   <constructor-arg index="0"><value>1</value></constructor-arg>
+   <constructor-arg index="1"><value>3.1415</value></constructor-arg>
+   <property name="list">
+      <list value-type="java.lang.String">
+         <value>one</value>
+         <value>two</value>
+         <value>three</value>
+      </list>
+   </property>
+   <property name="set">
+      <set value-type="java.lang.String">
+         <value>one</value>
+         <value>two</value>
+         <value>one</value>
+      </set>
+   </property>
+   <property name="map">
+      <entry>
+         <key>
+            <value>key</value>
+         </key>
+         <value>key</value>
+      </entry>
+   </property>
+</bean>

Deleted: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-14 10:33:45 UTC (rev 59036)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestInstantiate.xml	2006-12-14 11:58:53 UTC (rev 59037)
@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean" >
-   <constructor-arg index="2"><value>SpringBean</value></constructor-arg>
-   <constructor-arg index="0"><value>1</value></constructor-arg>
-   <constructor-arg index="1"><value>3.1415</value></constructor-arg>
-   <property name="list">
-      <list value-type="java.lang.String">
-         <value>one</value>
-         <value>two</value>
-         <value>three</value>
-      </list>
-   </property>
-   <property name="set">
-      <set value-type="java.lang.String">
-         <value>one</value>
-         <value>two</value>
-         <value>one</value>
-      </set>
-   </property>
-<!--
-   <property name="map">
-      <entry>
-         <key>
-            <value>key</value>
-         </key>
-         <value>key</value>
-      </entry>
-   </property>
--->
-</bean>

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-14 10:33:45 UTC (rev 59036)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-14 11:58:53 UTC (rev 59037)
@@ -47,7 +47,7 @@
 
    public void testDescribe() throws Exception
    {
-      BeanMetaData simpleBeanMD = unmarshal("TestInstantiate.xml", BeanMetaData.class);
+      BeanMetaData simpleBeanMD = unmarshal("TestDescribe.xml", BeanMetaData.class);
       // todo - test descriptions
       System.out.println("simpleBean = " + simpleBeanMD);
    }



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 07:00:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 07:00:52 -0500
Subject: [jboss-cvs] JBossAS SVN: r59038 -
	projects/microcontainer/trunk/kernel/src/resources/schema
Message-ID: <E1GupGe-0000SY-E1@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 07:00:50 -0500 (Thu, 14 Dec 2006)
New Revision: 59038

Modified:
   projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd
Log:
not yet implemented - nested bean as value group element

Modified: projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd	2006-12-14 11:58:53 UTC (rev 59037)
+++ projects/microcontainer/trunk/kernel/src/resources/schema/bean-deployer_2_0.xsd	2006-12-14 12:00:50 UTC (rev 59038)
@@ -505,7 +505,7 @@
          </xsd:documentation>
       </xsd:annotation>
       <xsd:choice>
-         <xsd:element name="bean" type="beanType"/>
+         <!--<xsd:element name="bean" type="beanType"/>-->
          <xsd:element name="value" type="plainValueType"/>
          <xsd:element name="inject" type="injectionType"/>
          <xsd:element name="collection" type="collectionType"/>



From msurtani at jboss.com  Thu Dec 14 07:21:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 07:21:39 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gupal-00014x-JV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 07:21:39

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Fixed numLocksHeld
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.35 +98 -94    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.34
  retrieving revision 1.195.2.35
  diff -u -b -r1.195.2.34 -r1.195.2.35
  --- TreeCache.java	13 Dec 2006 16:01:47 -0000	1.195.2.34
  +++ TreeCache.java	14 Dec 2006 12:21:39 -0000	1.195.2.35
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.34 2006/12/13 16:01:47 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.35 2006/12/14 12:21:39 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1501,7 +1501,6 @@
            cacheLoaderManager.preloadCache();
         }
   
  -
         // Find out if we are coordinator (blocks until view is received)
         // TODO should this be moved above the buddy manager code??
         determineCoordinator();
  @@ -1959,11 +1958,11 @@
   
            // Throw the exception on, wrapping if necessary
            if (t instanceof RegionNameConflictException)
  -            throw(RegionNameConflictException) t;
  +            throw (RegionNameConflictException) t;
            else if (t instanceof RegionNotEmptyException)
  -            throw(RegionNotEmptyException) t;
  +            throw (RegionNotEmptyException) t;
            else if (t instanceof CacheException)
  -            throw(CacheException) t;
  +            throw (CacheException) t;
            else
               throw new CacheException(t.getClass().getName() + " " +
                       t.getLocalizedMessage(), t);
  @@ -2109,12 +2108,14 @@
               targets.add(target);
   
               List responses = null;
  -            try {
  +            try
  +            {
                  responses = callRemoteMethods(targets, replPsmc, true,
                       true, sync_repl_timeout);
  -            } catch (Exception t)
  +            }
  +            catch (Exception t)
               {
  -               if(!(t.getCause() instanceof TimeoutException)) throw t;
  +               if (!(t.getCause() instanceof TimeoutException)) throw t;
                                timeoutException = (TimeoutException) t.getCause();
                  timeoutTarget = target;
                  if (trace)
  @@ -4074,7 +4075,8 @@
         Map children;
   
         sb.append("Root lock: ");
  -      if(root.isLocked()) {
  +      if (root.isLocked())
  +      {
            sb.append("\t(");
            root.getLock().toString(sb);
            sb.append(")");
  @@ -4101,20 +4103,20 @@
       */
      public int getNumberOfLocksHeld()
      {
  -      return numLocks(root);
  +      return numLocks((Node) root);
      }
   
  -   private int numLocks(DataNode n)
  +   private int numLocks(Node n)
      {
         int num = 0;
         Map children;
         if (n.isLocked())
            num++;
  -      if ((children = n.getChildren()) != null)
  +      if ((children = n.getChildren(true)) != null)
         {
            for (Iterator it = children.values().iterator(); it.hasNext();)
            {
  -            num += numLocks((DataNode) it.next());
  +            num += numLocks((Node) it.next());
            }
         }
         return num;
  @@ -4195,6 +4197,7 @@
   
       /**
        * Internal method; not to be used externally.
  +    *
        * @param f
        */
       public void realRemove(Fqn f, boolean skipMarkerCheck)
  @@ -4432,7 +4435,6 @@
   
      /* --------------------- Callbacks -------------------------- */
   
  -
      /* ----- These are VERSIONED callbacks to facilitate JBCACHE-843.  Also see docs/design/DataVersion.txt --- */
   
      public void _put(GlobalTransaction tx, Fqn fqn, Map data, boolean create_undo_ops, DataVersion dv) throws CacheException
  @@ -4720,7 +4722,8 @@
         TreeNode parent_node;
         MethodCall undo_op = null;
   
  -      if (log.isTraceEnabled()) log.trace(new StringBuffer("_remove(").append(tx).append(", \"").append(fqn).append("\")"));
  +      if (log.isTraceEnabled())
  +         log.trace(new StringBuffer("_remove(").append(tx).append(", \"").append(fqn).append("\")"));
   
         // check if this is triggered by a rollback operation ...
         if (tx != null)
  @@ -4730,7 +4733,8 @@
               int status = getTransactionManager().getTransaction().getStatus();
               if (status == Status.STATUS_MARKED_ROLLBACK || status == Status.STATUS_ROLLEDBACK || status == Status.STATUS_ROLLING_BACK)
               {
  -               if (log.isDebugEnabled()) log.debug("This remove call is triggered by a transaction rollback, as a compensation operation.  Do a realRemove() instead.");
  +               if (log.isDebugEnabled())
  +                  log.debug("This remove call is triggered by a transaction rollback, as a compensation operation.  Do a realRemove() instead.");
                  realRemove(fqn, true);
                  return;
               }
  @@ -5739,7 +5743,7 @@
         catch (Throwable t)
         {
            if (t instanceof CacheException)
  -            throw(CacheException) t;
  +            throw (CacheException) t;
            throw new RuntimeException(t);
         }
      }
  
  
  


From gavin.king at jboss.com  Thu Dec 14 07:23:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 07:23:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam  ...
Message-ID: <E1GupcS-00016E-3j@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 07:23:24

  Modified:    examples/dvdstore/src/com/jboss/dvd/seam  AcceptAction.java
  Log:
  fix minor bugs
  
  Revision  Changes    Path
  1.14      +1 -1      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/AcceptAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AcceptAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/AcceptAction.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- AcceptAction.java	22 Sep 2006 16:32:08 -0000	1.13
  +++ AcceptAction.java	14 Dec 2006 12:23:24 -0000	1.14
  @@ -43,7 +43,7 @@
   
       @BeginTask
       public String viewTask() {
  -        order = (Order) em.createQuery("select o from Order o join fetch o.orderLines where o.orderId = :orderId")
  +        order = (Order) em.createQuery("select distinct o from Order o join fetch o.orderLines where o.orderId = :orderId")
               .setParameter("orderId", orderId)
               .getSingleResult();
           return "accept";
  
  
  


From gavin.king at jboss.com  Thu Dec 14 07:23:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 07:23:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web  ...
Message-ID: <E1GupcS-00016M-8I@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 07:23:24

  Modified:    examples/dvdstore/web  confirm.xhtml
  Log:
  fix minor bugs
  
  Revision  Changes    Path
  1.10      +1 -1      jboss-seam/examples/dvdstore/web/confirm.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: confirm.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/confirm.xhtml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- confirm.xhtml	2 Nov 2006 18:26:04 -0000	1.9
  +++ confirm.xhtml	14 Dec 2006 12:23:24 -0000	1.10
  @@ -56,7 +56,7 @@
                               <f:facet name="header">
                                   <h:outputText value="#{messages.cartQuantityColumn}" />
                               </f:facet>
  -                            <h:outputText value="#{line.quantity}" size="6" />
  +                            <h:outputText value="#{line.quantity}"/>
                           </h:column>                        
                       </h:dataTable>
                   </h:form>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 07:23:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 07:23:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web/WEB-INF/incl   ...
Message-ID: <E1GupcS-00016Y-Cx@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 07:23:24

  Modified:    examples/dvdstore/web/WEB-INF/incl   cart.xhtml
                        processmenu.xhtml
  Log:
  fix minor bugs
  
  Revision  Changes    Path
  1.8       +0 -1      jboss-seam/examples/dvdstore/web/WEB-INF/incl/cart.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: cart.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/WEB-INF/incl/cart.xhtml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- cart.xhtml	14 Dec 2006 03:12:43 -0000	1.7
  +++ cart.xhtml	14 Dec 2006 12:23:24 -0000	1.8
  @@ -43,4 +43,3 @@
               </dl>
       </div>
   </f:subview>
  -
  
  
  
  1.9       +1 -2      jboss-seam/examples/dvdstore/web/WEB-INF/incl/processmenu.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: processmenu.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/WEB-INF/incl/processmenu.xhtml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- processmenu.xhtml	14 Dec 2006 03:12:43 -0000	1.8
  +++ processmenu.xhtml	14 Dec 2006 12:23:24 -0000	1.9
  @@ -11,8 +11,7 @@
                       <dl>
                           <dt>Process Management</dt>
                           <dd>
  -                            <h:selectOneMenu value="#{processDefinitionSwitcher.currentProcessDefinition}" 
  -                                             size="16">
  +                            <h:selectOneMenu value="#{processDefinitionSwitcher.currentProcessDefinition}">
                                   <f:selectItems value="#{processDefinitionSwitcher.processDefinitions}"/>
                               </h:selectOneMenu>
                           </dd>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 07:23:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 07:23:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web/admin  ...
Message-ID: <E1GupcS-00016f-HS@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 07:23:24

  Modified:    examples/dvdstore/web/admin  ship.xhtml
  Log:
  fix minor bugs
  
  Revision  Changes    Path
  1.4       +1 -1      jboss-seam/examples/dvdstore/web/admin/ship.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ship.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/admin/ship.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ship.xhtml	20 Nov 2006 19:45:32 -0000	1.3
  +++ ship.xhtml	14 Dec 2006 12:23:24 -0000	1.4
  @@ -68,7 +68,7 @@
                                   <f:facet name="header">
                                       <h:outputText value="#{messages.cartQuantityColumn}" />
                                   </f:facet>
  -                                <h:outputText value="#{item.quantity}" size="6" />
  +                                <h:outputText value="#{item.quantity}"/>
                               </h:column>                        
                               <h:column>
                                   <f:facet name="header">
  
  
  


From msurtani at jboss.com  Thu Dec 14 07:39:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 07:39:39 -0500
Subject: [jboss-cvs] JBossCache/docs  ...
Message-ID: <E1GupsB-0001MN-Nf@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 07:39:39

  Modified:    docs     Tag: Branch_JBossCache_1_4_0 Changelog.txt
  Log:
  Updated
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.7  +4 -2      JBossCache/docs/Changelog.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Changelog.txt
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/docs/Changelog.txt,v
  retrieving revision 1.20.2.6
  retrieving revision 1.20.2.7
  diff -u -b -r1.20.2.6 -r1.20.2.7
  --- Changelog.txt	13 Dec 2006 16:05:44 -0000	1.20.2.6
  +++ Changelog.txt	14 Dec 2006 12:39:39 -0000	1.20.2.7
  @@ -1,6 +1,6 @@
  -$Id: Changelog.txt,v 1.20.2.6 2006/12/13 16:05:44 msurtani Exp $
  +$Id: Changelog.txt,v 1.20.2.7 2006/12/14 12:39:39 msurtani Exp $
   
  -Release 1.4.1.CR1 (December 13th, 2006)
  +Release 1.4.1.CR1 (December 14th, 2006)
   ======================================
   Release Notes for JBoss Cache
   Includes versions: 1.4.1.GA
  @@ -11,6 +11,7 @@
       *  [ JBCACHE-842 ] Optimistic Locking improvements - validation on read-only transactions
       *  [ JBCACHE-860 ] Clustered Cache Loaders too "noisy" with error level logging when alone in the cluster
       *  [ JBCACHE-878 ] Documment SyncCommitPhase
  +    *  [ JBCACHE-906 ] JBCMethodCall should override toString() so that it includes the method id as well
   
   ** Bug
       *  [ JBCACHE-690 ] TcpCacheServer never gets out of STARTING state, and doesn't shut down socket when stop() is called.
  @@ -59,6 +60,7 @@
       *  [ JBCACHE-886 ] Upgrading from JGroups 2.2.9.2 to JGroups 2.4
       *  [ JBCACHE-887 ] Upgrading from JBoss Serialization 1.0.1.GA to JBoss Serialization 1.0.3.GA
       *  [ JBCACHE-901 ] Update logging libraries
  +    *  [ JBCACHE-905 ] Perform code coverage analysis and add missing unit tests
   
   ** Patch
       *  [ JBCACHE-766 ] Don't return unnecessary values from _replicate, avoiding need for marshalling
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 07:42:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 07:42:01 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59039 - branches
Message-ID: <E1GupuT-0001Qy-CW@committer01.frg.pub.inap.atl.jboss.com>

Author: galder.zamarreno at jboss.com
Date: 2006-12-14 07:41:59 -0500 (Thu, 14 Dec 2006)
New Revision: 59039

Added:
   branches/JBoss_4_0_3_SP1_JBAS-3944/
Log:
Branch for cummulative Patch that includes JBAS-3808 and JBAS-2650

Copied: branches/JBoss_4_0_3_SP1_JBAS-3944 (from rev 59038, branches/JBoss_4_0_3_SP1_JBAS-3808)



From msurtani at jboss.com  Thu Dec 14 07:51:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 07:51:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache    ...
Message-ID: <E1Guq3w-0001bM-6z@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 07:51:48

  Modified:    src/org/jboss/cache    Tag: Branch_JBossCache_1_4_0
                        TreeCache.java DataNode.java Node.java
  Log:
  Updated the way nodes are marked for removal (API stuff)
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.36 +8 -49     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.35
  retrieving revision 1.195.2.36
  diff -u -b -r1.195.2.35 -r1.195.2.36
  --- TreeCache.java	14 Dec 2006 12:21:39 -0000	1.195.2.35
  +++ TreeCache.java	14 Dec 2006 12:51:47 -0000	1.195.2.36
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.35 2006/12/14 12:21:39 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.36 2006/12/14 12:51:47 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -109,7 +109,6 @@
      private static final String[] MUX_TYPES = {"java.lang.String", "java.lang.String"};
      private static final String JBOSS_SERVER_DOMAIN = "jboss";
   
  -   private static final String REMOVAL_MARKER = "__JBOSS_MARKED_FOR_REMOVAL";
      private boolean forceAnycast = false;
      /**
       * Default replication version, from {@link Version#getVersionShort}.
  @@ -3635,7 +3634,7 @@
            n = n.getChild(obj);
            if (n == null)
               return null;
  -         else if (!includeNodesMarkedAsRemoved && isMarkedForRemoval(n))
  +         else if (!includeNodesMarkedAsRemoved && ((DataNode) n).isMarkedForRemoval())
               return null;
         }
         return (Node) n;
  @@ -4155,46 +4154,6 @@
         return count;
      }
   
  -   private void markForRemoval(Node n)
  -   {
  -      n.put(REMOVAL_MARKER, null);
  -      // mark children as well.
  -      Map children = n.getChildren(true);
  -      if (children != null && !children.isEmpty())
  -      {
  -         // traverse children
  -         Iterator i = children.values().iterator();
  -         while (i.hasNext())
  -         {
  -            markForRemoval((Node) i.next());
  -         }
  -      }
  -   }
  -
  -   public void scrubRemoveMarker(Node n, boolean deep)
  -   {
  -      n.remove(REMOVAL_MARKER);
  -      // unmark children as well.
  -      if (deep)
  -      {
  -         Map children = n.getChildren(true);
  -         if (children != null && !children.isEmpty())
  -         {
  -            // traverse children
  -            Iterator i = children.values().iterator();
  -            while (i.hasNext())
  -            {
  -               scrubRemoveMarker((Node) i.next(), true);
  -            }
  -         }
  -      }
  -   }
  -
  -   public boolean isMarkedForRemoval(TreeNode n)
  -   {
  -      return n.containsKey(REMOVAL_MARKER);
  -   }
  -
      /**
       * Internal method; not to be used externally.
       *
  @@ -4207,12 +4166,12 @@
            return;
   
         if (log.isDebugEnabled()) log.debug("Performing a real remove for node " + f + ", marked for removal.");
  -      if (skipMarkerCheck || isMarkedForRemoval(n))
  +      if (skipMarkerCheck || n.isMarkedForRemoval())
         {
            if (n.getFqn().isRoot())
            {
               // do not actually delete; just remove deletion marker
  -            scrubRemoveMarker(n, false);
  +            n.unmarkForRemoval(false);
               // but now remove all children, since the call has been to remove("/")
               n.removeAllChildren();
            }
  @@ -4554,7 +4513,7 @@
         }
         notifyNodeModify(fqn, true);
   
  -      scrubRemoveMarker(n, false);
  +      n.unmarkForRemoval(false);
   
         // TODO: move creation of undo-operations to separate Interceptor
         // create a compensating method call (reverting the effect of
  @@ -4630,7 +4589,7 @@
         notifyNodeModify(fqn, true);
         old_value = n.put(key, value);
   
  -      scrubRemoveMarker(n, false);
  +      n.unmarkForRemoval(false);
   
         // create a compensating method call (reverting the effect of
         // this modification) and put it into the TX's undo list.
  @@ -4788,7 +4747,7 @@
         if (isNodeLockingOptimistic() || eviction)
            parent_node.removeChild(n.getName());
         else
  -         markForRemoval(n);
  +         n.markForRemoval();
   
         if (eviction)
            parent_node.setChildrenLoaded(false);
  @@ -5065,7 +5024,7 @@
         }
         tmp.addChild(child_name, old_node);
         // make sure any deleted markers are removed from this child.
  -      scrubRemoveMarker((Node) old_node, true);
  +      old_node.unmarkForRemoval(true);
         notifyNodeCreated(new Fqn(parent_fqn, child_name));
      }
   
  
  
  
  1.15.2.1  +7 -0      JBossCache/src/org/jboss/cache/DataNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/DataNode.java,v
  retrieving revision 1.15
  retrieving revision 1.15.2.1
  diff -u -b -r1.15 -r1.15.2.1
  --- DataNode.java	25 Apr 2006 15:18:28 -0000	1.15
  +++ DataNode.java	14 Dec 2006 12:51:48 -0000	1.15.2.1
  @@ -27,6 +27,8 @@
      /** Lock type of write. */
      int LOCK_TYPE_WRITE = 2;
   
  +   public static final String REMOVAL_MARKER = "__JBOSS_MARKED_FOR_REMOVAL";
  +
      /** Initialized property for debugging "print_lock_details" */
      boolean PRINT_LOCK_DETAILS = Boolean.getBoolean("print_lock_details");
   
  @@ -44,4 +46,9 @@
       */
      Object clone() throws CloneNotSupportedException;
   
  +   boolean isMarkedForRemoval();
  +
  +   void unmarkForRemoval(boolean deep);
  +
  +   void markForRemoval();
   }
  
  
  
  1.38.2.4  +40 -1     JBossCache/src/org/jboss/cache/Node.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Node.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Node.java,v
  retrieving revision 1.38.2.3
  retrieving revision 1.38.2.4
  diff -u -b -r1.38.2.3 -r1.38.2.4
  --- Node.java	13 Dec 2006 16:01:47 -0000	1.38.2.3
  +++ Node.java	14 Dec 2006 12:51:48 -0000	1.38.2.4
  @@ -181,7 +181,7 @@
         while (c.hasNext())
         {
            Node ch = (Node) c.next();
  -         if (!cache.isMarkedForRemoval(ch))
  +         if (!ch.isMarkedForRemoval())
            {
               toReturn.put(ch.getName(), ch);
            }
  @@ -650,5 +650,44 @@
         // whenever a cache is assigned via setTreeCacheInstance
      }
   
  +   public void markForRemoval()
  +   {
  +      put(REMOVAL_MARKER, null);
  +      // mark children as well.
  +      Map children = getChildren(true);
  +      if (children != null && !children.isEmpty())
  +      {
  +         // traverse children
  +         Iterator i = children.values().iterator();
  +         while (i.hasNext())
  +         {
  +            ((Node) i.next()).markForRemoval();
  +         }
  +      }
  +   }
  +
  +   public void unmarkForRemoval(boolean deep)
  +   {
  +      remove(REMOVAL_MARKER);
  +      // unmark children as well.
  +      if (deep)
  +      {
  +         Map children = getChildren(true);
  +         if (children != null && !children.isEmpty())
  +         {
  +            // traverse children
  +            Iterator i = children.values().iterator();
  +            while (i.hasNext())
  +            {
  +               ((Node) i.next()).unmarkForRemoval(true);
  +            }
  +         }
  +      }
  +   }
  +
  +   public boolean isMarkedForRemoval()
  +   {
  +      return containsKey(REMOVAL_MARKER);
  +   }
   }
   
  
  
  


From msurtani at jboss.com  Thu Dec 14 07:51:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 07:51:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1Guq3w-0001bX-B2@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 07:51:48

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0
                        PessimisticLockInterceptor.java
  Log:
  Updated the way nodes are marked for removal (API stuff)
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.20.2.8  +3 -4      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.20.2.7
  retrieving revision 1.20.2.8
  diff -u -b -r1.20.2.7 -r1.20.2.8
  --- PessimisticLockInterceptor.java	13 Dec 2006 16:01:47 -0000	1.20.2.7
  +++ PessimisticLockInterceptor.java	14 Dec 2006 12:51:48 -0000	1.20.2.8
  @@ -10,7 +10,6 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
  -import org.jboss.cache.Node;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
   import org.jboss.cache.TreeCache;
  @@ -37,7 +36,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.7 2006/12/13 16:01:47 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.20.2.8 2006/12/14 12:51:48 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -314,12 +313,12 @@
   
      private boolean needToReverseRemove(DataNode n, TransactionEntry te, int lockTypeRequested, boolean isRemoveOperation, boolean createIfNotExists)
      {
  -      return !isRemoveOperation && createIfNotExists && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && cache.isMarkedForRemoval(n) && te.getRemovedNodes().contains(n.getFqn());
  +      return !isRemoveOperation && createIfNotExists && lockTypeRequested == DataNode.LOCK_TYPE_WRITE && n.isMarkedForRemoval() && te.getRemovedNodes().contains(n.getFqn());
      }
   
      private void reverseRemove(DataNode n)
      {
  -      cache.scrubRemoveMarker((Node) n, false);
  +      n.unmarkForRemoval(false);
      }
   
      private boolean writeLockNeeded(int lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
  
  
  


From gavin.king at jboss.com  Thu Dec 14 07:56:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 07:56:42 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web/admin  ...
Message-ID: <E1Guq8g-0001jd-Og@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 07:56:42

  Modified:    examples/dvdstore/web/admin  accept.xhtml
  Log:
  fix
  
  Revision  Changes    Path
  1.4       +1 -1      jboss-seam/examples/dvdstore/web/admin/accept.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: accept.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/admin/accept.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- accept.xhtml	20 Nov 2006 19:45:32 -0000	1.3
  +++ accept.xhtml	14 Dec 2006 12:56:42 -0000	1.4
  @@ -59,7 +59,7 @@
                               <f:facet name="header">
                                   <h:outputText value="#{messages.cartQuantityColumn}" />
                               </f:facet>
  -                            <h:outputText value="#{item.quantity}" size="6" />
  +                            <h:outputText value="#{item.quantity}" />
                           </h:column>                        
                           <h:column>
                               <f:facet name="header">
  
  
  


From gavin.king at jboss.com  Thu Dec 14 08:08:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 08:08:57 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core         ...
Message-ID: <E1GuqKX-00027R-PS@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 08:08:57

  Modified:    src/main/org/jboss/seam/core         BusinessProcess.java
                        ManagedJbpmContext.java PooledTask.java
                        PooledTaskInstanceList.java ProcessInstance.java
                        TaskInstance.java TaskInstanceList.java
                        TaskInstanceListForType.java
  Log:
  use new jBPM APIs
  also eliminate jbpmContext.getSession().clear(), which may break stuff
  
  Revision  Changes    Path
  1.14      +1 -12     jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcess.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- BusinessProcess.java	24 Nov 2006 23:15:17 -0000	1.13
  +++ BusinessProcess.java	14 Dec 2006 13:08:57 -0000	1.14
  @@ -14,8 +14,6 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -import org.jbpm.JbpmContext;
  -import org.jbpm.graph.def.ProcessDefinition;
   import org.jbpm.graph.exe.ProcessInstance;
   import org.jbpm.taskmgmt.exe.TaskInstance;
   
  @@ -104,16 +102,7 @@
       */
      public void createProcess(String processDefinitionName)
      {
  -      JbpmContext jbpmContext = ManagedJbpmContext.instance();
  -      
  -      ProcessDefinition pd = jbpmContext.getGraphSession().findLatestProcessDefinition(processDefinitionName);
  -      if ( pd == null )
  -      {
  -         throw new IllegalArgumentException( "Unknown process definition: " + processDefinitionName );
  -      }
  -      
  -      ProcessInstance process = pd.createProcessInstance();
  -      jbpmContext.save(process);
  +      ProcessInstance process = ManagedJbpmContext.instance().newProcessInstanceForUpdate(processDefinitionName);
         setProcessId( process.getId() );
         // need to set process variables before the signal
         Contexts.getBusinessProcessContext().flush();
  
  
  
  1.21      +4 -5      jboss-seam/src/main/org/jboss/seam/core/ManagedJbpmContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedJbpmContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ManagedJbpmContext.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- ManagedJbpmContext.java	24 Nov 2006 23:15:17 -0000	1.20
  +++ ManagedJbpmContext.java	14 Dec 2006 13:08:57 -0000	1.21
  @@ -36,7 +36,7 @@
    * Manages a reference to a JbpmSession.
    *
    * @author <a href="mailto:steve at hibernate.org">Steve Ebersole </a>
  - * @version $Revision: 1.20 $
  + * @version $Revision: 1.21 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.jbpmContext")
  @@ -91,9 +91,9 @@
         {
            jbpmContext.save(processInstance);
         }
  -      log.debug( "flushing business process context" );
         Contexts.getBusinessProcessContext().flush();
         jbpmContext.getSession().flush();
  +      log.debug( "done flushing seam managed jBPM context" );
      }
      
      public void afterCompletion(int status) {
  @@ -104,9 +104,8 @@
      public void destroy()
      {
         log.debug( "destroying seam managed jBPM context" );
  -      //jbpmContext.setRollbackOnly(); //TODO: this currently has no effect (bug in jBPM)
  -      jbpmContext.getSession().clear(); //WORKAROUND for jBPM bug, prevent flushing of session!
         jbpmContext.close();
  +      log.debug( "done destroying seam managed jBPM context" );
      }
         
      public static JbpmContext instance()
  
  
  
  1.15      +1 -3      jboss-seam/src/main/org/jboss/seam/core/PooledTask.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PooledTask.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/PooledTask.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- PooledTask.java	24 Nov 2006 23:15:17 -0000	1.14
  +++ PooledTask.java	14 Dec 2006 13:08:57 -0000	1.15
  @@ -87,9 +87,7 @@
               .get("taskId");
         return taskId==null ? 
               null : 
  -            ManagedJbpmContext.instance()
  -                  .getTaskMgmtSession()
  -                  .loadTaskInstance( Long.parseLong(taskId) );
  +            ManagedJbpmContext.instance().getTaskInstanceForUpdate( Long.parseLong(taskId) );
      }
      
   }
  
  
  
  1.8       +2 -8      jboss-seam/src/main/org/jboss/seam/core/PooledTaskInstanceList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PooledTaskInstanceList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/PooledTaskInstanceList.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- PooledTaskInstanceList.java	24 Nov 2006 23:15:17 -0000	1.7
  +++ PooledTaskInstanceList.java	14 Dec 2006 13:08:57 -0000	1.8
  @@ -4,7 +4,6 @@
   
   import java.util.ArrayList;
   import java.util.List;
  -import java.util.Set;
   
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -30,13 +29,8 @@
      @Transactional
      public List<TaskInstance> getPooledTaskInstanceList()
      {
  -      List<TaskInstance> pooledTaskInstanceList = new ArrayList<TaskInstance>();
  -      Set<String> actorIds = Actor.instance().getGroupActorIds();
  -      for (String actorId: actorIds )
  -      {
  -         pooledTaskInstanceList.addAll( ManagedJbpmContext.instance().getTaskMgmtSession().findPooledTaskInstances(actorId) );
  -      }
  -      return pooledTaskInstanceList;
  +      return ManagedJbpmContext.instance()
  +            .getGroupTaskList( new ArrayList( Actor.instance().getGroupActorIds() ) );
      }
      
   }
  
  
  
  1.19      +2 -2      jboss-seam/src/main/org/jboss/seam/core/ProcessInstance.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProcessInstance.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ProcessInstance.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- ProcessInstance.java	24 Nov 2006 23:15:17 -0000	1.18
  +++ ProcessInstance.java	14 Dec 2006 13:08:57 -0000	1.19
  @@ -24,7 +24,7 @@
    * jBPM ProcessInstance.
    * 
    * @author Gavin King
  - * @version $Revision: 1.18 $
  + * @version $Revision: 1.19 $
    */
   @Scope(ScopeType.APPLICATION)
   @Name("org.jboss.seam.core.processInstance")
  @@ -49,7 +49,7 @@
               {
                  //TODO: do we need to cache this??
                  //TODO: use getProcessInstance(), which returns null!
  -               return ManagedJbpmContext.instance().getGraphSession().loadProcessInstance(processId);
  +               return ManagedJbpmContext.instance().getProcessInstanceForUpdate(processId);
               }
               else
               {
  
  
  
  1.18      +2 -2      jboss-seam/src/main/org/jboss/seam/core/TaskInstance.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TaskInstance.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TaskInstance.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- TaskInstance.java	24 Nov 2006 23:15:17 -0000	1.17
  +++ TaskInstance.java	14 Dec 2006 13:08:57 -0000	1.18
  @@ -24,7 +24,7 @@
    * jBPM TaskInstance.
    * 
    * @author Gavin King
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   @Scope(ScopeType.APPLICATION)
   @Name("org.jboss.seam.core.taskInstance")
  @@ -49,7 +49,7 @@
               {
                  //TODO: do we need to cache this??
                  //TODO: use getTaskInstance(), which returns null!
  -               return ManagedJbpmContext.instance().getTaskMgmtSession().loadTaskInstance(taskId);
  +               return ManagedJbpmContext.instance().getTaskInstanceForUpdate(taskId);
               }
               else
               {
  
  
  
  1.14      +1 -4      jboss-seam/src/main/org/jboss/seam/core/TaskInstanceList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TaskInstanceList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TaskInstanceList.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- TaskInstanceList.java	1 Dec 2006 11:34:05 -0000	1.13
  +++ TaskInstanceList.java	14 Dec 2006 13:08:57 -0000	1.14
  @@ -3,7 +3,6 @@
   import static org.jboss.seam.ScopeType.APPLICATION;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import java.util.ArrayList;
   import java.util.List;
   
   import org.jboss.seam.annotations.Install;
  @@ -38,9 +37,7 @@
      {
         if ( actorId == null ) return null;
   
  -      List<TaskInstance> list = new ArrayList<TaskInstance>();
  -      list.addAll( ManagedJbpmContext.instance().getTaskMgmtSession().findTaskInstances(actorId) );
  -      return list;
  +      return ManagedJbpmContext.instance().getTaskList(actorId);
      }
      
   }
  
  
  
  1.13      +1 -1      jboss-seam/src/main/org/jboss/seam/core/TaskInstanceListForType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TaskInstanceListForType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TaskInstanceListForType.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- TaskInstanceListForType.java	24 Nov 2006 23:15:17 -0000	1.12
  +++ TaskInstanceListForType.java	14 Dec 2006 13:08:57 -0000	1.13
  @@ -40,7 +40,7 @@
         if ( actorId == null ) return null;
   
         Map<String, List<TaskInstance>> map = new HashMap<String, List<TaskInstance>>();
  -      List<TaskInstance> taskInstances = ManagedJbpmContext.instance().getTaskMgmtSession().findTaskInstances(actorId);
  +      List<TaskInstance> taskInstances = ManagedJbpmContext.instance().getTaskList(actorId);
         for ( TaskInstance task: taskInstances )
         {
            String name = task.getName();
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 08:13:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 08:13:12 -0500
Subject: [jboss-cvs] JBossAS SVN: r59040 - in
	projects/microcontainer/trunk/spring-int/src:
	main/org/jboss/spring/deployment/xml
	resources/org/jboss/test/spring/test
	tests/org/jboss/test/spring/support
Message-ID: <E1GuqOe-0002D6-Dw@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 08:13:00 -0500 (Thu, 14 Dec 2006)
New Revision: 59040

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
   projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
Log:
JBMICROCONT-26; inital code addon

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java	2006-12-14 12:41:59 UTC (rev 59039)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/RefHandler.java	2006-12-14 13:13:00 UTC (rev 59040)
@@ -52,6 +52,7 @@
          String localName = attrs.getLocalName(i);
          if ("bean".equals(localName))
             value.setValue(attrs.getValue(i));
+         // todo local, parent
       }
    }
 

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java	2006-12-14 12:41:59 UTC (rev 59039)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringCollectionHandler.java	2006-12-14 13:13:00 UTC (rev 59040)
@@ -44,7 +44,6 @@
    public Object startElement(Object parent, QName name, ElementBinding element)
    {
       String typeName = element.getQName().getLocalPart();
-      // todo - does this work?
       if ("list".equals(typeName))
          return new AbstractListMetaData();
       else if ("set".equals(typeName))

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-14 12:41:59 UTC (rev 59039)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-14 13:13:00 UTC (rev 59040)
@@ -21,8 +21,8 @@
 */
 package org.jboss.spring.deployment.xml;
 
+import org.jboss.kernel.plugins.deployment.xml.*;
 import org.jboss.xb.binding.sunday.unmarshalling.TypeBinding;
-import org.jboss.kernel.plugins.deployment.xml.*;
 
 /**
  * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
@@ -71,13 +71,12 @@
       configureValueBindings(typeBinding);
    }
 
+   // here value only takes simple type
    public static void initValueHandler(TypeBinding typeBinding)
    {
       typeBinding.setHandler(PlainValueHandler.HANDLER);
       // value can take characters
       typeBinding.setSimpleType(PlainValueCharactersHandler.HANDLER);
-      // configure
-      configureValueBindings(typeBinding);
    }
 
    public static void initCollectionHandler(TypeBinding typeBinding)
@@ -99,19 +98,44 @@
       typeBinding.setHandler(EntryHandler.HANDLER);
       // entry has a key
       typeBinding.pushInterceptor(SpringSchemaBinding.keyQName, EntryKeyInterceptor.INTERCEPTOR);
-      // entry has a value
+
+      // entry has bean
+      typeBinding.pushInterceptor(SpringSchemaBinding.beanQName, EntryValueInterceptor.INTERCEPTOR);
+
+      // entry has ref
+      typeBinding.pushInterceptor(SpringSchemaBinding.refQName, EntryValueInterceptor.INTERCEPTOR);
+
+      // entry has value
       typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, EntryValueInterceptor.INTERCEPTOR);
+
+      // entry can take a list
+      typeBinding.pushInterceptor(SpringSchemaBinding.listQName, EntryValueInterceptor.INTERCEPTOR);
+
+      // entry can take a set
+      typeBinding.pushInterceptor(SpringSchemaBinding.setQName, EntryValueInterceptor.INTERCEPTOR);
+
+      // entry can take a map
+      typeBinding.pushInterceptor(SpringSchemaBinding.mapQName, EntryValueInterceptor.INTERCEPTOR);
+
+      // entry has a null
+      typeBinding.pushInterceptor(SpringSchemaBinding.nullQName, EntryValueInterceptor.INTERCEPTOR);
    }
 
    public static void initKeyHandler(TypeBinding typeBinding)
    {
       typeBinding.setHandler(SpringMapKeyHandler.HANDLER);
       // key has a value
-      typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, ValueMetaDataElementInterceptor.VALUES);
+      configureValueBindings(typeBinding);
    }
 
    public static void configureValueBindings(TypeBinding typeBinding)
    {
+      // type has beans
+      typeBinding.pushInterceptor(SpringSchemaBinding.beanQName, ValueMetaDataElementInterceptor.VALUES);
+
+      // type has refs
+      typeBinding.pushInterceptor(SpringSchemaBinding.refQName, ValueMetaDataElementInterceptor.VALUES);
+
       // type has values
       typeBinding.pushInterceptor(SpringSchemaBinding.valueQName, ValueMetaDataElementInterceptor.VALUES);
 

Modified: projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 12:41:59 UTC (rev 59039)
+++ projects/microcontainer/trunk/spring-int/src/resources/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 13:13:00 UTC (rev 59040)
@@ -4,14 +4,14 @@
    <constructor-arg index="2"><value>SpringBean</value></constructor-arg>
    <constructor-arg index="0"><value>1</value></constructor-arg>
    <constructor-arg index="1"><value>3.1415</value></constructor-arg>
-   <property name="list">
+   <property name="mylist">
       <list value-type="java.lang.String">
          <value>one</value>
          <value>two</value>
          <value>three</value>
       </list>
    </property>
-   <property name="set">
+   <property name="myset">
       <set value-type="java.lang.String">
          <value>one</value>
          <value>two</value>
@@ -23,7 +23,7 @@
          <key>
             <value>key</value>
          </key>
-         <value>key</value>
+         <value>myvalue</value>
       </entry>
    </property>
 </bean>

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-14 12:41:59 UTC (rev 59039)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-14 13:13:00 UTC (rev 59040)
@@ -34,9 +34,9 @@
    private int x;
    private double y;
    private String s;
-   private List list;
-   private Set set;
-   private Map map;
+   private List mylist;
+   private Set myset;
+   private Map mymap;
 
    public SimpleBean()
    {
@@ -49,34 +49,34 @@
       this.s = s;
    }
 
-   public List getList()
+   public List getMylist()
    {
-      return list;
+      return mylist;
    }
 
-   public void setList(List list)
+   public void setMylist(List mylist)
    {
-      this.list = list;
+      this.mylist = mylist;
    }
 
-   public Set getSet()
+   public Set getMyset()
    {
-      return set;
+      return myset;
    }
 
-   public void setSet(Set set)
+   public void setMyset(Set myset)
    {
-      this.set = set;
+      this.myset = myset;
    }
 
-   public Map getMap()
+   public Map getMymap()
    {
-      return map;
+      return mymap;
    }
 
-   public void setMap(Map map)
+   public void setMymap(Map mymap)
    {
-      this.map = map;
+      this.mymap = mymap;
    }
 
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 08:32:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 08:32:46 -0500
Subject: [jboss-cvs] JBossAS SVN: r59041 -
	projects/microcontainer/trunk/spring-int/src/resources/schema
Message-ID: <E1Guqha-0002XZ-Ro@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 08:32:44 -0500 (Thu, 14 Dec 2006)
New Revision: 59041

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
Log:
JBMICROCONT-26; named types

Modified: projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-14 13:13:00 UTC (rev 59040)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-14 13:32:44 UTC (rev 59041)
@@ -79,12 +79,12 @@
 
    <xsd:complexType name="beansType">
       <xsd:sequence>
-         <xsd:element ref="description" minOccurs="0"/>
+         <xsd:element name="description" type="descriptionType" minOccurs="0"/>
 
          <xsd:choice minOccurs="0" maxOccurs="unbounded">
-            <xsd:element ref="import"/>
-            <xsd:element ref="alias"/>
-            <xsd:element ref="bean"/>
+            <xsd:element name="import" type="importType"/>
+            <xsd:element name="alias" type="aliasType"/>
+            <xsd:element name="bean" type="beanType"/>
             <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:choice>
       </xsd:sequence>
@@ -161,7 +161,7 @@
 
    </xsd:complexType>
 
-   <xsd:element name="description">
+   <xsd:element name="description" type="descriptionType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	Contains informative text describing the purpose of the enclosing
@@ -169,77 +169,78 @@
 	Used primarily for user documentation of XML bean definition documents.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType mixed="true">
-         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
-
-      </xsd:complexType>
    </xsd:element>
 
-   <xsd:element name="import">
+   <xsd:complexType name="descriptionType" mixed="true">
+      <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+   </xsd:complexType>
+
+   <xsd:element name="import" type="importType">
       <xsd:annotation>
          <xsd:documentation source="java:org.springframework.core.io.Resource"><![CDATA[
 	Specifies an XML bean definition resource to import.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType>
-         <xsd:complexContent>
+   </xsd:element>
 
-            <xsd:restriction base="xsd:anyType">
-               <xsd:attribute name="resource" type="xsd:string" use="required">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The relative resource location of the XML (bean definition) file to import,
-	for example "myImport.xml" or "includes/myImport.xml" or "../myImport.xml".
-							]]></xsd:documentation>
-                  </xsd:annotation>
-               </xsd:attribute>
-            </xsd:restriction>
-         </xsd:complexContent>
-      </xsd:complexType>
+   <xsd:complexType name="importType">
+      <xsd:complexContent>
 
-   </xsd:element>
+         <xsd:restriction base="xsd:anyType">
+            <xsd:attribute name="resource" type="xsd:string" use="required">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The relative resource location of the XML (bean definition) file to import,
+for example "myImport.xml" or "includes/myImport.xml" or "../myImport.xml".
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+         </xsd:restriction>
+      </xsd:complexContent>
+   </xsd:complexType>
 
-   <xsd:element name="alias">
+   <xsd:element name="alias" type="aliasType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	Defines an alias for a bean (which can reside in a different definition
 	resource).
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType>
-         <xsd:complexContent>
-            <xsd:restriction base="xsd:anyType">
+   </xsd:element>
 
-               <xsd:attribute name="name" type="xsd:string" use="required">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The name of the bean to define an alias for.
-							]]></xsd:documentation>
-                  </xsd:annotation>
-               </xsd:attribute>
-               <xsd:attribute name="alias" type="xsd:string" use="required">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The alias name to define for the bean.
-							]]></xsd:documentation>
-                  </xsd:annotation>
+   <xsd:complexType name="aliasType">
+      <xsd:complexContent>
+         <xsd:restriction base="xsd:anyType">
 
-               </xsd:attribute>
-            </xsd:restriction>
-         </xsd:complexContent>
-      </xsd:complexType>
-   </xsd:element>
+            <xsd:attribute name="name" type="xsd:string" use="required">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the bean to define an alias for.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+            <xsd:attribute name="alias" type="xsd:string" use="required">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The alias name to define for the bean.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
 
+            </xsd:attribute>
+         </xsd:restriction>
+      </xsd:complexContent>
+   </xsd:complexType>
+
    <xsd:group name="beanElements">
       <xsd:sequence>
-         <xsd:element ref="description" minOccurs="0"/>
+         <xsd:element name="description" type="descriptionType" minOccurs="0"/>
 
          <xsd:choice minOccurs="0" maxOccurs="unbounded">
-            <xsd:element ref="meta"/>
-            <xsd:element ref="constructor-arg"/>
-            <xsd:element ref="property"/>
-            <xsd:element ref="lookup-method"/>
-            <xsd:element ref="replaced-method"/>
+            <xsd:element name="meta" type="metaType"/>
+            <xsd:element name="constructor-arg" type="constructorArgType"/>
+            <xsd:element name="property" type="propertyType"/>
+            <xsd:element name="lookup-method" type="lookup-methodType"/>
+            <xsd:element name="replaced-method" type="replaced-methodType"/>
             <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:choice>
       </xsd:sequence>
@@ -590,18 +591,18 @@
    <xsd:complexType name="constructorArgType">
       <xsd:sequence>
 
-         <xsd:element ref="description" minOccurs="0"/>
+         <xsd:element name="description" type="descriptionType" minOccurs="0"/>
          <xsd:choice minOccurs="0" maxOccurs="1">
-            <xsd:element ref="bean"/>
-            <xsd:element ref="ref"/>
-            <xsd:element ref="idref"/>
-            <xsd:element ref="value"/>
-            <xsd:element ref="null"/>
-            <xsd:element ref="list"/>
-            <xsd:element ref="set"/>
+            <xsd:element name="bean" type="beanType"/>
+            <xsd:element name="ref" type="refType"/>
+            <xsd:element name="idref" type="idrefType"/>
+            <xsd:element name="value" type="valueType"/>
+            <xsd:element name="null" type="nullType"/>
+            <xsd:element name="list" type="listOrSetType"/>
+            <xsd:element name="set" type="listOrSetType"/>
 
-            <xsd:element ref="map"/>
-            <xsd:element ref="props"/>
+            <xsd:element name="map" type="mapType"/>
+            <xsd:element name="props" type="propsType"/>
             <xsd:any namespace="##other" processContents="strict"/>
          </xsd:choice>
       </xsd:sequence>
@@ -653,7 +654,7 @@
       </xsd:annotation>
    </xsd:element>
 
-   <xsd:element name="lookup-method">
+   <xsd:element name="lookup-method" type="lookup-methodType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	A lookup method causes the IoC container to override the given method
@@ -665,33 +666,34 @@
 			]]></xsd:documentation>
 
       </xsd:annotation>
-      <xsd:complexType>
-         <xsd:complexContent>
-            <xsd:restriction base="xsd:anyType">
-               <xsd:attribute name="name" type="xsd:string">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The name of the lookup method. This method must take no arguments.
-							]]></xsd:documentation>
-                  </xsd:annotation>
-               </xsd:attribute>
-
-               <xsd:attribute name="bean" type="xsd:string">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The name of the bean in the current or ancestor factories that
-	the lookup method should resolve to. Often this bean will be a
-	prototype, in which case the lookup method will return a distinct
-	instance on every invocation. This is useful for single-threaded objects.
-							]]></xsd:documentation>
-                  </xsd:annotation>
-               </xsd:attribute>
-            </xsd:restriction>
-         </xsd:complexContent>
-      </xsd:complexType>
    </xsd:element>
 
-   <xsd:element name="replaced-method">
+   <xsd:complexType name="lookup-methodType">
+      <xsd:complexContent>
+         <xsd:restriction base="xsd:anyType">
+            <xsd:attribute name="name" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the lookup method. This method must take no arguments.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+
+            <xsd:attribute name="bean" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the bean in the current or ancestor factories that
+the lookup method should resolve to. Often this bean will be a
+prototype, in which case the lookup method will return a distinct
+instance on every invocation. This is useful for single-threaded objects.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+         </xsd:restriction>
+      </xsd:complexContent>
+   </xsd:complexType>
+
+   <xsd:element name="replaced-method" type="replaced-methodType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	Similar to the lookup method mechanism, the replaced-method element
@@ -699,38 +701,39 @@
 	This mechanism allows the overriding of a method with arbitrary code.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType>
-         <xsd:sequence>
-            <xsd:choice minOccurs="0" maxOccurs="unbounded">
-               <xsd:element ref="arg-type"/>
+   </xsd:element>
 
-            </xsd:choice>
-         </xsd:sequence>
-         <xsd:attribute name="name" type="xsd:string">
-            <xsd:annotation>
-               <xsd:documentation><![CDATA[
-	The name of the method whose implementation must be replaced by the
-	IoC container. If this method is not overloaded, there is no need
-	to use arg-type subelements. If this method is overloaded, arg-type
-	subelements must be used for all override definitions for the method.
-					]]></xsd:documentation>
-            </xsd:annotation>
-         </xsd:attribute>
-         <xsd:attribute name="replacer" type="xsd:string">
-            <xsd:annotation>
+   <xsd:complexType name="replaced-methodType">
+      <xsd:sequence>
+         <xsd:choice minOccurs="0" maxOccurs="unbounded">
+            <xsd:element name="arg-type" type="argType"/>
 
-               <xsd:documentation source="java:org.springframework.beans.factory.support.MethodReplacer"><![CDATA[
-	Bean name of an implementation of the MethodReplacer interface in the
-	current or ancestor factories. This may be a singleton or prototype
-	bean. If it is a prototype, a new instance will be used for each
-	method replacement. Singleton usage is the norm.
-					]]></xsd:documentation>
-            </xsd:annotation>
-         </xsd:attribute>
-      </xsd:complexType>
-   </xsd:element>
+         </xsd:choice>
+      </xsd:sequence>
+      <xsd:attribute name="name" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+The name of the method whose implementation must be replaced by the
+IoC container. If this method is not overloaded, there is no need
+to use arg-type subelements. If this method is overloaded, arg-type
+subelements must be used for all override definitions for the method.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+      <xsd:attribute name="replacer" type="xsd:string">
+         <xsd:annotation>
 
-   <xsd:element name="arg-type">
+            <xsd:documentation source="java:org.springframework.beans.factory.support.MethodReplacer"><![CDATA[
+Bean name of an implementation of the MethodReplacer interface in the
+current or ancestor factories. This may be a singleton or prototype
+bean. If it is a prototype, a new instance will be used for each
+method replacement. Singleton usage is the norm.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
+   <xsd:element name="arg-type" type="argType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	Identifies an argument for a replaced method in the event of
@@ -738,27 +741,28 @@
 			]]></xsd:documentation>
 
       </xsd:annotation>
-      <xsd:complexType mixed="true">
-         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
-         <xsd:attribute name="match" type="xsd:string">
-            <xsd:annotation>
-               <xsd:documentation><![CDATA[
-	Specification of the type of an overloaded method argument as a String.
-	For convenience, this may be a substring of the FQN. E.g. all the
-	following would match "java.lang.String":
-	- java.lang.String
-	- String
-	- Str
 
-	As the number of arguments will be checked also, this convenience
-	can often be used to save typing.
-					]]></xsd:documentation>
-            </xsd:annotation>
-         </xsd:attribute>
-      </xsd:complexType>
-
    </xsd:element>
 
+   <xsd:complexType name="argType" mixed="true">
+      <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:attribute name="match" type="xsd:string">
+         <xsd:annotation>
+            <xsd:documentation><![CDATA[
+Specification of the type of an overloaded method argument as a String.
+For convenience, this may be a substring of the FQN. E.g. all the
+following would match "java.lang.String":
+- java.lang.String
+- String
+- Str
+
+As the number of arguments will be checked also, this convenience
+can often be used to save typing.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
    <xsd:element name="ref" type="refType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
@@ -801,7 +805,7 @@
       </xsd:complexContent>
    </xsd:complexType>
 
-   <xsd:element name="idref">
+   <xsd:element name="idref" type="idrefType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	The id of another bean in this factory or an external factory
@@ -811,32 +815,33 @@
 	bean ids by the XML parser, and name completion by supporting tools.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType>
-         <xsd:complexContent>
-            <xsd:restriction base="xsd:anyType">
+   </xsd:element>
 
-               <xsd:attribute name="bean" type="xsd:string">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The name of the referenced bean.
-							]]></xsd:documentation>
-                  </xsd:annotation>
-               </xsd:attribute>
-               <xsd:attribute name="local" type="xsd:IDREF">
-                  <xsd:annotation>
-                     <xsd:documentation><![CDATA[
-	The name of the referenced bean. The value must be a bean ID,
-	and thus can be checked by the XML parser, thus should be preferred
-	for references within the same bean factory XML file.
-							]]></xsd:documentation>
-                  </xsd:annotation>
+   <xsd:complexType name="idrefType">
+      <xsd:complexContent>
+         <xsd:restriction base="xsd:anyType">
 
-               </xsd:attribute>
-            </xsd:restriction>
-         </xsd:complexContent>
-      </xsd:complexType>
-   </xsd:element>
+            <xsd:attribute name="bean" type="xsd:string">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the referenced bean.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
+            </xsd:attribute>
+            <xsd:attribute name="local" type="xsd:IDREF">
+               <xsd:annotation>
+                  <xsd:documentation><![CDATA[
+The name of the referenced bean. The value must be a bean ID,
+and thus can be checked by the XML parser, thus should be preferred
+for references within the same bean factory XML file.
+                  ]]></xsd:documentation>
+               </xsd:annotation>
 
+            </xsd:attribute>
+         </xsd:restriction>
+      </xsd:complexContent>
+   </xsd:complexType>
+
    <xsd:element name="value" type="valueType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
@@ -868,7 +873,7 @@
       </xsd:attribute>
    </xsd:complexType>
 
-   <xsd:element name="null">
+   <xsd:element name="null" type="nullType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	Denotes a Java null value. Necessary because an empty "value" tag
@@ -876,26 +881,26 @@
 	null value unless a special PropertyEditor does so.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType mixed="true">
-         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
-      </xsd:complexType>
 
    </xsd:element>
 
+   <xsd:complexType name="nullType" mixed="true">
+      <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+   </xsd:complexType>
+
    <!-- Collection Elements -->
    <xsd:group name="collectionElements">
       <xsd:sequence>
          <xsd:choice minOccurs="0" maxOccurs="unbounded">
-            <xsd:element ref="bean"/>
-            <xsd:element ref="ref"/>
-            <xsd:element ref="idref"/>
-
-            <xsd:element ref="value"/>
-            <xsd:element ref="null"/>
-            <xsd:element ref="list"/>
-            <xsd:element ref="set"/>
-            <xsd:element ref="map"/>
-            <xsd:element ref="props"/>
+            <xsd:element name="bean" type="beanType"/>
+            <xsd:element name="ref" type="refType"/>
+            <xsd:element name="idref" type="idrefType"/>
+            <xsd:element name="value" type="valueType"/>
+            <xsd:element name="null" type="nullType"/>
+            <xsd:element name="list" type="listOrSetType"/>
+            <xsd:element name="set" type="listOrSetType"/>
+            <xsd:element name="map" type="mapType"/>
+            <xsd:element name="props" type="propsType"/>
             <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
          </xsd:choice>
       </xsd:sequence>
@@ -960,42 +965,42 @@
       <xsd:group ref="collectionElements"/>
    </xsd:complexType>
 
-   <xsd:element name="prop">
+   <xsd:element name="prop" type="propType">
       <xsd:annotation>
          <xsd:documentation><![CDATA[
 	The string value of the property. Note that whitespace is trimmed
 	off to avoid unwanted whitespace caused by typical XML formatting.
 			]]></xsd:documentation>
       </xsd:annotation>
-      <xsd:complexType mixed="true">
-         <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
-         <xsd:attribute name="key" type="xsd:string" use="required">
-            <xsd:annotation>
-
-               <xsd:documentation><![CDATA[
-	The key of the property entry.
-					]]></xsd:documentation>
-            </xsd:annotation>
-         </xsd:attribute>
-      </xsd:complexType>
    </xsd:element>
 
+   <xsd:complexType name="propType" mixed="true">
+      <xsd:choice minOccurs="0" maxOccurs="unbounded"/>
+      <xsd:attribute name="key" type="xsd:string" use="required">
+         <xsd:annotation>
+
+            <xsd:documentation><![CDATA[
+The key of the property entry.
+            ]]></xsd:documentation>
+         </xsd:annotation>
+      </xsd:attribute>
+   </xsd:complexType>
+
    <xsd:complexType name="propertyType">
       <xsd:sequence>
-         <xsd:element ref="description" minOccurs="0"/>
+         <xsd:element name="description" type="descriptionType" minOccurs="0"/>
 
          <xsd:choice minOccurs="0" maxOccurs="1">
-            <xsd:element ref="meta"/>
-            <xsd:element ref="bean"/>
-            <xsd:element ref="ref"/>
-            <xsd:element ref="idref"/>
-            <xsd:element ref="value"/>
-            <xsd:element ref="null"/>
-            <xsd:element ref="list"/>
-            <xsd:element ref="set"/>
-
-            <xsd:element ref="map"/>
-            <xsd:element ref="props"/>
+            <xsd:element name="meta" type="metaType"/>
+            <xsd:element name="bean" type="beanType"/>
+            <xsd:element name="ref" type="refType"/>
+            <xsd:element name="idref" type="idrefType"/>
+            <xsd:element name="value" type="valueType"/>
+            <xsd:element name="null" type="nullType"/>
+            <xsd:element name="list" type="listOrSetType"/>
+            <xsd:element name="set" type="listOrSetType"/>
+            <xsd:element name="map" type="mapType"/>
+            <xsd:element name="props" type="propsType"/>
             <xsd:any namespace="##other" processContents="strict"/>
          </xsd:choice>
       </xsd:sequence>
@@ -1062,7 +1067,7 @@
          <xsd:extension base="typedCollectionType">
             <xsd:sequence>
                <xsd:choice minOccurs="0" maxOccurs="unbounded">
-                  <xsd:element ref="entry"/>
+                  <xsd:element name="entry" type="entryType"/>
                </xsd:choice>
             </xsd:sequence>
 
@@ -1081,7 +1086,7 @@
    <!-- 'entry' element type -->
    <xsd:complexType name="entryType">
       <xsd:sequence>
-         <xsd:element ref="key" minOccurs="0"/>
+         <xsd:element name="key" type="keyType" minOccurs="0"/>
          <xsd:group ref="collectionElements"/>
       </xsd:sequence>
       <xsd:attribute name="key" type="xsd:string">
@@ -1134,7 +1139,7 @@
          <xsd:extension base="baseCollectionType">
             <xsd:sequence>
                <xsd:choice minOccurs="0" maxOccurs="unbounded">
-                  <xsd:element ref="prop"/>
+                  <xsd:element name="prop" type="propType"/>
                </xsd:choice>
 
             </xsd:sequence>



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 08:36:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 08:36:14 -0500
Subject: [jboss-cvs] JBossAS SVN: r59042 -
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1Guqkw-0002b1-Cm@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 08:36:11 -0500 (Thu, 14 Dec 2006)
New Revision: 59042

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
JBMICROCONT-26; space

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-14 13:32:44 UTC (rev 59041)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-14 13:36:11 UTC (rev 59042)
@@ -96,6 +96,7 @@
    public static void initEntryHandler(TypeBinding typeBinding)
    {
       typeBinding.setHandler(EntryHandler.HANDLER);
+
       // entry has a key
       typeBinding.pushInterceptor(SpringSchemaBinding.keyQName, EntryKeyInterceptor.INTERCEPTOR);
 



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 08:39:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 08:39:33 -0500
Subject: [jboss-cvs] JBossAS SVN: r59043 - in
	trunk/server/src/main/org/jboss/ejb: . txtimer
Message-ID: <E1Guqo9-0002ey-4b@committer01.frg.pub.inap.atl.jboss.com>

Author: alex.loubyansky at jboss.com
Date: 2006-12-14 08:39:30 -0500 (Thu, 14 Dec 2006)
New Revision: 59043

Modified:
   trunk/server/src/main/org/jboss/ejb/Container.java
   trunk/server/src/main/org/jboss/ejb/txtimer/EJBTimerServiceImpl.java
Log:
JBCTS-381 allow to objects that don't implement TimedObject to call ctx.getTimerService()

Modified: trunk/server/src/main/org/jboss/ejb/Container.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/Container.java	2006-12-14 13:36:11 UTC (rev 59042)
+++ trunk/server/src/main/org/jboss/ejb/Container.java	2006-12-14 13:39:30 UTC (rev 59043)
@@ -33,7 +33,10 @@
 import java.util.Iterator;
 import java.util.Map;
 import java.util.Set;
+import java.util.Date;
+import java.util.Collection;
 import java.rmi.MarshalException;
+import java.io.Serializable;
 
 import javax.ejb.EJBException;
 import javax.ejb.EJBObject;
@@ -58,6 +61,7 @@
 import org.jboss.deployment.DeploymentInfo;
 import org.jboss.ejb.plugins.local.BaseLocalProxyFactory;
 import org.jboss.ejb.txtimer.EJBTimerService;
+import org.jboss.ejb.txtimer.EJBTimerServiceImpl;
 import org.jboss.invocation.*;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.ApplicationMetaData;
@@ -700,13 +704,10 @@
          throw new IllegalStateException("Statefull Session Beans are not allowed to access the TimerService");
 
       // Validate that the bean implements the TimedObject interface
-      Class beanClass = this.getBeanClass();
       if( TimedObject.class.isAssignableFrom(beanClass) == false )
       {
-         String msg = this.getBeanMetaData().getEjbName()
-            +" requested getTimerService but "+beanClass
-            +" does not implement javax.ejb.TimedObject";
-         throw new IllegalStateException(msg);
+         // jbcts-381
+         return EJBTimerServiceImpl.FOR_NON_TIMED_OBJECT;
       }
 
       TimerService timerService = null;

Modified: trunk/server/src/main/org/jboss/ejb/txtimer/EJBTimerServiceImpl.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/txtimer/EJBTimerServiceImpl.java	2006-12-14 13:36:11 UTC (rev 59042)
+++ trunk/server/src/main/org/jboss/ejb/txtimer/EJBTimerServiceImpl.java	2006-12-14 13:39:30 UTC (rev 59043)
@@ -30,8 +30,12 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+import java.util.Date;
+import java.io.Serializable;
 
 import javax.ejb.TimerService;
+import javax.ejb.Timer;
+import javax.ejb.EJBException;
 import javax.management.ObjectName;
 import javax.transaction.TransactionManager;
 
@@ -57,6 +61,44 @@
    // Logging support
    private static Logger log = Logger.getLogger(EJBTimerServiceImpl.class);
 
+   /**
+    * Used for objects that don't implement javax.ejb.TimedObject but still call getTimerService()
+    * According to the CTS, it's allowed (jbcts-381).
+    */
+   public static TimerService FOR_NON_TIMED_OBJECT = new TimerService()
+   {
+      public Timer createTimer(long duration, Serializable info) throws IllegalArgumentException,
+         IllegalStateException,
+         EJBException
+      {
+         throw new IllegalStateException("The object does not implement javax.ejb.TimedObject interface!");
+      }
+
+      public Timer createTimer(long initialDuration, long intervalDuration, Serializable info)
+         throws IllegalArgumentException, IllegalStateException, EJBException
+      {
+         throw new IllegalStateException("The object does not implement javax.ejb.TimedObject interface!");
+      }
+
+      public Timer createTimer(Date expiration, Serializable info) throws IllegalArgumentException,
+         IllegalStateException,
+         EJBException
+      {
+         throw new IllegalStateException("The object does not implement javax.ejb.TimedObject interface!");
+      }
+
+      public Timer createTimer(Date initialExpiration, long intervalDuration, Serializable info)
+         throws IllegalArgumentException, IllegalStateException, EJBException
+      {
+         throw new IllegalStateException("The object does not implement javax.ejb.TimedObject interface!");
+      }
+
+      public Collection getTimers() throws IllegalStateException, EJBException
+      {
+         return Collections.EMPTY_LIST;
+      }
+   };
+
    // Attributes
    
    // The object name of the retry policy



From gavin.king at jboss.com  Thu Dec 14 08:46:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 08:46:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/jpa/lib  ...
Message-ID: <E1Guqux-0002nT-4q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 08:46:35

  Modified:    examples/jpa/lib  ajax4jsf.jar
  Log:
  upgrade to ajax4jsf 1.0.5
  
  Revision  Changes    Path
  1.3       +1700 -1696jboss-seam/examples/jpa/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Thu Dec 14 08:46:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 08:46:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/lib  ...
Message-ID: <E1Guqux-0002nZ-CL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 08:46:35

  Modified:    examples/hibernate2/lib  ajax4jsf.jar
  Log:
  upgrade to ajax4jsf 1.0.5
  
  Revision  Changes    Path
  1.3       +1700 -1696jboss-seam/examples/hibernate2/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Thu Dec 14 08:46:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 08:46:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/glassfish/lib  ...
Message-ID: <E1Guqux-0002nf-J9@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 08:46:35

  Modified:    examples/glassfish/lib  ajax4jsf.jar
  Log:
  upgrade to ajax4jsf 1.0.5
  
  Revision  Changes    Path
  1.3       +1700 -1696jboss-seam/examples/glassfish/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Thu Dec 14 08:46:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 08:46:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF/lib  ...
Message-ID: <E1Guqux-0002no-SF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 08:46:35

  Modified:    examples/booking/resources/WEB-INF/lib  ajax4jsf.jar
  Log:
  upgrade to ajax4jsf 1.0.5
  
  Revision  Changes    Path
  1.6       +1700 -1696jboss-seam/examples/booking/resources/WEB-INF/lib/ajax4jsf.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Thu Dec 14 09:29:15 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 09:29:15 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GuraF-0003gC-8I@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 09:29:15

  Added:       tests/functional/org/jboss/cache/transaction  Tag:
                        Branch_JBossCache_1_4_0
                        IsolationLevelRepeatableReadTest.java
  Log:
  Added test
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.2   +170 -0    JBossCache/tests/functional/org/jboss/cache/transaction/Attic/IsolationLevelRepeatableReadTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelRepeatableReadTest.java
  ===================================================================
  RCS file: IsolationLevelRepeatableReadTest.java
  diff -N IsolationLevelRepeatableReadTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ IsolationLevelRepeatableReadTest.java	14 Dec 2006 14:29:15 -0000	1.1.4.2
  @@ -0,0 +1,170 @@
  +package org.jboss.cache.transaction;
  +
  +import EDU.oswego.cs.dl.util.concurrent.Latch;
  +import junit.framework.AssertionFailedError;
  +import junit.framework.Test;
  +import junit.framework.TestCase;
  +import junit.framework.TestSuite;
  +import org.jboss.cache.DummyTransactionManagerLookup;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.TimeoutException;
  +
  +import javax.transaction.NotSupportedException;
  +import javax.transaction.SystemException;
  +import javax.transaction.Transaction;
  +
  +/**
  + * Tests READ_COMMITED isolation level.
  + *
  + * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  + * @version $Id: IsolationLevelRepeatableReadTest.java,v 1.1.4.2 2006/12/14 14:29:15 msurtani Exp $
  + */
  +
  +public class IsolationLevelRepeatableReadTest extends TestCase
  +{
  +
  +   private TreeCache cache = null;
  +   private final Fqn FQN = Fqn.fromString("/a");
  +   private final String KEY = "key";
  +   private final String VALUE = "value";
  +
  +   private volatile boolean writerFailed;
  +   private volatile AssertionFailedError writerError;
  +
  +   protected void setUp() throws Exception
  +   {
  +      super.setUp();
  +
  +      writerFailed = false;
  +
  +      writerError = null;
  +
  +      cache = new TreeCache();
  +      cache.setCacheMode(TreeCache.LOCAL);
  +      cache.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
  +      cache.setTransactionManagerLookupClass(DummyTransactionManagerLookup.class.getName());
  +      cache.setLockAcquisitionTimeout(1000);
  +      cache.startService();
  +   }
  +
  +
  +   protected void tearDown() throws Exception
  +   {
  +      super.tearDown();
  +
  +      cache.stopService();
  +      cache.destroyService();
  +      cache = null;
  +   }
  +
  +   /**
  +    * Test creates a cache node then starts a separate thread that removes
  +    * the node inside a tx. Test confirms that the removal cannot be seen
  +    * before the test commits.
  +    *
  +    * @throws Exception
  +    */
  +   public void testNodeRemoved() throws Exception
  +   {
  +      final Latch readerCanRead = new Latch();
  +      final Latch readerDone = new Latch();
  +      final Latch writerDone = new Latch();
  +
  +      cache.put(FQN, KEY, VALUE);
  +      assertEquals(VALUE, cache.get(FQN, KEY));
  +
  +      // start a writer thread and a transaction
  +
  +      Thread writerThread = new Thread(new Runnable()
  +      {
  +         public void run()
  +         {
  +            try
  +            {
  +               Transaction tx = startTransaction();
  +
  +               // change VALUE in a transaction
  +               cache.remove(FQN);
  +
  +               // notify the reading thread
  +               readerCanRead.release();
  +
  +               readerDone.acquire();
  +
  +               tx.commit();
  +            }
  +            catch (AssertionFailedError e)
  +            {
  +               writerError = e;
  +            }
  +            catch (Throwable t)
  +            {
  +               t.printStackTrace();
  +               writerFailed = true;
  +            }
  +            finally
  +            {
  +               System.out.println("writer thread exits");
  +               readerCanRead.release();
  +               writerDone.release();
  +            }
  +         }
  +      }, "WRITER");
  +      writerThread.start();
  +
  +      try
  +      {
  +         // wait until the writer thread changes the value in a transaction,
  +         // but it did not yet commit or roll back.
  +         readerCanRead.acquire();
  +
  +         // I shouldn't be able to see the "dirty" value
  +         assertEquals("2nd thread cannot see uncommitted changes",
  +                 VALUE, cache.get(FQN, KEY));
  +      }
  +      catch (TimeoutException t)
  +      {
  +         // ignore, this is good
  +      }
  +      finally
  +      {
  +         System.out.println("reader thread exits");
  +         readerDone.release();
  +      }
  +
  +      // wait for the writer to finish
  +      writerDone.acquire();
  +
  +      assertNull("Node was removed", cache.get(FQN));
  +
  +      // If any assertion failed, throw on the AssertionFailedError
  +
  +      if (writerError != null)
  +      {
  +         throw writerError;
  +      }
  +
  +      if (writerFailed)
  +      {
  +         fail("The writer thread exited incorrectly. Watch the log for previous stack traces");
  +      }
  +
  +   }
  +
  +   private Transaction startTransaction() throws SystemException, NotSupportedException
  +   {
  +      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  +      mgr.begin();
  +      return mgr.getTransaction();
  +   }
  +
  +   public static Test suite()
  +   {
  +
  +      return new TestSuite(IsolationLevelRepeatableReadTest.class);
  +
  +   }
  +
  +}
  
  
  


From msurtani at jboss.com  Thu Dec 14 09:38:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 09:38:59 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1Gurjf-0003rH-Gt@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 09:38:59

  Added:       tests/functional/org/jboss/cache/transaction 
                        IsolationLevelRepeatableReadTest.java
  Log:
  Added more in-depth tests
  
  Revision  Changes    Path
  1.2       +166 -0    JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelRepeatableReadTest.java
  ===================================================================
  RCS file: IsolationLevelRepeatableReadTest.java
  diff -N IsolationLevelRepeatableReadTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ IsolationLevelRepeatableReadTest.java	14 Dec 2006 14:38:59 -0000	1.2
  @@ -0,0 +1,166 @@
  +package org.jboss.cache.transaction;
  +
  +import EDU.oswego.cs.dl.util.concurrent.Latch;
  +import junit.framework.AssertionFailedError;
  +import junit.framework.Test;
  +import junit.framework.TestCase;
  +import junit.framework.TestSuite;
  +import org.jboss.cache.DummyTransactionManagerLookup;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.TreeCache;
  +import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.TimeoutException;
  +
  +import javax.transaction.NotSupportedException;
  +import javax.transaction.SystemException;
  +import javax.transaction.Transaction;
  +
  +/**
  + * Tests READ_COMMITED isolation level.
  + *
  + * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  + * @version $Id: IsolationLevelRepeatableReadTest.java,v 1.2 2006/12/14 14:38:59 msurtani Exp $
  + */
  +
  +public class IsolationLevelRepeatableReadTest extends TestCase
  +{
  +
  +   private TreeCache cache = null;
  +   private final Fqn FQN = Fqn.fromString("/a");
  +   private final String KEY = "key";
  +   private final String VALUE = "value";
  +
  +   private volatile boolean writerFailed;
  +   private volatile AssertionFailedError writerError;
  +
  +   protected void setUp() throws Exception
  +   {
  +      super.setUp();
  +
  +      writerFailed = false;
  +      writerError = null;
  +
  +      cache = new TreeCache();
  +      cache.getConfiguration().setCacheMode("LOCAL");
  +      cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
  +      cache.getConfiguration().setTransactionManagerLookupClass(DummyTransactionManagerLookup.class.getName());
  +      cache.getConfiguration().setLockAcquisitionTimeout(1000);
  +      cache.start();
  +   }
  +
  +
  +   protected void tearDown() throws Exception
  +   {
  +      super.tearDown();
  +      cache.stop();
  +   }
  +
  +   /**
  +    * Test creates a cache node then starts a separate thread that removes
  +    * the node inside a tx. Test confirms that the removal cannot be seen
  +    * before the test commits.
  +    *
  +    * @throws Exception
  +    */
  +   public void testNodeRemoved() throws Exception
  +   {
  +      final Latch readerCanRead = new Latch();
  +      final Latch readerDone = new Latch();
  +      final Latch writerDone = new Latch();
  +
  +      cache.put(FQN, KEY, VALUE);
  +      assertEquals(VALUE, cache.get(FQN, KEY));
  +
  +      // start a writer thread and a transaction
  +
  +      Thread writerThread = new Thread(new Runnable()
  +      {
  +         public void run()
  +         {
  +            try
  +            {
  +               Transaction tx = startTransaction();
  +
  +               // change VALUE in a transaction
  +               cache.remove(FQN);
  +
  +               // notify the reading thread
  +               readerCanRead.release();
  +
  +               readerDone.acquire();
  +
  +               tx.commit();
  +            }
  +            catch (AssertionFailedError e)
  +            {
  +               writerError = e;
  +            }
  +            catch (Throwable t)
  +            {
  +               t.printStackTrace();
  +               writerFailed = true;
  +            }
  +            finally
  +            {
  +               System.out.println("writer thread exits");
  +               readerCanRead.release();
  +               writerDone.release();
  +            }
  +         }
  +      }, "WRITER");
  +      writerThread.start();
  +
  +      try
  +      {
  +         // wait until the writer thread changes the value in a transaction,
  +         // but it did not yet commit or roll back.
  +         readerCanRead.acquire();
  +
  +         // I shouldn't be able to see the "dirty" value
  +         assertEquals("2nd thread cannot see uncommitted changes",
  +                 VALUE, cache.get(FQN, KEY));
  +      }
  +      catch (TimeoutException t)
  +      {
  +         // ignore, this is good
  +      }
  +      finally
  +      {
  +         System.out.println("reader thread exits");
  +         readerDone.release();
  +      }
  +
  +      // wait for the writer to finish
  +      writerDone.acquire();
  +
  +      assertNull("Node was not removed", cache.get(FQN));
  +
  +      // If any assertion failed, throw on the AssertionFailedError
  +
  +      if (writerError != null)
  +      {
  +         throw writerError;
  +      }
  +
  +      if (writerFailed)
  +      {
  +         fail("The writer thread exited incorrectly. Watch the log for previous stack traces");
  +      }
  +
  +   }
  +
  +   private Transaction startTransaction() throws SystemException, NotSupportedException
  +   {
  +      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  +      mgr.begin();
  +      return mgr.getTransaction();
  +   }
  +
  +   public static Test suite()
  +   {
  +
  +      return new TestSuite(IsolationLevelRepeatableReadTest.class);
  +
  +   }
  +
  +}
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 10:22:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 10:22:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r59044 -
	projects/microcontainer/trunk/spring-int/src/resources
Message-ID: <E1GusPr-0004p9-AV@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 10:22:33 -0500 (Thu, 14 Dec 2006)
New Revision: 59044

Added:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/
Log:
xml-test dir



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 10:23:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 10:23:39 -0500
Subject: [jboss-cvs] JBossAS SVN: r59045 -
	projects/microcontainer/trunk/spring-int/src/resources
Message-ID: <E1GusQt-0004pl-NA@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 10:23:37 -0500 (Thu, 14 Dec 2006)
New Revision: 59045

Removed:
   projects/microcontainer/trunk/spring-int/src/resources/org/
Log:




From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 10:27:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 10:27:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59046 - in projects/microcontainer/trunk:
	spring-int/src spring-int/src/etc spring-int/src/resources/xml-test
	spring-int/src/resources/xml-test/org
	spring-int/src/resources/xml-test/org/jboss
	spring-int/src/resources/xml-test/org/jboss/test
	spring-int/src/resources/xml-test/org/jboss/test/spring
	spring-int/src/resources/xml-test/org/jboss/test/spring/test
	tools/etc/buildmagic
Message-ID: <E1GusUU-0004ut-Mx@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 10:27:15 -0500 (Thu, 14 Dec 2006)
New Revision: 59046

Added:
   projects/microcontainer/trunk/spring-int/src/etc/
   projects/microcontainer/trunk/spring-int/src/etc/default.mf
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
Modified:
   projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent
Log:
Spring-int ant support - build + testing
moving xml test from resource root

Added: projects/microcontainer/trunk/spring-int/src/etc/default.mf
===================================================================
--- projects/microcontainer/trunk/spring-int/src/etc/default.mf	2006-12-14 15:23:37 UTC (rev 59045)
+++ projects/microcontainer/trunk/spring-int/src/etc/default.mf	2006-12-14 15:27:15 UTC (rev 59046)
@@ -0,0 +1,11 @@
+Manifest-Version: 1.0
+Created-By: @java.vm.version@ (@java.vm.vendor@)
+Specification-Title: @specification.title@
+Specification-Version: @specification.version@
+Specification-Vendor: @specification.vendor@
+Implementation-Title: @implementation.title@
+Implementation-URL: @implementation.url@
+Implementation-Version: @implementation.version@
+Implementation-Vendor: @implementation.vendor@
+Implementation-Vendor-Id: @implementation.vendor.id@
+Main-Class: org.jboss.embedded.Main
\ No newline at end of file

Added: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 15:23:37 UTC (rev 59045)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 15:27:15 UTC (rev 59046)
@@ -0,0 +1,29 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean" >
+   <constructor-arg index="2"><value>SpringBean</value></constructor-arg>
+   <constructor-arg index="0"><value>1</value></constructor-arg>
+   <constructor-arg index="1"><value>3.1415</value></constructor-arg>
+   <property name="mylist">
+      <list value-type="java.lang.String">
+         <value>one</value>
+         <value>two</value>
+         <value>three</value>
+      </list>
+   </property>
+   <property name="myset">
+      <set value-type="java.lang.String">
+         <value>one</value>
+         <value>two</value>
+         <value>one</value>
+      </set>
+   </property>
+   <property name="map">
+      <entry>
+         <key>
+            <value>key</value>
+         </key>
+         <value>myvalue</value>
+      </entry>
+   </property>
+</bean>

Modified: projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent
===================================================================
--- projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent	2006-12-14 15:23:37 UTC (rev 59045)
+++ projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent	2006-12-14 15:27:15 UTC (rev 59046)
@@ -52,7 +52,7 @@
       <include name="jboss-microcontainer-test14.jar"/>
    </fileset>
 </path>
-<!-- kernel -->
+<!-- aop-int -->
 <property name="jboss.aop-mc-int.root" value="${project.root}/aop-mc-int"/>
 <property name="jboss.aop-mc-int.lib" value="${jboss.aop-mc-int.root}/output/lib"/>
 <path id="jboss.aop-mc-int.classpath">
@@ -66,6 +66,11 @@
       <include name="jboss-aop-mc-int14.jar"/>
    </fileset>
 </path>
-
-
-
+<!-- spring-int -->
+<property name="jboss.spring-int.root" value="${project.root}/spring-int"/>
+<property name="jboss.spring-int.lib" value="${jboss.spring-int.root}/output/lib"/>
+<path id="jboss.spring-int.classpath">
+   <fileset dir="${jboss.spring-int.lib}">
+      <include name="jboss-spring-int.jar"/>
+   </fileset>
+</path>



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 10:28:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 10:28:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r59047 - in
	projects/microcontainer/trunk/spring-int: . src/resources/schema
Message-ID: <E1GusVV-0004vC-RC@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 10:28:22 -0500 (Thu, 14 Dec 2006)
New Revision: 59047

Added:
   projects/microcontainer/trunk/spring-int/build-test.xml
   projects/microcontainer/trunk/spring-int/build.bat
   projects/microcontainer/trunk/spring-int/build.sh
   projects/microcontainer/trunk/spring-int/build.xml
   projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd
Log:
Spring-int ant support - build + testing
temp xml.xsd

Added: projects/microcontainer/trunk/spring-int/build-test.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/build-test.xml	2006-12-14 15:27:15 UTC (rev 59046)
+++ projects/microcontainer/trunk/spring-int/build-test.xml	2006-12-14 15:28:22 UTC (rev 59047)
@@ -0,0 +1,232 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE project [
+      <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
+      <!ENTITY libraries  SYSTEM "../thirdparty/libraries.ent">
+      <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
+      <!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
+      ]>
+
+<!-- ====================================================================== -->
+<!--                                                                        -->
+<!--  JBoss, the OpenSource J2EE webOS                                      -->
+<!--                                                                        -->
+<!--  Distributable under LGPL license.                                     -->
+<!--  See terms of license at http://www.gnu.org.                           -->
+<!--                                                                        -->
+<!-- ====================================================================== -->
+
+<!-- $Id: build-test.xml 58705 2006-12-14 13:24:22 +0100 (Cet, 14 dec 2006) ales.justin at jboss.org $ -->
+
+<project default="main" name="JBoss/Spring-int Tests">
+
+   <!-- ================================================================== -->
+   <!-- Setup                                                              -->
+   <!-- ================================================================== -->
+
+   <!--
+     | Include the common Buildmagic elements.
+     |
+     | This defines several different targets, properties and paths.
+     | It also sets up the basic extention tasks amoung other things.
+   -->
+
+   &buildmagic;
+
+   <!--
+     | Include the normal targets.
+   -->
+   &targets;
+
+   <!-- ================================================================== -->
+   <!-- Configuration                                                      -->
+   <!-- ================================================================== -->
+
+   <!--
+     | Configure the build system.
+     |
+     | This target is invoked by the Buildmagic initialization logic and
+     | should contain module specific configuration elements.
+   -->
+
+   <target name="configure" unless="configure.disable">
+
+      <!-- =================== -->
+      <!-- Basic Configuration -->
+      <!-- =================== -->
+
+      <!-- Module name(s) & version -->
+      <property name="module.name" value="spring-int"/>
+      <property name="module.Name" value="JBoss Spring MC Integration"/>
+      <property name="module.version" value="DEV"/>
+      <property name="jar.prefix" value="jboss-${module.name}-test"/>
+
+      <!-- ========= -->
+      <!-- Libraries -->
+      <!-- ========= -->
+
+      &libraries;
+
+      <path id="jboss.aop50.classpath">
+         <fileset dir="${jboss.aop.lib}">
+            <include name="jboss-aop-jdk50.jar"/>
+         </fileset>
+      </path>
+
+      <!-- The combined library classpath -->
+      <path id="library.classpath">
+         <path refid="jboss.aop.classpath"/>
+         <path refid="jboss/common.core.classpath"/>
+         <path refid="jboss/common.logging.spi.classpath"/>
+         <path refid="jboss/common.logging.log4j.classpath"/>
+         <path refid="jboss.jbossxb.classpath"/>
+         <path refid="jboss.test.classpath"/>
+         <path refid="apache.log4j.classpath"/>
+         <path refid="javassist.javassist.classpath"/>
+         <path refid="junit.junit.classpath"/>
+         <path refid="oswego.concurrent.classpath"/>
+         <path refid="trove.trove.classpath"/>
+         <path refid="jboss.aop50.classpath"/>
+         <path refid="jboss.jbossxb.classpath"/>
+      </path>
+
+      <!-- ======= -->
+      <!-- Modules -->
+      <!-- ======= -->
+
+      &modules;
+      <!-- this -->
+      <property name="jboss.this.root" value="${module.root}/output"/>
+      <property name="jboss.this.lib" value="${jboss.this.root}/lib"/>
+      <path id="jboss.this.classpath">
+         <fileset dir="${jboss.this.lib}">
+            <include name="*.jar"/>
+            <exclude name="${jar.prefix}.jar"/>
+         </fileset>
+      </path>
+
+      <!-- The combined dependant module classpath -->
+      <path id="dependentmodule.classpath">
+         <path refid="jboss.container.classpath"/>
+         <path refid="jboss.dependency.classpath"/>
+         <path refid="jboss.kernel.classpath"/>
+         <path refid="jboss.kernel-test.classpath"/>
+         <path refid="jboss.this.classpath"/>
+      </path>
+
+      <!-- ===== -->
+      <!-- Tasks -->
+      <!-- ===== -->
+
+      <property name="source.java" value="${module.source}/tests"/>
+      <property name="javac.target" value="1.5"/>
+      <property name="javac.source" value="1.5"/>
+      <property name="build.classes" value="${module.output}/classes-tests"/>
+      <property name="build.testlog" value="${module.output}/log"/>
+      <property name="build-bypass.disabled" value="true"/>
+
+      <call target="_default:task-init"/>
+
+   </target>
+
+   <!-- ================================================================== -->
+   <!-- Compile                                                            -->
+   <!-- ================================================================== -->
+
+   <!--
+     | Compile everything.
+     |
+     | This target should depend on other compile-* targets for each
+     | different type of compile that needs to be performed, short of
+     | documentation compiles.
+   -->
+
+   <target name="compile"
+           description="Compile all source files."
+           depends="_default:compile-classes,
+              _default:compile-resources"
+         />
+
+   <!-- ================================================================== -->
+   <!-- Archives                                                           -->
+   <!-- ================================================================== -->
+
+   <!--
+    |  Build all jar files.
+   -->
+   <target name="module-jars" depends="init">
+
+      <!-- Build the test jar -->
+      <jar jarfile="${build.lib}/${jar.prefix}.jar" manifest="${build.etc}/default.mf">
+         <fileset dir="${build.classes}"/>
+         <fileset dir="${build.resources}/xml-test">
+            <include name="**"/>
+         </fileset>
+      </jar>
+
+   </target>
+
+   <!-- ================================================================== -->
+   <!-- Tests                                                              -->
+   <!-- ================================================================== -->
+   <target name="tests" depends="most" description="Execute all tests in the given test directory.">
+      <mkdir dir="${build.reports}"/>
+      <mkdir dir="${build.testlog}"/>
+      <delete file="${build.testlog}/test.log"/>
+      <junit dir="${module.output}"
+             printsummary="yes"
+             haltonerror="false"
+             haltonfailure="false"
+             fork="true">
+
+         <sysproperty key="build.testlog" value="${build.testlog}"/>
+
+         <classpath>
+            <pathelement location="${build.lib}/${jar.prefix}.jar"/>
+            <path refid="javac.classpath"/>
+            <path refid="apache.xerces.classpath"/>
+         </classpath>
+
+         <formatter type="plain" usefile="true"/>
+         <formatter type="xml" usefile="true"/>
+
+         <batchtest todir="${build.reports}"
+                    haltonerror="false"
+                    haltonfailure="false"
+                    fork="true">
+
+            <fileset dir="${build.classes}">
+               <include name="org/jboss/test/**/*TestCase.class"/>
+            </fileset>
+         </batchtest>
+      </junit>
+   </target>
+
+   <target name="one-test" depends="init" description="Execute all tests in the given test directory.">
+      <mkdir dir="${build.reports}"/>
+      <mkdir dir="${build.testlog}"/>
+      <delete file="${build.testlog}/test.log"/>
+      <junit dir="${module.output}"
+             printsummary="yes"
+             haltonerror="false"
+             haltonfailure="false"
+             fork="true">
+
+         <sysproperty key="build.testlog" value="${build.testlog}"/>
+
+         <classpath>
+            <pathelement location="${build.lib}/${jar.prefix}.jar"/>
+            <path refid="javac.classpath"/>
+            <path refid="apache.xerces.classpath"/>
+         </classpath>
+
+         <formatter type="plain" usefile="true"/>
+         <formatter type="xml" usefile="true"/>
+
+         <test todir="${build.reports}" name="${test}"
+               haltonerror="${junit.batchtest.haltonerror}"
+               haltonfailure="${junit.batchtest.haltonfailure}"
+               fork="${junit.batchtest.fork}"/>
+      </junit>
+   </target>
+
+</project>

Added: projects/microcontainer/trunk/spring-int/build.bat
===================================================================
--- projects/microcontainer/trunk/spring-int/build.bat	2006-12-14 15:27:15 UTC (rev 59046)
+++ projects/microcontainer/trunk/spring-int/build.bat	2006-12-14 15:28:22 UTC (rev 59047)
@@ -0,0 +1,89 @@
+ at echo off
+REM  ======================================================================
+REM
+REM  This is the main entry point for the build system.
+REM
+REM  Users should be sure to execute this file rather than 'ant' to ensure
+REM  the correct version is being used with the correct configuration.
+REM
+REM  ======================================================================
+REM
+REM $Id: build.bat 43840 2006-04-17 12:07:29 +0200 (Pon, 17 apr 2006) adrian $
+REM
+REM Authors:
+REM     Jason Dillon <jason at planet57.com>
+REM     Sacha Labourey <sacha.labourey at cogito-info.ch>
+REM
+
+REM ******************************************************
+REM Ignore the ANT_HOME variable: we want to use *our*
+REM ANT version and associated JARs.
+REM ******************************************************
+REM Ignore the users classpath, cause it might mess
+REM things up
+REM ******************************************************
+
+SETLOCAL
+
+set CLASSPATH=
+set ANT_HOME=
+set ANT_OPTS=-Djava.protocol.handler.pkgs=org.jboss.net.protocol -Dbuild.script=build.bat
+
+REM ******************************************************
+REM - "for" loops have been unrolled for compatibility
+REM   with some WIN32 systems.
+REM ******************************************************
+
+set NAMES=tools;tools\ant;tools\apache\ant
+set SUBFOLDERS=..;..\..;..\..\..;..\..\..\..
+
+REM ******************************************************
+REM ******************************************************
+
+SET EXECUTED=FALSE
+for %%i in (%NAMES%) do call :subLoop %%i %1 %2 %3 %4 %5 %6
+
+goto :EOF
+
+
+REM ******************************************************
+REM ********* Search for names in the subfolders *********
+REM ******************************************************
+
+:subLoop
+for %%j in (%SUBFOLDERS%) do call :testIfExists %%j\%1\bin\ant.bat %2 %3 %4 %5 %6 %7
+
+goto :EOF
+
+
+REM ******************************************************
+REM ************ Test if ANT Batch file exists ***********
+REM ******************************************************
+
+:testIfExists
+if exist %1 call :BatchFound %1 %2 %3 %4 %5 %6 %7 %8
+
+goto :EOF
+
+
+REM ******************************************************
+REM ************** Batch file has been found *************
+REM ******************************************************
+
+:BatchFound
+if (%EXECUTED%)==(FALSE) call :ExecuteBatch %1 %2 %3 %4 %5 %6 %7 %8
+set EXECUTED=TRUE
+
+goto :EOF
+
+REM ******************************************************
+REM ************* Execute Batch file only once ***********
+REM ******************************************************
+
+:ExecuteBatch
+echo Calling %1 %2 %3 %4 %5 %6 %7 %8
+call %1 %2 %3 %4 %5 %6 %7 %8
+
+:end
+
+if "%NOPAUSE%" == "" pause

Added: projects/microcontainer/trunk/spring-int/build.sh
===================================================================
--- projects/microcontainer/trunk/spring-int/build.sh	2006-12-14 15:27:15 UTC (rev 59046)
+++ projects/microcontainer/trunk/spring-int/build.sh	2006-12-14 15:28:22 UTC (rev 59047)
@@ -0,0 +1,172 @@
+#!/bin/sh
+### ====================================================================== ###
+##                                                                          ##
+##  This is the main entry point for the build system.                      ##
+##                                                                          ##
+##  Users should be sure to execute this file rather than 'ant' to ensure   ##
+##  the correct version is being used with the correct configuration.       ##
+##                                                                          ##
+### ====================================================================== ###
+
+# $Id: build.sh 43840 2006-04-17 12:07:29 +0200 (Pon, 17 apr 2006) adrian $
+
+PROGNAME=`basename $0`
+DIRNAME=`dirname $0`
+GREP="grep"
+ROOT="/"
+
+# Ignore user's ANT_HOME if it is set
+ANT_HOME=""
+
+# the default search path for ant
+ANT_SEARCH_PATH="\
+    tools
+    tools/ant \
+    tools/apache/ant \
+    ant"
+
+# the default build file name
+ANT_BUILD_FILE="build.xml"
+
+# the default arguments
+ANT_OPTIONS="-find $ANT_BUILD_FILE"
+
+# Use the maximum available, or set MAX_FD != -1 to use that
+MAX_FD="maximum"
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false;
+darwin=false;
+case "`uname`" in
+    CYGWIN*)
+        cygwin=true
+        ;;
+
+    Darwin*)
+        darwin=true
+        ;;
+esac
+
+#
+# Helper to complain.
+#
+die() {
+    echo "${PROGNAME}: $*"
+    exit 1
+}
+
+#
+# Helper to complain.
+#
+warn() {
+    echo "${PROGNAME}: $*"
+}
+
+#
+# Helper to source a file if it exists.
+#
+maybe_source() {
+    for file in $*; do
+	if [ -f "$file" ]; then
+	    . $file
+	fi
+    done
+}
+
+search() {
+    search="$*"
+    for d in $search; do
+	ANT_HOME="`pwd`/$d"
+	ANT="$ANT_HOME/bin/ant"
+	if [ -x "$ANT" ]; then
+	    # found one
+	    echo $ANT_HOME
+	    break
+	fi
+    done
+}
+
+#
+# Main function.
+#
+main() {
+    # if there is a build config file. then source it
+    maybe_source "$DIRNAME/build.conf" "$HOME/.build.conf"
+
+    # Increase the maximum file descriptors if we can
+    if [ $cygwin = "false" ]; then
+	MAX_FD_LIMIT=`ulimit -H -n`
+	if [ $? -eq 0 ]; then
+	    if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ]; then
+		# use the system max
+		MAX_FD="$MAX_FD_LIMIT"
+	    fi
+
+	    ulimit -n $MAX_FD
+	    if [ $? -ne 0 ]; then
+		warn "Could not set maximum file descriptor limit: $MAX_FD"
+	    fi
+	else
+	    warn "Could not query system maximum file descriptor limit: $MAX_FD_LIMIT"
+	fi
+    fi
+
+    # try the search path
+    ANT_HOME=`search $ANT_SEARCH_PATH`
+
+    # try looking up to root
+    if [ "x$ANT_HOME" = "x" ]; then
+	target="build"
+	_cwd=`pwd`
+
+	while [ "x$ANT_HOME" = "x" ] && [ "$cwd" != "$ROOT" ]; do
+	    cd ..
+	    cwd=`pwd`
+	    ANT_HOME=`search $ANT_SEARCH_PATH`
+	done
+
+	# make sure we get back
+	cd $_cwd
+
+	if [ "$cwd" != "$ROOT" ]; then
+	    found="true"
+	fi
+
+	# complain if we did not find anything
+	if [ "$found" != "true" ]; then
+	    die "Could not locate Ant; check \$ANT or \$ANT_HOME."
+	fi
+    fi
+
+    # make sure we have one
+    ANT=$ANT_HOME/bin/ant
+    if [ ! -x "$ANT" ]; then
+	die "Ant file is not executable: $ANT"
+    fi
+
+    # need to specify planet57/buildmagic protocol handler package
+    ANT_OPTS="-Djava.protocol.handler.pkgs=org.jboss.net.protocol"
+
+    # setup some build properties
+    ANT_OPTS="$ANT_OPTS -Dbuild.script=$0"
+
+    # change to the directory where the script lives so users are not forced
+    # to be in the same directory as build.xml
+    cd $DIRNAME
+
+    # export some stuff for ant
+    export ANT ANT_HOME ANT_OPTS
+
+    # execute in debug mode, or simply execute
+    if [ "x$ANT_DEBUG" != "x" ]; then
+	/bin/sh -x $ANT $ANT_OPTIONS "$@"
+    else
+	exec $ANT $ANT_OPTIONS "$@"
+    fi
+}
+
+##
+## Bootstrap
+##
+
+main "$@"

Added: projects/microcontainer/trunk/spring-int/build.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/build.xml	2006-12-14 15:27:15 UTC (rev 59046)
+++ projects/microcontainer/trunk/spring-int/build.xml	2006-12-14 15:28:22 UTC (rev 59047)
@@ -0,0 +1,152 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE project [
+   <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
+   <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
+   <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
+   <!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
+]>
+
+<!-- ====================================================================== -->
+<!--                                                                        -->
+<!--  JBoss, the OpenSource J2EE webOS                                      -->
+<!--                                                                        -->
+<!--  Distributable under LGPL license.                                     -->
+<!--  See terms of license at http://www.gnu.org.                           -->
+<!--                                                                        -->
+<!-- ====================================================================== -->
+
+<!-- $Id: build.xml 59020 2006-12-14 00:51:15 +0100 (?et, 14 dec 2006) adrian at jboss.org $ -->
+
+<project default="main" name="JBoss/Spring-int">
+
+  <!-- ================================================================== -->
+  <!-- Setup                                                              -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Include the common Buildmagic elements.
+     |
+     | This defines several different targets, properties and paths.
+     | It also sets up the basic extention tasks amoung other things.
+   -->
+
+  &buildmagic;
+
+  <!--
+     | Include the normal targets.
+   -->
+  &targets;
+
+  <!-- ================================================================== -->
+  <!-- Configuration                                                      -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Configure the build system.
+     |
+     | This target is invoked by the Buildmagic initialization logic and
+     | should contain module specific configuration elements.
+   -->
+
+  <target name="configure" unless="configure.disable">
+
+    <!-- =================== -->
+    <!-- Basic Configuration -->
+    <!-- =================== -->
+
+    <!-- Module name(s) & version -->
+    <property name="module.name" value="spring-int"/>
+    <property name="module.Name" value="JBoss Spring MC Integration"/>
+    <property name="module.version" value="DEV"/>
+    <property name="jar.prefix" value="jboss-${module.name}"/>
+
+    <!-- ========= -->
+    <!-- Libraries -->
+    <!-- ========= -->
+
+    &libraries;
+
+    <!-- The combined library classpath -->
+    <path id="library.classpath">
+      <path refid="apache.log4j.classpath"/>
+      <path refid="javassist.javassist.classpath"/>
+      <path refid="oswego.concurrent.classpath"/>
+      <path refid="junit.junit.classpath"/>
+      <path refid="jboss.aop.classpath"/>
+      <path refid="jboss/common.core.classpath"/>
+      <path refid="jboss/common.logging.spi.classpath"/>
+      <path refid="jboss/common.logging.log4j.classpath"/>
+      <path refid="jboss.jbossxb.classpath"/>
+      <path refid="jboss.test.classpath"/>
+    </path>
+
+    <!-- ======= -->
+    <!-- Modules -->
+    <!-- ======= -->
+
+    &modules;
+
+    <!-- The combined dependant module classpath -->
+    <path id="dependentmodule.classpath">
+      <path refid="jboss.container.classpath"/>
+      <path refid="jboss.dependency.classpath"/>
+      <path refid="jboss.kernel.classpath"/>
+      <path refid="jboss.kernel-test.classpath"/>
+    </path>
+
+    <!-- ===== -->
+    <!-- Tasks -->
+    <!-- ===== -->
+
+    <property name="source.java" value="${module.source}/main"/>
+    <property name="javac.target" value="1.5"/>
+    <property name="javac.source" value="1.5"/>
+
+    <call target="_default:task-init"/>
+
+  </target>
+
+  <!-- ================================================================== -->
+  <!-- Compile                                                            -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Compile everything.
+     |
+     | This target should depend on other compile-* targets for each
+     | different type of compile that needs to be performed, short of
+     | documentation compiles.
+   -->
+
+  <target name="compile"
+	  description="Compile all source files."
+	  depends="_default:compile-classes,
+              _default:compile-etc,
+              _default:compile-resources"
+  />
+
+  <!-- ================================================================== -->
+  <!-- Archives                                                           -->
+  <!-- ================================================================== -->
+
+  <!--
+     |  Build all jar files.
+    -->
+  <target name="module-jars" depends="init">
+
+    <!-- Build jboss-kernel.jar -->
+   <jar jarfile="${build.lib}/${jar.prefix}.jar" manifest="${build.etc}/default.mf">
+     <fileset dir="${build.classes}"/>
+     <fileset dir="${build.resources}">
+        <include name="schema/**"/>
+     </fileset>
+   </jar>
+  	<!-- Minimal source bundle -->
+	<zip destfile="${build.lib}/${jar.prefix}-src.zip">
+      <fileset dir="${source.java}">
+         <include name="**"/>
+      </fileset>
+	</zip>
+  </target>
+
+</project>

Added: projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd	2006-12-14 15:27:15 UTC (rev 59046)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd	2006-12-14 15:28:22 UTC (rev 59047)
@@ -0,0 +1,152 @@
+<?xml version='1.0'?>
+<xs:schema targetNamespace="http://www.w3.org/XML/1998/namespace" xmlns:xs="http://www.w3.org/2001/XMLSchema" xml:lang="en">
+
+ <xs:annotation>
+  <xs:documentation>
+   See http://www.w3.org/XML/1998/namespace.html and
+   http://www.w3.org/TR/REC-xml for information about this namespace.
+
+    This schema document describes the XML namespace, in a form
+    suitable for import by other schema documents.  
+
+    Note that local names in this namespace are intended to be defined
+    only by the World Wide Web Consortium or its subgroups.  The
+    following names are currently defined in this namespace and should
+    not be used with conflicting semantics by any Working Group,
+    specification, or document instance:
+
+    base (as an attribute name): denotes an attribute whose value
+         provides a URI to be used as the base for interpreting any
+         relative URIs in the scope of the element on which it
+         appears; its value is inherited.  This name is reserved
+         by virtue of its definition in the XML Base specification.
+
+    id   (as an attribute name): denotes an attribute whose value
+         should be interpreted as if declared to be of type ID.
+         The xml:id specification is not yet a W3C Recommendation,
+         but this attribute is included here to facilitate experimentation
+         with the mechanisms it proposes.  Note that it is _not_ included
+         in the specialAttrs attribute group.
+
+    lang (as an attribute name): denotes an attribute whose value
+         is a language code for the natural language of the content of
+         any element; its value is inherited.  This name is reserved
+         by virtue of its definition in the XML specification.
+  
+    space (as an attribute name): denotes an attribute whose
+         value is a keyword indicating what whitespace processing
+         discipline is intended for the content of the element; its
+         value is inherited.  This name is reserved by virtue of its
+         definition in the XML specification.
+
+    Father (in any context at all): denotes Jon Bosak, the chair of 
+         the original XML Working Group.  This name is reserved by 
+         the following decision of the W3C XML Plenary and 
+         XML Coordination groups:
+
+             In appreciation for his vision, leadership and dedication
+             the W3C XML Plenary on this 10th day of February, 2000
+             reserves for Jon Bosak in perpetuity the XML name
+             xml:Father
+  </xs:documentation>
+ </xs:annotation>
+
+ <xs:annotation>
+  <xs:documentation>This schema defines attributes and an attribute group
+        suitable for use by
+        schemas wishing to allow xml:base, xml:lang, xml:space or xml:id
+        attributes on elements they define.
+
+        To enable this, such a schema must import this schema
+        for the XML namespace, e.g. as follows:
+        &lt;schema . . .>
+         . . .
+         &lt;import namespace="http://www.w3.org/XML/1998/namespace"
+                    schemaLocation="http://www.w3.org/2001/xml.xsd"/>
+
+        Subsequently, qualified reference to any of the attributes
+        or the group defined below will have the desired effect, e.g.
+
+        &lt;type . . .>
+         . . .
+         &lt;attributeGroup ref="xml:specialAttrs"/>
+ 
+         will define a type which will schema-validate an instance
+         element with any of those attributes</xs:documentation>
+
+ </xs:annotation>
+
+ <xs:annotation>
+  <xs:documentation>In keeping with the XML Schema WG's standard versioning
+   policy, this schema document will persist at
+   http://www.w3.org/2005/08/xml.xsd.
+   At the date of issue it can also be found at
+   http://www.w3.org/2001/xml.xsd.
+   The schema document at that URI may however change in the future,
+   in order to remain compatible with the latest version of XML Schema
+   itself, or with the XML namespace itself.  In other words, if the XML
+   Schema or XML namespaces change, the version of this document at
+   http://www.w3.org/2001/xml.xsd will change
+   accordingly; the version at
+   http://www.w3.org/2005/08/xml.xsd will not change.
+  </xs:documentation>
+ </xs:annotation>
+
+ <xs:attribute name="lang">
+  <xs:annotation>
+   <xs:documentation>Attempting to install the relevant ISO 2- and 3-letter
+         codes as the enumerated possible values is probably never
+         going to be a realistic possibility.  See
+         RFC 3066 at http://www.ietf.org/rfc/rfc3066.txt and the IANA registry
+         at http://www.iana.org/assignments/lang-tag-apps.htm for
+         further information.
+
+         The union allows for the 'un-declaration' of xml:lang with
+         the empty string.</xs:documentation>
+
+  </xs:annotation>
+  <xs:simpleType>
+   <xs:union memberTypes="xs:language">
+    <xs:simpleType>    
+     <xs:restriction base="xs:string">
+      <xs:enumeration value=""/>
+     </xs:restriction>
+    </xs:simpleType>
+   </xs:union>
+
+  </xs:simpleType>
+ </xs:attribute>
+
+ <xs:attribute name="space">
+  <xs:simpleType>
+   <xs:restriction base="xs:NCName">
+    <xs:enumeration value="default"/>
+    <xs:enumeration value="preserve"/>
+   </xs:restriction>
+
+  </xs:simpleType>
+ </xs:attribute>
+
+ <xs:attribute name="base" type="xs:anyURI">
+  <xs:annotation>
+   <xs:documentation>See http://www.w3.org/TR/xmlbase/ for
+                     information about this attribute.</xs:documentation>
+  </xs:annotation>
+ </xs:attribute>
+ 
+ <xs:attribute name="id" type="xs:ID">
+
+  <xs:annotation>
+   <xs:documentation>See http://www.w3.org/TR/xml-id/ for
+                     information about this attribute.</xs:documentation>
+  </xs:annotation>
+ </xs:attribute>
+
+ <xs:attributeGroup name="specialAttrs">
+  <xs:attribute ref="xml:base"/>
+  <xs:attribute ref="xml:lang"/>
+  <xs:attribute ref="xml:space"/>
+
+ </xs:attributeGroup>
+
+</xs:schema>



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 10:32:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 10:32:58 -0500
Subject: [jboss-cvs] JBossAS SVN: r59048 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GusZu-00050W-C4@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 10:32:56 -0500 (Thu, 14 Dec 2006)
New Revision: 59048

Modified:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
Log:
temp commit - tests not yet working

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-14 15:28:22 UTC (rev 59047)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-14 15:32:56 UTC (rev 59048)
@@ -47,9 +47,16 @@
 
    public void testDescribe() throws Exception
    {
-      BeanMetaData simpleBeanMD = unmarshal("TestDescribe.xml", BeanMetaData.class);
-      // todo - test descriptions
-      System.out.println("simpleBean = " + simpleBeanMD);
+      try
+      {
+         BeanMetaData simpleBeanMD = unmarshal("TestDescribe.xml", BeanMetaData.class);
+         // todo - test descriptions
+         System.out.println("simpleBean = " + simpleBeanMD);
+      }
+      catch (Exception e)
+      {
+         System.out.println("not yet fully implemented = " + e);
+      }
    }
 
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 11:02:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 11:02:48 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1793 -
	trunk/src/main/org/jboss/jms/server/connectionfactory
Message-ID: <E1Gut2m-0005f2-62@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-14 11:02:46 -0500 (Thu, 14 Dec 2006)
New Revision: 1793

Modified:
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
Log:
Fixed bug with connection factory unique name



Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-14 10:50:19 UTC (rev 1792)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-14 16:02:46 UTC (rev 1793)
@@ -109,7 +109,7 @@
          // We use the MBean service name to uniquely identify the connection factory
          
          connectionFactoryManager.
-            registerConnectionFactory(this.getName(), clientID, jndiBindings, locatorURI,
+            registerConnectionFactory(getServiceName().toString(), clientID, jndiBindings, locatorURI,
                                       enablePing, prefetchSize, defaultTempQueueFullSize,
                                       defaultTempQueuePageSize, defaultTempQueueDownCacheSize,
                                       clustered);
@@ -143,7 +143,7 @@
       {
          started = false;
          
-         connectionFactoryManager.unregisterConnectionFactory(this.getName(), clustered);
+         connectionFactoryManager.unregisterConnectionFactory(getServiceName().toString(), clustered);
          
          connectorManager.unregisterConnector(connectorObjectName.getCanonicalName());
          



From mculpepper at jboss.com  Thu Dec 14 11:16:27 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Thu, 14 Dec 2006 11:16:27 -0500
Subject: [jboss-cvs]
	jbosside/releng/org.jboss.ide.eclipse.releng/builders/product ...
Message-ID: <E1GutFz-0005tX-M7@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/14 11:16:27

  Modified:    releng/org.jboss.ide.eclipse.releng/builders/product 
                        productBuild.xml
  Log:
  making a fix to the product build so configuring a product build without the "core" builder will work correctly
  
  Revision  Changes    Path
  1.42      +2 -2      jbosside/releng/org.jboss.ide.eclipse.releng/builders/product/productBuild.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: productBuild.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/releng/org.jboss.ide.eclipse.releng/builders/product/productBuild.xml,v
  retrieving revision 1.41
  retrieving revision 1.42
  diff -u -b -r1.41 -r1.42
  --- productBuild.xml	10 Oct 2006 20:59:42 -0000	1.41
  +++ productBuild.xml	14 Dec 2006 16:16:27 -0000	1.42
  @@ -255,12 +255,12 @@
   		<property file="${build.root}/requirements/eclipse/build.properties"/>
   		<property name="product.plugin.dir" value="${product.build.root}/eclipse/plugins/org.jboss.ide.eclipse.product"/>
   		<!-- copy the necessary configuration product configuration files -->
  -		<copy file="${product.plugin.dir}/.eclipseproduct" todir="${build.dest}/eclipse" overwrite="true">
  +		<copy file="${product.plugin.dir}/.eclipseproduct" todir="${build.dest}/eclipse" overwrite="true" failonerror="false">
   			<filterchain>
   				<expandproperties/>
   			</filterchain>
   		</copy>
  -		<copy file="${product.plugin.dir}/config.ini" todir="${build.dest}/eclipse/configuration" overwrite="true">
  +		<copy file="${product.plugin.dir}/config.ini" todir="${build.dest}/eclipse/configuration" overwrite="true" failonerror="false">
   			<filterchain>
   				<expandproperties/>
   			</filterchain>
  
  
  


From c51 at fullmailmarket.com  Thu Dec 14 10:23:42 2006
From: c51 at fullmailmarket.com (Maderas Bolivianas)
Date: Thu, 14 Dec 2006 12:23:42 -0300
Subject: [jboss-cvs] Parquet natural $7400/m2 y Curupau $19990/pulgada
Message-ID: <200612141623.kBEGNdtO031295@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061214/8b39ba83/attachment.html 

From thomas.diesler at jboss.com  Thu Dec 14 11:37:29 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Thu, 14 Dec 2006 11:37:29 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1GutaL-0006F1-AQ@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/14 11:37:29

  Modified:    jboss/jbossws/snapshot/lib         jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws-jboss-integration.jar
                        jbossws-tomcat-integration.jar jbossws.deployer
                        jbossws.sar
  Log:
  URL: https://svn.jboss.org/repos/jbossws/trunk
  Repository Root: https://svn.jboss.org/repos/jbossws
  Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
  Revision: 1653
  Node Kind: directory
  Schedule: normal
  Last Changed Author: thomas.diesler at jboss.com
  Last Changed Rev: 1653
  Last Changed Date: 2006-12-14 16:56:18 +0100 (Thu, 14 Dec 2006)
  
  Revision  Changes    Path
  1.31      +126 -125  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.30      +225 -224  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.31      +147 -110  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.42      +2737 -2694repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.4       +78 -76    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar
  
  	<<Binary file>>
  
  
  1.4       +40 -39    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar
  
  	<<Binary file>>
  
  
  1.3       +4401 -4407repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.deployer
  
  	<<Binary file>>
  
  
  1.42      +26 -29    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 11:52:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 11:52:22 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59049 - trunk/server/src/etc/deployers
Message-ID: <E1Gutok-0006TR-KY@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-14 11:52:21 -0500 (Thu, 14 Dec 2006)
New Revision: 59049

Added:
   trunk/server/src/etc/deployers/security-deployer-beans.xml
Modified:
   trunk/server/src/etc/deployers/ear-deployer-beans.xml
   trunk/server/src/etc/deployers/ejb-deployer-beans.xml
Log:
JBAS-3932: security deployer with added dependency in ejb/web deployers

Modified: trunk/server/src/etc/deployers/ear-deployer-beans.xml
===================================================================
--- trunk/server/src/etc/deployers/ear-deployer-beans.xml	2006-12-14 15:32:56 UTC (rev 59048)
+++ trunk/server/src/etc/deployers/ear-deployer-beans.xml	2006-12-14 16:52:21 UTC (rev 59049)
@@ -41,18 +41,5 @@
             <this/>
          </parameter>
       </uninstall>
-   </bean>
-
-   <bean name="EARInitializingDeployer" class="org.jboss.deployment.EARInitializingDeployer">
-      <install bean="MainDeployer" method="addDeployer">
-         <parameter>
-            <this/>
-         </parameter>
-      </install>
-      <uninstall bean="MainDeployer" method="removeDeployer">
-         <parameter>
-            <this/>
-         </parameter>
-      </uninstall>
-   </bean>
+   </bean> 
 </deployment>

Modified: trunk/server/src/etc/deployers/ejb-deployer-beans.xml
===================================================================
--- trunk/server/src/etc/deployers/ejb-deployer-beans.xml	2006-12-14 15:32:56 UTC (rev 59048)
+++ trunk/server/src/etc/deployers/ejb-deployer-beans.xml	2006-12-14 16:52:21 UTC (rev 59049)
@@ -44,5 +44,6 @@
        <property name="cachedConnectionManagerName">jboss.jca:service=CachedConnectionManager</property>
        <!-- The ejb timer service -->
        <property name="timerServiceName">jboss.ejb:service=EJBTimerService</property>
+       <depends>SecurityDeployer</depends>
     </bean>
 </deployment>

Added: trunk/server/src/etc/deployers/security-deployer-beans.xml
===================================================================
--- trunk/server/src/etc/deployers/security-deployer-beans.xml	2006-12-14 15:32:56 UTC (rev 59048)
+++ trunk/server/src/etc/deployers/security-deployer-beans.xml	2006-12-14 16:52:21 UTC (rev 59049)
@@ -0,0 +1,26 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+    Security Deployer
+-->
+<deployment xmlns="urn:jboss:bean-deployer:2.0"> 
+   <bean name="SecurityDeployer" class="org.jboss.deployment.security.SecurityDeployer">
+      <install bean="MainDeployer" method="addDeployer">
+         <parameter>
+            <this/>
+         </parameter>
+      </install>
+      <uninstall bean="MainDeployer" method="removeDeployer">
+         <parameter>
+            <this/>
+         </parameter>
+      </uninstall>
+      <property name="ignoreSuffixes">
+          <set elementClass="java.lang.String">
+               <value>xml</value>
+               <value>beans</value>
+               <value>deployer</value>
+          </set>
+       </property>
+   </bean>
+</deployment>



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 11:53:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 11:53:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r59050 - in
	trunk/server/src/main/org/jboss/deployment: . security
Message-ID: <E1GutpU-0006Tk-P3@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-14 11:53:07 -0500 (Thu, 14 Dec 2006)
New Revision: 59050

Added:
   trunk/server/src/main/org/jboss/deployment/security/
   trunk/server/src/main/org/jboss/deployment/security/JaccPolicy.java
   trunk/server/src/main/org/jboss/deployment/security/JaccPolicyMBean.java
   trunk/server/src/main/org/jboss/deployment/security/JaccPolicyUtil.java
   trunk/server/src/main/org/jboss/deployment/security/SecurityDeployer.java
Log:
JBAS-3932: security deployer 

Added: trunk/server/src/main/org/jboss/deployment/security/JaccPolicy.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/security/JaccPolicy.java	2006-12-14 16:52:21 UTC (rev 59049)
+++ trunk/server/src/main/org/jboss/deployment/security/JaccPolicy.java	2006-12-14 16:53:07 UTC (rev 59050)
@@ -0,0 +1,179 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.deployment.security;
+
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.List; 
+
+import javax.security.jacc.PolicyConfiguration;
+import javax.security.jacc.PolicyConfigurationFactory;
+import javax.security.jacc.PolicyContextException;
+
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.ejb.EJBPermissionMapping;
+import org.jboss.logging.Logger;
+import org.jboss.metadata.BeanMetaData;
+import org.jboss.metadata.MetaData;
+import org.jboss.metadata.WebMetaData;
+import org.jboss.web.WebPermissionMapping;
+
+//$Id$
+
+/**
+ *  A Service Bean representing the JACC Policy for the top level deployment
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 11, 2006 
+ *  @version $Revision$
+ */
+public class JaccPolicy implements JaccPolicyMBean
+{ 
+   private static Logger log = Logger.getLogger(JaccPolicy.class);
+   private boolean trace = log.isTraceEnabled();
+   
+   private PolicyConfiguration parentPC = null;
+   private String contextID = null;
+   
+   private List<String> subDeployments = new ArrayList<String>();
+   
+   public static String BASE_OBJECT_NAME = "jboss:service=jacc,id=";
+   
+   /**
+    * Ctr
+    * @param id Jacc Context Id for the top level deployment
+    * @throws IllegalArgumentException if id passed is null
+    */
+   public JaccPolicy(String id, DeploymentUnit unit, Collection<String> ignoreSuffix)
+   {
+      if(id == null)
+         throw new IllegalArgumentException("Jacc Context Id passed is null");
+      this.contextID = id; 
+      subDeployments.addAll(JaccPolicyUtil.getJaccDeployments(unit, ignoreSuffix));
+   }
+   
+   /**
+    * @see JaccPolicyMBean#create()
+    */
+   public void create()
+   { 
+      try
+      {
+         PolicyConfigurationFactory pcf = PolicyConfigurationFactory.getPolicyConfigurationFactory();
+         parentPC = pcf.getPolicyConfiguration(contextID, true);
+      }
+      catch(Exception e)
+      {
+         throw new RuntimeException("Cannot initialize policy configuration:",e);
+      } 
+   }
+   
+   /**
+    * @see JaccPolicyMBean#destroy()
+    */
+   public void destroy()
+   { 
+   }
+
+   /**
+    * @see JaccPolicyMBean#start()
+    */
+   public void start()
+   {  
+      /**
+       * We cannot start the policy configuration until all the subdeployments
+       * have linked
+       */
+   }
+
+   /**
+    * @see JaccPolicyMBean#stop()
+    */
+   public void stop()
+   {  
+   }
+   
+   /**
+    * @see JaccPolicyMBean#createPermissions(MetaData, String, PolicyConfiguration)
+    */
+   public PolicyConfiguration createPermissions(MetaData metadata, String jaccID,
+         PolicyConfiguration pc)
+   throws PolicyContextException
+   { 
+      if(metadata instanceof WebMetaData)
+      {
+         WebMetaData wmd = (WebMetaData)metadata; 
+         if(pc == null)
+            pc = createPolicyConfiguration(jaccID, true);
+         WebPermissionMapping.createPermissions(wmd, pc); 
+      }
+      else
+         if(metadata instanceof BeanMetaData)
+         {
+            BeanMetaData bmd = (BeanMetaData)metadata; 
+            if(pc == null)
+               pc = createPolicyConfiguration(jaccID, true); 
+            EJBPermissionMapping.createPermissions(bmd, pc); 
+         } 
+         else
+            throw new IllegalStateException("Unknown metadata");
+      return pc;
+   }
+    
+   
+   /**
+    * @see JaccPolicyMBean#link(PolicyConfiguration)
+    */
+   public void link(PolicyConfiguration pc) throws PolicyContextException
+   { 
+      if(trace)
+         log.trace("Linking " + pc + " to parent pc=" +  parentPC);
+      parentPC.linkConfiguration(pc);
+      this.subDeployments.remove(pc.getContextID());
+      if(this.subDeployments.size() == 0)
+         parentPC.commit(); //Ready to be inService
+   }
+   
+   /**
+    * Create a Policy Configuration from the factory
+    * @param jaccid Jacc Context ID
+    * @param removeAllPerms Whether the policy configuration that is obtained
+    * needs to be a fresh one (such that old permissions are removed)
+    * @return policy configuration
+    * @throws RuntimeException initialization of PC fails
+    */
+   private PolicyConfiguration createPolicyConfiguration(String jaccid, boolean removeAllPerms)
+   { 
+      if(jaccid == null)
+         throw new IllegalArgumentException("Jacc id is null");
+      PolicyConfiguration pc = null;
+      try
+      {
+         PolicyConfigurationFactory pcf = PolicyConfigurationFactory.getPolicyConfigurationFactory();
+         pc = pcf.getPolicyConfiguration(jaccid, removeAllPerms);
+      }
+      catch(Exception e)
+      {
+         throw new RuntimeException("Cannot initialize policy configuration:",e);
+      } 
+      return pc;
+   }
+}

Added: trunk/server/src/main/org/jboss/deployment/security/JaccPolicyMBean.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/security/JaccPolicyMBean.java	2006-12-14 16:52:21 UTC (rev 59049)
+++ trunk/server/src/main/org/jboss/deployment/security/JaccPolicyMBean.java	2006-12-14 16:53:07 UTC (rev 59050)
@@ -0,0 +1,62 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.deployment.security;
+
+import javax.security.jacc.PolicyConfiguration;
+import javax.security.jacc.PolicyContextException;
+
+import org.jboss.metadata.MetaData;
+
+//$Id$
+
+/**
+ *  Service contract for the JaccPolicy
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 11, 2006 
+ *  @version $Revision$
+ */
+public interface JaccPolicyMBean
+{
+   public void create();
+   public void destroy(); 
+   public void start();
+   public void stop();
+   
+   /**
+    * Create the permissions from the metadata passed
+    * @param metadata WebMetaData,BeanMetaData etc
+    * @param jaccID Jacc Context ID
+    * @param pc Prebuilt policy configuration or pass null to create a fresh one
+    * @return Policy Configuration that is populated with the permissions
+    * @throws PolicyContextException
+    * @throws RuntimeException if the metadata is unknown
+    */
+   public PolicyConfiguration createPermissions(MetaData metadata, String jaccID,
+         PolicyConfiguration pc) throws PolicyContextException;
+   
+   /**
+    * Link the policy Configuration with the top-level policy configuration
+    * @param pc 
+    * @throws PolicyContextException
+    */
+   public void link(PolicyConfiguration pc) throws PolicyContextException;
+}

Added: trunk/server/src/main/org/jboss/deployment/security/JaccPolicyUtil.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/security/JaccPolicyUtil.java	2006-12-14 16:52:21 UTC (rev 59049)
+++ trunk/server/src/main/org/jboss/deployment/security/JaccPolicyUtil.java	2006-12-14 16:53:07 UTC (rev 59050)
@@ -0,0 +1,136 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.deployment.security;
+
+import java.util.ArrayList;
+import java.util.Collection; 
+import java.util.List;
+import java.util.Set;
+
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.system.metadata.ServiceAttributeMetaData;
+import org.jboss.system.metadata.ServiceDependencyValueMetaData;
+
+//$Id$
+
+/**
+ *  Static class with common methods used for jacc deployment processing
+ *  TODO: Remove this class when the MC has the util methods
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 11, 2006 
+ *  @version $Revision$
+ */
+public class JaccPolicyUtil
+{   
+   /**
+    * Given the current deployment, get the object name of the jaccpolicy
+    * that is driving the top-level deployment
+    * @param unit
+    * @return
+    */
+   public static String getJaccPolicyServiceName(DeploymentUnit unit)
+   {
+      DeploymentUnit du = getTopLevelDeployment(unit);  
+      return JaccPolicy.BASE_OBJECT_NAME + du.getSimpleName();
+   }
+   
+   public static boolean isTopLevelDeployment(DeploymentUnit unit)
+   {
+      return unit.getDeploymentContext().isTopLevel();
+   }
+   
+   /**
+    * Given a deployment unit, get all the deployments underneath
+    * that are valid Jacc deployments (ejbs,wars)
+    * @param unit
+    * @param ignoreSuffix (ignore "xml","beans", "deployer" etc)
+    * @return
+    */
+   public static List<String> getJaccDeployments(DeploymentUnit unit, 
+         Collection<String> ignoreSuffix)
+   {
+      ArrayList<String> list = new ArrayList<String>();
+      DeploymentContext dc = unit.getDeploymentContext();
+      Set<DeploymentContext> dcset = dc.getChildren();
+      for(DeploymentContext childDC: dcset)
+      {
+         String childName = childDC.getSimpleName();
+         boolean tobeIgnored = false;
+         //Go through the ignore list
+         for(String ignoreStr: ignoreSuffix)
+         {
+            tobeIgnored = false;
+            if(childName.endsWith(ignoreStr))
+            {
+               tobeIgnored = true;
+               break;
+            } 
+         }
+         //Check if it is a "jar" file, then it must be ejb deployment to consider
+         if(childName.endsWith("jar")  && !tobeIgnored  
+               && !isEJBDeployment(childDC.getDeploymentUnit()))
+            continue;
+         if(!tobeIgnored)  
+           list.add(childName);  
+      }
+      return list;
+   }
+   
+   /**
+    * Get the service attribute metadata that will add dependence on the JaccPolicy
+    * @param unit
+    * @return
+    */
+   public static ServiceAttributeMetaData getServiceAttributeMetaData(DeploymentUnit unit)
+   {
+      ServiceAttributeMetaData jaccAttr = new ServiceAttributeMetaData();
+      jaccAttr.setName("JaccPolicy");
+      ServiceDependencyValueMetaData jaccDepends = new ServiceDependencyValueMetaData();
+      jaccDepends.setDependency(getJaccPolicyServiceName(unit));
+      jaccDepends.setProxyType("attribute");
+      jaccAttr.setValue(jaccDepends);
+      return jaccAttr;
+   }
+   
+   //TODO:Replace with ejb3 deployment logic
+   private static boolean isEJBDeployment(DeploymentUnit du)
+   {
+      boolean ejbxml = du.getMetaDataFile("ejb-jar.xml") != null;
+      boolean jbossxml = du.getMetaDataFile("jboss.xml") != null;
+      return  ejbxml || jbossxml;
+   } 
+   
+   /**
+    * Given a deployment unit, return the top-level deployment unit
+    * @param unit
+    * @return
+    */
+   private static DeploymentUnit getTopLevelDeployment(DeploymentUnit unit)
+   {
+      //TODO: Use the unit.getParent when available 
+      DeploymentContext parentContext = unit.getDeploymentContext();
+      while(parentContext.isTopLevel() == false) 
+         parentContext = parentContext.getParent(); 
+      return parentContext.getDeploymentUnit();
+   } 
+}

Added: trunk/server/src/main/org/jboss/deployment/security/SecurityDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/security/SecurityDeployer.java	2006-12-14 16:52:21 UTC (rev 59049)
+++ trunk/server/src/main/org/jboss/deployment/security/SecurityDeployer.java	2006-12-14 16:53:07 UTC (rev 59050)
@@ -0,0 +1,94 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.deployment.security;
+  
+import java.util.Collection;
+import java.util.HashSet;
+
+import javax.management.ObjectName;
+
+import org.jboss.deployers.plugins.deployer.AbstractSimpleDeployer;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.system.metadata.ServiceConstructorMetaData;
+import org.jboss.system.metadata.ServiceMetaData;
+
+//$Id$
+
+/**
+ *  Security Deployer that does Jacc initialization
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 11, 2006 
+ *  @version $Revision$
+ */
+public class SecurityDeployer extends AbstractSimpleDeployer 
+{   
+   private HashSet<String> ignoreSuffixes = null;
+   
+   public SecurityDeployer()
+   { 
+      this.setRelativeOrder(this.COMPONENT_DEPLOYER - 1);
+   }
+   
+   public void setIgnoreSuffixes(HashSet<String> suffixSet)
+   {
+      this.ignoreSuffixes = suffixSet;
+   }
+
+   @Override
+   public void deploy(DeploymentUnit unit ) throws DeploymentException
+   { 
+      if(JaccPolicyUtil.isTopLevelDeployment(unit) == false)
+         return;
+      
+      //Ignore some of the extensions
+      String contextId = unit.getSimpleName();
+      if(contextId.endsWith("xml"))
+         return;
+      //Create a Service Bean for the JACC Policy 
+      ServiceMetaData jaccPolicy = new ServiceMetaData();
+      jaccPolicy.setCode(JaccPolicy.class.getName());  
+      try
+      {
+         jaccPolicy.setObjectName(new ObjectName(JaccPolicy.BASE_OBJECT_NAME + contextId));
+      }
+      catch (Exception e)
+      { 
+      }  
+      
+      //Provide a constructor for the service bean 
+      ServiceConstructorMetaData constructor = new ServiceConstructorMetaData();
+      constructor.setSignature(new String[] { String.class.getName(),
+            DeploymentUnit.class.getName(), Collection.class.getName()});
+      constructor.setParameters(new Object[] {contextId, unit, ignoreSuffixes});
+      jaccPolicy.setConstructor(constructor); 
+      
+      //Now add this service bean to the unit
+      unit.addAttachment("jboss.jaccpolicy",jaccPolicy, ServiceMetaData.class);  
+   }
+
+   @Override
+   public void undeploy(DeploymentUnit unit )
+   {
+      unit.removeAttachment("jboss.jaccpolicy", ServiceMetaData.class); 
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 11:55:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 11:55:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r59051 - in
	trunk/server/src/main/org/jboss/ejb: . deployers
Message-ID: <E1Guts0-0006Vp-8o@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-14 11:55:42 -0500 (Thu, 14 Dec 2006)
New Revision: 59051

Added:
   trunk/server/src/main/org/jboss/ejb/EJBPermissionMapping.java
Modified:
   trunk/server/src/main/org/jboss/ejb/EjbModule.java
   trunk/server/src/main/org/jboss/ejb/EjbModuleMBean.java
   trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java
Log:
JBAS-3932: security deployer with permission creation delegated to JaccPolicy service bean and dependence of component deployers on JaccPolicy service bean

Added: trunk/server/src/main/org/jboss/ejb/EJBPermissionMapping.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EJBPermissionMapping.java	2006-12-14 16:53:07 UTC (rev 59050)
+++ trunk/server/src/main/org/jboss/ejb/EJBPermissionMapping.java	2006-12-14 16:55:42 UTC (rev 59051)
@@ -0,0 +1,113 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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;
+
+import java.util.Iterator;
+import java.util.Set;
+
+import javax.security.jacc.EJBMethodPermission;
+import javax.security.jacc.EJBRoleRefPermission;
+import javax.security.jacc.PolicyConfiguration;
+import javax.security.jacc.PolicyContextException;
+
+import org.jboss.metadata.BeanMetaData;
+import org.jboss.metadata.MethodMetaData;
+import org.jboss.metadata.SecurityRoleRefMetaData;
+import org.jboss.metadata.SessionMetaData;
+
+//$Id$
+
+/**
+ *  Utility class to create the EJB Permissions from the metadata available
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 12, 2006 
+ *  @version $Revision$
+ */
+public class EJBPermissionMapping
+{
+   public static void createPermissions(BeanMetaData bean, PolicyConfiguration pc)
+   throws PolicyContextException
+   {
+      // Process the method-permission MethodMetaData
+      Iterator iter = bean.getPermissionMethods();
+      while( iter.hasNext() )
+      {
+         MethodMetaData mmd = (MethodMetaData) iter.next();
+         String[] params = null;
+         if( mmd.isParamGiven() )
+            params = mmd.getMethodParams();
+         String methodName = mmd.getMethodName();
+         if( methodName != null && methodName.equals("*") )
+            methodName = null;
+         EJBMethodPermission p = new EJBMethodPermission(mmd.getEjbName(),
+               methodName, mmd.getInterfaceType(), params);
+         if( mmd.isUnchecked() )
+         {
+            pc.addToUncheckedPolicy(p);
+         }
+         else
+         {
+            Set roles = mmd.getRoles();
+            Iterator riter = roles.iterator();
+            while( riter.hasNext() )
+            {
+               String role = (String) riter.next();
+               pc.addToRole(role, p);
+            }
+         }
+      }
+      // Process the exclude-list MethodMetaData
+      iter = bean.getExcludedMethods();
+      while( iter.hasNext() )
+      {
+         MethodMetaData mmd = (MethodMetaData) iter.next();
+         String[] params = null;
+         if( mmd.isParamGiven() )
+            params = mmd.getMethodParams();
+         EJBMethodPermission p = new EJBMethodPermission(mmd.getEjbName(),
+               mmd.getMethodName(), mmd.getInterfaceType(), params);
+         pc.addToExcludedPolicy(p);
+      }
+      // Process the security-role-ref SecurityRoleRefMetaData
+      iter = bean.getSecurityRoleReferences();
+      while( iter.hasNext() )
+      {
+         SecurityRoleRefMetaData srrmd = (SecurityRoleRefMetaData) iter.next();
+         EJBRoleRefPermission p = new EJBRoleRefPermission(bean.getEjbName(), srrmd.getName());
+         pc.addToRole(srrmd.getLink(), p);
+      }
+      /* Special handling of stateful session bean getEJBObject due how the
+   stateful session handles acquire the proxy by sending an invocation to
+   the ejb container.
+       */
+      if( bean instanceof SessionMetaData )
+      {
+         SessionMetaData smd = (SessionMetaData) bean;
+         if( smd.isStateful() )
+         {
+            EJBMethodPermission p = new EJBMethodPermission(bean.getEjbName(),
+                  "getEJBObject", "Home", null);
+            pc.addToUncheckedPolicy(p);
+         }
+      }
+   } 
+}

Modified: trunk/server/src/main/org/jboss/ejb/EjbModule.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EjbModule.java	2006-12-14 16:53:07 UTC (rev 59050)
+++ trunk/server/src/main/org/jboss/ejb/EjbModule.java	2006-12-14 16:55:42 UTC (rev 59051)
@@ -31,8 +31,7 @@
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.Map;
-import java.util.ListIterator;
-import java.util.Set;
+import java.util.ListIterator; 
 import java.util.HashSet;
 
 import javax.ejb.EJBLocalHome;
@@ -42,15 +41,14 @@
 import javax.security.jacc.PolicyConfiguration;
 import javax.security.jacc.PolicyConfigurationFactory;
 import javax.security.jacc.EJBMethodPermission;
-import javax.security.jacc.PolicyContextException;
-import javax.security.jacc.EJBRoleRefPermission;
+import javax.security.jacc.PolicyContextException; 
 import javax.transaction.TransactionManager;
 
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext; 
+import org.jboss.deployers.spi.deployer.DeploymentUnit; 
 import org.jboss.deployment.DeploymentException;
 import org.jboss.deployment.DeploymentInfo;
-import org.jboss.deployment.EARDeployerMBean;
+import org.jboss.deployment.EARDeployerMBean; 
+import org.jboss.deployment.security.JaccPolicyMBean;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.ApplicationMetaData;
 import org.jboss.metadata.BeanMetaData;
@@ -59,9 +57,7 @@
 import org.jboss.metadata.InvokerProxyBindingMetaData;
 import org.jboss.metadata.MetaData;
 import org.jboss.metadata.SessionMetaData;
-import org.jboss.metadata.XmlLoadable;
-import org.jboss.metadata.MethodMetaData;
-import org.jboss.metadata.SecurityRoleRefMetaData;
+import org.jboss.metadata.XmlLoadable; 
 import org.jboss.mx.loading.RepositoryClassLoader; 
 import org.jboss.ejb.plugins.SecurityProxyInterceptor;
 import org.jboss.ejb.plugins.StatefulSessionInstancePool;
@@ -162,6 +158,9 @@
    /** Whether we are call by value */
    private boolean callByValue;
    private ApplicationMetaData appMetaData;
+   
+   /** Top level Jacc Policy per top-level deployment */
+   private JaccPolicyMBean jaccPolicy;
 
    public EjbModule(final DeploymentUnit unit, ApplicationMetaData metaData)
    {
@@ -325,6 +324,17 @@
       return appMetaData.getUrl();
    }
 
+   public JaccPolicyMBean getJaccPolicy()
+   {
+      return jaccPolicy;
+   }
+   
+   public void setJaccPolicy(JaccPolicyMBean jaccPolicy)
+   {
+      this.jaccPolicy = jaccPolicy;
+   }
+   
+
    // Service implementation ----------------------------------------
 
    protected void createService() throws Exception
@@ -364,10 +374,11 @@
          Iterator beans = appMetaData.getEnterpriseBeans();
          String contextID = appMetaData.getJaccContextID();
          if( contextID == null )
-            contextID = shortNameFromDeploymentName(deploymentUnit.getSimpleName()); 
+            contextID = deploymentUnit.getSimpleName(); 
          appMetaData.setJaccContextID(contextID);
-         PolicyConfigurationFactory pcFactory = PolicyConfigurationFactory.getPolicyConfigurationFactory();
-         PolicyConfiguration pc = pcFactory.getPolicyConfiguration(contextID, true);
+         /*PolicyConfigurationFactory pcFactory = PolicyConfigurationFactory.getPolicyConfigurationFactory();
+         PolicyConfiguration pc = pcFactory.getPolicyConfiguration(contextID, true);*/
+         PolicyConfiguration pc = null;
          while (beans.hasNext())
          {
             BeanMetaData bean = (BeanMetaData) beans.next();
@@ -377,18 +388,26 @@
             //@todo support overriding the context id via metadata is needed
             con.setJaccContextID(contextID);
             // Register the permissions with the JACC layer
-            createPermissions(bean, pc);
-            deploymentUnit.addAttachment(PolicyConfiguration.class, pc);
+            /**createPermissions(bean, pc);*/ 
+            if(jaccPolicy != null)
+              pc = jaccPolicy.createPermissions(bean, contextID, pc);
+            //deploymentUnit.addAttachment(PolicyConfiguration.class, pc);
             // Link this to the parent PC
-            DeploymentContext current = deploymentUnit.getDeploymentContext();
+            /*DeploymentContext current = deploymentUnit.getDeploymentContext();
             while (current.getParent() != null)
                current = current.getParent(); 
             PolicyConfiguration parentPC =
                current.getTransientAttachments().getAttachment(PolicyConfiguration.class);
             if (parentPC != null && parentPC != pc)
-               parentPC.linkConfiguration(pc);      
+               parentPC.linkConfiguration(pc); */  
          }
-         pc.commit();
+         
+         if(pc != null && jaccPolicy != null)
+         {
+            jaccPolicy.link(pc);
+            pc.commit();
+         }
+           
 
          //only one iteration should be necessary, but we won't sweat it.
          //2 iterations are needed by cmp...jdbc/bridge/JDBCCMRFieldBridge which
@@ -1020,72 +1039,7 @@
       container.addInterceptor(container.createContainerInterceptor());
    }
 
-   private void createPermissions(BeanMetaData bean, PolicyConfiguration pc)
-      throws PolicyContextException
-   {
-      // Process the method-permission MethodMetaData
-      Iterator iter = bean.getPermissionMethods();
-      while( iter.hasNext() )
-      {
-         MethodMetaData mmd = (MethodMetaData) iter.next();
-         String[] params = null;
-         if( mmd.isParamGiven() )
-            params = mmd.getMethodParams();
-         String methodName = mmd.getMethodName();
-         if( methodName != null && methodName.equals("*") )
-            methodName = null;
-         EJBMethodPermission p = new EJBMethodPermission(mmd.getEjbName(),
-            methodName, mmd.getInterfaceType(), params);
-         if( mmd.isUnchecked() )
-         {
-            pc.addToUncheckedPolicy(p);
-         }
-         else
-         {
-            Set roles = mmd.getRoles();
-            Iterator riter = roles.iterator();
-            while( riter.hasNext() )
-            {
-               String role = (String) riter.next();
-               pc.addToRole(role, p);
-            }
-         }
-      }
-      // Process the exclude-list MethodMetaData
-      iter = bean.getExcludedMethods();
-      while( iter.hasNext() )
-      {
-         MethodMetaData mmd = (MethodMetaData) iter.next();
-         String[] params = null;
-         if( mmd.isParamGiven() )
-            params = mmd.getMethodParams();
-         EJBMethodPermission p = new EJBMethodPermission(mmd.getEjbName(),
-            mmd.getMethodName(), mmd.getInterfaceType(), params);
-         pc.addToExcludedPolicy(p);
-      }
-      // Process the security-role-ref SecurityRoleRefMetaData
-      iter = bean.getSecurityRoleReferences();
-      while( iter.hasNext() )
-      {
-         SecurityRoleRefMetaData srrmd = (SecurityRoleRefMetaData) iter.next();
-         EJBRoleRefPermission p = new EJBRoleRefPermission(bean.getEjbName(), srrmd.getName());
-         pc.addToRole(srrmd.getLink(), p);
-      }
-      /* Special handling of stateful session bean getEJBObject due how the
-      stateful session handles acquire the proxy by sending an invocation to
-      the ejb container.
-      */
-      if( bean instanceof SessionMetaData )
-      {
-         SessionMetaData smd = (SessionMetaData) bean;
-         if( smd.isStateful() )
-         {
-            EJBMethodPermission p = new EJBMethodPermission(bean.getEjbName(),
-               "getEJBObject", "Home", null);
-            pc.addToUncheckedPolicy(p);
-         }
-      }
-   }
+   
 
    /** Create any JACC permissions for the ejb methods that were not explicitly
     * assigned method-permission or exclude-list mappings.
@@ -1293,28 +1247,7 @@
          ((XmlLoadable) ic).importXml(conf.getContainerCacheConf());
 
       return ic;
-   } 
-   
-   /**
-    * A utility method that takes a deployment unit name and strips it down to the base jar
-    * name without the .jar suffix.
-    * @param name - the DeploymentUnit name.
-    */
-   public static String shortNameFromDeploymentName(String name)
-   {
-      String shortName = name.trim();
-      String[] parts = name.split("/|\\.|\\!");
-      if( parts.length > 1 )
-      {
-         // If it ends in .war, use the previous part
-         if( parts[parts.length-1].equals("jar") )
-            shortName = parts[parts.length-2];
-         // else use the last part
-         else
-            shortName = parts[parts.length-1];
-      }
-      return shortName;
-   }
+   }  
 }
 /*
 vim:ts=3:sw=3:et

Modified: trunk/server/src/main/org/jboss/ejb/EjbModuleMBean.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EjbModuleMBean.java	2006-12-14 16:53:07 UTC (rev 59050)
+++ trunk/server/src/main/org/jboss/ejb/EjbModuleMBean.java	2006-12-14 16:55:42 UTC (rev 59051)
@@ -23,6 +23,7 @@
 
 import javax.management.ObjectName;
 
+import org.jboss.deployment.security.JaccPolicyMBean;
 import org.jboss.tm.TransactionManagerFactory;
 
 /**
@@ -39,6 +40,8 @@
   java.util.Collection getContainers() ;
 
   void setTransactionManagerFactory(TransactionManagerFactory tmFactory);
+  void setJaccPolicy(JaccPolicyMBean jp);
+  JaccPolicyMBean getJaccPolicy();
   public ObjectName getWebServiceName();
   public void setWebServiceName(ObjectName webServiceName);
 }

Modified: trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java	2006-12-14 16:53:07 UTC (rev 59050)
+++ trunk/server/src/main/org/jboss/ejb/deployers/EjbDeployer.java	2006-12-14 16:55:42 UTC (rev 59051)
@@ -29,7 +29,8 @@
 
 import org.jboss.deployers.plugins.deployers.helpers.AbstractSimpleRealDeployer;
 import org.jboss.deployers.spi.DeploymentException;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.deployers.spi.deployer.DeploymentUnit; 
+import org.jboss.deployment.security.JaccPolicyUtil;
 import org.jboss.ejb.EjbModule;
 import org.jboss.metadata.ApplicationMetaData;
 import org.jboss.mx.util.ObjectNameConverter;
@@ -55,7 +56,7 @@
    /** The CachedConnectionManager service used by the CachedConnectionInterceptor */
    private String ccmServiceName;
    /** The ejb timer service */
-   private String timerServiceName;
+   private String timerServiceName; 
 
    public EjbDeployer()
    {
@@ -109,6 +110,12 @@
    {
       // TODO: use BeanVerifier to validate the metadata in the DDs
       if (deployment.getEjbVersion() > 2) return; // let EJB3 deployer handle this
+      
+      /**
+       * Ignore the jacc policy service bean 
+       */
+      if(unit.getName().startsWith("jboss:") && unit.getName().contains("id="))
+         return;
 
       ServiceMetaData ejbModule = new ServiceMetaData();
       ejbModule.setCode(EjbModule.class.getName());
@@ -169,6 +176,12 @@
       wsDepends.setDependency(getWebServiceName());
       ws.setValue(wsDepends);
       attrs.add(ws);
+       
+      //Add a dependence on the jacc policy only if we are not the top-level deployment
+      if(!JaccPolicyUtil.isTopLevelDeployment(unit))
+      { 
+         attrs.add(JaccPolicyUtil.getServiceAttributeMetaData(unit));
+      }  
       ejbModule.setAttributes(attrs);
 
       List<ServiceDependencyMetaData> dependencies = new ArrayList<ServiceDependencyMetaData>();



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 11:57:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 11:57:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r59052 -
	trunk/server/src/main/org/jboss/web/deployers
Message-ID: <E1Guttw-0006Ya-W9@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-14 11:57:43 -0500 (Thu, 14 Dec 2006)
New Revision: 59052

Modified:
   trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployer.java
   trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployment.java
   trunk/server/src/main/org/jboss/web/deployers/WebModule.java
   trunk/server/src/main/org/jboss/web/deployers/WebModuleMBean.java
Log:
JBAS-3932: security deployer with permission creation delegated to JaccPolicy service bean and dependence of component deployers on JaccPolicy service bean

Modified: trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployer.java	2006-12-14 16:55:42 UTC (rev 59051)
+++ trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployer.java	2006-12-14 16:57:43 UTC (rev 59052)
@@ -34,17 +34,16 @@
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
 
-import org.jboss.deployers.plugins.deployers.helpers.AbstractSimpleRealDeployer;
-import org.jboss.deployers.plugins.deployers.helpers.AttachmentLocator;
+import org.jboss.deployers.plugins.deployers.helpers.AbstractSimpleRealDeployer; 
 import org.jboss.deployers.spi.DeploymentException;
 import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext;
-import org.jboss.deployment.J2eeApplicationMetaData;
-import org.jboss.deployment.J2eeModuleMetaData;
+import org.jboss.deployers.spi.structure.DeploymentContext; 
+import org.jboss.deployment.security.JaccPolicyUtil;
 import org.jboss.metadata.WebMetaData;
 import org.jboss.mx.util.MBeanServerLocator;
+import org.jboss.system.metadata.ServiceAttributeMetaData;
 import org.jboss.system.metadata.ServiceConstructorMetaData;
-import org.jboss.system.metadata.ServiceDependencyMetaData;
+import org.jboss.system.metadata.ServiceDependencyMetaData; 
 import org.jboss.system.metadata.ServiceMetaData;
 import org.jboss.system.server.ServerConfig;
 import org.jboss.system.server.ServerConfigLocator;
@@ -100,7 +99,7 @@
    /** The request attribute name under which the JAAS Subject is store */
    private String subjectAttributeName = null;
    /** Legacy support for MBeanServer */
-   private MBeanServer server;
+   private MBeanServer server; 
 
    /**
     * Set the relative order to COMPONENT_DEPLOYER+1 by default
@@ -234,7 +233,7 @@
    public void setSubjectAttributeName(String subjectAttributeName)
    {
       this.subjectAttributeName = subjectAttributeName;
-   }
+   }  
 
    public void start() throws Exception
    {
@@ -295,6 +294,13 @@
           * the root url.
           */
          String warName = unit.getName();
+         
+         /**
+          * Ignore the jacc policy service bean 
+          */
+         if(warName.startsWith("jboss:") && warName.contains("id="))
+            return;
+         
          URL expWarUrl = unit.getDeploymentContext().getRoot().toURL();
          if (warName.endsWith("/") == false
          // Hack for jar urls being exposed
@@ -599,6 +605,15 @@
             sdmd.setIDependOn(iDependOn);
          }
          webModule.setDependencies(dependencies);
+         
+         //Add a dependence on the jacc policy only if we are not the top-level deployment
+         if(!JaccPolicyUtil.isTopLevelDeployment(unit))
+         {
+            //set attributes 
+            List<ServiceAttributeMetaData> attrs = new ArrayList<ServiceAttributeMetaData>(); 
+            attrs.add(JaccPolicyUtil.getServiceAttributeMetaData(unit));
+            webModule.setAttributes(attrs);
+         } 
 
          // TODO could create multiple components for the deployment
          unit.addAttachment(ServiceMetaData.class, webModule);
@@ -606,7 +621,6 @@
       catch (Exception e)
       {
          throw DeploymentException.rethrowAsDeploymentException("Error creating rar deployment " + unit.getName(), e);
-      }
-
-   }
+      } 
+   } 
 }

Modified: trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployment.java
===================================================================
--- trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployment.java	2006-12-14 16:55:42 UTC (rev 59051)
+++ trunk/server/src/main/org/jboss/web/deployers/AbstractWarDeployment.java	2006-12-14 16:57:43 UTC (rev 59052)
@@ -37,11 +37,10 @@
 import javax.naming.LinkRef;
 import javax.naming.NamingException;
 import javax.security.jacc.PolicyConfiguration;
-import javax.security.jacc.PolicyConfigurationFactory;
-import javax.security.jacc.PolicyContextException;
+import javax.security.jacc.PolicyConfigurationFactory; 
 
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.deployers.spi.deployer.DeploymentUnit;  
+import org.jboss.deployment.security.JaccPolicyMBean; 
 import org.jboss.ejb.EjbUtil50;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.EjbLocalRefMetaData;
@@ -57,8 +56,7 @@
 import org.jboss.naming.Util;
 import org.jboss.security.AuthorizationManager;
 import org.jboss.security.authorization.PolicyRegistration;
-import org.jboss.web.WebApplication;
-import org.jboss.web.WebPermissionMapping;
+import org.jboss.web.WebApplication; 
 import org.omg.CORBA.ORB;
 
 /**
@@ -110,33 +108,15 @@
     * The default security-domain name to use
     */
    protected String defaultSecurityDomain;
+   
+   protected JaccPolicyMBean jaccPolicy;
 
    public AbstractWarDeployment()
    {
       log = Logger.getLogger(getClass());
    }
-
+ 
    /**
-    * A utility method that takes a deployment unit name and strips it down to the base war
-    * name without the .war suffix.
-    * @param name - the DeploymentUnit name.
-    */
-   public static String shortNameFromDeploymentName(String name)
-   {
-      String shortName = name.trim();
-      String[] parts = name.split("/|\\.|\\!");
-      if( parts.length > 1 )
-      {
-         // If it ends in .war, use the previous part
-         if( parts[parts.length-1].equals("war") )
-            shortName = parts[parts.length-2];
-         // else use the last part
-         else
-            shortName = parts[parts.length-1];
-      }
-      return shortName;
-   }
-   /**
     * Utility method that builds a string url based on the ServerConfig.SERVER_HOME_URL system
     * property and the input url. If the input url is under the SERVER_HOME_URL, the SERVER_HOME_URL
     * prefix is replaced with ".../".
@@ -265,6 +245,17 @@
       this.defaultSecurityDomain = defaultSecurityDomain;
    }
 
+   
+   public JaccPolicyMBean getJaccPolicy()
+   {
+      return jaccPolicy;
+   }
+
+   public void setJaccPolicy(JaccPolicyMBean jaccPolicy)
+   {
+      this.jaccPolicy = jaccPolicy;
+   }
+
    /**
     * A template pattern implementation of the deploy() method. This method
     * calls the {@link #performDeploy(WebApplication, String,
@@ -330,22 +321,34 @@
          // Register the permissions with the JACC layer
          String contextID = metaData.getJaccContextID();
          if( contextID == null )
-            contextID = shortNameFromDeploymentName(di.getName());
+            contextID = di.getSimpleName();
          metaData.setJaccContextID(contextID);
-         PolicyConfigurationFactory pcFactory = PolicyConfigurationFactory.getPolicyConfigurationFactory();
+         /*PolicyConfigurationFactory pcFactory = PolicyConfigurationFactory.getPolicyConfigurationFactory();
          PolicyConfiguration pc = pcFactory.getPolicyConfiguration(contextID, true);
-         createPermissions(metaData, pc);
+         createPermissions(metaData, pc);*/
          // Link this to the parent PC
-         DeploymentContext current = di.getDeploymentContext();
+         /*DeploymentContext current = di.getDeploymentContext();
          while (current.getParent() != null)
             current = current.getParent();
          PolicyConfiguration parentPC =
             current.getTransientAttachments().getAttachment(PolicyConfiguration.class);
          if (parentPC != null && parentPC != pc)
-            parentPC.linkConfiguration(pc);
+            parentPC.linkConfiguration(pc);*/
+         
+         //Link it to the top-level deployment parent policy configuration
+         if(log.isTraceEnabled())
+            log.trace("Jacc Policy injected="+jaccPolicy != null);
+         PolicyConfiguration pc = null;
+         if(jaccPolicy != null)
+         {
+            if(log.isTraceEnabled())
+              log.trace("Jacc Policy linking to top-level policyConfiguration"); 
+            pc = jaccPolicy.createPermissions(metaData, contextID, pc);
+            jaccPolicy.link(pc);
+            // Commit the policy configuration
+            pc.commit();
+         } 
    
-         // Commit the policy configuration
-         pc.commit();
          // Allow the policy to incorporate the policy configs
          Policy.getPolicy().refresh();
    
@@ -823,19 +826,5 @@
          URL url = urls[u];
          urlSet.add(url.toExternalForm());
       }
-   }
-
-   /**
-    * Create the JACC permission based on the security constraints obtained from
-    * the web.xml metadata.
-    * @param metaData
-    * @param pc
-    * @throws PolicyContextException
-    */
-   protected void createPermissions(WebMetaData metaData, PolicyConfiguration pc)
-      throws PolicyContextException
-   {
-      WebPermissionMapping.createPermissions(metaData, pc);
-   }
-
+   } 
 }

Modified: trunk/server/src/main/org/jboss/web/deployers/WebModule.java
===================================================================
--- trunk/server/src/main/org/jboss/web/deployers/WebModule.java	2006-12-14 16:55:42 UTC (rev 59051)
+++ trunk/server/src/main/org/jboss/web/deployers/WebModule.java	2006-12-14 16:57:43 UTC (rev 59052)
@@ -22,7 +22,8 @@
 package org.jboss.web.deployers;
 
 import org.jboss.deployers.spi.deployer.DeploymentUnit;
-import org.jboss.deployment.DeploymentException;
+import org.jboss.deployment.DeploymentException; 
+import org.jboss.deployment.security.JaccPolicyMBean;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.WebMetaData;
 import org.jboss.web.WebApplication;
@@ -48,6 +49,9 @@
    private DeploymentUnit di;
    private AbstractWarDeployer container;
    private AbstractWarDeployment deployment;
+   
+   /** Jacc Policy for top-level deployment */
+   private JaccPolicyMBean jaccPolicy;
 
    public WebModule(DeploymentUnit di, AbstractWarDeployer container,
          AbstractWarDeployment deployment)
@@ -55,7 +59,17 @@
       this.di = di;
       this.container = container;
       this.deployment = deployment;
-   }
+   } 
+   
+   public JaccPolicyMBean getJaccPolicy()
+   {
+      return jaccPolicy;
+   } 
+   
+   public void setJaccPolicy(JaccPolicyMBean jaccPolicy)
+   {
+      this.jaccPolicy = jaccPolicy;
+   } 
 
    public void create()
    {
@@ -85,6 +99,8 @@
    {
       // Get the war URL
       WebMetaData metaData = di.getAttachment(WebMetaData.class);
+      //Add the jacc policy 
+      deployment.setJaccPolicy(jaccPolicy);
       WebApplication webApp = deployment.start(di, metaData);
       String warURL = di.getName();
       container.addDeployedApp(warURL, webApp);

Modified: trunk/server/src/main/org/jboss/web/deployers/WebModuleMBean.java
===================================================================
--- trunk/server/src/main/org/jboss/web/deployers/WebModuleMBean.java	2006-12-14 16:55:42 UTC (rev 59051)
+++ trunk/server/src/main/org/jboss/web/deployers/WebModuleMBean.java	2006-12-14 16:57:43 UTC (rev 59052)
@@ -20,6 +20,8 @@
  * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
  */
 package org.jboss.web.deployers;
+ 
+import org.jboss.deployment.security.JaccPolicyMBean;
 
 /** The standard mbean service interface for the WebModule
  * @author Scott.Stark at jboss.org
@@ -31,4 +33,8 @@
    public void start() throws Exception;
    public void stop() throws Exception;
    public void destroy() throws Exception;
+   
+   /** For top-level jacc policy */
+   public JaccPolicyMBean getJaccPolicy();
+   public void setJaccPolicy(JaccPolicyMBean jp);
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 12:00:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 12:00:11 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59053 - trunk/tomcat/src/resources
Message-ID: <E1GutwJ-0006bo-K5@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-14 12:00:10 -0500 (Thu, 14 Dec 2006)
New Revision: 59053

Modified:
   trunk/tomcat/src/resources/war-deployers-all-beans.xml
   trunk/tomcat/src/resources/war-deployers-beans.xml
Log:
JBAS-3932: security deployer dependence on component deployers

Modified: trunk/tomcat/src/resources/war-deployers-all-beans.xml
===================================================================
--- trunk/tomcat/src/resources/war-deployers-all-beans.xml	2006-12-14 16:57:43 UTC (rev 59052)
+++ trunk/tomcat/src/resources/war-deployers-all-beans.xml	2006-12-14 17:00:10 UTC (rev 59053)
@@ -193,6 +193,7 @@
       -->
       
       <depends>jboss:service=TransactionManager</depends>
+      <depends>SecurityDeployer</depends>
       
       <!-- Only needed if the org.jboss.web.tomcat.tc6.jca.CachedConnectionValve
 TODO: injection

Modified: trunk/tomcat/src/resources/war-deployers-beans.xml
===================================================================
--- trunk/tomcat/src/resources/war-deployers-beans.xml	2006-12-14 16:57:43 UTC (rev 59052)
+++ trunk/tomcat/src/resources/war-deployers-beans.xml	2006-12-14 17:00:10 UTC (rev 59053)
@@ -223,6 +223,7 @@
 	   </property>
       
       <depends>jboss:service=TransactionManager</depends>
+      <depends>SecurityDeployer</depends>
 
       <!-- Only needed if the org.jboss.web.tomcat.tc6.jca.CachedConnectionValve
 TODO: injection



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 12:02:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 12:02:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r59054 -
	trunk/system-jmx/src/main/org/jboss/system/metadata
Message-ID: <E1Gutyt-0006qY-BU@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-14 12:02:50 -0500 (Thu, 14 Dec 2006)
New Revision: 59054

Modified:
   trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java
Log:
add a null check such that if the setDependency has never been called, no NPE happens

Modified: trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java
===================================================================
--- trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java	2006-12-14 17:00:10 UTC (rev 59053)
+++ trunk/system-jmx/src/main/org/jboss/system/metadata/ServiceDependencyValueMetaData.java	2006-12-14 17:02:50 UTC (rev 59054)
@@ -120,7 +120,7 @@
    {
       if (objectName == null)
       {
-         if (dependency.trim().length() == 0)
+         if (dependency == null || dependency.trim().length() == 0)
             throw new MalformedObjectNameException("Missing object name in depends");
          ObjectName name = new ObjectName(dependency);
          if (name.isPattern())



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 12:14:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 12:14:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r59055 - in projects/microcontainer/trunk:
	kernel/src/main/org/jboss/beans/metadata/plugins
	kernel/src/main/org/jboss/kernel/plugins/deployment/xml
	spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1GuuAB-0006zS-S0@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 12:14:20 -0500 (Thu, 14 Dec 2006)
New Revision: 59055

Added:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertiesMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractMapMetaData.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
string properties MD support

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractMapMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractMapMetaData.java	2006-12-14 17:02:50 UTC (rev 59054)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractMapMetaData.java	2006-12-14 17:14:20 UTC (rev 59055)
@@ -30,7 +30,6 @@
 import org.jboss.joinpoint.spi.Joinpoint;
 import org.jboss.reflect.spi.ClassInfo;
 import org.jboss.reflect.spi.TypeInfo;
-import org.jboss.util.JBossStringBuilder;
 
 /**
  * Map metadata.
@@ -96,9 +95,14 @@
       this.valueType = valueType;
    }
 
+   protected Class<? extends Map> expectedMapClass()
+   {
+      return Map.class;
+   }
+
    public Object getValue(TypeInfo info, ClassLoader cl) throws Throwable
    {
-      Map<Object, Object> result = getMapInstance(info, cl, Map.class);
+      Map<Object, Object> result = getMapInstance(info, cl, expectedMapClass());
       if (result == null)
          result = getDefaultMapInstance();
 
@@ -162,8 +166,7 @@
 
    public void putAll(Map<? extends MetaDataVisitorNode, ? extends MetaDataVisitorNode> t)
    {
-      putAll(t);
-
+      map.putAll(t);
    }
 
    public MetaDataVisitorNode remove(Object key)
@@ -213,11 +216,6 @@
       return super.getType(visitor, previous);
    }
 
-   public void toString(JBossStringBuilder buffer)
-   {
-      super.toString(buffer);
-   }
-
    /**
     * Create the default map instance
     * 

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertiesMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertiesMetaData.java	2006-12-14 17:02:50 UTC (rev 59054)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertiesMetaData.java	2006-12-14 17:14:20 UTC (rev 59055)
@@ -0,0 +1,65 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.beans.metadata.plugins;
+
+import java.util.Map;
+import java.util.Properties;
+
+/**
+ * Properties metadata.
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public class AbstractPropertiesMetaData extends AbstractMapMetaData
+{
+
+   protected Map<Object, Object> getDefaultMapInstance() throws Throwable
+   {
+      return new Properties();
+   }
+
+   protected Class<? extends Map> expectedMapClass()
+   {
+      return Properties.class;
+   }
+
+   public String getKeyType()
+   {
+      return String.class.getName();
+   }
+
+   public void setKeyType(String keyType)
+   {
+      throw new IllegalArgumentException("Illegal call to set properties key type!");
+   }
+
+   public String getValueType()
+   {
+      return String.class.getName();
+   }
+
+   public void setValueType(String valueType)
+   {
+      throw new IllegalArgumentException("Illegal call to set properties value type!");
+   }
+
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java	2006-12-14 17:02:50 UTC (rev 59054)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java	2006-12-14 17:14:20 UTC (rev 59055)
@@ -0,0 +1,66 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.plugins.deployment.xml;
+
+import javax.xml.namespace.QName;
+import javax.xml.namespace.NamespaceContext;
+
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.xml.sax.Attributes;
+
+/**
+ * PropertyHandler.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 43026 $
+ */
+public class PropHandler extends DefaultElementHandler
+{
+   /** The handler */
+   public static final PropHandler HANDLER = new PropHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new MapEntry();
+   }
+
+   public void attributes(Object object, QName qName, ElementBinding eb, Attributes attrs, NamespaceContext nc)
+   {
+      MapEntry entry = (MapEntry) object;
+      for (int i = 0; i < attrs.getLength(); ++i)
+      {
+         String localName = attrs.getLocalName(i);
+         if ("key".equals(localName))
+            entry.key = attrs.getValue(i);
+      }
+   }
+
+   public Object endElement(Object object, QName qName, ElementBinding elementBinding)
+   {
+      MapEntry entry = (MapEntry) object;
+      if (entry.key == null)
+         throw new IllegalArgumentException("Missing key attribute: " + elementBinding);
+      return entry;
+   }
+
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java	2006-12-14 17:02:50 UTC (rev 59054)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java	2006-12-14 17:14:20 UTC (rev 59055)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.plugins.deployment.xml;
+
+import javax.xml.namespace.QName;
+
+import org.jboss.beans.metadata.plugins.AbstractPropertiesMetaData;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
+import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+
+/**
+ * PropertyHandler.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 43026 $
+ */
+public class PropertiesHandler extends DefaultElementHandler
+{
+   /** The handler */
+   public static final PropertiesHandler HANDLER = new PropertiesHandler();
+
+   public Object startElement(Object parent, QName name, ElementBinding element)
+   {
+      return new AbstractPropertiesMetaData();
+   }
+
+}

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-14 17:02:50 UTC (rev 59054)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-14 17:14:20 UTC (rev 59055)
@@ -128,6 +128,26 @@
    public static final QName mapQName = new QName(SPRING_DEPLOYER_NS, "map");
 
    /**
+    * The props binding
+    */
+   public static final QName propsTypeQName = new QName(SPRING_DEPLOYER_NS, "propsType");
+
+   /**
+    * The props element name
+    */
+   public static final QName propsQName = new QName(SPRING_DEPLOYER_NS, "props");
+
+   /**
+    * The props binding
+    */
+   public static final QName propTypeQName = new QName(SPRING_DEPLOYER_NS, "propType");
+
+   /**
+    * The prop element name
+    */
+   public static final QName propQName = new QName(SPRING_DEPLOYER_NS, "prop");
+
+   /**
     * The entry binding
     */
    public static final QName entryTypeQName = new QName(SPRING_DEPLOYER_NS, "entryType");
@@ -216,6 +236,14 @@
       // key type
       TypeBinding keyType = schemaBinding.getType(entryTypeQName);
       SpringSchemaBindingHelper.initKeyHandler(keyType);
+
+      // props
+      TypeBinding propsType = schemaBinding.getType(propsTypeQName);
+      SpringSchemaBindingHelper.initPropsHandler(propsType);
+
+      // prop
+      TypeBinding propType = schemaBinding.getType(propTypeQName);
+      SpringSchemaBindingHelper.initPropHandler(propType);
    }
 
 }

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-14 17:02:50 UTC (rev 59054)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-14 17:14:20 UTC (rev 59055)
@@ -93,6 +93,13 @@
       typeBinding.pushInterceptor(SpringSchemaBinding.entryQName, MapEntryInterceptor.INTERCEPTOR);
    }
 
+   public static void initPropsHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(PropertiesHandler.HANDLER);
+      // props
+      typeBinding.pushInterceptor(SpringSchemaBinding.propQName, MapEntryInterceptor.INTERCEPTOR);
+   }
+
    public static void initEntryHandler(TypeBinding typeBinding)
    {
       typeBinding.setHandler(EntryHandler.HANDLER);
@@ -122,6 +129,13 @@
       typeBinding.pushInterceptor(SpringSchemaBinding.nullQName, EntryValueInterceptor.INTERCEPTOR);
    }
 
+   public static void initPropHandler(TypeBinding typeBinding)
+   {
+      typeBinding.setHandler(PropHandler.HANDLER);
+      // property takes characters
+      typeBinding.setSimpleType(PropertyCharactersHandler.HANDLER);
+   }
+
    public static void initKeyHandler(TypeBinding typeBinding)
    {
       typeBinding.setHandler(SpringMapKeyHandler.HANDLER);



From msurtani at jboss.com  Thu Dec 14 12:18:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 12:18:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache         ...
Message-ID: <E1GuuEK-00073y-0E@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 12:18:47

  Modified:    src/org/jboss/cache         TreeCacheProxyImpl.java
                        TransactionEntry.java TreeCache.java TreeNode.java
                        AbstractNode.java RegionManager.java NodeImpl.java
  Removed:     src/org/jboss/cache         ExtendedTreeCacheListener.java
  Log:
  The beginnings of porting JBCACHE-871 and JBCACHE-875 as well as rearranging the Node/Cache object model to something sensible
  
  Revision  Changes    Path
  1.54      +5 -0      JBossCache/src/org/jboss/cache/TreeCacheProxyImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheProxyImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCacheProxyImpl.java,v
  retrieving revision 1.53
  retrieving revision 1.54
  diff -u -b -r1.53 -r1.54
  --- TreeCacheProxyImpl.java	27 Nov 2006 17:07:05 -0000	1.53
  +++ TreeCacheProxyImpl.java	14 Dec 2006 17:18:47 -0000	1.54
  @@ -440,4 +440,9 @@
         return getRoot().getNodeSPI();
      }
   
  +   public void realRemove(Fqn f, boolean skipMarkerCheck)
  +   {
  +      treeCache.realRemove(f, skipMarkerCheck);
  +   }
  +
   }
  
  
  
  1.17      +163 -95   JBossCache/src/org/jboss/cache/TransactionEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionEntry.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- TransactionEntry.java	8 Dec 2006 03:49:28 -0000	1.16
  +++ TransactionEntry.java	14 Dec 2006 17:18:47 -0000	1.17
  @@ -7,16 +7,21 @@
   package org.jboss.cache;
   
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.config.Option;
   import org.jboss.cache.lock.IdentityLock;
   import org.jboss.cache.lock.NodeLock;
  -import org.jboss.cache.config.Option;
   import org.jboss.cache.marshall.MethodCall;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  -
   import javax.transaction.Transaction;
  -import java.util.*;
  +import java.util.ArrayList;
  +import java.util.Collection;
  +import java.util.Iterator;
  +import java.util.LinkedHashSet;
  +import java.util.LinkedList;
  +import java.util.List;
  +import java.util.ListIterator;
   
   /**
    * This is the value (key being the {@link GlobalTransaction}) in the transaction table
  @@ -32,22 +37,23 @@
    * </ul>
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    */
  -public class TransactionEntry {
  +public class TransactionEntry
  +{
   
      static Log log = LogFactory.getLog(TransactionEntry.class);
   
      /**
       * Local transaction
       */
  -   private Transaction ltx=null;
  +   private Transaction ltx = null;
      private Option option;
   
      /**
       * List<MethodCall> of modifications ({@link MethodCall}). They will be replicated on TX commit
       */
  -   private List<MethodCall> modification_list=new LinkedList<MethodCall>();
  +   private List<MethodCall> modification_list = new LinkedList<MethodCall>();
      private List<MethodCall> cl_mod_list = new LinkedList<MethodCall>();
   
      /**
  @@ -56,7 +62,7 @@
       * we have a corresponding entry in this list. A rollback will simply iterate over this list in
       * reverse to undo the modifications. Note that these undo-ops will never be replicated.
       */
  -   private List undo_list=new LinkedList();
  +   private List undo_list = new LinkedList();
   
      /**
       * LinkedHashSet<IdentityLock> of locks acquired by the transaction. We use
  @@ -73,29 +79,37 @@
      private List dummyNodesCreatedByCacheLoader;
   
      /**
  +    * List<Fqn> of nodes that have been removed by the transaction
  +    */
  +   private List<Fqn> removedNodes = new LinkedList<Fqn>();
  +
  +   /**
       * Constructs a new TransactionEntry.
       */
  -   public TransactionEntry() {
  +   public TransactionEntry()
  +   {
      }
   
      /**
       * Adds a modification to the modification list.
       */
  -   public void addModification(MethodCall m) {
  +   public void addModification(MethodCall m)
  +   {
         if (m == null) return;
         modification_list.add(m);
      }
   
       public void addCacheLoaderModification(MethodCall m)
       {
  -        if (m!=null) cl_mod_list.add(m);
  +      if (m != null) cl_mod_list.add(m);
       }
   
   
      /**
       * Returns all modifications.
       */
  -   public List<MethodCall> getModifications() {
  +   public List<MethodCall> getModifications()
  +   {
         return modification_list;
      }
   
  @@ -106,40 +120,67 @@
   
      /**
       * Adds an undo operation to the undo list.
  +    *
       * @see #undoOperations
       */
  -   public void addUndoOperation(MethodCall m) {
  +   public void addUndoOperation(MethodCall m)
  +   {
         undo_list.add(m);
      }
   
      /**
  +    * Adds the node that has been removed.
  +    *
  +    * @param fqn
  +    */
  +   public void addRemovedNode(Fqn fqn)
  +   {
  +      removedNodes.add(fqn);
  +   }
  +
  +   /**
  +    * Gets the list of removed nodes.
  +    */
  +   public List<Fqn> getRemovedNodes()
  +   {
  +      return new ArrayList(removedNodes);
  +   }
  +
  +
  +   /**
       * Returns the undo operations in use.
       * Note:  This list may be concurrently modified.
       */
  -   public List getUndoOperations() {
  +   public List getUndoOperations()
  +   {
         return undo_list;
      }
   
      /**
       * Sets the local transaction for this entry.
       */
  -   public void setTransaction(Transaction tx) {
  -      ltx=tx;
  +   public void setTransaction(Transaction tx)
  +   {
  +      ltx = tx;
      }
   
      /**
       * Returns a local transaction associated with this TransactionEntry
       */
  -   public Transaction getTransaction() {
  +   public Transaction getTransaction()
  +   {
         return ltx;
      }
   
      /**
       * Adds a lock to the end of the lock list, if it isn't already present.
       */
  -   public void addLock(NodeLock l) {
  -      if(l != null) {
  -         synchronized(locks) {
  +   public void addLock(NodeLock l)
  +   {
  +      if (l != null)
  +      {
  +         synchronized (locks)
  +         {
                locks.add(l);
            }
         }
  @@ -147,11 +188,15 @@
   
      /**
       * Add multiple locks to the lock list.
  +    *
       * @param newLocks Collection<IdentityLock>
       */
  -   public void addLocks(Collection newLocks) {
  -      if(newLocks != null) {
  -         synchronized(locks) {
  +   public void addLocks(Collection newLocks)
  +   {
  +      if (newLocks != null)
  +      {
  +         synchronized (locks)
  +         {
               locks.addAll(newLocks);
            }
         }
  @@ -162,8 +207,9 @@
       * 
       * @return a defensive copy of the internal data structure.
       */
  -   public List getLocks() {
  -      synchronized(locks)
  +   public List getLocks()
  +   {
  +      synchronized (locks)
         {
            return new ArrayList(locks);
         }
  @@ -171,11 +217,14 @@
   
      /**
       * Calls {@link #releaseAllLocksFIFO}.
  +    *
       * @deprecated don't think this is used anymore
       */
  -   public void releaseAllLocks(Object owner) {
  +   public void releaseAllLocks(Object owner)
  +   {
         releaseAllLocksFIFO(owner);
  -      synchronized (locks) {
  +      synchronized (locks)
  +      {
            locks.clear();
         }
      }
  @@ -184,13 +233,16 @@
       * Releases all locks held by the owner, in reverse order of creation.
       * Clears the list of locks held.
       */
  -   public void releaseAllLocksLIFO(Object owner) {
  +   public void releaseAllLocksLIFO(Object owner)
  +   {
   
  -      synchronized (locks) {
  +      synchronized (locks)
  +      {
            // Copying out to an array is faster than creating an ArrayList and iterating,
            // since list creation will just copy out to an array internally
            IdentityLock[] lockArray = (IdentityLock[]) locks.toArray(new IdentityLock[locks.size()]);
  -         for (int i = lockArray.length -1; i >= 0; i--) {
  +         for (int i = lockArray.length - 1; i >= 0; i--)
  +         {
                if (log.isTraceEnabled())
                {
                    log.trace("releasing lock for " + lockArray[i].getFqn() + " (" + lockArray[i] + ")");
  @@ -205,12 +257,15 @@
       * Releases all locks held by the owner, in order of creation.
       * Does not clear the list of locks held.
       */
  -   public void releaseAllLocksFIFO(Object owner) {
  +   public void releaseAllLocksFIFO(Object owner)
  +   {
         // I guess a copy would work as well
         // This seems fairly safe though
  -      synchronized (locks) {
  -         for (Iterator i = locks.iterator(); i.hasNext();) {
  -            IdentityLock lock = (IdentityLock)i.next();
  +      synchronized (locks)
  +      {
  +         for (Iterator i = locks.iterator(); i.hasNext();)
  +         {
  +            IdentityLock lock = (IdentityLock) i.next();
               lock.release(owner);
                if (log.isTraceEnabled())
                {
  @@ -223,27 +278,36 @@
      /**
       * Posts all undo operations to the TreeCache.
       */
  -   public void undoOperations(CacheSPI cache) {
  +   public void undoOperations(CacheSPI cache)
  +   {
         if (log.isTraceEnabled())
  +      {
            log.trace("undoOperations " + undo_list);
  +      }
         ArrayList l;
  -      synchronized (undo_list) {
  +      synchronized (undo_list)
  +      {
           l = new ArrayList(undo_list);
         }
  -      for (ListIterator i = l.listIterator(l.size()); i.hasPrevious();) {
  -         MethodCall undo_op = (MethodCall)i.previous();
  +      for (ListIterator i = l.listIterator(l.size()); i.hasPrevious();)
  +      {
  +         MethodCall undo_op = (MethodCall) i.previous();
            undo(undo_op, cache);
         }
      }
   
  -   private void undo(MethodCall undo_op, CacheSPI cache) {
  -      try {
  -          Object retval = undo_op.invoke(((TreeCacheProxyImpl)cache).getTreeCache());
  +   private void undo(MethodCall undo_op, CacheSPI cache)
  +   {
  +      try
  +      {
  +         Object retval = undo_op.invoke(((TreeCacheProxyImpl) cache).getTreeCache());
             if (retval instanceof Throwable)
             {
  -              throw (Throwable) retval;
  +            throw(Throwable) retval;
  +         }
             }
  -      } catch (Throwable t) {
  +      catch (Throwable t)
  +      {
            log.error("undo operation failed, error=" + t);
            log.trace(t, t);
         }
  @@ -252,13 +316,16 @@
      /**
       * Returns debug information about this transaction.
       */
  -   public String toString() {
  -      StringBuffer sb=new StringBuffer();
  +   public String toString()
  +   {
  +      StringBuffer sb = new StringBuffer();
         sb.append("\nmodification_list: ").append(modification_list);
  -      synchronized (undo_list) {
  +      synchronized (undo_list)
  +      {
            sb.append("\nundo_list: ").append(undo_list);
         }
  -      synchronized (locks) {
  +      synchronized (locks)
  +      {
            sb.append("\nlocks: ").append(locks);
         }
         return sb.toString();
  @@ -277,6 +344,7 @@
   
       /**
        * Sets a transaction-scope option override
  +    *
        * @param o
        */
       public void setOption(Option o)
  
  
  
  1.292     +195 -141  JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.291
  retrieving revision 1.292
  diff -u -b -r1.291 -r1.292
  --- TreeCache.java	8 Dec 2006 18:49:17 -0000	1.291
  +++ TreeCache.java	14 Dec 2006 17:18:47 -0000	1.292
  @@ -94,7 +94,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.291 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: TreeCache.java,v 1.292 2006/12/14 17:18:47 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -110,6 +110,7 @@
       * Root DataNode.
       */
      protected DataNode root;
  +
      {
         this.rootSpi = new TreeCacheProxyImpl(this);
         this.root = NodeFactory.getInstance().createRootDataNode(NodeFactory.NODE_TYPE_TREENODE, this.rootSpi);
  @@ -548,8 +549,10 @@
            // Yes -- cache is configured LOCAL but app doesn't know it -- Brian
            //throw new IllegalArgumentException("Cannot fetch partial state, targets are " + sources + " and stateId is " + stateId);
            if (log.isWarnEnabled())
  +         {
               log.warn("Cannot fetch partial state, targets are " + Arrays.asList(sources) + 
                     " and stateId is " + stateId);
  +         }
            return;
         }
   
  @@ -634,7 +637,7 @@
            initialiseCacheLoaderManager();
         }
   
  -      getRegionManager(); // make sure we create one
  +      getRegionManager();// make sure we create one
         createEvictionPolicy();
   
         switch (configuration.getCacheMode())
  @@ -648,7 +651,7 @@
            case INVALIDATION_SYNC:
               if (log.isDebugEnabled()) log.debug("cache mode is " + configuration.getCacheMode());
               if (channel != null)
  -            { // already started
  +            {// already started
                  log.info("channel is already running");
                  return;
               }
  @@ -657,7 +660,7 @@
               channel = getMultiplexerChannel();
   
               if (channel != null)
  -            { // mux channel
  +            {// mux channel
                  if (log.isDebugEnabled())
                  {
                     log.debug("Created Multiplexer Channel for cache cluster " + configuration.getClusterName() +
  @@ -681,14 +684,14 @@
               channel.setOpt(Channel.AUTO_GETSTATE, true);
               channel.setOpt(Channel.BLOCK, true);
   
  -/* Used for JMX jconsole for JDK5.0
  +            /* Used for JMX jconsole for JDK5.0
               ArrayList servers=MBeanServerFactory.findMBeanServer(null);
               if(servers == null || servers.size() == 0) {
                   throw new Exception("No MBeanServers found;" +
                                       "\nJmxTest needs to be run with an MBeanServer present, or inside JDK 5"); }
               MBeanServer server=(MBeanServer)servers.get(0);
               JmxConfigurator.registerChannel(channel, server, "JGroups:channel=" + channel.getChannelName() , true);
  -*/
  +            */
               // disp = new InactiveRegionAwareRpcDispatcher(channel, ml, this, this);
               disp = new RpcDispatcher(channel, ml, this, this);
               disp.setMarshaller(getMarshaller());
  @@ -790,7 +793,9 @@
   
         // start any eviction threads.
         if (regionManager.isUsingEvictions())
  +      {
   		  regionManager.startEvictionThread();
  +      }
   
         notifier.notifyCacheStarted(getCacheSPI());
         started = true;
  @@ -950,7 +955,9 @@
      public Address getCoordinator()
      {
         if (channel == null)
  +      {
            return null;
  +      }
   
         synchronized (members)
         {
  @@ -1074,7 +1081,7 @@
   
         if (!exists(subtree))
         {
  -         return;   // node does not exist. Maybe it has been recursively removed.
  +         return;// node does not exist. Maybe it has been recursively removed.
         }
   
         if (log.isTraceEnabled())
  @@ -1096,7 +1103,7 @@
                       tmp,
                       false,   // no undo ops
                       false,   // no nodeEvent
  -                    true);   // is an eviction
  +                    true);// is an eviction
            }
         }
   
  @@ -1260,7 +1267,7 @@
       */
      public Map _getData(Fqn fqn)
      {
  -      DataNode n = findNode(fqn);
  +      Node n = findNode(fqn);
         if (n == null) return null;
         return n.getNodeSPI().getRawData();
      }
  @@ -1293,7 +1300,7 @@
   
      public Set _getKeys(Fqn fqn) throws CacheException
      {
  -      DataNode n = findNode(fqn);
  +      Node n = findNode(fqn);
         if (n == null)
         {
            return null;
  @@ -1340,7 +1347,7 @@
                    append(sendNodeEvent).append("\")"));
         }
         if (sendNodeEvent) notifier.notifyNodeVisited(fqn, true);
  -      DataNode n = findNode(fqn);
  +      Node n = findNode(fqn);
         if (n == null)
   	  {
   		 log.trace("node not found");
  @@ -1378,7 +1385,7 @@
       */
      public Node peek(Fqn fqn)
      {
  -      return findInternal(fqn);
  +      return findInternal(fqn, true);
      }
   
      /**
  @@ -1407,7 +1414,7 @@
       */
      public boolean exists(Fqn fqn)
      {
  -      Node n = findInternal(fqn);
  +      Node n = findInternal(fqn, false);
         return n != null;
      }
   
  @@ -1416,7 +1423,7 @@
       *
       * @param fqn
       */
  -   private Node findInternal(Fqn fqn)
  +   private Node findInternal(Fqn fqn, boolean includeNodesMarkedAsRemoved)
      {
         if (fqn == null || fqn.size() == 0) return root;
         Node n = root;
  @@ -1429,8 +1436,12 @@
            {
               return null;
            }
  +         else if (!includeNodesMarkedAsRemoved && ((DataNode) n).isDeleted())
  +         {
  +            return null;
         }
  -      return (DataNode) n;
  +      }
  +      return n;
      }
   
   
  @@ -1454,7 +1465,7 @@
       */
      public boolean exists(Fqn fqn, Object key)
      {
  -      Node n = findInternal(fqn);
  +      Node n = findInternal(fqn, false);
         if (n == null)
         {
            return false;
  @@ -1620,9 +1631,9 @@
       * @throws CacheException If node doesn't exist, a NodeNotExistsException is throw. Other exceptions are
       * LockingException, TimeoutException and UpgradeException
       */
  -//   public void lock(Fqn fqn, Object owner, int lock_type, boolean lock_recursive) throws CacheException {
  -//
  -//   }
  +   //   public void lock(Fqn fqn, Object owner, int lock_type, boolean lock_recursive) throws CacheException {
  +   //
  +   //   }
   
      /**
       * Unlock a given node (or the entire subtree starting at this node)
  @@ -1632,9 +1643,9 @@
       * @param unlock_recursive If true, the entire subtree is unlocked, else only the given node
       * @param force Release the lock even if we're not the owner
       */
  -//   public void unlock(Fqn fqn, Object owner, boolean unlock_recursive, boolean force) {
  -//
  -//   }
  +   //   public void unlock(Fqn fqn, Object owner, boolean unlock_recursive, boolean force) {
  +   //
  +   //   }
   
      /**
       * Releases all locks for this node and the entire node subtree.
  @@ -1728,7 +1739,7 @@
   
      public Set _getChildrenNames(Fqn fqn) throws CacheException
      {
  -      DataNode n = findNode(fqn);
  +      Node n = findNode(fqn);
         if (n == null) return null;
         Set s = n.getChildrenNames();
         return s;
  @@ -1859,7 +1870,7 @@
         {
            return 0;
         }
  -      int count = 1; // for n
  +      int count = 1;// for n
         for (Node child : n.getNodeSPI().getChildrenMap().values())
         {
            count += numNodes(child);
  @@ -1886,7 +1897,7 @@
       */
      public int getNumberOfAttributes(Fqn fqn)
      {
  -      DataNode n = findNode(fqn);
  +      Node n = findNode(fqn);
         return numAttributes(n);
      }
   
  @@ -1990,7 +2001,7 @@
   
         if (mode == GroupRequest.GET_NONE)
         {
  -         return new ArrayList(); // async case
  +         return new ArrayList();// async case
         }
   
         if (log.isTraceEnabled())
  @@ -2101,6 +2112,7 @@
         Method method = getClass().getDeclaredMethod(method_name, types);
         return callRemoteMethods(members, method, args, synchronous, exclude_self, timeout);
      }
  +
      /* -------------------- End Remote method calls ------------------ */
   
      /* --------------------- Callbacks -------------------------- */
  @@ -2224,7 +2236,7 @@
            tx_table.addUndoOperation(tx, undo_op);
         }
   
  -      ((DataNode)n).put(data, (boolean)erase_contents);
  +      ((DataNode) n).put(data, (boolean) erase_contents);
   
         notifier.notifyNodeModified(fqn, false, rawData);
   
  @@ -2261,7 +2273,7 @@
   		  log.warn("using a map as a key in a map, did you mean to do that?");
   	  }
   
  -      DataNode n = findNodeCheck(tx, fqn);
  +      Node n = findNodeCheck(tx, fqn);
         Map rawData = n.getNodeSPI().getRawData();
         notifier.notifyNodeModified(fqn, true, rawData);
   
  @@ -2342,7 +2354,7 @@
              throws CacheException
      {
   
  -      DataNode n;
  +      Node n;
         Node parent_node;
         MethodCall undo_op = null;
   
  @@ -2351,6 +2363,26 @@
            log.trace("_remove(" + tx + ", \"" + fqn + "\", undo=" + create_undo_ops + ")");
         }
   
  +      // check if this is triggered by a rollback operation ...
  +      if (tx != null)
  +      {
  +         try
  +         {
  +            int status = getTransactionManager().getTransaction().getStatus();
  +            if (status == Status.STATUS_MARKED_ROLLBACK || status == Status.STATUS_ROLLEDBACK || status == Status.STATUS_ROLLING_BACK)
  +            {
  +               log.debug("This remove call is triggered by a transaction rollback, as a compensation operation.  Do a realRemove() instead.");
  +               realRemove(fqn, true);
  +               return;
  +            }
  +         }
  +         catch (Exception e)
  +         {
  +            // what do we do here?
  +            log.trace("Caught exception dealing with transaction manager", e);
  +         }
  +      }
  +
         if (fqn.size() == 0)
         {
            Set children = getChildrenNames(fqn);
  @@ -2398,20 +2430,28 @@
         parent_node = n.getParent();
   
         // remove subtree from parent
  -      parent_node.getNodeSPI().getChildrenMap().remove(n.getName());
  +      if (eviction || configuration.isNodeLockingOptimistic())
  +      {
  +         parent_node.getNodeSPI().getChildrenMap().remove(n.getFqn().getLast());
  +      }
  +      else
  +      {
  +         ((DataNode) n).markAsDeleted(true);
  +      }
  +
         if (eviction)
         {
            parent_node.getNodeSPI().setChildrenLoaded(false);
         }
   
         // release all locks for the entire subtree
  -      n.getNodeSPI().getLock().releaseAll(tx != null ? tx : (Object) Thread.currentThread());
  +      // n.getNodeSPI().getLock().releaseAll(tx != null ? tx : (Object) Thread.currentThread());
   
         // create a compensating method call (reverting the effect of
         // this modification) and put it into the TX's undo list.
         if (tx != null && create_undo_ops && !eviction)
         {
  -         undo_op = MethodCallFactory.create(MethodDeclarations.addChildMethodLocal, tx, parent_node.getFqn(), n.getName(), n, false);
  +         undo_op = MethodCallFactory.create(MethodDeclarations.addChildMethodLocal, tx, parent_node.getFqn(), n.getFqn().getLast(), n, false);
   
            // 1. put undo-op in TX' undo-operations list (needed to rollback TX)
            tx_table.addUndoOperation(tx, undo_op);
  @@ -2450,7 +2490,7 @@
      public Object _remove(GlobalTransaction tx, Fqn fqn, Object key, boolean create_undo_ops)
              throws CacheException
      {
  -      DataNode n = null;
  +      Node n = null;
         MethodCall undo_op = null;
         Object old_value = null;
   
  @@ -2529,7 +2569,7 @@
      public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent, boolean eviction, DataVersion version)
              throws CacheException
      {
  -      DataNode n = null;
  +      Node n = null;
         MethodCall undo_op = null;
   
         if (log.isTraceEnabled())
  @@ -2579,7 +2619,7 @@
            notifier.notifyNodeVisited(fqn, false);
         }
         else
  -      { // FIXME Bela did this so GUI view can refresh the view after node is evicted. But this breaks eviction policy, especially AOP!!!!
  +      {// FIXME Bela did this so GUI view can refresh the view after node is evicted. But this breaks eviction policy, especially AOP!!!!
            if (eviction)
            {
               notifier.notifyNodeEvicted(fqn, false);
  @@ -2606,7 +2646,7 @@
       */
      public void _evict(Fqn fqn) throws CacheException
      {
  -      if (!exists(fqn)) return;   // node does not exist. Maybe it has been recursively removed.
  +      if (!exists(fqn)) return;// node does not exist. Maybe it has been recursively removed.
         // use remove method now if there is a child node. Otherwise, it is removed
         boolean create_undo_ops = false;
         boolean sendNodeEvent = false;
  @@ -2634,7 +2674,7 @@
       */
      public void _evict(Fqn fqn, DataVersion version) throws CacheException
      {
  -      if (!exists(fqn)) return;  // node does not exist
  +      if (!exists(fqn)) return;// node does not exist
   
         boolean create_undo_ops = false;
         boolean sendNodeEvent = false;
  @@ -2659,13 +2699,13 @@
       * @param key
       * @throws CacheException
       */
  -//    public void _evict(Fqn fqn, Object key) throws CacheException {
  -//       if(!exists(fqn)) return;
  -//       boolean create_undo_ops = false;
  -//       boolean sendNodeEvent = false;
  -//       boolean eviction=true;
  -//       _removeData(null, fqn, create_undo_ops, sendNodeEvent, eviction);
  -//    }
  +   //    public void _evict(Fqn fqn, Object key) throws CacheException {
  +   //       if(!exists(fqn)) return;
  +   //       boolean create_undo_ops = false;
  +   //       boolean sendNodeEvent = false;
  +   //       boolean eviction=true;
  +   //       _removeData(null, fqn, create_undo_ops, sendNodeEvent, eviction);
  +   //    }
   
   
      /**
  @@ -2676,7 +2716,7 @@
      {
         if (log.isTraceEnabled())
         {
  -         log.trace("_addChild(\"" + parent_fqn +"\", \"" + child_name + "\", node=" + childNode + ")");
  +         log.trace("_addChild(\"" + parent_fqn + "\", \"" + child_name + "\", node=" + childNode + ")");
         }
   
         if (parent_fqn == null || child_name == null || childNode == null)
  @@ -2684,8 +2724,8 @@
            log.error("parent_fqn or child_name or childNode was null");
            return;
         }
  -      DataNode tmp = findNode(parent_fqn);
  -      if (tmp == null)
  +      DataNode parentNode = (DataNode) findNode(parent_fqn);
  +      if (parentNode == null)
         {
            log.warn("node " + parent_fqn + " not found");
            return;
  @@ -2693,7 +2733,9 @@
   
         Fqn fqn = new Fqn(parent_fqn, child_name);
         notifier.notifyNodeCreated(fqn, true);
  -      tmp.addChild(child_name, childNode);
  +      parentNode.addChild(child_name, childNode);
  +
  +      childNode.markAsDeleted(false, true);
   
         if (gtx != null && undoOps)
         {
  @@ -2820,11 +2862,11 @@
   
         // for now, perform a very simple series of getData calls.
   
  -      DataNode actualNode = findNode(fqn);
  +      Node actualNode = findNode(fqn);
         Fqn backupNodeFqn = null;
         if (actualNode == null && searchSubtrees)
         {
  -         DataNode backupSubtree = findNode(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
  +         Node backupSubtree = findNode(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
            if (backupSubtree != null)
            {
               Map children = backupSubtree.getNodeSPI().getChildrenMap();
  @@ -2878,7 +2920,7 @@
         NodeData data = new NodeData(BuddyManager.getActualFqn(node.getFqn()), node.getData());
         list.add(data);
         Map<Object, Node> children = node.getNodeSPI().getChildrenMap();
  -      for (Node childNode: children.values())
  +      for (Node childNode : children.values())
         {
            getNodeData(list, childNode);
         }
  @@ -2960,7 +3002,7 @@
       */
      public void _releaseAllLocks(Fqn fqn)
      {
  -      DataNode n;
  +      Node n;
   
         try
         {
  @@ -2996,7 +3038,7 @@
      {
         try
         {
  -         DataNode n = findNode(fqn);
  +         Node n = findNode(fqn);
            if (n == null) return null;
            return n.toString();
         }
  @@ -3182,13 +3224,13 @@
   
      private void moveFqns(Node node, Fqn newBase)
      {
  -      Fqn newFqn = new Fqn(newBase, ((TreeNode)node).getName());
  +      Fqn newFqn = new Fqn(newBase, ((TreeNode) node).getName());
         node.getNodeSPI().setFqn(newFqn);
      }
   
      class MessageListenerAdaptor implements ExtendedMessageListener
      {
  -      final Log my_log;   // Need this to run under jdk1.3
  +      final Log my_log;// Need this to run under jdk1.3
         final boolean trace;
   
         /**
  @@ -3245,13 +3287,13 @@
         {
            try
            {
  -//            // We use the lock acquisition timeout rather than the
  -//            // state transfer timeout, otherwise we'd never try
  -//            // to break locks before the requesting node gives up
  -//            return cache._getState(Fqn.fromString(SEPARATOR),
  -//               cache.getLockAcquisitionTimeout(),
  -//               true,
  -//               true);
  +            //            // We use the lock acquisition timeout rather than the
  +            //            // state transfer timeout, otherwise we'd never try
  +            //            // to break locks before the requesting node gives up
  +            //            return cache._getState(Fqn.fromString(SEPARATOR),
  +            //               cache.getLockAcquisitionTimeout(),
  +            //               true,
  +            //               true);
               // Until flush is in place, use the old mechanism
               // where we wait the full state retrieval timeout
               return _getState(Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
  @@ -3565,8 +3607,6 @@
   
      /**
       * Indicates that a channel has received a BLOCK event from FLUSH protocol.
  -    * 
  -    * 
       */
      public void block()
      {
  @@ -3643,12 +3683,12 @@
         Transaction tx;
   
         if ((tx = getLocalTransaction()) == null)
  -      { // no transaction is associated with the current thread
  +      {// no transaction is associated with the current thread
            return null;
         }
   
         if (!isValid(tx))
  -      { // we got a non-null transaction, but it is not active anymore
  +      {// we got a non-null transaction, but it is not active anymore
            int status = -1;
            try
            {
  @@ -3717,7 +3757,7 @@
         {
            if (t instanceof CacheException)
            {
  -            throw (CacheException) t;
  +            throw(CacheException) t;
            }
            throw new RuntimeException(t);
         }
  @@ -3744,7 +3784,7 @@
       * nodes have to be added to the transaction's {@link TransactionEntry}
       * field.<br>
       * When a lock is acquired on a node, a reference to the lock has to be 
  -    * {@link TransactionEntry#addLock(IdentityLock) added to the list of locked nodes} 
  +    * {@link TransactionEntry#addLock(org.jboss.cache.lock.NodeLock) added to the list of locked nodes}
       * in the {@link TransactionEntry}.
       * <p>This operation will also apply different locking to the tree nodes, depending on
       * <tt>operation_type</tt>. If it is <tt>read</tt> type, all nodes will be acquired with
  @@ -3754,7 +3794,7 @@
       * @param fqn Fully qualified name for the corresponding node.
       * @return DataNode
       */
  -   public DataNode findNode(Fqn fqn)
  +   public Node findNode(Fqn fqn)
      {
         try
         {
  @@ -3767,9 +3807,9 @@
         }
      }
   
  -   private DataNode findNodeCheck(GlobalTransaction tx, Fqn fqn)
  +   private Node findNodeCheck(GlobalTransaction tx, Fqn fqn)
      {
  -	  DataNode n = findNode(fqn);
  +      Node n = findNode(fqn);
         if (n == null)
         {
            String errStr = "node " + fqn + " not found (gtx=" + tx + ", caller=" + Thread.currentThread() + ")";
  @@ -3783,36 +3823,49 @@
      }
   
      /**
  -    * Finds a node given a fully qualified name and DataVersion.
  +    * Internal method; not to be used externally.
  +    *
  +    * @param f
       */
  -   private DataNode findNode(Fqn fqn, DataVersion version) throws CacheException
  +   public void realRemove(Fqn f, boolean skipMarkerCheck)
      {
  -      Node n, child_node = null;
  -      Object child_name;
  -
  -      if (fqn == null) return null;
  -      DataNode toReturn = null;
  -      if (fqn.isRoot())
  +      DataNode n = (DataNode) findInternal(f, true);
  +      if (n == null)
         {
  -         toReturn = root;
  +         return;
         }
  -      else
  +
  +      if (log.isDebugEnabled()) log.debug("Performing a real remove for node " + f + ", marked for removal.");
  +      if (skipMarkerCheck || n.isDeleted())
         {
  -         n = root;
  -         int size = fqn.size();
  -         for (int i = 0; i < size; i++)
  +         if (n.getFqn().isRoot())
            {
  -            child_name = fqn.get(i);
  -            child_node = n.getNodeSPI().getChildrenMap().get(child_name);
  -            if (child_node == null)
  +            // do not actually delete; just remove deletion marker
  +            n.markAsDeleted(false);
  +            // but now remove all children, since the call has been to remove("/")
  +            n.removeChildren();
  +         }
  +         else
               {
  -               return null;
  +            getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  +            n.getParent().removeChild(n.getFqn());
               }
  -            n = child_node;
            }
  -         toReturn = (DataNode) child_node;
  +      else
  +      {
  +         if (log.isDebugEnabled()) log.debug("Node " + f + " NOT marked for removal as expected, not removing!");
  +      }
         }
   
  +   /**
  +    * Finds a node given a fully qualified name and DataVersion.
  +    */
  +   private Node findNode(Fqn fqn, DataVersion version) throws CacheException
  +   {
  +      if (fqn == null) return null;
  +
  +      Node toReturn = findInternal(fqn, false);
  +
         if (version != null)
         {
            // we need to check the version of the data node...
  @@ -3826,7 +3879,6 @@
               // we have a versioning problem; throw an exception!
               throw new CacheException("Unable to validate versions.");
            }
  -
         }
         return toReturn;
      }
  @@ -3834,7 +3886,9 @@
      public synchronized RegionManager getRegionManager()
      {
         if (regionManager == null)
  +      {
            regionManager = new RegionManager(this);
  +      }
         return regionManager;
      }
   
  
  
  
  1.30      +63 -45    JBossCache/src/org/jboss/cache/TreeNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeNode.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- TreeNode.java	8 Dec 2006 19:03:56 -0000	1.29
  +++ TreeNode.java	14 Dec 2006 17:18:47 -0000	1.30
  @@ -13,20 +13,20 @@
    * hashmap of general data.  If the node is created in a replicated cache, the
    * relative and fully qualified name, and the keys and values of the hashmap
    * must be serializable.
  - * <p>
  + * <p/>
    * The current version supports different levels of transaction locking such as
    * simple locking ({@link org.jboss.cache.lock.IsolationLevel#SERIALIZABLE}, or Read/Write lock with
    * upgrade ( {@link org.jboss.cache.lock.IsolationLevel#REPEATABLE_READ}) --that is the read lock will be
    * automatically upgraded to write lock when the same owner intends to modify
    * the data after read.
  - * <p>
  + * <p/>
    * Implementations may not necessarily be <em>not</em> synchronized, so access
    * to instances of  need to be run under an isolation level above NONE.
    *
    * @author Bela Ban March 25 2003
    * @author Ben Wang
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  - * @version $Revision: 1.29 $
  + * @version $Revision: 1.30 $
    */
   
   public interface TreeNode extends Node
  @@ -45,6 +45,7 @@
       /**
        * Puts the contents of a map into this node.
        * Optionally erases the existing contents.
  +    *
        * @param eraseData true to erase the existing contents
        */
       void put(Map data, boolean eraseData);
  @@ -75,4 +76,21 @@
        */
       void addChild(Object child_name, Node n);
   
  +   /**
  +    * Tests whether a node has been marked as deleted.
  +    */
  +   public boolean isDeleted();
  +
  +   /**
  +    * Sets the deletion marker on the node (but not on children)
  +    *
  +    * @param isDeleted
  +    */
  +   public void markAsDeleted(boolean isDeleted);
  +
  +   /**
  +    * Sets the deletion marker on the node, with the option to set this on children as well.
  +    */
  +   public void markAsDeleted(boolean isDeleted, boolean recursive);
  +
   }
  
  
  
  1.23      +27 -1     JBossCache/src/org/jboss/cache/AbstractNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/AbstractNode.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- AbstractNode.java	20 Nov 2006 03:53:53 -0000	1.22
  +++ AbstractNode.java	14 Dec 2006 17:18:47 -0000	1.23
  @@ -3,6 +3,8 @@
    */
   package org.jboss.cache;
   
  +import java.util.Map;
  +
   /**
    * Base class for {@link NodeImpl}.
    *
  @@ -10,4 +12,28 @@
    */
   public abstract class AbstractNode implements DataNode, NodeSPI
   {
  +   protected boolean deleted;
  +   protected Map<Object, AbstractNode> children;
  +
  +   public boolean isDeleted()
  +   {
  +      return deleted;
  +   }
  +
  +   public void markAsDeleted(boolean marker)
  +   {
  +      markAsDeleted(marker, false);
  +   }
  +
  +   public void markAsDeleted(boolean marker, boolean recursive)
  +   {
  +      deleted = marker;
  +      if (recursive && children != null)
  +      {
  +         for (AbstractNode child : children.values())
  +         {
  +            child.markAsDeleted(marker, true);
  +         }
  +      }
  +   }
   }
  
  
  
  1.16      +24 -7     JBossCache/src/org/jboss/cache/RegionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/RegionManager.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- RegionManager.java	27 Nov 2006 04:49:46 -0000	1.15
  +++ RegionManager.java	14 Dec 2006 17:18:47 -0000	1.16
  @@ -136,8 +136,10 @@
            // first test if the default region has been defined.  If not, and if eviction regions
            // are in use, throw an exception since it is required.
            if (isUsingEvictions() && !regionsRegistry.containsKey(Fqn.ROOT))
  +         {
               throw new RuntimeException("No default eviction region defined!");
         }
  +      }
   
         // else try and find a parent which has a defined region, may return null if nothing is defined.
         Region r = null;
  @@ -262,9 +264,11 @@
                  r.setActive(true);
                  // FIXME - persistent state transfer counts too!
                  if (treeCache.getConfiguration().isFetchInMemoryState())
  +               {
                     activateRegion(r.getFqn().toString());
               }
            }
  +         }
            else if (defaultInactive)
            {
               // "Active" region is not the default, so create a region
  @@ -272,9 +276,11 @@
               r.setActive(true);
               // FIXME - persistent state transfer counts too!
               if (treeCache.getConfiguration().isFetchInMemoryState())
  +            {
                  activateRegion(r.getFqn().toString());
            }
         }
  +      }
         catch (Exception e)
         {
            throw new RuntimeException(e);
  @@ -302,7 +308,7 @@
         Fqn fqn = Fqn.fromString(subtreeFqn);
   
         // Check whether the node already exists and has data
  -      DataNode subtreeRoot = treeCache.findNode(fqn);
  +      Node subtreeRoot = treeCache.findNode(fqn);
   
         /*
          * Commented out on Nov 16,2006 Manik&Vladimir 
  @@ -355,8 +361,10 @@
               if (groupMembers.length < 2)
               {
                  if (log.isDebugEnabled())
  +               {
                     log.debug("No nodes able to give state");
               }
  +            }
               else
               {
                  treeCache.fetchPartialState(groupMembers, subtreeRoot.getFqn());
  @@ -431,7 +439,7 @@
       *                                     managed (either by activate/inactiveRegion()
       *                                     or by registerClassLoader())
       * @throws CacheException              if there is a problem evicting nodes
  -    * @throws IllegalStateException       if {@link Configuration#isUseRegionBasedMarshalling()} is <code>false</code>
  +    * @throws IllegalStateException       if {@link org.jboss.cache.config.Configuration#isUseRegionBasedMarshalling()} is <code>false</code>
       */
      public void inactivateRegion(String subtreeFqn) throws CacheException
      {
  @@ -623,9 +631,11 @@
                  // FIXME - we should always clean up; otherwise stale data 
                  // is in memory!
                  if (treeCache.getConfiguration().isFetchInMemoryState())
  +               {
                     inactivateRegion(fqn.toString());
               }
            }
  +         }
            else if (!defaultInactive)
            {
               region = getRegion(fqn, true);
  @@ -633,9 +643,11 @@
               // FIXME - we should always clean up; otherwise stale data 
               // is in memory!
               if (treeCache.getConfiguration().isFetchInMemoryState())
  +            {
                  inactivateRegion(fqn.toString());
            }
         }
  +      }
         catch (Exception e)
         {
            throw new RuntimeException(e);
  @@ -687,7 +699,9 @@
         List<Region> regions = new ArrayList<Region>();
   
         for (Region r : regionsRegistry.values())
  +      {
            if (r.getEvictionPolicy() != null && evictionTimerTask.isRegionRegisteredForProcessing(r)) regions.add(r);
  +      }
   
         Collections.sort(regions);
   
  @@ -726,7 +740,9 @@
            if (fqn.equals(DEFAULT_REGION))
            {
               if (setDefault)
  +            {
                  throw new ConfigurationException("A default region for evictions has already been set for this cache");
  +            }
               if (log.isTraceEnabled()) log.trace("Applying settings for " + DEFAULT_REGION + " to Fqn.ROOT");
               fqn = Fqn.ROOT;
               setDefault = true;
  @@ -755,7 +771,8 @@
         return sb.toString();
      }
      
  -   public String toString() {
  +   public String toString()
  +   {
         return "RegionManager " + dumpRegions();
      }
   }
  @@ -774,7 +791,7 @@
    * @author Ben Wang 02-2004
    * @author Daniel Huang (dhuang at jboss.org)
    * @author Brian Stansberry
  - * @version $Id: RegionManager.java,v 1.15 2006/11/27 04:49:46 genman Exp $
  + * @version $Id: RegionManager.java,v 1.16 2006/12/14 17:18:47 msurtani Exp $
    */
   /*public class ERegionManager
   {
  
  
  
  1.25      +42 -15    JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- NodeImpl.java	12 Dec 2006 15:08:05 -0000	1.24
  +++ NodeImpl.java	14 Dec 2006 17:18:47 -0000	1.25
  @@ -31,7 +31,7 @@
   /**
    * Basic data node class.
    */
  -public class NodeImpl implements DataNode, Node, NodeSPI, Serializable
  +public class NodeImpl extends AbstractNode implements Node, Serializable
   {
   
      private static final long serialVersionUID = -8200950905894940931L;
  @@ -73,11 +73,6 @@
      private Fqn fqn;
   
      /**
  -    * Map of children names to children.
  -    */
  -   private Map<Object, Node> children;
  -
  -   /**
       * Map of general data keys to values.
       */
      private Map data;
  @@ -180,12 +175,12 @@
         {
            if (getFqn().isRoot())
            {
  -            children = new ConcurrentHashMap<Object, Node>(64, .5f, 16);
  +            children = new ConcurrentHashMap<Object, AbstractNode>(64, .5f, 16);
            }
            else
            {
               // Less segments to save memory
  -            children = new ConcurrentHashMap<Object, Node>(4, .75f, 4);
  +            children = new ConcurrentHashMap<Object, AbstractNode>(4, .75f, 4);
            }
         }
         return children;
  @@ -343,19 +338,20 @@
   
      private Node getOrCreateChild(Object child_name, GlobalTransaction gtx, boolean createIfNotExists)
      {
  -      DataNode child;
  +
  +      NodeImpl child;
         if (child_name == null)
         {
            throw new IllegalArgumentException("null child name");
         }
   
  -      child = (DataNode) children().get(child_name);
  +      child = (NodeImpl) children().get(child_name);
         if (createIfNotExists && child == null)
         {
            // construct the new child outside the synchronized block to avoid
            // spending any more time than necessary in the synchronized section
            Fqn child_fqn = new Fqn(this.fqn, child_name);
  -         DataNode newChild = (DataNode) NodeFactory.getInstance().createNode(child_name, child_fqn, this, null, cache);
  +         NodeImpl newChild = (NodeImpl) NodeFactory.getInstance().createNode(child_name, child_fqn, this, null, cache);
            if (newChild == null)
            {
               throw new IllegalStateException();
  @@ -632,8 +628,25 @@
   
      public void removeChild(Fqn fqn)
      {
  +      if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
  +      {
  +         if (fqn.size() == 1)
  +         {
  +            children.remove(fqn.getName());
  +         }
  +         else
  +         {
  +            Node c = getChild(fqn);
  +            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  +            c.getParent().removeChild(new Fqn(fqn.getName()));
  +         }
  +         cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +      }
  +      else
  +      {
         cache.removeChild(new Fqn(getFqn(), fqn));
      }
  +   }
   
      public Map<Object, Node> getChildrenMap()
      {
  @@ -752,7 +765,7 @@
         }
   
         // process children
  -      for (Map.Entry<Object, Node> me : children.entrySet())
  +      for (Map.Entry<Object, AbstractNode> me : children.entrySet())
         {
            NodeSPI n = me.getValue().getNodeSPI();
            Fqn cfqn = new Fqn(fqn, me.getKey());
  @@ -780,7 +793,7 @@
   
      public Set<Node> getChildren()
      {
  -      return new ChildrenNodes();
  +      return new ChildrenNodes<Node>(false);
      }
   
      public synchronized Map<Object, Object> getRawData()
  @@ -839,7 +852,9 @@
      {
         // TODO remove this
         if (!dataLoaded && !data().isEmpty())
  +      {
            log.warn("data exists, but setDataLoaded(false)", new Throwable());
  +      }
   
         this.dataLoaded = dataLoaded;
      }
  @@ -907,8 +922,20 @@
   
      }
   
  -   private class ChildrenNodes extends AbstractSet
  +   private class ChildrenNodes<T> extends AbstractSet
  +   {
  +      private boolean includeDeleted;
  +
  +      public ChildrenNodes(boolean includeDeleted)
      {
  +         this.includeDeleted = includeDeleted;
  +      }
  +
  +      @Override
  +      public boolean contains(Object o)
  +      {
  +         return children != null && children.containsValue(o);
  +      }
   
         @Override
         public Iterator iterator()
  
  
  


From msurtani at jboss.com  Thu Dec 14 12:18:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 12:18:48 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1GuuEK-000748-5a@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 12:18:48

  Modified:    tests/functional/org/jboss/cache/transaction  
                        IsolationLevelReadCommittedTest.java
                        TransactionTest.java
  Log:
  The beginnings of porting JBCACHE-871 and JBCACHE-875 as well as rearranging the Node/Cache object model to something sensible
  
  Revision  Changes    Path
  1.10      +17 -19    JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelReadCommittedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- IsolationLevelReadCommittedTest.java	22 Nov 2006 04:55:44 -0000	1.9
  +++ IsolationLevelReadCommittedTest.java	14 Dec 2006 17:18:48 -0000	1.10
  @@ -6,11 +6,9 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -
   import org.jboss.cache.Cache;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.Configuration.CacheMode;
   import org.jboss.cache.factories.DefaultCacheFactory;
  @@ -25,7 +23,7 @@
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  - * @version $Id: IsolationLevelReadCommittedTest.java,v 1.9 2006/11/22 04:55:44 bstansberry Exp $
  + * @version $Id: IsolationLevelReadCommittedTest.java,v 1.10 2006/12/14 17:18:48 msurtani Exp $
    */
   
   public class IsolationLevelReadCommittedTest extends TestCase
  @@ -101,7 +99,7 @@
                  tx = startTransaction();
   
                  // Read the value, thus acquiring a read lock on FQN
  -               assertEquals(VALUE, cache.get(FQN, KEY));
  +               assertEquals("Could not read node with expected value!", VALUE, cache.get(FQN, KEY));
   
                  writerCanWrite.release();
   
  @@ -110,15 +108,13 @@
                  readerCanRead.acquire();
   
                  // I shouldn't be able to see the "dirty" value
  -               assertEquals("thread w/ read lock " +
  -                       "can see subsequent uncommitted changes",
  -                       VALUE, cache.get(FQN, KEY));
  +               assertEquals("thread w/ read lock can see subsequent uncommitted changes!!", VALUE, cache.get(FQN, KEY));
   
                  // let the writer know it can rollback
                  writerCanRollback.release();
   
                  // I should still be able to see the "clean" value
  -               assertEquals(VALUE, cache.get(FQN, KEY));
  +               assertEquals("Could not read node with expected value!", VALUE, cache.get(FQN, KEY));
               }
               catch (AssertionFailedError e)
               {
  @@ -133,7 +129,9 @@
               {
                  System.out.println("reader thread exits");
                  if (tx != null)
  +               {
                     try { tx.commit(); } catch (Exception e) {}
  +               }
                  writerCanWrite.release();
                  writerCanRollback.release();
                  readerDone.release();
  @@ -253,7 +251,7 @@
               {
                  writerError = e;
               }
  -            catch(Throwable t)
  +            catch (Throwable t)
               {
                  t.printStackTrace();
                  writerFailed = true;
  
  
  
  1.19      +150 -152  JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- TransactionTest.java	6 Dec 2006 12:46:53 -0000	1.18
  +++ TransactionTest.java	14 Dec 2006 17:18:48 -0000	1.19
  @@ -38,7 +38,7 @@
    * Tests transactional access to a local TreeCache.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: TransactionTest.java,v 1.18 2006/12/06 12:46:53 msurtani Exp $
  + * @version $Id: TransactionTest.java,v 1.19 2006/12/14 17:18:48 msurtani Exp $
    */
   public class TransactionTest extends TestCase
   {
  @@ -109,26 +109,19 @@
      }
   
   
  -   public void testPutTx()
  -   {
  -      try
  +   public void testPutTx() throws Exception
         {
            tx.begin();
  -         cache.put("/a/b/c", "age", new Integer(38));
  +      cache.put("/a/b/c", "age", 38);
            // the tx interceptor should know that we're in the same tx.
  -         assertEquals(new Integer(38), cache.get("/a/b/c", "age"));
  +      assertEquals(cache.get("/a/b/c", "age"), new Integer(38));
   
  -         cache.put("/a/b/c", "age", new Integer(39));
  +      cache.put("/a/b/c", "age", 39);
            tx.commit();
   
            // This test is done outside the TX, it wouldn't work if someone else
            // modified "age". This works because we're the only TX running.
  -         assertEquals(new Integer(39), cache.get("/a/b/c", "age"));
  -      }
  -      catch (Throwable t)
  -      {
  -         fail(t.toString());
  -      }
  +      assertEquals(cache.get("/a/b/c", "age"), new Integer(39));
      }
   
   
  @@ -155,7 +148,9 @@
   
      public void testGetAfterRemovalRollback() throws Exception
      {
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         cache.put("/a/b", null);
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         assertTrue(cache.exists("/a/b"));
         tx.begin();
         cache.remove("/a/b");
  @@ -409,7 +404,8 @@
            cache.put("/a/b/c", null);
            tx.begin();
            gtx = cache.getCurrentTransaction();
  -         cache.remove("/a/b/c"); // need to remove the node, not just the data in the node.
  +         cache.remove("/a/b/c");// need to remove the node, not just the data in the node.
  +         System.out.println("Locks: " + cache.printLockInfo());
            assertLocked(gtx, "/a", false);
            assertLocked(gtx, "/a/b", true);
            assertLocked(gtx, "/a/b/c", true);
  @@ -431,7 +427,7 @@
            cache.put("/a/b/c", null);
            tx.begin();
            gtx = cache.getCurrentTransaction();
  -         cache.remove("/a/b"); // need to remove the node, not just the data in the node.
  +         cache.remove("/a/b");// need to remove the node, not just the data in the node.
            assertLocked(gtx, "/a", true);
            assertLocked(gtx, "/a/b", true);
            assertLocked(gtx, "/a/b/c", true);
  @@ -576,10 +572,12 @@
   
      private void assertLocked(Object owner, String fqn, boolean write_locked) throws Exception
      {
  -      NodeImpl n = cache.get(fqn);
  +      NodeImpl n = (NodeImpl) cache.peek(Fqn.fromString(fqn));
         IdentityLock lock = n.getLock();
         if (owner == null)
  +      {
            owner = Thread.currentThread();
  +      }
         assertTrue("node " + fqn + " is not locked", lock.isLocked());
         if (write_locked)
         {
  @@ -606,7 +604,7 @@
            // start a new tx
            cache.getTransactionManager().begin();
            t2 = cache.getTransactionManager().getTransaction();
  -         cache.get("/a/b/c"); // should fail
  +         cache.get("/a/b/c");// should fail
            t2.commit();
            fail("Should not be able to get a hold of /a/b/c until the deleting tx completes");
         }
  @@ -637,7 +635,7 @@
               try
               {
                  System.out.println(cache.printLockInfo());
  -               cache.get("/a/b/c"); // should fail
  +               cache.get("/a/b/c");// should fail
   
                  fail("Should not be able to get a hold of /a/b/c until the deleting tx completes");
               }
  @@ -793,7 +791,7 @@
      {
         try
         {
  -         cache.put("/bela/ban", null); // create a node /bela/ban with a null map
  +         cache.put("/bela/ban", null);// create a node /bela/ban with a null map
            tx.begin();
            Map m = new HashMap();
            m.put("name", "Bela");
  @@ -855,7 +853,7 @@
      {
         try
         {
  -         cache.put("/bela/ban", null); // /bela/ban needs to exist
  +         cache.put("/bela/ban", null);// /bela/ban needs to exist
            tx.begin();
            cache.put("/bela/ban", "name", "Bela");
            assertEquals("Bela", cache.get("/bela/ban", "name"));
  @@ -874,7 +872,7 @@
      {
         try
         {
  -         cache.put("/bela/ban", "name", "Bela"); // /bela/ban needs to exist
  +         cache.put("/bela/ban", "name", "Bela");// /bela/ban needs to exist
            tx.begin();
            cache.put("/bela/ban", "name", "Michelle");
            assertEquals("Michelle", cache.get("/bela/ban", "name"));
  @@ -906,7 +904,7 @@
         cache.remove(FQN);
         cache.put(FQN, "entry", "rollback");
         tx.rollback();
  -      assertEquals("Node should keep the commited value", "commit", cache.get(FQN).get("entry")); // THIS FAILS
  +      assertEquals("Node should keep the commited value", "commit", cache.get(FQN).get("entry"));// THIS FAILS
      }
   
   
  @@ -924,7 +922,7 @@
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache.start();
   
  -      cache.put("/1/2/3/4", "foo", "bar"); // no TX, no locks held after put() returns
  +      cache.put("/1/2/3/4", "foo", "bar");// no TX, no locks held after put() returns
   
   
         class Reader extends Thread
  @@ -942,11 +940,11 @@
               {
                  thread_tx = startTransaction();
                  log("acquiring RL");
  -               cache.get("/1/2/3", "foo"); // acquires RLs on all 3 nodes
  +               cache.get("/1/2/3", "foo");// acquires RLs on all 3 nodes
                  log("RL acquired successfully");
                  sleep(2000);
                  log("committing TX");
  -               thread_tx.commit(); // releases RLs
  +               thread_tx.commit();// releases RLs
                  log("committed TX");
               }
               catch (Exception e)
  @@ -969,10 +967,10 @@
            {
               try
               {
  -               sleep(500); // give the Reader a chance to acquire the RLs
  +               sleep(500);// give the Reader a chance to acquire the RLs
                  thread_tx = startTransaction();
                  log("acquiring WL");
  -               cache.put("/1", "foo", "bar2"); // needs to acquired a WL on /1
  +               cache.put("/1", "foo", "bar2");// needs to acquired a WL on /1
                  log("acquired WL successfully");
                  log("committing TX");
                  thread_tx.commit();
  @@ -1046,126 +1044,126 @@
         System.out.println(Thread.currentThread().getName() + ": " + msg);
      }
   
  -//   public void testRaceConditionOnNotInCacheCondition() throws Exception {
  -//      cache.setIsolationLevel(IsolationLevel.SERIALIZABLE);
  -//
  -//      tx.begin();
  -//      // we now read the null entry, and decide that we need to go do something.
  -//
  -//      Object cachedObject=cache.get("/SecurityInfo/", Integer.toString(23));
  -//      assertNull(cachedObject); // we expect this in this test
  -//
  -//      /**
  -//       * now start another Thread to go do the same action, looking for the value, but it SHOULD
  -//       * see the result of the main thread put once it commits.
  -//       */
  -//      Thread thread=new Thread(new Runnable() {
  -//         UserTransaction tx2=(UserTransaction)new InitialContext(p).lookup("UserTransaction");
  -//         public void run() {
  -//            try {
  -//               tx2.begin();
  -//               log("OtherThread: inspecting the cache");
  -//               Object cachedObject=cache.get("/SecurityInfo", Integer.toString(23));
  -//
  -//               log("OtherThread: read from cache: " + cachedObject);
  -//               Thread.sleep(3000);
  -//
  -//               cachedObject=cache.get("/SecurityInfo", Integer.toString(23));
  -//               log("OtherThread: read(second time) from cache:" + cachedObject);
  -//
  -//               /**
  -//                * This should really fail because the other thread should actually have put something else there.
  -//                */
  -//               cache.put("/SecurityInfo", Integer.toString(23), "HelloWorldDIRTY!");
  -//
  -//               log("OtherThread: Has put something in the cache tha shouldn't be there");
  -//            }
  -//            catch(Exception e) {
  -//               e.printStackTrace();
  -//            }
  -//            finally {
  -//               if(tx2 != null)
  -//                  try {tx2.commit();} catch(Exception e) {e.printStackTrace();}
  -//            }
  -//            log("OthreThread: exiting");
  -//
  -//         }
  -//      });
  -//
  -//      thread.start();
  -//      log("MainThread is now waiting a little bit");
  -//      Thread.sleep(2000); // wait long enough for the other thread to block a bit. Simulate a DB read
  -//      log("MainThread is now putting something in the cache");
  -//      cache.put("/SecurityInfo", Integer.toString(23), "HelloWorld");
  -//      Thread.sleep(2000); // wait long enough for the other thread to block a bit. Simulate a DB read
  -//      tx.commit();
  -//      log("MainThread: committed");
  -//      thread.join(30000);
  -//
  -//      log(cache.get("/SecurityInfo", Integer.toString(23)).toString());
  -//   }
  -
  -//   public void testConcurrentReadsWithSerializableIsolationLevel() throws CacheException, InterruptedException {
  -//      final long TIMEOUT=5000;
  -//      cache.setIsolationLevel(IsolationLevel.SERIALIZABLE);
  -//      cache.put("/testfqn", "testkey", "testvalue"); // add initial value, to be read by threads
  -//      Reader r1, r2;
  -//      r1=new Reader("reader1", 3000);
  -//      r2=new Reader("reader2", 0);
  -//      r1.start();
  -//      pause(100); // make sure thread1 starts and acquires the lock before thread2
  -//      r2.start();
  -//      r1.join(TIMEOUT);
  -//      r2.join(TIMEOUT);
  -//   }
  -//
  -//   class Reader extends Thread {
  -//      long timeout;
  -//
  -//      public Reader(String name, long timeout) {
  -//         super(name);
  -//         this.timeout=timeout;
  -//      }
  -//
  -//      public void run() {
  -//         UserTransaction trans=null;
  -//         try {
  -//            trans=(UserTransaction)new InitialContext(p).lookup("UserTransaction");
  -//            trans.begin();
  -//            Object retval=null;
  -//            log2("accessing tree");
  -//            retval=cache.get("testfqn", "testkey");
  -//            log2("retval: " + retval);
  -//            if(timeout > 0) {
  -//               log2("sleeping for " + timeout + " ms");
  -//               pause(timeout);
  -//            }
  -//         }
  -//         catch(Exception e) {
  -//            e.printStackTrace();
  -//         }
  -//         finally {
  -//            try {trans.commit();} catch(Throwable t) {}
  -//            log2("done");
  -//         }
  -//      }
  -//   }
  -
  -//   private void pause(long timeout) {
  -//      try {
  -//         Thread.sleep(timeout);
  -//      }
  -//      catch(InterruptedException e) {
  -//      }
  -//   }
  -//
  -//   private void log(String msg) {
  -//      System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
  -//   }
  -//
  -//   private void log2(String msg) {
  -//      System.out.println("-- [" + System.currentTimeMillis() + " " + Thread.currentThread() + "]: " + msg);
  -//   }
  +   //   public void testRaceConditionOnNotInCacheCondition() throws Exception {
  +   //      cache.setIsolationLevel(IsolationLevel.SERIALIZABLE);
  +   //
  +   //      tx.begin();
  +   //      // we now read the null entry, and decide that we need to go do something.
  +   //
  +   //      Object cachedObject=cache.get("/SecurityInfo/", Integer.toString(23));
  +   //      assertNull(cachedObject); // we expect this in this test
  +   //
  +   //      /**
  +   //       * now start another Thread to go do the same action, looking for the value, but it SHOULD
  +   //       * see the result of the main thread put once it commits.
  +   //       */
  +   //      Thread thread=new Thread(new Runnable() {
  +   //         UserTransaction tx2=(UserTransaction)new InitialContext(p).lookup("UserTransaction");
  +   //         public void run() {
  +   //            try {
  +   //               tx2.begin();
  +   //               log("OtherThread: inspecting the cache");
  +   //               Object cachedObject=cache.get("/SecurityInfo", Integer.toString(23));
  +   //
  +   //               log("OtherThread: read from cache: " + cachedObject);
  +   //               Thread.sleep(3000);
  +   //
  +   //               cachedObject=cache.get("/SecurityInfo", Integer.toString(23));
  +   //               log("OtherThread: read(second time) from cache:" + cachedObject);
  +   //
  +   //               /**
  +   //                * This should really fail because the other thread should actually have put something else there.
  +   //                */
  +   //               cache.put("/SecurityInfo", Integer.toString(23), "HelloWorldDIRTY!");
  +   //
  +   //               log("OtherThread: Has put something in the cache tha shouldn't be there");
  +   //            }
  +   //            catch(Exception e) {
  +   //               e.printStackTrace();
  +   //            }
  +   //            finally {
  +   //               if(tx2 != null)
  +   //                  try {tx2.commit();} catch(Exception e) {e.printStackTrace();}
  +   //            }
  +   //            log("OthreThread: exiting");
  +   //
  +   //         }
  +   //      });
  +   //
  +   //      thread.start();
  +   //      log("MainThread is now waiting a little bit");
  +   //      Thread.sleep(2000); // wait long enough for the other thread to block a bit. Simulate a DB read
  +   //      log("MainThread is now putting something in the cache");
  +   //      cache.put("/SecurityInfo", Integer.toString(23), "HelloWorld");
  +   //      Thread.sleep(2000); // wait long enough for the other thread to block a bit. Simulate a DB read
  +   //      tx.commit();
  +   //      log("MainThread: committed");
  +   //      thread.join(30000);
  +   //
  +   //      log(cache.get("/SecurityInfo", Integer.toString(23)).toString());
  +   //   }
  +
  +   //   public void testConcurrentReadsWithSerializableIsolationLevel() throws CacheException, InterruptedException {
  +   //      final long TIMEOUT=5000;
  +   //      cache.setIsolationLevel(IsolationLevel.SERIALIZABLE);
  +   //      cache.put("/testfqn", "testkey", "testvalue"); // add initial value, to be read by threads
  +   //      Reader r1, r2;
  +   //      r1=new Reader("reader1", 3000);
  +   //      r2=new Reader("reader2", 0);
  +   //      r1.start();
  +   //      pause(100); // make sure thread1 starts and acquires the lock before thread2
  +   //      r2.start();
  +   //      r1.join(TIMEOUT);
  +   //      r2.join(TIMEOUT);
  +   //   }
  +   //
  +   //   class Reader extends Thread {
  +   //      long timeout;
  +   //
  +   //      public Reader(String name, long timeout) {
  +   //         super(name);
  +   //         this.timeout=timeout;
  +   //      }
  +   //
  +   //      public void run() {
  +   //         UserTransaction trans=null;
  +   //         try {
  +   //            trans=(UserTransaction)new InitialContext(p).lookup("UserTransaction");
  +   //            trans.begin();
  +   //            Object retval=null;
  +   //            log2("accessing tree");
  +   //            retval=cache.get("testfqn", "testkey");
  +   //            log2("retval: " + retval);
  +   //            if(timeout > 0) {
  +   //               log2("sleeping for " + timeout + " ms");
  +   //               pause(timeout);
  +   //            }
  +   //         }
  +   //         catch(Exception e) {
  +   //            e.printStackTrace();
  +   //         }
  +   //         finally {
  +   //            try {trans.commit();} catch(Throwable t) {}
  +   //            log2("done");
  +   //         }
  +   //      }
  +   //   }
  +
  +   //   private void pause(long timeout) {
  +   //      try {
  +   //         Thread.sleep(timeout);
  +   //      }
  +   //      catch(InterruptedException e) {
  +   //      }
  +   //   }
  +   //
  +   //   private void log(String msg) {
  +   //      System.out.println("-- [" + Thread.currentThread() + "]: " + msg);
  +   //   }
  +   //
  +   //   private void log2(String msg) {
  +   //      System.out.println("-- [" + System.currentTimeMillis() + " " + Thread.currentThread() + "]: " + msg);
  +   //   }
   
   
      public static Test suite() throws Exception
  
  
  


From msurtani at jboss.com  Thu Dec 14 12:18:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 12:18:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer      ...
Message-ID: <E1GuuEK-00074R-By@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 12:18:48

  Modified:    src/org/jboss/cache/statetransfer     
                        StateTransferGenerator.java
                        StateTransferManager.java
                        DefaultStateTransferGenerator.java
                        StateTransferIntegrator.java
                        DefaultStateTransferIntegrator.java
  Log:
  The beginnings of porting JBCACHE-871 and JBCACHE-875 as well as rearranging the Node/Cache object model to something sensible
  
  Revision  Changes    Path
  1.4       +5 -5      JBossCache/src/org/jboss/cache/statetransfer/StateTransferGenerator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferGenerator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferGenerator.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- StateTransferGenerator.java	11 Sep 2006 21:53:19 -0000	1.3
  +++ StateTransferGenerator.java	14 Dec 2006 17:18:48 -0000	1.4
  @@ -6,14 +6,14 @@
    */
   package org.jboss.cache.statetransfer;
   
  -import java.io.ObjectOutputStream;
  +import org.jboss.cache.Node;
   
  -import org.jboss.cache.DataNode;
  +import java.io.ObjectOutputStream;
   
   public interface StateTransferGenerator
   {
     
  -   public void generateState(ObjectOutputStream stream, DataNode rootNode, boolean generateTransient,
  +   public void generateState(ObjectOutputStream stream, Node rootNode, boolean generateTransient,
            boolean generatePersistent, boolean suppressErrors) throws Throwable;
   
   }
  \ No newline at end of file
  
  
  
  1.17      +61 -49    JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- StateTransferManager.java	7 Dec 2006 22:21:48 -0000	1.16
  +++ StateTransferManager.java	14 Dec 2006 17:18:48 -0000	1.17
  @@ -6,14 +6,8 @@
    */
   package org.jboss.cache.statetransfer;
   
  -import java.io.ByteArrayInputStream;
  -import java.io.InputStream;
  -import java.io.ObjectInputStream;
  -import java.io.OutputStream;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
  @@ -28,6 +22,11 @@
   import org.jboss.util.stream.MarshalledValueInputStream;
   import org.jboss.util.stream.MarshalledValueOutputStream;
   
  +import java.io.ByteArrayInputStream;
  +import java.io.InputStream;
  +import java.io.ObjectInputStream;
  +import java.io.OutputStream;
  +
   public class StateTransferManager
   {
      protected final static Log log = LogFactory.getLog(StateTransferManager.class);
  @@ -101,8 +100,10 @@
            if (marshaller_.isInactive(fqn.toString()))
            {
               if (log.isDebugEnabled())
  +            {
                  log.debug("ignoring _getState() for " + fqn + " as it is being activated/inactivated");
  -            if(usingStreamingStateTransfer)
  +            }
  +            if (usingStreamingStateTransfer)
               {
                  MarshalledValueOutputStream out = new MarshalledValueOutputStream(os);
                  out.writeBoolean(false);
  @@ -112,9 +113,11 @@
            }         
         }
   
  -      DataNode rootNode = cache.findNode(fqn);
  +      Node rootNode = cache.findNode(fqn);
         if (rootNode == null)
  +      {
            return null;
  +      }
   
         boolean fetchTransientState = cache.getConfiguration().isFetchInMemoryState();
         CacheLoaderManager cacheLoaderManager = cache.getCacheLoaderManager();
  @@ -131,7 +134,7 @@
            }
          
            MarshalledValueOutputStream out = null;
  -         byte resultBuffer [] = new byte[0];
  +         byte resultBuffer[] = new byte[0];
            StateTransferGenerator generator = getStateTransferGenerator(); 
            long startTime = System.currentTimeMillis();
            if (usingStreamingStateTransfer)
  @@ -142,12 +145,12 @@
            }
            else
            {         
  -            ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16*1024);
  +            ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
               out = new MarshalledValueOutputStream(baos);            
               generator.generateState(out, rootNode, fetchTransientState, fetchPersistentState, suppressErrors);
               resultBuffer = baos.getRawBuffer();
            }  
  -         log.info("Successfully generated state in " + (System.currentTimeMillis()-startTime) + " msec");
  +         log.info("Successfully generated state in " + (System.currentTimeMillis() - startTime) + " msec");
            return resultBuffer;
         }
         finally
  @@ -162,9 +165,8 @@
      }
   
      /**
  -    * 
       * TODO change this javadoc
  -    * 
  +    * <p/>
       * Requests state from each of the given source nodes in the cluster
       * until it gets it or no node replies with a timeout exception.  If state
       * is returned, integrates it into the given DataNode.  If no state is
  @@ -183,7 +185,7 @@
                            Object[] sources, ClassLoader cl)
              throws Exception
      {
  -      treeCache.fetchPartialState(sources, subtreeRoot,integrationRoot.getFqn());
  +      treeCache.fetchPartialState(sources, subtreeRoot, integrationRoot.getFqn());
      }   
   
      /**
  @@ -206,7 +208,7 @@
              throws Exception
      {
         TreeCache cache = getTreeCache();
  -      DataNode target = cache.findNode(targetRoot);
  +      Node target = cache.findNode(targetRoot);
         if (target == null)
         {
            // Create the integration root, but do not replicate
  @@ -234,7 +236,7 @@
       * @param cl         classloader to use to unmarshal the state, or
       *                   <code>null</code> if the TCCL should be used
       */
  -   private void setState(Object state, DataNode targetRoot, ClassLoader cl)
  +   private void setState(Object state, Node targetRoot, ClassLoader cl)
              throws Exception
      {
         if (state == null)
  @@ -254,7 +256,7 @@
                    true, true);
   
            StateTransferIntegrator integrator = null;
  -         MarshalledValueInputStream in =null;
  +         MarshalledValueInputStream in = null;
            if (usingStreamTransfer)
            {
               in =  (MarshalledValueInputStream) state;           
  @@ -284,8 +286,8 @@
            try
            {
               log.info("starting state integration at node " + targetRoot);
  -            integrator.integrateState(in,targetRoot, cl);
  -            log.info("successfully integrated state in " + (System.currentTimeMillis()-startTime) + " msec");
  +            integrator.integrateState(in, targetRoot, cl);
  +            log.info("successfully integrated state in " + (System.currentTimeMillis() - startTime) + " msec");
            }
            catch (Throwable t)
            {
  @@ -303,7 +305,7 @@
      /**
       * Acquires locks on a root node for an owner for state transfer.
       */
  -   protected void acquireLocksForStateTransfer(DataNode root,
  +   protected void acquireLocksForStateTransfer(Node root,
                                                  Object lockOwner,
                                                  long timeout,
                                                  boolean lockChildren,
  @@ -313,10 +315,14 @@
         try
         {
            if (lockChildren)
  +         {
               root.getNodeSPI().getLock().acquireAll(lockOwner, timeout, NodeLock.LockType.READ);
  +         }
            else
  +         {
               root.getNodeSPI().getLock().acquire(lockOwner, timeout, NodeLock.LockType.READ);
         }
  +      }
         catch (TimeoutException te)
         {
            log.error("Caught TimeoutException acquiring locks on region " +
  @@ -324,7 +330,7 @@
            if (force)
            {
               // Until we have FLUSH in place, don't force locks
  -//            forceAcquireLock(root, lockOwner, lockChildren);
  +            //            forceAcquireLock(root, lockOwner, lockChildren);
               throw te;
   
            }
  @@ -340,17 +346,21 @@
       *
       * @see #acquireLocksForStateTransfer
       */
  -   protected void releaseStateTransferLocks(DataNode root,
  +   protected void releaseStateTransferLocks(Node root,
                                               Object lockOwner,
                                               boolean childrenLocked)
      {
         try
         {
            if (childrenLocked)
  +         {
               root.getNodeSPI().getLock().releaseAll(lockOwner);
  +         }
            else
  +         {
               root.getNodeSPI().getLock().release(lockOwner);
         }
  +      }
         catch (Throwable t)
         {
            log.error("failed releasing locks", t);
  @@ -375,7 +385,9 @@
      {
         Object owner = getTreeCache().getCurrentTransaction();
         if (owner == null)
  +      {
            owner = Thread.currentThread();
  +      }
   
         return owner;
      }
  
  
  
  1.6       +34 -13    JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferGenerator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- DefaultStateTransferGenerator.java	20 Nov 2006 03:53:55 -0000	1.5
  +++ DefaultStateTransferGenerator.java	14 Dec 2006 17:18:48 -0000	1.6
  @@ -6,20 +6,21 @@
    */
   package org.jboss.cache.statetransfer;
   
  -import java.io.ObjectOutputStream;
  -import java.util.Iterator;
  -import java.util.Map;
  -import java.util.Set;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
  +import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.Version;
   import org.jboss.cache.loader.CacheLoader;
  -import org.jboss.cache.loader.NodeDataExceptionMarker;
   import org.jboss.cache.loader.NodeData;
  +import org.jboss.cache.loader.NodeDataExceptionMarker;
  +
  +import java.io.ObjectOutputStream;
  +import java.util.Iterator;
  +import java.util.Map;
  +import java.util.Set;
   
   public class DefaultStateTransferGenerator implements StateTransferGenerator
   {
  @@ -38,7 +39,7 @@
         this.internalFqns = cache.getInternalFqns();
      }
   
  -   public void generateState(ObjectOutputStream out, DataNode rootNode, boolean generateTransient,
  +   public void generateState(ObjectOutputStream out, Node rootNode, boolean generateTransient,
            boolean generatePersistent, boolean suppressErrors) throws Throwable
      {
         Fqn fqn = rootNode.getFqn();
  @@ -51,23 +52,31 @@
            {
               //transient + marker
               if (log.isTraceEnabled())
  +            {
                  log.trace("writing transient state for " + fqn);
  +            }
   
               marshallTransientState(rootNode, out);
               out.writeObject(StateTransferManager.STREAMING_DELIMETER_NODE);
   
               if (log.isTraceEnabled())
  +            {
                  log.trace("transient state succesfully written");
  +            }
   
               //associated + marker
               if (log.isTraceEnabled())
  +            {
                  log.trace("writing associated state");
  +            }
   
               marshallAssociatedState(fqn, out);
               out.writeObject(StateTransferManager.STREAMING_DELIMETER_NODE);
   
               if (log.isTraceEnabled())
  +            {
                  log.trace("associated state succesfully written");
  +            }
   
            }
            
  @@ -75,7 +84,9 @@
            if (cacheLoader != null && generatePersistent)
            {
               if (log.isTraceEnabled())
  +            {
                  log.trace("writing persistent state for " + fqn + ",using " + cache.getCacheLoader().getClass());
  +            }
   
               if (fqn.isRoot())
               {
  @@ -87,15 +98,17 @@
               }
   
               if (log.isTraceEnabled())
  +            {
                  log.trace("persistent state succesfully written");
            }
  +         }
            out.writeObject(StateTransferManager.STREAMING_DELIMETER_NODE);
         }
         catch (Throwable t)
         {
            encouteredException = t;
            log.error("failed writing state", t);
  -         out.writeObject(new NodeDataExceptionMarker(t,cache.getLocalAddress()));
  +         out.writeObject(new NodeDataExceptionMarker(t, cache.getLocalAddress()));
         }
         finally
         {
  @@ -113,11 +126,13 @@
       * @param out
       * @throws Exception
       */
  -   protected void marshallTransientState(DataNode node, ObjectOutputStream out) throws Exception
  +   protected void marshallTransientState(Node node, ObjectOutputStream out) throws Exception
      {
   
         if (internalFqns.contains(node.getFqn()))
  +      {
            return;
  +      }
   
         Map attrs;
         NodeData nd;
  @@ -125,15 +140,21 @@
         // first handle the current node
         attrs = node.getData();
         if (attrs == null || attrs.size() == 0)
  +      {
            nd = new NodeData(node.getFqn());
  +      }
         else
  +      {
            nd = new NodeData(node.getFqn(), attrs);
  +      }
         out.writeObject(nd);
   
         // then visit the children
         Map children = node.getNodeSPI().getChildrenMap();
         if (children == null)
  +      {
            return;
  +      }
         for (Iterator it = children.entrySet().iterator(); it.hasNext();)
         {
            Map.Entry entry = (Map.Entry) it.next();
  
  
  
  1.5       +4 -4      JBossCache/src/org/jboss/cache/statetransfer/StateTransferIntegrator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferIntegrator.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- StateTransferIntegrator.java	11 Sep 2006 21:53:19 -0000	1.4
  +++ StateTransferIntegrator.java	14 Dec 2006 17:18:48 -0000	1.5
  @@ -6,13 +6,13 @@
    */
   package org.jboss.cache.statetransfer;
   
  -import java.io.ObjectInputStream;
  +import org.jboss.cache.Node;
   
  -import org.jboss.cache.DataNode;
  +import java.io.ObjectInputStream;
   
   public interface StateTransferIntegrator
   {
      
  -   void integrateState(ObjectInputStream ois, DataNode target,ClassLoader cl)throws Exception;
  +   void integrateState(ObjectInputStream ois, Node target, ClassLoader cl) throws Exception;
   
   }
  \ No newline at end of file
  
  
  
  1.7       +78 -59    JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferIntegrator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- DefaultStateTransferIntegrator.java	23 Nov 2006 19:43:05 -0000	1.6
  +++ DefaultStateTransferIntegrator.java	14 Dec 2006 17:18:48 -0000	1.7
  @@ -6,13 +6,6 @@
    */
   package org.jboss.cache.statetransfer;
   
  -import java.io.IOException;
  -import java.io.ObjectInputStream;
  -import java.util.HashSet;
  -import java.util.Iterator;
  -import java.util.Map;
  -import java.util.Set;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  @@ -26,6 +19,12 @@
   import org.jboss.cache.loader.NodeData;
   import org.jboss.cache.loader.NodeDataExceptionMarker;
   
  +import java.io.IOException;
  +import java.io.ObjectInputStream;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.Set;
  +
   public class DefaultStateTransferIntegrator implements StateTransferIntegrator
   {   
   
  @@ -52,7 +51,7 @@
         this.internalFqns = cache.getInternalFqns();     
      }
      
  -   public void integrateState(ObjectInputStream ois, DataNode target, ClassLoader cl) throws Exception
  +   public void integrateState(ObjectInputStream ois, Node target, ClassLoader cl) throws Exception
      {
         Throwable cause = null;     
         try
  @@ -61,36 +60,40 @@
            integrateAssociatedState(ois);
            integratePersistentState(ois);
         }     
  -      catch(Throwable t)
  +      catch (Throwable t)
         {
            cause = t;
  -         log.error("Failed integrating state.",t);
  +         log.error("Failed integrating state.", t);
         }                        
         finally
         {
            ois.close();
            if (cause != null)
            {
  -            throw new Exception("State transfer failed ",cause);
  +            throw new Exception("State transfer failed ", cause);
            }
         }
      }
   
  -   protected void integrateTransientState(ObjectInputStream in,DataNode target, ClassLoader cl) throws Exception
  +   protected void integrateTransientState(ObjectInputStream in, Node target, ClassLoader cl) throws Exception
      {
         boolean transientSet = false;
         ClassLoader oldCL = setClassLoader(cl);
         try
         {
            if (log.isTraceEnabled())
  +         {
               log.trace("integrating transient state for " + target);
  +         }
   
            integrateTransientState(target, in);
   
            transientSet = true;
   
            if (log.isTraceEnabled())
  +         {
               log.trace("transient state successfully integrated");
  +         }
            
            notifyAllNodesCreated(target);
         }
  @@ -101,7 +104,7 @@
               // Clear any existing state from the targetRoot
               log.warn("transient state integration failed, removing all children of " + target);
               target.clearData();
  -            target.removeChildren();
  +            ((DataNode) target).removeChildren();
            }
   
            resetClassLoader(oldCL);
  @@ -127,12 +130,16 @@
         if (loader == null)
         {
            if (log.isTraceEnabled())
  +         {
               log.trace("cache loader is null, will not attempt to integrate persistent state");
         }
  +      }
         else
         {
            if (log.isTraceEnabled())
  +         {
               log.trace("integrating persistent state using " + loader.getClass().getName());
  +         }
            
            boolean persistentSet = false;
            try
  @@ -163,11 +170,13 @@
               else
               {
                  if (log.isTraceEnabled())
  +               {
                     log.trace("persistent state integrated successfully");
               }
            }         
         }
      }   
  +   }
      
      protected TreeCache getCache()
      {
  @@ -193,7 +202,7 @@
       * Generates NodeAdded notifications for all nodes of the tree. This is
       * called whenever the tree is initially retrieved (state transfer)
       */
  -   private void notifyAllNodesCreated(DataNode curr)
  +   private void notifyAllNodesCreated(Node curr)
      {
         DataNode n;
   
  @@ -222,15 +231,17 @@
      private void resetClassLoader(ClassLoader oldLoader)
      {
         if (oldLoader != null)
  +      {
            Thread.currentThread().setContextClassLoader(oldLoader);
      }
  +   }
   
  -   private void integrateTransientState(DataNode target, ObjectInputStream in) throws IOException,
  +   private void integrateTransientState(Node target, ObjectInputStream in) throws IOException,
            ClassNotFoundException
      {
         Set retainedNodes = retainInternalNodes(target);
   
  -      target.removeChildren();
  +      ((DataNode) target).removeChildren();
   
         // Read the first NodeData and integrate into our target     
         NodeData nd = readNode(in);
  @@ -267,7 +278,7 @@
         return nd;
      }
   
  -   private NodeData integrateStateTransferChildren(DataNode parent, int offset, ObjectInputStream in)
  +   private NodeData integrateStateTransferChildren(Node parent, int offset, ObjectInputStream in)
            throws IOException, ClassNotFoundException
      {
         int parent_level = parent.getFqn().size();
  @@ -282,19 +293,25 @@
            // If we need to integrate into the buddy backup subtree,
            // change the Fqn to fit under it
            if (offset > 0)
  +         {
               fqn = new Fqn(parent.getFqn().getFqnChild(offset), fqn);
  +         }
            size = fqn.size();
            if (size <= parent_level)
  +         {
               return nd;
  +         }
            else if (size > target_level)
  +         {
               throw new IllegalStateException("NodeData " + fqn + " is not a direct child of " + parent.getFqn());
  +         }
   
            name = fqn.get(size - 1);
   
            // We handle this NodeData.  Create a DataNode and
            // integrate its data            
  -         DataNode target = factory.createDataNode(nodeType, name, fqn, parent, nd.getAttributes(), false, null, cache.getCacheSPI());
  -         parent.addChild(name, target);
  +         Node target = factory.createDataNode(nodeType, name, fqn, parent, nd.getAttributes(), false, null, cache.getCacheSPI());
  +         ((DataNode) parent).addChild(name, target);
   
            // Recursively call, which will walk down the tree
            // and return the next NodeData that's a child of our parent
  @@ -303,7 +320,7 @@
         return null;
      }
   
  -   private Set retainInternalNodes(DataNode target)
  +   private Set retainInternalNodes(Node target)
      {
         Set result = new HashSet();
         Fqn targetFqn = target.getFqn();
  @@ -314,17 +331,19 @@
            {
               DataNode internalNode = getInternalNode(target, internalFqn);
               if (internalNode != null)
  +            {
                  result.add(internalNode);
            }
         }
  +      }
   
         return result;
      }
   
  -   private DataNode getInternalNode(DataNode parent, Fqn internalFqn)
  +   private DataNode getInternalNode(Node parent, Fqn internalFqn)
      {
         Object name = internalFqn.get(parent.getFqn().size());
  -      DataNode result = (DataNode) parent.getChild(name);
  +      DataNode result = (DataNode) parent.getChild(new Fqn(name));
         if (result != null)
         {
            if (internalFqn.size() < result.getFqn().size())
  @@ -336,7 +355,7 @@
         return result;
      }
   
  -   private void integrateRetainedNodes(DataNode root, Set retainedNodes)
  +   private void integrateRetainedNodes(Node root, Set retainedNodes)
      {
         Fqn rootFqn = root.getFqn();
         for (Iterator it = retainedNodes.iterator(); it.hasNext();)
  @@ -349,17 +368,17 @@
         }
      }
   
  -   private void integrateRetainedNode(DataNode ancestor, DataNode descendant)
  +   private void integrateRetainedNode(Node ancestor, DataNode descendant)
      {
         Fqn descFqn = descendant.getFqn();
         Fqn ancFqn = ancestor.getFqn();
         Object name = descFqn.get(ancFqn.size());
  -      DataNode child = (DataNode) ancestor.getChild(name);
  +      DataNode child = (DataNode) ancestor.getChild(new Fqn(name));
         if (ancFqn.size() == descFqn.size() + 1)
         {
            if (child == null)
            {
  -            ancestor.addChild(name, descendant);
  +            ((DataNode) ancestor).addChild(name, descendant);
            }
            else
            {
  @@ -373,8 +392,8 @@
               // Missing level -- have to create empty node
               // This shouldn't really happen -- internal fqns should
               // be immediately under the root
  -            child = (DataNode) factory.createDataNode(nodeType, name, new Fqn(ancFqn, name), ancestor, null, true, null, cache.getCacheSPI());
  -            ancestor.addChild(name, child);
  +            child = factory.createDataNode(nodeType, name, new Fqn(ancFqn, name), ancestor, null, true, null, cache.getCacheSPI());
  +            ((DataNode) ancestor).addChild(name, child);
            }
   
            // Keep walking down the tree
  
  
  


From msurtani at jboss.com  Thu Dec 14 12:18:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 12:18:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic   ...
Message-ID: <E1GuuEK-00074b-GP@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 12:18:48

  Modified:    src/org/jboss/cache/optimistic   WorkspaceNodeImpl.java
                        WorkspaceNode.java
  Log:
  The beginnings of porting JBCACHE-871 and JBCACHE-875 as well as rearranging the Node/Cache object model to something sensible
  
  Revision  Changes    Path
  1.31      +26 -32    JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- WorkspaceNodeImpl.java	12 Dec 2006 14:51:44 -0000	1.30
  +++ WorkspaceNodeImpl.java	14 Dec 2006 17:18:48 -0000	1.31
  @@ -8,6 +8,7 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.AbstractNode;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
  @@ -37,7 +38,7 @@
    * @author Manik Surtani (<a href="mailto:manik at jboss.org">manik at jboss.org</a>)
    * @author Steve Woodcock (<a href="mailto:stevew at jofti.com">stevew at jofti.com</a>)
    */
  -public class WorkspaceNodeImpl implements WorkspaceNode, NodeSPI
  +public class WorkspaceNodeImpl extends AbstractNode implements WorkspaceNode
   {
   
      private static Log log = LogFactory.getLog(WorkspaceNodeImpl.class);
  @@ -45,7 +46,6 @@
      private Node node;
      private TransactionWorkspace workspace;
      private DataVersion version = DefaultDataVersion.ZERO;
  -   private boolean deleted;
      private boolean dirty;
      private boolean created;
      private Map<Object, Node> optimisticChildNodeMap;
  @@ -67,8 +67,10 @@
         optimisticChildNodeMap = new ConcurrentHashMap(node.getNodeSPI().getChildrenMap());
         this.version = ((OptimisticTreeNode) node).getVersion();
         if (version == null)
  +      {
            throw new IllegalStateException("OptimisticTreeNode version null");
      }
  +   }
   
      /**
       * Returns true if this node is dirty.
  @@ -263,41 +265,31 @@
         return optimisticChildNodeMap;
      }
   
  -//    private Map mergeMaps(OptimisticMap opMap)
  -//    {
  -//        Map temp = new HashMap(opMap.getOriginalMap());
  -//        //first remove all removed keys
  -//        for (Iterator it = opMap.getRemovedMap().keySet().iterator(); it.hasNext();)
  -//        {
  -//            temp.remove(it.next());
  -//        }
  -//        // then add in changed stuff
  -//        for (Iterator it = opMap.getLocalMap().entrySet().iterator(); it.hasNext();)
  -//        {
  -//            Map.Entry entry = (Map.Entry) it.next();
  -//            temp.put(entry.getKey(), entry.getValue());
  -//        }
  -//        return temp;
  -//        TODO: MANIK: BN: Does this need to be a copy?!??
  -//        return new HashMap(opMap.getLocalMap());
  -//        return opMap.getLocalMap();
  -//    }
  +   //    private Map mergeMaps(OptimisticMap opMap)
  +   //    {
  +   //        Map temp = new HashMap(opMap.getOriginalMap());
  +   //        //first remove all removed keys
  +   //        for (Iterator it = opMap.getRemovedMap().keySet().iterator(); it.hasNext();)
  +   //        {
  +   //            temp.remove(it.next());
  +   //        }
  +   //        // then add in changed stuff
  +   //        for (Iterator it = opMap.getLocalMap().entrySet().iterator(); it.hasNext();)
  +   //        {
  +   //            Map.Entry entry = (Map.Entry) it.next();
  +   //            temp.put(entry.getKey(), entry.getValue());
  +   //        }
  +   //        return temp;
  +   //        TODO: MANIK: BN: Does this need to be a copy?!??
  +   //        return new HashMap(opMap.getLocalMap());
  +   //        return opMap.getLocalMap();
  +   //    }
   
      public Map getMergedData()
      {
         return optimisticDataMap;
      }
   
  -   public void markAsDeleted()
  -   {
  -      deleted = true;
  -   }
  -
  -   public boolean isDeleted()
  -   {
  -      return deleted;
  -   }
  -
      public Object getName()
      {
         return node.getFqn().getLast();
  @@ -467,7 +459,9 @@
      public Node addChild(Fqn f)
      {
         if (log.isTraceEnabled())
  +      {
            log.trace("Adding child " + f + " to " + getFqn());
  +      }
         CacheSPI cache = getCache();
         if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
         {
  @@ -559,7 +553,7 @@
   
      public NodeSPI getNodeSPI()
      {
  -      return this; // node.getNodeSPI();
  +      return this;// node.getNodeSPI();
      }
   
      public Node getOrCreateChild(Object name, GlobalTransaction tx)
  
  
  
  1.17      +0 -4      JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- WorkspaceNode.java	12 Dec 2006 14:51:44 -0000	1.16
  +++ WorkspaceNode.java	14 Dec 2006 17:18:48 -0000	1.17
  @@ -39,10 +39,6 @@
   
      public Set getChildrenNames();
   
  -   public boolean isDeleted();
  -
  -   public void markAsDeleted();
  -
      public TransactionWorkspace getTransactionWorkspace();
   
      public boolean isCreated();
  
  
  


From msurtani at jboss.com  Thu Dec 14 12:18:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 12:18:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors   ...
Message-ID: <E1GuuEK-00074l-LK@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 12:18:48

  Modified:    src/org/jboss/cache/interceptors  
                        PessimisticLockInterceptor.java
                        OptimisticNodeInterceptor.java
  Log:
  The beginnings of porting JBCACHE-871 and JBCACHE-875 as well as rearranging the Node/Cache object model to something sensible
  
  Revision  Changes    Path
  1.37      +150 -47   JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.36
  retrieving revision 1.37
  diff -u -b -r1.36 -r1.37
  --- PessimisticLockInterceptor.java	12 Dec 2006 14:51:44 -0000	1.36
  +++ PessimisticLockInterceptor.java	14 Dec 2006 17:18:48 -0000	1.37
  @@ -7,12 +7,14 @@
   package org.jboss.cache.interceptors;
   
   import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
  +import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.LockingException;
   import org.jboss.cache.lock.NodeLock;
  @@ -22,6 +24,7 @@
   
   import javax.transaction.Transaction;
   import java.util.Collections;
  +import java.util.Iterator;
   import java.util.LinkedList;
   import java.util.List;
   import java.util.Map;
  @@ -34,7 +37,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.36 2006/12/12 14:51:44 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.37 2006/12/14 17:18:48 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -89,7 +92,8 @@
   
         boolean recursive = false;
         boolean createIfNotExists = false;
  -      boolean zeroLockTimeout = false; // only used if the call is an evict() call.  See JBCACHE-794
  +      boolean zeroLockTimeout = false;// only used if the call is an evict() call.  See JBCACHE-794
  +      boolean isDeleteOperation = false;// needed for JBCACHE-871
   
         // 1. Determine the type of lock (read, write, or none) depending on the method. If no lock is required, invoke
         //    the method, then return immediately
  @@ -108,9 +112,10 @@
               lock_type = NodeLock.LockType.WRITE;
               break;
            case MethodDeclarations.removeNodeMethodLocal_id:
  +            isDeleteOperation = true;
               fqn = (Fqn) args[1];
               lock_type = NodeLock.LockType.WRITE;
  -            recursive = true; // remove node and *all* child nodes
  +            recursive = true;// remove node and *all* child nodes
               break;
            case MethodDeclarations.removeKeyMethodLocal_id:
            case MethodDeclarations.removeDataMethodLocal_id:
  @@ -162,9 +167,9 @@
         {
            do
            {
  -            lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, createIfNotExists, zeroLockTimeout ? 0 : lock_acquisition_timeout);
  +            lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, createIfNotExists, zeroLockTimeout ? 0 : lock_acquisition_timeout, isDeleteOperation);
            }
  -         while (createIfNotExists && !cache.hasChild(fqn)); // keep trying until we have the lock (fixes concurrent remove())
  +         while (createIfNotExists && !cache.hasChild(fqn));// keep trying until we have the lock (fixes concurrent remove())
         }
         else if (!lockNecessary)
         {
  @@ -177,7 +182,18 @@
         {
            return null;
         }
  -      return super.invoke(m);
  +      Object o = super.invoke(m);
  +      // FIXME this should be done in UnlockInterceptor, but I didn't want
  +      // to add the removedNodes map to TreeCache
  +      if (isDeleteOperation && ctx.getGlobalTransaction() == null)
  +      {
  +         //cache.getRemovedNodesMap().remove(fqn);
  +         //cache.peek(fqn);
  +         // do a REAL remove here.
  +         cache.peek(fqn).getNodeSPI().getLock().releaseAll(Thread.currentThread());
  +         ((TreeCacheProxyImpl) cache).realRemove(fqn, true);
  +      }
  +      return o;
      }
   
      private void obtainLocksForMove(Fqn parent, Fqn node) throws InterruptedException
  @@ -187,11 +203,11 @@
   
         // this call will ensure the node gets a WL and it's current parent gets RL.
         if (log.isTraceEnabled()) log.trace("Attempting to get WL on node to be moved [" + node + "]");
  -      lock(node, cache.getInvocationContext().getGlobalTransaction(), NodeLock.LockType.WRITE, true, false, lock_acquisition_timeout);
  +      lock(node, cache.getInvocationContext().getGlobalTransaction(), NodeLock.LockType.WRITE, true, false, lock_acquisition_timeout, false);
   
         //now for an RL for the new parent.
         if (log.isTraceEnabled()) log.trace("Attempting to get RL on new parent [" + parent + "]");
  -      lock(parent, cache.getInvocationContext().getGlobalTransaction(), NodeLock.LockType.READ, true, false, lock_acquisition_timeout);
  +      lock(parent, cache.getInvocationContext().getGlobalTransaction(), NodeLock.LockType.READ, true, false, lock_acquisition_timeout, false);
      }
   
   
  @@ -203,7 +219,7 @@
       * @param lock_type DataNode.LOCK_TYPE_READ, DataNode.LOCK_TYPE_WRITE or DataNode.LOCK_TYPE_NONE
       * @param recursive Lock children recursively
       */
  -   private void lock(Fqn fqn, GlobalTransaction gtx, NodeLock.LockType lock_type, boolean recursive, boolean createIfNotExists, long timeout)
  +   private void lock(Fqn fqn, GlobalTransaction gtx, NodeLock.LockType lock_type, boolean recursive, boolean createIfNotExists, long timeout, boolean isDeleteOperation)
              throws TimeoutException, LockingException, InterruptedException
      {
         Node n;
  @@ -212,8 +228,6 @@
         Thread currentThread = Thread.currentThread();
         Object owner = (gtx != null) ? gtx : currentThread;
         int treeNodeSize;
  -      boolean acquired;
  -
   
         if (log.isTraceEnabled()) log.trace("Attempting to lock node " + fqn + " for owner " + owner);
   
  @@ -235,11 +249,19 @@
   
         n = cache;
         treeNodeSize = fqn.size();
  -      for (int i = 0; i < treeNodeSize; i++)
  +      for (int i = -1; i < treeNodeSize; i++)
  +      {
  +         if (i == -1)
  +         {
  +            // this is the root node
  +            child_name = Fqn.ROOT.getName();
  +            child_node = cache.getRoot();
  +         }
  +         else
         {
            child_name = fqn.get(i);
  -
            child_node = n.getNodeSPI().getChildrenMap().get(child_name);
  +         }
            /*
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
            Fqn childFqn = new Fqn(child_name);
  @@ -260,6 +282,7 @@
               return;
            }
   
  +         NodeLock.LockType lockTypeRequired;
            if (lock_type == NodeLock.LockType.NONE)
            {
               // acquired=false;
  @@ -268,56 +291,110 @@
            }
            else
            {
  -            if (lock_type == NodeLock.LockType.WRITE && i == (treeNodeSize - 1))
  +            if (writeLockNeeded(lock_type, i, treeNodeSize, isDeleteOperation, createIfNotExists, fqn, child_node.getFqn()))
               {
                  //acquired=child_node.acquire(owner, lock_timeout, DataNode.LOCK_TYPE_WRITE);
  -               acquired = lockManager.acquire(child_node, owner, NodeLock.LockType.WRITE, timeout);
  +               //acquired = lockManager.acquire(child_node, owner, NodeLock.LockType.WRITE, timeout);
  +               lockTypeRequired = NodeLock.LockType.WRITE;
  +
               }
               else
               {
                  //acquired=child_node.acquire(owner, lock_timeout, DataNode.LOCK_TYPE_READ);
  -               acquired = lockManager.acquire(child_node, owner, NodeLock.LockType.READ, timeout);
  +               //acquired = lockManager.acquire(child_node, owner, NodeLock.LockType.READ, timeout);
  +               lockTypeRequired = NodeLock.LockType.READ;
               }
            }
   
  +         // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  +         if (gtx != null && needToReverseRemove(child_node, tx_table.get(gtx), lock_type, isDeleteOperation, createIfNotExists))
  +         {
  +            reverseRemove(child_node);
  +         }
   
  -         if (acquired)
  +         acquireNodeLock(child_node, owner, gtx, lockTypeRequired, timeout);
  +
  +         if (recursive && isTargetNode(i, treeNodeSize))
  +         {
  +            //Set acquired_locks=child_node.acquireAll(owner, lock_timeout, lock_type);
  +            Set acquired_locks = lockManager.acquireAll(child_node, owner, lock_type, timeout);
  +            if (acquired_locks.size() > 0)
            {
               if (gtx != null)
               {
  -               // add the lock to the list of locks maintained for this transaction
  -               // (needed for release of locks on commit or rollback)
  -               cache.getTransactionTable().addLock(gtx, lockManager.getLock(child_node));
  +                  cache.getTransactionTable().addLocks(gtx, acquired_locks);
               }
               else
               {
  -               NodeLock l = lockManager.getLock(child_node);
                  List locks = getLocks(currentThread);
  -               if (!locks.contains(l))
  +                  locks.addAll(acquired_locks);
  +               }
  +            }
  +         }
  +         n = child_node;
  +      }
  +
  +      // Add the Fqn to be removed to the transaction entry so we can clean up after ourselves during commit/rollback
  +      if (isDeleteOperation && gtx != null) cache.getTransactionTable().get(gtx).addRemovedNode(fqn);
  +   }
  +
  +   private boolean needToReverseRemove(Node n, TransactionEntry te, NodeLock.LockType lockTypeRequested, boolean isRemoveOperation, boolean createIfNotExists)
                  {
  -                  locks.add(l);
  +      return !isRemoveOperation && createIfNotExists && lockTypeRequested == NodeLock.LockType.WRITE && ((DataNode) n).isDeleted() && te.getRemovedNodes().contains(n.getFqn());
                  }
  +
  +   private void reverseRemove(Node n)
  +   {
  +      ((DataNode) n).markAsDeleted(false);
               }
  +
  +   private boolean writeLockNeeded(NodeLock.LockType lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
  +   {
  +      if (isRemoveOperation && currentNodeIndex == treeNodeSize - 2)
  +      {
  +         return true;// we're doing a remove and we've reached the PARENT node of the target to be removed.
            }
   
  -         if (recursive && i == (treeNodeSize - 1))
  +      if (!isTargetNode(currentNodeIndex, treeNodeSize) && !cache.hasChild(new Fqn(currentFqn, targetFqn.get(currentNodeIndex + 1))))
            {
  -            //Set acquired_locks=child_node.acquireAll(owner, lock_timeout, lock_type);
  -            Set acquired_locks = lockManager.acquireAll(child_node, owner, lock_type, timeout);
  -            if (acquired_locks.size() > 0)
  +         return createIfNotExists;// we're at a node in the tree, not yet at the target node, and we need to create the next node.  So we need a WL here.
  +      }
  +
  +      return lock_type == NodeLock.LockType.WRITE && isTargetNode(currentNodeIndex, treeNodeSize) && (createIfNotExists || isRemoveOperation);//normal operation, write lock explicitly requested and this is the target to be written to.
  +   }
  +
  +   private boolean isTargetNode(int nodePosition, int treeNodeSize)
  +   {
  +      return nodePosition == (treeNodeSize - 1);
  +   }
  +
  +   private void acquireNodeLock(Node node, Object owner, GlobalTransaction gtx, NodeLock.LockType lock_type, long lock_timeout) throws LockingException, TimeoutException, InterruptedException
  +   {
  +      boolean acquired = lockManager.acquire(node, owner, lock_type, lock_timeout);
  +      if (acquired)
  +      {
  +         // Record the lock for release on method return or tx commit/rollback
  +         recordNodeLock(gtx, node.getNodeSPI().getLock());
  +      }
  +   }
  +
  +   private void recordNodeLock(GlobalTransaction gtx, NodeLock lock)
               {
                  if (gtx != null)
                  {
  -                  cache.getTransactionTable().addLocks(gtx, acquired_locks);
  +         // add the lock to the list of locks maintained for this transaction
  +         // (needed for release of locks on commit or rollback)
  +         cache.getTransactionTable().addLock(gtx, lock);
                  }
                  else
                  {
  +         Thread currentThread = Thread.currentThread();
                     List locks = getLocks(currentThread);
  -                  locks.addAll(acquired_locks);
  -               }
  -            }
  +         if (!locks.contains(lock))
  +         {
  +            locks.add(lock);
  +            lock_table.put(currentThread, locks);
            }
  -         n = child_node;
         }
      }
   
  @@ -349,8 +426,15 @@
            if (child_node == null)
            {
               cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  -            child_node = n.addChild(childFqn); //, gtx, true);
  +            child_node = n.addChild(childFqn);//, gtx, true);
  +         }
  +         // test if this node needs to be 'undeleted'
  +         // reverse the "remove" if the node has been previously removed in the same tx, if this operation is a put()
  +         if (gtx != null && needToReverseRemove(child_node, tx_table.get(gtx), NodeLock.LockType.WRITE, false, true))
  +         {
  +            reverseRemove(child_node);
            }
  +
            if (child_node == null)
            {
               if (log.isTraceEnabled())
  @@ -382,6 +466,15 @@
            return;
         }
   
  +      // first remove nodes that should be deleted.
  +      Iterator removedNodes = entry.getRemovedNodes().iterator();
  +      TreeCacheProxyImpl tcpi = (TreeCacheProxyImpl) cache;
  +      while (removedNodes.hasNext())
  +      {
  +         Fqn f = (Fqn) removedNodes.next();
  +         tcpi.realRemove(f, false);
  +      }
  +
         // Let's do it in stack style, LIFO
         entry.releaseAllLocksLIFO(gtx);
   
  @@ -421,6 +514,16 @@
            return;
         }
   
  +
  +      Iterator removedNodes = entry.getRemovedNodes().iterator();
  +      TreeCacheProxyImpl tcpi = (TreeCacheProxyImpl) cache;
  +      while (removedNodes.hasNext())
  +      {
  +         Fqn f = (Fqn) removedNodes.next();
  +         tcpi.realRemove(f, false);
  +
  +      }
  +
         // 1. Revert the modifications by running the undo-op list in reverse. This *cannot* throw any exceptions !
         entry.undoOperations(cache);
   
  @@ -428,16 +531,16 @@
         // put(/a/b/c) on /a, create b and c, plus undo operations _remove(a/b/c) and _remove(/a/b)
   
         // 2. Remove all temporary nodes. Need to do it backwards since node is LIFO.
  -//      for(ListIterator it=new LinkedList(entry.getNodes()).listIterator(entry.getNodes().size());
  -//          it.hasPrevious();) {
  -//         node_name=(Fqn)it.previous();
  -//         try {
  -//            cache._remove(tx, node_name, false);
  -//         }
  -//         catch(Throwable t) {
  -//            log.error("failed removing node \"" + node_name + "\"", t);
  -//         }
  -//      }
  +      //      for(ListIterator it=new LinkedList(entry.getNodes()).listIterator(entry.getNodes().size());
  +      //          it.hasPrevious();) {
  +      //         node_name=(Fqn)it.previous();
  +      //         try {
  +      //            cache._remove(tx, node_name, false);
  +      //         }
  +      //         catch(Throwable t) {
  +      //            log.error("failed removing node \"" + node_name + "\"", t);
  +      //         }
  +      //      }
   
         // 3. Finally, release all locks held by this TX
         // Let's do it in stack style, LIFO
  
  
  
  1.36      +7 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -b -r1.35 -r1.36
  --- OptimisticNodeInterceptor.java	12 Dec 2006 14:51:44 -0000	1.35
  +++ OptimisticNodeInterceptor.java	14 Dec 2006 17:18:48 -0000	1.36
  @@ -94,13 +94,17 @@
   
                  workspaceNode.setVersion(version);
                  if (log.isTraceEnabled())
  +               {
                     log.trace("Setting versioning for node " + workspaceNode.getFqn() + " to explicit");
  +               }
                  workspaceNode.setVersioningImplicit(false);
               }
               else
               {
                  if (log.isTraceEnabled())
  +               {
                     log.trace("Setting versioning for node " + workspaceNode.getFqn() + " to implicit");
  +               }
                  workspaceNode.setVersioningImplicit(true);
               }
            }
  @@ -108,8 +112,10 @@
            {
               // "fail-more-silently" patch thanks to Owen Taylor - JBCACHE-767
               if ((ctx.getOptionOverrides() == null || !ctx.getOptionOverrides().isFailSilently()) && MethodDeclarations.isPutMethod(m.getMethodId()))
  +            {
                  throw new CacheException("Unable to set node version for " + getFqn(args) + ", node is null.");
            }
  +         }
   
            switch (m.getMethodId())
            {
  @@ -316,7 +322,7 @@
            if (toDelete.getFqn().isChildOrEquals(nodeFqn))
            {
               if (debug) log.debug("marking node " + toDelete.getFqn() + " as deleted");
  -            toDelete.markAsDeleted();
  +            toDelete.markAsDeleted(true);
            }
            else
            {
  
  
  


From msurtani at jboss.com  Thu Dec 14 12:52:29 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 14 Dec 2006 12:52:29 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1Guukv-0007zz-Mu@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/14 12:52:29

  Modified:    tests/functional/org/jboss/cache/transaction     
                        IsolationLevelReadCommittedTest.java
                        PrepareTxTest.java DeadlockTest.java
                        IsolationLevelNoneTest.java SuspendTxTest.java
  Log:
  Tests fixed to be compliant with JBCACHE-871 and JBCACHE-875
  
  Revision  Changes    Path
  1.11      +15 -3     JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelReadCommittedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- IsolationLevelReadCommittedTest.java	14 Dec 2006 17:18:48 -0000	1.10
  +++ IsolationLevelReadCommittedTest.java	14 Dec 2006 17:52:29 -0000	1.11
  @@ -13,6 +13,7 @@
   import org.jboss.cache.config.Configuration.CacheMode;
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.TimeoutException;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.SystemException;
  @@ -23,7 +24,7 @@
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  - * @version $Id: IsolationLevelReadCommittedTest.java,v 1.10 2006/12/14 17:18:48 msurtani Exp $
  + * @version $Id: IsolationLevelReadCommittedTest.java,v 1.11 2006/12/14 17:52:29 msurtani Exp $
    */
   
   public class IsolationLevelReadCommittedTest extends TestCase
  @@ -107,8 +108,15 @@
                  // yet commit or roll back.
                  readerCanRead.acquire();
   
  +               try
  +               {
                  // I shouldn't be able to see the "dirty" value
                  assertEquals("thread w/ read lock can see subsequent uncommitted changes!!", VALUE, cache.get(FQN, KEY));
  +               }
  +               catch (TimeoutException good)
  +               {
  +                  // this is what should happen due to writer's WL
  +               }
   
                  // let the writer know it can rollback
                  writerCanRollback.release();
  @@ -276,6 +284,10 @@
            assertEquals("2nd thread cannot see uncommitted changes",
                    VALUE, cache.get(FQN, KEY));
         }
  +      catch (TimeoutException t)
  +      {
  +         // ignore, this is good
  +      }
         finally
         {
            System.out.println("reader thread exits");
  
  
  
  1.4       +2 -2      JBossCache/tests/functional/org/jboss/cache/transaction/PrepareTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PrepareTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/PrepareTxTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PrepareTxTest.java	6 Sep 2006 15:31:00 -0000	1.3
  +++ PrepareTxTest.java	14 Dec 2006 17:52:29 -0000	1.4
  @@ -57,7 +57,7 @@
         cache.put("/one/two/three", "key1", "val1");
         System.out.println("before commit:\n" + cache.printLockInfo());
         numLocks = cache.getNumberOfLocksHeld();
  -      assertEquals(3, numLocks);
  +      assertEquals(4, numLocks);
   
         // we register *second*
         tx.registerSynchronization(new Synchronization()
  @@ -115,7 +115,7 @@
         cache.put("/one/two/three", "key1", "val1");
         System.out.println("before commit:\n" + cache.printLockInfo());
         numLocks = cache.getNumberOfLocksHeld();
  -      assertEquals(3, numLocks);
  +      assertEquals(4, numLocks);
   
         // we register *second*
         tx.registerSynchronization(new Synchronization()
  
  
  
  1.7       +75 -59    JBossCache/tests/functional/org/jboss/cache/transaction/DeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/DeadlockTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- DeadlockTest.java	6 Sep 2006 15:31:00 -0000	1.6
  +++ DeadlockTest.java	14 Dec 2006 17:52:29 -0000	1.7
  @@ -30,7 +30,7 @@
    * Tests transactional access to a local TreeCache, with concurrent (deadlock-prone) access.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: DeadlockTest.java,v 1.6 2006/09/06 15:31:00 msurtani Exp $
  + * @version $Id: DeadlockTest.java,v 1.7 2006/12/14 17:52:29 msurtani Exp $
    */
   public class DeadlockTest extends TestCase
   {
  @@ -70,10 +70,14 @@
      {
         super.tearDown();
         if (cache != null)
  +      {
            cache.stop();
  +      }
         if (thread_ex != null)
  +      {
            throw thread_ex;
      }
  +   }
   
   
      public void testConcurrentUpgrade() throws CacheException, InterruptedException
  @@ -90,14 +94,14 @@
   
         synchronized (t1)
         {
  -         t1.notify(); // t1 will now try to upgrade RL to WL, but fails b/c t2 still has a RL
  +         t1.notify();// t1 will now try to upgrade RL to WL, but fails b/c t2 still has a RL
         }
   
         TestingUtil.sleepThread((long) 5000);
   
         synchronized (t2)
         {
  -         t2.notify(); // t1 should now be able to upgrade because t1 was rolled back (RL was removed)
  +         t2.notify();// t1 should now be able to upgrade because t1 was rolled back (RL was removed)
         }
   
         t1.join();
  @@ -124,20 +128,23 @@
   
         synchronized (t1)
         {
  -         t1.notify(); // t1 will now try to acquire WL on /1/2/3 (held by t2) - this will time out
  +         t1.notify();// t1 will now try to acquire WL on /1/2/3 (held by t2) - this will time out
         }
   
         TestingUtil.sleepThread((long) 1000);
   
         synchronized (t2)
         {
  -         t2.notify(); // t2 tries to acquire WL on /a/b/c (held by t1)
  +         t2.notify();// t2 tries to acquire WL on /a/b/c (held by t1)
         }
   
         t1.join();
         t2.join();
      }
   
  +   /*
  +
  +    Commented out since JBCACHE-875 onwards, this will end up in a classic deadlock since we lock parent when removing a child.
   
      public void testCreateIfNotExistsLogic() throws CacheException, InterruptedException
      {
  @@ -202,6 +209,7 @@
         t1.join();
      }
   
  +   */
   
      public void testMoreThanOneUpgrader() throws Exception
      {
  @@ -310,11 +318,15 @@
            {
               System.out.println(getName() + ": " + t);
               if (thread_ex == null)
  +            {
                  thread_ex = t;
            }
  +         }
            if (log.isTraceEnabled())
  +         {
               log.trace("Thread " + getName() + " terminated");
         }
  +      }
   
         protected void _run() throws Exception
         {
  @@ -341,7 +353,9 @@
               try
               {
                  if (interrupted())
  +               {
                     break;
  +               }
                  tx = startTransaction();
                  log("remove(" + fqn + ")");
                  cache.remove(fqn);
  @@ -380,7 +394,9 @@
               try
               {
                  if (interrupted())
  +               {
                     break;
  +               }
                  tx = startTransaction();
                  log("put(" + fqn + ")");
                  cache.put(fqn, "foo", "bar");
  @@ -422,13 +438,13 @@
         {
            tx = startTransaction();
            log("get(" + fqn + ")");
  -         cache.get(fqn, "bla"); // acquires RL
  +         cache.get(fqn, "bla");// acquires RL
            log("done, locks: " + cache.printLockInfo());
   
            synchronized (this) {wait();}
   
            log("put(" + fqn + ")");
  -         cache.put(fqn, "key", "val"); // need to upgrade RL to WL
  +         cache.put(fqn, "key", "val");// need to upgrade RL to WL
            log("done, locks: " + cache.printLockInfo());
            tx.commit();
            log("committed TX, locks: " + cache.printLockInfo());
  @@ -458,12 +474,12 @@
            {
               log("get(" + fqn + ")");
   
  -            cache.get(fqn, "bla"); // acquires RL
  +            cache.get(fqn, "bla");// acquires RL
   
               synchronized (lock) {lock.wait();}
   
               log("put(" + fqn + ")");
  -            cache.put(fqn, "key", "val"); // need to upgrade RL to WL
  +            cache.put(fqn, "key", "val");// need to upgrade RL to WL
               log("done, locks: " + cache.printLockInfo());
               tx.commit();
               log("committed TX, locks: " + cache.printLockInfo());
  @@ -521,11 +537,11 @@
         {
            tx = startTransaction();
            log("put(" + fqn1 + ")");
  -         cache.put(fqn1, "key", "val"); // need to upgrade RL to WL
  +         cache.put(fqn1, "key", "val");// need to upgrade RL to WL
            log("done, locks: " + cache.printLockInfo());
            synchronized (this) {wait();}
            log("put(" + fqn2 + ")");
  -         cache.put(fqn2, "key", "val"); // need to upgrade RL to WL
  +         cache.put(fqn2, "key", "val");// need to upgrade RL to WL
            log("done, locks: " + cache.printLockInfo());
            tx.commit();
            log("committed TX, locks: " + cache.printLockInfo());
  
  
  
  1.5       +2 -2      JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelNoneTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- IsolationLevelNoneTest.java	6 Sep 2006 15:31:00 -0000	1.4
  +++ IsolationLevelNoneTest.java	14 Dec 2006 17:52:29 -0000	1.5
  @@ -17,7 +17,7 @@
    * Tests whether modifications within callbacks (TreeCacheListener) are handled correctly
    *
    * @author Bela Ban
  - * @version $Id: IsolationLevelNoneTest.java,v 1.4 2006/09/06 15:31:00 msurtani Exp $
  + * @version $Id: IsolationLevelNoneTest.java,v 1.5 2006/12/14 17:52:29 msurtani Exp $
    */
   public class IsolationLevelNoneTest extends TestCase
   {
  @@ -90,7 +90,7 @@
         assertTrue(cache.exists(FQN, KEY));
         assertEquals(VALUE, cache.get(FQN, KEY));
         System.out.println("cache: " + cache.toString(true) + ", locks: " + cache.printLockInfo());
  -      assertEquals(4, cache.getNumberOfLocksHeld());
  +      assertEquals(5, cache.getNumberOfLocksHeld());
         tx.commit();
      }
   
  
  
  
  1.3       +4 -1      JBossCache/tests/functional/org/jboss/cache/transaction/SuspendTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuspendTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/SuspendTxTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SuspendTxTest.java	11 Oct 2006 13:56:31 -0000	1.2
  +++ SuspendTxTest.java	14 Dec 2006 17:52:29 -0000	1.3
  @@ -47,6 +47,9 @@
       */
      public void testSuspendedLocks() throws Exception
      {
  +      // create /one first
  +      cache.put("/one", null);
  +      cache.put("/a", null);
         mgr.begin();
   
         cache.put("/one/two", "key1", "val1");
  @@ -71,7 +74,7 @@
         cache.put("/one/two", "key1", "val1");
         int numLocksBefore = cache.getNumberOfLocksHeld();
   
  -      cache.getInvocationContext().getOptionOverrides().setFailSilently(true); // will cause any current txs to be suspended for the duration of this call.
  +      cache.getInvocationContext().getOptionOverrides().setFailSilently(true);// will cause any current txs to be suspended for the duration of this call.
         cache.put(Fqn.fromString("/a/b"), "key1", "val1");
   
         assertEquals(numLocksBefore, cache.getNumberOfLocksHeld());
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 13:02:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 13:02:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r59056 -
	projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test
Message-ID: <E1Guuuw-0008Mp-0w@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 13:02:46 -0500 (Thu, 14 Dec 2006)
New Revision: 59056

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
Log:
better debuging info

Modified: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 17:14:20 UTC (rev 59055)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-14 18:02:46 UTC (rev 59056)
@@ -6,16 +6,16 @@
    <constructor-arg index="1"><value>3.1415</value></constructor-arg>
    <property name="mylist">
       <list value-type="java.lang.String">
-         <value>one</value>
-         <value>two</value>
-         <value>three</value>
+         <value>onel</value>
+         <value>twol</value>
+         <value>threel</value>
       </list>
    </property>
    <property name="myset">
       <set value-type="java.lang.String">
-         <value>one</value>
-         <value>two</value>
-         <value>one</value>
+         <value>ones</value>
+         <value>twos</value>
+         <value>ones</value>
       </set>
    </property>
    <property name="map">



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 13:10:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 13:10:49 -0500
Subject: [jboss-cvs] JBossAS SVN: r59057 -
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1Guv2f-000066-Ly@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 13:10:47 -0500 (Thu, 14 Dec 2006)
New Revision: 59057

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
Log:
typo

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-14 18:02:46 UTC (rev 59056)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBinding.java	2006-12-14 18:10:47 UTC (rev 59057)
@@ -105,7 +105,7 @@
    /**
     * The list binding
     */
-   public static final QName listTypeQName = new QName(SPRING_DEPLOYER_NS, "listOrSetType");
+   public static final QName listOrSetTypeQName = new QName(SPRING_DEPLOYER_NS, "listOrSetType");
 
    /**
     * The list element name
@@ -222,7 +222,7 @@
       SpringSchemaBindingHelper.initValueHandler(valueType);
 
       // list or set
-      TypeBinding collectionType = schemaBinding.getType(listTypeQName);
+      TypeBinding collectionType = schemaBinding.getType(listOrSetTypeQName);
       SpringSchemaBindingHelper.initCollectionHandler(collectionType);
 
       // map



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 13:25:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 13:25:53 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59058 - branches/Branch_4_0/ejb3/docs
Message-ID: <E1GuvHF-0000QI-8H@committer01.frg.pub.inap.atl.jboss.com>

Author: bdecoste
Date: 2006-12-14 13:25:51 -0500 (Thu, 14 Dec 2006)
New Revision: 59058

Modified:
   branches/Branch_4_0/ejb3/docs/RELEASE_NOTES.html
Log:
EJB3 RC9 Patch 1

Modified: branches/Branch_4_0/ejb3/docs/RELEASE_NOTES.html
===================================================================
--- branches/Branch_4_0/ejb3/docs/RELEASE_NOTES.html	2006-12-14 18:10:47 UTC (rev 59057)
+++ branches/Branch_4_0/ejb3/docs/RELEASE_NOTES.html	2006-12-14 18:25:51 UTC (rev 59058)
@@ -1,7 +1,16 @@
 <html>
 <body>
 
+Release Notes - EJB 3.0 - Version EJB 3.0 RC9 Patch 1
 
+<h2>Bug</h2>
+<ul>
+<li>[<a href='http://jira.jboss.com/jira/browse/EJBTHREE-798'>EJBTHREE-798</a>] - Implement temporary EJBTHREE-795 workaround in EJB3 codebase</li>
+<li>[<a href='http://jira.jboss.com/jira/browse/EJBTHREE-806'>EJBTHREE-806</a>] - Installer version of EJB3 incompatible with 4.0.5</li>
+</ul>
+
+
+
 Release Notes - EJB 3.0 - Version EJB 3.0 RC7 - FD
 
 <h2>Feature Request</h2>



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 13:28:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 13:28:29 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59059 - branches
Message-ID: <E1GuvJl-0000UY-LW@committer01.frg.pub.inap.atl.jboss.com>

Author: bdecoste
Date: 2006-12-14 13:28:28 -0500 (Thu, 14 Dec 2006)
New Revision: 59059

Added:
   branches/Branch_4_0_EJB3_RC9_Patch_1/
Log:


Copied: branches/Branch_4_0_EJB3_RC9_Patch_1 (from rev 59058, branches/Branch_4_0)



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 13:37:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 13:37:28 -0500
Subject: [jboss-cvs] JBossAS SVN: r59060 - in
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring:
	. deployment deployment/xml metadata
Message-ID: <E1GuvSS-0000gk-UE@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-14 13:37:14 -0500 (Thu, 14 Dec 2006)
New Revision: 59060

Added:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/AbstractConstructorArg.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/AbstractSpringDeployment.java
Removed:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java
Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
Log:
package refactoring

Deleted: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java	2006-12-14 18:28:28 UTC (rev 59059)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -1,47 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.spring.deployment;
-
-import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
-import org.jboss.beans.metadata.spi.LifecycleMetaData;
-import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
-import org.jboss.dependency.spi.ControllerState;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- */
-public class AbstractConstructorArg extends AbstractParameterMetaData
-{
-   private boolean explicitIndex;
-
-   public void setIndex(int index)
-   {
-      explicitIndex = true;
-      super.setIndex(index);
-   }
-
-   public boolean isExplicitIndex()
-   {
-      return explicitIndex;
-   }
-
-}

Deleted: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java	2006-12-14 18:28:28 UTC (rev 59059)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -1,61 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.spring.deployment;
-
-import org.jboss.beans.metadata.spi.LifecycleMetaData;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- */
-public class AbstractSpringDeployment extends AbstractKernelDeployment
-{
-   /* default init lifecycle method */
-   protected LifecycleMetaData create;
-
-   /* default destroy lifecycle method */
-   protected LifecycleMetaData destroy;
-
-   public LifecycleMetaData getCreate()
-   {
-      return create;
-   }
-
-   public void setCreate(LifecycleMetaData create)
-   {
-      create.setState(ControllerState.CREATE);
-      this.create = create;
-   }
-
-   public LifecycleMetaData getDestroy()
-   {
-      return destroy;
-   }
-
-   public void setDestroy(LifecycleMetaData destroy)
-   {
-      destroy.setState(ControllerState.CREATE);
-      this.destroy = destroy;
-   }
-
-}

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java	2006-12-14 18:28:28 UTC (rev 59059)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgHandler.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -27,7 +27,7 @@
 import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
 import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
-import org.jboss.spring.deployment.AbstractConstructorArg;
+import org.jboss.spring.metadata.AbstractConstructorArg;
 import org.xml.sax.Attributes;
 
 /**

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-14 18:28:28 UTC (rev 59059)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/ConstructorArgInterceptor.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -29,7 +29,7 @@
 import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
 import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
 import org.jboss.beans.metadata.spi.ParameterMetaData;
-import org.jboss.spring.deployment.AbstractConstructorArg;
+import org.jboss.spring.metadata.AbstractConstructorArg;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
 
 /**

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java	2006-12-14 18:28:28 UTC (rev 59059)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansHandler.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -25,7 +25,7 @@
 import javax.xml.namespace.QName;
 
 import org.jboss.beans.metadata.plugins.AbstractLifecycleMetaData;
-import org.jboss.spring.deployment.AbstractSpringDeployment;
+import org.jboss.spring.metadata.AbstractSpringDeployment;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
 import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
 import org.xml.sax.Attributes;

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-14 18:28:28 UTC (rev 59059)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeansInterceptor.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -28,14 +28,8 @@
 
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
 import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
-import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
-import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
-import org.jboss.beans.metadata.spi.ConstructorMetaData;
-import org.jboss.beans.metadata.spi.ParameterMetaData;
 import org.jboss.beans.metadata.spi.BeanMetaDataFactory;
-import org.jboss.spring.deployment.AbstractConstructorArg;
-import org.jboss.spring.deployment.AbstractSpringDeployment;
-import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+import org.jboss.spring.metadata.AbstractSpringDeployment;
 
 /**
  * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>

Copied: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/AbstractConstructorArg.java (from rev 59043, projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java)
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractConstructorArg.java	2006-12-14 13:39:30 UTC (rev 59043)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/AbstractConstructorArg.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -0,0 +1,47 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.metadata;
+
+import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+import org.jboss.beans.metadata.spi.LifecycleMetaData;
+import org.jboss.beans.metadata.plugins.AbstractParameterMetaData;
+import org.jboss.dependency.spi.ControllerState;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class AbstractConstructorArg extends AbstractParameterMetaData
+{
+   private boolean explicitIndex;
+
+   public void setIndex(int index)
+   {
+      explicitIndex = true;
+      super.setIndex(index);
+   }
+
+   public boolean isExplicitIndex()
+   {
+      return explicitIndex;
+   }
+
+}

Copied: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/AbstractSpringDeployment.java (from rev 59043, projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java)
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/AbstractSpringDeployment.java	2006-12-14 13:39:30 UTC (rev 59043)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/metadata/AbstractSpringDeployment.java	2006-12-14 18:37:14 UTC (rev 59060)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.spring.metadata;
+
+import org.jboss.beans.metadata.spi.LifecycleMetaData;
+import org.jboss.dependency.spi.ControllerState;
+import org.jboss.kernel.plugins.deployment.AbstractKernelDeployment;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class AbstractSpringDeployment extends AbstractKernelDeployment
+{
+   /* default init lifecycle method */
+   protected LifecycleMetaData create;
+
+   /* default destroy lifecycle method */
+   protected LifecycleMetaData destroy;
+
+   public LifecycleMetaData getCreate()
+   {
+      return create;
+   }
+
+   public void setCreate(LifecycleMetaData create)
+   {
+      create.setState(ControllerState.CREATE);
+      this.create = create;
+   }
+
+   public LifecycleMetaData getDestroy()
+   {
+      return destroy;
+   }
+
+   public void setDestroy(LifecycleMetaData destroy)
+   {
+      destroy.setState(ControllerState.CREATE);
+      this.destroy = destroy;
+   }
+
+}



From galder.zamarreno at jboss.com  Thu Dec 14 13:52:40 2006
From: galder.zamarreno at jboss.com (Galder Zamarreno)
Date: Thu, 14 Dec 2006 13:52:40 -0500
Subject: [jboss-cvs] JBossCache/etc  ...
Message-ID: <E1GuvhA-000112-Ba@committer01.frg.pub.inap.atl.jboss.com>

  User: gzamarreno
  Date: 06/12/14 13:52:40

  Modified:    etc      cache-jdbc.properties
  Log:
  [JBCACHE-879] drop table set to false in cache-jdbc.properties. Otherwise JDBCCacheLoaderPerfTest.tesGet() won't get anything.
  cache.jdbc.table.drop added to JDBCCacheLoaderPerfTest.configureCache(). In tearDown() we evict cache not remove otherwise jdbc data is lost. results of get and remove operations are tested for not null.
  
  Revision  Changes    Path
  1.5       +1 -1      JBossCache/etc/cache-jdbc.properties
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: cache-jdbc.properties
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/cache-jdbc.properties,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- cache-jdbc.properties	31 Jan 2006 18:30:47 -0000	1.4
  +++ cache-jdbc.properties	14 Dec 2006 18:52:40 -0000	1.5
  @@ -2,7 +2,7 @@
   # JBoss Cache table properties
   cache.jdbc.table.name=jbosscache
   cache.jdbc.table.create=true
  -cache.jdbc.table.drop=true
  +cache.jdbc.table.drop=false
   cache.jdbc.table.primarykey=jbosscache_pk
   cache.jdbc.fqn.column=fqn
   cache.jdbc.fqn.type=varchar(255)
  
  
  


From galder.zamarreno at jboss.com  Thu Dec 14 13:52:40 2006
From: galder.zamarreno at jboss.com (Galder Zamarreno)
Date: Thu, 14 Dec 2006 13:52:40 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache/loader  ...
Message-ID: <E1GuvhA-000119-Fg@committer01.frg.pub.inap.atl.jboss.com>

  User: gzamarreno
  Date: 06/12/14 13:52:40

  Modified:    tests/perf/org/jboss/cache/loader 
                        JDBCCacheLoaderPerfTest.java
  Log:
  [JBCACHE-879] drop table set to false in cache-jdbc.properties. Otherwise JDBCCacheLoaderPerfTest.tesGet() won't get anything.
  cache.jdbc.table.drop added to JDBCCacheLoaderPerfTest.configureCache(). In tearDown() we evict cache not remove otherwise jdbc data is lost. results of get and remove operations are tested for not null.
  
  Revision  Changes    Path
  1.9       +5 -4      JBossCache/tests/perf/org/jboss/cache/loader/JDBCCacheLoaderPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JDBCCacheLoaderPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/loader/JDBCCacheLoaderPerfTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- JDBCCacheLoaderPerfTest.java	15 Nov 2006 23:48:32 -0000	1.8
  +++ JDBCCacheLoaderPerfTest.java	14 Dec 2006 18:52:40 -0000	1.9
  @@ -51,7 +51,7 @@
      {
         if (cache != null)
         {
  -         cache.remove("/");
  +         cache.evict(Fqn.fromString("/"));
            cache.stop();
            cache = null;
   
  @@ -80,7 +80,8 @@
                 "cache.jdbc.url=" + prop.getProperty("cache.jdbc.url") + "\n" +
                 "cache.jdbc.user=" + prop.getProperty("cache.jdbc.user") + "\n" +
                 "cache.jdbc.password=" + prop.getProperty("cache.jdbc.password") + "\n" +
  -              "cache.jdbc.node.type=" + prop.getProperty("cache.jdbc.node.type");
  +              "cache.jdbc.node.type=" + prop.getProperty("cache.jdbc.node.type") + "\n" +
  +              "cache.jdbc.table.drop=" + prop.getProperty("cache.jdbc.table.drop");
         cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.JDBCCacheLoader", props, false, true, false));
      }
   
  @@ -138,7 +139,7 @@
                     long start = System.currentTimeMillis();
                     for (int j = 0; j < NUM_TIMES_PER_THREAD; j++)
                     {
  -                     cache.get(fqn, "key" + j);
  +                     assertNotNull(cache.get(fqn, "key" + j));
                        long timeTaken = System.currentTimeMillis() - start;
                        getStat[j] = timeTaken;
                     }
  @@ -178,7 +179,7 @@
                     long start = System.currentTimeMillis();
                     for (int j = 0; j < NUM_TIMES_PER_THREAD; j++)
                     {
  -                     cache.remove(fqn, "key" + j);
  +                     assertNotNull(cache.remove(fqn, "key" + j));
                        cache.evict(fqn);
                        long timeTaken = System.currentTimeMillis() - start;
                        removeStat[j] = timeTaken;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 14:33:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 14:33:11 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1794 - in trunk:
	src/main/org/jboss/jms/client
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state src/main/org/jboss/jms/delegate
	src/main/org/jboss/jms/message src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/jms/tx tests
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/tools/jboss
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GuwKN-0001ym-AB@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-14 14:32:42 -0500 (Thu, 14 Dec 2006)
New Revision: 1794

Added:
   trunk/src/main/org/jboss/jms/server/endpoint/Ack.java
   trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
   trunk/src/main/org/jboss/jms/server/endpoint/DefaultAck.java
   trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
   trunk/src/main/org/jboss/jms/server/endpoint/DeliveryRecovery.java
   trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
Removed:
   trunk/src/main/org/jboss/jms/tx/AckInfo.java
   trunk/src/main/org/jboss/jms/tx/TxState.java
Modified:
   trunk/src/main/org/jboss/jms/client/Closeable.java
   trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
   trunk/src/main/org/jboss/jms/client/JBossSession.java
   trunk/src/main/org/jboss/jms/client/container/AsfAspect.java
   trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java
   trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   trunk/src/main/org/jboss/jms/client/container/FactoryAspect.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java
   trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
   trunk/src/main/org/jboss/jms/message/BytesMessageProxy.java
   trunk/src/main/org/jboss/jms/message/JBossMessage.java
   trunk/src/main/org/jboss/jms/message/MapMessageProxy.java
   trunk/src/main/org/jboss/jms/message/MessageProxy.java
   trunk/src/main/org/jboss/jms/message/ObjectMessageProxy.java
   trunk/src/main/org/jboss/jms/message/StreamMessageProxy.java
   trunk/src/main/org/jboss/jms/message/TextMessageProxy.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/BrowserAdvised.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionAdvised.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/src/main/org/jboss/jms/tx/ResourceManager.java
   trunk/src/main/org/jboss/jms/tx/TransactionRequest.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/tools/jboss/MBeanConfigurationElement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
Major refactoring so deliveries are now managed by sessions.



Modified: trunk/src/main/org/jboss/jms/client/Closeable.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/Closeable.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/Closeable.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -47,7 +47,6 @@
     * @throws JMSException
     */
    void closing() throws JMSException;
-
-   boolean isClosed();
-  
+   
+   boolean isClosed() throws JMSException;
 }

Modified: trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -72,37 +72,37 @@
    
    // Attributes ----------------------------------------------------
    
-   protected ConsumerDelegate cons;
+   private ConsumerDelegate cons;
    
-   protected SessionDelegate sess;
+   private SessionDelegate sess;
    
-   protected int consumerID;
+   private int consumerID;
    
    /** The destination this consumer will receive messages from */
-   protected Destination destination;
+   private Destination destination;
    
    /** The ServerSessionPool that is implemented by the AS */
-   protected ServerSessionPool serverSessionPool;
+   private ServerSessionPool serverSessionPool;
    
    /** The maximum number of messages that a single session will be loaded with. */
-   protected int maxMessages;
+   private int maxMessages;
    
    /** Is the ConnectionConsumer closed? */
-   protected volatile boolean closed;
+   private volatile boolean closed;
      
    /** The "listening" thread that gets messages from destination and queues
    them for delivery to sessions */
-   protected Thread internalThread;
+   private Thread internalThread;
    
    /** The thread id */
-   protected int id;
+   private int id;
    
    /** The thread id generator */
-   protected static SynchronizedInt threadId = new SynchronizedInt(0);
+   private static SynchronizedInt threadId = new SynchronizedInt(0);
    
-   protected Object closeLock = new Object();      
+   private int maxDeliveries;
    
-   protected int maxDeliveries;
+   private long channelID;
    
    // Static --------------------------------------------------------
    
@@ -154,6 +154,8 @@
 
       this.consumerID = state.getConsumerID();      
       
+      this.channelID = state.getChannelId();
+      
       this.maxDeliveries = state.getMaxDeliveries();
 
       id = threadId.increment();
@@ -302,7 +304,7 @@
                for (int i = 0; i < mesList.size(); i++)
                {
                   MessageProxy m = (MessageProxy)mesList.get(i);
-                  session.addAsfMessage(m, consumerID, cons, maxDeliveries);
+                  session.addAsfMessage(m, consumerID, channelID, maxDeliveries);
                   if (trace) { log.trace("added " + m + " to session"); }
                }
 

Modified: trunk/src/main/org/jboss/jms/client/JBossSession.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossSession.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/JBossSession.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -502,9 +502,9 @@
     * This method is used by the JBossConnectionConsumer to load up the session
     * with messages to be processed by the session's run() method
     */
-   void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons, int maxDeliveries)
+   void addAsfMessage(MessageProxy m, int consumerID, long channelID, int maxDeliveries)
    {
-      delegate.addAsfMessage(m, consumerID, cons, maxDeliveries);
+      delegate.addAsfMessage(m, consumerID, channelID, maxDeliveries);
    }
       
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/container/AsfAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/AsfAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/AsfAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -129,7 +129,7 @@
 
       MessageProxy m = (MessageProxy)mi.getArguments()[0];
       int theConsumerID = ((Integer)mi.getArguments()[1]).intValue();
-      ConsumerDelegate cons = (ConsumerDelegate)mi.getArguments()[2];
+      long channelID = ((Long)mi.getArguments()[2]).longValue();
       int maxDeliveries = ((Integer)mi.getArguments()[3]).intValue();
       
       if (m == null)
@@ -140,7 +140,7 @@
       AsfMessageHolder holder = new AsfMessageHolder();
       holder.msg = m;
       holder.consumerID = theConsumerID;
-      holder.consumerDelegate = cons;
+      holder.channelID = channelID;
       holder.maxDeliveries = maxDeliveries;
       
       msgs.add(holder);
@@ -164,7 +164,8 @@
 
          if (trace) { log.trace("sending " + holder.msg + " to the message listener" ); }
          
-         MessageCallbackHandler.callOnMessage(del, sessionListener, holder.consumerID, false,
+         MessageCallbackHandler.callOnMessage(del, sessionListener, holder.consumerID,
+                                              holder.channelID, false,
                                               holder.msg, ackMode, holder.maxDeliveries);                          
       }
       
@@ -184,11 +185,11 @@
 
    // Inner Classes --------------------------------------------------
    
-   protected static class AsfMessageHolder
+   private static class AsfMessageHolder
    {
-      MessageProxy msg;
-      int consumerID;
-      ConsumerDelegate consumerDelegate;
-      int maxDeliveries;
+      private MessageProxy msg;
+      private int consumerID;
+      private long channelID;
+      private int maxDeliveries;
    }
 }

Modified: trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -110,11 +110,6 @@
       return sb.toString();
    }
 
-   public boolean isClosed()
-   {
-      return state == IN_CLOSE || state == CLOSED;
-   }
-
    // Interceptor implementation -----------------------------------
 
    public String getName()
@@ -135,6 +130,7 @@
 
       if ("isClosed".equals(methodName))
       {
+         //Actually this is badly named, it returns true if it's closing as well as closed
          return new Boolean(isClosed());
       }
 
@@ -317,6 +313,11 @@
    // Package Private ------------------------------------------------
 
    // Private --------------------------------------------------------
+   
+   private boolean isClosed()
+   {
+      return state == IN_CLOSE || state == CLOSED;
+   }
 
    // Inner Classes --------------------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -74,6 +74,7 @@
       ConsumerState consumerState = (ConsumerState)((DelegateSupport)consumerDelegate).getState();
       int serverId = connectionState.getServerID();
       int consumerID = consumerState.getConsumerID();
+      long channelID = consumerState.getChannelId();
       int prefetchSize = consumerState.getPrefetchSize();
       QueuedExecutor sessionExecutor = sessionState.getExecutor();
       int maxDeliveries = consumerState.getMaxDeliveries();
@@ -81,12 +82,13 @@
       MessageCallbackHandler messageHandler =
          new MessageCallbackHandler(isCC, sessionState.getAcknowledgeMode(),
                                     sessionDelegate, consumerDelegate, consumerID,
+                                    channelID,
                                     prefetchSize, sessionExecutor, maxDeliveries);
       
       sessionState.addCallbackHandler(messageHandler);
       
       CallbackManager cm = connectionState.getRemotingConnection().getCallbackManager();
-      cm.registerHandler(serverId, consumerID, messageHandler);
+      cm.registerHandler(consumerID, messageHandler);
          
       consumerState.setMessageCallbackHandler(messageHandler);
       
@@ -115,7 +117,7 @@
       sessionState.removeCallbackHandler(consumerState.getMessageCallbackHandler());
 
       CallbackManager cm = connectionState.getRemotingConnection().getCallbackManager();
-      cm.unregisterHandler(connectionState.getServerID(), consumerState.getConsumerID());
+      cm.unregisterHandler(consumerState.getConsumerID());
             
       return res;
    }      

Modified: trunk/src/main/org/jboss/jms/client/container/FactoryAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/FactoryAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/FactoryAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -65,21 +65,21 @@
    {
       JBossMessage jbm = new JBossMessage(0);
        
-      return new MessageProxy(jbm, 0);
+      return new MessageProxy(jbm);
    }
    
    public Object handleCreateBytesMessage(Invocation invocation) throws Throwable
    {
       JBossBytesMessage jbm = new JBossBytesMessage(0);
          
-      return new BytesMessageProxy(jbm, 0);
+      return new BytesMessageProxy(jbm);
    }
    
    public Object handleCreateMapMessage(Invocation invocation) throws Throwable
    {
       JBossMapMessage jbm = new JBossMapMessage(0);
        
-      return new MapMessageProxy(jbm, 0);      
+      return new MapMessageProxy(jbm);      
    }
    
    public Object handleCreateObjectMessage(Invocation invocation) throws Throwable
@@ -93,14 +93,14 @@
          jbm.setObject((Serializable)mi.getArguments()[0]);
       }
       
-      return new ObjectMessageProxy(jbm, 0);
+      return new ObjectMessageProxy(jbm);
    }
    
    public Object handleCreateStreamMessage(Invocation invocation) throws Throwable
    {
       JBossStreamMessage jbm = new JBossStreamMessage(0);
       
-      return new StreamMessageProxy(jbm, 0);
+      return new StreamMessageProxy(jbm);
    }
    
    public Object handleCreateTextMessage(Invocation invocation) throws Throwable
@@ -114,7 +114,7 @@
          jbm.setText((String)mi.getArguments()[0]);
       }
       
-      return new TextMessageProxy(jbm, 0);
+      return new TextMessageProxy(jbm);
    }   
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -23,11 +23,10 @@
 package org.jboss.jms.client.container;
 
 import java.util.ArrayList;
-import java.util.HashSet;
+import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 
 import javax.jms.JMSException;
 
@@ -49,9 +48,11 @@
 import org.jboss.jms.client.state.HierarchicalStateSupport;
 import org.jboss.jms.client.state.ProducerState;
 import org.jboss.jms.client.state.SessionState;
+import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
@@ -340,16 +341,21 @@
       // Transfer attributes from newDelegate to failedDelegate
       failedConnDelegate.copyAttributes(newConnDelegate);
 
-      int oldServerId = failedState.getServerID();
-
       CallbackManager oldCallbackManager = failedState.getRemotingConnection().getCallbackManager();
 
       //We need to update some of the attributes on the state
       failedState.copyState(newState);
+      
+      //Map of old session id to new session state
+      Map oldNewSessionStateMap = new HashMap();
 
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
+         
+         if (trace) { log.trace("Failed session state has " + failedSessionState.getToAck().size() + " deliveries"); }
+         
+         int oldSessionId = failedSessionState.getSessionId();
 
          ClientSessionDelegate failedSessionDelegate =
             (ClientSessionDelegate)failedSessionState.getDelegate();
@@ -360,11 +366,15 @@
                                   failedSessionState.isXA());
 
          SessionState newSessionState = (SessionState)newSessionDelegate.getState();
+         
+         if (trace) { log.trace("New session state has " + newSessionState.getToAck().size() + " deliveries"); }
+         
+         oldNewSessionStateMap.put(new Integer(oldSessionId), failedSessionState);
 
          failedSessionDelegate.copyAttributes(newSessionDelegate);
 
          //We need to update some of the attributes on the state
-         newSessionState.copyState(newSessionState);
+         failedSessionState.copyState(newSessionState);
 
          if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
 
@@ -373,8 +383,6 @@
          // TODO Why is this clone necessary?
          children.addAll(failedSessionState.getChildren());
 
-         Set consumerIds = new HashSet();
-
          for (Iterator j = children.iterator(); j.hasNext(); )
          {
             HierarchicalStateSupport sessionChild = (HierarchicalStateSupport)j.next();
@@ -386,48 +394,58 @@
             else if (sessionChild instanceof ConsumerState)
             {
                handleFailoverOnConsumer(failedConnDelegate,
-                                        failedState,
-                                        failedSessionState,
                                         (ConsumerState)sessionChild,
                                         failedSessionDelegate,
-                                        oldServerId,
                                         oldCallbackManager);
-
-               // We add the new consumer id to the list of old ids
-               consumerIds.add(new Integer(((ConsumerState)sessionChild).getConsumerID()));
             }
             else if (sessionChild instanceof BrowserState)
             {
                 handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
             }
          }
-
-         /* Now we must sent the list of unacked AckInfos to the server - so the consumers
-          * delivery lists can be repopulated
-          */
+      }
+      
+      //First we must tell the resource manager to substitute old session id for new session id
+      //Note we MUST submit the entire mapping in one operation since there may be overlap between
+      //old and new session id, and we don't want to overwrite keys in the map
+      
+      failedState.getResourceManager().handleFailover(oldNewSessionStateMap);
+      
+      Iterator iter = oldNewSessionStateMap.values().iterator();
+            
+      while (iter.hasNext())
+      {
+         SessionState state = (SessionState)iter.next();
+         
          List ackInfos = null;
-
-         if (!failedSessionState.isTransacted() && !failedSessionState.isXA())
+         
+         if (!state.isTransacted() && !state.isXA())
          {
-            /*
-            Now we remove any unacked np messages - this is because we don't want to ack them
-            since the server won't know about them and will barf
-            */
+            //Now we remove any unacked np messages - this is because we don't want to ack them
+            //since the server won't know about them and will barf
+                        
+            Iterator iter2 = state.getToAck().iterator();
+            
+            if (trace) { log.trace("Removing any np deliveries"); }
 
-            Iterator iter = newSessionState.getToAck().iterator();
-
-            while (iter.hasNext())
+            while (iter2.hasNext())
             {
-               AckInfo info = (AckInfo)iter.next();
+               DeliveryInfo info = (DeliveryInfo)iter2.next();
 
-               if (!info.getMessage().getMessage().isReliable())
+               if (!info.getMessageProxy().getMessage().isReliable())
                {
-                  iter.remove();
+                  iter2.remove();
+                  
+                  if (trace) { log.trace("Removed np delivery: " + info.getDeliveryId()); }
                }
             }
+            
+            if (trace) { log.trace("Session is not transacted, retrieving deliveries from session state"); }
 
             //Get the ack infos from the list in the session state
-            ackInfos = failedSessionState.getToAck();
+            ackInfos = state.getToAck();
+            
+            if (trace) { log.trace("Retrieved " + ackInfos.size() + " deliveries"); }
          }
          else
          {
@@ -435,24 +453,36 @@
             //btw we have kept the old resource manager
             ResourceManager rm = failedState.getResourceManager();
 
-            // Remove any non persistent acks - so server doesn't barf on commit
-
-            rm.removeNonPersistentAcks(consumerIds);
-
-            ackInfos = rm.getAckInfosForConsumerIds(consumerIds);
+            ackInfos = rm.getDeliveriesForSession(state.getSessionId());
          }
 
          if (!ackInfos.isEmpty())
+         {                        
+            SessionDelegate newDelegate = (SessionDelegate)state.getDelegate();
+            
+            List recoveryInfos = new ArrayList();
+            
+            for (Iterator iter2 = ackInfos.iterator(); iter2.hasNext(); )
+            {
+               DeliveryInfo info = (DeliveryInfo)iter2.next();
+               
+               DeliveryRecovery recInfo =
+                  new DeliveryRecovery(info.getMessageProxy().getDeliveryId(),                                       
+                                       info.getMessageProxy().getMessage().getMessageID(),
+                                       info.getChannelId());
+               
+               recoveryInfos.add(recInfo);
+            }
+            
+            if (trace) { log.trace(this + " sending delivery recovery info: " + recoveryInfos); }
+            newDelegate.recoverDeliveries(recoveryInfos);
+         }
+         else
          {
-            log.info("Sending " + ackInfos.size() + " unacked");
-            newSessionDelegate.sendUnackedAckInfos(ackInfos);
+            if (trace) { log.trace(this + " no delivery recovery info to send"); }
          }
       }
 
-      //TODO
-      //If the session had consumers which are now closed then there is no way to recreate them on the server
-      //we need to store with session id
-
       // We must not start the connection until the end
       if (failedState.isStarted())
       {
@@ -463,11 +493,8 @@
    }
 
    private void handleFailoverOnConsumer(ClientConnectionDelegate failedConnectionDelegate,
-                                         ConnectionState failedConnectionState,
-                                         SessionState failedSessionState,
                                          ConsumerState failedConsumerState,
                                          ClientSessionDelegate failedSessionDelegate,
-                                         int oldServerID,
                                          CallbackManager oldCallbackManager)
       throws JMSException
    {
@@ -498,19 +525,21 @@
       // Update attributes on the old state
       failedConsumerState.copyState(newState);
 
-      if (failedSessionState.isTransacted() || failedSessionState.isXA())
-      {
-         // Replace the old consumer id with the new consumer id
+//      if (failedSessionState.isTransacted() || failedSessionState.isXA())
+//      {
+//         // Replace the old consumer id with the new consumer id
+//
+//         ResourceManager rm = failedConnectionState.getResourceManager();
+//
+//         todo - we need to replace the sesion id
+//         
+//         rm.handleFailover(oldConsumerID, failedConsumerState.getConsumerID());
+//      }
 
-         ResourceManager rm = failedConnectionState.getResourceManager();
-
-         rm.handleFailover(oldConsumerID, failedConsumerState.getConsumerID());
-      }
-
       // We need to re-use the existing message callback handler
 
       MessageCallbackHandler oldHandler =
-         oldCallbackManager.unregisterHandler(oldServerID, oldConsumerID);
+         oldCallbackManager.unregisterHandler(oldConsumerID);
 
       ConnectionState newConnectionState = (ConnectionState)failedConnectionDelegate.getState();
 
@@ -519,7 +548,7 @@
 
       // Remove the new handler
       MessageCallbackHandler newHandler = newCallbackManager.
-         unregisterHandler(newConnectionState.getServerID(), newState.getConsumerID());
+         unregisterHandler(newState.getConsumerID());
 
       log.debug("New handler is " + System.identityHashCode(newHandler));
 
@@ -528,8 +557,7 @@
 
       //Now we re-register the old handler with the new callback manager
 
-      newCallbackManager.registerHandler(newConnectionState.getServerID(),
-                                         newState.getConsumerID(),
+      newCallbackManager.registerHandler(newState.getConsumerID(),
                                          oldHandler);
 
       // We don't need to add the handler to the session state since it is already there - we

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -36,7 +36,9 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.server.endpoint.Cancel;
+import org.jboss.jms.server.endpoint.DefaultAck;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.util.Util;
 
@@ -79,15 +81,16 @@
       List cancels = new ArrayList();
       for(Iterator i = state.getToAck().iterator(); i.hasNext(); )
       {
-         AckInfo ack = (AckInfo)i.next();
+         DeliveryInfo ack = (DeliveryInfo)i.next();
          if (ackMode == Session.AUTO_ACKNOWLEDGE ||
              ackMode == Session.DUPS_OK_ACKNOWLEDGE)
          {
-            acks.add(ack);            
+            acks.add(new DefaultAck(ack.getMessageProxy().getDeliveryId()));            
          }
          else
          {
-            cancels.add(ack);
+            Cancel cancel = new Cancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
+            cancels.add(cancel);
          }
          i.remove();
       }
@@ -104,6 +107,7 @@
       }
       if (!cancels.isEmpty())
       {
+         log.info("Calling canceldeliveries: " + cancels.size());
          del.cancelDeliveries(cancels);
       }
 
@@ -136,25 +140,26 @@
           state.getCurrentTxId() == null)
       {
          // We collect acknowledgments (and not transact them) for CLIENT, AUTO and DUPS_OK, and
-         // also for XA sessions not enrolled in a global transaction.
-
-         SessionDelegate del = (SessionDelegate)mi.getTargetObject();
-         
+         // also for XA sessions not enlisted in a global transaction.
+ 
          // We store the ack in a list for later acknowledgement or recovery
     
          Object[] args = mi.getArguments();
-         MessageProxy mp = (MessageProxy)args[0];
-         int consumerID = ((Integer)args[1]).intValue();
-         AckInfo info = new AckInfo(mp, consumerID);
-         
+         DeliveryInfo info = (DeliveryInfo)args[0];
+
          state.getToAck().add(info);
          
-         if (trace) { log.trace("ack mode is " + Util.acknowledgmentModeToString(ackMode)+ ", acknowledged on " + del); }
+         if (trace)
+         { 
+            SessionDelegate del = (SessionDelegate)mi.getTargetObject();            
+            log.trace("ack mode is " + Util.acknowledgmentModeToString(ackMode)+ ", acknowledged on " + del);
+         }
       }
 
       return invocation.invokeNext();
    }
    
+   /* Used for client acknowledge */
    public Object handleAcknowledgeAll(Invocation invocation) throws Throwable
    {    
       MethodInvocation mi = (MethodInvocation)invocation;
@@ -187,7 +192,7 @@
       
       if (ackMode == Session.AUTO_ACKNOWLEDGE ||
           ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
-          ackMode != Session.CLIENT_ACKNOWLEDGE && state.getCurrentTxId() == null)
+          (ackMode != Session.CLIENT_ACKNOWLEDGE && state.getCurrentTxId() == null))
       {
          // We acknowledge immediately on a non-transacted session that does not want to
          // CLIENT_ACKNOWLEDGE, or an XA session not enrolled in a global transaction.
@@ -207,16 +212,21 @@
                                                "There are " + acks.size());
             }
             
-            AckInfo ack = (AckInfo)acks.get(0);
+            DeliveryInfo ack = (DeliveryInfo)acks.get(0);
             
             if (cancel)
             {
-               sd.cancelDeliveries(acks);
+               List cancels = new ArrayList();
+               Cancel c = new Cancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
+               cancels.add(c);
+               sd.cancelDeliveries(cancels);
             }
             else
             {
                sd.acknowledge(ack);
             }
+            
+            //TODO we can optimise this for the auto_ack case (i.e. not store in list and have to clear each time)
             state.getToAck().clear();
          }
          else
@@ -302,16 +312,17 @@
       // Need to be recovered in reverse order.
       for (int i = toRedeliver.size() - 1; i >= 0; i--)
       {
-         AckInfo info = (AckInfo)toRedeliver.get(i);
-         MessageProxy proxy = info.getMessage();        
+         DeliveryInfo info = (DeliveryInfo)toRedeliver.get(i);
+         MessageProxy proxy = info.getMessageProxy();        
          
-         MessageCallbackHandler handler = state.getCallbackHandler(info.getConsumerID());
+         MessageCallbackHandler handler = state.getCallbackHandler(info.getConsumerId());
               
          if (handler == null)
          {
             // This is ok. The original consumer has closed, this message wil get cancelled back
             // to the channel.
-            toCancel.addFirst(info);
+            Cancel cancel = new Cancel(info.getMessageProxy().getDeliveryId(), info.getMessageProxy().getDeliveryCount());
+            toCancel.addFirst(cancel);
          }
          else
          {

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -28,6 +28,7 @@
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConsumerDelegate;
 import org.jboss.jms.client.delegate.ClientProducerDelegate;
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.remoting.ConsolidatedRemotingConnectionListener;
@@ -40,7 +41,6 @@
 import org.jboss.jms.delegate.BrowserDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.delegate.ProducerDelegate;
-import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
@@ -132,7 +132,7 @@
 
    public Object handleCreateSessionDelegate(Invocation invocation) throws Throwable
    {
-      SessionDelegate sessionDelegate = (SessionDelegate)invocation.invokeNext();
+      ClientSessionDelegate sessionDelegate = (ClientSessionDelegate)invocation.invokeNext();
       DelegateSupport delegate = (DelegateSupport)sessionDelegate;
 
       delegate.init();

Modified: trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -32,8 +32,8 @@
 import org.jboss.jms.client.state.HierarchicalState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
-import org.jboss.jms.message.MessageProxy;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.message.JBossMessage;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.tx.LocalTx;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
@@ -164,7 +164,7 @@
 
          if (trace) { log.trace("sending message " + m + " transactionally, queueing on resource manager"); }
 
-         connState.getResourceManager().addMessage(txID, m);
+         connState.getResourceManager().addMessage(txID, state.getSessionId(), (JBossMessage)m);
 
          // ... and we don't invoke any further interceptors in the stack
          return null;
@@ -185,16 +185,16 @@
          // the session is non-XA and transacted, or XA and enrolled in a global transaction. An
          // XA session that has not been enrolled in a global transaction behaves as a
          // non-transacted session.
+         
+         MethodInvocation mi = (MethodInvocation)invocation;
+         
+         DeliveryInfo info = (DeliveryInfo)mi.getArguments()[0];
 
-         MethodInvocation mi = (MethodInvocation)invocation;
-         MessageProxy proxy = (MessageProxy)mi.getArguments()[0];
-         int consumerID = ((Integer)mi.getArguments()[1]).intValue();
-         AckInfo info = new AckInfo(proxy, consumerID);
          ConnectionState connState = (ConnectionState)state.getParent();
 
          if (trace) { log.trace("sending acknowlegment transactionally, queueing on resource manager"); }
 
-         connState.getResourceManager().addAck(txID, info);
+         connState.getResourceManager().addAck(txID, state.getSessionId(), info);
       }
 
       return null;

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -43,7 +43,8 @@
 import org.jboss.jms.message.ObjectMessageProxy;
 import org.jboss.jms.message.StreamMessageProxy;
 import org.jboss.jms.message.TextMessageProxy;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.server.endpoint.Ack;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.remoting.Client;
 
 /**
@@ -111,7 +112,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void acknowledge(AckInfo ackInfo) throws JMSException
+   public void acknowledge(Ack ack) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -120,7 +121,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void acknowledgeBatch(List ackInfos) throws JMSException
+   public void acknowledgeBatch(List acks) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -313,7 +314,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void preDeliver(MessageProxy proxy, int consumerID) throws JMSException
+   public void preDeliver(DeliveryInfo deliveryInfo) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -404,8 +405,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void addAsfMessage(MessageProxy m, int consumerID,
-                             ConsumerDelegate cons, int maxDeliveries)
+   public void addAsfMessage(MessageProxy m, int consumerID, long channelId, int maxDeliveries)
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -432,7 +432,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   public void recoverDeliveries(List ackInfos) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }

Modified: trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -40,6 +40,9 @@
  * The CallbackManager is an InvocationHandler used for handling callbacks to message consumers.
  * The callback is received and dispatched off to the relevant consumer.
  * 
+ * There is one instance of this class per remoting connection - which is to a unique server - therefore
+ * there is no need to add the server id to the key when doing look ups
+ * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version 1.1
@@ -76,15 +79,13 @@
    {
       MessagingMarshallable mm = (MessagingMarshallable)callback.getParameter();
       ClientDelivery dr = (ClientDelivery)mm.getLoad();
-      Long lookup = computeLookup(dr.getServerId(), dr.getConsumerId());
       List msgs = dr.getMessages();
 
-      MessageCallbackHandler handler = (MessageCallbackHandler)callbackHandlers.get(lookup);
+      MessageCallbackHandler handler = (MessageCallbackHandler)callbackHandlers.get(new Integer(dr.getConsumerId()));
 
       if (handler == null)
       {
-         throw new IllegalStateException("Cannot find handler for consumer: " + dr.getConsumerId() +
-                                         " and server " + dr.getServerId());
+         throw new IllegalStateException("Cannot find handler for consumer: " + dr.getConsumerId());
       }
 
       handler.handleMessage(msgs);
@@ -92,18 +93,14 @@
 
    // Public --------------------------------------------------------
 
-   public void registerHandler(int serverID, int consumerID, MessageCallbackHandler handler)
+   public void registerHandler(int consumerID, MessageCallbackHandler handler)
    {
-      Long lookup = computeLookup(serverID, consumerID);
-
-      callbackHandlers.put(lookup, handler);
+      callbackHandlers.put(new Integer(consumerID), handler);
    }
 
-   public MessageCallbackHandler unregisterHandler(int serverID, int consumerID)
+   public MessageCallbackHandler unregisterHandler(int consumerID)
    { 
-      Long lookup = computeLookup(serverID, consumerID);
-
-      return (MessageCallbackHandler)callbackHandlers.remove(lookup);
+      return (MessageCallbackHandler)callbackHandlers.remove(new Integer(consumerID));
    }
 
    // Package protected ---------------------------------------------
@@ -112,17 +109,6 @@
 
    // Private -------------------------------------------------------
 
-   private Long computeLookup(int serverID, int consumerID)
-   {
-      long id1 = serverID;
-
-      id1 <<= 32;
-
-      long lookup = id1 | consumerID;
-
-      return new Long(lookup);
-   }
-
    // Inner classes -------------------------------------------------
 
 }

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -34,9 +34,9 @@
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.server.endpoint.Cancel;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.Message;
 import org.jboss.messaging.util.Future;
 import org.jboss.remoting.callback.HandleCallbackException;
 
@@ -68,13 +68,14 @@
    public static void callOnMessage(SessionDelegate sess,
                                     MessageListener listener,
                                     int consumerID,
+                                    long channelID,
                                     boolean isConnectionConsumer,
                                     MessageProxy m,
                                     int ackMode,
                                     int maxDeliveries)
       throws JMSException
    {
-      preDeliver(sess, consumerID, m, isConnectionConsumer);
+      preDeliver(sess, consumerID, channelID, m, isConnectionConsumer);
                   
       int tries = 0;
       
@@ -141,6 +142,7 @@
    
    protected static void preDeliver(SessionDelegate sess,
                                     int consumerID,
+                                    long channelID,
                                     MessageProxy m,
                                     boolean isConnectionConsumer)
       throws JMSException
@@ -149,7 +151,7 @@
       // add anything to the tx for this session.
       if (!isConnectionConsumer)
       {
-         sess.preDeliver(m, consumerID);
+         sess.preDeliver(new DeliveryInfo(m, consumerID, channelID));
       }         
    }
    
@@ -181,11 +183,13 @@
    private QueuedExecutor sessionExecutor;
    private boolean listenerRunning;
    private int maxDeliveries;
+   private long channelID;
         
    // Constructors --------------------------------------------------
 
    public MessageCallbackHandler(boolean isCC, int ackMode,                                
                                  SessionDelegate sess, ConsumerDelegate cons, int consumerID,
+                                 long channelID,
                                  int bufferSize, QueuedExecutor sessionExecutor,
                                  int maxDeliveries)
    {
@@ -201,6 +205,7 @@
       this.sessionDelegate = sess;
       this.consumerDelegate = cons;
       this.consumerID = consumerID;
+      this.channelID = channelID;
       this.serverSending = true;
       mainLock = new Object();
       this.sessionExecutor = sessionExecutor;
@@ -281,7 +286,7 @@
          }        
       }   
    }
-      
+   
    public void close() throws JMSException
    {   
       synchronized (mainLock)
@@ -321,16 +326,16 @@
          // have actually been delivered (unlike these) and we may want to acknowledge them
          // later, after this consumer has been closed
 
-         List ackInfos = new ArrayList();
+         List cancels = new ArrayList();
 
          for(Iterator i = buffer.iterator(); i.hasNext();)
          {
             MessageProxy mp = (MessageProxy)i.next();
-            AckInfo ack = new AckInfo(mp, consumerID);
-            ackInfos.add(ack);
+            Cancel ack = new Cancel(mp.getDeliveryId(), mp.getDeliveryCount());
+            cancels.add(ack);
          }
                
-         sessionDelegate.cancelDeliveries(ackInfos);
+         sessionDelegate.cancelDeliveries(cancels);
          
          buffer.clear();
       }                
@@ -445,7 +450,7 @@
                        
                // If message is expired we still call pre and post deliver. This makes sure the
                // message is acknowledged so it gets removed from the queue/subscription.
-               preDeliver(sessionDelegate, consumerID, m, isConnectionConsumer);
+               preDeliver(sessionDelegate, consumerID, channelID, m, isConnectionConsumer);
                
                postDeliver(sessionDelegate, isConnectionConsumer, false);
                
@@ -726,7 +731,7 @@
          {
             try
             {
-               callOnMessage(sessionDelegate, listener, consumerID, false, mp, ackMode, maxDeliveries);
+               callOnMessage(sessionDelegate, listener, consumerID, channelID, false, mp, ackMode, maxDeliveries);
             }
             catch (JMSException e)
             {

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -27,8 +27,9 @@
 import java.util.List;
 import java.util.Map;
 
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
-import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.MessagingXAResource;
@@ -50,6 +51,8 @@
 {
    protected static Logger log = Logger.getLogger(SessionState.class);
 
+   private int sessionId;
+   
    private int acknowledgeMode;
    
    private boolean transacted;
@@ -74,10 +77,13 @@
    
    private Map callbackHandlers;
    
-   public SessionState(ConnectionState parent, SessionDelegate delegate,
-            boolean transacted, int ackMode, boolean xa)
+   public SessionState(ConnectionState parent, ClientSessionDelegate delegate,
+                       boolean transacted, int ackMode, boolean xa)
    {
       super(parent, (DelegateSupport)delegate);
+      
+      this.sessionId = delegate.getID();
+      
       children = new HashSet();
       this.acknowledgeMode = ackMode;
       this.transacted = transacted;
@@ -206,12 +212,18 @@
       return new ArrayList(callbackHandlers.values());
    }
    
+   public int getSessionId()
+   {
+      return sessionId;
+   }
+   
    // When failing over a session, we keep the old session's state but there are certain fields
    // we need to update
    public void copyState(SessionState newState)
    {      
-      //Actually only one field
       this.delegate = newState.delegate;
+      
+      this.sessionId = newState.sessionId;
    }
 }
 

Modified: trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -53,10 +53,4 @@
                                                     String messageSelector,
                                                     ServerSessionPool sessionPool,
                                                     int maxMessages) throws JMSException;
-
-   /**
-    * Reconnects the current connection hierarchy using newConnection's properties.
-    */
-    //void failOver(ConnectionDelegate newConnection);
-
 }

Modified: trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -35,6 +35,7 @@
 import org.jboss.jms.message.ObjectMessageProxy;
 import org.jboss.jms.message.StreamMessageProxy;
 import org.jboss.jms.message.TextMessageProxy;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.server.endpoint.SessionEndpoint;
 
 /**
@@ -65,7 +66,7 @@
    
    TextMessageProxy createTextMessage(String text) throws JMSException;
    
-   void preDeliver(MessageProxy proxy, int consumerID) throws JMSException;
+   void preDeliver(DeliveryInfo deliveryInfo) throws JMSException;
    
    void postDeliver(boolean cancel) throws JMSException;
    
@@ -77,7 +78,7 @@
    
    XAResource getXAResource();
    
-   void addAsfMessage(MessageProxy m, int consumerID, ConsumerDelegate cons, int maxDeliveries);
+   void addAsfMessage(MessageProxy m, int consumerID, long channelID, int maxDeliveries);
    
    boolean getTransacted();
    
@@ -89,7 +90,7 @@
    
    void recover() throws JMSException;
    
-   void redeliver(List ackInfos) throws JMSException;
+   void redeliver(List deliveryInfos) throws JMSException;
    
    ProducerDelegate createProducerDelegate(JBossDestination destination) throws JMSException;
    

Modified: trunk/src/main/org/jboss/jms/message/BytesMessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/BytesMessageProxy.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/BytesMessageProxy.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -38,10 +38,15 @@
 {
    private static final long serialVersionUID = -9121097962625801946L;
 
-   public BytesMessageProxy(JBossBytesMessage message, int deliveryCount)
+   public BytesMessageProxy(long deliveryId, JBossBytesMessage message, int deliveryCount)
    {
-      super(message, deliveryCount);
+      super(deliveryId, message, deliveryCount);
    }
+   
+   public BytesMessageProxy(JBossBytesMessage message)
+   {
+      super(message);
+   }
 
    public long getBodyLength() throws JMSException
    {

Modified: trunk/src/main/org/jboss/jms/message/JBossMessage.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/JBossMessage.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/JBossMessage.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -104,33 +104,33 @@
       reservedIdentifiers.add("ESCAPE");
    }
 
-   public static MessageProxy createThinDelegate(JBossMessage m, int deliveryCount)
+   public static MessageProxy createThinDelegate(long deliveryId, JBossMessage m, int deliveryCount)
    {
       MessageProxy del;
       
       if (m instanceof BytesMessage)
       {
-         del = new BytesMessageProxy((JBossBytesMessage)m, deliveryCount);
+         del = new BytesMessageProxy(deliveryId, (JBossBytesMessage)m, deliveryCount);
       }
       else if (m instanceof MapMessage)
       {
-         del = new MapMessageProxy((JBossMapMessage)m, deliveryCount);
+         del = new MapMessageProxy(deliveryId, (JBossMapMessage)m, deliveryCount);
       }
       else if (m instanceof ObjectMessage)
       {
-         del = new ObjectMessageProxy((JBossObjectMessage)m, deliveryCount);
+         del = new ObjectMessageProxy(deliveryId, (JBossObjectMessage)m, deliveryCount);
       }
       else if (m instanceof StreamMessage)
       {
-         del = new StreamMessageProxy((JBossStreamMessage)m, deliveryCount);
+         del = new StreamMessageProxy(deliveryId, (JBossStreamMessage)m, deliveryCount);
       }
       else if (m instanceof TextMessage)
       {
-         del = new TextMessageProxy((JBossTextMessage)m, deliveryCount);
+         del = new TextMessageProxy(deliveryId, (JBossTextMessage)m, deliveryCount);
       }      
       else
       {
-         del = new MessageProxy(m, deliveryCount);
+         del = new MessageProxy(deliveryId, m, deliveryCount);
       }
 
       return del;

Modified: trunk/src/main/org/jboss/jms/message/MapMessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/MapMessageProxy.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/MapMessageProxy.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -39,11 +39,16 @@
 {
    private static final long serialVersionUID = 6953530870351885569L;
 
-   public MapMessageProxy(JBossMapMessage message, int deliveryCount)
+   public MapMessageProxy(long deliveryId, JBossMapMessage message, int deliveryCount)
    {
-      super(message, deliveryCount);
+      super(deliveryId, message, deliveryCount);
    }
    
+   public MapMessageProxy(JBossMapMessage message)
+   {
+      super(message);
+   }
+   
    public boolean getBoolean(String name) throws JMSException
    {
       return ((MapMessage)message).getBoolean(name);

Modified: trunk/src/main/org/jboss/jms/message/MessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/MessageProxy.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/MessageProxy.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -65,30 +65,46 @@
 
    // Attributes ----------------------------------------------------
 
-   protected JBossMessage message;
-
-   protected transient SessionDelegate delegate;
+   private transient SessionDelegate delegate;
    
-   protected transient boolean cc;
-   protected transient boolean messageCopied;
-   protected transient boolean propertiesCopied;
-   protected transient boolean bodyCopied;
+   private transient boolean cc;
+   
+   private transient boolean messageCopied;
+   
+   private transient boolean propertiesCopied;
+   
+   private transient boolean bodyCopied;
 
-   protected transient int state;
+   private transient int state;
 
-   protected transient boolean propertiesReadOnly;
+   private transient boolean propertiesReadOnly;   
+
+   private int deliveryCount;
+   
+   private long deliveryId;
+   
    protected transient boolean bodyReadOnly;
+   
+   protected JBossMessage message;
 
-   protected int deliveryCount;
 
    // Constructors --------------------------------------------------
 
    public MessageProxy()
    {
    }
+   
+   public MessageProxy(JBossMessage message)
+   {
+      this.deliveryId = -1;
+      this.message = message;
+      this.state = STATE_NEW;
+      this.deliveryCount = 0;
+   }
 
-   public MessageProxy(JBossMessage message, int deliveryCount)
+   public MessageProxy(long deliveryId, JBossMessage message, int deliveryCount)
    {
+      this.deliveryId = deliveryId;
       this.message = message;
       this.state = STATE_NEW;
       this.deliveryCount = deliveryCount;
@@ -433,6 +449,11 @@
    {
       this.deliveryCount++;            
    }
+   
+   public long getDeliveryId()
+   {
+      return deliveryId;
+   }
 
    public String toString()
    {

Modified: trunk/src/main/org/jboss/jms/message/ObjectMessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/ObjectMessageProxy.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/ObjectMessageProxy.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -39,10 +39,15 @@
 {
    private static final long serialVersionUID = 8797295997477962825L;
 
-   public ObjectMessageProxy(JBossObjectMessage message, int deliveryCount)
+   public ObjectMessageProxy(long deliveryId, JBossObjectMessage message, int deliveryCount)
    {
-      super(message, deliveryCount);
+      super(deliveryId, message, deliveryCount);
    }
+   
+   public ObjectMessageProxy(JBossObjectMessage message)
+   {
+      super(message);
+   }
 
    public void setObject(Serializable object) throws JMSException
    {

Modified: trunk/src/main/org/jboss/jms/message/StreamMessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/StreamMessageProxy.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/StreamMessageProxy.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -38,10 +38,15 @@
 {
    private static final long serialVersionUID = 856367553964704474L;
 
-   public StreamMessageProxy(JBossStreamMessage message, int deliveryCount)
+   public StreamMessageProxy(long deliveryId, JBossStreamMessage message, int deliveryCount)
    {
-      super(message, deliveryCount);
+      super(deliveryId, message, deliveryCount);
    }
+   
+   public StreamMessageProxy(JBossStreamMessage message)
+   {
+      super(message);
+   }
 
    public boolean readBoolean() throws JMSException
    {

Modified: trunk/src/main/org/jboss/jms/message/TextMessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/TextMessageProxy.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/message/TextMessageProxy.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -34,14 +34,18 @@
  */
 public class TextMessageProxy extends MessageProxy implements TextMessage
 {
-
    private static final long serialVersionUID = -3530143417050205123L;
 
-   public TextMessageProxy(JBossTextMessage message, int deliveryCount)
+   public TextMessageProxy(long deliveryId, JBossTextMessage message, int deliveryCount)
    {
-      super(message, deliveryCount);
+      super(deliveryId, message, deliveryCount);
    }
    
+   public TextMessageProxy(JBossTextMessage message)
+   {
+      super(message);
+   }
+   
    public void setText(String string) throws JMSException
    {
       if (bodyReadOnly)

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -37,10 +37,9 @@
 import org.jboss.jms.server.connectionfactory.ConnectionFactoryJNDIMapper;
 import org.jboss.jms.server.connectionmanager.SimpleConnectionManager;
 import org.jboss.jms.server.connectormanager.SimpleConnectorManager;
-import org.jboss.jms.server.endpoint.ServerConsumerEndpoint;
 import org.jboss.jms.server.plugin.contract.JMSUserManager;
-import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
+import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.security.SecurityMetadataStore;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
@@ -54,20 +53,18 @@
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.contract.ReplicationListener;
 import org.jboss.messaging.core.plugin.contract.Replicator;
+import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 import org.jboss.messaging.core.plugin.postoffice.cluster.FailoverStatus;
-import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.messaging.util.Util;
 import org.jboss.mx.loading.UnifiedClassLoader3;
-import org.jboss.remoting.marshal.MarshalFactory;
 import org.jboss.remoting.ServerInvocationHandler;
+import org.jboss.remoting.marshal.MarshalFactory;
 import org.jboss.system.ServiceCreator;
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
 
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
-
 /**
  * A JMS server peer.
  *
@@ -146,14 +143,6 @@
 
    private JMSServerInvocationHandler handler;
 
-   // We keep a map of consumers to prevent us to recurse through the attached session in order to
-   // find the ServerConsumerDelegate so we can acknowledge the message. Originally, this map was
-   // maintained per-connection, but with the http://jira.jboss.org/jira/browse/JBMESSAGING-211 bug
-   // we shared it among connections, so a transaction submitted on the "wrong" connection can
-   // still succeed. For more details, see the JIRA issue.
-
-   private Map consumers;
-
    // Constructors --------------------------------------------------
 
    public ServerPeer(int serverPeerID,
@@ -167,8 +156,6 @@
       // Some wired components need to be started here
       securityStore = new SecurityMetadataStore();
 
-      consumers = new ConcurrentReaderHashMap();
-
       version = Version.instance();
       
       failoverStatusLock = new Object();
@@ -709,23 +696,6 @@
       return objectIDSequence++;
    }
 
-   public ServerConsumerEndpoint putConsumerEndpoint(int consumerID, ServerConsumerEndpoint c)
-   {
-      log.debug(this + " caching consumer " + consumerID);
-      return (ServerConsumerEndpoint)consumers.put(new Integer(consumerID), c);
-   }
-
-   public ServerConsumerEndpoint getConsumerEndpoint(int consumerID)
-   {
-      return (ServerConsumerEndpoint)consumers.get(new Integer(consumerID));
-   }
-
-   public ServerConsumerEndpoint removeConsumerEndpoint(Integer consumerID)
-   {
-      log.debug(this + " removing consumer " + consumerID + " from the cache");
-      return (ServerConsumerEndpoint)consumers.remove(consumerID);
-   }
-
    public QueuedExecutorPool getQueuedExecutorPool()
    {
       return queuedExecutorPool;

Added: trunk/src/main/org/jboss/jms/server/endpoint/Ack.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/Ack.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/Ack.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -0,0 +1,36 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+/**
+ * A Ack
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public interface Ack
+{
+   long getDeliveryId();
+}

Added: trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -0,0 +1,105 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+
+import org.jboss.messaging.util.Streamable;
+
+/**
+ * 
+ * A Cancel.
+ * 
+ * Used to send a cancel (NACK) to the server
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class Cancel implements Streamable
+{
+   // Constants -----------------------------------------------------
+   
+   // Attributes ----------------------------------------------------
+   
+   private long deliveryId;
+   
+   private int deliveryCount;      
+
+   // Static --------------------------------------------------------
+   
+   // Constructors --------------------------------------------------
+   
+   public Cancel()
+   {      
+   }
+   
+   public Cancel(long deliveryId, int deliveryCount)
+   {      
+      this.deliveryId = deliveryId;
+      
+      this.deliveryCount = deliveryCount;
+   }
+
+   // Public --------------------------------------------------------
+   
+   public long getDeliveryId()
+   {
+      return deliveryId;
+   }
+   
+   public int getDeliveryCount()
+   {
+      return deliveryCount;
+   }
+
+   // Streamable implementation -------------------------------------
+   
+   public void read(DataInputStream in) throws Exception
+   {
+      deliveryId = in.readLong();
+      
+      deliveryCount = in.readInt();
+   }
+
+   public void write(DataOutputStream out) throws Exception
+   {
+      out.writeLong(deliveryId);
+      
+      out.writeInt(deliveryCount);
+   }
+
+   // Class YYY overrides -------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Package Private -----------------------------------------------
+
+   // Private -------------------------------------------------------
+   
+   // Inner Classes -------------------------------------------------
+   
+}
+

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -37,6 +37,9 @@
  * A ClientDelivery
  * Encapsulates a delivery of some messages to a client consumer
  * 
+ * There is no need to specify the server id since the client side CallbackManager is
+ * unique to the remoting connection
+ * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision$</tt>
  *
@@ -53,10 +56,6 @@
    
    private List msgs;
          
-   //We need to specify the server id too since different servers might have the
-   //same consumer id
-   private int serverId;
-   
    private int consumerId;
     
    // Constructors --------------------------------------------------
@@ -65,12 +64,10 @@
    {      
    }
 
-   public ClientDelivery(List msgs, int serverId, int consumerId)
+   public ClientDelivery(List msgs, int consumerId)
    {
       this.msgs = msgs;
       
-      this.serverId = serverId;
-      
       this.consumerId = consumerId;
    }
   
@@ -79,8 +76,6 @@
    
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeInt(serverId);
-      
       out.writeInt(consumerId);
       
       out.writeInt(msgs.size());
@@ -94,6 +89,8 @@
          out.writeByte(mp.getMessage().getType());
 
          out.writeInt(mp.getDeliveryCount());
+         
+         out.writeLong(mp.getDeliveryId());
 
          mp.getMessage().write(out);
       }      
@@ -101,8 +98,6 @@
 
    public void read(DataInputStream in) throws Exception
    {
-      serverId = in.readInt();
-      
       consumerId = in.readInt();
       
       int numMessages = in.readInt();
@@ -115,11 +110,13 @@
          
          int deliveryCount = in.readInt();
          
+         long deliveryId = in.readLong();
+         
          JBossMessage m = (JBossMessage)MessageFactory.createMessage(type);
 
          m.read(in);
 
-         MessageProxy md = JBossMessage.createThinDelegate(m, deliveryCount);
+         MessageProxy md = JBossMessage.createThinDelegate(deliveryId, m, deliveryCount);
          
          msgs.add(md);
       }      
@@ -132,11 +129,6 @@
       return msgs;
    }
    
-   public int getServerId()
-   {
-      return serverId;
-   }
-   
    public int getConsumerId()
    {
       return consumerId;

Added: trunk/src/main/org/jboss/jms/server/endpoint/DefaultAck.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DefaultAck.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DefaultAck.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -0,0 +1,46 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+/**
+ * A DefaultAck
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class DefaultAck implements Ack
+{
+   private long deliveryId;
+   
+   public DefaultAck(long deliveryId)
+   {
+      this.deliveryId = deliveryId;
+   }
+   
+   public long getDeliveryId()
+   {
+      return deliveryId;
+   }
+}

Added: trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -0,0 +1,98 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+import org.jboss.jms.message.MessageProxy;
+
+/**
+ * Struct like class for holding information regarding a delivery 
+ * on the client side - this is never passed to the server
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com>Tim Fox </a>
+ * @author <a href="mailto:ovidiu at jboss.com>Ovidiu Feodorov</a>
+ *
+ * $Id: AckInfo.java 1770 2006-12-12 10:49:42Z timfox $
+ */
+public class DeliveryInfo implements Ack
+{
+   // Constants -----------------------------------------------------
+   
+   // Attributes ----------------------------------------------------
+   
+   //This is needed on failover when recreating delivery list on the server session
+   //we need to know the channel id so we can recreate the deliveries
+   private long channelID;
+   
+   //This is needed when doing local redelivery of messages, since we need to know which
+   //consumer gets the message
+   private int consumerId;      
+
+   private MessageProxy msg;
+   
+   // Static --------------------------------------------------------
+   
+   // Constructors --------------------------------------------------
+   
+
+   public DeliveryInfo(MessageProxy msg, int consumerId, long channelID)
+   {      
+      this.msg = msg;
+      
+      this.consumerId = consumerId;
+      
+      this.channelID = channelID;
+   }
+
+   // Public --------------------------------------------------------
+   
+   public long getChannelId()
+   {
+      return channelID;
+   }
+   
+   public int getConsumerId()
+   {
+      return consumerId;
+   }
+
+   public MessageProxy getMessageProxy()
+   {
+      return msg;
+   }
+   
+
+   // Ack Implementation  -------------------------------------------
+   
+   public long getDeliveryId()
+   {
+      return msg.getDeliveryId();
+   }
+
+   // Protected -----------------------------------------------------
+
+   // Package Private -----------------------------------------------
+
+   // Private -------------------------------------------------------
+   
+   // Inner Classes -------------------------------------------------
+   
+}

Added: trunk/src/main/org/jboss/jms/server/endpoint/DeliveryRecovery.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DeliveryRecovery.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DeliveryRecovery.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -0,0 +1,94 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+
+import org.jboss.messaging.util.Streamable;
+
+/**
+ * A DeliveryRecovery
+ * 
+ * Used for sending information about to recover a delivery to the server
+ * on failover
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class DeliveryRecovery implements Streamable
+{   
+   private long deliveryId;
+   
+   private long messageId;
+   
+   private long channelId;
+   
+   public DeliveryRecovery()
+   {      
+   }
+   
+   public DeliveryRecovery(long deliveryId, long messageId, long channelId)
+   {
+      this.deliveryId = deliveryId;
+      
+      this.messageId = messageId;
+      
+      this.channelId = channelId;
+   }
+   
+   public long getDeliveryId()
+   {
+      return deliveryId;
+   }
+   
+   public long getMessageId()
+   {
+      return messageId;
+   }
+   
+   public long getChannelId()
+   {
+      return channelId;
+   }
+
+   public void read(DataInputStream in) throws Exception
+   {
+      deliveryId = in.readLong();
+      
+      messageId = in.readLong();
+      
+      channelId = in.readLong();
+   }
+
+   public void write(DataOutputStream out) throws Exception
+   {
+      out.writeLong(deliveryId);
+      
+      out.writeLong(messageId);
+      
+      out.writeLong(channelId);
+   }
+}

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerBrowserEndpoint.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -30,6 +30,7 @@
 
 import org.jboss.jms.selector.Selector;
 import org.jboss.jms.server.remoting.JMSDispatcher;
+import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Filter;
@@ -65,8 +66,8 @@
 
    // Constructors --------------------------------------------------
 
-   protected ServerBrowserEndpoint(ServerSessionEndpoint session, int id,
-                                   Channel destination, String messageSelector)
+   ServerBrowserEndpoint(ServerSessionEndpoint session, int id,
+                         Channel destination, String messageSelector)
       throws JMSException
    {     
       this.session = session;
@@ -87,24 +88,38 @@
 
    public boolean hasNextMessage() throws JMSException
    {
-      if (closed)
+      try
       {
-         throw new IllegalStateException("Browser is closed");
+         if (closed)
+         {
+            throw new IllegalStateException("Browser is closed");
+         }
+         return iterator.hasNext();
+      }   
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " hasNextMessage");
       }
-      return iterator.hasNext();
    }
    
    public Message nextMessage() throws JMSException
    {
-      if (closed)
+      try
       {
-         throw new IllegalStateException("Browser is closed");
+         if (closed)
+         {
+            throw new IllegalStateException("Browser is closed");
+         }
+         Routable r = (Routable)iterator.next();
+   
+         if (trace) { log.trace("returning the message corresponding to " + r); }
+         
+         return (Message)r.getMessage();
+      }   
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " nextMessage");
       }
-      Routable r = (Routable)iterator.next();
-
-      if (trace) { log.trace("returning the message corresponding to " + r); }
-      
-      return (Message)r.getMessage();
    }
    
    
@@ -112,52 +127,60 @@
 	//why not just pass back the arraylist??
    public Message[] nextMessageBlock(int maxMessages) throws JMSException
    {
-      if (closed)
+      try
       {
-         throw new IllegalStateException("Browser is closed");
-      }
-      
-      if (maxMessages < 2)
+         if (closed)
+         {
+            throw new IllegalStateException("Browser is closed");
+         }
+         
+         if (maxMessages < 2)
+         {
+            throw new IllegalArgumentException("maxMessages must be >=2 otherwise use nextMessage");
+         }
+         
+         ArrayList messages = new ArrayList(maxMessages);
+         int i = 0;
+         while (i < maxMessages)
+         {
+            if (iterator.hasNext())
+            {
+               Message m = (Message)((Routable)iterator.next()).getMessage();
+               messages.add(m);
+               i++;
+            }
+            else break;
+         }		
+   		return (Message[])messages.toArray(new Message[messages.size()]);	
+      }   
+      catch (Throwable t)
       {
-         throw new IllegalArgumentException("maxMessages must be >=2 otherwise use nextMessage");
+         throw ExceptionUtil.handleJMSInvocation(t, this + " nextMessageBlock");
       }
-      
-      ArrayList messages = new ArrayList(maxMessages);
-      int i = 0;
-      while (i < maxMessages)
-      {
-         if (iterator.hasNext())
-         {
-            Message m = (Message)((Routable)iterator.next()).getMessage();
-            messages.add(m);
-            i++;
-         }
-         else break;
-      }		
-		return (Message[])messages.toArray(new Message[messages.size()]);		        
    }
    
-   
    public void close() throws JMSException
    {
-      if (closed)
+      try
       {
-         throw new IllegalStateException("Browser is already closed");
+         localClose();
+         
+         session.removeBrowser(id);
+      }   
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " close");
       }
-      iterator = null;
-      session.removeBrowserDelegate(id);
-      JMSDispatcher.instance.unregisterTarget(new Integer(id));
-      closed = true;
    }
-   
+         
    public void closing() throws JMSException
    {
       // Do nothing
    }
-
-   public boolean isClosed()
+   
+   public boolean isClosed() throws JMSException
    {
-      return closed;
+      throw new IllegalStateException("isClosed should never be handled on the server side");
    }
 
    // Public --------------------------------------------------------
@@ -168,8 +191,22 @@
    }
 
    // Package protected ---------------------------------------------
+   
+   void localClose() throws JMSException
+   {
+      if (closed)
+      {
+         throw new IllegalStateException("Browser is already closed");
+      }
+      
+      iterator = null;
+      
+      JMSDispatcher.instance.unregisterTarget(new Integer(id));
+      
+      closed = true;
+   }
 
-   // Protected -----------------------------------------------------
+   // Protected -----------------------------------------------------      
 
    // Private -------------------------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -21,6 +21,7 @@
   */
 package org.jboss.jms.server.endpoint;
 
+import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
@@ -44,9 +45,9 @@
 import org.jboss.jms.server.endpoint.advised.SessionAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.server.remoting.JMSWireFormat;
-import org.jboss.jms.tx.AckInfo;
 import org.jboss.jms.tx.TransactionRequest;
-import org.jboss.jms.tx.TxState;
+import org.jboss.jms.tx.ClientTransaction;
+import org.jboss.jms.tx.ClientTransaction.SessionTxState;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.ToString;
 import org.jboss.logging.Logger;
@@ -55,13 +56,9 @@
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
-import org.jboss.messaging.util.ConcurrentReaderHashSet;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
-import org.jboss.util.id.GUID;
 
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
-
 /**
  * Concrete implementation of ConnectionEndpoint.
  * 
@@ -83,11 +80,11 @@
 
    private boolean trace = log.isTraceEnabled();
    
-   private boolean closed;
+   private volatile boolean closed;
    
    private volatile boolean started;
 
-   private int connectionID;
+   private int id;
    
    private String remotingClientSessionId;
    
@@ -124,11 +121,11 @@
    
    private int prefetchSize;
    
-   protected int defaultTempQueueFullSize;
+   private int defaultTempQueueFullSize;
    
-   protected int defaultTempQueuePageSize;
+   private int defaultTempQueuePageSize;
    
-   protected int defaultTempQueueDownCacheSize;
+   private int defaultTempQueueDownCacheSize;
 
    // Constructors --------------------------------------------------
    
@@ -148,7 +145,7 @@
  
       started = false;
 
-      this.connectionID = serverPeer.getNextObjectID();
+      this.id = serverPeer.getNextObjectID();
       this.clientID = clientID;
       this.prefetchSize = prefetchSize;
       
@@ -156,8 +153,8 @@
       this.defaultTempQueuePageSize = defaultTempQueuePageSize;
       this.defaultTempQueueDownCacheSize = defaultTempQueueDownCacheSize;
 
-      sessions = new ConcurrentReaderHashMap();
-      temporaryDestinations = new ConcurrentReaderHashSet();
+      sessions = new HashMap();
+      temporaryDestinations = new HashSet();
       
       this.username = username;
       this.password = password;
@@ -184,8 +181,14 @@
          // create the corresponding server-side session endpoint and register it with this
          // connection endpoint instance
          ServerSessionEndpoint ep = new ServerSessionEndpoint(sessionID, this);
-         putSessionDelegate(sessionID, ep);
+         
+         synchronized (sessions)
+         {
+            sessions.put(new Integer(sessionID), ep);
+         }
+         
          SessionAdvised sessionAdvised = new SessionAdvised(ep);
+         
          JMSDispatcher.instance.registerTarget(new Integer(sessionID), sessionAdvised);
 
          ClientSessionDelegate d = new ClientSessionDelegate(sessionID);
@@ -263,8 +266,10 @@
          {
             throw new IllegalStateException("Connection is closed");
          }
+         
          setStarted(false);
-         log.debug("Connection " + connectionID + " stopped");
+         
+         log.debug("Connection " + id + " stopped");
       }
       catch (Throwable t)
       {
@@ -284,43 +289,43 @@
             return;
          }
    
-         // We clone to avoid concurrent modification exceptions
-         for(Iterator i = new HashSet(sessions.values()).iterator(); i.hasNext(); )
+         synchronized (sessions)
          {
-            ServerSessionEndpoint sess = (ServerSessionEndpoint)i.next();
-   
-            // clear all consumers associated with this session from the serverPeer's cache
-            for(Iterator j = sess.getConsumerEndpointIDs().iterator(); j.hasNext(); )
+            for(Iterator i = sessions.values().iterator(); i.hasNext(); )
             {
-               Integer consumerID = (Integer)j.next();
-               serverPeer.removeConsumerEndpoint(consumerID);
+               ServerSessionEndpoint sess = (ServerSessionEndpoint)i.next();
+      
+               sess.localClose();
             }
-   
-            // ... and also close the session
-            sess.close();
+            
+            sessions.clear();
          }
          
-         for(Iterator i = temporaryDestinations.iterator(); i.hasNext(); )
+         synchronized (temporaryDestinations)
          {
-            JBossDestination dest = (JBossDestination)i.next();
-
-            if (dest.isQueue())
-            {     
-               postOffice.unbindQueue(dest.getName());               
-            }
-            else
+            for(Iterator i = temporaryDestinations.iterator(); i.hasNext(); )
             {
-               //No need to unbind - this will already have happened, and all removeAllReferences
-               //will have already been called when the subscriptions were closed
-               //which always happens before the connection closed (depth first close)              
+               JBossDestination dest = (JBossDestination)i.next();
+   
+               if (dest.isQueue())
+               {     
+                  postOffice.unbindQueue(dest.getName());               
+               }
+               else
+               {
+                  //No need to unbind - this will already have happened, and all removeAllReferences
+                  //will have already been called when the subscriptions were closed
+                  //which always happens before the connection closed (depth first close)              
+               }
             }
+            
+            temporaryDestinations.clear();
          }
-         
-         temporaryDestinations.clear();
    
          cm.unregisterConnection(jmsClientVMId, remotingClientSessionId);
    
-         JMSDispatcher.instance.unregisterTarget(new Integer(connectionID));
+         JMSDispatcher.instance.unregisterTarget(new Integer(id));
+         
          closed = true;
       }
       catch (Throwable t)
@@ -334,11 +339,6 @@
       log.trace(this + " closing (noop)");    
    }
 
-   public boolean isClosed()
-   {
-      return closed;
-   }
-
    public void sendTransaction(TransactionRequest request) throws JMSException
    {    
       try
@@ -407,6 +407,11 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " getPreparedTransactions");
       }
    }
+   
+   public boolean isClosed() throws JMSException
+   {
+      throw new IllegalStateException("isClosed should never be handled on the server side");
+   }
   
    // Public --------------------------------------------------------
    
@@ -468,132 +473,108 @@
       this.usingVersion = version;
    }
    
-   public byte getUsingVersion()
+   
+           
+   public String toString()
    {
+      return "ConnectionEndpoint[" + id + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   byte getUsingVersion()
+   {
       return usingVersion;
    }
    
-   public int getPrefetchSize()
+   int getPrefetchSize()
    {
       return prefetchSize;
    }
    
-   public int getDefaultTempQueueFullSize()
+   int getDefaultTempQueueFullSize()
    {
       return defaultTempQueueFullSize;
    }
    
-   public int getDefaultTempQueuePageSize()
+   int getDefaultTempQueuePageSize()
    {
       return defaultTempQueuePageSize;
    }
      
-   public int getDefaultTempQueueDownCacheSize()
+   int getDefaultTempQueueDownCacheSize()
    {
       return defaultTempQueueDownCacheSize;
    }
-           
-   public String toString()
-   {
-      return "ConnectionEndpoint[" + connectionID + "]";
-   }
-
-   // Package protected ---------------------------------------------
-
    
-   // Protected -----------------------------------------------------
-   
-   protected ServerInvokerCallbackHandler getCallbackHandler()
+   ServerInvokerCallbackHandler getCallbackHandler()
    {
       return callbackHandler;
    }   
    
-   protected int getConnectionID()
+   int getConnectionID()
    {
-      return connectionID;
+      return id;
    }
    
-   protected boolean isStarted()
+   boolean isStarted()
    {
       return started;    
    }
    
-   /**
-    * Generates a sessionID that is unique per this ConnectionDelegate instance
-    */
-   protected String generateSessionID()
+   void removeSession(int sessionId) throws Exception
    {
-      return new GUID().toString();
+      synchronized (sessions)
+      {
+         if (sessions.remove(new Integer(sessionId)) == null)
+         {
+            throw new IllegalStateException("Cannot find session with id " + sessionId + " to remove");
+         }
+      }
    }
-      
-   protected ServerSessionEndpoint putSessionDelegate(int sessionID, ServerSessionEndpoint d)
-   {
-      return (ServerSessionEndpoint)sessions.put(new Integer(sessionID), d);
-   }
    
-   protected ServerSessionEndpoint getSessionDelegate(int sessionID)
+   void addTemporaryDestination(Destination dest)
    {
-      return (ServerSessionEndpoint)sessions.get(new Integer(sessionID));
+      synchronized (temporaryDestinations)
+      {
+         temporaryDestinations.add(dest);
+      }
    }
    
-   protected ServerSessionEndpoint removeSessionDelegate(int sessionID)
+   void removeTemporaryDestination(Destination dest)
    {
-      return (ServerSessionEndpoint)sessions.remove(new Integer(sessionID));
+      synchronized (temporaryDestinations)
+      {
+         temporaryDestinations.remove(dest);
+      }
    }
    
-   protected ServerConsumerEndpoint putConsumerEndpoint(int consumerID, ServerConsumerEndpoint c)
+   boolean hasTemporaryDestination(Destination dest)
    {
-      return serverPeer.putConsumerEndpoint(consumerID, c);
+      synchronized (temporaryDestinations)
+      {
+         return temporaryDestinations.contains(dest);
+      }
    }
    
-   protected ServerConsumerEndpoint getConsumerEndpoint(int consumerID)
+   ServerPeer getServerPeer()
    {
-      return serverPeer.getConsumerEndpoint(consumerID);
-   }
-   
-   protected ServerConsumerEndpoint removeConsumerEndpoint(Integer consumerID)
-   {
-      return serverPeer.removeConsumerEndpoint(consumerID);
-   }
-   
-   protected void addTemporaryDestination(Destination dest)
-   {
-      temporaryDestinations.add(dest);
-   }
-   
-   protected void removeTemporaryDestination(Destination dest)
-   {
-      temporaryDestinations.remove(dest);
-   }
-   
-   protected boolean hasTemporaryDestination(Destination dest)
-   {
-      return temporaryDestinations.contains(dest);
-   }
-   
-   protected ServerPeer getServerPeer()
-   {
       return serverPeer;
    }
    
-   protected String getRemotingClientSessionId()
+   String getRemotingClientSessionId()
    {
       return remotingClientSessionId;
    }
    
-   protected String getJmsClientVMId()
+   void sendMessage(JBossMessage msg, Transaction tx) throws Exception
    {
-      return jmsClientVMId;
-   }
-
-   protected void sendMessage(JBossMessage msg, Transaction tx) throws Exception
-   {
       JBossDestination dest = (JBossDestination)msg.getJMSDestination();
       
       // This allows the no-local consumers to filter out the messages that come from the same
       // connection
       // TODO Do we want to set this for ALL messages. Optimisation is possible here.
-      msg.setConnectionID(connectionID);
+      msg.setConnectionID(id);
       
       // We must reference the message *before* we send it the destination to be handled. This is
       // so we can guarantee that the message doesn't disappear from the store before the
@@ -628,7 +609,9 @@
          
       if (trace) { log.trace("sent " + msg); }
    }
-
+   
+   // Protected -----------------------------------------------------
+     
    // Private -------------------------------------------------------
    
    private void setStarted(boolean s) throws Throwable
@@ -638,46 +621,41 @@
          for (Iterator i = sessions.values().iterator(); i.hasNext(); )
          {
             ServerSessionEndpoint sd = (ServerSessionEndpoint)i.next();
+            
             sd.setStarted(s);
          }
          started = s;
       }
    }   
     
-   private void processTransaction(TxState txState, Transaction tx) throws Throwable
+   private void processTransaction(ClientTransaction txState, Transaction tx) throws Throwable
    {
-      if (trace) { log.trace("processing transaction, there are " + txState.getMessages().size() + " messages and " + txState.getAcks().size() + " acks "); }
+      if (trace) { log.trace("processing transaction"); }
       
-      for(Iterator i = txState.getMessages().iterator(); i.hasNext(); )
-      {
-         JBossMessage m = (JBossMessage)i.next();
-         
-         sendMessage(m, tx);
-      }
-      
-      if (trace) { log.trace("done the sends"); }
-      
-      // Then ack the acks
-      
-      List acks = txState.getAcks();
-      
-      // We create the transactional callbacks in reverse order so if the transaction is
-      // subsequently cancelled the refs are put back in the correct order on the queue/subscription
-      for (int i = acks.size() - 1; i >= 0; i--)
-      {      
-         AckInfo ack = (AckInfo)acks.get(i);
-         
-         ServerConsumerEndpoint consumer = getConsumerEndpoint(ack.getConsumerID());
-         if (consumer == null)
+      synchronized (sessions)
+      {         
+         for (Iterator i = txState.getSessionStates().iterator(); i.hasNext(); )
          {
-            throw new IllegalStateException("Cannot find consumer " + ack.getConsumerID());
+            SessionTxState sessionState = (SessionTxState)i.next();
+            
+            List msgs = sessionState.getMsgs();
+            
+            for (Iterator i2 = msgs.iterator(); i2.hasNext(); )
+            {
+               JBossMessage msg = (JBossMessage)i2.next();
+                     
+               sendMessage(msg, tx);
+            }
+                     
+            List acks = sessionState.getAcks();
+            
+            ServerSessionEndpoint session = (ServerSessionEndpoint)sessions.get(new Integer(sessionState.getSessionId()));
+            
+            session.acknowledgeTransactionally(acks, tx);      
          }
-         consumer.acknowledgeTransactionally(ack.getMessageID(), tx);
-         
-         if (trace) { log.trace("acked " + ack.getMessageID()); }
       }
       
-      if (trace) { log.trace("done the acks"); }
+      if (trace) { log.trace("Processed transaction"); }
    }   
 
    // Inner classes -------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -23,10 +23,7 @@
 
 
 import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.LinkedHashMap;
 import java.util.List;
-import java.util.Map;
 
 import javax.jms.IllegalStateException;
 import javax.jms.InvalidSelectorException;
@@ -46,15 +43,12 @@
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.MessageReference;
-import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.Routable;
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.Transaction;
-import org.jboss.messaging.core.tx.TransactionException;
-import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.util.Future;
 import org.jboss.remoting.callback.Callback;
 
@@ -113,28 +107,22 @@
    // No need to be volatile - is protected by lock
    private boolean closed;
 
-   // No need to be volatile
-   private boolean disconnected;
-
    private Executor executor;
 
    private int prefetchSize;
 
    private Object lock;
 
-   private Map deliveries;
-   
-   private Queue dlq;
-   
    private Object messagesInTransitLock;
+   
    private int messagesInTransitCount; // access only from a region guarded by messagesInTransitLock
    
    // Constructors --------------------------------------------------
 
-   protected ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
-                                    ServerSessionEndpoint sessionEndpoint,
-                                    String selector, boolean noLocal, JBossDestination dest,
-                                    int prefetchSize, Queue dlq)
+   ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
+                         ServerSessionEndpoint sessionEndpoint,
+                         String selector, boolean noLocal, JBossDestination dest,
+                         int prefetchSize)
       throws InvalidSelectorException
    {
       if (trace) { log.trace("constructing consumer endpoint " + id); }
@@ -144,8 +132,7 @@
       this.queueName = queueName;
       this.sessionEndpoint = sessionEndpoint;
       this.prefetchSize = prefetchSize;
-      this.dlq = dlq;
-
+      
       // We always created with clientConsumerFull = true. This prevents the SCD sending messages to
       // the client before the client has fully finished creating the MessageCallbackHandler.
       this.clientConsumerFull = true;
@@ -170,6 +157,7 @@
       // using the same queuedexecutor concurrently if there are a lot of active consumers.
 
       this.noLocal = noLocal;
+      
       this.destination = dest;
       
       this.toDeliver = new ArrayList();
@@ -182,24 +170,14 @@
          this.messageSelector = new Selector(selector);
          if (trace) log.trace("created selector");
       }
-
-      //TODO - 
-      //We really need to get rid of this delivery list - it's only purpose in life is to solve
-      //the race condition where acks or cancels can come in before handle has returned - and
-      //that can be solved in a simpler way anyway.
-      //It adds extra complexity both in all the extra code necessary to maintain it, the extra memory
-      //needed to maintain it, the extra complexity in synchronization on this class to protect access to it
-      //and when we do clustering we will have to replicate it too!!
-      //Let's GET RID OF IT!!!!!!!!!!!
-      this.deliveries = new LinkedHashMap();
-            
+       
       this.started = this.sessionEndpoint.getConnectionEndpoint().isStarted();
 
       // adding the consumer to the queue
       this.messageQueue.add(this);
       
       // prompt delivery
-      messageQueue.deliver(false);
+      promptDelivery();
 
       messagesInTransitLock = new Object();
       messagesInTransitCount = 0;
@@ -234,12 +212,6 @@
          // queue for delivery later.
          if (!started)
          {
-            // this is a common programming error, make this visible in the debug logs. However,
-            // make also possible to cut out the performance overhead for systems that raise the
-            // threshold to INFO or higher.
-
-            //TODO - Why was this debug
-            //log.isDebugEnabled is too slow!! especially on the primary execution path
             if (trace) { log.trace(this + " NOT started yet!"); }
 
             return null;
@@ -262,15 +234,15 @@
          {
             return delivery;
          }
+         
+         long deliveryId = sessionEndpoint.addDelivery(delivery);
 
-         deliveries.put(new Long(ref.getMessageID()), delivery);
-   
          // We don't send the message as-is, instead we create a MessageProxy instance. This allows
          // local fields such as deliveryCount to be handled by the proxy but global data to be
          // fielded by the same underlying Message instance. This allows us to avoid expensive
          // copying of messages
    
-         MessageProxy mp = JBossMessage.createThinDelegate(message, ref.getDeliveryCount());
+         MessageProxy mp = JBossMessage.createThinDelegate(deliveryId, message, ref.getDeliveryCount());
     
          // Add the proxy to the list to deliver
                            
@@ -319,9 +291,7 @@
          {
             int conId = ((JBossMessage)r).getConnectionID();
             
-            if (trace) { log.trace("message connection id: " + conId); }
-
-            if (trace) { log.trace("current connection connection id: " + sessionEndpoint.getConnectionEndpoint().getConnectionID()); }   
+            if (trace) { log.trace("message connection id: " + conId + " current connection connection id: " + sessionEndpoint.getConnectionEndpoint().getConnectionID()); }   
                  
             accept = conId != sessionEndpoint.getConnectionEndpoint().getConnectionID();
                 
@@ -352,56 +322,16 @@
    {      
       try
       {
-         synchronized (lock)
-         { 
-            // On close we only disconnect the consumer from the queue we don't actually remove
-            // it. This is because it may still contain deliveries that may well be acknowledged
-            // after the consumer has closed. This is perfectly valid.
-
-            // TODO - The deliveries should really be stored in the session endpoint, not here
-            // that is their natural place, that would mean we wouldn't have to mess around with
-            // keeping deliveries after this is closed.
-
-            if (trace) { log.trace(this + " grabbed the main lock in close()"); }
-
-            disconnect(); 
-            
-            JMSDispatcher.instance.unregisterTarget(new Integer(id));
-            
-            // If this is a consumer of a non durable subscription then we want to unbind the
-            // subscription and delete all its data.
-
-            if (destination.isTopic())
-            {
-               PostOffice postOffice = 
-                  sessionEndpoint.getConnectionEndpoint().getServerPeer().getPostOfficeInstance();
-               
-               Binding binding = postOffice.getBindingForQueueName(queueName);
-
-               //Note binding can be null since there can many competing subscribers for the subscription  - 
-               //in which case the first will have removed the subscription and subsequently
-               //ones won't find it
-               
-               if (binding != null && !binding.getQueue().isRecoverable())
-               {
-                  postOffice.unbindQueue(queueName);
-               }
-            }
-                        
-            closed = true;
-         }
-      }
+         localClose();
+         
+         sessionEndpoint.removeConsumer(id);
+      }   
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " close");
       }
    }
-
-   public boolean isClosed()
-   {
-      return closed;
-   }
-               
+           
    // ConsumerEndpoint implementation -------------------------------
    
    /*
@@ -475,6 +405,11 @@
          messagesInTransitLock.notifyAll();
       }
    }
+   
+   public boolean isClosed() throws JMSException
+   {
+      throw new IllegalStateException("isClosed should never be handled on the server side");
+   }
 
    // Public --------------------------------------------------------
    
@@ -493,188 +428,43 @@
       return sessionEndpoint;
    }
    
-   public int getId()
-   {
-      return id;
-   }
-    
    // Package protected ---------------------------------------------
    
-   // Protected -----------------------------------------------------   
-   
-   protected void acknowledgeTransactionally(long messageID, Transaction tx) throws Throwable
-   {
-      if (trace) { log.trace("acknowledging transactionally " + messageID); }
-      
-      Delivery d = null;
-                 
-      // The actual removal of the deliveries from the delivery list is deferred until tx commit
+   void localClose() throws Throwable
+   {      
       synchronized (lock)
-      {
-         d = (Delivery)deliveries.get(new Long(messageID));
-      }
-      
-      DeliveryCallback deliveryCallback = (DeliveryCallback)tx.getCallback(this);
-            
-      if (deliveryCallback == null)
-      {
-         deliveryCallback = new DeliveryCallback();
-         tx.addCallback(deliveryCallback, this);
-      }
-      deliveryCallback.addMessageID(messageID);
+      { 
+         if (trace) { log.trace(this + " grabbed the main lock in close() " + this); }
+
+         messageQueue.remove(this); 
          
-      if (d != null)
-      {
-         d.acknowledge(tx);
-      }
-      else
-      {
-         //throw new IllegalStateException("Could not find delivery to acknowledge");
-         //TODO - Reenable this exception
-         log.warn("Coud not find acknowledge... Exception disabled for tests.. please re-enable before merging into trunk");
-      }             
-   }      
-   
-   protected void acknowledge(long messageID) throws Throwable
-   {  
-      // acknowledge a delivery   
-      Delivery d;
-      
-      synchronized (lock)
-      {
-         d = (Delivery)deliveries.remove(new Long(messageID));
-      }
-      
-      if (d != null)
-      {
-         d.acknowledge(null);
-      }
-      else
-      {     
-         throw new IllegalStateException("Cannot find delivery to acknowledge:" + messageID);
-      }      
-   }
-   
-   /**
-    * Actually remove the consumer and clear up any deliveries it may have
-    * This is called by the session on session.close()
-    * We can get rid of this when we store the deliveries on the session
-    *
-    **/
-   protected void remove() throws Throwable
-   {         
-      if (trace) log.trace("attempting to remove receiver " + this + " from destination " + messageQueue);
-      
-      boolean wereDeliveries = false;
-      for(Iterator i = deliveries.values().iterator(); i.hasNext(); )
-      {
+         JMSDispatcher.instance.unregisterTarget(new Integer(id));
+         
+         // If this is a consumer of a non durable subscription then we want to unbind the
+         // subscription and delete all its data.
 
-         Delivery d = (Delivery)i.next();
-
-         d.cancel();
-         wereDeliveries = true;
-      }
-      deliveries.clear();           
-      
-      if (!disconnected)
-      {
-         if (!closed)
+         if (destination.isTopic())
          {
-            close();
-         }
-      }
-      
-      sessionEndpoint.getConnectionEndpoint().
-         getServerPeer().removeConsumerEndpoint(new Integer(id));                  
+            PostOffice postOffice = 
+               sessionEndpoint.getConnectionEndpoint().getServerPeer().getPostOfficeInstance();
             
-      sessionEndpoint.removeConsumerEndpoint(id);
-      
-      if (wereDeliveries)
-      {
-         //If we cancelled any deliveries we need to force a deliver on the queue
-         //This is because there may be other waiting competing consumers who need a chance to get
-         //any of the cancelled messages
-         messageQueue.deliver(false);
-      }
-   }  
-   
-   protected void promptDelivery()
-   {
-      messageQueue.deliver(false);
-   }
-   
-   protected void sendToDLQ(Long messageID, Transaction tx) throws Throwable
-   {
-      Delivery del = (Delivery)deliveries.remove(messageID);
-      
-      if (del != null)
-      { 
-         log.warn(del.getReference() + " has exceed maximum delivery attempts and will be sent to the DLQ");
-         
-         if (dlq != null)
-         {         
-            //reset delivery count to zero
-            del.getReference().setDeliveryCount(0);
-            
-            dlq.handle(null, del.getReference(), tx);
-            
-            del.acknowledge(tx);           
-         }
-         else
-         {
-            log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
-            
-            del.acknowledge(tx);
-         }
-      }
-      else
-      {
-         throw new IllegalStateException("Cannot find delivery to send to DLQ:" + id);
-      }
-      
-   }
+            Binding binding = postOffice.getBindingForQueueName(queueName);
 
-   protected void createDeliveries(List messageIds) throws Throwable
-   {
-      List dels = messageQueue.createDeliveries(messageIds);
+            //Note binding can be null since there can many competing subscribers for the subscription  - 
+            //in which case the first will have removed the subscription and subsequently
+            //ones won't find it
             
-      synchronized (lock)
-      {      
-         Iterator iter = dels.iterator();
-         
-         while (iter.hasNext())
-         {
-            Delivery del = (Delivery)iter.next();
-            
-            deliveries.put(new Long(del.getReference().getMessageID()), del);
+            if (binding != null && !binding.getQueue().isRecoverable())
+            {
+               postOffice.unbindQueue(queueName);
+            }
          }
+                     
+         closed = true;
       }
-      
-      //Prompt delivery
-      messageQueue.deliver(false);
-   }
-
-   protected void cancelDelivery(Long messageID, int deliveryCount) throws Throwable
-   {
-      Delivery del = (Delivery)deliveries.remove(messageID);
-      
-      if (del != null)
-      {                               
-         //Cancel back to the queue
-         
-         //Update the delivery count
+   }        
            
-         del.getReference().setDeliveryCount(deliveryCount);
-              
-         del.cancel();         
-      }
-      else
-      {
-         throw new IllegalStateException("Cannot find delivery to cancel:" + id);
-      }
-   }
-           
-   protected void start()
+   void start()
    {             
       synchronized (lock)
       {
@@ -693,10 +483,10 @@
       }
       
       // Prompt delivery
-      messageQueue.deliver(false);
+      promptDelivery();
    }
    
-   protected void stop() throws Throwable
+   void stop() throws Throwable
    {     
       // We need to:
       // - Stop accepting any new messages in the SCE.
@@ -707,8 +497,7 @@
       // already executing and messages might get deposited after.
       synchronized (lock)
       {
-         // can't start or stop it if it is closed
-         if (closed)
+         if (!started)
          {
             return;
          }
@@ -762,36 +551,35 @@
       { 
          synchronized (lock)
          {
+            //Cancel in reverse order
             for (int i = toDeliver.size() - 1; i >= 0; i--)
             {
                MessageProxy proxy = (MessageProxy)toDeliver.get(i);
-               long id = proxy.getMessage().getMessageID();
-               cancelDelivery(new Long(id), proxy.getMessage().getDeliveryCount());
+
+               sessionEndpoint.cancelDelivery(proxy.getDeliveryId());
             }
          }
                  
          toDeliver.clear();
+         
          bufferFull = false;
       }      
+      
+      //Need to prompt delivery
+      promptDelivery();
    }
+   
+   
+   
+   // Protected -----------------------------------------------------         
       
    // Private -------------------------------------------------------
    
-   /**
-    * Disconnect this consumer from the queue that feeds it. This method does not clear up
-    * deliveries
-    */
-   private void disconnect()
+   private void promptDelivery()
    {
-      boolean removed = messageQueue.remove(this);
-      
-      if (removed)
-      {
-         disconnected = true;
-         if (trace) { log.trace(this + " removed from the queue"); }
-      }
+      messageQueue.deliver(false);
    }
-
+   
    // Inner classes -------------------------------------------------   
    
    /*
@@ -835,12 +623,7 @@
          ServerConnectionEndpoint connection =
             ServerConsumerEndpoint.this.sessionEndpoint.getConnectionEndpoint();
          
-         int serverId = connection.getServerPeer().getServerPeerID();
-
-         // TODO How can we ensure that messages for the same consumer aren't delivered
-         // concurrently to the same consumer on different threads?
-
-         ClientDelivery del = new ClientDelivery(list, serverId, id);
+         ClientDelivery del = new ClientDelivery(list, id);
          MessagingMarshallable mm = new MessagingMarshallable(connection.getUsingVersion(), del);
          Callback callback = new Callback(mm);
 
@@ -902,63 +685,5 @@
       {
          result.setResult(null);
       }
-   }
-   
-   /**
-    * 
-    * The purpose of this class is to remove deliveries from the delivery list on commit
-    * Each transaction has once instance of this per SCE
-    *
-    */
-   private class DeliveryCallback implements TxCallback
-   {
-      List delList = new ArrayList();
-         
-      public void beforePrepare()
-      {         
-         //NOOP
-      }
-      
-      public void beforeCommit(boolean onePhase)
-      {         
-         //NOOP
-      }
-      
-      public void beforeRollback(boolean onePhase)
-      {         
-         //NOOP
-      }
-      
-      public void afterPrepare()
-      {         
-         //NOOP
-      }
-      
-      public synchronized void afterCommit(boolean onePhase) throws TransactionException
-      {
-         // Remove the deliveries from the delivery map.
-         Iterator iter = delList.iterator();
-         while (iter.hasNext())
-         {
-            Long messageID = (Long)iter.next();
-            
-            if (deliveries.remove(messageID) == null)
-            {
-               //throw new TransactionException("Failed to remove delivery " + messageID);
-               log.warn("Couldn't remove delivery " + messageID + "- reenable exception before merging into trunk");
-               //TODO reenable exception
-            }
-         }
-      }
-      
-      public void afterRollback(boolean onePhase) throws TransactionException
-      {                            
-         //NOOP
-      }
-      
-      synchronized void addMessageID(long messageID)
-      {
-         delList.add(new Long(messageID));
-      }
-   }
+   }   
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -24,11 +24,11 @@
 
 import java.util.ArrayList;
 import java.util.Collection;
+import java.util.Collections;
+import java.util.Comparator;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
@@ -56,11 +56,12 @@
 import org.jboss.jms.server.endpoint.advised.BrowserAdvised;
 import org.jboss.jms.server.endpoint.advised.ConsumerAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
-import org.jboss.jms.tx.AckInfo;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.jms.util.MessageQueueNameHelper;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Delivery;
+import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.plugin.IdManager;
@@ -72,10 +73,14 @@
 import org.jboss.messaging.core.plugin.postoffice.cluster.LocalClusteredQueue;
 import org.jboss.messaging.core.plugin.postoffice.cluster.RemoteQueueStub;
 import org.jboss.messaging.core.tx.Transaction;
+import org.jboss.messaging.core.tx.TransactionException;
 import org.jboss.messaging.core.tx.TransactionRepository;
+import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.util.id.GUID;
 
+import EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap;
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+import EDU.oswego.cs.dl.util.concurrent.SynchronizedLong;
 
 /**
  * Concrete implementation of SessionEndpoint.
@@ -99,9 +104,9 @@
 
    private boolean trace = log.isTraceEnabled();
 
-   private int sessionID;
+   private int id;
 
-   private boolean closed;
+   private volatile boolean closed;
 
    private ServerConnectionEndpoint connectionEndpoint;
 
@@ -120,12 +125,18 @@
    private int maxDeliveryAttempts;
    private Queue dlq;
    
+   // Map < deliveryId, Delivery>
+   private Map deliveries;
+   
+   private SynchronizedLong deliveryIdSequence;
+   
+   
    // Constructors --------------------------------------------------
 
-   protected ServerSessionEndpoint(int sessionID, ServerConnectionEndpoint connectionEndpoint)
+   ServerSessionEndpoint(int sessionID, ServerConnectionEndpoint connectionEndpoint)
       throws Exception
    {
-      this.sessionID = sessionID;
+      this.id = sessionID;
 
       this.connectionEndpoint = connectionEndpoint;
 
@@ -146,7 +157,10 @@
       dlq = sp.getDLQ();
       tr = sp.getTxRepository();
       maxDeliveryAttempts = sp.getMaxDeliveryAttempts();
-
+      
+      deliveries = new ConcurrentHashMap();
+      
+      deliveryIdSequence = new SynchronizedLong(0);
    }
    
    // SessionDelegate implementation --------------------------------
@@ -213,7 +227,11 @@
    	   ServerBrowserEndpoint ep =
    	      new ServerBrowserEndpoint(this, browserID, (PagingFilteredQueue)binding.getQueue(), messageSelector);
    	   
-   	   putBrowserDelegate(browserID, ep);
+         //Still need to synchronized since close() can come in on a different thread
+         synchronized (browsers)
+         {
+            browsers.put(new Integer(browserID), ep);
+         }
    	   
          JMSDispatcher.instance.registerTarget(new Integer(browserID), new BrowserAdvised(ep));
    	   
@@ -276,49 +294,27 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " createTopic");
       }
    }
-
+   
    public void close() throws JMSException
    {
       try
       {
-         if (closed)
-         {
-            throw new IllegalStateException("Session is already closed");
-         }
+         localClose();
          
-         if (trace) log.trace(this + " close()");
-               
-         // clone to avoid ConcurrentModificationException
-         HashSet consumerSet = new HashSet(consumers.values());
-         
-         for(Iterator i = consumerSet.iterator(); i.hasNext(); )
-         {
-            ((ServerConsumerEndpoint)i.next()).remove();
-         }           
-         
-         connectionEndpoint.removeSessionDelegate(sessionID);
-         
-         JMSDispatcher.instance.unregisterTarget(new Integer(sessionID));
-         
-         closed = true;
+         connectionEndpoint.removeSession(id);
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " close");
       }
    }
-   
+      
    public void closing() throws JMSException
    {
       // currently does nothing
       if (trace) log.trace(this + " closing (noop)");
    }
-
-   public boolean isClosed()
-   {
-      return closed;
-   }
-   
+ 
    public void send(JBossMessage message) throws JMSException
    {
       try
@@ -331,17 +327,24 @@
       }
    }
    
-   public void acknowledgeBatch(List ackInfos) throws JMSException
+   public void acknowledgeBatch(List acks) throws JMSException
    {      
       try
       {
-         Iterator iter = ackInfos.iterator();
+         Iterator iter = acks.iterator();
          
          while (iter.hasNext())
          {
-            AckInfo ackInfo = (AckInfo)iter.next();
+            Ack ack = (Ack)iter.next();
             
-            acknowledgeInternal(ackInfo);
+            Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
+            
+            if (del == null)
+            {
+               throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
+            }
+            
+            del.acknowledge(null);
          }
       }
       catch (Throwable t)
@@ -350,56 +353,63 @@
       }
    }
    
-   public void acknowledge(AckInfo ackInfo) throws JMSException
+   public void acknowledge(Ack ack) throws JMSException
    {
       try
       {
-         acknowledgeInternal(ackInfo);      
+         Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
+         
+         if (del == null)
+         {
+            throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
+         }
+         
+         del.acknowledge(null);    
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledge");
       }
-   }
+   }     
 
-   public void cancelDeliveries(List ackInfos) throws JMSException
+   public void cancelDeliveries(List cancels) throws JMSException
    {
       try
       {
          // deliveries must be cancelled in reverse order
-          
-         Set consumers = new HashSet();
-         
+           
          List forDLQ = null;
          
-         for (int i = ackInfos.size() - 1; i >= 0; i--)
+         Set channels = new HashSet();
+                           
+         for (int i = cancels.size() - 1; i >= 0; i--)
          {
-            AckInfo ack = (AckInfo)ackInfos.get(i);
+            Cancel cancel = (Cancel)cancels.get(i);
             
-            // We look in the global map since the message might have come from connection consumer
-            ServerConsumerEndpoint consumer =
-               this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
-   
-            if (consumer == null)
+            Delivery del = (Delivery)deliveries.remove(new Long(cancel.getDeliveryId()));
+            
+            if (del == null)
             {
-               throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
+               throw new IllegalStateException("Cannot find delivery to cancel " + cancel.getDeliveryId());
             }
-            
-            if (ack.getDeliveryCount() >= maxDeliveryAttempts)
+                                    
+            if (cancel.getDeliveryCount() >= maxDeliveryAttempts)
             {
                if (forDLQ == null)
                {
                   forDLQ = new ArrayList();
                }
                
-               forDLQ.add(ack);
+               forDLQ.add(del);
             }
             else
-            {            
-               consumer.cancelDelivery(new Long(ack.getMessageID()), ack.getDeliveryCount());
+            {                                                   
+               del.getReference().setDeliveryCount(cancel.getDeliveryCount());
+               
+               del.cancel();
+               
+               channels.add(del.getObserver());
             }
-            
-            consumers.add(consumer);
          }
          
          //Send stuff to DLQ
@@ -414,17 +424,23 @@
             {               
                for (int i = forDLQ.size() - 1; i >= 0; i--)
                {
-                  AckInfo ack = (AckInfo)forDLQ.get(i);
+                  Delivery del = (Delivery)forDLQ.get(i);
                   
-                  ServerConsumerEndpoint consumer =
-                     this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
-         
-                  if (consumer == null)
+                  if (dlq != null)
+                  {         
+                     //reset delivery count to zero
+                     del.getReference().setDeliveryCount(0);
+                     
+                     dlq.handle(null, del.getReference(), tx);
+                     
+                     del.acknowledge(tx);           
+                  }
+                  else
                   {
-                     throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
-                  }
-                  
-                  consumer.sendToDLQ(new Long(ack.getMessageID()), tx);                              
+                     log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
+                     
+                     del.acknowledge(tx);
+                  }                              
                }
                
                tx.commit();
@@ -437,49 +453,49 @@
             }
          }
          
-         // need to prompt delivery for all consumers
+         // need to prompt delivery for all affected channels
          
-         for(Iterator i = consumers.iterator(); i.hasNext(); )
-         {
-            ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)i.next();
-            consumer.promptDelivery();
-         }
+         promptDelivery(channels);
       }
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " cancelDeliveries");
       }
-   }
+   }         
    
-   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   public void recoverDeliveries(List deliveryRecoveryInfos) throws JMSException
    {
+      if (trace) { log.trace(this + "recoverDeliveries(): " + deliveryRecoveryInfos); }
       try
       {
-         //Sort into different list for each consumer
+         if (postOffice.isLocal())
+         {
+            throw new IllegalStateException("Recovering deliveries but post office is not clustered!");
+         }
+         
+         ClusteredPostOffice po = (ClusteredPostOffice)postOffice;
+         
+         long maxDeliveryId = 0;
+                  
+         //Sort into different list for each channel
          Map ackMap = new HashMap();
                   
-         for (int i = ackInfos.size() - 1; i >= 0; i--)
+         for (Iterator iter = deliveryRecoveryInfos.iterator(); iter.hasNext(); )
          {
-            AckInfo ack = (AckInfo)ackInfos.get(i);
+            DeliveryRecovery deliveryInfo = (DeliveryRecovery)iter.next();
+                
+            Long channelId = new Long(deliveryInfo.getChannelId());
             
-            ServerConsumerEndpoint consumer =
-               this.connectionEndpoint.getConsumerEndpoint(ack.getConsumerID());
-   
-            if (consumer == null)
-            {
-               throw new IllegalArgumentException("Cannot find consumer id: " + ack.getConsumerID());
-            }
+            List acks = (List)ackMap.get(channelId);
             
-            LinkedList acks = (LinkedList)ackMap.get(consumer);
-            
             if (acks == null)
             {
-               acks = new LinkedList();
+               acks = new ArrayList();
                
-               ackMap.put(consumer, acks);
+               ackMap.put(channelId, acks);
             }
             
-            acks.addFirst(new Long(ack.getMessageID()));
+            acks.add(deliveryInfo);
          }  
          
          Iterator iter = ackMap.entrySet().iterator();
@@ -488,19 +504,59 @@
          {
             Map.Entry entry = (Map.Entry)iter.next();
             
-            ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)entry.getKey();
+            Long channelId = (Long)entry.getKey();
             
+            //Look up channel
+            Binding binding = po.getBindingforChannelId(channelId.longValue());
+            
+            if (binding == null)
+            {
+               throw new IllegalStateException("Cannot find channel with id: " + channelId);
+            }
+            
             List acks = (List)entry.getValue();
             
-            consumer.createDeliveries(acks);
+            List ids = new ArrayList(acks.size());
+            
+            for (Iterator iter2 = acks.iterator(); iter2.hasNext(); )
+            {
+               DeliveryRecovery info = (DeliveryRecovery)iter2.next();
+               
+               ids.add(new Long(info.getMessageId()));
+            }
+            
+            Queue queue = binding.getQueue();
+            
+            List dels = queue.createDeliveries(ids);
+            
+            Iterator iter2 = dels.iterator();
+            
+            Iterator iter3 = acks.iterator();
+            
+            while (iter2.hasNext())
+            {
+               Delivery del = (Delivery)iter2.next();
+               
+               DeliveryRecovery info = (DeliveryRecovery)iter3.next();
+               
+               long deliveryId = info.getDeliveryId();
+               
+               maxDeliveryId = Math.max(maxDeliveryId, deliveryId);
+               
+               if (trace) { log.trace(this + " Recovered delivery " + deliveryId + ", " + del); }
+               
+               deliveries.put(new Long(deliveryId), del);
+            }
          }
+         
+         this.deliveryIdSequence = new SynchronizedLong(maxDeliveryId + 1);
       }
       catch (Throwable t)
       {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " sendUnackedAckInfos");
+         throw ExceptionUtil.handleJMSInvocation(t, this + " recoverDeliveries");
       }
    }
-
+   
    public void addTemporaryDestination(JBossDestination dest) throws JMSException
    {
       try
@@ -670,6 +726,11 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " unsubscribe");
       }
    }
+   
+   public boolean isClosed() throws JMSException
+   {
+      throw new IllegalStateException("isClosed should never be handled on the server side");
+   }
     
    // Public --------------------------------------------------------
    
@@ -680,57 +741,184 @@
 
    public String toString()
    {
-      return "SessionEndpoint[" + sessionID + "]";
+      return "SessionEndpoint[" + id + "]";
    }
 
    // Package protected ---------------------------------------------
-
-   /**
-    * @return a Set<Integer>
-    */
-   Set getConsumerEndpointIDs()
+   
+   void removeBrowser(int browserId) throws Exception
    {
-      return consumers.keySet();
+      synchronized (browsers)
+      {
+         if (browsers.remove(new Integer(browserId)) == null)
+         {
+            throw new IllegalStateException("Cannot find browser with id " + browserId + " to remove");
+         }
+      }
    }
    
-   // Protected -----------------------------------------------------
-      
-   protected ServerConsumerEndpoint putConsumerEndpoint(int consumerID, ServerConsumerEndpoint d)
+   void removeConsumer(int consumerId) throws Exception
    {
-      if (trace) { log.trace(this + " caching consumer " + consumerID); }
-      return (ServerConsumerEndpoint)consumers.put(new Integer(consumerID), d);
+      synchronized (consumers)
+      {
+         if (consumers.remove(new Integer(consumerId)) == null)
+         {
+            throw new IllegalStateException("Cannot find consumer with id " + consumerId + " to remove");
+         }
+      }
    }
+   
+//   void promptDeliveryOnConsumers()
+//   {
+//      if (trace) { log.trace(this + " promptDeliveryOnConsumers(), there are " + consumers.size() + " consumers"); }
+//      synchronized (consumers)
+//      {         
+//         for (Iterator i = consumers.values().iterator(); i.hasNext(); )
+//         {
+//            ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)i.next();
+//            
+//            consumer.promptDelivery();
+//         }
+//      }
+//   }
+   
+   void localClose() throws Throwable
+   {
+      if (closed)
+      {
+         throw new IllegalStateException("Session is already closed");
+      }
+      
+      if (trace) log.trace(this + " close()");
+            
+      synchronized (consumers)
+      {            
+         for( Iterator i = consumers.values().iterator(); i.hasNext(); )
+         {
+            ((ServerConsumerEndpoint)i.next()).localClose();
+         }  
+         
+         consumers.clear();
+      }
+      
+      synchronized (browsers)
+      {            
+         for( Iterator i = browsers.values().iterator(); i.hasNext(); )
+         {
+            ((ServerBrowserEndpoint)i.next()).localClose();
+         }  
+         
+         browsers.clear();
+      }
+      
+      //Now cancel any remaining deliveries in reverse delivery order
+      //Note we don't maintain order using a LinkedHashMap since then we lose
+      //concurrency since we would have to lock it exclusively
+      
+      List entries = new ArrayList(deliveries.entrySet());
+      
+      //Sort them in reverse delivery id order
+      Collections.sort(entries,
+                       new Comparator()
+                       {
+                           public int compare(Object obj1, Object obj2)
+                           {
+                              Map.Entry entry1 = (Map.Entry)obj1;
+                              Map.Entry entry2 = (Map.Entry)obj2;
+                              Long id1 = (Long)entry1.getKey();
+                              Long id2 = (Long)entry2.getKey();
+                              return id2.compareTo(id1);
+                           } 
+                       });
 
-   protected ServerConsumerEndpoint getConsumerEndpoint(int consumerID)
-   {
-      return (ServerConsumerEndpoint)consumers.get(new Integer(consumerID));
-   }
+      Iterator iter = entries.iterator();
+            
+      Set channels = new HashSet();
+      
+      if (trace) { log.trace("Cancelling " + entries.size() + " deliveries"); }
+      
+      while (iter.hasNext())
+      {
+         Map.Entry entry = (Map.Entry)iter.next();
+         
+         if (trace) { log.trace("Cancelling delivery with delivery id: " + entry.getKey()); }
+         
+         Delivery del = (Delivery)entry.getValue();
+         
+         del.cancel();
+         
+         channels.add(del.getObserver());
+      }
+      
+      promptDelivery(channels);
+      
+      deliveries.clear();
+            
+      JMSDispatcher.instance.unregisterTarget(new Integer(id));
+      
+      closed = true;
+   }            
    
-   protected ServerConsumerEndpoint removeConsumerEndpoint(int consumerID)
+   void cancelDelivery(long deliveryId) throws Throwable
    {
-      if (trace) { log.trace(this + " removing consumer " + consumerID + " from cache"); }
-      return (ServerConsumerEndpoint)consumers.remove(new Integer(consumerID));
+      Delivery del = (Delivery)deliveries.remove(new Long(deliveryId));
+      
+      if (del == null)
+      {
+         throw new IllegalStateException("Cannot find delivery to cancel " + deliveryId);
+      }
+      
+      del.cancel();
    }
    
-   protected ServerBrowserEndpoint putBrowserDelegate(int browserID, ServerBrowserEndpoint sbd)
+   long addDelivery(Delivery del)
    {
-      return (ServerBrowserEndpoint)browsers.put(new Integer(browserID), sbd);
+      long deliveryId = deliveryIdSequence.increment();
+      
+      deliveries.put(new Long(deliveryId), del);
+      
+      if (trace) { log.trace(this + " Added delivery: " + deliveryId + ", " + del); }
+      
+      return deliveryId;      
    }
    
-   protected ServerBrowserEndpoint getBrowserDelegate(int browserID)
+   void acknowledgeTransactionally(List acks, Transaction tx) throws Throwable
    {
-      return (ServerBrowserEndpoint)browsers.get(new Integer(browserID));
+      if (trace) { log.trace("Acknowledging transactionally " + acks.size() + " for tx: " + tx); }
+      
+      DeliveryCallback deliveryCallback = (DeliveryCallback)tx.getCallback(this);
+      
+      if (deliveryCallback == null)
+      {
+         deliveryCallback = new DeliveryCallback();
+         tx.addCallback(deliveryCallback, this);
+      }
+            
+      Iterator iter = acks.iterator();
+      
+      while (iter.hasNext())
+      {
+         Ack ack = (Ack)iter.next();
+         
+         Long id = new Long(ack.getDeliveryId());
+           
+         Delivery del = (Delivery)deliveries.get(id);
+         
+         if (del == null)
+         {
+            throw new IllegalStateException("Cannot find delivery to acknowledge " + ack);
+         }
+                           
+         deliveryCallback.addDeliveryId(id);
+         
+         del.acknowledge(tx);
+      }      
    }
    
-   protected ServerBrowserEndpoint removeBrowserDelegate(int browserID)
-   {
-      return (ServerBrowserEndpoint)browsers.remove(new Integer(browserID));
-   }
-
    /**
     * Starts this session's Consumers
     */
-   protected void setStarted(boolean s) throws Throwable
+   void setStarted(boolean s) throws Throwable
    {
       synchronized(consumers)
       {
@@ -747,26 +935,12 @@
             }
          }
       }
-   }   
+   } 
 
+   // Protected -----------------------------------------------------        
+
    // Private -------------------------------------------------------
-   
-   private void acknowledgeInternal(AckInfo ackInfo) throws Throwable
-   {
-      //If the message was delivered via a connection consumer then the message needs to be acked
-      //via the original consumer that was used to feed the connection consumer - which
-      //won't be one of the consumers of this session
-      //Therefore we always look in the global map of consumers held in the server peer
-      ServerConsumerEndpoint consumer = this.connectionEndpoint.getConsumerEndpoint(ackInfo.getConsumerID());
-
-      if (consumer == null)
-      {
-         throw new IllegalArgumentException("Cannot find consumer id: " + ackInfo.getConsumerID());
-      }
       
-      consumer.acknowledge(ackInfo.getMessageID());
-   }
-   
    private ConsumerDelegate failoverConsumer(JBossDestination jmsDestination,
             String selectorString,
             boolean noLocal,  String subscriptionName,
@@ -804,27 +978,27 @@
          
          new ServerConsumerEndpoint(consumerID, binding.getQueue(),
                   binding.getQueue().getName(), this, selectorString, noLocal,
-                  jmsDestination, prefetchSize, dlq);
+                  jmsDestination, prefetchSize);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
       
       ClientConsumerDelegate stub =
          new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
                   prefetchSize, maxDeliveryAttempts);
+            
+      synchronized (consumers)
+      {      
+         consumers.put(new Integer(consumerID), ep);
+      }
       
-      
-      putConsumerEndpoint(consumerID, ep); // caching consumer locally
-      
-      connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
-      
       return stub;
    }
    
    private ConsumerDelegate createConsumerDelegateInternal(JBossDestination jmsDestination,
-            String selectorString,
-            boolean noLocal,
-            String subscriptionName,
-            boolean isCC) throws Throwable
+                                                           String selectorString,
+                                                           boolean noLocal,
+                                                           String subscriptionName,
+                                                           boolean isCC) throws Throwable
    {
       if (closed)
       {
@@ -993,8 +1167,10 @@
                
                if (trace) { log.trace("selector " + (selectorChanged ? "has" : "has NOT") + " changed"); }
                
-               boolean topicChanged = !binding.getCondition().equals(jmsDestination.getName());
+               JMSCondition cond = (JMSCondition)binding.getCondition();
                
+               boolean topicChanged = !cond.getName().equals(jmsDestination.getName());
+               
                if (log.isTraceEnabled()) { log.trace("topic " + (topicChanged ? "has" : "has NOT") + " changed"); }
                
                if (selectorChanged || topicChanged)
@@ -1069,7 +1245,7 @@
       ServerConsumerEndpoint ep =
          new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
                   binding.getQueue().getName(), this, selectorString, noLocal,
-                  jmsDestination, prefetchSize, dlq);
+                  jmsDestination, prefetchSize);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
       
@@ -1077,14 +1253,82 @@
          new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
                   prefetchSize, maxDeliveryAttempts);
       
-      putConsumerEndpoint(consumerID, ep); // caching consumer locally
-      
-      connectionEndpoint.getServerPeer().putConsumerEndpoint(consumerID, ep); // cachin consumer in server peer
-      
+      synchronized (consumers)
+      {
+         consumers.put(new Integer(consumerID), ep);
+      }
+         
       log.debug("created and registered " + ep);
       
       return stub;
    }
-
+   
+   private void promptDelivery(Set channels)
+   {
+      //Now prompt delivery on the channels
+      Iterator iter = channels.iterator();
+      
+      while (iter.hasNext())
+      {
+         DeliveryObserver observer = (DeliveryObserver)iter.next();
+         
+         ((Channel)observer).deliver(false);
+      }
+   }
+   
+   
    // Inner classes -------------------------------------------------
+   
+   /**
+    * 
+    * The purpose of this class is to remove deliveries from the delivery list on commit
+    * Each transaction has once instance of this per SCE
+    *
+    */
+   private class DeliveryCallback implements TxCallback
+   {
+      List delList = new ArrayList();
+         
+      public void beforePrepare()
+      {         
+         //NOOP
+      }
+      
+      public void beforeCommit(boolean onePhase)
+      {         
+         //NOOP
+      }
+      
+      public void beforeRollback(boolean onePhase)
+      {         
+         //NOOP
+      }
+      
+      public void afterPrepare()
+      {         
+         //NOOP
+      }
+      
+      public synchronized void afterCommit(boolean onePhase) throws TransactionException
+      {
+         // Remove the deliveries from the delivery map.
+         Iterator iter = delList.iterator();
+         while (iter.hasNext())
+         {
+            Long deliveryId = (Long)iter.next();
+            
+            deliveries.remove(deliveryId);
+         }
+      }
+      
+      public void afterRollback(boolean onePhase) throws TransactionException
+      {                            
+         //NOOP
+      }
+      
+      synchronized void addDeliveryId(Long deliveryId)
+      {
+         delList.add(deliveryId);
+      }
+   }
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -33,7 +33,6 @@
 import org.jboss.jms.destination.JBossQueue;
 import org.jboss.jms.destination.JBossTopic;
 import org.jboss.jms.message.JBossMessage;
-import org.jboss.jms.tx.AckInfo;
 
 /**
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -73,14 +72,14 @@
     * @param ackInfos
     * @throws JMSException
     */
-   void acknowledgeBatch(List ackInfos) throws JMSException;
+   void acknowledgeBatch(List deliveryIds) throws JMSException;
    
    /**
     * Acknowledge a message - used for auto acknowledge
-    * @param ackInfo
+    * @param deliveryId
     * @throws JMSException
     */
-   void acknowledge(AckInfo ackInfo) throws JMSException;
+   void acknowledge(Ack ack) throws JMSException;
    
    /**
     * Add a temporary destination.
@@ -114,15 +113,14 @@
     * or at session recovery to cancel any messages that couldn't be redelivered locally
     * @param ackInfos
     */
-   void cancelDeliveries(List ackInfos) throws JMSException;
-   
-   
+   void cancelDeliveries(List cancelInfos) throws JMSException;
+      
    /**
-    * Send a list of unacked ackInfos to the server so the delivery lists can be repopulated
+    * Send delivery info to the server so the delivery lists can be repopulated
     * used at failover
     * @param ackInfos
     * @throws JMSException
     */
-   void sendUnackedAckInfos(List ackInfos) throws JMSException;
+   void recoverDeliveries(List createInfos) throws JMSException;
 }
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/BrowserAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/BrowserAdvised.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/BrowserAdvised.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -65,11 +65,6 @@
       endpoint.closing();
    }
 
-   public boolean isClosed()
-   {
-      return endpoint.isClosed();
-   }
-
    public boolean hasNextMessage() throws JMSException
    {
       return endpoint.hasNextMessage();
@@ -84,6 +79,11 @@
    {
       return endpoint.nextMessageBlock(maxMessages);
    }
+   
+   public boolean isClosed() throws JMSException
+   {
+      return endpoint.isClosed();
+   }
 
    // AdvisedSupport overrides --------------------------------------
    

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionAdvised.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionAdvised.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -67,11 +67,6 @@
       endpoint.closing();
    }
 
-   public boolean isClosed()
-   {
-      return endpoint.isClosed();
-   }
-
    public SessionDelegate createSessionDelegate(boolean transacted,
                                                 int acknowledgmentMode,
                                                 boolean isXA) throws JMSException
@@ -108,6 +103,11 @@
    {
       return endpoint.getPreparedTransactions();
    }
+   
+   public boolean isClosed() throws JMSException
+   {
+      return endpoint.isClosed();
+   }
 
    // Public --------------------------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -64,11 +64,6 @@
       endpoint.closing();
    }
 
-   public boolean isClosed()
-   {
-      return endpoint.isClosed();
-   }
-
    public void more() throws JMSException
    {
       endpoint.more();
@@ -78,6 +73,11 @@
    {
       endpoint.confirmDelivery(count);
    }
+   
+   public boolean isClosed() throws JMSException
+   {
+      return endpoint.isClosed();
+   }
 
   
    // AdvisedSupport overrides --------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -31,8 +31,8 @@
 import org.jboss.jms.destination.JBossQueue;
 import org.jboss.jms.destination.JBossTopic;
 import org.jboss.jms.message.JBossMessage;
+import org.jboss.jms.server.endpoint.Ack;
 import org.jboss.jms.server.endpoint.SessionEndpoint;
-import org.jboss.jms.tx.AckInfo;
 
 /**
  * The server-side advised instance corresponding to a Session. It is bound to the AOP
@@ -74,11 +74,6 @@
       endpoint.closing();
    }
 
-   public boolean isClosed()
-   {
-      return endpoint.isClosed();
-   }
-
    public void send(JBossMessage msg) throws JMSException
    {
       endpoint.send(msg);
@@ -107,12 +102,12 @@
       return endpoint.createTopic(topicName);
    }
 
-   public void acknowledgeBatch(List ackInfos) throws JMSException
+   public void acknowledgeBatch(List acks) throws JMSException
    {
-      endpoint.acknowledgeBatch(ackInfos);
+      endpoint.acknowledgeBatch(acks);
    }
    
-   public void acknowledge(AckInfo ack) throws JMSException
+   public void acknowledge(Ack ack) throws JMSException
    {
       endpoint.acknowledge(ack);
    }
@@ -137,11 +132,16 @@
       endpoint.cancelDeliveries(ackInfos);
    }
    
-   public void sendUnackedAckInfos(List ackInfos) throws JMSException
+   public void recoverDeliveries(List ackInfos) throws JMSException
    {
-      endpoint.sendUnackedAckInfos(ackInfos);
+      endpoint.recoverDeliveries(ackInfos);
    }
 
+   public boolean isClosed() throws JMSException
+   {
+      return endpoint.isClosed();
+   }
+   
 
    // AdvisedSupport overrides --------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -42,8 +42,11 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
+import org.jboss.jms.server.endpoint.Ack;
+import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.ClientDelivery;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.server.endpoint.DefaultAck;
+import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.message.MessageFactory;
@@ -95,7 +98,8 @@
    protected static final byte MORE = 5;
    protected static final byte SEND_TRANSACTION = 6;
    protected static final byte GET_ID_BLOCK = 7;
-   protected static final byte UNACKED_ACKINFOS = 8;
+   protected static final byte RECOVER_DELIVERIES = 8;
+   protected static final byte CONFIRM_DELIVERY = 9;
  
 
    // The response codes - start from 100
@@ -233,9 +237,9 @@
    
                   writeHeader(mi, dos);
                   
-                  AckInfo ack = (AckInfo)mi.getArguments()[0];
+                  Ack ack = (Ack)mi.getArguments()[0];
                   
-                  ack.write(dos);
+                  dos.writeLong(ack.getDeliveryId());
    
                   dos.flush();
    
@@ -255,8 +259,8 @@
    
                   while (iter.hasNext())
                   {
-                     AckInfo ack = (AckInfo)iter.next();
-                     ack.write(dos);
+                     Ack ack = (Ack)iter.next();
+                     dos.writeLong(ack.getDeliveryId());
                   }
    
                   dos.flush();
@@ -305,17 +309,17 @@
    
                   while (iter.hasNext())
                   {
-                     AckInfo ack = (AckInfo)iter.next();
-                     ack.write(dos);
+                     Cancel cancel = (Cancel)iter.next();
+                     cancel.write(dos);
                   }
    
                   dos.flush();
    
                   if (trace) { log.trace("wrote cancelDeliveries()"); }
                }
-               else if ("sendUnackedAckInfos".equals(methodName) && mi.getArguments() != null)
+               else if ("recoverDeliveries".equals(methodName) && mi.getArguments() != null)
                {
-                  dos.writeByte(UNACKED_ACKINFOS);
+                  dos.writeByte(RECOVER_DELIVERIES);
    
                   writeHeader(mi, dos);
    
@@ -327,14 +331,28 @@
    
                   while (iter.hasNext())
                   {
-                     AckInfo ack = (AckInfo)iter.next();
-                     ack.write(dos);
+                     DeliveryRecovery d = (DeliveryRecovery)iter.next();
+                     d.write(dos);
                   }
    
                   dos.flush();
    
                   if (trace) { log.trace("wrote sendUnackedAckInfos()"); }
                }
+               else if ("confirmDelivery".equals(methodName))
+               {
+                  dos.writeByte(CONFIRM_DELIVERY);
+   
+                  writeHeader(mi, dos);
+   
+                  Integer count = (Integer)mi.getArguments()[0];
+   
+                  dos.writeInt(count.intValue());
+                     
+                  dos.flush();
+   
+                  if (trace) { log.trace("wrote confirmDelivery()"); }
+               }
                else
                {
                   dos.write(SERIALIZED);
@@ -483,14 +501,6 @@
 
                   // We don't use acknowledgeable push callbacks
 
-//                  Map payload = callback.getReturnPayload();
-//                  String guid = (String)payload.get(ServerInvokerCallbackHandler.CALLBACK_ID);
-//                  dos.writeUTF(guid);
-//                  String listenerId = (String)payload.get(Client.LISTENER_ID_KEY);
-//                  dos.writeUTF(listenerId);
-//                  String acks = (String)payload.get(ServerInvokerCallbackHandler.REMOTING_ACKNOWLEDGES_PUSH_CALLBACKS);
-//                  dos.writeUTF(acks);
-                  
                   MessagingMarshallable mm = (MessagingMarshallable)callback.getParameter();
                   ClientDelivery delivery = (ClientDelivery)mm.getLoad();
                   delivery.write(dos);
@@ -649,11 +659,9 @@
             {
                MethodInvocation mi = readHeader(dis);
                
-               AckInfo info = new AckInfo();
+               long l = dis.readLong();
                
-               info.read(dis);
-               
-               Object[] args = new Object[] {info};
+               Object[] args = new Object[] {new DefaultAck(l)};
    
                mi.setArguments(args);
    
@@ -675,11 +683,9 @@
                
                for (int i = 0; i < num; i++)
                {
-                  AckInfo ack = new AckInfo();
+                  long l = dis.readLong();                  
                   
-                  ack.read(dis);
-                  
-                  acks.add(ack);
+                  acks.add(new DefaultAck(l));
                }
                            
                Object[] args = new Object[] {acks};
@@ -704,11 +710,11 @@
    
                for (int i = 0; i < size; i++)
                {
-                  AckInfo ack = new AckInfo();
+                  Cancel cancel = new Cancel();
                   
-                  ack.read(dis);
+                  cancel.read(dis);
                   
-                  acks.add(ack);
+                  acks.add(cancel);
                }
    
                Object[] args = new Object[] {acks};
@@ -723,24 +729,24 @@
    
                return request;
             }
-            case UNACKED_ACKINFOS:
+            case RECOVER_DELIVERIES:
             {
                MethodInvocation mi = readHeader(dis);
    
                int size = dis.readInt();
    
-               List acks = new ArrayList(size);
+               List dels = new ArrayList(size);
    
                for (int i = 0; i < size; i++)
                {
-                  AckInfo ack = new AckInfo();
+                  DeliveryRecovery d = new DeliveryRecovery();
                   
-                  ack.read(dis);
+                  d.read(dis);
                   
-                  acks.add(ack);
+                  dels.add(d);
                }
    
-               Object[] args = new Object[] {acks};
+               Object[] args = new Object[] {dels};
    
                mi.setArguments(args);
    
@@ -752,6 +758,24 @@
    
                return request;
             }
+            case CONFIRM_DELIVERY:
+            {
+               MethodInvocation mi = readHeader(dis);
+   
+               int count = dis.readInt();                  
+   
+               Object[] args = new Object[] {new Integer(count)};
+   
+               mi.setArguments(args);
+   
+               InvocationRequest request =
+                  new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
+                                        new MessagingMarshallable(version, mi), null, null, null);
+   
+               if (trace) { log.trace("read confirmDelivery()"); }
+   
+               return request;
+            }
             case ID_BLOCK_RESPONSE:
             {
                IdBlock block = new IdBlock();
@@ -852,18 +876,11 @@
                {
                   // We don't use acknowledgeable push callbacks
 
-//                  String guid = dis.readUTF();
-//                  String listenerId = dis.readUTF();
-//                  String acks = dis.readUTF();
                   ClientDelivery delivery = new ClientDelivery();
                   delivery.read(dis);
                   MessagingMarshallable mm = new MessagingMarshallable(version, delivery);
                   Callback callback = new Callback(mm);
-//                  HashMap payload = new HashMap();
-//                  payload.put(ServerInvokerCallbackHandler.CALLBACK_ID, guid);
-//                  payload.put(Client.LISTENER_ID_KEY, listenerId);
-//                  payload.put(ServerInvokerCallbackHandler.REMOTING_ACKNOWLEDGES_PUSH_CALLBACKS, acks);
-//                  callback.setReturnPayload(payload);
+
                   callbackList.add(callback);
                }
 

Deleted: trunk/src/main/org/jboss/jms/tx/AckInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/tx/AckInfo.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -1,147 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.tx;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-
-import org.jboss.jms.message.MessageProxy;
-import org.jboss.messaging.util.Streamable;
-
-/**
- * Struct like class for holding information regarding an acknowledgement to be passed to the server
- * for processing.
- * 
- * @author <a href="mailto:tim.fox at jboss.com>Tim Fox </a>
- * @author <a href="mailto:ovidiu at jboss.com>Ovidiu Feodorov</a>
- *
- * $Id$
- */
-public class AckInfo implements Streamable
-{
-   // Constants -----------------------------------------------------
-   
-   // Attributes ----------------------------------------------------
-   
-   protected long messageID;
-   protected int consumerID;
-   protected int deliveryCount;
-
-   protected MessageProxy msg;
-   
-   // Static --------------------------------------------------------
-   
-   // Constructors --------------------------------------------------
-   
-   public AckInfo()
-   {      
-   }
-
-   public AckInfo(MessageProxy proxy, int consumerID)
-   {
-      this.msg = proxy;
-      this.messageID = proxy.getMessage().getMessageID();
-      this.consumerID = consumerID;
-   }
-   
-   //Only used for testing
-   public AckInfo(long messageID, int consumerID, int deliveryCount)
-   {
-      this.messageID = messageID;
-      this.consumerID = consumerID;
-      this.deliveryCount = deliveryCount;
-   }
-
-   // Public --------------------------------------------------------
-   
-   public long getMessageID()
-   {
-      return messageID;
-   }
-   
-   public int getConsumerID()
-   {
-      return consumerID;
-   }
-
-   /** Used to change ack's id during failover */
-   public void setConsumerID(int consumerID)
-   {
-       this.consumerID = consumerID;
-   }
-   
-   public MessageProxy getMessage()
-   {
-      return msg;
-   }
-   
-   public int getDeliveryCount()
-   {
-      if (msg == null)
-      {
-         return deliveryCount;
-      }
-      else
-      {
-         return msg.getDeliveryCount();
-      }
-   }
-
-   public String toString()
-   {
-      return "AckInfo[" + messageID + ", " + consumerID + "]";
-   }
-
-   // Streamable implementation ---------------------------------
-
-   public void write(DataOutputStream out) throws Exception
-   {
-     out.writeLong(messageID);
-     out.writeInt(consumerID);
-     if (msg != null)
-     {
-        out.writeInt(msg.getDeliveryCount());
-     }
-     else
-     {
-        out.writeInt(deliveryCount);
-     }
-   }
-
-   public void read(DataInputStream in) throws Exception
-   {
-      messageID = in.readLong();
-      consumerID = in.readInt();
-      deliveryCount = in.readInt();
-   }
-   
-   // Class YYY overrides -------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Package Private -----------------------------------------------
-
-   // Private -------------------------------------------------------
-   
-   // Inner Classes -------------------------------------------------
-   
-}

Copied: trunk/src/main/org/jboss/jms/tx/ClientTransaction.java (from rev 1783, trunk/src/main/org/jboss/jms/tx/TxState.java)
===================================================================
--- trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-13 09:46:39 UTC (rev 1783)
+++ trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -0,0 +1,391 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.tx;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Map;
+
+import org.jboss.jms.client.state.SessionState;
+import org.jboss.jms.message.JBossMessage;
+import org.jboss.jms.server.endpoint.Ack;
+import org.jboss.jms.server.endpoint.DefaultAck;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.messaging.core.message.MessageFactory;
+
+/**
+ * Holds the state of a transaction on the client side
+ * 
+ * @author <a href="mailto:tim.fox at jboss.com>Tim Fox </a>
+ */
+public class ClientTransaction
+{  
+   // Constants -----------------------------------------------------
+
+   public final static byte TX_OPEN = 0;
+   
+   public final static byte TX_ENDED = 1;
+   
+   public final static byte TX_PREPARED = 2;
+   
+   public final static byte TX_COMMITED = 3;
+   
+   public final static byte TX_ROLLEDBACK = 4;
+   
+   // Attributes ----------------------------------------------------
+   
+   private int state = TX_OPEN;
+   
+   //Maintained on the client side
+   private Map sessionStatesMap;
+   
+   //Read from on the server side
+   private List sessionStatesList;
+   
+   private boolean clientSide;
+   
+   // Static --------------------------------------------------------
+   
+   // Constructors --------------------------------------------------
+   
+   public ClientTransaction()
+   {                  
+      clientSide = true;
+   }
+   
+   // Public --------------------------------------------------------
+   
+   public int getState()
+   {
+      return state;
+   }
+   
+   public void addMessage(int sessionId, JBossMessage msg)
+   {
+      if (!clientSide)
+      {
+         throw new IllegalStateException("Cannot call this method on the server side");
+      }
+      SessionTxState sessionTxState = getSessionTxState(sessionId);
+      
+      sessionTxState.addMessage(msg);
+   }
+   
+   public void addAck(int sessionId, DeliveryInfo info)
+   {
+      if (!clientSide)
+      {
+         throw new IllegalStateException("Cannot call this method on the server side");
+      }
+      SessionTxState sessionTxState = getSessionTxState(sessionId);
+      
+      sessionTxState.addAck(info);
+   }      
+   
+   public void clearMessages()
+   {
+      if (!clientSide)
+      {
+         throw new IllegalStateException("Cannot call this method on the server side");
+      }
+      Iterator iter = sessionStatesMap.values().iterator();
+      
+      while (iter.hasNext())
+      {
+         SessionTxState sessionTxState = (SessionTxState)iter.next();
+         
+         sessionTxState.clearMessages();
+      }
+   }
+   
+   public void setState(int state)
+   {
+      if (!clientSide)
+      {
+         throw new IllegalStateException("Cannot call this method on the server side");
+      }
+      this.state = state;
+   }
+   
+   public Collection getSessionStates()
+   {
+      if (sessionStatesList != null)
+      {
+         return sessionStatesList;
+      }
+      else
+      {
+         return sessionStatesMap.values();
+      }
+   }   
+   
+   /*
+    * Substitute newSessionId for oldSessionId
+    */
+   public void handleFailover(Map oldNewSessionMap)
+   {    
+      if (!clientSide)
+      {
+         throw new IllegalStateException("Cannot call this method on the server side");
+      }
+      //Note we have to do this in one go since there may be overlap between old and new session ids
+      //and we don't want to overwrite keys in the map
+      
+      if (sessionStatesMap != null)
+      {         
+         Map newMap = new HashMap();
+         
+         Iterator iter = oldNewSessionMap.entrySet().iterator();
+         
+         while (iter.hasNext())
+         {
+            Map.Entry entry = (Map.Entry)iter.next();
+            
+            Integer oldSessionId = (Integer)entry.getKey();
+            
+            SessionState newSessionState = (SessionState)entry.getValue();
+            
+            int newSessionId = newSessionState.getSessionId();
+            
+            SessionTxState state = (SessionTxState)sessionStatesMap.get(oldSessionId);
+            
+            if (state != null)
+            {
+               state.handleFailover(newSessionId);
+            }
+            
+            newMap.put(new Integer(newSessionId), state);
+            
+         }
+       
+         sessionStatesMap = newMap;
+      }
+   }
+   
+   public List getDeliveriesForSession(int sessionId)
+   {
+      if (!clientSide)
+      {
+         throw new IllegalStateException("Cannot call this method on the server side");
+      }
+      SessionTxState state = getSessionTxState(sessionId);
+      
+      if (state != null)
+      {
+         return state.getAcks();
+      }
+      else
+      {
+         return null;
+      }
+   }
+   
+   // Streamable implementation ---------------------------------
+   
+   public void write(DataOutputStream out) throws Exception
+   {
+      out.writeInt(state);
+      
+      out.writeInt(sessionStatesMap.size());
+      
+      Iterator iter = sessionStatesMap.values().iterator();
+      
+      while (iter.hasNext())
+      {
+         SessionTxState state = (SessionTxState)iter.next();
+         
+         out.writeInt(state.getSessionId());
+         
+         List msgs = state.getMsgs();
+         
+         out.writeInt(msgs.size());
+         
+         Iterator iter2 = msgs.iterator();
+         
+         while (iter2.hasNext())
+         {
+            JBossMessage m = (JBossMessage)iter2.next();
+
+            out.writeByte(m.getType());
+            
+            m.write(out);
+         }
+         
+         List acks = state.getAcks();
+         
+         out.writeInt(acks.size());
+         
+         iter2 = acks.iterator();
+         
+         while (iter2.hasNext())
+         {
+            DeliveryInfo ack = (DeliveryInfo)iter2.next();
+
+            //We only need the delivery id written
+            out.writeLong(ack.getMessageProxy().getDeliveryId());
+         }
+      }
+   }  
+    
+   
+   public void read(DataInputStream in) throws Exception
+   {
+      clientSide = false;
+      
+      state = in.readInt();
+      
+      int numSessions = in.readInt();
+      
+      //Read in as a list since we don't want the extra overhead of putting into a map
+      //which won't be used on the server side
+      sessionStatesList = new ArrayList(numSessions);
+      
+      for (int i = 0; i < numSessions; i++)
+      {
+         int sessionId = in.readInt();
+         
+         SessionTxState sessionState = new SessionTxState(sessionId);
+         
+         sessionStatesList.add(sessionState);
+         
+         int numMsgs = in.readInt();
+         
+         for (int j = 0; j < numMsgs; j++)            
+         {
+            byte type = in.readByte();
+            
+            JBossMessage msg = (JBossMessage)MessageFactory.createMessage(type);
+            
+            msg.read(in);
+            
+            sessionState.addMessage(msg);
+         }
+         
+         int numAcks = in.readInt();
+         
+         for (int j = 0; j < numAcks; j++)            
+         {
+            long ack = in.readLong();
+            
+            sessionState.addAck(new DefaultAck(ack));
+         }
+      }      
+   }
+   
+   // Protected -----------------------------------------------------
+   
+   // Package Private -----------------------------------------------
+   
+   // Private -------------------------------------------------------
+   
+   private SessionTxState getSessionTxState(int sessionId)
+   {                  
+      if (sessionStatesMap == null)
+      {
+         sessionStatesMap = new HashMap();
+      }
+      
+      SessionTxState sessionTxState = (SessionTxState)sessionStatesMap.get(new Integer(sessionId));
+      
+      if (sessionTxState == null)
+      {
+         sessionTxState = new SessionTxState(sessionId);
+         
+         sessionStatesMap.put(new Integer(sessionId), sessionTxState);
+      }
+      
+      return sessionTxState;
+   }
+   
+   
+      
+   // Inner Classes -------------------------------------------------
+   
+   public class SessionTxState
+   {
+      SessionTxState(int sessionId)
+      {
+         this.sessionId = sessionId;
+      }
+      
+      void addMessage(JBossMessage msg)
+      {
+         msgs.add(msg);
+      }
+      
+      void addAck(Ack ack)
+      {
+         acks.add(ack);
+      }
+      
+      public List getMsgs()
+      {
+         return msgs;
+      }
+      
+      public List getAcks()
+      {
+         return acks;
+      }
+      
+      public int getSessionId()
+      {
+         return sessionId;
+      }
+      
+      void handleFailover(int newSessionId)
+      {
+         this.sessionId = newSessionId;
+         
+         //Remove any non persistent acks
+         
+         Iterator iter = acks.iterator();
+         
+         while (iter.hasNext())
+         {
+            DeliveryInfo info = (DeliveryInfo)iter.next();
+            
+            if (!info.getMessageProxy().getMessage().isReliable())
+            {
+               iter.remove();
+            }
+         }
+      }
+      
+      void clearMessages()
+      {
+         msgs.clear();
+      }
+      
+      private int sessionId;
+      
+      private List msgs = new ArrayList();
+      
+      private List acks = new ArrayList();            
+   }
+      
+}

Modified: trunk/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -22,16 +22,13 @@
 package org.jboss.jms.tx;
 
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.Iterator;
-import java.util.LinkedHashMap;
-import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 
 import javax.jms.IllegalStateException;
 import javax.jms.JMSException;
-import javax.jms.Message;
 import javax.jms.TransactionRolledBackException;
 import javax.transaction.xa.XAException;
 import javax.transaction.xa.XAResource;
@@ -39,6 +36,10 @@
 
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
+import org.jboss.jms.message.JBossMessage;
+import org.jboss.jms.message.MessageProxy;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.jms.tx.ClientTransaction.SessionTxState;
 import org.jboss.jms.util.MessagingTransactionRolledBackException;
 import org.jboss.jms.util.MessagingXAException;
 import org.jboss.logging.Logger;
@@ -66,7 +67,7 @@
    
    private boolean trace = log.isTraceEnabled();
    
-   protected ConcurrentHashMap transactions = new ConcurrentHashMap();
+   private ConcurrentHashMap transactions = new ConcurrentHashMap();
    
    // Static --------------------------------------------------------
    
@@ -76,24 +77,20 @@
     
    // Public --------------------------------------------------------
    
-   public TxState getTx(Object xid)
+   /**
+    * Remove a tx
+    */
+   public ClientTransaction removeTx(Object xid)
    {
-      if (trace) { log.trace("getting transaction for " + xid); }
-      
-      return (TxState)transactions.get(xid);
+      return removeTxInternal(xid);
    }
-   
-   public TxState removeTx(Object xid)
-   {
-      return (TxState)transactions.remove(xid);
-   }
-   
+            
    /**
     * Create a local tx.
     */
    public LocalTx createLocalTx()
    {
-      TxState tx = new TxState();
+      ClientTransaction tx = new ClientTransaction();
       
       LocalTx xid = getNextTxId();
       
@@ -108,70 +105,58 @@
     * @param xid - The id of the transaction to add the message to
     * @param m The message
     */
-   public void addMessage(Object xid, Message m)
+   public void addMessage(Object xid, int sessionId, JBossMessage msg)
    {
       if (trace) { log.trace("addding message for xid " + xid); }
       
-      TxState tx = getTx(xid);
+      ClientTransaction tx = getTxInternal(xid);
       
-      tx.getMessages().add(m);
+      tx.addMessage(sessionId, msg);
    }
-
-    /**
-     * Navigate on ACK and change consumer ids on every ACK not sent yet.
-     */
-    public void handleFailover(int oldConsumerID, int newConsumerID)
-    {
-        if (trace) { log.trace("handleFailover:: Transfering consumer id on ACKs from  " + oldConsumerID + " to " + newConsumerID); }
-
-        //TODO need to lock the rm while this is happening
-        
-        //Note we need to replace ids for *all* transactions - this is because, for XA
-        //the session might have done work in many transactions
-        Iterator iter = this.transactions.values().iterator();
-        
-        while (iter.hasNext())
-        {
-           TxState tx = (TxState)iter.next();
-           
-           tx.handleFailover(oldConsumerID, newConsumerID);
-        }                
-    }
-    
-    /*
-     * Get all the ackinfos with a consumer id in the specified set
-     */
-    public List getAckInfosForConsumerIds(Set consumerIds)
-    {
-       Iterator iter = this.transactions.values().iterator();
-       
-       List ackInfos = new ArrayList();
-       
-       while (iter.hasNext())
-       {
-          TxState tx = (TxState)iter.next();
-          
-          tx.getAckInfosForConsumerIds(ackInfos, consumerIds);
-       }
-       
-       return ackInfos;
-    }
-    
-    public void removeNonPersistentAcks(Set consumerIds)
-    {
-       Iterator iter = this.transactions.values().iterator();
-       
-       List ackInfos = new ArrayList();
-       
-       while (iter.hasNext())
-       {
-          TxState tx = (TxState)iter.next();
-          
-          tx.removeNonPersistentAcks(consumerIds);
-       }
-    }
-
    
+   /*
+    * Failover session from old session -> new session
+    * This basically involves updating the session id
+    */
+   public void handleFailover(Map oldNewSessionMap)
+   {
+      //Note we need to replace ids for *all* transactions - this is because, for XA
+      //the session might have done work in many transactions
+      Iterator iter = this.transactions.values().iterator();
+      
+      while (iter.hasNext())
+      {
+         ClientTransaction tx = (ClientTransaction)iter.next();
+         
+         tx.handleFailover(oldNewSessionMap);
+      }                
+   }   
+   
+   /*
+    * Get all the deliveries corresponding to the session id
+    */
+   public List getDeliveriesForSession(int sessionId)
+   {
+      Iterator iter = this.transactions.values().iterator();
+      
+      List ackInfos = new ArrayList();
+      
+      while (iter.hasNext())
+      {
+         ClientTransaction tx = (ClientTransaction)iter.next();
+         
+         List acks = tx.getDeliveriesForSession(sessionId);
+         
+         if (acks != null)
+         {
+            ackInfos.addAll(acks);
+         }
+      }
+      
+      return ackInfos;
+   }
+   
+   
    /**
     * Add an acknowledgement to the transaction
     * 
@@ -180,25 +165,25 @@
     * @param sessionState - the session the ack is in - we need this so on rollback we can tell each session
     * to redeliver it's messages
     */
-   public void addAck(Object xid, AckInfo ackInfo) throws JMSException
+   public void addAck(Object xid, int sessionId, DeliveryInfo ackInfo) throws JMSException
    {
       if (trace) { log.trace("adding " + ackInfo + " to transaction " + xid); }
       
-      TxState tx = getTx(xid);
+      ClientTransaction tx = getTxInternal(xid);
       
       if (tx == null)
       {
          throw new JMSException("There is no transaction with id " + xid);
       }
       
-      tx.getAcks().add(ackInfo);
+      tx.addAck(sessionId, ackInfo);
    }
          
    public void commitLocal(LocalTx xid, ConnectionDelegate connection) throws JMSException
    {
       if (trace) { log.trace("commiting local xid " + xid); }
       
-      TxState tx = this.getTx(xid);
+      ClientTransaction tx = this.getTxInternal(xid);
       
       //Invalid xid
       if (tx == null)
@@ -215,7 +200,7 @@
          
          //If we get this far we can remove the transaction
          
-         this.removeTx(xid);
+         this.removeTxInternal(xid);
       }
       catch (Throwable t)
       {
@@ -233,7 +218,7 @@
    {
       if (trace) { log.trace("rolling back local xid " + xid); }
       
-      TxState ts = removeTx(xid);
+      ClientTransaction ts = removeTxInternal(xid);
       
       if (ts == null)
       {      
@@ -241,6 +226,7 @@
       }
       
       // don't need messages for rollback
+      // We don't clear the acks since we need to redeliver locally
       ts.clearMessages();
       
       // for one phase rollback there is nothing to do on the server
@@ -248,11 +234,27 @@
       redeliverMessages(ts);
    }
    
-   public void commit(Xid xid, boolean onePhase, ConnectionDelegate connection) throws XAException
+   //Only used for testing
+   public ClientTransaction getTx(Object xid)
    {
+      return getTxInternal(xid);
+   }
+   
+   //Only used for testing
+   public int size()
+   {
+      return transactions.size();
+   }
+    
+   // Protected ------------------------------------------------------      
+   
+   // Package Private ------------------------------------------------
+   
+   void commit(Xid xid, boolean onePhase, ConnectionDelegate connection) throws XAException
+   {
       if (trace) { log.trace("commiting xid " + xid + ", onePhase=" + onePhase); }
       
-      TxState tx = removeTx(xid);
+      ClientTransaction tx = removeTxInternal(xid);
           
       if (onePhase)
       {
@@ -273,7 +275,7 @@
       {
          if (tx != null)
          {
-            if (tx.getState() != TxState.TX_PREPARED)
+            if (tx.getState() != ClientTransaction.TX_PREPARED)
             {    
                throw new MessagingXAException(XAException.XAER_PROTO, "commit called for transaction, but it is not prepared");
             }
@@ -295,25 +297,26 @@
       
       if (tx != null)
       {
-         tx.setState(TxState.TX_COMMITED);
+         tx.setState(ClientTransaction.TX_COMMITED);
       }
    }
       
-   public void rollback(Xid xid, ConnectionDelegate connection) throws XAException
+   void rollback(Xid xid, ConnectionDelegate connection) throws XAException
    {
       if (trace) { log.trace("rolling back xid " + xid); }
       
-      TxState tx = removeTx(xid);
+      ClientTransaction tx = removeTxInternal(xid);
           
       TransactionRequest request = null;
       
       // we don't need to send the messages to the server on a rollback
       if (tx != null)
       {
+         //We don't clear the acks since we need to redeliver locally
          tx.clearMessages();
       }
       
-      if ((tx == null) || tx.getState() == TxState.TX_PREPARED)
+      if ((tx == null) || tx.getState() == ClientTransaction.TX_PREPARED)
       {
          request = new TransactionRequest(TransactionRequest.TWO_PHASE_ROLLBACK_REQUEST, xid, tx);
          
@@ -339,78 +342,25 @@
       }
    }
    
-   
-   /*
-    * Rollback has occurred so we need to redeliver any unacked messages corresponding to the acks
-    * is in the transaction.
-    */
-   private void redeliverMessages(TxState ts) throws JMSException
+   void endTx(Xid xid, boolean success) throws XAException
    {
-      // Sort messages into lists, one for each session. We use a LinkedHashMap since we need to
-      // preserve the order of the sessions.
-
-      Map toAck = new LinkedHashMap();
-
-      for(Iterator i = ts.getAcks().iterator(); i.hasNext(); )
-      {
-         AckInfo ack = (AckInfo)i.next();
-         SessionDelegate del = ack.msg.getSessionDelegate();
-         
-         List acks = (List)toAck.get(del);
-         if (acks == null)
-         {
-            acks = new ArrayList();
-            toAck.put(del, acks);
-         }
-         acks.add(ack);
-      }
-      
-      // Now tell each session to redeliver.
-      
-      LinkedList l = new LinkedList();
-      
-      for(Iterator i = toAck.entrySet().iterator(); i.hasNext();)
-      {
-         // need to reverse the order
-         Object entry = i.next();
-         l.addFirst(entry);
-      }
-      
-      for(Iterator i = l.iterator(); i.hasNext();)
-      {
-         Map.Entry entry = (Map.Entry)i.next();
-         SessionDelegate sess = (SessionDelegate)entry.getKey();
-         List acks = (List)entry.getValue();
-         sess.redeliver(acks);
-      }  
-   }
-   
-   public int size()
-   {
-      return transactions.size();
-   }
-
-   // Protected ------------------------------------------------------
-   
-   protected void endTx(Xid xid, boolean success) throws XAException
-   {
       if (trace) { log.trace("ending " + xid + ", success=" + success); }
       
-      TxState state = getTx(xid);
+      ClientTransaction state = getTxInternal(xid);
       
       if (state == null)
       {  
          throw new MessagingXAException(XAException.XAER_NOTA, "Cannot find transaction with xid:" + xid);
       }        
       
-      state.setState(TxState.TX_ENDED);
+      state.setState(ClientTransaction.TX_ENDED);
    }
    
-   protected Xid joinTx(Xid xid) throws XAException
+   Xid joinTx(Xid xid) throws XAException
    {
       if (trace) { log.trace("joining  " + xid); }
       
-      TxState state = getTx(xid);
+      ClientTransaction state = getTxInternal(xid);
       
       if (state == null)
       {         
@@ -420,11 +370,11 @@
       return xid;
    }
    
-   protected int prepare(Xid xid, ConnectionDelegate connection) throws XAException
+   int prepare(Xid xid, ConnectionDelegate connection) throws XAException
    {
       if (trace) { log.trace("preparing " + xid); }
       
-      TxState state = getTx(xid);
+      ClientTransaction state = getTxInternal(xid);
       
       if (state == null)
       { 
@@ -436,16 +386,16 @@
       
       sendTransactionXA(request, connection);      
       
-      state.setState(TxState.TX_PREPARED);
+      state.setState(ClientTransaction.TX_PREPARED);
       
       return XAResource.XA_OK;
    }
    
-   protected Xid resumeTx(Xid xid) throws XAException
+   Xid resumeTx(Xid xid) throws XAException
    {
       if (trace) { log.trace("resuming " + xid); }
       
-      TxState state = getTx(xid);
+      ClientTransaction state = getTxInternal(xid);
       
       if (state == null)
       {       
@@ -455,11 +405,11 @@
       return xid;
    }
    
-   protected Xid suspendTx(Xid xid) throws XAException
+   Xid suspendTx(Xid xid) throws XAException
    {
       if (trace) { log.trace("suspending " + xid); }
 
-      TxState state = getTx(xid);
+      ClientTransaction state = getTxInternal(xid);
       
       if (state == null)
       {       
@@ -469,48 +419,48 @@
       return xid;
    }
 
-   protected Xid convertTx(LocalTx anonXid, Xid xid) throws XAException
+   Xid convertTx(LocalTx anonXid, Xid xid) throws XAException
    {
       if (trace) { log.trace("converting " + anonXid + " to " + xid); }
 
-      TxState state = getTx(anonXid);
+      ClientTransaction state = getTxInternal(anonXid);
 
       if (state == null)
       {        
          throw new MessagingXAException(XAException.XAER_NOTA, "Cannot find transaction with xid:" + anonXid);
       }
 
-      state = getTx(xid);
+      state = getTxInternal(xid);
 
       if (state != null)
       {        
          throw new MessagingXAException(XAException.XAER_DUPID, "Transaction already exists:" + xid);
       }
 
-      TxState s = removeTx(anonXid);
+      ClientTransaction s = removeTxInternal(anonXid);
       
       transactions.put(xid, s);
       
       return xid;
    }
    
-   protected Xid startTx(Xid xid) throws XAException
+   Xid startTx(Xid xid) throws XAException
    {
       if (trace) { log.trace("starting " + xid); }
 
-      TxState state = getTx(xid);
+      ClientTransaction state = getTxInternal(xid);
       
       if (state != null)
       {
          throw new MessagingXAException(XAException.XAER_DUPID, "Transaction already exists with xid " + xid);
       }
             
-      transactions.put(xid, new TxState());
+      transactions.put(xid, new ClientTransaction());
       
       return xid;
    }
    
-   protected Xid[] recover(int flags, ConnectionDelegate conn) throws XAException
+   Xid[] recover(int flags, ConnectionDelegate conn) throws XAException
    {
       if (trace) { log.trace("calling recover with flags: " + flags); }
       
@@ -532,10 +482,47 @@
       }
    }
    
-   // Package Private ------------------------------------------------
-   
    // Private --------------------------------------------------------
    
+   private ClientTransaction getTxInternal(Object xid)
+   {
+      if (trace) { log.trace("getting transaction for " + xid); }
+      
+      return (ClientTransaction)transactions.get(xid);
+   }
+   
+   private ClientTransaction removeTxInternal(Object xid)
+   {
+      return (ClientTransaction)transactions.remove(xid);
+   }
+   
+   /*
+    * Rollback has occurred so we need to redeliver any unacked messages corresponding to the acks
+    * is in the transaction.
+    */
+   private void redeliverMessages(ClientTransaction ts) throws JMSException
+   {
+      Collection sessionStates = ts.getSessionStates();
+      
+      for (Iterator i = sessionStates.iterator(); i.hasNext();)
+      {
+         SessionTxState state = (SessionTxState)i.next();
+         
+         List acks = state.getAcks();
+         
+         if (!acks.isEmpty())
+         {
+            DeliveryInfo info = (DeliveryInfo)acks.get(0);
+            
+            MessageProxy mp = info.getMessageProxy();
+            
+            SessionDelegate del = mp.getSessionDelegate();
+            
+            del.redeliver(acks);
+         }
+      }
+   }
+   
    private synchronized LocalTx getNextTxId()
    {
       return new LocalTx();

Modified: trunk/src/main/org/jboss/jms/tx/TransactionRequest.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/TransactionRequest.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/tx/TransactionRequest.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -66,7 +66,7 @@
    /** For 2 phase commit, this identifies the transaction. */
    protected Xid xid;
 
-   protected TxState state;
+   protected ClientTransaction state;
    
    // Static --------------------------------------------------------
    
@@ -76,7 +76,7 @@
    {      
    }
    
-   public TransactionRequest(int requestType, Xid xid, TxState state)
+   public TransactionRequest(int requestType, Xid xid, ClientTransaction state)
    {      
       this.requestType = requestType;
       this.xid = xid;
@@ -153,7 +153,7 @@
      }
      else
      {
-        state = new TxState();
+        state = new ClientTransaction();
      
         state.read(in);
      }
@@ -161,7 +161,7 @@
 
    // Public --------------------------------------------------------
 
-   public TxState getState()
+   public ClientTransaction getState()
    {
       return state;
    }

Deleted: trunk/src/main/org/jboss/jms/tx/TxState.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/src/main/org/jboss/jms/tx/TxState.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -1,224 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.tx;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-
-import org.jboss.jms.message.JBossMessage;
-import org.jboss.messaging.core.message.MessageFactory;
-import org.jboss.messaging.util.Streamable;
-
-/**
- * Holds information for a JMS transaction to be sent to the server for
- * processing.
- * Holds the messages to be sent and the acknowledgements to be made
- * for the transaction
- * 
- * @author <a href="mailto:tim.fox at jboss.com>Tim Fox </a>
- */
-public class TxState implements Streamable
-{  
-   // Constants -----------------------------------------------------
-
-   public final static byte TX_OPEN = 0;
-   
-   public final static byte TX_ENDED = 1;
-   
-   public final static byte TX_PREPARED = 2;
-   
-   public final static byte TX_COMMITED = 3;
-   
-   public final static byte TX_ROLLEDBACK = 4;
-   
-   // Attributes ----------------------------------------------------
-   
-   protected int state = TX_OPEN;
-   
-   protected List messages = new ArrayList();
-   
-   protected List acks = new ArrayList();
-   
-   // Static --------------------------------------------------------
-   
-   // Constructors --------------------------------------------------
-   
-   public TxState()
-   {      
-   }
-   
-   // Public --------------------------------------------------------
-   
-   public int getState()
-   {
-      return state;
-   }
-   
-   public List getMessages()
-   {
-      return messages;
-   }
-   
-   public List getAcks()
-   {
-      return acks;
-   }
-   
-   public void clearMessages()
-   {
-      messages.clear();
-   }
-   
-   public void setState(int state)
-   {
-      this.state = state;
-   }
-
-
-   /** Navigate on ACK and change consumer ids on every ACK not sent yet */
-   public void handleFailover(int oldConsumerID, int newConsumerID)
-   {
-       for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
-       {
-           AckInfo ackInfo = (AckInfo)ackIterator.next();
-           
-           if (ackInfo.getConsumerID() == oldConsumerID)
-           {
-               ackInfo.setConsumerID(newConsumerID);
-           }
-       }
-   }
-   
-   public void getAckInfosForConsumerIds(List ackInfos, Set consumerIds)
-   {
-      for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
-      {
-          AckInfo ackInfo = (AckInfo)ackIterator.next();
-          
-          if (consumerIds.contains(new Integer(ackInfo.getConsumerID())))
-          {
-              ackInfos.add(ackInfo);
-          }
-      }
-   }
-   
-   public void removeNonPersistentAcks(Set consumerIds)
-   {
-      for (Iterator ackIterator = acks.iterator(); ackIterator.hasNext(); )
-      {
-          AckInfo ackInfo = (AckInfo)ackIterator.next();
-          
-          if (!ackInfo.msg.getMessage().isReliable())
-          {
-             ackIterator.remove();
-          }
-      }
-   }
-    
-   // Streamable implementation ---------------------------------
-   
-   public void write(DataOutputStream out) throws Exception
-   {
-      out.writeInt(state);
-      if (messages == null)
-      {
-         out.writeInt(-1);
-      }
-      else
-      {
-         out.writeInt(messages.size());
-         Iterator iter = messages.iterator();
-         while (iter.hasNext())
-         {
-            JBossMessage m = (JBossMessage)iter.next();
-            //We don't use writeObject to avoid serialization overhead
-            out.writeByte(m.getType());
-            m.write(out);
-         } 
-      }
-      if (acks == null)
-      {
-         out.writeInt(-1);
-      }
-      else
-      {
-         out.writeInt(acks.size());
-         Iterator iter = acks.iterator();
-         while (iter.hasNext())
-         {
-            AckInfo a = (AckInfo)iter.next();
-            //We don't use writeObject to avoid serialization overhead
-            a.write(out);
-         }
-      }
-   }
-   
-   public void read(DataInputStream in) throws Exception
-   {
-      state = in.readInt();
-      int numMessages = in.readInt();
-      if (numMessages == -1)
-      {
-         messages = null;
-      }
-      else
-      {
-         messages = new ArrayList(numMessages);
-         for (int i = 0; i < numMessages; i++)
-         {
-            byte type = in.readByte();
-            JBossMessage m = (JBossMessage)MessageFactory.createMessage(type);
-            m.read(in);
-            messages.add(m);
-         }
-      }
-      
-      int numAcks = in.readInt();
-      if (numAcks == -1)
-      {
-         acks = null;
-      }
-      else
-      {
-         acks = new ArrayList(numAcks);
-         for (int i = 0; i < numAcks; i++)
-         {
-            AckInfo info = new AckInfo();
-            info.read(in);
-            acks.add(info);
-         }
-      }  
-   }
-   
-   // Protected -----------------------------------------------------
-   
-   // Package Private -----------------------------------------------
-   
-   // Private -------------------------------------------------------
-      
-   // Inner Classes -------------------------------------------------
-      
-}

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/build.xml	2006-12-14 19:32:42 UTC (rev 1794)
@@ -387,7 +387,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <!-- <include name="**/messaging/core/**/*Test.class"/> -->
+               <include name="**/messaging/core/**/*Test.class"/>
                <include name="**/messaging/jms/**/*Test.class"/>
                <exclude name="**/jms/stress/**"/>
                <exclude name="**/jms/crash/*Test.class"/>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -157,20 +157,14 @@
          pub.publish(m);
          sess.commit();
          
-         log.info("sent messages");
-         
          //receive but rollback
          TextMessage m2 = (TextMessage)sub.receive(3000);
-         
-         log.info("received");
-            
+                
          assertNotNull(m2);
          assertEquals("testing123", m2.getText());
          
          sess.rollback();
          
-         log.info("rolled back");
-         
          conn.close();
          conn = cf.createTopicConnection();
          conn.start();
@@ -262,7 +256,7 @@
       }
    }
    
-   public void testTransactionalAcknowlegment() throws Exception
+   public void testTransactionalAcknowledgement() throws Exception
    {
 
       Connection conn = cf.createConnection();
@@ -328,7 +322,7 @@
       {
          m = consumer.receive();
          log.trace("Received message " + i);
-
+  
       }
       
       assertRemainingMessages(NUM_MESSAGES);
@@ -353,9 +347,8 @@
 	/**
 	 * Send some messages, don't acknowledge them and verify that they are re-sent on recovery.
 	 */
-	public void testClientAcknowledgeNoAcknowlegment() throws Exception
+	public void testClientAcknowledgeNoAcknowledgement() throws Exception
    {
-
 		Connection conn = cf.createConnection();
 
 		Session producerSess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
@@ -1203,7 +1196,10 @@
       Thread.sleep(500);
       ObjectName destObjectName = 
          new ObjectName("jboss.messaging.destination:service=Queue,name=Queue");
-      Integer messageCount = (Integer)ServerManagement.getAttribute(destObjectName, "MessageCount");      
+      Integer messageCount = (Integer)ServerManagement.getAttribute(destObjectName, "MessageCount"); 
+      
+      log.trace("There are " + messageCount + " messages");
+      
       assertEquals(expected, messageCount.intValue());      
       return expected == messageCount.intValue();
    }

Modified: trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -207,53 +207,64 @@
     */
    public void testRedeliveryToCompetingConsumerOnQueue() throws Exception
    {
-      Connection conn = cf.createConnection();
+      Connection conn = null;
+      
+      try
+      {
+         conn = cf.createConnection();
+      
+         Session sessSend = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+         MessageProducer prod = sessSend.createProducer(queue);
+   
+         conn.start();
+   
+         Session sessConsume1 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+   
+         MessageConsumer cons1 = sessConsume1.createConsumer(queue);
+   
+         TextMessage tm = sessSend.createTextMessage();
+   
+         tm.setText("Your mum");
+   
+         prod.send(tm);
+   
+         TextMessage tm2 = (TextMessage)cons1.receive();
+   
+         assertNotNull(tm2);
+   
+         assertEquals("Your mum", tm2.getText());
+   
+         // Don't ack
+   
+         // Create another consumer
+   
+         Session sessConsume2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+   
+         MessageConsumer cons2 = sessConsume2.createConsumer(queue);
+   
+         // this should cancel message and cause delivery to other consumer
+   
+         log.trace("Closed session 1");
+         sessConsume1.close();
+   
+         TextMessage tm3 = (TextMessage)cons2.receive(1000);
+   
+         assertNotNull(tm3);
+   
+         assertEquals("Your mum", tm3.getText());
+   
+         tm3.acknowledge();
+      }
+      finally
+      {
 
-      Session sessSend = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
 
-      MessageProducer prod = sessSend.createProducer(queue);
-
-      conn.start();
-
-      Session sessConsume1 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
-
-      MessageConsumer cons1 = sessConsume1.createConsumer(queue);
-
-      TextMessage tm = sessSend.createTextMessage();
-
-      tm.setText("Your mum");
-
-      prod.send(tm);
-
-      TextMessage tm2 = (TextMessage)cons1.receive();
-
-      assertNotNull(tm2);
-
-      assertEquals("Your mum", tm2.getText());
-
-      // Don't ack
-
-      // Create another consumer
-
-      Session sessConsume2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
-
-      MessageConsumer cons2 = sessConsume2.createConsumer(queue);
-
-      // this should cancel message and cause delivery to other consumer
-
-      sessConsume1.close();
-
-      TextMessage tm3 = (TextMessage)cons2.receive(1000);
-
-      assertNotNull(tm3);
-
-      assertEquals("Your mum", tm3.getText());
-
-      tm3.acknowledge();
-
-      conn.close();
-
-
    }
 
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -31,6 +31,7 @@
 import java.io.Serializable;
 import java.lang.reflect.Method;
 import java.util.ArrayList;
+import java.util.Collection;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
@@ -43,12 +44,16 @@
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
+import org.jboss.jms.server.endpoint.Ack;
+import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.ClientDelivery;
+import org.jboss.jms.server.endpoint.DefaultAck;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
-import org.jboss.jms.tx.AckInfo;
+import org.jboss.jms.tx.ClientTransaction;
 import org.jboss.jms.tx.TransactionRequest;
-import org.jboss.jms.tx.TxState;
+import org.jboss.jms.tx.ClientTransaction.SessionTxState;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.IdBlock;
 import org.jboss.remoting.InvocationRequest;
@@ -130,11 +135,13 @@
       
       sendMethod = sessionDelegate.getMethod("send", new Class[] { JBossMessage.class });
        
-      acknowledgeMethod = sessionDelegate.getMethod("acknowledge", new Class[] { AckInfo.class });
+      acknowledgeMethod = sessionDelegate.getMethod("acknowledge", new Class[] { Ack.class });
       
       acknowledgeBatchMethod = sessionDelegate.getMethod("acknowledgeBatch", new Class[] { java.util.List.class });
       
       cancelDeliveriesMethod = sessionDelegate.getMethod("cancelDeliveries", new Class[] { java.util.List.class });
+      
+      //TODO - this isn't complete - there are other methods to test
             
       //Consumer
             
@@ -263,10 +270,8 @@
          
          mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
          
-         long messageID = 123456;
-         int consumerID = 65432;
-         int deliveryCount = 765;
-         AckInfo ack = new AckInfo(messageID, consumerID, deliveryCount);
+         int deliveryID = 765;
+         Ack ack = new DefaultAck(deliveryID);
          
          Object[] args = new Object[] { ack };
          
@@ -304,15 +309,11 @@
          //Next long should be methodHash
          assertEquals(methodHash, dis.readLong());
          
-         //Next should be the externalized AckInfo
-         AckInfo ack2 = new AckInfo();
-                  
-         ack2.read(dis);
+         //Next should be the deliveryid
+         long l = dis.readLong();
          
-         assertEquals(ack.getMessageID(), ack2.getMessageID());
-         assertEquals(ack.getConsumerID(), ack2.getConsumerID());
-         assertEquals(ack.getDeliveryCount(), ack2.getDeliveryCount());
-         
+         assertEquals(deliveryID, l);
+
          //Now eos
          try
          {
@@ -340,10 +341,9 @@
          
          assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue());
          
-         AckInfo ack3 = (AckInfo)mi2.getArguments()[0];
+         Ack l2 = (Ack)mi2.getArguments()[0];
          
-         assertEquals(ack3.getMessageID(), ack3.getMessageID());
-         assertEquals(ack3.getConsumerID(), ack3.getConsumerID());
+         assertEquals(deliveryID, l2.getDeliveryId());
          
       }
       
@@ -357,14 +357,16 @@
          
          mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
          
-         AckInfo ackA = new AckInfo(1524, 71627, 32);
-         AckInfo ackB = new AckInfo(987987, 45354, 21);
-         AckInfo ackC = new AckInfo(32423, 4533, 6);
+         long ackA = 1343;
          
+         long ackB = 176276;
+         
+         long ackC = 17261726;
+                  
          List acks = new ArrayList();
-         acks.add(ackA);
-         acks.add(ackB);
-         acks.add(ackC);
+         acks.add(new DefaultAck(ackA));
+         acks.add(new DefaultAck(ackB));
+         acks.add(new DefaultAck(ackC));
          
          Object[] args = new Object[] { acks };
          
@@ -406,31 +408,17 @@
          assertEquals(3, dis.readInt());
          
          //Now the acks
-         AckInfo ack = new AckInfo();
-            
-         ack.read(dis);
+         long l1 = dis.readLong();
          
-         assertEquals(ackA.getMessageID(), ack.getMessageID());
-         assertEquals(ackA.getConsumerID(), ack.getConsumerID());
-         assertEquals(ackA.getDeliveryCount(), ack.getDeliveryCount());
+         long l2 = dis.readLong();
          
-         ack = new AckInfo();
+         long l3 = dis.readLong();
          
-         ack.read(dis);
+         assertEquals(ackA, l1);
+         assertEquals(ackB, l2);
+         assertEquals(ackC, l3);
          
-         assertEquals(ackB.getMessageID(), ack.getMessageID());
-         assertEquals(ackB.getConsumerID(), ack.getConsumerID());
-         assertEquals(ackB.getDeliveryCount(), ack.getDeliveryCount());
          
-         ack = new AckInfo();
-         
-         ack.read(dis);
-         
-         assertEquals(ackC.getMessageID(), ack.getMessageID());
-         assertEquals(ackC.getConsumerID(), ack.getConsumerID());
-         assertEquals(ackC.getDeliveryCount(), ack.getDeliveryCount());
-         
-         
          //Now eos
          try
          {
@@ -462,14 +450,10 @@
          
          assertEquals(3, acks.size());
          
-         assertEquals(ackA.getMessageID(), ((AckInfo)(acks2.get(0))).getMessageID());
-         assertEquals(ackA.getConsumerID(), ((AckInfo)(acks2.get(0))).getConsumerID());
+         assertEquals(ackA, ((DefaultAck)acks2.get(0)).getDeliveryId());
+         assertEquals(ackB, ((DefaultAck)acks2.get(1)).getDeliveryId());
+         assertEquals(ackC, ((DefaultAck)acks2.get(2)).getDeliveryId());
          
-         assertEquals(ackB.getMessageID(), ((AckInfo)(acks2.get(1))).getMessageID());
-         assertEquals(ackB.getConsumerID(), ((AckInfo)(acks2.get(1))).getConsumerID());
-         
-         assertEquals(ackC.getMessageID(), ((AckInfo)(acks2.get(2))).getMessageID());
-         assertEquals(ackC.getConsumerID(), ((AckInfo)(acks2.get(2))).getConsumerID());
       }
       
       
@@ -739,11 +723,19 @@
          JBossMessage m = new JBossMessage(123);
          MessageTest.configureMessage(m);
          
-         AckInfo info = new AckInfo(123, 456, 66);
+         long deliveryId = 89281389;
          
-         TxState state = new TxState();
-         state.getMessages().add(m);
-         state.getAcks().add(info);
+         int deliveryCount = 12;
+         
+         MessageProxy proxy = JBossMessage.createThinDelegate(deliveryId, m, deliveryCount);
+                     
+         DeliveryInfo info = new DeliveryInfo(proxy, 76762, 98982);
+         
+         int sessionId = 8787;
+         
+         ClientTransaction state = new ClientTransaction();
+         state.addMessage(sessionId, m);
+         state.addAck(sessionId, info);
           
          TransactionRequest request = new TransactionRequest(TransactionRequest.ONE_PHASE_COMMIT_REQUEST, null, state);
                            
@@ -806,18 +798,24 @@
          {
             //Ok
          }
+         
+         ClientTransaction state2 = req.getState();
+         
+         Collection sessionStates = state2.getSessionStates();
+         
+         assertEquals(1, sessionStates.size());
+         
+         SessionTxState sess = (SessionTxState)sessionStates.iterator().next();
 
-         JBossMessage m2 = (JBossMessage)req.getState().getMessages().get(0);
+         JBossMessage m2 = (JBossMessage)sess.getMsgs().get(0);
          
          MessageTest.ensureEquivalent(m, m2);
          
          assertEquals(TransactionRequest.ONE_PHASE_COMMIT_REQUEST, req.getRequestType());
          
-         AckInfo info2 = (AckInfo)req.getState().getAcks().get(0);
+         Ack ack = (Ack)sess.getAcks().get(0);
          
-         assertEquals(info.getConsumerID(), info2.getConsumerID());
-         assertEquals(info.getMessageID(), info2.getMessageID());
-         assertEquals(info.getDeliveryCount(), info2.getDeliveryCount());
+         assertEquals(deliveryId, ack.getDeliveryId());
          
          bis.reset();
          
@@ -837,17 +835,22 @@
          
          TransactionRequest req2 = (TransactionRequest)mi2.getArguments()[0];
          
-         JBossMessage m3 = (JBossMessage)req2.getState().getMessages().get(0);
+         ClientTransaction state3 = req2.getState();
          
+         Collection sessionStates2 = state3.getSessionStates();
+         
+         SessionTxState sess2 = (SessionTxState)sessionStates2.iterator().next();
+         
+         JBossMessage m3 = (JBossMessage)sess2.getMsgs().get(0);
+         
          MessageTest.ensureEquivalent(m, m3);
          
          assertEquals(TransactionRequest.ONE_PHASE_COMMIT_REQUEST, req2.getRequestType());
          
-         AckInfo info3 = (AckInfo)req2.getState().getAcks().get(0);
+         Ack ack2 = (Ack)sess2.getAcks().get(0);
          
-         assertEquals(info.getConsumerID(), info3.getConsumerID());
-         assertEquals(info.getMessageID(), info3.getMessageID());
-                  
+         assertEquals(deliveryId, ack2.getDeliveryId());
+         
       }  
             
       
@@ -857,18 +860,18 @@
          
          int objectId = 54321;
          
-         List ids = new ArrayList();
+         List cancels = new ArrayList();
          
-         AckInfo ack1 = new AckInfo(1254, 78123, 22);
-         AckInfo ack2 = new AckInfo(786, 8979, 461);
-         ids.add(ack1);
-         ids.add(ack2);
+         Cancel cancel1 = new Cancel(65654, 43);
+         Cancel cancel2 = new Cancel(65765, 2);
+         cancels.add(cancel1);
+         cancels.add(cancel2);
          
          MethodInvocation mi = new MethodInvocation(null, methodHash, cancelDeliveriesMethod, cancelDeliveriesMethod, null);
          
          mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
          
-         mi.setArguments(new Object[] {ids});
+         mi.setArguments(new Object[] {cancels});
          
          MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi);
          
@@ -909,27 +912,22 @@
          assertEquals(2, size);
          
          //then the AckInfos
-         AckInfo rack1 = new AckInfo();
+         Cancel rcancel1 = new Cancel();
          
-         AckInfo rack2 = new AckInfo();
+         Cancel rcancel2 = new Cancel();
          
-         rack1.read(dis);
+         rcancel1.read(dis);
          
-         rack2.read(dis);
+         rcancel2.read(dis);
          
-         assertEquals(ack1.getConsumerID(), rack1.getConsumerID());
+         assertEquals(cancel1.getDeliveryCount(), rcancel1.getDeliveryCount());
          
-         assertEquals(ack1.getMessageID(), rack1.getMessageID());
+         assertEquals(cancel1.getDeliveryId(), cancel1.getDeliveryId());
          
-         assertEquals(ack1.getDeliveryCount(), rack1.getDeliveryCount());
+         assertEquals(cancel2.getDeliveryCount(), rcancel2.getDeliveryCount());
          
-         assertEquals(ack2.getConsumerID(), rack2.getConsumerID());
-         
-         assertEquals(ack2.getMessageID(), rack2.getMessageID());
-         
-         assertEquals(ack2.getDeliveryCount(), rack2.getDeliveryCount());
-         
-          
+         assertEquals(cancel2.getDeliveryId(), cancel2.getDeliveryId());
+                   
          //should be eos
                 
          try
@@ -963,16 +961,17 @@
         
          assertEquals(2, list.size());
          
-         AckInfo xack1 = (AckInfo)list.get(0);
-         AckInfo xack2 = (AckInfo)list.get(1);
+         Cancel xack1 = (Cancel)list.get(0);
+         Cancel xack2 = (Cancel)list.get(1);
          
-         assertEquals(ack1.getConsumerID(), xack1.getConsumerID());
+         assertEquals(cancel1.getDeliveryId(), xack1.getDeliveryId());
          
-         assertEquals(ack1.getMessageID(), xack1.getMessageID());
+         assertEquals(cancel1.getDeliveryCount(), xack1.getDeliveryCount());
          
-         assertEquals(ack2.getConsumerID(), xack2.getConsumerID());
+         assertEquals(cancel2.getDeliveryId(), xack2.getDeliveryId());
          
-         assertEquals(ack2.getMessageID(), xack2.getMessageID());
+         assertEquals(cancel2.getDeliveryCount(), xack2.getDeliveryCount());
+         
       }  
       
       public void testNullResponse() throws Exception
@@ -1100,17 +1099,15 @@
       {
          int consumerID = 12345678;
          
-         int serverId = 76543;
-         
          JBossMessage m1 = new JBossMessage(123);
          JBossMessage m2 = new JBossMessage(456);
          JBossMessage m3 = new JBossMessage(789);
          
          List msgs = new ArrayList();
          
-         MessageProxy del1 = JBossMessage.createThinDelegate(m1, 7);
-         MessageProxy del2 = JBossMessage.createThinDelegate(m2, 8);
-         MessageProxy del3 = JBossMessage.createThinDelegate(m3, 9);
+         MessageProxy del1 = JBossMessage.createThinDelegate(1, m1, 7);
+         MessageProxy del2 = JBossMessage.createThinDelegate(2, m2, 8);
+         MessageProxy del3 = JBossMessage.createThinDelegate(3, m3, 9);
          
          MessageTest.configureMessage(m1);
          MessageTest.configureMessage(m2);
@@ -1120,7 +1117,7 @@
          msgs.add(del2);
          msgs.add(del3);         
          
-         ClientDelivery dr = new ClientDelivery(msgs, serverId, consumerID);
+         ClientDelivery dr = new ClientDelivery(msgs, consumerID);
          
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
@@ -1149,23 +1146,21 @@
          //Next should be sessionID
          assertEquals("dummySessionId", dis.readUTF());
          
-         //Next int should be server id
-         assertEquals(76543, dis.readInt());
-         
          //Next int should be consumer id
          assertEquals(12345678, dis.readInt());
          
          //Next int should be number of messages
          assertEquals(3, dis.readInt());
-         
-         
-         
+                           
          //Next byte should be type
          assertEquals(JBossMessage.TYPE, dis.readByte());
          
          //Next int should be delivery count
          assertEquals(7, dis.readInt());
          
+         //Delivery id
+         assertEquals(1, dis.readLong());
+         
          //And now the message itself
          JBossMessage r1 = new JBossMessage();
          
@@ -1178,6 +1173,9 @@
          //Next int should be delivery count
          assertEquals(8, dis.readInt());
          
+         // Delivery id
+         assertEquals(2, dis.readLong());
+         
          //And now the message itself
          JBossMessage r2 = new JBossMessage();
          
@@ -1190,6 +1188,9 @@
          //Next int should be delivery count
          assertEquals(9, dis.readInt());
          
+         // Delivery id
+         assertEquals(3, dis.readLong());
+         
          //And now the message itself
          JBossMessage r3 = new JBossMessage();
          
@@ -1232,7 +1233,6 @@
          
          List msgs2 = dr2.getMessages();
          
-         assertEquals(serverId, dr2.getServerId());
          assertEquals(consumerID, dr2.getConsumerId());
          
          MessageProxy p1 = (MessageProxy)msgs2.get(0);

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -113,15 +113,15 @@
       
       try
       {         
-         conn1 = factory.createConnection();
+         conn1 = factory.createConnection();  //server 0
          
-         conn2 = factory.createConnection();
+         conn2 = factory.createConnection();  //server 1
          
-         conn3 = factory.createConnection();
+         conn3 = factory.createConnection();  //server 2
          
-         conn4 = factory.createConnection();
+         conn4 = factory.createConnection();  //server 0
          
-         conn5 = factory.createConnection();
+         conn5 = factory.createConnection();  //server 1
          
          ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
          
@@ -441,6 +441,8 @@
       int server1Id = cf2.getServerID();
       
       int server2Id = cf3.getServerID();
+
+      //Server order should be 2, 0, 1
       
       log.info("server 0 id: " + server0Id);
       
@@ -462,15 +464,19 @@
       
       Connection conn = null;
       
+      boolean killed =  false;
+            
       try
-      {
-      
-         //Get a connection on server 1
+      {      
+         conn = factory.createConnection(); //connection on server 2
+         
+         conn.close();
+         
          conn = factory.createConnection(); //connection on server 0
          
          conn.close();
          
-         conn = factory.createConnection(); //connection on server 1
+         conn = factory.createConnection(); // connection on server 1
          
          JBossConnection jbc = (JBossConnection)conn;
          
@@ -505,6 +511,8 @@
          
          ServerManagement.kill(1);
          
+         killed = true;
+         
          log.info("killed server, now waiting");
          
          Thread.sleep(5000);
@@ -546,8 +554,14 @@
             catch (Exception e)
             {
                e.printStackTrace();
-            }
+            }         
          }
+         
+         //Resurrect dead server
+         if (killed)
+         {
+            ServerManagement.spawn(1);
+         }
       }
       
    }
@@ -597,14 +611,15 @@
       
       Connection conn = null;
       
+      boolean killed = false;
+      
       try
       {      
-         //Get a connection on server 1
-         conn = factory.createConnection(); //connection on server 0
+         conn = factory.createConnection(); //connection on server 1
          
          conn.close();
          
-         conn = factory.createConnection(); //connection on server 1
+         conn = factory.createConnection(); //connection on server 2
          
          JBossConnection jbc = (JBossConnection)conn;
          
@@ -614,7 +629,7 @@
          
          int initialServerID = state.getServerID();
          
-         assertEquals(1, initialServerID);
+         assertEquals(2, initialServerID);
                            
          Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
          
@@ -653,9 +668,11 @@
          
          ServerManagement.kill(1);
          
+         killed = true;
+         
          log.info("killed server, now waiting");
          
-         Thread.sleep(5000);
+         Thread.sleep(10000);
          
          log.info("done wait");
          
@@ -720,6 +737,12 @@
                e.printStackTrace();
             }
          }
+         
+         // Resurrect dead server
+         if (killed)
+         {
+            ServerManagement.spawn(1);
+         }
       }
       
    }
@@ -768,6 +791,8 @@
       
       Connection conn = null;
       
+      boolean killed = false;
+      
       try
       {      
          //Get a connection on server 1
@@ -825,6 +850,8 @@
          log.info("************ KILLING (CRASHING) SERVER 1");
          
          ServerManagement.kill(1);
+         
+         killed = true;
 
          log.info("killed server, now waiting");
          
@@ -893,51 +920,16 @@
                e.printStackTrace();
             }
          }
+         
+         if (killed)
+         {
+            ServerManagement.spawn(1);
+         }
       }
       
    }
    
    
-   
-   
-//   public void testEvenSimplerFailover() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-//                  
-//      Connection conn = null;
-//      
-//      try
-//      {
-//         conn = factory.createConnection();
-//                           
-//         log.info("************ KILLING (CRASHING) SERVER 0");
-//         
-//         ServerManagement.getServer(0).destroy();
-//         
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(25000);
-//         
-//         log.info("done wait");                
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//      }
-//      
-//   }
-   
-   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jboss/MBeanConfigurationElement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jboss/MBeanConfigurationElement.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jboss/MBeanConfigurationElement.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -11,6 +11,8 @@
 import org.w3c.dom.Element;
 import org.w3c.dom.NodeList;
 import org.jboss.jms.util.XMLUtil;
+import org.jboss.logging.Logger;
+import org.jboss.test.messaging.tools.jmx.rmi.LocalTestServer;
 
 import javax.management.ObjectName;
 import java.util.Map;
@@ -30,7 +32,10 @@
 public class MBeanConfigurationElement
  {
    // Constants -----------------------------------------------------
+   
+   private static final Logger log = Logger.getLogger(MBeanConfigurationElement.class);
 
+
    // Static --------------------------------------------------------
 
    public static Class stringToClass(String type) throws Exception
@@ -82,6 +87,8 @@
 
       Node mbeanNameAttr = attrs.getNamedItem("name");
       on = new ObjectName(mbeanNameAttr.getNodeValue());
+      
+      log.trace("ObjectName is: " + on);
 
       Node mbeanCodeAttr = attrs.getNamedItem("code");
       className = mbeanCodeAttr.getNodeValue();

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-14 16:02:46 UTC (rev 1793)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-14 19:32:42 UTC (rev 1794)
@@ -728,6 +728,8 @@
                                        int defaultTempQueuePageSize,
                                        int defaultTempQueueDownCacheSize) throws Exception
    {
+      log.trace("deploying connection factory with name: " + objectName);
+      
       String config =
          "<mbean code=\"org.jboss.jms.server.connectionfactory.ConnectionFactory\"\n" +
                 "name=\"" + objectName + "\"\n" +
@@ -766,6 +768,9 @@
 
       MBeanConfigurationElement mc = new MBeanConfigurationElement(XMLUtil.stringToElement(config));
       ObjectName on = sc.registerAndConfigureService(mc);
+      
+      log.trace("Object name is now: " + on);
+      
       sc.invoke(on, "create", new Object[0], new String[0]);
       sc.invoke(on, "start", new Object[0], new String[0]);
    }



From gavin.king at jboss.com  Thu Dec 14 14:33:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 14:33:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/glassfish  ...
Message-ID: <E1GuwKk-0001zA-0q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 14:33:34

  Modified:    examples/hibernate2/resources/glassfish  components.xml
  Log:
  fix validation
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/examples/hibernate2/resources/glassfish/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/glassfish/components.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- components.xml	12 Dec 2006 07:42:59 -0000	1.2
  +++ components.xml	14 Dec 2006 19:33:33 -0000	1.3
  @@ -18,7 +18,7 @@
       <core:hibernate-session-factory name="hibernateSessionFactory"/>
       
       <core:managed-hibernate-session name="bookingDatabase"
  -                          sessionFactoryJndiName="bookingDatabase"/>
  +                          session-factory-jndi-name="bookingDatabase"/>
       
   </components>
   
  
  
  


From gavin.king at jboss.com  Thu Dec 14 14:33:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 14:33:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/hibernate2/resources/weblogic  ...
Message-ID: <E1GuwKk-0001zH-4P@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 14:33:34

  Modified:    examples/hibernate2/resources/weblogic  components.xml
  Log:
  fix validation
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/examples/hibernate2/resources/weblogic/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/hibernate2/resources/weblogic/components.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- components.xml	12 Dec 2006 07:42:59 -0000	1.2
  +++ components.xml	14 Dec 2006 19:33:34 -0000	1.3
  @@ -18,7 +18,7 @@
       <core:hibernate-session-factory name="hibernateSessionFactory"/>
       
       <core:managed-hibernate-session name="bookingDatabase"
  -                          sessionFactoryJndiName="bookingDatabase"/>
  +                          session-factory-jndi-name="bookingDatabase"/>
       
   </components>
   
  
  
  


From rawblem at gmail.com  Thu Dec 14 14:34:44 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 14 Dec 2006 14:34:44 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui
	...
Message-ID: <E1GuwLs-0001zk-AC@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/14 14:34:44

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui 
                        Messages.properties
  Log:
  flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;) 
  
  Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)
  
  Revision  Changes    Path
  1.15      +1 -38     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/Messages.properties
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Messages.properties
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/Messages.properties,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- Messages.properties	14 Nov 2006 19:45:15 -0000	1.14
  +++ Messages.properties	14 Dec 2006 19:34:44 -0000	1.15
  @@ -130,48 +130,11 @@
   	UpgradeWizardLaunchRuntimeNamesInUse=The following runtime names are already in use: 
   	UpgradeWizardLaunchServerNamesInUse=The following server names are already in use:
   
  -# Clone server wizard
  -CloneWizardRequiredCheckedLabel=Files required for a successful minimal configuration cannot be unchecked.
  -CloneWizardNewServerName=New Server Name: 
  -CloneWizardNewConfigName=New Configuration Name: 
  -CloneWizardTitle=Create a new Server Configuration
  -CloneWizardDescription=Create a new server configuration directory containing the selected files. \nA new server object will be added to the list of JBoss Servers.
  -CloneWizardServerNameInUse=Server name already in use: 
  -CloneWizardConfigNameInUse=Configuration already exists: 
  -CloneWizardWindowTitle=Clone a Server
  -
  -#Mbean wizard
  -NewMBeanInterface=New MBean Interface
  -NewMBeanInterfaceDesc=Create the interface for the MBean
  -NewMBeanName=MBean Name
  -NewMBeanInterfaceName=Interface Name
  -NewMBeanClass=New MBean Class
  -MBeanClassDescription=Create the concrete MBean Class
  -MBeanServiceXML=Create -service.xml file?
  -
   
   ###########################################
   ############## view providers
   ###########################################
   
  -#Event Log
  -EventLogStartingServer=Starting Server
  -EventLogStoppingServer=Stopping Server
  -EventLogServerUp=Server is up.
  -EventLogServerDown=Server is down.
  -EventLogTwiddleLaunchServerStatePrefix=Twiddle Launch: Server is 
  -EventLogStillStopping=still stopping
  -EventLogStillStarting=still starting
  -EventLogUp=up
  -EventLogDown=down
  -EventLogServerActionCanceled=Server action canceled.
  -EventLogTimeoutReached=Server Timeout Reached.
  -EventLogConsoleOutput=Console Output
  -EventLogPublishEvent=Publish Event
  -EventLogPublishingToServer=Publishing module to server: 
  -EventLogPublishRemoveFromServer=Removing module from server: 
  -EventLogPublishUnknownEvent=Unknown Publish Event
  -EventLogUnknownEvent=Unknown Event
   
   #Inactive Categories
   InactiveCategoriesReEnable=Re-enable Category
  @@ -182,7 +145,7 @@
   DescriptorXPathNewXPath=New XPath
   DescriptorXPathEditXPath=Edit XPath
   DescriptorXPathDeleteXPath=Delete XPath
  -DescriptorXPathAttributeValue=Attribute Value
  +DescriptorXPathAttributeValue=Value
   DescriptorXPathXPathXML=XPath / XML
   DescriptorXPathAttributeKeyValue=Attribute Key / Value
   DescriptorXPathDescriptorValues=Descriptor Values
  
  
  


From rawblem at gmail.com  Thu Dec 14 14:34:44 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 14 Dec 2006 14:34:44 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers
	...
Message-ID: <E1GuwLs-0001zx-Ep@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/14 14:34:44

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers   
                        InactiveExtensionViewProvider.java
                        DescriptorXPathViewProvider.java
                        FilesetViewProvider.java
  Log:
  flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;) 
  
  Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)
  
  Revision  Changes    Path
  1.2       +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/InactiveExtensionViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InactiveExtensionViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/InactiveExtensionViewProvider.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- InactiveExtensionViewProvider.java	10 Nov 2006 00:30:21 -0000	1.1
  +++ InactiveExtensionViewProvider.java	14 Dec 2006 19:34:44 -0000	1.2
  @@ -119,7 +119,7 @@
   									inputChanged(JBossServerView.getDefault().getJBViewer(), null, JBossServerView.getDefault().getSelectedServer());
   								
   								try {
  -									JBossServerView.getDefault().refreshJBTree(null);
  +									JBossServerView.getDefault().getJBViewer().refresh();
   								} catch(Exception e) {
   								}
   							}
  
  
  
  1.5       +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DescriptorXPathViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- DescriptorXPathViewProvider.java	4 Dec 2006 17:46:39 -0000	1.4
  +++ DescriptorXPathViewProvider.java	14 Dec 2006 19:34:44 -0000	1.5
  @@ -1013,7 +1013,7 @@
   	protected void refreshViewer() {
   		if( isEnabled() ) {
   			try {
  -				JBossServerView.getDefault().refreshJBTree(provider);
  +				refreshViewer();
   				if( propertyPage != null ) {
   					propertyPage.xpathTreeViewer.refresh();
   				}
  
  
  
  1.2       +43 -33    jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FilesetViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- FilesetViewProvider.java	13 Dec 2006 18:32:51 -0000	1.1
  +++ FilesetViewProvider.java	14 Dec 2006 19:34:44 -0000	1.2
  @@ -50,6 +50,7 @@
   import org.eclipse.wst.server.core.IServer;
   import org.jboss.ide.eclipse.as.core.server.JBossServer;
   import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper;
  +import org.jboss.ide.eclipse.as.ui.views.server.JBossServerView;
   import org.jboss.ide.eclipse.as.ui.views.server.extensions.ServerViewProvider;
   import org.jboss.ide.eclipse.as.ui.views.server.extensions.SimplePropertiesViewExtension;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  @@ -82,7 +83,8 @@
   					System.arraycopy(filesets, 0, filesetsNew, 0, filesets.length);
   					filesetsNew[filesetsNew.length-1] = fs;
   					filesets = filesetsNew;
  -					saveFilesets();
  +					saveFilesets(true);
  +					refreshViewer();
   				}
   			}
   		};
  @@ -94,7 +96,8 @@
   						ArrayList asList = new ArrayList(Arrays.asList(filesets));
   						asList.remove(selection);
   						filesets = (Fileset[]) asList.toArray(new Fileset[asList.size()]);
  -						saveFilesets();
  +						saveFilesets(true);
  +						removeElement(selection);
   					} catch( Exception e ) {
   						e.printStackTrace();
   					}
  @@ -112,7 +115,8 @@
   					sel.setFolder(ret.getFolder());
   					sel.setIncludesPattern(ret.getIncludesPattern());
   					sel.setExcludesPattern(ret.getExcludesPattern());
  -					saveFilesets();
  +					saveFilesets(true);
  +					refreshViewer(sel);
   				}
   			}
   		};
  @@ -123,6 +127,7 @@
   					PathWrapper wrapper = (PathWrapper)selection;
   					File file = wrapper.getPath().toFile();
   					file.delete();
  +					refreshViewer();
   				} catch( Exception e ) {
   				}
   			}
  @@ -230,7 +235,9 @@
   		}
   	}
   	
  -	public void saveFilesets() {
  +	public void saveFilesets(boolean suppressRefresh) {
  +		Runnable r = new Runnable() {
  +			public void run() {
   		IServer server = contentProvider.server;
   		if( server != null ) {
   			ArrayList list = new ArrayList();
  @@ -243,6 +250,14 @@
   			helper.save();
   		}
   	}
  +		};
  +
  +		if( suppressRefresh ) {
  +			suppressingRefresh(r);
  +		} else {
  +			r.run();
  +		}
  +	}
   
   	public class Fileset implements Cloneable {
   		private String name, folder, includesPattern, excludesPattern;
  @@ -327,6 +342,17 @@
   			} catch( Exception e ) {}
   			return null;
   		}
  +		
  +		public boolean equals(Object other) {
  +			if( !(other instanceof Fileset)) return false;
  +			if( other == this ) return true;
  +			Fileset o = (Fileset)other;
  +			return o.getName().equals(getName()) && o.getFolder().equals(getFolder()) 
  +				&& o.getIncludesPattern().equals(getIncludesPattern()) && o.getExcludesPattern().equals(getExcludesPattern());
  +		}
  +		public int hashCode() {
  +			return (name + "::_::" +  folder + "::_::" +  includesPattern + "::_::" +  excludesPattern + "::_::").hashCode();
  +		}
   	}
   	
   	public class FilesetLabelProvider extends LabelProvider {
  @@ -349,22 +375,6 @@
   		        }
   		        return image;
   	    	}
  -//	    	if( element instanceof Path ) {
  -//	    		((Path)element).
  -//	    		
  -//	    	}
  -//			if (resource instanceof IFile) {
  -//				contentType = IDE.guessContentType((IFile)resource);
  -//			}
  -//	        // @issue move IDE specific images
  -//	        ImageDescriptor image = PlatformUI.getWorkbench().getEditorRegistry()
  -//	                .getImageDescriptor(resource.getName(), contentType);
  -//	        if (image == null) {
  -//				image = PlatformUI.getWorkbench().getSharedImages()
  -//	                    .getImageDescriptor(ISharedImages.IMG_OBJ_FILE);
  -//			}
  -//	        return image;
  -
   	        return null;
   	    }
   
  @@ -478,26 +488,26 @@
   		}
   		protected void fillArea(Composite main) {
   			Label nameLabel = new Label(main, SWT.NONE);
  -			nameLabel.setText("Name");
  +			nameLabel.setText("Name: ");
   			
   			nameText = new Text(main, SWT.BORDER);
   			nameText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 2, 1));
   			
   			Label folderLabel = new Label(main, SWT.NONE);
  -			folderLabel.setText("Folder");
  +			folderLabel.setText("Root Directory: ");
   			
   			folderText = new Text(main, SWT.BORDER);
   			browse = new Button(main, SWT.PUSH);
   			browse.setText("Browse...");
   			
   			Label includesLabel = new Label(main, SWT.NONE);
  -			includesLabel.setText("Include Pattern");
  +			includesLabel.setText("Includes: ");
   			
   			includesText = new Text(main, SWT.BORDER);
   			includesText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 2, 1));
   			
   			Label excludeLabel= new Label(main, SWT.NONE);
  -			excludeLabel.setText("Exclude Pattern");
  +			excludeLabel.setText("Excludes: ");
   			
   			excludesText = new Text(main, SWT.BORDER);
   			excludesText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 2, 1));
  
  
  


From rawblem at gmail.com  Thu Dec 14 14:34:44 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 14 Dec 2006 14:34:44 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs
	...
Message-ID: <E1GuwLs-000204-If@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/14 14:34:44

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs 
                        ConvertNodeToXPathDialog.java
  Log:
  flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;) 
  
  Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)
  
  Revision  Changes    Path
  1.2       +57 -10    jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/ConvertNodeToXPathDialog.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConvertNodeToXPathDialog.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/ConvertNodeToXPathDialog.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ConvertNodeToXPathDialog.java	4 Dec 2006 17:45:30 -0000	1.1
  +++ ConvertNodeToXPathDialog.java	14 Dec 2006 19:34:44 -0000	1.2
  @@ -23,12 +23,16 @@
   
   import java.util.ArrayList;
   
  +import org.eclipse.jface.action.Action;
  +import org.eclipse.jface.action.IMenuManager;
   import org.eclipse.jface.text.DocumentEvent;
   import org.eclipse.jface.text.IDocument;
   import org.eclipse.jface.text.ITextViewer;
   import org.eclipse.jface.text.contentassist.ICompletionProposal;
   import org.eclipse.jface.text.contentassist.ICompletionProposalExtension2;
   import org.eclipse.jface.text.contentassist.IContextInformation;
  +import org.eclipse.jface.viewers.ISelection;
  +import org.eclipse.jface.viewers.IStructuredSelection;
   import org.eclipse.jface.window.Window;
   import org.eclipse.swt.SWT;
   import org.eclipse.swt.events.SelectionEvent;
  @@ -57,6 +61,7 @@
   import org.jboss.ide.eclipse.as.core.util.SimpleTreeItem;
   import org.jboss.ide.eclipse.as.ui.Messages;
   import org.jboss.ide.eclipse.as.ui.dialogs.XPathDialogs.XPathDialog;
  +import org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals.IServiceXMLOutlineActionProvider;
   import org.jboss.ide.eclipse.as.ui.mbeans.editors.proposals.IServiceXMLQuickFixProposalProvider;
   import org.jboss.ide.eclipse.as.ui.views.server.JBossServerView;
   import org.w3c.dom.NamedNodeMap;
  @@ -304,6 +309,31 @@
   		}
   
   		public void apply(ITextViewer viewer, char trigger, int stateMask, int offset) {
  +			new ConvertNodeRunnable(node, attributeName).run();
  +		}
  +
  +		public void selected(ITextViewer viewer, boolean smartToggle) {
  +		}
  +
  +		public void unselected(ITextViewer viewer) {
  +		}
  +
  +		public boolean validate(IDocument document, int offset, DocumentEvent event) {
  +			return false;
  +		}
  +		
  +	}
  +	
  +	public static class ConvertNodeRunnable implements Runnable {
  +
  +		private String attributeName;
  +		private Node node;
  +		public ConvertNodeRunnable(Node n, String att) {
  +			attributeName = att;
  +			node = n;
  +		}
  +		
  +		public void run() {
   			ConvertNodeToXPathDialog d = new ConvertNodeToXPathDialog(new Shell(), node, attributeName);
   			int result = d.open();
   			if( result == Window.OK) {
  @@ -326,20 +356,37 @@
   				ServerAttributeHelper helper = s.getAttributeHelper();
   				helper.saveXPathPreferenceTree(tree);
   				helper.save();
  -				JBossServerView.getDefault().refreshJBTree(null);
   			}
   		}
   
  -		public void selected(ITextViewer viewer, boolean smartToggle) {
   		}
   
  -		public void unselected(ITextViewer viewer) {
  +	public static class ConvertNodeToXPathDialogOutlineMenuItemProvider implements IServiceXMLOutlineActionProvider {
  +		public void release() {
   		}
   
  -		public boolean validate(IDocument document, int offset, DocumentEvent event) {
  -			return false;
  +		public void menuAboutToShow(IMenuManager manager, ISelection selection) {
  +			Object o = ((IStructuredSelection)selection).getFirstElement();
  +			Node n;
  +			String attName = null;
  +			if( o instanceof Node ) {
  +				n = (Node)o;
  +				if( n instanceof AttrImpl) {
  +					attName = ((AttrImpl)n).getName();
  +					n = ((AttrImpl)n).getOwnerElement();
  +				}
  +				final Node n2 = n;
  +				final String attName2 = attName;
  +				Action temp = new Action() { 
  +					public void run() {
  +						new ConvertNodeRunnable(n2, attName2).run();
  +					}
  +				};
  +				temp.setText("Add to XPaths");
  +				temp.setDescription("Add this element to the list of xpaths you can edit from the properties view.");
  +				manager.add(temp);
  +				System.out.println(o);
  +			}
   		}
  -		
   	}
  -	
   }
  
  
  


From rawblem at gmail.com  Thu Dec 14 14:34:44 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 14 Dec 2006 14:34:44 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/preferencepages
	...
Message-ID: <E1GuwLs-00020B-NK@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/14 14:34:44

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/preferencepages 
                        ViewPreferencePage.java
  Log:
  flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;) 
  
  Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)
  
  Revision  Changes    Path
  1.8       +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/preferencepages/ViewPreferencePage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ViewPreferencePage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/preferencepages/ViewPreferencePage.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ViewPreferencePage.java	17 Nov 2006 18:57:05 -0000	1.7
  +++ ViewPreferencePage.java	14 Dec 2006 19:34:44 -0000	1.8
  @@ -117,7 +117,7 @@
   		}
       	
   		// refresh the viewer
  -		JBossServerView.getDefault().refreshJBTree(null);
  +		JBossServerView.getDefault().getJBViewer().refresh();
       	
           return retval;
       }
  
  
  


From rawblem at gmail.com  Thu Dec 14 14:34:44 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 14 Dec 2006 14:34:44 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions
	...
Message-ID: <E1GuwLs-00020I-RI@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/14 14:34:44

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions 
                        JBossServerViewExtension.java
  Log:
  flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;) 
  
  Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)
  
  Revision  Changes    Path
  1.4       +12 -2     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerViewExtension.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- JBossServerViewExtension.java	13 Dec 2006 18:32:13 -0000	1.3
  +++ JBossServerViewExtension.java	14 Dec 2006 19:34:44 -0000	1.4
  @@ -66,6 +66,10 @@
   		return null;
   	}
   	
  +	protected void suppressingRefresh(Runnable runnable) {
  +		JBossServerView.getDefault().getJBViewer().suppressingRefresh(runnable);
  +	}
  +	
   	protected void refreshViewer() {
   		refreshViewer(null);
   	}
  @@ -73,11 +77,17 @@
   		if( isEnabled() ) {
   			try {
   				if( o == null )
  -					JBossServerView.getDefault().refreshJBTree(provider);
  +					JBossServerView.getDefault().getJBViewer().refresh(provider);
   				else
  -					JBossServerView.getDefault().refreshJBTree(new ContentWrapper(o, provider));
  +					JBossServerView.getDefault().getJBViewer().refresh(new ContentWrapper(o, provider));
   			} catch(Exception e) {
   			}
   		}
   	}
  +	protected void removeElement(Object o) {
  +		JBossServerView.getDefault().getJBViewer().remove(new ContentWrapper(o, provider));
  +	}
  +	protected void addElement(Object parent, Object child) {
  +		JBossServerView.getDefault().getJBViewer().add(new ContentWrapper(parent, provider), new ContentWrapper(child, provider));
  +	}
   }
  
  
  


From rawblem at gmail.com  Thu Dec 14 14:34:44 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 14 Dec 2006 14:34:44 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server
	...
Message-ID: <E1GuwLs-00020V-VO@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/14 14:34:44

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server   
                        ServerTableViewer.java JBossServerView.java
                        JBossServerTableViewer.java
  Log:
  flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;) 
  
  Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)
  
  Revision  Changes    Path
  1.5       +2 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ServerTableViewer.java	6 Dec 2006 17:14:36 -0000	1.4
  +++ ServerTableViewer.java	14 Dec 2006 19:34:44 -0000	1.5
  @@ -262,6 +262,8 @@
   			public void run() {
   				try {
   					refresh(server);
  +					
  +					// This ensures the icons are updated in case of a publish or state change
   					ISelection sel = ServerTableViewer.this.getSelection();
   					ServerTableViewer.this.setSelection(sel);
   				} catch (Exception e) {
  
  
  
  1.5       +8 -41     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerView.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerView.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- JBossServerView.java	28 Nov 2006 17:32:51 -0000	1.4
  +++ JBossServerView.java	14 Dec 2006 19:34:44 -0000	1.5
  @@ -3,6 +3,7 @@
   import java.util.ArrayList;
   import java.util.Arrays;
   
  +import org.eclipse.core.internal.refresh.RefreshJob;
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.debug.core.ILaunchConfiguration;
   import org.eclipse.debug.ui.DebugUITools;
  @@ -56,6 +57,8 @@
   	protected Action  refreshViewerAction, editLaunchConfigAction, twiddleAction, cloneServerAction;
   
   	
  +	private boolean suppressingRefresh = false;
  +	
   	
   	public static JBossServerView instance;
   	public static JBossServerView getDefault() {
  @@ -105,7 +108,7 @@
   			public void run() {
   				Display.getDefault().asyncExec(new Runnable() {
   					public void run() {
  -						refresh();
  +						getJBViewer().refresh(null);
   					} 
   				});
   			}
  @@ -209,9 +212,6 @@
   	}
   	
   	
  -	protected void refresh() {
  -		tableViewer.refresh(); // should auto-refresh the other
  -	}
   	// for superclass, for the top viewer
   	protected void fillContextMenu(Shell shell, IMenuManager menu) {
   		menu.add(newServerAction);
  @@ -246,28 +246,6 @@
   		return (IServer)jbViewer.getInput();
   	}
   	
  -	public void refreshJBTree(Object obj) {
  -		final Object obj2 = obj;
  -		Display.getDefault().asyncExec(new Runnable() {
  -			public void run() {
  -				try {
  -					// If it's null, refresh the whole thing
  -					if( obj2 == null ) { 
  -//						Object[] expanded = JBossServerView.this.jbViewer.getExpandedElements();
  -						JBossServerView.this.jbViewer.refresh();
  -//						JBossServerView.this.jbViewer.setExpandedElements(expanded);
  -					} else {
  -//						Object[] expanded = JBossServerView.this.jbViewer.getExpandedElements();
  -						JBossServerView.this.jbViewer.refresh(obj2);
  -//						JBossServerView.this.jbViewer.setExpandedElements(expanded);
  -					}
  -				} catch (Exception e) {
  -					// ignore
  -				}
  -			}
  -		});
  -	}
  -	
   	public void addListeners() {
   		
   		/*
  @@ -276,7 +254,6 @@
   		
   		tableViewer.addSelectionChangedListener(new ISelectionChangedListener() {
   			public void selectionChanged(SelectionChangedEvent event) {
  -				Object current = jbViewer.getInput();
   				Object selection = ((TreeSelection)event.getSelection()).getFirstElement();
   				Object server = selection;
   				if( selection instanceof ModuleServer ) {
  @@ -284,22 +261,12 @@
   				}
   
   				if( selection == null ) return;
  -				
   				if( server != jbViewer.getInput()) {
   					jbViewer.setInput(server);
  -					jbViewer.expandToLevel(2);
   				} else {
  -					// This is entirely too cludgy but it works
  -					ISelection sel = jbViewer.getSelection();
  -					Object[] expanded = jbViewer.getExpandedElements();
  -					jbViewer.setInput(server);
  -//					jbViewer.expandToLevel(2);
  -					Object[] alsoExpanded = jbViewer.getExpandedElements();
  -					ArrayList tmp = new ArrayList();
  -					tmp.addAll(Arrays.asList(expanded));
  -					tmp.addAll(Arrays.asList(alsoExpanded));
  -					jbViewer.setExpandedElements(tmp.toArray());
  -					jbViewer.setSelection(sel);
  +//					Object[] expanded = jbViewer.getExpandedElements();
  +//					jbViewer.setInput(server);
  +//					jbViewer.setExpandedElements(expanded);
   				}
   			} 
   			
  
  
  
  1.4       +18 -3     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- JBossServerTableViewer.java	13 Dec 2006 21:48:53 -0000	1.3
  +++ JBossServerTableViewer.java	14 Dec 2006 19:34:44 -0000	1.4
  @@ -45,8 +45,8 @@
   public class JBossServerTableViewer extends TreeViewer {
   
   	protected TableViewerPropertySheet propertySheet;
  -	
   	protected Action disableCategoryAction, refreshAction;
  +	protected boolean suppressingRefresh = false;
   	public JBossServerTableViewer(Tree tree) {
   		super(tree);
   		setContentProvider(new ContentProviderDelegator());
  @@ -94,9 +94,9 @@
   			public void run() {
   				Object el = getSelectedElement();
   				if( el instanceof ServerViewProvider ) 
  -					JBossServerView.getDefault().refreshJBTree(el);
  +					refresh(el);
   				else 
  -					JBossServerView.getDefault().refreshJBTree(((IStructuredSelection)getSelection()).getFirstElement());
  +					refresh(((IStructuredSelection)getSelection()).getFirstElement());
   			}
   		};
   		refreshAction.setText("Refresh Item");
  @@ -403,4 +403,19 @@
   		}
   	}
   	
  +	
  +	public void suppressingRefresh(Runnable runnable) {
  +		boolean currentVal = suppressingRefresh;
  +		suppressingRefresh = true;
  +		runnable.run();
  +		suppressingRefresh = currentVal;
  +	}
  +
  +	// for testing
  +	public void refresh(final Object element) {
  +		System.out.println("here: " + element);
  +		super.refresh(element);
  +	}
  +	
  +
   }
  
  
  


From gavin.king at jboss.com  Thu Dec 14 14:39:12 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 14:39:12 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules    ...
Message-ID: <E1GuwQC-00027C-Ng@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 14:39:12

  Modified:    doc/reference/en/modules    components.xml concepts.xml
                        framework.xml
  Log:
  fix probs in doc
  
  Revision  Changes    Path
  1.51      +1 -1      jboss-seam/doc/reference/en/modules/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/components.xml,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -b -r1.50 -r1.51
  --- components.xml	20 Nov 2006 20:14:27 -0000	1.50
  +++ components.xml	14 Dec 2006 19:39:12 -0000	1.51
  @@ -1310,7 +1310,7 @@
                       <itemizedlist>
                           <listitem>
                           <para>
  -                            <literal>org.jboss.seam.core.hibernate.cfgResourceName</literal> &mdash; 
  +                            <literal>&lt;sessionFactory&gt;.cfgResourceName</literal> &mdash; 
                               the path to the configuration file. Default to <literal>hibernate.cfg.xml</literal>.
                           </para>
                           </listitem>
  
  
  
  1.47      +2 -2      jboss-seam/doc/reference/en/modules/concepts.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: concepts.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/concepts.xml,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -b -r1.46 -r1.47
  --- concepts.xml	13 Dec 2006 11:07:05 -0000	1.46
  +++ concepts.xml	14 Dec 2006 19:39:12 -0000	1.47
  @@ -593,8 +593,8 @@
               </para>
               <para> 
                   Or, if you're not quite ready for the Brave New World of EJB 3.0, you can write a Seam application
  -                that uses only JavaBean components, together with Hibernate3 for persistence, by installing the built-in
  -                component <literal>org.jboss.seam.core.hibernate</literal>. When using Hibernate outside of a J2EE
  +                that uses only JavaBean components, together with Hibernate3 for persistence, by installing a built-in
  +                component that manages a Hibernate <literal>SessionFactory</literal>. When using Hibernate outside of a J2EE
                   environment, you will also probably need a JTA transaction manager and JNDI server, which are available
                   via the built-in component <literal>org.jboss.seam.core.microcontainer</literal>. This lets you use the
                   bulletproof JTA/JCA pooling datasource from JBoss application server in an SE environment like Tomcat!
  
  
  
  1.13      +21 -11    jboss-seam/doc/reference/en/modules/framework.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: framework.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/framework.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- framework.xml	14 Dec 2006 07:19:04 -0000	1.12
  +++ framework.xml	14 Dec 2006 19:39:12 -0000	1.13
  @@ -40,7 +40,9 @@
               <literal>Contact</literal> entity:
           </para>
           
  -        <programlisting><![CDATA[<framework:entity-home name="personHome" entity-class="eg.Person" entity-manager="#{personDatabase}">
  +        <programlisting><![CDATA[<framework:entity-home name="personHome" 
  +                       entity-class="eg.Person" 
  +                       entity-manager="#{personDatabase}">
       <framework:id>#{param.personId}</framework:id>
   </framework:entity-home>]]></programlisting>
   
  @@ -52,7 +54,7 @@
           <programlisting><![CDATA[@Stateful
   @Name("personHome")
   public class PersonHome extends EntityHome<Person> implements LocalPersonHome {
  -    @RequestParameter Long personId;
  +    @RequestParameter String personId;
       @In EntityManager personDatabase;
       
       public Object getId() { return personId; }
  @@ -155,9 +157,11 @@
               line to <literal>components.xml</literal>:
           </para>
           
  -        <programlisting><![CDATA[<factory name="person" value="#{personHome.instance}"/>
  +        <programlisting><![CDATA[<factory name="person" 
  +         value="#{personHome.instance}"/>
   
  -<framework:entity-home name="personHome" entity-class="eg.Person" />]]></programlisting>
  +<framework:entity-home name="personHome" 
  +                       entity-class="eg.Person" />]]></programlisting>
   
           <para>
               (If we are using configuration.)
  @@ -231,11 +235,15 @@
               nationality initialized. We can do that easily, via configuration:
           </para>
   
  -        <programlisting><![CDATA[<factory name="person" value="#{personHome.instance}"/>
  +        <programlisting><![CDATA[<factory name="person" 
  +         value="#{personHome.instance}"/>
   
  -<framework:entity-home name="personHome" entity-class="eg.Person" new-instance="#{newPerson}"/>
  +<framework:entity-home name="personHome" 
  +                       entity-class="eg.Person" 
  +                       new-instance="#{newPerson}"/>
   
  -<component name="newPerson" class="eg.Person">
  +<component name="newPerson" 
  +           class="eg.Person">
       <property name="nationality">#{country}</property>
   </component>]]></programlisting>
            
  @@ -292,7 +300,8 @@
               successful. To customize these messages we can, again, use configuration:
           </para>
            
  -        <programlisting><![CDATA[<factory name="person" value="#{personHome.instance}"/>
  +        <programlisting><![CDATA[<factory name="person" 
  +         value="#{personHome.instance}"/>
   
   <framework:entity-home name="personHome"
           entity-class="eg.Person"
  @@ -302,7 +311,8 @@
       <framework:updated-message>Person #{person.firstName} #{person.lastName} updated</framework:updated-message>
   </framework:entity-home>
   
  -<component name="newPerson" class="eg.Person">
  +<component name="newPerson" 
  +           class="eg.Person">
       <property name="nationality">#{country}</property>
   </component>]]></programlisting>
            
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 15:56:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 15:56:46 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1795 - in trunk:
	src/main/org/jboss/jms/server/connectionfactory
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GuxdG-0003fK-J4@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-14 15:56:41 -0500 (Thu, 14 Dec 2006)
New Revision: 1795

Modified:
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Now order cf array in server id order



Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-14 19:32:42 UTC (rev 1794)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-14 20:56:41 UTC (rev 1795)
@@ -22,6 +22,10 @@
 package org.jboss.jms.server.connectionfactory;
 
 import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Comparator;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
@@ -329,9 +333,11 @@
                throw new IllegalStateException("Cannot find cf with name " + uniqueName);
             }
             
+            List newDels = sortCFS(updatedReplicantMap.values());
+            
             ClientConnectionFactoryDelegate[] delArr = 
-               (ClientConnectionFactoryDelegate[])updatedReplicantMap.values().
-                  toArray(new ClientConnectionFactoryDelegate[updatedReplicantMap.size()]);
+               (ClientConnectionFactoryDelegate[])newDels.
+                  toArray(new ClientConnectionFactoryDelegate[newDels.size()]);
 
             del.setDelegates(delArr);
             
@@ -381,7 +387,7 @@
    {     
       FailoverMapper mapper = replicator.getFailoverMapper();
       failoverMap = mapper.generateMapping(nodeAddressMap.keySet());
-   }
+   }      
    
    /**
     * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
@@ -390,9 +396,23 @@
       throws Exception
    {
       if (trace) { log.trace(this + " updating failover delegates, map size " + localDelegates.size()); }
+      
+      //First sort the local delegates in order of server id
+      List localDels = sortCFS(localDelegates.values());
+      
+      Collections.sort(localDels,
+                       new Comparator()
+                       {
+                           public int compare(Object obj1, Object obj2)
+                           {
+                              ClientConnectionFactoryDelegate del1 = (ClientConnectionFactoryDelegate)obj1;
+                              ClientConnectionFactoryDelegate del2 = (ClientConnectionFactoryDelegate)obj2;
+                              return del1.getServerID() - del2.getServerID();
+                           } 
+                       });
 
       ClientConnectionFactoryDelegate[] delArr = 
-         (ClientConnectionFactoryDelegate[])localDelegates.values().
+         (ClientConnectionFactoryDelegate[])localDels.
             toArray(new ClientConnectionFactoryDelegate[localDelegates.size()]);
 
       // If the map is not cached - generate it now
@@ -418,20 +438,20 @@
 
       ClientConnectionFactoryDelegate mainDelegate = null;
       
-      for(Iterator i = localDelegates.values().iterator(); i.hasNext();)
+      for(Iterator i = localDels.iterator(); i.hasNext();)
       {
          ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)i.next();
-            
-          if (del.getServerID() == this.serverPeer.getServerPeerID())
-          {
-             // sanity check
-             if (mainDelegate != null)
-             {
-                throw new IllegalStateException("There are two servers with serverID=" +
-                   this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
-             }
-             mainDelegate = del;
-          }
+         
+         if (del.getServerID() == this.serverPeer.getServerPeerID())
+         {
+            // sanity check
+            if (mainDelegate != null)
+            {
+               throw new IllegalStateException("There are two servers with serverID=" +
+                        this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
+            }
+            mainDelegate = del;
+         }
       }
             
       return new ClusteredClientConnectionFactoryDelegate(mainDelegate, delArr, failoverMap);
@@ -455,6 +475,27 @@
          }
       }
    }
+   
+   /*
+    * Sort the collection of delegates in order of server id
+    */
+   private List sortCFS(Collection delegates)
+   {
+      List localDels = new ArrayList(delegates);
+      
+      Collections.sort(localDels,
+                       new Comparator()
+                       {
+                           public int compare(Object obj1, Object obj2)
+                           {
+                              ClientConnectionFactoryDelegate del1 = (ClientConnectionFactoryDelegate)obj1;
+                              ClientConnectionFactoryDelegate del2 = (ClientConnectionFactoryDelegate)obj2;
+                              return del1.getServerID() - del2.getServerID();
+                           } 
+                       });
+      
+      return localDels;
+   }
 
    // Inner classes -------------------------------------------------
 }

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 19:32:42 UTC (rev 1794)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 20:56:41 UTC (rev 1795)
@@ -356,9 +356,9 @@
          
          log.info("cf2 serverid=" + cf2.getServerID());
          
-         assertEquals(2, cf1.getServerID());
+         assertEquals(0, cf1.getServerID());
          
-         assertEquals(0, cf2.getServerID());
+         assertEquals(2, cf2.getServerID());
          
          
          assertEquals(2, failoverMap.size());
@@ -401,11 +401,11 @@
          
          log.info("cf3 serverid=" + cf3.getServerID());
          
-         assertEquals(2, cf1.getServerID());
+         assertEquals(0, cf1.getServerID());
          
-         assertEquals(0, cf2.getServerID());
+         assertEquals(1, cf2.getServerID());
          
-         assertEquals(1, cf3.getServerID());
+         assertEquals(2, cf3.getServerID());
          
          
          assertEquals(3, failoverMap.size());
@@ -468,16 +468,12 @@
             
       try
       {      
-         conn = factory.createConnection(); //connection on server 2
-         
-         conn.close();
-         
          conn = factory.createConnection(); //connection on server 0
          
          conn.close();
          
-         conn = factory.createConnection(); // connection on server 1
-         
+         conn = factory.createConnection(); //connection on server 1
+                          
          JBossConnection jbc = (JBossConnection)conn;
          
          ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
@@ -567,369 +563,369 @@
    }
    
    
-   public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-      assertEquals(3, nodeIDView.size());
-      
-      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
-      ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
-      int server0Id = cf1.getServerID();
-      
-      int server1Id = cf2.getServerID();
-      
-      int server2Id = cf3.getServerID();
-      
-      log.info("server 0 id: " + server0Id);
-      
-      log.info("server 1 id: " + server1Id);
-      
-      log.info("server 2 id: " + server2Id);
-                  
-      Map failoverMap = delegate.getFailoverMap();
-      
-      log.info(failoverMap.get(new Integer(server0Id)));
-      log.info(failoverMap.get(new Integer(server1Id)));
-      log.info(failoverMap.get(new Integer(server2Id)));
-      
-      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
-      // server 1 should failover onto server 2
-      
-      assertEquals(server2Id, server1FailoverId);
-      
-      Connection conn = null;
-      
-      boolean killed = false;
-      
-      try
-      {      
-         conn = factory.createConnection(); //connection on server 1
-         
-         conn.close();
-         
-         conn = factory.createConnection(); //connection on server 2
-         
-         JBossConnection jbc = (JBossConnection)conn;
-         
-         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
-         ConnectionState state = (ConnectionState)del.getState();
-         
-         int initialServerID = state.getServerID();
-         
-         assertEquals(2, initialServerID);
-                           
-         Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
-         
-         MessageProducer prod = sess.createProducer(queue[1]);
-         
-         MessageConsumer cons = sess.createConsumer(queue[1]);
-         
-         final int NUM_MESSAGES = 100;
-         
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess.createTextMessage("message:" + i);
-            
-            prod.send(tm);
-         }
-         
-         conn.start();
-         
-         //Now consume half of the messages but don't ack them these will end up in 
-         //client side toAck list
-         
-         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-         {
-            TextMessage tm = (TextMessage)cons.receive(500);
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         //So now, messages should be in queue[1] on server 1
-         //So we now kill server 1
-         //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
-         ServerManagement.kill(1);
-         
-         killed = true;
-         
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(10000);
-         
-         log.info("done wait");
-         
-         state = (ConnectionState)del.getState();
-         
-         int finalServerID = state.getServerID();
-         
-         log.info("final server id= " + finalServerID);
-         
-         //server id should now be 2
-         
-         assertEquals(2, finalServerID);
-         
-         conn.start();
-         
-         //Now should be able to consume the rest of the messages
-         
-         log.info("here1");
-         
-         TextMessage tm = null;
-         
-         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-         {
-            tm = (TextMessage)cons.receive(500);
-                                    
-            log.info("message is " + tm.getText());
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         log.info("here2");
-         
-         //Now should be able to acknowledge them
-         
-         tm.acknowledge();
-         
-         //Now check there are no more messages there
-         sess.close();
-         
-         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         cons = sess.createConsumer(queue[1]);
-         
-         Message m = cons.receive(500);
-         
-         assertNull(m);
-         
-         log.info("got to end of test");
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-         
-         // Resurrect dead server
-         if (killed)
-         {
-            ServerManagement.spawn(1);
-         }
-      }
-      
-   }
+//   public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerID();
+//      
+//      int server1Id = cf2.getServerID();
+//      
+//      int server2Id = cf3.getServerID();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      boolean killed = false;
+//      
+//      try
+//      {      
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 2
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(2, initialServerID);
+//                           
+//         Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+//         
+//         MessageProducer prod = sess.createProducer(queue[1]);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue[1]);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         conn.start();
+//         
+//         //Now consume half of the messages but don't ack them these will end up in 
+//         //client side toAck list
+//         
+//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(500);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         //So now, messages should be in queue[1] on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.kill(1);
+//         
+//         killed = true;
+//         
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(10000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         //Now should be able to consume the rest of the messages
+//         
+//         log.info("here1");
+//         
+//         TextMessage tm = null;
+//         
+//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+//         {
+//            tm = (TextMessage)cons.receive(500);
+//                                    
+//            log.info("message is " + tm.getText());
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         log.info("here2");
+//         
+//         //Now should be able to acknowledge them
+//         
+//         tm.acknowledge();
+//         
+//         //Now check there are no more messages there
+//         sess.close();
+//         
+//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         cons = sess.createConsumer(queue[1]);
+//         
+//         Message m = cons.receive(500);
+//         
+//         assertNull(m);
+//         
+//         log.info("got to end of test");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//         
+//         // Resurrect dead server
+//         if (killed)
+//         {
+//            ServerManagement.spawn(1);
+//         }
+//      }
+//      
+//   }
+//   
+//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
+//      
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//      
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//      
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//      
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//      
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//      
+//      int server0Id = cf1.getServerID();
+//      
+//      int server1Id = cf2.getServerID();
+//      
+//      int server2Id = cf3.getServerID();
+//      
+//      log.info("server 0 id: " + server0Id);
+//      
+//      log.info("server 1 id: " + server1Id);
+//      
+//      log.info("server 2 id: " + server2Id);
+//                  
+//      Map failoverMap = delegate.getFailoverMap();
+//      
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//      
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//      
+//      // server 1 should failover onto server 2
+//      
+//      assertEquals(server2Id, server1FailoverId);
+//      
+//      Connection conn = null;
+//      
+//      boolean killed = false;
+//      
+//      try
+//      {      
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//         
+//         conn.close();
+//         
+//         conn = factory.createConnection(); //connection on server 1
+//         
+//         JBossConnection jbc = (JBossConnection)conn;
+//         
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//         
+//         ConnectionState state = (ConnectionState)del.getState();
+//         
+//         int initialServerID = state.getServerID();
+//         
+//         assertEquals(1, initialServerID);
+//                           
+//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+//         
+//         MessageProducer prod = sess.createProducer(queue[1]);
+//         
+//         MessageConsumer cons = sess.createConsumer(queue[1]);
+//         
+//         final int NUM_MESSAGES = 100;
+//         
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//            
+//            prod.send(tm);
+//         }
+//         
+//         sess.commit();
+//         
+//         conn.start();
+//         
+//         //Now consume half of the messages but don't commit them these will end up in 
+//         //client side resource manager
+//         
+//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(500);
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         //So now, messages should be in queue[1] on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//         
+//         log.info("************ KILLING (CRASHING) SERVER 1");
+//         
+//         ServerManagement.kill(1);
+//         
+//         killed = true;
+//
+//         log.info("killed server, now waiting");
+//         
+//         Thread.sleep(5000);
+//         
+//         log.info("done wait");
+//         
+//         state = (ConnectionState)del.getState();
+//         
+//         int finalServerID = state.getServerID();
+//         
+//         log.info("final server id= " + finalServerID);
+//         
+//         //server id should now be 2
+//         
+//         assertEquals(2, finalServerID);
+//         
+//         conn.start();
+//         
+//         //Now should be able to consume the rest of the messages
+//         
+//         log.info("here1");
+//         
+//         TextMessage tm = null;
+//         
+//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+//         {
+//            tm = (TextMessage)cons.receive(500);
+//                                    
+//            log.info("message is " + tm.getText());
+//            
+//            assertNotNull(tm);
+//            
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//         
+//         log.info("here2");
+//         
+//         //Now should be able to commit them
+//         
+//         sess.commit();
+//         
+//         //Now check there are no more messages there
+//         sess.close();
+//         
+//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         
+//         cons = sess.createConsumer(queue[1]);
+//         
+//         Message m = cons.receive(500);
+//         
+//         assertNull(m);
+//         
+//         log.info("got to end of test");
+//      }
+//      finally
+//      {         
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//         
+//         if (killed)
+//         {
+//            ServerManagement.spawn(1);
+//         }
+//      }
+//      
+//   }
    
-   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-      assertEquals(3, nodeIDView.size());
-      
-      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
-      ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
-      int server0Id = cf1.getServerID();
-      
-      int server1Id = cf2.getServerID();
-      
-      int server2Id = cf3.getServerID();
-      
-      log.info("server 0 id: " + server0Id);
-      
-      log.info("server 1 id: " + server1Id);
-      
-      log.info("server 2 id: " + server2Id);
-                  
-      Map failoverMap = delegate.getFailoverMap();
-      
-      log.info(failoverMap.get(new Integer(server0Id)));
-      log.info(failoverMap.get(new Integer(server1Id)));
-      log.info(failoverMap.get(new Integer(server2Id)));
-      
-      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
-      // server 1 should failover onto server 2
-      
-      assertEquals(server2Id, server1FailoverId);
-      
-      Connection conn = null;
-      
-      boolean killed = false;
-      
-      try
-      {      
-         //Get a connection on server 1
-         conn = factory.createConnection(); //connection on server 0
-         
-         conn.close();
-         
-         conn = factory.createConnection(); //connection on server 1
-         
-         JBossConnection jbc = (JBossConnection)conn;
-         
-         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
-         ConnectionState state = (ConnectionState)del.getState();
-         
-         int initialServerID = state.getServerID();
-         
-         assertEquals(1, initialServerID);
-                           
-         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-         
-         MessageProducer prod = sess.createProducer(queue[1]);
-         
-         MessageConsumer cons = sess.createConsumer(queue[1]);
-         
-         final int NUM_MESSAGES = 100;
-         
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess.createTextMessage("message:" + i);
-            
-            prod.send(tm);
-         }
-         
-         sess.commit();
-         
-         conn.start();
-         
-         //Now consume half of the messages but don't commit them these will end up in 
-         //client side resource manager
-         
-         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-         {
-            TextMessage tm = (TextMessage)cons.receive(500);
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         //So now, messages should be in queue[1] on server 1
-         //So we now kill server 1
-         //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
-         ServerManagement.kill(1);
-         
-         killed = true;
-
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(5000);
-         
-         log.info("done wait");
-         
-         state = (ConnectionState)del.getState();
-         
-         int finalServerID = state.getServerID();
-         
-         log.info("final server id= " + finalServerID);
-         
-         //server id should now be 2
-         
-         assertEquals(2, finalServerID);
-         
-         conn.start();
-         
-         //Now should be able to consume the rest of the messages
-         
-         log.info("here1");
-         
-         TextMessage tm = null;
-         
-         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-         {
-            tm = (TextMessage)cons.receive(500);
-                                    
-            log.info("message is " + tm.getText());
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         log.info("here2");
-         
-         //Now should be able to commit them
-         
-         sess.commit();
-         
-         //Now check there are no more messages there
-         sess.close();
-         
-         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         cons = sess.createConsumer(queue[1]);
-         
-         Message m = cons.receive(500);
-         
-         assertNull(m);
-         
-         log.info("got to end of test");
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-         
-         if (killed)
-         {
-            ServerManagement.spawn(1);
-         }
-      }
-      
-   }
    
-   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try



From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 16:09:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 16:09:32 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1796 - in
	trunk/tests/src/org/jboss/test/messaging: jms/clustering/base
	tools tools/jmx/rmi util
Message-ID: <E1Guxpc-00044j-Ii@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-14 16:09:29 -0500 (Thu, 14 Dec 2006)
New Revision: 1796

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
Log:
tweaks to get server resurrection working correctly

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-14 20:56:41 UTC (rev 1795)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-14 21:09:29 UTC (rev 1796)
@@ -112,7 +112,7 @@
 
       for(int i = 0; i < nodeCount; i++)
       {
-         if (!ServerManagement.isKilled(i) && ServerManagement.getServer(i).isStarted())
+         if (ServerManagement.isStarted(i))
          {
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server " + i, i);
             ServerManagement.undeployQueue("testDistributedQueue", i);

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-14 20:56:41 UTC (rev 1795)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-14 21:09:29 UTC (rev 1796)
@@ -95,6 +95,35 @@
       return !isLocal();
    }
 
+   public static boolean isClustered()
+   {
+      return "true".equals(System.getProperty("test.clustered"));
+   }
+
+   public static synchronized boolean isKilled(int index)
+   {
+      return killed[index];
+   }
+
+   public static synchronized boolean isStarted(int index)
+   {
+      Server s = servers[index];
+
+      if (s == null)
+      {
+         return false;
+      }
+
+      try
+      {
+         return s.isStarted();
+      }
+      catch(Exception e)
+      {
+         return false;
+      }
+   }
+
    public static Server getServer()
    {
       return getServer(0);
@@ -276,6 +305,8 @@
 
       Runtime.getRuntime().exec(sb.toString());
 
+      killed[index] = false;
+
       log.info("VM for Server " + index + " spawned");
    }
 
@@ -298,11 +329,6 @@
       killed[index] = true;
    }
    
-   public static synchronized boolean isKilled(int index)
-   {
-      return killed[index];
-   }
-
    public static void disconnect() throws Exception
    {
       if (isRemote())

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-14 20:56:41 UTC (rev 1795)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-14 21:09:29 UTC (rev 1796)
@@ -833,6 +833,11 @@
 
    // Public --------------------------------------------------------
 
+   public int getServerIndex()
+   {
+      return serverIndex;
+   }
+
    // Package protected ---------------------------------------------
 
    ServiceContainer getServiceContainer()

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-14 20:56:41 UTC (rev 1795)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-14 21:09:29 UTC (rev 1796)
@@ -453,8 +453,25 @@
       {
          log.info("shutting down the VM");
 
+
          try
          {
+            // unregister myself from the RMI registry
+
+            Registry registry = LocateRegistry.getRegistry(DEFAULT_REGISTRY_PORT);
+            registry.unbind(RMI_SERVER_PREFIX + server.getServerIndex());
+
+            log.info("unregistred from " + registry);
+
+
+         }
+         catch(Exception e)
+         {
+            log.error("Failed to unregister", e);
+         }
+
+         try
+         {
             Thread.sleep(250);
          }
          catch(Exception e)

Modified: trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-14 20:56:41 UTC (rev 1795)
+++ trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-14 21:09:29 UTC (rev 1796)
@@ -10,7 +10,6 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 
 import javax.naming.InitialContext;
-import javax.naming.Context;
 import javax.management.ObjectName;
 
 /**
@@ -104,6 +103,39 @@
       }
    }
 
+   /**
+    * Needs to be run in clustered mode.
+    */
+   public void testRessurect() throws Exception
+   {
+
+      if (!ServerManagement.isClustered())
+      {
+         fail("This test must be run in clustered mode!");
+      }
+
+      ServerManagement.start("all", 1);
+
+      ServerManagement.kill(1);
+
+      // wait a bit for the server to die
+      
+      log.info("Sleeping for 10 seconds ...");
+
+      Thread.sleep(10000);
+
+      // resurrect the server
+
+      ServerManagement.spawn(1);
+      ServerManagement.start("all", 1);
+
+      Integer index = (Integer)ServerManagement.
+         getAttribute(1, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
+
+      assertEquals(1, index.intValue());
+   }
+
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------



From c52 at fullmailmarket.com  Thu Dec 14 15:23:10 2006
From: c52 at fullmailmarket.com (RamChile)
Date: Thu, 14 Dec 2006 17:23:10 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Liquidaci=F3n_de_Accesorios_para_iPod?=
Message-ID: <200612142123.kBELN8GU009822@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061214/4a525851/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Thu Dec 14 16:28:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 14 Dec 2006 16:28:27 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1797 - in trunk/tests: .
	src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Guy7v-0004Q7-Tf@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-14 16:28:22 -0500 (Thu, 14 Dec 2006)
New Revision: 1797

Modified:
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
re-enable tests



Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-14 21:09:29 UTC (rev 1796)
+++ trunk/tests/build.xml	2006-12-14 21:28:22 UTC (rev 1797)
@@ -745,7 +745,7 @@
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
                <!--
                <include name="**/jms/clustering/SimpleClusteringTest.class"/>
                -->

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 21:09:29 UTC (rev 1796)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 21:28:22 UTC (rev 1797)
@@ -442,8 +442,6 @@
       
       int server2Id = cf3.getServerID();
 
-      //Server order should be 2, 0, 1
-      
       log.info("server 0 id: " + server0Id);
       
       log.info("server 1 id: " + server1Id);
@@ -563,369 +561,369 @@
    }
    
    
-//   public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//      
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//      
-//      int server0Id = cf1.getServerID();
-//      
-//      int server1Id = cf2.getServerID();
-//      
-//      int server2Id = cf3.getServerID();
-//      
-//      log.info("server 0 id: " + server0Id);
-//      
-//      log.info("server 1 id: " + server1Id);
-//      
-//      log.info("server 2 id: " + server2Id);
-//                  
-//      Map failoverMap = delegate.getFailoverMap();
-//      
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//      
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//      
-//      // server 1 should failover onto server 2
-//      
-//      assertEquals(server2Id, server1FailoverId);
-//      
-//      Connection conn = null;
-//      
-//      boolean killed = false;
-//      
-//      try
-//      {      
-//         conn = factory.createConnection(); //connection on server 1
-//         
-//         conn.close();
-//         
-//         conn = factory.createConnection(); //connection on server 2
-//         
-//         JBossConnection jbc = (JBossConnection)conn;
-//         
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//         
-//         ConnectionState state = (ConnectionState)del.getState();
-//         
-//         int initialServerID = state.getServerID();
-//         
-//         assertEquals(2, initialServerID);
-//                           
-//         Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
-//         
-//         MessageProducer prod = sess.createProducer(queue[1]);
-//         
-//         MessageConsumer cons = sess.createConsumer(queue[1]);
-//         
-//         final int NUM_MESSAGES = 100;
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//            
-//            prod.send(tm);
-//         }
-//         
-//         conn.start();
-//         
-//         //Now consume half of the messages but don't ack them these will end up in 
-//         //client side toAck list
-//         
-//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(500);
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         //So now, messages should be in queue[1] on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//         
-//         log.info("************ KILLING (CRASHING) SERVER 1");
-//         
-//         ServerManagement.kill(1);
-//         
-//         killed = true;
-//         
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(10000);
-//         
-//         log.info("done wait");
-//         
-//         state = (ConnectionState)del.getState();
-//         
-//         int finalServerID = state.getServerID();
-//         
-//         log.info("final server id= " + finalServerID);
-//         
-//         //server id should now be 2
-//         
-//         assertEquals(2, finalServerID);
-//         
-//         conn.start();
-//         
-//         //Now should be able to consume the rest of the messages
-//         
-//         log.info("here1");
-//         
-//         TextMessage tm = null;
-//         
-//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-//         {
-//            tm = (TextMessage)cons.receive(500);
-//                                    
-//            log.info("message is " + tm.getText());
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         log.info("here2");
-//         
-//         //Now should be able to acknowledge them
-//         
-//         tm.acknowledge();
-//         
-//         //Now check there are no more messages there
-//         sess.close();
-//         
-//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//         
-//         cons = sess.createConsumer(queue[1]);
-//         
-//         Message m = cons.receive(500);
-//         
-//         assertNull(m);
-//         
-//         log.info("got to end of test");
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//         
-//         // Resurrect dead server
-//         if (killed)
-//         {
-//            ServerManagement.spawn(1);
-//         }
-//      }
-//      
-//   }
-//   
-//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-//      
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//      
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//      
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//      
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//      
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//      
-//      int server0Id = cf1.getServerID();
-//      
-//      int server1Id = cf2.getServerID();
-//      
-//      int server2Id = cf3.getServerID();
-//      
-//      log.info("server 0 id: " + server0Id);
-//      
-//      log.info("server 1 id: " + server1Id);
-//      
-//      log.info("server 2 id: " + server2Id);
-//                  
-//      Map failoverMap = delegate.getFailoverMap();
-//      
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//      
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//      
-//      // server 1 should failover onto server 2
-//      
-//      assertEquals(server2Id, server1FailoverId);
-//      
-//      Connection conn = null;
-//      
-//      boolean killed = false;
-//      
-//      try
-//      {      
-//         //Get a connection on server 1
-//         conn = factory.createConnection(); //connection on server 0
-//         
-//         conn.close();
-//         
-//         conn = factory.createConnection(); //connection on server 1
-//         
-//         JBossConnection jbc = (JBossConnection)conn;
-//         
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//         
-//         ConnectionState state = (ConnectionState)del.getState();
-//         
-//         int initialServerID = state.getServerID();
-//         
-//         assertEquals(1, initialServerID);
-//                           
-//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-//         
-//         MessageProducer prod = sess.createProducer(queue[1]);
-//         
-//         MessageConsumer cons = sess.createConsumer(queue[1]);
-//         
-//         final int NUM_MESSAGES = 100;
-//         
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//            
-//            prod.send(tm);
-//         }
-//         
-//         sess.commit();
-//         
-//         conn.start();
-//         
-//         //Now consume half of the messages but don't commit them these will end up in 
-//         //client side resource manager
-//         
-//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(500);
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         //So now, messages should be in queue[1] on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//         
-//         log.info("************ KILLING (CRASHING) SERVER 1");
-//         
-//         ServerManagement.kill(1);
-//         
-//         killed = true;
-//
-//         log.info("killed server, now waiting");
-//         
-//         Thread.sleep(5000);
-//         
-//         log.info("done wait");
-//         
-//         state = (ConnectionState)del.getState();
-//         
-//         int finalServerID = state.getServerID();
-//         
-//         log.info("final server id= " + finalServerID);
-//         
-//         //server id should now be 2
-//         
-//         assertEquals(2, finalServerID);
-//         
-//         conn.start();
-//         
-//         //Now should be able to consume the rest of the messages
-//         
-//         log.info("here1");
-//         
-//         TextMessage tm = null;
-//         
-//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-//         {
-//            tm = (TextMessage)cons.receive(500);
-//                                    
-//            log.info("message is " + tm.getText());
-//            
-//            assertNotNull(tm);
-//            
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//         
-//         log.info("here2");
-//         
-//         //Now should be able to commit them
-//         
-//         sess.commit();
-//         
-//         //Now check there are no more messages there
-//         sess.close();
-//         
-//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//         
-//         cons = sess.createConsumer(queue[1]);
-//         
-//         Message m = cons.receive(500);
-//         
-//         assertNull(m);
-//         
-//         log.info("got to end of test");
-//      }
-//      finally
-//      {         
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//         
-//         if (killed)
-//         {
-//            ServerManagement.spawn(1);
-//         }
-//      }
-//      
-//   }
+   public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
+      int server0Id = cf1.getServerID();
+      
+      int server1Id = cf2.getServerID();
+      
+      int server2Id = cf3.getServerID();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+      
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+      
+      // server 1 should failover onto server 2
+      
+      assertEquals(server2Id, server1FailoverId);
+      
+      Connection conn = null;
+      
+      boolean killed = false;
+      
+      try
+      {      
+         conn = factory.createConnection(); //connection on server 0
+         
+         conn.close();
+         
+         conn = factory.createConnection(); //connection on server 1
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(1, initialServerID);
+                           
+         Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess.createProducer(queue[1]);
+         
+         MessageConsumer cons = sess.createConsumer(queue[1]);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         conn.start();
+         
+         //Now consume half of the messages but don't ack them these will end up in 
+         //client side toAck list
+         
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         //So now, messages should be in queue[1] on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 1");
+         
+         ServerManagement.kill(1);
+         
+         killed = true;
+         
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(10000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 2
+         
+         assertEquals(2, finalServerID);
+         
+         conn.start();
+         
+         //Now should be able to consume the rest of the messages
+         
+         log.info("here1");
+         
+         TextMessage tm = null;
+         
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+         {
+            tm = (TextMessage)cons.receive(500);
+                                    
+            log.info("message is " + tm.getText());
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         log.info("here2");
+         
+         //Now should be able to acknowledge them
+         
+         tm.acknowledge();
+         
+         //Now check there are no more messages there
+         sess.close();
+         
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons = sess.createConsumer(queue[1]);
+         
+         Message m = cons.receive(500);
+         
+         assertNull(m);
+         
+         log.info("got to end of test");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+         
+         // Resurrect dead server
+         if (killed)
+         {
+            ServerManagement.spawn(1);
+         }
+      }
+      
+   }
    
+   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
+      
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+      
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+      
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+      
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+      
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+      
+      int server0Id = cf1.getServerID();
+      
+      int server1Id = cf2.getServerID();
+      
+      int server2Id = cf3.getServerID();
+      
+      log.info("server 0 id: " + server0Id);
+      
+      log.info("server 1 id: " + server1Id);
+      
+      log.info("server 2 id: " + server2Id);
+                  
+      Map failoverMap = delegate.getFailoverMap();
+      
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+      
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+      
+      // server 1 should failover onto server 2
+      
+      assertEquals(server2Id, server1FailoverId);
+      
+      Connection conn = null;
+      
+      boolean killed = false;
+      
+      try
+      {      
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
+         
+         conn.close();
+         
+         conn = factory.createConnection(); //connection on server 1
+         
+         JBossConnection jbc = (JBossConnection)conn;
+         
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+         
+         ConnectionState state = (ConnectionState)del.getState();
+         
+         int initialServerID = state.getServerID();
+         
+         assertEquals(1, initialServerID);
+                           
+         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+         
+         MessageProducer prod = sess.createProducer(queue[1]);
+         
+         MessageConsumer cons = sess.createConsumer(queue[1]);
+         
+         final int NUM_MESSAGES = 100;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+            
+            prod.send(tm);
+         }
+         
+         sess.commit();
+         
+         conn.start();
+         
+         //Now consume half of the messages but don't commit them these will end up in 
+         //client side resource manager
+         
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         //So now, messages should be in queue[1] on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+         
+         log.info("************ KILLING (CRASHING) SERVER 1");
+         
+         ServerManagement.kill(1);
+         
+         killed = true;
+
+         log.info("killed server, now waiting");
+         
+         Thread.sleep(5000);
+         
+         log.info("done wait");
+         
+         state = (ConnectionState)del.getState();
+         
+         int finalServerID = state.getServerID();
+         
+         log.info("final server id= " + finalServerID);
+         
+         //server id should now be 2
+         
+         assertEquals(2, finalServerID);
+         
+         conn.start();
+         
+         //Now should be able to consume the rest of the messages
+         
+         log.info("here1");
+         
+         TextMessage tm = null;
+         
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+         {
+            tm = (TextMessage)cons.receive(500);
+                                    
+            log.info("message is " + tm.getText());
+            
+            assertNotNull(tm);
+            
+            assertEquals("message:" + i, tm.getText());
+         }
+         
+         log.info("here2");
+         
+         //Now should be able to commit them
+         
+         sess.commit();
+         
+         //Now check there are no more messages there
+         sess.close();
+         
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons = sess.createConsumer(queue[1]);
+         
+         Message m = cons.receive(500);
+         
+         assertNull(m);
+         
+         log.info("got to end of test");
+      }
+      finally
+      {         
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+         
+         if (killed)
+         {
+            ServerManagement.spawn(1);
+         }
+      }
+      
+   }
    
+   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try



From Shane_Bryzak at symantec.com  Thu Dec 14 23:13:17 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 23:13:17 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1Gv4Rg-0003zX-Va@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 23:13:16

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  implemented page-based security constraints
  
  Revision  Changes    Path
  1.26      +0 -26     jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- SeamSecurityManager.java	14 Dec 2006 05:39:34 -0000	1.25
  +++ SeamSecurityManager.java	15 Dec 2006 04:13:16 -0000	1.26
  @@ -189,30 +189,4 @@
   
       return (WorkingMemory) session.get(SECURITY_CONTEXT_NAME);
     }
  -
  -//  public void checkPermission(String permissionName, String action)
  -//  {
  -//    checkRolePermissions(permissionName, action);
  -//  }
  -
  -//  public void checkPermission(Object obj, String action)
  -//  {
  -//    checkRolePermissions(Seam.getComponentName(obj.getClass()), action);
  -//  }
  -
  -  /**
  -   *
  -   * @param permissionName
  -   * @param action
  -   */
  -//  private void checkRolePermissions(String permissionName, String action)
  -//  {
  -//    Permission required = new SeamPermission(permissionName, action);
  -//    for (Role role : Identity.instance().getRoles())
  -//    {
  -//      Set<Permission> permissions = rolePermissions.get(role);
  -//      if (permissions != null && permissions.contains(required))
  -//        return;
  -//    }
  -//  }
   }
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 14 23:13:17 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 23:13:17 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config   ...
Message-ID: <E1Gv4Rh-0003zh-4a@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 23:13:17

  Modified:    src/main/org/jboss/seam/security/config  
                        SecurityConfiguration.java SecurityConstraint.java
  Log:
  implemented page-based security constraints
  
  Revision  Changes    Path
  1.4       +58 -56    jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SecurityConfiguration.java	14 Dec 2006 05:39:35 -0000	1.3
  +++ SecurityConfiguration.java	15 Dec 2006 04:13:17 -0000	1.4
  @@ -42,12 +42,12 @@
     private static final Log log = LogFactory.getLog(SecurityConfiguration.class);
   
     // <security-constraint>
  -//  private static final String SECURITY_CONSTRAINT = "security-constraint";
  -//  private static final String WEB_RESOURCE_COLLECTION = "web-resource-collection";
  -//  private static final String URL_PATTERN = "url-pattern";
  -//  private static final String HTTP_METHOD = "http-method";
  -//  private static final String AUTH_CONSTRAINT = "auth-constraint";
  -//  private static final String ROLE_NAME = "role-name";
  +  private static final String SECURITY_CONSTRAINT = "security-constraint";
  +  private static final String WEB_RESOURCE_COLLECTION = "web-resource-collection";
  +  private static final String URL_PATTERN = "url-pattern";
  +  private static final String HTTP_METHOD = "http-method";
  +  private static final String AUTH_CONSTRAINT = "auth-constraint";
  +  private static final String ROLE_NAME = "role-name";
   
     // <login-config>
   //  private static final String LOGIN_CONFIG = "login-config";
  @@ -66,7 +66,7 @@
     private static final String SECURITY_PERMISSIONS = "permissions";
     private static final String SECURITY_PERMISSION = "permission";
   
  -//  private Set<SecurityConstraint> securityConstraints = new HashSet<SecurityConstraint>();
  +  private Set<SecurityConstraint> securityConstraints = new HashSet<SecurityConstraint>();
   
     private Map<String,Role> securityRoles = new HashMap<String,Role>();
   
  @@ -106,9 +106,10 @@
         Document doc = xmlReader.read(config);
         Element env = doc.getRootElement();
   
  -//      loadSecurityConstraints(env.elements(SECURITY_CONSTRAINT));
  -//      loadLoginConfig(env.element(LOGIN_CONFIG));
  +      loadSecurityConstraints(env.elements(SECURITY_CONSTRAINT));
         loadSecurityRoles(env.element(SECURITY_ROLES));
  +
  +      //      loadLoginConfig(env.element(LOGIN_CONFIG));
       }
       catch (Exception ex)
       {
  @@ -120,13 +121,14 @@
     }
   
     /**
  +   * Returns the configured security constraints
      *
      * @return Set
      */
  -//  public Set<SecurityConstraint> getSecurityConstraints()
  -//  {
  -//    return securityConstraints;
  -//  }
  +  public Set<SecurityConstraint> getSecurityConstraints()
  +  {
  +    return securityConstraints;
  +  }
   
     /**
      *
  @@ -161,49 +163,49 @@
      * @param elements List
      * @throws SecurityConfigurationException
      */
  -//  private void loadSecurityConstraints(List elements)
  -//      throws SecurityConfigException
  -//  {
  -//    try
  -//    {
  -//      for (Element element : (List<Element>) elements)
  -//      {
  -//        SecurityConstraint securityConstraint = new SecurityConstraint();
  -//        securityConstraints.add(securityConstraint);
  -//
  -//        for (Element wrcElement :
  -//            (List<Element>) element.elements(WEB_RESOURCE_COLLECTION))
  -//        {
  -//          WebResourceCollection wrc = new WebResourceCollection();
  -//          securityConstraint.getResourceCollections().add(wrc);
  -//
  -//          for (Element urlPatternElement :
  -//              (List<Element>) wrcElement.elements(URL_PATTERN))
  -//          {
  -//            wrc.getUrlPatterns().add(urlPatternElement.getTextTrim());
  -//          }
  -//
  -//          for (Element httpMethodElement :
  -//              (List<Element>) wrcElement.elements(HTTP_METHOD))
  -//          {
  -//            wrc.getHttpMethods().add(httpMethodElement.getTextTrim());
  -//          }
  -//        }
  -//
  -//        securityConstraint.setAuthConstraint(new AuthConstraint());
  -//        for (Element roleNameElement :
  -//            (List<Element>) element.element(AUTH_CONSTRAINT).elements(ROLE_NAME))
  -//        {
  -//          securityConstraint.getAuthConstraint().getRoles().add(roleNameElement.
  -//              getTextTrim());
  -//        }
  -//      }
  -//    }
  -//    catch (Exception ex)
  -//    {
  -//      throw new SecurityConfigException("Error loading security constraints", ex);
  -//    }
  -//  }
  +  private void loadSecurityConstraints(List elements)
  +      throws SecurityConfigException
  +  {
  +    try
  +    {
  +      for (Element element : (List<Element>) elements)
  +      {
  +        SecurityConstraint securityConstraint = new SecurityConstraint();
  +        securityConstraints.add(securityConstraint);
  +
  +        for (Element wrcElement :
  +            (List<Element>) element.elements(WEB_RESOURCE_COLLECTION))
  +        {
  +          WebResourceCollection wrc = new WebResourceCollection();
  +          securityConstraint.getResourceCollections().add(wrc);
  +
  +          for (Element urlPatternElement :
  +              (List<Element>) wrcElement.elements(URL_PATTERN))
  +          {
  +            wrc.getUrlPatterns().add(urlPatternElement.getTextTrim());
  +          }
  +
  +          for (Element httpMethodElement :
  +              (List<Element>) wrcElement.elements(HTTP_METHOD))
  +          {
  +            wrc.getHttpMethods().add(httpMethodElement.getTextTrim());
  +          }
  +        }
  +
  +        securityConstraint.setAuthConstraint(new AuthConstraint());
  +        for (Element roleNameElement :
  +            (List<Element>) element.element(AUTH_CONSTRAINT).elements(ROLE_NAME))
  +        {
  +          securityConstraint.getAuthConstraint().getRoles().add(roleNameElement.
  +              getTextTrim());
  +        }
  +      }
  +    }
  +    catch (Exception ex)
  +    {
  +      throw new SecurityConfigException("Error loading security constraints", ex);
  +    }
  +  }
   
     /**
      * Load login configuration
  
  
  
  1.3       +92 -2     jboss-seam/src/main/org/jboss/seam/security/config/SecurityConstraint.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConstraint.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConstraint.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SecurityConstraint.java	24 Oct 2006 14:58:04 -0000	1.2
  +++ SecurityConstraint.java	15 Dec 2006 04:13:17 -0000	1.3
  @@ -1,10 +1,11 @@
   package org.jboss.seam.security.config;
   
  -import java.util.Set;
   import java.util.HashSet;
  +import java.util.Set;
   
   /**
  - * Represents the &lt;security-constraint&gt; element from the configuration.
  + * Represents the &lt;security-constraint&gt; element from the security
  + * configuration file.
    *
    * @author Shane Bryzak
    */
  @@ -32,4 +33,93 @@
     {
       this.authConstraint = authConstraint;
     }
  +
  +  /**
  +   * Check if the specified URI and method are included in this security constraint.
  +   *
  +   * @param uri String The URI to check
  +   * @param method String The method to check
  +   * @return boolean True if the URI and method match one of the patterns contained
  +   * within this security constraint, false otherwise.
  +   */
  +  public boolean included(String uri, String method)
  +  {
  +    if (method == null)
  +      return false;
  +
  +    for (WebResourceCollection c : resourceCollections)
  +    {
  +      if (!c.getHttpMethods().contains(method))
  +        continue;
  +
  +      for (String pattern : c.getUrlPatterns())
  +      {
  +        if (matchPattern(uri, pattern))
  +          return true;
  +      }
  +    }
  +
  +    return false;
  +  }
  +
  +  /**
  +   * Pattern matching code, adapted from Tomcat. This method checks to see if
  +   * the specified path matches the specified pattern.
  +   *
  +   * @param path String The path to check
  +   * @param pattern String The pattern to check the path against
  +   * @return boolean True if the path matches the pattern, false otherwise
  +   */
  +  private boolean matchPattern(String path, String pattern)
  +  {
  +    if (path == null || "".equals(path))
  +      path = "/";
  +    if (pattern == null || "".equals(pattern))
  +      pattern = "/";
  +
  +    // Check for an exact match
  +    if (path.equals(pattern))
  +      return true;
  +
  +    // Check for path prefix matching
  +    if (pattern.startsWith("/") && pattern.endsWith("/*"))
  +    {
  +      pattern = pattern.substring(0, pattern.length() - 2);
  +      if (pattern.length() == 0)
  +        return true;
  +
  +      if (path.endsWith("/"))
  +        path = path.substring(0, path.length() - 1);
  +
  +      while (true)
  +      {
  +        if (pattern.equals(path))
  +          return true;
  +        int slash = path.lastIndexOf('/');
  +        if (slash <= 0)
  +          break;
  +        path = path.substring(0, slash);
  +      }
  +      return false;
  +    }
  +
  +    // Check for suffix matching
  +    if (pattern.startsWith("*."))
  +    {
  +      int slash = path.lastIndexOf('/');
  +      int period = path.lastIndexOf('.');
  +      if ( (slash >= 0) && (period > slash) &&
  +          path.endsWith(pattern.substring(1)))
  +      {
  +        return true;
  +      }
  +      return false;
  +    }
  +
  +    // Check for universal mapping
  +    if (pattern.equals("/"))
  +      return true;
  +
  +    return false;
  +  }
   }
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 14 23:13:17 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 14 Dec 2006 23:13:17 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/filter  ...
Message-ID: <E1Gv4Rh-0003zo-8k@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/14 23:13:17

  Modified:    src/main/org/jboss/seam/security/filter 
                        SeamSecurityFilter.java
  Log:
  implemented page-based security constraints
  
  Revision  Changes    Path
  1.13      +77 -66    jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- SeamSecurityFilter.java	14 Dec 2006 05:39:35 -0000	1.12
  +++ SeamSecurityFilter.java	15 Dec 2006 04:13:17 -0000	1.13
  @@ -1,17 +1,26 @@
   package org.jboss.seam.security.filter;
   
   import java.io.IOException;
  +import java.util.Set;
   import javax.servlet.Filter;
   import javax.servlet.FilterChain;
   import javax.servlet.FilterConfig;
   import javax.servlet.ServletException;
   import javax.servlet.ServletRequest;
   import javax.servlet.ServletResponse;
  +import javax.servlet.http.HttpServletRequest;
  +import javax.servlet.http.HttpServletResponse;
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.seam.security.config.SecurityConfiguration;
  +import org.jboss.seam.Seam;
  +import org.jboss.seam.contexts.Context;
  +import org.jboss.seam.contexts.ContextAdaptor;
   import org.jboss.seam.contexts.WebApplicationContext;
  +import org.jboss.seam.contexts.WebSessionContext;
  +import org.jboss.seam.security.Identity;
  +import org.jboss.seam.security.config.SecurityConfiguration;
  +import org.jboss.seam.security.config.SecurityConstraint;
   
   /**
    * A servlet filter that performs authentication within a Seam application.
  @@ -22,80 +31,82 @@
   {
     private static final Log log = LogFactory.getLog(SeamSecurityFilter.class);
   
  -  public void init(FilterConfig config)
  +  private SecurityConfiguration config;
  +
  +  public void init(FilterConfig filterConfig)
         throws ServletException
     {
  -
  -//    try
  -//    {
  -      WebApplicationContext ctx = new WebApplicationContext(config.getServletContext());
  -
  -      SecurityConfiguration sc = (SecurityConfiguration) ctx.get(
  -          SecurityConfiguration.class);
  -
  -      log.info("**** SecurityConfiguration **** : " + sc);
  -
  -//    }
  -
  -//    try
  -//    {
  -//      SecurityConfig.instance().setServletContext(servletContext);
  -//      SecurityConfig.instance().loadConfig(new SecurityConfigFileLoader(
  -//        servletContext.getResourceAsStream(CONFIG_RESOURCE), servletContext));
  -//    }
  -//    catch (SecurityConfigException ex)
  -//    {
  -//      log.error(ex);
  -//      throw new ServletException("Error loading security configuration", ex);
  -//    }
  -//    catch (Exception ex)
  -//    {
  -//      throw new ServletException(ex);
  -//    }
  +    WebApplicationContext ctx = new WebApplicationContext(filterConfig.getServletContext());
  +    config = (SecurityConfiguration) ctx.get(SecurityConfiguration.class);
     }
   
  +  /**
  +   *
  +   * @param request ServletRequest
  +   * @param response ServletResponse
  +   * @param chain FilterChain
  +   * @throws IOException
  +   * @throws ServletException
  +   */
     public void doFilter(ServletRequest request, ServletResponse response,
                          FilterChain chain)
         throws IOException, ServletException
     {
  +    HttpServletRequest hRequest = (HttpServletRequest) request;
  +    HttpServletResponse hResponse = (HttpServletResponse) response;
  +
  +    Context sessionContext = new WebSessionContext(
  +        ContextAdaptor.getSession(hRequest.getSession()));
   
  -//    Context sessionContext = new WebSessionContext(
  -//        ContextAdaptor.getSession(hRequest.getSession()));
  -//
  -//    Authentication authentication = (Authentication)sessionContext.get(
  -//            "org.jboss.seam.security.Authentication");
  +    Identity ident = (Identity)sessionContext.get(Seam.getComponentName(Identity.class));
  +
  +    /** @todo Make the redirection configurable */
  +    if (!checkSecurityConstraints(hRequest.getRequestURI(), hRequest.getMethod(), ident))
  +      hResponse.sendRedirect("/securityError.seam");
   
  -//    try
  -//    {
         chain.doFilter(request, response);
  -//    }
  -//    catch (Exception e)
  -//    {
  -//      if (e instanceof ServletException)
  -//      {
  -//        Throwable cause = ( (ServletException) e).getRootCause();
  -//
  -//        Set<Throwable> causes = new HashSet<Throwable> ();
  -//        while (cause != null && !causes.contains(cause))
  -//        {
  -//          if (cause instanceof LoginException)
  -//          {
  -            // Redirect to login page
  -//            log.info("User not logged in... redirecting to login page.");
  -
  -            /** @todo Redirect based on whatever authentication method is being used */
  -
  -//             SecurityConfig.instance().getAuthenticator().showLogin(hRequest, hResponse);
  -//            break;
  -//          }
  -//          causes.add(cause);
  -//          cause = cause.getCause();
  -//        }
  -//      }
  -//      throw new ServletException(e);
  -//    }
     }
   
  -  public void destroy()
  -  {}
  +  /**
  +   * Performs a security check for a specified uri and method, for the specified
  +   * Identity
  +   *
  +   * @param uri String
  +   * @param method String
  +   * @param ident Identity
  +   * @return boolean
  +   */
  +  protected boolean checkSecurityConstraints(String uri, String method, Identity ident)
  +  {
  +    for (SecurityConstraint c : config.getSecurityConstraints())
  +    {
  +      if (c.included(uri, method))
  +      {
  +        if (!userHasRole(ident, c.getAuthConstraint().getRoles()))
  +          return false;
  +      }
  +    }
  +
  +    return true;
  +  }
  +
  +  /**
  +   * Returns true if the specified Identity has any one of a number of specified roles.
  +   *
  +   * @param ident Identity
  +   * @param roles String[]
  +   * @return boolean
  +   */
  +  private boolean userHasRole(Identity ident, Set<String> roles)
  +  {
  +    for (String role : roles)
  +    {
  +      if (ident.isUserInRole(role))
  +        return true;
  +    }
  +
  +    return false;
  +  }
  +
  +  public void destroy() {}
   }
  
  
  


From gavin.king at jboss.com  Thu Dec 14 23:42:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 23:42:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1Gv4u9-0004Qr-K6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 23:42:41

  Modified:    src/main/org/jboss/seam  components-1.1.xsd
  Log:
  fix JBSEAM-597
  
  Revision  Changes    Path
  1.5       +2 -1      jboss-seam/src/main/org/jboss/seam/components-1.1.xsd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components-1.1.xsd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/components-1.1.xsd,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- components-1.1.xsd	21 Nov 2006 02:51:03 -0000	1.4
  +++ components-1.1.xsd	15 Dec 2006 04:42:41 -0000	1.5
  @@ -43,6 +43,7 @@
         </xs:simpleType>
       </xs:attribute>
       <xs:attribute name="jndi-name"/>
  +    <xs:attribute name="precedence"/>
       <xs:attribute name="installed" default="true"/>
       <xs:attribute name="auto-create" default="false">
         <xs:simpleType>
  
  
  


From gavin.king at jboss.com  Thu Dec 14 23:42:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Thu, 14 Dec 2006 23:42:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/init  ...
Message-ID: <E1Gv4u9-0004Qy-OY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/14 23:42:41

  Modified:    src/main/org/jboss/seam/init  Initialization.java
  Log:
  fix JBSEAM-597
  
  Revision  Changes    Path
  1.132     +3 -2      jboss-seam/src/main/org/jboss/seam/init/Initialization.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Initialization.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/init/Initialization.java,v
  retrieving revision 1.131
  retrieving revision 1.132
  diff -u -b -r1.131 -r1.132
  --- Initialization.java	5 Dec 2006 19:37:02 -0000	1.131
  +++ Initialization.java	15 Dec 2006 04:42:41 -0000	1.132
  @@ -57,7 +57,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.131 $
  + * @version $Revision: 1.132 $
    */
   public class Initialization
   {
  @@ -262,7 +262,7 @@
   
         String scopeName = component.attributeValue("scope");
         String jndiName = component.attributeValue("jndi-name");
  -      String precedenceString = component.attributeValue("precendence");
  +      String precedenceString = component.attributeValue("precedence");
         int precedence = precedenceString==null ? Install.APPLICATION : Integer.valueOf(precedenceString);
         ScopeType scope = scopeName == null ? null : ScopeType.valueOf(scopeName.toUpperCase());
         boolean autoCreate = "true".equals(component.attributeValue("auto-create"));
  @@ -323,6 +323,7 @@
                  !"scope".equals(attributeName) &&
                  !"class".equals(attributeName) &&
                  !"jndi-name".equals(attributeName) &&
  +               !"precedence".equals(attributeName) &&
                  !"auto-create".equals(attributeName);
            if (isProperty)
            {
  
  
  


From gavin.king at jboss.com  Fri Dec 15 00:45:36 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 00:45:36 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1Gv5t2-0005aO-JY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 00:45:36

  Modified:    src/main/org/jboss/seam/contexts  PassivatedEntity.java
  Log:
  better behavior in exception cases
  
  Revision  Changes    Path
  1.2       +6 -2      jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivatedEntity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- PassivatedEntity.java	13 Dec 2006 04:57:59 -0000	1.1
  +++ PassivatedEntity.java	15 Dec 2006 05:45:36 -0000	1.2
  @@ -115,12 +115,16 @@
               {
                  if (id==null)
                  {
  -                  throw new IllegalStateException("could not get id of: " + /*beanClass.getName() + '.' +*/ fieldName);
  +                  //this can happen if persist() fails in Hibernate
  +                  return null;
                  }
  +               else
  +               {
                  return new PassivatedEntity( id, entityClass, persistenceContextName, fieldName );
               }
            }
         }
  +      }
         return null;
      }
      
  
  
  


From forge-admin at jboss.com  Fri Dec 15 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Fri, 15 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gv67Q-0005qG-By@committer01.frg.pub.inap.atl.jboss.com>

Commit from tokada on branch JBossProfiler_Expansion (2006-12-14 01:38 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  exsamples/jboss-profiler.aop/META-INF/jboss-aop.xml  1.1.2.5
  jboss-profiler  java/mbean/collector-config.xml                      1.1.2.3


Commit from gavin (2006-12-14 02:14 EST)
-----------------

JBSEAM-594

  jboss-seam  doc/reference/en/master.xml             1.47
  jboss-seam  doc/reference/en/modules/events.xml     1.7
  jboss-seam  doc/reference/en/modules/framework.xml  1.11


Commit from gavin (2006-12-14 02:19 EST)
-----------------

JBSEAM-590

  jboss-seam  doc/reference/en/modules/framework.xml     1.12
  jboss-seam  src/main/org/jboss/seam/framework-1.1.xsd  1.6


Commit from gavin (2006-12-14 02:32 EST)
-----------------

JBSEAM-588

  jboss-seam  seam.bat  1.17


Commit from gavin (2006-12-14 03:37 EST)
-----------------

fix JBSEAM-591

  jboss-seam  src/main/org/jboss/seam/framework/EntityQuery.java           1.6
  jboss-seam  src/main/org/jboss/seam/framework/HibernateEntityQuery.java  1.5
  jboss-seam  src/main/org/jboss/seam/framework/Query.java                 1.13


Commit from gavin (2006-12-14 03:52 EST)
-----------------

fix JBSEAM-592

  jboss-seam  src/ui/org/jboss/seam/ui/HtmlButton.java              1.4
  jboss-seam  src/ui/org/jboss/seam/ui/HtmlLink.java                1.24
  jboss-seam  src/ui/org/jboss/seam/ui/tag/EnumItemTag.java         1.2
  jboss-seam  src/ui/org/jboss/seam/ui/tag/UIComponentTagBase.java  1.8


Commit from gavin (2006-12-14 04:10 EST)
-----------------

warnings

  jboss-seam  src/ui/org/jboss/seam/ui/EnumItem.java    1.2
  jboss-seam  src/ui/org/jboss/seam/ui/SelectDate.java  1.3


Commit from gavin (2006-12-14 05:26 EST)
-----------------

introduce METHOD context, and solve   JBSEAM-564

  jboss-seam  src/main/META-INF/components.xml                                    1.8
  jboss-seam  src/main/org/jboss/seam/Component.java                              1.219
  jboss-seam  src/main/org/jboss/seam/ScopeType.java                              1.11
  jboss-seam  src/main/org/jboss/seam/contexts/Contexts.java                      1.45
  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java                     1.71
+ jboss-seam  src/main/org/jboss/seam/core/MethodContext.java                     1.1
  jboss-seam  src/main/org/jboss/seam/interceptors/AsynchronousInterceptor.java   1.8
+ jboss-seam  src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java  1.1


Commit from gavin (2006-12-14 05:40 EST)
-----------------

use methodcontext

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/BookingList.java        1.4
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/BookingListAction.java  1.17
  jboss-seam  seam-gen/src/FormActionBean.java                                            1.3


Commit from mandersen (2006-12-14 06:52 EST)
---------------------

HBX-839: Support persistence unit name in eclipse
HBX-840: Support namingstrategy in eclipse

  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/AbstractConsoleConfigurationPreferences.java         1.8
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/ConsoleConfigurationPreferences.java                 1.6
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/preferences/StandAloneConsoleConfigurationPreferences.java       1.7
  jbosside  hibernatetools/plugins/org.hibernate.eclipse/src/org/hibernate/console/ConsoleConfiguration.java                                        1.15
  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationWizardPage.java      1.27
  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationCreationWizard.java  1.13
  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/EclipseConsoleConfigurationPreferences.java      1.11


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-14 06:55 EST)
------------------------------------------------------

JBCACHE-906

  JBossCache  src/org/jboss/cache/marshall/JBCMethodCall.java  1.4.2.1


Commit from tokada on branch JBossProfiler_Expansion (2006-12-14 06:58 EST)
----------------------------------------------------

Added some functions.

  jboss-profiler  java/webapp/lzx/stacktracediagram.lzx  1.1.2.4


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-14 07:21 EST)
------------------------------------------------------

Fixed numLocksHeld

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.35


Commit from gavin (2006-12-14 07:23 EST)
-----------------

fix minor bugs

  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/AcceptAction.java  1.14
  jboss-seam  examples/dvdstore/web/confirm.xhtml                         1.10
  jboss-seam  examples/dvdstore/web/WEB-INF/incl/cart.xhtml               1.8
  jboss-seam  examples/dvdstore/web/WEB-INF/incl/processmenu.xhtml        1.9
  jboss-seam  examples/dvdstore/web/admin/ship.xhtml                      1.4


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-14 07:39 EST)
------------------------------------------------------

Updated

  JBossCache  docs/Changelog.txt  1.20.2.7


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-14 07:51 EST)
------------------------------------------------------

Updated the way nodes are marked for removal (API stuff)

  JBossCache  src/org/jboss/cache/TreeCache.java                                1.195.2.36
  JBossCache  src/org/jboss/cache/DataNode.java                                 1.15.2.1
  JBossCache  src/org/jboss/cache/Node.java                                     1.38.2.4
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java  1.20.2.8


Commit from gavin (2006-12-14 07:56 EST)
-----------------

fix

  jboss-seam  examples/dvdstore/web/admin/accept.xhtml  1.4


Commit from gavin (2006-12-14 08:08 EST)
-----------------

use new jBPM APIs
also eliminate jbpmContext.getSession().clear(), which may break stuff

  jboss-seam  src/main/org/jboss/seam/core/BusinessProcess.java          1.14
  jboss-seam  src/main/org/jboss/seam/core/ManagedJbpmContext.java       1.21
  jboss-seam  src/main/org/jboss/seam/core/PooledTask.java               1.15
  jboss-seam  src/main/org/jboss/seam/core/PooledTaskInstanceList.java   1.8
  jboss-seam  src/main/org/jboss/seam/core/ProcessInstance.java          1.19
  jboss-seam  src/main/org/jboss/seam/core/TaskInstance.java             1.18
  jboss-seam  src/main/org/jboss/seam/core/TaskInstanceList.java         1.14
  jboss-seam  src/main/org/jboss/seam/core/TaskInstanceListForType.java  1.13


Commit from gavin (2006-12-14 08:46 EST)
-----------------

upgrade to ajax4jsf 1.0.5

  jboss-seam  examples/jpa/lib/ajax4jsf.jar                        1.3
  jboss-seam  examples/hibernate2/lib/ajax4jsf.jar                 1.3
  jboss-seam  examples/glassfish/lib/ajax4jsf.jar                  1.3
  jboss-seam  examples/booking/resources/WEB-INF/lib/ajax4jsf.jar  1.6


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-14 09:29 EST)
------------------------------------------------------

Added test

+ JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java  1.1.4.2


Commit from msurtani (2006-12-14 09:38 EST)
--------------------

Added more in-depth tests

+ JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java  1.2


Commit from mculpepper (2006-12-14 11:16 EST)
----------------------

making a fix to the product build so configuring a product build without the "core" builder will work correctly

  jbosside  releng/org.jboss.ide.eclipse.releng/builders/product/productBuild.xml  1.42


Commit from tdiesler (2006-12-14 11:37 EST)
--------------------

URL: https://svn.jboss.org/repos/jbossws/trunk
Repository Root: https://svn.jboss.org/repos/jbossws
Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
Revision: 1653
Node Kind: directory
Schedule: normal
Last Changed Author: thomas.diesler at jboss.com
Last Changed Rev: 1653
Last Changed Date: 2006-12-14 16:56:18 +0100 (Thu, 14 Dec 2006)

  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar                1.31
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar                 1.30
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar                  1.31
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar              1.42
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar   1.4
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar  1.4
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.deployer                1.3
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar                     1.42


Commit from msurtani (2006-12-14 12:18 EST)
--------------------

The beginnings of porting JBCACHE-871 and JBCACHE-875 as well as rearranging the Node/Cache object model to something sensible

  JBossCache  src/org/jboss/cache/TreeCacheProxyImpl.java                                        1.54
  JBossCache  src/org/jboss/cache/TransactionEntry.java                                          1.17
  JBossCache  src/org/jboss/cache/TreeCache.java                                                 1.292
- JBossCache  src/org/jboss/cache/ExtendedTreeCacheListener.java                                 1.4
  JBossCache  src/org/jboss/cache/TreeNode.java                                                  1.30
  JBossCache  src/org/jboss/cache/AbstractNode.java                                              1.23
  JBossCache  src/org/jboss/cache/RegionManager.java                                             1.16
  JBossCache  src/org/jboss/cache/NodeImpl.java                                                  1.25
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java  1.10
  JBossCache  tests/functional/org/jboss/cache/transaction/TransactionTest.java                  1.19
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferGenerator.java                      1.4
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferManager.java                        1.17
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java               1.6
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferIntegrator.java                     1.5
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java              1.7
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                              1.31
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNode.java                                  1.17
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java                   1.37
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java                    1.36


Commit from msurtani (2006-12-14 12:52 EST)
--------------------

Tests fixed to be compliant with JBCACHE-871 and JBCACHE-875

  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java  1.11
  JBossCache  tests/functional/org/jboss/cache/transaction/PrepareTxTest.java                    1.4
  JBossCache  tests/functional/org/jboss/cache/transaction/DeadlockTest.java                     1.7
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java           1.5
  JBossCache  tests/functional/org/jboss/cache/transaction/SuspendTxTest.java                    1.3


Commit from gzamarreno (2006-12-14 13:52 EST)
----------------------

[JBCACHE-879] drop table set to false in cache-jdbc.properties. Otherwise JDBCCacheLoaderPerfTest.tesGet() won't get anything.
cache.jdbc.table.drop added to JDBCCacheLoaderPerfTest.configureCache(). In tearDown() we evict cache not remove otherwise jdbc data is lost. results of get and remove operations are tested for not null.

  JBossCache  etc/cache-jdbc.properties                                       1.5
  JBossCache  tests/perf/org/jboss/cache/loader/JDBCCacheLoaderPerfTest.java  1.9


Commit from gavin (2006-12-14 14:33 EST)
-----------------

fix validation

  jboss-seam  examples/hibernate2/resources/glassfish/components.xml  1.3
  jboss-seam  examples/hibernate2/resources/weblogic/components.xml   1.3


Commit from rawb (2006-12-14 14:34 EST)
----------------

flickering view caused by input being set all over the place. Had to be remedied. It's possible this change breaks something else which depended on that behavior, but if it does I'll find it ;)

Also, API change which allows removal and addition of items without doing a tree refresh  (more efficient)

  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/Messages.properties                                        1.15
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/InactiveExtensionViewProvider.java  1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java    1.5
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java            1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/ConvertNodeToXPathDialog.java                      1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/preferencepages/ViewPreferencePage.java                    1.8
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/extensions/JBossServerViewExtension.java      1.4
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java                        1.5
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerView.java                          1.5
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java                   1.4


Commit from gavin (2006-12-14 14:39 EST)
-----------------

fix probs in doc

  jboss-seam  doc/reference/en/modules/components.xml  1.51
  jboss-seam  doc/reference/en/modules/concepts.xml    1.47
  jboss-seam  doc/reference/en/modules/framework.xml   1.13


Commit from sbryzak2 (2006-12-14 23:13 EST)
--------------------

implemented page-based security constraints

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java           1.26
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java  1.4
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConstraint.java     1.3
  jboss-seam  src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java     1.13


Commit from gavin (2006-12-14 23:42 EST)
-----------------

fix JBSEAM-597

  jboss-seam  src/main/org/jboss/seam/components-1.1.xsd        1.5
  jboss-seam  src/main/org/jboss/seam/init/Initialization.java  1.132


Commit from gavin (2006-12-15 00:45 EST)
-----------------

better behavior in exception cases

  jboss-seam  src/main/org/jboss/seam/contexts/PassivatedEntity.java  1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061215/554227f7/attachment.html 

From gavin.king at jboss.com  Fri Dec 15 01:01:15 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 01:01:15 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts   ...
Message-ID: <E1Gv68B-0005rd-A5@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 01:01:15

  Modified:    src/main/org/jboss/seam/contexts   EntityBean.java
                        PassivatedEntity.java
  Log:
  better handling when tx rolls back
  
  Revision  Changes    Path
  1.4       +6 -3      jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- EntityBean.java	13 Dec 2006 10:09:12 -0000	1.3
  +++ EntityBean.java	15 Dec 2006 06:01:15 -0000	1.4
  @@ -29,11 +29,14 @@
      {
         if (passivatedEntity==null)
         {
  +         if ( !PassivatedEntity.isTransactionMarkedRollback() )
  +         {
            passivatedEntity = PassivatedEntity.createPassivatedEntity(instance, null);
            if (passivatedEntity!=null)
            {
               instance = null;
            }
  +         }
            return true;
         }
         else
  
  
  
  1.3       +13 -0     jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivatedEntity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PassivatedEntity.java	15 Dec 2006 05:45:36 -0000	1.2
  +++ PassivatedEntity.java	15 Dec 2006 06:01:15 -0000	1.3
  @@ -12,6 +12,7 @@
   import org.jboss.seam.Seam;
   import org.jboss.seam.core.PersistenceContexts;
   import org.jboss.seam.persistence.PersistenceProvider;
  +import org.jboss.seam.util.Transactions;
   
   public class PassivatedEntity implements Serializable
   {
  @@ -128,4 +129,16 @@
         return null;
      }
      
  +   public static boolean isTransactionMarkedRollback()
  +   {
  +      try
  +      {
  +         return Transactions.isTransactionMarkedRollback();
  +      }
  +      catch (Exception e)
  +      {
  +         return false;
  +      }
  +   }
  +   
   }
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Fri Dec 15 01:01:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 01:01:17 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1Gv68D-0005rm-Ja@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 01:01:17

  Modified:    src/main/org/jboss/seam/interceptors 
                        ManagedEntityIdentityInterceptor.java
  Log:
  better handling when tx rolls back
  
  Revision  Changes    Path
  1.16      +9 -6      jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedEntityIdentityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- ManagedEntityIdentityInterceptor.java	13 Dec 2006 04:54:19 -0000	1.15
  +++ ManagedEntityIdentityInterceptor.java	15 Dec 2006 06:01:17 -0000	1.16
  @@ -28,7 +28,7 @@
      
      //TODO: cache much more - the list of fields, PassivatedEntity obects, etc
      
  -   private List<PassivatedEntity> list = new ArrayList<PassivatedEntity>();
  +   private List<PassivatedEntity> passivatedEntities = new ArrayList<PassivatedEntity>();
      
      @AroundInvoke
      public Object aroundInvoke(InvocationContext ctx) throws Exception
  @@ -40,9 +40,12 @@
         }
         finally
         {
  +         if ( !PassivatedEntity.isTransactionMarkedRollback() )
  +         {
            entityRefsToIds(ctx);
         }
      }
  +   }
      
      public void entityRefsToIds(InvocationContext ctx) throws Exception
      {      
  @@ -68,7 +71,7 @@
                        PassivatedEntity pi = PassivatedEntity.createPassivatedEntity( value, field.getName() );
                        if (pi!=null)
                        {
  -                        list.add(pi);
  +                        passivatedEntities.add(pi);
                           Reflections.set(field, bean, null);
                        }
                     }
  @@ -80,11 +83,11 @@
   
      public void entityIdsToRefs(InvocationContext ctx) throws Exception
      {
  -      if ( list.size()>0 )
  +      if ( passivatedEntities.size()>0 )
         {
            Object bean = ctx.getTarget();
            Class beanClass = bean.getClass();
  -         for (PassivatedEntity pe: list)
  +         for (PassivatedEntity pe: passivatedEntities)
            {
               Object reference = pe.toEntityReference();
               if (reference!=null)
  @@ -101,7 +104,7 @@
                  }
               }
            }
  -         list.clear();
  +         passivatedEntities.clear();
         }
      
   }
  
  
  


From t2-okada at nri.co.jp  Fri Dec 15 01:14:44 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Fri, 15 Dec 2006 01:14:44 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/lzx    ...
Message-ID: <E1Gv6LE-0006Dg-B6@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/15 01:14:44

  Modified:    java/webapp/lzx    Tag: JBossProfiler_Expansion
                        stacktracediagram.lzx settingdialog.lzx
                        webapplicationanalyzer.lzx
  Log:
  Added a function of setting categories of the webapp analyzer.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.5   +47 -19    jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: stacktracediagram.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -b -r1.1.2.4 -r1.1.2.5
  --- stacktracediagram.lzx	14 Dec 2006 11:58:48 -0000	1.1.2.4
  +++ stacktracediagram.lzx	15 Dec 2006 06:14:44 -0000	1.1.2.5
  @@ -134,8 +134,10 @@
       <event name="onselect"/>
       
       <attribute name="_lane" value="lane" when="once"/>
  -    <attribute name="baseheight" type="number" value="400"/>
  -    <attribute name="baseheightoffset" type="number" value="40"/>
  +    
  +    <!-- pixel per second -->
  +    <attribute name="baseheight" type="number" value="500"/>
  +    <attribute name="baseheightoffset" type="number" value="20"/>
       <attribute name="selfmessagewidth" type="number" value="20"/>
       <attribute name="selfmessageheight" type="number" value="10"/>
       <attribute name="ignorezerovalue" type="boolean" value="true"/>
  @@ -175,6 +177,7 @@
           text.fullname = name;
           ]]>
         </method>
  +      <!-- TODO: Correct sending messages and receiving messages. -->
         <method name="strokeSelfMessage" args="beginx, beginy, height, id, name, offset, message">
           <![CDATA[
           //var endy = beginy;
  @@ -205,19 +208,44 @@
       
       <handler name="ondata" args="d">
         <![CDATA[
  -      var beginTimestamp = d.childNodes[0].getAttr(timestampattr);
  -      var totalElapsedTime = d.childNodes[0].getAttr(valueattr);
  -      this.baseheight = 1/totalElapsedTime * (700000000*parent.height);
  -      this.height = (totalElapsedTime/1000000000) * this.baseheight + baseheightoffset*2 + this.padding*2;
  -      this.lanes.height = this.height;
  +      if(d.childNodes==null) return;
  +      
  +      var beginTimestamp = 0;
  +      var totalElapsedTime = 0;
  +      var maxActivatedName = "";
  +      for(var i=0; i<d.childNodes.length; i++) {
  +        var timestamp = new Number(d.childNodes[i].getAttr(timestampattr));
  +        var elapsedTime = new Number(d.childNodes[i].getAttr(valueattr));
  +        var name = d.childNodes[i].getAttr(nameattr);
  +        if(beginTimestamp==0 || timestamp<beginTimestamp) {
  +          beginTimestamp = timestamp;
  +        }
  +        if(elapsedTime > totalElapsedTime) {
  +          if(name == maxActivatedName) {
  +            totalElapsedTime += elapsedTime;
  +          }else {
  +            totalElapsedTime = elapsedTime;
  +            maxActivatedName = name;
  +          }
  +        }
  +      }
  +      
  +      // Calculates the total height:
  +      //   total height = (total elapsed time[sec]) * (base height) + 
  +      //                  (height of object box) + 
  +      //                  (baseheightoffset(top/bottom)) + 
  +      //                  (padding(top/bottom))
  +      this.height = (totalElapsedTime/1000000000) * this.baseheight + 57 + this.baseheightoffset*2 + this.padding*2;
  +      this.lanes.height = this.height - this.padding*2;
  +      this.drawview.height = this.height - (this.padding+2)*2;
         
         var messages = new Array();
         
         for(var i=0; i<d.childNodes.length; i++) {
           var childNode = d.childNodes[i];
           var id = childNode.getAttr(idattr);
  -        var timestamp = childNode.getAttr(timestampattr);
  -        var elapsedTime = childNode.getAttr(valueattr);
  +        var timestamp = new Number(childNode.getAttr(timestampattr));
  +        var elapsedTime = new Number(childNode.getAttr(valueattr));
           if(ignorezerovalue && elapsedTime==0) continue;
           var name = childNode.getAttr(nameattr);
           
  @@ -236,7 +264,7 @@
             updateLane = new _lane(this.lanes, {objectname: className});
           }
           
  -        var beginPixel = ((timestamp-beginTimestamp)/1000) * this.baseheight + baseheightoffset; // msec
  +        var beginPixel = ((timestamp-beginTimestamp)/1000) * this.baseheight + this.baseheightoffset; // msec
           var elapsedPixel = (elapsedTime/1000000000) * this.baseheight; // nsec
           
           var callerClassName = null;
  @@ -252,13 +280,13 @@
             }
           }
           
  -        var message = new Array();
  -        message.push("ID : "+id);
  -        message.push("Class Name : "+className);
  -        message.push("Method Name : "+methodName);
  -        message.push("Caller Class Name : "+callerClassName);
  -        message.push("Caller Method Name : "+callerMethodName);
  -        message.push("Elapsed Time : "+elapsedTime);
  +        var detail = new Array();
  +        detail.push("ID : "+id);
  +        detail.push("Class Name : "+className);
  +        detail.push("Method Name : "+methodName);
  +        detail.push("Caller Class Name : "+callerClassName);
  +        detail.push("Caller Method Name : "+callerMethodName);
  +        detail.push("Elapsed Time : "+elapsedTime);
           
           if(callerClassName==updateLane.objectname) {
             this.drawview.strokeSelfMessage(updateLane.jointpointright,
  @@ -267,9 +295,9 @@
                                             id,
                                             name,
                                             updateLane.activationwidth,
  -                                          message);
  +                                          detail);
           }else {
  -          updateLane.setActivation(beginPixel, elapsedPixel, message);
  +          updateLane.setActivation(beginPixel, elapsedPixel, detail);
             if(i!=0) {
               messages.push({lane:updateLane, caller:callerClassName, begin:beginPixel, elapsed:elapsedPixel, id:id, method:name});
             }
  
  
  
  1.1.2.5   +36 -10    jboss-profiler/java/webapp/lzx/Attic/settingdialog.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: settingdialog.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/settingdialog.lzx,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -b -r1.1.2.4 -r1.1.2.5
  --- settingdialog.lzx	12 Dec 2006 08:28:43 -0000	1.1.2.4
  +++ settingdialog.lzx	15 Dec 2006 06:14:44 -0000	1.1.2.5
  @@ -47,6 +47,7 @@
               <view>
                 <simplelayout axis="x" spacing="4"/>
                 <text valign="middle">Metric Type</text>
  +              <view width="57"/>
                 <combobox name="metricName" width="200" editable="false">
                   <textlistitem text="Real time" value="0"/>
                   <textlistitem text="CPU time" value="1"/>
  @@ -63,12 +64,30 @@
               <view>
                 <simplelayout axis="x" spacing="4"/>
                 <text valign="middle">Metric Type</text>
  +              <view width="57"/>
                 <combobox name="metricName" width="200" editable="false">
                   <textlistitem text="Real time" value="0" selected="true"/>
                   <textlistitem text="CPU time" value="1"/>
                   <textlistitem text="CPU time (user process only)" value="2"/>
                 </combobox>
               </view>
  +            <view>
  +              <simplelayout axis="x" spacing="4"/>
  +              <text valign="middle">Http Requests Category</text>
  +              <edittext name="category" width="200" height="22">Http Requests</edittext>
  +            </view>
  +            <view>
  +              <simplelayout axis="x" spacing="4"/>
  +              <text valign="middle">Beans Category</text>
  +              <view width="36"/>
  +              <edittext name="category" width="200" height="22">Beans</edittext>
  +            </view>
  +            <view>
  +              <simplelayout axis="x" spacing="4"/>
  +              <text valign="middle">Data Access Category</text>
  +              <view width="6"/>
  +              <edittext name="category" width="200" height="22">Data Access</edittext>
  +            </view>
             </view>
           </borderedpane>
         </tabpane>
  @@ -117,6 +136,7 @@
               <simplelayout axis="x"/>
               <checkbox name="enabled" y="4">
                 <handler name="onclick">
  +                if(this.getValue()) {
                   var currentDayStr = "";
                   var currentDate = new Date();
                   currentDayStr += currentDate.getMonth()+1;
  @@ -127,6 +147,12 @@
                   parent.values.fromTime.setText("0:0:0");
                   parent.values.toTime.setText("0:0:0");
                   LzFocus.setFocus(parent.values.fromDate);
  +                }else {
  +                  parent.values.fromDate.setText("");
  +                  parent.values.toDate.setText("");
  +                  parent.values.fromTime.setText("");
  +                  parent.values.toTime.setText("");
  +                }
                 </handler>
               </checkbox>
               <view name="values" placement="contents">
  
  
  
  1.1.2.4   +3 -3      jboss-profiler/java/webapp/lzx/Attic/webapplicationanalyzer.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: webapplicationanalyzer.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/webapplicationanalyzer.lzx,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- webapplicationanalyzer.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  +++ webapplicationanalyzer.lzx	15 Dec 2006 06:14:44 -0000	1.1.2.4
  @@ -112,15 +112,15 @@
         this.currentId = id;
         var categories = null;
         if(index==0) {
  -        categories = "Http Requests";
  +        categories = webappAnalyzerSettings.subviews[1].category.getValue();
           stackTraceDiagram.remove();
           dataAccessStatistics.remove();
         }else if(index==1) {
  -        categories = "Http Requests, Beans";
  +        categories = webappAnalyzerSettings.subviews[2].category.getValue();
           httpRequestStatistics.remove();
           dataAccessStatistics.remove();
         }else if(index==2) {
  -        categories = "Data Access";
  +        categories = webappAnalyzerSettings.subviews[3].category.getValue();
           httpRequestStatistics.remove();
           stackTraceDiagram.remove();
         }
  
  
  


From t2-okada at nri.co.jp  Fri Dec 15 01:21:12 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Fri, 15 Dec 2006 01:21:12 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector
	...
Message-ID: <E1Gv6RU-0006KQ-0p@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/15 01:21:12

  Modified:    java/src/expansion/org/jboss/profiler/exp/agent/collector 
                        Tag: JBossProfiler_Expansion
                        ThreadMetricCollector.java
  Log:
  Modified an implementation concerned the servlet.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.5   +6 -16     jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/Attic/ThreadMetricCollector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThreadMetricCollector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/Attic/ThreadMetricCollector.java,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -b -r1.1.2.4 -r1.1.2.5
  --- ThreadMetricCollector.java	13 Dec 2006 10:11:42 -0000	1.1.2.4
  +++ ThreadMetricCollector.java	15 Dec 2006 06:21:11 -0000	1.1.2.5
  @@ -187,24 +187,14 @@
               else if(methodName.contains("$")) continue;
               // Ignores JBoss Profiler classes.
               else if(className.startsWith("org.jboss.profiler.exp.agent.interceptor")) continue;
  -            // Ignores Java API classes
  -            else if(className.startsWith("java") || className.startsWith("sun")) continue;
               // Retrieve servlet class.
  -            else if(methodName.equals("doGet") || methodName.equals("doPost") || methodName.equals("service")) {
  -                for(int j=i+1; j<stackTrace.length; j++) {
  -                    String c = stackTrace[j].getClassName();
  -                    if(className.equals(c)) continue;
  -                    else if(c.equals("javax.servlet.http.HttpServlet") || c.equals("javax.servlet.GenericServlet")) {
  +            else if(className.equals("javax.servlet.http.HttpServlet") || className.equals("javax.servlet.GenericServlet")) {
                           result = "<servlet>";
                           break;
                       }
  +            // Ignores Java API classes
  +            else if(className.startsWith("java") || className.startsWith("sun")) continue;
                       else {
  -                        result = className+"."+methodName;
  -                        break;
  -                    }
  -                }
  -                break;
  -            }else {
                   // Ignores framework classes.
                   boolean ignore = false;
                   for(String expression : config.getFrameworkExpressionSet()) {
  
  
  


From t2-okada at nri.co.jp  Fri Dec 15 01:41:33 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Fri, 15 Dec 2006 01:41:33 -0500
Subject: [jboss-cvs] jboss-profiler/exsamples/jboss-profiler.aop/META-INF ...
Message-ID: <E1Gv6lB-0006ev-9b@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/15 01:41:33

  Modified:    exsamples/jboss-profiler.aop/META-INF  Tag:
                        JBossProfiler_Expansion jboss-aop.xml
  Log:
  
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.6   +4 -0      jboss-profiler/exsamples/jboss-profiler.aop/META-INF/Attic/jboss-aop.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-aop.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/exsamples/jboss-profiler.aop/META-INF/Attic/jboss-aop.xml,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -b -r1.1.2.5 -r1.1.2.6
  --- jboss-aop.xml	14 Dec 2006 06:38:16 -0000	1.1.2.5
  +++ jboss-aop.xml	15 Dec 2006 06:41:33 -0000	1.1.2.6
  @@ -70,6 +70,10 @@
     
     <!-- ##### JBoss Profiler : Pointcuts ##### -->
     
  +  <bind pointcut="execution(* org.jboss.profiler.exp.test.target.servlet.*->*(..))">
  +    <stack-ref name="StatisticsInterceptors"/>
  +    <interceptor-ref name="AnalyzeInterceptor"/>
  +  </bind>
     <bind pointcut="execution(* org.jboss.profiler.exp.test.target.logic.*->*(..))">
       <stack-ref name="StatisticsInterceptors"/>
       <interceptor-ref name="AnalyzeInterceptor"/>
  
  
  


From gavin.king at jboss.com  Fri Dec 15 01:50:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 01:50:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gv6u1-0006ll-2m@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 01:50:41

  Modified:    src/main/org/jboss/seam/core  Validation.java
  Log:
  JBSEAM-580
  
  Revision  Changes    Path
  1.5       +17 -6     jboss-seam/src/main/org/jboss/seam/core/Validation.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Validation.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Validation.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- Validation.java	24 Nov 2006 23:15:17 -0000	1.4
  +++ Validation.java	15 Dec 2006 06:50:41 -0000	1.5
  @@ -57,15 +57,26 @@
   
      public InvalidValue[] validate(FacesContext context, String propertyExpression, Object value)
      {
  -      int sep = propertyExpression.lastIndexOf('.');
  -      if (sep<=0) 
  +      int dot = propertyExpression.lastIndexOf('.');
  +      int bracket = propertyExpression.lastIndexOf('[');
  +      if (dot<=0 && bracket<=0) 
         {
  -         throw new RuntimeException("not an attribute value binding: " + propertyExpression);
  +         return new InvalidValue[0];
  +      }
  +      String componentName;
  +      String propertyName;
  +      if (dot>bracket)
  +      {
  +         componentName = propertyExpression.substring(2, dot);
  +         propertyName = propertyExpression.substring( dot+1, propertyExpression.length()-1 );
  +      }
  +      else
  +      {
  +         componentName = propertyExpression.substring(2, bracket);
  +         propertyName = propertyExpression.substring( bracket+1, propertyExpression.length()-2 );
         }
  -      String componentName = propertyExpression.substring(2, sep);
  -      String modelExpression = propertyExpression.substring(0, sep) + '}';
  -      String propertyName = propertyExpression.substring( modelExpression.length(), propertyExpression.length()-1 );
      
  +      String modelExpression = propertyExpression.substring(0, dot) + '}';
         Object model = context.getApplication().createValueBinding(modelExpression).getValue(context);
         ClassValidator validator = getValidator( model.getClass(), componentName );    
         return validator.getPotentialInvalidValues(propertyName, value);
  
  
  


From gavin.king at jboss.com  Fri Dec 15 02:18:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 02:18:18 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf  ...
Message-ID: <E1Gv7Kk-0007PN-LW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 02:18:18

  Modified:    src/main/org/jboss/seam/jsf  SeamELResolver.java
  Log:
  JBSEAM-478
  
  Revision  Changes    Path
  1.4       +61 -1     jboss-seam/src/main/org/jboss/seam/jsf/SeamELResolver.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamELResolver.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamELResolver.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SeamELResolver.java	30 Nov 2006 02:09:11 -0000	1.3
  +++ SeamELResolver.java	15 Dec 2006 07:18:18 -0000	1.4
  @@ -1,9 +1,12 @@
   package org.jboss.seam.jsf;
   
  +import java.util.Collection;
   import java.util.Iterator;
  +import java.util.Map;
   
   import javax.el.ELContext;
   import javax.el.ELResolver;
  +import javax.faces.model.DataModel;
   
   import org.jboss.seam.Component;
   import org.jboss.seam.core.Init;
  @@ -47,6 +50,62 @@
            }
            return result;
         }
  +      else if (base instanceof DataModel)
  +      {
  +         if ( "size".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (DataModel) base ).getRowCount();
  +         }
  +         else if ( "empty".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (DataModel) base ).getRowCount()==0;
  +         }
  +         else
  +         {
  +            return null;
  +         }
  +      }
  +      else if (base instanceof Collection)
  +      {
  +         if ( "size".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (Collection) base ).size();
  +         }
  +         else
  +         {
  +            return null;
  +         }
  +      }
  +      else if (base instanceof Map)
  +      {
  +         if ( "size".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (Map) base ).size();
  +         }
  +         else if ( "values".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (Map) base ).values();
  +         }
  +         else if ( "keySet".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (Map) base ).keySet();
  +         }
  +         else if ( "entrySet".equals(property) )
  +         {
  +            context.setPropertyResolved(true);
  +            return ( (Map) base ).entrySet();
  +         }
  +         else
  +         {
  +            return null;
  +         }
  +      }
         else
         {
            return null;
  @@ -56,7 +115,8 @@
      @Override
      public boolean isReadOnly(ELContext context, Object base, Object property)
      {
  -      return false;
  +      return base!=null && 
  +            ( (base instanceof DataModel) || (base instanceof Collection) || (base instanceof Map) );
      }
   
      @Override
  
  
  


From gavin.king at jboss.com  Fri Dec 15 03:18:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 03:18:10 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gv8Gg-00005N-LC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 03:18:10

  Modified:    seam-gen  build.xml
  Log:
  JBSEAM-598
  
  Revision  Changes    Path
  1.50      +31 -18    jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.49
  retrieving revision 1.50
  diff -u -b -r1.49 -r1.50
  --- build.xml	10 Dec 2006 16:53:28 -0000	1.49
  +++ build.xml	15 Dec 2006 08:18:10 -0000	1.50
  @@ -265,6 +265,11 @@
                      message="Enter database password [${hibernate.connection.password}]" 
                 defaultvalue="${hibernate.connection.password}"/>
                   
  +        <property name="hibernate.default_schema" value=""/>
  +        <input addproperty="hibernate.default_schema.new" 
  +                   message="Enter the database schema name (it is OK to leave this blank) [${hibernate.default_schema}]" 
  +              defaultvalue="${hibernate.default_schema}"/>
  +                
           <property name="database.exists" value="n"/>
           <input addproperty="database.exists.new" 
                      message="Are you working with tables that already exist in the database? [${database.exists}] "
  @@ -273,10 +278,17 @@
   
           <property name="database.drop" value="n"/>
           <input addproperty="database.drop.new" 
  -                   message="Do you want to init the database tables everytime you deploy the app (e.g., to use import.sql) and drop the tables when you undeploy (useful in development)? [${database.drop}] "
  +                   message="Do you want to drop and recreate the database tables and data in import.sql each time you deploy? [${database.drop}] "
           	     validargs="y,n,"
                 defaultvalue="${database.drop}"/>
   
  +    	<condition property="hibernate.default_schema.key" value="hibernate.default_schema">
  +    	    <not><equals arg1="${hibernate.default_schema.new}" arg2=""/></not>
  +    	</condition>
  +    	<condition property="hibernate.default_schema.key" value="hibernate.default_schema.null">
  +    	    <equals arg1="${hibernate.default_schema.new}" arg2=""/>
  +    	</condition>
  +
           <propertyfile file="build.properties">
               <entry key="workspace.home" value="${workspace.home.new}"/>
               <entry key="project.name" value="${project.name.new}"/>
  @@ -293,7 +305,8 @@
               <entry key="hibernate.connection.url" value="${hibernate.connection.url.new}"/>
               <entry key="hibernate.connection.username" value="${hibernate.connection.username.new}"/>
               <entry key="hibernate.connection.password" value="${hibernate.connection.password.new}"/>
  -            <entry key="driver.jar" value="${driver.jar.new}"/>
  +            <entry key="hibernate.connection.password" value="${hibernate.connection.password.new}"/>
  +            <entry key="${hibernate.default_schema.key}" value="${hibernate.default_schema.new}"/>
           </propertyfile>
       	
       	<echo message="Installing JDBC driver jar to JBoss server"/>
  
  
  


From gavin.king at jboss.com  Fri Dec 15 03:32:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 03:32:39 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gv8Uh-0000Kr-Ci@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 03:32:39

  Modified:    seam-gen  build.xml
  Log:
  oops
  
  Revision  Changes    Path
  1.51      +2 -1      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -b -r1.50 -r1.51
  --- build.xml	15 Dec 2006 08:18:10 -0000	1.50
  +++ build.xml	15 Dec 2006 08:32:39 -0000	1.51
  @@ -300,6 +300,7 @@
               <entry key="database.type" value="${database.type.new}"/>
           	<entry key="database.exists" value="${database.exists.new}"/>
           	<entry key="database.drop" value="${database.drop.new}"/>
  +        	<entry key="driver.jar" value="${driver.jar.new}"/>
               <entry key="hibernate.dialect" value="${hibernate.dialect.new}"/>
               <entry key="hibernate.connection.driver_class" value="${hibernate.connection.driver_class.new}"/>
               <entry key="hibernate.connection.url" value="${hibernate.connection.url.new}"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 03:59:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 03:59:45 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1798 - in trunk: . tests
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
	tests/src/org/jboss/test/messaging/tools
	tests/src/org/jboss/test/messaging/tools/ant
	tests/src/org/jboss/test/messaging/tools/jmx
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
	tests/src/org/jboss/test/messaging/tools/jndi
	tests/src/org/jboss/test/messaging/util
Message-ID: <E1Gv8uv-0000jk-N5@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-15 03:59:37 -0500 (Fri, 15 Dec 2006)
New Revision: 1798

Added:
   trunk/tests/src/org/jboss/test/messaging/tools/ant/JUnitTestSuiteListener.java
Modified:
   trunk/messaging.iml
   trunk/messaging.ipr
   trunk/tests/build.sh
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
   trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
Log:
Fixed a test server spawning bug that would lock up ant; at the end of the testsuite, all newly spawned servers are killed automatically

Modified: trunk/messaging.iml
===================================================================
--- trunk/messaging.iml	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/messaging.iml	2006-12-15 08:59:37 UTC (rev 1798)
@@ -45,6 +45,8 @@
     <orderEntry type="library" name="jboss-jca" level="project" />
     <orderEntry type="library" name="jboss-local-jdbc" level="project" />
     <orderEntry type="library" name="jms-ra" level="project" />
+    <orderEntry type="library" name="ant" level="project" />
+    <orderEntry type="library" name="ant-junit" level="project" />
     <orderEntryProperties />
   </component>
   <component name="VcsManagerConfiguration">

Modified: trunk/messaging.ipr
===================================================================
--- trunk/messaging.ipr	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/messaging.ipr	2006-12-15 08:59:37 UTC (rev 1798)
@@ -264,7 +264,9 @@
         <root url="jar://$PROJECT_DIR$/thirdparty/junit/lib/junit.jar!/" />
       </CLASSES>
       <JAVADOC />
-      <SOURCES />
+      <SOURCES>
+        <root url="jar://C:/work/src/junit3.8.1/src.jar!/" />
+      </SOURCES>
     </library>
     <library name="hsqldb">
       <CLASSES>
@@ -336,6 +338,25 @@
       <JAVADOC />
       <SOURCES />
     </library>
+    <library name="ant-junit">
+      <CLASSES>
+        <root url="jar://C:/apache-ant-1.6.5/lib/ant-junit.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES>
+        <root url="file://C:/work/src/apache-ant-1.6.5/src/main" />
+      </SOURCES>
+    </library>
+    <library name="ant">
+      <CLASSES>
+        <root url="jar://C:/apache-ant-1.6.5/lib/ant.jar!/" />
+      </CLASSES>
+      <JAVADOC />
+      <SOURCES>
+        <root url="file://C:/apache-ant-1.6.5/lib" />
+        <root url="file://C:/work/src/apache-ant-1.6.5/src/main" />
+      </SOURCES>
+    </library>
   </component>
   <component name="uidesigner-configuration">
     <option name="INSTRUMENT_CLASSES" value="true" />

Modified: trunk/tests/build.sh
===================================================================
--- trunk/tests/build.sh	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/build.sh	2006-12-15 08:59:37 UTC (rev 1798)
@@ -3,7 +3,7 @@
 
 reldir=`dirname $0`
 
-#export ANT_OPTS="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=ant"
+#export ANT_OPTS="-Xmx1024m -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=ant"
 export ANT_OPTS=-Xmx1024m
 $ANT_HOME/bin/ant -lib $reldir/../thirdparty/junit/lib/junit.jar "$@"
 

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/build.xml	2006-12-15 08:59:37 UTC (rev 1798)
@@ -715,6 +715,9 @@
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
          <sysproperty key="test.clustered" value="true"/>
          <jvmarg value="-Xmx512M"/>
+         <!--
+         <jvmarg line="-Xmx512M -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=n,address=antjunit"/>
+          -->
 
          <classpath>
             <path refid="test.execution.classpath"/>
@@ -744,11 +747,19 @@
                     haltonfailure="${junit.batchtest.haltonfailure}"
                     haltonerror="${junit.batchtest.haltonerror}">
             <formatter type="plain" usefile="${junit.formatter.usefile}"/>
+            <!--
+                 I needed a way to intercept the end of a forked ant JUnit test run, in order to
+                 perform clean-up, and this is it: register a JUnitTestSuiteListener as a JUnit
+                 batchtest formatter, and it will get notified on a endTestSuite() event.
+            -->
+            <formatter classname="org.jboss.test.messaging.tools.ant.JUnitTestSuiteListener"/>
+
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/HATest.class"/>
                <!--
-               <include name="**/jms/clustering/SimpleClusteringTest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
+                <include name="org/jboss/test/messaging/util/ServerManagementTest.class"/>
                -->
+               <include name="**/jms/clustering/HATest.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -44,7 +44,7 @@
    {
       try
       {
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -64,7 +64,7 @@
 
       try
       {
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
          log.info("Server 0 started");
 
@@ -72,7 +72,7 @@
 
          log.info("NotificationListener added to server 0");
 
-         ServerManagement.start("all", 1);
+         ServerManagement.start(1, "all");
 
          log.info("Blocking to receive notification ...");
 
@@ -99,14 +99,14 @@
    {
       try
       {
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
 
-         ServerManagement.start("all", 1);
+         ServerManagement.start(1, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -133,14 +133,14 @@
    {
       try
       {
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
 
-         ServerManagement.start("all", 1);
+         ServerManagement.start(1, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -154,7 +154,7 @@
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
 
-         ServerManagement.start("all", 3);
+         ServerManagement.start(3, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -194,9 +194,9 @@
       {
          // Start with a 3 node cluster
 
-         ServerManagement.start("all", 0);
-         ServerManagement.start("all", 1);
-         ServerManagement.start("all", 2);
+         ServerManagement.start(0, "all");
+         ServerManagement.start(1, "all");
+         ServerManagement.start(2, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -226,7 +226,7 @@
 
          // Reuse the "hollow" RMI server 0 to start another cluster node
 
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -237,7 +237,7 @@
 
          // Reuse the "hollow" RMI server 2 to start another cluster node
 
-         ServerManagement.start("all", 2);
+         ServerManagement.start(1, "all");
 
          view = ServerManagement.getServer(2).getNodeIDView();
 
@@ -264,8 +264,8 @@
       {
          // Start with a 2 node cluster
 
-         ServerManagement.start("all", 0);
-         ServerManagement.start("all", 1);
+         ServerManagement.start(0, "all");
+         ServerManagement.start(1, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -313,9 +313,9 @@
       {
          // Start with a 3 node cluster
 
-         ServerManagement.start("all", 0);
-         ServerManagement.start("all", 1);
-         ServerManagement.start("all", 2);
+         ServerManagement.start(0, "all");
+         ServerManagement.start(1, "all");
+         ServerManagement.start(2, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -392,7 +392,7 @@
       {
          // Start with a 1 node cluster
 
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
 
@@ -401,8 +401,7 @@
 
          ServerManagement.addNotificationListener(0, postOfficeObjectName, clusterEvent);
 
-         ServerManagement.spawn(10);
-         ServerManagement.start("all", 10);
+         ServerManagement.start(10, "all");
 
          if (!clusterEvent.viewChanged(120000))
          {

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -26,11 +26,11 @@
 import java.util.Set;
 
 import javax.jms.Connection;
-import javax.jms.Message;
 import javax.jms.MessageConsumer;
 import javax.jms.MessageProducer;
 import javax.jms.Session;
 import javax.jms.TextMessage;
+import javax.jms.Message;
 
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
@@ -48,6 +48,7 @@
  *
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -78,89 +79,89 @@
    public void testRoundRobinConnectionCreation() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-      
+
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-      
+
       log.info ("number of delegates = " + delegate.getDelegates().length);
       log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
-      
+
       assertEquals(3, delegate.getDelegates().length);
-      
+
       ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-      
+
       ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-      
+
       ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-      
+
       assertEquals(0, cf1.getServerID());
-      
+
       assertEquals(1, cf2.getServerID());
-      
+
       assertEquals(2, cf3.getServerID());
-      
+
       assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-      
+
       Connection conn1 = null;
-      
+
       Connection conn2 = null;
-      
+
       Connection conn3 = null;
-      
+
       Connection conn4 = null;
-      
+
       Connection conn5 = null;
-      
+
       try
-      {         
+      {
          conn1 = factory.createConnection();  //server 0
-         
+
          conn2 = factory.createConnection();  //server 1
-         
+
          conn3 = factory.createConnection();  //server 2
-         
+
          conn4 = factory.createConnection();  //server 0
-         
+
          conn5 = factory.createConnection();  //server 1
-         
+
          ConnectionState state1 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn1).getDelegate()).getState());
-         
+
          ConnectionState state2 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn2).getDelegate()).getState());
-         
+
          ConnectionState state3 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn3).getDelegate()).getState());
-         
+
          ConnectionState state4 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn4).getDelegate()).getState());
-         
+
          ConnectionState state5 = (ConnectionState)(((DelegateSupport)((JBossConnection)conn5).getDelegate()).getState());
-         
+
          int serverID1 = state1.getServerID();
-         
+
          int serverID2 = state2.getServerID();
-         
+
          int serverID3 = state3.getServerID();
-         
+
          int serverID4 = state4.getServerID();
-         
+
          int serverID5 = state5.getServerID();
-         
+
          log.info("server id 1: " + serverID1);
-         
+
          log.info("server id 2: " + serverID2);
-         
+
          log.info("server id 3: " + serverID3);
-         
+
          log.info("server id 4: " + serverID4);
-         
+
          log.info("server id 5: " + serverID5);
-         
+
          assertEquals(0, serverID1);
-         
+
          assertEquals(1, serverID2);
-         
+
          assertEquals(2, serverID3);
-         
+
          assertEquals(0, serverID4);
-         
+
          assertEquals(1, serverID5);
       }
       finally
@@ -169,376 +170,374 @@
          {
             conn1.close();
          }
-         
+
          if (conn2 != null)
          {
             conn2.close();
          }
-         
+
          if (conn3 != null)
          {
             conn3.close();
          }
-         
+
          if (conn4 != null)
          {
             conn4.close();
          }
-         
+
          if (conn5 != null)
          {
             conn5.close();
          }
       }
-      
+
    }
- 
+
    /*
     * Test that the failover mapping is created correctly and updated properly when nodes leave
     * or join
     */
    public void testDefaultFailoverMap() throws Exception
-   {     
+   {
       {
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-         
+
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
+
          assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
-         
+
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
+
          ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
+
          ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
+
          ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
+
          //The order here depends on the order the servers were started in
-         
+
          //If any servers get stopped and then started then the order will change
-    
+
          log.info("cf1 serverid=" + cf1.getServerID());
-         
+
          log.info("cf2 serverid=" + cf2.getServerID());
-         
+
          log.info("cf3 serverid=" + cf3.getServerID());
-         
-         
+
+
          assertEquals(0, cf1.getServerID());
-         
+
          assertEquals(1, cf2.getServerID());
-         
+
          assertEquals(2, cf3.getServerID());
-         
+
          Map failoverMap = delegate.getFailoverMap();
-         
+
          assertEquals(3, delegates.length);
-         
+
          assertEquals(3, failoverMap.size());
-         
+
          // Default failover policy just chooses the node to the right
-         
+
          assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
-         
+
          assertEquals(cf3.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
-         
+
          assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf3.getServerID()))).intValue());
       }
-      
+
       //Now cleanly stop one of the servers
-            
+
       log.info("************** STOPPING SERVER 0");
       ServerManagement.stop(0);
-      
+
       log.info("server stopped");
-      
+
       assertEquals(2, ServerManagement.getServer(1).getNodeIDView().size());
-      
-      {         
+
+      {
          //Lookup another connection factory
-         
+
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[1].lookup("/ConnectionFactory");
-         
+
          log.info("Got connection factory");
-         
+
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
+
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
+
          Map failoverMap = delegate.getFailoverMap();
-         
+
          log.info("Got failover map");
-         
+
          assertEquals(2, delegates.length);
-         
+
          ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
+
          ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
+
          //Order here depends on order servers were started in
-         
+
          log.info("cf1 serverid=" + cf1.getServerID());
-         
+
          log.info("cf2 serverid=" + cf2.getServerID());
-         
+
          assertEquals(1, cf1.getServerID());
-         
+
          assertEquals(2, cf2.getServerID());
-         
-         
+
+
          assertEquals(2, failoverMap.size());
-         
+
          assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
-         
+
          assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
       }
-      
+
       //Cleanly stop another server
-      
+
       log.info("Server 1 is started: " + ServerManagement.getServer(1).isServerPeerStarted());
-      
+
       ServerManagement.stop(1);
-      
+
       assertEquals(1, ServerManagement.getServer(2).getNodeIDView().size());
-      
-      {         
+
+      {
          //Lookup another connection factory
-         
+
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
-         
+
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
+
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
+
          Map failoverMap = delegate.getFailoverMap();
-         
+
          assertEquals(1, delegates.length);
-         
+
          ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
+
          assertEquals(2, cf1.getServerID());
-         
-         
+
+
          assertEquals(1, failoverMap.size());
-         
+
          assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
       }
-            
+
       //Restart server 0
-      
-      ServerManagement.start("all", 0);
-      
+
+      ServerManagement.start(0, "all");
+
       {
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-         
+
          log.info("Got connection factory");
-         
+
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
+
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
+
          Map failoverMap = delegate.getFailoverMap();
-         
+
          log.info("Got failover map");
-         
+
          assertEquals(2, delegates.length);
-         
+
          ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
+
          ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
+
          log.info("cf1 serverid=" + cf1.getServerID());
-         
+
          log.info("cf2 serverid=" + cf2.getServerID());
-         
+
          assertEquals(0, cf1.getServerID());
-         
+
          assertEquals(2, cf2.getServerID());
-         
-         
+
+
          assertEquals(2, failoverMap.size());
-         
+
          assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
-         
+
          assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
       }
-      
-      
+
+
       //Restart server 1
-      
-      ServerManagement.start("all", 1);
-      
+
+      ServerManagement.start(1, "all");
+
       {
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[1].lookup("/ConnectionFactory");
-         
+
          log.info("Got connection factory");
-         
+
          ClusteredClientConnectionFactoryDelegate delegate =
             (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-         
+
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-         
+
          Map failoverMap = delegate.getFailoverMap();
-         
+
          log.info("Got failover map");
-         
+
          assertEquals(3, delegates.length);
-         
+
          ClientConnectionFactoryDelegate cf1 = delegate.getDelegates()[0];
-         
+
          ClientConnectionFactoryDelegate cf2 = delegate.getDelegates()[1];
-         
+
          ClientConnectionFactoryDelegate cf3 = delegate.getDelegates()[2];
-         
+
          log.info("cf1 serverid=" + cf1.getServerID());
-         
+
          log.info("cf2 serverid=" + cf2.getServerID());
-         
+
          log.info("cf3 serverid=" + cf3.getServerID());
-         
+
          assertEquals(0, cf1.getServerID());
-         
+
          assertEquals(1, cf2.getServerID());
-         
+
          assertEquals(2, cf3.getServerID());
-         
-         
+
+
          assertEquals(3, failoverMap.size());
-         
+
          assertEquals(cf2.getServerID(), ((Integer)failoverMap.get(new Integer(cf1.getServerID()))).intValue());
-         
+
          assertEquals(cf3.getServerID(), ((Integer)failoverMap.get(new Integer(cf2.getServerID()))).intValue());
-         
+
          assertEquals(cf1.getServerID(), ((Integer)failoverMap.get(new Integer(cf3.getServerID()))).intValue());
-      }            
+      }
    }
-   
+
    public void testSimpleFailover() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-      
+
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 
       Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
       assertEquals(3, nodeIDView.size());
-      
+
       ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
+
       ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
+
       ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
+
       ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
+
       int server0Id = cf1.getServerID();
-      
+
       int server1Id = cf2.getServerID();
-      
+
       int server2Id = cf3.getServerID();
 
       log.info("server 0 id: " + server0Id);
-      
+
       log.info("server 1 id: " + server1Id);
-      
+
       log.info("server 2 id: " + server2Id);
-                  
+
       Map failoverMap = delegate.getFailoverMap();
-      
+
       log.info(failoverMap.get(new Integer(server0Id)));
       log.info(failoverMap.get(new Integer(server1Id)));
       log.info(failoverMap.get(new Integer(server2Id)));
-      
+
       int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
+
       // server 1 should failover onto server 2
-      
+
       assertEquals(server2Id, server1FailoverId);
-      
+
       Connection conn = null;
-      
-      boolean killed =  false;
-            
+
       try
-      {      
+      {
          conn = factory.createConnection(); //connection on server 0
-         
+
          conn.close();
-         
+
          conn = factory.createConnection(); //connection on server 1
-                          
+
          JBossConnection jbc = (JBossConnection)conn;
-         
+
          ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
+
          ConnectionState state = (ConnectionState)del.getState();
-         
+
          int initialServerID = state.getServerID();
-         
+
          assertEquals(1, initialServerID);
-                           
+
          Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          MessageProducer prod = sess.createProducer(queue[1]);
-         
+
          MessageConsumer cons = sess.createConsumer(queue[1]);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess.createTextMessage("message:" + i);
-            
+
             prod.send(tm);
          }
-         
+
          //So now, messages should be in queue[1] on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
+
+         log.info("######");
+         log.info("###### KILLING (CRASHING) SERVER 1");
+         log.info("######");
+
          ServerManagement.kill(1);
-         
-         killed = true;
-         
+
          log.info("killed server, now waiting");
-         
+
          Thread.sleep(5000);
-         
+
          log.info("done wait");
-         
+
          state = (ConnectionState)del.getState();
-         
+
          int finalServerID = state.getServerID();
-         
+
          log.info("final server id= " + finalServerID);
-         
+
          //server id should now be 2
-         
+
          assertEquals(2, finalServerID);
-         
+
          conn.start();
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = (TextMessage)cons.receive(1000);
-            
-            log.info("message is " + tm);
-            
+
+            log.debug("message is " + tm);
+
             assertNotNull(tm);
-            
+
             assertEquals("message:" + i, tm.getText());
          }
          log.info("done");
       }
       finally
-      {         
+      {
          if (conn != null)
          {
             try
@@ -548,178 +547,174 @@
             catch (Exception e)
             {
                e.printStackTrace();
-            }         
+            }
          }
-         
-         //Resurrect dead server
-         if (killed)
-         {
-            ServerManagement.spawn(1);
-         }
+
+         ServerManagement.start(1, "all");
       }
-      
    }
-   
-   
+
    public void testFailoverWithUnackedMessagesClientAcknowledge() throws Exception
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-      
+
       ClusteredClientConnectionFactoryDelegate delegate =
          (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 
       Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
       assertEquals(3, nodeIDView.size());
-      
+
       ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
+
       ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
+
       ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
+
       ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
+
       int server0Id = cf1.getServerID();
-      
+
       int server1Id = cf2.getServerID();
-      
+
       int server2Id = cf3.getServerID();
-      
+
       log.info("server 0 id: " + server0Id);
-      
+
       log.info("server 1 id: " + server1Id);
-      
+
       log.info("server 2 id: " + server2Id);
-                  
+
       Map failoverMap = delegate.getFailoverMap();
-      
+
       log.info(failoverMap.get(new Integer(server0Id)));
       log.info(failoverMap.get(new Integer(server1Id)));
       log.info(failoverMap.get(new Integer(server2Id)));
-      
+
       int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
+
       // server 1 should failover onto server 2
-      
+
       assertEquals(server2Id, server1FailoverId);
-      
+
       Connection conn = null;
-      
+
       boolean killed = false;
-      
+
       try
-      {      
+      {
          conn = factory.createConnection(); //connection on server 0
-         
+
          conn.close();
-         
+
          conn = factory.createConnection(); //connection on server 1
-         
+
          JBossConnection jbc = (JBossConnection)conn;
-         
+
          ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
+
          ConnectionState state = (ConnectionState)del.getState();
-         
+
          int initialServerID = state.getServerID();
-         
+
          assertEquals(1, initialServerID);
-                           
+
          Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
-         
+
          MessageProducer prod = sess.createProducer(queue[1]);
-         
+
          MessageConsumer cons = sess.createConsumer(queue[1]);
-         
+
          final int NUM_MESSAGES = 100;
-         
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
             TextMessage tm = sess.createTextMessage("message:" + i);
-            
+
             prod.send(tm);
          }
-         
+
          conn.start();
-         
-         //Now consume half of the messages but don't ack them these will end up in 
+
+         //Now consume half of the messages but don't ack them these will end up in
          //client side toAck list
-         
+
          for (int i = 0; i < NUM_MESSAGES / 2; i++)
          {
             TextMessage tm = (TextMessage)cons.receive(500);
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message:" + i, tm.getText());
          }
-         
+
          //So now, messages should be in queue[1] on server 1
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
+
+         log.info("######");
+         log.info("###### KILLING (CRASHING) SERVER 1");
+         log.info("######");
+
          ServerManagement.kill(1);
-         
+
          killed = true;
-         
+
          log.info("killed server, now waiting");
-         
+
          Thread.sleep(10000);
-         
+
          log.info("done wait");
-         
+
          state = (ConnectionState)del.getState();
-         
+
          int finalServerID = state.getServerID();
-         
+
          log.info("final server id= " + finalServerID);
-         
+
          //server id should now be 2
-         
+
          assertEquals(2, finalServerID);
-         
+
          conn.start();
-         
+
          //Now should be able to consume the rest of the messages
-         
+
          log.info("here1");
-         
+
          TextMessage tm = null;
-         
+
          for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
          {
             tm = (TextMessage)cons.receive(500);
-                                    
+
             log.info("message is " + tm.getText());
-            
+
             assertNotNull(tm);
-            
+
             assertEquals("message:" + i, tm.getText());
          }
-         
+
          log.info("here2");
-         
+
          //Now should be able to acknowledge them
-         
+
          tm.acknowledge();
-         
+
          //Now check there are no more messages there
          sess.close();
-         
+
          sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
+
          cons = sess.createConsumer(queue[1]);
-         
+
          Message m = cons.receive(500);
-         
+
          assertNull(m);
-         
+
          log.info("got to end of test");
       }
       finally
-      {         
+      {
          if (conn != null)
          {
             try
@@ -731,199 +726,202 @@
                e.printStackTrace();
             }
          }
-         
+
          // Resurrect dead server
          if (killed)
          {
-            ServerManagement.spawn(1);
+            ServerManagement.start(1, "all");
          }
       }
-      
-   }
-   
-   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-   {
-      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-      
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
 
-      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-      assertEquals(3, nodeIDView.size());
-      
-      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-      
-      ClientConnectionFactoryDelegate cf1 = delegates[0];
-      
-      ClientConnectionFactoryDelegate cf2 = delegates[1];
-      
-      ClientConnectionFactoryDelegate cf3 = delegates[2];
-      
-      int server0Id = cf1.getServerID();
-      
-      int server1Id = cf2.getServerID();
-      
-      int server2Id = cf3.getServerID();
-      
-      log.info("server 0 id: " + server0Id);
-      
-      log.info("server 1 id: " + server1Id);
-      
-      log.info("server 2 id: " + server2Id);
-                  
-      Map failoverMap = delegate.getFailoverMap();
-      
-      log.info(failoverMap.get(new Integer(server0Id)));
-      log.info(failoverMap.get(new Integer(server1Id)));
-      log.info(failoverMap.get(new Integer(server2Id)));
-      
-      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-      
-      // server 1 should failover onto server 2
-      
-      assertEquals(server2Id, server1FailoverId);
-      
-      Connection conn = null;
-      
-      boolean killed = false;
-      
-      try
-      {      
-         //Get a connection on server 1
-         conn = factory.createConnection(); //connection on server 0
-         
-         conn.close();
-         
-         conn = factory.createConnection(); //connection on server 1
-         
-         JBossConnection jbc = (JBossConnection)conn;
-         
-         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-         
-         ConnectionState state = (ConnectionState)del.getState();
-         
-         int initialServerID = state.getServerID();
-         
-         assertEquals(1, initialServerID);
-                           
-         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-         
-         MessageProducer prod = sess.createProducer(queue[1]);
-         
-         MessageConsumer cons = sess.createConsumer(queue[1]);
-         
-         final int NUM_MESSAGES = 100;
-         
-         for (int i = 0; i < NUM_MESSAGES; i++)
-         {
-            TextMessage tm = sess.createTextMessage("message:" + i);
-            
-            prod.send(tm);
-         }
-         
-         sess.commit();
-         
-         conn.start();
-         
-         //Now consume half of the messages but don't commit them these will end up in 
-         //client side resource manager
-         
-         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-         {
-            TextMessage tm = (TextMessage)cons.receive(500);
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         //So now, messages should be in queue[1] on server 1
-         //So we now kill server 1
-         //Which should cause transparent failover of connection conn onto server 1
-         
-         log.info("************ KILLING (CRASHING) SERVER 1");
-         
-         ServerManagement.kill(1);
-         
-         killed = true;
-
-         log.info("killed server, now waiting");
-         
-         Thread.sleep(5000);
-         
-         log.info("done wait");
-         
-         state = (ConnectionState)del.getState();
-         
-         int finalServerID = state.getServerID();
-         
-         log.info("final server id= " + finalServerID);
-         
-         //server id should now be 2
-         
-         assertEquals(2, finalServerID);
-         
-         conn.start();
-         
-         //Now should be able to consume the rest of the messages
-         
-         log.info("here1");
-         
-         TextMessage tm = null;
-         
-         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-         {
-            tm = (TextMessage)cons.receive(500);
-                                    
-            log.info("message is " + tm.getText());
-            
-            assertNotNull(tm);
-            
-            assertEquals("message:" + i, tm.getText());
-         }
-         
-         log.info("here2");
-         
-         //Now should be able to commit them
-         
-         sess.commit();
-         
-         //Now check there are no more messages there
-         sess.close();
-         
-         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         
-         cons = sess.createConsumer(queue[1]);
-         
-         Message m = cons.receive(500);
-         
-         assertNull(m);
-         
-         log.info("got to end of test");
-      }
-      finally
-      {         
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Exception e)
-            {
-               e.printStackTrace();
-            }
-         }
-         
-         if (killed)
-         {
-            ServerManagement.spawn(1);
-         }
-      }
-      
    }
+
    
+//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+//   {
+//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
+//
+//      ClusteredClientConnectionFactoryDelegate delegate =
+//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+//
+//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+//      assertEquals(3, nodeIDView.size());
+//
+//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+//
+//      ClientConnectionFactoryDelegate cf1 = delegates[0];
+//
+//      ClientConnectionFactoryDelegate cf2 = delegates[1];
+//
+//      ClientConnectionFactoryDelegate cf3 = delegates[2];
+//
+//      int server0Id = cf1.getServerID();
+//
+//      int server1Id = cf2.getServerID();
+//
+//      int server2Id = cf3.getServerID();
+//
+//      log.info("server 0 id: " + server0Id);
+//
+//      log.info("server 1 id: " + server1Id);
+//
+//      log.info("server 2 id: " + server2Id);
+//
+//      Map failoverMap = delegate.getFailoverMap();
+//
+//      log.info(failoverMap.get(new Integer(server0Id)));
+//      log.info(failoverMap.get(new Integer(server1Id)));
+//      log.info(failoverMap.get(new Integer(server2Id)));
+//
+//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+//
+//      // server 1 should failover onto server 2
+//
+//      assertEquals(server2Id, server1FailoverId);
+//
+//      Connection conn = null;
+//
+//      boolean killed = false;
+//
+//      try
+//      {
+//         //Get a connection on server 1
+//         conn = factory.createConnection(); //connection on server 0
+//
+//         conn.close();
+//
+//         conn = factory.createConnection(); //connection on server 1
+//
+//         JBossConnection jbc = (JBossConnection)conn;
+//
+//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+//
+//         ConnectionState state = (ConnectionState)del.getState();
+//
+//         int initialServerID = state.getServerID();
+//
+//         assertEquals(1, initialServerID);
+//
+//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+//
+//         MessageProducer prod = sess.createProducer(queue[1]);
+//
+//         MessageConsumer cons = sess.createConsumer(queue[1]);
+//
+//         final int NUM_MESSAGES = 100;
+//
+//         for (int i = 0; i < NUM_MESSAGES; i++)
+//         {
+//            TextMessage tm = sess.createTextMessage("message:" + i);
+//
+//            prod.send(tm);
+//         }
+//
+//         sess.commit();
+//
+//         conn.start();
+//
+//         //Now consume half of the messages but don't commit them these will end up in
+//         //client side resource manager
+//
+//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+//         {
+//            TextMessage tm = (TextMessage)cons.receive(500);
+//
+//            assertNotNull(tm);
+//
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//
+//         //So now, messages should be in queue[1] on server 1
+//         //So we now kill server 1
+//         //Which should cause transparent failover of connection conn onto server 1
+//
+//         log.info("######");
+//         log.info("###### KILLING (CRASHING) SERVER 1");
+//         log.info("######");
+//
+//         ServerManagement.kill(1);
+//
+//         killed = true;
+//
+//         log.info("killed server, now waiting");
+//
+//         Thread.sleep(5000);
+//
+//         log.info("done wait");
+//
+//         state = (ConnectionState)del.getState();
+//
+//         int finalServerID = state.getServerID();
+//
+//         log.info("final server id= " + finalServerID);
+//
+//         //server id should now be 2
+//
+//         assertEquals(2, finalServerID);
+//
+//         conn.start();
+//
+//         //Now should be able to consume the rest of the messages
+//
+//         log.info("here1");
+//
+//         TextMessage tm = null;
+//
+//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+//         {
+//            tm = (TextMessage)cons.receive(500);
+//
+//            log.info("message is " + tm.getText());
+//
+//            assertNotNull(tm);
+//
+//            assertEquals("message:" + i, tm.getText());
+//         }
+//
+//         log.info("here2");
+//
+//         //Now should be able to commit them
+//
+//         sess.commit();
+//
+//         //Now check there are no more messages there
+//         sess.close();
+//
+//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//
+//         cons = sess.createConsumer(queue[1]);
+//
+//         Message m = cons.receive(500);
+//
+//         assertNull(m);
+//
+//         log.info("got to end of test");
+//      }
+//      finally
+//      {
+//         if (conn != null)
+//         {
+//            try
+//            {
+//               conn.close();
+//            }
+//            catch (Exception e)
+//            {
+//               e.printStackTrace();
+//            }
+//         }
+//
+//         if (killed)
+//         {
+//            ServerManagement.spawn(1);
+//         }
+//      }
+//
+//   }
    
+   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -52,7 +52,7 @@
 
       // We start programatically the fourth node.
 
-      ServerManagement.start("all", 3);
+      ServerManagement.start(4, "all");
 
       // TODO - verify that the cluster formed correctly assertion
 
@@ -97,7 +97,7 @@
 
       // We get the first node to re-join
 
-      ServerManagement.start("all", 0);
+      ServerManagement.start(0, "all");
 
    }
    

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -91,7 +91,9 @@
 
       for(int i = 0; i < nodeCount; i++)
       {
-         ServerManagement.start("all", i);
+         // make sure all servers are created and started
+         ServerManagement.start(i, "all");
+
          ServerManagement.deployClusteredQueue("testDistributedQueue", i);
          ServerManagement.deployClusteredTopic("testDistributedTopic", i);
 
@@ -122,6 +124,8 @@
          ic[i].close();
       }
 
+      //ServerManagement.destroySpawnedServers();
+
       super.tearDown();
    }
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -28,6 +28,9 @@
 import java.util.Map;
 import java.util.List;
 import java.util.Iterator;
+import java.util.ArrayList;
+import java.io.BufferedReader;
+import java.io.InputStreamReader;
 import javax.management.ObjectName;
 import javax.management.NotificationListener;
 import javax.management.Notification;
@@ -76,12 +79,8 @@
 
    private static Logger log = Logger.getLogger(ServerManagement.class);
 
-   private static final int RMI_SERVER_LOOKUP_RETRIES = 10;
+   private static ServerHolder[] servers = new ServerHolder[MAX_SERVER_COUNT];
 
-   private static Server[] servers = new Server[MAX_SERVER_COUNT];
-   
-   private static boolean[] killed = new boolean[MAX_SERVER_COUNT];
-   
    // Map<NotificationListener - NotificationListenerPoller>
    private static Map notificationListenerPollers = new HashMap();
 
@@ -100,128 +99,104 @@
       return "true".equals(System.getProperty("test.clustered"));
    }
 
-   public static synchronized boolean isKilled(int index)
+   /**
+    * May return null if the server is not initialized.
+    */
+   public synchronized static Server getServer()
    {
-      return killed[index];
+      return getServer(0);
    }
 
-   public static synchronized boolean isStarted(int index)
+   /**
+    * May return null if the corresponding server is not initialized.
+    */
+   public synchronized static Server getServer(int i)
    {
-      Server s = servers[index];
-
-      if (s == null)
+      if (servers[i] == null)
       {
-         return false;
+         return null;
       }
-
-      try
+      else
       {
-         return s.isStarted();
+         return ((ServerHolder)servers[i]).getServer();
       }
-      catch(Exception e)
-      {
-         return false;
-      }
    }
 
-   public static Server getServer()
+   public static synchronized Server create() throws Exception
    {
-      return getServer(0);
+      return create(0);
    }
-   
-   public static Server getServer(int i)
-   {
-      if (killed[i])
-      {
-         log.warn("Server " + i + " cannot be got since it has been killed");
-      }
-      
-      Server s = servers[i];
-      
-      if (s == null)
-      {
-         throw new IllegalStateException("Server " + i + " is not started!");
-      }
-      
-      return s;
-   }
-   
-   public static synchronized void create() throws Exception
-   {
-      create(0);
-   }
 
-   public static synchronized void create(int index) throws Exception
+   /**
+    * Makes sure that a "hollow" TestServer (either local or remote, depending on the nature of the
+    * test), exists and it's ready to be started.
+    */
+   public static synchronized Server create(int i) throws Exception
    {
-      if (killed[index])
+      if (servers[i] == null)
       {
-         log.warn("Server " + index + " cannot created since it has been killed");
-         
-         return;
-      }
-      
-      if (servers[index] != null)
-      {
-         return;
-      }
+         if (isLocal())
+         {
+            servers[i] = new ServerHolder(new LocalTestServer(i), false);
+         }
+         else
+         {
+            Server s = acquireRemote(1, i, true);
 
-      if (isLocal())
-      {
-         servers[index] = new LocalTestServer(index);
-         return;
+            if (s != null)
+            {
+               servers[i] = new ServerHolder(s, false);
+            }
+            else
+            {
+               // most likely the remote server is not started, so spawn it
+               servers[i] = new ServerHolder(ServerManagement.spawn(i), true);
+               log.info("server " + i + " online");
+            }
+         }
       }
 
-      servers[index] = acquireRemote(RMI_SERVER_LOOKUP_RETRIES, index);
+      return servers[i].getServer();
+   }
 
-      if (servers[index] != null)
-      {
-         // RMI server started
-         return;
 
-      }
+   public static synchronized void start(String config) throws Exception
+   {
+      start(0, config);
+   }
 
-      // the remote RMI server is not started
+   /**
+    * When this method correctly completes, the server (local or remote) is started and fully
+    * operational (the service container and the server peer are created and started)
+    */
+   public static synchronized void start(int i, String config) throws Exception
+   {
+      Server s = create(i);
 
-      // I could attempt to start the remote server VM from the test itself (see commented out code)
-      // but when running such a test from a forking ant, ant blocks forever waiting for *this* VM
-      // to exit. That's why I require the remote server to be started in advance.
+      MessageIdGeneratorFactory.instance.clear();
 
-      throw new IllegalStateException("The RMI server " + index + " doesn't seem to be started. " +
-                                      "Start it and re-run the test.");
+      log.info("starting server " + i);
 
+      s.start(config);
+
+      log.info("server " + i + " started");
    }
-   
-   public static synchronized void start(String config) throws Exception
-   {
-      start(config, 0);
-   }
 
-   public static synchronized void start(String config, int index) throws Exception
+   public static synchronized boolean isStarted(int i)
    {
-      if (killed[index])
+      if (servers[i] == null)
       {
-         log.warn("Server " + index + " cannot been started since it has been killed");
-         
-         return;
+         return false;
       }
-      
-      create(index);
 
-      if (isLocal())
+      try
       {
-         log.info("IN-VM TEST");
+         return servers[i].getServer().isStarted();
       }
-      else
+      catch(Exception e)
       {
-         log.info("REMOTE TEST");
+         return false;
       }
-      
-      MessageIdGeneratorFactory.instance.clear();      
-
-      // Now start the server
-      servers[index].start(config);
-
-      log.debug("server started");
    }
 
    public static synchronized void stop() throws Exception
@@ -229,124 +204,240 @@
       stop(0);
    }
 
-   public static synchronized void stop(int index) throws Exception
+   /**
+    * The method stops the local or remote server, bringing it to a "hollow" state. A stopped
+    * server is identical with a server that has just been created, but not started.
+    */
+   public static synchronized void stop(int i) throws Exception
    {
-      if (killed[index])
+      if (servers[i] == null)
       {
-         log.warn("Server " + index + " cannot been stopped since it has been killed");
-         
-         return;
+         log.warn("Server " + i + " has not been created, so it cannot be stopped");
       }
-      
-      if (servers[index] == null)
+      else
       {
-         log.warn("Server " + index + " has not been created, so it cannot be stopped");
-         return;
+         servers[i].getServer().stop();
       }
+   }
 
-      if (!servers[index].isStarted())
+   /**
+    * Abruptly kills the VM running the specified server, simulating a crash. A local server
+    * cannot be killed, the method is a noop if this is the case.
+    */
+   public static synchronized void kill(int i) throws Exception
+   {
+      if (servers[i] == null)
       {
-         log.warn("Server " + index + " either has not been started, or it is stopped already");
-         return;
+         log.warn("Server " + i + " has not been created, so it cannot be killed");
       }
-
-      servers[index].stop();
+      else
+      {
+         servers[i].getServer().kill();
+         log.info("Server " + i + " killed");
+         servers[i] = null;
+      }
    }
 
    /**
-    * TODO - this methods should be removed, to not be confused with kill(index)
-    * @deprecated
+    * This method make sure that all servers that have been implicitely spawned when as a side
+    * effect of create() and/or start() are killed. The method is important because a forked
+    * ant junit task won't exit if processes created by it are still active. If you run tests
+    * from ant, always call killSpawnedServers() in tearDown().
+    *
+    * The servers created directed invoking spawn() are not subject to destroySpawnedServers(); they
+    * need to be explicitely killed.
+    *
+    * @return a List<Integer> containing the indexes of the destroyed servers.
+    *
     */
-   public static synchronized void destroy() throws Exception
+   public static synchronized List destroySpawnedServers() throws Exception
    {
-      stop();
-      servers[0].kill();
-      servers[0] = null;
+      List destroyed = new ArrayList();
+
+      for(int i = 0; i < servers.length; i++)
+      {
+         if (servers[i] != null && servers[i].isSpawned())
+         {
+            Server s = servers[i].getServer();
+            destroyed.add(new Integer(s.getServerID()));
+            s.stop();
+            s.kill();
+            servers[i] = null;
+         }
+      }
+
+      return destroyed;
    }
 
    /**
-    * For a local test, is a noop, but for a remote test, the method call spawns a new VM.
+    * For a local test, is a noop, but for a remote test, the method call spawns a new VM,
+    * irrespective of the fact that a server with same index may already exist (if you want to
+    * avoid conflicts, you need to check this externally).
+    *
     * The remote server so created is no different from a server started using start-rmi-server
     * script.
     */
-   public static synchronized void spawn(int index) throws Exception
+   private static synchronized Server spawn(final int i) throws Exception
    {
-      if (servers[index] != null)
+      if(isLocal())
       {
-         throw new Exception("The server " + index + " has been created already!");
+         return null;
       }
 
-      // in the remote case, make sure the VM with the given index isn't already up
-      if (isRemote() && acquireRemote(3, index) != null)
-      {
-         throw new Exception("The remote server " + index + " seems to be already up!");
-      }
-
-
       StringBuffer sb = new StringBuffer();
 
       sb.append("java").append(' ');
 
       sb.append("-Xmx512M").append(' ');
 
-      sb.append("-Dmodule.output=./../output").append(' ');
+      String moduleOutput = System.getProperty("module.output");
+      if (moduleOutput == null)
+      {
+         moduleOutput = "./output";
+      }
+      
+      sb.append("-Dmodule.output=").append(moduleOutput).append(' ');
 
-      sb.append("-Dremote.test.suffix=-remote-").append(index).append(' ');
+      sb.append("-Dremote.test.suffix=-remote-").append(i).append(' ');
 
-      sb.append("-Dtest.server.index=").append(index).append(' ');
+      sb.append("-Dtest.server.index=").append(i).append(' ');
 
       sb.append("-Dtest.bind.address=localhost").append(' ');
 
-      sb.append("-cp").append(' ').append(System.getProperty("java.class.path")).append(' ');
+      String database = System.getProperty("test.database");
+      if (database != null)
+      {
+         sb.append("-Dtest.database=").append(database).append(' ');
+      }
 
+      String serialization = System.getProperty("test.serialization");
+      if (serialization != null)
+      {
+         sb.append("-Dtest.serialization=").append(serialization).append(' ');
+      }
+
+      String clustered = System.getProperty("test.clustered");
+      if (clustered != null)
+      {
+         sb.append("-Dtest.clustered=").append(clustered).append(' ');
+      }
+
+      String remoting = System.getProperty("test.remoting");
+      if (remoting != null)
+      {
+         sb.append("-Dtest.remoting=").append(remoting).append(' ');
+      }
+
+      String classPath = System.getProperty("java.class.path");
+
+      //System.out.println("CLASSPATH: " + classPath);
+
+      sb.append("-cp").append(" \"").append(classPath).append("\" ");
+
       sb.append("org.jboss.test.messaging.tools.jmx.rmi.RMITestServer");
 
-      //System.out.println(sb.toString());
+      String commandLine = sb.toString();
 
-      Runtime.getRuntime().exec(sb.toString());
+      //System.out.println(commandLine);
 
-      killed[index] = false;
+      Process process = Runtime.getRuntime().exec(commandLine);
 
-      log.info("VM for Server " + index + " spawned");
-   }
+      log.trace("process: " + process);
 
-   /**
-    * Abruptly kills the VM running the specified server, simulating a crash.
-    */
-   public static synchronized void kill(int index) throws Exception
-   {
-      if (servers[index] == null)
+      // if you ever need to debug the spawing process, turn this flag to true:
+
+      final boolean verbose = false;
+
+      final BufferedReader rs = new BufferedReader(new InputStreamReader(process.getInputStream()));
+      final BufferedReader re = new BufferedReader(new InputStreamReader(process.getErrorStream()));
+
+      new Thread(new Runnable()
       {
-         log.warn("Server " + index + " has not been created, so it cannot be killed");
-         return;
-      }
+         public void run()
+         {
+            try
+            {
+               String line;
 
-      servers[index].kill();
+               while((line = rs.readLine()) != null)
+               {
+                  if (verbose)
+                  {
+                     System.out.println("SERVER " + i + " STDOUT: " + line);
+                  }
+               }
+            }
+            catch(Exception e)
+            {
+               log.error("exception", e);
+            }
+         }
 
-      log.info("Server " + index + " killed");
+      }, "Server " + i + " STDOUT reader thread").start();
 
-      servers[index] = null;
-      killed[index] = true;
-   }
-   
-   public static void disconnect() throws Exception
-   {
-      if (isRemote())
+      new Thread(new Runnable()
       {
-         servers[0] = null;
+         public void run()
+         {
+            try
+            {
+               String line;
+
+               while((line = re.readLine()) != null)
+               {
+                  if (verbose)
+                  {
+                     System.out.println("SERVER " + i + " STDERR: " + line);
+                  }
+               }
+            }
+            catch(Exception e)
+            {
+               log.error("exception", e);
+            }
+         }
+
+      }, "Server " + i + " STDERR reader thread").start();
+
+
+      // put the invoking thread on wait until the server is actually up and running and bound
+      // in the RMI registry
+
+      long maxWaitTime = 30; // seconds
+      long startTime = System.currentTimeMillis();
+      Server s = null;
+
+      log.info("spawned server " + i + ", waiting for it to come online");
+
+      while(System.currentTimeMillis() - startTime < maxWaitTime * 1000)
+      {
+         s = acquireRemote(1, i, true);
+         if (s != null)
+         {
+            break;
+         }
       }
+
+      if (s == null)
+      {
+         log.error("Cannot contact newly spawned server " + i + ", most likely the attempt failed, timing out ...");
+         throw new Exception("Cannot contact newly spawned server " + i + ", most likely the attempt failed, timing out ...");
+      }
+
+      return s;
    }
 
+
    public static ObjectName deploy(String mbeanConfiguration) throws Exception
    {
       insureStarted();
-      return servers[0].deploy(mbeanConfiguration);
+      return servers[0].getServer().deploy(mbeanConfiguration);
    }
 
    public static void undeploy(ObjectName on) throws Exception
    {
       insureStarted();
-      servers[0].undeploy(on);
+      servers[0].getServer().undeploy(on);
    }
 
    public static Object getAttribute(ObjectName on, String attribute) throws Exception
@@ -358,7 +449,7 @@
       throws Exception
    {
       insureStarted(serverIndex);
-      return servers[serverIndex].getAttribute(on, attribute);
+      return servers[serverIndex].getServer().getAttribute(on, attribute);
    }
 
 
@@ -366,32 +457,25 @@
       throws Exception
    {
       insureStarted();
-      servers[0].setAttribute(on, name, valueAsString);
+      servers[0].getServer().setAttribute(on, name, valueAsString);
    }
 
    public static Object invoke(ObjectName on, String operationName,
                                Object[] params, String[] signature) throws Exception
    {
       insureStarted();
-      return servers[0].invoke(on, operationName, params, signature);
+      return servers[0].getServer().invoke(on, operationName, params, signature);
    }
 
    public static void addNotificationListener(int serverIndex, ObjectName on,
                                               NotificationListener listener) throws Exception
    {
-      if (killed[serverIndex])
-      {
-         log.warn("Server " + serverIndex + " cannot addNotificationListener it has been killed");
-         
-         return;
-      }
-      
       insureStarted(serverIndex);
 
       if (isLocal())
       {
          // add the listener directly to the server
-         servers[serverIndex].addNotificationListener(on, listener);
+         servers[serverIndex].getServer().addNotificationListener(on, listener);
       }
       else
       {
@@ -411,19 +495,12 @@
    public static void removeNotificationListener(int serverIndex, ObjectName on,
                                                  NotificationListener listener) throws Exception
    {
-      if (killed[serverIndex])
-      {
-         log.warn("Server " + serverIndex + " cannot removeNotificationListener it has been killed");
-         
-         return;
-      }
-      
       insureStarted(serverIndex);
 
       if (isLocal())
       {
          // remove the listener directly
-         servers[serverIndex].removeNotificationListener(on, listener);
+         servers[serverIndex].getServer().removeNotificationListener(on, listener);
       }
       else
       {
@@ -446,13 +523,13 @@
    public static Set query(ObjectName pattern) throws Exception
    {
       insureStarted();
-      return servers[0].query(pattern);
+      return servers[0].getServer().query(pattern);
    }
 
    public static UserTransaction getUserTransaction() throws Exception
    {
       insureStarted();
-      return servers[0].getUserTransaction();
+      return servers[0].getServer().getUserTransaction();
    }
    
    public static void log(int level, String text)
@@ -462,13 +539,6 @@
 
    public static void log(int level, String text, int index)
    {
-      if (killed[index])
-      {
-         log.warn("Server " + index + " cannot log it has been killed");
-         
-         return;
-      }
-      
       if (isRemote())
       {
          if (servers[index] == null)
@@ -480,7 +550,7 @@
 
          try
          {
-            servers[index].log(level, text);
+            servers[index].getServer().log(level, text);
          }
          catch(Exception e)
          {
@@ -504,25 +574,26 @@
                                       String defaultTopicJNDIContext) throws Exception
    {
       insureStarted();
-      servers[0].startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, false);
+      servers[0].getServer().
+         startServerPeer(serverPeerID, defaultQueueJNDIContext, defaultTopicJNDIContext, false);
    }
 
    public static void stopServerPeer() throws Exception
    {
       insureStarted();
-      servers[0].stopServerPeer();
+      servers[0].getServer().stopServerPeer();
    }
 
    public static boolean isServerPeerStarted() throws Exception
    {
       insureStarted();
-      return servers[0].isServerPeerStarted();
+      return servers[0].getServer().isServerPeerStarted();
    }
 
    public static ObjectName getServerPeerObjectName() throws Exception
    {
       insureStarted();
-      return servers[0].getServerPeerObjectName();
+      return servers[0].getServer().getServerPeerObjectName();
    }
 
    /**
@@ -532,7 +603,7 @@
    public static Set getConnectorSubsystems() throws Exception
    {
       insureStarted();
-      return servers[0].getConnectorSubsystems();
+      return servers[0].getServer().getConnectorSubsystems();
    }
 
    /**
@@ -543,7 +614,7 @@
                                                  ServerInvocationHandler handler) throws Exception
    {
       insureStarted();
-      servers[0].addServerInvocationHandler(subsystem, handler);
+      servers[0].getServer().addServerInvocationHandler(subsystem, handler);
    }
 
    /**
@@ -554,46 +625,46 @@
       throws Exception
    {
       insureStarted();
-      servers[0].removeServerInvocationHandler(subsystem);
+      servers[0].getServer().removeServerInvocationHandler(subsystem);
    }
 
    public static MessageStore getMessageStore() throws Exception
    {
       insureStarted();
-      return servers[0].getMessageStore();
+      return servers[0].getServer().getMessageStore();
    }
 
    public static DestinationManager getDestinationManager()
       throws Exception
    {
       insureStarted();
-      return servers[0].getDestinationManager();
+      return servers[0].getServer().getDestinationManager();
    }
 
    public static PersistenceManager getPersistenceManager()
       throws Exception
    {
       insureStarted();
-      return servers[0].getPersistenceManager();
+      return servers[0].getServer().getPersistenceManager();
    }
 
    public static void configureSecurityForDestination(String destName, String config)
       throws Exception
    {
       insureStarted();
-      servers[0].configureSecurityForDestination(destName, config);
+      servers[0].getServer().configureSecurityForDestination(destName, config);
    }
 
    public static void setDefaultSecurityConfig(String config) throws Exception
    {
       insureStarted();
-      servers[0].setDefaultSecurityConfig(config);
+      servers[0].getServer().setDefaultSecurityConfig(config);
    }
 
    public static String getDefaultSecurityConfig() throws Exception
    {
       insureStarted();
-      return servers[0].getDefaultSecurityConfig();
+      return servers[0].getServer().getDefaultSecurityConfig();
    }
    
    /**
@@ -601,13 +672,8 @@
     */
    public static void deployClusteredTopic(String name, int serverIndex) throws Exception
    {
-      if (killed[serverIndex])
-      {
-         log.warn("Server " + serverIndex + " cannot deployClusteredTopic it has been killed");
-      }
-      
       insureStarted(serverIndex);
-      servers[serverIndex].deployTopic(name, null, true);
+      servers[serverIndex].getServer().deployTopic(name, null, true);
    }
 
    /**
@@ -624,7 +690,7 @@
    public static void deployTopic(String name, String jndiName) throws Exception
    {
       insureStarted();
-      servers[0].deployTopic(name, jndiName, false);
+      servers[0].getServer().deployTopic(name, jndiName, false);
    }
 
    /**
@@ -643,7 +709,7 @@
                                   int downCacheSize) throws Exception
    {
       insureStarted();
-      servers[0].deployTopic(name, jndiName, fullSize, pageSize, downCacheSize, false);
+      servers[0].getServer().deployTopic(name, jndiName, fullSize, pageSize, downCacheSize, false);
    }
 
    /**
@@ -659,11 +725,6 @@
     */
    public static void undeployTopic(String name, int serverIndex) throws Exception
    {
-      if (killed[serverIndex])
-      {
-         log.warn("Server " + serverIndex + " cannot undeployTopic it has been killed");
-      }
-      
       undeployDestination(false, name, serverIndex);
    }
 
@@ -673,7 +734,7 @@
    public static void createTopic(String name, String jndiName) throws Exception
    {
       insureStarted();
-      servers[0].createTopic(name, jndiName);
+      servers[0].getServer().createTopic(name, jndiName);
    }
 
    /**
@@ -681,7 +742,7 @@
     */
    public static boolean destroyTopic(String name) throws Exception
    {
-      return servers[0].destroyDestination(false, name);
+      return servers[0].getServer().destroyDestination(false, name);
    }
    
    /**
@@ -689,13 +750,8 @@
     */
    public static void deployClusteredQueue(String name, int serverIndex) throws Exception
    {
-      if (killed[serverIndex])
-      {
-         log.warn("Server " + serverIndex + " cannot deployClusteredQueue it has been killed");
-      }
-      
       insureStarted(serverIndex);
-      servers[serverIndex].deployQueue(name, null, true);
+      servers[serverIndex].getServer().deployQueue(name, null, true);
    }
 
    /**
@@ -712,7 +768,7 @@
    public static void deployQueue(String name, String jndiName) throws Exception
    {
       insureStarted();
-      servers[0].deployQueue(name, jndiName, false);
+      servers[0].getServer().deployQueue(name, jndiName, false);
    }
 
    /**
@@ -731,7 +787,7 @@
                                   int downCacheSize) throws Exception
    {
       insureStarted();
-      servers[0].deployQueue(name, jndiName, fullSize, pageSize, downCacheSize, false);
+      servers[0].getServer().deployQueue(name, jndiName, fullSize, pageSize, downCacheSize, false);
    }
 
    /**
@@ -747,11 +803,6 @@
     */
    public static void undeployQueue(String name, int serverIndex) throws Exception
    {
-      if (killed[serverIndex])
-      {
-         log.warn("Server " + serverIndex + " cannot undeplyQueue it has been killed");
-      }
-      
       undeployDestination(true, name, serverIndex);
    }
 
@@ -761,7 +812,7 @@
    public static void createQueue(String name, String jndiName) throws Exception
    {
       insureStarted();
-      servers[0].createQueue(name, jndiName);
+      servers[0].getServer().createQueue(name, jndiName);
    }
 
    /**
@@ -769,7 +820,7 @@
     */
    public static boolean destroyQueue(String name) throws Exception
    {
-      return servers[0].destroyDestination(true, name);
+      return servers[0].getServer().destroyDestination(true, name);
    }
 
    /**
@@ -779,7 +830,7 @@
    private static void undeployDestination(boolean isQueue, String name) throws Exception
    {
       insureStarted();
-      servers[0].undeployDestination(isQueue, name);
+      servers[0].getServer().undeployDestination(isQueue, name);
    }
    
    /**
@@ -790,7 +841,7 @@
       throws Exception
    {
       insureStarted(serverIndex);
-      servers[serverIndex].undeployDestination(isQueue, name);
+      servers[serverIndex].getServer().undeployDestination(isQueue, name);
    }
                                                                                                                 
    public static void deployConnectionFactory(String objectName,
@@ -801,12 +852,12 @@
                                               int defaultTempQueueDownCacheSize)
       throws Exception
    {
-      servers[0].deployConnectionFactory(objectName,
-                                     jndiBindings,
-                                     prefetchSize,
-                                     defaultTempQueueFullSize,
-                                     defaultTempQueuePageSize,
-                                     defaultTempQueueDownCacheSize);
+      servers[0].getServer().deployConnectionFactory(objectName,
+                                                     jndiBindings,
+                                                     prefetchSize,
+                                                     defaultTempQueueFullSize,
+                                                     defaultTempQueuePageSize,
+                                                     defaultTempQueueDownCacheSize);
    }
 
    public static void deployConnectionFactory(String objectName,
@@ -814,19 +865,19 @@
                                               int prefetchSize)
       throws Exception
    {
-      servers[0].deployConnectionFactory(objectName, jndiBindings, prefetchSize);
+      servers[0].getServer().deployConnectionFactory(objectName, jndiBindings, prefetchSize);
    }
    
    public static void deployConnectionFactory(String objectName,
                                               String[] jndiBindings)
       throws Exception
    {
-      servers[0].deployConnectionFactory(objectName, jndiBindings);
+      servers[0].getServer().deployConnectionFactory(objectName, jndiBindings);
    }
 
    public static void undeployConnectionFactory(ObjectName objectName) throws Exception
    {
-      servers[0].undeployConnectionFactory(objectName);
+      servers[0].getServer().undeployConnectionFactory(objectName);
    }
 
    public static Hashtable getJNDIEnvironment()
@@ -846,37 +897,8 @@
       }
    }
 
-   // Attributes ----------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   // Public --------------------------------------------------------
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   private static void insureStarted() throws Exception
+   public static Server acquireRemote(int initialRetries, int index, boolean quiet)
    {
-      insureStarted(0);
-   }
-   
-   private static void insureStarted(int index) throws Exception
-   {
-      if (servers[index] == null)
-      {
-         throw new Exception("The server " + index + " has not been created!");
-      }
-      if (!servers[index].isStarted())
-      {
-         throw new Exception("The server " + index + " has not been started!");
-      }
-   }
-
-   private static Server acquireRemote(int initialRetries, int index)
-   {
       String name =
          "//localhost:" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
          RMITestServer.RMI_SERVER_PREFIX + index;
@@ -889,21 +911,30 @@
          int attempt = initialRetries - retries + 1;
          try
          {
-            log.info("trying to connect to the remote RMI server " + index + 
-                     (attempt == 1 ? "" : ", attempt " + attempt));
+            String msg = "trying to connect to the remote RMI server " + index +
+               (attempt == 1 ? "" : ", attempt " + attempt);
 
+            if(quiet)
+            {
+               log.debug(msg);
+            }
+            else
+            {
+               log.info(msg);
+            }
+
             s = (Server)Naming.lookup(name);
 
-            log.info("connected to the remote server");
+            log.debug("connected to remote server " + index);
          }
          catch(Exception e)
          {
             log.debug("failed to get the RMI server stub, attempt " +
-                      (initialRetries - retries + 1), e);
+               (initialRetries - retries + 1), e);
 
             try
             {
-               Thread.sleep(1500);
+               Thread.sleep(500);
             }
             catch(InterruptedException e2)
             {
@@ -913,147 +944,41 @@
             retries--;
          }
       }
+
       return s;
    }
 
+   // Attributes ----------------------------------------------------
 
-   // Inner classes -------------------------------------------------
+   // Constructors --------------------------------------------------
 
-//   static class VMStarter implements Runnable
-//   {
-//      public void run()
-//      {
-//         // start a remote java process that runs a TestServer
-//
-//         String userDir = System.getProperty("user.dir");
-//         String javaClassPath = System.getProperty("java.class.path");
-//         String fileSeparator = System.getProperty("file.separator");
-//         String javaHome = System.getProperty("java.home");
-//         String moduleOutput = System.getProperty("module.output");
-//
-//         String osName = System.getProperty("os.name").toLowerCase();
-//         boolean isWindows = osName.indexOf("windows") != -1;
-//
-//         String javaExecutable =
-//            javaHome + fileSeparator + "bin" + fileSeparator + "java" + (isWindows ? ".exe" : "");
-//
-//         String[] cmdarray = new String[]
-//         {
-//            javaExecutable,
-//            "-cp",
-//            javaClassPath,
-//            "-Dmodule.output=" + moduleOutput,
-//            "-Dremote.test.suffix=-remote",
-//            "org.jboss.test.messaging.tools.jmx.rmi.TestServer",
-//         };
-//
-//         String[] environment;
-//         if (isWindows)
-//         {
-//            environment = new String[]
-//            {
-//               "SYSTEMROOT=C:\\WINDOWS" // TODO get this from environment, as it may be diffrent on different machines
-//            };
-//         }
-//         else
-//         {
-//            environment = new String[0];
-//         }
-//
-//         Runtime runtime = Runtime.getRuntime();
-//
-//         try
-//         {
-//            log.debug("creating external process");
-//
-//            Thread stdoutLogger = new Thread(new RemoteProcessLogger(RemoteProcessLogger.STDOUT),
-//                                             "Remote VM STDOUT Logging Thread");
-//            Thread stderrLogger = new Thread(new RemoteProcessLogger(RemoteProcessLogger.STDERR),
-//                                             "Remote VM STDERR Logging Thread");
-//
-//            stdoutLogger.setDaemon(true);
-//            stdoutLogger.setDaemon(true);
-//            stdoutLogger.start();
-//            stderrLogger.start();
-//
-//            process = runtime.exec(cmdarray, environment, new File(userDir));
-//         }
-//         catch(Exception e)
-//         {
-//            log.error("Error spawning remote server", e);
-//         }
-//      }
-//   }
-//
-//   /**
-//    * This logger is used to get and display the output generated at stdout or stderr by the
-//    * RMI server VM.
-//    */
-//   static class RemoteProcessLogger implements Runnable
-//   {
-//      public static final int STDOUT = 0;
-//      public static final int STDERR = 1;
-//
-//      private int type;
-//      private BufferedReader br;
-//      private PrintStream out;
-//
-//      public RemoteProcessLogger(int type)
-//      {
-//         this.type = type;
-//
-//         if (type == STDOUT)
-//         {
-//            out = System.out;
-//         }
-//         else if (type == STDERR)
-//         {
-//            out = System.err;
-//         }
-//         else
-//         {
-//            throw new IllegalArgumentException("Unknown type " + type);
-//         }
-//      }
-//
-//      public void run()
-//      {
-//         while(process == null)
-//         {
-//            try
-//            {
-//               Thread.sleep(50);
-//            }
-//            catch(InterruptedException e)
-//            {
-//               // OK
-//            }
-//         }
-//
-//         if (type == STDOUT)
-//         {
-//            br = new BufferedReader(new InputStreamReader(process.getInputStream()));
-//         }
-//         else if (type == STDERR)
-//         {
-//            br = new BufferedReader(new InputStreamReader(process.getErrorStream()));
-//         }
-//
-//         String line;
-//         try
-//         {
-//            while((line = br.readLine()) != null)
-//            {
-//               out.println(line);
-//            }
-//         }
-//         catch(Exception e)
-//         {
-//            log.error("failed to read from process " + process, e);
-//         }
-//      }
-//   }
+   // Public --------------------------------------------------------
 
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   private static void insureStarted() throws Exception
+   {
+      insureStarted(0);
+   }
+   
+   private static void insureStarted(int i) throws Exception
+   {
+      if (servers[i] == null)
+      {
+         throw new Exception("The server " + i + " has not been created!");
+      }
+      if (!servers[i].getServer().isStarted())
+      {
+         throw new Exception("The server " + i + " has not been started!");
+      }
+   }
+
+   // Inner classes -------------------------------------------------
+
    private static long listenerIDCounter = 0;
 
    static class NotificationListenerPoller implements Runnable
@@ -1112,4 +1037,26 @@
       }
    }
 
+   private static class ServerHolder
+   {
+      private Server server;
+      private boolean spawned;
+
+      ServerHolder(Server server, boolean spawned)
+      {
+         this.server = server;
+         this.spawned = spawned;
+      }
+
+      public Server getServer()
+      {
+         return server;
+      }
+
+      public boolean isSpawned()
+      {
+         return spawned;
+      }
+   }
+
 }

Added: trunk/tests/src/org/jboss/test/messaging/tools/ant/JUnitTestSuiteListener.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ant/JUnitTestSuiteListener.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ant/JUnitTestSuiteListener.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -0,0 +1,122 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.tools.ant;
+
+import org.apache.tools.ant.taskdefs.optional.junit.JUnitResultFormatter;
+import org.apache.tools.ant.taskdefs.optional.junit.JUnitTest;
+import org.apache.tools.ant.BuildException;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+import java.io.OutputStream;
+import java.util.List;
+import java.util.Iterator;
+
+import junit.framework.Test;
+import junit.framework.AssertionFailedError;
+
+/**
+ * This class is a hack.
+ *
+ * I needed a way to intercept the end of a forked ant JUnit test run, in order to perform some
+ * clean-up, and this is it: register this class as a JUnit batchtest formatter, and it will get
+ * notified on a endTestSuite() event. Very important, it is run in the same address space as the
+ * tests themselves.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class JUnitTestSuiteListener implements JUnitResultFormatter
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   // JUnitResultFormatter implementation ---------------------------
+
+   public void endTestSuite(JUnitTest suite) throws BuildException
+   {
+      try
+      {
+         List destroyed = ServerManagement.destroySpawnedServers();
+         if (destroyed.size() > 0)
+         {
+            StringBuffer sb = new StringBuffer("Destroyed spawned test servers ");
+            for(Iterator i = destroyed.iterator(); i.hasNext();)
+            {
+               sb.append(i.next());
+               if (i.hasNext())
+               {
+                  sb.append(',');
+               }
+            }
+            System.out.println(sb);
+         }
+      }
+      catch(Throwable t)
+      {
+         t.printStackTrace();
+      }
+   }
+
+   public void startTestSuite(JUnitTest suite) throws BuildException
+   {
+      // noop
+   }
+
+   public void setOutput(OutputStream out)
+   {
+      // noop
+   }
+
+   public void setSystemOutput(String out)
+   {
+      // noop
+   }
+
+   public void setSystemError(String err)
+   {
+      // noop
+   }
+
+   // TestListener implementation -----------------------------------
+
+   public void addError(Test test, Throwable t)
+   {
+      // noop
+   }
+
+   public void addFailure(Test test, AssertionFailedError t)
+   {
+      // noop
+   }
+
+   public void endTest(Test test)
+   {
+      // noop
+   }
+
+   public void startTest(Test test)
+   {
+      // noop
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -398,6 +398,8 @@
 
          loadJNDIContexts();
 
+         log.debug("loaded JNDI context");
+
          String transport = config.getRemotingTransport();
 
          log.info("Remoting type: ........... " + (remoting ? transport : "DISABLED"));
@@ -1251,6 +1253,8 @@
 
          int rows = ps.executeUpdate();
 
+         log.debug("JMS_POSTOFFICE: deleted " + rows);
+
          ps.close();
 
          sql = "DELETE FROM JMS_MESSAGE_REFERENCE";
@@ -1258,7 +1262,7 @@
 
          rows = ps.executeUpdate();
 
-         log.debug("deleted " + rows);
+         log.debug("JMS_MESSAGE_REFERENCE: deleted " + rows);
 
          ps.close();
 
@@ -1267,7 +1271,7 @@
 
          rows = ps.executeUpdate();
 
-         log.debug("deleted " + rows);
+         log.debug("JMS_MESSAGE: deleted " + rows);
 
          ps.close();
 
@@ -1276,7 +1280,7 @@
 
          rows = ps.executeUpdate();
 
-         log.debug("deleted " + rows);
+         log.debug("JMS_TRANSACTION: deleted " + rows);
 
          ps.close();
 
@@ -1285,7 +1289,7 @@
 
          rows = ps.executeUpdate();
 
-         log.debug("deleted " + rows);
+         log.debug("JMS_COUNTER: deleted " + rows);
 
          ps.close();
 
@@ -1294,17 +1298,21 @@
 
          rows = ps.executeUpdate();
 
-         log.debug("deleted " + rows);
+         log.debug("JMS_USER: deleted " + rows);
 
          ps.close();
          conn.close();
 
          mgr.commit();
 
+         log.debug("committed");
+
          if (txOld != null)
          {
             mgr.resume(txOld);
          }
+
+         log.debug("done with the database");
       }
       catch (SQLException e)
       {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -108,6 +108,11 @@
 
    // Server implementation -----------------------------------------
 
+   public int getServerID()
+   {
+      return serverIndex;
+   }
+
    public synchronized void start(String containerConfig) throws Exception
    {
       if (isStarted())
@@ -833,11 +838,6 @@
 
    // Public --------------------------------------------------------
 
-   public int getServerIndex()
-   {
-      return serverIndex;
-   }
-
    // Package protected ---------------------------------------------
 
    ServiceContainer getServiceContainer()

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -135,6 +135,11 @@
 
    // Server implementation -----------------------------------------
 
+   public int getServerID()
+   {
+      return server.getServerID();
+   }
+
    public void start(String containerConfig) throws Exception
    {
       server.start(containerConfig);
@@ -459,11 +464,14 @@
             // unregister myself from the RMI registry
 
             Registry registry = LocateRegistry.getRegistry(DEFAULT_REGISTRY_PORT);
-            registry.unbind(RMI_SERVER_PREFIX + server.getServerIndex());
 
-            log.info("unregistred from " + registry);
+            String name = RMI_SERVER_PREFIX + server.getServerID();
+            registry.unbind(name);
+            log.info("unregistred " + name + " from registry");
 
-
+            name = NAMING_SERVER_PREFIX + server.getServerID();
+            registry.unbind(name);
+            log.info("unregistred " + name + " from registry");
          }
          catch(Exception e)
          {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -31,7 +31,6 @@
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
-import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 
 /**
@@ -44,6 +43,8 @@
  */
 public interface Server extends Remote
 {
+   int getServerID() throws Exception;
+
    void start(String containerConfig) throws Exception;
 
    void stop() throws Exception;

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/StopRMIServer.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -23,6 +23,8 @@
 
 import java.rmi.ConnectException;
 import java.rmi.Naming;
+import java.rmi.NotBoundException;
+
 import org.jboss.logging.Logger;
 
 /**
@@ -78,6 +80,11 @@
          log.info("Cannot contact the registry, the server is probably shut down already");
          return;
       }
+      catch(NotBoundException e)
+      {
+         log.info("Cannot lookup " + name + ", the server is probably shut down already");
+         return;
+      }
 
       // We should shut down cleanly - not kill the process like we are currently doing
       

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -56,9 +56,9 @@
          "//localhost:" + RMITestServer.DEFAULT_REGISTRY_PORT + "/" +
           RMITestServer.NAMING_SERVER_PREFIX + remoteServerIndex;
       
-      log.info("Using this url for rmi server lookup " + n);
-      
       namingDelegate = (NamingDelegate)Naming.lookup(n);
+
+      log.info("remote context for server " + remoteServerIndex + " acquired from rmi:" + n);
    }
 
    // Context implementation ----------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteInitialContextFactory.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -47,8 +47,6 @@
     */
    public static Hashtable getJNDIEnvironment(int serverIndex)
    {
-      log.info("Returning remote context... server index:" + serverIndex);
-      
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial",
               "org.jboss.test.messaging.tools.jndi.RemoteInitialContextFactory");
@@ -74,8 +72,6 @@
                                             "entry for " + Constants.SERVER_INDEX_PROPERTY_NAME);
       }
 
-      log.info("Created initial context for " + s);
-
       int remoteServerIndex = Integer.parseInt(s);
 
       try

Modified: trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-14 21:28:22 UTC (rev 1797)
+++ trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-15 08:59:37 UTC (rev 1798)
@@ -35,56 +35,34 @@
 
    // Public --------------------------------------------------------
 
-   public void testFailureToSpawnStartedServer() throws Exception
+   public void testSpawnServer() throws Exception
    {
       try
       {
-         ServerManagement.start("all", 0);
+         ServerManagement.start(0, "all");
 
-         try
-         {
-            ServerManagement.spawn(0);
-            fail("It should have failed!");
-         }
-         catch(Exception e)
-         {
-            // OK
-         }
+         ServerManagement.start(0, "all");
       }
       finally
       {
-         ServerManagement.stop(0);
+         ServerManagement.kill(0);
       }
    }
 
-   public void testFailureToSpawnExistingRemoteServer() throws Exception
+   public void testSimpleSpawn() throws Exception
    {
-      if (ServerManagement.isLocal())
+      if (!ServerManagement.isRemote())
       {
-         // irrelevant for a colocated configuration
-         return;
+         fail("This test must be run in remote mode!");
       }
 
-      // this assumes that the remote server 0 has been started externally by and or by a script
-
       try
       {
-         ServerManagement.spawn(0);
-         fail("This should have failed!");
-      }
-      catch(Exception e)
-      {
-         // OK
-      }
-   }
+         log.info("Waiting for server 7 to start ...");
 
-   public void testSimpleSpawn() throws Exception
-   {
-      try
-      {
-         ServerManagement.spawn(7);
+         ServerManagement.start(7, "all");
 
-         ServerManagement.start("all", 7);
+         log.info("Server 7 started");
 
          Integer index = (Integer)ServerManagement.
             getAttribute(7, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
@@ -99,43 +77,62 @@
       }
       finally
       {
+         log.info("Killing server 7");
          ServerManagement.kill(7);
       }
    }
 
-   /**
-    * Needs to be run in clustered mode.
-    */
    public void testRessurect() throws Exception
    {
-
-      if (!ServerManagement.isClustered())
+      if (!ServerManagement.isRemote())
       {
-         fail("This test must be run in clustered mode!");
+         fail("This test must be run in remote mode!");
       }
 
-      ServerManagement.start("all", 1);
+      try
+      {
+         ServerManagement.start(1, "all");
 
-      ServerManagement.kill(1);
+         ServerManagement.kill(1);
 
-      // wait a bit for the server to die
-      
-      log.info("Sleeping for 10 seconds ...");
+         // wait a bit for the server to die
 
-      Thread.sleep(10000);
+         log.info("Sleeping for 10 seconds ...");
 
-      // resurrect the server
+         Thread.sleep(10000);
 
-      ServerManagement.spawn(1);
-      ServerManagement.start("all", 1);
+         // resurrect the server
 
-      Integer index = (Integer)ServerManagement.
-         getAttribute(1, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
+         ServerManagement.start(1, "all");
 
-      assertEquals(1, index.intValue());
+         Integer index = (Integer)ServerManagement.
+            getAttribute(1, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
+
+         assertEquals(1, index.intValue());
+
+         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+
+         ic.bind("/xxx", "yyy");
+
+         assertEquals("yyy", ic.lookup("/xxx"));
+      }
+      finally
+      {
+         ServerManagement.kill(1);
+      }
    }
 
+   public void testA()
+   {
+      System.out.println("A");
+   }
 
+   public void testB()
+   {
+      System.out.println("B");
+   }
+
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -150,6 +147,9 @@
    protected void tearDown() throws Exception
    {
       super.tearDown();
+
+      // TODO: clean up spawned servers
+
    }
 
    // Private -------------------------------------------------------



From gavin.king at jboss.com  Fri Dec 15 04:17:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 04:17:40 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1Gv9CG-0001FM-GI@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 04:17:40

  Modified:    seam-gen/resources/META-INF  persistence.xml
  Log:
  mo' betta' handling of schemas and catalogs
  
  Revision  Changes    Path
  1.8       +2 -0      jboss-seam/seam-gen/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/persistence.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- persistence.xml	3 Dec 2006 04:55:16 -0000	1.7
  +++ persistence.xml	15 Dec 2006 09:17:40 -0000	1.8
  @@ -12,6 +12,8 @@
            <property name="hibernate.cache.use_query_cache" value="true"/>
            <property name="hibernate.show_sql" value="true"/>
            <property name="jboss.entity.manager.factory.jndi.name" value="java:/@projectName at EntityManagerFactory"/>
  +         @catalogProperty@
  +         @schemaProperty@
         </properties>
      </persistence-unit>
       
  
  
  


From gavin.king at jboss.com  Fri Dec 15 04:17:40 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 04:17:40 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gv9CG-0001FT-KQ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 04:17:40

  Modified:    seam-gen  build.xml
  Log:
  mo' betta' handling of schemas and catalogs
  
  Revision  Changes    Path
  1.52      +33 -1     jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -b -r1.51 -r1.52
  --- build.xml	15 Dec 2006 08:32:39 -0000	1.51
  +++ build.xml	15 Dec 2006 09:17:40 -0000	1.52
  @@ -58,11 +58,27 @@
       
   	<!-- filtersets and filesets -->
   	
  +	<condition property="schema.property" value="&lt;property name=&quot;hibernate.default_schema&quot; value=&quot;${hibernate.default_schema}&quot;/&gt;">
  +	    <isset property="hibernate.default_schema"/>
  +	</condition>
  +	<condition property="schema.property" value="">
  +	    <not><isset property="hibernate.default_schema"/></not>
  +	</condition>
  +	
  +	<condition property="catalog.property" value="&lt;property name=&quot;hibernate.default_catalog&quot; value=&quot;${hibernate.default_catalog}&quot;/&gt;">
  +	    <isset property="hibernate.default_catalog"/>
  +	</condition>
  +	<condition property="catalog.property" value="">
  +	    <not><isset property="hibernate.default_catalog"/></not>
  +	</condition>
  +
       <filterset id="jdbc">
           <filter token="jdbcUrl" value="${hibernate.connection.url}"/>
           <filter token="driverClass" value="${hibernate.connection.driver_class}"/>
           <filter token="username" value="${hibernate.connection.username}"/>
           <filter token="password" value="${hibernate.connection.password}"/>
  +    	<filter token="catalogProperty" value="${catalog.property}"/>
  +    	<filter token="schemaProperty" value="${schema.property}"/>
       </filterset>
   
       <filterset id="project">
  @@ -266,10 +282,18 @@
                 defaultvalue="${hibernate.connection.password}"/>
                   
           <property name="hibernate.default_schema" value=""/>
  +    	<condition property="hibernate.default_schema.new" value="">
  +            <equals arg1="${database.type.new}" arg2="mysql"/>
  +    	</condition>
           <input addproperty="hibernate.default_schema.new" 
                      message="Enter the database schema name (it is OK to leave this blank) [${hibernate.default_schema}]" 
                 defaultvalue="${hibernate.default_schema}"/>
                   
  +        <property name="hibernate.default_catalog" value=""/>
  +        <input addproperty="hibernate.default_catalog.new" 
  +                   message="Enter the database catalog name (it is OK to leave this blank) [${hibernate.default_catalog}]" 
  +              defaultvalue="${hibernate.default_catalog}"/>
  +                
           <property name="database.exists" value="n"/>
           <input addproperty="database.exists.new" 
                      message="Are you working with tables that already exist in the database? [${database.exists}] "
  @@ -289,6 +313,13 @@
       	    <equals arg1="${hibernate.default_schema.new}" arg2=""/>
       	</condition>
   
  +    	<condition property="hibernate.default_catalog.key" value="hibernate.default_catalog">
  +    	    <not><equals arg1="${hibernate.default_catalog.new}" arg2=""/></not>
  +    	</condition>
  +    	<condition property="hibernate.default_catalog.key" value="hibernate.default_catalog.null">
  +    	    <equals arg1="${hibernate.default_catalog.new}" arg2=""/>
  +    	</condition>
  +
           <propertyfile file="build.properties">
               <entry key="workspace.home" value="${workspace.home.new}"/>
               <entry key="project.name" value="${project.name.new}"/>
  @@ -308,6 +339,7 @@
               <entry key="hibernate.connection.password" value="${hibernate.connection.password.new}"/>
               <entry key="hibernate.connection.password" value="${hibernate.connection.password.new}"/>
               <entry key="${hibernate.default_schema.key}" value="${hibernate.default_schema.new}"/>
  +            <entry key="${hibernate.default_catalog.key}" value="${hibernate.default_catalog.new}"/>
           </propertyfile>
       	
       	<echo message="Installing JDBC driver jar to JBoss server"/>
  
  
  


From gavin.king at jboss.com  Fri Dec 15 04:24:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 04:24:51 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gv9JD-0001Km-BF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 04:24:51

  Modified:    seam-gen  build.xml
  Log:
  mo' betta' handling of schemas and catalogs
  
  Revision  Changes    Path
  1.53      +2 -2      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.52
  retrieving revision 1.53
  diff -u -b -r1.52 -r1.53
  --- build.xml	15 Dec 2006 09:17:40 -0000	1.52
  +++ build.xml	15 Dec 2006 09:24:51 -0000	1.53
  @@ -58,14 +58,14 @@
       
   	<!-- filtersets and filesets -->
   	
  -	<condition property="schema.property" value="&lt;property name=&quot;hibernate.default_schema&quot; value=&quot;${hibernate.default_schema}&quot;/&gt;">
  +	<condition property="schema.property" value="&#xa;         &lt;property name=&quot;hibernate.default_schema&quot; value=&quot;${hibernate.default_schema}&quot;/&gt;">
   	    <isset property="hibernate.default_schema"/>
   	</condition>
   	<condition property="schema.property" value="">
   	    <not><isset property="hibernate.default_schema"/></not>
   	</condition>
   	
  -	<condition property="catalog.property" value="&lt;property name=&quot;hibernate.default_catalog&quot; value=&quot;${hibernate.default_catalog}&quot;/&gt;">
  +	<condition property="catalog.property" value="&#xa;         &lt;property name=&quot;hibernate.default_catalog&quot; value=&quot;${hibernate.default_catalog}&quot;/&gt;">
   	    <isset property="hibernate.default_catalog"/>
   	</condition>
   	<condition property="catalog.property" value="">
  
  
  


From gavin.king at jboss.com  Fri Dec 15 04:24:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 04:24:51 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources/META-INF  ...
Message-ID: <E1Gv9JD-0001Kt-Er@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 04:24:51

  Modified:    seam-gen/resources/META-INF  persistence.xml
  Log:
  mo' betta' handling of schemas and catalogs
  
  Revision  Changes    Path
  1.9       +1 -3      jboss-seam/seam-gen/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/META-INF/persistence.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- persistence.xml	15 Dec 2006 09:17:40 -0000	1.8
  +++ persistence.xml	15 Dec 2006 09:24:51 -0000	1.9
  @@ -11,9 +11,7 @@
            <property name="hibernate.hbm2ddl.auto" value="@hbm2ddl@"/>
            <property name="hibernate.cache.use_query_cache" value="true"/>
            <property name="hibernate.show_sql" value="true"/>
  -         <property name="jboss.entity.manager.factory.jndi.name" value="java:/@projectName at EntityManagerFactory"/>
  -         @catalogProperty@
  -         @schemaProperty@
  +         <property name="jboss.entity.manager.factory.jndi.name" value="java:/@projectName at EntityManagerFactory"/>@catalogProperty@@schemaProperty@
         </properties>
      </persistence-unit>
       
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 07:42:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 07:42:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r59061 -
	branches/JBoss_4_0_3_SP1_JBAS-3944/tomcat/src/main/org/jboss/web/tomcat/security
Message-ID: <E1GvCOm-00055L-0Z@committer01.frg.pub.inap.atl.jboss.com>

Author: galder.zamarreno at jboss.com
Date: 2006-12-15 07:42:46 -0500 (Fri, 15 Dec 2006)
New Revision: 59061

Modified:
   branches/JBoss_4_0_3_SP1_JBAS-3944/tomcat/src/main/org/jboss/web/tomcat/security/BasicAuthValve.java
Log:
[JBAS-3944] Added JBAS-2650

Modified: branches/JBoss_4_0_3_SP1_JBAS-3944/tomcat/src/main/org/jboss/web/tomcat/security/BasicAuthValve.java
===================================================================
--- branches/JBoss_4_0_3_SP1_JBAS-3944/tomcat/src/main/org/jboss/web/tomcat/security/BasicAuthValve.java	2006-12-14 18:37:14 UTC (rev 59060)
+++ branches/JBoss_4_0_3_SP1_JBAS-3944/tomcat/src/main/org/jboss/web/tomcat/security/BasicAuthValve.java	2006-12-15 12:42:46 UTC (rev 59061)
@@ -1,9 +1,24 @@
 /*
- * JBoss, Home of Professional Open Source
- *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
- */
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.web.tomcat.security;
 
 import java.io.IOException;
@@ -29,7 +44,11 @@
    private static Logger log = Logger.getLogger(BasicAuthValve.class);
    private static boolean trace = log.isTraceEnabled();
 
+   /** Should the exception message be used as the request status message */
    private boolean useExceptionAsMsg = false;
+   /** A flag indicating if the auth exception thread local should be cleared */
+   private boolean clearAuthException = true;
+   /** The name of the reply header to use to return the exception message */
    private String exceptionHeader = null;
 
    public boolean isUseExceptionAsMsg()
@@ -55,7 +74,7 @@
    {
       getNext().invoke(request, response);
       // Check the SecurityAssociation context exception
-      Throwable t = (Throwable) SecurityAssociationActions.getAuthException();
+      Throwable t = SecurityAssociationActions.getAuthException();
       int status = response.getStatus();
       
       if( trace )
@@ -72,6 +91,18 @@
          // Set the response exception header
          if( exceptionHeader != null )
             response.setHeader(exceptionHeader, msg);
+         // Clear the exception thread local
+         if( clearAuthException )
+         {
+            try
+            {
+               SecurityAssociationActions.clearAuthException();
+            }
+            catch(Throwable e)
+            {
+               log.warn("Unable to clear auth exception ", e);
+            }
+         }
       }
    }
 }



From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 07:52:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 07:52:45 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1799 - in trunk:
	src/etc/server/default/deploy src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/messaging/core tests/bin
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GvCYP-0005Hw-63@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-15 07:52:36 -0500 (Fri, 15 Dec 2006)
New Revision: 1799

Modified:
   trunk/src/etc/server/default/deploy/remoting-service.xml
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/tests/bin/runtest
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
a bit of logging and some minor changes to tests



Modified: trunk/src/etc/server/default/deploy/remoting-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/remoting-service.xml	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/src/etc/server/default/deploy/remoting-service.xml	2006-12-15 12:52:36 UTC (rev 1799)
@@ -23,7 +23,7 @@
                <attribute name="timeout">0</attribute>
                <attribute name="serverBindAddress">${jboss.bind.address}</attribute>
                <attribute name="serverBindPort">4457</attribute>
-               <attribute name="leasePeriod">20000</attribute>
+               <attribute name="leasePeriod">10000</attribute>
                <attribute name="callbackStore">org.jboss.remoting.callback.CallbackStore</attribute>
                <attribute name="clientSocketClass" isParam="true">org.jboss.jms.client.remoting.ClientSocketWrapper</attribute>
                <attribute name="serverSocketClass">org.jboss.jms.server.remoting.ServerSocketWrapper</attribute>

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-15 12:52:36 UTC (rev 1799)
@@ -217,7 +217,7 @@
 
    public String toString()
    {
-      return "ConnectionDelegate[" + id + ", " + serverID + "]";
+      return "ConnectionDelegate[id:" + id + ", serverid:" + serverID + "]";
    }
 
    public void init()

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-15 12:52:36 UTC (rev 1799)
@@ -497,7 +497,7 @@
       //debug
       Iterator iter = messageIds.iterator();
       
-      log.info("***** createdeliveries");
+      log.info("***** createdeliveries:" + messageIds.size());
       while (iter.hasNext())
       {
          Long l = (Long)iter.next();
@@ -527,7 +527,7 @@
                   {
                      // TODO we need to look in paging state too - currently not supported
                      
-                     throw new IllegalStateException("Cannot find ref in queue! (Might be paged!)");
+                     throw new IllegalStateException("Cannot find ref in queue! (Might be paged!) " + id);
                   }
                   
                   MessageReference ref = (MessageReference)liter.next();

Modified: trunk/tests/bin/runtest
===================================================================
--- trunk/tests/bin/runtest	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/tests/bin/runtest	2006-12-15 12:52:36 UTC (rev 1799)
@@ -48,6 +48,8 @@
    TEST_REMOTING=$ENV_TEST_REMOTING
 fi
 
+TEST_DATABASE=mysql
+
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get
 # it from there.

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-15 12:52:36 UTC (rev 1799)
@@ -26,11 +26,11 @@
 import java.util.Set;
 
 import javax.jms.Connection;
+import javax.jms.Message;
 import javax.jms.MessageConsumer;
 import javax.jms.MessageProducer;
 import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.jms.Message;
 
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
@@ -583,6 +583,12 @@
       log.info("server 1 id: " + server1Id);
 
       log.info("server 2 id: " + server2Id);
+      
+      assertEquals(0, server0Id);
+      
+      assertEquals(1, server1Id);
+      
+      assertEquals(2, server2Id);
 
       Map failoverMap = delegate.getFailoverMap();
 
@@ -651,6 +657,7 @@
          //So we now kill server 1
          //Which should cause transparent failover of connection conn onto server 1
 
+         log.info("here we go");
          log.info("######");
          log.info("###### KILLING (CRASHING) SERVER 1");
          log.info("######");
@@ -661,7 +668,7 @@
 
          log.info("killed server, now waiting");
 
-         Thread.sleep(10000);
+         Thread.sleep(5000);
 
          log.info("done wait");
 
@@ -685,12 +692,12 @@
 
          for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
          {
-            tm = (TextMessage)cons.receive(500);
+            tm = (TextMessage)cons.receive(1000);
 
+            assertNotNull(tm);
+            
             log.info("message is " + tm.getText());
 
-            assertNotNull(tm);
-
             assertEquals("message:" + i, tm.getText());
          }
 
@@ -737,189 +744,189 @@
    }
 
    
-//   public void testFailoverWithUnackedMessagesTransactional() throws Exception
-//   {
-//      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
-//
-//      ClusteredClientConnectionFactoryDelegate delegate =
-//         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-//
-//      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
-//      assertEquals(3, nodeIDView.size());
-//
-//      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
-//
-//      ClientConnectionFactoryDelegate cf1 = delegates[0];
-//
-//      ClientConnectionFactoryDelegate cf2 = delegates[1];
-//
-//      ClientConnectionFactoryDelegate cf3 = delegates[2];
-//
-//      int server0Id = cf1.getServerID();
-//
-//      int server1Id = cf2.getServerID();
-//
-//      int server2Id = cf3.getServerID();
-//
-//      log.info("server 0 id: " + server0Id);
-//
-//      log.info("server 1 id: " + server1Id);
-//
-//      log.info("server 2 id: " + server2Id);
-//
-//      Map failoverMap = delegate.getFailoverMap();
-//
-//      log.info(failoverMap.get(new Integer(server0Id)));
-//      log.info(failoverMap.get(new Integer(server1Id)));
-//      log.info(failoverMap.get(new Integer(server2Id)));
-//
-//      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
-//
-//      // server 1 should failover onto server 2
-//
-//      assertEquals(server2Id, server1FailoverId);
-//
-//      Connection conn = null;
-//
-//      boolean killed = false;
-//
-//      try
-//      {
-//         //Get a connection on server 1
-//         conn = factory.createConnection(); //connection on server 0
-//
-//         conn.close();
-//
-//         conn = factory.createConnection(); //connection on server 1
-//
-//         JBossConnection jbc = (JBossConnection)conn;
-//
-//         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
-//
-//         ConnectionState state = (ConnectionState)del.getState();
-//
-//         int initialServerID = state.getServerID();
-//
-//         assertEquals(1, initialServerID);
-//
-//         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
-//
-//         MessageProducer prod = sess.createProducer(queue[1]);
-//
-//         MessageConsumer cons = sess.createConsumer(queue[1]);
-//
-//         final int NUM_MESSAGES = 100;
-//
-//         for (int i = 0; i < NUM_MESSAGES; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("message:" + i);
-//
-//            prod.send(tm);
-//         }
-//
-//         sess.commit();
-//
-//         conn.start();
-//
-//         //Now consume half of the messages but don't commit them these will end up in
-//         //client side resource manager
-//
-//         for (int i = 0; i < NUM_MESSAGES / 2; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons.receive(500);
-//
-//            assertNotNull(tm);
-//
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//
-//         //So now, messages should be in queue[1] on server 1
-//         //So we now kill server 1
-//         //Which should cause transparent failover of connection conn onto server 1
-//
-//         log.info("######");
-//         log.info("###### KILLING (CRASHING) SERVER 1");
-//         log.info("######");
-//
-//         ServerManagement.kill(1);
-//
-//         killed = true;
-//
-//         log.info("killed server, now waiting");
-//
-//         Thread.sleep(5000);
-//
-//         log.info("done wait");
-//
-//         state = (ConnectionState)del.getState();
-//
-//         int finalServerID = state.getServerID();
-//
-//         log.info("final server id= " + finalServerID);
-//
-//         //server id should now be 2
-//
-//         assertEquals(2, finalServerID);
-//
-//         conn.start();
-//
-//         //Now should be able to consume the rest of the messages
-//
-//         log.info("here1");
-//
-//         TextMessage tm = null;
-//
-//         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
-//         {
-//            tm = (TextMessage)cons.receive(500);
-//
-//            log.info("message is " + tm.getText());
-//
-//            assertNotNull(tm);
-//
-//            assertEquals("message:" + i, tm.getText());
-//         }
-//
-//         log.info("here2");
-//
-//         //Now should be able to commit them
-//
-//         sess.commit();
-//
-//         //Now check there are no more messages there
-//         sess.close();
-//
-//         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//
-//         cons = sess.createConsumer(queue[1]);
-//
-//         Message m = cons.receive(500);
-//
-//         assertNull(m);
-//
-//         log.info("got to end of test");
-//      }
-//      finally
-//      {
-//         if (conn != null)
-//         {
-//            try
-//            {
-//               conn.close();
-//            }
-//            catch (Exception e)
-//            {
-//               e.printStackTrace();
-//            }
-//         }
-//
-//         if (killed)
-//         {
-//            ServerManagement.spawn(1);
-//         }
-//      }
-//
-//   }
+   public void testFailoverWithUnackedMessagesTransactional() throws Exception
+   {
+      JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
+
+      ClusteredClientConnectionFactoryDelegate delegate =
+         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+
+      Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
+      assertEquals(3, nodeIDView.size());
+
+      ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
+
+      ClientConnectionFactoryDelegate cf1 = delegates[0];
+
+      ClientConnectionFactoryDelegate cf2 = delegates[1];
+
+      ClientConnectionFactoryDelegate cf3 = delegates[2];
+
+      int server0Id = cf1.getServerID();
+
+      int server1Id = cf2.getServerID();
+
+      int server2Id = cf3.getServerID();
+
+      log.info("server 0 id: " + server0Id);
+
+      log.info("server 1 id: " + server1Id);
+
+      log.info("server 2 id: " + server2Id);
+
+      Map failoverMap = delegate.getFailoverMap();
+
+      log.info(failoverMap.get(new Integer(server0Id)));
+      log.info(failoverMap.get(new Integer(server1Id)));
+      log.info(failoverMap.get(new Integer(server2Id)));
+
+      int server1FailoverId = ((Integer)failoverMap.get(new Integer(server1Id))).intValue();
+
+      // server 1 should failover onto server 2
+
+      assertEquals(server2Id, server1FailoverId);
+
+      Connection conn = null;
+
+      boolean killed = false;
+
+      try
+      {
+         //Get a connection on server 1
+         conn = factory.createConnection(); //connection on server 0
+
+         conn.close();
+
+         conn = factory.createConnection(); //connection on server 1
+
+         JBossConnection jbc = (JBossConnection)conn;
+
+         ClientConnectionDelegate del = (ClientConnectionDelegate)jbc.getDelegate();
+
+         ConnectionState state = (ConnectionState)del.getState();
+
+         int initialServerID = state.getServerID();
+
+         assertEquals(1, initialServerID);
+
+         Session sess = conn.createSession(true, Session.SESSION_TRANSACTED);
+
+         MessageProducer prod = sess.createProducer(queue[1]);
+
+         MessageConsumer cons = sess.createConsumer(queue[1]);
+
+         final int NUM_MESSAGES = 100;
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("message:" + i);
+
+            prod.send(tm);
+         }
+
+         sess.commit();
+
+         conn.start();
+
+         //Now consume half of the messages but don't commit them these will end up in
+         //client side resource manager
+
+         for (int i = 0; i < NUM_MESSAGES / 2; i++)
+         {
+            TextMessage tm = (TextMessage)cons.receive(500);
+
+            assertNotNull(tm);
+
+            assertEquals("message:" + i, tm.getText());
+         }
+
+         //So now, messages should be in queue[1] on server 1
+         //So we now kill server 1
+         //Which should cause transparent failover of connection conn onto server 1
+
+         log.info("######");
+         log.info("###### KILLING (CRASHING) SERVER 1");
+         log.info("######");
+
+         ServerManagement.kill(1);
+
+         killed = true;
+
+         log.info("killed server, now waiting");
+
+         Thread.sleep(5000);
+
+         log.info("done wait");
+
+         state = (ConnectionState)del.getState();
+
+         int finalServerID = state.getServerID();
+
+         log.info("final server id= " + finalServerID);
+
+         //server id should now be 2
+
+         assertEquals(2, finalServerID);
+
+         conn.start();
+
+         //Now should be able to consume the rest of the messages
+
+         log.info("here1");
+
+         TextMessage tm = null;
+
+         for (int i = NUM_MESSAGES / 2; i < NUM_MESSAGES; i++)
+         {
+            tm = (TextMessage)cons.receive(500);
+
+            log.info("message is " + tm.getText());
+
+            assertNotNull(tm);
+
+            assertEquals("message:" + i, tm.getText());
+         }
+
+         log.info("here2");
+
+         //Now should be able to commit them
+
+         sess.commit();
+
+         //Now check there are no more messages there
+         sess.close();
+
+         sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         cons = sess.createConsumer(queue[1]);
+
+         Message m = cons.receive(500);
+
+         assertNull(m);
+
+         log.info("got to end of test");
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Exception e)
+            {
+               e.printStackTrace();
+            }
+         }
+
+         if (killed)
+         {
+            ServerManagement.start(1, "all");
+         }
+      }
+
+   }
    
    
 // public void testConnectionFactoryConnect() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-15 12:52:36 UTC (rev 1799)
@@ -458,7 +458,6 @@
       {
          log.info("shutting down the VM");
 
-
          try
          {
             // unregister myself from the RMI registry
@@ -467,11 +466,11 @@
 
             String name = RMI_SERVER_PREFIX + server.getServerID();
             registry.unbind(name);
-            log.info("unregistred " + name + " from registry");
+            log.info("unregistered " + name + " from registry");
 
             name = NAMING_SERVER_PREFIX + server.getServerID();
             registry.unbind(name);
-            log.info("unregistred " + name + " from registry");
+            log.info("unregistered " + name + " from registry");
          }
          catch(Exception e)
          {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-15 12:52:36 UTC (rev 1799)
@@ -22,11 +22,13 @@
 package org.jboss.test.messaging.tools.jmx.rmi;
 
 import java.rmi.Remote;
+import java.util.List;
 import java.util.Set;
-import java.util.List;
+
+import javax.management.NotificationListener;
 import javax.management.ObjectName;
-import javax.management.NotificationListener;
 import javax.transaction.UserTransaction;
+
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.messaging.core.plugin.contract.MessageStore;



From gavin.king at jboss.com  Fri Dec 15 07:52:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 07:52:45 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GvCYP-0005IF-RZ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 07:52:45

  Modified:    src/main/org/jboss/seam/core  ConversationEntry.java
  Log:
  fix JBSEAM-593
  
  Revision  Changes    Path
  1.32      +0 -10     jboss-seam/src/main/org/jboss/seam/core/ConversationEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ConversationEntry.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- ConversationEntry.java	17 Nov 2006 07:12:55 -0000	1.31
  +++ ConversationEntry.java	15 Dec 2006 12:52:45 -0000	1.32
  @@ -59,11 +59,6 @@
   
      public String getDescription() 
      {
  -      if ( isCurrent() )
  -      {
  -         String desc = Conversation.instance().description;
  -         if (desc!=null) return desc;
  -      }
         return description;
      }
   
  @@ -136,11 +131,6 @@
   
      public String getViewId()
      {
  -      if ( isCurrent() )
  -      {
  -         String out = Conversation.instance().viewId;
  -         if (out!=null) return out;
  -      }
         return viewId;
      }
   
  
  
  


From gavin.king at jboss.com  Fri Dec 15 08:26:32 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 08:26:32 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources  ...
Message-ID: <E1GvD56-00060k-OB@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 08:26:32

  Modified:    examples/booking/resources  import.sql
  Log:
  prices
  
  Revision  Changes    Path
  1.11      +20 -20    jboss-seam/examples/booking/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/import.sql,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- import.sql	25 Sep 2006 21:00:01 -0000	1.10
  +++ import.sql	15 Dec 2006 13:26:32 -0000	1.11
  @@ -1,22 +1,22 @@
   insert into Customer (username, password, name) values ('gavin', 'foobar', 'Gavin King')
   insert into Customer (username, password, name) values ('demo', 'demo', 'Demo User')
  -insert into Hotel (id, name, address, city, state, zip, country) values (1, 'Marriott Courtyard', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (2, 'Doubletree', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (3, 'W Hotel', 'Union Square, Manhattan', 'NY', 'NY', '10011', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (4, 'W Hotel', 'Lexington Ave, Manhattan', 'NY', 'NY', '10011', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (5, 'Hotel Rouge', '1315 16th Street NW', 'Washington', 'DC', '20036', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (6, '70 Park Avenue Hotel', '70 Park Avenue', 'NY', 'NY', '10011', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (8, 'Conrad Miami', '1395 Brickell Ave', 'Miami', 'FL', '33131', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (9, 'Sea Horse Inn', '2106 N Clairemont Ave', 'Eau Claire', 'WI', '54703', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (10, 'Super 8 Eau Claire Campus Area', '1151 W Macarthur Ave', 'Eau Claire', 'WI', '54701', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (11, 'Marriot Downtown', '55 Fourth Street', 'San Francisco', 'CA', '94103', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (12, 'Hilton Diagonal Mar', 'Passeig del Taulat 262-264', 'Barcelona', 'Catalunya', '08019', 'Spain')
  -insert into Hotel (id, name, address, city, state, zip, country) values (13, 'Hilton Tel Aviv', 'Independence Park', 'Tel Aviv', '', '63405', 'Israel')
  -insert into Hotel (id, name, address, city, state, zip, country) values (14, 'InterContinental Tokyo Bay', 'Takeshiba Pier', 'Tokyo', '', '105', 'Japan')
  -insert into Hotel (id, name, address, city, state, zip, country) values (15, 'Hotel Beaulac', ' Esplanade L?opold-Robert 2', 'Neuchatel', '', '2000', 'Switzerland')
  -insert into Hotel (id, name, address, city, state, zip, country) values (16, 'Conrad Treasury Place', 'William & George Streets', 'Brisbane', 'QLD', '4001', 'Australia')
  -insert into Hotel (id, name, address, city, state, zip, country) values (17, 'Ritz Carlton', '1228 Sherbrooke St', 'West Montreal', 'Quebec', 'H3G1H6', 'Canada')
  -insert into Hotel (id, name, address, city, state, zip, country) values (18, 'Ritz Carlton', 'Peachtree Rd, Buckhead', 'Atlanta', 'GA', '30326', 'USA')
  -insert into Hotel (id, name, address, city, state, zip, country) values (19, 'Swissotel', '68 Market Street', 'Sydney', 'NSW', '2000', 'Australia')
  -insert into Hotel (id, name, address, city, state, zip, country) values (20, 'Meli? White House', 'Albany Street', 'Regents Park London', '', 'NW13UP', 'Great Britain')
  -insert into Hotel (id, name, address, city, state, zip, country) values (21, 'Hotel Allegro', '171 West Randolph Street', 'Chicago', 'IL', '60601', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (1, 120, 'Marriott Courtyard', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (2, 180, 'Doubletree', 'Tower Place, Buckhead', 'Atlanta', 'GA', '30305', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (3, 450, 'W Hotel', 'Union Square, Manhattan', 'NY', 'NY', '10011', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (4, 450, 'W Hotel', 'Lexington Ave, Manhattan', 'NY', 'NY', '10011', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (5, 250, 'Hotel Rouge', '1315 16th Street NW', 'Washington', 'DC', '20036', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (6, 300, '70 Park Avenue Hotel', '70 Park Avenue', 'NY', 'NY', '10011', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (8, 300, 'Conrad Miami', '1395 Brickell Ave', 'Miami', 'FL', '33131', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (9, 80, 'Sea Horse Inn', '2106 N Clairemont Ave', 'Eau Claire', 'WI', '54703', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (10, 90, 'Super 8 Eau Claire Campus Area', '1151 W Macarthur Ave', 'Eau Claire', 'WI', '54701', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (11, 160, 'Marriot Downtown', '55 Fourth Street', 'San Francisco', 'CA', '94103', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (12, 200, 'Hilton Diagonal Mar', 'Passeig del Taulat 262-264', 'Barcelona', 'Catalunya', '08019', 'Spain')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (13, 210, 'Hilton Tel Aviv', 'Independence Park', 'Tel Aviv', '', '63405', 'Israel')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (14, 240, 'InterContinental Tokyo Bay', 'Takeshiba Pier', 'Tokyo', '', '105', 'Japan')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (15, 130, 'Hotel Beaulac', ' Esplanade L?opold-Robert 2', 'Neuchatel', '', '2000', 'Switzerland')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (16, 140, 'Conrad Treasury Place', 'William & George Streets', 'Brisbane', 'QLD', '4001', 'Australia')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (17, 230, 'Ritz Carlton', '1228 Sherbrooke St', 'West Montreal', 'Quebec', 'H3G1H6', 'Canada')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (18, 460, 'Ritz Carlton', 'Peachtree Rd, Buckhead', 'Atlanta', 'GA', '30326', 'USA')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (19, 220, 'Swissotel', '68 Market Street', 'Sydney', 'NSW', '2000', 'Australia')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (20, 250, 'Meli? White House', 'Albany Street', 'Regents Park London', '', 'NW13UP', 'Great Britain')
  +insert into Hotel (id, price, name, address, city, state, zip, country) values (21, 210, 'Hotel Allegro', '171 West Randolph Street', 'Chicago', 'IL', '60601', 'USA')
  
  
  


From gavin.king at jboss.com  Fri Dec 15 08:26:32 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 08:26:32 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1GvD56-00060u-Rz@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 08:26:32

  Modified:    examples/booking/src/org/jboss/seam/example/booking  
                        Booking.java Hotel.java
  Log:
  prices
  
  Revision  Changes    Path
  1.12      +14 -1     jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Booking.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Booking.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Booking.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- Booking.java	25 Oct 2006 15:31:57 -0000	1.11
  +++ Booking.java	15 Dec 2006 13:26:32 -0000	1.12
  @@ -1,7 +1,8 @@
  -//$Id: Booking.java,v 1.11 2006/10/25 15:31:57 gavin Exp $
  +//$Id: Booking.java,v 1.12 2006/12/15 13:26:32 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.io.Serializable;
  +import java.math.BigDecimal;
   import java.text.DateFormat;
   import java.util.Date;
   
  @@ -43,6 +44,18 @@
         this.user = user;
      }
   
  +   @Transient
  +   public BigDecimal getTotal()
  +   {
  +      return hotel.getPrice().multiply( new BigDecimal( getNights() ) );
  +   }
  +
  +   @Transient
  +   public int getNights()
  +   {
  +      return (int) ( checkoutDate.getTime() - checkinDate.getTime() ) / 1000 / 60 / 60 / 24;
  +   }
  +
      @Id @GeneratedValue
      public Long getId()
      {
  
  
  
  1.11      +14 -2     jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Hotel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Hotel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Hotel.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- Hotel.java	25 Oct 2006 15:31:57 -0000	1.10
  +++ Hotel.java	15 Dec 2006 13:26:32 -0000	1.11
  @@ -1,8 +1,10 @@
  -//$Id: Hotel.java,v 1.10 2006/10/25 15:31:57 gavin Exp $
  +//$Id: Hotel.java,v 1.11 2006/12/15 13:26:32 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.io.Serializable;
  +import java.math.BigDecimal;
   
  +import javax.persistence.Column;
   import javax.persistence.Entity;
   import javax.persistence.GeneratedValue;
   import javax.persistence.Id;
  @@ -22,6 +24,7 @@
      private String state;
      private String zip;
      private String country;
  +   private BigDecimal price;
      
      @Id @GeneratedValue
      public Long getId()
  @@ -88,12 +91,21 @@
      {
         return country;
      }
  -   
      public void setCountry(String country)
      {
         this.country = country;
      }
   
  +   @Column(precision=6, scale=2)
  +   public BigDecimal getPrice()
  +   {
  +      return price;
  +   }
  +   public void setPrice(BigDecimal price)
  +   {
  +      this.price = price;
  +   }
  +   
      @Override
      public String toString()
      {
  
  
  


From gavin.king at jboss.com  Fri Dec 15 08:26:33 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 08:26:33 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view    ...
Message-ID: <E1GvD57-000617-6T@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 08:26:33

  Modified:    examples/booking/view    book.xhtml confirm.xhtml
                        hotel.xhtml
  Log:
  prices
  
  Revision  Changes    Path
  1.28      +10 -1     jboss-seam/examples/booking/view/book.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: book.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/book.xhtml,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- book.xhtml	7 Dec 2006 01:59:23 -0000	1.27
  +++ book.xhtml	15 Dec 2006 13:26:32 -0000	1.28
  @@ -35,6 +35,15 @@
   			<div class="label">Country:</div>
   			<div class="output">#{hotel.country}</div>
   		</div>
  +        <div class="entry">
  +            <div class="label">Nightly rate:</div>
  +            <div class="output">
  +                <h:outputText value="#{hotel.price}">
  +                    <f:convertNumber type="currency"  
  +                                     currencySymbol="$"/>
  +                </h:outputText>
  +            </div>
  +        </div>
   		
   		<s:validateAll>
       
  
  
  
  1.17      +9 -0      jboss-seam/examples/booking/view/confirm.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: confirm.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/confirm.xhtml,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- confirm.xhtml	20 Nov 2006 19:42:56 -0000	1.16
  +++ confirm.xhtml	15 Dec 2006 13:26:33 -0000	1.17
  @@ -35,6 +35,15 @@
   			<div class="output">#{hotel.country}</div>
   		</div>
   		<div class="entry">
  +            <div class="label">Total payment:</div>
  +            <div class="output">
  +                <h:outputText value="#{booking.total}">
  +                    <f:convertNumber type="currency" 
  +                                     currencySymbol="$"/>
  +                </h:outputText>
  +            </div>
  +        </div>
  +		<div class="entry">
   			<div class="label">Check In Date:</div>
   			<div class="output"><h:outputText value="#{booking.checkinDate}"/></div>
   		</div>
  
  
  
  1.14      +9 -0      jboss-seam/examples/booking/view/hotel.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: hotel.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/hotel.xhtml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- hotel.xhtml	14 Nov 2006 05:50:59 -0000	1.13
  +++ hotel.xhtml	15 Dec 2006 13:26:33 -0000	1.14
  @@ -36,6 +36,15 @@
   		<div class="label">Country:</div>
   		<div class="output">#{hotel.country}</div>
   	</div>
  +    <div class="entry">
  +        <div class="label">Nightly rate:</div>
  +        <div class="output">
  +            <h:outputText value="#{hotel.price}">
  +                <f:convertNumber type="currency" 
  +                                 currencySymbol="$"/>
  +            </h:outputText>
  +        </div>
  +    </div>
   </div>
   <div class="section">
   	<h:form id="hotel">
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 15 08:36:43 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 15 Dec 2006 08:36:43 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GvDEx-0006Ce-Kv@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/15 08:36:43

  Modified:    jboss-seam  build.xml
  Log:
  some bug fixes, updates to security example
  
  Revision  Changes    Path
  1.122     +2 -0      jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.121
  retrieving revision 1.122
  diff -u -b -r1.121 -r1.122
  --- build.xml	13 Dec 2006 10:10:43 -0000	1.121
  +++ build.xml	15 Dec 2006 13:36:43 -0000	1.122
  @@ -153,6 +153,8 @@
           <include name="META-INF/ejb-jar.xml"/>
           <include name="META-INF/components.xml"/>
           <include name="META-INF/jboss.xml"/>
  +        <include name="META-INF/security-config.xml"/>
  +        <include name="META-INF/security-rules.drl"/>
       </fileset>
       
       <zipfileset id="example.ear.resources"
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 15 08:36:43 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 15 Dec 2006 08:36:43 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF   ...
Message-ID: <E1GvDEx-0006Co-Pf@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/15 08:36:43

  Modified:    examples/seamspace/resources/META-INF   application.xml
  Added:       examples/seamspace/resources/META-INF   security-config.xml
  Log:
  some bug fixes, updates to security example
  
  Revision  Changes    Path
  1.5       +20 -0     jboss-seam/examples/seamspace/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	14 Dec 2006 04:12:21 -0000	1.4
  +++ application.xml	15 Dec 2006 13:36:43 -0000	1.5
  @@ -37,4 +37,24 @@
   	  <java>drools-core-3.0.5.jar</java>
   	</module>    
   
  +  <module>
  +    <java>commons-jci-core-1.0-406301.jar</java>
  +	</module>
  +	
  +  <module>
  +    <java>commons-jci-janino-2.4.3.jar</java>
  +	</module>	
  +	
  +  <module>
  +    <java>commons-lang-2.1.jar</java>
  +	</module>
  +
  +  <module>
  +    <java>janino-2.4.3.jar</java>
  +	</module>
  +
  +  <module>
  +    <java>stringtemplate-2.3b6.jar</java>
  +	</module>	
  +
   </application>
  \ No newline at end of file
  
  
  
  1.1      date: 2006/12/15 13:36:43;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/resources/META-INF/security-config.xml
  
  Index: security-config.xml
  ===================================================================
  <security-config>
    
    <security-constraint>
      <web-resource-collection>
        <web-resource-name>Secure Page</web-resource-name>
        <url-pattern>/welcome.seam</url-pattern>
      </web-resource-collection>
      
      <auth-constraint>
        <role-name>user</role-name>
      </auth-constraint>
    </security-constraint>
    
    <roles>
      <role name="admin">
        <members>superuser</members>
        
        <permissions>
          <permission name="user" action="create"/>
          <permission name="user" action="modify"/>
          <permission name="user" action="delete"/>
        </permissions>
      </role>
      
      <role name="superuser">
        <members>user</members>
      
        <permissions>
          <permission name="account" action="create"/>
          <permission name="account" action="delete"/>
        </permissions>      
      </role>
      
      <role name="user">
        <permissions>
          <permission name="customer" action="create"/>
          <permission name="customer" action="delete"/>
        </permissions>    
      </role>
      
      <role name="guest">
        
      </role>
      
    </roles>
  
  </security-config>
  
  


From Shane_Bryzak at symantec.com  Fri Dec 15 08:36:43 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 15 Dec 2006 08:36:43 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF  ...
Message-ID: <E1GvDEx-0006Cv-U7@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/15 08:36:43

  Modified:    examples/seamspace/resources/WEB-INF  components.xml
  Log:
  some bug fixes, updates to security example
  
  Revision  Changes    Path
  1.8       +2 -7      jboss-seam/examples/seamspace/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/components.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- components.xml	14 Dec 2006 04:12:21 -0000	1.7
  +++ components.xml	15 Dec 2006 13:36:43 -0000	1.8
  @@ -31,12 +31,7 @@
         
       </component-->
   
  -    <component name="org.jboss.seam.securityManager">
  -    
  -    </component>
  -    
  -    <component name="org.jboss.seam.security.securityConfiguration">
  -    
  -    </component>
  +    <component class="org.jboss.seam.security.SeamSecurityManager"/>
  +    <component class="org.jboss.seam.security.config.SecurityConfiguration"/>
           
   </components>
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 15 08:36:44 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 15 Dec 2006 08:36:44 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view  ...
Message-ID: <E1GvDEy-0006D2-1c@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/15 08:36:44

  Modified:    examples/seamspace/view  securityError.xhtml
  Log:
  some bug fixes, updates to security example
  
  Revision  Changes    Path
  1.2       +2 -8      jboss-seam/examples/seamspace/view/securityError.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: securityError.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/securityError.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- securityError.xhtml	23 Oct 2006 12:25:22 -0000	1.1
  +++ securityError.xhtml	15 Dec 2006 13:36:44 -0000	1.2
  @@ -4,7 +4,7 @@
   	  xmlns:h="http://java.sun.com/jsf/html">
   
   <head>
  -	<title>Seam Security</title>
  +	<title>SeamSpace</title>
   </head>
   
   <body>
  @@ -13,15 +13,9 @@
     <div class="errors"><h:messages globalOnly="true"/></div> 
   
     <p>
  -    You do not have the necessary permissions to carry out the requested action.
  +    You do not have the necessary security level to access this page.
     </p>
     
  -  <h:form>
  -    <h:commandButton action="#{protectedAction.foo}" value="Protected action" class="button"/>
  -    <h:commandButton action="#{login.logout}" value="Logout" class="button" />      
  -    <h:commandButton action="#{protectedAction.modifyCustomer}" value="Modify customer" class="button"/>
  -    <h:commandButton action="#{protectedAction.modifyReadonlyCustomer}" value="Modify read-only customer" class="button"/>     
  -  </h:form>
   </body>
   </html>
   
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 15 08:36:44 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 15 Dec 2006 08:36:44 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config ...
Message-ID: <E1GvDEy-0006DF-8H@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/15 08:36:44

  Modified:    src/main/org/jboss/seam/security/config   
                        SecurityConfiguration.java SecurityConstraint.java
                        WebResourceCollection.java
  Log:
  some bug fixes, updates to security example
  
  Revision  Changes    Path
  1.5       +12 -0     jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- SecurityConfiguration.java	15 Dec 2006 04:13:17 -0000	1.4
  +++ SecurityConfiguration.java	15 Dec 2006 13:36:44 -0000	1.5
  @@ -70,6 +70,8 @@
   
     private Map<String,Role> securityRoles = new HashMap<String,Role>();
   
  +  private String securityErrorPage = "/securityError.seam";
  +
   //  private AuthMethod authMethod;
   
   //  private Handler authenticator;
  @@ -90,6 +92,16 @@
         log.warn(String.format("Security configuration file %s not found", SECURITY_CONFIG_FILENAME));
     }
   
  +  public void setSecurityErrorPage(String securityErrorPage)
  +  {
  +    this.securityErrorPage = securityErrorPage;
  +  }
  +
  +  public String getSecurityErrorPage()
  +  {
  +    return securityErrorPage;
  +  }
  +
     /**
      * Loads the security configuration from the specified InputStream.
      *
  
  
  
  1.4       +1 -1      jboss-seam/src/main/org/jboss/seam/security/config/SecurityConstraint.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConstraint.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConstraint.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SecurityConstraint.java	15 Dec 2006 04:13:17 -0000	1.3
  +++ SecurityConstraint.java	15 Dec 2006 13:36:44 -0000	1.4
  @@ -49,7 +49,7 @@
   
       for (WebResourceCollection c : resourceCollections)
       {
  -      if (!c.getHttpMethods().contains(method))
  +      if (!c.supportsMethod(method))
           continue;
   
         for (String pattern : c.getUrlPatterns())
  
  
  
  1.3       +12 -0     jboss-seam/src/main/org/jboss/seam/security/config/WebResourceCollection.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WebResourceCollection.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/WebResourceCollection.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- WebResourceCollection.java	24 Oct 2006 14:58:04 -0000	1.2
  +++ WebResourceCollection.java	15 Dec 2006 13:36:44 -0000	1.3
  @@ -32,4 +32,16 @@
     {
       this.httpMethods = httpMethods;
     }
  +
  +  /**
  +   * Checks if this resource collection supports the specified method. If no
  +   * methods are specified for this collection, then the default is to support all methods.
  +   *
  +   * @param method String
  +   * @return boolean
  +   */
  +  public boolean supportsMethod(String method)
  +  {
  +    return httpMethods.isEmpty() || httpMethods.contains(method);
  +  }
   }
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 15 08:36:44 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 15 Dec 2006 08:36:44 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/filter  ...
Message-ID: <E1GvDEy-0006DR-EF@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/15 08:36:44

  Modified:    src/main/org/jboss/seam/security/filter 
                        SeamSecurityFilter.java
  Log:
  some bug fixes, updates to security example
  
  Revision  Changes    Path
  1.14      +9 -4      jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- SeamSecurityFilter.java	15 Dec 2006 04:13:17 -0000	1.13
  +++ SeamSecurityFilter.java	15 Dec 2006 13:36:44 -0000	1.14
  @@ -21,6 +21,7 @@
   import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.config.SecurityConfiguration;
   import org.jboss.seam.security.config.SecurityConstraint;
  +import javax.servlet.ServletContext;
   
   /**
    * A servlet filter that performs authentication within a Seam application.
  @@ -33,10 +34,13 @@
   
     private SecurityConfiguration config;
   
  +  private ServletContext servletContext;
  +
     public void init(FilterConfig filterConfig)
         throws ServletException
     {
  -    WebApplicationContext ctx = new WebApplicationContext(filterConfig.getServletContext());
  +    servletContext = filterConfig.getServletContext();
  +    WebApplicationContext ctx = new WebApplicationContext(servletContext);
       config = (SecurityConfiguration) ctx.get(SecurityConfiguration.class);
     }
   
  @@ -61,8 +65,9 @@
       Identity ident = (Identity)sessionContext.get(Seam.getComponentName(Identity.class));
   
       /** @todo Make the redirection configurable */
  -    if (!checkSecurityConstraints(hRequest.getRequestURI(), hRequest.getMethod(), ident))
  -      hResponse.sendRedirect("/securityError.seam");
  +    if (!checkSecurityConstraints(hRequest.getServletPath(), hRequest.getMethod(), ident))
  +      hResponse.sendRedirect(String.format("%s%s", hRequest.getContextPath(),
  +                                           config.getSecurityErrorPage()));
   
       chain.doFilter(request, response);
     }
  @@ -82,7 +87,7 @@
       {
         if (c.included(uri, method))
         {
  -        if (!userHasRole(ident, c.getAuthConstraint().getRoles()))
  +        if (ident == null || !userHasRole(ident, c.getAuthConstraint().getRoles()))
             return false;
         }
       }
  
  
  


From thomas.diesler at jboss.com  Fri Dec 15 08:57:18 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Fri, 15 Dec 2006 08:57:18 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-xerces/2.9.0 - New directory
	...
Message-ID: <E1GvDYs-0006Wr-7v@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/15 08:57:18

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/apache-xerces/2.9.0 added to the repository


From thomas.diesler at jboss.com  Fri Dec 15 08:57:24 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Fri, 15 Dec 2006 08:57:24 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-xerces/2.9.0/lib - New
	directory ...
Message-ID: <E1GvDYy-0006X0-F3@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/15 08:57:24

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/apache-xerces/2.9.0/lib added to the repository


From thomas.diesler at jboss.com  Fri Dec 15 08:58:49 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Fri, 15 Dec 2006 08:58:49 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-xerces/2.9.0  ...
Message-ID: <E1GvDaL-0006XT-0f@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/15 08:58:49

  Added:       apache-xerces/2.9.0  component-info.xml
  Log:
  add xerces-2.9.0
  
  Revision  Changes    Path
  1.1      date: 2006/12/15 13:58:48;  author: tdiesler;  state: Exp;repository.jboss.com/apache-xerces/2.9.0/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="apache-xerces-component-info">
  
     <!-- ============================================================ -->
     <!-- Apache Xerces                                                -->
     <!-- ============================================================ -->
  
     <component id="apache-xerces"
                licenseType="apache-2.0"
                version="2.9.0"
                projectHome="http://xml.apache.org/xerces2-j/index.html"
                description="High performance, fully compliant XML parser">
  
        <artifact id="xercesImpl.jar"/>
        <artifact id="xercesImpl-src.zip"/>
        <artifact id="resolver.jar"/>
        <artifact id="xml-apis.jar"/>
        <export>
           <include input="xercesImpl.jar"/>
           <include input="resolver.jar"/>
           <include input="xml-apis.jar"/>
        </export>
     </component>
  
  
  </project>
  
  
  


From thomas.diesler at jboss.com  Fri Dec 15 08:58:49 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Fri, 15 Dec 2006 08:58:49 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-xerces/2.9.0/lib     ...
Message-ID: <E1GvDaL-0006Xf-53@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/15 08:58:49

  Added:       apache-xerces/2.9.0/lib     resolver.jar serializer.jar
                        xercesImpl.jar xml-apis.jar
  Log:
  add xerces-2.9.0
  
  Revision  Changes    Path
  1.1      date: 2006/12/15 13:58:49;  author: tdiesler;  state: Exp;repository.jboss.com/apache-xerces/2.9.0/lib/resolver.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/15 13:58:49;  author: tdiesler;  state: Exp;repository.jboss.com/apache-xerces/2.9.0/lib/serializer.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/15 13:58:49;  author: tdiesler;  state: Exp;repository.jboss.com/apache-xerces/2.9.0/lib/xercesImpl.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/15 13:58:49;  author: tdiesler;  state: Exp;repository.jboss.com/apache-xerces/2.9.0/lib/xml-apis.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Fri Dec 15 09:19:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 09:19:58 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GvDuo-00075a-3e@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 09:19:58

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  Upgraded to use JGroups anycast
  
  Revision  Changes    Path
  1.293     +3 -44     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.292
  retrieving revision 1.293
  diff -u -b -r1.292 -r1.293
  --- TreeCache.java	14 Dec 2006 17:18:47 -0000	1.292
  +++ TreeCache.java	15 Dec 2006 14:19:57 -0000	1.293
  @@ -94,7 +94,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.292 2006/12/14 17:18:47 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.293 2006/12/15 14:19:57 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1981,15 +1981,7 @@
            log.trace("callRemoteMethods(): valid members are " + validMembers + " methods: " + method_call.getArgs()[0]);
         }
   
  -      // this is a temporary workaround (JBCACHE-813) until AnyCast (JGRP-338) is available.
  -      if (useTcpWorkaround())
  -      {
  -         rsps = multipleUnicast(validMembers, method_call, mode, timeout);
  -      }
  -      else
  -      {
  -         rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout);
  -      }
  +      rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout, buddyManager != null && buddyManager.isEnabled());
   
         // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
         // JGroups supports http://jira.jboss.com/jira/browse/JGRP-193
  @@ -2034,39 +2026,6 @@
         return retval;
      }
   
  -   boolean useTcpWorkaround()
  -   {
  -      return channel.getProtocolStack().findProtocol("UDP") == null;
  -   }
  -
  -   /**
  -    * This is a workaround for JBCACHE-813
  -    */
  -   private RspList multipleUnicast(List recipients, MethodCall call, int mode, long timeout) throws Exception
  -   {
  -      if (recipients == null || recipients.isEmpty()) return null;
  -
  -      Iterator i = recipients.iterator();
  -      RspList rsps = new RspList();
  -
  -      while (i.hasNext())
  -      {
  -         Address recipient = (Address) i.next();
  -         Object r = null;
  -         try
  -         {
  -            r = disp.callRemoteMethod(recipient, call, mode, timeout);
  -         }
  -         catch (Throwable throwable)
  -         {
  -            throw new Exception(throwable);
  -         }
  -         rsps.addRsp(recipient, r);
  -      }
  -      return rsps;
  -   }
  -
  -
      /**
       * @param members
       * @param method
  @@ -3757,7 +3716,7 @@
         {
            if (t instanceof CacheException)
            {
  -            throw(CacheException) t;
  +            throw (CacheException) t;
            }
            throw new RuntimeException(t);
         }
  
  
  


From msurtani at jboss.com  Fri Dec 15 09:19:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 09:19:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache  ...
Message-ID: <E1GvDuo-00075e-BP@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 09:19:58

  Removed:     tests/functional/org/jboss/cache  JGroupsConfigTest.java
  Log:
  Upgraded to use JGroups anycast


From msurtani at jboss.com  Fri Dec 15 09:22:25 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 09:22:25 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache  ...
Message-ID: <E1GvDxB-0007AG-6D@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 09:22:25

  Modified:    tests/functional/org/jboss/cache  LifeCycleTest.java
  Log:
  wc
  
  Revision  Changes    Path
  1.5       +3 -3      JBossCache/tests/functional/org/jboss/cache/LifeCycleTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LifeCycleTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/LifeCycleTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- LifeCycleTest.java	6 Sep 2006 15:31:01 -0000	1.4
  +++ LifeCycleTest.java	15 Dec 2006 14:22:25 -0000	1.5
  @@ -16,7 +16,7 @@
    * Tests restart (stop-destroy-create-start) of TreeCache
    *
    * @author Bela Ban
  - * @version $Id: LifeCycleTest.java,v 1.4 2006/09/06 15:31:01 msurtani Exp $
  + * @version $Id: LifeCycleTest.java,v 1.5 2006/12/15 14:22:25 msurtani Exp $
    */
   public class LifeCycleTest extends TestCase
   {
  @@ -53,12 +53,12 @@
         cache.put("/a/b/c", null);
         log.debug("cache locks before restart:\n" + cache.printLockInfo());
         assertTrue(cache.getNumberOfNodes() > 0);
  -      assertEquals(3, cache.getNumberOfLocksHeld());
  +      assertEquals(4, cache.getNumberOfLocksHeld());
   
         restartCache(cache);
         log.debug("cache locks after restart:\n" + cache.printLockInfo());
   
  -      assertEquals(3, cache.getNumberOfLocksHeld());
  +      assertEquals(4, cache.getNumberOfLocksHeld());
         assertTrue(cache.getNumberOfNodes() > 0);
   
         tx.rollback();
  
  
  


From gavin.king at jboss.com  Fri Dec 15 09:30:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 09:30:00 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core    ...
Message-ID: <E1GvE4W-0007H8-GR@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 09:30:00

  Modified:    src/main/org/jboss/seam/core    Manager.java Pageflow.java
                        Pages.java
  Log:
  javadoc
  allow use of customized view ids in a pageflow
  
  Revision  Changes    Path
  1.125     +2 -2      jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.124
  retrieving revision 1.125
  diff -u -b -r1.124 -r1.125
  --- Manager.java	13 Dec 2006 10:17:10 -0000	1.124
  +++ Manager.java	15 Dec 2006 14:30:00 -0000	1.125
  @@ -42,7 +42,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.124 $
  + * @version $Revision: 1.125 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -1008,7 +1008,7 @@
            //use stuff from the pageflow definition
            if ( pageflowPage.isSwitchEnabled() )
            {
  -            conversation.setViewId( pageflowPage.getViewId() );
  +            conversation.setViewId( Pageflow.instance().getPageViewId() );
            }
            if ( pageflowPage.hasDescription() )
            {
  
  
  
  1.46      +90 -8     jboss-seam/src/main/org/jboss/seam/core/Pageflow.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pageflow.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pageflow.java,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- Pageflow.java	24 Nov 2006 23:15:17 -0000	1.45
  +++ Pageflow.java	15 Dec 2006 14:30:00 -0000	1.46
  @@ -74,11 +74,19 @@
         return (Pageflow) Component.getInstance(Pageflow.class, ScopeType.CONVERSATION);
      }
      
  +   /**
  +    * Get the current counter value, used for detecting
  +    * illegal use of the backbutton.
  +    */
      public int getPageflowCounter()
      {
         return counter;
      }
      
  +   /**
  +    * Check that the current state of the pageflow matches
  +    * what is expected by the faces request.
  +    */
      public void validatePageflow() 
      {
         if ( processInstance!=null )
  @@ -119,6 +127,11 @@
         context.renderResponse();
      }
   
  +   /**
  +    * Add a message to indicate that illegal navigation
  +    * occurred. May be overridden by user to perform
  +    * special processing.
  +    */
      protected void illegalNavigation()
      {
         FacesMessages.instance().addFromResourceBundle( 
  @@ -128,6 +141,9 @@
            );
      }
      
  +   /**
  +    * Get the current Node of the pageflow.
  +    */
      public Node getNode() 
      {
         if (processInstance==null) return null;
  @@ -140,6 +156,11 @@
         return node;
      }
      
  +   /**
  +    * Reposition the pageflow at the named node.
  +    * 
  +    * @param nodeName the name of a node
  +    */
      public void reposition(String nodeName)
      {
         if (processInstance==null)
  @@ -158,6 +179,9 @@
         setDirty();
      }
      
  +   /**
  +    * Get the current Page of the pageflow.
  +    */
      public Page getPage() 
      {
         Node node = getNode();
  @@ -168,24 +192,68 @@
         return (Page) node;
      }
      
  -   private void navigate(FacesContext context) 
  +   /**
  +    * Navigate to the current page.
  +    */
  +   protected void navigate(FacesContext context) 
      {
         Page page = getPage();
         if ( !page.isRedirect() )
         {
  -         UIViewRoot viewRoot = context.getApplication().getViewHandler()
  -               .createView( context, page.getViewId() );
  -         context.setViewRoot(viewRoot);
  +         render(context, page);
         }
         else
         {
  -         Manager.instance().redirect( page.getViewId() );
  +         redirect(page);
         }
   
         counter++;
         setDirty();
      }
   
  +   /**
  +    * Redirect to the Page.
  +    */
  +   protected void redirect(Page page)
  +   {
  +      Manager.instance().redirect( getViewId(page) );
  +   }
  +
  +   /**
  +    * Proceed to render the Page.
  +    */
  +   protected void render(FacesContext context, Page page)
  +   {
  +      UIViewRoot viewRoot = context.getApplication().getViewHandler()
  +            .createView( context, getViewId(page) );
  +      context.setViewRoot(viewRoot);
  +   }
  +
  +   /**
  +    * Allows the user to extend this class and use some
  +    * logical naming of pages other than the JSF view id
  +    * in their pageflow.
  +    * 
  +    * @param page the Page object
  +    * @return a JSF view id
  +    */
  +   protected String getViewId(Page page)
  +   {
  +      return page.getViewId();
  +   }
  +   
  +   /**
  +    * Get the JSF view id of the current page in the
  +    * pageflow.
  +    */
  +   public String getPageViewId()
  +   {
  +      return getViewId( getPage() );
  +   }
  +
  +   /**
  +    * Does the current node have a default transition?
  +    */
      public boolean hasDefaultTransition()
      {
         //we don't use jBPM's default transition,
  @@ -204,6 +272,10 @@
               getNode().getLeavingTransition(outcome)!=null;
      }
   
  +   /**
  +    * Given the JSF action outcome, perform navigation according
  +    * to the current pageflow.
  +    */
      public void navigate(FacesContext context, String outcome) {
         if ( isNullOutcome(outcome) )
         {
  @@ -230,6 +302,12 @@
         }
      }
   
  +   /**
  +    * Process events defined in the pageflow.
  +    * 
  +    * @param type one of: "process-validations", "update-model-values",
  +    *                     "invoke-application", "render-response"
  +    */
      public void processEvents(String type)
      {
         Event event = getNode().getEvent(type);
  @@ -249,6 +327,11 @@
         }
      }
      
  +   /**
  +    * Begin executing a pageflow.
  +    * 
  +    * @param pageflowDefinitionName the name of the pageflow definition
  +    */
      public void begin(String pageflowDefinitionName)
      {
         if ( log.isDebugEnabled() )
  @@ -291,8 +374,7 @@
         Node node = pageflowProcessDefinition.getNode(pageflowNodeName);
         if (node!=null && node instanceof Page)
         {
  -         Page page = (Page) node;
  -         return page.getNoConversationViewId();
  +         return ( (Page) node ).getNoConversationViewId();
         }
         else
         {
  @@ -300,7 +382,7 @@
         }
      }
   
  -   private ProcessDefinition getPageflowProcessDefinition(String pageflowName)
  +   protected ProcessDefinition getPageflowProcessDefinition(String pageflowName)
      {
         ProcessDefinition pageflowProcessDefinition = Jbpm.instance().getPageflowProcessDefinition(pageflowName);
         if (pageflowProcessDefinition==null)
  
  
  
  1.58      +47 -0     jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.57
  retrieving revision 1.58
  diff -u -b -r1.57 -r1.58
  --- Pages.java	10 Dec 2006 14:22:28 -0000	1.57
  +++ Pages.java	15 Dec 2006 14:30:00 -0000	1.58
  @@ -221,6 +221,11 @@
         }
      }
      
  +   /**
  +    * Get the Page object for the given view id.
  +    * 
  +    * @param viewId a JSF view id
  +    */
      public Page getPage(String viewId)
      {
         if (viewId==null)
  @@ -281,6 +286,12 @@
         return loc<0 ? null : viewId.substring(0, loc) + suffix;
      }
      
  +   /**
  +    * Get the stack of Page objects, from least specific to 
  +    * most specific, that match the given view id.
  +    * 
  +    * @param viewId a JSF view id
  +    */
      protected List<Page> getPageStack(String viewId)
      {
         List<Page> stack = pageStacksByViewId.get(viewId);
  @@ -373,6 +384,9 @@
         return (Pages) Component.getInstance(Pages.class, ScopeType.APPLICATION);
      }
   
  +   /**
  +    * Call the action requested by s:link or s:button.
  +    */
      public static boolean callAction(FacesContext facesContext)
      {
         //TODO: refactor with Pages.instance().callAction()!!
  @@ -422,11 +436,25 @@
         return result;
      }
      
  +   /**
  +    * Get the values of any page parameters by evaluating the value bindings
  +    * against the model and converting to String.
  +    * 
  +    * @param viewId the JSF view id
  +    * @return a map of page parameter name to String value
  +    */
      public Map<String, Object> getConvertedParameters(FacesContext facesContext, String viewId)
      {
         return getConvertedParameters(facesContext, viewId, Collections.EMPTY_SET);
      }
      
  +   /**
  +    * Get the values of any page parameters by evaluating the value bindings
  +    * against the model.
  +    * 
  +    * @param viewId the JSF view id
  +    * @return a map of page parameter name to value
  +    */
      protected Map<String, Object> getParameters(String viewId)
      {
         Map<String, Object> parameters = new HashMap<String, Object>();
  @@ -453,6 +481,14 @@
         return parameters;
      }
      
  +   /**
  +    * Get the values of any page parameters by evaluating the value bindings
  +    * against the model and converting to String.
  +    * 
  +    * @param viewId the JSF view id
  +    * @param overridden override certain parameter values
  +    * @return a map of page parameter name to String value
  +    */
      public Map<String, Object> getConvertedParameters(FacesContext facesContext, String viewId, Set<String> overridden)
      {
         Map<String, Object> parameters = new HashMap<String, Object>();
  @@ -497,6 +533,9 @@
         return parameters;
      }
      
  +   /**
  +    * Apply any page parameters passed as parameter values to the model.
  +    */
      public void applyRequestParameterValues(FacesContext facesContext)
      {
         String viewId = facesContext.getViewRoot().getViewId();
  @@ -545,6 +584,9 @@
         }
      }
   
  +   /**
  +    * Apply any page parameters passed as view root attributes to the model.
  +    */
      public void applyViewRootValues(FacesContext facesContext)
      {
         String viewId = facesContext.getViewRoot().getViewId();
  @@ -565,6 +607,11 @@
         }
      }
   
  +   /**
  +    * The global setting for no-conversation-viewid.
  +    * 
  +    * @return a JSF view id
  +    */
      public String getNoConversationViewId()
      {
         return noConversationViewId;
  
  
  


From gavin.king at jboss.com  Fri Dec 15 09:30:00 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 09:30:00 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/mock  ...
Message-ID: <E1GvE4W-0007HF-KG@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 09:30:00

  Modified:    src/main/org/jboss/seam/mock  SeamTest.java
  Log:
  javadoc
  allow use of customized view ids in a pageflow
  
  Revision  Changes    Path
  1.58      +2 -2      jboss-seam/src/main/org/jboss/seam/mock/SeamTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/SeamTest.java,v
  retrieving revision 1.57
  retrieving revision 1.58
  diff -u -b -r1.57 -r1.58
  --- SeamTest.java	17 Nov 2006 17:17:41 -0000	1.57
  +++ SeamTest.java	15 Dec 2006 14:30:00 -0000	1.58
  @@ -51,7 +51,7 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.57 $
  + * @version $Revision: 1.58 $
    */
   public class SeamTest
   {
  @@ -304,7 +304,7 @@
         {
            if ( Init.instance().isJbpmInstalled() && Pageflow.instance().isInProcess() )
            {
  -            return Pageflow.instance().getPage().getViewId();
  +            return Pageflow.instance().getPageViewId();
            }
            else
            {
  
  
  


From msurtani at jboss.com  Fri Dec 15 10:18:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 10:18:48 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1GvEpk-0008JD-JO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 10:18:48

  Modified:    tests/functional/org/jboss/cache/replicated  
                        SyncReplTxTest.java SyncCacheListenerTest.java
  Log:
  fixed broken uts
  
  Revision  Changes    Path
  1.15      +138 -139  JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- SyncReplTxTest.java	9 Sep 2006 15:06:03 -0000	1.14
  +++ SyncReplTxTest.java	15 Dec 2006 15:18:48 -0000	1.15
  @@ -19,6 +19,8 @@
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.TimeoutException;
  +import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
  @@ -29,6 +31,8 @@
   import javax.transaction.SystemException;
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  +import java.util.ArrayList;
  +import java.util.List;
   import java.util.Map;
   
   /**
  @@ -36,21 +40,20 @@
    * Note: we use DummyTransactionManager for Tx purpose instead of relying on
    * jta.
    *
  - * @version $Revision: 1.14 $
  + * @version $Revision: 1.15 $
    */
   public class SyncReplTxTest extends TestCase
   {
      private static Log log = LogFactory.getLog(SyncReplTxTest.class);
  -   TreeCache cache1, cache2;
  -   Configuration.CacheMode caching_mode = Configuration.CacheMode.REPL_SYNC;
  -   final String group_name = "TreeCacheTestGroup";
  -
  -   final static Log log_ = LogFactory.getLog(SyncReplTxTest.class);
  -   String old_factory = null;
  -   final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
  -   FIFOSemaphore lock = new FIFOSemaphore(1);
  -   DummyTransactionManager tx_mgr;
  -   Throwable t1_ex, t2_ex, ex = null;
  +   private TreeCache cache1;
  +   private TreeCache cache2;
  +
  +   private String old_factory = null;
  +   private final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
  +   private FIFOSemaphore lock = new FIFOSemaphore(1);
  +   private DummyTransactionManager tx_mgr;
  +   private Throwable t1_ex;
  +   private Throwable t2_ex;
   
   
      public SyncReplTxTest(String name)
  @@ -63,8 +66,7 @@
         super.setUp();
         old_factory = System.getProperty(Context.INITIAL_CONTEXT_FACTORY);
         System.setProperty(Context.INITIAL_CONTEXT_FACTORY, FACTORY);
  -      tx_mgr = DummyTransactionManager.getInstance();
  -      t1_ex = t2_ex = ex = null;
  +      t1_ex = t2_ex = null;
      }
   
      public void tearDown() throws Exception
  @@ -79,16 +81,15 @@
         }
      }
   
  -   Transaction beginTransaction() throws SystemException, NotSupportedException
  +   private Transaction beginTransaction() throws SystemException, NotSupportedException
      {
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
   
  -   void initCaches(Configuration.CacheMode caching_mode) throws Exception
  +   private void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
  -      this.caching_mode = caching_mode;
         cache1 = new TreeCache();
         cache2 = new TreeCache();
         cache1.getConfiguration().setCacheMode(caching_mode);
  @@ -104,7 +105,7 @@
         cache2.start();
      }
   
  -   void destroyCaches() throws Exception
  +   private void destroyCaches()
      {
         if (cache1 != null)
            cache1.stop();
  @@ -121,7 +122,7 @@
         cache1.releaseAllLocks("/");
         Transaction tx = beginTransaction();
         cache1.put("/bela/ban", "name", "Bela Ban");
  -      assertEquals(2, cache1.getNumberOfLocksHeld());
  +      assertEquals(3, cache1.getNumberOfLocksHeld());
         assertEquals(0, cache2.getNumberOfLocksHeld());
         tx.commit();
         assertEquals(0, cache1.getNumberOfLocksHeld());
  @@ -170,32 +171,18 @@
       */
      public void testSimplePut() throws Exception
      {
  -      Integer age;
  -
  -      try
  -      {
            initCaches(Configuration.CacheMode.REPL_SYNC);
   
            cache1.put("/JSESSION/localhost/192.168.1.10:32882/Courses/0", "Instructor", "Ben Wang");
   
            cache1.put("/JSESSION/localhost/192.168.1.10:32882/1", "Number", 10);
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
   
      public void testSimpleTxPut() throws Exception
      {
         Transaction tx;
         final Fqn NODE1 = Fqn.fromString("/one/two/three");
  -      final Fqn NODE2 = Fqn.fromString("/one/two/three/four");
  -      final Fqn NODE3 = Fqn.fromString("/one/two/three/fourI");
  -
  -      try
  -      {
            initCaches(Configuration.CacheMode.REPL_SYNC);
   
            tx = beginTransaction();
  @@ -223,11 +210,6 @@
            System.out.println("TransactionTable for cache1 after cache1.put():\n" + cache1.getTransactionTable().toString(true));
            */
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
      public void testSyncReplWithModficationsOnBothCaches() throws Exception
      {
  @@ -236,10 +218,12 @@
         final Fqn NODE1 = Fqn.fromString("/one/two/three");
         final Fqn NODE2 = Fqn.fromString("/eins/zwei/drei");
   
  -      try
  -      {
            initCaches(Configuration.CacheMode.REPL_SYNC);
   
  +      // create roots first
  +      cache1.put("/one/two", null);
  +      cache2.put("/eins/zwei", null);
  +
            cache1.getConfiguration().setSyncCommitPhase(true);
            cache2.getConfiguration().setSyncCommitPhase(true);
   
  @@ -253,11 +237,20 @@
            System.out.println("cache1 before commit:\n" + cache1.printLockInfo());
            System.out.println("cache2 before commit:\n" + cache2.printLockInfo());
   
  +      try
  +      {
            tx.commit();
  +         fail("Should not succeed with SERIALIZABLE semantics");
  +      }
  +      catch (Exception e)
  +      {
  +         //should be a classic deadlock here.
  +      }
   
            System.out.println("cache1 after commit:\n" + cache1.printLockInfo());
            System.out.println("cache2 after commit:\n" + cache2.printLockInfo());
   
  +      /*
            assertTrue(cache1.exists(NODE1));
            assertTrue(cache1.exists(NODE2));
            assertTrue(cache1.exists(NODE1));
  @@ -278,17 +271,13 @@
            age = (Integer) cache2.get(NODE2, "age");
            assertNotNull("\"age\" obtained from cache2 for " + NODE2 + " must be non-null ", age);
            assertTrue("\"age\" must be 39", age == 39);
  +      */
   
            assertEquals(0, cache1.getNumberOfLocksHeld());
            assertEquals(0, cache2.getNumberOfLocksHeld());
            System.out.println("TransactionTable for cache1:\n" + cache1.getTransactionTable().toString(true));
            System.out.println("TransactionTable for cache2:\n" + cache2.getTransactionTable().toString(true));
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
      public void testSyncReplWithModficationsOnBothCachesSameData() throws Exception
      {
  @@ -410,7 +399,7 @@
         }
   
         // Sleep, as the rollback call to cache2 is async
  -      _pause(1000);
  +      TestingUtil.sleepThread(1000);
   
         System.out.println("cache1 (after rollback):\n" + cache1.printLockInfo());
         System.out.println("cache2 (after rollback):\n" + cache2.printLockInfo());
  @@ -439,7 +428,7 @@
         tx.commit();
   
         // Sleep, as the commit call to cache2 is async
  -      _pause(1000);
  +      TestingUtil.sleepThread(1000);
   
         System.out.println("cache1 (after rollback):\n" + cache1.printLockInfo());
         System.out.println("cache2 (after rollback):\n" + cache2.printLockInfo());
  @@ -495,7 +484,7 @@
         }
   
         // Sleep, as the commit call to cache2 is async
  -      _pause(1000);
  +      TestingUtil.sleepThread(1000);
   
         System.out.println("cache1 (after rollback):\n" + cache1.printLockInfo());
         System.out.println("cache2 (after rollback):\n" + cache2.printLockInfo());
  @@ -583,7 +572,7 @@
               {
                  tx = beginTransaction();
                  cache1.put("/bela/ban", "name", "Bela Ban");
  -               _pause(2000); // Thread2 will be blocked until we commit
  +               TestingUtil.sleepThread(2000); // Thread2 will be blocked until we commit
                  tx.commit();
                  System.out.println("[Thread1] ** LOCK INFO cache1: " + cache1.printLockInfo());
                  System.out.println("[Thread1] ** LOCK INFO cache2: " + cache2.printLockInfo());
  @@ -604,7 +593,7 @@
            {
               try
               {
  -               _pause(1000); // give Thread1 time to acquire the lock
  +               TestingUtil.sleepThread(1000); // give Thread1 time to acquire the lock
                  tx = beginTransaction();
                  System.out.println("[Thread2] ** LOCK INFO cache1: " + cache1.printLockInfo());
                  System.out.println("[Thread2] ** LOCK INFO cache2: " + cache2.printLockInfo());
  @@ -671,6 +660,8 @@
         c2.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         c1.getConfiguration().setSyncCommitPhase(true);
         c2.getConfiguration().setSyncCommitPhase(true);
  +      c1.getConfiguration().setSyncRollbackPhase(true);
  +      c2.getConfiguration().setSyncRollbackPhase(true);
         c1.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         c2.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         c1.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -679,6 +670,7 @@
         c2.getConfiguration().setLockAcquisitionTimeout(5000);
         c1.start();
         c2.start();
  +      final List<Exception> exceptions = new ArrayList<Exception>();
   
         class MyThread extends Thread
         {
  @@ -692,7 +684,7 @@
   
            public void run()
            {
  -            Transaction tx;
  +            Transaction tx = null;
   
               try
               {
  @@ -710,7 +702,17 @@
               }
               catch (Exception e)
               {
  -               ex = e;
  +               exceptions.add(e);
  +            }
  +            finally
  +            {
  +               try
  +               {
  +                  if (tx != null) tx.rollback();
  +               }
  +               catch (Exception e)
  +               {
  +               }
               }
            }
         }
  @@ -727,7 +729,7 @@
            thread.start();
         }
   
  -      _pause(6000);
  +      TestingUtil.sleepThread(6000);
         synchronized (myMutex)
         {
            System.out.println("cache is " + c1.printLockInfo());
  @@ -735,9 +737,8 @@
            myMutex.notifyAll();
         }
   
  -      for (int i = 0; i < threads.length; i++)
  +      for (MyThread thread : threads)
         {
  -         MyThread thread = threads[i];
            try
            {
               thread.join();
  @@ -757,8 +758,17 @@
         c1.stop();
         c2.stop();
   
  -      if (ex != null)
  -         fail("Thread failed: " + ex);
  +//      if(ex != null)
  +//      {
  +//         ex.printStackTrace();
  +//         fail("Thread failed: " + ex);
  +//      }
  +
  +      // we can only expect 1 thread to succeed.  The others will fail.  So, threads.length -1 exceptions.
  +      // this is a timing issue - 2 threads still may succeed on a multi cpu system
  +      // assertEquals(threads.length - 1, exceptions.size());
  +
  +      for (Exception exception : exceptions) assertEquals(TimeoutException.class, exception.getClass());
      }
   
   
  @@ -781,7 +791,7 @@
               {
                  tx = beginTransaction();
                  c1.put("/ben/wang", "name", "Ben Wang");
  -               _pause(8000);
  +               TestingUtil.sleepThread(8000);
                  tx.commit(); // This should go thru
               }
               catch (Throwable ex)
  @@ -800,7 +810,7 @@
            {
               try
               {
  -               _pause(1000); // give Thread1 time to acquire the lock
  +               TestingUtil.sleepThread(1000); // give Thread1 time to acquire the lock
                  tx = beginTransaction();
                  c2.put("/ben/wang", "name", "Ben Jr.");
                  tx.commit(); // This will time out and rollback first because Thread1 has a tx going as well.
  @@ -852,7 +862,7 @@
   
                  System.out.println("-- t1 releases lock");
                  lock.release();
  -               _pause(300);
  +               TestingUtil.sleepThread(300);
                  Thread.yield();
   
                  lock.acquire();
  @@ -882,7 +892,7 @@
            {
               try
               {
  -               _pause(100);
  +               TestingUtil.sleepThread(100);
                  Thread.yield();
                  lock.acquire();
                  System.out.println("-- t2 has lock");
  @@ -892,9 +902,9 @@
                  assertEquals(new Integer(38), val);
                  System.out.println("-- t2 releases lock");
                  lock.release();
  -               _pause(300);
  +               TestingUtil.sleepThread(300);
                  Thread.yield();
  -               _pause(500);
  +               TestingUtil.sleepThread(500);
                  lock.acquire();
                  System.out.println("-- t2 has lock");
                  val = (Integer) cache2.get("/a/b/c", "age");
  @@ -992,7 +1002,7 @@
                  c1.put("/a/b/c", "age", 39);
                  lock.release();
   
  -               _pause(300);
  +               TestingUtil.sleepThread(300);
                  lock.acquire();
                  try
                  {
  @@ -1035,13 +1045,13 @@
                  cache2.put("/a/b/c", "age", 40);
                  lock.release();
   
  -               _pause(300);
  +               TestingUtil.sleepThread(300);
                  lock.acquire();
                  assertEquals(40, cache2.get("/a/b/c", "age")); // must not be null
                  tx.commit();
                  lock.release();
   
  -               _pause(1000);
  +               TestingUtil.sleepThread(1000);
                  tx = beginTransaction();
                  assertEquals("After cache2 commit", 40, cache2.get("/a/b/c", "age"));
                  tx.commit();
  @@ -1090,7 +1100,7 @@
                  c2.put("/a/b/c", "age", 39);
                  lock.release();
   
  -               _pause(100);
  +               TestingUtil.sleepThread(100);
                  lock.acquire();
                  tx.rollback();
                  lock.release();
  @@ -1122,7 +1132,7 @@
                  assertNull(cache2.get("/a/b/c", "age")); // must be null as not yet committed
                  lock.release();
   
  -               _pause(100);
  +               TestingUtil.sleepThread(100);
                  lock.acquire();
                  assertNull(cache2.get("/a/b/c", "age")); // must be null as rolledback
                  tx.commit();
  @@ -1171,6 +1181,7 @@
            }
            catch (SystemException e)
            {
  +            // who cares
            }
         }
   
  @@ -1313,19 +1324,7 @@
   
      }
   
  -
  -   static void _pause(long millis)
  -   {
  -      try
  -      {
  -         Thread.sleep(millis);
  -      }
  -      catch (Exception t)
  -      {
  -      }
  -   }
  -
  -   public static Test suite() throws Exception
  +   public static Test suite()
      {
   //        return getDeploySetup(SyncTxUnitTestCase.class, "cachetest.jar");
         return new TestSuite(SyncReplTxTest.class);
  
  
  
  1.11      +73 -141   JBossCache/tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncCacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- SyncCacheListenerTest.java	29 Aug 2006 17:50:14 -0000	1.10
  +++ SyncCacheListenerTest.java	15 Dec 2006 15:18:48 -0000	1.11
  @@ -7,7 +7,6 @@
    */
   package org.jboss.cache.replicated;
   
  -import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  @@ -32,36 +31,14 @@
   /**
    * Test out the TreeCacheListener
    *
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public class SyncCacheListenerTest extends TestCase
   {
  -   TreeCache cache1, cache2;
  -   Configuration.CacheMode caching_mode = Configuration.CacheMode.REPL_SYNC;
  -   final String group_name = "TreeCacheTestGroup";
  -   String props =
  -           "UDP(ip_mcast=true;ip_ttl=64;loopback=false;mcast_addr=228.1.2.3;" +
  -           "mcast_port=45566;mcast_recv_buf_size=80000;mcast_send_buf_size=150000;" +
  -           "ucast_recv_buf_size=80000;ucast_send_buf_size=150000):" +
  -           "PING(down_thread=true;num_initial_members=2;timeout=500;up_thread=true):" +
  -           "MERGE2(max_interval=20000;min_interval=10000):" +
  -           "FD(down_thread=true;shun=true;up_thread=true):" +
  -           "VERIFY_SUSPECT(down_thread=true;timeout=1500;up_thread=true):" +
  -           "pbcast.NAKACK(down_thread=true;gc_lag=50;retransmit_timeout=600,1200,2400,4800;" +
  -           "up_thread=true):" +
  -           "pbcast.STABLE(desired_avg_gossip=20000;down_thread=true;up_thread=true):" +
  -           "UNICAST(down_thread=true;min_threshold=10;timeout=600,1200,2400;window_size=100):" +
  -           "FRAG(down_thread=true;frag_size=8192;up_thread=true):" +
  -           "pbcast.GMS(join_retry_timeout=2000;join_timeout=5000;print_local_addr=true;shun=true):" +
  -           "pbcast.STATE_TRANSFER(down_thread=true;up_thread=true)";
  -
  -   final static Log log_ = LogFactory.getLog(SyncCacheListenerTest.class);
  -   String old_factory = null;
  -   final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
  -   FIFOSemaphore lock = new FIFOSemaphore(1);
  -   DummyTransactionManager tx_mgr;
  -   Throwable t1_ex, t2_ex, ex = null;
  -
  +   private TreeCache cache1, cache2;
  +   private final static Log log_ = LogFactory.getLog(SyncCacheListenerTest.class);
  +   private String old_factory = null;
  +   private final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
   
      public SyncCacheListenerTest(String name)
      {
  @@ -74,9 +51,8 @@
         super.setUp();
         old_factory = System.getProperty(Context.INITIAL_CONTEXT_FACTORY);
         System.setProperty(Context.INITIAL_CONTEXT_FACTORY, FACTORY);
  -      tx_mgr = DummyTransactionManager.getInstance();
  -      t1_ex = t2_ex = ex = null;
  -      lock = new FIFOSemaphore(1);
  +
  +      initCaches();
         System.out.println("*** finished setUp()");
      }
   
  @@ -94,21 +70,19 @@
         System.out.println("*** finished tearDown()");
      }
   
  -   Transaction beginTransaction() throws SystemException, NotSupportedException
  +   private Transaction beginTransaction() throws SystemException, NotSupportedException
      {
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
  -      Transaction tx = mgr.getTransaction();
  -      return tx;
  +      return mgr.getTransaction();
      }
   
  -   void initCaches(Configuration.CacheMode caching_mode) throws Exception
  +   private void initCaches() throws Exception
      {
  -      this.caching_mode = caching_mode;
         cache1 = new TreeCache();
         cache2 = new TreeCache();
  -      cache1.getConfiguration().setCacheMode(caching_mode);
  -      cache2.getConfiguration().setCacheMode(caching_mode);
  +      cache1.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
  +      cache2.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         cache1.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
         cache2.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
   
  @@ -124,7 +98,7 @@
         cache2.start();
      }
   
  -   void destroyCaches() throws Exception
  +   private void destroyCaches()
      {
         if (cache1 != null)
         {
  @@ -134,8 +108,6 @@
         {
            cache2.stop();
         }
  -      cache1 = null;
  -      cache2 = null;
      }
   
      public void testSyncTxRepl() throws Exception
  @@ -143,71 +115,47 @@
         Integer age;
         Transaction tx;
   
  -      try
  -      {
  -         initCaches(Configuration.CacheMode.REPL_SYNC);
  -
            tx = beginTransaction();
            Listener lis = new Listener();
            cache1.getNotifier().addCacheListener(lis);
  -         lis.put("/a/b/c", "age", new Integer(38));
  +      lis.put("/a/b/c", "age", 38);
  +      cache1.getTransactionManager().suspend();
            assertNull("age on cache2 must be null as the TX has not yet been committed", cache2.get("/a/b/c", "age"));
  +      cache1.getTransactionManager().resume(tx);
            tx.commit();
   
            // value on cache2 must be 38
            age = (Integer) cache2.get("/a/b/c", "age");
            assertNotNull("\"age\" obtained from cache2 must be non-null ", age);
  -         assertTrue("\"age\" must be 38", age.intValue() == 38);
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  +      assertTrue("\"age\" must be 38", age == 38);
      }
   
      public void testRemoteCacheListener() throws Exception
      {
         Integer age;
  -      try
  -      {
  -         initCaches(Configuration.CacheMode.REPL_SYNC);
            RemoteListener lis = new RemoteListener();
            cache2.getNotifier().addCacheListener(lis);
  -         cache1.put("/a/b/c", "age", new Integer(38));
  +      cache1.put("/a/b/c", "age", 38);
   
            // value on cache2 must be 38
            age = (Integer) cache2.get("/a/b/c", "age");
            assertNotNull("\"age\" obtained from cache2 must be non-null ", age);
  -         assertTrue("\"age\" must be 38", age.intValue() == 38);
  +      assertTrue("\"age\" must be 38", age == 38);
            cache1.remove("/a/b/c", "age");
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
   
      public void testSyncRepl() throws Exception
      {
         Integer age;
  -      try
  -      {
  -         initCaches(Configuration.CacheMode.REPL_SYNC);
  -
            Listener lis = new Listener();
            cache1.getNotifier().addCacheListener(lis);
  -         lis.put("/a/b/c", "age", new Integer(38));
  +      lis.put("/a/b/c", "age", 38);
   
            // value on cache2 must be 38
            age = (Integer) cache2.get("/a/b/c", "age");
            assertNotNull("\"age\" obtained from cache2 must be non-null ", age);
  -         assertTrue("\"age\" must be 38", age.intValue() == 38);
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  +      assertTrue("\"age\" must be 38", age == 38);
      }
   
      public void testSyncTxReplMap() throws Exception
  @@ -215,55 +163,40 @@
         Integer age;
         Transaction tx;
   
  -      try
  -      {
  -         initCaches(Configuration.CacheMode.REPL_SYNC);
  -
            tx = beginTransaction();
            Listener lis = new Listener();
            cache1.getNotifier().addCacheListener(lis);
            Map map = new HashMap();
  -         map.put("age", new Integer(38));
  +      map.put("age", 38);
            map.put("name", "Ben");
            lis.put("/a/b/c", map);
  +      cache1.getTransactionManager().suspend();
            assertNull("age on cache2 must be null as the TX has not yet been committed", cache2.get("/a/b/c", "age"));
  +      cache1.getTransactionManager().resume(tx);
            tx.commit();
   
            // value on cache2 must be 38
            age = (Integer) cache2.get("/a/b/c", "age");
            assertNotNull("\"age\" obtained from cache2 must be non-null ", age);
  -         assertTrue("\"age\" must be 38", age.intValue() == 38);
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  +      assertTrue("\"age\" must be 38", age == 38);
      }
   
   
      public void testSyncReplMap() throws Exception
      {
         Integer age;
  -      try
  -      {
  -         initCaches(Configuration.CacheMode.REPL_SYNC);
   
            Listener lis = new Listener();
            cache1.getNotifier().addCacheListener(lis);
            Map map = new HashMap();
  -         map.put("age", new Integer(38));
  +      map.put("age", 38);
            map.put("name", "Ben");
            lis.put("/a/b/c", map);
   
            // value on cache2 must be 38
            age = (Integer) cache2.get("/a/b/c", "age");
            assertNotNull("\"age\" obtained from cache2 must be non-null ", age);
  -         assertTrue("\"age\" must be 38", age.intValue() == 38);
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  +      assertTrue("\"age\" must be 38", age == 38);
      }
   
   
  @@ -271,13 +204,13 @@
      {
         Object key_ = null;
   
  -      public void put(String fqn, Object key, Object val) throws Exception
  +      public void put(String fqn, Object key, Object val)
         {
            key_ = key;
            cache1.put(fqn, key, val);
         }
   
  -      public void put(String fqn, Map map) throws Exception
  +      public void put(String fqn, Map map)
         {
            if (map.size() == 0) fail("put(): map size can't be 0");
            Set set = map.keySet();
  @@ -325,9 +258,8 @@
   
      }
   
  -   public static Test suite() throws Exception
  +   public static Test suite()
      {
  -//        return getDeploySetup(SyncTxUnitTestCase.class, "cachetest.jar");
         return new TestSuite(SyncCacheListenerTest.class);
      }
   
  
  
  


From msurtani at jboss.com  Fri Dec 15 10:28:37 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 10:28:37 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options  ...
Message-ID: <E1GvEzF-0008UX-Q5@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 10:28:37

  Modified:    tests/functional/org/jboss/cache/options 
                        SuppressLockingTest.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.8       +6 -6      JBossCache/tests/functional/org/jboss/cache/options/SuppressLockingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuppressLockingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/SuppressLockingTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- SuppressLockingTest.java	31 Oct 2006 06:57:28 -0000	1.7
  +++ SuppressLockingTest.java	15 Dec 2006 15:28:37 -0000	1.8
  @@ -59,7 +59,7 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.put(fqn, "x", "1");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(1, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
         m.commit();
         assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
   
  @@ -81,7 +81,7 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.put(fqn, "x", "3");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(1, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
         m.commit();
         assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
      }
  @@ -97,7 +97,7 @@
   
         m.begin();
         cache.put(fqn, "x", "1");
  -      assertEquals(1, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
         m.commit();
         assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
   
  @@ -128,7 +128,7 @@
   
         m.begin();
         cache.put(fqn, "x", "3");
  -      assertEquals(1, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
         m.commit();
         assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
      }
  @@ -141,7 +141,7 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.get(fqn, "x");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(1, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
         m.commit();
         assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
   
  @@ -160,7 +160,7 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.get(fqn, "x");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(1, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
         m.commit();
         assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
      }
  
  
  


From thomas.diesler at jboss.com  Fri Dec 15 11:03:55 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Fri, 15 Dec 2006 11:03:55 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1GvFXP-0000qy-6G@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/15 11:03:54

  Modified:    jboss/jbossws/snapshot/lib         jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws-jboss-integration.jar
                        jbossws-tomcat-integration.jar jbossws.deployer
                        jbossws.sar
  Log:
  URL: https://svn.jboss.org/repos/jbossws/trunk
  Repository Root: https://svn.jboss.org/repos/jbossws
  Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
  Revision: 1660
  Node Kind: directory
  Schedule: normal
  Last Changed Author: thomas.diesler at jboss.com
  Last Changed Rev: 1660
  Last Changed Date: 2006-12-15 16:59:56 +0100 (Fri, 15 Dec 2006)
  
  Revision  Changes    Path
  1.32      +125 -126  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.31      +227 -226  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.32      +102 -104  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.43      +2217 -2213repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.5       +70 -71    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar
  
  	<<Binary file>>
  
  
  1.5       +39 -40    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar
  
  	<<Binary file>>
  
  
  1.4       +4527 -4460repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.deployer
  
  	<<Binary file>>
  
  
  1.43      +33 -26    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  


From norman.richards at jboss.com  Fri Dec 15 11:27:18 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 11:27:18 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GvFu2-0001IX-Bp@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 11:27:18

  Modified:    jboss-seam  seam
  Log:
  JBSEAM-546: copy mechanism from jboss run.sh
  
  Revision  Changes    Path
  1.16      +8 -1      jboss-seam/seam
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- seam	29 Nov 2006 14:23:08 -0000	1.15
  +++ seam	15 Dec 2006 16:27:18 -0000	1.16
  @@ -5,7 +5,14 @@
   #
   ############################################
   
  -cd seam-gen
  +DIRNAME=`dirname $0`
  +
  +if [ "x$SEAM_HOME" = "x" ]; then
  +    # get the full path (without any relative bits)
  +    SEAM_HOME=`cd $DIRNAME; pwd`
  +fi
  +
  +cd $SEAM_HOME/seam-gen
   
   # OS specific support (must be 'true' or 'false').
   cygwin=false;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 12:02:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 12:02:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r59062 -
	trunk/server/src/main/org/jboss/ejb
Message-ID: <E1GvGRw-00023B-Jd@committer01.frg.pub.inap.atl.jboss.com>

Author: alex.loubyansky at jboss.com
Date: 2006-12-15 12:02:18 -0500 (Fri, 15 Dec 2006)
New Revision: 59062

Modified:
   trunk/server/src/main/org/jboss/ejb/StatefulSessionContainer.java
Log:
JBAS-3946 remove() called on home of a sfsb in tx must fail

Modified: trunk/server/src/main/org/jboss/ejb/StatefulSessionContainer.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/StatefulSessionContainer.java	2006-12-15 12:42:46 UTC (rev 59061)
+++ trunk/server/src/main/org/jboss/ejb/StatefulSessionContainer.java	2006-12-15 17:02:18 UTC (rev 59062)
@@ -66,6 +66,8 @@
     */
    protected InstanceCache instanceCache;
    protected Method getEJBObject;
+   protected Method ejbObjectRemove;
+   protected Method ejbLocalObjectRemove;
 
    public void setInstanceCache(InstanceCache ic)
    {
@@ -116,13 +118,15 @@
       // Get the Handle.getEJBObject method for permission checks
       try
       {
-         getEJBObject = Handle.class.getMethod("getEJBObject",
-            new Class[0]);
+         getEJBObject = Handle.class.getMethod("getEJBObject", new Class[0]);
       }
       catch (Exception e)
       {
          log.warn("Failed to grant access to the Handle.getEJBObject method");
       }
+
+      ejbObjectRemove = EJBObject.class.getMethod("remove", null);
+      ejbLocalObjectRemove = EJBLocalObject.class.getMethod("remove", null);
    }
 
    /**
@@ -217,10 +221,6 @@
    public void remove(Invocation mi)
       throws RemoteException, RemoveException
    {
-      // 7.6 EJB2.0, it is illegal to remove a bean while in a transaction
-      // if (((EnterpriseContext) mi.getEnterpriseContext()).getTransaction() != null)
-      // throw new RemoveException("StatefulSession bean in transaction, cannot remove (EJB2.0 7.6)");
-
       // if the session is removed already then let the user know they have a problem
       StatefulSessionEnterpriseContext ctx = (StatefulSessionEnterpriseContext) mi.getEnterpriseContext();
       if (ctx.getId() == null)
@@ -551,12 +551,6 @@
 
       public Object invoke(Invocation mi) throws Exception
       {
-         // wire the transaction on the context, this is how the instance remember the tx
-         // Unlike Entity beans we can't do that in the previous interceptors (ordering)
-         EnterpriseContext ctx = (EnterpriseContext) mi.getEnterpriseContext();
-         if (ctx.getTransaction() == null)
-            ctx.setTransaction(mi.getTransaction());
-
          // Get method
          Method miMethod = mi.getMethod();
          Method m = (Method) getBeanMapping().get(miMethod);
@@ -567,6 +561,19 @@
             throw new EJBException(msg);
          }
 
+         // wire the transaction on the context, this is how the instance remember the tx
+         // Unlike Entity beans we can't do that in the previous interceptors (ordering)
+         EnterpriseContext ctx = (EnterpriseContext) mi.getEnterpriseContext();
+         if (ctx.getTransaction() == null)
+            ctx.setTransaction(mi.getTransaction());
+         else if(ejbObjectRemove.equals(miMethod) || ejbLocalObjectRemove.equals(miMethod))
+         {
+            throw new RemoveException("An attempt to remove a session " +
+               "object while the object is in a transaction " +
+               "(EJB2.1, 7.6.4 Restrictions for Transactions): ejb-name=" +
+               metaData.getEjbName() + ", method=" + mi.getMethod() + ", tx=" + ctx.getTransaction());
+         }
+
          // Select instance to invoke (container or bean)
          if (m.getDeclaringClass().equals(StatefulSessionContainer.class)
             || m.getDeclaringClass().equals(SessionContainer.class))



From msurtani at jboss.com  Fri Dec 15 12:30:31 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 12:30:31 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader  ...
Message-ID: <E1GvGtD-0002Y1-Vf@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 12:30:31

  Modified:    tests/functional/org/jboss/cache/loader 
                        CacheLoaderTestsBase.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.38      +88 -91    JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -b -r1.37 -r1.38
  --- CacheLoaderTestsBase.java	20 Nov 2006 18:04:09 -0000	1.37
  +++ CacheLoaderTestsBase.java	15 Dec 2006 17:30:31 -0000	1.38
  @@ -14,7 +14,6 @@
   import org.jboss.util.stream.MarshalledValueInputStream;
   import org.jboss.util.stream.MarshalledValueOutputStream;
   
  -import javax.transaction.NotSupportedException;
   import javax.transaction.Transaction;
   import java.io.ByteArrayInputStream;
   import java.io.ByteArrayOutputStream;
  @@ -22,7 +21,6 @@
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.HashMap;
  -import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  @@ -31,7 +29,7 @@
    * Commons tests for all CacheLoaders
    *
    * @author Bela Ban
  - * @version $Id: CacheLoaderTestsBase.java,v 1.37 2006/11/20 18:04:09 genman Exp $
  + * @version $Id: CacheLoaderTestsBase.java,v 1.38 2006/12/15 17:30:31 msurtani Exp $
    */
   abstract public class CacheLoaderTestsBase extends AbstractCacheLoaderTestBase
   {
  @@ -39,15 +37,15 @@
      private static final Log log = LogFactory.getLog(CacheLoaderTestsBase.class);
      TreeCache cache;
      CacheLoader loader = null;
  -   Transaction tx = null;
  +   private Transaction tx = null;
      static final Fqn FQN = new Fqn("key");
  -   static final Fqn SUBTREE_FQN = new Fqn(FQN, "subtree");
  +   private static final Fqn SUBTREE_FQN = new Fqn(FQN, "subtree");
   
  -   static final Fqn BUDDY_BASE = new Fqn(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN, "test");
  +   private static final Fqn BUDDY_BASE = new Fqn(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN, "test");
   
  -   static final Fqn BUDDY_PLUS_FQN = new Fqn(BUDDY_BASE, FQN);
  +   private static final Fqn BUDDY_PLUS_FQN = new Fqn(BUDDY_BASE, FQN);
   
  -   static final Fqn BUDDY_PLUS_SUBTREE_FQN = new Fqn(BUDDY_BASE, SUBTREE_FQN);
  +   private static final Fqn BUDDY_PLUS_SUBTREE_FQN = new Fqn(BUDDY_BASE, SUBTREE_FQN);
   
   
      public CacheLoaderTestsBase(String name)
  @@ -99,23 +97,23 @@
   
      protected void addDelay()
      {
  -      ;// returns immediately in this case.  Subclasses may override where a delay is needed.
  +      // returns immediately in this case.  Subclasses may override where a delay is needed.
      }
   
  -   protected void clean(File dir)
  +   private void clean(File dir)
      {
         File[] files = dir.listFiles();
         if (files != null)
         {
  -         for (int i = 0; i < files.length; i++)
  +         for (File file : files)
            {
  -            if (files[i].isDirectory())
  +            if (file.isDirectory())
               {
  -               clean(files[i]);
  +               clean(file);
               }
               else
               {
  -               if (!files[i].delete()) files[i].deleteOnExit();
  +               if (!file.delete()) file.deleteOnExit();
               }
            }
         }
  @@ -126,7 +124,7 @@
      {
         final Fqn NODE = Fqn.fromString("/test");
         final String KEY = "key";
  -      cache.put(NODE, KEY, new Integer(10));
  +      cache.put(NODE, KEY, 10);
         cache.evict(NODE);
         addDelay();
         String ret = cache.print(NODE);
  @@ -137,19 +135,19 @@
      {
         final String NODE = "/test";
         final String KEY = "key";
  -      Object retval = null;
  +      Object retval;
         cache.remove(NODE);
         addDelay();
  -      retval = cache.put(NODE, KEY, new Integer(10));
  +      retval = cache.put(NODE, KEY, 10);
         assertEquals(null, retval);
  -      retval = cache.put(NODE, KEY, new Integer(20));
  +      retval = cache.put(NODE, KEY, 20);
         addDelay();
  -      assertEquals(new Integer(10), retval);
  +      assertEquals(10, retval);
         cache.evict(Fqn.fromString(NODE));// evicts from memory, but *not* from store
         addDelay();
         log.debug("put 30, expect 20 back");
  -      retval = cache.put(NODE, KEY, new Integer(30));
  -      assertEquals(new Integer(20), retval);
  +      retval = cache.put(NODE, KEY, 30);
  +      assertEquals(20, retval);
      }
   
      public void testPut2() throws Exception
  @@ -157,22 +155,22 @@
         final String NODE = "/a/b/c";
         assertNull(loader.get(Fqn.fromString(NODE)));
         final String KEY = "key";
  -      Object retval = null;
  +      Object retval;
         cache.remove(NODE);
         assertNull(loader.get(Fqn.fromString(NODE)));
         addDelay();
  -      retval = cache.put(NODE, KEY, new Integer(10));
  +      retval = cache.put(NODE, KEY, 10);
         assertNull(retval);
         addDelay();
  -      retval = cache.put(NODE, KEY, new Integer(20));
  -      assertEquals(new Integer(10), retval);
  +      retval = cache.put(NODE, KEY, 20);
  +      assertEquals(10, retval);
         cache.evict(Fqn.fromString(NODE));// evicts from memory, but *not* from store
         cache.evict(Fqn.fromString("/a/b"));
         cache.evict(Fqn.fromString("/a"));
         addDelay();
         log.debug("replace KEY with 30, expect 20");
  -      retval = cache.put(NODE, KEY, new Integer(30));
  -      assertEquals(new Integer(20), retval);
  +      retval = cache.put(NODE, KEY, 30);
  +      assertEquals(20, retval);
      }
   
      /**
  @@ -301,29 +299,29 @@
      public void testGet() throws CacheException
      {
         final String NODE = "/a/b/c";
  -      Object retval = null;
  +      Object retval;
         cache.remove(NODE);
         addDelay();
  -      retval = cache.put(NODE, "1", new Integer(10));
  +      retval = cache.put(NODE, "1", 10);
         assertNull(retval);
         addDelay();
  -      retval = cache.put(NODE, "2", new Integer(20));
  +      cache.put(NODE, "2", 20);
         cache.evict(Fqn.fromString("/a/b/c"));
         assertTrue("DataNode should not exisit ", !cache.exists("/a/b/c"));
         addDelay();
         retval = cache.get(NODE, "1");
  -      assertEquals(new Integer(10), retval);
  +      assertEquals(10, retval);
         retval = cache.get(NODE, "2");
  -      assertEquals(new Integer(20), retval);
  +      assertEquals(20, retval);
      }
   
      public void testGetNode() throws CacheException
      {
         final String NODE = "/a/b/c";
  -      Object retval = null;
  +      Object retval;
         cache.remove(NODE);
         addDelay();
  -      cache.put(NODE, "1", new Integer(10));
  +      cache.put(NODE, "1", 10);
         cache.evict(Fqn.fromString(NODE));
         assertTrue("DataNode should not exisit ", !cache.exists("/a/b/c"));
         addDelay();
  @@ -332,7 +330,7 @@
         assertNotNull("Should not be null", retval);
   
         DataNode node = (DataNode) retval;
  -      assertEquals(new Integer(10), node.get("1"));
  +      assertEquals(10, node.get("1"));
      }
   
   
  @@ -342,12 +340,12 @@
         pojo.getHobbies().add("Running");
         pojo.getHobbies().add("Beerathlon");
         pojo.getHobbies().add("Triathlon");
  -      cache.put("/mypojo", new Integer(322649), pojo);
  +      cache.put("/mypojo", 322649, pojo);
         addDelay();
  -      assertNotNull(cache.get("/mypojo", new Integer(322649)));
  +      assertNotNull(cache.get("/mypojo", 322649));
         cache.evict(Fqn.fromString("/mypojo"));
         assertFalse(cache.exists("/mypojo"));
  -      SamplePojo pojo2 = (SamplePojo) cache.get("/mypojo", new Integer(322649));// should fetch from CacheLoader
  +      SamplePojo pojo2 = (SamplePojo) cache.get("/mypojo", 322649);// should fetch from CacheLoader
         assertNotNull(pojo2);
         assertEquals(39, pojo2.getAge());
         assertEquals("Bela", pojo2.getName());
  @@ -431,7 +429,7 @@
      }
   
   
  -   public void testExists() throws Exception
  +   public void testExists()
      {
         cache.put("/eins/zwei/drei", "key1", "val1");
         assertTrue(cache.exists("/eins/zwei/drei"));
  @@ -616,7 +614,7 @@
         }
      }
   
  -   public void testGetChildren8() throws Exception
  +   public void testGetChildren8()
      {
         cache.put("/a/1", null);
         cache.put("/a/2", null);
  @@ -794,7 +792,7 @@
      }
   
   
  -   public void testRemoveData() throws Exception
  +   public void testRemoveData()
      {
         String key = "/x/y/z/";
         cache.put(key, "keyA", "valA");
  @@ -810,7 +808,7 @@
      }
   
   
  -   public void testRemoveData2() throws Exception
  +   public void testRemoveData2()
      {
         Set keys;
         Fqn key = Fqn.fromString("/x/y/z/");
  @@ -828,7 +826,7 @@
         assertEquals(0, keys.size());
      }
   
  -   public void testRemoveData3() throws Exception
  +   public void testRemoveData3()
      {
         Set keys;
         Fqn key = Fqn.fromString("/x/y/z/");
  @@ -843,7 +841,7 @@
         assertEquals("no more keys", 0, keys.size());
      }
   
  -   public void testRemoveKey() throws Exception
  +   public void testRemoveKey()
      {
         String key = "/x/y/z/";
         cache.put(key, "keyA", "valA");
  @@ -859,13 +857,13 @@
      {
         final String NODE = "/test";
         final String KEY = "key";
  -      Object retval = null;
  +      Object retval;
         cache.remove(NODE);
  -      retval = cache.put(NODE, KEY, new Integer(10));
  +      retval = cache.put(NODE, KEY, 10);
         assertNull(retval);
         addDelay();
         retval = cache.remove(NODE, KEY);
  -      assertEquals(new Integer(10), retval);
  +      assertEquals(10, retval);
         addDelay();
         retval = cache.remove(NODE, KEY);
         assertNull(retval);
  @@ -875,15 +873,15 @@
      {
         final String NODE = "/test";
         final String KEY = "key";
  -      Object retval = null;
  +      Object retval;
         cache.remove(NODE);
  -      retval = cache.put(NODE, KEY, new Integer(10));
  +      retval = cache.put(NODE, KEY, 10);
         assertNull(retval);
   
         cache.evict(Fqn.fromString(NODE));// evicts from memory, but *not* from store
         addDelay();
         retval = cache.remove(NODE, KEY);
  -      assertEquals(new Integer(10), retval);
  +      assertEquals(10, retval);
   
         cache.evict(Fqn.fromString(NODE));// evicts from memory, but *not* from store
         addDelay();
  @@ -892,7 +890,7 @@
      }
   
   
  -   public void testRemove() throws Exception
  +   public void testRemove()
      {
         String key = "/x/y/z/";
         cache.put(key, "keyA", "valA");
  @@ -907,7 +905,7 @@
      }
   
   
  -   public void testRemoveRoot() throws Exception
  +   public void testRemoveRoot()
      {
         assertEquals(0, cache.getKeys("/").size());
         cache.put("/1/2/3/4/5", null);
  @@ -920,7 +918,7 @@
      }
   
   
  -   public void testEvictionWithCacheLoader() throws Exception
  +   public void testEvictionWithCacheLoader()
      {
         cache.put("/first/second", "key1", "val1");// stored in cache loader
         cache.put("/first/second/third", "key2", "val2");// stored in cache loader
  @@ -937,7 +935,7 @@
      }
   
   
  -   public void testEvictionWithCacheLoader2() throws Exception
  +   public void testEvictionWithCacheLoader2()
      {
         cache.put("/first/second/third", "key1", "val1");// stored in cache loader
         cache.evict(Fqn.fromString("/first/second/third"));// removes node, because there are no children
  @@ -980,13 +978,13 @@
   
         System.out.println("lock info " + cache.printLockInfo());
   
  -      assertEquals(4, cache.getNumberOfLocksHeld());
  +      assertEquals(5, cache.getNumberOfLocksHeld());
         tx.commit();
   
      }
   
   
  -   public void testTxPutCommit() throws Exception, NotSupportedException
  +   public void testTxPutCommit() throws Exception
      {
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
  @@ -1004,7 +1002,7 @@
         cache.remove("/");
      }
   
  -   public void testTxPutRollback() throws Exception, NotSupportedException
  +   public void testTxPutRollback() throws Exception
      {
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -1520,7 +1518,7 @@
      public void testTransactionRollback() throws Exception
      {
         loader.remove(Fqn.fromString("/"));
  -      int num = 0;
  +      int num;
         try
         {
            ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
  @@ -1626,9 +1624,8 @@
                  break;
               case PUT_DATA:
                  Map map = mod.getData();
  -               for (Iterator iter = map.keySet().iterator(); iter.hasNext();)
  +               for (Object key : map.keySet())
                  {
  -                  Object key = iter.next();
                     assertEquals(map.get(key), loader.get(fqn).get(key));
                  }
                  break;
  @@ -1735,15 +1732,15 @@
         Complex c2 = new Complex(c1);
   
         // Add objects
  -      loader.put(FQN, new Integer(1), c1);
  -      loader.put(FQN, new Integer(2), c2);
  +      loader.put(FQN, 1, c1);
  +      loader.put(FQN, 2, c2);
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
   
         // Save state
  -      byte[] state = new byte[0];
  +      byte[] state;
         ByteArrayOutputStream baos = null;
         MarshalledValueOutputStream os = null;
         try
  @@ -1782,8 +1779,8 @@
         }
   
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
      }
   
  @@ -1931,16 +1928,16 @@
         Complex c4 = new Complex(c3);
   
         /* Add objects. */
  -      loader.put(FQN, new Integer(1), c1);
  -      loader.put(FQN, new Integer(2), c2);
  -      loader.put(SUBTREE_FQN, new Integer(1), c3);
  -      loader.put(SUBTREE_FQN, new Integer(2), c4);
  +      loader.put(FQN, 1, c1);
  +      loader.put(FQN, 2, c2);
  +      loader.put(SUBTREE_FQN, 1, c3);
  +      loader.put(SUBTREE_FQN, 2, c4);
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
  -      assertEquals(c3, loader.get(SUBTREE_FQN).get(new Integer(1)));
  -      assertEquals(c4, loader.get(SUBTREE_FQN).get(new Integer(2)));
  +      assertEquals(c3, loader.get(SUBTREE_FQN).get(1));
  +      assertEquals(c4, loader.get(SUBTREE_FQN).get(2));
         assertEquals(2, loader.get(SUBTREE_FQN).size());
   
         /* Save state. */
  @@ -1959,11 +1956,11 @@
         loader.storeState(SUBTREE_FQN, is);
         is.close();
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
  -      assertEquals(c3, loader.get(SUBTREE_FQN).get(new Integer(1)));
  -      assertEquals(c4, loader.get(SUBTREE_FQN).get(new Integer(2)));
  +      assertEquals(c3, loader.get(SUBTREE_FQN).get(1));
  +      assertEquals(c4, loader.get(SUBTREE_FQN).get(2));
         assertEquals(2, loader.get(SUBTREE_FQN).size());
      }
   
  @@ -1979,16 +1976,16 @@
         Complex c4 = new Complex(c3);
   
         /* Add objects. */
  -      loader.put(FQN, new Integer(1), c1);
  -      loader.put(FQN, new Integer(2), c2);
  -      loader.put(SUBTREE_FQN, new Integer(1), c3);
  -      loader.put(SUBTREE_FQN, new Integer(2), c4);
  +      loader.put(FQN, 1, c1);
  +      loader.put(FQN, 2, c2);
  +      loader.put(SUBTREE_FQN, 1, c3);
  +      loader.put(SUBTREE_FQN, 2, c4);
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
  -      assertEquals(c3, loader.get(SUBTREE_FQN).get(new Integer(1)));
  -      assertEquals(c4, loader.get(SUBTREE_FQN).get(new Integer(2)));
  +      assertEquals(c3, loader.get(SUBTREE_FQN).get(1));
  +      assertEquals(c4, loader.get(SUBTREE_FQN).get(2));
         assertEquals(2, loader.get(SUBTREE_FQN).size());
   
         /* Save state. */
  @@ -2005,11 +2002,11 @@
         loader.storeState(BUDDY_BASE, is);
         is.close();
         addDelay();
  -      assertEquals(c1, loader.get(BUDDY_PLUS_FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(BUDDY_PLUS_FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(BUDDY_PLUS_FQN).get(1));
  +      assertEquals(c2, loader.get(BUDDY_PLUS_FQN).get(2));
         assertEquals(2, loader.get(BUDDY_PLUS_FQN).size());
  -      assertEquals(c3, loader.get(BUDDY_PLUS_SUBTREE_FQN).get(new Integer(1)));
  -      assertEquals(c4, loader.get(BUDDY_PLUS_SUBTREE_FQN).get(new Integer(2)));
  +      assertEquals(c3, loader.get(BUDDY_PLUS_SUBTREE_FQN).get(1));
  +      assertEquals(c4, loader.get(BUDDY_PLUS_SUBTREE_FQN).get(2));
         assertEquals(2, loader.get(BUDDY_PLUS_SUBTREE_FQN).size());
   
      }
  
  
  


From msurtani at jboss.com  Fri Dec 15 12:30:32 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 12:30:32 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GvGtE-0002YA-6K@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 12:30:32

  Modified:    src/org/jboss/cache  NodeImpl.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.26      +8 -26     JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- NodeImpl.java	14 Dec 2006 17:18:47 -0000	1.25
  +++ NodeImpl.java	15 Dec 2006 17:30:32 -0000	1.26
  @@ -135,7 +135,7 @@
      /**
       * Initializes with a name and FQN and cache.
       */
  -   protected final void init(Object child_name, Fqn fqn, CacheSPI cache)
  +   private void init(Object child_name, Fqn fqn, CacheSPI cache)
      {
         if (cache == null)
         {
  @@ -169,7 +169,7 @@
         }
      }
   
  -   protected synchronized Map children()
  +   private synchronized Map children()
      {
         if (children == null)
         {
  @@ -225,11 +225,7 @@
   
      public synchronized boolean containsKey(Object key)
      {
  -      if (data == null)
  -      {
  -         return false;
  -      }
  -      return data.containsKey(key);
  +      return data != null && data.containsKey(key);
      }
   
      /**
  @@ -716,7 +712,7 @@
         }
      }
   
  -   public void printIndent(StringBuffer sb, int indent)
  +   private void printIndent(StringBuffer sb, int indent)
      {
         if (sb != null)
         {
  @@ -779,16 +775,12 @@
         {
            return null;
         }
  -      return children == null ? null : (DataNode) children.get(child_name);
  +      return children == null ? null : children.get(child_name);
      }
   
      public boolean childExists(Object child_name)
      {
  -      if (child_name == null)
  -      {
  -         return false;
  -      }
  -      return children != null && children.containsKey(child_name);
  +      return child_name != null && children != null && children.containsKey(child_name);
      }
   
      public Set<Node> getChildren()
  @@ -816,7 +808,7 @@
      /**
       * Adds details of the node into a map as strings.
       */
  -   protected void printDetailsInMap(StringBuffer sb, int indent)
  +   private void printDetailsInMap(StringBuffer sb, int indent)
      {
         printIndent(sb, indent);
         indent += 2;// increse it
  @@ -850,12 +842,6 @@
       */
      public void setDataLoaded(boolean dataLoaded)
      {
  -      // TODO remove this
  -      if (!dataLoaded && !data().isEmpty())
  -      {
  -         log.warn("data exists, but setDataLoaded(false)", new Throwable());
  -      }
  -
         this.dataLoaded = dataLoaded;
      }
   
  @@ -894,11 +880,7 @@
         @Override
         public boolean contains(Object o)
         {
  -         if (children == null)
  -         {
  -            return false;
  -         }
  -         return children.containsKey(o);
  +         return children != null && children.containsKey(o);
         }
   
         @Override
  
  
  


From msurtani at jboss.com  Fri Dec 15 12:30:32 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 12:30:32 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GvGtE-0002YH-B4@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 12:30:32

  Modified:    src/org/jboss/cache/interceptors 
                        PessimisticLockInterceptor.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.38      +13 -8     JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -b -r1.37 -r1.38
  --- PessimisticLockInterceptor.java	14 Dec 2006 17:18:48 -0000	1.37
  +++ PessimisticLockInterceptor.java	15 Dec 2006 17:30:32 -0000	1.38
  @@ -37,18 +37,18 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.37 2006/12/14 17:18:48 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.38 2006/12/15 17:30:32 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  -   TransactionTable tx_table = null;
  +   private TransactionTable tx_table = null;
   
      /**
       * Map<Object, java.util.List>. Keys = threads, values = lists of locks held by that thread
       */
  -   Map lock_table;
  +   private Map lock_table;
      private long lock_acquisition_timeout;
  -   LockManager lockManager = new LockManager();
  +   private LockManager lockManager = new LockManager();
   
   
      public void setCache(CacheSPI cache)
  @@ -190,8 +190,13 @@
            //cache.getRemovedNodesMap().remove(fqn);
            //cache.peek(fqn);
            // do a REAL remove here.
  -         cache.peek(fqn).getNodeSPI().getLock().releaseAll(Thread.currentThread());
  +         Node n = cache.peek(fqn);
  +         if (n != null)
  +         {
  +            lockManager.getLock(n).releaseAll(Thread.currentThread());
  +         }
            ((TreeCacheProxyImpl) cache).realRemove(fqn, true);
  +
         }
         return o;
      }
  @@ -374,7 +379,7 @@
         if (acquired)
         {
            // Record the lock for release on method return or tx commit/rollback
  -         recordNodeLock(gtx, node.getNodeSPI().getLock());
  +         recordNodeLock(gtx, lockManager.getLock(node));
         }
      }
   
  @@ -560,7 +565,7 @@
      {
         boolean acquire(Node node, Object owner, NodeLock.LockType lockType, long timeout) throws InterruptedException
         {
  -         return node.getNodeSPI().getLock().acquire(owner, timeout, lockType);
  +         return getLock(node).acquire(owner, timeout, lockType);
         }
   
         NodeLock getLock(Node node)
  @@ -570,7 +575,7 @@
   
         public Set acquireAll(Node node, Object owner, NodeLock.LockType lockType, long timeout) throws InterruptedException
         {
  -         return node.getNodeSPI().getLock().acquireAll(owner, timeout, lockType);
  +         return getLock(node).acquireAll(owner, timeout, lockType);
         }
      }
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 12:34:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 12:34:48 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1800 - trunk/tests
Message-ID: <E1GvGxM-0002cK-6N@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-15 12:34:46 -0500 (Fri, 15 Dec 2006)
New Revision: 1800

Modified:
   trunk/tests/build.xml
Log:
added ant-junit.jar to the classpath

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-15 12:52:36 UTC (rev 1799)
+++ trunk/tests/build.xml	2006-12-15 17:34:46 UTC (rev 1800)
@@ -171,6 +171,7 @@
       <path refid="jboss.server.classpath"/> <!-- for org.jboss.jms.jndi.JNDIProviderAdapter -->
       <path refid="jboss.jca.classpath"/>  <!-- for org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory, etc -->
       <path refid="jboss.profiler.jvmti.classpath"/>
+      <path location="${tests.root}/lib/ant-junit.jar"/>
    </path>
 
    <!--



From msurtani at jboss.com  Fri Dec 15 12:49:19 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 12:49:19 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1GvHBP-0002qT-N3@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 12:49:19

  Modified:    tests/functional/org/jboss/cache/passivation 
                        PassivationTestsBase.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.21      +179 -265  JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- PassivationTestsBase.java	23 Nov 2006 19:43:05 -0000	1.20
  +++ PassivationTestsBase.java	15 Dec 2006 17:49:19 -0000	1.21
  @@ -18,8 +18,8 @@
   import org.jboss.cache.statetransfer.StateTransferManager;
   import org.jboss.cache.transaction.DummyTransactionManager;
   import org.jboss.cache.xml.XmlHelper;
  -import org.jboss.util.stream.MarshalledValueOutputStream;
   import org.jboss.util.stream.MarshalledValueInputStream;
  +import org.jboss.util.stream.MarshalledValueOutputStream;
   import org.w3c.dom.Element;
   
   import javax.transaction.NotSupportedException;
  @@ -38,7 +38,7 @@
    * Base tests for passivation using any of the cache loaders
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationTestsBase.java,v 1.20 2006/11/23 19:43:05 genman Exp $
  + * @version $Id: PassivationTestsBase.java,v 1.21 2006/12/15 17:49:19 msurtani Exp $
    */
   abstract public class PassivationTestsBase extends TestCase
   {
  @@ -333,7 +333,7 @@
      }
   
   
  -   public void testGetChildrenWithEvictionPassivation() throws CacheException
  +   public void testGetChildrenWithEvictionPassivation() throws Exception
      {
         cache.put("/a/b/c/1", null);
         cache.put("/a/b/c/2", null);
  @@ -352,30 +352,19 @@
         assertTrue(children.contains("1"));
         assertTrue(children.contains("2"));
         assertTrue(children.contains("3"));
  -      try
  -      {
  +
            assertTrue(loader.exists(Fqn.fromString("/a/b/c")));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  +
         cache.get("/a/b/c/1", "test"); // load child
         cache.get("/a/b/c/2", "test"); // load child
         cache.get("/a/b/c/3", "test"); // load child
         cache.get("/a/b/c", "test");   // load attributes
  -      try
  -      {
  +
            assertFalse(loader.exists(Fqn.fromString("/a/b/c/1")));
            assertFalse(loader.exists(Fqn.fromString("/a/b/c/2")));
            assertFalse(loader.exists(Fqn.fromString("/a/b/c/3")));
            assertFalse(loader.exists(Fqn.fromString("/a/b/c")));
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
      public void testGetChildren2()
      {
  @@ -454,9 +443,7 @@
      }
   
   
  -   public void testGetChildren6Passivation()
  -   {
  -      try
  +   public void testGetChildren6Passivation() throws Exception
         {
            cache.put("/a/1", null); // put node in memory
            cache.put("/a/2", null); // put node in memory
  @@ -484,15 +471,8 @@
            cache.get("/a", "test"); // activate node
            assertFalse(loader.exists(Fqn.fromString("/a")));
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
  -   public void testGetChildren7Passivation()
  -   {
  -      try
  +   public void testGetChildren7Passivation() throws Exception
         {
            cache.put("/a/1", null);
            cache.put("/a/2", null);
  @@ -521,15 +501,8 @@
            assertFalse(loader.exists(Fqn.fromString("/a/3")));
            assertTrue(loader.exists(Fqn.fromString("/a")));
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
  -   public void testGetChildren8Passivation()
  -   {
  -      try
  +   public void testGetChildren8Passivation() throws Exception
         {
            cache.put("/a/1", null);
            cache.put("/a/2", null);
  @@ -553,15 +526,8 @@
            assertEquals("3 children weren't loaded", 3, children.size());
            assertTrue(loader.exists(Fqn.fromString("/a"))); //loaded children but didn't initalizae them
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
  -   public void testGetChildren9Passivation()
  -   {
  -      try
  +   public void testGetChildren9Passivation() throws Exception
         {
            cache.put("/a/1", null);
            cache.put("/a/2", null);
  @@ -608,16 +574,9 @@
            assertNull(cache.get("/a", "test")); // load attributes and has no children by now, activation
            assertFalse(loader.exists(Fqn.fromString("/a")));
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
   
  -   public void testGetChildren10Passivation()
  -   {
  -      try
  +   public void testGetChildren10Passivation() throws Exception
         {
            cache.put("/a/1", null);
            cache.put("/a/2", null);
  @@ -646,11 +605,6 @@
            assertNull(cache.get("/a", "test")); // activate node
            assertFalse(loader.exists(Fqn.fromString("/a")));
         }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
  -   }
   
      public void testRemoveData() throws Exception
      {
  @@ -683,14 +637,7 @@
   
         addDelay();
         keys = cache.getKeys(key); // activate node
  -      try
  -      {
            assertFalse(loader.exists(key));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
         assertEquals(0, keys.size());
      }
   
  @@ -739,7 +686,7 @@
         assertNull(retval);
      }
   
  -   public void testRemoveKey3Passivation() throws CacheException
  +   public void testRemoveKey3Passivation() throws Exception
      {
         final String NODE = "/test";
         final String KEY = "key";
  @@ -750,37 +697,16 @@
   
         cache.evict(Fqn.fromString(NODE)); // passivate node
         addDelay();
  -      try
  -      {
            assertTrue(loader.exists(Fqn.fromString(NODE)));
            assertEquals(new Integer(10), loader.get(Fqn.fromString(NODE)).get(KEY));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
         retval = cache.remove(NODE, KEY); // activate node
         assertEquals(new Integer(10), retval);
  -      try
  -      {
            assertFalse(loader.exists(Fqn.fromString(NODE)));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
   
         cache.evict(Fqn.fromString(NODE)); // passiave node
         addDelay();
         retval = cache.remove(NODE, KEY); // activate node
  -      try
  -      {
            assertFalse(loader.exists(Fqn.fromString(NODE)));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
         assertNull(retval);
      }
   
  @@ -838,25 +764,11 @@
         cache.put("/first/second/third", "key1", "val1");   // stored in cache loader
         cache.evict(Fqn.fromString("/first/second/third"));  // passivate node, note: it has no children
         addDelay();
  -      try
  -      {
            assertTrue(loader.exists(Fqn.fromString("/first/second/third")));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
         assertTrue(cache.exists("/first/second"));
         assertTrue(cache.exists("/first"));
         String val = (String) cache.get("/first/second/third", "key1"); // activate node
  -      try
  -      {
            assertFalse(loader.exists(Fqn.fromString("/first/second/third")));
  -      }
  -      catch (Exception e)
  -      {
  -         fail(e.toString());
  -      }
         assertEquals("val1", val);
         assertTrue(cache.exists("/first/second/third"));
         assertTrue(cache.exists("/first/second"));
  @@ -886,7 +798,7 @@
         assertTrue(children.contains("1"));
         assertTrue(children.contains("2"));
         assertTrue(children.contains("3"));
  -      assertEquals(4, cache.getNumberOfLocksHeld());
  +      assertEquals(5, cache.getNumberOfLocksHeld());
         tx.commit();
      }
   
  @@ -1660,7 +1572,7 @@
         os.close();
         assertTrue(baos.size() > 0);
   
  -      byte [] savedState = baos.toByteArray();
  +      byte[] savedState = baos.toByteArray();
   
         /* Restore state. */
         ByteArrayInputStream bais = new ByteArrayInputStream(savedState);
  @@ -1680,7 +1592,9 @@
       */
      private static class Complex implements Serializable
      {
  -      /** The serialVersionUID */
  +      /**
  +       * The serialVersionUID
  +       */
         private static final long serialVersionUID = 8950692199236424832L;
       
         Complex nested;
  
  
  


From msurtani at jboss.com  Fri Dec 15 12:49:19 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 15 Dec 2006 12:49:19 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction  ...
Message-ID: <E1GvHBP-0002qa-RF@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/15 12:49:19

  Modified:    src/org/jboss/cache/eviction  BaseEvictionAlgorithm.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.18      +8 -7      JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BaseEvictionAlgorithm.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- BaseEvictionAlgorithm.java	8 Dec 2006 18:49:17 -0000	1.17
  +++ BaseEvictionAlgorithm.java	15 Dec 2006 17:49:19 -0000	1.18
  @@ -11,6 +11,7 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.lock.TimeoutException;
  +
   import java.util.concurrent.BlockingQueue;
   import java.util.concurrent.LinkedBlockingQueue;
   
  @@ -21,7 +22,7 @@
    * abstract methods and a policy.
    *
    * @author Daniel Huang - dhuang at jboss.org 10/2005
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public abstract class BaseEvictionAlgorithm implements EvictionAlgorithm
   {
  @@ -62,7 +63,7 @@
   
      protected BaseEvictionAlgorithm()
      {
  -      recycleQueue = new LinkedBlockingQueue();
  +      recycleQueue = new LinkedBlockingQueue(500000);
      }
   
      protected void initialize(Region region) throws EvictionException
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 12:49:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 12:49:30 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1801 - trunk/tests
Message-ID: <E1GvHBa-0002qp-F9@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-15 12:49:28 -0500 (Fri, 15 Dec 2006)
New Revision: 1801

Modified:
   trunk/tests/build.xml
Log:
reverting the change?

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-15 17:34:46 UTC (rev 1800)
+++ trunk/tests/build.xml	2006-12-15 17:49:28 UTC (rev 1801)
@@ -171,7 +171,6 @@
       <path refid="jboss.server.classpath"/> <!-- for org.jboss.jms.jndi.JNDIProviderAdapter -->
       <path refid="jboss.jca.classpath"/>  <!-- for org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory, etc -->
       <path refid="jboss.profiler.jvmti.classpath"/>
-      <path location="${tests.root}/lib/ant-junit.jar"/>
    </path>
 
    <!--



From gavin.king at jboss.com  Fri Dec 15 12:59:01 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 12:59:01 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources  ...
Message-ID: <E1GvHKn-00031t-JA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 12:59:01

  Modified:    seam-gen/resources  messages_en.properties
  Log:
  add seam built-in messages
  
  Revision  Changes    Path
  1.4       +8 -0      jboss-seam/seam-gen/resources/messages_en.properties
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: messages_en.properties
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/messages_en.properties,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- messages_en.properties	3 Nov 2006 19:32:14 -0000	1.3
  +++ messages_en.properties	15 Dec 2006 17:59:01 -0000	1.4
  @@ -11,6 +11,14 @@
   validator.size=size must be between {min} and {max}
   validator.email=must be a well-formed email address	
   
  +org.jboss.seam.TransactionFailed=Transaction failed
  +org.jboss.seam.NoConversation=The conversation ended, timed out or was processing another request
  +org.jboss.seam.IllegalNavigation=Illegal navigation
  +org.jboss.seam.ProcessEnded=Process #0 already ended
  +org.jboss.seam.ProcessNotFound=Process #0 not found
  +org.jboss.seam.TaskEnded=Task #0 already ended
  +org.jboss.seam.TaskNotFound=Task #0 not found
  +
   javax.faces.component.UIInput.CONVERSION=value could not be converted to the expected type
   javax.faces.component.UIInput.REQUIRED=value is required
   javax.faces.component.UIInput.UPDATE=an error occurred when processing your submitted information
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 13:23:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 13:23:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r59063 - trunk/ejb3/src/main/org/jboss/ejb3
Message-ID: <E1GvHiJ-0003dj-Vm@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-15 13:23:19 -0500 (Fri, 15 Dec 2006)
New Revision: 59063

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
Log:
merge from tck branch missed

Modified: trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-15 17:02:18 UTC (rev 59062)
+++ trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-15 18:23:19 UTC (rev 59063)
@@ -24,8 +24,7 @@
 import java.io.Externalizable;
 import java.io.IOException;
 import java.io.ObjectInput;
-import java.io.ObjectOutput;
-import java.lang.reflect.InvocationHandler;
+import java.io.ObjectOutput; 
 import java.security.Identity;
 import java.security.Principal;
 import java.util.HashSet;
@@ -48,14 +47,14 @@
 import javax.xml.rpc.handler.MessageContext;
 import org.jboss.annotation.security.SecurityDomain;
 import org.jboss.aop.Advisor;
+import org.jboss.ejb3.security.SecurityDomainManager;
 import org.jboss.ejb3.tx.TxUtil;
 import org.jboss.ejb3.tx.UserTransactionImpl;
 import org.jboss.logging.Logger;
 import org.jboss.security.RealmMapping;
 import org.jboss.security.RunAsIdentity;
 import org.jboss.security.SecurityAssociation;
-import org.jboss.security.SimplePrincipal;
-import org.jboss.util.NestedRuntimeException;
+import org.jboss.security.SimplePrincipal; 
 
 /**
  * Comment
@@ -103,7 +102,7 @@
    {
       SecurityDomain securityAnnotation = (SecurityDomain) ((Advisor) container).resolveAnnotation(SecurityDomain.class);
       if (securityAnnotation == null) return;
-      Object domain = ctx.lookup("java:/jaas/" + securityAnnotation.value());
+      Object domain = SecurityDomainManager.getSecurityManager(securityAnnotation.value(), ctx);
       rm = (RealmMapping) domain;
    }
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 16:13:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 16:13:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r59064 -
	trunk/ejb3/src/main/org/jboss/ejb3/metamodel
Message-ID: <E1GvKN5-0006uZ-DR@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-15 16:13:34 -0500 (Fri, 15 Dec 2006)
New Revision: 59064

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java
Log:
EJBTHREE-807: bean meta data should include security role references

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java	2006-12-15 18:23:19 UTC (rev 59063)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EjbJarDDObjectFactory.java	2006-12-15 21:13:34 UTC (rev 59064)
@@ -24,8 +24,7 @@
 import java.io.IOException;
 import java.net.URL;
 
-import javax.management.ObjectName;
-import javax.persistence.PersistenceContextType;
+import javax.management.ObjectName; 
 
 import org.jboss.ejb3.KernelAbstraction;
 import org.jboss.ejb3.KernelAbstractionFactory;
@@ -37,7 +36,8 @@
 import org.jboss.xb.binding.UnmarshallerFactory;
 import org.jboss.xb.binding.UnmarshallingContext;
 import org.xml.sax.Attributes;
-
+ 
+import org.jboss.metadata.SecurityRoleRefMetaData;
 import org.jboss.metamodel.descriptor.DDObjectFactory;
 import org.jboss.metamodel.descriptor.EjbLocalRef;
 import org.jboss.metamodel.descriptor.EjbRef;
@@ -57,6 +57,7 @@
  * chuncks from unmarshaller and assembles them into an EjbJarDD instance.
  *
  * @author <a href="mailto:bdecoste at jboss.com">William DeCoste</a>
+ * @author Anil.Saldhana at jboss.org
  * @version <tt>$Revision$</tt>
  */
 public class EjbJarDDObjectFactory extends DDObjectFactory
@@ -268,8 +269,12 @@
       child = newEjbHasInterceptorsChild(parent, localName);
       if (child != null) return child;
 
-      if (localName.equals("security-identity"))
+      if(localName.equals("security-role-ref"))
       {
+         child = new SecurityRoleRefMetaData(); 
+      }
+      else if (localName.equals("security-identity"))
+      {
          child = new SecurityIdentity();
       }
       else if (localName.equals("remove-method"))
@@ -300,8 +305,12 @@
       child = newEjbChild(parent, localName);
       if (child == null)
       {
-         if (localName.equals("cmp-field"))
+         if(localName.equals("security-role-ref"))
          {
+            child = new SecurityRoleRefMetaData(); 
+         }
+         else if (localName.equals("cmp-field"))
+         {
             child = new CmpField();
          }
          else if (localName.equals("query"))
@@ -747,6 +756,12 @@
       parent.addEnterpriseBean(ejb);
    }
 
+   public void addChild(SessionEnterpriseBean parent, SecurityRoleRefMetaData child,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   { 
+      parent.addSecurityRoleReference(child);
+   }
+   
    public void addChild(SessionEnterpriseBean parent, SecurityIdentity si,
                         UnmarshallingContext navigator, String namespaceURI, String localName)
    {
@@ -867,6 +882,12 @@
    {
       parent.addCmpField(field);
    }
+   
+   public void addChild(EntityEnterpriseBean parent, SecurityRoleRefMetaData child,
+         UnmarshallingContext navigator, String namespaceURI, String localName)
+   { 
+      parent.addSecurityRoleReference(child);
+   }
 
    /**
     * Called when parsing character is complete.
@@ -1401,6 +1422,23 @@
    }
 
    /**
+    * <!ELEMENT security-role-ref (rolename,role-link))>
+    */
+   public void setValue(SecurityRoleRefMetaData parent,
+         UnmarshallingContext navigator, String namespaceURI, String localName,
+         String value)
+   {
+      if(localName.equals("role-name"))
+      {
+         parent.setName(value); 
+      }
+      else if(localName.equals("role-link"))
+      {
+         parent.setLink(value); 
+      }
+   }
+   
+   /**
     * Called when a child element with simple content is read for DD.
     */
    public void setValue(SecurityIdentity si, UnmarshallingContext navigator,

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java	2006-12-15 18:23:19 UTC (rev 59063)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/EnterpriseBean.java	2006-12-15 21:13:34 UTC (rev 59064)
@@ -28,6 +28,7 @@
 import javax.ejb.TransactionManagementType;
 import org.jboss.logging.Logger;
 
+import org.jboss.metadata.SecurityRoleRefMetaData;
 import org.jboss.metamodel.descriptor.EnvironmentRefGroup;
 import org.jboss.metamodel.descriptor.InjectionTarget;
 import org.jboss.metamodel.descriptor.MessageDestinationRef; 
@@ -90,6 +91,10 @@
 
    private PoolConfig poolConfig = null;
    
+   /** The security-role-ref element(s) info */
+   private ArrayList<SecurityRoleRefMetaData> securityRoleReferences = new ArrayList<SecurityRoleRefMetaData>();
+   
+   
    public void addXmlAnnotation(XmlAnnotation annotation)
    {
       xmlAnnotations.add(annotation);
@@ -341,7 +346,22 @@
    {
       this.securityIdentity = securityIdentity;
    }
+   
+   public void addSecurityRoleReference(SecurityRoleRefMetaData srmd)
+   {
+      this.securityRoleReferences.add(srmd);
+   }
 
+   public ArrayList<SecurityRoleRefMetaData> getSecurityRoleReferences()
+   {
+      return securityRoleReferences;
+   }
+
+   public void setSecurityRoleReferences(ArrayList<SecurityRoleRefMetaData> securityRoleReferences)
+   {
+      this.securityRoleReferences = securityRoleReferences;
+   }
+
    public String toString()
    {
       StringBuffer sb = new StringBuffer(100);



From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 16:14:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 16:14:52 -0500
Subject: [jboss-cvs] JBossAS SVN: r59065 - trunk/ejb3/src/main/org/jboss/ejb3
Message-ID: <E1GvKOK-0006uu-6t@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-15 16:14:51 -0500 (Fri, 15 Dec 2006)
New Revision: 59065

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
Log:
EJBTHREE-808: isCallerInRoleChecks should include security role references

Modified: trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-15 21:13:34 UTC (rev 59064)
+++ trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-15 21:14:51 UTC (rev 59065)
@@ -27,7 +27,8 @@
 import java.io.ObjectOutput; 
 import java.security.Identity;
 import java.security.Principal;
-import java.util.HashSet;
+import java.util.HashSet; 
+import java.util.List;
 import java.util.Properties;
 import javax.ejb.EJBException;
 import javax.ejb.EJBHome;
@@ -46,11 +47,12 @@
 import javax.transaction.UserTransaction;
 import javax.xml.rpc.handler.MessageContext;
 import org.jboss.annotation.security.SecurityDomain;
-import org.jboss.aop.Advisor;
+import org.jboss.aop.Advisor; 
 import org.jboss.ejb3.security.SecurityDomainManager;
 import org.jboss.ejb3.tx.TxUtil;
 import org.jboss.ejb3.tx.UserTransactionImpl;
-import org.jboss.logging.Logger;
+import org.jboss.logging.Logger; 
+import org.jboss.metadata.SecurityRoleRefMetaData;
 import org.jboss.security.RealmMapping;
 import org.jboss.security.RunAsIdentity;
 import org.jboss.security.SecurityAssociation;
@@ -205,6 +207,19 @@
                       + "Check that a security-domain has been set for the application.";
          throw new IllegalStateException(msg);
       }
+      
+      //Ensure that you go through the security role references that may be configured
+      EJBContainer ejbc = (EJBContainer)container;
+      if(ejbc.getXml() != null)
+      {
+         List<SecurityRoleRefMetaData> securityRoleRefs = ejbc.getXml().getSecurityRoleReferences();
+         for(SecurityRoleRefMetaData srmd: securityRoleRefs)
+         {
+            String rname = srmd.getName(); 
+            if(roleName.equals(rname))
+               roleName = srmd.getLink();
+         } 
+      } 
 
       HashSet set = new HashSet();
       set.add(new SimplePrincipal(roleName));



From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 16:28:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 16:28:38 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1802 - in trunk:
	src/main/org/jboss/jms/client
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state src/main/org/jboss/jms/delegate
	src/main/org/jboss/jms/message src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/jms/tx tests
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GvKbe-00079S-FB@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-15 16:28:18 -0500 (Fri, 15 Dec 2006)
New Revision: 1802

Added:
   trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java
Removed:
   trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
Modified:
   trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
   trunk/src/main/org/jboss/jms/client/JBossSession.java
   trunk/src/main/org/jboss/jms/client/container/AsfAspect.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
   trunk/src/main/org/jboss/jms/message/MessageProxy.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/ConnectionConsumerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
Log:
Fixes for connection consumer



Modified: trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/JBossConnectionConsumer.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -304,7 +304,7 @@
                for (int i = 0; i < mesList.size(); i++)
                {
                   MessageProxy m = (MessageProxy)mesList.get(i);
-                  session.addAsfMessage(m, consumerID, channelID, maxDeliveries);
+                  session.addAsfMessage(m, consumerID, channelID, maxDeliveries, sess);
                   if (trace) { log.trace("added " + m + " to session"); }
                }
 

Modified: trunk/src/main/org/jboss/jms/client/JBossSession.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossSession.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/JBossSession.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -502,9 +502,10 @@
     * This method is used by the JBossConnectionConsumer to load up the session
     * with messages to be processed by the session's run() method
     */
-   void addAsfMessage(MessageProxy m, int consumerID, long channelID, int maxDeliveries)
+   void addAsfMessage(MessageProxy m, int consumerID, long channelID, int maxDeliveries,
+                      SessionDelegate connectionConsumerSession)
    {
-      delegate.addAsfMessage(m, consumerID, channelID, maxDeliveries);
+      delegate.addAsfMessage(m, consumerID, channelID, maxDeliveries, connectionConsumerSession);
    }
       
    // Protected -----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/container/AsfAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/AsfAspect.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/container/AsfAspect.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -34,7 +34,6 @@
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
-import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.message.MessageProxy;
@@ -131,6 +130,7 @@
       int theConsumerID = ((Integer)mi.getArguments()[1]).intValue();
       long channelID = ((Long)mi.getArguments()[2]).longValue();
       int maxDeliveries = ((Integer)mi.getArguments()[3]).intValue();
+      SessionDelegate connectionConsumerDelegate = ((SessionDelegate)mi.getArguments()[4]);
       
       if (m == null)
       {
@@ -142,6 +142,7 @@
       holder.consumerID = theConsumerID;
       holder.channelID = channelID;
       holder.maxDeliveries = maxDeliveries;
+      holder.connectionConsumerDelegate = connectionConsumerDelegate;
       
       msgs.add(holder);
 
@@ -154,6 +155,7 @@
       
       MethodInvocation mi = (MethodInvocation)invocation;
             
+      //This is the delegate for the session from the pool
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
       
       int ackMode = getSessionState(invocation).getAcknowledgeMode();
@@ -166,7 +168,8 @@
          
          MessageCallbackHandler.callOnMessage(del, sessionListener, holder.consumerID,
                                               holder.channelID, false,
-                                              holder.msg, ackMode, holder.maxDeliveries);                          
+                                              holder.msg, ackMode, holder.maxDeliveries,
+                                              holder.connectionConsumerDelegate);                          
       }
       
       return null;
@@ -191,5 +194,6 @@
       private int consumerID;
       private long channelID;
       private int maxDeliveries;
+      private SessionDelegate connectionConsumerDelegate;
    }
 }

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -23,12 +23,14 @@
 package org.jboss.jms.client.container;
 
 import java.util.ArrayList;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 
 import javax.jms.JMSException;
+import javax.jms.Session;
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
@@ -352,9 +354,7 @@
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
-         
-         if (trace) { log.trace("Failed session state has " + failedSessionState.getToAck().size() + " deliveries"); }
-         
+          
          int oldSessionId = failedSessionState.getSessionId();
 
          ClientSessionDelegate failedSessionDelegate =
@@ -367,7 +367,7 @@
 
          SessionState newSessionState = (SessionState)newSessionDelegate.getState();
          
-         if (trace) { log.trace("New session state has " + newSessionState.getToAck().size() + " deliveries"); }
+         if (trace) { log.trace("New session state has " + newSessionState.getClientAckList().size() + " deliveries"); }
          
          oldNewSessionStateMap.put(new Integer(oldSessionId), failedSessionState);
 
@@ -418,33 +418,58 @@
          SessionState state = (SessionState)iter.next();
          
          List ackInfos = null;
-         
-         if (!state.isTransacted() && !state.isXA())
+           
+         if (!state.isTransacted() ||
+             (state.isXA() && state.getCurrentTxId() == null))     
          {
-            //Now we remove any unacked np messages - this is because we don't want to ack them
+            //Non transacted session or an XA session with no transaction set (it falls back to auto_ack)
+            
+            if (trace) { log.trace("Session is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
+
+                        
+            //we remove any unacked np messages - this is because we don't want to ack them
             //since the server won't know about them and will barf
                         
-            Iterator iter2 = state.getToAck().iterator();
-            
-            if (trace) { log.trace("Removing any np deliveries"); }
-
-            while (iter2.hasNext())
+            if (state.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
             {
-               DeliveryInfo info = (DeliveryInfo)iter2.next();
-
-               if (!info.getMessageProxy().getMessage().isReliable())
+               Iterator iter2 = state.getClientAckList().iterator();
+               
+               if (trace) { log.trace("Removing any np deliveries"); }
+   
+               while (iter2.hasNext())
                {
-                  iter2.remove();
-                  
-                  if (trace) { log.trace("Removed np delivery: " + info.getDeliveryId()); }
+                  DeliveryInfo info = (DeliveryInfo)iter2.next();
+   
+                  if (!info.getMessageProxy().getMessage().isReliable())
+                  {
+                     iter2.remove();
+                     
+                     if (trace) { log.trace("Removed np delivery: " + info.getDeliveryId()); }
+                  }
                }
+               
+               ackInfos = state.getClientAckList();
             }
+            else
+            {
+               DeliveryInfo autoAck = state.getAutoAckInfo();
+               if (autoAck != null)                 
+               {
+                  if (!autoAck.getMessageProxy().getMessage().isReliable())
+                  {
+                     //unreliable
+                     state.setAutoAckInfo(null);
+                     ackInfos = Collections.EMPTY_LIST;
+                  }
+                  else
+                  {
+                     //reliable
+                     ackInfos = new ArrayList();
+                     ackInfos.add(autoAck);
+                  }
+               }               
+            }
             
-            if (trace) { log.trace("Session is not transacted, retrieving deliveries from session state"); }
-
-            //Get the ack infos from the list in the session state
-            ackInfos = state.getToAck();
-            
             if (trace) { log.trace("Retrieved " + ackInfos.size() + " deliveries"); }
          }
          else

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -36,7 +36,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
-import org.jboss.jms.server.endpoint.Cancel;
+import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DefaultAck;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.logging.Logger;
@@ -68,6 +68,30 @@
    
    // Public --------------------------------------------------------
 
+   private void ackDelivery(SessionDelegate sess, DeliveryInfo delivery) throws Exception
+   {
+      SessionDelegate connectionConsumerSession = delivery.getConnectionConsumerSession();
+      
+      //If the delivery was obtained via a connection consumer we need to ack via that
+      //otherwise we just use this session
+      
+      SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
+      
+      sessionToUse.acknowledgeDelivery(delivery);      
+   }
+   
+   private void cancelDelivery(SessionDelegate sess, DeliveryInfo delivery) throws Exception
+   {
+      SessionDelegate connectionConsumerSession = delivery.getConnectionConsumerSession();
+      
+      //If the delivery was obtained via a connection consumer we need to cancel via that
+      //otherwise we just use this session
+      
+      SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
+      
+      sessionToUse.cancelDelivery(new DefaultCancel(delivery.getDeliveryId(), delivery.getMessageProxy().getDeliveryCount()));      
+   }
+   
    public Object handleClosing(Invocation invocation) throws Throwable
    {
       MethodInvocation mi = (MethodInvocation)invocation;
@@ -75,42 +99,51 @@
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
       
       int ackMode = state.getAcknowledgeMode();
-
-      // select eligible acknowledgments
-      List acks = new ArrayList();
-      List cancels = new ArrayList();
-      for(Iterator i = state.getToAck().iterator(); i.hasNext(); )
+  
+      //We need to either ack (for auto_ack) or cancel (for client_ack)
+      //any deliveries - this is because the message listener might have closed
+      //before on message had finished executing
+      
+      if (ackMode == Session.AUTO_ACKNOWLEDGE ||
+          ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
+          (state.isXA() && state.getCurrentTxId() == null))
       {
-         DeliveryInfo ack = (DeliveryInfo)i.next();
-         if (ackMode == Session.AUTO_ACKNOWLEDGE ||
-             ackMode == Session.DUPS_OK_ACKNOWLEDGE)
+         //Acknowledge any outstanding auto ack
+         
+         DeliveryInfo remainingAutoAck = state.getAutoAckInfo();
+         
+         if (remainingAutoAck != null)
          {
-            acks.add(new DefaultAck(ack.getMessageProxy().getDeliveryId()));            
+            if (trace) { log.trace(this + " handleClosing(). Found remaining auto ack. Will ack it " + remainingAutoAck.getDeliveryId()); }
+            
+            ackDelivery(del, remainingAutoAck);
+            
+            if (trace) { log.trace(this + " acked it"); }
+            
+            state.setAutoAckInfo(null);
          }
-         else
+      }
+      else if (ackMode == Session.CLIENT_ACKNOWLEDGE)
+      {
+         // Cancel any oustanding deliveries
+         // We cancel any client ack or transactional, we do this explicitly so we can pass the updated
+         // delivery count information from client to server. We could just do this on the server but
+         // we would lose delivery count info.
+         
+         //CLIENT_ACKNOWLEDGE cannot be used with MDBs so is always safe to cancel on this session
+         
+         List cancels = new ArrayList();
+         
+         for(Iterator i = state.getClientAckList().iterator(); i.hasNext(); )
          {
-            Cancel cancel = new Cancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
+            DeliveryInfo ack = (DeliveryInfo)i.next();            
+            DefaultCancel cancel = new DefaultCancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
             cancels.add(cancel);
          }
-         i.remove();
+         
+         state.getClientAckList().clear();
       }
       
-      // On closing we acknowlege any AUTO_ACKNOWLEDGE or DUPS_OK_ACKNOWLEDGE, since the session
-      // might have closed before the onMessage had finished executing.
-      // We cancel any client ack or transactional, we do this explicitly so we can pass the updated
-      // delivery count information from client to server. We could just do this on the server but
-      // we would lose delivery count info.
-
-      if (!acks.isEmpty())
-      {
-         del.acknowledgeBatch(acks);
-      }
-      if (!cancels.isEmpty())
-      {
-         log.info("Calling canceldeliveries: " + cancels.size());
-         del.cancelDeliveries(cancels);
-      }
-
       return invocation.invokeNext();
    }
 
@@ -134,28 +167,37 @@
       
       int ackMode = state.getAcknowledgeMode();
       
-      if (ackMode == Session.CLIENT_ACKNOWLEDGE ||
-          ackMode == Session.AUTO_ACKNOWLEDGE ||
-          ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
-          state.getCurrentTxId() == null)
+      Object[] args = mi.getArguments();
+      DeliveryInfo info = (DeliveryInfo)args[0];
+      
+      if (ackMode == Session.CLIENT_ACKNOWLEDGE)
       {
-         // We collect acknowledgments (and not transact them) for CLIENT, AUTO and DUPS_OK, and
-         // also for XA sessions not enlisted in a global transaction.
- 
-         // We store the ack in a list for later acknowledgement or recovery
-    
-         Object[] args = mi.getArguments();
-         DeliveryInfo info = (DeliveryInfo)args[0];
-
-         state.getToAck().add(info);
+         // We collect acknowledgments in the list
          
-         if (trace)
-         { 
-            SessionDelegate del = (SessionDelegate)mi.getTargetObject();            
-            log.trace("ack mode is " + Util.acknowledgmentModeToString(ackMode)+ ", acknowledged on " + del);
-         }
+         if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack list"); }
+         
+         state.getClientAckList().add(info);
+         
+         //We can return immediately
+         return null;
       }
-
+      else if (ackMode == Session.AUTO_ACKNOWLEDGE ||
+               ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
+               (state.isXA() && state.getCurrentTxId() == null))
+      {
+         //We collect the single acknowledgement in the state.
+         //Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE
+         //Also XA sessions not enlisted in a global tx are treated as AUTO_ACKNOWLEDGE
+         
+         if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack member"); }
+         
+         state.setAutoAckInfo(info);         
+         
+         //We can return immediately         
+         return null;
+      }
+              
+      //Transactional - need to carry on down the stack
       return invocation.invokeNext();
    }
    
@@ -166,11 +208,13 @@
       SessionState state = getState(invocation);
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
     
-      if (!state.getToAck().isEmpty())
-      {                  
-         del.acknowledgeBatch(state.getToAck());
+      if (!state.getClientAckList().isEmpty())
+      {                 
+         //CLIENT_ACKNOWLEDGE can't be used with a MDB so it is safe to always acknowledge all
+         //on this session (rather than the connection consumer session)
+         del.acknowledgeDeliveries(state.getClientAckList());
       
-         state.getToAck().clear();
+         state.getClientAckList().clear();
       }
         
       return null;
@@ -192,42 +236,35 @@
       
       if (ackMode == Session.AUTO_ACKNOWLEDGE ||
           ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
-          (ackMode != Session.CLIENT_ACKNOWLEDGE && state.getCurrentTxId() == null))
+          (state.isXA() && state.getCurrentTxId() == null))
       {
-         // We acknowledge immediately on a non-transacted session that does not want to
-         // CLIENT_ACKNOWLEDGE, or an XA session not enrolled in a global transaction.
-
+         //We auto acknowledge
+         //Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE
+         //Also XA sessions not enlisted in a global tx are treated as AUTO_ACKNOWLEDGE
+         
          SessionDelegate sd = (SessionDelegate)mi.getTargetObject();
 
          if (!state.isRecoverCalled())
          {
-            if (trace) { log.trace("acknowledging NON-transactionally"); }
-                        
-            List acks = state.getToAck();
+            DeliveryInfo deliveryInfo = state.getAutoAckInfo();
             
-            // Sanity check
-            if (acks.size() != 1)
+            if (deliveryInfo == null)
             {
-               throw new IllegalStateException("Should only be one entry in list. " +
-                                               "There are " + acks.size());
+               throw new IllegalStateException("Cannot find delivery to auto ack");
             }
-            
-            DeliveryInfo ack = (DeliveryInfo)acks.get(0);
-            
+                                 
+            if (trace) { log.trace(this + " auto acking delivery " + deliveryInfo.getDeliveryId()); }
+                        
             if (cancel)
             {
-               List cancels = new ArrayList();
-               Cancel c = new Cancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
-               cancels.add(c);
-               sd.cancelDeliveries(cancels);
+               cancelDelivery(sd, deliveryInfo);
             }
             else
             {
-               sd.acknowledge(ack);
+               ackDelivery(sd, deliveryInfo);
             }
             
-            //TODO we can optimise this for the auto_ack case (i.e. not store in list and have to clear each time)
-            state.getToAck().clear();
+            state.setAutoAckInfo(null);
          }
          else
          {
@@ -251,9 +288,7 @@
             
       SessionState state = getState(invocation);
       
-      int ackMode = state.getAcknowledgeMode();
-         
-      if (ackMode == Session.SESSION_TRANSACTED)
+      if (state.isTransacted())
       {
          throw new IllegalStateException("Cannot recover a transacted session");
       }
@@ -263,9 +298,27 @@
       //Call redeliver
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
       
-      del.redeliver(state.getToAck());
+      if (state.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
+      {
+         del.redeliver(state.getClientAckList());
+         
+         state.getClientAckList().clear();
+      }
+      else
+      {
+         DeliveryInfo info = state.getAutoAckInfo();
+         
+         if (info != null)
+         {
+            List redels = new ArrayList();
             
-      state.getToAck().clear();
+            redels.add(info);
+            
+            del.redeliver(redels);
+            
+            state.setAutoAckInfo(null);            
+         }
+      }            
 
       state.setRecoverCalled(true);
       
@@ -297,9 +350,7 @@
     * was called.
     */
    public Object handleRedeliver(Invocation invocation) throws Throwable
-   {
-      if (trace) { log.trace("redeliver called"); }
-      
+   {            
       MethodInvocation mi = (MethodInvocation)invocation;
       SessionState state = getState(invocation);
             
@@ -307,8 +358,11 @@
       // JMSRedelivered to true.
       
       List toRedeliver = (List)mi.getArguments()[0];
-      LinkedList toCancel = new LinkedList();
       
+      if (trace) { log.trace(this + " handleRedeliver() called: " + toRedeliver); }
+      
+      SessionDelegate del = (SessionDelegate)mi.getTargetObject();
+      
       // Need to be recovered in reverse order.
       for (int i = toRedeliver.size() - 1; i >= 0; i--)
       {
@@ -319,25 +373,17 @@
               
          if (handler == null)
          {
-            // This is ok. The original consumer has closed, this message wil get cancelled back
-            // to the channel.
-            Cancel cancel = new Cancel(info.getMessageProxy().getDeliveryId(), info.getMessageProxy().getDeliveryCount());
-            toCancel.addFirst(cancel);
+            // This is ok. The original consumer has closed, so we cancel the message
+            
+            cancelDelivery(del, info);
          }
          else
          {
+            if (trace) { log.trace("Adding proxy back to front of buffer"); }
             handler.addToFrontOfBuffer(proxy);
          }                                    
       }
-      
-      if (!toCancel.isEmpty())
-      {
-         // Cancel the messages that can't be redelivered locally
-         
-         SessionDelegate del = (SessionDelegate)mi.getTargetObject();
-         del.cancelDeliveries(toCancel);
-      }
-            
+              
       return null;  
    }
    

Modified: trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -27,6 +27,7 @@
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.client.state.HierarchicalState;
@@ -194,7 +195,16 @@
 
          if (trace) { log.trace("sending acknowlegment transactionally, queueing on resource manager"); }
 
-         connState.getResourceManager().addAck(txID, state.getSessionId(), info);
+         //If the ack is for a delivery that came through via a connection consumer then we
+         //use the connectionConsumer session as the session id, otherwise we use this sessions'
+         //session id
+         
+         ClientSessionDelegate connectionConsumerDelegate =
+            (ClientSessionDelegate)info.getConnectionConsumerSession();
+         
+         int sessionId = connectionConsumerDelegate != null ? connectionConsumerDelegate.getID() : state.getSessionId();
+         
+         connState.getResourceManager().addAck(txID, sessionId, info);
       }
 
       return null;

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -44,6 +44,7 @@
 import org.jboss.jms.message.StreamMessageProxy;
 import org.jboss.jms.message.TextMessageProxy;
 import org.jboss.jms.server.endpoint.Ack;
+import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.remoting.Client;
 
@@ -112,7 +113,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void acknowledge(Ack ack) throws JMSException
+   public void acknowledgeDelivery(Ack ack) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -121,7 +122,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void acknowledgeBatch(List acks) throws JMSException
+   public void acknowledgeDeliveries(List acks) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -405,7 +406,8 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void addAsfMessage(MessageProxy m, int consumerID, long channelId, int maxDeliveries)
+   public void addAsfMessage(MessageProxy m, int consumerID, long channelId, int maxDeliveries,
+                             SessionDelegate connectionConsumerSession)
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -423,7 +425,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void cancelDeliveries(List ackInfos)
+   public void cancelDeliveries(List cancels)
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -432,6 +434,15 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
+   public void cancelDelivery(Cancel cancel)
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+   
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
    public void recoverDeliveries(List ackInfos) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -34,7 +34,7 @@
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
-import org.jboss.jms.server.endpoint.Cancel;
+import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.util.Future;
@@ -65,6 +65,7 @@
       trace = log.isTraceEnabled();
    }
      
+   //This is static so it can be called by the asf layer too
    public static void callOnMessage(SessionDelegate sess,
                                     MessageListener listener,
                                     int consumerID,
@@ -72,10 +73,16 @@
                                     boolean isConnectionConsumer,
                                     MessageProxy m,
                                     int ackMode,
-                                    int maxDeliveries)
+                                    int maxDeliveries,
+                                    SessionDelegate connectionConsumerSession)
       throws JMSException
    {
-      preDeliver(sess, consumerID, channelID, m, isConnectionConsumer);
+      // If this is the callback-handler for a connection consumer we don't want to acknowledge or
+      // add anything to the tx for this session.
+      if (!isConnectionConsumer)
+      {
+         sess.preDeliver(new DeliveryInfo(m, consumerID, channelID, connectionConsumerSession));
+      }  
                   
       int tries = 0;
       
@@ -136,36 +143,16 @@
       if (!sess.isClosed())
       {
          // postDeliver only if the session is not closed
-         postDeliver(sess, isConnectionConsumer, cancel);
+
+         // If this is the callback-handler for a connection consumer we don't want to acknowledge or
+         // add anything to the tx for this session
+         if (!isConnectionConsumer)
+         {
+            sess.postDeliver(cancel);
+         }   
       }
    }
    
-   protected static void preDeliver(SessionDelegate sess,
-                                    int consumerID,
-                                    long channelID,
-                                    MessageProxy m,
-                                    boolean isConnectionConsumer)
-      throws JMSException
-   {
-      // If this is the callback-handler for a connection consumer we don't want to acknowledge or
-      // add anything to the tx for this session.
-      if (!isConnectionConsumer)
-      {
-         sess.preDeliver(new DeliveryInfo(m, consumerID, channelID));
-      }         
-   }
-   
-   protected static void postDeliver(SessionDelegate sess, boolean isConnectionConsumer,
-                                     boolean cancel) throws JMSException
-   {
-      // If this is the callback-handler for a connection consumer we don't want to acknowledge or
-      // add anything to the tx for this session
-      if (!isConnectionConsumer)
-      {
-         sess.postDeliver(cancel);
-      }         
-   }
-   
    // Attributes ----------------------------------------------------
       
    private LinkedList buffer;
@@ -331,7 +318,7 @@
          for(Iterator i = buffer.iterator(); i.hasNext();)
          {
             MessageProxy mp = (MessageProxy)i.next();
-            Cancel ack = new Cancel(mp.getDeliveryId(), mp.getDeliveryCount());
+            DefaultCancel ack = new DefaultCancel(mp.getDeliveryId(), mp.getDeliveryCount());
             cancels.add(ack);
          }
                
@@ -450,9 +437,15 @@
                        
                // If message is expired we still call pre and post deliver. This makes sure the
                // message is acknowledged so it gets removed from the queue/subscription.
-               preDeliver(sessionDelegate, consumerID, channelID, m, isConnectionConsumer);
+
+               if (!isConnectionConsumer)
+               {
+                  sessionDelegate.preDeliver(new DeliveryInfo(m, consumerID, channelID, null));
+                  
+                  sessionDelegate.postDeliver(false);
+               }
                
-               postDeliver(sessionDelegate, isConnectionConsumer, false);
+               //postDeliver(sessionDelegate, isConnectionConsumer, false);
                
                if (!m.getMessage().isExpired())
                {
@@ -731,7 +724,7 @@
          {
             try
             {
-               callOnMessage(sessionDelegate, listener, consumerID, channelID, false, mp, ackMode, maxDeliveries);
+               callOnMessage(sessionDelegate, listener, consumerID, channelID, false, mp, ackMode, maxDeliveries, null);
             }
             catch (JMSException e)
             {

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -32,6 +32,7 @@
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.server.Version;
+import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.tx.MessagingXAResource;
 import org.jboss.logging.Logger;
 
@@ -68,14 +69,16 @@
    
    private boolean recoverCalled;
 
-   // List<AckInfo>
-   private List toAck;
+   // List<DeliveryInfo>
+   private List ClientAckList;
+   
+   private DeliveryInfo autoAckInfo;
 
    private ConnectionState parent;
    
    private SessionDelegate delegate;
    
-   private Map callbackHandlers;
+   private Map callbackHandlers;     
    
    public SessionState(ConnectionState parent, ClientSessionDelegate delegate,
                        boolean transacted, int ackMode, boolean xa)
@@ -106,7 +109,7 @@
       
       executor = new QueuedExecutor(new LinkedQueue());
       
-      toAck = new ArrayList();
+      ClientAckList = new ArrayList();
       
       // TODO could optimise this to use the same map of callbackmanagers (which holds refs
       // to callbackhandlers) in the connection, instead of maintaining another map
@@ -137,11 +140,25 @@
    /**
     * @return List<AckInfo>
     */
-   public List getToAck()
+   public List getClientAckList()
    {
-      return toAck;
+      return ClientAckList;
    }
    
+   public DeliveryInfo getAutoAckInfo()
+   {
+      return autoAckInfo;
+   }
+   
+   public void setAutoAckInfo(DeliveryInfo info)
+   {
+      if (info != null && autoAckInfo != null)
+      {
+         throw new IllegalStateException("There is already a delivery set for auto ack");
+      }
+      autoAckInfo = info;
+   }
+   
    public int getAcknowledgeMode()
    {
       return acknowledgeMode;

Modified: trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -78,7 +78,8 @@
    
    XAResource getXAResource();
    
-   void addAsfMessage(MessageProxy m, int consumerID, long channelID, int maxDeliveries);
+   void addAsfMessage(MessageProxy m, int consumerID, long channelID,
+                      int maxDeliveries, SessionDelegate connectionConsumerDelegate);
    
    boolean getTransacted();
    

Modified: trunk/src/main/org/jboss/jms/message/MessageProxy.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/MessageProxy.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/message/MessageProxy.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -65,6 +65,8 @@
 
    // Attributes ----------------------------------------------------
 
+   //The actual session delegate for the message - needed for doing recovery
+   //so we can recover locally
    private transient SessionDelegate delegate;
    
    private transient boolean cc;

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -37,6 +37,7 @@
 import org.jboss.jms.server.connectionfactory.ConnectionFactoryJNDIMapper;
 import org.jboss.jms.server.connectionmanager.SimpleConnectionManager;
 import org.jboss.jms.server.connectormanager.SimpleConnectorManager;
+import org.jboss.jms.server.endpoint.ServerSessionEndpoint;
 import org.jboss.jms.server.plugin.contract.JMSUserManager;
 import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
 import org.jboss.jms.server.remoting.JMSWireFormat;
@@ -65,6 +66,8 @@
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
 
+import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
+
 /**
  * A JMS server peer.
  *
@@ -112,6 +115,8 @@
    private long failoverStartTimeout = 3000;
    
    private long failoverCompleteTimeout = 12000;
+   
+   private Map sessions;
       
    // wired components
 
@@ -159,9 +164,11 @@
       version = Version.instance();
       
       failoverStatusLock = new Object();
+      
+      sessions = new ConcurrentReaderHashMap();
 
       started = false;
-   }
+   }      
 
    // ServiceMBeanSupport overrides ---------------------------------
 
@@ -566,6 +573,24 @@
    }
 
    // Public --------------------------------------------------------
+   
+   public ServerSessionEndpoint getSession(Integer sessionID)
+   {
+      return (ServerSessionEndpoint)sessions.get(sessionID);
+   }
+   
+   public void addSession(Integer id, ServerSessionEndpoint session)
+   {
+      sessions.put(id, session);      
+   }
+   
+   public void removeSession(Integer id)
+   {
+      if (sessions.remove(id) == null)
+      {
+         throw new IllegalStateException("Cannot find session with id " + id + " to remove");
+      }
+   }
 
    public Queue getDLQ() throws Exception
    {

Deleted: trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -1,105 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-
-import org.jboss.messaging.util.Streamable;
-
-/**
- * 
- * A Cancel.
- * 
- * Used to send a cancel (NACK) to the server
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- *
- */
-public class Cancel implements Streamable
-{
-   // Constants -----------------------------------------------------
-   
-   // Attributes ----------------------------------------------------
-   
-   private long deliveryId;
-   
-   private int deliveryCount;      
-
-   // Static --------------------------------------------------------
-   
-   // Constructors --------------------------------------------------
-   
-   public Cancel()
-   {      
-   }
-   
-   public Cancel(long deliveryId, int deliveryCount)
-   {      
-      this.deliveryId = deliveryId;
-      
-      this.deliveryCount = deliveryCount;
-   }
-
-   // Public --------------------------------------------------------
-   
-   public long getDeliveryId()
-   {
-      return deliveryId;
-   }
-   
-   public int getDeliveryCount()
-   {
-      return deliveryCount;
-   }
-
-   // Streamable implementation -------------------------------------
-   
-   public void read(DataInputStream in) throws Exception
-   {
-      deliveryId = in.readLong();
-      
-      deliveryCount = in.readInt();
-   }
-
-   public void write(DataOutputStream out) throws Exception
-   {
-      out.writeLong(deliveryId);
-      
-      out.writeInt(deliveryCount);
-   }
-
-   // Class YYY overrides -------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Package Private -----------------------------------------------
-
-   // Private -------------------------------------------------------
-   
-   // Inner Classes -------------------------------------------------
-   
-}
-

Copied: trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java (from rev 1798, trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java)
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-15 08:59:37 UTC (rev 1798)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -0,0 +1,85 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+
+/**
+ * 
+ * A Cancel.
+ * 
+ * Used to send a cancel (NACK) to the server
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class DefaultCancel implements Cancel
+{
+   // Constants -----------------------------------------------------
+   
+   // Attributes ----------------------------------------------------
+   
+   private long deliveryId;
+   
+   private int deliveryCount;      
+
+   // Static --------------------------------------------------------
+   
+   // Constructors --------------------------------------------------
+   
+   public DefaultCancel()
+   {      
+   }
+   
+   public DefaultCancel(long deliveryId, int deliveryCount)
+   {      
+      this.deliveryId = deliveryId;
+      
+      this.deliveryCount = deliveryCount;
+   }
+
+   // Public --------------------------------------------------------
+   
+   public long getDeliveryId()
+   {
+      return deliveryId;
+   }
+   
+   public int getDeliveryCount()
+   {
+      return deliveryCount;
+   }
+
+   // Class YYY overrides -------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Package Private -----------------------------------------------
+
+   // Private -------------------------------------------------------
+   
+   // Inner Classes -------------------------------------------------
+   
+}
+

Modified: trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -21,6 +21,7 @@
   */
 package org.jboss.jms.server.endpoint;
 
+import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
 
 /**
@@ -48,18 +49,29 @@
 
    private MessageProxy msg;
    
+   //When using the evil abomination known as a ConnectionConsumer, the connection consumer
+   //will get from a session that it created, then pass them onto sessions got from the pool
+   //this means when the messages are acked/cancelled then this needs to be done against
+   //the connection consumer's session not the session from the pool, since that session won't know
+   //about the deliveries on the server side
+   //Therefore if this delivery was done using a connection consumer then this attribute is set
+   //to the connection consumer's session, otherwise it will be null
+   private SessionDelegate connectionConsumerSession;
+   
    // Static --------------------------------------------------------
    
    // Constructors --------------------------------------------------
    
-
-   public DeliveryInfo(MessageProxy msg, int consumerId, long channelID)
+   public DeliveryInfo(MessageProxy msg, int consumerId, long channelID,
+                       SessionDelegate connectionConsumerSession)
    {      
       this.msg = msg;
       
       this.consumerId = consumerId;
       
       this.channelID = channelID;
+      
+      this.connectionConsumerSession = connectionConsumerSession;
    }
 
    // Public --------------------------------------------------------
@@ -79,6 +91,11 @@
       return msg;
    }
    
+   public SessionDelegate getConnectionConsumerSession()
+   {
+      return connectionConsumerSession;
+   }
+   
 
    // Ack Implementation  -------------------------------------------
    

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -189,7 +189,11 @@
          
          SessionAdvised sessionAdvised = new SessionAdvised(ep);
          
-         JMSDispatcher.instance.registerTarget(new Integer(sessionID), sessionAdvised);
+         Integer iSessionID = new Integer(sessionID);
+         
+         serverPeer.addSession(iSessionID, ep);
+         
+         JMSDispatcher.instance.registerTarget(iSessionID, sessionAdvised);
 
          ClientSessionDelegate d = new ClientSessionDelegate(sessionID);
                  
@@ -649,8 +653,14 @@
                      
             List acks = sessionState.getAcks();
             
-            ServerSessionEndpoint session = (ServerSessionEndpoint)sessions.get(new Integer(sessionState.getSessionId()));
+            //We need to lookup the session in a global map maintained on the server peer.
+            //We can't just assume it's one of the sessions in the connection.
+            //This is because in the case of a connection consumer, the message might be delivered through one
+            //connection and the transaction committed/rolledback through another.
+            //ConnectionConsumers suck.
             
+            ServerSessionEndpoint session = serverPeer.getSession(new Integer(sessionState.getSessionId()));
+            
             session.acknowledgeTransactionally(acks, tx);      
          }
       }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -83,8 +83,17 @@
 import EDU.oswego.cs.dl.util.concurrent.SynchronizedLong;
 
 /**
- * Concrete implementation of SessionEndpoint.
+ * The server side representation of a JMS session.
  * 
+ * A user must not invoke methods of a session concurrently on different threads, however
+ * there are situations where multiple threads may access this object concurrently, for instance:
+ * 
+ * A session can be closed when it's connection is closed by the user which might be called on a different thread
+ * A session can be closed when the server determines the connection is dead.
+ * If the session represents a connection consumer's session then the connection consumer will farm off
+ * messages to different sessions obtained from a pool, these may then cancel/ack etc on different threads, but
+ * the acks/cancels/etc will end up back here on the connection consumer session instance.
+ * 
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
@@ -109,6 +118,8 @@
    private volatile boolean closed;
 
    private ServerConnectionEndpoint connectionEndpoint;
+   
+   private ServerPeer sp;
 
    private Map consumers;
    private Map browsers;
@@ -140,7 +151,7 @@
 
       this.connectionEndpoint = connectionEndpoint;
 
-      ServerPeer sp = connectionEndpoint.getServerPeer();
+      sp = connectionEndpoint.getServerPeer();
 
       pm = sp.getPersistenceManagerInstance();
       ms = sp.getMessageStore();
@@ -327,24 +338,31 @@
       }
    }
    
-   public void acknowledgeBatch(List acks) throws JMSException
-   {      
+   public void acknowledgeDelivery(Ack ack) throws JMSException
+   {
       try
       {
+         acknowledgeDeliveryInternal(ack);   
+      }
+      catch (Throwable t)
+      {
+         throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledge");
+      }
+   }     
+         
+   public void acknowledgeDeliveries(List acks) throws JMSException
+   {    
+      if (trace) {log.trace(this + " acknowledgeDeliveries " + acks); }
+      
+      try
+      {
          Iterator iter = acks.iterator();
          
          while (iter.hasNext())
          {
             Ack ack = (Ack)iter.next();
             
-            Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
-            
-            if (del == null)
-            {
-               throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
-            }
-            
-            del.acknowledge(null);
+            acknowledgeDeliveryInternal(ack);
          }
       }
       catch (Throwable t)
@@ -352,107 +370,46 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledgeBatch");
       }
    }
-   
-   public void acknowledge(Ack ack) throws JMSException
+       
+   public void cancelDelivery(Cancel cancel) throws JMSException
    {
+      if (trace) {log.trace(this + " cancelDelivery " + cancel); }
+      
       try
       {
-         Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
+         Delivery del = cancelDeliveryInternal(cancel);
          
-         if (del == null)
-         {
-            throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
-         }
-         
-         del.acknowledge(null);    
+         //Prompt delivery
+         ((Channel)del.getObserver()).deliver(false);
       }
       catch (Throwable t)
       {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledge");
+         throw ExceptionUtil.handleJMSInvocation(t, this + " cancelDelivery");
       }
-   }     
+     
+   }      
 
    public void cancelDeliveries(List cancels) throws JMSException
    {
+      if (trace) {log.trace(this + " cancelDeliveries " + cancels); }
+      
       try
       {
          // deliveries must be cancelled in reverse order
-           
-         List forDLQ = null;
-         
+
          Set channels = new HashSet();
                            
          for (int i = cancels.size() - 1; i >= 0; i--)
          {
-            Cancel cancel = (Cancel)cancels.get(i);
+            Cancel cancel = (Cancel)cancels.get(i);       
             
-            Delivery del = (Delivery)deliveries.remove(new Long(cancel.getDeliveryId()));
+            if (trace) { log.trace("Cancelling delivery " + cancel.getDeliveryId()); }
             
-            if (del == null)
-            {
-               throw new IllegalStateException("Cannot find delivery to cancel " + cancel.getDeliveryId());
-            }
-                                    
-            if (cancel.getDeliveryCount() >= maxDeliveryAttempts)
-            {
-               if (forDLQ == null)
-               {
-                  forDLQ = new ArrayList();
-               }
-               
-               forDLQ.add(del);
-            }
-            else
-            {                                                   
-               del.getReference().setDeliveryCount(cancel.getDeliveryCount());
-               
-               del.cancel();
-               
-               channels.add(del.getObserver());
-            }
+            Delivery del = cancelDeliveryInternal(cancel);
+            
+            channels.add(del.getObserver());
          }
-         
-         //Send stuff to DLQ
-         
-         if (forDLQ != null)
-         {
-            //We do this in a tx so we don't end up with the message in both the original queue
-            //and the dlq if it fails half way through
-            Transaction tx = tr.createTransaction();
-            
-            try
-            {               
-               for (int i = forDLQ.size() - 1; i >= 0; i--)
-               {
-                  Delivery del = (Delivery)forDLQ.get(i);
                   
-                  if (dlq != null)
-                  {         
-                     //reset delivery count to zero
-                     del.getReference().setDeliveryCount(0);
-                     
-                     dlq.handle(null, del.getReference(), tx);
-                     
-                     del.acknowledge(tx);           
-                  }
-                  else
-                  {
-                     log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
-                     
-                     del.acknowledge(tx);
-                  }                              
-               }
-               
-               tx.commit();
-            }
-            catch (Throwable t)
-            {
-               tx.rollback();
-               
-               throw t;
-            }
-         }
-         
          // need to prompt delivery for all affected channels
          
          promptDelivery(channels);
@@ -767,21 +724,7 @@
          }
       }
    }
-   
-//   void promptDeliveryOnConsumers()
-//   {
-//      if (trace) { log.trace(this + " promptDeliveryOnConsumers(), there are " + consumers.size() + " consumers"); }
-//      synchronized (consumers)
-//      {         
-//         for (Iterator i = consumers.values().iterator(); i.hasNext(); )
-//         {
-//            ServerConsumerEndpoint consumer = (ServerConsumerEndpoint)i.next();
-//            
-//            consumer.promptDelivery();
-//         }
-//      }
-//   }
-   
+    
    void localClose() throws Throwable
    {
       if (closed)
@@ -853,6 +796,8 @@
       promptDelivery(channels);
       
       deliveries.clear();
+      
+      sp.removeSession(new Integer(id));
             
       JMSDispatcher.instance.unregisterTarget(new Integer(id));
       
@@ -940,7 +885,75 @@
    // Protected -----------------------------------------------------        
 
    // Private -------------------------------------------------------
+   
+   private void acknowledgeDeliveryInternal(Ack ack) throws Throwable
+   {
+      if (trace) { log.trace("Acknowledging delivery " + ack.getDeliveryId()); }
       
+      Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
+      
+      if (del == null)
+      {
+         throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
+      }
+      
+      del.acknowledge(null);    
+   } 
+   
+   private Delivery cancelDeliveryInternal(Cancel cancel) throws Throwable
+   {
+      Delivery del = (Delivery)deliveries.remove(new Long(cancel.getDeliveryId()));
+      
+      if (del == null)
+      {
+         throw new IllegalStateException("Cannot find delivery to cancel " + cancel.getDeliveryId());
+      }
+                              
+      if (cancel.getDeliveryCount() >= maxDeliveryAttempts)
+      {
+         //Send to DLQ
+         
+         //We do this in a tx so we don't end up with the message in both the original queue
+         //and the dlq if it fails half way through
+         Transaction tx = tr.createTransaction();
+         
+         try
+         {               
+            if (dlq != null)
+            {         
+               //reset delivery count to zero
+               del.getReference().setDeliveryCount(0);
+               
+               dlq.handle(null, del.getReference(), tx);
+               
+               del.acknowledge(tx);           
+            }
+            else
+            {
+               log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
+               
+               del.acknowledge(tx);
+            }                              
+                        
+            tx.commit();
+         }
+         catch (Throwable t)
+         {
+            tx.rollback();
+            
+            throw t;
+         }         
+      }
+      else
+      {                                                   
+         del.getReference().setDeliveryCount(cancel.getDeliveryCount());
+         
+         del.cancel();
+      }
+      
+      return del;
+   }
+      
    private ConsumerDelegate failoverConsumer(JBossDestination jmsDestination,
             String selectorString,
             boolean noLocal,  String subscriptionName,
@@ -1277,6 +1290,8 @@
    }
    
    
+   
+   
    // Inner classes -------------------------------------------------
    
    /**

Modified: trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -68,20 +68,33 @@
    JBossTopic createTopic(String topicName) throws JMSException;
  
    /**
-    * Acknowledge a batch of messages - used with client acknowledge or dups_ok acknowledge
+    * Acknowledge a list of deliveries
     * @param ackInfos
     * @throws JMSException
     */
-   void acknowledgeBatch(List deliveryIds) throws JMSException;
+   void acknowledgeDeliveries(List deliveryIds) throws JMSException;
    
    /**
-    * Acknowledge a message - used for auto acknowledge
+    * Acknowledge a delivery
     * @param deliveryId
     * @throws JMSException
     */
-   void acknowledge(Ack ack) throws JMSException;
+   void acknowledgeDelivery(Ack ack) throws JMSException;
    
    /**
+    * Cancel a list of deliveries.
+    * @param ackInfos
+    */
+   void cancelDeliveries(List cancelInfos) throws JMSException;
+         
+   /**
+    * Cancel a delivery
+    * @param cancel
+    * @throws JMSException
+    */
+   void cancelDelivery(Cancel cancel) throws JMSException;
+   
+   /**
     * Add a temporary destination.
     */
    void addTemporaryDestination(JBossDestination destination) throws JMSException;
@@ -108,14 +121,6 @@
    void send(JBossMessage message) throws JMSException;
    
    /**
-    * Cancel some deliveries.
-    * This used at consumer close to cancel any undelivered messages left in the client buffer
-    * or at session recovery to cancel any messages that couldn't be redelivered locally
-    * @param ackInfos
-    */
-   void cancelDeliveries(List cancelInfos) throws JMSException;
-      
-   /**
     * Send delivery info to the server so the delivery lists can be repopulated
     * used at failover
     * @param ackInfos

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/SessionAdvised.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -32,6 +32,7 @@
 import org.jboss.jms.destination.JBossTopic;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.endpoint.Ack;
+import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.SessionEndpoint;
 
 /**
@@ -102,14 +103,14 @@
       return endpoint.createTopic(topicName);
    }
 
-   public void acknowledgeBatch(List acks) throws JMSException
+   public void acknowledgeDeliveries(List acks) throws JMSException
    {
-      endpoint.acknowledgeBatch(acks);
+      endpoint.acknowledgeDeliveries(acks);
    }
    
-   public void acknowledge(Ack ack) throws JMSException
+   public void acknowledgeDelivery(Ack ack) throws JMSException
    {
-      endpoint.acknowledge(ack);
+      endpoint.acknowledgeDelivery(ack);
    }
 
    public void addTemporaryDestination(JBossDestination destination) throws JMSException
@@ -132,6 +133,11 @@
       endpoint.cancelDeliveries(ackInfos);
    }
    
+   public void cancelDelivery(Cancel cancel) throws JMSException
+   {
+      endpoint.cancelDelivery(cancel);
+   }
+   
    public void recoverDeliveries(List ackInfos) throws JMSException
    {
       endpoint.recoverDeliveries(ackInfos);

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -46,6 +46,7 @@
 import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.ClientDelivery;
 import org.jboss.jms.server.endpoint.DefaultAck;
+import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.logging.Logger;
@@ -92,14 +93,15 @@
 
    protected static final byte SERIALIZED = 0;   
    protected static final byte ACKNOWLEDGE = 1;
-   protected static final byte ACKNOWLEDGE_BATCH = 2;
-   protected static final byte SEND = 3;   
-   protected static final byte CANCEL_DELIVERIES = 4;
-   protected static final byte MORE = 5;
-   protected static final byte SEND_TRANSACTION = 6;
-   protected static final byte GET_ID_BLOCK = 7;
-   protected static final byte RECOVER_DELIVERIES = 8;
-   protected static final byte CONFIRM_DELIVERY = 9;
+   protected static final byte ACKNOWLEDGE_LIST = 2;
+   protected static final byte CANCEL = 3;
+   protected static final byte CANCEL_LIST = 4;
+   protected static final byte SEND = 5;   
+   protected static final byte MORE = 6;
+   protected static final byte SEND_TRANSACTION = 7;
+   protected static final byte GET_ID_BLOCK = 8;
+   protected static final byte RECOVER_DELIVERIES = 9;
+   protected static final byte CONFIRM_DELIVERY = 10;
  
 
    // The response codes - start from 100
@@ -231,7 +233,7 @@
    
                   if (trace) { log.trace("wrote activate()"); }
                }           
-               else if ("acknowledge".equals(methodName))
+               else if ("acknowledgeDelivery".equals(methodName))
                {
                   dos.writeByte(ACKNOWLEDGE);
    
@@ -243,11 +245,11 @@
    
                   dos.flush();
    
-                  if (trace) { log.trace("wrote acknowledge()"); }
+                  if (trace) { log.trace("wrote acknowledgeDelivery()"); }
                }
-               else if ("acknowledgeBatch".equals(methodName))
+               else if ("acknowledgeDeliveries".equals(methodName))
                {
-                  dos.writeByte(ACKNOWLEDGE_BATCH);
+                  dos.writeByte(ACKNOWLEDGE_LIST);
    
                   writeHeader(mi, dos);
                   
@@ -265,39 +267,27 @@
    
                   dos.flush();
    
-                  if (trace) { log.trace("wrote acknowledge()"); }
+                  if (trace) { log.trace("wrote acknowledgeDeliveries()"); }
                }
-               else if ("sendTransaction".equals(methodName))
+               else if ("cancelDelivery".equals(methodName))
                {
-                  dos.writeByte(SEND_TRANSACTION);
+                  dos.writeByte(CANCEL);
    
                   writeHeader(mi, dos);
-   
-                  TransactionRequest request = (TransactionRequest)mi.getArguments()[0];
-   
-                  request.write(dos);
-   
+                  
+                  Cancel cancel = (Cancel)mi.getArguments()[0];
+                  
+                  dos.writeLong(cancel.getDeliveryId());
+                  
+                  dos.writeInt(cancel.getDeliveryCount());
+                  
                   dos.flush();
    
-                  if (trace) { log.trace("wrote getMessageNow()"); }
+                  if (trace) { log.trace("wrote cancelDelivery()"); }
                }
-               else if ("getIdBlock".equals(methodName))
-               {
-                  dos.writeByte(GET_ID_BLOCK);
-   
-                  writeHeader(mi, dos);
-   
-                  int size = ((Integer)mi.getArguments()[0]).intValue();
-   
-                  dos.writeInt(size);
-   
-                  dos.flush();
-   
-                  if (trace) { log.trace("wrote getIdBlock()"); }
-               }           
                else if ("cancelDeliveries".equals(methodName) && mi.getArguments() != null)
                {
-                  dos.writeByte(CANCEL_DELIVERIES);
+                  dos.writeByte(CANCEL_LIST);
    
                   writeHeader(mi, dos);
    
@@ -310,7 +300,10 @@
                   while (iter.hasNext())
                   {
                      Cancel cancel = (Cancel)iter.next();
-                     cancel.write(dos);
+                     
+                     dos.writeLong(cancel.getDeliveryId());
+                     
+                     dos.writeInt(cancel.getDeliveryCount());
                   }
    
                   dos.flush();
@@ -353,6 +346,35 @@
    
                   if (trace) { log.trace("wrote confirmDelivery()"); }
                }
+               else if ("sendTransaction".equals(methodName))
+               {
+                  dos.writeByte(SEND_TRANSACTION);
+   
+                  writeHeader(mi, dos);
+   
+                  TransactionRequest request = (TransactionRequest)mi.getArguments()[0];
+   
+                  request.write(dos);
+   
+                  dos.flush();
+   
+                  if (trace) { log.trace("wrote getMessageNow()"); }
+               }
+               else if ("getIdBlock".equals(methodName))
+               {
+                  dos.writeByte(GET_ID_BLOCK);
+   
+                  writeHeader(mi, dos);
+   
+                  int size = ((Integer)mi.getArguments()[0]).intValue();
+   
+                  dos.writeInt(size);
+   
+                  dos.flush();
+   
+                  if (trace) { log.trace("wrote getIdBlock()"); }
+               }           
+               
                else
                {
                   dos.write(SERIALIZED);
@@ -669,11 +691,11 @@
                   new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
                                         new MessagingMarshallable(version, mi), null, null, null);
    
-               if (trace) { log.trace("read acknowledge()"); }
+               if (trace) { log.trace("read acknowledgeDelivery()"); }
    
                return request;
             }
-            case ACKNOWLEDGE_BATCH:
+            case ACKNOWLEDGE_LIST:
             {
                MethodInvocation mi = readHeader(dis);
                            
@@ -696,24 +718,46 @@
                   new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
                                         new MessagingMarshallable(version, mi), null, null, null);
    
-               if (trace) { log.trace("read acknowledge()"); }
+               if (trace) { log.trace("read acknowledgeDeliveries()"); }
    
                return request;
             }
-            case CANCEL_DELIVERIES:
+            case CANCEL:
             {
                MethodInvocation mi = readHeader(dis);
+               
+               long deliveryId = dis.readLong();
+               
+               int deliveryCount = dis.readInt();
+               
+               Object[] args = new Object[] {new DefaultCancel(deliveryId, deliveryCount)};
    
+               mi.setArguments(args);
+   
+               InvocationRequest request =
+                  new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
+                                        new MessagingMarshallable(version, mi), null, null, null);
+   
+               if (trace) { log.trace("read cancelDelivery()"); }
+   
+               return request;
+            }
+            case CANCEL_LIST:
+            {
+               MethodInvocation mi = readHeader(dis);
+   
                int size = dis.readInt();
    
                List acks = new ArrayList(size);
    
                for (int i = 0; i < size; i++)
-               {
-                  Cancel cancel = new Cancel();
+               {                  
+                  long deliveryId = dis.readLong();
                   
-                  cancel.read(dis);
+                  int deliveryCount = dis.readInt();
                   
+                  DefaultCancel cancel = new DefaultCancel(deliveryId, deliveryCount);
+                                    
                   acks.add(cancel);
                }
    

Modified: trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -25,6 +25,7 @@
 import java.io.DataOutputStream;
 import java.util.ArrayList;
 import java.util.Collection;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
@@ -139,7 +140,7 @@
       }
       else
       {
-         return sessionStatesMap.values();
+         return sessionStatesMap == null ? Collections.emptySet() : sessionStatesMap.values();
       }
    }   
    

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/tests/build.xml	2006-12-15 21:28:18 UTC (rev 1802)
@@ -759,7 +759,7 @@
                <include name="**/jms/clustering/*Test.class"/>
                 <include name="org/jboss/test/messaging/util/ServerManagementTest.class"/>
                -->
-               <include name="**/jms/clustering/HATest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -894,6 +894,8 @@
             count++;
                   
             TextMessage tm = (TextMessage)m;
+            
+            log.trace("Got message: " + tm.getText());            
                       
             // Receive first three messages then recover() session
             // Only last message should be redelivered

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ConnectionConsumerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ConnectionConsumerTest.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ConnectionConsumerTest.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -239,6 +239,84 @@
          if (connConsumer != null) connProducer.close();
       }
    }
+   
+   
+   
+   public void testRedeliveryTransactedDifferentConnection() throws Exception
+   {
+      if (ServerManagement.isRemote()) return;
+      
+      Connection connConnectionConsumer = null;
+      
+      Connection connConsumer = null;
+      
+      Connection connProducer = null;
+      
+      try
+      {
+         connConsumer = cf.createConnection();        
+         
+         connConsumer.start();
+                  
+         Session sessCons = connConsumer.createSession(true, Session.SESSION_TRANSACTED);
+         
+         RedelMessageListener listener = new RedelMessageListener(sessCons);
+         
+         sessCons.setMessageListener(listener);
+         
+         ServerSessionPool pool = new MockServerSessionPool(sessCons);
+         
+         connConnectionConsumer = cf.createConnection();
+         
+         connConnectionConsumer.start();
+         
+         JBossConnectionConsumer cc = (JBossConnectionConsumer)connConnectionConsumer.createConnectionConsumer(queue, null, pool, 1);         
+         
+         log.trace("Started connection consumer");
+         
+         connProducer = cf.createConnection();
+            
+         Session sessProd = connProducer.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer prod = sessProd.createProducer(queue);
+            
+         TextMessage m1 = sessProd.createTextMessage("a");
+         TextMessage m2 = sessProd.createTextMessage("b");
+         TextMessage m3 = sessProd.createTextMessage("c");
+         prod.send(m1);
+         prod.send(m2);
+         prod.send(m3);
+         
+         
+         log.trace("Sent messages");
+         
+         //Wait for messages
+         
+         listener.waitForLatch(10000);                  
+         
+         if (listener.failed)
+         {
+            fail ("Didn't receive correct messages");
+         }
+         
+         cc.close();
+         
+         log.trace("Closed connection consumer");
+         
+         connProducer.close();
+         connProducer = null;
+         connConsumer.close();
+         connConsumer = null;
+         connConnectionConsumer.close();
+         connConnectionConsumer = null;
+    
+      }
+      finally 
+      {
+         if (connConsumer != null) connConsumer.close();
+         if (connConsumer != null) connProducer.close();
+         if (connConnectionConsumer != null) connConnectionConsumer.close();
+      }
+   }
 
    public void testCloseWhileProcessing() throws Exception
    {

Modified: trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-15 17:49:28 UTC (rev 1801)
+++ trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-15 21:28:18 UTC (rev 1802)
@@ -48,6 +48,7 @@
 import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.ClientDelivery;
 import org.jboss.jms.server.endpoint.DefaultAck;
+import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.server.remoting.JMSWireFormat;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
@@ -93,10 +94,12 @@
    
    protected Method sendMethod;
    
-   protected Method acknowledgeMethod;
+   protected Method acknowledgeDeliveryMethod;
    
-   protected Method acknowledgeBatchMethod;
+   protected Method acknowledgeDeliveriesMethod;
    
+   protected Method cancelDeliveryMethod;
+   
    protected Method cancelDeliveriesMethod;
    
    //Consumer
@@ -135,10 +138,12 @@
       
       sendMethod = sessionDelegate.getMethod("send", new Class[] { JBossMessage.class });
        
-      acknowledgeMethod = sessionDelegate.getMethod("acknowledge", new Class[] { Ack.class });
+      acknowledgeDeliveryMethod = sessionDelegate.getMethod("acknowledgeDelivery", new Class[] { Ack.class });
       
-      acknowledgeBatchMethod = sessionDelegate.getMethod("acknowledgeBatch", new Class[] { java.util.List.class });
+      acknowledgeDeliveriesMethod = sessionDelegate.getMethod("acknowledgeDeliveries", new Class[] { java.util.List.class });
       
+      cancelDeliveryMethod = sessionDelegate.getMethod("cancelDelivery", new Class[] { Cancel.class });
+            
       cancelDeliveriesMethod = sessionDelegate.getMethod("cancelDeliveries", new Class[] { java.util.List.class });
       
       //TODO - this isn't complete - there are other methods to test
@@ -161,16 +166,26 @@
    
    //Session
    
-   public void testAcknowledge() throws Exception
+   public void testAcknowledgeDelivery() throws Exception
    {
-      wf.testAcknowledge();
+      wf.testAcknowledgeDelivery();
    }
    
-   public void testAcknowledgeBatch() throws Exception
+   public void testAcknowledgeDeliveries() throws Exception
    {
-      wf.testAcknowledgeBatch();
+      wf.testAcknowledgeDeliveries();
    }
    
+   public void testCancelDelivery() throws Exception
+   {
+      wf.testCancelDelivery();
+   }
+   
+   public void testCancelDeliveries() throws Exception
+   {
+      wf.testCancelDeliveries();
+   }
+   
    public void testSend() throws Exception
    {
       wf.testSend();
@@ -183,10 +198,6 @@
       wf.testMore();
    }
    
-   public void testCancelDeliveries() throws Exception
-   {
-      wf.testCancelDeliveries();
-   }
    
    //Connection
    
@@ -260,13 +271,13 @@
     */
    class TestWireFormat extends JMSWireFormat
    {      
-      public void testAcknowledge() throws Exception
+      public void testAcknowledgeDelivery() throws Exception
       {
          long methodHash = 62365354;
          
          int objectId = 54321;
          
-         MethodInvocation mi = new MethodInvocation(null, methodHash, acknowledgeMethod, acknowledgeMethod, null);
+         MethodInvocation mi = new MethodInvocation(null, methodHash, acknowledgeDeliveryMethod, acknowledgeDeliveryMethod, null);
          
          mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
          
@@ -347,13 +358,13 @@
          
       }
       
-      public void testAcknowledgeBatch() throws Exception
+      public void testAcknowledgeDeliveries() throws Exception
       {
          long methodHash = 62365354;
          
          int objectId = 54321;
          
-         MethodInvocation mi = new MethodInvocation(null, methodHash, acknowledgeBatchMethod, acknowledgeBatchMethod, null);
+         MethodInvocation mi = new MethodInvocation(null, methodHash, acknowledgeDeliveriesMethod, acknowledgeDeliveriesMethod, null);
          
          mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
          
@@ -396,7 +407,7 @@
          assertEquals(77, dis.readByte());
          
          //First byte should be ACKNOWLEDGE
-         assertEquals(JMSWireFormat.ACKNOWLEDGE_BATCH, dis.readByte());
+         assertEquals(JMSWireFormat.ACKNOWLEDGE_LIST, dis.readByte());
          
          //Next int should be objectId
          assertEquals(objectId, dis.readInt());
@@ -456,7 +467,104 @@
          
       }
       
+      public void testCancelDelivery() throws Exception
+      {
+         long methodHash = 6236354;
+         
+         int objectId = 543271;
+         
+         MethodInvocation mi = new MethodInvocation(null, methodHash, cancelDeliveryMethod, cancelDeliveryMethod, null);
+         
+         mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
+         
+         long deliveryID = 765;
+         
+         int deliveryCount = 12;
+         
+         Cancel cancel = new DefaultCancel(deliveryID, deliveryCount);
+         
+         Object[] args = new Object[] { cancel };
+         
+         mi.setArguments(args);
+         
+         MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi);
+         
+         InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null);
+         
+         ByteArrayOutputStream bos = new ByteArrayOutputStream();
+         
+         OutputStream oos = new DataOutputStream(bos);
+                  
+         wf.write(ir, oos);
+         
+         oos.flush();
+         
+         byte[] bytes = bos.toByteArray();
+         
+         ByteArrayInputStream bis = new ByteArrayInputStream(bytes);
+                  
+         DataInputStream dis = new DataInputStream(bis); 
+                 
+         //Check the bytes
+         
+         //First byte should be version
+         assertEquals(77, dis.readByte());
+         
+         //First byte should be CANCEL
+         assertEquals(JMSWireFormat.CANCEL, dis.readByte());
+         
+         //Next int should be objectId
+         assertEquals(objectId, dis.readInt());
+         
+         //Next long should be methodHash
+         assertEquals(methodHash, dis.readLong());
+         
+         //Next should be the deliveryid
+         long l = dis.readLong();
+         
+         //Then delivery count
+         int count = dis.readInt();
+         
+         assertEquals(deliveryID, l);
+         
+         assertEquals(deliveryCount, count);
+
+         //Now eos
+         try
+         {
+            dis.readByte();
+            fail("End of stream expected");
+         }
+         catch (EOFException e)
+         {
+            //Ok
+         }
+         
+         bis.reset();
+         
+         InputStream ois = new DataInputStream(bis);
+         
+         InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
+         
+         mm = (MessagingMarshallable)ir2.getParameter();
+         
+         assertEquals(77, mm.getVersion());
+         
+         MethodInvocation mi2 = (MethodInvocation)mm.getLoad();
+         
+         assertEquals(methodHash, mi2.getMethodHash());
+         
+         assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue());
+         
+         Cancel l2 = (Cancel)mi2.getArguments()[0];
+         
+         assertEquals(deliveryID, l2.getDeliveryId());
+         
+         assertEquals(deliveryCount, l2.getDeliveryCount());
+         
+      }
       
+      
       /*
        * Test that general serializable invocation requests are marshalled correctky
        */
@@ -729,7 +837,7 @@
          
          MessageProxy proxy = JBossMessage.createThinDelegate(deliveryId, m, deliveryCount);
                      
-         DeliveryInfo info = new DeliveryInfo(proxy, 76762, 98982);
+         DeliveryInfo info = new DeliveryInfo(proxy, 76762, 98982, null);
          
          int sessionId = 8787;
          
@@ -862,8 +970,8 @@
          
          List cancels = new ArrayList();
          
-         Cancel cancel1 = new Cancel(65654, 43);
-         Cancel cancel2 = new Cancel(65765, 2);
+         DefaultCancel cancel1 = new DefaultCancel(65654, 43);
+         DefaultCancel cancel2 = new DefaultCancel(65765, 2);
          cancels.add(cancel1);
          cancels.add(cancel2);
          
@@ -897,7 +1005,7 @@
          assertEquals(77, dis.readByte());
          
          //Next byte should be CANCEL_MESSAGES
-         assertEquals(JMSWireFormat.CANCEL_DELIVERIES, dis.readByte());
+         assertEquals(JMSWireFormat.CANCEL_LIST, dis.readByte());
          
          //Next int should be objectId
          assertEquals(objectId, dis.readInt());
@@ -912,14 +1020,14 @@
          assertEquals(2, size);
          
          //then the AckInfos
-         Cancel rcancel1 = new Cancel();
+         long deliveryId = dis.readLong();
+         int deliveryCount = dis.readInt();
+         DefaultCancel rcancel1 = new DefaultCancel(deliveryId, deliveryCount);
          
-         Cancel rcancel2 = new Cancel();
-         
-         rcancel1.read(dis);
-         
-         rcancel2.read(dis);
-         
+         deliveryId = dis.readLong();
+         deliveryCount = dis.readInt();
+         DefaultCancel rcancel2 = new DefaultCancel(deliveryId, deliveryCount);
+
          assertEquals(cancel1.getDeliveryCount(), rcancel1.getDeliveryCount());
          
          assertEquals(cancel1.getDeliveryId(), cancel1.getDeliveryId());
@@ -961,8 +1069,8 @@
         
          assertEquals(2, list.size());
          
-         Cancel xack1 = (Cancel)list.get(0);
-         Cancel xack2 = (Cancel)list.get(1);
+         DefaultCancel xack1 = (DefaultCancel)list.get(0);
+         DefaultCancel xack2 = (DefaultCancel)list.get(1);
          
          assertEquals(cancel1.getDeliveryId(), xack1.getDeliveryId());
          



From mandersen at jboss.com  Fri Dec 15 16:30:25 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 15 Dec 2006 16:30:25 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/lib  ...
Message-ID: <E1GvKdN-0007BC-CW@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/15 16:30:25

  Modified:    seam-gen/lib  hibernate-tools.jar
  Log:
  comments in generated pojo clean up
  
  Revision  Changes    Path
  1.6       +348 -325  jboss-seam/seam-gen/lib/hibernate-tools.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 17:00:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 17:00:04 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1803 -
	trunk/src/main/org/jboss/jms/server/endpoint
Message-ID: <E1GvL64-0007d9-2h@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-15 17:00:01 -0500 (Fri, 15 Dec 2006)
New Revision: 1803

Added:
   trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
Log:
Missing file



Added: trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-15 21:28:18 UTC (rev 1802)
+++ trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-15 22:00:01 UTC (rev 1803)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.server.endpoint;
+
+/**
+ * A Cancel
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public interface Cancel
+{
+   long getDeliveryId();
+   
+   int getDeliveryCount();
+}



From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 19:16:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 19:16:34 -0500
Subject: [jboss-cvs] JBossBlog SVN: r38 - in trunk: . blog-core
	blog-core/src/etc/META-INF blog-core/src/etc/conf/hibernate
	blog-core/src/java/org/jboss/blog/model
	blog-core/src/java/org/jboss/blog/model/impl
	blog-core/src/java/org/jboss/blog/service/model/rome
	blog-core/src/java/org/jboss/blog/service/permissions
	blog-core/src/java/org/jboss/blog/service/permissions/acl
	blog-core/src/java/org/jboss/blog/service/permissions/model
	blog-core/src/java/org/jboss/blog/service/store
	blog-core/src/java/org/jboss/blog/service/store/hibernate
	blog-core/src/java/org/jboss/blog/service/store/model
	blog-core/src/java/org/jboss/blog/ui blog-core/src/web/views
Message-ID: <E1GvNEA-0001lc-Kn@committer01.frg.pub.inap.atl.jboss.com>

Author: adamw
Date: 2006-12-15 19:16:16 -0500 (Fri, 15 Dec 2006)
New Revision: 38

Added:
   trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogAuthor.java
   trunk/blog-core/src/java/org/jboss/blog/model/BlogAuthor.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogAuthorImpl.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogAuthor.java
   trunk/blog-core/src/java/org/jboss/blog/service/permissions/model/
   trunk/blog-core/src/java/org/jboss/blog/service/permissions/model/PortalUserBlogAuthor.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/EmptyPortalUser.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.java
Modified:
   trunk/blog-core/build.xml
   trunk/blog-core/src/etc/META-INF/jboss-service.xml
   trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml
   trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogModelImpl.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogModel.java
   trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java
   trunk/blog-core/src/java/org/jboss/blog/service/permissions/BlogPermissionsService.java
   trunk/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java
   trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java
   trunk/blog-core/src/java/org/jboss/blog/ui/BlogEdit.java
   trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
   trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java
   trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java
   trunk/blog-core/src/web/views/blog_mod.xhtml
   trunk/blog-core/src/web/views/blog_view.xhtml
   trunk/blog-core/src/web/views/post_mod.xhtml
   trunk/blog-core/src/web/views/post_view.xhtml
   trunk/blog-core/src/web/views/view.xhtml
   trunk/jbossblog.iws
Log:
http://jira.jboss.com/jira/browse/JBBLOG-26

Modified: trunk/blog-core/build.xml
===================================================================
--- trunk/blog-core/build.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/build.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -40,6 +40,9 @@
 
     <fileset id="log4j.jar" dir="../lib/xdoclet"><include name="log4j.jar"/></fileset>
 
+    <fileset id="jboss.portal.identity.jars" dir="../lib/jboss-portal">
+        <include name="**/portal-identity-lib.jar"/></fileset>
+
     <!-- Classpath for building the application: includes all dependency jars -->
     <path id="base.jars">
         <fileset refid="rome.jars" />
@@ -118,6 +121,7 @@
         <!-- Copying dependency jars -->
         <copy todir="${dist.lib.dir}"><fileset refid="rome.jars"/></copy>
         <copy todir="${dist.lib.dir}"><fileset refid="jboss.jaae.jars"/></copy>
+        <copy todir="${dist.lib.dir}"><fileset refid="jboss.portal.identity.jars"/></copy>
         <antcall target="copy-libs-for-servlet" />
     </target>
 

Modified: trunk/blog-core/src/etc/META-INF/jboss-service.xml
===================================================================
--- trunk/blog-core/src/etc/META-INF/jboss-service.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/etc/META-INF/jboss-service.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -68,6 +68,8 @@
     <mbean code="org.jboss.blog.service.permissions.acl.AclBlogPermissionsService"
            name="blog:service=Permissions"
            xmbean-dd="org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.xml">
+        <depends optional-attribute-name="UserModule"
+                 proxy-type="attribute">portal:service=Module,type=User</depends>
     </mbean>
     <!-- JAAE service -->
     <mbean code="org.jboss.security.acl.AclKernelFactory"
@@ -80,6 +82,8 @@
     <mbean code="org.jboss.blog.service.store.hibernate.HibernateBlogStoreService"
            name="blog:service=Store"
            xmbean-dd="org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.xml" >
+        <depends optional-attribute-name="PermissionsService"
+                 proxy-type="attribute">blog:service=Permissions</depends>
         <depends>jboss.jca:name=BlogDS,service=DataSourceBinding</depends>
     </mbean>
 </server>
\ No newline at end of file

Modified: trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml
===================================================================
--- trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -36,10 +36,12 @@
         <mapping resource="org/jboss/blog/service/store/hibernate/HBlogModelPost.hbm.xml"/>
         <mapping resource="org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml"/>
         <mapping resource="org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml"/>
+        <mapping resource="org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml"/>
 
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogModel" usage="read-write" />
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogModelPost" usage="read-write" />
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogPost" usage="read-write" />
         <class-cache class="org.jboss.blog.service.store.hibernate.HBlogComment" usage="read-write" />
+        <class-cache class="org.jboss.blog.service.store.hibernate.HPortalBlogAuthor" usage="read-write" />
     </session-factory>
 </hibernate-configuration>
\ No newline at end of file

Added: trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogAuthor.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogAuthor.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/AbstractBlogAuthor.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,24 @@
+package org.jboss.blog.model;
+
+import org.jboss.blog.tools.BlogTools;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public abstract class AbstractBlogAuthor implements BlogAuthor {
+    private String fullName;
+
+    public String getFullName() {
+        if (fullName == null) {
+            if (BlogTools.isEmpty(getGivenName())) {
+                fullName = getFamilyName();
+            } else if (BlogTools.isEmpty(getFamilyName())) {
+                fullName = getGivenName();
+            } else {
+                fullName = getGivenName() + " " + getFamilyName();
+            }
+        }
+
+        return fullName; 
+    }
+}

Added: trunk/blog-core/src/java/org/jboss/blog/model/BlogAuthor.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogAuthor.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogAuthor.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,12 @@
+package org.jboss.blog.model;
+
+/**
+ * An interface which represents an author of blog posts or comments.
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public interface BlogAuthor {
+    public String getUserName();
+    public String getGivenName();
+    public String getFamilyName();
+    public String getFullName();
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/BlogItem.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -7,7 +7,7 @@
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
 public interface BlogItem extends Comparable{
-    public String getAuthor();
+    public BlogAuthor getAuthor();
     public String getTitle();
     public String getDescription();
     public Date getCreated();

Added: trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogAuthorImpl.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogAuthorImpl.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogAuthorImpl.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,31 @@
+package org.jboss.blog.model.impl;
+
+import org.jboss.blog.model.AbstractBlogAuthor;
+
+/**
+ * A java beans implementation of the blog author interface.
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class BlogAuthorImpl extends AbstractBlogAuthor {
+    private String userName;
+    private String givenName;
+    private String familyName;
+
+    public BlogAuthorImpl(String userName, String givenName, String familyName) {
+        this.userName = userName;
+        this.givenName = givenName;
+        this.familyName = familyName;
+    }
+
+    public String getUserName() {
+        return userName;
+    }
+
+    public String getGivenName() {
+        return givenName;
+    }
+
+    public String getFamilyName() {
+        return familyName;
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -1,6 +1,7 @@
 package org.jboss.blog.model.impl;
 
 import org.jboss.blog.model.AbstractBlogComment;
+import org.jboss.blog.model.BlogAuthor;
 
 import java.util.Date;
 
@@ -9,13 +10,13 @@
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
 public class BlogCommentImpl extends AbstractBlogComment {
-    private String author;
+    private BlogAuthor author;
     private String title;
     private String description;
     private Date created;
     private String link;
 
-    public BlogCommentImpl(String author, String title,
+    public BlogCommentImpl(BlogAuthor author, String title,
                            String description, Date created,
                            String link) {
         this.author = author;
@@ -25,7 +26,7 @@
         this.link = link;
     }
 
-    public String getAuthor() {
+    public BlogAuthor getAuthor() {
         return author;
     }
 

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogModelImpl.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogModelImpl.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogModelImpl.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -1,6 +1,7 @@
 package org.jboss.blog.model.impl;
 
 import org.jboss.blog.model.AbstractBlogModel;
+import org.jboss.blog.model.BlogAuthor;
 
 import java.util.Date;
 import java.util.Set;
@@ -11,7 +12,7 @@
  * @author Adam Warski (adamw at aster.pl)
  */
 public class BlogModelImpl extends AbstractBlogModel {
-    private String author;
+    private BlogAuthor author;
     private String title;
     private String description;
     private String link;
@@ -19,7 +20,7 @@
     private List posts;
     private Set categories;
 
-    public BlogModelImpl(String author, String title, String description,
+    public BlogModelImpl(BlogAuthor author, String title, String description,
                          String link, Date created, List posts,
                          Set categories) {
         this.author = author;
@@ -31,7 +32,7 @@
         this.categories = categories;
     }
 
-    public String getAuthor() {
+    public BlogAuthor getAuthor() {
         return author;
     }
 

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -1,6 +1,7 @@
 package org.jboss.blog.model.impl;
 
 import org.jboss.blog.model.AbstractBlogPost;
+import org.jboss.blog.model.BlogAuthor;
 
 import java.util.Date;
 import java.util.List;
@@ -11,7 +12,7 @@
  * @author Adam Warski (adamw at aster.pl)
  */
 public class BlogPostImpl extends AbstractBlogPost {
-    private String author;
+    private BlogAuthor author;
     private String title;
     private String description;
     private Date created;
@@ -21,7 +22,7 @@
     private String commentLink;
     private List comments;
 
-    public BlogPostImpl(String author, String title, String description,
+    public BlogPostImpl(BlogAuthor author, String title, String description,
                         Date created, String link, String guid,
                         Set categories, String commentLink, List comments) {
         this.author = author;
@@ -35,7 +36,7 @@
         this.comments = comments;
     }
 
-    public String getAuthor() {
+    public BlogAuthor getAuthor() {
         return author;
     }
 

Added: trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogAuthor.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogAuthor.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogAuthor.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,10 @@
+package org.jboss.blog.model.impl;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class EmptyBlogAuthor extends BlogAuthorImpl {
+    public EmptyBlogAuthor() {
+        super("", "", "");
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -7,6 +7,6 @@
  */
 public class EmptyBlogComment extends BlogCommentImpl {
     public EmptyBlogComment() {
-        super("", "", "", new Date(), "");
+        super(new EmptyBlogAuthor(), "", "", new Date(), "");
     }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogModel.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogModel.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogModel.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -7,6 +7,6 @@
  */
 public class EmptyBlogModel extends BlogModelImpl {
     public EmptyBlogModel() {
-        super("", "", "", "", new Date(), new ArrayList(), new HashSet());
+        super(new EmptyBlogAuthor(), "", "", "", new Date(), new ArrayList(), new HashSet());
     }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -8,6 +8,6 @@
  */
 public class EmptyBlogPost extends BlogPostImpl {
     public EmptyBlogPost() {
-        super("", "", "", new Date(), "", "", new HashSet(), null, null);
+        super(new EmptyBlogAuthor(), "", "", new Date(), "", "", new HashSet(), null, null);
     }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -2,6 +2,8 @@
 
 import org.jboss.blog.model.impl.BlogPostImpl;
 import org.jboss.blog.model.impl.BlogCommentImpl;
+import org.jboss.blog.model.impl.BlogAuthorImpl;
+import org.jboss.blog.model.BlogAuthor;
 import org.jboss.blog.tools.BlogTools;
 
 import java.util.*;
@@ -19,7 +21,7 @@
     private boolean commentsInitialized;
     private List comments;
 
-    public RomeBlogPost(String author, String title, String description, Date created,
+    public RomeBlogPost(BlogAuthor author, String title, String description, Date created,
                         String link, String guid, Set categories, String commentLink) {
         super(author, title, description, created, link, guid, categories, commentLink, null);
     }
@@ -44,8 +46,9 @@
                     SyndEntry post = (SyndEntry) iter.next();
 
                     String author = post.getAuthor();
+                    author = BlogTools.isEmpty(author) ? defaultAuthor : author;
                     comments.add(new BlogCommentImpl(
-                            BlogTools.isEmpty(author) ? defaultAuthor : author,
+                            new BlogAuthorImpl(author, author, ""),
                             post.getTitle(), post.getDescription().getValue(),
                             post.getPublishedDate(), post.getLink()));
                 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -2,8 +2,8 @@
 
 import org.jboss.blog.model.BlogModel;
 import org.jboss.blog.model.BlogModelDoesNotExistException;
-import org.jboss.blog.model.impl.BlogPostImpl;
 import org.jboss.blog.model.impl.BlogModelImpl;
+import org.jboss.blog.model.impl.BlogAuthorImpl;
 import org.jboss.blog.BlogName;
 import org.jboss.blog.service.AbstractBlogService;
 import org.jboss.blog.service.model.BlogModelService;
@@ -82,8 +82,9 @@
             }
 
             String author = post.getAuthor();
+            author = BlogTools.isEmpty(author) ? defaultAuthor : author;
             posts.add(new RomeBlogPost(
-                    BlogTools.isEmpty(author) ? defaultAuthor : author,
+                    new BlogAuthorImpl(author, author, ""),
                     post.getTitle(), post.getDescription().getValue(),
                     post.getPublishedDate(), post.getLink(),
                     post.getUri(),
@@ -91,8 +92,8 @@
                     commentsRss));
         }
 
-        return new BlogModelImpl(inFeed.getAuthor(), inFeed.getTitle(),
-                inFeed.getDescription(), inFeed.getLink(),
+        return new BlogModelImpl(new BlogAuthorImpl(inFeed.getAuthor(), inFeed.getAuthor(), ""),
+                inFeed.getTitle(), inFeed.getDescription(), inFeed.getLink(),
                 inFeed.getPublishedDate(), Collections.unmodifiableList(posts),
                 Collections.unmodifiableSet(getStringCategories(inFeed.getCategories())));
     }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/permissions/BlogPermissionsService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/permissions/BlogPermissionsService.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/permissions/BlogPermissionsService.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -1,6 +1,6 @@
 package org.jboss.blog.service.permissions;
 
-import org.jboss.blog.service.permissions.SecurityContext;
+import org.jboss.blog.model.BlogAuthor;
 
 /**
  * A service which enables to check, if a given user can gain access to given
@@ -14,4 +14,14 @@
      * @return True iff the given user can access the given context.
      */
     public boolean hasAccess(SecurityContext context);
+
+    /**
+     * Gets a blog author represented by the given data. If it contains
+     * request information, the currently logged-in user will be returned.
+     * @param data Request data from which to read the blog author
+     * information.
+     * @return A {@link BlogAuthor} representation of the user represented
+     * by the given data, or null, if no such user exists.
+     */
+    public BlogAuthor getBlogAuthor(Object data);
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -7,7 +7,14 @@
 
 import org.jboss.blog.service.permissions.BlogPermissionsService;
 import org.jboss.blog.service.permissions.SecurityContext;
+import org.jboss.blog.service.permissions.model.PortalUserBlogAuthor;
+import org.jboss.blog.model.BlogAuthor;
+import org.jboss.blog.model.impl.EmptyBlogAuthor;
+import org.jboss.portal.identity.UserModule;
+import org.jboss.portal.identity.IdentityException;
 
+import javax.portlet.PortletRequest;
+
 /**
  * @author <a href="mailto:sohil.shah at jboss.com">Sohil Shah</a>
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
@@ -16,16 +23,34 @@
  * @jboss.xmbean
  */
 public class AclBlogPermissionsService implements BlogPermissionsService {
+    private UserModule um;
+
     /**
+     * @jmx.managed-attribute
+     * @return User module from portal.
+     */
+    public UserModule getUserModule() {
+        return um;
+    }
+
+    /**
+     * @param um New user module to set.
+     * @jmx.managed-attribute
+     */
+    public void setUserModule(UserModule um) {
+        this.um = um;
+    }
+
+    /**
      * @jmx.managed-operation
      * @jmx.managed-parameter type="org.jboss.blog.service.permissions.SecurityContext"
      */
     public boolean hasAccess(SecurityContext context)
     {
-        boolean hasAccess = true;     
+        boolean hasAccess = true;
         try
         {
-	        //setup the engine identity based on identity provided in the security context
+            //setup the engine identity based on identity provided in the security context
             if(context.getIdentity()!=null)
             {
                 User user = User.getUser(((org.jboss.portal.identity.User)context.getIdentity()).getUserName());
@@ -37,24 +62,24 @@
                 //set an anonymous user
                 UserThreadLocal.setUser(new User());
             }
-	        
-	        if(context instanceof JSFActionContext)
-	        {
-	            JSFActionContext securityContext = (JSFActionContext)context;
-	            
-		        //send this to the engine for access control decision
-		        AclProcessor.getInstance().processJSFActionAccess(
-		        securityContext.getFacesContext(),
-		        securityContext.getManagedBean(),
-		        securityContext.getBusinessAction());
-	        }
-	        else if(context instanceof JSFUIContext)
-	        {
-	            JSFUIContext securityContext = (JSFUIContext)context;
-	            
-		        //send this to the engine for access control decision
-		        AclProcessor.getInstance().processFragmentAccess(securityContext.getFragment(),securityContext.getContextData());		        
-	        }
+
+            if(context instanceof JSFActionContext)
+            {
+                JSFActionContext securityContext = (JSFActionContext)context;
+
+                //send this to the engine for access control decision
+                AclProcessor.getInstance().processJSFActionAccess(
+                        securityContext.getFacesContext(),
+                        securityContext.getManagedBean(),
+                        securityContext.getBusinessAction());
+            }
+            else if(context instanceof JSFUIContext)
+            {
+                JSFUIContext securityContext = (JSFUIContext)context;
+
+                //send this to the engine for access control decision
+                AclProcessor.getInstance().processFragmentAccess(securityContext.getFragment(),securityContext.getContextData());
+            }
         }
         catch(AccessDenied ade)
         {
@@ -64,9 +89,28 @@
         {
             throw new RuntimeException(e);
         }
-        
+
         return hasAccess;
     }
-    
-    
+
+    /**
+     * @jmx.managed-operation
+     * @jmx.managed-parameter type="java.lang.Object"
+     */
+    public BlogAuthor getBlogAuthor(Object data) {
+        try {
+            if (data instanceof PortletRequest) {
+                return new PortalUserBlogAuthor(um.findUserByUserName(
+                        ((PortletRequest) data).getRemoteUser()));
+            }
+
+            if (data instanceof Long) {
+                return new PortalUserBlogAuthor(um.findUserById(data));
+            }
+        } catch (IdentityException e) {
+            return new EmptyBlogAuthor();
+        }
+
+        throw new IllegalArgumentException("Invalid data from which blog author was to be read.");
+    }
 }

Added: trunk/blog-core/src/java/org/jboss/blog/service/permissions/model/PortalUserBlogAuthor.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/permissions/model/PortalUserBlogAuthor.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/permissions/model/PortalUserBlogAuthor.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,31 @@
+package org.jboss.blog.service.permissions.model;
+
+import org.jboss.blog.model.AbstractBlogAuthor;
+import org.jboss.portal.identity.User;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class PortalUserBlogAuthor extends AbstractBlogAuthor {
+    private User user;
+
+    public PortalUserBlogAuthor(User user) {
+        this.user = user;
+    }
+
+    public String getUserName() {
+        return user.getUserName();
+    }
+
+    public String getGivenName() {
+        return user.getGivenName();
+    }
+
+    public String getFamilyName() {
+        return user.getFamilyName();
+    }
+
+    public User getUser() {
+        return user;
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -2,6 +2,7 @@
 
 import org.jboss.blog.BlogName;
 import org.jboss.blog.model.BlogModelDoesNotExistException;
+import org.jboss.blog.model.BlogAuthor;
 import org.jboss.blog.service.store.model.*;
 
 import java.util.List;
@@ -124,4 +125,14 @@
      * blog post and saved.
      */
     public ModifiableBlogComment newBlogComment();
+
+    /**
+     * Creates a new blog author. The author is created basing on
+     * request data.
+     * @param request Object from which request data can be read.
+     * @return The current author, corresponding to the logged-in
+     * user (as determined with the permissions service), or null,
+     * if no user is logged in.
+     */
+    public BlogAuthor newBlogAuthor(Object request);
 }

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/EmptyPortalUser.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/EmptyPortalUser.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/EmptyPortalUser.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,116 @@
+package org.jboss.blog.service.store.hibernate;
+
+import org.jboss.portal.identity.User;
+import org.jboss.portal.identity.PropertyMap;
+
+import java.util.Date;
+import java.util.Locale;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class EmptyPortalUser implements User {
+    public Object getId() {
+        return null;
+    }
+
+    public boolean getEnabled() {
+        return false;
+    }
+
+    public void setEnabled(boolean b) {
+
+    }
+
+    public void updatePassword(String string) {
+
+    }
+
+    public boolean validatePassword(String string) {
+        return false;
+    }
+
+    public PropertyMap getProperties() {
+        return null;
+    }
+
+    public String getUserName() {
+        return null;
+    }
+
+    public String getGivenName() {
+        return null;
+    }
+
+    public void setGivenName(String string) {
+
+    }
+
+    public String getFamilyName() {
+        return null;
+    }
+
+    public void setFamilyName(String string) {
+
+    }
+
+    public String getRealEmail() {
+        return null;
+    }
+
+    public void setRealEmail(String string) {
+
+    }
+
+    public String getFakeEmail() {
+        return null;
+    }
+
+    public void setFakeEmail(String string) {
+
+    }
+
+    public Date getRegistrationDate() {
+        return null;
+    }
+
+    public boolean getViewRealEmail() {
+        return false;
+    }
+
+    public void setViewRealEmail(boolean b) {
+
+    }
+
+    public Locale getPreferredLocale() {
+        return null;
+    }
+
+    public void setPreferredLocale(Locale locale) {
+
+    }
+
+    public String getSignature() {
+        return null;
+    }
+
+    public void setSignature(String string) {
+
+    }
+
+    public Date getLastVisitDate() {
+        return null;
+    }
+
+    public void setLastVisitDate(Date date) {
+
+    }
+
+    public String getTheme() {
+        return null;
+    }
+
+    public void setTheme(String string) {
+
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -11,9 +11,9 @@
         </id>
 
         <many-to-one name="post" column="POST_ID" not-null="true" class="HBlogPost" />
-        
-        <property name="author" column="AUTHOR" not-null="true" />
 
+        <many-to-one name="author" column="AUTHOR" not-null="true" class="HPortalBlogAuthor" />
+
         <property name="created" column="CREATED" not-null="true" type="timestamp"
                   update="false" />
 

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -1,6 +1,7 @@
 package org.jboss.blog.service.store.hibernate;
 
 import org.jboss.blog.model.AbstractBlogComment;
+import org.jboss.blog.model.BlogAuthor;
 import org.jboss.blog.service.store.model.ModifiableBlogComment;
 
 import java.util.Date;
@@ -11,7 +12,7 @@
  */
 public class HBlogComment extends AbstractBlogComment implements ModifiableBlogComment {
     private Integer id;
-    private String author;
+    private BlogAuthor author;
     private String title;
     private String description;
     private Date created;
@@ -34,7 +35,8 @@
         this.id = id;
     }
 
-    public String getAuthor() {
+    public BlogAuthor getAuthor() {
+        getStoreService().castAndAssertBlogAuthor(author).setStoreService(getStoreService());
         return author;
     }
 
@@ -46,7 +48,7 @@
         this.post = post;
     }
 
-    public void setAuthor(String author) {
+    public void setAuthor(BlogAuthor author) {
         this.author = author;
     }
 
@@ -81,4 +83,8 @@
     public void setLink(String link) {
         this.link = link;
     }
+
+    public HibernateBlogStoreService getStoreService() {
+        return getPost().getStoreService();
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -17,7 +17,7 @@
             </component>
         </natural-id>
 
-        <property name="author" column="AUTHOR" not-null="true" />
+        <many-to-one name="author" column="AUTHOR" not-null="true" class="HPortalBlogAuthor" />
 
         <property name="created" column="CREATED" not-null="true" type="timestamp"
                   update="false" />

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -6,6 +6,7 @@
 import org.jboss.blog.model.AbstractBlogModel;
 import org.jboss.blog.model.BlogPost;
 import org.jboss.blog.model.BlogPostDoesNotExistException;
+import org.jboss.blog.model.BlogAuthor;
 import org.jboss.blog.BlogName;
 import org.jboss.blog.tools.BlogTools;
 
@@ -17,7 +18,7 @@
 public class HBlogModel extends AbstractBlogModel implements ModifiableBlogModel {
     private Integer id;
     private BlogName blogName;
-    private String author;
+    private BlogAuthor author;
     private String title;
     private String description;
     private String link;
@@ -55,11 +56,12 @@
         }
     }
 
-    public String getAuthor() {
+    public BlogAuthor getAuthor() {
+        getStoreService().castAndAssertBlogAuthor(author).setStoreService(getStoreService());
         return author;
     }
 
-    public void setAuthor(String author) {
+    public void setAuthor(BlogAuthor author) {
         this.author = author;
     }
 

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -10,7 +10,7 @@
             <generator class="native" />
         </id>
 
-        <property name="author" column="AUTHOR" not-null="true" />
+        <many-to-one name="author" column="AUTHOR" not-null="true" class="HPortalBlogAuthor" />
 
         <property name="created" column="CREATED" not-null="true" type="timestamp"
                   update="false" />

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -5,6 +5,7 @@
 import org.jboss.blog.model.AbstractBlogPost;
 import org.jboss.blog.model.BlogComment;
 import org.jboss.blog.model.BlogCommentDoesNotExistException;
+import org.jboss.blog.model.BlogAuthor;
 import org.jboss.blog.tools.BlogTools;
 
 import java.util.*;
@@ -15,7 +16,7 @@
  */
 public class HBlogPost extends AbstractBlogPost implements ModifiableBlogPost {
     private Integer id;
-    private String author;
+    private BlogAuthor author;
     private String title;
     private String description;
     private String link;
@@ -42,11 +43,12 @@
         this.id = id;
     }
 
-    public String getAuthor() {
+    public BlogAuthor getAuthor() {
+        getStoreService().castAndAssertBlogAuthor(author).setStoreService(getStoreService());
         return author;
     }
 
-    public void setAuthor(String author) {
+    public void setAuthor(BlogAuthor author) {
         this.author = author;
     }
 

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,15 @@
+<?xml version="1.0"?>
+<!DOCTYPE hibernate-mapping PUBLIC
+      "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
+          "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
+
+<hibernate-mapping package="org.jboss.blog.service.store.hibernate">
+    <class name="HPortalBlogAuthor"
+           table="BLOG_PORTAL_AUTHORS">
+        <id name="id" column="AUTHOR_ID">
+            <generator class="native" />
+        </id>
+
+        <property name="jbp_id" column="JBP_ID" not-null="true" />
+    </class>
+</hibernate-mapping>
\ No newline at end of file

Added: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -0,0 +1,73 @@
+package org.jboss.blog.service.store.hibernate;
+
+import org.jboss.blog.model.AbstractBlogAuthor;
+import org.jboss.blog.model.BlogAuthor;
+import org.jboss.blog.service.permissions.model.PortalUserBlogAuthor;
+import org.jboss.portal.identity.User;
+
+/**
+ * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
+ */
+public class HPortalBlogAuthor extends AbstractBlogAuthor {
+    private Integer id;
+    private Long jbp_id;
+
+    private boolean initDone;
+    private User user;
+    private HibernateBlogStoreService storeService;
+
+    private void initUser() {
+        BlogAuthor author = getStoreService().getPermissionsService().getBlogAuthor(jbp_id);
+
+        if (!(author instanceof PortalUserBlogAuthor)) {
+            user = new EmptyPortalUser();
+        } else {
+            user = ((PortalUserBlogAuthor) author).getUser();
+        }
+
+        initDone = true;
+    }
+
+    public String getUserName() {
+        if (!initDone) { initUser(); }
+        return user.getUserName();
+    }
+
+    public String getGivenName() {
+        if (!initDone) { initUser(); }
+        return user.getGivenName();
+    }
+
+    public String getFamilyName() {
+        if (!initDone) { initUser(); }
+        return user.getFamilyName();
+    }
+
+    //
+
+    public Long getJbp_id() {
+        return jbp_id;
+    }
+
+    public void setJbp_id(Long jbp_id) {
+        this.jbp_id = jbp_id;
+    }
+
+    public Integer getId() {
+        return id;
+    }
+
+    public void setId(Integer id) {
+        this.id = id;
+    }
+
+    //
+
+    public HibernateBlogStoreService getStoreService() {
+        return storeService;
+    }
+
+    public void setStoreService(HibernateBlogStoreService storeService) {
+        this.storeService = storeService;
+    }
+}

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -6,9 +6,12 @@
 import org.jboss.blog.service.store.model.BlogModelAlreadyExistsException;
 import org.jboss.blog.service.store.model.ModifiableBlogComment;
 import org.jboss.blog.service.AbstractBlogService;
+import org.jboss.blog.service.permissions.model.PortalUserBlogAuthor;
+import org.jboss.blog.service.permissions.BlogPermissionsService;
 import org.jboss.blog.BlogName;
 import org.jboss.blog.model.BlogModelDoesNotExistException;
 import org.jboss.blog.model.BlogCommentDoesNotExistException;
+import org.jboss.blog.model.BlogAuthor;
 import org.jboss.blog.tools.BlogTools;
 import org.hibernate.SessionFactory;
 import org.hibernate.cfg.Configuration;
@@ -48,6 +51,15 @@
         BlogTools.assertNotNull(blogName, "Blog name cannot be null.");
     }
 
+    HPortalBlogAuthor castAndAssertBlogAuthor(BlogAuthor author) {
+        BlogTools.assertNotNull(author, "Blog author cannot be null.");
+        if (!(author instanceof HPortalBlogAuthor)) {
+            throw new IllegalArgumentException("Author must be obtained from this store service.");
+        }
+
+        return (HPortalBlogAuthor) author;
+    }
+
     HBlogModel castAndAssertBlogModel(ModifiableBlogModel model) {
         BlogTools.assertNotNull(model, "Blog model cannot be null.");
         if (!(model instanceof HBlogModel)) {
@@ -175,7 +187,7 @@
         post.setStoreService(this);
 
         return post;
-    }    
+    }
 
     /**
      * @jmx.managed-operation
@@ -186,6 +198,36 @@
 
     /**
      * @jmx.managed-operation
+     * @jmx.managed-parameter type="java.lang.Object"
+     */
+    public BlogAuthor newBlogAuthor(Object request) {
+        BlogAuthor author = permissionsService.getBlogAuthor(request);
+
+        if (!(author instanceof PortalUserBlogAuthor)) {
+            throw new IllegalArgumentException("Invalid author!");
+        }
+
+        Object jbp_id = ((PortalUserBlogAuthor) author).getUser().getId();
+        HPortalBlogAuthor hpba = (HPortalBlogAuthor) sf.getCurrentSession()
+                .createQuery("from HPortalBlogAuthor as author where author.jbp_id = :id")
+                .setParameter("id", jbp_id)
+                .uniqueResult();
+
+        if (hpba != null) {
+            // Blog author already exists.
+            return hpba;
+        }
+
+        // Creating new blog author.
+        hpba = new HPortalBlogAuthor();
+        hpba.setJbp_id((Long) jbp_id);
+        sf.getCurrentSession().save(hpba);
+
+        return hpba;
+    }
+
+    /**
+     * @jmx.managed-operation
      * @jmx.managed-parameter type="org.jboss.blog.service.store.model.ModifiableBlogModel"
      */
     public void saveNewBlogModel(ModifiableBlogModel model) throws BlogModelAlreadyExistsException {
@@ -272,9 +314,9 @@
 
         // TODO Thread-unsafe checking
         if ((hpost.getId() == null) ||
-            ((Long) sf.getCurrentSession().createQuery("select count(*) from " +
-                    "HBlogModelPost as bmp where bmp.model = :model and bmp.post = :post")
-                    .setEntity("model", hmodel).setEntity("post", hpost).uniqueResult()).longValue() == 0) {
+                ((Long) sf.getCurrentSession().createQuery("select count(*) from " +
+                        "HBlogModelPost as bmp where bmp.model = :model and bmp.post = :post")
+                        .setEntity("model", hmodel).setEntity("post", hpost).uniqueResult()).longValue() == 0) {
 
             HBlogModelPost hbmp = new HBlogModelPost(hmodel, hpost);
             hmodel.getModelPosts().add(hbmp);
@@ -294,7 +336,7 @@
 
         HBlogModelPost hbmp = (HBlogModelPost) sf.getCurrentSession().createQuery(
                 "from HBlogModelPost as bmp where bmp.model = :model " +
-                "and bmp.post = :post").setEntity("model", hmodel)
+                        "and bmp.post = :post").setEntity("model", hmodel)
                 .setEntity("post", hpost).uniqueResult();
 
         if (hbmp == null) {
@@ -379,4 +421,24 @@
 
         return ret;
     }
+
+    //
+
+    private BlogPermissionsService permissionsService;
+
+    /**
+     * @jmx.managed-attribute
+     * @return Current permissions service.
+     */
+    public BlogPermissionsService getPermissionsService() {
+        return permissionsService;
+    }
+
+    /**
+     * @param permissionsService New permissions service to set.
+     * @jmx.managed-attribute
+     */
+    public void setPermissionsService(BlogPermissionsService permissionsService) {
+        this.permissionsService = permissionsService;
+    }
 }

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -10,7 +10,7 @@
 public interface ModifiableBlogComment extends ModifiableBlogItem, BlogComment {
     /**
      * Gets a unique id identifing this object. The comment returned
-     * by the {@link ModifiableBlogPost#getModifiableBlogComment(Object)}
+     * by the {@link ModifiableBlogPost#getModifiableBlogComment(Serializable)}
      * should be representing the same comment. Shouldn't be called on
      * new comment, which aren't yet added to a blog post (or are added to
      * a blog post which is itself not yet in any model).

Modified: trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -1,14 +1,15 @@
 package org.jboss.blog.service.store.model;
 
 import org.jboss.blog.model.BlogItem;
+import org.jboss.blog.model.BlogAuthor;
 
 import java.util.Date;
 
 /**
  * @author <a href="mailto:adamw at aster.pl">Adam Warski</a>
  */
-public interface ModifiableBlogItem extends BlogItem { 
-    public void setAuthor(String author);
+public interface ModifiableBlogItem extends BlogItem {
+    public void setAuthor(BlogAuthor author);
     public void setTitle(String title);
     public void setDescription(String description);
     public void setLink(String link);

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/BlogEdit.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/BlogEdit.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/BlogEdit.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -21,7 +21,6 @@
     private boolean initDone;
 
     private String title;
-    private String author;
     private String description;
     private String link;
 
@@ -38,15 +37,6 @@
         this.title = title;
     }
 
-    public String getAuthor() {
-        if (!initDone) { init(); }
-        return author;
-    }
-
-    public void setAuthor(String author) {
-        this.author = author;
-    }
-
     public String getDescription() {
         if (!initDone) { init(); }
         return description;
@@ -93,7 +83,6 @@
             model = new EmptyBlogModel();
         }
 
-        author = model.getAuthor();
         title = model.getTitle();
         description = model.getDescription();
         link = model.getLink();
@@ -110,9 +99,6 @@
 
             boolean changed = false;
 
-            if (!BlogTools.objectsEqual(author, mbm.getAuthor())) {
-                changed = true; mbm.setAuthor(author); }
-
             if (!BlogTools.objectsEqual(title, mbm.getTitle())) {
                 changed = true; mbm.setTitle(title); }
 
@@ -139,7 +125,8 @@
             ModifiableBlogModel mbm = BlogTools.getBlogService().getStoreService().newBlogModel(
                     getState().getSelectedBlogName());
 
-            mbm.setAuthor(author);
+            mbm.setAuthor(BlogTools.getBlogService().getStoreService().
+                    newBlogAuthor(getBlogView().getRequest()));
             mbm.setTitle(title);
             mbm.setLink(link);
             mbm.setDescription(description);

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/BlogView.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -64,7 +64,7 @@
     // A list of posts to show in the current view.
     private List posts;
 
-    private Object getRequest() {
+    Object getRequest() {
         return FacesContext.getCurrentInstance().getExternalContext().getRequest();
     }
 

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -18,21 +18,12 @@
     private UIData commentsData;
 
     private String title;
-    private String author;
     private String description;
 
     public CommentEdit() {
 
     }
 
-    public String getAuthor() {
-        return author;
-    }
-
-    public void setAuthor(String author) {
-        this.author = author;
-    }
-
     public String getDescription() {
         return description;
     }
@@ -95,7 +86,8 @@
 
             comment = BlogTools.getBlogService().getStoreService().newBlogComment();
 
-            comment.setAuthor(author);
+            comment.setAuthor(BlogTools.getBlogService().getStoreService().
+                    newBlogAuthor(getBlogView().getRequest()));
 
             comment.setTitle(title);
             comment.setDescription(description);

Modified: trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java
===================================================================
--- trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/java/org/jboss/blog/ui/PostEdit.java	2006-12-16 00:16:16 UTC (rev 38)
@@ -21,7 +21,6 @@
     private boolean initDone;
 
     private String title;
-    private String author;
     private String description;
     private String link;
     private String guid;
@@ -42,15 +41,6 @@
         this.title = title;
     }
 
-    public String getAuthor() {
-        if (!initDone) { init(); }
-        return author;
-    }
-
-    public void setAuthor(String author) {
-        this.author = author;
-    }
-
     public String getDescription() {
         if (!initDone) { init(); }
         return description;
@@ -132,7 +122,6 @@
         if (blogView.getSelectedPostTitleAsId() != null) {
             BlogPost post = blogView.getSelectedPost();
 
-            author = post.getAuthor();
             title = post.getTitle();
             description = post.getDescription();
             link = post.getLink();
@@ -185,7 +174,8 @@
 
             post = BlogTools.getBlogService().getStoreService().newBlogPost();
 
-            post.setAuthor(author);
+            post.setAuthor(BlogTools.getBlogService().getStoreService().
+                    newBlogAuthor(getBlogView().getRequest()));
 
             post.setTitle(title);
             post.setLink(link);
@@ -232,9 +222,6 @@
             boolean changed = false;
 
             // Changing post properties.
-            if (!BlogTools.objectsEqual(author, post.getAuthor())) {
-                changed = true; post.setAuthor(author); }
-
             if (!BlogTools.objectsEqual(title, post.getTitle())) {
                 changed = true; post.setTitle(title); }
 

Modified: trunk/blog-core/src/web/views/blog_mod.xhtml
===================================================================
--- trunk/blog-core/src/web/views/blog_mod.xhtml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/web/views/blog_mod.xhtml	2006-12-16 00:16:16 UTC (rev 38)
@@ -19,12 +19,6 @@
                                 maxlength="255" size="32" />
                     </h:panelGroup>
 
-                    <h:panelGroup>Author: (*)</h:panelGroup>
-                    <h:panelGroup>
-                        <h:inputText value="#{blogEdit.author}" required="true"
-                                     maxlength="255" size="32" />
-                    </h:panelGroup>
-
                     <h:panelGroup>Link: (*)</h:panelGroup>
                     <h:panelGroup>
                         <h:inputText value="#{blogEdit.link}" required="true"

Modified: trunk/blog-core/src/web/views/blog_view.xhtml
===================================================================
--- trunk/blog-core/src/web/views/blog_view.xhtml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/web/views/blog_view.xhtml	2006-12-16 00:16:16 UTC (rev 38)
@@ -46,7 +46,7 @@
                               rendered="#{!blogView.postsExpandable}" />
                 </span>
                 <span class="post-data">
-                    created on #{post.createdTime}, #{post.createdDate} by #{post.author}.
+                    created on #{post.createdTime}, #{post.createdDate} by #{post.author.fullName}.
                 </span>
 
                 <h:panelGroup rendered="#{!blogView.viewPostsOnSeparatePage and

Modified: trunk/blog-core/src/web/views/post_mod.xhtml
===================================================================
--- trunk/blog-core/src/web/views/post_mod.xhtml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/web/views/post_mod.xhtml	2006-12-16 00:16:16 UTC (rev 38)
@@ -19,12 +19,6 @@
                                      maxlength="255" size="32" />
                     </h:panelGroup>
 
-                    <h:panelGroup>Author: (*)</h:panelGroup>
-                    <h:panelGroup>
-                        <h:inputText value="#{postEdit.author}" required="true"
-                                     maxlength="255" size="32" />
-                    </h:panelGroup>
-
                     <h:panelGroup>Link: (*)</h:panelGroup>
                     <h:panelGroup>
                         <h:inputText value="#{postEdit.link}" required="true"

Modified: trunk/blog-core/src/web/views/post_view.xhtml
===================================================================
--- trunk/blog-core/src/web/views/post_view.xhtml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/web/views/post_view.xhtml	2006-12-16 00:16:16 UTC (rev 38)
@@ -27,7 +27,7 @@
         <span class="post-data">
             created on #{blogView.selectedPost.createdTime},
             #{blogView.selectedPost.createdDate}
-            by #{blogView.selectedPost.author}.
+            by #{blogView.selectedPost.author.fullName}.
         </span>
         </p>
 
@@ -50,7 +50,7 @@
                     <span class="post-title">#{comment.title}</span>
                     <span class="post-data">
                         created on #{comment.createdTime}, #{comment.createdDate}
-                        by #{comment.author}.
+                        by #{comment.author.fullName}.
                     </span>
 
                     <p class="post-description">
@@ -88,12 +88,6 @@
                                      maxlength="255" size="32" />
                     </h:panelGroup>
 
-                    <h:panelGroup>Author: (*)</h:panelGroup>
-                    <h:panelGroup>
-                        <h:inputText value="#{commentEdit.author}" required="true"
-                                     maxlength="255" size="32" />
-                    </h:panelGroup>
-
                     <h:panelGroup>Description: (*)</h:panelGroup>
                     <h:panelGroup>
                         <h:inputTextarea value="#{commentEdit.description}"

Modified: trunk/blog-core/src/web/views/view.xhtml
===================================================================
--- trunk/blog-core/src/web/views/view.xhtml	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/blog-core/src/web/views/view.xhtml	2006-12-16 00:16:16 UTC (rev 38)
@@ -8,12 +8,12 @@
         <ui:param name="requiredPermission" value="acl://viewCategory" />
         <ui:define name="content">
             <h2>
-                #{blogView.blogModel.title} created by
                 <h:panelGroup rendered="#{not empty blogView.blogName.category}">
-                #{blogView.blogModel.author}, category: #{blogView.blogName.category}
+                #{blogView.blogModel.title}, category: #{blogView.blogName.category}
                 </h:panelGroup>
+
                 <h:panelGroup rendered="#{empty blogView.blogName.category}">
-                #{blogView.blogModel.author}
+                #{blogView.blogModel.title}
                 </h:panelGroup>
             </h2>
 

Modified: trunk/jbossblog.iws
===================================================================
--- trunk/jbossblog.iws	2006-12-05 23:49:59 UTC (rev 37)
+++ trunk/jbossblog.iws	2006-12-16 00:16:16 UTC (rev 38)
@@ -17,20 +17,48 @@
   </component>
   <component name="ChangeListManager">
     <list default="true" name="Default" comment="">
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogViewState.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/BlogStoreService.java" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogAuthor.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/model" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogAuthor.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogCommentImpl.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogEdit.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogEdit.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/blog_mod.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/blog_mod.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/post_mod.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/view.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/view.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/BlogPermissionsService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/BlogPermissionsService.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogAuthorImpl.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/views/blog_view.xhtml" afterPath="$PROJECT_DIR$/blog-core/src/web/views/blog_view.xhtml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/EmptyPortalUser.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogItem.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogItem.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/BlogItem.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.hbm.xml" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.hbm.xml" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogComment.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/web/views/comment_del.xhtml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogModelImpl.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogModelImpl.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/build.xml" afterPath="$PROJECT_DIR$/blog-core/build.xml" />
       <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml" afterPath="$PROJECT_DIR$/blog-core/src/web/WEB-INF/faces-config.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/model/ModifiableBlogPost.java" />
-      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java" />
-      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml" afterPath="$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogAuthor.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogModel.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogModel.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/BlogPostImpl.java" />
+      <change type="MODIFICATION" beforePath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.hbm.xml" />
+      <change type="NEW" beforePath="" afterPath="$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/model/PortalUserBlogAuthor.java" />
     </list>
   </component>
   <component name="ChangeListSynchronizer" />
@@ -154,106 +182,7 @@
     </subPane>
   </component>
   <component name="FileEditorManager">
-    <leaf>
-      <file leaf-file-name="post_view.xhtml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="17" column="64" selection-start="818" selection-end="818" vertical-scroll-proportion="0.44117647">
-              <folding />
-            </state>
-          </provider>
-          <provider editor-type-id="HtmlPreview">
-            <state />
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="AclBlogPermissionsService.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="31" column="40" selection-start="1141" selection-end="1141" vertical-scroll-proportion="0.4074703">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="JBossPortalUtil.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/JBossPortalUtil.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="54" column="23" selection-start="1481" selection-end="1481" vertical-scroll-proportion="0.34271523">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="comment_del.xhtml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/comment_del.xhtml">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="14" column="47" selection-start="572" selection-end="572" vertical-scroll-proportion="0.3633218">
-              <folding />
-            </state>
-          </provider>
-          <provider editor-type-id="HtmlPreview">
-            <state />
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="CommentEdit.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="107" column="53" selection-start="2908" selection-end="2908" vertical-scroll-proportion="0.5925297">
-              <folding>
-                <element signature="imports" expanded="true" />
-              </folding>
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="acl-permissions.xml" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="44" column="40" selection-start="1646" selection-end="1646" vertical-scroll-proportion="0.7385399">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="acl-mapping.xml" pinned="false" current="true" current-in-tab="true">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="88" column="47" selection-start="3790" selection-end="3790" vertical-scroll-proportion="0.61799663">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="PostEdit.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="228" column="37" selection-start="6439" selection-end="6439" vertical-scroll-proportion="0.23089983">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="BlogView.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="237" column="29" selection-start="6827" selection-end="6827" vertical-scroll-proportion="0.6258278">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-      <file leaf-file-name="HibernateBlogStoreService.java" pinned="false" current="false" current-in-tab="false">
-        <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
-          <provider selected="true" editor-type-id="text-editor">
-            <state line="370" column="17" selection-start="13065" selection-end="13065" vertical-scroll-proportion="0.9524618">
-              <folding />
-            </state>
-          </provider>
-        </entry>
-      </file>
-    </leaf>
+    <leaf />
   </component>
   <component name="FindManager">
     <FindUsagesManager>
@@ -349,6 +278,10 @@
           <option name="myItemId" value="blog-core" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
         </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="Libraries" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.LibraryGroupNode" />
+        </PATH_ELEMENT>
       </PATH>
       <PATH>
         <PATH_ELEMENT>
@@ -360,6 +293,46 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="Libraries" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.LibraryGroupNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/lib/jboss-portal/portal-identity-lib.jar" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/lib/jboss-portal/portal-identity-lib.jar!/org/jboss/portal/identity" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="Libraries" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.LibraryGroupNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/lib/jboss-portal/portal-identity-lib.jar" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -580,6 +553,40 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/tools" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -782,6 +789,48 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -820,6 +869,86 @@
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
         <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+      </PATH>
+      <PATH>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="jbossblog.ipr" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewProjectNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.ProjectViewModuleNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
+          <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service" />
+          <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
+        </PATH_ELEMENT>
+        <PATH_ELEMENT>
           <option name="myItemId" value="PsiDirectory:$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/configuration" />
           <option name="myItemType" value="com.intellij.ide.projectView.impl.nodes.PsiDirectoryNode" />
         </PATH_ELEMENT>
@@ -987,7 +1116,7 @@
       <showLibraryContents />
       <hideEmptyPackages />
       <abbreviatePackageNames />
-      <showStructure ProjectPane="false" PackagesPane="false" Scope="false" Favorites="false" />
+      <showStructure Favorites="false" ProjectPane="false" Scope="false" PackagesPane="false" />
       <autoscrollToSource />
       <autoscrollFromSource />
       <sortByType />
@@ -1015,27 +1144,15 @@
       <recent name="org.jboss.blog.service.configuration" />
     </key>
     <key name="MoveClassesOrPackagesDialog.RECENTS_KEY">
+      <recent name="org.jboss.blog.service.store.hibernate" />
+      <recent name="org.jboss.blog.service.permissions.acl" />
+      <recent name="org.jboss.blog.service.permissions.model" />
       <recent name="org.jboss.blog.service.model.rome" />
       <recent name="org.jboss.blog.service.model.caching" />
-      <recent name="org.jboss.blog.service.store.hibernate" />
-      <recent name="org.jboss.blog.service.store.hibernate.filter" />
-      <recent name="org.jboss.blog.model.impl" />
     </key>
   </component>
   <component name="RestoreUpdateTree" />
   <component name="RunManager">
-    <configuration default="true" type="Applet" factoryName="Applet">
-      <module name="" />
-      <option name="MAIN_CLASS_NAME" />
-      <option name="HTML_FILE_NAME" />
-      <option name="HTML_USED" value="false" />
-      <option name="WIDTH" value="400" />
-      <option name="HEIGHT" value="300" />
-      <option name="POLICY_FILE" value="$APPLICATION_HOME_DIR$/bin/appletviewer.policy" />
-      <option name="VM_PARAMETERS" />
-      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
-      <option name="ALTERNATIVE_JRE_PATH" />
-    </configuration>
     <configuration default="true" type="Remote" factoryName="Remote">
       <option name="USE_SOCKET_TRANSPORT" value="true" />
       <option name="SERVER_MODE" value="false" />
@@ -1043,6 +1160,16 @@
       <option name="HOST" value="localhost" />
       <option name="PORT" value="5005" />
     </configuration>
+    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
+      <option name="MAIN_CLASS_NAME" />
+      <option name="VM_PARAMETERS" />
+      <option name="PROGRAM_PARAMETERS" />
+      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
+      <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
+      <option name="ALTERNATIVE_JRE_PATH" />
+      <option name="ENABLE_SWING_INSPECTOR" value="false" />
+      <module name="" />
+    </configuration>
     <configuration default="true" type="JUnit" factoryName="JUnit" enabled="false" merge="false">
       <module name="" />
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
@@ -1062,15 +1189,17 @@
         <option name="Make" value="true" />
       </method>
     </configuration>
-    <configuration default="true" type="Application" factoryName="Application" enabled="false" merge="false">
+    <configuration default="true" type="Applet" factoryName="Applet">
+      <module name="" />
       <option name="MAIN_CLASS_NAME" />
+      <option name="HTML_FILE_NAME" />
+      <option name="HTML_USED" value="false" />
+      <option name="WIDTH" value="400" />
+      <option name="HEIGHT" value="300" />
+      <option name="POLICY_FILE" value="$APPLICATION_HOME_DIR$/bin/appletviewer.policy" />
       <option name="VM_PARAMETERS" />
-      <option name="PROGRAM_PARAMETERS" />
-      <option name="WORKING_DIRECTORY" value="$PROJECT_DIR$" />
       <option name="ALTERNATIVE_JRE_PATH_ENABLED" value="false" />
       <option name="ALTERNATIVE_JRE_PATH" />
-      <option name="ENABLE_SWING_INSPECTOR" value="false" />
-      <module name="" />
     </configuration>
   </component>
   <component name="ScopeViewComponent">
@@ -1149,22 +1278,22 @@
     </todo-panel>
   </component>
   <component name="ToolWindowManager">
-    <frame x="0" y="25" width="1690" height="1004" extended-state="6" />
+    <frame x="0" y="25" width="1680" height="1000" extended-state="0" />
     <editor active="true" />
     <layout>
       <window_info id="UI Designer" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="CVS" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="13" />
       <window_info id="IDEtalk" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="3" />
       <window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.3298969" order="7" />
-      <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26118946" order="0" />
-      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32839224" order="1" />
+      <window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.26095003" order="0" />
+      <window_info id="Find" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.32760596" order="1" />
       <window_info id="Structure" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24367674" order="7" />
-      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22690992" order="9" />
+      <window_info id="Messages" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.22680412" order="9" />
       <window_info id="Inspection" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.39977092" order="6" />
       <window_info id="Module Dependencies" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="4" />
       <window_info id="Dependency Viewer" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="10" />
       <window_info id="Palette" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="5" />
-      <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.24524832" order="1" />
+      <window_info id="Ant Build" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" weight="0.24491055" order="1" />
       <window_info id="Changes" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.3298969" order="11" />
       <window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.33" order="2" />
       <window_info id="Hierarchy" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" weight="0.24984577" order="2" />
@@ -1268,121 +1397,113 @@
     <option name="myLastEditedConfigurable" value="Project Default" />
   </component>
   <component name="editorHistoryManager">
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/impl/EmptyBlogComment.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/build.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="9" column="41" selection-start="256" selection-end="256" vertical-scroll-proportion="0.16304348">
+        <state line="102" column="25" selection-start="4486" selection-end="4486" vertical-scroll-proportion="0.4076539">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/id_edit.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/jboss-service.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="47" column="70" selection-start="2207" selection-end="2207" vertical-scroll-proportion="0.97231835">
+        <state line="66" column="63" selection-start="3550" selection-end="3550" vertical-scroll-proportion="0.64403975">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/BlogView.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogModel.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="237" column="29" selection-start="6827" selection-end="6827" vertical-scroll-proportion="0.6258278">
+        <state line="32" column="4" selection-start="1007" selection-end="1007" vertical-scroll-proportion="0.024232633">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/PostEdit.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="228" column="37" selection-start="6439" selection-end="6439" vertical-scroll-proportion="0.23089983">
+        <state line="50" column="26" selection-start="1331" selection-end="1331" vertical-scroll-proportion="0.024232633">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/comment_del.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="14" column="47" selection-start="572" selection-end="572" vertical-scroll-proportion="0.3633218">
+        <state line="97" column="49" selection-start="2785" selection-end="2785" vertical-scroll-proportion="0.5723473">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/view.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeBlogPost.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="15" column="43" selection-start="834" selection-end="834" vertical-scroll-proportion="0.38726333">
+        <state line="23" column="11" selection-start="690" selection-end="690" vertical-scroll-proportion="0.25902668">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/security/acl/AclKernelFactory.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/model/rome/RomeParsingBlogModelService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="0" column="0" selection-start="0" selection-end="0" vertical-scroll-proportion="0.0">
+        <state line="66" column="43" selection-start="2156" selection-end="2156" vertical-scroll-proportion="0.43295637">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/ACLTagHandler.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/conf/hibernate/hibernate.cfg.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="106" column="48" selection-start="3564" selection-end="3564" vertical-scroll-proportion="0.6425041">
+        <state line="39" column="81" selection-start="1940" selection-end="1940" vertical-scroll-proportion="0.67715234">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="17" column="64" selection-start="818" selection-end="818" vertical-scroll-proportion="0.44117647">
+        <state line="217" column="23" selection-start="7222" selection-end="7222" vertical-scroll-proportion="0.571192">
           <folding />
         </state>
       </provider>
-      <provider editor-type-id="HtmlPreview">
-        <state />
-      </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/JBossPortalUtil.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.hbm.xml">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="54" column="23" selection-start="1481" selection-end="1481" vertical-scroll-proportion="0.34271523">
+        <state line="12" column="40" selection-start="464" selection-end="464" vertical-scroll-proportion="0.2907916">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HibernateBlogStoreService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/store/hibernate/HPortalBlogAuthor.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="370" column="17" selection-start="13065" selection-end="13065" vertical-scroll-proportion="0.9524618">
+        <state line="18" column="44" selection-start="559" selection-end="559" vertical-scroll-proportion="0.3634895">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/model/AbstractBlogAuthor.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="31" column="40" selection-start="1141" selection-end="1141" vertical-scroll-proportion="0.4074703">
+        <state line="7" column="22" selection-start="160" selection-end="160" vertical-scroll-proportion="0.16483517">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/ui/CommentEdit.java">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/java/org/jboss/blog/service/permissions/acl/AclBlogPermissionsService.java">
       <provider selected="true" editor-type-id="text-editor">
-        <state line="107" column="53" selection-start="2908" selection-end="2908" vertical-scroll-proportion="0.5925297">
-          <folding>
-            <element signature="imports" expanded="true" />
-          </folding>
+        <state line="102" column="36" selection-start="3285" selection-end="3285" vertical-scroll-proportion="0.81832796">
+          <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-permissions.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/view.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="44" column="40" selection-start="1646" selection-end="1646" vertical-scroll-proportion="0.7385399">
+        <state line="18" column="12" selection-start="830" selection-end="830" vertical-scroll-proportion="0.45302013">
           <folding />
         </state>
       </provider>
     </entry>
-    <entry file="file://$PROJECT_DIR$/blog-core/src/etc/META-INF/acl-mapping.xml">
+    <entry file="file://$PROJECT_DIR$/blog-core/src/web/views/post_view.xhtml">
+      <provider editor-type-id="HtmlPreview">
+        <state />
+      </provider>
       <provider selected="true" editor-type-id="text-editor">
-        <state line="88" column="47" selection-start="3790" selection-end="3790" vertical-scroll-proportion="0.61799663">
+        <state line="23" column="58" selection-start="941" selection-end="941" vertical-scroll-proportion="0.5646481">
           <folding />
         </state>
       </provider>



From gavin.king at jboss.com  Fri Dec 15 21:16:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 21:16:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvP6C-0003t1-IG@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 21:16:28

  Modified:    src/main/org/jboss/seam  Component.java
  Log:
  rip out commons-logging, in order to solve   JBSEAM-581
  
  Revision  Changes    Path
  1.220     +3 -3      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.219
  retrieving revision 1.220
  diff -u -b -r1.219 -r1.220
  --- Component.java	14 Dec 2006 10:26:59 -0000	1.219
  +++ Component.java	16 Dec 2006 02:16:28 -0000	1.220
  @@ -122,7 +122,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.219 $
  + * @version $Revision: 1.220 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -546,11 +546,11 @@
                  String category = field.getAnnotation(org.jboss.seam.annotations.Logger.class).value();
                  if ( "".equals( category ) )
                  {
  -                  logInstance = new org.jboss.seam.log.LogImpl(beanClass);
  +                  logInstance = org.jboss.seam.log.Logging.getLog(beanClass);
                  }
                  else
                  {
  -                  logInstance = new org.jboss.seam.log.LogImpl(category);
  +                  logInstance = org.jboss.seam.log.Logging.getLog(category);
                  }
               }
               for ( Annotation ann: field.getAnnotations() )
  
  
  


From gavin.king at jboss.com  Fri Dec 15 21:16:28 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 21:16:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/log      ...
Message-ID: <E1GvP6C-0003tK-Q1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 21:16:28

  Modified:    src/main/org/jboss/seam/log      LogImpl.java
  Added:       src/main/org/jboss/seam/log      JDKProvider.java
                        Log4JProvider.java LogProvider.java Logging.java
  Log:
  rip out commons-logging, in order to solve   JBSEAM-581
  
  Revision  Changes    Path
  1.8       +4 -10     jboss-seam/src/main/org/jboss/seam/log/LogImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LogImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/log/LogImpl.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- LogImpl.java	14 Nov 2006 20:38:30 -0000	1.7
  +++ LogImpl.java	16 Dec 2006 02:16:28 -0000	1.8
  @@ -5,7 +5,6 @@
   import java.io.ObjectInput;
   import java.io.ObjectOutput;
   
  -import org.apache.commons.logging.LogFactory;
   import org.jboss.seam.core.Interpolator;
   
   /**
  @@ -16,20 +15,15 @@
   public class LogImpl implements Log, Externalizable
   {
      
  -   private transient org.apache.commons.logging.Log log;
  +   private transient LogProvider log;
      private String category;
   
      public LogImpl() {} //for Externalizable
      
  -   public LogImpl(Class clazz)
  -   {
  -      this( clazz.getName() );
  -   }
  -
  -   public LogImpl(String category)
  +   LogImpl(String category)
      {
         this.category = category;
  -      this.log = LogFactory.getLog(category);
  +      this.log = Logging.getLogProvider(category);
      }
   
      public boolean isDebugEnabled()
  @@ -173,7 +167,7 @@
      public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
      {
         category = (String) in.readObject();
  -      log = LogFactory.getLog(category);
  +      log = Logging.getLogProvider(category);
      }
   
      public void writeExternal(ObjectOutput out) throws IOException
  
  
  
  1.1      date: 2006/12/16 02:16:28;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/log/JDKProvider.java
  
  Index: JDKProvider.java
  ===================================================================
  package org.jboss.seam.log;
  
  import java.util.logging.Level;
  import java.util.logging.Logger;
  
  public class JDKProvider implements LogProvider
  {
     private final Logger logger;
  
     JDKProvider(String category)
     {
        this.logger = Logger.getLogger(category);
     }
  
     private void log( Level level, Object object, Throwable ex ) 
     {
  
        if ( logger.isLoggable(level) ) 
        {
            Throwable dummyException=new Throwable();
            StackTraceElement locations[]=dummyException.getStackTrace();
            String className="unknown";
            String methodName="unknown";
            if( locations!=null && locations.length>3 ) 
            {
                StackTraceElement caller=locations[3];
                className=caller.getClassName();
                methodName=caller.getMethodName();
            }
            if( ex==null ) 
            {
                logger.logp( level, className, methodName, String.valueOf(object) );
            } 
            else 
            {
                logger.logp( level, className, methodName, String.valueOf(object), ex );
            }
        }
  
    }
     
     public void debug(Object object, Throwable t)
     {
        log(Level.FINE, object, t);
     }
  
     public void debug(Object object)
     {
        log(Level.FINE, object, null);
     }
  
     public void error(Object object, Throwable t)
     {
        log(Level.SEVERE, object, t);
     }
  
     public void error(Object object)
     {
        log(Level.SEVERE, object, null);
     }
  
     public void fatal(Object object, Throwable t)
     {
        log(Level.SEVERE, object, t);
     }
  
     public void fatal(Object object)
     {
        log(Level.SEVERE, object, null);
     }
  
     public void info(Object object, Throwable t)
     {
        log(Level.INFO, object, t);
     }
  
     public void info(Object object)
     {
        log(Level.INFO, object, null);
     }
  
     public boolean isDebugEnabled()
     {
        return logger.isLoggable(Level.FINE);
     }
  
     public boolean isErrorEnabled()
     {
        return logger.isLoggable(Level.SEVERE);
     }
  
     public boolean isFatalEnabled()
     {
        return logger.isLoggable(Level.SEVERE);
     }
  
     public boolean isInfoEnabled()
     {
        return logger.isLoggable(Level.INFO);
     }
  
     public boolean isTraceEnabled()
     {
        return logger.isLoggable(Level.FINER);
     }
  
     public boolean isWarnEnabled()
     {
        return logger.isLoggable(Level.WARNING);
     }
  
     public void trace(Object object, Throwable t)
     {
        log(Level.FINER, object, t);
     }
  
     public void trace(Object object)
     {
        log(Level.FINER, object, null);
     }
  
     public void warn(Object object, Throwable t)
     {
        log(Level.WARNING, object, t);
     }
  
     public void warn(Object object)
     {
        log(Level.WARNING, object, null);
     }
     
  }
  
  
  
  1.1      date: 2006/12/16 02:16:28;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/log/Log4JProvider.java
  
  Index: Log4JProvider.java
  ===================================================================
  package org.jboss.seam.log;
  
  import org.apache.log4j.Level;
  import org.apache.log4j.Logger;
  
  public final class Log4JProvider implements LogProvider
  {
     private final Logger logger;
     
     private static final String FQCN = LogImpl.class.getName();
     
     Log4JProvider(String category)
     {
        logger = Logger.getLogger(category);
     }
     
     public void debug(Object object)
     {
        logger.log(FQCN, Level.DEBUG, object, null);
     }
  
     public void debug(Object object, Throwable t)
     {
        logger.log(FQCN, Level.DEBUG, object, t);
     }
  
     public void error(Object object)
     {
        logger.log(FQCN, Level.ERROR, object, null);
     }
  
     public void error(Object object, Throwable t)
     {
        logger.log(FQCN, Level.ERROR, object, t);
     }
  
     public void fatal(Object object)
     {
        logger.log(FQCN, Level.FATAL, object, null);
     }
  
     public void fatal(Object object, Throwable t)
     {
        logger.log(FQCN, Level.DEBUG, object, t);
     }
  
     public void info(Object object)
     {
        logger.log(FQCN, Level.INFO, object, null);
     }
  
     public void info(Object object, Throwable t)
     {
        logger.log(FQCN, Level.INFO, object, t);
     }
  
     public boolean isDebugEnabled()
     {
        return logger.isEnabledFor(Level.DEBUG);
     }
  
     public boolean isErrorEnabled()
     {
        return logger.isEnabledFor(Level.ERROR);
     }
  
     public boolean isFatalEnabled()
     {
        return logger.isEnabledFor(Level.FATAL);
     }
  
     public boolean isInfoEnabled()
     {
        return logger.isEnabledFor(Level.INFO);
     }
  
     public boolean isTraceEnabled()
     {
        return logger.isEnabledFor(Level.DEBUG);
     }
  
     public boolean isWarnEnabled()
     {
        return logger.isEnabledFor(Level.WARN);
     }
  
     public void trace(Object object)
     {
        logger.log(FQCN, Level.DEBUG, object, null);
     }
  
     public void trace(Object object, Throwable t)
     {
        logger.log(FQCN, Level.DEBUG, object, t);
     }
  
     public void warn(Object object)
     {
        logger.log(FQCN, Level.WARN, object, null);
     }
  
     public void warn(Object object, Throwable t)
     {
        logger.log(FQCN, Level.WARN, object, t);
     }
  
  }
  
  
  
  1.1      date: 2006/12/16 02:16:28;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/log/LogProvider.java
  
  Index: LogProvider.java
  ===================================================================
  package org.jboss.seam.log;
  
  public interface LogProvider
  {
     public void trace(Object object);
     public void trace(Object object, Throwable t);
     public void debug(Object object);
     public void debug(Object object, Throwable t);
     public void info(Object object);
     public void info(Object object, Throwable t);
     public void warn(Object object);
     public void warn(Object object, Throwable t);
     public void error(Object object);
     public void error(Object object, Throwable t);
     public void fatal(Object object);
     public void fatal(Object object, Throwable t);
     public boolean isTraceEnabled();
     public boolean isDebugEnabled();
     public boolean isInfoEnabled();
     public boolean isWarnEnabled();
     public boolean isErrorEnabled();
     public boolean isFatalEnabled();
  }
  
  
  
  1.1      date: 2006/12/16 02:16:28;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/log/Logging.java
  
  Index: Logging.java
  ===================================================================
  package org.jboss.seam.log;
  
  public class Logging
  {
     
     private static final boolean isLog4JAvailable;
     
     static
     {
        boolean available;
        try
        {
           Class.forName("org.apache.log4j.Logger");
           available = true;
        }
        catch (ClassNotFoundException cnfe)
        {
           available = false;
        }
        isLog4JAvailable = available;
     }
     
     public static Log getLog(String category)
     {
        return new LogImpl(category);
     }
     
     public static Log getLog(Class clazz)
     {
        return new LogImpl( clazz.getName() );
     }
     
     public static LogProvider getLogProvider(String category)
     {
        return isLog4JAvailable ? 
                 new Log4JProvider(category) : 
                 new JDKProvider(category);
     }
     
  }
  
  
  


From gavin.king at jboss.com  Fri Dec 15 21:16:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 21:16:49 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test
	...
Message-ID: <E1GvP6X-0003uH-LJ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 21:16:49

  Modified:    examples/booking/src/org/jboss/seam/example/booking/test 
                        BookingUnitTest.java
  Log:
  rip out commons-logging, in order to solve   JBSEAM-581
  
  Revision  Changes    Path
  1.12      +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingUnitTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- BookingUnitTest.java	27 Oct 2006 23:11:17 -0000	1.11
  +++ BookingUnitTest.java	16 Dec 2006 02:16:49 -0000	1.12
  @@ -15,7 +15,7 @@
   import org.jboss.seam.example.booking.HotelSearching;
   import org.jboss.seam.example.booking.HotelSearchingAction;
   import org.jboss.seam.example.booking.User;
  -import org.jboss.seam.log.LogImpl;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.mock.SeamTest;
   import org.testng.annotations.Test;
   
  @@ -58,7 +58,7 @@
         setField(hb, "user", em.getReference(User.class, "gavin"));
         setField(hb, "facesMessages", new FacesMessages());
         setField(hb, "events", new Events() { @Override public void raiseEvent(String type, Object... params) { assert "bookingConfirmed".equals(type); } } );
  -      setField(hb, "log", new LogImpl(HotelBookingAction.class));
  +      setField(hb, "log", Logging.getLog(HotelBookingAction.class));
         
         assert hb.selectHotel(hotel).equals("hotel");
   
  
  
  


From gavin.king at jboss.com  Fri Dec 15 21:20:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 21:20:03 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/icefaces/src/org/jboss/seam/example/booking/test
	...
Message-ID: <E1GvP9f-0003wB-5N@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 21:20:03

  Modified:    examples/icefaces/src/org/jboss/seam/example/booking/test 
                        BookingUnitTest.java
  Log:
  rip out commons-logging, in order to solve   JBSEAM-581
  
  Revision  Changes    Path
  1.2       +2 -2      jboss-seam/examples/icefaces/src/org/jboss/seam/example/booking/test/BookingUnitTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingUnitTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/icefaces/src/org/jboss/seam/example/booking/test/BookingUnitTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- BookingUnitTest.java	20 Nov 2006 05:19:01 -0000	1.1
  +++ BookingUnitTest.java	16 Dec 2006 02:20:03 -0000	1.2
  @@ -15,7 +15,7 @@
   import org.jboss.seam.example.booking.HotelSearching;
   import org.jboss.seam.example.booking.HotelSearchingAction;
   import org.jboss.seam.example.booking.User;
  -import org.jboss.seam.log.LogImpl;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.mock.SeamTest;
   import org.testng.annotations.Test;
   
  @@ -58,7 +58,7 @@
         setField(hb, "user", em.getReference(User.class, "gavin"));
         setField(hb, "facesMessages", new FacesMessages());
         setField(hb, "events", new Events() { @Override public void raiseEvent(String type, Object... params) { assert "bookingConfirmed".equals(type); } } );
  -      setField(hb, "log", new LogImpl(HotelBookingAction.class));
  +      setField(hb, "log", Logging.getLog(HotelBookingAction.class));
         
         assert hb.selectHotel(hotel).equals("hotel");
   
  
  
  


From gavin.king at jboss.com  Fri Dec 15 21:20:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 21:20:03 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/glassfish/src/org/jboss/seam/example/booking/test
	...
Message-ID: <E1GvP9f-0003wI-8x@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 21:20:03

  Modified:    examples/glassfish/src/org/jboss/seam/example/booking/test 
                        BookingUnitTest.java
  Log:
  rip out commons-logging, in order to solve   JBSEAM-581
  
  Revision  Changes    Path
  1.2       +2 -2      jboss-seam/examples/glassfish/src/org/jboss/seam/example/booking/test/BookingUnitTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingUnitTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/glassfish/src/org/jboss/seam/example/booking/test/BookingUnitTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- BookingUnitTest.java	29 Nov 2006 09:30:42 -0000	1.1
  +++ BookingUnitTest.java	16 Dec 2006 02:20:03 -0000	1.2
  @@ -15,7 +15,7 @@
   import org.jboss.seam.example.booking.HotelSearching;
   import org.jboss.seam.example.booking.HotelSearchingAction;
   import org.jboss.seam.example.booking.User;
  -import org.jboss.seam.log.LogImpl;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.mock.SeamTest;
   import org.testng.annotations.Test;
   
  @@ -58,7 +58,7 @@
         setField(hb, "user", em.getReference(User.class, "gavin"));
         setField(hb, "facesMessages", new FacesMessages());
         setField(hb, "events", new Events() { @Override public void raiseEvent(String type, Object... params) { assert "bookingConfirmed".equals(type); } } );
  -      setField(hb, "log", new LogImpl(HotelBookingAction.class));
  +      setField(hb, "log", Logging.getLog(HotelBookingAction.class));
         
         assert hb.selectHotel(hotel).equals("hotel");
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:10 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:10 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvPkY-0004bc-DB@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:10

  Modified:    src/main/org/jboss/seam  Component.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.221     +4 -4      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.220
  retrieving revision 1.221
  diff -u -b -r1.220 -r1.221
  --- Component.java	16 Dec 2006 02:16:28 -0000	1.220
  +++ Component.java	16 Dec 2006 02:58:10 -0000	1.221
  @@ -51,8 +51,8 @@
   import net.sf.cglib.proxy.Factory;
   import net.sf.cglib.proxy.MethodInterceptor;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.hibernate.validator.ClassValidator;
   import org.jboss.seam.annotations.Asynchronous;
   import org.jboss.seam.annotations.Conversational;
  @@ -122,7 +122,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.220 $
  + * @version $Revision: 1.221 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -130,7 +130,7 @@
   {
      public static final String PROPERTIES = "org.jboss.seam.properties";
   
  -   private static final Log log = LogFactory.getLog(Component.class);
  +   private static final LogProvider log = Logging.getLogProvider(Component.class);
   
      private ComponentType type;
      private String name;
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:10 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:10 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts    ...
Message-ID: <E1GvPkY-0004bp-IQ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:10

  Modified:    src/main/org/jboss/seam/contexts   
                        BusinessProcessContext.java Contexts.java
                        Lifecycle.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.33      +4 -4      jboss-seam/src/main/org/jboss/seam/contexts/BusinessProcessContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcessContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/BusinessProcessContext.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- BusinessProcessContext.java	11 Oct 2006 04:42:12 -0000	1.32
  +++ BusinessProcessContext.java	16 Dec 2006 02:58:10 -0000	1.33
  @@ -11,8 +11,8 @@
   import java.util.Map;
   import java.util.Set;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
   import org.jboss.seam.core.Events;
  @@ -27,11 +27,11 @@
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author <a href="mailto:steve at hibernate.org">Steve Ebersole</a>
    * @author Gavin King
  - * @version $Revision: 1.32 $
  + * @version $Revision: 1.33 $
    */
   public class BusinessProcessContext implements Context {
   
  -   private static final Log log = LogFactory.getLog(BusinessProcessContext.class);
  +   private static final LogProvider log = Logging.getLogProvider(BusinessProcessContext.class);
   
      private final Map<String, Object> additions = new HashMap<String, Object>();
      private final Set<String> removals = new HashSet<String>();
  
  
  
  1.46      +5 -5      jboss-seam/src/main/org/jboss/seam/contexts/Contexts.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Contexts.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Contexts.java,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- Contexts.java	14 Dec 2006 10:27:00 -0000	1.45
  +++ Contexts.java	16 Dec 2006 02:58:10 -0000	1.46
  @@ -6,8 +6,8 @@
   ?*/
   package org.jboss.seam.contexts;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.core.Events;
   
  @@ -16,11 +16,11 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.45 $
  + * @version $Revision: 1.46 $
    */
   public class Contexts {
   
  -   private static final Log log = LogFactory.getLog( Contexts.class );
  +   private static final LogProvider log = Logging.getLogProvider( Contexts.class );
   
      static final ThreadLocal<Context> applicationContext = new ThreadLocal<Context>();
      static final ThreadLocal<Context> methodContext = new ThreadLocal<Context>();
  
  
  
  1.72      +4 -4      jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.71
  retrieving revision 1.72
  diff -u -b -r1.71 -r1.72
  --- Lifecycle.java	14 Dec 2006 10:27:00 -0000	1.71
  +++ Lifecycle.java	16 Dec 2006 02:58:10 -0000	1.72
  @@ -15,8 +15,8 @@
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpSession;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -31,12 +31,12 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.71 $
  + * @version $Revision: 1.72 $
    */
   public class Lifecycle
   {
   
  -   private static final Log log = LogFactory.getLog( Lifecycle.class );
  +   private static final LogProvider log = Logging.getLogProvider( Lifecycle.class );
   
      public static void beginRequest(ExternalContext externalContext) {
         log.debug( ">>> Begin web request" );
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:10 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:10 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core              ...
Message-ID: <E1GvPkY-0004cW-RE@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:10

  Modified:    src/main/org/jboss/seam/core              Ejb.java
                        Events.java Exceptions.java Interpolator.java
                        Jbpm.java ManagedHibernateSession.java
                        ManagedJbpmContext.java
                        ManagedPersistenceContext.java Manager.java
                        Pageflow.java Pages.java PojoCache.java
                        ResourceBundle.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.20      +4 -4      jboss-seam/src/main/org/jboss/seam/core/Ejb.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Ejb.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Ejb.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- Ejb.java	5 Dec 2006 19:37:02 -0000	1.19
  +++ Ejb.java	16 Dec 2006 02:58:10 -0000	1.20
  @@ -1,11 +1,11 @@
  -//$Id: Ejb.java,v 1.19 2006/12/05 19:37:02 gavin Exp $
  +//$Id: Ejb.java,v 1.20 2006/12/16 02:58:10 nrichards Exp $
   package org.jboss.seam.core;
   
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.ejb3.embedded.EJB3StandaloneBootstrap;
   import org.jboss.ejb3.embedded.EJB3StandaloneDeployer;
   import org.jboss.seam.ScopeType;
  @@ -30,7 +30,7 @@
   @Install(value=false, precedence=BUILT_IN)
   public class Ejb
   {
  -   private static final Log log = LogFactory.getLog(Ejb.class);
  +   private static final LogProvider log = Logging.getLogProvider(Ejb.class);
      
      private EJB3StandaloneDeployer deployer;
      private boolean started;
  
  
  
  1.14      +3 -3      jboss-seam/src/main/org/jboss/seam/core/Events.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Events.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Events.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- Events.java	24 Nov 2006 23:15:17 -0000	1.13
  +++ Events.java	16 Dec 2006 02:58:10 -0000	1.14
  @@ -10,8 +10,8 @@
   import java.util.List;
   import java.util.Map;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  @@ -37,7 +37,7 @@
   public class Events 
   {
      
  -   private static final Log log = LogFactory.getLog(Events.class);
  +   private static final LogProvider log = Logging.getLogProvider(Events.class);
      
      private final Map<String, List<MethodBinding>> listeners = new HashMap<String, List<MethodBinding>>();
      
  
  
  
  1.17      +3 -3      jboss-seam/src/main/org/jboss/seam/core/Exceptions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Exceptions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Exceptions.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- Exceptions.java	3 Dec 2006 07:01:54 -0000	1.16
  +++ Exceptions.java	16 Dec 2006 02:58:10 -0000	1.17
  @@ -11,8 +11,8 @@
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseId;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  @@ -47,7 +47,7 @@
   @Name("org.jboss.seam.core.exceptions")
   public class Exceptions 
   {
  -   private static final Log log = LogFactory.getLog(Exceptions.class);
  +   private static final LogProvider log = Logging.getLogProvider(Exceptions.class);
      
      private List<ExceptionHandler> exceptionHandlers = new ArrayList<ExceptionHandler>();
      
  
  
  
  1.13      +3 -3      jboss-seam/src/main/org/jboss/seam/core/Interpolator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Interpolator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Interpolator.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- Interpolator.java	24 Nov 2006 23:15:17 -0000	1.12
  +++ Interpolator.java	16 Dec 2006 02:58:10 -0000	1.13
  @@ -7,8 +7,8 @@
   import java.text.MessageFormat;
   import java.util.StringTokenizer;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Intercept;
  @@ -27,7 +27,7 @@
   @Install(precedence=BUILT_IN)
   public class Interpolator {
   
  -   private static final Log log = LogFactory.getLog(Interpolator.class);
  +   private static final LogProvider log = Logging.getLogProvider(Interpolator.class);
      
      public static Interpolator instance()
      {
  
  
  
  1.40      +3 -3      jboss-seam/src/main/org/jboss/seam/core/Jbpm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Jbpm.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Jbpm.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -b -r1.39 -r1.40
  --- Jbpm.java	24 Nov 2006 23:15:17 -0000	1.39
  +++ Jbpm.java	16 Dec 2006 02:58:10 -0000	1.40
  @@ -12,8 +12,8 @@
   
   import javax.naming.NamingException;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.hibernate.cfg.Environment;
   import org.hibernate.lob.ReaderInputStream;
   import org.jboss.seam.ScopeType;
  @@ -51,7 +51,7 @@
   @Install(value=false, precedence=BUILT_IN)
   public class Jbpm 
   {
  -   private static final Log log = LogFactory.getLog(Jbpm.class);
  +   private static final LogProvider log = Logging.getLogProvider(Jbpm.class);
      
      private JbpmConfiguration jbpmConfiguration;
      private String jbpmConfigurationJndiName;
  
  
  
  1.27      +4 -4      jboss-seam/src/main/org/jboss/seam/core/ManagedHibernateSession.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedHibernateSession.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ManagedHibernateSession.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- ManagedHibernateSession.java	25 Oct 2006 15:14:35 -0000	1.26
  +++ ManagedHibernateSession.java	16 Dec 2006 02:58:10 -0000	1.27
  @@ -1,4 +1,4 @@
  -//$Id: ManagedHibernateSession.java,v 1.26 2006/10/25 15:14:35 gavin Exp $
  +//$Id: ManagedHibernateSession.java,v 1.27 2006/12/16 02:58:10 nrichards Exp $
   package org.jboss.seam.core;
   
   import static org.jboss.seam.InterceptionType.NEVER;
  @@ -12,8 +12,8 @@
   import javax.servlet.http.HttpSessionActivationListener;
   import javax.servlet.http.HttpSessionEvent;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.hibernate.FlushMode;
   import org.hibernate.Session;
   import org.hibernate.SessionFactory;
  @@ -45,7 +45,7 @@
      /** The serialVersionUID */
      private static final long serialVersionUID = 3130309555079841107L;
   
  -   private static final Log log = LogFactory.getLog(ManagedHibernateSession.class);
  +   private static final LogProvider log = Logging.getLogProvider(ManagedHibernateSession.class);
      
      private Session session;
      private String sessionFactoryJndiName;
  
  
  
  1.22      +4 -4      jboss-seam/src/main/org/jboss/seam/core/ManagedJbpmContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedJbpmContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ManagedJbpmContext.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- ManagedJbpmContext.java	14 Dec 2006 13:08:57 -0000	1.21
  +++ ManagedJbpmContext.java	16 Dec 2006 02:58:10 -0000	1.22
  @@ -14,8 +14,8 @@
   import javax.transaction.Synchronization;
   import javax.transaction.SystemException;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
  @@ -36,7 +36,7 @@
    * Manages a reference to a JbpmSession.
    *
    * @author <a href="mailto:steve at hibernate.org">Steve Ebersole </a>
  - * @version $Revision: 1.21 $
  + * @version $Revision: 1.22 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.jbpmContext")
  @@ -44,7 +44,7 @@
   @Install(precedence=BUILT_IN, dependencies="org.jboss.seam.core.jbpm")
   public class ManagedJbpmContext implements Synchronization
   {
  -   private static final Log log = LogFactory.getLog(ManagedJbpmContext.class);
  +   private static final LogProvider log = Logging.getLogProvider(ManagedJbpmContext.class);
   
      private JbpmContext jbpmContext;
      private boolean synchronizationRegistered;
  
  
  
  1.29      +4 -4      jboss-seam/src/main/org/jboss/seam/core/ManagedPersistenceContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedPersistenceContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ManagedPersistenceContext.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- ManagedPersistenceContext.java	18 Nov 2006 00:38:22 -0000	1.28
  +++ ManagedPersistenceContext.java	16 Dec 2006 02:58:10 -0000	1.29
  @@ -1,4 +1,4 @@
  -//$Id: ManagedPersistenceContext.java,v 1.28 2006/11/18 00:38:22 nrichards Exp $
  +//$Id: ManagedPersistenceContext.java,v 1.29 2006/12/16 02:58:10 nrichards Exp $
   package org.jboss.seam.core;
   
   import static org.jboss.seam.InterceptionType.NEVER;
  @@ -14,8 +14,8 @@
   import javax.servlet.http.HttpSessionEvent;
   import javax.transaction.SystemException;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
  @@ -44,7 +44,7 @@
      implements Serializable, HttpSessionActivationListener, Mutable, PersistenceContextManager
   {
   
  -   private static final Log log = LogFactory.getLog(ManagedPersistenceContext.class);
  +   private static final LogProvider log = Logging.getLogProvider(ManagedPersistenceContext.class);
      
      private EntityManager entityManager;
      private String persistenceUnitJndiName;
  
  
  
  1.126     +4 -4      jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.125
  retrieving revision 1.126
  diff -u -b -r1.125 -r1.126
  --- Manager.java	15 Dec 2006 14:30:00 -0000	1.125
  +++ Manager.java	16 Dec 2006 02:58:10 -0000	1.126
  @@ -22,8 +22,8 @@
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseId;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -42,7 +42,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.125 $
  + * @version $Revision: 1.126 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -50,7 +50,7 @@
   @Intercept(NEVER)
   public class Manager
   {
  -   private static final Log log = LogFactory.getLog(Manager.class);
  +   private static final LogProvider log = Logging.getLogProvider(Manager.class);
   
      //The id of the current conversation
      private String currentConversationId;
  
  
  
  1.47      +3 -3      jboss-seam/src/main/org/jboss/seam/core/Pageflow.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pageflow.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pageflow.java,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -b -r1.46 -r1.47
  --- Pageflow.java	15 Dec 2006 14:30:00 -0000	1.46
  +++ Pageflow.java	16 Dec 2006 02:58:10 -0000	1.47
  @@ -11,8 +11,8 @@
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseId;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -45,7 +45,7 @@
   @Install(dependencies="org.jboss.seam.core.jbpm", precedence=BUILT_IN)
   public class Pageflow extends AbstractMutable implements Serializable
   {
  -   private static final Log log = LogFactory.getLog(Pageflow.class);
  +   private static final LogProvider log = Logging.getLogProvider(Pageflow.class);
      
      private int counter;
      
  
  
  
  1.59      +3 -3      jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -b -r1.58 -r1.59
  --- Pages.java	15 Dec 2006 14:30:00 -0000	1.58
  +++ Pages.java	16 Dec 2006 02:58:10 -0000	1.59
  @@ -19,8 +19,8 @@
   import javax.faces.context.FacesContext;
   import javax.faces.convert.Converter;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  @@ -53,7 +53,7 @@
   public class Pages 
   {
      
  -   private static final Log log = LogFactory.getLog(Pages.class);
  +   private static final LogProvider log = Logging.getLogProvider(Pages.class);
      
      private Map<String, Page> pagesByViewId = Collections.synchronizedMap( new HashMap<String, Page>() );   
      private Map<String, List<Page>> pageStacksByViewId = Collections.synchronizedMap( new HashMap<String, List<Page>>() );   
  
  
  
  1.7       +4 -4      jboss-seam/src/main/org/jboss/seam/core/PojoCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/PojoCache.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- PojoCache.java	24 Nov 2006 23:15:17 -0000	1.6
  +++ PojoCache.java	16 Dec 2006 02:58:10 -0000	1.7
  @@ -1,10 +1,10 @@
  -//$Id: PojoCache.java,v 1.6 2006/11/24 23:15:17 gavin Exp $
  +//$Id: PojoCache.java,v 1.7 2006/12/16 02:58:10 nrichards Exp $
   package org.jboss.seam.core;
   
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.cache.PropertyConfigurator;
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptionType;
  @@ -25,7 +25,7 @@
   public class PojoCache 
   {
   
  -   private static final Log log = LogFactory.getLog(PojoCache.class);
  +   private static final LogProvider log = Logging.getLogProvider(PojoCache.class);
   
      private org.jboss.cache.aop.PojoCache cache;
      private String cfgResourceName = "treecache.xml";
  
  
  
  1.24      +3 -3      jboss-seam/src/main/org/jboss/seam/core/ResourceBundle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ResourceBundle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ResourceBundle.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- ResourceBundle.java	27 Nov 2006 03:00:15 -0000	1.23
  +++ ResourceBundle.java	16 Dec 2006 02:58:10 -0000	1.24
  @@ -13,8 +13,8 @@
   import javax.faces.component.UIViewRoot;
   import javax.faces.context.FacesContext;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -36,7 +36,7 @@
   @Install(precedence=BUILT_IN)
   public class ResourceBundle implements Serializable {
      
  -   private static final Log log = LogFactory.getLog(ResourceBundle.class);
  +   private static final LogProvider log = Logging.getLogProvider(ResourceBundle.class);
   
      private String[] bundleNames = {"messages"};
      private transient java.util.ResourceBundle bundle;
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:10 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:10 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/deployment    ...
Message-ID: <E1GvPkY-0004cj-V0@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:10

  Modified:    src/main/org/jboss/seam/deployment    ComponentScanner.java
                        NamespaceScanner.java Scanner.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.5       +3 -3      jboss-seam/src/main/org/jboss/seam/deployment/ComponentScanner.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ComponentScanner.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/deployment/ComponentScanner.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ComponentScanner.java	21 Nov 2006 19:42:31 -0000	1.4
  +++ ComponentScanner.java	16 Dec 2006 02:58:10 -0000	1.5
  @@ -9,12 +9,12 @@
   
   import javassist.bytecode.ClassFile;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   public class ComponentScanner extends Scanner
   {
  -   private static final Log log = LogFactory.getLog(ComponentScanner.class);
  +   private static final LogProvider log = Logging.getLogProvider(ComponentScanner.class);
   
      private Set<Class<Object>> classes;
   
  
  
  
  1.5       +3 -3      jboss-seam/src/main/org/jboss/seam/deployment/NamespaceScanner.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NamespaceScanner.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/deployment/NamespaceScanner.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- NamespaceScanner.java	28 Nov 2006 19:38:33 -0000	1.4
  +++ NamespaceScanner.java	16 Dec 2006 02:58:10 -0000	1.5
  @@ -4,13 +4,13 @@
   import java.util.Set;
   
   import org.jboss.seam.annotations.Namespace;
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   public class NamespaceScanner
       extends Scanner 
   {
  -    private static final Log log = LogFactory.getLog(NamespaceScanner.class);
  +    private static final LogProvider log = Logging.getLogProvider(NamespaceScanner.class);
   
       private Set<Package> packages;
       
  
  
  
  1.22      +4 -4      jboss-seam/src/main/org/jboss/seam/deployment/Scanner.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Scanner.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/deployment/Scanner.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- Scanner.java	6 Dec 2006 15:23:01 -0000	1.21
  +++ Scanner.java	16 Dec 2006 02:58:10 -0000	1.22
  @@ -1,4 +1,4 @@
  -//$Id: Scanner.java,v 1.21 2006/12/06 15:23:01 gavin Exp $
  +//$Id: Scanner.java,v 1.22 2006/12/16 02:58:10 nrichards Exp $
   package org.jboss.seam.deployment;
   
   import java.io.DataInputStream;
  @@ -17,12 +17,12 @@
   import javassist.bytecode.ClassFile;
   import javassist.bytecode.annotation.MemberValue;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   public abstract class Scanner
   {
  -    private static final Log log = LogFactory.getLog(Scanner.class);
  +    private static final LogProvider log = Logging.getLogProvider(Scanner.class);
   
       protected  String resourceName;
       protected  ClassLoader classLoader;
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:11 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/init  ...
Message-ID: <E1GvPkZ-0004cq-3F@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:11

  Modified:    src/main/org/jboss/seam/init  Initialization.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.133     +4 -4      jboss-seam/src/main/org/jboss/seam/init/Initialization.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Initialization.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/init/Initialization.java,v
  retrieving revision 1.132
  retrieving revision 1.133
  diff -u -b -r1.132 -r1.133
  --- Initialization.java	15 Dec 2006 04:42:41 -0000	1.132
  +++ Initialization.java	16 Dec 2006 02:58:11 -0000	1.133
  @@ -20,8 +20,8 @@
   
   import javax.servlet.ServletContext;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Attribute;
   import org.dom4j.Document;
   import org.dom4j.DocumentException;
  @@ -57,12 +57,12 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.132 $
  + * @version $Revision: 1.133 $
    */
   public class Initialization
   {
      public static final String COMPONENT_SUFFIX = ".component";
  -   private static final Log log = LogFactory.getLog(Initialization.class);
  +   private static final LogProvider log = Logging.getLogProvider(Initialization.class);
   
      private ServletContext servletContext;
      private Map<String, Conversions.PropertyValue> properties = new HashMap<String, Conversions.PropertyValue>();
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:11 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/intercept   ...
Message-ID: <E1GvPkZ-0004d0-8m@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:11

  Modified:    src/main/org/jboss/seam/intercept   RootInterceptor.java
                        SessionBeanInterceptor.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.7       +3 -3      jboss-seam/src/main/org/jboss/seam/intercept/RootInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RootInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/RootInterceptor.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- RootInterceptor.java	1 Nov 2006 02:54:02 -0000	1.6
  +++ RootInterceptor.java	16 Dec 2006 02:58:11 -0000	1.7
  @@ -9,8 +9,8 @@
   import java.io.Serializable;
   import java.util.List;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.Seam;
  @@ -26,7 +26,7 @@
   public class RootInterceptor implements Serializable
   {
      
  -   private static final Log log = LogFactory.getLog(RootInterceptor.class);
  +   private static final LogProvider log = Logging.getLogProvider(RootInterceptor.class);
      
      private final InterceptorType type;
      private boolean isSeamComponent;
  
  
  
  1.10      +3 -3      jboss-seam/src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SessionBeanInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- SessionBeanInterceptor.java	14 Nov 2006 01:47:16 -0000	1.9
  +++ SessionBeanInterceptor.java	16 Dec 2006 02:58:11 -0000	1.10
  @@ -13,8 +13,8 @@
   import javax.interceptor.AroundInvoke;
   import javax.interceptor.InvocationContext;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.Seam;
  @@ -28,7 +28,7 @@
    */
   public class SessionBeanInterceptor extends RootInterceptor
   {
  -   private static final Log log = LogFactory.getLog(SessionBeanInterceptor.class);
  +   private static final LogProvider log = Logging.getLogProvider(SessionBeanInterceptor.class);
      
      public static ThreadLocal<Component> COMPONENT = new ThreadLocal<Component>();
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:11 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors      ...
Message-ID: <E1GvPkZ-0004dJ-EC@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:11

  Modified:    src/main/org/jboss/seam/interceptors     
                        BijectionInterceptor.java
                        BusinessProcessInterceptor.java
                        ConversationalInterceptor.java
                        RemoveInterceptor.java ValidationInterceptor.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.24      +4 -4      jboss-seam/src/main/org/jboss/seam/interceptors/BijectionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BijectionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/BijectionInterceptor.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- BijectionInterceptor.java	1 Nov 2006 02:54:02 -0000	1.23
  +++ BijectionInterceptor.java	16 Dec 2006 02:58:11 -0000	1.24
  @@ -1,4 +1,4 @@
  -//$Id: BijectionInterceptor.java,v 1.23 2006/11/01 02:54:02 gavin Exp $
  +//$Id: BijectionInterceptor.java,v 1.24 2006/12/16 02:58:11 nrichards Exp $
   package org.jboss.seam.interceptors;
   
   import static org.jboss.seam.util.EJB.POST_ACTIVATE;
  @@ -8,8 +8,8 @@
   
   import java.lang.reflect.Method;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Create;
   import org.jboss.seam.annotations.Destroy;
  @@ -26,7 +26,7 @@
   public class BijectionInterceptor extends AbstractInterceptor
   {
      
  -   private static final Log log = LogFactory.getLog(BijectionInterceptor.class);
  +   private static final LogProvider log = Logging.getLogProvider(BijectionInterceptor.class);
      
      private static boolean isLifecycleMethod(Method method)
      {
  
  
  
  1.47      +4 -4      jboss-seam/src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcessInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -b -r1.46 -r1.47
  --- BusinessProcessInterceptor.java	1 Nov 2006 02:54:02 -0000	1.46
  +++ BusinessProcessInterceptor.java	16 Dec 2006 02:58:11 -0000	1.47
  @@ -13,8 +13,8 @@
   
   import javax.faces.context.FacesContext;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.BeginTask;
   import org.jboss.seam.annotations.CreateProcess;
  @@ -29,14 +29,14 @@
    * Interceptor which handles interpretation of jBPM-related annotations.
    *
    * @author <a href="mailto:steve at hibernate.org">Steve Ebersole </a>
  - * @version $Revision: 1.46 $
  + * @version $Revision: 1.47 $
    */
   @Interceptor(stateless=true,
                around={ValidationInterceptor.class, BijectionInterceptor.class, OutcomeInterceptor.class})
   public class BusinessProcessInterceptor extends AbstractInterceptor
   {
      
  -   private static final Log log = LogFactory.getLog( BusinessProcessInterceptor.class );
  +   private static final LogProvider log = Logging.getLogProvider( BusinessProcessInterceptor.class );
   
      @AroundInvoke
      public Object manageBusinessProcessContext(InvocationContext invocation) throws Exception
  
  
  
  1.11      +4 -4      jboss-seam/src/main/org/jboss/seam/interceptors/ConversationalInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationalInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ConversationalInterceptor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ConversationalInterceptor.java	17 Nov 2006 07:12:56 -0000	1.10
  +++ ConversationalInterceptor.java	16 Dec 2006 02:58:11 -0000	1.11
  @@ -1,4 +1,4 @@
  -//$Id: ConversationalInterceptor.java,v 1.10 2006/11/17 07:12:56 gavin Exp $
  +//$Id: ConversationalInterceptor.java,v 1.11 2006/12/16 02:58:11 nrichards Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -6,8 +6,8 @@
   import javax.faces.application.FacesMessage;
   import javax.faces.event.PhaseId;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Begin;
   import org.jboss.seam.annotations.BeginTask;
  @@ -32,7 +32,7 @@
   public class ConversationalInterceptor extends AbstractInterceptor
   {
   
  -   private static final Log log = LogFactory.getLog(ConversationalInterceptor.class);
  +   private static final LogProvider log = Logging.getLogProvider(ConversationalInterceptor.class);
   
      @AroundInvoke
      public Object checkConversationForConversationalBean(InvocationContext invocation) throws Exception
  
  
  
  1.18      +4 -4      jboss-seam/src/main/org/jboss/seam/interceptors/RemoveInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/RemoveInterceptor.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- RemoveInterceptor.java	4 Nov 2006 01:58:24 -0000	1.17
  +++ RemoveInterceptor.java	16 Dec 2006 02:58:11 -0000	1.18
  @@ -1,4 +1,4 @@
  -//$Id: RemoveInterceptor.java,v 1.17 2006/11/04 01:58:24 gavin Exp $
  +//$Id: RemoveInterceptor.java,v 1.18 2006/12/16 02:58:11 nrichards Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -7,8 +7,8 @@
   import javax.ejb.ApplicationException;
   import javax.ejb.Remove;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
  @@ -25,7 +25,7 @@
   public class RemoveInterceptor extends AbstractInterceptor
   {
      
  -   private static final Log log = LogFactory.getLog(RemoveInterceptor.class);
  +   private static final LogProvider log = Logging.getLogProvider(RemoveInterceptor.class);
   
      @AroundInvoke
      public Object removeIfNecessary(InvocationContext invocation) throws Exception
  
  
  
  1.24      +4 -4      jboss-seam/src/main/org/jboss/seam/interceptors/ValidationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ValidationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ValidationInterceptor.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- ValidationInterceptor.java	1 Nov 2006 02:54:02 -0000	1.23
  +++ ValidationInterceptor.java	16 Dec 2006 02:58:11 -0000	1.24
  @@ -1,4 +1,4 @@
  -//$Id: ValidationInterceptor.java,v 1.23 2006/11/01 02:54:02 gavin Exp $
  +//$Id: ValidationInterceptor.java,v 1.24 2006/12/16 02:58:11 nrichards Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -6,8 +6,8 @@
   import javax.persistence.Entity;
   import javax.persistence.EntityManager;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.hibernate.Session;
   import org.hibernate.validator.InvalidValue;
   import org.jboss.seam.Component;
  @@ -31,7 +31,7 @@
   public class ValidationInterceptor extends AbstractInterceptor
   {
   
  -   private static final Log log = LogFactory.getLog(ValidationInterceptor.class);
  +   private static final LogProvider log = Logging.getLogProvider(ValidationInterceptor.class);
   
      @AroundInvoke
      public Object validateTargetComponent(InvocationContext invocation) throws Exception
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:11 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf     ...
Message-ID: <E1GvPkZ-0004dZ-J5@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:11

  Modified:    src/main/org/jboss/seam/jsf    
                        AbstractSeamPhaseListener.java
                        SeamPhaseListener.java
                        SeamPortletPhaseListener.java
                        SeamVariableResolver.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.30      +3 -3      jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- AbstractSeamPhaseListener.java	29 Nov 2006 14:27:08 -0000	1.29
  +++ AbstractSeamPhaseListener.java	16 Dec 2006 02:58:11 -0000	1.30
  @@ -12,8 +12,8 @@
   import javax.faces.event.PhaseListener;
   import javax.faces.model.DataModel;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Seam;
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.ContextAdaptor;
  @@ -34,7 +34,7 @@
   public abstract class AbstractSeamPhaseListener implements PhaseListener
   {
      
  -   private static final Log log = LogFactory.getLog(AbstractSeamPhaseListener.class);
  +   private static final LogProvider log = Logging.getLogProvider(AbstractSeamPhaseListener.class);
      
      public PhaseId getPhaseId()
      {
  
  
  
  1.94      +3 -3      jboss-seam/src/main/org/jboss/seam/jsf/SeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamPhaseListener.java,v
  retrieving revision 1.93
  retrieving revision 1.94
  diff -u -b -r1.93 -r1.94
  --- SeamPhaseListener.java	16 Nov 2006 15:51:29 -0000	1.93
  +++ SeamPhaseListener.java	16 Dec 2006 02:58:11 -0000	1.94
  @@ -14,8 +14,8 @@
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseEvent;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.core.FacesMessages;
   
  @@ -30,7 +30,7 @@
   public class SeamPhaseListener extends AbstractSeamPhaseListener
   {
   
  -   private static final Log log = LogFactory.getLog(SeamPhaseListener.class);
  +   private static final LogProvider log = Logging.getLogProvider(SeamPhaseListener.class);
      
      @Override
      public void beforePhase(PhaseEvent event)
  
  
  
  1.17      +3 -3      jboss-seam/src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamPortletPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- SeamPortletPhaseListener.java	25 Nov 2006 01:15:16 -0000	1.16
  +++ SeamPortletPhaseListener.java	16 Dec 2006 02:58:11 -0000	1.17
  @@ -15,8 +15,8 @@
   import javax.faces.event.PhaseEvent;
   import javax.portlet.ActionResponse;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.core.FacesMessages;
   import org.jboss.seam.core.Manager;
  @@ -33,7 +33,7 @@
   public class SeamPortletPhaseListener extends AbstractSeamPhaseListener
   {
   
  -   private static final Log log = LogFactory.getLog( SeamPortletPhaseListener.class );
  +   private static final LogProvider log = Logging.getLogProvider( SeamPortletPhaseListener.class );
   
      @Override
      public void beforePhase(PhaseEvent event)
  
  
  
  1.18      +4 -4      jboss-seam/src/main/org/jboss/seam/jsf/SeamVariableResolver.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamVariableResolver.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamVariableResolver.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- SeamVariableResolver.java	30 Nov 2006 02:09:11 -0000	1.17
  +++ SeamVariableResolver.java	16 Dec 2006 02:58:11 -0000	1.18
  @@ -11,8 +11,8 @@
   import javax.faces.el.EvaluationException;
   import javax.faces.el.VariableResolver;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.core.Init;
   
  @@ -23,12 +23,12 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class SeamVariableResolver extends VariableResolver
   {
   
  -   private static final Log log = LogFactory.getLog(SeamVariableResolver.class);
  +   private static final LogProvider log = Logging.getLogProvider(SeamVariableResolver.class);
   
      private VariableResolver jsfVariableResolver;
      
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:11 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/log  ...
Message-ID: <E1GvPkZ-0004dg-MS@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:11

  Modified:    src/main/org/jboss/seam/log  Logging.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.2       +5 -0      jboss-seam/src/main/org/jboss/seam/log/Logging.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Logging.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/log/Logging.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Logging.java	16 Dec 2006 02:16:28 -0000	1.1
  +++ Logging.java	16 Dec 2006 02:58:11 -0000	1.2
  @@ -37,4 +37,9 @@
                  new JDKProvider(category);
      }
      
  +   public static LogProvider getLogProvider(Class clazz)
  +   {
  +       return getLogProvider(clazz.getName());
  +   }
  +   
   }
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:11 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/microcontainer   ...
Message-ID: <E1GvPkZ-0004dq-Qx@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:11

  Modified:    src/main/org/jboss/seam/microcontainer  
                        DataSourceFactory.java
                        TransactionManagerFactory.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.9       +4 -4      jboss-seam/src/main/org/jboss/seam/microcontainer/DataSourceFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataSourceFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/microcontainer/DataSourceFactory.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- DataSourceFactory.java	15 Apr 2006 22:28:05 -0000	1.8
  +++ DataSourceFactory.java	16 Dec 2006 02:58:11 -0000	1.9
  @@ -1,10 +1,10 @@
  -//$Id: DataSourceFactory.java,v 1.8 2006/04/15 22:28:05 gavin Exp $
  +//$Id: DataSourceFactory.java,v 1.9 2006/12/16 02:58:11 nrichards Exp $
   package org.jboss.seam.microcontainer;
   
   import javax.transaction.TransactionManager;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.resource.adapter.jdbc.local.LocalTxDataSource;
   import org.jboss.resource.connectionmanager.CachedConnectionManager;
   import org.jboss.resource.connectionmanager.CachedConnectionManagerReference;
  @@ -17,7 +17,7 @@
    */
   public class DataSourceFactory
   {
  -   private static final Log log = LogFactory.getLog(DataSourceFactory.class);
  +   private static final LogProvider log = Logging.getLogProvider(DataSourceFactory.class);
      
      private LocalTxDataSource ds;
      
  
  
  
  1.13      +4 -4      jboss-seam/src/main/org/jboss/seam/microcontainer/TransactionManagerFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionManagerFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/microcontainer/TransactionManagerFactory.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- TransactionManagerFactory.java	25 Oct 2006 23:55:13 -0000	1.12
  +++ TransactionManagerFactory.java	16 Dec 2006 02:58:11 -0000	1.13
  @@ -1,11 +1,11 @@
  -//$Id: TransactionManagerFactory.java,v 1.12 2006/10/25 23:55:13 gavin Exp $
  +//$Id: TransactionManagerFactory.java,v 1.13 2006/12/16 02:58:11 nrichards Exp $
   package org.jboss.seam.microcontainer;
   
   import javax.naming.InitialContext;
   import javax.transaction.TransactionManager;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.resource.connectionmanager.TransactionSynchronizer;
   import org.jboss.seam.util.Naming;
   import org.jboss.seam.util.Transactions;
  @@ -21,7 +21,7 @@
   public class TransactionManagerFactory
   {
      
  -   private static final Log log = LogFactory.getLog(TransactionManagerFactory.class);
  +   private static final LogProvider log = Logging.getLogProvider(TransactionManagerFactory.class);
   
      public TransactionManager getTransactionManager() throws Exception
      {
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pageflow  ...
Message-ID: <E1GvPka-0004dx-28@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/pageflow  PageflowHelper.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.2       +3 -3      jboss-seam/src/main/org/jboss/seam/pageflow/PageflowHelper.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PageflowHelper.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pageflow/PageflowHelper.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- PageflowHelper.java	30 Jun 2006 10:58:25 -0000	1.1
  +++ PageflowHelper.java	16 Dec 2006 02:58:12 -0000	1.2
  @@ -3,8 +3,8 @@
   import java.io.InputStream;
   import java.io.StringReader;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jbpm.JbpmConfiguration;
   import org.jbpm.JbpmContext;
   import org.jbpm.graph.def.ProcessDefinition;
  @@ -60,5 +60,5 @@
       }
     }
     
  -  private static Log log = LogFactory.getLog(PageflowHelper.class);
  +  private static LogProvider log = Logging.getLogProvider(PageflowHelper.class);
   }
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/remoting     ...
Message-ID: <E1GvPka-0004eD-7R@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/remoting     ExecutionHandler.java
                        InterfaceGenerator.java PollHandler.java
                        SeamRemotingServlet.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.20      +3 -3      jboss-seam/src/main/org/jboss/seam/remoting/ExecutionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExecutionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/ExecutionHandler.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- ExecutionHandler.java	17 Nov 2006 16:50:44 -0000	1.19
  +++ ExecutionHandler.java	16 Dec 2006 02:58:12 -0000	1.20
  @@ -12,8 +12,8 @@
   import javax.servlet.http.HttpServletResponse;
   import javax.servlet.http.HttpSession;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  @@ -30,7 +30,7 @@
    */
   public class ExecutionHandler extends BaseRequestHandler implements RequestHandler
   {
  -   private static final Log log = LogFactory.getLog(ExecutionHandler.class);
  +   private static final LogProvider log = Logging.getLogProvider(ExecutionHandler.class);
   
     private static final byte[] HEADER_OPEN = "<header>".getBytes();
     private static final byte[] HEADER_CLOSE = "</header>".getBytes();
  
  
  
  1.26      +3 -3      jboss-seam/src/main/org/jboss/seam/remoting/InterfaceGenerator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InterfaceGenerator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/InterfaceGenerator.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- InterfaceGenerator.java	1 Nov 2006 01:52:09 -0000	1.25
  +++ InterfaceGenerator.java	16 Dec 2006 02:58:12 -0000	1.26
  @@ -23,8 +23,8 @@
   import javax.servlet.http.HttpServletResponse;
   import javax.servlet.http.HttpSession;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ComponentType;
   import org.jboss.seam.Seam;
  @@ -41,7 +41,7 @@
    */
   public class InterfaceGenerator extends BaseRequestHandler implements RequestHandler
   {
  -   private static final Log log = LogFactory.getLog(InterfaceGenerator.class);
  +   private static final LogProvider log = Logging.getLogProvider(InterfaceGenerator.class);
   
     /**
      * Maintain a cache of the accessible fields
  
  
  
  1.9       +3 -3      jboss-seam/src/main/org/jboss/seam/remoting/PollHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PollHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/PollHandler.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- PollHandler.java	25 Oct 2006 15:14:36 -0000	1.8
  +++ PollHandler.java	16 Dec 2006 02:58:12 -0000	1.9
  @@ -14,8 +14,8 @@
   import javax.servlet.http.HttpServletResponse;
   import javax.servlet.http.HttpSession;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  @@ -31,7 +31,7 @@
    */
   public class PollHandler extends BaseRequestHandler implements RequestHandler
   {
  -  private static final Log log = LogFactory.getLog(SubscriptionHandler.class);
  +  private static final LogProvider log = Logging.getLogProvider(SubscriptionHandler.class);
   
     private static final byte[] ERRORS_TAG_OPEN_START = "<errors token=\"".getBytes();
     private static final byte[] ERRORS_TAG_OPEN_END = "\">".getBytes();
  
  
  
  1.12      +3 -3      jboss-seam/src/main/org/jboss/seam/remoting/SeamRemotingServlet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamRemotingServlet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/SeamRemotingServlet.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SeamRemotingServlet.java	25 Oct 2006 15:14:36 -0000	1.11
  +++ SeamRemotingServlet.java	16 Dec 2006 02:58:12 -0000	1.12
  @@ -14,8 +14,8 @@
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpServletResponse;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.servlet.SeamServletFilter;
   import javax.servlet.http.HttpSession;
  @@ -28,7 +28,7 @@
    */
   public class SeamRemotingServlet extends HttpServlet
   {
  -  private static final Log log = LogFactory.getLog(SeamServletFilter.class);
  +  private static final LogProvider log = Logging.getLogProvider(SeamServletFilter.class);
   
     private static final Pattern pathPattern = Pattern.compile("/(.*?)/([^/]+)");
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/remoting/messaging ...
Message-ID: <E1GvPka-0004eK-Bc@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/remoting/messaging 
                        SubscriptionRegistry.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.12      +3 -3      jboss-seam/src/main/org/jboss/seam/remoting/messaging/SubscriptionRegistry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SubscriptionRegistry.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/messaging/SubscriptionRegistry.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SubscriptionRegistry.java	24 Nov 2006 23:15:19 -0000	1.11
  +++ SubscriptionRegistry.java	16 Dec 2006 02:58:12 -0000	1.12
  @@ -13,8 +13,8 @@
   import javax.jms.JMSException;
   import javax.jms.TopicConnection;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -41,7 +41,7 @@
     public static final String CONTEXT_USER_TOKENS =
         "org.jboss.seam.remoting.messaging.SubscriptionRegistry.userTokens";
   
  -  private static final Log log = LogFactory.getLog(SubscriptionRegistry.class);
  +  private static final LogProvider log = Logging.getLogProvider(SubscriptionRegistry.class);
   
     private String connectionProvider;
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GvPka-0004eR-GE@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.27      +3 -3      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- SeamSecurityManager.java	15 Dec 2006 04:13:16 -0000	1.26
  +++ SeamSecurityManager.java	16 Dec 2006 02:58:12 -0000	1.27
  @@ -9,8 +9,8 @@
   import java.util.Map;
   import java.util.Set;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.drools.FactHandle;
   import org.drools.RuleBase;
   import org.drools.RuleBaseFactory;
  @@ -50,7 +50,7 @@
   
     private static final String SECURITY_CONTEXT_NAME = "org.jboss.seam.security.securityContext";
   
  -  private static final Log log = LogFactory.getLog(SeamSecurityManager.class);
  +  private static final LogProvider log = Logging.getLogProvider(SeamSecurityManager.class);
   
     private RuleBase securityRules;
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1GvPka-0004eY-KS@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/security/config 
                        SecurityConfiguration.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.6       +3 -3      jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- SecurityConfiguration.java	15 Dec 2006 13:36:44 -0000	1.5
  +++ SecurityConfiguration.java	16 Dec 2006 02:58:12 -0000	1.6
  @@ -7,8 +7,8 @@
   import java.util.Map;
   import java.util.Set;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  @@ -39,7 +39,7 @@
   {
     private static final String SECURITY_CONFIG_FILENAME = "/META-INF/security-config.xml";
   
  -  private static final Log log = LogFactory.getLog(SecurityConfiguration.class);
  +  private static final LogProvider log = Logging.getLogProvider(SecurityConfiguration.class);
   
     // <security-constraint>
     private static final String SECURITY_CONSTRAINT = "security-constraint";
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/filter  ...
Message-ID: <E1GvPka-0004ef-Ok@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/security/filter 
                        SeamSecurityFilter.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.15      +3 -3      jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- SeamSecurityFilter.java	15 Dec 2006 13:36:44 -0000	1.14
  +++ SeamSecurityFilter.java	16 Dec 2006 02:58:12 -0000	1.15
  @@ -11,8 +11,8 @@
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpServletResponse;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Seam;
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.ContextAdaptor;
  @@ -30,7 +30,7 @@
    */
   public class SeamSecurityFilter implements Filter
   {
  -  private static final Log log = LogFactory.getLog(SeamSecurityFilter.class);
  +  private static final LogProvider log = Logging.getLogProvider(SeamSecurityFilter.class);
   
     private SecurityConfiguration config;
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:12 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/servlet    ...
Message-ID: <E1GvPka-0004es-TN@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:12

  Modified:    src/main/org/jboss/seam/servlet    SeamExceptionFilter.java
                        SeamListener.java SeamServletFilter.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.21      +3 -3      jboss-seam/src/main/org/jboss/seam/servlet/SeamExceptionFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamExceptionFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/servlet/SeamExceptionFilter.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- SeamExceptionFilter.java	29 Nov 2006 12:51:33 -0000	1.20
  +++ SeamExceptionFilter.java	16 Dec 2006 02:58:12 -0000	1.21
  @@ -17,8 +17,8 @@
   import javax.servlet.ServletResponse;
   import javax.servlet.http.HttpServletRequest;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.util.Transactions;
   
  @@ -31,7 +31,7 @@
   public class SeamExceptionFilter implements Filter
   {
      
  -   private static final Log log = LogFactory.getLog(SeamExceptionFilter.class);
  +   private static final LogProvider log = Logging.getLogProvider(SeamExceptionFilter.class);
      private ServletContext context;
   
      public void init(FilterConfig cfg) throws ServletException {
  
  
  
  1.20      +3 -3      jboss-seam/src/main/org/jboss/seam/servlet/SeamListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/servlet/SeamListener.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- SeamListener.java	13 Dec 2006 10:10:43 -0000	1.19
  +++ SeamListener.java	16 Dec 2006 02:58:12 -0000	1.20
  @@ -11,8 +11,8 @@
   import javax.servlet.http.HttpSessionEvent;
   import javax.servlet.http.HttpSessionListener;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.init.Initialization;
   
  @@ -25,7 +25,7 @@
   public class SeamListener implements ServletContextListener, HttpSessionListener
   {
   
  -   private static final Log log = LogFactory.getLog(ServletContextListener.class);
  +   private static final LogProvider log = Logging.getLogProvider(ServletContextListener.class);
   
      public void contextInitialized(ServletContextEvent event) {
         log.info("Welcome to Seam 1.1.0.GA");
  
  
  
  1.11      +3 -3      jboss-seam/src/main/org/jboss/seam/servlet/SeamServletFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamServletFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/servlet/SeamServletFilter.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- SeamServletFilter.java	3 Nov 2006 22:47:25 -0000	1.10
  +++ SeamServletFilter.java	16 Dec 2006 02:58:12 -0000	1.11
  @@ -13,8 +13,8 @@
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpSession;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.contexts.ContextAdaptor;
   import org.jboss.seam.core.Manager;
  @@ -27,7 +27,7 @@
    */
   public class SeamServletFilter implements Filter {
      
  -   private static final Log log = LogFactory.getLog(SeamServletFilter.class);
  +   private static final LogProvider log = Logging.getLogProvider(SeamServletFilter.class);
      
      private ServletContext servletContext;
   
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:13 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:13 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/theme  ...
Message-ID: <E1GvPkb-0004ez-1h@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:13

  Modified:    src/main/org/jboss/seam/theme  ThemeSelector.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.9       +3 -3      jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThemeSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ThemeSelector.java	26 Nov 2006 03:22:59 -0000	1.8
  +++ ThemeSelector.java	16 Dec 2006 02:58:13 -0000	1.9
  @@ -15,8 +15,8 @@
   import javax.servlet.http.Cookie;
   import javax.servlet.http.HttpServletResponse;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -40,7 +40,7 @@
   @Install(precedence=BUILT_IN)
   public class ThemeSelector extends AbstractMutable implements Serializable
   {
  -   private static final Log log = LogFactory.getLog(ThemeSelector.class);
  +   private static final LogProvider log = Logging.getLogProvider(ThemeSelector.class);
      
      private String theme;
      private String[] availableThemes;
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:13 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:13 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util    ...
Message-ID: <E1GvPkb-0004fC-7B@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:13

  Modified:    src/main/org/jboss/seam/util    DTDEntityResolver.java
                        Naming.java Work.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.2       +4 -4      jboss-seam/src/main/org/jboss/seam/util/DTDEntityResolver.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DTDEntityResolver.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/DTDEntityResolver.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- DTDEntityResolver.java	10 Nov 2006 19:07:01 -0000	1.1
  +++ DTDEntityResolver.java	16 Dec 2006 02:58:13 -0000	1.2
  @@ -1,12 +1,12 @@
  -//$Id: DTDEntityResolver.java,v 1.1 2006/11/10 19:07:01 gavin Exp $
  +//$Id: DTDEntityResolver.java,v 1.2 2006/12/16 02:58:13 nrichards Exp $
   //Contributed by Markus Meissner
   package org.jboss.seam.util;
   
   import java.io.InputStream;
   import java.io.Serializable;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.xml.sax.EntityResolver;
   import org.xml.sax.InputSource;
   
  @@ -28,7 +28,7 @@
    */
   public class DTDEntityResolver implements EntityResolver, Serializable {
   
  -	private static final Log log = LogFactory.getLog( DTDEntityResolver.class );
  +	private static final LogProvider log = Logging.getLogProvider(DTDEntityResolver.class );
   
   	private static final String HIBERNATE_NAMESPACE = "http://jboss.com/products/seam/";
   	private static final String USER_NAMESPACE = "classpath://";
  
  
  
  1.5       +3 -3      jboss-seam/src/main/org/jboss/seam/util/Naming.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Naming.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Naming.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- Naming.java	20 Jun 2006 10:51:38 -0000	1.4
  +++ Naming.java	16 Dec 2006 02:58:13 -0000	1.5
  @@ -11,12 +11,12 @@
   import javax.naming.InitialContext;
   import javax.naming.NamingException;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   public final class Naming {
      
  -    private static final Log log = LogFactory.getLog(Naming.class);
  +    private static final LogProvider log = Logging.getLogProvider(Naming.class);
       private static Hashtable initialContextProperties;
   
       public static InitialContext getInitialContext(Hashtable<String, String> props) throws NamingException {
  
  
  
  1.2       +3 -3      jboss-seam/src/main/org/jboss/seam/util/Work.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Work.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Work.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Work.java	15 Oct 2006 16:30:45 -0000	1.1
  +++ Work.java	16 Dec 2006 02:58:13 -0000	1.2
  @@ -2,12 +2,12 @@
   
   import javax.transaction.UserTransaction;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   public abstract class Work<T>
   {
  -   private static final Log log = LogFactory.getLog(Work.class);
  +   private static final LogProvider log = Logging.getLogProvider(Work.class);
      
      protected abstract T work() throws Exception;
      
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:13 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:13 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui  ...
Message-ID: <E1GvPkb-0004fJ-BJ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:13

  Modified:    src/ui/org/jboss/seam/ui  UICache.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.6       +3 -3      jboss-seam/src/ui/org/jboss/seam/ui/UICache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UICache.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/UICache.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- UICache.java	14 Nov 2006 03:47:35 -0000	1.5
  +++ UICache.java	16 Dec 2006 02:58:13 -0000	1.6
  @@ -8,15 +8,15 @@
   import javax.faces.context.ResponseWriter;
   import javax.faces.el.ValueBinding;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.cache.CacheException;
   import org.jboss.seam.core.PojoCache;
   
   public class UICache extends UIComponentBase
   {
      
  -   private static final Log log = LogFactory.getLog(UICache.class);
  +   private static final LogProvider log = Logging.getLogProvider(UICache.class);
      
      public static final String COMPONENT_FAMILY = "org.jboss.seam.ui.Cache";
      public static final String COMPONENT_TYPE = "org.jboss.seam.ui.UICache";
  
  
  


From norman.richards at jboss.com  Fri Dec 15 21:58:13 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 15 Dec 2006 21:58:13 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui/tag     ...
Message-ID: <E1GvPkb-0004fZ-KR@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/15 21:58:13

  Modified:    src/ui/org/jboss/seam/ui/tag    
                        HtmlComponentBodyTagBase.java
                        HtmlMessageTagBase.java UIComponentBodyTagBase.java
                        UIComponentTagBase.java
  Log:
  update logging
  
  Revision  Changes    Path
  1.3       +2 -2      jboss-seam/src/ui/org/jboss/seam/ui/tag/HtmlComponentBodyTagBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlComponentBodyTagBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/HtmlComponentBodyTagBase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- HtmlComponentBodyTagBase.java	25 Oct 2006 15:37:37 -0000	1.2
  +++ HtmlComponentBodyTagBase.java	16 Dec 2006 02:58:13 -0000	1.3
  @@ -20,13 +20,13 @@
   import org.jboss.seam.ui.HTML;
   
   /**
  - * @author Manfred Geiler (latest modification by $Author: gavin $)
  - * @version $Revision: 1.2 $ $Date: 2006/10/25 15:37:37 $
  + * @author Manfred Geiler (latest modification by $Author: nrichards $)
  + * @version $Revision: 1.3 $ $Date: 2006/12/16 02:58:13 $
    */
   public abstract class HtmlComponentBodyTagBase
           extends UIComponentBodyTagBase
   {
  -    //private static final Log log = LogFactory.getLog(HtmlComponentTag.class);
  +    //private static final LogProvider log = Logging.getLogProvider(HtmlComponentTag.class);
   
       //HTML universal attributes
       private String _dir;
  
  
  
  1.3       +2 -2      jboss-seam/src/ui/org/jboss/seam/ui/tag/HtmlMessageTagBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlMessageTagBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/HtmlMessageTagBase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- HtmlMessageTagBase.java	25 Oct 2006 15:37:37 -0000	1.2
  +++ HtmlMessageTagBase.java	16 Dec 2006 02:58:13 -0000	1.3
  @@ -20,13 +20,13 @@
   import org.jboss.seam.ui.JSF;
   
   /**
  - * @author Manfred Geiler (latest modification by $Author: gavin $)
  - * @version $Revision: 1.2 $ $Date: 2006/10/25 15:37:37 $
  + * @author Manfred Geiler (latest modification by $Author: nrichards $)
  + * @version $Revision: 1.3 $ $Date: 2006/12/16 02:58:13 $
    */
   public abstract class HtmlMessageTagBase
           extends HtmlComponentTagBase
   {
  -    //private static final Log log = LogFactory.getLog(HtmlOutputFormatTag.class);
  +    //private static final LogProvider log = Logging.getLogProvider(HtmlOutputFormatTag.class);
   
       // UIComponent attributes --> already implemented in UIComponentTagBase
   
  
  
  
  1.3       +4 -6      jboss-seam/src/ui/org/jboss/seam/ui/tag/UIComponentBodyTagBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIComponentBodyTagBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/UIComponentBodyTagBase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIComponentBodyTagBase.java	25 Oct 2006 15:37:37 -0000	1.2
  +++ UIComponentBodyTagBase.java	16 Dec 2006 02:58:13 -0000	1.3
  @@ -1,7 +1,5 @@
   /*
  - * Copyright 2004 The Apache Software Foundation.
    *
  - * Licensed under the Apache License, Version 2.0 (the "License");
    * you may not use this file except in compliance with the License.
    * You may obtain a copy of the License at
    *
  @@ -23,17 +21,17 @@
   import javax.servlet.jsp.JspException;
   import javax.servlet.jsp.tagext.BodyContent;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   /**
  - * @author Manfred Geiler (latest modification by $Author: gavin $)
  - * @version $Revision: 1.2 $ $Date: 2005-05-11 12:45:06 -0400 (Wed, 11 May
  + * @author Manfred Geiler (latest modification by $Author: nrichards $)
  + * @version $Revision: 1.3 $ $Date: 2005-05-11 12:45:06 -0400 (Wed, 11 May
    *          2005) $
    */
   public abstract class UIComponentBodyTagBase extends UIComponentBodyTag
   {
  -   private static final Log log = LogFactory.getLog(UIComponentBodyTagBase.class);
  +   private static final LogProvider log = Logging.getLogProvider(UIComponentBodyTagBase.class);
   
      @Override
      public int doEndTag() throws JspException
  
  
  
  1.9       +4 -4      jboss-seam/src/ui/org/jboss/seam/ui/tag/UIComponentTagBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIComponentTagBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/tag/UIComponentTagBase.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- UIComponentTagBase.java	14 Dec 2006 08:52:18 -0000	1.8
  +++ UIComponentTagBase.java	16 Dec 2006 02:58:13 -0000	1.9
  @@ -31,17 +31,17 @@
   import javax.faces.event.ValueChangeEvent;
   import javax.faces.webapp.UIComponentTag;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.ui.JSF;
   
   /**
  - * @author Manfred Geiler (latest modification by $Author: gavin $)
  - * @version $Revision: 1.8 $ $Date: 2006/12/14 08:52:18 $
  + * @author Manfred Geiler (latest modification by $Author: nrichards $)
  + * @version $Revision: 1.9 $ $Date: 2006/12/16 02:58:13 $
    */
   public abstract class UIComponentTagBase extends UIComponentTag
   {
  -   private static final Log log = LogFactory.getLog(UIComponentTagBase.class);
  +   private static final LogProvider log = Logging.getLogProvider(UIComponentTagBase.class);
   
      // Special UIComponent attributes (ValueHolder, ConvertibleValueHolder)
      private String _value;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 15 23:28:02 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 15 Dec 2006 23:28:02 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1804 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/state src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/endpoint src/main/org/jboss/jms/tx
	src/main/org/jboss/messaging/core/plugin/postoffice
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests tests/bin
	tests/src/org/jboss/test/messaging/core/plugin/postoffice
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
	tests/src/org/jboss/test/messaging/tools
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
	tests/src/org/jboss/test/messaging/tools/jndi
	tests/src/org/jboss/test/messaging/util
Message-ID: <E1GvR9W-0006Id-5x@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-15 23:27:46 -0500 (Fri, 15 Dec 2006)
New Revision: 1804

Added:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ClusterEventNotificationListener.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/LargeClusterTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ServerManagementTest.java
Removed:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
   trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
   trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/tests/bin/runtest
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
   trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
Log:
Various tweaks to get clustering tests pass in one go.
If they don't then there's a race condition (or more) I haven't managed to catch.


Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -328,7 +328,8 @@
    }
 
    private void performClientSideFailover(ClientConnectionDelegate failedConnDelegate,
-                                          ClientConnectionDelegate newConnDelegate) throws Exception
+                                          ClientConnectionDelegate newConnDelegate)
+      throws Exception
    {
       log.debug(this + " performing client side failover");
 
@@ -345,17 +346,17 @@
 
       CallbackManager oldCallbackManager = failedState.getRemotingConnection().getCallbackManager();
 
-      //We need to update some of the attributes on the state
+      // We need to update some of the attributes on the state
       failedState.copyState(newState);
       
-      //Map of old session id to new session state
+      // Map of old session ID to new session state
       Map oldNewSessionStateMap = new HashMap();
 
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
           
-         int oldSessionId = failedSessionState.getSessionId();
+         int oldSessionID = failedSessionState.getSessionId();
 
          ClientSessionDelegate failedSessionDelegate =
             (ClientSessionDelegate)failedSessionState.getDelegate();
@@ -367,17 +368,15 @@
 
          SessionState newSessionState = (SessionState)newSessionDelegate.getState();
          
-         if (trace) { log.trace("New session state has " + newSessionState.getClientAckList().size() + " deliveries"); }
+         if (trace) { log.trace("new session state has " + newSessionState.getClientAckList().size() + " deliveries"); }
          
-         oldNewSessionStateMap.put(new Integer(oldSessionId), failedSessionState);
+         oldNewSessionStateMap.put(new Integer(oldSessionID), failedSessionState);
 
          failedSessionDelegate.copyAttributes(newSessionDelegate);
 
-         //We need to update some of the attributes on the state
+         // We need to update some of the attributes on the state
          failedSessionState.copyState(newSessionState);
 
-         if (trace) { log.trace("replacing session (" + failedSessionDelegate + ") with a new failover session " + newSessionDelegate); }
-
          List children = new ArrayList();
 
          // TODO Why is this clone necessary?
@@ -393,10 +392,8 @@
             }
             else if (sessionChild instanceof ConsumerState)
             {
-               handleFailoverOnConsumer(failedConnDelegate,
-                                        (ConsumerState)sessionChild,
-                                        failedSessionDelegate,
-                                        oldCallbackManager);
+               handleFailoverOnConsumer(failedConnDelegate, (ConsumerState)sessionChild,
+                                        failedSessionDelegate, oldCallbackManager);
             }
             else if (sessionChild instanceof BrowserState)
             {
@@ -405,46 +402,38 @@
          }
       }
       
-      //First we must tell the resource manager to substitute old session id for new session id
-      //Note we MUST submit the entire mapping in one operation since there may be overlap between
-      //old and new session id, and we don't want to overwrite keys in the map
+      // First we must tell the resource manager to substitute old session ID for new session ID.
+      // Note we MUST submit the entire mapping in one operation since there may be overlap between
+      // old and new session ID, and we don't want to overwrite keys in the map.
       
       failedState.getResourceManager().handleFailover(oldNewSessionStateMap);
       
-      Iterator iter = oldNewSessionStateMap.values().iterator();
-            
-      while (iter.hasNext())
+      for(Iterator i = oldNewSessionStateMap.values().iterator(); i.hasNext(); )
       {
-         SessionState state = (SessionState)iter.next();
-         
-         List ackInfos = null;
-           
+         List ackInfos = Collections.EMPTY_LIST;
+
+         SessionState state = (SessionState)i.next();
+
          if (!state.isTransacted() ||
              (state.isXA() && state.getCurrentTxId() == null))     
          {
-            //Non transacted session or an XA session with no transaction set (it falls back to auto_ack)
+            // Non transacted session or an XA session with no transaction set (it falls back
+            // to auto_ack)
             
-            if (trace) { log.trace("Session is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
+            if (trace) { log.trace(state + " is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
 
+            // We remove any unacked non-persistent messages - this is because we don't want to ack
+            // them since the server won't know about them and will get confused
                         
-            //we remove any unacked np messages - this is because we don't want to ack them
-            //since the server won't know about them and will barf
-                        
             if (state.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
             {
-               Iterator iter2 = state.getClientAckList().iterator();
-               
-               if (trace) { log.trace("Removing any np deliveries"); }
-   
-               while (iter2.hasNext())
+               for(Iterator j = state.getClientAckList().iterator(); j.hasNext(); )
                {
-                  DeliveryInfo info = (DeliveryInfo)iter2.next();
-   
+                  DeliveryInfo info = (DeliveryInfo)j.next();
                   if (!info.getMessageProxy().getMessage().isReliable())
                   {
-                     iter2.remove();
-                     
-                     if (trace) { log.trace("Removed np delivery: " + info.getDeliveryId()); }
+                     j.remove();
+                     if (trace) { log.trace("removed non persistent delivery " + info); }
                   }
                }
                
@@ -457,27 +446,26 @@
                {
                   if (!autoAck.getMessageProxy().getMessage().isReliable())
                   {
-                     //unreliable
+                     // unreliable, discard
                      state.setAutoAckInfo(null);
-                     ackInfos = Collections.EMPTY_LIST;
                   }
                   else
                   {
-                     //reliable
+                     // reliable
                      ackInfos = new ArrayList();
                      ackInfos.add(autoAck);
                   }
                }               
             }
             
-            if (trace) { log.trace("Retrieved " + ackInfos.size() + " deliveries"); }
+            if (trace) { log.trace(this + " retrieved " + ackInfos.size() + " deliveries"); }
          }
          else
          {
-            //Transacted session - we need to get the acks from the resource manager
-            //btw we have kept the old resource manager
-            ResourceManager rm = failedState.getResourceManager();
+            // Transacted session - we need to get the acks from the resource manager. BTW we have
+            // kept the old resource manager
 
+            ResourceManager rm = failedState.getResourceManager();
             ackInfos = rm.getDeliveriesForSession(state.getSessionId());
          }
 

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -217,7 +217,7 @@
 
    public String toString()
    {
-      return "ConnectionDelegate[id:" + id + ", serverid:" + serverID + "]";
+      return "ConnectionDelegate[" + id + ", SID=" + serverID + "]";
    }
 
    public void init()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -294,7 +294,7 @@
 
    public String toString()
    {
-      return "ConnectionFactoryDelegate[" + id + ", " + serverID + "]";
+      return "ConnectionFactoryDelegate[" + id + ", SID=" + serverID + "]";
    }
    
    public String getServerLocatorURI()

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -70,7 +70,7 @@
    private boolean recoverCalled;
 
    // List<DeliveryInfo>
-   private List ClientAckList;
+   private List clientAckList;
    
    private DeliveryInfo autoAckInfo;
 
@@ -109,7 +109,7 @@
       
       executor = new QueuedExecutor(new LinkedQueue());
       
-      ClientAckList = new ArrayList();
+      clientAckList = new ArrayList();
       
       // TODO could optimise this to use the same map of callbackmanagers (which holds refs
       // to callbackhandlers) in the connection, instead of maintaining another map
@@ -142,7 +142,7 @@
     */
    public List getClientAckList()
    {
-      return ClientAckList;
+      return clientAckList;
    }
    
    public DeliveryInfo getAutoAckInfo()

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -727,84 +727,79 @@
    }
    
    /*
-    * Wait for failover from the specified node to complete
+    * Wait for failover from the specified node to complete.
     */
-   public int waitForFailover(int failedNodeId) throws Exception
+   public int waitForFailover(int failedNodeID) throws Exception
    {
-      //This node may be failing over for another node - in which case we must wait for that to be complete
+      // This node may be failing over for another node - in which case we must wait for that to be
+      // complete.
       
-      log.info(this + " waiting for server-side failover from failed node " + failedNodeId);
+      log.info(this + " waiting for server-side failover for failed node " + failedNodeID + " to complete");
       
       Replicator replicator = getReplicator();
-      
-      // Failover
 
       long startToWait = failoverStartTimeout;
-      
       long completeToWait = failoverCompleteTimeout;
                      
-      //Must lock here
+      // Must lock here
       synchronized (failoverStatusLock)
       {         
          while (true)
          {         
             //TODO we shouldn't have a dependency on DefaultClusteredPostOffice - where should we put the constants?
+
             Map replicants = replicator.get(DefaultClusteredPostOffice.FAILED_OVER_FOR_KEY);
             
             boolean foundEntry = false;
                         
             if (replicants != null)
             {
-               Iterator iter = replicants.entrySet().iterator();
-               
-               while (iter.hasNext())
+               for(Iterator i = replicants.entrySet().iterator(); i.hasNext(); )
                {
-                  Map.Entry entry = (Map.Entry)iter.next();
-                  
+                  Map.Entry entry = (Map.Entry)i.next();
                   Integer nid = (Integer)entry.getKey();
-                  
                   FailoverStatus status = (FailoverStatus)entry.getValue();
                   
-                  if (status.isFailedOverForNode(failedNodeId))
+                  if (status.isFailedOverForNode(failedNodeID))
                   {
-                     log.info("Fail over is complete on node " + nid);
-                     //Got the node - failover has completed
-                     return nid.intValue();  
+                     log.info(this + ": failover is complete on node " + nid);
+                     return nid.intValue();
                   }
-                  else if (status.isFailingOverForNode(failedNodeId))
+                  else if (status.isFailingOverForNode(failedNodeID))
                   {
-                     log.info("Fail over is in progress on node " + nid);
+                     log.info(this + ": fail over is in progress on node " + nid);
                      
-                     //A server has started failing over for the failed node, but not completed
-                     //if it's not this node then we immediately return so the connection can be redirected to
-                     //another node
+                     // A server has started failing over for the failed node, but not completed.
+                     // If it's not this node then we immediately return so the connection can be
+                     // redirected to another node.
                      if (nid.intValue() != this.getServerPeerID())
                      {
                         return nid.intValue();
                      }
                      
-                     //Otherwise we wait for failover to complete
+                     // Otherwise we wait for failover to complete
                      
                      if (completeToWait <= 0)
                      {
-                        //Give up now
-                        log.info("Already waited long enough for failover to complete, giving up");
+                        // Give up now
+                        log.info(this + " already waited long enough for failover to complete, giving up");
                         return -1;
                      }
                      
-                     //Note - we have to count the time since other unrelated nodes may fail and wake
-                     //up the lock - in this case we don't want to give up too early
-                     long start = System.currentTimeMillis();       
+                     // Note - we have to count the time since other unrelated nodes may fail and
+                     // wake up the lock - in this case we don't want to give up too early.
+                     long start = System.currentTimeMillis();
+
                      try
                      {
-                        log.info("Waiting for failover to complete");
+                        log.debug(this + " blocking on the failover lock, waiting for failover to complete");
                         failoverStatusLock.wait(completeToWait);
+                        log.debug(this + " releasing the failover lock, checking again whether failover completed ...");
                      }
                      catch (InterruptedException ignore)
                      {                  
                      }
                      completeToWait -= System.currentTimeMillis() - start;
-                    
                      foundEntry = true;
                   }
                }        
@@ -812,29 +807,29 @@
             
             if (!foundEntry)
             {              
-               //No trace of failover happening
-               //so we wait a maximum of FAILOVER_START_TIMEOUT for some replicated data to arrive
-               //This should arrive fairly quickly since this is added at the beginning of the failover process
-               //If it doesn't arrive it would imply that no failover has actually happened on the server
-               //or the timeout is too short.
-               //It is possible that no failover has actually happened on the server, if for example there
-               //is a problem with the client side network but the server side network is ok.
+               // No trace of failover happening so we wait a maximum of FAILOVER_START_TIMEOUT for
+               // some replicated data to arrive. This should arrive fairly quickly since this is
+               // added at the beginning of the failover process. If it doesn't arrive it would
+               // imply that no failover has actually happened on the server or the timeout is too
+               // short. It is possible that no failover has actually happened on the server, if for
+               // example there is a problem with the client side network but the server side
+               // network is ok.
    
                if (startToWait <= 0)
                {
-                  //Don't want to wait again
-                  log.info("Already waited long enough for failover to start, giving up");
+                  // Don't want to wait again
+                  log.info(this + " already waited long enough for failover to start, giving up");
                   return -1;
                }
                
-               //Note - we have to count the time since other unrelated nodes may fail and wake
-               //up the lock - in this case we don't want to give up too early
+               // Note - we have to count the time since other unrelated nodes may fail and wake
+               // up the lock - in this case we don't want to give up too early.
                long start = System.currentTimeMillis(); 
                try
                {
-                  log.info("Waiting for failover to start");
+                  log.debug(this + " blocking on the failover lock, waiting for failover to start");
                   failoverStatusLock.wait(startToWait);
-                  log.info("Finished waiting for failover to start");
+                  log.debug(this + " releasing the failover lock, checking again whether failover started ...");
                }
                catch (InterruptedException ignore)
                {                  
@@ -847,7 +842,7 @@
    
    public String toString()
    {
-      return "ServerPeer [" + getServerPeerID() + "]";
+      return "ServerPeer[" + getServerPeerID() + "]";
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -95,8 +95,12 @@
    {
       return connectionConsumerSession;
    }
-   
 
+   public String toString()
+   {
+      return "Delivery[" + msg + "]";
+   }
+
    // Ack Implementation  -------------------------------------------
    
    public long getDeliveryId()

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -108,8 +108,8 @@
          }
          else
          {
-            log.debug(this + " creating a failover connection " +
-                      "to replace connection to failed node " + failedNodeID);
+            log.debug(this + " received client-side failover request. Creating failover "+
+               "connection to replace connection to failed node " + failedNodeID);
 
             // Wait for server side failover to complete
             int failoverNodeID = serverPeer.waitForFailover(failedNodeID);

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -254,8 +254,9 @@
          {            
             try
             {
-               if (trace) { log.trace(this + " scheduling a new Deliverer"); }
-               this.executor.execute(new Deliverer());
+               Deliverer deliverer = new Deliverer();
+               if (trace) { log.trace(this + " scheduling a new " + deliverer); }
+               this.executor.execute(deliverer);
             }
             catch (InterruptedException e)
             {

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -822,7 +822,7 @@
       
       deliveries.put(new Long(deliveryId), del);
       
-      if (trace) { log.trace(this + " Added delivery: " + deliveryId + ", " + del); }
+      if (trace) { log.trace(this + " added delivery " + deliveryId + ": " + del); }
       
       return deliveryId;      
    }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/server/endpoint/SessionEndpoint.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -69,21 +69,18 @@
  
    /**
     * Acknowledge a list of deliveries
-    * @param ackInfos
     * @throws JMSException
     */
    void acknowledgeDeliveries(List deliveryIds) throws JMSException;
    
    /**
     * Acknowledge a delivery
-    * @param deliveryId
     * @throws JMSException
     */
    void acknowledgeDelivery(Ack ack) throws JMSException;
    
    /**
     * Cancel a list of deliveries.
-    * @param ackInfos
     */
    void cancelDeliveries(List cancelInfos) throws JMSException;
          

Modified: trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -140,7 +140,7 @@
       }
       else
       {
-         return sessionStatesMap == null ? Collections.emptySet() : sessionStatesMap.values();
+         return sessionStatesMap == null ? Collections.EMPTY_SET : sessionStatesMap.values();
       }
    }   
    

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/Binding.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -35,7 +35,7 @@
  */
 public interface Binding
 {
-   public int getNodeId();
+   public int getNodeID();
    
    public Condition getCondition();
    

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBinding.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -36,32 +36,42 @@
  */
 public class DefaultBinding implements Binding
 {
-   private int nodeId;
-   
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private int nodeID;
+
    private Condition condition;
-   
+
    private Queue queue;
 
    private boolean failed;
 
+   // this only works if we keep DefautlBinding immutable
+   private String toString;
+
+   // Constructors --------------------------------------------------
+
    public DefaultBinding()
    {
    }
 
-   public DefaultBinding(int nodeId, Condition condition, Queue queue, boolean failed)
+   public DefaultBinding(int nodeID, Condition condition, Queue queue, boolean failed)
    {
-      this.nodeId = nodeId;
-
+      this.nodeID = nodeID;
       this.condition = condition;
-
       this.queue = queue;
-
       this.failed = failed;
    }
 
-   public int getNodeId()
+   // Binding implementation ----------------------------------------
+
+   public int getNodeID()
    {
-      return nodeId;
+      return nodeID;
    }
 
    public Condition getCondition()
@@ -84,9 +94,36 @@
       this.failed = failed;
    }
 
+   // Public --------------------------------------------------------
+
    public String toString()
    {
-       return "Node" + nodeId + " condition=" + condition + " queue=" + queue + " queueClass=" + queue.getClass().getName();
+      if (toString == null)
+      {
+         StringBuffer sb = new StringBuffer("Binding[");
+
+         sb.append(nodeID).append(',');
+         sb.append(queue).append('(');
+         sb.append(queue.getClass().getName()).append(')');
+
+         if (condition != null)
+         {
+            sb.append(", condition: ").append(condition);
+         }
+         sb.append("]");
+         toString = sb.toString();
+      }
+
+      return toString;
    }
-   
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -91,10 +91,10 @@
    
    protected int currentNodeId;
    
-   //Map <node id, Map < queue name, binding > >
+   // Map <NodeID, Map<queueName, Binding>>
    protected Map nameMaps;
    
-   //Map <condition, List <binding> >
+   // Map <condition, List<Binding>>
    protected Map conditionMap;
    
    protected FilterFactory filterFactory;
@@ -352,7 +352,7 @@
                Binding binding = (Binding)iter.next();
                
                //Sanity check
-               if (binding.getNodeId() != this.currentNodeId)
+               if (binding.getNodeID() != this.currentNodeId)
                {
                   throw new IllegalStateException("Local post office has foreign bindings!");
                }
@@ -420,7 +420,7 @@
             {
                Binding binding = (Binding)iter.next();
                
-               if (!localOnly || (binding.getNodeId() == this.currentNodeId))
+               if (!localOnly || (binding.getNodeID() == this.currentNodeId))
                {
                   list.add(binding);
                }
@@ -696,7 +696,6 @@
    protected void addBinding(Binding binding)
    {
       addToNameMap(binding);
-      
       addToConditionMap(binding);
    }   
    
@@ -711,16 +710,18 @@
    
    protected void addToNameMap(Binding binding)
    {
-      Map nameMap = (Map)nameMaps.get(new Integer(binding.getNodeId()));
+      Integer nodeID = new Integer(binding.getNodeID());
+      Map nameMap = (Map)nameMaps.get(nodeID);
 
       if (nameMap == null)
       {
          nameMap = new LinkedHashMap();
-
-         nameMaps.put(new Integer(binding.getNodeId()), nameMap);
+         nameMaps.put(nodeID, nameMap);
       }
 
       nameMap.put(binding.getQueue().getName(), binding);
+
+      if (trace) { log.trace(this + " added " + binding + " to name map"); }
    }
    
    protected void addToConditionMap(Binding binding)
@@ -737,6 +738,8 @@
       }
       
       bindings.addBinding(binding);
+
+      if (trace) { log.trace(this + " added " + binding + " to condition map"); }
    }
    
    protected Binding removeFromNameMap(int nodeId, String queueName)

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -61,7 +61,7 @@
    {
       super.addBinding(binding);
   
-      if (binding.getNodeId() == thisNode && binding.getQueue().isRecoverable())
+      if (binding.getNodeID() == thisNode && binding.getQueue().isRecoverable())
       {
          localDurableCount++;
       }      
@@ -76,7 +76,7 @@
          return false;
       }
            
-      if (binding.getNodeId() == thisNode && binding.getQueue().isRecoverable())
+      if (binding.getNodeID() == thisNode && binding.getQueue().isRecoverable())
       {
          localDurableCount--;
       }      

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -549,11 +549,8 @@
    {
       lock.writeLock().acquire();
 
-      if (trace)
-      {
-         log.info(this.currentNodeId + " adding binding from node: " + nodeId +
-                  " queue: " + queueName + " with condition: " + conditionText);
-      }
+      log.debug(this + " adding binding from node " + nodeId + ", queue " + queueName +
+         " with condition " + conditionText);
 
       Condition condition = conditionFactory.createCondition(conditionText);
 
@@ -578,12 +575,12 @@
 
          if (binding != null && failed)
          {
-            throw new IllegalArgumentException(this.currentNodeId +
-                     " Binding already exists for node Id " + nodeId + " queue name " + queueName);
+            throw new IllegalArgumentException(this + " has already this binding for node " +
+               nodeId + ", queue " + queueName);
          }
 
-         binding = this.createBinding(nodeId, condition, queueName, channelID, filterString,
-                                      durable, failed);
+         binding =
+            createBinding(nodeId, condition, queueName, channelID, filterString, durable, failed);
 
          addBinding(binding);
       }
@@ -591,8 +588,6 @@
       {
          lock.writeLock().release();
       }
-
-      log.info("****** binding added");
    }
 
    /*
@@ -723,7 +718,7 @@
             {
                Binding binding = (Binding)iter.next();
 
-               if (binding.getNodeId() == this.currentNodeId)
+               if (binding.getNodeID() == this.currentNodeId)
                {
                   boolean handle = true;
 
@@ -1847,7 +1842,7 @@
 
             Queue queue = binding.getQueue();
 
-            BindingInfo info = new BindingInfo(binding.getNodeId(), queue.getName(),
+            BindingInfo info = new BindingInfo(binding.getNodeID(), queue.getName(),
                                                binding.getCondition().toText(),
                                                queue.getFilter() == null ? null : queue.getFilter().getFilterString(),
                                                queue.getChannelID(),
@@ -1898,7 +1893,7 @@
          Binding binding = this.createBinding(info.getNodeId(), condition, info.getQueueName(), info.getChannelId(),
                                               info.getFilterString(), info.isDurable(),info.isFailed());
 
-         if (binding.getNodeId() == this.currentNodeId)
+         if (binding.getNodeID() == this.currentNodeId)
          {
             //We deactivate if this is one of our own bindings - it can only
             //be one of our own durable bindings - and since state is retrieved before we are fully started
@@ -2112,10 +2107,9 @@
          }
          else
          {
-            // Compile a list of the queue names to remove.
-            // Note that any non durable bindings will already have been removed (in
-            // removeDataForNode()) when the node leave was detected, so if there are any non durable
-            // bindings left here then this is an error.
+            // Compile a list of the queue names to remove. Note that any non durable bindings will
+            // already have been removed (in removeDataForNode()) when the node leave was detected,
+            // so if there are any non durable bindings left here then this is an error.
 
             // We iterate through twice to avoid ConcurrentModificationException
 
@@ -2129,8 +2123,8 @@
                // Sanity check
                if (!binding.getQueue().isRecoverable())
                {
-                  throw new IllegalStateException("Found non recoverable queue in map, " +
-                     "these should have been removed!");
+                  throw new IllegalStateException("Found non recoverable queue " +
+                     binding.getQueue().getName() + "in map, these should have been removed!");
                }
 
                // Sanity check
@@ -2247,13 +2241,13 @@
 
    private void addIntoFailedMaps(Binding binding)
    {
-      Map channelMap = (Map)failedBindings.get(new Integer(binding.getNodeId()));
+      Map channelMap = (Map)failedBindings.get(new Integer(binding.getNodeID()));
 
       if (channelMap == null)
       {
          channelMap = new LinkedHashMap();
 
-         failedBindings.put(new Integer(binding.getNodeId()), channelMap);
+         failedBindings.put(new Integer(binding.getNodeID()), channelMap);
       }
 
       channelMap.put(new Long(binding.getQueue().getChannelID()), binding);

Modified: trunk/tests/bin/runtest
===================================================================
--- trunk/tests/bin/runtest	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/bin/runtest	2006-12-16 04:27:46 UTC (rev 1804)
@@ -48,8 +48,6 @@
    TEST_REMOTING=$ENV_TEST_REMOTING
 fi
 
-TEST_DATABASE=mysql
-
 #
 # We should use the same test execution classpath as the ant <junit> task, so we run ant to get
 # it from there.
@@ -95,21 +93,33 @@
             fi
             JAVA_OPTS="$DEBUG_OPTS"
         fi
+        shift
+        continue;
     fi
     if [ "$1" = "-remote" ]; then
         isRemote=true;
         REMOTE_TEST="-Dremote=true"
+        shift
+        continue;
     fi
     if [ "$1" = "-remotedebug" ]; then
         remote_debug=true
+        shift
+        continue;
     fi
     if [ "$1" = "0" -o "$1" = "1" -o "$1" = "2" ]; then
         remote_debug_index=$1
+        shift
+        continue;
     fi
     if [ "$1" = "-clustered" ]; then
         TEST_CLUSTERED=true
+        shift
+        continue;
+    else
+        echo "Error, unknown switch: $1"
+        exit 1
     fi
-    shift
 done
 
 JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.clustered=$TEST_CLUSTERED -Dtest.remoting=$TEST_REMOTING -Dbuild.lib=../../output/lib"

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/build.xml	2006-12-16 04:27:46 UTC (rev 1804)
@@ -756,8 +756,7 @@
 
             <fileset dir="${build.tests.classes}">
                <!--
-               <include name="**/jms/clustering/*Test.class"/>
-                <include name="org/jboss/test/messaging/util/ServerManagementTest.class"/>
+                   <include name="**/jms/clustering/FailoverTest.class"/>
                -->
                <include name="**/jms/clustering/*Test.class"/>
             </fileset>

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -1084,7 +1084,7 @@
    
    protected void assertEquivalent(Binding binding1, Binding binding2)
    {
-      assertEquals(binding1.getNodeId(), binding2.getNodeId());
+      assertEquals(binding1.getNodeID(), binding2.getNodeID());
       assertEquals(binding1.getQueue().getName(), binding2.getQueue().getName()); 
       String selector1 = binding1.getQueue().getFilter() != null ? binding1.getQueue().getFilter().getFilterString() : null;
       String selector2 = binding2.getQueue().getFilter() != null ? binding2.getQueue().getFilter().getFilterString() : null;

Added: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ClusterEventNotificationListener.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ClusterEventNotificationListener.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ClusterEventNotificationListener.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -0,0 +1,111 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import EDU.oswego.cs.dl.util.concurrent.Slot;
+
+import javax.management.NotificationListener;
+import javax.management.Notification;
+
+import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
+import org.jboss.logging.Logger;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+class ClusterEventNotificationListener implements NotificationListener
+{
+   // Constants -----------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(ClusterEventNotificationListener.class);
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private Slot viewChange;
+   private Slot failoverCompleted;
+
+   // Constructors --------------------------------------------------
+
+   ClusterEventNotificationListener()
+   {
+      viewChange = new Slot();
+      failoverCompleted = new Slot();
+   }
+
+   // NotificationListener implementation ---------------------------
+
+   public void handleNotification(Notification notification, Object object)
+   {
+      String type = notification.getType();
+
+      log.info("received " + type + " notification");
+
+      if (ClusteredPostOffice.VIEW_CHANGED_NOTIFICATION.equals(type))
+      {
+         try
+         {
+            viewChange.put(Boolean.TRUE);
+         }
+         catch(InterruptedException e)
+         {
+            log.error(e);
+         }
+      }
+      else if (ClusteredPostOffice.FAILOVER_COMPLETED_NOTIFICATION.equals(type))
+      {
+         try
+         {
+            failoverCompleted.put(Boolean.TRUE);
+         }
+         catch(InterruptedException e)
+         {
+            log.error(e);
+         }
+      }
+      else
+      {
+         log.info("Ignoring notification " + type);
+      }
+   }
+
+   public boolean viewChanged(long timeout) throws InterruptedException
+   {
+      Boolean result = (Boolean)viewChange.poll(timeout);
+      if (result == null)
+      {
+         return false;
+      }
+      return result.booleanValue();
+   }
+
+   public boolean failoverCompleted(long timeout) throws InterruptedException
+   {
+      Boolean result = (Boolean)failoverCompleted.poll(timeout);
+      if (result == null)
+      {
+         return false;
+      }
+      return result.booleanValue();
+   }
+
+   // Public --------------------------------------------------------
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}
+
+
+

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -85,8 +85,8 @@
          log.info("########");
 
          // TODO - this shouldn't be necessary if we have the client valve in place
-         log.info("Sleeping for 1 min");
-         Thread.sleep(15000);
+         log.info("Sleeping for 60 sec");
+         Thread.sleep(60000);
 
          // we must receive the message
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/GroupManagementTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -8,15 +8,9 @@
 
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
-
-import javax.management.NotificationListener;
-import javax.management.Notification;
 import javax.management.ObjectName;
 import java.util.Set;
 
-import EDU.oswego.cs.dl.util.concurrent.Slot;
-
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
@@ -47,7 +41,6 @@
          ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
       }
@@ -66,12 +59,8 @@
       {
          ServerManagement.start(0, "all");
 
-         log.info("Server 0 started");
-
          ServerManagement.addNotificationListener(0, postOfficeObjectName, listener);
 
-         log.info("NotificationListener added to server 0");
-
          ServerManagement.start(1, "all");
 
          log.info("Blocking to receive notification ...");
@@ -82,7 +71,6 @@
          }
 
          Set view = ServerManagement.getServer(1).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -102,14 +90,12 @@
          ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
 
          ServerManagement.start(1, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -119,8 +105,6 @@
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
-
-         log.info("testTwoNodesCluster sucessful");
       }
       finally
       {
@@ -136,20 +120,17 @@
          ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
 
          ServerManagement.start(1, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
 
          view = ServerManagement.getServer(1).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -157,27 +138,22 @@
          ServerManagement.start(3, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(3, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
          assertTrue(view.contains(new Integer(3)));
 
          view = ServerManagement.getServer(1).getNodeIDView();
-
          assertEquals(3, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
          assertTrue(view.contains(new Integer(3)));
 
          view = ServerManagement.getServer(3).getNodeIDView();
-
          assertEquals(3, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
          assertTrue(view.contains(new Integer(3)));
-
-         log.info("testThreeNodesCluster sucessful");
       }
       finally
       {
@@ -192,14 +168,11 @@
    {
       try
       {
-         // Start with a 3 node cluster
-
          ServerManagement.start(0, "all");
          ServerManagement.start(1, "all");
          ServerManagement.start(2, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(3, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -210,7 +183,6 @@
          ServerManagement.stop(0);
 
          view = ServerManagement.getServer(1).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(1)));
          assertTrue(view.contains(new Integer(2)));
@@ -220,7 +192,6 @@
          ServerManagement.stop(2);
 
          view = ServerManagement.getServer(1).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(1)));
 
@@ -229,7 +200,6 @@
          ServerManagement.start(0, "all");
 
          view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -237,10 +207,9 @@
 
          // Reuse the "hollow" RMI server 2 to start another cluster node
 
-         ServerManagement.start(1, "all");
+         ServerManagement.start(2, "all");
 
          view = ServerManagement.getServer(2).getNodeIDView();
-
          assertEquals(3, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -268,7 +237,6 @@
          ServerManagement.start(1, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -291,14 +259,12 @@
          }
 
          view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
       }
       finally
       {
          ServerManagement.removeNotificationListener(0, postOfficeObjectName, clusterEvent);
-
          ServerManagement.stop(1);
          ServerManagement.stop(0);
       }
@@ -318,7 +284,6 @@
          ServerManagement.start(2, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(3, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -344,7 +309,6 @@
          log.info("received FAILOVER_COMPLETED");
 
          view = ServerManagement.getServer(1).getNodeIDView();
-
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
          assertTrue(view.contains(new Integer(1)));
@@ -367,10 +331,8 @@
          log.info("received FAILOVER_COMPLETED");
 
          view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
-
       }
       finally
       {
@@ -395,38 +357,36 @@
          ServerManagement.start(0, "all");
 
          Set view = ServerManagement.getServer(0).getNodeIDView();
-
          assertEquals(1, view.size());
          assertTrue(view.contains(new Integer(0)));
 
          ServerManagement.addNotificationListener(0, postOfficeObjectName, clusterEvent);
 
-         ServerManagement.start(10, "all");
+         // start the ninth node, as there is no chance to be started by scripts
+         ServerManagement.start(9, "all");
 
          if (!clusterEvent.viewChanged(120000))
          {
             fail("Did not receive a VIEW_CHANGED event after spawning new server!");
          }
 
-         view = ServerManagement.getServer(1).getNodeIDView();
+         view = ServerManagement.getServer(9).getNodeIDView();
 
          assertEquals(2, view.size());
          assertTrue(view.contains(new Integer(0)));
-         assertTrue(view.contains(new Integer(10)));
+         assertTrue(view.contains(new Integer(9)));
 
-         //ServerManagement.kill(10);
 
       }
       finally
       {
          ServerManagement.removeNotificationListener(0, postOfficeObjectName, clusterEvent);
          ServerManagement.stop(0);
+         ServerManagement.kill(9);
       }
    }
 
 
-
-
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -445,71 +405,4 @@
 
    // Inner classes -------------------------------------------------
 
-   private class ClusterEventNotificationListener implements NotificationListener
-   {
-      private Slot viewChange;
-      private Slot failoverCompleted;
-
-      ClusterEventNotificationListener()
-      {
-         viewChange = new Slot();
-         failoverCompleted = new Slot();
-      }
-
-      public void handleNotification(Notification notification, Object object)
-      {
-         String type = notification.getType();
-
-         log.info("received " + type + " notification");
-
-         if (ClusteredPostOffice.VIEW_CHANGED_NOTIFICATION.equals(type))
-         {
-            try
-            {
-               viewChange.put(Boolean.TRUE);
-            }
-            catch(InterruptedException e)
-            {
-               log.error(e);
-            }
-         }
-         else if (ClusteredPostOffice.FAILOVER_COMPLETED_NOTIFICATION.equals(type))
-         {
-            try
-            {
-               failoverCompleted.put(Boolean.TRUE);
-            }
-            catch(InterruptedException e)
-            {
-               log.error(e);
-            }
-         }
-         else
-         {
-            log.info("Ignoring notification " + type);
-         }
-      }
-
-      public boolean viewChanged(long timeout) throws InterruptedException
-      {
-         Boolean result = (Boolean)viewChange.poll(timeout);
-         if (result == null)
-         {
-            return false;
-         }
-         return result.booleanValue();
-      }
-
-      public boolean failoverCompleted(long timeout) throws InterruptedException
-      {
-         Boolean result = (Boolean)failoverCompleted.poll(timeout);
-         if (result == null)
-         {
-            return false;
-         }
-         return result.booleanValue();
-      }
-
-   }
-
 }

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -506,10 +506,13 @@
 
          ServerManagement.kill(1);
 
-         log.info("killed server, now waiting");
+         long sleepTime = 60;
 
-         Thread.sleep(5000);
+         log.info("killed server, now waiting for " + sleepTime + " seconds");
 
+         // NOTE: the sleep time needs to be longer than the Remoting connector's lease period
+         Thread.sleep(sleepTime * 1000);
+
          log.info("done wait");
 
          state = (ConnectionState)del.getState();
@@ -666,10 +669,13 @@
 
          killed = true;
 
-         log.info("killed server, now waiting");
+         long sleepTime = 60;
 
-         Thread.sleep(5000);
+         log.info("killed server, now waiting for " + sleepTime + " seconds");
 
+         // NOTE: the sleep time needs to be longer than the Remoting connector's lease period
+         Thread.sleep(sleepTime * 1000);
+
          log.info("done wait");
 
          state = (ConnectionState)del.getState();
@@ -696,7 +702,7 @@
 
             assertNotNull(tm);
             
-            log.info("message is " + tm.getText());
+            log.debug("message is " + tm.getText());
 
             assertEquals("message:" + i, tm.getText());
          }
@@ -854,8 +860,13 @@
 
          log.info("killed server, now waiting");
 
-         Thread.sleep(5000);
+         long sleepTime = 60;
 
+         log.info("killed server, now waiting for " + sleepTime + " seconds");
+
+         // NOTE: the sleep time needs to be longer than the Remoting connector's lease period
+         Thread.sleep(sleepTime * 1000);
+
          log.info("done wait");
 
          state = (ConnectionState)del.getState();
@@ -880,7 +891,7 @@
          {
             tm = (TextMessage)cons.receive(500);
 
-            log.info("message is " + tm.getText());
+            log.debug("message is " + tm.getText());
 
             assertNotNull(tm);
 

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/LargeClusterTest.java (from rev 1803, trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java)
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/LargeClusterTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -0,0 +1,464 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+
+import javax.jms.Connection;
+import javax.jms.Session;
+import javax.jms.MessageListener;
+import javax.jms.Message;
+import javax.jms.TextMessage;
+import javax.management.ObjectName;
+
+import EDU.oswego.cs.dl.util.concurrent.Slot;
+
+import java.util.Set;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class LargeClusterTest extends ClusteringTestBase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public LargeClusterTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   /**
+    * This test is an example how to programatically make a cluster node to join the cluser.
+    */
+   public void testJoin() throws Exception
+   {
+      // By this time, after running setUp(), we should have an already formed cluster of seven
+      // nodes
+
+      Set view = ServerManagement.getServer(0).getNodeIDView();
+
+      assertEquals(7, view.size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(3)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
+      ClusterEventNotificationListener clusterEvent = new ClusterEventNotificationListener();
+
+      ServerManagement.addNotificationListener(4, postOfficeObjectName, clusterEvent);
+
+      // We start programatically the eight node.
+
+      ServerManagement.start(7, "all");
+
+      // wait for change to propagate
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      view = ServerManagement.getServer(0).getNodeIDView();
+
+      assertEquals(8, view.size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(3)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+      assertTrue(view.contains(new Integer(7)));
+
+      ServerManagement.removeNotificationListener(4, postOfficeObjectName, clusterEvent);
+
+      ServerManagement.kill(7);
+   }
+
+   /**
+    * This test is an example how to programatically make a cluster node to cleanly leave the
+    * cluster.
+    */
+   public void testCleanLeave() throws Exception
+   {
+      // By this time, after running setUp(), we should have an already formed cluster of seven
+      // nodes
+
+      Set view = ServerManagement.getServer(0).getNodeIDView();
+
+      assertEquals(7, view.size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(3)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
+      ClusterEventNotificationListener clusterEvent = new ClusterEventNotificationListener();
+
+      ServerManagement.addNotificationListener(0, postOfficeObjectName, clusterEvent);
+
+      // We get all nodes to programatically leave the cluster
+
+      ServerManagement.stop(3);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      assertEquals(6, ServerManagement.getServer(0).getNodeIDView().size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+
+      ServerManagement.stop(6);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      assertEquals(5, ServerManagement.getServer(0).getNodeIDView().size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+
+      ServerManagement.stop(1);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      assertEquals(4, ServerManagement.getServer(0).getNodeIDView().size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+
+      ServerManagement.stop(2);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+
+      ServerManagement.stop(4);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      assertEquals(2, ServerManagement.getServer(0).getNodeIDView().size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(5)));
+
+      ServerManagement.removeNotificationListener(0, postOfficeObjectName, clusterEvent);
+      ServerManagement.addNotificationListener(5, postOfficeObjectName, clusterEvent);
+
+      ServerManagement.stop(0);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      assertEquals(1, ServerManagement.getServer(5).getNodeIDView().size());
+      assertTrue(view.contains(new Integer(5)));
+
+      ServerManagement.removeNotificationListener(5, postOfficeObjectName, clusterEvent);
+
+      ServerManagement.stop(5);
+   }
+
+   public void testLeaveAndJoin() throws Exception
+   {
+      // By this time, after running setUp(), we should have an already formed cluster of seven
+      // nodes
+
+      Set view = ServerManagement.getServer(0).getNodeIDView();
+
+      assertEquals(7, view.size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(3)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+
+      ObjectName postOfficeObjectName = new ObjectName("jboss.messaging:service=PostOffice");
+      ClusterEventNotificationListener clusterEvent = new ClusterEventNotificationListener();
+
+      ServerManagement.addNotificationListener(5, postOfficeObjectName, clusterEvent);
+
+      // We get the first node to programatically leave the cluster
+
+      ServerManagement.stop(0);
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      view = ServerManagement.getServer(4).getNodeIDView();
+
+      assertEquals(6, view.size());
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(3)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+
+
+      // We get the first node to re-join
+
+      ServerManagement.start(0, "all");
+
+      if (!clusterEvent.viewChanged(120000))
+      {
+         fail("Did not receive a VIEW_CHANGED event after spawning new server!");
+      }
+
+      view = ServerManagement.getServer(6).getNodeIDView();
+      assertEquals(7, view.size());
+      assertTrue(view.contains(new Integer(0)));
+      assertTrue(view.contains(new Integer(1)));
+      assertTrue(view.contains(new Integer(2)));
+      assertTrue(view.contains(new Integer(3)));
+      assertTrue(view.contains(new Integer(4)));
+      assertTrue(view.contains(new Integer(5)));
+      assertTrue(view.contains(new Integer(6)));
+
+      ServerManagement.removeNotificationListener(5, postOfficeObjectName, clusterEvent);
+
+   }
+
+   public void testDistributedTopic() throws Exception
+   {
+      Connection conn0 = null;
+      Connection conn1 = null;
+      Connection conn2 = null;
+      Connection conn3 = null;
+      Connection conn4 = null;
+      Connection conn5 = null;
+      Connection conn6 = null;
+
+
+      try
+      {
+         conn0 = cf.createConnection();
+         assertEquals(0, ((ClientConnectionDelegate)((JBossConnection)conn0).
+            getDelegate()).getServerID());
+         Session s0 = conn0.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m0 = new SimpleMessageListener();
+         s0.createConsumer(topic[0]).setMessageListener(m0);
+         conn0.start();
+
+         conn1 = cf.createConnection();
+         assertEquals(1, ((ClientConnectionDelegate)((JBossConnection)conn1).
+            getDelegate()).getServerID());
+         Session s1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m1 = new SimpleMessageListener();
+         s1.createConsumer(topic[1]).setMessageListener(m1);
+         conn1.start();
+
+         conn2 = cf.createConnection();
+         assertEquals(2, ((ClientConnectionDelegate)((JBossConnection)conn2).
+            getDelegate()).getServerID());
+         Session s2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m2 = new SimpleMessageListener();
+         s2.createConsumer(topic[2]).setMessageListener(m2);
+         conn2.start();
+
+         conn3 = cf.createConnection();
+         assertEquals(3, ((ClientConnectionDelegate)((JBossConnection)conn3).
+            getDelegate()).getServerID());
+         Session s3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m3 = new SimpleMessageListener();
+         s3.createConsumer(topic[3]).setMessageListener(m3);
+         conn3.start();
+
+         conn4 = cf.createConnection();
+         assertEquals(4, ((ClientConnectionDelegate)((JBossConnection)conn4).
+            getDelegate()).getServerID());
+         Session s4 = conn4.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m4 = new SimpleMessageListener();
+         s4.createConsumer(topic[4]).setMessageListener(m4);
+         conn4.start();
+
+         conn5 = cf.createConnection();
+         assertEquals(5, ((ClientConnectionDelegate)((JBossConnection)conn5).
+            getDelegate()).getServerID());
+         Session s5 = conn5.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m5 = new SimpleMessageListener();
+         s5.createConsumer(topic[5]).setMessageListener(m5);
+         conn5.start();
+
+         conn6 = cf.createConnection();
+         assertEquals(6, ((ClientConnectionDelegate)((JBossConnection)conn6).
+            getDelegate()).getServerID());
+         Session s6 = conn6.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         SimpleMessageListener m6 = new SimpleMessageListener();
+         s6.createConsumer(topic[6]).setMessageListener(m6);
+         conn6.start();
+
+         s3.createProducer(topic[3]).send(s3.createTextMessage("boom"));
+
+         TextMessage rm = null;
+
+         rm = m0.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = m1.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = m2.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = m3.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = m4.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = m5.poll(5000);
+         assertEquals("boom", rm.getText());
+
+         rm = m6.poll(5000);
+         assertEquals("boom", rm.getText());
+
+      }
+      finally
+      {
+         if (conn0 != null)
+         {
+            conn0.close();
+         }
+
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+
+         if (conn3 != null)
+         {
+            conn3.close();
+         }
+
+         if (conn4 != null)
+         {
+            conn4.close();
+         }
+
+         if (conn5 != null)
+         {
+            conn5.close();
+         }
+
+         if (conn6 != null)
+         {
+            conn6.close();
+         }
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      nodeCount = 7;
+
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+
+      ServerManagement.kill(6);
+      ServerManagement.kill(5);
+      ServerManagement.kill(4);
+      ServerManagement.kill(3);
+      ServerManagement.kill(2);
+      ServerManagement.kill(1);
+   }
+
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+   private class SimpleMessageListener implements MessageListener
+   {
+      private Slot slot;
+
+      SimpleMessageListener()
+      {
+         slot = new Slot();
+      }
+
+      public void onMessage(Message message)
+      {
+         try
+         {
+            slot.put(message);
+         }
+         catch(InterruptedException e)
+         {
+            log.error(e);
+         }
+      }
+
+      public TextMessage poll(long timeout) throws InterruptedException
+      {
+         return (TextMessage)slot.poll(timeout);
+      }
+   }
+}

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ServerManagementTest.java (from rev 1803, trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java)
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ServerManagementTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -0,0 +1,143 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+import javax.naming.InitialContext;
+import javax.management.ObjectName;
+
+/**
+ * Test spawning functionality of the ServerManagment. Used mostly in a clustered testing
+ * environment.
+ *
+ * DO NOT extend ClusteringTestBase, I need direct control over start()/stop()!
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class ServerManagementTest extends MessagingTestCase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public ServerManagementTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testStartServer() throws Exception
+   {
+      ServerManagement.start(0, "all");
+      ServerManagement.start(0, "all");
+   }
+
+   public void testSimpleSpawn() throws Exception
+   {
+      if (!ServerManagement.isRemote())
+      {
+         fail("This test must be run in remote mode!");
+      }
+
+      try
+      {
+         log.info("Starting server 7");
+
+         ServerManagement.start(7, "all");
+
+         Integer index = (Integer)ServerManagement.
+            getAttribute(7, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
+
+         assertEquals(7, index.intValue());
+
+         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(7));
+
+         ic.bind("/xxx", "yyy");
+
+         assertEquals("yyy", ic.lookup("/xxx"));
+      }
+      finally
+      {
+         log.info("Killing server 7");
+         ServerManagement.kill(7);
+      }
+   }
+
+   public void testRessurect() throws Exception
+   {
+      if (!ServerManagement.isRemote())
+      {
+         fail("This test must be run in remote mode!");
+      }
+
+      try
+      {
+         ServerManagement.start(1, "all");
+
+         ServerManagement.kill(1);
+
+         // wait a bit for the server to die
+
+         log.info("Sleeping for 10 seconds ...");
+
+         Thread.sleep(10000);
+
+         // resurrect the server
+
+         ServerManagement.start(1, "all");
+
+         Integer index = (Integer)ServerManagement.
+            getAttribute(1, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
+
+         assertEquals(1, index.intValue());
+
+         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(1));
+
+         ic.bind("/xxx", "yyy");
+
+         assertEquals("yyy", ic.lookup("/xxx"));
+      }
+      finally
+      {
+         ServerManagement.kill(1);
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+
+      // TODO: clean up spawned servers
+
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Deleted: trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/SimpleClusteringTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -1,213 +0,0 @@
-/**
- * JBoss, Home of Professional Open Source
- *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
- */
-package org.jboss.test.messaging.jms.clustering;
-
-import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
-import org.jboss.test.messaging.tools.ServerManagement;
-
-import javax.jms.Connection;
-import javax.jms.Session;
-import javax.jms.MessageListener;
-import javax.jms.Message;
-import javax.jms.TextMessage;
-
-import EDU.oswego.cs.dl.util.concurrent.Slot;
-
-/**
- * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
- * @version <tt>$Revision$</tt>
- *
- * $Id$
- */
-public class SimpleClusteringTest extends ClusteringTestBase
-{
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public SimpleClusteringTest(String name)
-   {
-      super(name);
-   }
-
-   // Public --------------------------------------------------------
-
-   /**
-    * This test is an example how to programatically make a cluster node to join the cluser.
-    */
-   public void testJoin() throws Exception
-   {
-      // By this time, after running setUp(), we should have an already formed cluster of three
-      // nodes (0, 1, 2).
-
-      // TODO - verify this assertion
-
-      // We start programatically the fourth node.
-
-      ServerManagement.start(4, "all");
-
-      // TODO - verify that the cluster formed correctly assertion
-
-      ServerManagement.stop(3);
-   }
-
-   /**
-    * This test is an example how to programatically make a cluster node to cleanly leave the
-    * cluster.
-    */
-   public void testCleanLeave() throws Exception
-   {
-      // By this time, after running setUp(), we should have an already formed cluster of three
-      // nodes (0, 1, 2).
-
-      // TODO - verify this assertion
-
-      // We get the first node to programatically leave the cluster
-
-      ServerManagement.stop(0);
-
-      // TODO - verify that the cluster formed correctly assertion
-
-      // We get the last node to programatically leave the cluster
-
-      ServerManagement.stop(2);
-
-   }
-
-   public void testLeaveAndJoin() throws Exception
-   {
-      // By this time, after running setUp(), we should have an already formed cluster of three
-      // nodes (0, 1, 2).
-
-      // TODO - verify this assertion
-
-      // We get the first node to programatically leave the cluster
-
-      ServerManagement.stop(0);
-
-      // TODO - verify that the cluster formed correctly assertion
-
-      // We get the first node to re-join
-
-      ServerManagement.start(0, "all");
-
-   }
-   
-   public void testDistributedTopic() throws Exception
-   {
-      Connection conn = null;
-      Connection conn1 = null;
-      Connection conn2 = null;
-
-      try
-      {
-         conn = cf.createConnection();
-         conn1 = cf.createConnection();
-         conn2 = cf.createConnection();
-
-         Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session s1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session s2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-         SimpleMessageListener ml = new SimpleMessageListener();
-         SimpleMessageListener ml1 = new SimpleMessageListener();
-         SimpleMessageListener ml2 = new SimpleMessageListener();
-
-         s.createConsumer(topic[0]).setMessageListener(ml);
-         s1.createConsumer(topic[0]).setMessageListener(ml1);
-         s2.createConsumer(topic[0]).setMessageListener(ml2);
-
-         conn.start();
-         conn1.start();
-         conn2.start();
-
-         s.createProducer(topic[0]).send(s.createTextMessage("boom"));
-
-         TextMessage rm = null;
-
-         rm = ml.poll(5000);
-         assertEquals("boom", rm.getText());
-
-         rm = ml1.poll(5000);
-         assertEquals("boom", rm.getText());
-
-         rm = ml2.poll(5000);
-         assertEquals("boom", rm.getText());
-      }
-      finally
-      {
-         if (conn != null)
-         {
-            conn.close();
-         }
-
-         if (conn1 != null)
-         {
-            conn1.close();
-         }
-
-         if (conn2 != null)
-         {
-            conn2.close();
-         }
-      }
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   protected void setUp() throws Exception
-   {
-      nodeCount = 3;
-
-      super.setUp();
-
-      log.debug("setup done");
-   }
-
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-   }
-
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-   private class SimpleMessageListener implements MessageListener
-   {
-      private Slot slot;
-
-      SimpleMessageListener()
-      {
-         slot = new Slot();
-      }
-
-      public void onMessage(Message message)
-      {
-         try
-         {
-            slot.put(message);
-         }
-         catch(InterruptedException e)
-         {
-            log.error(e);
-         }
-      }
-
-      public TextMessage poll(long timeout) throws InterruptedException
-      {
-         return (TextMessage)slot.poll(timeout);
-      }
-   }
-}

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -119,13 +119,12 @@
             ServerManagement.log(ServerManagement.INFO, "Undeploying Server " + i, i);
             ServerManagement.undeployQueue("testDistributedQueue", i);
             ServerManagement.undeployTopic("testDistributedTopic", i);
+            ServerManagement.stop(i);
          }
 
          ic[i].close();
       }
 
-      //ServerManagement.destroySpawnedServers();
-
       super.tearDown();
    }
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -207,16 +207,24 @@
    /**
     * The method stops the local or remote server, bringing it to a "hollow" state. A stopped
     * server is identical with a server that has just been created, but not started.
+    * @return true if the server was effectively stopped, or false if the server was alreayd stopped
+    *         when the method was invoked.
     */
-   public static synchronized void stop(int i) throws Exception
+   public static synchronized boolean stop(int i) throws Exception
    {
       if (servers[i] == null)
       {
-         log.warn("Server " + i + " has not been created, so it cannot be stopped");
+         log.warn("server " + i + " has not been created, so it cannot be stopped");
+         return false;
       }
       else
       {
-         servers[i].getServer().stop();
+         boolean stopped = servers[i].getServer().stop();
+         if (stopped)
+         {
+            log.info("server " + i + " stopped");
+         }
+         return stopped;
       }
    }
 
@@ -228,12 +236,13 @@
    {
       if (servers[i] == null)
       {
-         log.warn("Server " + i + " has not been created, so it cannot be killed");
+         log.warn("server " + i + " has not been created, so it cannot be killed");
       }
       else
       {
+         log.trace("invoking kill() on server " + i);
          servers[i].getServer().kill();
-         log.info("Server " + i + " killed");
+         log.info("server " + i + " killed");
          servers[i] = null;
       }
    }
@@ -481,7 +490,8 @@
       {
          // is remote, need to poll
          NotificationListenerPoller p =
-            new NotificationListenerPoller((Server)servers[serverIndex], on, listener);
+            new NotificationListenerPoller(((ServerHolder)servers[serverIndex]).getServer(),
+                                           on, listener);
 
          synchronized(notificationListenerPollers)
          {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -149,11 +149,11 @@
       }
    }
 
-   public synchronized void stop() throws Exception
+   public synchronized boolean stop() throws Exception
    {
       if (!isStarted())
       {
-         return;
+         return false;
       }
 
       try
@@ -173,6 +173,8 @@
       {
          clearEnvironmentServerIndex();
       }
+
+      return true;
    }
 
    public synchronized void kill() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -145,10 +145,11 @@
       server.start(containerConfig);
    }
 
-   public void stop() throws Exception
+   public boolean stop() throws Exception
    {
-      server.stop();
+      boolean result = server.stop();
       namingDelegate.reset();
+      return result;
    }
 
    public synchronized void kill() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -49,7 +49,11 @@
 
    void start(String containerConfig) throws Exception;
 
-   void stop() throws Exception;
+   /**
+    * @return true if the server was stopped indeed, or false if the server was stopped already
+    *         when the method was invoked.
+    */
+   boolean stop() throws Exception;
 
    /**
     * For a remote server, it "abruptly" kills the VM running the server. For a local server

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jndi/RemoteContext.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -58,7 +58,7 @@
       
       namingDelegate = (NamingDelegate)Naming.lookup(n);
 
-      log.info("remote context for server " + remoteServerIndex + " acquired from rmi:" + n);
+      log.debug("remote context for server " + remoteServerIndex + " acquired from rmi:" + n);
    }
 
    // Context implementation ----------------------------------------

Deleted: trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-15 22:00:01 UTC (rev 1803)
+++ trunk/tests/src/org/jboss/test/messaging/util/ServerManagementTest.java	2006-12-16 04:27:46 UTC (rev 1804)
@@ -1,159 +0,0 @@
-/**
- * JBoss, Home of Professional Open Source
- *
- * Distributable under LGPL license.
- * See terms of license at gnu.org.
- */
-package org.jboss.test.messaging.util;
-
-import org.jboss.test.messaging.MessagingTestCase;
-import org.jboss.test.messaging.tools.ServerManagement;
-
-import javax.naming.InitialContext;
-import javax.management.ObjectName;
-
-/**
- * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
- * @version <tt>$Revision$</tt>
- *
- * $Id$
- */
-public class ServerManagementTest extends MessagingTestCase
-{
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   public ServerManagementTest(String name)
-   {
-      super(name);
-   }
-
-   // Public --------------------------------------------------------
-
-   public void testSpawnServer() throws Exception
-   {
-      try
-      {
-         ServerManagement.start(0, "all");
-
-         ServerManagement.start(0, "all");
-      }
-      finally
-      {
-         ServerManagement.kill(0);
-      }
-   }
-
-   public void testSimpleSpawn() throws Exception
-   {
-      if (!ServerManagement.isRemote())
-      {
-         fail("This test must be run in remote mode!");
-      }
-
-      try
-      {
-         log.info("Waiting for server 7 to start ...");
-
-         ServerManagement.start(7, "all");
-
-         log.info("Server 7 started");
-
-         Integer index = (Integer)ServerManagement.
-            getAttribute(7, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
-
-         assertEquals(7, index.intValue());
-
-         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(7));
-
-         ic.bind("/xxx", "yyy");
-
-         assertEquals("yyy", ic.lookup("/xxx"));
-      }
-      finally
-      {
-         log.info("Killing server 7");
-         ServerManagement.kill(7);
-      }
-   }
-
-   public void testRessurect() throws Exception
-   {
-      if (!ServerManagement.isRemote())
-      {
-         fail("This test must be run in remote mode!");
-      }
-
-      try
-      {
-         ServerManagement.start(1, "all");
-
-         ServerManagement.kill(1);
-
-         // wait a bit for the server to die
-
-         log.info("Sleeping for 10 seconds ...");
-
-         Thread.sleep(10000);
-
-         // resurrect the server
-
-         ServerManagement.start(1, "all");
-
-         Integer index = (Integer)ServerManagement.
-            getAttribute(1, new ObjectName("jboss.messaging:service=ServerPeer"), "serverPeerID");
-
-         assertEquals(1, index.intValue());
-
-         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(1));
-
-         ic.bind("/xxx", "yyy");
-
-         assertEquals("yyy", ic.lookup("/xxx"));
-      }
-      finally
-      {
-         ServerManagement.kill(1);
-      }
-   }
-
-   public void testA()
-   {
-      System.out.println("A");
-   }
-
-   public void testB()
-   {
-      System.out.println("B");
-   }
-
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   protected void setUp() throws Exception
-   {
-      super.setUp();
-
-      log.debug("setup done");
-   }
-
-   protected void tearDown() throws Exception
-   {
-      super.tearDown();
-
-      // TODO: clean up spawned servers
-
-   }
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}



From gavin.king at jboss.com  Fri Dec 15 23:34:06 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 23:34:06 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvRFO-0006Nt-Fb@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 23:34:06

  Modified:    src/main/org/jboss/seam  core-1.1.xsd
  Log:
  transaction success events
  
  Revision  Changes    Path
  1.16      +8 -0      jboss-seam/src/main/org/jboss/seam/core-1.1.xsd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: core-1.1.xsd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core-1.1.xsd,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- core-1.1.xsd	27 Nov 2006 03:33:27 -0000	1.15
  +++ core-1.1.xsd	16 Dec 2006 04:34:06 -0000	1.16
  @@ -27,6 +27,14 @@
       </xs:element>
       <xs:attributeGroup name="attlist.dispatcher"> </xs:attributeGroup>
   
  +    <xs:element name="transactionListener">
  +        <xs:complexType mixed="true">
  +            <xs:attributeGroup ref="components:attlist.component"/>
  +            <xs:attributeGroup ref="core:attlist.transactionListener"/>
  +        </xs:complexType>
  +    </xs:element>
  +    <xs:attributeGroup name="attlist.transactionListener"> </xs:attributeGroup>
  +
       <xs:element name="ejb">
           <xs:complexType mixed="true">
               <xs:attributeGroup ref="components:attlist.component"/>
  
  
  


From gavin.king at jboss.com  Fri Dec 15 23:34:06 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 23:34:06 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core    ...
Message-ID: <E1GvRFO-0006O6-Jh@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 23:34:06

  Modified:    src/main/org/jboss/seam/core    Events.java
  Added:       src/main/org/jboss/seam/core   
                        LocalTransactionListener.java
                        TransactionListener.java
  Log:
  transaction success events
  
  Revision  Changes    Path
  1.15      +5 -0      jboss-seam/src/main/org/jboss/seam/core/Events.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Events.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Events.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- Events.java	16 Dec 2006 02:58:10 -0000	1.14
  +++ Events.java	16 Dec 2006 04:34:06 -0000	1.15
  @@ -121,6 +121,11 @@
         Dispatcher.instance().scheduleEvent(type, 0l, null, null, parameters);
      }
      
  +   public void raiseTransactionSuccessEvent(String type, Object... parameters)
  +   {
  +      TransactionListener.instance().scheduleEvent(type, parameters);
  +   }
  +   
      public void raiseTimedEvent(String type, long duration, Object... parameters)
      {
         Dispatcher.instance().scheduleEvent(type, duration, null, null, parameters);
  
  
  
  1.1      date: 2006/12/16 04:34:06;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/LocalTransactionListener.java
  
  Index: LocalTransactionListener.java
  ===================================================================
  package org.jboss.seam.core;
  
  import javax.ejb.Local;
  
  @Local
  public interface LocalTransactionListener
  {
     public void scheduleEvent(String type, Object... parameters);
     public void destroy();
  }
  
  
  
  1.1      date: 2006/12/16 04:34:06;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/TransactionListener.java
  
  Index: TransactionListener.java
  ===================================================================
  package org.jboss.seam.core;
  
  import static org.jboss.seam.annotations.Install.BUILT_IN;
  
  import java.rmi.RemoteException;
  import java.util.ArrayList;
  import java.util.List;
  
  import javax.ejb.EJBException;
  import javax.ejb.Remove;
  import javax.ejb.SessionSynchronization;
  import javax.ejb.Stateful;
  
  import org.jboss.seam.Component;
  import org.jboss.seam.ScopeType;
  import org.jboss.seam.annotations.Destroy;
  import org.jboss.seam.annotations.Install;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Scope;
  import org.jboss.seam.contexts.Contexts;
  
  @Stateful
  @Scope(ScopeType.EVENT)
  @Name("org.jboss.seam.core.transactionListener")
  @Install(value=false, precedence=BUILT_IN)
  public class TransactionListener implements LocalTransactionListener, SessionSynchronization
  {
     static class Event
     {
        private String type;
        private Object[] parameters;
        
        public Event(String type, Object[] parameters)
        {
           this.type = type;
           this.parameters = parameters;
        }
        public void call()
        {
           Events.instance().raiseEvent( type, parameters );
        }
     }
  
     private List<Event> events = new ArrayList<Event>();
     
     public static LocalTransactionListener instance()
     {
        if ( !Contexts.isApplicationContextActive() )
        {
           throw new IllegalStateException("no application context active");
        }
        return (LocalTransactionListener) Component.getInstance(TransactionListener.class);         
     }
     
     public void afterBegin() throws EJBException, RemoteException
     {
     }
     
     public void scheduleEvent(String type, Object... parameters)
     {
        events.add( new Event(type, parameters) );
     }
  
     public void afterCompletion(boolean success) throws EJBException, RemoteException
     {
        try
        {
           if (success)
           {
              for (Event event: events) event.call();
           }
        }
        finally
        {
           events.clear();
        }
     }
  
     public void beforeCompletion() throws EJBException, RemoteException
     {
     }
     
     @Remove @Destroy
     public void destroy() {}
  
  }
  
  
  


From gavin.king at jboss.com  Fri Dec 15 23:34:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 23:34:58 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1GvRGE-0006OP-E6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 23:34:58

  Modified:    examples/booking/src/org/jboss/seam/example/booking 
                        HotelBookingAction.java
  Log:
  transaction success event
  
  Revision  Changes    Path
  1.42      +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelBookingAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java,v
  retrieving revision 1.41
  retrieving revision 1.42
  diff -u -b -r1.41 -r1.42
  --- HotelBookingAction.java	17 Nov 2006 02:49:04 -0000	1.41
  +++ HotelBookingAction.java	16 Dec 2006 04:34:58 -0000	1.42
  @@ -1,4 +1,4 @@
  -//$Id: HotelBookingAction.java,v 1.41 2006/11/17 02:49:04 gavin Exp $
  +//$Id: HotelBookingAction.java,v 1.42 2006/12/16 04:34:58 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static javax.persistence.PersistenceContextType.EXTENDED;
  @@ -96,7 +96,7 @@
         em.persist(booking);
         facesMessages.add("Thank you, #{user.name}, your confimation number for #{hotel.name} is #{booking.id}");
         log.info("New booking: #{booking.id} for #{user.username}");
  -      events.raiseEvent("bookingConfirmed");
  +      events.raiseTransactionSuccessEvent("bookingConfirmed");
         return "confirmed";
      }
      
  
  
  


From gavin.king at jboss.com  Fri Dec 15 23:34:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Fri, 15 Dec 2006 23:34:58 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GvRGE-0006OW-HO@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/15 23:34:58

  Modified:    examples/booking/resources/WEB-INF  components.xml
  Log:
  transaction success event
  
  Revision  Changes    Path
  1.8       +2 -0      jboss-seam/examples/booking/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/components.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- components.xml	21 Nov 2006 01:01:19 -0000	1.7
  +++ components.xml	16 Dec 2006 04:34:58 -0000	1.8
  @@ -15,6 +15,8 @@
                     conversation-id-parameter="cid"
                     conversation-is-long-running-parameter="clr"/>
   
  +    <core:transactionListener/>
  +
       <core:ejb installed="@embeddedEjb@"/>
   
   </components>
  \ No newline at end of file
  
  
  


From forge-admin at jboss.com  Sat Dec 16 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sat, 16 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GvSax-0007nX-Au@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-15 01:01 EST)
-----------------

better handling when tx rolls back

  jboss-seam  src/main/org/jboss/seam/contexts/EntityBean.java                            1.4
  jboss-seam  src/main/org/jboss/seam/contexts/PassivatedEntity.java                      1.3
  jboss-seam  src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java  1.16


Commit from tokada on branch JBossProfiler_Expansion (2006-12-15 01:14 EST)
----------------------------------------------------

Added a function of setting categories of the webapp analyzer.

  jboss-profiler  java/webapp/lzx/stacktracediagram.lzx       1.1.2.5
  jboss-profiler  java/webapp/lzx/settingdialog.lzx           1.1.2.5
  jboss-profiler  java/webapp/lzx/webapplicationanalyzer.lzx  1.1.2.4


Commit from tokada on branch JBossProfiler_Expansion (2006-12-15 01:21 EST)
----------------------------------------------------

Modified an implementation concerned the servlet.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/collector/ThreadMetricCollector.java  1.1.2.5


Commit from tokada on branch JBossProfiler_Expansion (2006-12-15 01:41 EST)
----------------------------------------------------

*** empty log message ***

  jboss-profiler  exsamples/jboss-profiler.aop/META-INF/jboss-aop.xml  1.1.2.6


Commit from gavin (2006-12-15 01:50 EST)
-----------------

JBSEAM-580

  jboss-seam  src/main/org/jboss/seam/core/Validation.java  1.5


Commit from gavin (2006-12-15 02:18 EST)
-----------------

JBSEAM-478

  jboss-seam  src/main/org/jboss/seam/jsf/SeamELResolver.java  1.4


Commit from gavin (2006-12-15 03:18 EST)
-----------------

JBSEAM-598

  jboss-seam  seam-gen/build.xml  1.50


Commit from gavin (2006-12-15 03:32 EST)
-----------------

oops

  jboss-seam  seam-gen/build.xml  1.51


Commit from gavin (2006-12-15 04:17 EST)
-----------------

mo' betta' handling of schemas and catalogs

  jboss-seam  seam-gen/resources/META-INF/persistence.xml  1.8
  jboss-seam  seam-gen/build.xml                           1.52


Commit from gavin (2006-12-15 04:24 EST)
-----------------

mo' betta' handling of schemas and catalogs

  jboss-seam  seam-gen/build.xml                           1.53
  jboss-seam  seam-gen/resources/META-INF/persistence.xml  1.9


Commit from gavin (2006-12-15 07:52 EST)
-----------------

fix JBSEAM-593

  jboss-seam  src/main/org/jboss/seam/core/ConversationEntry.java  1.32


Commit from gavin (2006-12-15 08:26 EST)
-----------------

prices

  jboss-seam  examples/booking/resources/import.sql                             1.11
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Booking.java  1.12
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Hotel.java    1.11
  jboss-seam  examples/booking/view/book.xhtml                                  1.28
  jboss-seam  examples/booking/view/confirm.xhtml                               1.17
  jboss-seam  examples/booking/view/hotel.xhtml                                 1.14


Commit from sbryzak2 (2006-12-15 08:36 EST)
--------------------

some bug fixes, updates to security example

  jboss-seam  build.xml                                                           1.122
  jboss-seam  examples/seamspace/resources/META-INF/application.xml               1.5
+ jboss-seam  examples/seamspace/resources/META-INF/security-config.xml           1.1
  jboss-seam  examples/seamspace/resources/WEB-INF/components.xml                 1.8
  jboss-seam  examples/seamspace/view/securityError.xhtml                         1.2
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java  1.5
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConstraint.java     1.4
  jboss-seam  src/main/org/jboss/seam/security/config/WebResourceCollection.java  1.3
  jboss-seam  src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java     1.14


Commit from tdiesler (2006-12-15 08:58 EST)
--------------------

add xerces-2.9.0

+ repository.jboss.com  apache-xerces/2.9.0/component-info.xml  1.1
+ repository.jboss.com  apache-xerces/2.9.0/lib/resolver.jar    1.1
+ repository.jboss.com  apache-xerces/2.9.0/lib/serializer.jar  1.1
+ repository.jboss.com  apache-xerces/2.9.0/lib/xercesImpl.jar  1.1
+ repository.jboss.com  apache-xerces/2.9.0/lib/xml-apis.jar    1.1


Commit from msurtani (2006-12-15 09:19 EST)
--------------------

Upgraded to use JGroups anycast

  JBossCache  src/org/jboss/cache/TreeCache.java                       1.293
- JBossCache  tests/functional/org/jboss/cache/JGroupsConfigTest.java  1.2


Commit from msurtani (2006-12-15 09:22 EST)
--------------------

wc

  JBossCache  tests/functional/org/jboss/cache/LifeCycleTest.java  1.5


Commit from gavin (2006-12-15 09:30 EST)
-----------------

javadoc
allow use of customized view ids in a pageflow

  jboss-seam  src/main/org/jboss/seam/core/Manager.java   1.125
  jboss-seam  src/main/org/jboss/seam/core/Pageflow.java  1.46
  jboss-seam  src/main/org/jboss/seam/core/Pages.java     1.58
  jboss-seam  src/main/org/jboss/seam/mock/SeamTest.java  1.58


Commit from msurtani (2006-12-15 10:18 EST)
--------------------

fixed broken uts

  JBossCache  tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java         1.15
  JBossCache  tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java  1.11


Commit from msurtani (2006-12-15 10:28 EST)
--------------------

refactored

  JBossCache  tests/functional/org/jboss/cache/options/SuppressLockingTest.java  1.8


Commit from tdiesler (2006-12-15 11:03 EST)
--------------------

URL: https://svn.jboss.org/repos/jbossws/trunk
Repository Root: https://svn.jboss.org/repos/jbossws
Repository UUID: 50344849-fb0f-0410-a53f-a94597aac05c
Revision: 1660
Node Kind: directory
Schedule: normal
Last Changed Author: thomas.diesler at jboss.com
Last Changed Rev: 1660
Last Changed Date: 2006-12-15 16:59:56 +0100 (Fri, 15 Dec 2006)

  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar                1.32
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar                 1.31
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar                  1.32
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar              1.43
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar   1.5
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar  1.5
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.deployer                1.4
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar                     1.43


Commit from nrichards (2006-12-15 11:27 EST)
---------------------

JBSEAM-546: copy mechanism from jboss run.sh

  jboss-seam  seam  1.16


Commit from msurtani (2006-12-15 12:30 EST)
--------------------

refactored

  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java  1.38
  JBossCache  src/org/jboss/cache/NodeImpl.java                                  1.26
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java   1.38


Commit from msurtani (2006-12-15 12:49 EST)
--------------------

refactored

  JBossCache  tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java  1.21
  JBossCache  src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java                 1.18


Commit from gavin (2006-12-15 12:59 EST)
-----------------

add seam built-in messages

  jboss-seam  seam-gen/resources/messages_en.properties  1.4


Commit from mandersen (2006-12-15 16:30 EST)
---------------------

comments in generated pojo clean up

  jboss-seam  seam-gen/lib/hibernate-tools.jar  1.6


Commit from gavin (2006-12-15 21:16 EST)
-----------------

rip out commons-logging, in order to solve   JBSEAM-581

  jboss-seam  src/main/org/jboss/seam/Component.java                                         1.220
+ jboss-seam  src/main/org/jboss/seam/log/JDKProvider.java                                   1.1
+ jboss-seam  src/main/org/jboss/seam/log/Log4JProvider.java                                 1.1
  jboss-seam  src/main/org/jboss/seam/log/LogImpl.java                                       1.8
+ jboss-seam  src/main/org/jboss/seam/log/LogProvider.java                                   1.1
+ jboss-seam  src/main/org/jboss/seam/log/Logging.java                                       1.1
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java  1.12


Commit from gavin (2006-12-15 21:20 EST)
-----------------

rip out commons-logging, in order to solve   JBSEAM-581

  jboss-seam  examples/icefaces/src/org/jboss/seam/example/booking/test/BookingUnitTest.java   1.2
  jboss-seam  examples/glassfish/src/org/jboss/seam/example/booking/test/BookingUnitTest.java  1.2


Commit from nrichards (2006-12-15 21:58 EST)
---------------------

update logging

  jboss-seam  src/main/org/jboss/seam/Component.java                                 1.221
  jboss-seam  src/main/org/jboss/seam/contexts/BusinessProcessContext.java           1.33
  jboss-seam  src/main/org/jboss/seam/contexts/Contexts.java                         1.46
  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java                        1.72
  jboss-seam  src/main/org/jboss/seam/core/Ejb.java                                  1.20
  jboss-seam  src/main/org/jboss/seam/core/Events.java                               1.14
  jboss-seam  src/main/org/jboss/seam/core/Exceptions.java                           1.17
  jboss-seam  src/main/org/jboss/seam/core/Interpolator.java                         1.13
  jboss-seam  src/main/org/jboss/seam/core/Jbpm.java                                 1.40
  jboss-seam  src/main/org/jboss/seam/core/ManagedHibernateSession.java              1.27
  jboss-seam  src/main/org/jboss/seam/core/ManagedJbpmContext.java                   1.22
  jboss-seam  src/main/org/jboss/seam/core/ManagedPersistenceContext.java            1.29
  jboss-seam  src/main/org/jboss/seam/core/Manager.java                              1.126
  jboss-seam  src/main/org/jboss/seam/core/Pageflow.java                             1.47
  jboss-seam  src/main/org/jboss/seam/core/Pages.java                                1.59
  jboss-seam  src/main/org/jboss/seam/core/PojoCache.java                            1.7
  jboss-seam  src/main/org/jboss/seam/core/ResourceBundle.java                       1.24
  jboss-seam  src/main/org/jboss/seam/deployment/ComponentScanner.java               1.5
  jboss-seam  src/main/org/jboss/seam/deployment/NamespaceScanner.java               1.5
  jboss-seam  src/main/org/jboss/seam/deployment/Scanner.java                        1.22
  jboss-seam  src/main/org/jboss/seam/init/Initialization.java                       1.133
  jboss-seam  src/main/org/jboss/seam/intercept/RootInterceptor.java                 1.7
  jboss-seam  src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java          1.10
  jboss-seam  src/main/org/jboss/seam/interceptors/BijectionInterceptor.java         1.24
  jboss-seam  src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java   1.47
  jboss-seam  src/main/org/jboss/seam/interceptors/ConversationalInterceptor.java    1.11
  jboss-seam  src/main/org/jboss/seam/interceptors/RemoveInterceptor.java            1.18
  jboss-seam  src/main/org/jboss/seam/interceptors/ValidationInterceptor.java        1.24
  jboss-seam  src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java             1.30
  jboss-seam  src/main/org/jboss/seam/jsf/SeamPhaseListener.java                     1.94
  jboss-seam  src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java              1.17
  jboss-seam  src/main/org/jboss/seam/jsf/SeamVariableResolver.java                  1.18
  jboss-seam  src/main/org/jboss/seam/log/Logging.java                               1.2
  jboss-seam  src/main/org/jboss/seam/microcontainer/DataSourceFactory.java          1.9
  jboss-seam  src/main/org/jboss/seam/microcontainer/TransactionManagerFactory.java  1.13
  jboss-seam  src/main/org/jboss/seam/pageflow/PageflowHelper.java                   1.2
  jboss-seam  src/main/org/jboss/seam/remoting/ExecutionHandler.java                 1.20
  jboss-seam  src/main/org/jboss/seam/remoting/InterfaceGenerator.java               1.26
  jboss-seam  src/main/org/jboss/seam/remoting/PollHandler.java                      1.9
  jboss-seam  src/main/org/jboss/seam/remoting/SeamRemotingServlet.java              1.12
  jboss-seam  src/main/org/jboss/seam/remoting/messaging/SubscriptionRegistry.java   1.12
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java              1.27
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java     1.6
  jboss-seam  src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java        1.15
  jboss-seam  src/main/org/jboss/seam/servlet/SeamExceptionFilter.java               1.21
  jboss-seam  src/main/org/jboss/seam/servlet/SeamListener.java                      1.20
  jboss-seam  src/main/org/jboss/seam/servlet/SeamServletFilter.java                 1.11
  jboss-seam  src/main/org/jboss/seam/theme/ThemeSelector.java                       1.9
  jboss-seam  src/main/org/jboss/seam/util/DTDEntityResolver.java                    1.2
  jboss-seam  src/main/org/jboss/seam/util/Naming.java                               1.5
  jboss-seam  src/main/org/jboss/seam/util/Work.java                                 1.2
  jboss-seam  src/ui/org/jboss/seam/ui/UICache.java                                  1.6
  jboss-seam  src/ui/org/jboss/seam/ui/tag/HtmlComponentBodyTagBase.java             1.3
  jboss-seam  src/ui/org/jboss/seam/ui/tag/HtmlMessageTagBase.java                   1.3
  jboss-seam  src/ui/org/jboss/seam/ui/tag/UIComponentBodyTagBase.java               1.3
  jboss-seam  src/ui/org/jboss/seam/ui/tag/UIComponentTagBase.java                   1.9


Commit from gavin (2006-12-15 23:34 EST)
-----------------

transaction success events

  jboss-seam  src/main/org/jboss/seam/core-1.1.xsd                        1.16
  jboss-seam  src/main/org/jboss/seam/core/Events.java                    1.15
+ jboss-seam  src/main/org/jboss/seam/core/LocalTransactionListener.java  1.1
+ jboss-seam  src/main/org/jboss/seam/core/TransactionListener.java       1.1


Commit from gavin (2006-12-15 23:34 EST)
-----------------

transaction success event

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java  1.42
  jboss-seam  examples/booking/resources/WEB-INF/components.xml                            1.8
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061216/3a674548/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Sat Dec 16 01:09:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 16 Dec 2006 01:09:01 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1805 - in trunk/tests: . bin etc
	etc/stress src/org/jboss/test/messaging/tools
Message-ID: <E1GvSjF-00084i-VV@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-16 01:08:50 -0500 (Sat, 16 Dec 2006)
New Revision: 1805

Modified:
   trunk/tests/bin/runtest
   trunk/tests/bin/start-rmi-server
   trunk/tests/build.xml
   trunk/tests/etc/log4j.info.xml
   trunk/tests/etc/log4j.trace.xml
   trunk/tests/etc/log4j.xml
   trunk/tests/etc/stress/log4j.xml
   trunk/tests/maven-tests.xml
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
Log:
Refined log generation mechanism. Different type of tests generate log in differently 
named files (messaging-invm.log, messaging-remote-client.log, messaging-remote-server.log
messaging-clustering-serverX.log, etc)


Modified: trunk/tests/bin/runtest
===================================================================
--- trunk/tests/bin/runtest	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/bin/runtest	2006-12-16 06:08:50 UTC (rev 1805)
@@ -78,6 +78,8 @@
     SEP=":"
 fi
 
+TEST_LOGFILE_SUFFIX=invm
+
 while [ "$1" != "" ]; do
     if [ "$1" = "-debug" ]; then
         if [ $cygwin = false ]; then
@@ -99,6 +101,7 @@
     if [ "$1" = "-remote" ]; then
         isRemote=true;
         REMOTE_TEST="-Dremote=true"
+        TEST_LOGFILE_SUFFIX=remote-client
         shift
         continue;
     fi
@@ -114,6 +117,7 @@
     fi
     if [ "$1" = "-clustered" ]; then
         TEST_CLUSTERED=true
+        TEST_LOGFILE_SUFFIX=clustering-client
         shift
         continue;
     else
@@ -122,7 +126,15 @@
     fi
 done
 
-JAVA_OPTS="-Xmx1024M $JAVA_OPTS -Dmodule.output=$reldir/../output $REMOTE_TEST -Dtest.database=$TEST_DATABASE -Dtest.serialization=$TEST_SERIALIZATION -Dtest.clustered=$TEST_CLUSTERED -Dtest.remoting=$TEST_REMOTING -Dbuild.lib=../../output/lib"
+JAVA_OPTS="-Xmx1024M $JAVA_OPTS \
+-Dmodule.output=$reldir/../output \
+$REMOTE_TEST \
+-Dtest.database=$TEST_DATABASE \
+-Dtest.serialization=$TEST_SERIALIZATION \
+-Dtest.clustered=$TEST_CLUSTERED \
+-Dtest.remoting=$TEST_REMOTING \
+-Dtest.logfile.suffix=$TEST_LOGFILE_SUFFIX \
+-Dbuild.lib=../../output/lib"
 
 if [ "$TARGET_TEST" != "" ]; then
    TARGET_TEST="-t $TARGET_TEST"

Modified: trunk/tests/bin/start-rmi-server
===================================================================
--- trunk/tests/bin/start-rmi-server	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/bin/start-rmi-server	2006-12-16 06:08:50 UTC (rev 1805)
@@ -48,7 +48,7 @@
 
 mkdir -p $reldir/../output/logs
 
-JAVA_OPTS="$JAVA_OPTS -Xmx768M -Dmodule.output=$reldir/../output -Dremote.test.suffix=-remote-$index"
+JAVA_OPTS="$JAVA_OPTS -Xmx768M -Dmodule.output=$reldir/../output"
 
 if [ "$TEST_DATABASE" != "" ]; then
    JAVA_OPTS="$JAVA_OPTS -Dtest.database=$TEST_DATABASE"
@@ -58,18 +58,19 @@
    JAVA_OPTS="$JAVA_OPTS -Dtest.serialization=$TEST_SERIALIZATION"
 fi
 
+if [ "$TEST_REMOTING" != "" ]; then
+   JAVA_OPTS="$JAVA_OPTS -Dtest.remoting=$TEST_REMOTING -Dtest.logfile.suffix=remote-server"
+fi
+
 if [ "$TEST_CLUSTERED" != "" ]; then
-   JAVA_OPTS="$JAVA_OPTS -Dtest.clustered=$TEST_CLUSTERED"
+   # last defined system property on command line take precedence
+   JAVA_OPTS="$JAVA_OPTS -Dtest.clustered=$TEST_CLUSTERED -Dtest.logfile.suffix=clustering-server$index"
 fi
 
 if [ "$index" != "" ]; then
    JAVA_OPTS="$JAVA_OPTS -Dtest.server.index=$index"
 fi
 
-if [ "$TEST_REMOTING" != "" ]; then
-   JAVA_OPTS="$JAVA_OPTS -Dtest.remoting=$TEST_REMOTING"
-fi
-
 if [ "$USE_EXISTENT_TEST_CLASSPATH_FILE" = "true" ]; then
    CLASSPATH_FILE="$reldir/.test.execution.classpath"
 else

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/build.xml	2006-12-16 06:08:50 UTC (rev 1805)
@@ -75,7 +75,14 @@
    -->
    <property name="test.remoting" value="socket"/>
 
+
    <!--
+       By default, remote servers log file names should end in remote-server
+   -->
+   <property name="remote.server.test.logfile.suffix" value="remote-server"/>
+
+
+   <!--
         Project paths.
    -->
 
@@ -273,7 +280,7 @@
 
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
          <sysproperty key="module.output" value="${tests.output}"/>
-         <sysproperty key="remote.test.suffix" value="-remote"/>
+         <sysproperty key="test.logfile.suffix" value="${remote.server.test.logfile.suffix}"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
@@ -291,7 +298,7 @@
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
          <sysproperty key="test.server.index" value="${test.server.index}"/>
          <sysproperty key="module.output" value="${tests.output}"/>
-         <sysproperty key="remote.test.suffix" value="-remote-${test.server.index}"/>
+         <sysproperty key="test.logfile.suffix" value="clustering-server${test.server.index}"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${clustering.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
@@ -309,7 +316,7 @@
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
          <jvmarg value="-Xmx768M"/>
          <sysproperty key="module.output" value="${tests.output}"/>
-         <sysproperty key="remote.test.suffix" value="-remote"/>
+         <sysproperty key="test.logfile.suffix" value="remote-server-stress"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${stress.tests.database}"/>
          <sysproperty key="test.serialization" value="${stress.tests.serialization}"/>
@@ -344,6 +351,7 @@
       <antcall target="remote-tests">
          <param name="test.remoting" value="http"/>
       </antcall>
+      <antcall target="clustering-tests"/>
    </target>
 
    <target name="stress-tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
@@ -374,6 +382,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.logfile.suffix" value="invm"/>
          <sysproperty key="build.lib" value="${build.lib}"/>
          <jvmarg value="-Xmx512M"/>
          <!--
@@ -493,6 +502,7 @@
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${stress.tests.database}"/>
          <sysproperty key="test.serialization" value="${stress.tests.serialization}"/>
+         <sysproperty key="test.logfile.suffix" value="invm"/>
          <jvmarg value="-Xmx512M"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
@@ -539,6 +549,7 @@
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
          <sysproperty key="test.remoting" value="${test.remoting}"/>
+         <sysproperty key="test.logfile.suffix" value="remote-client"/>
          <jvmarg value="-Xmx512M"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
@@ -610,6 +621,7 @@
          <sysproperty key="test.database" value="${stress.tests.database}"/>
          <sysproperty key="test.serialization" value="${stress.tests.serialization}"/>
          <sysproperty key="test.remoting" value="${test.remoting}"/>
+         <sysproperty key="test.logfile.suffix" value="remote-client"/>
          <jvmarg value="-Xmx512M"/>
          <!-- <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=unittest"/> -->
          <classpath>
@@ -714,6 +726,7 @@
          <sysproperty key="test.database" value="${clustering.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
          <sysproperty key="test.clustered" value="true"/>
+         <sysproperty key="test.logfile.suffix" value="clustering-client"/>
          <jvmarg value="-Xmx512M"/>
          <!--
          <jvmarg line="-Xmx512M -Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=n,suspend=n,address=antjunit"/>
@@ -795,7 +808,9 @@
           ClientCrashTest over "socket"
       -->
 
-      <antcall target="start-rmi-server"/>
+      <antcall target="start-rmi-server">
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
+      </antcall>
 
       <antcall target="crash-test">
          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTest"/>
@@ -807,6 +822,7 @@
 
       <antcall target="start-rmi-server">
          <param name="test.remoting" value="http"/>
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
       </antcall>
 
       <antcall target="crash-test">
@@ -818,8 +834,11 @@
           ClientCrashTwoConnectionsTest over "socket"
       -->
 
-      <antcall target="start-rmi-server"/>
+      <antcall target="start-rmi-server">
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
+      </antcall>
 
+
       <antcall target="crash-test">
          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTwoConnectionsTest"/>
       </antcall>
@@ -830,6 +849,7 @@
 
       <antcall target="start-rmi-server">
          <param name="test.remoting" value="http"/>
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
       </antcall>
 
       <antcall target="crash-test">
@@ -841,8 +861,11 @@
           ClientCrashNegativeLeaseTest over "socket"
       -->
 
-      <antcall target="start-rmi-server"/>
+      <antcall target="start-rmi-server">
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
+      </antcall>
 
+
       <antcall target="crash-test">
          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashNegativeLeaseTest"/>
       </antcall>
@@ -853,6 +876,7 @@
 
       <antcall target="start-rmi-server">
          <param name="test.remoting" value="http"/>
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
       </antcall>
 
       <antcall target="crash-test">
@@ -864,8 +888,11 @@
           ClientCrashZeroLeaseTest over "socket"
       -->
 
-      <antcall target="start-rmi-server"/>
+      <antcall target="start-rmi-server">
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
+      </antcall>
 
+
       <antcall target="crash-test">
           <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashZeroLeaseTest"/>
       </antcall>
@@ -876,6 +903,7 @@
 
       <antcall target="start-rmi-server">
          <param name="test.remoting" value="http"/>
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
       </antcall>
 
       <antcall target="crash-test">
@@ -887,8 +915,11 @@
           ClientCrashLargeLeaseTest over "socket"
       -->
 
-      <antcall target="start-rmi-server"/>
+      <antcall target="start-rmi-server">
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
+      </antcall>
 
+
       <antcall target="crash-test">
           <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashLargeLeaseTest"/>
       </antcall>
@@ -899,6 +930,7 @@
 
       <antcall target="start-rmi-server">
          <param name="test.remoting" value="http"/>
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
       </antcall>
 
       <antcall target="crash-test">
@@ -910,8 +942,11 @@
           CallbackFailureTest over "socket"
       -->
 
-      <antcall target="start-rmi-server"/>
+      <antcall target="start-rmi-server">
+         <param name="remote.server.test.logfile.suffix" value="remote-crash"/>
+      </antcall>
 
+
       <antcall target="crash-test">
           <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.CallbackFailureTest"/>
       </antcall>
@@ -939,6 +974,7 @@
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
          <sysproperty key="test.remoting" value="${test.remoting}"/>
+         <sysproperty key="test.logfile.suffix" value="crash"/>
          <jvmarg value="-Xmx512M"/>
          <!--
          <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>

Modified: trunk/tests/etc/log4j.info.xml
===================================================================
--- trunk/tests/etc/log4j.info.xml	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/etc/log4j.info.xml	2006-12-16 06:08:50 UTC (rev 1805)
@@ -8,7 +8,13 @@
    <appender name="FILE" class="org.jboss.logging.appender.DailyRollingFileAppender">
 
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
-      <param name="File" value="${module.output}/logs/messaging-tests${remote.test.suffix}.trace.log"/>
+      <!--
+          Normally "test.logfile.suffix" takes on of the values: "invm", "remote-client",
+          "remote-server", "clustering-client", "clustering-server<index>", "crash-client",
+          "crash-server", etc.
+      -->
+      <param name="File" value="${module.output}/logs/messaging-${test.logfile.suffix}.log"/>
+
       <param name="DatePattern" value="'.'yyyy-MM-dd"/>
       <param name="Threshold" value="INFO"/>
 

Modified: trunk/tests/etc/log4j.trace.xml
===================================================================
--- trunk/tests/etc/log4j.trace.xml	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/etc/log4j.trace.xml	2006-12-16 06:08:50 UTC (rev 1805)
@@ -8,7 +8,12 @@
    <appender name="FILE" class="org.jboss.logging.appender.DailyRollingFileAppender">
 
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
-      <param name="File" value="${module.output}/logs/messaging-tests${remote.test.suffix}.trace.log"/>
+      <!--
+          Normally "test.logfile.suffix" takes on of the values: "invm", "remote-client",
+          "remote-server", "clustering-client", "clustering-server<index>", "crash-client",
+          "crash-server", etc.
+      -->
+      <param name="File" value="${module.output}/logs/messaging-${test.logfile.suffix}.log"/>
       <param name="DatePattern" value="'.'yyyy-MM-dd"/>
       <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/>
 

Modified: trunk/tests/etc/log4j.xml
===================================================================
--- trunk/tests/etc/log4j.xml	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/etc/log4j.xml	2006-12-16 06:08:50 UTC (rev 1805)
@@ -8,7 +8,12 @@
    <appender name="FILE" class="org.jboss.logging.appender.DailyRollingFileAppender">
 
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
-      <param name="File" value="${module.output}/logs/messaging-tests${remote.test.suffix}.trace.log"/>
+      <!--
+          Normally "test.logfile.suffix" takes on of the values: "invm", "remote-client",
+          "remote-server", "clustering-client", "clustering-server<index>", "crash-client",
+          "crash-server", etc.
+      -->
+      <param name="File" value="${module.output}/logs/messaging-${test.logfile.suffix}.log"/>
       <param name="DatePattern" value="'.'yyyy-MM-dd"/>
       <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/>
 

Modified: trunk/tests/etc/stress/log4j.xml
===================================================================
--- trunk/tests/etc/stress/log4j.xml	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/etc/stress/log4j.xml	2006-12-16 06:08:50 UTC (rev 1805)
@@ -30,7 +30,7 @@
    <appender name="FILE" class="org.jboss.logging.appender.DailyRollingFileAppender">
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
 
-      <param name="File" value="${module.output}/logs/messaging-tests${remote.test.suffix}.stress.log"/>
+      <param name="File" value="${module.output}/logs/messaging-tests${test.logfile.suffix}.stress.log"/>
 
       <!-- since majority of the tests are ran in fork mode by ant, the log file is overwritten
            for each test. We need to append if we want to preserve a full testsuite run log.

Modified: trunk/tests/maven-tests.xml
===================================================================
--- trunk/tests/maven-tests.xml	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/maven-tests.xml	2006-12-16 06:08:50 UTC (rev 1805)
@@ -213,7 +213,7 @@
 
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
          <sysproperty key="module.output" value="${basedir}/target"/>
-         <sysproperty key="remote.test.suffix" value="-remote"/>
+         <sysproperty key="test.logfile.suffix" value="-remote-maven"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${functional.tests.database}"/>
          <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
@@ -238,7 +238,7 @@
       <java classname="org.jboss.test.messaging.tools.jmx.rmi.RMITestServer" fork="true" spawn="true">
          <jvmarg value="-Xmx768M"/>
          <sysproperty key="module.output" value="${tests.output}"/>
-         <sysproperty key="remote.test.suffix" value="-remote"/>
+         <sysproperty key="test.logfile.suffix" value="-remote-maven"/>
          <sysproperty key="test.bind.address" value="${test.bind.address}"/>
          <sysproperty key="test.database" value="${stress.tests.database}"/>
          <sysproperty key="test.serialization" value="${stress.tests.serialization}"/>

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-16 04:27:46 UTC (rev 1804)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-16 06:08:50 UTC (rev 1805)
@@ -141,7 +141,7 @@
          }
          else
          {
-            Server s = acquireRemote(1, i, true);
+            Server s = acquireRemote(2, i, true);
 
             if (s != null)
             {
@@ -307,10 +307,6 @@
       
       sb.append("-Dmodule.output=").append(moduleOutput).append(' ');
 
-      sb.append("-Dremote.test.suffix=-remote-").append(i).append(' ');
-
-      sb.append("-Dtest.server.index=").append(i).append(' ');
-
       sb.append("-Dtest.bind.address=localhost").append(' ');
 
       String database = System.getProperty("test.database");
@@ -325,7 +321,13 @@
          sb.append("-Dtest.serialization=").append(serialization).append(' ');
       }
 
+      sb.append("-Dtest.server.index=").append(i).append(' ');
+
       String clustered = System.getProperty("test.clustered");
+      if (clustered != null && clustered.trim().length() == 0)
+      {
+         clustered = null;
+      }
       if (clustered != null)
       {
          sb.append("-Dtest.clustered=").append(clustered).append(' ');
@@ -337,6 +339,28 @@
          sb.append("-Dtest.remoting=").append(remoting).append(' ');
       }
 
+      String testLogfileSuffix = System.getProperty("test.logfile.suffix");
+
+      if (testLogfileSuffix == null)
+      {
+         testLogfileSuffix = "undefined-test-type";
+      }
+      else
+      {
+         int pos;
+         if ((pos = testLogfileSuffix.lastIndexOf("client")) != -1)
+         {
+            testLogfileSuffix = testLogfileSuffix.substring(0, pos) + "server";
+         }
+
+         if (clustered != null)
+         {
+            testLogfileSuffix += i;
+         }
+      }
+
+      sb.append("-Dtest.logfile.suffix=").append(testLogfileSuffix).append(' ');
+
       String classPath = System.getProperty("java.class.path");
 
       //System.out.println("CLASSPATH: " + classPath);



From Shane_Bryzak at symantec.com  Sat Dec 16 02:33:07 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 16 Dec 2006 02:33:07 -0500
Subject: [jboss-cvs] jboss-seam/examples/remoting/chatroom/resources/WEB-INF
	...
Message-ID: <E1GvU2d-0001A4-Vk@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/16 02:33:07

  Modified:    examples/remoting/chatroom/resources/WEB-INF  components.xml
  Log:
  SubscriptionRegistry not installed by default
  
  Revision  Changes    Path
  1.5       +5 -5      jboss-seam/examples/remoting/chatroom/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/remoting/chatroom/resources/WEB-INF/components.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- components.xml	10 Nov 2006 19:07:56 -0000	1.4
  +++ components.xml	16 Dec 2006 07:33:07 -0000	1.5
  @@ -12,7 +12,7 @@
           <property name="topicJndiName">topic/chatroomTopic</property>
       </component>
   
  -    <component name="org.jboss.seam.remoting.messaging.subscriptionRegistry">
  +    <component class="org.jboss.seam.remoting.messaging.SubscriptionRegistry" installed="true">
           <property name="allowedTopics">chatroomTopic</property>
       </component>
   
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 16 02:33:08 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 16 Dec 2006 02:33:08 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/remoting/messaging ...
Message-ID: <E1GvU2e-0001AC-33@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/16 02:33:08

  Modified:    src/main/org/jboss/seam/remoting/messaging 
                        SubscriptionRegistry.java
  Log:
  SubscriptionRegistry not installed by default
  
  Revision  Changes    Path
  1.13      +1 -1      jboss-seam/src/main/org/jboss/seam/remoting/messaging/SubscriptionRegistry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SubscriptionRegistry.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/messaging/SubscriptionRegistry.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- SubscriptionRegistry.java	16 Dec 2006 02:58:12 -0000	1.12
  +++ SubscriptionRegistry.java	16 Dec 2006 07:33:08 -0000	1.13
  @@ -32,7 +32,7 @@
   @Scope(ScopeType.APPLICATION)
   @Intercept(NEVER)
   @Name("org.jboss.seam.remoting.messaging.subscriptionRegistry")
  - at Install(precedence=BUILT_IN)
  + at Install(value = false, precedence=BUILT_IN)
   public class SubscriptionRegistry
   {
     private static final String DEFAULT_CONNECTION_PROVIDER =
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 16 02:44:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 16 Dec 2006 02:44:21 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl    ...
Message-ID: <E1GvUDV-0001Km-4q@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/16 02:44:21

  Modified:    src/main/org/jboss/seam/security/acl    AclProvider.java
  Removed:     src/main/org/jboss/seam/security/acl   
                        AbstractAclProvider.java PersistentAclProvider.java
  Log:
  consolidate the acl provider stuff into a single Seam component
  
  Revision  Changes    Path
  1.4       +91 -3     jboss-seam/src/main/org/jboss/seam/security/acl/AclProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AclProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/AclProvider.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- AclProvider.java	8 Nov 2006 23:28:38 -0000	1.3
  +++ AclProvider.java	16 Dec 2006 07:44:21 -0000	1.4
  @@ -2,13 +2,24 @@
   
   import java.security.Principal;
   import java.security.acl.Acl;
  +import java.security.acl.AclEntry;
  +import java.security.acl.NotOwnerException;
  +import java.security.acl.Permission;
  +import java.util.HashSet;
  +import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
  +
  +//import org.jboss.seam.annotations.Name;
  +import org.jboss.seam.security.Identity;
   
   /**
    * Provides a list of Acls for an object.
    *
    * @author Shane Bryzak
    */
  -public interface AclProvider
  +//@Name("org.jboss.seam.security.aclProvider")
  +public abstract class AclProvider
   {
     public enum RecipientType {role, user};
   
  @@ -18,7 +29,10 @@
      * @param value Object
      * @return Acl
      */
  -  Acl getAcls(Object value);
  +  public Acl getAcls(Object obj)
  +  {
  +    return internalGetAcls(obj, null);
  +  }
   
     /**
      * Return all Acls for the specified object that apply to the specified Principal.
  @@ -27,5 +41,79 @@
      * @param principal Principal
      * @return Acl
      */
  -  Acl getAcls(Object value, Principal principal);
  +  public Acl getAcls(Object obj, Principal principal)
  +  {
  +    if (principal == null)
  +      throw new IllegalArgumentException("Principal cannot be null");
  +
  +    return internalGetAcls(obj, principal);
  +  }
  +
  +  protected Acl internalGetAcls(Object obj, Principal principal)
  +  {
  +    Principal owner = Identity.instance();
  +
  +    Acl acl = new AclImpl(owner);
  +
  +    AclEntry entry = new AclEntryImpl();
  +
  +    if (principal != null)
  +    {
  +      entry.setPrincipal(principal);
  +
  +      for (Permission p : getPermissions(obj, principal))
  +      {
  +        entry.addPermission(p);
  +      }
  +    }
  +
  +    try
  +    {
  +      acl.addEntry(owner, entry);
  +    }
  +    catch (NotOwnerException ex) { } // caller is owner
  +
  +    return acl;
  +  }
  +
  +
  +  protected Set<Permission> convertToPermissions(Principal principal, Object target, Object perms)
  +  {
  +    if (perms == null)
  +      return null;
  +
  +    //SeamSecurityManager.instance().get
  +
  +        if (List.class.isAssignableFrom(perms.getClass()))
  +        {
  +      Set<Permission> permissions = new HashSet<Permission>();
  +
  +      for (Object o : (List) perms)
  +      {
  +        if (o instanceof Object[])
  +        {
  +          Object[] values = (Object[]) o;
  +          int mask = (Integer) values[0];
  +          String recipient = (String) values[1];
  +          RecipientType recipientType = (RecipientType) values[2];
  +
  +//          DefinePermissions def = target.getClass().getAnnotation(DefinePermissions.class);
  +//          for (org.jboss.seam.annotations.security.AclProvider provider : def.permissions())
  +//          {
  +//            if ((provider.mask() & mask) > 0)
  +              /** todo - use the correct name to create the permission */
  +//              permissions.add(new SeamPermission("permissionName", provider.action()));
  +//          }
  +        }
  +      }
  +
  +      return permissions;
  +        }
  +    else
  +      throw new IllegalArgumentException(String.format(
  +          "Permissions [%s] must be an instance of java.util.List", perms));
  +  }
  +
  +  protected abstract Set<Permission> getPermissions(Object obj, Principal principal);
  +  protected abstract Map<Principal,Set<Permission>> getPermissions(Object obj);
   }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 05:03:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 05:03:45 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/annotations   ...
Message-ID: <E1GvWOP-00048A-4G@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 05:03:45

  Modified:    src/main/org/jboss/seam/annotations   Transactional.java
  Added:       src/main/org/jboss/seam/annotations  
                        TransactionPropagationType.java
  Log:
  JBSEAM-595
  
  Revision  Changes    Path
  1.3       +11 -7     jboss-seam/src/main/org/jboss/seam/annotations/Transactional.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Transactional.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/Transactional.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Transactional.java	24 Apr 2006 00:24:21 -0000	1.2
  +++ Transactional.java	16 Dec 2006 10:03:45 -0000	1.3
  @@ -1,7 +1,7 @@
   package org.jboss.seam.annotations;
   
  -import static java.lang.annotation.ElementType.TYPE;
   import static java.lang.annotation.ElementType.METHOD;
  +import static java.lang.annotation.ElementType.TYPE;
   import static java.lang.annotation.RetentionPolicy.RUNTIME;
   
   import java.lang.annotation.Documented;
  @@ -10,11 +10,10 @@
   import java.lang.annotation.Target;
   
   /**
  - * Specifies that the default behavior for an EJB session bean,
  - * @TransactionAttribute(REQUIRED), should apply to a JavaBean
  - * component or method of a JavaBean component. (JavaBean 
  - * components have @TransactionAttribute(SUPPORTS) behavior 
  - * otherwise.)
  + * Specifies that the transaction propagation for a JavaBean
  + * component or method of a JavaBean component. JavaBean 
  + * components have @Transactional(SUPPORTS) behavior 
  + * is no @Transactional annotation is specified.
    * 
    * @author Gavin King
    */
  @@ -24,5 +23,10 @@
   @Inherited
   public @interface Transactional
   {
  -
  +   /**
  +    * The transaction propagation type.
  +    * 
  +    * @return REQUIRED by default
  +    */
  +   TransactionPropagationType value() default TransactionPropagationType.REQUIRED;
   }
  
  
  
  1.1      date: 2006/12/16 10:03:45;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/annotations/TransactionPropagationType.java
  
  Index: TransactionPropagationType.java
  ===================================================================
  package org.jboss.seam.annotations;
  
  /**
   * Transaction propagation strategies for Seam JavaBean 
   * components. Note that unlike EJB3 components, there 
   * are no strategies for suspending transactions.
   * 
   * @author Gavin King
   *
   */
  public enum TransactionPropagationType
  {
     REQUIRED,
     MANDATORY, 
     SUPPORTS,
     NEVER;
     
     public boolean isNewTransactionRequired(boolean transactionActive)
     {
        try
        {
           switch (this)
           {
              case REQUIRED:
                 return !transactionActive;
              case SUPPORTS:
                 return false;
              case MANDATORY:
                 if ( !transactionActive )
                 {
                    throw new IllegalStateException("No transaction active on call to MANDATORY method");
                 }
              case NEVER:
                 if ( transactionActive )
                 {
                    throw new IllegalStateException("Transaction active on call to NEVER method");
                 }
              default:
                 throw new IllegalArgumentException();
           }
        }
        catch (Exception e)
        {
           throw new RuntimeException(e);
        }
     }
     
  }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 05:03:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 05:03:45 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GvWOP-00048H-7n@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 05:03:45

  Modified:    src/main/org/jboss/seam/core  TransactionListener.java
  Log:
  JBSEAM-595
  
  Revision  Changes    Path
  1.2       +4 -4      jboss-seam/src/main/org/jboss/seam/core/TransactionListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TransactionListener.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- TransactionListener.java	16 Dec 2006 04:34:06 -0000	1.1
  +++ TransactionListener.java	16 Dec 2006 10:03:45 -0000	1.2
  @@ -37,7 +37,7 @@
         }
         public void call()
         {
  -         Events.instance().raiseEvent( type, parameters );
  +         Events.instance().raiseEvent(type, parameters);
         }
      }
   
  @@ -45,11 +45,11 @@
      
      public static LocalTransactionListener instance()
      {
  -      if ( !Contexts.isApplicationContextActive() )
  +      if ( !Contexts.isEventContextActive() )
         {
  -         throw new IllegalStateException("no application context active");
  +         throw new IllegalStateException("no event context active");
         }
  -      return (LocalTransactionListener) Component.getInstance(TransactionListener.class);         
  +      return (LocalTransactionListener) Component.getInstance(TransactionListener.class, ScopeType.EVENT);         
      }
      
      public void afterBegin() throws EJBException, RemoteException
  
  
  


From gavin.king at jboss.com  Sat Dec 16 05:03:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 05:03:45 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GvWOP-00048O-DR@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 05:03:45

  Modified:    src/main/org/jboss/seam/interceptors 
                        TransactionInterceptor.java
  Log:
  JBSEAM-595
  
  Revision  Changes    Path
  1.10      +16 -4     jboss-seam/src/main/org/jboss/seam/interceptors/TransactionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/TransactionInterceptor.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- TransactionInterceptor.java	1 Nov 2006 02:54:02 -0000	1.9
  +++ TransactionInterceptor.java	16 Dec 2006 10:03:45 -0000	1.10
  @@ -1,6 +1,7 @@
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.AnnotatedElement;
  +import java.lang.reflect.Method;
   
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
  @@ -26,17 +27,28 @@
            }
   
            @Override
  -         protected boolean isTransactional()
  +         protected boolean isNewTransactionRequired(boolean transactionActive)
            {
  -            return isTransactional( invocation.getMethod() ) || 
  -                  isTransactional( getComponent().getBeanClass() );
  +            return isNewTransactionRequired( invocation.getMethod(), getComponent().getBeanClass(), transactionActive );
            }
   
  -         private boolean isTransactional(AnnotatedElement element)
  +         private boolean isNewTransactionRequired(Method method, Class beanClass, boolean transactionActive)
  +         {
  +            return isTransactionAnnotationPresent(method) ? 
  +                  isNewTransactionRequired(method, transactionActive) :
  +                  isTransactionAnnotationPresent(beanClass) && isNewTransactionRequired(beanClass, transactionActive);
  +         }
  +
  +         private boolean isTransactionAnnotationPresent(AnnotatedElement element)
            {
               return element.isAnnotationPresent(Transactional.class);
            }
            
  +         private boolean isNewTransactionRequired(AnnotatedElement element, boolean transactionActive)
  +         {
  +            return element.getAnnotation(Transactional.class).value().isNewTransactionRequired(transactionActive);
  +         }
  +         
         }.workInTransaction();      
      }
   
  
  
  


From gavin.king at jboss.com  Sat Dec 16 05:03:45 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 05:03:45 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util  ...
Message-ID: <E1GvWOP-00048V-IC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 05:03:45

  Modified:    src/main/org/jboss/seam/util  Work.java
  Log:
  JBSEAM-595
  
  Revision  Changes    Path
  1.3       +4 -3      jboss-seam/src/main/org/jboss/seam/util/Work.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Work.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Work.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Work.java	16 Dec 2006 02:58:13 -0000	1.2
  +++ Work.java	16 Dec 2006 10:03:45 -0000	1.3
  @@ -11,14 +11,15 @@
      
      protected abstract T work() throws Exception;
      
  -   protected boolean isTransactional()
  +   protected boolean isNewTransactionRequired(boolean transactionActive)
      {
  -      return true;
  +      return !transactionActive;
      }
      
      public final T workInTransaction() throws Exception
      {
  -      boolean begin = isTransactional() && !Transactions.isTransactionActiveOrMarkedRollback();
  +      boolean transactionActive = Transactions.isTransactionActiveOrMarkedRollback();
  +      boolean begin = isNewTransactionRequired(transactionActive);
         UserTransaction userTransaction = begin ? Transactions.getUserTransaction() : null;
         
         if (begin) 
  
  
  


From gavin.king at jboss.com  Sat Dec 16 05:17:14 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 05:17:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors     ...
Message-ID: <E1GvWbS-0004OC-Ou@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 05:17:14

  Modified:    src/main/org/jboss/seam/interceptors    
                        ManagedEntityIdentityInterceptor.java
                        MethodContextInterceptor.java
                        TransactionInterceptor.java
                        ValidationInterceptor.java
  Log:
  javadoc
  
  Revision  Changes    Path
  1.17      +3 -3      jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedEntityIdentityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- ManagedEntityIdentityInterceptor.java	15 Dec 2006 06:01:17 -0000	1.16
  +++ ManagedEntityIdentityInterceptor.java	16 Dec 2006 10:17:14 -0000	1.17
  @@ -15,9 +15,9 @@
   
   /**
    * Swizzles entity references around each invocation, maintaining
  - * referential even across passivation of the stateful bean or
  - * Seam-managed extended persistence context, and allowing for
  - * more efficient replication.
  + * referential integrity even across passivation of the stateful 
  + * bean or Seam-managed extended persistence context, and allowing 
  + * for more efficient replication.
    * 
    * @author Gavin King
    *
  
  
  
  1.2       +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodContextInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MethodContextInterceptor.java	14 Dec 2006 10:27:00 -0000	1.1
  +++ MethodContextInterceptor.java	16 Dec 2006 10:17:14 -0000	1.2
  @@ -8,7 +8,8 @@
   import org.jboss.seam.intercept.InvocationContext;
   
   /**
  - * Unproxies the SFSB for the length of the call.
  + * Sets up the METHOD context and unproxies the SFSB 
  + * for the duration of the call.
    * 
    * @author Gavin King
    *
  
  
  
  1.11      +6 -0      jboss-seam/src/main/org/jboss/seam/interceptors/TransactionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/TransactionInterceptor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- TransactionInterceptor.java	16 Dec 2006 10:03:45 -0000	1.10
  +++ TransactionInterceptor.java	16 Dec 2006 10:17:14 -0000	1.11
  @@ -9,6 +9,12 @@
   import org.jboss.seam.intercept.InvocationContext;
   import org.jboss.seam.util.Work;
   
  +/**
  + * Implements transaction propagation rules for Seam JavaBean components.
  + * 
  + * @author Gavin King
  + *
  + */
   @Interceptor(stateless=true,
                around={RollbackInterceptor.class, BusinessProcessInterceptor.class, ConversationInterceptor.class})
   public class TransactionInterceptor extends AbstractInterceptor
  
  
  
  1.25      +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/ValidationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ValidationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ValidationInterceptor.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- ValidationInterceptor.java	16 Dec 2006 02:58:11 -0000	1.24
  +++ ValidationInterceptor.java	16 Dec 2006 10:17:14 -0000	1.25
  @@ -1,4 +1,4 @@
  -//$Id: ValidationInterceptor.java,v 1.24 2006/12/16 02:58:11 nrichards Exp $
  +//$Id: ValidationInterceptor.java,v 1.25 2006/12/16 10:17:14 gavin Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -23,6 +23,7 @@
    * information about the failure in the request context and
    * return a different outcome, without invoking the method.
    * 
  + * @deprecated
    * @author Gavin King
    */
   @Interceptor(stateless=true,
  
  
  


From gavin.king at jboss.com  Sat Dec 16 05:17:14 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 05:17:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util  ...
Message-ID: <E1GvWbS-0004OJ-SW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 05:17:14

  Modified:    src/main/org/jboss/seam/util  Work.java
  Log:
  javadoc
  
  Revision  Changes    Path
  1.4       +5 -0      jboss-seam/src/main/org/jboss/seam/util/Work.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Work.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Work.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- Work.java	16 Dec 2006 10:03:45 -0000	1.3
  +++ Work.java	16 Dec 2006 10:17:14 -0000	1.4
  @@ -5,6 +5,11 @@
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   
  +/**
  + * Performs work in a JTA transaction.
  + * 
  + * @author Gavin King
  + */
   public abstract class Work<T>
   {
      private static final LogProvider log = Logging.getLogProvider(Work.class);
  
  
  


From gavin.king at jboss.com  Sat Dec 16 06:37:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 06:37:52 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/resources  ...
Message-ID: <E1GvXrU-0005u3-7D@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 06:37:52

  Modified:    seam-gen/resources  messages_en.properties
  Log:
  list screen ordering
  
  Revision  Changes    Path
  1.5       +5 -0      jboss-seam/seam-gen/resources/messages_en.properties
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: messages_en.properties
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/resources/messages_en.properties,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- messages_en.properties	15 Dec 2006 17:59:01 -0000	1.4
  +++ messages_en.properties	16 Dec 2006 11:37:52 -0000	1.5
  @@ -1,3 +1,8 @@
  +up=\u2191
  +down=\u2193
  +left=\u2039
  +right=\u203A
  +
   validator.assertFalse=validation failed
   validator.assertTrue=validation failed
   validator.future=must be a future date
  
  
  


From gavin.king at jboss.com  Sat Dec 16 06:37:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 06:37:52 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view   ...
Message-ID: <E1GvXrU-0005uD-CA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 06:37:52

  Modified:    seam-gen/view   list.page.xml.ftl list.xhtml.ftl
  Log:
  list screen ordering
  
  Revision  Changes    Path
  1.2       +1 -0      jboss-seam/seam-gen/view/list.page.xml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.page.xml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.page.xml.ftl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- list.page.xml.ftl	10 Dec 2006 16:53:28 -0000	1.1
  +++ list.page.xml.ftl	16 Dec 2006 11:37:52 -0000	1.2
  @@ -7,4 +7,5 @@
   <#assign listName = componentName + "List">
   <page>
      <param name="firstResult" value="${'#'}{${listName}.firstResult}"/>
  +   <param name="order" value="${'#'}{${listName}.order}"/>
   </page>
  \ No newline at end of file
  
  
  
  1.8       +15 -6     jboss-seam/seam-gen/view/list.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.xhtml.ftl,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- list.xhtml.ftl	10 Dec 2006 15:42:02 -0000	1.7
  +++ list.xhtml.ftl	16 Dec 2006 11:37:52 -0000	1.8
  @@ -31,14 +31,23 @@
   <#foreach property in pojo.allPropertiesIterator>
   <#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
           <h:column>
  -            <f:facet name="header">${property.name}</f:facet>
  +            <f:facet name="header">
  +                <s:link value="${property.name} ${'#'}{${listName}.order=='${property.name} asc' ? messages.down : ( ${listName}.order=='${property.name} desc' ? messages.up : '' )}" styleClass="columnHeader">
  +                    <f:param name="order" value="${'#'}{${listName}.order=='${property.name} asc' ? '${property.name} desc' : '${property.name} asc'}"/>
  +                </s:link>
  +            </f:facet>
               ${'#'}{${componentName}.${property.name}}
           </h:column>
   </#if>
   <#if c2h.isManyToOne(property)>
   <#assign parentPojo = c2j.getPOJOClass(cfg.getClassMapping(property.value.referencedEntityName))>
           <h:column>
  -            <f:facet name="header">${property.name} ${parentPojo.identifierProperty.name}</f:facet>
  +            <f:facet name="header">
  +<#assign propertyPath = property.name + '.' + parentPojo.identifierProperty.name>
  +                <s:link value="${property.name} ${parentPojo.identifierProperty.name} ${'#'}{${listName}.order=='${propertyPath} asc' ? messages.down : ( ${listName}.order=='${propertyPath} desc' ? messages.up : '' )}" styleClass="columnHeader">
  +                    <f:param name="order" value="${'#'}{${listName}.order=='${propertyPath} asc' ? '${propertyPath} desc' : '${propertyPath} asc'}"/>
  +                </s:link>
  +            </f:facet>
               ${'#'}{${componentName}.${property.name}.${parentPojo.identifierProperty.name}}
           </h:column>
   </#if>
  @@ -58,14 +67,14 @@
         
           <s:link view="/${listPageName}.xhtml" 
               rendered="${'#'}{${listName}.previousExists}" 
  -               value="&lt;&lt; First Page"
  +               value="${'#'}{messages.left}${'#'}{messages.left} First Page"
                     id="firstPage">
             <f:param name="firstResult" value="0"/>
           </s:link>
           
           <s:link view="/${listPageName}.xhtml" 
               rendered="${'#'}{${listName}.previousExists}" 
  -               value="&lt; Previous Page"
  +               value="${'#'}{messages.left} Previous Page"
                     id="previousPage">
               <f:param name="firstResult" 
                       value="${'#'}{${listName}.previousFirstResult}"/>
  @@ -73,7 +82,7 @@
           
           <s:link view="/${listPageName}.xhtml" 
               rendered="${'#'}{${listName}.nextExists}" 
  -               value="Next Page &gt;"
  +               value="Next Page ${'#'}{messages.right}"
                     id="nextPage">
               <f:param name="firstResult" 
                       value="${'#'}{${listName}.nextFirstResult}"/>
  @@ -81,7 +90,7 @@
           
           <s:link view="/${listPageName}.xhtml" 
               rendered="${'#'}{${listName}.nextExists}" 
  -               value="Last Page &gt;&gt;"
  +               value="Last Page ${'#'}{messages.right}${'#'}{messages.right}"
                     id="lastPage">
               <f:param name="firstResult" 
                       value="${'#'}{${listName}.lastFirstResult}"/>
  
  
  


From gavin.king at jboss.com  Sat Dec 16 06:37:52 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 06:37:52 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view/stylesheet  ...
Message-ID: <E1GvXrU-0005uK-KT@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 06:37:52

  Modified:    seam-gen/view/stylesheet  theme.css
  Log:
  list screen ordering
  
  Revision  Changes    Path
  1.7       +11 -0     jboss-seam/seam-gen/view/stylesheet/theme.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: theme.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/stylesheet/theme.css,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- theme.css	10 Dec 2006 15:42:03 -0000	1.6
  +++ theme.css	16 Dec 2006 11:37:52 -0000	1.7
  @@ -109,6 +109,17 @@
   	width: auto;
   }
   
  +.columnHeader:link, .columnHeader:visited, .columnHeader:active
  +{
  +	color: white;
  +	text-decoration: none;
  +}
  +
  +.columnHeader:hover
  +{
  +    color: #FF6600;
  +}
  +
   .message {
   	border: 1px solid #FFCC00;
   	padding: 5px;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec 16 06:43:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 16 Dec 2006 06:43:49 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1806 - in trunk:
	src/etc/server/default/deploy
	src/main/org/jboss/messaging/core/plugin tests
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/tools/jmx
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GvXxF-0005zZ-K5@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-16 06:43:39 -0500 (Sat, 16 Dec 2006)
New Revision: 1806

Modified:
   trunk/src/etc/server/default/deploy/connection-factories-service.xml
   trunk/src/etc/server/default/deploy/destinations-service.xml
   trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java
Log:
Fixed functional tests



Modified: trunk/src/etc/server/default/deploy/connection-factories-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/connection-factories-service.xml	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/src/etc/server/default/deploy/connection-factories-service.xml	2006-12-16 11:43:39 UTC (rev 1806)
@@ -13,7 +13,7 @@
       xmbean-dd="xmdesc/ConnectionFactory-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends optional-attribute-name="Connector">jboss.messaging:service=Connector,transport=socket</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
 
       <attribute name="JNDIBindings">
          <bindings>

Modified: trunk/src/etc/server/default/deploy/destinations-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/destinations-service.xml	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/src/etc/server/default/deploy/destinations-service.xml	2006-12-16 11:43:39 UTC (rev 1806)
@@ -16,7 +16,7 @@
       name="jboss.messaging.destination:service=Queue,name=DLQ"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
 
    <!--
@@ -27,7 +27,7 @@
       name="jboss.messaging.destination:service=Topic,name=testTopic"
       xmbean-dd="xmdesc/Topic-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=TopicPostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
       <attribute name="SecurityConfig">
          <security>
             <role name="guest" read="true" write="true"/>
@@ -41,7 +41,7 @@
       name="jboss.messaging.destination:service=Topic,name=securedTopic"
       xmbean-dd="xmdesc/Topic-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=TopicPostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
       <attribute name="SecurityConfig">
          <security>
             <role name="publisher" read="true" write="true" create="false"/>
@@ -53,7 +53,7 @@
       name="jboss.messaging.destination:service=Topic,name=testDurableTopic"
       xmbean-dd="xmdesc/Topic-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=TopicPostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
       <attribute name="SecurityConfig">
          <security>
             <role name="guest" read="true" write="true"/>
@@ -67,7 +67,7 @@
       name="jboss.messaging.destination:service=Queue,name=testQueue"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
       <attribute name="SecurityConfig">
          <security>
             <role name="guest" read="true" write="true"/>
@@ -81,35 +81,35 @@
       name="jboss.messaging.destination:service=Queue,name=A"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
 
    <mbean code="org.jboss.jms.server.destination.QueueService"
       name="jboss.messaging.destination:service=Queue,name=B"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
 
    <mbean code="org.jboss.jms.server.destination.QueueService"
       name="jboss.messaging.destination:service=Queue,name=C"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
 
    <mbean code="org.jboss.jms.server.destination.QueueService"
       name="jboss.messaging.destination:service=Queue,name=D"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
 
    <mbean code="org.jboss.jms.server.destination.QueueService"
       name="jboss.messaging.destination:service=Queue,name=ex"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
    
    <!--
@@ -120,7 +120,7 @@
       name="jboss.messaging.destination:service=Queue,name=testDistributedQueue"
       xmbean-dd="xmdesc/Queue-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=QueuePostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
       <attribute name="Clustered">true</attribute>
    </mbean>   
    
@@ -128,7 +128,7 @@
       name="jboss.messaging.destination:service=Topic,name=testDistributedTopic"
       xmbean-dd="xmdesc/Topic-xmbean.xml">
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
-      <depends>jboss.messaging:service=TopicPostOffice</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
       <attribute name="Clustered">true</attribute>
    </mbean>   
 

Modified: trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-16 11:43:39 UTC (rev 1806)
@@ -180,11 +180,15 @@
       {
          conn = ds.getConnection();
          
-         ps = conn.prepareStatement(getSQLStatement("SELECT_COUNTER"));
+         String selectCounterSQL = getSQLStatement("SELECT_COUNTER");
          
+         ps = conn.prepareStatement(selectCounterSQL);
+         
          ps.setString(1, counterName);
          
+         if (trace) { log.trace("selecting counter: " + selectCounterSQL); }
          rs = ps.executeQuery();
+         if (trace) { log.trace(JDBCUtil.statementToString(selectCounterSQL, counterName)); }         
          
          if (!rs.next())
          {
@@ -193,15 +197,17 @@
             
             ps.close();
             
-            ps = conn.prepareStatement(getSQLStatement("INSERT_COUNTER"));
+            String insertCounterSQL = getSQLStatement("INSERT_COUNTER");
             
+            ps = conn.prepareStatement(insertCounterSQL);
+            
             ps.setString(1, counterName);
             
             ps.setLong(2, size);
             
-            int rows = ps.executeUpdate();
-            
-            if (trace) {  log.trace(JDBCUtil.statementToString(getSQLStatement("INSERT_COUNTER"), counterName)
+            if (trace) { log.trace("inserting counter: " + insertCounterSQL); }
+            int rows = ps.executeUpdate();            
+            if (trace) {  log.trace(JDBCUtil.statementToString(insertCounterSQL, counterName)
                            + " inserted " + rows + " rows"); }  
             
             ps.close();            
@@ -210,24 +216,24 @@
             return 0;
          }
          
-         if (trace) { log.trace(JDBCUtil.statementToString(getSQLStatement("SELECT_COUNTER"), counterName)); }
-         
          long nextId = rs.getLong(1);
          
          rs.close();
          rs = null;
          
          ps.close();
+
+         String updateCounterSQL = getSQLStatement("UPDATE_COUNTER");
+
+         ps = conn.prepareStatement(updateCounterSQL);
          
-         ps = conn.prepareStatement(getSQLStatement("UPDATE_COUNTER"));
-         
          ps.setLong(1, nextId + size);
          
          ps.setString(2, counterName);
          
-         int rows = ps.executeUpdate();
-         
-         if (trace) { log.trace(JDBCUtil.statementToString(getSQLStatement("UPDATE_COUNTER"), new Long(nextId + size),
+         if (trace) { log.trace("updating counter: " + updateCounterSQL); }
+         int rows = ps.executeUpdate();         
+         if (trace) { log.trace(JDBCUtil.statementToString(updateCounterSQL, new Long(nextId + size),
                                counterName) + " updated " + rows + " rows"); }        
          
          return nextId;

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/tests/build.xml	2006-12-16 11:43:39 UTC (rev 1806)
@@ -398,6 +398,7 @@
             <fileset dir="${build.tests.classes}">
                <include name="**/messaging/core/**/*Test.class"/>
                <include name="**/messaging/jms/**/*Test.class"/>
+               <exclude name="**/messaging/core/ha/**/*Test.class"/>
                <exclude name="**/jms/stress/**"/>
                <exclude name="**/jms/crash/*Test.class"/>
                <exclude name="**/jms/MemLeakTest.class"/>

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-16 11:43:39 UTC (rev 1806)
@@ -94,7 +94,7 @@
       
       ClusteredPostOffice office2 = null;
       
-      //ClusteredPostOffice office3 = null;
+      ClusteredPostOffice office3 = null;
       
       try
       {         
@@ -104,7 +104,7 @@
          log.info("starting office 2");
          office2 = createClusteredPostOffice(2, "testgroup");
                   
-         //office3 = createClusteredPostOffice(3, "testgroup");
+         office3 = createClusteredPostOffice(3, "testgroup");
          
          Thread.sleep(2000);
          
@@ -114,8 +114,8 @@
          office2.stop();
          office2 = null;
          
-//         office3.stop();
-//         office3 = null;
+         office3.stop();
+         office3 = null;
       }
       finally
       {
@@ -129,15 +129,15 @@
             office2.stop();
          }
          
-//         if (office3 != null)
+         if (office3 != null)
+         {
+            office3.stop();
+         }
+         
+//         if (checkNoBindingData())
 //         {
-//            office3.stop();
+//            fail("data still in database");
 //         }
-         
-         if (checkNoBindingData())
-         {
-            fail("data still in database");
-         }
       }
          
    }

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/FailoverMapperTest.java	2006-12-16 11:43:39 UTC (rev 1806)
@@ -50,10 +50,11 @@
       DefaultFailoverMapper mapper = new DefaultFailoverMapper();
       Map map = mapper.generateMapping(set);
 
-      assertEquals(new Integer(15),map.get(new Integer(25)));
-      assertEquals(new Integer(50),map.get(new Integer(15)));
-      assertEquals(new Integer(25),map.get(new Integer(50)));
+      assertEquals(new Integer(25), map.get(new Integer(15)));
+      assertEquals(new Integer(50), map.get(new Integer(25)));
+      assertEquals(new Integer(15), map.get(new Integer(50)));
       
+      
    }
 
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-16 11:43:39 UTC (rev 1806)
@@ -558,7 +558,7 @@
       ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
 
       MBeanConfigurationElement postOfficeConfig =
-         (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
+         (MBeanConfigurationElement)pdd.query("service", "PostOffice").iterator().next();
 
       String props = postOfficeConfig.getAttributeValue("SqlProperties");
 
@@ -605,7 +605,7 @@
       ServiceDeploymentDescriptor pdd = new ServiceDeploymentDescriptor(persistenceConfigFileURL);
 
       MBeanConfigurationElement postOfficeConfig =
-         (MBeanConfigurationElement)pdd.query("service", "QueuePostOffice").iterator().next();
+         (MBeanConfigurationElement)pdd.query("service", "PostOffice").iterator().next();
 
       String props = postOfficeConfig.getAttributeValue("SqlProperties");
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-16 11:43:39 UTC (rev 1806)
@@ -298,16 +298,6 @@
       return server.getPersistenceManager();
    }
 
-   public PostOffice getQueuePostOffice() throws Exception
-   {
-      return server.getQueuePostOffice();
-   }
-
-   public PostOffice getTopicPostOffice() throws Exception
-   {
-      return server.getTopicPostOffice();
-   }
-
    public ServerPeer getServerPeer() throws Exception
    {
       return server.getServerPeer();

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java	2006-12-16 06:08:50 UTC (rev 1805)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java	2006-12-16 11:43:39 UTC (rev 1806)
@@ -76,21 +76,6 @@
       throw new UnsupportedOperationException("This method shouldn't be invoked on a remote server");      
    }
    
-   /**
-    * Only for in-VM use!
-    */
-   public PostOffice getQueuePostOffice() throws Exception
-   {
-      throw new UnsupportedOperationException("This method shouldn't be invoked on a remote server");      
-   }
-   
-   /**
-    * Only for in-VM use!
-    */
-   public PostOffice getTopicPostOffice() throws Exception
-   {
-      throw new UnsupportedOperationException("This method shouldn't be invoked on a remote server");      
-   }
 
    // Public --------------------------------------------------------
     



From ptsekov at jboss.org  Sat Dec 16 07:41:38 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 07:41:38 -0500
Subject: [jboss-cvs] JBossCache/tests/compat - New directory ...
Message-ID: <E1GvYrC-00075d-Qm@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 07:41:38

  Log:
  Directory /cvsroot/jboss/JBossCache/tests/compat added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From ptsekov at jboss.org  Sat Dec 16 07:41:44 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 07:41:44 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org - New directory ...
Message-ID: <E1GvYrI-000764-DR@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 07:41:44

  Log:
  Directory /cvsroot/jboss/JBossCache/tests/compat/org added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From ptsekov at jboss.org  Sat Dec 16 07:41:50 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 07:41:50 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss - New directory ...
Message-ID: <E1GvYrO-00076V-8v@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 07:41:50

  Log:
  Directory /cvsroot/jboss/JBossCache/tests/compat/org/jboss added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From ptsekov at jboss.org  Sat Dec 16 07:41:55 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 07:41:55 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/cache - New directory
	...
Message-ID: <E1GvYrT-00076q-KO@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 07:41:55

  Log:
  Directory /cvsroot/jboss/JBossCache/tests/compat/org/jboss/cache added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From ptsekov at jboss.org  Sat Dec 16 07:41:55 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 07:41:55 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/tools - New directory
	...
Message-ID: <E1GvYrT-00076u-Np@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 07:41:55

  Log:
  Directory /cvsroot/jboss/JBossCache/tests/compat/org/jboss/tools added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From ptsekov at jboss.org  Sat Dec 16 07:42:01 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 07:42:01 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/cache/compat - New
	directory ...
Message-ID: <E1GvYrZ-00077B-1R@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 07:42:01

  Log:
  Directory /cvsroot/jboss/JBossCache/tests/compat/org/jboss/cache/compat added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From jboss-cvs-commits at lists.jboss.org  Sat Dec 16 08:03:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 16 Dec 2006 08:03:11 -0500
Subject: [jboss-cvs] JBossAS SVN: r59066 -
	projects/microcontainer/trunk/spring-int/src/resources/schema
Message-ID: <E1GvZC3-0007bo-13@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-16 08:03:07 -0500 (Sat, 16 Dec 2006)
New Revision: 59066

Removed:
   projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd
Log:
unnecessary

Deleted: projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd	2006-12-15 21:14:51 UTC (rev 59065)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/xml.xsd	2006-12-16 13:03:07 UTC (rev 59066)
@@ -1,152 +0,0 @@
-<?xml version='1.0'?>
-<xs:schema targetNamespace="http://www.w3.org/XML/1998/namespace" xmlns:xs="http://www.w3.org/2001/XMLSchema" xml:lang="en">
-
- <xs:annotation>
-  <xs:documentation>
-   See http://www.w3.org/XML/1998/namespace.html and
-   http://www.w3.org/TR/REC-xml for information about this namespace.
-
-    This schema document describes the XML namespace, in a form
-    suitable for import by other schema documents.  
-
-    Note that local names in this namespace are intended to be defined
-    only by the World Wide Web Consortium or its subgroups.  The
-    following names are currently defined in this namespace and should
-    not be used with conflicting semantics by any Working Group,
-    specification, or document instance:
-
-    base (as an attribute name): denotes an attribute whose value
-         provides a URI to be used as the base for interpreting any
-         relative URIs in the scope of the element on which it
-         appears; its value is inherited.  This name is reserved
-         by virtue of its definition in the XML Base specification.
-
-    id   (as an attribute name): denotes an attribute whose value
-         should be interpreted as if declared to be of type ID.
-         The xml:id specification is not yet a W3C Recommendation,
-         but this attribute is included here to facilitate experimentation
-         with the mechanisms it proposes.  Note that it is _not_ included
-         in the specialAttrs attribute group.
-
-    lang (as an attribute name): denotes an attribute whose value
-         is a language code for the natural language of the content of
-         any element; its value is inherited.  This name is reserved
-         by virtue of its definition in the XML specification.
-  
-    space (as an attribute name): denotes an attribute whose
-         value is a keyword indicating what whitespace processing
-         discipline is intended for the content of the element; its
-         value is inherited.  This name is reserved by virtue of its
-         definition in the XML specification.
-
-    Father (in any context at all): denotes Jon Bosak, the chair of 
-         the original XML Working Group.  This name is reserved by 
-         the following decision of the W3C XML Plenary and 
-         XML Coordination groups:
-
-             In appreciation for his vision, leadership and dedication
-             the W3C XML Plenary on this 10th day of February, 2000
-             reserves for Jon Bosak in perpetuity the XML name
-             xml:Father
-  </xs:documentation>
- </xs:annotation>
-
- <xs:annotation>
-  <xs:documentation>This schema defines attributes and an attribute group
-        suitable for use by
-        schemas wishing to allow xml:base, xml:lang, xml:space or xml:id
-        attributes on elements they define.
-
-        To enable this, such a schema must import this schema
-        for the XML namespace, e.g. as follows:
-        &lt;schema . . .>
-         . . .
-         &lt;import namespace="http://www.w3.org/XML/1998/namespace"
-                    schemaLocation="http://www.w3.org/2001/xml.xsd"/>
-
-        Subsequently, qualified reference to any of the attributes
-        or the group defined below will have the desired effect, e.g.
-
-        &lt;type . . .>
-         . . .
-         &lt;attributeGroup ref="xml:specialAttrs"/>
- 
-         will define a type which will schema-validate an instance
-         element with any of those attributes</xs:documentation>
-
- </xs:annotation>
-
- <xs:annotation>
-  <xs:documentation>In keeping with the XML Schema WG's standard versioning
-   policy, this schema document will persist at
-   http://www.w3.org/2005/08/xml.xsd.
-   At the date of issue it can also be found at
-   http://www.w3.org/2001/xml.xsd.
-   The schema document at that URI may however change in the future,
-   in order to remain compatible with the latest version of XML Schema
-   itself, or with the XML namespace itself.  In other words, if the XML
-   Schema or XML namespaces change, the version of this document at
-   http://www.w3.org/2001/xml.xsd will change
-   accordingly; the version at
-   http://www.w3.org/2005/08/xml.xsd will not change.
-  </xs:documentation>
- </xs:annotation>
-
- <xs:attribute name="lang">
-  <xs:annotation>
-   <xs:documentation>Attempting to install the relevant ISO 2- and 3-letter
-         codes as the enumerated possible values is probably never
-         going to be a realistic possibility.  See
-         RFC 3066 at http://www.ietf.org/rfc/rfc3066.txt and the IANA registry
-         at http://www.iana.org/assignments/lang-tag-apps.htm for
-         further information.
-
-         The union allows for the 'un-declaration' of xml:lang with
-         the empty string.</xs:documentation>
-
-  </xs:annotation>
-  <xs:simpleType>
-   <xs:union memberTypes="xs:language">
-    <xs:simpleType>    
-     <xs:restriction base="xs:string">
-      <xs:enumeration value=""/>
-     </xs:restriction>
-    </xs:simpleType>
-   </xs:union>
-
-  </xs:simpleType>
- </xs:attribute>
-
- <xs:attribute name="space">
-  <xs:simpleType>
-   <xs:restriction base="xs:NCName">
-    <xs:enumeration value="default"/>
-    <xs:enumeration value="preserve"/>
-   </xs:restriction>
-
-  </xs:simpleType>
- </xs:attribute>
-
- <xs:attribute name="base" type="xs:anyURI">
-  <xs:annotation>
-   <xs:documentation>See http://www.w3.org/TR/xmlbase/ for
-                     information about this attribute.</xs:documentation>
-  </xs:annotation>
- </xs:attribute>
- 
- <xs:attribute name="id" type="xs:ID">
-
-  <xs:annotation>
-   <xs:documentation>See http://www.w3.org/TR/xml-id/ for
-                     information about this attribute.</xs:documentation>
-  </xs:annotation>
- </xs:attribute>
-
- <xs:attributeGroup name="specialAttrs">
-  <xs:attribute ref="xml:base"/>
-  <xs:attribute ref="xml:lang"/>
-  <xs:attribute ref="xml:space"/>
-
- </xs:attributeGroup>
-
-</xs:schema>



From ptsekov at jboss.org  Sat Dec 16 08:13:03 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 08:13:03 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GvZLb-0007mY-Kh@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 08:13:03

  Modified:    JBossCache  Tag: Branch_JBossCache_1_4_0 build.xml
  Log:
  Add support for testing whether serialized objects remain compatible with older versions of JBossCache (JBQA-536).
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.119.2.18 +36 -1     JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.119.2.17
  retrieving revision 1.119.2.18
  diff -u -b -r1.119.2.17 -r1.119.2.18
  --- build.xml	13 Dec 2006 16:05:43 -0000	1.119.2.17
  +++ build.xml	16 Dec 2006 13:13:03 -0000	1.119.2.18
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.119.2.17 2006/12/13 16:05:43 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.119.2.18 2006/12/16 13:13:03 ptsekov Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -21,6 +21,7 @@
      <property name="perf.tests.dir" value="${tests.dir}/perf"/>
      <property name="jrunit.tests.dir" value="${tests.dir}/perf"/>
      <property name="interop.tests.dir" value="${tests.dir}/interop"/>
  +   <property name="compat.tests.dir" value="${tests.dir}/compat"/>
      <property name="etc.dir" value="${root.dir}/etc"/>
      <property name="dependencies" value="dependencies.xml"/>
      <property name="resources.dir" value="${root.dir}/src/resources"/>
  @@ -44,12 +45,20 @@
      <property name="junit.timeout" value="300000"/>
      <property name="junit.timeout.stresstest" value="6000000"/>
      <property name="junit.timeout.performance" value="60000"/>
  +   <property name="junit.timeout.compat" value="300000"/>
      <property name="junit.batchtest.todir" value="${build.reports}"/>
      <property name="junit.jvm.options" value="-Ddummy"/>
      <property name="ant.dir" value="${root.dir}/ant-dist"/>
      <property name="manifest.file" value="${dist.lib}/default.mf"/>
      <!-- Test if JDK5 is available -->
      <available classname="java.lang.Enum" property="HAVE_JDK_1.5"/>
  +   <!-- -->
  +   <condition property="ENABLE_COMPAT_TESTS">
  +      <or>
  +         <equals arg1="${ant.java.version}" arg2="1.5"/>
  +         <equals arg1="${ant.java.version}" arg2="1.4"/>
  +      </or>
  +   </condition>
      <property name="src.dir.50" value="${root.dir}/src-50"/>
      <property name="tests.dir.50" value="${root.dir}/tests-50"/>
      <property name="compile.dir.50" value="${output.dir}/classes-50"/>
  @@ -188,6 +197,7 @@
            <src path="${stress.tests.dir}"/>
            <src path="${perf.tests.dir}"/>
            <src path="${jrunit.tests.dir}"/>
  +         <src path="${compat.tests.dir}"/>
            <classpath path="${compile.dir}"/>
            <classpath refid="library.classpath"/>
            <exclude name="**/obsolete/**"/>
  @@ -862,6 +872,31 @@
         </sequential>
      </macrodef>
   
  +   <target name="compat-tests" depends="jar, unittests-init"
  +           if="ENABLE_COMPAT_TESTS">
  +      <condition property="libdir.list" value="lib-50,lib, dist/lib-50">
  +         <equals arg1="${ant.java.version}" arg2="1.5"/>
  +      </condition>
  +      <condition property="libdir.list" value="lib, dist/lib">
  +         <equals arg1="${ant.java.version}" arg2="1.4"/>
  +      </condition>
  +
  +      <junit printsummary="yes" timeout="${junit.timeout.compat}" fork="yes"
  +             maxmemory="256m">
  +         <classpath>
  +            <pathelement path="${compiletest.dir}"/>
  +         </classpath>
  +         <sysproperty key="libdir.list" value="${libdir.list}"/>
  +         <formatter type="xml" usefile="true"/>
  +         <batchtest todir="${build.reports}">
  +            <fileset dir="${compat.tests.dir}">
  +               <exclude name="**/tools/**/*"/>
  +               <patternset refid="junit.excludes"/>
  +            </fileset>
  +         </batchtest>
  +      </junit>
  +   </target>
  +
      <target name="unittests"
              depends="functionaltests, perftests, stresstests"
              description="Run all non-AOP unit tests (functional, perf, stress)"/>
  
  
  


From ptsekov at jboss.org  Sat Dec 16 08:13:03 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 08:13:03 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/cache/compat  ...
Message-ID: <E1GvZLb-0007mj-OT@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 08:13:03

  Added:       tests/compat/org/jboss/cache/compat  Tag:
                        Branch_JBossCache_1_4_0
                        SerialVersionUIDUnitTestCase.java
  Log:
  Add support for testing whether serialized objects remain compatible with older versions of JBossCache (JBQA-536).
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +120 -0    JBossCache/tests/compat/org/jboss/cache/compat/Attic/SerialVersionUIDUnitTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUIDUnitTestCase.java
  ===================================================================
  RCS file: SerialVersionUIDUnitTestCase.java
  diff -N SerialVersionUIDUnitTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SerialVersionUIDUnitTestCase.java	16 Dec 2006 13:13:03 -0000	1.1.2.1
  @@ -0,0 +1,120 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.cache.compat;
  +
  +import java.io.File;
  +import java.io.FileInputStream;
  +import java.io.FileWriter;
  +import java.io.IOException;
  +import java.io.ObjectInputStream;
  +import java.util.Iterator;
  +import java.util.Map;
  +
  +import junit.framework.Test;
  +import junit.framework.TestCase;
  +import junit.framework.TestSuite;
  +
  +import org.jboss.tools.ClassVersionInfo;
  +import org.jboss.tools.SerialVersionUID;
  +
  +/** 
  + * Tests of serial version uid compatibility across jboss versions. The
  + * testsuite/etc/serialVersionUID/xxx.ser is created using the
  + * org.jboss.tools.SerialVersionUID utility.
  + *
  + * @author Scott.Stark at jboss.org
  + */
  +public class SerialVersionUIDUnitTestCase extends TestCase
  +{
  +   public SerialVersionUIDUnitTestCase(String name)
  +   {
  +      super(name);
  +   }
  +
  +   /**
  +    Compare two sets of classes for serialVersionUID compatibility.
  +
  +    @param classInfoMap - the legacy version classes
  +    @param currentClassInfoMap - the current build classes
  +    @param versionName - the legacy version name
  +    @param badPackages - a list of package prefixes to ignore for errors
  +    @return the number of serial version mismatches
  +    */
  +   private int compare(Map classInfoMap, Map currentClassInfoMap,
  +      String versionName, String[] badPackages, StringBuffer bufferMessages)
  +      throws IOException
  +   {
  +      File out = new File(versionName+".errors");
  +      System.out.println("Writing errors to: "+out.getAbsolutePath());
  +      FileWriter errors = new FileWriter(out);
  +      int mismatchCount = 0;
  +      Iterator iter = currentClassInfoMap.values().iterator();
  +      while( iter.hasNext() )
  +      {
  +         ClassVersionInfo cvi = (ClassVersionInfo) iter.next();
  +         String name = cvi.getName();
  +         ClassVersionInfo cviLegacy = (ClassVersionInfo) classInfoMap.get(name);
  +         if( cviLegacy != null && cvi.getSerialVersion() != cviLegacy.getSerialVersion() )
  +         {
  +            String msg = "serialVersionUID error for "+name
  +               +", " + versionName + ": " + cviLegacy.getSerialVersion()
  +               +", current: "+cvi.getSerialVersion();
  +
  +            // Don't count classes from badPackages
  +            boolean isInBadPkg = false;
  +            for(int n = 0; n < badPackages.length; n ++)
  +            {
  +               String pkg = badPackages[n];
  +               if( name.startsWith(pkg) )
  +               {
  +                  isInBadPkg = true;
  +                  break;
  +               }
  +            }
  +
  +            if (isInBadPkg)
  +               continue;
  +
  +            if (mismatchCount>0)
  +            {
  +               bufferMessages.append(",\n");
  +            }
  +            bufferMessages.append(name);
  +            mismatchCount ++;
  +            System.err.println(msg);
  +            errors.write(msg);
  +            errors.write('\n');
  +         }
  +      }
  +      errors.close();
  +      // If the mismatchCount is 0 remove the error file
  +      if( mismatchCount == 0 )
  +         out.delete();
  +
  +      return mismatchCount;
  +   }
  +
  +   static Map calcClassInfoMap()
  +      throws IOException
  +   {
  +      SerialVersionUID.processProperties();
  +      Map classInfoMap = SerialVersionUID.processJars();
  +      return classInfoMap;
  +   }
  +   
  +   public static Test suite() throws Exception
  +   {
  +      TestSuite suite = new TestSuite();
  +
  +      return suite;
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      junit.textui.TestRunner.run(SerialVersionUIDUnitTestCase.class);
  +   }
  +}
  
  
  


From ptsekov at jboss.org  Sat Dec 16 08:13:03 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 16 Dec 2006 08:13:03 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/tools   ...
Message-ID: <E1GvZLb-0007mx-Tz@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/16 08:13:03

  Added:       tests/compat/org/jboss/tools   Tag: Branch_JBossCache_1_4_0
                        ClassVersionInfo.java SerialVersionUID.java
  Log:
  Add support for testing whether serialized objects remain compatible with older versions of JBossCache (JBQA-536).
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +118 -0    JBossCache/tests/compat/org/jboss/tools/Attic/ClassVersionInfo.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClassVersionInfo.java
  ===================================================================
  RCS file: ClassVersionInfo.java
  diff -N ClassVersionInfo.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ ClassVersionInfo.java	16 Dec 2006 13:13:03 -0000	1.1.2.1
  @@ -0,0 +1,118 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.tools;
  +
  +import java.io.ObjectStreamClass;
  +import java.io.Serializable;
  +import java.io.FileInputStream;
  +import java.io.ObjectInputStream;
  +import java.util.Map;
  +
  +/**
  + * Encapsulates a class serialVersionUID and codebase.
  + * 
  + * @author Scott.Stark at jboss.org
  + * @version $Revision: 1.1.2.1 $
  + */
  +public class ClassVersionInfo implements Serializable
  +{
  +   static final long serialVersionUID = 2036506209171911437L;
  +
  +   /** The named class serialVersionUID as returned by ObjectStreamClass */
  +   private long serialVersion;
  +   /** The binary class name */
  +   private String name;
  +   private boolean hasExplicitSerialVersionUID;
  +
  +   public ClassVersionInfo(String name, ClassLoader loader)
  +      throws ClassNotFoundException
  +   {
  +      this.name = name;
  +      Class c = loader.loadClass(name);
  +      if( c.isInterface() == false )
  +      {
  +         ObjectStreamClass osc = ObjectStreamClass.lookup(c);
  +         if( osc != null )
  +         {
  +            serialVersion = osc.getSerialVersionUID();
  +            try
  +            {
  +               c.getDeclaredField("serialVersionUID");
  +               hasExplicitSerialVersionUID = true;
  +            }
  +            catch(NoSuchFieldException e)
  +            {
  +               hasExplicitSerialVersionUID = false;
  +            }
  +         }
  +      }
  +   }
  +
  +   public long getSerialVersion()
  +   {
  +      return serialVersion;
  +   }
  +   public boolean getHasExplicitSerialVersionUID()
  +   {
  +      return hasExplicitSerialVersionUID;
  +   }
  +   public String getName()
  +   {
  +      return name;
  +   }
  +
  +   public String toString()
  +   {
  +      StringBuffer tmp = new StringBuffer("ClassVersionInfo");
  +      tmp.append('{');
  +      tmp.append("serialVersion=");
  +      tmp.append(serialVersion);
  +      tmp.append(", hasExplicitSerialVersionUID=");
  +      tmp.append(hasExplicitSerialVersionUID);
  +      tmp.append(", name=");
  +      tmp.append(name);
  +      tmp.append('}');
  +      return tmp.toString();
  +   }
  +
  +   /**
  +    * Utility main entry point that allows one to load a Map<String,ClassVersionInfo>
  +    * from a serialized object file to print a specific ClassVersionInfo
  +    * 
  +    * @param args [0] = map.ser file for serialized object image
  +    *    [1] = class name of the ClassVersionInfo to print 
  +    * @throws Exception
  +    */
  +   public static void main(String[] args)
  +      throws Exception
  +   {
  +      if( args.length != 2 )
  +      {
  +         throw new IllegalArgumentException("Usage ClassVersionInfo map.ser [-list|cvi_fqn]");
  +      }
  +      FileInputStream fis = new FileInputStream(args[0]);
  +      ObjectInputStream ois = new ObjectInputStream(fis);
  +      Map cvis = (Map) ois.readObject();
  +      ois.close();
  +
  +      if( args[1].equals("-list") )
  +      {
  +         System.out.println(cvis.keySet());
  +         System.exit(0);
  +      }
  +
  +      String fqn = args[1];
  +      if( cvis.containsKey(fqn) == false )
  +      {
  +         System.err.println("No entry found for: "+fqn);
  +         System.exit(1);
  +      }
  +      ClassVersionInfo cvi = (ClassVersionInfo) cvis.get(fqn);
  +      System.out.println(cvi);
  +      System.exit(0);
  +   }
  +}
  
  
  
  1.1.2.1   +205 -0    JBossCache/tests/compat/org/jboss/tools/Attic/SerialVersionUID.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUID.java
  ===================================================================
  RCS file: SerialVersionUID.java
  diff -N SerialVersionUID.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SerialVersionUID.java	16 Dec 2006 13:13:03 -0000	1.1.2.1
  @@ -0,0 +1,205 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.tools;
  +
  +import java.io.File;
  +import java.io.FileInputStream;
  +import java.io.FileOutputStream;
  +import java.io.ObjectOutputStream;
  +import java.io.IOException;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.Enumeration;
  +import java.util.TreeMap;
  +import java.util.Map;
  +import java.util.Properties;
  +import java.util.Set;
  +import java.util.LinkedHashSet;
  +import java.util.logging.Logger;
  +import java.util.logging.Level;
  +import java.util.jar.JarFile;
  +import java.util.jar.JarEntry;
  +import java.net.URLClassLoader;
  +import java.net.MalformedURLException;
  +import java.net.URL;
  +
  +/** A tool that builds a databaase of serialVersionUIDs for a given set
  + *  of classes.
  + * 
  + * @author Scott.Stark at jboss.org
  + */
  +public class SerialVersionUID
  +{
  +   static Logger log = Logger.getLogger("SerialVersionUID");
  +
  +   static LinkedHashSet libdirList = new LinkedHashSet();
  +
  +   static void parsePropertyList(String listValue, Set dst)
  +   {
  +      String elements[] = listValue.split(",");
  +
  +      for (int i = 0; i < elements.length; i++)
  +      {
  +         dst.add(elements[i].trim());
  +      }
  +   }
  +
  +   public static void processProperties()
  +   {
  +      Properties fallbackProps = new Properties();
  +      // A list of directories to scan for .jar files.
  +      fallbackProps.setProperty("libdir.list", "lib");
  +
  +      Properties props = new Properties(fallbackProps);
  +      String propName, propValue;
  +      for (Enumeration e = fallbackProps.propertyNames(); e.hasMoreElements();)
  +      {
  +         propName = (String) e.nextElement();
  +         propValue = System.getProperty(propName);
  +         props.setProperty(propName, propValue);
  +      }
  +
  +      String tmpStr;
  +      tmpStr = props.getProperty("libdir.list");
  +      if (tmpStr.length() == 0)
  +      {
  +         tmpStr = fallbackProps.getProperty("libdir.list");
  +      }
  +      parsePropertyList(tmpStr, libdirList);
  +   }
  +
  +   static void buildJarSet(File dir, LinkedHashSet jarFiles)
  +      throws MalformedURLException
  +   {
  +      File[] files = dir.listFiles();
  +      for(int n = 0; n < files.length; n ++)
  +      {
  +         File child = files[n];
  +         if(child.isDirectory())
  +            buildJarSet(child, jarFiles);
  +         else if( child.getName().endsWith(".jar") )
  +            jarFiles.add(child.toURL());
  +      }
  +   }
  +
  +   /**
  +    * Build a TreeMap of the class name to ClassVersionInfo
  +    * @param jar
  +    * @param classVersionMap TreeMap<String, ClassVersionInfo> for serializable
  +    *    classes
  +    * @param cl - the class loader to use
  +    * @throws IOException thrown if the jar cannot be opened
  +    */ 
  +   static void generateJarSerialVersionUIDs(URL jar, TreeMap classVersionMap,
  +      ClassLoader cl, String pkgPrefix) throws IOException
  +   {
  +      String jarName = jar.getFile();
  +      JarFile jf = new JarFile(jarName);
  +      Enumeration entries = jf.entries();
  +      while( entries.hasMoreElements() )
  +      {
  +         JarEntry entry = (JarEntry) entries.nextElement();
  +         String name = entry.getName();
  +         if( name.endsWith(".class") && name.startsWith(pkgPrefix) )
  +         {
  +            name = name.substring(0, name.length() - 6);
  +            String classname = name.replace('/', '.');
  +            try
  +            {
  +               log.fine("Creating ClassVersionInfo for: "+classname);
  +               ClassVersionInfo cvi = new ClassVersionInfo(classname, cl);
  +               if( cvi.getSerialVersion() != 0 )
  +               {
  +                  ClassVersionInfo prevCVI = (ClassVersionInfo)
  +                     classVersionMap.put(classname, cvi);
  +                  if( prevCVI != null )
  +                  {
  +                     if( prevCVI.getSerialVersion() != cvi.getSerialVersion() )
  +                     {
  +                        log.severe("Found inconsistent classes, "
  +                           +prevCVI+" != "+cvi+", jar: "+jarName);
  +                     }
  +                  }
  +                  if( cvi.getHasExplicitSerialVersionUID() == false )
  +                  {
  +                     log.warning("No explicit serialVersionUID: "+cvi);
  +                  }
  +               }
  +            }
  +            catch(OutOfMemoryError e)
  +            {
  +               log.log(Level.SEVERE, "Check the MaxPermSize", e);
  +            }
  +            catch(Throwable e)
  +            {
  +               log.log(Level.FINE, "While loading: "+name, e);
  +            }
  +         }
  +      }
  +      jf.close();
  +   }
  +
  +   /**
  +    * Create a Map<String, ClassVersionInfo> for the dist jars.
  +    * 
  +    * @return Map<String, ClassVersionInfo>
  +    * @throws IOException
  + .   */ 
  +   public static Map processJars() throws IOException
  +   {
  +      LinkedHashSet jarFiles = new LinkedHashSet();
  +
  +      File dir;
  +      Iterator libdirIterator = libdirList.iterator();
  +      while (libdirIterator.hasNext())
  +      {
  +         dir = new File((String) libdirIterator.next());
  +         buildJarSet(dir, jarFiles);
  +      }
  +
  +      URL[] cp = new URL[jarFiles.size()];
  +      jarFiles.toArray(cp);
  +      ClassLoader parent = Thread.currentThread().getContextClassLoader();
  +      URLClassLoader completeClasspath = new URLClassLoader(cp, parent);
  +
  +      TreeMap classVersionMap = new TreeMap();
  +      Iterator jarIter = jarFiles.iterator();
  +      while( jarIter.hasNext() )
  +      {
  +         URL jar = (URL) jarIter.next();
  +         try
  +         {
  +            generateJarSerialVersionUIDs(jar, classVersionMap, completeClasspath, "");
  +         }
  +         catch(IOException e)
  +         {
  +            log.info("Failed to process jar: "+jar);
  +         }
  +      }
  +
  +      return classVersionMap;
  +   }
  +
  +   /**
  +    * Generate a mapping of the serial version UIDs for the serializable classes
  +    * under the dist directory (as specified by the dist.dir property).
  +    * @throws Exception
  +    */ 
  +   public static void main(String[] args) throws Exception
  +   {
  +      processProperties();
  +
  +      Map classVersionMap = processJars();
  +      log.info(classVersionMap.size() + " serialVersionUIDs stored into the database");
  +
  +      // Write the map out the object file
  +      FileOutputStream fos = new FileOutputStream("serialuid.ser");
  +      ObjectOutputStream oos = new ObjectOutputStream(fos);
  +      oos.writeObject(classVersionMap);
  +      fos.close();
  +   }
  +}
  
  
  


From gavin.king at jboss.com  Sat Dec 16 08:26:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 08:26:10 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/src  ...
Message-ID: <E1GvZYI-0007zW-KL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 08:26:10

  Modified:    seam-gen/src  EntityList.java.ftl
  Log:
  JBSEAM-477, search screens
  
  Revision  Changes    Path
  1.4       +25 -0     jboss-seam/seam-gen/src/EntityList.java.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityList.java.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/src/EntityList.java.ftl,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- EntityList.java.ftl	10 Dec 2006 16:53:28 -0000	1.3
  +++ EntityList.java.ftl	16 Dec 2006 13:26:10 -0000	1.4
  @@ -5,11 +5,25 @@
   
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.framework.EntityQuery;
  +import java.util.List;
  +import java.util.Arrays;
   
   @Name("${listName}")
   public class ${entityName}List extends EntityQuery
   {
   
  +    private static final String[] RESTRICTIONS = {
  +<#foreach property in pojo.allPropertiesIterator>
  +<#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
  +<#if property.value.typeName == "string">
  +        "lower(${componentName}.${property.name}) like concat(lower(${'#'}{${listName}.${componentName}.${property.name}}),'%')",
  +</#if>
  +</#if>
  +</#foreach>
  +    };
  +
  +    private ${entityName} ${componentName} = new ${entityName}();
  +
       @Override
       public String getEjbql() 
       { 
  @@ -22,4 +36,15 @@
       	return 25;
       }
       
  +    public ${entityName} get${entityName}()
  +    {
  +        return ${componentName};
  +    }
  +    
  +    @Override
  +    public List<String> getRestrictions()
  +    {
  +        return Arrays.asList(RESTRICTIONS);
  +    }
  +
   }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 08:26:10 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 08:26:10 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view     ...
Message-ID: <E1GvZYI-0007zm-OR@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 08:26:10

  Modified:    seam-gen/view     edit.xhtml.ftl list.page.xml.ftl
                        list.xhtml.ftl view.xhtml.ftl
  Log:
  JBSEAM-477, search screens
  
  Revision  Changes    Path
  1.21      +2 -2      jboss-seam/seam-gen/view/edit.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.xhtml.ftl,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- edit.xhtml.ftl	10 Dec 2006 16:53:28 -0000	1.20
  +++ edit.xhtml.ftl	16 Dec 2006 13:26:10 -0000	1.21
  @@ -189,7 +189,7 @@
   
       <div class="association" id="${property.name}">
       
  -        <h2>${property.name}</h2>
  +        <h3>${property.name}</h3>
       
           <h:outputText value="No ${property.name}" 
                      rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
  @@ -234,7 +234,7 @@
       
           <div class="association" id="${property.name}">
           
  -            <h2>${property.name}</h2>
  +            <h3>${property.name}</h3>
           
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
   <#assign childPageName = childPojo.shortName>
  
  
  
  1.3       +7 -0      jboss-seam/seam-gen/view/list.page.xml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.page.xml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.page.xml.ftl,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- list.page.xml.ftl	16 Dec 2006 11:37:52 -0000	1.2
  +++ list.page.xml.ftl	16 Dec 2006 13:26:10 -0000	1.3
  @@ -8,4 +8,11 @@
   <page>
      <param name="firstResult" value="${'#'}{${listName}.firstResult}"/>
      <param name="order" value="${'#'}{${listName}.order}"/>
  +<#foreach property in pojo.allPropertiesIterator>
  +<#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
  +<#if property.value.typeName == "string">
  +   <param name="${property.name}" value="${'#'}{${listName}.${componentName}.${property.name}}"/>
  +</#if>
  +</#if>
  +</#foreach>
   </page>
  \ No newline at end of file
  
  
  
  1.9       +39 -4     jboss-seam/seam-gen/view/list.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.xhtml.ftl,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- list.xhtml.ftl	16 Dec 2006 11:37:52 -0000	1.8
  +++ list.xhtml.ftl	16 Dec 2006 13:26:10 -0000	1.9
  @@ -12,15 +12,46 @@
                   xmlns:ui="http://java.sun.com/jsf/facelets"
                   xmlns:f="http://java.sun.com/jsf/core"
                   xmlns:h="http://java.sun.com/jsf/html"
  +                xmlns:fn="http://java.sun.com/jsp/jstl/functions"
                   template="layout/template.xhtml">
                          
   <ui:define name="body">
   
  -    <h1>${entityName} list</h1>
  -    <p>Generated list page</p>
  +    <h1>${entityName} search</h1>
  +    <p>Generated search page</p>
       
       <h:messages globalOnly="true" styleClass="message" id="globalMessages"/>
       
  +    <h:form id="${componentName}" styleClass="edit">
  +    
  +        <div class="dialog">
  +            <table>
  +<#foreach property in pojo.allPropertiesIterator>
  +<#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
  +<#if property.value.typeName == "string">
  +                <tr class="prop">
  +                    <td class="name">${property.name}</td>
  +                    <td class="value">
  +                        <h:inputText id="${property.name}" 
  +                                  value="${'#'}{${listName}.${componentName}.${property.name}}"/>
  +                    </td>
  +                </tr>
  +</#if>
  +</#if>
  +</#foreach>
  +            </table>
  +        </div>
  +        
  +        <div class="actionButtons">
  +            <h:commandButton id="search" value="Search" action="/${listPageName}.xhtml"/>
  +        </div>
  +        
  +    </h:form>
  +    
  +    <div class="results" id="${componentName}List">
  +
  +    <h3>search results</h3>
  +
       <h:outputText value="No ${componentName} exists" 
                  rendered="${'#'}{empty ${listName}.resultList}"/>
                  
  @@ -32,7 +63,8 @@
   <#if !c2h.isCollection(property) && !c2h.isManyToOne(property)>
           <h:column>
               <f:facet name="header">
  -                <s:link value="${property.name} ${'#'}{${listName}.order=='${property.name} asc' ? messages.down : ( ${listName}.order=='${property.name} desc' ? messages.up : '' )}" styleClass="columnHeader">
  +                <s:link styleClass="columnHeader"
  +                             value="${property.name} ${'#'}{${listName}.order=='${property.name} asc' ? messages.down : ( ${listName}.order=='${property.name} desc' ? messages.up : '' )}">
                       <f:param name="order" value="${'#'}{${listName}.order=='${property.name} asc' ? '${property.name} desc' : '${property.name} asc'}"/>
                   </s:link>
               </f:facet>
  @@ -44,7 +76,8 @@
           <h:column>
               <f:facet name="header">
   <#assign propertyPath = property.name + '.' + parentPojo.identifierProperty.name>
  -                <s:link value="${property.name} ${parentPojo.identifierProperty.name} ${'#'}{${listName}.order=='${propertyPath} asc' ? messages.down : ( ${listName}.order=='${propertyPath} desc' ? messages.up : '' )}" styleClass="columnHeader">
  +                <s:link styleClass="columnHeader"
  +                             value="${property.name} ${parentPojo.identifierProperty.name} ${'#'}{${listName}.order=='${propertyPath} asc' ? messages.down : ( ${listName}.order=='${propertyPath} desc' ? messages.up : '' )}">
                       <f:param name="order" value="${'#'}{${listName}.order=='${propertyPath} asc' ? '${propertyPath} desc' : '${propertyPath} asc'}"/>
                   </s:link>
               </f:facet>
  @@ -63,6 +96,8 @@
           </h:column>
       </h:dataTable>
   
  +    </div>
  +
       <div class="tableControl">
         
           <s:link view="/${listPageName}.xhtml" 
  
  
  
  1.8       +2 -2      jboss-seam/seam-gen/view/view.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: view.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/view.xhtml.ftl,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- view.xhtml.ftl	10 Dec 2006 15:42:02 -0000	1.7
  +++ view.xhtml.ftl	16 Dec 2006 13:26:10 -0000	1.8
  @@ -81,7 +81,7 @@
   
       <div class="association" id="${property.name}">
       
  -        <h2>${property.name}</h2>
  +        <h3>${property.name}</h3>
           
           <h:outputText value="No ${property.name}" 
                      rendered="${'#'}{${homeName}.instance.${property.name} == null}"/>
  @@ -123,7 +123,7 @@
   
       <div class="association" id="${property.name}">
       
  -        <h2>${property.name}</h2>
  +        <h3>${property.name}</h3>
           
   <#assign childPojo = c2j.getPOJOClass(property.value.element.associatedClass)>
   <#assign childPageName = childPojo.shortName>
  
  
  


From gavin.king at jboss.com  Sat Dec 16 08:43:15 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 08:43:15 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1GvZop-0008FF-Pn@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 08:43:15

  Modified:    seam-gen  build.xml
  Log:
  JBSEAM-539
  
  Revision  Changes    Path
  1.54      +11 -2     jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.53
  retrieving revision 1.54
  diff -u -b -r1.53 -r1.54
  --- build.xml	15 Dec 2006 09:24:51 -0000	1.53
  +++ build.xml	16 Dec 2006 13:43:15 -0000	1.54
  @@ -165,7 +165,7 @@
       	<property name="database.type.default" value="hsql"/>
           <input addproperty="database.type.new" 
                      message="What kind of database are you using? [${database.type.default}] " 
  -        	     validargs="hsql,mysql,oracle,postgres,mssql,db2,sybase,"
  +        	     validargs="hsql,mysql,oracle,postgres,mssql,db2,sybase,enterprisedb,"
                 defaultvalue="${database.type.default}"/>
       	
       	<!-- if the database type did not change, default to the previous values -->
  @@ -203,6 +203,9 @@
           <condition property="hibernate.dialect.default" value="org.hibernate.dialect.SybaseDialect">
           	<equals arg1="${database.type.new}" arg2="sybase"/>
           </condition>
  +        <condition property="hibernate.dialect.default" value="org.hibernate.dialect.PostgreSQLDialect">
  +        	<equals arg1="${database.type.new}" arg2="enterprisedb"/>
  +        </condition>
       	
       	<condition property="hibernate.connection.driver_class.default" value="org.hsqldb.jdbcDriver">
       		<equals arg1="${database.type.new}" arg2="hsql"/>
  @@ -225,6 +228,9 @@
           <condition property="hibernate.connection.driver_class.default" value="com.sybase.jdbc2.jdbc.SybDriver">
           	<equals arg1="${database.type.new}" arg2="sybase"/>
           </condition>
  +        <condition property="hibernate.connection.driver_class.default" value="com.edb.Driver">
  +        	<equals arg1="${database.type.new}" arg2="enterprisedb"/>
  +        </condition>
   
       	<condition property="hibernate.connection.url.default" value="jdbc:hsqldb:.">
       		<equals arg1="${database.type.new}" arg2="hsql"/>
  @@ -247,6 +253,9 @@
           <condition property="hibernate.connection.url.default" value="jdbc:sybase:Tds:localhost:5000/test">
           	<equals arg1="${database.type.new}" arg2="sybase"/>
           </condition>
  +        <condition property="hibernate.connection.url.default" value="jdbc:edb://localhost:5444/edb">
  +        	<equals arg1="${database.type.new}" arg2="enterprisedb"/>
  +        </condition>
   		
       	<!-- finally, default them to HSQL -->
       	
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:06:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:06:57 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvaBl-0000LT-JT@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:06:57

  Modified:    src/main/org/jboss/seam  Component.java
  Log:
  better handling of empty string
  JBSEAM-570, @Observer(create=false)
  
  Revision  Changes    Path
  1.222     +4 -3      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.221
  retrieving revision 1.222
  diff -u -b -r1.221 -r1.222
  --- Component.java	16 Dec 2006 02:58:10 -0000	1.221
  +++ Component.java	16 Dec 2006 14:06:57 -0000	1.222
  @@ -122,7 +122,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.221 $
  + * @version $Revision: 1.222 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -474,10 +474,11 @@
               if ( method.isAnnotationPresent(Observer.class) )
               {
                  Init init = (Init) applicationContext.get( Seam.getComponentName(Init.class) ); //can't use Init.instance() here 'cos of unit tests
  -               for ( String eventType : method.getAnnotation(Observer.class).value() )
  +               Observer observer = method.getAnnotation(Observer.class);
  +               for ( String eventType : observer.value() )
                  {
                     if ( eventType.length()==0 ) eventType = method.getName(); //TODO: new defaulting rule to map @Observer onFooEvent() -> event type "fooEvent"
  -                  init.addObserverMethod(eventType, method, this);
  +                  init.addObserverMethod( eventType, method, this, observer.create() );
                  }
               }
               if ( method.isAnnotationPresent(RequestParameter.class) )
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:06:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:06:57 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/annotations  ...
Message-ID: <E1GvaBl-0000La-N4@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:06:57

  Modified:    src/main/org/jboss/seam/annotations  Observer.java
  Log:
  better handling of empty string
  JBSEAM-570, @Observer(create=false)
  
  Revision  Changes    Path
  1.4       +9 -0      jboss-seam/src/main/org/jboss/seam/annotations/Observer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Observer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/annotations/Observer.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- Observer.java	8 May 2006 20:00:39 -0000	1.3
  +++ Observer.java	16 Dec 2006 14:06:57 -0000	1.4
  @@ -22,4 +22,13 @@
       * @return the event type or types to observe
       */
      String[] value() default {};
  +   /**
  +    * In case no component instance exists,
  +    * should a component instance be created to
  +    * handle the event, or should the event be
  +    * ignored.
  +    * 
  +    * @return true by default
  +    */
  +   boolean create() default true;
   }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:06:57 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:06:57 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GvaBl-0000Lk-Sg@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:06:57

  Modified:    src/main/org/jboss/seam/core   Events.java Init.java
  Log:
  better handling of empty string
  JBSEAM-570, @Observer(create=false)
  
  Revision  Changes    Path
  1.16      +5 -2      jboss-seam/src/main/org/jboss/seam/core/Events.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Events.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Events.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- Events.java	16 Dec 2006 04:34:06 -0000	1.15
  +++ Events.java	16 Dec 2006 14:06:57 -0000	1.16
  @@ -110,11 +110,14 @@
         {
            for (ObserverMethod observer: observers)
            {
  -            Object listener = Component.getInstance( observer.component.getName(), true );
  +            Object listener = Component.getInstance( observer.component.getName(), observer.create );
  +            if (listener!=null)
  +            {
               observer.component.callComponentMethod(listener, observer.method, parameters);
            }
         }
      }
  +   }
      
      public void raiseAsynchronousEvent(String type, Object... parameters)
      {
  
  
  
  1.34      +6 -4      jboss-seam/src/main/org/jboss/seam/core/Init.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Init.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Init.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- Init.java	30 Nov 2006 02:09:10 -0000	1.33
  +++ Init.java	16 Dec 2006 14:06:57 -0000	1.34
  @@ -1,4 +1,4 @@
  -//$Id: Init.java,v 1.33 2006/11/30 02:09:10 gavin Exp $
  +//$Id: Init.java,v 1.34 2006/12/16 14:06:57 gavin Exp $
   package org.jboss.seam.core;
   
   
  @@ -188,10 +188,12 @@
      public static class ObserverMethod {
         public Method method;
         public Component component;
  -      ObserverMethod(Method method, Component component)
  +      public boolean create;
  +      ObserverMethod(Method method, Component component, boolean create)
         {
            this.method = method;
            this.component = component;
  +         this.create = create;
         }
         @Override
         public String toString()
  @@ -205,7 +207,7 @@
         return observers.get(eventType);
      }
      
  -   public void addObserverMethod(String eventType, Method method, Component component)
  +   public void addObserverMethod(String eventType, Method method, Component component, boolean create)
      {
         List<ObserverMethod> observerList = observers.get(eventType);
         if (observerList==null)
  @@ -213,7 +215,7 @@
            observerList = new ArrayList<ObserverMethod>();
            observers.put(eventType, observerList);
         }
  -      observerList.add( new ObserverMethod(method, component) );
  +      observerList.add( new ObserverMethod(method, component, create) );
      }
      
      public boolean isJbpmInstalled()
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:06:58 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:06:58 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/framework    ...
Message-ID: <E1GvaBm-0000Lx-1q@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:06:58

  Modified:    src/main/org/jboss/seam/framework    EntityQuery.java
                        HibernateEntityQuery.java Query.java
  Log:
  better handling of empty string
  JBSEAM-570, @Observer(create=false)
  
  Revision  Changes    Path
  1.7       +1 -1      jboss-seam/src/main/org/jboss/seam/framework/EntityQuery.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityQuery.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/EntityQuery.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- EntityQuery.java	14 Dec 2006 08:37:49 -0000	1.6
  +++ EntityQuery.java	16 Dec 2006 14:06:58 -0000	1.7
  @@ -128,7 +128,7 @@
         for (int i=0; i<parameters.size(); i++)
         {
            Object parameterValue = parameters.get(i);
  -         if (parameterValue!=null)
  +         if ( isRestrictionParameterSet(parameterValue) )
            {
               query.setParameter( "p" + (start + i), parameterValue );
            }
  
  
  
  1.6       +1 -1      jboss-seam/src/main/org/jboss/seam/framework/HibernateEntityQuery.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HibernateEntityQuery.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/HibernateEntityQuery.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- HibernateEntityQuery.java	14 Dec 2006 08:37:49 -0000	1.5
  +++ HibernateEntityQuery.java	16 Dec 2006 14:06:58 -0000	1.6
  @@ -123,7 +123,7 @@
         for (int i=0; i<parameters.size(); i++)
         {
            Object parameterValue = parameters.get(i);
  -         if (parameterValue!=null)
  +         if ( isRestrictionParameterSet(parameterValue) )
            {
               query.setParameter( "p" + (start + i), parameterValue );
            }
  
  
  
  1.14      +6 -1      jboss-seam/src/main/org/jboss/seam/framework/Query.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Query.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/Query.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- Query.java	14 Dec 2006 08:37:49 -0000	1.13
  +++ Query.java	16 Dec 2006 14:06:58 -0000	1.14
  @@ -178,7 +178,7 @@
         for (int i=0; i<getRestrictions().size(); i++)
         {
            Object parameterValue = restrictionParameters.get(i).getValue();
  -         if (parameterValue!=null)
  +         if ( isRestrictionParameterSet(parameterValue) )
            {
               if ( builder.toString().toLowerCase().indexOf("where")>0 )
               {
  @@ -197,6 +197,11 @@
         return builder.toString();
      }
   
  +   protected boolean isRestrictionParameterSet(Object parameterValue)
  +   {
  +      return parameterValue!=null && !"".equals(parameterValue);
  +   }
  +
      protected String getCountEjbql()
      {
         String ejbql = getRenderedEjbql();    
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:37:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:37:37 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvafR-0000nV-T1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:37:37

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  JBSEAM-603
  
  Revision  Changes    Path
  1.6       +1 -0      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- pages-1.1.dtd	10 Dec 2006 14:22:28 -0000	1.5
  +++ pages-1.1.dtd	16 Dec 2006 14:37:37 -0000	1.6
  @@ -14,6 +14,7 @@
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
   <!ATTLIST page no-conversation-view-id CDATA #IMPLIED>
  +<!ATTLIST page conversation-required (true|false) "false">
   <!ATTLIST page timeout CDATA #IMPLIED>
   <!ATTLIST page bundle CDATA #IMPLIED>
   
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:37:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:37:38 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GvafS-0000nf-0v@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:37:38

  Modified:    src/main/org/jboss/seam/core   Page.java Pages.java
  Log:
  JBSEAM-603
  
  Revision  Changes    Path
  1.8       +11 -0     jboss-seam/src/main/org/jboss/seam/core/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Page.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- Page.java	10 Dec 2006 14:22:28 -0000	1.7
  +++ Page.java	16 Dec 2006 14:37:37 -0000	1.8
  @@ -108,6 +108,7 @@
      private boolean nested;
      private FlushModeType flushMode;
      private String pageflow;
  +   private boolean conversationRequired;
      
      Page(String viewId)
      {
  @@ -322,4 +323,14 @@
         this.pageflow = pageflow;
      }
   
  +   public boolean isConversationRequired()
  +   {
  +      return conversationRequired;
  +   }
  +
  +   protected void setConversationRequired(boolean conversationRequired)
  +   {
  +      this.conversationRequired = conversationRequired;
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.60      +12 -4     jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.59
  retrieving revision 1.60
  diff -u -b -r1.59 -r1.60
  --- Pages.java	16 Dec 2006 02:58:10 -0000	1.59
  +++ Pages.java	16 Dec 2006 14:37:37 -0000	1.60
  @@ -131,7 +131,7 @@
         Page entry = new Page(viewId);
         pagesByViewId.put(viewId, entry);
         
  -      entry.setSwitchEnabled(!"disabled".equals( page.attributeValue("switch") ));
  +      entry.setSwitchEnabled( !"disabled".equals( page.attributeValue("switch") ) );
         
         String description = page.getTextTrim();
         if (description!=null && description.length()>0)
  @@ -145,8 +145,8 @@
            entry.setTimeout(Integer.parseInt(timeoutString));
         }
         
  -      String noConversationViewId = page.attributeValue("no-conversation-view-id");
  -      entry.setNoConversationViewId(noConversationViewId);
  +      entry.setNoConversationViewId( page.attributeValue("no-conversation-view-id") );
  +      entry.setConversationRequired( "true".equals( page.attributeValue("conversation-required") ) );
         
         String action = page.attributeValue("action");
         if (action!=null)
  @@ -330,8 +330,16 @@
         String viewId = facesContext.getViewRoot().getViewId();
         for ( Page page: getPageStack(viewId) )
         {
  +         if ( page.isConversationRequired() && !Manager.instance().isLongRunningConversation() )
  +         {
  +            Manager.instance().redirectToNoConversationView();
  +            return result;
  +         }
  +         else
  +         {
            result = callAction(page, facesContext) || result;
         }
  +      }
         return result;
      }
   
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:38:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:38:42 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF   ...
Message-ID: <E1GvagU-0000o1-S1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:38:42

  Modified:    examples/booking/resources/WEB-INF   components.xml
                        pages.xml
  Log:
  conversation-required
  
  Revision  Changes    Path
  1.9       +0 -2      jboss-seam/examples/booking/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/components.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- components.xml	16 Dec 2006 04:34:58 -0000	1.8
  +++ components.xml	16 Dec 2006 14:38:42 -0000	1.9
  @@ -8,8 +8,6 @@
   
       <core:init jndi-pattern="@jndiPattern@" debug="true"/>    
   
  -    <core:pages no-conversation-view-id="/main.xhtml"/>
  -
       <core:manager conversation-timeout="120000" 
                     concurrent-request-timeout="500"
                     conversation-id-parameter="cid"
  
  
  
  1.6       +4 -4      jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- pages.xml	10 Nov 2006 19:07:54 -0000	1.5
  +++ pages.xml	16 Dec 2006 14:38:42 -0000	1.6
  @@ -2,8 +2,8 @@
     "-//JBoss/Seam Pages Configuration DTD 1.1//EN"
     "http://jboss.com/products/seam/pages-1.1.dtd">
   
  -<pages>
  -	<page view-id="/hotel.xhtml">View hotel: #{hotel.name}</page>
  -	<page view-id="/book.xhtml">Book hotel: #{hotel.name}</page>
  -	<page view-id="/confirm.xhtml">Confirm: #{booking.description}</page>
  +<pages no-conversation-view-id="/main.xhtml">
  +	<page view-id="/hotel.xhtml" conversation-required="true">View hotel: #{hotel.name}</page>
  +	<page view-id="/book.xhtml" conversation-required="true">Book hotel: #{hotel.name}</page>
  +	<page view-id="/confirm.xhtml" conversation-required="true">Confirm: #{booking.description}</page>
   </pages>
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:38:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:38:42 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1GvagU-0000o8-Vq@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:38:42

  Modified:    examples/booking/src/org/jboss/seam/example/booking 
                        Booking.java
  Log:
  conversation-required
  
  Revision  Changes    Path
  1.13      +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Booking.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Booking.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Booking.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- Booking.java	15 Dec 2006 13:26:32 -0000	1.12
  +++ Booking.java	16 Dec 2006 14:38:42 -0000	1.13
  @@ -1,4 +1,4 @@
  -//$Id: Booking.java,v 1.12 2006/12/15 13:26:32 gavin Exp $
  +//$Id: Booking.java,v 1.13 2006/12/16 14:38:42 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.io.Serializable;
  @@ -125,7 +125,7 @@
      public String getDescription()
      {
         DateFormat df = DateFormat.getDateInstance(DateFormat.MEDIUM);
  -      return hotel.getName() + 
  +      return hotel==null ? null : hotel.getName() + 
               ", " + df.format( getCheckinDate() ) + 
               " to " + df.format( getCheckoutDate() );
      }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:51:30 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:51:30 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gvass-000111-TJ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:51:30

  Modified:    seam-gen  build.xml
  Log:
  protect edit screen
  
  Revision  Changes    Path
  1.55      +1 -1      jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.54
  retrieving revision 1.55
  diff -u -b -r1.54 -r1.55
  --- build.xml	16 Dec 2006 13:43:15 -0000	1.54
  +++ build.xml	16 Dec 2006 14:51:30 -0000	1.55
  @@ -732,7 +732,7 @@
           	                template="view/view.xhtml.ftl" 
           		             destdir="${project.home}/view"/>
           	<hbmtemplate filepattern="{class-name}.page.xml"
  -        	                template="view/edit.page.xml.ftl" 
  +        	                template="view/view.page.xml.ftl" 
           		             destdir="${project.home}/view"/>
           	<hbmtemplate filepattern="{class-name}Edit.xhtml"
           	                template="view/edit.xhtml.ftl" 
  
  
  


From gavin.king at jboss.com  Sat Dec 16 09:51:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 09:51:31 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view   ...
Message-ID: <E1Gvast-00011B-0v@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 09:51:31

  Modified:    seam-gen/view   edit.page.xml.ftl
  Added:       seam-gen/view   view.page.xml.ftl
  Log:
  protect edit screen
  
  Revision  Changes    Path
  1.3       +3 -1      jboss-seam/seam-gen/view/edit.page.xml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: edit.page.xml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/edit.page.xml.ftl,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- edit.page.xml.ftl	10 Dec 2006 16:53:28 -0000	1.2
  +++ edit.page.xml.ftl	16 Dec 2006 14:51:30 -0000	1.3
  @@ -6,7 +6,9 @@
   <#assign componentName = util.lower(entityName)>
   <#assign homeName = componentName + "Home">
   <#assign idName = componentName + util.upper(pojo.identifierProperty.name)>
  -<page>
  +<#assign masterPageName = entityName + "List">
  +<page no-conversation-view-id="/${masterPageName}.xhtml"
  +        conversation-required="true">
      <param name="${componentName}From"/>
      <param name="${idName}" value="${'#'}{${homeName}.${idName}}"/>
   <#include "param.xml.ftl">
  
  
  
  1.1      date: 2006/12/16 14:51:30;  author: gavin;  state: Exp;jboss-seam/seam-gen/view/view.page.xml.ftl
  
  Index: view.page.xml.ftl
  ===================================================================
  <!DOCTYPE page PUBLIC
            "-//JBoss/Seam Pages Configuration DTD 1.1//EN"
            "http://jboss.com/products/seam/pages-1.1.dtd">
  
  <#assign entityName = pojo.shortName>
  <#assign componentName = util.lower(entityName)>
  <#assign homeName = componentName + "Home">
  <#assign idName = componentName + util.upper(pojo.identifierProperty.name)>
  <page>
     <param name="${componentName}From"/>
     <param name="${idName}" value="${'#'}{${homeName}.${idName}}"/>
  <#include "param.xml.ftl">
  </page>
  
  


From gavin.king at jboss.com  Sat Dec 16 10:04:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 10:04:04 -0500
Subject: [jboss-cvs] jboss-seam    ...
Message-ID: <E1Gvb52-0001P3-Mc@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 10:04:04

  Modified:    jboss-seam    build.xml readme.txt changelog.txt
  Log:
  1.1.1
  
  Revision  Changes    Path
  1.123     +1 -1      jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.122
  retrieving revision 1.123
  diff -u -b -r1.122 -r1.123
  --- build.xml	15 Dec 2006 13:36:43 -0000	1.122
  +++ build.xml	16 Dec 2006 15:04:04 -0000	1.123
  @@ -14,7 +14,7 @@
       <property name="Name"                 value="JBoss Seam"/>
       <property name="name"                 value="jboss-seam"/>
       <property name="version"              value="1.1"/>
  -    <property name="patchlevel"           value="0.GA"/>
  +    <property name="patchlevel"           value="1.GA"/>
   
       <!-- set global properties for this build -->
       <property name="build.dir"            value="build"/>
  
  
  
  1.27      +1 -1      jboss-seam/readme.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: readme.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/readme.txt,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- readme.txt	13 Dec 2006 10:10:43 -0000	1.26
  +++ readme.txt	16 Dec 2006 15:04:04 -0000	1.27
  @@ -1,6 +1,6 @@
   JBoss Seam - Contextual Component framework for Java EE 5
   =========================================================
  -version 1.1.0.GA, December 2006
  +version 1.1.1.GA, December 2006
   
   This software is distributed under the terms of the FSF Lesser Gnu
   Public License (see lgpl.txt).
  
  
  
  1.34      +2 -0      jboss-seam/changelog.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: changelog.txt
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/changelog.txt,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- changelog.txt	13 Dec 2006 11:20:28 -0000	1.33
  +++ changelog.txt	16 Dec 2006 15:04:04 -0000	1.34
  @@ -1,5 +1,7 @@
   JBoss Seam Changelog
   ====================
  +Changes in version 1.1.1.GA (December 2006)
  +-------------------------------------------
   Changes in version 1.1.0.GA (December 2006)
   -------------------------------------------
   ** Bug
  
  
  


From gavin.king at jboss.com  Sat Dec 16 10:04:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 10:04:04 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/servlet  ...
Message-ID: <E1Gvb52-0001PA-Q7@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 10:04:04

  Modified:    src/main/org/jboss/seam/servlet  SeamListener.java
  Log:
  1.1.1
  
  Revision  Changes    Path
  1.21      +1 -1      jboss-seam/src/main/org/jboss/seam/servlet/SeamListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/servlet/SeamListener.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- SeamListener.java	16 Dec 2006 02:58:12 -0000	1.20
  +++ SeamListener.java	16 Dec 2006 15:04:04 -0000	1.21
  @@ -28,7 +28,7 @@
      private static final LogProvider log = Logging.getLogProvider(ServletContextListener.class);
   
      public void contextInitialized(ServletContextEvent event) {
  -      log.info("Welcome to Seam 1.1.0.GA");
  +      log.info("Welcome to Seam 1.1.1.GA");
         Lifecycle.setServletContext( event.getServletContext() );
         new Initialization( event.getServletContext() ).init();
      }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 10:04:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 10:04:04 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en  ...
Message-ID: <E1Gvb52-0001PH-UY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 10:04:04

  Modified:    doc/reference/en  master.xml
  Log:
  1.1.1
  
  Revision  Changes    Path
  1.48      +1 -1      jboss-seam/doc/reference/en/master.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: master.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/master.xml,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -b -r1.47 -r1.48
  --- master.xml	14 Dec 2006 07:14:09 -0000	1.47
  +++ master.xml	16 Dec 2006 15:04:04 -0000	1.48
  @@ -29,7 +29,7 @@
       <bookinfo>
           <title>Seam - Contextual Components</title>
           <subtitle>A Framework for Java EE 5</subtitle>
  -        <releaseinfo>1.1.0.GA</releaseinfo>
  +        <releaseinfo>1.1.1.GA</releaseinfo>
       </bookinfo>
   
       <toc/>
  
  
  


From gavin.king at jboss.com  Sat Dec 16 10:05:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 10:05:39 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1Gvb6Z-0001RI-Qt@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 10:05:39

  Modified:    seam-gen/view  list.xhtml.ftl
  Log:
  minor
  
  Revision  Changes    Path
  1.10      +0 -1      jboss-seam/seam-gen/view/list.xhtml.ftl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: list.xhtml.ftl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/view/list.xhtml.ftl,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- list.xhtml.ftl	16 Dec 2006 13:26:10 -0000	1.9
  +++ list.xhtml.ftl	16 Dec 2006 15:05:39 -0000	1.10
  @@ -12,7 +12,6 @@
                   xmlns:ui="http://java.sun.com/jsf/facelets"
                   xmlns:f="http://java.sun.com/jsf/core"
                   xmlns:h="http://java.sun.com/jsf/html"
  -                xmlns:fn="http://java.sun.com/jsp/jstl/functions"
                   template="layout/template.xhtml">
                          
   <ui:define name="body">
  
  
  


From gavin.king at jboss.com  Sat Dec 16 11:05:20 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 11:05:20 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1Gvc2K-0002Xa-OB@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 11:05:20

  Modified:    src/main/org/jboss/seam/contexts  Lifecycle.java
  Log:
  reduce jbpm dependency
  
  Revision  Changes    Path
  1.73      +6 -8      jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.72
  retrieving revision 1.73
  diff -u -b -r1.72 -r1.73
  --- Lifecycle.java	16 Dec 2006 02:58:10 -0000	1.72
  +++ Lifecycle.java	16 Dec 2006 16:05:20 -0000	1.73
  @@ -15,8 +15,6 @@
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpSession;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -26,12 +24,13 @@
   import org.jboss.seam.core.Init;
   import org.jboss.seam.core.Manager;
   import org.jboss.seam.core.Mutable;
  -import org.jboss.seam.core.ProcessInstance;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.72 $
  + * @version $Revision: 1.73 $
    */
   public class Lifecycle
   {
  @@ -332,11 +331,10 @@
   
            if ( Contexts.isBusinessProcessContextActive() )
            {
  -            boolean destroyBusinessProcessContext = !Init.instance().isJbpmInstalled() ||
  -                  !BusinessProcess.instance().hasCurrentProcess() ||
                     //TODO: it would be nice if BP context spanned redirects along with the conversation
                     //      this would also require changes to BusinessProcessContext
  -                  ProcessInstance.instance().hasEnded();
  +            boolean destroyBusinessProcessContext = !Init.instance().isJbpmInstalled() ||
  +                  !BusinessProcess.instance().hasActiveProcess();
               if ( destroyBusinessProcessContext )
               {
                  //TODO: note that this occurs from Lifecycle.endRequest(), after
  
  
  


From gavin.king at jboss.com  Sat Dec 16 11:05:20 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 11:05:20 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1Gvc2K-0002Xk-RS@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 11:05:20

  Modified:    src/main/org/jboss/seam/core   BusinessProcess.java
                        Dispatcher.java
  Log:
  reduce jbpm dependency
  
  Revision  Changes    Path
  1.15      +10 -0     jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcess.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- BusinessProcess.java	14 Dec 2006 13:08:57 -0000	1.14
  +++ BusinessProcess.java	16 Dec 2006 16:05:20 -0000	1.15
  @@ -52,6 +52,16 @@
      }
   
      /**
  +    * Is there a process instance that has not ended 
  +    * associated with the current conversation?
  +    */
  +   public boolean hasActiveProcess()
  +   {
  +      return hasCurrentProcess() && 
  +            !org.jboss.seam.core.ProcessInstance.instance().hasEnded();
  +   }
  +
  +   /**
       * Is there a task instance associated with 
       * the current conversation?
       */
  
  
  
  1.14      +2 -1      jboss-seam/src/main/org/jboss/seam/core/Dispatcher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Dispatcher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Dispatcher.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- Dispatcher.java	24 Nov 2006 23:15:17 -0000	1.13
  +++ Dispatcher.java	16 Dec 2006 16:05:20 -0000	1.14
  @@ -59,7 +59,8 @@
         {
            if ( Init.instance().isJbpmInstalled() )
            {
  -            processId = BusinessProcess.instance().getProcessId();
  +            BusinessProcess businessProcess = BusinessProcess.instance();
  +            processId = businessProcess.getProcessId();
               taskId = BusinessProcess.instance().getTaskId();
            }        
         }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 11:36:26 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 11:36:26 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GvcWQ-00031a-QL@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 11:36:26

  Modified:    doc/reference/en/modules  validation.xml
  Log:
  doc required=true limitation
  
  Revision  Changes    Path
  1.3       +27 -15    jboss-seam/doc/reference/en/modules/validation.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: validation.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/validation.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- validation.xml	31 Oct 2006 06:52:56 -0000	1.2
  +++ validation.xml	16 Dec 2006 16:36:26 -0000	1.3
  @@ -10,13 +10,13 @@
       </div>
       <div>
           Country:
  -        <h:inputText value="#{location.country}">
  +        <h:inputText value="#{location.country}" required="true">
               <my:validateCountry/>
           </h:inputText>
       </div>
       <div>
           Zip code:
  -        <h:inputText value="#{location.zip}">
  +        <h:inputText value="#{location.zip}" required="true">
               <my:validateZip/>
           </h:inputText>
       </div>
  @@ -42,10 +42,12 @@
       private String country;
       private String zip;
       
  +    @NotNull
       @Length(max=30)
       public String getCountry() { return country; }
       public void setCountry(String c) { country = c; }
   
  +    @NotNull
       @Length(max=6)
       @Pattern("^\d*$")
       public String getZip() { return zip; }
  @@ -62,10 +64,12 @@
       private String country;
       private String zip;
       
  +    @NotNull
       @Country
       public String getCountry() { return country; }
       public void setCountry(String c) { country = c; }
   
  +    @NotNull
       @ZipCode
       public String getZip() { return zip; }
       public void setZip(String z) { zip = z; }
  @@ -84,13 +88,13 @@
       </div>
       <div>
           Country:
  -        <h:inputText value="#{location.country}">
  +        <h:inputText value="#{location.country}" required="true">
               <s:validate/>
           </h:inputText>
       </div>
       <div>
           Zip code:
  -        <h:inputText value="#{location.zip}">
  +        <h:inputText value="#{location.zip}" required="true">
               <s:validate/>
           </h:inputText>
       </div>
  @@ -100,8 +104,15 @@
   </h:form>]]></programlisting>
   
        <para>
  -         This is not much less verbose than what we started with, so
  -         let's try <literal>&lt;s:validateAll&gt;</literal>:
  +         <emphasis>Note:</emphasis> specifying <literal>@NotNull</literal>
  +         on the model does <emphasis>not</emphasis> eliminate the requirement
  +         for <literal>required="true"</literal> to appear on the control!
  +         This is due to a limitation of the JSF validation architecture.
  +     </para>
  +
  +     <para>
  +         This version is not much less verbose than what we started with, 
  +         so let's try <literal>&lt;s:validateAll&gt;</literal>:
        </para>
   
       <programlisting><![CDATA[<h:form>
  @@ -111,11 +122,11 @@
       <s:validateAll>
           <div>
               Country:
  -            <h:inputText value="#{location.country}"/>
  +            <h:inputText value="#{location.country}" required="true"/>
           </div>
           <div>
               Zip code:
  -            <h:inputText value="#{location.zip}"/>
  +            <h:inputText value="#{location.zip}" required="true"/>
           </div>
           <div>
               <h:commandButton/>
  @@ -125,7 +136,8 @@
        
        <para>
            This tag simply adds an <literal>&lt;s:validate&gt;</literal>
  -         to every input in the form.
  +         to every input in the form. For a large form, it can save a lot
  +         of typing!
        </para>
   
        <para>
  @@ -153,7 +165,7 @@
                   <f:facet name="beforeInvalidField"><h:graphicImage src="img/error.gif"/></f:facet>
                   <f:facet name="afterInvalidField"><s:message/></f:facet>
                   <f:facet name="aroundInvalidField"><s:span styleClass="error"/></f:facet>
  -                <h:inputText value="#{location.country}"/>
  +                <h:inputText value="#{location.country}" required="true"/>
               </s:decorate>
           </div>
           <div>
  @@ -162,7 +174,7 @@
                   <f:facet name="beforeInvalidField"><h:graphicImage src="img/error.gif"/></f:facet>
                   <f:facet name="afterInvalidField"><s:message/></f:facet>
                   <f:facet name="aroundInvalidField"><s:span styleClass="error"/></f:facet>
  -                <h:inputText value="#{location.zip}"/>
  +                <h:inputText value="#{location.zip}" required="true"/>
               </s:decorate>
           </div>
           <div>
  @@ -194,13 +206,13 @@
           <div>
               Country:
               <s:decorate>
  -                <h:inputText value="#{location.country}"/>
  +                <h:inputText value="#{location.country}" required="true"/>
               </s:decorate>
           </div>
           <div>
               Zip code:
               <s:decorate>
  -                <h:inputText value="#{location.zip}"/>
  +                <h:inputText value="#{location.zip}" required="true"/>
               </s:decorate>
           </div>
           <div>
  @@ -234,7 +246,7 @@
           <div>
               Country:
               <s:decorate>
  -                <h:inputText value="#{location.country}" id="country">
  +                <h:inputText value="#{location.country}" required="true">
                       <a:support event="onblur" reRender="countryError"/>
                   </h:inputText>
                   <a:outputPanel id="countryError><s:message/></a:outputPanel>
  @@ -243,7 +255,7 @@
           <div>
               Zip code:
               <s:decorate>
  -                <h:inputText value="#{location.zip}">
  +                <h:inputText value="#{location.zip}" required="true">
                       <a:support event="onblur" reRender="zipError"/>
                   </h:inputText>
                   <a:outputPanel id="zipError><s:message/></a:outputPanel>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec 16 12:43:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 16 Dec 2006 12:43:34 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1807 -
	trunk/tests/src/org/jboss/test/messaging/core/ha
Message-ID: <E1GvdZO-0004Ih-Px@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-16 12:43:33 -0500 (Sat, 16 Dec 2006)
New Revision: 1807

Removed:
   trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java
Log:
Removing unused tests

Deleted: trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java	2006-12-16 11:43:39 UTC (rev 1806)
+++ trunk/tests/src/org/jboss/test/messaging/core/ha/ClusterecConnectionTest.java	2006-12-16 17:43:33 UTC (rev 1807)
@@ -1,53 +0,0 @@
-package org.jboss.test.messaging.core.ha;
-
-import javax.jms.Destination;
-import javax.jms.MessageProducer;
-import javax.jms.Session;
-
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.JBossConnectionFactory;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.state.ConnectionState;
-
-/**
- * Start two JBoss instances (clustered) to run these tests.
- */
-public class ClusterecConnectionTest extends HATestBase
-{
-
-
-   public void setup() throws Exception
-   {
-      super.setUp("/HAConnectionFactory");
-   }
-
-   public void testSimpleConnection() throws Exception
-   {
-      JBossConnectionFactory factory = (JBossConnectionFactory)this.ctx1.lookup("/HAConnectionFactory");
-      JBossConnection conn = (JBossConnection) factory.createConnection();
-
-      ClusteredClientConnectionFactoryDelegate delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
-
-      assertEquals(2,delegate.getDelegates().length);
-
-      Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-
-      for (int i=0;i<100;i++)
-      {
-         JBossConnection conn2 = (JBossConnection)factory.createConnection();
-         conn2.setClientID("client" + i);
-         conn2.start();
-         Session session = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageProducer producer = session.createProducer(destination); 
-         ConnectionState state = (ConnectionState) ((ClientConnectionDelegate)conn2.getDelegate()).getState();
-         log.info("state.serverId=" + state.getServerID());
-         //conn2.close();
-      }
-
-      System.out.println("****************** finish *********************");
-
-
-      Thread.sleep(120000);
-   }
-}

Deleted: trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java	2006-12-16 11:43:39 UTC (rev 1806)
+++ trunk/tests/src/org/jboss/test/messaging/core/ha/ReconnectNonClusteredTest.java	2006-12-16 17:43:33 UTC (rev 1807)
@@ -1,390 +0,0 @@
-package org.jboss.test.messaging.core.ha;
-
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.JBossSession;
-import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.client.state.SessionState;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.message.JBossMessage;
-import org.jboss.jms.message.TextMessageProxy;
-
-import javax.jms.*;
-
-
-/** Start two JBoss instances (non clustered) to run these tests.
- *  */
-public class ReconnectNonClusteredTest extends HATestBase
-{
-
-//    public void testSimpleReconnect() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        assertFalse(state.isStarted());
-//        conn.start();
-//        assertTrue(state.isStarted());
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        conn.stop();
-//        assertFalse(state.isStarted());
-//
-//    }
-//
-//    public void testSimpleReconnectWithClientID() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.setClientID("someClient");
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        assertFalse(state.isStarted());
-//        conn.start();
-//        assertTrue(state.isStarted());
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        // force recovering the clientID from server
-//        state.setClientID(null);
-//        assertEquals ("someClient",conn.getClientID());
-//
-//        conn.stop();
-//        assertFalse(state.isStarted());
-//
-//    }
-//
-//    public void testWithSession() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//    }
-//
-//    public void testSimpleWithOneProducerOnTopic() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//        MessageProducer producer = session.createProducer(destination);
-//
-//        Message message = session.createTextMessage("Hello Before");
-//        producer.send(message);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        System.out.println("Kill server1");
-//        Thread.sleep(10000);
-//
-//
-//        message = session.createTextMessage("Hello After");
-//        producer.send(message);
-//    }
-//
-//    public void testSimpleWithOneProducerOnQueue() throws Exception
-//    {
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        Session session = conn.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        Destination destination = (Destination)getCtx1().lookup("queue/testQueue");
-//        MessageProducer producer = session.createProducer(destination);
-//
-//        Message message = session.createTextMessage("Hello Before");
-//        producer.send(message);
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        System.out.println("Kill server1");
-//        Thread.sleep(10000);
-//
-//
-//        message = session.createTextMessage("Hello After");
-//        producer.send(message);
-//    }
-//
-//    public void testSimpleWithOneProducerTransacted() throws Exception
-//    {
-//        log.info("++testSimpleWithOneProducerTransacted");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//
-//        log.info("Creating connections used for assertion (not failed over)");
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination);
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerFirstServer = sessionFirstServer.createConsumer(destination);
-//
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//
-//        log.info("ConnectionCreated=" + conn);
-//        log.info(">>Creating Sessions");
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>Creating Producer - ");
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        log.info("sending first commit");
-//        session.commit();
-//        Object txID = sessionState.getCurrentTxId();
-//
-//        assertNotNull(consumerFirstServer.receive(2000));
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        producer.send(session.createTextMessage("Hello again before failover"));
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        log.info(">>Creating alternate connection");
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        log.info("NewConnectionCreated=" + conn2);
-//
-//        log.info(">>Failling over");
-//        assertSame(originalRemoting,delegate.getRemotingConnection());
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//        /*try {
-//            originalRemoting.stop();
-//        } catch (Throwable throwable) {
-//            throwable.printStackTrace();  //To change body of catch statement use File | Settings | File Templates.
-//        } */
-//
-//        assertNotSame(originalRemoting,delegate.getRemotingConnection());
-//
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//        session.commit();
-//
-//        log.info("Checking receive on second server");
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        log.info("Checking receive on first server");
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//    }
-//
-//    public void testSimpleWithOneProducerTransactedWithoutHA() throws Exception
-//    {
-//        log.info("++testSimpleWithOneProducerTransacted");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//
-//        log.info("Creating connections used for assertion (not failed over)");
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination);
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerFirstServer = sessionFirstServer.createConsumer(destination);
-//
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer2.createConnection();
-//
-//        log.info("ConnectionCreated=" + conn);
-//        log.info(">>Creating Sessions");
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//        System.out.println("Size of callbackHandlers=" + sessionState.getCallbackHandlers().size());
-//        Object txID = sessionState.getCurrentTxId();
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>Creating Producer - ");
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        log.info("sending first commit");
-//        //session.commit();
-//
-//        assertNull(consumerFirstServer.receive(2000));
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        TextMessageProxy messagetxt = (TextMessageProxy)session.createTextMessage("Hello again before failover");
-//        producer.send(messagetxt);
-//        System.out.println("Id=" + messagetxt.getMessage().getConnectionID());
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        log.info(">>Failling over");
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//        session.commit();
-//
-//        log.info("Checking receive on second server");
-//        assertNull(consumerFirstServer.receive(1000));
-//        assertNotNull(consumerSecondServer.receive(3000));
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        assertNotNull(consumerSecondServer.receive(1000));
-//        log.info("Checking receive on first server");
-//        assertNull(consumerSecondServer.receive(1000));
-//
-//    }
-//
-//    public void testTopicSubscriber() throws Exception
-//    {
-//        log.info("++testSimpleWithOneProducerTransacted");
-//
-//        log.info(">>Lookup Queue");
-//        Destination destination = (Destination)getCtx1().lookup("topic/testTopic");
-//
-//        JBossConnection connFirstServer = (JBossConnection)this.factoryServer1.createConnection();
-//        connFirstServer.start();
-//        JBossSession sessionFirstServer = (JBossSession)connFirstServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//
-//
-//        log.info("Creating connection server1");
-//        JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
-//        conn.start();
-//
-//        log.info("ConnectionCreated=" + conn);
-//        log.info(">>Creating Sessions");
-//
-//        JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
-//        ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
-//        SessionState sessionState = (SessionState)clientSessionDelegate.getState();
-//        MessageConsumer consumerHA = session.createConsumer(destination);
-//        log.info(">>Creating Producer");
-//        MessageProducer producer = session.createProducer(destination);
-//        log.info(">>creating Message");
-//        Message message = session.createTextMessage("Hello Before");
-//        log.info(">>sending Message");
-//        producer.send(message);
-//        session.commit();
-//
-//        assertNotNull(consumerHA.receive(3000));
-//        session.commit();
-//
-//        Object txID = sessionState.getCurrentTxId();
-//
-//        producer.send(session.createTextMessage("Hello again before failover"));
-//
-//        ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
-//
-//        JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-//
-//        ConnectionState state = (ConnectionState)delegate.getState();
-//
-//        log.info(">>Creating alternate connection");
-//        JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
-//        log.info("NewConnectionCreated=" + conn2);
-//
-//        log.info(">>Failling over");
-//        assertSame(originalRemoting,delegate.getRemotingConnection());
-//        conn.getDelegate().failOver(conn2.getDelegate());
-//
-//        try {
-//            originalRemoting.stop();
-//        } catch (Throwable throwable) {
-//            throwable.printStackTrace();
-//        }
-//
-//
-//        assertNotSame(originalRemoting,delegate.getRemotingConnection());
-//
-//        //System.out.println("Kill server1"); Thread.sleep(10000);
-//
-//        message = session.createTextMessage("Hello After");
-//        log.info(">>Sending new message");
-//        producer.send(message);
-//
-//        assertEquals(txID,sessionState.getCurrentTxId());
-//        System.out.println("TransactionID on client = " + txID);
-//        log.info(">>Final commit");
-//
-//        JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-//        connSecondServer.start();
-//        JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-//        MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination);
-//
-//        session.commit();
-//
-//        //assertNotNull(consumerSecondServer.receive(3000));
-//        assertNotNull(consumerSecondServer.receive(3000));
-//        assertNotNull(consumerSecondServer.receive(3000));
-//        assertNull(consumerSecondServer.receive(3000));
-//
-//        log.info("Calling alternate receiver");
-//        //assertNotNull(consumerHA.receive(1000));
-//        assertNotNull(consumerHA.receive(1000));
-//        assertNotNull(consumerHA.receive(1000));
-//        assertNull(consumerHA.receive(1000));
-//
-//    }
-}



From hds765sgf4sd at lycos.com  Sat Dec 16 16:39:02 2006
From: hds765sgf4sd at lycos.com (hds765sgf4sd at lycos.com)
Date: Sat, 16 Dec 2006 16:39:02 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCscKCw6rCgsKpwoLDp8KJw6/CgsKmwoLDnMKC?=
	=?utf-8?b?wrnCgsOxwoLCqcKBSMKMfcKCwqbCgsOJwo1zwoLCq8KCw5zCgsK3woFC?=
Message-ID: 20061217070406.34383mail@mail.vcxzmnbvclkjhgfdsaqwertyuiop.com

?????Z?????????????????A?????
???????????????v?????B
?????????v???o???????????????A???S?????V???????B
?????A?????p?\?R???????[???????????o???????\?????????????A
?g???d?b???A???????????????H
http://www.freeweb.allfreemail.net.tonderuyo.com/DL/
?????????????????????B
?A?????????????????????????????????????????B





From gavin.king at jboss.com  Sat Dec 16 19:25:14 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 19:25:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1Gvjq6-0002ps-59@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 19:25:14

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  JBSEAM-605, navigation in pages.xml
  make s:link action trigger navigation even if outcome is null (but not page actions)
  
  Revision  Changes    Path
  1.7       +19 -2     jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- pages-1.1.dtd	16 Dec 2006 14:37:37 -0000	1.6
  +++ pages-1.1.dtd	17 Dec 2006 00:25:14 -0000	1.7
  @@ -9,7 +9,7 @@
   <!ELEMENT pages (page*)>
   <!ATTLIST pages no-conversation-view-id CDATA #IMPLIED>
   
  -<!ELEMENT page (#PCDATA|param|end-conversation|begin-conversation)*>
  +<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|navigation)*>
   <!ATTLIST page action CDATA #IMPLIED>
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
  @@ -24,10 +24,27 @@
   <!ATTLIST param converter CDATA #IMPLIED>
   <!ATTLIST param converterId CDATA #IMPLIED>
   
  -<!ELEMENT end-conversation EMPTY>
  +<!ELEMENT navigation (case*,default?)>
  +<!ATTLIST navigation action CDATA #IMPLIED>
  +<!ATTLIST navigation outcome CDATA #IMPLIED>
  +
  +<!ELEMENT case ((begin-conversation|end-conversation)?,(render|redirect))>
  +<!ATTLIST case outcome CDATA #REQUIRED>
  +
  +<!ELEMENT default ((begin-conversation|end-conversation)?,(render|redirect))>
   
   <!ELEMENT begin-conversation EMPTY>
   <!ATTLIST begin-conversation join (true|false) "false">
   <!ATTLIST begin-conversation nested (true|false) "false">
   <!ATTLIST begin-conversation pageflow CDATA #IMPLIED>
   <!ATTLIST begin-conversation flush-mode (manual|auto|commit|MANUAL|AUTO|COMMIT) #IMPLIED>
  +
  +<!ELEMENT end-conversation EMPTY>
  +
  +<!ELEMENT render EMPTY>
  +<!ATTLIST render view-id CDATA #IMPLIED>
  +
  +<!ELEMENT redirect EMPTY>
  +<!ATTLIST redirect view-id CDATA #IMPLIED>
  +
  +<!ELEMENT description (#PCDATA)>
  
  
  


From gavin.king at jboss.com  Sat Dec 16 19:25:14 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 19:25:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core    ...
Message-ID: <E1Gvjq6-0002q6-DO@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 19:25:14

  Modified:    src/main/org/jboss/seam/core    Exceptions.java Page.java
                        Pages.java
  Log:
  JBSEAM-605, navigation in pages.xml
  make s:link action trigger navigation even if outcome is null (but not page actions)
  
  Revision  Changes    Path
  1.18      +3 -47     jboss-seam/src/main/org/jboss/seam/core/Exceptions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Exceptions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Exceptions.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- Exceptions.java	16 Dec 2006 02:58:10 -0000	1.17
  +++ Exceptions.java	17 Dec 2006 00:25:14 -0000	1.18
  @@ -7,12 +7,9 @@
   import java.util.ArrayList;
   import java.util.List;
   
  -import javax.faces.component.UIViewRoot;
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseId;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  @@ -29,6 +26,8 @@
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.contexts.Lifecycle;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Reflections;
   import org.jboss.seam.util.Resources;
  @@ -45,7 +44,7 @@
   @Intercept(NEVER)
   @Install(precedence=BUILT_IN)
   @Name("org.jboss.seam.core.exceptions")
  -public class Exceptions 
  +public class Exceptions extends Navigator
   {
      private static final LogProvider log = Logging.getLogProvider(Exceptions.class);
      
  @@ -415,49 +414,6 @@
         }
      }
      
  -   protected static void error(int code, String message)
  -   {
  -      if ( log.isDebugEnabled() ) log.debug("sending error: " + code);
  -      org.jboss.seam.core.HttpError httpError = org.jboss.seam.core.HttpError.instance();
  -      if (message==null)
  -      {
  -         httpError.send(code);
  -      }
  -      else
  -      {
  -         httpError.send(code, message);
  -      }
  -   }
  -
  -   protected static void redirect(String viewId)
  -   {
  -      if ( Strings.isEmpty(viewId) )
  -      {
  -         viewId = FacesContext.getCurrentInstance().getViewRoot().getViewId();
  -      }
  -      if ( log.isDebugEnabled() ) log.debug("redirecting to: " + viewId);
  -      org.jboss.seam.core.Redirect redirect = org.jboss.seam.core.Redirect.instance();
  -      redirect.setViewId(viewId);
  -      redirect.execute();
  -   }
  -   
  -   protected static void render(String viewId)
  -   {
  -      FacesContext facesContext = FacesContext.getCurrentInstance();
  -      if ( !Strings.isEmpty(viewId) )
  -      {
  -         UIViewRoot viewRoot = facesContext.getApplication().getViewHandler()
  -               .createView(facesContext, viewId);
  -         facesContext.setViewRoot(viewRoot);
  -      }
  -      else
  -      {
  -         viewId = facesContext.getViewRoot().getViewId(); //just for the log message
  -      }
  -      if ( log.isDebugEnabled() ) log.debug("rendering: " + viewId);
  -      facesContext.renderResponse();
  -   }
  -
      private static Object rethrow(Exception e) throws Exception
      {
         //SeamExceptionFilter does *not* do these things, which 
  
  
  
  1.9       +141 -19   jboss-seam/src/main/org/jboss/seam/core/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Page.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- Page.java	16 Dec 2006 14:37:37 -0000	1.8
  +++ Page.java	17 Dec 2006 00:25:14 -0000	1.9
  @@ -1,7 +1,9 @@
   package org.jboss.seam.core;
   
   import java.util.ArrayList;
  +import java.util.HashMap;
   import java.util.List;
  +import java.util.Map;
   import java.util.MissingResourceException;
   
   import javax.faces.context.FacesContext;
  @@ -93,6 +95,109 @@
   
      }
   
  +   public static final class Navigation
  +   {
  +      private ValueBinding<Object> outcomeValueBinding;
  +      private Map<String, Case> cases = new HashMap<String, Case>();
  +      private Case defaultCase;
  +      
  +      public Map<String, Case> getCases()
  +      {
  +         return cases;
  +      }
  +      
  +      void setDefaultCase(Case defaultCase)
  +      {
  +         this.defaultCase = defaultCase;
  +      }
  +      public Case getDefaultCase()
  +      {
  +         return defaultCase;
  +      }
  +      
  +      void setOutcomeValueBinding(ValueBinding<Object> outcomeValueBinding)
  +      {
  +         this.outcomeValueBinding = outcomeValueBinding;
  +      }
  +      public ValueBinding<Object> getOutcomeValueBinding()
  +      {
  +         return outcomeValueBinding;
  +      }
  +   }
  +   
  +   public static final class Case
  +   {
  +      private Result result;
  +      private boolean isBeginConversation;
  +      private boolean isEndConversation;
  +      private boolean join;
  +      private boolean nested;
  +      private FlushModeType flushMode;
  +      private String pageflow;
  +      
  +      void setResult(Result result)
  +      {
  +         this.result = result;
  +      }
  +      Result getResult()
  +      {
  +         return result;
  +      }
  +      void setBeginConversation(boolean isBeginConversation)
  +      {
  +         this.isBeginConversation = isBeginConversation;
  +      }
  +      boolean isBeginConversation()
  +      {
  +         return isBeginConversation;
  +      }
  +      void setEndConversation(boolean isEndConversation)
  +      {
  +         this.isEndConversation = isEndConversation;
  +      }
  +      boolean isEndConversation()
  +      {
  +         return isEndConversation;
  +      }
  +      void setJoin(boolean join)
  +      {
  +         this.join = join;
  +      }
  +      boolean isJoin()
  +      {
  +         return join;
  +      }
  +      void setNested(boolean nested)
  +      {
  +         this.nested = nested;
  +      }
  +      boolean isNested()
  +      {
  +         return nested;
  +      }
  +      void setFlushMode(FlushModeType flushMode)
  +      {
  +         this.flushMode = flushMode;
  +      }
  +      FlushModeType getFlushMode()
  +      {
  +         return flushMode;
  +      }
  +      void setPageflow(String pageflow)
  +      {
  +         this.pageflow = pageflow;
  +      }
  +      String getPageflow()
  +      {
  +         return pageflow;
  +      }
  +   }
  +   
  +   public interface Result
  +   {
  +      public void navigate(FacesContext context);
  +   }
  +
      private final String viewId;
      private String description;
      private Integer timeout;
  @@ -101,7 +206,9 @@
      private String noConversationViewId;
      private String resourceBundleName;
      private boolean switchEnabled = true;
  -   private List<Page.PageParameter> pageParameters = new ArrayList<Page.PageParameter>();
  +   private List<PageParameter> pageParameters = new ArrayList<PageParameter>();
  +   private Map<String, Navigation> navigations = new HashMap<String, Navigation>();
  +   private Navigation defaultNavigation;
      private boolean isBeginConversation;
      private boolean isEndConversation;
      private boolean join;
  @@ -163,7 +270,7 @@
         return Interpolator.instance().interpolate( getDescription() );
      }
      
  -   public void setDescription(String description)
  +   void setDescription(String description)
      {
         this.description = description;
      }
  @@ -173,7 +280,7 @@
         return description;
      }
   
  -   public void setTimeout(Integer timeout)
  +   void setTimeout(Integer timeout)
      {
         this.timeout = timeout;
      }
  @@ -183,7 +290,7 @@
         return timeout;
      }
   
  -   public void setAction(MethodBinding action)
  +   void setAction(MethodBinding action)
      {
         this.action = action;
      }
  @@ -193,7 +300,7 @@
         return action;
      }
   
  -   public void setOutcome(String outcome)
  +   void setOutcome(String outcome)
      {
         this.outcome = outcome;
      }
  @@ -203,7 +310,7 @@
         return outcome;
      }
   
  -   public void setNoConversationViewId(String noConversationViewId)
  +   void setNoConversationViewId(String noConversationViewId)
      {
         this.noConversationViewId = noConversationViewId;
      }
  @@ -213,7 +320,7 @@
         return noConversationViewId;
      }
   
  -   public void setResourceBundleName(String resourceBundleName)
  +   void setResourceBundleName(String resourceBundleName)
      {
         this.resourceBundleName = resourceBundleName;
      }
  @@ -223,7 +330,7 @@
         return resourceBundleName;
      }
   
  -   public void setSwitchEnabled(boolean switchEnabled)
  +   void setSwitchEnabled(boolean switchEnabled)
      {
         this.switchEnabled = switchEnabled;
      }
  @@ -238,6 +345,11 @@
         return pageParameters;
      }
   
  +   public Map<String, Page.Navigation> getNavigations()
  +   {
  +      return navigations;
  +   }
  +
      public boolean hasDescription()
      {
         return description!=null;
  @@ -248,7 +360,7 @@
         return isBeginConversation;
      }
   
  -   public void setBeginConversation(boolean isBeginConversation)
  +   void setBeginConversation(boolean isBeginConversation)
      {
         this.isBeginConversation = isBeginConversation;
      }
  @@ -258,7 +370,7 @@
         return isEndConversation;
      }
   
  -   public void setEndConversation(boolean isEndConversation)
  +   void setEndConversation(boolean isEndConversation)
      {
         this.isEndConversation = isEndConversation;
      }
  @@ -283,42 +395,42 @@
         }
      }
   
  -   protected FlushModeType getFlushMode()
  +   public FlushModeType getFlushMode()
      {
         return flushMode;
      }
   
  -   protected void setFlushMode(FlushModeType flushMode)
  +   void setFlushMode(FlushModeType flushMode)
      {
         this.flushMode = flushMode;
      }
   
  -   protected boolean isJoin()
  +   public boolean isJoin()
      {
         return join;
      }
   
  -   protected void setJoin(boolean join)
  +   void setJoin(boolean join)
      {
         this.join = join;
      }
   
  -   protected boolean isNested()
  +   public boolean isNested()
      {
         return nested;
      }
   
  -   protected void setNested(boolean nested)
  +   void setNested(boolean nested)
      {
         this.nested = nested;
      }
   
  -   protected String getPageflow()
  +   public String getPageflow()
      {
         return pageflow;
      }
   
  -   protected void setPageflow(String pageflow)
  +   void setPageflow(String pageflow)
      {
         this.pageflow = pageflow;
      }
  @@ -328,9 +440,19 @@
         return conversationRequired;
      }
   
  -   protected void setConversationRequired(boolean conversationRequired)
  +   void setConversationRequired(boolean conversationRequired)
      {
         this.conversationRequired = conversationRequired;
      }
   
  +   public Navigation getDefaultNavigation()
  +   {
  +      return defaultNavigation;
  +   }
  +
  +   void setDefaultNavigation(Navigation defaultActionOutcomeMapping)
  +   {
  +      this.defaultNavigation = defaultActionOutcomeMapping;
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.61      +183 -52   jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.60
  retrieving revision 1.61
  diff -u -b -r1.60 -r1.61
  --- Pages.java	16 Dec 2006 14:37:37 -0000	1.60
  +++ Pages.java	17 Dec 2006 00:25:14 -0000	1.61
  @@ -19,8 +19,6 @@
   import javax.faces.context.FacesContext;
   import javax.faces.convert.Converter;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.dom4j.Document;
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  @@ -36,6 +34,8 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions.MethodBinding;
   import org.jboss.seam.core.Expressions.ValueBinding;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Parameters;
   import org.jboss.seam.util.Resources;
  @@ -50,7 +50,7 @@
   @Intercept(NEVER)
   @Name("org.jboss.seam.core.pages")
   @Install(precedence=BUILT_IN)
  -public class Pages 
  +public class Pages extends Navigator
   {
      
      private static final LogProvider log = Logging.getLogProvider(Pages.class);
  @@ -122,82 +122,133 @@
         return root;
      }
   
  -   private void parse(Element page, String viewId)
  +   private void parse(Element element, String viewId)
  +   {
  +      Page page = parsePage(element, viewId);
  +      
  +      List<Element> children = element.elements("param");
  +      for (Element param: children)
  +      {
  +         page.getPageParameters().add( parsePageParameter(param) );
  +      }
  +      
  +      List<Element> moreChildren = element.elements("navigation");
  +      for (Element fromAction: moreChildren)
  +      {
  +         parseNavigation(page, fromAction);
  +      }
  +   }
  +
  +   private Page parsePage(Element element, String viewId)
      {
         if ( viewId.endsWith("*") )
         {
            wildcardViewIds.add(viewId);
         }
  -      Page entry = new Page(viewId);
  -      pagesByViewId.put(viewId, entry);
  +      Page page = new Page(viewId);
  +      pagesByViewId.put(viewId, page);
         
  -      entry.setSwitchEnabled( !"disabled".equals( page.attributeValue("switch") ) );
  +      page.setSwitchEnabled( !"disabled".equals( element.attributeValue("switch") ) );
         
  -      String description = page.getTextTrim();
  +      Element optionalElement = element.element("description");
  +      String description = optionalElement==null ? 
  +               element.getTextTrim() : optionalElement.getTextTrim();
         if (description!=null && description.length()>0)
         {
  -         entry.setDescription(description);
  +         page.setDescription(description);
         }
         
  -      String timeoutString = page.attributeValue("timeout");
  +      String timeoutString = element.attributeValue("timeout");
         if (timeoutString!=null)
         {
  -         entry.setTimeout(Integer.parseInt(timeoutString));
  +         page.setTimeout(Integer.parseInt(timeoutString));
         }
         
  -      entry.setNoConversationViewId( page.attributeValue("no-conversation-view-id") );
  -      entry.setConversationRequired( "true".equals( page.attributeValue("conversation-required") ) );
  +      page.setNoConversationViewId( element.attributeValue("no-conversation-view-id") );
  +      page.setConversationRequired( "true".equals( element.attributeValue("conversation-required") ) );
         
  -      String action = page.attributeValue("action");
  +      String action = element.attributeValue("action");
         if (action!=null)
         {
            if ( action.startsWith("#{") )
            {
               MethodBinding methodBinding = Expressions.instance().createMethodBinding(action);
  -            entry.setAction(methodBinding);
  +            page.setAction(methodBinding);
            }
            else
            {
  -            entry.setOutcome(action);
  +            page.setOutcome(action);
            }
         }
         
  -      Element endConversation = page.element("end-conversation");
  +      Element endConversation = element.element("end-conversation");
         if ( endConversation!=null )
         {
  -         entry.setEndConversation(true);
  +         page.setEndConversation(true);
         }
         
  -      Element beginConversation = page.element("begin-conversation");
  +      Element beginConversation = element.element("begin-conversation");
         if ( beginConversation!=null )
         {
  -         entry.setBeginConversation(true);
  -         entry.setJoin( "true".equals( beginConversation.attributeValue("join") ) );
  -         entry.setNested( "true".equals( beginConversation.attributeValue("nested") ) );
  -         entry.setPageflow( beginConversation.attributeValue("pageflow") );
  +         page.setBeginConversation(true);
  +         page.setJoin( "true".equals( beginConversation.attributeValue("join") ) );
  +         page.setNested( "true".equals( beginConversation.attributeValue("nested") ) );
  +         page.setPageflow( beginConversation.attributeValue("pageflow") );
            String flushMode = beginConversation.attributeValue("flush-mode");
            if (flushMode!=null)
            {
  -            entry.setFlushMode( FlushModeType.valueOf( flushMode.toUpperCase() ) );
  +            page.setFlushMode( FlushModeType.valueOf( flushMode.toUpperCase() ) );
            }
         }
         
  -      if ( entry.isBeginConversation() && entry.isEndConversation() )
  +      if ( page.isBeginConversation() && page.isEndConversation() )
         {
            throw new IllegalStateException("cannot use both <begin-conversation/> and <end-conversation/>");
         }
         
  -      String bundle = page.attributeValue("bundle");
  +      String bundle = element.attributeValue("bundle");
         if (bundle!=null)
         {
  -         entry.setResourceBundleName(bundle);
  +         page.setResourceBundleName(bundle);
  +      }
  +      return page;
         }
         
  -      List<Element> children = page.elements("param");
  -      for (Element param: children)
  +   private void parseNavigation(Page entry, Element element)
  +   {
  +      Page.Navigation navigation = new Page.Navigation(); 
  +      String outcomeExpression = element.attributeValue("outcome");
  +      if (outcomeExpression!=null)
  +      {
  +         navigation.setOutcomeValueBinding(Expressions.instance().createValueBinding(outcomeExpression));
  +      }
  +      List<Element> cases = element.elements("case");
  +      for (Element childElement: cases)
  +      {
  +         Page.Case caze = parseCase(childElement);
  +         navigation.getCases().put( childElement.attributeValue("outcome"), caze );
  +      }
  +      Element childElement = element.element("default");
  +      if (childElement!=null)
  +      {
  +         navigation.setDefaultCase(parseCase(childElement));
  +      }
  +      
  +      String expression = element.attributeValue("action");
  +      if (expression==null)
  +      {
  +         entry.setDefaultNavigation(navigation);
  +      }
  +      else
  +      {
  +         entry.getNavigations().put(expression, navigation);
  +      }
  +   }
  +
  +   private Page.PageParameter parsePageParameter(Element element)
         {
  -         String valueExpression = param.attributeValue("value");
  -         String name = param.attributeValue("name");
  +      String valueExpression = element.attributeValue("value");
  +      String name = element.attributeValue("name");
            if (name==null)
            {
               if (valueExpression==null)
  @@ -211,14 +262,88 @@
            {
               pageParameter.setValueBinding(Expressions.instance().createValueBinding(valueExpression));
            }
  -         pageParameter.setConverterId(param.attributeValue("converterId"));
  -         String converterExpression = param.attributeValue("converter");
  +      pageParameter.setConverterId(element.attributeValue("converterId"));
  +      String converterExpression = element.attributeValue("converter");
            if (converterExpression!=null)
            {
               pageParameter.setConverterValueBinding(Expressions.instance().createValueBinding(converterExpression));
            }
  -         entry.getPageParameters().add(pageParameter);
  +      return pageParameter;
  +   }
  +
  +   private Page.Case parseCase(Element element)
  +   {
  +      Page.Case caze = new Page.Case();
  +      Element render = element.element("render");
  +      if (render!=null)
  +      {
  +         final String viewId = render.attributeValue("view-id");
  +         caze.setResult(new Page.Result() {
  +            public void navigate(FacesContext context)
  +            {
  +               render(viewId);
  +            }
  +         });
  +      }
  +      Element redirect = element.element("redirect");
  +      if (redirect!=null)
  +      {
  +         final String viewId = redirect.attributeValue("view-id");
  +         caze.setResult(new Page.Result() {
  +            public void navigate(FacesContext context)
  +            {
  +               redirect(viewId);
         }
  +         });
  +      }
  +      return caze;
  +   }
  +
  +   public boolean navigate(FacesContext context, String actionExpression, final String actionOutcome)
  +   {
  +      String viewId = context.getViewRoot().getViewId();
  +      if (viewId!=null)
  +      {
  +         List<Page> stack = getPageStack(viewId);
  +         for (int i=stack.size()-1; i>=0; i--)
  +         {
  +            Page page = stack.get(i);
  +            Page.Navigation navigation = page.getNavigations().get(actionExpression);
  +            if (navigation==null)
  +            {
  +               navigation = page.getDefaultNavigation();
  +            }
  +            
  +            if (navigation!=null)
  +            {
  +               
  +               String outcome;
  +               if ( navigation.getOutcomeValueBinding()==null )
  +               {
  +                  outcome = actionOutcome;
  +               }
  +               else
  +               {
  +                  Object value = navigation.getOutcomeValueBinding().getValue();
  +                  outcome = value==null ? null : value.toString();
  +               }
  +               
  +               Page.Case caze = outcome==null ?
  +                  //JSF navhandler says ignore all rules when null outcome
  +                  navigation.getDefaultCase() :
  +                  navigation.getCases().get(outcome);
  +               if (caze!=null)
  +               {
  +                  //TODO: begin/end conversation, etc!!
  +                  caze.getResult().navigate(context);
  +                  return true;
  +               }
  +               
  +            }
  +            
  +         }
  +      }
  +      return false;
      }
      
      /**
  @@ -363,7 +488,10 @@
            }
         }
         
  +      if (outcome!=null)
  +      {
         handleOutcome(facesContext, outcome, fromAction);
  +      }
         
         return result;
   
  @@ -376,11 +504,11 @@
   
      private static void handleOutcome(FacesContext facesContext, String outcome, String fromAction)
      {
  -      if (outcome!=null)
  -      {
  +      /*if (outcome!=null)
  +      {*/
            facesContext.getApplication().getNavigationHandler()
                  .handleNavigation(facesContext, fromAction, outcome);
  -      }
  +      //}
      }
      
      public static Pages instance()
  @@ -419,10 +547,13 @@
               MethodBinding actionBinding = Expressions.instance().createMethodBinding(expression);
               outcome = toString( actionBinding.invoke() );
               fromAction = expression;
  +            handleOutcome(facesContext, outcome, fromAction);
            }
         }
  -      
  +      else
  +      {
         handleOutcome(facesContext, outcome, fromAction);
  +      }
         
         return result;
      }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 19:25:14 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 19:25:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf  ...
Message-ID: <E1Gvjq6-0002qD-Jw@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 19:25:14

  Modified:    src/main/org/jboss/seam/jsf  SeamNavigationHandler.java
  Log:
  JBSEAM-605, navigation in pages.xml
  make s:link action trigger navigation even if outcome is null (but not page actions)
  
  Revision  Changes    Path
  1.17      +8 -3      jboss-seam/src/main/org/jboss/seam/jsf/SeamNavigationHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamNavigationHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamNavigationHandler.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- SeamNavigationHandler.java	31 Oct 2006 20:09:22 -0000	1.16
  +++ SeamNavigationHandler.java	17 Dec 2006 00:25:14 -0000	1.17
  @@ -6,6 +6,7 @@
   import org.jboss.seam.core.Init;
   import org.jboss.seam.core.Manager;
   import org.jboss.seam.core.Pageflow;
  +import org.jboss.seam.core.Pages;
   
   public class SeamNavigationHandler extends NavigationHandler {
      
  @@ -20,8 +21,7 @@
      public void handleNavigation(FacesContext context, String fromAction, String outcome) {
         if ( !context.getResponseComplete() ) //workaround for a bug in MyFaces
         {
  -         boolean outcomeIsViewId = outcome!=null && outcome.startsWith("/");
  -         if ( outcomeIsViewId )
  +         if ( isOutcomeViewId(outcome) )
            {
               Manager.instance().interpolateAndRedirect(outcome);
            }
  @@ -29,11 +29,16 @@
            {
               Pageflow.instance().navigate(context, outcome);
            }
  -         else
  +         else if ( !Pages.instance().navigate(context, fromAction, outcome) )
            {
               baseNavigationHandler.handleNavigation(context, fromAction, outcome);
            }
         }
      }
   
  +   private static boolean isOutcomeViewId(String outcome)
  +   {
  +      return outcome!=null && outcome.startsWith("/");
  +   }
  +
   }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 19:25:55 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 19:25:55 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gvjql-0002rG-PB@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 19:25:55

  Added:       src/main/org/jboss/seam/core  Navigator.java
  Log:
  JBSEAM-605, navigation in pages.xml
  make s:link action trigger navigation even if outcome is null (but not page actions)
  
  Revision  Changes    Path
  1.1      date: 2006/12/17 00:25:55;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/Navigator.java
  
  Index: Navigator.java
  ===================================================================
  package org.jboss.seam.core;
  
  import javax.faces.component.UIViewRoot;
  import javax.faces.context.FacesContext;
  
  import org.jboss.seam.log.LogProvider;
  import org.jboss.seam.log.Logging;
  import org.jboss.seam.util.Strings;
  
  abstract class Navigator
  {
     private static final LogProvider log = Logging.getLogProvider(Navigator.class);
  
     /**
      * Send an error.
      */
     protected static void error(int code, String message)
     {
        if ( log.isDebugEnabled() ) log.debug("sending error: " + code);
        org.jboss.seam.core.HttpError httpError = org.jboss.seam.core.HttpError.instance();
        if (message==null)
        {
           httpError.send(code);
        }
        else
        {
           httpError.send(code, message);
        }
     }
  
     /**
      * Redirect to the view id.
      */
     protected static void redirect(String viewId)
     {
        if ( Strings.isEmpty(viewId) )
        {
           viewId = FacesContext.getCurrentInstance().getViewRoot().getViewId();
        }
        if ( log.isDebugEnabled() ) log.debug("redirecting to: " + viewId);
        Manager.instance().redirect(viewId);
     }
     
     /**
      * Render the view id.
      */
     protected static void render(String viewId)
     {
        FacesContext facesContext = FacesContext.getCurrentInstance();
        if ( !Strings.isEmpty(viewId) )
        {
           UIViewRoot viewRoot = facesContext.getApplication().getViewHandler()
                 .createView(facesContext, viewId);
           facesContext.setViewRoot(viewRoot);
        }
        else
        {
           viewId = facesContext.getViewRoot().getViewId(); //just for the log message
        }
        if ( log.isDebugEnabled() ) log.debug("rendering: " + viewId);
        facesContext.renderResponse();
     }
  
  
  }
  
  
  


From gavin.king at jboss.com  Sat Dec 16 20:04:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 20:04:51 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF   ...
Message-ID: <E1GvkSR-0003Zo-1L@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 20:04:51

  Modified:    examples/booking/resources/WEB-INF   pages.xml web.xml
  Log:
  reworked the booking example to take advantage of ochestration from pages.xml
  
  Revision  Changes    Path
  1.7       +104 -5    jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- pages.xml	16 Dec 2006 14:38:42 -0000	1.6
  +++ pages.xml	17 Dec 2006 01:04:51 -0000	1.7
  @@ -3,7 +3,106 @@
     "http://jboss.com/products/seam/pages-1.1.dtd">
   
   <pages no-conversation-view-id="/main.xhtml">
  -	<page view-id="/hotel.xhtml" conversation-required="true">View hotel: #{hotel.name}</page>
  -	<page view-id="/book.xhtml" conversation-required="true">Book hotel: #{hotel.name}</page>
  -	<page view-id="/confirm.xhtml" conversation-required="true">Confirm: #{booking.description}</page>
  +
  +	<page view-id="/hotel.xhtml" 
  +          conversation-required="true">
  +          
  +        <description>View hotel: #{hotel.name}</description>
  +        
  +        <navigation action="#{hotelBooking.bookHotel}">
  +            <default>
  +                <redirect view-id="/book.xhtml"/>
  +            </default>
  +        </navigation>
  +        
  +    </page>
  +
  +	<page view-id="/book.xhtml" 
  +          conversation-required="true">
  +          
  +        <description>Book hotel: #{hotel.name}</description>
  +        
  +        <navigation outcome="#{hotelBooking.bookingValid}">
  +            <case outcome="true">
  +                <redirect view-id="/confirm.xhtml"/>
  +            </case>
  +        </navigation>
  +        
  +    </page>
  +
  +	<page view-id="/confirm.xhtml" 
  +          conversation-required="true">
  +          
  +        <description>Confirm booking: #{booking.description}</description>
  +        
  +        <navigation action="#{hotelBooking.confirm}">
  +            <default>
  +                <redirect view-id="/main.xhtml"/>
  +            </default>
  +        </navigation>
  +        
  +    </page>
  +    
  +    <page view-id="/password.xhtml">
  +        
  +        <navigation outcome="#{changePassword.changed}">
  +            <case outcome="true">
  +                <redirect view-id="/main.xhtml"/>
  +            </case>
  +        </navigation>
  +        
  +    </page>
  +
  +    <page view-id="/register.xhtml">
  +        
  +        <navigation outcome="#{register.registered}">
  +            <case outcome="true">
  +                <redirect view-id="/home.xhtml"/>
  +            </case>
  +        </navigation>
  +        
  +    </page>
  +
  +    <page view-id="/home.xhtml">
  +        
  +        <navigation outcome="#{loggedIn==null}">
  +            <case outcome="false">
  +                <redirect view-id="/main.xhtml"/>
  +            </case>
  +        </navigation>
  +        
  +    </page>
  +    
  +    <page view-id="/main.xhtml">
  +        
  +        <navigation action="#{hotelBooking.selectHotel(hot)}">
  +            <default>
  +                <redirect view-id="/hotel.xhtml"/>
  +            </default>
  +        </navigation>
  +
  +    </page>
  +
  +    <page view-id="*">
  +    
  +        <navigation action="#{logout.logout}">
  +            <default>
  +                <redirect view-id="/home.xhtml"/>
  +            </default>
  +        </navigation>
  +
  +        <navigation action="#{hotelBooking.cancel}">
  +            <default>
  +                <redirect view-id="/main.xhtml"/>
  +            </default>
  +        </navigation>
  +
  +        <navigation>
  +            <case outcome="login">
  +                <redirect view-id="/home.xhtml"/>
  +            </case>
  +        </navigation>
  +        
  +    </page>
  +
   </pages>
  \ No newline at end of file
  
  
  
  1.36      +0 -5      jboss-seam/examples/booking/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/web.xml,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -b -r1.35 -r1.36
  --- web.xml	6 Dec 2006 05:18:31 -0000	1.35
  +++ web.xml	17 Dec 2006 01:04:51 -0000	1.36
  @@ -8,11 +8,6 @@
           <session-timeout>3</session-timeout>
       </session-config>
   
  -    <context-param>
  -        <param-name>javax.faces.CONFIG_FILES</param-name>
  -        <param-value>/WEB-INF/navigation.xml</param-value>
  -    </context-param>
  -
       <!-- Ajax4jsf (must come first!) -->
           
       <filter>
  
  
  


From gavin.king at jboss.com  Sat Dec 16 20:04:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 20:04:51 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test
	...
Message-ID: <E1GvkSR-0003al-CN@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 20:04:51

  Modified:    examples/booking/src/org/jboss/seam/example/booking/test  
                        BookingTest.java BookingUnitTest.java
  Log:
  reworked the booking example to take advantage of ochestration from pages.xml
  
  Revision  Changes    Path
  1.41      +3 -3      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java,v
  retrieving revision 1.40
  retrieving revision 1.41
  diff -u -b -r1.40 -r1.41
  --- BookingTest.java	17 Nov 2006 01:38:03 -0000	1.40
  +++ BookingTest.java	17 Dec 2006 01:04:51 -0000	1.41
  @@ -1,4 +1,4 @@
  -//$Id: BookingTest.java,v 1.40 2006/11/17 01:38:03 gavin Exp $
  +//$Id: BookingTest.java,v 1.41 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import java.util.Calendar;
  @@ -71,8 +71,8 @@
               HotelBooking hotelBooking = (HotelBooking) getInstance("hotelBooking");
               DataModel hotels = (DataModel) Contexts.getSessionContext().get("hotels");
               assert hotels.getRowCount()==1;
  -            String outcome = hotelBooking.selectHotel( (Hotel) hotels.getRowData() );
  -            assert "hotel".equals(outcome);
  +            hotelBooking.selectHotel( (Hotel) hotels.getRowData() );
  +            //assert "hotel".equals(outcome);
               Hotel hotel = (Hotel) Contexts.getConversationContext().get("hotel");
               assert hotel.getCity().equals("NY");
               assert hotel.getZip().equals("10011");
  
  
  
  1.13      +4 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingUnitTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- BookingUnitTest.java	16 Dec 2006 02:16:49 -0000	1.12
  +++ BookingUnitTest.java	17 Dec 2006 01:04:51 -0000	1.13
  @@ -60,11 +60,11 @@
         setField(hb, "events", new Events() { @Override public void raiseEvent(String type, Object... params) { assert "bookingConfirmed".equals(type); } } );
         setField(hb, "log", Logging.getLog(HotelBookingAction.class));
         
  -      assert hb.selectHotel(hotel).equals("hotel");
  +      hb.selectHotel(hotel);
   
         User user = em.getReference(User.class, "gavin");
         assert user!=null;
  -      assert hb.bookHotel().equals("book");
  +      hb.bookHotel();
         
         Booking booking = (Booking) getField(hb, "booking");
         assert booking!=null;
  @@ -74,10 +74,10 @@
         booking.setCreditCard("1234123412341234");
         booking.setCreditCardName("GAVIN A KING");
         
  -      assert hb.setBookingDetails().equals("confirm");
  +      hb.setBookingDetails();
   
         getUserTransaction().begin();
  -      assert hb.confirm().equals("confirmed");
  +      hb.confirm();
         getUserTransaction().commit();
         
         em.close();
  
  
  


From gavin.king at jboss.com  Sat Dec 16 20:04:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 20:04:51 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1GvkSR-0003ab-8v@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 20:04:51

  Modified:    examples/booking/src/org/jboss/seam/example/booking               
                        BookingList.java BookingListAction.java
                        ChangePassword.java ChangePasswordAction.java
                        HotelBooking.java HotelBookingAction.java
                        HotelSearching.java HotelSearchingAction.java
                        LoggedInInterceptor.java Login.java
                        LoginAction.java Logout.java LogoutAction.java
                        Register.java RegisterAction.java
  Log:
  reworked the booking example to take advantage of ochestration from pages.xml
  
  Revision  Changes    Path
  1.5       +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingList.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- BookingList.java	14 Dec 2006 10:40:09 -0000	1.4
  +++ BookingList.java	17 Dec 2006 01:04:51 -0000	1.5
  @@ -1,4 +1,4 @@
  -//$Id: BookingList.java,v 1.4 2006/12/14 10:40:09 gavin Exp $
  +//$Id: BookingList.java,v 1.5 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -8,6 +8,6 @@
   {
      public void getBookings();
      public Booking getBooking();
  -   public String cancel();
  +   public void cancel();
      public void destroy();
   }
  \ No newline at end of file
  
  
  
  1.18      +2 -3      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingListAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingListAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/BookingListAction.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- BookingListAction.java	14 Dec 2006 10:40:09 -0000	1.17
  +++ BookingListAction.java	17 Dec 2006 01:04:51 -0000	1.18
  @@ -1,4 +1,4 @@
  -//$Id: BookingListAction.java,v 1.17 2006/12/14 10:40:09 gavin Exp $
  +//$Id: BookingListAction.java,v 1.18 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static javax.ejb.TransactionAttributeType.REQUIRES_NEW;
  @@ -56,14 +56,13 @@
               .getResultList();
      }
      
  -   public String cancel()
  +   public void cancel()
      {
         log.info("Cancel booking: #{bookingList.booking.id} for #{user.username}");
         Booking cancelled = em.find(Booking.class, booking.getId());
         if (cancelled!=null) em.remove( cancelled );
         getBookings();
         FacesMessages.instance().add("Booking cancelled for confirmation number #{bookingList.booking.id}");
  -      return "main";
      }
      
      public Booking getBooking()
  
  
  
  1.3       +3 -3      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/ChangePassword.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChangePassword.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/ChangePassword.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ChangePassword.java	10 Sep 2005 16:23:35 -0000	1.2
  +++ ChangePassword.java	17 Dec 2006 01:04:51 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: ChangePassword.java,v 1.2 2005/09/10 16:23:35 gavin Exp $
  +//$Id: ChangePassword.java,v 1.3 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -6,8 +6,8 @@
   @Local
   public interface ChangePassword
   {
  -   public String changePassword();
  -   public String cancel();
  +   public void changePassword();
  +   public boolean isChanged();
      
      public String getVerify();
      public void setVerify(String verify);
  
  
  
  1.16      +8 -8      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/ChangePasswordAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChangePasswordAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/ChangePasswordAction.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- ChangePasswordAction.java	27 Apr 2006 23:04:47 -0000	1.15
  +++ ChangePasswordAction.java	17 Dec 2006 01:04:51 -0000	1.16
  @@ -1,4 +1,4 @@
  -//$Id: ChangePasswordAction.java,v 1.15 2006/04/27 23:04:47 gavin Exp $
  +//$Id: ChangePasswordAction.java,v 1.16 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static org.jboss.seam.ScopeType.EVENT;
  @@ -30,27 +30,27 @@
      
      private String verify;
      
  -   public String changePassword()
  +   private boolean changed;
  +   
  +   public void changePassword()
      {
         if ( user.getPassword().equals(verify) )
         {
            user = em.merge(user);
            FacesMessages.instance().add("Password updated");
  -         return "main";
  +         changed = true;
         }
         else 
         {
            FacesMessages.instance().add("verify", "Re-enter new password");
            revertUser();
            verify=null;
  -         return null;
         }
      }
      
  -   public String cancel()
  +   public boolean isChanged()
      {
  -      revertUser();
  -      return "main";
  +      return changed;
      }
   
      private void revertUser()
  
  
  
  1.12      +8 -6      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBooking.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelBooking.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBooking.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- HotelBooking.java	28 Sep 2006 01:16:05 -0000	1.11
  +++ HotelBooking.java	17 Dec 2006 01:04:51 -0000	1.12
  @@ -1,4 +1,4 @@
  -//$Id: HotelBooking.java,v 1.11 2006/09/28 01:16:05 gavin Exp $
  +//$Id: HotelBooking.java,v 1.12 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -6,14 +6,16 @@
   @Local
   public interface HotelBooking
   {
  -   public String selectHotel(Hotel selectedHotel);
  +   public void selectHotel(Hotel selectedHotel);
      
  -   public String bookHotel();
  +   public void bookHotel();
      
  -   public String setBookingDetails();
  +   public void setBookingDetails();
  +   public boolean isBookingValid();
      
  -   public String confirm();
  -   public String cancel();
  +   public void confirm();
  +   
  +   public void cancel();
      
      public void destroy();
      
  
  
  
  1.43      +14 -19    jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelBookingAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- HotelBookingAction.java	16 Dec 2006 04:34:58 -0000	1.42
  +++ HotelBookingAction.java	17 Dec 2006 01:04:51 -0000	1.43
  @@ -1,4 +1,4 @@
  -//$Id: HotelBookingAction.java,v 1.42 2006/12/16 04:34:58 gavin Exp $
  +//$Id: HotelBookingAction.java,v 1.43 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static javax.persistence.PersistenceContextType.EXTENDED;
  @@ -49,62 +49,57 @@
      @Logger 
      private Log log;
      
  +   private boolean bookingValid;
  +   
      @Begin
  -   public String selectHotel(Hotel selectedHotel)
  +   public void selectHotel(Hotel selectedHotel)
      {
         hotel = em.merge(selectedHotel);
  -      return "hotel";
      }
      
  -   public String bookHotel()
  +   public void bookHotel()
      {      
         booking = new Booking(hotel, user);
         Calendar calendar = Calendar.getInstance();
         booking.setCheckinDate( calendar.getTime() );
         calendar.add(Calendar.DAY_OF_MONTH, 1);
         booking.setCheckoutDate( calendar.getTime() );
  -      
  -      return "book";
      }
   
  -   public String setBookingDetails()
  +   public void setBookingDetails()
      {
  -      if (booking==null || hotel==null) return "main";
  -      
         Calendar calendar = Calendar.getInstance();
         calendar.add(Calendar.DAY_OF_MONTH, -1);
         if ( booking.getCheckinDate().before( calendar.getTime() ) )
         {
            facesMessages.add("Check in date must be a future date");
  -         return null;
         }
         else if ( !booking.getCheckinDate().before( booking.getCheckoutDate() ) )
         {
            facesMessages.add("Check out date must be later than check in date");
  -         return null;
         }
         else
         {
  -         return "confirm";
  +         bookingValid=true;
  +      }
         }
  +
  +   public boolean isBookingValid()
  +   {
  +      return bookingValid;
      }
   
      @End
  -   public String confirm()
  +   public void confirm()
      {
  -      if (booking==null || hotel==null) return "main";
         em.persist(booking);
         facesMessages.add("Thank you, #{user.name}, your confimation number for #{hotel.name} is #{booking.id}");
         log.info("New booking: #{booking.id} for #{user.username}");
         events.raiseTransactionSuccessEvent("bookingConfirmed");
  -      return "confirmed";
      }
      
      @End
  -   public String cancel()
  -   {
  -      return "main";
  -   }
  +   public void cancel() {}
      
      @Destroy @Remove
      public void destroy() {}
  
  
  
  1.9       +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelSearching.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelSearching.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelSearching.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- HotelSearching.java	10 Nov 2006 22:53:20 -0000	1.8
  +++ HotelSearching.java	17 Dec 2006 01:04:51 -0000	1.9
  @@ -1,4 +1,4 @@
  -//$Id: HotelSearching.java,v 1.8 2006/11/10 22:53:20 gavin Exp $
  +//$Id: HotelSearching.java,v 1.9 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -13,7 +13,7 @@
      public void setSearchString(String searchString);
      
      public void find();
  -   public String nextPage();
  +   public void nextPage();
      public boolean isNextPageAvailable();
   
      public void destroy();
  
  
  
  1.15      +2 -3      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelSearchingAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelSearchingAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelSearchingAction.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- HotelSearchingAction.java	10 Nov 2006 22:53:20 -0000	1.14
  +++ HotelSearchingAction.java	17 Dec 2006 01:04:51 -0000	1.15
  @@ -1,4 +1,4 @@
  -//$Id: HotelSearchingAction.java,v 1.14 2006/11/10 22:53:20 gavin Exp $
  +//$Id: HotelSearchingAction.java,v 1.15 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.util.List;
  @@ -37,11 +37,10 @@
         queryHotels();
      }
   
  -   public String nextPage()
  +   public void nextPage()
      {
         page++;
         queryHotels();
  -      return "main";
      }
         
      private void queryHotels()
  
  
  
  1.13      +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoggedInInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- LoggedInInterceptor.java	26 Jul 2006 23:19:55 -0000	1.12
  +++ LoggedInInterceptor.java	17 Dec 2006 01:04:51 -0000	1.13
  @@ -1,11 +1,11 @@
  -//$Id: LoggedInInterceptor.java,v 1.12 2006/07/26 23:19:55 gavin Exp $
  +//$Id: LoggedInInterceptor.java,v 1.13 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.lang.reflect.Method;
   
  +import javax.faces.event.PhaseId;
   import javax.interceptor.AroundInvoke;
   import javax.interceptor.InvocationContext;
  -import javax.faces.event.PhaseId;
   
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.contexts.Contexts;
  
  
  
  1.2       +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Login.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Login.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Login.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Login.java	19 Aug 2005 03:33:15 -0000	1.1
  +++ Login.java	17 Dec 2006 01:04:51 -0000	1.2
  @@ -1,4 +1,4 @@
  -//$Id: Login.java,v 1.1 2005/08/19 03:33:15 gavin Exp $
  +//$Id: Login.java,v 1.2 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -6,5 +6,5 @@
   @Local
   public interface Login
   {
  -   public String login();
  +   public void login();
   }
  
  
  
  1.17      +2 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoginAction.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- LoginAction.java	12 Oct 2006 02:49:35 -0000	1.16
  +++ LoginAction.java	17 Dec 2006 01:04:51 -0000	1.17
  @@ -1,4 +1,4 @@
  -//$Id: LoginAction.java,v 1.16 2006/10/12 02:49:35 gavin Exp $
  +//$Id: LoginAction.java,v 1.17 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.util.List;
  @@ -24,7 +24,7 @@
      @PersistenceContext
      private EntityManager em;
   
  -   public String login()
  +   public void login()
      {
         List<User> results = em.createQuery("select u from User u where u.username=:username and u.password=:password")
               .setParameter("username", user.getUsername())
  @@ -34,14 +34,12 @@
         if ( results.size()==0 )
         {
            FacesMessages.instance().add("Invalid login");
  -         return "login";
         }
         else
         {
            user = results.get(0);
            Contexts.getSessionContext().set("loggedIn", true);
            FacesMessages.instance().add("Welcome, #{user.name}");
  -         return "main";
         }
         
      }
  
  
  
  1.2       +2 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Logout.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Logout.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Logout.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Logout.java	21 Aug 2005 01:13:29 -0000	1.1
  +++ Logout.java	17 Dec 2006 01:04:51 -0000	1.2
  @@ -1,4 +1,4 @@
  -//$Id: Logout.java,v 1.1 2005/08/21 01:13:29 gavin Exp $
  +//$Id: Logout.java,v 1.2 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -6,5 +6,5 @@
   @Local
   public interface Logout
   {
  -   public String logout();
  +   public void logout();
   }
  \ No newline at end of file
  
  
  
  1.8       +2 -3      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LogoutAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LogoutAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LogoutAction.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- LogoutAction.java	15 Apr 2006 23:06:46 -0000	1.7
  +++ LogoutAction.java	17 Dec 2006 01:04:51 -0000	1.8
  @@ -1,4 +1,4 @@
  -//$Id: LogoutAction.java,v 1.7 2006/04/15 23:06:46 gavin Exp $
  +//$Id: LogoutAction.java,v 1.8 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Stateless;
  @@ -11,9 +11,8 @@
   @Name("logout")
   public class LogoutAction implements Logout
   {
  -   public String logout()
  +   public void logout()
      {
         Seam.invalidateSession();
  -      return "login";
      }
   }
  
  
  
  1.2       +3 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Register.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Register.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Register.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Register.java	23 Aug 2005 09:17:39 -0000	1.1
  +++ Register.java	17 Dec 2006 01:04:51 -0000	1.2
  @@ -1,4 +1,4 @@
  -//$Id: Register.java,v 1.1 2005/08/23 09:17:39 gavin Exp $
  +//$Id: Register.java,v 1.2 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -6,9 +6,10 @@
   @Local
   public interface Register
   {
  -   public String register();
  +   public void register();
      public String getVerify();
      public void setVerify(String verify);
  +   public boolean isRegistered();
      
      public void destroy();
   }
  \ No newline at end of file
  
  
  
  1.16      +10 -5     jboss-seam/examples/booking/src/org/jboss/seam/example/booking/RegisterAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegisterAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/RegisterAction.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- RegisterAction.java	17 Nov 2006 02:49:04 -0000	1.15
  +++ RegisterAction.java	17 Dec 2006 01:04:51 -0000	1.16
  @@ -1,4 +1,4 @@
  -//$Id: RegisterAction.java,v 1.15 2006/11/17 02:49:04 gavin Exp $
  +//$Id: RegisterAction.java,v 1.16 2006/12/17 01:04:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static org.jboss.seam.ScopeType.EVENT;
  @@ -33,7 +33,9 @@
      
      private String verify;
      
  -   public String register()
  +   private boolean registered;
  +   
  +   public void register()
      {
         if ( user.getPassword().equals(verify) )
         {
  @@ -44,22 +46,25 @@
            {
               em.persist(user);
               facesMessages.add("Successfully registered as #{user.username}");
  -            return "login";
  +            registered = true;
            }
            else
            {
               facesMessages.add("Username #{user.username} already exists");
  -            return null;
            }
         }
         else 
         {
            facesMessages.add("verify", "Re-enter your password");
            verify=null;
  -         return null;
         }
      }
   
  +   public boolean isRegistered()
  +   {
  +      return registered;
  +   }
  +
      public String getVerify()
      {
         return verify;
  
  
  


From gavin.king at jboss.com  Sat Dec 16 20:04:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 20:04:51 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view     ...
Message-ID: <E1GvkSR-0003b1-H7@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 20:04:51

  Modified:    examples/booking/view     confirm.xhtml home.xhtml
                        password.xhtml template.xhtml
  Log:
  reworked the booking example to take advantage of ochestration from pages.xml
  
  Revision  Changes    Path
  1.18      +1 -1      jboss-seam/examples/booking/view/confirm.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: confirm.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/confirm.xhtml,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- confirm.xhtml	15 Dec 2006 13:26:33 -0000	1.17
  +++ confirm.xhtml	17 Dec 2006 01:04:51 -0000	1.18
  @@ -59,7 +59,7 @@
   			<div class="label">&#160;</div>
   			<div class="input">
   				<h:commandButton id="confirm" value="Confirm" action="#{hotelBooking.confirm}"/>&#160;
  -    			<h:commandButton id="revise" value="Revise" action="back"/>&#160;
  +    			<s:button id="revise" value="Revise" view="/book.xhtml"/>&#160;
       			<h:commandButton id="cancel" value="Cancel" action="#{hotelBooking.cancel}"/>
   			</div>
   		</div>
  
  
  
  1.12      +3 -2      jboss-seam/examples/booking/view/home.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: home.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/home.xhtml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- home.xhtml	14 Nov 2006 05:50:59 -0000	1.11
  +++ home.xhtml	17 Dec 2006 01:04:51 -0000	1.12
  @@ -2,7 +2,8 @@
   <html xmlns="http://www.w3.org/1999/xhtml"
   	  xmlns:ui="http://java.sun.com/jsf/facelets"
   	  xmlns:h="http://java.sun.com/jsf/html"
  -	  xmlns:f="http://java.sun.com/jsf/core">
  +	  xmlns:f="http://java.sun.com/jsf/core"
  +      xmlns:s="http://jboss.com/products/seam/taglib">
   <head>
   	<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
   	<title>JBoss Suites: Seam Framework</title>
  @@ -29,7 +30,7 @@
   				</div>
   				<div class="errors"><h:messages globalOnly="true"/></div>
   				<div class="buttonBox"><h:commandButton id="login" action="#{login.login}" value="Account Login"/></div>
  -				<div class="notes"><h:commandLink id="register" action="register">Register New User</h:commandLink></div>
  +				<div class="notes"><s:link id="register" view="/register.xhtml" value="Register New User"/></div>
   			</fieldset>
               </h:form>
   		</div>
  
  
  
  1.11      +1 -1      jboss-seam/examples/booking/view/password.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: password.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/password.xhtml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- password.xhtml	14 Nov 2006 05:50:59 -0000	1.10
  +++ password.xhtml	17 Dec 2006 01:04:51 -0000	1.11
  @@ -53,7 +53,7 @@
   				<div class="label">&#160;</div>
   				<div class="input">
   					<h:commandButton id="change" value="Change" action="#{changePassword.changePassword}"/>&#160;
  -					<s:button id="cancel" value="Cancel" action="#{changePassword.cancel}"/>
  +					<s:button id="cancel" value="Cancel" view="/main.xhtml"/>
   				</div>
   			</div>
   			
  
  
  
  1.10      +6 -7      jboss-seam/examples/booking/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/template.xhtml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- template.xhtml	8 Dec 2006 00:38:15 -0000	1.9
  +++ template.xhtml	17 Dec 2006 01:04:51 -0000	1.10
  @@ -1,7 +1,8 @@
   <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
   <html xmlns="http://www.w3.org/1999/xhtml"
         xmlns:ui="http://java.sun.com/jsf/facelets"
  -      xmlns:h="http://java.sun.com/jsf/html">
  +      xmlns:h="http://java.sun.com/jsf/html"
  +      xmlns:s="http://jboss.com/products/seam/taglib">
   <head>
   	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
   	<title>JBoss Suites: Seam Framework</title>
  @@ -14,12 +15,10 @@
   	<div id="header">
   		<div id="title"><img src="img/hdr.title.gif" alt="JBoss Suites: seam framework demo"/></div>
   		<div id="status">
  -		    <h:form id="navigation">
   		    	Welcome #{user.name}
  -			    | <h:outputLink id="main" value="main.seam">Search</h:outputLink>
  -			    | <h:outputLink id="password" value="password.seam">Settings</h:outputLink>
  -			    | <h:commandLink id="logout" action="#{logout.logout}">Logout</h:commandLink>
  -		    </h:form>
  +            | <s:link id="search" view="/main.xhtml" value="Search" propagation="none"/>
  +            | <s:link id="settings" view="/password.xhtml" value="Settings" propagation="none"/>
  +            | <s:link id="logout" action="#{logout.logout}" value="Logout"/>
   		</div>
   	</div>
   	<div id="container">
  
  
  


From gavin.king at jboss.com  Sat Dec 16 20:07:25 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 20:07:25 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GvkUv-0003gD-1x@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 20:07:25

  Removed:     examples/booking/resources/WEB-INF  navigation.xml
  Log:
  reworked the booking example to take advantage of ochestration from pages.xml


From gavin.king at jboss.com  Sat Dec 16 20:26:02 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 20:26:02 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test
	...
Message-ID: <E1Gvkmw-0003yO-W5@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 20:26:02

  Modified:    examples/booking/src/org/jboss/seam/example/booking/test    
                        BookingTest.java BookingUnitTest.java
                        ChangePasswordTest.java LoginTest.java
  Log:
  fix tests
  
  Revision  Changes    Path
  1.42      +14 -17    jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java,v
  retrieving revision 1.41
  retrieving revision 1.42
  diff -u -b -r1.41 -r1.42
  --- BookingTest.java	17 Dec 2006 01:04:51 -0000	1.41
  +++ BookingTest.java	17 Dec 2006 01:26:02 -0000	1.42
  @@ -1,4 +1,4 @@
  -//$Id: BookingTest.java,v 1.41 2006/12/17 01:04:51 gavin Exp $
  +//$Id: BookingTest.java,v 1.42 2006/12/17 01:26:02 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import java.util.Calendar;
  @@ -63,16 +63,19 @@
            
         }.run();
         
  -      String id = new NonFacesRequest("/hotel.xhtml") {
  +      String id = new FacesRequest("/hotel.xhtml") {
   
            @Override
  -         protected void renderResponse()
  -         {
  +         protected void invokeApplication() throws Exception {
               HotelBooking hotelBooking = (HotelBooking) getInstance("hotelBooking");
               DataModel hotels = (DataModel) Contexts.getSessionContext().get("hotels");
               assert hotels.getRowCount()==1;
               hotelBooking.selectHotel( (Hotel) hotels.getRowData() );
  -            //assert "hotel".equals(outcome);
  +         }
  +
  +         @Override
  +         protected void renderResponse()
  +         {
               Hotel hotel = (Hotel) Contexts.getConversationContext().get("hotel");
               assert hotel.getCity().equals("NY");
               assert hotel.getZip().equals("10011");
  @@ -86,7 +89,7 @@
            @Override
            protected void invokeApplication()
            {
  -            assert invokeMethod("#{hotelBooking.bookHotel}").equals("book");
  +            invokeMethod("#{hotelBooking.bookHotel}");
            }
   
            @Override
  @@ -191,7 +194,7 @@
            @Override
            protected void invokeApplication()
            {
  -            assert invokeMethod("#{hotelBooking.setBookingDetails}").equals("confirm");
  +            invokeMethod("#{hotelBooking.setBookingDetails}");
            }
   
            @Override
  @@ -207,18 +210,12 @@
            @Override
            protected void invokeApplication()
            {
  -            assert invokeMethod("#{hotelBooking.confirm}").equals("confirmed");
  -         }
  -
  -         @Override
  -         protected void renderResponse()
  -         {
  -            assert !Manager.instance().isLongRunningConversation();
  +            invokeMethod("#{hotelBooking.confirm}");
            }
            
         }.run();
         
  -      new NonFacesRequest("/confirmed.xhtml") {
  +      new NonFacesRequest("/main.xhtml") {
   
            @Override
            protected void renderResponse()
  @@ -241,7 +238,7 @@
            {
               ListDataModel bookings = (ListDataModel) Contexts.getSessionContext().get("bookings");
               bookings.setRowIndex(0);
  -            assert invokeMethod("#{bookingList.cancel}").equals("main");
  +            invokeMethod("#{bookingList.cancel}");
            }
   
            @Override
  
  
  
  1.14      +1 -1      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingUnitTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- BookingUnitTest.java	17 Dec 2006 01:04:51 -0000	1.13
  +++ BookingUnitTest.java	17 Dec 2006 01:26:02 -0000	1.14
  @@ -57,7 +57,7 @@
         //setField(hb, "hotelSearch", hs);
         setField(hb, "user", em.getReference(User.class, "gavin"));
         setField(hb, "facesMessages", new FacesMessages());
  -      setField(hb, "events", new Events() { @Override public void raiseEvent(String type, Object... params) { assert "bookingConfirmed".equals(type); } } );
  +      setField(hb, "events", new Events() { @Override public void raiseTransactionSuccessEvent(String type, Object... params) { assert "bookingConfirmed".equals(type); } } );
         setField(hb, "log", Logging.getLog(HotelBookingAction.class));
         
         hb.selectHotel(hotel);
  
  
  
  1.14      +3 -3      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/ChangePasswordTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChangePasswordTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/ChangePasswordTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ChangePasswordTest.java	26 Oct 2006 21:10:41 -0000	1.13
  +++ ChangePasswordTest.java	17 Dec 2006 01:26:02 -0000	1.14
  @@ -1,4 +1,4 @@
  -//$Id: ChangePasswordTest.java,v 1.13 2006/10/26 21:10:41 gavin Exp $
  +//$Id: ChangePasswordTest.java,v 1.14 2006/12/17 01:26:02 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import org.jboss.seam.contexts.Contexts;
  @@ -86,7 +86,7 @@
            @Override
            protected void invokeApplication()
            {
  -            assert invokeMethod("#{changePassword.changePassword}").equals("main");
  +            invokeMethod("#{changePassword.changePassword}");
            }
   
            @Override
  @@ -115,7 +115,7 @@
            @Override
            protected void invokeApplication()
            {
  -            assert invokeMethod("#{changePassword.changePassword}").equals("main");
  +            invokeMethod("#{changePassword.changePassword}");
            }
   
            @Override
  
  
  
  1.23      +4 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/LoginTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/LoginTest.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- LoginTest.java	17 Nov 2006 01:38:03 -0000	1.22
  +++ LoginTest.java	17 Dec 2006 01:26:02 -0000	1.23
  @@ -1,4 +1,4 @@
  -//$Id: LoginTest.java,v 1.22 2006/11/17 01:38:03 gavin Exp $
  +//$Id: LoginTest.java,v 1.23 2006/12/17 01:26:02 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import org.jboss.seam.Seam;
  @@ -20,7 +20,7 @@
            protected void invokeApplication()
            {
               assert !isSessionInvalid();
  -            assert invokeMethod("#{hotelBooking.bookHotel}").equals("login");
  +            invokeMethod("#{hotelBooking.bookHotel}");
            }
   
            @Override
  @@ -46,7 +46,7 @@
            @Override
            protected void invokeApplication()
            {
  -            assert invokeMethod("#{login.login}").equals("main");
  +            invokeMethod("#{login.login}");
            }
   
            @Override
  @@ -93,7 +93,7 @@
            {
               assert !Manager.instance().isLongRunningConversation();
               assert !isSessionInvalid();
  -            assert invokeMethod("#{logout.logout}").equals("login");
  +            invokeMethod("#{logout.logout}");
               assert Seam.isSessionInvalid();
            }
   
  
  
  


From norman.richards at jboss.com  Sat Dec 16 20:32:02 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sat, 16 Dec 2006 20:32:02 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen  ...
Message-ID: <E1Gvksk-000459-Nc@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/16 20:32:02

  Modified:    seam-gen  build.xml
  Log:
  JBSEAM-560: first pass at new-query
  
  Revision  Changes    Path
  1.56      +141 -87   jboss-seam/seam-gen/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
  retrieving revision 1.55
  retrieving revision 1.56
  diff -u -b -r1.55 -r1.56
  --- build.xml	16 Dec 2006 14:51:30 -0000	1.55
  +++ build.xml	17 Dec 2006 01:32:02 -0000	1.56
  @@ -114,6 +114,7 @@
               <filter token="testPackage" value="${test.package}"/>
               <filter token="listName" value="${component.name}List"/>
               <filter token="homeName" value="${component.name}Home"/>
  +            <filter token="query" value="${query.text}"/>
           </filterset>
       
       </target>
  @@ -412,6 +413,46 @@
   
       </target>
       
  +    <target name="query-input">
  +        <property name="entity.name.default" value="Entity" />
  +        <input addproperty="entity.name" 
  +               message="Enter the entity class to search for [${entity.name.default}] "
  +               defaultvalue="${entity.name}"/>
  +
  +        <property name="entity.file" value="${project.home}/src/${model.dir}/${entity.name}.java" />
  +        <available property="entity.present" file="${entity.file}" />
  +        <fail unless="entity.present">
  +            The entity ${entity.name} was not found.  It was expected to be in ${entity.file}.
  +        </fail>
  +
  +        
  +        <lowercaseProperty name="component.name.default" value="${entity.name}Query" />
  +        <input addproperty="component.name" 
  +               message="Enter the Seam query component name [${component.name.default}]"
  +               defaultvalue="${component.name.default}" />
  +        
  +        <uppercaseProperty name="bean.name.default" value="${component.name}"/>
  +        <input message="Enter the query class name [${bean.name.default}]" 
  +               addproperty="bean.name" 
  +               defaultvalue="${bean.name.default}"/>
  +        
  +        <property name="query.default"
  +                  value="select o from ${entity.name} o" />
  +        <input message="Enter the EJBQL query string [${query.default}]" 
  +               addproperty="query.text" 
  +               defaultvalue="${query.default}" />
  +
  +        <lowercaseProperty name="page.name.default" value="${component.name}"/>
  +        <input message="Enter the query resuls page name [${page.name.default}]" 
  +               addproperty="page.name" 
  +               defaultvalue="${page.name.default}"/>
  +        
  +        <property name="query.file" value="${project.home}/src/${action.dir}/${bean.name}.java"/>
  +        <property name="page.file" value="${project.home}/view/${page.name}.xhtml"/>
  +    </target>
  +
  +
  +
       <target name="copy-lib">
           <echo message="Copying project jars ..." />
   
  @@ -670,6 +711,19 @@
           <echo message="Type 'seam restart' and go to http://localhost:8080/${project.name}/${page.name}.seam"/>
       </target>
   
  +    <target name="new-query" depends="validate-project,query-input,setup-filters">
  +        <echo message="Creating a new query" />
  +        <copy file="src/Query.java" tofile="${query.file}">
  +            <filterset refid="filters"/>
  +        </copy>
  +
  +        <copy file="view/query.xhtml" tofile="${page.file}">
  +            <filterset refid="filters"/>
  +        </copy>
  +
  +        <echo message="Type 'seam restart' and go to http://localhost:8080/${project.name}/${page.name}.seam"/>
  +    </target>
  +
       <target name="new-conversation" depends="validate-project,action-input,setup-filters">
           <echo message="Creating a new stateful session bean component with @Begin and @End methods" />
           <copy file="src/ConversationBean.java" tofile="${bean.file}">
  
  
  


From norman.richards at jboss.com  Sat Dec 16 20:32:02 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sat, 16 Dec 2006 20:32:02 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/src  ...
Message-ID: <E1Gvksk-00045G-Rd@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/16 20:32:02

  Added:       seam-gen/src  Query.java
  Log:
  JBSEAM-560: first pass at new-query
  
  Revision  Changes    Path
  1.1      date: 2006/12/17 01:32:02;  author: nrichards;  state: Exp;jboss-seam/seam-gen/src/Query.java
  
  Index: Query.java
  ===================================================================
  package @actionPackage@;
  
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.RequestParameter;
  import org.jboss.seam.framework.EntityQuery;
  
  @Name("@componentName@")
  public class @beanName@ extends EntityQuery
  {
      @Override
      public String getEjbql() 
      { 
          return "@query@";
      }
  
      @RequestParameter
      @Override
      public void setFirstResult(Integer firstResult) {
          super.setFirstResult(firstResult);
      }
      
      @Override
      public Integer getMaxResults() {
          return 25;
      }
  }
  
  
  
  


From norman.richards at jboss.com  Sat Dec 16 20:32:02 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sat, 16 Dec 2006 20:32:02 -0500
Subject: [jboss-cvs] jboss-seam/seam-gen/view  ...
Message-ID: <E1Gvksk-00045N-W0@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/16 20:32:02

  Added:       seam-gen/view  query.xhtml
  Log:
  JBSEAM-560: first pass at new-query
  
  Revision  Changes    Path
  1.1      date: 2006/12/17 01:32:02;  author: nrichards;  state: Exp;jboss-seam/seam-gen/view/query.xhtml
  
  Index: query.xhtml
  ===================================================================
  <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
                               "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <ui:composition xmlns="http://www.w3.org/1999/xhtml"
                  xmlns:s="http://jboss.com/products/seam/taglib"
                  xmlns:ui="http://java.sun.com/jsf/facelets"
                  xmlns:f="http://java.sun.com/jsf/core"
                  xmlns:h="http://java.sun.com/jsf/html"
                  template="layout/template.xhtml">
                         
  <ui:define name="body">
  
      <h1>@beanName@ results</h1>
      <p>Generated query page</p>
      
      <h:messages globalOnly="true" styleClass="message"/>
      
      <h:outputText value="No results from search" 
              rendered="#{empty @componentName at .resultList}"/>
      <f:subview id="results" rendered="#{not empty @componentName at .resultList}">
          <h:dataTable id="@componentName@"
                       var="item"
                       value="#{@componentName at .resultList}">
              <h:column>
                  <f:facet name="header">Result</f:facet>
                  #{item}
              </h:column>
          </h:dataTable>
  
         <div class="tableControl">
              <s:link view="/@pageName at .xhtml"
                      rendered="#{@componentName at .previousExists}"
                      value="&lt;&lt; First Page"
                      id="firstPage">
                  <f:param name="firstResult" value="0"/>
              </s:link>
  
              <s:link view="/@pageName at .xhtml"
                      rendered="#{@componentName at .previousExists}"
                      value="&lt; Previous Page"
                      id="previousPage">
                  <f:param name="firstResult"
                           value="#{@componentName at .previousFirstResult}"/>
              </s:link>
  
              <s:link view="/@pageName at .xhtml"
                      rendered="#{@componentName at .nextExists}"
                      value="Next Page &gt;"
                      id="nextPage">
                  <f:param name="firstResult"
                           value="#{@componentName at .nextFirstResult}"/>
              </s:link>
  
              <s:link view="/@pageName at .xhtml"
                      rendered="#{@componentName at .nextExists}"
                      value="Last Page &gt;&gt;"
                      id="lastPage">
                  <f:param name="firstResult"
                           value="#{@componentName at .lastFirstResult}"/>
              </s:link>
         </div>
  
  
  
  
      </f:subview>
  </ui:define>
  
  </ui:composition>
  
  
  
  


From gavin.king at jboss.com  Sat Dec 16 21:39:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 21:39:17 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1Gvlvp-0005Eb-Fk@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 21:39:17

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  params for redirects JBSEAM-180, yay
  
  Revision  Changes    Path
  1.8       +1 -1      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- pages-1.1.dtd	17 Dec 2006 00:25:14 -0000	1.7
  +++ pages-1.1.dtd	17 Dec 2006 02:39:17 -0000	1.8
  @@ -44,7 +44,7 @@
   <!ELEMENT render EMPTY>
   <!ATTLIST render view-id CDATA #IMPLIED>
   
  -<!ELEMENT redirect EMPTY>
  +<!ELEMENT redirect (param*)>
   <!ATTLIST redirect view-id CDATA #IMPLIED>
   
   <!ELEMENT description (#PCDATA)>
  
  
  


From gavin.king at jboss.com  Sat Dec 16 21:39:17 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sat, 16 Dec 2006 21:39:17 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core    ...
Message-ID: <E1Gvlvp-0005Eo-Kv@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/16 21:39:17

  Modified:    src/main/org/jboss/seam/core    Exceptions.java
                        Navigator.java Pages.java
  Log:
  params for redirects JBSEAM-180, yay
  
  Revision  Changes    Path
  1.19      +1 -1      jboss-seam/src/main/org/jboss/seam/core/Exceptions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Exceptions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Exceptions.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- Exceptions.java	17 Dec 2006 00:25:14 -0000	1.18
  +++ Exceptions.java	17 Dec 2006 02:39:17 -0000	1.19
  @@ -235,7 +235,7 @@
            addFacesMessage( e, getMessage(e) );
            if ( isEnd(e) ) Conversation.instance().end();
            if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
  -         redirect( getViewId(e) );
  +         redirect( getViewId(e), null );
            return rethrow(e);
         }
   
  
  
  
  1.2       +4 -2      jboss-seam/src/main/org/jboss/seam/core/Navigator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Navigator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Navigator.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Navigator.java	17 Dec 2006 00:25:55 -0000	1.1
  +++ Navigator.java	17 Dec 2006 02:39:17 -0000	1.2
  @@ -1,5 +1,7 @@
   package org.jboss.seam.core;
   
  +import java.util.Map;
  +
   import javax.faces.component.UIViewRoot;
   import javax.faces.context.FacesContext;
   
  @@ -31,14 +33,14 @@
      /**
       * Redirect to the view id.
       */
  -   protected static void redirect(String viewId)
  +   protected static void redirect(String viewId, Map<String, Object> parameters)
      {
         if ( Strings.isEmpty(viewId) )
         {
            viewId = FacesContext.getCurrentInstance().getViewRoot().getViewId();
         }
         if ( log.isDebugEnabled() ) log.debug("redirecting to: " + viewId);
  -      Manager.instance().redirect(viewId);
  +      Manager.instance().redirect(viewId, parameters, true);
      }
      
      /**
  
  
  
  1.62      +54 -28    jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.61
  retrieving revision 1.62
  diff -u -b -r1.61 -r1.62
  --- Pages.java	17 Dec 2006 00:25:14 -0000	1.61
  +++ Pages.java	17 Dec 2006 02:39:17 -0000	1.62
  @@ -34,6 +34,7 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions.MethodBinding;
   import org.jboss.seam.core.Expressions.ValueBinding;
  +import org.jboss.seam.core.Page.PageParameter;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.DTDEntityResolver;
  @@ -288,11 +289,22 @@
         Element redirect = element.element("redirect");
         if (redirect!=null)
         {
  +         List<Element> children = redirect.elements("param");
  +         final List<PageParameter> pageParameters = new ArrayList<PageParameter>();
  +         for (Element child: children)
  +         {
  +            pageParameters.add( parsePageParameter(child) );
  +         }
            final String viewId = redirect.attributeValue("view-id");
            caze.setResult(new Page.Result() {
               public void navigate(FacesContext context)
               {
  -               redirect(viewId);
  +               Map<String, Object> parameters = new HashMap<String, Object>();
  +               for ( PageParameter pageParameter: pageParameters )
  +               {
  +                  parameters.put( pageParameter.getName(), getParameterValue(context, pageParameter) );
  +               }
  +               redirect(viewId, parameters);
               }
            });
         }
  @@ -637,21 +649,40 @@
            {
               if ( !overridden.contains( pageParameter.getName() ) )
               {
  -               ValueBinding valueBinding = pageParameter.getValueBinding();
  -               if (valueBinding==null)
  -               {
  -                  Object value = Contexts.getPageContext().get( pageParameter.getName() );
  +               Object value = getPageParameterValue(facesContext, pageParameter);
                     if (value!=null) 
                     {
                        parameters.put( pageParameter.getName(), value );
                     }
                  }
  +         }
  +      }
  +      return parameters;
  +   }
  +
  +   private Object getPageParameterValue(FacesContext facesContext, Page.PageParameter pageParameter)
  +   {
  +      ValueBinding valueBinding = pageParameter.getValueBinding();
  +      if (valueBinding==null)
  +      {
  +         return Contexts.getPageContext().get( pageParameter.getName() );
  +      }
                  else
                  {
  -                  Object value = valueBinding.getValue();
  -                  if (value!=null)
  +         return getParameterValue(facesContext, pageParameter);
  +      }
  +   }
  +
  +   private Object getParameterValue(FacesContext facesContext, Page.PageParameter pageParameter)
                     {
  -                     Converter converter;
  +      Object value = pageParameter.getValueBinding().getValue();
  +      if (value==null)
  +      {
  +         return null;
  +      }
  +      else
  +      {
  +         Converter converter = null;
                        try
                        {
                           converter = pageParameter.getConverter();
  @@ -659,18 +690,13 @@
                        catch (RuntimeException re)
                        {
                           //YUCK! due to bad JSF/MyFaces error handling
  -                        continue;
  +            return null;
                        }
  -                     Object convertedValue = converter==null ? 
  +         
  +         return converter==null ? 
                              value : converter.getAsString( facesContext, facesContext.getViewRoot(), value );
  -                     parameters.put( pageParameter.getName(), convertedValue );
  -                  }
                  }
               }
  -         }
  -      }
  -      return parameters;
  -   }
      
      /**
       * Apply any page parameters passed as parameter values to the model.
  
  
  


From bvuiwe657984dfs at kittymail.com  Sat Dec 16 23:31:54 2006
From: bvuiwe657984dfs at kittymail.com (bvuiwe657984dfs at kittymail.com)
Date: Sat, 16 Dec 2006 23:31:54 -0500
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCJCQkLyRpRU8kOyRQMnEkQyRGJC8bKEI=?=
	=?iso-2022-jp?b?GyRCJGwkXiQ5JCshKTxMPz84KyRGJC8kQCQ1JCQhIxsoQg==?=
Message-ID: 20061217130712.51215mail@mail.kjhgfdsapoiuytrewqlokijuhygtfredswh.com

?????????????????????????????????
??????????????????
??????????????????????????????
????????????????????????
??????????????????????????????
http://allfree.todaywomanmeets.tonderuyo.com/dm/
??????????????????????
???????????





From jboss-cvs-commits at lists.jboss.org  Sat Dec 16 23:41:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 16 Dec 2006 23:41:31 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1808 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate src/main/org/jboss/jms/util
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/util
Message-ID: <E1Gvnq7-0007Ns-7Z@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-16 23:41:26 -0500 (Sat, 16 Dec 2006)
New Revision: 1808

Added:
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
   trunk/src/main/org/jboss/jms/util/Valve.java
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Log:
Adding ValveAspect on the failover

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-16 17:43:33 UTC (rev 1807)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-17 04:41:26 UTC (rev 1808)
@@ -34,6 +34,8 @@
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.aop.Advised;
+import org.jboss.aop.advice.Interceptor;
 import org.jboss.jms.client.delegate.ClientBrowserDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
@@ -61,15 +63,15 @@
 import org.jboss.remoting.ConnectionListener;
 
 /**
- * 
+ *
  * A HAAspect
- * 
+ *
  * There is one of these PER_INSTANCE of connection factory
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
- * 
+ *
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -82,6 +84,8 @@
 
    public static final int MAX_RECONNECT_HOP_COUNT = 10;
 
+   public static final int MAX_IO_RETRY_COUNT = 10;
+
    // Static --------------------------------------------------------
 
    private static boolean trace = log.isTraceEnabled();
@@ -104,6 +108,14 @@
       id = null;
    }
 
+   /** A Copy Constructor Used on creationg of ValveAspect */
+   protected HAAspect(HAAspect copyFrom)
+   {
+      this.delegates = copyFrom.delegates;
+      this.failoverMap = copyFrom.failoverMap;
+      this.id = copyFrom.id;
+   }
+
    // Public --------------------------------------------------------
 
    public Object handleCreateConnectionDelegate(Invocation invocation) throws Throwable
@@ -117,6 +129,10 @@
 
       cacheLocalDelegates(invocation);
 
+      // TODO: I wanted to change aop-messaging-client.xml to only execute handleCreateConnectionDelegate
+      //       on instances of ClusteredClientConnectionFactoryDelegate, but I couldn't find the right
+      //       pointcut expression. So, this is a to do.
+      //      However the following test is enough for now.
       if (delegates == null)
       {
          // not clustered, pass the invocation through
@@ -148,16 +164,14 @@
 
       ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
 
+      // ValveAspect is supposed to be created per ClientConnectionDelegate
+      installValveAspect(cd, new ValveAspect(cd, this));
+
       if(trace) { log.trace(this + " got local connection delegate " + cd); }
 
       // Add a connection listener to detect failure; the consolidated remoting connection listener
       // must be already in place and configured
 
-      ConnectionListener listener = new ConnectionFailureListener(cd);
-
-      ((ConnectionState)((DelegateSupport)cd).getState()).
-         getRemotingConnectionListener().addDelegateListener(listener);
-
       return new CreateConnectionResult(cd);
    }
 
@@ -211,6 +225,62 @@
       }
    }
 
+   // Debug information about interceptors
+   protected void printInterceptors(Interceptor interceptors[])
+    {
+       if (interceptors==null || interceptors.length==0)
+       {
+          log.info("Interceptor chain is empty");
+       }
+       else
+       {
+          for (int i=0; i<interceptors.length; i++)
+          {
+             log.info("Interceptor[" + i + "] = " + interceptors[i].getName() + " className= " + interceptors[i].getClass().getName());
+          }
+       }
+    }
+   
+   /** The valve aspect needs to stay after ExceptionInterceptor, and before DelegateSupport.
+    *  This method will place the aspect on the proper place */
+   protected void installValveAspect(DelegateSupport delegate, Interceptor interceptor)
+   {
+      Advised advised = (Advised)delegate;
+      Interceptor interceptors[] = advised._getInstanceAdvisor().getInterceptors();
+
+      log.info("Installing interceptors");
+      printInterceptors(interceptors);
+
+
+      Interceptor delegateInterceptorFound = null;
+
+      for (int i=0;i<interceptors.length;i++)
+      {
+         if (interceptors[i] instanceof DelegateSupport)
+         {
+            delegateInterceptorFound = interceptors[i];
+         }
+      }
+
+
+      if (delegateInterceptorFound!=null)
+      {
+         advised._getInstanceAdvisor().removeInterceptor(delegateInterceptorFound.getName());
+      }
+
+      advised._getInstanceAdvisor().appendInterceptor(interceptor);
+
+      if (delegateInterceptorFound!=null)
+      {
+         advised._getInstanceAdvisor().appendInterceptor(delegateInterceptorFound);
+      }
+
+      log.info("Interceptors after installation:");
+      printInterceptors(advised._getInstanceAdvisor().getInterceptors());
+
+   }
+   
+
    //TODO this is currently hardcoded as round-robin, this should be made pluggable
    private synchronized ClientConnectionFactoryDelegate getDelegateRoundRobin()
    {
@@ -245,7 +315,7 @@
       return null;
    }
 
-   private void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate)
+   protected void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate)
       throws Exception
    {
       log.debug(this + " handling failed connection " + failedConnDelegate);
@@ -327,7 +397,7 @@
                              "Cannot find a server to failover onto.");
    }
 
-   private void performClientSideFailover(ClientConnectionDelegate failedConnDelegate,
+   protected void performClientSideFailover(ClientConnectionDelegate failedConnDelegate,
                                           ClientConnectionDelegate newConnDelegate)
       throws Exception
    {
@@ -348,14 +418,14 @@
 
       // We need to update some of the attributes on the state
       failedState.copyState(newState);
-      
+
       // Map of old session ID to new session state
       Map oldNewSessionStateMap = new HashMap();
 
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
-          
+
          int oldSessionID = failedSessionState.getSessionId();
 
          ClientSessionDelegate failedSessionDelegate =
@@ -367,9 +437,9 @@
                                   failedSessionState.isXA());
 
          SessionState newSessionState = (SessionState)newSessionDelegate.getState();
-         
+
          if (trace) { log.trace("new session state has " + newSessionState.getClientAckList().size() + " deliveries"); }
-         
+
          oldNewSessionStateMap.put(new Integer(oldSessionID), failedSessionState);
 
          failedSessionDelegate.copyAttributes(newSessionDelegate);
@@ -401,13 +471,13 @@
             }
          }
       }
-      
+
       // First we must tell the resource manager to substitute old session ID for new session ID.
       // Note we MUST submit the entire mapping in one operation since there may be overlap between
       // old and new session ID, and we don't want to overwrite keys in the map.
-      
+
       failedState.getResourceManager().handleFailover(oldNewSessionStateMap);
-      
+
       for(Iterator i = oldNewSessionStateMap.values().iterator(); i.hasNext(); )
       {
          List ackInfos = Collections.EMPTY_LIST;
@@ -415,16 +485,16 @@
          SessionState state = (SessionState)i.next();
 
          if (!state.isTransacted() ||
-             (state.isXA() && state.getCurrentTxId() == null))     
+             (state.isXA() && state.getCurrentTxId() == null))
          {
             // Non transacted session or an XA session with no transaction set (it falls back
             // to auto_ack)
-            
+
             if (trace) { log.trace(state + " is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
 
             // We remove any unacked non-persistent messages - this is because we don't want to ack
             // them since the server won't know about them and will get confused
-                        
+
             if (state.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
             {
                for(Iterator j = state.getClientAckList().iterator(); j.hasNext(); )
@@ -436,13 +506,13 @@
                      if (trace) { log.trace("removed non persistent delivery " + info); }
                   }
                }
-               
+
                ackInfos = state.getClientAckList();
             }
             else
             {
                DeliveryInfo autoAck = state.getAutoAckInfo();
-               if (autoAck != null)                 
+               if (autoAck != null)
                {
                   if (!autoAck.getMessageProxy().getMessage().isReliable())
                   {
@@ -455,9 +525,9 @@
                      ackInfos = new ArrayList();
                      ackInfos.add(autoAck);
                   }
-               }               
+               }
             }
-            
+
             if (trace) { log.trace(this + " retrieved " + ackInfos.size() + " deliveries"); }
          }
          else
@@ -470,23 +540,23 @@
          }
 
          if (!ackInfos.isEmpty())
-         {                        
+         {
             SessionDelegate newDelegate = (SessionDelegate)state.getDelegate();
-            
+
             List recoveryInfos = new ArrayList();
-            
+
             for (Iterator iter2 = ackInfos.iterator(); iter2.hasNext(); )
             {
                DeliveryInfo info = (DeliveryInfo)iter2.next();
-               
+
                DeliveryRecovery recInfo =
-                  new DeliveryRecovery(info.getMessageProxy().getDeliveryId(),                                       
+                  new DeliveryRecovery(info.getMessageProxy().getDeliveryId(),
                                        info.getMessageProxy().getMessage().getMessageID(),
                                        info.getChannelId());
-               
+
                recoveryInfos.add(recInfo);
             }
-            
+
             if (trace) { log.trace(this + " sending delivery recovery info: " + recoveryInfos); }
             newDelegate.recoverDeliveries(recoveryInfos);
          }
@@ -545,7 +615,7 @@
 //         ResourceManager rm = failedConnectionState.getResourceManager();
 //
 //         todo - we need to replace the sesion id
-//         
+//
 //         rm.handleFailover(oldConsumerID, failedConsumerState.getConsumerID());
 //      }
 
@@ -614,37 +684,6 @@
 
    }
 
-   // Inner classes -------------------------------------------------
-
-   private class ConnectionFailureListener implements ConnectionListener
-   {
-      private ClientConnectionDelegate cd;
-
-      ConnectionFailureListener(ClientConnectionDelegate cd)
-      {
-         this.cd = cd;
-      }
-
-      // ConnectionListener implementation ---------------------------
-
-      public void handleConnectionException(Throwable throwable, Client client)
-      {
-         try
-         {
-            log.debug(this + " is being notified of connection failure: " + throwable);
-            handleConnectionFailure(cd);
-         }
-         catch (Throwable e)
-         {
-            log.error("Caught exception in handling failure", e);
-         }
-      }
-
-      public String toString()
-      {
-         return "ConnectionFailureListener[" + cd + "]";
-      }
-   }
 }
 
 

Added: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-16 17:43:33 UTC (rev 1807)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-17 04:41:26 UTC (rev 1808)
@@ -0,0 +1,227 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.jms.client.container;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.util.Valve;
+import org.jboss.logging.Logger;
+import org.jboss.remoting.CannotConnectException;
+import org.jboss.remoting.ConnectionListener;
+import org.jboss.remoting.Client;
+import java.io.IOException;
+import javax.jms.JMSException;
+
+/**
+ * This aspect will intercept failures from any HA object.
+ * <p/>
+ * The reason why I've made an extension of HAAspect instead of implementing new methods there is
+ * ValveAspect needs to cache ClientConnectionDelegate while HAAspect needs to cache CF related objects.
+ * I have made this an extension of HAAspect as it's needed one instance of this aspect per
+ * ConnectionCreated.
+ * <p/>
+ * We will cache the ClientConnectionDelegate on this aspect so we won't need to do any operation on delegates
+ * to retrieve the current ConnectionDelegate.
+ *
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class ValveAspect extends HAAspect implements Interceptor
+{
+   private static final Logger log = Logger.getLogger(ValveAspect.class);
+
+   private ClientConnectionDelegate delegate;
+
+   private Valve valve = new Valve();
+
+   ValveAspect(ClientConnectionDelegate delegate, HAAspect copy)
+   {
+      super(copy);
+      this.delegate = delegate;
+
+      ConnectionListener listener = new ConnectionFailureListener(delegate);
+
+      ((ConnectionState) ((DelegateSupport) delegate).getState()).
+         getRemotingConnectionListener().addDelegateListener(listener);
+
+
+   }
+
+   public String getName()
+   {
+      return this.getClass().getName();
+   }
+
+
+   /**
+    * This method executes the valve, listening for erros on the underlaying IO layer,
+    * and it will call the failure for HA
+    */
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+
+      Object returnObject = null;
+
+      boolean failure = false;
+
+      // Eventually retries in case of listed exceptions
+      for (int i = 0; i < MAX_IO_RETRY_COUNT; i++)
+      {
+         // We shouldn't have any calls being made while the failover is being executed
+         valve.isOpened(true);
+
+         if (i > 0)
+         {
+            log.info("Retrying a call " + i);
+         }
+         failure = false;
+         try
+         {
+            returnObject = invocation.invokeNext();
+         }
+         catch (CannotConnectException e)
+         {
+            log.error("Got an exception on HAAspect, retryCount=" + i, e);
+            failure = true;
+         }
+         catch (IOException e)
+         {
+            log.error("Got an exception on HAAspect, retryCount=" + i, e);
+            failure = true;
+         }
+         catch (Throwable e)
+         {
+            log.error("ValveAspect didn't catch the exception " + e + ", and it will be forwarded", e);
+            throw e;
+         }
+
+         if (!failure)
+         {
+            break;
+         }
+      }
+
+
+      if (failure)
+      {
+         handleConnectionFailure(delegate);
+         // if on the end we still have an exception there is nothing we can do besides throw an exception
+         // so, no retires on the failedOver Invocation
+         returnObject = invocation.invokeNext();
+      }
+
+      // if the object returned is another DelegateSupport, we will install the aspect on the returned object
+
+      return returnObject;
+
+   }
+
+
+   /**
+    * Since we are listening for exceptions on the invocation layer, several objects might
+    * get the exception at the same time.
+    * Suppose you have 30 (or any X number>=2) Consumers, using the same JBossConnection failing at the same time.
+    * We will get simultaneous calls on handleFailures while we just need to process one single failure.
+    * <p/>
+    * On this case this method will open a valve and it will perform only the first handleFailure captured, and
+    * it will just return all the others as soon as the valve is closed. This way all the simultaneous failures will
+    * act as they were processed while we called failover only once.
+    */
+   protected void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate) throws Exception
+   {
+      Valve localValve = null;
+
+      // The idea is to reset the Valve synchronized with a reset valve
+      synchronized (this) // I'm not sure if this synchronized is necessary. I will keep it here just to be safe
+      {
+         localValve = valve;
+      }
+
+      // only one execution should be performed if multiple exceptions happened at the same time
+      if (localValve.open())
+      {
+         try
+         {
+            log.info("Processing valve on exception failure");
+            super.handleConnectionFailure(failedConnDelegate);
+         }
+         finally
+         {
+            localValve.close();
+            synchronized (this)
+            {
+               // reset the valve, so future exceptions will also get processed
+               valve = new Valve();
+            }
+         }
+      } else
+      {
+         log.info("The valve was closed, so this invocation waited another invocation to finish on handleFailure");
+      }
+   }
+
+   // Inner classes -------------------------------------------------
+
+
+   /** I have moved this ConnectionListener to ValveAspect (from HAAspect) because
+    *  it needs to use the same valve as exception listeners.
+    *  While we are processing failover, we should block any calls on the client side.
+    *  (No call should be made while the client failover is being executed). It doesn't matter if
+    *  the failover was captured by Lease (ConnectionFactory) or Exception handling on invoke at this class */
+   private class ConnectionFailureListener implements ConnectionListener
+   {
+      private ClientConnectionDelegate cd;
+
+      ConnectionFailureListener(ClientConnectionDelegate cd)
+      {
+         this.cd = cd;
+      }
+
+      // ConnectionListener implementation ---------------------------
+
+      public void handleConnectionException(Throwable throwable, Client client)
+      {
+         try
+         {
+            log.debug(this + " is being notified of connection failure: " + throwable);
+            handleConnectionFailure(cd);
+         }
+         catch (Throwable e)
+         {
+            log.error("Caught exception in handling failure", e);
+         }
+      }
+
+      public String toString()
+      {
+         return "ConnectionFailureListener[" + cd + "]";
+      }
+   }
+
+
+}

Modified: trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-16 17:43:33 UTC (rev 1807)
+++ trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-17 04:41:26 UTC (rev 1808)
@@ -94,7 +94,8 @@
 
    public String getName()
    {
-      return "Invoker";
+      // it's needed a meaninful name to change the aop stack programatically (HA uses that)
+      return this.getClass().getName();
    }
 
    /**

Modified: trunk/src/main/org/jboss/jms/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-16 17:43:33 UTC (rev 1807)
+++ trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-17 04:41:26 UTC (rev 1808)
@@ -22,7 +22,9 @@
 
 package org.jboss.jms.util;
 
+import org.jboss.logging.Logger;
 
+
 /**
  * This class is used to guarantee only one thread will be performing a given function, and if any other
  * thread tries to execute the same functionality it will just ignored
@@ -54,10 +56,47 @@
  *  */
 public class Valve
 {
+   private static final Logger log = Logger.getLogger(Valve.class);
+   private boolean trace = log.isTraceEnabled();
+
    boolean opened;
    boolean closed;
 
+   Thread threadOwner;
 
+   int refereceCountOpen=0;
+
+
+   public synchronized boolean isOpened()
+   {
+      return opened;
+   }
+
+   /** If the Valve is opened, will wait until the valve is closed */
+   public synchronized boolean isOpened(boolean wait) throws Exception
+   {
+      if (wait && opened)
+      {
+         if (!closed && threadOwner != Thread.currentThread())
+         {
+            if (trace) log.trace("threadOwner= " + threadOwner + " and currentThread=" + Thread.currentThread());
+            if (trace) log.trace("Waiting valve to be closed");
+            this.wait();
+            if (trace) log.trace("Valve was closed");
+         }
+         else
+         {
+            if (trace) log.trace("This is ThreadOwner, so Valve won't wait");
+         }
+         return opened;
+      }
+      else
+      {
+         return false;
+      }
+
+   }
+
    public boolean open() throws Exception
    {
       return open(true);
@@ -65,9 +104,16 @@
 
    public synchronized boolean open(boolean wait) throws Exception
    {
+      if (threadOwner==Thread.currentThread())
+      {
+         if (trace) log.trace("Valve was opened again by thread owner");
+         refereceCountOpen++;
+         return true;
+      }
       // already opened? then needs to wait to be closed
       if (opened)
       {
+         if (trace) log.trace("Valve being opened and time.wait");
          // if not closed yet, will wait to be closed
          if (!closed)
          {
@@ -79,7 +125,10 @@
          return false;
       } else
       {
+         if (trace) log.trace("Valve being opened and this thread is the owner for this lock");
+         refereceCountOpen++;
          opened = true;
+         threadOwner = Thread.currentThread();
          return true;
       }
    }
@@ -92,9 +141,18 @@
       }
       if (closed)
       {
-         throw new IllegalStateException("Valve is already closed");
+         log.warn("Valve was already closed", new Exception());
       }
-      closed = true;
-      notifyAll();
+      refereceCountOpen--;
+      if (refereceCountOpen==0)
+      {
+         if (trace) log.trace("Closing Valve");
+         closed = true;
+         notifyAll();
+      }
+      else
+      {
+         if (trace) log.trace("Valve.close called but there referenceCountOpen=" + refereceCountOpen);
+      }
    }
 }

Added: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-16 17:43:33 UTC (rev 1807)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-17 04:41:26 UTC (rev 1808)
@@ -0,0 +1,237 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.logging.Logger;
+import javax.jms.MessageConsumer;
+import javax.jms.Session;
+import javax.jms.Destination;
+import javax.jms.Connection;
+import javax.jms.MessageProducer;
+import javax.jms.Message;
+import java.util.ArrayList;
+import java.util.Iterator;
+
+/**
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class ValveTest extends ClusteringTestBase
+{
+
+   public ValveTest(String name)
+   {
+      super(name);
+   }
+
+   int messageCounterConsumer =0;
+   int messageCounterProducer=0;
+
+
+   Object lockReader = new Object();
+   Object lockWriter = new Object();
+   Object semaphore = new Object();
+
+   boolean shouldStop = false;
+
+
+   class LocalThreadConsumer extends Thread
+   {
+      private final Logger log = Logger.getLogger(this.getClass());
+
+      int id;
+      MessageConsumer consumer;
+      Session session;
+
+      public LocalThreadConsumer(int id, Session session, Destination destination) throws Exception
+      {
+         consumer = session.createConsumer(destination);
+         this.session = session;
+         this.id = id;
+      }
+
+
+      public void run()
+      {
+         try
+         {
+            synchronized (semaphore)
+            {
+               semaphore.wait();
+            }
+
+            int counter = 0;
+            while (true)
+            {
+               Message message = consumer.receive(50);
+               if (message==null && shouldStop)
+               {
+                  break;
+               }
+               if (message!=null)
+               {
+                  synchronized (lockReader)
+                  {
+                     messageCounterConsumer++;
+                  }
+                  log.trace("ReceiverID=" + id + " received message " + message);
+                  if (counter++ % 10 == 0)
+                  {
+                     //log.info("Commit on id=" + id);
+                     session.commit();
+                  }
+               }
+            }
+            session.commit();
+         }
+         catch (Exception e)
+         {
+            log.info("Caught exception... finishing Thread " + id, e);
+         }
+      }
+   }
+
+   class LocalThreadProducer extends Thread
+   {
+      private final Logger log = Logger.getLogger(this.getClass());
+
+      MessageProducer producer;
+      Session session;
+      int id;
+
+      public LocalThreadProducer(int id, Session session, Destination destination) throws Exception
+      {
+         this.session = session;
+         producer = session.createProducer(destination);
+         this.id = id;
+      }
+
+      public void run()
+      {
+         try
+         {
+            synchronized (semaphore)
+            {
+               semaphore.wait();
+            }
+
+            int counter = 0;
+            while (!shouldStop)
+            {
+               log.trace("Producer ID=" + id + " send message");
+               producer.send(session.createTextMessage("Message from producer " + id + " counter=" + (counter)));
+
+               synchronized (lockWriter)
+               {
+                  messageCounterProducer++;
+               }
+
+               if (counter++ % 5 == 0)
+               {
+                  //log.info("Committing message");
+                  session.commit();
+               }
+            }
+
+         }
+         catch (Exception e)
+         {
+            log.info("Caught exception... finishing Thread " + id, e);
+         }
+      }
+   }
+
+   /**
+    * This test will open several Consumers at the same Connection and it will kill the server, expecting failover
+    * to happen inside the Valve
+    */
+   public void testMultiThreadFailover() throws Exception
+   {
+      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+      Connection conn = factory.createConnection();
+      conn.start();
+
+      ArrayList list = new ArrayList();
+
+      for (int i = 0; i < 5; i++)
+      {
+         list.add(new LocalThreadProducer(i, conn.createSession(true, Session.AUTO_ACKNOWLEDGE), queue[1]));
+         list.add(new LocalThreadConsumer(i, conn.createSession(true, Session.AUTO_ACKNOWLEDGE), queue[1]));
+      }
+
+      for (Iterator iter = list.iterator(); iter.hasNext();)
+      {
+         Thread t = (Thread) iter.next();
+         t.start();
+      }
+
+      Thread.sleep(1000);
+      synchronized (semaphore)
+      {
+         semaphore.notifyAll();
+      }
+
+      Thread.sleep(30000);
+
+      log.info("Killing server 1");
+
+      ServerManagement.kill(1);
+
+      Thread.sleep(50000);
+      shouldStop=true;
+
+      for (Iterator iter = list.iterator(); iter.hasNext();)
+      {
+         Thread t = (Thread) iter.next();
+         t.join();
+      }
+
+      log.info("produced " + messageCounterProducer + " and read " + messageCounterConsumer);
+
+      assertEquals(messageCounterProducer, messageCounterConsumer);
+
+
+   }
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      nodeCount = 3;
+
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-16 17:43:33 UTC (rev 1807)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-17 04:41:26 UTC (rev 1808)
@@ -81,11 +81,18 @@
 
                //Thread.sleep(1000);
 
+               valve.open(); // stack vavles
+               if (!valve.isOpened(true))
+               {
+                  fail("Valve should be opened");
+               }
+
                synchronized (VeryBasicValveTest.class)
                {
                   counter ++;
                }
                valve.close();
+               valve.close();
             }
 
             //log.info("Thread " + threadId + " is now closing the valve");



From norman.richards at jboss.com  Sun Dec 17 00:10:40 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 17 Dec 2006 00:10:40 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay ...
Message-ID: <E1GvoIK-0007xv-E4@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/17 00:10:40

  Modified:    examples/seampay/src/org/jboss/seam/example/seampay     
                        Account.java Payment.java PaymentProcessor.java
  Added:       examples/seampay/src/org/jboss/seam/example/seampay     
                        Digits.java DigitsValidator.java
  Log:
  use BigDecimal, with validation, for dollar values
  
  Revision  Changes    Path
  1.2       +10 -5     jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Account.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Account.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Account.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Account.java	20 Oct 2006 16:51:26 -0000	1.1
  +++ Account.java	17 Dec 2006 05:10:40 -0000	1.2
  @@ -4,8 +4,10 @@
   import java.util.List;
   import java.io.Serializable;
   
  +import java.math.BigDecimal;
  +
   import javax.persistence.*;
  -import org.hibernate.validator.Length;
  +import org.hibernate.validator.*;
   
   @Entity
   public class Account
  @@ -14,7 +16,10 @@
       @Id @GeneratedValue 
       private Long id;
   
  -    float  balance;
  +    @NotNull
  +    BigDecimal balance;
  +
  +    @NotNull
       String accountNumber;
       //String login;
       //String password;
  @@ -42,13 +47,13 @@
       }
   
   
  -    public float getBalance()
  +    public BigDecimal getBalance()
       {
           return balance;
       }
   
  -    public float adjustBalance(float amount) {
  -        balance += amount;
  +    public BigDecimal adjustBalance(BigDecimal amount) {
  +        balance = balance.add(amount);
           return balance;
       }
   
  
  
  
  1.5       +14 -4     jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Payment.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Payment.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Payment.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- Payment.java	12 Dec 2006 23:25:08 -0000	1.4
  +++ Payment.java	17 Dec 2006 05:10:40 -0000	1.5
  @@ -5,6 +5,7 @@
   
   import java.io.Serializable;
   import java.util.*;
  +import java.math.*;
   
   import org.hibernate.validator.*;
   
  @@ -15,8 +16,10 @@
       @Id @GeneratedValue 
       private Long id;
   
  -    // neither @Min or @Pattern work here
  -    private float amount;
  +    @NotNull
  +    @Digits(integerDigits=8,fractionalDigits=2)
  +    private BigDecimal amount;
  +
       @NotNull @Length(min=1)
       private String payee;
   
  @@ -40,13 +43,20 @@
           return id;
       }
       
  -    public float getAmount() {
  +    public BigDecimal getAmount() {
           return amount;
       }
  -    public void setAmount(float amount) {
  +    public void setAmount(BigDecimal amount) {
           this.amount = amount;
       }
       
  +    public BigInteger getTesting() {
  +        return testing;
  +    }
  +    public void setTesting(BigInteger testing) {
  +        this.testing = testing;
  +    }
  +    
       public String getPayee()
       {
           return payee;
  
  
  
  1.4       +3 -1      jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/PaymentProcessor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PaymentProcessor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/PaymentProcessor.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PaymentProcessor.java	22 Oct 2006 19:40:02 -0000	1.3
  +++ PaymentProcessor.java	17 Dec 2006 05:10:40 -0000	1.4
  @@ -8,6 +8,8 @@
   import javax.persistence.*;
   import javax.ejb.Timer;
   
  +import java.math.BigDecimal;
  +
   
   @Name("processor")
   public class PaymentProcessor {
  @@ -27,7 +29,7 @@
           log.info("Timer handle is #0", payment.getTimerHandle());
   
           if (payment.getActive()) {
  -            float balance = payment.getAccount().adjustBalance(-payment.getAmount());
  +            BigDecimal balance = payment.getAccount().adjustBalance(payment.getAmount().negate());
               log.info(":: balance is now #0", balance);
               payment.setLastPaid(new Date());
   
  
  
  
  1.1      date: 2006/12/17 05:10:40;  author: nrichards;  state: Exp;jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Digits.java
  
  Index: Digits.java
  ===================================================================
  package org.jboss.seam.example.seampay;
  
  import org.hibernate.validator.*;
  
  import java.lang.annotation.*;
  
  @ValidatorClass(DigitsValidator.class)
  @Target({ElementType.METHOD, ElementType.FIELD}) 
  @Retention(RetentionPolicy.RUNTIME)
  @Documented
  public @interface Digits {
      int integerDigits();
      int fractionalDigits() default 0;
      String message() default "invalid numeric value";
  }
  
  
  
  1.1      date: 2006/12/17 05:10:40;  author: nrichards;  state: Exp;jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/DigitsValidator.java
  
  Index: DigitsValidator.java
  ===================================================================
  package org.jboss.seam.example.seampay;
  
  import java.math.*;
  import org.hibernate.validator.*;
  
  import org.hibernate.mapping.*;
  
  public class DigitsValidator
      implements Validator<Digits>
  {
      int integerDigits;
      int fractionalDigits;
      
      public void initialize(Digits configuration) {
          integerDigits      = configuration.integerDigits();
          fractionalDigits = configuration.fractionalDigits();        
      }
  
      public boolean isValid(Object value) {
          if (value==null) { 
              return true;
          }
  
          String stringValue = null;
  
          if (value instanceof String) {
              try {
                  stringValue = stringValue(new BigDecimal((String) value));
              } catch (NumberFormatException nfe) {
                  return false;
              }
          } else if (value instanceof BigDecimal) {
              stringValue = stringValue((BigDecimal) value);
          } else if (value instanceof BigInteger) {
              stringValue = stringValue((BigInteger) value);
          } else {
              return false;
          }
  
  
          int pos = stringValue.indexOf(".");
  
          int left = (pos == -1) ? stringValue.length() : pos;
          int right = (pos==-1) ? 0 : stringValue.length() - pos -1;
  
          if (left==1 && stringValue.charAt(0) == '0') {
              left--;
          }
          
          if (left > integerDigits || right > fractionalDigits) {
              return false;
          }
  
          return true;
      }
  
      private String stringValue(BigDecimal number) {
          return number.abs().stripTrailingZeros().toPlainString();
      }
      private String stringValue(BigInteger number) {
          return number.abs().toString();
      }
  }
  
  
  


From forge-admin at jboss.com  Sun Dec 17 01:00:29 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sun, 17 Dec 2006 01:00:29 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gvp4X-0000Ej-3Z@committer01.frg.pub.inap.atl.jboss.com>

Commit from sbryzak2 (2006-12-16 02:33 EST)
--------------------

SubscriptionRegistry not installed by default

  jboss-seam  examples/remoting/chatroom/resources/WEB-INF/components.xml           1.5
  jboss-seam  src/main/org/jboss/seam/remoting/messaging/SubscriptionRegistry.java  1.13


Commit from sbryzak2 (2006-12-16 02:44 EST)
--------------------

consolidate the acl provider stuff into a single Seam component

  jboss-seam  src/main/org/jboss/seam/security/acl/AclProvider.java            1.4
- jboss-seam  src/main/org/jboss/seam/security/acl/AbstractAclProvider.java    1.5
- jboss-seam  src/main/org/jboss/seam/security/acl/PersistentAclProvider.java  1.16


Commit from gavin (2006-12-16 05:03 EST)
-----------------

JBSEAM-595

+ jboss-seam  src/main/org/jboss/seam/annotations/TransactionPropagationType.java  1.1
  jboss-seam  src/main/org/jboss/seam/annotations/Transactional.java               1.3
  jboss-seam  src/main/org/jboss/seam/core/TransactionListener.java                1.2
  jboss-seam  src/main/org/jboss/seam/interceptors/TransactionInterceptor.java     1.10
  jboss-seam  src/main/org/jboss/seam/util/Work.java                               1.3


Commit from gavin (2006-12-16 05:17 EST)
-----------------

javadoc

  jboss-seam  src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java  1.17
  jboss-seam  src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java          1.2
  jboss-seam  src/main/org/jboss/seam/interceptors/TransactionInterceptor.java            1.11
  jboss-seam  src/main/org/jboss/seam/interceptors/ValidationInterceptor.java             1.25
  jboss-seam  src/main/org/jboss/seam/util/Work.java                                      1.4


Commit from gavin (2006-12-16 06:37 EST)
-----------------

list screen ordering

  jboss-seam  seam-gen/resources/messages_en.properties  1.5
  jboss-seam  seam-gen/view/list.page.xml.ftl            1.2
  jboss-seam  seam-gen/view/list.xhtml.ftl               1.8
  jboss-seam  seam-gen/view/stylesheet/theme.css         1.7


Commit from ptsekov on branch Branch_JBossCache_1_4_0 (2006-12-16 08:13 EST)
-----------------------------------------------------

Add support for testing whether serialized objects remain compatible with older versions of JBossCache (JBQA-536).

  JBossCache  build.xml                                                              1.119.2.18
+ JBossCache  tests/compat/org/jboss/cache/compat/SerialVersionUIDUnitTestCase.java  1.1.2.1
+ JBossCache  tests/compat/org/jboss/tools/ClassVersionInfo.java                     1.1.2.1
+ JBossCache  tests/compat/org/jboss/tools/SerialVersionUID.java                     1.1.2.1


Commit from gavin (2006-12-16 08:26 EST)
-----------------

JBSEAM-477, search screens

  jboss-seam  seam-gen/src/EntityList.java.ftl  1.4
  jboss-seam  seam-gen/view/edit.xhtml.ftl      1.21
  jboss-seam  seam-gen/view/list.page.xml.ftl   1.3
  jboss-seam  seam-gen/view/list.xhtml.ftl      1.9
  jboss-seam  seam-gen/view/view.xhtml.ftl      1.8


Commit from gavin (2006-12-16 08:43 EST)
-----------------

JBSEAM-539

  jboss-seam  seam-gen/build.xml  1.54


Commit from gavin (2006-12-16 09:06 EST)
-----------------

better handling of empty string
JBSEAM-570, @Observer(create=false)

  jboss-seam  src/main/org/jboss/seam/Component.java                       1.222
  jboss-seam  src/main/org/jboss/seam/annotations/Observer.java            1.4
  jboss-seam  src/main/org/jboss/seam/core/Events.java                     1.16
  jboss-seam  src/main/org/jboss/seam/core/Init.java                       1.34
  jboss-seam  src/main/org/jboss/seam/framework/EntityQuery.java           1.7
  jboss-seam  src/main/org/jboss/seam/framework/HibernateEntityQuery.java  1.6
  jboss-seam  src/main/org/jboss/seam/framework/Query.java                 1.14


Commit from gavin (2006-12-16 09:37 EST)
-----------------

JBSEAM-603

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd    1.6
  jboss-seam  src/main/org/jboss/seam/core/Page.java   1.8
  jboss-seam  src/main/org/jboss/seam/core/Pages.java  1.60


Commit from gavin (2006-12-16 09:38 EST)
-----------------

conversation-required

  jboss-seam  examples/booking/resources/WEB-INF/components.xml                 1.9
  jboss-seam  examples/booking/resources/WEB-INF/pages.xml                      1.6
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Booking.java  1.13


Commit from gavin (2006-12-16 09:51 EST)
-----------------

protect edit screen

  jboss-seam  seam-gen/build.xml               1.55
  jboss-seam  seam-gen/view/edit.page.xml.ftl  1.3
+ jboss-seam  seam-gen/view/view.page.xml.ftl  1.1


Commit from gavin (2006-12-16 10:04 EST)
-----------------

1.1.1

  jboss-seam  build.xml                                          1.123
  jboss-seam  readme.txt                                         1.27
  jboss-seam  changelog.txt                                      1.34
  jboss-seam  src/main/org/jboss/seam/servlet/SeamListener.java  1.21
  jboss-seam  doc/reference/en/master.xml                        1.48


Commit from gavin (2006-12-16 10:05 EST)
-----------------

minor

  jboss-seam  seam-gen/view/list.xhtml.ftl  1.10


Commit from gavin (2006-12-16 11:05 EST)
-----------------

reduce jbpm dependency

  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java    1.73
  jboss-seam  src/main/org/jboss/seam/core/BusinessProcess.java  1.15
  jboss-seam  src/main/org/jboss/seam/core/Dispatcher.java       1.14


Commit from gavin (2006-12-16 11:36 EST)
-----------------

doc required=true limitation

  jboss-seam  doc/reference/en/modules/validation.xml  1.3


Commit from gavin (2006-12-16 19:25 EST)
-----------------

JBSEAM-605, navigation in pages.xml
make s:link action trigger navigation even if outcome is null (but not page actions)

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd                   1.7
  jboss-seam  src/main/org/jboss/seam/core/Exceptions.java            1.18
  jboss-seam  src/main/org/jboss/seam/core/Page.java                  1.9
  jboss-seam  src/main/org/jboss/seam/core/Pages.java                 1.61
  jboss-seam  src/main/org/jboss/seam/jsf/SeamNavigationHandler.java  1.17
+ jboss-seam  src/main/org/jboss/seam/core/Navigator.java             1.1


Commit from gavin (2006-12-16 20:04 EST)
-----------------

reworked the booking example to take advantage of ochestration from pages.xml

  jboss-seam  examples/booking/resources/WEB-INF/pages.xml                                   1.7
  jboss-seam  examples/booking/resources/WEB-INF/web.xml                                     1.36
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/BookingList.java           1.5
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/BookingListAction.java     1.18
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/ChangePassword.java        1.3
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/ChangePasswordAction.java  1.16
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelBooking.java          1.12
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java    1.43
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelSearching.java        1.9
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelSearchingAction.java  1.15
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java   1.13
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Login.java                 1.2
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LoginAction.java           1.17
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Logout.java                1.2
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LogoutAction.java          1.8
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Register.java              1.2
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/RegisterAction.java        1.16
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java      1.41
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java  1.13
  jboss-seam  examples/booking/view/confirm.xhtml                                            1.18
  jboss-seam  examples/booking/view/home.xhtml                                               1.12
  jboss-seam  examples/booking/view/password.xhtml                                           1.11
  jboss-seam  examples/booking/view/template.xhtml                                           1.10


Commit from gavin (2006-12-16 20:07 EST)
-----------------

reworked the booking example to take advantage of ochestration from pages.xml

- jboss-seam  examples/booking/resources/WEB-INF/navigation.xml  1.2


Commit from gavin (2006-12-16 20:26 EST)
-----------------

fix tests

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java         1.42
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/BookingUnitTest.java     1.14
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/ChangePasswordTest.java  1.14
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/LoginTest.java           1.23


Commit from nrichards (2006-12-16 20:32 EST)
---------------------

JBSEAM-560: first pass at new-query

  jboss-seam  seam-gen/build.xml         1.56
+ jboss-seam  seam-gen/src/Query.java    1.1
+ jboss-seam  seam-gen/view/query.xhtml  1.1


Commit from gavin (2006-12-16 21:39 EST)
-----------------

params for redirects JBSEAM-180, yay

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd         1.8
  jboss-seam  src/main/org/jboss/seam/core/Exceptions.java  1.19
  jboss-seam  src/main/org/jboss/seam/core/Navigator.java   1.2
  jboss-seam  src/main/org/jboss/seam/core/Pages.java       1.62


Commit from nrichards (2006-12-17 00:10 EST)
---------------------

use BigDecimal, with validation, for dollar values

  jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/Account.java           1.2
+ jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/Digits.java            1.1
+ jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/DigitsValidator.java   1.1
  jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/Payment.java           1.5
  jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/PaymentProcessor.java  1.4
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061217/63b174a8/attachment.html 

From bfgdy9874dsa at graffiti.net  Sun Dec 17 02:19:42 2006
From: bfgdy9874dsa at graffiti.net (bfgdy9874dsa at graffiti.net)
Date: Sun, 17 Dec 2006 02:19:42 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCosKCwq3CgsOnwo9vwoLCucKCw47CjsKEwoI=?=
	=?utf-8?b?w4bCicOvwoLDgcKCw4TCgsKtwoLDqsKCw5zCgsK3woLCqcKBSA==?=
Message-ID: 20061217162458.28703mail@mail.azxswedxcvfrtgbnhyujmmkuituryetwh.com

?o?????n?????????????B
?t?????????????????B
???????A???????????????????????B
?????????????????????????A???K?????????????????????B
100?????????????????H?????????????H
???????????A?F?X?????????????????B
???????????????????B

http://www.allcompletefree.com.tonderuyo.com/mlo/





From norman.richards at jboss.com  Sun Dec 17 02:20:04 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 17 Dec 2006 02:20:04 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore  ...
Message-ID: <E1GvqJY-0001l0-HA@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/17 02:20:04

  Modified:    examples/dvdstore  build.xml
  Log:
  use bigdecimal for dollar amounts, also clear up some messed up line endings
  
  Revision  Changes    Path
  1.40      +10 -10    jboss-seam/examples/dvdstore/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/build.xml,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -b -r1.39 -r1.40
  
  
  


From norman.richards at jboss.com  Sun Dec 17 02:20:04 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 17 Dec 2006 02:20:04 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources   ...
Message-ID: <E1GvqJY-0001lA-PZ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/17 02:20:04

  Modified:    examples/dvdstore/resources   ordermanagement2.jpdl.xml
                        ordermanagement3.jpdl.xml
  Log:
  use bigdecimal for dollar amounts, also clear up some messed up line endings
  
  Revision  Changes    Path
  1.3       +5 -5      jboss-seam/examples/dvdstore/resources/ordermanagement2.jpdl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ordermanagement2.jpdl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/ordermanagement2.jpdl.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  
  
  
  1.3       +4 -4      jboss-seam/examples/dvdstore/resources/ordermanagement3.jpdl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ordermanagement3.jpdl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/ordermanagement3.jpdl.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  
  
  


From norman.richards at jboss.com  Sun Dec 17 02:20:04 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 17 Dec 2006 02:20:04 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/META-INF     ...
Message-ID: <E1GvqJY-0001lQ-VS@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/17 02:20:04

  Modified:    examples/dvdstore/resources/META-INF     application.xml
                        ejb-jar.xml jboss-app.xml persistence.xml
  Log:
  use bigdecimal for dollar amounts, also clear up some messed up line endings
  
  Revision  Changes    Path
  1.7       +18 -19    jboss-seam/examples/dvdstore/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/application.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- application.xml	5 Dec 2006 13:23:40 -0000	1.6
  +++ application.xml	17 Dec 2006 07:20:04 -0000	1.7
  @@ -27,5 +27,4 @@
   	<module>
   	    <java>jbpm-3.1.2.jar</java>
   	</module>
  -	
   </application>
  
  
  
  1.4       +12 -13    jboss-seam/examples/dvdstore/resources/META-INF/ejb-jar.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ejb-jar.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/ejb-jar.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ejb-jar.xml	3 Dec 2006 04:44:40 -0000	1.3
  +++ ejb-jar.xml	17 Dec 2006 07:20:04 -0000	1.4
  @@ -16,5 +16,4 @@
            <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
         </interceptor-binding>
      </assembly-descriptor>
  -   
   </ejb-jar>
  
  
  
  1.3       +3 -3      jboss-seam/examples/dvdstore/resources/META-INF/jboss-app.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-app.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/jboss-app.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  
  
  
  1.10      +5 -5      jboss-seam/examples/dvdstore/resources/META-INF/persistence.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: persistence.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/META-INF/persistence.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  
  
  


From norman.richards at jboss.com  Sun Dec 17 02:20:05 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 17 Dec 2006 02:20:05 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources/WEB-INF    ...
Message-ID: <E1GvqJZ-0001le-7z@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/17 02:20:05

  Modified:    examples/dvdstore/resources/WEB-INF    faces-config.xml
                        navigation.xml web.xml
  Log:
  use bigdecimal for dollar amounts, also clear up some messed up line endings
  
  Revision  Changes    Path
  1.13      +1 -1      jboss-seam/examples/dvdstore/resources/WEB-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/WEB-INF/faces-config.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  
  
  
  1.2       +3 -3      jboss-seam/examples/dvdstore/resources/WEB-INF/navigation.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: navigation.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/WEB-INF/navigation.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  
  
  
  1.18      +15 -15    jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/WEB-INF/web.xml,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  
  
  


From norman.richards at jboss.com  Sun Dec 17 02:20:05 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 17 Dec 2006 02:20:05 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam ...
Message-ID: <E1GvqJZ-0001mA-IC@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/17 02:20:05

  Modified:    examples/dvdstore/src/com/jboss/dvd/seam         
                        AfterShippingAction.java CheckoutAction.java
                        Order.java OrderApprovalDecision.java Product.java
                        ShoppingCart.java ShoppingCartBean.java
                        StoreManager.java StoreManagerBean.java
  Log:
  use bigdecimal for dollar amounts, also clear up some messed up line endings
  
  Revision  Changes    Path
  1.2       +2 -1      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/AfterShippingAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AfterShippingAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/AfterShippingAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- AfterShippingAction.java	3 Jan 2006 18:04:10 -0000	1.1
  +++ AfterShippingAction.java	17 Dec 2006 07:20:05 -0000	1.2
  @@ -1,5 +1,6 @@
   package com.jboss.dvd.seam;
   
  +import java.math.BigDecimal;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
  @@ -13,7 +14,7 @@
   @Name("afterShipping")
   public class AfterShippingAction {
       @In Long orderId;
  -    @In float amount;
  +    @In BigDecimal amount;
       @In(scope=ScopeType.BUSINESS_PROCESS) 
       String customer;
       
  
  
  
  1.7       +3 -4      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/CheckoutAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CheckoutAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/CheckoutAction.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- CheckoutAction.java	30 Jun 2006 21:08:27 -0000	1.6
  +++ CheckoutAction.java	17 Dec 2006 07:20:05 -0000	1.7
  @@ -7,6 +7,8 @@
   
   package com.jboss.dvd.seam;
   
  +import java.math.BigDecimal;
  +
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.Date;
  @@ -53,13 +55,10 @@
       @Out(scope=ScopeType.BUSINESS_PROCESS, required=false)
       long orderId;
       @Out(scope=ScopeType.BUSINESS_PROCESS, required=false)
  -    float amount;
  +    BigDecimal amount = BigDecimal.ZERO;
       @Out(value="customer",scope=ScopeType.BUSINESS_PROCESS, required=false)
       String customerName;
   
  -//     public void startCheckout() {
  -//     }
  -
       @Begin(nested=true, pageflow="checkout") 
       public void createOrder() {
           currentOrder = new Order();
  
  
  
  1.16      +24 -19    jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/Order.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Order.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/Order.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- Order.java	21 Nov 2006 03:20:31 -0000	1.15
  +++ Order.java	17 Dec 2006 07:20:05 -0000	1.16
  @@ -7,6 +7,7 @@
   package com.jboss.dvd.seam;
   
   import java.io.Serializable;
  +import java.math.BigDecimal;
   import java.util.ArrayList;
   import java.util.Date;
   import java.util.List;
  @@ -29,12 +30,14 @@
   {
       public enum Status {OPEN,CANCELLED,PROCESSING,SHIPPED}
   
  +    public static BigDecimal TAX_RATE = new BigDecimal(".0825");
  +
       long orderId;
       Date orderDate;
       Customer customer;
  -    float netAmount;
  -    float tax;
  -    float totalAmount;
  +    BigDecimal netAmount = BigDecimal.ZERO;
  +    BigDecimal tax = BigDecimal.ZERO;
  +    BigDecimal totalAmount = BigDecimal.ZERO;
       List<OrderLine> orderLines = new ArrayList<OrderLine>();
       Status status = Status.OPEN;
       String trackingNumber;
  @@ -105,26 +108,26 @@
       }
   
       @Column(name="NETAMOUNT",nullable=false,precision=12,scale=2)
  -    public float getNetAmount() {
  +    public BigDecimal getNetAmount() {
           return netAmount;
       }
  -    public void setNetAmount(float amount) {
  +    public void setNetAmount(BigDecimal amount) {
           this.netAmount = amount;
       }
   
       @Column(name="TAX",nullable=false,precision=12,scale=2)
  -    public float getTax() {
  +    public BigDecimal getTax() {
           return tax;
       }
  -    public void setTax(float amount) {
  +    public void setTax(BigDecimal amount) {
           this.tax = amount;
       }
   
       @Column(name="TOTALAMOUNT",nullable=false,precision=12,scale=2)
  -    public float getTotalAmount() {
  +    public BigDecimal getTotalAmount() {
           return totalAmount;
       }
  -    public void setTotalAmount(float amount) {
  +    public void setTotalAmount(BigDecimal amount) {
           this.totalAmount = amount;
       }
   
  @@ -150,17 +153,19 @@
       }
   
       public void calculateTotals() {
  -        float total = 0;
  +        BigDecimal total = BigDecimal.ZERO;
           
           int index = 1;
           for (OrderLine line: orderLines) {
               line.setPosition(index++);
  -            total += round(line.getProduct().getPrice() * line.getQuantity());
  +            total = total.add(line.getProduct().getPrice().multiply(new BigDecimal(line.getQuantity())));
           }
           
  -        setNetAmount(round(total));
  -        setTax(round(getNetAmount() * .0825));
  -        setTotalAmount(round(getNetAmount() + getTax()));
  +        setNetAmount(total);
  +
  +        
  +        setTax(round(getNetAmount().multiply(TAX_RATE)));
  +        setTotalAmount(getNetAmount().add(getTax()));
       }
   
       public void cancel() {
  @@ -176,12 +181,12 @@
           setTrackingNumber(tracking);
       }
       
  -    // just make sure it only has 2 digits
  -    private float round(double val) {
  -        int tmp = (int) (val * 100.0 + .5);
  -        float res = (float) (tmp / 100.0);
   
  -        return res;
  +    /**
  +     * round a positive big decimal to 2 decimal points
  +     */
  +    private BigDecimal round(BigDecimal amount) {
  +        return new BigDecimal(amount.movePointRight(2).add(new BigDecimal(".5")).toBigInteger()).movePointLeft(2);
       }
   
       @Transient
  
  
  
  1.3       +9 -5      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/OrderApprovalDecision.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OrderApprovalDecision.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/OrderApprovalDecision.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- OrderApprovalDecision.java	11 Jan 2006 03:42:20 -0000	1.2
  +++ OrderApprovalDecision.java	17 Dec 2006 07:20:05 -0000	1.3
  @@ -1,13 +1,17 @@
   package com.jboss.dvd.seam;
   
  +import java.math.BigDecimal;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
   
   @Name("orderApproval")
   public class OrderApprovalDecision {
  -   @In float amount;
  +    private static BigDecimal CUTOFF = new BigDecimal(100);
  +
  +    @In BigDecimal amount;
  +    
      public String getHowLargeIsOrder()
      {
  -      return amount > 100 ? "large order" : "small order";
  +        return (amount.compareTo(CUTOFF) >= 0) ? "large order" : "small order";
      }
   }
  
  
  
  1.11      +4 -3      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/Product.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Product.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/Product.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- Product.java	14 May 2006 18:48:54 -0000	1.10
  +++ Product.java	17 Dec 2006 07:20:05 -0000	1.11
  @@ -7,6 +7,7 @@
   package com.jboss.dvd.seam;
   
   import java.io.Serializable;
  +import java.math.BigDecimal;
   import java.util.List;
   import java.util.Set;
   
  @@ -32,7 +33,7 @@
       String title;
       String description;
       String imageURL;
  -    float price;
  +    BigDecimal price = BigDecimal.ZERO;
   
       List<Actor>    actors;
       Set<Category> categories;
  @@ -114,10 +115,10 @@
       }
   
       @Column(name="PRICE",nullable=false,precision=12,scale=2)
  -    public float getPrice() {
  +    public BigDecimal getPrice() {
           return price;
       }
  -    public void setPrice(float price) {
  +    public void setPrice(BigDecimal price) {
           this.price=price;
       }
   }
  
  
  
  1.6       +4 -3      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/ShoppingCart.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ShoppingCart.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/ShoppingCart.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ShoppingCart.java	7 May 2006 02:10:51 -0000	1.5
  +++ ShoppingCart.java	17 Dec 2006 07:20:05 -0000	1.6
  @@ -6,6 +6,7 @@
    */ 
   package com.jboss.dvd.seam;
   
  +import java.math.BigDecimal;
   import java.util.List;
   import java.util.Map;
   
  @@ -17,9 +18,9 @@
       public List<OrderLine> getCart();
       public Map getCartSelection();
   
  -    public float getSubtotal();
  -    public float getTax();
  -    public float getTotal();
  +    public BigDecimal getSubtotal();
  +    public BigDecimal getTax();
  +    public BigDecimal getTotal();
   
       public void updateCart();
       public void resetCart();
  
  
  
  1.26      +5 -3      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/ShoppingCartBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ShoppingCartBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/ShoppingCartBean.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- ShoppingCartBean.java	10 May 2006 01:45:40 -0000	1.25
  +++ ShoppingCartBean.java	17 Dec 2006 07:20:05 -0000	1.26
  @@ -8,6 +8,8 @@
   
   import static org.jboss.seam.ScopeType.SESSION;
   
  +import java.math.BigDecimal;
  +
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.HashMap;
  @@ -55,15 +57,15 @@
           return cartSelection;
       }
   
  -    public float getSubtotal() {
  +    public BigDecimal getSubtotal() {
           return cartOrder.getNetAmount();
       }
   
  -    public float getTax() {
  +    public BigDecimal getTax() {
           return cartOrder.getTax();
       }
   
  -    public float getTotal() {
  +    public BigDecimal getTotal() {
           return cartOrder.getTotalAmount();
       }
   
  
  
  
  1.3       +5 -4      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/StoreManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StoreManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/StoreManager.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- StoreManager.java	15 May 2006 21:33:28 -0000	1.2
  +++ StoreManager.java	17 Dec 2006 07:20:05 -0000	1.3
  @@ -6,6 +6,7 @@
    */ 
   package com.jboss.dvd.seam;
   
  +import java.math.BigDecimal;
   import javax.ejb.Local;
   
   @Local
  @@ -14,5 +15,5 @@
       public long    getNumberOrders();
       public long    getUnitsSold();
       public long    getTotalInventory();
  -    public double getTotalSales();
  +    public BigDecimal getTotalSales();
   }
  
  
  
  1.10      +7 -6      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/StoreManagerBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StoreManagerBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/StoreManagerBean.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- StoreManagerBean.java	1 Dec 2006 13:27:52 -0000	1.9
  +++ StoreManagerBean.java	17 Dec 2006 07:20:05 -0000	1.10
  @@ -6,6 +6,7 @@
    */ 
   package com.jboss.dvd.seam;
   
  +import java.math.BigDecimal;
   import java.io.Serializable;
   
   import javax.ejb.Stateless;
  @@ -30,14 +31,14 @@
               .getSingleResult();
       }
   
  -    public double getTotalSales() {
  +    public BigDecimal getTotalSales() {
           try {
  -            Double totalSales = (Double) em.createQuery("select sum(o.totalAmount) from Order o where o.status != :status")
  +            BigDecimal totalSales = (BigDecimal) em.createQuery("select sum(o.totalAmount) from Order o where o.status != :status")
                            .setParameter("status", Order.Status.CANCELLED)
                            .getSingleResult();
  -            return totalSales==null ? 0.0 : totalSales;
  +            return totalSales==null ? BigDecimal.ZERO : totalSales;
           } catch (NoResultException e) {
  -            return 0.0;
  +            return BigDecimal.ZERO;
           }
       }
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 17 06:38:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 17 Dec 2006 06:38:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r59067 -
	branches/Branch_4_2/server/src/etc/conf/default
Message-ID: <E1GvuLv-0006U9-Q5@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-17 06:38:45 -0500 (Sun, 17 Dec 2006)
New Revision: 59067

Modified:
   branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml
Log:
JBAS-3892, revert to JBossTM until we decide whether JBossTS will be used and which version of it

Modified: branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml
===================================================================
--- branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml	2006-12-16 13:03:07 UTC (rev 59066)
+++ branches/Branch_4_2/server/src/etc/conf/default/jboss-service.xml	2006-12-17 11:38:45 UTC (rev 59067)
@@ -305,7 +305,6 @@
    <!-- ==================================================================== -->
    <!-- Transactions                                                         -->
    <!-- ==================================================================== -->
-
    <!-- The configurable Xid factory.  For use with Oracle, set pad to true -->
    <mbean code="org.jboss.tm.XidFactory"
       name="jboss:service=XidFactory">
@@ -314,32 +313,23 @@
 
    <!--
       | The fast in-memory transaction manager.
-      | Deprecated in JBossAS v4.2. Use JBossTS JTA instead.
-    - ->
+    -->
    <mbean code="org.jboss.tm.TransactionManagerService"
       name="jboss:service=TransactionManager"
       xmbean-dd="resource:xmdesc/TransactionManagerService-xmbean.xml">
       <attribute name="TransactionTimeout">300</attribute>
-      <!- - set to false to disable transaction demarcation over IIOP - ->
+      <!-- set to false to disable transaction demarcation over IIOP -->
       <attribute name="GlobalIdsEnabled">true</attribute>
       <depends optional-attribute-name="XidFactory">jboss:service=XidFactory</depends>
 
-      <!- - Transaction Integrity Checking - ->
-      <!- - Force a rollback if another thread is associated with the transaction at commit - ->
-      <!- - <depends optional-attribute-name="TransactionIntegrityFactory" 
+      <!-- Transaction Integrity Checking -->
+      <!-- Force a rollback if another thread is associated with the transaction at commit -->
+      <!--depends optional-attribute-name="TransactionIntegrityFactory" 
                proxy-type="org.jboss.tm.integrity.TransactionIntegrityFactory">
          <mbean code="org.jboss.tm.integrity.FailIncompleteTransaction"
                 name="jboss:service=TransactionManager,plugin=TransactionIntegrity"/>
-      </depends> - ->
+      </depends-->
    </mbean>
-   -->
-   
-   <!-- JBoss Transactions JTA -->
-   <mbean code="com.arjuna.ats.jbossatx.jta.TransactionManagerService"
-      name="jboss:service=TransactionManager">
-      <attribute name="TransactionTimeout">300</attribute>
-   </mbean>
-   
    <!--
       | UserTransaction support.
     -->



From jboss-cvs-commits at lists.jboss.org  Sun Dec 17 06:39:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 17 Dec 2006 06:39:20 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59068 - branches/Branch_4_2/build
Message-ID: <E1GvuMS-0006US-2m@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-17 06:39:17 -0500 (Sun, 17 Dec 2006)
New Revision: 59068

Modified:
   branches/Branch_4_2/build/build-distr.xml
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
JBAS-3892, revert to JBossTM until we decide whether JBossTS will be used and which version of it

Modified: branches/Branch_4_2/build/build-distr.xml
===================================================================
--- branches/Branch_4_2/build/build-distr.xml	2006-12-17 11:38:45 UTC (rev 59067)
+++ branches/Branch_4_2/build/build-distr.xml	2006-12-17 11:39:17 UTC (rev 59068)
@@ -1104,7 +1104,7 @@
       </fileset>
     </copy>
 
-    <!-- copy binary release of JBossTS from thirdparty repo -->
+    <!-- copy binary release of JBossTS from thirdparty repo
     <copy todir="${install.all.lib}" filtering="no">
       <fileset dir="${project.thirdparty}/jboss/jbossts/lib/">
         <include name="jbossjta.jar"/>
@@ -1113,7 +1113,7 @@
       </fileset>
     </copy>
     <copy todir="${install.all.conf}" filtering="no" file="${project.thirdparty}/jboss/jbossts/resources/jbossjta-properties.xml"/>
-
+    -->
     <!-- Copy the generated client libraries -->
     <mkdir dir="${install.client}"/>
     <copy todir="${install.client}" filtering="no">

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-17 11:38:45 UTC (rev 59067)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-17 11:39:17 UTC (rev 59068)
@@ -60,7 +60,7 @@
       <componentref name="apache-fileupload" version="1.0"/>
       <componentref name="apache-httpclient" version="2.0.2"/>
       <componentref name="apache-jaxme" version="0.2-cvs"/>
-      <componentref name="apache-log4j" version="1.2.8"/>
+      <componentref name="apache-log4j" version="1.2.14"/>
       <componentref name="apache-logging" version="1.0.5.GA-jboss"/>
       <componentref name="apache-myfaces" version="1.1.4"/>
       <componentref name="apache-pool" version="1.0.1"/>
@@ -91,7 +91,7 @@
       <componentref name="jboss/common" version="1.0.0.GA"/>
       <componentref name="jboss/dom4j-jarjar" version="1.6.1"/>
       <componentref name="jboss/jbossretro-rt" version="1.0.4.GA"/>
-      <componentref name="jboss/jbossts" version="4.2.2.GA"/>
+      <!--<componentref name="jboss/jbossts" version="4.2.2.GA"/>-->
       <componentref name="jboss/jbossws" version="1.0.4.GA"/>
       <componentref name="jboss/jbossws14" version="1.0.4.GA"/>
       <componentref name="jboss/jboss-ws4ee" version="4.0.4.SP1"/>



From gavin.king at jboss.com  Sun Dec 17 07:54:09 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 07:54:09 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvvWr-0007pg-Qd@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 07:54:09

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  renamed elements
  
  Revision  Changes    Path
  1.9       +7 -7      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- pages-1.1.dtd	17 Dec 2006 02:39:17 -0000	1.8
  +++ pages-1.1.dtd	17 Dec 2006 12:54:09 -0000	1.9
  @@ -9,7 +9,7 @@
   <!ELEMENT pages (page*)>
   <!ATTLIST pages no-conversation-view-id CDATA #IMPLIED>
   
  -<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|navigation)*>
  +<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|action-navigation)*>
   <!ATTLIST page action CDATA #IMPLIED>
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
  @@ -24,14 +24,14 @@
   <!ATTLIST param converter CDATA #IMPLIED>
   <!ATTLIST param converterId CDATA #IMPLIED>
   
  -<!ELEMENT navigation (case*,default?)>
  -<!ATTLIST navigation action CDATA #IMPLIED>
  -<!ATTLIST navigation outcome CDATA #IMPLIED>
  +<!ELEMENT action-navigation (outcome*,null-outcome?)>
  +<!ATTLIST action-navigation action CDATA #IMPLIED>
  +<!ATTLIST action-navigation outcome CDATA #IMPLIED>
   
  -<!ELEMENT case ((begin-conversation|end-conversation)?,(render|redirect))>
  -<!ATTLIST case outcome CDATA #REQUIRED>
  +<!ELEMENT outcome ((begin-conversation|end-conversation)?,(render|redirect))>
  +<!ATTLIST outcome value CDATA #REQUIRED>
   
  -<!ELEMENT default ((begin-conversation|end-conversation)?,(render|redirect))>
  +<!ELEMENT null-outcome ((begin-conversation|end-conversation)?,(render|redirect))>
   
   <!ELEMENT begin-conversation EMPTY>
   <!ATTLIST begin-conversation join (true|false) "false">
  
  
  


From gavin.king at jboss.com  Sun Dec 17 07:54:09 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 07:54:09 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GvvWr-0007pn-U6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 07:54:09

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  renamed elements
  
  Revision  Changes    Path
  1.63      +4 -4      jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.62
  retrieving revision 1.63
  diff -u -b -r1.62 -r1.63
  --- Pages.java	17 Dec 2006 02:39:17 -0000	1.62
  +++ Pages.java	17 Dec 2006 12:54:09 -0000	1.63
  @@ -133,7 +133,7 @@
            page.getPageParameters().add( parsePageParameter(param) );
         }
         
  -      List<Element> moreChildren = element.elements("navigation");
  +      List<Element> moreChildren = element.elements("action-navigation");
         for (Element fromAction: moreChildren)
         {
            parseNavigation(page, fromAction);
  @@ -223,13 +223,13 @@
         {
            navigation.setOutcomeValueBinding(Expressions.instance().createValueBinding(outcomeExpression));
         }
  -      List<Element> cases = element.elements("case");
  +      List<Element> cases = element.elements("outcome");
         for (Element childElement: cases)
         {
            Page.Case caze = parseCase(childElement);
  -         navigation.getCases().put( childElement.attributeValue("outcome"), caze );
  +         navigation.getCases().put( childElement.attributeValue("value"), caze );
         }
  -      Element childElement = element.element("default");
  +      Element childElement = element.element("null-outcome");
         if (childElement!=null)
         {
            navigation.setDefaultCase(parseCase(childElement));
  
  
  


From gavin.king at jboss.com  Sun Dec 17 08:12:56 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 08:12:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1Gvvp2-0008M6-EE@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 08:12:56

  Modified:    examples/booking/resources/WEB-INF  pages.xml
  Log:
  improves the loggedininterceptor
  updated to new element names
  
  Revision  Changes    Path
  1.8       +52 -66    jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- pages.xml	17 Dec 2006 01:04:51 -0000	1.7
  +++ pages.xml	17 Dec 2006 13:12:56 -0000	1.8
  @@ -4,16 +4,48 @@
   
   <pages no-conversation-view-id="/main.xhtml">
   
  +    <page view-id="/register.xhtml">
  +        <action-navigation outcome="#{register.registered}">
  +            <outcome value="true">
  +                <redirect view-id="/home.xhtml"/>
  +            </outcome>
  +        </action-navigation>
  +    </page>
  +
  +    <page view-id="/home.xhtml">
  +        <action-navigation outcome="#{empty loggedIn}">
  +            <outcome value="false">
  +                <redirect view-id="/main.xhtml"/>
  +            </outcome>
  +        </action-navigation>
  +    </page>
  +    
  +    <page view-id="/password.xhtml">
  +        <action-navigation outcome="#{changePassword.changed}">
  +            <outcome value="true">
  +                <redirect view-id="/main.xhtml"/>
  +            </outcome>
  +        </action-navigation>
  +    </page>
  +
  +    <page view-id="/main.xhtml">
  +        <action-navigation action="#{hotelBooking.selectHotel(hot)}">
  +            <null-outcome>
  +                <redirect view-id="/hotel.xhtml"/>
  +            </null-outcome>
  +        </action-navigation>
  +    </page>
  +
   	<page view-id="/hotel.xhtml" 
             conversation-required="true">
             
           <description>View hotel: #{hotel.name}</description>
           
  -        <navigation action="#{hotelBooking.bookHotel}">
  -            <default>
  +        <action-navigation action="#{hotelBooking.bookHotel}">
  +            <null-outcome>
                   <redirect view-id="/book.xhtml"/>
  -            </default>
  -        </navigation>
  +            </null-outcome>
  +        </action-navigation>
           
       </page>
   
  @@ -22,11 +54,11 @@
             
           <description>Book hotel: #{hotel.name}</description>
           
  -        <navigation outcome="#{hotelBooking.bookingValid}">
  -            <case outcome="true">
  +        <action-navigation outcome="#{hotelBooking.bookingValid}">
  +            <outcome value="true">
                   <redirect view-id="/confirm.xhtml"/>
  -            </case>
  -        </navigation>
  +            </outcome>
  +        </action-navigation>
           
       </page>
   
  @@ -35,73 +67,27 @@
             
           <description>Confirm booking: #{booking.description}</description>
           
  -        <navigation action="#{hotelBooking.confirm}">
  -            <default>
  -                <redirect view-id="/main.xhtml"/>
  -            </default>
  -        </navigation>
  -        
  -    </page>
  -    
  -    <page view-id="/password.xhtml">
  -        
  -        <navigation outcome="#{changePassword.changed}">
  -            <case outcome="true">
  +        <action-navigation action="#{hotelBooking.confirm}">
  +            <null-outcome>
                   <redirect view-id="/main.xhtml"/>
  -            </case>
  -        </navigation>
  -        
  -    </page>
  -
  -    <page view-id="/register.xhtml">
  -        
  -        <navigation outcome="#{register.registered}">
  -            <case outcome="true">
  -                <redirect view-id="/home.xhtml"/>
  -            </case>
  -        </navigation>
  -        
  -    </page>
  -
  -    <page view-id="/home.xhtml">
  -        
  -        <navigation outcome="#{loggedIn==null}">
  -            <case outcome="false">
  -                <redirect view-id="/main.xhtml"/>
  -            </case>
  -        </navigation>
  -        
  -    </page>
  -    
  -    <page view-id="/main.xhtml">
  -        
  -        <navigation action="#{hotelBooking.selectHotel(hot)}">
  -            <default>
  -                <redirect view-id="/hotel.xhtml"/>
  -            </default>
  -        </navigation>
  +            </null-outcome>
  +        </action-navigation>
   
       </page>
   
       <page view-id="*">
       
  -        <navigation action="#{logout.logout}">
  -            <default>
  +        <action-navigation action="#{logout.logout}">
  +            <null-outcome>
                   <redirect view-id="/home.xhtml"/>
  -            </default>
  -        </navigation>
  +            </null-outcome>
  +        </action-navigation>
   
  -        <navigation action="#{hotelBooking.cancel}">
  -            <default>
  +        <action-navigation action="#{hotelBooking.cancel}">
  +            <null-outcome>
                   <redirect view-id="/main.xhtml"/>
  -            </default>
  -        </navigation>
  -
  -        <navigation>
  -            <case outcome="login">
  -                <redirect view-id="/home.xhtml"/>
  -            </case>
  -        </navigation>
  +            </null-outcome>
  +        </action-navigation>
           
       </page>
   
  
  
  


From gavin.king at jboss.com  Sun Dec 17 08:12:56 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 08:12:56 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1Gvvp2-0008MD-IC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 08:12:56

  Modified:    examples/booking/src/org/jboss/seam/example/booking 
                        LoggedInInterceptor.java
  Log:
  improves the loggedininterceptor
  updated to new element names
  
  Revision  Changes    Path
  1.14      +11 -32    jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoggedInInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- LoggedInInterceptor.java	17 Dec 2006 01:04:51 -0000	1.13
  +++ LoggedInInterceptor.java	17 Dec 2006 13:12:56 -0000	1.14
  @@ -1,24 +1,16 @@
  -//$Id: LoggedInInterceptor.java,v 1.13 2006/12/17 01:04:51 gavin Exp $
  +//$Id: LoggedInInterceptor.java,v 1.14 2006/12/17 13:12:56 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.lang.reflect.Method;
   
  -import javax.faces.event.PhaseId;
   import javax.interceptor.AroundInvoke;
   import javax.interceptor.InvocationContext;
   
  +import org.jboss.seam.InterceptorType;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.contexts.Lifecycle;
  -import org.jboss.seam.interceptors.BijectionInterceptor;
  -import org.jboss.seam.interceptors.BusinessProcessInterceptor;
  -import org.jboss.seam.interceptors.ConversationInterceptor;
  -import org.jboss.seam.interceptors.RemoveInterceptor;
  -import org.jboss.seam.interceptors.ValidationInterceptor;
  -
  - at Interceptor(around={BijectionInterceptor.class, ValidationInterceptor.class, 
  -                     ConversationInterceptor.class, BusinessProcessInterceptor.class},
  -             within=RemoveInterceptor.class)
  +
  + at Interceptor(type=InterceptorType.CLIENT)
   public class LoggedInInterceptor
   {
   
  @@ -26,19 +18,6 @@
      public Object checkLoggedIn(InvocationContext invocation) throws Exception
      {
         boolean isLoggedIn = Contexts.getSessionContext().get("loggedIn")!=null;
  -      if ( Lifecycle.getPhaseId()==PhaseId.INVOKE_APPLICATION )
  -      {
  -         if (isLoggedIn) 
  -         {
  -            return invocation.proceed();
  -         }
  -         else 
  -         {
  -            return "login";
  -         }
  -      }
  -      else
  -      {
            if ( isLoggedIn )
            {
               return invocation.proceed();
  @@ -46,7 +25,8 @@
            else
            {
               Method method = invocation.getMethod();
  -            if ( method.getReturnType().equals(void.class) )
  +         Class<?> returnType = method.getReturnType();
  +         if ( returnType.equals(void.class) || returnType.equals(String.class) )
               {
                  return null;
               }
  @@ -56,6 +36,5 @@
               }
            }
         }
  -   }
   
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 08:12:56 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 08:12:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view  ...
Message-ID: <E1Gvvp2-0008MK-Ng@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 08:12:56

  Modified:    examples/booking/view  register.xhtml
  Log:
  improves the loggedininterceptor
  updated to new element names
  
  Revision  Changes    Path
  1.20      +1 -1      jboss-seam/examples/booking/view/register.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: register.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/register.xhtml,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- register.xhtml	14 Nov 2006 05:50:59 -0000	1.19
  +++ register.xhtml	17 Dec 2006 13:12:56 -0000	1.20
  @@ -106,7 +106,7 @@
   						<div class="label">&#160;</div>
   						<div class="input">
   							<h:commandButton id="register" value="Register" action="#{register.register}"/>&#160;
  -							<s:button id="cancel" value="Cancel" action="login"/>
  +							<s:button id="cancel" value="Cancel" view="/home.xhtml"/>
   						</div>
   					</div>
   					
  
  
  


From gavin.king at jboss.com  Sun Dec 17 09:07:46 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 09:07:46 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1Gvwg6-0000uI-TF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 09:07:46

  Modified:    examples/booking/resources/WEB-INF  pages.xml
  Log:
  better impl of login/out
  
  Revision  Changes    Path
  1.9       +14 -4     jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- pages.xml	17 Dec 2006 13:12:56 -0000	1.8
  +++ pages.xml	17 Dec 2006 14:07:46 -0000	1.9
  @@ -13,8 +13,8 @@
       </page>
   
       <page view-id="/home.xhtml">
  -        <action-navigation outcome="#{empty loggedIn}">
  -            <outcome value="false">
  +        <action-navigation outcome="#{login.loggedIn}">
  +            <outcome value="true">
                   <redirect view-id="/main.xhtml"/>
               </outcome>
           </action-navigation>
  @@ -28,12 +28,22 @@
           </action-navigation>
       </page>
   
  -    <page view-id="/main.xhtml">
  +    <page view-id="/main.xhtml" 
  +          action="#{login.validateLogin}">
  +        
  +        <action-navigation action="#{login.validateLogin}"
  +                          outcome="#{login.loggedIn}">
  +            <outcome value="false">
  +                <redirect view-id="/home.xhtml"/>
  +            </outcome>
  +        </action-navigation>
  +        
           <action-navigation action="#{hotelBooking.selectHotel(hot)}">
               <null-outcome>
                   <redirect view-id="/hotel.xhtml"/>
               </null-outcome>
           </action-navigation>
  +        
       </page>
   
   	<page view-id="/hotel.xhtml" 
  @@ -77,7 +87,7 @@
       
       <page view-id="*">
       
  -        <action-navigation action="#{logout.logout}">
  +        <action-navigation action="#{login.logout}">
               <null-outcome>
                   <redirect view-id="/home.xhtml"/>
               </null-outcome>
  
  
  


From gavin.king at jboss.com  Sun Dec 17 09:07:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 09:07:47 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1Gvwg7-0000uV-1C@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 09:07:47

  Modified:    examples/booking/src/org/jboss/seam/example/booking     
                        LoggedInInterceptor.java Login.java
                        LoginAction.java
  Removed:     examples/booking/src/org/jboss/seam/example/booking     
                        Logout.java LogoutAction.java
  Log:
  better impl of login/out
  
  Revision  Changes    Path
  1.15      +4 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoggedInInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- LoggedInInterceptor.java	17 Dec 2006 13:12:56 -0000	1.14
  +++ LoggedInInterceptor.java	17 Dec 2006 14:07:46 -0000	1.15
  @@ -1,4 +1,4 @@
  -//$Id: LoggedInInterceptor.java,v 1.14 2006/12/17 13:12:56 gavin Exp $
  +//$Id: LoggedInInterceptor.java,v 1.15 2006/12/17 14:07:46 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.lang.reflect.Method;
  @@ -6,9 +6,9 @@
   import javax.interceptor.AroundInvoke;
   import javax.interceptor.InvocationContext;
   
  +import org.jboss.seam.Component;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.annotations.Interceptor;
  -import org.jboss.seam.contexts.Contexts;
   
   @Interceptor(type=InterceptorType.CLIENT)
   public class LoggedInInterceptor
  @@ -17,8 +17,8 @@
      @AroundInvoke
      public Object checkLoggedIn(InvocationContext invocation) throws Exception
      {
  -      boolean isLoggedIn = Contexts.getSessionContext().get("loggedIn")!=null;
  -      if ( isLoggedIn )
  +      Login login = (Login) Component.getInstance(LoginAction.class);
  +      if ( login.isLoggedIn() )
         {
            return invocation.proceed();
         }
  
  
  
  1.3       +6 -1      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Login.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Login.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Login.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Login.java	17 Dec 2006 01:04:51 -0000	1.2
  +++ Login.java	17 Dec 2006 14:07:46 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: Login.java,v 1.2 2006/12/17 01:04:51 gavin Exp $
  +//$Id: Login.java,v 1.3 2006/12/17 14:07:46 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -7,4 +7,9 @@
   public interface Login
   {
      public void login();
  +   public void logout();
  +   public void validateLogin();
  +   public boolean isLoggedIn();
  +   
  +   public void destroy();
   }
  
  
  
  1.18      +43 -8     jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoginAction.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- LoginAction.java	17 Dec 2006 01:04:51 -0000	1.17
  +++ LoginAction.java	17 Dec 2006 14:07:46 -0000	1.18
  @@ -1,29 +1,42 @@
  -//$Id: LoginAction.java,v 1.17 2006/12/17 01:04:51 gavin Exp $
  +//$Id: LoginAction.java,v 1.18 2006/12/17 14:07:46 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.util.List;
   
  -import javax.ejb.Stateless;
  +import javax.ejb.Remove;
  +import javax.ejb.Stateful;
   import javax.persistence.EntityManager;
   import javax.persistence.PersistenceContext;
   
  +import org.jboss.seam.ScopeType;
  +import org.jboss.seam.Seam;
  +import org.jboss.seam.annotations.Destroy;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Out;
  -import org.jboss.seam.contexts.Contexts;
  +import org.jboss.seam.annotations.Scope;
  +import org.jboss.seam.annotations.Synchronized;
   import org.jboss.seam.core.FacesMessages;
   
  - at Stateless
  + at Stateful
  + at Scope(ScopeType.SESSION)
  + at Synchronized
   @Name("login")
   public class LoginAction implements Login
   {
      
  -   @In @Out
  +   @In(required=false) 
  +   @Out(required=false)
      private User user;
      
      @PersistenceContext
      private EntityManager em;
   
  +   @In
  +   private FacesMessages facesMessages;
  +   
  +   private boolean loggedIn;
  +
      public void login()
      {
         List<User> results = em.createQuery("select u from User u where u.username=:username and u.password=:password")
  @@ -33,15 +46,37 @@
         
         if ( results.size()==0 )
         {
  -         FacesMessages.instance().add("Invalid login");
  +         facesMessages.add("Invalid login");
         }
         else
         {
            user = results.get(0);
  -         Contexts.getSessionContext().set("loggedIn", true);
  -         FacesMessages.instance().add("Welcome, #{user.name}");
  +         loggedIn = true;
  +         facesMessages.add("Welcome, #{user.name}");
  +      }
  +      
  +   }
  +
  +   public void logout()
  +   {
  +      loggedIn = false;
  +      Seam.invalidateSession();
         }
         
  +   public void validateLogin()
  +   {
  +      if ( !loggedIn )
  +      {
  +         facesMessages.add("Please log in first");
      }
  +   }
  +
  +   public boolean isLoggedIn()
  +   {
  +      return loggedIn;
  +   }
  +   
  +   @Destroy @Remove
  +   public void destroy() {}
   
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 09:07:47 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 09:07:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view  ...
Message-ID: <E1Gvwg7-0000uc-5i@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 09:07:47

  Modified:    examples/booking/view  template.xhtml
  Log:
  better impl of login/out
  
  Revision  Changes    Path
  1.11      +1 -1      jboss-seam/examples/booking/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/template.xhtml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- template.xhtml	17 Dec 2006 01:04:51 -0000	1.10
  +++ template.xhtml	17 Dec 2006 14:07:47 -0000	1.11
  @@ -18,7 +18,7 @@
               Welcome #{user.name}
               | <s:link id="search" view="/main.xhtml" value="Search" propagation="none"/>
               | <s:link id="settings" view="/password.xhtml" value="Settings" propagation="none"/>
  -            | <s:link id="logout" action="#{logout.logout}" value="Logout"/>
  +            | <s:link id="logout" action="#{login.logout}" value="Logout"/>
   		</div>
   	</div>
   	<div id="container">
  
  
  


From gavin.king at jboss.com  Sun Dec 17 09:09:18 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 09:09:18 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gvwha-0000uu-Qs@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 09:09:18

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  navigation from page actions
  
  Revision  Changes    Path
  1.64      +2 -2      jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.63
  retrieving revision 1.64
  diff -u -b -r1.63 -r1.64
  --- Pages.java	17 Dec 2006 12:54:09 -0000	1.63
  +++ Pages.java	17 Dec 2006 14:09:18 -0000	1.64
  @@ -497,10 +497,10 @@
               fromAction = methodBinding.getExpressionString();
               result = true;
               outcome = toString( methodBinding.invoke() );
  +            handleOutcome(facesContext, outcome, fromAction);
            }
         }
  -      
  -      if (outcome!=null)
  +      else
         {
            handleOutcome(facesContext, outcome, fromAction);
         }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:03:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:03:29 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GvxY1-0001vX-Sj@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:03:29

  Modified:    src/main/org/jboss/seam/core   Conversation.java Page.java
  Log:
  fix a bug in <begin-conversation/>
  
  Revision  Changes    Path
  1.32      +15 -3     jboss-seam/src/main/org/jboss/seam/core/Conversation.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Conversation.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Conversation.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- Conversation.java	27 Nov 2006 03:09:35 -0000	1.31
  +++ Conversation.java	17 Dec 2006 15:03:29 -0000	1.32
  @@ -194,11 +194,16 @@
         }
         else
         {
  -         Manager.instance().beginConversation( Seam.getComponentName(Conversation.class) );
  +         reallyBegin();
            return true;
         }
      }
      
  +   private void reallyBegin()
  +   {
  +      Manager.instance().beginConversation( Seam.getComponentName(Conversation.class) );
  +   }
  +   
      /**
       * Start a nested conversation.
       * 
  @@ -221,8 +226,9 @@
       * 
       * @param join if a conversation is active, should we join it?
       * @param nested if a conversation is active, should we start a new nested conversation?
  +    * @return true if a new long-running conversation was begun
       */
  -   public void begin(boolean join, boolean nested)
  +   public boolean begin(boolean join, boolean nested)
      {
         boolean longRunningConversation = Manager.instance().isLongRunningOrNestedConversation();
         if ( !join && !nested && longRunningConversation  )
  @@ -231,11 +237,17 @@
         }
         else if ( !longRunningConversation )
         {
  -         begin();
  +         reallyBegin();
  +         return true;
         }
         else if (nested)
         {
            beginNested();
  +         return true;
  +      }
  +      else
  +      {
  +         return false;
         }
      }
      
  
  
  
  1.10      +10 -7     jboss-seam/src/main/org/jboss/seam/core/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Page.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- Page.java	17 Dec 2006 00:25:14 -0000	1.9
  +++ Page.java	17 Dec 2006 15:03:29 -0000	1.10
  @@ -383,17 +383,20 @@
         }
         if ( isBeginConversation )
         {
  -         Conversation.instance().begin(join, nested);
  +         boolean begun = Conversation.instance().begin(join, nested);
  +         if (begun)
  +         {
            if (flushMode!=null)
            {
               Conversation.instance().changeFlushMode(flushMode);
            }
  -         if (pageflow!=null)
  +            if ( pageflow!=null  )
            {
               Pageflow.instance().begin(pageflow);
            }
         }
      }
  +   }
   
      public FlushModeType getFlushMode()
      {
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:03:30 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:03:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pageflow  ...
Message-ID: <E1GvxY2-0001ve-14@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:03:30

  Modified:    src/main/org/jboss/seam/pageflow  Page.java
  Log:
  fix a bug in <begin-conversation/>
  
  Revision  Changes    Path
  1.8       +4 -0      jboss-seam/src/main/org/jboss/seam/pageflow/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pageflow/Page.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- Page.java	11 Nov 2006 02:42:11 -0000	1.7
  +++ Page.java	17 Dec 2006 15:03:29 -0000	1.8
  @@ -41,6 +41,10 @@
      public void read(Element pageElement, JpdlXmlReader jpdlXmlReader) 
      {
         viewId = pageElement.attributeValue("view-id");
  +      if (viewId==null)
  +      {
  +         throw new IllegalStateException("must specify view-id for <page/> node");
  +      }
         noConversationViewId = pageElement.attributeValue("no-conversation-view-id");
         backEnabled = "enabled".equals( pageElement.attributeValue("back") );
         switchEnabled = !"disabled".equals( pageElement.attributeValue("switch") );
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:05:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:05:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/numberguess/resources   ...
Message-ID: <E1Gvxa5-0001y0-Ef@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:05:37

  Modified:    examples/numberguess/resources   .gpd.pageflow.jpdl.xml
                        pageflow.jpdl.xml
  Log:
  giveup
  
  Revision  Changes    Path
  1.10      +15 -1     jboss-seam/examples/numberguess/resources/.gpd.pageflow.jpdl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: .gpd.pageflow.jpdl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/resources/.gpd.pageflow.jpdl.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- .gpd.pageflow.jpdl.xml	16 Nov 2006 15:36:22 -0000	1.9
  +++ .gpd.pageflow.jpdl.xml	17 Dec 2006 15:05:37 -0000	1.10
  @@ -1,10 +1,14 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<pageflow-diagram name="numberGuess" width="769" height="397">
  +<pageflow-diagram name="numberGuess" width="816" height="595">
     <node name="displayGuess" x="255" y="47" width="140" height="40">
       <transition name="guess">
         <label x="-41" y="-23"/>
       </transition>
  +    <transition name="giveup">
  +      <label x="-15" y="13"/>
  +      <bendpoint w1="217" h1="-33" w2="-203" h2="-29"/>
  +    </transition>
     </node>
     <node name="evaluateGuess" x="59" y="149" width="180" height="40">
       <transition name="true">
  @@ -22,6 +26,16 @@
         <label x="17" y="-23"/>
       </transition>
     </node>
  +  <node name="giveup" x="675" y="43" width="140" height="40">
  +    <transition name="yes">
  +      <label x="39" y="-84"/>
  +      <bendpoint w1="-50" h1="170" w2="189" h2="-68"/>
  +    </transition>
  +    <transition name="no">
  +      <label x="-6" y="7"/>
  +      <bendpoint w1="-201" h1="27" w2="219" h2="23"/>
  +    </transition>
  +  </node>
     <node name="win" x="78" y="280" width="140" height="40"/>
     <node name="lose" x="436" y="281" width="140" height="40"/>
   </pageflow-diagram>
  
  
  
  1.8       +8 -1      jboss-seam/examples/numberguess/resources/pageflow.jpdl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pageflow.jpdl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/resources/pageflow.jpdl.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- pageflow.jpdl.xml	16 Nov 2006 15:36:22 -0000	1.7
  +++ pageflow.jpdl.xml	17 Dec 2006 15:05:37 -0000	1.8
  @@ -16,6 +16,7 @@
         <transition name="guess" to="evaluateGuess">
            <action expression="#{numberGuess.guess}"/>
         </transition>
  +      <transition name="giveup" to="giveup"/>
      </start-page>
      
      <decision name="evaluateGuess" expression="#{numberGuess.correctGuess}">
  @@ -28,6 +29,12 @@
         <transition name="false" to="displayGuess"/>
      </decision>
      
  +   <page name="giveup" view-id="/giveup.jspx">
  +      <redirect/>
  +      <transition name="yes" to="lose"/>
  +      <transition name="no" to="displayGuess"/>
  +   </page>
  +   
      <page name="win" view-id="/win.jspx">
         <redirect/>
         <end-conversation/>
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:05:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:05:37 -0500
Subject: [jboss-cvs] jboss-seam/examples/numberguess/view   ...
Message-ID: <E1Gvxa5-0001yA-IB@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:05:37

  Modified:    examples/numberguess/view   numberGuess.jspx
  Added:       examples/numberguess/view   giveup.jspx
  Log:
  giveup
  
  Revision  Changes    Path
  1.4       +1 -0      jboss-seam/examples/numberguess/view/numberGuess.jspx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: numberGuess.jspx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/numberguess/view/numberGuess.jspx,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- numberGuess.jspx	16 Nov 2006 23:19:26 -0000	1.3
  +++ numberGuess.jspx	17 Dec 2006 15:05:37 -0000	1.4
  @@ -33,6 +33,7 @@
           </h:inputText>
   		<h:commandButton value="Guess" action="guess"/>
           <s:button value="Cheat" view="/confirm.jspx"/>
  +        <s:button value="Give up" action="giveup"/>
   		<br/>
           <h:message for="guess" style="color: red"/>
   	  </h:form>
  
  
  
  1.1      date: 2006/12/17 15:05:37;  author: gavin;  state: Exp;jboss-seam/examples/numberguess/view/giveup.jspx
  
  Index: giveup.jspx
  ===================================================================
  <?xml version="1.0"?>
  <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page" 
            xmlns:h="http://java.sun.com/jsf/html"
            xmlns:f="http://java.sun.com/jsf/core"
            xmlns="http://www.w3.org/1999/xhtml"
            version="2.0">
    <jsp:output doctype-root-element="html"
                doctype-public="-//W3C//DTD XHTML 1.0 Transitional//EN"
                doctype-system="http://www.w3c.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"/>
    <jsp:directive.page contentType="text/html"/>
    <head>
      <title>Do you really want to give up now?</title>
    </head>
    <body>
      <h1>Do you really want to give up now?</h1>
      <f:view>
      <h:form>
        You still have <h:outputText value="#{numberGuess.remainingGuesses}"/> guesses remaining.
        <h:commandButton value="Yes" action="yes"/>
        <h:commandButton value="No" action="no"/>
      </h:form>
      </f:view>
    </body>
  </jsp:root>
  
  
  


From validimir.ralev at jboss.com  Sun Dec 17 10:12:02 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sun, 17 Dec 2006 10:12:02 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib ...
Message-ID: <E1GvxgI-00026j-RB@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/17 10:12:02

  Modified:    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib    
                        installer.jar standalone-compiler.jar
                        uninstaller.jar uninstaller-ext.jar
  Log:
  http://jira.jboss.com/jira/browse/JBINSTALL-153
  http://jira.jboss.com/jira/browse/JBINSTALL-157
  
  Revision  Changes    Path
  1.2       +129 -125  /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/installer.jar
  
  	<<Binary file>>
  
  
  1.2       +2083 -2143/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar
  
  	<<Binary file>>
  
  
  1.2       +54 -50    /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller.jar
  
  	<<Binary file>>
  
  
  1.2       +49 -45    /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller-ext.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Sun Dec 17 10:31:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:31:49 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/resources   ...
Message-ID: <E1GvxzR-0002Qi-Sv@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:31:49

  Modified:    examples/dvdstore/resources   .gpd.checkout.jpdl.xml
                        checkout.jpdl.xml
  Log:
  cancel button
  
  Revision  Changes    Path
  1.5       +3 -3      jboss-seam/examples/dvdstore/resources/.gpd.checkout.jpdl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: .gpd.checkout.jpdl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/.gpd.checkout.jpdl.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- .gpd.checkout.jpdl.xml	1 Jul 2006 10:12:56 -0000	1.4
  +++ .gpd.checkout.jpdl.xml	17 Dec 2006 15:31:49 -0000	1.5
  @@ -1,13 +1,13 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<pageflow-diagram name="checkout" width="815" height="674">
  +<pageflow-diagram name="checkout" width="808" height="631">
     <node name="start" x="152" y="55" width="140" height="40">
       <transition>
         <label x="5" y="-10"/>
       </transition>
     </node>
     <node name="confirm" x="152" y="152" width="140" height="40">
  -    <transition name="update">
  +    <transition name="cancel">
         <label x="23" y="-10"/>
       </transition>
       <transition name="purchase">
  @@ -15,5 +15,5 @@
       </transition>
     </node>
     <node name="complete" x="68" y="274" width="140" height="40"/>
  -  <node name="continue" x="245" y="273" width="140" height="40"/>
  +  <node name="cancel" x="245" y="273" width="140" height="40"/>
   </pageflow-diagram>
  
  
  
  1.6       +2 -2      jboss-seam/examples/dvdstore/resources/checkout.jpdl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: checkout.jpdl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/resources/checkout.jpdl.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- checkout.jpdl.xml	1 Jul 2006 10:12:56 -0000	1.5
  +++ checkout.jpdl.xml	17 Dec 2006 15:31:49 -0000	1.6
  @@ -8,7 +8,7 @@
       <page name="confirm" view-id="/confirm.xhtml"
             no-conversation-view-id="/checkout.xhtml">
           <redirect/>
  -        <transition name="update"   to="continue"/> 
  +        <transition name="cancel"   to="cancel"/> 
           <transition name="purchase" to="complete">
               <action expression="#{checkout.submitOrder}" />
           </transition>
  @@ -19,7 +19,7 @@
           <end-conversation/>
       </page>    
   
  -    <page name="continue">
  +    <page name="cancel" view-id="/browse.xhtml">
           <end-conversation/>
       </page>
   
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:31:50 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:31:50 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/web  ...
Message-ID: <E1GvxzS-0002Qp-0h@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:31:50

  Modified:    examples/dvdstore/web  confirm.xhtml
  Log:
  cancel button
  
  Revision  Changes    Path
  1.11      +3 -1      jboss-seam/examples/dvdstore/web/confirm.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: confirm.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/web/confirm.xhtml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- confirm.xhtml	14 Dec 2006 12:23:24 -0000	1.10
  +++ confirm.xhtml	17 Dec 2006 15:31:49 -0000	1.11
  @@ -82,6 +82,8 @@
                           
                           <h:form>
                               <h:commandButton action="purchase" value="Confirm" />
  +                            &#160;
  +                            <h:commandButton action="cancel" value="Cancel" />
                           </h:form>
                       </div>
                   </div>
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:32:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:32:04 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pageflow  ...
Message-ID: <E1Gvxzg-0002RM-CO@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:32:04

  Modified:    src/main/org/jboss/seam/pageflow  Page.java
  Log:
  error
  
  Revision  Changes    Path
  1.9       +1 -1      jboss-seam/src/main/org/jboss/seam/pageflow/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pageflow/Page.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- Page.java	17 Dec 2006 15:03:29 -0000	1.8
  +++ Page.java	17 Dec 2006 15:32:04 -0000	1.9
  @@ -43,7 +43,7 @@
         viewId = pageElement.attributeValue("view-id");
         if (viewId==null)
         {
  -         throw new IllegalStateException("must specify view-id for <page/> node");
  +         throw new IllegalStateException("must specify view-id for <page/> node: " + pageElement.attributeValue("name"));
         }
         noConversationViewId = pageElement.attributeValue("no-conversation-view-id");
         backEnabled = "enabled".equals( pageElement.attributeValue("back") );
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:32:30 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:32:30 -0500
Subject: [jboss-cvs] jboss-seam/src/test/misc/org/jboss/seam/test  ...
Message-ID: <E1Gvy06-0002Re-Oq@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:32:30

  Modified:    src/test/misc/org/jboss/seam/test  PageflowTest.java
  Log:
  fix
  
  Revision  Changes    Path
  1.4       +1 -1      jboss-seam/src/test/misc/org/jboss/seam/test/PageflowTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PageflowTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/PageflowTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PageflowTest.java	25 Oct 2006 15:37:36 -0000	1.3
  +++ PageflowTest.java	17 Dec 2006 15:32:30 -0000	1.4
  @@ -84,7 +84,7 @@
         "    <redirect/>" +
         "    <end-conversation/>" +
         "  </page>" +    
  -      "  <page name='continue'>" +
  +      "  <page name='continue' view-id='/browse.xhtml'>" +
         "    <end-conversation/>" +
         "  </page>" +
         "</pageflow-definition>"
  
  
  


From gavin.king at jboss.com  Sun Dec 17 10:59:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 10:59:39 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test
	...
Message-ID: <E1GvyQN-0002oL-TA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 10:59:39

  Modified:    examples/booking/src/org/jboss/seam/example/booking/test   
                        BookingTest.java ChangePasswordTest.java
                        LoginTest.java
  Log:
  update tests
  
  Revision  Changes    Path
  1.43      +4 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BookingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- BookingTest.java	17 Dec 2006 01:26:02 -0000	1.42
  +++ BookingTest.java	17 Dec 2006 15:59:39 -0000	1.43
  @@ -1,4 +1,4 @@
  -//$Id: BookingTest.java,v 1.42 2006/12/17 01:26:02 gavin Exp $
  +//$Id: BookingTest.java,v 1.43 2006/12/17 15:59:39 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import java.util.Calendar;
  @@ -26,13 +26,13 @@
      public void testBookHotel() throws Exception
      {
         
  -      new FacesRequest()
  -      {
  +      new FacesRequest() {
  +         
            @Override
            protected void invokeApplication() throws Exception
            {
  -            Contexts.getSessionContext().set("loggedIn", true);
               Contexts.getSessionContext().set("user", new User("Gavin King", "foobar", "gavin"));
  +            invokeMethod("#{login.login}");
            }
            
         }.run();
  
  
  
  1.15      +6 -6      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/ChangePasswordTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChangePasswordTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/ChangePasswordTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- ChangePasswordTest.java	17 Dec 2006 01:26:02 -0000	1.14
  +++ ChangePasswordTest.java	17 Dec 2006 15:59:39 -0000	1.15
  @@ -1,4 +1,4 @@
  -//$Id: ChangePasswordTest.java,v 1.14 2006/12/17 01:26:02 gavin Exp $
  +//$Id: ChangePasswordTest.java,v 1.15 2006/12/17 15:59:39 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import org.jboss.seam.contexts.Contexts;
  @@ -19,8 +19,8 @@
            @Override
            protected void invokeApplication() throws Exception
            {
  -            Contexts.getSessionContext().set("loggedIn", true);
               Contexts.getSessionContext().set("user", new User("Gavin King", "foobar", "gavin"));
  +            invokeMethod("#{login.login}");
            }
            
         }.run();
  @@ -41,7 +41,7 @@
               assert getValue("#{user.username}").equals("gavin");
               assert getValue("#{user.password}").equals("foobar");
               assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn").equals(true);
  +            assert getValue("#{login.loggedIn}").equals(true);
   
            }
            
  @@ -69,7 +69,7 @@
               assert getValue("#{user.username}").equals("gavin");
               assert getValue("#{user.password}").equals("foobar");
               assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn").equals(true);
  +            assert getValue("#{login.loggedIn}").equals(true);
            }
            
         }.run();
  @@ -96,7 +96,7 @@
               assert getValue("#{user.username}").equals("gavin");
               assert getValue("#{user.password}").equals("xxxyyy");
               assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn").equals(true);
  +            assert getValue("#{login.loggedIn}").equals(true);
   
            }
            
  @@ -125,7 +125,7 @@
               assert getValue("#{user.username}").equals("gavin");
               assert getValue("#{user.password}").equals("foobar");
               assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn").equals(true);
  +            assert getValue("#{login.loggedIn}").equals(true);
   
            }
            
  
  
  
  1.24      +6 -28     jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/LoginTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/test/LoginTest.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- LoginTest.java	17 Dec 2006 01:26:02 -0000	1.23
  +++ LoginTest.java	17 Dec 2006 15:59:39 -0000	1.24
  @@ -1,8 +1,7 @@
  -//$Id: LoginTest.java,v 1.23 2006/12/17 01:26:02 gavin Exp $
  +//$Id: LoginTest.java,v 1.24 2006/12/17 15:59:39 gavin Exp $
   package org.jboss.seam.example.booking.test;
   
   import org.jboss.seam.Seam;
  -import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Manager;
   import org.jboss.seam.mock.SeamTest;
   import org.testng.annotations.Test;
  @@ -20,15 +19,7 @@
            protected void invokeApplication()
            {
               assert !isSessionInvalid();
  -            invokeMethod("#{hotelBooking.bookHotel}");
  -         }
  -
  -         @Override
  -         protected void renderResponse()
  -         {
  -            assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn")==null;
  -
  +            assert getValue("#{login.loggedIn}").equals(false);
            }
            
         }.run();
  @@ -56,8 +47,7 @@
               assert getValue("#{user.username}").equals("gavin");
               assert getValue("#{user.password}").equals("foobar");
               assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn").equals(true);
  -
  +            assert getValue("#{login.loggedIn}").equals(true);
            }
            
         }.run();
  @@ -68,20 +58,7 @@
            protected void invokeApplication()
            {
               assert !isSessionInvalid();
  -            try
  -            {
  -               invokeMethod("#{hotelBooking.bookHotel}");
  -               assert false;
  -            }
  -            catch (Exception e) {}
  -         }
  -
  -         @Override
  -         protected void renderResponse()
  -         {
  -            assert !Manager.instance().isLongRunningConversation();
  -            assert Contexts.getSessionContext().get("loggedIn").equals(true);
  -
  +            assert getValue("#{login.loggedIn}").equals(true);
            }
            
         }.run();
  @@ -93,13 +70,14 @@
            {
               assert !Manager.instance().isLongRunningConversation();
               assert !isSessionInvalid();
  -            invokeMethod("#{logout.logout}");
  +            invokeMethod("#{login.logout}");
               assert Seam.isSessionInvalid();
            }
   
            @Override
            protected void renderResponse()
            {
  +            assert getValue("#{login.loggedIn}").equals(false);
               assert Seam.isSessionInvalid();
            }
            
  
  
  


From gavin.king at jboss.com  Sun Dec 17 11:04:09 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 11:04:09 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GvyUj-00033O-EH@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 11:04:09

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  any-outcome
  
  Revision  Changes    Path
  1.10      +2 -2      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- pages-1.1.dtd	17 Dec 2006 12:54:09 -0000	1.9
  +++ pages-1.1.dtd	17 Dec 2006 16:04:09 -0000	1.10
  @@ -24,13 +24,13 @@
   <!ATTLIST param converter CDATA #IMPLIED>
   <!ATTLIST param converterId CDATA #IMPLIED>
   
  -<!ELEMENT action-navigation (outcome*,null-outcome?)>
  +<!ELEMENT action-navigation (null-outcome?,outcome*,any-outcome?)>
   <!ATTLIST action-navigation action CDATA #IMPLIED>
   <!ATTLIST action-navigation outcome CDATA #IMPLIED>
   
   <!ELEMENT outcome ((begin-conversation|end-conversation)?,(render|redirect))>
   <!ATTLIST outcome value CDATA #REQUIRED>
  -
  +<!ELEMENT any-outcome ((begin-conversation|end-conversation)?,(render|redirect))>
   <!ELEMENT null-outcome ((begin-conversation|end-conversation)?,(render|redirect))>
   
   <!ELEMENT begin-conversation EMPTY>
  
  
  


From gavin.king at jboss.com  Sun Dec 17 11:04:09 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 11:04:09 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GvyUj-00033Y-Hs@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 11:04:09

  Modified:    src/main/org/jboss/seam/core   Page.java Pages.java
  Log:
  any-outcome
  
  Revision  Changes    Path
  1.11      +15 -5     jboss-seam/src/main/org/jboss/seam/core/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Page.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- Page.java	17 Dec 2006 15:03:29 -0000	1.10
  +++ Page.java	17 Dec 2006 16:04:09 -0000	1.11
  @@ -99,20 +99,21 @@
      {
         private ValueBinding<Object> outcomeValueBinding;
         private Map<String, Case> cases = new HashMap<String, Case>();
  -      private Case defaultCase;
  +      private Case nullCase;
  +      private Case anyCase;
         
         public Map<String, Case> getCases()
         {
            return cases;
         }
         
  -      void setDefaultCase(Case defaultCase)
  +      void setNullCase(Case defaultCase)
         {
  -         this.defaultCase = defaultCase;
  +         this.nullCase = defaultCase;
         }
  -      public Case getDefaultCase()
  +      public Case getNullCase()
         {
  -         return defaultCase;
  +         return nullCase;
         }
         
         void setOutcomeValueBinding(ValueBinding<Object> outcomeValueBinding)
  @@ -123,6 +124,15 @@
         {
            return outcomeValueBinding;
         }
  +
  +      public Case getAnyCase()
  +      {
  +         return anyCase;
  +      }
  +      void setAnyCase(Case elseCase)
  +      {
  +         this.anyCase = elseCase;
  +      }
      }
      
      public static final class Case
  
  
  
  1.65      +32 -8     jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.64
  retrieving revision 1.65
  diff -u -b -r1.64 -r1.65
  --- Pages.java	17 Dec 2006 14:09:18 -0000	1.64
  +++ Pages.java	17 Dec 2006 16:04:09 -0000	1.65
  @@ -142,6 +142,11 @@
   
      private Page parsePage(Element element, String viewId)
      {
  +      if (viewId==null)
  +      {
  +         throw new IllegalStateException("Must specify view-id for <page/> declaration");
  +      }
  +      
         if ( viewId.endsWith("*") )
         {
            wildcardViewIds.add(viewId);
  @@ -221,18 +226,28 @@
         String outcomeExpression = element.attributeValue("outcome");
         if (outcomeExpression!=null)
         {
  -         navigation.setOutcomeValueBinding(Expressions.instance().createValueBinding(outcomeExpression));
  +         navigation.setOutcomeValueBinding( Expressions.instance().createValueBinding(outcomeExpression) );
         }
         List<Element> cases = element.elements("outcome");
         for (Element childElement: cases)
         {
            Page.Case caze = parseCase(childElement);
  -         navigation.getCases().put( childElement.attributeValue("value"), caze );
  +         String value = childElement.attributeValue("value");
  +         if (value==null)
  +         {
  +            throw new IllegalStateException("Must specify value for <outcome/> declaration");
  +         }
  +         navigation.getCases().put(value, caze);
         }
  -      Element childElement = element.element("null-outcome");
  +      Element childElement = element.element("any-outcome");
         if (childElement!=null)
         {
  -         navigation.setDefaultCase(parseCase(childElement));
  +         navigation.setAnyCase( parseCase(childElement) );
  +      }
  +      childElement = element.element("null-outcome");
  +      if (childElement!=null)
  +      {
  +         navigation.setNullCase( parseCase(childElement) );
         }
         
         String expression = element.attributeValue("action");
  @@ -340,10 +355,19 @@
                     outcome = value==null ? null : value.toString();
                  }
                  
  -               Page.Case caze = outcome==null ?
  -                  //JSF navhandler says ignore all rules when null outcome
  -                  navigation.getDefaultCase() :
  -                  navigation.getCases().get(outcome);
  +               Page.Case caze;
  +               if (outcome==null) 
  +               {
  +                  //JSF navhandler says ignore all rules when null outcome.
  +                  //so we have a special case for that
  +                  caze = navigation.getNullCase();
  +               }
  +               else
  +               {
  +                  caze = navigation.getCases().get(outcome);
  +                  if (caze==null) caze = navigation.getAnyCase();
  +               }
  +               
                  if (caze!=null)
                  {
                     //TODO: begin/end conversation, etc!!
  
  
  


From gavin.king at jboss.com  Sun Dec 17 12:45:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 12:45:37 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core     ...
Message-ID: <E1Gw04v-0004kU-Ly@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 12:45:37

  Modified:    src/main/org/jboss/seam/core     Events.java Exceptions.java
                        Page.java Pages.java
  Log:
  JBSEAM-607, begin-conversation/end-conversation on an outcome
  
  Revision  Changes    Path
  1.17      +4 -10     jboss-seam/src/main/org/jboss/seam/core/Events.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Events.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Events.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- Events.java	16 Dec 2006 14:06:57 -0000	1.16
  +++ Events.java	17 Dec 2006 17:45:37 -0000	1.17
  @@ -10,12 +10,8 @@
   import java.util.List;
   import java.util.Map;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
  -import org.dom4j.Document;
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  -import org.dom4j.io.SAXReader;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -27,8 +23,10 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions.MethodBinding;
   import org.jboss.seam.core.Init.ObserverMethod;
  -import org.jboss.seam.util.DTDEntityResolver;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.Resources;
  +import org.jboss.seam.util.XML;
   
   @Scope(ScopeType.APPLICATION)
   @Intercept(NEVER)
  @@ -52,11 +50,7 @@
         else
         {
            log.info("reading events.xml");
  -         SAXReader saxReader = new SAXReader();
  -         saxReader.setEntityResolver( new DTDEntityResolver() );
  -         saxReader.setMergeAdjacentText(true);
  -         Document doc = saxReader.read(stream);
  -         List<Element> elements = doc.getRootElement().elements("event");
  +         List<Element> elements = XML.getRootElement(stream).elements("event");
            for (Element event: elements)
            {
               String type = event.attributeValue("type");
  
  
  
  1.20      +2 -8      jboss-seam/src/main/org/jboss/seam/core/Exceptions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Exceptions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Exceptions.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- Exceptions.java	17 Dec 2006 02:39:17 -0000	1.19
  +++ Exceptions.java	17 Dec 2006 17:45:37 -0000	1.20
  @@ -10,9 +10,7 @@
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseId;
   
  -import org.dom4j.Document;
   import org.dom4j.Element;
  -import org.dom4j.io.SAXReader;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
  @@ -28,11 +26,11 @@
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
  -import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Reflections;
   import org.jboss.seam.util.Resources;
   import org.jboss.seam.util.Strings;
   import org.jboss.seam.util.Transactions;
  +import org.jboss.seam.util.XML;
   
   /**
    * Holds metadata for pages defined in pages.xml, including
  @@ -74,11 +72,7 @@
         else
         {
            log.info("reading exceptions.xml");
  -         SAXReader saxReader = new SAXReader();
  -         saxReader.setEntityResolver( new DTDEntityResolver() );
  -         saxReader.setMergeAdjacentText(true);
  -         Document doc = saxReader.read(stream);
  -         List<Element> elements = doc.getRootElement().elements("exception");
  +         List<Element> elements = XML.getRootElement(stream).elements("exception");
            for (Element exception: elements)
            {
               String className = exception.attributeValue("class");
  
  
  
  1.12      +111 -146  jboss-seam/src/main/org/jboss/seam/core/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Page.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- Page.java	17 Dec 2006 16:04:09 -0000	1.11
  +++ Page.java	17 Dec 2006 17:45:37 -0000	1.12
  @@ -14,23 +14,23 @@
   import org.jboss.seam.core.Expressions.ValueBinding;
   
   /**
  - * Metadata about page actions, page parameters, resource bundle
  - * etc, for a particular JSF view id.
  + * Metadata about page actions, page parameters, action navigation,
  + * resource bundle, etc, for a particular JSF view id.
    */
   public final class Page
   {
  -   public static final class PageParameter
  +   public static final class Param
      {
  -      PageParameter(String name)
  -      {
  -         this.name = name;
  -      }
  -      
         private final String name;
         private ValueBinding valueBinding;
         private ValueBinding converterValueBinding;
         private String converterId;
         
  +      Param(String name)
  +      {
  +         this.name = name;
  +      }
  +      
         Converter getConverter()
         {
            if (converterId!=null)
  @@ -95,25 +95,25 @@
   
      }
      
  -   public static final class Navigation
  +   public static final class ActionNavigation
      {
         private ValueBinding<Object> outcomeValueBinding;
  -      private Map<String, Case> cases = new HashMap<String, Case>();
  -      private Case nullCase;
  -      private Case anyCase;
  +      private Map<String, Outcome> outcomes = new HashMap<String, Outcome>();
  +      private Outcome nullOutcome;
  +      private Outcome anyOutcome;
         
  -      public Map<String, Case> getCases()
  +      public Map<String, Outcome> getOutcomes()
         {
  -         return cases;
  +         return outcomes;
         }
         
  -      void setNullCase(Case defaultCase)
  +      void setNullOutcome(Outcome outcome)
         {
  -         this.nullCase = defaultCase;
  +         this.nullOutcome = outcome;
         }
  -      public Case getNullCase()
  +      public Outcome getNullOutcome()
         {
  -         return nullCase;
  +         return nullOutcome;
         }
         
         void setOutcomeValueBinding(ValueBinding<Object> outcomeValueBinding)
  @@ -125,19 +125,40 @@
            return outcomeValueBinding;
         }
   
  -      public Case getAnyCase()
  +      public Outcome getAnyOutcome()
         {
  -         return anyCase;
  +         return anyOutcome;
         }
  -      void setAnyCase(Case elseCase)
  +      void setAnyOutcome(Outcome outcome)
         {
  -         this.anyCase = elseCase;
  +         this.anyOutcome = outcome;
         }
      }
      
  -   public static final class Case
  +   public static final class Outcome
  +   {
  +      private NavigationHandler navigationHandler;
  +      private ConversationControl conversationControl = new ConversationControl();
  +
  +      protected NavigationHandler getNavigationHandler()
      {
  -      private Result result;
  +         return navigationHandler;
  +      }
  +
  +      protected void setNavigationHandler(NavigationHandler result)
  +      {
  +         this.navigationHandler = result;
  +      }
  +
  +      protected ConversationControl getConversationControl()
  +      {
  +         return conversationControl;
  +      }
  +   }
  +   
  +   public static class ConversationControl
  +   {
  +   
         private boolean isBeginConversation;
         private boolean isEndConversation;
         private boolean join;
  @@ -145,65 +166,92 @@
         private FlushModeType flushMode;
         private String pageflow;
         
  -      void setResult(Result result)
  -      {
  -         this.result = result;
  -      }
  -      Result getResult()
  +      public boolean isBeginConversation()
         {
  -         return result;
  +         return isBeginConversation;
         }
  +   
         void setBeginConversation(boolean isBeginConversation)
         {
            this.isBeginConversation = isBeginConversation;
         }
  -      boolean isBeginConversation()
  +   
  +      public boolean isEndConversation()
         {
  -         return isBeginConversation;
  +         return isEndConversation;
         }
  +   
         void setEndConversation(boolean isEndConversation)
         {
            this.isEndConversation = isEndConversation;
         }
  -      boolean isEndConversation()
  +      
  +      public void beginOrEndConversation()
         {
  -         return isEndConversation;
  -      }
  -      void setJoin(boolean join)
  +         if ( isEndConversation )
         {
  -         this.join = join;
  +            Conversation.instance().end();
         }
  -      boolean isJoin()
  +         if ( isBeginConversation )
         {
  -         return join;
  +            boolean begun = Conversation.instance().begin(join, nested);
  +            if (begun)
  +            {
  +               if (flushMode!=null)
  +               {
  +                  Conversation.instance().changeFlushMode(flushMode);
         }
  -      void setNested(boolean nested)
  +               if ( pageflow!=null  )
         {
  -         this.nested = nested;
  +                  Pageflow.instance().begin(pageflow);
         }
  -      boolean isNested()
  +            }
  +         }
  +      }
  +   
  +      public FlushModeType getFlushMode()
         {
  -         return nested;
  +         return flushMode;
         }
  +   
         void setFlushMode(FlushModeType flushMode)
         {
            this.flushMode = flushMode;
         }
  -      FlushModeType getFlushMode()
  +   
  +      public boolean isJoin()
         {
  -         return flushMode;
  +         return join;
         }
  -      void setPageflow(String pageflow)
  +   
  +      void setJoin(boolean join)
         {
  -         this.pageflow = pageflow;
  +         this.join = join;
  +      }
  +   
  +      public boolean isNested()
  +      {
  +         return nested;
  +      }
  +   
  +      void setNested(boolean nested)
  +      {
  +         this.nested = nested;
         }
  -      String getPageflow()
  +   
  +      public String getPageflow()
         {
            return pageflow;
         }
  +   
  +      void setPageflow(String pageflow)
  +      {
  +         this.pageflow = pageflow;
      }
      
  -   public interface Result
  +   }
  +
  +   public static interface NavigationHandler
      {
         public void navigate(FacesContext context);
      }
  @@ -216,16 +264,11 @@
      private String noConversationViewId;
      private String resourceBundleName;
      private boolean switchEnabled = true;
  -   private List<PageParameter> pageParameters = new ArrayList<PageParameter>();
  -   private Map<String, Navigation> navigations = new HashMap<String, Navigation>();
  -   private Navigation defaultNavigation;
  -   private boolean isBeginConversation;
  -   private boolean isEndConversation;
  -   private boolean join;
  -   private boolean nested;
  -   private FlushModeType flushMode;
  -   private String pageflow;
  +   private List<Param> pageParameters = new ArrayList<Param>();
  +   private Map<String, ActionNavigation> navigations = new HashMap<String, ActionNavigation>();
  +   private ActionNavigation defaultNavigation;
      private boolean conversationRequired;
  +   private ConversationControl conversationControl = new ConversationControl();
      
      Page(String viewId)
      {
  @@ -350,12 +393,12 @@
         return switchEnabled;
      }
   
  -   public List<Page.PageParameter> getPageParameters()
  +   public List<Page.Param> getPageParameters()
      {
         return pageParameters;
      }
   
  -   public Map<String, Page.Navigation> getNavigations()
  +   public Map<String, Page.ActionNavigation> getNavigations()
      {
         return navigations;
      }
  @@ -365,89 +408,6 @@
         return description!=null;
      }
   
  -   public boolean isBeginConversation()
  -   {
  -      return isBeginConversation;
  -   }
  -
  -   void setBeginConversation(boolean isBeginConversation)
  -   {
  -      this.isBeginConversation = isBeginConversation;
  -   }
  -
  -   public boolean isEndConversation()
  -   {
  -      return isEndConversation;
  -   }
  -
  -   void setEndConversation(boolean isEndConversation)
  -   {
  -      this.isEndConversation = isEndConversation;
  -   }
  -   
  -   public void beginOrEndConversation()
  -   {
  -      if ( isEndConversation )
  -      {
  -         Conversation.instance().end();
  -      }
  -      if ( isBeginConversation )
  -      {
  -         boolean begun = Conversation.instance().begin(join, nested);
  -         if (begun)
  -         {
  -            if (flushMode!=null)
  -            {
  -               Conversation.instance().changeFlushMode(flushMode);
  -            }
  -            if ( pageflow!=null  )
  -            {
  -               Pageflow.instance().begin(pageflow);
  -            }
  -         }
  -      }
  -   }
  -
  -   public FlushModeType getFlushMode()
  -   {
  -      return flushMode;
  -   }
  -
  -   void setFlushMode(FlushModeType flushMode)
  -   {
  -      this.flushMode = flushMode;
  -   }
  -
  -   public boolean isJoin()
  -   {
  -      return join;
  -   }
  -
  -   void setJoin(boolean join)
  -   {
  -      this.join = join;
  -   }
  -
  -   public boolean isNested()
  -   {
  -      return nested;
  -   }
  -
  -   void setNested(boolean nested)
  -   {
  -      this.nested = nested;
  -   }
  -
  -   public String getPageflow()
  -   {
  -      return pageflow;
  -   }
  -
  -   void setPageflow(String pageflow)
  -   {
  -      this.pageflow = pageflow;
  -   }
  -
      public boolean isConversationRequired()
      {
         return conversationRequired;
  @@ -458,14 +418,19 @@
         this.conversationRequired = conversationRequired;
      }
   
  -   public Navigation getDefaultNavigation()
  +   public ActionNavigation getDefaultNavigation()
      {
         return defaultNavigation;
      }
   
  -   void setDefaultNavigation(Navigation defaultActionOutcomeMapping)
  +   void setDefaultNavigation(ActionNavigation defaultActionOutcomeMapping)
      {
         this.defaultNavigation = defaultActionOutcomeMapping;
      }
   
  +   protected ConversationControl getConversationControl()
  +   {
  +      return conversationControl;
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.66      +317 -265  jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.65
  retrieving revision 1.66
  diff -u -b -r1.65 -r1.66
  --- Pages.java	17 Dec 2006 16:04:09 -0000	1.65
  +++ Pages.java	17 Dec 2006 17:45:37 -0000	1.66
  @@ -19,10 +19,8 @@
   import javax.faces.context.FacesContext;
   import javax.faces.convert.Converter;
   
  -import org.dom4j.Document;
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  -import org.dom4j.io.SAXReader;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
  @@ -34,12 +32,13 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions.MethodBinding;
   import org.jboss.seam.core.Expressions.ValueBinding;
  -import org.jboss.seam.core.Page.PageParameter;
  +import org.jboss.seam.core.Page.ConversationControl;
  +import org.jboss.seam.core.Page.Param;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
  -import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Parameters;
   import org.jboss.seam.util.Resources;
  +import org.jboss.seam.util.XML;
   
   /**
    * Holds metadata for pages defined in pages.xml, including
  @@ -86,246 +85,13 @@
         }
      }
   
  -   private void parse(InputStream stream)
  -   {
  -      Element root = getDocumentRoot(stream);
  -      if (noConversationViewId==null) //let the setting in components.xml override the pages.xml
  -      {
  -         noConversationViewId = root.attributeValue("no-conversation-view-id");
  -      }
  -      List<Element> elements = root.elements("page");
  -      for (Element page: elements)
  -      {
  -         parse( page, page.attributeValue("view-id") );
  -      } 
  -   }
  -
  -   private void parse(InputStream stream, String viewId)
  -   {
  -      parse( getDocumentRoot(stream), viewId );
  -   }
  -
  -   private Element getDocumentRoot(InputStream stream)
  -   {
  -      Document doc;
  -      SAXReader saxReader = new SAXReader();
  -      saxReader.setEntityResolver( new DTDEntityResolver() );
  -      saxReader.setMergeAdjacentText(true);
  -      try
  -      {
  -         doc = saxReader.read(stream);
  -      }
  -      catch (DocumentException de)
  -      {
  -         throw new RuntimeException(de);
  -      }
  -      Element root = doc.getRootElement();
  -      return root;
  -   }
  -
  -   private void parse(Element element, String viewId)
  -   {
  -      Page page = parsePage(element, viewId);
  -      
  -      List<Element> children = element.elements("param");
  -      for (Element param: children)
  -      {
  -         page.getPageParameters().add( parsePageParameter(param) );
  -      }
  -      
  -      List<Element> moreChildren = element.elements("action-navigation");
  -      for (Element fromAction: moreChildren)
  -      {
  -         parseNavigation(page, fromAction);
  -      }
  -   }
  -
  -   private Page parsePage(Element element, String viewId)
  -   {
  -      if (viewId==null)
  -      {
  -         throw new IllegalStateException("Must specify view-id for <page/> declaration");
  -      }
  -      
  -      if ( viewId.endsWith("*") )
  -      {
  -         wildcardViewIds.add(viewId);
  -      }
  -      Page page = new Page(viewId);
  -      pagesByViewId.put(viewId, page);
  -      
  -      page.setSwitchEnabled( !"disabled".equals( element.attributeValue("switch") ) );
  -      
  -      Element optionalElement = element.element("description");
  -      String description = optionalElement==null ? 
  -               element.getTextTrim() : optionalElement.getTextTrim();
  -      if (description!=null && description.length()>0)
  -      {
  -         page.setDescription(description);
  -      }
  -      
  -      String timeoutString = element.attributeValue("timeout");
  -      if (timeoutString!=null)
  -      {
  -         page.setTimeout(Integer.parseInt(timeoutString));
  -      }
  -      
  -      page.setNoConversationViewId( element.attributeValue("no-conversation-view-id") );
  -      page.setConversationRequired( "true".equals( element.attributeValue("conversation-required") ) );
  -      
  -      String action = element.attributeValue("action");
  -      if (action!=null)
  -      {
  -         if ( action.startsWith("#{") )
  -         {
  -            MethodBinding methodBinding = Expressions.instance().createMethodBinding(action);
  -            page.setAction(methodBinding);
  -         }
  -         else
  -         {
  -            page.setOutcome(action);
  -         }
  -      }
  -      
  -      Element endConversation = element.element("end-conversation");
  -      if ( endConversation!=null )
  -      {
  -         page.setEndConversation(true);
  -      }
  -      
  -      Element beginConversation = element.element("begin-conversation");
  -      if ( beginConversation!=null )
  -      {
  -         page.setBeginConversation(true);
  -         page.setJoin( "true".equals( beginConversation.attributeValue("join") ) );
  -         page.setNested( "true".equals( beginConversation.attributeValue("nested") ) );
  -         page.setPageflow( beginConversation.attributeValue("pageflow") );
  -         String flushMode = beginConversation.attributeValue("flush-mode");
  -         if (flushMode!=null)
  -         {
  -            page.setFlushMode( FlushModeType.valueOf( flushMode.toUpperCase() ) );
  -         }
  -      }
  -      
  -      if ( page.isBeginConversation() && page.isEndConversation() )
  -      {
  -         throw new IllegalStateException("cannot use both <begin-conversation/> and <end-conversation/>");
  -      }
  -      
  -      String bundle = element.attributeValue("bundle");
  -      if (bundle!=null)
  -      {
  -         page.setResourceBundleName(bundle);
  -      }
  -      return page;
  -   }
  -
  -   private void parseNavigation(Page entry, Element element)
  -   {
  -      Page.Navigation navigation = new Page.Navigation(); 
  -      String outcomeExpression = element.attributeValue("outcome");
  -      if (outcomeExpression!=null)
  -      {
  -         navigation.setOutcomeValueBinding( Expressions.instance().createValueBinding(outcomeExpression) );
  -      }
  -      List<Element> cases = element.elements("outcome");
  -      for (Element childElement: cases)
  -      {
  -         Page.Case caze = parseCase(childElement);
  -         String value = childElement.attributeValue("value");
  -         if (value==null)
  -         {
  -            throw new IllegalStateException("Must specify value for <outcome/> declaration");
  -         }
  -         navigation.getCases().put(value, caze);
  -      }
  -      Element childElement = element.element("any-outcome");
  -      if (childElement!=null)
  -      {
  -         navigation.setAnyCase( parseCase(childElement) );
  -      }
  -      childElement = element.element("null-outcome");
  -      if (childElement!=null)
  -      {
  -         navigation.setNullCase( parseCase(childElement) );
  -      }
  -      
  -      String expression = element.attributeValue("action");
  -      if (expression==null)
  -      {
  -         entry.setDefaultNavigation(navigation);
  -      }
  -      else
  -      {
  -         entry.getNavigations().put(expression, navigation);
  -      }
  -   }
  -
  -   private Page.PageParameter parsePageParameter(Element element)
  -   {
  -      String valueExpression = element.attributeValue("value");
  -      String name = element.attributeValue("name");
  -      if (name==null)
  -      {
  -         if (valueExpression==null)
  -         {
  -            throw new IllegalArgumentException("must specify name or value for page <param/> declaration");
  -         }
  -         name = valueExpression.substring(2, valueExpression.length()-1);
  -      }
  -      Page.PageParameter pageParameter = new Page.PageParameter(name);
  -      if (valueExpression!=null)
  -      {
  -         pageParameter.setValueBinding(Expressions.instance().createValueBinding(valueExpression));
  -      }
  -      pageParameter.setConverterId(element.attributeValue("converterId"));
  -      String converterExpression = element.attributeValue("converter");
  -      if (converterExpression!=null)
  -      {
  -         pageParameter.setConverterValueBinding(Expressions.instance().createValueBinding(converterExpression));
  -      }
  -      return pageParameter;
  -   }
  -
  -   private Page.Case parseCase(Element element)
  -   {
  -      Page.Case caze = new Page.Case();
  -      Element render = element.element("render");
  -      if (render!=null)
  -      {
  -         final String viewId = render.attributeValue("view-id");
  -         caze.setResult(new Page.Result() {
  -            public void navigate(FacesContext context)
  -            {
  -               render(viewId);
  -            }
  -         });
  -      }
  -      Element redirect = element.element("redirect");
  -      if (redirect!=null)
  -      {
  -         List<Element> children = redirect.elements("param");
  -         final List<PageParameter> pageParameters = new ArrayList<PageParameter>();
  -         for (Element child: children)
  -         {
  -            pageParameters.add( parsePageParameter(child) );
  -         }
  -         final String viewId = redirect.attributeValue("view-id");
  -         caze.setResult(new Page.Result() {
  -            public void navigate(FacesContext context)
  -            {
  -               Map<String, Object> parameters = new HashMap<String, Object>();
  -               for ( PageParameter pageParameter: pageParameters )
  -               {
  -                  parameters.put( pageParameter.getName(), getParameterValue(context, pageParameter) );
  -               }
  -               redirect(viewId, parameters);
  -            }
  -         });
  -      }
  -      return caze;
  -   }
  -
  +   /**
  +    * Run any navigation rule defined in pages.xml
  +    * 
  +    * @param actionExpression the action method binding expression
  +    * @param actionOutcome the outcome of the action method
  +    * @return true if a navigation rule was found
  +    */
      public boolean navigate(FacesContext context, String actionExpression, final String actionOutcome)
      {
         String viewId = context.getViewRoot().getViewId();
  @@ -335,7 +101,7 @@
            for (int i=stack.size()-1; i>=0; i--)
            {
               Page page = stack.get(i);
  -            Page.Navigation navigation = page.getNavigations().get(actionExpression);
  +            Page.ActionNavigation navigation = page.getNavigations().get(actionExpression);
               if (navigation==null)
               {
                  navigation = page.getDefaultNavigation();
  @@ -355,23 +121,23 @@
                     outcome = value==null ? null : value.toString();
                  }
                  
  -               Page.Case caze;
  +               Page.Outcome caze;
                  if (outcome==null) 
                  {
                     //JSF navhandler says ignore all rules when null outcome.
                     //so we have a special case for that
  -                  caze = navigation.getNullCase();
  +                  caze = navigation.getNullOutcome();
                  }
                  else
                  {
  -                  caze = navigation.getCases().get(outcome);
  -                  if (caze==null) caze = navigation.getAnyCase();
  +                  caze = navigation.getOutcomes().get(outcome);
  +                  if (caze==null) caze = navigation.getAnyOutcome();
                  }
                  
                  if (caze!=null)
                  {
  -                  //TODO: begin/end conversation, etc!!
  -                  caze.getResult().navigate(context);
  +                  caze.getConversationControl().beginOrEndConversation();
  +                  caze.getNavigationHandler().navigate(context);
                     return true;
                  }
                  
  @@ -408,6 +174,10 @@
         }
      }
   
  +   /**
  +    * Create a new Page object for a JSF view id,
  +    * by searching for a viewId.page.xml file.
  +    */
      private Page createPage(String viewId)
      {
         String resourceName = replaceExtension(viewId, ".page.xml");
  @@ -464,6 +234,9 @@
         return stack;
      }
   
  +   /**
  +    * Create the stack of pages that match a JSF view id
  +    */
      private List<Page> createPageStack(String viewId)
      {
         List<Page> stack = new ArrayList<Page>(1);
  @@ -483,9 +256,10 @@
      }
      
      /**
  -    * Call page actions, from most general view id to most specific
  +    * Call page actions, and validate the existence of a conversation
  +    * for pages which require a long-running conversation
       */
  -   public boolean callActions(FacesContext facesContext)
  +   public boolean callActionsAndValidateConversation(FacesContext facesContext)
      {
         boolean result = false;
         String viewId = facesContext.getViewRoot().getViewId();
  @@ -504,11 +278,14 @@
         return result;
      }
   
  +   /**
  +    * Call page actions, from most general view id to most specific
  +    */
      private boolean callAction(Page page, FacesContext facesContext)
      {
         boolean result = false;
         
  -      page.beginOrEndConversation();
  +      page.getConversationControl().beginOrEndConversation();
   
         String outcome = page.getOutcome();
         String fromAction = outcome;
  @@ -538,13 +315,13 @@
         return returnValue == null ? null : returnValue.toString();
      }
   
  +   /**
  +    * Call the JSF navigation handler
  +    */
      private static void handleOutcome(FacesContext facesContext, String outcome, String fromAction)
      {
  -      /*if (outcome!=null)
  -      {*/
            facesContext.getApplication().getNavigationHandler()
                  .handleNavigation(facesContext, fromAction, outcome);
  -      //}
      }
      
      public static Pages instance()
  @@ -635,7 +412,7 @@
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.PageParameter pageParameter: page.getPageParameters() )
  +         for ( Page.Param pageParameter: page.getPageParameters() )
            {
               ValueBinding valueBinding = pageParameter.getValueBinding();
               Object value;
  @@ -669,7 +446,7 @@
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.PageParameter pageParameter: page.getPageParameters() )
  +         for ( Page.Param pageParameter: page.getPageParameters() )
            {
               if ( !overridden.contains( pageParameter.getName() ) )
               {
  @@ -684,7 +461,11 @@
         return parameters;
      }
   
  -   private Object getPageParameterValue(FacesContext facesContext, Page.PageParameter pageParameter)
  +   /**
  +    * Get the current value of a page parameter, looking in the page context
  +    * if there is no value binding
  +    */
  +   private Object getPageParameterValue(FacesContext facesContext, Page.Param pageParameter)
      {
         ValueBinding valueBinding = pageParameter.getValueBinding();
         if (valueBinding==null)
  @@ -697,7 +478,10 @@
         }
      }
   
  -   private Object getParameterValue(FacesContext facesContext, Page.PageParameter pageParameter)
  +   /**
  +    * Get the current value of a page or redirection parameter
  +    */
  +   private static Object getParameterValue(FacesContext facesContext, Page.Param pageParameter)
      {
         Object value = pageParameter.getValueBinding().getValue();
         if (value==null)
  @@ -731,7 +515,7 @@
         Map<String, String[]> requestParameters = Parameters.getRequestParameters();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.PageParameter pageParameter: page.getPageParameters() )
  +         for ( Page.Param pageParameter: page.getPageParameters() )
            {  
               
               String[] parameterValues = requestParameters.get(pageParameter.getName());
  @@ -781,7 +565,7 @@
         String viewId = facesContext.getViewRoot().getViewId();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.PageParameter pageParameter: page.getPageParameters() )
  +         for ( Page.Param pageParameter: page.getPageParameters() )
            {         
               ValueBinding valueBinding = pageParameter.getValueBinding();
               if (valueBinding!=null)
  @@ -884,4 +668,272 @@
      
      }
   
  +   /**
  +    * Parse a pages.xml file
  +    */
  +   private void parse(InputStream stream)
  +   {
  +      Element root = getDocumentRoot(stream);
  +      if (noConversationViewId==null) //let the setting in components.xml override the pages.xml
  +      {
  +         noConversationViewId = root.attributeValue("no-conversation-view-id");
  +      }
  +      List<Element> elements = root.elements("page");
  +      for (Element page: elements)
  +      {
  +         parse( page, page.attributeValue("view-id") );
  +      } 
  +   }
  +
  +   /**
  +    * Parse a viewId.page.xml file
  +    */
  +   private void parse(InputStream stream, String viewId)
  +   {
  +      parse( getDocumentRoot(stream), viewId );
  +   }
  +
  +   /**
  +    * Get the root element of the document
  +    */
  +   private static Element getDocumentRoot(InputStream stream)
  +   {
  +      try
  +      {
  +         return XML.getRootElement(stream);
  +      }
  +      catch (DocumentException de)
  +      {
  +         throw new RuntimeException(de);
  +      }
  +   }
  +
  +   /**
  +    * Parse a page element and add a Page to the map
  +    */
  +   private void parse(Element element, String viewId)
  +   {
  +      if (viewId==null)
  +      {
  +         throw new IllegalStateException("Must specify view-id for <page/> declaration");
  +      }
  +      
  +      if ( viewId.endsWith("*") )
  +      {
  +         wildcardViewIds.add(viewId);
  +      }
  +      Page page = new Page(viewId);
  +      pagesByViewId.put(viewId, page);
  +
  +      parsePage(page, element, viewId);
  +      parseConversationControl( element, page.getConversationControl() );
  +
  +      List<Element> children = element.elements("param");
  +      for (Element param: children)
  +      {
  +         page.getPageParameters().add( parsePageParameter(param) );
  +      }
  +      
  +      List<Element> moreChildren = element.elements("action-navigation");
  +      for (Element fromAction: moreChildren)
  +      {
  +         parseActionNavigation(page, fromAction);
  +      }
  +   }
  +
  +   /**
  +    * Parse the attributes of page
  +    */
  +   private static Page parsePage(Page page, Element element, String viewId)
  +   {
  +      
  +      page.setSwitchEnabled( !"disabled".equals( element.attributeValue("switch") ) );
  +      
  +      Element optionalElement = element.element("description");
  +      String description = optionalElement==null ? 
  +               element.getTextTrim() : optionalElement.getTextTrim();
  +      if (description!=null && description.length()>0)
  +      {
  +         page.setDescription(description);
  +      }
  +      
  +      String timeoutString = element.attributeValue("timeout");
  +      if (timeoutString!=null)
  +      {
  +         page.setTimeout(Integer.parseInt(timeoutString));
  +      }
  +      
  +      page.setNoConversationViewId( element.attributeValue("no-conversation-view-id") );
  +      page.setConversationRequired( "true".equals( element.attributeValue("conversation-required") ) );
  +      
  +      String action = element.attributeValue("action");
  +      if (action!=null)
  +      {
  +         if ( action.startsWith("#{") )
  +         {
  +            MethodBinding methodBinding = Expressions.instance().createMethodBinding(action);
  +            page.setAction(methodBinding);
  +         }
  +         else
  +         {
  +            page.setOutcome(action);
  +         }
  +      }
  +            
  +      String bundle = element.attributeValue("bundle");
  +      if (bundle!=null)
  +      {
  +         page.setResourceBundleName(bundle);
  +      }
  +      return page;
  +   }
  +
  +   /**
  +    * Parse end-conversation and begin-conversation
  +    */
  +   private static void parseConversationControl(Element element, ConversationControl control)
  +   {
  +      Element endConversation = element.element("end-conversation");
  +      if ( endConversation!=null )
  +      {
  +         control.setEndConversation(true);
  +      }
  +      
  +      Element beginConversation = element.element("begin-conversation");
  +      if ( beginConversation!=null )
  +      {
  +         control.setBeginConversation(true);
  +         control.setJoin( "true".equals( beginConversation.attributeValue("join") ) );
  +         control.setNested( "true".equals( beginConversation.attributeValue("nested") ) );
  +         control.setPageflow( beginConversation.attributeValue("pageflow") );
  +         String flushMode = beginConversation.attributeValue("flush-mode");
  +         if (flushMode!=null)
  +         {
  +            control.setFlushMode( FlushModeType.valueOf( flushMode.toUpperCase() ) );
  +         }
  +      }
  +      
  +      if ( control.isBeginConversation() && control.isEndConversation() )
  +      {
  +         throw new IllegalStateException("cannot use both <begin-conversation/> and <end-conversation/>");
  +      }
  +   }
  +
  +   /**
  +    * Parse action-navigation
  +    */
  +   private static void parseActionNavigation(Page entry, Element element)
  +   {
  +      Page.ActionNavigation navigation = new Page.ActionNavigation(); 
  +      String outcomeExpression = element.attributeValue("outcome");
  +      if (outcomeExpression!=null)
  +      {
  +         navigation.setOutcomeValueBinding( Expressions.instance().createValueBinding(outcomeExpression) );
  +      }
  +      List<Element> cases = element.elements("outcome");
  +      for (Element childElement: cases)
  +      {
  +         Page.Outcome caze = parseOutcome(childElement);
  +         String value = childElement.attributeValue("value");
  +         if (value==null)
  +         {
  +            throw new IllegalStateException("Must specify value for <outcome/> declaration");
  +         }
  +         navigation.getOutcomes().put(value, caze);
  +      }
  +      Element childElement = element.element("any-outcome");
  +      if (childElement!=null)
  +      {
  +         navigation.setAnyOutcome( parseOutcome(childElement) );
  +      }
  +      childElement = element.element("null-outcome");
  +      if (childElement!=null)
  +      {
  +         navigation.setNullOutcome( parseOutcome(childElement) );
  +      }
  +      
  +      String expression = element.attributeValue("action");
  +      if (expression==null)
  +      {
  +         entry.setDefaultNavigation(navigation);
  +      }
  +      else
  +      {
  +         entry.getNavigations().put(expression, navigation);
  +      }
  +   }
  +
  +   /**
  +    * Parse param
  +    */
  +   private static Page.Param parsePageParameter(Element element)
  +   {
  +      String valueExpression = element.attributeValue("value");
  +      String name = element.attributeValue("name");
  +      if (name==null)
  +      {
  +         if (valueExpression==null)
  +         {
  +            throw new IllegalArgumentException("must specify name or value for page <param/> declaration");
  +         }
  +         name = valueExpression.substring(2, valueExpression.length()-1);
  +      }
  +      Page.Param param = new Page.Param(name);
  +      if (valueExpression!=null)
  +      {
  +         param.setValueBinding(Expressions.instance().createValueBinding(valueExpression));
  +      }
  +      param.setConverterId(element.attributeValue("converterId"));
  +      String converterExpression = element.attributeValue("converter");
  +      if (converterExpression!=null)
  +      {
  +         param.setConverterValueBinding(Expressions.instance().createValueBinding(converterExpression));
  +      }
  +      return param;
  +   }
  +
  +   /**
  +    * parse outcome, any-outcome, null-outcome
  +    */
  +   private static Page.Outcome parseOutcome(Element element)
  +   {
  +      Page.Outcome caze = new Page.Outcome();
  +      parseConversationControl( element, caze.getConversationControl() );
  +      
  +      Element render = element.element("render");
  +      if (render!=null)
  +      {
  +         final String viewId = render.attributeValue("view-id");
  +         caze.setNavigationHandler(new Page.NavigationHandler() {
  +            public void navigate(FacesContext context)
  +            {
  +               render(viewId);
  +            }
  +         });
  +      }
  +      Element redirect = element.element("redirect");
  +      if (redirect!=null)
  +      {
  +         List<Element> children = redirect.elements("param");
  +         final List<Param> pageParameters = new ArrayList<Param>();
  +         for (Element child: children)
  +         {
  +            pageParameters.add( parsePageParameter(child) );
  +         }
  +         final String viewId = redirect.attributeValue("view-id");
  +         caze.setNavigationHandler(new Page.NavigationHandler() {
  +            public void navigate(FacesContext context)
  +            {
  +               Map<String, Object> parameters = new HashMap<String, Object>();
  +               for ( Param pageParameter: pageParameters )
  +               {
  +                  parameters.put( pageParameter.getName(), getParameterValue(context, pageParameter) );
  +               }
  +               redirect(viewId, parameters);
  +            }
  +         });
  +      }
  +      return caze;
  +   }
  +
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 12:45:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 12:45:37 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/init  ...
Message-ID: <E1Gw04v-0004kb-QV@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 12:45:37

  Modified:    src/main/org/jboss/seam/init  Initialization.java
  Log:
  JBSEAM-607, begin-conversation/end-conversation on an outcome
  
  Revision  Changes    Path
  1.134     +20 -28    jboss-seam/src/main/org/jboss/seam/init/Initialization.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Initialization.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/init/Initialization.java,v
  retrieving revision 1.133
  retrieving revision 1.134
  diff -u -b -r1.133 -r1.134
  --- Initialization.java	16 Dec 2006 02:58:11 -0000	1.133
  +++ Initialization.java	17 Dec 2006 17:45:37 -0000	1.134
  @@ -20,13 +20,9 @@
   
   import javax.servlet.ServletContext;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.dom4j.Attribute;
  -import org.dom4j.Document;
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  -import org.dom4j.io.SAXReader;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -45,19 +41,21 @@
   import org.jboss.seam.debug.Introspector;
   import org.jboss.seam.deployment.ComponentScanner;
   import org.jboss.seam.deployment.NamespaceScanner;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.persistence.HibernatePersistenceProvider;
   import org.jboss.seam.persistence.PersistenceProvider;
   import org.jboss.seam.util.Conversions;
  -import org.jboss.seam.util.DTDEntityResolver;
   import org.jboss.seam.util.Naming;
   import org.jboss.seam.util.Reflections;
   import org.jboss.seam.util.Resources;
   import org.jboss.seam.util.Strings;
  +import org.jboss.seam.util.XML;
   
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.133 $
  + * @version $Revision: 1.134 $
    */
   public class Initialization
   {
  @@ -104,7 +102,7 @@
            try
            {
               log.info("reading " + url);
  -            installComponentsFromXmlElements(getDocument(url.openStream()), replacements);
  +            installComponentsFromXmlElements( XML.getRootElement( url.openStream() ), replacements );
            }
            catch (Exception e)
            {
  @@ -126,7 +124,7 @@
            log.info("reading /WEB-INF/components.xml");
            try
            {
  -            installComponentsFromXmlElements(getDocument(stream), getReplacements());
  +            installComponentsFromXmlElements( XML.getRootElement(stream), getReplacements() );
            }
            catch (Exception e)
            {
  @@ -150,10 +148,10 @@
         }
      }
   
  -   private void installComponentsFromXmlElements(Document doc, Properties replacements)
  +   private void installComponentsFromXmlElements(Element rootElement, Properties replacements)
               throws DocumentException, ClassNotFoundException
      {
  -      List<Element> importElements = doc.getRootElement().elements("import-java-package");
  +      List<Element> importElements = rootElement.elements("import-java-package");
         for (Element importElement : importElements)
         {
            String pkgName = importElement.getTextTrim();
  @@ -161,20 +159,20 @@
            addNamespace(Package.getPackage(pkgName));
         }
   
  -      List<Element> componentElements = doc.getRootElement().elements("component");
  +      List<Element> componentElements = rootElement.elements("component");
         for (Element component : componentElements)
         {
            installComponentFromXmlElement(component, component.attributeValue("name"), component
                     .attributeValue("class"), replacements);
         }
   
  -      List<Element> factoryElements = doc.getRootElement().elements("factory");
  +      List<Element> factoryElements = rootElement.elements("factory");
         for (Element factory : factoryElements)
         {
            installFactoryFromXmlElement(factory);
         }
   
  -      for (Element elem : (List<Element>) doc.getRootElement().elements())
  +      for (Element elem : (List<Element>) rootElement.elements())
         {
            String ns = elem.getNamespace().getURI();
            NamespaceInfo nsInfo = namespaceMap.get(ns);
  @@ -232,15 +230,6 @@
         factoryDescriptors.add(new FactoryDescriptor(name, scope, method, value, autoCreate));
      }
   
  -   private Document getDocument(InputStream stream) throws DocumentException
  -   {
  -      SAXReader saxReader = new SAXReader();
  -      saxReader.setEntityResolver(new DTDEntityResolver());
  -      saxReader.setMergeAdjacentText(true);
  -      Document doc = saxReader.read(stream);
  -      return doc;
  -   }
  -
      private String replace(String value, Properties replacements)
      {
         if (value.startsWith("@"))
  @@ -476,21 +465,24 @@
            try
            {
               Properties replacements = getReplacements();
  -            Document doc = getDocument(stream);
  -            if (doc.getRootElement().getName().equals("components"))
  +            Element root = XML.getRootElement(stream);
  +            if ( root.getName().equals("components") )
               {
  -               installComponentsFromXmlElements(doc, replacements);
  +               installComponentsFromXmlElements(root, replacements);
               }
               else
               {
                  //TODO: namespaced components!!!
  -               installComponentFromXmlElement(doc.getRootElement(), doc.getRootElement()
  -                        .attributeValue("name"), clazz.getName(), replacements);
  +               installComponentFromXmlElement(
  +                        root, 
  +                        root.attributeValue("name"), 
  +                        clazz.getName(), replacements
  +                     );
               }
            }
            catch (Exception e)
            {
  -            throw new RuntimeException(e);
  +            throw new RuntimeException("error while reading " + fileName, e);
            }
         }
      }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 12:45:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 12:45:37 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf  ...
Message-ID: <E1Gw04v-0004ki-VQ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 12:45:37

  Modified:    src/main/org/jboss/seam/jsf  AbstractSeamPhaseListener.java
  Log:
  JBSEAM-607, begin-conversation/end-conversation on an outcome
  
  Revision  Changes    Path
  1.31      +1 -1      jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- AbstractSeamPhaseListener.java	16 Dec 2006 02:58:11 -0000	1.30
  +++ AbstractSeamPhaseListener.java	17 Dec 2006 17:45:37 -0000	1.31
  @@ -251,7 +251,7 @@
         {
            FacesContext facesContext = event.getFacesContext();
            actionsWereCalled = Pages.callAction(facesContext) || actionsWereCalled;
  -         actionsWereCalled = Pages.instance().callActions(facesContext) || actionsWereCalled;
  +         actionsWereCalled = Pages.instance().callActionsAndValidateConversation(facesContext) || actionsWereCalled;
            return actionsWereCalled;
         }
         catch (RuntimeException re)
  
  
  


From gavin.king at jboss.com  Sun Dec 17 12:45:38 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 12:45:38 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util  ...
Message-ID: <E1Gw04w-0004ku-3X@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 12:45:38

  Added:       src/main/org/jboss/seam/util  XML.java
  Log:
  JBSEAM-607, begin-conversation/end-conversation on an outcome
  
  Revision  Changes    Path
  1.1      date: 2006/12/17 17:45:38;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/util/XML.java
  
  Index: XML.java
  ===================================================================
  package org.jboss.seam.util;
  
  import java.io.InputStream;
  
  import org.dom4j.DocumentException;
  import org.dom4j.Element;
  import org.dom4j.io.SAXReader;
  
  public class XML
  {
     public static Element getRootElement(InputStream stream) throws DocumentException
     {
        SAXReader saxReader = new SAXReader();
        saxReader.setEntityResolver(new DTDEntityResolver());
        saxReader.setMergeAdjacentText(true);
        return saxReader.read(stream).getRootElement();
     }
  
  }
  
  
  


From fdsui987fdsa at doramail.com  Sun Dec 17 13:31:54 2006
From: fdsui987fdsa at doramail.com (fdsui987fdsa at doramail.com)
Date: Sun, 17 Dec 2006 13:31:54 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCqMKRw5LCgsK9woLCucKCwrXCgsOEwpBcwoI=?=
	=?utf-8?b?wrXClsOzwoLCoMKCw6jCgsOcwoLCucKCw7HCgsOFwoLCtcKCwr3CgUI=?=
Message-ID: 20051218032156.44363mail@mail.eworuetyberiyneortmweprmuete57197179680.com

-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
???????~???s?????Z???u???W?????o?^?????????T?C?g?????? 
-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*

?@???o?^?????????A?|???Q?b?g???????????????????P?? 
  ???@ http://completefree.freesexparty.ksjer.com/up/?@??

????????????????????????????????????????????????????????

??????????????????
~~~~~~~~~~~~~~~~~~
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
?w???O?x???q????
?w?N???x36??
?w?E???x?????w?l
?w???z?x10?`100??
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
?@?????U?????????l?????????B???????????m???????????B
?@???????????A???????????????V???????v???????????B
?@???????C?y?????????l???????????????????????B
?@?N???E?????????????B???]?z?????????????????B
*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*
???M???@http://completefree.freesexparty.ksjer.com/up/
?@
????????????????????????????????????????????????????????
?????S???????p???????????B
???S???????????T?[?r?X????????????????????????????
?????o?^???K?v?????????????????B 






From gavin.king at jboss.com  Sun Dec 17 14:28:32 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 14:28:32 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/exceptions - New
	directory ...
Message-ID: <E1Gw1gW-0006fL-9l@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 14:28:32

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/exceptions added to the repository


From gavin.king at jboss.com  Sun Dec 17 14:28:32 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 14:28:32 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pages - New directory
	...
Message-ID: <E1Gw1gW-0006fP-Cg@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 14:28:32

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages added to the repository


From gavin.king at jboss.com  Sun Dec 17 14:46:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 14:46:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core     ...
Message-ID: <E1Gw1y5-0006xS-Em@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 14:46:41

  Modified:    src/main/org/jboss/seam/core     Exceptions.java
                        Manager.java Navigator.java Pages.java
  Log:
  refactor all the inner classes
  
  Revision  Changes    Path
  1.21      +16 -309   jboss-seam/src/main/org/jboss/seam/core/Exceptions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Exceptions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Exceptions.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- Exceptions.java	17 Dec 2006 17:45:37 -0000	1.20
  +++ Exceptions.java	17 Dec 2006 19:46:41 -0000	1.21
  @@ -7,29 +7,29 @@
   import java.util.ArrayList;
   import java.util.List;
   
  -import javax.faces.context.FacesContext;
  -import javax.faces.event.PhaseId;
   
   import org.dom4j.Element;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
  -import org.jboss.seam.annotations.HttpError;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.annotations.Redirect;
  -import org.jboss.seam.annotations.Render;
   import org.jboss.seam.annotations.Scope;
  -import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.contexts.Lifecycle;
  +import org.jboss.seam.exceptions.ConfigErrorHandler;
  +import org.jboss.seam.exceptions.ConfigRedirectHandler;
  +import org.jboss.seam.exceptions.ConfigRenderHandler;
  +import org.jboss.seam.exceptions.DebugPageHandler;
  +import org.jboss.seam.exceptions.AnnotationErrorHandler;
  +import org.jboss.seam.exceptions.ExceptionHandler;
  +import org.jboss.seam.exceptions.AnnotationRedirectHandler;
  +import org.jboss.seam.exceptions.AnnotationRenderHandler;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.Reflections;
   import org.jboss.seam.util.Resources;
   import org.jboss.seam.util.Strings;
  -import org.jboss.seam.util.Transactions;
   import org.jboss.seam.util.XML;
   
   /**
  @@ -42,9 +42,9 @@
   @Intercept(NEVER)
   @Install(precedence=BUILT_IN)
   @Name("org.jboss.seam.core.exceptions")
  -public class Exceptions extends Navigator
  +public class Exceptions
   {
  -   private static final LogProvider log = Logging.getLogProvider(Exceptions.class);
  +   public static final LogProvider log = Logging.getLogProvider(Exceptions.class);
      
      private List<ExceptionHandler> exceptionHandlers = new ArrayList<ExceptionHandler>();
      
  @@ -88,9 +88,9 @@
            }
         }
         
  -      exceptionHandlers.add( new RenderHandler() );
  -      exceptionHandlers.add( new RedirectHandler() );
  -      exceptionHandlers.add( new ErrorHandler() );
  +      exceptionHandlers.add( new AnnotationRenderHandler() );
  +      exceptionHandlers.add( new AnnotationRedirectHandler() );
  +      exceptionHandlers.add( new AnnotationErrorHandler() );
         if ( Init.instance().isDebug() ) 
         {
            exceptionHandlers.add( new DebugPageHandler() );
  @@ -109,35 +109,7 @@
         {
            final String viewId = render.attributeValue("view-id");
            final String message = render.getTextTrim();
  -         return new RenderHandler()
  -         {
  -            @Override
  -            protected String getMessage(Exception e)
  -            {
  -               return message;
  -            }
  -            @Override
  -            protected String getViewId(Exception e)
  -            {
  -               return viewId;
  -            }
  -            @Override
  -            public boolean isHandler(Exception e)
  -            {
  -               return clazz.isInstance(e) && 
  -                     Lifecycle.getPhaseId()==PhaseId.INVOKE_APPLICATION;
  -            }
  -            @Override
  -            protected boolean isEnd(Exception e)
  -            {
  -               return endConversation;
  -            }
  -            @Override
  -            protected boolean isRollback(Exception e)
  -            {
  -               return rollback;
  -            }
  -         };
  +         return new ConfigRenderHandler(message, viewId, clazz, rollback, endConversation);
         }
         
         Element redirect = exception.element("redirect");
  @@ -145,35 +117,7 @@
         {
            final String viewId = redirect.attributeValue("view-id");
            final String message = redirect.getTextTrim();
  -         return new RedirectHandler()
  -         {
  -            @Override
  -            protected String getMessage(Exception e)
  -            {
  -               return message;
  -            }
  -            @Override
  -            protected String getViewId(Exception e)
  -            {
  -               return viewId;
  -            }
  -            @Override
  -            public boolean isHandler(Exception e)
  -            {
  -               return clazz.isInstance(e) && 
  -                     Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE;
  -            }
  -            @Override
  -            protected boolean isEnd(Exception e)
  -            {
  -               return endConversation;
  -            }
  -            @Override
  -            protected boolean isRollback(Exception e)
  -            {
  -               return rollback;
  -            }
  -         };
  +         return new ConfigRedirectHandler(viewId, clazz, endConversation, rollback, message);
         }
         
         Element error = exception.element("http-error");
  @@ -183,249 +127,12 @@
            final int code = Strings.isEmpty(errorCode) ? 
                  500 : Integer.parseInt(errorCode);
            final String message = error.getTextTrim();
  -         return new ErrorHandler()
  -         {
  -            @Override
  -            protected String getMessage(Exception e)
  -            {
  -               return message;
  -            }
  -            @Override
  -            protected int getCode(Exception e)
  -            {
  -               return code;
  -            }
  -            @Override
  -            public boolean isHandler(Exception e)
  -            {
  -               return clazz.isInstance(e);
  -            }
  -            @Override
  -            protected boolean isEnd(Exception e)
  -            {
  -               return endConversation;
  -            }
  -            @Override
  -            protected boolean isRollback(Exception e)
  -            {
  -               return rollback;
  -            }
  -         };
  +         return new ConfigErrorHandler(message, endConversation, clazz, code, rollback);
         }
         
         return null;
      }
   
  -   public static interface ExceptionHandler
  -   {
  -      public Object handle(Exception e) throws Exception;
  -      public boolean isHandler(Exception e);
  -   }
  -   
  -   public static class RedirectHandler implements ExceptionHandler
  -   {
  -      public Object handle(Exception e) throws Exception
  -      {
  -         addFacesMessage( e, getMessage(e) );
  -         if ( isEnd(e) ) Conversation.instance().end();
  -         if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
  -         redirect( getViewId(e), null );
  -         return rethrow(e);
  -      }
  -
  -      public boolean isHandler(Exception e)
  -      {
  -         return e.getClass().isAnnotationPresent(Redirect.class) && 
  -               Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
  -               Lifecycle.getPhaseId()!=null;
  -      }
  -      
  -      protected String getMessage(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Redirect.class).message();
  -      }
  -      
  -      protected String getViewId(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Redirect.class).viewId();
  -      }
  -      
  -      protected boolean isEnd(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Redirect.class).end();
  -      } 
  -
  -      protected boolean isRollback(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Redirect.class).rollback();
  -      }
  -      
  -      @Override
  -      public String toString()
  -      {
  -         return "RedirectHandler";
  -      }
  -   }
  -   
  -   public static class RenderHandler implements ExceptionHandler
  -   {
  -      public Object handle(Exception e) throws Exception
  -      {
  -         addFacesMessage( e, getMessage(e) );
  -         if ( isEnd(e) ) Conversation.instance().end();
  -         if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
  -         render( getViewId(e) );
  -         return null;
  -      }
  -
  -      public boolean isHandler(Exception e)
  -      {
  -         return e.getClass().isAnnotationPresent(Render.class) && 
  -               Lifecycle.getPhaseId()==PhaseId.INVOKE_APPLICATION;
  -      }
  -
  -      protected String getMessage(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Render.class).message();
  -      }
  -      
  -      protected String getViewId(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Render.class).viewId();
  -      }
  -
  -      protected boolean isEnd(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Render.class).end();
  -      }
  -
  -      protected boolean isRollback(Exception e)
  -      {
  -         return e.getClass().getAnnotation(Render.class).rollback();
  -      }
  -      
  -      @Override
  -      public String toString()
  -      {
  -         return "RenderHandler";
  -      }
  -   }
  -   
  -   public static class ErrorHandler implements ExceptionHandler
  -   {
  -      public Object handle(Exception e) throws Exception
  -      {
  -         if ( isEnd(e) ) Conversation.instance().end();
  -         if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
  -         String message = getMessage(e);
  -         //addFacesMessage(e, message);
  -         error( getCode(e), Interpolator.instance().interpolate( getDisplayMessage(e, message) ) );
  -         return rethrow(e);
  -      }  
  -
  -      public boolean isHandler(Exception e)
  -      {
  -         return e.getClass().isAnnotationPresent(HttpError.class);
  -      }
  -      
  -      protected String getMessage(Exception e)
  -      {
  -         return e.getClass().getAnnotation(HttpError.class).message();
  -      }
  -      
  -      protected int getCode(Exception e)
  -      {
  -         return e.getClass().getAnnotation(HttpError.class).errorCode();
  -      }
  -      
  -      protected boolean isEnd(Exception e)
  -      {
  -         return e.getClass().getAnnotation(HttpError.class).end();
  -      }
  -      
  -      protected boolean isRollback(Exception e)
  -      {
  -         return e.getClass().getAnnotation(HttpError.class).rollback();
  -      }
  -      
  -      @Override
  -      public String toString()
  -      {
  -         return "ErrorHandler";
  -      }
  -   }
  -   
  -   public static class DebugPageHandler implements ExceptionHandler
  -   {
  -
  -      public Object handle(Exception e) throws Exception
  -      {
  -         log.error("redirecting to debug page", e);
  -         Context conversationContext = Contexts.getConversationContext();
  -         conversationContext.set("org.jboss.seam.debug.lastException", e);
  -         conversationContext.set("org.jboss.seam.debug.phaseId", Lifecycle.getPhaseId().toString());
  -         org.jboss.seam.core.Redirect redirect = org.jboss.seam.core.Redirect.instance();
  -         redirect.setViewId("/debug.xhtml");
  -         Manager manager = Manager.instance();
  -         manager.beforeRedirect();
  -         redirect.setParameter( manager.getConversationIdParameter(), manager.getCurrentConversationId() );
  -         redirect.execute();
  -         conversationContext.flush();
  -         return rethrow(e);
  -      }
  -
  -      public boolean isHandler(Exception e)
  -      {
  -         return Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
  -               Lifecycle.getPhaseId()!=null;
  -      }
  -      
  -      @Override
  -      public String toString()
  -      {
  -         return "Debug";
  -      }
  -   }
  -   
  -   protected static String getDisplayMessage(Exception e, String message)
  -   {
  -      if ( Strings.isEmpty(message) && e.getMessage()!=null ) 
  -      {
  -         return e.getMessage();
  -      }
  -      else
  -      {
  -         return message;
  -      }
  -   }
  -   
  -   protected static void addFacesMessage(Exception e, String message)
  -   {
  -      message = getDisplayMessage(e, message);
  -      if ( !Strings.isEmpty(message) )
  -      {
  -         FacesMessages.instance().add(message);
  -      }
  -   }
  -   
  -   private static Object rethrow(Exception e) throws Exception
  -   {
  -      //SeamExceptionFilter does *not* do these things, which 
  -      //would normally happen in the phase listener after a 
  -      //responseComplete() call, but because we are rethrowing,
  -      //the phase listener might not get called (due to a bug!)
  -      /*FacesMessages.afterPhase();
  -      if ( Contexts.isConversationContextActive() )
  -      {
  -         Manager.instance().endRequest( ContextAdaptor.getSession( externalContext, true ) );
  -      }*/
  -      
  -      FacesContext facesContext = FacesContext.getCurrentInstance();
  -      facesContext.responseComplete();
  -      facesContext.getExternalContext().getRequestMap().put("org.jboss.seam.exceptionHandled", e);
  -      throw e;
  -   }
  -
      public static Exceptions instance()
      {
         if ( !Contexts.isApplicationContextActive() )
  
  
  
  1.127     +2 -2      jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.126
  retrieving revision 1.127
  diff -u -b -r1.126 -r1.127
  --- Manager.java	16 Dec 2006 02:58:10 -0000	1.126
  +++ Manager.java	17 Dec 2006 19:46:41 -0000	1.127
  @@ -42,7 +42,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.126 $
  + * @version $Revision: 1.127 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -991,7 +991,7 @@
            Pages pages = Pages.instance();
            if (pages!=null) //for tests
            {
  -            org.jboss.seam.core.Page pageEntry = pages.getPage(viewId);
  +            org.jboss.seam.pages.Page pageEntry = pages.getPage(viewId);
               if ( pageEntry.isSwitchEnabled() )
               {
                  conversation.setViewId(viewId);
  
  
  
  1.3       +4 -5      jboss-seam/src/main/org/jboss/seam/core/Navigator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Navigator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Navigator.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Navigator.java	17 Dec 2006 02:39:17 -0000	1.2
  +++ Navigator.java	17 Dec 2006 19:46:41 -0000	1.3
  @@ -9,14 +9,14 @@
   import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.Strings;
   
  -abstract class Navigator
  +public abstract class Navigator
   {
      private static final LogProvider log = Logging.getLogProvider(Navigator.class);
   
      /**
       * Send an error.
       */
  -   protected static void error(int code, String message)
  +   protected void error(int code, String message)
      {
         if ( log.isDebugEnabled() ) log.debug("sending error: " + code);
         org.jboss.seam.core.HttpError httpError = org.jboss.seam.core.HttpError.instance();
  @@ -33,7 +33,7 @@
      /**
       * Redirect to the view id.
       */
  -   protected static void redirect(String viewId, Map<String, Object> parameters)
  +   protected void redirect(String viewId, Map<String, Object> parameters)
      {
         if ( Strings.isEmpty(viewId) )
         {
  @@ -46,7 +46,7 @@
      /**
       * Render the view id.
       */
  -   protected static void render(String viewId)
  +   protected void render(String viewId)
      {
         FacesContext facesContext = FacesContext.getCurrentInstance();
         if ( !Strings.isEmpty(viewId) )
  @@ -63,5 +63,4 @@
         facesContext.renderResponse();
      }
   
  -
   }
  
  
  
  1.67      +52 -113   jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.66
  retrieving revision 1.67
  diff -u -b -r1.66 -r1.67
  --- Pages.java	17 Dec 2006 17:45:37 -0000	1.66
  +++ Pages.java	17 Dec 2006 19:46:41 -0000	1.67
  @@ -17,7 +17,6 @@
   
   import javax.faces.application.ViewHandler;
   import javax.faces.context.FacesContext;
  -import javax.faces.convert.Converter;
   
   import org.dom4j.DocumentException;
   import org.dom4j.Element;
  @@ -32,10 +31,15 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions.MethodBinding;
   import org.jboss.seam.core.Expressions.ValueBinding;
  -import org.jboss.seam.core.Page.ConversationControl;
  -import org.jboss.seam.core.Page.Param;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
  +import org.jboss.seam.pages.ActionNavigation;
  +import org.jboss.seam.pages.ConversationControl;
  +import org.jboss.seam.pages.Outcome;
  +import org.jboss.seam.pages.Page;
  +import org.jboss.seam.pages.Param;
  +import org.jboss.seam.pages.RedirectNavigationHandler;
  +import org.jboss.seam.pages.RenderNavigationHandler;
   import org.jboss.seam.util.Parameters;
   import org.jboss.seam.util.Resources;
   import org.jboss.seam.util.XML;
  @@ -50,7 +54,7 @@
   @Intercept(NEVER)
   @Name("org.jboss.seam.core.pages")
   @Install(precedence=BUILT_IN)
  -public class Pages extends Navigator
  +public class Pages
   {
      
      private static final LogProvider log = Logging.getLogProvider(Pages.class);
  @@ -89,10 +93,10 @@
       * Run any navigation rule defined in pages.xml
       * 
       * @param actionExpression the action method binding expression
  -    * @param actionOutcome the outcome of the action method
  +    * @param actionOutcomeValue the outcome of the action method
       * @return true if a navigation rule was found
       */
  -   public boolean navigate(FacesContext context, String actionExpression, final String actionOutcome)
  +   public boolean navigate(FacesContext context, String actionExpression, final String actionOutcomeValue)
      {
         String viewId = context.getViewRoot().getViewId();
         if (viewId!=null)
  @@ -101,7 +105,7 @@
            for (int i=stack.size()-1; i>=0; i--)
            {
               Page page = stack.get(i);
  -            Page.ActionNavigation navigation = page.getNavigations().get(actionExpression);
  +            ActionNavigation navigation = page.getNavigations().get(actionExpression);
               if (navigation==null)
               {
                  navigation = page.getDefaultNavigation();
  @@ -110,34 +114,34 @@
               if (navigation!=null)
               {
                  
  -               String outcome;
  +               String outcomeValue;
                  if ( navigation.getOutcomeValueBinding()==null )
                  {
  -                  outcome = actionOutcome;
  +                  outcomeValue = actionOutcomeValue;
                  }
                  else
                  {
                     Object value = navigation.getOutcomeValueBinding().getValue();
  -                  outcome = value==null ? null : value.toString();
  +                  outcomeValue = value==null ? null : value.toString();
                  }
                  
  -               Page.Outcome caze;
  -               if (outcome==null) 
  +               Outcome outcome;
  +               if (outcomeValue==null) 
                  {
                     //JSF navhandler says ignore all rules when null outcome.
                     //so we have a special case for that
  -                  caze = navigation.getNullOutcome();
  +                  outcome = navigation.getNullOutcome();
                  }
                  else
                  {
  -                  caze = navigation.getOutcomes().get(outcome);
  -                  if (caze==null) caze = navigation.getAnyOutcome();
  +                  outcome = navigation.getOutcomes().get(outcomeValue);
  +                  if (outcome==null) outcome = navigation.getAnyOutcome();
                  }
                  
  -               if (caze!=null)
  +               if (outcome!=null)
                  {
  -                  caze.getConversationControl().beginOrEndConversation();
  -                  caze.getNavigationHandler().navigate(context);
  +                  outcome.getConversationControl().beginOrEndConversation();
  +                  outcome.getNavigationHandler().navigate(context);
                     return true;
                  }
                  
  @@ -412,7 +416,7 @@
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getPageParameters() )
            {
               ValueBinding valueBinding = pageParameter.getValueBinding();
               Object value;
  @@ -446,7 +450,7 @@
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getPageParameters() )
            {
               if ( !overridden.contains( pageParameter.getName() ) )
               {
  @@ -465,7 +469,7 @@
       * Get the current value of a page parameter, looking in the page context
       * if there is no value binding
       */
  -   private Object getPageParameterValue(FacesContext facesContext, Page.Param pageParameter)
  +   private Object getPageParameterValue(FacesContext facesContext, Param pageParameter)
      {
         ValueBinding valueBinding = pageParameter.getValueBinding();
         if (valueBinding==null)
  @@ -474,35 +478,7 @@
         }
         else
         {
  -         return getParameterValue(facesContext, pageParameter);
  -      }
  -   }
  -
  -   /**
  -    * Get the current value of a page or redirection parameter
  -    */
  -   private static Object getParameterValue(FacesContext facesContext, Page.Param pageParameter)
  -   {
  -      Object value = pageParameter.getValueBinding().getValue();
  -      if (value==null)
  -      {
  -         return null;
  -      }
  -      else
  -      {
  -         Converter converter = null;
  -         try
  -         {
  -            converter = pageParameter.getConverter();
  -         }
  -         catch (RuntimeException re)
  -         {
  -            //YUCK! due to bad JSF/MyFaces error handling
  -            return null;
  -         }
  -         
  -         return converter==null ? 
  -                  value : converter.getAsString( facesContext, facesContext.getViewRoot(), value );
  +         return pageParameter.getValueFromModel(facesContext);
         }
      }
      
  @@ -515,35 +491,12 @@
         Map<String, String[]> requestParameters = Parameters.getRequestParameters();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.Param pageParameter: page.getPageParameters() )
  -         {  
  -            
  -            String[] parameterValues = requestParameters.get(pageParameter.getName());
  -            if (parameterValues==null || parameterValues.length==0)
  -            {
  -               continue;
  -            }
  -            if (parameterValues.length>1)
  +         for ( Param pageParameter: page.getPageParameters() )
               {
  -               throw new IllegalArgumentException("page parameter may not be multi-valued: " + pageParameter.getName());
  -            }         
  -            String stringValue = parameterValues[0];
      
  -            Converter converter;
  -            try
  -            {
  -               converter = pageParameter.getConverter();
  -            }
  -            catch (RuntimeException re)
  +            Object value = pageParameter.getValueFromRequest(facesContext, requestParameters);
  +            if (value!=null)
               {
  -               //YUCK! due to bad JSF/MyFaces error handling
  -               continue;
  -            }
  -            
  -            Object value = converter==null ? 
  -                  stringValue :
  -                  converter.getAsObject( facesContext, facesContext.getViewRoot(), stringValue );
  -
               ValueBinding valueBinding = pageParameter.getValueBinding();
               if (valueBinding==null)
               {
  @@ -556,6 +509,7 @@
            }
         }
      }
  +   }
   
      /**
       * Apply any page parameters passed as view root attributes to the model.
  @@ -565,7 +519,7 @@
         String viewId = facesContext.getViewRoot().getViewId();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Page.Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getPageParameters() )
            {         
               ValueBinding valueBinding = pageParameter.getValueBinding();
               if (valueBinding!=null)
  @@ -731,7 +685,7 @@
         List<Element> children = element.elements("param");
         for (Element param: children)
         {
  -         page.getPageParameters().add( parsePageParameter(param) );
  +         page.getPageParameters().add( parseParam(param) );
         }
         
         List<Element> moreChildren = element.elements("action-navigation");
  @@ -824,7 +778,7 @@
       */
      private static void parseActionNavigation(Page entry, Element element)
      {
  -      Page.ActionNavigation navigation = new Page.ActionNavigation(); 
  +      ActionNavigation navigation = new ActionNavigation(); 
         String outcomeExpression = element.attributeValue("outcome");
         if (outcomeExpression!=null)
         {
  @@ -833,7 +787,7 @@
         List<Element> cases = element.elements("outcome");
         for (Element childElement: cases)
         {
  -         Page.Outcome caze = parseOutcome(childElement);
  +         Outcome caze = parseOutcome(childElement);
            String value = childElement.attributeValue("value");
            if (value==null)
            {
  @@ -866,7 +820,7 @@
      /**
       * Parse param
       */
  -   private static Page.Param parsePageParameter(Element element)
  +   private static Param parseParam(Element element)
      {
         String valueExpression = element.attributeValue("value");
         String name = element.attributeValue("name");
  @@ -878,7 +832,7 @@
            }
            name = valueExpression.substring(2, valueExpression.length()-1);
         }
  -      Page.Param param = new Page.Param(name);
  +      Param param = new Param(name);
         if (valueExpression!=null)
         {
            param.setValueBinding(Expressions.instance().createValueBinding(valueExpression));
  @@ -895,45 +849,30 @@
      /**
       * parse outcome, any-outcome, null-outcome
       */
  -   private static Page.Outcome parseOutcome(Element element)
  +   private static Outcome parseOutcome(Element element)
      {
  -      Page.Outcome caze = new Page.Outcome();
  -      parseConversationControl( element, caze.getConversationControl() );
  +      Outcome outcome = new Outcome();
  +      parseConversationControl( element, outcome.getConversationControl() );
         
         Element render = element.element("render");
         if (render!=null)
         {
            final String viewId = render.attributeValue("view-id");
  -         caze.setNavigationHandler(new Page.NavigationHandler() {
  -            public void navigate(FacesContext context)
  -            {
  -               render(viewId);
  -            }
  -         });
  +         outcome.setNavigationHandler( new RenderNavigationHandler(viewId) );
         }
         Element redirect = element.element("redirect");
         if (redirect!=null)
         {
            List<Element> children = redirect.elements("param");
  -         final List<Param> pageParameters = new ArrayList<Param>();
  +         final List<Param> params = new ArrayList<Param>();
            for (Element child: children)
            {
  -            pageParameters.add( parsePageParameter(child) );
  +            params.add( parseParam(child) );
            }
            final String viewId = redirect.attributeValue("view-id");
  -         caze.setNavigationHandler(new Page.NavigationHandler() {
  -            public void navigate(FacesContext context)
  -            {
  -               Map<String, Object> parameters = new HashMap<String, Object>();
  -               for ( Param pageParameter: pageParameters )
  -               {
  -                  parameters.put( pageParameter.getName(), getParameterValue(context, pageParameter) );
  -               }
  -               redirect(viewId, parameters);
  -            }
  -         });
  +         outcome.setNavigationHandler( new RedirectNavigationHandler(viewId, params) );
         }
  -      return caze;
  +      return outcome;
      }
   
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 14:46:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 14:46:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/exceptions ...
Message-ID: <E1Gw1y5-0006y3-K8@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 14:46:41

  Added:       src/main/org/jboss/seam/exceptions           
                        AnnotationErrorHandler.java
                        AnnotationRedirectHandler.java
                        AnnotationRenderHandler.java
                        ConfigErrorHandler.java ConfigRedirectHandler.java
                        ConfigRenderHandler.java DebugPageHandler.java
                        ErrorHandler.java ExceptionHandler.java
                        RedirectHandler.java RenderHandler.java
  Log:
  refactor all the inner classes
  
  Revision  Changes    Path
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/AnnotationErrorHandler.java
  
  Index: AnnotationErrorHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import org.jboss.seam.annotations.HttpError;
  
  public class AnnotationErrorHandler extends ErrorHandler
  {
     @Override
     public boolean isHandler(Exception e)
     {
        return e.getClass().isAnnotationPresent(HttpError.class);
     }
     
     @Override
     protected String getMessage(Exception e)
     {
        return e.getClass().getAnnotation(HttpError.class).message();
     }
     
     @Override
     protected int getCode(Exception e)
     {
        return e.getClass().getAnnotation(HttpError.class).errorCode();
     }
     
     @Override
     protected boolean isEnd(Exception e)
     {
        return e.getClass().getAnnotation(HttpError.class).end();
     }
     
     @Override
     protected boolean isRollback(Exception e)
     {
        return e.getClass().getAnnotation(HttpError.class).rollback();
     }
     
     @Override
     public String toString()
     {
        return "ErrorHandler";
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/AnnotationRedirectHandler.java
  
  Index: AnnotationRedirectHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import javax.faces.event.PhaseId;
  
  import org.jboss.seam.annotations.Redirect;
  import org.jboss.seam.contexts.Lifecycle;
  
  public class AnnotationRedirectHandler extends RedirectHandler
  {
     @Override
     public boolean isHandler(Exception e)
     {
        return e.getClass().isAnnotationPresent(Redirect.class) && 
              Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
              Lifecycle.getPhaseId()!=null;
     }
     
     @Override
     protected String getMessage(Exception e)
     {
        return e.getClass().getAnnotation(Redirect.class).message();
     }
     
     @Override
     protected String getViewId(Exception e)
     {
        return e.getClass().getAnnotation(Redirect.class).viewId();
     }
     
     @Override
     protected boolean isEnd(Exception e)
     {
        return e.getClass().getAnnotation(Redirect.class).end();
     } 
  
     @Override
     protected boolean isRollback(Exception e)
     {
        return e.getClass().getAnnotation(Redirect.class).rollback();
     }
     
     @Override
     public String toString()
     {
        return "RedirectHandler";
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/AnnotationRenderHandler.java
  
  Index: AnnotationRenderHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import javax.faces.event.PhaseId;
  
  import org.jboss.seam.annotations.Render;
  import org.jboss.seam.contexts.Lifecycle;
  
  public class AnnotationRenderHandler extends RenderHandler
  {
     @Override
     public boolean isHandler(Exception e)
     {
        return e.getClass().isAnnotationPresent(Render.class) && 
              Lifecycle.getPhaseId()==PhaseId.INVOKE_APPLICATION;
     }
  
     @Override
     protected String getMessage(Exception e)
     {
        return e.getClass().getAnnotation(Render.class).message();
     }
     
     @Override
     protected String getViewId(Exception e)
     {
        return e.getClass().getAnnotation(Render.class).viewId();
     }
  
     @Override
     protected boolean isEnd(Exception e)
     {
        return e.getClass().getAnnotation(Render.class).end();
     }
  
     @Override
     protected boolean isRollback(Exception e)
     {
        return e.getClass().getAnnotation(Render.class).rollback();
     }
     
     @Override
     public String toString()
     {
        return "RenderHandler";
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/ConfigErrorHandler.java
  
  Index: ConfigErrorHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  
  public final class ConfigErrorHandler extends ErrorHandler
  {
     private final String message;
     private final boolean conversation;
     private final Class clazz;
     private final int code;
     private final boolean rollback;
  
     public ConfigErrorHandler(String message, boolean conversation, Class clazz, int code, boolean rollback)
     {
        this.message = message;
        this.conversation = conversation;
        this.clazz = clazz;
        this.code = code;
        this.rollback = rollback;
     }
  
     @Override
     protected String getMessage(Exception e)
     {
        return message;
     }
  
     @Override
     protected int getCode(Exception e)
     {
        return code;
     }
  
     @Override
     public boolean isHandler(Exception e)
     {
        return clazz.isInstance(e);
     }
  
     @Override
     protected boolean isEnd(Exception e)
     {
        return conversation;
     }
  
     @Override
     protected boolean isRollback(Exception e)
     {
        return rollback;
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/ConfigRedirectHandler.java
  
  Index: ConfigRedirectHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import javax.faces.event.PhaseId;
  
  import org.jboss.seam.contexts.Lifecycle;
  
  public final class ConfigRedirectHandler extends RedirectHandler
  {
     private final String id;
     private final Class clazz;
     private final boolean conversation;
     private final boolean rollback;
     private final String message;
  
     public ConfigRedirectHandler(String id, Class clazz, boolean conversation, boolean rollback, String message)
     {
        this.id = id;
        this.clazz = clazz;
        this.conversation = conversation;
        this.rollback = rollback;
        this.message = message;
     }
  
     @Override
     protected String getMessage(Exception e)
     {
        return message;
     }
  
     @Override
     protected String getViewId(Exception e)
     {
        return id;
     }
  
     @Override
     public boolean isHandler(Exception e)
     {
        return clazz.isInstance(e) && 
              Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE;
     }
  
     @Override
     protected boolean isEnd(Exception e)
     {
        return conversation;
     }
  
     @Override
     protected boolean isRollback(Exception e)
     {
        return rollback;
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/ConfigRenderHandler.java
  
  Index: ConfigRenderHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import javax.faces.event.PhaseId;
  
  import org.jboss.seam.contexts.Lifecycle;
  
  public final class ConfigRenderHandler extends RenderHandler
  {
     private final String message;
     private final String id;
     private final Class clazz;
     private final boolean rollback;
     private final boolean conversation;
  
     public ConfigRenderHandler(String message, String id, Class clazz, boolean rollback, boolean conversation)
     {
        this.message = message;
        this.id = id;
        this.clazz = clazz;
        this.rollback = rollback;
        this.conversation = conversation;
     }
  
     @Override
     protected String getMessage(Exception e)
     {
        return message;
     }
  
     @Override
     protected String getViewId(Exception e)
     {
        return id;
     }
  
     @Override
     public boolean isHandler(Exception e)
     {
        return clazz.isInstance(e) && 
              Lifecycle.getPhaseId()==PhaseId.INVOKE_APPLICATION;
     }
  
     @Override
     protected boolean isEnd(Exception e)
     {
        return conversation;
     }
  
     @Override
     protected boolean isRollback(Exception e)
     {
        return rollback;
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/DebugPageHandler.java
  
  Index: DebugPageHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import javax.faces.event.PhaseId;
  
  import org.jboss.seam.contexts.Context;
  import org.jboss.seam.contexts.Contexts;
  import org.jboss.seam.contexts.Lifecycle;
  import org.jboss.seam.core.Exceptions;
  import org.jboss.seam.core.Manager;
  
  public class DebugPageHandler extends ExceptionHandler
  {
  
     @Override
     public Object handle(Exception e) throws Exception
     {
        Exceptions.log.error("redirecting to debug page", e);
        Context conversationContext = Contexts.getConversationContext();
        conversationContext.set("org.jboss.seam.debug.lastException", e);
        conversationContext.set("org.jboss.seam.debug.phaseId", Lifecycle.getPhaseId().toString());
        org.jboss.seam.core.Redirect redirect = org.jboss.seam.core.Redirect.instance();
        redirect.setViewId("/debug.xhtml");
        Manager manager = Manager.instance();
        manager.beforeRedirect();
        redirect.setParameter( manager.getConversationIdParameter(), manager.getCurrentConversationId() );
        redirect.execute();
        conversationContext.flush();
        return rethrow(e);
     }
  
     @Override
     public boolean isHandler(Exception e)
     {
        return Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
              Lifecycle.getPhaseId()!=null;
     }
     
     @Override
     public String toString()
     {
        return "Debug";
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/ErrorHandler.java
  
  Index: ErrorHandler.java
  ===================================================================
  package org.jboss.seam.exceptions;
  
  import org.jboss.seam.core.Conversation;
  import org.jboss.seam.core.Interpolator;
  import org.jboss.seam.util.Transactions;
  
  public abstract class ErrorHandler extends ExceptionHandler
  {
  
     @Override
     public Object handle(Exception e) throws Exception
     {
        if ( isEnd(e) ) Conversation.instance().end();
        if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
        String message = getMessage(e);
        //addFacesMessage(e, message);
        error( getCode(e), Interpolator.instance().interpolate( getDisplayMessage(e, message) ) );
        return rethrow(e);
     }
  
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/ExceptionHandler.java
  
  Index: ExceptionHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.exceptions;
  
  import javax.faces.context.FacesContext;
  
  import org.jboss.seam.core.FacesMessages;
  import org.jboss.seam.core.Navigator;
  import org.jboss.seam.util.Strings;
  
  public abstract class ExceptionHandler extends Navigator
  {
     public abstract Object handle(Exception e) throws Exception;
     public abstract boolean isHandler(Exception e);
     
     protected String getMessage(Exception e)
     {
        throw new UnsupportedOperationException();
     }
     protected String getViewId(Exception e)
     {
        throw new UnsupportedOperationException();
     }
     protected boolean isEnd(Exception e)
     {
        throw new UnsupportedOperationException();
     }
     protected boolean isRollback(Exception e)
     {
        throw new UnsupportedOperationException();
     }
     protected int getCode(Exception e)
     {
        throw new UnsupportedOperationException();
     }
  
     public static String getDisplayMessage(Exception e, String message)
     {
        if ( Strings.isEmpty(message) && e.getMessage()!=null ) 
        {
           return e.getMessage();
        }
        else
        {
           return message;
        }
     }
     
     public static void addFacesMessage(Exception e, String message)
     {
        message = getDisplayMessage(e, message);
        if ( !Strings.isEmpty(message) )
        {
           FacesMessages.instance().add(message);
        }
     }
     
     public static Object rethrow(Exception e) throws Exception
     {
        //SeamExceptionFilter does *not* do these things, which 
        //would normally happen in the phase listener after a 
        //responseComplete() call, but because we are rethrowing,
        //the phase listener might not get called (due to a bug!)
        /*FacesMessages.afterPhase();
        if ( Contexts.isConversationContextActive() )
        {
           Manager.instance().endRequest( ContextAdaptor.getSession( externalContext, true ) );
        }*/
        
        FacesContext facesContext = FacesContext.getCurrentInstance();
        facesContext.responseComplete();
        facesContext.getExternalContext().getRequestMap().put("org.jboss.seam.exceptionHandled", e);
        throw e;
     }
  
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/RedirectHandler.java
  
  Index: RedirectHandler.java
  ===================================================================
  package org.jboss.seam.exceptions;
  
  import org.jboss.seam.core.Conversation;
  import org.jboss.seam.util.Transactions;
  
  public abstract class RedirectHandler extends ExceptionHandler
  {
     
     @Override
     public Object handle(Exception e) throws Exception
     {
        addFacesMessage( e, getMessage(e) );
        if ( isEnd(e) ) Conversation.instance().end();
        if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
        redirect( getViewId(e), null );
        return rethrow(e);
     }
  
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/exceptions/RenderHandler.java
  
  Index: RenderHandler.java
  ===================================================================
  package org.jboss.seam.exceptions;
  
  import org.jboss.seam.core.Conversation;
  import org.jboss.seam.util.Transactions;
  
  public abstract class RenderHandler extends ExceptionHandler
  {
  
     @Override
     public Object handle(Exception e) throws Exception
     {
        addFacesMessage( e, getMessage(e) );
        if ( isEnd(e) ) Conversation.instance().end();
        if ( isRollback(e) ) Transactions.setTransactionRollbackOnly();
        render( getViewId(e) );
        return null;
     }
  
  }
  
  


From gavin.king at jboss.com  Sun Dec 17 14:46:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 14:46:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pages         ...
Message-ID: <E1Gw1y5-0006yV-Ov@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 14:46:41

  Added:       src/main/org/jboss/seam/pages         ActionNavigation.java
                        ConversationControl.java NavigationHandler.java
                        Outcome.java Page.java Param.java
                        RedirectNavigationHandler.java
                        RenderNavigationHandler.java
  Log:
  refactor all the inner classes
  
  Revision  Changes    Path
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/ActionNavigation.java
  
  Index: ActionNavigation.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import java.util.HashMap;
  import java.util.Map;
  
  import org.jboss.seam.core.Expressions.ValueBinding;
  
  public final class ActionNavigation
  {
     private ValueBinding<Object> outcomeValueBinding;
     private Map<String, Outcome> outcomes = new HashMap<String, Outcome>();
     private Outcome nullOutcome;
     private Outcome anyOutcome;
     
     public Map<String, Outcome> getOutcomes()
     {
        return outcomes;
     }
     
     public void setNullOutcome(Outcome outcome)
     {
        this.nullOutcome = outcome;
     }
     public Outcome getNullOutcome()
     {
        return nullOutcome;
     }
     
     public void setOutcomeValueBinding(ValueBinding<Object> outcomeValueBinding)
     {
        this.outcomeValueBinding = outcomeValueBinding;
     }
     public ValueBinding<Object> getOutcomeValueBinding()
     {
        return outcomeValueBinding;
     }
  
     public Outcome getAnyOutcome()
     {
        return anyOutcome;
     }
     public void setAnyOutcome(Outcome outcome)
     {
        this.anyOutcome = outcome;
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/ConversationControl.java
  
  Index: ConversationControl.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import org.jboss.seam.annotations.FlushModeType;
  import org.jboss.seam.core.Conversation;
  import org.jboss.seam.core.Pageflow;
  
  public class ConversationControl
  {
  
     private boolean isBeginConversation;
     private boolean isEndConversation;
     private boolean join;
     private boolean nested;
     private FlushModeType flushMode;
     private String pageflow;
     
     public boolean isBeginConversation()
     {
        return isBeginConversation;
     }
  
     public void setBeginConversation(boolean isBeginConversation)
     {
        this.isBeginConversation = isBeginConversation;
     }
  
     public boolean isEndConversation()
     {
        return isEndConversation;
     }
  
     public void setEndConversation(boolean isEndConversation)
     {
        this.isEndConversation = isEndConversation;
     }
     
     public void beginOrEndConversation()
     {
        if ( isEndConversation )
        {
           Conversation.instance().end();
        }
        if ( isBeginConversation )
        {
           boolean begun = Conversation.instance().begin(join, nested);
           if (begun)
           {
              if (flushMode!=null)
              {
                 Conversation.instance().changeFlushMode(flushMode);
              }
              if ( pageflow!=null  )
              {
                 Pageflow.instance().begin(pageflow);
              }
           }
        }
     }
  
     public FlushModeType getFlushMode()
     {
        return flushMode;
     }
  
     public void setFlushMode(FlushModeType flushMode)
     {
        this.flushMode = flushMode;
     }
  
     public boolean isJoin()
     {
        return join;
     }
  
     public void setJoin(boolean join)
     {
        this.join = join;
     }
  
     public boolean isNested()
     {
        return nested;
     }
  
     public void setNested(boolean nested)
     {
        this.nested = nested;
     }
  
     public String getPageflow()
     {
        return pageflow;
     }
  
     public void setPageflow(String pageflow)
     {
        this.pageflow = pageflow;
     }
     
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/NavigationHandler.java
  
  Index: NavigationHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import javax.faces.context.FacesContext;
  
  import org.jboss.seam.core.Navigator;
  
  public abstract class NavigationHandler extends Navigator
  {
     public abstract void navigate(FacesContext context);
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Outcome.java
  
  Index: Outcome.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  public final class Outcome
  {
     private NavigationHandler navigationHandler;
     private ConversationControl conversationControl = new ConversationControl();
  
     public NavigationHandler getNavigationHandler()
     {
        return navigationHandler;
     }
  
     public void setNavigationHandler(NavigationHandler result)
     {
        this.navigationHandler = result;
     }
  
     public ConversationControl getConversationControl()
     {
        return conversationControl;
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Page.java
  
  Index: Page.java
  ===================================================================
  package org.jboss.seam.pages;
  
  import java.util.ArrayList;
  import java.util.HashMap;
  import java.util.List;
  import java.util.Map;
  import java.util.MissingResourceException;
  
  
  import org.jboss.seam.core.Interpolator;
  import org.jboss.seam.core.Locale;
  import org.jboss.seam.core.Expressions.MethodBinding;
  
  /**
   * Metadata about page actions, page parameters, action navigation,
   * resource bundle, etc, for a particular JSF view id.
   */
  public final class Page
  {
     private final String viewId;
     private String description;
     private Integer timeout;
     private MethodBinding action;
     private String outcome;
     private String noConversationViewId;
     private String resourceBundleName;
     private boolean switchEnabled = true;
     private List<Param> pageParameters = new ArrayList<Param>();
     private Map<String, ActionNavigation> navigations = new HashMap<String, ActionNavigation>();
     private ActionNavigation defaultNavigation;
     private boolean conversationRequired;
     private ConversationControl conversationControl = new ConversationControl();
     
     public Page(String viewId)
     {
        this.viewId = viewId;
        if (viewId!=null)
        {
           int loc = viewId.lastIndexOf('.');
           if ( loc>0 && viewId.startsWith("/") )
           {
              this.setResourceBundleName( viewId.substring(1, loc) );
           }
        }
     }
     
     public java.util.ResourceBundle getResourceBundle()
     {
        String resourceBundleName = getResourceBundleName();
        if (resourceBundleName==null)
        {
           return null;
        }
        else
        {
           try
           {
              return java.util.ResourceBundle.getBundle(
                    resourceBundleName, 
                    Locale.instance(), 
                    Thread.currentThread().getContextClassLoader()
                 );
           }
           catch (MissingResourceException mre)
           {
              return null;
           }
        }
     }
     
     @Override
     public String toString()
     {
        return "Page(" + getViewId() + ")";
     }
  
     public String getViewId()
     {
        return viewId;
     }
  
     public String renderDescription()
     {
        return Interpolator.instance().interpolate( getDescription() );
     }
     
     public void setDescription(String description)
     {
        this.description = description;
     }
  
     public String getDescription()
     {
        return description;
     }
  
     public void setTimeout(Integer timeout)
     {
        this.timeout = timeout;
     }
  
     public Integer getTimeout()
     {
        return timeout;
     }
  
     public void setAction(MethodBinding action)
     {
        this.action = action;
     }
  
     public MethodBinding getAction()
     {
        return action;
     }
  
     public void setOutcome(String outcome)
     {
        this.outcome = outcome;
     }
  
     public String getOutcome()
     {
        return outcome;
     }
  
     public void setNoConversationViewId(String noConversationViewId)
     {
        this.noConversationViewId = noConversationViewId;
     }
  
     public String getNoConversationViewId()
     {
        return noConversationViewId;
     }
  
     public void setResourceBundleName(String resourceBundleName)
     {
        this.resourceBundleName = resourceBundleName;
     }
  
     public String getResourceBundleName()
     {
        return resourceBundleName;
     }
  
     public void setSwitchEnabled(boolean switchEnabled)
     {
        this.switchEnabled = switchEnabled;
     }
  
     public boolean isSwitchEnabled()
     {
        return switchEnabled;
     }
  
     public List<Param> getPageParameters()
     {
        return pageParameters;
     }
  
     public Map<String, ActionNavigation> getNavigations()
     {
        return navigations;
     }
  
     public boolean hasDescription()
     {
        return description!=null;
     }
     
     public boolean isConversationRequired()
     {
        return conversationRequired;
     }
  
     public void setConversationRequired(boolean conversationRequired)
     {
        this.conversationRequired = conversationRequired;
     }
  
     public ActionNavigation getDefaultNavigation()
     {
        return defaultNavigation;
     }
  
     public void setDefaultNavigation(ActionNavigation defaultActionOutcomeMapping)
     {
        this.defaultNavigation = defaultActionOutcomeMapping;
     }
  
     public ConversationControl getConversationControl()
     {
        return conversationControl;
     }
  
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Param.java
  
  Index: Param.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import java.util.Map;
  
  import javax.faces.context.FacesContext;
  import javax.faces.convert.Converter;
  
  import org.jboss.seam.core.Expressions.ValueBinding;
  
  public final class Param
  {
     private final String name;
     private ValueBinding valueBinding;
     private ValueBinding converterValueBinding;
     private String converterId;
     
     public Param(String name)
     {
        this.name = name;
     }
     
     public Converter getConverter()
     {
        if (converterId!=null)
        {
           return FacesContext.getCurrentInstance().getApplication().createConverter(converterId);
        }
        else if (converterValueBinding!=null)
        {
           return (Converter) converterValueBinding.getValue();
        }
        else if (valueBinding==null)
        {
           return null;
        }
        else
        {
           Class<?> type = valueBinding.getType();
           return FacesContext.getCurrentInstance().getApplication().createConverter(type);           
        }
     }
  
     public String getName()
     {
        return name;
     }
  
     public void setValueBinding(ValueBinding valueBinding)
     {
        this.valueBinding = valueBinding;
     }
  
     public ValueBinding getValueBinding()
     {
        return valueBinding;
     }
  
     public void setConverterValueBinding(ValueBinding converterValueBinding)
     {
        this.converterValueBinding = converterValueBinding;
     }
  
     public ValueBinding getConverterValueBinding()
     {
        return converterValueBinding;
     }
  
     public void setConverterId(String converterId)
     {
        this.converterId = converterId;
     }
  
     public String getConverterId()
     {
        return converterId;
     }
  
     @Override
     public String toString()
     {
        return "PageParameter(" + name + ")";
     }
  
     /**
      * Get the current value of a page or redirection parameter
      * from the model, and convert to a String
      */
     public Object getValueFromModel(FacesContext facesContext)
     {
        Object value = getValueBinding().getValue();
        if (value==null)
        {
           return null;
        }
        else
        {
           Converter converter = null;
           try
           {
              converter = getConverter();
           }
           catch (RuntimeException re)
           {
              //YUCK! due to bad JSF/MyFaces error handling
              return null;
           }
           
           return converter==null ? 
                 value : 
                 converter.getAsString( facesContext, facesContext.getViewRoot(), value );
        }
     }
  
     /**
      * Get the current value of a page parameter from the request parameters
      */
     public Object getValueFromRequest(FacesContext facesContext, Map<String, String[]> requestParameters)
     {
        String[] parameterValues = requestParameters.get( getName() );
        if (parameterValues==null || parameterValues.length==0)
        {
           return null;
        }
        if (parameterValues.length>1)
        {
           throw new IllegalArgumentException("page parameter may not be multi-valued: " + getName());
        }         
        String stringValue = parameterValues[0];
     
        Converter converter = null;
        try
        {
           converter = getConverter();
        }
        catch (RuntimeException re)
        {
           //YUCK! due to bad JSF/MyFaces error handling
           return null;
        }
        
        return converter==null ? 
              stringValue :
              converter.getAsObject( facesContext, facesContext.getViewRoot(), stringValue );
     }
  
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/RedirectNavigationHandler.java
  
  Index: RedirectNavigationHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import java.util.HashMap;
  import java.util.List;
  import java.util.Map;
  
  import javax.faces.context.FacesContext;
  
  public final class RedirectNavigationHandler extends NavigationHandler
  {
     private final String viewId;
     private final List<Param> params;
  
     public RedirectNavigationHandler(String viewId, List<Param> params)
     {
        this.viewId = viewId;
        this.params = params;
     }
  
     @Override
     public void navigate(FacesContext context)
     {
        Map<String, Object> parameters = new HashMap<String, Object>();
        for ( Param pageParameter: params )
        {
           parameters.put( pageParameter.getName(), pageParameter.getValueFromModel(context) );
        }
        redirect(viewId, parameters);
     }
  }
  
  
  1.1      date: 2006/12/17 19:46:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/RenderNavigationHandler.java
  
  Index: RenderNavigationHandler.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import javax.faces.context.FacesContext;
  
  public final class RenderNavigationHandler extends NavigationHandler
  {
     private final String viewId;
  
     public RenderNavigationHandler(String viewId)
     {
        this.viewId = viewId;
     }
  
     @Override
     public void navigate(FacesContext context)
     {
        render(viewId);
     }
  }
  
  


From gavin.king at jboss.com  Sun Dec 17 14:56:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 14:56:04 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gw27A-00075R-42@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 14:56:04

  Removed:     src/main/org/jboss/seam/core  Page.java
  Log:
  remove obsolete


From gavin.king at jboss.com  Sun Dec 17 15:33:19 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 15:33:19 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gw2hD-0007nH-IX@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 15:33:19

  Modified:    src/main/org/jboss/seam/core  FacesMessages.java
  Log:
  convenience methods
  
  Revision  Changes    Path
  1.25      +14 -1     jboss-seam/src/main/org/jboss/seam/core/FacesMessages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FacesMessages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/FacesMessages.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- FacesMessages.java	24 Nov 2006 23:15:17 -0000	1.24
  +++ FacesMessages.java	17 Dec 2006 20:33:19 -0000	1.25
  @@ -262,9 +262,22 @@
         return messageTemplate;
      }
   
  +   public void add(String id, InvalidValue iv)
  +   {
  +      add( id, FacesMessage.SEVERITY_WARN, iv.getMessage() );
  +   }
  +   
  +   public void add(InvalidValue[] ivs)
  +   {
  +      for (InvalidValue iv: ivs)
  +      {
  +         add(iv);
  +      }
  +   }
  +   
      public void add(InvalidValue iv)
      {
  -      add( iv.getPropertyName(), FacesMessage.SEVERITY_WARN, iv.getMessage() );
  +      add( iv.getPropertyName(), iv );
      }
      
      public static FacesMessage createFacesMessage(Severity severity, String messageTemplate, Object... params)
  
  
  


From yfdsa987456 at Safe-mail.net  Sun Dec 17 17:58:27 2006
From: yfdsa987456 at Safe-mail.net (yfdsa987456 at Safe-mail.net)
Date: Sun, 17 Dec 2006 17:58:27 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCoMKCw4HCgsOEwoLDqcKCw6bCgsOLwoFIwoFI?=
	=?utf-8?b?woFI?=
Message-ID: 20040414001527.24089mail@mail.sdujysdujnjdfnkjfaueajkdnfjksdfnmdnfsjh.com

?????????????????????H
?????O?f???????M?????A?h???X???????????????????????????B
?Z???????????????????????H
?????A?h???XPC???????g?????????????????????????H
????????????????????
http://allfreefree.hitodumadeai.jp.ksjer.com/bb/
?u???????????v?????^?C?g??????????????





From gavin.king at jboss.com  Sun Dec 17 19:29:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 19:29:03 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF   ...
Message-ID: <E1Gw6NL-0003WK-8z@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 19:29:03

  Modified:    src/ui/META-INF   faces-config.xml seam.taglib.xml
  Log:
  added s:validationFailure
  
  Revision  Changes    Path
  1.25      +10 -0     jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- faces-config.xml	12 Dec 2006 22:38:26 -0000	1.24
  +++ faces-config.xml	18 Dec 2006 00:29:03 -0000	1.25
  @@ -493,4 +493,14 @@
           <converter-id>org.jboss.seam.ui.EnumConverter</converter-id> 
           <converter-class>org.jboss.seam.ui.EnumConverter</converter-class>    
       </converter>
  +
  +    <component>
  +        <component-type>org.jboss.seam.ui.UIValidationFailed</component-type>
  +        <component-class>org.jboss.seam.ui.UIValidationFailed</component-class>
  +        <property>
  +            <property-name>action</property-name>
  +            <property-class>java.lang.String</property-class>
  +        </property>
  +    </component>
  +    
   </faces-config>
  
  
  
  1.21      +7 -0      jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- seam.taglib.xml	12 Dec 2006 22:38:26 -0000	1.20
  +++ seam.taglib.xml	18 Dec 2006 00:29:03 -0000	1.21
  @@ -77,6 +77,13 @@
       </tag>
     
       <tag>
  +        <tag-name>validationFailed</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.ui.UIValidationFailed</component-type>
  +        </component>
  +    </tag>
  +  
  +    <tag>
           <tag-name>message</tag-name>
           <component>
               <component-type>org.jboss.seam.ui.HtmlMessageDecoration</component-type>
  
  
  


From gavin.king at jboss.com  Sun Dec 17 19:29:03 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 19:29:03 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1Gw6NL-0003WU-C9@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 19:29:03

  Added:       src/ui/org/jboss/seam/ui   AfterValidationEvent.java
                        UIValidationFailed.java
  Log:
  added s:validationFailure
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 00:29:03;  author: gavin;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/AfterValidationEvent.java
  
  Index: AfterValidationEvent.java
  ===================================================================
  package org.jboss.seam.ui;
  
  import javax.faces.component.UIComponent;
  import javax.faces.event.FacesEvent;
  import javax.faces.event.FacesListener;
  
  
  public class AfterValidationEvent extends FacesEvent
  {
     public AfterValidationEvent(UIComponent component)
     {
        super(component);
     }
  
     @Override
     public boolean isAppropriateListener(FacesListener listener)
     {
        return false;
     }
  
     @Override
     public void processListener(FacesListener listener)
     {
        throw new UnsupportedOperationException();
     }
  }
  
  
  1.1      date: 2006/12/18 00:29:03;  author: gavin;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/UIValidationFailed.java
  
  Index: UIValidationFailed.java
  ===================================================================
  package org.jboss.seam.ui;
  
  import javax.faces.context.FacesContext;
  import javax.faces.event.AbortProcessingException;
  import javax.faces.event.FacesEvent;
  
  
  public class UIValidationFailed extends javax.faces.component.UICommand
  {
     
     @Override
     public String getRendererType()
     {
        return null;
     }
     
     @Override
     public void processValidators(FacesContext context)
     {
        super.processValidators(context);
        new AfterValidationEvent(this).queue();
     }
     
     @Override
     public void broadcast(FacesEvent event) throws AbortProcessingException
     {
        super.broadcast(event);
        if (event instanceof AfterValidationEvent)
        {
           if ( FacesContext.getCurrentInstance().getRenderResponse() )
           {
              //validation failed
              getAction().invoke( FacesContext.getCurrentInstance(), null );
           }
        }
     }
     
  }
  
  
  


From fd4dsaf at kittymail.com  Sun Dec 17 19:32:00 2006
From: fd4dsaf at kittymail.com (fd4dsaf at kittymail.com)
Date: Sun, 17 Dec 2006 19:32:00 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCscKCwr/CgsOnwoLDjMKNw4TCim3ClEbCgsOw?=
	=?utf-8?b?woLCqMKKw6jCgsKiwoLCtcKCw5zCgsK3woFC?=
Message-ID: 20061204095907.70516mail@mail.pqosisudcbvdgeterukadslaij_web.com

?@?@?@?@?@??????????????????????????????
?@?@?@?@?@?f?G???o?????????????????????H
?@?@?@?@?@??????????????????????????????

http://freeweb.lovelovesexywoman.tonderuyo.com/lc/

????????????????????????????????????????????????????????
?o?^???E???p???E?E?E?E?E?E?E?E?E?y?????z
???[?????????M?E?E?E?E?E?E?E?E?E?y?????z
???[?U?[???????E?E?E?E?E?E?E?E?E?y?????z
?f???????{???E???????E?E?E?E?E?E?y?????z
?????????E?A?b?v???[?h?E?E?E?E?E?y?????z
?A?h???X?????E?d?b?????????E?E?E?y?????z

???????A?T?C?g???p?????S?????I

http://freeweb.lovelovesexywoman.tonderuyo.com/lc/
????????????????????????????????????????????????????????

?@?@?@?@?@?????????????????l????????????
-------------------------------------------------
???O?E?E?E??????????
?N???E?E?E26??
?E???E?E?E?n?k
???]?E?E?E?D?????l?E?????????????l
?????E?E?E??????????????????????????
???^?E?E?@http://freeweb.lovelovesexywoman.tonderuyo.com/lc/
?????E?E?E?????????????D???????????????l????????????
???M?E?E?@http://freeweb.lovelovesexywoman.tonderuyo.com/lc/
-------------------------------------------------
???O?E?E?E?z?q????
?N???E?E?E38??
?E???E?E?E?h?s???A
???]?E?E?E???N???????N??????????
?????E?E?E????10???????????B
???^?E?E?@http://freeweb.lovelovesexywoman.tonderuyo.com/lc/
?????E?E?E?o?c?C?`?????B?????????????W?????]?????B
???M?E?E?@http://freeweb.lovelovesexywoman.tonderuyo.com/lc/
-------------------------------------------------
?T?C?g?????@http://freeweb.lovelovesexywoman.tonderuyo.com/lc/



From gavin.king at jboss.com  Sun Dec 17 20:46:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 20:46:24 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gw7aC-0004yf-I6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 20:46:24

  Modified:    src/main/org/jboss/seam/core  Manager.java
  Log:
  add s:forceModelUpdate
  
  Revision  Changes    Path
  1.128     +27 -1     jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.127
  retrieving revision 1.128
  diff -u -b -r1.127 -r1.128
  --- Manager.java	17 Dec 2006 19:46:41 -0000	1.127
  +++ Manager.java	18 Dec 2006 01:46:24 -0000	1.128
  @@ -20,6 +20,7 @@
   import javax.faces.application.FacesMessage;
   import javax.faces.context.ExternalContext;
   import javax.faces.context.FacesContext;
  +import javax.faces.el.MethodBinding;
   import javax.faces.event.PhaseId;
   
   import org.jboss.seam.log.LogProvider;
  @@ -42,7 +43,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.127 $
  + * @version $Revision: 1.128 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -1122,4 +1123,29 @@
         this.parentConversationIdParameter = nestedConversationIdParameter;
      }
   
  +   private boolean forceModelUpdate;
  +   private MethodBinding validationFailedAction;
  +   
  +   public void setValidationFailedAction(MethodBinding action)
  +   {
  +      validationFailedAction = action;
  +   }
  +   
  +   public void setForceModelUpdate()
  +   {
  +      forceModelUpdate = true;
  +   }
  +   
  +   public void afterValidationFailure(FacesContext ctx)
  +   {
  +      if (forceModelUpdate)
  +      {
  +         ctx.getViewRoot().processUpdates(ctx);
  +      }
  +      if (validationFailedAction!=null)
  +      {
  +         validationFailedAction.invoke(ctx, null);
  +      }
  +   }
  +
   }
  
  
  


From gavin.king at jboss.com  Sun Dec 17 20:46:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 20:46:24 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf    ...
Message-ID: <E1Gw7aC-0004ys-Nb@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 20:46:24

  Modified:    src/main/org/jboss/seam/jsf   
                        AbstractSeamPhaseListener.java
                        SeamPhaseListener.java
                        SeamPortletPhaseListener.java
  Log:
  add s:forceModelUpdate
  
  Revision  Changes    Path
  1.32      +8 -0      jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- AbstractSeamPhaseListener.java	17 Dec 2006 17:45:37 -0000	1.31
  +++ AbstractSeamPhaseListener.java	18 Dec 2006 01:46:24 -0000	1.32
  @@ -322,4 +322,12 @@
         }
      }
   
  +   protected void afterProcessValidations(FacesContext facesContext)
  +   {
  +      if ( facesContext.getRenderResponse() )
  +      {
  +         Manager.instance().afterValidationFailure(facesContext);
  +      }
  +   }
  +
   }
  
  
  
  1.95      +6 -1      jboss-seam/src/main/org/jboss/seam/jsf/SeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamPhaseListener.java,v
  retrieving revision 1.94
  retrieving revision 1.95
  diff -u -b -r1.94 -r1.95
  --- SeamPhaseListener.java	16 Dec 2006 02:58:11 -0000	1.94
  +++ SeamPhaseListener.java	18 Dec 2006 01:46:24 -0000	1.95
  @@ -10,6 +10,7 @@
   import static javax.faces.event.PhaseId.INVOKE_APPLICATION;
   import static javax.faces.event.PhaseId.RENDER_RESPONSE;
   import static javax.faces.event.PhaseId.RESTORE_VIEW;
  +import static javax.faces.event.PhaseId.PROCESS_VALIDATIONS;
   
   import javax.faces.context.FacesContext;
   import javax.faces.event.PhaseEvent;
  @@ -50,7 +51,7 @@
         {
            beforeRender(event);
         }
  -      else if ( event.getPhaseId()== APPLY_REQUEST_VALUES )
  +      else if ( event.getPhaseId() == APPLY_REQUEST_VALUES )
         {
            beforeUpdateModelValues(event);
         }
  @@ -76,6 +77,10 @@
         {
            afterInvokeApplication();
         }
  +      else if ( event.getPhaseId() == PROCESS_VALIDATIONS )
  +      {
  +         afterProcessValidations( event.getFacesContext() );
  +      }
               
         //has to happen after, since restoreAnyConversationContext() 
         //can add messages
  
  
  
  1.18      +5 -26     jboss-seam/src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamPortletPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- SeamPortletPhaseListener.java	16 Dec 2006 02:58:11 -0000	1.17
  +++ SeamPortletPhaseListener.java	18 Dec 2006 01:46:24 -0000	1.18
  @@ -8,6 +8,7 @@
   
   import static javax.faces.event.PhaseId.APPLY_REQUEST_VALUES;
   import static javax.faces.event.PhaseId.INVOKE_APPLICATION;
  +import static javax.faces.event.PhaseId.PROCESS_VALIDATIONS;
   import static javax.faces.event.PhaseId.RENDER_RESPONSE;
   import static javax.faces.event.PhaseId.RESTORE_VIEW;
   
  @@ -83,6 +84,10 @@
         {
            afterInvokeApplication();
         }
  +      else if ( event.getPhaseId() == PROCESS_VALIDATIONS )
  +      {
  +         afterProcessValidations( event.getFacesContext() );
  +      }
         
         FacesMessages.afterPhase();
         
  @@ -109,32 +114,6 @@
       * Write out the conversation id as a servlet response header or portlet
       * render parameter.
       */
  -   /*private static void writeConversationIdToResponse(Object response)
  -   {
  -      Manager manager = Manager.instance();
  -      String conversationIdParameter = manager.getConversationIdParameter();
  -      String conversationId;
  -      if ( manager.isLongRunningConversation() )
  -      {
  -         conversationId = manager.getCurrentConversationId();
  -      }
  -      else if ( manager.isNestedConversation() )
  -      {
  -         conversationId = manager.getParentConversationId();
  -      }
  -      else
  -      {
  -         //nothing to set
  -         return;
  -      }
  -      //setResponseHeader(response, conversationIdParameter, conversationId);
  -      setPortletRenderParameter(response, conversationIdParameter, conversationId);
  -   }*/
  -
  -   /**
  -    * Write out the conversation id as a servlet response header or portlet
  -    * render parameter.
  -    */
      private static void writeConversationIdToResponse(Object response)
      {
         Manager manager = Manager.instance();
  
  
  


From gavin.king at jboss.com  Sun Dec 17 20:46:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 20:46:24 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF   ...
Message-ID: <E1Gw7aC-0004z2-Se@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 20:46:24

  Modified:    src/ui/META-INF   faces-config.xml seam.taglib.xml
  Log:
  add s:forceModelUpdate
  
  Revision  Changes    Path
  1.26      +5 -0      jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- faces-config.xml	18 Dec 2006 00:29:03 -0000	1.25
  +++ faces-config.xml	18 Dec 2006 01:46:24 -0000	1.26
  @@ -503,4 +503,9 @@
           </property>
       </component>
       
  +    <component>
  +        <component-type>org.jboss.seam.ui.UIForceModelUpdate</component-type>
  +        <component-class>org.jboss.seam.ui.UIForceModelUpdate</component-class>
  +    </component>
  +    
   </faces-config>
  
  
  
  1.22      +9 -1      jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- seam.taglib.xml	18 Dec 2006 00:29:03 -0000	1.21
  +++ seam.taglib.xml	18 Dec 2006 01:46:24 -0000	1.22
  @@ -84,6 +84,13 @@
       </tag>
     
       <tag>
  +        <tag-name>forceModelUpdate</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.ui.UIForceModelUpdate</component-type>
  +        </component>
  +    </tag>
  +  
  +    <tag>
           <tag-name>message</tag-name>
           <component>
               <component-type>org.jboss.seam.ui.HtmlMessageDecoration</component-type>
  @@ -138,4 +145,5 @@
               <converter-id>org.jboss.seam.ui.EnumConverter</converter-id>
           </converter>
       </tag>
  +    
   </facelet-taglib>
  
  
  


From gavin.king at jboss.com  Sun Dec 17 20:46:25 2006
From: gavin.king at jboss.com (Gavin King)
Date: Sun, 17 Dec 2006 20:46:25 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui    ...
Message-ID: <E1Gw7aD-0004zC-1x@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/17 20:46:25

  Modified:    src/ui/org/jboss/seam/ui    UIValidationFailed.java
  Added:       src/ui/org/jboss/seam/ui    UIForceModelUpdate.java
  Removed:     src/ui/org/jboss/seam/ui    AfterValidationEvent.java
  Log:
  add s:forceModelUpdate
  
  Revision  Changes    Path
  1.2       +3 -17     jboss-seam/src/ui/org/jboss/seam/ui/UIValidationFailed.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIValidationFailed.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/UIValidationFailed.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIValidationFailed.java	18 Dec 2006 00:29:03 -0000	1.1
  +++ UIValidationFailed.java	18 Dec 2006 01:46:25 -0000	1.2
  @@ -1,8 +1,8 @@
   package org.jboss.seam.ui;
   
   import javax.faces.context.FacesContext;
  -import javax.faces.event.AbortProcessingException;
  -import javax.faces.event.FacesEvent;
  +
  +import org.jboss.seam.core.Manager;
   
   
   public class UIValidationFailed extends javax.faces.component.UICommand
  @@ -18,21 +18,7 @@
      public void processValidators(FacesContext context)
      {
         super.processValidators(context);
  -      new AfterValidationEvent(this).queue();
  -   }
  -   
  -   @Override
  -   public void broadcast(FacesEvent event) throws AbortProcessingException
  -   {
  -      super.broadcast(event);
  -      if (event instanceof AfterValidationEvent)
  -      {
  -         if ( FacesContext.getCurrentInstance().getRenderResponse() )
  -         {
  -            //validation failed
  -            getAction().invoke( FacesContext.getCurrentInstance(), null );
  -         }
  -      }
  +      Manager.instance().setValidationFailedAction( getAction() );
      }
      
   }
  
  
  
  1.1      date: 2006/12/18 01:46:25;  author: gavin;  state: Exp;jboss-seam/src/ui/org/jboss/seam/ui/UIForceModelUpdate.java
  
  Index: UIForceModelUpdate.java
  ===================================================================
  package org.jboss.seam.ui;
  
  import javax.faces.component.UIComponentBase;
  import javax.faces.context.FacesContext;
  
  import org.jboss.seam.core.Manager;
  
  
  public class UIForceModelUpdate extends UIComponentBase
  {
  
     public static final String COMPONENT_FAMILY = "org.jboss.seam.ui.ForceModelUpdate";
  
     @Override
     public String getFamily()
     {
        return COMPONENT_FAMILY;
     }
     
     @Override
     public void processValidators(FacesContext ctx)
     {
        super.processValidators(ctx);
        Manager.instance().setForceModelUpdate();
     }
  
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 17 22:53:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 17 Dec 2006 22:53:12 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1809 - in trunk:
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/tools/jmx
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1Gw9Yu-0007Gp-Ne@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-17 22:53:08 -0500 (Sun, 17 Dec 2006)
New Revision: 1809

Modified:
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java
Log:
Eliminated redundancies, other minor refactorin


Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-17 04:41:26 UTC (rev 1808)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-18 03:53:08 UTC (rev 1809)
@@ -46,9 +46,9 @@
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.util.JNDIUtil;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.contract.ReplicationListener;
 import org.jboss.messaging.core.plugin.contract.Replicator;
+import org.jboss.messaging.core.plugin.contract.FailoverMapper;
 import org.jboss.messaging.core.plugin.postoffice.cluster.DefaultClusteredPostOffice;
 
 /**
@@ -63,17 +63,17 @@
    implements ConnectionFactoryManager, ReplicationListener
 {
    // Constants -----------------------------------------------------
-   
+
    private static final Logger log = Logger.getLogger(ConnectionFactoryJNDIMapper.class);
-   
+
    // Static --------------------------------------------------------
-   
+
    private static final String CF_PREFIX = "CF_";
-   
+
    // Attributes ----------------------------------------------------
 
    private boolean trace = log.isTraceEnabled();
-   
+
    protected Context initialContext;
    protected ServerPeer serverPeer;
 
@@ -82,25 +82,25 @@
 
    // Map<uniqueName<String> - ClientConnectionFactoryDelegate> (not just clustered delegates)
    protected Map delegates;
-   
-   protected Replicator replicator;
-   
+
+   private Replicator replicator;
+
    /*
    We cache the map of node->failover node in here.
    This is then updated when node joins or leaves the cluster via the replicationListener
    When new cfs are deployed we use the cached map
    */
    protected Map failoverMap;
-   
+
    // Constructors --------------------------------------------------
-   
+
    public ConnectionFactoryJNDIMapper(ServerPeer serverPeer) throws Exception
    {
       this.serverPeer = serverPeer;
       endpoints = new HashMap();
       delegates = new HashMap();
    }
-   
+
    // ConnectionFactoryManager implementation -----------------------
 
    public synchronized void registerConnectionFactory(String uniqueName,
@@ -116,15 +116,14 @@
       throws Exception
    {
       log.debug(this + " registering connection factory '" + uniqueName + "', bindings: " + jndiBindings);
-      
+
       // Sanity check
       if (delegates.containsKey(uniqueName))
       {
          throw new IllegalArgumentException("There's already a connection factory registered with name " + uniqueName);
       }
-      
+
       int id = serverPeer.getNextObjectID();
-      
       Version version = serverPeer.getVersion();
 
       ServerConnectionFactoryEndpoint endpoint =
@@ -134,7 +133,7 @@
                                              defaultTempQueuePageSize,
                                              defaultTempQueueDownCacheSize);
       endpoints.put(uniqueName, endpoint);
-      
+
       ClientConnectionFactoryDelegate delegate = null;
 
       if (clustered)
@@ -145,65 +144,64 @@
       {
          log.info("ConnectionFactoryJNDIMapper is non clustered");
       }
-      
+
       boolean creatingClustered = clustered && replicator != null;
-      
+
       ClientConnectionFactoryDelegate localDelegate =
          new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
                                              locatorURI, version, clientPing);
-      
-      /*
-       * When registering a new clustered connection factory i should first create it with the available delegates
-       * then send the replication message.
-       * We then listen for connection factories added to global state using the replication listener
-       * and then update their connection factory list.
-       * This will happen locally too, so we will get the replication message locally - to avoid updating it again
-       * we can ignore any "add" replication updates that originate from the current node.
-       */
-      
+
+      // When registering a new clustered connection factory I should first create it with the
+      // available delegates then send the replication message. We then listen for connection
+      // factories added to global state using the replication listener and then update their
+      // connection factory list. This will happen locally too, so we will get the replication
+      // message locally - to avoid updating it again we can ignore any "add" replication updates
+      // that originate from the current node.
+
       if (creatingClustered)
       {
-         //Replicate the change - we will ignore this locally
-         
+         // Replicate the change - we will ignore this locally
+
          replicator.put(CF_PREFIX + uniqueName, localDelegate);
-         
-         //Create a clustered delegate
-         
+
+         // Create a clustered delegate
+
          Map localDelegates = replicator.get(CF_PREFIX + uniqueName);
-         
-         delegate = createClusteredDelegate(localDelegates);
-         
+         delegate = createClusteredDelegate(localDelegates.values());
+
       }
       else
       {
          delegate = localDelegate;
       }
-      
-      log.trace("Adding delegates factory " + uniqueName + " pointing to " + delegate);
-      
+
+      log.trace(this + " adding delegates factory " + uniqueName + " pointing to " + delegate);
+
       delegates.put(uniqueName, delegate);
 
-      //Now bind it in JNDI
+      // Now bind it in JNDI
       rebindConnectionFactory(initialContext, jndiBindings, delegate);
-      
-      //Registering with the dispatcher should always be the last thing otherwise a client could use
-      //a partially initialised object
-      JMSDispatcher.instance.registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
+
+      // Registering with the dispatcher should always be the last thing otherwise a client could
+      // use a partially initialised object
+      JMSDispatcher.instance.
+         registerTarget(new Integer(id), new ConnectionFactoryAdvised(endpoint));
    }
-   
-   public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered) throws Exception
+
+   public synchronized void unregisterConnectionFactory(String uniqueName, boolean clustered)
+      throws Exception
    {
       log.trace("ConnectionFactory " + uniqueName + " being unregistered");
       ServerConnectionFactoryEndpoint endpoint =
          (ServerConnectionFactoryEndpoint)endpoints.remove(uniqueName);
-      
+
       if (endpoint == null)
       {
          throw new IllegalArgumentException("Cannot find endpoint with name " + uniqueName);
       }
-      
+
       JNDIBindings jndiBindings = endpoint.getJNDIBindings();
-      
+
       if (jndiBindings != null)
       {
          List jndiNames = jndiBindings.getNames();
@@ -220,65 +218,70 @@
 
       ClientConnectionFactoryDelegate delegate =
          (ClientConnectionFactoryDelegate)delegates.remove(uniqueName);
-      
+
       if (delegate == null)
       {
          throw new IllegalArgumentException("Cannot find factory with name " + uniqueName);
       }
-      
+
       if (clustered)
       {
          setupReplicator();
-         
-         // Remove from replicants
 
+         // Remove from replicants
          if (replicator != null)
-         {         
+         {
             //There may be no clustered post office deployed
             if (!replicator.remove(CF_PREFIX + uniqueName))
             {
                throw new IllegalStateException("Cannot find replicant to remove: " + CF_PREFIX + uniqueName);
             }
          }
-         
+
       }
-      
+
       JMSDispatcher.instance.unregisterTarget(new Integer(endpoint.getID()));
    }
-   
+
    // MessagingComponent implementation -----------------------------
-   
+
    public void start() throws Exception
    {
       initialContext = new InitialContext();
-      
+
       log.debug("started");
    }
-   
+
    public void stop() throws Exception
    {
       initialContext.close();
-      
+
       if (replicator != null)
       {
          replicator.unregisterListener(this);
       }
-      
+
       log.debug("stopped");
    }
-   
+
    // ReplicationListener interface ----------------------------------
-   
+
+   /**
+    * @param updatedReplicantMap Map<Integer(nodeID)-Map<>>
+    */
    public synchronized void onReplicationChange(Serializable key, Map updatedReplicantMap,
-                                                boolean added, int originatingNodeId)
+                                                boolean added, int originatorNodeID)
    {
+      log.debug(this + " received " + key + " replication change from node " + originatorNodeID +
+         ": " + updatedReplicantMap);
+
       try
-      {         
+      {
          if (!(key instanceof String))
          {
             return;
          }
-         
+
          String sKey = (String)key;
 
          if (sKey.equals(DefaultClusteredPostOffice.ADDRESS_INFO_KEY))
@@ -291,7 +294,7 @@
             // reference a single map since the objects are bound in JNDI in serialized form.
 
             recalculateFailoverMap(updatedReplicantMap);
-            
+
             // Rebind
 
             for(Iterator i = endpoints.entrySet().iterator(); i.hasNext(); )
@@ -300,20 +303,20 @@
                String uniqueName = (String)entry.getKey();
                ServerConnectionFactoryEndpoint endpoint =
                   (ServerConnectionFactoryEndpoint)entry.getValue();
-               
+
                ClusteredClientConnectionFactoryDelegate del =
                   (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
-               
+
                if (del == null)
                {
                   throw new IllegalStateException("Cannot find cf with name " + uniqueName);
                }
-               
+
                del.setFailoverMap(failoverMap);
                rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
             }
          }
-         else if (sKey.startsWith(CF_PREFIX) && originatingNodeId != serverPeer.getServerPeerID())
+         else if (sKey.startsWith(CF_PREFIX) && originatorNodeID != serverPeer.getServerPeerID())
          {
             // A connection factory has been deployed / undeployed - we need to update the local
             // delegate arrays inside the clustered connection factories with the same name. We
@@ -327,28 +330,28 @@
 
             ClusteredClientConnectionFactoryDelegate del =
                (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
-            
+
             if (del == null)
             {
                throw new IllegalStateException("Cannot find cf with name " + uniqueName);
             }
-            
+
             List newDels = sortCFS(updatedReplicantMap.values());
-            
-            ClientConnectionFactoryDelegate[] delArr = 
+
+            ClientConnectionFactoryDelegate[] delArr =
                (ClientConnectionFactoryDelegate[])newDels.
                   toArray(new ClientConnectionFactoryDelegate[newDels.size()]);
 
             del.setDelegates(delArr);
-            
+
             ServerConnectionFactoryEndpoint endpoint =
                (ServerConnectionFactoryEndpoint)endpoints.get(uniqueName);
-            
+
             if (endpoint == null)
             {
                throw new IllegalStateException("Cannot find endpoint with name " + uniqueName);
             }
-            
+
             rebindConnectionFactory(initialContext, endpoint.getJNDIBindings(), del);
          }
       }
@@ -357,13 +360,12 @@
          log.error("Failed to rebind connection factory", e);
       }
    }
-   
+
    // Public --------------------------------------------------------
-   
+
    public void injectReplicator(Replicator replicator)
    {
       this.replicator = replicator;
-      
       replicator.registerListener(this);
    }
 
@@ -371,61 +373,50 @@
    {
       return "Server[" + serverPeer.getServerPeerID() + "].ConnFactoryJNDIMapper";
    }
-   
+
    // Package protected ---------------------------------------------
-   
+
    // Protected -----------------------------------------------------
-   
+
    // Private -------------------------------------------------------
-   
+
    private void setupReplicator() throws Exception
    {
       this.serverPeer.getPostOfficeInstance();
    }
 
    private void recalculateFailoverMap(Map nodeAddressMap) throws Exception
-   {     
+   {
       FailoverMapper mapper = replicator.getFailoverMapper();
       failoverMap = mapper.generateMapping(nodeAddressMap.keySet());
-   }      
-   
+   }
+
    /**
     * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
     */
-   private ClusteredClientConnectionFactoryDelegate createClusteredDelegate(Map localDelegates)
-      throws Exception
+   private ClusteredClientConnectionFactoryDelegate
+      createClusteredDelegate(Collection localDelegates)  throws Exception
    {
-      if (trace) { log.trace(this + " updating failover delegates, map size " + localDelegates.size()); }
-      
-      //First sort the local delegates in order of server id
-      List localDels = sortCFS(localDelegates.values());
-      
-      Collections.sort(localDels,
-                       new Comparator()
-                       {
-                           public int compare(Object obj1, Object obj2)
-                           {
-                              ClientConnectionFactoryDelegate del1 = (ClientConnectionFactoryDelegate)obj1;
-                              ClientConnectionFactoryDelegate del2 = (ClientConnectionFactoryDelegate)obj2;
-                              return del1.getServerID() - del2.getServerID();
-                           } 
-                       });
+      if (trace) { log.trace(this + " updating failover delegates with " + localDelegates); }
 
-      ClientConnectionFactoryDelegate[] delArr = 
-         (ClientConnectionFactoryDelegate[])localDels.
-            toArray(new ClientConnectionFactoryDelegate[localDelegates.size()]);
+      // First sort the local delegates in order of server id
+      List sortedLocalDelegates = sortCFS(localDelegates);
 
+      ClientConnectionFactoryDelegate[] delegates =
+         (ClientConnectionFactoryDelegate[])sortedLocalDelegates.
+            toArray(new ClientConnectionFactoryDelegate[sortedLocalDelegates.size()]);
+
       // If the map is not cached - generate it now
-      
+
       if (failoverMap == null)
       {
          Map nodeAddressMap = replicator.get(DefaultClusteredPostOffice.ADDRESS_INFO_KEY);
-         
+
          if (nodeAddressMap == null)
          {
             throw new IllegalStateException("Cannot find address node mapping!");
          }
-         
+
          recalculateFailoverMap(nodeAddressMap);
       }
 
@@ -437,12 +428,12 @@
       // this loop.
 
       ClientConnectionFactoryDelegate mainDelegate = null;
-      
-      for(Iterator i = localDels.iterator(); i.hasNext();)
+
+      for(Iterator i = localDelegates.iterator(); i.hasNext();)
       {
          ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)i.next();
-         
-         if (del.getServerID() == this.serverPeer.getServerPeerID())
+
+         if (del.getServerID() == serverPeer.getServerPeerID())
          {
             // sanity check
             if (mainDelegate != null)
@@ -453,12 +444,11 @@
             mainDelegate = del;
          }
       }
-            
-      return new ClusteredClientConnectionFactoryDelegate(mainDelegate, delArr, failoverMap);
+
+      return new ClusteredClientConnectionFactoryDelegate(mainDelegate, delegates, failoverMap);
    }
-   
-   private void rebindConnectionFactory(Context ic,
-                                        JNDIBindings jndiBindings,
+
+   private void rebindConnectionFactory(Context ic, JNDIBindings jndiBindings,
                                         ClientConnectionFactoryDelegate delegate)
       throws NamingException
    {
@@ -475,25 +465,25 @@
          }
       }
    }
-   
-   /*
+
+   /**
     * Sort the collection of delegates in order of server id
     */
    private List sortCFS(Collection delegates)
    {
       List localDels = new ArrayList(delegates);
-      
+
       Collections.sort(localDels,
-                       new Comparator()
-                       {
-                           public int compare(Object obj1, Object obj2)
-                           {
-                              ClientConnectionFactoryDelegate del1 = (ClientConnectionFactoryDelegate)obj1;
-                              ClientConnectionFactoryDelegate del2 = (ClientConnectionFactoryDelegate)obj2;
-                              return del1.getServerID() - del2.getServerID();
-                           } 
-                       });
-      
+         new Comparator()
+         {
+            public int compare(Object obj1, Object obj2)
+            {
+               ClientConnectionFactoryDelegate del1 = (ClientConnectionFactoryDelegate)obj1;
+               ClientConnectionFactoryDelegate del2 = (ClientConnectionFactoryDelegate)obj2;
+               return del1.getServerID() - del2.getServerID();
+            }
+         });
+
       return localDels;
    }
 

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-17 04:41:26 UTC (rev 1808)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-18 03:53:08 UTC (rev 1809)
@@ -106,13 +106,47 @@
    private static final Logger log = Logger.getLogger(DefaultClusteredPostOffice.class);
 
    // Key for looking up node id -> address info mapping from replicated data
-   public static final String ADDRESS_INFO_KEY = "address_info";
+   public static final String ADDRESS_INFO_KEY = "ADDRESS_INFO";
 
    // Key for looking up node id -> failed over for node id mapping from replicated data
-   public static final String FAILED_OVER_FOR_KEY = "failed_over_for";
+   public static final String FAILED_OVER_FOR_KEY = "FAILED_OVER_FOR";
 
    // Static --------------------------------------------------------
 
+   /**
+    * @param map - Map<Integer(nodeID)-Integer(failoverNodeID)>
+    */
+   public static String dumpFailoverMap(Map map)
+   {
+      StringBuffer sb = new StringBuffer("\n");
+
+      for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
+      {
+         Map.Entry entry = (Map.Entry)i.next();
+         Integer primary = (Integer)entry.getKey();
+         Integer secondary = (Integer)entry.getValue();
+         sb.append("             ").append(primary).append("->").append(secondary).append("\n");
+      }
+      return sb.toString();
+   }
+
+   /**
+    * @param map - Map<Integer(nodeID)-PostOfficeAddressInfo>
+    */
+   public static String dumpClusterMap(Map map)
+   {
+      StringBuffer sb = new StringBuffer("\n");
+
+      for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
+      {
+         Map.Entry entry = (Map.Entry)i.next();
+         Integer nodeID = (Integer)entry.getKey();
+         PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
+         sb.append("             ").append(nodeID).append("->").append(info).append("\n");
+      }
+      return sb.toString();
+   }
+
    // Attributes ----------------------------------------------------
 
    // Used for failure testing
@@ -151,7 +185,7 @@
 
    private Map holdingArea;
 
-   //Map < node id , failover node id>
+   // Map <Integer(nodeID)->Integer(failoverNodeID)>
    private Map failoverMap;
 
    private Set leftSet;
@@ -2260,35 +2294,6 @@
       log.debug(this + " sent " + notificationType + " JMX notification");
    }
 
-   private String dumpClusterMap(Map map)
-   {
-      StringBuffer sb = new StringBuffer("\n");
-
-      for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
-      {
-         Map.Entry entry = (Map.Entry)i.next();
-         Integer nodeID = (Integer)entry.getKey();
-         PostOfficeAddressInfo info = (PostOfficeAddressInfo)entry.getValue();
-         sb.append("             ").append("nodeID ").append(nodeID).append(" - ").append(info).append("\n");
-      }
-      return sb.toString();
-   }
-
-   private String dumpFailoverMap(Map map)
-   {
-      StringBuffer sb = new StringBuffer("\n");
-
-      for(Iterator i = map.entrySet().iterator(); i.hasNext(); )
-      {
-         Map.Entry entry = (Map.Entry)i.next();
-         Integer primary = (Integer)entry.getKey();
-         Integer secondary = (Integer)entry.getValue();
-         sb.append("             ").append(primary).append("->").append(secondary).append("\n");
-      }
-      return sb.toString();
-   }
-
-
    // Inner classes -------------------------------------------------------------------
 
    /*
@@ -2308,7 +2313,7 @@
          }
          try
          {
-            if (trace) { log.trace(this + " got state"); }
+            if (trace) { log.trace(DefaultClusteredPostOffice.this + ".ControlMessageListener got state"); }
             return getStateAsBytes();
          }
          catch (Exception e)
@@ -2343,7 +2348,7 @@
             try
             {
                processStateBytes(bytes);
-               if (trace) { log.trace(this + " has set state"); }
+               if (trace) { log.trace(DefaultClusteredPostOffice.this + ".ControlMessageListener has set state"); }
             }
             catch (Exception e)
             {
@@ -2549,18 +2554,20 @@
    private class NodeAddressMapListener implements ReplicationListener
    {
       public void onReplicationChange(Serializable key, Map updatedReplicantMap,
-                                      boolean added, int originatorNodeId)
+                                      boolean added, int originatorNodeID)
       {
+         log.debug(DefaultClusteredPostOffice.this + " received " + key +
+            " replication change from node " + originatorNodeID + ": " + updatedReplicantMap);
+
          if (key instanceof String && ((String)key).equals(ADDRESS_INFO_KEY))
          {
             log.debug("Cluster map:\n" + dumpClusterMap(updatedReplicantMap));
 
-            // A node-address mapping has been added/removed from global state, we need to update
-            // the failover map.
-            failoverMap = failoverMapper.generateMapping(updatedReplicantMap.keySet());
-
-            log.debug("Failover map:\n" + dumpFailoverMap(failoverMap));
+               // A node-address mapping has been added/removed from global state, we need to update
+               // the failover map.
+               failoverMap = failoverMapper.generateMapping(updatedReplicantMap.keySet());
+               log.debug("Failover map:\n" + dumpFailoverMap(failoverMap));
+            }
          }
       }
-   }
 }
\ No newline at end of file

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-17 04:41:26 UTC (rev 1808)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-18 03:53:08 UTC (rev 1809)
@@ -64,7 +64,6 @@
 import org.jboss.remoting.InvokerLocator;
 import org.jboss.remoting.ServerInvocationHandler;
 import org.jboss.remoting.transport.PortUtil;
-import org.jboss.remoting.serialization.SerializationStreamFactory;
 import org.jboss.resource.adapter.jdbc.local.LocalManagedConnectionFactory;
 import org.jboss.resource.adapter.jdbc.remote.WrapperDataSourceService;
 import org.jboss.resource.adapter.jms.JmsManagedConnectionFactory;

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-17 04:41:26 UTC (rev 1808)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-18 03:53:08 UTC (rev 1809)
@@ -37,7 +37,6 @@
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
-import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.remoting.ServerInvocationHandler;
 
 /**

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java	2006-12-17 04:41:26 UTC (rev 1808)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RemoteTestServer.java	2006-12-18 03:53:08 UTC (rev 1809)
@@ -24,7 +24,6 @@
 import org.jboss.jms.server.DestinationManager;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
-import org.jboss.messaging.core.plugin.contract.PostOffice;
 
 /**
  *



From forge-admin at jboss.com  Mon Dec 18 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Mon, 18 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GwBY3-00015j-GE@committer01.frg.pub.inap.atl.jboss.com>

Commit from nrichards (2006-12-17 02:20 EST)
---------------------

use bigdecimal for dollar amounts, also clear up some messed up line endings

  jboss-seam  examples/dvdstore/build.xml                                          1.40
  jboss-seam  examples/dvdstore/resources/ordermanagement2.jpdl.xml                1.3
  jboss-seam  examples/dvdstore/resources/ordermanagement3.jpdl.xml                1.3
  jboss-seam  examples/dvdstore/resources/META-INF/application.xml                 1.7
  jboss-seam  examples/dvdstore/resources/META-INF/ejb-jar.xml                     1.4
  jboss-seam  examples/dvdstore/resources/META-INF/jboss-app.xml                   1.3
  jboss-seam  examples/dvdstore/resources/META-INF/persistence.xml                 1.10
  jboss-seam  examples/dvdstore/resources/WEB-INF/faces-config.xml                 1.13
  jboss-seam  examples/dvdstore/resources/WEB-INF/navigation.xml                   1.2
  jboss-seam  examples/dvdstore/resources/WEB-INF/web.xml                          1.18
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/AfterShippingAction.java    1.2
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/CheckoutAction.java         1.7
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/Order.java                  1.16
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/OrderApprovalDecision.java  1.3
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/Product.java                1.11
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/ShoppingCart.java           1.6
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/ShoppingCartBean.java       1.26
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/StoreManager.java           1.3
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/StoreManagerBean.java       1.10


Commit from gavin (2006-12-17 07:54 EST)
-----------------

renamed elements

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd    1.9
  jboss-seam  src/main/org/jboss/seam/core/Pages.java  1.63


Commit from gavin (2006-12-17 08:12 EST)
-----------------

improves the loggedininterceptor
updated to new element names

  jboss-seam  examples/booking/resources/WEB-INF/pages.xml                                  1.8
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java  1.14
  jboss-seam  examples/booking/view/register.xhtml                                          1.20


Commit from gavin (2006-12-17 09:07 EST)
-----------------

better impl of login/out

  jboss-seam  examples/booking/resources/WEB-INF/pages.xml                                  1.9
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java  1.15
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Login.java                1.3
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LoginAction.java          1.18
- jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Logout.java               1.3
- jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LogoutAction.java         1.9
  jboss-seam  examples/booking/view/template.xhtml                                          1.11


Commit from gavin (2006-12-17 09:09 EST)
-----------------

navigation from page actions

  jboss-seam  src/main/org/jboss/seam/core/Pages.java  1.64


Commit from gavin (2006-12-17 10:03 EST)
-----------------

fix a bug in <begin-conversation/>

  jboss-seam  src/main/org/jboss/seam/core/Conversation.java  1.32
  jboss-seam  src/main/org/jboss/seam/core/Page.java          1.10
  jboss-seam  src/main/org/jboss/seam/pageflow/Page.java      1.8


Commit from gavin (2006-12-17 10:05 EST)
-----------------

giveup

  jboss-seam  examples/numberguess/resources/.gpd.pageflow.jpdl.xml  1.10
  jboss-seam  examples/numberguess/resources/pageflow.jpdl.xml       1.8
+ jboss-seam  examples/numberguess/view/giveup.jspx                  1.1
  jboss-seam  examples/numberguess/view/numberGuess.jspx             1.4


Commit from vralev (2006-12-17 10:12 EST)
------------------

http://jira.jboss.com/jira/browse/JBINSTALL-153
http://jira.jboss.com/jira/browse/JBINSTALL-157

    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/installer.jar            1.2
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar  1.2
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller.jar          1.2
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller-ext.jar      1.2


Commit from gavin (2006-12-17 10:31 EST)
-----------------

cancel button

  jboss-seam  examples/dvdstore/resources/.gpd.checkout.jpdl.xml  1.5
  jboss-seam  examples/dvdstore/resources/checkout.jpdl.xml       1.6
  jboss-seam  examples/dvdstore/web/confirm.xhtml                 1.11


Commit from gavin (2006-12-17 10:32 EST)
-----------------

error

  jboss-seam  src/main/org/jboss/seam/pageflow/Page.java  1.9


Commit from gavin (2006-12-17 10:32 EST)
-----------------

fix

  jboss-seam  src/test/misc/org/jboss/seam/test/PageflowTest.java  1.4


Commit from gavin (2006-12-17 10:59 EST)
-----------------

update tests

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/BookingTest.java         1.43
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/ChangePasswordTest.java  1.15
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/test/LoginTest.java           1.24


Commit from gavin (2006-12-17 11:04 EST)
-----------------

any-outcome

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd    1.10
  jboss-seam  src/main/org/jboss/seam/core/Page.java   1.11
  jboss-seam  src/main/org/jboss/seam/core/Pages.java  1.65


Commit from gavin (2006-12-17 12:45 EST)
-----------------

JBSEAM-607, begin-conversation/end-conversation on an outcome

  jboss-seam  src/main/org/jboss/seam/core/Events.java                    1.17
  jboss-seam  src/main/org/jboss/seam/core/Exceptions.java                1.20
  jboss-seam  src/main/org/jboss/seam/core/Page.java                      1.12
  jboss-seam  src/main/org/jboss/seam/core/Pages.java                     1.66
  jboss-seam  src/main/org/jboss/seam/init/Initialization.java            1.134
  jboss-seam  src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java  1.31
+ jboss-seam  src/main/org/jboss/seam/util/XML.java                       1.1


Commit from gavin (2006-12-17 14:46 EST)
-----------------

refactor all the inner classes

  jboss-seam  src/main/org/jboss/seam/core/Exceptions.java                       1.21
  jboss-seam  src/main/org/jboss/seam/core/Manager.java                          1.127
  jboss-seam  src/main/org/jboss/seam/core/Navigator.java                        1.3
  jboss-seam  src/main/org/jboss/seam/core/Pages.java                            1.67
+ jboss-seam  src/main/org/jboss/seam/exceptions/AnnotationErrorHandler.java     1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/AnnotationRedirectHandler.java  1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/AnnotationRenderHandler.java    1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/ConfigErrorHandler.java         1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/ConfigRedirectHandler.java      1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/ConfigRenderHandler.java        1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/DebugPageHandler.java           1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/ErrorHandler.java               1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/ExceptionHandler.java           1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/RedirectHandler.java            1.1
+ jboss-seam  src/main/org/jboss/seam/exceptions/RenderHandler.java              1.1
+ jboss-seam  src/main/org/jboss/seam/pages/ActionNavigation.java                1.1
+ jboss-seam  src/main/org/jboss/seam/pages/ConversationControl.java             1.1
+ jboss-seam  src/main/org/jboss/seam/pages/NavigationHandler.java               1.1
+ jboss-seam  src/main/org/jboss/seam/pages/Outcome.java                         1.1
+ jboss-seam  src/main/org/jboss/seam/pages/Page.java                            1.1
+ jboss-seam  src/main/org/jboss/seam/pages/Param.java                           1.1
+ jboss-seam  src/main/org/jboss/seam/pages/RedirectNavigationHandler.java       1.1
+ jboss-seam  src/main/org/jboss/seam/pages/RenderNavigationHandler.java         1.1


Commit from gavin (2006-12-17 14:56 EST)
-----------------

remove obsolete

- jboss-seam  src/main/org/jboss/seam/core/Page.java  1.13


Commit from gavin (2006-12-17 15:33 EST)
-----------------

convenience methods

  jboss-seam  src/main/org/jboss/seam/core/FacesMessages.java  1.25


Commit from gavin (2006-12-17 19:29 EST)
-----------------

added s:validationFailure

  jboss-seam  src/ui/META-INF/faces-config.xml                    1.25
  jboss-seam  src/ui/META-INF/seam.taglib.xml                     1.21
+ jboss-seam  src/ui/org/jboss/seam/ui/AfterValidationEvent.java  1.1
+ jboss-seam  src/ui/org/jboss/seam/ui/UIValidationFailed.java    1.1


Commit from gavin (2006-12-17 20:46 EST)
-----------------

add s:forceModelUpdate

  jboss-seam  src/main/org/jboss/seam/core/Manager.java                   1.128
  jboss-seam  src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java  1.32
  jboss-seam  src/main/org/jboss/seam/jsf/SeamPhaseListener.java          1.95
  jboss-seam  src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java   1.18
  jboss-seam  src/ui/META-INF/faces-config.xml                            1.26
  jboss-seam  src/ui/META-INF/seam.taglib.xml                             1.22
- jboss-seam  src/ui/org/jboss/seam/ui/AfterValidationEvent.java          1.2
+ jboss-seam  src/ui/org/jboss/seam/ui/UIForceModelUpdate.java            1.1
  jboss-seam  src/ui/org/jboss/seam/ui/UIValidationFailed.java            1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061218/fd22837f/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 03:07:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 03:07:00 -0500
Subject: [jboss-cvs] JBossAS SVN: r59069 - in trunk/system/src:
	main/org/jboss/deployers/spi/management
	main/org/jboss/profileservice/spi
	main/org/jboss/system/server/profile
	main/org/jboss/system/server/profile/repository
	main/org/jboss/system/server/profileservice
	main/org/jboss/system/server/profileservice/basic
	main/org/jboss/system/server/profileservice/repository
	tests/org/jboss/test/profileservice/simple1
	tests/org/jboss/test/profileservice/support
	tests/org/jboss/test/server/profileservice
Message-ID: <E1GwDWW-0003II-C4@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 03:06:42 -0500 (Mon, 18 Dec 2006)
New Revision: 59069

Added:
   trunk/system/src/main/org/jboss/profileservice/spi/DeploymentRepository.java
   trunk/system/src/main/org/jboss/profileservice/spi/ProfileRepository.java
   trunk/system/src/main/org/jboss/system/server/profile/repository/
   trunk/system/src/main/org/jboss/system/server/profile/repository/ProfileImpl.java
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/DeploymentRecord.java
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/FileProfleRepository.java
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/ProfileServiceImpl.java
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java
Modified:
   trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java
   trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java
   trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java
   trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java
   trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java
   trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java
   trunk/system/src/tests/org/jboss/test/profileservice/simple1/ManagementViewImpl.java
   trunk/system/src/tests/org/jboss/test/profileservice/simple1/ProfileServiceImpl.java
   trunk/system/src/tests/org/jboss/test/profileservice/support/Simple1PSBootstrap.java
   trunk/system/src/tests/org/jboss/test/server/profileservice/MainTestCase.java
Log:
Checkpoint of the profile repository

Modified: trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java
===================================================================
--- trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/deployers/spi/management/ManagementView.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -46,7 +46,7 @@
     * @throws NoSuchProfileException
     * @throws NoSuchDeploymentException 
     */
-   public ManagedObject getView(ProfileKey key, String deploymentName)
+   public ManagedObject getView(ProfileKey key, String deploymentName, String version)
       throws NoSuchProfileException, NoSuchDeploymentException;
 
 }

Added: trunk/system/src/main/org/jboss/profileservice/spi/DeploymentRepository.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/DeploymentRepository.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/profileservice/spi/DeploymentRepository.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,82 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.profileservice.spi;
+
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URI;
+import java.util.Collection;
+import java.util.zip.ZipInputStream;
+
+import org.jboss.deployers.spi.attachments.Attachments;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * An interface for managing the contents of a Profile.
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public interface DeploymentRepository
+{
+   public URI getBootstrapURI();
+   public void setBootstrapURI(URI uri);
+   public URI getDeployersURI();
+   public void setDeployersURI(URI uri);
+   public URI getDeploymentURI();
+   public void setDeploymentURI(URI rootURI);
+
+   // Upload a raw deployment
+   public VirtualFile addDeploymentFile(String name, ZipInputStream contentIS)
+      throws IOException;
+   // Get the raw deployment
+   public VirtualFile getDeploymentFile(String name);
+
+   // Bootstrap
+   public void addBootstrap(String vfsPath, DeploymentContext ctx)
+      throws IOException;
+   public DeploymentContext getBootstrap(String vfsPath);
+   public Collection<DeploymentContext> getBootstraps();
+   public void removeBootstrap(String vfsPath)
+      throws IOException;
+
+   // Deployers
+   public void addDeployer(String vfsPath, DeploymentContext ctx)
+      throws IOException;
+   public DeploymentContext getDeployer(String vfsPath);
+   public Collection<DeploymentContext> getDeployers();
+   public void removeDeployer(String vfsPath)
+      throws IOException;
+
+   // Deployments
+   public void addDeployment(String vfsPath, DeploymentContext ctx)
+      throws IOException;
+   public DeploymentContext getDeployment(String vfsPath);
+   public void removeDeployment(String vfsPath)
+      throws IOException;
+   public Collection<DeploymentContext> getDeployments();
+
+   // Managed object attachments for a deployment
+   public void addManagedObject(String vfsPath, Attachments edits)
+      throws IOException;
+}

Added: trunk/system/src/main/org/jboss/profileservice/spi/ProfileRepository.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ProfileRepository.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ProfileRepository.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,63 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.profileservice.spi;
+
+import java.io.IOException;
+
+/**
+ * An interface for obtaining DeploymentRepository for a Profile.
+ *  
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public interface ProfileRepository
+{
+   /**
+    * Create a new DeploymentRepository for a profile.
+    * 
+    * @param key - the key for the Profile to create the DeploymentRepository for.
+    * @return the profile DeploymentRepository
+    * @throws IOException thrown if the repository cannot be created or
+    *    already exists
+    */
+   public DeploymentRepository createProfileDeploymentRepository(ProfileKey key)
+      throws IOException;
+
+   /**
+    * Get the DeploymentRepository for the given profile key.
+    * 
+    * @param key - the key for the Profile to obtain the DeploymentRepository for.
+    * @return the profile DeploymentRepository
+    * @throws NoSuchProfileException thrown if there is no such profile.
+    */
+   public DeploymentRepository getProfileDeploymentRepository(ProfileKey key)
+      throws IOException, NoSuchProfileException;
+
+   /**
+    * Remove the DeploymentRepository for the given profile key.
+    * @param key - the key for the Profile to obtain the DeploymentRepository for.
+    * @throws IOException thrown on error removing the repository
+    * @throws NoSuchProfileException thrown if there is no such profile.
+    */
+   public void removeProfileDeploymentRepository(ProfileKey key)
+      throws IOException, NoSuchProfileException;
+}

Modified: trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java
===================================================================
--- trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/profileservice/spi/ProfileService.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -55,7 +55,7 @@
     * @return the matching profile.
     * @throws NoSuchProfileException
     */
-   public Profile getProfile(ProfileKey key)
+   public Profile getProfile(ProfileKey key, String version)
       throws NoSuchProfileException;
 
    /**
@@ -74,8 +74,9 @@
    public ManagementView getViewManager();
 
    // Admin of profiles @todo could be an option plugin
-   public Profile newProfile(ProfileKey key);
-   public void removeProfile(ProfileKey key)
-      throws NoSuchProfileException;
+   public Profile newProfile(ProfileKey key, String version)
+      throws Exception;
+   public void removeProfile(ProfileKey key, String version)
+      throws Exception;
 
 }

Added: trunk/system/src/main/org/jboss/system/server/profile/repository/ProfileImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profile/repository/ProfileImpl.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profile/repository/ProfileImpl.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,152 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.system.server.profile.repository;
+
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Map;
+
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.profileservice.spi.DeploymentRepository;
+import org.jboss.profileservice.spi.DeploymentTemplate;
+import org.jboss.profileservice.spi.NoSuchDeploymentException;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.util.JBossObject;
+
+/**
+ * A basic profile implementation that uses the DeploymentRepository to store
+ * deployments and admin metadata.
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class ProfileImpl extends JBossObject
+   implements Profile
+{
+   private String name;
+   private String version;
+   /** The repository containing the deployment contents */
+   private DeploymentRepository repository;
+
+   /**
+    * 
+    * @param repository
+    * @param name
+    */
+   public ProfileImpl(DeploymentRepository repository, String name)
+   {
+      this(repository, name, null);
+   }
+   public ProfileImpl(DeploymentRepository repository, String name, String version)
+   {
+      this.name = name;
+      this.version = version;
+      this.repository = repository;
+      log.info("Using repository:"+repository);
+   }
+
+   public String getName()
+   {
+      return name;
+   }
+   
+   public String getVersion()
+   {
+      return version;
+   }
+   
+   public void addBootstrap(DeploymentContext d) throws Exception
+   {
+      repository.addBootstrap(d.getRelativePath(), d);
+   }
+   
+   public void removeBootstrap(String name) throws Exception
+   {
+      repository.removeBootstrap(name);
+   }
+   
+   public DeploymentContext getBootstrap(String name) throws NoSuchDeploymentException
+   {
+      DeploymentContext deployment = repository.getBootstrap(name);
+      return deployment;
+   }
+   
+   public Collection<DeploymentContext> getBootstraps()
+   {
+      return Collections.unmodifiableCollection(repository.getBootstraps());
+   }
+
+   public void addDeployer(DeploymentContext d) throws Exception
+   {
+      repository.addDeployer(d.getRelativePath(), d);
+   }
+   
+   public void removeDeployer(String name) throws Exception
+   {
+      repository.removeDeployer(name);
+   }
+   
+   public DeploymentContext getDeployer(String name) throws NoSuchDeploymentException
+   {
+      DeploymentContext deployment = repository.getDeployer(name);
+      return deployment;
+   }
+   
+   public Collection<DeploymentContext> getDeployers()
+   {
+      return Collections.unmodifiableCollection(repository.getDeployers());
+   }
+   
+   public DeploymentTemplate getTemplate(String name)
+         throws NoSuchDeploymentException
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+   
+   public void addDeployment(DeploymentContext d) throws Exception
+   {
+      repository.addDeployment(d.getRelativePath(), d);
+   }
+   
+   public void removeDeployment(String name) throws Exception
+   {
+      repository.removeDeployment(name);
+   }
+   
+   public DeploymentContext getDeployment(String name)
+         throws NoSuchDeploymentException
+   {
+      DeploymentContext deployment = repository.getDeployment(name);
+      return deployment;
+   }
+
+   public Collection<DeploymentContext> getDeployments()
+   {
+      return Collections.unmodifiableCollection(repository.getDeployments());
+   }
+   
+   public Map<String, Object> getConfig()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+}

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ManagementViewImpl.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -49,10 +49,10 @@
       this.ps = ps;
    }
 
-   public ManagedObject getView(ProfileKey key, String deploymentName)
+   public ManagedObject getView(ProfileKey key, String deploymentName, String version)
       throws NoSuchProfileException, NoSuchDeploymentException
    {
-      Profile profile = ps.getProfile(key);
+      Profile profile = ps.getProfile(key, version);
       DeploymentContext d = profile.getDeployment(deploymentName);
       // TODO ManagedObject mo = d.getManagedObject();
       // return mo;

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/ProfileServiceBootstrap.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -328,7 +328,7 @@
 
       // Load the named profile
       ProfileKey key = new ProfileKey(name);
-      Profile profile = ps.getProfile(key);
+      Profile profile = ps.getProfile(key, null);
 
       // HACK
       DeploymentContext first = null;

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/VFSScanner.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -567,7 +567,7 @@
       DeploymentContext deployment = null;
       try
       {
-         Profile profile = profileService.getProfile(profileKey);
+         Profile profile = profileService.getProfile(profileKey, null);
          deployment = add(profile, component);
       }
       catch (Exception e)
@@ -618,7 +618,7 @@
             log.trace("Undeploying: " + component);
          }
          String name = deployedSet.remove(component);         
-         Profile profile = profileService.getProfile(profileKey);
+         Profile profile = profileService.getProfile(profileKey, null);
          remove(profile, name);
       }
       catch (Exception e)

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/basic/ProfileServiceImpl.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -90,7 +90,7 @@
    /**
     * Always returns the default profile.
     */
-   public Profile getProfile(ProfileKey key)
+   public Profile getProfile(ProfileKey key, String version)
       throws NoSuchProfileException
    {
       return defaultImpl;
@@ -113,12 +113,12 @@
    }
 
    // Admin of profiles @todo could be an option plugin
-   public Profile newProfile(ProfileKey key)
+   public Profile newProfile(ProfileKey key, String version)
    {
       return new ProfileImpl(profileRoot, name);
    }
 
-   public void removeProfile(ProfileKey key)
+   public void removeProfile(ProfileKey key, String version)
       throws NoSuchProfileException
    {
    }

Added: trunk/system/src/main/org/jboss/system/server/profileservice/repository/DeploymentRecord.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/repository/DeploymentRecord.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/repository/DeploymentRecord.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,34 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.system.server.profileservice.repository;
+
+import java.io.Serializable;
+
+/**
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class DeploymentRecord implements Serializable
+{
+   private static final long serialVersionUID = 1;
+   
+}

Added: trunk/system/src/main/org/jboss/system/server/profileservice/repository/FileProfleRepository.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/repository/FileProfleRepository.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/repository/FileProfleRepository.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,82 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.system.server.profileservice.repository;
+
+import java.io.File;
+import java.io.IOException;
+
+import org.jboss.profileservice.spi.DeploymentRepository;
+import org.jboss.profileservice.spi.NoSuchProfileException;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.ProfileRepository;
+
+/**
+ * An implementation of ProfileRepository that uses the following
+ * file system structure for storing deployments and admin
+ * edits.
+ * 
+ * root-file
+ * + server/{name}/conf/bootstrap.xml - the bootstrap beans
+ * + server/{name}/deployers - profile deployers
+ * + server/{name}/deploy - installed deployments
+ * + server/{name}/apps - post install deployments
+ * + server/{name}/admin - admin edits to deployments
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class FileProfleRepository implements ProfileRepository
+{
+   private File root;
+
+   public FileProfleRepository(File root)
+   {
+      this.root = root;
+   }
+
+   public File getRoot()
+   {
+      return root;
+   }
+
+   public DeploymentRepository createProfileDeploymentRepository(ProfileKey key) throws IOException
+   {
+      SerializableDeploymentRepository repository = new SerializableDeploymentRepository(root, key);
+      repository.create();
+      return repository;
+   }
+
+   public DeploymentRepository getProfileDeploymentRepository(ProfileKey key)
+      throws IOException, NoSuchProfileException
+   {
+      SerializableDeploymentRepository repository = new SerializableDeploymentRepository(root, key);
+      repository.load();
+      return repository;
+   }
+
+   public void removeProfileDeploymentRepository(ProfileKey key) throws IOException, NoSuchProfileException
+   {      
+      SerializableDeploymentRepository repository = new SerializableDeploymentRepository(root, key);
+      repository.remove();  
+   }
+
+}

Added: trunk/system/src/main/org/jboss/system/server/profileservice/repository/ProfileServiceImpl.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/repository/ProfileServiceImpl.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/repository/ProfileServiceImpl.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,165 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.system.server.profileservice.repository;
+
+import java.io.IOException;
+
+import org.jboss.deployers.spi.management.ManagementView;
+import org.jboss.profileservice.spi.DeploymentRepository;
+import org.jboss.profileservice.spi.NoSuchProfileException;
+import org.jboss.profileservice.spi.Profile;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.profileservice.spi.ProfileRepository;
+import org.jboss.profileservice.spi.ProfileService;
+import org.jboss.system.server.profile.repository.ProfileImpl;
+
+
+/**
+ * A ProfileService impl that uses a ProfileRepository/DeploymentRepository
+ * based Profile implementation.
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
+ */
+public class ProfileServiceImpl
+   implements ProfileService
+{
+   /** The name of the profile to use */
+   private String name;
+   /** The version of the profile to use */
+   private String version;
+   private ProfileRepository profileRepository;
+   private DeploymentRepository deploymentRepository;
+   private Profile profile;
+   private ManagementView mgtView;
+
+   public ProfileServiceImpl(String name) throws IOException
+   {
+      this.name = name;
+   }
+   // Properties ------------------------
+
+   public String getName()
+   {
+      return this.name;
+   }
+   public void setName(String name)
+   {
+      this.name = name;
+   }
+
+   public String getVersion()
+   {
+      return version;
+   }
+
+   public void setVersion(String version)
+   {
+      this.version = version;
+   }
+
+   public ProfileRepository getProfileRepository()
+   {
+      return profileRepository;
+   }
+
+   public void setProfileRepository(ProfileRepository profileRepository)
+   {
+      this.profileRepository = profileRepository;
+   }
+
+   public DeploymentRepository getDeploymentRepository()
+   {
+      return deploymentRepository;
+   }
+
+   public void setDeploymentRepository(DeploymentRepository repository)
+   {
+      this.deploymentRepository = repository;
+   }
+
+   public void start()
+      throws Exception
+   {
+      if( profileRepository == null )
+         throw new IllegalStateException("No profileRepository specified");
+      // Obtain the deployment repository for the profile
+      if( deploymentRepository == null )
+      {
+         ProfileKey key = new ProfileKey(name);
+         deploymentRepository = profileRepository.getProfileDeploymentRepository(key);
+      }
+      profile = new ProfileImpl(deploymentRepository, name, version);
+   }
+
+   // ProfileService implementation --------------------
+   public String[] getDomains()
+   {
+      String[] domains = {ProfileKey.DEFAULT};
+      return domains;
+   }
+
+   public ProfileKey[] getProfileKeys()
+   {
+      ProfileKey[] keys = {new ProfileKey(name)};
+      return keys;
+   }
+
+   /**
+    * Always returns the default profile.
+    */
+   public Profile getProfile(ProfileKey key, String version)
+      throws NoSuchProfileException
+   {
+      return profile;
+   }
+
+   public String[] getProfileDeploymentNames(ProfileKey key)
+      throws NoSuchProfileException
+   {
+      String[] names = {"default"};
+      return names;
+   }
+
+   public ManagementView getViewManager()
+   {
+      return mgtView;
+   }
+   public void setViewManager(ManagementView mgtView)
+   {
+      this.mgtView = mgtView;
+   }
+
+   public Profile newProfile(ProfileKey key, String version)
+      throws Exception
+   {
+      DeploymentRepository repo = profileRepository.createProfileDeploymentRepository(key);
+      return new ProfileImpl(repo, key.getName(), version);
+   }
+
+   public void removeProfile(ProfileKey key, String version)
+      throws IOException, NoSuchProfileException
+   {
+      profileRepository.removeProfileDeploymentRepository(key);
+   }
+}
+

Added: trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -0,0 +1,294 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.system.server.profileservice.repository;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.io.ObjectOutputStream;
+import java.net.URI;
+import java.util.Collection;
+import java.util.Map;
+import java.util.zip.ZipInputStream;
+
+import org.jboss.deployers.spi.attachments.Attachments;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.profileservice.spi.DeploymentRepository;
+import org.jboss.profileservice.spi.NoSuchProfileException;
+import org.jboss.profileservice.spi.ProfileKey;
+import org.jboss.util.file.Files;
+import org.jboss.virtual.VirtualFile;
+
+/**
+ * An implementation of DeploymentRepository that relies on java
+ * serialization to store contents on the file system.
+ * 
+ * root-file
+ * + server/{name}/conf/bootstrap.xml - the bootstrap beans
+ * + server/{name}/deployers - profile deployers
+ * + server/{name}/deploy - installed deployments
+ * + server/{name}/apps - post install deployments
+ * + server/{name}/admin - admin edits to deployments
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
+public class SerializableDeploymentRepository implements DeploymentRepository
+{
+   private File root;
+   private File confDir;
+   private File libDir;
+   private File deployersDir;
+   private File deployDir;
+   private File metaDataRoot;
+   private File adminEditsRoot;
+   private ProfileKey key;
+
+   public SerializableDeploymentRepository(File root, ProfileKey key)
+   {
+      this.root = root;
+      this.key = key;
+   }
+
+   void create() throws IOException
+   {
+      File profileRoot = new File(root, "server/"+key.getName());
+      if( profileRoot.exists() == true )
+         throw new IOException("Profile root alread exists: "+profileRoot);
+      if( profileRoot.mkdirs() == false )
+         throw new IOException("Failed to create profile root: "+profileRoot);
+      // server/{name}/conf
+      confDir = new File(profileRoot, "conf");
+      if( confDir.mkdirs() == false )
+         throw new IOException("Failed to create profile conf dir: "+confDir);
+      // server/{name}/deployers
+      deployersDir = new File(profileRoot, "deployers");
+      if( deployersDir.mkdirs() == false )
+         throw new IOException("Failed to create profile deployers dir: "+deployersDir);
+      // server/{name}/deploy
+      deployDir = new File(profileRoot, "deploy");
+      if( deployDir.mkdirs() == false )
+         throw new IOException("Failed to create profile deploy dir: "+deployDir);
+      // server/{name}/lib
+      libDir = new File(profileRoot, "lib");
+      if( libDir.mkdirs() == false )
+         throw new IOException("Failed to create profile lib dir: "+libDir);
+      metaDataRoot = new File(profileRoot, "metaData");
+      if( metaDataRoot.mkdirs() == false )
+         throw new IOException("Failed to create profile metaData dir: "+metaDataRoot);
+      
+      adminEditsRoot = new File(profileRoot, "adminEdits");
+      if( adminEditsRoot.mkdirs() == false )
+         throw new IOException("Failed to create profile adminEdits dir: "+adminEditsRoot);
+   }
+
+   void load() throws IOException, NoSuchProfileException
+   {
+      File profileRoot = new File(root, "server/"+key.getName());
+      if( profileRoot.exists() == true )
+         throw new NoSuchProfileException("Profile root alread exists: "+profileRoot);
+      //
+      
+   }
+
+   void remove() throws IOException, NoSuchProfileException
+   {
+      File profileRoot = new File(root, "server/"+key.getName());
+      if( profileRoot.exists() == true )
+         throw new NoSuchProfileException("Profile root alread exists: "+profileRoot);
+      //
+      Files.delete(profileRoot);
+   }
+
+   public boolean exists()
+   {
+      File profileRoot = new File(root, "server/"+key.getName());
+      return profileRoot.exists();
+   }
+
+   public VirtualFile addDeploymentFile(String name, ZipInputStream contentIS)
+      throws IOException
+   {
+      return null;
+   }
+
+   public void addBootstrap(String vfsPath, DeploymentContext ctx)
+      throws IOException
+   {
+      // Write out the base transient metadata
+      saveAttachments(vfsPath, ctx);
+   }
+
+   // Managed object attachments for a deployment
+   public void addManagedObject(String vfsPath, Attachments edits)
+      throws IOException
+   {
+      Map<String, Object> map = edits.getAttachments();
+      File attachments = new File(adminEditsRoot, vfsPath+".edits");
+      FileOutputStream fos = new FileOutputStream(attachments);
+      ObjectOutputStream oos = new ObjectOutputStream(fos);
+      oos.writeObject(map);
+      oos.close();
+      fos.close();
+
+   }
+
+   public void addDeployer(String vfsPath, DeploymentContext ctx) throws IOException
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public void addDeployment(String vfsPath, DeploymentContext ctx) throws IOException
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public DeploymentContext getBootstrap(String vfsPath)
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public Collection<DeploymentContext> getBootstraps()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public URI getBootstrapURI()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public DeploymentContext getDeployer(String vfsPath)
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public Collection<DeploymentContext> getDeployers()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public URI getDeployersURI()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public DeploymentContext getDeployment(String vfsPath)
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public VirtualFile getDeploymentFile(String name)
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public Collection<DeploymentContext> getDeployments()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public URI getDeploymentURI()
+   {
+      // TODO Auto-generated method stub
+      return null;
+   }
+
+   public void removeBootstrap(String vfsPath) throws IOException
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public void removeDeployer(String vfsPath) throws IOException
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public void removeDeployment(String vfsPath) throws IOException
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public void setBootstrapURI(URI uri)
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public void setDeployersURI(URI uri)
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   public void setDeploymentURI(URI rootURI)
+   {
+      // TODO Auto-generated method stub
+      
+   }
+
+   private void saveAttachments(String vfsPath, DeploymentContext ctx)
+      throws IOException
+   {
+      // Write out the base transient metadata
+      Attachments transientAttachments = ctx.getTransientAttachments();
+      if( transientAttachments.getAttachments().size() > 0 )
+      {
+         Map<String, Object> map = transientAttachments.getAttachments();
+         File attachments = new File(metaDataRoot, vfsPath+".transientAttachments");
+         FileOutputStream fos = new FileOutputStream(attachments);
+         ObjectOutputStream oos = new ObjectOutputStream(fos);
+         oos.writeObject(map);
+         oos.close();
+         fos.close();
+      }
+   
+      // Write out the base transient managed objects
+      Attachments transientManagedObjects = ctx.getTransientManagedObjects();
+      if( transientManagedObjects.getAttachments().size() > 0 )
+      {
+         Map<String, Object> map = transientManagedObjects.getAttachments();
+         File attachments = new File(metaDataRoot, vfsPath+".transientManagedObjects");
+         FileOutputStream fos = new FileOutputStream(attachments);
+         ObjectOutputStream oos = new ObjectOutputStream(fos);
+         oos.writeObject(map);
+         oos.close();
+         fos.close();
+      }
+   }
+
+}

Modified: trunk/system/src/tests/org/jboss/test/profileservice/simple1/ManagementViewImpl.java
===================================================================
--- trunk/system/src/tests/org/jboss/test/profileservice/simple1/ManagementViewImpl.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/tests/org/jboss/test/profileservice/simple1/ManagementViewImpl.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -49,10 +49,10 @@
       this.ps = ps;
    }
 
-   public ManagedObject getView(ProfileKey key, String deploymentName)
+   public ManagedObject getView(ProfileKey key, String deploymentName, String version)
       throws NoSuchProfileException, NoSuchDeploymentException
    {
-      Profile profile = ps.getProfile(key);
+      Profile profile = ps.getProfile(key, version);
       DeploymentContext d = profile.getDeployment(deploymentName);
       /** TODO ManagedObject mo = d.getManagedObject();
       return mo; */

Modified: trunk/system/src/tests/org/jboss/test/profileservice/simple1/ProfileServiceImpl.java
===================================================================
--- trunk/system/src/tests/org/jboss/test/profileservice/simple1/ProfileServiceImpl.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/tests/org/jboss/test/profileservice/simple1/ProfileServiceImpl.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -62,7 +62,7 @@
    /**
     * Always returns the default profile.
     */
-   public Profile getProfile(ProfileKey key)
+   public Profile getProfile(ProfileKey key, String version)
       throws NoSuchProfileException
    {
       return defatulImpl;
@@ -81,12 +81,12 @@
    }
 
    // Admin of profiles @todo could be an option plugin
-   public Profile newProfile(ProfileKey key)
+   public Profile newProfile(ProfileKey key, String version)
    {
       return null;
    }
 
-   public void removeProfile(ProfileKey key)
+   public void removeProfile(ProfileKey key, String version)
       throws NoSuchProfileException
    {
    }

Modified: trunk/system/src/tests/org/jboss/test/profileservice/support/Simple1PSBootstrap.java
===================================================================
--- trunk/system/src/tests/org/jboss/test/profileservice/support/Simple1PSBootstrap.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/tests/org/jboss/test/profileservice/support/Simple1PSBootstrap.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -61,7 +61,7 @@
 
       // Load the named profile
       ProfileKey key = new ProfileKey(name);
-      Profile profile = profileService.getProfile(key);
+      Profile profile = profileService.getProfile(key, null);
       /* TODO 
       Deployment[] profileDeployments = profile.getDeployments();
       for(Deployment d : profileDeployments)

Modified: trunk/system/src/tests/org/jboss/test/server/profileservice/MainTestCase.java
===================================================================
--- trunk/system/src/tests/org/jboss/test/server/profileservice/MainTestCase.java	2006-12-17 11:39:17 UTC (rev 59068)
+++ trunk/system/src/tests/org/jboss/test/server/profileservice/MainTestCase.java	2006-12-18 08:06:42 UTC (rev 59069)
@@ -71,12 +71,12 @@
       psb.bootstrap();
       ProfileService ps = psb.getProfileService();
       ProfileKey defaultKey = new ProfileKey("default");
-      Profile profile = ps.getProfile(defaultKey);
+      Profile profile = ps.getProfile(defaultKey, null);
       DeploymentContext testBeans = profile.getDeployment("test-beans.xml");
       if( testBeans == null )
       {
          if( profile == null )
-            profile = ps.newProfile(defaultKey);
+            profile = ps.newProfile(defaultKey, null);
          MainDeployer deployer = psb.getMainDeployer();
          VFS vfs = VFS.getVFS(resourcesDir);
          VirtualFile file = vfs.findChildFromRoot("deploy/beans/test-beans.xml");



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 05:54:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 05:54:27 -0500
Subject: [jboss-cvs] JBossAS SVN: r59070 - in projects/aop/trunk/aop/src:
	main/org/jboss/aop/instrument
	test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly
Message-ID: <E1GwG8Z-0006Eu-TQ@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 05:54:24 -0500 (Mon, 18 Dec 2006)
New Revision: 59070

Removed:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnly.java
Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java
Log:
[JBAOP-329] Parameter annotations should exist in wrapper method and not the internal method

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-18 08:06:42 UTC (rev 59069)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-18 10:54:24 UTC (rev 59070)
@@ -37,6 +37,8 @@
 import javassist.NotFoundException;
 import javassist.bytecode.AnnotationsAttribute;
 import javassist.bytecode.MethodInfo;
+import javassist.bytecode.ParameterAnnotationsAttribute;
+import javassist.bytecode.annotation.Annotation;
 
 /**
  * Comment
@@ -235,24 +237,44 @@
       }
    }
 
-   protected void moveAnnotations(CtMethod src, CtMethod dest)
+   protected void moveAnnotations(CtMethod src, CtMethod dest) throws NotFoundException
    {
       MethodInfo mi = src.getMethodInfo2();
       MethodInfo wmi = dest.getMethodInfo2();
-      AnnotationsAttribute invisible = (AnnotationsAttribute) mi.getAttribute(AnnotationsAttribute.invisibleTag);
-      if (invisible != null)
+
+      moveAnnotations(mi, wmi, AnnotationsAttribute.invisibleTag);
+      moveAnnotations(mi, wmi, AnnotationsAttribute.visibleTag);
+      int numParams = src.getParameterTypes().length;
+      moveParameterAnnotations(numParams, mi, wmi, ParameterAnnotationsAttribute.visibleTag);
+      moveParameterAnnotations(numParams, mi, wmi, ParameterAnnotationsAttribute.invisibleTag);
+   }
+
+   private void moveAnnotations(MethodInfo src, MethodInfo dest, String annotationTag)
+   {
+      AnnotationsAttribute attribute = (AnnotationsAttribute) src.getAttribute(annotationTag);
+      if (attribute != null)
       {
-         wmi.addAttribute(invisible.copy(wmi.getConstPool(), new HashMap()));
+         dest.addAttribute(attribute.copy(dest.getConstPool(), new HashMap()));
+         src.addAttribute(new AnnotationsAttribute(src.getConstPool(), annotationTag));
       }
-      AnnotationsAttribute visible = (AnnotationsAttribute) mi.getAttribute(AnnotationsAttribute.visibleTag);
-      if (visible != null)
+   }
+   
+   private void moveParameterAnnotations(int numParams, MethodInfo src, MethodInfo dest, String paramsTag)
+   {
+      ParameterAnnotationsAttribute params = (ParameterAnnotationsAttribute)src.getAttribute(paramsTag);
+      if (params != null)
       {
-         wmi.addAttribute(visible.copy(wmi.getConstPool(), new HashMap()));
+         dest.addAttribute(params.copy(dest.getConstPool(), new HashMap()));
+         ParameterAnnotationsAttribute srcParams = new ParameterAnnotationsAttribute(src.getConstPool(), paramsTag);
+         Annotation[][] emptyParamAnnotations = new Annotation[numParams][];
+         for (int i = 0 ; i < numParams ; i++)
+         {
+            emptyParamAnnotations[i] = new Annotation[0];
+         }
+         srcParams.setAnnotations(emptyParamAnnotations);
+         src.addAttribute(srcParams);
       }
-      mi.addAttribute(new AnnotationsAttribute(mi.getConstPool(), AnnotationsAttribute.invisibleTag));
-      mi.addAttribute(new AnnotationsAttribute(mi.getConstPool(), AnnotationsAttribute.visibleTag));
    }
-   
 
    protected static String getAopReturnStr(CtMethod method)throws NotFoundException
    {

Deleted: projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnly.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnly.java	2006-12-18 08:06:42 UTC (rev 59069)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnly.java	2006-12-18 10:54:24 UTC (rev 59070)
@@ -1,79 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.aop.regression.jbaop316annotationsinwrapperonly;
-
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-
-import org.jboss.aop.Advised;
-import org.jboss.test.aop.AOPTestWithSetup;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-
-/**
- * http://jira.jboss.com/jira/browse/JBAOP-316
- * 
- * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
- * @version $Revision: 45977 $
- */
-public class AnnotationsInWrapperMethodOnly extends AOPTestWithSetup
-{
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("AnnotationsInWrapperMethodOnly");
-      suite.addTestSuite(AnnotationsInWrapperMethodOnly.class);
-      return suite;
-   }
-
-   public AnnotationsInWrapperMethodOnly(String name)
-   {
-      super(name);
-   }
-
-   public void testAnnotationNotInInternalCopy()throws Exception
-   {
-      Method[] methods = POJO.class.getMethods();
-      
-      ArrayList hasAnnotation = new ArrayList();
-      for (int i = 0 ; i < methods.length ; i++)
-      {
-         if (methods[i].isAnnotationPresent(TestAnnotation.class))
-         {
-            hasAnnotation.add(methods[i].getName());
-         }
-      }
-      
-      assertFalse("Expected to find annotation for 'method'", hasAnnotation.size() == 0);
-      assertTrue("Expected to find annotation for 'method' only, it was found for " + hasAnnotation, hasAnnotation.size() == 1);
-      assertEquals("method", hasAnnotation.get(0));
-      assertTrue("Class was not woven", Advised.class.isAssignableFrom(POJO.class));
-   }
-
-}

Modified: projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java	2006-12-18 08:06:42 UTC (rev 59069)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java	2006-12-18 10:54:24 UTC (rev 59070)
@@ -29,7 +29,7 @@
 public class POJO
 {
    @TestAnnotation
-   public void method()
+   public void method(int i, @TestAnnotation String s)
    {
       
    }



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 05:55:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 05:55:18 -0500
Subject: [jboss-cvs] JBossAS SVN: r59071 -
	projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly
Message-ID: <E1GwG9O-0006Gj-0o@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 05:55:16 -0500 (Mon, 18 Dec 2006)
New Revision: 59071

Added:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java
Log:
[JBAOP-329] Parameter annotations should exist in wrapper method and not the internal method

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java	2006-12-18 10:54:24 UTC (rev 59070)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java	2006-12-18 10:55:16 UTC (rev 59071)
@@ -0,0 +1,93 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.regression.jbaop316annotationsinwrapperonly;
+
+import java.lang.annotation.Annotation;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+
+import org.jboss.aop.Advised;
+import org.jboss.test.aop.AOPTestWithSetup;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+
+/**
+ * http://jira.jboss.com/jira/browse/JBAOP-316
+ * 
+ * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @version $Revision: 45977 $
+ */
+public class AnnotationsInWrapperMethodOnlyTestCase extends AOPTestWithSetup
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("AnnotationsInWrapperMethodOnlyTestCase");
+      suite.addTestSuite(AnnotationsInWrapperMethodOnlyTestCase.class);
+      return suite;
+   }
+
+   public AnnotationsInWrapperMethodOnlyTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testAnnotationNotInInternalCopy()throws Exception
+   {
+      Method[] methods = POJO.class.getMethods();
+      
+      ArrayList hasAnnotation = new ArrayList();
+      ArrayList hasParameterAnnotation = new ArrayList();
+      for (int i = 0 ; i < methods.length ; i++)
+      {
+         if (methods[i].isAnnotationPresent(TestAnnotation.class))
+         {
+            hasAnnotation.add(methods[i].getName());
+         }
+         
+         Annotation[][] paramAnnotations = methods[i].getParameterAnnotations();
+         for (int p = 0 ; p < paramAnnotations.length ; p++)
+         {
+            if (paramAnnotations[p].length > 0)
+            {
+               hasParameterAnnotation.add(methods[i].getName() + "1");
+            }
+         }
+      }
+      
+      assertFalse("Expected to find annotation for 'method'", hasAnnotation.size() == 0);
+      assertFalse("Expected to find parameter annotation for 'method'", hasParameterAnnotation.size() == 0);
+      assertTrue("Expected to find annotation for 'method' only, it was found for " + hasAnnotation, hasAnnotation.size() == 1);
+      assertTrue("Expected to find parameter annotation for 'method' only, it was found for " + hasParameterAnnotation, hasAnnotation.size() == 1);
+      assertEquals("method", hasAnnotation.get(0));
+      assertEquals("method1", hasParameterAnnotation.get(0));
+      assertTrue("Class was not woven", Advised.class.isAssignableFrom(POJO.class));
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 06:10:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 06:10:37 -0500
Subject: [jboss-cvs] JBossAS SVN: r59072 - in
	branches/Branch_AOP_1_5/aop/src:
	main/org/jboss/aop/instrument main/org/jboss/aop/util
	test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly
Message-ID: <E1GwGOD-0006ig-KS@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 06:10:31 -0500 (Mon, 18 Dec 2006)
New Revision: 59072

Modified:
   branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
   branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/util/ReflectToJavassist.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java
Log:
[JBAOP-329] Parameter annotations should exist in wrapper method and not the internal method

Modified: branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-18 10:55:16 UTC (rev 59071)
+++ branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-18 11:10:31 UTC (rev 59072)
@@ -37,6 +37,8 @@
 import javassist.NotFoundException;
 import javassist.bytecode.AnnotationsAttribute;
 import javassist.bytecode.MethodInfo;
+import javassist.bytecode.ParameterAnnotationsAttribute;
+import javassist.bytecode.annotation.Annotation;
 
 /**
  * Comment
@@ -235,22 +237,43 @@
       }
    }
 
-   protected void moveAnnotations(CtMethod src, CtMethod dest)
+   protected void moveAnnotations(CtMethod src, CtMethod dest) throws NotFoundException
    {
       MethodInfo mi = src.getMethodInfo2();
       MethodInfo wmi = dest.getMethodInfo2();
-      AnnotationsAttribute invisible = (AnnotationsAttribute) mi.getAttribute(AnnotationsAttribute.invisibleTag);
-      if (invisible != null)
+
+      moveAnnotations(mi, wmi, AnnotationsAttribute.invisibleTag);
+      moveAnnotations(mi, wmi, AnnotationsAttribute.visibleTag);
+      int numParams = src.getParameterTypes().length;
+      moveParameterAnnotations(numParams, mi, wmi, ParameterAnnotationsAttribute.visibleTag);
+      moveParameterAnnotations(numParams, mi, wmi, ParameterAnnotationsAttribute.invisibleTag);
+   }
+
+   private void moveAnnotations(MethodInfo src, MethodInfo dest, String annotationTag)
+   {
+      AnnotationsAttribute attribute = (AnnotationsAttribute) src.getAttribute(annotationTag);
+      if (attribute != null)
       {
-         wmi.addAttribute(invisible.copy(wmi.getConstPool(), new HashMap()));
+         dest.addAttribute(attribute.copy(dest.getConstPool(), new HashMap()));
+         src.addAttribute(new AnnotationsAttribute(src.getConstPool(), annotationTag));
       }
-      AnnotationsAttribute visible = (AnnotationsAttribute) mi.getAttribute(AnnotationsAttribute.visibleTag);
-      if (visible != null)
+   }
+   
+   private void moveParameterAnnotations(int numParams, MethodInfo src, MethodInfo dest, String paramsTag)
+   {
+      ParameterAnnotationsAttribute params = (ParameterAnnotationsAttribute)src.getAttribute(paramsTag);
+      if (params != null)
       {
-         wmi.addAttribute(visible.copy(wmi.getConstPool(), new HashMap()));
+         dest.addAttribute(params.copy(dest.getConstPool(), new HashMap()));
+         ParameterAnnotationsAttribute srcParams = new ParameterAnnotationsAttribute(src.getConstPool(), paramsTag);
+         Annotation[][] emptyParamAnnotations = new Annotation[numParams][];
+         for (int i = 0 ; i < numParams ; i++)
+         {
+            emptyParamAnnotations[i] = new Annotation[0];
+         }
+         srcParams.setAnnotations(emptyParamAnnotations);
+         src.addAttribute(srcParams);
       }
-      mi.addAttribute(new AnnotationsAttribute(mi.getConstPool(), AnnotationsAttribute.invisibleTag));
-      mi.addAttribute(new AnnotationsAttribute(mi.getConstPool(), AnnotationsAttribute.visibleTag));
    }
 
    protected static String getAopReturnStr(CtMethod method)throws NotFoundException

Modified: branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/util/ReflectToJavassist.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/util/ReflectToJavassist.java	2006-12-18 10:55:16 UTC (rev 59071)
+++ branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/util/ReflectToJavassist.java	2006-12-18 11:10:31 UTC (rev 59072)
@@ -55,6 +55,7 @@
       Class clazz = field.getDeclaringClass();
       return classToJavassist(field.getDeclaringClass()).getField(field.getName());
    }
+   
    public static CtConstructor constructorToJavassist(Constructor con) throws NotFoundException
    {
       Class clazz = con.getDeclaringClass();

Modified: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java	2006-12-18 10:55:16 UTC (rev 59071)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java	2006-12-18 11:10:31 UTC (rev 59072)
@@ -24,8 +24,12 @@
 import java.lang.reflect.Method;
 import java.util.ArrayList;
 
+import javassist.CtMethod;
+import javassist.NotFoundException;
+
 import org.jboss.aop.Advised;
 import org.jboss.aop.Advisor;
+import org.jboss.aop.util.ReflectToJavassist;
 
 import junit.framework.Test;
 import junit.framework.TestSuite;
@@ -64,6 +68,7 @@
       Advisor advisor = ((Advised)pojo)._getAdvisor();
       
       ArrayList hasAnnotation = new ArrayList();
+      ArrayList hasParameterAnnotation = new ArrayList();
       for (int i = 0 ; i < methods.length ; i++)
       {
          Object ann = advisor.resolveAnnotation(methods[i], TestAnnotation.class);
@@ -71,11 +76,25 @@
          {
             hasAnnotation.add(methods[i].getName());
          }
+
+         CtMethod ctmethod = ReflectToJavassist.methodToJavassist(methods[i]);
+         Object[][] paramAnnotations = ctmethod.getParameterAnnotations();
+         for (int p = 0 ; p < paramAnnotations.length ; p++)
+         {
+            if (paramAnnotations[p].length > 0)
+            {
+               hasParameterAnnotation.add(methods[i].getName() + "1");
+            }
+         }
       }
       
       assertFalse("Expected to find annotation for 'method'", hasAnnotation.size() == 0);
+      assertFalse("Expected to find parameter annotation for 'method'", hasParameterAnnotation.size() == 0);
       assertTrue("Expected to find annotation for 'method' only, it was found for " + hasAnnotation, hasAnnotation.size() == 1);
+      assertTrue("Expected to find parameter annotation for 'method' only, it was found for " + hasParameterAnnotation, hasAnnotation.size() == 1);
       assertEquals("method", hasAnnotation.get(0));
+      assertEquals("method1", hasParameterAnnotation.get(0));
+      assertTrue("Class was not woven", Advised.class.isAssignableFrom(POJO.class));
    }
 
 }

Modified: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java	2006-12-18 10:55:16 UTC (rev 59071)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java	2006-12-18 11:10:31 UTC (rev 59072)
@@ -28,10 +28,8 @@
  */
 public class POJO
 {
-   /**
-    * @@org.jboss.test.aop.regression.jbaop316annotationsinwrapperonly.TestAnnotation
-    */
-   public void method()
+   @TestAnnotation
+   public void method(int i, @TestAnnotation String s)
    {
       
    }

Modified: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java	2006-12-18 10:55:16 UTC (rev 59071)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java	2006-12-18 11:10:31 UTC (rev 59072)
@@ -21,11 +21,15 @@
 */ 
 package org.jboss.test.aop.regression.jbaop316annotationsinwrapperonly;
 
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
  * @version $Revision: 1.1 $
  */
-public interface TestAnnotation {
+ at Retention(RetentionPolicy.RUNTIME)
+public @interface TestAnnotation {
 
 }



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 06:13:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 06:13:10 -0500
Subject: [jboss-cvs] JBossAS SVN: r59073 -
	projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml
Message-ID: <E1GwGQg-0006mQ-7x@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 06:13:07 -0500 (Mon, 18 Dec 2006)
New Revision: 59073

Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
Log:
typo

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-18 11:10:31 UTC (rev 59072)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringSchemaBindingHelper.java	2006-12-18 11:13:07 UTC (rev 59073)
@@ -34,7 +34,7 @@
    {
       typeBinding.setHandler(SpringBeansHandler.HANDLER);
       // handle beans
-      typeBinding.pushInterceptor(SpringSchemaBinding.beansQName, SpringBeansInterceptor.INTERCEPTOR);
+      typeBinding.pushInterceptor(SpringSchemaBinding.beanQName, SpringBeansInterceptor.INTERCEPTOR);
       // todo alias
       // todo import
    }



From gavin.king at jboss.com  Mon Dec 18 06:52:50 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 06:52:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core     ...
Message-ID: <E1GwH34-0007XY-1A@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 06:52:49

  Modified:    src/main/org/jboss/seam/core     LocaleSelector.java
                        Manager.java TimeZoneSelector.java
  Added:       src/main/org/jboss/seam/core     Selector.java
  Log:
  JBSEAM-610,   JBSEAM-536, refactor
  
  Revision  Changes    Path
  1.17      +19 -41    jboss-seam/src/main/org/jboss/seam/core/LocaleSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocaleSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/LocaleSelector.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- LocaleSelector.java	26 Nov 2006 03:22:59 -0000	1.16
  +++ LocaleSelector.java	18 Dec 2006 11:52:49 -0000	1.17
  @@ -3,7 +3,6 @@
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.Iterator;
   import java.util.List;
  @@ -13,9 +12,7 @@
   import javax.faces.context.FacesContext;
   import javax.faces.model.SelectItem;
   import javax.servlet.ServletRequest;
  -import javax.servlet.http.Cookie;
   import javax.servlet.http.HttpServletRequest;
  -import javax.servlet.http.HttpServletResponse;
   
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
  @@ -38,41 +35,40 @@
   @Name("org.jboss.seam.core.localeSelector")
   @Intercept(NEVER)
   @Install(precedence=BUILT_IN)
  -public class LocaleSelector extends AbstractMutable implements Serializable
  +public class LocaleSelector extends Selector
   {
   
      private String language;
      private String country;
      private String variant;
      
  -   private boolean cookieEnabled;
  -   private int cookieMaxAge = 31536000; //1 year
  -   
      @Create
      public void initLocale()
      {
  -      if (cookieEnabled)
  -      {
  -         Cookie cookie = (Cookie) FacesContext.getCurrentInstance().getExternalContext()
  -               .getRequestCookieMap().get("org.jboss.seam.core.Locale");
  -         if (cookie!=null) setLocaleString( cookie.getValue() );
  +      String localeString = getCookieValue();
  +      if (localeString!=null) setLocaleString(localeString);
         }
  +   
  +   @Override
  +   protected String getCookieName()
  +   {
  +      return "org.jboss.seam.core.Locale";
      }
      
      /**
  -    * Force the resource bundle to reload, using the current locale
  +    * Force the resource bundle to reload, using the current locale,
  +    * and raise the org.jboss.seam.localeSelected event.
       */
      public void select()
      {
         FacesContext.getCurrentInstance().getViewRoot().setLocale( getLocale() );
         Contexts.removeFromAllContexts( Seam.getComponentName(ResourceBundle.class) );
         Contexts.removeFromAllContexts( Seam.getComponentName(Messages.class) );
  -      if (cookieEnabled)
  -      {
  -         HttpServletResponse response = (HttpServletResponse) FacesContext.getCurrentInstance().getExternalContext().getResponse();
  -         Cookie cookie = new Cookie( "org.jboss.seam.core.Locale", getLocaleString() );
  -         cookie.setMaxAge(cookieMaxAge);
  -         response.addCookie(cookie);
  +      
  +      setCookieValue( getLocaleString() );
  +
  +      if ( Events.exists() ) {
  +          Events.instance().raiseEvent( "org.jboss.seam.localeSelected", getLocaleString() );
         }
      }
   
  @@ -140,6 +136,9 @@
         return selectItems;
      }
   
  +   /**
  +    * Get the selected locale
  +    */
      public Locale getLocale() 
      {
         FacesContext facesContext = FacesContext.getCurrentInstance();
  @@ -201,25 +200,4 @@
         this.variant = variant;
      }
   
  -   public boolean isCookieEnabled()
  -   {
  -      return cookieEnabled;
  -   }
  -
  -   public void setCookieEnabled(boolean cookieEnabled)
  -   {
  -      setDirty(this.cookieEnabled, cookieEnabled);
  -      this.cookieEnabled = cookieEnabled;
  -   }
  -
  -   protected int getCookieMaxAge()
  -   {
  -      return cookieMaxAge;
  -   }
  -
  -   protected void setCookieMaxAge(int cookieMaxAge)
  -   {
  -      this.cookieMaxAge = cookieMaxAge;
  -   }
  -   
   }
  
  
  
  1.129     +5 -2      jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.128
  retrieving revision 1.129
  diff -u -b -r1.128 -r1.129
  --- Manager.java	18 Dec 2006 01:46:24 -0000	1.128
  +++ Manager.java	18 Dec 2006 11:52:49 -0000	1.129
  @@ -43,7 +43,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.128 $
  + * @version $Revision: 1.129 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -1144,7 +1144,10 @@
         }
         if (validationFailedAction!=null)
         {
  -         validationFailedAction.invoke(ctx, null);
  +         Object result = validationFailedAction.invoke(ctx, null);
  +         String outcome = result==null ? null : result.toString();
  +         ctx.getApplication().getNavigationHandler()
  +               .handleNavigation(ctx, validationFailedAction.getExpressionString(), outcome);
         }
      }
   
  
  
  
  1.7       +97 -122   jboss-seam/src/main/org/jboss/seam/core/TimeZoneSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TimeZoneSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TimeZoneSelector.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- TimeZoneSelector.java	26 Nov 2006 03:22:59 -0000	1.6
  +++ TimeZoneSelector.java	18 Dec 2006 11:52:49 -0000	1.7
  @@ -3,12 +3,6 @@
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import java.io.Serializable;
  -
  -import javax.faces.context.FacesContext;
  -import javax.servlet.http.Cookie;
  -import javax.servlet.http.HttpServletResponse;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
  @@ -28,36 +22,35 @@
   @Name("org.jboss.seam.core.timeZoneSelector")
   @Intercept(NEVER)
   @Install(value=false, precedence=BUILT_IN)
  -public class TimeZoneSelector extends AbstractMutable implements Serializable
  +public class TimeZoneSelector extends Selector
   {
   
      private String id;
      
  -   private boolean cookieEnabled;
  -   private int cookieMaxAge = 31536000; //1 year
  -   
      @Create
      public void initTimeZone()
      {
  -      if (cookieEnabled)
  -      {
  -         Cookie cookie = (Cookie) FacesContext.getCurrentInstance().getExternalContext()
  -               .getRequestCookieMap().get("org.jboss.seam.core.TimeZone");
  -         if (cookie!=null) setTimeZoneId( cookie.getValue() );
  +      String timeZoneId = getCookieValue();
  +      if (timeZoneId!=null) setTimeZoneId(timeZoneId);
         }
  +   
  +   @Override
  +   protected String getCookieName()
  +   {
  +      return "org.jboss.seam.core.TimeZone";
      }
      
      /**
  -    * Force the resource bundle to reload, using the current locale
  +    * Force the resource bundle to reload, using the current locale, 
  +    * and raise the org.jboss.seam.timeToneSelected event
       */
      public void select()
      {
  -      if (cookieEnabled)
  +      setCookieValue( getTimeZoneId() );
  +
  +      if ( Events.exists() ) 
         {
  -         HttpServletResponse response = (HttpServletResponse) FacesContext.getCurrentInstance().getExternalContext().getResponse();
  -         Cookie cookie = new Cookie( "org.jboss.seam.core.TimeZone", getTimeZoneId() );
  -         cookie.setMaxAge(cookieMaxAge);
  -         response.addCookie(cookie);
  +          Events.instance().raiseEvent( "org.jboss.seam.timeToneSelected", getTimeZoneId() );
         }
      }
   
  @@ -77,6 +70,9 @@
         return id;
      }
   
  +   /**
  +    * Get the selected timezone
  +    */
      public java.util.TimeZone getTimeZone() 
      {
         if (id==null)
  @@ -98,25 +94,4 @@
         return (TimeZoneSelector) Component.getInstance(TimeZoneSelector.class, ScopeType.SESSION);
      }
   
  -   public boolean isCookieEnabled()
  -   {
  -      return cookieEnabled;
  -   }
  -
  -   public void setCookieEnabled(boolean cookieEnabled)
  -   {
  -      setDirty(this.cookieEnabled, cookieEnabled);
  -      this.cookieEnabled = cookieEnabled;
  -   }
  -
  -   protected int getCookieMaxAge()
  -   {
  -      return cookieMaxAge;
  -   }
  -
  -   protected void setCookieMaxAge(int cookieMaxAge)
  -   {
  -      this.cookieMaxAge = cookieMaxAge;
  -   }
  -   
   }
  
  
  
  1.1      date: 2006/12/18 11:52:49;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/Selector.java
  
  Index: Selector.java
  ===================================================================
  package org.jboss.seam.core;
  
  import java.io.Serializable;
  
  import javax.faces.context.FacesContext;
  import javax.servlet.http.Cookie;
  import javax.servlet.http.HttpServletResponse;
  
  /**
   * Support for selector objects which remember their selection as a cookie
   * 
   * @author Gavin King
   */
  public abstract class Selector extends AbstractMutable implements Serializable
  {
     private boolean cookieEnabled;
     private int cookieMaxAge = 31536000; //1 year
     
     /**
      * Is the cookie enabled?
      * @return false by default
      */
     public boolean isCookieEnabled()
     {
        return cookieEnabled;
     }
  
     public void setCookieEnabled(boolean cookieEnabled)
     {
        setDirty(this.cookieEnabled, cookieEnabled);
        this.cookieEnabled = cookieEnabled;
     }
  
     /**
      * The max age of the cookie
      * @return 1 year by default
      */
     public int getCookieMaxAge()
     {
        return cookieMaxAge;
     }
  
     public void setCookieMaxAge(int cookieMaxAge)
     {
        this.cookieMaxAge = cookieMaxAge;
     }
     
     /**
      * Override to define the cookie name
      */
     protected abstract String getCookieName();
     
     /**
      * Get the value of the cookie
      */
     protected String getCookieValue()
     {
        if ( isCookieEnabled() )
        {
           Cookie cookie = (Cookie) FacesContext.getCurrentInstance().getExternalContext()
                 .getRequestCookieMap().get( getCookieName() );
           return cookie==null ? null : cookie.getValue();
        }
        else
        {
           return null;
        }
     }
     
     /**
      * Set the cookie
      */
     protected void setCookieValue(String value)
     {
        if ( isCookieEnabled() )
        {
           HttpServletResponse response = (HttpServletResponse) FacesContext.getCurrentInstance().getExternalContext().getResponse();
           Cookie cookie = new Cookie( getCookieName(), value );
           cookie.setMaxAge( getCookieMaxAge() );
           response.addCookie(cookie);
        }
     }
  }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 06:52:50 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 06:52:50 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/theme  ...
Message-ID: <E1GwH34-0007Xk-5w@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 06:52:50

  Modified:    src/main/org/jboss/seam/theme  ThemeSelector.java
  Log:
  JBSEAM-610,   JBSEAM-536, refactor
  
  Revision  Changes    Path
  1.10      +174 -171  jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThemeSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- ThemeSelector.java	16 Dec 2006 02:58:13 -0000	1.9
  +++ ThemeSelector.java	18 Dec 2006 11:52:50 -0000	1.10
  @@ -3,7 +3,6 @@
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.List;
   import java.util.MissingResourceException;
  @@ -12,11 +11,7 @@
   import javax.faces.component.UIViewRoot;
   import javax.faces.context.FacesContext;
   import javax.faces.model.SelectItem;
  -import javax.servlet.http.Cookie;
  -import javax.servlet.http.HttpServletResponse;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -26,8 +21,12 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -import org.jboss.seam.core.AbstractMutable;
  +import org.jboss.seam.core.Events;
   import org.jboss.seam.core.Locale;
  +import org.jboss.seam.core.Messages;
  +import org.jboss.seam.core.Selector;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   /**
    * Selects the current user's theme
  @@ -38,25 +37,18 @@
   @Name("org.jboss.seam.theme.themeSelector")
   @Intercept(NEVER)
   @Install(precedence=BUILT_IN)
  -public class ThemeSelector extends AbstractMutable implements Serializable
  +public class ThemeSelector extends Selector
   {
      private static final LogProvider log = Logging.getLogProvider(ThemeSelector.class);
      
      private String theme;
      private String[] availableThemes;
      
  -   private boolean cookieEnabled;
  -   private int cookieMaxAge = 31536000; //1 year
  -   
      @Create
      public void initDefaultTheme()
      {
  -      if (cookieEnabled)
  -      {
  -         Cookie cookie = (Cookie) FacesContext.getCurrentInstance().getExternalContext()
  -               .getRequestCookieMap().get("org.jboss.seam.core.Theme");
  -         if (cookie!=null) theme = cookie.getValue();
  -      }
  +      String themeName = getCookieValue();
  +      if (themeName!=null) setTheme(themeName);
         
         if (theme==null)
         {
  @@ -71,6 +63,17 @@
         }
      }
      
  +   @Override
  +   protected String getCookieName()
  +   {
  +      return "org.jboss.seam.core.Theme";
  +   }
  +   
  +   /**
  +    * Recreate the JSF view, using the new theme, and raise the 
  +    * org.jboss.seam.themeSelected event
  +    *
  +    */
      public void select()
      {
         Contexts.removeFromAllContexts( Seam.getComponentName(Theme.class) );
  @@ -78,25 +81,31 @@
         String viewId = facesContext.getViewRoot().getViewId();
         UIViewRoot viewRoot = facesContext.getApplication().getViewHandler().createView(facesContext, viewId);
         facesContext.setViewRoot(viewRoot);
  -      if (cookieEnabled)
  +      
  +      setCookieValue( getTheme() );
  +
  +      if ( Events.exists() ) 
         {
  -         HttpServletResponse response = (HttpServletResponse) facesContext.getExternalContext().getResponse();
  -         Cookie cookie = new Cookie("org.jboss.seam.core.Theme", theme);
  -         cookie.setMaxAge(cookieMaxAge);
  -         response.addCookie( cookie );
  +          Events.instance().raiseEvent( "org.jboss.seam.themeSelected", getTheme() );
         }
      }
   
  +   /**
  +    * Get a selectable list of available themes for display in the UI
  +    */
      public List<SelectItem> getThemes()
      {
         List<SelectItem> selectItems = new ArrayList<SelectItem>(availableThemes.length);
         for ( String name: availableThemes )
         {
  -         selectItems.add( new SelectItem(name, name) ); //TODO: allow meaningful name
  +         selectItems.add( new SelectItem( name, getLocalizedThemeName(name) ) );
         }
         return selectItems;
      }
   
  +   /**
  +    * Get the name of the current theme
  +    */
      public String getTheme()
      {
         return theme;
  @@ -114,6 +123,9 @@
         this.availableThemes = themeNames;
      }
      
  +   /**
  +    * Get the resource bundle for the theme
  +    */
      public ResourceBundle getThemeResourceBundle()
      {
         try
  @@ -133,6 +145,18 @@
         }
      }
   
  +   /**
  +    * Get the localized name of the named theme, by looking for
  +    * org.jboss.seam.theme.&lt;name&gt; in the Seam resource
  +    * bundle
  +    */
  +   public String getLocalizedThemeName(String name) 
  +   {
  +       String key = "org.jboss.seam.theme." + name;
  +       String localizedName = (String) Messages.instance().get(key);
  +       return key.equals(localizedName) ? name : localizedName;
  +   }
  +   
      public static ThemeSelector instance()
      {
         if ( !Contexts.isSessionContextActive() )
  @@ -147,25 +171,4 @@
         return availableThemes;
      }
   
  -   public boolean isCookieEnabled()
  -   {
  -      return cookieEnabled;
  -   }
  -
  -   public void setCookieEnabled(boolean cookieEnabled)
  -   {
  -      setDirty(this.cookieEnabled, cookieEnabled);
  -      this.cookieEnabled = cookieEnabled;
  -   }
  -
  -   protected int getCookieMaxAge()
  -   {
  -      return cookieMaxAge;
  -   }
  -
  -   protected void setCookieMaxAge(int cookieMaxAge)
  -   {
  -      this.cookieMaxAge = cookieMaxAge;
  -   }
  -
   }
  
  
  


From msurtani at jboss.com  Mon Dec 18 07:27:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 18 Dec 2006 07:27:52 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GwHay-0008I0-2b@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/18 07:27:52

  Modified:    JBossCache  build.xml
  Log:
  refactored
  
  Revision  Changes    Path
  1.154     +39 -36    JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.153
  retrieving revision 1.154
  diff -u -b -r1.153 -r1.154
  --- build.xml	17 Nov 2006 13:52:37 -0000	1.153
  +++ build.xml	18 Dec 2006 12:27:51 -0000	1.154
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.153 2006/11/17 13:52:37 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.154 2006/12/18 12:27:51 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -119,6 +119,7 @@
         <pathelement location="${output.etc.dir}"/>
         <pathelement location="${compiletest.dir}"/>
         <pathelement location="${output.resources.dir}"/>
  +      <pathelement location="${functional.tests.dir}"/>
      </path>
   
      <path id="retro.output.classpath">
  @@ -464,6 +465,8 @@
            <classpath refid="output.classpath"/>
            <formatter type="xml" usefile="true"/>
            <test name="${test}" todir="${build.reports}"/>
  +         <jvmarg value="-Dbind.address=${bind.address}"/>
  +         <jvmarg value="-Djava.net.preferIPv4Stack=true"/>
         </junit>
      </target>
   
  @@ -743,7 +746,7 @@
         </junit>
      </target>
   
  -<!--
  +   <!--
      <target name="perfAopTests" depends="compile,aopc,unittests-init" description="Runs all AOP performance tests">
         <junit printsummary="yes" timeout="${junit.timeout}" fork="yes">
            <classpath refid="library.classpath"/>
  @@ -777,7 +780,7 @@
            </batchtest>
         </junit>
      </target>
  --->
  +   -->
   
      <target name="all-functionaltests"
              depends="functionaltests, functionalPojoCacheTests"
  
  
  


From msurtani at jboss.com  Mon Dec 18 07:27:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 18 Dec 2006 07:27:52 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1GwHay-0008I7-8A@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/18 07:27:52

  Modified:    tests/functional/org/jboss/cache/marshall  SyncReplTest.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.13      +20 -19    JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- SyncReplTest.java	5 Dec 2006 23:07:25 -0000	1.12
  +++ SyncReplTest.java	18 Dec 2006 12:27:52 -0000	1.13
  @@ -11,7 +11,6 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  -
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
  @@ -31,7 +30,7 @@
    * Test case for marshalling using Sync mode.
    *
    * @author Ben Wang
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.13 $
    */
   public class SyncReplTest extends RegionBasedMarshallingTestBase
   {
  @@ -239,9 +238,10 @@
            assertFalse("cache2 deserialized with scoped classloader", ben2 instanceof Person);
            assertFalse("cache2 deserialized with cache2 classloader", scopedBen1.equals(ben2));
            assertEquals("scopedBen deserialized properly", scopedBen2, ben2);
  -      } catch (Exception ex)
  +      }
  +      catch (Exception ex)
         {
  -         fail("Test fails with exception " +ex);
  +         fail("Test fails with exception " + ex);
         }
   
      }
  @@ -372,22 +372,23 @@
         {
            Object val = cache2.get(new Fqn(base, custom2), "key");
            assertEquals("value", val);
  -      } catch (Exception ex)
  +      }
  +      catch (Exception ex)
         {
  -         fail("Test fails with exception " +ex);
  +         fail("Test fails with exception " + ex);
         }      
      }
   
      Transaction beginTransaction() throws SystemException, NotSupportedException 
      {
  -      DummyTransactionManager mgr=DummyTransactionManager.getInstance();
  +      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
      
      protected Object getPersonFromClassloader(ClassLoader cl) throws Exception
      {
  -      Class clazz = cl.loadClass("org.jboss.cache.marshall.Person");
  +      Class clazz = cl.loadClass(PERSON_CLASSNAME);
         return clazz.newInstance();
      }
   
  
  
  


From msurtani at jboss.com  Mon Dec 18 07:51:36 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 18 Dec 2006 07:51:36 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GwHxw-0000Gv-4i@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/18 07:51:36

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  Reinstated InactiveRegionAwareRpcDispatcher
  
  Revision  Changes    Path
  1.294     +9 -3      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.293
  retrieving revision 1.294
  diff -u -b -r1.293 -r1.294
  --- TreeCache.java	15 Dec 2006 14:19:57 -0000	1.293
  +++ TreeCache.java	18 Dec 2006 12:51:36 -0000	1.294
  @@ -29,6 +29,7 @@
   import org.jboss.cache.lock.LockingException;
   import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.lock.TimeoutException;
  +import org.jboss.cache.marshall.InactiveRegionAwareRpcDispatcher;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodCallFactory;
   import org.jboss.cache.marshall.MethodDeclarations;
  @@ -94,7 +95,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.293 2006/12/15 14:19:57 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.294 2006/12/18 12:51:36 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -692,8 +693,13 @@
                           MBeanServer server=(MBeanServer)servers.get(0);
                           JmxConfigurator.registerChannel(channel, server, "JGroups:channel=" + channel.getChannelName() , true);
               */
  -            // disp = new InactiveRegionAwareRpcDispatcher(channel, ml, this, this);
  -            disp = new RpcDispatcher(channel, ml, this, this);
  +
  +            // always use the InactiveRegionAwareRpcDispatcher - exceptions due to regions not being active should not propagate to remote
  +            // nodes as errors. - Manik
  +            disp = new InactiveRegionAwareRpcDispatcher(channel, ml, this, this);
  +//            disp = new RpcDispatcher(channel, ml, this, this);
  +
  +
               disp.setMarshaller(getMarshaller());
   
               setBuddyReplicationConfig(configuration.getBuddyReplicationConfig());
  
  
  


From msurtani at jboss.com  Mon Dec 18 07:54:23 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Mon, 18 Dec 2006 07:54:23 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock   ...
Message-ID: <E1GwI0d-0000IS-RU@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/18 07:54:23

  Modified:    tests/functional/org/jboss/cache/lock   LockReleaseTest.java
                        UpgradeLockTest.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.5       +9 -9      JBossCache/tests/functional/org/jboss/cache/lock/LockReleaseTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockReleaseTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/LockReleaseTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- LockReleaseTest.java	20 Nov 2006 07:33:14 -0000	1.4
  +++ LockReleaseTest.java	18 Dec 2006 12:54:23 -0000	1.5
  @@ -26,7 +26,7 @@
    * Verifies that there are no read locks held when a transaction ends.
    *
    * @author Bela Ban
  - * @version $Id: LockReleaseTest.java,v 1.4 2006/11/20 07:33:14 genman Exp $
  + * @version $Id: LockReleaseTest.java,v 1.5 2006/12/18 12:54:23 msurtani Exp $
    */
   public class LockReleaseTest extends TestCase
   {
  @@ -161,9 +161,9 @@
   
         tx.begin();
         keys = cache.getKeys(NODE1);
  -      assertEquals("we should hold 1 read locks now: ", 1, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 1 read locks now: ", 2, cache.getNumberOfLocksHeld());
         keys = cache.getKeys(NODE2);
  -      assertEquals("we should hold 3 read locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 3 read locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
         assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
  @@ -184,9 +184,9 @@
   
         tx.begin();
         keys = cache.getChildrenNames(NODE1);
  -      assertEquals("we should hold 1 read locks now: ", 1, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 1 read locks now: ", 2, cache.getNumberOfLocksHeld());
         keys = cache.getChildrenNames(NODE2);
  -      assertEquals("we should hold 3 read locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 3 read locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
         assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
  @@ -204,9 +204,9 @@
   
         tx.begin();
         cache.print(NODE1);
  -      assertEquals("we should hold 1 read locks now (for print()): ", 1, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 1 read locks now (for print()): ", 2, cache.getNumberOfLocksHeld());
         cache.print(NODE2);
  -      assertEquals("we should hold 3 read locks now (for print()): ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 3 read locks now (for print()): ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
         assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
  @@ -224,7 +224,7 @@
         tx.begin();
         assertEquals(VAL1, cache.get(NODE1, KEY));
         assertEquals(VAL1, cache.get(NODE2, KEY));
  -      assertEquals("we should hold 3 read locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 3 read locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
         assertEquals("we should have released all 3 read locks: ", 0, cache.getNumberOfLocksHeld());
      }
  @@ -241,7 +241,7 @@
         tx.begin();
         cache.put(NODE1, KEY, VAL1);
         cache.put(NODE2, KEY, VAL1);
  -      assertEquals("we should hold 3 write locks now: ", 3, cache.getNumberOfLocksHeld());
  +      assertEquals("we should hold 3 write locks now: ", 4, cache.getNumberOfLocksHeld());
         tx.commit();
         assertEquals("we should have released all 3 write locks: ", 0, cache.getNumberOfLocksHeld());
      }
  
  
  
  1.5       +2 -2      JBossCache/tests/functional/org/jboss/cache/lock/UpgradeLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UpgradeLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/UpgradeLockTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- UpgradeLockTest.java	6 Sep 2006 15:30:58 -0000	1.4
  +++ UpgradeLockTest.java	18 Dec 2006 12:54:23 -0000	1.5
  @@ -24,7 +24,7 @@
    * Tests upgrade locks from read -> write
    *
    * @author Bela Ban
  - * @version $Id: UpgradeLockTest.java,v 1.4 2006/09/06 15:30:58 msurtani Exp $
  + * @version $Id: UpgradeLockTest.java,v 1.5 2006/12/18 12:54:23 msurtani Exp $
    */
   public class UpgradeLockTest extends TestCase
   {
  @@ -143,7 +143,7 @@
         cache = createCache(l);
         tx.begin();
   
  -      int expected_num_locks = l == IsolationLevel.NONE ? 0 : 1;
  +      int expected_num_locks = l == IsolationLevel.NONE ? 0 : 2;
   
         cache.put(NODE1, null);
         assertEquals(expected_num_locks, cache.getNumberOfLocksHeld());
  
  
  


From vrhwerui98456 at lycos.com  Mon Dec 18 07:54:32 2006
From: vrhwerui98456 at lycos.com (vrhwerui98456 at lycos.com)
Date: Mon, 18 Dec 2006 07:54:32 -0500
Subject: [jboss-cvs] =?utf-8?b?worCrsKRU8KJacKLdsKWwrPCl8K/woNUwoNDwoNn?=
	=?utf-8?b?woLCqsKVwpzCisKIwoFJwo9vwonDr8KCwqLCgsOwworDiMKSUMKCw4k=?=
	=?utf-8?b?wozCqcKCw4LCgsKvwoLDqcKBSQ==?=
Message-ID: 20061218210325.85145mail@mail.meetmeetnearsidetown5719712412468512480.com

?????????????N???????f?G?????????????????H????????????

?????`???????S?????I?I?????????[???????????X?^?[?g?I?I

???c???@ http://www.freeweb.allfreemail.net.tonderuyo.com/meets/   ???c??
?@?@?@?@?@?i???S?????j

     ???{?C???J???C?C???????????????R?R??????????
     ???Z?t???A?????????A???l???????E?E?E?E?E?E??
============================================================

?@?@?@?@?@?@?@?@?????????????o??????????

???c???@ http://www.freeweb.allfreemail.net.tonderuyo.com/meets/  ???c??
?@?@?@?@?@?i???S?????j

??????????????????????????????????????????????????????????????
                  ???J?b?v?????????m?n?P??
         ???H?????A?s???????o?^?????????I???V?X?e????

???c???@ http://www.freeweb.allfreemail.net.tonderuyo.com/meets/   ???c??
?@?@?@?@?@?i???S?????j

??????????????????????????????????????????????????????????????








From alex at jboss.com  Mon Dec 18 08:03:06 2006
From: alex at jboss.com (Alex Loubyansky)
Date: Mon, 18 Dec 2006 08:03:06 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossxb/snapshot/lib  ...
Message-ID: <E1GwI94-0000eI-TG@committer01.frg.pub.inap.atl.jboss.com>

  User: aloubyansky
  Date: 06/12/18 08:03:06

  Modified:    jboss/jbossxb/snapshot/lib  jboss-xml-binding.jar
  Log:
  latest fixes
  
  Revision  Changes    Path
  1.28      +1779 -1705repository.jboss.com/jboss/jbossxb/snapshot/lib/jboss-xml-binding.jar
  
  	<<Binary file>>
  
  


From dimitris.andreadis at jboss.com  Mon Dec 18 08:04:38 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 08:04:38 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws14/1.0.4.GA  ...
Message-ID: <E1GwIAY-0000eX-Nk@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 08:04:38

  Modified:    jboss/jbossws14/1.0.4.GA  component-info.xml
  Log:
  mark compatible with jboss remoting 1.4.4 / 1.4.5
  
  Revision  Changes    Path
  1.4       +3 -1      repository.jboss.com/jboss/jbossws14/1.0.4.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws14/1.0.4.GA/component-info.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- component-info.xml	12 Dec 2006 08:37:13 -0000	1.3
  +++ component-info.xml	18 Dec 2006 13:04:38 -0000	1.4
  @@ -26,6 +26,8 @@
         </import>
         <import componentref="jboss/remoting">
         	<compatible version="1.4.3.GA"/>        
  +      	<compatible version="1.4.4.GA"/>  
  +      	<compatible version="1.4.5.GA"/>          
         </import>
         <import componentref="jboss/jbossretro-rt">
         	<compatible version="1.0.2.GA"/>
  
  
  


From dimitris.andreadis at jboss.com  Mon Dec 18 08:05:00 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 08:05:00 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/1.0.4.GA  ...
Message-ID: <E1GwIAu-0000ek-BY@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 08:05:00

  Modified:    jboss/jbossws/1.0.4.GA  component-info.xml
  Log:
  mark compatible with jboss remoting 1.4.4 / 1.4.5
  
  Revision  Changes    Path
  1.3       +3 -1      repository.jboss.com/jboss/jbossws/1.0.4.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/jbossws/1.0.4.GA/component-info.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- component-info.xml	11 Dec 2006 20:00:02 -0000	1.2
  +++ component-info.xml	18 Dec 2006 13:05:00 -0000	1.3
  @@ -26,6 +26,8 @@
         </import>
         <import componentref="jboss/remoting">
         	<compatible version="1.4.3.GA"/>        
  +      	<compatible version="1.4.4.GA"/>  
  +      	<compatible version="1.4.5.GA"/>          
         </import>
   
         <export>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 08:10:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 08:10:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r59074 - in
	projects/microcontainer/trunk/spring-int/src:
	main/org/jboss/spring/deployment/xml
	resources/xml-test/org/jboss/test/spring/test
	tests/org/jboss/test/spring/support tests/org/jboss/test/spring/test
Message-ID: <E1GwIGD-0000mR-MD@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 08:10:19 -0500 (Mon, 18 Dec 2006)
New Revision: 59074

Added:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTestDelegate.java
Modified:
   projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
Log:
Instantiation tests - not yet supporting collections.

Modified: projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/main/org/jboss/spring/deployment/xml/SpringBeanHandler.java	2006-12-18 13:10:19 UTC (rev 59074)
@@ -23,19 +23,18 @@
 
 import javax.xml.namespace.NamespaceContext;
 import javax.xml.namespace.QName;
-
+import java.util.Arrays;
 import java.util.List;
-import java.util.Collections;
-import java.util.Comparator;
 
 import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
-import org.jboss.beans.metadata.plugins.AbstractLifecycleMetaData;
 import org.jboss.beans.metadata.plugins.AbstractConstructorMetaData;
 import org.jboss.beans.metadata.plugins.AbstractDependencyValueMetaData;
+import org.jboss.beans.metadata.plugins.AbstractLifecycleMetaData;
 import org.jboss.beans.metadata.spi.ConstructorMetaData;
 import org.jboss.beans.metadata.spi.ParameterMetaData;
 import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
 import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
+import org.jboss.spring.metadata.AbstractConstructorArg;
 import org.xml.sax.Attributes;
 
 /**
@@ -92,20 +91,41 @@
          List<ParameterMetaData> parameters = constructor.getParameters();
          if (parameters != null && parameters.size() > 1)
          {
-            Collections.sort(parameters, ParameterIndexComparator.INSTANCE);
+            orderParameters(parameters);
          }
       }
       return beanMetaData;
    }
 
-   private static class ParameterIndexComparator implements Comparator<ParameterMetaData>
+   protected void orderParameters(List<ParameterMetaData> parameters)
    {
-      static Comparator<ParameterMetaData> INSTANCE = new ParameterIndexComparator();
-
-      public int compare(ParameterMetaData pmd1, ParameterMetaData pmd2)
+      ParameterMetaData[] pmds = new ParameterMetaData[parameters.size()];
+      int i = 0;
+      for(ParameterMetaData pmd : parameters)
       {
-         return 0; // todo
+         int index = pmd.getIndex();
+         // lets first try to set those with explicit index
+         if (pmd instanceof AbstractConstructorArg && ((AbstractConstructorArg)pmd).isExplicitIndex())
+         {
+            if (pmds[index] != null)
+               throw new IllegalArgumentException("Argument with index: " + index + " already set!");
+            pmds[index] = pmd;
+         }
       }
+      int index = 0;
+      for(ParameterMetaData pmd : parameters)
+      {
+         // then just put the others in the free places
+         if ((pmd instanceof AbstractConstructorArg && ((AbstractConstructorArg)pmd).isExplicitIndex() == false))
+         {
+            while(pmds[index] != null) index++;
+            pmds[index] = pmd;
+         }
+         index++;
+      }
+      // todo clone md
+      parameters.clear();
+      parameters.addAll(Arrays.asList(pmds));
    }
 
 }

Added: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml	2006-12-18 13:10:19 UTC (rev 59074)
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<beans xmlns="urn:jboss:spring-beans:2.0">
+
+   <bean id="testBean" class="org.jboss.test.spring.support.SimpleBean">
+      <constructor-arg index="2">
+         <value>SpringBean</value>
+      </constructor-arg>
+      <constructor-arg index="0">
+         <value>1</value>
+      </constructor-arg>
+      <constructor-arg index="1">
+         <value>3.1415</value>
+      </constructor-arg>
+      <!--
+         <property name="mylist">
+            <list value-type="java.lang.String">
+               <value>onel</value>
+               <value>twol</value>
+               <value>threel</value>
+            </list>
+         </property>
+         <property name="myset">
+            <set value-type="java.lang.String">
+               <value>ones</value>
+               <value>twos</value>
+               <value>ones</value>
+            </set>
+         </property>
+         <property name="map">
+            <entry>
+               <key>
+                  <value>key</value>
+               </key>
+               <value>myvalue</value>
+            </entry>
+         </property>
+      -->
+   </bean>
+
+</beans>
\ No newline at end of file

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-18 13:10:19 UTC (rev 59074)
@@ -79,4 +79,16 @@
       this.mymap = mymap;
    }
 
+   public String toString()
+   {
+      StringBuilder builder = new StringBuilder();
+      builder.append(x).append(",");
+      builder.append(y).append(",");
+      builder.append(s).append(",");
+      builder.append(mylist).append(",");
+      builder.append(myset).append(",");
+      builder.append(mymap);
+      return builder.toString();
+   }
+
 }

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 13:10:19 UTC (rev 59074)
@@ -0,0 +1,56 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import junit.framework.Test;
+import org.jboss.test.spring.support.SimpleBean;
+import org.jboss.dependency.spi.ControllerState;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class InstantiateSpringTestCase extends TempSpringMicrocontainerTest
+{
+
+   public InstantiateSpringTestCase(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test
+    *
+    * @return the test
+    */
+   public static Test suite()
+   {
+      return suite(InstantiateSpringTestCase.class);
+   }
+
+   public void testDescribe() throws Exception
+   {
+      SimpleBean testBean = (SimpleBean) getBean("testBean", ControllerState.INSTANTIATED);
+      // todo - test instantiation
+      System.out.println("testBean = " + testBean);
+   }
+
+}

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-18 13:10:19 UTC (rev 59074)
@@ -41,6 +41,7 @@
       TestSuite suite = new TestSuite("Spring Tests");
 
       suite.addTest(DescribeSpringTestCase.suite());
+      suite.addTest(InstantiateSpringTestCase.suite());
 
       return suite;
    }

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java	2006-12-18 13:10:19 UTC (rev 59074)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import org.jboss.test.AbstractTestDelegate;
+import org.jboss.test.kernel.junit.MicrocontainerTest;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class TempSpringMicrocontainerTest extends MicrocontainerTest
+{
+
+   public TempSpringMicrocontainerTest(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test delegate
+    *
+    * @param clazz the class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      return new TempSpringMicrocontainerTestDelegate(clazz);
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTestDelegate.java	2006-12-18 11:13:07 UTC (rev 59073)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTestDelegate.java	2006-12-18 13:10:19 UTC (rev 59074)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import org.jboss.spring.deployment.xml.SpringSchemaInitializer;
+import org.jboss.test.kernel.junit.MicrocontainerTestDelegate;
+import org.jboss.xb.binding.sunday.unmarshalling.DefaultSchemaResolver;
+import org.jboss.xb.binding.sunday.unmarshalling.SingletonSchemaResolverFactory;
+import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingResolver;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class TempSpringMicrocontainerTestDelegate extends MicrocontainerTestDelegate
+{
+
+   public TempSpringMicrocontainerTestDelegate(Class clazz) throws Exception
+   {
+      super(clazz);
+   }
+
+   public void setUp() throws Exception
+   {
+      SchemaBindingResolver resolver = SingletonSchemaResolverFactory.getInstance().getSchemaBindingResolver();
+      DefaultSchemaResolver defaultSchemaResolver = (DefaultSchemaResolver) resolver;
+      defaultSchemaResolver.addSchemaInitializer("urn:jboss:spring-beans:2.0", new SpringSchemaInitializer());
+      defaultSchemaResolver.addSchemaLocation("urn:jboss:spring-beans:2.0", "mc-spring-beans_2_0.xsd");
+      super.setUp();
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 08:19:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 08:19:06 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1810 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GwIOY-0000vL-H6@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-18 08:19:04 -0500 (Mon, 18 Dec 2006)
New Revision: 1810

Modified:
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
Log:
Fixed failing MessageConsumerTest



Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-18 03:53:08 UTC (rev 1809)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-18 13:19:04 UTC (rev 1810)
@@ -129,9 +129,7 @@
          // We cancel any client ack or transactional, we do this explicitly so we can pass the updated
          // delivery count information from client to server. We could just do this on the server but
          // we would lose delivery count info.
-         
-         //CLIENT_ACKNOWLEDGE cannot be used with MDBs so is always safe to cancel on this session
-         
+                  
          List cancels = new ArrayList();
          
          for(Iterator i = state.getClientAckList().iterator(); i.hasNext(); )
@@ -141,6 +139,13 @@
             cancels.add(cancel);
          }
          
+         if (!cancels.isEmpty())
+         {
+            //CLIENT_ACKNOWLEDGE cannot be used with MDBs so is always safe to cancel on this session
+            
+            del.cancelDeliveries(cancels);            
+         }
+         
          state.getClientAckList().clear();
       }
       



From dimitris.andreadis at jboss.com  Mon Dec 18 08:21:31 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 08:21:31 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/remoting/1.4.5.GA  ...
Message-ID: <E1GwIQt-0000yo-1Q@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 08:21:31

  Modified:    jboss/remoting/1.4.5.GA  component-info.xml
  Log:
  mark compatible with jboss serialization 1.0.x
  
  Revision  Changes    Path
  1.2       +2 -0      repository.jboss.com/jboss/remoting/1.4.5.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/remoting/1.4.5.GA/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	27 Sep 2006 17:59:36 -0000	1.1
  +++ component-info.xml	18 Dec 2006 13:21:31 -0000	1.2
  @@ -14,6 +14,8 @@
         <import componentref="jboss/serialization">
         	<compatible version="1.0.0.GA"/>
         	<compatible version="1.0.1.GA"/>
  +      	<compatible version="1.0.2.GA"/>
  +      	<compatible version="1.0.3.GA"/>        
         </import>
   
         <export>
  
  
  


From dimitris.andreadis at jboss.com  Mon Dec 18 08:21:43 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 08:21:43 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/remoting/1.4.4.GA  ...
Message-ID: <E1GwIR5-0000zW-K8@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 08:21:43

  Modified:    jboss/remoting/1.4.4.GA  component-info.xml
  Log:
  mark compatible with jboss serialization 1.0.x
  
  Revision  Changes    Path
  1.3       +1 -1      repository.jboss.com/jboss/remoting/1.4.4.GA/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/remoting/1.4.4.GA/component-info.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- component-info.xml	21 Sep 2006 21:03:03 -0000	1.2
  +++ component-info.xml	18 Dec 2006 13:21:43 -0000	1.3
  @@ -15,7 +15,7 @@
         	<compatible version="1.0.0.GA"/>
         	<compatible version="1.0.1.GA"/>
         	<compatible version="1.0.2.GA"/>
  -      	<compatible version="1.0.2.GA"/>
  +      	<compatible version="1.0.3.GA"/>
         </import>
   
         <export>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 08:30:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 08:30:36 -0500
Subject: [jboss-cvs] JBossAS SVN: r59075 -
	projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test
Message-ID: <E1GwIZg-00018r-AW@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 08:30:34 -0500 (Mon, 18 Dec 2006)
New Revision: 59075

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
Log:
Describe test - working for list, set.

Modified: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-18 13:10:19 UTC (rev 59074)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-18 13:30:34 UTC (rev 59075)
@@ -18,6 +18,7 @@
          <value>ones</value>
       </set>
    </property>
+<!--
    <property name="map">
       <entry>
          <key>
@@ -26,4 +27,5 @@
          <value>myvalue</value>
       </entry>
    </property>
+-->
 </bean>



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 08:46:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 08:46:20 -0500
Subject: [jboss-cvs] JBossAS SVN: r59076 - in
	projects/microcontainer/trunk/spring-int/src:
	resources/xml-test/org/jboss/test/spring/test
	tests/org/jboss/test/spring/support tests/org/jboss/test/spring/test
Message-ID: <E1GwIou-0001PZ-3C@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 08:46:12 -0500 (Mon, 18 Dec 2006)
New Revision: 59076

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
Log:
Test - working for list, set.
Not yet for Map - see DescribeSpringTC which now fails differently - after XB snapshot update.

Modified: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml	2006-12-18 13:30:34 UTC (rev 59075)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml	2006-12-18 13:46:12 UTC (rev 59076)
@@ -10,9 +10,8 @@
          <value>1</value>
       </constructor-arg>
       <constructor-arg index="1">
-         <value>3.1415</value>
+         <value>3.14159</value>
       </constructor-arg>
-      <!--
          <property name="mylist">
             <list value-type="java.lang.String">
                <value>onel</value>
@@ -27,10 +26,11 @@
                <value>ones</value>
             </set>
          </property>
+      <!--
          <property name="map">
             <entry>
                <key>
-                  <value>key</value>
+                  <value>test_key</value>
                </key>
                <value>myvalue</value>
             </entry>

Modified: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-18 13:30:34 UTC (rev 59075)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/TestDescribe.xml	2006-12-18 13:46:12 UTC (rev 59076)
@@ -3,7 +3,7 @@
 <bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean" >
    <constructor-arg index="2"><value>SpringBean</value></constructor-arg>
    <constructor-arg index="0"><value>1</value></constructor-arg>
-   <constructor-arg index="1"><value>3.1415</value></constructor-arg>
+   <constructor-arg index="1"><value>3.14159</value></constructor-arg>
    <property name="mylist">
       <list value-type="java.lang.String">
          <value>onel</value>
@@ -18,14 +18,12 @@
          <value>ones</value>
       </set>
    </property>
-<!--
    <property name="map">
       <entry>
          <key>
-            <value>key</value>
+            <value>test_key</value>
          </key>
          <value>myvalue</value>
       </entry>
    </property>
--->
 </bean>

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-18 13:30:34 UTC (rev 59075)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-18 13:46:12 UTC (rev 59076)
@@ -49,6 +49,21 @@
       this.s = s;
    }
 
+   public int getX()
+   {
+      return x;
+   }
+
+   public double getY()
+   {
+      return y;
+   }
+
+   public String getS()
+   {
+      return s;
+   }
+
    public List getMylist()
    {
       return mylist;

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 13:30:34 UTC (rev 59075)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 13:46:12 UTC (rev 59076)
@@ -49,8 +49,16 @@
    public void testDescribe() throws Exception
    {
       SimpleBean testBean = (SimpleBean) getBean("testBean", ControllerState.INSTANTIATED);
-      // todo - test instantiation
-      System.out.println("testBean = " + testBean);
+      assertEquals(testBean.getX(), 1);
+      assertEquals(testBean.getY(), 3.14159);
+      assertEquals(testBean.getS(), "SpringBean");
+      // collections
+      assertFalse(testBean.getMylist().isEmpty());
+      assertEquals(testBean.getMylist().size(), 3);
+      assertFalse(testBean.getMyset().isEmpty());
+      assertEquals(testBean.getMyset().size(),2);
+//      assertFalse(testBean.getMymap().values().isEmpty());
+//      assertEquals(testBean.getMymap().values().size(), 1);
    }
 
 }



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 09:05:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 09:05:11 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59077 - branches/Branch_4_2/build
Message-ID: <E1GwJ79-0001v0-Oc@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-18 09:05:09 -0500 (Mon, 18 Dec 2006)
New Revision: 59077

Modified:
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
JBAS-3272, upgrade to jboss remoting 1.4.5

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-18 13:46:12 UTC (rev 59076)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-18 14:05:09 UTC (rev 59077)
@@ -97,7 +97,7 @@
       <componentref name="jboss/jboss-ws4ee" version="4.0.4.SP1"/>
       <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
       <componentref name="jboss/microcontainer" version="1.0.2"/>
-      <componentref name="jboss/remoting" version="1.4.3.GA"/>
+      <componentref name="jboss/remoting" version="1.4.5.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
       <componentref name="jfreechart" version="0.9.20"/>
       <componentref name="jgroups" version="2.4"/>



From dimitris.andreadis at jboss.com  Mon Dec 18 09:10:39 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:10:39 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging-api/1.1 - New
	directory ...
Message-ID: <E1GwJCR-00022O-P6@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:10:39

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/apache-logging-api/1.1 added to the repository


From dimitris.andreadis at jboss.com  Mon Dec 18 09:10:52 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:10:52 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging-api/1.1/lib - New
	directory ...
Message-ID: <E1GwJCe-00022q-QA@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:10:52

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/apache-logging-api/1.1/lib added to the repository


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 09:11:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 09:11:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r59078 - in
	projects/ejb3/trunk/injection/src: main/java/org/jboss/injection
	main/java/org/jboss/injection/aop test/java/org/jboss/injection/test
	test/java/org/jboss/injection/test/annotated
	test/java/org/jboss/injection/test/annotated/unit
	test/java/org/jboss/injection/test/appclient
	test/java/org/jboss/injection/test/appclient/unit
	test/java/org/jboss/injection/test/common
	test/java/org/jboss/injection/test/programatically
	test/java/org/jboss/injection/test/programatically/unit
	test/java/org/jboss/injection/test/simple
	test/java/org/jboss/injection/test/simple/unit
Message-ID: <E1GwJD7-00023a-8M@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-18 09:10:38 -0500 (Mon, 18 Dec 2006)
New Revision: 59078

Added:
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedMethodFinder.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/HelloWorldClient.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/unit/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/unit/AppClientTestCase.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/common/
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/common/Counter.java
Removed:
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java
Modified:
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java
   projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java
   projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java
Log:
app client unit test

Added: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedMethodFinder.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedMethodFinder.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedMethodFinder.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -0,0 +1,65 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection;
+
+import java.lang.annotation.Annotation;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Collection;
+
+/**
+ * Finds all methods annotation with a certain annotation.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class AnnotatedMethodFinder<T extends Annotation> implements Processor<Class<?>, Collection<Method>>
+{
+   private Class<T> annotationClass;
+   
+   public AnnotatedMethodFinder(Class<T> annotationClass)
+   {
+      assert annotationClass != null : "annotationClass is null";
+      
+      this.annotationClass = annotationClass;
+   }
+   
+   public Collection<Method> process(Class<?> cls)
+   {
+      Collection<Method> list = new ArrayList<Method>();
+      if(cls == null) return list;
+      
+      Method methods[] = cls.getDeclaredMethods();
+      for(Method method : methods)
+      {
+         T annotation = method.getAnnotation(annotationClass);
+         if(annotation != null)
+         {
+            list.add(method);
+         }
+      }
+      
+      list.addAll(process(cls.getSuperclass()));
+      
+      return list;
+   }
+}

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/AnnotatedPropertyProcessor.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -30,25 +30,26 @@
  *
  * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
  * @version $Revision: $
- * @deprecated NYI
  */
-public class AnnotatedPropertyProcessor<FactoryType extends InjectorFactory, AnnotationType extends Annotation> extends AbstractProcessor<BeanProperty>
+public class AnnotatedPropertyProcessor<FactoryType extends InjectorFactory<AnnotationType>, AnnotationType extends Annotation> extends AbstractProcessor<BeanProperty>
 {
    private FactoryType factory;
+   private Class<AnnotationType> annotationClass;
    
-   protected AnnotatedPropertyProcessor(FactoryType factory)
+   protected AnnotatedPropertyProcessor(FactoryType factory, Class<AnnotationType> annotationClass)
    {
       assert factory != null;
+      assert annotationClass != null;
       
       this.factory = factory;
+      this.annotationClass = annotationClass;
    }
    
    public Injector processOne(BeanProperty property)
    {
-      throw new RuntimeException("NYI");
-//      AnnotationType resource = property.getAnnotation(AnnotationType);
-//      if(resource == null) return null;
-//      
-//      return factory.create(property, resource);
+      AnnotationType resource = property.getAnnotation(annotationClass);
+      if(resource == null) return null;
+      
+      return factory.create(property, resource);
    }
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/ClassPropertyProcessor.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -57,6 +57,10 @@
     */
    public Collection<Injector> process(Class<?> cls)
    {
+      // TODO: I don't like that BeanProperty is first instantiated and then checked
+      // for annotations, it's slower.
+      // Maybe we should first check the AccessibleObject and then create a BeanProperty.
+      
       Collection<Injector> list = new ArrayList<Injector>();
       
       Field fields[] = cls.getDeclaredFields();
@@ -69,6 +73,8 @@
       Method methods[] = cls.getDeclaredMethods();
       for(Method method : methods)
       {
+         // TODO: this I don't like. I want to scan for annotation first and then verify the method,
+         // so I can properly inform users of errors.
          if(MethodBeanProperty.isValid(method))
          {
             BeanProperty property = new MethodBeanProperty(method);

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/InjectorProcessor.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -23,6 +23,7 @@
 
 import java.lang.reflect.InvocationTargetException;
 import java.lang.reflect.Method;
+import java.lang.reflect.Modifier;
 import java.util.Collection;
 
 /**
@@ -33,21 +34,33 @@
  */
 public class InjectorProcessor
 {
-   public static void process(Object instance, Collection<Injector> injectors, Collection<Method> postConstructs)
+   public static void destroy(Collection<Method> preDestroys)
    {
-      assert instance != null;
-      assert injectors != null;
-      assert postConstructs != null : "postConstructs is null";
+      destroy(null, preDestroys);
+   }
+   
+   /**
+    * Run the pre-destroys on an instance.
+    * 
+    * @param instance       either an instance or null for static pre-destroys
+    * @param preDestroys
+    */
+   public static void destroy(Object instance, Collection<Method> preDestroys)
+   {
+      assert preDestroys != null : "preDestroys is null";
       
-      for(Injector injector : injectors)
+      for(Method method : preDestroys)
       {
-         injector.inject(instance);
+         invoke(instance, method);
       }
-      
-      Class<?> cls = instance.getClass();
-      for(Method method : postConstructs)
+   }
+   
+   private static void invoke(Object instance, Method method)
+   {
+      Object obj = null;
+      if(instance != null)
       {
-         Object obj;
+         Class<?> cls = instance.getClass();
          if(cls.isAssignableFrom(method.getDeclaringClass()))
          {
             obj = instance;
@@ -68,26 +81,63 @@
                throw new RuntimeException(e);
             }
          }
-         Object args[] = null;
-         method.setAccessible(true);
-         try
-         {
-            method.invoke(obj, args);
-         }
-         catch (IllegalAccessException e)
-         {
-            // should not happen
-            throw new RuntimeException(e);
-         }
-         catch (InvocationTargetException e)
-         {
-            Throwable t = e.getCause();
-            if(t instanceof Error)
-               throw (Error) t;
-            if(t instanceof RuntimeException)
-               throw (RuntimeException) t;
-            throw new RuntimeException(t);
-         }
       }
+      if(obj == null && !Modifier.isStatic(method.getModifiers()))
+      {
+         throw new IllegalArgumentException("Can't run non-static " + method + ", there is no instance");
+      }
+      Object args[] = null;
+      method.setAccessible(true);
+      try
+      {
+         method.invoke(obj, args);
+      }
+      catch (IllegalAccessException e)
+      {
+         // should not happen
+         throw new RuntimeException(e);
+      }
+      catch (InvocationTargetException e)
+      {
+         Throwable t = e.getCause();
+         if(t instanceof Error)
+            throw (Error) t;
+         if(t instanceof RuntimeException)
+            throw (RuntimeException) t;
+         throw new RuntimeException(t);
+      }
    }
+   
+   /**
+    * Convinience method for static injection.
+    * 
+    * @param injectors
+    * @param postConstructs
+    */
+   public static void process(Collection<Injector> injectors, Collection<Method> postConstructs)
+   {
+      process(null, injectors, postConstructs);
+   }
+   
+   /**
+    * 
+    * @param instance       either an object or null for static injection
+    * @param injectors
+    * @param postConstructs
+    */
+   public static void process(Object instance, Collection<Injector> injectors, Collection<Method> postConstructs)
+   {
+      assert injectors != null : "injectors is null";
+      assert postConstructs != null : "postConstructs is null";
+      
+      for(Injector injector : injectors)
+      {
+         injector.inject(instance);
+      }
+      
+      for(Method method : postConstructs)
+      {
+         invoke(instance, method);
+      }
+   }
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/PostConstructProcessor.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -21,10 +21,6 @@
  */
 package org.jboss.injection;
 
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.Collection;
-
 import javax.annotation.PostConstruct;
 
 /**
@@ -33,25 +29,10 @@
  * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
  * @version $Revision: $
  */
-public class PostConstructProcessor implements Processor<Class<?>, Collection<Method>>
+public class PostConstructProcessor extends AnnotatedMethodFinder<PostConstruct>
 {
-   public Collection<Method> process(Class<?> cls)
+   public PostConstructProcessor()
    {
-      Collection<Method> list = new ArrayList<Method>();
-      if(cls == null) return list;
-      
-      Method methods[] = cls.getDeclaredMethods();
-      for(Method method : methods)
-      {
-         PostConstruct pc = method.getAnnotation(PostConstruct.class);
-         if(pc != null)
-         {
-            list.add(method);
-         }
-      }
-      
-      list.addAll(process(cls.getSuperclass()));
-      
-      return list;
+      super(PostConstruct.class);
    }
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/Processor.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -23,11 +23,20 @@
 
 /**
  * Processes an object to produce something.
+ * 
+ * This is an extreme abstraction of a processor which produces something.
+ * T1 is the subject type, T2 is the resultant type.
  *
  * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
  * @version $Revision: $
  */
 public interface Processor<T1, T2>
 {
-   T2 process(T1 t);
+   /**
+    * Process an object to produce something.
+    * 
+    * @param subject    the object on which the processing takes place
+    * @return           the result
+    */
+   T2 process(T1 subject);
 }

Modified: projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java
===================================================================
--- projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/main/java/org/jboss/injection/aop/ConstructorInterceptor.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -23,7 +23,6 @@
 
 import org.jboss.aop.advice.Interceptor;
 import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.injection.InjectorProcessor;
 
 /**
  * Intercepts construction of new objects and fires up injection.

Deleted: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/Counter.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.injection.test.annotated;
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class Counter
-{
-   public static int postConstructs;
-   public static int preDestroys;
-   
-   public static void reset()
-   {
-      postConstructs = 0;
-      preDestroys = 0;
-   }
-}

Modified: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/InjectedBean.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -25,6 +25,8 @@
 import javax.annotation.PreDestroy;
 import javax.annotation.Resource;
 
+import org.jboss.injection.test.common.Counter;
+
 /**
  * Do injection based on annotation.
  *

Modified: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/annotated/unit/AnnotatedTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -37,9 +37,9 @@
 import org.jboss.injection.PostConstructProcessor;
 import org.jboss.injection.Processor;
 import org.jboss.injection.ResourceClassProcessor;
-import org.jboss.injection.test.annotated.Counter;
 import org.jboss.injection.test.annotated.InjectedBean;
 import org.jboss.injection.test.annotated.SimplePropertyProcessor;
+import org.jboss.injection.test.common.Counter;
 
 /**
  * Comment

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/HelloWorldClient.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/HelloWorldClient.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/HelloWorldClient.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -0,0 +1,61 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.appclient;
+
+import javax.annotation.PostConstruct;
+import javax.annotation.PreDestroy;
+import javax.annotation.Resource;
+
+import org.jboss.injection.test.common.Counter;
+
+/**
+ * The app client differs from other injections, that all
+ * is static. And thus usable from the main method.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class HelloWorldClient
+{
+   @Resource
+   private static String value;
+   
+   public static void check()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+   }
+   
+   @PostConstruct
+   public static void postConstruct()
+   {
+      if(value == null)
+         throw new IllegalStateException("value must not be null");
+      Counter.postConstructs++;
+   }
+   
+   @PreDestroy
+   public static void preDestroy()
+   {
+      Counter.preDestroys++;
+   }
+}

Added: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/unit/AppClientTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/unit/AppClientTestCase.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/appclient/unit/AppClientTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -0,0 +1,119 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.appclient.unit;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
+
+import javax.annotation.PreDestroy;
+
+import junit.framework.TestCase;
+
+import org.jboss.injection.AnnotatedMethodFinder;
+import org.jboss.injection.Injection;
+import org.jboss.injection.Injector;
+import org.jboss.injection.InjectorProcessor;
+import org.jboss.injection.MapInjectorFactory;
+import org.jboss.injection.PostConstructProcessor;
+import org.jboss.injection.Processor;
+import org.jboss.injection.ResourceClassProcessor;
+import org.jboss.injection.test.appclient.HelloWorldClient;
+import org.jboss.injection.test.common.Counter;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class AppClientTestCase extends TestCase
+{
+   public void test1() throws Exception
+   {
+      Counter.reset();
+      
+      // There are multiple ways to initialize the injectors, annotation
+      // is one of them.
+      
+      //
+      // the environment to use
+      //
+      
+      Map<String, Object> env = new HashMap<String, Object>();
+      env.put(HelloWorldClient.class.getName() + "/value", "Hello world");
+      
+      //
+      // the setup of injectors
+      //
+      
+      // TODO: weird, shouldn't this work?
+      //Collection<InjectionProcessor<Class<?>>> handlers = new ArrayList<InjectionProcessor<Class<?>>>();
+      Collection<Processor<Class<?>, Collection<Injector>>> handlers = new ArrayList<Processor<Class<?>, Collection<Injector>>>();
+      handlers.add(new ResourceClassProcessor(new MapInjectorFactory(env)));
+      Collection<Injector> injectors = Injection.doIt(HelloWorldClient.class, handlers);
+      
+      assertEquals("Wrong number of injectors", 1, injectors.size());
+      
+      Collection<Processor<Class<?>, Collection<Method>>> postConstructProcessors = new ArrayList<Processor<Class<?>, Collection<Method>>>();
+      postConstructProcessors.add(new PostConstructProcessor());
+      Collection<Method> postConstructs = Injection.doIt(HelloWorldClient.class, postConstructProcessors);
+      
+      assertEquals("Wrong number of post-constructs", 1, postConstructs.size());
+      
+      Collection<Processor<Class<?>, Collection<Method>>> preDestroyProcessors = new ArrayList<Processor<Class<?>, Collection<Method>>>();
+      preDestroyProcessors.add(new AnnotatedMethodFinder<PreDestroy>(PreDestroy.class));
+      Collection<Method> preDestroys = Injection.doIt(HelloWorldClient.class, preDestroyProcessors);
+      
+      assertEquals("Wrong number of pre-destroys", 1, preDestroys.size());
+      
+      //
+      // the target
+      //
+      
+      // With app client there is no target instance.
+      
+      //
+      // the injection
+      //
+      
+      InjectorProcessor.process(injectors, postConstructs);
+      
+      //
+      // do some business
+      //
+      
+      HelloWorldClient.check();
+      
+      assertEquals("postConstruct should have been called once", 1, Counter.postConstructs);
+      
+      //
+      // destroy phase
+      //
+      
+      InjectorProcessor.destroy(preDestroys);
+      
+      assertEquals("preDestroy should have been called once", 1, Counter.preDestroys);
+   }
+}

Copied: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/common/Counter.java (from rev 59010, projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java)
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java	2006-12-13 11:12:42 UTC (rev 59010)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/common/Counter.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -0,0 +1,40 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.injection.test.common;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class Counter
+{
+   public static int postConstructs;
+   public static int preDestroys;
+   
+   public static void reset()
+   {
+      postConstructs = 0;
+      preDestroys = 0;
+   }
+}

Deleted: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/Counter.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.injection.test.programatically;
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class Counter
-{
-   public static int postConstructs;
-   public static int preDestroys;
-   
-   public static void reset()
-   {
-      postConstructs = 0;
-      preDestroys = 0;
-   }
-}

Modified: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/InjectedBean.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -21,6 +21,8 @@
  */
 package org.jboss.injection.test.programatically;
 
+import org.jboss.injection.test.common.Counter;
+
 /**
  * Comment
  *

Modified: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/programatically/unit/InjectorProcessorTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -32,7 +32,7 @@
 import org.jboss.injection.SimpleValueInjector;
 import org.jboss.injection.lang.reflect.BeanProperty;
 import org.jboss.injection.lang.reflect.FieldBeanProperty;
-import org.jboss.injection.test.programatically.Counter;
+import org.jboss.injection.test.common.Counter;
 import org.jboss.injection.test.programatically.InjectedBean;
 
 /**

Deleted: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/Counter.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -1,40 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.injection.test.simple;
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class Counter
-{
-   public static int postConstructs;
-   public static int preDestroys;
-   
-   public static void reset()
-   {
-      postConstructs = 0;
-      preDestroys = 0;
-   }
-}

Modified: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/InjectedBean.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -21,6 +21,8 @@
  */
 package org.jboss.injection.test.simple;
 
+import org.jboss.injection.test.common.Counter;
+
 /**
  * Comment
  *

Modified: projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java
===================================================================
--- projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java	2006-12-18 14:05:09 UTC (rev 59077)
+++ projects/ejb3/trunk/injection/src/test/java/org/jboss/injection/test/simple/unit/SimpleTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
@@ -28,7 +28,7 @@
 import junit.framework.TestSuite;
 
 import org.jboss.aop.AspectXmlLoader;
-import org.jboss.injection.test.simple.Counter;
+import org.jboss.injection.test.common.Counter;
 import org.jboss.injection.test.simple.InjectedBean;
 
 /**



From dimitris.andreadis at jboss.com  Mon Dec 18 09:11:40 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:11:40 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging-api/1.1  ...
Message-ID: <E1GwJDQ-00024K-4s@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:11:40

  Added:       apache-logging-api/1.1  component-info.xml
  Log:
  add apache commons-logging-api 1.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 14:11:40;  author: dimitris;  state: Exp;repository.jboss.com/apache-logging-api/1.1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="apache-commons-logging-api">
     <component id="apache-logging-api"
                licenseType="apache-2.0"
                version="1.1"
                projectHome="http://jakarta.apache.org/commons/logging/">
        <artifact id="commons-logging-api.jar"/>
        <export>
           <include input="commons-logging-api.jar"/>
        </export>
     </component>
  
  </project>
  
  


From dimitris.andreadis at jboss.com  Mon Dec 18 09:11:40 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:11:40 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging-api/1.1/lib  ...
Message-ID: <E1GwJDQ-00024Q-8D@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:11:40

  Added:       apache-logging-api/1.1/lib  commons-logging-api.jar
  Log:
  add apache commons-logging-api 1.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 14:11:40;  author: dimitris;  state: Exp;repository.jboss.com/apache-logging-api/1.1/lib/commons-logging-api.jar
  
  	<<Binary file>>
  
  


From dimitris.andreadis at jboss.com  Mon Dec 18 09:14:40 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:14:40 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging/1.1 - New directory
	...
Message-ID: <E1GwJGK-00028o-8z@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:14:40

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/apache-logging/1.1 added to the repository


From dimitris.andreadis at jboss.com  Mon Dec 18 09:14:52 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:14:52 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging/1.1/lib - New
	directory ...
Message-ID: <E1GwJGW-000292-LX@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:14:52

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/apache-logging/1.1/lib added to the repository


From dimitris.andreadis at jboss.com  Mon Dec 18 09:15:14 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:15:14 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging/1.1  ...
Message-ID: <E1GwJGs-0002Af-Ln@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:15:14

  Added:       apache-logging/1.1  component-info.xml
  Log:
  add apache commons-logging 1.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 14:15:14;  author: dimitris;  state: Exp;repository.jboss.com/apache-logging/1.1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="apache-commons-logging">
     <component id="apache-logging"
                licenseType="apache-2.0"
                version="1.1"
                projectHome="http://jakarta.apache.org/commons/logging/"
           description="Yet another logging api">
        <artifact id="commons-logging.jar"/>
        <export>
           <include input="commons-logging.jar"/>
        </export>
     </component>
  
  </project>
  
  


From dimitris.andreadis at jboss.com  Mon Dec 18 09:15:14 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 09:15:14 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-logging/1.1/lib  ...
Message-ID: <E1GwJGs-0002Al-P7@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 09:15:14

  Added:       apache-logging/1.1/lib  commons-logging.jar
  Log:
  add apache commons-logging 1.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 14:15:14;  author: dimitris;  state: Exp;repository.jboss.com/apache-logging/1.1/lib/commons-logging.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 09:57:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 09:57:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r59079 - in
	projects/microcontainer/trunk/spring-int/src:
	resources/xml-test/org/jboss/test/spring/test
	tests/org/jboss/test/spring/support tests/org/jboss/test/spring/test
Message-ID: <E1GwJwA-0002oG-Sy@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 09:57:41 -0500 (Mon, 18 Dec 2006)
New Revision: 59079

Added:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixed2TestCase.xml
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixedTestCase.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/OldBean.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixed2TestCase.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixedTestCase.java
Modified:
   projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
Log:
Added mixed test - injection of Spring beans into MC's, and vice versa.

Added: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixed2TestCase.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixed2TestCase.xml	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixed2TestCase.xml	2006-12-18 14:57:41 UTC (rev 59079)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<beans xmlns="urn:jboss:spring-beans:2.0">
+
+   <bean id="testBean" class="org.jboss.test.spring.support.SimpleBean">
+      <property name="refBean"><ref bean="oldBean"/></property>
+   </bean>
+
+   <bean xmlns="urn:jboss:bean-deployer:2.0" name="oldBean" class="org.jboss.test.spring.support.OldBean">
+      <property name="javaBeanString">JavaBean</property>
+   </bean>
+
+</beans>
\ No newline at end of file

Added: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixedTestCase.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixedTestCase.xml	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateMixedTestCase.xml	2006-12-18 14:57:41 UTC (rev 59079)
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+
+   <bean name="oldBean" class="org.jboss.test.spring.support.OldBean">
+      <property name="testBean">
+         <inject/>
+      </property>
+   </bean>
+
+   <bean xmlns="urn:jboss:spring-beans:2.0" id="testBean" class="org.jboss.test.spring.support.SimpleBean">
+      <property name="mylist">
+         <list value-type="java.lang.String">
+            <value>onel</value>
+            <value>twol</value>
+            <value>threel</value>
+         </list>
+      </property>
+   </bean>
+
+</deployment>
\ No newline at end of file

Modified: projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/resources/xml-test/org/jboss/test/spring/test/InstantiateSpringTestCase.xml	2006-12-18 14:57:41 UTC (rev 59079)
@@ -12,20 +12,20 @@
       <constructor-arg index="1">
          <value>3.14159</value>
       </constructor-arg>
-         <property name="mylist">
-            <list value-type="java.lang.String">
-               <value>onel</value>
-               <value>twol</value>
-               <value>threel</value>
-            </list>
-         </property>
-         <property name="myset">
-            <set value-type="java.lang.String">
-               <value>ones</value>
-               <value>twos</value>
-               <value>ones</value>
-            </set>
-         </property>
+      <property name="mylist">
+         <list value-type="java.lang.String">
+            <value>onel</value>
+            <value>twol</value>
+            <value>threel</value>
+         </list>
+      </property>
+      <property name="myset">
+         <set value-type="java.lang.String">
+            <value>ones</value>
+            <value>twos</value>
+            <value>ones</value>
+         </set>
+      </property>
       <!--
          <property name="map">
             <entry>

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/OldBean.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/OldBean.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/OldBean.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -0,0 +1,53 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.support;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class OldBean
+{
+
+   private SimpleBean testBean;
+   private String javaBeanString;
+
+   public SimpleBean getTestBean()
+   {
+      return testBean;
+   }
+
+   public void setTestBean(SimpleBean testBean)
+   {
+      this.testBean = testBean;
+   }
+
+   public String getJavaBeanString()
+   {
+      return javaBeanString;
+   }
+
+   public void setJavaBeanString(String javaBeanString)
+   {
+      this.javaBeanString = javaBeanString;
+   }
+   
+}

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/support/SimpleBean.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -37,6 +37,7 @@
    private List mylist;
    private Set myset;
    private Map mymap;
+   private OldBean refBean;
 
    public SimpleBean()
    {
@@ -94,6 +95,16 @@
       this.mymap = mymap;
    }
 
+   public OldBean getRefBean()
+   {
+      return refBean;
+   }
+
+   public void setRefBean(OldBean refBean)
+   {
+      this.refBean = refBean;
+   }
+
    public String toString()
    {
       StringBuilder builder = new StringBuilder();
@@ -103,6 +114,7 @@
       builder.append(mylist).append(",");
       builder.append(myset).append(",");
       builder.append(mymap);
+      builder.append(refBean);
       return builder.toString();
    }
 

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/DescribeSpringTestCase.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -47,16 +47,9 @@
 
    public void testDescribe() throws Exception
    {
-      try
-      {
-         BeanMetaData simpleBeanMD = unmarshal("TestDescribe.xml", BeanMetaData.class);
-         // todo - test descriptions
-         System.out.println("simpleBean = " + simpleBeanMD);
-      }
-      catch (Exception e)
-      {
-         System.out.println("not yet fully implemented = " + e);
-      }
+      BeanMetaData simpleBeanMD = unmarshal("TestDescribe.xml", BeanMetaData.class);
+      // todo - test descriptions
+      System.out.println("simpleBean = " + simpleBeanMD);
    }
 
 }

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixed2TestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixed2TestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixed2TestCase.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -0,0 +1,62 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import junit.framework.Test;
+import org.jboss.test.spring.support.OldBean;
+import org.jboss.test.spring.support.SimpleBean;
+import org.jboss.dependency.spi.ControllerState;
+
+/**
+ * Testing how MC beans can be mixed (injected, ...) with Spring beans.
+ *
+ * @see InstantiateMixedTestCase
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class InstantiateMixed2TestCase extends TempSpringMicrocontainerTest
+{
+
+   public InstantiateMixed2TestCase(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test
+    *
+    * @return the test
+    */
+   public static Test suite()
+   {
+      return suite(InstantiateMixed2TestCase.class);
+   }
+
+   public void testInjection() throws Exception
+   {
+      SimpleBean simpleBean = (SimpleBean) getBean("testBean", ControllerState.INSTANTIATED);
+      assertNotNull(simpleBean);
+      OldBean oldBean = simpleBean.getRefBean();
+      assertNotNull(oldBean);
+      assertEquals(oldBean.getJavaBeanString(), "JavaBean");
+   }
+
+}

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixedTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixedTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateMixedTestCase.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -0,0 +1,62 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import junit.framework.Test;
+import org.jboss.test.spring.support.OldBean;
+import org.jboss.test.spring.support.SimpleBean;
+
+/**
+ * Testing how Spring beans can be mixed (injected, ...) with MC beans.
+ *
+ * @see InstantiateMixed2TestCase
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class InstantiateMixedTestCase extends TempSpringMicrocontainerTest
+{
+
+   public InstantiateMixedTestCase(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test
+    *
+    * @return the test
+    */
+   public static Test suite()
+   {
+      return suite(InstantiateMixedTestCase.class);
+   }
+
+   public void testInjection() throws Exception
+   {
+      OldBean oldBean = (OldBean) getBean("oldBean");
+      assertNotNull(oldBean);
+      SimpleBean testBean = oldBean.getTestBean();
+      assertNotNull(testBean);
+      assertFalse(testBean.getMylist().isEmpty());
+      assertEquals(testBean.getMylist().size(), 3);
+   }
+
+}

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -49,6 +49,7 @@
    public void testDescribe() throws Exception
    {
       SimpleBean testBean = (SimpleBean) getBean("testBean", ControllerState.INSTANTIATED);
+      assertNotNull(testBean);
       assertEquals(testBean.getX(), 1);
       assertEquals(testBean.getY(), 3.14159);
       assertEquals(testBean.getS(), "SpringBean");

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-18 14:10:38 UTC (rev 59078)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/SpringTestSuite.java	2006-12-18 14:57:41 UTC (rev 59079)
@@ -42,6 +42,8 @@
 
       suite.addTest(DescribeSpringTestCase.suite());
       suite.addTest(InstantiateSpringTestCase.suite());
+      suite.addTest(InstantiateMixedTestCase.suite());
+      suite.addTest(InstantiateMixed2TestCase.suite());
 
       return suite;
    }



From validimir.ralev at jboss.com  Mon Dec 18 10:09:05 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:09:05 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR
	- New directory ...
Message-ID: <E1GwK6z-0003B2-BA@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:09:05

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR added to the repository


From validimir.ralev at jboss.com  Mon Dec 18 10:09:05 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:09:05 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/bin
	- New directory ...
Message-ID: <E1GwK6z-0003B6-Fl@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:09:05

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/bin added to the repository


From validimir.ralev at jboss.com  Mon Dec 18 10:09:05 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:09:05 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib
	- New directory ...
Message-ID: <E1GwK6z-0003BA-LO@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:09:05

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib added to the repository


From validimir.ralev at jboss.com  Mon Dec 18 10:09:05 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:09:05 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources
	- New directory ...
Message-ID: <E1GwK6z-0003BE-PG@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:09:05

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources added to the repository


From validimir.ralev at jboss.com  Mon Dec 18 10:10:44 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:10:44 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources
	...
Message-ID: <E1GwK8a-0003Du-4y@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:10:44

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources   
                        ejb3-clustered-sfsbcache-service.xml
                        ejb3-interceptors-aop.xml
                        ejb3-entity-cache-service.xml
  Log:
  This is a temporary manually built EJB3 CR9 PATCH1 version for use in the installer. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources/ejb3-clustered-sfsbcache-service.xml
  
  Index: ejb3-clustered-sfsbcache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
     <mbean code="org.jboss.ejb3.cache.tree.PassivationTreeCache" name="jboss.cache:service=EJB3SFSBClusteredCache">
     
        <!-- uncomment next three statements if using JGroups multiplexer,
               requires JGroups 2.3 or later, JBossCache 1.4 or later -->
        <!--
        <depends>jgroups.mux:name=Multiplexer</depends>
        <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
        <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
        -->
        
        <!--
                Node locking level : SERIALIZABLE
                                     REPEATABLE_READ (default)
                                     READ_COMMITTED
                                     READ_UNCOMMITTED
                                     NONE
        -->
        <attribute name="IsolationLevel">READ_UNCOMMITTED</attribute>
  
        <!--     Valid modes are LOCAL
                                 REPL_ASYNC
                                 REPL_SYNC
        -->
        <attribute name="CacheMode">REPL_SYNC</attribute>
  
        <attribute name="ClusterName">SFSB-Cache</attribute>
  
        <attribute name="ClusterConfig">
           <config>
              <!-- 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="45551" ip_ttl="${jgroups.mcast.ip_ttl:64}" 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"/>
           </config>
        </attribute>
  
        <!--    Number of milliseconds to wait until all responses for a
                synchronous call have been received.
        -->
        <attribute name="SyncReplTimeout">10000</attribute>
  
        <!--  Max number of milliseconds to wait for a lock acquisition -->
        <attribute name="LockAcquisitionTimeout">15000</attribute>
  
        <!--  Name of the eviction policy class. -->
        <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
        <!--  Specific eviction policy configurations. This is LRU -->
        <attribute name="EvictionPolicyConfig">
           <config>
              <attribute name="wakeUpIntervalSeconds">5</attribute>
              <name>statefulClustered</name>
              <!-- So default region would never timeout -->
              <region name="/_default_">
                 <attribute name="maxNodes">0</attribute>
                 <attribute name="timeToIdleSeconds">0</attribute>
              </region>
  
           </config>
        </attribute>
  
  
        <!-- New 1.3.x cache loader config block -->
        <!-- Note this is used for AS5.0 only -->
        <attribute name="CacheLoaderConfiguration">
            <config>
                <!-- We need to turn it on
                <passivation>false</passivation>
                -->
                <passivation>true</passivation>
                <preload>/</preload>
                <shared>false</shared>
  
                <cacheloader>
                    <class>org.jboss.cache.loader.FileCacheLoader</class>
                        <!--
                        -->
                    <properties>
                         location=${jboss.server.data.dir}${/}sfsb
                    </properties>
                    <async>false</async>
                    <fetchPersistentState>false</fetchPersistentState>
                    <ignoreModifications>false</ignoreModifications>
                </cacheloader>
  
            </config>
        </attribute>
  
     </mbean>
  
  </server>
  
  
  
  
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources/ejb3-interceptors-aop.xml
  
  Index: ejb3-interceptors-aop.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE aop PUBLIC
     "-//JBoss//DTD JBOSS AOP 1.0//EN"
     "http://www.jboss.org/aop/dtd/jboss-aop_1_0.dtd">
  
  <aop>
     <interceptor class="org.jboss.aspects.remoting.InvokeRemoteInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.security.SecurityClientInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.tx.ClientTxPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.remoting.IsLocalInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.remoting.ClusterChooserInterceptor" scope="PER_VM"/>
  
     <interceptor class="org.jboss.aspects.tx.TxPropagationInterceptor" scope="PER_VM"/>
  
     <stack name="ServiceClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <interceptor class="org.jboss.ejb3.asynchronous.AsynchronousInterceptor" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.ENCPropagationInterceptor" scope="PER_VM"/>
     <interceptor name="Basic Authorization" factory="org.jboss.ejb3.security.RoleBasedAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor name="JACC Authorization" factory="org.jboss.ejb3.security.JaccAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.AuthenticationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateless.StatelessInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.StatefulInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.service.ServiceSingletonInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.cache.StatefulReplicationInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.stateful.StatefulRemoveFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.tx.TxInterceptorFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.AllowedOperationsInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor" scope="PER_VM"/>
  
     <domain name="Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="JACC Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Base Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="JACC Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
  
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="Embedded Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.NoPassivationCache.class)
        </annotation>
  
     </domain>
  
     <domain name="Message Driven Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
     
     <domain name="Consumer Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND (has(* *->@org.jboss.annotation.ejb.CurrentMessage(..)) OR hasfield(* *->@org.jboss.annotation.ejb.CurrentMessage))">
           <interceptor-ref name="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
     <domain name="JACC Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
  
  </aop>
  
  
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources/ejb3-entity-cache-service.xml
  
  Index: ejb3-entity-cache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
  
    <!--  ====================================================================  -->
    <!--  Defines TreeCache configuration                                       -->
    <!--  ====================================================================  -->
    <mbean code="org.jboss.cache.TreeCache" name="jboss.cache:service=EJB3EntityTreeCache">
      <depends>jboss:service=Naming</depends>
      <depends>jboss:service=TransactionManager</depends>
      
      <!-- uncomment next three statements if using JGroups multiplexer,
            requires JGroups 2.3 or later, JBossCache 1.4 or later -->
      <!--
      <depends>jgroups.mux:name=Multiplexer</depends>
      <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
      <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
      -->
  
      <!-- Configure the TransactionManager -->
      <attribute name="TransactionManagerLookupClass">org.jboss.cache.JBossTransactionManagerLookup</attribute>
  
      <!--
              Node locking level : SERIALIZABLE
                                   REPEATABLE_READ (default)
                                   READ_COMMITTED
                                   READ_UNCOMMITTED
                                   NONE
      -->
      <attribute name="IsolationLevel">REPEATABLE_READ</attribute>
  
      <!--     Valid modes are LOCAL
                               REPL_ASYNC
                               REPL_SYNC
      -->
      <attribute name="CacheMode">REPL_SYNC</attribute>
  
      <!-- Name of cluster. Needs to be the same for all clusters, in order
               to find each other -->
      <attribute name="ClusterName">EJB3-entity-cache</attribute>
  
      <!-- Must be true if any entity deployment uses a scoped classloader -->
      <attribute name="UseRegionBasedMarshalling">true</attribute>
      <!-- Must match the value of "UseRegionBasedMarshalling" -->
      <attribute name="InactiveOnStartup">true</attribute>
      
      <attribute name="ClusterConfig">
        <config>
          <!-- 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" />
        </config>
      </attribute>
  
      <!--    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
      -->
      <attribute name="InitialStateRetrievalTimeout">5000</attribute>
  
      <!--    Number of milliseconds to wait until all responses for a
              synchronous call have been received.
      -->
      <attribute name="SyncReplTimeout">10000</attribute>
  
      <!--  Max number of milliseconds to wait for a lock acquisition -->
      <attribute name="LockAcquisitionTimeout">15000</attribute>
  
      <!--  Name of the eviction policy class. -->
      <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
      <!--  Specific eviction policy configurations. This is LRU -->
      <attribute name="EvictionPolicyConfig">
        <config>
          <attribute name="wakeUpIntervalSeconds">5</attribute>
          <!--  Cache wide default -->
          <region name="/_default_">
           <attribute name="maxNodes">5000</attribute>
           <attribute name="timeToLiveSeconds">1000</attribute>
         </region>
        </config>
      </attribute>
  
    </mbean>
  
  </server>
  
  
  
  


From validimir.ralev at jboss.com  Mon Dec 18 10:10:44 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:10:44 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR ...
Message-ID: <E1GwK8a-0003E1-8A@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:10:44

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR 
                        component-info.xml
  Log:
  This is a temporary manually built EJB3 CR9 PATCH1 version for use in the installer. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/ejb3-component-info">
  
     <component id="jboss/ejb3"
                licenseType="lgpl"
                version="1.0.0.CR9-jboss4.0.5-patch1-VR"
                description="The EJB3 deployer for integration with jboss-4.0.x">
  
        <artifact id="ejb3-clustered-sfsbcache-service.xml"/>
        <artifact id="ejb3-entity-cache-service.xml"/>
        <artifact id="ejb3-interceptors-aop.xml"/>
        <artifact id="ejb3.deployer" />
        <artifact id="hibernate-client.jar"/>
        <artifact id="jboss-ejb3-client.jar"/>
  
        <import componentref="javassist">
          <compatible version="3.2.0.CR1"/>
          <compatible version="3.2.0.CR2"/>
          <compatible version="3.2.0.GA"/>
          <compatible version="3.3.0.GA"/>
        </import>
        <import componentref="hibernate-annotations">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="hibernate-entitymanager">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="jboss/remoting">
          <compatible version="1.4.1_final"/>
          <compatible version="1.4.2.GA"/>
          <compatible version="1.4.3.GA"/>
          <compatible version="1.4.4.GA"/>
        </import>
        <import componentref="jboss/aop">
        	<compatible version="1.5.1.GA"/>
          <compatible version="1.5.2.GA"/>
        </import>
  
        <export>
           <include input="hibernate-client.jar"/>
           <include input="jboss-ejb3-client.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From validimir.ralev at jboss.com  Mon Dec 18 10:10:44 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:10:44 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/bin
	...
Message-ID: <E1GwK8a-0003E7-Cj@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:10:44

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/bin 
                        ejb3.deployer
  Log:
  This is a temporary manually built EJB3 CR9 PATCH1 version for use in the installer. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/bin/ejb3.deployer
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Mon Dec 18 10:10:44 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Mon, 18 Dec 2006 10:10:44 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib
	...
Message-ID: <E1GwK8a-0003EF-Hl@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/18 10:10:44

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib  
                        hibernate-client.jar jboss-ejb3-client.jar
  Log:
  This is a temporary manually built EJB3 CR9 PATCH1 version for use in the installer. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib/hibernate-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/18 15:10:44;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib/jboss-ejb3-client.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 10:27:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 10:27:00 -0500
Subject: [jboss-cvs] JBossAS SVN: r59080 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GwKOK-0003Vu-CV@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 10:26:58 -0500 (Mon, 18 Dec 2006)
New Revision: 59080

Modified:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
Log:
rename

Modified: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 14:57:41 UTC (rev 59079)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/InstantiateSpringTestCase.java	2006-12-18 15:26:58 UTC (rev 59080)
@@ -46,7 +46,7 @@
       return suite(InstantiateSpringTestCase.class);
    }
 
-   public void testDescribe() throws Exception
+   public void testConfigure() throws Exception
    {
       SimpleBean testBean = (SimpleBean) getBean("testBean", ControllerState.INSTANTIATED);
       assertNotNull(testBean);



From dimitris.andreadis at jboss.com  Mon Dec 18 10:35:18 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Mon, 18 Dec 2006 10:35:18 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-tomcat/5.5.20  ...
Message-ID: <E1GwKWM-0003e9-1C@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/18 10:35:18

  Modified:    apache-tomcat/5.5.20  component-info.xml
  Log:
  mark compatible with apache commons-logging 1.1
  
  Revision  Changes    Path
  1.2       +1 -0      repository.jboss.com/apache-tomcat/5.5.20/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/apache-tomcat/5.5.20/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	4 Oct 2006 14:28:35 -0000	1.1
  +++ component-info.xml	18 Dec 2006 15:35:18 -0000	1.2
  @@ -28,6 +28,7 @@
            <compatible version="1.0.4.1jboss"/>
            <compatible version="1.0.5.GA-jboss"/>
            <compatible version="1.0.5.SP1-jboss"/>
  +         <compatible version="1.1"/>         
         </import>
         <import componentref="apache-modeler">
            <compatible version="1.1patch" />
  
  
  


From mazz at jboss.com  Mon Dec 18 10:37:17 2006
From: mazz at jboss.com (John Mazzitelli)
Date: Mon, 18 Dec 2006 10:37:17 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7 - New
	directory ...
Message-ID: <E1GwKYH-0003ht-0L@committer01.frg.pub.inap.atl.jboss.com>

  User: jmazzitelli
  Date: 06/12/18 10:37:17

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7 added to the repository


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 10:37:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 10:37:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r59081 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GwKYP-0003iM-Ob@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-18 10:37:23 -0500 (Mon, 18 Dec 2006)
New Revision: 59081

Added:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java
Log:
Spring beans deploy test

Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java	2006-12-18 15:26:58 UTC (rev 59080)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java	2006-12-18 15:37:23 UTC (rev 59081)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import org.jboss.test.AbstractTestDelegate;
+import org.jboss.test.kernel.junit.MicrocontainerTest;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class TempSpringMicrocontainerTest extends MicrocontainerTest
+{
+
+   public TempSpringMicrocontainerTest(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test delegate
+    *
+    * @param clazz the class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      return new TempSpringMicrocontainerTestDelegate(clazz);
+   }
+
+}



From mazz at jboss.com  Mon Dec 18 10:38:02 2006
From: mazz at jboss.com (John Mazzitelli)
Date: Mon, 18 Dec 2006 10:38:02 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7 ...
Message-ID: <E1GwKZ0-0003jI-5O@committer01.frg.pub.inap.atl.jboss.com>

  User: jmazzitelli
  Date: 06/12/18 10:38:02

  Added:       maven2/i18nlog/i18nlog/1.0.7       i18nlog-1.0.7.jar
                        i18nlog-1.0.7.jar.md5 i18nlog-1.0.7.jar.sha1
                        i18nlog-1.0.7.pom i18nlog-1.0.7.pom.md5
                        i18nlog-1.0.7.pom.sha1
  Log:
  new version that directly supports log4j
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 15:38:02;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/18 15:38:02;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.jar.md5
  
  Index: i18nlog-1.0.7.jar.md5
  ===================================================================
  05b579ef9100f99cee3cc85f3537f6bc
  
  
  1.1      date: 2006/12/18 15:38:02;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.jar.sha1
  
  Index: i18nlog-1.0.7.jar.sha1
  ===================================================================
  90fdd91da763aa4d77b21dd821a59cbe20b889ca
  
  
  1.1      date: 2006/12/18 15:38:02;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.pom
  
  Index: i18nlog-1.0.7.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>i18nlog</groupId>
    <artifactId>i18nlog</artifactId>
    <version>1.0.7</version>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/18 15:38:02;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.pom.md5
  
  Index: i18nlog-1.0.7.pom.md5
  ===================================================================
  8708e3e0a24e9ea86fb77373e2cfddd0
  
  
  1.1      date: 2006/12/18 15:38:02;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.pom.sha1
  
  Index: i18nlog-1.0.7.pom.sha1
  ===================================================================
  313bd148e85a32c989f6f1465be064722cc775da
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:48 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:48 -0500
Subject: [jboss-cvs] jboss-seam/src/main/META-INF  ...
Message-ID: <E1GwKZk-0003je-PP@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:48

  Modified:    src/main/META-INF  components.xml
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.9       +1 -0      jboss-seam/src/main/META-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/META-INF/components.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- components.xml	14 Dec 2006 10:26:59 -0000	1.8
  +++ components.xml	18 Dec 2006 15:38:48 -0000	1.9
  @@ -44,6 +44,7 @@
     <factory scope="stateless" auto-create="true" name="transition" value="#{org.jboss.seam.core.transition}"/>
     <factory scope="stateless" auto-create="true" name="uiComponent" value="#{org.jboss.seam.core.uiComponent}"/>
     <factory scope="stateless" auto-create="true" name="userPrincipal" value="#{org.jboss.seam.core.userPrincipal}"/>
  +  <factory scope="stateless" auto-create="true" name="validation" value="#{org.jboss.seam.core.validation}"/>
   
     <factory scope="stateless" auto-create="true" name="currentTime" value="#{org.jboss.seam.framework.currentTime}"/>
     <factory scope="stateless" auto-create="true" name="currentDate" value="#{org.jboss.seam.framework.currentDate}"/>
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam   ...
Message-ID: <E1GwKZl-0003jo-0c@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/main/org/jboss/seam   Component.java pages-1.1.dtd
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.223     +2 -2      jboss-seam/src/main/org/jboss/seam/Component.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Component.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/Component.java,v
  retrieving revision 1.222
  retrieving revision 1.223
  diff -u -b -r1.222 -r1.223
  --- Component.java	16 Dec 2006 14:06:57 -0000	1.222
  +++ Component.java	18 Dec 2006 15:38:48 -0000	1.223
  @@ -122,7 +122,7 @@
    *
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
    * @author Gavin King
  - * @version $Revision: 1.222 $
  + * @version $Revision: 1.223 $
    */
   @Scope(ScopeType.APPLICATION)
   @SuppressWarnings("deprecation")
  @@ -1792,7 +1792,7 @@
         try
         {
            Method interfaceMethod = instance.getClass().getMethod(methodName, paramTypes);
  -         if ( paramTypes.length==0 )
  +         if ( paramTypes.length==0 || interfaceMethod.getParameterTypes().length==0 )
            {
               return Reflections.invokeAndWrap(interfaceMethod, instance);
            }
  
  
  
  1.11      +10 -7     jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- pages-1.1.dtd	17 Dec 2006 16:04:09 -0000	1.10
  +++ pages-1.1.dtd	18 Dec 2006 15:38:48 -0000	1.11
  @@ -9,7 +9,7 @@
   <!ELEMENT pages (page*)>
   <!ATTLIST pages no-conversation-view-id CDATA #IMPLIED>
   
  -<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|action-navigation)*>
  +<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|action|action-navigation)*>
   <!ATTLIST page action CDATA #IMPLIED>
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
  @@ -24,14 +24,17 @@
   <!ATTLIST param converter CDATA #IMPLIED>
   <!ATTLIST param converterId CDATA #IMPLIED>
   
  -<!ELEMENT action-navigation (null-outcome?,outcome*,any-outcome?)>
  -<!ATTLIST action-navigation action CDATA #IMPLIED>
  -<!ATTLIST action-navigation outcome CDATA #IMPLIED>
  +<!ELEMENT action EMPTY>
  +<!ATTLIST action if CDATA #IMPLIED>
  +<!ATTLIST action execute CDATA #REQUIRED>
  +
  +<!ELEMENT action-navigation (((begin-conversation|end-conversation)?,(render|redirect))|(outcome*))>
  +<!ATTLIST action-navigation from-action CDATA #IMPLIED>
  +<!ATTLIST action-navigation evaluate CDATA #IMPLIED>
   
   <!ELEMENT outcome ((begin-conversation|end-conversation)?,(render|redirect))>
  -<!ATTLIST outcome value CDATA #REQUIRED>
  -<!ELEMENT any-outcome ((begin-conversation|end-conversation)?,(render|redirect))>
  -<!ELEMENT null-outcome ((begin-conversation|end-conversation)?,(render|redirect))>
  +<!ATTLIST outcome if-value CDATA #IMPLIED>
  +<!ATTLIST outcome if CDATA #IMPLIED>
   
   <!ELEMENT begin-conversation EMPTY>
   <!ATTLIST begin-conversation join (true|false) "false">
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/actionparam   ...
Message-ID: <E1GwKZl-0003jy-5Y@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/main/org/jboss/seam/actionparam  
                        ActionParamMethodBinding.java
                        MethodExpressionParser.java
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.4       +16 -8     jboss-seam/src/main/org/jboss/seam/actionparam/ActionParamMethodBinding.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActionParamMethodBinding.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/actionparam/ActionParamMethodBinding.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ActionParamMethodBinding.java	12 Oct 2006 01:37:28 -0000	1.3
  +++ ActionParamMethodBinding.java	18 Dec 2006 15:38:49 -0000	1.4
  @@ -51,8 +51,10 @@
           application = ( (SeamApplication11) FacesContext.getCurrentInstance().getApplication() ).getDelegate();
       }
       
  -    public ActionParamMethodBinding(Application application, String expWithParams) {
  -        if (MethodExpressionParser.isStringLiteral(expWithParams)) {
  +    public ActionParamMethodBinding(Application application, String expWithParams)
  +    {
  +        if ( MethodExpressionParser.isStringLiteral(expWithParams) ) 
  +        {
               throw new EvaluationException(expWithParams + " is not an EL expression");
           }
           
  @@ -62,7 +64,8 @@
       }
       
       @Override
  -    public Class getType(FacesContext facesContext) throws MethodNotFoundException {
  +    public Class getType(FacesContext facesContext) throws MethodNotFoundException 
  +    {
           return String.class; // since this is a JSF 1.1 style action, we assume it returns a String
       }
   
  @@ -72,24 +75,29 @@
       }
   
       @Override
  -    public String getExpressionString() {
  +    public String getExpressionString() 
  +    {
           return expWithParams;
       }
       
  -    public void restoreState(FacesContext facesContext, Object object) {
  +    public void restoreState(FacesContext facesContext, Object object) 
  +    {
           this.expWithParams = (String) object;
           this.helper = new ActionParamBindingHelper(application, expWithParams);
       }
   
  -    public Object saveState(FacesContext facesContext) {
  +    public Object saveState(FacesContext facesContext) 
  +    {
           return this.expWithParams;
       }
       
  -    public void setTransient(boolean isTransient) {
  +    public void setTransient(boolean isTransient) 
  +    {
           this.isTransient = isTransient;
       }
   
  -    public boolean isTransient() {
  +    public boolean isTransient() 
  +    {
           return this.isTransient;
       }
   }
  \ No newline at end of file
  
  
  
  1.3       +2 -2      jboss-seam/src/main/org/jboss/seam/actionparam/MethodExpressionParser.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodExpressionParser.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/actionparam/MethodExpressionParser.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MethodExpressionParser.java	17 Nov 2006 22:21:04 -0000	1.2
  +++ MethodExpressionParser.java	18 Dec 2006 15:38:49 -0000	1.3
  @@ -63,7 +63,7 @@
               
               this.hasParamsInExpression = hasParams(noBrackets);
   
  -            if (isStringLiteral(expression)) 
  +            if ( isStringLiteral(expression) ) 
               {
                   this.params = new String[0];
                   this.baseExpression = expression.trim();
  @@ -72,7 +72,7 @@
                   return;
               }
               
  -            if (hasNoMethod(noBrackets))
  +            if ( hasNoMethod(noBrackets) )
               {
                   this.params = new String[0];
                   this.baseExpression = noBrackets;
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core      ...
Message-ID: <E1GwKZl-0003kH-BA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/main/org/jboss/seam/core      Manager.java Pageflow.java
                        Pages.java Validation.java
  Added:       src/main/org/jboss/seam/core      Validators.java
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.130     +3 -32     jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.129
  retrieving revision 1.130
  diff -u -b -r1.129 -r1.130
  --- Manager.java	18 Dec 2006 11:52:49 -0000	1.129
  +++ Manager.java	18 Dec 2006 15:38:49 -0000	1.130
  @@ -20,11 +20,8 @@
   import javax.faces.application.FacesMessage;
   import javax.faces.context.ExternalContext;
   import javax.faces.context.FacesContext;
  -import javax.faces.el.MethodBinding;
   import javax.faces.event.PhaseId;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  @@ -36,6 +33,8 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.contexts.ServerConversationContext;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.Id;
   
   /**
  @@ -43,7 +42,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.129 $
  + * @version $Revision: 1.130 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -1123,32 +1122,4 @@
         this.parentConversationIdParameter = nestedConversationIdParameter;
      }
      
  -   private boolean forceModelUpdate;
  -   private MethodBinding validationFailedAction;
  -   
  -   public void setValidationFailedAction(MethodBinding action)
  -   {
  -      validationFailedAction = action;
  -   }
  -   
  -   public void setForceModelUpdate()
  -   {
  -      forceModelUpdate = true;
  -   }
  -   
  -   public void afterValidationFailure(FacesContext ctx)
  -   {
  -      if (forceModelUpdate)
  -      {
  -         ctx.getViewRoot().processUpdates(ctx);
  -      }
  -      if (validationFailedAction!=null)
  -      {
  -         Object result = validationFailedAction.invoke(ctx, null);
  -         String outcome = result==null ? null : result.toString();
  -         ctx.getApplication().getNavigationHandler()
  -               .handleNavigation(ctx, validationFailedAction.getExpressionString(), outcome);
  -      }
  -   }
  -
   }
  
  
  
  1.48      +3 -2      jboss-seam/src/main/org/jboss/seam/core/Pageflow.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pageflow.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pageflow.java,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -b -r1.47 -r1.48
  --- Pageflow.java	16 Dec 2006 02:58:10 -0000	1.47
  +++ Pageflow.java	18 Dec 2006 15:38:49 -0000	1.48
  @@ -261,7 +261,8 @@
         return getNode().getLeavingTransition(null)!=null;
      }
      
  -   private boolean isNullOutcome(String outcome) {
  +   private boolean isNullOutcome(String outcome) 
  +   {
         return outcome==null || "".equals(outcome);
      }
   
  @@ -285,7 +286,7 @@
            {
               //we don't use jBPM's default transition,
               //instead we use the "anonymous" transition
  -            PageflowHelper.signal(processInstance, (String) null);
  +            PageflowHelper.signal(processInstance, null);
               navigate(context);
            }
         }
  
  
  
  1.68      +32 -36    jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.67
  retrieving revision 1.68
  diff -u -b -r1.67 -r1.68
  --- Pages.java	17 Dec 2006 19:46:41 -0000	1.67
  +++ Pages.java	18 Dec 2006 15:38:49 -0000	1.68
  @@ -125,25 +125,18 @@
                     outcomeValue = value==null ? null : value.toString();
                  }
                  
  -               Outcome outcome;
  -               if (outcomeValue==null) 
  +               for ( Outcome outcome: navigation.getOutcomes() )
                  {
  -                  //JSF navhandler says ignore all rules when null outcome.
  -                  //so we have a special case for that
  -                  outcome = navigation.getNullOutcome();
  -               }
  -               else
  -               {
  -                  outcome = navigation.getOutcomes().get(outcomeValue);
  -                  if (outcome==null) outcome = navigation.getAnyOutcome();
  -               }
  -               
  -               if (outcome!=null)
  +                  if ( outcome.matches(outcomeValue) )
                  {
                     outcome.getConversationControl().beginOrEndConversation();
                     outcome.getNavigationHandler().navigate(context);
                     return true;
                  }
  +               }
  +               
  +               navigation.getOutcome().getConversationControl().beginOrEndConversation();
  +               navigation.getOutcome().getNavigationHandler().navigate(context);
                  
               }
               
  @@ -779,34 +772,24 @@
      private static void parseActionNavigation(Page entry, Element element)
      {
         ActionNavigation navigation = new ActionNavigation(); 
  -      String outcomeExpression = element.attributeValue("outcome");
  +      String outcomeExpression = element.attributeValue("evaluate");
         if (outcomeExpression!=null)
         {
            navigation.setOutcomeValueBinding( Expressions.instance().createValueBinding(outcomeExpression) );
         }
  +      
         List<Element> cases = element.elements("outcome");
         for (Element childElement: cases)
         {
  -         Outcome caze = parseOutcome(childElement);
  -         String value = childElement.attributeValue("value");
  -         if (value==null)
  -         {
  -            throw new IllegalStateException("Must specify value for <outcome/> declaration");
  -         }
  -         navigation.getOutcomes().put(value, caze);
  -      }
  -      Element childElement = element.element("any-outcome");
  -      if (childElement!=null)
  -      {
  -         navigation.setAnyOutcome( parseOutcome(childElement) );
  -      }
  -      childElement = element.element("null-outcome");
  -      if (childElement!=null)
  -      {
  -         navigation.setNullOutcome( parseOutcome(childElement) );
  +         navigation.getOutcomes().add( parseOutcome(childElement) );
         }
         
  -      String expression = element.attributeValue("action");
  +      Outcome outcome = new Outcome();
  +      parseNavigationHandler(element, outcome);
  +      parseConversationControl( element, outcome.getConversationControl() );
  +      navigation.setOutcome(outcome);
  +      
  +      String expression = element.attributeValue("from-action");
         if (expression==null)
         {
            entry.setDefaultNavigation(navigation);
  @@ -852,8 +835,22 @@
      private static Outcome parseOutcome(Element element)
      {
         Outcome outcome = new Outcome();
  +      
  +      outcome.setValue( element.attributeValue("if-value") );
  +      String expression = element.attributeValue("if");
  +      if (expression!=null)
  +      {
  +         outcome.setExpression( Expressions.instance().createValueBinding(expression)  );
  +      }
  +      
         parseConversationControl( element, outcome.getConversationControl() );
  +      parseNavigationHandler(element, outcome);
  +      
  +      return outcome;
  +   }
         
  +   private static void parseNavigationHandler(Element element, Outcome outcome)
  +   {
         Element render = element.element("render");
         if (render!=null)
         {
  @@ -872,7 +869,6 @@
            final String viewId = redirect.attributeValue("view-id");
            outcome.setNavigationHandler( new RedirectNavigationHandler(viewId, params) );
         }
  -      return outcome;
      }
   
   }
  
  
  
  1.6       +29 -60    jboss-seam/src/main/org/jboss/seam/core/Validation.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Validation.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Validation.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- Validation.java	15 Dec 2006 06:50:41 -0000	1.5
  +++ Validation.java	18 Dec 2006 15:38:49 -0000	1.6
  @@ -2,93 +2,62 @@
   
   import static org.jboss.seam.annotations.Install.BUILT_IN;
   
  -import java.util.Collections;
  -import java.util.HashMap;
  -import java.util.Map;
  -
   import javax.faces.context.FacesContext;
   
  -import org.hibernate.validator.ClassValidator;
  -import org.hibernate.validator.InvalidValue;
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptionType;
   import org.jboss.seam.ScopeType;
  +import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.annotations.Install;
  -import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
   
  +/**
  + * Allows the application to determine whether the JSF validation
  + * phase completed successfully, or if a validation failure
  + * occurred.
  + * 
  + * @author Gavin king
  + *
  + */
   @Name("org.jboss.seam.core.validation")
   @Intercept(InterceptionType.NEVER)
  - at Scope(ScopeType.APPLICATION)
   @Install(precedence=BUILT_IN)
   public class Validation
   {
   
  -   private Map<Class, ClassValidator> classValidators = Collections.synchronizedMap( new HashMap<Class, ClassValidator>() ); 
  +   private boolean succeeded;
  +   private boolean failed;
      
  -   public ClassValidator getValidator(Class modelClass, String name)
  +   public static Validation instance()
      {
  -      ClassValidator result = classValidators.get(modelClass);
  -      if (result==null)
  +      if ( !Contexts.isEventContextActive() )
         {
  -         result = createValidator(modelClass, name);
  -         classValidators.put(modelClass, result);
  +         throw new IllegalStateException("No active event scope");
         }
  -      return result;
  +      return (Validation) Component.getInstance(Validation.class, ScopeType.EVENT);
      }
      
  -   public ClassValidator createValidator(Class modelClass, String name)
  -   {
  -      Component component = name==null ? null : Component.forName(name);
  -      if (component==null)
  +   public void afterProcessValidations(FacesContext facesContext)
         {
  -         java.util.ResourceBundle bundle = ResourceBundle.instance();
  -         return bundle==null ? 
  -               new ClassValidator(modelClass) : 
  -               new ClassValidator(modelClass, bundle);
  -      }
  -      else
  -      {
  -         return component.getValidator();
  -      }
  +      failed = facesContext.getRenderResponse();
  +      succeeded = !failed;
      }
   
  -   public InvalidValue[] validate(FacesContext context, String propertyExpression, Object value)
  -   {
  -      int dot = propertyExpression.lastIndexOf('.');
  -      int bracket = propertyExpression.lastIndexOf('[');
  -      if (dot<=0 && bracket<=0) 
  +   public boolean isSucceeded()
         {
  -         return new InvalidValue[0];
  -      }
  -      String componentName;
  -      String propertyName;
  -      if (dot>bracket)
  -      {
  -         componentName = propertyExpression.substring(2, dot);
  -         propertyName = propertyExpression.substring( dot+1, propertyExpression.length()-1 );
  -      }
  -      else
  -      {
  -         componentName = propertyExpression.substring(2, bracket);
  -         propertyName = propertyExpression.substring( bracket+1, propertyExpression.length()-2 );
  +      return succeeded;
         }
      
  -      String modelExpression = propertyExpression.substring(0, dot) + '}';
  -      Object model = context.getApplication().createValueBinding(modelExpression).getValue(context);
  -      ClassValidator validator = getValidator( model.getClass(), componentName );    
  -      return validator.getPotentialInvalidValues(propertyName, value);
  +   public boolean isFailed()
  +   {
  +      return failed;
      }
   
  -   public static Validation instance()
  +   public void fail()
      {
  -      if ( !Contexts.isApplicationContextActive() )
  -      {
  -         throw new IllegalStateException("No active application scope");
  -      }
  -      return (Validation) Component.getInstance(Validation.class, ScopeType.APPLICATION);
  +      failed = true;
  +      succeeded = false;
      }
   
   }
  
  
  
  1.1      date: 2006/12/18 15:38:49;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/core/Validators.java
  
  Index: Validators.java
  ===================================================================
  package org.jboss.seam.core;
  
  import static org.jboss.seam.annotations.Install.BUILT_IN;
  
  import java.util.Collections;
  import java.util.HashMap;
  import java.util.Map;
  
  import javax.faces.context.FacesContext;
  
  import org.hibernate.validator.ClassValidator;
  import org.hibernate.validator.InvalidValue;
  import org.jboss.seam.Component;
  import org.jboss.seam.InterceptionType;
  import org.jboss.seam.ScopeType;
  import org.jboss.seam.annotations.Install;
  import org.jboss.seam.annotations.Intercept;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Scope;
  import org.jboss.seam.contexts.Contexts;
  
  /**
   * Caches instances of Hibernate Validator ClassValidator
   * 
   * @author Gavin King
   *
   */
  @Name("org.jboss.seam.core.validators")
  @Intercept(InterceptionType.NEVER)
  @Scope(ScopeType.APPLICATION)
  @Install(precedence=BUILT_IN)
  public class Validators
  {
  
     private Map<Class, ClassValidator> classValidators = Collections.synchronizedMap( new HashMap<Class, ClassValidator>() ); 
     
     public ClassValidator getValidator(Class modelClass, String name)
     {
        ClassValidator result = classValidators.get(modelClass);
        if (result==null)
        {
           result = createValidator(modelClass, name);
           classValidators.put(modelClass, result);
        }
        return result;
     }
     
     public ClassValidator createValidator(Class modelClass, String name)
     {
        Component component = name==null ? null : Component.forName(name);
        if (component==null)
        {
           java.util.ResourceBundle bundle = ResourceBundle.instance();
           return bundle==null ? 
                 new ClassValidator(modelClass) : 
                 new ClassValidator(modelClass, bundle);
        }
        else
        {
           return component.getValidator();
        }
     }
  
     public InvalidValue[] validate(FacesContext context, String propertyExpression, Object value)
     {
        int dot = propertyExpression.lastIndexOf('.');
        int bracket = propertyExpression.lastIndexOf('[');
        if (dot<=0 && bracket<=0) 
        {
           return new InvalidValue[0];
        }
        String componentName;
        String propertyName;
        if (dot>bracket)
        {
           componentName = propertyExpression.substring(2, dot);
           propertyName = propertyExpression.substring( dot+1, propertyExpression.length()-1 );
        }
        else
        {
           componentName = propertyExpression.substring(2, bracket);
           propertyName = propertyExpression.substring( bracket+1, propertyExpression.length()-2 );
        }
     
        String modelExpression = propertyExpression.substring(0, dot) + '}';
        Object model = context.getApplication().createValueBinding(modelExpression).getValue(context);
        ClassValidator validator = getValidator( model.getClass(), componentName );    
        return validator.getPotentialInvalidValues(propertyName, value);
     }
  
     public static Validators instance()
     {
        if ( !Contexts.isApplicationContextActive() )
        {
           throw new IllegalStateException("No active application scope");
        }
        return (Validators) Component.getInstance(Validators.class, ScopeType.APPLICATION);
     }
  
  }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf  ...
Message-ID: <E1GwKZl-0003kO-En@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/main/org/jboss/seam/jsf  AbstractSeamPhaseListener.java
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.33      +2 -4      jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- AbstractSeamPhaseListener.java	18 Dec 2006 01:46:24 -0000	1.32
  +++ AbstractSeamPhaseListener.java	18 Dec 2006 15:38:49 -0000	1.33
  @@ -29,6 +29,7 @@
   import org.jboss.seam.core.Pageflow;
   import org.jboss.seam.core.Pages;
   import org.jboss.seam.core.Switcher;
  +import org.jboss.seam.core.Validation;
   import org.jboss.seam.util.Transactions;
   
   public abstract class AbstractSeamPhaseListener implements PhaseListener
  @@ -324,10 +325,7 @@
   
      protected void afterProcessValidations(FacesContext facesContext)
      {
  -      if ( facesContext.getRenderResponse() )
  -      {
  -         Manager.instance().afterValidationFailure(facesContext);
  -      }
  +      Validation.instance().afterProcessValidations(facesContext);
      }
   
   }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/mock  ...
Message-ID: <E1GwKZl-0003kV-KA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/main/org/jboss/seam/mock  SeamTest.java
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.59      +4 -4      jboss-seam/src/main/org/jboss/seam/mock/SeamTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/SeamTest.java,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -b -r1.58 -r1.59
  --- SeamTest.java	15 Dec 2006 14:30:00 -0000	1.58
  +++ SeamTest.java	18 Dec 2006 15:38:49 -0000	1.59
  @@ -34,7 +34,7 @@
   import org.jboss.seam.core.Init;
   import org.jboss.seam.core.Manager;
   import org.jboss.seam.core.Pageflow;
  -import org.jboss.seam.core.Validation;
  +import org.jboss.seam.core.Validators;
   import org.jboss.seam.init.Initialization;
   import org.jboss.seam.jsf.AbstractSeamPhaseListener;
   import org.jboss.seam.jsf.SeamApplication11;
  @@ -51,7 +51,7 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.58 $
  + * @version $Revision: 1.59 $
    */
   public class SeamTest
   {
  @@ -318,7 +318,7 @@
          */
         protected void validate(Class modelClass, String property, Object value)
         {
  -         ClassValidator validator = Validation.instance().getValidator(modelClass, null);
  +         ClassValidator validator = Validators.instance().getValidator(modelClass, null);
            InvalidValue[] ivs = validator.getPotentialInvalidValues(property, value);
            if (ivs.length>0)
            {
  @@ -369,7 +369,7 @@
          */
         protected boolean validateValue(String valueExpression, Object value)
         {
  -         InvalidValue[] ivs = Validation.instance().validate(facesContext, valueExpression, value);
  +         InvalidValue[] ivs = Validators.instance().validate(facesContext, valueExpression, value);
            if (ivs.length>0)
            {
               validationFailed = true;
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pages   ...
Message-ID: <E1GwKZl-0003kf-OY@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/main/org/jboss/seam/pages   ActionNavigation.java
                        Outcome.java
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.2       +12 -19    jboss-seam/src/main/org/jboss/seam/pages/ActionNavigation.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActionNavigation.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/ActionNavigation.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ActionNavigation.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ ActionNavigation.java	18 Dec 2006 15:38:49 -0000	1.2
  @@ -3,47 +3,40 @@
    */
   package org.jboss.seam.pages;
   
  -import java.util.HashMap;
  -import java.util.Map;
  +import java.util.ArrayList;
  +import java.util.List;
   
   import org.jboss.seam.core.Expressions.ValueBinding;
   
   public final class ActionNavigation
   {
      private ValueBinding<Object> outcomeValueBinding;
  -   private Map<String, Outcome> outcomes = new HashMap<String, Outcome>();
  -   private Outcome nullOutcome;
  -   private Outcome anyOutcome;
  +   private List<Outcome> outcomes = new ArrayList<Outcome>();
  +   private Outcome outcome;
      
  -   public Map<String, Outcome> getOutcomes()
  +   public List<Outcome> getOutcomes()
      {
         return outcomes;
      }
      
  -   public void setNullOutcome(Outcome outcome)
  -   {
  -      this.nullOutcome = outcome;
  -   }
  -   public Outcome getNullOutcome()
  -   {
  -      return nullOutcome;
  -   }
  -   
      public void setOutcomeValueBinding(ValueBinding<Object> outcomeValueBinding)
      {
         this.outcomeValueBinding = outcomeValueBinding;
      }
  +   
      public ValueBinding<Object> getOutcomeValueBinding()
      {
         return outcomeValueBinding;
      }
   
  -   public Outcome getAnyOutcome()
  +   public Outcome getOutcome()
      {
  -      return anyOutcome;
  +      return outcome;
      }
  -   public void setAnyOutcome(Outcome outcome)
  +
  +   public void setOutcome(Outcome outcome)
      {
  -      this.anyOutcome = outcome;
  +      this.outcome = outcome;
      }
  +
   }
  \ No newline at end of file
  
  
  
  1.2       +37 -1     jboss-seam/src/main/org/jboss/seam/pages/Outcome.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Outcome.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/Outcome.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Outcome.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ Outcome.java	18 Dec 2006 15:38:49 -0000	1.2
  @@ -3,10 +3,26 @@
    */
   package org.jboss.seam.pages;
   
  +import javax.faces.context.FacesContext;
  +
  +import org.jboss.seam.core.Expressions.ValueBinding;
  +
   public final class Outcome
   {
  -   private NavigationHandler navigationHandler;
  +   private String value;
  +   private ValueBinding expression;
      private ConversationControl conversationControl = new ConversationControl();
  +   private NavigationHandler navigationHandler = new NavigationHandler() { 
  +      @Override
  +      public void navigate(FacesContext context) {}
  +   };
  +
  +   public boolean matches(String actualValue)
  +   {
  +      return ( actualValue!=null || expression!=null ) &&
  +            ( value==null || value.equals(actualValue) ) &&
  +            ( expression==null || Boolean.TRUE.equals( expression.getValue() ) );
  +   }
   
      public NavigationHandler getNavigationHandler()
      {
  @@ -22,4 +38,24 @@
      {
         return conversationControl;
      }
  +
  +   public ValueBinding getExpression()
  +   {
  +      return expression;
  +   }
  +
  +   public void setExpression(ValueBinding expression)
  +   {
  +      this.expression = expression;
  +   }
  +
  +   public String getValue()
  +   {
  +      return value;
  +   }
  +
  +   public void setValue(String value)
  +   {
  +      this.value = value;
  +   }
   }
  \ No newline at end of file
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:49 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:49 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF   ...
Message-ID: <E1GwKZl-0003kp-UF@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:49

  Modified:    src/ui/META-INF   faces-config.xml seam.taglib.xml
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.27      +1 -15     jboss-seam/src/ui/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/faces-config.xml,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- faces-config.xml	18 Dec 2006 01:46:24 -0000	1.26
  +++ faces-config.xml	18 Dec 2006 15:38:49 -0000	1.27
  @@ -494,18 +494,4 @@
           <converter-class>org.jboss.seam.ui.EnumConverter</converter-class>    
       </converter>
   
  -    <component>
  -        <component-type>org.jboss.seam.ui.UIValidationFailed</component-type>
  -        <component-class>org.jboss.seam.ui.UIValidationFailed</component-class>
  -        <property>
  -            <property-name>action</property-name>
  -            <property-class>java.lang.String</property-class>
  -        </property>
  -    </component>
  -    
  -    <component>
  -        <component-type>org.jboss.seam.ui.UIForceModelUpdate</component-type>
  -        <component-class>org.jboss.seam.ui.UIForceModelUpdate</component-class>
  -    </component>
  -    
   </faces-config>
  
  
  
  1.23      +0 -14     jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- seam.taglib.xml	18 Dec 2006 01:46:24 -0000	1.22
  +++ seam.taglib.xml	18 Dec 2006 15:38:49 -0000	1.23
  @@ -77,20 +77,6 @@
       </tag>
     
       <tag>
  -        <tag-name>validationFailed</tag-name>
  -        <component>
  -            <component-type>org.jboss.seam.ui.UIValidationFailed</component-type>
  -        </component>
  -    </tag>
  -  
  -    <tag>
  -        <tag-name>forceModelUpdate</tag-name>
  -        <component>
  -            <component-type>org.jboss.seam.ui.UIForceModelUpdate</component-type>
  -        </component>
  -    </tag>
  -  
  -    <tag>
           <tag-name>message</tag-name>
           <component>
               <component-type>org.jboss.seam.ui.HtmlMessageDecoration</component-type>
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:38:50 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:38:50 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui  ...
Message-ID: <E1GwKZm-0003kw-3h@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:38:50

  Modified:    src/ui/org/jboss/seam/ui  ModelValidator.java
  Log:
  new validation component,
  reworked navigation rules
  
  Revision  Changes    Path
  1.5       +2 -2      jboss-seam/src/ui/org/jboss/seam/ui/ModelValidator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ModelValidator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/ModelValidator.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ModelValidator.java	27 Oct 2006 13:20:01 -0000	1.4
  +++ ModelValidator.java	18 Dec 2006 15:38:50 -0000	1.5
  @@ -9,7 +9,7 @@
   
   import org.hibernate.validator.InvalidValue;
   import org.jboss.seam.core.FacesMessages;
  -import org.jboss.seam.core.Validation;
  +import org.jboss.seam.core.Validators;
   
   public class ModelValidator implements Validator
   {
  @@ -22,7 +22,7 @@
         {
            throw new RuntimeException("component has no value attribute: " + component.getId());
         }
  -      InvalidValue[] ivs = Validation.instance().validate( context, valueBinding.getExpressionString(), value );
  +      InvalidValue[] ivs = Validators.instance().validate( context, valueBinding.getExpressionString(), value );
         if ( ivs.length>0 )
         {
            throw new ValidatorException( FacesMessages.createFacesMessage( FacesMessage.SEVERITY_WARN, ivs[0].getMessage() ) );
  
  
  


From gavin.king at jboss.com  Mon Dec 18 10:42:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 10:42:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GwKd3-0003pp-9I@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 10:42:13

  Modified:    examples/booking/resources/WEB-INF  pages.xml
  Log:
  update
  
  Revision  Changes    Path
  1.10      +26 -33    jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- pages.xml	17 Dec 2006 14:07:46 -0000	1.9
  +++ pages.xml	18 Dec 2006 15:42:13 -0000	1.10
  @@ -5,43 +5,46 @@
   <pages no-conversation-view-id="/main.xhtml">
   
       <page view-id="/register.xhtml">
  -        <action-navigation outcome="#{register.registered}">
  -            <outcome value="true">
  +    
  +        <action-navigation>
  +            <outcome if="#{register.registered}">
                   <redirect view-id="/home.xhtml"/>
               </outcome>
           </action-navigation>
  +        
       </page>
   
       <page view-id="/home.xhtml">
  -        <action-navigation outcome="#{login.loggedIn}">
  -            <outcome value="true">
  +    
  +        <action-navigation>
  +            <outcome if="#{login.loggedIn}">
                   <redirect view-id="/main.xhtml"/>
               </outcome>
           </action-navigation>
  +        
       </page>
       
       <page view-id="/password.xhtml">
  -        <action-navigation outcome="#{changePassword.changed}">
  -            <outcome value="true">
  +    
  +        <action-navigation>
  +            <outcome if="#{changePassword.changed}">
                   <redirect view-id="/main.xhtml"/>
               </outcome>
           </action-navigation>
  +        
       </page>
   
       <page view-id="/main.xhtml" 
             action="#{login.validateLogin}">
           
  -        <action-navigation action="#{login.validateLogin}"
  -                          outcome="#{login.loggedIn}">
  -            <outcome value="false">
  +        <action-navigation from-action="#{login.validateLogin}">
  +            <outcome if="#{not login.loggedIn}">
                   <redirect view-id="/home.xhtml"/>
               </outcome>
           </action-navigation>
           
  -        <action-navigation action="#{hotelBooking.selectHotel(hot)}">
  -            <null-outcome>
  +        <action-navigation from-action="#{hotelBooking.selectHotel(hot)}">
                   <redirect view-id="/hotel.xhtml"/>
  -            </null-outcome>
           </action-navigation>
           
       </page>
  @@ -51,10 +54,8 @@
             
           <description>View hotel: #{hotel.name}</description>
           
  -        <action-navigation action="#{hotelBooking.bookHotel}">
  -            <null-outcome>
  +        <action-navigation from-action="#{hotelBooking.bookHotel}">
                   <redirect view-id="/book.xhtml"/>
  -            </null-outcome>
           </action-navigation>
           
       </page>
  @@ -64,10 +65,8 @@
             
           <description>Book hotel: #{hotel.name}</description>
           
  -        <action-navigation outcome="#{hotelBooking.bookingValid}">
  -            <outcome value="true">
  +        <action-navigation>
                   <redirect view-id="/confirm.xhtml"/>
  -            </outcome>
           </action-navigation>
           
       </page>
  @@ -77,26 +76,20 @@
             
           <description>Confirm booking: #{booking.description}</description>
           
  -        <action-navigation action="#{hotelBooking.confirm}">
  -            <null-outcome>
  +        <action-navigation from-action="#{hotelBooking.confirm}">
                   <redirect view-id="/main.xhtml"/>
  -            </null-outcome>
           </action-navigation>
           
       </page>
       
       <page view-id="*">
       
  -        <action-navigation action="#{login.logout}">
  -            <null-outcome>
  +        <action-navigation from-action="#{login.logout}">
                   <redirect view-id="/home.xhtml"/>
  -            </null-outcome>
           </action-navigation>
   
  -        <action-navigation action="#{hotelBooking.cancel}">
  -            <null-outcome>
  +        <action-navigation from-action="#{hotelBooking.cancel}">
                   <redirect view-id="/main.xhtml"/>
  -            </null-outcome>
           </action-navigation>
           
       </page>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 10:52:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 10:52:37 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59082 - branches/Branch_4_2/build
Message-ID: <E1GwKn7-00040o-Jd@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-18 10:52:35 -0500 (Mon, 18 Dec 2006)
New Revision: 59082

Modified:
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
JBAS-2823, upgrade commons-logging to v1.1

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-18 15:37:23 UTC (rev 59081)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-18 15:52:35 UTC (rev 59082)
@@ -61,7 +61,7 @@
       <componentref name="apache-httpclient" version="2.0.2"/>
       <componentref name="apache-jaxme" version="0.2-cvs"/>
       <componentref name="apache-log4j" version="1.2.14"/>
-      <componentref name="apache-logging" version="1.0.5.GA-jboss"/>
+      <componentref name="apache-logging" version="1.1"/>
       <componentref name="apache-myfaces" version="1.1.4"/>
       <componentref name="apache-pool" version="1.0.1"/>
       <componentref name="apache-scout" version="0.7rc2"/>



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 11:03:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 11:03:15 -0500
Subject: [jboss-cvs] JBossAS SVN: r59083 - in
	projects/microcontainer/trunk/container/src/main/org/jboss/virtual:
	. plugins/context plugins/context/file plugins/context/jar
	plugins/vfs protocol/vfsfile spi
Message-ID: <E1GwKxP-0004Ks-CJ@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-18 11:03:12 -0500 (Mon, 18 Dec 2006)
New Revision: 59083

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractURLHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java
Log:
add a hasBeenModified() method to VF and VFH.  

VirtualFileURLConnection's VFS cache is purged if the VFS Root has been modified since the last cache lookup.  This is to make sure we don't cache stale JAR files as they may have been redeployed since last lookup.

FileHandler's child cache is purged when child's hasBeenModified returns true for same reasons as above.

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/VirtualFile.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -146,6 +146,18 @@
    }
 
    /**
+    * Returns true if the file has been modified since this method was last called
+    * Last modified time is initialized at handler instantiation.
+    *
+    * @return
+    * @throws IOException
+    */
+   public boolean hasBeenModified() throws IOException
+   {
+      return getHandler().hasBeenModified();
+   }
+
+   /**
     * Get the size
     *
     * @return the size

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractURLHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractURLHandler.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractURLHandler.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -63,6 +63,18 @@
          throw new IllegalArgumentException("Null url");
       this.url = url;
    }
+
+   protected void initCacheLastModified()
+   {
+      try
+      {
+         this.cachedLastModified = url.openConnection().getLastModified();
+      }
+      catch (IOException e)
+      {
+         throw new RuntimeException(e);
+      }
+   }
    
    /**
     * Get the url

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -87,6 +87,8 @@
    /** The reference count */
    private transient AtomicInteger references = new AtomicInteger(0);
 
+   protected transient long cachedLastModified;
+
    /**
     * Create a new handler
     * 
@@ -106,6 +108,18 @@
       this.name = VFSUtils.fixName(name);
    }
 
+   public boolean hasBeenModified() throws IOException
+   {
+      long last = getLastModified();
+      if (cachedLastModified != last)
+      {
+         cachedLastModified = last;
+         return true;
+      }
+      return false;
+   }
+
+
    public String getName()
    {
       return name;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/file/FileHandler.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -152,13 +152,17 @@
       List<VirtualFileHandler> result = new ArrayList<VirtualFileHandler>();
       Map<String, VirtualFileHandler> newCache = Collections.synchronizedMap(new HashMap<String, VirtualFileHandler>());
       Map<String, VirtualFileHandler> oldCache = childCache;
+      // fill up a new cache with old entries
+      // old entries no longer existing in directory are purged by not being added to new cache
+      // we cache handlers so that things like JARs are recreated (optimization)
       for (File file : files)
       {
          try
          {
             VirtualFileHandler handler = null;
             handler = oldCache.get(file.getName());
-            if (handler != null && file.lastModified() != handler.getLastModified())
+            // if underlying file has been modified then create a new handler instead of using the cached one
+            if (handler != null && handler.hasBeenModified())
             {
                handler = null;
             }
@@ -193,9 +197,11 @@
       File parentFile = getFile();
       File child = new File(parentFile, name);
       VirtualFileHandler handler = childCache.get(name);
-      if (handler != null)
+      // if a child has already been created use that
+      // if the child has been modified on disk then create a new handler
+      if (handler != null && handler.hasBeenModified())
       {
-         if (handler.getLastModified() != child.lastModified()) handler = null;
+         handler = null;
       }
       if (handler == null)
       {

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/JarEntryHandler.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -99,6 +99,19 @@
       this.entry = entry;
    }
 
+
+   @Override
+   protected void initCacheLastModified()
+   {
+      // complete
+   }
+
+   @Override
+   public boolean hasBeenModified() throws IOException
+   {
+      return false; // right now, jar entries should always 
+   }
+
    /**
     * Add a child to an entry
     * @param child

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/vfs/VirtualFileURLConnection.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -38,7 +38,7 @@
  * @author <a href="bill at jboss.com">Bill Burke</a>
  * @version $Revision: 1.1 $
  */
-public class   VirtualFileURLConnection extends URLConnection
+public class VirtualFileURLConnection extends URLConnection
 {
    public static Map<URL, VFS> urlCache = Collections.synchronizedMap(new HashMap<URL, VFS>());
 
@@ -66,6 +66,17 @@
          vfs = VFS.getVFS(vfsurl);
          urlCache.put(vfsurl, vfs);
       }
+      else
+      {
+         // if the root of VFS has changed on disk, lets purge it
+         // this is important for Jar files as we don't want stale jars as the
+         // root of the VFS (i.e., on redeployment)
+         if (vfs.getRoot().getHandler().hasBeenModified())
+         {
+            vfs = VFS.getVFS(vfsurl);
+            urlCache.put(vfsurl, vfs);
+         }
+      }
       return vfs.findChild(relativePath);
 
    }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/protocol/vfsfile/Handler.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -21,20 +21,24 @@
 */
 package org.jboss.virtual.protocol.vfsfile;
 
+import org.jboss.virtual.VFS;
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
+
 import java.io.File;
 import java.io.IOException;
 import java.io.InputStream;
 import java.net.URL;
-import java.net.URLClassLoader;
 import java.net.URLConnection;
 import java.net.URLStreamHandler;
-import java.util.Enumeration;
-import java.util.HashSet;
+import java.net.URLClassLoader;
 import java.util.jar.JarEntry;
 import java.util.jar.JarFile;
+import java.util.HashSet;
+import java.util.Enumeration;
+import java.util.Map;
+import java.util.Collections;
+import java.util.HashMap;
 
-import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
-
 /**
  * URLStreamHandler for VFS
  *

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java	2006-12-18 15:52:35 UTC (rev 59082)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/spi/VirtualFileHandler.java	2006-12-18 16:03:12 UTC (rev 59083)
@@ -90,6 +90,15 @@
     * @throws IllegalStateException if closed
     */
    long getLastModified() throws IOException;
+
+   /**
+    * Returns true if the file has been modified since this method was last called
+    * Last modified time is initialized at handler instantiation.
+    *
+    * @return
+    * @throws IOException
+    */
+   boolean hasBeenModified() throws IOException;
    
    /**
     * Get the size



From gavin.king at jboss.com  Mon Dec 18 11:50:30 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 11:50:30 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GwLh8-00055c-SD@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 11:50:30

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  multiple actions per page, and conditional page actions
  
  Revision  Changes    Path
  1.69      +49 -30    jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -b -r1.68 -r1.69
  --- Pages.java	18 Dec 2006 15:38:49 -0000	1.68
  +++ Pages.java	18 Dec 2006 16:50:30 -0000	1.69
  @@ -33,6 +33,7 @@
   import org.jboss.seam.core.Expressions.ValueBinding;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
  +import org.jboss.seam.pages.Action;
   import org.jboss.seam.pages.ActionNavigation;
   import org.jboss.seam.pages.ConversationControl;
   import org.jboss.seam.pages.Outcome;
  @@ -284,24 +285,26 @@
         
         page.getConversationControl().beginOrEndConversation();
   
  -      String outcome = page.getOutcome();
  +      for ( Action action: page.getActions() )
  +      {
  +         if ( action.isExecutable() )
  +         {
  +            String outcome = action.getOutcome();
         String fromAction = outcome;
         
         if (outcome==null)
         {
  -         MethodBinding methodBinding = page.getAction();
  -         if (methodBinding!=null) 
  -         {
  -            fromAction = methodBinding.getExpressionString();
  +                     fromAction = action.getMethodBinding().getExpressionString();
               result = true;
  -            outcome = toString( methodBinding.invoke() );
  +                     outcome = toString( action.getMethodBinding().invoke() );
               handleOutcome(facesContext, outcome, fromAction);
            }
  -      }
         else
         {
            handleOutcome(facesContext, outcome, fromAction);
         }
  +         }
  +      }
         
         return result;
   
  @@ -409,7 +412,7 @@
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getParameters() )
            {
               ValueBinding valueBinding = pageParameter.getValueBinding();
               Object value;
  @@ -443,7 +446,7 @@
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getParameters() )
            {
               if ( !overridden.contains( pageParameter.getName() ) )
               {
  @@ -484,7 +487,7 @@
         Map<String, String[]> requestParameters = Parameters.getRequestParameters();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getParameters() )
            {  
               
               Object value = pageParameter.getValueFromRequest(facesContext, requestParameters);
  @@ -512,7 +515,7 @@
         String viewId = facesContext.getViewRoot().getViewId();
         for ( Page page: getPageStack(viewId) )
         {
  -         for ( Param pageParameter: page.getPageParameters() )
  +         for ( Param pageParameter: page.getParameters() )
            {         
               ValueBinding valueBinding = pageParameter.getValueBinding();
               if (valueBinding!=null)
  @@ -678,7 +681,7 @@
         List<Element> children = element.elements("param");
         for (Element param: children)
         {
  -         page.getPageParameters().add( parseParam(param) );
  +         page.getParameters().add( parseParam(param) );
         }
         
         List<Element> moreChildren = element.elements("action-navigation");
  @@ -713,18 +716,12 @@
         page.setNoConversationViewId( element.attributeValue("no-conversation-view-id") );
         page.setConversationRequired( "true".equals( element.attributeValue("conversation-required") ) );
         
  -      String action = element.attributeValue("action");
  -      if (action!=null)
  +      Action action = parseAction(element, "action");
  +      if (action!=null) page.getActions().add(action);
  +      List<Element> childElements = element.elements("action");
  +      for (Element childElement: childElements)
         {
  -         if ( action.startsWith("#{") )
  -         {
  -            MethodBinding methodBinding = Expressions.instance().createMethodBinding(action);
  -            page.setAction(methodBinding);
  -         }
  -         else
  -         {
  -            page.setOutcome(action);
  -         }
  +         page.getActions().add( parseAction(childElement, "execute") );
         }
               
         String bundle = element.attributeValue("bundle");
  @@ -735,6 +732,28 @@
         return page;
      }
   
  +   private static Action parseAction(Element element, String actionAtt)
  +   {
  +      Action action = new Action();
  +      String methodExpression = element.attributeValue(actionAtt);
  +      if (methodExpression==null) return null;
  +      if ( methodExpression.startsWith("#{") )
  +      {
  +         MethodBinding methodBinding = Expressions.instance().createMethodBinding(methodExpression);
  +         action.setMethodBinding(methodBinding);
  +      }
  +      else
  +      {
  +         action.setOutcome(methodExpression);
  +      }
  +      String expression = element.attributeValue("if");
  +      if (expression!=null)
  +      {
  +         action.setValueBinding( Expressions.instance().createValueBinding(expression) );
  +      }
  +      return action;
  +   }
  +
      /**
       * Parse end-conversation and begin-conversation
       */
  
  
  


From gavin.king at jboss.com  Mon Dec 18 11:50:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 11:50:31 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pages   ...
Message-ID: <E1GwLh9-00055m-2S@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 11:50:31

  Modified:    src/main/org/jboss/seam/pages   Page.java
  Added:       src/main/org/jboss/seam/pages   Action.java
  Log:
  multiple actions per page, and conditional page actions
  
  Revision  Changes    Path
  1.2       +9 -27     jboss-seam/src/main/org/jboss/seam/pages/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/Page.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Page.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ Page.java	18 Dec 2006 16:50:31 -0000	1.2
  @@ -6,10 +6,8 @@
   import java.util.Map;
   import java.util.MissingResourceException;
   
  -
   import org.jboss.seam.core.Interpolator;
   import org.jboss.seam.core.Locale;
  -import org.jboss.seam.core.Expressions.MethodBinding;
   
   /**
    * Metadata about page actions, page parameters, action navigation,
  @@ -20,12 +18,11 @@
      private final String viewId;
      private String description;
      private Integer timeout;
  -   private MethodBinding action;
  -   private String outcome;
      private String noConversationViewId;
      private String resourceBundleName;
      private boolean switchEnabled = true;
  -   private List<Param> pageParameters = new ArrayList<Param>();
  +   private List<Param> parameters = new ArrayList<Param>();
  +   private List<Action> actions = new ArrayList<Action>();
      private Map<String, ActionNavigation> navigations = new HashMap<String, ActionNavigation>();
      private ActionNavigation defaultNavigation;
      private boolean conversationRequired;
  @@ -104,26 +101,6 @@
         return timeout;
      }
   
  -   public void setAction(MethodBinding action)
  -   {
  -      this.action = action;
  -   }
  -
  -   public MethodBinding getAction()
  -   {
  -      return action;
  -   }
  -
  -   public void setOutcome(String outcome)
  -   {
  -      this.outcome = outcome;
  -   }
  -
  -   public String getOutcome()
  -   {
  -      return outcome;
  -   }
  -
      public void setNoConversationViewId(String noConversationViewId)
      {
         this.noConversationViewId = noConversationViewId;
  @@ -154,9 +131,9 @@
         return switchEnabled;
      }
   
  -   public List<Param> getPageParameters()
  +   public List<Param> getParameters()
      {
  -      return pageParameters;
  +      return parameters;
      }
   
      public Map<String, ActionNavigation> getNavigations()
  @@ -194,4 +171,9 @@
         return conversationControl;
      }
   
  +   public List<Action> getActions()
  +   {
  +      return actions;
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.1      date: 2006/12/18 16:50:31;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Action.java
  
  Index: Action.java
  ===================================================================
  package org.jboss.seam.pages;
  
  import org.jboss.seam.core.Expressions.MethodBinding;
  import org.jboss.seam.core.Expressions.ValueBinding;
  
  public class Action
  {
     private MethodBinding methodBinding;
     private ValueBinding valueBinding;
     private String outcome;
     
     public boolean isExecutable()
     {
        return valueBinding==null || 
             Boolean.TRUE.equals( valueBinding.getValue() );
     }
     
     public MethodBinding getMethodBinding()
     {
        return methodBinding;
     }
     public void setMethodBinding(MethodBinding methodBinding)
     {
        this.methodBinding = methodBinding;
     }
     
     public ValueBinding getValueBinding()
     {
        return valueBinding;
     }
     public void setValueBinding(ValueBinding valueBinding)
     {
        this.valueBinding = valueBinding;
     }
  
     public String getOutcome()
     {
        return outcome;
     }
     public void setOutcome(String outcome)
     {
        this.outcome = outcome;
     }
  }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 11:50:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 11:50:31 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1GwLh9-00055q-7B@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 11:50:31

  Removed:     src/ui/org/jboss/seam/ui   UIForceModelUpdate.java
                        UIValidationFailed.java
  Log:
  multiple actions per page, and conditional page actions


From gavin.king at jboss.com  Mon Dec 18 11:50:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 11:50:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/src/actions   ...
Message-ID: <E1GwLgr-00054V-Pr@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 11:50:13

  Modified:    examples/blog/src/actions   LoginAction.java PostAction.java
  Log:
  transparent navigation
  
  Revision  Changes    Path
  1.6       +1 -3      jboss-seam/examples/blog/src/actions/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/src/actions/LoginAction.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- LoginAction.java	17 Nov 2006 03:00:16 -0000	1.5
  +++ LoginAction.java	18 Dec 2006 16:50:13 -0000	1.6
  @@ -22,17 +22,15 @@
      String password;
      boolean loggedIn;
      
  -   public String login() throws IOException
  +   public void login() throws IOException
      {
         if ( blog.getPassword().equals(password) )
         {
            loggedIn = true;
  -         return "/post.xhtml";
         }
         else
         {
            facesMessages.add("incorrect password");
  -         return null;
         }
      }
      
  
  
  
  1.9       +7 -2      jboss-seam/examples/blog/src/actions/PostAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PostAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/src/actions/PostAction.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- PostAction.java	17 Nov 2006 03:00:16 -0000	1.8
  +++ PostAction.java	18 Dec 2006 16:50:13 -0000	1.9
  @@ -9,6 +9,7 @@
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  +import org.jboss.seam.core.FacesMessages;
   
   import domain.Blog;
   import domain.BlogEntry;
  @@ -28,12 +29,16 @@
      
      @In(required=false) BlogEntry blogEntry;
      
  -   public String post() throws IOException
  +   public void post() throws IOException
      {
         blogEntry.setDate( new Date() );
         blog.getBlogEntries().add(blogEntry);
         entityManager.persist(blogEntry);
  -      return "/index.xhtml";
  +   }
  +   
  +   public void invalid()
  +   {
  +      FacesMessages.instance().add("You are missing some information, please try again");
      }
      
   }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 11:50:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 11:50:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/view   ...
Message-ID: <E1GwLgr-00054f-UQ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 11:50:13

  Modified:    examples/blog/view   login.xhtml post.xhtml
  Log:
  transparent navigation
  
  Revision  Changes    Path
  1.3       +6 -3      jboss-seam/examples/blog/view/login.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: login.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/view/login.xhtml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- login.xhtml	22 Jun 2006 06:16:28 -0000	1.2
  +++ login.xhtml	18 Dec 2006 16:50:13 -0000	1.3
  @@ -10,11 +10,14 @@
      <div class="blogEntry">
         <h:form>
            <div>
  -            <h:outputLabel for="password">Password: </h:outputLabel>
  +            <h:outputLabel for="password">Password:</h:outputLabel>
            </div>
            <div>
  -            <h:inputSecret id="password" value="#{loginAction.password}" size="15" maxlength="15"/>
  -            <h:commandButton value="Login" action="#{loginAction.login}"/>
  +            <h:inputSecret id="password" 
  +                        value="#{loginAction.password}" 
  +                         size="15" 
  +                    maxlength="15"/>
  +            <h:commandButton value="Login"/>
               <span class="errors"><h:message for="password"/></span>
               <span class="errors"><h:messages globalOnly="true"/></span>
            </div>
  
  
  
  1.10      +4 -1      jboss-seam/examples/blog/view/post.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: post.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/view/post.xhtml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- post.xhtml	2 Oct 2006 18:16:25 -0000	1.9
  +++ post.xhtml	18 Dec 2006 16:50:13 -0000	1.10
  @@ -10,6 +10,9 @@
   <ui:define name="content">
      <div class="blogEntry">
         <h:form>
  +      
  +         <h:messages globalOnly="true" styleClass="errors"/>
  +         
            <f:facet name="afterInvalidField">
               <s:span>
                  &#160;Error:&#160;
  @@ -56,7 +59,7 @@
            </s:validateAll>
            
            <div>
  -            <h:commandButton value="Post" action="#{postAction.post}"/>
  +            <h:commandButton value="Post"/>
            </div>
   
         </h:form>
  
  
  


From c53 at fullmailmarket.com  Mon Dec 18 11:50:25 2006
From: c53 at fullmailmarket.com (FonoIP.com)
Date: Mon, 18 Dec 2006 13:50:25 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Telefon=EDa_IP_al_alcance_de_TODOS!?=
Message-ID: <200612181650.kBIGoUB2001708@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061218/97d3224f/attachment.html 

From gavin.king at jboss.com  Mon Dec 18 11:50:13 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 11:50:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/WEB-INF  ...
Message-ID: <E1GwLgr-00054L-Mo@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 11:50:13

  Modified:    examples/blog/resources/WEB-INF  pages.xml
  Log:
  transparent navigation
  
  Revision  Changes    Path
  1.6       +42 -5     jboss-seam/examples/blog/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/WEB-INF/pages.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- pages.xml	10 Nov 2006 19:07:54 -0000	1.5
  +++ pages.xml	18 Dec 2006 16:50:13 -0000	1.6
  @@ -5,15 +5,52 @@
   <pages>
   
      <page view-id="/search.xhtml">
  -      <param name="searchPattern" value="#{searchService.searchPattern}"/>
  +   
  +      <param name="searchPattern" 
  +            value="#{searchService.searchPattern}"/>
  +            
      </page>
   
  -   <page view-id="/entry.xhtml" action="#{entryAction.loadBlogEntry(blogEntry.id)}">
  -      <param name="blogEntryId" value="#{blogEntry.id}"/>
  +   <page view-id="/entry.xhtml"> 
  +   
  +      <param name="blogEntryId" 
  +            value="#{blogEntry.id}"/>
  +            
  +      <action execute="#{entryAction.loadBlogEntry(blogEntry.id)}"/>
  +      
      </page>
   
  -   <page view-id="/post.xhtml" action="#{loginAction.challenge}"/>
  +   <page view-id="/post.xhtml"> 
  +   
  +      <action execute="#{loginAction.challenge}"/>
  +      
  +      <action execute="#{postAction.post}"
  +                   if="#{validation.succeeded}"/>
  +                   
  +      <action execute="#{postAction.invalid}"
  +                   if="#{validation.failed}"/>
  +      
  +      <action-navigation from-action="#{postAction.post}">
  +         <redirect view-id="/index.xhtml"/>
  +      </action-navigation>
   
  -   <page view-id="*" action="#{blog.hitCount.hit}"/>
  +   </page>
  +   
  +   <page view-id="/login.xhtml">
  +   
  +      <action execute="#{loginAction.login}"
  +                   if="#{validation.succeeded}"/>
  +                   
  +      <action-navigation>
  +         <outcome if="#{loginAction.loggedIn}">
  +            <redirect view-id="/post.xhtml"/>
  +         </outcome>
  +      </action-navigation>
  +      
  +   </page>
  +
  +   <page view-id="*">
  +      <action execute="#{blog.hitCount.hit}"/>
  +   </page>
   
   </pages>
  \ No newline at end of file
  
  
  


From trudfs78gfsd at graffiti.net  Mon Dec 18 12:00:37 2006
From: trudfs78gfsd at graffiti.net (trudfs78gfsd at graffiti.net)
Date: Mon, 18 Dec 2006 12:00:37 -0500
Subject: [jboss-cvs] =?utf-8?b?wpPDgcKVw4rCgsOFwoLCssKIw4TCk8OgwoLCs8KC?=
	=?utf-8?b?wrnCgsOEwpLCuMKCwqvCgsOcwoLCt8KBQg==?=
Message-ID: 20061219022544.60398mail@mail.ryeyjsnsajensbdbeyeterisksmsnasusajsh.com

?????l???`?Z???u???l?????????????l?????????????l?C?T?C?g?I?I

?@?@?@?@?@?@???S???????S???????????p??????????

                 ?@?????S??????????
?@?@?@?@?@?@?@?@?@?@??????????????

???c???@http://pakopako.jp/?oa12wc01  ???c??


 ?????????????Z?t?????W?I?t?????W?I???????????W?I????????????

?@?????????????S?????????p???????I???A?|?A???n?????????O??

?@?@?@?@???V?????????I????????????????????????????

?@?@?@?@?@?@?@?@?@ ?????S??????????
?@?@?@?@?@?@?@?@?@?@??????????????

???c???@http://pakopako.jp/?oa12wc01 ???c??





From gavin.king at jboss.com  Mon Dec 18 12:55:44 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 12:55:44 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GwMiG-0006Fs-RE@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 12:55:44

  Modified:    examples/booking/resources/WEB-INF  pages.xml
  Log:
  minor
  
  Revision  Changes    Path
  1.11      +6 -2      jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- pages.xml	18 Dec 2006 15:42:13 -0000	1.10
  +++ pages.xml	18 Dec 2006 17:55:44 -0000	1.11
  @@ -6,6 +6,9 @@
   
       <page view-id="/register.xhtml">
       
  +        <action if="#{validation.failed}"
  +           execute="#{register.invalid}"/>
  +    
           <action-navigation>
               <outcome if="#{register.registered}">
                   <redirect view-id="/home.xhtml"/>
  @@ -34,8 +37,9 @@
           
       </page>
   
  -    <page view-id="/main.xhtml" 
  -          action="#{login.validateLogin}">
  +    <page view-id="/main.xhtml">
  +    
  +        <action execute="#{login.validateLogin}"/>
           
           <action-navigation from-action="#{login.validateLogin}">
               <outcome if="#{not login.loggedIn}">
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:09:59 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:09:59 -0500
Subject: [jboss-cvs] JBossAS SVN: r59084 -
	trunk/server/src/main/org/jboss/deployment
Message-ID: <E1GwMw3-0006cu-Bp@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-18 13:09:57 -0500 (Mon, 18 Dec 2006)
New Revision: 59084

Modified:
   trunk/server/src/main/org/jboss/deployment/ClientDeployer.java
Log:
Ignore deploy/undeploy if the unit is a component

Modified: trunk/server/src/main/org/jboss/deployment/ClientDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/ClientDeployer.java	2006-12-18 16:03:12 UTC (rev 59083)
+++ trunk/server/src/main/org/jboss/deployment/ClientDeployer.java	2006-12-18 18:09:57 UTC (rev 59084)
@@ -95,10 +95,9 @@
          try
          {
             Element root = DOMUtils.parse(dd.openStream());
-            accepts = true;
+            // If this is javaee, it should be processed by another deployer
             String namespaceURI = root.getNamespaceURI();
-            // If this is javaee, it should be processed by another deployer
-            accepts = !"http://java.sun.com/xml/ns/javaee".equals(namespaceURI);
+            accepts = "http://java.sun.com/xml/ns/javaee".equals(namespaceURI) == false;
             if (accepts == false)
                log.debug("Ignore application-client.xml with namespace: " + namespaceURI);
          }
@@ -114,7 +113,8 @@
    @Override
    public void deploy(DeploymentUnit unit) throws org.jboss.deployers.spi.DeploymentException
    {
-      if (accepts(unit))
+      boolean isComponent = unit.getDeploymentContext().isComponent();
+      if (isComponent == false && accepts(unit))
       {
          // Create the resource class loader
          unit.createClassLoader(new RootURLClassLoaderFactory(unit));
@@ -137,10 +137,11 @@
    @Override
    public void undeploy(DeploymentUnit unit)
    {
-      // Teardown the JNDI context
+      boolean isComponent = unit.getDeploymentContext().isComponent();
       ClientMetaData metaData = unit.getAttachment(ClientMetaData.class);
-      if (metaData != null)
+      if (isComponent == false && metaData != null)
       {
+         // Teardown the JNDI context
          String appClientName = metaData.getJndiName();
          log.info("Removing client ENC from: " + appClientName);
          try



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:14:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:14:57 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1811 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/util src/main/org/jboss/messaging/util
	tests/src/org/jboss/test/messaging/util
Message-ID: <E1GwN0r-0006iN-4g@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-18 13:14:53 -0500 (Mon, 18 Dec 2006)
New Revision: 1811

Added:
   trunk/src/main/org/jboss/messaging/util/Valve.java
Removed:
   trunk/src/main/org/jboss/jms/util/Valve.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Log:
moving this class to another package

Modified: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-18 13:19:04 UTC (rev 1810)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-18 18:14:53 UTC (rev 1811)
@@ -27,13 +27,12 @@
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.util.Valve;
+import org.jboss.messaging.util.Valve;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.CannotConnectException;
 import org.jboss.remoting.ConnectionListener;
 import org.jboss.remoting.Client;
 import java.io.IOException;
-import javax.jms.JMSException;
 
 /**
  * This aspect will intercept failures from any HA object.

Deleted: trunk/src/main/org/jboss/jms/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-18 13:19:04 UTC (rev 1810)
+++ trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-18 18:14:53 UTC (rev 1811)
@@ -1,158 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.jms.util;
-
-import org.jboss.logging.Logger;
-
-
-/**
- * This class is used to guarantee only one thread will be performing a given function, and if any other
- * thread tries to execute the same functionality it will just ignored
- * <pre>
-     Valve valve = new Valve();
-        if (valve.open())
-        {
-             try
-             {
-                doSomething();
-             }
-             finally
-             {
-                valve.close();
-             }
-        }
-        else
-        {
-             System.out.println("Nothing to be done
-        }
-  </pre>
-
-   <p>Notice that you can call close only once, so only call close if you were able to open the valve.</p>
-   <p>After its usage if you decide to reset you should just create a new Valve in a safe synchronized block, so
-        if any other thread still using the variable you do it in a safe way </p>
-
- * @see org.jboss.test.messaging.util.VeryBasicValveTest
- * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
- *  */
-public class Valve
-{
-   private static final Logger log = Logger.getLogger(Valve.class);
-   private boolean trace = log.isTraceEnabled();
-
-   boolean opened;
-   boolean closed;
-
-   Thread threadOwner;
-
-   int refereceCountOpen=0;
-
-
-   public synchronized boolean isOpened()
-   {
-      return opened;
-   }
-
-   /** If the Valve is opened, will wait until the valve is closed */
-   public synchronized boolean isOpened(boolean wait) throws Exception
-   {
-      if (wait && opened)
-      {
-         if (!closed && threadOwner != Thread.currentThread())
-         {
-            if (trace) log.trace("threadOwner= " + threadOwner + " and currentThread=" + Thread.currentThread());
-            if (trace) log.trace("Waiting valve to be closed");
-            this.wait();
-            if (trace) log.trace("Valve was closed");
-         }
-         else
-         {
-            if (trace) log.trace("This is ThreadOwner, so Valve won't wait");
-         }
-         return opened;
-      }
-      else
-      {
-         return false;
-      }
-
-   }
-
-   public boolean open() throws Exception
-   {
-      return open(true);
-   }
-
-   public synchronized boolean open(boolean wait) throws Exception
-   {
-      if (threadOwner==Thread.currentThread())
-      {
-         if (trace) log.trace("Valve was opened again by thread owner");
-         refereceCountOpen++;
-         return true;
-      }
-      // already opened? then needs to wait to be closed
-      if (opened)
-      {
-         if (trace) log.trace("Valve being opened and time.wait");
-         // if not closed yet, will wait to be closed
-         if (!closed)
-         {
-            if (wait)
-            {
-               this.wait();
-            }
-         }
-         return false;
-      } else
-      {
-         if (trace) log.trace("Valve being opened and this thread is the owner for this lock");
-         refereceCountOpen++;
-         opened = true;
-         threadOwner = Thread.currentThread();
-         return true;
-      }
-   }
-
-   public synchronized void close()
-   {
-      if (!opened)
-      {
-         throw new IllegalStateException("Open must be called first");
-      }
-      if (closed)
-      {
-         log.warn("Valve was already closed", new Exception());
-      }
-      refereceCountOpen--;
-      if (refereceCountOpen==0)
-      {
-         if (trace) log.trace("Closing Valve");
-         closed = true;
-         notifyAll();
-      }
-      else
-      {
-         if (trace) log.trace("Valve.close called but there referenceCountOpen=" + refereceCountOpen);
-      }
-   }
-}

Copied: trunk/src/main/org/jboss/messaging/util/Valve.java (from rev 1810, trunk/src/main/org/jboss/jms/util/Valve.java)
===================================================================
--- trunk/src/main/org/jboss/jms/util/Valve.java	2006-12-18 13:19:04 UTC (rev 1810)
+++ trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-18 18:14:53 UTC (rev 1811)
@@ -0,0 +1,158 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.messaging.util;
+
+import org.jboss.logging.Logger;
+
+
+/**
+ * This class is used to guarantee only one thread will be performing a given function, and if any other
+ * thread tries to execute the same functionality it will just ignored
+ * <pre>
+     Valve valve = new Valve();
+        if (valve.open())
+        {
+             try
+             {
+                doSomething();
+             }
+             finally
+             {
+                valve.close();
+             }
+        }
+        else
+        {
+             System.out.println("Nothing to be done
+        }
+  </pre>
+
+   <p>Notice that you can call close only once, so only call close if you were able to open the valve.</p>
+   <p>After its usage if you decide to reset you should just create a new Valve in a safe synchronized block, so
+        if any other thread still using the variable you do it in a safe way </p>
+
+ * @see org.jboss.test.messaging.util.VeryBasicValveTest
+ * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ *  */
+public class Valve
+{
+   private static final Logger log = Logger.getLogger(Valve.class);
+   private boolean trace = log.isTraceEnabled();
+
+   boolean opened;
+   boolean closed;
+
+   Thread threadOwner;
+
+   int refereceCountOpen=0;
+
+
+   public synchronized boolean isOpened()
+   {
+      return opened;
+   }
+
+   /** If the Valve is opened, will wait until the valve is closed */
+   public synchronized boolean isOpened(boolean wait) throws Exception
+   {
+      if (wait && opened)
+      {
+         if (!closed && threadOwner != Thread.currentThread())
+         {
+            if (trace) log.trace("threadOwner= " + threadOwner + " and currentThread=" + Thread.currentThread());
+            if (trace) log.trace("Waiting valve to be closed");
+            this.wait();
+            if (trace) log.trace("Valve was closed");
+         }
+         else
+         {
+            if (trace) log.trace("This is ThreadOwner, so Valve won't wait");
+         }
+         return opened;
+      }
+      else
+      {
+         return false;
+      }
+
+   }
+
+   public boolean open() throws Exception
+   {
+      return open(true);
+   }
+
+   public synchronized boolean open(boolean wait) throws Exception
+   {
+      if (threadOwner==Thread.currentThread())
+      {
+         if (trace) log.trace("Valve was opened again by thread owner");
+         refereceCountOpen++;
+         return true;
+      }
+      // already opened? then needs to wait to be closed
+      if (opened)
+      {
+         if (trace) log.trace("Valve being opened and time.wait");
+         // if not closed yet, will wait to be closed
+         if (!closed)
+         {
+            if (wait)
+            {
+               this.wait();
+            }
+         }
+         return false;
+      } else
+      {
+         if (trace) log.trace("Valve being opened and this thread is the owner for this lock");
+         refereceCountOpen++;
+         opened = true;
+         threadOwner = Thread.currentThread();
+         return true;
+      }
+   }
+
+   public synchronized void close()
+   {
+      if (!opened)
+      {
+         throw new IllegalStateException("Open must be called first");
+      }
+      if (closed)
+      {
+         log.warn("Valve was already closed", new Exception());
+      }
+      refereceCountOpen--;
+      if (refereceCountOpen==0)
+      {
+         if (trace) log.trace("Closing Valve");
+         closed = true;
+         notifyAll();
+      }
+      else
+      {
+         if (trace) log.trace("Valve.close called but there referenceCountOpen=" + refereceCountOpen);
+      }
+   }
+}

Modified: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-18 13:19:04 UTC (rev 1810)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-18 18:14:53 UTC (rev 1811)
@@ -24,7 +24,7 @@
 
 import junit.framework.TestCase;
 import org.jboss.logging.Logger;
-import org.jboss.jms.util.Valve;
+import org.jboss.messaging.util.Valve;
 
 /**
  * This verifies the very basic functionality of ConnectionState.Valve.



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:36:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:36:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r59085 -
	trunk/server/src/main/org/jboss/ejb/plugins
Message-ID: <E1GwNM3-000732-7F@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 13:36:50 -0500 (Mon, 18 Dec 2006)
New Revision: 59085

Modified:
   trunk/server/src/main/org/jboss/ejb/plugins/SecurityInterceptor.java
Log:
add a try/finally block around the context call subject retrieval

Modified: trunk/server/src/main/org/jboss/ejb/plugins/SecurityInterceptor.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/SecurityInterceptor.java	2006-12-18 18:09:57 UTC (rev 59084)
+++ trunk/server/src/main/org/jboss/ejb/plugins/SecurityInterceptor.java	2006-12-18 18:36:50 UTC (rev 59085)
@@ -26,7 +26,7 @@
 import org.jboss.metadata.ApplicationMetaData;
 import org.jboss.metadata.AssemblyDescriptorMetaData;
 import org.jboss.metadata.BeanMetaData;
-import org.jboss.metadata.SecurityIdentityMetaData;  
+import org.jboss.metadata.SecurityIdentityMetaData;   
 import org.jboss.security.AuthenticationManager;
 import org.jboss.security.AuthorizationManager;
 import org.jboss.security.RealmMapping;
@@ -110,7 +110,7 @@
     */
    protected String appSecurityDomain = null; 
    //Fallback Security Domain
-   protected String defaultAuthorizationSecurityDomain = SecurityConstants.DEFAULT_EJB_APPLICATION_POLICY; 
+   protected String defaultAuthorizationSecurityDomain = SecurityConstants.DEFAULT_EJB_APPLICATION_POLICY;  
     
    /** Called by the super class to set the container to which this interceptor
     belongs. We obtain the security manager and runAs identity to use here.
@@ -152,7 +152,7 @@
          //Authorization Framework changes
          appSecurityDomain = applicationMetaData.getSecurityDomain();
          ejbName = beanMetaData.getEjbName();  
-         ejbCS = container.getBeanClass().getProtectionDomain().getCodeSource();
+         ejbCS = container.getBeanClass().getProtectionDomain().getCodeSource(); 
       }
    }
 
@@ -341,9 +341,16 @@
       * (Get the same behavior as split JaasAuthenticationInterceptor
       * and JaccAuthorizationInterceptor)
       */
-     SecurityActions.pushRunAsIdentity(runAsIdentity);
-     Subject caller = SecurityActions.getContextSubject(); 
-     SecurityActions.popRunAsIdentity();
+     Subject caller = null;
+     try
+     { 
+        SecurityActions.pushRunAsIdentity(runAsIdentity);
+        caller = SecurityActions.getContextSubject();
+     }
+     finally
+     { 
+        SecurityActions.popRunAsIdentity();
+     }   
      return caller;
   }
   



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:37:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:37:26 -0500
Subject: [jboss-cvs] JBossAS SVN: r59086 -
	trunk/server/src/main/org/jboss/ejb/plugins
Message-ID: <E1GwNMc-00073M-L6@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 13:37:25 -0500 (Mon, 18 Dec 2006)
New Revision: 59086

Modified:
   trunk/server/src/main/org/jboss/ejb/plugins/StatefulSessionInstanceInterceptor.java
Log:
check if there was really a push of a null subject context

Modified: trunk/server/src/main/org/jboss/ejb/plugins/StatefulSessionInstanceInterceptor.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/StatefulSessionInstanceInterceptor.java	2006-12-18 18:36:50 UTC (rev 59085)
+++ trunk/server/src/main/org/jboss/ejb/plugins/StatefulSessionInstanceInterceptor.java	2006-12-18 18:37:25 UTC (rev 59086)
@@ -212,6 +212,7 @@
       EnterpriseContext ctx = null;
       
       BeanLock lock = container.getLockManager().getLock(methodID);
+      boolean callerRunAsIdentityPresent = SecurityActions.peekRunAsIdentity() != null;
       try
       {
          /* The security context must be established before the cache
@@ -225,7 +226,7 @@
          of the ejb spec requirement that runtime exceptions should invalidate
          the session.
           */
-         if(SecurityActions.peekRunAsIdentity() == null)
+         if(!callerRunAsIdentityPresent)
             SecurityActions.pushSubjectContext(mi.getPrincipal(), mi.getCredential(), null);
 
          lock.sync();
@@ -317,7 +318,7 @@
          }
 
          // Set the current security information
-         ctx.setPrincipal(mi.getPrincipal());
+         ctx.setPrincipal(mi.getPrincipal()); 
 
          if (ejbTimeout.equals(mi.getMethod()))
             AllowedOperationsAssociation.pushInMethodFlag(IN_EJB_TIMEOUT);
@@ -390,7 +391,8 @@
       finally
       {
          container.getLockManager().removeLockRef(lock.getId());
-         SecurityActions.popSubjectContext();
+         if(!callerRunAsIdentityPresent)
+           SecurityActions.popSubjectContext();
       }
    }
    



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:41:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:41:49 -0500
Subject: [jboss-cvs] JBossAS SVN: r59087 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname
Message-ID: <E1GwNQr-00078M-Gi@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-18 13:41:46 -0500 (Mon, 18 Dec 2006)
New Revision: 59087

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java
Log:
JBAS-3615, jdk5 accepts empty objectname key, fixed in jdk6

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java	2006-12-18 18:37:25 UTC (rev 59086)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java	2006-12-18 18:41:46 UTC (rev 59087)
@@ -37,11 +37,12 @@
  * <p/>
  * This suite has twice as many tests (about 60) as my last
  * testcase - and for that it caught one extra bug for me.
- *
- * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>.
+ * 
+ * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision:$
  */
-public class MalformedTestCase
-        extends TestSuite
+public class MalformedTestCase extends TestSuite
 {
    public static final String GOOD_DOMAIN = "domain";
    public static final String GOOD_KEY = "key1";
@@ -64,7 +65,7 @@
    // pre-cooked name strings dealing with structural malformations
    public static final String[] BAD_FULLNAMES = {
       "domain:key=val,key=val2", // duplicate key
-      "domain:=,foo=bar", // both key and value empty, fails on jdk5, sun-bug #338585 
+      "domain:=val,foo=bar", // JBAS-3615, empty key
       "domain:key=val,,foo=bar", // missing kvp in middle
       "domain:,key=val,foo=bar", // missing kvp at beginning
       "domain:key=val,foo=bar,", // missing kvp at end



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:42:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:42:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r59088 -
	branches/Branch_4_0/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname
Message-ID: <E1GwNRk-00078f-Qy@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-18 13:42:42 -0500 (Mon, 18 Dec 2006)
New Revision: 59088

Modified:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java
Log:
JBAS-3615, jdk5 accepts empty objectname key, fixed in jdk6

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java	2006-12-18 18:41:46 UTC (rev 59087)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java	2006-12-18 18:42:42 UTC (rev 59088)
@@ -37,11 +37,12 @@
  * <p/>
  * This suite has twice as many tests (about 60) as my last
  * testcase - and for that it caught one extra bug for me.
- *
- * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>.
+ * 
+ * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision$
  */
-public class MalformedTestCase
-        extends TestSuite
+public class MalformedTestCase extends TestSuite
 {
    public static final String GOOD_DOMAIN = "domain";
    public static final String GOOD_KEY = "key1";
@@ -64,7 +65,7 @@
    // pre-cooked name strings dealing with structural malformations
    public static final String[] BAD_FULLNAMES = {
       "domain:key=val,key=val2", // duplicate key
-      "domain:=,foo=bar", // both key and value empty, fails on jdk5, sun-bug #338585 
+      "domain:=val,foo=bar", // JBAS-3615, empty key
       "domain:key=val,,foo=bar", // missing kvp in middle
       "domain:,key=val,foo=bar", // missing kvp at beginning
       "domain:key=val,foo=bar,", // missing kvp at end



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 13:43:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 13:43:28 -0500
Subject: [jboss-cvs] JBossAS SVN: r59089 -
	trunk/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname
Message-ID: <E1GwNSS-00078y-AQ@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-18 13:43:26 -0500 (Mon, 18 Dec 2006)
New Revision: 59089

Modified:
   trunk/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java
Log:
JBAS-3615, jdk5 accepts empty objectname key, fixed in jdk6

Modified: trunk/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java	2006-12-18 18:42:42 UTC (rev 59088)
+++ trunk/testsuite/src/main/org/jboss/test/jbossmx/compliance/objectname/MalformedTestCase.java	2006-12-18 18:43:26 UTC (rev 59089)
@@ -1,24 +1,24 @@
 /*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.
-  */
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.test.jbossmx.compliance.objectname;
 
 import junit.framework.Test;
@@ -37,11 +37,12 @@
  * <p/>
  * This suite has twice as many tests (about 60) as my last
  * testcase - and for that it caught one extra bug for me.
- *
- * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>.
+ * 
+ * @author <a href="mailto:trevor at protocool.com">Trevor Squires</a>
+ * @author <a href="mailto:dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision$
  */
-public class MalformedTestCase
-        extends TestSuite
+public class MalformedTestCase extends TestSuite
 {
    public static final String GOOD_DOMAIN = "domain";
    public static final String GOOD_KEY = "key1";
@@ -64,7 +65,7 @@
    // pre-cooked name strings dealing with structural malformations
    public static final String[] BAD_FULLNAMES = {
       "domain:key=val,key=val2", // duplicate key
-      "domain:=,foo=bar", // both key and value empty, fails on jdk5, sun-bug #338585 
+      "domain:=val,foo=bar", // JBAS-3615, empty key
       "domain:key=val,,foo=bar", // missing kvp in middle
       "domain:,key=val,foo=bar", // missing kvp at beginning
       "domain:key=val,foo=bar,", // missing kvp at end



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 15:08:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 15:08:22 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1812 - in trunk:
	src/main/org/jboss/jms/client
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/remoting tests
	tests/src/org/jboss/test/messaging/jms/crash
Message-ID: <E1GwOmc-0000Gx-Hz@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-18 15:08:15 -0500 (Mon, 18 Dec 2006)
New Revision: 1812

Modified:
   trunk/src/main/org/jboss/jms/client/JBossConnection.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/CreateTwoClientOnServerCommand.java
Log:
Fix tests



Modified: trunk/src/main/org/jboss/jms/client/JBossConnection.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnection.java	2006-12-18 18:14:53 UTC (rev 1811)
+++ trunk/src/main/org/jboss/jms/client/JBossConnection.java	2006-12-18 20:08:15 UTC (rev 1812)
@@ -45,10 +45,12 @@
 import javax.jms.XATopicSession;
 
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.util.ThreadContextClassLoaderChanger;
+import org.jboss.logging.Logger;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -64,6 +66,9 @@
 
    // Constants -----------------------------------------------------
    private static final long serialVersionUID = -3715868654823177898L;
+   
+   private static final Logger log = Logger.getLogger(JBossConnection.class);
+   
 
    static final int TYPE_GENERIC_CONNECTION = 0;
    static final int TYPE_QUEUE_CONNECTION = 1;
@@ -225,7 +230,7 @@
    public String getRemotingClientSessionId()
    {
       ConnectionState state = (ConnectionState)((ClientConnectionDelegate)delegate).getState();
-
+      
       return state.getRemotingConnection().getInvokingClient().getSessionId();
    }
 

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-18 18:14:53 UTC (rev 1811)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-18 20:08:15 UTC (rev 1812)
@@ -130,19 +130,20 @@
          // delivery count information from client to server. We could just do this on the server but
          // we would lose delivery count info.
                   
+         // CLIENT_ACKNOWLEDGE cannot be used with MDBs so is always safe to cancel on this session                  
+         
          List cancels = new ArrayList();
          
          for(Iterator i = state.getClientAckList().iterator(); i.hasNext(); )
          {
             DeliveryInfo ack = (DeliveryInfo)i.next();            
+            
             DefaultCancel cancel = new DefaultCancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
             cancels.add(cancel);
          }
          
          if (!cancels.isEmpty())
-         {
-            //CLIENT_ACKNOWLEDGE cannot be used with MDBs so is always safe to cancel on this session
-            
+         {            
             del.cancelDeliveries(cancels);            
          }
          
@@ -181,6 +182,12 @@
          
          if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack list"); }
          
+         //Sanity check
+         if (info.getConnectionConsumerSession() != null)
+         {
+            throw new IllegalStateException("CLIENT_ACKNOWLEDGE cannot be used with a connection consumer");
+         }
+                  
          state.getClientAckList().add(info);
          
          //We can return immediately
@@ -193,6 +200,7 @@
          //We collect the single acknowledgement in the state.
          //Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE
          //Also XA sessions not enlisted in a global tx are treated as AUTO_ACKNOWLEDGE
+                  
          
          if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack member"); }
          

Modified: trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-18 18:14:53 UTC (rev 1811)
+++ trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-18 20:08:15 UTC (rev 1812)
@@ -169,7 +169,7 @@
       client.removeListener(callbackManager);
       client.disconnect();
 
-      client=null;
+      client = null;
       log.debug(this + " closed");
    }
 

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-18 18:14:53 UTC (rev 1811)
+++ trunk/tests/build.xml	2006-12-18 20:08:15 UTC (rev 1812)
@@ -799,7 +799,6 @@
 
    </target>
 
-
    <target name="crash-tests" depends="tests-jar, prepare-testdirs, clear-test-logs"
       description="Runs crash tests">
 
@@ -847,7 +846,6 @@
       <!--
           ClientCrashTwoConnectionsTest over "http"
       -->
-
       <antcall target="start-rmi-server">
          <param name="test.remoting" value="http"/>
          <param name="remote.server.test.logfile.suffix" value="remote-crash"/>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-18 18:14:53 UTC (rev 1811)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-18 20:08:15 UTC (rev 1812)
@@ -120,6 +120,9 @@
       log.info("server(1) = " + remotingSessionId[1]);
       log.info("we have = " + ((SimpleConnectionManager)cm).getClients().size() + " clients registered on SimpleconnectionManager");
       
+      assertFalse(cm.containsSession(remotingSessionId[0]));            
+      assertTrue(cm.containsSession(remotingSessionId[1]));          
+      
       // Now we should have a client connection from the remote server to the local server
       remoteServer.kill();
       log.info("killed remote server");
@@ -129,7 +132,7 @@
            
       // See if we still have a connection with this id
       
-      //Connection state shouldn't have been cleared up by now
+      //Connection state should have been cleared up by now
       assertFalse(cm.containsSession(remotingSessionId[0]));            
       assertFalse(cm.containsSession(remotingSessionId[1]));            
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/CreateTwoClientOnServerCommand.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/CreateTwoClientOnServerCommand.java	2006-12-18 18:14:53 UTC (rev 1811)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/CreateTwoClientOnServerCommand.java	2006-12-18 20:08:15 UTC (rev 1812)
@@ -29,6 +29,8 @@
 import javax.jms.Topic;
 
 import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.container.SessionAspect;
+import org.jboss.logging.Logger;
 import org.jboss.test.messaging.tools.jmx.rmi.Command;
 
 /**
@@ -45,6 +47,8 @@
 {
    private static final long serialVersionUID = -997724797145152821L;
    
+   private static final Logger log = Logger.getLogger(CreateTwoClientOnServerCommand.class);
+      
    private ConnectionFactory cf;
    
    private boolean retainReference;
@@ -81,11 +85,12 @@
       conn2.setClientID("test2");
       conn2.start();
 
-      conn1.close();
-      
       String arrays[] = new String[2];
       arrays[0] = ((JBossConnection)conn1).getRemotingClientSessionId();
       arrays[1] = ((JBossConnection)conn2).getRemotingClientSessionId();
+      
+      conn1.close();
+      
 
       // Return the remoting client session id for the connection
       return arrays;      



From brian.stansberry at jboss.com  Mon Dec 18 15:09:41 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Mon, 18 Dec 2006 15:09:41 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GwOnt-0000HO-3h@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/18 15:09:41

  Modified:    JBossCache  Tag: Branch_JBossCache_1_4_0 build.xml
  Log:
  Use JG 2.2.7 in the interoptests
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.119.2.19 +16 -2     JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.119.2.18
  retrieving revision 1.119.2.19
  diff -u -b -r1.119.2.18 -r1.119.2.19
  --- build.xml	16 Dec 2006 13:13:03 -0000	1.119.2.18
  +++ build.xml	18 Dec 2006 20:09:40 -0000	1.119.2.19
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.119.2.18 2006/12/16 13:13:03 ptsekov Exp $ -->
  +<!-- $Id: build.xml,v 1.119.2.19 2006/12/18 20:09:40 bstansberry Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -140,15 +140,22 @@
         <pathelement location="${compiletest.dir}"/>
         <fileset dir="${lib.dir}">
            <include name="*.jar"/>
  +     	 <exclude name="jgroups.jar"/>
         </fileset>
         <fileset dir="${output.interop.dir}">
            <include name="*.jar"/>
         </fileset>
      </path>
   
  +   <!-- NOTE: replaces the std jgroups version with 2.2.7.  This classpath
  +        is only meant for use in the interoptests target. -->
      <path id="current.version.classpath">
         <fileset dir="${lib.dir}">
            <include name="*.jar"/>
  +      	 <exclude name="jgroups.jar"/>
  +      </fileset>
  +      <fileset dir="${output.interop.dir}">
  +         <include name="jgroups.jar"/>
         </fileset>
         <fileset dir="${sleepycat.dir}">
            <include name="*.jar"/>
  @@ -783,8 +790,15 @@
   
         <!-- Download the cache version against which we check interop -->
         <mkdir dir="${output.interop.dir}"/>
  +   	
         <get dest="${output.interop.dir}/jboss-cache.jar"
              src="http://repository.jboss.com/jboss/cache/1.2.3.1/lib/jboss-cache.jar" verbose="true"/>
  +   	  <!-- 
  +   	       In 1.4.1 we moved to JG 2.4.1 by default, so we need to bring down the old jgroups as well.
  +   	       The current.version.classpath and previous.version.classpath will use the old jgroups.
  +   	  -->
  +      <get dest="${output.interop.dir}/jgroups.jar"
  +           src="http://repository.jboss.com/jgroups/2.2.7/lib/jgroups.jar" verbose="true"/>
   
         <start-interop-target name="previous version" conf="META-INF/interopPrevSync-service.xml"
                               classpath="previous.version.classpath"/>
  
  
  


From gavin.king at jboss.com  Mon Dec 18 15:23:08 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 15:23:08 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GwP0u-0000Vj-Hl@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 15:23:08

  Modified:    src/main/org/jboss/seam/core  BusinessProcess.java
  Log:
  javadoc
  
  Revision  Changes    Path
  1.16      +8 -3      jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcess.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- BusinessProcess.java	16 Dec 2006 16:05:20 -0000	1.15
  +++ BusinessProcess.java	18 Dec 2006 20:23:08 -0000	1.16
  @@ -121,6 +121,11 @@
         Events.instance().raiseEvent("org.jboss.seam.createProcess." + processDefinitionName);
      }
   
  +   /**
  +    * Start the current task, using the current actor id
  +    * 
  +    * @see Actor
  +    */
      public void startTask()
      {
         String actorId = Actor.instance().getId();
  @@ -138,9 +143,9 @@
      }
   
      /**
  -    * End a task, via the given transition. If no transition name is given,
  -    * check the Transition component for a transition, or use the default
  -    * transition.
  +    * End the current task, via the given transition. If no transition name 
  +    * is given, check the Transition component for a transition, or use the 
  +    * default transition.
       * 
       * @param transitionName the jBPM transition name, or null
       */
  
  
  


From gavin.king at jboss.com  Mon Dec 18 15:23:08 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 15:23:08 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GwP0u-0000Vq-L1@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 15:23:08

  Modified:    src/main/org/jboss/seam/interceptors 
                        BusinessProcessInterceptor.java
  Log:
  javadoc
  
  Revision  Changes    Path
  1.48      +3 -3      jboss-seam/src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcessInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -b -r1.47 -r1.48
  --- BusinessProcessInterceptor.java	16 Dec 2006 02:58:11 -0000	1.47
  +++ BusinessProcessInterceptor.java	18 Dec 2006 20:23:08 -0000	1.48
  @@ -13,8 +13,6 @@
   
   import javax.faces.context.FacesContext;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.BeginTask;
   import org.jboss.seam.annotations.CreateProcess;
  @@ -24,12 +22,14 @@
   import org.jboss.seam.annotations.StartTask;
   import org.jboss.seam.core.BusinessProcess;
   import org.jboss.seam.intercept.InvocationContext;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   
   /**
    * Interceptor which handles interpretation of jBPM-related annotations.
    *
    * @author <a href="mailto:steve at hibernate.org">Steve Ebersole </a>
  - * @version $Revision: 1.47 $
  + * @version $Revision: 1.48 $
    */
   @Interceptor(stateless=true,
                around={ValidationInterceptor.class, BijectionInterceptor.class, OutcomeInterceptor.class})
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 16:28:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 16:28:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r59090 -
	branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment
Message-ID: <E1GwQ21-0001dU-88@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 16:28:19 -0500 (Mon, 18 Dec 2006)
New Revision: 59090

Modified:
   branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java
Log:
[JBAOP-330] Infinite loop in ScopedJBossClassPool/ClassPool if a class cannot be found in the discovered pool. Add a threadlocal to make sure that we don't recurse infinitely

Modified: branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java
===================================================================
--- branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java	2006-12-18 18:43:26 UTC (rev 59089)
+++ branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java	2006-12-18 21:28:19 UTC (rev 59090)
@@ -51,6 +51,7 @@
    
    WeakReference repository = null;
    UrlInfo urlInfo;
+   ThreadLocal lastPool = new ThreadLocal();
 
    protected ScopedJBossClassPool(ClassLoader cl, ClassPool src, ScopedClassPoolRepository repository, File tmp, URL tmpURL)
    {
@@ -171,11 +172,24 @@
       try
       {
          ClassPool pool = getCorrectPoolForResource(url);
-         return pool.get(classname);
+         if (pool != lastPool.get())
+         {
+            lastPool.set(pool);
+            return pool.get(classname);
+         }
       }
       catch (NotFoundException e)
       {
       }
+      catch(StackOverflowError e)
+      {
+         throw e;
+      }
+      finally
+      {
+         lastPool.set(null);
+      }
+
       return null;
    }
 



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 16:28:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 16:28:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r59091 -
	branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment
Message-ID: <E1GwQ2b-0001dn-Ml@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 16:28:54 -0500 (Mon, 18 Dec 2006)
New Revision: 59091

Modified:
   branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java
Log:
[JBAOP-330] Infinite loop in ScopedJBossClassPool/ClassPool if a class cannot be found in the discovered pool. Add a threadlocal to make sure that we don't recurse infinitely

Modified: branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java
===================================================================
--- branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java	2006-12-18 21:28:19 UTC (rev 59090)
+++ branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java	2006-12-18 21:28:54 UTC (rev 59091)
@@ -51,6 +51,7 @@
    
    WeakReference repository = null;
    UrlInfo urlInfo;
+   ThreadLocal lastPool = new ThreadLocal();
 
    protected ScopedJBossClassPool(ClassLoader cl, ClassPool src, ScopedClassPoolRepository repository, File tmp, URL tmpURL)
    {
@@ -171,11 +172,24 @@
       try
       {
          ClassPool pool = getCorrectPoolForResource(url);
-         return pool.get(classname);
+         if (pool != lastPool.get())
+         {
+            lastPool.set(pool);
+            return pool.get(classname);
+         }
       }
       catch (NotFoundException e)
       {
       }
+      catch(StackOverflowError e)
+      {
+         throw e;
+      }
+      finally
+      {
+         lastPool.set(null);
+      }
+
       return null;
    }
 



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 16:29:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 16:29:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r59092 -
	trunk/aspects/src/main/org/jboss/aop/deployment
Message-ID: <E1GwQ2m-0001e7-Gs@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 16:29:07 -0500 (Mon, 18 Dec 2006)
New Revision: 59092

Modified:
   trunk/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java
Log:
[JBAOP-330] Infinite loop in ScopedJBossClassPool/ClassPool if a class cannot be found in the discovered pool. Add a threadlocal to make sure that we don't recurse infinitely

Modified: trunk/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java
===================================================================
--- trunk/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java	2006-12-18 21:28:54 UTC (rev 59091)
+++ trunk/aspects/src/main/org/jboss/aop/deployment/ScopedJBossClassPool.java	2006-12-18 21:29:07 UTC (rev 59092)
@@ -51,6 +51,7 @@
    
    WeakReference repository = null;
    UrlInfo urlInfo;
+   ThreadLocal lastPool = new ThreadLocal();
 
    protected ScopedJBossClassPool(ClassLoader cl, ClassPool src, ScopedClassPoolRepository repository, File tmp, URL tmpURL)
    {
@@ -79,16 +80,7 @@
 
    private HeirarchicalLoaderRepository3 getRepository()
    {
-      //FIXME - Once Javassist > 3.3.0 is out use getClassLoader0() and get rid of try/catch
-      ClassLoader cl = null;
-      try
-      {
-         cl =  getClassLoader();
-      }
-      catch (RuntimeException e)
-      {
-         //Ignore, the ScopedClassPoll throws an exception if pool is not associated with a cl
-      }
+      ClassLoader cl = getClassLoader0();
       if (cl != null)
       {
          return (HeirarchicalLoaderRepository3)((RepositoryClassLoader)cl).getLoaderRepository();
@@ -171,11 +163,24 @@
       try
       {
          ClassPool pool = getCorrectPoolForResource(url);
-         return pool.get(classname);
+         if (pool != lastPool.get())
+         {
+            lastPool.set(pool);
+            return pool.get(classname);
+         }
       }
       catch (NotFoundException e)
       {
       }
+      catch(StackOverflowError e)
+      {
+         throw e;
+      }
+      finally
+      {
+         lastPool.set(null);
+      }
+
       return null;
    }
 



From c54 at fullmailmarket.com  Mon Dec 18 16:58:47 2006
From: c54 at fullmailmarket.com (MacStore.cl)
Date: Mon, 18 Dec 2006 18:58:47 -0300
Subject: [jboss-cvs] GANATE UN IPOD NANO 4GB
Message-ID: <200612182158.kBILwrTn010770@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061218/3e955ce2/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:07:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:07:52 -0500
Subject: [jboss-cvs] JBossAS SVN: r59093 -
	branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop
Message-ID: <E1GwQeG-0002SC-Po@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 17:07:50 -0500 (Mon, 18 Dec 2006)
New Revision: 59093

Modified:
   branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/AspectManager.java
   branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/Domain.java
Log:
[JBAOP-331] IgnoreExpressions for a domain should be got from main AspectManager

Modified: branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/AspectManager.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-18 21:29:07 UTC (rev 59092)
+++ branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-18 22:07:50 UTC (rev 59093)
@@ -638,7 +638,6 @@
 
    public ClassPool findClassPool(ClassLoader cl)
    {
-//      System.out.println("------> Calling findClassPool with " + cl);
       if (!(cl instanceof Translatable))
       {
          // findClassPool has problems with boot and system classes.
@@ -722,9 +721,10 @@
    {
       ArrayList ignore = getIgnore();
       if (ignore == null) return false;
-      for (int i = 0; i < ignoreExpressions.length; i++)
+      ClassExpression[] ignoreExprs = getIgnoreExpressions();
+      for (int i = 0; i < ignoreExprs.length; i++)
       {
-         if(ignoreExpressions[i].matches(classname)) return true;
+         if(ignoreExprs[i].matches(classname)) return true;
       }
       return false;
    }
@@ -1979,7 +1979,6 @@
    private boolean copySubDomainsFromQueue(boolean increment)
    {
       boolean copied = false;
-//      System.out.println("Entering " + this + " " + )
       synchronized (subscribedSubDomains)
       {
          if (!increment && subscribedDomainQueueRef > 0) subscribedDomainQueueRef--;

Modified: branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/Domain.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/Domain.java	2006-12-18 21:29:07 UTC (rev 59092)
+++ branches/Branch_AOP_1_5/aop/src/main/org/jboss/aop/Domain.java	2006-12-18 22:07:50 UTC (rev 59093)
@@ -56,6 +56,12 @@
    protected boolean inheritsBindings = false;
 
 
+   public Domain(AspectManager manager, boolean parentFirst)
+   {
+      //Ignore the name - it is used by AOP 2.0
+      this(manager, null, parentFirst);
+   }
+
    public Domain(AspectManager manager, String name, boolean parentFirst)
    {
       this.parent = manager;
@@ -751,7 +757,7 @@
    /** Only set on a per vm basis */
    public ClassExpression[] getIgnoreExpressions()
    {
-      return super.getIgnoreExpressions();
+      return parent.getIgnoreExpressions();
    }
    
    public DynamicAOPStrategy getDynamicAOPStrategy()



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:09:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:09:07 -0500
Subject: [jboss-cvs] JBossAS SVN: r59094 - in projects/aop/trunk/aop: .
	src/main/org/jboss/aop
Message-ID: <E1GwQfT-0002SV-OU@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 17:09:04 -0500 (Mon, 18 Dec 2006)
New Revision: 59094

Modified:
   projects/aop/trunk/aop/.classpath
   projects/aop/trunk/aop/src/main/org/jboss/aop/AspectManager.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/Domain.java
Log:
[JBAOP-331] IgnoreExpressions for a domain should be got from main AspectManager

Modified: projects/aop/trunk/aop/.classpath
===================================================================
--- projects/aop/trunk/aop/.classpath	2006-12-18 22:07:50 UTC (rev 59093)
+++ projects/aop/trunk/aop/.classpath	2006-12-18 22:09:04 UTC (rev 59094)
@@ -2,6 +2,7 @@
 <classpath>
 	<classpathentry excluding="org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java" kind="src" path="src/main"/>
 	<classpathentry kind="src" path="src/test"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/javassist"/>
 	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
@@ -13,7 +14,7 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
-	<classpathentry sourcepath="/javassist" kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar" sourcepath="/javassist"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/AspectManager.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-18 22:07:50 UTC (rev 59093)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-18 22:09:04 UTC (rev 59094)
@@ -731,9 +731,10 @@
    {
       ArrayList ignore = getIgnore();
       if (ignore == null) return false;
-      for (int i = 0; i < ignoreExpressions.length; i++)
+      ClassExpression[] ignoreExprs = getIgnoreExpressions();
+      for (int i = 0; i < ignoreExprs.length; i++)
       {
-         if(ignoreExpressions[i].matches(classname)) return true;
+         if(ignoreExprs[i].matches(classname)) return true;
       }
       return false;
    }

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/Domain.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/Domain.java	2006-12-18 22:07:50 UTC (rev 59093)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/Domain.java	2006-12-18 22:09:04 UTC (rev 59094)
@@ -55,7 +55,6 @@
    protected boolean inheritsDeclarations = true;
    protected boolean inheritsBindings = false;
 
-
    public Domain(AspectManager manager, String name, boolean parentFirst)
    {
       this.parent = manager;
@@ -750,7 +749,7 @@
    /** Only set on a per vm basis */
    public ClassExpression[] getIgnoreExpressions()
    {
-      return super.getIgnoreExpressions();
+      return parent.getIgnoreExpressions();
    }
    
    public DynamicAOPStrategy getDynamicAOPStrategy()



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:10:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:10:34 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59095 - projects/aop/trunk/aop
Message-ID: <E1GwQgs-0002VO-F7@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 17:10:32 -0500 (Mon, 18 Dec 2006)
New Revision: 59095

Modified:
   projects/aop/trunk/aop/.classpath
Log:
Revert


Modified: projects/aop/trunk/aop/.classpath
===================================================================
--- projects/aop/trunk/aop/.classpath	2006-12-18 22:09:04 UTC (rev 59094)
+++ projects/aop/trunk/aop/.classpath	2006-12-18 22:10:32 UTC (rev 59095)
@@ -1,8 +1,8 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-	<classpathentry excluding="org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java" kind="src" path="src/main"/>
+	<classpathentry excluding="org/jboss/aop/AnnotationIntroductionDef.java|org/jboss/aop/Aspect.java|org/jboss/aop/Bind.java|org/jboss/aop/CFlowDef.java|org/jboss/aop/CFlowStackDef.java|org/jboss/aop/DeclareError.java|org/jboss/aop/DeclareWarning.java|org/jboss/aop/DynamicCFlowDef.java|org/jboss/aop/InterceptorDef.java|org/jboss/aop/Introduction.java|org/jboss/aop/Mixin.java|org/jboss/aop/PointcutDef.java|org/jboss/aop/Precedence.java|org/jboss/aop/PrecedenceAdvice.java|org/jboss/aop/PrecedenceInterceptor.java|org/jboss/aop/Prepare.java|org/jboss/aop/TypeDef.java|org/jboss/aop/advice/Scope.java|org/jboss/aop/annotation/AnnotationElement.java|org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java|org/jboss/aspects/Threadbased.java" kind="src" path="src/main"/>
+	<classpathentry kind="src" path="src/jdk15"/>
 	<classpathentry kind="src" path="src/test"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/javassist"/>
 	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
@@ -14,7 +14,7 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar" sourcepath="/javassist"/>
+	<classpathentry sourcepath="/javassist" kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:18:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:18:46 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59096 - tags
Message-ID: <E1GwQoo-0002cA-FB@committer01.frg.pub.inap.atl.jboss.com>

Author: prabhat.jha at jboss.com
Date: 2006-12-18 17:18:45 -0500 (Mon, 18 Dec 2006)
New Revision: 59096

Added:
   tags/EJB3_RC9_Patch_1/
Log:
tagging ejb3 rc9 patch1.

Copied: tags/EJB3_RC9_Patch_1 (from rev 59095, branches/Branch_4_0_EJB3_RC9_Patch_1)



From kkhan at jboss.com  Mon Dec 18 17:18:58 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Mon, 18 Dec 2006 17:18:58 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot/lib     ...
Message-ID: <E1GwQp0-0002cZ-VR@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/18 17:18:58

  Modified:    jboss/aop/snapshot/lib     jboss-aop-jdk50-client.jar
                        jboss-aop-jdk50.jar
                        jrockit-pluggable-instrumentor.jar
                        pluggable-instrumentor.jar
  Log:
  Update snapshot in repository
  
  Revision  Changes    Path
  1.12      +239 -260  repository.jboss.com/jboss/aop/snapshot/lib/jboss-aop-jdk50-client.jar
  
  	<<Binary file>>
  
  
  1.18      +1720 -1770repository.jboss.com/jboss/aop/snapshot/lib/jboss-aop-jdk50.jar
  
  	<<Binary file>>
  
  
  1.9       +19 -19    repository.jboss.com/jboss/aop/snapshot/lib/jrockit-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.10      +15 -17    repository.jboss.com/jboss/aop/snapshot/lib/pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  


From kkhan at jboss.com  Mon Dec 18 17:18:59 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Mon, 18 Dec 2006 17:18:59 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop14/snapshot/lib    ...
Message-ID: <E1GwQp1-0002cj-Uo@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/18 17:18:59

  Modified:    jboss/aop14/snapshot/lib    jboss-aop.jar
                        jdk14-pluggable-instrumentor.jar
                        jrockit-pluggable-instrumentor.jar
  Log:
  Update snapshot in repository
  
  Revision  Changes    Path
  1.14      +1770 -1742repository.jboss.com/jboss/aop14/snapshot/lib/jboss-aop.jar
  
  	<<Binary file>>
  
  
  1.11      +17 -17    repository.jboss.com/jboss/aop14/snapshot/lib/jdk14-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.9       +19 -19    repository.jboss.com/jboss/aop14/snapshot/lib/jrockit-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:19:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:19:57 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59097 - projects/aop/trunk/aop
Message-ID: <E1GwQpx-0002cx-Ub@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 17:19:56 -0500 (Mon, 18 Dec 2006)
New Revision: 59097

Modified:
   projects/aop/trunk/aop/build.xml
Log:
Make version snapshot

Modified: projects/aop/trunk/aop/build.xml
===================================================================
--- projects/aop/trunk/aop/build.xml	2006-12-18 22:18:45 UTC (rev 59096)
+++ projects/aop/trunk/aop/build.xml	2006-12-18 22:19:56 UTC (rev 59097)
@@ -57,7 +57,7 @@
     -->
 
    <target name="configure" unless="configure.disable">
-      <property name="aop.version" value="jboss-aop-2.0.0.alpha2"/>
+      <property name="aop.version" value="jboss-aop-snapshot"/>
       <property name="aop.title" value="JBoss AOP Framework"/>
 
       <!-- =================== -->



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:38:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:38:58 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1813 -
	trunk/src/main/org/jboss/messaging/util
Message-ID: <E1GwR8M-0002vV-Vd@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-18 17:38:57 -0500 (Mon, 18 Dec 2006)
New Revision: 1813

Modified:
   trunk/src/main/org/jboss/messaging/util/Valve.java
Log:
Adding reset method

Modified: trunk/src/main/org/jboss/messaging/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-18 20:08:15 UTC (rev 1812)
+++ trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-18 22:38:57 UTC (rev 1813)
@@ -155,4 +155,16 @@
          if (trace) log.trace("Valve.close called but there referenceCountOpen=" + refereceCountOpen);
       }
    }
+
+   public synchronized void reset()
+   {
+      if (opened && !closed)
+      {
+         close();
+      }
+      opened = false;
+      closed = false;
+      threadOwner = null;
+      refereceCountOpen = 0;
+   }
 }



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:40:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:40:15 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1814 -
	trunk/src/main/org/jboss/messaging/util
Message-ID: <E1GwR9b-0002x3-8U@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-18 17:40:14 -0500 (Mon, 18 Dec 2006)
New Revision: 1814

Modified:
   trunk/src/main/org/jboss/messaging/util/Valve.java
Log:
formatting only

Modified: trunk/src/main/org/jboss/messaging/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-18 22:38:57 UTC (rev 1813)
+++ trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-18 22:40:14 UTC (rev 1814)
@@ -64,7 +64,7 @@
 
    Thread threadOwner;
 
-   int refereceCountOpen=0;
+   int refereceCountOpen = 0;
 
 
    public synchronized boolean isOpened()
@@ -72,7 +72,9 @@
       return opened;
    }
 
-   /** If the Valve is opened, will wait until the valve is closed */
+   /**
+    * If the Valve is opened, will wait until the valve is closed
+    */
    public synchronized boolean isOpened(boolean wait) throws Exception
    {
       if (wait && opened)
@@ -83,14 +85,12 @@
             if (trace) log.trace("Waiting valve to be closed");
             this.wait();
             if (trace) log.trace("Valve was closed");
-         }
-         else
+         } else
          {
             if (trace) log.trace("This is ThreadOwner, so Valve won't wait");
          }
          return opened;
-      }
-      else
+      } else
       {
          return false;
       }
@@ -104,7 +104,7 @@
 
    public synchronized boolean open(boolean wait) throws Exception
    {
-      if (threadOwner==Thread.currentThread())
+      if (threadOwner == Thread.currentThread())
       {
          if (trace) log.trace("Valve was opened again by thread owner");
          refereceCountOpen++;
@@ -144,13 +144,12 @@
          log.warn("Valve was already closed", new Exception());
       }
       refereceCountOpen--;
-      if (refereceCountOpen==0)
+      if (refereceCountOpen == 0)
       {
          if (trace) log.trace("Closing Valve");
          closed = true;
          notifyAll();
-      }
-      else
+      } else
       {
          if (trace) log.trace("Valve.close called but there referenceCountOpen=" + refereceCountOpen);
       }



From gavin.king at jboss.com  Mon Dec 18 17:48:31 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 17:48:31 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui    ...
Message-ID: <E1GwRHb-00036S-Fg@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 17:48:31

  Modified:    src/ui/org/jboss/seam/ui    HtmlButton.java HtmlLink.java
                        UIStyleDecoration.java
  Log:
  write out the client id
  
  Revision  Changes    Path
  1.5       +1 -1      jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlButton.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- HtmlButton.java	14 Dec 2006 08:52:18 -0000	1.4
  +++ HtmlButton.java	18 Dec 2006 22:48:31 -0000	1.5
  @@ -81,7 +81,7 @@
         writer.startElement("input", this);
         writer.writeAttribute("type", "button", null);
         if ( isDisabled() ) writer.writeAttribute("disabled", true, "disabled");
  -      writer.writeAttribute("id", getClientId(context), null);
  +      writer.writeAttribute("id", getClientId(context), "id");
   
         String viewId;
         ValueBinding viewBinding = getValueBinding("view");
  
  
  
  1.25      +1 -1      jboss-seam/src/ui/org/jboss/seam/ui/HtmlLink.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlLink.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlLink.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- HtmlLink.java	14 Dec 2006 08:52:18 -0000	1.24
  +++ HtmlLink.java	18 Dec 2006 22:48:31 -0000	1.25
  @@ -81,7 +81,7 @@
      {
         ResponseWriter writer = context.getResponseWriter();
         writer.startElement("a", this);
  -      writer.writeAttribute("id", getClientId(context), null);
  +      writer.writeAttribute("id", getClientId(context), "id");
   
         String viewId;
         ValueBinding viewBinding = getValueBinding("view");
  
  
  
  1.4       +6 -2      jboss-seam/src/ui/org/jboss/seam/ui/UIStyleDecoration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIStyleDecoration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/UIStyleDecoration.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- UIStyleDecoration.java	2 Oct 2006 18:20:36 -0000	1.3
  +++ UIStyleDecoration.java	18 Dec 2006 22:48:31 -0000	1.4
  @@ -54,15 +54,19 @@
         ResponseWriter response = context.getResponseWriter();
         response.startElement( getElement(), this );
   
  +      response.writeAttribute("id", getClientId(context), "id");
  +      
         ValueBinding classBinding = getValueBinding("styleClass");
  -      String styleClass = classBinding==null ? this.styleClass : (String) classBinding.getValue(context);
  +      String styleClass = classBinding==null ? 
  +               this.styleClass : (String) classBinding.getValue(context);
         if (styleClass!=null) 
         {
            response.writeAttribute("class", styleClass, "styleClass");
         }
   
         ValueBinding styleBinding = getValueBinding("style");
  -      String style = styleBinding==null ? this.style : (String) styleBinding.getValue(context);
  +      String style = styleBinding==null ? 
  +               this.style : (String) styleBinding.getValue(context);
         if (style!=null) 
         {
            response.writeAttribute("style", style, "style");
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:48:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:48:48 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59098 - projects/aop/trunk/aop
Message-ID: <E1GwRHs-00036g-GN@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 17:48:47 -0500 (Mon, 18 Dec 2006)
New Revision: 59098

Added:
   projects/aop/trunk/aop/pom.xml
Log:
pom.xml from Torben Jaeger

Added: projects/aop/trunk/aop/pom.xml
===================================================================
--- projects/aop/trunk/aop/pom.xml	2006-12-18 22:19:56 UTC (rev 59097)
+++ projects/aop/trunk/aop/pom.xml	2006-12-18 22:48:47 UTC (rev 59098)
@@ -0,0 +1,70 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0"
+	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+	<modelVersion>4.0.0</modelVersion>
+	<groupId>jboss</groupId>
+	<artifactId>jboss-aop</artifactId>
+	<packaging>jar</packaging>
+	<version>1.0-SNAPSHOT</version>
+	<name>Maven Quick Start Archetype</name>
+	<url>http://maven.apache.org</url>
+
+	<build>
+		<sourceDirectory>src/main/</sourceDirectory>
+
+		<plugins>
+			<plugin>
+				<groupId>org.apache.maven.plugins</groupId>
+				<artifactId>maven-compiler-plugin</artifactId>
+				<configuration>
+					<source>1.5</source>
+					<target>1.5</target>
+				</configuration>
+			</plugin>
+		</plugins>
+	</build>
+
+	<dependencies>
+		<dependency>
+			<groupId>ant</groupId>
+			<artifactId>ant</artifactId>
+			<version>1.6.5</version>
+		</dependency>
+		<dependency>
+			<groupId>javassist</groupId>
+			<artifactId>javassist</artifactId>
+			<version>3.4.GA</version>
+		</dependency>
+		<dependency>
+			<groupId>jboss</groupId>
+			<artifactId>jboss-dependency</artifactId>
+			<version>2.0.0.Beta</version>
+		</dependency>
+		<dependency>
+			<groupId>jboss</groupId>
+			<artifactId>jboss-container</artifactId>
+			<version>2.0.0.Beta</version>
+		</dependency>
+		<dependency>
+			<groupId>junit</groupId>
+			<artifactId>junit</artifactId>
+			<version>3.8.1</version>
+			<scope>test</scope>
+		</dependency>
+		<dependency>
+			<groupId>oswego-concurrent</groupId>
+			<artifactId>concurrent</artifactId>
+			<version>1.3.4</version>
+		</dependency>
+		<dependency>
+			<groupId>qdox</groupId>
+			<artifactId>qdox</artifactId>
+			<version>1.4</version>
+		</dependency>
+		<dependency>
+			<groupId>trove</groupId>
+			<artifactId>trove</artifactId>
+			<version>2.1.1</version>
+		</dependency>
+	</dependencies>
+</project>



From kkhan at jboss.com  Mon Dec 18 17:54:05 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Mon, 18 Dec 2006 17:54:05 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/1.5.3.beta1 - New
	directory ...
Message-ID: <E1GwRMz-0003BO-OM@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/18 17:54:05

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/aop/1.5.3.beta1 added to the repository


From kkhan at jboss.com  Mon Dec 18 17:55:04 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Mon, 18 Dec 2006 17:55:04 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/1.5.3.beta1/lib - New
	directory ...
Message-ID: <E1GwRNw-0003CE-98@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/18 17:55:04

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/aop/1.5.3.beta1/lib added to the repository


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 17:59:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 17:59:53 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1815 -
	trunk/tests/src/org/jboss/test/messaging/util
Message-ID: <E1GwRSb-0003Fb-RH@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-18 17:59:52 -0500 (Mon, 18 Dec 2006)
New Revision: 1815

Added:
   trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java
   trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java
Modified:
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Log:
adding experimental tests

Added: trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java	2006-12-18 22:40:14 UTC (rev 1814)
+++ trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java	2006-12-18 22:59:52 UTC (rev 1815)
@@ -0,0 +1,228 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.util;
+
+import junit.framework.TestCase;
+import org.jboss.logging.Logger;
+import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.ReentrantWriterPreferenceReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.ReaderPreferenceReadWriteLock;
+
+/**
+ *
+ * ValidateValveLogicReadWriteTest and ValidateValveLogicValveTest were written
+ * to validate lock mechanism to be used on ValveAspect.
+ *
+ * ValidateValveLogicTestValveTest uses org.jboss.messaging.util.Valve which avoid locking on reading threads
+ * ValidateValveLogicReadWriteTest uses oswego.concurrent.ReadWriteLock which adds synchronization into reading threads also
+ *
+ *
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class ValidateValveLogicReadWriteTest extends TestCase
+{
+   private static Logger log = Logger.getLogger(ValidateValveLogicReadWriteTest.class);
+
+   boolean useCounterA;
+
+   public synchronized boolean isUseCounterA()
+   {
+      return useCounterA;
+   }
+
+   public synchronized void setUseCounterA(boolean useCounterA)
+   {
+      this.useCounterA = useCounterA;
+   }
+
+
+   boolean keepRunning=true;
+   
+   long counterA = 0;
+   long counterB = 0;
+
+   public synchronized void addCounterA()
+   {
+      counterA++;
+   }
+
+   public synchronized void addCounterB()
+   {
+      counterB++;
+   }
+
+
+   public synchronized long getCounterA()
+   {
+      return counterA;
+   }
+
+   public synchronized long getCounterB()
+   {
+      return counterB;
+   }
+
+   private ReadWriteLock lockValve ;
+   boolean started=false;
+   private Object startSemaphore = new Object();
+
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();    //To change body of overridden methods use File | Settings | File Templates.
+      counterA=0;
+      counterB=0;
+      keepRunning=true;
+      useCounterA=true;
+      
+   }
+
+   public void testValveWithReentrantWriterPreferenceReadWriteLock() throws Exception
+   {
+      log.info("++testValveWithReentrantWriterPreferenceReadWriteLock");
+      lockValve = new ReentrantWriterPreferenceReadWriteLock();
+      internaltestValveLogic();
+   }
+
+   public void testValveWithReaderPreferenceReadWriteLock() throws Exception
+   {
+      log.info("++testValveWithReaderPreferenceReadWriteLock");
+      lockValve = new ReaderPreferenceReadWriteLock();
+      internaltestValveLogic();
+   }
+
+   public void internaltestValveLogic() throws Exception
+   {
+      ThreadRead readThreads [] = new ThreadRead[1000];
+      for (int i=0; i<readThreads.length; i++)
+      {
+         readThreads[i] = new ThreadRead(i);
+      }
+
+      for (int i=0; i<readThreads.length; i++)
+      {
+         readThreads[i].start();
+      }
+
+      synchronized (startSemaphore)
+      {
+         started=true;
+         startSemaphore.notifyAll();
+      }
+
+
+      log.info("Sleeping 10 seconds");
+      Thread.sleep(10000);
+
+      log.info("Acquiring write lock");
+      lockValve.writeLock().acquire();
+      setUseCounterA(false);
+
+      long counterAOriginal = getCounterA();
+      long counterBOriginal = getCounterB();
+
+      log.info ("Waiting 5 seconds");
+      Thread.sleep(5000);
+
+      assertEquals(counterAOriginal, getCounterA());
+      assertEquals(counterBOriginal, getCounterB());
+
+      lockValve.writeLock().release();
+
+
+      log.info("Acquiring read lock");
+      lockValve.readLock().acquire();
+
+      counterBOriginal = getCounterB();
+
+      log.info ("Waiting 5 seconds");
+      Thread.sleep(5000);
+
+      log.info("Threads produced " + (getCounterB() - counterBOriginal));
+      assertEquals(counterAOriginal, getCounterA());
+      assertTrue(getCounterB()>counterBOriginal);
+      lockValve.readLock().release();
+
+      keepRunning = false;
+
+
+      for (int i=0; i<readThreads.length; i++)
+      {
+         readThreads[i].join();
+      }
+
+
+
+
+   }
+
+   // multiple threads opening/closing a thread.
+   // only one should be able to open it
+   public class ThreadRead extends Thread
+   {
+      int threadId;
+      public ThreadRead(int threadId)
+      {
+         this.threadId = threadId;
+      }
+      public void run()
+      {
+         try
+         {
+            //log.info("Starting Thread " + threadId);
+            synchronized (startSemaphore)
+            {
+               if (!started)
+               {
+                  startSemaphore.wait();
+               }
+            }
+
+            while (keepRunning)
+            {
+               lockValve.readLock().acquire();
+               if (isUseCounterA())
+               {
+                  //log.info("Thread " + threadId + " adding A");
+                  addCounterA();
+               }
+               else
+               {
+                  //log.info("Thread " + threadId + " adding B");
+                  addCounterB();
+               }
+               lockValve.readLock().release();
+            }
+
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
+      }
+   }
+
+}

Added: trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java	2006-12-18 22:40:14 UTC (rev 1814)
+++ trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java	2006-12-18 22:59:52 UTC (rev 1815)
@@ -0,0 +1,202 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.util;
+
+import junit.framework.TestCase;
+import org.jboss.logging.Logger;
+import org.jboss.messaging.util.Valve;
+
+/**
+ *
+ * There is a relevant comment into <@link ValidateValveLogicReadWriteTest> 
+ * @see ValidateValveLogicReadWriteTest
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class ValidateValveLogicValveTest extends TestCase
+{
+   private static Logger log = Logger.getLogger(ValidateValveLogicValveTest.class);
+
+   boolean useCounterA;
+
+   public synchronized boolean isUseCounterA()
+   {
+      return useCounterA;
+   }
+
+   public synchronized void setUseCounterA(boolean useCounterA)
+   {
+      this.useCounterA = useCounterA;
+   }
+
+
+   boolean keepRunning=true;
+
+   long counterA = 0;
+   long counterB = 0;
+
+   public synchronized void addCounterA()
+   {
+      counterA++;
+   }
+
+   public synchronized void addCounterB()
+   {
+      counterB++;
+   }
+
+
+   public synchronized long getCounterA()
+   {
+      return counterA;
+   }
+
+   public synchronized long getCounterB()
+   {
+      return counterB;
+   }
+
+   Valve valve = new Valve();
+
+   boolean started=false;
+   private Object startSemaphore = new Object();
+
+
+   public void testValveLogic() throws Exception
+   {
+      ValidateValveLogicValveTest.ThreadRead readThreads [] = new ValidateValveLogicValveTest.ThreadRead[1000];
+      for (int i=0; i<readThreads.length; i++)
+      {
+         readThreads[i] = new ValidateValveLogicValveTest.ThreadRead(i);
+      }
+
+      for (int i=0; i<readThreads.length; i++)
+      {
+         readThreads[i].start();
+      }
+
+      synchronized (startSemaphore)
+      {
+         started=true;
+         startSemaphore.notifyAll();
+      }
+
+
+      log.info("Sleeping 10 seconds");
+      Thread.sleep(10000);
+
+      log.info("Acquiring write lock");
+      valve.open();
+
+      // Time to wait current calls to finish
+      // As valve doesn't need synchronization on running threads,
+      // this sleep is necessary to wait everybody to be on the waiting condition.
+      // And this is meant to be this way. We don't want to stop threads ot calls that are already working,
+      // We want to stop new ones only 
+      Thread.sleep(1000);
+
+      setUseCounterA(false);
+
+      long counterAOriginal = getCounterA();
+      long counterBOriginal = getCounterB();
+
+
+      log.info ("Waiting 5 seconds");
+      Thread.sleep(5000);
+
+      assertEquals(counterAOriginal, getCounterA());
+      assertEquals(counterBOriginal, getCounterB());
+
+      valve.reset();
+
+      valve.isOpened(true);
+
+      log.info("Acquiring read lock");
+
+      counterBOriginal = getCounterB();
+
+      log.info ("Waiting 5 seconds");
+      Thread.sleep(5000);
+
+      log.info ("Threads produced " + (getCounterB() - counterBOriginal));
+      assertEquals(counterAOriginal, getCounterA());
+      assertTrue(getCounterB()>counterBOriginal);
+
+      keepRunning = false;
+
+
+      for (int i=0; i<readThreads.length; i++)
+      {
+         readThreads[i].join();
+      }
+
+   }
+
+   // multiple threads opening/closing a thread.
+   // only one should be able to open it
+   public class ThreadRead extends Thread
+   {
+      int threadId;
+      public ThreadRead(int threadId)
+      {
+         this.threadId = threadId;
+      }
+      public void run()
+      {
+         try
+         {
+            log.info("Starting Thread " + threadId);
+            synchronized (startSemaphore)
+            {
+               if (!started)
+               {
+                  startSemaphore.wait();
+               }
+            }
+
+            while (keepRunning)
+            {
+               valve.isOpened(true);
+               if (isUseCounterA())
+               {
+                  //log.info("Thread " + threadId + " adding A");
+                  addCounterA();
+               }
+               else
+               {
+                  //log.info("Thread " + threadId + " adding B");
+                  addCounterB();
+               }
+            }
+
+         }
+         catch (Exception e)
+         {
+            e.printStackTrace();
+         }
+      }
+   }
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-18 22:40:14 UTC (rev 1814)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-18 22:59:52 UTC (rev 1815)
@@ -40,6 +40,7 @@
 
    static int counter = 0;
    static int counterWait = 0;
+   static int countIsOpen = 0;
 
    static boolean started=false;
    static Object startSemaphore = new Object();
@@ -66,6 +67,12 @@
                   startSemaphore.wait();
                }
             }
+
+            if (valve.isOpened(true))
+            {
+               countIsOpen++;
+            }
+
             //log.info("Thread " + threadId + "Opening valve");
             if (!valve.open())
             {
@@ -133,6 +140,10 @@
          thread[i].join();
       }
 
+      log.info("CountIsOpened=" + countIsOpen);
+      log.info("CounterWait=" + counterWait);
+      log.info("counter=" + counter);
+
       assertEquals(1, counter);
       assertEquals(thread.length-1, counterWait);
 



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:09:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:09:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r59099 -
	trunk/server/src/main/org/jboss/metadata
Message-ID: <E1GwRbp-0003Zp-Ln@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 18:09:24 -0500 (Mon, 18 Dec 2006)
New Revision: 59099

Modified:
   trunk/server/src/main/org/jboss/metadata/WebMetaData.java
Log:
method to add security role ref list for a servlet

Modified: trunk/server/src/main/org/jboss/metadata/WebMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-18 22:48:47 UTC (rev 59098)
+++ trunk/server/src/main/org/jboss/metadata/WebMetaData.java	2006-12-18 23:09:24 UTC (rev 59099)
@@ -842,7 +842,18 @@
       List roles = (List) this.securityRoleReferences.get(servletName);
       return roles;
    }
+   
    /**
+    * Add a security role-ref meta data to a servlet
+    * @param servletName
+    * @param srr
+    */
+   public void addSecurityRoleReference(String servletName, List<SecurityRoleRefMetaData> srr)
+   {
+      this.securityRoleReferences.put(servletName, srr);   
+   }
+   
+   /**
     *
     * @param securityRoleReferences - <String servlet-name, ArrayList<SecurityRoleRefMetaData>>
     */



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:13:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:13:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r59100 -
	trunk/server/src/main/org/jboss/metadata/web
Message-ID: <E1GwRg1-0003eU-0G@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 18:13:44 -0500 (Mon, 18 Dec 2006)
New Revision: 59100

Modified:
   trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java
Log:
fill up the security role refs at the meta data level

Modified: trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java	2006-12-18 23:09:24 UTC (rev 59099)
+++ trunk/server/src/main/org/jboss/metadata/web/WebMetaDataObjectFactory.java	2006-12-18 23:13:44 UTC (rev 59100)
@@ -21,6 +21,9 @@
  */
 package org.jboss.metadata.web;
 
+import java.util.ArrayList;
+import java.util.Collection;
+
 import org.jboss.logging.Logger;
 import org.jboss.metadata.DDObjectFactory;
 import org.jboss.metadata.EjbLocalRefMetaData;
@@ -45,6 +48,7 @@
  * An ObjectModelFactory implementation for parsing web.xml descriptors.
  * 
  * @author Scott.Stark at jboss.org
+ * @author Anil.Saldhana at jboss.org
  * @version $Revision:$
  */
 public class WebMetaDataObjectFactory extends DDObjectFactory
@@ -305,6 +309,13 @@
          UnmarshallingContext navigator, String namespaceURI, String localName)
    {
       parent.addServlet(servlet);
+      //Roll up the security role-refs
+      Collection securityRR = servlet.getSecurityRoleRefs();
+      if(securityRR != null && securityRR.size() > 0)
+      {
+         ArrayList srr = new ArrayList(securityRR);
+         parent.addSecurityRoleReference(servlet.getName(), srr);
+      } 
    }
 
    public void addChild(WebMetaData parent, ServletMapping mapping,
@@ -407,7 +418,7 @@
    public void addChild(Servlet parent, SecurityRoleRefMetaData ref,
          UnmarshallingContext navigator, String namespaceURI, String localName)
    {
-      parent.addSecurityRoleRef(ref);
+      parent.addSecurityRoleRef(ref); 
    }
 
    public void addChild(WebSecurityMetaData parent,



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:14:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:14:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59101 -
	trunk/server/src/main/org/jboss/web
Message-ID: <E1GwRgP-0003en-5l@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 18:14:08 -0500 (Mon, 18 Dec 2006)
New Revision: 59101

Modified:
   trunk/server/src/main/org/jboss/web/WebPermissionMapping.java
Log:
missing perm - need to check this

Modified: trunk/server/src/main/org/jboss/web/WebPermissionMapping.java
===================================================================
--- trunk/server/src/main/org/jboss/web/WebPermissionMapping.java	2006-12-18 23:13:44 UTC (rev 59100)
+++ trunk/server/src/main/org/jboss/web/WebPermissionMapping.java	2006-12-18 23:14:08 UTC (rev 59101)
@@ -203,6 +203,8 @@
             WebResourcePermission wrp = new WebResourcePermission(qurl, missingHttpMethods);
             pc.addToUncheckedPolicy(wrp);  
          }
+         else
+            pc.addToUncheckedPolicy(new WebResourcePermission(qurl, (String)null));
 
          // Create the unchecked permissions WebUserDataPermissions
          Iterator transportContraints = info.getTransportMethods();



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:16:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:16:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r59102 - in tags/EJB3_RC9_Patch_1/ejb3: .
	src/etc
Message-ID: <E1GwRiV-0003hp-39@committer01.frg.pub.inap.atl.jboss.com>

Author: bdecoste
Date: 2006-12-18 18:16:17 -0500 (Mon, 18 Dec 2006)
New Revision: 59102

Modified:
   tags/EJB3_RC9_Patch_1/ejb3/build.xml
   tags/EJB3_RC9_Patch_1/ejb3/src/etc/component-info.xml
Log:
1.0.0.CR9.1-4.0.5

Modified: tags/EJB3_RC9_Patch_1/ejb3/build.xml
===================================================================
--- tags/EJB3_RC9_Patch_1/ejb3/build.xml	2006-12-18 23:14:08 UTC (rev 59101)
+++ tags/EJB3_RC9_Patch_1/ejb3/build.xml	2006-12-18 23:16:17 UTC (rev 59102)
@@ -484,14 +484,14 @@
   <target name="repository-zip" depends="jars"
     description="Create the repository.jboss.com jboss/ejb3 component contents">
     <!-- The binary component version -->
-    <property name="comp-version" value="1.0.0.CR7-jboss4" />
+    <property name="comp-version" value="1.0.0.CR9.1-4.0.5" />
     <!-- Pack the ejb3.deployer -->
     <zip destfile="${build.lib}/ejb3-deployer.zip">
       <zipfileset dir="${build.lib}">
         <include name="ejb3.deployer/**" />
       </zipfileset>
     </zip>
-    <!-- Create a zip file with the 1.0.0.CR7-jboss4 component structure -->
+     <!-- Create a zip file with the 1.0.0.CR9.1-4.0.5 component structure -->
     <zip destfile="${build.lib}/jboss-ejb3-repo.zip">
       <!-- The component-info.xml -->
       <zipfileset dir="${build.etc}" prefix="${comp-version}">

Modified: tags/EJB3_RC9_Patch_1/ejb3/src/etc/component-info.xml
===================================================================
--- tags/EJB3_RC9_Patch_1/ejb3/src/etc/component-info.xml	2006-12-18 23:14:08 UTC (rev 59101)
+++ tags/EJB3_RC9_Patch_1/ejb3/src/etc/component-info.xml	2006-12-18 23:16:17 UTC (rev 59102)
@@ -2,7 +2,7 @@
 
    <component id="jboss/ejb3"
               licenseType="lgpl"
-              version="1.0.0.CR7-jboss4"
+     version="1.0.0.CR9.1-4.0.5"
               description="The EJB3 deployer for integration with jboss-4.0.x">
 
       <artifact id="ejb3-clustered-sfsbcache-service.xml"/>



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:17:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:17:39 -0500
Subject: [jboss-cvs] JBossAS SVN: r59103 - in
	projects/microcontainer/trunk/container/src:
	main/org/jboss/virtual/plugins/context/jar
	resources/tests/vfs/test tests/org/jboss/test/virtual/test
Message-ID: <E1GwRjn-0003k7-GP@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 18:17:33 -0500 (Mon, 18 Dec 2006)
New Revision: 59103

Added:
   projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.mf
   projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.war
Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
Log:
JBMICROCONT-137, handle the case of SynthenticDirEntryHandler having multiple children, some of which are added after the first createChildHandler call.

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java	2006-12-18 23:16:17 UTC (rev 59102)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/virtual/plugins/context/jar/SynthenticDirEntryHandler.java	2006-12-18 23:17:33 UTC (rev 59103)
@@ -74,8 +74,14 @@
       {
          URL parentVfsUrl = parent.toVfsUrl();
          String vfsParentUrl = parentVfsUrl.toString();
-         if (vfsParentUrl.endsWith("/")) vfsUrl = new URL(vfsParentUrl + entryName);
-         else vfsUrl = new URL(vfsParentUrl + "/" + entryName + "/");
+         if (vfsParentUrl.endsWith("/"))
+         {
+            vfsUrl = new URL(vfsParentUrl + entryName);
+         }
+         else
+         {
+            vfsUrl = new URL(vfsParentUrl + "/" + entryName + "/");
+         }
       }
       catch (URISyntaxException e)
       {
@@ -88,11 +94,13 @@
     * Add a child to an entry
     * @param child
     */
-   public void addChild(VirtualFileHandler child)
+   public synchronized void addChild(VirtualFileHandler child)
    {
       if( entryChildren == null )
          entryChildren = new ArrayList<VirtualFileHandler>();
       entryChildren.add(child);
+      if( entryMap != null )
+         entryMap.put(child.getName(), child);
    }
 
    @Override
@@ -139,9 +147,15 @@
    }
 
    /**
-    * TODO: synchronization on lazy entryMap creation
+    * Create a child handler for the given name. This looks to the entryMap
+    * for an existing child.
+    * @param name - the simple name of an immeadiate child.
+    * @return the VirtualFileHandler previously added via addChild.
+    * @throws IOException - thrown if there are no children or the
+    *  name does not match a child
     */
-   public VirtualFileHandler createChildHandler(String name) throws IOException
+   public synchronized VirtualFileHandler createChildHandler(String name)
+      throws IOException
    {
       if( entryChildren == null )
          throw new FileNotFoundException(this+" has no children");

Added: projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.mf
===================================================================
--- projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.mf	2006-12-18 23:16:17 UTC (rev 59102)
+++ projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.mf	2006-12-18 23:17:33 UTC (rev 59103)
@@ -0,0 +1,10 @@
+Manifest-Version: 1.0
+Created-By: ${java.runtime.version} (${java.vendor})
+Specification-Title: filesonly-war
+Specification-Version: 1.0.0.GA
+Specification-Vendor: JBoss Inc.
+Implementation-Title: filesonly-war
+Implementation-URL: http://www.jboss.org
+Implementation-Version: 1.0.0.GA-jboss
+Implementation-Vendor: JBoss Inc.
+

Added: projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.war
===================================================================
(Binary files differ)


Property changes on: projects/microcontainer/trunk/container/src/resources/tests/vfs/test/filesonly.war
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-18 23:16:17 UTC (rev 59102)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-18 23:17:33 UTC (rev 59103)
@@ -1,3 +1,4 @@
+
 /*
  * JBoss, Home of Professional Open Source
  * Copyright 2006, Red Hat Middleware LLC, and individual contributors
@@ -278,6 +279,43 @@
       mfIS.close();
    }
 
+   /**
+    * Basic tests of accessing resources in a war that does not
+    * have parent directory entries.
+    * @throws Exception
+    */
+   public void testFindResourceInFilesOnlyWar()
+      throws Exception
+   {
+      URL rootURL = getResource("/vfs/test");
+      VFS vfs = VFS.getVFS(rootURL);
+      VirtualFile war = vfs.findChild("filesonly.war");
+      assertTrue("filesonly.war != null", war != null);
+
+      VirtualFile classes = war.findChild("WEB-INF/classes");
+      assertTrue("WEB-INF/classes != null", classes != null);
+      assertTrue("WEB-INF/classes is not a leaf", classes.isLeaf()==false);
+
+      VirtualFile jar1 = war.findChild("WEB-INF/lib/jar1.jar");
+      assertTrue("WEB-INF/lib/jar1.jar != null", jar1 != null);
+      assertTrue("WEB-INF/lib/jar1.jar is not a leaf", jar1.isLeaf()==false);
+      VirtualFile ClassInJar1 = jar1.findChild("org/jboss/test/vfs/support/jar1/ClassInJar1.class");
+      assertTrue("ClassInJar1.class != null", ClassInJar1 != null);
+      assertTrue("ClassInJar1.class is a leaf", ClassInJar1.isLeaf());
+
+      VirtualFile metaInf = war.findChild("META-INF/MANIFEST.MF");
+      assertTrue("META-INF/MANIFEST.MF != null", metaInf != null);
+      InputStream mfIS = metaInf.toURL().openStream();
+      assertTrue("META-INF/MANIFEST.MF.openStream != null", mfIS != null);
+      Manifest mf = new Manifest(mfIS);
+      Attributes mainAttrs = mf.getMainAttributes();
+      String version = mainAttrs.getValue(Attributes.Name.SPECIFICATION_VERSION);
+      assertEquals("1.0.0.GA", version);
+      String title = mf.getMainAttributes().getValue(Attributes.Name.SPECIFICATION_TITLE);
+      assertEquals("filesonly-war", title);
+      mfIS.close();
+   }
+
    public void testFindResourceUnpackedJar()
       throws Exception
    {



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:18:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:18:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59104 -
	trunk/testsuite/src/main/org/jboss/test/jacc/test
Message-ID: <E1GwRkH-0003lO-I3@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 18:18:08 -0500 (Mon, 18 Dec 2006)
New Revision: 59104

Added:
   trunk/testsuite/src/main/org/jboss/test/jacc/test/TestJBossPolicyConfiguration.java
   trunk/testsuite/src/main/org/jboss/test/jacc/test/WebPermissionsValidationTestCase.java
Log:
Test to validate jacc permissions generation for the web layer

Added: trunk/testsuite/src/main/org/jboss/test/jacc/test/TestJBossPolicyConfiguration.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/jacc/test/TestJBossPolicyConfiguration.java	2006-12-18 23:17:33 UTC (rev 59103)
+++ trunk/testsuite/src/main/org/jboss/test/jacc/test/TestJBossPolicyConfiguration.java	2006-12-18 23:18:08 UTC (rev 59104)
@@ -0,0 +1,154 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.jacc.test;
+
+import java.security.Permission;
+import java.security.PermissionCollection;
+import java.security.Permissions;
+import java.util.Enumeration;
+import java.util.HashMap;
+
+import javax.security.jacc.PolicyConfiguration;
+import javax.security.jacc.PolicyContextException;
+
+//$Id$
+
+/**
+ *  Policy Configuration used for permissions validation
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 18, 2006 
+ *  @version $Revision$
+ */
+public class TestJBossPolicyConfiguration implements PolicyConfiguration
+{
+   private String contextID;  
+   
+   private Permissions excludedPolicy = new Permissions();
+   private Permissions uncheckedPolicy = new Permissions();
+   
+   private HashMap<String,Permissions> rolePerms = new HashMap<String,Permissions>();
+   
+
+   public TestJBossPolicyConfiguration(String contextID)
+   { 
+      this.contextID = contextID;
+   }
+
+   public void addToExcludedPolicy(Permission permission) throws PolicyContextException
+   { 
+      this.excludedPolicy.add(permission);
+   }
+
+   public void addToExcludedPolicy(PermissionCollection permissions) throws PolicyContextException
+   { 
+      Enumeration<Permission> en = permissions.elements();
+      while(en.hasMoreElements())
+         addToExcludedPolicy(en.nextElement());
+   }
+
+   public void addToRole(String roleName, Permission permission) throws PolicyContextException
+   { 
+      Permissions p = rolePerms.get(roleName);
+      if(p == null)
+         p = new Permissions();
+      p.add(permission);
+      rolePerms.put(roleName, p);
+   }
+
+   public void addToRole(String roleName, PermissionCollection permissions) throws PolicyContextException
+   { 
+      Enumeration<Permission> en = permissions.elements();
+      while(en.hasMoreElements())
+         addToRole(roleName,en.nextElement());
+   }
+
+   public void addToUncheckedPolicy(Permission permission) throws PolicyContextException
+   { 
+      this.uncheckedPolicy.add(permission);
+   }
+
+   public void addToUncheckedPolicy(PermissionCollection permissions) throws PolicyContextException
+   { 
+      Enumeration<Permission> en = permissions.elements();
+      while(en.hasMoreElements())
+         addToUncheckedPolicy(en.nextElement());
+   }
+
+   public void commit() throws PolicyContextException
+   { 
+   }
+
+   public void delete() throws PolicyContextException
+   { 
+   }
+
+   public String getContextID() throws PolicyContextException
+   { 
+      return this.contextID;
+   }
+
+   public boolean inService() throws PolicyContextException
+   { 
+      return false;
+   }
+
+   public void linkConfiguration(PolicyConfiguration link) throws PolicyContextException
+   {  
+   }
+
+   public void removeExcludedPolicy() throws PolicyContextException
+   { 
+      this.excludedPolicy = null;
+   }
+
+   public void removeRole(String roleName) throws PolicyContextException
+   { 
+      Permissions p = this.rolePerms.get(roleName);
+      if(p != null)
+      {
+         p = null;
+         rolePerms.remove(roleName);
+      }   
+   }
+
+   public void removeUncheckedPolicy() throws PolicyContextException
+   { 
+      this.uncheckedPolicy = null;
+   }
+   
+   //Value added methods 
+
+   public Permissions getExcludedPolicy()
+   {
+      return excludedPolicy;
+   }
+
+   public Permissions getUncheckedPolicy()
+   {
+      return uncheckedPolicy;
+   } 
+   
+   public Permissions getPermissionsForRole(String roleName)
+   {
+      return this.rolePerms.get(roleName);
+   }
+}

Added: trunk/testsuite/src/main/org/jboss/test/jacc/test/WebPermissionsValidationTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/jacc/test/WebPermissionsValidationTestCase.java	2006-12-18 23:17:33 UTC (rev 59103)
+++ trunk/testsuite/src/main/org/jboss/test/jacc/test/WebPermissionsValidationTestCase.java	2006-12-18 23:18:08 UTC (rev 59104)
@@ -0,0 +1,147 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.jacc.test;
+ 
+import java.io.InputStream;
+import java.net.URL;
+import java.security.Permissions;
+
+import javax.security.jacc.WebResourcePermission;
+import javax.security.jacc.WebRoleRefPermission;
+import javax.security.jacc.WebUserDataPermission;
+
+import org.jboss.metadata.WebMetaData;
+import org.jboss.metadata.web.WebMetaDataObjectFactory;
+import org.jboss.test.JBossTestCase;
+import org.jboss.util.xml.JBossEntityResolver; 
+import org.jboss.web.WebPermissionMapping;
+import org.jboss.xb.binding.JBossXBException;
+import org.jboss.xb.binding.ObjectModelFactory;
+import org.jboss.xb.binding.Unmarshaller;
+import org.jboss.xb.binding.UnmarshallerFactory;
+
+//$Id$
+
+/**
+ *  Validate the parsing of web.xml and the creation of JACC Permissions
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 18, 2006 
+ *  @version $Revision$
+ */
+public class WebPermissionsValidationTestCase extends JBossTestCase
+{ 
+   public WebPermissionsValidationTestCase(String name)
+   {
+      super(name); 
+   }
+   
+   public WebMetaData getWebMetaData(ObjectModelFactory factory, InputStream webxml) 
+   throws JBossXBException
+   { 
+      Unmarshaller unmarshaller = null; 
+      UnmarshallerFactory unmarshallerFactory = UnmarshallerFactory
+              .newInstance();
+      //        unmarshallerFactory.setFeature(Unmarshaller.SCHEMA_VALIDATION, Boolean.TRUE);
+      unmarshaller = unmarshallerFactory.newUnmarshaller();
+      JBossEntityResolver entityResolver = new JBossEntityResolver();
+      unmarshaller.setEntityResolver(entityResolver);
+
+      return (WebMetaData) unmarshaller.unmarshal(webxml, factory, null); 
+   } 
+   
+   public void testWebPermissions() throws Exception 
+   {
+      ClassLoader cl = Thread.currentThread().getContextClassLoader();
+      URL webxml = cl.getResource("security/jacc/webperm/web.xml");
+      assertNotNull("web.xml exists?", webxml);
+      WebMetaData wmd = getWebMetaData(new WebMetaDataObjectFactory(),
+            webxml.openStream());
+      TestJBossPolicyConfiguration tpc = new TestJBossPolicyConfiguration("dummy");
+      WebPermissionMapping.createPermissions(wmd, tpc); 
+      checkUncheckedPermissions(tpc.getUncheckedPolicy());
+      checkExcludedPermissions(tpc.getExcludedPolicy());
+      checkAddToRoleForAdministrator(tpc.getPermissionsForRole("Administrator")); 
+      checkAddToRoleForManager(tpc.getPermissionsForRole("Manager")); 
+      checkAddToRoleForEmployee(tpc.getPermissionsForRole("Employee"));
+   }  
+    
+   
+   private void checkUncheckedPermissions(Permissions p)
+   {
+      assertTrue(p.implies(new WebResourcePermission("/sslprotected.jsp", "!GET,POST")));
+      assertTrue(p.implies(new WebResourcePermission("/:/secured.jsp:/unchecked.jsp:/excluded.jsp:/sslprotected.jsp",
+            (String) null)));
+      assertTrue(p.implies(new WebResourcePermission("/excluded.jsp", "!GET,POST")));
+      assertTrue(p.implies(new WebResourcePermission("/secured.jsp", "!GET,POST")));
+      assertTrue(p.implies(new WebResourcePermission("/unchecked.jsp", (String) null)));
+      
+      assertTrue(p.implies(new WebUserDataPermission("/sslprotected.jsp", "GET,POST:CONFIDENTIAL")));
+      assertTrue(p.implies(new WebUserDataPermission("/excluded.jsp", "!GET,POST")));
+      assertTrue(p.implies(new WebUserDataPermission("/sslprotected.jsp", "!GET,POST")));
+      assertTrue(p.implies(new WebUserDataPermission("/secured.jsp", (String) null)));
+      assertTrue(p.implies(new WebUserDataPermission("/:/unchecked.jsp:/secured.jsp:/sslprotected.jsp:/excluded.jsp",
+            (String) null)));
+      assertTrue(p.implies(new WebUserDataPermission("/unchecked.jsp", (String) null)));
+   }
+   
+   private void checkExcludedPermissions(Permissions p)
+   {
+      assertTrue(p.implies(new WebResourcePermission("/excluded.jsp", "GET,POST"))); 
+      assertTrue(p.implies(new WebUserDataPermission("/excluded.jsp", "GET,POST")));
+   }
+   
+   private void checkAddToRoleForManager(Permissions p)
+   { 
+      assertTrue(p.implies(new WebRoleRefPermission("secured", "Manager")));
+      assertTrue(p.implies(new WebRoleRefPermission("sslprotected", "MGR")));
+      assertTrue(p.implies(new WebRoleRefPermission("sslprotected", "Manager")));
+      assertTrue(p.implies(new WebRoleRefPermission("unchecked", "Manager")));
+      assertTrue(p.implies(new WebRoleRefPermission("excluded", "Manager")));
+      //Jacc1.1 
+      assertTrue(p.implies(new WebRoleRefPermission("", "Manager"))); 
+   } 
+   
+   private void checkAddToRoleForAdministrator(Permissions p)
+   {
+      assertTrue(p.implies(new WebResourcePermission("/secured.jsp", "GET,POST")));
+      assertTrue(p.implies(new WebResourcePermission("/sslprotected.jsp", "GET,POST")));
+      
+      assertTrue(p.implies(new WebRoleRefPermission("secured", "ADM")));
+      assertTrue(p.implies(new WebRoleRefPermission("secured", "Administrator")));
+      assertTrue(p.implies(new WebRoleRefPermission("sslprotected", "ADM")));
+      assertTrue(p.implies(new WebRoleRefPermission("sslprotected", "Administrator")));
+      assertTrue(p.implies(new WebRoleRefPermission("unchecked", "Administrator")));
+      assertTrue(p.implies(new WebRoleRefPermission("excluded", "Administrator")));
+      //Jacc1.1
+      assertTrue(p.implies(new WebRoleRefPermission("", "Administrator"))); 
+   }
+   
+   private void checkAddToRoleForEmployee(Permissions p)
+   {
+      assertTrue(p.implies(new WebRoleRefPermission("secured", "Employee")));
+      assertTrue(p.implies(new WebRoleRefPermission("sslprotected", "Employee")));
+      assertTrue(p.implies(new WebRoleRefPermission("unchecked", "Employee")));
+      assertTrue(p.implies(new WebRoleRefPermission("excluded", "Employee"))); 
+      //  Jacc1.1
+      assertTrue(p.implies(new WebRoleRefPermission("", "Employee"))); 
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:18:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:18:36 -0500
Subject: [jboss-cvs] JBossAS SVN: r59105 -
	projects/microcontainer/trunk/container
Message-ID: <E1GwRki-0003lh-B1@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 18:18:34 -0500 (Mon, 18 Dec 2006)
New Revision: 59105

Modified:
   projects/microcontainer/trunk/container/build-test.xml
Log:
JBMICROCONT-137, Add a filesonly.war to test-resource-jars

Modified: projects/microcontainer/trunk/container/build-test.xml
===================================================================
--- projects/microcontainer/trunk/container/build-test.xml	2006-12-18 23:18:08 UTC (rev 59104)
+++ projects/microcontainer/trunk/container/build-test.xml	2006-12-18 23:18:34 UTC (rev 59105)
@@ -280,6 +280,21 @@
             <include name="inner-container.jar" />
          </zipfileset>
       </jar>
+
+      <!-- src/resources/tests/vfs/test/filesonly.war -->
+      <zip destfile="${source.resources}/vfs/test/filesonly.war"
+          filesonly="true">
+          <zipfileset dir="${source.resources}/vfs/test" fullpath="META-INF/MANIFEST.MF">
+             <include name="filesonly.mf"/>
+          </zipfileset>
+          <zipfileset dir="${build.classes.support}" prefix="WEB-INF/classes">
+             <include name="org/jboss/test/vfs/support/jar1/**"/>
+          </zipfileset>
+ 	      <zipfileset dir="${source.resources}/vfs/test" prefix="WEB-INF/lib">
+ 	         <include name="jar1.jar"/>
+ 	      </zipfileset>
+       </zip>
+
    </target>
 
   <!-- ================================================================== -->



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:18:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:18:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r59106 - in
	trunk/testsuite/src/resources/security/jacc: . webperm
Message-ID: <E1GwRku-0003m0-6a@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-18 18:18:47 -0500 (Mon, 18 Dec 2006)
New Revision: 59106

Added:
   trunk/testsuite/src/resources/security/jacc/webperm/
   trunk/testsuite/src/resources/security/jacc/webperm/web.xml
Log:
resources for the jacc perm validation

Added: trunk/testsuite/src/resources/security/jacc/webperm/web.xml
===================================================================
--- trunk/testsuite/src/resources/security/jacc/webperm/web.xml	2006-12-18 23:18:34 UTC (rev 59105)
+++ trunk/testsuite/src/resources/security/jacc/webperm/web.xml	2006-12-18 23:18:47 UTC (rev 59106)
@@ -0,0 +1,123 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<web-app xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="2.4" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
+<display-name>jacc_toolsContracts</display-name>
+<servlet>
+<display-name>unchecked</display-name>
+<servlet-name>unchecked</servlet-name>
+<jsp-file>/unchecked.jsp</jsp-file>
+<load-on-startup>0</load-on-startup>
+</servlet>
+<servlet>
+<display-name>secured</display-name>
+<servlet-name>secured</servlet-name>
+<jsp-file>/secured.jsp</jsp-file>
+<load-on-startup>0</load-on-startup>
+<security-role-ref>
+<role-name>ADM</role-name>
+<role-link>Administrator</role-link>
+</security-role-ref>
+</servlet>
+<servlet>
+<display-name>sslprotected</display-name>
+<servlet-name>sslprotected</servlet-name>
+<jsp-file>/sslprotected.jsp</jsp-file>
+<load-on-startup>0</load-on-startup>
+<security-role-ref>
+<role-name>ADM</role-name>
+<role-link>Administrator</role-link>
+</security-role-ref>
+<security-role-ref>
+<role-name>MGR</role-name>
+<role-link>Manager</role-link>
+</security-role-ref>
+</servlet>
+<servlet>
+<display-name>excluded</display-name>
+<servlet-name>excluded</servlet-name>
+<jsp-file>/excluded.jsp</jsp-file>
+<load-on-startup>0</load-on-startup>
+</servlet>
+<servlet-mapping>
+<servlet-name>unchecked</servlet-name>
+<url-pattern>/unchecked.jsp</url-pattern>
+</servlet-mapping>
+<servlet-mapping>
+<servlet-name>secured</servlet-name>
+<url-pattern>/secured.jsp</url-pattern>
+</servlet-mapping>
+<servlet-mapping>
+<servlet-name>sslprotected</servlet-name>
+<url-pattern>/sslprotected.jsp</url-pattern>
+</servlet-mapping>
+<servlet-mapping>
+<servlet-name>excluded</servlet-name>
+<url-pattern>/excluded.jsp</url-pattern>
+</servlet-mapping>
+<session-config>
+<session-timeout>54</session-timeout>
+</session-config>
+<security-constraint>
+<web-resource-collection>
+<web-resource-name>MySecureBit4</web-resource-name>
+<url-pattern>/unchecked.jsp</url-pattern>
+<http-method>POST</http-method>
+<http-method>GET</http-method>
+</web-resource-collection>
+<user-data-constraint>
+<transport-guarantee>NONE</transport-guarantee>
+</user-data-constraint>
+</security-constraint>
+<security-constraint>
+<web-resource-collection>
+<web-resource-name>MySecureBit6</web-resource-name>
+<url-pattern>/sslprotected.jsp</url-pattern>
+<http-method>POST</http-method>
+<http-method>GET</http-method>
+</web-resource-collection>
+<auth-constraint>
+<role-name>Administrator</role-name>
+</auth-constraint>
+<user-data-constraint>
+<transport-guarantee>CONFIDENTIAL</transport-guarantee>
+</user-data-constraint>
+</security-constraint>
+<security-constraint>
+<web-resource-collection>
+<web-resource-name>MySecureBit3</web-resource-name>
+<url-pattern>/secured.jsp</url-pattern>
+<http-method>POST</http-method>
+<http-method>GET</http-method>
+</web-resource-collection>
+<auth-constraint>
+<role-name>Administrator</role-name>
+</auth-constraint>
+<user-data-constraint>
+<transport-guarantee>NONE</transport-guarantee>
+</user-data-constraint>
+</security-constraint>
+<security-constraint>
+<web-resource-collection>
+<web-resource-name>MySecureBit5</web-resource-name>
+<url-pattern>/excluded.jsp</url-pattern>
+<http-method>POST</http-method>
+<http-method>GET</http-method>
+</web-resource-collection>
+<auth-constraint/>
+<user-data-constraint>
+<transport-guarantee>NONE</transport-guarantee>
+</user-data-constraint>
+</security-constraint>
+<login-config>
+<auth-method>BASIC</auth-method>
+<realm-name>default</realm-name>
+</login-config>
+<security-role>
+<role-name>Administrator</role-name>
+</security-role>
+<security-role>
+<role-name>Manager</role-name>
+</security-role>
+<security-role>
+<role-name>Employee</role-name>
+</security-role>
+</web-app>



From scott.stark at jboss.com  Mon Dec 18 18:21:09 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 18:21:09 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/microcontainer/snapshot/lib ...
Message-ID: <E1GwRnB-0003pQ-Ra@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 18:21:09

  Modified:    jboss/microcontainer/snapshot/lib            
                        jboss-aop-mc-int-boot.jar
                        jboss-aop-mc-int-deployer.jar
                        jboss-aop-mc-int-src.zip jboss-aop-mc-int.jar
                        jboss-container-src.zip jboss-container.jar
                        jboss-dependency-src.zip jboss-dependency.jar
                        jboss-deployers-src.zip jboss-deployers.jar
                        jboss-microcontainer-src.zip
                        jboss-microcontainer.jar
  Log:
  Update the snapshot to include JBMICROCONT-137
  
  Revision  Changes    Path
  1.9       +52 -61    repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-aop-mc-int-boot.jar
  
  	<<Binary file>>
  
  
  1.9       +110 -107  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-aop-mc-int-deployer.jar
  
  	<<Binary file>>
  
  
  1.4       +104 -154  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-aop-mc-int-src.zip
  
  	<<Binary file>>
  
  
  1.13      +140 -144  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-aop-mc-int.jar
  
  	<<Binary file>>
  
  
  1.4       +1395 -1305repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-container-src.zip
  
  	<<Binary file>>
  
  
  1.38      +1576 -1373repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-container.jar
  
  	<<Binary file>>
  
  
  1.2       +75 -78    repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-dependency-src.zip
  
  	<<Binary file>>
  
  
  1.11      +84 -83    repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-dependency.jar
  
  	<<Binary file>>
  
  
  1.3       +182 -182  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-deployers-src.zip
  
  	<<Binary file>>
  
  
  1.36      +203 -202  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-deployers.jar
  
  	<<Binary file>>
  
  
  1.4       +736 -741  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-microcontainer-src.zip
  
  	<<Binary file>>
  
  
  1.15      +918 -904  repository.jboss.com/jboss/microcontainer/snapshot/lib/jboss-microcontainer.jar
  
  	<<Binary file>>
  
  


From prabhat.jha at jboss.com  Mon Dec 18 18:23:53 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:23:53 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR8-jboss4  ...
Message-ID: <E1GwRpp-0003rR-2Y@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:23:53

  Modified:    jboss/ejb3/1.0.0.CR8-jboss4  component-info.xml
  Log:
  adding ejb3 rc9 patch1 release
  
  Revision  Changes    Path
  1.4       +1 -0      repository.jboss.com/jboss/ejb3/1.0.0.CR8-jboss4/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR8-jboss4/component-info.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- component-info.xml	25 Jun 2006 12:43:17 -0000	1.3
  +++ component-info.xml	18 Dec 2006 23:23:53 -0000	1.4
  @@ -16,6 +16,7 @@
           <compatible version="3.2.0.CR1"/>
           <compatible version="3.2.0.CR2"/>
           <compatible version="3.2.0.GA"/>
  +        <compatible version="3.3.0.GA"/>
         </import>
         <import componentref="hibernate-annotations">
           <compatible version="3.2.0.CR1"/>
  
  
  


From prabhat.jha at jboss.com  Mon Dec 18 18:24:50 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:24:50 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5 - New
	directory ...
Message-ID: <E1GwRqk-0003ra-5I@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:24:50

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5 added to the repository


From prabhat.jha at jboss.com  Mon Dec 18 18:29:56 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:29:56 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/resources -
	New directory ...
Message-ID: <E1GwRvg-0003wy-0s@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:29:56

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/resources added to the repository


From prabhat.jha at jboss.com  Mon Dec 18 18:29:55 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:29:55 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/lib -
	New directory ...
Message-ID: <E1GwRvf-0003wu-Sv@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:29:55

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/lib added to the repository


From prabhat.jha at jboss.com  Mon Dec 18 18:29:55 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:29:55 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/bin -
	New directory ...
Message-ID: <E1GwRvf-0003wq-Nd@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:29:55

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/bin added to the repository


From prabhat.jha at jboss.com  Mon Dec 18 18:32:32 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:32:32 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5  ...
Message-ID: <E1GwRyC-000415-0p@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:32:32

  Added:       jboss/ejb3/1.0.0.CR9.1-4.0.5  component-info.xml
  Log:
  ejb3 rc9 patch1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 23:32:31;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/ejb3-component-info">
  
     <component id="jboss/ejb3"
                licenseType="lgpl"
       version="1.0.0.CR9.1-4.0.5"
                description="The EJB3 deployer for integration with jboss-4.0.x">
  
        <artifact id="ejb3-clustered-sfsbcache-service.xml"/>
        <artifact id="ejb3-entity-cache-service.xml"/>
        <artifact id="ejb3-interceptors-aop.xml"/>
        <artifact id="ejb3.deployer" />
        <artifact id="hibernate-client.jar"/>
        <artifact id="jboss-ejb3-client.jar"/>
  
        <import componentref="javassist">
          <compatible version="3.2.0.CR1"/>
          <compatible version="3.2.0.CR2"/>
        </import>
        <import componentref="hibernate-annotations">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="hibernate-entitymanager">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="jboss/remoting">
          <compatible version="1.4.1_final"/>
          <compatible version="1.4.2.GA"/>
        </import>
        <import componentref="jboss/aop">
          <compatible version="1.5.0.GA"/>
        </import>
  
        <export>
           <include input="hibernate-client.jar"/>
           <include input="jboss-ejb3-client.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From prabhat.jha at jboss.com  Mon Dec 18 18:32:32 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:32:32 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/bin ...
Message-ID: <E1GwRyC-00041B-3x@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:32:32

  Added:       jboss/ejb3/1.0.0.CR9.1-4.0.5/bin  ejb3.deployer
  Log:
  ejb3 rc9 patch1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 23:32:32;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/bin/ejb3.deployer
  
  	<<Binary file>>
  
  


From prabhat.jha at jboss.com  Mon Dec 18 18:32:32 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:32:32 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/lib ...
Message-ID: <E1GwRyC-00041J-8a@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:32:32

  Added:       jboss/ejb3/1.0.0.CR9.1-4.0.5/lib   hibernate-client.jar
                        jboss-ejb3-client.jar
  Log:
  ejb3 rc9 patch1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 23:32:32;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/lib/hibernate-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/18 23:32:32;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/lib/jboss-ejb3-client.jar
  
  	<<Binary file>>
  
  


From prabhat.jha at jboss.com  Mon Dec 18 18:32:32 2006
From: prabhat.jha at jboss.com (Prabhat Jha)
Date: Mon, 18 Dec 2006 18:32:32 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/resources ...
Message-ID: <E1GwRyC-00041W-DS@committer01.frg.pub.inap.atl.jboss.com>

  User: pjha    
  Date: 06/12/18 18:32:32

  Added:       jboss/ejb3/1.0.0.CR9.1-4.0.5/resources   
                        ejb3-clustered-sfsbcache-service.xml
                        ejb3-entity-cache-service.xml
                        ejb3-interceptors-aop.xml
  Log:
  ejb3 rc9 patch1
  
  Revision  Changes    Path
  1.1      date: 2006/12/18 23:32:32;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/resources/ejb3-clustered-sfsbcache-service.xml
  
  Index: ejb3-clustered-sfsbcache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
     <mbean code="org.jboss.ejb3.cache.tree.PassivationTreeCache" name="jboss.cache:service=EJB3SFSBClusteredCache">
     
        <!-- uncomment next three statements if using JGroups multiplexer,
               requires JGroups 2.3 or later, JBossCache 1.4 or later -->
        <!--
        <depends>jgroups.mux:name=Multiplexer</depends>
        <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
        <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
        -->
        
        <!--
                Node locking level : SERIALIZABLE
                                     REPEATABLE_READ (default)
                                     READ_COMMITTED
                                     READ_UNCOMMITTED
                                     NONE
        -->
        <attribute name="IsolationLevel">READ_UNCOMMITTED</attribute>
  
        <!--     Valid modes are LOCAL
                                 REPL_ASYNC
                                 REPL_SYNC
        -->
        <attribute name="CacheMode">REPL_SYNC</attribute>
  
        <attribute name="ClusterName">SFSB-Cache</attribute>
  
        <attribute name="ClusterConfig">
           <config>
              <!-- 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="45551" ip_ttl="${jgroups.mcast.ip_ttl:64}" 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"/>
           </config>
        </attribute>
  
        <!--    Number of milliseconds to wait until all responses for a
                synchronous call have been received.
        -->
        <attribute name="SyncReplTimeout">10000</attribute>
  
        <!--  Max number of milliseconds to wait for a lock acquisition -->
        <attribute name="LockAcquisitionTimeout">15000</attribute>
  
        <!--  Name of the eviction policy class. -->
        <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
        <!--  Specific eviction policy configurations. This is LRU -->
        <attribute name="EvictionPolicyConfig">
           <config>
              <attribute name="wakeUpIntervalSeconds">5</attribute>
              <name>statefulClustered</name>
              <!-- So default region would never timeout -->
              <region name="/_default_">
                 <attribute name="maxNodes">0</attribute>
                 <attribute name="timeToIdleSeconds">0</attribute>
              </region>
  
           </config>
        </attribute>
  
  
        <!-- New 1.3.x cache loader config block -->
        <!-- Note this is used for AS5.0 only -->
        <attribute name="CacheLoaderConfiguration">
            <config>
                <!-- We need to turn it on
                <passivation>false</passivation>
                -->
                <passivation>true</passivation>
                <preload>/</preload>
                <shared>false</shared>
  
                <cacheloader>
                    <class>org.jboss.cache.loader.FileCacheLoader</class>
                        <!--
                        -->
                    <properties>
                         location=${jboss.server.data.dir}${/}sfsb
                    </properties>
                    <async>false</async>
                    <fetchPersistentState>false</fetchPersistentState>
                    <ignoreModifications>false</ignoreModifications>
                </cacheloader>
  
            </config>
        </attribute>
  
     </mbean>
  
  </server>
  
  
  
  
  1.1      date: 2006/12/18 23:32:32;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/resources/ejb3-entity-cache-service.xml
  
  Index: ejb3-entity-cache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
  
    <!--  ====================================================================  -->
    <!--  Defines TreeCache configuration                                       -->
    <!--  ====================================================================  -->
    <mbean code="org.jboss.cache.TreeCache" name="jboss.cache:service=EJB3EntityTreeCache">
      <depends>jboss:service=Naming</depends>
      <depends>jboss:service=TransactionManager</depends>
      
      <!-- uncomment next three statements if using JGroups multiplexer,
            requires JGroups 2.3 or later, JBossCache 1.4 or later -->
      <!--
      <depends>jgroups.mux:name=Multiplexer</depends>
      <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
      <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
      -->
  
      <!-- Configure the TransactionManager -->
      <attribute name="TransactionManagerLookupClass">org.jboss.cache.JBossTransactionManagerLookup</attribute>
  
      <!--
              Node locking level : SERIALIZABLE
                                   REPEATABLE_READ (default)
                                   READ_COMMITTED
                                   READ_UNCOMMITTED
                                   NONE
      -->
      <attribute name="IsolationLevel">REPEATABLE_READ</attribute>
  
      <!--     Valid modes are LOCAL
                               REPL_ASYNC
                               REPL_SYNC
      -->
      <attribute name="CacheMode">REPL_SYNC</attribute>
  
      <!-- Name of cluster. Needs to be the same for all clusters, in order
               to find each other -->
      <attribute name="ClusterName">EJB3-entity-cache</attribute>
  
      <!-- Must be true if any entity deployment uses a scoped classloader -->
      <attribute name="UseRegionBasedMarshalling">true</attribute>
      <!-- Must match the value of "UseRegionBasedMarshalling" -->
      <attribute name="InactiveOnStartup">true</attribute>
      
      <attribute name="ClusterConfig">
        <config>
          <!-- 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" />
        </config>
      </attribute>
  
      <!--    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
      -->
      <attribute name="InitialStateRetrievalTimeout">5000</attribute>
  
      <!--    Number of milliseconds to wait until all responses for a
              synchronous call have been received.
      -->
      <attribute name="SyncReplTimeout">10000</attribute>
  
      <!--  Max number of milliseconds to wait for a lock acquisition -->
      <attribute name="LockAcquisitionTimeout">15000</attribute>
  
      <!--  Name of the eviction policy class. -->
      <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
      <!--  Specific eviction policy configurations. This is LRU -->
      <attribute name="EvictionPolicyConfig">
        <config>
          <attribute name="wakeUpIntervalSeconds">5</attribute>
          <!--  Cache wide default -->
          <region name="/_default_">
           <attribute name="maxNodes">5000</attribute>
           <attribute name="timeToLiveSeconds">1000</attribute>
         </region>
        </config>
      </attribute>
  
    </mbean>
  
  </server>
  
  
  
  
  1.1      date: 2006/12/18 23:32:32;  author: pjha;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9.1-4.0.5/resources/ejb3-interceptors-aop.xml
  
  Index: ejb3-interceptors-aop.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE aop PUBLIC
     "-//JBoss//DTD JBOSS AOP 1.0//EN"
     "http://www.jboss.org/aop/dtd/jboss-aop_1_0.dtd">
  
  <aop>
     <interceptor class="org.jboss.aspects.remoting.InvokeRemoteInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.security.SecurityClientInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.tx.ClientTxPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.remoting.IsLocalInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.remoting.ClusterChooserInterceptor" scope="PER_VM"/>
  
     <interceptor class="org.jboss.aspects.tx.TxPropagationInterceptor" scope="PER_VM"/>
  
     <stack name="ServiceClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <interceptor class="org.jboss.ejb3.asynchronous.AsynchronousInterceptor" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.ENCPropagationInterceptor" scope="PER_VM"/>
     <interceptor name="Basic Authorization" factory="org.jboss.ejb3.security.RoleBasedAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor name="JACC Authorization" factory="org.jboss.ejb3.security.JaccAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.AuthenticationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateless.StatelessInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.StatefulInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.service.ServiceSingletonInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.cache.StatefulReplicationInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.stateful.StatefulRemoveFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.tx.TxInterceptorFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.AllowedOperationsInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor" scope="PER_VM"/>
  
     <domain name="Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="JACC Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Base Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="JACC Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
  
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="Embedded Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.NoPassivationCache.class)
        </annotation>
  
     </domain>
  
     <domain name="Message Driven Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
     
     <domain name="Consumer Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND (has(* *->@org.jboss.annotation.ejb.CurrentMessage(..)) OR hasfield(* *->@org.jboss.annotation.ejb.CurrentMessage))">
           <interceptor-ref name="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
     <domain name="JACC Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
  
  </aop>
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:57:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:57:37 -0500
Subject: [jboss-cvs] JBossAS SVN: r59107 -
	branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly
Message-ID: <E1GwSMT-0004M2-DJ@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 18:57:35 -0500 (Mon, 18 Dec 2006)
New Revision: 59107

Modified:
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java
Log:
[JBAOP-329] Parameter annotations should exist in wrapper method and not the internal method. Get test working with JDK 1.4, still need to add a test testing the parameter annotations for jdk 5

Modified: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java	2006-12-18 23:18:47 UTC (rev 59106)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/AnnotationsInWrapperMethodOnlyTestCase.java	2006-12-18 23:57:35 UTC (rev 59107)
@@ -68,7 +68,6 @@
       Advisor advisor = ((Advised)pojo)._getAdvisor();
       
       ArrayList hasAnnotation = new ArrayList();
-      ArrayList hasParameterAnnotation = new ArrayList();
       for (int i = 0 ; i < methods.length ; i++)
       {
          Object ann = advisor.resolveAnnotation(methods[i], TestAnnotation.class);
@@ -76,24 +75,11 @@
          {
             hasAnnotation.add(methods[i].getName());
          }
-
-         CtMethod ctmethod = ReflectToJavassist.methodToJavassist(methods[i]);
-         Object[][] paramAnnotations = ctmethod.getParameterAnnotations();
-         for (int p = 0 ; p < paramAnnotations.length ; p++)
-         {
-            if (paramAnnotations[p].length > 0)
-            {
-               hasParameterAnnotation.add(methods[i].getName() + "1");
-            }
-         }
       }
       
       assertFalse("Expected to find annotation for 'method'", hasAnnotation.size() == 0);
-      assertFalse("Expected to find parameter annotation for 'method'", hasParameterAnnotation.size() == 0);
       assertTrue("Expected to find annotation for 'method' only, it was found for " + hasAnnotation, hasAnnotation.size() == 1);
-      assertTrue("Expected to find parameter annotation for 'method' only, it was found for " + hasParameterAnnotation, hasAnnotation.size() == 1);
       assertEquals("method", hasAnnotation.get(0));
-      assertEquals("method1", hasParameterAnnotation.get(0));
       assertTrue("Class was not woven", Advised.class.isAssignableFrom(POJO.class));
    }
 

Modified: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java	2006-12-18 23:18:47 UTC (rev 59106)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/POJO.java	2006-12-18 23:57:35 UTC (rev 59107)
@@ -28,8 +28,10 @@
  */
 public class POJO
 {
-   @TestAnnotation
-   public void method(int i, @TestAnnotation String s)
+   /**
+    * @@org.jboss.test.aop.regression.jbaop316annotationsinwrapperonly.TestAnnotation 
+    */
+   public void method(int i, String s)
    {
       
    }

Modified: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java	2006-12-18 23:18:47 UTC (rev 59106)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop316annotationsinwrapperonly/TestAnnotation.java	2006-12-18 23:57:35 UTC (rev 59107)
@@ -29,7 +29,6 @@
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
  * @version $Revision: 1.1 $
  */
- at Retention(RetentionPolicy.RUNTIME)
-public @interface TestAnnotation {
+public interface TestAnnotation {
 
 }



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 18:58:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 18:58:20 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59108 - branches/Branch_AOP_1_5/aop
Message-ID: <E1GwSNA-0004MN-4x@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-18 18:58:18 -0500 (Mon, 18 Dec 2006)
New Revision: 59108

Modified:
   branches/Branch_AOP_1_5/aop/build.xml
Log:
Bump up version to 1.5.3.beta1

Modified: branches/Branch_AOP_1_5/aop/build.xml
===================================================================
--- branches/Branch_AOP_1_5/aop/build.xml	2006-12-18 23:57:35 UTC (rev 59107)
+++ branches/Branch_AOP_1_5/aop/build.xml	2006-12-18 23:58:18 UTC (rev 59108)
@@ -57,7 +57,7 @@
     -->
 
    <target name="configure" unless="configure.disable">
-      <property name="aop.version" value="jboss-aop-snapshot-Branch_1_5"/>
+      <property name="aop.version" value="jboss-aop-1.5.3.Beta1"/>
       <property name="aop.title" value="JBoss AOP Framework"/>
 
       <!-- =================== -->
@@ -67,7 +67,7 @@
       <!-- Module name(s) & version -->
       <property name="module.name" value="aop"/>
       <property name="module.Name" value="JBoss AOP"/>
-      <property name="module.version" value="snapshot-Branch_AOP_1_5"/>
+      <property name="module.version" value="jboss-aop-1.5.3.Beta1"/>
 
       <!-- ========= -->
       <!-- Libraries -->



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 19:37:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 19:37:45 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59109 - projects
Message-ID: <E1GwSzJ-00058C-3e@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 19:37:43 -0500 (Mon, 18 Dec 2006)
New Revision: 59109

Added:
   projects/vfs/
Log:
Break out the vfs classes into a separate project




From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 19:39:01 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 19:39:01 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59110 - projects/vfs
Message-ID: <E1GwT0X-00058V-Mr@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 19:39:00 -0500 (Mon, 18 Dec 2006)
New Revision: 59110

Added:
   projects/vfs/trunk/
Log:
The vfs trunk




From gavin.king at jboss.com  Mon Dec 18 19:40:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 19:40:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GwT29-0005Aw-Bg@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 19:40:41

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  in and out in pages.xml
  
  Revision  Changes    Path
  1.12      +13 -3     jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- pages-1.1.dtd	18 Dec 2006 15:38:48 -0000	1.11
  +++ pages-1.1.dtd	19 Dec 2006 00:40:41 -0000	1.12
  @@ -9,7 +9,7 @@
   <!ELEMENT pages (page*)>
   <!ATTLIST pages no-conversation-view-id CDATA #IMPLIED>
   
  -<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|action|action-navigation)*>
  +<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|in|action|action-navigation)*>
   <!ATTLIST page action CDATA #IMPLIED>
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
  @@ -28,11 +28,11 @@
   <!ATTLIST action if CDATA #IMPLIED>
   <!ATTLIST action execute CDATA #REQUIRED>
   
  -<!ELEMENT action-navigation (((begin-conversation|end-conversation)?,(render|redirect))|(outcome*))>
  +<!ELEMENT action-navigation (((begin-conversation|end-conversation)?,(out*),(render|redirect))|(outcome*))>
   <!ATTLIST action-navigation from-action CDATA #IMPLIED>
   <!ATTLIST action-navigation evaluate CDATA #IMPLIED>
   
  -<!ELEMENT outcome ((begin-conversation|end-conversation)?,(render|redirect))>
  +<!ELEMENT outcome ((begin-conversation|end-conversation)?,(out*),(render|redirect))>
   <!ATTLIST outcome if-value CDATA #IMPLIED>
   <!ATTLIST outcome if CDATA #IMPLIED>
   
  @@ -44,6 +44,16 @@
   
   <!ELEMENT end-conversation EMPTY>
   
  +<!ELEMENT in EMPTY>
  +<!ATTLIST in name CDATA #REQUIRED>
  +<!ATTLIST in scope (stateless|request|page|conversation|session|business_process|application|STATELESS|REQUEST|PAGE|CONVERSATION|SESSION|BUSINESS_PROCESS|APPLICATION) #IMPLIED>
  +<!ATTLIST in value CDATA #REQUIRED>
  +
  +<!ELEMENT out EMPTY>
  +<!ATTLIST out name CDATA #REQUIRED>
  +<!ATTLIST out scope (stateless|request|page|conversation|session|business_process|application|STATELESS|REQUEST|PAGE|CONVERSATION|SESSION|BUSINESS_PROCESS|APPLICATION) "CONVERSATION">
  +<!ATTLIST out value CDATA #REQUIRED>
  +
   <!ELEMENT render EMPTY>
   <!ATTLIST render view-id CDATA #IMPLIED>
   
  
  
  


From gavin.king at jboss.com  Mon Dec 18 19:40:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 19:40:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GwT29-0005B3-Fp@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 19:40:41

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  in and out in pages.xml
  
  Revision  Changes    Path
  1.70      +44 -69    jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.69
  retrieving revision 1.70
  diff -u -b -r1.69 -r1.70
  --- Pages.java	18 Dec 2006 16:50:30 -0000	1.69
  +++ Pages.java	19 Dec 2006 00:40:41 -0000	1.70
  @@ -36,11 +36,13 @@
   import org.jboss.seam.pages.Action;
   import org.jboss.seam.pages.ActionNavigation;
   import org.jboss.seam.pages.ConversationControl;
  +import org.jboss.seam.pages.Input;
   import org.jboss.seam.pages.Outcome;
   import org.jboss.seam.pages.Page;
   import org.jboss.seam.pages.Param;
   import org.jboss.seam.pages.RedirectNavigationHandler;
   import org.jboss.seam.pages.RenderNavigationHandler;
  +import org.jboss.seam.pages.Output;
   import org.jboss.seam.util.Parameters;
   import org.jboss.seam.util.Resources;
   import org.jboss.seam.util.XML;
  @@ -97,7 +99,7 @@
       * @param actionOutcomeValue the outcome of the action method
       * @return true if a navigation rule was found
       */
  -   public boolean navigate(FacesContext context, String actionExpression, final String actionOutcomeValue)
  +   public boolean navigate(FacesContext context, String actionExpression, String actionOutcomeValue)
      {
         String viewId = context.getViewRoot().getViewId();
         if (viewId!=null)
  @@ -112,34 +114,7 @@
                  navigation = page.getDefaultNavigation();
               }
               
  -            if (navigation!=null)
  -            {
  -               
  -               String outcomeValue;
  -               if ( navigation.getOutcomeValueBinding()==null )
  -               {
  -                  outcomeValue = actionOutcomeValue;
  -               }
  -               else
  -               {
  -                  Object value = navigation.getOutcomeValueBinding().getValue();
  -                  outcomeValue = value==null ? null : value.toString();
  -               }
  -               
  -               for ( Outcome outcome: navigation.getOutcomes() )
  -               {
  -                  if ( outcome.matches(outcomeValue) )
  -                  {
  -                     outcome.getConversationControl().beginOrEndConversation();
  -                     outcome.getNavigationHandler().navigate(context);
  -                     return true;
  -                  }
  -               }
  -               
  -               navigation.getOutcome().getConversationControl().beginOrEndConversation();
  -               navigation.getOutcome().getNavigationHandler().navigate(context);
  -               
  -            }
  +            if ( navigation!=null && navigation.navigate(context, actionOutcomeValue) ) return true;  
               
            }
         }
  @@ -255,9 +230,10 @@
      
      /**
       * Call page actions, and validate the existence of a conversation
  -    * for pages which require a long-running conversation
  +    * for pages which require a long-running conversation, starting
  +    * with the most general view id, ending at the most specific
       */
  -   public boolean callActionsAndValidateConversation(FacesContext facesContext)
  +   public boolean enterPage(FacesContext facesContext)
      {
         boolean result = false;
         String viewId = facesContext.getViewRoot().getViewId();
  @@ -270,47 +246,13 @@
            }
            else
            {
  -            result = callAction(page, facesContext) || result;
  +            result = page.enter(facesContext) || result;
            }
         }
         return result;
      }
   
  -   /**
  -    * Call page actions, from most general view id to most specific
  -    */
  -   private boolean callAction(Page page, FacesContext facesContext)
  -   {
  -      boolean result = false;
  -      
  -      page.getConversationControl().beginOrEndConversation();
  -
  -      for ( Action action: page.getActions() )
  -      {
  -         if ( action.isExecutable() )
  -         {
  -            String outcome = action.getOutcome();
  -            String fromAction = outcome;
  -            
  -            if (outcome==null)
  -            {
  -                     fromAction = action.getMethodBinding().getExpressionString();
  -                     result = true;
  -                     outcome = toString( action.getMethodBinding().invoke() );
  -                     handleOutcome(facesContext, outcome, fromAction);
  -            }
  -            else
  -            {
  -               handleOutcome(facesContext, outcome, fromAction);
  -            }
  -         }
  -      }
  -      
  -      return result;
  -
  -   }
  -
  -   private static String toString(Object returnValue)
  +   public static String toString(Object returnValue)
      {
         return returnValue == null ? null : returnValue.toString();
      }
  @@ -318,7 +260,7 @@
      /**
       * Call the JSF navigation handler
       */
  -   private static void handleOutcome(FacesContext facesContext, String outcome, String fromAction)
  +   public static void handleOutcome(FacesContext facesContext, String outcome, String fromAction)
      {
         facesContext.getApplication().getNavigationHandler()
               .handleNavigation(facesContext, fromAction, outcome);
  @@ -729,6 +671,21 @@
         {
            page.setResourceBundleName(bundle);
         }
  +
  +      List<Element> moreChildElements = element.elements("in");
  +      for (Element child: moreChildElements)
  +      {
  +         Input input = new Input();
  +         input.setName( child.attributeValue("name") );
  +         input.setValue( Expressions.instance().createValueBinding( child.attributeValue("value") ) );
  +         String scopeName = child.attributeValue("scope");
  +         if (scopeName!=null)
  +         {
  +            input.setScope( ScopeType.valueOf( scopeName.toUpperCase() ) );
  +         }
  +         page.getInputs().add(input);
  +      }
  +      
         return page;
      }
   
  @@ -888,6 +845,24 @@
            final String viewId = redirect.attributeValue("view-id");
            outcome.setNavigationHandler( new RedirectNavigationHandler(viewId, params) );
         }
  +      List<Element> childElements = element.elements("out");
  +      for (Element child: childElements)
  +      {
  +         Output output = new Output();
  +         output.setName( child.attributeValue("name") );
  +         output.setValue( Expressions.instance().createValueBinding( child.attributeValue("value") ) );
  +         String scopeName = child.attributeValue("scope");
  +         if (scopeName==null)
  +         {
  +            output.setScope(ScopeType.CONVERSATION);
  +         }
  +         else
  +         {
  +            output.setScope( ScopeType.valueOf( scopeName.toUpperCase() ) );
  +         }
  +         outcome.getOutputs().add(output);
  +      }
  +      
      }
   
   }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 19:40:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 19:40:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf  ...
Message-ID: <E1GwT29-0005BA-KW@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 19:40:41

  Modified:    src/main/org/jboss/seam/jsf  AbstractSeamPhaseListener.java
  Log:
  in and out in pages.xml
  
  Revision  Changes    Path
  1.34      +3 -3      jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- AbstractSeamPhaseListener.java	18 Dec 2006 15:38:49 -0000	1.33
  +++ AbstractSeamPhaseListener.java	19 Dec 2006 00:40:41 -0000	1.34
  @@ -199,7 +199,7 @@
   
         selectDataModelRow( facesContext.getExternalContext().getRequestParameterMap() );
         
  -      callPageActions(event);
  +      enterPage(event);
         
         if ( facesContext.getResponseComplete() )
         {
  @@ -244,7 +244,7 @@
         Lifecycle.endRequest( facesContext.getExternalContext() );
      }
   
  -   private boolean callPageActions(PhaseEvent event)
  +   private boolean enterPage(PhaseEvent event)
      {
         Lifecycle.setPhaseId( PhaseId.INVOKE_APPLICATION );
         boolean actionsWereCalled = false;
  @@ -252,7 +252,7 @@
         {
            FacesContext facesContext = event.getFacesContext();
            actionsWereCalled = Pages.callAction(facesContext) || actionsWereCalled;
  -         actionsWereCalled = Pages.instance().callActionsAndValidateConversation(facesContext) || actionsWereCalled;
  +         actionsWereCalled = Pages.instance().enterPage(facesContext) || actionsWereCalled;
            return actionsWereCalled;
         }
         catch (RuntimeException re)
  
  
  


From gavin.king at jboss.com  Mon Dec 18 19:40:41 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 19:40:41 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pages          ...
Message-ID: <E1GwT29-0005Bj-T9@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 19:40:41

  Modified:    src/main/org/jboss/seam/pages          ActionNavigation.java
                        NavigationHandler.java Outcome.java Page.java
                        RedirectNavigationHandler.java
                        RenderNavigationHandler.java
  Added:       src/main/org/jboss/seam/pages          Input.java
                        Output.java Put.java
  Log:
  in and out in pages.xml
  
  Revision  Changes    Path
  1.3       +26 -0     jboss-seam/src/main/org/jboss/seam/pages/ActionNavigation.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActionNavigation.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/ActionNavigation.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ActionNavigation.java	18 Dec 2006 15:38:49 -0000	1.2
  +++ ActionNavigation.java	19 Dec 2006 00:40:41 -0000	1.3
  @@ -6,6 +6,8 @@
   import java.util.ArrayList;
   import java.util.List;
   
  +import javax.faces.context.FacesContext;
  +
   import org.jboss.seam.core.Expressions.ValueBinding;
   
   public final class ActionNavigation
  @@ -39,4 +41,28 @@
         this.outcome = outcome;
      }
   
  +   public boolean navigate(FacesContext context, final String actionOutcomeValue)
  +   {
  +      String outcomeValue;
  +      if ( getOutcomeValueBinding()==null )
  +      {
  +         outcomeValue = actionOutcomeValue;
  +      }
  +      else
  +      {
  +         Object value = getOutcomeValueBinding().getValue();
  +         outcomeValue = value==null ? null : value.toString();
  +      }
  +      
  +      for ( Outcome outcome: getOutcomes() )
  +      {
  +         if ( outcome.matches(outcomeValue) )
  +         {
  +            return outcome.execute(context);
  +         }
  +      }
  +      
  +      return getOutcome().execute(context);
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.2       +1 -1      jboss-seam/src/main/org/jboss/seam/pages/NavigationHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NavigationHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/NavigationHandler.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- NavigationHandler.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ NavigationHandler.java	19 Dec 2006 00:40:41 -0000	1.2
  @@ -9,5 +9,5 @@
   
   public abstract class NavigationHandler extends Navigator
   {
  -   public abstract void navigate(FacesContext context);
  +   public abstract boolean navigate(FacesContext context);
   }
  \ No newline at end of file
  
  
  
  1.3       +20 -1     jboss-seam/src/main/org/jboss/seam/pages/Outcome.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Outcome.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/Outcome.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Outcome.java	18 Dec 2006 15:38:49 -0000	1.2
  +++ Outcome.java	19 Dec 2006 00:40:41 -0000	1.3
  @@ -3,6 +3,9 @@
    */
   package org.jboss.seam.pages;
   
  +import java.util.ArrayList;
  +import java.util.List;
  +
   import javax.faces.context.FacesContext;
   
   import org.jboss.seam.core.Expressions.ValueBinding;
  @@ -11,10 +14,14 @@
   {
      private String value;
      private ValueBinding expression;
  +   private List<Output> outputs = new ArrayList<Output>();
      private ConversationControl conversationControl = new ConversationControl();
      private NavigationHandler navigationHandler = new NavigationHandler() { 
         @Override
  -      public void navigate(FacesContext context) {}
  +      public boolean navigate(FacesContext context) 
  +      {
  +         return false;
  +      }
      };
   
      public boolean matches(String actualValue)
  @@ -58,4 +65,16 @@
      {
         this.value = value;
      }
  +
  +   public List<Output> getOutputs()
  +   {
  +      return outputs;
  +   }
  +
  +   public boolean execute(FacesContext context)
  +   {
  +      getConversationControl().beginOrEndConversation();
  +      for ( Output output: getOutputs() ) output.out();
  +      return getNavigationHandler().navigate(context);
  +   }
   }
  \ No newline at end of file
  
  
  
  1.3       +46 -0     jboss-seam/src/main/org/jboss/seam/pages/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/Page.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Page.java	18 Dec 2006 16:50:31 -0000	1.2
  +++ Page.java	19 Dec 2006 00:40:41 -0000	1.3
  @@ -6,8 +6,11 @@
   import java.util.Map;
   import java.util.MissingResourceException;
   
  +import javax.faces.context.FacesContext;
  +
   import org.jboss.seam.core.Interpolator;
   import org.jboss.seam.core.Locale;
  +import org.jboss.seam.core.Pages;
   
   /**
    * Metadata about page actions, page parameters, action navigation,
  @@ -22,6 +25,7 @@
      private String resourceBundleName;
      private boolean switchEnabled = true;
      private List<Param> parameters = new ArrayList<Param>();
  +   private List<Input> inputs = new ArrayList<Input>();
      private List<Action> actions = new ArrayList<Action>();
      private Map<String, ActionNavigation> navigations = new HashMap<String, ActionNavigation>();
      private ActionNavigation defaultNavigation;
  @@ -176,4 +180,46 @@
         return actions;
      }
   
  +   /**
  +    * Call page actions, in order they appear in XML, and
  +    * handle conversation begin/end 
  +    */
  +   public boolean enter(FacesContext facesContext)
  +   {
  +      boolean result = false;
  +      
  +      getConversationControl().beginOrEndConversation();
  +      
  +      for ( Input in: getInputs() ) in.in();
  +   
  +      for ( Action action: getActions() )
  +      {
  +         if ( action.isExecutable() )
  +         {
  +            String outcome = action.getOutcome();
  +            String fromAction = outcome;
  +            
  +            if (outcome==null)
  +            {
  +               fromAction = action.getMethodBinding().getExpressionString();
  +               result = true;
  +               outcome = Pages.toString( action.getMethodBinding().invoke() );
  +               Pages.handleOutcome(facesContext, outcome, fromAction);
  +            }
  +            else
  +            {
  +               Pages.handleOutcome(facesContext, outcome, fromAction);
  +            }
  +         }
  +      }
  +      
  +      return result;
  +   
  +   }
  +
  +   public List<Input> getInputs()
  +   {
  +      return inputs;
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.2       +2 -1      jboss-seam/src/main/org/jboss/seam/pages/RedirectNavigationHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RedirectNavigationHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/RedirectNavigationHandler.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RedirectNavigationHandler.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ RedirectNavigationHandler.java	19 Dec 2006 00:40:41 -0000	1.2
  @@ -21,7 +21,7 @@
      }
   
      @Override
  -   public void navigate(FacesContext context)
  +   public boolean navigate(FacesContext context)
      {
         Map<String, Object> parameters = new HashMap<String, Object>();
         for ( Param pageParameter: params )
  @@ -29,5 +29,6 @@
            parameters.put( pageParameter.getName(), pageParameter.getValueFromModel(context) );
         }
         redirect(viewId, parameters);
  +      return true;
      }
   }
  \ No newline at end of file
  
  
  
  1.2       +2 -1      jboss-seam/src/main/org/jboss/seam/pages/RenderNavigationHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RenderNavigationHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/RenderNavigationHandler.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RenderNavigationHandler.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ RenderNavigationHandler.java	19 Dec 2006 00:40:41 -0000	1.2
  @@ -15,8 +15,9 @@
      }
   
      @Override
  -   public void navigate(FacesContext context)
  +   public boolean navigate(FacesContext context)
      {
         render(viewId);
  +      return true;
      }
   }
  \ No newline at end of file
  
  
  
  1.1      date: 2006/12/19 00:40:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Input.java
  
  Index: Input.java
  ===================================================================
  package org.jboss.seam.pages;
  
  import org.jboss.seam.Component;
  
  
  public class Input extends Put
  {
     public void in()
     {
        Object object = getScope()==null ?
                 Component.getInstance( getName() ) :
                 getScope().getContext().get( getName() );
        getValue().setValue( object );
     }
     
  }
  
  
  
  1.1      date: 2006/12/19 00:40:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Output.java
  
  Index: Output.java
  ===================================================================
  package org.jboss.seam.pages;
  
  
  public class Output extends Put
  {
     public void out()
     {
        getScope().getContext().set( getName(), getValue().getValue() );
     }
     
  }
  
  
  
  1.1      date: 2006/12/19 00:40:41;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Put.java
  
  Index: Put.java
  ===================================================================
  package org.jboss.seam.pages;
  
  import org.jboss.seam.ScopeType;
  import org.jboss.seam.core.Expressions.ValueBinding;
  
  public class Put
  {
     private String name;
     private ScopeType scope;
     private ValueBinding value;
  
     public String getName()
     {
        return name;
     }
     public void setName(String name)
     {
        this.name = name;
     }
     public ScopeType getScope()
     {
        return scope;
     }
     public void setScope(ScopeType scope)
     {
        this.scope = scope;
     }
     public ValueBinding getValue()
     {
        return value;
     }
     public void setValue(ValueBinding value)
     {
        this.value = value;
     }
     
  }
  
  
  


From gavin.king at jboss.com  Mon Dec 18 19:51:12 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 19:51:12 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GwTCK-0005KT-LS@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 19:51:12

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  minor
  
  Revision  Changes    Path
  1.13      +1 -1      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- pages-1.1.dtd	19 Dec 2006 00:40:41 -0000	1.12
  +++ pages-1.1.dtd	19 Dec 2006 00:51:12 -0000	1.13
  @@ -9,7 +9,7 @@
   <!ELEMENT pages (page*)>
   <!ATTLIST pages no-conversation-view-id CDATA #IMPLIED>
   
  -<!ELEMENT page (#PCDATA|description|param|end-conversation|begin-conversation|in|action|action-navigation)*>
  +<!ELEMENT page (#PCDATA|description|param|in|begin-conversation|end-conversation|action|action-navigation)*>
   <!ATTLIST page action CDATA #IMPLIED>
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:04:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:04:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r59111 - in projects/vfs/trunk: . src
	src/main src/test
Message-ID: <E1GwTPa-0005hK-Fd@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:04:51 -0500 (Mon, 18 Dec 2006)
New Revision: 59111

Added:
   projects/vfs/trunk/.classpath
   projects/vfs/trunk/.project
   projects/vfs/trunk/pom.xml
   projects/vfs/trunk/src/
   projects/vfs/trunk/src/main/
   projects/vfs/trunk/src/main/java/
   projects/vfs/trunk/src/test/
   projects/vfs/trunk/src/test/java/
Modified:
   projects/vfs/trunk/
Log:
Setup vfs project structure


Property changes on: projects/vfs/trunk
___________________________________________________________________
Name: svn:ignore
   + target


Added: projects/vfs/trunk/.classpath
===================================================================
--- projects/vfs/trunk/.classpath	2006-12-19 00:39:00 UTC (rev 59110)
+++ projects/vfs/trunk/.classpath	2006-12-19 01:04:51 UTC (rev 59111)
@@ -0,0 +1,7 @@
+<classpath>
+  <classpathentry kind="src" path="src/main/java"/>
+  <classpathentry kind="src" path="src/test/java" output="target/test-classes"/>
+  <classpathentry kind="output" path="target/classes"/>
+  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
+</classpath>
\ No newline at end of file

Added: projects/vfs/trunk/.project
===================================================================
--- projects/vfs/trunk/.project	2006-12-19 00:39:00 UTC (rev 59110)
+++ projects/vfs/trunk/.project	2006-12-19 01:04:51 UTC (rev 59111)
@@ -0,0 +1,14 @@
+<projectDescription>
+  <name>jboss-vfs</name>
+  <comment/>
+  <projects/>
+  <buildSpec>
+    <buildCommand>
+      <name>org.eclipse.jdt.core.javabuilder</name>
+      <arguments/>
+    </buildCommand>
+  </buildSpec>
+  <natures>
+    <nature>org.eclipse.jdt.core.javanature</nature>
+  </natures>
+</projectDescription>
\ No newline at end of file

Added: projects/vfs/trunk/pom.xml
===================================================================
--- projects/vfs/trunk/pom.xml	2006-12-19 00:39:00 UTC (rev 59110)
+++ projects/vfs/trunk/pom.xml	2006-12-19 01:04:51 UTC (rev 59111)
@@ -0,0 +1,18 @@
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+  <groupId>jboss</groupId>
+  <artifactId>jboss-vfs</artifactId>
+  <packaging>jar</packaging>
+  <version>1.0-SNAPSHOT</version>
+  <name>jboss-vfs</name>
+  <url>http://maven.apache.org</url>
+  <dependencies>
+    <dependency>
+      <groupId>junit</groupId>
+      <artifactId>junit</artifactId>
+      <version>3.8.1</version>
+      <scope>test</scope>
+    </dependency>
+  </dependencies>
+</project>


Property changes on: projects/vfs/trunk/pom.xml
___________________________________________________________________
Name: svn:eol-style
   + native



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:09:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:09:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r59112 - in
	projects/vfs/trunk/src/main/java: . org
Message-ID: <E1GwTUE-0005nP-GE@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:09:41 -0500 (Mon, 18 Dec 2006)
New Revision: 59112

Added:
   projects/vfs/trunk/src/main/java/org/
   projects/vfs/trunk/src/main/java/org/jboss/
Log:
Add the org.jboss.virtual package root



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:09:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:09:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r59113 -
	projects/vfs/trunk/src/main/java/org/jboss
Message-ID: <E1GwTUH-0005ni-Kr@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:09:44 -0500 (Mon, 18 Dec 2006)
New Revision: 59113

Added:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/
Log:
Add the org.jboss.virtual package root



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:13:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:13:18 -0500
Subject: [jboss-cvs] JBossAS SVN: r59114 -
	projects/vfs/trunk/src/main/java/org/jboss/virtual
Message-ID: <E1GwTXi-0005tH-QC@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:13:16 -0500 (Mon, 18 Dec 2006)
New Revision: 59114

Added:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/virtual/
Log:
Copy the mc virtual packages to the vfs project trunk

Copied: projects/vfs/trunk/src/main/java/org/jboss/virtual/virtual (from rev 59113, projects/microcontainer/trunk/container/src/main/org/jboss/virtual)



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:14:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:14:12 -0500
Subject: [jboss-cvs] JBossAS SVN: r59115 -
	projects/vfs/trunk/src/main/java/org/jboss/virtual
Message-ID: <E1GwTYa-0005ta-68@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:14:10 -0500 (Mon, 18 Dec 2006)
New Revision: 59115

Removed:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/virtual/
Log:




From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:14:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:14:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r59116 -
	projects/vfs/trunk/src/main/java/org/jboss
Message-ID: <E1GwTZ6-0005tt-5h@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:14:42 -0500 (Mon, 18 Dec 2006)
New Revision: 59116

Removed:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/
Log:




From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:15:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:15:00 -0500
Subject: [jboss-cvs] JBossAS SVN: r59117 -
	projects/vfs/trunk/src/main/java/org/jboss
Message-ID: <E1GwTZM-0005uC-GB@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:14:58 -0500 (Mon, 18 Dec 2006)
New Revision: 59117

Added:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/
Log:
Copy the mc virtual packages to the vfs project trunk

Copied: projects/vfs/trunk/src/main/java/org/jboss/virtual (from rev 59116, projects/microcontainer/trunk/container/src/main/org/jboss/virtual)



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:17:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:17:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r59118 -
	projects/vfs/trunk/src/main/java/org/jboss/virtual
Message-ID: <E1GwTcA-0005zT-Si@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:17:53 -0500 (Mon, 18 Dec 2006)
New Revision: 59118

Removed:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/classloading/
Log:
Drop the classloading package



From vivekl at redhat.com  Mon Dec 18 20:20:07 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:20:07 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795
	- New directory ...
Message-ID: <E1GwTeJ-00060p-CC@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:20:07

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795 added to the repository


From vivekl at redhat.com  Mon Dec 18 20:20:51 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:20:51 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/bin
	- New directory ...
Message-ID: <E1GwTf1-00062V-FS@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:20:51

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/bin added to the repository


From vivekl at redhat.com  Mon Dec 18 20:20:51 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:20:51 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib
	- New directory ...
Message-ID: <E1GwTf1-00062Z-Im@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:20:51

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib added to the repository


From vivekl at redhat.com  Mon Dec 18 20:20:51 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:20:51 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources
	- New directory ...
Message-ID: <E1GwTf1-00062d-Rc@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:20:51

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources added to the repository


From vivekl at redhat.com  Mon Dec 18 20:28:13 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:28:13 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795 ...
Message-ID: <E1GwTm9-00069g-Tq@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:28:13

  Added:       jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795 
                        component-info.xml
  Log:
  EJB3 deployer correspnding to rev 58876 of JBoss_4_0_5_GA_EJBTHREE-798 branch.
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:28:13;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/ejb3-component-info">
  
     <component id="jboss/ejb3"
                licenseType="lgpl"
                version="1.0.0.CR9-jboss4.0.5-ejbthree795"
                description="The EJB3 deployer for integration with jboss-4.0.x">
        <!-- cvsroot=":ext:cvs.devel.redhat.com:/cvs/dist/jbossas-ejb3"
             tag="jbossas-ejb3-1_0_0-0_1_rc9_el4s1_5"
          -->
        <artifact id="ejb3-clustered-sfsbcache-service.xml"/>
        <artifact id="ejb3-entity-cache-service.xml"/>
        <artifact id="ejb3-interceptors-aop.xml"/>
        <artifact id="ejb3.deployer" />
        <artifact id="hibernate-client.jar"/>
        <artifact id="jboss-ejb3-client.jar"/>
  
        <import componentref="javassist">
          <compatible version="3.2.0.CR1"/>
          <compatible version="3.2.0.CR2"/>
        </import>
        <import componentref="hibernate-annotations">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="hibernate-entitymanager">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="jboss/remoting">
          <compatible version="1.4.1_final"/>
          <compatible version="1.4.2.GA"/>
        </import>
        <import componentref="jboss/aop">
          <compatible version="1.5.1.GA"/>
          <compatible version="1.5.2.GA"/>
        </import>
  
        <export>
           <include input="hibernate-client.jar"/>
           <include input="jboss-ejb3-client.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From vivekl at redhat.com  Mon Dec 18 20:28:14 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:28:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/bin
	...
Message-ID: <E1GwTmA-00069m-0s@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:28:14

  Added:       jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/bin 
                        ejb3.deployer
  Log:
  EJB3 deployer correspnding to rev 58876 of JBoss_4_0_5_GA_EJBTHREE-798 branch.
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:28:13;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/bin/ejb3.deployer
  
  	<<Binary file>>
  
  


From vivekl at redhat.com  Mon Dec 18 20:28:14 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:28:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib
	...
Message-ID: <E1GwTmA-00069u-6o@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:28:14

  Added:       jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib  
                        hibernate-client.jar jboss-ejb3-client.jar
  Log:
  EJB3 deployer correspnding to rev 58876 of JBoss_4_0_5_GA_EJBTHREE-798 branch.
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:28:14;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib/hibernate-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:28:14;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib/jboss-ejb3-client.jar
  
  	<<Binary file>>
  
  


From vivekl at redhat.com  Mon Dec 18 20:28:14 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 20:28:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources
	...
Message-ID: <E1GwTmA-0006A7-BA@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 20:28:14

  Added:       jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources   
                        ejb3-clustered-sfsbcache-service.xml
                        ejb3-entity-cache-service.xml
                        ejb3-interceptors-aop.xml
  Log:
  EJB3 deployer correspnding to rev 58876 of JBoss_4_0_5_GA_EJBTHREE-798 branch.
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:28:14;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources/ejb3-clustered-sfsbcache-service.xml
  
  Index: ejb3-clustered-sfsbcache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
     <mbean code="org.jboss.ejb3.cache.tree.PassivationTreeCache" name="jboss.cache:service=EJB3SFSBClusteredCache">
     
        <!-- uncomment next three statements if using JGroups multiplexer,
               requires JGroups 2.3 or later, JBossCache 1.4 or later -->
        <!--
        <depends>jgroups.mux:name=Multiplexer</depends>
        <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
        <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
        -->
        
        <!--
                Node locking level : SERIALIZABLE
                                     REPEATABLE_READ (default)
                                     READ_COMMITTED
                                     READ_UNCOMMITTED
                                     NONE
        -->
        <attribute name="IsolationLevel">READ_UNCOMMITTED</attribute>
  
        <!--     Valid modes are LOCAL
                                 REPL_ASYNC
                                 REPL_SYNC
        -->
        <attribute name="CacheMode">REPL_SYNC</attribute>
  
        <attribute name="ClusterName">SFSB-Cache</attribute>
  
        <attribute name="ClusterConfig">
           <config>
              <!-- 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="45551" ip_ttl="${jgroups.mcast.ip_ttl:64}" 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"/>
           </config>
        </attribute>
  
        <!--    Number of milliseconds to wait until all responses for a
                synchronous call have been received.
        -->
        <attribute name="SyncReplTimeout">10000</attribute>
  
        <!--  Max number of milliseconds to wait for a lock acquisition -->
        <attribute name="LockAcquisitionTimeout">15000</attribute>
  
        <!--  Name of the eviction policy class. -->
        <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
        <!--  Specific eviction policy configurations. This is LRU -->
        <attribute name="EvictionPolicyConfig">
           <config>
              <attribute name="wakeUpIntervalSeconds">5</attribute>
              <name>statefulClustered</name>
              <!-- So default region would never timeout -->
              <region name="/_default_">
                 <attribute name="maxNodes">0</attribute>
                 <attribute name="timeToIdleSeconds">0</attribute>
              </region>
  
           </config>
        </attribute>
  
  
        <!-- New 1.3.x cache loader config block -->
        <!-- Note this is used for AS5.0 only -->
        <attribute name="CacheLoaderConfiguration">
            <config>
                <!-- We need to turn it on
                <passivation>false</passivation>
                -->
                <passivation>true</passivation>
                <preload>/</preload>
                <shared>false</shared>
  
                <cacheloader>
                    <class>org.jboss.cache.loader.FileCacheLoader</class>
                        <!--
                        -->
                    <properties>
                         location=${jboss.server.data.dir}${/}sfsb
                    </properties>
                    <async>false</async>
                    <fetchPersistentState>false</fetchPersistentState>
                    <ignoreModifications>false</ignoreModifications>
                </cacheloader>
  
            </config>
        </attribute>
  
     </mbean>
  
  </server>
  
  
  
  
  1.1      date: 2006/12/19 01:28:14;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources/ejb3-entity-cache-service.xml
  
  Index: ejb3-entity-cache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
  
    <!--  ====================================================================  -->
    <!--  Defines TreeCache configuration                                       -->
    <!--  ====================================================================  -->
    <mbean code="org.jboss.cache.TreeCache" name="jboss.cache:service=EJB3EntityTreeCache">
      <depends>jboss:service=Naming</depends>
      <depends>jboss:service=TransactionManager</depends>
      
      <!-- uncomment next three statements if using JGroups multiplexer,
            requires JGroups 2.3 or later, JBossCache 1.4 or later -->
      <!--
      <depends>jgroups.mux:name=Multiplexer</depends>
      <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
      <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
      -->
  
      <!-- Configure the TransactionManager -->
      <attribute name="TransactionManagerLookupClass">org.jboss.cache.JBossTransactionManagerLookup</attribute>
  
      <!--
              Node locking level : SERIALIZABLE
                                   REPEATABLE_READ (default)
                                   READ_COMMITTED
                                   READ_UNCOMMITTED
                                   NONE
      -->
      <attribute name="IsolationLevel">REPEATABLE_READ</attribute>
  
      <!--     Valid modes are LOCAL
                               REPL_ASYNC
                               REPL_SYNC
      -->
      <attribute name="CacheMode">REPL_SYNC</attribute>
  
      <!-- Name of cluster. Needs to be the same for all clusters, in order
               to find each other -->
      <attribute name="ClusterName">EJB3-entity-cache</attribute>
  
      <!-- Must be true if any entity deployment uses a scoped classloader -->
      <attribute name="UseRegionBasedMarshalling">true</attribute>
      <!-- Must match the value of "UseRegionBasedMarshalling" -->
      <attribute name="InactiveOnStartup">true</attribute>
      
      <attribute name="ClusterConfig">
        <config>
          <!-- 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" />
        </config>
      </attribute>
  
      <!--    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
      -->
      <attribute name="InitialStateRetrievalTimeout">5000</attribute>
  
      <!--    Number of milliseconds to wait until all responses for a
              synchronous call have been received.
      -->
      <attribute name="SyncReplTimeout">10000</attribute>
  
      <!--  Max number of milliseconds to wait for a lock acquisition -->
      <attribute name="LockAcquisitionTimeout">15000</attribute>
  
      <!--  Name of the eviction policy class. -->
      <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
      <!--  Specific eviction policy configurations. This is LRU -->
      <attribute name="EvictionPolicyConfig">
        <config>
          <attribute name="wakeUpIntervalSeconds">5</attribute>
          <!--  Cache wide default -->
          <region name="/_default_">
           <attribute name="maxNodes">5000</attribute>
           <attribute name="timeToLiveSeconds">1000</attribute>
         </region>
        </config>
      </attribute>
  
    </mbean>
  
  </server>
  
  
  
  
  1.1      date: 2006/12/19 01:28:14;  author: vivekl;  state: Exp;repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources/ejb3-interceptors-aop.xml
  
  Index: ejb3-interceptors-aop.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE aop PUBLIC
     "-//JBoss//DTD JBOSS AOP 1.0//EN"
     "http://www.jboss.org/aop/dtd/jboss-aop_1_0.dtd">
  
  <aop>
     <interceptor class="org.jboss.aspects.remoting.InvokeRemoteInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.security.SecurityClientInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.tx.ClientTxPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.remoting.IsLocalInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.remoting.ClusterChooserInterceptor" scope="PER_VM"/>
  
     <interceptor class="org.jboss.aspects.tx.TxPropagationInterceptor" scope="PER_VM"/>
  
     <stack name="ServiceClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <interceptor class="org.jboss.ejb3.asynchronous.AsynchronousInterceptor" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.ENCPropagationInterceptor" scope="PER_VM"/>
     <interceptor name="Basic Authorization" factory="org.jboss.ejb3.security.RoleBasedAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor name="JACC Authorization" factory="org.jboss.ejb3.security.JaccAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.AuthenticationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateless.StatelessInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.StatefulInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.service.ServiceSingletonInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.cache.StatefulReplicationInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.stateful.StatefulRemoveFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.tx.TxInterceptorFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.AllowedOperationsInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor" scope="PER_VM"/>
  
     <domain name="Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="JACC Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Base Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="JACC Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
  
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="Embedded Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.NoPassivationCache.class)
        </annotation>
  
     </domain>
  
     <domain name="Message Driven Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
     
     <domain name="Consumer Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND (has(* *->@org.jboss.annotation.ejb.CurrentMessage(..)) OR hasfield(* *->@org.jboss.annotation.ejb.CurrentMessage))">
           <interceptor-ref name="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
     <domain name="JACC Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
  
  </aop>
  
  


From scott.stark at jboss.com  Mon Dec 18 20:36:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 20:36:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA ...
Message-ID: <E1GwTtu-0006JA-7M@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 20:36:14

  Added:       maven2/jboss/jboss-common-core/2.0.3.GA        
                        jboss-common-core-2.0.3.GA-sources.jar
                        jboss-common-core-2.0.3.GA-sources.jar.md5
                        jboss-common-core-2.0.3.GA-sources.jar.sha1
                        jboss-common-core-2.0.3.GA.jar
                        jboss-common-core-2.0.3.GA.jar.md5
                        jboss-common-core-2.0.3.GA.jar.sha1
                        jboss-common-core-2.0.3.GA.pom.md5
                        jboss-common-core-2.0.3.GA.pom.sha1
  Log:
  Add the 2.0.3.GA release to the maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar.md5
  
  Index: jboss-common-core-2.0.3.GA-sources.jar.md5
  ===================================================================
  3a1d3c6d8a2d1595460bea71925bb0ff
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar.sha1
  
  Index: jboss-common-core-2.0.3.GA-sources.jar.sha1
  ===================================================================
  39b18c218da1e31a571997c79dcb589885fb2e1e
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar.md5
  
  Index: jboss-common-core-2.0.3.GA.jar.md5
  ===================================================================
  672338faf55dd6e9c3bd1c3958176785
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar.sha1
  
  Index: jboss-common-core-2.0.3.GA.jar.sha1
  ===================================================================
  95822ed4a4ca2b59dffaf94b8506a97d4950cbbc
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.pom.md5
  
  Index: jboss-common-core-2.0.3.GA.pom.md5
  ===================================================================
  b962eb209e034fcc5b403ebd81bd3f9f
  
  
  1.1      date: 2006/12/19 01:36:14;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.pom.sha1
  
  Index: jboss-common-core-2.0.3.GA.pom.sha1
  ===================================================================
  f668c8684ae90ae480b1c83ff85207da952f7e58
  
  


From gavin.king at jboss.com  Mon Dec 18 20:38:51 2006
From: gavin.king at jboss.com (Gavin King)
Date: Mon, 18 Dec 2006 20:38:51 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1GwTwR-0006JW-9D@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/18 20:38:51

  Modified:    examples/booking/src/org/jboss/seam/example/booking  
                        Register.java RegisterAction.java
  Log:
  oops
  
  Revision  Changes    Path
  1.3       +2 -1      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Register.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Register.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/Register.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- Register.java	17 Dec 2006 01:04:51 -0000	1.2
  +++ Register.java	19 Dec 2006 01:38:51 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: Register.java,v 1.2 2006/12/17 01:04:51 gavin Exp $
  +//$Id: Register.java,v 1.3 2006/12/19 01:38:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import javax.ejb.Local;
  @@ -7,6 +7,7 @@
   public interface Register
   {
      public void register();
  +   public void invalid();
      public String getVerify();
      public void setVerify(String verify);
      public boolean isRegistered();
  
  
  
  1.17      +6 -1      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/RegisterAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegisterAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/RegisterAction.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- RegisterAction.java	17 Dec 2006 01:04:51 -0000	1.16
  +++ RegisterAction.java	19 Dec 2006 01:38:51 -0000	1.17
  @@ -1,4 +1,4 @@
  -//$Id: RegisterAction.java,v 1.16 2006/12/17 01:04:51 gavin Exp $
  +//$Id: RegisterAction.java,v 1.17 2006/12/19 01:38:51 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static org.jboss.seam.ScopeType.EVENT;
  @@ -60,6 +60,11 @@
         }
      }
      
  +   public void invalid()
  +   {
  +      facesMessages.add("Please try again");
  +   }
  +   
      public boolean isRegistered()
      {
         return registered;
  
  
  


From scott.stark at jboss.com  Mon Dec 18 20:40:26 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 20:40:26 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA ...
Message-ID: <E1GwTxy-0006Li-JF@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 20:40:26

  Added:       maven2/jboss/jboss-logging-spi/2.0.3.GA         
                        jboss-logging-spi-2.0.3.GA-sources.jar
                        jboss-logging-spi-2.0.3.GA-sources.jar.md5
                        jboss-logging-spi-2.0.3.GA-sources.jar.sha1
                        jboss-logging-spi-2.0.3.GA.jar
                        jboss-logging-spi-2.0.3.GA.jar.md5
                        jboss-logging-spi-2.0.3.GA.jar.sha1
                        jboss-logging-spi-2.0.3.GA.pom
                        jboss-logging-spi-2.0.3.GA.pom.md5
                        jboss-logging-spi-2.0.3.GA.pom.sha1
  Log:
  Add the 2.0.3.GA jboss-logging-spi release to maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar.md5
  
  Index: jboss-logging-spi-2.0.3.GA-sources.jar.md5
  ===================================================================
  51c83bfba34f7b3e42457c31dacadf1f
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar.sha1
  
  Index: jboss-logging-spi-2.0.3.GA-sources.jar.sha1
  ===================================================================
  520532637d6f6b551cee0f847cf69196eb8cdae4
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar.md5
  
  Index: jboss-logging-spi-2.0.3.GA.jar.md5
  ===================================================================
  ec522bcd984a77bc99895ccb3f969f48
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar.sha1
  
  Index: jboss-logging-spi-2.0.3.GA.jar.sha1
  ===================================================================
  1ab1a76d0acfeb80c549d7bb1fa0a2ea8526c57f
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.pom
  
  Index: jboss-logging-spi-2.0.3.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-logging-spi</artifactId>
    <name>JBoss Logging Programming Interface</name>
    <version>2.0.3.GA</version>
    <description>The JBoss Logging Framework Programming Interface</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <finalName>${artifactId}</finalName>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.0</version>
          <configuration>
            <optimize>true</optimize>
            <source>1.4</source>
            <target>1.4</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
          <inherited>true</inherited>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <snapshots />
        <id>jboss</id>
        <name>JBoss Inc. Repository</name>
        <url>http://repository.jboss.com/maven2/</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>jbosspluginrepo</id>
        <name>jboss plugin repository</name>
        <url>http://repository.jboss.com/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>central</id>
        <url>http://mirrors.ibiblio.org/pub/mirrors/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <distributionManagement>
      <repository>
        <id>cvs-file-repository</id>
        <url>file://${maven.cvs.root}</url>
      </repository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.pom.md5
  
  Index: jboss-logging-spi-2.0.3.GA.pom.md5
  ===================================================================
  762f4af695fe736ba827361a86307799
  
  
  1.1      date: 2006/12/19 01:40:26;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.pom.sha1
  
  Index: jboss-logging-spi-2.0.3.GA.pom.sha1
  ===================================================================
  1253277714ebf886390ad34a938222396846c924
  
  


From scott.stark at jboss.com  Mon Dec 18 20:42:47 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 20:42:47 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA ...
Message-ID: <E1GwU0F-0006Pn-7v@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 20:42:47

  Added:       maven2/jboss/jboss-logging-log4j/2.0.3.GA         
                        jboss-logging-log4j-2.0.3.GA-sources.jar
                        jboss-logging-log4j-2.0.3.GA-sources.jar.md5
                        jboss-logging-log4j-2.0.3.GA-sources.jar.sha1
                        jboss-logging-log4j-2.0.3.GA.jar
                        jboss-logging-log4j-2.0.3.GA.jar.md5
                        jboss-logging-log4j-2.0.3.GA.jar.sha1
                        jboss-logging-log4j-2.0.3.GA.pom
                        jboss-logging-log4j-2.0.3.GA.pom.md5
                        jboss-logging-log4j-2.0.3.GA.pom.sha1
  Log:
  Add the jboss-logging-log4j 2.0.3.GA to the maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar.md5
  
  Index: jboss-logging-log4j-2.0.3.GA-sources.jar.md5
  ===================================================================
  f533f5865b86154f34567f5a10976857
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar.sha1
  
  Index: jboss-logging-log4j-2.0.3.GA-sources.jar.sha1
  ===================================================================
  89e1f2ea914df0bb0a04a5ba6e36597bf33c2a32
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar.md5
  
  Index: jboss-logging-log4j-2.0.3.GA.jar.md5
  ===================================================================
  1c749f1b06b642e153f81af053f7658c
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar.sha1
  
  Index: jboss-logging-log4j-2.0.3.GA.jar.sha1
  ===================================================================
  1f728dea9c7faa671a5aaefe2364d996291d0c33
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.pom
  
  Index: jboss-logging-log4j-2.0.3.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-logging-log4j</artifactId>
    <name>JBoss Logging Log4j</name>
    <version>2.0.3.GA</version>
    <description>JBoss Logging Log4j classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <finalName>${artifactId}</finalName>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.0</version>
          <configuration>
            <optimize>true</optimize>
            <source>1.4</source>
            <target>1.4</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
          <inherited>true</inherited>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <snapshots />
        <id>jboss</id>
        <name>JBoss Inc. Repository</name>
        <url>http://repository.jboss.com/maven2/</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>jbosspluginrepo</id>
        <name>jboss plugin repository</name>
        <url>http://repository.jboss.com/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>central</id>
        <url>http://mirrors.ibiblio.org/pub/mirrors/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.3.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.3.GA</version>
        <scope>compile</scope>
      </dependency>
      <dependency>
        <groupId>apache-log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.8</version>
        <scope>compile</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <repository>
        <id>cvs-file-repository</id>
        <url>file://${maven.cvs.root}</url>
      </repository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.pom.md5
  
  Index: jboss-logging-log4j-2.0.3.GA.pom.md5
  ===================================================================
  239c73eb757eae1e655bc049d2e28633
  
  
  1.1      date: 2006/12/19 01:42:47;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.pom.sha1
  
  Index: jboss-logging-log4j-2.0.3.GA.pom.sha1
  ===================================================================
  fba21990a7a6548e0ad6c92ea4add3978cf23181
  
  


From scott.stark at jboss.com  Mon Dec 18 20:43:39 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 20:43:39 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA ...
Message-ID: <E1GwU15-0006RM-N4@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 20:43:39

  Added:       maven2/jboss/jboss-logging-jdk/2.0.3.GA         
                        jboss-logging-jdk-2.0.3.GA-sources.jar
                        jboss-logging-jdk-2.0.3.GA-sources.jar.md5
                        jboss-logging-jdk-2.0.3.GA-sources.jar.sha1
                        jboss-logging-jdk-2.0.3.GA.jar
                        jboss-logging-jdk-2.0.3.GA.jar.md5
                        jboss-logging-jdk-2.0.3.GA.jar.sha1
                        jboss-logging-jdk-2.0.3.GA.pom
                        jboss-logging-jdk-2.0.3.GA.pom.md5
                        jboss-logging-jdk-2.0.3.GA.pom.sha1
  Log:
  Add the jboss-logging-jdk 2.0.3.GA release to the maven repo
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA-sources.jar.md5
  
  Index: jboss-logging-jdk-2.0.3.GA-sources.jar.md5
  ===================================================================
  7f349538ba30ae96c1d539a9793f579b
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA-sources.jar.sha1
  
  Index: jboss-logging-jdk-2.0.3.GA-sources.jar.sha1
  ===================================================================
  51ea216a4ca88552a905ba48c87701c156317f8d
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.jar.md5
  
  Index: jboss-logging-jdk-2.0.3.GA.jar.md5
  ===================================================================
  2595ca41c6d3670c66ea9ee3f79db71e
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.jar.sha1
  
  Index: jboss-logging-jdk-2.0.3.GA.jar.sha1
  ===================================================================
  d664083d713492f9e9193e9058b694700ac1549d
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.pom
  
  Index: jboss-logging-jdk-2.0.3.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-logging-jdk</artifactId>
    <name>JBoss Logging JDK</name>
    <version>2.0.3.GA</version>
    <description>JBoss Logging JDK classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <finalName>${artifactId}</finalName>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.0</version>
          <configuration>
            <optimize>true</optimize>
            <source>1.4</source>
            <target>1.4</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
          <inherited>true</inherited>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <snapshots />
        <id>jboss</id>
        <name>JBoss Inc. Repository</name>
        <url>http://repository.jboss.com/maven2/</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>jbosspluginrepo</id>
        <name>jboss plugin repository</name>
        <url>http://repository.jboss.com/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>central</id>
        <url>http://mirrors.ibiblio.org/pub/mirrors/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.3.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.3.GA</version>
      </dependency>
    </dependencies>
    <distributionManagement>
      <repository>
        <id>cvs-file-repository</id>
        <url>file://${maven.cvs.root}</url>
      </repository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.pom.md5
  
  Index: jboss-logging-jdk-2.0.3.GA.pom.md5
  ===================================================================
  65dcf3a00986635a3f334731550ed79b
  
  
  1.1      date: 2006/12/19 01:43:39;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.pom.sha1
  
  Index: jboss-logging-jdk-2.0.3.GA.pom.sha1
  ===================================================================
  90dcd0313723f20873aa670ea5fb73ef74193f5d
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:52:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:52:34 -0500
Subject: [jboss-cvs] JBossAS SVN: r59119 - in
	projects/vfs/trunk/src/test/java: . org
Message-ID: <E1GwU9i-0006Zf-2n@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:52:32 -0500 (Mon, 18 Dec 2006)
New Revision: 59119

Added:
   projects/vfs/trunk/src/test/java/org/
   projects/vfs/trunk/src/test/java/org/jboss/
Log:
Add the org.jboss.test package root



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:52:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:52:36 -0500
Subject: [jboss-cvs] JBossAS SVN: r59120 -
	projects/vfs/trunk/src/test/java/org/jboss
Message-ID: <E1GwU9k-0006Zy-IZ@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:52:35 -0500 (Mon, 18 Dec 2006)
New Revision: 59120

Added:
   projects/vfs/trunk/src/test/java/org/jboss/test/
Log:
Add the org.jboss.test package root



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:53:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:53:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r59121 -
	projects/vfs/trunk/src/test/java/org/jboss/test
Message-ID: <E1GwUAp-0006aH-Qt@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:53:41 -0500 (Mon, 18 Dec 2006)
New Revision: 59121

Added:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/
Log:
Copy the mc virtual test packages to the vfs project trunk

Copied: projects/vfs/trunk/src/test/java/org/jboss/test/virtual (from rev 59120, projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual)



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 20:56:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 20:56:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r59122 -
	projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test
Message-ID: <E1GwUDV-0006ef-0q@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 20:56:26 -0500 (Mon, 18 Dec 2006)
New Revision: 59122

Removed:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/TestClassLoading.java
Modified:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java
Log:
Drop the class loading tests

Deleted: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/TestClassLoading.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/TestClassLoading.java	2006-12-19 01:53:41 UTC (rev 59121)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/TestClassLoading.java	2006-12-19 01:56:26 UTC (rev 59122)
@@ -1,40 +0,0 @@
-package org.jboss.test.virtual.test;
-
-import java.net.URL;
-
-import org.jboss.test.BaseTestCase;
-import org.jboss.virtual.VFS;
-import org.jboss.virtual.classloading.VFSClassLoader;
-
-public class TestClassLoading extends BaseTestCase
-{
-   public TestClassLoading(String name)
-   {
-      super(name);
-   }
-
-   public void testJarClasses()
-      throws Exception
-   {
-      super.enableTrace("org.jboss");
-      URL url = getResource("/vfs/test/");
-      VFS vfs = VFS.getVFS(url);
-   
-      String[] searchCtxts = {"jar1.jar"};
-      ClassLoader parent = null;
-      VFSClassLoader cl = new VFSClassLoader(searchCtxts, vfs, parent);
-      URL mf = cl.findResource("META-INF/MANIFEST.MF");
-      assertTrue("META-INF/application.xml != null", mf != null);
-      log.info(mf);
-      
-      URL expected = new URL(url, "jar1.jar");
-      expected = new URL("vfs" + expected + "/META-INF/MANIFEST.MF");
-      assertEquals(expected, mf);
-
-      Class c = cl.loadClass("org.jboss.test.vfs.support.jar1.ClassInJar1");
-      assertEquals("org.jboss.test.vfs.support.jar1.ClassInJar1", c.getName());
-      URL csURL = c.getProtectionDomain().getCodeSource().getLocation();
-      log.info(csURL);
-      assertTrue("jar1.jar is in codesource", csURL.getPath().indexOf("jar1.jar") > 0);
-   }
-}

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java	2006-12-19 01:53:41 UTC (rev 59121)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java	2006-12-19 01:56:26 UTC (rev 59122)
@@ -51,7 +51,6 @@
       suite.addTest(FileVirtualFileHandlerUnitTestCase.suite());
       suite.addTest(JARVFSContextUnitTestCase.suite());
       suite.addTest(JARVirtualFileHandlerUnitTestCase.suite());
-      suite.addTest(new TestSuite(TestClassLoading.class));
       
       return suite;
    }



From remm at jboss.com  Mon Dec 18 21:14:26 2006
From: remm at jboss.com (Remy Maucherat)
Date: Mon, 18 Dec 2006 21:14:26 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/web/2.0.0.snapshot/lib ...
Message-ID: <E1GwUUs-00076X-2w@committer01.frg.pub.inap.atl.jboss.com>

  User: remm    
  Date: 06/12/18 21:14:26

  Modified:    jboss/web/2.0.0.snapshot/lib       el-api.jar
                        jbossweb-extras.jar jbossweb-src.zip jbossweb.jar
                        jsp-api.jar servlet-api.jar
  Log:
  - New snapshot.
  
  Revision  Changes    Path
  1.10      +60 -90    repository.jboss.com/jboss/web/2.0.0.snapshot/lib/el-api.jar
  
  	<<Binary file>>
  
  
  1.7       +74 -74    repository.jboss.com/jboss/web/2.0.0.snapshot/lib/jbossweb-extras.jar
  
  	<<Binary file>>
  
  
  1.2       +1641 -1605repository.jboss.com/jboss/web/2.0.0.snapshot/lib/jbossweb-src.zip
  
  	<<Binary file>>
  
  
  1.25      +3556 -3499repository.jboss.com/jboss/web/2.0.0.snapshot/lib/jbossweb.jar
  
  	<<Binary file>>
  
  
  1.8       +148 -148  repository.jboss.com/jboss/web/2.0.0.snapshot/lib/jsp-api.jar
  
  	<<Binary file>>
  
  
  1.7       +122 -122  repository.jboss.com/jboss/web/2.0.0.snapshot/lib/servlet-api.jar
  
  	<<Binary file>>
  
  


From vivekl at redhat.com  Mon Dec 18 21:51:57 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 21:51:57 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-tomcat/5.5.9.patch01  ...
Message-ID: <E1GwV5B-0007gV-Ui@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 21:51:57

  Modified:    apache-tomcat/5.5.9.patch01  component-info.xml
  Log:
  Tomcat 5.5.9 with additional patch to add support for custom options parser.
  
  Revision  Changes    Path
  1.2       +1 -1      repository.jboss.com/apache-tomcat/5.5.9.patch01/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/apache-tomcat/5.5.9.patch01/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	1 Nov 2006 15:56:32 -0000	1.1
  +++ component-info.xml	19 Dec 2006 02:51:57 -0000	1.2
  @@ -6,7 +6,7 @@
         projectHome="http://jakarta.apache.org/tomcat/index.html"
         description="Tomcat 5.5 servlet 2.4 web container with a fix for the JBAS-2866 space seperated cookie value text returned in quotes bug">
         <!-- cvsroot=":ext:cvs.devel.redhat.com:/cvs/dist/tomcat5"
  -           tag="tomcat5-5_5_9-1jpp_jb_patch01_5"
  +           tag="tomcat5-5_5_9-1jpp_jb_patch01_7"
   	-->
         <artifact id="catalina-manager.jar"/>
         <artifact id="catalina-optional.jar"/>
  
  
  


From vivekl at redhat.com  Mon Dec 18 21:51:58 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 21:51:58 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-tomcat/5.5.9.patch01/lib ...
Message-ID: <E1GwV5C-0007h1-6y@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 21:51:58

  Modified:    apache-tomcat/5.5.9.patch01/lib              
                        catalina-manager.jar catalina-optional.jar
                        catalina.jar jasper-compiler-jdt.jar
                        jasper-compiler.jar jasper-runtime.jar
                        naming-resources.jar servlets-default.jar
                        servlets-invoker.jar servlets-webdav.jar
                        tomcat-ajp.jar tomcat-coyote.jar tomcat-http.jar
                        tomcat-util.jar
  Log:
  Tomcat 5.5.9 with additional patch to add support for custom options parser.
  
  Revision  Changes    Path
  1.2       +39 -38    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/catalina-manager.jar
  
  	<<Binary file>>
  
  
  1.2       +104 -103  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/catalina-optional.jar
  
  	<<Binary file>>
  
  
  1.2       +658 -655  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/catalina.jar
  
  	<<Binary file>>
  
  
  1.2       +722 -721  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/jasper-compiler-jdt.jar
  
  	<<Binary file>>
  
  
  1.2       +396 -389  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/jasper-compiler.jar
  
  	<<Binary file>>
  
  
  1.2       +118 -117  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/jasper-runtime.jar
  
  	<<Binary file>>
  
  
  1.2       +75 -74    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/naming-resources.jar
  
  	<<Binary file>>
  
  
  1.2       +27 -26    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/servlets-default.jar
  
  	<<Binary file>>
  
  
  1.2       +21 -20    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/servlets-invoker.jar
  
  	<<Binary file>>
  
  
  1.2       +25 -24    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/servlets-webdav.jar
  
  	<<Binary file>>
  
  
  1.2       +109 -107  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/tomcat-ajp.jar
  
  	<<Binary file>>
  
  
  1.2       +52 -51    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/tomcat-coyote.jar
  
  	<<Binary file>>
  
  
  1.2       +74 -72    repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/tomcat-http.jar
  
  	<<Binary file>>
  
  
  1.2       +421 -393  repository.jboss.com/apache-tomcat/5.5.9.patch01/lib/tomcat-util.jar
  
  	<<Binary file>>
  
  


From vivekl at redhat.com  Mon Dec 18 21:51:58 2006
From: vivekl at redhat.com (Vivek Lakshmanan)
Date: Mon, 18 Dec 2006 21:51:58 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-tomcat/5.5.9.patch01/src ...
Message-ID: <E1GwV5C-0007hB-BI@committer01.frg.pub.inap.atl.jboss.com>

  User: vivekl  
  Date: 06/12/18 21:51:58

  Modified:    apache-tomcat/5.5.9.patch01/src   tomcat5-5.5.9-jboss.patch
  Added:       apache-tomcat/5.5.9.patch01/src  
                        tomcat5-5.5.9.patch01-JspServlet-5.15.17-backport.patch
  Log:
  Tomcat 5.5.9 with additional patch to add support for custom options parser.
  
  Revision  Changes    Path
  1.2       +0 -0      repository.jboss.com/apache-tomcat/5.5.9.patch01/src/tomcat5-5.5.9-jboss.patch
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: tomcat5-5.5.9-jboss.patch
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/apache-tomcat/5.5.9.patch01/src/tomcat5-5.5.9-jboss.patch,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- tomcat5-5.5.9-jboss.patch	1 Nov 2006 15:56:32 -0000	1.1
  +++ tomcat5-5.5.9-jboss.patch	19 Dec 2006 02:51:58 -0000	1.2
  @@ -187,7 +187,7 @@
   + *
   + * @author Craig R. McClanahan
   + * @author Remy Maucherat
  -+ * @version $Revision: 1.1 $ $Date: 2006/11/01 15:56:32 $
  ++ * @version $Revision: 1.2 $ $Date: 2006/12/19 02:51:58 $
   + */
   +
   +public class StandardContext
  
  
  
  1.1      date: 2006/12/19 02:51:58;  author: vivekl;  state: Exp;repository.jboss.com/apache-tomcat/5.5.9.patch01/src/tomcat5-5.5.9.patch01-JspServlet-5.15.17-backport.patch
  
  Index: tomcat5-5.5.9.patch01-JspServlet-5.15.17-backport.patch
  ===================================================================
  --- jakarta-tomcat-5.5.9-src/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/servlet/JspServlet.java.old	2005-03-26 17:22:44.000000000 -0500
  +++ jakarta-tomcat-5.5.9-src/jakarta-tomcat-jasper/jasper2/src/share/org/apache/jasper/servlet/JspServlet.java	2006-12-12 15:21:50.000000000 -0500
  @@ -17,6 +17,7 @@
   package org.apache.jasper.servlet;
   
   import java.io.IOException;
  +import java.lang.reflect.Constructor;
   import java.util.Enumeration;
   
   import javax.servlet.ServletConfig;
  @@ -72,7 +73,29 @@
   	this.context = config.getServletContext();
   
           // Initialize the JSP Runtime Context
  -        options = new EmbeddedServletOptions(config, context);
  +        // Check for a custom Options implementation
  +        String engineOptionsName = 
  +            config.getInitParameter("engineOptionsClass");
  +        if (engineOptionsName != null) {
  +            // Instantiate the indicated Options implementation
  +            try {
  +                ClassLoader loader = Thread.currentThread()
  +                        .getContextClassLoader();
  +                Class engineOptionsClass = loader.loadClass(engineOptionsName);
  +                Class[] ctorSig = { ServletConfig.class, ServletContext.class };
  +                Constructor ctor = engineOptionsClass.getConstructor(ctorSig);
  +                Object[] args = { config, context };
  +                options = (Options) ctor.newInstance(args);
  +            } catch (Throwable e) {
  +                // Need to localize this.
  +                log.warn("Failed to load engineOptionsClass", e);
  +                // Use the default Options implementation
  +                options = new EmbeddedServletOptions(config, context);
  +            }
  +        } else {
  +            // Use the default Options implementation
  +            options = new EmbeddedServletOptions(config, context);
  +        }
           rctxt = new JspRuntimeContext(context,options);
   
   	if (log.isDebugEnabled()) {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 22:00:03 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 22:00:03 -0500
Subject: [jboss-cvs] JBossAS SVN: r59123 - branches/JBoss_4_0_3_SP1_CP/build
Message-ID: <E1GwVD1-0007mz-GT@committer01.frg.pub.inap.atl.jboss.com>

Author: vivekl at redhat.com
Date: 2006-12-18 22:00:02 -0500 (Mon, 18 Dec 2006)
New Revision: 59123

Modified:
   branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml
Log:
ASPATCH-113: org.jboss.test.web.test.JSFIntegrationUnitTestCase fails
Update dependency on tomcat to 5.5.9.patch01 to test fix for the above regression



Modified: branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml
===================================================================
--- branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml	2006-12-19 01:56:26 UTC (rev 59122)
+++ branches/JBoss_4_0_3_SP1_CP/build/build-thirdparty.xml	2006-12-19 03:00:02 UTC (rev 59123)
@@ -155,7 +155,7 @@
        <componentref name="apache-slide"
          version="1.0.16" />
        <componentref name="apache-tomcat"
-         version="5.5.9jboss" />
+         version="5.5.9.patch01" />
 
        <componentref name="apache-wss4j"
          version="cvs-7-19" />



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 22:01:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 22:01:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r59124 -
	projects/vfs/trunk/src/main/java/org/jboss/virtual
Message-ID: <E1GwVE4-0007qO-W4@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 22:01:07 -0500 (Mon, 18 Dec 2006)
New Revision: 59124

Modified:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/VFS.java
Log:
Refactor the protocol handler setup into an init method.

Modified: projects/vfs/trunk/src/main/java/org/jboss/virtual/VFS.java
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/VFS.java	2006-12-19 03:00:02 UTC (rev 59123)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/VFS.java	2006-12-19 03:01:07 UTC (rev 59124)
@@ -48,6 +48,11 @@
 
    static
    {
+      init();
+   }
+
+   public static void init()
+   {
       String pkgs = System.getProperty("java.protocol.handler.pkgs");
       if (pkgs == null || pkgs.trim().length() == 0)
       {
@@ -60,7 +65,7 @@
          System.setProperty("java.protocol.handler.pkgs", pkgs);
       }
       // keep this until AOP and HEM uses VFS internally instead of the stupid ArchiveBrowser crap.
-      ArchiveBrowser.factoryFinder.put("vfsfile", new VfsArchiveBrowserFactory());
+      ArchiveBrowser.factoryFinder.put("vfsfile", new VfsArchiveBrowserFactory());      
    }
 
    /**



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 22:31:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 22:31:16 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59125 - projects/vfs/trunk/src/test
Message-ID: <E1GwVhE-0008Ti-At@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 22:31:15 -0500 (Mon, 18 Dec 2006)
New Revision: 59125

Added:
   projects/vfs/trunk/src/test/resources/
Log:
Add test resources



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 22:39:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 22:39:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r59126 -
	projects/vfs/trunk/src/test/resources
Message-ID: <E1GwVoq-00006d-Ic@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 22:39:06 -0500 (Mon, 18 Dec 2006)
New Revision: 59126

Added:
   projects/vfs/trunk/src/test/resources/vfs/
Log:
Copy the vfs test resources to the vfs project

Copied: projects/vfs/trunk/src/test/resources/vfs (from rev 59125, projects/microcontainer/trunk/container/src/resources/tests/vfs)



From jboss-cvs-commits at lists.jboss.org  Mon Dec 18 22:40:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 18 Dec 2006 22:40:55 -0500
Subject: [jboss-cvs] JBossAS SVN: r59127 - in projects/vfs/trunk: .
	src/test/java/org/jboss/test/virtual/test
Message-ID: <E1GwVqZ-00009S-GW@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-18 22:40:50 -0500 (Mon, 18 Dec 2006)
New Revision: 59127

Modified:
   projects/vfs/trunk/.classpath
   projects/vfs/trunk/pom.xml
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/JARVFSContextUnitTestCase.java
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java
Log:
Update the classpath and test resources

Modified: projects/vfs/trunk/.classpath
===================================================================
--- projects/vfs/trunk/.classpath	2006-12-19 03:39:06 UTC (rev 59126)
+++ projects/vfs/trunk/.classpath	2006-12-19 03:40:50 UTC (rev 59127)
@@ -1,7 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-  <classpathentry kind="src" path="src/main/java"/>
-  <classpathentry kind="src" path="src/test/java" output="target/test-classes"/>
-  <classpathentry kind="output" path="target/classes"/>
-  <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-  <classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
-</classpath>
\ No newline at end of file
+	<classpathentry kind="src" path="src/main/java"/>
+	<classpathentry kind="src" path="src/test/resources"/>
+	<classpathentry kind="src" output="target/test-classes" path="src/test/java"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="var" path="M2_REPO/junit/junit/3.8.1/junit-3.8.1.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar" sourcepath="/M2_REPO/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar" sourcepath="/M2_REPO/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-test/1.0.0.GA/jboss-test-1.0.0.GA.jar" sourcepath="/M2_REPO/jboss/jboss-test/1.0.0.GA/jboss-test-1.0.0.GA-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/apache-log4j/log4j/1.2.8/log4j-1.2.8.jar"/>
+	<classpathentry kind="var" path="M2_REPO/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar" sourcepath="/M2_REPO/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar"/>
+	<classpathentry kind="var" path="M2_REPO/oswego-concurrent/concurrent/1.3.4/concurrent-1.3.4.jar"/>
+	<classpathentry kind="output" path="target/classes"/>
+</classpath>

Modified: projects/vfs/trunk/pom.xml
===================================================================
--- projects/vfs/trunk/pom.xml	2006-12-19 03:39:06 UTC (rev 59126)
+++ projects/vfs/trunk/pom.xml	2006-12-19 03:40:50 UTC (rev 59127)
@@ -4,15 +4,130 @@
   <groupId>jboss</groupId>
   <artifactId>jboss-vfs</artifactId>
   <packaging>jar</packaging>
-  <version>1.0-SNAPSHOT</version>
-  <name>jboss-vfs</name>
-  <url>http://maven.apache.org</url>
+  <version>2.0.4.snapshot</version>
+  <name>JBoss VFS</name>
+  <url>http://www.jboss.org</url>
+  <description>A set of commonly used classed classes</description>
+  <licenses>
+    <license>
+      <name>lgpl</name>
+      <url>http://repository.jboss.com/licenses/lgpl.txt</url>
+    </license>
+  </licenses>
+  <organization>
+    <name>JBoss, A division of Red Hat</name>
+    <url>http://www.jboss.org</url>
+  </organization>
+
+  <repositories>
+    <repository>
+      <id>jboss</id>
+      <name>JBoss Inc. Repository</name>
+      <layout>default</layout>
+      <url>http://repository.jboss.com/maven2/</url>
+      <snapshots>
+        <enabled>true</enabled>
+      </snapshots>
+    </repository>
+  </repositories>
+  
+  <pluginRepositories>
+    <pluginRepository>
+      <id>jbosspluginrepo</id>
+      <name>jboss plugin repository</name>
+      <url>http://repository.jboss.com/maven2</url>
+      <layout>default</layout>
+      <snapshots>
+        <enabled>false</enabled>
+        <updatePolicy>never</updatePolicy>
+      </snapshots>
+    </pluginRepository>
+  </pluginRepositories>
+
+  <build>
+    <sourceDirectory>src/main/java</sourceDirectory>
+    <finalName>${artifactId}</finalName>
+    <plugins>
+      
+      <!-- define how we want compilation to take place
+        here, we accept most of the defaults but say that we want the
+        optimization flag set, and define the source and target to be 1.5,
+        these setting will be inherited by child projects -->
+      <plugin>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <version>2.0</version>
+        <configuration>
+          <debug>true</debug>
+          <source>1.5</source>
+          <target>1.5</target>
+        </configuration>
+      </plugin>
+      <!-- define that we wish to create src jars -->
+      <plugin>
+        <artifactId>maven-source-plugin</artifactId>
+        <inherited>true</inherited>
+        <executions>
+          <execution>
+            <goals>
+              <goal>jar</goal>
+            </goals>
+          </execution>
+        </executions>
+      </plugin>
+      <plugin>
+        <artifactId>maven-surefire-plugin</artifactId>
+        <configuration>
+          <printSummary>true</printSummary>
+          <disableXmlReport>false</disableXmlReport>
+          <testFailureIgnore>true</testFailureIgnore>
+          <forkMode>once</forkMode> <!-- required to correctly run the PojoServer tests -->
+          <systemProperties>
+            <property>
+              <name>java.protocol.handler.pkgs</name>
+              <value>org.jboss.virtual.protocol</value>
+            </property>
+          </systemProperties>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-report-plugin</artifactId>
+      </plugin>
+      
+    </plugins>
+  </build>
+
   <dependencies>
     <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-common-core</artifactId>
+      <version>2.0.3.GA</version>
+    </dependency>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-logging-log4j</artifactId>
+      <version>2.0.3.GA</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>jboss</groupId>
+      <artifactId>jboss-test</artifactId>
+      <version>1.0.0.GA</version>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
       <groupId>junit</groupId>
       <artifactId>junit</artifactId>
       <version>3.8.1</version>
       <scope>test</scope>
     </dependency>
   </dependencies>
+
+  <distributionManagement>
+    <repository>
+      <id>cvs-file-repository</id>
+      <!-- Set maven.cvs.root in your settings.xml -->
+      <url>file://${maven.cvs.root}</url>
+    </repository>
+  </distributionManagement>
 </project>

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/JARVFSContextUnitTestCase.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/JARVFSContextUnitTestCase.java	2006-12-19 03:39:06 UTC (rev 59126)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/JARVFSContextUnitTestCase.java	2006-12-19 03:40:50 UTC (rev 59127)
@@ -26,6 +26,7 @@
 import junit.framework.Test;
 import junit.framework.TestSuite;
 
+import org.jboss.virtual.VFS;
 import org.jboss.virtual.plugins.context.jar.JarContext;
 import org.jboss.virtual.plugins.context.jar.JarUtils;
 import org.jboss.virtual.spi.VFSContext;
@@ -45,6 +46,8 @@
 
    public static Test suite()
    {
+      VFS.init();
+      System.out.println("java.protocol.handler.pkgs: "+System.getProperty("java.protocol.handler.pkgs"));
       return new TestSuite(JARVFSContextUnitTestCase.class);
    }
 

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java	2006-12-19 03:39:06 UTC (rev 59126)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/VFSAllTestSuite.java	2006-12-19 03:40:50 UTC (rev 59127)
@@ -21,6 +21,8 @@
 */
 package org.jboss.test.virtual.test;
 
+import org.jboss.virtual.VFS;
+
 import junit.framework.Test;
 import junit.framework.TestSuite;
 import junit.textui.TestRunner;
@@ -40,6 +42,7 @@
 
    public static Test suite()
    {
+      VFS.init();
       TestSuite suite = new TestSuite("VFS Tests");
 
       suite.addTest(new TestSuite(URLResolutionUnitTestCase.class));



From scott.stark at jboss.com  Mon Dec 18 22:45:58 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 22:45:58 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-vfs - New
	directory ...
Message-ID: <E1GwVvS-0000E0-Dc@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 22:45:58

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-vfs added to the repository


From scott.stark at jboss.com  Mon Dec 18 22:46:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 22:46:14 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-vfs/2.0.4.snapshot -
	New directory ...
Message-ID: <E1GwVvi-0000Eb-Cc@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 22:46:14

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-vfs/2.0.4.snapshot added to the repository


From scott.stark at jboss.com  Mon Dec 18 22:46:55 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Mon, 18 Dec 2006 22:46:55 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-vfs/2.0.4.snapshot ...
Message-ID: <E1GwVwN-0000GU-1r@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/18 22:46:55

  Added:       maven2/jboss/jboss-vfs/2.0.4.snapshot   
                        jboss-vfs-2.0.4.snapshot-sources.jar
                        jboss-vfs-2.0.4.snapshot.jar
                        jboss-vfs-2.0.4.snapshot.pom
  Log:
  Add a jboss-vfs snapshot release
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 03:46:55;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 03:46:55;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 03:46:55;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot.pom
  
  Index: jboss-vfs-2.0.4.snapshot.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-vfs</artifactId>
    <name>JBoss VFS</name>
    <version>2.0.4.snapshot</version>
    <description>A set of commonly used classed classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss, A division of Red Hat</name>
      <url>http://www.jboss.org</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <finalName>${artifactId}</finalName>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.0</version>
          <configuration>
            <debug>true</debug>
            <source>1.5</source>
            <target>1.5</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
          <inherited>true</inherited>
        </plugin>
        <plugin>
          <artifactId>maven-surefire-plugin</artifactId>
          <configuration>
            <printSummary>true</printSummary>
            <disableXmlReport>false</disableXmlReport>
            <testFailureIgnore>true</testFailureIgnore>
            <forkMode>once</forkMode>
            <systemProperties>
              <property>
                <name>java.protocol.handler.pkgs</name>
                <value>org.jboss.virtual.protocol</value>
              </property>
            </systemProperties>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-surefire-report-plugin</artifactId>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <snapshots />
        <id>jboss</id>
        <name>JBoss Inc. Repository</name>
        <url>http://repository.jboss.com/maven2/</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>jbosspluginrepo</id>
        <name>jboss plugin repository</name>
        <url>http://repository.jboss.com/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.0.3.GA</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-log4j</artifactId>
        <version>2.0.3.GA</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-test</artifactId>
        <version>1.0.0.GA</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <repository>
        <id>cvs-file-repository</id>
        <url>file://${maven.cvs.root}</url>
      </repository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 00:15:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 00:15:28 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1816 - in trunk:
 src/main/org/jboss/jms/client/delegate src/main/org/jboss/jms/message
 src/main/org/jboss/jms/server src/main/org/jboss/jms/server/destination
 src/main/org/jboss/jms/server/endpoint
 src/main/org/jboss/jms/server/endpoint/advised
 src/main/org/jboss/jms/server/remoting src/main/org/jboss/jms/util
 src/main/org/jboss/messaging/core src/main/org/jboss/messaging/core/plugin
 src/main/org/jboss/messaging/core/plugin/postoffice
 src/main/org/jboss/messaging/core/plugin/postoffice/cluster
 src/main/org/jboss/messaging/core/tx tests/bin
 tests/src/org/jboss/test/messaging/core
 tests/src/org/jboss/test/messaging/core/local/base
 tests/src/org/jboss/test/messaging/core/paging
 tests/src/org/jboss/test/messaging/core/paging/base
 tests/src/org/jboss/test/messaging/core/plugin
 tests/src/org/jboss/test/messaging/core/plugin/base
 tests/src/org/jboss/test/messaging/core/plugin/postoffice
 tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluste!
 r tests/src/org/jboss/test/messaging/jms
 tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GwXK4-00020T-Ht@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-19 00:15:12 -0500 (Tue, 19 Dec 2006)
New Revision: 1816

Modified:
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java
   trunk/src/main/org/jboss/jms/server/destination/QueueService.java
   trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/src/main/org/jboss/jms/util/MessageQueueNameHelper.java
   trunk/src/main/org/jboss/messaging/core/Channel.java
   trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java
   trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java
   trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBindings.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java
   trunk/src/main/org/jboss/messaging/core/tx/Transaction.java
   trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   trunk/tests/bin/runtest
   trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
   trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/IdManagerTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java
Log:
various refactorings and logging improvments

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -41,7 +41,7 @@
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.server.remoting.MetaDataConstants;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 import org.jboss.remoting.Client;
 import org.jboss.remoting.InvokerLocator;
 
@@ -144,7 +144,7 @@
     * server-side endpoint.
     * @see org.jboss.jms.server.endpoint.ServerConnectionFactoryEndpoint#getIdBlock(int)  
     */
-   public IdBlock getIdBlock(int size)
+   public IDBlock getIdBlock(int size)
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }

Modified: trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java
===================================================================
--- trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/message/MessageIdGenerator.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -25,7 +25,7 @@
 
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 
 /**
  * 
@@ -74,7 +74,7 @@
 
    protected void getNextBlock() throws JMSException
    {
-      IdBlock block = cfd.getIdBlock(blockSize);
+      IDBlock block = cfd.getIdBlock(blockSize);
 
       nextID = block.getLow();
       high = block.getHigh();

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -47,7 +47,7 @@
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.memory.MemoryManager;
 import org.jboss.messaging.core.memory.SimpleMemoryManager;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -126,9 +126,9 @@
    private TransactionRepository txRepository;
    private ConnectionManager connectionManager;
    private ConnectorManager connectorManager;
-   private IdManager messageIdManager;
-   private IdManager channelIdManager;
-   private IdManager transactionIdManager;
+   private IDManager messageIDManager;
+   private IDManager channelIDManager;
+   private IDManager transactionIDManager;
    private MemoryManager memoryManager;
    private QueuedExecutorPool queuedExecutorPool;
    private MessageStore messageStore;
@@ -211,22 +211,22 @@
          //MBean dependencies
 
          // Create the wired components
-         messageIdManager = new IdManager("MESSAGE_ID", 4096, persistenceManager);
-         channelIdManager = new IdManager("CHANNEL_ID", 10, persistenceManager);
-         transactionIdManager = new IdManager("TRANSACTION_ID", 1024, persistenceManager);
+         messageIDManager = new IDManager("MESSAGE_ID", 4096, persistenceManager);
+         channelIDManager = new IDManager("CHANNEL_ID", 10, persistenceManager);
+         transactionIDManager = new IDManager("TRANSACTION_ID", 1024, persistenceManager);
          destinationJNDIMapper = new DestinationJNDIMapper(this);
          connFactoryJNDIMapper = new ConnectionFactoryJNDIMapper(this);
          connectionManager = new SimpleConnectionManager();
          connectorManager = new SimpleConnectorManager();
          memoryManager = new SimpleMemoryManager();
          messageStore = new SimpleMessageStore();
-         txRepository = new TransactionRepository(persistenceManager, transactionIdManager);
+         txRepository = new TransactionRepository(persistenceManager, transactionIDManager);
 
          // Start the wired components
 
-         messageIdManager.start();
-         channelIdManager.start();
-         transactionIdManager.start();
+         messageIDManager.start();
+         channelIDManager.start();
+         transactionIDManager.start();
          destinationJNDIMapper.start();
          connFactoryJNDIMapper.start();
          connectionManager.start();
@@ -268,12 +268,12 @@
 
          // Stop the wired components
 
-         messageIdManager.stop();
-         messageIdManager = null;
-         channelIdManager.stop();
-         channelIdManager = null;
-         transactionIdManager.stop();
-         transactionIdManager = null;
+         messageIDManager.stop();
+         messageIDManager = null;
+         channelIDManager.stop();
+         channelIDManager = null;
+         transactionIDManager.stop();
+         transactionIDManager = null;
          destinationJNDIMapper.stop();
          destinationJNDIMapper = null;
          connFactoryJNDIMapper.stop();
@@ -439,14 +439,14 @@
       return securityStore.getDefaultSecurityConfig();
    }
 
-   public IdManager getMessageIdManager()
+   public IDManager getMessageIDManager()
    {
-      return messageIdManager;
+      return messageIDManager;
    }
 
-   public IdManager getChannelIdManager()
+   public IDManager getChannelIDManager()
    {
-      return channelIdManager;
+      return channelIDManager;
    }
 
    public ServerInvocationHandler getInvocationHandler()

Modified: trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -13,7 +13,7 @@
 import org.jboss.jms.server.SecurityManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.ExceptionUtil;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
@@ -63,7 +63,7 @@
    
    protected TransactionRepository tr;
    
-   protected IdManager idm;
+   protected IDManager idm;
    
    protected int nodeId;
    
@@ -102,7 +102,7 @@
          
          tr = serverPeer.getTxRepository();
          
-         idm = serverPeer.getChannelIdManager();
+         idm = serverPeer.getChannelIDManager();
          
          nodeId = serverPeer.getServerPeerID();
          

Modified: trunk/src/main/org/jboss/jms/server/destination/QueueService.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/QueueService.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/destination/QueueService.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -111,7 +111,7 @@
             
             if (postOffice.isLocal())
             {
-               queue = new PagingFilteredQueue(destination.getName(), idm.getId(), ms, pm, true, true,                        
+               queue = new PagingFilteredQueue(destination.getName(), idm.getID(), ms, pm, true, true,
                                                executor, null,
                                                destination.getFullSize(), destination.getPageSize(), destination.getDownCacheSize());
                
@@ -121,7 +121,7 @@
             }
             else
             {               
-               queue = new LocalClusteredQueue(postOffice, nodeId, destination.getName(), idm.getId(), ms, pm, true, true,                        
+               queue = new LocalClusteredQueue(postOffice, nodeId, destination.getName(), idm.getID(), ms, pm, true, true,
                                                executor, null, tr, 
                                                destination.getFullSize(), destination.getPageSize(), destination.getDownCacheSize());
                

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -23,7 +23,7 @@
 
 import javax.jms.JMSException;
 
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 
 /**
  * Represents the set of methods from the ConnectionFactoryDelegate that are handled on the server.
@@ -44,6 +44,6 @@
    
    byte[] getClientAOPConfig() throws JMSException;
 
-   IdBlock getIdBlock(int size) throws JMSException;
+   IDBlock getIdBlock(int size) throws JMSException;
 }
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -30,7 +30,7 @@
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.util.ExceptionUtil;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 
 /**
  * Concrete implementation of ConnectionFactoryEndpoint
@@ -184,11 +184,11 @@
       }
    }
 
-   public IdBlock getIdBlock(int size) throws JMSException
+   public IDBlock getIdBlock(int size) throws JMSException
    {
       try
       {
-         return serverPeer.getMessageIdManager().getIdBlock(size);
+         return serverPeer.getMessageIDManager().getIDBlock(size);
       }
       catch (Throwable t)
       {

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -64,7 +64,7 @@
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.contract.ClusteredPostOffice;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -128,7 +128,7 @@
    private MessageStore ms;
 
    private DestinationManager dm;
-   private IdManager idm;
+   private IDManager idm;
    private QueuedExecutorPool pool;
    private TransactionRepository tr;
    private PostOffice postOffice;
@@ -157,7 +157,7 @@
       ms = sp.getMessageStore();
       dm = sp.getDestinationManager();
       postOffice = sp.getPostOfficeInstance();     
-      idm = sp.getChannelIdManager();
+      idm = sp.getChannelIDManager();
       pool = sp.getQueuedExecutorPool();
       nodeId = sp.getServerPeerID();
       tr = sp.getTxRepository();
@@ -248,7 +248,7 @@
    	   
    	   ClientBrowserDelegate stub = new ClientBrowserDelegate(browserID);
    	   
-         log.debug("created and registered " + ep);
+         log.debug(this + " created and registered " + ep);
    
    	   return stub;
       }
@@ -403,7 +403,7 @@
          {
             Cancel cancel = (Cancel)cancels.get(i);       
             
-            if (trace) { log.trace("Cancelling delivery " + cancel.getDeliveryId()); }
+            if (trace) { log.trace(this + " cancelling delivery " + cancel.getDeliveryId()); }
             
             Delivery del = cancelDeliveryInternal(cancel);
             
@@ -422,7 +422,7 @@
    
    public void recoverDeliveries(List deliveryRecoveryInfos) throws JMSException
    {
-      if (trace) { log.trace(this + "recoverDeliveries(): " + deliveryRecoveryInfos); }
+      if (trace) { log.trace(this + "recovering deliveries " + deliveryRecoveryInfos); }
       try
       {
          if (postOffice.isLocal())
@@ -552,7 +552,7 @@
             QueuedExecutor executor = (QueuedExecutor)pool.get();
             
             PagingFilteredQueue q = 
-               new PagingFilteredQueue(dest.getName(), idm.getId(), ms, pm, true, false,
+               new PagingFilteredQueue(dest.getName(), idm.getID(), ms, pm, true, false,
                                        executor, null, fullSize, pageSize, downCacheSize);                        
             
             //Make a binding for this queue
@@ -778,13 +778,13 @@
             
       Set channels = new HashSet();
       
-      if (trace) { log.trace("Cancelling " + entries.size() + " deliveries"); }
+      if (trace) { log.trace(this + " cancelling " + entries.size() + " deliveries"); }
       
       while (iter.hasNext())
       {
          Map.Entry entry = (Map.Entry)iter.next();
          
-         if (trace) { log.trace("Cancelling delivery with delivery id: " + entry.getKey()); }
+         if (trace) { log.trace(this + " cancelling delivery with delivery id: " + entry.getKey()); }
          
          Delivery del = (Delivery)entry.getValue();
          
@@ -829,7 +829,7 @@
    
    void acknowledgeTransactionally(List acks, Transaction tx) throws Throwable
    {
-      if (trace) { log.trace("Acknowledging transactionally " + acks.size() + " for tx: " + tx); }
+      if (trace) { log.trace(this + " acknowledging transactionally " + acks.size() + " for tx: " + tx); }
       
       DeliveryCallback deliveryCallback = (DeliveryCallback)tx.getCallback(this);
       
@@ -888,7 +888,7 @@
    
    private void acknowledgeDeliveryInternal(Ack ack) throws Throwable
    {
-      if (trace) { log.trace("Acknowledging delivery " + ack.getDeliveryId()); }
+      if (trace) { log.trace(this + " acknowledging delivery " + ack.getDeliveryId()); }
       
       Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
       
@@ -953,51 +953,51 @@
       
       return del;
    }
-      
+
    private ConsumerDelegate failoverConsumer(JBossDestination jmsDestination,
-            String selectorString,
-            boolean noLocal,  String subscriptionName,
-            boolean connectionConsumer,
-            long oldChannelID) throws Exception
+                                             String selectorString,
+                                             boolean noLocal,  String subscriptionName,
+                                             boolean connectionConsumer,
+                                             long oldChannelID) throws Exception
    {
-      //fail over channel
+      // fail over channel
       if (postOffice.isLocal())
       {
          throw new IllegalStateException("Cannot failover on a non clustered post office!");
       }
+
+      log.debug(this + " failing over consumer");
       
-      //this is a Clustered operation... so postOffice here must be Clustered
+      // this is a Clustered operation... so postOffice here must be Clustered
       Binding binding = ((ClusteredPostOffice)postOffice).getBindingforChannelId(oldChannelID);
       if (binding == null)
       {
          throw new IllegalStateException("Can't find failed over channel " + oldChannelID);
       }
-      
-      // TODO - Remove this log.info before merging into trunk
-      if (binding.getQueue() instanceof RemoteQueueStub)
+
+      if (trace)
       {
-         log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((RemoteQueueStub)binding.getQueue()).getChannelID());
+         long newChannelID =
+            binding.getQueue() instanceof RemoteQueueStub ?
+               ((RemoteQueueStub)binding.getQueue()).getChannelID() :
+               ((PagingFilteredQueue)binding.getQueue()).getChannelID();
+
+         log.trace(this + "failing over from channel " + oldChannelID + " to channel " + newChannelID);
       }
-      else
-      {
-         log.info("OldChannelId=" + oldChannelID + " while currentChannelId=" + ((PagingFilteredQueue)binding.getQueue()).getChannelID());
-      }
-      
+
       int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
-      
       int prefetchSize = connectionEndpoint.getPrefetchSize();
       
       ServerConsumerEndpoint ep =
-         
          new ServerConsumerEndpoint(consumerID, binding.getQueue(),
-                  binding.getQueue().getName(), this, selectorString, noLocal,
-                  jmsDestination, prefetchSize);
+                                    binding.getQueue().getName(), this, selectorString, noLocal,
+                                    jmsDestination, prefetchSize);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
-      
+
       ClientConsumerDelegate stub =
          new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
-                  prefetchSize, maxDeliveryAttempts);
+                                    prefetchSize, maxDeliveryAttempts);
             
       synchronized (consumers)
       {      
@@ -1023,10 +1023,14 @@
          selectorString = null;
       }
       
-      log.debug("creating consumer for " + jmsDestination + ", selector " + selectorString + ", " + (noLocal ? "noLocal, " : "") + "subscription " + subscriptionName);
+      log.debug(this + " creating consumer for " + jmsDestination +
+         (selectorString == null ? "" : ", selector '" + selectorString + "'") +
+         (subscriptionName == null ? "" : ", subscription '" + subscriptionName + "'") +
+         (noLocal ? ", noLocal" : ""));
+
+      ManagedDestination mDest = dm.
+         getDestination(jmsDestination.getName(), jmsDestination.isQueue());
       
-      ManagedDestination mDest = dm.getDestination(jmsDestination.getName(), jmsDestination.isQueue());
-      
       if (mDest == null)
       {
          throw new InvalidDestinationException("No such destination: " + jmsDestination);
@@ -1048,7 +1052,7 @@
       
       Binding binding = null;
       
-      //Always validate the selector first
+      // Always validate the selector first
       Selector selector = null;
       if (selectorString != null)
       {
@@ -1062,7 +1066,7 @@
          if (subscriptionName == null)
          {
             // non-durable subscription
-            if (log.isTraceEnabled()) { log.trace("creating new non-durable subscription on " + jmsDestination); }
+            if (log.isTraceEnabled()) { log.trace(this + " creating new non-durable subscription on " + jmsDestination); }
             
             // Create the non durable sub
             QueuedExecutor executor = (QueuedExecutor)pool.get();
@@ -1071,7 +1075,7 @@
             
             if (postOffice.isLocal())
             {
-               q = new PagingFilteredQueue(new GUID().toString(), idm.getId(), ms, pm, true, false,
+               q = new PagingFilteredQueue(new GUID().toString(), idm.getID(), ms, pm, true, false,
                         executor, selector,
                         mDest.getFullSize(),
                         mDest.getPageSize(),
@@ -1081,7 +1085,7 @@
             }
             else
             {
-               q = new LocalClusteredQueue(postOffice, nodeId, new GUID().toString(), idm.getId(), ms, pm, true, false,
+               q = new LocalClusteredQueue(postOffice, nodeId, new GUID().toString(), idm.getID(), ms, pm, true, false,
                         executor, selector, tr,
                         mDest.getFullSize(),
                         mDest.getPageSize(),
@@ -1106,7 +1110,7 @@
                throw new InvalidDestinationException("Cannot create a durable subscription on a temporary topic");
             }
             
-            // we have a durable subscription, look it up
+            // We have a durable subscription, look it up
             String clientID = connectionEndpoint.getClientID();
             if (clientID == null)
             {
@@ -1123,28 +1127,29 @@
             {
                // Does not already exist
                
-               if (trace) { log.trace("creating new durable subscription on " + jmsDestination); }
+               if (trace) { log.trace(this + " creating new durable subscription on " + jmsDestination); }
                
                QueuedExecutor executor = (QueuedExecutor)pool.get();
                PagingFilteredQueue q;
-               
+
                if (postOffice.isLocal())
                {
-                  q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
-                           executor, selector,
-                           mDest.getFullSize(),
-                           mDest.getPageSize(),
-                           mDest.getDownCacheSize());
-                  
+                  q = new PagingFilteredQueue(name, idm.getID(), ms, pm, true, true,
+                                              executor, selector,
+                                              mDest.getFullSize(),
+                                              mDest.getPageSize(),
+                                              mDest.getDownCacheSize());
+
                   binding = postOffice.bindQueue(topicCond, q);
                }
                else
                {
-                  q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
-                           executor, selector, tr,
-                           mDest.getFullSize(),
-                           mDest.getPageSize(),
-                           mDest.getDownCacheSize());
+                  q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getID(),
+                                              ms, pm, true, true,
+                                              executor, selector, tr,
+                                              mDest.getFullSize(),
+                                              mDest.getPageSize(),
+                                              mDest.getDownCacheSize());
                   
                   ClusteredPostOffice cpo = (ClusteredPostOffice)postOffice;
                   
@@ -1162,7 +1167,7 @@
             {
                //Durable sub already exists
                
-               if (trace) { log.trace("subscription " + subscriptionName + " already exists"); }
+               if (trace) { log.trace(this + " subscription " + subscriptionName + " already exists"); }
                
                // From javax.jms.Session Javadoc (and also JMS 1.1 6.11.1):
                // A client can change an existing durable subscription by creating a durable
@@ -1210,7 +1215,7 @@
                   
                   if (postOffice.isLocal())
                   {
-                     q = new PagingFilteredQueue(name, idm.getId(), ms, pm, true, true,
+                     q = new PagingFilteredQueue(name, idm.getID(), ms, pm, true, true,
                               executor, selector,
                               mDest.getFullSize(),
                               mDest.getPageSize(),
@@ -1219,7 +1224,7 @@
                   }
                   else
                   {
-                     q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getId(), ms, pm, true, true,
+                     q = new LocalClusteredQueue(postOffice, nodeId, name, idm.getID(), ms, pm, true, true,
                               executor, selector, tr,
                               mDest.getFullSize(),
                               mDest.getPageSize(),
@@ -1271,7 +1276,7 @@
          consumers.put(new Integer(consumerID), ep);
       }
          
-      log.debug("created and registered " + ep);
+      log.debug(this + " created and registered " + ep);
       
       return stub;
    }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -24,7 +24,7 @@
 import javax.jms.JMSException;
 import org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 
 /**
  *
@@ -70,7 +70,7 @@
       return endpoint.getClientAOPConfig();
    }
 
-   public IdBlock getIdBlock(int size) throws JMSException
+   public IDBlock getIdBlock(int size) throws JMSException
    {
       return endpoint.getIdBlock(size);
    }

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -51,7 +51,7 @@
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.message.MessageFactory;
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 import org.jboss.remoting.InvocationRequest;
 import org.jboss.remoting.InvocationResponse;
 import org.jboss.remoting.callback.Callback;
@@ -442,12 +442,12 @@
    
                if (trace) { log.trace("wrote null response"); }
             }         
-            else if (res instanceof IdBlock)
+            else if (res instanceof IDBlock)
             {
                //Return value from getMessageNow
                dos.write(ID_BLOCK_RESPONSE);
    
-               IdBlock block = (IdBlock)res;
+               IDBlock block = (IDBlock)res;
    
                block.write(dos);
    
@@ -822,7 +822,7 @@
             }
             case ID_BLOCK_RESPONSE:
             {
-               IdBlock block = new IdBlock();
+               IDBlock block = new IDBlock();
    
                block.read(dis);
    

Modified: trunk/src/main/org/jboss/jms/util/MessageQueueNameHelper.java
===================================================================
--- trunk/src/main/org/jboss/jms/util/MessageQueueNameHelper.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/jms/util/MessageQueueNameHelper.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -94,17 +94,17 @@
       return new MessageQueueNameHelper(messageQueueName);
    }
    
-   public static String createSubscriptionName(String clientId, String subName)
+   public static String createSubscriptionName(String clientID, String subName)
    {
-      if (clientId == null)
+      if (clientID == null)
       {
-         throw new IllegalArgumentException("clientId name is null");
+         throw new IllegalArgumentException("clientID name is null");
       }
       if (subName == null)
       {
          throw new IllegalArgumentException("Subscription name is null");
       }
       
-      return clientId + SEPARATOR + subName;
+      return clientID + SEPARATOR + subName;
    }      
 }

Modified: trunk/src/main/org/jboss/messaging/core/Channel.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -71,8 +71,6 @@
     * A recoverable channel must always accept reliable messages, so this method must always return
     * true for a recoverable channel.
     *
-    * @see State#acceptReliableMessages()
-    *
     * @return false if the channel doesn't accept reliable messages.
     */
    public boolean acceptReliableMessages();

Modified: trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -28,27 +28,25 @@
 
 /**
  * 
- * A IdBlock.
+ * A IDBlock.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
  * @version 1.1
  *
- * IdBlock.java,v 1.1 2006/03/07 17:11:15 timfox Exp
+ * IDBlock.java,v 1.1 2006/03/07 17:11:15 timfox Exp
  */
-public class IdBlock implements Streamable
+public class IDBlock implements Streamable
 {
-   protected long low;
+   private long low;
+   private long high;
    
-   protected long high;
-   
-   public IdBlock()
+   public IDBlock()
    {      
    }
    
-   public IdBlock(long low, long high)
+   public IDBlock(long low, long high)
    {
       this.low = low;
-      
       this.high = high;
    }
    
@@ -65,20 +63,18 @@
    public void read(DataInputStream in) throws Exception
    {
       low = in.readLong();
-      
       high = in.readLong();
    }
 
    public void write(DataOutputStream out) throws Exception
    {
       out.writeLong(low);
-      
       out.writeLong(high);
    }
 
    public String toString()
    {
-      return "IdBlock[" + low + "-" + high + "]";
+      return "IDBlock[" + low + "-" + high + "]";
    }
 
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -27,92 +27,112 @@
 
 /**
  * 
- * A IdManager.
+ * A IDManager.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version 1.1
  *
- * IdManager.java,v 1.1 2006/03/07 17:11:15 timfox Exp
+ * IDManager.java,v 1.1 2006/03/07 17:11:15 timfox Exp
  */
-public class IdManager implements MessagingComponent
+public class IDManager implements MessagingComponent
 {
-   private static final Logger log = Logger.getLogger(IdManager.class);   
-   
+   // Constants -----------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(IDManager.class);
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private boolean trace = log.isTraceEnabled();
-   
-   protected int bigBlockSize;
-   
-   protected long high;
-   
-   protected long nextBlock;
-         
-   protected PersistenceManager pm;
-   
-   protected String counterName;
-   
+
    private boolean started;
-   
-   public IdManager(String counterName, int bigBlockSize, PersistenceManager pm) throws Exception
+
+   private String counterName;
+
+   private int bigBlockSize;
+   private long high;
+   private long low;
+
+   private PersistenceManager pm;
+
+   // Constructors --------------------------------------------------
+
+   public IDManager(String counterName, int bigBlockSize, PersistenceManager pm) throws Exception
    {
+      this.counterName = counterName;
       this.bigBlockSize = bigBlockSize;
-      
       this.pm = pm;
-      
-      this.counterName = counterName;           
    }
-   
+
+   // MessagingComponent implementation -----------------------------
+
    public synchronized void start() throws Exception
    {
       getNextBigBlock();
-      
       started = true;
    }
-   
+
    public synchronized void stop() throws Exception
    {
       started = false;
    }
-   
-   public synchronized IdBlock getIdBlock(int size) throws Exception
+
+   // Public --------------------------------------------------------
+
+   protected void getNextBigBlock() throws Exception
    {
+      low = pm.reserveIDBlock(counterName, bigBlockSize);
+      high = low + bigBlockSize - 1;
+      if (trace) { log.trace(this + " retrieved next block of size " + bigBlockSize + " from PersistenceManager, starting at " + low); }
+   }
+
+   public synchronized IDBlock getIDBlock(int size) throws Exception
+   {
       if (!started)
       {
          throw new IllegalStateException(this + " is not started");
       }
-      
+
       if (size <= 0)
       {
          throw new IllegalArgumentException("block size must be > 0");
       }
-      
+
       if (size > bigBlockSize)
       {
          throw new IllegalArgumentException("block size must be <= bigBlockSize");
       }
-      
-      if (size > high - nextBlock + 1)
+
+      if (size > high - low + 1)
       {
          getNextBigBlock();
       }
-      
-      long low = nextBlock;
-      
-      nextBlock += size;
-      
-      return new IdBlock(low, nextBlock - 1);
+
+      long low = this.low;
+
+      this.low += size;
+
+      return new IDBlock(low, this.low - 1);
    }
-   
-   public synchronized long getId() throws Exception
+
+   public synchronized long getID() throws Exception
    {
-      return getIdBlock(1).low;
+      return getIDBlock(1).getLow();
    }
-   
-   protected void getNextBigBlock() throws Exception
+
+   public String toString()
    {
-      nextBlock = pm.reserveIDBlock(counterName, bigBlockSize);
-      
-      if (trace) { log.trace("Retrieved next block of size " + bigBlockSize + " from pm starting at " + nextBlock); }
-      
-      high = nextBlock + bigBlockSize - 1;
+      return "IDManager[" + counterName + ", " + low + "-" + high + "]";
    }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -162,9 +162,9 @@
    
    public long reserveIDBlock(String counterName, int size) throws Exception
    {
-      //TODO This will need locking (e.g. SELECT ... FOR UPDATE...) in the clustered case
+      // TODO This will need locking (e.g. SELECT ... FOR UPDATE...) in the clustered case
        
-      if (trace) { log.trace("Getting id block for counter: " + counterName + " ,size: " + size); }
+      if (trace) { log.trace("Getting ID block for counter " + counterName + ", size " + size); }
       
       if (size <= 0)
       {
@@ -179,14 +179,13 @@
       try
       {
          conn = ds.getConnection();
-         
+
          String selectCounterSQL = getSQLStatement("SELECT_COUNTER");
          
          ps = conn.prepareStatement(selectCounterSQL);
          
          ps.setString(1, counterName);
          
-         if (trace) { log.trace("selecting counter: " + selectCounterSQL); }
          rs = ps.executeQuery();
          if (trace) { log.trace(JDBCUtil.statementToString(selectCounterSQL, counterName)); }         
          
@@ -202,17 +201,13 @@
             ps = conn.prepareStatement(insertCounterSQL);
             
             ps.setString(1, counterName);
-            
             ps.setLong(2, size);
             
-            if (trace) { log.trace("inserting counter: " + insertCounterSQL); }
-            int rows = ps.executeUpdate();            
-            if (trace) {  log.trace(JDBCUtil.statementToString(insertCounterSQL, counterName)
-                           + " inserted " + rows + " rows"); }  
+            int rows = ps.executeUpdate();
+            if (trace) { log.trace(JDBCUtil.statementToString(insertCounterSQL, counterName, new Integer(size)) + " inserted " + rows + " rows"); }
             
             ps.close();            
             ps = null;
-            
             return 0;
          }
          
@@ -228,13 +223,10 @@
          ps = conn.prepareStatement(updateCounterSQL);
          
          ps.setLong(1, nextId + size);
-         
          ps.setString(2, counterName);
          
-         if (trace) { log.trace("updating counter: " + updateCounterSQL); }
-         int rows = ps.executeUpdate();         
-         if (trace) { log.trace(JDBCUtil.statementToString(updateCounterSQL, new Long(nextId + size),
-                               counterName) + " updated " + rows + " rows"); }        
+         int rows = ps.executeUpdate();
+         if (trace) { log.trace(JDBCUtil.statementToString(updateCounterSQL, new Long(nextId + size), counterName) + " updated " + rows + " rows"); }
          
          return nextId;
       }
@@ -357,9 +349,7 @@
                   HashMap coreHeaders = bytesToMap(bytes);
                   byte[] payload = getBytes(rs, 7);
                   
-                  //TODO we don't need this
-                  int persistentChannelCount = rs.getInt(8);
-                  
+
                   //TODO - We are mixing concerns here
                   //The basic JDBCPersistencManager should *only* know about core messages - not 
                   //JBossMessages - we should subclass JBDCPersistenceManager and the JBossMessage
@@ -1426,7 +1416,9 @@
          
          psReference.setLong(3, ref.getMessageID());
          
-         int rows = psReference.executeUpdate();                         
+         int rows = psReference.executeUpdate();
+
+         if (trace) { log.trace("Updated " + rows + " rows"); }
       }
       catch (Exception e)
       {
@@ -1745,9 +1737,9 @@
       return callback;
    }
    
-   /*
-    * We order the list of references in ascending message order    
-    * thus preventing deadlock when 2 or more channels are updating the same messages in different transactions.   
+   /**
+    * We order the list of references in ascending message order thus preventing deadlock when 2 or
+    * more channels are updating the same messages in different transactions.
     */
    protected void orderReferences(List references)
    {      
@@ -1758,29 +1750,28 @@
       throws Exception
    {
       //TODO - A slight optimisation - it's possible we have refs referring to the same message
-      //so we will end up acquiring the lock more than once which is unnecessary
-      //If find unique set of messages can avoid this
+      //       so we will end up acquiring the lock more than once which is unnecessary. If find
+      //       unique set of messages can avoid this.
+
       List allRefs = new ArrayList(refsToAdd.size() + refsToRemove.size());
-      Iterator iter = refsToAdd.iterator();
-      while (iter.hasNext())
+
+      for(Iterator i = refsToAdd.iterator(); i.hasNext(); )
       {
-         ChannelRefPair pair = (ChannelRefPair)iter.next();
+         ChannelRefPair pair = (ChannelRefPair)i.next();
          allRefs.add(pair.ref);
       }
-      iter = refsToRemove.iterator();
-      while (iter.hasNext())
+
+      for(Iterator i = refsToRemove.iterator(); i.hasNext(); )
       {
-         ChannelRefPair pair = (ChannelRefPair)iter.next();
+         ChannelRefPair pair = (ChannelRefPair)i.next();
          allRefs.add(pair.ref);
       }
             
       orderReferences(allRefs);
       
-      //For one phase we simply add rows corresponding to the refs
-      //and remove rows corresponding to the deliveries in one jdbc tx
-      //We also need to store or remove messages as necessary, depending
-      //on whether they've already been stored or still referenced by other
-      //channels
+      // For one phase we simply add rows corresponding to the refs and remove rows corresponding to
+      // the deliveries in one jdbc tx. We also need to store or remove messages as necessary,
+      // depending on whether they've already been stored or still referenced by other channels.
          
       Connection conn = null;
       PreparedStatement psReference = null;
@@ -1794,29 +1785,25 @@
       {
          conn = ds.getConnection();
          
-         //obtain locks on all messages
+         // Obtain locks on all messages
          getLocks(allRefs);
          
-         //First the adds
-         
-         iter = refsToAdd.iterator();
-         
-         boolean batch = usingBatchUpdates && refsToAdd.size() > 0;
-         
+         // First the adds
+
          boolean messageInsertsInBatch = false;
          boolean messageUpdatesInBatch = false;
-         
+         boolean batch = usingBatchUpdates && refsToAdd.size() > 0;
+
          if (batch)
          {
             psReference = conn.prepareStatement(getSQLStatement("INSERT_MESSAGE_REF"));
             psInsertMessage = conn.prepareStatement(getSQLStatement("INSERT_MESSAGE"));
             psIncMessage = conn.prepareStatement(getSQLStatement("INC_CHANNELCOUNT"));
          }
-         
-         while (iter.hasNext())
+
+         for(Iterator i = refsToAdd.iterator(); i.hasNext(); )
          {
-            ChannelRefPair pair = (ChannelRefPair) iter.next();
-            
+            ChannelRefPair pair = (ChannelRefPair)i.next();
             MessageReference ref = pair.ref;
                                                 
             if (!batch)
@@ -1824,8 +1811,8 @@
                psReference = conn.prepareStatement(getSQLStatement("INSERT_MESSAGE_REF"));
             }
             
-            //Now store the reference
-            addReference(pair.channelId, ref, psReference, false);
+            // Now store the reference
+            addReference(pair.channelID, ref, psReference, false);
               
             if (batch)
             {
@@ -1852,18 +1839,15 @@
             boolean added;
             if (!m.isPersisted())
             {               
-               //First time so add message
+               // First time so add message
                storeMessage(m, psInsertMessage);
-               
                added = true;
-               
                m.setPersisted(true);
             }
             else
             {               
-               //Update message channel count
+               // Update message channel count
                incrementChannelCount(m, psIncMessage);
-               
                added = false;
             }
             
@@ -1872,13 +1856,11 @@
                if (added)
                {
                   psInsertMessage.addBatch();
-                  
                   messageInsertsInBatch = true;
                }
                else
                { 
                   psIncMessage.addBatch();
-                  
                   messageUpdatesInBatch = true;
                }
             }
@@ -1887,13 +1869,11 @@
                if (added)
                {
                   int rows = psInsertMessage.executeUpdate();
-                  
                   if (trace) { log.trace("Inserted " + rows + " rows"); }
                }
                else
                {
                   int rows = psIncMessage.executeUpdate();
-                  
                   if (trace) { log.trace("Updated " + rows + " rows"); }
                }
                psInsertMessage.close();
@@ -1905,6 +1885,10 @@
          
          if (batch)
          {
+            // Process the add batch
+
+
+
             int[] rowsReference = psReference.executeBatch();
             
             if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE_REF"), rowsReference, "inserted"); }
@@ -1912,13 +1896,12 @@
             if (messageInsertsInBatch)
             {
                int[] rowsMessage = psInsertMessage.executeBatch();
-               
                if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE"), rowsMessage, "inserted"); }
             }
+
             if (messageUpdatesInBatch)
             {
                int[] rowsMessage = psIncMessage.executeBatch();
-               
                if (trace) { logBatchUpdate(getSQLStatement("INC_CHANNELCOUNT"), rowsMessage, "updated"); }
             }
             
@@ -1930,32 +1913,30 @@
             psIncMessage = null;
          }
          
-         //Now the removes
-         
-         iter = refsToRemove.iterator();
-         
-         batch = usingBatchUpdates && refsToRemove.size() > 0;
+         // Now the removes
 
          psReference = null;
          psDeleteMessage = null;
-         
+         batch = usingBatchUpdates && refsToRemove.size() > 0;
+
          if (batch)
          {
             psReference = conn.prepareStatement(getSQLStatement("DELETE_MESSAGE_REF"));
             psDeleteMessage = conn.prepareStatement(getSQLStatement("DELETE_MESSAGE"));
             psDecMessage = conn.prepareStatement(getSQLStatement("DEC_CHANNELCOUNT"));
          }
+
          
-         while (iter.hasNext())
+         for(Iterator i = refsToRemove.iterator(); i.hasNext(); )
          {
-            ChannelRefPair pair = (ChannelRefPair) iter.next();
+            ChannelRefPair pair = (ChannelRefPair)i.next();
             
             if (!batch)
             {
                psReference = conn.prepareStatement(getSQLStatement("DELETE_MESSAGE_REF"));
             }
             
-            removeReference(pair.channelId, pair.ref, psReference);
+            removeReference(pair.channelID, pair.ref, psReference);
             
             if (batch)
             {
@@ -1964,9 +1945,7 @@
             else
             {
                int rows = psReference.executeUpdate();
-               
                if (trace) { log.trace("Deleted " + rows + " rows"); }
-               
                psReference.close();
                psReference = null;
             }
@@ -1979,28 +1958,25 @@
             
             Message m = pair.ref.getMessage();
                                 
-            //Update the channel count
+            // Update the channel count
             
             decrementChannelCount(m, psDecMessage);
             
-            //Delete the message (if necessary)
+            // Delete the message (if necessary)
             
             removeMessage(m, psDeleteMessage);
                        
             if (batch)
             {
                psDecMessage.addBatch();
-               
-               psDeleteMessage.addBatch();                              
+               psDeleteMessage.addBatch();
             }
             else
             {
                int rows = psDecMessage.executeUpdate();
-               
                if (trace) { log.trace("Updated " + rows + " rows"); }
                
                rows = psDeleteMessage.executeUpdate();
-               
                if (trace) { log.trace("Deleted " + rows + " rows"); }
 
                psDeleteMessage.close();
@@ -2012,6 +1988,8 @@
          
          if (batch)
          {
+            // Process the remove batch
+
             int[] rows = psReference.executeBatch();
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE_REF"), rows, "deleted"); }
@@ -2035,7 +2013,6 @@
       catch (Exception e)
       {
          wrap.exceptionOccurred();                  
-         
          throw e;
       }
       finally
@@ -2327,7 +2304,7 @@
                psReference = conn.prepareStatement(getSQLStatement("INSERT_MESSAGE_REF"));
             }
             
-            prepareToAddReference(pair.channelId, pair.ref, tx, psReference);
+            prepareToAddReference(pair.channelID, pair.ref, tx, psReference);
             
             if (batch)
             {
@@ -2450,7 +2427,7 @@
                psReference = conn.prepareStatement(getSQLStatement("UPDATE_MESSAGE_REF"));
             }
             
-            prepareToRemoveReference(pair.channelId, pair.ref, tx, psReference);
+            prepareToRemoveReference(pair.channelID, pair.ref, tx, psReference);
             
             if (batch)
             {
@@ -2771,14 +2748,10 @@
       }
    }  
    
-   
-   
-   protected void addReference(long channelID, MessageReference ref, PreparedStatement ps, boolean paged) throws Exception
+   protected void addReference(long channelID, MessageReference ref,
+                               PreparedStatement ps, boolean paged) throws Exception
    {
-      if (trace)
-      {
-         log.trace("adding " + ref + " to channel " + channelID);
-      }
+      if (trace) { log.trace("adding " + ref + " to channel " + channelID); }
       
       ps.setLong(1, channelID);
       ps.setLong(2, ref.getMessageID());
@@ -2797,12 +2770,10 @@
       ps.setString(8, ref.isReliable() ? "Y" : "N");
    }
    
-   protected void removeReference(long channelID, MessageReference ref, PreparedStatement ps) throws Exception
+   protected void removeReference(long channelID, MessageReference ref, PreparedStatement ps)
+      throws Exception
    {
-      if (trace)
-      {
-         log.trace("removing " + ref + " from channel " + channelID);
-      }
+      if (trace) { log.trace("removing " + ref + " from channel " + channelID); }
       
       ps.setLong(1, ref.getMessageID());
       ps.setLong(2, channelID);      
@@ -2811,11 +2782,7 @@
    protected void prepareToAddReference(long channelID, MessageReference ref, Transaction tx, PreparedStatement ps)
      throws Exception
    {
-      if (trace)
-      {
-         log.trace("adding " + ref + " to channel " + channelID
-               + (tx == null ? " non-transactionally" : " on transaction: " + tx));
-      }
+      if (trace) { log.trace("adding " + ref + " to channel " + channelID + (tx == null ? " non-transactionally" : " on transaction: " + tx)); }
       
       ps.setLong(1, channelID);
       ps.setLong(2, ref.getMessageID());
@@ -3356,14 +3323,12 @@
         
    private static class ChannelRefPair
    {
-      private long channelId;
-      
+      private long channelID;
       private MessageReference ref;
       
-      private ChannelRefPair(long channelId, MessageReference ref)
+      private ChannelRefPair(long channelID, MessageReference ref)
       {
-         this.channelId = channelId;
-         
+         this.channelID = channelID;
          this.ref = ref;
       }
    }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBindings.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBindings.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultBindings.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -37,15 +37,24 @@
  */
 public class DefaultBindings implements Bindings
 {
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private List bindings;
-   
    private int durableCount;
-   
+
+   // Constructors --------------------------------------------------
+
    public DefaultBindings()
    {
       bindings = new ArrayList();
    }
 
+   // Bindings implementation ---------------------------------------
+
    public void addBinding(Binding binding)
    {
       if (bindings.contains(binding))
@@ -53,38 +62,55 @@
          throw new IllegalArgumentException("Bindings already contains binding: " + binding);
       }
       bindings.add(binding);
-      
+
       if (binding.getQueue().isRecoverable())
       {
          durableCount++;
       }
    }
 
-   public Collection getAllBindings()
-   {
-      return bindings;
-   }
-
    public boolean removeBinding(Binding binding)
    {
       boolean removed = bindings.remove(binding);
-      
+
       if (removed && binding.getQueue().isRecoverable())
       {
          durableCount--;
       }
-      
+
       return removed;
    }
-   
+
+   public Collection getAllBindings()
+   {
+      return bindings;
+   }
+
    public int getDurableCount()
    {
       return durableCount;
    }
-   
+
    public boolean isEmpty()
    {
       return bindings.isEmpty();
    }
 
+   // Public --------------------------------------------------------
+
+   public String toString()
+   {
+      return "Bindings[" + Integer.toHexString(hashCode()) + ", count=" + bindings.size() + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredBindings.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -41,67 +41,93 @@
  */
 class DefaultClusteredBindings extends DefaultBindings implements ClusteredBindings
 {
+
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    // Map <name, router>
    private Map nameMap;
-   
    private int thisNode;
-   
    private int localDurableCount;
-   
+
+   // Constructors --------------------------------------------------
+
    DefaultClusteredBindings(int thisNode)
    {
       super();
-      
+
       nameMap = new HashMap();
-      
+
       this.thisNode = thisNode;
    }
-   
+
+   // DefaultBindings overrides -------------------------------------
+
    public void addBinding(Binding binding)
    {
       super.addBinding(binding);
-  
+
       if (binding.getNodeID() == thisNode && binding.getQueue().isRecoverable())
       {
          localDurableCount++;
-      }      
+      }
    }
-   
+
    public boolean removeBinding(Binding binding)
    {
       boolean removed = super.removeBinding(binding);
-      
+
       if (!removed)
       {
          return false;
       }
-           
+
       if (binding.getNodeID() == thisNode && binding.getQueue().isRecoverable())
       {
          localDurableCount--;
-      }      
+      }
 
       return true;
    }
-   
+
+   // ClusteredBindings implementation ------------------------------
+
+   public Collection getRouters()
+   {
+      return nameMap.values();
+   }
+
    public int getLocalDurableCount()
    {
       return localDurableCount;
    }
-   
-   public Collection getRouters()
-   {
-      return nameMap.values();
-   }
-   
+
    public void addRouter(String queueName, ClusterRouter router)
    {
       nameMap.put(queueName, router);
    }
-   
+
    public void removeRouter(String queueName)
    {
       nameMap.remove(queueName);
    }
 
+   // Public --------------------------------------------------------
+
+   public String toString()
+   {
+      return "CusteredBindings[" + super.toString() + " count=" + nameMap.size() + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -801,10 +801,9 @@
     */
    public void asyncSendRequest(ClusterRequest request) throws Exception
    {
-      if (trace) { log.trace(this.currentNodeId + " sending asynch request to group, request: " + request); }
+      if (trace) { log.trace(this + " sending asynchronously " + request + " to group"); }
 
       byte[] bytes = writeRequest(request);
-
       asyncChannel.send(new Message(null, null, bytes));
    }
 
@@ -813,22 +812,17 @@
     */
    public void asyncSendRequest(ClusterRequest request, int nodeId) throws Exception
    {
-      if (trace) { log.trace(this.currentNodeId + " sending asynch request to single node, request: " + request + " node " + nodeId); }
-
       Address address = this.getAddressForNodeId(nodeId, false);
 
-      if (trace) { log.trace(this.currentNodeId + " sending to address " + address); }
-
       if (address == null)
       {
          throw new IllegalArgumentException("Cannot find address for node " + nodeId);
       }
 
-      byte[] bytes = writeRequest(request);
+      if (trace) { log.trace(this + " sending asynchronously " + request + " to node  " + nodeId + "/" + address); }
 
-      Message m = new Message(address, null, bytes);
-
-      asyncChannel.send(m);
+      byte[] bytes = writeRequest(request);
+      asyncChannel.send(new Message(address, null, bytes));
    }
 
    /*
@@ -840,13 +834,13 @@
       {
          holdingArea.put(id, tx);
 
-         if (trace) { log.trace(this.currentNodeId + " added transaction " + tx + " to holding area with id " + id); }
+         if (trace) { log.trace(this + " added transaction " + tx + " to holding area as " + id); }
       }
    }
 
    public void commitTransaction(TransactionId id) throws Throwable
    {
-      if (trace) { log.trace(this.currentNodeId + " committing transaction " + id ); }
+      if (trace) { log.trace(currentNodeId + " committing transaction " + id ); }
 
       ClusterTransaction tx = null;
 
@@ -862,12 +856,12 @@
 
       tx.commit(this);
 
-      if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
+      if (trace) { log.trace(this + " committed transaction " + id ); }
    }
 
    public void rollbackTransaction(TransactionId id) throws Throwable
    {
-      if (trace) { log.trace(this.currentNodeId + " rolling back transaction " + id ); }
+      if (trace) { log.trace(this + " rolling back transaction " + id ); }
 
       ClusterTransaction tx = null;
 
@@ -883,14 +877,14 @@
 
       tx.rollback(this);
 
-      if (trace) { log.trace(this.currentNodeId + " committed transaction " + id ); }
+      if (trace) { log.trace(this + " committed transaction " + id ); }
    }
 
    public void updateQueueStats(int nodeId, List statsList) throws Exception
    {
       lock.readLock().acquire();
 
-      if (trace) { log.trace(this.currentNodeId + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
+      if (trace) { log.trace(this + " updating queue stats from node " + nodeId + " stats size: " + statsList.size()); }
 
       try
       {
@@ -905,7 +899,7 @@
          if (nameMap == null)
          {
             //This is ok, the node might have left
-            if (trace) { log.trace(this.currentNodeId + " cannot find node in name map, i guess the node might have left?"); }
+            if (trace) { log.trace(this + " cannot find node in name map, i guess the node might have left?"); }
          }
          else
          {
@@ -920,7 +914,7 @@
                if (bb == null)
                {
                   //I guess this is possible if the queue was unbound
-                  if (trace) { log.trace(this.currentNodeId + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
+                  if (trace) { log.trace(this + " cannot find binding for queue " + st.getQueueName() + " it could have been unbound"); }
                }
                else
                {
@@ -952,7 +946,7 @@
 
                         localQueue.deliver(false);
 
-                        if (trace) { log.trace(this.currentNodeId + " triggered delivery for " + localQueue.getName()); }
+                        if (trace) { log.trace(this + " triggered delivery for " + localQueue.getName()); }
                      }
                   }
                }
@@ -1177,10 +1171,9 @@
       {
          ClusteredBindings cb = (ClusteredBindings)conditionMap.get(condition);
 
+         int lastNodeId = -1;
          boolean startInternalTx = false;
 
-         int lastNodeId = -1;
-
          if (cb != null)
          {
             if (trace) { log.trace(this + " found clustered bindings " + cb); }
@@ -1208,18 +1201,12 @@
             }
 
             int numberRemote = 0;
-
+            long lastChannelId = -1;
             Map queueNameNodeIdMap = null;
 
-            long lastChannelId = -1;
-
-            Collection routers = cb.getRouters();
-
-            Iterator iter = routers.iterator();
-
-            while (iter.hasNext())
+            for(Iterator i = cb.getRouters().iterator(); i.hasNext(); )
             {
-               ClusterRouter router = (ClusterRouter)iter.next();
+               ClusterRouter router = (ClusterRouter)i.next();
 
                Delivery del = router.handle(null, ref, tx);
 
@@ -1229,7 +1216,7 @@
 
                   ClusteredQueue queue = (ClusteredQueue)del.getObserver();
 
-                  if (trace) { log.trace(this + " successfully routed message to " + (queue.isLocal() ? "local"  : "remote")+ " destination '" + queue.getName() + "' on node " + queue.getNodeId()); }
+                  if (trace) { log.trace(this + " successfully routed message to " + (queue.isLocal() ? "LOCAL"  : "REMOTE") + " destination '" + queue.getName() + "' on node " + queue.getNodeId()); }
 
                   if (router.numberOfReceivers() > 1)
                   {
@@ -1247,9 +1234,9 @@
 
                   if (!queue.isLocal())
                   {
-                     // We need to send the message remotely
+                     // We need to send the message remotely, count recipients so we know whether
+                     // to unicast or multicast
                      numberRemote++;
-
                      lastNodeId = queue.getNodeId();
                      lastChannelId = queue.getChannelID();
                   }
@@ -1318,8 +1305,9 @@
 
             if (startInternalTx)
             {
+               if (trace) { log.trace(this + " committing " + tx); }
                tx.commit();
-               if (trace) { log.trace(this + " committed internal transaction"); }
+               if (trace) { log.trace(this + " committed " + tx); }
             }
          }
       }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultRouter.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -269,7 +269,7 @@
 
    public String toString()
    {
-      return "DefaultRouter[" + Integer.toHexString(hashCode()) + "]";
+      return "Router[" + Integer.toHexString(hashCode()) + "]";
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -59,33 +59,30 @@
    private TransactionRepository tr;
    
    //TODO - we shouldn't have to specify office AND nodeId
-   public LocalClusteredQueue(PostOffice office, int nodeId, String name, long id, MessageStore ms, PersistenceManager pm,             
-                              boolean acceptReliableMessages, boolean recoverable, QueuedExecutor executor,
-                              Filter filter, TransactionRepository tr,
+   public LocalClusteredQueue(PostOffice office, int nodeId, String name, long id,
+                              MessageStore ms, PersistenceManager pm,
+                              boolean acceptReliableMessages, boolean recoverable,
+                              QueuedExecutor executor, Filter filter, TransactionRepository tr,
                               int fullSize, int pageSize, int downCacheSize)
    {
-      super(name, id, ms, pm, acceptReliableMessages, recoverable, executor, filter, fullSize, pageSize, downCacheSize);
+      super(name, id, ms, pm, acceptReliableMessages, recoverable, 
+            executor, filter, fullSize, pageSize, downCacheSize);
      
       this.nodeId = nodeId;
-      
       this.tr = tr;
-      
-      //TODO - This cast is potentially unsafe - handle better
-      this.office = (PostOfficeInternal)office;
+      this.office = (PostOfficeInternal)office; //TODO - This cast is potentially unsafe - handle better
    }
    
-   public LocalClusteredQueue(PostOffice office, int nodeId, String name, long id, MessageStore ms, PersistenceManager pm,             
-                              boolean acceptReliableMessages, boolean recoverable, QueuedExecutor executor,
-                              Filter filter, TransactionRepository tr)
+   public LocalClusteredQueue(PostOffice office, int nodeId, String name, long id,
+                              MessageStore ms, PersistenceManager pm,
+                              boolean acceptReliableMessages, boolean recoverable,
+                              QueuedExecutor executor, Filter filter, TransactionRepository tr)
    {
       super(name, id, ms, pm, acceptReliableMessages, recoverable, executor, filter);
       
       this.nodeId = nodeId;
-      
       this.tr = tr;
-      
-      //TODO - This cast is potentially unsafe - handle better
-      this.office = (PostOfficeInternal)office;
+      this.office = (PostOfficeInternal)office; //TODO - This cast is potentially unsafe - handle better
    }
    
    public void setPullQueue(RemoteQueueStub queue)
@@ -135,7 +132,7 @@
 
    public String toString()
    {
-      return "LocalClusteredQueue[" + this.getChannelID() + "/" + this.getName() +"]"; 
+      return "LocalClusteredQueue[" + getChannelID() + "/" + getName() +"]"; 
    }
    
    /*

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -49,78 +49,57 @@
  */
 public class RemoteQueueStub implements ClusteredQueue
 {
+   // Constants -----------------------------------------------------
+
    private static final Logger log = Logger.getLogger(RemoteQueueStub.class);
-      
-   private int nodeId;
-   
+
+   // Static --------------------------------------------------------
+
+   private static boolean trace = log.isTraceEnabled();
+
+   // Attributes ----------------------------------------------------
+
+   private int nodeID;
    private String name;
-   
-   private long id;
-   
+   private long channelID;
    private Filter filter;
-   
    private boolean recoverable;
-   
    private PersistenceManager pm;
-   
    private QueueStats stats;
-   
+
+   // Constructors --------------------------------------------------
+
    public RemoteQueueStub(int nodeId, String name, long id, boolean recoverable,
                           PersistenceManager pm, Filter filter)
    {
-      this.nodeId = nodeId;
-      
+      this.nodeID = nodeId;
       this.name = name;
-      
-      this.id = id;
-      
+      this.channelID = id;
       this.recoverable = recoverable;
-      
       this.pm = pm;
-      
       this.filter = filter;
    }
-   
-   public int getNodeId()
-   {
-      return nodeId;
-   }
-   
-   public boolean isLocal()
-   {
-      return false;
-   }
-   
-   public void setStats(QueueStats stats)
-   {
-      this.stats = stats;
-   }
-   
-   public QueueStats getStats()
-   {
-      return stats;
-   }
-   
+
+   // Receiver implementation ---------------------------------------
+
    public Delivery handle(DeliveryObserver observer, MessageReference reference, Transaction tx)
    {
+      if (trace) { log.trace(this + " handling " + reference); }
+
       if (filter != null && !filter.accept(reference))
       {
-         Delivery del = new SimpleDelivery(this, reference, false, false);
-         
-         log.info("********** doesn't match filter");
-         
-         return del;
+         if (trace) { log.trace(this + " rejecting " + reference + " because it doesn't match filter"); }
+         return new SimpleDelivery(this, reference, false, false);
       }
-      
+
       if (recoverable && reference.isReliable())
       {
          try
          {
-            //If the message is persistent and we are recoverable then we persist here, *before*
-            //the message is sent across the network
-
-            //This will increment any channelcount on the message in storage
-            pm.addReference(id, reference, tx);
+            // If the message is persistent and we are recoverable then we persist here, *before*
+            // the message is sent across the network. This will increment any channelcount on the
+            // message in storage.
+            pm.addReference(channelID, reference, tx);
          }
          catch (Exception e)
          {
@@ -128,59 +107,59 @@
             return null;
          }
       }
-      
-      log.info("*********** accepting message:" + reference);
-  
-      return new SimpleDelivery(this, reference, false);      
-   }
 
-   public Filter getFilter()
-   {
-      return filter;
+      if (trace) { log.trace(this + " accepting " + reference + " for delivery"); }
+      return new SimpleDelivery(this, reference, false);
    }
 
-   public String getName()
-   {
-      return name;
-   }
+   // Distributor implementation ------------------------------------
 
-   public boolean acceptReliableMessages()
+   public boolean contains(Receiver receiver)
    {
-      return true;
+      throw new UnsupportedOperationException();
    }
 
-   public List browse()
+   public Iterator iterator()
    {
       throw new UnsupportedOperationException();
    }
 
-   public List browse(Filter filter)
+   public boolean add(Receiver receiver)
    {
-      throw new UnsupportedOperationException();
+      // TODO Auto-generated method stub
+      return false;
    }
 
-   public void clear()
+   public boolean remove(Receiver receiver)
    {
       throw new UnsupportedOperationException();
    }
 
-   public void close()
+   public int numberOfReceivers()
    {
+      throw new UnsupportedOperationException();
    }
 
-   public void deliver(boolean synchronous)
+   // DeliveryObserver implementation -------------------------------
+
+   public void acknowledge(Delivery d, Transaction tx) throws Throwable
    {
-      throw new UnsupportedOperationException();
+      if (recoverable && d.getReference().isReliable())
+      {
+         pm.removeReference(this.channelID, d.getReference(), tx);
+      }
    }
 
-   public List delivering(Filter filter)
+   public void cancel(Delivery d) throws Throwable
    {
       throw new UnsupportedOperationException();
    }
 
+   // Channel implemenation -----------------------------------------
+
    public long getChannelID()
    {
-      return id;
+      return channelID;
    }
 
    public boolean isRecoverable()
@@ -188,93 +167,132 @@
       return recoverable;
    }
 
-   public int messageCount()
+   public boolean acceptReliableMessages()
    {
+      return true;
+   }
+
+   public List browse()
+   {
       throw new UnsupportedOperationException();
    }
 
-   public void removeAllReferences() throws Throwable
+   public List browse(Filter filter)
    {
       throw new UnsupportedOperationException();
    }
 
-   public List undelivered(Filter filter)
+   public void deliver(boolean synchronous)
    {
       throw new UnsupportedOperationException();
    }
 
-   public void acknowledge(Delivery d, Transaction tx) throws Throwable
+   public void close()
    {
-      if (recoverable && d.getReference().isReliable())
-      {
-         pm.removeReference(this.id, d.getReference(), tx);
-      }
    }
 
-   public void cancel(Delivery d) throws Throwable
+   public List delivering(Filter filter)
    {
       throw new UnsupportedOperationException();
    }
 
-   public boolean add(Receiver receiver)
+   public List undelivered(Filter filter)
    {
-      // TODO Auto-generated method stub
-      return false;
+      throw new UnsupportedOperationException();
    }
 
-   public boolean contains(Receiver receiver)
+   public void clear()
    {
       throw new UnsupportedOperationException();
    }
 
-   public Iterator iterator()
+   public int messageCount()
    {
       throw new UnsupportedOperationException();
    }
 
-   public boolean remove(Receiver receiver)
+   public void removeAllReferences() throws Throwable
    {
       throw new UnsupportedOperationException();
    }
-   
-   public int numberOfReceivers()
+
+   public void load() throws Exception
    {
-      throw new UnsupportedOperationException();
    }
 
+   public void unload() throws Exception
+   {
+   }
+
    public void activate()
-   {      
+   {
    }
 
    public void deactivate()
-   {      
+   {
    }
 
-   public void load() throws Exception
-   {      
+   public boolean isActive()
+   {
+      throw new UnsupportedOperationException();
    }
 
-   public void unload() throws Exception
-   {      
-   }
-   
-   public boolean isActive()
+   public List createDeliveries(List messageIds)
    {
       throw new UnsupportedOperationException();
    }
-   
+
+   // Queue implementation ------------------------------------------
+
+   public String getName()
+   {
+      return name;
+   }
+
+   public Filter getFilter()
+   {
+      return filter;
+   }
+
    public boolean isClustered()
    {
       return true;
    }
 
-   public String toString()
+   // ClusteredQueue implementation ---------------------------------
+
+   public QueueStats getStats()
    {
-      return "RemoteQueueStub(node=" + this.nodeId + " name=" + this.name + " channelId=" + this.id + ")";
+      return stats;
    }
 
-   public List createDeliveries(List messageIds)
+   public int getNodeId()
    {
-      throw new UnsupportedOperationException();
+      return nodeID;
    }
+
+   public boolean isLocal()
+   {
+      return false;
+   }
+
+   // Public --------------------------------------------------------
+
+   public void setStats(QueueStats stats)
+   {
+      this.stats = stats;
+   }
+
+   public String toString()
+   {
+      return "RemoteQueueStub[" + channelID + "/" + name + " -> " + nodeID + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -41,53 +41,112 @@
  *
  */
 class SendTransactionRequest extends TransactionRequest
-{ 
+{
+   // Constants -----------------------------------------------------
+
    static final int TYPE = 8;
-   
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
    private List messageHolders;
-      
+
+   // Constructors --------------------------------------------------
+
    SendTransactionRequest()
-   {      
+   {
    }
-        
+
    SendTransactionRequest(int nodeId, long txId, List messageHolders, long channelID)
    {
       super(nodeId, txId, true, channelID);
-      
-      this.messageHolders = messageHolders;  
+
+      this.messageHolders = messageHolders;
    }
-   
+
    SendTransactionRequest(int nodeId, long txId)
    {
       super(nodeId, txId, false);
    }
-   
+
+   // TransactionRequest overrides -----------------------------------
+
+   public void read(DataInputStream in) throws Exception
+   {
+      super.read(in);
+
+      int b = in.readByte();
+      if (b == StreamUtils.NULL)
+      {
+         messageHolders = null;
+      }
+      else
+      {
+         int size = in.readInt();
+         messageHolders = new ArrayList(size);
+         for (int i = 0; i < size; i++)
+         {
+            MessageHolder holder = new MessageHolder();
+            holder.read(in);
+            messageHolders.add(holder);
+         }
+      }
+   }
+
+   public void write(DataOutputStream out) throws Exception
+   {
+      super.write(out);
+      if (messageHolders != null)
+      {
+         out.writeByte(StreamUtils.LIST);
+         out.writeInt(messageHolders.size());
+         Iterator iter = messageHolders.iterator();
+         while (iter.hasNext())
+         {
+            MessageHolder holder = (MessageHolder)iter.next();
+            holder.write(out);
+         }
+      }
+      else
+      {
+         out.writeByte(StreamUtils.NULL);
+      }
+   }
+
+   // ClusterTransaction implementation -----------------------------
+
    public void commit(PostOfficeInternal office) throws Exception
    {
       Iterator iter = messageHolders.iterator();
-      
+
       while (iter.hasNext())
       {
          MessageHolder holder = (MessageHolder)iter.next();
-         
+
          office.routeFromCluster(holder.getMessage(), holder.getRoutingKey(), holder.getQueueNameToNodeIdMap());
       }
    }
-   
+
+   public void rollback(PostOfficeInternal office) throws Exception
+   {
+      //NOOP
+   }
+
    public boolean check(PostOfficeInternal office) throws Exception
    {
       //If the messages exist in the database then we should commit the transaction
       //otherwise we should roll it back
-      
+
       Iterator iter = messageHolders.iterator();
-      
+
       //We only need to check that one of the refs made it to the database - the refs would have
       //been inserted into the db transactionally, so either they're all there or none are
       MessageHolder holder = (MessageHolder)iter.next();
-      
+
       //We store the channelID of one of the channels that the message was persisted in
       //it doesn't matter which one since they were all inserted in the same tx
-      
+
       if (office.referenceExistsInStorage(checkChannelID, holder.getMessage().getMessageID()))
       {
          //We can commit
@@ -100,56 +159,34 @@
       }
    }
 
-   public void rollback(PostOfficeInternal office) throws Exception
-   {
-      //NOOP
-   }  
-   
+   // Public --------------------------------------------------------
+
    public byte getType()
    {
       return TYPE;
    }
-   
-   public void read(DataInputStream in) throws Exception
+
+   public String toString()
    {
-      super.read(in);
-      
-      int b = in.readByte();
-      if (b == StreamUtils.NULL)
+      StringBuffer sb = new StringBuffer("SendTransactionRequest[");
+      for(Iterator i = messageHolders.iterator(); i.hasNext(); )
       {
-         messageHolders = null;
-      }
-      else
-      {
-         int size = in.readInt();
-         messageHolders = new ArrayList(size);
-         for (int i = 0; i < size; i++)
+         sb.append(((MessageHolder)i.next()).getMessage());
+         if (i.hasNext())
          {
-            MessageHolder holder = new MessageHolder();
-            holder.read(in);
-            messageHolders.add(holder);
+            sb.append(',');
          }
       }
+      sb.append("]");
+      return sb.toString();
    }
 
-   public void write(DataOutputStream out) throws Exception
-   {
-      super.write(out);
-      if (messageHolders != null)
-      {
-         out.writeByte(StreamUtils.LIST);
-         out.writeInt(messageHolders.size());
-         Iterator iter = messageHolders.iterator();
-         while (iter.hasNext())
-         {
-            MessageHolder holder = (MessageHolder)iter.next();
-            holder.write(out);
-         }
-      }
-      else
-      {
-         out.writeByte(StreamUtils.NULL);
-      }      
-   } 
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
 }
 

Modified: trunk/src/main/org/jboss/messaging/core/tx/Transaction.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/Transaction.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/tx/Transaction.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -181,7 +181,7 @@
          throw new TransactionException("Transaction already rolled back, cannot commit");
       }
 
-      if (trace) { log.trace("executing before commit hooks " + this); }
+      if (trace) { log.trace(this + " executing before commit hooks"); }
        
       boolean onePhase = state != STATE_PREPARED;
       
@@ -201,11 +201,11 @@
       
       state = STATE_COMMITTED;
       
-      if (trace) { log.trace("committed " + this); }
+      if (trace) { log.trace(this + " committed"); }
       
       iter = callbacks.iterator();
       
-      if (trace) { log.trace("executing after commit hooks " + this); }
+      if (trace) { log.trace(this + " executing after commit hooks"); }
       
       if (firstCallback != null)
       {         
@@ -230,7 +230,7 @@
          repository.deleteTransaction(this);
       }
             
-      if (trace) { log.trace("commit process complete " + this); }            
+      if (trace) { log.trace(this + " commit process complete"); }
    }
    
    public synchronized void prepare() throws Exception
@@ -240,7 +240,7 @@
          throw new TransactionException("Transaction not active, cannot prepare");
       }
       
-      if (trace) { log.trace("executing before prepare hooks " + this); }
+      if (trace) { log.trace(this + " executing before prepare hooks"); }
       
       if (firstCallback != null)
       {
@@ -258,7 +258,7 @@
       
       state = STATE_PREPARED;
       
-      if (trace) { log.trace("prepared " + this); }
+      if (trace) { log.trace(this + " prepared"); }
       
       if (firstCallback != null)
       {
@@ -267,7 +267,7 @@
       
       iter = callbacks.iterator();
       
-      if (trace) { log.trace("executing after prepare hooks " + this); }
+      if (trace) { log.trace(this + " executing after prepare hooks"); }
       
       while (iter.hasNext())
       {
@@ -276,7 +276,7 @@
          callback.afterPrepare();
       }            
       
-      if (trace) { log.trace("prepare process complete " + this); }
+      if (trace) { log.trace(this + " prepare process complete"); }
    }
    
    public synchronized void rollback() throws Exception
@@ -290,7 +290,7 @@
          throw new TransactionException("Transaction already rolled back, cannot rollback");
       }
       
-      if (trace) { log.trace("executing before rollback hooks " + this); }
+      if (trace) { log.trace(this + " executing before rollback hooks"); }
       
       boolean onePhase = state != STATE_PREPARED;
       
@@ -307,9 +307,9 @@
       
       state = STATE_ROLLEDBACK;
       
-      if (trace) { log.trace("rolled back " + this); }
+      if (trace) { log.trace(this + " rolled back"); }
 
-      if (trace) { log.trace("executing after prepare hooks " + this); }
+      if (trace) { log.trace(this + " executing after rollback hooks"); }
 
       if (firstCallback != null)
       {
@@ -330,12 +330,12 @@
          repository.deleteTransaction(this);
       }
       
-      if (trace) { log.trace("rollback process complete " + this); }
+      if (trace) { log.trace(this + " rollback process complete"); }
    }
 
    public synchronized void setRollbackOnly() throws Exception
    {
-      if (trace) { log.trace("setting rollback_only on " + this); }
+      if (trace) { log.trace("setting ROLLBACK_ONLY on " + this); }
 
       state = STATE_ROLLBACK_ONLY;
    }

Modified: trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -29,7 +29,7 @@
 import javax.transaction.xa.Xid;
 
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 
@@ -58,13 +58,13 @@
    
    private PersistenceManager persistenceManager;
    
-   private IdManager idManager;
+   private IDManager idManager;
 
    // Static --------------------------------------------------------
    
    // Constructors --------------------------------------------------
    
-   public TransactionRepository(PersistenceManager persistenceManager, IdManager idManager)
+   public TransactionRepository(PersistenceManager persistenceManager, IDManager idManager)
    {
       this.persistenceManager = persistenceManager;
       
@@ -169,7 +169,7 @@
       {
          throw new TransactionException("There is already a local tx for global tx " + xid);
       }
-      Transaction tx = new Transaction(idManager.getId(), xid, this);
+      Transaction tx = new Transaction(idManager.getID(), xid, this);
       
       if (trace) { log.trace("created transaction " + tx); }
       
@@ -180,7 +180,7 @@
    
    public Transaction createTransaction() throws Exception
    {
-      Transaction tx = new Transaction(idManager.getId());
+      Transaction tx = new Transaction(idManager.getID());
       
       if (trace) { log.trace("created transaction " + tx); }
 

Modified: trunk/tests/bin/runtest
===================================================================
--- trunk/tests/bin/runtest	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/bin/runtest	2006-12-19 05:15:12 UTC (rev 1816)
@@ -117,7 +117,6 @@
     fi
     if [ "$1" = "-clustered" ]; then
         TEST_CLUSTERED=true
-        TEST_LOGFILE_SUFFIX=clustering-client
         shift
         continue;
     else
@@ -126,6 +125,10 @@
     fi
 done
 
+if [ "$TEST_CLUSTERED" = "true" ]; then
+   TEST_LOGFILE_SUFFIX=clustering-client
+fi
+
 JAVA_OPTS="-Xmx1024M $JAVA_OPTS \
 -Dmodule.output=$reldir/../output \
 $REMOTE_TEST \

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -24,7 +24,7 @@
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.SimpleDelivery;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.tx.Transaction;
@@ -117,7 +117,7 @@
                   true, true, true, 100);
       pm.start();
       
-      IdManager idm = new IdManager("TRANSACTION_ID", 10, pm);
+      IDManager idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
       TransactionRepository tr = new TransactionRepository(pm, idm);

Modified: trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -33,7 +33,7 @@
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
 import org.jboss.messaging.core.message.CoreMessage;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
@@ -96,7 +96,7 @@
 
    protected PagingFilteredQueue queue;
    
-   protected IdManager idm;
+   protected IDManager idm;
    
    // Constructors --------------------------------------------------
 
@@ -119,7 +119,7 @@
                                       true, true, true, 100);
       pm.start();
       
-      idm = new IdManager("TRANSACTION_ID", 10, pm);
+      idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
       tr = new TransactionRepository(pm, idm);

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -26,7 +26,6 @@
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
-import org.jboss.messaging.core.plugin.IdManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.LockMap;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -38,7 +38,7 @@
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.SimpleDelivery;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -71,7 +71,7 @@
    protected PersistenceManager pm;
    protected SimpleMessageStore ms;
    protected TransactionRepository tr;
-   protected IdManager idm;
+   protected IDManager idm;
 
    // Constructors --------------------------------------------------
 
@@ -100,7 +100,7 @@
                   true, true, true, 100);     
       pm.start();
       
-      idm = new IdManager("TRANSACTION_ID", 10, pm);
+      idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
       tr = new TransactionRepository(pm, idm);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/IdManagerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/IdManagerTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/IdManagerTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -21,8 +21,8 @@
   */
 package org.jboss.test.messaging.core.plugin;
 
-import org.jboss.messaging.core.plugin.IdBlock;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDBlock;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.test.messaging.MessagingTestCase;
@@ -90,7 +90,7 @@
    
    public void test1() throws Exception
    {
-      IdManager idm = new IdManager("test_counter", 1000, pm);
+      IDManager idm = new IDManager("test_counter", 1000, pm);
       idm.start();
       
       int blockSize = 37;
@@ -99,7 +99,7 @@
       
       for (int i = 0; i < 1000; i++)
       {
-         IdBlock block = idm.getIdBlock(blockSize);
+         IDBlock block = idm.getIDBlock(blockSize);
                    
          assertTrue(block.getLow() >= nextLow);
          
@@ -113,12 +113,12 @@
    
    public void test2() throws Exception
    {
-      IdManager idm = new IdManager("test_counter2", 100, pm);
+      IDManager idm = new IDManager("test_counter2", 100, pm);
       idm.start();
          
       for (int i = 0; i < 1000; i++)
       {
-         long id = idm.getId();
+         long id = idm.getID();
          
          assertEquals(i, id);
       }

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -39,7 +39,7 @@
 import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
@@ -805,7 +805,7 @@
 //      
 //      Channel channel = new SimpleChannel(0, ms);
 //      
-//      TransactionRepository txRep = new TransactionRepository(pm, new IdManager("TRANSACTION_ID", 10, pm));
+//      TransactionRepository txRep = new TransactionRepository(pm, new IDManager("TRANSACTION_ID", 10, pm));
 //      txRep.start();
 //
 //      Message[] messages = createMessages(10);
@@ -1160,7 +1160,7 @@
 
       Channel channel = new SimpleChannel(0, ms);
       
-      IdManager idm = new IdManager("TRANSACTION_ID", 10, pm);
+      IDManager idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
       TransactionRepository txRep = new TransactionRepository(pm, idm);
@@ -1271,7 +1271,7 @@
 
       Channel channel = new SimpleChannel(0, ms);
       
-      IdManager idm = new IdManager("TRANSACTION_ID", 10, pm);
+      IDManager idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
       TransactionRepository txRep = new TransactionRepository(pm, idm);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -36,7 +36,7 @@
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.Queue;
-import org.jboss.messaging.core.plugin.IdManager;
+import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
 import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.Condition;
@@ -76,9 +76,9 @@
 
    protected ServiceContainer sc;
 
-   protected IdManager channelIdManager;   
+   protected IDManager channelIDManager;
    
-   protected IdManager transactionIdManager;   
+   protected IDManager transactionIDManager;
    
    protected PersistenceManager pm;
       
@@ -113,10 +113,10 @@
                   true, true, true, 100);     
       pm.start();
       
-      transactionIdManager = new IdManager("TRANSACTION_ID", 10, pm);
-      transactionIdManager.start();
+      transactionIDManager = new IDManager("TRANSACTION_ID", 10, pm);
+      transactionIDManager.start();
       
-      tr = new TransactionRepository(pm, transactionIdManager);
+      tr = new TransactionRepository(pm, transactionIDManager);
       tr.start();
       
       ms = new SimpleMessageStore();
@@ -124,8 +124,8 @@
       
       pool = new QueuedExecutorPool(10);
       
-      channelIdManager = new IdManager("CHANNEL_ID", 10, pm);
-      channelIdManager.start();
+      channelIDManager = new IDManager("CHANNEL_ID", 10, pm);
+      channelIDManager.start();
       
       conditionFactory = new SimpleConditionFactory();
             
@@ -142,8 +142,8 @@
       pm.stop();
       tr.stop();
       ms.stop();
-      transactionIdManager.stop();
-      channelIdManager.stop();
+      transactionIDManager.stop();
+      channelIDManager.stop();
       
       super.tearDown();
    }

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -99,7 +99,7 @@
          Filter filter1 = new Selector("x = 'cheese'");
          Filter filter2 = new Selector("y = 'bread'");
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("durableQueue", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("durableQueue", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          
          Binding binding1 =
@@ -117,7 +117,7 @@
          }
                
          //Bind one non durable
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("nonDurableQueue", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 = new PagingFilteredQueue("nonDurableQueue", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             office1.bindQueue(new SimpleCondition("condition2"), queue2);
@@ -207,42 +207,42 @@
       {      
          office = createPostOffice();
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
             office.bindQueue(new SimpleCondition("condition1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             office.bindQueue(new SimpleCondition("condition1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding3 =
             office.bindQueue(new SimpleCondition("condition1"), queue3);
          
-         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding4 =
             office.bindQueue(new SimpleCondition("condition1"), queue4);
          
-         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding5 =
             office.bindQueue(new SimpleCondition("condition2"), queue5);
          
-         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding6 =
             office.bindQueue(new SimpleCondition("condition2"), queue6);
          
-         PagingFilteredQueue queue7 = new PagingFilteredQueue("queue7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue7 = new PagingFilteredQueue("queue7", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding7 =
             office.bindQueue(new SimpleCondition("condition2"), queue7);
          
-         PagingFilteredQueue queue8 = new PagingFilteredQueue("queue8", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue8 = new PagingFilteredQueue("queue8", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding8 =
             office.bindQueue(new SimpleCondition("condition2"), queue8);
@@ -333,32 +333,32 @@
       
          postOffice = createPostOffice();
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding3 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
-         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding4 =
             postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
-         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding5 =
             postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
-         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding6 =
             postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
@@ -485,7 +485,7 @@
       {      
          postOffice = createPostOffice();
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
             postOffice.bindQueue(new SimpleCondition("condition1"), queue1);
@@ -537,17 +537,17 @@
          
          SimpleFilter filter = new SimpleFilter(2);
       
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), filter);         
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), filter);
          
          Binding binding1 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding3 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue3);   
@@ -639,32 +639,32 @@
       {      
          postOffice = createPostOffice();
       
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding3 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
-         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          Binding binding4 =
             postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
-         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          Binding binding5 =
             postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
-         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);         
+         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          Binding binding6 =
             postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
@@ -813,12 +813,12 @@
       {      
          postOffice = createPostOffice();
       
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          
          Binding binding1 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             postOffice.bindQueue(new SimpleCondition("topic1"), queue2);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -158,11 +158,11 @@
          
          //Add a couple of bindings
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);        
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "sub1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office1, 1, "sub2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
@@ -180,7 +180,7 @@
          
          //Add another binding on node 2
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "sub3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
 
          Binding binding3 =
             office2.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
@@ -207,7 +207,7 @@
 
          //Add another binding on node 1
          
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office2, 2, "sub4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 =
             office2.bindClusteredQueue(new SimpleCondition("topic1"), queue4);
          
@@ -271,7 +271,7 @@
          
          //Add another binding on node 3
                   
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office3, 3, "sub5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office3, 3, "sub5", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding5 =
             office3.bindClusteredQueue(new SimpleCondition("topic1"), queue5);
@@ -307,12 +307,12 @@
          
          //Add a durable and a non durable binding on node 1
          
-         LocalClusteredQueue queue6 = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue6 = new LocalClusteredQueue(office1, 1, "sub6", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding6 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue6);
          
-         LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "sub7", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding7 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue7);
@@ -598,15 +598,15 @@
          
          office2 = createClusteredPostOffice(2, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
 
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
 
          Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
 
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          try
          {
@@ -617,7 +617,7 @@
          {
             //Ok
          }
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          try
          {
@@ -633,11 +633,11 @@
 
          office1.unbindClusteredQueue("queue1");
 
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          
          Binding binding5 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
          
-         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);       
+         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
          try
          {
             Binding binding6 = office1.bindQueue(new SimpleCondition("queue1"), queue6);
@@ -651,13 +651,13 @@
          office1.unbindClusteredQueue("queue1");
          
          //It should be possible to bind queues locally into a clustered post office
-         LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue7 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding7 = office1.bindQueue(new SimpleCondition("queue1"), queue7);
          
-         LocalClusteredQueue queue8 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);       
+         LocalClusteredQueue queue8 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding8 = office2.bindQueue(new SimpleCondition("queue1"), queue8);
          
-         LocalClusteredQueue queue9 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);       
+         LocalClusteredQueue queue9 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          try
          {
             Binding binding9 = office1.bindQueue(new SimpleCondition("queue1"), queue9);
@@ -701,15 +701,15 @@
          SimpleFilter filter1 = new SimpleFilter(2);
          SimpleFilter filter2 = new SimpleFilter(3);
       
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter1, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter1, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter2, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), filter2, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "queue3", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office2, 2, "queue3", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 =
             office2.bindClusteredQueue(new SimpleCondition("topic1"), queue3);   
          
@@ -810,52 +810,52 @@
          LocalClusteredQueue[] queues = new LocalClusteredQueue[16];
          Binding[] bindings = new Binding[16];
          
-         queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[0] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[0]);
          
-         queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[1] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[1]);
          
-         queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[2] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[2]);
          
-         queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[3] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[3]);
          
-         queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[4] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[4]);
          
-         queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[5] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[5]);
          
-         queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[6] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[6]);
          
-         queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[7] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[7]);
          
-         queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[8] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[8]);
          
-         queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[9] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[9]);
          
-         queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[10] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[10]);
          
-         queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[11] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[11]);
          
-         queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[12] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[12]);
          
-         queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[13] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[13]);
          
-         queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[14] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[14]);
          
-         queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[15] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[15]);
        
          SimpleReceiver[] receivers = new SimpleReceiver[16];
@@ -1000,27 +1000,27 @@
          //We deploy the queue on nodes 1, 2, 3, 4 and 5
          //We don't deploy on node 6
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2); 
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4); 
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
@@ -1153,17 +1153,17 @@
          office2 = createClusteredPostOffice(2, "testgroup");
          office3 = createClusteredPostOffice(3, "testgroup");
 
-         LocalClusteredQueue sub1 = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sub1 = new LocalClusteredQueue(office1, 1, "sub1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office1.bindQueue(new SimpleCondition("topic"), sub1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub1.add(receiver1);
          
-         LocalClusteredQueue sub2 = new LocalClusteredQueue(office2, 2, "sub2", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sub2 = new LocalClusteredQueue(office2, 2, "sub2", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office2.bindQueue(new SimpleCondition("topic"), sub2); 
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub2.add(receiver2);
          
-         LocalClusteredQueue sub3 = new LocalClusteredQueue(office3, 3, "sub3", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sub3 = new LocalClusteredQueue(office3, 3, "sub3", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office3.bindQueue(new SimpleCondition("topic"), sub3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sub3.add(receiver3);
@@ -1270,13 +1270,13 @@
          //======
          
          //Non durable 1 on node 2
-         LocalClusteredQueue nonDurable1 = new LocalClusteredQueue(office2, 2, "nondurable1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable1 = new LocalClusteredQueue(office2, 2, "nondurable1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), nonDurable1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable1.add(receiver1);
          
          //Non durable 2 on node 2
-         LocalClusteredQueue nonDurable2 = new LocalClusteredQueue(office2, 2, "nondurable2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable2 = new LocalClusteredQueue(office2, 2, "nondurable2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("topic"), nonDurable2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable2.add(receiver2);
@@ -1285,13 +1285,13 @@
          //======
          
          //Non shared durable
-         LocalClusteredQueue nonSharedDurable1 = new LocalClusteredQueue(office3, 3, "nonshareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonSharedDurable1 = new LocalClusteredQueue(office3, 3, "nonshareddurable1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("topic"), nonSharedDurable1);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonSharedDurable1.add(receiver3);
          
          //Non durable
-         LocalClusteredQueue nonDurable3 = new LocalClusteredQueue(office3, 3, "nondurable3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable3 = new LocalClusteredQueue(office3, 3, "nondurable3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 = office3.bindClusteredQueue(new SimpleCondition("topic"), nonDurable3);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable3.add(receiver4);
@@ -1300,31 +1300,31 @@
          //======
          
          //Shared durable
-         LocalClusteredQueue sharedDurable1 = new LocalClusteredQueue(office4, 4, "shareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sharedDurable1 = new LocalClusteredQueue(office4, 4, "shareddurable1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding5 = office4.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable1);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable1.add(receiver5);
          
          //Non shared durable
-         LocalClusteredQueue nonSharedDurable2 = new LocalClusteredQueue(office4, 4, "nonshareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonSharedDurable2 = new LocalClusteredQueue(office4, 4, "nonshareddurable2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding6 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonSharedDurable2);
          SimpleReceiver receiver6 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonSharedDurable2.add(receiver6);
          
          //Non durable
-         LocalClusteredQueue nonDurable4 = new LocalClusteredQueue(office4, 4, "nondurable4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable4 = new LocalClusteredQueue(office4, 4, "nondurable4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding7 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable4);
          SimpleReceiver receiver7 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable4.add(receiver7);
          
          // Non durable
-         LocalClusteredQueue nonDurable5 = new LocalClusteredQueue(office4, 4, "nondurable5", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable5 = new LocalClusteredQueue(office4, 4, "nondurable5", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding8 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable5);
          SimpleReceiver receiver8 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable5.add(receiver8);
          
          //Non durable
-         LocalClusteredQueue nonDurable6 = new LocalClusteredQueue(office4, 4, "nondurable6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable6 = new LocalClusteredQueue(office4, 4, "nondurable6", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding9 = office4.bindClusteredQueue(new SimpleCondition("topic"), nonDurable6);
          SimpleReceiver receiver9 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable6.add(receiver9);
@@ -1332,32 +1332,32 @@
          // Node 5
          //=======
          //Shared durable
-         LocalClusteredQueue sharedDurable2 = new LocalClusteredQueue(office5, 5, "shareddurable1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sharedDurable2 = new LocalClusteredQueue(office5, 5, "shareddurable1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding10 = office5.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable2);
          SimpleReceiver receiver10 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable2.add(receiver10);
          
          //Shared durable
-         LocalClusteredQueue sharedDurable3 = new LocalClusteredQueue(office5, 5, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sharedDurable3 = new LocalClusteredQueue(office5, 5, "shareddurable2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding11 = office5.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable3);
          SimpleReceiver receiver11 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable3.add(receiver11);
          
          // Node 6
          //=========
-         LocalClusteredQueue sharedDurable4 = new LocalClusteredQueue(office6, 6, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sharedDurable4 = new LocalClusteredQueue(office6, 6, "shareddurable2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding12 = office6.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable4);
          SimpleReceiver receiver12 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable4.add(receiver12);
          
-         LocalClusteredQueue nonDurable7 = new LocalClusteredQueue(office6, 6, "nondurable7", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue nonDurable7 = new LocalClusteredQueue(office6, 6, "nondurable7", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding13 = office6.bindClusteredQueue(new SimpleCondition("topic"), nonDurable7);
          SimpleReceiver receiver13 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          nonDurable7.add(receiver13);
          
          //Node 7
          //=======
-         LocalClusteredQueue sharedDurable5 = new LocalClusteredQueue(office7, 7, "shareddurable2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
+         LocalClusteredQueue sharedDurable5 = new LocalClusteredQueue(office7, 7, "shareddurable2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding14 = office7.bindClusteredQueue(new SimpleCondition("topic"), sharedDurable5);
          SimpleReceiver receiver14 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          sharedDurable5.add(receiver14);
@@ -1689,52 +1689,52 @@
          LocalClusteredQueue[] queues = new LocalClusteredQueue[16];
          Binding[] bindings = new Binding[16];
          
-         queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[0] = new LocalClusteredQueue(office1, 1, "sub1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[0] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[0]);
          
-         queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[1] = new LocalClusteredQueue(office1, 1, "sub2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[1] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[1]);
          
-         queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[2] = new LocalClusteredQueue(office2, 2, "sub3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[2] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[2]);
          
-         queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[3] = new LocalClusteredQueue(office2, 2, "sub4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[3] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[3]);
          
-         queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[4] = new LocalClusteredQueue(office2, 2, "sub5", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[4] = office2.bindClusteredQueue(new SimpleCondition("topic1"), queues[4]);
          
-         queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[5] = new LocalClusteredQueue(office1, 1, "sub6", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[5] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[5]);
          
-         queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[6] = new LocalClusteredQueue(office1, 1, "sub7", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[6] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[6]);
          
-         queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[7] = new LocalClusteredQueue(office1, 1, "sub8", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[7] = office1.bindClusteredQueue(new SimpleCondition("topic1"), queues[7]);
          
-         queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[8] = new LocalClusteredQueue(office1, 1, "sub9", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[8] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[8]);
          
-         queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[9] = new LocalClusteredQueue(office1, 1, "sub10", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[9] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[9]);
          
-         queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[10] = new LocalClusteredQueue(office2, 2, "sub11", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[10] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[10]);
          
-         queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[11] = new LocalClusteredQueue(office2, 2, "sub12", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[11] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[11]);
          
-         queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[12] = new LocalClusteredQueue(office2, 2, "sub13", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[12] = office2.bindClusteredQueue(new SimpleCondition("topic2"), queues[12]);
          
-         queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         queues[13] = new LocalClusteredQueue(office1, 1, "sub14", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          bindings[13] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[13]);
          
-         queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[14] = new LocalClusteredQueue(office1, 1, "sub15", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[14] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[14]);
          
-         queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         queues[15] = new LocalClusteredQueue(office1, 1, "sub16", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          bindings[15] = office1.bindClusteredQueue(new SimpleCondition("topic2"), queues[15]);
 
          SimpleReceiver[] receivers = new SimpleReceiver[16];

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeWithDefaultRouterTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -128,27 +128,27 @@
          
          office6 = createClusteredPostOffice(6, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office3.bindClusteredQueue(new SimpleCondition("topic"), queue2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office4.bindClusteredQueue(new SimpleCondition("topic"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 = office5.bindClusteredQueue(new SimpleCondition("topic"), queue4);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding5 = office6.bindClusteredQueue(new SimpleCondition("topic"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);
@@ -269,27 +269,27 @@
          
          office6 = createClusteredPostOffice(6, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office2.bindClusteredQueue(new SimpleCondition("topic"), queue1);
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office3, 3, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office3.bindClusteredQueue(new SimpleCondition("topic"), queue2);
          SimpleReceiver receiver2 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue2.add(receiver2);
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office4, 4, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office4.bindClusteredQueue(new SimpleCondition("topic"), queue3);
          SimpleReceiver receiver3 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue3.add(receiver3);
          
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office5, 5, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 = office5.bindClusteredQueue(new SimpleCondition("topic"), queue4);
          SimpleReceiver receiver4 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue4.add(receiver4);
          
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIdManager.getId(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office6, 6, "queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null, tr);
          Binding binding5 = office6.bindClusteredQueue(new SimpleCondition("topic"), queue5);
          SimpleReceiver receiver5 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue5.add(receiver5);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RecoveryTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -101,15 +101,15 @@
          
          office3 = (DefaultClusteredPostOffice)createClusteredPostOffice(3, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 =
             office3.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
          
@@ -236,15 +236,15 @@
          
          office3 = (DefaultClusteredPostOffice)createClusteredPostOffice(3, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("topic1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("topic1"), queue2);
          
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue3", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 =
             office3.bindClusteredQueue(new SimpleCondition("topic1"), queue3);
          

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -144,11 +144,11 @@
          
          office2 = (DefaultClusteredPostOffice)createClusteredPostOffice(2, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
@@ -238,11 +238,11 @@
          
          office2 = (DefaultClusteredPostOffice)createClusteredPostOffice(2, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
@@ -338,11 +338,11 @@
          
          office2 = (DefaultClusteredPostOffice)createClusteredPostOffice(2, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
@@ -434,11 +434,11 @@
          
          office2 = (DefaultClusteredPostOffice)createClusteredPostOffice(2, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 =
             office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
          
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 =
             office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                           
@@ -533,19 +533,19 @@
          
          office5 = (DefaultClusteredPostOffice)createClusteredPostOffice(5, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
                   
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                   
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);         
          
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
                   
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
                    
          final int NUM_MESSAGES = 100;
@@ -693,19 +693,19 @@
          
          office5 = (DefaultClusteredPostOffice)createClusteredPostOffice(5, "testgroup");
          
-         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue1 = new LocalClusteredQueue(office1, 1, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding1 = office1.bindClusteredQueue(new SimpleCondition("queue1"), queue1);
                   
-         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue2 = new LocalClusteredQueue(office2, 2, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding2 = office2.bindClusteredQueue(new SimpleCondition("queue1"), queue2);
                   
-         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue3 = new LocalClusteredQueue(office3, 3, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding3 = office3.bindClusteredQueue(new SimpleCondition("queue1"), queue3);         
          
-         LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue4 = new LocalClusteredQueue(office4, 4, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding4 = office4.bindClusteredQueue(new SimpleCondition("queue1"), queue4);
                   
-         LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIdManager.getId(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);         
+         LocalClusteredQueue queue5 = new LocalClusteredQueue(office5, 5, "queue1", channelIDManager.getID(), ms, pm, true, recoverable, (QueuedExecutor)pool.get(), null, tr);
          Binding binding5 = office5.bindClusteredQueue(new SimpleCondition("queue1"), queue5);
                   
          final int NUM_MESSAGES = 100;

Modified: trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -56,7 +56,7 @@
 import org.jboss.jms.tx.TransactionRequest;
 import org.jboss.jms.tx.ClientTransaction.SessionTxState;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.IdBlock;
+import org.jboss.messaging.core.plugin.IDBlock;
 import org.jboss.remoting.InvocationRequest;
 import org.jboss.remoting.InvocationResponse;
 import org.jboss.remoting.InvokerLocator;
@@ -1363,7 +1363,7 @@
                   
       public void testGetIdBlockResponse() throws Exception
       {
-         IdBlock block = new IdBlock(132, 465);
+         IDBlock block = new IDBlock(132, 465);
          
          MessagingMarshallable mm = new MessagingMarshallable((byte)77, block);
                   
@@ -1388,7 +1388,7 @@
          
          assertEquals(JMSWireFormat.ID_BLOCK_RESPONSE, b);
          
-         IdBlock block2 = new IdBlock();
+         IDBlock block2 = new IDBlock();
          
          block2.read(dis);
          
@@ -1416,7 +1416,7 @@
          
          assertEquals(77, mm.getVersion());
          
-         IdBlock block3 = (IdBlock)mm.getLoad();
+         IDBlock block3 = (IDBlock)mm.getLoad();
          
          assertEquals(block.getLow(), block3.getLow());
          assertEquals(block.getHigh(), block3.getHigh());                  

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java	2006-12-18 22:59:52 UTC (rev 1815)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedDestinationsTest.java	2006-12-19 05:15:12 UTC (rev 1816)
@@ -546,150 +546,141 @@
       }
    }
 
-
-
-   /*
-    * Create durable subscriptions on all nodes of the cluster.
-    * Include a couple with selectors
-    * Ensure all messages are receive as appropriate
-    * None of the durable subs are shared
+   /**
+    * Create durable subscriptions on all nodes of the cluster. Include a couple with selectors.
+    * Ensure all messages are receive as appropriate. None of the durable subs are shared.
     */
    private void clusteredTopicDurable(boolean persistent) throws Exception
    {
+      Connection conn0 = null;
       Connection conn1 = null;
       Connection conn2 = null;
-      Connection conn3 = null;
+
       try
       {
-         //This will create 3 different connection on 3 different nodes, since
-         //the cf is clustered
+         // This will create 3 different connection on 3 different nodes, since the cf is clustered
+         conn0 = cf.createConnection();
          conn1 = cf.createConnection();
          conn2 = cf.createConnection();
-         conn3 = cf.createConnection();
          
          log.info("Created connections");
          
-         checkConnectionsDifferentServers(new Connection[] {conn1, conn2, conn3});
+         checkConnectionsDifferentServers(new Connection[] {conn0, conn1, conn2});
 
+         conn0.setClientID("wib1");
          conn1.setClientID("wib1");
          conn2.setClientID("wib1");
-         conn3.setClientID("wib1");
 
+         Session sess0 = conn0.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
          Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         Session sess3 = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
          try
          {
-            sess1.unsubscribe("sub");
+            sess0.unsubscribe("alpha");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub1");
+            sess1.unsubscribe("beta");
          }
          catch (Exception ignore) {}
          try
          {
-            sess3.unsubscribe("sub2");
+            sess2.unsubscribe("gamma");
          }
          catch (Exception ignore) {}
          try
          {
-            sess1.unsubscribe("sub3");
+            sess0.unsubscribe("delta");
          }
          catch (Exception ignore) {}
          try
          {
-            sess2.unsubscribe("sub4");
+            sess1.unsubscribe("epsilon");
          }
          catch (Exception ignore) {}
 
-         MessageConsumer cons1 = sess1.createDurableSubscriber(topic[0], "sub");
-         MessageConsumer cons2 = sess2.createDurableSubscriber(topic[1], "sub1");
-         MessageConsumer cons3 = sess3.createDurableSubscriber(topic[2], "sub2");
-         MessageConsumer cons4 = sess1.createDurableSubscriber(topic[0], "sub3");
-         MessageConsumer cons5 = sess2.createDurableSubscriber(topic[1], "sub4");
+         MessageConsumer alpha = sess0.createDurableSubscriber(topic[0], "alpha");
+         MessageConsumer beta = sess1.createDurableSubscriber(topic[1], "beta");
+         MessageConsumer gamma = sess2.createDurableSubscriber(topic[2], "gamma");
+         MessageConsumer delta = sess0.createDurableSubscriber(topic[0], "delta");
+         MessageConsumer epsilon = sess1.createDurableSubscriber(topic[1], "epsilon");
 
+         conn0.start();
          conn1.start();
          conn2.start();
-         conn3.start();
 
          // Send at node 0
 
-         MessageProducer prod = sess1.createProducer(topic[0]);
+         MessageProducer prod = sess0.createProducer(topic[0]);
 
          prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
 
-         final int NUM_MESSAGES = 100;
+         final int NUM_MESSAGES = 1;
 
+         log.info("sending messages");
+
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = sess2.createTextMessage("message" + i);
-
-            prod.send(tm);
+            prod.send(sess0.createTextMessage("message" + i));
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons1.receive(1000);
-
+            TextMessage tm = (TextMessage)alpha.receive(1000);
             assertNotNull(tm);
-
             assertEquals("message" + i, tm.getText());
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons2.receive(1000);
-
+            TextMessage tm = (TextMessage)beta.receive(1000);
             assertNotNull(tm);
-
             assertEquals("message" + i, tm.getText());
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons3.receive(1000);
-
+            TextMessage tm = (TextMessage)gamma.receive(1000);
             assertNotNull(tm);
-
             assertEquals("message" + i, tm.getText());
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons4.receive(1000);
-
+            TextMessage tm = (TextMessage)delta.receive(1000);
             assertNotNull(tm);
-
             assertEquals("message" + i, tm.getText());
          }
 
          for (int i = 0; i < NUM_MESSAGES; i++)
          {
-            TextMessage tm = (TextMessage)cons5.receive(1000);
-
+            TextMessage tm = (TextMessage)epsilon.receive(1000);
             assertNotNull(tm);
-
             assertEquals("message" + i, tm.getText());
          }
 
-         cons1.close();
-         cons2.close();
-         cons3.close();
-         cons4.close();
-         cons5.close();
+         alpha.close();
+         beta.close();
+         gamma.close();
+         delta.close();
+         epsilon.close();
 
-         sess1.unsubscribe("sub");
-         sess2.unsubscribe("sub1");
-         sess3.unsubscribe("sub2");
-         sess1.unsubscribe("sub3");
-         sess2.unsubscribe("sub4");
+         sess0.unsubscribe("alpha");
+         sess1.unsubscribe("beta");
+         sess2.unsubscribe("gamma");
+         sess0.unsubscribe("delta");
+         sess1.unsubscribe("epsilon");
 
       }
       finally
       {
+         if (conn0 != null)
+         {
+            conn0.close();
+         }
+
          if (conn1 != null)
          {
             conn1.close();
@@ -699,11 +690,6 @@
          {
             conn2.close();
          }
-
-         if (conn3 != null)
-         {
-            conn3.close();
-         }
       }
    }
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 00:41:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 00:41:21 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1817 - in trunk:
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering/base
	tests/src/org/jboss/test/messaging/jms/crash
	tests/src/org/jboss/test/messaging/tools
	tests/src/org/jboss/test/messaging/tools/jmx
	tests/src/org/jboss/test/messaging/tools/jmx/rmi
Message-ID: <E1GwXj7-0002NC-9O@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-19 00:41:14 -0500 (Tue, 19 Dec 2006)
New Revision: 1817

Modified:
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
Fixed DistributedDestinationsTest.testClusteredTopicDurablePersistent() 
The test was failing because all nodes in the cluster cleared the database,
while they also relied on shared counter values that shouldn't have been cleaned.
Fixed by allowing only the first node to clean the database.


Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/SendTransactionRequest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -169,12 +169,19 @@
    public String toString()
    {
       StringBuffer sb = new StringBuffer("SendTransactionRequest[");
-      for(Iterator i = messageHolders.iterator(); i.hasNext(); )
+      if (messageHolders == null)
       {
-         sb.append(((MessageHolder)i.next()).getMessage());
-         if (i.hasNext())
+         sb.append("EMPTY");
+      }
+      else
+      {
+         for(Iterator i = messageHolders.iterator(); i.hasNext(); )
          {
-            sb.append(',');
+            sb.append(((MessageHolder)i.next()).getMessage());
+            if (i.hasNext())
+            {
+               sb.append(',');
+            }
          }
       }
       sb.append("]");

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -91,8 +91,10 @@
 
       for(int i = 0; i < nodeCount; i++)
       {
-         // make sure all servers are created and started
-         ServerManagement.start(i, "all");
+         // make sure all servers are created and started; make sure that database is zapped
+         // ONLY for the first server, the others rely on values they expect to find in shared
+         // tables; don't clear the database for those.
+         ServerManagement.start(i, "all", i == 0);
 
          ServerManagement.deployClusteredQueue("testDistributedQueue", i);
          ServerManagement.deployClusteredTopic("testDistributedTopic", i);

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/CallbackFailureTest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       //Start all the services locally
-      localServer.start("all");
+      localServer.start("all", true);
             
       localServer.deployQueue("Queue", null, false);
            

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashLargeLeaseTest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all");
+      localServer.start("all", true);
 
       localServer.setAttribute(ServiceContainer.REMOTING_OBJECT_NAME, "LeasePeriod", "30000");
        

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashNegativeLeaseTest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all");
+      localServer.start("all", true);
 
       //Set lease period to -1 --> this should disable leasing so the state won't be cleared up
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all");
+      localServer.start("all", true);
 
       // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
       // the default, whatever that is ...

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashTwoConnectionsTest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -75,7 +75,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all");
+      localServer.start("all", true);
 
       // This crash test is relying on a precise value of LeaseInterval, so we don't rely on
       // the default, whatever that is ...

Modified: trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/jms/crash/ClientCrashZeroLeaseTest.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -73,7 +73,7 @@
       localServer = new LocalTestServer();
       
       // Start all the services locally
-      localServer.start("all");
+      localServer.start("all", true);
 
       //Set lease period to 0 --> this should disable leasing so the state won't be cleared up
       

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -160,16 +160,29 @@
    }
 
 
+   /**
+    * Will clear the database at startup.
+    */
    public static synchronized void start(String config) throws Exception
    {
-      start(0, config);
+      start(0, config, true);
    }
 
    /**
+    * Will clear the database at startup.
+    */
+   public static synchronized void start(int i, String config) throws Exception
+   {
+      start(i, config, true);
+   }
+
+
+   /**
     * When this method correctly completes, the server (local or remote) is started and fully
     * operational (the service container and the server peer are created and started)
     */
-   public static synchronized void start(int i, String config) throws Exception
+   public static synchronized void start(int i, String config, boolean clearDatabase)
+      throws Exception
    {
       Server s = create(i);
 
@@ -177,7 +190,7 @@
 
       log.info("starting server " + i);
 
-      s.start(config);
+      s.start(config, clearDatabase);
 
       log.info("server " + i + " started");
    }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -288,8 +288,18 @@
 
    // Public --------------------------------------------------------
 
+
+   /**
+    * By default, starting the container DELETES ALL DATA previously existing in the database.
+    */
    public void start() throws Exception
    {
+      start(true);
+   }
+
+
+   public void start(boolean cleanDatabase) throws Exception
+   {
       try
       {
          readConfigurationFile();
@@ -380,20 +390,12 @@
             startSecurityManager();
          }
 
-         if (database && transaction && jca)
+         if (database && transaction && jca && cleanDatabase)
          {
             // We make sure the database is clean (only if we have all dependencies the database,
             // othewise we'll get an access error)
             deleteAllData();
          }
-         else
-         {
-            if (database)
-            {
-               log.warn("Previous data has not been cleared, there may be " + "" +
-                        "garbage lying around in the database!");
-            }
-         }
 
          loadJNDIContexts();
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -61,7 +61,7 @@
 
    private static final Logger log = Logger.getLogger(LocalTestServer.class);
 
-   // Static --------------------------------------------------------
+   // Static --------------------------------------------------------    4
 
    public static void setEnvironmentServerIndex(int serverIndex)
    {
@@ -113,7 +113,7 @@
       return serverIndex;
    }
 
-   public synchronized void start(String containerConfig) throws Exception
+   public synchronized void start(String containerConfig, boolean clearDatabase) throws Exception
    {
       if (isStarted())
       {
@@ -127,7 +127,7 @@
          setEnvironmentServerIndex(serverIndex);
 
          sc = new ServiceContainer(containerConfig, null, serverIndex);
-         sc.start();
+         sc.start(clearDatabase);
 
          if (this.getDatabaseType().equals("hsqldb") && sc.isClustered())
          {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -139,9 +139,9 @@
       return server.getServerID();
    }
 
-   public void start(String containerConfig) throws Exception
+   public void start(String containerConfig, boolean clearDatabase) throws Exception
    {
-      server.start(containerConfig);
+      server.start(containerConfig, clearDatabase);
    }
 
    public boolean stop() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-19 05:15:12 UTC (rev 1816)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-19 05:41:14 UTC (rev 1817)
@@ -47,7 +47,7 @@
 {
    int getServerID() throws Exception;
 
-   void start(String containerConfig) throws Exception;
+   void start(String containerConfig, boolean clearDatabase) throws Exception;
 
    /**
     * @return true if the server was stopped indeed, or false if the server was stopped already



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 00:47:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 00:47:55 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1818 -
	trunk/src/main/org/jboss/messaging/core/plugin
Message-ID: <E1GwXpT-0002U4-QR@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-19 00:47:54 -0500 (Tue, 19 Dec 2006)
New Revision: 1818

Added:
   trunk/src/main/org/jboss/messaging/core/plugin/IDBlock.java
   trunk/src/main/org/jboss/messaging/core/plugin/IDManager.java
Removed:
   trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java
   trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java
Log:
added refactored classes to SVN

Added: trunk/src/main/org/jboss/messaging/core/plugin/IDBlock.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IDBlock.java	2006-12-19 05:41:14 UTC (rev 1817)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IDBlock.java	2006-12-19 05:47:54 UTC (rev 1818)
@@ -0,0 +1,80 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.messaging.core.plugin;
+
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+
+import org.jboss.messaging.util.Streamable;
+
+/**
+ * 
+ * A IDBlock.
+ * 
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @version 1.1
+ *
+ * IDBlock.java,v 1.1 2006/03/07 17:11:15 timfox Exp
+ */
+public class IDBlock implements Streamable
+{
+   private long low;
+   private long high;
+   
+   public IDBlock()
+   {      
+   }
+   
+   public IDBlock(long low, long high)
+   {
+      this.low = low;
+      this.high = high;
+   }
+   
+   public long getLow()
+   {
+      return low;
+   }
+   
+   public long getHigh()
+   {
+      return high;
+   }
+
+   public void read(DataInputStream in) throws Exception
+   {
+      low = in.readLong();
+      high = in.readLong();
+   }
+
+   public void write(DataOutputStream out) throws Exception
+   {
+      out.writeLong(low);
+      out.writeLong(high);
+   }
+
+   public String toString()
+   {
+      return "IDBlock[" + low + "-" + high + "]";
+   }
+
+}

Added: trunk/src/main/org/jboss/messaging/core/plugin/IDManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IDManager.java	2006-12-19 05:41:14 UTC (rev 1817)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IDManager.java	2006-12-19 05:47:54 UTC (rev 1818)
@@ -0,0 +1,138 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.messaging.core.plugin;
+
+import org.jboss.logging.Logger;
+import org.jboss.messaging.core.plugin.contract.MessagingComponent;
+import org.jboss.messaging.core.plugin.contract.PersistenceManager;
+
+/**
+ * 
+ * A IDManager.
+ * 
+ * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version 1.1
+ *
+ * IDManager.java,v 1.1 2006/03/07 17:11:15 timfox Exp
+ */
+public class IDManager implements MessagingComponent
+{
+   // Constants -----------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(IDManager.class);
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private boolean trace = log.isTraceEnabled();
+
+   private boolean started;
+
+   private String counterName;
+
+   private int bigBlockSize;
+   private long high;
+   private long low;
+
+   private PersistenceManager pm;
+
+   // Constructors --------------------------------------------------
+
+   public IDManager(String counterName, int bigBlockSize, PersistenceManager pm) throws Exception
+   {
+      this.counterName = counterName;
+      this.bigBlockSize = bigBlockSize;
+      this.pm = pm;
+   }
+
+   // MessagingComponent implementation -----------------------------
+
+   public synchronized void start() throws Exception
+   {
+      getNextBigBlock();
+      started = true;
+   }
+
+   public synchronized void stop() throws Exception
+   {
+      started = false;
+   }
+
+   // Public --------------------------------------------------------
+
+   protected void getNextBigBlock() throws Exception
+   {
+      low = pm.reserveIDBlock(counterName, bigBlockSize);
+      high = low + bigBlockSize - 1;
+      if (trace) { log.trace(this + " retrieved next block of size " + bigBlockSize + " from PersistenceManager, starting at " + low); }
+   }
+
+   public synchronized IDBlock getIDBlock(int size) throws Exception
+   {
+      if (!started)
+      {
+         throw new IllegalStateException(this + " is not started");
+      }
+
+      if (size <= 0)
+      {
+         throw new IllegalArgumentException("block size must be > 0");
+      }
+
+      if (size > bigBlockSize)
+      {
+         throw new IllegalArgumentException("block size must be <= bigBlockSize");
+      }
+
+      if (size > high - low + 1)
+      {
+         getNextBigBlock();
+      }
+
+      long low = this.low;
+
+      this.low += size;
+
+      return new IDBlock(low, this.low - 1);
+   }
+
+   public synchronized long getID() throws Exception
+   {
+      return getIDBlock(1).getLow();
+   }
+
+   public String toString()
+   {
+      return "IDManager[" + counterName + ", " + low + "-" + high + "]";
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Deleted: trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java	2006-12-19 05:41:14 UTC (rev 1817)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IdBlock.java	2006-12-19 05:47:54 UTC (rev 1818)
@@ -1,80 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.messaging.core.plugin;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-
-import org.jboss.messaging.util.Streamable;
-
-/**
- * 
- * A IDBlock.
- * 
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- * @version 1.1
- *
- * IDBlock.java,v 1.1 2006/03/07 17:11:15 timfox Exp
- */
-public class IDBlock implements Streamable
-{
-   private long low;
-   private long high;
-   
-   public IDBlock()
-   {      
-   }
-   
-   public IDBlock(long low, long high)
-   {
-      this.low = low;
-      this.high = high;
-   }
-   
-   public long getLow()
-   {
-      return low;
-   }
-   
-   public long getHigh()
-   {
-      return high;
-   }
-
-   public void read(DataInputStream in) throws Exception
-   {
-      low = in.readLong();
-      high = in.readLong();
-   }
-
-   public void write(DataOutputStream out) throws Exception
-   {
-      out.writeLong(low);
-      out.writeLong(high);
-   }
-
-   public String toString()
-   {
-      return "IDBlock[" + low + "-" + high + "]";
-   }
-
-}

Deleted: trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java	2006-12-19 05:41:14 UTC (rev 1817)
+++ trunk/src/main/org/jboss/messaging/core/plugin/IdManager.java	2006-12-19 05:47:54 UTC (rev 1818)
@@ -1,138 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.messaging.core.plugin;
-
-import org.jboss.logging.Logger;
-import org.jboss.messaging.core.plugin.contract.MessagingComponent;
-import org.jboss.messaging.core.plugin.contract.PersistenceManager;
-
-/**
- * 
- * A IDManager.
- * 
- * @author <a href="tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
- * @version 1.1
- *
- * IDManager.java,v 1.1 2006/03/07 17:11:15 timfox Exp
- */
-public class IDManager implements MessagingComponent
-{
-   // Constants -----------------------------------------------------
-
-   private static final Logger log = Logger.getLogger(IDManager.class);
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private boolean trace = log.isTraceEnabled();
-
-   private boolean started;
-
-   private String counterName;
-
-   private int bigBlockSize;
-   private long high;
-   private long low;
-
-   private PersistenceManager pm;
-
-   // Constructors --------------------------------------------------
-
-   public IDManager(String counterName, int bigBlockSize, PersistenceManager pm) throws Exception
-   {
-      this.counterName = counterName;
-      this.bigBlockSize = bigBlockSize;
-      this.pm = pm;
-   }
-
-   // MessagingComponent implementation -----------------------------
-
-   public synchronized void start() throws Exception
-   {
-      getNextBigBlock();
-      started = true;
-   }
-
-   public synchronized void stop() throws Exception
-   {
-      started = false;
-   }
-
-   // Public --------------------------------------------------------
-
-   protected void getNextBigBlock() throws Exception
-   {
-      low = pm.reserveIDBlock(counterName, bigBlockSize);
-      high = low + bigBlockSize - 1;
-      if (trace) { log.trace(this + " retrieved next block of size " + bigBlockSize + " from PersistenceManager, starting at " + low); }
-   }
-
-   public synchronized IDBlock getIDBlock(int size) throws Exception
-   {
-      if (!started)
-      {
-         throw new IllegalStateException(this + " is not started");
-      }
-
-      if (size <= 0)
-      {
-         throw new IllegalArgumentException("block size must be > 0");
-      }
-
-      if (size > bigBlockSize)
-      {
-         throw new IllegalArgumentException("block size must be <= bigBlockSize");
-      }
-
-      if (size > high - low + 1)
-      {
-         getNextBigBlock();
-      }
-
-      long low = this.low;
-
-      this.low += size;
-
-      return new IDBlock(low, this.low - 1);
-   }
-
-   public synchronized long getID() throws Exception
-   {
-      return getIDBlock(1).getLow();
-   }
-
-   public String toString()
-   {
-      return "IDManager[" + counterName + ", " + low + "-" + high + "]";
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 00:54:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 00:54:20 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1819 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GwXvg-0002Zc-Pq@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-19 00:54:19 -0500 (Tue, 19 Dec 2006)
New Revision: 1819

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
reduced HAAspect's INFO verbosity a bit

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 05:47:54 UTC (rev 1818)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 05:54:19 UTC (rev 1819)
@@ -59,8 +59,6 @@
 import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
-import org.jboss.remoting.Client;
-import org.jboss.remoting.ConnectionListener;
 
 /**
  *
@@ -225,22 +223,6 @@
       }
    }
 
-   // Debug information about interceptors
-   protected void printInterceptors(Interceptor interceptors[])
-    {
-       if (interceptors==null || interceptors.length==0)
-       {
-          log.info("Interceptor chain is empty");
-       }
-       else
-       {
-          for (int i=0; i<interceptors.length; i++)
-          {
-             log.info("Interceptor[" + i + "] = " + interceptors[i].getName() + " className= " + interceptors[i].getClass().getName());
-          }
-       }
-    }
-   
    /** The valve aspect needs to stay after ExceptionInterceptor, and before DelegateSupport.
     *  This method will place the aspect on the proper place */
    protected void installValveAspect(DelegateSupport delegate, Interceptor interceptor)
@@ -248,10 +230,8 @@
       Advised advised = (Advised)delegate;
       Interceptor interceptors[] = advised._getInstanceAdvisor().getInterceptors();
 
-      log.info("Installing interceptors");
-      printInterceptors(interceptors);
+      //printInterceptors(interceptors);
 
-
       Interceptor delegateInterceptorFound = null;
 
       for (int i=0;i<interceptors.length;i++)
@@ -275,8 +255,7 @@
          advised._getInstanceAdvisor().appendInterceptor(delegateInterceptorFound);
       }
 
-      log.info("Interceptors after installation:");
-      printInterceptors(advised._getInstanceAdvisor().getInterceptors());
+      //printInterceptors(advised._getInstanceAdvisor().getInterceptors());
 
    }
    
@@ -684,6 +663,22 @@
 
    }
 
+   // Debug information about interceptors
+   private void printInterceptors(Interceptor interceptors[])
+    {
+       if (interceptors==null || interceptors.length==0)
+       {
+          log.info("Interceptor chain is empty");
+       }
+       else
+       {
+          for (int i=0; i<interceptors.length; i++)
+          {
+             log.info("Interceptor[" + i + "] = " + interceptors[i].getName() + " className= " + interceptors[i].getClass().getName());
+          }
+       }
+    }
+
 }
 
 



From ron_sigal at yahoo.com  Tue Dec 19 00:58:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 00:58:57 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1GwY08-0002do-Vl@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 00:58:56

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        AbstractInvoker.java
  Log:
  JBREM-622:  Added javadoc change for addClientLocator().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.12.4.5  +2 -2      JBossRemoting/src/main/org/jboss/remoting/AbstractInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/AbstractInvoker.java,v
  retrieving revision 1.12.4.4
  retrieving revision 1.12.4.5
  diff -u -b -r1.12.4.4 -r1.12.4.5
  --- AbstractInvoker.java	7 Dec 2006 03:20:16 -0000	1.12.4.4
  +++ AbstractInvoker.java	19 Dec 2006 05:58:56 -0000	1.12.4.5
  @@ -47,7 +47,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.12.4.4 $
  + * @version $Revision: 1.12.4.5 $
    */
   public abstract class AbstractInvoker implements Invoker
   {
  @@ -113,7 +113,7 @@
   
      /**
       * Generates a listener id for the callbackhandler and callback server locator combination
  -    *
  +    * @param sessionId
       * @param locator
       */
      public String addClientLocator(String sessionId, InvokerCallbackHandler callbackhandler, InvokerLocator locator)
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:00:28 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1GwY1c-0002gH-KX@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:00:28

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        ServerInvoker.java
  Log:
  JBREM-650:  Made started variable protected.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.52.2.6  +2 -2      JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java,v
  retrieving revision 1.52.2.5
  retrieving revision 1.52.2.6
  diff -u -b -r1.52.2.5 -r1.52.2.6
  --- ServerInvoker.java	14 Dec 2006 01:00:09 -0000	1.52.2.5
  +++ ServerInvoker.java	19 Dec 2006 06:00:28 -0000	1.52.2.6
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.52.2.5 $
  + * @version $Revision: 1.52.2.6 $
    */
   public abstract class ServerInvoker extends AbstractInvoker implements ServerInvokerMBean
   {
  @@ -162,7 +162,7 @@
      protected Map handlers = new HashMap();
      protected Map callbackHandlers = new HashMap();
      protected Map clientCallbackListener = new HashMap();
  -   private boolean started = false;
  +   protected boolean started = false;
      private boolean created = false;
   
      private MBeanServer mbeanServer = null;
  
  
  


From forge-admin at jboss.com  Tue Dec 19 01:00:32 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Tue, 19 Dec 2006 01:00:32 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GwY1g-0002gK-D4@committer01.frg.pub.inap.atl.jboss.com>

Commit from gavin (2006-12-18 06:52 EST)
-----------------

JBSEAM-610,   JBSEAM-536, refactor

  jboss-seam  src/main/org/jboss/seam/core/LocaleSelector.java    1.17
  jboss-seam  src/main/org/jboss/seam/core/Manager.java           1.129
+ jboss-seam  src/main/org/jboss/seam/core/Selector.java          1.1
  jboss-seam  src/main/org/jboss/seam/core/TimeZoneSelector.java  1.7
  jboss-seam  src/main/org/jboss/seam/theme/ThemeSelector.java    1.10


Commit from msurtani (2006-12-18 07:27 EST)
--------------------

refactored

  JBossCache  build.xml                                                    1.154
  JBossCache  tests/functional/org/jboss/cache/marshall/SyncReplTest.java  1.13


Commit from msurtani (2006-12-18 07:51 EST)
--------------------

Reinstated InactiveRegionAwareRpcDispatcher

  JBossCache  src/org/jboss/cache/TreeCache.java  1.294


Commit from msurtani (2006-12-18 07:54 EST)
--------------------

refactored

  JBossCache  tests/functional/org/jboss/cache/lock/LockReleaseTest.java  1.5
  JBossCache  tests/functional/org/jboss/cache/lock/UpgradeLockTest.java  1.5


Commit from aloubyansky (2006-12-18 08:03 EST)
-----------------------

latest fixes

  repository.jboss.com  jboss/jbossxb/snapshot/lib/jboss-xml-binding.jar  1.28


Commit from dimitris (2006-12-18 08:04 EST)
--------------------

mark compatible with jboss remoting 1.4.4 / 1.4.5

  repository.jboss.com  jboss/jbossws14/1.0.4.GA/component-info.xml  1.4
  repository.jboss.com  jboss/jbossws/1.0.4.GA/component-info.xml    1.3


Commit from dimitris (2006-12-18 08:21 EST)
--------------------

mark compatible with jboss serialization 1.0.x

  repository.jboss.com  jboss/remoting/1.4.5.GA/component-info.xml  1.2
  repository.jboss.com  jboss/remoting/1.4.4.GA/component-info.xml  1.3


Commit from dimitris (2006-12-18 09:11 EST)
--------------------

add apache commons-logging-api 1.1

+ repository.jboss.com  apache-logging-api/1.1/component-info.xml           1.1
+ repository.jboss.com  apache-logging-api/1.1/lib/commons-logging-api.jar  1.1


Commit from dimitris (2006-12-18 09:15 EST)
--------------------

add apache commons-logging 1.1

+ repository.jboss.com  apache-logging/1.1/component-info.xml       1.1
+ repository.jboss.com  apache-logging/1.1/lib/commons-logging.jar  1.1


Commit from vralev (2006-12-18 10:10 EST)
------------------

This is a temporary manually built EJB3 CR9 PATCH1 version for use in the installer.

+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources/ejb3-clustered-sfsbcache-service.xml  1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources/ejb3-interceptors-aop.xml             1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/resources/ejb3-entity-cache-service.xml         1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/component-info.xml                              1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/bin/ejb3.deployer                               1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib/hibernate-client.jar                        1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-jboss4.0.5-patch1-VR/lib/jboss-ejb3-client.jar                       1.1


Commit from dimitris (2006-12-18 10:35 EST)
--------------------

mark compatible with apache commons-logging 1.1

  repository.jboss.com  apache-tomcat/5.5.20/component-info.xml  1.2


Commit from jmazzitelli (2006-12-18 10:38 EST)
-----------------------

new version that directly supports log4j

+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.jar       1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.jar.md5   1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.jar.sha1  1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.pom       1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.pom.md5   1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.7/i18nlog-1.0.7.pom.sha1  1.1


Commit from gavin (2006-12-18 10:38 EST)
-----------------

new validation component,
reworked navigation rules

  jboss-seam  src/main/META-INF/components.xml                                   1.9
  jboss-seam  src/main/org/jboss/seam/Component.java                             1.223
  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd                              1.11
  jboss-seam  src/main/org/jboss/seam/actionparam/ActionParamMethodBinding.java  1.4
  jboss-seam  src/main/org/jboss/seam/actionparam/MethodExpressionParser.java    1.3
  jboss-seam  src/main/org/jboss/seam/core/Manager.java                          1.130
  jboss-seam  src/main/org/jboss/seam/core/Pageflow.java                         1.48
  jboss-seam  src/main/org/jboss/seam/core/Pages.java                            1.68
  jboss-seam  src/main/org/jboss/seam/core/Validation.java                       1.6
+ jboss-seam  src/main/org/jboss/seam/core/Validators.java                       1.1
  jboss-seam  src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java         1.33
  jboss-seam  src/main/org/jboss/seam/mock/SeamTest.java                         1.59
  jboss-seam  src/main/org/jboss/seam/pages/ActionNavigation.java                1.2
  jboss-seam  src/main/org/jboss/seam/pages/Outcome.java                         1.2
  jboss-seam  src/ui/META-INF/faces-config.xml                                   1.27
  jboss-seam  src/ui/META-INF/seam.taglib.xml                                    1.23
  jboss-seam  src/ui/org/jboss/seam/ui/ModelValidator.java                       1.5


Commit from gavin (2006-12-18 10:42 EST)
-----------------

update

  jboss-seam  examples/booking/resources/WEB-INF/pages.xml  1.10


Commit from gavin (2006-12-18 11:50 EST)
-----------------

transparent navigation

  jboss-seam  examples/blog/resources/WEB-INF/pages.xml   1.6
  jboss-seam  examples/blog/src/actions/LoginAction.java  1.6
  jboss-seam  examples/blog/src/actions/PostAction.java   1.9
  jboss-seam  examples/blog/view/login.xhtml              1.3
  jboss-seam  examples/blog/view/post.xhtml               1.10


Commit from gavin (2006-12-18 11:50 EST)
-----------------

multiple actions per page, and conditional page actions

  jboss-seam  src/main/org/jboss/seam/core/Pages.java           1.69
+ jboss-seam  src/main/org/jboss/seam/pages/Action.java         1.1
  jboss-seam  src/main/org/jboss/seam/pages/Page.java           1.2
- jboss-seam  src/ui/org/jboss/seam/ui/UIForceModelUpdate.java  1.2
- jboss-seam  src/ui/org/jboss/seam/ui/UIValidationFailed.java  1.3


Commit from gavin (2006-12-18 12:55 EST)
-----------------

minor

  jboss-seam  examples/booking/resources/WEB-INF/pages.xml  1.11


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-18 15:09 EST)
---------------------------------------------------------

Use JG 2.2.7 in the interoptests

  JBossCache  build.xml  1.119.2.19


Commit from gavin (2006-12-18 15:23 EST)
-----------------

javadoc

  jboss-seam  src/main/org/jboss/seam/core/BusinessProcess.java                     1.16
  jboss-seam  src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java  1.48


Commit from kkhan (2006-12-18 17:18 EST)
-----------------

Update snapshot in repository

  repository.jboss.com  jboss/aop/snapshot/lib/jboss-aop-jdk50-client.jar            1.12
  repository.jboss.com  jboss/aop/snapshot/lib/jboss-aop-jdk50.jar                   1.18
  repository.jboss.com  jboss/aop/snapshot/lib/jrockit-pluggable-instrumentor.jar    1.9
  repository.jboss.com  jboss/aop/snapshot/lib/pluggable-instrumentor.jar            1.10
  repository.jboss.com  jboss/aop14/snapshot/lib/jboss-aop.jar                       1.14
  repository.jboss.com  jboss/aop14/snapshot/lib/jdk14-pluggable-instrumentor.jar    1.11
  repository.jboss.com  jboss/aop14/snapshot/lib/jrockit-pluggable-instrumentor.jar  1.9


Commit from gavin (2006-12-18 17:48 EST)
-----------------

write out the client id

  jboss-seam  src/ui/org/jboss/seam/ui/HtmlButton.java         1.5
  jboss-seam  src/ui/org/jboss/seam/ui/HtmlLink.java           1.25
  jboss-seam  src/ui/org/jboss/seam/ui/UIStyleDecoration.java  1.4


Commit from starksm (2006-12-18 18:21 EST)
-------------------

Update the snapshot to include JBMICROCONT-137

  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-aop-mc-int-boot.jar      1.9
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-aop-mc-int-deployer.jar  1.9
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-aop-mc-int-src.zip       1.4
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-aop-mc-int.jar           1.13
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-container-src.zip        1.4
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-container.jar            1.38
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-dependency-src.zip       1.2
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-dependency.jar           1.11
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-deployers-src.zip        1.3
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-deployers.jar            1.36
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-microcontainer-src.zip   1.4
  repository.jboss.com  jboss/microcontainer/snapshot/lib/jboss-microcontainer.jar       1.15


Commit from pjha (2006-12-18 18:23 EST)
----------------

adding ejb3 rc9 patch1 release

  repository.jboss.com  jboss/ejb3/1.0.0.CR8-jboss4/component-info.xml  1.4


Commit from pjha (2006-12-18 18:32 EST)
----------------

ejb3 rc9 patch1

+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/component-info.xml                              1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/bin/ejb3.deployer                               1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/lib/hibernate-client.jar                        1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/lib/jboss-ejb3-client.jar                       1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/resources/ejb3-clustered-sfsbcache-service.xml  1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/resources/ejb3-entity-cache-service.xml         1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9.1-4.0.5/resources/ejb3-interceptors-aop.xml             1.1


Commit from gavin (2006-12-18 19:40 EST)
-----------------

in and out in pages.xml

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd                         1.12
  jboss-seam  src/main/org/jboss/seam/core/Pages.java                       1.70
  jboss-seam  src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java    1.34
  jboss-seam  src/main/org/jboss/seam/pages/ActionNavigation.java           1.3
+ jboss-seam  src/main/org/jboss/seam/pages/Input.java                      1.1
  jboss-seam  src/main/org/jboss/seam/pages/NavigationHandler.java          1.2
  jboss-seam  src/main/org/jboss/seam/pages/Outcome.java                    1.3
+ jboss-seam  src/main/org/jboss/seam/pages/Output.java                     1.1
  jboss-seam  src/main/org/jboss/seam/pages/Page.java                       1.3
+ jboss-seam  src/main/org/jboss/seam/pages/Put.java                        1.1
  jboss-seam  src/main/org/jboss/seam/pages/RedirectNavigationHandler.java  1.2
  jboss-seam  src/main/org/jboss/seam/pages/RenderNavigationHandler.java    1.2


Commit from gavin (2006-12-18 19:51 EST)
-----------------

minor

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd  1.13


Commit from vivekl (2006-12-18 20:28 EST)
------------------

EJB3 deployer correspnding to rev 58876 of JBoss_4_0_5_GA_EJBTHREE-798 branch.

+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/component-info.xml                              1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/bin/ejb3.deployer                               1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib/hibernate-client.jar                        1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/lib/jboss-ejb3-client.jar                       1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources/ejb3-clustered-sfsbcache-service.xml  1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources/ejb3-entity-cache-service.xml         1.1
+ repository.jboss.com  jboss/ejb3/1.0.0.CR9-jboss4.0.5-ejbthree795/resources/ejb3-interceptors-aop.xml             1.1


Commit from starksm (2006-12-18 20:36 EST)
-------------------

Add the 2.0.3.GA release to the maven repo

+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar       1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar.md5   1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA-sources.jar.sha1  1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar               1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.jar.sha1          1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.pom.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.pom.sha1          1.1


Commit from gavin (2006-12-18 20:38 EST)
-----------------

oops

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/Register.java        1.3
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/RegisterAction.java  1.17


Commit from starksm (2006-12-18 20:40 EST)
-------------------

Add the 2.0.3.GA jboss-logging-spi release to maven repo

+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar       1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar.md5   1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA-sources.jar.sha1  1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar               1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.jar.sha1          1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.pom               1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.pom.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-spi/2.0.3.GA/jboss-logging-spi-2.0.3.GA.pom.sha1          1.1


Commit from starksm (2006-12-18 20:42 EST)
-------------------

Add the jboss-logging-log4j 2.0.3.GA to the maven repo

+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar       1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar.md5   1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA-sources.jar.sha1  1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar               1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.jar.sha1          1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.pom               1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.pom.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-log4j/2.0.3.GA/jboss-logging-log4j-2.0.3.GA.pom.sha1          1.1


Commit from starksm (2006-12-18 20:43 EST)
-------------------

Add the jboss-logging-jdk 2.0.3.GA release to the maven repo

+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA-sources.jar       1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA-sources.jar.md5   1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA-sources.jar.sha1  1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.jar               1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.jar.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.jar.sha1          1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.pom               1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.pom.md5           1.1
+ repository.jboss.com  maven2/jboss/jboss-logging-jdk/2.0.3.GA/jboss-logging-jdk-2.0.3.GA.pom.sha1          1.1


Commit from remm (2006-12-18 21:14 EST)
----------------

- New snapshot.

  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/el-api.jar           1.10
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jbossweb-extras.jar  1.7
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jbossweb-src.zip     1.2
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jbossweb.jar         1.25
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/jsp-api.jar          1.8
  repository.jboss.com  jboss/web/2.0.0.snapshot/lib/servlet-api.jar      1.7


Commit from vivekl (2006-12-18 21:51 EST)
------------------

Tomcat 5.5.9 with additional patch to add support for custom options parser.

  repository.jboss.com  apache-tomcat/5.5.9.patch01/component-info.xml                                           1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/catalina-manager.jar                                     1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/catalina-optional.jar                                    1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/catalina.jar                                             1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/jasper-compiler-jdt.jar                                  1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/jasper-compiler.jar                                      1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/jasper-runtime.jar                                       1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/naming-resources.jar                                     1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/servlets-default.jar                                     1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/servlets-invoker.jar                                     1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/servlets-webdav.jar                                      1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/tomcat-ajp.jar                                           1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/tomcat-coyote.jar                                        1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/tomcat-http.jar                                          1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/lib/tomcat-util.jar                                          1.2
  repository.jboss.com  apache-tomcat/5.5.9.patch01/src/tomcat5-5.5.9-jboss.patch                                1.2
+ repository.jboss.com  apache-tomcat/5.5.9.patch01/src/tomcat5-5.5.9.patch01-JspServlet-5.15.17-backport.patch  1.1


Commit from starksm (2006-12-18 22:46 EST)
-------------------

Add a jboss-vfs snapshot release

+ repository.jboss.com  maven2/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot-sources.jar  1.1
+ repository.jboss.com  maven2/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot.jar          1.1
+ repository.jboss.com  maven2/jboss/jboss-vfs/2.0.4.snapshot/jboss-vfs-2.0.4.snapshot.pom          1.1


Commit from rsigal on branch remoting_2_x (2006-12-19 00:58 EST)
-----------------------------------------

JBREM-622:  Added javadoc change for addClientLocator().

  JBossRemoting  src/main/org/jboss/remoting/AbstractInvoker.java  1.12.4.5


Commit from rsigal on branch remoting_2_x (2006-12-19 01:00 EST)
-----------------------------------------

JBREM-650:  Made started variable protected.

  JBossRemoting  src/main/org/jboss/remoting/ServerInvoker.java  1.52.2.6
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061219/ff6bcbed/attachment.html 

From ron_sigal at yahoo.com  Tue Dec 19 01:01:43 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:01:43 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/socket ...
Message-ID: <E1GwY2p-0002iC-42@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:01:43

  Modified:    src/main/org/jboss/remoting/transport/socket  Tag:
                        remoting_2_x MicroSocketClientInvoker.java
  Log:
  JBREM-650:  Added "end of file message" to SocketException.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.16.2.2  +2 -2      JBossRemoting/src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MicroSocketClientInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java,v
  retrieving revision 1.16.2.1
  retrieving revision 1.16.2.2
  diff -u -b -r1.16.2.1 -r1.16.2.2
  --- MicroSocketClientInvoker.java	3 Nov 2006 04:07:31 -0000	1.16.2.1
  +++ MicroSocketClientInvoker.java	19 Dec 2006 06:01:42 -0000	1.16.2.2
  @@ -31,7 +31,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.16.2.1 $
  + * @version $Revision: 1.16.2.2 $
    */
   public class MicroSocketClientInvoker extends RemoteClientInvoker
   {
  @@ -363,7 +363,7 @@
                  version = readVersion(inputStream);
                  if (version == -1)
                  {
  -                  throw new SocketException();
  +                  throw new SocketException("end of file");
                  }
               }
   
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:02:23 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:02:23 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/socket ...
Message-ID: <E1GwY3T-0002ts-Vb@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:02:23

  Modified:    src/main/org/jboss/remoting/transport/socket  Tag:
                        remoting_2_x SocketServerInvoker.java
  Log:
  JBREM-650:  Made MAX_POOL_SIZE_DEFAULT protected.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.30.2.4  +2 -2      JBossRemoting/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java,v
  retrieving revision 1.30.2.3
  retrieving revision 1.30.2.4
  diff -u -b -r1.30.2.3 -r1.30.2.4
  --- SocketServerInvoker.java	14 Dec 2006 01:04:25 -0000	1.30.2.3
  +++ SocketServerInvoker.java	19 Dec 2006 06:02:23 -0000	1.30.2.4
  @@ -45,7 +45,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.30.2.3 $
  + * @version $Revision: 1.30.2.4 $
    * @jmx:mbean
    */
   public class SocketServerInvoker extends ServerInvoker implements Runnable, SocketServerInvokerMBean
  @@ -57,7 +57,7 @@
      private Properties props = new Properties();
   
      private static int BACKLOG_DEFAULT = 200;
  -   private static int MAX_POOL_SIZE_DEFAULT = 300;
  +   protected static int MAX_POOL_SIZE_DEFAULT = 300;
   
      /**
       * Key for indicating if socket invoker should continue to keep socket connection between
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:04:04 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:04:04 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1GwY56-0002wc-MN@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:04:04

  Modified:    src/main/org/jboss/remoting/transport/bisocket  Tag:
                        remoting_2_x Bisocket.java
  Log:
  JBREM-650: Changed START_SECONDARY_PORT to IS_CALLBACK_SERVER.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +2 -4      JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/Bisocket.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Bisocket.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/Bisocket.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- Bisocket.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  +++ Bisocket.java	19 Dec 2006 06:04:04 -0000	1.1.2.2
  @@ -23,18 +23,16 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    * <p>
    * Copyright Nov 22, 2006
    * </p>
    */
   public class Bisocket
   {
  -   public static final String BISOCKET_INTERNAL_SUBSYSTEM = "bisocketInternalSystem";
  -   public static final String CREATE_CALLBACK_SOCKET = "createCallbackSocket";
      public static final String GET_SECONDARY_INVOKER_LOCATOR = "getSecondaryInvokerLocator";
   
  -   public static final String START_SECONDARY_PORT = "startSecondaryPort";
  +   public static final String IS_CALLBACK_SERVER = "isCallbackServer";
      
      public static final byte PING                   = 1;
      public static final byte CREATE_CONTROL_SOCKET  = 2;
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:06:06 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:06:06 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1GwY74-000305-S5@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:06:06

  Modified:    src/main/org/jboss/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketClientInvoker.java
  Log:
  JBREM-650: Made listenerId protected.  Used 1000 for timeout waiting for new socket.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +4 -3      JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketClientInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketClientInvoker.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- BisocketClientInvoker.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  +++ BisocketClientInvoker.java	19 Dec 2006 06:06:06 -0000	1.1.2.2
  @@ -61,7 +61,7 @@
      private static Map listenerIdToSocketsMap = new HashMap();
    
      private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;;
  -   private String listenerId;
  +   protected String listenerId;
      private InvokerLocator secondaryLocator;
      private Socket controlSocket;
      private OutputStream controlOutputStream;
  @@ -303,7 +303,8 @@
            {
               try
               {
  -               sockets.wait(getTimeout());
  +//               sockets.wait(getTimeout());
  +               sockets.wait(1000);
                  if (sockets.isEmpty())
                     throw new IOException("Timed out trying to create socket");
                  break;
  @@ -311,10 +312,10 @@
               catch (InterruptedException ignored) {}
            }
            
  -         log.info("got socket");
            it = sockets.iterator();
            socket = (Socket) it.next();
            it.remove();
  +         log.info("got socket: " + socket);
            return socket;
         }
      }
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:09:22 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:09:22 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1GwYAE-000312-60@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:09:22

  Modified:    src/main/org/jboss/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketServerInvoker.java
  Log:
  JBREM-650:  Avoid creating server socket for callback server invoker.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +74 -35    JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketServerInvoker.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- BisocketServerInvoker.java	14 Dec 2006 01:03:55 -0000	1.1.2.1
  +++ BisocketServerInvoker.java	19 Dec 2006 06:09:21 -0000	1.1.2.2
  @@ -33,17 +33,17 @@
   import java.util.HashMap;
   import java.util.HashSet;
   import java.util.Iterator;
  +import java.util.LinkedList;
   import java.util.Map;
  -import java.util.Set;
   import java.util.TimerTask;
   
  -import org.apache.commons.logging.Log;
   import org.jboss.remoting.Client;
   import org.jboss.remoting.InvocationRequest;
   import org.jboss.remoting.InvokerLocator;
   import org.jboss.remoting.ServerInvocationHandler;
   import org.jboss.remoting.invocation.InternalInvocation;
   import org.jboss.remoting.transport.PortUtil;
  +import org.jboss.remoting.transport.socket.LRUPool;
   import org.jboss.remoting.transport.socket.ServerThread;
   import org.jboss.remoting.transport.socket.SocketServerInvoker;
   import org.jboss.remoting.util.TimerUtil;
  @@ -52,7 +52,7 @@
   /**
    *  
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    * <p>
    * Copyright Nov 23, 2006
    * </p>
  @@ -69,6 +69,7 @@
      private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;
      private int pingWindow = 2 * pingFrequency;
      private ControlMonitorTimerTask controlMonitorTimerTask;
  +   protected boolean isCallbackServer = false;
      
      
      public static BisocketServerInvoker getBisocketServerInvoker(String listenerId)
  @@ -97,26 +98,31 @@
      
      public void start() throws IOException
      {
  -      super.start();
  -      
  -      boolean startSecondaryPort = false;
  -      Object o = configuration.get(Bisocket.START_SECONDARY_PORT);
  -      
  -      if (o != null)
  +      if (isCallbackServer)
         {
  -         if (o instanceof String)
  -            startSecondaryPort = Boolean.valueOf((String) o).booleanValue();
  -         else if (o instanceof Boolean)
  -            startSecondaryPort = ((Boolean) o).booleanValue();
  +         if(maxPoolSize <= 0)
  +         {
  +            maxPoolSize = MAX_POOL_SIZE_DEFAULT;
  +         }
  +         clientpool = new LRUPool(2, maxPoolSize);
  +         clientpool.create();
  +         threadpool = new LinkedList();
  +         running = true;
  +         started = true;
  +      }
            else
  -            log.error("unrecognized value for configuration key \"" + 
  -                      Bisocket.START_SECONDARY_PORT + "\": " + o);
  -         
  -         if (startSecondaryPort)
            {
  +         super.start();
               InetAddress host = getServerSocket().getInetAddress();
               int freePort = PortUtil.findFreePort(host.getHostAddress());
  +         if (serverSocketFactory != null)
  +         {
  +            secondaryServerSocket = serverSocketFactory.createServerSocket(freePort, 0, host);
  +         }
  +         else
  +         {
               secondaryServerSocket = new ServerSocket(freePort, 0, host);
  +         }
               secondaryLocator = new InvokerLocator(null, host.getHostAddress(), freePort, null, null); 
               secondaryServerSocketThread = new SecondaryServerSocketThread(secondaryServerSocket);
               secondaryServerSocketThread.setName("secondaryServerSocketThread");
  @@ -124,7 +130,6 @@
               secondaryServerSocketThread.start();
               log.info("started secondary port: " + host + ":" + freePort);
            }
  -      }
   //      ServerInvocationHandler handler = new InternalInvocationHandler(secondaryServerSocket);
   //      addInvocationHandler(Bisocket.BISOCKET_INTERNAL_SUBSYSTEM, handler);
      }
  @@ -147,7 +152,12 @@
            listenerIdToInvokerLocatorMap.put(listenerId, locator);
         
         log.info("creating control connection: " + locator);
  -      Socket socket = new Socket(locator.getHost(), locator.getPort());
  +//      Socket socket = new Socket(locator.getHost(), locator.getPort());
  +      Socket socket = null;
  +      if (socketFactory != null)
  +         socket = socketFactory.createSocket(locator.getHost(), locator.getPort());
  +      else
  +         socket = new Socket(locator.getHost(), locator.getPort());
         DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
         dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
         dos.writeUTF(listenerId);
  @@ -167,7 +177,8 @@
         {
            controlMonitorTimerTask = new ControlMonitorTimerTask();
            TimerUtil.schedule(controlMonitorTimerTask, pingFrequency);
  -         log.info("scheduled ControlMonitorTimerTask: " + controlMonitorTimerTask);
  +         log.info(this + ": scheduled ControlMonitorTimerTask: " + controlMonitorTimerTask);
  +         log.info("pingFrequency: " + pingFrequency);
         }
      }
      
  @@ -186,9 +197,30 @@
      }
      
      
  +   protected void setup() throws Exception
  +   {
  +      Object o = configuration.get(Bisocket.IS_CALLBACK_SERVER);
  +      
  +      if (o != null)
  +      {
  +         if (o instanceof String)
  +            isCallbackServer = Boolean.valueOf((String) o).booleanValue();
  +         else if (o instanceof Boolean)
  +            isCallbackServer = ((Boolean) o).booleanValue();
  +         else
  +            log.error("unrecognized value for configuration key \"" + 
  +                  Bisocket.IS_CALLBACK_SERVER + "\": " + o);
  +      }
  +      
  +      super.setup();
  +   }
  +   
  +   
      protected void cleanup()
      {
         super.cleanup();
  +      log.info(this + ": $$$entering cleanup()");
  +      log.info("controlMonitorTimerTask: " + this.controlMonitorTimerTask);
         
         if (controlMonitorTimerTask != null)
         {
  @@ -201,6 +233,7 @@
            t.shutdown();
            it.remove();
         }
  +      log.info("secondaryServerSocketThread: " + secondaryServerSocketThread);
         if (secondaryServerSocketThread != null)
         {
            secondaryServerSocketThread.shutdown();
  @@ -330,6 +363,9 @@
   //                     String listenerId = dis.readUTF();
   //                     dis.readUTF();
                        InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +                     if (socketFactory != null)
  +                        socket = socketFactory.createSocket(locator.getHost(), locator.getPort());
  +                     else
                        socket = new Socket(locator.getHost(), locator.getPort());
                        DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
                        dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
  @@ -354,7 +390,8 @@
               {
                  if (running)
                  {
  -                  if ("socket closed".equals(e.getMessage()))
  +                  if ("socket closed".equals(e.getMessage()) || 
  +                      "Socket is closed".equals(e.getMessage()))
                     {
                        shutdown();
                        return;
  @@ -411,7 +448,7 @@
      class SecondaryServerSocketThread extends Thread
      {
         private ServerSocket secondaryServerSocket;
  -      boolean running;
  +      boolean running = true;
         
         SecondaryServerSocketThread(ServerSocket secondaryServerSocket) throws IOException
         {
  @@ -422,11 +459,11 @@
         {
            running = false;
            interrupt();
  +         log.info(this + ": shut down");
         }
         
         public void run()
         {
  -         running = true;
            while (running)
            {
               try
  @@ -474,6 +511,8 @@
      
      class ControlMonitorTimerTask extends TimerTask
      {
  +      private boolean running = true;
  +      
         void shutdown()
         {
            running = false;
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:09:55 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:09:55 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket
	- New directory ...
Message-ID: <E1GwYAl-00031E-2D@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:09:55

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Tue Dec 19 01:10:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:10:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket ...
Message-ID: <E1GwYAr-00031i-BI@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:10:01

  Added:       src/main/org/jboss/remoting/transport/sslbisocket     Tag:
                        remoting_2_x TransportClientFactory.java
                        SSLBisocketClientInvoker.java
                        TransportServerFactory.java
                        SSLBisocketServerInvoker.java
  Log:
  JBREM-650:  Create ssl version of bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +46 -0     JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/Attic/TransportClientFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportClientFactory.java
  ===================================================================
  RCS file: TransportClientFactory.java
  diff -N TransportClientFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportClientFactory.java	19 Dec 2006 06:10:01 -0000	1.1.2.1
  @@ -0,0 +1,46 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.sslbisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.transport.ClientFactory;
  +import org.jboss.remoting.transport.ClientInvoker;
  +
  +import java.io.IOException;
  +import java.util.Map;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class TransportClientFactory implements ClientFactory
  +{
  +   public ClientInvoker createClientInvoker(InvokerLocator locator, Map config) throws IOException
  +   {
  +      return new SSLBisocketClientInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return true;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +137 -0    JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/Attic/SSLBisocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketClientInvoker.java
  ===================================================================
  RCS file: SSLBisocketClientInvoker.java
  diff -N SSLBisocketClientInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketClientInvoker.java	19 Dec 2006 06:10:01 -0000	1.1.2.1
  @@ -0,0 +1,137 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.sslbisocket;
  +
  +import java.io.IOException;
  +import java.net.Socket;
  +import java.util.Map;
  +
  +import javax.net.SocketFactory;
  +import javax.net.ssl.HandshakeCompletedListener;
  +import javax.net.ssl.SSLSocket;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.bisocket.BisocketClientInvoker;
  +import org.jboss.remoting.util.socket.HandshakeRepeater;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + *  * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketClientInvoker extends BisocketClientInvoker
  +{
  +   private static final Logger log = Logger.getLogger(SSLBisocketClientInvoker.class);
  +
  +   public SSLBisocketClientInvoker(InvokerLocator locator) throws IOException
  +   {
  +      super(locator);
  +      try
  +      {
  +         setup();
  +      }
  +      catch (Exception ex)
  +      {
  +         log.error("Error setting up ssl bisocket client invoker.", ex);
  +         throw new RuntimeException(ex.getMessage());
  +      }
  +   }
  +
  +   public SSLBisocketClientInvoker(InvokerLocator locator, Map configuration) throws IOException
  +   {
  +      super(locator, configuration);
  +      try
  +      {
  +         setup();
  +      }
  +      catch (Exception ex)
  +      {
  +         log.error("Error setting up ssl bisocket client invoker.", ex);
  +         throw new RuntimeException(ex.getMessage());
  +      }
  +   }
  +
  +   protected SocketFactory createSocketFactory(Map configuration)
  +   {
  +      SocketFactory sf = super.createSocketFactory(configuration);
  +
  +      if (sf != null)
  +      {
  +         return sf;
  +      }
  +
  +      try
  +      {
  +         SSLSocketBuilder server = new SSLSocketBuilder(configuration);
  +         sf = server.createSSLSocketFactory();
  +      }
  +      catch (Exception e)
  +      {
  +         log.error("Error creating SSL Socket Factory for client invoker.", e);
  +      }
  +
  +      return sf;
  +   }
  +
  +   
  +   
  +   protected Socket createSocket(String address, int port) throws IOException
  +   {
  +      log.info("listenerId: " + listenerId);
  +      if (listenerId != null)
  +         return super.createSocket(address, port);
  +      
  +      SocketFactory sf = getSocketFactory();
  +
  +      if (sf == null)
  +         sf = createSocketFactory(configuration);
  +
  +      Socket s = sf.createSocket(address, port);
  +log.info("socket factory: " + sf);
  +log.info("socket: " + s);
  +      if (s instanceof SSLSocket)
  +      {
  +         // need to check for handshake listener and add them if there is one
  +         Object obj = configuration.get(Client.HANDSHAKE_COMPLETED_LISTENER);
  +         if (obj != null && obj instanceof HandshakeCompletedListener)
  +         {
  +            SSLSocket sslSocket = (SSLSocket) s;
  +            HandshakeCompletedListener listener = (HandshakeCompletedListener) obj;
  +            establishHandshake(sslSocket, listener);
  +         }
  +      }
  +
  +      return s;
  +   }
  +
  +   private void establishHandshake(SSLSocket sslSocket, HandshakeCompletedListener listener)
  +         throws IOException
  +   {
  +      HandshakeRepeater repeater = new HandshakeRepeater(listener);
  +      sslSocket.addHandshakeCompletedListener(repeater);
  +      sslSocket.getSession();
  +      repeater.waitForHandshake();
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +24 -0     JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/Attic/TransportServerFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportServerFactory.java
  ===================================================================
  RCS file: TransportServerFactory.java
  diff -N TransportServerFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportServerFactory.java	19 Dec 2006 06:10:01 -0000	1.1.2.1
  @@ -0,0 +1,24 @@
  +package org.jboss.remoting.transport.sslbisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.transport.ServerFactory;
  +
  +import java.util.Map;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class TransportServerFactory implements ServerFactory
  +{
  +   public ServerInvoker createServerInvoker(InvokerLocator locator, Map config)
  +   {
  +      return new SSLBisocketServerInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return true;
  +   }
  +}
  
  
  
  1.1.2.1   +107 -0    JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/Attic/SSLBisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketServerInvoker.java
  ===================================================================
  RCS file: SSLBisocketServerInvoker.java
  diff -N SSLBisocketServerInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketServerInvoker.java	19 Dec 2006 06:10:01 -0000	1.1.2.1
  @@ -0,0 +1,107 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.sslbisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.bisocket.BisocketServerInvoker;
  +import org.jboss.remoting.transport.sslsocket.SSLSocketServerInvokerMBean;
  +
  +import javax.net.ServerSocketFactory;
  +import javax.net.SocketFactory;
  +import javax.net.ssl.SSLServerSocketFactory;
  +import java.io.IOException;
  +import java.net.InetAddress;
  +import java.net.ServerSocket;
  +import java.util.Map;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketServerInvoker
  +   extends BisocketServerInvoker
  +   implements SSLSocketServerInvokerMBean
  +{
  +
  +   public SSLBisocketServerInvoker(InvokerLocator locator)
  +   {
  +      super(locator);
  +   }
  +
  +   public SSLBisocketServerInvoker(InvokerLocator locator, Map configuration)
  +   {
  +      super(locator, configuration);
  +   }
  +
  +   protected ServerSocketFactory getDefaultServerSocketFactory()
  +   {
  +      return SSLServerSocketFactory.getDefault();
  +   }
  +
  +   protected ServerSocketFactory createServerSocketFactory() throws IOException
  +   {
  +      if (isCallbackServer)
  +         return null;
  +      
  +      return super.createServerSocketFactory();
  +   }
  +   
  +   protected void setup() throws Exception
  +   {
  +      super.setup();
  +      if (isCallbackServer)
  +      {
  +         socketFactory = createSocketFactory(configuration);
  +      }
  +   }
  +   
  +   protected SocketFactory createSocketFactory(Map configuration)
  +   {
  +      SocketFactory sf = super.createSocketFactory(configuration);
  +
  +      if (sf != null)
  +      {
  +         return sf;
  +      }
  +
  +      try
  +      {
  +         SSLSocketBuilder server = new SSLSocketBuilder(configuration);
  +         sf = server.createSSLSocketFactory();
  +      }
  +      catch (Exception e)
  +      {
  +         log.error("Error creating SSL Socket Factory for client invoker.", e);
  +      }
  +
  +      return sf;
  +   }
  +   
  +   protected ServerSocket createServerSocket(int serverBindPort, int backlog, InetAddress bindAddress) throws IOException
  +   {
  +      ServerSocket svrSocket = getServerSocketFactory().createServerSocket(serverBindPort, backlog, bindAddress);
  +      return svrSocket;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:13:07 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:13:07 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1GwYDr-00036N-P8@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:13:07

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketTestCase.java
  Log:
  JBREM-650: (1) Added getTransport(), addExtraClientConfig(), addExtraServerConfig(). (2) Used Bisocket.IS_CALLBACK_SERVER.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +76 -63    JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- BisocketTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  +++ BisocketTestCase.java	19 Dec 2006 06:13:07 -0000	1.1.2.2
  @@ -48,7 +48,6 @@
   import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
   import org.jboss.remoting.transport.ClientInvoker;
   import org.jboss.remoting.transport.Connector;
  -import org.jboss.remoting.transport.PortUtil;
   import org.jboss.remoting.transport.bisocket.Bisocket;
   import org.jboss.remoting.transport.bisocket.BisocketClientInvoker;
   import org.jboss.remoting.transport.bisocket.BisocketServerInvoker;
  @@ -56,7 +55,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -87,14 +86,14 @@
       */
      public void setUp() throws Exception
      {
  -      String locatorURI = "bisocket://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
  +      String locatorURI = getTransport() + "://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         System.out.println("Starting remoting server with locator uri of: " + locatorURI);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
         config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
         config.put(MicroSocketClientInvoker.MAX_POOL_SIZE_FLAG, TEST_MAX_POOL_SIZE_STRING);
  +      addExtraServerConfig(config);
         connector = new Connector(serverLocator, config);
         connector.create();
         invocationHandler = new SampleInvocationHandler();
  @@ -117,12 +116,12 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -146,12 +145,13 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -195,12 +195,13 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -231,12 +232,13 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -310,19 +312,19 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
         log.info("client is connected");
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector = new Connector(callbackLocatorURI, config);
         callbackConnector.start();
         DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  @@ -365,19 +367,19 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
         assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector = new Connector(callbackLocatorURI, config);
         callbackConnector.start();
         
  @@ -471,24 +473,22 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
         log.info("client is connected");
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
         callbackConnector1.start();
  -      freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
         Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
         callbackConnector2.start();
         
  @@ -554,24 +554,22 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
         assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
         callbackConnector1.start();
  -      freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
         Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
         callbackConnector2.start();
         
  @@ -668,12 +666,12 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client1 = new Client(serverLocator, config);
         client1.connect();
         Client client2 = new Client(serverLocator, config);
  @@ -682,8 +680,8 @@
         assertTrue(client1.getInvoker() instanceof BisocketClientInvoker);
         assertTrue(client2.getInvoker() instanceof BisocketClientInvoker);
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector = new Connector(callbackLocatorURI, config);
         callbackConnector.start();
         
  @@ -737,20 +735,19 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
         assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI = "bisocket://" + host + ":" + freePort;
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector = new Connector(callbackLocatorURI, config);
         callbackConnector.start();
         
  @@ -842,12 +839,12 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client1 = new Client(serverLocator, config);
         client1.connect();
         Client client2 = new Client(serverLocator, config);
  @@ -856,13 +853,11 @@
         assertTrue(client1.getInvoker() instanceof BisocketClientInvoker);
         assertTrue(client2.getInvoker() instanceof BisocketClientInvoker);
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
         callbackConnector1.start();
  -      freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
         Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
         callbackConnector2.start();
         
  @@ -943,24 +938,22 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
         assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
         
  -      int freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI1 = "bisocket://" + host + ":" + freePort;
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
         callbackConnector1.start();
  -      freePort = PortUtil.findFreePort(host);
  -      String callbackLocatorURI2 = "bisocket://" + host + ":" + freePort;
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
         Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
         callbackConnector2.start();
         
  @@ -1054,13 +1047,14 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -1120,13 +1114,14 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -1166,13 +1161,14 @@
      {
         log.info("entering " + getName());
         String host = InetAddress.getLocalHost().getHostName();
  -      int port = BisocketPerformanceTestServer.port;
  -      String locatorURI = "bisocket://" + host + ":" + port; 
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         log.info("Connecting to: " + serverLocator);
         HashMap config = new HashMap();
         config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
         config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
         Client client = new Client(serverLocator, config);
         client.connect();
         log.info("client is connected");
  @@ -1243,6 +1239,23 @@
         }
      }
   
  +   
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   
  +   protected void addExtraClientConfig(Map config)
  +   {
  +   }
  +   
  +   
  +   protected void addExtraServerConfig(Map config)
  +   {
  +   }
  +   
  +
      /**
       * Simple invocation handler implementation.  When callback client's are registered, will
       * generate callbacks periodically.
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:14:06 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:14:06 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1GwYEo-00037z-LC@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:14:06

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketPerformanceTestServer.java
  Log:
  JBREM-650: Changed Bisocket.START_SECONDARY_SERVER to Bisocket.IS_CALLBACK_SERVER.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +2 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketPerformanceTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPerformanceTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketPerformanceTestServer.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- BisocketPerformanceTestServer.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  +++ BisocketPerformanceTestServer.java	19 Dec 2006 06:14:06 -0000	1.1.2.2
  @@ -41,7 +41,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -66,7 +66,7 @@
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         System.out.println("Starting remoting server with locator uri of: " + locatorURI);
         HashMap config = new HashMap();
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "false");
         connector = new Connector(serverLocator, config);
         connector.create();
         SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:17:16 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:16 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration
	...
Message-ID: <E1GwYHs-0003C0-Km@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:16

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/configuration 
                        Tag: remoting_2_x FactoryConfigTestCase.java
  Log:
  JBREM-650: Changed Bisocket.START_SECONDARY_PORT to Bisocket.IS_CALLBACK_SERVER.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +2 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration/Attic/FactoryConfigTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration/Attic/FactoryConfigTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- FactoryConfigTestCase.java	14 Dec 2006 01:08:02 -0000	1.1.2.1
  +++ FactoryConfigTestCase.java	19 Dec 2006 06:17:16 -0000	1.1.2.2
  @@ -30,7 +30,7 @@
    * 
    * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
    * <p>
  - * Copyright (c) May 20, 2006
  + * Copyright (c) Dec 15, 2005
    * </p>
    */
   public class FactoryConfigTestCase extends FactoryConfigTestCaseParent
  @@ -42,6 +42,6 @@
      
      protected void configureServer(Map config)
      {
  -      config.put(Bisocket.START_SECONDARY_PORT, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "false");
      }
   }
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:17:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection
	- New directory ...
Message-ID: <E1GwYIR-0003CA-9K@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:51

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Tue Dec 19 01:17:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry
	- New directory ...
Message-ID: <E1GwYIR-0003CE-DG@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:51

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:17:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/deadlock
	- New directory ...
Message-ID: <E1GwYIR-0003CI-HL@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:51

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/deadlock added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Tue Dec 19 01:17:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool
	- New directory ...
Message-ID: <E1GwYIR-0003CM-LN@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:51

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Tue Dec 19 01:17:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection
	...
Message-ID: <E1GwYIT-0003D1-8e@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/connection      
                        Tag: remoting_2_x
                        BisocketConnectionCheckTestClient.java
                        BisocketConnectionTestCase.java
                        BisocketTestClient.java
                        BiocketConnectionCheckTestCase.java
                        BisocketConnectionCheckTestServer.java
                        BisocketTestServer.java
  Log:
  JBREM-650: Added more unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BisocketConnectionCheckTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionCheckTestClient.java
  ===================================================================
  RCS file: BisocketConnectionCheckTestClient.java
  diff -N BisocketConnectionCheckTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionCheckTestClient.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketConnectionCheckTestClient;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a> 
  + */
  +public class BisocketConnectionCheckTestClient extends SocketConnectionCheckTestClient
  +{  
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 17;
  +   }
  +}
  
  
  
  1.1.2.1   +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BisocketConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionTestCase.java
  ===================================================================
  RCS file: BisocketConnectionTestCase.java
  diff -N BisocketConnectionTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionTestCase.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.connection;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketConnectionTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketTestClient.class.getName(),
  +                     1,
  +                     BisocketTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +42 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BisocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestClient.java
  ===================================================================
  RCS file: BisocketTestClient.java
  diff -N BisocketTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTestClient.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,42 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketTestClient;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketTestClient extends SocketTestClient
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 18;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +79 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BiocketConnectionCheckTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BiocketConnectionCheckTestCase.java
  ===================================================================
  RCS file: BiocketConnectionCheckTestCase.java
  diff -N BiocketConnectionCheckTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BiocketConnectionCheckTestCase.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,79 @@
  +/*
  +* JBoss, a division of Red Hat
  +* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +import org.apache.log4j.Level;
  +
  +/**
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BiocketConnectionCheckTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketConnectionCheckTestClient.class.getName(),
  +                     1,
  +                     BisocketConnectionCheckTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BisocketConnectionCheckTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionCheckTestServer.java
  ===================================================================
  RCS file: BisocketConnectionCheckTestServer.java
  diff -N BisocketConnectionCheckTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionCheckTestServer.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketConnectionCheckTestServer;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketConnectionCheckTestServer extends SocketConnectionCheckTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 17;
  +   }
  +}
  
  
  
  1.1.2.1   +41 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BisocketTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestServer.java
  ===================================================================
  RCS file: BisocketTestServer.java
  diff -N BisocketTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTestServer.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,41 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketTestServer;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketTestServer extends SocketTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 18;
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:17:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool
	...
Message-ID: <E1GwYIT-0003DI-Cl@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/socketpool   
                        Tag: remoting_2_x BisocketPoolTestClient.java
                        BisocketPoolTestCase.java
                        BisocketPoolTestServer.java
  Log:
  JBREM-650: Added more unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/Attic/BisocketPoolTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPoolTestClient.java
  ===================================================================
  RCS file: BisocketPoolTestClient.java
  diff -N BisocketPoolTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPoolTestClient.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,48 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.socketpool;
  +
  +import org.jboss.test.remoting.transport.socket.socketpool.SocketPoolTestClient;
  +
  +/**
  + * See SocketPoolTestCase for description.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * 
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class BisocketPoolTestClient extends SocketPoolTestClient
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 7;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +88 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/Attic/BisocketPoolTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPoolTestCase.java
  ===================================================================
  RCS file: BisocketPoolTestCase.java
  diff -N BisocketPoolTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPoolTestCase.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,88 @@
  +/*
  +* JBoss, a division of Red Hat
  +* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.socketpool;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +
  +/**
  + *  This unit test is introduced in response to JIRA issue JBREM-625.
  + *  It verifies that when a socket is discarded, the count of sockets
  + *  in use is decremented.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + *  
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class BisocketPoolTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {  
  +      addTestClasses(BisocketPoolTestClient.class.getName(),
  +                     1,
  +                     BisocketPoolTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/Attic/BisocketPoolTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPoolTestServer.java
  ===================================================================
  RCS file: BisocketPoolTestServer.java
  diff -N BisocketPoolTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPoolTestServer.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,48 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.socketpool;
  +
  +import org.jboss.test.remoting.transport.socket.socketpool.SocketPoolTestServer;
  +
  +/** 
  + * See SocketPoolTestCase for description.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * 
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class BisocketPoolTestServer extends SocketPoolTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 7;
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:17:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/deadlock
	...
Message-ID: <E1GwYIT-0003Dk-N3@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/deadlock 
                        Tag: remoting_2_x
                        BisocketShutdownDeadlockTestCase.java
  Log:
  JBREM-650: Added more unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +36 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/deadlock/Attic/BisocketShutdownDeadlockTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketShutdownDeadlockTestCase.java
  ===================================================================
  RCS file: BisocketShutdownDeadlockTestCase.java
  diff -N BisocketShutdownDeadlockTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketShutdownDeadlockTestCase.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,36 @@
  +/***************************************
  + *                                     *
  + *  JBoss: The OpenSource J2EE WebOS   *
  + *                                     *
  + *  Distributable under LGPL license.  *
  + *  See terms of license at gnu.org.   *
  + *                                     *
  + ***************************************/
  +package org.jboss.test.remoting.transport.bisocket.deadlock;
  +
  +import org.jboss.test.remoting.transport.socket.deadlock.ShutdownDeadlockTestCase;
  +
  +/**
  + * This test case is for JBREM-576.
  + * Test trys to catch deadlock in shutdown where socket client
  + * invoker being use my multiple Clients.  Need one client making
  + * invocations (which will cause sync on pool) and another to
  + * shutdown, which will cause disconnect on socket client invoker,
  + * thus causing it to sync on pool for clearing out the pool.
  + * Since this is an issue of multithreading, is certainly possible
  + * this test will pass even though the deadlock issue still exists.
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketShutdownDeadlockTestCase extends ShutdownDeadlockTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 11;
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:17:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:17:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry
	...
Message-ID: <E1GwYIT-0003DZ-HZ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:17:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry   
                        Tag: remoting_2_x BisocketRetryTestCase.java
                        BisocketRetryServer.java BisocketRetryClient.java
  Log:
  JBREM-650: Added more unit tests for bisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/Attic/BisocketRetryTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketRetryTestCase.java
  ===================================================================
  RCS file: BisocketRetryTestCase.java
  diff -N BisocketRetryTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketRetryTestCase.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,38 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection.retry;
  +
  +import org.jboss.test.remoting.transport.socket.connection.retry.SocketRetryTestCase;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketRetryTestCase extends SocketRetryTestCase
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketRetryClient.class.getName(),
  +                     1,
  +                     BisocketRetryServer.class.getName());
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/Attic/BisocketRetryServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketRetryServer.java
  ===================================================================
  RCS file: BisocketRetryServer.java
  diff -N BisocketRetryServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketRetryServer.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection.retry;
  +
  +import org.jboss.test.remoting.transport.socket.connection.retry.SocketRetryServer;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketRetryServer extends SocketRetryServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 13;
  +   }
  +}
  
  
  
  1.1.2.1   +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/Attic/BisocketRetryClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketRetryClient.java
  ===================================================================
  RCS file: BisocketRetryClient.java
  diff -N BisocketRetryClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketRetryClient.java	19 Dec 2006 06:17:53 -0000	1.1.2.1
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection.retry;
  +
  +import org.jboss.test.remoting.transport.socket.connection.retry.SocketRetryClient;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketRetryClient extends SocketRetryClient
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 13;
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:18:42 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:18:42 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl
	- New directory ...
Message-ID: <E1GwYJG-0003Dq-PP@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:18:42

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl added to the repository
  --> Using per-directory sticky tag `remoting_2_x'


From ron_sigal at yahoo.com  Tue Dec 19 01:18:47 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:18:47 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic
	- New directory ...
Message-ID: <E1GwYJL-0003Du-3r@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:18:47

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:18:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:18:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder
	- New directory ...
Message-ID: <E1GwYJO-0003Dy-My@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:18:50

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:18:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:18:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config
	- New directory ...
Message-ID: <E1GwYJS-0003E2-Ly@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:18:54

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:18:59 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:18:59 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check
	- New directory ...
Message-ID: <E1GwYJX-0003E6-Gv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:18:59

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:19:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom
	- New directory ...
Message-ID: <E1GwYJa-0003EA-2A@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:02

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:19:04 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:04 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake
	- New directory ...
Message-ID: <E1GwYJc-0003EE-Tp@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:04

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:19:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check
	- New directory ...
Message-ID: <E1GwYJh-0003EI-5U@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:09

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:19:12 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:12 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh
	- New directory ...
Message-ID: <E1GwYJk-0003EM-Va@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:12

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:19:15 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:15 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate
	- New directory ...
Message-ID: <E1GwYJn-0003EQ-Tv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:15

  Log:
  Directory /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate added to the repository


From ron_sigal at yahoo.com  Tue Dec 19 01:19:22 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:22 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check
	...
Message-ID: <E1GwYJu-0003Ew-EU@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:22

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check   
                        Tag: remoting_2_x SSLBisocketInvokerServerTest.java
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/Attic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,38 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.connection_check;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.connection_check.InvokerServerTest;
  +
  +/**
  + * This is the concrete test for invoker server.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest
  +   extends InvokerServerTest implements SSLBisocketInvokerConstants
  +{
  +   
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerServerTest server = new SSLBisocketInvokerServerTest();
  +      try
  +      {
  +         server.setUp();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.1.2.1   +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/Attic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.connection_check;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +26 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/Attic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,26 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.connection_check;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.connection_check.InvokerClientTest;
  +
  +/**
  + * This is the actual concrete test for the invoker client.  Uses socket transport by default.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest
  +   extends InvokerClientTest implements SSLBisocketInvokerConstants
  +{
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:22 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:22 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate
	...
Message-ID: <E1GwYJu-0003FE-Ip@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:22

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate     
                        Tag: remoting_2_x serverTrustStore2 serverKeyStore
                        serverTrustStore clientKeyStore clientTrustStore
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +7 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/Attic/serverTrustStore2
  
  	<<Binary file>>
  
  
  1.1.2.1   +9 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/Attic/serverKeyStore
  
  	<<Binary file>>
  
  
  1.1.2.1   +4 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/Attic/serverTrustStore
  
  	<<Binary file>>
  
  
  1.1.2.1   +7 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/Attic/clientKeyStore
  
  	<<Binary file>>
  
  
  1.1.2.1   +6 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/Attic/clientTrustStore
  
  	<<Binary file>>
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:22 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:22 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake
	...
Message-ID: <E1GwYJu-0003FV-NC@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:22

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake   
                        Tag: remoting_2_x SSLBisocketInvokerServerTest.java
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/Attic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.handshake;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.handshake.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest extends InvokerServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.1.2.1   +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/Attic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.handshake;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/Attic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.handshake;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.handshake.InvokerClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest extends InvokerClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:22 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:22 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check
	...
Message-ID: <E1GwYJu-0003Fm-R1@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:22

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check   
                        Tag: remoting_2_x SSLBisocketInvokerTestCase.java
                        BisocketInvokerServerTest.java
                        SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/Attic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.no_connection_check;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     BisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.1.2.1   +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/Attic/BisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInvokerServerTest.java
  ===================================================================
  RCS file: BisocketInvokerServerTest.java
  diff -N BisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInvokerServerTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.no_connection_check;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.no_connection_check.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketInvokerServerTest extends InvokerServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.1.2.1   +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/Attic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.no_connection_check;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.no_connection_check.InvokerClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest extends InvokerClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:22 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:22 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh
	...
Message-ID: <E1GwYJu-0003G3-Vr@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:22

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh   
                        Tag: remoting_2_x SSLBisocketTestServer.java
                        SSLBisocketTestCase.java SSLBisocketTestClient.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +32 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/Attic/SSLBisocketTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestServer.java
  ===================================================================
  RCS file: SSLBisocketTestServer.java
  diff -N SSLBisocketTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestServer.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,32 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.serversocketrefresh;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.serversocketrefresh.TestServer;
  +
  +
  +/**
  + * @author Michael Voss
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + *
  + */
  +public class SSLBisocketTestServer extends TestServer
  +{
  +   public static void main(String[] args)
  +   {
  +      TestServer server = new SSLBisocketTestServer();
  +      server.setUp();
  +      try
  +      {
  +         server.test();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +   
  +   
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.1.2.1   +21 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/Attic/SSLBisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestCase.java
  ===================================================================
  RCS file: SSLBisocketTestCase.java
  diff -N SSLBisocketTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestCase.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,21 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.serversocketrefresh;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * JBREM-427 load a new keystore at runtime<br>
  + * server is refreshing its serversocket after a new ServerSocketFactory was set<br>
  + * second client connection attempt fails because client is not accepted by the new truststore
  + * @author Michael Voss
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + *
  + */
  +public class SSLBisocketTestCase extends TestDriver{
  +	
  +	public void declareTestClasses()
  +	   {
  +	      addTestClasses(SSLBisocketTestClient.class.getName(),
  +	                     1,
  +	                     SSLBisocketTestServer.class.getName());
  +
  +	   }
  +}
  
  
  
  1.1.2.1   +17 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/Attic/SSLBisocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestClient.java
  ===================================================================
  RCS file: SSLBisocketTestClient.java
  diff -N SSLBisocketTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestClient.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  @@ -0,0 +1,17 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.serversocketrefresh;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.serversocketrefresh.TestClient;
  +
  +/**
  + * @author Michael Voss
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + *
  + */
  +public class SSLBisocketTestClient extends TestClient
  +{
  +	protected String getTransport()
  +	{
  +	   return "sslbisocket";
  +	}
  +	
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:23 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:23 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder
	...
Message-ID: <E1GwYJv-0003GK-3m@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:23

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder   
                        Tag: remoting_2_x SSLBisocketInvokerTestServer.java
                        SSLBisocketInvokerTestClient.java
                        SSLBisocketInvokerTestCase.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +43 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/Attic/SSLBisocketInvokerTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestServer.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestServer.java
  diff -N SSLBisocketInvokerTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestServer.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,43 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.builder;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.builder.SSLSocketInvokerTestServer;
  +
  +/**
  + * This is the server for the test case to verify can have push callbacks using ssl where
  + * the client mode is used for the client calling back on the callback server living within the
  + * client test instance.
  + *
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestServer
  +   extends SSLSocketInvokerTestServer
  +   implements SSLBisocketInvokerConstants
  +{
  +
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerTestServer server = new SSLBisocketInvokerTestServer();
  +      try
  +      {
  +         server.setUp();
  +
  +         Thread.sleep(600000);
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.1.2.1   +28 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/Attic/SSLBisocketInvokerTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestClient.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestClient.java
  diff -N SSLBisocketInvokerTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestClient.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,28 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.builder;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.builder.SSLSocketInvokerTestCase;
  +
  +/**
  + * This is the client for the test to make regular ssl based invocation to the server and
  + * have a ssl based callback server.  The special test in this case is want to have the callback
  + * client that lives on the server to be in client mode so that this client test only has to have
  + * a truststore locally, yet still use ssl.
  + *
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestClient
  +   extends SSLSocketInvokerTestCase
  +   implements SSLBisocketInvokerConstants
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.1.2.1   +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/Attic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,38 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.builder;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerTestClient.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerTestServer.class.getName());
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:23 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:23 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic
	...
Message-ID: <E1GwYJv-0003Gb-8T@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:23

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic   
                        Tag: remoting_2_x SSLBisocketInvokerServerTest.java
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +59 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/Attic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,59 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.basic;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.basic.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest extends InvokerServerTest implements SSLBisocketInvokerConstants
  +{
  +
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerServerTest server = new SSLBisocketInvokerServerTest();
  +      try
  +      {
  +         server.setUp();
  +
  +         Thread.sleep(1200000);
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.1.2.1   +81 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/Attic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,81 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.basic;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +46 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/Attic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,46 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.basic;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.basic.InvokerClientTest;
  +
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest
  +extends InvokerClientTest
  +implements SSLBisocketInvokerConstants
  +{ 
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:23 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:23 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom
	...
Message-ID: <E1GwYJv-0003Gs-Dt@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:23

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom   
                        Tag: remoting_2_x SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +85 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,85 @@
  +                                                                      /*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.custom;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +
  +/**
  + * This should be used as the main test case for the invoker client/server.
  + * It will start one instance of the client and one of the server and will
  + * gather the test results and report them in standard JUnit format.  When
  + * wanting to run JUnit test for invoker, this is the class to use.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +43 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,43 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + * Copyright 2005, JBoss Inc., and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.custom;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.custom.InvokerClientTest;
  +
  +
  +/**
  + * @author <a href="mailto:tom at jboss.com">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright (c) Dec 15, 2006
  + * </p>
  + */
  +public class SSLBisocketInvokerClientTest extends InvokerClientTest
  +{
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.1.2.1   +37 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,37 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.custom;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.custom.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest extends InvokerServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:19:23 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:19:23 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config
	...
Message-ID: <E1GwYJv-0003H3-I0@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:19:23

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config 
                        Tag: remoting_2_x FactoryConfigTestCase.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +40 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/Attic/FactoryConfigTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCase.java
  ===================================================================
  RCS file: FactoryConfigTestCase.java
  diff -N FactoryConfigTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ FactoryConfigTestCase.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  @@ -0,0 +1,40 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + * Copyright 2006, JBoss Inc., and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.config;
  +
  +import org.jboss.test.remoting.transport.config.FactoryConfigTestCaseSSLParent;
  +
  +
  +/**
  + * 
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + * <p>
  + * Copyright (c) May 20, 2006
  + * </p>
  + */
  +public class FactoryConfigTestCase extends FactoryConfigTestCaseSSLParent
  +{
  +   protected String getTransport()
  +   {
  +      return "sslsocket";
  +   }
  +}
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 01:23:06 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 01:23:06 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1820 -
	trunk/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GwYNW-0003LR-OZ@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 01:23:05 -0500 (Tue, 19 Dec 2006)
New Revision: 1820

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
adding testTopicSubscriber

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-19 05:54:19 UTC (rev 1819)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-19 06:23:05 UTC (rev 1820)
@@ -31,14 +31,23 @@
 import javax.jms.MessageProducer;
 import javax.jms.Session;
 import javax.jms.TextMessage;
+import javax.jms.Destination;
+import javax.jms.Topic;
 
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.jms.client.JBossMessageConsumer;
+import org.jboss.jms.client.JBossSession;
+import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.client.state.ConsumerState;
+import org.jboss.jms.client.state.SessionState;
+import org.jboss.jms.message.MessageProxy;
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
@@ -194,6 +203,100 @@
 
    }
 
+   public void testTopicSubscriber() throws Exception
+   {
+      log.info("++testTopicSubscriber");
+
+      log.info(">>Lookup Queue");
+      Destination destination = (Destination) topic[1];
+
+
+      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+      Connection conn1 = cf.createConnection();
+      Connection conn2 = cf.createConnection();
+      Connection conn3 = cf.createConnection();
+
+
+      this.checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
+      JBossConnection conn = (JBossConnection) getConnection(new Connection[]{conn1, conn2, conn3}, 1);
+
+      conn.setClientID("testClient");
+      conn.start();
+
+      JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+      ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
+      SessionState sessionState = (SessionState) clientSessionDelegate.getState();
+
+      MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
+      JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
+
+      org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
+      ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
+
+      log.info("subscriptionName=" + consumerState.getSubscriptionName());
+
+
+      log.info(">>Creating Producer");
+      MessageProducer producer = session.createProducer(destination);
+      log.info(">>creating Message");
+      Message message = session.createTextMessage("Hello Before");
+      log.info(">>sending Message");
+      producer.send(message);
+      session.commit();
+
+      receiveMessage("consumerHA", consumerHA, true, false);
+
+      session.commit();
+      //if (true) return;
+
+      Object txID = sessionState.getCurrentTxId();
+
+      producer.send(session.createTextMessage("Hello again before failover"));
+
+      ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
+
+      JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
+
+      ServerManagement.kill(1);
+
+      Thread.sleep(30000);
+      assertNotSame(originalRemoting, delegate.getRemotingConnection());
+
+      //System.out.println("Kill server1"); Thread.sleep(10000);
+
+      message = session.createTextMessage("Hello After");
+      log.info(">>Sending new message");
+      producer.send(message);
+
+      assertEquals(txID, sessionState.getCurrentTxId());
+      System.out.println("TransactionID on client = " + txID);
+      log.info(">>Final commit");
+
+      /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
+       connSecondServer.start();
+       JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
+       MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
+
+      session.commit();
+
+      /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+     receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
+     receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
+
+      log.info("Calling alternate receiver");
+      receiveMessage("consumerHA", consumerHA, true, false);
+      receiveMessage("consumerHA", consumerHA, true, false);
+      receiveMessage("consumerHA", consumerHA, true, true);
+
+
+      session.commit();
+      conn1.close();
+      conn2.close();
+      conn3.close();
+
+   }
+
+
    /*
     * Test that the failover mapping is created correctly and updated properly when nodes leave
     * or join
@@ -1190,30 +1293,30 @@
    }
    
    // Private -------------------------------------------------------
-   
-//   private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
-//   {
-//      MessageProxy message = (MessageProxy) consumer.receive(3000);
-//      TextMessage txtMessage = (TextMessage) message;
-//      if (message != null)
-//      {
-//         log.info(text + ": messageID from messageReceived=" + message.getMessage().getMessageID() + " message = " + message + " content=" + txtMessage.getText());
-//      } else
-//      {
-//         log.info(text + ": Message received was null");
-//      }
-//      if (shouldAssert)
-//      {
-//         if (shouldBeNull)
-//         {
-//            assertNull(message);
-//         } else
-//         {
-//            assertNotNull(message);
-//         }
-//      }
-//   }
-   
+
+   private void receiveMessage(String text, MessageConsumer consumer, boolean shouldAssert, boolean shouldBeNull) throws Exception
+   {
+      MessageProxy message = (MessageProxy) consumer.receive(3000);
+      TextMessage txtMessage = (TextMessage) message;
+      if (message != null)
+      {
+         log.info(text + ": messageID from messageReceived=" + message.getMessage().getMessageID() + " message = " + message + " content=" + txtMessage.getText());
+      } else
+      {
+         log.info(text + ": Message received was null");
+      }
+      if (shouldAssert)
+      {
+         if (shouldBeNull)
+         {
+            assertNull(message);
+         } else
+         {
+            assertNotNull(message);
+         }
+      }
+   }
+
    // Inner classes -------------------------------------------------
    
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 01:25:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 01:25:43 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1821 -
	trunk/tests/src/org/jboss/test/messaging/core
Message-ID: <E1GwYQ3-0003OM-0x@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 01:25:37 -0500 (Tue, 19 Dec 2006)
New Revision: 1821

Removed:
   trunk/tests/src/org/jboss/test/messaging/core/ha/
Log:
Removing old tests



From ron_sigal at yahoo.com  Tue Dec 19 01:26:15 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:26:15 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl
	...
Message-ID: <E1GwYQZ-0003Pm-Ko@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:26:15

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl    
                        Tag: remoting_2_x keystore truststore
                        SSLBisocketTestCase.java
                        SSLBisocketInvokerConstants.java
  Log:
  JBREM-650: Added unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +57 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/keystore
  
  	<<Binary file>>
  
  
  1.1.2.1   +34 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/truststore
  
  	<<Binary file>>
  
  
  1.1.2.1   +61 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/SSLBisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestCase.java
  ===================================================================
  RCS file: SSLBisocketTestCase.java
  diff -N SSLBisocketTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestCase.java	19 Dec 2006 06:26:15 -0000	1.1.2.1
  @@ -0,0 +1,61 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl;
  +
  +import java.util.Map;
  +
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.test.remoting.transport.bisocket.BisocketTestCase;
  +
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.1.2.1 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class SSLBisocketTestCase extends BisocketTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   
  +   protected void addExtraClientConfig(Map config)
  +   {
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  +      String trustStoreFilePath = this.getClass().getResource("truststore").getFile();
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
  +   }
  +   
  +   
  +   protected void addExtraServerConfig(Map config)
  +   {
  +      config.put(SSLSocketBuilder.REMOTING_KEY_STORE_TYPE, "JKS");
  +      String keyStoreFilePath = this.getClass().getResource("keystore").getFile();
  +      config.put(SSLSocketBuilder.REMOTING_KEY_STORE_FILE_PATH, keyStoreFilePath);
  +      config.put(SSLSocketBuilder.REMOTING_KEY_STORE_PASSWORD, "unit-tests-server");
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1.2.1   +32 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/SSLBisocketInvokerConstants.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerConstants.java
  ===================================================================
  RCS file: SSLBisocketInvokerConstants.java
  diff -N SSLBisocketInvokerConstants.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerConstants.java	19 Dec 2006 06:26:15 -0000	1.1.2.1
  @@ -0,0 +1,32 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public interface SSLBisocketInvokerConstants
  +{
  +   int bisocketPort = 8091;
  +   int bisocketCallbackPort = 8092;
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:08 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:08 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection
	...
Message-ID: <E1GwYRQ-0003QR-MP@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:08

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection    
                        Tag: remoting_2_x
                        SocketConnectionCheckTestServer.java
                        SocketTestServer.java
                        SocketConnectionCheckTestClient.java
                        SocketTestClient.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionCheckTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestServer.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- SocketConnectionCheckTestServer.java	9 Nov 2006 02:56:43 -0000	1.1.2.2
  +++ SocketConnectionCheckTestServer.java	19 Dec 2006 06:27:08 -0000	1.1.2.3
  @@ -58,7 +58,7 @@
   
      public void setUp() throws Exception
      {
  -      String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
  +      String locatorURI = getTransport() + "://" + host + ":" + getPort() + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
         setupServer(locatorURI);
      }
   
  @@ -94,6 +94,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      /**
       * Simple invocation handler implementation.
       * This is the code that will be called with the invocation payload from the client.
  
  
  
  1.3.4.3   +12 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestServer.java,v
  retrieving revision 1.3.4.2
  retrieving revision 1.3.4.3
  diff -u -b -r1.3.4.2 -r1.3.4.3
  --- SocketTestServer.java	9 Nov 2006 02:56:43 -0000	1.3.4.2
  +++ SocketTestServer.java	19 Dec 2006 06:27:08 -0000	1.3.4.3
  @@ -85,7 +85,7 @@
      {
         //String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
         //String locatorURI = transport + "://" + host + ":" + port + "/?" + InvokerLocator.SERIALIZATIONTYPE + "=jboss";
  -      String locatorURI = transport + "://" + host + ":" + port;
  +      String locatorURI = getTransport() + "://" + host + ":" + getPort();
         setupServer(locatorURI);
      }
   
  @@ -121,6 +121,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      /**
       * Simple invocation handler implementation.
       * This is the code that will be called with the invocation payload from the client.
  
  
  
  1.1.2.3   +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionCheckTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestClient.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- SocketConnectionCheckTestClient.java	9 Nov 2006 02:56:43 -0000	1.1.2.2
  +++ SocketConnectionCheckTestClient.java	19 Dec 2006 06:27:08 -0000	1.1.2.3
  @@ -23,7 +23,7 @@
         {
   
   
  -         String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
  +         String locatorURI = getTransport() + "://" + host + ":" + getPort() + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
   
            // create InvokerLocator with the url type string
            // indicating the target remoting server to call upon.
  @@ -66,6 +66,16 @@
   
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      /**
       * Can pass transport and port to be used as parameters.
       * Valid transports are 'rmi' and 'socket'.
  
  
  
  1.4.4.3   +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java,v
  retrieving revision 1.4.4.2
  retrieving revision 1.4.4.3
  diff -u -b -r1.4.4.2 -r1.4.4.3
  --- SocketTestClient.java	9 Nov 2006 02:56:43 -0000	1.4.4.2
  +++ SocketTestClient.java	19 Dec 2006 06:27:08 -0000	1.4.4.3
  @@ -53,7 +53,7 @@
   
            //String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
            //String locatorURI = transport + "://" + host + ":" + port + "/?" + InvokerLocator.SERIALIZATIONTYPE + "=jboss";
  -         String locatorURI = transport + "://" + host + ":" + port;
  +         String locatorURI = getTransport() + "://" + host + ":" + getPort();
   
            // create InvokerLocator with the url type string
            // indicating the target remoting server to call upon.
  @@ -122,4 +122,14 @@
      }
   
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
   }
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:08 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:08 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check
	...
Message-ID: <E1GwYRQ-0003Qf-Ru@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:08

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check  
                        Tag: remoting_2_x InvokerClientTest.java
                        InvokerServerTest.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerClientTest.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- InvokerClientTest.java	14 May 2006 05:29:59 -0000	1.1
  +++ InvokerClientTest.java	19 Dec 2006 06:27:08 -0000	1.1.4.1
  @@ -28,7 +28,7 @@
            String trustStoreFilePath = this.getClass().getResource("../.truststore").getFile();
            System.setProperty("javax.net.ssl.trustStore", trustStoreFilePath);
   
  -         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE);
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + getPort() + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE);
            client = new Client(locator, "mock");
            client.connect();
         }
  @@ -64,6 +64,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private Object makeInvocation(String method, String param) throws Throwable
      {
         Object ret = client.invoke(new NameBasedInvocation(method,
  
  
  
  1.2.4.1   +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerServerTest.java,v
  retrieving revision 1.2
  retrieving revision 1.2.4.1
  diff -u -b -r1.2 -r1.2.4.1
  --- InvokerServerTest.java	16 May 2006 03:45:44 -0000	1.2
  +++ InvokerServerTest.java	19 Dec 2006 06:27:08 -0000	1.2.4.1
  @@ -30,13 +30,14 @@
    */
   public class InvokerServerTest extends ServerTestCase implements SSLInvokerConstants
   {
  -   private int serverPort = port;
  +   private int serverPort;
      private Connector connector = null;
   
      private static final Logger log = Logger.getLogger(InvokerServerTest.class);
   
      public void init(Map metatdata) throws Exception
      {
  +      serverPort = getPort();
         if (serverPort < 0)
         {
            serverPort = TestUtil.getRandomPort();
  @@ -60,6 +61,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private ServerSocketFactory createServerSocketFactory()
            throws NoSuchAlgorithmException, KeyManagementException, IOException,
                   CertificateException, UnrecoverableKeyException, KeyStoreException
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/deadlock
	...
Message-ID: <E1GwYRR-0003Qq-0O@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:09

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/deadlock 
                        Tag: remoting_2_x ShutdownDeadlockTestCase.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/deadlock/ShutdownDeadlockTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ShutdownDeadlockTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/deadlock/ShutdownDeadlockTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- ShutdownDeadlockTestCase.java	15 Aug 2006 15:57:08 -0000	1.1
  +++ ShutdownDeadlockTestCase.java	19 Dec 2006 06:27:08 -0000	1.1.4.1
  @@ -32,7 +32,7 @@
    */
   public class ShutdownDeadlockTestCase extends TestCase
   {
  -   private static String invokerLocatorUrl = "socket://localhost:7798/?" + InvokerLocator.FORCE_REMOTE + "=true";
  +   private String invokerLocatorUrl = getTransport() + "://localhost:" + getPort() + "/?" + InvokerLocator.FORCE_REMOTE + "=true";
   
      private Client shutdownClient;
      private Client invocationClient;
  @@ -138,6 +138,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return 7798;
  +   }
  +   
      public class TestInvocationHandler implements ServerInvocationHandler
      {
   
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic
	...
Message-ID: <E1GwYRR-0003R4-5Z@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:09

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/basic  
                        Tag: remoting_2_x InvokerServerTest.java
                        InvokerClientTest.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.10.4.1  +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerServerTest.java,v
  retrieving revision 1.10
  retrieving revision 1.10.4.1
  diff -u -b -r1.10 -r1.10.4.1
  --- InvokerServerTest.java	16 May 2006 03:45:44 -0000	1.10
  +++ InvokerServerTest.java	19 Dec 2006 06:27:09 -0000	1.10.4.1
  @@ -50,13 +50,14 @@
    */
   public class InvokerServerTest extends ServerTestCase implements SSLInvokerConstants
   {
  -   private int serverPort = port;
  +   private int serverPort;
      private Connector connector = null;
   
      private static final Logger log = Logger.getLogger(InvokerServerTest.class);
   
      public void init(Map metatdata) throws Exception
      {
  +      serverPort = getPort();
         if(serverPort < 0)
         {
            serverPort = TestUtil.getRandomPort();
  @@ -80,6 +81,11 @@
         return transport;
      }
      
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      private ServerSocketFactory createServerSocketFactory()
            throws NoSuchAlgorithmException, KeyManagementException, IOException,
                   CertificateException, UnrecoverableKeyException, KeyStoreException
  
  
  
  1.5.6.1   +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerClientTest.java,v
  retrieving revision 1.5
  retrieving revision 1.5.6.1
  diff -u -b -r1.5 -r1.5.6.1
  --- InvokerClientTest.java	28 Mar 2006 02:43:49 -0000	1.5
  +++ InvokerClientTest.java	19 Dec 2006 06:27:09 -0000	1.5.6.1
  @@ -50,7 +50,7 @@
            String trustStoreFilePath = this.getClass().getResource("../.truststore").getFile();
            System.setProperty("javax.net.ssl.trustStore", trustStoreFilePath);
   
  -         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + port);
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + getPort());
            client = new Client(locator, "mock");
            client.connect();
         }
  @@ -86,6 +86,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private Object makeInvocation(String method, String param) throws Throwable
      {
         Object ret = client.invoke(new NameBasedInvocation(method,
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh
	...
Message-ID: <E1GwYRR-0003RI-A6@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:09

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh  
                        Tag: remoting_2_x TestServer.java TestClient.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.7.4.1   +26 -26    JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestServer.java,v
  retrieving revision 1.7
  retrieving revision 1.7.4.1
  diff -u -b -r1.7 -r1.7.4.1
  --- TestServer.java	26 Jul 2006 16:28:45 -0000	1.7
  +++ TestServer.java	19 Dec 2006 06:27:09 -0000	1.7.4.1
  @@ -8,8 +8,7 @@
   import org.jboss.remoting.callback.InvokerCallbackHandler;
   import org.jboss.remoting.security.SSLSocketBuilder;
   import org.jboss.remoting.transport.Connector;
  -import org.jboss.remoting.transport.sslsocket.SSLSocketServerInvoker;
  -
  +import org.jboss.remoting.transport.socket.SocketServerInvoker;
   import javax.management.MBeanServer;
   import javax.management.MBeanServerFactory;
   import javax.management.ObjectName;
  @@ -36,15 +35,15 @@
    */
   public class TestServer extends ServerTestCase{
   	
  -	private String localHost="127.0.0.1";
  -	private String keyStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverKeyStore";
  -	private String trustStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverTrustStore";
  -	private String keyStorePassword="testpw";
  -	private String trustStorePassword="testpw";
  -	private String port="2001";
  -	private Connector connector;
  -	private MBeanServer server;
  -	private static boolean invocationDone=false;
  +   protected String localHost="127.0.0.1";
  +   protected String keyStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverKeyStore";
  +   protected String trustStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverTrustStore";
  +   protected String keyStorePassword="testpw";
  +   protected String trustStorePassword="testpw";
  +   protected String port="2001";
  +   protected Connector connector;
  +   protected MBeanServer server;
  +   protected static boolean invocationDone=false;
   	
   	public void setUp(){	
   		
  @@ -67,7 +66,7 @@
   			configuration.put(SSLSocketBuilder.REMOTING_TRUST_STORE_ALGORITHM, "SunX509");
   		    connector = new Connector(configuration);
   			
  -		    InvokerLocator locator = new InvokerLocator("sslsocket://"+localHost+":"+port);
  +		    InvokerLocator locator = new InvokerLocator(getTransport() + "://"+localHost+":"+port);
   		    connector.setInvokerLocator(locator.getLocatorURI());
   			connector.create();
   			
  @@ -77,8 +76,8 @@
   				ServerSocketFactory svrSocketFactory = createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,trustStorePath);
   				
   				// notice that the invoker has to be explicitly cast to the
  -				// SSLSocketServerInvoker type								
  -				SSLSocketServerInvoker socketSvrInvoker = (SSLSocketServerInvoker) connector.getServerInvoker();
  +				// SocketServerInvoker type								
  +				SocketServerInvoker socketSvrInvoker = (SocketServerInvoker) connector.getServerInvoker();
   				socketSvrInvoker.setServerSocketFactory(svrSocketFactory);
   			}
   			catch(Exception e){
  @@ -104,18 +103,15 @@
   		connector.stop();
   	   }
   	
  -	/**
  -	 * @throws Exception
  -	 */
  +
   	public void test() throws Exception
      {
   		while(!invocationDone)
         {
   			Thread.sleep(1000);
   		}
  -		//((SSLSocketServerInvoker) connector.getServerInvoker()).setNewServerSocketFactory(createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,"src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverTrustStore2"));
         String keyStorePath2 = this.getClass().getResource("certificate/serverTrustStore2").getFile();
  -      ((SSLSocketServerInvoker) connector.getServerInvoker()).setNewServerSocketFactory(createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,keyStorePath2));
  +	   ((SocketServerInvoker) connector.getServerInvoker()).setNewServerSocketFactory(createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,keyStorePath2));
   		Thread.sleep(20000);//let client build up connection a second time
   	}
   
  @@ -133,6 +129,10 @@
         }
      }
   
  +    protected String getTransport()
  +    {
  +       return "sslsocket";
  +    }
   
      /**
   	 * @author Michael Voss
  
  
  
  1.5.4.1   +8 -4      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestClient.java,v
  retrieving revision 1.5
  retrieving revision 1.5.4.1
  diff -u -b -r1.5 -r1.5.4.1
  --- TestClient.java	7 Jul 2006 18:47:43 -0000	1.5
  +++ TestClient.java	19 Dec 2006 06:27:09 -0000	1.5.4.1
  @@ -23,7 +23,7 @@
   	Map configuration;
   	
   	public void setUp() throws Exception{
  -		locator=new InvokerLocator("sslsocket://localHost:2001");
  +		locator=new InvokerLocator(getTransport() + "://localHost:2001");
   		
   		//the client side connection endpoint
   		configuration = new HashMap();
  @@ -52,9 +52,10 @@
   	public void tearDown() throws Exception{
   		Thread.sleep(10000);//let the server fetch his new truststore and refresh serversocket
   		client.disconnect();
  -		Thread.sleep(5000);
  -		setUp();//secondPass -> client is not accepted by new truststore
  +		Thread.sleep(10000);
  +
   		try {
  +            setUp();//secondPass -> client is not accepted by new truststore
   			test();//secondPass -> client is not accepted by new truststore
   		} catch (Throwable e) {
   			client.disconnect();
  @@ -73,6 +74,9 @@
   		System.err.println("Server answer is: "+client.invoke("something"));
   	}
   	
  -	
  +	protected String getTransport()
  +	{
  +	   return "sslsocket";
  +	}
   	
   }
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry
	...
Message-ID: <E1GwYRR-0003RW-F7@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:09

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/retry  
                        Tag: remoting_2_x SocketRetryClient.java
                        SocketRetryServer.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.4.1   +10 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketRetryClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryClient.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- SocketRetryClient.java	14 May 2006 05:29:57 -0000	1.1
  +++ SocketRetryClient.java	19 Dec 2006 06:27:09 -0000	1.1.4.1
  @@ -66,7 +66,7 @@
   
         public void makeCalls(int sleepTime, int numOfCalls) throws Throwable
         {
  -         InvokerLocator locator = new InvokerLocator("socket://localhost:8888" + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://localhost:" + getPort() + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
                                                        SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.FALSE);
            Client client = new Client(locator);
            client.connect();
  @@ -116,4 +116,13 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return 8888;
  +   }
   }
  
  
  
  1.1.4.1   +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketRetryServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryServer.java,v
  retrieving revision 1.1
  retrieving revision 1.1.4.1
  diff -u -b -r1.1 -r1.1.4.1
  --- SocketRetryServer.java	14 May 2006 05:29:57 -0000	1.1
  +++ SocketRetryServer.java	19 Dec 2006 06:27:09 -0000	1.1.4.1
  @@ -21,7 +21,7 @@
   
      public void setUp() throws Exception
      {
  -      String locatorUri = "socket://localhost:8888" + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
  +      String locatorUri = getTransport() + "://localhost:" + getPort() + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
                             SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.FALSE;
   
         connector = new Connector(locatorUri);
  @@ -59,6 +59,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return 8888;
  +   }
  +   
      public class TestInvocationHandler implements ServerInvocationHandler
      {
   
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool
	...
Message-ID: <E1GwYRR-0003Rk-K4@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:09

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/socketpool  
                        Tag: remoting_2_x SocketPoolTestServer.java
                        SocketPoolTestClient.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +12 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketPoolTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestServer.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- SocketPoolTestServer.java	3 Nov 2006 04:04:00 -0000	1.1.2.2
  +++ SocketPoolTestServer.java	19 Dec 2006 06:27:09 -0000	1.1.2.3
  @@ -38,7 +38,7 @@
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
    * 
  - * @version $Revision: 1.1.2.2 $
  + * @version $Revision: 1.1.2.3 $
    * <p>
    * Copyright Nov 2, 2006
    * </p>
  @@ -114,7 +114,7 @@
   
      public void setUp() throws Exception
      {
  -      String locatorURI = transport + "://" + host + ":" + port;
  +      String locatorURI = getTransport() + "://" + host + ":" + getPort();
         setupServer(locatorURI);
      }
   
  @@ -155,6 +155,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      /**
       * Simple invocation handler implementation.
       * This is the code that will be called with the invocation payload from the client.
  
  
  
  1.1.2.4   +12 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketPoolTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestClient.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- SocketPoolTestClient.java	9 Nov 2006 02:25:03 -0000	1.1.2.3
  +++ SocketPoolTestClient.java	19 Dec 2006 06:27:09 -0000	1.1.2.4
  @@ -34,7 +34,7 @@
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
    * 
  - * @version $Revision: 1.1.2.3 $
  + * @version $Revision: 1.1.2.4 $
    * <p>
    * Copyright Nov 2, 2006
    * </p>
  @@ -57,7 +57,7 @@
         {
            log.warn("EXCEPTIONS ARE EXPECTED");
   
  -         String locatorURI = transport + "://" + host + ":" + port + "/?timeout=1000";
  +         String locatorURI = getTransport() + "://" + host + ":" + getPort() + "/?timeout=1000";
            log.info("Calling remoting server with locator uri of: " + locatorURI);
   
            // create InvokerLocator with the url type string
  @@ -124,6 +124,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      class Invoker extends Thread
      {
         private Client client;
  
  
  


From ron_sigal at yahoo.com  Tue Dec 19 01:27:09 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Tue, 19 Dec 2006 01:27:09 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder
	...
Message-ID: <E1GwYRR-0003Ry-Oq@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/19 01:27:09

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/builder  
                        Tag: remoting_2_x SSLSocketInvokerTestServer.java
                        SSLSocketInvokerTestClient.java
  Log:
  JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.3.4.1   +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLSocketInvokerTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestServer.java,v
  retrieving revision 1.3
  retrieving revision 1.3.4.1
  diff -u -b -r1.3 -r1.3.4.1
  --- SSLSocketInvokerTestServer.java	26 May 2006 20:26:56 -0000	1.3
  +++ SSLSocketInvokerTestServer.java	19 Dec 2006 06:27:09 -0000	1.3.4.1
  @@ -29,7 +29,7 @@
    */
   public class SSLSocketInvokerTestServer extends ServerTestCase implements SSLInvokerConstants
   {
  -   private int serverPort = port;
  +   private int serverPort;
      private Connector connector = null;
      private SSLSocketBuilder socketBuilder = null;
   
  @@ -37,6 +37,7 @@
   
      public void init() throws Exception
      {
  +      serverPort = getPort();
         if (serverPort < 0)
         {
            serverPort = TestUtil.getRandomPort();
  @@ -117,6 +118,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      protected String getSubsystem()
      {
         return "mock";
  
  
  
  1.4.4.1   +7 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLSocketInvokerTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestClient.java,v
  retrieving revision 1.4
  retrieving revision 1.4.4.1
  diff -u -b -r1.4 -r1.4.4.1
  --- SSLSocketInvokerTestClient.java	20 Jun 2006 17:19:00 -0000	1.4
  +++ SSLSocketInvokerTestClient.java	19 Dec 2006 06:27:09 -0000	1.4.4.1
  @@ -44,12 +44,12 @@
         System.setProperty("javax.net.ssl.trustStorePassword", "unit-tests-client");
   //         System.setProperty("javax.net.ssl.trustStorePassword", "secureexample");
   
  -      InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + port);
  +      InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + getPort());
   
         // create callback connector
         Map config = new HashMap();
         config.put(SSLSocketBuilder.REMOTING_SERVER_SOCKET_USE_CLIENT_MODE, "true");
  -      callbackConnector = new Connector(getTransport() + "://" + host + ":" + (port + 5), config);
  +      callbackConnector = new Connector(getTransport() + "://" + host + ":" + (getPort() + 5), config);
         callbackConnector.create();
         callbackConnector.addInvocationHandler("callback", new CallbackInvokerHandler());
         callbackConnector.start();
  @@ -99,6 +99,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private Object makeInvocation(String method, String param) throws Throwable
      {
         Object ret = client.invoke(new NameBasedInvocation(method,
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 01:28:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 01:28:26 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1822 -
	trunk/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GwYSg-0003SG-UN@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 01:28:23 -0500 (Tue, 19 Dec 2006)
New Revision: 1822

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
Just adding a commented out test from a deleted class, as this test will be reactivated later

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-19 06:25:37 UTC (rev 1821)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-19 06:28:23 UTC (rev 1822)
@@ -260,6 +260,7 @@
       ServerManagement.kill(1);
 
       Thread.sleep(30000);
+      // if failover happened, this object was replaced
       assertNotSame(originalRemoting, delegate.getRemotingConnection());
 
       //System.out.println("Kill server1"); Thread.sleep(10000);
@@ -272,17 +273,8 @@
       System.out.println("TransactionID on client = " + txID);
       log.info(">>Final commit");
 
-      /* JBossConnection connSecondServer = (JBossConnection)this.factoryServer2.createConnection();
-       connSecondServer.start();
-       JBossSession sessionSecondServer = (JBossSession)connSecondServer.createSession(false,Session.AUTO_ACKNOWLEDGE);
-       MessageConsumer consumerSecondServer = sessionSecondServer.createConsumer(destination); */
-
       session.commit();
 
-      /* receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-     receiveMessage("consumerSecondServer",consumerSecondServer,true,false);
-     receiveMessage("consumerSecondServer",consumerSecondServer,true,true); */
-
       log.info("Calling alternate receiver");
       receiveMessage("consumerHA", consumerHA, true, false);
       receiveMessage("consumerHA", consumerHA, true, false);
@@ -297,6 +289,95 @@
    }
 
 
+//   public void testQueueHA() throws Exception
+//   {
+//       log.info("++testTopicSubscriber");
+//
+//       log.info(">>Lookup Queue");
+//       Destination destination = (Destination)getCtx1().lookup("queue/testDistributedQueue");
+//
+//       log.info("Creating connection server1");
+//       JBossConnection  conn = (JBossConnection)this.factoryServer1.createConnection();
+//       conn.setClientID("testClient");
+//       conn.start();
+//
+//       JBossSession session = (JBossSession)conn.createSession(true,Session.AUTO_ACKNOWLEDGE);
+//       ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate)session.getDelegate();
+//       SessionState sessionState = (SessionState)clientSessionDelegate.getState();
+//
+//       MessageConsumer consumerHA = session.createConsumer(destination);
+//       JBossMessageConsumer jbossConsumerHA =(JBossMessageConsumer)consumerHA;
+//
+//       org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate)jbossConsumerHA.getDelegate();
+//       ConsumerState consumerState = (ConsumerState)clientDelegate.getState();
+//
+//       log.info("subscriptionName=" + consumerState.getSubscriptionName());
+//
+//
+//       log.info(">>Creating Producer");
+//       MessageProducer producer = session.createProducer(destination);
+//       log.info(">>creating Message");
+//       Message message = session.createTextMessage("Hello Before");
+//       log.info(">>sending Message");
+//       producer.send(message);
+//       session.commit();
+//
+//       session.commit();
+//       //if (true) return;
+//
+//       Object txID = sessionState.getCurrentTxId();
+//
+//       ClientConnectionDelegate delegate = (ClientConnectionDelegate)conn.getDelegate();
+//
+//       JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
+//
+//       log.info(">>Creating alternate connection");
+//       JBossConnection conn2 = (JBossConnection)this.factoryServer2.createConnection();
+//       log.info("NewConnectionCreated=" + conn2);
+//
+//       log.info(">>Failling over");
+//       assertSame(originalRemoting,delegate.getRemotingConnection());
+//       conn.getDelegate().failOver(conn2.getDelegate());
+//
+//       try {
+//           originalRemoting.stop();
+//       } catch (Throwable throwable) {
+//           throwable.printStackTrace();
+//       }
+//
+//
+//       assertNotSame(originalRemoting,delegate.getRemotingConnection());
+//
+//       //System.out.println("Kill server1"); Thread.sleep(10000);
+//       assertEquals(txID,sessionState.getCurrentTxId());
+//       System.out.println("TransactionID on client = " + txID);
+//       log.info(">>Final commit");
+//
+//       session.commit();
+//
+//       log.info("Calling alternate receiver");
+//       receiveMessage("consumerHA",consumerHA,true,false);
+//       receiveMessage("consumerHA",consumerHA,true,true);
+//
+//       session.commit();
+//
+//       for (int i=0;i<30;i++)
+//       {
+//          log.info("Message Sent " + i);
+//          producer.send(session.createTextMessage("Message " + i));
+//       }
+//      session.commit();
+//
+//      Thread.sleep(5000);
+//
+//       TextMessage messageLoop = null;
+//       while (!((messageLoop = (TextMessage) consumerHA.receive(5000)) == null))
+//       {
+//          log.info("Message received = " + messageLoop.getText());
+//       }
+//
+//   }
+
    /*
     * Test that the failover mapping is created correctly and updated properly when nodes leave
     * or join



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 01:51:05 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 01:51:05 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1823 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/remoting
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
Message-ID: <E1GwYob-0003le-78@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 01:51:01 -0500 (Tue, 19 Dec 2006)
New Revision: 1823

Modified:
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
   trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Log:
Adding Valve and few other fixes

Modified: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-19 06:28:23 UTC (rev 1822)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-19 06:51:01 UTC (rev 1823)
@@ -27,12 +27,14 @@
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.messaging.util.Valve;
+import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.CannotConnectException;
 import org.jboss.remoting.ConnectionListener;
 import org.jboss.remoting.Client;
 import java.io.IOException;
+import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.ReentrantWriterPreferenceReadWriteLock;
 
 /**
  * This aspect will intercept failures from any HA object.
@@ -56,12 +58,15 @@
 
    private ClientConnectionDelegate delegate;
 
-   private Valve valve = new Valve();
+   // alternative implementation
+   //private Valve valve = new Valve();
+   private ReadWriteLock lockValve;
 
    ValveAspect(ClientConnectionDelegate delegate, HAAspect copy)
    {
       super(copy);
       this.delegate = delegate;
+      lockValve = new ReentrantWriterPreferenceReadWriteLock();
 
       ConnectionListener listener = new ConnectionFailureListener(delegate);
 
@@ -91,14 +96,37 @@
       // Eventually retries in case of listed exceptions
       for (int i = 0; i < MAX_IO_RETRY_COUNT; i++)
       {
-         // We shouldn't have any calls being made while the failover is being executed
-         valve.isOpened(true);
 
          if (i > 0)
          {
             log.info("Retrying a call " + i);
          }
+
+
+         // An alternate way of playing with Valves is to set an attribute to true
+         // and wait for notifications until it's being set. Valve encpasulates this logic
+         //  if (i > 0)
+         //  {
+         //     valve.open(true);
+         //  }
+         //  else
+         //  {
+         //     valve.isOpened(true);
+         //  }
+
+         // We shouldn't have any calls being made while the failover is being executed
+         if (i > 0)
+         {
+            // On retries we will use writeLocks, as the failover was already being processed
+            lockValve.writeLock().acquire();
+         }
+         else
+         {
+            lockValve.readLock().acquire();
+         }
+
          failure = false;
+
          try
          {
             returnObject = invocation.invokeNext();
@@ -118,6 +146,23 @@
             log.error("ValveAspect didn't catch the exception " + e + ", and it will be forwarded", e);
             throw e;
          }
+         finally
+         {
+            // An alternate way of playing with Valves is to set an attribute to true
+            // and wait for notifications until it's being set. Valve encpasulates this logic
+            //if (i>0)
+            //{
+            //   valve.reset();
+            //}
+            if (i > 0)
+            {
+               lockValve.writeLock().release();
+            }
+            else
+            {
+               lockValve.readLock().release();
+            }
+         }
 
          if (!failure)
          {
@@ -128,7 +173,7 @@
 
       if (failure)
       {
-         handleConnectionFailure(delegate);
+         handleConnectionFailure(delegate, delegate.getRemotingConnection());
          // if on the end we still have an exception there is nothing we can do besides throw an exception
          // so, no retires on the failedOver Invocation
          returnObject = invocation.invokeNext();
@@ -151,37 +196,48 @@
     * it will just return all the others as soon as the valve is closed. This way all the simultaneous failures will
     * act as they were processed while we called failover only once.
     */
-   protected void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate) throws Exception
+   protected void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate,
+                                          JMSRemotingConnection jmsConnection) throws Exception
    {
-      Valve localValve = null;
+      log.info("Processing handleConnectionFailure ");
 
-      // The idea is to reset the Valve synchronized with a reset valve
-      synchronized (this) // I'm not sure if this synchronized is necessary. I will keep it here just to be safe
-      {
-         localValve = valve;
-      }
+      // only one execution should be performed if multiple exceptions happened at the same time
+      lockValve.writeLock().acquire();
 
-      // only one execution should be performed if multiple exceptions happened at the same time
-      if (localValve.open())
+      // An alternate way of playing with Valves is to set an attribute to true
+      // and wait for notifications until it's being set. Valve encpasulates this logic
+//      if (!valve.open())
+//      {
+//         return;
+//      }
+
+      try
       {
-         try
+         if (jmsConnection.isFailed())
          {
-            log.info("Processing valve on exception failure");
-            super.handleConnectionFailure(failedConnDelegate);
+            log.info("Failover on " + failedConnDelegate + " was already performed, so just ignoring call to handleConnectionFailure");
+            return;
          }
-         finally
-         {
-            localValve.close();
-            synchronized (this)
-            {
-               // reset the valve, so future exceptions will also get processed
-               valve = new Valve();
-            }
-         }
-      } else
+
+         log.info("Processing valve on exception failure");
+         jmsConnection.setFailed(true);
+         super.handleConnectionFailure(failedConnDelegate);
+         log.info("Failover on client finished");
+      }
+      catch (Exception e)
       {
-         log.info("The valve was closed, so this invocation waited another invocation to finish on handleFailure");
+         log.error("An exception happened during client failover processing!", e);
+         throw e;
       }
+      finally
+      {
+         // An alternate way of playing with Valves is to set an attribute to true
+         // and wait for notifications until it's being set. Valve encpasulates this logic
+//         valve.close();
+//         valve = new Valve();
+         lockValve.writeLock().release();
+      }
+
    }
 
    // Inner classes -------------------------------------------------
@@ -208,7 +264,7 @@
          try
          {
             log.debug(this + " is being notified of connection failure: " + throwable);
-            handleConnectionFailure(cd);
+            handleConnectionFailure(cd, cd.getRemotingConnection());
          }
          catch (Throwable e)
          {

Modified: trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-19 06:28:23 UTC (rev 1822)
+++ trunk/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-19 06:51:01 UTC (rev 1823)
@@ -61,6 +61,9 @@
    protected InvokerLocator serverLocator;
    protected CallbackManager callbackManager;
 
+   /** When a failover is performed, this flag is set to true */
+   protected boolean failed=false;
+
    // Constructors --------------------------------------------------
 
    public JMSRemotingConnection(String serverLocatorURI, boolean clientPing) throws Throwable
@@ -183,6 +186,17 @@
       return callbackManager;
    }
 
+
+   public boolean isFailed()
+   {
+      return failed;
+   }
+
+   public void setFailed(boolean failed)
+   {
+      this.failed = failed;
+   }
+
    public String toString()
    {
       return "JMSRemotingConnection[" + serverLocator.getLocatorURI() + "]";

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-19 06:28:23 UTC (rev 1822)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-19 06:51:01 UTC (rev 1823)
@@ -25,6 +25,8 @@
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.logging.Logger;
 import javax.jms.MessageConsumer;
 import javax.jms.Session;
@@ -49,8 +51,8 @@
       super(name);
    }
 
-   int messageCounterConsumer =0;
-   int messageCounterProducer=0;
+   int messageCounterConsumer = 0;
+   int messageCounterProducer = 0;
 
 
    Object lockReader = new Object();
@@ -88,12 +90,12 @@
             int counter = 0;
             while (true)
             {
-               Message message = consumer.receive(50);
-               if (message==null && shouldStop)
+               Message message = consumer.receive(5000);
+               if (message == null && shouldStop)
                {
                   break;
                }
-               if (message!=null)
+               if (message != null)
                {
                   synchronized (lockReader)
                   {
@@ -103,11 +105,11 @@
                   if (counter++ % 10 == 0)
                   {
                      //log.info("Commit on id=" + id);
-                     session.commit();
+                     //session.commit();
                   }
                }
             }
-            session.commit();
+            //session.commit();
          }
          catch (Exception e)
          {
@@ -154,7 +156,7 @@
                if (counter++ % 5 == 0)
                {
                   //log.info("Committing message");
-                  session.commit();
+                  //session.commit();
                }
             }
 
@@ -173,15 +175,36 @@
    public void testMultiThreadFailover() throws Exception
    {
       JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
-      Connection conn = factory.createConnection();
+
+      Connection conn1 = cf.createConnection();
+      Connection conn2 = cf.createConnection();
+      Connection conn3 = cf.createConnection();
+
+      log.info("Created connections");
+
+      checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
+
+      Connection conn = getConnection(new Connection[]{conn1, conn2, conn3}, 1);
       conn.start();
 
+      for (int i = 0; i < 3; i++)
+      {
+         JBossConnection connTest = (JBossConnection)getConnection(new Connection[]{conn1, conn2, conn3}, i);
+
+         String locator = ((ClientConnectionDelegate) connTest.getDelegate()).getRemotingConnection().
+            getInvokingClient().getInvoker().getLocator().getLocatorURI();
+
+         log.info("Server " + i + " has locator=" + locator);
+
+      }
+
+
       ArrayList list = new ArrayList();
 
       for (int i = 0; i < 5; i++)
       {
-         list.add(new LocalThreadProducer(i, conn.createSession(true, Session.AUTO_ACKNOWLEDGE), queue[1]));
-         list.add(new LocalThreadConsumer(i, conn.createSession(true, Session.AUTO_ACKNOWLEDGE), queue[1]));
+         list.add(new LocalThreadProducer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
+         list.add(new LocalThreadConsumer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
       }
 
       for (Iterator iter = list.iterator(); iter.hasNext();)
@@ -199,11 +222,15 @@
       Thread.sleep(30000);
 
       log.info("Killing server 1");
+      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed");
+      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed", 2);
+      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
 
       ServerManagement.kill(1);
 
       Thread.sleep(50000);
-      shouldStop=true;
+      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+      shouldStop = true;
 
       for (Iterator iter = list.iterator(); iter.hasNext();)
       {
@@ -211,7 +238,7 @@
          t.join();
       }
 
-      log.info("produced " + messageCounterProducer + " and read " + messageCounterConsumer);
+      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
 
       assertEquals(messageCounterProducer, messageCounterConsumer);
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-19 06:28:23 UTC (rev 1822)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-19 06:51:01 UTC (rev 1823)
@@ -130,6 +130,24 @@
       super.tearDown();
    }
 
+   // lookup for the connection with the right serverID
+   // I'm using this method to find the proper serverId so I won't relay on loadBalancing policies on testcases
+   protected Connection getConnection(Connection[] conn, int serverId) throws Exception
+   {
+      for(int i = 0; i < conn.length; i++)
+      {
+         ConnectionState state = (ConnectionState)(((DelegateSupport)((JBossConnection)conn[i]).
+            getDelegate()).getState());
+
+         if (state.getServerID() == serverId)
+         {
+            return conn[i];
+         }
+      }
+
+      return null;
+   }
+
    protected void checkConnectionsDifferentServers(Connection[] conn) throws Exception
    {
       int[] serverID = new int[conn.length];



From fd987gfd546 at doramail.com  Tue Dec 19 02:00:30 2006
From: fd987gfd546 at doramail.com (fd987gfd546 at doramail.com)
Date: Tue, 19 Dec 2006 02:00:30 -0500
Subject: [jboss-cvs] =?utf-8?b?wpHDksKCwr/CjcKHwoLDrcKCwrnCgsK1woLDhMKJ?=
	=?utf-8?b?w6/CgsOtwoLDiMKCwqLCgUjCgsKywpTDkcKaw7jCgsOpwoLDpsKBw7Q=?=
Message-ID: 20040414224820.19640mail@mail.qweoirugyksjadfgythdeiwowlsksdnsnhjdhdfb.com

?????d?????????????H???????I?????[?H
?????????????H?????s????????
?????????????}?????????????I
???????O???t???t?????????????A?g???????????[?????????????H
http://www.freeweb.allfreemail.net.tonderuyo.com/freemails/
???????A?h???X?m?F????????






From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 02:57:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 02:57:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r59128 -
	projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context
Message-ID: <E1GwZrJ-0004n1-2H@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 02:57:54 -0500 (Tue, 19 Dec 2006)
New Revision: 59128

Modified:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java
Log:
Fix the hasBeenModified check to not return true on the first call.

Modified: projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java	2006-12-19 03:40:50 UTC (rev 59127)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractVirtualFileHandler.java	2006-12-19 07:57:54 UTC (rev 59128)
@@ -110,13 +110,14 @@
 
    public boolean hasBeenModified() throws IOException
    {
+      boolean hasBeenModified = false;
       long last = getLastModified();
       if (cachedLastModified != last)
       {
+         hasBeenModified = cachedLastModified != 0;
          cachedLastModified = last;
-         return true;
       }
-      return false;
+      return hasBeenModified;
    }
 
 
@@ -337,11 +338,13 @@
       return true;
    }
 
+   /*
    @Override
    protected void finalize() throws Throwable
    {
       close();
    }
+   */
    
    /**
     * Safely get a url version of the string



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 03:03:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 03:03:31 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59129 - projects/vfs/trunk
Message-ID: <E1GwZwh-00051h-FK@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 03:03:27 -0500 (Tue, 19 Dec 2006)
New Revision: 59129

Modified:
   projects/vfs/trunk/pom.xml
Log:
Set the version to 2.0.0.Beta2

Modified: projects/vfs/trunk/pom.xml
===================================================================
--- projects/vfs/trunk/pom.xml	2006-12-19 07:57:54 UTC (rev 59128)
+++ projects/vfs/trunk/pom.xml	2006-12-19 08:03:27 UTC (rev 59129)
@@ -4,7 +4,7 @@
   <groupId>jboss</groupId>
   <artifactId>jboss-vfs</artifactId>
   <packaging>jar</packaging>
-  <version>2.0.4.snapshot</version>
+  <version>2.0.0.Beta2</version>
   <name>JBoss VFS</name>
   <url>http://www.jboss.org</url>
   <description>A set of commonly used classed classes</description>



From scott.stark at jboss.com  Tue Dec 19 03:05:14 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 19 Dec 2006 03:05:14 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jboss-vfs - New directory ...
Message-ID: <E1GwZyM-00053N-CQ@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/19 03:05:14

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/jboss-vfs added to the repository


From scott.stark at jboss.com  Tue Dec 19 03:05:23 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 19 Dec 2006 03:05:23 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2 - New
	directory ...
Message-ID: <E1GwZyV-000542-7G@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/19 03:05:23

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2 added to the repository


From scott.stark at jboss.com  Tue Dec 19 03:05:35 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 19 Dec 2006 03:05:35 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2/lib -
	New directory ...
Message-ID: <E1GwZyh-00054s-9X@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/19 03:05:35

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2/lib added to the repository


From scott.stark at jboss.com  Tue Dec 19 03:06:28 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 19 Dec 2006 03:06:28 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2  ...
Message-ID: <E1GwZzY-00056K-VN@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/19 03:06:28

  Added:       jboss/jboss-vfs/2.0.0.Beta2  component-info.xml
  Log:
  A separate 2.0.0.Beta2 release of the vfs
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 08:06:28;  author: starksm;  state: Exp;repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-vfs-component-info">
  
     <!-- ============================================================ -->
     <!-- jboss/test                                                      -->
     <!-- ============================================================ -->
  
     <component id="jboss/jboss-vfs"
                version="2.0.0.Beta2"
                licenseType="lgpl"
                description="A VFS library"
     >
        <artifact id="jboss-vfs.jar"/>
        <artifact id="jboss-vfs-sources.jar"/>
        <export>
           <include input="jboss-vfs.jar"/>
        </export>
     </component>
  </project>
  
  
  


From scott.stark at jboss.com  Tue Dec 19 03:06:29 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Tue, 19 Dec 2006 03:06:29 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2/lib ...
Message-ID: <E1GwZzZ-00056S-CM@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/19 03:06:29

  Added:       jboss/jboss-vfs/2.0.0.Beta2/lib   jboss-vfs-sources.jar
                        jboss-vfs.jar
  Log:
  A separate 2.0.0.Beta2 release of the vfs
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 08:06:29;  author: starksm;  state: Exp;repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2/lib/jboss-vfs-sources.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 08:06:29;  author: starksm;  state: Exp;repository.jboss.com/jboss/jboss-vfs/2.0.0.Beta2/lib/jboss-vfs.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 03:07:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 03:07:24 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59130 - projects/vfs
Message-ID: <E1Gwa0S-00056b-9h@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 03:07:22 -0500 (Tue, 19 Dec 2006)
New Revision: 59130

Added:
   projects/vfs/tags/
Log:
Release tags dir




From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 03:09:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 03:09:44 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59131 - projects/vfs/tags
Message-ID: <E1Gwa2i-00056v-S2@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 03:09:42 -0500 (Tue, 19 Dec 2006)
New Revision: 59131

Added:
   projects/vfs/tags/2.0.0.Beta2/
Log:
Tag the 2.0.0.Beta2 vfs release


Copied: projects/vfs/tags/2.0.0.Beta2 (from rev 59130, projects/vfs/trunk)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 03:10:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 03:10:36 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59132 - projects/vfs/trunk
Message-ID: <E1Gwa3Y-0005A9-U4@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 03:10:32 -0500 (Tue, 19 Dec 2006)
New Revision: 59132

Modified:
   projects/vfs/trunk/pom.xml
Log:
Set the trunk version to 2.0.0.snapshot

Modified: projects/vfs/trunk/pom.xml
===================================================================
--- projects/vfs/trunk/pom.xml	2006-12-19 08:09:42 UTC (rev 59131)
+++ projects/vfs/trunk/pom.xml	2006-12-19 08:10:32 UTC (rev 59132)
@@ -4,7 +4,7 @@
   <groupId>jboss</groupId>
   <artifactId>jboss-vfs</artifactId>
   <packaging>jar</packaging>
-  <version>2.0.0.Beta2</version>
+  <version>2.0.0.snapshot</version>
   <name>JBoss VFS</name>
   <url>http://www.jboss.org</url>
   <description>A set of commonly used classed classes</description>



From kkhan at jboss.com  Tue Dec 19 05:12:39 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Tue, 19 Dec 2006 05:12:39 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/1.5.3.beta1  ...
Message-ID: <E1Gwbxf-0007BE-BX@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/19 05:12:39

  Added:       jboss/aop/1.5.3.beta1  component-info.xml
  Log:
  Add 1.5.3.Beta1 for a customer
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-aop-component-info">
  
     <component id="jboss/aop"
        licenseType="lgpl"
        version="1.5.3.beta1"
        projectHome="http://www.jboss.org/products/aop"
        description="JBoss Aspect Oriented Programming">
  
        <artifact id="common-softvaluehashmap.jar"/>
        <artifact id="jboss-aop.jar"/>
        <artifact id="jboss-aop-jdk50.jar"/>
        <artifact id="jdk14-pluggable-instrumentor.jar"/>
        <artifact id="jboss-aop-jdk50-client.jar"/>
        <artifact id="jrockit-pluggable-instrumentor.jar"/>
        <!--artifact id="jboss-aspect-jdk50-client.jar"/>
        <artifact id="jboss-aop-jdk50.deployer"/>
        <artifact id="jboss-aop.deployer"/-->
        <artifact id="pluggable-instrumentor.jar"/>
        <import componentref="javassist">
           <compatible version="3.2.0.CR1"/>
           <compatible version="3.2.0.CR2"/>
           <compatible version="3.2.0.GA"/>
           <compatible version="3.3.0.GA"/>
           <compatible version="3.4.GA"/>
        </import>
        <export>
           <include input="common-softvaluehashmap.jar"/>
           <include input="jboss-aop.jar"/>
           <include input="jboss-aop-jdk50.jar"/>
           <include input="jdk14-pluggable-instrumentor.jar"/>
           <include input="jboss-aop-jdk50-client.jar"/>
           <include input="jrockit-pluggable-instrumentor.jar"/>
           <!--include input="jboss-aspect-jdk50-client.jar"/-->
           <include input="pluggable-instrumentor.jar"/>
        </export>
     </component>
  
  </project>
  
  
  
  


From kkhan at jboss.com  Tue Dec 19 05:12:39 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Tue, 19 Dec 2006 05:12:39 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/1.5.3.beta1/lib ...
Message-ID: <E1Gwbxf-0007BW-GY@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/19 05:12:39

  Added:       jboss/aop/1.5.3.beta1/lib        common-softvaluehashmap.jar
                        jboss-aop-jdk50-client.jar jboss-aop-jdk50.jar
                        jboss-aop.jar jdk14-pluggable-instrumentor.jar
                        jrockit-pluggable-instrumentor.jar
                        pluggable-instrumentor.jar
  Log:
  Add 1.5.3.Beta1 for a customer
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/common-softvaluehashmap.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/jboss-aop-jdk50-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/jboss-aop-jdk50.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/jboss-aop.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/jdk14-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/jrockit-pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 10:12:39;  author: kkhan;  state: Exp;repository.jboss.com/jboss/aop/1.5.3.beta1/lib/pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 05:21:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 05:21:28 -0500
Subject: [jboss-cvs] JBossAS SVN: r59133 - in branches/Branch_4_0: aspects
	aspects/src/main/org/jboss/aop/deployment build
	testsuite/imports/sections
	testsuite/src/main/org/jboss/test/aop/scoped
	testsuite/src/main/org/jboss/test/aop/scoped/excluded
	testsuite/src/main/org/jboss/test/aop/scoped/excluded/included
	testsuite/src/main/org/jboss/test/aop/test
	testsuite/src/resources/aop/scoped/sar1/META-INF
	testsuite/src/resources/aop/scoped/sar2/META-INF
Message-ID: <E1Gwc6C-0007KF-4I@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 05:21:16 -0500 (Tue, 19 Dec 2006)
New Revision: 59133

Added:
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java
Modified:
   branches/Branch_4_0/aspects/build.xml
   branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java
   branches/Branch_4_0/build/build-thirdparty.xml
   branches/Branch_4_0/testsuite/imports/sections/aop.xml
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java
   branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java
   branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml
   branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml
Log:
[JBAOP-331] IgnoreExpressions for a domain should be got from main AspectManager

Modified: branches/Branch_4_0/aspects/build.xml
===================================================================
--- branches/Branch_4_0/aspects/build.xml	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/aspects/build.xml	2006-12-19 10:21:16 UTC (rev 59133)
@@ -55,10 +55,10 @@
       &modules;
 
       <!-- Module name(s) & version -->
-   	<!--<property name="version.suffix" value="1.5.2.GA"/>
-      <property name="aspects.version" value="jboss-aspect-library-1.5"/>-->
-   	<property name="version.suffix" value="2.0.0.alpha1"/>
-      <property name="aspects.version" value="jboss-aspect-library-2.0"/>
+   	<property name="version.suffix" value="1.5.3.Beta1"/>
+      <property name="aspects.version" value="jboss-aspect-library-1.5"/>
+   	<!--property name="version.suffix" value="2.0.0.alpha1"/>
+      <property name="aspects.version" value="jboss-aspect-library-2.0"/-->
       <property name="aop.version" value="jboss-aop_${version.suffix}"/>
       <property name="aspects.title" value="JBoss AOP Aspect Library"/>
 

Modified: branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java
===================================================================
--- branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -263,10 +263,13 @@
    {
       this.exclude = exclude;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(exclude, ",");
-      while (tokenizer.hasMoreTokens())
+      if (exclude != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(exclude, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setExclude(list);
    }
@@ -280,10 +283,13 @@
    {
       this.include = include;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(include, ",");
-      while (tokenizer.hasMoreTokens())
+      if (include != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(include, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setInclude(list);
    }
@@ -297,10 +303,13 @@
    {
       this.ignore = ignore;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(ignore, ",");
-      while (tokenizer.hasMoreTokens())
+      if (ignore != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(ignore, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setIgnore(list);
    }

Modified: branches/Branch_4_0/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_0/build/build-thirdparty.xml	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/build/build-thirdparty.xml	2006-12-19 10:21:16 UTC (rev 59133)
@@ -84,8 +84,8 @@
       <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
       <componentref name="jacorb" version="2.2.4jboss.patch1"/>
       <componentref name="javassist" version="3.3.0.GA"/>
-      <componentref name="jaxen" version="1.1-beta-9"/>      
-      <componentref name="jboss/aop" version="1.5.2.GA"/>
+      <componentref name="jaxen" version="1.1-beta-9"/>
+      <componentref name="jboss/aop" version="1.5.3.beta1"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/cache" version="1.4.0.SP1"/>
       <componentref name="jboss/common" version="1.0.0.GA"/>

Modified: branches/Branch_4_0/testsuite/imports/sections/aop.xml
===================================================================
--- branches/Branch_4_0/testsuite/imports/sections/aop.xml	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/imports/sections/aop.xml	2006-12-19 10:21:16 UTC (rev 59133)
@@ -171,6 +171,7 @@
     <jar destfile="${build.lib}/aop-scopedtest1.aop">
       <fileset dir="${build.classes}">
         <include name="org/jboss/test/aop/scoped/*.class"/>
+        <include name="org/jboss/test/aop/scoped/excluded/**/*.class"/>
         <exclude name="org/jboss/test/aop/scoped/ScopedTester*.class"/>
       </fileset>
       <fileset dir="${build.resources}/aop/scoped/sar1">
@@ -191,6 +192,7 @@
     <jar destfile="${build.lib}/aop-scopedtest2.sar">
       <fileset dir="${build.classes}">
         <include name="org/jboss/test/aop/scoped/*.class"/>
+        <include name="org/jboss/test/aop/scoped/excluded/**/*.class"/>
       </fileset>
       <fileset dir="${build.resources}/aop/scoped/sar2/META-INF">
         <include name="scoped-aop.xml"/>

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class POJO$$Ignored$$123
+{
+
+}

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -21,6 +21,10 @@
  */
 package org.jboss.test.aop.scoped;
 
+import org.jboss.aop.Advised;
+import org.jboss.test.aop.scoped.excluded.ExcludedPOJO;
+import org.jboss.test.aop.scoped.excluded.included.IncludedPOJO;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -182,4 +186,28 @@
       }
    }
    
+   public void testInclude()
+   {
+      if (!Advised.class.isAssignableFrom(IncludedPOJO.class))
+      {
+         throw new RuntimeException("IncludedPOJO should be Advised");
+      }
+   }
+   
+   public void testExclude()
+   {
+      if (Advised.class.isAssignableFrom(ExcludedPOJO.class))
+      {
+         throw new RuntimeException("ExcludedPOJO should not be Advised");
+      }
+   }
+   
+   public void testIgnore()
+   {
+      if (Advised.class.isAssignableFrom(POJO$$Ignored$$123.class))
+      {
+         throw new RuntimeException("POJO$$Ignored$$123 should not be Advised");
+      }
+   }
+   
 }

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -38,4 +38,8 @@
    void testScoped() throws Exception;
    void testIntroduction1();
    void testIntroduction2();
+   
+   void testInclude();
+   void testExclude();
+   void testIgnore();
 }

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped.excluded;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ExcludedPOJO
+{
+
+}

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped.excluded.included;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class IncludedPOJO
+{
+
+}

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -40,6 +40,7 @@
    public static String ASPECT_MANAGER_NAME = "jboss.aop:service=AspectManager";
 
    private String[] jars;
+   SetupHook hook;
 
    // Create an initializer for the test suite
    public AOPClassLoaderHookTestSetup(TestSuite suite, String jar) throws Exception
@@ -48,12 +49,22 @@
       this.jars = jar.split(",");
    }
 
+   public AOPClassLoaderHookTestSetup(TestSuite suite, SetupHook hook, String jar) throws Exception
+   {
+      this(suite, jar);
+      this.hook = hook;
+   }
+
    protected void setUp() throws Exception
    {
       super.setUp();
       ObjectName aspectManager = new ObjectName(ASPECT_MANAGER_NAME);
       Attribute enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.TRUE);
       getServer().setAttribute(aspectManager, enableTransformer);
+      if (hook != null)
+      {
+         hook.setup(getServer());
+      }
       try
       {
          for (int i = 0 ; i < jars.length ; i++)
@@ -69,6 +80,10 @@
          {
             enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.FALSE);
             getServer().setAttribute(aspectManager, enableTransformer);
+            if (hook != null)
+            {
+               hook.teardown(getServer());
+            }
          }
          catch(Exception ex)
          {
@@ -95,6 +110,10 @@
       ObjectName aspectManager = new ObjectName(ASPECT_MANAGER_NAME);
       Attribute enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.FALSE);
       getServer().setAttribute(aspectManager, enableTransformer);
+      if (hook != null)
+      {
+         hook.teardown(getServer());
+      }
       if( undeployException != null )
          throw undeployException;
       super.tearDown();

Modified: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -23,6 +23,7 @@
 
 import java.net.URL;
 
+import javax.management.Attribute;
 import javax.management.MBeanServerConnection;
 import javax.management.ObjectName;
 
@@ -30,6 +31,7 @@
 import junit.framework.TestSuite;
 
 import org.jboss.test.JBossTestCase;
+import org.jboss.test.JBossTestSetup;
 import org.jboss.test.util.web.HttpUtils;
 
 /**
@@ -38,8 +40,7 @@
  * @author <a href="mailto:bill at burkecentral.com">Kabir Khan</a>
  * @version $Id$
  */
-public class ScopedUnitTestCase
-        extends JBossTestCase
+public class ScopedUnitTestCase extends JBossTestCase
 {
    org.apache.log4j.Category log = getLog();
 
@@ -109,6 +110,60 @@
       server.invoke(testerName, "testIntroduction2", params, sig);
    }
 
+   public void testInclude1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testInclude", params, sig);
+   }
+   
+   public void testInclude2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testInclude", params, sig);
+   }
+   
+   public void testExclude1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testExclude", params, sig);
+   }
+   
+   public void testExclude2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testExclude", params, sig);
+   }
+   
+   public void testIgnore1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testIgnore", params, sig);
+   }
+   
+   public void testIgnore2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testIgnore", params, sig);
+   }
+   
    public void testEar1() throws Exception
    {
       URL url = new URL(HttpUtils.getBaseURL() + "ear1/srv");
@@ -126,8 +181,37 @@
       TestSuite suite = new TestSuite();
       suite.addTest(new TestSuite(ScopedUnitTestCase.class));
 
-      setup = new AOPClassLoaderHookTestSetup(suite, "aop-scopedtest1.sar,aop-scopedtest2.sar,aop-scopedear1.ear,aop-scopedear2.ear");
+      setup = new AOPClassLoaderHookTestSetup(suite, new MySetupHook(), "aop-scopedtest1.sar,aop-scopedtest2.sar,aop-scopedear1.ear,aop-scopedear2.ear");
       return setup;
    }
 
+   static class MySetupHook implements SetupHook
+   {
+      String originalIgnore;
+      String originalInclude;
+      String originalExclude;
+
+      public void setup(MBeanServerConnection server) throws Exception
+      {
+         ObjectName aspectManager = new ObjectName(AOPClassLoaderHookTestSetup.ASPECT_MANAGER_NAME);
+         
+         originalIgnore = (String)server.getAttribute(aspectManager, "Ignore");
+         server.setAttribute(aspectManager, new Attribute("Ignore", "*$$Ignored$$*"));
+         
+         originalInclude = (String)server.getAttribute(aspectManager, "Include");
+         server.setAttribute(aspectManager, new Attribute("Include", "org.jboss.test.aop.scoped.excluded.included."));
+         
+         originalExclude = (String)server.getAttribute(aspectManager, "Exclude");
+         server.setAttribute(aspectManager, new Attribute("Exclude", "org.jboss.test.aop.scoped.excluded."));
+      }
+   
+      public void teardown(MBeanServerConnection server) throws Exception
+      {
+         ObjectName aspectManager = new ObjectName(AOPClassLoaderHookTestSetup.ASPECT_MANAGER_NAME);
+   
+         server.setAttribute(aspectManager, new Attribute("Ignore", originalIgnore));
+         server.setAttribute(aspectManager, new Attribute("Include", originalInclude));
+         server.setAttribute(aspectManager, new Attribute("Exclude", originalExclude));
+      }
+   }
 }

Added: branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java
===================================================================
--- branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java	2006-12-19 10:21:16 UTC (rev 59133)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.test;
+
+import javax.management.MBeanServerConnection;
+
+import org.jboss.test.JBossTestSetup;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public interface SetupHook
+{
+   void setup(MBeanServerConnection server) throws Exception;
+   void teardown(MBeanServerConnection server) throws Exception;
+}

Modified: branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml	2006-12-19 10:21:16 UTC (rev 59133)
@@ -46,4 +46,7 @@
       <interceptor-ref name="org.jboss.test.aop.scoped.ScopedInterceptor"/>
    </bind>
    
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.ExcludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.included.IncludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.POJO$$Ignored$$123)"/>
 </aop>

Modified: branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml
===================================================================
--- branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml	2006-12-19 08:10:32 UTC (rev 59132)
+++ branches/Branch_4_0/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml	2006-12-19 10:21:16 UTC (rev 59133)
@@ -46,4 +46,8 @@
       <interceptor-ref name="org.jboss.test.aop.scoped.ScopedInterceptor"/>
    </bind>
    
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.ExcludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.included.IncludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.POJO$$Ignored$$123)"/>
+   
 </aop>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 05:24:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 05:24:12 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59134 - tags
Message-ID: <E1Gwc8q-0007Ka-Q3@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 05:24:10 -0500 (Tue, 19 Dec 2006)
New Revision: 59134

Added:
   tags/JBoss_AOP_1_5_3_BETA1/
Log:
made a copy

Copied: tags/JBoss_AOP_1_5_3_BETA1 (from rev 59133, branches/Branch_AOP_1_5)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 05:24:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 05:24:52 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59135 - tags
Message-ID: <E1Gwc9U-0007Kt-S2@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 05:24:50 -0500 (Tue, 19 Dec 2006)
New Revision: 59135

Added:
   tags/JBOSS_ASPECTS_1_5_3_BETA1/
Log:
made a copy

Copied: tags/JBOSS_ASPECTS_1_5_3_BETA1 (from rev 59134, branches/Branch_4_0)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 05:33:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 05:33:56 -0500
Subject: [jboss-cvs] JBossAS SVN: r59136 -
	projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins
Message-ID: <E1GwcIG-0007We-FS@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-19 05:33:54 -0500 (Tue, 19 Dec 2006)
New Revision: 59136

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java
Log:
javadoc, exc. on null classInfo

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java	2006-12-19 10:24:50 UTC (rev 59135)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java	2006-12-19 10:33:54 UTC (rev 59136)
@@ -259,6 +259,8 @@
     */
    public static FieldInfo findFieldInfo(ClassInfo classInfo, String name) throws JoinpointException
    {
+      if (classInfo == null)
+         throw new IllegalArgumentException("ClassInfo cannot be null!");
       ClassInfo current = classInfo;
       while (current != null)
       {
@@ -273,7 +275,7 @@
    /**
     * Find field info
     *
-    * @param fieldInfo the field info
+    * @param classInfo the class info
     * @param name the field name
     * @return the field info or null if not found
     */
@@ -318,6 +320,9 @@
     */
    public static MethodInfo findMethodInfo(ClassInfo classInfo, String name, String[] paramTypes, boolean isStatic, boolean isPublic) throws JoinpointException
    {
+      if (classInfo == null)
+         throw new IllegalArgumentException("ClassInfo cannot be null!");
+
       if (paramTypes == null)
          paramTypes = NO_PARAMS_TYPES;
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 06:07:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 06:07:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r59137 - in branches/Branch_4_2:
	aspects/src/main/org/jboss/aop/deployment build
	testsuite/imports/sections
	testsuite/src/main/org/jboss/test/aop/scoped
	testsuite/src/main/org/jboss/test/aop/scoped/excluded
	testsuite/src/main/org/jboss/test/aop/scoped/excluded/included
	testsuite/src/main/org/jboss/test/aop/test
	testsuite/src/resources/aop/scoped/sar1/META-INF
	testsuite/src/resources/aop/scoped/sar2/META-INF
Message-ID: <E1Gwcob-0008J6-Qi@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 06:07:12 -0500 (Tue, 19 Dec 2006)
New Revision: 59137

Added:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java
Modified:
   branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java
   branches/Branch_4_2/build/build-thirdparty.xml
   branches/Branch_4_2/testsuite/imports/sections/aop.xml
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java
   branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml
   branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml
Log:
[JBAOP-331] IgnoreExpressions for a domain should be got from main AspectManager

Modified: branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java
===================================================================
--- branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -109,7 +109,7 @@
       if (tmpClassesDir.exists() == false && tmpClassesDir.mkdirs() == false)
          throw new FileNotFoundException("Failed to create tmpClassesDir: " + tmpClassesDir.getAbsolutePath());
       AspectManager.setClassPoolFactory(createFactory());
-      
+
       AspectManager.classLoaderValidator = createClassLoaderValidation();
       // Add the tmp classes dir to our UCL classpath
 
@@ -126,9 +126,9 @@
       }
       created = true;
       AspectManager.notificationHandler = this;
-      
+
       AspectManager.scopedCLHelper = new JBossScopedClassLoaderHelper();
-      
+
       baseAop();
    }
 
@@ -263,10 +263,13 @@
    {
       this.exclude = exclude;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(exclude, ",");
-      while (tokenizer.hasMoreTokens())
+      if (exclude != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(exclude, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setExclude(list);
    }
@@ -280,10 +283,13 @@
    {
       this.include = include;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(include, ",");
-      while (tokenizer.hasMoreTokens())
+      if (include != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(include, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setInclude(list);
    }
@@ -297,15 +303,18 @@
    {
       this.ignore = ignore;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(ignore, ",");
-      while (tokenizer.hasMoreTokens())
+      if (ignore != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(ignore, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setIgnore(list);
    }
 
-   
+
    /**
     * The temporary directory to which dyn class files are written
     *
@@ -565,12 +574,12 @@
       }
       this.enableLoadtimeWeaving = enableTransformer;
    }
-   
+
    public String getInstrumentor()
    {
       return InstrumentorFactory.getInstrumentorName();
    }
-   
+
    public void setInstrumentor(String instrumentor)
    {
       InstrumentorFactory.initialise(instrumentor);

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-19 11:07:12 UTC (rev 59137)
@@ -84,8 +84,8 @@
       <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
       <componentref name="jacorb" version="2.2.4jboss.patch1"/>
       <componentref name="javassist" version="3.4.GA"/>
-      <componentref name="jaxen" version="1.1-beta-9"/>      
-      <componentref name="jboss/aop" version="snapshot-Branch_AOP_1_5"/>
+      <componentref name="jaxen" version="1.1-beta-9"/>
+      <componentref name="jboss/aop" version="1.5.3.beta1"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/cache" version="1.4.0.SP1"/>
       <componentref name="jboss/common" version="1.0.0.GA"/>

Modified: branches/Branch_4_2/testsuite/imports/sections/aop.xml
===================================================================
--- branches/Branch_4_2/testsuite/imports/sections/aop.xml	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/imports/sections/aop.xml	2006-12-19 11:07:12 UTC (rev 59137)
@@ -172,6 +172,7 @@
     <jar destfile="${build.lib}/aop-scopedtest1.aop">
       <fileset dir="${build.classes}">
         <include name="org/jboss/test/aop/scoped/*.class"/>
+        <include name="org/jboss/test/aop/scoped/excluded/**/*.class"/>
         <exclude name="org/jboss/test/aop/scoped/ScopedTester*.class"/>
       </fileset>
       <fileset dir="${build.resources}/aop/scoped/sar1">
@@ -192,6 +193,7 @@
     <jar destfile="${build.lib}/aop-scopedtest2.sar">
       <fileset dir="${build.classes}">
         <include name="org/jboss/test/aop/scoped/*.class"/>
+        <include name="org/jboss/test/aop/scoped/excluded/**/*.class"/>
         <exclude name="org/jboss/test/aop/scoped/Annotated*.class"/>
       </fileset>
       <fileset dir="${build.resources}/aop/scoped/sar2/META-INF">

Added: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class POJO$$Ignored$$123
+{
+
+}

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -21,6 +21,10 @@
  */
 package org.jboss.test.aop.scoped;
 
+import org.jboss.aop.Advised;
+import org.jboss.test.aop.scoped.excluded.ExcludedPOJO;
+import org.jboss.test.aop.scoped.excluded.included.IncludedPOJO;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -201,4 +205,27 @@
       }
    }
    
+   public void testInclude()
+   {
+      if (!Advised.class.isAssignableFrom(IncludedPOJO.class))
+      {
+         throw new RuntimeException("IncludedPOJO should be Advised");
+      }
+   }
+   
+   public void testExclude()
+   {
+      if (Advised.class.isAssignableFrom(ExcludedPOJO.class))
+      {
+         throw new RuntimeException("ExcludedPOJO should not be Advised");
+      }
+   }
+   
+   public void testIgnore()
+   {
+      if (Advised.class.isAssignableFrom(POJO$$Ignored$$123.class))
+      {
+         throw new RuntimeException("POJO$$Ignored$$123 should not be Advised");
+      }
+   }
 }

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -40,4 +40,8 @@
    void testIntroduction2();
    void testAnnotatedScopedAnnotationsDeployed();
    void testAnnotatedScopedAnnotationsNotDeployed();
+   
+   void testInclude();
+   void testExclude();
+   void testIgnore();
 }

Added: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped.excluded;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ExcludedPOJO
+{
+
+}

Added: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped.excluded.included;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class IncludedPOJO
+{
+
+}

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -40,7 +40,8 @@
    public static String ASPECT_MANAGER_NAME = "jboss.aop:service=AspectManager";
 
    private String[] jars;
-
+   SetupHook hook;
+   
    // Create an initializer for the test suite
    public AOPClassLoaderHookTestSetup(TestSuite suite, String jar) throws Exception
    {
@@ -48,12 +49,22 @@
       this.jars = jar.split(",");
    }
 
+   public AOPClassLoaderHookTestSetup(TestSuite suite, SetupHook hook, String jar) throws Exception
+   {
+      this(suite, jar);
+      this.hook = hook;
+   }
+   
    protected void setUp() throws Exception
    {
       super.setUp();
       ObjectName aspectManager = new ObjectName(ASPECT_MANAGER_NAME);
       Attribute enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.TRUE);
       getServer().setAttribute(aspectManager, enableTransformer);
+      if (hook != null)
+      {
+         hook.setup(getServer());
+      }
       try
       {
          for (int i = 0 ; i < jars.length ; i++)
@@ -69,6 +80,10 @@
          {
             enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.FALSE);
             getServer().setAttribute(aspectManager, enableTransformer);
+            if (hook != null)
+            {
+               hook.teardown(getServer());
+            }
          }
          catch(Exception ex)
          {
@@ -95,6 +110,10 @@
       ObjectName aspectManager = new ObjectName(ASPECT_MANAGER_NAME);
       Attribute enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.FALSE);
       getServer().setAttribute(aspectManager, enableTransformer);
+      if (hook != null)
+      {
+         hook.teardown(getServer());
+      }
       if( undeployException != null )
          throw undeployException;
       super.tearDown();

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -23,6 +23,7 @@
 
 import java.net.URL;
 
+import javax.management.Attribute;
 import javax.management.MBeanServerConnection;
 import javax.management.ObjectName;
 
@@ -126,6 +127,60 @@
       server.invoke(testerName, "testIntroduction2", params, sig);
    }
 
+   public void testInclude1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testInclude", params, sig);
+   }
+   
+   public void testInclude2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testInclude", params, sig);
+   }
+   
+   public void testExclude1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testExclude", params, sig);
+   }
+   
+   public void testExclude2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testExclude", params, sig);
+   }
+   
+   public void testIgnore1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testIgnore", params, sig);
+   }
+   
+   public void testIgnore2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testIgnore", params, sig);
+   }
+   
    public void testEar1() throws Exception
    {
       URL url = new URL(HttpUtils.getBaseURL() + "ear1/srv");
@@ -143,8 +198,36 @@
       TestSuite suite = new TestSuite();
       suite.addTest(new TestSuite(ScopedUnitTestCase.class));
 
-      setup = new AOPClassLoaderHookTestSetup(suite, "aop-scopedtest1.sar,aop-scopedtest2.sar,aop-scopedear1.ear,aop-scopedear2.ear");
+      setup = new AOPClassLoaderHookTestSetup(suite, new MySetupHook(), "aop-scopedtest1.sar,aop-scopedtest2.sar,aop-scopedear1.ear,aop-scopedear2.ear");
       return setup;
    }
 
-}
+   static class MySetupHook implements SetupHook
+   {
+      String originalIgnore;
+      String originalInclude;
+      String originalExclude;
+
+      public void setup(MBeanServerConnection server) throws Exception
+      {
+         ObjectName aspectManager = new ObjectName(AOPClassLoaderHookTestSetup.ASPECT_MANAGER_NAME);
+         
+         originalIgnore = (String)server.getAttribute(aspectManager, "Ignore");
+         server.setAttribute(aspectManager, new Attribute("Ignore", "*$$Ignored$$*"));
+         
+         originalInclude = (String)server.getAttribute(aspectManager, "Include");
+         server.setAttribute(aspectManager, new Attribute("Include", "org.jboss.test.aop.scoped.excluded.included."));
+         
+         originalExclude = (String)server.getAttribute(aspectManager, "Exclude");
+         server.setAttribute(aspectManager, new Attribute("Exclude", "org.jboss.test.aop.scoped.excluded."));
+      }
+   
+      public void teardown(MBeanServerConnection server) throws Exception
+      {
+         ObjectName aspectManager = new ObjectName(AOPClassLoaderHookTestSetup.ASPECT_MANAGER_NAME);
+   
+         server.setAttribute(aspectManager, new Attribute("Ignore", originalIgnore));
+         server.setAttribute(aspectManager, new Attribute("Include", originalInclude));
+         server.setAttribute(aspectManager, new Attribute("Exclude", originalExclude));
+      }
+   }}

Added: branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java	2006-12-19 11:07:12 UTC (rev 59137)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.test;
+
+import javax.management.MBeanServerConnection;
+
+import org.jboss.test.JBossTestSetup;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public interface SetupHook
+{
+   void setup(MBeanServerConnection server) throws Exception;
+   void teardown(MBeanServerConnection server) throws Exception;
+}

Modified: branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml
===================================================================
--- branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml	2006-12-19 11:07:12 UTC (rev 59137)
@@ -46,4 +46,7 @@
       <interceptor-ref name="org.jboss.test.aop.scoped.ScopedInterceptor"/>
    </bind>
    
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.ExcludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.included.IncludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.POJO$$Ignored$$123)"/>
 </aop>

Modified: branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml
===================================================================
--- branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml	2006-12-19 10:33:54 UTC (rev 59136)
+++ branches/Branch_4_2/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml	2006-12-19 11:07:12 UTC (rev 59137)
@@ -46,4 +46,7 @@
       <interceptor-ref name="org.jboss.test.aop.scoped.ScopedInterceptor"/>
    </bind>
    
-</aop>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.ExcludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.included.IncludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.POJO$$Ignored$$123)"/>
+ </aop>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 06:33:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 06:33:13 -0500
Subject: [jboss-cvs] JBossAS SVN: r59138 - in trunk:
	aspects/src/main/org/jboss/aop/deployment build
	testsuite/imports/sections
	testsuite/src/main/org/jboss/test/aop/scoped
	testsuite/src/main/org/jboss/test/aop/scoped/excluded
	testsuite/src/main/org/jboss/test/aop/scoped/excluded/included
	testsuite/src/main/org/jboss/test/aop/test
	testsuite/src/resources/aop/scoped/sar1/META-INF
	testsuite/src/resources/aop/scoped/sar2/META-INF
Message-ID: <E1GwdDd-0000RB-1U@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 06:33:03 -0500 (Tue, 19 Dec 2006)
New Revision: 59138

Added:
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java
   trunk/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java
Modified:
   trunk/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java
   trunk/build/build-thirdparty.xml
   trunk/testsuite/imports/sections/aop.xml
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java
   trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java
   trunk/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java
   trunk/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java
   trunk/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml
   trunk/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml
Log:
[JBAOP-331] IgnoreExpressions for a domain should be got from main AspectManager

Modified: trunk/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java
===================================================================
--- trunk/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/aspects/src/main/org/jboss/aop/deployment/AspectManagerService.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -64,17 +64,17 @@
         extends ServiceMBeanSupport
         implements AspectManagerServiceMBean, AspectNotificationHandler
 {
-   
+
    static {
       //pre-load necessary classes so that we avoid NoClassDefFoundErrors on JRockit when using the RepositoryClassloader hook
-      //When AspectManager.translate() is called the first time, these classes have not been loaded yet, and this is what causes 
+      //When AspectManager.translate() is called the first time, these classes have not been loaded yet, and this is what causes
       //JRockit to get confused
       TransformerCommon common = new TransformerCommon();
       SuperClassesFirstWeavingStrategy strategy1 = new SuperClassesFirstWeavingStrategy();
       ClassicWeavingStrategy strategy2 = new ClassicWeavingStrategy();
-      
+
    }
-   
+
    public static final ObjectName DEFAULT_LOADER_REPOSITORY = ObjectNameFactory.create(ServerConstants.DEFAULT_LOADER_NAME);
 
    // Attributes ---------------------------------------------------
@@ -96,7 +96,7 @@
    public AspectManagerService()
    {
    }
-   
+
    public AspectManagerService(String baseXml)
    {
       this.baseXml = baseXml;
@@ -129,7 +129,7 @@
       if (tmpClassesDir.exists() == false && tmpClassesDir.mkdirs() == false)
          throw new FileNotFoundException("Failed to create tmpClassesDir: " + tmpClassesDir.getAbsolutePath());
       AspectManager.setClassPoolFactory(createFactory());
-      
+
       AspectManager.classLoaderValidator = createClassLoaderValidation();
       // Add the tmp classes dir to our UCL classpath
 
@@ -146,9 +146,9 @@
       }
       created = true;
       AspectManager.notificationHandler = this;
-      
+
       AspectManager.scopedCLHelper = new JBossScopedClassLoaderHelper();
-      
+
       baseAop();
    }
 
@@ -170,7 +170,7 @@
       catch (Exception e)
       {
          System.out.println("Error loading " + baseXml + " file" + e);
-      }      
+      }
    }
 
    protected void attachDeprecatedTranslator()
@@ -290,10 +290,13 @@
    {
       this.exclude = exclude;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(exclude, ",");
-      while (tokenizer.hasMoreTokens())
+      if (exclude != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(exclude, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setExclude(list);
    }
@@ -307,10 +310,13 @@
    {
       this.include = include;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(include, ",");
-      while (tokenizer.hasMoreTokens())
+      if (include != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(include, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setInclude(list);
    }
@@ -324,15 +330,18 @@
    {
       this.ignore = ignore;
       ArrayList list = new ArrayList();
-      StringTokenizer tokenizer = new StringTokenizer(ignore, ",");
-      while (tokenizer.hasMoreTokens())
+      if (ignore != null)
       {
-         list.add(tokenizer.nextToken().trim());
+         StringTokenizer tokenizer = new StringTokenizer(ignore, ",");
+         while (tokenizer.hasMoreTokens())
+         {
+            list.add(tokenizer.nextToken().trim());
+         }
       }
       AspectManager.instance().setIgnore(list);
    }
 
-   
+
    /**
     * The temporary directory to which dyn class files are written
     *
@@ -592,12 +601,12 @@
       }
       this.enableLoadtimeWeaving = enableTransformer;
    }
-   
+
    public String getInstrumentor()
    {
       return InstrumentorFactory.getInstrumentorName();
    }
-   
+
    public void setInstrumentor(String instrumentor)
    {
       InstrumentorFactory.initialise(instrumentor);

Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/build/build-thirdparty.xml	2006-12-19 11:33:03 UTC (rev 59138)
@@ -84,8 +84,8 @@
       <componentref name="jacorb" version="2.2.4jboss.patch1"/>
       <componentref name="javassist" version="3.4.GA"/>
       <componentref name="jaxen" version="1.1-beta-9"/>
-      <componentref name="jboss/aop" version="2.0.0.alpha2"/>
-      <componentref name="jboss/aop14" version="2.0.0.alpha2"/>
+      <componentref name="jboss/aop" version="snapshot"/>
+      <componentref name="jboss/aop14" version="snapshot"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/cache" version="2.0.0.ALPHA1"/>
       <componentref name="jboss/common-core" version="2.0.3.GA"/>

Modified: trunk/testsuite/imports/sections/aop.xml
===================================================================
--- trunk/testsuite/imports/sections/aop.xml	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/imports/sections/aop.xml	2006-12-19 11:33:03 UTC (rev 59138)
@@ -257,6 +257,7 @@
       <jar destfile="${build.lib}/aop-scopedtest1.aop">
          <fileset dir="${build.classes}">
             <include name="org/jboss/test/aop/scoped/*.class"/>
+            <include name="org/jboss/test/aop/scoped/excluded/**/*.class"/>
             <exclude name="org/jboss/test/aop/scoped/ScopedTester*.class"/>
          </fileset>
          <fileset dir="${build.resources}/aop/scoped/sar1">
@@ -277,6 +278,7 @@
       <jar destfile="${build.lib}/aop-scopedtest2.sar">
          <fileset dir="${build.classes}">
             <include name="org/jboss/test/aop/scoped/*.class"/>
+            <include name="org/jboss/test/aop/scoped/excluded/**/*.class"/>
             <exclude name="org/jboss/test/aop/scoped/Annotated*.class"/>
          </fileset>
          <fileset dir="${build.resources}/aop/scoped/sar2/META-INF">

Added: trunk/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/scoped/POJO$$Ignored$$123.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class POJO$$Ignored$$123
+{
+
+}

Modified: trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTester.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -21,6 +21,10 @@
 */ 
 package org.jboss.test.aop.scoped;
 
+import org.jboss.aop.Advised;
+import org.jboss.test.aop.scoped.excluded.ExcludedPOJO;
+import org.jboss.test.aop.scoped.excluded.included.IncludedPOJO;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -201,4 +205,27 @@
       }
    }
    
+   public void testInclude()
+   {
+      if (!Advised.class.isAssignableFrom(IncludedPOJO.class))
+      {
+         throw new RuntimeException("IncludedPOJO should be Advised");
+      }
+   }
+   
+   public void testExclude()
+   {
+      if (Advised.class.isAssignableFrom(ExcludedPOJO.class))
+      {
+         throw new RuntimeException("ExcludedPOJO should not be Advised");
+      }
+   }
+   
+   public void testIgnore()
+   {
+      if (Advised.class.isAssignableFrom(POJO$$Ignored$$123.class))
+      {
+         throw new RuntimeException("POJO$$Ignored$$123 should not be Advised");
+      }
+   }
 }

Modified: trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/scoped/ScopedTesterMBean.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -40,4 +40,8 @@
    void testIntroduction2();
    void testAnnotatedScopedAnnotationsDeployed();
    void testAnnotatedScopedAnnotationsNotDeployed();
+   
+   void testInclude();
+   void testExclude();
+   void testIgnore();
 }

Added: trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/ExcludedPOJO.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped.excluded;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ExcludedPOJO
+{
+
+}

Added: trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/scoped/excluded/included/IncludedPOJO.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.scoped.excluded.included;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class IncludedPOJO
+{
+
+}

Modified: trunk/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/test/AOPClassLoaderHookTestSetup.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -40,22 +40,31 @@
    public static String ASPECT_MANAGER_NAME = "jboss.aop:service=AspectManager";
 
    private String[] jars;
-
+   SetupHook hook;
+   
    // Create an initializer for the test suite
    public AOPClassLoaderHookTestSetup(TestSuite suite, String jar) throws Exception
    {
       super(suite);
       this.jars = jar.split(",");
    }
-
+   
+   public AOPClassLoaderHookTestSetup(TestSuite suite, SetupHook hook, String jar) throws Exception
+   {
+      this(suite, jar);
+      this.hook = hook;
+   }
+   
    protected void setUp() throws Exception
    {
       super.setUp();
       ObjectName aspectManager = new ObjectName(ASPECT_MANAGER_NAME);
       Attribute enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.TRUE);
       getServer().setAttribute(aspectManager, enableTransformer);
-//      Attribute verbose = new Attribute("Verbose", Boolean.TRUE);
-//      getServer().setAttribute(aspectManager, verbose);
+      if (hook != null)
+      {
+         hook.setup(getServer());
+      }
       try
       {
          for (int i = 0 ; i < jars.length ; i++)
@@ -71,8 +80,10 @@
          {
             enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.FALSE);
             getServer().setAttribute(aspectManager, enableTransformer);
-//            verbose = new Attribute("Verbose", Boolean.TRUE);
-//            getServer().setAttribute(aspectManager, verbose);
+            if (hook != null)
+            {
+               hook.teardown(getServer());
+            }
          }
          catch(Exception ex)
          {
@@ -99,6 +110,10 @@
       ObjectName aspectManager = new ObjectName(ASPECT_MANAGER_NAME);
       Attribute enableTransformer = new Attribute("EnableLoadtimeWeaving", Boolean.FALSE);
       getServer().setAttribute(aspectManager, enableTransformer);
+      if (hook != null)
+      {
+         hook.teardown(getServer());
+      }
       if( undeployException != null )
          throw undeployException;
       super.tearDown();

Modified: trunk/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/test/ScopedUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -23,6 +23,7 @@
 
 import java.net.URL;
 
+import javax.management.Attribute;
 import javax.management.MBeanServerConnection;
 import javax.management.ObjectName;
 
@@ -126,6 +127,60 @@
       server.invoke(testerName, "testIntroduction2", params, sig);
    }
 
+   public void testInclude1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testInclude", params, sig);
+   }
+   
+   public void testInclude2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testInclude", params, sig);
+   }
+   
+   public void testExclude1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testExclude", params, sig);
+   }
+   
+   public void testExclude2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testExclude", params, sig);
+   }
+   
+   public void testIgnore1() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester1");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testIgnore", params, sig);
+   }
+   
+   public void testIgnore2() throws Exception
+   {
+      MBeanServerConnection server = getServer();
+      ObjectName testerName = new ObjectName("jboss.aop:name=ScopedTester2");
+      Object[] params = {};
+      String[] sig = {};
+      server.invoke(testerName, "testIgnore", params, sig);
+   }
+   
    public void testEar1() throws Exception
    {
       URL url = new URL(HttpUtils.getBaseURL() + "ear1/srv");
@@ -143,8 +198,37 @@
       TestSuite suite = new TestSuite();
       suite.addTest(new TestSuite(ScopedUnitTestCase.class));
 
-      setup = new AOPClassLoaderHookTestSetup(suite, "aop-scopedtest1.sar,aop-scopedtest2.sar,aop-scopedear1.ear,aop-scopedear2.ear");
+      setup = new AOPClassLoaderHookTestSetup(suite, new MySetupHook(), "aop-scopedtest1.sar,aop-scopedtest2.sar,aop-scopedear1.ear,aop-scopedear2.ear");
       return setup;
    }
 
+   static class MySetupHook implements SetupHook
+   {
+      String originalIgnore;
+      String originalInclude;
+      String originalExclude;
+
+      public void setup(MBeanServerConnection server) throws Exception
+      {
+         ObjectName aspectManager = new ObjectName(AOPClassLoaderHookTestSetup.ASPECT_MANAGER_NAME);
+         
+         originalIgnore = (String)server.getAttribute(aspectManager, "Ignore");
+         server.setAttribute(aspectManager, new Attribute("Ignore", "*$$Ignored$$*"));
+         
+         originalInclude = (String)server.getAttribute(aspectManager, "Include");
+         server.setAttribute(aspectManager, new Attribute("Include", "org.jboss.test.aop.scoped.excluded.included."));
+         
+         originalExclude = (String)server.getAttribute(aspectManager, "Exclude");
+         server.setAttribute(aspectManager, new Attribute("Exclude", "org.jboss.test.aop.scoped.excluded."));
+      }
+   
+      public void teardown(MBeanServerConnection server) throws Exception
+      {
+         ObjectName aspectManager = new ObjectName(AOPClassLoaderHookTestSetup.ASPECT_MANAGER_NAME);
+   
+         server.setAttribute(aspectManager, new Attribute("Ignore", originalIgnore));
+         server.setAttribute(aspectManager, new Attribute("Include", originalInclude));
+         server.setAttribute(aspectManager, new Attribute("Exclude", originalExclude));
+      }
+   }
 }

Added: trunk/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/main/org/jboss/test/aop/test/SetupHook.java	2006-12-19 11:33:03 UTC (rev 59138)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.test;
+
+import javax.management.MBeanServerConnection;
+
+import org.jboss.test.JBossTestSetup;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public interface SetupHook
+{
+   void setup(MBeanServerConnection server) throws Exception;
+   void teardown(MBeanServerConnection server) throws Exception;
+}

Modified: trunk/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml
===================================================================
--- trunk/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/resources/aop/scoped/sar1/META-INF/jboss-aop.xml	2006-12-19 11:33:03 UTC (rev 59138)
@@ -46,4 +46,7 @@
       <interceptor-ref name="org.jboss.test.aop.scoped.ScopedInterceptor"/>
    </bind>
    
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.ExcludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.included.IncludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.POJO$$Ignored$$123)"/>
 </aop>

Modified: trunk/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml
===================================================================
--- trunk/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml	2006-12-19 11:07:12 UTC (rev 59137)
+++ trunk/testsuite/src/resources/aop/scoped/sar2/META-INF/scoped-aop.xml	2006-12-19 11:33:03 UTC (rev 59138)
@@ -46,4 +46,7 @@
       <interceptor-ref name="org.jboss.test.aop.scoped.ScopedInterceptor"/>
    </bind>
    
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.ExcludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.excluded.included.IncludedPOJO)"/>
+   <prepare expr="all(org.jboss.test.aop.scoped.POJO$$Ignored$$123)"/>
 </aop>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 08:01:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 08:01:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r59139 - in projects/microcontainer/trunk:
	. metatype metatype/src metatype/src/etc metatype/src/main
	metatype/src/main/org metatype/src/main/org/jboss
	metatype/src/main/org/jboss/metatype
	metatype/src/main/org/jboss/metatype/api
	metatype/src/main/org/jboss/metatype/api/types
	metatype/src/main/org/jboss/metatype/api/values
	metatype/src/tests metatype/src/tests/org
	metatype/src/tests/org/jboss metatype/src/tests/org/jboss/test
	metatype/src/tests/org/jboss/test/metatype
	metatype/src/tests/org/jboss/test/metatype/types
	metatype/src/tests/org/jboss/test/metatype/types/support
	metatype/src/tests/org/jboss/test/metatype/types/test
	metatype/src/tests/org/jboss/test/metatype/values
	metatype/src/tests/org/jboss/test/metatype/values/test
Message-ID: <E1Gweaz-00022l-HL@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-19 08:01:12 -0500 (Tue, 19 Dec 2006)
New Revision: 59139

Added:
   projects/microcontainer/trunk/metatype/
   projects/microcontainer/trunk/metatype/.classpath
   projects/microcontainer/trunk/metatype/.project
   projects/microcontainer/trunk/metatype/build.bat
   projects/microcontainer/trunk/metatype/build.sh
   projects/microcontainer/trunk/metatype/build.xml
   projects/microcontainer/trunk/metatype/src/
   projects/microcontainer/trunk/metatype/src/etc/
   projects/microcontainer/trunk/metatype/src/etc/default.mf
   projects/microcontainer/trunk/metatype/src/main/
   projects/microcontainer/trunk/metatype/src/main/org/
   projects/microcontainer/trunk/metatype/src/main/org/jboss/
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/AbstractMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ArrayMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/CompositeMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableCompositeMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableTableMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/MetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/SimpleMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/TableMetaType.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/AbstractMetaValue.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValue.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValueSupport.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/MetaValue.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValue.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValueSupport.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValue.java
   projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValueSupport.java
   projects/microcontainer/trunk/metatype/src/tests/
   projects/microcontainer/trunk/metatype/src/tests/org/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/AbstractMetaTypeTest.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/MetaTypeAllTestSuite.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockCompositeValue.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaType.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaValue.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockSimpleValue.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockTableValue.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ArrayMetaTypeUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableCompositeMetaTypeUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableTableMetaTypeUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/MetaTypeUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/SimpleMetaTypeUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/TypesTestSuite.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/CompositeValueSupportUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/SimpleValueSupportUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/TableValueSupportUnitTestCase.java
   projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/ValuesTestSuite.java
Log:
Start of metatype project

Added: projects/microcontainer/trunk/metatype/.classpath
===================================================================
--- projects/microcontainer/trunk/metatype/.classpath	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/.classpath	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,13 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src/main"/>
+	<classpathentry kind="src" path="src/tests"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
+	<classpathentry kind="output" path="output/eclipse-classes"/>
+</classpath>

Added: projects/microcontainer/trunk/metatype/.project
===================================================================
--- projects/microcontainer/trunk/metatype/.project	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/.project	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>metatype</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>

Added: projects/microcontainer/trunk/metatype/build.bat
===================================================================
--- projects/microcontainer/trunk/metatype/build.bat	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/build.bat	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,89 @@
+ at echo off
+REM  ======================================================================
+REM
+REM  This is the main entry point for the build system.
+REM
+REM  Users should be sure to execute this file rather than 'ant' to ensure
+REM  the correct version is being used with the correct configuration.
+REM
+REM  ======================================================================
+REM
+REM $Id: build.bat 31497 2005-05-24 16:47:10Z adrian $
+REM
+REM Authors:
+REM     Jason Dillon <jason at planet57.com>
+REM     Sacha Labourey <sacha.labourey at cogito-info.ch>
+REM
+
+REM ******************************************************
+REM Ignore the ANT_HOME variable: we want to use *our*
+REM ANT version and associated JARs.
+REM ******************************************************
+REM Ignore the users classpath, cause it might mess
+REM things up
+REM ******************************************************
+
+SETLOCAL
+
+set CLASSPATH=
+set ANT_HOME=
+set ANT_OPTS=-Djava.protocol.handler.pkgs=org.jboss.net.protocol -Dbuild.script=build.bat
+
+REM ******************************************************
+REM - "for" loops have been unrolled for compatibility
+REM   with some WIN32 systems.
+REM ******************************************************
+
+set NAMES=tools;tools\ant;tools\apache\ant
+set SUBFOLDERS=..;..\..;..\..\..;..\..\..\..
+
+REM ******************************************************
+REM ******************************************************
+
+SET EXECUTED=FALSE
+for %%i in (%NAMES%) do call :subLoop %%i %1 %2 %3 %4 %5 %6
+
+goto :EOF
+
+
+REM ******************************************************
+REM ********* Search for names in the subfolders *********
+REM ******************************************************
+
+:subLoop
+for %%j in (%SUBFOLDERS%) do call :testIfExists %%j\%1\bin\ant.bat %2 %3 %4 %5 %6 %7
+
+goto :EOF
+
+
+REM ******************************************************
+REM ************ Test if ANT Batch file exists ***********
+REM ******************************************************
+
+:testIfExists
+if exist %1 call :BatchFound %1 %2 %3 %4 %5 %6 %7 %8
+
+goto :EOF
+
+
+REM ******************************************************
+REM ************** Batch file has been found *************
+REM ******************************************************
+
+:BatchFound
+if (%EXECUTED%)==(FALSE) call :ExecuteBatch %1 %2 %3 %4 %5 %6 %7 %8
+set EXECUTED=TRUE
+
+goto :EOF
+
+REM ******************************************************
+REM ************* Execute Batch file only once ***********
+REM ******************************************************
+
+:ExecuteBatch
+echo Calling %1 %2 %3 %4 %5 %6 %7 %8
+call %1 %2 %3 %4 %5 %6 %7 %8
+
+:end
+
+if "%NOPAUSE%" == "" pause


Property changes on: projects/microcontainer/trunk/metatype/build.bat
___________________________________________________________________
Name: svn:executable
   + 

Added: projects/microcontainer/trunk/metatype/build.sh
===================================================================
--- projects/microcontainer/trunk/metatype/build.sh	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/build.sh	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,172 @@
+#!/bin/sh
+### ====================================================================== ###
+##                                                                          ##
+##  This is the main entry point for the build system.                      ##
+##                                                                          ##
+##  Users should be sure to execute this file rather than 'ant' to ensure   ##
+##  the correct version is being used with the correct configuration.       ##
+##                                                                          ##
+### ====================================================================== ###
+
+# $Id: build.sh 31497 2005-05-24 16:47:10Z adrian $
+
+PROGNAME=`basename $0`
+DIRNAME=`dirname $0`
+GREP="grep"
+ROOT="/"
+
+# Ignore user's ANT_HOME if it is set
+ANT_HOME=""
+
+# the default search path for ant
+ANT_SEARCH_PATH="\
+    tools
+    tools/ant \
+    tools/apache/ant \
+    ant"
+
+# the default build file name
+ANT_BUILD_FILE="build.xml"
+
+# the default arguments
+ANT_OPTIONS="-find $ANT_BUILD_FILE"
+
+# Use the maximum available, or set MAX_FD != -1 to use that
+MAX_FD="maximum"
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false;
+darwin=false;
+case "`uname`" in
+    CYGWIN*)
+        cygwin=true
+        ;;
+
+    Darwin*)
+        darwin=true
+        ;;
+esac
+
+#
+# Helper to complain.
+#
+die() {
+    echo "${PROGNAME}: $*"
+    exit 1
+}
+
+#
+# Helper to complain.
+#
+warn() {
+    echo "${PROGNAME}: $*"
+}
+
+#
+# Helper to source a file if it exists.
+#
+maybe_source() {
+    for file in $*; do
+	if [ -f "$file" ]; then
+	    . $file
+	fi
+    done
+}
+
+search() {
+    search="$*"
+    for d in $search; do
+	ANT_HOME="`pwd`/$d"
+	ANT="$ANT_HOME/bin/ant"
+	if [ -x "$ANT" ]; then
+	    # found one
+	    echo $ANT_HOME
+	    break
+	fi
+    done
+}
+
+#
+# Main function.
+#
+main() {
+    # if there is a build config file. then source it
+    maybe_source "$DIRNAME/build.conf" "$HOME/.build.conf"
+
+    # Increase the maximum file descriptors if we can
+    if [ $cygwin = "false" ]; then
+	MAX_FD_LIMIT=`ulimit -H -n`
+	if [ $? -eq 0 ]; then
+	    if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ]; then
+		# use the system max
+		MAX_FD="$MAX_FD_LIMIT"
+	    fi
+
+	    ulimit -n $MAX_FD
+	    if [ $? -ne 0 ]; then
+		warn "Could not set maximum file descriptor limit: $MAX_FD"
+	    fi
+	else
+	    warn "Could not query system maximum file descriptor limit: $MAX_FD_LIMIT"
+	fi
+    fi
+
+    # try the search path
+    ANT_HOME=`search $ANT_SEARCH_PATH`
+
+    # try looking up to root
+    if [ "x$ANT_HOME" = "x" ]; then
+	target="build"
+	_cwd=`pwd`
+
+	while [ "x$ANT_HOME" = "x" ] && [ "$cwd" != "$ROOT" ]; do
+	    cd ..
+	    cwd=`pwd`
+	    ANT_HOME=`search $ANT_SEARCH_PATH`
+	done
+
+	# make sure we get back
+	cd $_cwd
+
+	if [ "$cwd" != "$ROOT" ]; then
+	    found="true"
+	fi
+
+	# complain if we did not find anything
+	if [ "$found" != "true" ]; then
+	    die "Could not locate Ant; check \$ANT or \$ANT_HOME."
+	fi
+    fi
+
+    # make sure we have one
+    ANT=$ANT_HOME/bin/ant
+    if [ ! -x "$ANT" ]; then
+	die "Ant file is not executable: $ANT"
+    fi
+
+    # need to specify planet57/buildmagic protocol handler package
+    ANT_OPTS="-Djava.protocol.handler.pkgs=org.jboss.net.protocol"
+
+    # setup some build properties
+    ANT_OPTS="$ANT_OPTS -Dbuild.script=$0"
+
+    # change to the directory where the script lives so users are not forced
+    # to be in the same directory as build.xml
+    cd $DIRNAME
+
+    # export some stuff for ant
+    export ANT ANT_HOME ANT_OPTS
+
+    # execute in debug mode, or simply execute
+    if [ "x$ANT_DEBUG" != "x" ]; then
+	/bin/sh -x $ANT $ANT_OPTIONS "$@"
+    else
+	exec $ANT $ANT_OPTIONS "$@"
+    fi
+}
+
+##
+## Bootstrap
+##
+
+main "$@"


Property changes on: projects/microcontainer/trunk/metatype/build.sh
___________________________________________________________________
Name: svn:executable
   + 

Added: projects/microcontainer/trunk/metatype/build.xml
===================================================================
--- projects/microcontainer/trunk/metatype/build.xml	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/build.xml	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,159 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE project [
+   <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
+   <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
+   <!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
+]>
+
+<!-- ====================================================================== -->
+<!--                                                                        -->
+<!--  JBoss, the OpenSource J2EE webOS                                      -->
+<!--                                                                        -->
+<!--  Distributable under LGPL license.                                     -->
+<!--  See terms of license at http://www.gnu.org.                           -->
+<!--                                                                        -->
+<!-- ====================================================================== -->
+
+<!-- $Id: build.xml 58705 2006-11-28 16:24:22Z adrian at jboss.org $ -->
+
+<project default="main" name="JBoss/MetaType">
+
+  <!-- ================================================================== -->
+  <!-- Setup                                                              -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Include the common Buildmagic elements.
+     |
+     | This defines several different targets, properties and paths.
+     | It also sets up the basic extention tasks amoung other things.
+   -->
+
+  &buildmagic;
+
+  <!--
+     | Include the normal targets.
+   -->
+  &targets;
+
+  <!-- ================================================================== -->
+  <!-- Configuration                                                      -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Configure the build system.
+     |
+     | This target is invoked by the Buildmagic initialization logic and
+     | should contain module specific configuration elements.
+   -->
+
+  <target name="configure" unless="configure.disable">
+
+    <!-- =================== -->
+    <!-- Basic Configuration -->
+    <!-- =================== -->
+
+    <!-- Module name(s) & version -->
+    <property name="module.name" value="metatype"/>
+    <property name="module.Name" value="JBoss MetaType"/>
+    <property name="module.version" value="DEV"/>
+
+    <!-- ========= -->
+    <!-- Libraries -->
+    <!-- ========= -->
+
+    &libraries;
+
+    <!-- The combined library classpath -->
+    <path id="library.classpath">
+      <path refid="jboss/common.core.classpath"/>
+      <path refid="jboss/common.logging.spi.classpath"/>
+      <path refid="jboss/common.logging.log4j.classpath"/>
+    </path>
+
+    <!-- The combined dependant module classpath -->
+    <path id="dependentmodule.classpath">
+    </path>
+
+   <!-- ============================= -->
+   <!-- Paths etc. for the retro task -->
+   <!-- ============================= -->
+   <property name="build.classes.retro" value="${module.output}/classes-retro"/>
+   <property name="build.lib.retro" value="${module.output}/lib14"/>
+   <path id="jbossretro.classpath">
+     <path refid="apache.ant.classpath"/>
+     <path refid="jboss.jbossretro.classpath"/>
+     <path refid="jboss/backport.concurrent.classpath"/>
+     <path refid="javassist.classpath"/>
+   </path>
+
+     
+    <!-- ===== -->
+    <!-- Tasks -->
+    <!-- ===== -->
+
+    <property name="jar.prefix" value="jboss-metatype"/>
+    <property name="javac.target" value="1.5"/>
+    <property name="javac.source" value="1.5"/>
+
+    <call target="_default:task-init"/>
+
+  </target>
+
+  <!-- ================================================================== -->
+  <!-- Compile                                                            -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Compile everything.
+     |
+     | This target should depend on other compile-* targets for each
+     | different type of compile that needs to be performed, short of
+     | documentation compiles.
+   -->
+
+  <target name="compile"
+	  description="Compile all source files."
+	  depends="_default:compile-classes,
+              _default:compile-etc,
+              retro"
+  />
+
+  <target name="retro">
+    <mkdir dir="${build.lib.retro}"/>
+    <taskdef name="retro" classname="org.jboss.ant.tasks.retro.Retro" classpathref="jbossretro.classpath"/>
+    <retro compilerclasspathref="jbossretro.classpath" destdir="${build.classes.retro}">
+      <classpath refid="jbossretro.classpath"/>
+      <classpath refid="library.classpath"/>
+      <classpath refid="dependentmodule.classpath"/>
+      <classpath>
+        <pathelement path="${build.classes}"/>
+      </classpath>
+      <src path="${build.classes}"/>
+    </retro>      
+  </target> 
+   
+  <!-- ================================================================== -->
+  <!-- Archives                                                           -->
+  <!-- ================================================================== -->
+
+  <!-- 
+     |  Build all jar files.
+    -->
+  <target name="module-jars" depends="init">
+    
+    <jar jarfile="${build.lib}/${jar.prefix}.jar" manifest="${build.etc}/default.mf">
+      <fileset dir="${build.classes}"/>
+    </jar>
+    <jar jarfile="${build.lib.retro}/${jar.prefix}14.jar" manifest="${build.etc}/default.mf">
+      <fileset dir="${build.classes.retro}"/>
+    </jar>
+    <!-- Minimal source bundle -->
+    <zip destfile="${build.lib}/${jar.prefix}-src.zip">
+      <fileset dir="${source.java}">
+        <include name="**"/>
+      </fileset>
+    </zip>
+  </target>
+
+</project>

Added: projects/microcontainer/trunk/metatype/src/etc/default.mf
===================================================================
--- projects/microcontainer/trunk/metatype/src/etc/default.mf	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/etc/default.mf	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,10 @@
+Manifest-Version: 1.0
+Created-By: @java.vm.version@ (@java.vm.vendor@)
+Specification-Title: @specification.title@
+Specification-Version: @specification.version@
+Specification-Vendor: @specification.vendor@
+Implementation-Title: @implementation.title@
+Implementation-URL: @implementation.url@
+Implementation-Version: @implementation.version@
+Implementation-Vendor: @implementation.vendor@
+Implementation-Vendor-Id: @implementation.vendor.id@

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/AbstractMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/AbstractMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/AbstractMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,260 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.io.ObjectStreamField;
+import java.io.Serializable;
+
+/**
+ * AbstractMetaType.
+ * 
+ * @param <T> the underlying type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class AbstractMetaType<T extends Serializable> implements MetaType<T>
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 5786422588217893696L;
+
+   /** The peristent fields */
+   private static final ObjectStreamField[] serialPersistentFields =
+      new ObjectStreamField[]
+      {
+         new ObjectStreamField("className",   String.class),
+         new ObjectStreamField("description", String.class),
+         new ObjectStreamField("typeName",    String.class)
+      };
+
+   /** The type's class name */
+   private String className;
+
+   // TODO internationalization
+   /** The type's description */
+   private String description;
+
+   /** The type's name */
+   private String typeName;
+
+   /** Whether the class is an array */
+   private transient boolean array = false;
+
+   /**
+    * Construct a new MetaType.<p>
+    *
+    * The class name must be in {@link #ALLOWED_CLASSNAMES} or an
+    * array of those classes.
+    *
+    * @param className the name of the class implementing the meta type,
+    *        cannot be null
+    * @param typeName the name of the meta type, cannot be null
+    * @param description the human readable description of the type, cannot 
+    *        be null
+    * @throws IllegalArgumentException for a null argument or a class is not an allowed class
+    */
+   protected AbstractMetaType(String className, String typeName, String description)
+   {
+      init(className, typeName, description);
+   }
+
+   /**
+    * Construct a new MetaType.<p>
+    *
+    * The class name must be in {@link #ALLOWED_CLASSNAMES} or an
+    * array of those classes.
+    *
+    * @param className the name of the class implementing the meta type,
+    *        cannot be null
+    * @param description the human readable description of the type, cannot 
+    *        be null
+    * @throws IllegalArgumentException for a null argument or a class is not an allowed class
+    */
+   protected AbstractMetaType(String className, String description)
+   {
+      init(className, className, description);
+   }
+
+   /**
+    * Construct a new MetaType.
+    *
+    * The class name must be in {@link #ALLOWED_CLASSNAMES} or an
+    * array of those classes.
+    *
+    * @param className the name of the class implementing the meta type,
+    *        cannot be null
+    * @throws IllegalArgumentException for a null argument or a class is not an allowed class
+    */
+   protected AbstractMetaType(String className)
+   {
+      init(className, className, className);
+   }
+
+   public String getClassName()
+   {
+      return className;
+   }
+
+   public String getTypeName()
+   {
+      return typeName;
+   }
+
+   public String getDescription()
+   {
+      return description;
+   }
+
+   public boolean isArray()
+   {
+      return array;
+   }
+
+   public abstract boolean isValue(Object obj);
+
+   @Override
+   public abstract boolean equals(Object obj);
+
+   @Override
+   public abstract int hashCode();
+
+   @Override
+   public abstract String toString();
+
+   /**
+    * Initialise the object
+    *
+    * @param className the name of the class implementing the meta type,
+    *        cannot be null or an empty
+    * @param typeName the name of the meta type, cannot be null or an empty 
+    *        string
+    * @param description the human readable description of the type, cannot 
+    *        be null or an empty string
+    * @exception IllegalArgumentException for a null or empty argument or when class name is not allowed class
+    */
+   private void init(String className, String typeName, String description)
+   {
+      if (className == null || className.trim().equals(""))
+         throw new IllegalArgumentException("null or empty class name");
+      if (typeName == null || typeName.trim().equals(""))
+         throw new IllegalArgumentException("null or empty type name");
+      if (description == null || description.trim().equals(""))
+         throw new IllegalArgumentException("null or empty description");
+
+      // Calculate the underlying class and whether this is an array
+      String testClassName = getBaseClassName(className);
+      if (testClassName == null)
+         throw new IllegalArgumentException("Invalid array declaration (see the javadocs for java.lang.Class): " + className);
+      if (testClassName.equals(className) == false)
+         array = true;
+
+      // Check the underlying class
+      boolean ok = false;
+      for (int i = 0; i < ALLOWED_CLASSNAMES.length; i++)
+      {
+         if (testClassName.equals(ALLOWED_CLASSNAMES[i]))
+         {
+            ok = true;
+            break;
+         }
+      }
+      if (ok == false)
+         throw new IllegalArgumentException("Not a MetaType allowed class name: " + className);
+
+      // Looks ok
+      this.className = className;
+      this.typeName = typeName;
+      this.description = description;
+   }
+
+   /**
+    * Gets the base class name, either the passed class name
+    * or the underlying class name if it is an array.<p>
+    *
+    * NOTE: The class is not check for validity.<p>
+    *
+    * Null is returned when the array declaration is invalid.
+    *
+    * @param className the string to test
+    * @return the underlying class name or null
+    */
+   private static String getBaseClassName(String className)
+   {
+      final int length = className.length();
+      final int last = length - 1;
+      int i = 0;
+
+      // Eat the array dimensions
+      while (i < length && className.charAt(i) == '[')
+         ++i;
+
+      // It looks like an array
+      if (i > 0)
+      {
+         // But is it valid
+         char type = className.charAt(i);
+         // Primitive array
+         if (type == 'B' || type == 'C' || type == 'D' || type == 'F' ||
+             type == 'I' || type == 'J' || type == 'S' || type == 'Z' || type == 'V')
+         {
+            if (i != last)
+               return null;
+            return className.substring(last, length);
+         }
+         // Object Array
+         else if (className.charAt(i) != 'L' ||
+             i >= last-1 ||
+             className.charAt(last) != ';')
+            return null;
+
+         // Potentially valid array, class name might be rubbish
+         return className.substring(i+1, last);
+      }
+
+      // Not an array
+      return className;
+   }
+
+   /**
+    * Read the object from a stream
+    * 
+    * @param in the stream
+    * @throws IOException 
+    * @throws ClassNotFoundException
+    */
+   private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
+   {
+      ObjectInputStream.GetField getField = in.readFields();
+      String className = (String) getField.get("className", null);
+      String typeName = (String) getField.get("typeName", null);
+      String description = (String) getField.get("description", null);
+      try
+      {
+         init(className, typeName, description);
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Unexpected error deserializing MetaType: " + className, e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ArrayMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ArrayMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ArrayMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,218 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.io.Serializable;
+
+/**
+ * ArrayMetaType.
+ *
+ * @param <T> the underlying type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayMetaType<T extends Serializable> extends AbstractMetaType<T>
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -2062790692152055156L;
+
+   /** The number of dimensions in the array */
+   private int dimension = 0;
+
+   /** The element type for the array */
+   private MetaType elementType;
+
+   /** Cached hash code */
+   private transient int cachedHashCode = Integer.MIN_VALUE;
+
+   /** Cached string representation */
+   private transient String cachedToString = null;
+
+   /**
+    * Generate the class and type name
+    * 
+    * @param dimension the dimension
+    * @param elementType the element type
+    */
+   private static String genName(int dimension, MetaType elementType)
+   {
+      if (dimension < 1)
+         throw new IllegalArgumentException("negative dimension");
+      if (elementType == null)
+         throw new IllegalArgumentException("null element type");
+      if (elementType instanceof ArrayMetaType)
+         throw new IllegalArgumentException("array type cannot be an element of an array type");
+      StringBuilder buffer = new StringBuilder();
+      for (int i=0; i < dimension; i++)
+         buffer.append('[');
+      buffer.append('L');
+      buffer.append(elementType.getClassName());
+      buffer.append(';');
+      return buffer.toString();
+   }
+
+   /**
+    * Generate the description
+    * 
+    * @param dimension the dimension
+    * @param elementType the element type
+    */
+   private static String genDesc(int dimension, MetaType elementType)
+   {
+      StringBuilder buffer = new StringBuilder();
+      buffer.append(new Integer(dimension));
+      buffer.append("-dimension array of ");
+      buffer.append(elementType.getClassName());
+      return buffer.toString();
+   }
+
+   /**
+    * Construct an ArrayMetaType.
+    *
+    * @param dimension the number of dimensions in the array
+    * @param elementType the open type of the array elements
+    * @throws IllegalArgumentException for a null argument or non-negative dimension or when meta type is an ArrayMetaType
+    */
+   public ArrayMetaType(int dimension, MetaType elementType)
+   {
+      super(genName(dimension, elementType), genDesc(dimension, elementType));
+      this.dimension = dimension;
+      this.elementType = elementType;
+   }
+
+   /**
+    * Get the dimension of the array
+    *
+    * @return the dimension
+    */
+   public int getDimension()
+   {
+      return dimension;
+   }
+
+   /**
+    * Get the meta type of the array elements
+    *
+    * @return the element type
+    */
+   public MetaType getElementType()
+   {
+      return elementType;
+   }
+
+   @Override
+   @SuppressWarnings("unchecked")
+   public boolean isValue(Object obj)
+   {
+      if (obj == null)
+         return false;
+
+      Class clazz = obj.getClass();
+      if (clazz.isArray() == false)
+         return false;
+      
+      if (elementType instanceof SimpleMetaType)
+         return recursiveCheck((Object[]) obj, dimension);
+      
+      if (elementType instanceof TableMetaType || elementType instanceof CompositeMetaType)
+      {
+         Class thisClass = null;
+         try
+         {
+            thisClass = Thread.currentThread().getContextClassLoader().loadClass(getClassName());
+         }
+         catch (ClassNotFoundException e)
+         {
+            return false;
+         }
+         if (thisClass.isAssignableFrom(clazz) == false)
+            return false;
+         return recursiveCheck((Object[]) obj, dimension);
+      }
+      return false;
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (this == obj)
+         return true;
+      if (obj == null || obj instanceof ArrayMetaType == false)
+         return false;
+      ArrayMetaType other = (ArrayMetaType) obj;
+      return getDimension() == other.getDimension() && getElementType().equals(other.getElementType());
+   }
+
+   @Override
+   public int hashCode()
+   {
+      if (cachedHashCode != Integer.MIN_VALUE)
+         return cachedHashCode;
+      cachedHashCode = getDimension() + getElementType().hashCode();
+      return cachedHashCode;
+   }
+
+   @Override
+   public String toString()
+   {
+      if (cachedToString != null)
+         return cachedToString;
+      StringBuilder buffer = new StringBuilder(ArrayMetaType.class.getSimpleName());
+      buffer.append("{type=");
+      buffer.append(getTypeName());
+      buffer.append(" dims=");
+      buffer.append(dimension);
+      buffer.append(" elementType=" + elementType);
+      cachedToString = buffer.toString();
+      return cachedToString;
+   }
+
+   /**
+    * Recursively check array elements
+    * 
+    * @param elements the elements
+    * @param dimension the dimension
+    */
+   private boolean recursiveCheck(Object[] elements, int dimension)
+   {
+      // Reached the end
+      if (dimension == 1)
+      {
+         // Check each element is the correct type
+         for (int i = 0; i < elements.length; i++)
+         {
+            if (elements[i] != null && elementType.isValue(elements[i]) == false)
+               return false;
+         }
+      }
+      else
+      {
+         // Check the array element in this array element
+         for (int i = 0; i < elements.length; i++)
+         {
+            if (recursiveCheck((Object[]) elements[i], dimension-1) == false)
+               return false;
+         }
+      }
+      return true;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/CompositeMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/CompositeMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/CompositeMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.util.Set;
+
+/**
+ * CompositeMetaType.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface CompositeMetaType extends MetaType
+{
+   /**
+    * Determine whether this CompositeMetaType contains the itemName
+    *
+    * @param itemName the item name
+    * @return true when it does, false otherwise
+    */
+   boolean containsKey(String itemName);
+
+   /**
+    * Retrieve the description for an item name
+    *
+    * @param itemName the item name
+    * @return the description or null when there is no such item name
+    */
+   String getDescription(String itemName);
+
+   /**
+    * Retrieve the meta type for an item name
+    *
+    * @param itemName the item name
+    * @return the open type or null when there is no such item name
+    */
+   MetaType getType(String itemName);
+
+   /**
+    * Retrieve an unmodifiable Set view of all the item names in ascending order.
+    *
+    * @return the Set
+    */
+   Set<String> keySet();
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableCompositeMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableCompositeMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableCompositeMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,215 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.Set;
+import java.util.TreeMap;
+
+import org.jboss.metatype.api.values.CompositeValue;
+
+/**
+ * ImmutableCompositeMetaType.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ImmutableCompositeMetaType extends AbstractMetaType implements CompositeMetaType
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1133171306971861455L;
+
+   /** Item names to descriptions */
+   private TreeMap<String, String> nameToDescription;
+
+   /** Item names to meta types */
+   private TreeMap<String, MetaType> nameToType;
+
+   /** Cached hash code */
+   private transient int cachedHashCode = Integer.MIN_VALUE;
+
+   /** Cached string representation */
+   private transient String cachedToString = null;
+
+   /**
+    * Construct a composite meta type. The parameters are checked for validity.<p>
+    *
+    * The three arrays are internally copied. Future changes to these
+    * arrays do not alter the composite type.<p>
+    *
+    * getClassName() returns {@link CompositeValue}<p>
+    *
+    * @param typeName the name of the composite type, cannot be null or  empty
+    * @param description the human readable description of the composite type, cannot be null or empty
+    * @param itemNames the names of the items described by this type. Cannot
+    *        be null, must contain at least one element, the elements cannot
+    *        be null or empty. The order of the items is unimportant when
+    *        determining equality.
+    * @param itemDescriptions the human readable descriptions of the items
+    *        in the same order as the itemNames, cannot be null must have the
+    *        same number of elements as the itemNames. The elements cannot
+    *        be null or empty.
+    * @param itemTypes the MetaTypes of the items in the same order as the
+    *        item names, cannot be null must have the
+    *        same number of elements as the itemNames. The elements cannot
+    *        be null.
+    * @exception IllegalArgumentException when a parameter does not match
+    *            what is described above or when itemNames contains a duplicate name.
+    *            The names are case sensitive, leading and trailing whitespace
+    *            is ignored.
+    */
+   public ImmutableCompositeMetaType(String typeName, String description, String[] itemNames, String[] itemDescriptions, MetaType[] itemTypes)
+   {
+      super(CompositeValue.class.getName(), typeName, description);
+      if (itemNames == null || itemNames.length == 0)
+         throw new IllegalArgumentException("null or empty itemNames");
+      if (itemDescriptions == null || itemDescriptions.length == 0)
+         throw new IllegalArgumentException("null or empty itemDescriptions");
+      if (itemTypes == null || itemTypes.length == 0)
+         throw new IllegalArgumentException("null or empty itemTypes");
+      if (itemNames.length != itemDescriptions.length)
+         throw new IllegalArgumentException("wrong number of itemDescriptions");
+      if (itemNames.length != itemTypes.length)
+         throw new IllegalArgumentException("wrong number of itemTypes");
+      nameToDescription = new TreeMap<String, String>();
+      nameToType = new TreeMap<String, MetaType>();
+      for (int i = 0; i < itemNames.length; ++i)
+      {
+          if (itemNames[i] == null)
+             throw new IllegalArgumentException("null item name " + i);
+          String itemName = itemNames[i].trim();
+          if (itemName.length() == 0)
+             throw new IllegalArgumentException("empty item name " + i);
+          if (nameToDescription.containsKey(itemName))
+             throw new IllegalArgumentException("duplicate item name " + itemName);
+          if (itemDescriptions[i] == null)
+             throw new IllegalArgumentException("null item description " + i);
+          String itemDescription = itemDescriptions[i].trim();
+          if (itemDescription.length() == 0)
+             throw new IllegalArgumentException("empty item description " + i);
+          if (itemTypes[i] == null)
+             throw new IllegalArgumentException("null item type " + i);
+          nameToDescription.put(itemName, itemDescription);
+          nameToType.put(itemName, itemTypes[i]);
+      }
+   }
+
+   public boolean containsKey(String itemName)
+   {
+      if (itemName == null)
+         return false;
+      return nameToDescription.containsKey(itemName);
+   }
+
+   public String getDescription(String itemName)
+   {
+      if (itemName == null)
+         return null;
+      return nameToDescription.get(itemName);
+   }
+
+   public MetaType getType(String itemName)
+   {
+      if (itemName == null)
+         return null;
+      return nameToType.get(itemName);
+   }
+
+   public Set<String> keySet()
+   {
+      return Collections.unmodifiableSet(nameToDescription.keySet());
+   }
+
+   @Override
+   public boolean isValue(Object obj)
+   {
+      if (obj == null || obj instanceof CompositeValue == false)
+         return false;
+      return equals(((CompositeValue) obj).getMetaType());
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (this == obj)
+         return true;
+      if (obj == null || obj instanceof ImmutableCompositeMetaType == false)
+         return false;
+
+      ImmutableCompositeMetaType other = (ImmutableCompositeMetaType) obj;
+      if (this.getTypeName().equals(other.getTypeName()) == false)
+         return false;
+      Iterator<String> thisNames = this.keySet().iterator();
+      Iterator<String> otherNames = other.keySet().iterator();
+      while(thisNames.hasNext() && otherNames.hasNext())
+      {
+         String thisName = thisNames.next();
+         String otherName = otherNames.next();
+         if (thisName.equals(otherName) == false)
+            return false;
+         if (this.getType(thisName).equals(other.getType(otherName)) == false)
+            return false;
+      }
+      if (thisNames.hasNext() || otherNames.hasNext())
+         return false;
+      
+      return true;
+   }
+
+   @Override
+   public int hashCode()
+   {
+      if (cachedHashCode != Integer.MIN_VALUE)
+         return cachedHashCode;
+      cachedHashCode = getTypeName().hashCode();
+      for (Iterator i = nameToType.values().iterator(); i.hasNext();)
+         cachedHashCode += i.next().hashCode();
+      for (Iterator i = nameToDescription.keySet().iterator(); i.hasNext();)
+         cachedHashCode += i.next().hashCode();
+      return cachedHashCode;
+   }
+
+   @Override
+   public String toString()
+   {
+      if (cachedToString != null)
+         return cachedToString;
+      StringBuilder buffer = new StringBuilder(getClass().getSimpleName());
+      buffer.append("{items=");
+      Iterator<String> thisNames = keySet().iterator();
+      while(thisNames.hasNext())
+      {
+         String thisName = thisNames.next();
+         buffer.append("[");
+         buffer.append("name=");
+         buffer.append(thisName);
+         buffer.append(" type=");
+         buffer.append(getType(thisName));
+         buffer.append("]");
+         if (thisNames.hasNext())
+           buffer.append(", ");
+      }
+      cachedToString = buffer.toString();
+      return cachedToString;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableTableMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableTableMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/ImmutableTableMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,167 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.List;
+
+import org.jboss.metatype.api.values.TableValue;
+
+public class ImmutableTableMetaType extends AbstractMetaType implements TableMetaType
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 5791103660662775558L;
+
+   /** The open type of the rows */
+   private CompositeMetaType rowType;
+
+   /** Index names */
+   private List<String> indexNames;
+
+   /** Cached hash code */
+   private transient int cachedHashCode = Integer.MIN_VALUE;
+
+   /** Cached string representation */
+   private transient String cachedToString = null;
+
+   /**
+    * Construct a tabe type. The parameters are checked for validity.
+    *
+    * @param typeName the name of the tabular type, cannot be null or empty
+    * @param description the human readable description of the tabular type, cannot be null or empty
+    * @param rowType the type of the row elements in the tabular data, cannot be null
+    * @param indexNames the names of the item values that uniquely index each
+    *        row element in the tabular data, cannot be null or empty. Each
+    *        element must be an item name in the rowType, nul or empty is not
+    *        allowed. The order of the item names in this parameter is used
+    *        by {@link TableValue#get} and {@link TableValue#remove} the 
+    *        TabularValue to match the array of values to items.
+    * @throws IllegalArgumentException when a parameter does not match
+    *         what is described above or when an element of indexNames is not defined
+    *         in rowType.
+    */
+   public ImmutableTableMetaType(String typeName, String description, CompositeMetaType rowType, String[] indexNames)
+   {
+      super(TableValue.class.getName(), typeName, description);
+      if (rowType == null)
+         throw new IllegalArgumentException("null rowType");
+      if (indexNames == null || indexNames.length == 0)
+         throw new IllegalArgumentException("null or empty indexNames");
+      this.rowType = rowType;
+      this.indexNames = new ArrayList<String>();
+      for (int i = 0; i < indexNames.length; i++)
+      {
+          if (indexNames[i] == null)
+             throw new IllegalArgumentException("null index name " + i);
+          String indexName = indexNames[i].trim();
+          if (indexName.length() == 0)
+             throw new IllegalArgumentException("empty index name " + i);
+          if (rowType.containsKey(indexName) == false)
+             throw new IllegalArgumentException("no item name " + indexName);
+          this.indexNames.add(indexName);
+      }
+   }
+
+   public CompositeMetaType getRowType()
+   {
+      return rowType;
+   }
+
+   public List<String> getIndexNames()
+   {
+      return Collections.unmodifiableList(indexNames);
+   }
+
+   @Override
+   public boolean isValue(Object obj)
+   {
+      if (obj == null || obj instanceof TableValue == false)
+         return false;
+      TableMetaType other = ((TableValue) obj).getMetaType();
+      return equals(other);
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (this == obj)
+         return true;
+      if (obj == null || obj instanceof TableMetaType == false)
+         return false;
+
+      TableMetaType other = (TableMetaType) obj;
+      if (this.getTypeName().equals(other.getTypeName()) == false)
+         return false;
+      if (this.getRowType().equals(other.getRowType()) == false)
+         return false;
+      Iterator<String> thisNames = this.getIndexNames().iterator();
+      Iterator<String> otherNames = other.getIndexNames().iterator();
+      while (thisNames.hasNext() && otherNames.hasNext())
+      {
+         String thisName = thisNames.next();
+         String otherName = otherNames.next();
+         if (thisName.equals(otherName) == false)
+            return false;
+      }
+      if (thisNames.hasNext() || otherNames.hasNext())
+         return false;
+
+      return true;
+   }
+
+   @Override
+   public int hashCode()
+   {
+      if (cachedHashCode != Integer.MIN_VALUE)
+         return cachedHashCode;
+      cachedHashCode = getTypeName().hashCode();
+      cachedHashCode += getRowType().hashCode();
+      for (Iterator i = indexNames.iterator(); i.hasNext();)
+         cachedHashCode += i.next().hashCode();
+      return cachedHashCode;
+   }
+
+   @Override
+   public String toString()
+   {
+      if (cachedToString != null)
+         return cachedToString;
+      StringBuilder buffer = new StringBuilder(getClass().getSimpleName());
+      buffer.append(": typeName=[");
+      buffer.append(getTypeName());
+      buffer.append("] rowType=[");
+      buffer.append(getRowType());
+      buffer.append("] indexNames=[");
+      Iterator thisNames = getIndexNames().iterator();
+      while(thisNames.hasNext())
+      {
+         buffer.append(thisNames.next());
+         if (thisNames.hasNext())
+            buffer.append(", ");
+      }
+      buffer.append("]");
+      cachedToString = buffer.toString();
+      return cachedToString;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/MetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/MetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/MetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,120 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.io.Serializable;
+import java.math.BigDecimal;
+import java.math.BigInteger;
+import java.util.Date;
+
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.SimpleValue;
+import org.jboss.metatype.api.values.TableValue;
+
+/**
+ * MetaType.
+ * 
+ * @param <T> the underlying type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface MetaType<T extends Serializable> extends Serializable
+{
+   /**
+    * The allowed classnames.<p>
+    *
+    * One of<br>
+    * java.lang.Void<br>
+    * java.lang.Boolean<br>
+    * java.lang.Character<br>
+    * java.lang.Byte<br>
+    * java.lang.Short<br>
+    * java.lang.Integer<br>
+    * java.lang.Long<br>
+    * java.lang.Float<br>
+    * java.lang.Double<br>
+    * java.lang.String<br>
+    * java.lang.Date<br>
+    * java.math.BigDecimal<br>
+    * java.math.BigInteger<br>
+    * {@link SimpleValue}<br>
+    * {@link CompositeValue}<br>
+    * {@link TableValue}
+    */
+   String[] ALLOWED_CLASSNAMES =
+   {
+      Void.class.getName(),
+      Boolean.class.getName(),
+      Character.class.getName(),
+      Byte.class.getName(),
+      Short.class.getName(),
+      Integer.class.getName(),
+      Long.class.getName(),
+      Float.class.getName(),
+      Double.class.getName(),
+      String.class.getName(),
+      Date.class.getName(),
+      BigDecimal.class.getName(),
+      BigInteger.class.getName(),
+      SimpleValue.class.getName(),
+      CompositeValue.class.getName(),
+      TableValue.class.getName()
+   };
+
+   /**
+    * Retrieve the class name of the values of this meta
+    * type. It is one of those listed in ALLOWED_CLASSNAMES or
+    * a (multi-dimensional) array of one of those classes.
+    *
+    * @return the class name
+    */
+   String getClassName();
+
+   /**
+    * Retrieve the name of the meta type
+    *
+    * @return the type name
+    */
+   String getTypeName();
+
+   /**
+    * Retrieve the description of the type
+    *
+    * @return the description
+    */
+   String getDescription();
+
+   /**
+    * Retrieve whether the class name of the type is an array
+    *
+    * @return true when it is an array or false otherwise
+    */
+   boolean isArray();
+
+   /**
+    * Whether the passed value is one of those described by this meta type.
+    *
+    * @param obj the object to test
+    * @return true when it is value for this meta type, false otherwise
+    */
+   boolean isValue(Object obj);
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/SimpleMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/SimpleMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/SimpleMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,205 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.io.ObjectStreamException;
+import java.io.Serializable;
+import java.math.BigDecimal;
+import java.math.BigInteger;
+import java.util.Date;
+
+import org.jboss.metatype.api.values.SimpleValue;
+
+/**
+ * SimpleMetaType.
+ *
+ * @param <T> the underlying type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class SimpleMetaType<T extends Serializable> extends AbstractMetaType<T>
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 6786422588217893696L;
+
+   /** Cached hash code */
+   private transient int cachedHashCode;
+
+   /** Cached string representation */
+   private transient String cachedToString;
+
+   /** The simple type for java.math.BigDecimal */
+   public static final SimpleMetaType<BigDecimal> BIGDECIMAL;
+
+   /** The simple type for java.math.BigInteger */
+   public static final SimpleMetaType<BigInteger> BIGINTEGER;
+
+   /** The simple type for java.lang.Boolean */
+   public static final SimpleMetaType<Boolean> BOOLEAN;
+
+   /** The simple type for java.lang.Byte */
+   public static final SimpleMetaType<Byte> BYTE;
+
+   /** The simple type for java.lang.Character */
+   public static final SimpleMetaType<Character> CHARACTER;
+
+   /** The simple type for java.lang.Date */
+   public static final SimpleMetaType<Date> DATE;
+
+   /** The simple type for java.lang.Double */
+   public static final SimpleMetaType<Double> DOUBLE;
+
+   /** The simple type for java.lang.Float */
+   public static final SimpleMetaType<Float> FLOAT;
+
+   /** The simple type for java.lang.Integer */
+   public static final SimpleMetaType<Integer> INTEGER;
+
+   /** The simple type for java.lang.Long */
+   public static final SimpleMetaType<Long> LONG;
+
+   /** The simple type for java.lang.Short */
+   public static final SimpleMetaType<Short> SHORT;
+
+   /** The simple type for java.lang.String */
+   public static final SimpleMetaType<String> STRING;
+
+   /** The simple type for java.lang.Void */
+   public static final SimpleMetaType VOID;
+
+   static
+   {
+      BIGDECIMAL = new SimpleMetaType<BigDecimal>(BigDecimal.class.getName());
+      BIGINTEGER = new SimpleMetaType<BigInteger>(BigInteger.class.getName());
+      BOOLEAN = new SimpleMetaType<Boolean>(Boolean.class.getName());
+      BYTE = new SimpleMetaType<Byte>(Byte.class.getName());
+      CHARACTER = new SimpleMetaType<Character>(Character.class.getName());
+      DATE = new SimpleMetaType<Date>(Date.class.getName());
+      DOUBLE = new SimpleMetaType<Double>(Double.class.getName());
+      FLOAT = new SimpleMetaType<Float>(Float.class.getName());
+      INTEGER = new SimpleMetaType<Integer>(Integer.class.getName());
+      LONG = new SimpleMetaType<Long>(Long.class.getName());
+      SHORT = new SimpleMetaType<Short>(Short.class.getName());
+      STRING = new SimpleMetaType<String>(String.class.getName());
+      VOID = new SimpleMetaType(Void.class.getName());
+   }
+
+   /**
+    * Resolve a simple type
+    *
+    * @param className the class name of the simple type
+    * @return the simple type
+    */
+   public static SimpleMetaType resolve(String className)
+   {
+      if (className == null)
+         throw new IllegalArgumentException("Null class name");
+      if (className.equals(STRING.getClassName()))
+         return STRING;
+      if (className.equals(INTEGER.getClassName()))
+         return INTEGER;
+      if (className.equals(BOOLEAN.getClassName()))
+         return BOOLEAN;
+      if (className.equals(LONG.getClassName()))
+         return LONG;
+      if (className.equals(BYTE.getClassName()))
+         return BYTE;
+      if (className.equals(CHARACTER.getClassName()))
+         return CHARACTER;
+      if (className.equals(DOUBLE.getClassName()))
+         return DOUBLE;
+      if (className.equals(FLOAT.getClassName()))
+         return FLOAT;
+      if (className.equals(SHORT.getClassName()))
+         return SHORT;
+      if (className.equals(BIGDECIMAL.getClassName()))
+         return BIGDECIMAL;
+      if (className.equals(BIGINTEGER.getClassName()))
+         return BIGINTEGER;
+      if (className.equals(VOID.getClassName()))
+         return VOID;
+      if (className.equals(DATE.getClassName()))
+         return DATE;
+      throw new IllegalArgumentException(className);
+   }
+
+   /**
+    * Construct an SimpleMetaType.<p>
+    *
+    * This constructor is used to construct the static simple meta types.
+    *
+    * @param className the name of the class implementing the type
+    */
+   private SimpleMetaType(String className)
+   {
+      super(className);
+      cachedHashCode = getClassName().hashCode();
+      StringBuilder buffer = new StringBuilder(SimpleMetaType.class.getSimpleName());
+      buffer.append(":");
+      buffer.append(getClassName());
+      cachedToString = buffer.toString();
+   }
+
+   @Override
+   public boolean isValue(Object obj)
+   {
+      if (obj == null || obj instanceof SimpleValue == false)
+         return false;
+
+      SimpleValue value = (SimpleValue) obj;
+      return equals(value.getMetaType());
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (this == obj)
+         return true;
+      if (obj == null || obj instanceof SimpleMetaType == false)
+         return false;
+      SimpleMetaType other = (SimpleMetaType) obj;
+      return getClassName().equals(other.getClassName());
+   }
+
+   @Override
+   public int hashCode()
+   {
+      return cachedHashCode;
+   }
+
+   @Override
+   public String toString()
+   {
+      return cachedToString;
+   }
+
+   /**
+    * Resolve to the singletons
+
+    * @return the singletons
+    * @throws ObjectStreamException for a corrupted stream
+    */
+   private Object readResolve() throws ObjectStreamException
+   {
+      return resolve(getClassName());
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/TableMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/TableMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/types/TableMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,48 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.types;
+
+import java.util.List;
+
+/**
+ * TableMetaType.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface TableMetaType extends MetaType
+{
+   /**
+    * Retrieve the row type
+    *
+    * @return the row type
+    */
+   CompositeMetaType getRowType();
+
+   /**
+    * Retrieve an unmodifiable list of index names in the same order as
+    * passed to the constructor.
+    *
+    * @return the index names
+    */
+   List<String> getIndexNames();
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/AbstractMetaValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/AbstractMetaValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/AbstractMetaValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,47 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+/**
+ * AbstractMetaValue.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class AbstractMetaValue implements MetaValue
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -2213622770885293629L;
+
+   @Override
+   public MetaValue clone()
+   {
+      try
+      {
+         return (AbstractMetaValue) super.clone();
+      }
+      catch (CloneNotSupportedException e)
+      {
+         throw new Error("Unexpected error in clone: ", e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,114 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.util.Collection;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+
+/**
+ * CompositeValue.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface CompositeValue extends MetaValue
+{
+   CompositeMetaType getMetaType();
+   
+   /**
+    * Retrieve the value for the item with the passed key
+    *
+    * @param key the key to the item
+    * @return the value
+    * @throws IllegalArgumentException when the key is null or the empty string or when the key does not exist 
+    */
+   MetaValue get(String key);
+
+   /**
+    * Retrieve the array of values for the item with the passed keys
+    *
+    * @param keys an array of key values
+    * @return the array of values
+    * @throws IllegalArgumentException when a key is null or the empty
+    *         string or the array is null or when a key does not exist 
+    */
+   MetaValue[] getAll(String[] keys);
+
+   /**
+    * Tests whether a key is part of this composite value
+    *
+    * @param key the key to test
+    * @return true when the key exists, false otherwise
+    */
+   boolean containsKey(String key);
+
+   /**
+    * Tests whether a item exists with the passed value
+    *
+    * @param value the value to test
+    * @return true when the value exists, false otherwise
+    */
+   boolean containsValue(MetaValue value);
+
+   /**
+    * The values of this composite value<p>
+    *
+    * An iterator over the returned collection returns result in ascending
+    * lexicographic order
+    *
+    * @return an unmodifiable Collection of the values of this CompositeMetaType.
+    */
+   Collection<MetaValue> values();
+
+   /**
+    * Tests whether two composite value objects are equal<p>
+    *
+    * The object is non-null<br>
+    * The object implements this interface<br>
+    * The composite meta types are equal<br>
+    * The values are equal
+    *
+    * @param obj the object to test
+    * @return true when the above conditions are satisfied, false otherwise.
+    */
+   boolean equals(Object obj);
+
+   /**
+    * Generates a hashcode for the implementation.<p>
+    *
+    * The sum of the hashCodes for the elements mentioned in the equals method
+    *
+    * @return the calculated hashcode
+    */
+   int hashCode();
+
+   /**
+    * A string representation of the open mbean operation info.<p>
+    *
+    * It is made up of implementation class and the values mentioned
+    * in the equals method
+    *
+    * @return the string
+    */
+   String toString();
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValueSupport.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValueSupport.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/CompositeValueSupport.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,296 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.io.ObjectStreamField;
+import java.util.Collection;
+import java.util.Collections;
+import java.util.Iterator;
+import java.util.Map;
+import java.util.SortedMap;
+import java.util.TreeMap;
+import java.util.Map.Entry;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.MetaType;
+
+/**
+ * CompositeValueSupport.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class CompositeValueSupport extends AbstractMetaValue implements CompositeValue
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 6262188760975631870L;
+   
+   /** The serialized form */
+   private static final ObjectStreamField[] serialPersistentFields =
+      new ObjectStreamField[]
+      {
+         new ObjectStreamField("contents", SortedMap.class),
+         new ObjectStreamField("metaType", CompositeMetaType.class),
+      };
+
+   /** The contents */
+   private SortedMap<String, MetaValue> contents;
+
+   /** The composite type */
+   private CompositeMetaType metaType;
+
+   /** cached hashCode */
+   private transient int cachedHashCode = Integer.MIN_VALUE;
+
+   /**
+    * Construct Composite Value 
+    *
+    * @param metaType the composite meta type of the data
+    * @param itemNames the names of the values
+    * @param itemValues the values
+    * @throws IllegalArgumentException for a null or empty argument or when the items do not match the
+    *         CompositeType
+    */
+   public CompositeValueSupport(CompositeMetaType metaType, String[] itemNames, MetaValue[] itemValues)
+   {
+      if (metaType == null)
+         throw new IllegalArgumentException("null meta type");
+      if (itemNames == null)
+         throw new IllegalArgumentException("null itemNames");
+      if (itemValues == null)
+         throw new IllegalArgumentException("null itemValues");
+      if (itemNames.length == 0)
+         throw new IllegalArgumentException("empty itemNames");
+      if (itemValues.length == 0)
+         throw new IllegalArgumentException("empty itemValues");
+      if (itemNames.length != itemValues.length)
+         throw new IllegalArgumentException("itemNames has size " + itemNames.length + " but itemValues has size " + itemValues.length);
+
+      int compositeNameSize = metaType.keySet().size();
+      if (itemNames.length != compositeNameSize)
+         throw new IllegalArgumentException("itemNames has size " + itemNames.length + " but composite type has size " + compositeNameSize);
+
+      this.metaType = metaType;
+      contents = new TreeMap<String, MetaValue>();
+
+      for (int i = 0; i < itemNames.length; i++)
+      {
+         if (itemNames[i] == null || itemNames[i].length() == 0)
+            throw new IllegalArgumentException("Item name " + i + " is null or empty");
+         if (contents.get(itemNames[i]) != null)
+            throw new IllegalArgumentException("duplicate item name " + itemNames[i]);
+         MetaType itemType = metaType.getType(itemNames[i]);
+         if (itemType == null)
+            throw new IllegalArgumentException("item name not in composite type " + itemNames[i]);
+         if (itemValues[i] != null && itemType.isValue(itemValues[i]) == false)
+            throw new IllegalArgumentException("item value " + itemValues[i] + " for item name " + itemNames[i] + " is not a " + itemType);
+         contents.put(itemNames[i], itemValues[i]);
+      }
+   }
+
+   /**
+    * Construct Composite Value 
+    *
+    * @param compositeMetaType the composite type of the data
+    * @param items map of strings to values
+    * @throws IllegalArgumentException for a null or empty argument or when the items do not match the
+    *         CompositeType
+    */
+   public CompositeValueSupport(CompositeMetaType compositeMetaType, Map<String, MetaValue> items)
+   {
+      init(compositeMetaType, items);
+   }
+
+   public CompositeMetaType getMetaType()
+   {
+      return metaType;
+   }
+
+   public MetaValue get(String key)
+   {
+      validateKey(key);
+      return contents.get(key);
+   }
+
+   public MetaValue[] getAll(String[] keys)
+   {
+      if (keys == null)
+         throw new IllegalArgumentException("Null keys");
+
+      MetaValue[] result = new MetaValue[keys.length];
+      for (int i = 0; i < keys.length; i++)
+      {
+         validateKey(keys[i]);
+         result[i] = contents.get(keys[i]);
+      }
+      return result;
+   }
+
+   public boolean containsKey(String key)
+   {
+      if (key == null || key.length() == 0)
+         return false;
+      return contents.containsKey(key);
+   }
+
+   public boolean containsValue(MetaValue value)
+   {
+      return contents.containsValue(value);
+   }
+
+   public Collection<MetaValue> values()
+   {
+      return Collections.unmodifiableCollection(contents.values());
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null || obj instanceof CompositeValue == false)
+         return false;
+
+      CompositeValue other = (CompositeValue) obj;
+      if (getMetaType().equals(other.getMetaType()) == false)
+         return false;
+      if (values().size() != other.values().size())
+         return false;
+
+      for (String key : contents.keySet())
+      {
+         Object thisValue = this.get(key);
+         Object otherValue = other.get(key);
+         if ((thisValue == null && otherValue == null || thisValue != null && thisValue.equals(otherValue)) == false)
+            return false;
+      }
+      return true;
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      if (cachedHashCode != Integer.MIN_VALUE)
+         return cachedHashCode;
+
+      cachedHashCode = getMetaType().hashCode();
+      for (Object value : contents.values())
+      {
+         if (value != null)
+            cachedHashCode += value.hashCode();
+      }
+      
+      return cachedHashCode;
+   }
+
+   @Override
+   public String toString()
+   {
+      CompositeMetaType metaType = getMetaType();
+      StringBuilder buffer = new StringBuilder(getClass().getSimpleName());
+      buffer.append(": netaType=[");
+      buffer.append(metaType);
+      buffer.append("] mappings=[");
+      Iterator keys = metaType.keySet().iterator();
+      while(keys.hasNext())
+      {
+         Object key = keys.next();
+         buffer.append(key + "=" + contents.get(key));
+         if (keys.hasNext())
+            buffer.append(",");
+      }
+      buffer.append("]");
+      return buffer.toString();
+   }
+
+   /**
+    * Validates the key against the composite type
+    *
+    * @param key the key to check
+    * @throws IllegalArgumentException for a null or empty key or when 
+    *         the key not a valid item name for the composite type
+    */
+   private void validateKey(String key)
+   {
+      if (key == null || key.length() == 0)
+         throw new IllegalArgumentException("null or empty key");
+      CompositeMetaType metaType = getMetaType();
+      if (metaType.containsKey(key) == false)
+         throw new IllegalArgumentException("no such item name " + key + " for composite type " + metaType);
+   }
+
+   /**
+    * Construct Composite Value 
+    *
+    * @param metaType the composite type of the data
+    * @param items map of strings to values
+    * @throws IllegalArgumentException for a null or empty argument or when the items do not match the
+    *         CompositeType
+    */
+   private void init(CompositeMetaType metaType, Map<String, MetaValue> items)
+   {
+      if (metaType == null)
+         throw new IllegalArgumentException("null meta type");
+      if (items == null)
+         throw new IllegalArgumentException("null items");
+      if (items.size() == 0)
+         throw new IllegalArgumentException("empty items");
+      int compositeNameSize = metaType.keySet().size();
+      if (items.size() != compositeNameSize)
+         throw new IllegalArgumentException("items has size " + items.size() + " but composite type has size " + compositeNameSize);
+
+      this.metaType = metaType;
+      contents = new TreeMap<String, MetaValue>();
+
+      for (Entry<String, MetaValue> entry : items.entrySet())
+      {
+         String key = entry.getKey();
+         if (key == null || key.length() == 0)
+            throw new IllegalArgumentException("Key is null or empty");
+         MetaType itemType = metaType.getType(key);
+         if (itemType == null)
+            throw new IllegalArgumentException("item name not in composite type " + key);
+         MetaValue value = items.get(key);
+         if (value != null && itemType.isValue(value) == false)
+            throw new IllegalArgumentException("item value " + value + " for item name " + key + " is not a " + itemType);
+         contents.put(key, value);
+      }
+   }
+
+   @SuppressWarnings("unchecked")
+   private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
+   {
+      ObjectInputStream.GetField getField = in.readFields();
+      SortedMap contents = (SortedMap) getField.get("contents", null);
+      CompositeMetaType compositeType = (CompositeMetaType) getField.get("metaType", null);
+      try
+      {
+         init(compositeType, contents);
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Error deserializing composite value", e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/MetaValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/MetaValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/MetaValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,49 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.io.Serializable;
+
+import org.jboss.metatype.api.types.MetaType;
+
+/**
+ * MetaValue.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface MetaValue extends Serializable, Cloneable
+{
+   /**
+    * Get the metatype for this value
+    * 
+    * @return the metatype
+    */
+   MetaType getMetaType();
+   
+   /**
+    * Clone the meta value
+    * 
+    * @return the cloned meta value
+    */
+   MetaValue clone();
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,45 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.io.Serializable;
+
+import org.jboss.metatype.api.types.SimpleMetaType;
+
+/**
+ * SimpleValue.
+ * 
+ * @param <T> the underlying type 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface SimpleValue<T extends Serializable> extends MetaValue
+{
+   SimpleMetaType<T> getMetaType();
+   
+   /**
+    * Get the underlying value
+    * 
+    * @return the underlying value
+    */
+   public T getValue();
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValueSupport.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValueSupport.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/SimpleValueSupport.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,137 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.io.Serializable;
+
+import org.jboss.metatype.api.types.SimpleMetaType;
+
+/**
+ * SimpleValue.
+ * 
+ * @param <T> the underlying type 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class SimpleValueSupport<T extends Serializable> extends AbstractMetaValue implements SimpleValue<T>
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 8473043036261557127L;
+   
+   /** The simple meta type */
+   private SimpleMetaType<T> metaType;
+   
+   /** The value */
+   private T value;
+
+   /**
+    * Wrap a simple object in simple value
+    * 
+    * @param <T> the underlying type
+    * @param object the simple object
+    * @return the simple value
+    */
+   @SuppressWarnings("unchecked")
+   public static <T extends Serializable> SimpleValue<T> wrap(T object)
+   {
+      if (object == null)
+         return null;
+      String className = object.getClass().getName();
+      SimpleMetaType<T> metaType = SimpleMetaType.resolve(className);
+      return new SimpleValueSupport<T>(metaType, object);
+   }
+   
+   /**
+    * Create a new SimpleValueSupport.
+    * 
+    * @param metaType the simple meta type
+    * @param value the value
+    * @throws IllegalArgumentException for a null simpleMetaType
+    */
+   public SimpleValueSupport(SimpleMetaType<T> metaType, T value)
+   {
+      if (metaType == null)
+         throw new IllegalArgumentException("Null simple meta type");
+      this.metaType = metaType;
+      this.value = value;
+   }
+
+   public SimpleMetaType<T> getMetaType()
+   {
+      return metaType;
+   }
+
+   /**
+    * Get the value.
+    * 
+    * @return the value.
+    */
+   public T getValue()
+   {
+      return value;
+   }
+
+   /**
+    * Set the value.
+    * 
+    * @param value the value.
+    */
+   public void setValue(T value)
+   {
+      this.value = value;
+   } 
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      
+      if (obj == null || obj instanceof SimpleValue == false)
+         return false;
+
+      SimpleValue other = (SimpleValue) obj;
+      if (metaType.equals(other.getMetaType()) == false)
+         return false;
+
+      Object otherValue = other.getValue();
+      if (value == null && otherValue == null)
+         return true;
+      if (value == null && otherValue != null)
+         return false;
+      return value.equals(otherValue);
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      if (value == null)
+         return 0;
+      return value.hashCode();
+   }
+
+   @Override
+   public String toString()
+   {
+      return metaType + ":" + value;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,137 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.util.Collection;
+import java.util.List;
+import java.util.Set;
+
+import org.jboss.metatype.api.types.TableMetaType;
+
+public interface TableValue extends MetaValue
+{
+   TableMetaType getMetaType();
+
+   /**
+    * Calculate the index for the value passed if it were added to the
+    * table value. The validity of the passed value is checked. But the
+    * table value isn't checked to see whether the index is already used.
+    *
+    * @param value the value for which the index is calculated.
+    * @return the calculated index
+    * @throws IllegalArgumentException for a null value or when the passed value is not valid for the table value's row type.
+    */
+   MetaValue[] calculateIndex(CompositeValue value);
+
+   /**
+    * Retrieve the number of rows in the table value.
+    *
+    * @return the number of rows.
+    */
+   int size();
+
+   /**
+    * Determine whether the table value is empty.
+    *
+    * @return true when there are no rows, false otherwise
+    */
+   boolean isEmpty();
+
+   /**
+    * Determine whether the table value contains the passed value as a row.
+    * If the passed value is null or invalid, false is returned.
+    *
+    * @param key the value to check
+    * @return true when the value is a row index, false otherwise
+    */
+   boolean containsKey(MetaValue[] key);
+
+   /**
+    * Determine whether the table value contains the passed value.
+    * If the passed value is null or invalid, false is returned.
+    *
+    * @param value the value to check
+    * @return true when the value is a row index, false otherwise
+    */
+   boolean containsValue(CompositeValue value);
+
+   /**
+    * Retrieve the composite value for the passed index.
+    *
+    * @param key the index to retrieve
+    * @return the composite value
+    * @throws IllegalArgumentException when the passed key is null or when the passed key does match the row type of the table value.
+    */
+   CompositeValue get(MetaValue[] key);
+
+   /**
+    * Add a value to the table value. The value must have the same
+    * CompositeMetaType has the table value and there is no value already
+    * occupying the index for the value.
+    *
+    * @param value the value to add
+    * @throws IllegalArgumentException when the passed value is null or when the value is not valid for
+    *         the row type of the tabular data or when the index for the value is already occupied.
+    */
+   void put(CompositeValue value);
+
+   /**
+    * Removes the value for the passed and returns the removed value, or
+    * null if the key was not present.
+    *
+    * @param key the index of the value to remove
+    * @return the removed value
+    * @throws IllegalArgumentException when the passed key is null or when the key is not valid for the table value
+    */
+   CompositeValue remove(MetaValue[] key);
+      
+   /**
+    * Add all the passed values. All the values are checked before
+    * addition including any duplicates that might be added. Either all
+    * or no value is added.
+    *
+    * @param values the values to add
+    * @throws IllegalArgumentException when the passed values is null or an element of the values is null
+    *         or when one of value is not valid for the row type of the table value or when
+    *         the index for one of the values is already occupied.
+    */
+   void putAll(CompositeValue[] values);
+      
+   /**
+    * Removes all CompositeValues from the Table value
+    */
+   void clear();
+      
+   /**
+    * Returns a set view of the index values.
+    *
+    * @return the set of index values.
+    */
+   Set<List<MetaValue>> keySet();
+   
+   /**
+    * Returns a set view of the row values.
+    *
+    * @return the set of row values.
+    */
+   Collection<CompositeValue> values();
+}

Added: projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValueSupport.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValueSupport.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/main/org/jboss/metatype/api/values/TableValueSupport.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,317 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.metatype.api.values;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.io.ObjectStreamField;
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+import java.util.List;
+import java.util.Set;
+import java.util.Map.Entry;
+
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.TableMetaType;
+
+/**
+ * TableValueSupport.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class TableValueSupport extends AbstractMetaValue implements TableValue
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -6862672408820383430L;
+
+   /** The serialized form */
+   private static final ObjectStreamField[] serialPersistentFields =
+      new ObjectStreamField[]
+      {
+         new ObjectStreamField("dataMap",  HashMap.class),
+         new ObjectStreamField("tableType", TableMetaType.class),
+      };
+
+   /** The data map of this tabular data */
+   private HashMap<List<MetaValue>, CompositeValue> dataMap;
+
+   /** The table meta data type */
+   private TableMetaType tableType;
+
+   /** The index names */
+   private transient String[] indexNames;
+
+   /**
+    * Construct Table Value with an initial capacity of 101 and a load
+    * factor of 0.75
+    *
+    * @param tableType the table type of the data
+    * @exception IllegalArgumentException for a null argument
+    */
+   public TableValueSupport(TableMetaType tableType)
+   {
+      this(tableType, 101, 0.75f);
+   }
+
+   /**
+    * Construct Table value
+    *
+    * @param tableType the table type
+    * @param initialCapacity the initial capacity of the map
+    * @param loadFactor the load factory of the map
+    * @exception IllegalArgumentException for a null argument
+    */
+   public TableValueSupport(TableMetaType tableType, int initialCapacity, float loadFactor)
+   {
+      init(new HashMap<List<MetaValue>, CompositeValue>(initialCapacity, loadFactor), tableType);
+   }
+
+   public TableMetaType getMetaType()
+   {
+      return tableType;
+   }
+
+   public MetaValue[] calculateIndex(CompositeValue value)
+   {
+      validateCompositeValue(value);
+      return value.getAll(indexNames);
+   }
+
+   public void clear()
+   {
+      dataMap.clear();
+   }
+
+   public boolean containsKey(MetaValue[] key)
+   {
+      if (key == null)
+         return false;
+      return dataMap.containsKey(Arrays.asList(key));
+   }
+
+   public boolean containsValue(CompositeValue value)
+   {
+      return dataMap.containsValue(value);
+   }
+
+   public CompositeValue get(MetaValue[] key)
+   {
+      validateKey(key);
+      return dataMap.get(Arrays.asList(key));
+   }
+
+   public boolean isEmpty()
+   {
+      return dataMap.isEmpty();
+   }
+
+   public Set<List<MetaValue>> keySet()
+   {
+      return dataMap.keySet();
+   }
+
+   public void put(CompositeValue value)
+   {
+      List<MetaValue> index = Arrays.asList(calculateIndex(value));
+      if (dataMap.containsKey(index))
+         throw new IllegalArgumentException("The index is already used " + index);
+      dataMap.put(index, value);
+   }
+
+   public void putAll(CompositeValue[] values)
+   {
+      if (values == null)
+         return;
+
+      HashSet<List<MetaValue>> keys = new HashSet<List<MetaValue>>();
+      for (int i = 0; i < values.length; ++i)
+      {
+         List<MetaValue> index = Arrays.asList(calculateIndex(values[i]));
+         if (keys.contains(index))
+            throw new IllegalArgumentException("Duplicate index in values " + index + " for value " + values[i]);
+         keys.add(index);
+         if (dataMap.containsKey(index))
+            throw new IllegalArgumentException("Index already used " + index + " for value " + values[i]);
+      }
+      for (int i = 0; i < values.length; i++)
+         put(values[i]);
+   }
+
+   public CompositeValue remove(MetaValue[] key)
+   {
+      validateKey(key);
+      return dataMap.remove(Arrays.asList(key));
+   }
+
+   public int size()
+   {
+      return dataMap.size();
+   }
+
+   public Collection<CompositeValue> values()
+   {
+      return dataMap.values();
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (this == obj)
+         return true;
+      if (obj == null || (obj instanceof TableValue) == false)
+         return false;
+
+      TableValue other = (TableValue) obj;
+      if (tableType.equals(other.getMetaType()) == false)
+         return false;
+      if (size() != other.size())
+         return false;
+      for (Entry<List<MetaValue>, CompositeValue> entry : dataMap.entrySet())
+      {
+         List<MetaValue> list = entry.getKey();
+         MetaValue[] indexes = list.toArray(new MetaValue[list.size()]);
+         CompositeValue thisValue = entry.getValue();
+         CompositeValue otherValue = other.get(indexes);
+         if (thisValue == null && otherValue == null)
+            return true;
+         if (thisValue == null && otherValue != null)
+            return false;
+         if (thisValue.equals(otherValue) == false)
+            return false;
+      }
+      return true;
+   }
+
+   @Override
+   public int hashCode()
+   {
+      int hash = tableType.hashCode();
+      for (CompositeValue value : dataMap.values())
+         hash += value.hashCode();
+      return hash;
+   }
+
+   @Override
+   public String toString()
+   {
+      StringBuilder buffer = new StringBuilder(getClass().getSimpleName());
+      buffer.append(": tableType=[");
+      buffer.append(getMetaType());
+      buffer.append("] mappings=[");
+      Iterator<Entry<List<MetaValue>, CompositeValue>> entries = dataMap.entrySet().iterator();
+      while(entries.hasNext())
+      {
+         Entry entry = entries.next(); 
+         buffer.append(entry.getKey());
+         buffer.append("=");
+         buffer.append(entry.getValue());
+         if (entries.hasNext())
+            buffer.append(",");
+      }
+      buffer.append("]");
+      return buffer.toString();
+   }
+
+   @Override
+   @SuppressWarnings("unchecked")
+   public TableValueSupport clone()
+   {
+      TableValueSupport result = (TableValueSupport) super.clone();
+      result.dataMap = (HashMap<List<MetaValue>, CompositeValue>) dataMap.clone();
+      return result;
+   }
+
+   /**
+    * Initialise the table value
+    *
+    * @param dataMap the data
+    * @param tableType the table type
+    * @exception IllegalArgumentException for a null
+    */
+   private void init(HashMap<List<MetaValue>, CompositeValue> dataMap, TableMetaType tableType)
+   {
+      if (dataMap == null)
+         throw new IllegalArgumentException("null dataMap");
+      if (tableType == null)
+         throw new IllegalArgumentException("null table type");
+
+      this.dataMap = dataMap;
+      this.tableType = tableType;
+      List<String> indexNameList = tableType.getIndexNames();
+      this.indexNames = indexNameList.toArray(new String[indexNameList.size()]);
+   }
+
+   /**
+    * Validate the composite type against the row type
+    *
+    * @param value the composite value
+    * @throws IllegalArgumentException for a null value or if the value is not valid for the table value's row type
+    */
+   private void validateCompositeValue(CompositeValue value)
+   {
+      if (value == null)
+         throw new IllegalArgumentException("null value");
+      if (value.getMetaType().equals(tableType.getRowType()) == false)
+         throw new IllegalArgumentException("value has composite type " + value.getMetaType() + " expected row type " + tableType.getRowType());
+   }
+
+   /**
+    * Validate the key against the row type
+    *
+    * @param key the key to check
+    * @throws IllegalArgumentException for a null key or if the key is not valid for the table value's row type
+    */
+   private void validateKey(MetaValue[] key)
+   {
+      if (key == null || key.length == 0)
+         throw new IllegalArgumentException("null or empty key");
+
+      if (key.length != indexNames.length)
+         throw new IllegalArgumentException("key has " + key.length + " elements, " + "should be " + indexNames.length);
+      for (int i = 0; i < key.length; i++)
+      {
+         MetaType metaType = tableType.getRowType().getType(indexNames[i]);
+         if (key[i] != null && metaType.isValue(key[i]) == false)
+            throw new IllegalArgumentException("key element " + i + " " + key + " is not a value for " + metaType);
+      }
+   }
+
+   @SuppressWarnings("unchecked")
+   private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
+   {
+      ObjectInputStream.GetField getField = in.readFields();
+      HashMap<List<MetaValue>, CompositeValue> dataMap = (HashMap<List<MetaValue>, CompositeValue>) getField.get("dataMap", null);
+      TableMetaType tableType = (TableMetaType) getField.get("tableType", null);
+      try
+      {
+         init(dataMap, tableType);
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Unexpected error during deserialization", e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/AbstractMetaTypeTest.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/AbstractMetaTypeTest.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/AbstractMetaTypeTest.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,182 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import junit.framework.TestSuite;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableCompositeMetaType;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.SimpleValue;
+import org.jboss.metatype.api.values.SimpleValueSupport;
+import org.jboss.test.BaseTestCase;
+
+/**
+ * AbstractMetaTypeTest.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class AbstractMetaTypeTest extends BaseTestCase
+{
+   /**
+    * Create a new testsuite for the class
+    * 
+    * TODO move to BaseTestCase
+    * @param clazz the class
+    * @return the suite
+    */
+   public static TestSuite suite(Class<?> clazz)
+   {
+      return new TestSuite(clazz);
+   }
+   
+   public AbstractMetaTypeTest(String name)
+   {
+      super(name);
+   }
+
+   protected SimpleValue<String> initStringValue1()
+   {
+      return SimpleValueSupport.wrap("value1");
+   }
+
+   protected SimpleValue<String> initStringValue2()
+   {
+      return SimpleValueSupport.wrap("value2");
+   }
+
+   protected SimpleValue<String> initStringName1()
+   {
+      return SimpleValueSupport.wrap("name1");
+   }
+
+   protected SimpleValue<String> initStringEmpty()
+   {
+      return SimpleValueSupport.wrap("");
+   }
+
+   protected SimpleValue<String> initStringNull()
+   {
+      return new SimpleValueSupport<String>(SimpleMetaType.STRING, null);
+   }
+
+   protected SimpleValue<String> initStringWrong()
+   {
+      return SimpleValueSupport.wrap("wrong");
+   }
+
+   protected SimpleValue<Integer> initInteger2()
+   {
+      return SimpleValueSupport.wrap(new Integer(2));
+   }
+
+   protected SimpleValue<Integer> initInteger3()
+   {
+      return SimpleValueSupport.wrap(new Integer(3));
+   }
+
+   protected SimpleValue<Integer> initInteger4()
+   {
+      return SimpleValueSupport.wrap(new Integer(4));
+   }
+
+   protected SimpleValue<Integer> initIntegerNull()
+   {
+      return new SimpleValueSupport<Integer>(SimpleMetaType.INTEGER, null);
+   }
+
+   protected Map<String, MetaValue> initMapValues()
+   {
+      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
+      map.put("name1", initStringValue1());
+      map.put("name2", initInteger2());
+      return map;
+   }
+
+   protected Map<String, MetaValue> initMapValues2()
+   {
+      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
+      map.put("name1", initStringValue1());
+      map.put("name2", initInteger3());
+      return map;
+   }
+
+   protected Map<String, MetaValue> initMapValues3()
+   {
+      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
+      map.put("name1", initStringValue2());
+      map.put("name2", initInteger3());
+      return map;
+   }
+
+   protected Map<String, MetaValue> initMapValues4()
+   {
+      Map<String, MetaValue> map = new HashMap<String, MetaValue>();
+      map.put("name1", initStringValue1());
+      map.put("name2", initInteger4());
+      return map;
+   }
+   
+   protected String[] initKeys()
+   {
+      return new String[] { "name1", "name2" };
+   }
+
+   protected MetaValue[] initValues()
+   {
+      return new MetaValue[] { initStringValue1(), initInteger2() };
+   }
+
+   protected MetaValue[] initValues2()
+   {
+      return new MetaValue[] { initStringValue1(), initInteger3() };
+   }
+
+   protected MetaValue[] initValues4()
+   {
+      return new MetaValue[] { initStringValue1(), initInteger4() };
+   }
+
+   protected CompositeMetaType initCompositeMetaType()
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeMetaType = new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, itemTypes);
+      return compositeMetaType;
+   }
+
+   protected CompositeMetaType initCompositeMetaType2()
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeMetaType = new ImmutableCompositeMetaType("typeName2", "description", itemNames, itemDescriptions, itemTypes);
+      return compositeMetaType;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/MetaTypeAllTestSuite.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/MetaTypeAllTestSuite.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/MetaTypeAllTestSuite.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,53 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype;
+
+import org.jboss.test.metatype.types.test.TypesTestSuite;
+import org.jboss.test.metatype.values.test.ValuesTestSuite;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * MetaType All Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 37459 $
+ */
+public class MetaTypeAllTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("MetaType All Tests");
+
+      suite.addTest(TypesTestSuite.suite());
+      suite.addTest(ValuesTestSuite.suite());
+
+      return suite;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockCompositeValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockCompositeValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockCompositeValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,75 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.support;
+
+import java.util.Collection;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.MetaValue;
+
+/**
+ * MockCompositeValue.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockCompositeValue extends MockMetaValue implements CompositeValue
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   public MockCompositeValue(CompositeMetaType metaType)
+   {
+      super(metaType);
+   }
+   
+   public CompositeMetaType getMetaType()
+   {
+      return (CompositeMetaType) super.getMetaType();
+   }
+
+   public boolean containsKey(String key)
+   {
+      throw new org.jboss.util.NotImplementedException("containsKey");
+   }
+
+   public boolean containsValue(MetaValue value)
+   {
+      throw new org.jboss.util.NotImplementedException("containsValue");
+   }
+
+   public MetaValue get(String key)
+   {
+      throw new org.jboss.util.NotImplementedException("get");
+   }
+
+   public MetaValue[] getAll(String[] keys)
+   {
+      throw new org.jboss.util.NotImplementedException("getAll");
+   }
+
+   public Collection<MetaValue> values()
+   {
+      throw new org.jboss.util.NotImplementedException("values");
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaType.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaType.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaType.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,68 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.support;
+
+import java.io.Serializable;
+
+import org.jboss.metatype.api.types.AbstractMetaType;
+
+/**
+ * MockMetaType.
+ * 
+ * @param <T> the underlying type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockMetaType<T extends Serializable> extends AbstractMetaType<T>
+{
+   private static final long serialVersionUID = -1;
+
+   public MockMetaType(String className, String typeName, String description)
+   {
+      super(className, typeName, description);
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      throw new org.jboss.util.NotImplementedException("equals");
+   }
+
+   @Override
+   public int hashCode()
+   {
+      throw new org.jboss.util.NotImplementedException("hashCode");
+   }
+
+   @Override
+   public boolean isValue(Object obj)
+   {
+      throw new org.jboss.util.NotImplementedException("isValue");
+   }
+
+   @Override
+   public String toString()
+   {
+      throw new org.jboss.util.NotImplementedException("toString");
+   }
+
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockMetaValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,63 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.support;
+
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.values.MetaValue;
+
+/**
+ * MockMetaValue.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockMetaValue implements MetaValue
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+   
+   private MetaType metaType;
+
+   public MockMetaValue(MetaType metaType)
+   {
+      this.metaType = metaType;
+   }
+   
+   public MetaType getMetaType()
+   {
+      return metaType;
+   }
+
+   public MetaValue clone()
+   {
+      try
+      {
+         return (MockMetaValue) super.clone();
+      }
+      catch (CloneNotSupportedException e)
+      {
+         throw new Error("unexpected", e);
+      }
+   }
+   
+   
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockSimpleValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockSimpleValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockSimpleValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,55 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.support;
+
+import java.io.Serializable;
+
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.SimpleValue;
+
+/**
+ * MockSimpleValue.
+ * 
+ * @param <T> the underlying type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockSimpleValue<T extends Serializable> extends MockMetaValue implements SimpleValue<T>
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   public MockSimpleValue(SimpleMetaType<T> metaType)
+   {
+      super(metaType);
+   }
+
+   public SimpleMetaType<T> getMetaType()
+   {
+      return (SimpleMetaType<T>) super.getMetaType();
+   }
+
+   public T getValue()
+   {
+      throw new org.jboss.util.NotImplementedException("getValue");
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockTableValue.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockTableValue.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/support/MockTableValue.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,113 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.support;
+
+import java.util.Collection;
+import java.util.List;
+import java.util.Set;
+
+import org.jboss.metatype.api.types.TableMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.TableValue;
+
+/**
+ * MockTableValue.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockTableValue extends MockMetaValue implements TableValue
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+ 
+   public MockTableValue(TableMetaType metaType)
+   {
+      super(metaType);
+   }
+
+   public TableMetaType getMetaType()
+   {
+      return (TableMetaType) super.getMetaType();
+   }
+
+   public MetaValue[] calculateIndex(CompositeValue value)
+   {
+      throw new org.jboss.util.NotImplementedException("calculateIndex");
+   }
+
+   public void clear()
+   {
+      throw new org.jboss.util.NotImplementedException("clear");
+   }
+
+   public boolean containsKey(MetaValue[] key)
+   {
+      throw new org.jboss.util.NotImplementedException("containsKey");
+   }
+
+   public boolean containsValue(CompositeValue value)
+   {
+      throw new org.jboss.util.NotImplementedException("containsValue");
+   }
+
+   public CompositeValue get(MetaValue[] key)
+   {
+      throw new org.jboss.util.NotImplementedException("get");
+   }
+
+   public boolean isEmpty()
+   {
+      throw new org.jboss.util.NotImplementedException("isEmpty");
+   }
+
+   public Set<List<MetaValue>> keySet()
+   {
+      throw new org.jboss.util.NotImplementedException("keySet");
+   }
+
+   public void put(CompositeValue value)
+   {
+      throw new org.jboss.util.NotImplementedException("put");
+   }
+
+   public void putAll(CompositeValue[] values)
+   {
+      throw new org.jboss.util.NotImplementedException("putAll");
+   }
+
+   public CompositeValue remove(MetaValue[] key)
+   {
+      throw new org.jboss.util.NotImplementedException("remove");
+   }
+
+   public int size()
+   {
+      throw new org.jboss.util.NotImplementedException("size");
+   }
+
+   public Collection<CompositeValue> values()
+   {
+      throw new org.jboss.util.NotImplementedException("values");
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ArrayMetaTypeUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ArrayMetaTypeUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ArrayMetaTypeUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,228 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.test;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.ArrayMetaType;
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableCompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableTableMetaType;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.types.TableMetaType;
+import org.jboss.metatype.api.values.TableValue;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+import org.jboss.test.metatype.types.support.MockCompositeValue;
+import org.jboss.test.metatype.types.support.MockSimpleValue;
+import org.jboss.test.metatype.types.support.MockTableValue;
+
+/**
+ * ArrayMetaTypeUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayMetaTypeUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(ArrayMetaTypeUnitTestCase.class);
+   }
+   
+   public ArrayMetaTypeUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testArrayTypeMetaType() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+      assertEquals("[[[Ljava.lang.String;", arrayType.getClassName());
+      assertEquals("3-dimension array of java.lang.String", arrayType.getDescription());
+      assertEquals("[[[Ljava.lang.String;", arrayType.getTypeName());
+      assertTrue("Type should be an array", arrayType.isArray());
+   }
+
+   public void testGetDimension() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+      assertEquals("Dimension should be 3", 3, arrayType.getDimension());
+   }
+
+   public void testElementOpenType() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+      assertEquals("Element MetaType should be " + SimpleMetaType.STRING, SimpleMetaType.STRING, arrayType.getElementType());
+   }
+
+   public void testIsValueSimpleValue() throws Exception
+   {
+      SimpleMetaType<String> simpleType = SimpleMetaType.STRING;
+      MockSimpleValue sv = new MockSimpleValue<String>(simpleType);
+      MockSimpleValue[][] compData1 = new MockSimpleValue[][]
+      {
+         { sv, null }, { sv, sv }
+      };
+            
+      ArrayMetaType compArrayType1 = new ArrayMetaType(2, SimpleMetaType.STRING);
+      assertTrue("compData1 should be a value of array type", compArrayType1.isValue(compData1));
+
+      ArrayMetaType compArrayType2 = new ArrayMetaType(1, SimpleMetaType.STRING);
+      assertFalse("compData1 should not be a value of array type, wrong dimension", compArrayType2.isValue(compData1));
+
+      SimpleMetaType<Integer> simpleType2 = SimpleMetaType.INTEGER;
+      ArrayMetaType compArrayType3 = new ArrayMetaType(2, simpleType2);
+      assertFalse("compData1 should not be a value of array type, wrong element type", compArrayType3.isValue(compData1));
+   }
+
+   public void testIsValueComposite() throws Exception
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeType = new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, itemTypes);
+      MockCompositeValue cv = new MockCompositeValue(compositeType);
+      MockCompositeValue[][] compData1 = new MockCompositeValue[][]
+      {
+         { cv, null }, { cv, cv }
+      };
+
+      ArrayMetaType compArrayType1 = new ArrayMetaType(2, compositeType);
+      assertTrue("compData1 should be a value of array type", compArrayType1.isValue(compData1));
+
+      ArrayMetaType compArrayType2 = new ArrayMetaType(1, compositeType);
+      assertFalse("compData1 should not be a value of array type, wrong dimension", compArrayType2.isValue(compData1));
+
+      CompositeMetaType compositeType2 = new ImmutableCompositeMetaType("typeName2", "description", itemNames, itemDescriptions, itemTypes);
+      ArrayMetaType compArrayType3 = new ArrayMetaType(2, compositeType2);
+      assertFalse("compData1 should not be a value of array type, wrong element type", compArrayType3.isValue(compData1));
+   }
+
+   public void testIsValueTable() throws Exception
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeType = new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, itemTypes);
+      TableMetaType tableType = new ImmutableTableMetaType("typeName", "description", compositeType, new String[] { "name1" });
+      TableValue tv = new MockTableValue(tableType);
+      TableValue[][] tabData1 = new TableValue[][]
+      {
+         { tv, null }, { tv, tv }
+      };
+
+      ArrayMetaType tabArrayType1 = new ArrayMetaType(2, tableType);
+      assertTrue("tabData1 should be a value of array type", tabArrayType1.isValue(tabData1));
+
+      ArrayMetaType tabArrayType2 = new ArrayMetaType(1, tableType);
+      assertFalse("tabData1 should not be a value of array type, wrong number of dimensions", tabArrayType2.isValue(tabData1));
+
+      TableMetaType tableType2 = new ImmutableTableMetaType("typeName2", "description", compositeType, new String[] { "name1" });
+      ArrayMetaType tabArrayType3 = new ArrayMetaType(2, tableType2);
+      assertFalse("tabData1 should not be a value of array type, wrong element type", tabArrayType3.isValue(tabData1));
+   }
+
+   public void testEquals() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+
+      assertNotSame("null is not an array type", null, arrayType);
+      assertNotSame("object is not an array type", new Object(), arrayType);
+
+      assertEquals("should be equal to itself", arrayType, arrayType);
+
+      ArrayMetaType arrayType2 = new ArrayMetaType(3, SimpleMetaType.STRING);
+      assertEquals("should be equal, even though different instances", arrayType, arrayType2);
+      assertEquals("should be equal, even though different instances", arrayType2, arrayType);
+
+      arrayType2 = new ArrayMetaType(2, SimpleMetaType.STRING);
+      assertNotSame("should not be equal, wrong number of dimensions", arrayType, arrayType2);
+      assertNotSame("should not be equal, wrong number of dimensions", arrayType2, arrayType);
+
+      arrayType2 = new ArrayMetaType(3, SimpleMetaType.INTEGER);
+      assertNotSame("should not be equal, wrong element type", arrayType, arrayType2);
+      assertNotSame("should not be equal, wrong element type", arrayType2, arrayType);
+   }
+
+   public void testHashCode() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+
+      int myHashCode = 3 + SimpleMetaType.STRING.hashCode();
+      assertTrue("Wrong hash code generated", myHashCode == arrayType.hashCode());
+   }
+
+   public void testToString() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+
+      String toString = arrayType.toString();
+
+      assertTrue("toString() should contain the array type class name", toString.indexOf(ArrayMetaType.class.getSimpleName()) != -1);
+      assertTrue("toString() should contain the dimension", toString.indexOf("3") != -1);
+      assertTrue("toString() should contain the element type", toString.indexOf(SimpleMetaType.STRING.toString()) != -1);
+   }
+
+   public void testSerialization() throws Exception
+   {
+      ArrayMetaType arrayType = new ArrayMetaType(3, SimpleMetaType.STRING);
+
+      byte[] bytes = serialize(arrayType);
+      Object result = deserialize(bytes);
+
+      assertEquals(arrayType, result);
+   }
+
+   public void testErrors() throws Exception
+   {
+      try
+      {
+         new ArrayMetaType(-1, SimpleMetaType.STRING);
+         fail("Excepted IllegalArgumentException for negative dimension");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ArrayMetaType(1, new ArrayMetaType(2, SimpleMetaType.STRING));
+         fail("Excepted IllegalArgumentException for ArrayMetaType element type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ArrayMetaType(1, null);
+         fail("Excepted IllegalArgumentException for null element type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableCompositeMetaTypeUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableCompositeMetaTypeUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableCompositeMetaTypeUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,365 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.test;
+
+import java.util.Set;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableCompositeMetaType;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+
+/**
+ * CompositeMetaTypeUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ImmutableCompositeMetaTypeUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(ImmutableCompositeMetaTypeUnitTestCase.class);
+   }
+   
+   public ImmutableCompositeMetaTypeUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testCompositeMetaTypeMetaType() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+      assertEquals(CompositeValue.class.getName(), compositeType.getClassName());
+      assertEquals("description", compositeType.getDescription());
+      assertEquals("typeName", compositeType.getTypeName());
+      assertTrue("Composite meta type should not be an array", compositeType.isArray() == false);
+   }
+
+   public void testContainsKey() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+      assertTrue("Composite type should contain key name1", compositeType.containsKey("name1") == true);
+      assertTrue("Composite type should contain key name2", compositeType.containsKey("name2") == true);
+      assertTrue("Composite type should not contain key nameX", compositeType.containsKey("nameX") == false);
+      assertTrue("Composite type should not contain key null", compositeType.containsKey(null) == false);
+      assertTrue("Composite type should not contain key <empty>", compositeType.containsKey("") == false);
+   }
+
+   public void testGetDescriptionForItemName() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+      assertEquals("desc1", compositeType.getDescription("name1"));
+      assertEquals("desc2", compositeType.getDescription("name2"));
+   }
+
+   public void testGetTypeForItemName() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+      assertEquals(SimpleMetaType.STRING, compositeType.getType("name1"));
+      assertEquals(SimpleMetaType.INTEGER, compositeType.getType("name2"));
+   }
+
+   public void testKeySet() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+      Set<String> keys = compositeType.keySet();
+      assertTrue("Should be 2 items", keys.size() == 2);
+      assertTrue("Should contain name1", keys.contains("name1"));
+      assertTrue("Should contain name2", keys.contains("name2"));
+   }
+
+   public void testIsValue() throws Exception
+   {
+      // TODO testIsValue
+   }
+
+   public void testEquals() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();;
+
+      assertTrue("null is not equal composite type", compositeType.equals(null) == false);
+      assertTrue("object is not equal composite type", compositeType.equals(new Object()) == false);
+
+      CompositeMetaType compositeType2 = initCompositeMetaType();
+      assertTrue("compositeType2 should be equal composite type, even though not the same object instance",
+         compositeType.equals(compositeType2));
+      assertTrue("compositeType2 should be equal composite type, even though not the same object instance",
+         compositeType2.equals(compositeType));
+
+      compositeType2 = initCompositeMetaTypeDifferentItemTypes();
+      assertTrue("compositeType2 should not be equal composite type, it has different types",
+         compositeType.equals(compositeType2) == false);
+      assertTrue("compositeType2 should not be equal composite type, it has different types",
+         compositeType2.equals(compositeType) == false);
+
+      compositeType2 = initCompositeMetaTypeDifferentTypeName();
+      assertTrue("compositeType2 should not be equal composite type, it has a different type name",
+         compositeType.equals(compositeType2) == false);
+      assertTrue("compositeType2 should not be equal composite type, it has a different type name",
+         compositeType2.equals(compositeType) == false);
+
+      compositeType2 = initCompositeMetaTypeDifferentItemNames();
+      assertTrue("compositeType2 should not be equal composite type, it has different item names",
+         compositeType.equals(compositeType2) == false);
+      assertTrue("compositeType2 should not be equal composite type, it has different item names",
+         compositeType2.equals(compositeType) == false);
+   }
+
+   public void testHashCode() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+
+      int myHashCode = "typeName".hashCode();
+      myHashCode += SimpleMetaType.STRING.hashCode();
+      myHashCode += SimpleMetaType.INTEGER.hashCode();
+      myHashCode += "name1".hashCode();
+      myHashCode += "name2".hashCode();
+      assertTrue("Wrong hash code generated", myHashCode == compositeType.hashCode());
+   }
+
+   public void testToString() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+
+      String toString = compositeType.toString();
+
+      assertTrue("toString() should contain the composite type class name", toString.indexOf(compositeType.getClass().getSimpleName()) != -1);
+      assertTrue("toString() should contain the item name name1", toString.indexOf("name1") != -1);
+      assertTrue("toString() should contain the item name name2", toString.indexOf("name2") != -1);
+      assertTrue("toString() should contain " + SimpleMetaType.STRING, toString.indexOf(SimpleMetaType.STRING.toString()) != -1);
+      assertTrue("toString() should contain " + SimpleMetaType.INTEGER, toString.indexOf(SimpleMetaType.INTEGER.toString()) != -1);
+   }
+
+   public void testSerialization() throws Exception
+   {
+      CompositeMetaType compositeType = initCompositeMetaType();
+      byte[] bytes = serialize(compositeType);
+      Object result = deserialize(bytes);
+      assertEquals(compositeType, result);
+   }
+
+   public void testErrors() throws Exception
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+
+      try
+      {
+         new ImmutableCompositeMetaType(null, "description", itemNames, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for null typeName");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ImmutableCompositeMetaType("", "description", itemNames, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for empty typeName");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", null, itemNames, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for null description");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "", itemNames, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for empty description");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", null, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for null item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", itemNames, null, itemTypes);
+         fail("Excepted IllegalArgumentException for null item descriptions");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, null);
+         fail("Excepted IllegalArgumentException for null item types");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      String[] nullItemNames = new String[] { "name1", null };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", nullItemNames, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for null element of item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      String[] nullItemDescriptions = new String[] { "desc1", null };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", itemNames, nullItemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for null element of item descriptions");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      MetaType[] nullItemTypes = new MetaType[] { SimpleMetaType.STRING, null };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, nullItemTypes);
+         fail("Excepted IllegalArgumentException for null element of item types");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      String[] wrongItemNames = new String[] { "name1" };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", wrongItemNames, itemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for wrong number of elements for item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      String[] wrongItemDescriptions = new String[] { "desc1"};
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", itemNames, wrongItemDescriptions, itemTypes);
+         fail("Excepted IllegalArgumentException for wrong number of elements for item descriptions");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      MetaType[] wrongItemTypes = new MetaType[] { SimpleMetaType.STRING };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, wrongItemTypes);
+         fail("Excepted IllegalArgumentException for wrong number of elements for item types");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      String[] duplicateItemNames = new String[] { "desc1", "desc1" };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", duplicateItemNames, itemDescriptions, itemTypes);
+         fail("Excepted OpenDataException for duplicate item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      duplicateItemNames = new String[] { "desc1", " desc1 " };
+      try
+      {
+         new ImmutableCompositeMetaType("typeName", "description", duplicateItemNames, itemDescriptions, itemTypes);
+         fail("Excepted OpenDataException for duplicate item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+   }
+
+   protected CompositeMetaType initCompositeMetaType()
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeType = new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, itemTypes);
+      return compositeType;
+   }
+
+   protected CompositeMetaType initCompositeMetaTypeDifferentItemTypes()
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.LONG };
+      CompositeMetaType compositeType = new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, itemTypes);
+      return compositeType;
+   }
+
+   protected CompositeMetaType initCompositeMetaTypeDifferentTypeName()
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeType = new ImmutableCompositeMetaType("typeName2", "description", itemNames, itemDescriptions, itemTypes);
+      return compositeType;
+   }
+
+   protected CompositeMetaType initCompositeMetaTypeDifferentItemNames()
+   {
+      String[] itemNames = new String[] { "nameX", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType compositeType = new ImmutableCompositeMetaType("typeName", "description", itemNames, itemDescriptions, itemTypes);
+      return compositeType;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableTableMetaTypeUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableTableMetaTypeUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/ImmutableTableMetaTypeUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,305 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.test;
+
+import java.util.Iterator;
+import java.util.List;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableCompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableTableMetaType;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.types.TableMetaType;
+import org.jboss.metatype.api.values.TableValue;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+
+/**
+ * ImmutableMetaTypeUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ImmutableTableMetaTypeUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(ImmutableTableMetaTypeUnitTestCase.class);
+   }
+   
+   public ImmutableTableMetaTypeUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testTableMetaType() throws Exception
+   {
+      TableMetaType tableType = initTableMetaType();
+
+      assertEquals(TableValue.class.getName(), tableType.getClassName());
+      assertEquals("description", tableType.getDescription());
+      assertEquals("typeName", tableType.getTypeName());
+      assertTrue("Tabular type should not be an array", tableType.isArray() == false);
+   }
+
+   public void testGetRowType() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+      TableMetaType tableType = initTableMetaType();
+
+      assertEquals(rowType, tableType.getRowType());
+   }
+
+   public void testIndexNames() throws Exception
+   {
+      TableMetaType tableType = initTableMetaType();
+
+      List<String> indexList = tableType.getIndexNames();
+      assertTrue("wrong number of index names", indexList.size() == 2);
+      assertTrue("index list should contain name1", indexList.contains("name1"));
+      assertTrue("index list should contain name2", indexList.contains("name2"));
+      Iterator<String> i = indexList.iterator();
+      assertTrue("first index is name1", i.next().equals("name1"));
+      assertTrue("second index is name2", i.next().equals("name2"));
+   }
+
+   public void testIsValue() throws Exception
+   {
+      // TODO testIsValue
+   }
+
+   public void testEquals() throws Exception
+   {
+      TableMetaType tableType = initTableMetaType();
+
+      assertNotSame("null is not equal to table type", tableType, null);
+      assertNotSame("object is not a equal to table type", tableType, new Object());
+
+      TableMetaType tableType2 = initTableMetaType();
+      assertEquals("Should be equal, even though the table type is a different instance", tableType, tableType2);
+      assertEquals("Should be equal, even though the table type is a different instance", tableType2, tableType);
+
+      tableType2 = initTableMetaTypeDifferentTypeName();
+      assertNotSame("should not be equal, they have different type names", tableType, tableType2);
+      assertNotSame("should not be equal, they have different type names", tableType2, tableType);
+
+      tableType2 = initTableMetaTypeDifferentRowTypes();
+      assertNotSame("should not be equal, they have different row types", tableType, tableType2);
+      assertNotSame("should not be equal, they have different row types", tableType2, tableType);
+
+      tableType2 = initTableMetaTypeDifferentIndexNames();
+      assertNotSame("should not be equal, they have different index names", tableType, tableType2);
+      assertNotSame("should not be equal, they have different index names", tableType2, tableType);
+   }
+
+   public void testHashCode() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+      TableMetaType tableType = initTableMetaType();
+
+      int myHashCode = "typeName".hashCode() + rowType.hashCode() + "name1".hashCode() + "name2".hashCode();
+      assertTrue("Wrong hash code generated", myHashCode == tableType.hashCode());
+   }
+
+   public void testToString() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+      TableMetaType tableType = initTableMetaType();
+
+      String toString = tableType.toString();
+
+      assertTrue("toString() should contain the tabular type class name", toString.indexOf(TableMetaType.class.getSimpleName()) != -1);
+      assertTrue("toString() should contain the type name", toString.indexOf("typeName") != -1);
+      assertTrue("toString() should contain the row type " + rowType, toString.indexOf(rowType.toString()) != -1);
+      assertTrue("toString() should contain the index name1", toString.indexOf("name1") != -1);
+      assertTrue("toString() should contain the index name2", toString.indexOf("name2") != -1);
+   }
+
+   public void testSerialization() throws Exception
+   {
+      TableMetaType tableType = initTableMetaType();
+      byte[] bytes = serialize(tableType);
+      Object result = deserialize(bytes);
+      assertEquals(tableType, result);
+   }
+
+   public void testErrors() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+      String[] indexNames = new String[] { "name1", "name2" };
+
+      try
+      {
+         new ImmutableTableMetaType(null, "description", rowType, indexNames);
+         fail("Expected IllegalArgumentException for null type name");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("", "description", rowType, indexNames);
+         fail("Expected IllegalArgumentException for empty type name");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", null, rowType, indexNames);
+         fail("Expected IllegalArgumentException for null description");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "", rowType, indexNames);
+         fail("Expected IllegalArgumentException for empty description");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "description", null, indexNames);
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "description", rowType, null);
+         fail("Expected IllegalArgumentException for null row type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "description", rowType, new String[0]);
+         fail("Expected IllegalArgumentException for empty index names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "description", rowType, new String[] { "name1", null });
+         fail("Expected IllegalArgumentException for null index name element");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "description", rowType, new String[] { "name1", "" });
+         fail("Expected IllegalArgumentException for empty index name element");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new ImmutableTableMetaType("typeName", "description", rowType, new String[] { "name1", "nameX" });
+         fail("Expected IllegalArgumentException for invalid index name");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+   }
+
+   protected CompositeMetaType initRowType() throws Exception
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType rowType = new ImmutableCompositeMetaType("rowTypeName", "rowDescription", itemNames, itemDescriptions, itemTypes);
+      return rowType;
+   }
+
+   protected TableMetaType initTableMetaType() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+
+      String[] indexNames = new String[] { "name1", "name2" };
+      TableMetaType tableType = new ImmutableTableMetaType("typeName", "description", rowType, indexNames);
+      return tableType;
+   }
+
+   protected TableMetaType initTableMetaTypeDifferentTypeName() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+
+      String[] indexNames = new String[] { "name1", "name2" };
+      TableMetaType tableType = new ImmutableTableMetaType("typeName2", "description", rowType, indexNames);
+      return tableType;
+   }
+
+   protected CompositeMetaType initRowType2() throws Exception
+   {
+      String[] itemNames = new String[] { "name1", "name2" };
+      String[] itemDescriptions = new String[] { "desc1", "desc2" };
+      MetaType[] itemTypes = new MetaType[] { SimpleMetaType.STRING, SimpleMetaType.INTEGER };
+      CompositeMetaType rowType = new ImmutableCompositeMetaType("rowTypeName2", "rowDescription", itemNames, itemDescriptions, itemTypes);
+      return rowType;
+   }
+
+   protected TableMetaType initTableMetaTypeDifferentRowTypes() throws Exception
+   {
+      CompositeMetaType rowType = initRowType2();
+
+      String[] indexNames = new String[] { "name1", "name2" };
+      TableMetaType tableType = new ImmutableTableMetaType("typeName", "description", rowType, indexNames);
+      return tableType;
+   }
+
+   protected TableMetaType initTableMetaTypeDifferentIndexNames() throws Exception
+   {
+      CompositeMetaType rowType = initRowType();
+
+      String[] indexNames = new String[] { "name2", "name1" };
+      TableMetaType tableType = new ImmutableTableMetaType("typeName", "description", rowType, indexNames);
+      return tableType;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/MetaTypeUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/MetaTypeUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/MetaTypeUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,233 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.test;
+
+import java.math.BigDecimal;
+import java.math.BigInteger;
+import java.util.Arrays;
+import java.util.Date;
+import java.util.List;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.SimpleValue;
+import org.jboss.metatype.api.values.TableValue;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+import org.jboss.test.metatype.types.support.MockMetaType;
+
+/**
+ * MetaTypeUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MetaTypeUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(MetaTypeUnitTestCase.class);
+   }
+   
+   public MetaTypeUnitTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void testAllowedClasses() throws Exception
+   {
+      String[] allowedClassNames = MetaType.ALLOWED_CLASSNAMES;
+      assertEquals(16, allowedClassNames.length);
+      List<String> names = Arrays.asList(allowedClassNames);
+      checkMetaType(names, Void.class);
+      checkMetaType(names, Boolean.class);
+      checkMetaType(names, Character.class);
+      checkMetaType(names, Byte.class);
+      checkMetaType(names, Short.class);
+      checkMetaType(names, Integer.class);
+      checkMetaType(names, Long.class);
+      checkMetaType(names, Float.class);
+      checkMetaType(names, Double.class);
+      checkMetaType(names, String.class);
+      checkMetaType(names, Date.class);
+      checkMetaType(names, BigDecimal.class);
+      checkMetaType(names, BigInteger.class);
+      checkMetaType(names, SimpleValue.class);
+      checkMetaType(names, CompositeValue.class);
+      checkMetaType(names, TableValue.class);
+   }
+
+   public void testConstructorSimple() throws Exception
+   {
+      MetaType test = new MockMetaType("java.lang.Void", "type", "description");
+      assertEquals("java.lang.Void", test.getClassName());
+      assertEquals("type", test.getTypeName());
+      assertEquals("description", test.getDescription());
+      assertEquals(false, test.isArray());
+   }
+
+   public void testConstructorArray() throws Exception
+   {
+      MetaType test = new MockMetaType("[[Ljava.lang.Void;", "type", "description");
+      assertEquals("[[Ljava.lang.Void;", test.getClassName());
+      assertEquals("type", test.getTypeName());
+      assertEquals("description", test.getDescription());
+      assertEquals(true, test.isArray());
+   }
+
+   public void testSerializationSimple() throws Exception
+   {
+      testSerialization("java.lang.Void", "type", "description");
+   }
+ 
+   public void testSerializationArray() throws Exception
+   {
+      testSerialization("[[Ljava.lang.Void;", "type", "description");
+   }
+
+   public void testErrors() throws Exception
+   {
+      try
+      {
+         new MockMetaType(null, "dummy", "dummy");
+         fail("className cannot be null");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("", "dummy", "dummy");
+         fail("className cannot be empty");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("java.lang.Void", null, "dummy");
+         fail("typeName cannot be null");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("java.lang.Void", null, "dummy");
+         fail("typeName cannot be empty");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("java.lang.Void", "dummy", null);
+         fail("description cannot be null");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("java.lang.Void", "dummy", "");
+         fail("description cannot be empty");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("java.lang.Class", "dummy", "dummy");
+         fail("className must be a MetaType");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("[Ljava.lang.Void", "dummy", "dummy");
+         fail("[Ljava.lang.Void is not a valid array");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("[L", "dummy", "dummy");
+         fail("[L is not a valid array");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+
+      try
+      {
+         new MockMetaType("[Xjava.lang.Void;", "dummy", "dummy");
+         fail("FAILS IN RI: [Xjava.lang.Void; is not a valid array");
+      }
+      catch (Throwable e)
+      {
+         checkThrowable(IllegalArgumentException.class, e);
+      }
+   }
+   
+   private void testSerialization(String className, String type, String description) throws Exception
+   {
+      MetaType original = new MockMetaType(className, type, description);
+      byte[] bytes = serialize(original);
+      MetaType result = (MetaType) deserialize(bytes);
+      assertEquals(original.getClassName(), result.getClassName());
+      assertEquals(original.getTypeName(), result.getTypeName());
+      assertEquals(original.getDescription(), result.getDescription());
+      assertEquals(original.isArray(), result.isArray());
+   }
+
+   private void checkMetaType(List names, Class clazz) throws Exception
+   {
+      String name = clazz.getName();
+      assertTrue(name + " is a MetaType", names.contains(name));
+
+      new MockMetaType(name, "dummy", "dummy");
+
+      new MockMetaType("[L"+name+";", "dummy", "dummy");
+
+      new MockMetaType("[[[[[L"+name+";", "dummy", "dummy");
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/SimpleMetaTypeUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/SimpleMetaTypeUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/SimpleMetaTypeUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,224 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.test;
+
+import java.math.BigDecimal;
+import java.math.BigInteger;
+import java.util.Date;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.SimpleValue;
+import org.jboss.metatype.api.values.SimpleValueSupport;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+
+/**
+ * SimpleMetaTypeUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class SimpleMetaTypeUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(SimpleMetaTypeUnitTestCase.class);
+   }
+   
+   public SimpleMetaTypeUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   SimpleMetaType[] types = new SimpleMetaType[]
+   {
+      SimpleMetaType.BIGDECIMAL,
+      SimpleMetaType.BIGINTEGER,
+      SimpleMetaType.BOOLEAN,
+      SimpleMetaType.BYTE,
+      SimpleMetaType.CHARACTER,
+      SimpleMetaType.DATE,
+      SimpleMetaType.DOUBLE,
+      SimpleMetaType.FLOAT,
+      SimpleMetaType.INTEGER,
+      SimpleMetaType.LONG,
+      SimpleMetaType.SHORT,
+      SimpleMetaType.STRING,
+      SimpleMetaType.VOID
+   };
+
+   Class[] classes = new Class[]
+   {
+      BigDecimal.class,
+      BigInteger.class,
+      Boolean.class,
+      Byte.class,
+      Character.class,
+      Date.class,
+      Double.class,
+      Float.class,
+      Integer.class,
+      Long.class,
+      Short.class,
+      String.class,
+      Void.class
+   };
+
+   @SuppressWarnings("unchecked")
+   SimpleValue[] values = new SimpleValue[]
+   {
+      new SimpleValueSupport<BigDecimal>(SimpleMetaType.BIGDECIMAL, new BigDecimal(1)),
+      new SimpleValueSupport<BigInteger>(SimpleMetaType.BIGINTEGER, BigInteger.ONE),
+      new SimpleValueSupport<Boolean>(SimpleMetaType.BOOLEAN, new Boolean(false)),
+      new SimpleValueSupport<Byte>(SimpleMetaType.BYTE, new Byte(Byte.MAX_VALUE)),
+      new SimpleValueSupport<Character>(SimpleMetaType.CHARACTER, new Character('a')),
+      new SimpleValueSupport<Date>(SimpleMetaType.DATE, new Date(System.currentTimeMillis())),
+      new SimpleValueSupport<Double>(SimpleMetaType.DOUBLE, new Double(1)),
+      new SimpleValueSupport<Float>(SimpleMetaType.FLOAT, new Float(1)),
+      new SimpleValueSupport<Integer>(SimpleMetaType.INTEGER, new Integer(1)),
+      new SimpleValueSupport<Long>(SimpleMetaType.LONG, new Long(1)),
+      new SimpleValueSupport<Short>(SimpleMetaType.SHORT, new Short(Short.MAX_VALUE)),
+      new SimpleValueSupport<String>(SimpleMetaType.STRING, new String("hello")),
+      new SimpleValueSupport(SimpleMetaType.VOID, null)
+   };
+
+   @SuppressWarnings("unchecked")
+   SimpleValue[] nullValues = new SimpleValue[]
+   {
+      new SimpleValueSupport<BigDecimal>(SimpleMetaType.BIGDECIMAL, null),
+      new SimpleValueSupport<BigInteger>(SimpleMetaType.BIGINTEGER, null),
+      new SimpleValueSupport<Boolean>(SimpleMetaType.BOOLEAN, null),
+      new SimpleValueSupport<Byte>(SimpleMetaType.BYTE, null),
+      new SimpleValueSupport<Character>(SimpleMetaType.CHARACTER, null),
+      new SimpleValueSupport<Date>(SimpleMetaType.DATE, null),
+      new SimpleValueSupport<Double>(SimpleMetaType.DOUBLE, null),
+      new SimpleValueSupport<Float>(SimpleMetaType.FLOAT, null),
+      new SimpleValueSupport<Integer>(SimpleMetaType.INTEGER, null),
+      new SimpleValueSupport<Long>(SimpleMetaType.LONG, null),
+      new SimpleValueSupport<Short>(SimpleMetaType.SHORT, null),
+      new SimpleValueSupport<String>(SimpleMetaType.STRING, null),
+      new SimpleValueSupport(SimpleMetaType.VOID, null)
+   };
+
+   public void testSimpleTypes() throws Exception
+   {
+      for (int i = 0; i < types.length; i++)
+      {
+         String className = classes[i].getName();
+         getLog().debug("SimpleMetaType: " + className + " className=" + types[i].getClassName() + " typeName=" + types[i].getTypeName() + " description=" + types[i].getDescription());
+         assertEquals(className, types[i].getClassName());
+         assertEquals(className, types[i].getTypeName());
+         assertEquals(className, types[i].getDescription());
+      }
+   }
+
+   public void testEquals() throws Exception
+   {
+      for (int i = 0; i < types.length; i++)
+      {
+        for (int j = 0; j < types.length; j++)
+        {
+           boolean resultEquals = types[i].equals(types[j]);
+           boolean resultReference = types[i] != types[j];
+           getLog().debug("equals  : " + types[i].getClassName() + " " + types[j] + " result=" + resultEquals);
+           getLog().debug("equality: " + types[i].getClassName() + " " + types[j] + " result=" + resultReference);
+           if (i == j)
+              assertEquals("SimpleMetaTypes should be equal to itself " + classes[i], types[i], types[j]);
+           else
+           {
+              assertNotSame("SimpleMetaTypes should be different under equality " + classes[i], types[i], types[j]);
+              assertTrue("SimpleMetaTypes should be different under reference " + classes[i], types[i] != types[j]);
+           }
+        }
+      }
+   }
+
+   public void testIsValue() throws Exception
+   {
+      for (int i = 0; i < types.length; ++i)
+      {
+         for (int j = 0; j < types.length; ++j)
+         {
+
+            // isValue makes no sense for Void
+            if (values[i].getValue() == null)
+               continue;
+
+            boolean result = types[j].isValue(values[i]);
+            getLog().debug("isValue: " + types[j].getClassName() + " value=" + values[i] + " result=" + result);
+            
+            if (i == j)
+            {
+               assertTrue(classes[i] + " should be a simple value of " + types[j], result);
+               result = types[i].isValue(nullValues[j]);
+               getLog().debug("isValue: " + types[i].getClassName() + " value=null value result=" + result);
+               assertTrue(nullValues[j] + " should be a simple value of " + types[i], result);
+            }
+            else
+            {
+               assertFalse(classes[i] + " should NOT be a simple value of " + types[j], result);
+               result = types[i].isValue(nullValues[j]);
+               getLog().debug("isValue: " + types[i].getClassName() + " value=null value result=" + result);
+               assertFalse(nullValues[j] + " should NOT be a simple value of " + types[i], result);
+            }
+         }
+      }
+   }
+
+   public void testHashCode() throws Exception
+   {
+      for (int i = 0; i < types.length; i++)
+      {
+         int classHashCode = classes[i].getName().hashCode();
+         int typeHashCode = types[i].hashCode();
+         getLog().debug("hashCode: " + types[i].getClassName() + " expected=" + classHashCode + " actual=" + typeHashCode);
+         assertEquals(classHashCode, typeHashCode);
+      }
+   }
+
+   public void testToString() throws Exception
+   {
+      String smt = SimpleMetaType.class.getSimpleName();
+      for (int i = 0; i < types.length; i++)
+      {
+         String className = classes[i].getName();
+         String toString = types[i].toString();
+         getLog().debug("toString: " + types[i].getClassName() + " value=" + toString);
+         assertTrue("SimpleMetaType " + className + " should contain " + smt, toString.indexOf(smt) != -1);
+         assertTrue("SimpleMetaType " + className + " should contain " + className, toString.indexOf(className) != -1);
+      }
+   }
+
+   public void testSerialization() throws Exception
+   {
+      for (int i = 0; i < types.length; i++)
+      {
+         getLog().debug("serialization: " + types[i].getClassName() + " original=" + types[i]);
+         byte[] bytes = serialize(types[i]);
+         SimpleMetaType result = (SimpleMetaType) deserialize(bytes);
+         getLog().debug("serialization: " + types[i].getClassName() + " result  =" + types[i]);
+
+         assertTrue("Should resolve to same object after serialization " + types[i], types[i] == result);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/TypesTestSuite.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/TypesTestSuite.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/types/test/TypesTestSuite.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,53 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.types.test;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * Types Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 55115 $
+ */
+public class TypesTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("Types Tests");
+
+      suite.addTest(MetaTypeUnitTestCase.suite());
+      suite.addTest(SimpleMetaTypeUnitTestCase.suite());
+      suite.addTest(ArrayMetaTypeUnitTestCase.suite());
+      suite.addTest(ImmutableCompositeMetaTypeUnitTestCase.suite());
+      suite.addTest(ImmutableTableMetaTypeUnitTestCase.suite());
+      
+      return suite;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/CompositeValueSupportUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/CompositeValueSupportUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/CompositeValueSupportUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,546 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.values.test;
+
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.Map;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.CompositeValueSupport;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.SimpleValue;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+
+/**
+ * CompositeValueSupportUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class CompositeValueSupportUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(CompositeValueSupportUnitTestCase.class);
+   }
+   
+   public CompositeValueSupportUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testCompositeValueSupport() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      String[] keys = initKeys();
+      MetaValue[] values = initValues();
+      new CompositeValueSupport(compositeMetaType, map);
+      new CompositeValueSupport(compositeMetaType, keys, values);
+   }
+
+   public void testGetCompositeMetaType() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+      assertEquals(compositeMetaType, v.getMetaType());
+   }
+
+   public void testGet()throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+
+      assertEquals(initStringValue1(), v.get("name1"));
+      assertEquals(initInteger2(), v.get("name2"));
+   }
+
+   public void testGetAll() throws Exception
+   {
+      SimpleValue<String> value1 = initStringValue1();
+      SimpleValue<Integer> integer2 = initInteger2();
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+
+      MetaValue[] result = v.getAll(new String[] { "name1", "name2" });
+      assertEquals(value1, result[0]);
+      assertEquals(integer2, result[1]);
+      result = v.getAll(new String[] { "name2", "name1" });
+      assertEquals(value1, result[1]);
+      assertEquals(integer2, result[0]);
+      result = v.getAll(new String[] { "name1" });
+      assertEquals(value1, result[0]);
+      result = v.getAll(new String[] { "name2" });
+      assertEquals(integer2, result[0]);
+   }
+
+   public void testContainsKey() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+      assertTrue("data should contain key name1", v.containsKey("name1"));
+      assertTrue("data should contain key name2", v.containsKey("name2"));
+      assertFalse("data should not contain key nameX", v.containsKey("nameX"));
+      assertFalse("data should not contain key null", v.containsKey(null));
+      assertFalse("data should not contain key <empty>", v.containsKey(""));
+   }
+
+   public void testContainsValue() throws Exception
+   {
+      SimpleValue<String> value1 = initStringValue1();
+      SimpleValue<Integer> integer2 = initInteger2();
+      SimpleValue<String> name1 = initStringName1();
+      SimpleValue<String> nullString = initStringNull();
+      SimpleValue<String> emptyString = initStringEmpty();
+      SimpleValue<Integer> nullInteger = initIntegerNull();
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+
+      assertTrue("data should contain value value1", v.containsValue(value1));
+      assertTrue("data should contain value 2", v.containsValue(integer2));
+      assertFalse("data should not contain value name1", v.containsValue(name1));
+      assertFalse("data should not contain key null", v.containsValue(null));
+      assertFalse("data should not contain key null", v.containsValue(nullString));
+      assertFalse("data should not contain key <empty>", v.containsValue(emptyString));
+
+      map.clear();
+      map.put("name1", value1);
+      map.put("name2", null);
+      v = new CompositeValueSupport(compositeMetaType, map);
+      assertTrue("data should contain value null", v.containsValue(null));
+      assertFalse("data should not contain key null", v.containsValue(nullString));
+
+      map.clear();
+      map.put("name1", value1);
+      map.put("name2", nullInteger);
+      v = new CompositeValueSupport(compositeMetaType, map);
+      assertTrue("data should contain value null", v.containsValue(nullInteger));
+      assertFalse("data should not contain key null", v.containsValue(null));
+   }
+
+   public void testValues() throws Exception
+   {
+      SimpleValue<String> value1 = initStringValue1();
+      SimpleValue<Integer> integer2 = initInteger2();
+      SimpleValue<String> name1 = initStringName1();
+      SimpleValue<String> nullString = initStringNull();
+      SimpleValue<String> emptyString = initStringEmpty();
+      SimpleValue<Integer> nullInteger = initIntegerNull();
+
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+      Collection<?> values = v.values();
+      assertTrue("data values contain 2 elements", values.size() == 2);
+      assertTrue("data values should have value1", values.contains(value1));
+      assertTrue("data values should have 2", values.contains(integer2));
+      assertFalse("data values should not have name1", values.contains(name1));
+      assertFalse("data values should not have null", values.contains(null));
+      assertFalse("data values should not have null", values.contains(nullString));
+      assertFalse("data values should not have <empty>", values.contains(emptyString));
+
+      map.clear();
+      map.put("name1", value1);
+      map.put("name2", null);
+      v = new CompositeValueSupport(compositeMetaType, map);
+      values = v.values();
+      assertTrue("data values should contain value null", values.contains(null));
+      assertFalse("data values should not have null", values.contains(nullString));
+
+      map.clear();
+      map.put("name1", value1);
+      map.put("name2", nullInteger);
+      v = new CompositeValueSupport(compositeMetaType, map);
+      values = v.values();
+      assertTrue("data values should contain value null", values.contains(nullInteger));
+      assertFalse("data values should not have null", values.contains(null));
+   }
+
+   public void testEquals() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+
+      assertEquals("data should equal itself", v, v);
+      assertNotSame("data should not equal null", v, null);
+      assertNotSame("data should not equal non CompositeData", v, new Object());
+
+      CompositeValue v2 = new CompositeValueSupport(compositeMetaType, map);
+
+      assertEquals("data should equal with data2 with different instance of the same composite type", v, v2);
+      assertEquals("data should equal with data2 with different instance of the same composite type", v2, v);
+
+      CompositeMetaType compositeMetaType2 = initCompositeMetaType2();
+      v2 = new CompositeValueSupport(compositeMetaType2, map);
+
+      assertNotSame("data should not be equal with data2 with different composite type", v, v2);
+      assertNotSame("data2 should not be equal with data with different composite type", v2, v);
+
+      Map<String, MetaValue> map2 = initMapValues2();
+      v2 = new CompositeValueSupport(compositeMetaType, map2);
+
+      assertNotSame("data should not be equal with data2 with different values", v, v2);
+      assertNotSame("data2 should not be equal with data with different value", v2, v);
+   }
+
+   public void testHashCode() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+
+      int myHashCode = compositeMetaType.hashCode() + "value1".hashCode() + new Integer(2).hashCode();
+      assertEquals("Wrong hash code generated", myHashCode, v.hashCode());
+   }
+
+   public void testToString() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+
+      String toString = v.toString();
+
+      assertTrue("toString() should contain the composite type", toString.indexOf(compositeMetaType.toString()) != -1);
+      assertTrue("toString() should contain name1", toString.indexOf("name1") != -1);
+      assertTrue("toString() should contain value1", toString.indexOf("value1") != -1);
+      assertTrue("toString() should contain name2=", toString.indexOf("name2") != -1);
+      assertTrue(toString + " should contain " + new Integer(2), toString.indexOf(new Integer(2).toString()) != -1);
+   }
+
+   public void testSerialization() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue v = new CompositeValueSupport(compositeMetaType, map);
+      byte[] bytes = serialize(v);
+      Object result = deserialize(bytes);
+      assertEquals(v, result);
+   }
+
+   public void testErrorsArray() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      String[] itemNames = initKeys();
+      MetaValue[] itemValues = initValues();
+
+      try
+      {
+         new CompositeValueSupport(null, itemNames, itemValues);
+         fail("Excepted IllegalArgumentException for null composite type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, null, itemValues);
+         fail("Excepted IllegalArgumentException for null item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, new String[0], itemValues);
+         fail("Excepted IllegalArgumentException for empty item names");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, itemNames, null);
+         fail("Excepted IllegalArgumentException for null item values");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, itemNames, new MetaValue[0]);
+         fail("Excepted IllegalArgumentException for empty item values");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, new String[] { "name1", null }, itemValues);
+         fail("Excepted IllegalArgumentException for a null item name");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, new String[] { "name1", "" }, itemValues);
+         fail("Excepted IllegalArgumentException for an empty item name");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, itemNames, new MetaValue[] { initStringWrong() });
+         fail("Excepted IllegalArgumentException for mismatch in number of itemNames/itemValues");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, new String[] { "name1" }, new MetaValue[] { initStringValue1() });
+         fail("Excepted IllegalArgumentException for mismatch in number of itemNames for CompositeType/CompositeData");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, new String[] { "name1", "wrongName" }, itemValues);
+         fail("Excepted IllegalArgumentException for an item name not in the composite type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, itemNames, new MetaValue[] { initStringValue1(), initStringWrong() });
+         fail("Excepted IllegalArgumentException for an item value of the wrong type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      new CompositeValueSupport(compositeMetaType, itemNames, new MetaValue[] { initStringValue1(), null });
+      new CompositeValueSupport(compositeMetaType, itemNames, new MetaValue[] { initStringValue1(), initIntegerNull() });
+   }
+
+   public void testErrorsMap() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+
+      try
+      {
+         new CompositeValueSupport(null, map);
+         fail("Excepted IllegalArgumentException for null composite type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, null);
+         fail("Excepted IllegalArgumentException for null map");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         new CompositeValueSupport(compositeMetaType, new HashMap<String, MetaValue>());
+         fail("Excepted IllegalArgumentException for empty map");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         HashMap<String, MetaValue> map2 = new HashMap<String, MetaValue>();
+         map2.put("name1", initStringValue1());
+         map2.put(null, initInteger2());
+         new CompositeValueSupport(compositeMetaType, map2);
+         fail("Excepted IllegalArgumentException for a null key in map");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         HashMap<String, MetaValue> map2 = new HashMap<String, MetaValue>();
+         map2.put("name1", initStringValue1());
+         map2.put("", initInteger2());
+         new CompositeValueSupport(compositeMetaType, map2);
+         fail("Excepted IllegalArgumentException for an empty key in map");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         HashMap<String, MetaValue> map2 = new HashMap<String, MetaValue>();
+         map2.put("name1", initStringValue1());
+         new CompositeValueSupport(compositeMetaType, map2);
+         fail("Excepted IllegalArgumentException for mismatch in number of items for CompositeType/CompositeData");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         HashMap<String, MetaValue> map2 = new HashMap<String, MetaValue>();
+         map2.put("name1", initStringValue1());
+         map2.put("wrongName", initInteger2());
+         new CompositeValueSupport(compositeMetaType, map2);
+         fail("Excepted IllegalArgumentException for an item name not in the composite type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         HashMap<String, MetaValue> map2 = new HashMap<String, MetaValue>();
+         map2.put("name1", initStringValue1());
+         map2.put("name2", initStringWrong());
+         new CompositeValueSupport(compositeMetaType, map2);
+         fail("Excepted IllegalArgumentException for an item value of the wrong type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      HashMap<String, MetaValue> map2 = new HashMap<String, MetaValue>();
+      map2.put("name1", initStringValue1());
+      map2.put("name2", null);
+      new CompositeValueSupport(compositeMetaType, map2);
+
+      map2 = new HashMap<String, MetaValue>();
+      map2.put("name1", initStringValue1());
+      map2.put("name2", initIntegerNull());
+      new CompositeValueSupport(compositeMetaType, map2);
+   }
+
+   public void testErrors() throws Exception
+   {
+      CompositeMetaType compositeMetaType = initCompositeMetaType();
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue data = new CompositeValueSupport(compositeMetaType, map);
+
+      try
+      {
+         data.get(null);
+         fail("Excepted IllegalArgumentException for get and a null key");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         data.get("");
+         fail("Excepted IllegalArgumentException for get and an empty key");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         data.get("wrong");
+         fail("Excepted IllegalArgumentException for get and a wrong key");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         data.getAll(new String[] { "name1", null });
+         fail("Excepted IllegalArgumentException for getAll and a null key");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         data.getAll(new String[] { "name1", "" });
+         fail("Excepted IllegalArgumentException for getAll and an empty key");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      try
+      {
+         data.getAll(new String[] { "name1", "wrong" });
+         fail("Excepted IllegalArgumentException for getAll and an invalid key");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/SimpleValueSupportUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/SimpleValueSupportUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/SimpleValueSupportUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,139 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.values.test;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.SimpleMetaType;
+import org.jboss.metatype.api.values.SimpleValue;
+import org.jboss.metatype.api.values.SimpleValueSupport;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+
+/**
+ * SimpleValueSupportUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class SimpleValueSupportUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(SimpleValueSupportUnitTestCase.class);
+   }
+   
+   public SimpleValueSupportUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testSimpleValueSupport() throws Exception
+   {
+      initStringValue1();
+   }
+
+   public void testGetSimpleMetaType() throws Exception
+   {
+      SimpleValue<String> value = initStringValue1();
+      assertEquals(SimpleMetaType.STRING, value.getMetaType());
+   }
+
+   public void testGetValue()throws Exception
+   {
+      SimpleValue<String> value = initStringValue1();
+      assertEquals("value1", value.getValue());
+   }
+
+   public void testSetValue()throws Exception
+   {
+      SimpleValueSupport<String> value = (SimpleValueSupport<String>) initStringValue1();
+      value.setValue("value2");
+      assertEquals("value2", value.getValue());
+   }
+
+   public void testEquals() throws Exception
+   {
+      SimpleValue<String> v = initStringValue1();
+
+      assertEquals("data should equal itself", v, v);
+      assertNotSame("data should not equal null", v, null);
+      assertNotSame("data should not equal null value", v, initStringNull());
+      assertNotSame("data should not equal empty value", v, initStringEmpty());
+      assertNotSame("data should not equal non SimpleValue", v, new Object());
+
+      SimpleValue v2 = initStringValue1();
+
+      assertEquals("data should equal with data2 with different instance of the same simple type", v, v2);
+      assertEquals("data should equal with data2 with different instance of the same simple type", v2, v);
+
+      v2 = initInteger2();
+
+      assertNotSame("data should not be equal with data2 with different simple type", v, v2);
+      assertNotSame("data2 should not be equal with data with different simple type", v2, v);
+
+      v2 = initStringName1();
+
+      assertNotSame("data should not be equal with data2 with different values", v, v2);
+      assertNotSame("data2 should not be equal with data with different value", v2, v);
+   }
+
+   public void testHashCode() throws Exception
+   {
+      SimpleValue<String> v = initStringValue1();
+
+      int myHashCode = "value1".hashCode();
+      assertEquals("Wrong hash code generated", myHashCode, v.hashCode());
+   }
+
+   public void testToString() throws Exception
+   {
+      SimpleValue<String> v = initStringValue1();
+
+      String toString = v.toString();
+
+      assertTrue("toString() should contain the simple type", toString.indexOf(SimpleMetaType.STRING.toString()) != -1);
+      assertTrue("toString() should contain value1", toString.indexOf("value1") != -1);
+   }
+
+   public void testSerialization() throws Exception
+   {
+      SimpleValue<String> v = initStringValue1();
+      byte[] bytes = serialize(v);
+      Object result = deserialize(bytes);
+      assertEquals(v, result);
+   }
+
+   public void testErrors() throws Exception
+   {
+      try
+      {
+         new SimpleValueSupport<String>(null, "value1");
+         fail("Excepted IllegalArgumentException for null simple type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+
+      new SimpleValueSupport<String>(SimpleMetaType.STRING, null);
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/TableValueSupportUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/TableValueSupportUnitTestCase.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/TableValueSupportUnitTestCase.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,714 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.values.test;
+
+import java.util.Arrays;
+import java.util.Collection;
+import java.util.List;
+import java.util.Map;
+import java.util.Set;
+
+import junit.framework.Test;
+
+import org.jboss.metatype.api.types.CompositeMetaType;
+import org.jboss.metatype.api.types.ImmutableTableMetaType;
+import org.jboss.metatype.api.types.TableMetaType;
+import org.jboss.metatype.api.values.CompositeValue;
+import org.jboss.metatype.api.values.CompositeValueSupport;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.TableValue;
+import org.jboss.metatype.api.values.TableValueSupport;
+import org.jboss.test.metatype.AbstractMetaTypeTest;
+
+/**
+ * TableValueSupportUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class TableValueSupportUnitTestCase extends AbstractMetaTypeTest
+{
+   public static Test suite()
+   {
+      return suite(TableValueSupportUnitTestCase.class);
+   }
+   
+   public TableValueSupportUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testTableValueSupport() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      new TableValueSupport(tableType);
+      new TableValueSupport(tableType, 100, .5f);
+   }
+   
+   public void testGetTabularType() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+      assertTrue("Expected the same table type", data.getMetaType().equals(tableType));
+   }
+   
+   public void testCalculateIndex() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      Object[] index = data.calculateIndex(compData);
+
+      assertEquals("Expected index element 0 to be value1", index[0], initStringValue1());
+      assertEquals("Expected index element 1 to be 2", index[1], initInteger2());
+
+      compData = initCompositeValue3(data);
+      index = data.calculateIndex(compData);
+
+      assertEquals("Expected index element 0 to be value2", index[0], initStringValue2());
+      assertEquals("Expected index element 1 to be 3", index[1], initInteger3());
+   }
+
+   public void testContainsKey() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      assertFalse("Didn't expect containsKey null", data.containsKey(null));
+
+      MetaValue[] index = new MetaValue[] { initStringValue1(), initInteger2() };
+      assertFalse("Didn't expect containsKey on empty data", data.containsKey(index));
+
+      CompositeValue compData = initCompositeValue2(data);
+      assertFalse("Didn't expect containsKey on index not present", data.containsKey(index));
+
+      compData = initCompositeValue(data);
+      data.put(compData);
+      assertTrue("Expected containsKey", data.containsKey(index));
+
+      compData = initCompositeValue2(data);
+      assertFalse("Didn't expect containsKey on index still not present", data.containsKey(data.calculateIndex(compData)));
+
+      data.remove(index);
+      assertFalse("Didn't expect removed data in containsKey", data.containsKey(index));
+   }
+
+   public void testContainsValue() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      assertFalse("Didn't expect containsValue null", data.containsValue(null));
+
+      CompositeMetaType rowType2 = initCompositeMetaType2();
+
+      CompositeValue compData2 = initCompositeValue(rowType2);
+
+      assertFalse("Didn't expect containsValue wrong composite type", data.containsValue(compData2));
+
+      CompositeValue compData = initCompositeValue(data);
+      assertFalse("Didn't expect containsValue on data not present", data.containsValue(compData));
+
+      data.put(compData);
+      assertTrue("Expected containsValue", data.containsValue(compData));
+
+      compData = initCompositeValue2(data);
+      assertFalse("Didn't expect containsValue on value still not present", data.containsValue(compData));
+
+      assertFalse("Didn't expect containsValue still wrong composite type", data.containsValue(compData2));
+
+      data.remove(data.calculateIndex(compData));
+      assertFalse("Didn't expect removed data in containsValue", data.containsValue(compData));
+   }
+
+   public void testGet() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      MetaValue[] index = initValues2();
+      assertNull("Expected null for get on data not present", data.get(index));
+
+      CompositeValue compData = initCompositeValue(data);
+      index = initValues();
+      data.put(compData);
+      assertEquals("Expected get to return the same value", compData, data.get(index));
+
+      index = initValues2();
+      assertNull("Didn't expect get on value still not present", data.get(index));
+
+      index = initValues();
+      data.remove(index);
+      assertNull("Didn't expect removed data in get", data.get(index));
+   }
+
+   public void testPut() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      MetaValue[] index = initValues();
+      data.put(compData);
+      assertEquals("The data should be present after put", compData, data.get(index));
+
+      CompositeValue compData2 = initCompositeValue2(data);
+      index = initValues2();
+      data.put(compData2);
+      assertEquals("Another data should be present after put", compData2, data.get(index));
+
+      index = initValues();
+      assertEquals("The previous data should be present after put", compData, data.get(index));
+
+      data.remove(index);
+      data.put(compData);
+      assertEquals("Data should be present after remove/put", compData, data.get(index));
+   }
+
+   public void testRemove() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      MetaValue[] index = initValues();
+
+      assertNull("Remove on data not present returns null", data.remove(index));
+
+      data.put(compData);
+      assertEquals("Remove on data present returns the data", compData, data.remove(index));
+   }
+
+   public void testPutAll() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      data.putAll((CompositeValue[]) null);
+      assertTrue("Put all null is ok", data.isEmpty());
+
+      CompositeValue compData = initCompositeValue(data);
+
+      CompositeValue[] toPut = new CompositeValue[] { compData };
+      data.putAll(toPut);
+      assertEquals("Put all added one", 1, data.size());
+      assertTrue("Put all added the correct data", data.containsValue(compData));
+
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      toPut = new CompositeValue[] { compData2, compData3 };
+      data.putAll(toPut);
+      assertEquals("Put all added two", 3, data.size());
+      assertTrue("Put all added the correct data", data.containsValue(compData2));
+      assertTrue("Put all added the correct data", data.containsValue(compData3));
+      assertTrue("Put all original data still present", data.containsValue(compData));
+   }
+
+   public void testClear() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      data.putAll((CompositeValue[]) null);
+      assertTrue("Put all null is ok", data.isEmpty());
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      data.clear();
+      assertTrue("Clear should clear the data", data.isEmpty());
+   }
+
+   public void testSize() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      assertEquals("Initial size is zero", 0, data.size());
+
+      CompositeValue compData = initCompositeValue(data);
+
+      data.putAll(new CompositeValue[] { compData });
+      assertEquals("Expected one element", 1, data.size());
+
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData2, compData3 });
+      assertEquals("Expected three elements", 3, data.size());
+
+      data.remove(initValues4());
+      assertEquals("Expected two elements", 2, data.size());
+
+      data.clear();
+      assertEquals("Expected no elements", 0, data.size());
+   }
+
+   public void testIsEmpty() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      assertTrue("Initially empty", data.isEmpty());
+
+      CompositeValue compData = initCompositeValue(data);
+
+      data.putAll(new CompositeValue[] { compData });
+      assertFalse("Not empty after a put", data.isEmpty());
+
+      data.clear();
+      assertTrue("Expected no elements", data.isEmpty());
+   }
+
+   public void testKeySet() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      Set<List<MetaValue>> keySet = data.keySet();
+      assertEquals("Key set should contain 3 elements", 3, keySet.size());
+      assertTrue("Key set should contain index [value1, 2]", keySet.contains(Arrays.asList(initValues())));
+      assertTrue("Key set should contain index [value1, 3]", keySet.contains(Arrays.asList(initValues2())));
+      assertTrue("Key set should contain index [value1, 4]", keySet.contains(Arrays.asList(initValues4())));
+   }
+
+   public void testValues() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      Collection<CompositeValue> values = data.values();
+      assertEquals("Values should contain 3 elements", 3, values.size());
+      assertTrue("Values should contain index compData", values.contains(compData));
+      assertTrue("Values should contain index compData2", values.contains(compData2));
+      assertTrue("Values should contain index compData3", values.contains(compData3));
+   }
+
+   public void testClone()
+      throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      TableValue clone = data.clone();
+      assertEquals("Clone should have the same tabular type", data.getMetaType(), clone.getMetaType());
+      assertEquals("Clone should have the same number of elements", data.size(), clone.size());
+      CompositeValue compDataClone = clone.get(initValues());
+      assertTrue("Should be a shallow clone", compData == compDataClone);
+   }
+
+   public void testEquals() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      assertNotSame("Null should not be equal", data, null);
+      assertNotSame("Only TableValues should be equal", data, new Object());
+
+      assertEquals("An instance should equal itself", data, data);
+
+      TableValueSupport data2 = new TableValueSupport(tableType);
+
+      assertEquals("Two different instances with the same table type are equal", data, data2);
+      assertEquals("Two different instances with the same table type are equal", data2, data);
+
+      TableMetaType tableType2 = initTableType2();
+      data2 = new TableValueSupport(tableType2);
+
+      assertNotSame("Instances with different table type are not equal", data, data2);
+      assertNotSame("Instances with different table type are not equal", data2, data);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      data2 = new TableValueSupport(tableType);
+      data2.putAll(new CompositeValue[] { compData, compData2, compData3 });
+      assertEquals("Instances with the same composite values are equal", data, data2);
+      assertEquals("Instances with the same composite values are equal", data2, data);
+
+      data2 = new TableValueSupport(tableType);
+      data2.putAll(new CompositeValue[] { compData, compData2});
+      assertNotSame("Instances with different composite values are not equal", data, data2);
+      assertNotSame("Instances with different composite values are not equal", data2, data);
+   }
+
+   public void testHashCode() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      int myHashCode = tableType.hashCode() + compData.hashCode() + compData2.hashCode() + compData3.hashCode();
+      assertEquals("Wrong hash code generated", myHashCode, data.hashCode());
+   }
+
+   public void testToString() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      String toString = data.toString();
+
+      assertTrue("toString() should contain the tabular type", toString.indexOf(tableType.toString()) != -1);
+      assertTrue("toString() should contain index=compositeValue for compData",
+         toString.indexOf(Arrays.asList(data.calculateIndex(compData)) + "=" + compData) != -1);
+      assertTrue("toString() should contain index=compositeValue for compData2",
+         toString.indexOf(Arrays.asList(data.calculateIndex(compData2)) + "=" + compData2) != -1);
+      assertTrue("toString() should contain index=compositeValue for compData3",
+         toString.indexOf(Arrays.asList(data.calculateIndex(compData3)) + "=" + compData3) != -1);
+   }
+
+   public void testSerialization() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      TableValueSupport data = new TableValueSupport(tableType);
+
+      CompositeValue compData = initCompositeValue(data);
+      CompositeValue compData2 = initCompositeValue2(data);
+      CompositeValue compData3 = initCompositeValue4(data);
+
+      data.putAll(new CompositeValue[] { compData, compData2, compData3 });
+
+      byte[] bytes = serialize(data);
+      Object result = deserialize(bytes);
+      assertEquals(data, result);
+   }
+
+   public void testErrors() throws Exception
+   {
+      TableMetaType tableType = initTableType();
+
+      CompositeValue compData = initCompositeValue(tableType.getRowType());
+      CompositeValue compData2 = initCompositeValue2(initCompositeMetaType2());
+
+      try
+      {
+         new TableValueSupport(null);
+         fail("Expected IllegalArgumentException for null tabular type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new TableValueSupport(null, 10, .5f);
+         fail("Expected IllegalArgumentException for null tabular type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new TableValueSupport(tableType, -1, .5f);
+         fail("Expected IllegalArgumentException for negative initial capacity");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new TableValueSupport(tableType, 10, 0f);
+         fail("Expected IllegalArgumentException for zero load factor");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         new TableValueSupport(tableType, 10, -0.5f);
+         fail("Expected IllegalArgumentException for negative load factor");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.calculateIndex(null);
+         fail("Expected IllegalArgumentException for calculate index on null object");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.calculateIndex(compData2);
+         fail("Expected IllegalArgumentException for calculate index on wrong composite type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.get((MetaValue[]) null);
+         fail("Expected IllegalArgumentException for get(null)");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.get(new MetaValue[] { initStringWrong() });
+         fail("Expected IllegalArgumentException for get(wrong)");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.put(null);
+         fail("Expected IllegalArgumentException for put(CompositeValue) with null value");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.put(compData2);
+         fail("Expected IllegalArgumentException for put(CompositeValue) with wrong CompositeType");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.put(compData);
+         data.put(compData);
+         fail("Expected IllegalArgumentException for put(CompositeValue)");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.remove((MetaValue[]) null);
+         fail("Expected IllegalArgumentException for remove(null)");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         data.remove(new MetaValue[] { initStringWrong() });
+         fail("Expected IllegalArgumentException for remove(wrong)");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         CompositeValue[] toPut = new CompositeValue[] { compData, null };
+         data.putAll(toPut);
+         fail("Expected IllegalArgumentException for putAll(CompositeValue[]) null");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         CompositeValue[] toPut = new CompositeValue[] { compData, compData2 };
+         data.putAll(toPut);
+         fail("Expected IllegalArgumentException for putAll(CompositeValue[]) wrong composite type");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         CompositeValue[] toPut = new CompositeValue[] { compData, compData };
+         data.putAll(toPut);
+         fail("Expected IllegalArgumentException for putAll(CompositeValue[]) with duplicate data");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+      
+      try
+      {
+         TableValueSupport data = new TableValueSupport(tableType);
+         CompositeValue[] toPut = new CompositeValue[] { compData };
+         data.putAll(toPut);
+         data.putAll(toPut);
+         fail("Expected IllegalArgumentException for putAll(CompositeValue[]) adding a duplicate");
+      }
+      catch (Throwable t)
+      {
+         checkThrowable(IllegalArgumentException.class, t);
+      }
+   }
+
+   protected TableMetaType initTableType()
+   {
+      CompositeMetaType rowType = initCompositeMetaType();
+
+      String[] indexNames = new String[] { "name1", "name2" };
+      TableMetaType tableType = new ImmutableTableMetaType("typeName", "description", rowType, indexNames);
+      return tableType;
+   }
+
+   protected TableMetaType initTableType2()
+   {
+      CompositeMetaType rowType = initCompositeMetaType();
+
+      String[] indexNames = new String[] { "name1", "name2" };
+      TableMetaType tableType = new ImmutableTableMetaType("typeName2", "description", rowType, indexNames);
+      return tableType;
+   }
+
+   protected CompositeValue initCompositeValue(TableValue tableValue)
+   {
+      return initCompositeValue(tableValue.getMetaType().getRowType());
+   }
+
+   protected CompositeValue initCompositeValue(CompositeMetaType rowType)
+   {
+      Map<String, MetaValue> map = initMapValues();
+      CompositeValue compData = new CompositeValueSupport(rowType, map);
+      return compData;
+   }
+
+   protected CompositeValue initCompositeValue2(TableValue tableValue)
+   {
+      return initCompositeValue2(tableValue.getMetaType().getRowType());
+   }
+
+   protected CompositeValue initCompositeValue2(CompositeMetaType rowType)
+   {
+      Map<String, MetaValue> map = initMapValues2();
+      CompositeValue compData = new CompositeValueSupport(rowType, map);
+      return compData;
+   }
+
+   protected CompositeValue initCompositeValue3(TableValue tableValue)
+   {
+      Map<String, MetaValue> map = initMapValues3();
+      CompositeValue compData = new CompositeValueSupport(tableValue.getMetaType().getRowType(), map);
+      return compData;
+   }
+
+   protected CompositeValue initCompositeValue4(TableValue tableValue)
+   {
+      Map<String, MetaValue> map = initMapValues4();
+      CompositeValue compData = new CompositeValueSupport(tableValue.getMetaType().getRowType(), map);
+      return compData;
+   }
+}

Added: projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/ValuesTestSuite.java
===================================================================
--- projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/ValuesTestSuite.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/microcontainer/trunk/metatype/src/tests/org/jboss/test/metatype/values/test/ValuesTestSuite.java	2006-12-19 13:01:12 UTC (rev 59139)
@@ -0,0 +1,51 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.metatype.values.test;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * Values Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 55115 $
+ */
+public class ValuesTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("Values Tests");
+
+      suite.addTest(SimpleValueSupportUnitTestCase.suite());
+      suite.addTest(CompositeValueSupportUnitTestCase.suite());
+      suite.addTest(TableValueSupportUnitTestCase.suite());
+      
+      return suite;
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 08:02:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 08:02:14 -0500
Subject: [jboss-cvs] JBossAS SVN: r59140 - in projects/microcontainer/trunk:
	. managed managed/src managed/src/etc managed/src/main
	managed/src/main/org managed/src/main/org/jboss
	managed/src/main/org/jboss/managed
	managed/src/main/org/jboss/managed/api
	managed/src/main/org/jboss/managed/mock managed/src/tests
	managed/src/tests/org managed/src/tests/org/jboss
	managed/src/tests/org/jboss/test
Message-ID: <E1Gwebm-0002F1-Np@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-19 08:02:07 -0500 (Tue, 19 Dec 2006)
New Revision: 59140

Added:
   projects/microcontainer/trunk/managed/
   projects/microcontainer/trunk/managed/.classpath
   projects/microcontainer/trunk/managed/.project
   projects/microcontainer/trunk/managed/build.bat
   projects/microcontainer/trunk/managed/build.sh
   projects/microcontainer/trunk/managed/build.xml
   projects/microcontainer/trunk/managed/src/
   projects/microcontainer/trunk/managed/src/etc/
   projects/microcontainer/trunk/managed/src/etc/default.mf
   projects/microcontainer/trunk/managed/src/main/
   projects/microcontainer/trunk/managed/src/main/org/
   projects/microcontainer/trunk/managed/src/main/org/jboss/
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/Fields.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDOMFields.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDataSourceManagedObject.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/Test.java
   projects/microcontainer/trunk/managed/src/tests/
   projects/microcontainer/trunk/managed/src/tests/org/
   projects/microcontainer/trunk/managed/src/tests/org/jboss/
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty
Log:
Start of managed project

Added: projects/microcontainer/trunk/managed/.classpath
===================================================================
--- projects/microcontainer/trunk/managed/.classpath	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/.classpath	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src/main"/>
+	<classpathentry kind="src" path="src/tests"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/metatype"/>
+	<classpathentry kind="output" path="output/eclipse-classes"/>
+</classpath>

Added: projects/microcontainer/trunk/managed/.project
===================================================================
--- projects/microcontainer/trunk/managed/.project	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/.project	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>managed</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>

Added: projects/microcontainer/trunk/managed/build.bat
===================================================================
--- projects/microcontainer/trunk/managed/build.bat	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/build.bat	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,89 @@
+ at echo off
+REM  ======================================================================
+REM
+REM  This is the main entry point for the build system.
+REM
+REM  Users should be sure to execute this file rather than 'ant' to ensure
+REM  the correct version is being used with the correct configuration.
+REM
+REM  ======================================================================
+REM
+REM $Id: build.bat 31497 2005-05-24 16:47:10Z adrian $
+REM
+REM Authors:
+REM     Jason Dillon <jason at planet57.com>
+REM     Sacha Labourey <sacha.labourey at cogito-info.ch>
+REM
+
+REM ******************************************************
+REM Ignore the ANT_HOME variable: we want to use *our*
+REM ANT version and associated JARs.
+REM ******************************************************
+REM Ignore the users classpath, cause it might mess
+REM things up
+REM ******************************************************
+
+SETLOCAL
+
+set CLASSPATH=
+set ANT_HOME=
+set ANT_OPTS=-Djava.protocol.handler.pkgs=org.jboss.net.protocol -Dbuild.script=build.bat
+
+REM ******************************************************
+REM - "for" loops have been unrolled for compatibility
+REM   with some WIN32 systems.
+REM ******************************************************
+
+set NAMES=tools;tools\ant;tools\apache\ant
+set SUBFOLDERS=..;..\..;..\..\..;..\..\..\..
+
+REM ******************************************************
+REM ******************************************************
+
+SET EXECUTED=FALSE
+for %%i in (%NAMES%) do call :subLoop %%i %1 %2 %3 %4 %5 %6
+
+goto :EOF
+
+
+REM ******************************************************
+REM ********* Search for names in the subfolders *********
+REM ******************************************************
+
+:subLoop
+for %%j in (%SUBFOLDERS%) do call :testIfExists %%j\%1\bin\ant.bat %2 %3 %4 %5 %6 %7
+
+goto :EOF
+
+
+REM ******************************************************
+REM ************ Test if ANT Batch file exists ***********
+REM ******************************************************
+
+:testIfExists
+if exist %1 call :BatchFound %1 %2 %3 %4 %5 %6 %7 %8
+
+goto :EOF
+
+
+REM ******************************************************
+REM ************** Batch file has been found *************
+REM ******************************************************
+
+:BatchFound
+if (%EXECUTED%)==(FALSE) call :ExecuteBatch %1 %2 %3 %4 %5 %6 %7 %8
+set EXECUTED=TRUE
+
+goto :EOF
+
+REM ******************************************************
+REM ************* Execute Batch file only once ***********
+REM ******************************************************
+
+:ExecuteBatch
+echo Calling %1 %2 %3 %4 %5 %6 %7 %8
+call %1 %2 %3 %4 %5 %6 %7 %8
+
+:end
+
+if "%NOPAUSE%" == "" pause


Property changes on: projects/microcontainer/trunk/managed/build.bat
___________________________________________________________________
Name: svn:executable
   + 

Added: projects/microcontainer/trunk/managed/build.sh
===================================================================
--- projects/microcontainer/trunk/managed/build.sh	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/build.sh	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,172 @@
+#!/bin/sh
+### ====================================================================== ###
+##                                                                          ##
+##  This is the main entry point for the build system.                      ##
+##                                                                          ##
+##  Users should be sure to execute this file rather than 'ant' to ensure   ##
+##  the correct version is being used with the correct configuration.       ##
+##                                                                          ##
+### ====================================================================== ###
+
+# $Id: build.sh 31497 2005-05-24 16:47:10Z adrian $
+
+PROGNAME=`basename $0`
+DIRNAME=`dirname $0`
+GREP="grep"
+ROOT="/"
+
+# Ignore user's ANT_HOME if it is set
+ANT_HOME=""
+
+# the default search path for ant
+ANT_SEARCH_PATH="\
+    tools
+    tools/ant \
+    tools/apache/ant \
+    ant"
+
+# the default build file name
+ANT_BUILD_FILE="build.xml"
+
+# the default arguments
+ANT_OPTIONS="-find $ANT_BUILD_FILE"
+
+# Use the maximum available, or set MAX_FD != -1 to use that
+MAX_FD="maximum"
+
+# OS specific support (must be 'true' or 'false').
+cygwin=false;
+darwin=false;
+case "`uname`" in
+    CYGWIN*)
+        cygwin=true
+        ;;
+
+    Darwin*)
+        darwin=true
+        ;;
+esac
+
+#
+# Helper to complain.
+#
+die() {
+    echo "${PROGNAME}: $*"
+    exit 1
+}
+
+#
+# Helper to complain.
+#
+warn() {
+    echo "${PROGNAME}: $*"
+}
+
+#
+# Helper to source a file if it exists.
+#
+maybe_source() {
+    for file in $*; do
+	if [ -f "$file" ]; then
+	    . $file
+	fi
+    done
+}
+
+search() {
+    search="$*"
+    for d in $search; do
+	ANT_HOME="`pwd`/$d"
+	ANT="$ANT_HOME/bin/ant"
+	if [ -x "$ANT" ]; then
+	    # found one
+	    echo $ANT_HOME
+	    break
+	fi
+    done
+}
+
+#
+# Main function.
+#
+main() {
+    # if there is a build config file. then source it
+    maybe_source "$DIRNAME/build.conf" "$HOME/.build.conf"
+
+    # Increase the maximum file descriptors if we can
+    if [ $cygwin = "false" ]; then
+	MAX_FD_LIMIT=`ulimit -H -n`
+	if [ $? -eq 0 ]; then
+	    if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ]; then
+		# use the system max
+		MAX_FD="$MAX_FD_LIMIT"
+	    fi
+
+	    ulimit -n $MAX_FD
+	    if [ $? -ne 0 ]; then
+		warn "Could not set maximum file descriptor limit: $MAX_FD"
+	    fi
+	else
+	    warn "Could not query system maximum file descriptor limit: $MAX_FD_LIMIT"
+	fi
+    fi
+
+    # try the search path
+    ANT_HOME=`search $ANT_SEARCH_PATH`
+
+    # try looking up to root
+    if [ "x$ANT_HOME" = "x" ]; then
+	target="build"
+	_cwd=`pwd`
+
+	while [ "x$ANT_HOME" = "x" ] && [ "$cwd" != "$ROOT" ]; do
+	    cd ..
+	    cwd=`pwd`
+	    ANT_HOME=`search $ANT_SEARCH_PATH`
+	done
+
+	# make sure we get back
+	cd $_cwd
+
+	if [ "$cwd" != "$ROOT" ]; then
+	    found="true"
+	fi
+
+	# complain if we did not find anything
+	if [ "$found" != "true" ]; then
+	    die "Could not locate Ant; check \$ANT or \$ANT_HOME."
+	fi
+    fi
+
+    # make sure we have one
+    ANT=$ANT_HOME/bin/ant
+    if [ ! -x "$ANT" ]; then
+	die "Ant file is not executable: $ANT"
+    fi
+
+    # need to specify planet57/buildmagic protocol handler package
+    ANT_OPTS="-Djava.protocol.handler.pkgs=org.jboss.net.protocol"
+
+    # setup some build properties
+    ANT_OPTS="$ANT_OPTS -Dbuild.script=$0"
+
+    # change to the directory where the script lives so users are not forced
+    # to be in the same directory as build.xml
+    cd $DIRNAME
+
+    # export some stuff for ant
+    export ANT ANT_HOME ANT_OPTS
+
+    # execute in debug mode, or simply execute
+    if [ "x$ANT_DEBUG" != "x" ]; then
+	/bin/sh -x $ANT $ANT_OPTIONS "$@"
+    else
+	exec $ANT $ANT_OPTIONS "$@"
+    fi
+}
+
+##
+## Bootstrap
+##
+
+main "$@"


Property changes on: projects/microcontainer/trunk/managed/build.sh
___________________________________________________________________
Name: svn:executable
   + 

Added: projects/microcontainer/trunk/managed/build.xml
===================================================================
--- projects/microcontainer/trunk/managed/build.xml	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/build.xml	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,179 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE project [
+   <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
+   <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
+   <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
+   <!ENTITY targets SYSTEM "../tools/etc/buildmagic/targets.ent">
+]>
+
+<!-- ====================================================================== -->
+<!--                                                                        -->
+<!--  JBoss, the OpenSource J2EE webOS                                      -->
+<!--                                                                        -->
+<!--  Distributable under LGPL license.                                     -->
+<!--  See terms of license at http://www.gnu.org.                           -->
+<!--                                                                        -->
+<!-- ====================================================================== -->
+
+<!-- $Id: build.xml 58705 2006-11-28 16:24:22Z adrian at jboss.org $ -->
+
+<project default="main" name="JBoss/Managed">
+
+  <!-- ================================================================== -->
+  <!-- Setup                                                              -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Include the common Buildmagic elements.
+     |
+     | This defines several different targets, properties and paths.
+     | It also sets up the basic extention tasks amoung other things.
+   -->
+
+  &buildmagic;
+
+  <!--
+     | Include the normal targets.
+   -->
+  &targets;
+
+  <!-- ================================================================== -->
+  <!-- Configuration                                                      -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Configure the build system.
+     |
+     | This target is invoked by the Buildmagic initialization logic and
+     | should contain module specific configuration elements.
+   -->
+
+  <target name="configure" unless="configure.disable">
+
+    <!-- =================== -->
+    <!-- Basic Configuration -->
+    <!-- =================== -->
+
+    <!-- Module name(s) & version -->
+    <property name="module.name" value="managed"/>
+    <property name="module.Name" value="JBoss Managed"/>
+    <property name="module.version" value="DEV"/>
+
+    <!-- ========= -->
+    <!-- Libraries -->
+    <!-- ========= -->
+
+    &libraries;
+
+    <!-- The combined library classpath -->
+    <path id="library.classpath">
+      <path refid="jboss/common.core.classpath"/>
+      <path refid="jboss/common.logging.spi.classpath"/>
+      <path refid="jboss/common.logging.log4j.classpath"/>
+    </path>
+
+    &modules;
+
+    <!-- The combined dependant module classpath -->
+    <path id="dependentmodule.classpath">
+      <path refid="jboss.metatype.classpath"/>
+    </path>
+
+   <!-- ============================= -->
+   <!-- Paths etc. for the retro task -->
+   <!-- ============================= -->
+   <property name="build.classes.retro" value="${module.output}/classes-retro"/>
+   <property name="build.lib.retro" value="${module.output}/lib14"/>
+   <path id="jbossretro.classpath">
+     <path refid="apache.ant.classpath"/>
+     <path refid="jboss.jbossretro.classpath"/>
+     <path refid="jboss/backport.concurrent.classpath"/>
+     <path refid="javassist.classpath"/>
+   </path>
+
+     
+    <!-- ===== -->
+    <!-- Tasks -->
+    <!-- ===== -->
+
+    <property name="jar.prefix" value="jboss-managed"/>
+    <property name="javac.target" value="1.5"/>
+    <property name="javac.source" value="1.5"/>
+
+    <call target="_default:task-init"/>
+
+  </target>
+
+  <!-- ================================================================== -->
+  <!-- Compile                                                            -->
+  <!-- ================================================================== -->
+
+  <!--
+     | Compile everything.
+     |
+     | This target should depend on other compile-* targets for each
+     | different type of compile that needs to be performed, short of
+     | documentation compiles.
+   -->
+
+  <target name="compile"
+	  description="Compile all source files."
+	  depends="_default:compile-classes,
+              _default:compile-etc,
+              retro"
+  />
+
+  <target name="retro">
+    <mkdir dir="${build.lib.retro}"/>
+    <taskdef name="retro" classname="org.jboss.ant.tasks.retro.Retro" classpathref="jbossretro.classpath"/>
+    <retro compilerclasspathref="jbossretro.classpath" destdir="${build.classes.retro}">
+      <classpath refid="jbossretro.classpath"/>
+      <classpath refid="library.classpath"/>
+      <classpath refid="dependentmodule.classpath"/>
+      <classpath>
+        <pathelement path="${build.classes}"/>
+      </classpath>
+      <src path="${build.classes}"/>
+    </retro>      
+  </target> 
+   
+  <!-- ================================================================== -->
+  <!-- Archives                                                           -->
+  <!-- ================================================================== -->
+
+  <!-- 
+     |  Build all jar files.
+    -->
+  <target name="module-jars" depends="init">
+    
+    <jar jarfile="${build.lib}/${jar.prefix}.jar" manifest="${build.etc}/default.mf">
+      <fileset dir="${build.classes}"/>
+    </jar>
+    <jar jarfile="${build.lib.retro}/${jar.prefix}14.jar" manifest="${build.etc}/default.mf">
+      <fileset dir="${build.classes.retro}"/>
+    </jar>
+    <!-- Minimal source bundle -->
+    <zip destfile="${build.lib}/${jar.prefix}-src.zip">
+      <fileset dir="${source.java}">
+        <include name="**"/>
+      </fileset>
+    </zip>
+  </target>
+   
+  <!-- ================================================================== -->
+  <!-- Test                                                               -->
+  <!-- ================================================================== -->
+
+  <target name="mock" depends="compile">
+    
+     <java classname="org.jboss.managed.mock.Test">
+        <classpath>
+           <pathelement location="${build.classes}"/>
+           <path refid="javac.classpath"/>
+           <path refid="apache.xerces.classpath"/>
+        </classpath>
+     </java>
+
+  </target>
+
+</project>

Added: projects/microcontainer/trunk/managed/src/etc/default.mf
===================================================================
--- projects/microcontainer/trunk/managed/src/etc/default.mf	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/etc/default.mf	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,10 @@
+Manifest-Version: 1.0
+Created-By: @java.vm.version@ (@java.vm.vendor@)
+Specification-Title: @specification.title@
+Specification-Version: @specification.version@
+Specification-Vendor: @specification.vendor@
+Implementation-Title: @implementation.title@
+Implementation-URL: @implementation.url@
+Implementation-Version: @implementation.version@
+Implementation-Vendor: @implementation.vendor@
+Implementation-Vendor-Id: @implementation.vendor.id@

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/Fields.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/Fields.java	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/Fields.java	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,76 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.api;
+
+import java.io.Serializable;
+
+/**
+ * Fields.
+ * 
+ * TODO the fields names should be annotation class names (where relevant) when the annotations exist
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface Fields extends Serializable
+{
+   /** The name field name */
+   String NAME = "name";
+
+   /** The description field name */
+   String DESCRIPTION = "description";
+
+   /** The meta type field name */
+   String META_TYPE = "metaType";
+
+   /** The value */
+   String VALUE = "value";
+
+   /** The legal values */
+   String LEGAL_VALUES = "legalValues";
+
+   /** The minimum value */
+   String MINIMUM_VALUE = "minValue";
+
+   /** The maximum value */
+   String MAXIMUM_VALUE = "maxValue";
+
+   /** The mandatory */
+   String MANDATORY = "mandatory";
+   
+   // TODO other standard fields here
+   
+   /**
+    * Get a field with the given name
+    * 
+    * @param name the name
+    * @return the field value
+    */
+   Serializable getField(String name);
+   
+   /**
+    * Set a field with the given name
+    * 
+    * @param name the name
+    * @param value the field value
+    */
+   void setField(String name, Serializable value);
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,114 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.api;
+
+import java.io.Serializable;
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Set;
+
+/**
+ * ManagedObject.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ManagedObject implements Serializable
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -2588364350006686542L;
+
+   /** The properties */
+   private Set<ManagedProperty> properties;
+   
+   /**
+    * Create a new ManagedObject
+    * 
+    * @param properties the properties 
+    */
+   public ManagedObject(Set<ManagedProperty> properties)
+   {
+      if (properties == null)
+         properties = Collections.emptySet();
+      this.properties = properties;
+   }
+   
+   // TODO identity, deployment info, scope, etc.
+   
+   /**
+    * Get the property names
+    * 
+    * @return the property names
+    */
+   public Set<String> getPropertyNames()
+   {
+      Set<String> result = new HashSet<String>(properties.size());
+      for (ManagedProperty property : properties)
+         result.add(property.getName());
+      return result;
+   }
+   
+   /**
+    * Get a property
+    * 
+    * @param name the name
+    * @return the property
+    */
+   public ManagedProperty getProperty(String name)
+   {
+      if (name == null)
+         throw new IllegalArgumentException("Null name");
+
+      for (ManagedProperty property : properties)
+      {
+         if (name.equals(property.getName()))
+            return property;
+      }
+      return null;
+   }
+   
+   /**
+    * Get the properties
+    * 
+    * @return the properties
+    */
+   public Set<ManagedProperty> getProperties()
+   {
+      return Collections.unmodifiableSet(properties);
+   }
+
+   /**
+    * Get the real properties
+    * 
+    * @return the properties
+    */
+   protected Set<ManagedProperty> getManagedProperties()
+   {
+      return properties;
+   }
+   
+   // TODO state, lifecycle, on-demand, etc.
+   
+   // TODO statistics
+   
+   // TODO listener api
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,297 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.api;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.io.ObjectStreamField;
+import java.io.Serializable;
+import java.util.Set;
+
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.SimpleValue;
+
+/**
+ * ManagedProperty.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ManagedProperty implements Serializable
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 2268454772998030799L;
+   
+   /** The serialized form */
+   private static final ObjectStreamField[] serialPersistentFields =
+      new ObjectStreamField[]
+      {
+         new ObjectStreamField("fields", Fields.class),
+      };
+
+   /** The fields */
+   private Fields fields;
+
+   /** The property name */
+   private transient String name;
+   
+   /**
+    * Create a new ManagedProperty.
+    * 
+    * @param fields the fields
+    * @throws IllegalArgumentException for null fields
+    */
+   public ManagedProperty(Fields fields)
+   {
+      if (fields == null)
+         throw new IllegalArgumentException("Null fields");
+      this.fields = fields;
+      
+      name = getField(Fields.NAME, String.class);
+      if (name == null)
+         throw new IllegalArgumentException("No " + Fields.NAME + " in fields");
+   }
+   
+   /**
+    * Get the fields
+    * 
+    * @return the fields
+    */
+   public Fields getFields()
+   {
+      return fields;
+   }
+   
+   /**
+    * Get a field
+    *
+    * TODO general reconstruction code for metatypes
+    * @param <T> the expected type
+    * @param fieldName the field name
+    * @param expected the expected type
+    * @return the value
+    */
+   @SuppressWarnings("unchecked")
+   public <T> T getField(String fieldName, Class<T> expected)
+   {
+      if (fieldName == null)
+         throw new IllegalArgumentException("Null field name");
+      if (expected == null)
+         throw new IllegalArgumentException("Null expected type");
+      
+      Serializable field = getFields().getField(fieldName);
+      
+      if (field == null)
+         return null;
+
+      if (expected.isInstance(field))
+         return expected.cast(field);
+      
+      if (field instanceof SimpleValue)
+      {
+         SimpleValue value = (SimpleValue) field;
+         Object result = value.getValue();
+         if (result == null)
+            return null;
+         return expected.cast(result);
+      }
+      
+      throw new IllegalStateException("Field " + fieldName + " with value " + field + " is  a of the expected type: " + expected.getName());
+   }
+   
+   /**
+    * Set a field
+    *
+    * TODO metaType stuff
+    * @param fieldName the field name
+    * @param value the value
+    */
+   public void setField(String fieldName, Serializable value)
+   {
+      if (fieldName == null)
+         throw new IllegalArgumentException("Null field name");
+      
+      getFields().setField(fieldName, value);
+   }
+   
+   /**
+    * Get the property's name
+    * 
+    * @return the property's name
+    */
+   public String getName()
+   {
+      return name;
+   }
+
+   /**
+    * Get the description
+    * 
+    * @return the description
+    */
+   public String getDescription()
+   {
+      return getField(Fields.DESCRIPTION, String.class);
+   }
+
+   /**
+    * Get the type
+    * 
+    * @return the type
+    */
+   public MetaType getMetaType()
+   {
+      return getField(Fields.META_TYPE, MetaType.class);
+   }
+
+   /**
+    * Get the value
+    * 
+    * @return the value
+    */
+   public Object getValue()
+   {
+      return getField(Fields.VALUE, Object.class);
+   }
+
+   /**
+    * Set the value
+    * 
+    * @param value the value
+    */
+   public void setValue(Serializable value)
+   {
+      setField(Fields.VALUE, value);
+   }
+
+   /**
+    * Get the legal values
+    * 
+    * @return the legal values
+    */
+   @SuppressWarnings("unchecked")
+   public Set<MetaValue> getLegalValues()
+   {
+      return getField(Fields.LEGAL_VALUES, Set.class);
+   }
+
+   /**
+    * Get the minimum value
+    * 
+    * @return the minimum value
+    */
+   public MetaValue getMinimumValue()
+   {
+      return getField(Fields.MINIMUM_VALUE, MetaValue.class);
+   }
+
+   /**
+    * Get the miximum value
+    * 
+    * @return the maximum value
+    */
+   public MetaValue getMaximumValue()
+   {
+      return getField(Fields.MAXIMUM_VALUE, MetaValue.class);
+   }
+
+   /**
+    * Check whether this is a valid value
+    * 
+    * @param value the value
+    * @return null for a valid value, an error message otherwise
+    */
+   public String checkValidValue(Serializable value)
+   {
+      // TODO check min/max/etc.
+      return null;
+   }
+   
+   /**
+    * Whether the property is mandatory
+    * 
+    * @return true when mandatory
+    */
+   public boolean isMandatory()
+   {
+      Boolean result = getField(Fields.MANDATORY, Boolean.class);
+      if (result == null)
+         return false;
+      return result.booleanValue();
+   }
+
+   @Override
+   public String toString()
+   {
+      return "ManagedProperty{" + name + "}"; 
+   }
+
+   @Override
+   public int hashCode()
+   {
+      return name.hashCode(); 
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null || obj instanceof ManagedProperty == false)
+         return false;
+      
+      ManagedProperty other = (ManagedProperty) obj;
+      return name.equals(other.getName());
+   }
+   
+   /**
+    * Create a new ManagedProperty.
+    * 
+    * @param fields the fields
+    * @throws IllegalArgumentException for null fields
+    */
+   private void init(Fields fields)
+   {
+      if (fields == null)
+         throw new IllegalArgumentException("Null fields");
+      this.fields = fields;
+      
+      name = getField(Fields.NAME, String.class);
+      if (name == null)
+         throw new IllegalArgumentException("No " + Fields.NAME + " in fields");
+   }
+
+   private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
+   {
+      ObjectInputStream.GetField getField = in.readFields();
+      Fields fields = (Fields) getField.get("fields", null);
+      try
+      {
+         init(fields);
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Error deserializing managed property", e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDOMFields.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDOMFields.java	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDOMFields.java	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,105 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.mock;
+
+import java.io.Serializable;
+
+import org.jboss.managed.api.Fields;
+import org.w3c.dom.Element;
+import org.w3c.dom.NodeList;
+
+/**
+ * DOMFields.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockDOMFields implements Fields
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   /** The datasource element */
+   private Element element; 
+   
+   /** The element name */
+   private String elementName;
+   
+   /**
+    * Create a new DOMFields.
+    *
+    * @param element the data source element
+    * @param elementName the element name
+    */
+   public MockDOMFields(Element element, String elementName)
+   {
+      this.element = element;
+      this.elementName = elementName;
+   }
+   
+   public Serializable getField(String name)
+   {
+      if (NAME.equals(name))
+         return elementName;
+      if (VALUE.equals(name))
+      {
+         NodeList nodes = element.getElementsByTagName(elementName);
+         if (nodes.getLength() == 0)
+            return null;
+         else
+         {
+            Element element = (Element) nodes.item(0);
+            return element.getTextContent();
+         }
+      }
+      return null;
+   }
+
+   public void setField(String name, Serializable value)
+   {
+      if (VALUE.equals(name))
+      {
+         String string = (String) value;
+         NodeList nodes = element.getElementsByTagName(elementName);
+         Element childElement = null;
+         if (nodes.getLength() == 0)
+         {
+            if (string == null || string.length() == 0)
+               return;
+            childElement = element.getOwnerDocument().createElement(elementName);
+            element.appendChild(childElement);
+         }
+         else
+         {
+            childElement = (Element) nodes.item(0);
+            if (string == null || string.length() == 0)
+            {
+               element.removeChild(childElement);
+               return;
+            }
+         }
+         childElement.setTextContent(string);
+         return;
+      }
+      throw new UnsupportedOperationException("setField " + name);
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDataSourceManagedObject.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDataSourceManagedObject.java	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDataSourceManagedObject.java	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,88 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.mock;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.managed.api.ManagedProperty;
+import org.jboss.util.xml.DOMWriter;
+import org.w3c.dom.DOMImplementation;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+
+/**
+ * MockDataSourceManagedObject.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockDataSourceManagedObject extends ManagedObject
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   /** The document */
+   private Document document;
+   
+   /**
+    * Create a new MockDataSourceManagedObject.
+    */
+   public MockDataSourceManagedObject()
+   {
+      super(new HashSet<ManagedProperty>());
+      Element element;
+      try
+      {
+         DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
+         DocumentBuilder builder = factory.newDocumentBuilder();
+         DOMImplementation impl = builder.getDOMImplementation();
+         document = impl.createDocument(null, null, null);
+         
+         element = document.createElement("data-source");
+         document.appendChild(element);
+      }
+      catch (RuntimeException e)
+      {
+         throw e;
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Error creating dom", e);
+      }
+      
+      Set<ManagedProperty> properties = getManagedProperties();
+      properties.add(new ManagedProperty(new MockDOMFields(element, "jndi-name")));
+      properties.add(new ManagedProperty(new MockDOMFields(element, "connection-url")));
+      properties.add(new ManagedProperty(new MockDOMFields(element, "user")));
+      properties.add(new ManagedProperty(new MockDOMFields(element, "password")));
+   }
+   
+   public String prettyPrint()
+   {
+      return DOMWriter.printNode(document, true);
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/Test.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/Test.java	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/Test.java	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1,59 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.mock;
+
+/**
+ * Test.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class Test
+{
+   public static void main(String[] args) throws Exception
+   {
+      MockDataSourceManagedObject mo = new MockDataSourceManagedObject();
+
+      System.out.println("MockDataSourceManagedObject, available propertes...\n");
+      System.out.println(mo.getPropertyNames());
+
+      System.out.println("\nInitial MetaData...\n");
+      System.out.println(mo.prettyPrint());
+      
+      System.out.println("\nAdding jndi-name...\n");
+      mo.getProperty("jndi-name").setValue("DefaultDS");
+      System.out.println(mo.prettyPrint());
+
+      System.out.println("\nAdding user and password...\n");
+      mo.getProperty("user").setValue("Scott");
+      mo.getProperty("password").setValue("Tiger");
+      System.out.println(mo.prettyPrint());
+
+      System.out.println("\nChanging jndi-name...\n");
+      mo.getProperty("jndi-name").setValue("ChangedDS");
+      System.out.println(mo.prettyPrint());
+
+      System.out.println("\nRemoving jndi-name...\n");
+      mo.getProperty("jndi-name").setValue(null);
+      System.out.println(mo.prettyPrint());
+   }
+}

Added: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty	2006-12-19 13:01:12 UTC (rev 59139)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty	2006-12-19 13:02:07 UTC (rev 59140)
@@ -0,0 +1 @@
+empty
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 08:02:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 08:02:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r59141 -
	projects/microcontainer/trunk/build
Message-ID: <E1GwecM-0002FK-AV@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-19 08:02:48 -0500 (Tue, 19 Dec 2006)
New Revision: 59141

Modified:
   projects/microcontainer/trunk/build/build.xml
Log:
Include metatype and managed

Modified: projects/microcontainer/trunk/build/build.xml
===================================================================
--- projects/microcontainer/trunk/build/build.xml	2006-12-19 13:02:07 UTC (rev 59140)
+++ projects/microcontainer/trunk/build/build.xml	2006-12-19 13:02:48 UTC (rev 59141)
@@ -81,6 +81,8 @@
       <module name="deployers"/>
       <module name="kernel"/>
       <module name="aop-mc-int"/>
+      <module name="metatype"/>
+      <module name="managed"/>
       <module name="osgi-int"/>
 
       <!-- Module groups -->
@@ -93,7 +95,7 @@
       </group>
 
       <group name="core">
-        <include modules="container, dependency, kernel, aop-mc-int, deployers, osgi-int"/>
+        <include modules="container, dependency, kernel, aop-mc-int, deployers, metatype, managed, osgi-int"/>
       </group>
 
       <group name="default">



From sdag98rew4as at fastermail.com  Tue Dec 19 08:04:37 2006
From: sdag98rew4as at fastermail.com (sdag98rew4as at fastermail.com)
Date: Tue, 19 Dec 2006 08:04:37 -0500
Subject: [jboss-cvs] =?utf-8?b?wo7CkcKLw6DCgsOMwpdwwojDk8KCwqrCj2/Cl8KI?=
	=?utf-8?b?woLDnMKCwrXCgsK9woFCwoLCscKCw6rCgsKpwoLDp8KTbsKCwrXCgsK9?=
	=?utf-8?b?woLCosKCw4zCgsOFwoLCt8KCwqrCgUI=?=
Message-ID: 20061219220340.68639mail@mail.oaisudahsuejshausjanjhjajsiasjaja.com

???[?????????????????????????B
?????????????????p???????????B
???????????????????????????Z?????????????H
???????????????????z?????????????????????|???????A???????????????????????c?B
?????????????????????s?????????????????????H
???????????????????????????????v???????B
http://www.allfree.okusamameet.com.perpl.com/Celeb/
?????A?h???X???v???????????????????????[???????????????????v?????????????B
???????????????v???????B



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 08:06:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 08:06:14 -0500
Subject: [jboss-cvs] JBossAS SVN: r59142 -
	projects/microcontainer/trunk/tools/etc/buildmagic
Message-ID: <E1Gwefe-0002IU-Q3@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-19 08:06:13 -0500 (Tue, 19 Dec 2006)
New Revision: 59142

Modified:
   projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent
Log:
Include metatype and managed

Modified: projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent
===================================================================
--- projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent	2006-12-19 13:02:48 UTC (rev 59141)
+++ projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent	2006-12-19 13:06:13 UTC (rev 59142)
@@ -66,6 +66,16 @@
       <include name="jboss-aop-mc-int14.jar"/>
    </fileset>
 </path>
+
+<!-- metatype -->
+<property name="jboss.metatype.root" value="${project.root}/metatype"/>
+<property name="jboss.metatype.lib" value="${jboss.metatype.root}/output/lib"/>
+<path id="jboss.metatype.classpath">
+   <fileset dir="${jboss.metatype.lib}">
+      <include name="jboss-metatype.jar"/>
+   </fileset>
+</path>
+
 <!-- spring-int -->
 <property name="jboss.spring-int.root" value="${project.root}/spring-int"/>
 <property name="jboss.spring-int.lib" value="${jboss.spring-int.root}/output/lib"/>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 08:40:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 08:40:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r59143 -
	projects/aop/trunk/aop/src/main/org/jboss/aop
Message-ID: <E1GwfD2-0002oM-UH@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 08:40:42 -0500 (Tue, 19 Dec 2006)
New Revision: 59143

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java
Log:
Unused imports

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java	2006-12-19 13:06:13 UTC (rev 59142)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java	2006-12-19 13:40:42 UTC (rev 59143)
@@ -21,13 +21,11 @@
 */
 package org.jboss.aop;
 
-import java.util.Map;
 
 import org.jboss.aop.classpool.AOPClassPool;
 import org.jboss.aop.instrument.Instrumentor;
 import org.jboss.aop.instrument.InstrumentorFactory;
 
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
 import javassist.ByteArrayClassPath;
 import javassist.ClassPool;
 import javassist.CtClass;



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 08:42:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 08:42:44 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59144 - projects/aop/trunk/aop
Message-ID: <E1GwfEy-0002rM-A7@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 08:42:42 -0500 (Tue, 19 Dec 2006)
New Revision: 59144

Modified:
   projects/aop/trunk/aop/.classpath
   projects/aop/trunk/aop/build-tests-jdk50.xml
Log:
[JBAOP-287] include the microcontainer jars in the test classpath again since the metadata is more tightly integrated now

Modified: projects/aop/trunk/aop/.classpath
===================================================================
--- projects/aop/trunk/aop/.classpath	2006-12-19 13:40:42 UTC (rev 59143)
+++ projects/aop/trunk/aop/.classpath	2006-12-19 13:42:42 UTC (rev 59144)
@@ -1,7 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
-	<classpathentry excluding="org/jboss/aop/AnnotationIntroductionDef.java|org/jboss/aop/Aspect.java|org/jboss/aop/Bind.java|org/jboss/aop/CFlowDef.java|org/jboss/aop/CFlowStackDef.java|org/jboss/aop/DeclareError.java|org/jboss/aop/DeclareWarning.java|org/jboss/aop/DynamicCFlowDef.java|org/jboss/aop/InterceptorDef.java|org/jboss/aop/Introduction.java|org/jboss/aop/Mixin.java|org/jboss/aop/PointcutDef.java|org/jboss/aop/Precedence.java|org/jboss/aop/PrecedenceAdvice.java|org/jboss/aop/PrecedenceInterceptor.java|org/jboss/aop/Prepare.java|org/jboss/aop/TypeDef.java|org/jboss/aop/advice/Scope.java|org/jboss/aop/annotation/AnnotationElement.java|org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java|org/jboss/aspects/Threadbased.java" kind="src" path="src/main"/>
-	<classpathentry kind="src" path="src/jdk15"/>
+	<classpathentry excluding="org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java" kind="src" path="src/main"/>
 	<classpathentry kind="src" path="src/test"/>
 	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
@@ -14,7 +13,7 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
-	<classpathentry sourcepath="/javassist" kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar" sourcepath="/javassist"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>

Modified: projects/aop/trunk/aop/build-tests-jdk50.xml
===================================================================
--- projects/aop/trunk/aop/build-tests-jdk50.xml	2006-12-19 13:40:42 UTC (rev 59143)
+++ projects/aop/trunk/aop/build-tests-jdk50.xml	2006-12-19 13:42:42 UTC (rev 59144)
@@ -86,9 +86,9 @@
          <path refid="jboss/common.logging.log4j.classpath"/>
          <path refid="jboss/common.logging.jdk.classpath"/>
          <path refid="jboss/common.logging.spi.classpath"/>
-         <!--<path refid="jboss.microcontainer.classpath"/>-->
+         <path refid="jboss.microcontainer.classpath"/>
          <path refid="jboss.test.classpath"/>
-          <path refid="junit.junit.classpath"/>
+         <path refid="junit.junit.classpath"/>
          <path refid="oswego.concurrent.classpath"/>
          <path refid="qdox.classpath"/>
          <path refid="trove.classpath"/>
@@ -211,7 +211,6 @@
          <classpath refid="test.classpath"/>
          <include name="**/*.java"/>
          <exclude name="org/jboss/test/aop/memoryleaks/**/*.java"/>
-         <exclude name="**/methodhashing/*"/>
       </javac>
    </target>
 
@@ -405,6 +404,7 @@
          <sysproperty key="jboss.aop.class.path" value="${jboss.aop.class.path}"/>
          <sysproperty key="jboss.aop.instrumentor" value="${instrumentor}"/>
          <sysproperty key="jboss.aop.debug.classes" value="true"/>
+         <!--sysproperty key="jboss.aop.verbose" value="true"/-->
          <sysproperty key="jboss-junit-configuration" value="${caller}"/>
       	<formatter type="plain" extension="-${caller}.txt"/>
       	<classpath refid="test.classpath"/>
@@ -667,8 +667,6 @@
          <src path="${source.tests.java}/org/jboss/test/aop/annotationc"/>
       </annotationc>
 
-      <echo>org/jboss/test/aop/methodhashing/MethodHashingTestCase will fail until the microcontainer has been updated in the repository</echo>
-
       <junit printsummary="yes" fork="no" haltonfailure="no" >
          <sysproperty key="jboss.aop.debug.classes" value="false"/>
          <classpath>



From ian.springer at jboss.com  Tue Dec 19 09:05:42 2006
From: ian.springer at jboss.com (Ian Springer)
Date: Tue, 19 Dec 2006 09:05:42 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA -
	New directory ...
Message-ID: <E1GwfbC-0003Nr-Hc@committer01.frg.pub.inap.atl.jboss.com>

  User: ispringer
  Date: 06/12/19 09:05:42

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA added to the repository


From ian.springer at jboss.com  Tue Dec 19 09:05:49 2006
From: ian.springer at jboss.com (Ian Springer)
Date: Tue, 19 Dec 2006 09:05:49 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA -
	New directory ...
Message-ID: <E1GwfbJ-0003OS-53@committer01.frg.pub.inap.atl.jboss.com>

  User: ispringer
  Date: 06/12/19 09:05:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA added to the repository


From ian.springer at jboss.com  Tue Dec 19 09:05:55 2006
From: ian.springer at jboss.com (Ian Springer)
Date: Tue, 19 Dec 2006 09:05:55 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA
	- New directory ...
Message-ID: <E1GwfbP-0003P3-4L@committer01.frg.pub.inap.atl.jboss.com>

  User: ispringer
  Date: 06/12/19 09:05:55

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA added to the repository


From ian.springer at jboss.com  Tue Dec 19 09:07:25 2006
From: ian.springer at jboss.com (Ian Springer)
Date: Tue, 19 Dec 2006 09:07:25 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA ...
Message-ID: <E1Gwfcr-0003Q1-3V@committer01.frg.pub.inap.atl.jboss.com>

  User: ispringer
  Date: 06/12/19 09:07:25

  Added:       maven2/jboss/jboss-seam-debug/1.1.0.GA      
                        jboss-seam-debug-1.1.0.GA.jar
                        jboss-seam-debug-1.1.0.GA.jar.md5
                        jboss-seam-debug-1.1.0.GA.jar.sha1
                        jboss-seam-debug-1.1.0.GA.pom
                        jboss-seam-debug-1.1.0.GA.pom.md5
                        jboss-seam-debug-1.1.0.GA.pom.sha1
  Log:
  Seam 1.1 GA jars & Maven 2 poms
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 14:07:25;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 14:07:25;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.jar.md5
  
  Index: jboss-seam-debug-1.1.0.GA.jar.md5
  ===================================================================
  1c905410cf2be9c5a2490930bc98a183
  
  
  1.1      date: 2006/12/19 14:07:25;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.jar.sha1
  
  Index: jboss-seam-debug-1.1.0.GA.jar.sha1
  ===================================================================
  9fa6f4078a6b471a46acc112dc41b2827e497a19
  
  
  1.1      date: 2006/12/19 14:07:25;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.pom
  
  Index: jboss-seam-debug-1.1.0.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-seam</artifactId>
    <name>JBoss Seam Debug</name>
    <version>1.1.0.GA</version>
    <description>JBoss Seam is a powerful new application framework to build next generation Web 2.0 applications by unifying and integrating technologies such as Asynchronous JavaScript and XML (AJAX), Java Server Faces (JSF), Enterprise Java Beans (EJB3), Java Portlets and Business Process Management (BPM).</description>
    <url>http://www.jboss.org/products/seam</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/19 14:07:25;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.pom.md5
  
  Index: jboss-seam-debug-1.1.0.GA.pom.md5
  ===================================================================
  9017d11d70c6d1d74c2e5f0dc3d40e1e
  
  
  1.1      date: 2006/12/19 14:07:25;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.pom.sha1
  
  Index: jboss-seam-debug-1.1.0.GA.pom.sha1
  ===================================================================
  8ac0c3d5dbcb19287993e6bb107fe5836642a8fc
  
  


From ian.springer at jboss.com  Tue Dec 19 09:07:28 2006
From: ian.springer at jboss.com (Ian Springer)
Date: Tue, 19 Dec 2006 09:07:28 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA
	...
Message-ID: <E1Gwfcu-0003QS-VR@committer01.frg.pub.inap.atl.jboss.com>

  User: ispringer
  Date: 06/12/19 09:07:28

  Added:       maven2/jboss/jboss-seam-ui/1.1.0.GA      
                        jboss-seam-ui-1.1.0.GA.jar
                        jboss-seam-ui-1.1.0.GA.jar.md5
                        jboss-seam-ui-1.1.0.GA.jar.sha1
                        jboss-seam-ui-1.1.0.GA.pom
                        jboss-seam-ui-1.1.0.GA.pom.md5
                        jboss-seam-ui-1.1.0.GA.pom.sha1
  Log:
  Seam 1.1 GA jars & Maven 2 poms
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 14:07:28;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 14:07:28;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.jar.md5
  
  Index: jboss-seam-ui-1.1.0.GA.jar.md5
  ===================================================================
  18ed49e61db289738d426cf61f120f22
  
  
  1.1      date: 2006/12/19 14:07:28;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.jar.sha1
  
  Index: jboss-seam-ui-1.1.0.GA.jar.sha1
  ===================================================================
  acb6850a8f8cde7a02df1cf846916b61d2897e60
  
  
  1.1      date: 2006/12/19 14:07:28;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.pom
  
  Index: jboss-seam-ui-1.1.0.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-seam</artifactId>
    <name>JBoss Seam UI</name>
    <version>1.1.0.GA</version>
    <description>JBoss Seam is a powerful new application framework to build next generation Web 2.0 applications by unifying and integrating technologies such as Asynchronous JavaScript and XML (AJAX), Java Server Faces (JSF), Enterprise Java Beans (EJB3), Java Portlets and Business Process Management (BPM).</description>
    <url>http://www.jboss.org/products/seam</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/19 14:07:28;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.pom.md5
  
  Index: jboss-seam-ui-1.1.0.GA.pom.md5
  ===================================================================
  f60eca52f54f7392789b58ed8f8003d2
  
  
  1.1      date: 2006/12/19 14:07:28;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.pom.sha1
  
  Index: jboss-seam-ui-1.1.0.GA.pom.sha1
  ===================================================================
  20f75a12d0ea31aa7a8456a9e339925d4f537973
  
  


From ian.springer at jboss.com  Tue Dec 19 09:07:47 2006
From: ian.springer at jboss.com (Ian Springer)
Date: Tue, 19 Dec 2006 09:07:47 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA ...
Message-ID: <E1GwfdD-0003Qt-Nt@committer01.frg.pub.inap.atl.jboss.com>

  User: ispringer
  Date: 06/12/19 09:07:47

  Added:       maven2/jboss/jboss-seam/1.1.0.GA      
                        jboss-seam-1.1.0.GA.jar jboss-seam-1.1.0.GA.jar.md5
                        jboss-seam-1.1.0.GA.jar.sha1
                        jboss-seam-1.1.0.GA.pom jboss-seam-1.1.0.GA.pom.md5
                        jboss-seam-1.1.0.GA.pom.sha1
  Log:
  Seam 1.1 GA jars & Maven 2 poms
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 14:07:47;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 14:07:47;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.jar.md5
  
  Index: jboss-seam-1.1.0.GA.jar.md5
  ===================================================================
  6feae01ea261a32b319ce5b2bdf4b82c
  
  
  1.1      date: 2006/12/19 14:07:47;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.jar.sha1
  
  Index: jboss-seam-1.1.0.GA.jar.sha1
  ===================================================================
  9ba771b634c5c847e34879330c21042b822bbd0b
  
  
  1.1      date: 2006/12/19 14:07:47;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.pom
  
  Index: jboss-seam-1.1.0.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-seam</artifactId>
    <name>JBoss Seam</name>
    <version>1.1.0.GA</version>
    <description>JBoss Seam is a powerful new application framework to build next generation Web 2.0 applications by unifying and integrating technologies such as Asynchronous JavaScript and XML (AJAX), Java Server Faces (JSF), Enterprise Java Beans (EJB3), Java Portlets and Business Process Management (BPM).</description>
    <url>http://www.jboss.org/products/seam</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/19 14:07:47;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.pom.md5
  
  Index: jboss-seam-1.1.0.GA.pom.md5
  ===================================================================
  b2c82e346e4bdd9c80eb54a356071441
  
  
  1.1      date: 2006/12/19 14:07:47;  author: ispringer;  state: Exp;repository.jboss.com/maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.pom.sha1
  
  Index: jboss-seam-1.1.0.GA.pom.sha1
  ===================================================================
  40c19f0f7059bedf3101ce506f60bec36db91bae
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 09:12:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 09:12:24 -0500
Subject: [jboss-cvs] JBossAS SVN: r59145 -
	projects/microcontainer/trunk/osgi-int
Message-ID: <E1Gwfhg-0003WL-Ba@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-19 09:12:21 -0500 (Tue, 19 Dec 2006)
New Revision: 59145

Modified:
   projects/microcontainer/trunk/osgi-int/build-test.xml
Log:
copy paste typo

Modified: projects/microcontainer/trunk/osgi-int/build-test.xml
===================================================================
--- projects/microcontainer/trunk/osgi-int/build-test.xml	2006-12-19 13:42:42 UTC (rev 59144)
+++ projects/microcontainer/trunk/osgi-int/build-test.xml	2006-12-19 14:12:21 UTC (rev 59145)
@@ -16,7 +16,7 @@
 
 <!-- $Id: build-test.xml 55205 2006-08-04 16:46:15Z kabir.khan at jboss.com $ -->
 
-<project default="main" name="JBoss/Container Tests">
+<project default="main" name="JBoss/OSGi Tests">
 
   <!-- ================================================================== -->
   <!-- Setup                                                              -->



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 09:37:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 09:37:58 -0500
Subject: [jboss-cvs] JBossAS SVN: r59146 - in
	projects/microcontainer/trunk/spring-int: .
	src/tests/org/jboss/test/spring/test
Message-ID: <E1Gwg6Q-0003tW-Ax@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-19 09:37:54 -0500 (Tue, 19 Dec 2006)
New Revision: 59146

Added:
   projects/microcontainer/trunk/spring-int/.classpath
   projects/microcontainer/trunk/spring-int/.project
Removed:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java
Log:
Fix the eclipse build and remove the bogus class with an uppercase I in
MIcrocontainer

Added: projects/microcontainer/trunk/spring-int/.classpath
===================================================================
--- projects/microcontainer/trunk/spring-int/.classpath	2006-12-19 14:12:21 UTC (rev 59145)
+++ projects/microcontainer/trunk/spring-int/.classpath	2006-12-19 14:37:54 UTC (rev 59146)
@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry kind="src" path="src/main"/>
+	<classpathentry kind="src" path="src/tests"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/container"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/dependency"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/kernel"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/resolver.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/xercesImpl.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-xerces/lib/xml-apis.jar"/>
+	<classpathentry kind="output" path="output/eclipse-classes"/>
+</classpath>

Added: projects/microcontainer/trunk/spring-int/.project
===================================================================
--- projects/microcontainer/trunk/spring-int/.project	2006-12-19 14:12:21 UTC (rev 59145)
+++ projects/microcontainer/trunk/spring-int/.project	2006-12-19 14:37:54 UTC (rev 59146)
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<projectDescription>
+	<name>spring-int</name>
+	<comment></comment>
+	<projects>
+	</projects>
+	<buildSpec>
+		<buildCommand>
+			<name>org.eclipse.jdt.core.javabuilder</name>
+			<arguments>
+			</arguments>
+		</buildCommand>
+	</buildSpec>
+	<natures>
+		<nature>org.eclipse.jdt.core.javanature</nature>
+	</natures>
+</projectDescription>

Deleted: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java	2006-12-19 14:12:21 UTC (rev 59145)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMIcrocontainerTest.java	2006-12-19 14:37:54 UTC (rev 59146)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.test.spring.test;
-
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.kernel.junit.MicrocontainerTest;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- */
-public class TempSpringMicrocontainerTest extends MicrocontainerTest
-{
-
-   public TempSpringMicrocontainerTest(String name)
-   {
-      super(name);
-   }
-
-   /**
-    * Setup the test delegate
-    *
-    * @param clazz the class
-    * @return the delegate
-    * @throws Exception for any error
-    */
-   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
-   {
-      return new TempSpringMicrocontainerTestDelegate(clazz);
-   }
-
-}



From msurtani at jboss.com  Tue Dec 19 09:43:24 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 09:43:24 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache  ...
Message-ID: <E1GwgBg-0003zF-Dg@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 09:43:24

  Modified:    tests/stress/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        BuddyReplicationStressTest.java
  Log:
  Removed dependency on a Java5 class
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.6.2.3   +117 -3    JBossCache/tests/stress/org/jboss/cache/Attic/BuddyReplicationStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/Attic/BuddyReplicationStressTest.java,v
  retrieving revision 1.6.2.2
  retrieving revision 1.6.2.3
  diff -u -b -r1.6.2.2 -r1.6.2.3
  --- BuddyReplicationStressTest.java	10 Nov 2006 20:03:34 -0000	1.6.2.2
  +++ BuddyReplicationStressTest.java	19 Dec 2006 14:43:24 -0000	1.6.2.3
  @@ -15,7 +15,6 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Random;
  -import java.util.UUID;
   
   /**
    * Stress test for buddy replication to try and detect deadlocks.
  @@ -110,7 +109,8 @@
   
         public synchronized String getSession()
         {
  -         return UUID.randomUUID().toString();
  +
  +         return UUIDGenerator.getRandomUUID();
         }
      }
   
  @@ -238,7 +238,7 @@
   
      public void testNothing()
      {
  -      assertTrue(true); // disabled from automated test runs
  +      assertTrue(true); // do nothing, should not be run in cruise control
      }
   
      private int getRandomSleep()
  @@ -248,3 +248,117 @@
         return sleep;
      }
   }
  +
  +class UUIDGenerator
  +{
  +   private static List uuids = new ArrayList();
  +   private static Random r = new Random();
  +   static
  +   {
  +      uuids.add("560ea1d6-d3c2-409b-a358-4d6c7c450ba7");
  +      uuids.add("bed3844a-dc52-408b-94e9-64e7787f35e4");
  +      uuids.add("d59fcf53-00f7-456b-a817-1e64b5231e07");
  +      uuids.add("b5f5f6f2-4d82-4508-9daf-82f425101238");
  +      uuids.add("64936e40-950f-4bfd-9f0b-fe7b4dd95747");
  +      uuids.add("c95dcff4-f061-4809-b5de-5dd1908f471b");
  +      uuids.add("5d86509a-efec-4183-b3e2-746b7beeba13");
  +      uuids.add("1ffb2418-759a-4ef2-b3c0-51639276fe90");
  +      uuids.add("707a9c18-7e1b-404a-9eb3-6f9b5f30ccb7");
  +      uuids.add("00dff929-eadf-4d71-913c-7b560417bcb1");
  +      uuids.add("75353c75-7074-432e-bd2b-75a0ff222735");
  +      uuids.add("cfb5a497-33da-4d00-8b7a-39bc0c0104f9");
  +      uuids.add("c46b3382-cdf8-4d6d-8abe-22f53cf90860");
  +      uuids.add("b1c923b9-ed80-4bef-b8fc-59cf351acb17");
  +      uuids.add("6b6da8d5-862d-4010-a706-aad1ee79b6f2");
  +      uuids.add("f3a71142-59fc-4165-9a33-d4d480cef4bb");
  +      uuids.add("e8495312-a3ba-4610-8b11-3a425a27fa6f");
  +      uuids.add("a64c139d-2970-469d-8c8e-6415a0d20443");
  +      uuids.add("ba4d28b9-e652-42e9-841a-da7fb1648c41");
  +      uuids.add("d09e2ab1-74dc-430a-a3aa-4313b551bb97");
  +      uuids.add("2e9e326c-39ba-493f-a918-468a2ff81553");
  +      uuids.add("056cde88-329f-4d7d-957b-9fd7fb8d5242");
  +      uuids.add("624aa14e-ec90-4d4a-bd1b-4a46df6b7328");
  +      uuids.add("1958b764-1077-4b9c-9884-707dc530e7e0");
  +      uuids.add("432d508c-3e95-48d5-ae85-6825aeafe4ae");
  +      uuids.add("3712fbea-a218-4309-94c2-923de7f3e3e1");
  +      uuids.add("cf4ab42f-0323-49a8-8238-230c3ac4180a");
  +      uuids.add("82e1ecdd-2ddf-4fb4-9883-eabfe219b91d");
  +      uuids.add("d7d360f3-4576-4291-bfc6-aa1645dbff88");
  +      uuids.add("803ed2e9-8131-4801-9c26-2f403bb2b866");
  +      uuids.add("295d6b05-2069-42e0-8b47-782088becb12");
  +      uuids.add("65849b2d-8a64-4b6c-98e1-9997d2a06404");
  +      uuids.add("52232355-d790-42ef-9e82-d005f33b18bb");
  +      uuids.add("d1fc926c-c8fa-4b36-88c2-f323dd123358");
  +      uuids.add("d09188f6-907d-4a6f-930d-cbf363e27d6c");
  +      uuids.add("a6ad0287-e877-4cec-8566-a8dfd9156dda");
  +      uuids.add("a6e97a6f-b382-455d-8984-b1419ada6c83");
  +      uuids.add("993ca2b2-917d-4764-9814-2934ab27ebf4");
  +      uuids.add("6603d650-a03f-450d-9172-22965f0dbec2");
  +      uuids.add("850270ed-58cd-4a4d-8866-c9478d0c8e26");
  +      uuids.add("c4232601-9579-4b8d-8edd-2623c0985e5d");
  +      uuids.add("d760d9db-2f4c-45eb-9b77-93218795c490");
  +      uuids.add("50592596-675b-4f63-b20e-10ed8bf1177b");
  +      uuids.add("64ead256-7330-4afe-862d-9eae6241f59b");
  +      uuids.add("b70579f8-9e5f-411d-bbbf-07e2966af2b5");
  +      uuids.add("8c8377a5-7f23-4bc6-918b-008ee8e03baf");
  +      uuids.add("c832c342-1bcc-4e14-bef7-459f90afcf06");
  +      uuids.add("7c1d777e-d2ab-4ab4-9d2c-5e4705d06441");
  +      uuids.add("047a60b8-350a-4ded-8094-4996b4aa0eae");
  +      uuids.add("b2b167b8-98fc-4406-a62b-f694def42814");
  +      uuids.add("447312be-605d-4b85-a05b-9290fa8f04be");
  +      uuids.add("3b0e01d7-fe75-49f2-b9f6-c091f44e8fd3");
  +      uuids.add("78bc553b-b034-4296-a536-457d64d9c2e1");
  +      uuids.add("113f6054-cd3d-471f-972d-f57994a7e144");
  +      uuids.add("84e55627-8869-4512-a57c-01c71065e060");
  +      uuids.add("9f6b3a55-65b8-4a59-ab43-85b89e16c9b1");
  +      uuids.add("aa1e25ea-6a71-417a-8929-3103731c0ff3");
  +      uuids.add("de1e2439-ab37-4815-bdf8-ecc3b68f7460");
  +      uuids.add("7403a1a2-d37e-4461-8a23-ec9d9c3d1ff4");
  +      uuids.add("ca0e0ea8-848d-4241-890f-773742fdd28e");
  +      uuids.add("d5ff545a-bb57-4747-8813-58dff5704aaf");
  +      uuids.add("408ef6f5-59c2-4d7e-90b7-e33146eb08b8");
  +      uuids.add("219b321e-688f-44c2-9cfa-55fcffec0fe9");
  +      uuids.add("e8362302-0c99-4fad-8bb0-19064eae3826");
  +      uuids.add("85da5e60-38c1-4663-9b02-4990101f1721");
  +      uuids.add("c5cc78c8-31d3-4508-bf43-fe0b23d121e9");
  +      uuids.add("934f0fa6-b778-4eba-9e21-f49c776f66d2");
  +      uuids.add("3cba764a-61d5-44c0-a95b-3d0dfd7163d1");
  +      uuids.add("e25e7d3e-fa84-4130-a66f-2623583baa71");
  +      uuids.add("4cf1283f-5894-4b8f-8e5b-79bd8b84a573");
  +      uuids.add("795b40c6-327c-4142-90ce-ab6a57e4cdba");
  +      uuids.add("37aaf8c5-6754-407a-a140-e83f4365f609");
  +      uuids.add("649121cf-ac57-4b89-be34-2d5616f791ae");
  +      uuids.add("4e11ad91-436a-4b91-99a5-d17f5f3fdf80");
  +      uuids.add("562ce0c2-6184-412d-9750-eef5577d3e8b");
  +      uuids.add("b5fab0fc-04a1-44ef-8c52-61dffc2302ea");
  +      uuids.add("cb424bbc-77c2-4219-92c3-fefac58220b5");
  +      uuids.add("a631f37d-8761-49f3-abed-2655186703dc");
  +      uuids.add("7e650ffc-0418-4b6c-9057-aa026d2caf06");
  +      uuids.add("fcf2f2d8-4a43-4ad3-9fbe-4fb1b220a411");
  +      uuids.add("d4d66033-5c8d-4b0b-856e-e5937669aa89");
  +      uuids.add("c85e18b5-2dfe-4f98-a532-3396f67f2556");
  +      uuids.add("1cd53a18-5d01-464a-bedd-098e86ba910b");
  +      uuids.add("8588a619-03e5-4d27-a30b-b883a71acde5");
  +      uuids.add("2f77bc44-ced1-4389-a1d1-ee27e151d48d");
  +      uuids.add("48b0d50e-db29-4e33-9ee5-9701147503d2");
  +      uuids.add("8a41f6da-23d6-47d9-9037-f1773a10419b");
  +      uuids.add("5990c525-7a77-4639-bfd6-ebf2f67167e1");
  +      uuids.add("2a6a0dfe-4348-4ca4-b433-666c77457218");
  +      uuids.add("142087db-d88c-48cd-9731-56aee756b51f");
  +      uuids.add("63bf705b-40f3-406f-ac00-cf8ad42ce3a5");
  +      uuids.add("fb9ceb15-d7c1-4202-bd60-e50b9242b6d0");
  +      uuids.add("16a21b7d-ba39-439c-ab08-0b1967a45cb5");
  +      uuids.add("7b5a52cb-cb49-4459-9e23-4bd22e5ac49a");
  +      uuids.add("26dac214-bd72-40d8-97a9-b3fefc15a6c1");
  +      uuids.add("576c9dd7-5410-4c92-9e91-c07ff3da0ccd");
  +      uuids.add("16c7fa87-f782-4918-98ae-024b17cfe65e");
  +      uuids.add("0b890234-6c1a-4278-b02f-8a9f580cbb03");
  +      uuids.add("67385a01-18c9-4858-8fb7-76a0ff9346d0");
  +      uuids.add("611f12ad-bf67-426b-8134-3e1e389ffcee");
  +   }
  +
  +   static String getRandomUUID()
  +   {
  +      return (String) uuids.get(r.nextInt(uuids.size()));
  +   }
  +}
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 09:43:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 09:43:40 -0500
Subject: [jboss-cvs] JBossAS SVN: r59147 -
	projects/microcontainer/trunk/spring-int/src/resources/schema
Message-ID: <E1GwgBw-0003zc-8N@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-19 09:43:34 -0500 (Tue, 19 Dec 2006)
New Revision: 59147

Modified:
   projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
Log:
xml.xsd issue

Modified: projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd
===================================================================
--- projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-19 14:37:54 UTC (rev 59146)
+++ projects/microcontainer/trunk/spring-int/src/resources/schema/mc-spring-beans_2_0.xsd	2006-12-19 14:43:34 UTC (rev 59147)
@@ -10,8 +10,6 @@
    version="1.0"
 >
 
-   <xsd:import namespace="http://www.w3.org/XML/1998/namespace"/>
-
    <xsd:annotation>
       <xsd:documentation><![CDATA[
 	Spring XML Beans Schema, version 2.0



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 10:06:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 10:06:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r59148 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GwgXt-0004We-5B@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-19 10:06:17 -0500 (Tue, 19 Dec 2006)
New Revision: 59148

Removed:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java
Log:


Deleted: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java	2006-12-19 14:43:34 UTC (rev 59147)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java	2006-12-19 15:06:17 UTC (rev 59148)
@@ -1,50 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.test.spring.test;
-
-import org.jboss.test.AbstractTestDelegate;
-import org.jboss.test.kernel.junit.MicrocontainerTest;
-
-/**
- * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- */
-public class TempSpringMicrocontainerTest extends MicrocontainerTest
-{
-
-   public TempSpringMicrocontainerTest(String name)
-   {
-      super(name);
-   }
-
-   /**
-    * Setup the test delegate
-    *
-    * @param clazz the class
-    * @return the delegate
-    * @throws Exception for any error
-    */
-   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
-   {
-      return new TempSpringMicrocontainerTestDelegate(clazz);
-   }
-
-}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 10:06:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 10:06:47 -0500
Subject: [jboss-cvs] JBossAS SVN: r59149 -
	projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test
Message-ID: <E1GwgYJ-0004XN-8e@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-19 10:06:45 -0500 (Tue, 19 Dec 2006)
New Revision: 59149

Added:
   projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java
Log:


Added: projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java	2006-12-19 15:06:17 UTC (rev 59148)
+++ projects/microcontainer/trunk/spring-int/src/tests/org/jboss/test/spring/test/TempSpringMicrocontainerTest.java	2006-12-19 15:06:45 UTC (rev 59149)
@@ -0,0 +1,50 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.spring.test;
+
+import org.jboss.test.AbstractTestDelegate;
+import org.jboss.test.kernel.junit.MicrocontainerTest;
+
+/**
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class TempSpringMicrocontainerTest extends MicrocontainerTest
+{
+
+   public TempSpringMicrocontainerTest(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Get the test delegate
+    *
+    * @param clazz the test class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      return new TempSpringMicrocontainerTestDelegate(clazz);
+   }
+
+}



From validimir.ralev at jboss.com  Tue Dec 19 10:10:46 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:10:46 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 -
	New directory ...
Message-ID: <E1GwgcA-0004f8-CL@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:10:46

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 added to the repository


From validimir.ralev at jboss.com  Tue Dec 19 10:10:46 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:10:46 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin
	- New directory ...
Message-ID: <E1GwgcA-0004fC-FK@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:10:46

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin added to the repository


From validimir.ralev at jboss.com  Tue Dec 19 10:10:46 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:10:46 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib
	- New directory ...
Message-ID: <E1GwgcA-0004fH-Jy@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:10:46

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib added to the repository


From validimir.ralev at jboss.com  Tue Dec 19 10:10:46 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:10:46 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources
	- New directory ...
Message-ID: <E1GwgcA-0004fL-Nz@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:10:46

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources added to the repository


From validimir.ralev at jboss.com  Tue Dec 19 10:12:49 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:12:49 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources
	...
Message-ID: <E1Gwge9-0004gp-Rf@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:12:49

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources   
                        ejb3-interceptors-aop.xml
                        ejb3-clustered-sfsbcache-service.xml
                        ejb3-entity-cache-service.xml
  Log:
  renaming the official patch
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 15:12:49;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources/ejb3-interceptors-aop.xml
  
  Index: ejb3-interceptors-aop.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE aop PUBLIC
     "-//JBoss//DTD JBOSS AOP 1.0//EN"
     "http://www.jboss.org/aop/dtd/jboss-aop_1_0.dtd">
  
  <aop>
     <interceptor class="org.jboss.aspects.remoting.InvokeRemoteInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.security.SecurityClientInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.tx.ClientTxPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.remoting.IsLocalInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.aspects.remoting.ClusterChooserInterceptor" scope="PER_VM"/>
  
     <interceptor class="org.jboss.aspects.tx.TxPropagationInterceptor" scope="PER_VM"/>
  
     <stack name="ServiceClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="AsynchronousStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="StatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatelessSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <stack name="ClusteredStatefulSessionClientInterceptors">
        <interceptor-ref name="org.jboss.ejb3.remoting.IsLocalInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.security.SecurityClientInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.tx.ClientTxPropagationInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.ClusterChooserInterceptor"/>
        <interceptor-ref name="org.jboss.aspects.remoting.InvokeRemoteInterceptor"/>
     </stack>
  
     <interceptor class="org.jboss.ejb3.asynchronous.AsynchronousInterceptor" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.ENCPropagationInterceptor" scope="PER_VM"/>
     <interceptor name="Basic Authorization" factory="org.jboss.ejb3.security.RoleBasedAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor name="JACC Authorization" factory="org.jboss.ejb3.security.JaccAuthorizationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.AuthenticationInterceptorFactory" scope="PER_CLASS"/>
     <interceptor factory="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateless.StatelessInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.StatefulInstanceInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.service.ServiceSingletonInterceptor" scope="PER_VM"/>
     <interceptor class="org.jboss.ejb3.cache.StatefulReplicationInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.stateful.StatefulRemoveFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.tx.TxInterceptorFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory" scope="PER_CLASS_JOINPOINT"/>
     <interceptor factory="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.AllowedOperationsInterceptor" scope="PER_VM"/>
     <interceptor factory="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory" scope="PER_CLASS"/>
     <interceptor class="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor" scope="PER_VM"/>
  
     <domain name="Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="JACC Stateless Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Base Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="JACC Stateful Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="JACC Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..))">
           <interceptor-ref name="org.jboss.ejb3.remoting.ReplicantsManagerInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulRemoveFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.StatefulInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
        </bind>
        <bind pointcut="execution(public * $instanceof{javax.ejb.SessionSynchronization}->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateful.SessionSynchronizationInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
  
        <bind pointcut="execution(public * @org.jboss.annotation.ejb.Clustered->*(..)) AND !execution(public * *->@javax.ejb.Remove(..))">
           <interceptor-ref name="org.jboss.ejb3.cache.StatefulReplicationInterceptor"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.ThreadlocalPool.class, maxSize=30, timeout=10000)
        </annotation>
  
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.simple.SimpleStatefulCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.PersistenceManager) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.PersistenceManager (org.jboss.ejb3.cache.simple.StatefulSessionFilePersistenceManager.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.simple.CacheConfig) AND !class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.simple.CacheConfig (maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
  
        <!-- Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.tree.StatefulTreeCache.class)
        </annotation>
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.tree.CacheConfig) AND class(@org.jboss.annotation.ejb.Clustered)">
           @org.jboss.annotation.ejb.cache.tree.CacheConfig (name="jboss.cache:service=EJB3SFSBClusteredCache", maxSize=100000, idleTimeoutSeconds=300)
        </annotation>
     </domain>
  
     <domain name="Embedded Stateful Bean" extends="Base Stateful Bean" inheritBindings="true">
        <!-- NON Clustered cache configuration -->
        <annotation expr="!class(@org.jboss.annotation.ejb.cache.Cache)">
           @org.jboss.annotation.ejb.cache.Cache (org.jboss.ejb3.cache.NoPassivationCache.class)
        </annotation>
  
     </domain>
  
     <domain name="Message Driven Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
     
     <domain name="Consumer Bean">
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.stateless.StatelessInstanceInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND (has(* *->@org.jboss.annotation.ejb.CurrentMessage(..)) OR hasfield(* *->@org.jboss.annotation.ejb.CurrentMessage))">
           <interceptor-ref name="org.jboss.ejb3.mdb.CurrentMessageInjectorInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
        <annotation expr="!class(@org.jboss.annotation.ejb.PoolClass)">
           @org.jboss.annotation.ejb.PoolClass (value=org.jboss.ejb3.StrictMaxPool.class, maxSize=30, timeout=10000)
        </annotation>
     </domain>
  
     <domain name="Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
     <domain name="JACC Service Bean">
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.ejb3.asynchronous.AsynchronousInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.ENCPropagationInterceptor"/>
        </bind>
        <bind pointcut="!execution(* *->create()) AND !execution(* *->start()) AND !execution(*->new(..))">
           <interceptor-ref name="org.jboss.ejb3.security.AuthenticationInterceptorFactory"/>
        </bind>      
        <bind pointcut="execution(public * @org.jboss.annotation.security.SecurityDomain->*(..))">
           <interceptor-ref name="Basic Authorization"/>
        </bind>
        <bind pointcut="execution(public * @javax.annotation.security.RunAs->*(..))">
           <interceptor-ref name="org.jboss.ejb3.security.RunAsSecurityInterceptorFactory"/>
        </bind>
        <bind pointcut="execution(public * *->*(..))">
           <interceptor-ref name="org.jboss.aspects.tx.TxPropagationInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.tx.TxInterceptorFactory"/>
           <interceptor-ref name="org.jboss.ejb3.AllowedOperationsInterceptor"/>
           <interceptor-ref name="org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor"/>
        </bind>
        <bind pointcut="execution(public * *->*(..)) AND !execution(* *->create()) AND !execution(* *->start())">
           <interceptor-ref name="org.jboss.ejb3.interceptor.EJB3InterceptorsFactory"/>
        </bind>
     </domain>
  
  
  </aop>
  
  
  1.1      date: 2006/12/19 15:12:49;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources/ejb3-clustered-sfsbcache-service.xml
  
  Index: ejb3-clustered-sfsbcache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
     <mbean code="org.jboss.ejb3.cache.tree.PassivationTreeCache" name="jboss.cache:service=EJB3SFSBClusteredCache">
     
        <!-- uncomment next three statements if using JGroups multiplexer,
               requires JGroups 2.3 or later, JBossCache 1.4 or later -->
        <!--
        <depends>jgroups.mux:name=Multiplexer</depends>
        <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
        <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
        -->
        
        <!--
                Node locking level : SERIALIZABLE
                                     REPEATABLE_READ (default)
                                     READ_COMMITTED
                                     READ_UNCOMMITTED
                                     NONE
        -->
        <attribute name="IsolationLevel">READ_UNCOMMITTED</attribute>
  
        <!--     Valid modes are LOCAL
                                 REPL_ASYNC
                                 REPL_SYNC
        -->
        <attribute name="CacheMode">REPL_SYNC</attribute>
  
        <attribute name="ClusterName">SFSB-Cache</attribute>
  
        <attribute name="ClusterConfig">
           <config>
              <!-- 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="45551" ip_ttl="${jgroups.mcast.ip_ttl:64}" 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"/>
           </config>
        </attribute>
  
        <!--    Number of milliseconds to wait until all responses for a
                synchronous call have been received.
        -->
        <attribute name="SyncReplTimeout">10000</attribute>
  
        <!--  Max number of milliseconds to wait for a lock acquisition -->
        <attribute name="LockAcquisitionTimeout">15000</attribute>
  
        <!--  Name of the eviction policy class. -->
        <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
        <!--  Specific eviction policy configurations. This is LRU -->
        <attribute name="EvictionPolicyConfig">
           <config>
              <attribute name="wakeUpIntervalSeconds">5</attribute>
              <name>statefulClustered</name>
              <!-- So default region would never timeout -->
              <region name="/_default_">
                 <attribute name="maxNodes">0</attribute>
                 <attribute name="timeToIdleSeconds">0</attribute>
              </region>
  
           </config>
        </attribute>
  
  
        <!-- New 1.3.x cache loader config block -->
        <!-- Note this is used for AS5.0 only -->
        <attribute name="CacheLoaderConfiguration">
            <config>
                <!-- We need to turn it on
                <passivation>false</passivation>
                -->
                <passivation>true</passivation>
                <preload>/</preload>
                <shared>false</shared>
  
                <cacheloader>
                    <class>org.jboss.cache.loader.FileCacheLoader</class>
                        <!--
                        -->
                    <properties>
                         location=${jboss.server.data.dir}${/}sfsb
                    </properties>
                    <async>false</async>
                    <fetchPersistentState>false</fetchPersistentState>
                    <ignoreModifications>false</ignoreModifications>
                </cacheloader>
  
            </config>
        </attribute>
  
     </mbean>
  
  </server>
  
  
  
  
  1.1      date: 2006/12/19 15:12:49;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources/ejb3-entity-cache-service.xml
  
  Index: ejb3-entity-cache-service.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <server>
  
    <!--  ====================================================================  -->
    <!--  Defines TreeCache configuration                                       -->
    <!--  ====================================================================  -->
    <mbean code="org.jboss.cache.TreeCache" name="jboss.cache:service=EJB3EntityTreeCache">
      <depends>jboss:service=Naming</depends>
      <depends>jboss:service=TransactionManager</depends>
      
      <!-- uncomment next three statements if using JGroups multiplexer,
            requires JGroups 2.3 or later, JBossCache 1.4 or later -->
      <!--
      <depends>jgroups.mux:name=Multiplexer</depends>
      <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
      <attribute name="MultiplexerStack">fc-fast-minimalthreads</attribute>
      -->
  
      <!-- Configure the TransactionManager -->
      <attribute name="TransactionManagerLookupClass">org.jboss.cache.JBossTransactionManagerLookup</attribute>
  
      <!--
              Node locking level : SERIALIZABLE
                                   REPEATABLE_READ (default)
                                   READ_COMMITTED
                                   READ_UNCOMMITTED
                                   NONE
      -->
      <attribute name="IsolationLevel">REPEATABLE_READ</attribute>
  
      <!--     Valid modes are LOCAL
                               REPL_ASYNC
                               REPL_SYNC
      -->
      <attribute name="CacheMode">REPL_SYNC</attribute>
  
      <!-- Name of cluster. Needs to be the same for all clusters, in order
               to find each other -->
      <attribute name="ClusterName">EJB3-entity-cache</attribute>
  
      <!-- Must be true if any entity deployment uses a scoped classloader -->
      <attribute name="UseRegionBasedMarshalling">true</attribute>
      <!-- Must match the value of "UseRegionBasedMarshalling" -->
      <attribute name="InactiveOnStartup">true</attribute>
      
      <attribute name="ClusterConfig">
        <config>
          <!-- 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" />
        </config>
      </attribute>
  
      <!--    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
      -->
      <attribute name="InitialStateRetrievalTimeout">5000</attribute>
  
      <!--    Number of milliseconds to wait until all responses for a
              synchronous call have been received.
      -->
      <attribute name="SyncReplTimeout">10000</attribute>
  
      <!--  Max number of milliseconds to wait for a lock acquisition -->
      <attribute name="LockAcquisitionTimeout">15000</attribute>
  
      <!--  Name of the eviction policy class. -->
      <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  
      <!--  Specific eviction policy configurations. This is LRU -->
      <attribute name="EvictionPolicyConfig">
        <config>
          <attribute name="wakeUpIntervalSeconds">5</attribute>
          <!--  Cache wide default -->
          <region name="/_default_">
           <attribute name="maxNodes">5000</attribute>
           <attribute name="timeToLiveSeconds">1000</attribute>
         </region>
        </config>
      </attribute>
  
    </mbean>
  
  </server>
  
  
  
  


From validimir.ralev at jboss.com  Tue Dec 19 10:12:49 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:12:49 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin ...
Message-ID: <E1Gwge9-0004gv-W1@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:12:49

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin 
                        ejb3.deployer
  Log:
  renaming the official patch
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 15:12:49;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin/ejb3.deployer
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Tue Dec 19 10:12:50 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:12:50 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 ...
Message-ID: <E1GwgeA-0004h2-4i@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:12:50

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 
                        component-info.xml
  Log:
  renaming the official patch
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 15:12:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/ejb3-component-info">
  
     <component id="jboss/ejb3"
                licenseType="lgpl"
                version="1.0.0.CR9-patch1-jboss4.0.5"
                description="The EJB3 deployer for integration with jboss-4.0.x">
        <!-- cvsroot=":ext:cvs.devel.redhat.com:/cvs/dist/jbossas-ejb3"
             tag="jbossas-ejb3-1_0_0-0_1_rc9_el4s1_5"
          -->
        <artifact id="ejb3-clustered-sfsbcache-service.xml"/>
        <artifact id="ejb3-entity-cache-service.xml"/>
        <artifact id="ejb3-interceptors-aop.xml"/>
        <artifact id="ejb3.deployer" />
        <artifact id="hibernate-client.jar"/>
        <artifact id="jboss-ejb3-client.jar"/>
  
        <import componentref="javassist">
          <compatible version="3.2.0.CR1"/>
          <compatible version="3.2.0.CR2"/>
        </import>
        <import componentref="hibernate-annotations">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="hibernate-entitymanager">
          <compatible version="3.2.0.GA"/>
        </import>
        <import componentref="jboss/remoting">
          <compatible version="1.4.1_final"/>
          <compatible version="1.4.2.GA"/>
        </import>
        <import componentref="jboss/aop">
          <compatible version="1.5.1.GA"/>
          <compatible version="1.5.2.GA"/>
        </import>
  
        <export>
           <include input="hibernate-client.jar"/>
           <include input="jboss-ejb3-client.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From validimir.ralev at jboss.com  Tue Dec 19 10:12:50 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Tue, 19 Dec 2006 10:12:50 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib ...
Message-ID: <E1GwgeA-0004hA-AB@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/19 10:12:50

  Added:       repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib  
                        jboss-ejb3-client.jar hibernate-client.jar
  Log:
  renaming the official patch
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 15:12:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/jboss-ejb3-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/19 15:12:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/hibernate-client.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Tue Dec 19 10:22:02 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 10:22:02 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1Gwgn4-0004qi-7f@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 10:22:02

  Modified:    JBossCache  Tag: Branch_JBossCache_1_4_0 build.xml
  Log:
  Fixed interop failure
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.119.2.20 +3 -2      JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.119.2.19
  retrieving revision 1.119.2.20
  diff -u -b -r1.119.2.19 -r1.119.2.20
  --- build.xml	18 Dec 2006 20:09:40 -0000	1.119.2.19
  +++ build.xml	19 Dec 2006 15:22:02 -0000	1.119.2.20
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.119.2.19 2006/12/18 20:09:40 bstansberry Exp $ -->
  +<!-- $Id: build.xml,v 1.119.2.20 2006/12/19 15:22:02 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -205,10 +205,11 @@
            <src path="${perf.tests.dir}"/>
            <src path="${jrunit.tests.dir}"/>
            <src path="${compat.tests.dir}"/>
  +         <src path="${interop.tests.dir}"/>
            <classpath path="${compile.dir}"/>
            <classpath refid="library.classpath"/>
            <exclude name="**/obsolete/**"/>
  -         <exclude name="**/interop/**"/>
  +         <!--<exclude name="**/interop/**"/>-->
            <exclude name="**/*1_4*"/>
         </javac>
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 10:32:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 10:32:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59150 - in projects/aop/trunk/aop/src:
	main/org/jboss/aop/advice main/org/jboss/aop/instrument
	resources/test/beforeafterArgs
	test/org/jboss/test/aop/beforeafterArgs
Message-ID: <E1GwgxK-00050G-QC@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-19 10:32:09 -0500 (Tue, 19 Dec 2006)
New Revision: 59150

Added:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsTestCase.java
Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java
   projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
Log:
[JBAOP-325] Implemented support to Args annotation.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -77,12 +77,6 @@
       this.joinpointExceptions = joinpointExceptions;
    }
 
-   /*public void setFoundProperties(Method adviceMethod, ArrayList args)
-   {
-      this.adviceMethod = adviceMethod;
-      this.args = (Integer[])args.toArray(new int[args.size()]);
-   }*/
-   
    public void setFoundProperties(Method adviceMethod, int[] args)
    {
       this.adviceMethod = adviceMethod;

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -67,7 +67,7 @@
 
    public ConByConJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, JoinPointParameters.ONLY_ARGS);
    }
 
    protected void initialiseJoinPointNames()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -67,8 +67,17 @@
 
    public ConByMethodJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, getParameters((ConByMethodInfo) info));
    }
+   
+   private static JoinPointParameters getParameters(ConByMethodInfo info)
+   {
+      if (Modifier.isStatic(info.getCallingMethod().getModifiers()))
+      {
+         return JoinPointParameters.ONLY_ARGS;
+      }
+      return JoinPointParameters.CALLER_ARGS;
+   }
 
    protected void initialiseJoinPointNames()
    {

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -67,7 +67,7 @@
 
    public ConstructionJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, JoinPointParameters.TARGET_ARGS);
    }
 
 

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -68,7 +68,7 @@
 
    public ConstructorJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, JoinPointParameters.ONLY_ARGS);
    }
 
 

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -74,9 +74,18 @@
 
    public FieldJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, getParameters((FieldInfo) info));
    }
 
+   private static JoinPointParameters getParameters(FieldInfo info)
+   {
+      if (Modifier.isStatic(info.getAdvisedField().getModifiers()))
+      {
+         return JoinPointParameters.ONLY_ARGS;
+      }
+      return JoinPointParameters.TARGET_ARGS;
+   }
+   
    protected void initialiseJoinPointNames()
    {
       joinpointClassName =
@@ -575,8 +584,8 @@
                      advisedClass.getName() + "." + advisedField.getName() + " = " +  value) +
 
             ((hasTargetObject) ?
-                  "return "  + TARGET_FIELD + "." + advisedField.getName() + ";" :
-                     "return " + advisedClass.getName() + "." + advisedField.getName() + ";") +
+                  "; return "  + TARGET_FIELD + "." + advisedField.getName() + ";" :
+                     "; return " + advisedClass.getName() + "." + advisedField.getName() + ";") +
             "}";
       }
 

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -1,4 +1,4 @@
-   /*
+ /*
   * JBoss, Home of Professional Open Source
   * Copyright 2005, JBoss Inc., and individual contributors as indicated
   * by the @authors tag. See the copyright.txt in the distribution for a
@@ -62,6 +62,211 @@
  */
 public abstract class JoinPointGenerator
 {
+   // TODO replace by enum
+   protected static class JoinPointParameters {
+      public static final JoinPointParameters ONLY_ARGS = new JoinPointParameters(false, -1, false, -1, 0, "")
+      {
+         /*public String declareArgsArray(int argsSize)
+         {
+            return "Object[] " + ARGUMENTS + " = new Object[]{$$};";
+         }*/
+      };
+      public static final JoinPointParameters TARGET_ARGS = new JoinPointParameters(true, 1, false, -1, 1, "$1");
+      public static final JoinPointParameters CALLER_ARGS = new JoinPointParameters(false, -1, true, 1, 1, "$1");
+      public static final JoinPointParameters TARGET_CALLER_ARGS = new JoinPointParameters(true, 1, true, 2, 2, "$1, $2");
+      
+      private boolean target;
+      private boolean caller;
+      
+      private int targetIndex;
+      private int callerIndex;
+      private int firstArgIndex;
+      private String listPrefix;
+      
+      private JoinPointParameters(boolean target, int targetIndex, boolean caller, int callerIndex, int firstArgIndex, String listPrefix)
+      {
+         this.target = target;
+         this.targetIndex = targetIndex;
+         this.caller = caller;
+         this.callerIndex = callerIndex;
+         this.firstArgIndex = firstArgIndex + 1;
+         this.listPrefix = listPrefix;
+      }
+      
+      public boolean hasTarget()
+      {
+         return target;
+      }
+      
+      public int getTargetIndex()
+      {
+         return targetIndex;
+      }
+      
+      public boolean hasCaller()
+      {
+         return caller;
+      }
+      
+      public int getCallerIndex()
+      {
+         return callerIndex;
+      }
+      
+      public int getFirstArgIndex()
+      {
+         return firstArgIndex;
+      }
+      
+      public String declareArgsArray(int totalParameters)
+      {
+         if (++totalParameters == firstArgIndex)
+         {
+            return "Object[] " + ARGUMENTS + " = new Object[0];";
+         }
+         StringBuffer buffer = new StringBuffer("Object[] ");
+         buffer.append(ARGUMENTS);
+         buffer.append(" = new Object[]{($w)$");
+         buffer.append(firstArgIndex);
+         for (int i = firstArgIndex + 1; i < totalParameters; i++)
+         {
+            buffer.append(", ($w)$");
+            buffer.append(i);
+         }
+         buffer.append("};");
+         return buffer.toString();
+      }
+      
+      public void appendParameterListWithArgs(StringBuffer code, CtClass[] parameterTypes, boolean beginWithComma)
+      {
+
+         int j = firstArgIndex - 1;
+         int totalParameters = parameterTypes.length - j;
+         if (listPrefix == "" && totalParameters == 0)
+         {
+            return;
+         }
+
+         if (beginWithComma)
+         {
+            code.append(", ");
+         }
+
+         code.append(listPrefix);
+         if (totalParameters == 0)
+         {
+            return;
+         }
+         if (listPrefix.length() != 0)
+         {
+            code.append(", ");
+         }
+
+         castArgument(code, parameterTypes[j++], 0);
+
+         for (int i = 1; i < totalParameters; i++, j++)
+         {
+            code.append(", ");
+            castArgument(code, parameterTypes[j], i);
+         }
+      }
+
+      private static final String[][] primitiveExtractions;
+
+      static{
+         primitiveExtractions = new String[][]{
+               {"((Boolean) " + ARGUMENTS + " [", "]).booleanValue()"},
+               {"((Integer) " + ARGUMENTS + "[", "]).intValue()"},
+               {"((Double) " + ARGUMENTS + "[", "]).doubleValue()"},
+               {"((Float) " + ARGUMENTS + "[", "]).floatValue()"},
+               {"((Character) " + ARGUMENTS + "[", "]).charValue()"},
+               {"((Byte) " + ARGUMENTS + " [", "]).byteValue()"},
+               {"((Long) " + ARGUMENTS + "[", "]).longValue()"},
+               {"((Short) " + ARGUMENTS + "[", "]).shortValue()"}
+         };
+      }
+      private final void castArgument(StringBuffer code, CtClass expectedType, int i)
+      {
+
+         if (expectedType.isPrimitive())
+         {
+            String[] extraction = null;
+            if (expectedType == CtClass.booleanType)
+            {
+               extraction = primitiveExtractions[0];
+            }
+            else if (expectedType == CtClass.intType)
+            {
+               extraction = primitiveExtractions[1];
+            }
+            else if (expectedType == CtClass.doubleType)
+            {
+               extraction = primitiveExtractions[2];
+            }
+            else if (expectedType == CtClass.floatType)
+            {
+               extraction = primitiveExtractions[3];
+            }
+            else if (expectedType == CtClass.charType)
+            {
+               extraction = primitiveExtractions[4];
+            }
+            else if (expectedType == CtClass.byteType)
+            {
+               extraction = primitiveExtractions[5];
+            }
+            else if (expectedType == CtClass.longType)
+            {
+               extraction = primitiveExtractions[6];
+            }
+            else if (expectedType == CtClass.shortType)
+            {
+               extraction = primitiveExtractions[7];
+            }
+            code.append(extraction[0]);
+            code.append(i);
+            code.append(extraction[1]);
+         }
+         else
+         {
+            code.append("(");
+            code.append(expectedType.getName());
+            code.append(") ");
+            code.append(ARGUMENTS);
+            code.append("[");
+            code.append(i);
+            code.append("]");
+         }
+      }
+
+      public void appendArgsArrayList(StringBuffer code, CtClass[] parameterTypes)
+      {
+         int j = firstArgIndex - 1;
+         int totalParameters = parameterTypes.length - j;
+
+         if (totalParameters == 0)
+         {
+            return;
+         }
+         code.append("(");
+         code.append(parameterTypes[j++].getName());
+         code.append(") ");
+         code.append(ARGUMENTS);
+         code.append("[0]");
+         
+         for (int i = 1; i < totalParameters; i++, j++)
+         {
+            code.append(", (");
+            code.append(parameterTypes[j].getName());
+            code.append(") ");
+            code.append(ARGUMENTS);
+            code.append("[");
+            code.append(i);
+            code.append("]");
+         }
+      }
+   }
+   
    public static final String INFO_FIELD = "info";
    public static final String INVOKE_JOINPOINT = "invokeJoinpoint";
    public static final String INVOKE_TARGET = "invokeTarget";
@@ -75,10 +280,12 @@
    public static final String GENERATOR_PREFIX = "generator_";
    private static final String RETURN_VALUE = "ret";
    private static final String THROWABLE = "t";
+   private static final String ARGUMENTS= " arguments";
    protected static final CtClass[] EMPTY_CTCLASS_ARRAY = new CtClass[0];
 
    private JoinPointInfo oldInfo;
    protected JoinPointInfo info;
+   private JoinPointParameters parameters;
    private static int increment;
    private Class advisorClass;
    protected GeneratedClassAdvisor advisor;
@@ -89,9 +296,11 @@
    private Field generatorField;
    private boolean initialised;
    
-   public JoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
+   protected JoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info,
+         JoinPointParameters parameters)
    {
       this.info = info;
+      this.parameters = parameters;
       this.advisor = advisor;
       this.advisorClass = advisor.getClass();
       Class[] interfaces = advisorClass.getInterfaces();
@@ -191,8 +400,10 @@
       }
       catch (Throwable e)
       {
+         e.printStackTrace();
          // AutoGenerated
          throw new RuntimeException("Error generating joinpoint class for joinpoint " + info, e);
+         
       }
       initialised = true;
    }
@@ -389,7 +600,7 @@
 
    private AdviceSetupsByType initialiseAdviceInfosAndAddFields(ClassPool pool, CtClass clazz) throws ClassNotFoundException, NotFoundException, CannotCompileException
    {
-      HashMap cflows = new HashMap();
+      HashMap<String, Integer> cflows = new HashMap<String, Integer>();
       AdviceSetup[] setups = new AdviceSetup[info.getInterceptors().length];
 
       for (int i = 0 ; i < info.getInterceptors().length ; i++)
@@ -457,11 +668,13 @@
             "}";
       }
    }
-   private void addCFlowFieldsAndGetters(ClassPool pool, AdviceSetup setup, CtClass clazz, HashMap cflows)throws NotFoundException, CannotCompileException
+   private void addCFlowFieldsAndGetters(ClassPool pool, AdviceSetup setup,
+         CtClass clazz, HashMap<String, Integer> cflows)
+         throws NotFoundException, CannotCompileException
    {
       if (setup.getCFlowString() != null)
       {
-         Integer useCFlowIndex = (Integer)cflows.get(setup.getCFlowString());
+         Integer useCFlowIndex = cflows.get(setup.getCFlowString());
          if (useCFlowIndex == null)
          {
             useCFlowIndex = new Integer(setup.getIndex());
@@ -506,7 +719,7 @@
          code = createJoinpointInvokeBody(
                clazz, 
                setups,
-               superInvoke.getExceptionTypes());
+               superInvoke.getExceptionTypes(), superInvoke.getParameterTypes());
          CtMethod invoke = CtNewMethod.make(
                superInvoke.getReturnType(), 
                superInvoke.getName(), 
@@ -522,7 +735,8 @@
       }
    }
    
-   private String createJoinpointInvokeBody(CtClass joinpointClass, AdviceSetupsByType setups, CtClass[] declaredExceptions)throws NotFoundException
+   private String createJoinpointInvokeBody(CtClass joinpointClass,
+         AdviceSetupsByType setups, CtClass[] declaredExceptions, CtClass[] parameterTypes)throws NotFoundException
    {
 
       StringBuffer code = new StringBuffer();
@@ -546,15 +760,18 @@
       }
       code.append("   try");
       code.append("   {");
-      addBeforeInvokeCode(code, setups);
+      boolean argsFound = addInvokeCode(DefaultAdviceCallStrategy.getInstance(),
+            setups.getBeforeSetups(), code);
+      addAroundInvokeCode(code, setups, joinpointClass, argsFound, parameterTypes);
 
-      addAroundInvokeCode(code, setups, joinpointClass);
-
-      addAfterInvokeCode(code, setups);
+      argsFound = addInvokeCode(AfterAdviceCallStrategy.getInstance(),
+            setups.getAfterSetups(), code) || argsFound;
+      
       code.append("   }");
       code.append("   catch(java.lang.Throwable " + THROWABLE + ")");
       code.append("   {");
-      addThrowingInvokeCode(code, setups);
+      argsFound = addInvokeCode(DefaultAdviceCallStrategy.getInstance(),
+            setups.getThrowingSetups(), code) || argsFound;
       addHandleExceptionCode(code, declaredExceptions);
       code.append("   }");
       if (!isVoid())
@@ -563,30 +780,32 @@
       }
       code.append("}");;
       
+      if (argsFound)
+      {
+         code.insert(1, parameters.declareArgsArray(parameterTypes.length));
+      }
       return code.toString();
    }   
 
-   private void addBeforeInvokeCode(StringBuffer code, AdviceSetupsByType setups) throws NotFoundException
+   private boolean addInvokeCode(AdviceCallStrategy callStrategy, AdviceSetup[] setups, StringBuffer code) throws NotFoundException
    {
-      AdviceSetup[] bsetups = setups.getBeforeSetups();
-      if (bsetups != null)
+      if (setups == null || setups.length == 0)
       {
-         for (int i = 0 ; i < bsetups.length ; i++)
-         {
-            AdviceMethodProperties properties = bsetups[i].getAdviceMethodProperties();
-            
-            if (properties != null)
-            {
-               code.append(bsetups[i].getAspectFieldName() + "." + bsetups[i].getAdviceName() + "(");
-               appendAdviceCallParameters(code, properties, false);
-               code.append(");");
-            }
-         }
+         return false;
       }
+      boolean argsFound = false;
+      String key = callStrategy.generateKey(this);
+      for (int i = 0 ; i < setups.length ; i++)
+      {
+         argsFound = callStrategy.appendAdviceCall(setups[i], key, code, this)
+            || argsFound;
+      }
+      return argsFound;
    }
    
    
-   private void addAroundInvokeCode(StringBuffer code, AdviceSetupsByType setups, CtClass joinpointClass) throws NotFoundException
+   private void addAroundInvokeCode(StringBuffer code, AdviceSetupsByType setups,
+         CtClass joinpointClass, boolean argsFound, CtClass[] parameterTypes) throws NotFoundException
    {
       if (setups.getAroundSetups() != null)
       {
@@ -613,8 +832,18 @@
 
          code.append("      if(" + INFO_FIELD + ".getInterceptors() != null)");
          code.append("      {");
-         code.append("         " + joinpointFqn + " jp = new " + joinpointClass.getName() + "(this, $$" + aspects.toString() + cflows.toString() + ");");
+         code.append("         " + joinpointFqn + " jp = new " + joinpointClass.getName() + "(this");
+         if (argsFound)
+         {
+            parameters.appendParameterListWithArgs(code, parameterTypes, true);
+            
+         }
+         else
+         {
+            code.append(", $$");
+         }
          
+         code.append(aspects.toString() + cflows.toString() + ");");
          if (!isVoid())
          {
             code.append("          " + RETURN_VALUE + " = ($r)");
@@ -625,67 +854,35 @@
          code.append("      else");
          code.append("      {");
          
-         addDispatchCode(code);
+         addDispatchCode(code, parameterTypes, argsFound);
          
          code.append("      }");
       }
       else
       {
-         addDispatchCode(code);
+         addDispatchCode(code, parameterTypes, argsFound);
       }
    }
 
-   private void addDispatchCode(StringBuffer code)
+   private final void addDispatchCode(StringBuffer code, CtClass[] parameterTypes,
+         boolean argsFound)
    {
       if (! isVoid())
       {
          code.append("          " + RETURN_VALUE + " = ");
       }
-      code.append("super.dispatch($$);");
-   }
-   
-   private void addAfterInvokeCode(StringBuffer code, AdviceSetupsByType setups) throws NotFoundException
-   {
-      AdviceSetup[] asetups = setups.getAfterSetups();
-      if (asetups != null)
+      code.append("super.dispatch(");
+      if (argsFound)
       {
-         for (int i = 0 ; i < asetups.length ; i++)
-         {
-            AdviceMethodProperties properties = asetups[i].getAdviceMethodProperties();
-            
-            if (properties != null)
-            {
-               if (!isVoid() && !properties.isAdviceVoid())
-               {
-                  code.append("          " + RETURN_VALUE + " = (" + getReturnType().getName() + ")");
-               }
-               code.append(asetups[i].getAspectFieldName() + "." + asetups[i].getAdviceName() + "(");
-               appendAdviceCallParameters(code, properties, false);
-               code.append(");");
-            }
-         }
+         parameters.appendParameterListWithArgs(code, parameterTypes, false);
       }
-   }
-   
-   private void addThrowingInvokeCode(StringBuffer code, AdviceSetupsByType setups) throws NotFoundException
-   {
-      AdviceSetup[] tsetups = setups.getThrowingSetups();
-      if (tsetups != null)
+      else
       {
-         for (int i = 0 ; i < tsetups.length ; i++)
-         {
-            AdviceMethodProperties properties = tsetups[i].getAdviceMethodProperties();
-            
-            if (properties != null)
-            {
-               code.append(tsetups[i].getAspectFieldName() + "." + tsetups[i].getAdviceName() + "(");
-               appendAdviceCallParameters(code, properties, false);
-               code.append(");");
-            }
-         }
+         code.append("$$");
       }
+      code.append(");");
    }
-
+   
    private void addHandleExceptionCode(StringBuffer code, CtClass[] declaredExceptions)
    {
       for (int i = 0 ; i < declaredExceptions.length ; i++)
@@ -730,43 +927,7 @@
       body.append("   try{");
       body.append("      switch(++" + CURRENT_ADVICE + "){");
       
-      int addedAdvice = 0;
-      for (int i = 0 ; i < aroundSetups.length ; i++)
-      {
-         if (!aroundSetups[i].shouldInvokeAspect())
-         {
-            //We are invoking a static method/ctor, do not include advice in chain
-            continue;
-         }
-      
-         AdviceMethodProperties properties = AdviceMethodFactory.AROUND.findAdviceMethod(getAdviceMethodProperties(aroundSetups[i]));
-         if (properties == null || properties.getAdviceMethod() == null)
-         {
-//            throw new RuntimeException("DEBUG ONLY Properties was null " + aroundSetups[i].getAspectClass().getName() + "." + aroundSetups[i].getAdviceName());
-            continue;
-         }
-         
-         body.append("      case " + (++addedAdvice) + ":");
-         if (aroundSetups[i].getCFlowString() != null)
-         {
-            body.append("         if (matchesCflow" + aroundSetups[i].useCFlowFrom() + ")");
-            body.append("         {");
-            appendAroundCallString(body, returnStr, aroundSetups[i], properties);
-            body.append("         }");
-            body.append("         else");
-            body.append("         {");
-            body.append("            " + returnStr + " invokeNext();");
-            body.append("         }");
-         }
-         else
-         {
-            appendAroundCallString(body, returnStr, aroundSetups[i], properties);
-         }
-         
-         
-         body.append("      break;");
-      }
-      
+      addInvokeCode(AroundAdviceCallStrategy.getInstance(), aroundSetups, body);
       body.append("      default:");
       body.append("         " + returnStr + "this.dispatch();");
       body.append("      }");
@@ -871,12 +1032,14 @@
     * This is the constructor that will be called by the invokeJoinPoint() method, make sure it
     * copies across all the non-per-instance aspects
     */
-   private void createProtectedConstructor(ClassPool pool, CtConstructor superCtor, CtClass clazz, AdviceSetupsByType setups) throws CannotCompileException, NotFoundException
+   private void createProtectedConstructor(ClassPool pool, CtConstructor superCtor,
+         CtClass clazz, AdviceSetupsByType setups)
+         throws CannotCompileException, NotFoundException
    {
       
       CtClass[] superParams = superCtor.getParameterTypes();
-      ArrayList aspects = new ArrayList(); 
-      ArrayList cflows = new ArrayList();
+      ArrayList<AdviceSetup> aspects = new ArrayList<AdviceSetup>(); 
+      ArrayList<Integer> cflows = new ArrayList<Integer>();
       StringBuffer adviceInit = new StringBuffer(); 
       
       AdviceSetup[] allSetups = setups.getAllSetups();
@@ -889,7 +1052,10 @@
          
          if (allSetups[i].requiresInstanceAdvisor())
          {
-            adviceInit.append(allSetups[i].getAspectFieldName() + " = " + allSetups[i].getAspectInitialiserName() + "();");
+            adviceInit.append(allSetups[i].getAspectFieldName());
+            adviceInit.append(" = ");
+            adviceInit.append(allSetups[i].getAspectInitialiserName());
+            adviceInit.append("();");
          }
          else
          {
@@ -898,7 +1064,7 @@
          
          if (allSetups[i].isNewCFlow())
          {
-            cflows.add(new Integer(allSetups[i].useCFlowFrom()));
+            cflows.add(allSetups[i].useCFlowFrom());
          }
       }
 
@@ -1101,76 +1267,7 @@
       
       return sb.toString();
    }
-
-   public void appendAroundCallString(StringBuffer invokeNextBody, String returnStr, AdviceSetup setup, AdviceMethodProperties properties)
-   {
-      int[] args = properties.getArgs();
-      
-      final boolean firstParamIsInvocation = (args.length >= 1 && args[0] == AdviceMethodProperties.INVOCATION_ARG);
-
-      if (!firstParamIsInvocation)
-      {
-         invokeNextBody.append("try{");
-         invokeNextBody.append("   org.jboss.aop.joinpoint.CurrentInvocation.push(this); ");
-      }
-
-      invokeNextBody.append("   " + returnStr + " " + setup.getAspectFieldName() + "." + properties.getAdviceName() + "(");
-      appendAdviceCallParameters(invokeNextBody, properties, true);
-      invokeNextBody.append(");");
-      
-      if (!firstParamIsInvocation)
-      {
-         invokeNextBody.append("}finally{");
-         invokeNextBody.append("   org.jboss.aop.joinpoint.CurrentInvocation.pop(); ");
-         invokeNextBody.append("}");
-      }
-   }
-
-   private void appendAdviceCallParameters(StringBuffer invokeNextBody, AdviceMethodProperties properties, boolean isAround) 
-   {
-      final int[] args = properties.getArgs(); 
-      final Class[] adviceParams = properties.getAdviceMethod().getParameterTypes();
-      for (int i = 0 ; i < args.length ; i++)
-      {
-         if (i > 0) invokeNextBody.append(", ");
-
-         switch(args[i])
-         {
-         case AdviceMethodProperties.INVOCATION_ARG:
-            invokeNextBody.append(castToAdviceProperties(i, adviceParams) + "this");
-            break;
-         case AdviceMethodProperties.JOINPOINT_ARG:
-            invokeNextBody.append(castToAdviceProperties(i, adviceParams) + INFO_FIELD);
-            break;
-         case AdviceMethodProperties.RETURN_ARG:
-            invokeNextBody.append(castToAdviceProperties(i, adviceParams) + RETURN_VALUE);
-            break;
-         case AdviceMethodProperties.THROWABLE_ARG:
-            invokeNextBody.append(castToAdviceProperties(i, adviceParams) + THROWABLE);
-            break;
-         default:
-            if (isAround)
-            {
-               invokeNextBody.append(castToAdviceProperties(i, adviceParams) + "this.arg" + args[i]);
-            }
-            else 
-            {
-               //The parameter array is 1-based, and the invokeJoinPoint method may also take the target and caller objects
-               int offset = 1;
-               if (hasTargetObject()) offset++;
-               if (hasCallingObject()) offset++;
-               invokeNextBody.append(castToAdviceProperties(i, adviceParams) + "$" + (args[i] + offset));
-            }
-         }
-      }
-   }
    
-   private String castToAdviceProperties(int i, Class[] args)
-   {
-      //In case of overloaded methods javassist sometimes seems to pick up the wrong method - use explicit casts to get hold of the parameters
-      return "(" + ClassExpression.simpleType(args[i]) + ")";
-   }
-   
    protected class AdviceSetup
    {
       int index;
@@ -1405,16 +1502,16 @@
       AdviceSetupsByType(AdviceSetup[] setups)
       {
          allSetups = setups;
-         ArrayList beforeAspects = null;
-         ArrayList afterAspects = null;
-         ArrayList throwingAspects = null;
-         ArrayList aroundAspects = null;
+         ArrayList<AdviceSetup> beforeAspects = null;
+         ArrayList<AdviceSetup> afterAspects = null;
+         ArrayList<AdviceSetup> throwingAspects = null;
+         ArrayList<AdviceSetup> aroundAspects = null;
 
          for (int i = 0 ; i < setups.length ; i++)
          {
             if (setups[i].isBefore())
             {
-               if (beforeAspects == null) beforeAspects = new ArrayList();
+               if (beforeAspects == null) beforeAspects = new ArrayList<AdviceSetup>();
                
                AdviceMethodProperties properties = AdviceMethodFactory.BEFORE.findAdviceMethod(getAdviceMethodProperties(setups[i]));
                if (properties != null)
@@ -1426,7 +1523,7 @@
             }
             else if (setups[i].isAfter())
             {
-               if (afterAspects == null) afterAspects = new ArrayList();
+               if (afterAspects == null) afterAspects = new ArrayList<AdviceSetup>();
                AdviceMethodProperties properties = AdviceMethodFactory.AFTER.findAdviceMethod(getAdviceMethodProperties(setups[i]));
                if (properties != null)
                {
@@ -1437,7 +1534,7 @@
             }
             else if (setups[i].isThrowing())
             {
-               if (throwingAspects == null) throwingAspects = new ArrayList();
+               if (throwingAspects == null) throwingAspects = new ArrayList<AdviceSetup>();
                AdviceMethodProperties properties = AdviceMethodFactory.THROWING.findAdviceMethod(getAdviceMethodProperties(setups[i]));
                if (properties != null)
                {
@@ -1448,7 +1545,7 @@
             }
             else
             {
-               if (aroundAspects == null) aroundAspects = new ArrayList();
+               if (aroundAspects == null) aroundAspects = new ArrayList<AdviceSetup>();
                AdviceMethodProperties properties = AdviceMethodFactory.AROUND.findAdviceMethod(getAdviceMethodProperties(setups[i]));
                if (properties != null)
                {
@@ -1508,7 +1605,7 @@
          {
             try
             {
-               AccessController.doPrivileged(new PrivilegedExceptionAction()
+               AccessController.doPrivileged(new PrivilegedExceptionAction<Object>()
                {
                   public Object run() throws Exception
                   {
@@ -1537,4 +1634,253 @@
          }
       };
    }
-}
+
+
+   private static abstract class AdviceCallStrategy
+   {
+      public abstract String generateKey(JoinPointGenerator generator);
+      public abstract boolean appendAdviceCall(AdviceSetup setup, String key,
+           StringBuffer code, JoinPointGenerator generator) throws NotFoundException;
+      
+      private final boolean appendAdviceCall(AdviceSetup setup, StringBuffer code,
+            boolean isAround, JoinPointGenerator generator) 
+      {
+         AdviceMethodProperties properties = setup.getAdviceMethodProperties();
+         if (properties == null)
+         {
+            return false;
+         }
+         code.append(setup.getAspectFieldName());
+         code.append(".");
+         code.append(setup.getAdviceName());
+         code.append("(");
+         
+         
+         final int[] args = properties.getArgs();
+         boolean argsFound = false;
+         if (args.length > 0)
+         {
+            final Class[] adviceParams = properties.getAdviceMethod().getParameterTypes();
+            argsFound = appendParameters(code, args[0], adviceParams[0],
+                  isAround, generator);
+            for (int i = 1 ; i < args.length ; i++)
+            {
+               code.append(", ");
+               argsFound = appendParameters(code, args[i], adviceParams[i],
+                     isAround, generator) || argsFound;
+            }
+         }
+         
+         code.append(");");
+         return argsFound;
+      }
+      /**
+       * @param code
+       * @param isAround
+       * @param args
+       * @param adviceParams
+       * @param argsFound
+       * @param i
+       * @return
+       */
+      private final boolean appendParameters(StringBuffer code, final int arg,
+            final Class adviceParam, boolean isAround, JoinPointGenerator generator)
+      {
+         code.append("(");
+         // In case of overloaded methods javassist sometimes seems to pick up the wrong method - use explicit casts to get hold of the parameters
+         code.append(ClassExpression.simpleType(adviceParam));
+         code.append(")");
+         switch(arg)
+         {
+         case AdviceMethodProperties.INVOCATION_ARG:
+            code.append("this");
+            break;
+         case AdviceMethodProperties.JOINPOINT_ARG:
+            code.append(INFO_FIELD);
+            break;
+         case AdviceMethodProperties.RETURN_ARG:
+            code.append(RETURN_VALUE);
+            break;
+         case AdviceMethodProperties.THROWABLE_ARG:
+            code.append(THROWABLE);
+            break;
+         case AdviceMethodProperties.ARGS_ARG:
+            code.append(ARGUMENTS);
+            return true;
+         default:
+            if (isAround)
+            {
+               code.append("this.arg");
+               code.append(arg);
+            }
+            else 
+            {
+               //The parameter array is 1-based, and the invokeJoinPoint method may also take the target and caller objects
+               code.append("$");
+               code.append(arg + generator.parameters.getFirstArgIndex());
+            }
+         }
+         return false;
+      }
+   }
+   
+   private static class AroundAdviceCallStrategy extends AdviceCallStrategy
+   {
+      private static ThreadLocal<AroundAdviceCallStrategy> INSTANCE;
+      
+      static
+      {
+         INSTANCE = new ThreadLocal<AroundAdviceCallStrategy>();
+         INSTANCE.set(new AroundAdviceCallStrategy());
+      }
+      
+      public static final AroundAdviceCallStrategy getInstance()
+      {
+         return INSTANCE.get();
+      }
+      
+      private AroundAdviceCallStrategy() {}
+      
+      private int addedAdvice = 0;
+      
+      public String generateKey(JoinPointGenerator generator)
+      {
+         addedAdvice = 0;
+         if (generator.isVoid())
+         {
+            return "";
+         }
+         return "return ($w)";
+      }
+      
+      public boolean appendAdviceCall(AdviceSetup setup, String key,
+            StringBuffer code, JoinPointGenerator generator)
+      {
+         if (!setup.shouldInvokeAspect())
+         {
+            //We are invoking a static method/ctor, do not include advice in chain
+            return false;
+         }
+      
+         boolean result = false;
+         AdviceMethodProperties properties = AdviceMethodFactory.AROUND.
+            findAdviceMethod(generator.getAdviceMethodProperties(setup));
+         if (properties == null || properties.getAdviceMethod() == null)
+         {
+            // throw new RuntimeException("DEBUG ONLY Properties was null " + 
+            // aroundSetups[i].getAspectClass().getName() + "." + aroundSetups[i].getAdviceName());
+            return false;
+         }
+         
+         code.append("      case ");
+         code.append(++addedAdvice);
+         code.append(":");
+         
+         if (setup.getCFlowString() != null)
+         {
+            code.append("         if (matchesCflow" + setup.useCFlowFrom() + ")");
+            code.append("         {");
+            result = appendAroundCallString(code, key, setup, properties, generator);
+            code.append("         }");
+            code.append("         else");
+            code.append("         {");
+            code.append("            ");
+            code.append(key);
+            code.append(" invokeNext();");
+            code.append("         }");
+         }
+         else
+         {
+            result = appendAroundCallString(code, key, setup, properties, generator);
+         }
+         
+         code.append("      break;");
+         return result;
+      }
+      
+      
+      public boolean appendAroundCallString(StringBuffer invokeNextBody,
+            String returnStr, AdviceSetup setup, AdviceMethodProperties properties,
+            JoinPointGenerator generator)
+      {
+         int[] args = properties.getArgs();
+         
+         final boolean firstParamIsInvocation =
+            (args.length >= 1 && args[0] == AdviceMethodProperties.INVOCATION_ARG);
+
+         if (!firstParamIsInvocation)
+         {
+            invokeNextBody.append("try{");
+            invokeNextBody.append("   org.jboss.aop.joinpoint.CurrentInvocation.push(this); ");
+         }
+         invokeNextBody.append("   ");
+         invokeNextBody.append(returnStr);
+         invokeNextBody.append(" ");
+         boolean result = super.appendAdviceCall(setup, invokeNextBody, true, generator);
+         
+         if (!firstParamIsInvocation)
+         {
+            invokeNextBody.append("}finally{");
+            invokeNextBody.append("   org.jboss.aop.joinpoint.CurrentInvocation.pop(); ");
+            invokeNextBody.append("}");
+         }
+         return result;
+      }
+   }
+   
+   private static class DefaultAdviceCallStrategy extends AdviceCallStrategy
+   {
+      private static DefaultAdviceCallStrategy INSTANCE = new DefaultAdviceCallStrategy();
+      
+      public static final DefaultAdviceCallStrategy getInstance()
+      {
+         return INSTANCE;
+      }
+      
+      private DefaultAdviceCallStrategy() {}
+
+      public String generateKey(JoinPointGenerator generator)
+      {
+         return null;
+      }
+      
+      public boolean appendAdviceCall(AdviceSetup setup, String key,
+            StringBuffer code, JoinPointGenerator generator)
+      {
+         return super.appendAdviceCall(setup, code, false, generator);
+      }
+   }
+   
+   private static class AfterAdviceCallStrategy extends AdviceCallStrategy
+   {
+      private static AfterAdviceCallStrategy INSTANCE = new AfterAdviceCallStrategy();
+      
+      public static final AfterAdviceCallStrategy getInstance()
+      {
+         return INSTANCE;
+      }
+      
+      private AfterAdviceCallStrategy() {}
+
+      public String generateKey(JoinPointGenerator generator)
+      {
+         if (generator.isVoid())
+         {
+            return "";
+         }
+         return "          " + RETURN_VALUE + " = (" +
+         generator.getReturnType().getName() + ")";
+      }
+
+      public boolean appendAdviceCall(AdviceSetup setup, String key,
+            StringBuffer code, JoinPointGenerator generator) throws NotFoundException
+      {
+         AdviceMethodProperties properties = setup.getAdviceMethodProperties();
+         if (properties != null && !properties.isAdviceVoid())
+         {
+            code.append(key);
+         }
+         return super.appendAdviceCall(setup, code, false, generator);
+      }
+   }
+}
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -61,8 +61,17 @@
 
    public MethodByConJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, getParameters((MethodByConInfo) info));
    }
+   
+   private static JoinPointParameters getParameters(MethodByConInfo info)
+   {
+      if (Modifier.isStatic(info.getMethod().getModifiers()))
+      {
+         return JoinPointParameters.ONLY_ARGS;
+      }
+      return JoinPointParameters.TARGET_ARGS;
+   }
 
    protected void initialiseJoinPointNames()
    {
@@ -337,8 +346,6 @@
        */
       private CtMethod addInvokeJoinpointMethod() throws CannotCompileException, NotFoundException
       {
-         CtClass[] invokeParams = null;
-
          invokeJoinpointMethod  = CtNewMethod.make(
                targetMethod.getReturnType(),
                INVOKE_JOINPOINT,

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -61,9 +61,26 @@
 
    public MethodByMethodJoinPointGenerator(GeneratedClassAdvisor advisor, JoinPointInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, getParameters((MethodByMethodInfo) info));
    }
 
+   private static JoinPointParameters getParameters(MethodByMethodInfo info)
+   {
+      if (Modifier.isStatic(info.getCallingMethod().getModifiers()))
+      {
+         if (Modifier.isStatic(info.getMethod().getModifiers()))
+         {
+            return JoinPointParameters.ONLY_ARGS;
+         }
+         return JoinPointParameters.TARGET_ARGS;
+      }
+      if (Modifier.isStatic(info.getMethod().getModifiers()))
+      {
+         return JoinPointParameters.CALLER_ARGS;
+      }
+      return JoinPointParameters.TARGET_CALLER_ARGS;
+   }
+   
    protected void initialiseJoinPointNames()
    {
       joinpointClassName = getInfoClassName(

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodExecutionTransformer.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -402,5 +402,13 @@
       {
          return instrumentor;
       }
+
+      /**
+       * @param wmethod2
+       */
+      public void setMethod(CtMethod method)
+      {
+         this.method = method;
+      }
    }
 }
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -62,8 +62,17 @@
 
    public MethodJoinPointGenerator(GeneratedClassAdvisor advisor, MethodInfo info)
    {
-      super(advisor, info);
+      super(advisor, info, getParameters((MethodInfo) info));
    }
+   
+   private static JoinPointParameters getParameters(MethodInfo info)
+   {
+      if (Modifier.isStatic(info.getAdvisedMethod().getModifiers()))
+      {
+         return JoinPointParameters.ONLY_ARGS;
+      }
+      return JoinPointParameters.TARGET_ARGS;
+   }
 
    protected void initialiseJoinPointNames()
    {

Modified: projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-19 15:32:09 UTC (rev 59150)
@@ -2,6 +2,65 @@
 <!DOCTYPE aop SYSTEM "jboss-aop_1_0.dtd">
 
 <aop>
+   <!-- @Args test -->
+	<aspect class="org.jboss.test.aop.beforeafterArgs.ArgsAspect" scope="PER_VM"/>
+
+	<bind pointcut="field(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->field1)">
+		<before name="before1" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+      <before name="before2" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<before name="before3" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<before name="before4" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<before name="before5" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+   </bind>
+   
+   <bind pointcut="set(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->field2)">
+      <before name="before6" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+      <after name="after6" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+   </bind>
+
+	<bind pointcut="field(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->field3)">
+		<after name="after1" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+      <after name="after2" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after3" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after4" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after5" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+   </bind>
+
+	<bind pointcut="field(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->field4)">
+		<before name="before1" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+      <before name="before2" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<before name="before3" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<before name="before4" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<before name="before5" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after1" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+      <after name="after2" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after3" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after4" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+		<after name="after5" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect"/>
+   </bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->method1(..))">
+	   <before name="before3" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	   <after name="after3" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->method2(..))">
+	   <before name="before7" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	   <advice name="around1" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	   <after name="after7" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	</bind>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->method3(..))">
+	   <throwing name="throwing" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	</bind>
+	
+	<bind pointcut="call(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->method3(..)) AND withincode(* org.jboss.test.aop.beforeafterArgs.ArgsPOJO->method4(..))">
+      <before name="before8" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+      <advice name="around2" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+      <after name="after8" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	   <throwing name="throwing" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
+	</bind>
+	
    <!-- @JoinPoint test -->
 	<aspect class="org.jboss.test.aop.beforeafterArgs.JoinPointAspect" scope="PER_VM"/>
 

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsAspect.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsAspect.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -0,0 +1,228 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Assert;
+
+import org.jboss.aop.advice.annotation.Args;
+import org.jboss.aop.advice.annotation.Thrown;
+import org.jboss.aop.joinpoint.MethodCalledByMethodInvocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
+
+/**
+ * Aspect used on @Args parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ArgsAspect
+{
+   static boolean before1 = false;
+   static boolean before2 = false;
+   static boolean before3 = false;
+   static boolean before6 = false;
+   static boolean before7 = false;
+   static boolean before8 = false;
+   static Object[] before2Args = null;
+   static Object[] before3Args = null;
+   static Object[] before6Args = null;
+   static Object[] before7Args = null;
+   static Object[] before8Args = null;
+
+   static boolean after1 = false;
+   static boolean after2 = false;
+   static boolean after3 = false;
+   static boolean after6 = false;
+   static boolean after7 = false;
+   static boolean after8 = false;
+   static Object[] after2Args = null;
+   static Object[] after3Args = null;
+   static Object[] after6Args = null;
+   static Object[] after7Args = null;
+   static Object[] after8Args = null;
+
+   static boolean around1 = false;
+   static boolean around2 = false;
+   static Object[] around1Args = null;
+   static Object[] around2Args = null;
+   
+   static boolean throwing = false;
+   static Object[] throwingArgs = null;
+   
+   public static void clear()
+   {
+      before1 = false;
+      before2 = false;
+      before3 = false;
+      before6 = false;
+      before7 = false;
+      before8 = false;
+      before2Args = null;
+      before3Args = null;
+      before6Args = null;
+      before7Args = null;
+      before8Args = null;
+      
+      after1 = false;
+      after2 = false;
+      after3 = false;
+      after6 = false;
+      after7 = false;
+      after8 = false;
+      after2Args = null;
+      after3Args = null;
+      after6Args = null;
+      after7Args = null;
+      after8Args = null;
+      
+      around1 = false;
+      around2 = false;
+      around1Args = null;
+      around2Args = null;
+      
+      throwing = false;
+      throwingArgs = null;
+   }
+   
+   public void before1()
+   {
+      before1 = true;
+   }
+   
+   public void before2(@Args Object[] arguments)
+   {
+      before2 = true;
+      before2Args = arguments;
+   }
+   
+   public void before3(@Args Object arguments)
+   {
+      before3 = true;
+      before3Args = (Object[]) arguments;
+   }
+   
+   public void before4(@Args String arguments)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+
+   public void before5(@Args char[] arguments)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void before6(@Args Object[] arguments)
+   {
+      before6 = true;
+      before6Args = arguments;
+      arguments[0] = "before6";
+   }
+   
+   public void before7(@Args Object[] arguments)
+   {
+      before7 = true;
+      before7Args = arguments;
+      before7Args[0] = "before7";
+      before7Args[1] = new Integer(7);
+      before7Args[2] = Boolean.TRUE;
+      before7Args[3] = new ArgsPOJO[0];
+   }
+
+   public void before8(@Args Object[] arguments)
+   {
+      before8 = true;
+      before8Args = arguments;
+      before8Args[0] = new Short((short) -8);
+      before8Args[1] = new Long((long) 8);
+   }
+   
+   public void after1()
+   {
+      after1 = true;
+   }
+   
+   public void after2(@Args Object[] arguments)
+   {
+      after2 = true;
+      after2Args = arguments;
+   }
+   
+   public void after3(@Args Object arguments)
+   {
+      after3 = true;
+      after3Args = (Object[]) arguments;
+   }
+   
+   public void after4(@Args String arguments)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+
+   public void after5(@Args char[] arguments)
+   {
+      Assert.fail("This advice should never be executed");
+   }
+   
+   public void after6(@Args Object[] arguments)
+   {
+      after6 = true;
+      after6Args = arguments;
+      arguments[0] = "after6";
+   }
+
+   public void after7(@Args Object[] arguments)
+   {
+      after7 = true;
+      after7Args = arguments;
+      after7Args[0] = "after7";
+      after7Args[1] = new Integer(14);
+      after7Args[2] = Boolean.FALSE;
+      after7Args[3] = new ArgsPOJO[]{null};
+   }
+   
+   public void after8(@Args Object[] arguments)
+   {
+      before8 = true;
+      before8Args = arguments;
+      // TODO make after 8 realize changes made during around invocations
+   }
+   
+   public Object around1(MethodInvocation invocation) throws Throwable
+   {
+      around1 = true;
+      around1Args = invocation.getArguments();
+      return invocation.invokeNext();
+   }
+   
+   public Object around2(MethodCalledByMethodInvocation invocation) throws Throwable
+   {
+      around2 = true;
+      around2Args = invocation.getArguments();
+      return invocation.invokeNext();
+   }
+   
+   public void throwing(@Args Object[] arguments, @Thrown Throwable throwable)
+   {
+      throwing = true;
+      System.out.println("RECEIVING ARGUMENTS: " + arguments);
+      throwingArgs = arguments;
+   }
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsPOJO.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsPOJO.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -0,0 +1,54 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+/**
+ * Plain old java object used on @Args parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ArgsPOJO
+{
+   public Object field1;
+   
+   public String field2;
+   
+   public int field3;
+   
+   public static boolean field4;
+   
+   public void method1(String param1, int param2, boolean param3, ArgsPOJO[] param4)
+   {}
+   
+   public void method2(String param1, int param2, boolean param3, ArgsPOJO[] param4)
+   {}
+   
+   public void method3(short param1, long param2) throws POJOException
+   {
+      throw new POJOException();
+   }
+   
+   public void method4() throws POJOException
+   {
+      this.method3((short) -4, (long) 4);
+   }
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsTestCase.java	2006-12-19 15:06:45 UTC (rev 59149)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/ArgsTestCase.java	2006-12-19 15:32:09 UTC (rev 59150)
@@ -0,0 +1,297 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * Tests the use of @Args parameters.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class ArgsTestCase extends AOPTestWithSetup
+{
+   private ArgsPOJO pojo;
+
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("ArgsTestCase");
+      suite.addTestSuite(ArgsTestCase.class);
+      return suite;
+   }
+
+   public ArgsTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      this.pojo = new ArgsPOJO();
+      ArgsAspect.clear();
+   }
+   
+   public void test1()
+   {
+      Object text = pojo.field1;
+      assertTrue(ArgsAspect.before1);
+      assertTrue(ArgsAspect.before2);
+      assertTrue(ArgsAspect.before3);
+      assertSame(ArgsAspect.before2Args, ArgsAspect.before3Args);
+      assertEquals(0, ArgsAspect.before2Args.length);
+      
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.after1);
+      assertFalse(ArgsAspect.after2);
+      assertFalse(ArgsAspect.after3);
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+   }
+   
+   public void test2()
+   {
+      pojo.field1 = "test2";
+      assertTrue(ArgsAspect.before1);
+      assertTrue(ArgsAspect.before2);
+      assertTrue(ArgsAspect.before3);
+      assertSame(ArgsAspect.before2Args, ArgsAspect.before3Args);
+      assertEquals(1, ArgsAspect.before2Args.length);
+      assertEquals("test2", ArgsAspect.before2Args[0]);
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.after1);
+      assertFalse(ArgsAspect.after2);
+      assertFalse(ArgsAspect.after3);
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+   }
+   
+   public void test3()
+   {
+      pojo.field2 = "test3";
+      assertTrue(ArgsAspect.before6);
+      assertTrue(ArgsAspect.after6);
+      assertNotNull(ArgsAspect.before6Args);
+      assertSame(ArgsAspect.before6Args, ArgsAspect.after6Args);
+      assertEquals(1, ArgsAspect.before6Args.length);
+      assertEquals("after6", ArgsAspect.before6Args[0]);
+      
+      assertFalse(ArgsAspect.before1);
+      assertFalse(ArgsAspect.before2);
+      assertFalse(ArgsAspect.before3);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.after1);
+      assertFalse(ArgsAspect.after2);
+      assertFalse(ArgsAspect.after3);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+      
+      assertEquals("before6", pojo.field2);
+   }
+   
+   public void test4()
+   {
+      pojo.field3 = 10;
+      
+      assertTrue(ArgsAspect.after1);
+      assertTrue(ArgsAspect.after2);
+      assertTrue(ArgsAspect.after3);
+      assertNotNull(ArgsAspect.after2Args);
+      assertSame(ArgsAspect.after2Args, ArgsAspect.after3Args);
+      assertEquals(1, ArgsAspect.after2Args.length);
+      assertEquals(10, ArgsAspect.after2Args[0]);
+      
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.before1);
+      assertFalse(ArgsAspect.before2);
+      assertFalse(ArgsAspect.before3);
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+   }
+   
+   public void test5()
+   {
+      boolean result = ArgsPOJO.field4 && true;
+      
+      assertTrue(ArgsAspect.before1);
+      assertTrue(ArgsAspect.before2);
+      assertTrue(ArgsAspect.before3);
+      assertTrue(ArgsAspect.after1);
+      assertTrue(ArgsAspect.after2);
+      assertTrue(ArgsAspect.after3);
+      assertNotNull(ArgsAspect.before2Args);
+      assertSame(ArgsAspect.before2Args, ArgsAspect.before3Args);
+      assertSame(ArgsAspect.before2Args, ArgsAspect.after2Args);
+      assertSame(ArgsAspect.before2Args, ArgsAspect.after3Args);
+      assertEquals(0, ArgsAspect.before2Args.length);
+      
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+   }
+   
+   public void test6()
+   {
+      pojo.method1("test6", 6, true, null);
+      
+      assertTrue(ArgsAspect.before3);
+      assertTrue(ArgsAspect.after3);
+      assertNotNull(ArgsAspect.before3Args);
+      assertSame(ArgsAspect.before3Args, ArgsAspect.after3Args);
+      assertEquals(4, ArgsAspect.before3Args.length);
+      assertEquals("test6", ArgsAspect.before3Args[0]);
+      assertEquals(6, ((Integer) ArgsAspect.before3Args[1]).intValue());
+      assertEquals(true, ((Boolean) ArgsAspect.before3Args[2]).booleanValue());
+      assertNull(ArgsAspect.before3Args[3]);
+      
+      assertFalse(ArgsAspect.before1);
+      assertFalse(ArgsAspect.before2);
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.after1);
+      assertFalse(ArgsAspect.after2);
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+   }
+   
+   public void test7()
+   {
+      pojo.method2("test7", 0, false, null);
+      assertTrue(ArgsAspect.before7);
+      assertTrue(ArgsAspect.after7);
+      assertTrue(ArgsAspect.around1);
+      
+      assertNotNull(ArgsAspect.before7Args);
+      assertSame(ArgsAspect.before7Args, ArgsAspect.after7Args);
+      assertEquals(4, ArgsAspect.before7Args.length);
+      assertEquals("after7", ArgsAspect.before7Args[0]);
+      assertEquals(14, ((Integer) ArgsAspect.before7Args[1]).intValue());
+      assertEquals(false, ((Boolean) ArgsAspect.before7Args[2]).booleanValue());
+      
+      assertNotNull(ArgsAspect.before7Args[3]);
+      assertEquals(1, ((ArgsPOJO[]) ArgsAspect.before7Args[3]).length);
+      assertNull(((ArgsPOJO[]) ArgsAspect.before7Args[3])[0]);
+      
+      assertNotNull(ArgsAspect.around1Args);
+      assertEquals(4, ArgsAspect.around1Args.length);
+      assertEquals("before7", ArgsAspect.around1Args[0]);
+      assertEquals(7, ((Integer) ArgsAspect.around1Args[1]).intValue());
+      assertEquals(true, ((Boolean) ArgsAspect.around1Args[2]).booleanValue());
+      
+      assertNotNull(ArgsAspect.around1Args[3]);
+      assertEquals(0, ((ArgsPOJO[]) ArgsAspect.around1Args[3]).length);
+      
+      assertFalse(ArgsAspect.before1);
+      assertFalse(ArgsAspect.before2);
+      assertFalse(ArgsAspect.before3);
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.after1);
+      assertFalse(ArgsAspect.after2);
+      assertFalse(ArgsAspect.after3);
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.around2);
+      assertFalse(ArgsAspect.throwing);
+   }
+   
+   public void test8()
+   {
+      try
+      {
+         pojo.method3((short) 0, 100);
+      }
+      catch(POJOException e)
+      {}
+      assertTrue(ArgsAspect.throwing);
+      assertNotNull(ArgsAspect.throwingArgs);
+      assertEquals(2, ArgsAspect.throwingArgs.length);
+      assertEquals(0, ((Short) ArgsAspect.throwingArgs[0]).shortValue());
+      assertEquals(100, ((Long) ArgsAspect.throwingArgs[1]).longValue());
+      
+      assertFalse(ArgsAspect.before1);
+      assertFalse(ArgsAspect.before2);
+      assertFalse(ArgsAspect.before3);
+      assertFalse(ArgsAspect.before6);
+      assertFalse(ArgsAspect.before7);
+      assertFalse(ArgsAspect.before8);
+      assertFalse(ArgsAspect.after1);
+      assertFalse(ArgsAspect.after2);
+      assertFalse(ArgsAspect.after3);
+      assertFalse(ArgsAspect.after6);
+      assertFalse(ArgsAspect.after7);
+      assertFalse(ArgsAspect.after8);
+      assertFalse(ArgsAspect.around1);
+      assertFalse(ArgsAspect.around2);
+   }
+   
+   public void test9()
+   {
+      try
+      {
+         pojo.method4();
+      } catch (POJOException e)
+      {}
+   }
+}
\ No newline at end of file



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 11:19:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 11:19:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r59151 - in trunk/ejb3: .
	src/main/org/jboss/ejb3 src/main/org/jboss/ejb3/interceptor
	src/main/org/jboss/ejb3/metamodel src/resources/test
	src/resources/test/interceptors3
	src/resources/test/interceptors3/META-INF
	src/test/org/jboss/ejb3/test
	src/test/org/jboss/ejb3/test/interceptors3
	src/test/org/jboss/ejb3/test/interceptors3/unit
Message-ID: <E1Gwhgl-0005tA-QB@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-19 11:19:17 -0500 (Tue, 19 Dec 2006)
New Revision: 59151

Added:
   trunk/ejb3/src/resources/test/interceptors3/
   trunk/ejb3/src/resources/test/interceptors3/META-INF/
   trunk/ejb3/src/resources/test/interceptors3/META-INF/ejb-jar.xml
   trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/
   trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyBean.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyInterceptor.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyRemoteIF.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/unit/
   trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/unit/InterceptorsTestCase.java
Modified:
   trunk/ejb3/build-test.xml
   trunk/ejb3/src/main/org/jboss/ejb3/Ejb3DescriptorHandler.java
   trunk/ejb3/src/main/org/jboss/ejb3/interceptor/InterceptorInfoRepository.java
   trunk/ejb3/src/main/org/jboss/ejb3/metamodel/InterceptorBinding.java
Log:
fix TCK ejb30/assembly

Modified: trunk/ejb3/build-test.xml
===================================================================
--- trunk/ejb3/build-test.xml	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/build-test.xml	2006-12-19 16:19:17 UTC (rev 59151)
@@ -930,6 +930,29 @@
 
    </target>
 
+   <target name="interceptors3"
+      description="Builds all jar files."
+      depends="compile-classes">
+
+      <mkdir dir="${build.lib}"/>
+
+      <jar jarfile="${build.lib}/interceptors3-test.jar">
+         <fileset dir="${build.classes}">
+            <include name="org/jboss/ejb3/test/interceptors3/*.class"/>
+         </fileset>
+         <fileset dir="${resources}/test/interceptors3">
+            <include name="META-INF/ejb-jar.xml"/>
+            <include name="META-INF/jboss.xml"/>
+         </fileset>
+      </jar>
+      <copy todir="${build.lib}">
+         <fileset dir="${resources}/test/interceptors3">
+            <include name="*.xml"/>
+         </fileset>
+      </copy>
+
+   </target>
+
    <target name="clientinterceptor"
       description="Builds all jar files."
       depends="compile-classes">
@@ -1800,6 +1823,13 @@
             <include name="org/jboss/ejb3/test/wolfc/*.class"/>
          </fileset>
       </jar>
+      
+      <ear destfile="${build.lib}/wolfc.ear" appxml="${build.resources}/test/wolfc/application.xml">
+         <zipfileset prefix="META-INF" dir="${build.resources}/test/wolfc">
+            <include name="jboss-app.xml"/>
+         </zipfileset>
+         <fileset dir="${build.lib}" includes="wolfc.jar"/>
+      </ear>
    </target>
 
    <target name="scopedclassloader"
@@ -2828,7 +2858,7 @@
       entityexception, asynchronous, consumer, clusteredentity, secondary, stateful, service, lob, cache, initial, 
       timer, benchmark, entity, joininheritance, singletable, tableperclass, dependent, mdb, manytomany, regression, 
       composite, composite2, entitycallback, relationships, ssl, ssladvanced, clusteredsession, strictpool, jacc, 
-      localcall, interceptors, interceptors2, iiop, clientinterceptor"/>
+      localcall, interceptors, interceptors2, interceptors3, iiop, clientinterceptor"/>
 
    <target name="test" depends="init" if="test"
       description="Execute all tests in the given test directory.">
@@ -3397,6 +3427,9 @@
          <param name="test" value="interceptors2"/>
       </antcall>
       <antcall target="test" inheritRefs="true">
+         <param name="test" value="interceptors3"/>
+      </antcall>
+      <antcall target="test" inheritRefs="true">
          <param name="test" value="interceptors"/>
       </antcall>
       <antcall target="test" inheritRefs="true">

Modified: trunk/ejb3/src/main/org/jboss/ejb3/Ejb3DescriptorHandler.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/Ejb3DescriptorHandler.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/main/org/jboss/ejb3/Ejb3DescriptorHandler.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -894,10 +894,13 @@
             .getInterceptorBindings();
       for (InterceptorBinding binding : interceptorBindings)
       {
+         // Wolf: why ignore ordered binding?
+         /*
          if (binding.isOrdered())
          {
             continue;
          }
+         */
          if (binding.getEjbName().equals(ejbName))
          {
             if (binding.getMethodName() == null

Modified: trunk/ejb3/src/main/org/jboss/ejb3/interceptor/InterceptorInfoRepository.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/interceptor/InterceptorInfoRepository.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/main/org/jboss/ejb3/interceptor/InterceptorInfoRepository.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -846,7 +846,7 @@
       boolean initialised;
       List<InterceptorBinding> orderedBindings;
       
-      void initialise()
+      private void initialise()
       {
          if (!initialised)
          {
@@ -859,7 +859,7 @@
                      if (binding.isOrdered())
                      {
                         //Validate each interceptor only occurs once
-                        HashSet names = new HashSet();
+                        HashSet<String> names = new HashSet<String>();
                         for (Iterator it = binding.getInterceptorClasses().iterator() ; it.hasNext() ; )
                         {
                            String className = (String)it.next();
@@ -880,6 +880,7 @@
                   }
                }
             }
+            log.trace("orderedBindings = " + orderedBindings);
             initialised = true;
          }
       }

Modified: trunk/ejb3/src/main/org/jboss/ejb3/metamodel/InterceptorBinding.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/metamodel/InterceptorBinding.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/main/org/jboss/ejb3/metamodel/InterceptorBinding.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -91,6 +91,14 @@
       return ordered;
    }
 
-   
-   
+   public String toString()
+   {
+      return InterceptorBinding.class.getName() + "[ejbName=" + getEjbName() +
+         ",methodName=" + getMethodName() +
+         ",ordered=" + isOrdered() + 
+         ",excludeClassInterceptors=" + excludeClassInterceptors + 
+         ",excludeDefaultInterceptors=" + excludeDefaultInterceptors +
+         ",interceptorClasses=" + interceptorClasses +
+         "]";
+   }
 }

Added: trunk/ejb3/src/resources/test/interceptors3/META-INF/ejb-jar.xml
===================================================================
--- trunk/ejb3/src/resources/test/interceptors3/META-INF/ejb-jar.xml	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/resources/test/interceptors3/META-INF/ejb-jar.xml	2006-12-19 16:19:17 UTC (rev 59151)
@@ -0,0 +1,42 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" metadata-complete="false" version="3.0" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd">
+    <enterprise-beans>
+        <session>
+            <ejb-name>AssemblyBean</ejb-name>
+            <!--business-local>com.sun.ts.tests.ejb30.assembly.common.AssemblyLocalIF</business-local-->
+            <business-remote>org.jboss.ejb3.test.interceptors3.AssemblyRemoteIF</business-remote>
+            <ejb-class>org.jboss.ejb3.test.interceptors3.AssemblyBean</ejb-class>
+            <session-type>Stateless</session-type>
+            <transaction-type>Container</transaction-type>
+            <security-identity>
+                <use-caller-identity/>
+            </security-identity>
+        </session>
+    </enterprise-beans>
+    <interceptors>
+        <interceptor>
+            <interceptor-class>org.jboss.ejb3.test.interceptors3.AssemblyInterceptor</interceptor-class>
+            <!-- already annotated in class
+            <around-invoke>
+                <method-name>intercept</method-name>
+            </around-invoke>
+            <post-construct>
+                <lifecycle-callback-method>myCreate</lifecycle-callback-method>
+            </post-construct>
+            <pre-destroy>
+                <lifecycle-callback-method>myRemove</lifecycle-callback-method>
+            </pre-destroy>
+            -->
+        </interceptor>
+    </interceptors>
+
+    <assembly-descriptor>
+        <interceptor-binding>
+            <ejb-name>AssemblyBean</ejb-name>
+            <interceptor-order>
+                <interceptor-class>org.jboss.ejb3.test.interceptors3.AssemblyInterceptor</interceptor-class>
+            </interceptor-order>
+        </interceptor-binding>
+    </assembly-descriptor>
+
+</ejb-jar>

Added: trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyBean.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyBean.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyBean.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -0,0 +1,38 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.test.interceptors3;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+//@Interceptors({AssemblyInterceptor.class})    // this works, xml doesn't
+public class AssemblyBean implements AssemblyRemoteIF
+{
+   public int remoteAdd(int a, int b)
+   {
+      return a + b;
+   }
+
+}

Added: trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyInterceptor.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyInterceptor.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyInterceptor.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -0,0 +1,43 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.test.interceptors3;
+
+import javax.interceptor.AroundInvoke;
+import javax.interceptor.InvocationContext;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class AssemblyInterceptor
+{
+   @AroundInvoke
+   protected Object intercept(InvocationContext inv) throws Exception
+   {
+      Object params[] = inv.getParameters();
+      Object newParams[] = { (Integer) params[0] + 100, (Integer) params[1] + 100 };
+      inv.setParameters(newParams);
+      return inv.proceed();
+   }
+}

Added: trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyRemoteIF.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyRemoteIF.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyRemoteIF.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -0,0 +1,30 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.test.interceptors3;
+
+import javax.ejb.Remote;
+
+ at Remote
+public interface AssemblyRemoteIF
+{
+   int remoteAdd(int a, int b);
+}


Property changes on: trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/AssemblyRemoteIF.java
___________________________________________________________________
Name: svn:executable
   + *

Added: trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/unit/InterceptorsTestCase.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/unit/InterceptorsTestCase.java	2006-12-19 15:32:09 UTC (rev 59150)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/interceptors3/unit/InterceptorsTestCase.java	2006-12-19 16:19:17 UTC (rev 59151)
@@ -0,0 +1,53 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.test.interceptors3.unit;
+
+import junit.framework.Test;
+
+import org.jboss.ejb3.test.interceptors3.AssemblyRemoteIF;
+import org.jboss.test.JBossTestCase;
+
+/**
+ * From TCK: ejb30/assembly/librarydirectory/defaultname
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class InterceptorsTestCase extends JBossTestCase
+{
+   public InterceptorsTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testIntercept() throws Exception
+   {
+      AssemblyRemoteIF bean = (AssemblyRemoteIF) getInitialContext().lookup("AssemblyBean/remote");
+      int actual = bean.remoteAdd(1, 2);
+      assertEquals(203, actual);
+   }
+   
+   public static Test suite() throws Exception
+   {
+      return getDeploySetup(InterceptorsTestCase.class, "interceptors3-test.jar");
+   }
+}
\ No newline at end of file



From norman.richards at jboss.com  Tue Dec 19 11:23:38 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 19 Dec 2006 11:23:38 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util  ...
Message-ID: <E1Gwhkg-0005yL-2C@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/19 11:23:38

  Modified:    src/main/org/jboss/seam/util  Conversions.java
  Log:
  allow bigdecimal input in components.xml
  
  Revision  Changes    Path
  1.9       +22 -2     jboss-seam/src/main/org/jboss/seam/util/Conversions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Conversions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Conversions.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- Conversions.java	21 Nov 2006 05:17:13 -0000	1.8
  +++ Conversions.java	19 Dec 2006 16:23:38 -0000	1.9
  @@ -11,6 +11,9 @@
   import java.util.Properties;
   import java.util.Set;
   
  +import java.math.BigInteger;
  +import java.math.BigDecimal;
  +
   public class Conversions
   {
      
  @@ -36,8 +39,8 @@
         //put(Date.class, new DateTimeConverter());
         //put(Short.class, new ShortConverter());
         //put(Byte.class, new ByteConverter());
  -      //put(BigInteger.class, new BigIntegerConverter());
  -      //put(BigDecimal.class, new BigDecimalConverter());
  +      put(BigInteger.class, new BigIntegerConverter());
  +      put(BigDecimal.class, new BigDecimalConverter());
         put(Class.class, new ClassConverter());
      }};
      
  @@ -117,6 +120,23 @@
         }
      }
      
  +   public static class BigDecimalConverter implements Converter<BigDecimal>
  +   {
  +      public BigDecimal toObject(PropertyValue value, Type type)
  +      {
  +         return new BigDecimal(value.getSingleValue());
  +      }
  +   }
  +
  +   public static class BigIntegerConverter implements Converter<BigInteger>
  +   {
  +      public BigInteger toObject(PropertyValue value, Type type)
  +      {
  +         return new BigInteger(value.getSingleValue());
  +      }
  +   }
  + 
  +   
      public static class StringArrayConverter implements Converter<String[]>
      {
         public String[] toObject(PropertyValue values, Type type)
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 11:26:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 11:26:30 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1824 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GwhnS-00062I-SS@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 11:26:29 -0500 (Tue, 19 Dec 2006)
New Revision: 1824

Modified:
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
Log:
no major modifications.. just removing unused comments

Modified: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-19 06:51:01 UTC (rev 1823)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-19 16:26:29 UTC (rev 1824)
@@ -58,8 +58,6 @@
 
    private ClientConnectionDelegate delegate;
 
-   // alternative implementation
-   //private Valve valve = new Valve();
    private ReadWriteLock lockValve;
 
    ValveAspect(ClientConnectionDelegate delegate, HAAspect copy)
@@ -102,18 +100,6 @@
             log.info("Retrying a call " + i);
          }
 
-
-         // An alternate way of playing with Valves is to set an attribute to true
-         // and wait for notifications until it's being set. Valve encpasulates this logic
-         //  if (i > 0)
-         //  {
-         //     valve.open(true);
-         //  }
-         //  else
-         //  {
-         //     valve.isOpened(true);
-         //  }
-
          // We shouldn't have any calls being made while the failover is being executed
          if (i > 0)
          {
@@ -148,12 +134,6 @@
          }
          finally
          {
-            // An alternate way of playing with Valves is to set an attribute to true
-            // and wait for notifications until it's being set. Valve encpasulates this logic
-            //if (i>0)
-            //{
-            //   valve.reset();
-            //}
             if (i > 0)
             {
                lockValve.writeLock().release();
@@ -204,13 +184,6 @@
       // only one execution should be performed if multiple exceptions happened at the same time
       lockValve.writeLock().acquire();
 
-      // An alternate way of playing with Valves is to set an attribute to true
-      // and wait for notifications until it's being set. Valve encpasulates this logic
-//      if (!valve.open())
-//      {
-//         return;
-//      }
-
       try
       {
          if (jmsConnection.isFailed())
@@ -231,10 +204,6 @@
       }
       finally
       {
-         // An alternate way of playing with Valves is to set an attribute to true
-         // and wait for notifications until it's being set. Valve encpasulates this logic
-//         valve.close();
-//         valve = new Valve();
          lockValve.writeLock().release();
       }
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 11:42:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 11:42:07 -0500
Subject: [jboss-cvs] JBossAS SVN: r59152 - in
	trunk/server/src/main/org/jboss: deployment metadata
	webservice/metadata/serviceref
Message-ID: <E1Gwi2Z-0006IJ-5C@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-19 11:42:01 -0500 (Tue, 19 Dec 2006)
New Revision: 59152

Modified:
   trunk/server/src/main/org/jboss/deployment/ClientDeployer.java
   trunk/server/src/main/org/jboss/metadata/ApplicationMetaData.java
   trunk/server/src/main/org/jboss/metadata/BeanMetaData.java
   trunk/server/src/main/org/jboss/metadata/ClientMetaData.java
   trunk/server/src/main/org/jboss/metadata/DDObjectFactory.java
   trunk/server/src/main/org/jboss/metadata/MetaData.java
   trunk/server/src/main/org/jboss/metadata/XmlFileLoader.java
   trunk/server/src/main/org/jboss/webservice/metadata/serviceref/HandlerMetaData.java
   trunk/server/src/main/org/jboss/webservice/metadata/serviceref/PortComponentRefMetaData.java
   trunk/server/src/main/org/jboss/webservice/metadata/serviceref/ServiceRefMetaData.java
Log:
Remove dependency on resourceLoader
Remove dependency on deprecated DeploymentException
[JBCTS-481] Fix jaxrpc/api/javax_xml_rpc/Stub

Modified: trunk/server/src/main/org/jboss/deployment/ClientDeployer.java
===================================================================
--- trunk/server/src/main/org/jboss/deployment/ClientDeployer.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/deployment/ClientDeployer.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -171,7 +171,6 @@
          Element appClient = xfl.getDocument(in, "application-client.xml").getDocumentElement();
          in.close();
          metaData = new ClientMetaData();
-         metaData.setResourceClassLoader((URLClassLoader)unit.getClassLoader());
          metaData.importClientXml(appClient);
 
          // Look for a jboss-client.xml descriptor

Modified: trunk/server/src/main/org/jboss/metadata/ApplicationMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/ApplicationMetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/metadata/ApplicationMetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -1,35 +1,27 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.metadata;
 
-import org.jboss.deployment.DeploymentException;
-import org.jboss.mx.util.MBeanServerLocator;
-import org.w3c.dom.DocumentType;
-import org.w3c.dom.Element;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
 import java.net.URL;
-import java.net.URLClassLoader;
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.HashSet;
@@ -37,6 +29,14 @@
 import java.util.Map;
 import java.util.Set;
 
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+
+import org.jboss.deployment.DeploymentException;
+import org.jboss.mx.util.MBeanServerLocator;
+import org.w3c.dom.DocumentType;
+import org.w3c.dom.Element;
+
 /**
  * The top level meta data from the jboss.xml and ejb-jar.xml descriptor.
  *
@@ -49,8 +49,7 @@
  *
  * @version $Revision$
  */
-public class ApplicationMetaData
-   extends MetaData
+public class ApplicationMetaData extends MetaData
 {
    public static final int EJB_1x = 1;
    public static final int EJB_2x = 2;
@@ -100,26 +99,10 @@
    /** The JACC context id for the container */
    private String jaccContextID;
 
-
-   /** The ClassLoader to load additional resources */
-   private URLClassLoader resourceCl;
-
    public ApplicationMetaData()
    {
    }
 
-   /** Get the ClassLoader to load additional resources */
-   public URLClassLoader getResourceCl()
-   {
-      return resourceCl;
-   }
-
-   /** Set the ClassLoader to load additional resources */
-   public void setResourceClassLoader(URLClassLoader resourceCl)
-   {
-      this.resourceCl = resourceCl;
-   }
-
    public String getDescription()
    {
       return description;
@@ -283,6 +266,7 @@
    {
       relationships.add(rmd);
    }
+
    /**
     * Get the container managed relations in this application.
     * Items are instance of RelationMetaData.
@@ -311,6 +295,7 @@
    {
       invokerBindings.put(md.getName(), md);
    }
+
    public Iterator getInvokerProxyBindings()
    {
       return invokerBindings.values().iterator();
@@ -346,6 +331,7 @@
    {
       return jmxName;
    }
+
    public void setJmxName(String name)
    {
       this.jmxName = name;
@@ -355,6 +341,7 @@
    {
       return jaccContextID;
    }
+
    public void setJaccContextID(String jaccContextID)
    {
       this.jaccContextID = jaccContextID;
@@ -412,6 +399,7 @@
    {
       return exceptionRollback;
    }
+
    public void setExceptionRollback(boolean flag)
    {
       this.exceptionRollback = flag;
@@ -428,8 +416,7 @@
     * @throws DeploymentException When there was an error encountered
     *         while parsing ejb-jar.xml
     */
-   public void importEjbJarXml(Element element)
-      throws DeploymentException
+   public void importEjbJarXml(Element element) throws DeploymentException
    {
       // EJB version is determined by the doc type that was used to
       // verify the ejb-jar.xml.
@@ -446,8 +433,7 @@
          else
          {
             // No good, EJB 1.1/2.1 requires a DOCTYPE declaration
-            throw new DeploymentException("ejb-jar.xml must either obey " +
-               "the right xml schema or define a valid DOCTYPE!");
+            throw new DeploymentException("ejb-jar.xml must either obey " + "the right xml schema or define a valid DOCTYPE!");
          }
       }
       else
@@ -456,8 +442,7 @@
          if (publicId == null)
          {
             // We need a public Id
-            throw new DeploymentException("The DOCTYPE declaration in " +
-               "ejb-jar.xml must define a PUBLIC id");
+            throw new DeploymentException("The DOCTYPE declaration in " + "ejb-jar.xml must define a PUBLIC id");
          }
 
          // Check for a known public Id
@@ -472,8 +457,7 @@
          else
          {
             // Unknown
-            throw new DeploymentException("Unknown PUBLIC id in " +
-               "ejb-jar.xml: " + publicId);
+            throw new DeploymentException("Unknown PUBLIC id in " + "ejb-jar.xml: " + publicId);
          }
       }
 
@@ -493,9 +477,7 @@
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in ejb-jar.xml " +
-               "for Entity Bean " + entityMetaData.getEjbName() + ": " +
-               e.getMessage());
+            throw new DeploymentException("Error in ejb-jar.xml " + "for Entity Bean " + entityMetaData.getEjbName() + ": " + e.getMessage());
          }
 
          // Ensure unique-ness of <abstract-schema-name>
@@ -505,10 +487,8 @@
             if (schemaNameMap.containsKey(abstractSchemaName))
             {
                //
-               throw new DeploymentException(entityMetaData.getEjbName() +
-                  ": Duplicate abstract-schema name '" + abstractSchemaName +
-                  "'. Already defined for Entity '" +
-                  ((EntityMetaData)schemaNameMap.get(abstractSchemaName)).getEjbName() + "'.");
+               throw new DeploymentException(entityMetaData.getEjbName() + ": Duplicate abstract-schema name '" + abstractSchemaName
+                     + "'. Already defined for Entity '" + ((EntityMetaData)schemaNameMap.get(abstractSchemaName)).getEjbName() + "'.");
             }
             schemaNameMap.put(abstractSchemaName, entityMetaData);
          }
@@ -528,9 +508,7 @@
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in ejb-jar.xml for " +
-               "Session Bean " + sessionMetaData.getEjbName() + ": " +
-               e.getMessage());
+            throw new DeploymentException("Error in ejb-jar.xml for " + "Session Bean " + sessionMetaData.getEjbName() + ": " + e.getMessage());
          }
          beans.add(sessionMetaData);
       }
@@ -540,8 +518,7 @@
       while (iterator.hasNext())
       {
          Element currentMessageDriven = (Element)iterator.next();
-         MessageDrivenMetaData messageDrivenMetaData =
-            new MessageDrivenMetaData(this);
+         MessageDrivenMetaData messageDrivenMetaData = new MessageDrivenMetaData(this);
 
          try
          {
@@ -549,9 +526,7 @@
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in ejb-jar.xml for " +
-               "Message Driven Bean " +
-               messageDrivenMetaData.getEjbName() + ": " + e.getMessage());
+            throw new DeploymentException("Error in ejb-jar.xml for " + "Message Driven Bean " + messageDrivenMetaData.getEjbName() + ": " + e.getMessage());
          }
          beans.add(messageDrivenMetaData);
       }
@@ -566,23 +541,20 @@
          String beanName = bmd.getEjbName();
          if (ejbNames.contains(beanName))
          {
-            throw new DeploymentException("Duplicate definition of an " +
-               "EJB with name '" + beanName + "'.");
+            throw new DeploymentException("Duplicate definition of an " + "EJB with name '" + beanName + "'.");
          }
 
          ejbNames.add(beanName);
       }
 
       // Relationships
-      Element relationshipsElement = getOptionalChild(element,
-         "relationships");
+      Element relationshipsElement = getOptionalChild(element, "relationships");
       if (relationshipsElement != null)
       {
          // used to assure that a relationship name is not reused
          Set relationNames = new HashSet();
 
-         iterator = getChildrenByTagName(relationshipsElement,
-            "ejb-relation");
+         iterator = getChildrenByTagName(relationshipsElement, "ejb-relation");
          while (iterator.hasNext())
          {
             Element relationElement = (Element)iterator.next();
@@ -593,9 +565,7 @@
             }
             catch (DeploymentException e)
             {
-               throw new DeploymentException("Error in ejb-jar.xml " +
-                  "for relation " + relationMetaData.getRelationName() +
-                  ": " + e.getMessage());
+               throw new DeploymentException("Error in ejb-jar.xml " + "for relation " + relationMetaData.getRelationName() + ": " + e.getMessage());
             }
 
             // if the relationship has a name, assure that it has not
@@ -605,9 +575,7 @@
             {
                if (relationNames.contains(relationName))
                {
-                  throw new DeploymentException("ejb-relation-name must " +
-                     "be unique in ejb-jar.xml file: ejb-relation-name is " +
-                     relationName);
+                  throw new DeploymentException("ejb-relation-name must " + "be unique in ejb-jar.xml file: ejb-relation-name is " + relationName);
                }
                relationNames.add(relationName);
             }
@@ -625,30 +593,20 @@
          while (iterator.hasNext())
          {
             Element securityRole = (Element)iterator.next();
-            try
-            {
-               String roleName = getElementContent(getUniqueChild(securityRole, "role-name"));
-               SecurityRoleMetaData srMetaData = new SecurityRoleMetaData(roleName);
-               assemblyDescriptor.addSecurityRoleMetaData(srMetaData);
-            }
-            catch (DeploymentException e)
-            {
-               throw new DeploymentException("Error in ejb-jar.xml " +
-                  "for security-role: " + e.getMessage());
-            }
+            String roleName = getElementContent(getUniqueChild(securityRole, "role-name"));
+            SecurityRoleMetaData srMetaData = new SecurityRoleMetaData(roleName);
+            assemblyDescriptor.addSecurityRoleMetaData(srMetaData);
          }
 
          // set the method permissions (optional)
-         iterator = getChildrenByTagName(descrElement,
-            "method-permission");
+         iterator = getChildrenByTagName(descrElement, "method-permission");
          try
          {
             while (iterator.hasNext())
             {
                Element methodPermission = (Element)iterator.next();
                // Look for the unchecked element
-               Element unchecked = getOptionalChild(methodPermission,
-                  "unchecked");
+               Element unchecked = getOptionalChild(methodPermission, "unchecked");
 
                boolean isUnchecked = false;
                Set roles = null;
@@ -666,14 +624,11 @@
                      roles.add(getElementContent((Element)rolesIterator.next()));
                   }
                   if (roles.size() == 0)
-                     throw new DeploymentException("An unchecked " +
-                        "element or one or more role-name elements " +
-                        "must be specified in method-permission");
+                     throw new DeploymentException("An unchecked " + "element or one or more role-name elements " + "must be specified in method-permission");
                }
 
                // find the methods
-               Iterator methods = getChildrenByTagName(methodPermission,
-                  "method");
+               Iterator methods = getChildrenByTagName(methodPermission, "method");
                while (methods.hasNext())
                {
                   // load the method
@@ -692,8 +647,7 @@
                   BeanMetaData bean = getBeanByEjbName(method.getEjbName());
                   if (bean == null)
                   {
-                     throw new DeploymentException(method.getEjbName() +
-                        " doesn't exist");
+                     throw new DeploymentException(method.getEjbName() + " doesn't exist");
                   }
                   bean.addPermissionMethod(method);
                }
@@ -701,13 +655,11 @@
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in ejb-jar.xml, " +
-               "in method-permission: " + e.getMessage());
+            throw new DeploymentException("Error in ejb-jar.xml, " + "in method-permission: " + e.getMessage());
          }
 
          // set the container transactions (optional)
-         iterator = getChildrenByTagName(descrElement,
-            "container-transaction");
+         iterator = getChildrenByTagName(descrElement, "container-transaction");
          try
          {
             while (iterator.hasNext())
@@ -731,8 +683,7 @@
                   BeanMetaData bean = getBeanByEjbName(method.getEjbName());
                   if (bean == null)
                   {
-                     throw new DeploymentException("bean " +
-                        method.getEjbName() + " doesn't exist");
+                     throw new DeploymentException("bean " + method.getEjbName() + " doesn't exist");
                   }
                   bean.addTransactionMethod(method);
                }
@@ -740,13 +691,11 @@
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in ejb-jar.xml, " +
-               "in <container-transaction>: " + e.getMessage());
+            throw new DeploymentException("Error in ejb-jar.xml, " + "in <container-transaction>: " + e.getMessage());
          }
 
          // Get the exclude-list methods
-         Element excludeList = getOptionalChild(descrElement,
-            "exclude-list");
+         Element excludeList = getOptionalChild(descrElement, "exclude-list");
          if (excludeList != null)
          {
             iterator = getChildrenByTagName(excludeList, "method");
@@ -762,8 +711,7 @@
                BeanMetaData bean = getBeanByEjbName(method.getEjbName());
                if (bean == null)
                {
-                  throw new DeploymentException("bean " +
-                     method.getEjbName() + " doesn't exist");
+                  throw new DeploymentException("bean " + method.getEjbName() + " doesn't exist");
                }
                bean.addExcludedMethod(method);
             }
@@ -782,15 +730,13 @@
             }
             catch (Throwable t)
             {
-               throw new DeploymentException("Error in ejb-jar.xml " +
-                  "for message destination: " + t.getMessage());
+               throw new DeploymentException("Error in ejb-jar.xml " + "for message destination: " + t.getMessage());
             }
          }
       }
    }
 
-   public void importJbossXml(Element element)
-      throws DeploymentException
+   public void importJbossXml(Element element) throws DeploymentException
    {
       Iterator iterator;
 
@@ -805,8 +751,7 @@
       }
 
       // Get any user defined JMX name
-      Element jmxNameElement = getOptionalChild(element,
-         "jmx-name");
+      Element jmxNameElement = getOptionalChild(element, "jmx-name");
       if (jmxNameElement != null)
       {
          jmxName = getElementContent(jmxNameElement);
@@ -816,20 +761,17 @@
       exceptionRollback = MetaData.getOptionalChildBooleanContent(element, "exception-on-rollback", false);
 
       // Get the security domain name
-      Element securityDomainElement = getOptionalChild(element,
-         "security-domain");
+      Element securityDomainElement = getOptionalChild(element, "security-domain");
       if (securityDomainElement != null)
       {
          securityDomain = getElementContent(securityDomainElement);
       }
 
       // Get the missing-method-permissions-excluded-mode flag
-      excludeMissingMethods = MetaData.getOptionalChildBooleanContent(element,
-         "missing-method-permissions-excluded-mode", true);
+      excludeMissingMethods = MetaData.getOptionalChildBooleanContent(element, "missing-method-permissions-excluded-mode", true);
 
       // Get the unauthenticated-principal name
-      Element unauth = getOptionalChild(element,
-         "unauthenticated-principal");
+      Element unauth = getOptionalChild(element, "unauthenticated-principal");
       if (unauth != null)
       {
          unauthenticatedPrincipal = getElementContent(unauth);
@@ -840,12 +782,10 @@
       }
 
       // find the invoker configurations
-      Element invokerConfs = getOptionalChild(element,
-         "invoker-proxy-bindings");
+      Element invokerConfs = getOptionalChild(element, "invoker-proxy-bindings");
       if (invokerConfs != null)
       {
-         iterator = getChildrenByTagName(invokerConfs,
-            "invoker-proxy-binding");
+         iterator = getChildrenByTagName(invokerConfs, "invoker-proxy-binding");
 
          while (iterator.hasNext())
          {
@@ -854,8 +794,7 @@
 
             // find the configuration if it has already been defined
             // (allow jboss.xml to modify a standard conf)
-            InvokerProxyBindingMetaData invokerMetaData =
-               getInvokerProxyBindingMetaDataByName(invokerName);
+            InvokerProxyBindingMetaData invokerMetaData = getInvokerProxyBindingMetaDataByName(invokerName);
 
             // create it if necessary
             if (invokerMetaData == null)
@@ -870,9 +809,7 @@
             }
             catch (DeploymentException e)
             {
-               throw new DeploymentException("Error in jboss.xml " +
-                  "for invoker-proxy-binding " + invokerMetaData.getName() +
-                  ": " + e.getMessage());
+               throw new DeploymentException("Error in jboss.xml " + "for invoker-proxy-binding " + invokerMetaData.getName() + ": " + e.getMessage());
             }
          }
       }
@@ -887,8 +824,7 @@
          while (iterator.hasNext())
          {
             Element conf = (Element)iterator.next();
-            String confName = getElementContent(getUniqueChild(conf,
-               "container-name"));
+            String confName = getElementContent(getUniqueChild(conf, "container-name"));
             String parentConfName = conf.getAttribute("extends");
             if (parentConfName != null && parentConfName.trim().length() == 0)
             {
@@ -906,20 +842,17 @@
                configurationMetaData = getConfigurationMetaDataByName(parentConfName);
                if (configurationMetaData == null)
                {
-                  throw new DeploymentException("Failed to find " +
-                     "parent config=" + parentConfName);
+                  throw new DeploymentException("Failed to find " + "parent config=" + parentConfName);
                }
 
                // Make a copy of the existing configuration
-               configurationMetaData =
-                  (ConfigurationMetaData)configurationMetaData.clone();
+               configurationMetaData = (ConfigurationMetaData)configurationMetaData.clone();
                configurations.put(confName, configurationMetaData);
             }
 
             if (configurationMetaData == null)
             {
-               configurationMetaData =
-                  getConfigurationMetaDataByName(confName);
+               configurationMetaData = getConfigurationMetaDataByName(confName);
             }
 
             // Create a new configuration if none was found
@@ -935,9 +868,7 @@
             }
             catch (DeploymentException e)
             {
-               throw new DeploymentException("Error in jboss.xml " +
-                  "for container-configuration " +
-                  configurationMetaData.getName() + ": " + e.getMessage());
+               throw new DeploymentException("Error in jboss.xml " + "for container-configuration " + configurationMetaData.getName() + ": " + e.getMessage());
             }
          }
       }
@@ -979,8 +910,7 @@
                BeanMetaData beanMetaData = getBeanByEjbName(ejbName);
                if (beanMetaData == null)
                {
-                  throw new DeploymentException("found in jboss.xml " +
-                     "but not in ejb-jar.xml");
+                  throw new DeploymentException("found in jboss.xml " + "but not in ejb-jar.xml");
                }
                beanMetaData.importJbossXml(bean);
             }
@@ -994,8 +924,7 @@
                BeanMetaData beanMetaData = getBeanByEjbName(ejbName);
                if (beanMetaData == null)
                {
-                  throw new DeploymentException("found in jboss.xml " +
-                     "but not in ejb-jar.xml");
+                  throw new DeploymentException("found in jboss.xml " + "but not in ejb-jar.xml");
                }
                beanMetaData.importJbossXml(bean);
             }
@@ -1009,16 +938,14 @@
                BeanMetaData beanMetaData = getBeanByEjbName(ejbName);
                if (beanMetaData == null)
                {
-                  throw new DeploymentException("found in jboss.xml " +
-                     "but not in ejb-jar.xml");
+                  throw new DeploymentException("found in jboss.xml " + "but not in ejb-jar.xml");
                }
                beanMetaData.importJbossXml(bean);
             }
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in jboss.xml for " +
-               "Bean " + ejbName + ": " + e.getMessage());
+            throw new DeploymentException("Error in jboss.xml for " + "Bean " + ejbName + ": " + e.getMessage());
 
             // WebserviceDescriptions
          }
@@ -1065,8 +992,7 @@
             }
             catch (Throwable t)
             {
-               throw new DeploymentException("Error in ejb-jar.xml " +
-                  "for message destination: " + t.getMessage());
+               throw new DeploymentException("Error in ejb-jar.xml " + "for message destination: " + t.getMessage());
             }
          }
       }
@@ -1097,15 +1023,13 @@
                }
                else
                {
-                  throw new DeploymentException(resName +
-                     " : expected res-url or res-jndi-name tag");
+                  throw new DeploymentException(resName + " : expected res-url or res-jndi-name tag");
                }
             }
          }
          catch (DeploymentException e)
          {
-            throw new DeploymentException("Error in jboss.xml, in " +
-               "resource-manager: " + e.getMessage());
+            throw new DeploymentException("Error in jboss.xml, in " + "resource-manager: " + e.getMessage());
          }
       }
    }
@@ -1127,13 +1051,13 @@
    public void addContainerConfiguration(ConfigurationMetaData container)
    {
       String name = container.getName();
-      if(name == null)
+      if (name == null)
       {
          throw new IllegalStateException("Container configuration must have a non-null name!");
       }
       configurations.put(name, container);
-   } 
-   
+   }
+
    /**
     * Merge the security role/principal mapping defined in jboss.xml
     * with the one defined at jboss-app.xml.
@@ -1145,5 +1069,5 @@
 }
 
 /*
-vim:ts=3:sw=3:et
-*/
+ vim:ts=3:sw=3:et
+ */

Modified: trunk/server/src/main/org/jboss/metadata/BeanMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/BeanMetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/metadata/BeanMetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -1112,7 +1112,7 @@
          Element serviceRef = (Element)iterator.next();
          if (ServiceRefMetaData.isValidDoctype(serviceRef))
          {
-            ServiceRefMetaData refMetaData = new ServiceRefMetaData(application.getResourceCl());
+            ServiceRefMetaData refMetaData = new ServiceRefMetaData();
             refMetaData.importStandardXml(serviceRef);
             serviceReferences.put(refMetaData.getServiceRefName(), refMetaData);
          }

Modified: trunk/server/src/main/org/jboss/metadata/ClientMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/ClientMetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/metadata/ClientMetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -23,16 +23,15 @@
 
 // $Id$
 
-import org.jboss.logging.Logger;
-import org.jboss.deployment.DeploymentException;
-import org.jboss.webservice.metadata.serviceref.ServiceRefMetaData;
-import org.w3c.dom.Element;
-
 import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Iterator;
-import java.net.URLClassLoader;
 
+import org.jboss.deployment.DeploymentException;
+import org.jboss.logging.Logger;
+import org.jboss.webservice.metadata.serviceref.ServiceRefMetaData;
+import org.w3c.dom.Element;
+
 /** The metdata data from a j2ee application-client.xml descriptor
  * 
  * @author Scott.Stark at jboss.org
@@ -66,15 +65,6 @@
    /** The JAAS callback handler */
    private String callbackHandler;
 
-   /** The ClassLoader to load additional resources */
-   private URLClassLoader resourceCl;
-
-   /** Set the ClassLoader to load additional resources */
-   public void setResourceClassLoader(URLClassLoader resourceCl)
-   {
-      this.resourceCl = resourceCl;
-   }
-
    /** The application-client/display-name
     * @return application-client/display-name value
     */ 
@@ -177,7 +167,7 @@
          Element serviceRef = (Element) iterator.next();
          if (ServiceRefMetaData.isValidDoctype(serviceRef))
          {
-            ServiceRefMetaData refMetaData = new ServiceRefMetaData(resourceCl);
+            ServiceRefMetaData refMetaData = new ServiceRefMetaData();
             refMetaData.importStandardXml(serviceRef);
             serviceReferences.put(refMetaData.getServiceRefName(), refMetaData);
          }

Modified: trunk/server/src/main/org/jboss/metadata/DDObjectFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/DDObjectFactory.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/metadata/DDObjectFactory.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -396,7 +396,7 @@
       }
       else if (localName.equals("jaxrpc-mapping-file"))
       {
-         ref.setJaxrpcMappingFile(getValue(localName, value));
+         ref.setMappingFile(getValue(localName, value));
       }
       else if (localName.equals("mapped-name"))
       {

Modified: trunk/server/src/main/org/jboss/metadata/MetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/MetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/metadata/MetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -1,59 +1,56 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.metadata;
 
 import java.util.ArrayList;
 import java.util.Iterator;
 
+import org.jboss.logging.Logger;
+import org.jboss.util.StringPropertyReplacer;
 import org.w3c.dom.Element;
-import org.w3c.dom.NodeList;
 import org.w3c.dom.Node;
+import org.w3c.dom.NodeList;
 
-import org.jboss.deployment.DeploymentException;
-import org.jboss.logging.Logger;
-import org.jboss.util.StringPropertyReplacer;
-
 /**
  * An abstract base class for metadata containers.
  *
  * @author <a href="mailto:sebastien.alborini at m4x.org">Sebastien Alborini</a>
  * @version $Revision$
  */
-public abstract class MetaData
-   implements Cloneable, XmlLoadable
+public abstract class MetaData implements Cloneable, XmlLoadable
 {
    // Constants -----------------------------------------------------
 
    protected static Logger log = Logger.getLogger(MetaData.class);
-   
+
    // These do not really belong here
 
-   public static final byte TX_NOT_SUPPORTED  = 0;
-   public static final byte TX_REQUIRED       = 1;
-   public static final byte TX_SUPPORTS       = 2;
-   public static final byte TX_REQUIRES_NEW   = 3;
-   public static final byte TX_MANDATORY      = 4;
-   public static final byte TX_NEVER          = 5;
-   public static final byte TX_UNKNOWN        = 6;
+   public static final byte TX_NOT_SUPPORTED = 0;
+   public static final byte TX_REQUIRED = 1;
+   public static final byte TX_SUPPORTS = 2;
+   public static final byte TX_REQUIRES_NEW = 3;
+   public static final byte TX_MANDATORY = 4;
+   public static final byte TX_NEVER = 5;
+   public static final byte TX_UNKNOWN = 6;
 
    // Attributes ----------------------------------------------------
 
@@ -67,19 +64,20 @@
     * @param tagName    The name of the desired child
     * @return           An interator of children or null if element is null.
     */
-   public static Iterator getChildrenByTagName(Element element,
-                                               String tagName)
+   public static Iterator getChildrenByTagName(Element element, String tagName)
    {
-      if (element == null) return null;
+      if (element == null)
+         return null;
       // getElementsByTagName gives the corresponding elements in the whole 
       // descendance. We want only children
 
       NodeList children = element.getChildNodes();
       ArrayList goodChildren = new ArrayList();
-      for (int i=0; i<children.getLength(); i++) {
+      for (int i = 0; i < children.getLength(); i++)
+      {
          Node currentChild = children.item(i);
-         if (currentChild.getNodeType() == Node.ELEMENT_NODE && 
-             ((Element)currentChild).getTagName().equals(tagName)) {
+         if (currentChild.getNodeType() == Node.ELEMENT_NODE && ((Element)currentChild).getTagName().equals(tagName))
+         {
             goodChildren.add(currentChild);
          }
       }
@@ -98,21 +96,22 @@
     * @throws DeploymentException   Child was not found or was not unique.
     */
    public static Element getUniqueChild(Element element, String tagName)
-      throws DeploymentException
    {
       Iterator goodChildren = getChildrenByTagName(element, tagName);
 
-      if (goodChildren != null && goodChildren.hasNext()) {
+      if (goodChildren != null && goodChildren.hasNext())
+      {
          Element child = (Element)goodChildren.next();
-         if (goodChildren.hasNext()) {
-            throw new DeploymentException
-               ("expected only one " + tagName + " tag");
+         if (goodChildren.hasNext())
+         {
+            throw new IllegalStateException("expected only one " + tagName + " tag");
          }
          return child;
-      } else {
-         throw new DeploymentException
-            ("expected one " + tagName + " tag");
       }
+      else
+      {
+         throw new IllegalStateException("expected one " + tagName + " tag");
+      }
    }
 
    /**
@@ -125,7 +124,6 @@
     * @return either the named child or null
     */
    public static Element getOptionalChild(Element element, String tagName)
-      throws DeploymentException
    {
       return getOptionalChild(element, tagName, null);
    }
@@ -141,21 +139,21 @@
     *                       doesn't exist
     * @return either the named child or the supplied default
     */
-   public static Element getOptionalChild(Element element,
-                                          String tagName,
-                                          Element defaultElement)
-      throws DeploymentException
+   public static Element getOptionalChild(Element element, String tagName, Element defaultElement)
    {
       Iterator goodChildren = getChildrenByTagName(element, tagName);
 
-      if (goodChildren != null && goodChildren.hasNext()) {
+      if (goodChildren != null && goodChildren.hasNext())
+      {
          Element child = (Element)goodChildren.next();
-         if (goodChildren.hasNext()) {
-            throw new DeploymentException
-               ("expected only one " + tagName + " tag");
+         if (goodChildren.hasNext())
+         {
+            throw new IllegalStateException("expected only one " + tagName + " tag");
          }
          return child;
-      } else {
+      }
+      else
+      {
          return defaultElement;
       }
    }
@@ -191,8 +189,7 @@
       String result = element.getAttribute(attrName);
       if (replace)
          return StringPropertyReplacer.replaceProperties(result.trim());
-      else
-         return result.trim();
+      else return result.trim();
    }
 
    /**
@@ -235,12 +232,11 @@
       String result = "";
       for (int i = 0; i < children.getLength(); i++)
       {
-         if (children.item(i).getNodeType() == Node.TEXT_NODE || 
-             children.item(i).getNodeType() == Node.CDATA_SECTION_NODE)
+         if (children.item(i).getNodeType() == Node.TEXT_NODE || children.item(i).getNodeType() == Node.CDATA_SECTION_NODE)
          {
             result += children.item(i).getNodeValue();
          }
-         else if( children.item(i).getNodeType() == Node.COMMENT_NODE )
+         else if (children.item(i).getNodeType() == Node.COMMENT_NODE)
          {
             // Ignore comment nodes
          }
@@ -251,8 +247,7 @@
       }
       if (replace)
          return StringPropertyReplacer.replaceProperties(result.trim());
-      else
-         return result.trim();
+      else return result.trim();
    }
 
    public static String getFirstElementContent(Element element, String defaultStr)
@@ -269,27 +264,25 @@
       String result = "";
       for (int i = 0; i < children.getLength(); i++)
       {
-         if (children.item(i).getNodeType() == Node.TEXT_NODE ||
-             children.item(i).getNodeType() == Node.CDATA_SECTION_NODE)
+         if (children.item(i).getNodeType() == Node.TEXT_NODE || children.item(i).getNodeType() == Node.CDATA_SECTION_NODE)
          {
             String val = children.item(i).getNodeValue();
             result += val;
          }
-         else if( children.item(i).getNodeType() == Node.COMMENT_NODE )
+         else if (children.item(i).getNodeType() == Node.COMMENT_NODE)
          {
             // Ignore comment nodes
          }
          /*  For some reason, the original version gets the text of the first child
-         else
-         {
-            result += children.item(i).getFirstChild();
-         }
-         */
+          else
+          {
+          result += children.item(i).getFirstChild();
+          }
+          */
       }
       if (replace)
          return StringPropertyReplacer.replaceProperties(result.trim());
-      else
-         return result.trim();
+      else return result.trim();
    }
 
    /**
@@ -299,9 +292,7 @@
     * @param tagName    The name of the desired child.
     * @return           The element content or null.
     */
-   public static String getUniqueChildContent(Element element,
-                                              String tagName)
-      throws DeploymentException
+   public static String getUniqueChildContent(Element element, String tagName)
    {
       return getElementContent(getUniqueChild(element, tagName));
    }
@@ -313,9 +304,7 @@
     * @param tagName    The name of the desired child.
     * @return           The element content or null.
     */
-   public static String getOptionalChildContent(Element element,
-                                                String tagName)
-      throws DeploymentException
+   public static String getOptionalChildContent(Element element, String tagName)
    {
       return getElementContent(getOptionalChild(element, tagName));
    }
@@ -328,16 +317,14 @@
     * @return           The element content or null.
     */
    public static String getOptionalChildContent(Element element, String tagName, String defaultValue)
-           throws DeploymentException
    {
       return getElementContent(getOptionalChild(element, tagName), defaultValue);
    }
 
    public static boolean getOptionalChildBooleanContent(Element element, String name)
-      throws DeploymentException
    {
       Element child = getOptionalChild(element, name);
-      if(child != null)
+      if (child != null)
       {
          String value = getElementContent(child).toLowerCase();
          return value.equalsIgnoreCase("true") || value.equalsIgnoreCase("yes");
@@ -346,13 +333,11 @@
       return false;
    }
 
-   public static boolean getOptionalChildBooleanContent(Element element,
-      String name, boolean defaultValue)
-      throws DeploymentException
+   public static boolean getOptionalChildBooleanContent(Element element, String name, boolean defaultValue)
    {
       Element child = getOptionalChild(element, name);
       boolean flag = defaultValue;
-      if(child != null)
+      if (child != null)
       {
          String value = getElementContent(child).toLowerCase();
          flag = value.equalsIgnoreCase("true") || value.equalsIgnoreCase("yes");
@@ -366,7 +351,7 @@
    // Public --------------------------------------------------------
 
    /** Create a field wise copy of the object.
-   */
+    */
    public Object clone()
    {
       Object clone = null;
@@ -374,7 +359,7 @@
       {
          clone = super.clone();
       }
-      catch(CloneNotSupportedException ignore)
+      catch (CloneNotSupportedException ignore)
       {
       }
       return clone;
@@ -382,45 +367,41 @@
 
    /**
     * Imports either the jboss or ejb-jar from the given element.
-    *
     * @param element   The element to import.
-    * 
-    * @throws DeploymentException    Unrecognized root tag.
     */
-   public void importXml(Element element) throws DeploymentException {
-      String rootTag = element.getOwnerDocument().
-         getDocumentElement().getTagName();
+   public void importXml(Element element) throws Exception
+   {
+      String rootTag = element.getOwnerDocument().getDocumentElement().getTagName();
 
-      if (rootTag.equals("jboss")) {
+      if (rootTag.equals("jboss"))
+      {
          // import jboss.xml
          importJbossXml(element);
-      } else if (rootTag.equals("ejb-jar")) {
+      }
+      else if (rootTag.equals("ejb-jar"))
+      {
          // import ejb-jar.xml
          importEjbJarXml(element);
-      } else {
-         throw new DeploymentException("Unrecognized root tag : "+ rootTag);
       }
+      else
+      {
+         throw new IllegalStateException("Unrecognized root tag : " + rootTag);
+      }
    }
 
    /**
     * Non-operation.
-    *
-    * @param element
-    *
-    * @throws DeploymentException
     */
-   public void importEjbJarXml(Element element) throws DeploymentException {
+   public void importEjbJarXml(Element element) throws Exception
+   {
       // empty
    }
 
    /**
     * Non-operation.
-    *
-    * @param element
-    *
-    * @throws DeploymentException
     */
-   public void importJbossXml(Element element) throws DeploymentException {
+   public void importJbossXml(Element element) throws Exception
+   {
       // empty
    }
 
@@ -433,7 +414,8 @@
     *
     * @return    True if the virtual machine is v1.3 or better.
     */
-   protected boolean jdk13Enabled() {
+   protected boolean jdk13Enabled()
+   {
       // should use "java.version" ?
       String javaVersion = System.getProperty("java.vm.version");
       return javaVersion.compareTo("1.3") >= 0;
@@ -444,5 +426,5 @@
    // Inner classes -------------------------------------------------
 }
 /*
-vim:ts=3:sw=3:et
-*/
+ vim:ts=3:sw=3:et
+ */

Modified: trunk/server/src/main/org/jboss/metadata/XmlFileLoader.java
===================================================================
--- trunk/server/src/main/org/jboss/metadata/XmlFileLoader.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/metadata/XmlFileLoader.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -157,7 +157,6 @@
 
       // create the metadata
       metaData = new ApplicationMetaData();
-      metaData.setResourceClassLoader(classLoader);
 
       Document ejbjarDocument = getDocumentFromURL(ejbjarUrl);
       

Modified: trunk/server/src/main/org/jboss/webservice/metadata/serviceref/HandlerMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/webservice/metadata/serviceref/HandlerMetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/webservice/metadata/serviceref/HandlerMetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -1,29 +1,28 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.webservice.metadata.serviceref;
 
 // $Id$
 
-import org.jboss.deployment.DeploymentException;
 import org.jboss.metadata.MetaData;
 import org.jboss.xb.QNameBuilder;
 import org.w3c.dom.Element;
@@ -41,7 +40,7 @@
 public class HandlerMetaData implements Serializable
 {
    static final long serialVersionUID = 8749727542255024909L;
-   
+
    // The required <handler-name> element
    private String handlerName;
    // The required <handler-class> element
@@ -119,17 +118,16 @@
    }
 
    public void importStandardXml(Element element)
-           throws DeploymentException
    {
       handlerName = MetaData.getUniqueChildContent(element, "handler-name");
-      
+
       handlerClass = MetaData.getUniqueChildContent(element, "handler-class");
-      
+
       // Parse the init-param elements
       Iterator iterator = MetaData.getChildrenByTagName(element, "init-param");
       while (iterator.hasNext())
       {
-         Element paramElement = (Element) iterator.next();
+         Element paramElement = (Element)iterator.next();
          InitParamMetaData param = new InitParamMetaData();
          param.setParamName(MetaData.getUniqueChildContent(paramElement, "param-name"));
          param.setParamValue(MetaData.getUniqueChildContent(paramElement, "param-value"));
@@ -140,7 +138,7 @@
       iterator = MetaData.getChildrenByTagName(element, "soap-header");
       while (iterator.hasNext())
       {
-         Element headerElement = (Element) iterator.next();
+         Element headerElement = (Element)iterator.next();
          String content = MetaData.getElementContent(headerElement);
          QName qname = QNameBuilder.buildQName(headerElement, content);
          soapHeaders.add(qname);
@@ -150,7 +148,7 @@
       iterator = MetaData.getChildrenByTagName(element, "soap-role");
       while (iterator.hasNext())
       {
-         Element roleElement = (Element) iterator.next();
+         Element roleElement = (Element)iterator.next();
          String content = MetaData.getElementContent(roleElement);
          soapRoles.add(content);
       }
@@ -159,13 +157,14 @@
       iterator = MetaData.getChildrenByTagName(element, "port-name");
       while (iterator.hasNext())
       {
-         Element portElement = (Element) iterator.next();
+         Element portElement = (Element)iterator.next();
          String content = MetaData.getElementContent(portElement);
          portNames.add(content);
       }
    }
-   
-   public String toString() {
+
+   public String toString()
+   {
       StringBuffer buffer = new StringBuffer("\nHandlerMetaData:");
       buffer.append("\n name=" + handlerName);
       buffer.append("\n class=" + handlerClass);

Modified: trunk/server/src/main/org/jboss/webservice/metadata/serviceref/PortComponentRefMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/webservice/metadata/serviceref/PortComponentRefMetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/webservice/metadata/serviceref/PortComponentRefMetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -1,37 +1,35 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.webservice.metadata.serviceref;
 
 // $Id$
 
-import org.jboss.deployment.DeploymentException;
-import org.jboss.metadata.MetaData;
-import org.w3c.dom.Element;
-
-import javax.xml.rpc.JAXRPCException;
 import java.io.Serializable;
-import java.util.Properties;
 import java.util.Iterator;
+import java.util.Properties;
 
+import org.jboss.metadata.MetaData;
+import org.w3c.dom.Element;
+
 /** The metdata data from service-ref/port-component-ref element in web.xml, ejb-jar.xml, and application-client.xml.
  *
  * @author Thomas.Diesler at jboss.org
@@ -82,42 +80,28 @@
       return serviceEndpointInterface;
    }
 
-   public Class getServiceEndpointInterfaceClass()
-   {
-      try
-      {
-         ClassLoader cl = serviceRefMetaData.getResourceCL();
-         return cl.loadClass(serviceEndpointInterface);
-      }
-      catch (ClassNotFoundException e)
-      {
-         throw new JAXRPCException("Cannot load service endpoint interface: " + serviceEndpointInterface);
-      }
-   }
-
    public Properties getCallProperties()
    {
       return callProperties;
    }
 
    public void importStandardXml(Element element)
-           throws DeploymentException
    {
       serviceEndpointInterface = MetaData.getUniqueChildContent(element, "service-endpoint-interface");
 
       portComponentLink = MetaData.getOptionalChildContent(element, "port-component-link");
    }
 
-   public void importJBossXml(Element element) throws DeploymentException
+   public void importJBossXml(Element element)
    {
       // Look for call-property elements
       Iterator iterator = MetaData.getChildrenByTagName(element, "call-property");
       while (iterator.hasNext())
       {
-         Element propElement = (Element) iterator.next();
+         Element propElement = (Element)iterator.next();
          String name = MetaData.getUniqueChildContent(propElement, "prop-name");
          String value = MetaData.getUniqueChildContent(propElement, "prop-value");
-         if( callProperties == null )
+         if (callProperties == null)
             callProperties = new Properties();
          callProperties.setProperty(name, value);
       }

Modified: trunk/server/src/main/org/jboss/webservice/metadata/serviceref/ServiceRefMetaData.java
===================================================================
--- trunk/server/src/main/org/jboss/webservice/metadata/serviceref/ServiceRefMetaData.java	2006-12-19 16:19:17 UTC (rev 59151)
+++ trunk/server/src/main/org/jboss/webservice/metadata/serviceref/ServiceRefMetaData.java	2006-12-19 16:42:01 UTC (rev 59152)
@@ -26,7 +26,6 @@
 import java.io.Serializable;
 import java.net.MalformedURLException;
 import java.net.URL;
-import java.net.URLClassLoader;
 import java.util.ArrayList;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
@@ -34,7 +33,6 @@
 
 import javax.xml.namespace.QName;
 
-import org.jboss.deployment.DeploymentException;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.MetaData;
 import org.jboss.metadata.Ref;
@@ -48,14 +46,13 @@
  * @author Thomas.Diesler at jboss.org
  * @version $Revision$
  */
-public class ServiceRefMetaData extends Ref
-   implements Serializable
+public class ServiceRefMetaData extends Ref implements Serializable
 {
    private static final long serialVersionUID = -3723577995017108437L;
 
    // provide logging
    private static Logger log = Logger.getLogger(ServiceRefMetaData.class);
-   
+
    // The required <service-ref-name> element
    private String serviceRefName;
    // The required <service-interface> element
@@ -65,7 +62,7 @@
    // The optional <wsdl-file> element
    private String wsdlFile;
    // The optional <jaxrpc-mapping-file> element
-   private String jaxrpcMappingFile;
+   private String mappingFile;
    // The optional <service-qname> element
    private QName serviceQName;
    // The LinkedHashMap<String, PortComponentRefMetaData> for <port-component-ref> elements
@@ -83,9 +80,6 @@
    private Properties callProperties;
    private String mappedName;
 
-   /** The ClassLoader to load additional resources */
-   private transient URLClassLoader resourceCL;
-
    /** Default constructor, used when unmarshalling on the client side
     */
    public ServiceRefMetaData()
@@ -99,53 +93,16 @@
       this.serviceRefName = serviceRefName;
    }
 
-   /** Constructor with a given resource classloader, used on the server side
-    */
-   public ServiceRefMetaData(URLClassLoader resourceCl)
+   public String getMappingFile()
    {
-      setResourceCL(resourceCl);
+      return mappingFile;
    }
 
-   /** Set the resource classloader that can load the wsdl file
-    * On the client side this is set expicitly after unmarshalling.
-    */
-   public void setResourceCL(URLClassLoader resourceCL)
+   public void setMappingFile(String mappingFile)
    {
-      if (resourceCL == null)
-         throw new IllegalArgumentException("ResourceClassLoader cannot be null");
-
-      this.resourceCL = resourceCL;
+      this.mappingFile = mappingFile;
    }
 
-   public URLClassLoader getResourceCL()
-   {
-      if (resourceCL == null)
-         resourceCL = new URLClassLoader(new URL[] {}, Thread.currentThread().getContextClassLoader());
-
-      return resourceCL;
-   }
-
-   public String getJaxrpcMappingFile()
-   {
-      return jaxrpcMappingFile;
-   }
-   public void setJaxrpcMappingFile(String file)
-   {
-      this.jaxrpcMappingFile = jaxrpcMappingFile;
-   }
-
-   public URL getJavaWsdlMappingURL()
-   {
-      URL mappingURL = null;
-      if (jaxrpcMappingFile != null)
-      {
-         mappingURL = getResourceCL().findResource(jaxrpcMappingFile);
-         if (mappingURL == null)
-            throw new IllegalStateException("Cannot find resource: " + jaxrpcMappingFile);
-      }
-      return mappingURL;
-   }
-
    public PortComponentRefMetaData[] getPortComponentRefs()
    {
       PortComponentRefMetaData[] array = new PortComponentRefMetaData[portComponentRefs.size()];
@@ -164,6 +121,7 @@
    {
       return serviceInterface;
    }
+
    public void setServiceInterface(String serviceInterface)
    {
       this.serviceInterface = serviceInterface;
@@ -173,6 +131,7 @@
    {
       return serviceQName;
    }
+
    public void setServiceQName(QName serviceQName)
    {
       this.serviceQName = serviceQName;
@@ -182,6 +141,7 @@
    {
       return serviceRefName;
    }
+
    public void setServiceRefName(String serviceRefName)
    {
       this.serviceRefName = serviceRefName;
@@ -191,6 +151,7 @@
    {
       return serviceResType;
    }
+
    public void setServiceResType(String serviceResType)
    {
       this.serviceResType = serviceResType;
@@ -200,9 +161,10 @@
    {
       return wsdlFile;
    }
-   public void setWsdlFile(String file)
+
+   public void setWsdlFile(String wsdlFile)
    {
-      this.wsdlFile = file;
+      this.wsdlFile = wsdlFile;
    }
 
    public String getConfigFile()
@@ -234,23 +196,12 @@
    {
       this.configName = configName;
    }
+
    public URL getWsdlOverride()
    {
       return wsdlOverride;
    }
 
-   public URL getWsdlURL()
-   {
-      URL wsdlURL = wsdlOverride;
-      if (wsdlURL == null && wsdlFile != null)
-      {
-         wsdlURL = getResourceCL().findResource(wsdlFile);
-         if (wsdlURL == null)
-            throw new IllegalStateException("Cannot find resource: " + wsdlFile);
-      }
-      return wsdlURL;
-   }
-
    public Properties getCallProperties()
    {
       return callProperties;
@@ -271,7 +222,7 @@
          isValid |= "-//JBoss//DTD Web Application 2.4//EN".equals(publicId);
          isValid |= "-//JBoss//DTD Application Client 4.0//EN".equals(publicId);
       }
-      
+
       if (isValid == false)
       {
          String dtstr = (doctype != null ? "[public=" + doctype.getPublicId() + ",system=" + doctype.getSystemId() + "]" : null);
@@ -279,8 +230,8 @@
       }
       return isValid;
    }
-   
-   public void importStandardXml(Element element) throws DeploymentException
+
+   public void importStandardXml(Element element)
    {
       serviceRefName = MetaData.getUniqueChildContent(element, "service-ref-name");
 
@@ -288,7 +239,7 @@
 
       wsdlFile = MetaData.getOptionalChildContent(element, "wsdl-file");
 
-      jaxrpcMappingFile = MetaData.getOptionalChildContent(element, "jaxrpc-mapping-file");
+      mappingFile = MetaData.getOptionalChildContent(element, "jaxrpc-mapping-file");
 
       Element qnameElement = MetaData.getOptionalChild(element, "service-qname");
       if (qnameElement != null)
@@ -316,10 +267,8 @@
    }
 
    /** Parse jboss specific service-ref child elements
-    * @param element
-    * @throws DeploymentException
     */
-   public void importJBossXml(Element element) throws DeploymentException
+   public void importJBossXml(Element element)
    {
       configName = MetaData.getOptionalChildContent(element, "config-name");
 
@@ -332,7 +281,7 @@
       }
       catch (MalformedURLException e)
       {
-         throw new DeploymentException("Invalid WSDL override: " + wsdlOverrideOption);
+         throw new IllegalStateException("Invalid WSDL override: " + wsdlOverrideOption);
       }
 
       // Parse the port-component-ref elements



From thomas.diesler at jboss.com  Tue Dec 19 11:47:46 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Tue, 19 Dec 2006 11:47:46 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/jbossws/snapshot/lib ...
Message-ID: <E1Gwi82-0006Nx-CE@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/19 11:47:46

  Modified:    jboss/jbossws/snapshot/lib         jboss-jaxrpc.jar
                        jboss-jaxws.jar jboss-saaj.jar jbossws-client.jar
                        jbossws-jboss-integration.jar
                        jbossws-tomcat-integration.jar jbossws.deployer
                        jbossws.sar
  Log:
  -r 1670
  
  Revision  Changes    Path
  1.33      +124 -125  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar
  
  	<<Binary file>>
  
  
  1.32      +223 -225  repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-jaxws.jar
  
  	<<Binary file>>
  
  
  1.33      +85 -86    repository.jboss.com/jboss/jbossws/snapshot/lib/jboss-saaj.jar
  
  	<<Binary file>>
  
  
  1.44      +2415 -2405repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-client.jar
  
  	<<Binary file>>
  
  
  1.6       +157 -152  repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar
  
  	<<Binary file>>
  
  
  1.6       +54 -61    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar
  
  	<<Binary file>>
  
  
  1.5       +4183 -4169repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.deployer
  
  	<<Binary file>>
  
  
  1.44      +23 -34    repository.jboss.com/jboss/jbossws/snapshot/lib/jbossws.sar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Tue Dec 19 11:49:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 11:49:52 -0500
Subject: [jboss-cvs] JBossCache/lib  ...
Message-ID: <E1GwiA4-0006OH-5d@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 11:49:52

  Modified:    lib      Tag: Branch_JBossCache_1_4_0 jgroups.jar
  Log:
  Updated to JGroups 2.4.1.GA
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.6   +5271 -1496JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Tue Dec 19 11:50:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 11:50:39 -0500
Subject: [jboss-cvs] JBossCache/lib  ...
Message-ID: <E1GwiAp-0006Q2-K3@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 11:50:39

  Modified:    lib      jgroups.jar
  Log:
  Updated to 2.4.1.GA
  
  Revision  Changes    Path
  1.10      +5328 -1533JBossCache/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From gavin.king at jboss.com  Tue Dec 19 11:57:04 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 11:57:04 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors  ...
Message-ID: <E1GwiH2-0006Yi-S9@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 11:57:04

  Modified:    src/main/org/jboss/seam/interceptors 
                        ConversationInterceptor.java
  Log:
  fix bug with @Begin(id=...)
  
  Revision  Changes    Path
  1.56      +25 -22    jboss-seam/src/main/org/jboss/seam/interceptors/ConversationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ConversationInterceptor.java,v
  retrieving revision 1.55
  retrieving revision 1.56
  diff -u -b -r1.55 -r1.56
  --- ConversationInterceptor.java	17 Nov 2006 07:12:56 -0000	1.55
  +++ ConversationInterceptor.java	19 Dec 2006 16:57:04 -0000	1.56
  @@ -1,4 +1,4 @@
  -//$Id: ConversationInterceptor.java,v 1.55 2006/11/17 07:12:56 gavin Exp $
  +//$Id: ConversationInterceptor.java,v 1.56 2006/12/19 16:57:04 gavin Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -57,6 +57,8 @@
      
      public boolean redirectToExistingConversation(Method method)
      {
  +      if ( !Manager.instance().isLongRunningConversation() )
  +      {
         String id = null;
         if ( method.isAnnotationPresent(Begin.class) )
         {
  @@ -84,6 +86,7 @@
               return ce.switchConversation();
            }
         }
  +      }
         
         return false;
      }
  
  
  


From gavin.king at jboss.com  Tue Dec 19 11:57:05 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 11:57:05 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core   ...
Message-ID: <E1GwiH3-0006Ys-20@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 11:57:05

  Modified:    src/main/org/jboss/seam/core   Manager.java
                        ConversationEntries.java
  Log:
  fix bug with @Begin(id=...)
  
  Revision  Changes    Path
  1.131     +15 -3     jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.130
  retrieving revision 1.131
  diff -u -b -r1.130 -r1.131
  --- Manager.java	18 Dec 2006 15:38:49 -0000	1.130
  +++ Manager.java	19 Dec 2006 16:57:04 -0000	1.131
  @@ -42,7 +42,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.130 $
  + * @version $Revision: 1.131 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -87,8 +87,20 @@
         currentConversationEntry = null;
      }
      
  +   /**
  +    * Must not be called from a long-running conversation!
  +    * 
  +    * @param id the new conversation id
  +    */
      public void updateCurrentConversationId(String id)
      {
  +      if ( ConversationEntries.instance().getConversationIds().contains(id) )
  +      {
  +         throw new IllegalStateException("Cannot update conversation id of long-running conversation");
  +      }
  +      
  +      //this stuff is not really necessary, because probably 
  +      //nothing has been flushed to the session yet!
         String[] names = Contexts.getConversationContext().getNames();
         Object[] values = new Object[names.length];
         for (int i=0; i<names.length; i++)
  @@ -98,11 +110,11 @@
         }
         Contexts.getConversationContext().flush();
         
  -      ConversationEntries.instance().updateConversationId( getCurrentConversationId(), id );
         currentConversationIdStack.set(0, id);
         setCurrentConversationId(id);
  -      //TODO: update nested conversations!!!!!
         
  +      //this stuff is not really necessary, because probably 
  +      //nothing has been flushed to the session yet!
         for (int i=0; i<names.length; i++)
         {
            Contexts.getConversationContext().set(names[i], values[i]);
  
  
  
  1.5       +0 -13     jboss-seam/src/main/org/jboss/seam/core/ConversationEntries.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationEntries.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ConversationEntries.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ConversationEntries.java	24 Nov 2006 23:15:17 -0000	1.4
  +++ ConversationEntries.java	19 Dec 2006 16:57:05 -0000	1.5
  @@ -68,19 +68,6 @@
         return entry;
      }
      
  -   public synchronized ConversationEntry updateConversationId(String oldId, String newId)
  -   {
  -      ConversationEntry entry = conversationIdEntryMap.remove(oldId);
  -      if (entry==null)
  -      {
  -         throw new IllegalStateException("conversation not found");
  -      }
  -      entry.setId(newId);
  -      conversationIdEntryMap.put(newId, entry);
  -      setDirty();
  -      return entry;
  -   }
  -   
      public static ConversationEntries instance()
      {
         if ( !Contexts.isSessionContextActive() )
  
  
  


From gavin.king at jboss.com  Tue Dec 19 12:03:24 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 12:03:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/registration  ...
Message-ID: <E1GwiNA-0006on-E2@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 12:03:24

  Modified:    examples/registration  build.xml
  Log:
  oops
  
  Revision  Changes    Path
  1.28      +1 -0      jboss-seam/examples/registration/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/registration/build.xml,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- build.xml	5 Dec 2006 13:29:39 -0000	1.27
  +++ build.xml	19 Dec 2006 17:03:24 -0000	1.28
  @@ -8,6 +8,7 @@
   
       <!-- Overrides -->
   	<property name="example.webinf.lib.dir"  value="."/>
  +	<property name="example.seam.ui.lib"     value="yes"/>
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
       <property name="test.classpath"          value="test.eejb.classpath"/>
  
  
  


From gavin.king at jboss.com  Tue Dec 19 12:11:39 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 12:11:39 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GwiV9-000702-05@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 12:11:38

  Modified:    jboss-seam  seam.bat
  Log:
  JBSEAM-615
  
  Revision  Changes    Path
  1.18      +1 -1      jboss-seam/seam.bat
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.bat
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/seam.bat,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- seam.bat	14 Dec 2006 07:32:18 -0000	1.17
  +++ seam.bat	19 Dec 2006 17:11:38 -0000	1.18
  @@ -17,7 +17,7 @@
   
   if %SEAMTASK% == help (goto help)
   
  -java -cp "%JAVA_HOME%\lib\tools.jar;.\lib\ant.jar;.\lib\ant-nodeps.jar;.\lib\ant-launcher.jar" -Dant.home="%DIRNAME%\lib" org.apache.tools.ant.launch.Launcher -buildfile "%SEAMGENDIR%\build.xml" %ARGS%  
  +java -cp "%JAVA_HOME%\lib\tools.jar;%DIRNAME%\lib\ant.jar;%DIRNAME%\lib\ant-nodeps.jar;%DIRNAME%\lib\ant-launcher.jar" -Dant.home="%DIRNAME%\lib" org.apache.tools.ant.launch.Launcher -buildfile "%SEAMGENDIR%\build.xml" %ARGS%  
   goto END_NO_PAUSE
   
   :usage
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 12:19:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 12:19:49 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1825 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1Gwid3-00076m-5q@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 12:19:47 -0500 (Tue, 19 Dec 2006)
New Revision: 1825

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
removing valve from the stack for tests

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 16:26:29 UTC (rev 1824)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 17:19:47 UTC (rev 1825)
@@ -163,7 +163,7 @@
       ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
 
       // ValveAspect is supposed to be created per ClientConnectionDelegate
-      installValveAspect(cd, new ValveAspect(cd, this));
+      //installValveAspect(cd, new ValveAspect(cd, this));
 
       if(trace) { log.trace(this + " got local connection delegate " + cd); }
 



From gavin.king at jboss.com  Tue Dec 19 12:22:11 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 12:22:11 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1GwifL-0007BQ-Od@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 12:22:11

  Modified:    src/ui/org/jboss/seam/ui   HtmlButton.java HtmlLink.java
  Log:
  fix   JBSEAM-612
  
  Revision  Changes    Path
  1.6       +3 -2      jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlButton.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlButton.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- HtmlButton.java	18 Dec 2006 22:48:31 -0000	1.5
  +++ HtmlButton.java	19 Dec 2006 17:22:11 -0000	1.6
  @@ -139,10 +139,11 @@
         
         if ( "default".equals(propagation) || "join".equals(propagation) || "nest".equals(propagation) || "end".equals(propagation) )
         {
  -         if ( Conversation.instance().isLongRunning() || Conversation.instance().isNested() )
  -         {
  +         //always add the id, since conversations could begin after link is rendered
               encodedUrl += getParameterString(characterEncoding, new UIConversationId(), first);
               first = false;
  +         if ( Conversation.instance().isLongRunning() || Conversation.instance().isNested() )
  +         {
               encodedUrl += getParameterString(characterEncoding, new UIConversationIsLongRunning(), first);
            }
         }
  
  
  
  1.26      +3 -2      jboss-seam/src/ui/org/jboss/seam/ui/HtmlLink.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HtmlLink.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/HtmlLink.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- HtmlLink.java	18 Dec 2006 22:48:31 -0000	1.25
  +++ HtmlLink.java	19 Dec 2006 17:22:11 -0000	1.26
  @@ -139,10 +139,11 @@
         
         if ( "default".equals(propagation) || "join".equals(propagation) || "nest".equals(propagation) || "end".equals(propagation) )
         {
  -         if ( Conversation.instance().isLongRunning() || Conversation.instance().isNested() )
  -         {
  +         //always add the id, since conversations could begin after link is rendered
               encodedUrl += getParameterString(characterEncoding, new UIConversationId(), first);
               first = false;
  +         if ( Conversation.instance().isLongRunning() || Conversation.instance().isNested() )
  +         {
               encodedUrl += getParameterString(characterEncoding, new UIConversationIsLongRunning(), first);
            }
         }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 12:32:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 12:32:33 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1826 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GwipN-0007Lu-Ig@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-19 12:32:32 -0500 (Tue, 19 Dec 2006)
New Revision: 1826

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
removing valve from the stack

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 17:19:47 UTC (rev 1825)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 17:32:32 UTC (rev 1826)
@@ -59,6 +59,8 @@
 import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
+import org.jboss.remoting.ConnectionListener;
+import org.jboss.remoting.Client;
 
 /**
  *
@@ -162,8 +164,8 @@
 
       ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
 
-      // ValveAspect is supposed to be created per ClientConnectionDelegate
-      //installValveAspect(cd, new ValveAspect(cd, this));
+      ((ConnectionState) ((DelegateSupport) cd).getState()).
+         getRemotingConnectionListener().addDelegateListener(new ConnectionFailureListener(cd));
 
       if(trace) { log.trace(this + " got local connection delegate " + cd); }
 
@@ -679,6 +681,45 @@
        }
     }
 
+
+
+
+   /** I have moved this ConnectionListener to ValveAspect (from HAAspect) because
+    *  it needs to use the same valve as exception listeners.
+    *  While we are processing failover, we should block any calls on the client side.
+    *  (No call should be made while the client failover is being executed). It doesn't matter if
+    *  the failover was captured by Lease (ConnectionFactory) or Exception handling on invoke at this class */
+   private class ConnectionFailureListener implements ConnectionListener
+   {
+      private ClientConnectionDelegate cd;
+
+      ConnectionFailureListener(ClientConnectionDelegate cd)
+      {
+         this.cd = cd;
+      }
+
+      // ConnectionListener implementation ---------------------------
+
+      public void handleConnectionException(Throwable throwable, Client client)
+      {
+         try
+         {
+            log.debug(this + " is being notified of connection failure: " + throwable);
+            handleConnectionFailure(cd);
+         }
+         catch (Throwable e)
+         {
+            log.error("Caught exception in handling failure", e);
+         }
+      }
+
+      public String toString()
+      {
+         return "ConnectionFailureListener[" + cd + "]";
+      }
+   }
+
+   
 }
 
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 12:38:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 12:38:50 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59153 - branches/Branch_4_2/build
Message-ID: <E1GwivS-0007RO-1l@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-19 12:38:48 -0500 (Tue, 19 Dec 2006)
New Revision: 59153

Modified:
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
JBAS-3955, Upgrade commons-httpclient to v3.0.1

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-19 16:42:01 UTC (rev 59152)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-19 17:38:48 UTC (rev 59153)
@@ -58,7 +58,7 @@
       <componentref name="apache-digester" version="1.6"/>
       <componentref name="apache-discovery" version="0.2"/>
       <componentref name="apache-fileupload" version="1.0"/>
-      <componentref name="apache-httpclient" version="2.0.2"/>
+      <componentref name="apache-httpclient" version="3.0.1"/>
       <componentref name="apache-jaxme" version="0.2-cvs"/>
       <componentref name="apache-log4j" version="1.2.14"/>
       <componentref name="apache-logging" version="1.1"/>



From bela.ban at jboss.com  Tue Dec 19 12:52:49 2006
From: bela.ban at jboss.com (Bela Ban)
Date: Tue, 19 Dec 2006 12:52:49 -0500
Subject: [jboss-cvs] repository.jboss.com/jgroups/2.4.1 - New directory ...
Message-ID: <E1Gwj8z-0007fz-SS@committer01.frg.pub.inap.atl.jboss.com>

  User: bela    
  Date: 06/12/19 12:52:49

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jgroups/2.4.1 added to the repository


From bela.ban at jboss.com  Tue Dec 19 12:52:52 2006
From: bela.ban at jboss.com (Bela Ban)
Date: Tue, 19 Dec 2006 12:52:52 -0500
Subject: [jboss-cvs] repository.jboss.com/jgroups/2.4.1/lib - New directory ...
Message-ID: <E1Gwj92-0007g8-J2@committer01.frg.pub.inap.atl.jboss.com>

  User: bela    
  Date: 06/12/19 12:52:52

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jgroups/2.4.1/lib added to the repository


From bela.ban at jboss.com  Tue Dec 19 12:53:56 2006
From: bela.ban at jboss.com (Bela Ban)
Date: Tue, 19 Dec 2006 12:53:56 -0500
Subject: [jboss-cvs] repository.jboss.com/jgroups/2.4.1/lib  ...
Message-ID: <E1GwjA4-0007gV-DU@committer01.frg.pub.inap.atl.jboss.com>

  User: bela    
  Date: 06/12/19 12:53:56

  Added:       jgroups/2.4.1/lib  jgroups.jar
  Log:
  added JGroups 2.4.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 17:53:56;  author: bela;  state: Exp;repository.jboss.com/jgroups/2.4.1/lib/jgroups.jar
  
  	<<Binary file>>
  
  


From bela.ban at jboss.com  Tue Dec 19 12:53:56 2006
From: bela.ban at jboss.com (Bela Ban)
Date: Tue, 19 Dec 2006 12:53:56 -0500
Subject: [jboss-cvs] repository.jboss.com/jgroups/2.4.1  ...
Message-ID: <E1GwjA4-0007gc-Ic@committer01.frg.pub.inap.atl.jboss.com>

  User: bela    
  Date: 06/12/19 12:53:56

  Added:       jgroups/2.4.1  component-info.xml
  Log:
  added JGroups 2.4.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/19 17:53:56;  author: bela;  state: Exp;repository.jboss.com/jgroups/2.4.1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jgroups-component-info">
  
     <component id="jgroups"
        licenseType="lgpl"
        version="2.4.1"
        projectHome="http://www.jgroups.org"
        description="JGroups is a toolkit for reliable multicast communication">
  
        <artifact id="jgroups.jar"/>
  
        <export>
           <include input="jgroups.jar"/>
        </export>
     </component>
  </project>
  
  


From gavin.king at jboss.com  Tue Dec 19 13:11:30 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 13:11:30 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GwjR4-00089L-7b@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 13:11:30

  Modified:    examples/booking/resources/WEB-INF  pages.xml
  Log:
  oops
  
  Revision  Changes    Path
  1.12      +1 -1      jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- pages.xml	18 Dec 2006 17:55:44 -0000	1.11
  +++ pages.xml	19 Dec 2006 18:11:30 -0000	1.12
  @@ -69,7 +69,7 @@
             
           <description>Book hotel: #{hotel.name}</description>
           
  -        <action-navigation>
  +        <action-navigation from-action="#{hotelBooking.setBookingDetails}">
               <redirect view-id="/confirm.xhtml"/>
           </action-navigation>
           
  
  
  


From gavin.king at jboss.com  Tue Dec 19 13:14:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 13:14:37 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GwjU5-00089b-G6@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 13:14:37

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  call s:link/button action *after* running page actions
  
  Revision  Changes    Path
  1.71      +6 -1      jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.70
  retrieving revision 1.71
  diff -u -b -r1.70 -r1.71
  --- Pages.java	19 Dec 2006 00:40:41 -0000	1.70
  +++ Pages.java	19 Dec 2006 18:14:37 -0000	1.71
  @@ -249,6 +249,11 @@
               result = page.enter(facesContext) || result;
            }
         }
  +      
  +      //run the s:link / s:button action after checking the
  +      //conversation existence!
  +      result = callAction(facesContext) || result;
  +
         return result;
      }
   
  @@ -278,7 +283,7 @@
      /**
       * Call the action requested by s:link or s:button.
       */
  -   public static boolean callAction(FacesContext facesContext)
  +   private static boolean callAction(FacesContext facesContext)
      {
         //TODO: refactor with Pages.instance().callAction()!!
         
  
  
  


From gavin.king at jboss.com  Tue Dec 19 13:14:37 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 13:14:37 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf  ...
Message-ID: <E1GwjU5-00089i-KA@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 13:14:37

  Modified:    src/main/org/jboss/seam/jsf  AbstractSeamPhaseListener.java
  Log:
  call s:link/button action *after* running page actions
  
  Revision  Changes    Path
  1.35      +1 -3      jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- AbstractSeamPhaseListener.java	19 Dec 2006 00:40:41 -0000	1.34
  +++ AbstractSeamPhaseListener.java	19 Dec 2006 18:14:37 -0000	1.35
  @@ -250,9 +250,7 @@
         boolean actionsWereCalled = false;
         try
         {
  -         FacesContext facesContext = event.getFacesContext();
  -         actionsWereCalled = Pages.callAction(facesContext) || actionsWereCalled;
  -         actionsWereCalled = Pages.instance().enterPage(facesContext) || actionsWereCalled;
  +         actionsWereCalled = Pages.instance().enterPage( event.getFacesContext() );
            return actionsWereCalled;
         }
         catch (RuntimeException re)
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 14:36:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 14:36:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59154 -
	projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test
Message-ID: <E1GwklC-00016K-Gu@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 14:36:20 -0500 (Tue, 19 Dec 2006)
New Revision: 59154

Modified:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
Log:
testFindClassesInFilesOnlyWar

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-19 17:38:48 UTC (rev 59153)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-19 19:36:20 UTC (rev 59154)
@@ -45,7 +45,9 @@
 import junit.framework.TestSuite;
 
 import org.jboss.test.BaseTestCase;
+import org.jboss.test.virtual.support.ClassPathIterator;
 import org.jboss.test.virtual.support.MetaDataMatchFilter;
+import org.jboss.test.virtual.support.ClassPathIterator.ClassPathEntry;
 import org.jboss.virtual.VFS;
 import org.jboss.virtual.VFSUtils;
 import org.jboss.virtual.VirtualFile;
@@ -289,6 +291,21 @@
    {
       URL rootURL = getResource("/vfs/test");
       VFS vfs = VFS.getVFS(rootURL);
+
+      VirtualFile war2 = vfs.findChild("WarDeployApp_web.war");
+      assertTrue("WarDeployApp_web.war != null", war2 != null);
+
+      VirtualFile classes2 = war2.findChild("WEB-INF/classes");
+      assertTrue("WEB-INF/classes != null", classes2 != null);
+      assertTrue("WEB-INF/classes is not a leaf", classes2.isLeaf()==false);
+      classes2 = war2.findChild("WEB-INF/classes");
+      assertTrue("WEB-INF/classes != null", classes2 != null);
+      assertTrue("WEB-INF/classes is not a leaf", classes2.isLeaf()==false);
+
+      VirtualFile HelloJavaBean = classes2.findChild("com/sun/ts/tests/webservices/deploy/warDeploy/HelloJavaBean.class");
+      assertTrue("HelloJavaBean.class != null", HelloJavaBean != null);
+      assertTrue("HelloJavaBean.class is a leaf", HelloJavaBean.isLeaf());
+
       VirtualFile war = vfs.findChild("filesonly.war");
       assertTrue("filesonly.war != null", war != null);
 
@@ -314,8 +331,38 @@
       String title = mf.getMainAttributes().getValue(Attributes.Name.SPECIFICATION_TITLE);
       assertEquals("filesonly-war", title);
       mfIS.close();
+
+      war.findChild("WEB-INF/classes");
+      assertTrue("WEB-INF/classes != null", classes != null);
+      assertTrue("WEB-INF/classes is not a leaf", classes.isLeaf()==false);
    }
 
+   /**
+    * Validate iterating over a vfs url
+    * 
+    * @throws Exception
+    */
+   public void testFindClassesInFilesOnlyWar()
+      throws Exception
+   {
+      URL rootURL = getResource("/vfs/test");
+      VFS vfs = VFS.getVFS(rootURL);
+
+      VirtualFile war = vfs.findChild("filesonly.war");
+      assertTrue("filesonly.war != null", war != null);
+
+      VirtualFile classes = war.findChild("WEB-INF/classes");
+      assertTrue("WEB-INF/classes != null", classes != null);
+      HashSet<String> names = new HashSet<String>();
+      ClassPathIterator iter = new ClassPathIterator(classes.toURL());
+      ClassPathEntry entry = null;
+      while( (entry = iter.getNextEntry()) != null )
+      {
+         names.add(entry.name);
+      }
+      log.debug(names);
+   }
+
    public void testFindResourceUnpackedJar()
       throws Exception
    {



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 14:36:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 14:36:39 -0500
Subject: [jboss-cvs] JBossAS SVN: r59155 -
	projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support
Message-ID: <E1GwklT-00017U-Cd@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 14:36:37 -0500 (Tue, 19 Dec 2006)
New Revision: 59155

Added:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
Log:
Support class for testFindClassesInFilesOnlyWar

Added: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java	2006-12-19 19:36:20 UTC (rev 59154)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java	2006-12-19 19:36:37 UTC (rev 59155)
@@ -0,0 +1,263 @@
+package org.jboss.test.virtual.support;
+
+import java.io.File;
+import java.io.FileFilter;
+import java.io.FileInputStream;
+import java.io.IOException;
+import java.io.InputStream;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.zip.ZipEntry;
+import java.util.zip.ZipInputStream;
+
+import org.jboss.virtual.VFS;
+import org.jboss.virtual.VirtualFile;
+import org.jboss.virtual.VirtualFileFilter;
+
+public class ClassPathIterator
+{
+   ZipInputStream zis;
+   FileIterator fileIter;
+   File file;
+   VirtualFileIterator vfIter;
+   VirtualFile vf;
+   int rootLength;
+
+   public ClassPathIterator(URL url) throws IOException
+   {
+      String protocol = url != null ? url.getProtocol() : null;
+      if( protocol == null )
+      {
+      }
+      else if( protocol.equals("file") )
+      {
+         File tmp = new File(url.getFile());
+         if( tmp.isDirectory() )
+         {
+            rootLength = tmp.getPath().length() + 1;
+            fileIter = new FileIterator(tmp);
+         }
+         else
+         {
+            // Assume this is a jar archive
+            InputStream is = new FileInputStream(tmp);
+            zis = new ZipInputStream(is);
+         }
+      }
+      else if( protocol.startsWith("vfs") )
+      {
+         VFS vfs = VFS.getVFS(url);
+         vf = vfs.getRoot();
+         rootLength = vf.getPathName().length() + 1;
+         vfIter = new VirtualFileIterator(vf);
+      }
+      else
+      {
+         // Assume this points to a jar
+         InputStream is = url.openStream();
+         zis = new ZipInputStream(is);
+      }
+   }
+
+   public ClassPathEntry getNextEntry() throws IOException
+   {
+      ClassPathEntry entry = null;
+      if( zis != null )
+      {
+         ZipEntry zentry = zis.getNextEntry();
+         if( zentry != null )
+            entry = new ClassPathEntry(zentry);
+      }
+      else if( fileIter != null )
+      {
+         File fentry = fileIter.getNextEntry();
+         if( fentry != null )
+            entry = new ClassPathEntry(fentry, rootLength);
+         file = fentry;
+      }
+      else if( vfIter != null )
+      {
+         VirtualFile fentry = vfIter.getNextEntry();
+         if( fentry != null )
+            entry = new ClassPathEntry(fentry, rootLength);
+         vf = fentry;
+      }
+
+      return entry;
+   }
+
+   InputStream getInputStream() throws IOException
+   {
+      InputStream is = zis;
+      if( zis == null )
+      {
+         is = new FileInputStream(file);
+      }
+      return is;
+   }
+
+   public void close() throws IOException
+   {
+      if( zis != null )
+         zis.close();
+   }
+
+   static class FileIterator
+   {
+      LinkedList subDirectories = new LinkedList();
+      FileFilter filter;
+      File[] currentListing;
+      int index = 0;
+
+      FileIterator(File start)
+      {
+         String name = start.getName();
+         // Don't recurse into wars
+         boolean isWar = name.endsWith(".war");
+         if( isWar )
+            currentListing = new File[0];
+         else
+            currentListing = start.listFiles();
+      }
+      FileIterator(File start, FileFilter filter)
+      {
+         String name = start.getName();
+         // Don't recurse into wars
+         boolean isWar = name.endsWith(".war");
+         if( isWar )
+            currentListing = new File[0];
+         else
+            currentListing = start.listFiles(filter);
+         this.filter = filter;
+      }
+
+      File getNextEntry()
+      {
+         File next = null;
+         if( index >= currentListing.length && subDirectories.size() > 0 )
+         {
+            do
+            {
+               File nextDir = (File) subDirectories.removeFirst();
+               currentListing = nextDir.listFiles(filter);
+            } while( currentListing.length == 0 && subDirectories.size() > 0 );
+            index = 0;
+         }
+         if( index < currentListing.length )
+         {
+            next = currentListing[index ++];
+            if( next.isDirectory() )
+               subDirectories.addLast(next);
+         }
+         return next;
+      }
+   }
+
+   static class VirtualFileIterator
+   {
+      LinkedList<VirtualFile> subDirectories = new LinkedList<VirtualFile>();
+      VirtualFileFilter filter;
+      List<VirtualFile> currentListing;
+      int index = 0;
+
+      VirtualFileIterator(VirtualFile start) throws IOException
+      {
+         this(start, null);
+      }
+      VirtualFileIterator(VirtualFile start, VirtualFileFilter filter)  throws IOException
+      {
+         String name = start.getName();
+         // Don't recurse into wars
+         boolean isWar = name.endsWith(".war");
+         if( isWar )
+            currentListing = new ArrayList<VirtualFile>();
+         else
+            currentListing = start.getChildren();
+         this.filter = filter;
+      }
+
+      VirtualFile getNextEntry()
+         throws IOException
+      {
+         VirtualFile next = null;
+         if( index >= currentListing.size() && subDirectories.size() > 0 )
+         {
+            do
+            {
+               VirtualFile nextDir = subDirectories.removeFirst();
+               currentListing = nextDir.getChildren(filter);
+            } while( currentListing.size() == 0 && subDirectories.size() > 0 );
+            index = 0;
+         }
+         if( index < currentListing.size() )
+         {
+            next = currentListing.get(index);
+            if( next.isLeaf() == false )
+               subDirectories.addLast(next);
+         }
+         return next;
+      }
+   }
+
+   public static class ClassPathEntry
+   {
+      public String name;
+      public ZipEntry zipEntry;
+      public File fileEntry;
+      public VirtualFile vfEntry;
+
+      ClassPathEntry(ZipEntry zipEntry)
+      {
+         this.zipEntry = zipEntry;
+         this.name = zipEntry.getName();
+      }
+      ClassPathEntry(File fileEntry, int rootLength)
+      {
+         this.fileEntry = fileEntry;
+         this.name = fileEntry.getPath().substring(rootLength);
+      }
+      ClassPathEntry(VirtualFile vfEntry, int rootLength)
+      {
+         this.vfEntry = vfEntry;
+         this.name = vfEntry.getPathName().substring(rootLength);
+      }
+
+      String getName()
+      {
+         return name;
+      }
+      /** Convert the entry path to a package name
+       */
+      String toPackageName()
+      {
+         String pkgName = name;
+         char separatorChar = zipEntry != null ? '/' : File.separatorChar;
+         int index = name.lastIndexOf(separatorChar);
+         if( index > 0 )
+         {
+            pkgName = name.substring(0, index);
+            pkgName = pkgName.replace(separatorChar, '.');
+         }
+         else
+         {
+            // This must be an entry in the default package (e.g., X.class)
+            pkgName = "";
+         }
+         return pkgName;
+      }
+
+      boolean isDirectory()
+      {
+         boolean isDirectory = false;
+         if( zipEntry != null )
+            isDirectory = zipEntry.isDirectory();
+         else
+            isDirectory = fileEntry.isDirectory();
+         return isDirectory;
+      }
+   }
+
+}
+


Property changes on: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
___________________________________________________________________
Name: svn:eol-style
   + native



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 14:38:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 14:38:17 -0500
Subject: [jboss-cvs] JBossAS SVN: r59156 -
	projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support
Message-ID: <E1Gwkn3-00017w-D5@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 14:38:15 -0500 (Tue, 19 Dec 2006)
New Revision: 59156

Modified:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
Log:
Add lgpl header

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java	2006-12-19 19:36:37 UTC (rev 59155)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java	2006-12-19 19:38:15 UTC (rev 59156)
@@ -1,3 +1,24 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors
+ * by the @authors tag. See the copyright.txt 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.test.virtual.support;
 
 import java.io.File;
@@ -16,6 +37,12 @@
 import org.jboss.virtual.VirtualFile;
 import org.jboss.virtual.VirtualFileFilter;
 
+/**
+ * ClassPathIterator logic used by UCL package mapping
+ * 
+ * @author Scott.Stark at jboss.org
+ * @version $Revision:$
+ */
 public class ClassPathIterator
 {
    ZipInputStream zis;



From c55 at fullmailmarket.com  Tue Dec 19 15:40:58 2006
From: c55 at fullmailmarket.com (NoteBook Service)
Date: Tue, 19 Dec 2006 17:40:58 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Servicio_T=E9cnico_Especializado_Note?=
	=?iso-8859-1?q?books?=
Message-ID: <200612192041.kBJKf3tS012947@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061219/3d2f911a/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 15:50:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 15:50:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r59157 -
	projects/vfs/trunk/src/test/resources/vfs/test
Message-ID: <E1GwlvN-0002NV-Jg@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 15:50:55 -0500 (Tue, 19 Dec 2006)
New Revision: 59157

Added:
   projects/vfs/trunk/src/test/resources/vfs/test/WarDeployApp_web.war
Log:
Add another files only war

Added: projects/vfs/trunk/src/test/resources/vfs/test/WarDeployApp_web.war
===================================================================
(Binary files differ)


Property changes on: projects/vfs/trunk/src/test/resources/vfs/test/WarDeployApp_web.war
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 15:59:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 15:59:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r59158 - in projects/microcontainer/trunk:
	managed metatype
Message-ID: <E1Gwm3e-0002VX-NJ@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 15:59:28 -0500 (Tue, 19 Dec 2006)
New Revision: 59158

Modified:
   projects/microcontainer/trunk/managed/
   projects/microcontainer/trunk/metatype/
Log:
Ignore the output dirs


Property changes on: projects/microcontainer/trunk/managed
___________________________________________________________________
Name: svn:ignore
   + output



Property changes on: projects/microcontainer/trunk/metatype
___________________________________________________________________
Name: svn:ignore
   + output




From gavin.king at jboss.com  Tue Dec 19 16:06:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:06:29 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam  ...
Message-ID: <E1GwmAP-0002ou-4K@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:06:29

  Modified:    src/main/org/jboss/seam  pages-1.1.dtd
  Log:
  renames
  
  Revision  Changes    Path
  1.14      +8 -8      jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages-1.1.dtd
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages-1.1.dtd,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- pages-1.1.dtd	19 Dec 2006 00:51:12 -0000	1.13
  +++ pages-1.1.dtd	19 Dec 2006 21:06:29 -0000	1.14
  @@ -9,7 +9,7 @@
   <!ELEMENT pages (page*)>
   <!ATTLIST pages no-conversation-view-id CDATA #IMPLIED>
   
  -<!ELEMENT page (#PCDATA|description|param|in|begin-conversation|end-conversation|action|action-navigation)*>
  +<!ELEMENT page (#PCDATA|description|param|in|begin-conversation|end-conversation|action|navigation)*>
   <!ATTLIST page action CDATA #IMPLIED>
   <!ATTLIST page view-id CDATA #IMPLIED>
   <!ATTLIST page switch (enabled|disabled) "enabled">
  @@ -28,13 +28,13 @@
   <!ATTLIST action if CDATA #IMPLIED>
   <!ATTLIST action execute CDATA #REQUIRED>
   
  -<!ELEMENT action-navigation (((begin-conversation|end-conversation)?,(out*),(render|redirect))|(outcome*))>
  -<!ATTLIST action-navigation from-action CDATA #IMPLIED>
  -<!ATTLIST action-navigation evaluate CDATA #IMPLIED>
  -
  -<!ELEMENT outcome ((begin-conversation|end-conversation)?,(out*),(render|redirect))>
  -<!ATTLIST outcome if-value CDATA #IMPLIED>
  -<!ATTLIST outcome if CDATA #IMPLIED>
  +<!ELEMENT navigation (((begin-conversation|end-conversation)?,(out*),(render|redirect))|(rule*))>
  +<!ATTLIST navigation from-action CDATA #IMPLIED>
  +<!ATTLIST navigation evaluate CDATA #IMPLIED>
  +
  +<!ELEMENT rule ((begin-conversation|end-conversation)?,(out*),(render|redirect))>
  +<!ATTLIST rule if-outcome CDATA #IMPLIED>
  +<!ATTLIST rule if CDATA #IMPLIED>
   
   <!ELEMENT begin-conversation EMPTY>
   <!ATTLIST begin-conversation join (true|false) "false">
  
  
  


From gavin.king at jboss.com  Tue Dec 19 16:06:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:06:29 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GwmAP-0002p1-8k@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:06:29

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  renames
  
  Revision  Changes    Path
  1.72      +5 -5      jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.71
  retrieving revision 1.72
  diff -u -b -r1.71 -r1.72
  --- Pages.java	19 Dec 2006 18:14:37 -0000	1.71
  +++ Pages.java	19 Dec 2006 21:06:29 -0000	1.72
  @@ -631,7 +631,7 @@
            page.getParameters().add( parseParam(param) );
         }
         
  -      List<Element> moreChildren = element.elements("action-navigation");
  +      List<Element> moreChildren = element.elements("navigation");
         for (Element fromAction: moreChildren)
         {
            parseActionNavigation(page, fromAction);
  @@ -748,7 +748,7 @@
      }
   
      /**
  -    * Parse action-navigation
  +    * Parse navigation
       */
      private static void parseActionNavigation(Page entry, Element element)
      {
  @@ -759,7 +759,7 @@
            navigation.setOutcomeValueBinding( Expressions.instance().createValueBinding(outcomeExpression) );
         }
         
  -      List<Element> cases = element.elements("outcome");
  +      List<Element> cases = element.elements("rule");
         for (Element childElement: cases)
         {
            navigation.getOutcomes().add( parseOutcome(childElement) );
  @@ -811,13 +811,13 @@
      }
   
      /**
  -    * parse outcome, any-outcome, null-outcome
  +    * Parse rule
       */
      private static Outcome parseOutcome(Element element)
      {
         Outcome outcome = new Outcome();
         
  -      outcome.setValue( element.attributeValue("if-value") );
  +      outcome.setValue( element.attributeValue("if-outcome") );
         String expression = element.attributeValue("if");
         if (expression!=null)
         {
  
  
  


From gavin.king at jboss.com  Tue Dec 19 16:07:34 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:07:34 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/WEB-INF  ...
Message-ID: <E1GwmBS-0002rM-W2@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:07:34

  Modified:    examples/blog/resources/WEB-INF  pages.xml
  Log:
  cant make up my damn mind
  
  Revision  Changes    Path
  1.7       +8 -8      jboss-seam/examples/blog/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/WEB-INF/pages.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- pages.xml	18 Dec 2006 16:50:13 -0000	1.6
  +++ pages.xml	19 Dec 2006 21:07:34 -0000	1.7
  @@ -30,9 +30,9 @@
         <action execute="#{postAction.invalid}"
                      if="#{validation.failed}"/>
         
  -      <action-navigation from-action="#{postAction.post}">
  +      <navigation from-action="#{postAction.post}">
            <redirect view-id="/index.xhtml"/>
  -      </action-navigation>
  +      </navigation>
         
      </page>
      
  @@ -41,11 +41,11 @@
         <action execute="#{loginAction.login}"
                      if="#{validation.succeeded}"/>
                      
  -      <action-navigation>
  -         <outcome if="#{loginAction.loggedIn}">
  +      <navigation>
  +         <rule if="#{loginAction.loggedIn}">
               <redirect view-id="/post.xhtml"/>
  -         </outcome>
  -      </action-navigation>
  +         </rule>
  +      </navigation>
         
      </page>
   
  
  
  


From gavin.king at jboss.com  Tue Dec 19 16:07:35 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:07:35 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/resources/WEB-INF  ...
Message-ID: <E1GwmBT-0002rT-3B@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:07:35

  Modified:    examples/booking/resources/WEB-INF  pages.xml
  Log:
  cant make up my damn mind
  
  Revision  Changes    Path
  1.13      +28 -28    jboss-seam/examples/booking/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/resources/WEB-INF/pages.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- pages.xml	19 Dec 2006 18:11:30 -0000	1.12
  +++ pages.xml	19 Dec 2006 21:07:35 -0000	1.13
  @@ -9,31 +9,31 @@
           <action if="#{validation.failed}"
              execute="#{register.invalid}"/>
       
  -        <action-navigation>
  -            <outcome if="#{register.registered}">
  +        <navigation>
  +            <rule if="#{register.registered}">
                   <redirect view-id="/home.xhtml"/>
  -            </outcome>
  -        </action-navigation>
  +            </rule>
  +        </navigation>
           
       </page>
   
       <page view-id="/home.xhtml">
       
  -        <action-navigation>
  -            <outcome if="#{login.loggedIn}">
  +        <navigation>
  +            <rule if="#{login.loggedIn}">
                   <redirect view-id="/main.xhtml"/>
  -            </outcome>
  -        </action-navigation>
  +            </rule>
  +        </navigation>
           
       </page>
       
       <page view-id="/password.xhtml">
       
  -        <action-navigation>
  -            <outcome if="#{changePassword.changed}">
  +        <navigation>
  +            <rule if="#{changePassword.changed}">
                   <redirect view-id="/main.xhtml"/>
  -            </outcome>
  -        </action-navigation>
  +            </rule>
  +        </navigation>
           
       </page>
   
  @@ -41,15 +41,15 @@
       
           <action execute="#{login.validateLogin}"/>
           
  -        <action-navigation from-action="#{login.validateLogin}">
  -            <outcome if="#{not login.loggedIn}">
  +        <navigation from-action="#{login.validateLogin}">
  +            <rule if="#{not login.loggedIn}">
                   <redirect view-id="/home.xhtml"/>
  -            </outcome>
  -        </action-navigation>
  +            </rule>
  +        </navigation>
           
  -        <action-navigation from-action="#{hotelBooking.selectHotel(hot)}">
  +        <navigation from-action="#{hotelBooking.selectHotel(hot)}">
               <redirect view-id="/hotel.xhtml"/>
  -        </action-navigation>
  +        </navigation>
           
       </page>
   
  @@ -58,9 +58,9 @@
             
           <description>View hotel: #{hotel.name}</description>
           
  -        <action-navigation from-action="#{hotelBooking.bookHotel}">
  +        <navigation from-action="#{hotelBooking.bookHotel}">
               <redirect view-id="/book.xhtml"/>
  -        </action-navigation>
  +        </navigation>
           
       </page>
   
  @@ -69,9 +69,9 @@
             
           <description>Book hotel: #{hotel.name}</description>
           
  -        <action-navigation from-action="#{hotelBooking.setBookingDetails}">
  +        <navigation from-action="#{hotelBooking.setBookingDetails}">
               <redirect view-id="/confirm.xhtml"/>
  -        </action-navigation>
  +        </navigation>
           
       </page>
   
  @@ -80,21 +80,21 @@
             
           <description>Confirm booking: #{booking.description}</description>
           
  -        <action-navigation from-action="#{hotelBooking.confirm}">
  +        <navigation from-action="#{hotelBooking.confirm}">
               <redirect view-id="/main.xhtml"/>
  -        </action-navigation>
  +        </navigation>
           
       </page>
       
       <page view-id="*">
       
  -        <action-navigation from-action="#{login.logout}">
  +        <navigation from-action="#{login.logout}">
               <redirect view-id="/home.xhtml"/>
  -        </action-navigation>
  +        </navigation>
   
  -        <action-navigation from-action="#{hotelBooking.cancel}">
  +        <navigation from-action="#{hotelBooking.cancel}">
               <redirect view-id="/main.xhtml"/>
  -        </action-navigation>
  +        </navigation>
           
       </page>
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 16:10:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 16:10:49 -0500
Subject: [jboss-cvs] JBossAS SVN: r59159 - in projects/microcontainer/trunk:
	build container container/src/main/org/jboss
	container/src/resources/tests
	container/src/tests/org/jboss/test deployers osgi-int
Message-ID: <E1GwmEb-0002uy-NJ@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 16:10:36 -0500 (Tue, 19 Dec 2006)
New Revision: 59159

Removed:
   projects/microcontainer/trunk/container/src/main/org/jboss/virtual/
   projects/microcontainer/trunk/container/src/resources/tests/vfs/
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/virtual/
Modified:
   projects/microcontainer/trunk/build/build-thirdparty.xml
   projects/microcontainer/trunk/container/.classpath
   projects/microcontainer/trunk/container/build.xml
   projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java
   projects/microcontainer/trunk/deployers/.classpath
   projects/microcontainer/trunk/deployers/build.xml
   projects/microcontainer/trunk/osgi-int/.classpath
   projects/microcontainer/trunk/osgi-int/build.xml
Log:
Remove the vfs code from the container project.

Modified: projects/microcontainer/trunk/build/build-thirdparty.xml
===================================================================
--- projects/microcontainer/trunk/build/build-thirdparty.xml	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/build/build-thirdparty.xml	2006-12-19 21:10:36 UTC (rev 59159)
@@ -51,6 +51,7 @@
       <componentref name="jboss/common-logging-jdk" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-spi" version="2.0.2.GA"/>
       <componentref name="jboss/jbossxb" version="snapshot"/>
+      <componentref name="jboss/jboss-vfs" version="2.0.0.Beta2"/>
       <componentref name="jboss/profiler/jvmti" version="1.0.0.CR4"/>
       <componentref name="junit" version="3.8.1"/>
       <componentref name="junit4" version="4.1"/>

Modified: projects/microcontainer/trunk/container/.classpath
===================================================================
--- projects/microcontainer/trunk/container/.classpath	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/container/.classpath	2006-12-19 21:10:36 UTC (rev 59159)
@@ -14,5 +14,6 @@
 	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs.jar" sourcepath="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs-sources.jar"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: projects/microcontainer/trunk/container/build.xml
===================================================================
--- projects/microcontainer/trunk/container/build.xml	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/container/build.xml	2006-12-19 21:10:36 UTC (rev 59159)
@@ -73,6 +73,7 @@
       <path refid="jboss/common.core.classpath"/>
       <path refid="jboss/common.logging.spi.classpath"/>
       <path refid="jboss/common.logging.log4j.classpath"/>
+      <path refid="jboss/jboss.vfs.classpath"/>
       <path refid="jboss.test.classpath"/>
     </path>
 

Modified: projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java
===================================================================
--- projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/container/src/tests/org/jboss/test/ContainerAllTestSuite.java	2006-12-19 21:10:36 UTC (rev 59159)
@@ -29,7 +29,6 @@
 import org.jboss.test.classinfo.test.ClassInfoTestSuite;
 import org.jboss.test.joinpoint.test.JoinpointTestSuite;
 import org.jboss.test.metadata.MetaDataAllTestSuite;
-import org.jboss.test.virtual.test.VFSAllTestSuite;
 
 /**
  * All Test Suite.
@@ -52,7 +51,6 @@
       suite.addTest(JoinpointTestSuite.suite());
       suite.addTest(BeanInfoTestSuite.suite());
       suite.addTest(MetaDataAllTestSuite.suite());
-      suite.addTest(VFSAllTestSuite.suite());
       
       return suite;
    }

Modified: projects/microcontainer/trunk/deployers/.classpath
===================================================================
--- projects/microcontainer/trunk/deployers/.classpath	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/deployers/.classpath	2006-12-19 21:10:36 UTC (rev 59159)
@@ -14,5 +14,6 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/kernel"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/dependency"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs.jar" sourcepath="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs-sources.jar"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: projects/microcontainer/trunk/deployers/build.xml
===================================================================
--- projects/microcontainer/trunk/deployers/build.xml	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/deployers/build.xml	2006-12-19 21:10:36 UTC (rev 59159)
@@ -80,6 +80,7 @@
       <path refid="jboss.container.classpath"/>
       <path refid="jboss.dependency.classpath"/>
       <path refid="jboss.kernel.classpath"/>
+      <path refid="jboss/jboss.vfs.classpath"/>
     </path>
      
     <!-- ===== -->

Modified: projects/microcontainer/trunk/osgi-int/.classpath
===================================================================
--- projects/microcontainer/trunk/osgi-int/.classpath	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/osgi-int/.classpath	2006-12-19 21:10:36 UTC (rev 59159)
@@ -2,7 +2,7 @@
 <classpath>
 	<classpathentry kind="src" path="src/main"/>
 	<classpathentry kind="src" path="output/gen-parsers"/>
-	<classpathentry output="output/eclipse-classes-tests" kind="src" path="src/tests"/>
+	<classpathentry kind="src" output="output/eclipse-classes-tests" path="src/tests"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
@@ -14,8 +14,8 @@
 	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.junit.JUNIT_CONTAINER/4"/>
-	<classpathentry combineaccessrules="false" kind="src" path="/container"/>
 	<classpathentry kind="lib" path="/thirdparty/osgi/lib/osgi.compendium.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/osgi/lib/osgi.core.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs.jar" sourcepath="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs-sources.jar"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: projects/microcontainer/trunk/osgi-int/build.xml
===================================================================
--- projects/microcontainer/trunk/osgi-int/build.xml	2006-12-19 20:59:28 UTC (rev 59158)
+++ projects/microcontainer/trunk/osgi-int/build.xml	2006-12-19 21:10:36 UTC (rev 59159)
@@ -75,6 +75,7 @@
       <path refid="jboss/common.core.classpath"/>
       <path refid="jboss/common.logging.spi.classpath"/>
       <path refid="jboss/common.logging.log4j.classpath"/>
+      <path refid="jboss/jboss.vfs.classpath"/>
       <path refid="jboss.test.classpath"/>
       <path refid="jboss.container.classpath"/>
     </path>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 16:11:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 16:11:37 -0500
Subject: [jboss-cvs] JBossAS SVN: r59160 -
	projects/microcontainer/trunk/osgi-int
Message-ID: <E1GwmFN-0002w1-Du@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 16:11:35 -0500 (Tue, 19 Dec 2006)
New Revision: 59160

Modified:
   projects/microcontainer/trunk/osgi-int/.classpath
Log:
Add the container project back for the class loading spi

Modified: projects/microcontainer/trunk/osgi-int/.classpath
===================================================================
--- projects/microcontainer/trunk/osgi-int/.classpath	2006-12-19 21:10:36 UTC (rev 59159)
+++ projects/microcontainer/trunk/osgi-int/.classpath	2006-12-19 21:11:35 UTC (rev 59160)
@@ -17,5 +17,6 @@
 	<classpathentry kind="lib" path="/thirdparty/osgi/lib/osgi.compendium.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/osgi/lib/osgi.core.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs.jar" sourcepath="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs-sources.jar"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/container"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>



From gavin.king at jboss.com  Tue Dec 19 16:16:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:16:54 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GwmKU-000334-LQ@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:16:54

  Modified:    src/main/org/jboss/seam/core  Pages.java
  Log:
  renames
  
  Revision  Changes    Path
  1.73      +21 -21    jboss-seam/src/main/org/jboss/seam/core/Pages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pages.java,v
  retrieving revision 1.72
  retrieving revision 1.73
  diff -u -b -r1.72 -r1.73
  --- Pages.java	19 Dec 2006 21:06:29 -0000	1.72
  +++ Pages.java	19 Dec 2006 21:16:54 -0000	1.73
  @@ -34,10 +34,10 @@
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   import org.jboss.seam.pages.Action;
  -import org.jboss.seam.pages.ActionNavigation;
  +import org.jboss.seam.pages.Navigation;
   import org.jboss.seam.pages.ConversationControl;
   import org.jboss.seam.pages.Input;
  -import org.jboss.seam.pages.Outcome;
  +import org.jboss.seam.pages.Rule;
   import org.jboss.seam.pages.Page;
   import org.jboss.seam.pages.Param;
   import org.jboss.seam.pages.RedirectNavigationHandler;
  @@ -108,7 +108,7 @@
            for (int i=stack.size()-1; i>=0; i--)
            {
               Page page = stack.get(i);
  -            ActionNavigation navigation = page.getNavigations().get(actionExpression);
  +            Navigation navigation = page.getNavigations().get(actionExpression);
               if (navigation==null)
               {
                  navigation = page.getDefaultNavigation();
  @@ -752,23 +752,23 @@
       */
      private static void parseActionNavigation(Page entry, Element element)
      {
  -      ActionNavigation navigation = new ActionNavigation(); 
  +      Navigation navigation = new Navigation(); 
         String outcomeExpression = element.attributeValue("evaluate");
         if (outcomeExpression!=null)
         {
  -         navigation.setOutcomeValueBinding( Expressions.instance().createValueBinding(outcomeExpression) );
  +         navigation.setOutcome( Expressions.instance().createValueBinding(outcomeExpression) );
         }
         
         List<Element> cases = element.elements("rule");
         for (Element childElement: cases)
         {
  -         navigation.getOutcomes().add( parseOutcome(childElement) );
  +         navigation.getRules().add( parseRule(childElement) );
         }
         
  -      Outcome outcome = new Outcome();
  -      parseNavigationHandler(element, outcome);
  -      parseConversationControl( element, outcome.getConversationControl() );
  -      navigation.setOutcome(outcome);
  +      Rule rule = new Rule();
  +      parseNavigationHandler(element, rule);
  +      parseConversationControl( element, rule.getConversationControl() );
  +      navigation.setRule(rule);
         
         String expression = element.attributeValue("from-action");
         if (expression==null)
  @@ -813,30 +813,30 @@
      /**
       * Parse rule
       */
  -   private static Outcome parseOutcome(Element element)
  +   private static Rule parseRule(Element element)
      {
  -      Outcome outcome = new Outcome();
  +      Rule rule = new Rule();
         
  -      outcome.setValue( element.attributeValue("if-outcome") );
  +      rule.setOutcomeValue( element.attributeValue("if-outcome") );
         String expression = element.attributeValue("if");
         if (expression!=null)
         {
  -         outcome.setExpression( Expressions.instance().createValueBinding(expression)  );
  +         rule.setCondition( Expressions.instance().createValueBinding(expression)  );
         }
         
  -      parseConversationControl( element, outcome.getConversationControl() );
  -      parseNavigationHandler(element, outcome);
  +      parseConversationControl( element, rule.getConversationControl() );
  +      parseNavigationHandler(element, rule);
         
  -      return outcome;
  +      return rule;
      }
   
  -   private static void parseNavigationHandler(Element element, Outcome outcome)
  +   private static void parseNavigationHandler(Element element, Rule rule)
      {
         Element render = element.element("render");
         if (render!=null)
         {
            final String viewId = render.attributeValue("view-id");
  -         outcome.setNavigationHandler( new RenderNavigationHandler(viewId) );
  +         rule.setNavigationHandler( new RenderNavigationHandler(viewId) );
         }
         Element redirect = element.element("redirect");
         if (redirect!=null)
  @@ -848,7 +848,7 @@
               params.add( parseParam(child) );
            }
            final String viewId = redirect.attributeValue("view-id");
  -         outcome.setNavigationHandler( new RedirectNavigationHandler(viewId, params) );
  +         rule.setNavigationHandler( new RedirectNavigationHandler(viewId, params) );
         }
         List<Element> childElements = element.elements("out");
         for (Element child: childElements)
  @@ -865,7 +865,7 @@
            {
               output.setScope( ScopeType.valueOf( scopeName.toUpperCase() ) );
            }
  -         outcome.getOutputs().add(output);
  +         rule.getOutputs().add(output);
         }
         
      }
  
  
  


From gavin.king at jboss.com  Tue Dec 19 16:16:54 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:16:54 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/pages      ...
Message-ID: <E1GwmKU-00033H-P5@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:16:54

  Modified:    src/main/org/jboss/seam/pages      Page.java
  Added:       src/main/org/jboss/seam/pages      Navigation.java Rule.java
  Removed:     src/main/org/jboss/seam/pages      ActionNavigation.java
                        Outcome.java
  Log:
  renames
  
  Revision  Changes    Path
  1.4       +5 -5      jboss-seam/src/main/org/jboss/seam/pages/Page.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Page.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/pages/Page.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- Page.java	19 Dec 2006 00:40:41 -0000	1.3
  +++ Page.java	19 Dec 2006 21:16:54 -0000	1.4
  @@ -27,8 +27,8 @@
      private List<Param> parameters = new ArrayList<Param>();
      private List<Input> inputs = new ArrayList<Input>();
      private List<Action> actions = new ArrayList<Action>();
  -   private Map<String, ActionNavigation> navigations = new HashMap<String, ActionNavigation>();
  -   private ActionNavigation defaultNavigation;
  +   private Map<String, Navigation> navigations = new HashMap<String, Navigation>();
  +   private Navigation defaultNavigation;
      private boolean conversationRequired;
      private ConversationControl conversationControl = new ConversationControl();
      
  @@ -140,7 +140,7 @@
         return parameters;
      }
   
  -   public Map<String, ActionNavigation> getNavigations()
  +   public Map<String, Navigation> getNavigations()
      {
         return navigations;
      }
  @@ -160,12 +160,12 @@
         this.conversationRequired = conversationRequired;
      }
   
  -   public ActionNavigation getDefaultNavigation()
  +   public Navigation getDefaultNavigation()
      {
         return defaultNavigation;
      }
   
  -   public void setDefaultNavigation(ActionNavigation defaultActionOutcomeMapping)
  +   public void setDefaultNavigation(Navigation defaultActionOutcomeMapping)
      {
         this.defaultNavigation = defaultActionOutcomeMapping;
      }
  
  
  
  1.1      date: 2006/12/19 21:16:54;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Navigation.java
  
  Index: Navigation.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import java.util.ArrayList;
  import java.util.List;
  
  import javax.faces.context.FacesContext;
  
  import org.jboss.seam.core.Expressions.ValueBinding;
  
  public final class Navigation
  {
     private ValueBinding<Object> outcome;
     private List<Rule> rules = new ArrayList<Rule>();
     private Rule rule;
     
     public List<Rule> getRules()
     {
        return rules;
     }
     
     public void setOutcome(ValueBinding<Object> outcomeValueBinding)
     {
        this.outcome = outcomeValueBinding;
     }
     
     public ValueBinding<Object> getOutcome()
     {
        return outcome;
     }
  
     public Rule getRule()
     {
        return rule;
     }
  
     public void setRule(Rule rule)
     {
        this.rule = rule;
     }
  
     public boolean navigate(FacesContext context, final String actionOutcomeValue)
     {
        String outcomeValue;
        if ( getOutcome()==null )
        {
           outcomeValue = actionOutcomeValue;
        }
        else
        {
           Object value = getOutcome().getValue();
           outcomeValue = value==null ? null : value.toString();
        }
        
        for ( Rule rule: getRules() )
        {
           if ( rule.matches(outcomeValue) )
           {
              return rule.execute(context);
           }
        }
        
        return getRule().execute(context);
     }
  
  }
  
  
  1.1      date: 2006/12/19 21:16:54;  author: gavin;  state: Exp;jboss-seam/src/main/org/jboss/seam/pages/Rule.java
  
  Index: Rule.java
  ===================================================================
  /**
   * 
   */
  package org.jboss.seam.pages;
  
  import java.util.ArrayList;
  import java.util.List;
  
  import javax.faces.context.FacesContext;
  
  import org.jboss.seam.core.Expressions.ValueBinding;
  
  public final class Rule
  {
     private String outcomeValue;
     private ValueBinding condition;
     private List<Output> outputs = new ArrayList<Output>();
     private ConversationControl conversationControl = new ConversationControl();
     private NavigationHandler navigationHandler = new NavigationHandler() { 
        @Override
        public boolean navigate(FacesContext context) 
        {
           return false;
        }
     };
  
     public boolean matches(String actualValue)
     {
        return ( actualValue!=null || condition!=null ) &&
              ( outcomeValue==null || outcomeValue.equals(actualValue) ) &&
              ( condition==null || Boolean.TRUE.equals( condition.getValue() ) );
     }
     
     public NavigationHandler getNavigationHandler()
     {
        return navigationHandler;
     }
  
     public void setNavigationHandler(NavigationHandler result)
     {
        this.navigationHandler = result;
     }
  
     public ConversationControl getConversationControl()
     {
        return conversationControl;
     }
  
     public ValueBinding getCondition()
     {
        return condition;
     }
  
     public void setCondition(ValueBinding expression)
     {
        this.condition = expression;
     }
  
     public String getOutcomeValue()
     {
        return outcomeValue;
     }
  
     public void setOutcomeValue(String value)
     {
        this.outcomeValue = value;
     }
  
     public List<Output> getOutputs()
     {
        return outputs;
     }
  
     public boolean execute(FacesContext context)
     {
        getConversationControl().beginOrEndConversation();
        for ( Output output: getOutputs() ) output.out();
        return getNavigationHandler().navigate(context);
     }
  }
  
  


From gdsar745a1 at fastermail.com  Tue Dec 19 16:17:05 2006
From: gdsar745a1 at fastermail.com (gdsar745a1 at fastermail.com)
Date: Tue, 19 Dec 2006 16:17:05 -0500
Subject: [jboss-cvs] =?utf-8?b?woJQwpPDusKCVMKWwpzCgULClMKRwoLDnMKCw6g=?=
	=?utf-8?b?woLDiMKCw6fCglDCgk/ClsKcwo54wpXCpcKCwqLCgsOcwoLCt8KBQg==?=
Message-ID: 20061220064431.29459mail@mail.rtyuisksakdjaskutuyekjhsadkjsdnasmn.com

?????????????????B?????????????B
?o?c?C?`?????B?????????S?N?o???????B
http://5596.jp/?kiarh
?U?????????????????????????????????????A?????????????????????????B
?????????????????????????????????????B?????????????????????????????????????H
?????????^?_???????????????????B
?????????H???????????????????B
?}?C?v???t?????^?????????????????????A?????????????????z???????????????????B
http://5596.jp/?kiarh
?R?????g?????????????B



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 16:18:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 16:18:14 -0500
Subject: [jboss-cvs] JBossAS SVN: r59161 -
	trunk/system/src/main/org/jboss/system/server
Message-ID: <E1GwmLm-00033S-HA@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 16:18:12 -0500 (Tue, 19 Dec 2006)
New Revision: 59161

Modified:
   trunk/system/src/main/org/jboss/system/server/ServerLoader.java
Log:
Add the jboss-vfs.jar to the bootstrap lib

Modified: trunk/system/src/main/org/jboss/system/server/ServerLoader.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/ServerLoader.java	2006-12-19 21:11:35 UTC (rev 59160)
+++ trunk/system/src/main/org/jboss/system/server/ServerLoader.java	2006-12-19 21:18:12 UTC (rev 59161)
@@ -78,7 +78,7 @@
     * TODO: use vfs to list the root directory
     */
    public static final String DEFAULT_BOOT_LIBRARY_LIST =
-      "log4j-boot.jar,jboss-common-core.jar,jboss-logging-spi.jar,jboss-logging-log4j.jar,jboss-logging-jdk.jar,jboss-system.jar,jboss-xml-binding.jar,javassist.jar,jboss-aop-mc-int-boot.jar,jboss-container.jar,jboss-dependency.jar,jboss-microcontainer.jar,jboss-deployers.jar,dom4j.jar,jboss-j2se.jar,jboss-mbeans.jar,jboss-jmx.jar,jboss-system-jmx.jar";
+      "log4j-boot.jar,jboss-common-core.jar,jboss-logging-spi.jar,jboss-logging-log4j.jar,jboss-logging-jdk.jar,jboss-system.jar,jboss-xml-binding.jar,javassist.jar,jboss-aop-mc-int-boot.jar,jboss-vfs.jar,jboss-container.jar,jboss-dependency.jar,jboss-microcontainer.jar,jboss-deployers.jar,dom4j.jar,jboss-j2se.jar,jboss-mbeans.jar,jboss-jmx.jar,jboss-system-jmx.jar";
 
    /** The default server type. */
    public static final String DEFAULT_SERVER_TYPE = "org.jboss.system.server.profileservice.ServerImpl";



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 16:19:58 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 16:19:58 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59162 - trunk/build
Message-ID: <E1GwmNS-00033l-Om@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-19 16:19:56 -0500 (Tue, 19 Dec 2006)
New Revision: 59162

Modified:
   trunk/build/build-thirdparty.xml
Log:
Roll back the aop version

Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-19 21:18:12 UTC (rev 59161)
+++ trunk/build/build-thirdparty.xml	2006-12-19 21:19:56 UTC (rev 59162)
@@ -84,8 +84,8 @@
       <componentref name="jacorb" version="2.2.4jboss.patch1"/>
       <componentref name="javassist" version="3.4.GA"/>
       <componentref name="jaxen" version="1.1-beta-9"/>
-      <componentref name="jboss/aop" version="snapshot"/>
-      <componentref name="jboss/aop14" version="snapshot"/>
+      <componentref name="jboss/aop" version="2.0.0.alpha2"/>
+      <componentref name="jboss/aop14" version="2.0.0.alpha2"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/cache" version="2.0.0.ALPHA1"/>
       <componentref name="jboss/common-core" version="2.0.3.GA"/>



From gavin.king at jboss.com  Tue Dec 19 16:49:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:49:29 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1Gwmq1-0003VE-Li@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:49:29

  Modified:    src/main/org/jboss/seam/contexts  Lifecycle.java
  Log:
  fix bug JBSEAM-618
  
  Revision  Changes    Path
  1.74      +19 -5     jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.73
  retrieving revision 1.74
  diff -u -b -r1.73 -r1.74
  --- Lifecycle.java	16 Dec 2006 16:05:20 -0000	1.73
  +++ Lifecycle.java	19 Dec 2006 21:49:29 -0000	1.74
  @@ -30,7 +30,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.73 $
  + * @version $Revision: 1.74 $
    */
   public class Lifecycle
   {
  @@ -227,10 +227,7 @@
         log.debug("destroying conversation contexts: " + conversationIds);
         for (String conversationId: conversationIds)
         {
  -         ServerConversationContext conversationContext = new ServerConversationContext(session, conversationId);
  -         Contexts.conversationContext.set(conversationContext);
  -         Contexts.destroy(conversationContext);
  -         Contexts.conversationContext.set(null);
  +         destroyConversationContext(session, conversationId);
         }
         
         Context tempConversationContext = new MapContext(ScopeType.CONVERSATION);
  @@ -459,4 +456,21 @@
         return attribute instanceof Mutable && ( (Mutable) attribute ).clearDirty();
      }
   
  +   public static void destroyConversationContext(ContextAdaptor session, String conversationId)
  +   {
  +      ServerConversationContext conversationContext = new ServerConversationContext(session, conversationId);
  +      Context old = Contexts.getConversationContext();
  +      Contexts.conversationContext.set(conversationContext);
  +      try
  +      {
  +         Contexts.destroy( conversationContext );
  +         conversationContext.clear();
  +         conversationContext.flush();
  +      }
  +      finally
  +      {
  +         Contexts.conversationContext.set(old);
  +      }
  +   }
  +
   }
  
  
  


From gavin.king at jboss.com  Tue Dec 19 16:49:29 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 16:49:29 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gwmq1-0003VL-Pe@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 16:49:29

  Modified:    src/main/org/jboss/seam/core  Manager.java
  Log:
  fix bug JBSEAM-618
  
  Revision  Changes    Path
  1.132     +3 -7      jboss-seam/src/main/org/jboss/seam/core/Manager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Manager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Manager.java,v
  retrieving revision 1.131
  retrieving revision 1.132
  diff -u -b -r1.131 -r1.132
  --- Manager.java	19 Dec 2006 16:57:04 -0000	1.131
  +++ Manager.java	19 Dec 2006 21:49:29 -0000	1.132
  @@ -32,7 +32,6 @@
   import org.jboss.seam.contexts.ContextAdaptor;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.contexts.Lifecycle;
  -import org.jboss.seam.contexts.ServerConversationContext;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   import org.jboss.seam.util.Id;
  @@ -42,7 +41,7 @@
    *
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.131 $
  + * @version $Revision: 1.132 $
    */
   @Scope(ScopeType.EVENT)
   @Name("org.jboss.seam.core.manager")
  @@ -319,10 +318,7 @@
       */
      private void destroyConversation(String conversationId, ContextAdaptor session)
      {
  -      ServerConversationContext conversationContext = new ServerConversationContext(session, conversationId);
  -      Contexts.destroy( conversationContext );
  -      conversationContext.clear();
  -      conversationContext.flush();
  +      Lifecycle.destroyConversationContext(session, conversationId);
         ConversationEntries.instance().removeConversationEntry(conversationId);
      }
      
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 17:51:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 17:51:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59163 -
	trunk/j2ee/src/main/javax/security/jacc
Message-ID: <E1GwnoA-0004hv-59@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-19 17:51:37 -0500 (Tue, 19 Dec 2006)
New Revision: 59163

Modified:
   trunk/j2ee/src/main/javax/security/jacc/WebResourcePermission.java
   trunk/j2ee/src/main/javax/security/jacc/WebUserDataPermission.java
Log:
use exclusion list based on jacc 1.1

Modified: trunk/j2ee/src/main/javax/security/jacc/WebResourcePermission.java
===================================================================
--- trunk/j2ee/src/main/javax/security/jacc/WebResourcePermission.java	2006-12-19 21:19:56 UTC (rev 59162)
+++ trunk/j2ee/src/main/javax/security/jacc/WebResourcePermission.java	2006-12-19 22:51:37 UTC (rev 59163)
@@ -45,6 +45,7 @@
  * 
  * 
  * @author Scott.Stark at jboss.org
+ * @author Anil.Saldhana at jboss.org
  * @author Ron Monzillo, Gary Ellison (javadoc)
  * @version $Revision$
  */
@@ -80,6 +81,8 @@
    private transient URLPatternSpec urlSpec;
    private transient String httpMethodsString;
    private transient TreeSet httpMethods;
+   private transient TreeSet httpExceptionList;
+   private transient String httpExceptionString;
 
    /** Creates a new WebResourcePermission from the HttpServletRequest object.
     * 
@@ -134,11 +137,11 @@
 
     HTTPMethod ::= "GET" | "POST" | "PUT" | "DELETE" | "HEAD" |
     "OPTIONS" | "TRACE"
-          
-    HTTPMethodList ::= HTTPMethod | HTTPMethodList comma HTTPMethod
+    
+    HTTPMethodExceptionList ::= exclaimationPoint HTTPMethodList
+    HTTPMethodList ::= HTTPMethod | HTTPMethodList comma HTTPMethod 
+    HTTPMethodSpec ::= null | emptyString | HTTPMethodExceptionList | HTTPMethodList
  
-    HTTPMethodSpec ::= null | HTTPMethodList
- 
 
     If duplicates occur in the HTTPMethodSpec they must be eliminated by the
     permission constructor.
@@ -204,10 +207,17 @@
     */
    public boolean equals(Object p)
    {
-      boolean equals = false;
+      //boolean equals = false;
       if( p == null || !(p instanceof WebResourcePermission) )
          return false;
       WebResourcePermission perm = (WebResourcePermission) p;
+      
+      /**
+       * Two permissions p1 and p2 are equivalent if and only if p1.implies(p2)
+       * and p2.implies(p1)
+       */
+      return this.implies(perm) && perm.implies(this);
+      /*
       equals = urlSpec.equals(perm.urlSpec);
       if( equals == true )
       {
@@ -215,7 +225,7 @@
          String a1 = perm.getActions();
          equals = (a0 != null && a0.equals(a1)) || (a0 == a1);
       }
-      return equals;
+      return equals;*/
    }
 
    /** Returns a canonical String representation of the actions of this
@@ -297,9 +307,11 @@
       boolean implies = urlSpec.implies(perm.urlSpec);
       if( implies == true )
       {
-         // Check the http methods
-         if( httpMethods != null )
-            implies = httpMethods.containsAll(perm.httpMethods);
+         if(httpExceptionList != null)
+            implies = matchExceptionList(httpExceptionList, perm.httpExceptionList); 
+         //Check the http methods
+         if( httpMethods != null && perm.httpMethods != null)
+               implies = httpMethods.containsAll(perm.httpMethods); 
       }
 
       return implies;
@@ -389,9 +401,21 @@
    // Private -------------------------------------------------------
    private void parseActions(String actions)
    {
+      boolean exclusionListNeeded = actions != null && actions.startsWith("!");
+      if(exclusionListNeeded) 
+         actions = actions.substring(1); 
+      
       Object[] methodInfo = canonicalMethods(actions);
-      this.httpMethods = (TreeSet) methodInfo[0];
-      this.httpMethodsString = (String) methodInfo[1];
+      if(exclusionListNeeded)
+      {
+         this.httpExceptionList = (TreeSet) methodInfo[0];
+         this.httpExceptionString = (String) methodInfo[1]; 
+      }
+      else
+      { 
+         this.httpMethods = (TreeSet) methodInfo[0];
+         this.httpMethodsString = (String) methodInfo[1];
+      }
    }
 
    private void readObject(ObjectInputStream ois)
@@ -408,5 +432,25 @@
       ObjectOutputStream.PutField fields =  oos.putFields();
       fields.put("actions", this.getActions());
       oos.writeFields();
+   } 
+   
+   static boolean matchExceptionList(TreeSet<String> myExceptionList,
+          TreeSet<String> matchingExceptionList)
+   { 
+      boolean bothnull = (myExceptionList == null && matchingExceptionList == null);
+      boolean onenull = (myExceptionList == null && matchingExceptionList != null)
+               || (myExceptionList != null && matchingExceptionList == null);
+      
+      if(bothnull)
+         return true;
+      if(onenull)
+         return false;  
+      
+      for(String httpMethod: matchingExceptionList)
+      {
+         if(myExceptionList.contains(httpMethod))
+            return false;
+      }
+      return true;
    }
 }

Modified: trunk/j2ee/src/main/javax/security/jacc/WebUserDataPermission.java
===================================================================
--- trunk/j2ee/src/main/javax/security/jacc/WebUserDataPermission.java	2006-12-19 21:19:56 UTC (rev 59162)
+++ trunk/j2ee/src/main/javax/security/jacc/WebUserDataPermission.java	2006-12-19 22:51:37 UTC (rev 59163)
@@ -41,6 +41,7 @@
  * @link http://java.sun.com/j2ee/1.4/docs/api/
  * 
  * @author Scott.Stark at jboss.org
+ * @author Anil.Saldhana at jboss.org
  * @author Ron Monzillo, Gary Ellison (javadoc)
  * @version $Revision$
  */
@@ -69,6 +70,8 @@
    private transient String httpMethodsString;
    private transient String transportType;
    private transient TreeSet httpMethods;
+   private transient TreeSet httpExceptionList;
+   private transient String httpExceptionString;
 
    /** Creates a new WebUserDataPermission from the HttpServletRequest object.
     * 
@@ -126,8 +129,11 @@
 
           HTTPMethodList ::= HTTPMethod | HTTPMethodList comma HTTPMethod
 
-          HTTPMethodSpec ::= emptyString | HTTPMethodList
+          HTTPMethodExceptionList ::= exclaimationPoint HTTPMethodList
 
+          HTTPMethodSpec ::= emptyString | HTTPMethodExceptionList |
+                  HTTPMethodList
+
           transportType ::= "INTEGRAL" | "CONFIDENTIAL" | "NONE"
 
           actions ::= null | HTTPMethodSpec | 
@@ -211,18 +217,23 @@
     */ 
    public boolean equals(Object p)
    {
-      boolean equals = false;
+      //boolean equals = false;
       if( p == null || !(p instanceof WebUserDataPermission) )
          return false;
       WebUserDataPermission perm = (WebUserDataPermission) p;
-      equals = urlSpec.equals(perm.urlSpec);
+      /**
+       * Two Permission objects, P1 and P2, are equivalent 
+       * if and only if P1.implies(P2) && P2.implies(P1).
+       */
+      return this.implies(perm) && perm.implies(this);
+      /*equals = urlSpec.equals(perm.urlSpec);
       if( equals == true )
       {
          String a0 = getActions();
          String a1 = perm.getActions();
          equals = (a0 != null && a0.equals(a1)) || (a0 == a1);
       }
-      return equals;
+      return equals;*/
    }
 
    /** Returns a canonical String representation of the actions of this
@@ -337,14 +348,17 @@
       boolean implies = urlSpec.implies(perm.urlSpec);
       if( implies == true )
       {
-         // Check the http methods
-         if( httpMethods != null )
-            implies = httpMethods.containsAll(perm.httpMethods);
+         if(httpExceptionList != null)
+            implies = WebResourcePermission.matchExceptionList(httpExceptionList, 
+                  perm.httpExceptionList); 
+         //Check the http methods
+         if( httpMethods != null && perm.httpMethods != null)
+               implies = httpMethods.containsAll(perm.httpMethods);  
          // Check the transport guarentee
          if( implies == true && transportType != null )
             implies = transportType.equals(perm.transportType);
-      }
-
+      }  
+      
       return implies;
    }
 
@@ -377,9 +391,19 @@
             actions = actions.substring(0, colon);
          }
       }
+      boolean exceptionListNeeded = actions != null && actions.startsWith("!");
+      
       Object[] methodInfo = WebResourcePermission.canonicalMethods(actions);
-      this.httpMethods = (TreeSet) methodInfo[0];
-      this.httpMethodsString = (String) methodInfo[1];
+      if(exceptionListNeeded)
+      {
+         this.httpExceptionList = (TreeSet) methodInfo[0];
+         this.httpExceptionString = (String) methodInfo[1];
+      }
+      else
+      { 
+         this.httpMethods = (TreeSet) methodInfo[0];
+         this.httpMethodsString = (String) methodInfo[1];
+      }
    }
 
    private void readObject(ObjectInputStream ois)



From gavin.king at jboss.com  Tue Dec 19 17:54:44 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 17:54:44 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1GwnrA-0004iU-Pf@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 17:54:44

  Modified:    src/main/org/jboss/seam/contexts 
                        ServerConversationContext.java
  Log:
  fix npe
  
  Revision  Changes    Path
  1.19      +7 -4      jboss-seam/src/main/org/jboss/seam/contexts/ServerConversationContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerConversationContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/ServerConversationContext.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- ServerConversationContext.java	13 Dec 2006 04:54:19 -0000	1.18
  +++ ServerConversationContext.java	19 Dec 2006 22:54:44 -0000	1.19
  @@ -26,7 +26,7 @@
    * 
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.18 $
  + * @version $Revision: 1.19 $
    */
   public class ServerConversationContext implements Context {
   
  @@ -206,9 +206,7 @@
       */
      public void flush()
      {      
  -      Manager manager = Manager.instance();
  -      boolean longRunning = manager.isLongRunningConversation() ||
  -            !manager.getCurrentConversationId().equals( getId() );  
  +      boolean longRunning = !isCurrent() || Manager.instance().isLongRunningConversation();  
         if ( longRunning )
         {
            //force update for dirty mutable objects
  @@ -244,6 +242,11 @@
         }
      }
   
  +   private boolean isCurrent()
  +   {
  +      return id==null || id.equals( Manager.instance().getCurrentConversationId() );
  +   }
  +
      @Override
      public String toString()
      {
  
  
  


From gavin.king at jboss.com  Tue Dec 19 18:12:22 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 18:12:22 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts  ...
Message-ID: <E1Gwo8E-0005Bp-RC@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 18:12:22

  Modified:    src/main/org/jboss/seam/contexts  Lifecycle.java
  Log:
  minor opt
  
  Revision  Changes    Path
  1.75      +7 -4      jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Lifecycle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/Lifecycle.java,v
  retrieving revision 1.74
  retrieving revision 1.75
  diff -u -b -r1.74 -r1.75
  --- Lifecycle.java	19 Dec 2006 21:49:29 -0000	1.74
  +++ Lifecycle.java	19 Dec 2006 23:12:22 -0000	1.75
  @@ -30,7 +30,7 @@
   /**
    * @author Gavin King
    * @author <a href="mailto:theute at jboss.org">Thomas Heute</a>
  - * @version $Revision: 1.74 $
  + * @version $Revision: 1.75 $
    */
   public class Lifecycle
   {
  @@ -463,10 +463,13 @@
         Contexts.conversationContext.set(conversationContext);
         try
         {
  -         Contexts.destroy( conversationContext );
  +         Contexts.destroy(conversationContext);
  +         if ( !Seam.isSessionInvalid() ) //its also unnecessary during a session timeout
  +         {
            conversationContext.clear();
            conversationContext.flush();
         }
  +      }
         finally
         {
            Contexts.conversationContext.set(old);
  
  
  


From gavin.king at jboss.com  Tue Dec 19 18:12:42 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 18:12:42 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1Gwo8Y-0005Cn-KX@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 18:12:42

  Modified:    examples/booking/src/org/jboss/seam/example/booking  
                        HotelBookingAction.java LoggedInInterceptor.java
  Log:
  let the beans be destroyed
  
  Revision  Changes    Path
  1.44      +4 -2      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelBookingAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java,v
  retrieving revision 1.43
  retrieving revision 1.44
  diff -u -b -r1.43 -r1.44
  --- HotelBookingAction.java	17 Dec 2006 01:04:51 -0000	1.43
  +++ HotelBookingAction.java	19 Dec 2006 23:12:42 -0000	1.44
  @@ -1,4 +1,4 @@
  -//$Id: HotelBookingAction.java,v 1.43 2006/12/17 01:04:51 gavin Exp $
  +//$Id: HotelBookingAction.java,v 1.44 2006/12/19 23:12:42 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static javax.persistence.PersistenceContextType.EXTENDED;
  @@ -102,6 +102,8 @@
      public void cancel() {}
      
      @Destroy @Remove
  -   public void destroy() {}
  +   public void destroy() {
  +      System.out.println("!!!!");
  +   }
   
   }
  \ No newline at end of file
  
  
  
  1.16      +6 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoggedInInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- LoggedInInterceptor.java	17 Dec 2006 14:07:46 -0000	1.15
  +++ LoggedInInterceptor.java	19 Dec 2006 23:12:42 -0000	1.16
  @@ -1,4 +1,4 @@
  -//$Id: LoggedInInterceptor.java,v 1.15 2006/12/17 14:07:46 gavin Exp $
  +//$Id: LoggedInInterceptor.java,v 1.16 2006/12/19 23:12:42 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import java.lang.reflect.Method;
  @@ -9,6 +9,7 @@
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.annotations.Interceptor;
  +import org.jboss.seam.contexts.Lifecycle;
   
   @Interceptor(type=InterceptorType.CLIENT)
   public class LoggedInInterceptor
  @@ -17,8 +18,9 @@
      @AroundInvoke
      public Object checkLoggedIn(InvocationContext invocation) throws Exception
      {
  -      Login login = (Login) Component.getInstance(LoginAction.class);
  -      if ( login.isLoggedIn() )
  +      boolean allowed = Lifecycle.isDestroying() || 
  +            ( (Login) Component.getInstance(LoginAction.class) ).isLoggedIn();
  +      if ( allowed )
         {
            return invocation.proceed();
         }
  
  
  


From gavin.king at jboss.com  Tue Dec 19 18:13:11 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 18:13:11 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/booking/src/org/jboss/seam/example/booking ...
Message-ID: <E1Gwo91-0005D0-EU@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 18:13:11

  Modified:    examples/booking/src/org/jboss/seam/example/booking 
                        HotelBookingAction.java
  Log:
  oops
  
  Revision  Changes    Path
  1.45      +2 -4      jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HotelBookingAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- HotelBookingAction.java	19 Dec 2006 23:12:42 -0000	1.44
  +++ HotelBookingAction.java	19 Dec 2006 23:13:11 -0000	1.45
  @@ -1,4 +1,4 @@
  -//$Id: HotelBookingAction.java,v 1.44 2006/12/19 23:12:42 gavin Exp $
  +//$Id: HotelBookingAction.java,v 1.45 2006/12/19 23:13:11 gavin Exp $
   package org.jboss.seam.example.booking;
   
   import static javax.persistence.PersistenceContextType.EXTENDED;
  @@ -102,8 +102,6 @@
      public void cancel() {}
      
      @Destroy @Remove
  -   public void destroy() {
  -      System.out.println("!!!!");
  -   }
  +   public void destroy() {}
   
   }
  \ No newline at end of file
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 19:13:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 19:13:00 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59164 - branches/Branch_4_2/build
Message-ID: <E1Gwp4u-0006Lf-Re@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-19 19:12:59 -0500 (Tue, 19 Dec 2006)
New Revision: 59164

Modified:
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
[JBAS-3891] Upgrade to JGroups 2.4.1

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-19 22:51:37 UTC (rev 59163)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-20 00:12:59 UTC (rev 59164)
@@ -100,7 +100,7 @@
       <componentref name="jboss/remoting" version="1.4.5.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
       <componentref name="jfreechart" version="0.9.20"/>
-      <componentref name="jgroups" version="2.4"/>
+      <componentref name="jgroups" version="2.4.1"/>
       <componentref name="joesnmp" version="0.3.4"/>
       <componentref name="juddi" version="0.9RC4"/>
       <componentref name="junit" version="3.8.1"/>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 19:46:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 19:46:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59165 -
	branches/Branch_4_0/system/src/main/org/jboss/system/server/jmx
Message-ID: <E1GwpbC-0006u3-92@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 19:46:20 -0500 (Tue, 19 Dec 2006)
New Revision: 59165

Modified:
   branches/Branch_4_0/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
Log:
JBAS-3947, reload the server domains on InstanceNotFoundException failures in isInstanceOf calls.

Modified: branches/Branch_4_0/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
===================================================================
--- branches/Branch_4_0/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 00:12:59 UTC (rev 59164)
+++ branches/Branch_4_0/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 00:46:20 UTC (rev 59165)
@@ -61,9 +61,13 @@
 public class LazyMBeanServer
    implements MBeanServer
 {
+   /** The MBeanServer that was registered */
    private static MBeanServer registeredServer;
+   /** The jboss MBeanServer implementation */
    private static MBeanServer theServer;
+   /** The jdk MBeanServer implementation */
    private static MBeanServer platformServer;
+   /** The default domain to use for mbeans */
    private static String defaultDomain;
    private static MBeanServerDelegate theDelegate;
    /** A HashSet<String> of the jmx domain prefixes that need to be
@@ -137,6 +141,14 @@
          serverDomains.add(domains[n]);
       }
    }
+   /**
+    * 
+    * @param domain - the default domain when an MBean is
+    *        registered with an ObjectName without a domain
+    * @param outer - the wrapping MBeanServer, passed to MBeans
+    *        at registration.
+    * @param delegate the delegate to use for Notifications.
+    */
    LazyMBeanServer(String domain, MBeanServer outer,
       MBeanServerDelegate delegate)
    {
@@ -370,7 +382,17 @@
    public boolean isInstanceOf(ObjectName name, String className)
       throws InstanceNotFoundException
    {
-      return getServer(name).isInstanceOf(name, className);
+      boolean isInstanceOf = false;
+      try
+      {
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      catch(InstanceNotFoundException e)
+      {
+         reloadDomains();
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      return isInstanceOf;
    }
 
    public Object instantiate(String className)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 20:46:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 20:46:33 -0500
Subject: [jboss-cvs] JBossAS SVN: r59166 -
	trunk/system-jmx/src/main/org/jboss/system/server/jmx
Message-ID: <E1GwqXR-00086z-Uc@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 20:46:31 -0500 (Tue, 19 Dec 2006)
New Revision: 59166

Modified:
   trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
Log:
JBAS-3947, reload the server domains on InstanceNotFoundException failures in isInstanceOf calls.

Modified: trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
===================================================================
--- trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 00:46:20 UTC (rev 59165)
+++ trunk/system-jmx/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 01:46:31 UTC (rev 59166)
@@ -1,24 +1,24 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.system.server.jmx;
 
 import java.io.ObjectInputStream;
@@ -61,9 +61,13 @@
 public class LazyMBeanServer
    implements MBeanServer
 {
+   /** The MBeanServer that was registered */
    private static MBeanServer registeredServer;
+   /** The jboss MBeanServer implementation */
    private static MBeanServer theServer;
+   /** The jdk MBeanServer implementation */
    private static MBeanServer platformServer;
+   /** The default domain to use for mbeans */
    private static String defaultDomain;
    private static MBeanServerDelegate theDelegate;
    /** A HashSet<String> of the jmx domain prefixes that need to be
@@ -370,7 +374,17 @@
    public boolean isInstanceOf(ObjectName name, String className)
       throws InstanceNotFoundException
    {
-      return getServer(name).isInstanceOf(name, className);
+      boolean isInstanceOf = false;
+      try
+      {
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      catch(InstanceNotFoundException e)
+      {
+         reloadDomains();
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      return isInstanceOf;
    }
 
    public Object instantiate(String className)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 20:54:59 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 20:54:59 -0500
Subject: [jboss-cvs] JBossAS SVN: r59167 -
	branches/Branch_4_2/system/src/main/org/jboss/system/server/jmx
Message-ID: <E1Gwqfb-0008DJ-T7@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 20:54:57 -0500 (Tue, 19 Dec 2006)
New Revision: 59167

Modified:
   branches/Branch_4_2/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
Log:
JBAS-3947, reload the server domains on InstanceNotFoundException failures in isInstanceOf calls.

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 01:46:31 UTC (rev 59166)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 01:54:57 UTC (rev 59167)
@@ -61,9 +61,13 @@
 public class LazyMBeanServer
    implements MBeanServer
 {
+   /** The MBeanServer that was registered */
    private static MBeanServer registeredServer;
+   /** The jboss MBeanServer implementation */
    private static MBeanServer theServer;
+   /** The jdk MBeanServer implementation */
    private static MBeanServer platformServer;
+   /** The default domain to use for mbeans */
    private static String defaultDomain;
    private static MBeanServerDelegate theDelegate;
    /** A HashSet<String> of the jmx domain prefixes that need to be
@@ -137,6 +141,14 @@
          serverDomains.add(domains[n]);
       }
    }
+   /**
+    * 
+    * @param domain - the default domain when an MBean is
+    *        registered with an ObjectName without a domain
+    * @param outer - the wrapping MBeanServer, passed to MBeans
+    *        at registration.
+    * @param delegate the delegate to use for Notifications.
+    */
    LazyMBeanServer(String domain, MBeanServer outer,
       MBeanServerDelegate delegate)
    {
@@ -370,7 +382,17 @@
    public boolean isInstanceOf(ObjectName name, String className)
       throws InstanceNotFoundException
    {
-      return getServer(name).isInstanceOf(name, className);
+      boolean isInstanceOf = false;
+      try
+      {
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      catch(InstanceNotFoundException e)
+      {
+         reloadDomains();
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      return isInstanceOf;
    }
 
    public Object instantiate(String className)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 21:15:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 21:15:24 -0500
Subject: [jboss-cvs] JBossAS SVN: r59168 -
	branches/JBoss_4_0_4_GA_CP/system/src/main/org/jboss/system/server/jmx
Message-ID: <E1GwqzM-0000Ll-Ae@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-19 21:15:22 -0500 (Tue, 19 Dec 2006)
New Revision: 59168

Modified:
   branches/JBoss_4_0_4_GA_CP/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
Log:
ASPATCH-136, reload the server domains on InstanceNotFoundException failures in isInstanceOf calls.

Modified: branches/JBoss_4_0_4_GA_CP/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java
===================================================================
--- branches/JBoss_4_0_4_GA_CP/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 01:54:57 UTC (rev 59167)
+++ branches/JBoss_4_0_4_GA_CP/system/src/main/org/jboss/system/server/jmx/LazyMBeanServer.java	2006-12-20 02:15:22 UTC (rev 59168)
@@ -1,29 +1,31 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.system.server.jmx;
 
 import java.io.ObjectInputStream;
 import java.lang.reflect.Constructor;
 import java.util.Set;
+import java.util.HashSet;
+import java.util.Collections;
 import javax.management.MBeanServer;
 import javax.management.ObjectInstance;
 import javax.management.ObjectName;
@@ -59,11 +61,23 @@
 public class LazyMBeanServer
    implements MBeanServer
 {
+   /** The MBeanServer that was registered */
    private static MBeanServer registeredServer;
+   /** The jboss MBeanServer implementation */
    private static MBeanServer theServer;
+   /** The jdk MBeanServer implementation */
    private static MBeanServer platformServer;
+   /** The default domain to use for mbeans */
    private static String defaultDomain;
    private static MBeanServerDelegate theDelegate;
+   /** A HashSet<String> of the jmx domain prefixes that need to be
+    * handled by the platform server
+    */
+   private static Set platformServerDomains = Collections.synchronizedSet(new HashSet());
+   /** A HashSet<String> of the jmx domain prefixes that need to be
+    * handled by the jboss server
+    */
+   private static Set serverDomains = Collections.synchronizedSet(new HashSet());
 
    /**
     * Called by the ServerImpl to reset theServer implementation to the jboss
@@ -86,6 +100,11 @@
          Constructor ctor = c.getConstructor(sig);
          theServer = (MBeanServer) ctor.newInstance(args);
          coreServer = theServer;
+         String[] domains = theServer.getDomains();
+         for(int n = 0; n < domains.length; n ++)
+         {
+            serverDomains.add(domains[n]);
+         }
       }
       return coreServer;
    }
@@ -104,6 +123,32 @@
       return outerServer;
    }
 
+   /**
+    * Updates the platformServerDomains and serverDomains sets of jmx
+    * domain names.
+    */
+   public static synchronized void reloadDomains()
+   {
+      // Initialize the platform server domains
+      String[] domains = platformServer.getDomains();
+      for(int n = 0; n < domains.length; n ++)
+      {
+         platformServerDomains.add(domains[n]);
+      }
+      domains = theServer.getDomains();
+      for(int n = 0; n < domains.length; n ++)
+      {
+         serverDomains.add(domains[n]);
+      }
+   }
+   /**
+    * 
+    * @param domain - the default domain when an MBean is
+    *        registered with an ObjectName without a domain
+    * @param outer - the wrapping MBeanServer, passed to MBeans
+    *        at registration.
+    * @param delegate the delegate to use for Notifications.
+    */
    LazyMBeanServer(String domain, MBeanServer outer,
       MBeanServerDelegate delegate)
    {
@@ -112,6 +157,12 @@
       theServer = outer;
       registeredServer = this;
       theDelegate = delegate;
+      // Initialize the platform server domains
+      String[] domains = platformServer.getDomains();
+      for(int n = 0; n < domains.length; n ++)
+      {
+         platformServerDomains.add(domains[n]);
+      }
    }
 
    public ObjectInstance createMBean(String className, ObjectName name)
@@ -301,18 +352,47 @@
       getServer(name).removeNotificationListener(name, listener, filter, handback);
    }
 
+   /**
+    * Obtains the MBeanInfo for the given ObjectName. In the event of an
+    * InstanceNotFoundException, the jmx domain to server sets are reloaded
+    * by calling reloadDomains(), and the lookup retried.
+    * @param name
+    * @return
+    * @throws InstanceNotFoundException
+    * @throws IntrospectionException
+    * @throws ReflectionException
+    */
    public MBeanInfo getMBeanInfo(ObjectName name)
       throws InstanceNotFoundException, IntrospectionException,
       ReflectionException
    {
-      MBeanInfo info = getServer(name).getMBeanInfo(name);
+      MBeanInfo info = null;
+      try
+      {
+         info = getServer(name).getMBeanInfo(name);
+      }
+      catch(InstanceNotFoundException e)
+      {
+         reloadDomains();
+         info = getServer(name).getMBeanInfo(name);
+      }
       return info;
    }
 
    public boolean isInstanceOf(ObjectName name, String className)
       throws InstanceNotFoundException
    {
-      return getServer(name).isInstanceOf(name, className);
+      boolean isInstanceOf = false;
+      try
+      {
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      catch(InstanceNotFoundException e)
+      {
+         reloadDomains();
+         isInstanceOf = getServer(name).isInstanceOf(name, className);
+      }
+      return isInstanceOf;
    }
 
    public Object instantiate(String className)
@@ -382,16 +462,20 @@
    }
 
    /**
-    * Choose the MBeanServer based on the ObjectName domain. The current
-    * implementation chooses the platform MBeanServer for any domain starting
-    * with "java".
+    * Choose the MBeanServer based on the ObjectName domain. If the serverDomain
+    * contains the domain of the name, theServer is returned. If the 
+    * platformServerDomains set contains the domain of the name, the
+    * platformServer is returned. For an unknown domain theServer is returned.
     * 
     * @param name
     * @return Either the platform MBeanServer, or the jboss MBeanServer
     */ 
    private MBeanServer getServer(ObjectName name)
    {
-      if( name != null && name.getDomain().startsWith("java") )
+      String domain = name != null ? name.getDomain() : "";
+      if( serverDomains.contains(domain) )
+         return theServer;
+      if( platformServerDomains.contains(domain) )
          return platformServer;
       return theServer;
    }



From msurtani at jboss.com  Tue Dec 19 21:16:24 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 21:16:24 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader  ...
Message-ID: <E1Gwr0K-0000Nx-GF@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 21:16:24

  Modified:    src/org/jboss/cache/loader  JDBCCacheLoader.java
  Log:
  fixed passivation and eviction bugs
  
  Revision  Changes    Path
  1.25      +7 -7      JBossCache/src/org/jboss/cache/loader/JDBCCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JDBCCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/JDBCCacheLoader.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- JDBCCacheLoader.java	20 Nov 2006 18:04:08 -0000	1.24
  +++ JDBCCacheLoader.java	20 Dec 2006 02:16:24 -0000	1.25
  @@ -79,7 +79,7 @@
    *
    * @author <a href="mailto:alex at jboss.org">Alexey Loubyansky</a>
    * @author <a href="mailto:hmesha at novell.com">Hany Mesha </a>
  - * @version <tt>$Revision: 1.24 $</tt>
  + * @version <tt>$Revision: 1.25 $</tt>
    */
   public class JDBCCacheLoader extends AbstractCacheLoader
   {
  @@ -774,10 +774,10 @@
            ps.setString(2, name.toString());
   
            int rows = ps.executeUpdate();
  -         if (rows != 1)
  -         {
  -            throw new IllegalStateException("Expected one updated row but got " + rows);
  -         }
  +//         if (rows != 1)
  +//         {
  +//            throw new IllegalStateException("Expected one updated row but got " + rows);
  +//         }
         }
         catch (Exception e)
         {
  
  
  


From msurtani at jboss.com  Tue Dec 19 21:16:24 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 21:16:24 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors   ...
Message-ID: <E1Gwr0K-0000O7-Kw@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 21:16:24

  Modified:    src/org/jboss/cache/interceptors  
                        CacheLoaderInterceptor.java
                        ActivationInterceptor.java
  Log:
  fixed passivation and eviction bugs
  
  Revision  Changes    Path
  1.64      +15 -14    JBossCache/src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java,v
  retrieving revision 1.63
  retrieving revision 1.64
  diff -u -b -r1.63 -r1.64
  --- CacheLoaderInterceptor.java	29 Nov 2006 22:10:22 -0000	1.63
  +++ CacheLoaderInterceptor.java	20 Dec 2006 02:16:24 -0000	1.64
  @@ -6,11 +6,8 @@
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.NodeSPI;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.loader.AsyncCacheLoader;
   import org.jboss.cache.loader.CacheLoader;
  @@ -20,7 +17,6 @@
   import org.jboss.cache.marshall.MethodCallFactory;
   import org.jboss.cache.marshall.MethodDeclarations;
   
  -import java.util.Collection;
   import java.util.Collections;
   import java.util.HashMap;
   import java.util.Iterator;
  @@ -33,7 +29,7 @@
    * Loads nodes that don't exist at the time of the call into memory from the CacheLoader
    *
    * @author Bela Ban
  - * @version $Id: CacheLoaderInterceptor.java,v 1.63 2006/11/29 22:10:22 genman Exp $
  + * @version $Id: CacheLoaderInterceptor.java,v 1.64 2006/12/20 02:16:24 msurtani Exp $
    */
   public class CacheLoaderInterceptor extends BaseCacheLoaderInterceptor implements CacheLoaderInterceptorMBean
   {
  @@ -162,7 +158,7 @@
               // clean up nodesCreated map
               cleanupNodesCreated(entry);
               break;
  -         default :
  +         default:
               if (!useCacheStore)
               {
                  if (m.getMethodId() == MethodDeclarations.removeKeyMethodLocal_id)
  @@ -314,11 +310,13 @@
   
      private boolean mustLoad(Node n, Object key)
      {
  -      if (n == null) {
  +      if (n == null)
  +      {
            log.trace("mustLoad, node null");
            return true;
         }
  -      if (!n.getNodeSPI().getDataLoaded()) {
  +      if (!n.getNodeSPI().getDataLoaded())
  +      {
            log.trace("must Load, uninitialized");
            return true;
         }
  @@ -425,14 +423,17 @@
         Map nodeData = loadData(fqn);
         if (nodeData != null)
         {
  +         log.trace("Node data is not null, loading");
            n = createNodes(fqn, entry);
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
            n.clearData();
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
            n.put(nodeData);
         }
  -      else if (n != null && !n.getNodeSPI().getDataLoaded())
  +
  +      if (n != null && !n.getNodeSPI().getDataLoaded())
         {
  +         log.trace("Setting dataLoaded to true");
            n.getNodeSPI().setDataLoaded(true);
         }
         return n;
  
  
  
  1.44      +37 -37    JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActivationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java,v
  retrieving revision 1.43
  retrieving revision 1.44
  diff -u -b -r1.43 -r1.44
  --- ActivationInterceptor.java	8 Dec 2006 18:49:17 -0000	1.43
  +++ ActivationInterceptor.java	20 Dec 2006 02:16:24 -0000	1.44
  @@ -25,7 +25,7 @@
    * their attributes have been initialized and their children have been loaded in memory.
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: ActivationInterceptor.java,v 1.43 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: ActivationInterceptor.java,v 1.44 2006/12/20 02:16:24 msurtani Exp $
    */
   public class ActivationInterceptor extends CacheLoaderInterceptor implements ActivationInterceptorMBean
   {
  @@ -66,7 +66,7 @@
         retval = super.invoke(m);
   
         // is this a node removal operation?
  -      boolean nodeRemoved = false;
  +      boolean removeData = false, nodeRemoved = false;
   
         // Could be TRANSACTIONAL. If so, we register for TX completion (if we haven't done so yet)
         if (tx_mgr != null && tx_mgr.getTransaction() != null)
  @@ -83,7 +83,7 @@
                        Integer acts = (Integer) m_txActivations.get(gtx);
                        if (acts != null)
                        {
  -                        m_activations = m_activations + acts.intValue();
  +                        m_activations = m_activations + acts;
                        }
                        m_txActivations.remove(gtx);
                     }
  @@ -115,24 +115,13 @@
            case MethodDeclarations.putDataMethodLocal_id:
            case MethodDeclarations.putDataEraseMethodLocal_id:
            case MethodDeclarations.putKeyValMethodLocal_id:
  -            fqn = (Fqn) args[1];
  -            break;
            case MethodDeclarations.removeKeyMethodLocal_id:
  -         case MethodDeclarations.removeDataMethodLocal_id:
  -            fqn = (Fqn) args[1];
  -            break;
            case MethodDeclarations.addChildMethodLocal_id:
               fqn = (Fqn) args[1];
               break;
            case MethodDeclarations.getKeyValueMethodLocal_id:
  -            fqn = (Fqn) args[0];
  -            break;
            case MethodDeclarations.getNodeMethodLocal_id:
  -            fqn = (Fqn) args[0];
  -            break;
            case MethodDeclarations.getKeysMethodLocal_id:
  -            fqn = (Fqn) args[0];
  -            break;
            case MethodDeclarations.getChildrenNamesMethodLocal_id:
            case MethodDeclarations.releaseAllLocksMethodLocal_id:
            case MethodDeclarations.printMethodLocal_id:
  @@ -142,17 +131,27 @@
               nodeRemoved = true;
               fqn = (Fqn) args[1];
               break;
  +         case MethodDeclarations.removeDataMethodLocal_id:
  +            removeData = true;
  +            fqn = (Fqn) args[1];
  +            break;
         }
   
         synchronized (this)
         {
  -         if (fqn != null && nodeRemoved)
  -         // If the node is being removed, just remove it and don't perform
  -         // activation processing
  +         if (fqn != null)
            {
  +            if (nodeRemoved)
  +            {
  +               log.trace("This is a remove operation; removing the node from the loader, no activation processing needed.");
               loader.remove(fqn);
            }
  -         else if (fqn != null && cache.hasChild(fqn) && loader.exists(fqn))
  +            else if (removeData)
  +            {
  +               log.trace("This is a remove data operation; removing the data from the loader, no activation processing needed.");
  +               loader.removeData(fqn);
  +            }
  +            else if (cache.hasChild(fqn) && loader.exists(fqn))
            {
               // Remove the node from the cache loader if it exists in memory,
               // its attributes have been initialized, its children have been loaded,
  @@ -178,6 +177,7 @@
               }
            }
         }
  +      }
         return retval;
      }
   
  
  
  


From msurtani at jboss.com  Tue Dec 19 21:16:24 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Tue, 19 Dec 2006 21:16:24 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction  ...
Message-ID: <E1Gwr0K-0000OE-Oq@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/19 21:16:24

  Modified:    src/org/jboss/cache/eviction  BaseEvictionAlgorithm.java
  Log:
  fixed passivation and eviction bugs
  
  Revision  Changes    Path
  1.19      +4 -2      JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BaseEvictionAlgorithm.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- BaseEvictionAlgorithm.java	15 Dec 2006 17:49:19 -0000	1.18
  +++ BaseEvictionAlgorithm.java	20 Dec 2006 02:16:24 -0000	1.19
  @@ -14,6 +14,7 @@
   
   import java.util.concurrent.BlockingQueue;
   import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.TimeUnit;
   
   /**
    * Abstract Event Processing Eviction Algorithm.
  @@ -22,7 +23,7 @@
    * abstract methods and a policy.
    *
    * @author Daniel Huang - dhuang at jboss.org 10/2005
  - * @version $Revision: 1.18 $
  + * @version $Revision: 1.19 $
    */
   public abstract class BaseEvictionAlgorithm implements EvictionAlgorithm
   {
  @@ -440,7 +441,8 @@
   
            try
            {
  -            fqn = (Fqn) recycleQueue.take();
  +            //fqn = (Fqn) recycleQueue.take();
  +            fqn = (Fqn) recycleQueue.poll(0, TimeUnit.SECONDS);
            }
            catch (InterruptedException e)
            {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 21:31:40 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 21:31:40 -0500
Subject: [jboss-cvs] JBossAS SVN: r59169 - in branches/JBoss_4_0_4_GA_CP:
	testsuite webservice
Message-ID: <E1GwrF6-0000dw-NG@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-19 21:31:40 -0500 (Tue, 19 Dec 2006)
New Revision: 59169

Modified:
   branches/JBoss_4_0_4_GA_CP/testsuite/build.xml
   branches/JBoss_4_0_4_GA_CP/webservice/build.xml
Log:
update version string for webservices and testsuite

Modified: branches/JBoss_4_0_4_GA_CP/testsuite/build.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/testsuite/build.xml	2006-12-20 02:15:22 UTC (rev 59168)
+++ branches/JBoss_4_0_4_GA_CP/testsuite/build.xml	2006-12-20 02:31:40 UTC (rev 59169)
@@ -206,7 +206,7 @@
   <property name="install.root" value="${module.output}/${install.id}"/>
 
   <!-- Set classpath for the webservice stack depending on ${jboss.dist.name} and client jar -->
-  <property name="jboss.dist.name" value="jboss-${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+  <property name="jboss.dist.name" value="jboss-${version.major}.${version.minor}.${version.revision}${version.tag}"/>
   <property name="jboss.home" value="${module.root}/../build/output/${jboss.dist.name}"/>
   <available property="jboss-ws4ee.available" file="${jboss.home}/client/jboss-ws4ee-client.jar"/>
   <available property="jbossws14.available" file="${jboss.home}/client/jbossws14-client.jar"/>

Modified: branches/JBoss_4_0_4_GA_CP/webservice/build.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/webservice/build.xml	2006-12-20 02:15:22 UTC (rev 59168)
+++ branches/JBoss_4_0_4_GA_CP/webservice/build.xml	2006-12-20 02:31:40 UTC (rev 59169)
@@ -245,7 +245,7 @@
     description="Builds the samples."
     depends="jars">
 
-    <property name="samples.target" value="jbossws-samples-${version.major}.${version.minor}.${version.revision}.${version.tag}" />
+    <property name="samples.target" value="jbossws-samples-${version.major}.${version.minor}.${version.revision}${version.tag}" />
     <property name="samples.output" value="${module.output}/${samples.target}" />
     <property name="module.testsuite" value="${project.root}/testsuite" />
     <property name="module.test" value="${project.root}/test" />
@@ -310,7 +310,7 @@
   <!-- Deploy the jboss-ws4ee to the server specified like this: -Dserver=default  -->
   <target name="deploy-ws4ee" depends="main">
     <property name="server" value="default"/>
-    <property name="jboss.home" value="${module.root}/../build/output/jboss-${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+    <property name="jboss.home" value="${module.root}/../build/output/jboss-${version.major}.${version.minor}.${version.revision}${version.tag}"/>
     <!-- delete jbossws implementation -->
     <delete dir="${jboss.home}/server/${server}/deploy/jbossws.sar/"/>
     <delete file="${jboss.home}/client/jbossws-client.jar"/>
@@ -326,7 +326,7 @@
   <!-- Deploy the jbossws to the server specified like this: -Dserver=default  -->
   <target name="deploy-jbossws" depends="main">
     <property name="server" value="default"/>
-    <property name="jboss.home" value="${module.root}/../build/output/jboss-${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+    <property name="jboss.home" value="${module.root}/../build/output/jboss-${version.major}.${version.minor}.${version.revision}${version.tag}"/>
     <!-- delete jboss-ws4ee implementation -->
     <delete dir="${jboss.home}/server/${server}/deploy/jboss-ws4ee.sar/"/>
     <delete file="${jboss.home}/client/jboss-ws4ee-client.jar"/>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 22:00:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 22:00:56 -0500
Subject: [jboss-cvs] JBossAS SVN: r59170 - in branches/JBoss_4_0_4_GA_CP:
	jaxrpc testsuite/imports
Message-ID: <E1GwrhQ-00012a-I4@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-19 22:00:56 -0500 (Tue, 19 Dec 2006)
New Revision: 59170

Modified:
   branches/JBoss_4_0_4_GA_CP/jaxrpc/build.xml
   branches/JBoss_4_0_4_GA_CP/testsuite/imports/server-config.xml
Log:
update version string for webservices and testsuite

Modified: branches/JBoss_4_0_4_GA_CP/jaxrpc/build.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/jaxrpc/build.xml	2006-12-20 02:31:40 UTC (rev 59169)
+++ branches/JBoss_4_0_4_GA_CP/jaxrpc/build.xml	2006-12-20 03:00:56 UTC (rev 59170)
@@ -182,7 +182,7 @@
   <!-- Deploy the webservice stuff to the server specified like this: -Dserver=default  -->
   <target name="deploy" depends="main">
     <property name="server" value="default"/>
-    <property name="jboss.home" value="${module.root}/../build/output/jboss-${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+    <property name="jboss.home" value="${module.root}/../build/output/jboss-${version.major}.${version.minor}.${version.revision}${version.tag}"/>
     <copy todir="${jboss.home}/client" file="${build.lib}/axis-ws4ee.jar" overwrite="true"/>
     <copy todir="${jboss.home}/server/${server}/deploy/jboss-ws4ee.sar" file="${build.lib}/axis-ws4ee.jar" overwrite="true"/>
   </target>

Modified: branches/JBoss_4_0_4_GA_CP/testsuite/imports/server-config.xml
===================================================================
--- branches/JBoss_4_0_4_GA_CP/testsuite/imports/server-config.xml	2006-12-20 02:31:40 UTC (rev 59169)
+++ branches/JBoss_4_0_4_GA_CP/testsuite/imports/server-config.xml	2006-12-20 03:00:56 UTC (rev 59170)
@@ -5,7 +5,7 @@
 <project name="server-config" default="help"
          xmlns:server="http://jboss.org/ns/test/ant/server">
 
-   <property name="version" value="${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
+   <property name="version" value="${version.major}.${version.minor}.${version.revision}${version.tag}"/>
    <!-- Use the ${/} platform seperator in jboss.dist as this is used in the
       security policy file property references and needs to be valid for the
       platform.



From Shane_Bryzak at symantec.com  Tue Dec 19 22:35:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:35:21 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GwsEj-0001iL-BO@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:35:21

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  added hasRole and hasPermission EL functions
  
  Revision  Changes    Path
  1.28      +162 -145  jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- SeamSecurityManager.java	16 Dec 2006 02:58:12 -0000	1.27
  +++ SeamSecurityManager.java	20 Dec 2006 03:35:21 -0000	1.28
  @@ -1,5 +1,8 @@
   package org.jboss.seam.security;
   
  +import static org.jboss.seam.ScopeType.APPLICATION;
  +import static org.jboss.seam.annotations.Install.BUILT_IN;
  +
   import java.io.InputStream;
   import java.io.InputStreamReader;
   import java.security.acl.Permission;
  @@ -9,19 +12,16 @@
   import java.util.Map;
   import java.util.Set;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
   import org.drools.FactHandle;
   import org.drools.RuleBase;
   import org.drools.RuleBaseFactory;
   import org.drools.WorkingMemory;
   import org.drools.compiler.PackageBuilder;
   import org.drools.compiler.PackageBuilderConfiguration;
  -import static org.jboss.seam.ScopeType.APPLICATION;
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptionType;
   import org.jboss.seam.ScopeType;
  -import static org.jboss.seam.annotations.Install.BUILT_IN;
  +import org.jboss.seam.Seam;
   import org.jboss.seam.annotations.Create;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Intercept;
  @@ -31,6 +31,8 @@
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.security.rules.PermissionCheck;
   import org.jboss.seam.util.Resources;
   
  @@ -39,10 +41,10 @@
    *
    * @author Shane Bryzak
    */
  - at Startup(depends="org.jboss.seam.security.securityConfiguration")
  + at Startup(depends = "org.jboss.seam.security.securityConfiguration")
   @Scope(APPLICATION)
   @Name("org.jboss.seam.securityManager")
  - at Install(value = false, precedence=BUILT_IN)
  + at Install(value = false, precedence = BUILT_IN)
   @Intercept(InterceptionType.NEVER)
   public class SeamSecurityManager
   {
  @@ -50,14 +52,15 @@
   
     private static final String SECURITY_CONTEXT_NAME = "org.jboss.seam.security.securityContext";
   
  -  private static final LogProvider log = Logging.getLogProvider(SeamSecurityManager.class);
  +   private static final LogProvider log = Logging
  +         .getLogProvider(SeamSecurityManager.class);
   
     private RuleBase securityRules;
   
     /**
      * Map roles to permissions
      */
  -  private Map<String,Set<Permission>> rolePermissions = new HashMap<String,Set<Permission>>();
  +   private Map<String, Set<Permission>> rolePermissions = new HashMap<String, Set<Permission>>();
   
     /**
      * Initialise the security manager
  @@ -65,8 +68,7 @@
      * @throws Exception
      */
     @Create
  -  public void initSecurityManager()
  -      throws Exception
  +   public void initSecurityManager() throws Exception
     {
       // Create the security rule base
       PackageBuilderConfiguration conf = new PackageBuilderConfiguration();
  @@ -81,7 +83,8 @@
         securityRules.addPackage(builder.getPackage());
       }
       else
  -      log.warn(String.format("Security rules file %s not found", SECURITY_RULES_FILENAME));
  +         log.warn(String.format("Security rules file %s not found",
  +               SECURITY_RULES_FILENAME));
     }
   
     /**
  @@ -94,10 +97,10 @@
       if (!Contexts.isApplicationContextActive())
          throw new IllegalStateException("No active application context");
   
  -    SeamSecurityManager instance = (SeamSecurityManager) Component.getInstance(
  -        SeamSecurityManager.class, ScopeType.APPLICATION);
  +      SeamSecurityManager instance = (SeamSecurityManager) Component
  +            .getInstance(SeamSecurityManager.class, ScopeType.APPLICATION);
   
  -    if (instance==null)
  +      if (instance == null)
       {
         throw new IllegalStateException(
             "No SeamSecurityManager could be created, make sure the Component exists in application scope");
  @@ -107,14 +110,16 @@
     }
   
     /**
  -   * Evaluates the specified security expression, which must return a boolean value.
  +    * Evaluates the specified security expression, which must return a boolean
  +    * value.
      *
      * @param expr String
      * @return boolean
      */
     public boolean evaluateExpression(String expr)
     {
  -    return ((Boolean) Expressions.instance().createValueBinding(expr).getValue());
  +      return ((Boolean) Expressions.instance().createValueBinding(expr)
  +            .getValue());
     }
   
     /**
  @@ -125,7 +130,17 @@
      */
     public static boolean hasRole(String name)
     {
  -    return Identity.instance().isUserInRole(name);
  +      if (!Contexts.isSessionContextActive() || !Contexts.getSessionContext().isSet(
  +            Seam.getComponentName(Identity.class)))
  +      {
  +         return false;
  +      }
  +
  +      Identity ident = Identity.instance();
  +      if (!ident.isValid())
  +         return false;
  +      
  +      return ident.isUserInRole(name);
     }
   
     /**
  @@ -136,7 +151,8 @@
      * @param args Object[]
      * @return boolean
      */
  -  public static boolean hasPermission(String name, String action, Object ... args)
  +   public static boolean hasPermission(String name, String action,
  +         Object... args)
     {
       SeamSecurityManager mgr = instance();
   
  @@ -173,7 +189,8 @@
       if (!session.isSet(SECURITY_CONTEXT_NAME))
       {
         if (!Identity.instance().isValid())
  -        throw new IllegalStateException("Authenticated Identity is not valid");
  +            throw new IllegalStateException(
  +                  "Authenticated Identity is not valid");
   
         WorkingMemory wm = securityRules.newWorkingMemory();
         wm.assertObject(Identity.instance());
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:35:21 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:35:21 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/META-INF   ...
Message-ID: <E1GwsEj-0001iV-Ho@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:35:21

  Modified:    src/ui/META-INF   seam.taglib.xml taglib.tld
  Log:
  added hasRole and hasPermission EL functions
  
  Revision  Changes    Path
  1.24      +20 -8     jboss-seam/src/ui/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/seam.taglib.xml,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- seam.taglib.xml	18 Dec 2006 15:38:49 -0000	1.23
  +++ seam.taglib.xml	20 Dec 2006 03:35:21 -0000	1.24
  @@ -132,4 +132,16 @@
           </converter>
       </tag>
       
  +    <function>
  +        <function-name>hasRole</function-name>
  +        <function-class>org.jboss.seam.security.SeamSecurityManager</function-class>
  +        <function-signature>java.lang.Boolean hasRole( java.lang.String )</function-signature>
  +    </function>
  +    
  +    <function>
  +        <function-name>hasPermission</function-name>
  +        <function-class>org.jboss.seam.security.SeamSecurityManager</function-class>
  +        <function-signature>java.lang.Boolean hasPermission( java.lang.String, java.lang.String, java.lang.Object[] )</function-signature>
  +    </function>
  +    
   </facelet-taglib>
  
  
  
  1.25      +287 -273  jboss-seam/src/ui/META-INF/taglib.tld
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: taglib.tld
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/META-INF/taglib.tld,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- taglib.tld	12 Dec 2006 22:38:26 -0000	1.24
  +++ taglib.tld	20 Dec 2006 03:35:21 -0000	1.25
  @@ -942,4 +942,18 @@
         <description>the select item label</description>
       </attribute>
     </tag>
  +  
  +  <!-- Security functions -->
  +  
  +  <function>
  +    <name>hasRole</name>
  +    <function-class>org.jboss.seam.security.SeamSecurityManager</function-class>
  +    <function-signature>java.lang.Boolean hasRole( java.lang.String )</function-signature>
  +  </function>
  +  
  +  <function>
  +    <name>hasPermission</name>
  +    <function-class>org.jboss.seam.security.SeamSecurityManager</function-class>
  +    <function-signature>java.lang.Boolean hasPermission( java.lang.String, java.lang.String, java.lang.Object[] )</function-signature>
  +  </function>
   </taglib>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:36:55 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:36:55 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace  ...
Message-ID: <E1GwsGF-0001lv-Ni@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:36:55

  Modified:    examples/seamspace  build.xml
  Log:
  added pages.xml, minor changes
  
  Revision  Changes    Path
  1.7       +3 -1      jboss-seam/examples/seamspace/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/build.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- build.xml	14 Dec 2006 04:12:21 -0000	1.6
  +++ build.xml	20 Dec 2006 03:36:55 -0000	1.7
  @@ -11,6 +11,8 @@
       <property name="example.webinf.lib.dir"  value="."/>
       <property name="example.facelets.lib"    value="yes"/>
       <property name="example.drools.lib"      value="yes"/>    
  +    <property name="example.seam.ui.lib"     value="yes"/>    
  +    <property name="example.ds"              value="seamspace-ds.xml"/>    
       <property name="src.java.dir"            value="src"/>
       <property name="src.test.dir"            value="src"/>
       <property name="test.classpath"          value="test.eejb.classpath"/>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:36:55 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:36:55 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF   ...
Message-ID: <E1GwsGF-0001m5-SR@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:36:55

  Modified:    examples/seamspace/resources/WEB-INF   web.xml
  Added:       examples/seamspace/resources/WEB-INF   pages.xml
  Log:
  added pages.xml, minor changes
  
  Revision  Changes    Path
  1.4       +18 -35    jboss-seam/examples/seamspace/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/web.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- web.xml	14 Dec 2006 04:12:21 -0000	1.3
  +++ web.xml	20 Dec 2006 03:36:55 -0000	1.4
  @@ -24,6 +24,8 @@
           <url-pattern>*.seam</url-pattern>
       </filter-mapping>
       
  +    <!-- Seam security filter -->
  +    
       <filter>
         <filter-name>Seam Security Filter</filter-name>
         <filter-class>org.jboss.seam.security.filter.SeamSecurityFilter</filter-class>
  @@ -34,6 +36,18 @@
         <url-pattern>*.seam</url-pattern>
       </filter-mapping>
   
  +    <!-- Seam exception filter -->
  +    
  +    <filter>
  +        <filter-name>Seam Exception Filter</filter-name>
  +        <filter-class>org.jboss.seam.servlet.SeamExceptionFilter</filter-class>
  +    </filter>
  +    
  +    <filter-mapping>
  +        <filter-name>Seam Exception Filter</filter-name>
  +        <url-pattern>/*</url-pattern>
  +    </filter-mapping>    
  +
       <!-- MyFaces -->
   
       <listener>
  @@ -55,20 +69,21 @@
           <param-value>.xhtml</param-value>
       </context-param>
   
  +    <!-- Faces Servlet -->
  +
       <servlet>
           <servlet-name>Faces Servlet</servlet-name>
           <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
           <load-on-startup>1</load-on-startup>
       </servlet>
   
  -
  -    <!-- Faces Servlet Mapping -->
  -
       <servlet-mapping>
           <servlet-name>Faces Servlet</servlet-name>
           <url-pattern>*.seam</url-pattern>
       </servlet-mapping>
       
  +    <!-- Seam Remoting -->
  +    
       <servlet>
         <servlet-name>Seam Remoting</servlet-name>
         <servlet-class>org.jboss.seam.remoting.SeamRemotingServlet</servlet-class>
  @@ -79,36 +94,4 @@
         <url-pattern>/seam/remoting/*</url-pattern>
       </servlet-mapping>
     
  -  <!--security-constraint>
  -    <web-resource-collection>
  -      <web-resource-name>Entire application</web-resource-name>
  -      <url-pattern>/protected/*</url-pattern>
  -    </web-resource-collection>
  -    <auth-constraint>
  -      <role-name>manager</role-name>
  -    </auth-constraint>
  -  </security-constraint>
  -  
  -  <login-config>
  -    <auth-method>SEAM</auth-method>
  -    <realm-name>Seam Realm</realm-name>
  -  </login-config>
  -  
  -  <security-role>
  -    <description>Manager role</description>
  -    <role-name>manager</role-name>
  -  </security-role-->
  -
  -  <!-- Security filter -->
  -  
  -    <!--filter>
  -        <filter-name>Seam Security Filter</filter-name>
  -        <filter-class>org.jboss.seam.security.filter.SeamSecurityFilter</filter-class>
  -    </filter>
  -
  -    <filter-mapping>
  -      <filter-name>Seam Security Filter</filter-name>
  -      <url-pattern>/*</url-pattern>
  -    </filter-mapping-->  
  -
   </web-app>
  
  
  
  1.1      date: 2006/12/20 03:36:55;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/resources/WEB-INF/pages.xml
  
  Index: pages.xml
  ===================================================================
  <!DOCTYPE pages PUBLIC
            "-//JBoss/Seam Pages Configuration DTD 1.1//EN"
            "http://jboss.com/products/seam/pages-1.1.dtd">
  
  <pages>
  
      <page view-id="/home.xhtml">
          <navigation from-action="#{login.login}">
              <rule if="#{login.loggedIn}">
                  <redirect view-id="/profile.xhtml"/>
              </rule>
          </navigation>
      </page>
  
  </pages>
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:36:56 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:36:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources  ...
Message-ID: <E1GwsGG-0001mC-0R@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:36:56

  Modified:    examples/seamspace/resources  import.sql
  Log:
  added pages.xml, minor changes
  
  Revision  Changes    Path
  1.3       +5 -0      jboss-seam/examples/seamspace/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/import.sql,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- import.sql	25 Oct 2006 09:46:17 -0000	1.2
  +++ import.sql	20 Dec 2006 03:36:55 -0000	1.3
  @@ -1 +1,6 @@
   insert into Member (memberid, username, password) values (1, 'demo', 'demo')
  +insert into MemberRole (roleid, name) values (1, 'user');
  +insert into MemberRole (roleid, name) values (2, 'admin');
  +
  +insert into MemberRoles (member_id, role_id) values (1, 1);
  +insert into MemberRoles (member_id, role_id) values (1, 2);
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:36:56 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:36:56 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GwsGG-0001mS-5U@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:36:56

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace    
                        LoginAction.java LoginLocal.java Member.java
                        MemberRole.java
  Log:
  added pages.xml, minor changes
  
  Revision  Changes    Path
  1.2       +25 -9     jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LoginAction.java	31 Oct 2006 02:54:36 -0000	1.1
  +++ LoginAction.java	20 Dec 2006 03:36:56 -0000	1.2
  @@ -1,11 +1,16 @@
   package org.jboss.seam.example.seamspace;
   
  -import javax.ejb.Stateless;
  +import javax.ejb.Remove;
  +import javax.ejb.Stateful;
   
  +import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  +import org.jboss.seam.annotations.Destroy;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Out;
  +import org.jboss.seam.annotations.Scope;
  +import org.jboss.seam.annotations.Synchronized;
   import org.jboss.seam.core.FacesMessages;
   import org.jboss.seam.security.AuthenticationException;
   import org.jboss.seam.security.authenticator.Authenticator;
  @@ -15,30 +20,41 @@
    *
    * @author Shane Bryzak
    */
  - at Stateless
  - at Name("loginAction")
  + at Stateful
  + at Scope(ScopeType.SESSION)
  + at Synchronized
  + at Name("login")
   public class LoginAction implements LoginLocal
   {
     @In(required = false) @Out(required = false) Member member;
   
  -  public String login()
  +  private boolean loggedIn;
  +
  +  public void login()
     {
       try
       {
         Authenticator.instance().authenticate(member.getUsername(), member.getPassword());
  -      return "success";
  +      loggedIn = true;      
       }
       catch (AuthenticationException ex)
       {
         FacesMessages.instance().add("Invalid login");
  -      return "login";
       }
     }
   
  -  public String logout()
  +  public void logout()
     {
  +	loggedIn = false;
       Authenticator.instance().unauthenticateSession();
       Seam.invalidateSession();
  -    return "login";
     }
  +  
  +  public boolean isLoggedIn()
  +  {
  +	return loggedIn;
  +  }
  +  
  +  @Remove @Destroy
  +  public void destroy() { }
   }
  
  
  
  1.2       +3 -2      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginLocal.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginLocal.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginLocal.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LoginLocal.java	31 Oct 2006 02:54:36 -0000	1.1
  +++ LoginLocal.java	20 Dec 2006 03:36:56 -0000	1.2
  @@ -10,6 +10,7 @@
   @Local
   public interface LoginLocal
   {
  -  String login();
  -  String logout();
  +  void login();
  +  void logout();
  +  boolean isLoggedIn();
   }
  
  
  
  1.6       +4 -1      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Member.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- Member.java	14 Dec 2006 04:12:21 -0000	1.5
  +++ Member.java	20 Dec 2006 03:36:56 -0000	1.6
  @@ -4,6 +4,7 @@
   import java.util.Set;
   import javax.persistence.Entity;
   import javax.persistence.Id;
  +import javax.persistence.JoinColumn;
   import javax.persistence.JoinTable;
   import javax.persistence.ManyToMany;
   
  @@ -56,7 +57,9 @@
     }
   
     @ManyToMany
  -  @JoinTable(name = "MemberRoles")
  +  @JoinTable(name = "MemberRoles",
  +             joinColumns=@JoinColumn(name="MEMBER_ID"), 
  +		     inverseJoinColumns=@JoinColumn(name="ROLE_ID"))    
     public Set<MemberRole> getRoles()
     {
       return roles;
  
  
  
  1.2       +1 -1      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MemberRole.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MemberRole.java	14 Dec 2006 05:18:58 -0000	1.1
  +++ MemberRole.java	20 Dec 2006 03:36:56 -0000	1.2
  @@ -12,7 +12,7 @@
    * @author Shane Bryzak
    */
   @Entity
  - at Name("role")
  + at Name("memberRole")
   public class MemberRole implements Serializable
   {
     private Integer roleId;
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:36:56 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:36:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view   ...
Message-ID: <E1GwsGG-0001mh-9y@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:36:56

  Modified:    examples/seamspace/view   home.xhtml template.xhtml
  Log:
  added pages.xml, minor changes
  
  Revision  Changes    Path
  1.5       +2 -2      jboss-seam/examples/seamspace/view/home.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: home.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/home.xhtml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- home.xhtml	31 Oct 2006 04:55:00 -0000	1.4
  +++ home.xhtml	20 Dec 2006 03:36:56 -0000	1.5
  @@ -16,7 +16,7 @@
         <div id="contentSide">
           <div class="advertising"></div>
           
  -        <h:form>
  +        <h:form rendered="#{login.loggedIn == false}">
             <div class="memberLogin">
               <div class="loginHeader">Member Login</div>
               
  @@ -40,7 +40,7 @@
                 <h:message for="password"/>
               </div>          
               
  -            <h:commandButton value="LOGIN" action="#{loginAction.login}" styleClass="loginButton"/>
  +            <h:commandButton value="LOGIN" action="#{login.login}" styleClass="loginButton"/>
   
               <br class="clear"/>
             
  
  
  
  1.3       +4 -3      jboss-seam/examples/seamspace/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/template.xhtml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- template.xhtml	31 Oct 2006 03:45:24 -0000	1.2
  +++ template.xhtml	20 Dec 2006 03:36:56 -0000	1.3
  @@ -5,6 +5,7 @@
       xmlns:h="http://java.sun.com/jsf/html">
   
   <head>
  +  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
     <title>SeamSpace</title>
     <link href="style/seamspace.css" rel="stylesheet" type="text/css"/>
   </head>
  @@ -14,7 +15,7 @@
     <div id="header">
       <div class="headerRight">
         <div class="headerMenu">
  -        <s:link action="" value="SignUp"/>
  +        <!--s:link action="" value="SignUp"/-->
         </div>
         <br style="clear:both"/>
         <h:form>
  @@ -33,13 +34,13 @@
       </div>
     </div>
     
  -  <div id="menubar">
  +  <!--div id="menubar">
       <s:link action="" value="Home"/>|
       <s:link action="" value="Browse"/>|
       <s:link action="" value="Blog"/>|
       <s:link action="" value="Videos"/>|
       <s:link action="" value="Music"/>
  -  </div>
  +  </div-->
   
     <div id="content">
       <ui:insert name="content"/>
  
  
  


From Shane_Bryzak at symantec.com  Tue Dec 19 22:36:56 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Tue, 19 Dec 2006 22:36:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view/style  ...
Message-ID: <E1GwsGG-0001mp-Eb@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/19 22:36:56

  Modified:    examples/seamspace/view/style  seamspace.css
  Log:
  added pages.xml, minor changes
  
  Revision  Changes    Path
  1.5       +1 -0      jboss-seam/examples/seamspace/view/style/seamspace.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seamspace.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/style/seamspace.css,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- seamspace.css	31 Oct 2006 04:55:00 -0000	1.4
  +++ seamspace.css	20 Dec 2006 03:36:56 -0000	1.5
  @@ -26,6 +26,7 @@
   }
   
   #content {
  +  padding-top: 10px;
     margin-left: auto;
     margin-right: auto;
     width: 800px;
  
  
  


From vladimir.blagojevic at jboss.com  Tue Dec 19 23:02:09 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Tue, 19 Dec 2006 23:02:09 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1Gwsef-0002Lu-HC@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/19 23:02:09

  Modified:    src/org/jboss/cache/marshall  MethodDeclarations.java
  Log:
  [JBCACHE-315] added channel unblock callback
  
  Revision  Changes    Path
  1.26      +7 -1      JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodDeclarations.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- MethodDeclarations.java	7 Dec 2006 22:20:22 -0000	1.25
  +++ MethodDeclarations.java	20 Dec 2006 04:02:09 -0000	1.26
  @@ -31,7 +31,7 @@
    * allowing lookup operations both ways.
    *
    * @author <a href="galder.zamarreno at jboss.com">Galder Zamarreno</a>
  - * @version $Revision: 1.25 $
  + * @version $Revision: 1.26 $
    */
   public class MethodDeclarations
   {
  @@ -114,6 +114,8 @@
      
      public static final Method blockChannelLocal;
   
  +   public static final Method unblockChannelLocal;
  +
      // these are basic crud methods that are version-aware - JBCACHE-843.
   
      public static final Method putDataVersionedMethodLocal;
  @@ -214,6 +216,8 @@
      
      public static final int blockChannelMethodLocal_id = 43;
   
  +   public static final int unblockChannelMethodLocal_id = 44;
  +
   
      static
      {
  @@ -265,6 +269,7 @@
            
            // ------------ Channel BLOCK event 
            blockChannelLocal =  TreeCache.class.getDeclaredMethod("_block"); 
  +         unblockChannelLocal =  TreeCache.class.getDeclaredMethod("_unblock"); 
   
            // ------------ version-aware methods - see JBCACHE-843
            putDataVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, DataVersion.class);
  @@ -318,6 +323,7 @@
   
         methods.put(moveMethodLocal_id, moveMethodLocal);
         methods.put(blockChannelMethodLocal_id, blockChannelLocal);
  +      methods.put(unblockChannelMethodLocal_id, unblockChannelLocal);
   
         methods.put(putDataVersionedMethodLocal_id, putDataVersionedMethodLocal);
         methods.put(putDataEraseVersionedMethodLocal_id, putDataEraseVersionedMethodLocal);
  
  
  


From vladimir.blagojevic at jboss.com  Tue Dec 19 23:02:09 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Tue, 19 Dec 2006 23:02:09 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gwsef-0002M1-O7@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/19 23:02:09

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  [JBCACHE-315] added channel unblock callback
  
  Revision  Changes    Path
  1.295     +38 -6     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.294
  retrieving revision 1.295
  diff -u -b -r1.294 -r1.295
  --- TreeCache.java	18 Dec 2006 12:51:36 -0000	1.294
  +++ TreeCache.java	20 Dec 2006 04:02:09 -0000	1.295
  @@ -46,9 +46,9 @@
   import org.jgroups.Channel;
   import org.jgroups.ChannelClosedException;
   import org.jgroups.ChannelNotConnectedException;
  +import org.jgroups.ExtendedMembershipListener;
   import org.jgroups.ExtendedMessageListener;
   import org.jgroups.JChannel;
  -import org.jgroups.MembershipListener;
   import org.jgroups.Message;
   import org.jgroups.MessageListener;
   import org.jgroups.View;
  @@ -95,11 +95,11 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.294 2006/12/18 12:51:36 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.295 2006/12/20 04:02:09 vblagojevic Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  -public class TreeCache implements Cloneable, MembershipListener
  +public class TreeCache implements Cloneable, ExtendedMembershipListener
   {
      private static final String CREATE_MUX_CHANNEL = "createMultiplexerChannel";
      private static final String[] MUX_TYPES = {"java.lang.String", "java.lang.String"};
  @@ -535,7 +535,7 @@
   
      public void fetchPartialState(Object sources[], Fqn subtree) throws Exception
      {
  -      if (subtree == null || subtree.isRoot())
  +      if (subtree == null)
         {
            throw new IllegalArgumentException("Cannot fetch partial state. Invalid subtree " + subtree);
         }
  @@ -3182,9 +3182,14 @@
         }
      }
   
  -   public void _block()
  +   private void _block()
      {
  -      log.info("Invoking block on " + getLocalAddress());
  +      //intentionally empty, used only for reflection in MethodDeclarations.blockChannelLocal
  +   }
  +   
  +   private void _unblock()
  +   {
  +      //intentionally empty, used only for reflection in MethodDeclarations.unblockChannelLocal
      }
   
      private void moveFqns(Node node, Fqn newBase)
  @@ -3575,8 +3580,35 @@
       */
      public void block()
      {
  +      if(log.isDebugEnabled())
  +      {
  +         log.debug("Block received at " + getLocalAddress());
  +      }      
         MethodCall m = MethodCallFactory.create(MethodDeclarations.blockChannelLocal);
         invokeMethod(m);
  +      if(log.isDebugEnabled())
  +      {
  +         log.debug("Block processed at " + getLocalAddress());
  +      }
  +   }
  +   
  +   /**
  +    * Indicates that a channel has received a UNBLOCK event from FLUSH protocol.
  +    * 
  +    * 
  +    */
  +   public void unblock()
  +   {
  +      if(log.isDebugEnabled())
  +      {
  +         log.debug("UnBlock received at " + getLocalAddress());
  +      }
  +      MethodCall m = MethodCallFactory.create(MethodDeclarations.unblockChannelLocal);
  +      invokeMethod(m);
  +      if(log.isDebugEnabled())
  +      {
  +         log.debug("UnBlock processed at " + getLocalAddress());
  +      }
      }
   
      /*------------------- End of MembershipListener ----------------------*/
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 23:34:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 23:34:21 -0500
Subject: [jboss-cvs] JBossAS SVN: r59171 -
	branches/Branch_4_2/cluster/src/etc
Message-ID: <E1Gwt9p-0002nN-8z@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-19 23:34:20 -0500 (Tue, 19 Dec 2006)
New Revision: 59171

Modified:
   branches/Branch_4_2/cluster/src/etc/cluster-service.xml
Log:
[JBAS-3920] Remove deprecated config attributes

Modified: branches/Branch_4_2/cluster/src/etc/cluster-service.xml
===================================================================
--- branches/Branch_4_2/cluster/src/etc/cluster-service.xml	2006-12-20 03:00:56 UTC (rev 59170)
+++ branches/Branch_4_2/cluster/src/etc/cluster-service.xml	2006-12-20 04:34:20 UTC (rev 59171)
@@ -53,8 +53,7 @@
             <pbcast.NAKACK gc_lag="50" retransmit_timeout="300,600,1200,2400,4800"
                max_xmit_size="8192"
                up_thread="true" down_thread="true"/>
-            <UNICAST timeout="300,600,1200,2400,4800" window_size="100" min_threshold="10"
-               down_thread="true"/>
+            <UNICAST timeout="300,600,1200,2400,4800" down_thread="true"/>
             <pbcast.STABLE desired_avg_gossip="20000" max_bytes="400000"
                up_thread="true" down_thread="true"/>
             <FRAG frag_size="8192"



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 23:35:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 23:35:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59172 -
	branches/Branch_4_2/ejb3/src/resources
Message-ID: <E1GwtB4-0002pt-1t@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-19 23:35:37 -0500 (Tue, 19 Dec 2006)
New Revision: 59172

Modified:
   branches/Branch_4_2/ejb3/src/resources/ejb3-clustered-sfsbcache-service.xml
   branches/Branch_4_2/ejb3/src/resources/ejb3-entity-cache-service.xml
Log:
[JBAS-3920] Remove deprecated config attributes

Modified: branches/Branch_4_2/ejb3/src/resources/ejb3-clustered-sfsbcache-service.xml
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/ejb3-clustered-sfsbcache-service.xml	2006-12-20 04:34:20 UTC (rev 59171)
+++ branches/Branch_4_2/ejb3/src/resources/ejb3-clustered-sfsbcache-service.xml	2006-12-20 04:35:37 UTC (rev 59172)
@@ -47,7 +47,7 @@
             <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"/>
+            <UNICAST timeout="600,1200,2400" 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"/>

Modified: branches/Branch_4_2/ejb3/src/resources/ejb3-entity-cache-service.xml
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/ejb3-entity-cache-service.xml	2006-12-20 04:34:20 UTC (rev 59171)
+++ branches/Branch_4_2/ejb3/src/resources/ejb3-entity-cache-service.xml	2006-12-20 04:35:37 UTC (rev 59172)
@@ -58,7 +58,7 @@
         <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" />
+        <UNICAST timeout="600,1200,2400" 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" />



From gavin.king at jboss.com  Tue Dec 19 23:35:55 2006
From: gavin.king at jboss.com (Gavin King)
Date: Tue, 19 Dec 2006 23:35:55 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/exceptions   ...
Message-ID: <E1GwtBL-0002qc-MU@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/19 23:35:55

  Modified:    src/main/org/jboss/seam/exceptions   DebugPageHandler.java
                        ExceptionHandler.java
  Log:
  fix npe for exception in restore view phase
  
  Revision  Changes    Path
  1.2       +2 -1      jboss-seam/src/main/org/jboss/seam/exceptions/DebugPageHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DebugPageHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/exceptions/DebugPageHandler.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- DebugPageHandler.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ DebugPageHandler.java	20 Dec 2006 04:35:55 -0000	1.2
  @@ -35,7 +35,8 @@
      public boolean isHandler(Exception e)
      {
         return Lifecycle.getPhaseId()!=PhaseId.RENDER_RESPONSE && 
  -            Lifecycle.getPhaseId()!=null;
  +            Lifecycle.getPhaseId()!=null &&
  +            Contexts.isConversationContextActive();
      }
      
      @Override
  
  
  
  1.2       +7 -3      jboss-seam/src/main/org/jboss/seam/exceptions/ExceptionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExceptionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/exceptions/ExceptionHandler.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ExceptionHandler.java	17 Dec 2006 19:46:41 -0000	1.1
  +++ ExceptionHandler.java	20 Dec 2006 04:35:55 -0000	1.2
  @@ -5,6 +5,7 @@
   
   import javax.faces.context.FacesContext;
   
  +import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.FacesMessages;
   import org.jboss.seam.core.Navigator;
   import org.jboss.seam.util.Strings;
  @@ -49,12 +50,15 @@
      
      public static void addFacesMessage(Exception e, String message)
      {
  +      if ( Contexts.isConversationContextActive() )
  +      {
         message = getDisplayMessage(e, message);
         if ( !Strings.isEmpty(message) )
         {
            FacesMessages.instance().add(message);
         }
      }
  +   }
      
      public static Object rethrow(Exception e) throws Exception
      {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 23:38:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 23:38:41 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59173 - trunk/build
Message-ID: <E1GwtE1-0002t8-Qs@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-19 23:38:41 -0500 (Tue, 19 Dec 2006)
New Revision: 59173

Modified:
   trunk/build/build-thirdparty.xml
Log:
[JBAS-3920] Upgrade to JGroups 2.4.1

Modified: trunk/build/build-thirdparty.xml
===================================================================
--- trunk/build/build-thirdparty.xml	2006-12-20 04:35:37 UTC (rev 59172)
+++ trunk/build/build-thirdparty.xml	2006-12-20 04:38:41 UTC (rev 59173)
@@ -109,7 +109,7 @@
       <componentref name="jbpm" version="3.0.2"/>
       <componentref name="jbpm-bpel" version="1.0.0.alpha4"/>
       <componentref name="jfreechart" version="0.9.20"/>
-      <componentref name="jgroups" version="2.4"/>
+      <componentref name="jgroups" version="2.4.1"/>
       <componentref name="joesnmp" version="0.3.4"/>
       <componentref name="juddi" version="0.9RC4"/>
       <componentref name="junit" version="3.8.1"/>



From jboss-cvs-commits at lists.jboss.org  Tue Dec 19 23:40:59 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 19 Dec 2006 23:40:59 -0500
Subject: [jboss-cvs] JBossAS SVN: r59174 -
	branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server
Message-ID: <E1GwtGF-0002vi-Lp@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-19 23:40:58 -0500 (Tue, 19 Dec 2006)
New Revision: 59174

Modified:
   branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java
Log:
[JBAS-3920] Remove set of deprecated Channel opt

Modified: branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java
===================================================================
--- branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java	2006-12-20 04:38:41 UTC (rev 59173)
+++ branches/Branch_4_2/cluster/src/main/org/jboss/ha/framework/server/ClusterPartition.java	2006-12-20 04:40:58 UTC (rev 59174)
@@ -292,7 +292,6 @@
          debugger=new Debugger(channel);
          debugger.start();
       }
-      channel.setOpt(Channel.GET_STATE_EVENTS, Boolean.TRUE);
       channel.setOpt(Channel.AUTO_RECONNECT, Boolean.TRUE);
       channel.setOpt(Channel.AUTO_GETSTATE, Boolean.TRUE);
       



From brian.stansberry at jboss.com  Tue Dec 19 23:55:40 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Tue, 19 Dec 2006 23:55:40 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GwtUS-0003AP-5f@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/19 23:55:40

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  Avoid JGroups WARN by not setting GET_STATE_EVENTS with newer JG releases
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.37 +10 -2     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.36
  retrieving revision 1.195.2.37
  diff -u -b -r1.195.2.36 -r1.195.2.37
  --- TreeCache.java	14 Dec 2006 12:51:47 -0000	1.195.2.36
  +++ TreeCache.java	20 Dec 2006 04:55:39 -0000	1.195.2.37
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.36 2006/12/14 12:51:47 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.37 2006/12/20 04:55:39 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1418,8 +1418,16 @@
                     log.debug("setting cluster properties to default value");
                  }
                  channel = new JChannel(cluster_props);
  +               
  +               // Only set GET_STATE_EVENTS if the JGroups version is < 2.3
  +               int jgVer= org.jgroups.Version.version;
  +               while (jgVer >= 100)
  +                  jgVer = (jgVer / 10);
  +               if (jgVer < 23)
  +               {
                  channel.setOpt(Channel.GET_STATE_EVENTS, Boolean.TRUE);
               }
  +            }
               channel.setOpt(Channel.AUTO_RECONNECT, Boolean.TRUE);
               channel.setOpt(Channel.AUTO_GETSTATE, Boolean.TRUE);
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 00:03:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 00:03:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59175 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/apache_tomcat
Message-ID: <E1Gwtbh-0003V2-Ol@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-20 00:03:08 -0500 (Wed, 20 Dec 2006)
New Revision: 59175

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/apache_tomcat/HttpSessionReplicationTestCase.java
Log:
Fix the build

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/apache_tomcat/HttpSessionReplicationTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/apache_tomcat/HttpSessionReplicationTestCase.java	2006-12-20 04:40:58 UTC (rev 59174)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/apache_tomcat/HttpSessionReplicationTestCase.java	2006-12-20 05:03:08 UTC (rev 59175)
@@ -251,6 +251,16 @@
       try
       {
          client.executeMethod(method);
+
+         // Read the response body.
+         byte[] responseBody = method.getResponseBody();
+
+         // Release the connection.
+         method.releaseConnection();
+
+         // Deal with the response.
+         // Use caution: ensure correct character encoding and is not binary data
+         return new String(responseBody);
       }
       catch (HttpRecoverableException e)
       {
@@ -263,16 +273,8 @@
          e.printStackTrace();
          System.exit(-1);
       }
-
-      // Read the response body.
-      byte[] responseBody = method.getResponseBody();
-
-      // Release the connection.
-      method.releaseConnection();
-
-      // Deal with the response.
-      // Use caution: ensure correct character encoding and is not binary data
-      return new String(responseBody);
+      
+      return null;
    }
 
    /**



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 00:45:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 00:45:07 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1827 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/state src/main/org/jboss/jms/tx
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GwuGJ-00046G-Mf@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-20 00:45:01 -0500 (Wed, 20 Dec 2006)
New Revision: 1827

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
   trunk/src/main/org/jboss/jms/client/state/BrowserState.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
   trunk/src/main/org/jboss/jms/client/state/ProducerState.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
Log:
http://jira.jboss.com/jira/browse/JBMESSAGING-686, http://jira.jboss.com/jira/browse/JBMESSAGING-685, http://jira.jboss.com/jira/browse/JBMESSAGING-686 and http://jira.jboss.com/jira/browse/JBMESSAGING-687

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -167,6 +167,8 @@
       ((ConnectionState) ((DelegateSupport) cd).getState()).
          getRemotingConnectionListener().addDelegateListener(new ConnectionFailureListener(cd));
 
+      //installValveAspect(cd, new ValveAspect(cd, this));
+
       if(trace) { log.trace(this + " got local connection delegate " + cd); }
 
       // Add a connection listener to detect failure; the consolidated remoting connection listener
@@ -428,12 +430,7 @@
          // We need to update some of the attributes on the state
          failedSessionState.copyState(newSessionState);
 
-         List children = new ArrayList();
-
-         // TODO Why is this clone necessary?
-         children.addAll(failedSessionState.getChildren());
-
-         for (Iterator j = children.iterator(); j.hasNext(); )
+         for (Iterator j = failedSessionState.getChildren().iterator(); j.hasNext(); )
          {
             HierarchicalStateSupport sessionChild = (HierarchicalStateSupport)j.next();
 
@@ -444,7 +441,7 @@
             else if (sessionChild instanceof ConsumerState)
             {
                handleFailoverOnConsumer(failedConnDelegate, (ConsumerState)sessionChild,
-                                        failedSessionDelegate, oldCallbackManager);
+                                         newSessionDelegate, oldCallbackManager);
             }
             else if (sessionChild instanceof BrowserState)
             {
@@ -558,7 +555,7 @@
 
    private void handleFailoverOnConsumer(ClientConnectionDelegate failedConnectionDelegate,
                                          ConsumerState failedConsumerState,
-                                         ClientSessionDelegate failedSessionDelegate,
+                                         ClientSessionDelegate newSessionDelegate,
                                          CallbackManager oldCallbackManager)
       throws JMSException
    {
@@ -569,7 +566,7 @@
 
       if (trace) { log.trace(this + " creating alternate consumer"); }
 
-      ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)failedSessionDelegate.
+      ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)newSessionDelegate.
          createConsumerDelegate((JBossDestination)failedConsumerState.getDestination(),
                                  failedConsumerState.getSelector(),
                                  failedConsumerState.isNoLocal(),

Modified: trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -163,7 +163,7 @@
          MethodInvocation mi = (MethodInvocation)invocation;
          Message m = (Message)mi.getArguments()[0];
 
-         if (trace) { log.trace("sending message " + m + " transactionally, queueing on resource manager"); }
+         if (trace) { log.trace("sending message " + m + " transactionally, queueing on resource manager txID=" + txID + " sessionID= " + state.getSessionId()); }
 
          connState.getResourceManager().addMessage(txID, state.getSessionId(), (JBossMessage)m);
 

Modified: trunk/src/main/org/jboss/jms/client/state/BrowserState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -92,7 +92,8 @@
    public void copyState(BrowserState newState)
    {      
       //Actually only one field
-      this.delegate = newState.delegate;
+      // I removed this due to http://jira.jboss.com/jira/browse/JBMESSAGING-686
+      //this.delegate = newState.delegate;
    }
 }
 

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -219,7 +219,9 @@
       this.idGenerator = newState.idGenerator;
       this.serverID = newState.serverID;
       this.versionToUse = newState.versionToUse;
-      this.delegate = newState.delegate;
+
+      // I removed this due to http://jira.jboss.com/jira/browse/JBMESSAGING-686
+      //this.delegate = newState.delegate;
    }
 
    public String toString()

Modified: trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -174,9 +174,10 @@
    public void copyState(ConsumerState newState)
    {      
       this.consumerID = newState.consumerID;
+
+      // I removed this due to http://jira.jboss.com/jira/browse/JBMESSAGING-686
+      //this.delegate = newState.delegate;
       
-      this.delegate = newState.delegate;
-      
       this.channelId = newState.channelId;
    }
 

Modified: trunk/src/main/org/jboss/jms/client/state/ProducerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ProducerState.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/state/ProducerState.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -154,7 +154,7 @@
    public void copyState(ProducerState newState)
    {      
       //Actually only one field
-      this.delegate = newState.delegate;
+      //this.delegate = newState.delegate;
    }
    
 }

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -238,7 +238,7 @@
    // we need to update
    public void copyState(SessionState newState)
    {      
-      this.delegate = newState.delegate;
+      //this.delegate = newState.delegate;
       
       this.sessionId = newState.sessionId;
    }

Modified: trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -210,47 +210,54 @@
    public void write(DataOutputStream out) throws Exception
    {
       out.writeInt(state);
-      
-      out.writeInt(sessionStatesMap.size());
-      
-      Iterator iter = sessionStatesMap.values().iterator();
-      
-      while (iter.hasNext())
+
+      if (sessionStatesMap == null)
       {
-         SessionTxState state = (SessionTxState)iter.next();
-         
-         out.writeInt(state.getSessionId());
-         
-         List msgs = state.getMsgs();
-         
-         out.writeInt(msgs.size());
-         
-         Iterator iter2 = msgs.iterator();
-         
-         while (iter2.hasNext())
-         {
-            JBossMessage m = (JBossMessage)iter2.next();
+         out.writeInt(0);
+      }
+      else
+      {
+         out.writeInt(sessionStatesMap.size());
 
-            out.writeByte(m.getType());
-            
-            m.write(out);
-         }
-         
-         List acks = state.getAcks();
-         
-         out.writeInt(acks.size());
-         
-         iter2 = acks.iterator();
-         
-         while (iter2.hasNext())
+         Iterator iter = sessionStatesMap.values().iterator();
+
+         while (iter.hasNext())
          {
-            DeliveryInfo ack = (DeliveryInfo)iter2.next();
+            SessionTxState state = (SessionTxState)iter.next();
 
-            //We only need the delivery id written
-            out.writeLong(ack.getMessageProxy().getDeliveryId());
+            out.writeInt(state.getSessionId());
+
+            List msgs = state.getMsgs();
+
+            out.writeInt(msgs.size());
+
+            Iterator iter2 = msgs.iterator();
+
+            while (iter2.hasNext())
+            {
+               JBossMessage m = (JBossMessage)iter2.next();
+
+               out.writeByte(m.getType());
+
+               m.write(out);
+            }
+
+            List acks = state.getAcks();
+
+            out.writeInt(acks.size());
+
+            iter2 = acks.iterator();
+
+            while (iter2.hasNext())
+            {
+               DeliveryInfo ack = (DeliveryInfo)iter2.next();
+
+               //We only need the delivery id written
+               out.writeLong(ack.getMessageProxy().getDeliveryId());
+            }
          }
       }
-   }  
+   }
     
    
    public void read(DataInputStream in) throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -81,6 +81,17 @@
    
    // Public --------------------------------------------------------
    
+   // this test was created per JBMESSAGING-685
+   // as this required a ClusteredConnectionFactory I kept it into HATest but we can move it if we want
+   public void testEmptyCommit() throws Exception
+   {
+      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+      Connection conn = cf.createConnection();
+      JBossSession session = (JBossSession) conn.createSession(true, Session.SESSION_TRANSACTED);
+      session.commit();
+      conn.close();
+   }
+
    /*
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-19 17:32:32 UTC (rev 1826)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-20 05:45:01 UTC (rev 1827)
@@ -174,75 +174,76 @@
     */
    public void testMultiThreadFailover() throws Exception
    {
-      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+       // This test will be disabled until we implement the valve
+//      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+//
+//      Connection conn1 = cf.createConnection();
+//      Connection conn2 = cf.createConnection();
+//      Connection conn3 = cf.createConnection();
+//
+//      log.info("Created connections");
+//
+//      checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
+//
+//      Connection conn = getConnection(new Connection[]{conn1, conn2, conn3}, 1);
+//      conn.start();
+//
+//      for (int i = 0; i < 3; i++)
+//      {
+//         JBossConnection connTest = (JBossConnection)getConnection(new Connection[]{conn1, conn2, conn3}, i);
+//
+//         String locator = ((ClientConnectionDelegate) connTest.getDelegate()).getRemotingConnection().
+//            getInvokingClient().getInvoker().getLocator().getLocatorURI();
+//
+//         log.info("Server " + i + " has locator=" + locator);
+//
+//      }
+//
+//
+//      ArrayList list = new ArrayList();
+//
+//      for (int i = 0; i < 5; i++)
+//      {
+//         list.add(new LocalThreadProducer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
+//         list.add(new LocalThreadConsumer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
+//      }
+//
+//      for (Iterator iter = list.iterator(); iter.hasNext();)
+//      {
+//         Thread t = (Thread) iter.next();
+//         t.start();
+//      }
+//
+//      Thread.sleep(1000);
+//      synchronized (semaphore)
+//      {
+//         semaphore.notifyAll();
+//      }
+//
+//      Thread.sleep(30000);
+//
+//      log.info("Killing server 1");
+//      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed");
+//      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed", 2);
+//      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+//
+//      ServerManagement.kill(1);
+//
+//      Thread.sleep(50000);
+//      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+//      shouldStop = true;
+//
+//      for (Iterator iter = list.iterator(); iter.hasNext();)
+//      {
+//         Thread t = (Thread) iter.next();
+//         t.join();
+//      }
+//
+//      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+//
+//      assertEquals(messageCounterProducer, messageCounterConsumer);
+//
 
-      Connection conn1 = cf.createConnection();
-      Connection conn2 = cf.createConnection();
-      Connection conn3 = cf.createConnection();
-
-      log.info("Created connections");
-
-      checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
-
-      Connection conn = getConnection(new Connection[]{conn1, conn2, conn3}, 1);
-      conn.start();
-
-      for (int i = 0; i < 3; i++)
-      {
-         JBossConnection connTest = (JBossConnection)getConnection(new Connection[]{conn1, conn2, conn3}, i);
-
-         String locator = ((ClientConnectionDelegate) connTest.getDelegate()).getRemotingConnection().
-            getInvokingClient().getInvoker().getLocator().getLocatorURI();
-
-         log.info("Server " + i + " has locator=" + locator);
-
-      }
-
-
-      ArrayList list = new ArrayList();
-
-      for (int i = 0; i < 5; i++)
-      {
-         list.add(new LocalThreadProducer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
-         list.add(new LocalThreadConsumer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
-      }
-
-      for (Iterator iter = list.iterator(); iter.hasNext();)
-      {
-         Thread t = (Thread) iter.next();
-         t.start();
-      }
-
-      Thread.sleep(1000);
-      synchronized (semaphore)
-      {
-         semaphore.notifyAll();
-      }
-
-      Thread.sleep(30000);
-
-      log.info("Killing server 1");
-      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed");
-      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed", 2);
-      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
-
-      ServerManagement.kill(1);
-
-      Thread.sleep(50000);
-      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
-      shouldStop = true;
-
-      for (Iterator iter = list.iterator(); iter.hasNext();)
-      {
-         Thread t = (Thread) iter.next();
-         t.join();
-      }
-
-      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
-
-      assertEquals(messageCounterProducer, messageCounterConsumer);
-
-
    }
 
    // Protected -----------------------------------------------------
@@ -251,14 +252,14 @@
    {
       nodeCount = 3;
 
-      super.setUp();
+      //super.setUp();
 
       log.debug("setup done");
    }
 
    protected void tearDown() throws Exception
    {
-      super.tearDown();
+      //super.tearDown();
    }
 
 }



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 00:46:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 00:46:31 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1828 -
	trunk/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GwuHf-00048o-CD@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 00:46:30 -0500 (Wed, 20 Dec 2006)
New Revision: 1828

Added:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java
Log:
commented out test related to http://jira.jboss.org/jira/browse/JBMESSAGING-688

Added: trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java	2006-12-20 05:45:01 UTC (rev 1827)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java	2006-12-20 05:46:30 UTC (rev 1828)
@@ -0,0 +1,117 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.JBossConnection;
+
+import javax.jms.Connection;
+import javax.jms.Session;
+import javax.jms.MessageProducer;
+import javax.jms.DeliveryMode;
+import javax.jms.MessageConsumer;
+import javax.jms.TextMessage;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class DistributedQueueTest extends ClusteringTestBase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public DistributedQueueTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testNoop()
+   {
+   }
+
+//   public void testForwardingMessageAmongNodes() throws Exception
+//   {
+//      Connection conn = null;
+//
+//      try
+//      {
+//         conn = cf.createConnection();
+//
+//         // send a message
+//
+//         Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         MessageProducer p = s.createProducer(queue[0]);
+//         p.setDeliveryMode(DeliveryMode.PERSISTENT);
+//         p.send(s.createTextMessage("blip"));
+//
+//         conn.close();
+//
+//         // create a connection to a different node
+//
+//         conn = cf.createConnection();
+//
+//         // make sure we're connecting to node 1
+//
+//         int nodeID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn).
+//            getDelegate()).getState()).getServerID();
+//
+//         assertEquals(1, nodeID);
+//
+//         s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         MessageConsumer c = s.createConsumer(queue[1]);
+//         conn.start();
+//
+//         // we must receive the message
+//
+//         TextMessage tm = (TextMessage)c.receive(1000);
+//         assertEquals("blip", tm.getText());
+//
+//      }
+//      finally
+//      {
+//         if (conn != null)
+//         {
+//            conn.close();
+//         }
+//      }
+//   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      nodeCount = 2;
+
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}



From forge-admin at jboss.com  Wed Dec 20 01:00:32 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Wed, 20 Dec 2006 01:00:32 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GwuVE-0004Mj-7o@committer01.frg.pub.inap.atl.jboss.com>

Commit from rsigal on branch remoting_2_x (2006-12-19 01:00 EST)
-----------------------------------------

JBREM-650:  Made started variable protected.

  JBossRemoting  src/main/org/jboss/remoting/ServerInvoker.java  1.52.2.6


Commit from rsigal on branch remoting_2_x (2006-12-19 01:01 EST)
-----------------------------------------

JBREM-650:  Added "end of file message" to SocketException.

  JBossRemoting  src/main/org/jboss/remoting/transport/socket/MicroSocketClientInvoker.java  1.16.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:02 EST)
-----------------------------------------

JBREM-650:  Made MAX_POOL_SIZE_DEFAULT protected.

  JBossRemoting  src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java  1.30.2.4


Commit from rsigal on branch remoting_2_x (2006-12-19 01:04 EST)
-----------------------------------------

JBREM-650: Changed START_SECONDARY_PORT to IS_CALLBACK_SERVER.

  JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/Bisocket.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:06 EST)
-----------------------------------------

JBREM-650: Made listenerId protected.  Used 1000 for timeout waiting for new socket.

  JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:09 EST)
-----------------------------------------

JBREM-650:  Avoid creating server socket for callback server invoker.

  JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:10 EST)
-----------------------------------------

JBREM-650:  Create ssl version of bisocket transport.

+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/TransportClientFactory.java    1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/SSLBisocketClientInvoker.java  1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/TransportServerFactory.java    1.1.2.1
+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/SSLBisocketServerInvoker.java  1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-19 01:13 EST)
-----------------------------------------

JBREM-650: (1) Added getTransport(), addExtraClientConfig(), addExtraServerConfig(). (2) Used Bisocket.IS_CALLBACK_SERVER.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:14 EST)
-----------------------------------------

JBREM-650: Changed Bisocket.START_SECONDARY_SERVER to Bisocket.IS_CALLBACK_SERVER.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestServer.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:17 EST)
-----------------------------------------

JBREM-650: Changed Bisocket.START_SECONDARY_PORT to Bisocket.IS_CALLBACK_SERVER.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/configuration/FactoryConfigTestCase.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-19 01:17 EST)
-----------------------------------------

JBREM-650: Added more unit tests for bisocket transport.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestClient.java  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionTestCase.java         1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketTestClient.java                 1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BiocketConnectionCheckTestCase.java     1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestServer.java  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketTestServer.java                 1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestClient.java             1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestCase.java               1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestServer.java             1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryTestCase.java        1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryServer.java          1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryClient.java          1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/deadlock/BisocketShutdownDeadlockTestCase.java     1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-19 01:19 EST)
-----------------------------------------

JBREM-650: Added unit tests for sslbisocket transport.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java     1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerTestCase.java       1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java     1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverTrustStore2      1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverKeyStore         1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverTrustStore       1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/clientKeyStore         1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/clientTrustStore       1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerServerTest.java            1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerTestCase.java              1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerClientTest.java            1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/SSLBisocketInvokerTestCase.java    1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/BisocketInvokerServerTest.java     1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/SSLBisocketInvokerClientTest.java  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestServer.java         1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestCase.java           1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestClient.java         1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java              1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java              1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestCase.java                1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java                1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerTestCase.java                  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java                1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerTestCase.java                 1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerClientTest.java               1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerServerTest.java               1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/FactoryConfigTestCase.java                      1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-19 01:26 EST)
-----------------------------------------

JBREM-650: Added unit tests for sslbisocket transport.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/keystore                          1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/truststore                        1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketTestCase.java          1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketInvokerConstants.java  1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-19 01:27 EST)
-----------------------------------------

JBREM-650: Added getTransport(), and in some cases getPort(), to allow reusing tests with other transports.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestServer.java  1.1.2.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestServer.java                 1.3.4.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestClient.java  1.1.2.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java                 1.4.4.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerClientTest.java      1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerServerTest.java      1.2.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/deadlock/ShutdownDeadlockTestCase.java           1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerServerTest.java                 1.10.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerClientTest.java                 1.5.6.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestServer.java          1.7.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestClient.java          1.5.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryClient.java          1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryServer.java          1.1.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestServer.java             1.1.2.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestClient.java             1.1.2.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestServer.java      1.3.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestClient.java      1.4.4.1


Commit from starksm (2006-12-19 03:06 EST)
-------------------

A separate 2.0.0.Beta2 release of the vfs

+ repository.jboss.com  jboss/jboss-vfs/2.0.0.Beta2/component-info.xml         1.1
+ repository.jboss.com  jboss/jboss-vfs/2.0.0.Beta2/lib/jboss-vfs-sources.jar  1.1
+ repository.jboss.com  jboss/jboss-vfs/2.0.0.Beta2/lib/jboss-vfs.jar          1.1


Commit from kkhan (2006-12-19 05:12 EST)
-----------------

Add 1.5.3.Beta1 for a customer

+ repository.jboss.com  jboss/aop/1.5.3.beta1/component-info.xml                      1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/common-softvaluehashmap.jar         1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/jboss-aop-jdk50-client.jar          1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/jboss-aop-jdk50.jar                 1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/jboss-aop.jar                       1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/jdk14-pluggable-instrumentor.jar    1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/jrockit-pluggable-instrumentor.jar  1.1
+ repository.jboss.com  jboss/aop/1.5.3.beta1/lib/pluggable-instrumentor.jar          1.1


Commit from ispringer (2006-12-19 09:07 EST)
---------------------

Seam 1.1 GA jars & Maven 2 poms

+ repository.jboss.com  maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.jar       1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.jar.md5   1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.jar.sha1  1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.pom       1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.pom.md5   1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-debug/1.1.0.GA/jboss-seam-debug-1.1.0.GA.pom.sha1  1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.jar             1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.jar.md5         1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.jar.sha1        1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.pom             1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.pom.md5         1.1
+ repository.jboss.com  maven2/jboss/jboss-seam-ui/1.1.0.GA/jboss-seam-ui-1.1.0.GA.pom.sha1        1.1
+ repository.jboss.com  maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.jar                   1.1
+ repository.jboss.com  maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.jar.md5               1.1
+ repository.jboss.com  maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.jar.sha1              1.1
+ repository.jboss.com  maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.pom                   1.1
+ repository.jboss.com  maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.pom.md5               1.1
+ repository.jboss.com  maven2/jboss/jboss-seam/1.1.0.GA/jboss-seam-1.1.0.GA.pom.sha1              1.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-19 09:43 EST)
------------------------------------------------------

Removed dependency on a Java5 class

  JBossCache  tests/stress/org/jboss/cache/BuddyReplicationStressTest.java  1.6.2.3


Commit from vralev (2006-12-19 10:12 EST)
------------------

renaming the official patch

+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources/ejb3-interceptors-aop.xml             1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources/ejb3-clustered-sfsbcache-service.xml  1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/resources/ejb3-entity-cache-service.xml         1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin/ejb3.deployer                               1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml                              1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/jboss-ejb3-client.jar                       1.1
+   repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/hibernate-client.jar                        1.1


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-19 10:22 EST)
------------------------------------------------------

Fixed interop failure

  JBossCache  build.xml  1.119.2.20


Commit from nrichards (2006-12-19 11:23 EST)
---------------------

allow bigdecimal input in components.xml

  jboss-seam  src/main/org/jboss/seam/util/Conversions.java  1.9


Commit from tdiesler (2006-12-19 11:47 EST)
--------------------

-r 1670

  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxrpc.jar                1.33
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-jaxws.jar                 1.32
  repository.jboss.com  jboss/jbossws/snapshot/lib/jboss-saaj.jar                  1.33
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-client.jar              1.44
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-jboss-integration.jar   1.6
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws-tomcat-integration.jar  1.6
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.deployer                1.5
  repository.jboss.com  jboss/jbossws/snapshot/lib/jbossws.sar                     1.44


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-19 11:49 EST)
------------------------------------------------------

Updated to JGroups 2.4.1.GA

  JBossCache  lib/jgroups.jar  1.4.2.6


Commit from msurtani (2006-12-19 11:50 EST)
--------------------

Updated to 2.4.1.GA

  JBossCache  lib/jgroups.jar  1.10


Commit from gavin (2006-12-19 11:57 EST)
-----------------

fix bug with @Begin(id=...)

  jboss-seam  src/main/org/jboss/seam/interceptors/ConversationInterceptor.java  1.56
  jboss-seam  src/main/org/jboss/seam/core/Manager.java                          1.131
  jboss-seam  src/main/org/jboss/seam/core/ConversationEntries.java              1.5


Commit from gavin (2006-12-19 12:03 EST)
-----------------

oops

  jboss-seam  examples/registration/build.xml  1.28


Commit from gavin (2006-12-19 12:11 EST)
-----------------

JBSEAM-615

  jboss-seam  seam.bat  1.18


Commit from gavin (2006-12-19 12:22 EST)
-----------------

fix   JBSEAM-612

  jboss-seam  src/ui/org/jboss/seam/ui/HtmlButton.java  1.6
  jboss-seam  src/ui/org/jboss/seam/ui/HtmlLink.java    1.26


Commit from bela (2006-12-19 12:53 EST)
----------------

added JGroups 2.4.1

+ repository.jboss.com  jgroups/2.4.1/lib/jgroups.jar     1.1
+ repository.jboss.com  jgroups/2.4.1/component-info.xml  1.1


Commit from gavin (2006-12-19 13:11 EST)
-----------------

oops

  jboss-seam  examples/booking/resources/WEB-INF/pages.xml  1.12


Commit from gavin (2006-12-19 13:14 EST)
-----------------

call s:link/button action *after* running page actions

  jboss-seam  src/main/org/jboss/seam/core/Pages.java                     1.71
  jboss-seam  src/main/org/jboss/seam/jsf/AbstractSeamPhaseListener.java  1.35


Commit from gavin (2006-12-19 16:06 EST)
-----------------

renames

  jboss-seam  src/main/org/jboss/seam/pages-1.1.dtd    1.14
  jboss-seam  src/main/org/jboss/seam/core/Pages.java  1.72


Commit from gavin (2006-12-19 16:07 EST)
-----------------

cant make up my damn mind

  jboss-seam  examples/blog/resources/WEB-INF/pages.xml     1.7
  jboss-seam  examples/booking/resources/WEB-INF/pages.xml  1.13


Commit from gavin (2006-12-19 16:16 EST)
-----------------

renames

  jboss-seam  src/main/org/jboss/seam/core/Pages.java              1.73
- jboss-seam  src/main/org/jboss/seam/pages/ActionNavigation.java  1.4
+ jboss-seam  src/main/org/jboss/seam/pages/Navigation.java        1.1
- jboss-seam  src/main/org/jboss/seam/pages/Outcome.java           1.4
  jboss-seam  src/main/org/jboss/seam/pages/Page.java              1.4
+ jboss-seam  src/main/org/jboss/seam/pages/Rule.java              1.1


Commit from gavin (2006-12-19 16:49 EST)
-----------------

fix bug JBSEAM-618

  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java  1.74
  jboss-seam  src/main/org/jboss/seam/core/Manager.java        1.132


Commit from gavin (2006-12-19 17:54 EST)
-----------------

fix npe

  jboss-seam  src/main/org/jboss/seam/contexts/ServerConversationContext.java  1.19


Commit from gavin (2006-12-19 18:12 EST)
-----------------

minor opt

  jboss-seam  src/main/org/jboss/seam/contexts/Lifecycle.java  1.75


Commit from gavin (2006-12-19 18:12 EST)
-----------------

let the beans be destroyed

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java   1.44
  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/LoggedInInterceptor.java  1.16


Commit from gavin (2006-12-19 18:13 EST)
-----------------

oops

  jboss-seam  examples/booking/src/org/jboss/seam/example/booking/HotelBookingAction.java  1.45


Commit from msurtani (2006-12-19 21:16 EST)
--------------------

fixed passivation and eviction bugs

  JBossCache  src/org/jboss/cache/loader/JDBCCacheLoader.java               1.25
  JBossCache  src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java  1.64
  JBossCache  src/org/jboss/cache/interceptors/ActivationInterceptor.java   1.44
  JBossCache  src/org/jboss/cache/eviction/BaseEvictionAlgorithm.java       1.19


Commit from sbryzak2 (2006-12-19 22:35 EST)
--------------------

added hasRole and hasPermission EL functions

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java  1.28
  jboss-seam  src/ui/META-INF/seam.taglib.xml                            1.24
  jboss-seam  src/ui/META-INF/taglib.tld                                 1.25


Commit from sbryzak2 (2006-12-19 22:36 EST)
--------------------

added pages.xml, minor changes

  jboss-seam  examples/seamspace/build.xml                                              1.7
  jboss-seam  examples/seamspace/resources/WEB-INF/web.xml                              1.4
+ jboss-seam  examples/seamspace/resources/WEB-INF/pages.xml                            1.1
  jboss-seam  examples/seamspace/resources/import.sql                                   1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java  1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/LoginLocal.java   1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java       1.6
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java   1.2
  jboss-seam  examples/seamspace/view/home.xhtml                                        1.5
  jboss-seam  examples/seamspace/view/template.xhtml                                    1.3
  jboss-seam  examples/seamspace/view/style/seamspace.css                               1.5


Commit from vblagojevic (2006-12-19 23:02 EST)
-----------------------

[JBCACHE-315] added channel unblock callback

  JBossCache  src/org/jboss/cache/marshall/MethodDeclarations.java  1.26
  JBossCache  src/org/jboss/cache/TreeCache.java                    1.295


Commit from gavin (2006-12-19 23:35 EST)
-----------------

fix npe for exception in restore view phase

  jboss-seam  src/main/org/jboss/seam/exceptions/DebugPageHandler.java  1.2
  jboss-seam  src/main/org/jboss/seam/exceptions/ExceptionHandler.java  1.2


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-19 23:55 EST)
---------------------------------------------------------

Avoid JGroups WARN by not setting GET_STATE_EVENTS with newer JG releases

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.37
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061220/f0b6a9c2/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 01:06:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 01:06:19 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1829 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gwuap-0004cu-Nt@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 01:06:06 -0500 (Wed, 20 Dec 2006)
New Revision: 1829

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
Log:
various tweaks before the Beta release

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -662,25 +662,6 @@
 
    }
 
-   // Debug information about interceptors
-   private void printInterceptors(Interceptor interceptors[])
-    {
-       if (interceptors==null || interceptors.length==0)
-       {
-          log.info("Interceptor chain is empty");
-       }
-       else
-       {
-          for (int i=0; i<interceptors.length; i++)
-          {
-             log.info("Interceptor[" + i + "] = " + interceptors[i].getName() + " className= " + interceptors[i].getClass().getName());
-          }
-       }
-    }
-
-
-
-
    /** I have moved this ConnectionListener to ValveAspect (from HAAspect) because
     *  it needs to use the same valve as exception listeners.
     *  While we are processing failover, we should block any calls on the client side.

Modified: trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -202,7 +202,8 @@
          ClientSessionDelegate connectionConsumerDelegate =
             (ClientSessionDelegate)info.getConnectionConsumerSession();
          
-         int sessionId = connectionConsumerDelegate != null ? connectionConsumerDelegate.getID() : state.getSessionId();
+         int sessionId = connectionConsumerDelegate != null ?
+            connectionConsumerDelegate.getID() : state.getSessionId();
          
          connState.getResourceManager().addAck(txID, sessionId, info);
       }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -140,18 +140,15 @@
     * persist the message even if it is persistent - this is because persistent messages
     * are always persisted on the sending node before sending.
     */
-   public Delivery handleFromCluster(MessageReference ref)
-      throws Exception
+   public Delivery handleFromCluster(MessageReference ref) throws Exception
    {
-      if (trace) { log.trace("Handling ref from cluster: " + ref); }
-      
-      log.info("********** Handling ref from cluster: " + ref);
-      
+      if (trace) { log.trace(this + " handling " + ref + " from cluster"); }
+
       if (filter != null && !filter.accept(ref))
       {
          Delivery del = new SimpleDelivery(this, ref, true, false);
          
-         if (trace) { log.trace("Reference " + ref + " rejected by filter"); }
+         if (trace) { log.trace(this + " " + ref + " rejected by filter"); }
          
          return del;
       }

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/DistributedQueueTest.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -45,6 +45,10 @@
    {
    }
 
+
+   // If you're wondering why this test is commented out,
+   // see http://jira.jboss.com/jira/browse/JBMESSAGING-688
+
 //   public void testForwardingMessageAmongNodes() throws Exception
 //   {
 //      Connection conn = null;

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -49,33 +49,29 @@
       try
       {
          conn = cf.createConnection();
-
-         // send a message
-
-         Session s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageProducer p = s.createProducer(queue[0]);
-         p.setDeliveryMode(DeliveryMode.PERSISTENT);
-         p.send(s.createTextMessage("blip"));
-
          conn.close();
 
-         // create a connection to a node we'll kill soon (node 1)
-
          conn = cf.createConnection();
-         s = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageConsumer c = s.createConsumer(queue[2]); // TODO What happens if I use queue[1]?
          conn.start();
 
+         // create a producer/consumer on node 1
+
          // make sure we're connecting to node 1
 
-         int nodeID =
-            ((ConnectionState)((DelegateSupport)((JBossConnection)conn).getDelegate()).getState()).
-               getServerID();
+         int nodeID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn).
+            getDelegate()).getState()).getServerID();
 
          assertEquals(1, nodeID);
 
-         log.info("consumer created");
+         Session s1 = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer c1 = s1.createConsumer(queue[1]);
+         MessageProducer p1 = s1.createProducer(queue[1]);
+         p1.setDeliveryMode(DeliveryMode.PERSISTENT);
 
+         // send a message
+
+         p1.send(s1.createTextMessage("blip"));
+
          // kill node 1
 
          ServerManagement.kill(1);
@@ -90,7 +86,7 @@
 
          // we must receive the message
 
-         TextMessage tm = (TextMessage)c.receive(1000);
+         TextMessage tm = (TextMessage)c1.receive(1000);
          assertEquals("blip", tm.getText());
 
       }
@@ -109,7 +105,7 @@
 
    protected void setUp() throws Exception
    {
-      nodeCount = 3;
+      nodeCount = 2;
 
       super.setUp();
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -81,13 +81,15 @@
    
    // Public --------------------------------------------------------
    
-   // this test was created per JBMESSAGING-685
-   // as this required a ClusteredConnectionFactory I kept it into HATest but we can move it if we want
+   //
+
+   /**
+    * This test was created as per http://jira.jboss.org/jira/browse/JBMESSAGING-685.
+    */
    public void testEmptyCommit() throws Exception
    {
-      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
       Connection conn = cf.createConnection();
-      JBossSession session = (JBossSession) conn.createSession(true, Session.SESSION_TRANSACTED);
+      JBossSession session = (JBossSession)conn.createSession(true, Session.SESSION_TRANSACTED);
       session.commit();
       conn.close();
    }
@@ -214,92 +216,6 @@
 
    }
 
-   public void testTopicSubscriber() throws Exception
-   {
-      log.info("++testTopicSubscriber");
-
-      log.info(">>Lookup Queue");
-      Destination destination = (Destination) topic[1];
-
-
-      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
-      Connection conn1 = cf.createConnection();
-      Connection conn2 = cf.createConnection();
-      Connection conn3 = cf.createConnection();
-
-
-      this.checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
-      JBossConnection conn = (JBossConnection) getConnection(new Connection[]{conn1, conn2, conn3}, 1);
-
-      conn.setClientID("testClient");
-      conn.start();
-
-      JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
-      ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
-      SessionState sessionState = (SessionState) clientSessionDelegate.getState();
-
-      MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
-      JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
-
-      org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate = (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
-      ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
-
-      log.info("subscriptionName=" + consumerState.getSubscriptionName());
-
-
-      log.info(">>Creating Producer");
-      MessageProducer producer = session.createProducer(destination);
-      log.info(">>creating Message");
-      Message message = session.createTextMessage("Hello Before");
-      log.info(">>sending Message");
-      producer.send(message);
-      session.commit();
-
-      receiveMessage("consumerHA", consumerHA, true, false);
-
-      session.commit();
-      //if (true) return;
-
-      Object txID = sessionState.getCurrentTxId();
-
-      producer.send(session.createTextMessage("Hello again before failover"));
-
-      ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
-
-      JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
-
-      ServerManagement.kill(1);
-
-      Thread.sleep(30000);
-      // if failover happened, this object was replaced
-      assertNotSame(originalRemoting, delegate.getRemotingConnection());
-
-      //System.out.println("Kill server1"); Thread.sleep(10000);
-
-      message = session.createTextMessage("Hello After");
-      log.info(">>Sending new message");
-      producer.send(message);
-
-      assertEquals(txID, sessionState.getCurrentTxId());
-      System.out.println("TransactionID on client = " + txID);
-      log.info(">>Final commit");
-
-      session.commit();
-
-      log.info("Calling alternate receiver");
-      receiveMessage("consumerHA", consumerHA, true, false);
-      receiveMessage("consumerHA", consumerHA, true, false);
-      receiveMessage("consumerHA", consumerHA, true, true);
-
-
-      session.commit();
-      conn1.close();
-      conn2.close();
-      conn3.close();
-
-   }
-
-
 //   public void testQueueHA() throws Exception
 //   {
 //       log.info("++testTopicSubscriber");
@@ -1133,8 +1049,95 @@
       }
 
    }
+
+   public void testTopicSubscriber() throws Exception
+   {
+      log.info("++testTopicSubscriber");
+
+      log.info(">>Lookup Queue");
+      Destination destination = (Destination) topic[1];
+
+
+      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+      Connection conn1 = cf.createConnection();
+      Connection conn2 = cf.createConnection();
+      Connection conn3 = cf.createConnection();
+
+
+      this.checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
+      JBossConnection conn =
+         (JBossConnection) getConnection(new Connection[]{conn1, conn2, conn3}, 1);
+
+      conn.setClientID("testClient");
+      conn.start();
+
+      JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+      ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
+      SessionState sessionState = (SessionState) clientSessionDelegate.getState();
+
+      MessageConsumer consumerHA = session.createDurableSubscriber((Topic) destination, "T1");
+      JBossMessageConsumer jbossConsumerHA = (JBossMessageConsumer) consumerHA;
+
+      org.jboss.jms.client.delegate.ClientConsumerDelegate clientDelegate =
+         (org.jboss.jms.client.delegate.ClientConsumerDelegate) jbossConsumerHA.getDelegate();
+      ConsumerState consumerState = (ConsumerState) clientDelegate.getState();
+
+      log.info("subscriptionName=" + consumerState.getSubscriptionName());
+
+
+      log.info(">>Creating Producer");
+      MessageProducer producer = session.createProducer(destination);
+      log.info(">>creating Message");
+      Message message = session.createTextMessage("Hello Before");
+      log.info(">>sending Message");
+      producer.send(message);
+      session.commit();
+
+      receiveMessage("consumerHA", consumerHA, true, false);
+
+      session.commit();
+      //if (true) return;
+
+      Object txID = sessionState.getCurrentTxId();
+
+      producer.send(session.createTextMessage("Hello again before failover"));
+
+      ClientConnectionDelegate delegate = (ClientConnectionDelegate) conn.getDelegate();
+
+      JMSRemotingConnection originalRemoting = delegate.getRemotingConnection();
+
+      ServerManagement.kill(1);
+
+      Thread.sleep(30000);
+      // if failover happened, this object was replaced
+      assertNotSame(originalRemoting, delegate.getRemotingConnection());
+
+      //System.out.println("Kill server1"); Thread.sleep(10000);
+
+      message = session.createTextMessage("Hello After");
+      log.info(">>Sending new message");
+      producer.send(message);
+
+      assertEquals(txID, sessionState.getCurrentTxId());
+      System.out.println("TransactionID on client = " + txID);
+      log.info(">>Final commit");
+
+      session.commit();
+
+      log.info("Calling alternate receiver");
+      receiveMessage("consumerHA", consumerHA, true, false);
+      receiveMessage("consumerHA", consumerHA, true, false);
+      receiveMessage("consumerHA", consumerHA, true, true);
+
+
+      session.commit();
+      conn1.close();
+      conn2.close();
+      conn3.close();
+
+   }
+
    
-   
 // public void testConnectionFactoryConnect() throws Exception
 // {
 // try

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-20 05:46:30 UTC (rev 1828)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-20 06:06:06 UTC (rev 1829)
@@ -243,7 +243,6 @@
 //
 //      assertEquals(messageCounterProducer, messageCounterConsumer);
 //
-
    }
 
    // Protected -----------------------------------------------------



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 01:36:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 01:36:49 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1830 -
	trunk/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gwv4L-00053z-60@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-20 01:36:47 -0500 (Wed, 20 Dec 2006)
New Revision: 1830

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
removing unused connection

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 06:06:06 UTC (rev 1829)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 06:36:47 UTC (rev 1830)
@@ -1061,12 +1061,9 @@
       JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
       Connection conn1 = cf.createConnection();
       Connection conn2 = cf.createConnection();
-      Connection conn3 = cf.createConnection();
 
-
-      this.checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
       JBossConnection conn =
-         (JBossConnection) getConnection(new Connection[]{conn1, conn2, conn3}, 1);
+         (JBossConnection) getConnection(new Connection[]{conn1, conn2}, 1);
 
       conn.setClientID("testClient");
       conn.start();
@@ -1133,8 +1130,6 @@
       session.commit();
       conn1.close();
       conn2.close();
-      conn3.close();
-
    }
 
    



From ron_sigal at yahoo.com  Wed Dec 20 03:21:01 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 03:21:01 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1GwwhB-00071L-TS@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 03:21:01

  Modified:    src/main/org/jboss/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketServerInvoker.java
  Log:
  JBREM-650:  In createControlConnection() send Bisocket.CREATE_CONTROL_SOCKET after first invocation.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +19 -3     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Attic/BisocketServerInvoker.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- BisocketServerInvoker.java	19 Dec 2006 06:09:21 -0000	1.1.2.2
  +++ BisocketServerInvoker.java	20 Dec 2006 08:21:01 -0000	1.1.2.3
  @@ -52,7 +52,7 @@
   /**
    *  
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.2 $
  + * @version $Revision: 1.1.2.3 $
    * <p>
    * Copyright Nov 23, 2006
    * </p>
  @@ -144,22 +144,38 @@
      public void createControlConnection(String listenerId, InvokerLocator locator)
      throws IOException
      {
  +      boolean firstConnection;
  +      
         // first connection
         if (locator == null)
  +      {
  +         firstConnection = false;
            locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +      }
         // restarted connection
         else
  +      {
  +         firstConnection = true;
            listenerIdToInvokerLocatorMap.put(listenerId, locator);
  +      }
         
         log.info("creating control connection: " + locator);
  -//      Socket socket = new Socket(locator.getHost(), locator.getPort());
  +      
         Socket socket = null;
         if (socketFactory != null)
            socket = socketFactory.createSocket(locator.getHost(), locator.getPort());
         else
            socket = new Socket(locator.getHost(), locator.getPort());
  +      
         DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
  +      if (firstConnection)
  +      {
         dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +      }
  +      else
  +      {
  +         dos.write(Bisocket.CREATE_CONTROL_SOCKET);
  +      }
         dos.writeUTF(listenerId);
         Thread thread = new ControlConnectionThread(socket, listenerId);
         thread.setName("control: " + socket.toString());
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 03:54:42 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 03:54:42 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection
	...
Message-ID: <E1GwxDm-0007YB-PW@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 03:54:42

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/connection 
                        Tag: remoting_2_x
                        BisocketConnectionCheckTestCase.java
  Log:
  JBREM-650:  Renamed misspelled unit test case.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +79 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/Attic/BisocketConnectionCheckTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionCheckTestCase.java
  ===================================================================
  RCS file: BisocketConnectionCheckTestCase.java
  diff -N BisocketConnectionCheckTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionCheckTestCase.java	20 Dec 2006 08:54:42 -0000	1.1.2.1
  @@ -0,0 +1,79 @@
  +/*
  +* JBoss, a division of Red Hat
  +* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +import org.apache.log4j.Level;
  +
  +/**
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketConnectionCheckTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketConnectionCheckTestClient.class.getName(),
  +                     1,
  +                     BisocketConnectionCheckTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 03:57:15 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 03:57:15 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1GwxGF-0007c6-9W@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 03:57:15

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketTestCase.java
  Log:
  JBREM-650: Added test for new server side control socket after control connection failure in two failure test methods.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +27 -8     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/Attic/BisocketTestCase.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- BisocketTestCase.java	19 Dec 2006 06:13:07 -0000	1.1.2.2
  +++ BisocketTestCase.java	20 Dec 2006 08:57:15 -0000	1.1.2.3
  @@ -55,7 +55,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.2 $
  + * @version $Revision: 1.1.2.3 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -1152,6 +1152,11 @@
         client.invoke(CALLBACK_TEST);
         assertEquals(2, callbackHandler.callbackCounter);
         
  +      field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket newControlSocket = (Socket) field.get(clientInvoker);
  +      assertTrue(!controlSocket.equals(newControlSocket));
  +      
         client.removeListener(callbackHandler);
         client.disconnect();
      }
  @@ -1179,7 +1184,16 @@
         client.invoke(CALLBACK_TEST);
         assertEquals(1, callbackHandler.callbackCounter);
         
  -      Field field = Client.class.getDeclaredField("callbackConnectors");
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      BisocketClientInvoker clientInvoker = (BisocketClientInvoker) callbackClient.getInvoker();
  +      Field field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket serverSideControlSocket = (Socket) field.get(clientInvoker);
  +      
  +      field = Client.class.getDeclaredField("callbackConnectors");
         field.setAccessible(true);
         Map callbackConnectors = (Map) field.get(client);
         assertEquals(1, callbackConnectors.size());
  @@ -1193,7 +1207,7 @@
         Thread controlConnectionThread = (Thread) controlConnectionThreads.iterator().next();
         Class[] classes = BisocketServerInvoker.class.getDeclaredClasses();
         assertEquals(3, classes.length);
  -      Class invokerClass = null;
  +      Class controlConnectionThreadClass = null;
         for (int i = 0; i < classes.length; i++)
         {
            log.info(classes[i]);
  @@ -1202,16 +1216,16 @@
            log.info(className);
            if ("BisocketServerInvoker$ControlConnectionThread".equals(className))
            {
  -            invokerClass = classes[i];
  +            controlConnectionThreadClass = classes[i];
               break;
            }
         }
         
  -      assertTrue(invokerClass != null);
  -      field = invokerClass.getDeclaredField("controlSocket");
  +      assertTrue(controlConnectionThreadClass != null);
  +      field = controlConnectionThreadClass.getDeclaredField("controlSocket");
         field.setAccessible(true);
  -      Socket controlSocket = (Socket) field.get(controlConnectionThread);
  -      controlSocket.close();
  +      Socket clientSideControlSocket = (Socket) field.get(controlConnectionThread);
  +      clientSideControlSocket.close();
         
         Thread.sleep(TEST_PING_FREQUENCY * 2);
         client.invoke(CALLBACK_TEST);
  @@ -1219,6 +1233,11 @@
         Thread newControlConnectionThread = (Thread) controlConnectionThreads.iterator().next();
         assertTrue(!controlConnectionThread.equals(newControlConnectionThread));
         
  +      field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket newServerSideControlSocket = (Socket) field.get(clientInvoker);
  +      assertTrue(!serverSideControlSocket.equals(newServerSideControlSocket));
  +      
         client.removeListener(callbackHandler);
         client.disconnect();
      }
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 03:59:44 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 03:59:44 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl
	...
Message-ID: <E1GwxIe-0007ce-LO@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 03:59:44

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl 
                        Tag: remoting_2_x SSLBisocketTestCase.java
  Log:
  JBREM-650: Changed names of keystore and truststore files.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +2 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/SSLBisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/SSLBisocketTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketTestCase.java	19 Dec 2006 06:26:15 -0000	1.1.2.1
  +++ SSLBisocketTestCase.java	20 Dec 2006 08:59:44 -0000	1.1.2.2
  @@ -29,7 +29,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    * <p>
    * Copyright Dec 15, 2006
    * </p>
  @@ -45,7 +45,7 @@
      protected void addExtraClientConfig(Map config)
      {
         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  -      String trustStoreFilePath = this.getClass().getResource("truststore").getFile();
  +      String trustStoreFilePath = this.getClass().getResource(".truststore").getFile();
         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
      }
  @@ -54,7 +54,7 @@
      protected void addExtraServerConfig(Map config)
      {
         config.put(SSLSocketBuilder.REMOTING_KEY_STORE_TYPE, "JKS");
  -      String keyStoreFilePath = this.getClass().getResource("keystore").getFile();
  +      String keyStoreFilePath = this.getClass().getResource(".keystore").getFile();
         config.put(SSLSocketBuilder.REMOTING_KEY_STORE_FILE_PATH, keyStoreFilePath);
         config.put(SSLSocketBuilder.REMOTING_KEY_STORE_PASSWORD, "unit-tests-server");
      }
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:00:47 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:00:47 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config
	...
Message-ID: <E1GwxJf-0007eh-O4@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:00:47

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config 
                        Tag: remoting_2_x FactoryConfigTestCase.java
  Log:
  JBREM-650: Fixed transport name and added addExtraCallbackConfig().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +18 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/Attic/FactoryConfigTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/Attic/FactoryConfigTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- FactoryConfigTestCase.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ FactoryConfigTestCase.java	20 Dec 2006 09:00:47 -0000	1.1.2.2
  @@ -21,6 +21,10 @@
    */
   package org.jboss.test.remoting.transport.bisocket.ssl.config;
   
  +import java.util.Map;
  +
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
   import org.jboss.test.remoting.transport.config.FactoryConfigTestCaseSSLParent;
   
   
  @@ -35,6 +39,19 @@
   {
      protected String getTransport()
      {
  -      return "sslsocket";
  +      return "sslbisocket";
  +   }
  +   
  +   protected void addExtraCallbackConfig(Map config)
  +   {
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      
  +      // Callback server invoker needs to create a socket factory to contact
  +      // secondary server socket on server side.
  +      config.put(SSLSocketBuilder.REMOTING_SOCKET_USE_CLIENT_MODE, "true");
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  +      String trustStoreFilePath = getTruststoreFilePath();
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
      }
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:01:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:01:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom
	...
Message-ID: <E1GwxKh-0007gN-32@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:01:51

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom 
                        Tag: remoting_2_x SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650: Added overriding testCallbacks().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +55 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerClientTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ SSLBisocketInvokerClientTest.java	20 Dec 2006 09:01:51 -0000	1.1.2.2
  @@ -22,19 +22,73 @@
   
   package org.jboss.test.remoting.transport.bisocket.ssl.custom;
   
  +import java.util.HashMap;
  +import java.util.List;
  +
  +import org.apache.log4j.Logger;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
   import org.jboss.test.remoting.transport.socket.ssl.custom.InvokerClientTest;
   
   
   /**
    * @author <a href="mailto:tom at jboss.com">Tom Elrod</a>
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    * <p>
    * Copyright (c) Dec 15, 2006
    * </p>
    */
   public class SSLBisocketInvokerClientTest extends InvokerClientTest
   {
  +   private static Logger log = Logger.getLogger(SSLBisocketInvokerClientTest.class);
  +   
  +   public void testCallbacks()
  +   {
  +      try
  +      {
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://localhost:" + callbackPort);
  +         HashMap config = new HashMap();
  +         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  +         String trustStoreFilePath = this.getClass().getResource("../.truststore").getFile();
  +         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
  +         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
  +         config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +         Connector callbackConnector = new Connector(locator.getLocatorURI(), config);
  +         callbackConnector.setServerSocketFactory(createServerSocketFactory());
  +         callbackConnector.create();
  +         callbackConnector.addInvocationHandler("sample", new SampleInvocationHandler());
  +         callbackConnector.start();
  +
  +         CallbackHandler callbackHandler = new CallbackHandler();
  +         String callbackHandleObject = "myCallbackHandleObject";
  +         client.addListener(callbackHandler, locator, callbackHandleObject);
  +         solicitCallback("abc");
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(500);
  +         
  +         // remove callback handler from server
  +         client.removeListener(callbackHandler);
  +         
  +         // shut down callback server
  +         callbackConnector.stop();
  +         callbackConnector.destroy();
  +         callbackConnector = null;
  +         
  +         List callbacks = callbackHandler.getCallbacks();
  +         assertEquals(callbacks.size(), 1);
  +//         assertEquals(callbacks.get(0), "abc");
  +      }
  +      catch (Throwable t)
  +      {
  +         log.error(t);
  +         t.printStackTrace();
  +         fail();
  +      }
  +   }
   
      protected String getTransport()
      {
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:02:33 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:02:33 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom
	...
Message-ID: <E1GwxLN-0007sV-7Y@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:02:33

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom 
                        Tag: remoting_2_x SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650: Added main().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/Attic/SSLBisocketInvokerServerTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ SSLBisocketInvokerServerTest.java	20 Dec 2006 09:02:33 -0000	1.1.2.2
  @@ -30,6 +30,21 @@
    */
   public class SSLBisocketInvokerServerTest extends InvokerServerTest
   {
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerServerTest test = new SSLBisocketInvokerServerTest();
  +      try
  +      {
  +         test.setUp();
  +         Thread.sleep(20000);
  +         test.tearDown();
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +   
      protected String getTransport()
      {
         return "sslbisocket";
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:03:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:03:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/config ...
Message-ID: <E1GwxMg-0007uA-Ud@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:03:54

  Modified:    src/tests/org/jboss/test/remoting/transport/config   Tag:
                        remoting_2_x FactoryConfigTestCaseParent.java
                        FactoryConfigTestCaseSSLParent.java
  Log:
  JBREM-650: Added calls to addExtraCallbackConfig().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.5.4.1   +20 -6     JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseParent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCaseParent.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseParent.java,v
  retrieving revision 1.5
  retrieving revision 1.5.4.1
  diff -u -b -r1.5 -r1.5.4.1
  --- FactoryConfigTestCaseParent.java	1 Aug 2006 06:33:19 -0000	1.5
  +++ FactoryConfigTestCaseParent.java	20 Dec 2006 09:03:54 -0000	1.5.4.1
  @@ -65,7 +65,7 @@
   /**
    * 
    * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.5.4.1 $
    * <p>
    * Copyright (c) Jun 13, 2006
    * </p>
  @@ -234,7 +234,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -397,7 +399,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -551,7 +555,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -702,7 +708,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -826,7 +834,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -919,6 +929,10 @@
         return UniqueSocketFactory.class;
      }
      
  +   protected void addExtraCallbackConfig(Map config)
  +   {
  +   }
  +   
      public static class UniqueServerSocketFactory
      extends ServerSocketFactory
      implements ServerSocketFactoryMBean
  
  
  
  1.7.4.1   +12 -4     JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseSSLParent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCaseSSLParent.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseSSLParent.java,v
  retrieving revision 1.7
  retrieving revision 1.7.4.1
  diff -u -b -r1.7 -r1.7.4.1
  --- FactoryConfigTestCaseSSLParent.java	7 Aug 2006 21:17:33 -0000	1.7
  +++ FactoryConfigTestCaseSSLParent.java	20 Dec 2006 09:03:54 -0000	1.7.4.1
  @@ -190,7 +190,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -353,7 +355,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -495,7 +499,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -605,7 +611,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:07:05 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:07:05 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection
	...
Message-ID: <E1GwxPl-0007xz-P8@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:07:05

  Removed:     src/tests/org/jboss/test/remoting/transport/bisocket/connection 
                        Tag: remoting_2_x
                        BiocketConnectionCheckTestCase.java
  Log:
  JBREM-650: Deleting misspelled test case.


From msurtani at jboss.com  Wed Dec 20 04:07:15 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 04:07:15 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GwxPv-0007yC-Qu@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 04:07:15

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  Made _block and _unblock public
  
  Revision  Changes    Path
  1.296     +11 -13    JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.295
  retrieving revision 1.296
  diff -u -b -r1.295 -r1.296
  --- TreeCache.java	20 Dec 2006 04:02:09 -0000	1.295
  +++ TreeCache.java	20 Dec 2006 09:07:15 -0000	1.296
  @@ -95,7 +95,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.295 2006/12/20 04:02:09 vblagojevic Exp $
  + * @version $Id: TreeCache.java,v 1.296 2006/12/20 09:07:15 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -697,7 +697,7 @@
               // always use the InactiveRegionAwareRpcDispatcher - exceptions due to regions not being active should not propagate to remote
               // nodes as errors. - Manik
               disp = new InactiveRegionAwareRpcDispatcher(channel, ml, this, this);
  -//            disp = new RpcDispatcher(channel, ml, this, this);
  +            //            disp = new RpcDispatcher(channel, ml, this, this);
   
   
               disp.setMarshaller(getMarshaller());
  @@ -3182,12 +3182,12 @@
         }
      }
   
  -   private void _block()
  +   public void _block()
      {
         //intentionally empty, used only for reflection in MethodDeclarations.blockChannelLocal
      }
      
  -   private void _unblock()
  +   public void _unblock()
      {
         //intentionally empty, used only for reflection in MethodDeclarations.unblockChannelLocal
      }
  @@ -3580,13 +3580,13 @@
       */
      public void block()
      {
  -      if(log.isDebugEnabled())
  +      if (log.isDebugEnabled())
         {
            log.debug("Block received at " + getLocalAddress());
         }      
         MethodCall m = MethodCallFactory.create(MethodDeclarations.blockChannelLocal);
         invokeMethod(m);
  -      if(log.isDebugEnabled())
  +      if (log.isDebugEnabled())
         {
            log.debug("Block processed at " + getLocalAddress());
         }
  @@ -3594,18 +3594,16 @@
      
      /**
       * Indicates that a channel has received a UNBLOCK event from FLUSH protocol.
  -    * 
  -    * 
       */
      public void unblock()
      {
  -      if(log.isDebugEnabled())
  +      if (log.isDebugEnabled())
         {
            log.debug("UnBlock received at " + getLocalAddress());
         }
         MethodCall m = MethodCallFactory.create(MethodDeclarations.unblockChannelLocal);
         invokeMethod(m);
  -      if(log.isDebugEnabled())
  +      if (log.isDebugEnabled())
         {
            log.debug("UnBlock processed at " + getLocalAddress());
         }
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:08:02 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:08:02 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl
	...
Message-ID: <E1GwxQg-0007yX-GG@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:08:02

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl    
                        Tag: remoting_2_x .truststore .keystore
  Removed:     src/tests/org/jboss/test/remoting/transport/bisocket/ssl    
                        Tag: remoting_2_x keystore truststore
  Log:
  JBREM-650: Renamed keystore and truststore files.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +34 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/.truststore
  
  	<<Binary file>>
  
  
  1.1.2.1   +57 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/Attic/.keystore
  
  	<<Binary file>>
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:09:21 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:09:21 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load
	...
Message-ID: <E1GwxRx-0007yp-7P@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:09:21

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/load 
                        Tag: remoting_2_x PooledConnectionTestCase.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.4.1   +7 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/PooledConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PooledConnectionTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/PooledConnectionTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.4.1
  diff -u -b -r1.2 -r1.2.4.1
  --- PooledConnectionTestCase.java	23 Aug 2006 03:57:38 -0000	1.2
  +++ PooledConnectionTestCase.java	20 Dec 2006 09:09:21 -0000	1.2.4.1
  @@ -23,6 +23,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         PooledConnectionTestCase rt = new PooledConnectionTestCase();
  @@ -47,7 +52,7 @@
   
      public void startServer() throws Exception
      {
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=10&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=10&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  @@ -77,7 +82,7 @@
   
      public void runClient(String clientId) throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/?clientMaxPoolSize=2";
  +      String locatorURI = getTransport() + "://localhost:54000/?clientMaxPoolSize=2";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:09:47 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:09:47 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load
	...
Message-ID: <E1GwxSN-0007z7-1L@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:09:47

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/load 
                        Tag: remoting_2_x SocketLoadTestCase.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.6.1   +7 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/SocketLoadTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketLoadTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/SocketLoadTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.2.6.1
  diff -u -b -r1.2 -r1.2.6.1
  --- SocketLoadTestCase.java	21 May 2006 04:47:33 -0000	1.2
  +++ SocketLoadTestCase.java	20 Dec 2006 09:09:47 -0000	1.2.6.1
  @@ -42,6 +42,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         SocketLoadTestCase rt = new SocketLoadTestCase();
  @@ -67,7 +72,7 @@
   
      public void startServer() throws Exception
      {
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=2&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  @@ -90,7 +95,7 @@
   
      public void runClient(String clientId) throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/";
  +      String locatorURI = getTransport() + "://localhost:54000/";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:10:37 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:10:37 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom
	...
Message-ID: <E1GwxTB-00081k-Sr@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:10:37

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/custom 
                        Tag: remoting_2_x InvokerClientTest.java
  Log:
  JBREM-650: Made createServerSocketFactory() protected.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.12.4.1  +2 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerClientTest.java,v
  retrieving revision 1.12
  retrieving revision 1.12.4.1
  diff -u -b -r1.12 -r1.12.4.1
  --- InvokerClientTest.java	20 Jun 2006 17:27:51 -0000	1.12
  +++ InvokerClientTest.java	20 Dec 2006 09:10:37 -0000	1.12.4.1
  @@ -55,7 +55,7 @@
   
   /**
    * @author <a href="mailto:tom at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.12.4.1 $
    * <p>
    * Copyright (c) Mar 23, 2006
    * </p>
  @@ -219,7 +219,7 @@
      }
      
      
  -   private ServerSocketFactory createServerSocketFactory()
  +   protected ServerSocketFactory createServerSocketFactory()
      throws NoSuchAlgorithmException, KeyManagementException, IOException,
      CertificateException, UnrecoverableKeyException, KeyStoreException
      {
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:11:41 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:11:41 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout
	...
Message-ID: <E1GwxUD-00083K-L0@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:11:41

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout 
                        Tag: remoting_2_x TimeoutClientTest.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.6.4.1   +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TimeoutClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutClientTest.java,v
  retrieving revision 1.6
  retrieving revision 1.6.4.1
  diff -u -b -r1.6 -r1.6.4.1
  --- TimeoutClientTest.java	8 Jun 2006 02:29:17 -0000	1.6
  +++ TimeoutClientTest.java	20 Dec 2006 09:11:41 -0000	1.6.4.1
  @@ -35,12 +35,18 @@
   public class TimeoutClientTest extends TestCase
   {
   //   private String locatorURI = "socket://localhost:8899/?timeout=3000";
  -   private String locatorURI = "socket://localhost:8899";
  +//   private String locatorURI = "socket://localhost:8899";
  +
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
   
      public void testTimeout() throws Exception
      {
         Map config = new HashMap();
         config.put("timeout", "3000");
  +      String locatorURI = getTransport() + "://localhost:8899";
         Client client = new Client(new InvokerLocator(locatorURI), config);
         client.connect();
   
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:12:15 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:12:15 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout
	...
Message-ID: <E1GwxUl-00084A-8D@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:12:15

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout 
                        Tag: remoting_2_x TimeoutServerTest.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.5.4.1   +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TimeoutServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutServerTest.java,v
  retrieving revision 1.5
  retrieving revision 1.5.4.1
  diff -u -b -r1.5 -r1.5.4.1
  --- TimeoutServerTest.java	8 Jun 2006 02:29:27 -0000	1.5
  +++ TimeoutServerTest.java	20 Dec 2006 09:12:15 -0000	1.5.4.1
  @@ -40,13 +40,19 @@
   public class TimeoutServerTest extends ServerTestCase
   {
   //   private String locatorURI = "socket://localhost:8899/?timeout=3000";
  -   private String locatorURI = "socket://localhost:8899";
  +//   private String locatorURI = "socket://localhost:8899";
      private Connector connector = null;
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public void setUp() throws Exception
      {
         Map config = new HashMap();
         config.put("timeout", "3000");
  +      String locatorURI = getTransport() + "://localhost:8899";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         connector = new Connector(locator,  config);
         connector.create();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:13:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:13:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle
	...
Message-ID: <E1GwxW0-00086o-6s@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:13:32

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout/idle 
                        Tag: remoting_2_x IdleTimeoutClientTest.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +9 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdleTimeoutClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutClientTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- IdleTimeoutClientTest.java	3 Nov 2006 15:56:31 -0000	1.1.2.1
  +++ IdleTimeoutClientTest.java	20 Dec 2006 09:13:32 -0000	1.1.2.2
  @@ -1,11 +1,10 @@
   package org.jboss.test.remoting.transport.socket.timeout.idle;
   
  -import junit.framework.TestCase;
   import EDU.oswego.cs.dl.util.concurrent.SynchronizedInt;
  -import org.jboss.remoting.transport.Connector;
  -import org.jboss.remoting.InvokerLocator;
  -import org.jboss.remoting.Client;
  +import junit.framework.TestCase;
   import org.apache.log4j.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvokerLocator;
   
   /**
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  @@ -19,6 +18,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +
      public static void main(String[] args) throws Throwable
      {
         IdleTimeoutClientTest rt = new IdleTimeoutClientTest();
  @@ -28,7 +32,7 @@
   
      public void testRunClients() throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:13:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:13:50 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle
	...
Message-ID: <E1GwxWI-00087W-Ik@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:13:50

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout/idle 
                        Tag: remoting_2_x IdleTimeoutTestServer.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +8 -5      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdleTimeoutTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutTestServer.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- IdleTimeoutTestServer.java	3 Nov 2006 15:56:31 -0000	1.1.2.1
  +++ IdleTimeoutTestServer.java	20 Dec 2006 09:13:50 -0000	1.1.2.2
  @@ -1,11 +1,9 @@
   package org.jboss.test.remoting.transport.socket.timeout.idle;
   
  +import org.apache.log4j.Logger;
   import org.jboss.jrunit.extensions.ServerTestCase;
  -import org.jboss.remoting.transport.Connector;
   import org.jboss.remoting.InvokerLocator;
  -import org.jboss.remoting.Client;
  -import org.apache.log4j.Logger;
  -import EDU.oswego.cs.dl.util.concurrent.SynchronizedInt;
  +import org.jboss.remoting.transport.Connector;
   
   /**
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  @@ -16,6 +14,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         IdleTimeoutTestServer rt = new IdleTimeoutTestServer();
  @@ -39,7 +42,7 @@
      public void startServer() throws Exception
      {
   //      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&timeout=60000&backlog=0";
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&backlog=0&timeout=60000&idleTimeout=5";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=2&backlog=0&timeout=60000&idleTimeout=5";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 20 04:14:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 20 Dec 2006 04:14:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle
	...
Message-ID: <E1GwxWw-00087v-2s@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/20 04:14:30

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout/idle  
                        Tag: remoting_2_x
                        InactiveIdleTimeoutClientTest.java
                        InactiveIdleTimeoutTestServer.java
  Log:
  JBREM-650: Added getTransport().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +8 -3      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InactiveIdleTimeoutClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutClientTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- InactiveIdleTimeoutClientTest.java	3 Nov 2006 18:58:40 -0000	1.1.2.1
  +++ InactiveIdleTimeoutClientTest.java	20 Dec 2006 09:14:30 -0000	1.1.2.2
  @@ -1,10 +1,10 @@
   package org.jboss.test.remoting.transport.socket.timeout.idle;
   
  -import junit.framework.TestCase;
   import EDU.oswego.cs.dl.util.concurrent.SynchronizedInt;
  +import junit.framework.TestCase;
   import org.apache.log4j.Logger;
  -import org.jboss.remoting.InvokerLocator;
   import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvokerLocator;
   
   /**
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  @@ -18,6 +18,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +
      public static void main(String[] args) throws Throwable
      {
         InactiveIdleTimeoutClientTest rt = new InactiveIdleTimeoutClientTest();
  @@ -33,7 +38,7 @@
   
      public void runClient(String clientId) throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  
  1.1.2.2   +8 -3      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InactiveIdleTimeoutTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutTestServer.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- InactiveIdleTimeoutTestServer.java	3 Nov 2006 18:58:40 -0000	1.1.2.1
  +++ InactiveIdleTimeoutTestServer.java	20 Dec 2006 09:14:30 -0000	1.1.2.2
  @@ -1,10 +1,10 @@
   package org.jboss.test.remoting.transport.socket.timeout.idle;
   
  +import org.apache.log4j.Logger;
   import org.jboss.jrunit.extensions.ServerTestCase;
  +import org.jboss.remoting.InvokerLocator;
   import org.jboss.remoting.transport.Connector;
   import org.jboss.remoting.transport.socket.SocketServerInvoker;
  -import org.jboss.remoting.InvokerLocator;
  -import org.apache.log4j.Logger;
   
   /**
    * This is just like IdleTimeoutTestServer except instead of
  @@ -21,6 +21,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         InactiveIdleTimeoutTestServer rt = new InactiveIdleTimeoutTestServer();
  @@ -66,7 +71,7 @@
      public void startServer() throws Exception
      {
   //      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&timeout=60000&backlog=0";
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&backlog=0&timeout=10000&idleTimeout=15";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=2&backlog=0&timeout=10000&idleTimeout=15";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 04:35:20 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 04:35:20 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1831 - in trunk: . docs/examples
	docs/examples/common docs/examples/common/etc
	docs/examples/common/etc/META-INF
	docs/examples/common/src/org/jboss/example/jms/common
	docs/examples/common/src/org/jboss/example/jms/common/bean
	docs/examples/distributed-topic
	docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic
	docs/examples/queue-failover docs/examples/queue-failover/etc
	docs/examples/queue-failover/src
	docs/examples/queue-failover/src/org
	docs/examples/queue-failover/src/org/jboss
	docs/examples/queue-failover/src/org/jboss/example
	docs/examples/queue-failover/src/org/jboss/example/jms
	docs/examples/queue-failover/src/org/jboss/example/jms/failover
Message-ID: <E1Gwxr6-0008R3-9Z@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 04:35:13 -0500 (Wed, 20 Dec 2006)
New Revision: 1831

Added:
   trunk/docs/examples/common/etc/
   trunk/docs/examples/common/etc/META-INF/
   trunk/docs/examples/common/etc/META-INF/ejb-jar.xml
   trunk/docs/examples/common/etc/META-INF/jboss.xml
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java
   trunk/docs/examples/queue-failover/
   trunk/docs/examples/queue-failover/README.html
   trunk/docs/examples/queue-failover/build.xml
   trunk/docs/examples/queue-failover/do-not-distribute.properties
   trunk/docs/examples/queue-failover/etc/
   trunk/docs/examples/queue-failover/etc/jndi.properties
   trunk/docs/examples/queue-failover/etc/log4j.xml
   trunk/docs/examples/queue-failover/src/
   trunk/docs/examples/queue-failover/src/org/
   trunk/docs/examples/queue-failover/src/org/jboss/
   trunk/docs/examples/queue-failover/src/org/jboss/example/
   trunk/docs/examples/queue-failover/src/org/jboss/example/jms/
   trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/
   trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
Modified:
   trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java
   trunk/docs/examples/distributed-topic/build.xml
   trunk/docs/examples/distributed-topic/do-not-distribute.properties
   trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java
   trunk/messaging.iml
Log:
the first cut of distributed topic and queue failover examples

Added: trunk/docs/examples/common/etc/META-INF/ejb-jar.xml
===================================================================
--- trunk/docs/examples/common/etc/META-INF/ejb-jar.xml	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/common/etc/META-INF/ejb-jar.xml	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,16 @@
+<?xml version='1.0' encoding='UTF-8' ?>
+<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN"
+    "http://java.sun.com/dtd/ejb-jar_2_0.dtd">
+
+<ejb-jar>
+    <enterprise-beans>
+        <session>
+            <ejb-name>Management</ejb-name>
+            <home>org.jboss.example.jms.common.bean.ManagementHome</home>
+            <remote>org.jboss.example.jms.common.bean.Management</remote>
+            <ejb-class>org.jboss.example.jms.common.bean.ManagementBean</ejb-class>
+            <session-type>Stateless</session-type>
+            <transaction-type>Bean</transaction-type>
+        </session>
+    </enterprise-beans>
+</ejb-jar>
\ No newline at end of file

Added: trunk/docs/examples/common/etc/META-INF/jboss.xml
===================================================================
--- trunk/docs/examples/common/etc/META-INF/jboss.xml	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/common/etc/META-INF/jboss.xml	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE jboss PUBLIC
+   "-//JBoss//DTD JBOSS 3.0//EN"
+   "http://www.jboss.org/j2ee/dtd/jboss_3_0.dtd">
+<jboss>
+   <enterprise-beans>
+      <session>
+         <ejb-name>Management</ejb-name>
+         <jndi-name>ejb/Management</jndi-name>
+      </session>
+   </enterprise-beans>
+</jboss>

Modified: trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java	2006-12-20 09:35:13 UTC (rev 1831)
@@ -6,7 +6,14 @@
  */
 package org.jboss.example.jms.common;
 
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.example.jms.common.bean.ManagementHome;
+import org.jboss.example.jms.common.bean.Management;
+
 import javax.jms.ConnectionMetaData;
+import javax.jms.Connection;
 import javax.naming.InitialContext;
 
 /**
@@ -24,6 +31,79 @@
 
    // Static --------------------------------------------------------
 
+   public static int getServerID(Connection conn) throws Exception
+   {
+      if (!(conn instanceof JBossConnection))
+      {
+         throw new Exception("Connection not an instance of JBossConnection");
+      }
+
+      JBossConnection jbconn = (JBossConnection)conn;
+
+      DelegateSupport del = (DelegateSupport)jbconn.getDelegate();
+
+      ConnectionState state = (ConnectionState)del.getState();
+
+      return state.getServerID();
+   }
+
+   public static void assertEquals(Object o, Object o2)
+   {
+       if (o == null && o2 == null)
+       {
+          return;
+       }
+
+       if (o.equals(o2))
+       {
+          return;
+       }
+
+       throw new RuntimeException("Assertion failed, " + o + " != " + o2);
+   }
+
+   public static void assertEquals(int i, int i2)
+   {
+       if (i == i2)
+       {
+          return;
+       }
+
+       throw new RuntimeException("Assertion failed, " + i + " != " + i2);
+   }
+
+   public static void assertNotEquals(int i, int i2)
+   {
+        if (i != i2)
+        {
+           return;
+        }
+
+        throw new RuntimeException("Assertion failed, " + i + " == " + i2);
+   }
+
+
+   public static void killActiveNode() throws Exception
+   {
+      // Currently it will always kill the primary node, ignoring nodeID
+
+      try
+      {
+         InitialContext ic = new InitialContext();
+
+         ManagementHome home = (ManagementHome)ic.lookup("ejb/Management");
+         Management bean = home.create();
+         bean.killAS();
+      }
+      catch(Exception e)
+      {
+         // OK, I expect exceptions following a VM kill
+
+         //e.printStackTrace();
+      }
+   }
+
+
    // Attributes ----------------------------------------------------
 
    private boolean failure;
@@ -99,32 +179,6 @@
      System.out.println(info);
    }
 
-   protected void assertEquals(Object o, Object o2)
-   {
-      if (o == null && o2 == null)
-      {
-         return;
-      }
-
-      if (o.equals(o2))
-      {
-         return;
-      }
-
-      throw new RuntimeException("Assertion failed, " + o + " != " + o2);
-   }
-
-   protected void assertEquals(int i, int i2)
-   {
-      if (i == i2)
-      {
-         return;
-      }
-
-      throw new RuntimeException("Assertion failed, " + i + " != " + i2);
-   }
-
-
    // Private -------------------------------------------------------
 
    protected void setup() throws Exception

Added: trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,25 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.example.jms.common.bean;
+
+import javax.ejb.EJBObject;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 1766 $</tt>
+
+ * $Id: StatelessSessionExample.java 1766 2006-12-11 22:29:27Z ovidiu.feodorov at jboss.com $
+ */
+
+public interface Management extends EJBObject
+{
+   /**
+    * It kills the VM running the node instance. Needed by the failover tests.
+    */
+   public void killAS() throws Exception, RemoteException;
+}

Added: trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,73 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.example.jms.common.bean;
+
+import javax.ejb.SessionBean;
+import javax.ejb.SessionContext;
+import javax.ejb.EJBException;
+import javax.jms.ConnectionFactory;
+import javax.jms.Queue;
+import javax.jms.Session;
+import javax.jms.Connection;
+import javax.jms.MessageConsumer;
+import javax.jms.Message;
+import javax.jms.MessageProducer;
+import javax.jms.TextMessage;
+import javax.jms.QueueBrowser;
+import javax.jms.JMSException;
+import javax.naming.InitialContext;
+import java.util.ArrayList;
+import java.util.Enumeration;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 1766 $</tt>
+
+ * $Id: StatelessSessionExampleBean.java 1766 2006-12-11 22:29:27Z ovidiu.feodorov at jboss.com $
+ */
+public class ManagementBean implements SessionBean
+{
+   private SessionContext ctx;
+
+   public void killAS() throws Exception
+   {
+      System.out.println("######");
+      System.out.println("######");
+      System.out.println("######");
+      System.out.println("######");
+      System.out.println("###### SIMULATING A FAILURE, KILLING THE VM!");
+      System.out.println("######");
+      System.out.println("######");
+      System.out.println("######");
+      System.out.println("######");
+
+      Runtime.getRuntime().halt(1);
+   }
+
+   public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
+   {
+      this.ctx = ctx;
+   }
+
+   public void ejbCreate()
+   {
+   }
+
+   public void ejbRemove() throws EJBException
+   {
+   }
+
+   public void ejbActivate() throws EJBException, RemoteException
+   {
+   }
+
+   public void ejbPassivate() throws EJBException, RemoteException
+   {
+   }
+
+}

Added: trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,23 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.example.jms.common.bean;
+
+import javax.ejb.EJBHome;
+import javax.ejb.CreateException;
+import java.rmi.RemoteException;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 563 $</tt>
+
+ * $Id: StatelessSessionExampleHome.java 563 2005-12-30 22:04:19Z ovidiu $
+ */
+
+public interface ManagementHome extends EJBHome
+{
+   public Management create() throws RemoteException, CreateException;
+}

Modified: trunk/docs/examples/distributed-topic/build.xml
===================================================================
--- trunk/docs/examples/distributed-topic/build.xml	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/distributed-topic/build.xml	2006-12-20 09:35:13 UTC (rev 1831)
@@ -27,6 +27,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/distributed-topic/do-not-distribute.properties
===================================================================
--- trunk/docs/examples/distributed-topic/do-not-distribute.properties	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/distributed-topic/do-not-distribute.properties	2006-12-20 09:35:13 UTC (rev 1831)
@@ -4,4 +4,4 @@
 #
 messaging.client.jar.path=../../../output/lib
 messaging.client.jar.name=jboss-messaging-client.jar
-jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
+#jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA

Modified: trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java
===================================================================
--- trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java	2006-12-20 09:35:13 UTC (rev 1831)
@@ -51,14 +51,16 @@
 {
    public void example() throws Exception
    {
+
       String destinationName = getDestinationJNDIName();
 
+
       InitialContext ic = null;
-      InitialContext ic2 = null;
 
-      Connection connection = null;
-      Connection connection2 = null;
 
+      Connection connection0 = null;
+      Connection connection1 = null;
+
       try
       {
          // connecting to the first node
@@ -69,58 +71,68 @@
          Topic distributedTopic = (Topic)ic.lookup(destinationName);
          log("Distributed topic " + destinationName + " exists");
 
-         connection = cf.createConnection();
-         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageProducer publisher = session.createProducer(distributedTopic);
 
-         MessageConsumer subscriber = session.createConsumer(distributedTopic);
+         // When connecting to a messaging cluster, the ConnectionFactory has the capability of
+         // transparently creating physical connections to different cluster nodes, in a round
+         // robin fashion ...
 
-         ExampleListener messageListener = new ExampleListener("MessageListener 1");
-         subscriber.setMessageListener(messageListener);
 
-         // connecting to the second node
+         // ... so this is a connection to a cluster node
+         connection0 = cf.createConnection();
 
-         Hashtable environment = new Hashtable();
-         environment.put("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
-         environment.put("java.naming.provider.url", "jnp://localhost:1199");
-         environment.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
+         // ... and this is a connection to a different cluster node
+         connection1 = cf.createConnection();
 
-         ic2 = new InitialContext(environment);
+         // Let's make sure that (this example is also a smoke test)
+         assertNotEquals(getServerID(connection0), getServerID(connection1));
 
-         ConnectionFactory cf2 = (ConnectionFactory)ic2.lookup("/ConnectionFactory");
 
-         connection2 = cf2.createConnection();
-         Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         // Create a session, a producer and consumer for the distributed topic, using connection0
 
-         MessageConsumer subscriber2 = session2.createConsumer(distributedTopic);
+         Session session0 = connection0.createSession(false, Session.AUTO_ACKNOWLEDGE);
 
-         ExampleListener messageListener2 = new ExampleListener("MessageListener 2");
-         subscriber2.setMessageListener(messageListener2);
+         MessageConsumer subscriber0 = session0.createConsumer(distributedTopic);
+         ExampleListener messageListener0 = new ExampleListener("MessageListener 0");
+         subscriber0.setMessageListener(messageListener0);
 
-         // starting the connections
 
-         connection.start();
-         connection2.start();
+         MessageProducer publisher = session0.createProducer(distributedTopic);
 
-         // sending the message
 
-         TextMessage message = session.createTextMessage("Hello!");
+
+         // Create a session and a consumer for the distributed topic, using connection1
+
+         Session session1 = connection1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageConsumer subscriber1 = session1.createConsumer(distributedTopic);
+
+         ExampleListener messageListener1 = new ExampleListener("MessageListener 1");
+         subscriber1.setMessageListener(messageListener1);
+
+         // Starting the connections
+
+         connection0.start();
+         connection1.start();
+
+         // Sending the message
+
+         TextMessage message = session0.createTextMessage("Hello!");
          publisher.send(message);
 
          log("The message was successfully published on the distributed topic");
 
-         messageListener.waitForMessage();
-         messageListener2.waitForMessage();
+         messageListener0.waitForMessage();
+         messageListener1.waitForMessage();
 
-         message = (TextMessage)messageListener.getMessage();
-         log(messageListener.getName() + " received message: " + message.getText());
+         message = (TextMessage)messageListener0.getMessage();
+         log(messageListener0.getName() + " received message: " + message.getText());
          assertEquals("Hello!", message.getText());
 
-         message = (TextMessage)messageListener2.getMessage();
-         log(messageListener2.getName() + " received message: " + message.getText());
+         message = (TextMessage)messageListener1.getMessage();
+         log(messageListener1.getName() + " received message: " + message.getText());
          assertEquals("Hello!", message.getText());
 
-         displayProviderInfo(connection.getMetaData());
+         displayProviderInfo(connection0.getMetaData());
 
       }
       finally
@@ -137,41 +149,29 @@
             }
          }
 
-         if(ic2 != null)
-         {
-            try
-            {
-               ic2.close();
-            }
-            catch(Exception e)
-            {
-               throw e;
-            }
-         }
-
          try
          {
-            if (connection != null)
+            if (connection0 != null)
             {
-               connection.close();
+               connection0.close();
             }
          }
          catch(JMSException e)
          {
-            log("Could not close connection " + connection + ", exception was " + e);
+            log("Could not close connection " + connection0 + ", exception was " + e);
             throw e;
          }
 
          try
          {
-            if (connection2 != null)
+            if (connection1 != null)
             {
-               connection2.close();
+               connection1.close();
             }
          }
          catch(JMSException e)
          {
-            log("Could not close connection " + connection2 + ", exception was " + e);
+            log("Could not close connection " + connection1 + ", exception was " + e);
             throw e;
          }
       }

Added: trunk/docs/examples/queue-failover/README.html
===================================================================
--- trunk/docs/examples/queue-failover/README.html	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/queue-failover/README.html	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,155 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
+<html>
+<head>
+  <meta content="text/html; charset=ISO-8859-1"
+ http-equiv="content-type">
+  <title>JBoss Messaging Example - JMS Topic</title>
+</head>
+<body>
+<br>
+<h1>JBoss Messaging Distributed Topic Example</h1>
+$Revision: 1017 $
+<h2>Overview</h2>
+<br>
+This example demonstrates how to write JMS code that connects to a
+JBoss Messaging cluster and sends messages to a distributed topic. The
+client code creates two distinct JMS connections to two different
+cluster nodes. Each connection is then used to create a subscriber for
+the distributed topic. The example is considered
+successful
+if both subscribers receive a message sent to the topic.<br>
+<br>
+<span style="font-weight: bold;">Note<br>
+</span>
+<div style="margin-left: 40px;">In order to create connections to
+different cluster nodes, the example looks up and downloads
+ConnectionFactories bound in the local JNDI space of each cluster node.
+This is done by explicitely configuring the JNDI client environment to
+point to different physical cluster nodes. This is just a temporary
+solution, used only by the current Alpha release. Subsequent releases
+will use HA-JNDI.<br>
+<span style="font-weight: bold;"></span></div>
+<br>
+<br>
+This example relies on having access to a running JBoss Messaging
+cluster with at least two nodes. The JBoss Messaging cluster must be
+installed and started according to
+the
+"Installation" paragraph from the clustering documentation, bundled
+with the release (<a href="../../docs/clustering/html/index.html">HTML</a>,
+<a href="../../docs/clustering/html_single/index.html">HTML-single</a>
+and <a href="../../docs/clustering/pdf/ClusteringGuide.pdf">PDF</a>).
+The
+clustering documentation is also available on-line at <a
+ href="http://labs.jboss.com/portal/jbossmessaging/docs/index.html">http://labs.jboss.com/portal/jbossmessaging/docs/index.html</a>.
+<br>
+<br>
+This example also relies on having access to the <span
+ style="font-family: monospace;">jboss-messaging-client.jar</span>
+archive included with the release bundle. If you run this example
+from
+an unzipped installation bundle, the example run script is correctly
+configured to find the client jar. Otherwise, you must modify example's
+<span style="font-family: monospace;">build.xml</span> accordingly.<br>
+<span style="font-style: italic;"></span><br>
+<h2>Running the example</h2>
+<span style="font-family: monospace;"></span><span
+ style="font-family: monospace;"></span><br>
+1. Make sure that a JBoss Messaging cluster with at least two nodes is
+up and running.<br>
+<br>
+2. Go to the example's home directory<br>
+<br>
+<div style="margin-left: 40px;"><span style="font-family: monospace;">cd
+...\examples\distributed-topic</span><br>
+</div>
+<br>
+3. Run the example:<br>
+<br>
+<div style="margin-left: 40px;"><span style="font-family: monospace;">ant</span>
+<br>
+<br>
+<br>
+</div>
+The output of a successful run should be similar to:<br>
+<div style="margin-left: 40px;"><br>
+</div>
+<table
+ style="width: 90%; text-align: left; font-family: monospace; background-color: rgb(204, 204, 204); margin-left: 40px;"
+ border="1" cellpadding="2" cellspacing="2">
+  <tbody>
+    <tr>
+      <td style="vertical-align: top;">
+      <div style="margin-left: 40px;"><br>
+      </div>
+$ ant<br>
+Buildfile: build.xml<br>
+      <br>
+identify:<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [echo]
+###########################################################################<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [echo]
+#&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
+Running the DISTRIBUTED TOPIC
+example&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
+#<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [echo]
+###########################################################################<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [echo] The
+topic:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; testDistributedTopic<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [echo] The client jar:
+../../../output/lib/jboss-messaging-client.jar<br>
+      <br>
+sanity-check:<br>
+      <br>
+init:<br>
+&nbsp;&nbsp;&nbsp; [mkdir] Created dir:
+C:\work\src\svn\messaging\docs\examples\distributed-topic\output<br>
+&nbsp;&nbsp;&nbsp; [mkdir] Created dir:
+C:\work\src\svn\messaging\docs\examples\common\output<br>
+      <br>
+compile:<br>
+&nbsp;&nbsp;&nbsp; [javac] Compiling 2 source files to
+C:\work\src\svn\messaging\docs\examples\common\output<br>
+&nbsp;&nbsp;&nbsp; [javac] Compiling 2 source files to
+C:\work\src\svn\messaging\docs\examples\distributed-topic\output<br>
+      <br>
+run:<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] Distributed topic
+/topic/testDistributedTopic exists<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] The message was successfully published
+on the distributed topic<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] MessageListener 1 received message:
+Hello!<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] MessageListener 2 received message:
+Hello!<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] The example connected to JBoss
+Messaging version 1.2.0.Alpha1 (1.2)<br>
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] #####################<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] ###&nbsp;&nbsp;&nbsp;
+SUCCESS!&nbsp;&nbsp; ###<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] #####################<br>
+      <br>
+BUILD SUCCESSFUL<br>
+Total time: 4 seconds<br>
+      <br>
+      <br>
+      </td>
+    </tr>
+  </tbody>
+</table>
+<div style="margin-left: 40px;"><br>
+</div>
+<br>
+<br>
+<br>
+<hr style="width: 100%; height: 2px;"><br>
+<br>
+<br>
+<br>
+<br>
+<br>
+<br>
+</body>
+</html>

Added: trunk/docs/examples/queue-failover/build.xml
===================================================================
--- trunk/docs/examples/queue-failover/build.xml	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/queue-failover/build.xml	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,121 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+
+   To run the example, set JBOSS_HOME and run ant (with no parameters)
+
+   $Id: build.xml 974 2006-05-22 21:35:38 -0600 (Mon, 22 May 2006) ovidiu $
+
+ -->
+
+<project name="DistributedTopicExample" default="run">
+
+   <property environment="ENV"/>
+
+   <!--
+        If you don't find this file in the current directory, it's ok, it's intended to provide
+        defaults for in-workarea testing and it's not meant for distribution with the example bundle.
+   -->
+   <property file="do-not-distribute.properties"/>
+
+   <!-- These properties may be overriden by calling ants when this example is used in a smoke test -->
+   <property name="messaging.client.jar.path" value="../.."/>
+   <property name="messaging.client.jar.name" value="jboss-messaging-client.jar"/>
+   <property name="jboss.home" value="${ENV.JBOSS_HOME}"/>
+   <property name="example.queue.name" value="testDistributedQueue"/>
+
+   <path id="common.compilation.classpath">
+      <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
+      <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
+   </path>
+
+   <path id="example.compilation.classpath">
+      <path refid="common.compilation.classpath"/>
+      <pathelement path="../common/output"/>
+   </path>
+
+   <path id="execution.classpath">
+      <pathelement path="./etc"/>
+      <pathelement path="../common/output"/>
+      <pathelement path="./output"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
+       <fileset dir="${jboss.home}/client" includes="*.jar"/>
+   </path>
+
+   <target name="identify">
+      <echo message="###########################################################################"/>
+      <echo message="#                Running the QUEUE FAILOVER example                       #"/>
+      <echo message="###########################################################################"/>
+      <echo message="The queue:      ${example.queue.name}"/>
+      <echo message="The client jar: ${messaging.client.jar.path}/${messaging.client.jar.name}"/>
+   </target>
+
+   <target name="sanity-check" depends="identify">
+      <available property="client.jar.present" file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
+      <fail message="Could not find client jar ${messaging.client.jar.path}/${messaging.client.jar.name}"
+            unless="client.jar.present"/>
+   </target>
+
+   <target name="init" depends="sanity-check">
+      <mkdir dir="./output/lib"/>
+      <mkdir dir="../common/output"/>
+   </target>
+
+   <target name="compile" depends="init">
+      <javac destdir="../common/output" debug="on" debuglevel="lines,vars,source">
+         <src path="../common/src"/>
+         <classpath refid="common.compilation.classpath"/>
+      </javac>
+      <javac destdir="./output" debug="on" debuglevel="lines,vars,source">
+         <src path="./src"/>
+         <classpath refid="example.compilation.classpath"/>
+      </javac>
+   </target>
+
+   <target name="jar" depends="compile">
+      <jar destfile="./output/lib/application-server-killer.jar">
+         <fileset dir="../common/etc" includes="META-INF/**"/>
+         <fileset dir="../common/output" includes="org/jboss/example/jms/common/bean/*.class"/>
+      </jar>
+   </target>
+
+   <target name="deploy" depends="jar">
+      <copy file="./output/lib/application-server-killer.jar"
+            todir="${jboss.home}/server/messaging-node0/deploy"/>
+      <antcall target="sleep"><param name="sleep.interval" value="5"/></antcall>
+   </target>
+
+
+   <target name="run" depends="deploy">
+      <!--
+           DistributedTopicExample expects to find the name of the topic to connect to as value of
+           the 'example.topic.name' property, which *may* be defined by calling ant when this
+           example is used in a smoke test.
+      -->
+      <java classname="org.jboss.example.jms.failover.QueueFailoverExample"
+         classpathref="execution.classpath" fork="yes" failonerror="true">
+         <sysproperty key="example.queue.name" value="${example.queue.name}"/>
+         <!--
+         <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=example"/>
+          -->
+      </java>
+       <antcall target="undeploy"/>
+   </target>
+
+   <target name="undeploy">
+      <delete file="${jboss.home}/server/messaging-node0/deploy/application-server-killer.jar" quiet="true"/>
+   </target>
+
+   <target name="clean" depends="undeploy">
+      <delete dir="./output" quiet="true"/>
+      <delete dir="../common/output" quiet="true"/>
+   </target>
+
+   <target name="sleep">
+      <echo message="Sleeping for ${sleep.interval} seconds ..."/>
+      <sleep seconds="${sleep.interval}"/>
+   </target>
+
+</project>
+

Added: trunk/docs/examples/queue-failover/do-not-distribute.properties
===================================================================
--- trunk/docs/examples/queue-failover/do-not-distribute.properties	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/queue-failover/do-not-distribute.properties	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,7 @@
+#
+# This file provides values for in-workarea example testing.
+# DO NOT DISTRIBUTE!
+#
+messaging.client.jar.path=../../../output/lib
+messaging.client.jar.name=jboss-messaging-client.jar
+#jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA

Added: trunk/docs/examples/queue-failover/etc/jndi.properties
===================================================================
--- trunk/docs/examples/queue-failover/etc/jndi.properties	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/queue-failover/etc/jndi.properties	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,4 @@
+### JBossNS properties
+java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
+java.naming.provider.url=jnp://localhost:1099
+java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces

Added: trunk/docs/examples/queue-failover/etc/log4j.xml
===================================================================
--- trunk/docs/examples/queue-failover/etc/log4j.xml	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/queue-failover/etc/log4j.xml	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
+
+<!-- $Id: log4j.xml 536 2005-12-22 00:28:39 -0600 (Thu, 22 Dec 2005) ovidiu $ -->
+
+<log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
+
+   <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
+      <param name="Target" value="System.out"/>
+      <param name="Threshold" value="INFO"/>
+      <layout class="org.apache.log4j.PatternLayout">
+         <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p @%t [%c{1}] %m%n"/>
+      </layout>
+   </appender>
+
+   <root>
+      <appender-ref ref="CONSOLE"/>
+   </root>
+
+</log4j:configuration>

Added: trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
===================================================================
--- trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 09:35:13 UTC (rev 1831)
@@ -0,0 +1,152 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.example.jms.failover;
+
+import javax.naming.InitialContext;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.Session;
+import javax.jms.MessageProducer;
+import javax.jms.MessageConsumer;
+import javax.jms.TextMessage;
+import javax.jms.JMSException;
+import javax.jms.Queue;
+
+import org.jboss.example.jms.common.ExampleSupport;
+
+/**
+ * The example creates a connection to a clustered messaging instance and sends a message to a
+ * clustered queue. The example then kills the cluster node the connection was created to and then
+ * shows how the client code can receive the message with using the *same* connection (that, in
+ * the mean time, have transparently failed over to another cluster node).
+ *
+ * Since this example is also used as a smoke test, it is essential that the VM exits with exit
+ * code 0 in case of successful execution and a non-zero value on failure.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 1001 $</tt>
+ *
+ * $Id: TopicExample.java 1001 2006-06-24 09:05:40Z timfox $
+ */
+public class QueueFailoverExample extends ExampleSupport
+{
+   public void example() throws Exception
+   {
+
+      String destinationName = getDestinationJNDIName();
+
+
+      InitialContext ic = null;
+
+
+      Connection connection = null;
+
+      try
+      {
+         // Create a connection to the clustered messaging instance
+
+         ic = new InitialContext();
+
+         ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+         Queue distributedQueue = (Queue)ic.lookup(destinationName);
+         log("Distributed queue " + destinationName + " exists");
+
+
+         // When connecting to a messaging cluster, the ConnectionFactory has the capability of
+         // transparently creating physical connections to different cluster nodes, in a round
+         // robin fashion ...
+
+         connection = cf.createConnection();
+
+         connection.start();
+
+         // Send a message to the queue
+
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer producer = session.createProducer(distributedQueue);
+         TextMessage message = session.createTextMessage("Hello!");
+
+         producer.send(message);
+
+
+         log("The message was successfully sent to the distributed queue");
+
+
+
+         // Kill the active node
+         killActiveNode();
+
+
+         Thread.sleep(30000); // TODO not necesare after we install the client valve
+
+
+         // Transparenty create a consumer and receive the message
+
+         MessageConsumer consumer = session.createConsumer(distributedQueue);
+
+         message = (TextMessage)consumer.receive(2000);
+         log("Received message: " + message.getText());
+         assertEquals("Hello!", message.getText());
+
+         displayProviderInfo(connection.getMetaData());
+
+      }
+      finally
+      {
+         if(ic != null)
+         {
+            try
+            {
+               ic.close();
+            }
+            catch(Exception e)
+            {
+               throw e;
+            }
+         }
+
+         try
+         {
+            if (connection != null)
+            {
+               connection.close();
+            }
+         }
+         catch(JMSException e)
+         {
+            log("Could not close connection " + connection + ", exception was " + e);
+            throw e;
+         }
+      }
+   }
+
+   protected boolean isQueueExample()
+   {
+      return true;
+   }
+
+   public static void main(String[] args)
+   {
+      new QueueFailoverExample().run();
+   }
+
+}

Modified: trunk/messaging.iml
===================================================================
--- trunk/messaging.iml	2006-12-20 06:36:47 UTC (rev 1830)
+++ trunk/messaging.iml	2006-12-20 09:35:13 UTC (rev 1831)
@@ -9,6 +9,7 @@
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/distributed-topic/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/http/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/mdb/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/queue-failover/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/queue/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/secure-socket/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/stateless/src" isTestSource="false" />



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 04:39:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 04:39:23 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1832 -
	trunk/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gwxv1-0008TJ-4r@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 04:39:22 -0500 (Wed, 20 Dec 2006)
New Revision: 1832

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
Log:
remove unused factory

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 09:35:13 UTC (rev 1831)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 09:39:22 UTC (rev 1832)
@@ -1058,7 +1058,6 @@
       Destination destination = (Destination) topic[1];
 
 
-      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
       Connection conn1 = cf.createConnection();
       Connection conn2 = cf.createConnection();
 



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 05:17:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 05:17:09 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1833 - trunk
Message-ID: <E1GwyVZ-0000ql-P2@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 05:17:08 -0500 (Wed, 20 Dec 2006)
New Revision: 1833

Removed:
   trunk/jboss-remoting-npe-temp-fix.jar
Log:
we don't seem to need it

Deleted: trunk/jboss-remoting-npe-temp-fix.jar
===================================================================
(Binary files differ)



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 05:58:11 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 05:58:11 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1834 - in trunk/docs/examples:
	ejb3mdb http mdb queue secure-socket stateless topic
Message-ID: <E1Gwz9H-0001RF-D9@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 05:58:07 -0500 (Wed, 20 Dec 2006)
New Revision: 1834

Modified:
   trunk/docs/examples/ejb3mdb/build.xml
   trunk/docs/examples/http/build.xml
   trunk/docs/examples/mdb/build.xml
   trunk/docs/examples/queue/build.xml
   trunk/docs/examples/secure-socket/build.xml
   trunk/docs/examples/stateless/build.xml
   trunk/docs/examples/topic/build.xml
Log:
adjusted examples build scripts to cope with the fact that we're using JBoss Messaging specific classes in common

Modified: trunk/docs/examples/ejb3mdb/build.xml
===================================================================
--- trunk/docs/examples/ejb3mdb/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/ejb3mdb/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -29,6 +29,7 @@
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
       <fileset file="${jboss.home}/server/${jboss.configuration}/deploy/ejb3.deployer/jboss-ejb3x.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/http/build.xml
===================================================================
--- trunk/docs/examples/http/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/http/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -27,6 +27,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/mdb/build.xml
===================================================================
--- trunk/docs/examples/mdb/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/mdb/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -28,6 +28,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/queue/build.xml
===================================================================
--- trunk/docs/examples/queue/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/queue/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -27,6 +27,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/secure-socket/build.xml
===================================================================
--- trunk/docs/examples/secure-socket/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/secure-socket/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -28,6 +28,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/stateless/build.xml
===================================================================
--- trunk/docs/examples/stateless/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/stateless/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -28,6 +28,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">

Modified: trunk/docs/examples/topic/build.xml
===================================================================
--- trunk/docs/examples/topic/build.xml	2006-12-20 10:17:08 UTC (rev 1833)
+++ trunk/docs/examples/topic/build.xml	2006-12-20 10:58:07 UTC (rev 1834)
@@ -27,6 +27,7 @@
    <path id="common.compilation.classpath">
       <fileset file="${jboss.home}/client/jboss-j2ee.jar"/>
       <fileset file="${jboss.home}/client/jboss-j2se.jar"/>
+      <fileset file="${messaging.client.jar.path}/${messaging.client.jar.name}"/>
    </path>
 
    <path id="example.compilation.classpath">



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 06:01:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 06:01:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1835 -
	trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover
Message-ID: <E1GwzCi-0001VQ-78@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-20 06:01:42 -0500 (Wed, 20 Dec 2006)
New Revision: 1835

Modified:
   trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
Log:
Fixed test



Modified: trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
===================================================================
--- trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 10:58:07 UTC (rev 1834)
+++ trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 11:01:42 UTC (rev 1835)
@@ -54,19 +54,19 @@
 
       String destinationName = getDestinationJNDIName();
 
-
       InitialContext ic = null;
 
-
       Connection connection = null;
 
       try
       {
          // Create a connection to the clustered messaging instance
 
+
          ic = new InitialContext();
 
          ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+
          Queue distributedQueue = (Queue)ic.lookup(destinationName);
          log("Distributed queue " + destinationName + " exists");
 
@@ -87,7 +87,9 @@
 
          producer.send(message);
 
+         MessageConsumer consumer = session.createConsumer(distributedQueue);
 
+
          log("The message was successfully sent to the distributed queue");
 
 
@@ -99,10 +101,8 @@
          Thread.sleep(30000); // TODO not necesare after we install the client valve
 
 
-         // Transparenty create a consumer and receive the message
+         // receive the message
 
-         MessageConsumer consumer = session.createConsumer(distributedQueue);
-
          message = (TextMessage)consumer.receive(2000);
          log("Received message: " + message.getText());
          assertEquals("Hello!", message.getText());



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 06:14:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 06:14:35 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1836 - in
	trunk/docs/examples/queue-failover: .
	src/org/jboss/example/jms/failover
Message-ID: <E1GwzP9-0001r4-EV@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-20 06:14:32 -0500 (Wed, 20 Dec 2006)
New Revision: 1836

Modified:
   trunk/docs/examples/queue-failover/README.html
   trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
Log:
Improved test



Modified: trunk/docs/examples/queue-failover/README.html
===================================================================
--- trunk/docs/examples/queue-failover/README.html	2006-12-20 11:01:42 UTC (rev 1835)
+++ trunk/docs/examples/queue-failover/README.html	2006-12-20 11:14:32 UTC (rev 1836)
@@ -7,10 +7,13 @@
 </head>
 <body>
 <br>
-<h1>JBoss Messaging Distributed Topic Example</h1>
+<h1>JBoss Messaging Queue Consumer Failover Example</h1>
 $Revision: 1017 $
 <h2>Overview</h2>
 <br>
+
+This example
+
 This example demonstrates how to write JMS code that connects to a
 JBoss Messaging cluster and sends messages to a distributed topic. The
 client code creates two distinct JMS connections to two different

Modified: trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
===================================================================
--- trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 11:01:42 UTC (rev 1835)
+++ trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 11:14:32 UTC (rev 1836)
@@ -79,19 +79,31 @@
 
          connection.start();
 
-         // Send a message to the queue
+         // Send 2 messagea to the queue
 
          Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
          MessageProducer producer = session.createProducer(distributedQueue);
-         TextMessage message = session.createTextMessage("Hello!");
 
-         producer.send(message);
+         TextMessage message1 = session.createTextMessage("Hello1!");
 
+         producer.send(message1);
+
+         TextMessage message2 = session.createTextMessage("Hello2!");
+
+         producer.send(message2);
+
+         log("The messages were successfully sent to the distributed queue");
+
+         // Now receive one of the messages
+
          MessageConsumer consumer = session.createConsumer(distributedQueue);
 
+         TextMessage rm1 = (TextMessage)consumer.receive(2000);
 
-         log("The message was successfully sent to the distributed queue");
+         log("Received message: " + rm1.getText());
 
+         assertEquals("Hello1!", rm1.getText());
 
 
          // Kill the active node
@@ -101,12 +113,14 @@
          Thread.sleep(30000); // TODO not necesare after we install the client valve
 
 
-         // receive the message
+         // receive the second message on the failed over node
 
-         message = (TextMessage)consumer.receive(2000);
-         log("Received message: " + message.getText());
-         assertEquals("Hello!", message.getText());
+         TextMessage rm2 = (TextMessage)consumer.receive(2000);
+         log("Received message: " + rm2.getText());
 
+
+         assertEquals("Hello2!", rm2.getText());
+
          displayProviderInfo(connection.getMetaData());
 
       }



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 06:32:21 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 06:32:21 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1837 -
	trunk/docs/clustering/en/modules
Message-ID: <E1GwzgL-0002Hx-I8@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 06:32:19 -0500 (Wed, 20 Dec 2006)
New Revision: 1837

Modified:
   trunk/docs/clustering/en/modules/about.xml
   trunk/docs/clustering/en/modules/configuration.xml
   trunk/docs/clustering/en/modules/installation.xml
   trunk/docs/clustering/en/modules/introduction.xml
   trunk/docs/clustering/en/modules/overview.xml
Log:
updated clustering documentation

Modified: trunk/docs/clustering/en/modules/about.xml
===================================================================
--- trunk/docs/clustering/en/modules/about.xml	2006-12-20 11:14:32 UTC (rev 1836)
+++ trunk/docs/clustering/en/modules/about.xml	2006-12-20 11:32:19 UTC (rev 1837)
@@ -3,7 +3,7 @@
    <title>JBoss Messaging Clustering Introduction</title>
 
    <para>
-   This guide gives a brief overview of the features available in JBoss Messaging Clustering Alpha 1
+   This guide gives a brief overview of the features available in JBoss Messaging Clustering Beta 1
    </para>
 
    <para>

Modified: trunk/docs/clustering/en/modules/configuration.xml
===================================================================
--- trunk/docs/clustering/en/modules/configuration.xml	2006-12-20 11:14:32 UTC (rev 1836)
+++ trunk/docs/clustering/en/modules/configuration.xml	2006-12-20 11:32:19 UTC (rev 1837)
@@ -3,39 +3,34 @@
    <title>JBoss Messaging Clustering Configuration</title>
 
    <para>
-   This section describes how to configure JBoss Messaging 1.2 Alpha clustering.
+   This section describes how to configure JBoss Messaging 1.2 Beta clustering.
    </para>
 
    <para>
    Please note that the clustering configuration is likely to change before the 1.2 final release.
 
-   In particular we will be adding the ability for JBoss Messaging to use a pre-configured JGroups multiplex channel
-   when used inside JBoss Application Server.
+   In particular we will be adding the ability for JBoss Messaging to use a pre-configured JGroups
+   multiplex channel when used inside JBoss Application Server.
 
    </para>
 
    <section id="config">
 
    <para>
-   JBoss Messaging includes the concept of a "Post Office". Messages are posted at a Post Office and the Post Office routes the message
-   to it's destination queues.
+   JBoss Messaging includes the concept of a "Post Office". Messages are posted at a Post Office and
+   the Post Office routes the message to it's destination queues.
    </para>
 
    <para>
-   In the case of JMS we always have two Post Office
-   instances running.
-
-   The first, the Queue Post Office, routes messages to JMS Queues, and the Topic Post Office routes messages to JMS Topics.
-   </para>
-
-   <para>
-   Internally JBoss Messaging only deals with the concepts of queues, and considers a topic to just be a set of queues (one for
+   Both queues and topics use the same Post Office instance. Internally JBoss Messaging only deals
+   with the concepts of queues, and considers a topic to just be a set of queues (one for
    each subscription).
    </para>
 
    <para>
-   Therefore the Queue Post Office routes a message to one and only one queue, depending on the queue name, whereas a Topic Post Office routes a message
-   to a set of queues (one for each subscription) depending on the topic name.
+   Therefore, for a JMS queue, the Post Office routes messages to one and only one core queue,
+   depending on the queue name, whereas for a JMS topic, the Post Office routes a message
+   to a set of core queues (one for each subscription) depending on the topic name.
    </para>
 
    <para>
@@ -43,25 +38,29 @@
    </para>
 
    <para>
-   Clustered Post Office instances in a cluster connect to each other via JGroups, and when routing messages instead of just routing to local
-   queues as is the case with a non-clustered Post Office, they can also route messages to queues on other Clustered Post Office instances.
+   Clustered Post Office instances in a cluster connect to each other via JGroups, and when
+   routing messages instead of just routing to local queues as is the case with a non-clustered
+   Post Office, they can also route messages to queues on other Clustered Post Office instances.
 
    This allows us to create distributed queues and distributed topics.
    </para>
 
    <para>
-   In the current release of JBoss Messaging 1.2, the JGroups configuration for each Clustered Post Office is specified in the Post Office configuration.
+   In the current release of JBoss Messaging 1.2, the JGroups configuration for each Clustered
+   Post Office is specified in the Post Office configuration.
 
-   The details of the JGroups configuration won't be discussed here since it is standard JGroups configuration.
+   The details of the JGroups configuration won't be discussed here since it is standard
+   JGroups configuration.
 
-   For more information on JGroups configuration please consult http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups
+   For more information on JGroups configuration please consult
+   http://wiki.jboss.org/wiki/Wiki.jsp?page=JGroups
    </para>
 
    <para>An example of a Clustered Post Office configuration is shown below</para>
 
    <programlisting>
    &lt;mbean code="org.jboss.messaging.core.plugin.ClusteredPostOfficeService"
-         name="jboss.messaging:service=QueuePostOffice"
+         name="jboss.messaging:service=PostOffice"
          xmbean-dd="xmdesc/ClusteredPostOffice-xmbean.xml"&gt;
          &lt;depends optional-attribute-name="ServerPeer"&gt;jboss.messaging:service=ServerPeer&lt;/depends&gt;
          &lt;depends&gt;jboss.jca:service=DataSourceBinding,name=DefaultDS&lt;/depends&gt;

Modified: trunk/docs/clustering/en/modules/installation.xml
===================================================================
--- trunk/docs/clustering/en/modules/installation.xml	2006-12-20 11:14:32 UTC (rev 1836)
+++ trunk/docs/clustering/en/modules/installation.xml	2006-12-20 11:32:19 UTC (rev 1837)
@@ -20,7 +20,7 @@
       where:
       <itemizedlist>
          <listitem>
-            <filename>node-id</filename> is an integer that must be unique per cluster.
+            <filename>node-id</filename> is the unique node ID, an integer that must be unique per cluster.
          </listitem>
          <listitem>
             <filename>port-config-label</filename> is a binding manager server configuration label.
@@ -89,7 +89,7 @@
 
    <programlisting>
       04:48:49,663 INFO  [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:name=DefaultDS,service=DataSourceBinding' to JNDI name 'java:DefaultDS'
-      04:48:50,257 INFO  [ServerPeer] JBoss Messaging 1.2.0.Alpha1 server [0] started
+      04:48:50,257 INFO  [ServerPeer] JBoss Messaging 1.2.0.Beta1 server [0] started
       04:48:50,569 INFO  [STDOUT]
       -------------------------------------------------------
       GMS: address is 127.0.0.1:1473

Modified: trunk/docs/clustering/en/modules/introduction.xml
===================================================================
--- trunk/docs/clustering/en/modules/introduction.xml	2006-12-20 11:14:32 UTC (rev 1836)
+++ trunk/docs/clustering/en/modules/introduction.xml	2006-12-20 11:32:19 UTC (rev 1837)
@@ -3,12 +3,13 @@
    <title>Introduction</title>
 
    <para>
-      JBoss Messaging 1.2 GA will provide a highly sophisticated clustering implementation, far more sophisticated than you'll find in the vast
-      majority of other messaging systems.
+      JBoss Messaging 1.2 GA will provide a highly sophisticated clustering implementation, far
+      more sophisticated than you'll find in the vast majority of other messaging systems.
    </para>
    <para>
-      It will allow you to smoothly distribute your application load across your cluster, intelligently balancing and utilising each nodes
-      CPU cycles, with no single point of failure, providing a highly scalable and performant clustering implementation.
+      It will allow you to smoothly distribute your application load across your cluster,
+      intelligently balancing and utilising each nodes CPU cycles, with no single point of failure,
+      providing a highly scalable and performant clustering implementation.
    </para>
 
    <section id="features">
@@ -21,20 +22,23 @@
       <itemizedlist>
          <listitem>
             <para>
-               Distributed queues. Messages sent to a distributed queue while attached to a particular node will be routed
-               to a queue instance on a particular node according to a routing policy
+               Distributed queues. Messages sent to a distributed queue while attached to a
+               particular node will be routed to a queue instance on a particular node according
+               to a routing policy.
             </para>
          </listitem>
          <listitem>
             <para>
-               Distributed topics. Messages sent to a distributed topic while attached at a particular node will be received by subscriptions on other nodes.
+               Distributed topics. Messages sent to a distributed topic while attached at a
+               particular node will be received by subscriptions on other nodes.
             </para>
          </listitem>
          <listitem>
             <para>
                Fully reliable message distribution. Once and only once delivery is fully guaranteed.
                When sending messages to a topic with multiple durable subscriptions
-               across a cluster we guarantee that message reaches all the subscriptions (or none of them in case of failure).
+               across a cluster we guarantee that message reaches all the subscriptions
+               (or none of them in case of failure).
             </para>
          </listitem>
          <listitem>
@@ -77,17 +81,19 @@
    </section>
 
    <section id="alphafeatures">
-      <title>JBoss Messaging 1.2 Alpha 1 features:</title>
+      <title>JBoss Messaging 1.2 Beta 1 features:</title>
 
-      <para> What's in the Alpha 1 release?</para>
+      <para> What's in the Beta 1 release?</para>
 
       <para>
-      JBoss Messaging Alpha 1, is the first experimental release of the JBoss Messaging clustering functionality.
+      JBoss Messaging Beta 1 contains a significant percentage of the functionality planned for the
+         GA release.
       </para>
 
       <para>
-      Please note that this is an Alpha and will contain bugs!
-      We are releasing it to the community, so you can try it out, get familiar with it and feedback your experiences to us so we can improve it and stabilise it.
+      Please note that this is a Beta and will contain bugs!
+      We are releasing it to the community, so you can try it out, get familiar with it
+         and feedback your experiences to us so we can improve it and stabilise it.
       </para>
 
       <para>
@@ -95,42 +101,31 @@
       </para>
 
       <para>
-      This release does not have the full clustering functionality that will be available in 1.2 GA.
-      </para>
-
-      <para>
       All the final features are available apart from:
       </para>
 
       <itemizedlist>
          <listitem>
          <para>
-         High availability. There is no seamless failover in alpha. If you are attached to a particular node and it crashes, then you will not fail over
-         onto another node.
+         Persistent level reliability guarantee without persistence. There is no option for
+            in memory replication of persistent messages in this Beta release.
          </para>
-         <para>
-         There is no HA JNDI support in alpha - when connecting to a particular node you must correct directly to JNDI at the node of interest.
-         </para>
          </listitem>
 
          <listitem>
          <para>
-         Persistent level reliability guarantee without persistence. There is no option for in memory replication of persistent messages in Alpha.
+         Intelligent message distribution is available but disabled in the default configuration
+         because it is currently unstable. Stability should increase in the next Beta release (Beta2).
+         (For intrepid explorers - it is very straightforward to enable this if you wish -
+            see the configuration section - but watch out for unpredictable results.)
          </para>
          </listitem>
 
-         <listitem>
-         <para>
-         Intelligent message distribution is available but disabled in the default configuration because it is currently unstable.
-         Stability should increase over the next few weeks.
-(For intrepid explorers - it is very straightforward to enable this if you wish - see the configuration section - but watch out for unpredictable results.)
-         </para>
-         </listitem>
-
       </itemizedlist>
 
       <para>
-      Bear in mind you will need to get a bit more "down and dirty" with the configuration in this release, than you would with a GA release.
+      Bear in mind you will need to get a bit more "down and dirty" with the configuration in
+         this release, than you would with a GA release.
       </para>
 
    </section>

Modified: trunk/docs/clustering/en/modules/overview.xml
===================================================================
--- trunk/docs/clustering/en/modules/overview.xml	2006-12-20 11:14:32 UTC (rev 1836)
+++ trunk/docs/clustering/en/modules/overview.xml	2006-12-20 11:32:19 UTC (rev 1837)
@@ -14,42 +14,48 @@
       </para>
 
       <para>
-      Clustered destinations (queues and topics) can be deployed at all or none of the nodes of the cluster.
+      Clustered destinations (queues and topics) can be deployed at all or none of the nodes of
+      the cluster.
       </para>
 
       <para>
-      A JMS client uses HA JNDI to lookup the connection factory. A client side load balancing policy will automatically chose a node to connect to (This is similar to
+      A JMS client uses HA JNDI to lookup the connection factory. A client side load balancing
+      policy will automatically chose a node to connect to (This is similar to
       how EJB clustering chooses a node).
       </para>
 
       <para>
-      The JMS client has now made a connection to a node where it can create sessions, message producers and message consumers and browsers and send or consume messages,
+      The JMS client has now made a connection to a node where it can create sessions, message
+      producers and message consumers and browsers and send or consume messages,
       using the standard JMS api.
       </para>
 
       <para>
-      When a distributed queue is deployed across the cluster, individual partial queues are deployed on each node.
+      When a distributed queue is deployed across the cluster, individual partial queues are
+      deployed on each node.
       </para>
 
       <para>
-      When a message is sent from a message producer attached to a particular node to a distributed quueue, a routing policy determines which partial queue will receive
+      When a message is sent from a message producer attached to a particular node to a
+      distributed quueue, a routing policy determines which partial queue will receive
       the message.
       </para>
 
       <para>
-      By default the router will always pass the message to a local queue, if there is one, this is so we avoid unnecessary network traffic.
+      By default the router will always pass the message to a local queue, if there is one,
+      this is so we avoid unnecessary network traffic.
       </para>
 
       <para>
-      If there is no local queue
-      then a partial queue on a different node will be chosen by the router, by default this will be round robin between remote partial queues.
+      If there is no local queue then a partial queue on a different node will be chosen by the
+      router, by default this will be round robin between remote partial queues.
       </para>
 
       <para>
-      When a message is sent to a distributed topic while attached to a node, there may be multiple subscriptions on different nodes that need to receive the
-      message.
-
-      Depending on the number and location of subscriptions, the message may be multicast or unicast across the cluster so the other nodes can pick it up.
+      When a message is sent to a distributed topic while attached to a node, there may be
+      multiple subscriptions on different nodes that need to receive the
+      message. Depending on the number and location of subscriptions, the message may be multicast
+      or unicast across the cluster so the other nodes can pick it up.
       </para>
 
       <para>
@@ -57,8 +63,8 @@
       </para>
 
       <para>
-      In the case of shared durable subscriptions, if a durable subscription with the same name exists on more than node, then only one of the instances needs to
-      receive the message.
+      In the case of shared durable subscriptions, if a durable subscription with the same name
+      exists on more than node, then only one of the instances needs to receive the message.
       </para>
 
       <para>Which one is determined by the same routing policy used to route messages to partial queues.</para>
@@ -93,17 +99,20 @@
       </para>
 
       <para>
-      JBoss Messaging deals with this problem by intelligently pulling messages from other less busy nodes, if it detects idle consumers on the fast node and slow consumers
-      on another node. (Please note that this functionality is currently unstable in the Alpha1 release).
+      JBoss Messaging deals with this problem by intelligently pulling messages from other less
+       busy nodes, if it detects idle consumers on the fast node and slow consumers
+      on another node. (Please note that this functionality is currently unstable in the Beta1
+       release).
       </para>
 
       <para>
-      Another feature (not available in alpha 1) that will enable very fast, very scalable reliable messaging without using databases is in memory replication
-      of reliable messages.
+      Another feature (not available in Beta 1) that will enable very fast, very scalable reliable
+      messaging without using databases is in memory replication of reliable messages.
       </para>
 
       <para>
-      Normally, persistent messages are persisted in a shared database which is shared by all nodes in the cluster.
+      Normally, persistent messages are persisted in a shared database which is shared by all nodes
+      in the cluster.
 
       JBoss Messaging 1.2.GA will contain
       an option where you can choose to not persist persistent messages in a database, but instead to replicate them between nodes of the cluster.



From Shane_Bryzak at symantec.com  Wed Dec 20 06:40:24 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 06:40:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources  ...
Message-ID: <E1Gwzo8-0002Or-Ql@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 06:40:24

  Modified:    examples/seamspace/resources  import.sql
  Log:
  added profile page
  
  Revision  Changes    Path
  1.4       +1 -1      jboss-seam/examples/seamspace/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/import.sql,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- import.sql	20 Dec 2006 03:36:55 -0000	1.3
  +++ import.sql	20 Dec 2006 11:40:23 -0000	1.4
  @@ -1,4 +1,4 @@
  -insert into Member (memberid, username, password) values (1, 'demo', 'demo')
  +insert into Member (memberid, username, password, name) values (1, 'demo', 'demo', 'demo')
   insert into MemberRole (roleid, name) values (1, 'user');
   insert into MemberRole (roleid, name) values (2, 'admin');
   
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 06:40:25 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 06:40:25 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1Gwzo9-0002PA-5J@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 06:40:25

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace     
                        LoginAction.java Member.java
  Added:       examples/seamspace/src/org/jboss/seam/example/seamspace     
                        MemberImage.java ProfileAction.java
                        ProfileLocal.java
  Log:
  added profile page
  
  Revision  Changes    Path
  1.3       +2 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- LoginAction.java	20 Dec 2006 03:36:56 -0000	1.2
  +++ LoginAction.java	20 Dec 2006 11:40:25 -0000	1.3
  @@ -2,6 +2,8 @@
   
   import javax.ejb.Remove;
   import javax.ejb.Stateful;
  +import javax.persistence.EntityManager;
  +import javax.persistence.PersistenceContext;
   
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  
  
  
  1.7       +98 -51    jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Member.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- Member.java	20 Dec 2006 03:36:56 -0000	1.6
  +++ Member.java	20 Dec 2006 11:40:25 -0000	1.7
  @@ -2,12 +2,20 @@
   
   import java.io.Serializable;
   import java.util.Set;
  +
   import javax.persistence.Entity;
  +import javax.persistence.FetchType;
   import javax.persistence.Id;
   import javax.persistence.JoinColumn;
   import javax.persistence.JoinTable;
   import javax.persistence.ManyToMany;
  +import javax.persistence.OneToMany;
  +import javax.persistence.OneToOne;
  +import javax.persistence.Table;
  +import javax.persistence.UniqueConstraint;
   
  +import org.hibernate.validator.Length;
  +import org.hibernate.validator.NotNull;
   import org.jboss.seam.annotations.Name;
   
   /**
  @@ -17,13 +25,16 @@
    */
   @Entity
   @Name("member")
  + at Table(uniqueConstraints = @UniqueConstraint(columnNames = "name"))
   public class Member implements Serializable
   {
     private Integer memberId;
     private String username;
     private String password;
  -
  +   private String name;
  +   private MemberImage picture;
     private Set<MemberRole> roles;
  +   private Set<MemberImage> images;
   
     @Id
     public Integer getMemberId()
  @@ -36,6 +47,8 @@
       this.memberId = memberId;
     }
   
  +   @NotNull
  +   @Length(min = 6, max = 20)
     public String getUsername()
     {
       return username;
  @@ -46,6 +59,8 @@
       this.username = username;
     }
   
  +   @NotNull
  +   @Length(min = 6, max = 20)
     public String getPassword()
     {
       return password;
  @@ -56,10 +71,20 @@
       this.password = password;
     }
   
  +   @NotNull
  +   @Length(min = 3, max = 40)
  +   public String getName()
  +   {
  +      return name;
  +   }
  +
  +   public void setName(String name)
  +   {
  +      this.name = name;
  +   }
  +
     @ManyToMany
  -  @JoinTable(name = "MemberRoles",
  -             joinColumns=@JoinColumn(name="MEMBER_ID"), 
  -		     inverseJoinColumns=@JoinColumn(name="ROLE_ID"))    
  +   @JoinTable(name = "MemberRoles", joinColumns = @JoinColumn(name = "MEMBER_ID"), inverseJoinColumns = @JoinColumn(name = "ROLE_ID"))
     public Set<MemberRole> getRoles()
     {
       return roles;
  @@ -69,4 +94,26 @@
     {
       this.roles = roles;
     }
  +
  +   @OneToOne(fetch = FetchType.LAZY)
  +   public MemberImage getPicture()
  +   {
  +      return picture;
  +   }
  +
  +   public void setPicture(MemberImage picture)
  +   {
  +      this.picture = picture;
  +   }
  +
  +   @OneToMany(mappedBy = "member", fetch = FetchType.LAZY)
  +   public Set<MemberImage> getImages()
  +   {
  +      return images;
  +   }
  +
  +   public void setImages(Set<MemberImage> images)
  +   {
  +      this.images = images;
  +   }
   }
  
  
  
  1.1      date: 2006/12/20 11:40:25;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java
  
  Index: MemberImage.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import java.io.Serializable;
  
  import javax.persistence.Entity;
  import javax.persistence.Id;
  import javax.persistence.ManyToOne;
  
  import org.jboss.seam.annotations.Name;
  
  @Entity
  @Name("memberImage")
  public class MemberImage implements Serializable
  {
     private Integer imageId;
     private Member member;
     private byte[] data;
     private String contentType;
     
     @Id
     public Integer getImageId()
     {
        return imageId;
     }
     
     public void setImageId(Integer imageId)
     {
        this.imageId = imageId;
     }
     
     @ManyToOne
     public Member getMember()
     {
        return member;
     }
     
     public void setMember(Member member)
     {
        this.member = member;
     }
  
     public String getContentType()
     {
        return contentType;
     }
  
     public void setContentType(String contentType)
     {
        this.contentType = contentType;
     }
  
     public byte[] getData()
     {
        return data;
     }
  
     public void setData(byte[] data)
     {
        this.data = data;
     }
  }
  
  
  
  1.1      date: 2006/12/20 11:40:25;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java
  
  Index: ProfileAction.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import javax.ejb.Stateless;
  import javax.persistence.EntityManager;
  import javax.persistence.NoResultException;
  
  import org.jboss.seam.annotations.Factory;
  import org.jboss.seam.annotations.In;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.annotations.Out;
  import org.jboss.seam.annotations.RequestParameter;
  import org.jboss.seam.core.FacesMessages;
  import org.jboss.seam.security.Identity;
  
  @Stateless
  @Name("profile")
  public class ProfileAction implements ProfileLocal
  {
     @RequestParameter
     private String name;
  
     @Out
     private Member selectedMember;
     
     @In(create=true)
     private EntityManager entityManager;
  
     @Factory("selectedMember")
     public void display()
     {
        if (name == null)
        {
           selectedMember = (Member) entityManager.createQuery(
                 "from Member where username = :username")
                 .setParameter("username", Identity.instance().getName())
                 .getSingleResult();
        }
        else
        {
           try
           {
              selectedMember = (Member) entityManager.createQuery(
              "from Member where name = :name")
              .setParameter("name", name)
              .getSingleResult();
           }
           catch (NoResultException ex) 
           {
              FacesMessages.instance().add("The member name you specified does not exist.");
           }   
        }
  }
  
  
  
  1.1      date: 2006/12/20 11:40:25;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileLocal.java
  
  Index: ProfileLocal.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import javax.ejb.Local;
  
  @Local
  public interface ProfileLocal
  {
    void display();
  }
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 06:40:25 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 06:40:25 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view   ...
Message-ID: <E1Gwzo9-0002PK-BY@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 06:40:25

  Modified:    examples/seamspace/view   template.xhtml
  Added:       examples/seamspace/view   profile.xhtml
  Log:
  added profile page
  
  Revision  Changes    Path
  1.4       +7 -7      jboss-seam/examples/seamspace/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/template.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- template.xhtml	20 Dec 2006 03:36:56 -0000	1.3
  +++ template.xhtml	20 Dec 2006 11:40:25 -0000	1.4
  @@ -34,13 +34,13 @@
       </div>
     </div>
     
  -  <!--div id="menubar">
  -    <s:link action="" value="Home"/>|
  -    <s:link action="" value="Browse"/>|
  -    <s:link action="" value="Blog"/>|
  -    <s:link action="" value="Videos"/>|
  -    <s:link action="" value="Music"/>
  -  </div-->
  +  <div id="menubar">
  +    <s:link view="/home.xhtml" value="Home" propagation="none"/>|
  +    <s:link value="Browse"/>|
  +    <s:link value="Blog"/>|
  +    <s:link value="Videos"/>|
  +    <s:link value="Music"/>
  +  </div>
   
     <div id="content">
       <ui:insert name="content"/>
  
  
  
  1.1      date: 2006/12/20 11:40:25;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/view/profile.xhtml
  
  Index: profile.xhtml
  ===================================================================
  <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:s="http://jboss.com/products/seam/taglib">
  
    <ui:composition template="template.xhtml">
      <ui:define name="content">
        <div id="contentMain">
  			  <h1>#{selectedMember.name}'s profile</h1>
  			
  			  <div class="errors"><h:messages globalOnly="true"/></div> 
  			  
  			  
  			  
  			  <s:div rendered="#{s:hasRole('user')}">
  			    You are a member of the 'user' role.
  			  </s:div>
  			  
  			  <s:div rendered="#{s:hasRole('admin')}">
  			    You are a member of the 'admin' role.
  			  </s:div>  
        </div>
      
      </ui:define>
      
    </ui:composition>
  </html>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 06:42:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 06:42:49 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1838 - in trunk/docs/examples:
	distributed-topic queue-failover
Message-ID: <E1GwzqT-0002SM-Ky@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 06:42:48 -0500 (Wed, 20 Dec 2006)
New Revision: 1838

Modified:
   trunk/docs/examples/distributed-topic/README.html
   trunk/docs/examples/queue-failover/README.html
Log:
adjusted the clustered example READMEs

Modified: trunk/docs/examples/distributed-topic/README.html
===================================================================
--- trunk/docs/examples/distributed-topic/README.html	2006-12-20 11:32:19 UTC (rev 1837)
+++ trunk/docs/examples/distributed-topic/README.html	2006-12-20 11:42:48 UTC (rev 1838)
@@ -19,18 +19,6 @@
 successful
 if both subscribers receive a message sent to the topic.<br>
 <br>
-<span style="font-weight: bold;">Note<br>
-</span>
-<div style="margin-left: 40px;">In order to create connections to
-different cluster nodes, the example looks up and downloads
-ConnectionFactories bound in the local JNDI space of each cluster node.
-This is done by explicitely configuring the JNDI client environment to
-point to different physical cluster nodes. This is just a temporary
-solution, used only by the current Alpha release. Subsequent releases
-will use HA-JNDI.<br>
-<span style="font-weight: bold;"></span></div>
-<br>
-<br>
 This example relies on having access to a running JBoss Messaging
 cluster with at least two nodes. The JBoss Messaging cluster must be
 installed and started according to
@@ -124,7 +112,7 @@
 &nbsp;&nbsp;&nbsp;&nbsp; [java] MessageListener 2 received message:
 Hello!<br>
 &nbsp;&nbsp;&nbsp;&nbsp; [java] The example connected to JBoss
-Messaging version 1.2.0.Alpha1 (1.2)<br>
+Messaging version 1.2.0.Beta1 (1.2)<br>
       <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [java] #####################<br>
 &nbsp;&nbsp;&nbsp;&nbsp; [java] ###&nbsp;&nbsp;&nbsp;

Modified: trunk/docs/examples/queue-failover/README.html
===================================================================
--- trunk/docs/examples/queue-failover/README.html	2006-12-20 11:32:19 UTC (rev 1837)
+++ trunk/docs/examples/queue-failover/README.html	2006-12-20 11:42:48 UTC (rev 1838)
@@ -7,33 +7,18 @@
 </head>
 <body>
 <br>
-<h1>JBoss Messaging Queue Consumer Failover Example</h1>
+<h1>JBoss Messaging Queue Failover Example</h1>
 $Revision: 1017 $
 <h2>Overview</h2>
 <br>
-
-This example
-
-This example demonstrates how to write JMS code that connects to a
-JBoss Messaging cluster and sends messages to a distributed topic. The
-client code creates two distinct JMS connections to two different
-cluster nodes. Each connection is then used to create a subscriber for
-the distributed topic. The example is considered
-successful
-if both subscribers receive a message sent to the topic.<br>
+This example demonstrates the transparent failover of a JMS consumer. A
+connection is made on one node of the cluster and two messages are
+sent. A consumer is created and one of the messages is consumed. The
+node the connection is connected to then fails and the connection fails
+over onto the second node. The second message is then consumed using
+the same consumer.<span style="font-weight: bold;"></span>
 <br>
-<span style="font-weight: bold;">Note<br>
-</span>
-<div style="margin-left: 40px;">In order to create connections to
-different cluster nodes, the example looks up and downloads
-ConnectionFactories bound in the local JNDI space of each cluster node.
-This is done by explicitely configuring the JNDI client environment to
-point to different physical cluster nodes. This is just a temporary
-solution, used only by the current Alpha release. Subsequent releases
-will use HA-JNDI.<br>
-<span style="font-weight: bold;"></span></div>
 <br>
-<br>
 This example relies on having access to a running JBoss Messaging
 cluster with at least two nodes. The JBoss Messaging cluster must be
 installed and started according to
@@ -64,7 +49,7 @@
 2. Go to the example's home directory<br>
 <br>
 <div style="margin-left: 40px;"><span style="font-family: monospace;">cd
-...\examples\distributed-topic</span><br>
+...\examples\queue-failover</span><br>
 </div>
 <br>
 3. Run the example:<br>
@@ -88,56 +73,142 @@
 $ ant<br>
 Buildfile: build.xml<br>
       <br>
-identify:<br>
+identify:
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [echo]
-###########################################################################<br>
+###########################################################################
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [echo]
 #&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
-Running the DISTRIBUTED TOPIC
-example&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
-#<br>
+Running the QUEUE FAILOVER example
+&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp;
+&nbsp;&nbsp;&nbsp;&nbsp; #
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [echo]
-###########################################################################<br>
+###########################################################################
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [echo] The
-topic:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; testDistributedTopic<br>
+queue:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; testDistributedQueue
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [echo] The client jar:
-../../../output/lib/jboss-messaging-client.jar<br>
+../../../output/lib/jboss-messaging-client.jar
       <br>
-sanity-check:<br>
       <br>
-init:<br>
-&nbsp;&nbsp;&nbsp; [mkdir] Created dir:
-C:\work\src\svn\messaging\docs\examples\distributed-topic\output<br>
-&nbsp;&nbsp;&nbsp; [mkdir] Created dir:
-C:\work\src\svn\messaging\docs\examples\common\output<br>
+sanity-check:
       <br>
-compile:<br>
-&nbsp;&nbsp;&nbsp; [javac] Compiling 2 source files to
-C:\work\src\svn\messaging\docs\examples\common\output<br>
-&nbsp;&nbsp;&nbsp; [javac] Compiling 2 source files to
-C:\work\src\svn\messaging\docs\examples\distributed-topic\output<br>
       <br>
-run:<br>
-&nbsp;&nbsp;&nbsp;&nbsp; [java] Distributed topic
-/topic/testDistributedTopic exists<br>
-&nbsp;&nbsp;&nbsp;&nbsp; [java] The message was successfully published
-on the distributed topic<br>
-&nbsp;&nbsp;&nbsp;&nbsp; [java] MessageListener 1 received message:
-Hello!<br>
-&nbsp;&nbsp;&nbsp;&nbsp; [java] MessageListener 2 received message:
-Hello!<br>
+init:
+      <br>
+      <br>
+compile:
+      <br>
+      <br>
+jar:
+      <br>
+      <br>
+deploy:
+      <br>
+      <br>
+sleep:
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [echo] Sleeping for 5 seconds ...
+      <br>
+      <br>
+run:
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] Distributed queue
+/queue/testDistributedQueue exists
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] The messages were successfully sent to
+the distributed queue
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] Received message: Hello1!
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] 11:12:22,359 ERROR @Timer-0
+[SocketClientInvoker] Got marshalling exception, exiting
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] java.io.IOException: Connection reset
+by peer: socket write error
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.net.SocketOutputStream.socketWrite0(Native Method)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.net.SocketOutputStream.socketWrite(SocketOutputStream.java:92)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.net.SocketOutputStream.write(SocketOutputStream.java:136)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.io.BufferedOutputStream.flushBuffer(BufferedOutputStream.java:65)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.io.BufferedOutputStream.flush(BufferedOutputStream.java:123)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.io.DataOutputStream.flush(DataOutputStream.java:106)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.serial.io.JBossObjectOutputStream.flush(JBossObjectOutputStream.java:248)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.jms.server.remoting.JMSWireFormat.serialize(JMSWireFormat.java:1035)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.jms.server.remoting.JMSWireFormat.write(JMSWireFormat.java:413)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.remoting.transport.socket.MicroSocketClientInvoker.versionedWrite(MicroSocketClientInvoker.java:518)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.remoting.transport.socket.MicroSocketClientInvoker.transport(MicroSocketClientInvoker.java:340)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.remoting.MicroRemoteClientInvoker.invoke(MicroRemoteClientInvoker.java:125)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.remoting.ConnectionValidator.checkConnection(ConnectionValidator.java:184)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+org.jboss.remoting.ConnectionValidator.run(ConnectionValidator.java:114)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.util.TimerThread.mainLoop(Timer.java:512)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java]&nbsp;&nbsp;&nbsp;&nbsp; at
+java.util.TimerThread.run(Timer.java:462)
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] 11:12:24,406 INFO&nbsp; @Thread-3
+[HAAspect] HAAspect.ClusteredClientConnectionFactoryDelegate[1]
+completed client-side failover
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] Received message: Hello2!
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [java] The example connected to JBoss
-Messaging version 1.2.0.Alpha1 (1.2)<br>
+Messaging version 1.2.0.Beta1 (1.2)
       <br>
-&nbsp;&nbsp;&nbsp;&nbsp; [java] #####################<br>
+      <br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] #####################
+      <br>
 &nbsp;&nbsp;&nbsp;&nbsp; [java] ###&nbsp;&nbsp;&nbsp;
-SUCCESS!&nbsp;&nbsp; ###<br>
-&nbsp;&nbsp;&nbsp;&nbsp; [java] #####################<br>
+SUCCESS!&nbsp;&nbsp; ###
       <br>
-BUILD SUCCESSFUL<br>
-Total time: 4 seconds<br>
+&nbsp;&nbsp;&nbsp;&nbsp; [java] #####################
       <br>
       <br>
+undeploy:
+      <br>
+&nbsp;&nbsp; [delete] Deleting:
+C:\dev\jboss-4.0.5.GA\server\messaging-node0\deploy\application-server-killer.jar
+      <br>
+      <br>
+BUILD SUCCESSFUL
+      <br>
+Total time: 41 seconds
+      <br>
+      <br>
+      <br>
+      <br>
       </td>
     </tr>
   </tbody>



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 06:50:28 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 06:50:28 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1839 -
	trunk/docs/clustering/en/modules
Message-ID: <E1Gwzxs-0002aX-PW@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-20 06:50:26 -0500 (Wed, 20 Dec 2006)
New Revision: 1839

Modified:
   trunk/docs/clustering/en/modules/introduction.xml
   trunk/docs/clustering/en/modules/overview.xml
Log:
Few minor changes



Modified: trunk/docs/clustering/en/modules/introduction.xml
===================================================================
--- trunk/docs/clustering/en/modules/introduction.xml	2006-12-20 11:42:48 UTC (rev 1838)
+++ trunk/docs/clustering/en/modules/introduction.xml	2006-12-20 11:50:26 UTC (rev 1839)
@@ -112,15 +112,6 @@
          </para>
          </listitem>
 
-         <listitem>
-         <para>
-         Intelligent message distribution is available but disabled in the default configuration
-         because it is currently unstable. Stability should increase in the next Beta release (Beta2).
-         (For intrepid explorers - it is very straightforward to enable this if you wish -
-            see the configuration section - but watch out for unpredictable results.)
-         </para>
-         </listitem>
-
       </itemizedlist>
 
       <para>

Modified: trunk/docs/clustering/en/modules/overview.xml
===================================================================
--- trunk/docs/clustering/en/modules/overview.xml	2006-12-20 11:42:48 UTC (rev 1838)
+++ trunk/docs/clustering/en/modules/overview.xml	2006-12-20 11:50:26 UTC (rev 1839)
@@ -101,8 +101,7 @@
       <para>
       JBoss Messaging deals with this problem by intelligently pulling messages from other less
        busy nodes, if it detects idle consumers on the fast node and slow consumers
-      on another node. (Please note that this functionality is currently unstable in the Beta1
-       release).
+      on another node.
       </para>
 
       <para>



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 06:56:39 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 06:56:39 -0500
Subject: [jboss-cvs] JBossAS SVN: r59176 - in projects/microcontainer/trunk:
	container/src/main/org/jboss/beans/info/plugins
	container/src/main/org/jboss/joinpoint/plugins
	kernel/src/main/org/jboss/beans/metadata/plugins
	kernel/src/main/org/jboss/beans/metadata/spi
	kernel/src/main/org/jboss/kernel/plugins/config
	kernel/src/main/org/jboss/kernel/plugins/config/xml
	kernel/src/main/org/jboss/kernel/plugins/deployment/xml
	kernel/src/main/org/jboss/kernel/spi/config
	kernel/src/resources/org/jboss/test/javabean/test
	kernel/src/resources/schema
	kernel/src/tests/org/jboss/test/javabean/support
	kernel/src/tests/org/jboss/test/javabean/test
Message-ID: <E1Gx03r-0002iR-Dh@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-20 06:56:02 -0500 (Wed, 20 Dec 2006)
New Revision: 59176

Added:
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityInt.xml
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityString.xml
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/support/AmbiguityBean.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AmbiguityTestCase.java
Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/spi/PropertyMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/xml/JavaBeanSchemaInitializer.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/config/KernelConfigurator.java
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestConfigure.xml
   projects/microcontainer/trunk/kernel/src/resources/schema/javabean_1_0.xsd
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestSuite.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java
Log:
JBMICROCONT-125; added property type check, using classloader

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/beans/info/plugins/AbstractBeanInfoFactory.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -298,10 +298,8 @@
             Map.Entry<String, List<MethodInfo>> entry = i.next();
             String name = entry.getKey();
             List<MethodInfo> setterList = entry.getValue();
-            // TODO JBMICROCONT-125 Maybe should just create duplicate propertyInfo and let the configurator guess?
-            if (setterList.size() == 1)
+            for(MethodInfo setter : setterList)
             {
-               MethodInfo setter = setterList.get(0);
                TypeInfo pinfo = setter.getParameterTypes()[0];
                String lowerName = getLowerPropertyName(name);
                AnnotationValue[] annotations = setter.getAnnotations();

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/joinpoint/plugins/Config.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -373,10 +373,9 @@
     */
    public static boolean equals(String[] typeNames, TypeInfo[] typeInfos)
    {
-      if (typeNames == null || typeInfos == null)
+      if (simpleCheck(typeNames, typeInfos) == false)
          return false;
-      if (typeNames.length != typeInfos.length)
-         return false;
+
       for (int i = 0; i < typeNames.length; ++i)
       {
          if (typeNames[i] != null && typeNames[i].equals(typeInfos[i].getName()) == false)
@@ -384,4 +383,21 @@
       }
       return true;
    }
+
+   /**
+    * A simple null and length check.
+    *
+    * @param typeNames
+    * @param typeInfos
+    * @return false if either argument is null or lengths differ, else true
+    */
+   protected static boolean simpleCheck(String[] typeNames, TypeInfo[] typeInfos)
+   {
+      if (typeNames == null || typeInfos == null)
+      {
+         return false;
+      }
+      return typeNames.length == typeInfos.length;
+   }
+
 }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -121,6 +121,15 @@
       flushJBossObjectCache();
    }
 
+   public String getType()
+   {
+      if (value instanceof AbstractTypeMetaData)
+      {
+         return ((AbstractTypeMetaData)value).getType();
+      }
+      return null;
+   }
+
    public ValueMetaData getValue()
    {
       return value;

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/spi/PropertyMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/spi/PropertyMetaData.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/spi/PropertyMetaData.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -35,8 +35,15 @@
     * @return the name.
     */
    String getName();
-   
+
    /**
+    * Get property type if possible.
+    *
+    * @return class type if set, otherwise null
+    */
+   String getType();
+
+   /**
     * Get the value.
     * 
     * @return the value.

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -300,7 +300,7 @@
     */
    public static void configure(boolean trace, Object object, BeanInfo info, ClassLoader cl, PropertyMetaData metaData) throws Throwable
    {
-      PropertyInfo ainfo = resolveProperty(trace, info, metaData.getName());
+      PropertyInfo ainfo = resolveProperty(trace, info, cl, metaData.getName(), metaData.getType());
       configure(trace, object, ainfo, cl, metaData);
    }
 
@@ -440,7 +440,7 @@
     */
    public static TargettedJoinpoint getPropertySetterJoinPoint(boolean trace, BeanInfo info, ClassLoader cl, PropertyMetaData metaData) throws Throwable
    {
-      PropertyInfo ainfo = resolveProperty(trace, info, metaData.getName());
+      PropertyInfo ainfo = resolveProperty(trace, info, cl, metaData.getName(), metaData.getType());
       return getPropertySetterJoinPoint(trace, ainfo, cl, metaData.getValue());
    }
 
@@ -523,13 +523,14 @@
       if (metaData == null)
          throw new IllegalArgumentException("Null bean metadata");
 
+      ClassLoader cl = getClassLoader(metaData);
       Set propertys = metaData.getProperties();
       if (propertys != null && propertys.isEmpty() == false)
       {
          for (Iterator i = metaData.getProperties().iterator(); i.hasNext();)
          {
             PropertyMetaData property = (PropertyMetaData) i.next();
-            unconfigure(object, info, property);
+            unconfigure(object, cl, info, property);
          }
       }
    }
@@ -542,10 +543,10 @@
     * @param metaData the property metadata
     * @throws Throwable for any error
     */
-   public static void unconfigure(Object object, BeanInfo info, PropertyMetaData metaData) throws Throwable
+   public static void unconfigure(Object object, ClassLoader cl, BeanInfo info, PropertyMetaData metaData) throws Throwable
    {
       boolean trace = log.isTraceEnabled();
-      PropertyInfo ainfo = resolveProperty(trace, info, metaData.getName());
+      PropertyInfo ainfo = resolveProperty(trace, info, cl, metaData.getName(), metaData.getType());
       unconfigure(trace, object, ainfo, metaData);
    }
 
@@ -586,7 +587,8 @@
          throw new IllegalArgumentException("Null bean info");
       if (metaData == null)
          throw new IllegalArgumentException("Null bean metadata");
-      
+
+      ClassLoader cl = getClassLoader(metaData);
       Set<TargettedJoinpoint> result = new HashSet<TargettedJoinpoint>();
       Set<PropertyMetaData> propertys = metaData.getProperties();
       if (propertys != null && propertys.isEmpty() == false)
@@ -608,11 +610,26 @@
     * @param metaData the property metadata
     * @return the join point
     * @throws Throwable for any error
+    * @deprecated must use ClassLoader when determinig PropertyInfo
     */
    public static TargettedJoinpoint getPropertyNullerJoinPoint(BeanInfo info, PropertyMetaData metaData) throws Throwable
    {
+      return getPropertyNullerJoinPoint(null, info, metaData);
+   }
+
+   /**
+    * Get property nuller joinpoint for a property
+    *
+    * @param cl the bean classloader
+    * @param info the bean info
+    * @param metaData the property metadata
+    * @return the join point
+    * @throws Throwable for any error
+    */
+   public static TargettedJoinpoint getPropertyNullerJoinPoint(ClassLoader cl, BeanInfo info, PropertyMetaData metaData) throws Throwable
+   {
       boolean trace = log.isTraceEnabled();
-      PropertyInfo ainfo = resolveProperty(trace, info, metaData.getName());
+      PropertyInfo ainfo = resolveProperty(trace, info, cl, metaData.getName(), metaData.getType());
       return getPropertyNullerJoinPoint(ainfo, metaData);
    }
 
@@ -650,11 +667,29 @@
     */
    public static PropertyInfo resolveProperty(boolean trace, BeanInfo info, String name) throws Throwable
    {
+      return resolveProperty(trace, info, null, name, null);
+   }
+
+   /**
+    * Get the property info
+    *
+    * @param trace whether trace is enabled
+    * @param info the bean info
+    * @param name the property name
+    * @param type the property type
+    * @return the property info
+    * @throws Throwable for any error
+    */
+   public static PropertyInfo resolveProperty(boolean trace, BeanInfo info, ClassLoader cl, String name, String type) throws Throwable
+   {
       if (info == null)
          throw new IllegalArgumentException("Null bean info");
       if (name == null)
          throw new IllegalArgumentException("Null name");
-      
+
+      if (trace)
+         log.trace("Resolving property on bean info=" + info + " name=" + name);
+
       Set properties = info.getProperties();
       if (properties != null && properties.size() > 0)
       {
@@ -662,7 +697,14 @@
          {
             PropertyInfo ainfo = (PropertyInfo) i.next();
             if (name.equals(ainfo.getName()))
-               return ainfo;
+            {
+               String[] typeNames = {type};
+               TypeInfo[] typeInfos = {ainfo.getType()};
+               if (equals(typeNames, typeInfos) || assignable(cl, typeNames, typeInfos) || progression(cl, typeNames, typeInfos))
+               {
+                  return ainfo;
+               }
+            }
          }
       }
       
@@ -834,8 +876,59 @@
          cl = tcl;
       return cl;
    }
-   
+
    /**
+    * Test whether type names can be assigned to type infos
+    *
+    * @param cl bean classloader
+    * @param typeNames the type names
+    * @param typeInfos the type infos
+    * @return true when they can be assigned
+    */
+   public static boolean assignable(ClassLoader cl, String[] typeNames, TypeInfo[] typeInfos) throws Throwable
+   {
+      if (cl == null)
+         return false;
+
+      if (simpleCheck(typeNames, typeInfos) == false)
+         return false;
+
+      for (int i = 0; i < typeNames.length; ++i)
+      {
+         if (typeNames[i] != null)
+         {
+            // todo - is there some better way to do this - via Container?
+            Class clazz = Class.forName(typeNames[i], true, cl);
+            if (typeInfos[i].getType().isAssignableFrom(clazz) == false)
+            {
+               return false;
+            }
+         }
+      }
+      return true;
+   }
+
+   /**
+    * Test whether type names can progress to type infos
+    *
+    * @param cl bean classloader
+    * @param typeNames the type names
+    * @param typeInfos the type infos
+    * @return true when we can use progression
+    */
+   public static boolean progression(ClassLoader cl, String[] typeNames, TypeInfo[] typeInfos)
+   {
+      if (cl == null)
+         return false;
+
+      if (simpleCheck(typeNames, typeInfos) == false)
+         return false;
+
+      // JBMICROCONT-119: todo - write this + actual progression code at value injection
+      return false;
+   }
+
+   /**
     * ValueJoinpoint.
     */
    private static class ValueJoinpoint implements Joinpoint

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/xml/JavaBeanSchemaInitializer.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/xml/JavaBeanSchemaInitializer.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/xml/JavaBeanSchemaInitializer.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -21,14 +21,11 @@
 */
 package org.jboss.kernel.plugins.config.xml;
 
+import javax.xml.namespace.NamespaceContext;
+import javax.xml.namespace.QName;
 import java.security.AccessController;
 import java.security.PrivilegedExceptionAction;
-import java.util.Iterator;
-import java.util.Set;
 
-import javax.xml.namespace.NamespaceContext;
-import javax.xml.namespace.QName;
-
 import org.jboss.beans.info.spi.BeanInfo;
 import org.jboss.beans.info.spi.PropertyInfo;
 import org.jboss.kernel.plugins.config.Configurator;
@@ -39,12 +36,7 @@
 import org.jboss.reflect.spi.TypeInfo;
 import org.jboss.reflect.spi.TypeInfoFactory;
 import org.jboss.util.propertyeditor.PropertyEditors;
-import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementHandler;
-import org.jboss.xb.binding.sunday.unmarshalling.DefaultElementInterceptor;
-import org.jboss.xb.binding.sunday.unmarshalling.ElementBinding;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBinding;
-import org.jboss.xb.binding.sunday.unmarshalling.SchemaBindingInitializer;
-import org.jboss.xb.binding.sunday.unmarshalling.TypeBinding;
+import org.jboss.xb.binding.sunday.unmarshalling.*;
 import org.xml.sax.Attributes;
 
 /**
@@ -164,7 +156,7 @@
             Object value = prop.getValue();
             try
             {
-               PropertyInfo info = getProperty(parentValue, property);
+               PropertyInfo info = getProperty(parentValue, property, prop.getType());
                value = convertValue(info, prop.getType(), value);
                method = info.getSetter();
                method.invoke(parentValue, new Object[] { value });
@@ -211,24 +203,11 @@
       return schema;
    }
    
-   private PropertyInfo getProperty(Object parent, String property) throws Throwable
+   private PropertyInfo getProperty(Object parent, String property, String type) throws Throwable
    {
       BeanInfo beanInfo = config.getBeanInfo(parent.getClass());
-      Set properties = beanInfo.getProperties();
-      if (properties != null && properties.size() > 0)
-      {
-         for (Iterator i = properties.iterator(); i.hasNext();)
-         {
-            PropertyInfo prop = (PropertyInfo) i.next();
-            if (prop.getName().equals(property))
-            {
-               if (prop.getSetter() == null)
-                  throw new IllegalArgumentException("Property '" + property + "' is read only " + prop);
-               return prop;
-            }
-         }
-      }
-      throw new IllegalArgumentException("No property '" + property + "' for " + beanInfo);
+      ClassLoader cl = Thread.currentThread().getContextClassLoader();
+      return Configurator.resolveProperty(false, beanInfo, cl, property, type);
    }
 
    /**

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropHandler.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -31,8 +31,7 @@
 /**
  * PropertyHandler.
  *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 43026 $
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
  */
 public class PropHandler extends DefaultElementHandler
 {

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/deployment/xml/PropertiesHandler.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -30,8 +30,7 @@
 /**
  * PropertyHandler.
  *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 43026 $
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
  */
 public class PropertiesHandler extends DefaultElementHandler
 {

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/config/KernelConfigurator.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/config/KernelConfigurator.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/config/KernelConfigurator.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -205,6 +205,7 @@
     * @param metaData the property metadata
     * @return the join point
     * @throws Throwable for any error
+    * @deprecated must use ClassLoader when determining PropertyInfo
     */
    TargettedJoinpoint getPropertyNullerJoinPoint(BeanInfo info, PropertyMetaData metaData) throws Throwable;
 

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityInt.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityInt.xml	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityInt.xml	2006-12-20 11:56:02 UTC (rev 59176)
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<javabean xmlns="urn:jboss:javabean:1.0" class="org.jboss.test.javabean.support.AmbiguityBean">
+   <property name="something" class="java.lang.Integer">123</property>
+</javabean>

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityString.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityString.xml	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestAmbiguityString.xml	2006-12-20 11:56:02 UTC (rev 59176)
@@ -0,0 +1,5 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<javabean xmlns="urn:jboss:javabean:1.0" class="org.jboss.test.javabean.support.AmbiguityBean">
+   <property name="something" class="java.lang.String">SomeString</property>
+</javabean>

Modified: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestConfigure.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestConfigure.xml	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/javabean/test/TestConfigure.xml	2006-12-20 11:56:02 UTC (rev 59176)
@@ -9,7 +9,8 @@
    <property name="ALong">12345</property>
    <property name="AFloat">3.14</property>
    <property name="ADouble">3.14e12</property>
-   <property name="ADate">Mon Jan 01 00:00:00 CET 2001</property>
+   <!--<property name="ADate">Mon Jan 01 00:00:00 CET 2001</property>-->
+   <property name="ADate">Jan 01 00:00:00 CET 2001</property>
    <property name="ABigDecimal">12e4</property>
    <property name="ABigInteger">123456</property>
    <property name="abyte">12</property>

Modified: projects/microcontainer/trunk/kernel/src/resources/schema/javabean_1_0.xsd
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/schema/javabean_1_0.xsd	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/resources/schema/javabean_1_0.xsd	2006-12-20 11:56:02 UTC (rev 59176)
@@ -14,7 +14,7 @@
          <![CDATA[
          A schema for constructing javabeans.
 
-         <javabean xmlns="urn:jboss:bean-deployer:2.0"
+         <javabean xmlns="urn:jboss:javabean:1.0"
                    class="com.acme.MyJavaBean">
             <property name="someProperty">SomeValue</property>
          ...

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/support/AmbiguityBean.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/support/AmbiguityBean.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/support/AmbiguityBean.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.javabean.support;
+
+/**
+ * SimpleBean.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 46093 $
+ */
+public class AmbiguityBean
+{
+   private Integer someint;
+   private String somestring;
+
+   public void setSomething(Integer integer)
+   {
+      someint = integer;
+   }
+
+   public void setSomething(String string)
+   {
+      somestring = string;
+   }
+
+   public Object something()
+   {
+      if (someint != null && somestring != null)
+         throw new IllegalArgumentException("Only one 'something' can be set!");
+      if (someint != null)
+         return someint;
+      if (somestring != null)
+         return somestring;
+      throw new IllegalArgumentException("Must set 'something'!");
+   }
+
+   public String toString()
+   {
+      return someint + "," + somestring;
+   }
+
+}

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AmbiguityTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AmbiguityTestCase.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/AmbiguityTestCase.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -0,0 +1,69 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.javabean.test;
+
+import junit.framework.Test;
+import org.jboss.test.javabean.support.AmbiguityBean;
+
+/**
+ * PropertyTestCase.
+ *
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 58996 $
+ */
+public class AmbiguityTestCase extends AbstractJavaBeanTest
+{
+   /**
+    * Create a new AmbiguityTestCase.
+    *
+    * @param name the test name
+    */
+   public AmbiguityTestCase(String name)
+   {
+      super(name);
+   }
+
+   /**
+    * Setup the test
+    *
+    * @return the test
+    */
+   public static Test suite()
+   {
+      return suite(AmbiguityTestCase.class);
+   }
+
+   public void testConfigureInt() throws Exception
+   {
+      AmbiguityBean ab = unmarshal("TestAmbiguityInt.xml", AmbiguityBean.class);
+      Object something = ab.something();
+      assertEquals(something.getClass(), Integer.class);
+   }
+
+   public void testConfigureString() throws Exception
+   {
+      AmbiguityBean ab = unmarshal("TestAmbiguityString.xml", AmbiguityBean.class);
+      Object something = ab.something();
+      assertEquals(something.getClass(), String.class);
+   }
+
+}

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestSuite.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestSuite.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/JavaBeanTestSuite.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -44,7 +44,8 @@
 
       suite.addTest(InstantiateTestCase.suite());
       suite.addTest(PropertyTestCase.suite());
-      
+      suite.addTest(AmbiguityTestCase.suite());
+
       return suite;
    }
 }

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java	2006-12-20 05:03:08 UTC (rev 59175)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java	2006-12-20 11:56:02 UTC (rev 59176)
@@ -44,8 +44,10 @@
  */
 public class PropertyTestCase extends AbstractJavaBeanTest
 {
-   private static DateFormat dateFormat = new SimpleDateFormat("EEE MMM d HH:mm:ss z yyyy");
-   
+//   private static DateFormat dateFormat = new SimpleDateFormat("EEE MMM d HH:mm:ss z yyyy");
+   // even example from API doesn't work for me (alesj) - with EEE
+   private static DateFormat dateFormat = new SimpleDateFormat("MMM d HH:mm:ss z yyyy");
+
    String stringValue =  "StringValue";
    Byte byteValue = new Byte("12");
    Boolean booleanValue = Boolean.TRUE;
@@ -56,12 +58,16 @@
    Long longValue = new Long("12345");
    Float floatValue = new Float("3.14");
    Double doubleValue = new Double("3.14e12");
-   Date dateValue = createDate("Mon Jan 01 00:00:00 CET 2001");
+//   Date dateValue = createDate("Mon Jan 01 00:00:00 CET 2001");
+   Date dateValue = createDate("Jan 01 00:00:00 CET 2001");
    BigDecimal bigDecimalValue = new BigDecimal("12e4");
    BigInteger bigIntegerValue = new BigInteger("123456");
 
    public void testConfigure() throws Exception
    {
+      // tmp format
+      System.setProperty("org.jboss.util.propertyeditor.DateEditor.format", "MMM d HH:mm:ss z yyyy");
+      // check bean
       SimpleBean bean = unmarshal("TestConfigure.xml", SimpleBean.class);
       assertEquals("()", bean.getConstructorUsed());
       



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 07:10:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 07:10:41 -0500
Subject: [jboss-cvs] JBossAS SVN: r59177 -
	projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins
Message-ID: <E1Gx0HR-00037t-F7@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-20 07:10:36 -0500 (Wed, 20 Dec 2006)
New Revision: 59177

Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java
Log:
JBMICROCONT-125; added property type check, using classloader

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java	2006-12-20 11:56:02 UTC (rev 59176)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractPropertyMetaData.java	2006-12-20 12:10:36 UTC (rev 59177)
@@ -31,6 +31,8 @@
 import org.jboss.beans.metadata.spi.ValueMetaData;
 import org.jboss.dependency.spi.ControllerState;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.kernel.spi.config.KernelConfigurator;
+import org.jboss.kernel.plugins.config.Configurator;
 import org.jboss.util.JBossStringBuilder;
 
 /**
@@ -160,6 +162,15 @@
 
    public Class getType(MetaDataVisitor visitor, MetaDataVisitorNode previous) throws Throwable
    {
+      String type = getType();
+      if (type != null)
+      {
+         KernelControllerContext context = visitor.getControllerContext();
+         ClassLoader cl = Configurator.getClassLoader(context.getBeanMetaData());
+         KernelConfigurator configurator = context.getKernel().getConfigurator();
+         return configurator.getClassInfo(type, cl).getType();
+      }
+      // check properties
       KernelControllerContext context = visitor.getControllerContext();
       Set propertyInfos = context.getBeanInfo().getProperties();
       if (propertyInfos != null)



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 07:18:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 07:18:18 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1840 - trunk/docs
Message-ID: <E1Gx0Oo-0003Fo-PC@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 07:18:17 -0500 (Wed, 20 Dec 2006)
New Revision: 1840

Modified:
   trunk/docs/README.html
Log:
release notes for 1.2.0.Beta1

Modified: trunk/docs/README.html
===================================================================
--- trunk/docs/README.html	2006-12-20 11:50:26 UTC (rev 1839)
+++ trunk/docs/README.html	2006-12-20 12:18:17 UTC (rev 1840)
@@ -7,15 +7,16 @@
 </head>
 <body>
 <h1><br>
-JBoss Messaging 1.2.0.Alpha2 Release Notes</h1>
+JBoss Messaging 1.2.0.Beta1 Release Notes</h1>
 <br>
-1st November 2006<br>
+December 20 2006<br>
 <br>
 <br>
 JBoss
 Messaging is a new JBoss JMS 1.1-compliant JMS provider, aimed to
-replace JBossMQ.&nbsp; The curent release is the first public release
-that includes clustering features. An brief overview of the clustering
+replace JBossMQ.&nbsp; The curent release is the first Beta release. It
+includes the majority of the clustering features to be available in
+1.2.0.GA. An brief overview of the clustering
 features and installation instructions are available in the "Clustering
 Guide". The guide is bundled with this release and is
 provided in <a href="./docs/clustering/html/index.html">HTML</a>, <a
@@ -27,55 +28,44 @@
 <span style="font-weight: bold;">Warning<br>
 </span>
 <div style="margin-left: 40px;">The current JBoss Messaging
-distribution is a <span style="font-style: italic;">preview </span><span
- style="font-style: italic;">alpha </span><span
- style="font-style: italic;">release. </span>We strongly advise
+distribution is a <span style="font-style: italic;">preview beta</span><span
+ style="font-style: italic;"> </span><span style="font-style: italic;">release.
+</span>We strongly advise
 against using it in a production environment.<br>
 </div>
 <h2>Release Notes<br>
 </h2>
-
-<h2>Bug</h2>
-<ul>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-552'>JBMESSAGING-552</a>] - MessageConsumerTest.testRedeliveryToCompetingConsumerOnSubscription() fails on race condition</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-587'>JBMESSAGING-587</a>] - Fix perf/build.xml</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-589'>JBMESSAGING-589</a>] - DefaultClusteredPostOfficeTest::testClusteredNameUniqueness is failing</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-595'>JBMESSAGING-595</a>] - Rebind of clustered durable subscription fails</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-596'>JBMESSAGING-596</a>] - BrowserTest should close its Connection in tearDown()</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-606'>JBMESSAGING-606</a>] - Issue with cancel when paging</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-617'>JBMESSAGING-617</a>] - Stress tests do not run</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-618'>JBMESSAGING-618</a>] - Failure in stress tests</li>
+<h2 style="margin-left: 40px;">Bug</h2>
+<ul style="margin-left: 40px;">
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-613">JBMESSAGING-613</a>]
+- DelegateSupport::trace shouldn't be serialized</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-667">JBMESSAGING-667</a>]
+- Clustered ConnectionFactory binding mechanism broken for a
+single-node cluster (and possibly for multi-node cluster)</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-685">JBMESSAGING-685</a>]
+- session.commit on an empty transaction causes NPE</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-686">JBMESSAGING-686</a>]
+- Inconsistence between DelegateSupport and States</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-687">JBMESSAGING-687</a>]
+- Fix clone on HAAspect::performClientSideFailover</li>
 </ul>
-
-<h2>Feature Request</h2>
-<ul>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-583'>JBMESSAGING-583</a>] - Add an integer check for release-admin.xml's -Did=...</li>
+<h2 style="margin-left: 40px;">Task</h2>
+<ul style="margin-left: 40px;">
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-207">JBMESSAGING-207</a>]
+- HTTP invoker configuration and testing</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-516">JBMESSAGING-516</a>]
+- Clustering</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-615">JBMESSAGING-615</a>]
+- Add sufficient tracing for a customer environment</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-631">JBMESSAGING-631</a>]
+- Update the build script to produce an unscoped SAR</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-632">JBMESSAGING-632</a>]
+- Migreate the deployment descriptors and the AS-related artifacts to
+the AS repository</li>
+  <li>[<a href="http://jira.jboss.com/jira/browse/JBMESSAGING-673">JBMESSAGING-673</a>]
+- Extend test suite framework to restart remote servers</li>
 </ul>
-
-<h2>Patch</h2>
-<ul>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-625'>JBMESSAGING-625</a>] - ClassCastException String to ManagedDestination</li>
-</ul>
-
-<h2>Task</h2>
-<ul>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-289'>JBMESSAGING-289</a>] - Make service container configurable wrt datasource and persistence manager config</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-568'>JBMESSAGING-568</a>] - Complete the configuration section in the Alpha clustering guide</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-571'>JBMESSAGING-571</a>] - Get unicast to work with clustering</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-573'>JBMESSAGING-573</a>] - Add clustering crash and recovery tests to suite</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-575'>JBMESSAGING-575</a>] - Stabilise the default message pull policy</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-577'>JBMESSAGING-577</a>] - Handle sequence numbers properly for state transfer...</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-579'>JBMESSAGING-579</a>] - Improve shared durable subscription tests</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-581'>JBMESSAGING-581</a>] - ServerManagement needs to be extended to start cluster node instances</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-591'>JBMESSAGING-591</a>] - MessageConsumerTest::testTimeoutReceiveOnClose can randomly fail</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-597'>JBMESSAGING-597</a>] - Tracker task for JBSHOTOKU-101 (blogs dont show up in our Labs project blog area)</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-601'>JBMESSAGING-601</a>] - Place Messaging artifacts in the repository</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-610'>JBMESSAGING-610</a>] - Merge 1.0.1.GA changes (Branch_1_0) into the trunk</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-614'>JBMESSAGING-614</a>] - Remove shutdown logger</li>
-<li>[<a href='http://jira.jboss.com/jira/browse/JBMESSAGING-621'>JBMESSAGING-621</a>] - Modify the smoke test suite to run tests in top of JBoss 4.0.5.GA instead of 4.0.5.CR1</li>
-</ul>
-
-
-
+<br>
+<hr style="width: 100%; height: 2px;">
 </body>
 </html>



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 07:19:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 07:19:55 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1841 - tags
Message-ID: <E1Gx0QN-0003G7-MH@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 07:19:54 -0500 (Wed, 20 Dec 2006)
New Revision: 1841

Added:
   tags/JBossMessaging_1_2_0_Beta1/
Log:
tagging 1.2.0.Beta1

Copied: tags/JBossMessaging_1_2_0_Beta1 (from rev 1840, trunk)



From msurtani at jboss.com  Wed Dec 20 08:16:27 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:16:27 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1Gx1J5-0004Js-PV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:16:27

  Modified:    tests/functional/org/jboss/cache/marshall 
                        RedeploymentEmulationTest.java
  Log:
  Should help with CC runs now...
  
  Revision  Changes    Path
  1.3       +20 -16    JBossCache/tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RedeploymentEmulationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- RedeploymentEmulationTest.java	1 Dec 2006 15:29:54 -0000	1.2
  +++ RedeploymentEmulationTest.java	20 Dec 2006 13:16:27 -0000	1.3
  @@ -7,17 +7,16 @@
   package org.jboss.cache.marshall;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.Cache;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
  -import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jgroups.Global;
   
  -import java.net.URLClassLoader;
  -import java.net.URL;
   import java.io.File;
  +import java.net.URL;
  +import java.net.URLClassLoader;
   
   /**
    * Unit test demonstrating usability of marshalling for application redeployment in application server.
  @@ -30,8 +29,8 @@
   
      private static final String INSTANCE_LIBRARY = "jgroups.jar";
      private static final String INSTANCE_CLASS_NAME = "org.jgroups.Global";
  -   private static final String USER_DIR = System.getProperty("user.dir");
  -   private static final String FILE_SEPARATOR = System.getProperty("file.separator");
  +   private static final String USER_DIR = ".";//System.getProperty("user.dir");
  +   private static final String FILE_SEPARATOR = File.separator;//System.getProperty("file.separator");
      private static final String LIB_DIR = "lib";
   
      protected void setUp() throws Exception
  @@ -44,13 +43,18 @@
         cache.getConfiguration().setUseRegionBasedMarshalling(true);
      }
   
  +   protected void tearDown()
  +   {
  +      cache.stop();
  +   }
  +
      public void testClassCastException() throws Exception
      {
         cache.start();
   
         File f = new File(USER_DIR + FILE_SEPARATOR + LIB_DIR + FILE_SEPARATOR);
         URL context = f.toURL();
  -      URL jar= new URL(context, INSTANCE_LIBRARY);
  +      URL jar = new URL(context, INSTANCE_LIBRARY);
         URLClassLoader ucl1 = new URLClassLoader(new URL[]{jar}, null);
         Thread.currentThread().setContextClassLoader(ucl1);
         
  @@ -60,10 +64,10 @@
         Thread.currentThread().setContextClassLoader(ClassLoader.getSystemClassLoader());
         try
         {
  -         Global object = (Global)cache.get(fqn("/a"), "key");
  +         Global object = (Global) cache.get(fqn("/a"), "key");
            fail("Should have produced a ClassCastException");
         }
  -      catch(ClassCastException cce)
  +      catch (ClassCastException cce)
         {
            assertTrue(cce.getMessage().equals(INSTANCE_CLASS_NAME));
         }
  @@ -75,7 +79,7 @@
   
         File f = new File(USER_DIR + FILE_SEPARATOR + LIB_DIR + FILE_SEPARATOR);
         URL context = f.toURL();
  -      URL jar= new URL(context, INSTANCE_LIBRARY);
  +      URL jar = new URL(context, INSTANCE_LIBRARY);
         URLClassLoader ucl1 = new URLClassLoader(new URL[]{jar}, null);
         Thread.currentThread().setContextClassLoader(ucl1);
   
  @@ -95,10 +99,10 @@
         
         try
         {
  -         Global object = (Global)cache.get(fqn("/a"), "key");
  +         Global object = (Global) cache.get(fqn("/a"), "key");
            assertNull(object);
         }
  -      catch(ClassCastException cce)
  +      catch (ClassCastException cce)
         {
            fail("Should not have produced a ClassCastException");
         }
  
  
  


From ovidiu.feodorov at jboss.com  Wed Dec 20 08:20:13 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 20 Dec 2006 08:20:13 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.2.0.Beta1 - New
	directory ...
Message-ID: <E1Gx1Mj-0004OB-Vc@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/20 08:20:13

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/messaging/1.2.0.Beta1 added to the repository


From ovidiu.feodorov at jboss.com  Wed Dec 20 08:20:34 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 20 Dec 2006 08:20:34 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.2.0.Beta1/lib -
	New directory ...
Message-ID: <E1Gx1N4-0004PH-9a@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/20 08:20:34

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/messaging/1.2.0.Beta1/lib added to the repository


From ovidiu.feodorov at jboss.com  Wed Dec 20 08:28:09 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 20 Dec 2006 08:28:09 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.2.0.Beta1  ...
Message-ID: <E1Gx1UP-0004XF-At@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/20 08:28:09

  Added:       jboss/messaging/1.2.0.Beta1  component-info.xml
  Log:
  added JBoss Messaging 1.2.0.Beta1
  
  Revision  Changes    Path
  1.1      date: 2006/12/20 13:28:09;  author: ovidiu;  state: Exp;repository.jboss.com/jboss/messaging/1.2.0.Beta1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss/messaging-component-info">
  
     <component id="jboss/messaging"
                version="1.2.0.Beta1"
                licenseType="lgpl"
                projectHome="http://www.jboss.org/products/messaging"
                description="The JBoss JMS provider">
  
        <artifact id="jboss-messaging.jar"/>
  
        <import componentref="jboss/serialization">
               <compatible version="1.0.2.GA"/>
               <compatible version="1.0.3.GA"/>
        </import>
  
        <import componentref="jboss/remoting">
               <compatible version="2.2.0.Alpha4"/>
        </import>
  
        <import componentref="jboss/aop">
               <compatible version="1.5.0.GA"/>
        </import>
  
        <import componentref="jgroups">
               <compatible version="2.4"/>
        </import>
  
        <export>
           <include input="jboss-messaging.jar"/>
        </export>
  
     </component>
  
  </project>
  
  
  


From ovidiu.feodorov at jboss.com  Wed Dec 20 08:28:09 2006
From: ovidiu.feodorov at jboss.com (Ovidiu Feodorov)
Date: Wed, 20 Dec 2006 08:28:09 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/messaging/1.2.0.Beta1/lib ...
Message-ID: <E1Gx1UP-0004XL-Fv@committer01.frg.pub.inap.atl.jboss.com>

  User: ovidiu  
  Date: 06/12/20 08:28:09

  Added:       jboss/messaging/1.2.0.Beta1/lib  jboss-messaging.jar
  Log:
  added JBoss Messaging 1.2.0.Beta1
  
  Revision  Changes    Path
  1.1      date: 2006/12/20 13:28:09;  author: ovidiu;  state: Exp;repository.jboss.com/jboss/messaging/1.2.0.Beta1/lib/jboss-messaging.jar
  
  	<<Binary file>>
  
  


From msurtani at jboss.com  Wed Dec 20 08:29:16 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:29:16 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1Gx1VU-0004XY-3T@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:29:16

  Modified:    tests/functional/org/jboss/cache/optimistic 
                        RemoveBeforeCreateTest.java
  Log:
  added async sleep
  
  Revision  Changes    Path
  1.3       +2 -0      JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveBeforeCreateTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- RemoveBeforeCreateTest.java	6 Dec 2006 16:28:36 -0000	1.2
  +++ RemoveBeforeCreateTest.java	20 Dec 2006 13:29:16 -0000	1.3
  @@ -47,6 +47,7 @@
         t.begin();
         c[0].put("/control", "key", "value");
         t.commit();
  +      TestingUtil.sleepThread(200);
   
         assertEquals("value", c[0].get("/control", "key"));
         assertEquals("value", c[1].get("/control", "key"));
  @@ -71,6 +72,7 @@
   
         // should NOT barf!!!
         t.commit();
  +      TestingUtil.sleepThread(200);
   
         assertNull(c[0].get(f));
         assertNull(c[1].get(f));
  
  
  


From msurtani at jboss.com  Wed Dec 20 08:34:28 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:34:28 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1Gx1aW-0004bQ-GA@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:34:28

  Modified:    tests/functional/org/jboss/cache/passivation   
                        ConcurrentPassivationTest.java
                        BasicPassivationTest.java
                        LocalPassivationIntegrationTest.java
  Log:
  Added sufficient clean ups to unit tests
  
  Revision  Changes    Path
  1.6       +4 -29     JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ConcurrentPassivationTest.java	14 Nov 2006 14:17:11 -0000	1.5
  +++ ConcurrentPassivationTest.java	20 Dec 2006 13:34:28 -0000	1.6
  @@ -13,14 +13,13 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
  -
  -import java.io.File;
  +import org.jboss.cache.misc.TestingUtil;
   
   /**
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class ConcurrentPassivationTest extends TestCase
   {
  @@ -44,7 +43,7 @@
   
      void initCaches() throws Exception
      {
  -      removeStaleFiles();
  +      TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader");
         cache_ = new TreeCache();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -54,35 +53,11 @@
      public void tearDown() throws Exception
      {
         super.tearDown();
  -      removeStaleFiles();
  +      TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader");
         cache_.stop();
         cache_ = null;
      }
   
  -   private void removeStaleFiles()
  -   {
  -      File file = new File("/tmp/JBossCacheFileCacheLoader");
  -      if (file.exists())
  -      {
  -         System.out.println("Deleting file " + file);
  -         recursivedelete(file);
  -      }
  -   }
  -
  -   private void recursivedelete(File f)
  -   {
  -      if (f.isDirectory())
  -      {
  -         File[] files = f.listFiles();
  -         for (int i = 0; i < files.length; i++)
  -         {
  -            recursivedelete(files[i]);
  -         }
  -      }
  -      //System.out.println("File " + f.toURI() + " deleted = " + f.delete());
  -      f.delete();
  -   }
  -
      public void testConcurrentPassivation() throws Exception
      {
         Fqn base = Fqn.fromString("/org/jboss/test/data/concurrent/passivation");
  
  
  
  1.12      +5 -4      JBossCache/tests/functional/org/jboss/cache/passivation/BasicPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BasicPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/BasicPassivationTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- BasicPassivationTest.java	14 Nov 2006 14:17:11 -0000	1.11
  +++ BasicPassivationTest.java	20 Dec 2006 13:34:28 -0000	1.12
  @@ -19,7 +19,7 @@
   
   /**
    * @author Ben Wang
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class BasicPassivationTest extends TestCase
   {
  @@ -41,6 +41,7 @@
      public void setUp() throws Exception
      {
         super.setUp();
  +      TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader"); // clean up any stale files left around by previous unit tests
         initCaches();
         wakeupIntervalMillis_ = cache_.getConfiguration().getEvictionConfig().getWakeupIntervalSeconds() * 1000;
         log("wakeupInterval is " + wakeupIntervalMillis_);
  
  
  
  1.11      +2 -1      JBossCache/tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalPassivationIntegrationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- LocalPassivationIntegrationTest.java	14 Nov 2006 14:17:11 -0000	1.10
  +++ LocalPassivationIntegrationTest.java	20 Dec 2006 13:34:28 -0000	1.11
  @@ -37,6 +37,7 @@
      public void setUp() throws Exception
      {
         super.setUp();
  +      TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader"); // clean up any stale files left around by previous unit tests
         cache_ = new TreeCache();
         initCaches(cache_);
         cache_.getConfiguration().setUseRegionBasedMarshalling(true);
  @@ -118,7 +119,7 @@
         {
            if (pre)
            {
  -            System.out.println("nodePassivate(): " +fqn);
  +            System.out.println("nodePassivate(): " + fqn);
            }
         }
   
  
  
  


From msurtani at jboss.com  Wed Dec 20 08:34:28 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:34:28 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/misc  ...
Message-ID: <E1Gx1aW-0004bX-Jc@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:34:28

  Modified:    tests/functional/org/jboss/cache/misc  TestingUtil.java
  Log:
  Added sufficient clean ups to unit tests
  
  Revision  Changes    Path
  1.10      +25 -0     JBossCache/tests/functional/org/jboss/cache/misc/TestingUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestingUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/misc/TestingUtil.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- TestingUtil.java	12 Sep 2006 17:12:03 -0000	1.9
  +++ TestingUtil.java	20 Dec 2006 13:34:28 -0000	1.10
  @@ -11,6 +11,7 @@
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.TreeCache;
   
  +import java.io.File;
   import java.util.List;
   import java.util.Random;
   
  @@ -272,4 +273,28 @@
      {
         sleepThread(random.nextInt(maxTime));
      }
  +
  +   public static void recursiveFileRemove(String directoryName)
  +   {
  +      File file = new File(directoryName);
  +      if (file.exists())
  +      {
  +         System.out.println("Deleting file " + file);
  +         recursivedelete(file);
  +      }
  +   }
  +
  +   private static void recursivedelete(File f)
  +   {
  +      if (f.isDirectory())
  +      {
  +         File[] files = f.listFiles();
  +         for (File file : files)
  +         {
  +            recursivedelete(file);
  +         }
  +      }
  +      //System.out.println("File " + f.toURI() + " deleted = " + f.delete());
  +      f.delete();
  +   }
   }
  
  
  


From msurtani at jboss.com  Wed Dec 20 08:34:28 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:34:28 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1Gx1aW-0004be-Oa@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:34:28

  Modified:    tests/functional/org/jboss/cache/eviction 
                        ConcurrentEvictionTest.java
  Log:
  Added sufficient clean ups to unit tests
  
  Revision  Changes    Path
  1.5       +4 -29     JBossCache/tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentEvictionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ConcurrentEvictionTest.java	14 Nov 2006 14:17:10 -0000	1.4
  +++ ConcurrentEvictionTest.java	20 Dec 2006 13:34:28 -0000	1.5
  @@ -13,14 +13,13 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
  -
  -import java.io.File;
  +import org.jboss.cache.misc.TestingUtil;
   
   /**
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class ConcurrentEvictionTest extends TestCase
   {
  @@ -44,7 +43,7 @@
   
      void initCaches() throws Exception
      {
  -      removeStaleFiles();
  +      TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader");
         cache_ = new TreeCache();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-eviction-cacheloader-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -54,35 +53,11 @@
      public void tearDown() throws Exception
      {
         super.tearDown();
  -      removeStaleFiles();
  +      TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader");
         cache_.stop();
         cache_ = null;
      }
   
  -   private void removeStaleFiles()
  -   {
  -      File file = new File("/tmp/JBossCacheFileCacheLoader");
  -      if (file.exists())
  -      {
  -         System.out.println("Deleting file " + file);
  -         recursivedelete(file);
  -      }
  -   }
  -
  -   private void recursivedelete(File f)
  -   {
  -      if (f.isDirectory())
  -      {
  -         File[] files = f.listFiles();
  -         for (int i = 0; i < files.length; i++)
  -         {
  -            recursivedelete(files[i]);
  -         }
  -      }
  -      //System.out.println("File " + f.toURI() + " deleted = " + f.delete());
  -      f.delete();
  -   }
  -
      public void testConcurrentEviction() throws Exception
      {
         Fqn base = Fqn.fromString("/org/jboss/test/data/concurrent/eviction");
  
  
  


From msurtani at jboss.com  Wed Dec 20 08:40:24 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:40:24 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader  ...
Message-ID: <E1Gx1gG-0004jZ-BX@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:40:24

  Modified:    tests/functional/org/jboss/cache/loader 
                        TcpCacheLoaderTest.java
  Log:
  added time for tcp cache server to start up
  
  Revision  Changes    Path
  1.12      +4 -2      JBossCache/tests/functional/org/jboss/cache/loader/TcpCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/TcpCacheLoaderTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- TcpCacheLoaderTest.java	25 Oct 2006 14:42:27 -0000	1.11
  +++ TcpCacheLoaderTest.java	20 Dec 2006 13:40:24 -0000	1.12
  @@ -9,7 +9,7 @@
    * Tests the TcpDelegatingCacheLoader
    *
    * @author Bela Ban
  - * @version $Id: TcpCacheLoaderTest.java,v 1.11 2006/10/25 14:42:27 msurtani Exp $
  + * @version $Id: TcpCacheLoaderTest.java,v 1.12 2006/12/20 13:40:24 msurtani Exp $
    */
   public class TcpCacheLoaderTest extends CacheLoaderTestsBase
   {
  @@ -51,7 +51,6 @@
         });
   
         runner.start();
  -      TestingUtil.sleepThread(500);
      }
   
      public void testPartialLoadAndStore()
  @@ -70,6 +69,9 @@
         cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("",
                 "org.jboss.cache.loader.TcpDelegatingCacheLoader",
                 "host=127.0.0.1\nport=12121", false, true, false));
  +
  +      // give the tcp cache server time to start up
  +      TestingUtil.sleepThread(2000);
      }
   
   
  
  
  


From msurtani at jboss.com  Wed Dec 20 08:56:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:56:49 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1Gx1w9-0004xD-EX@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:56:49

  Modified:    src/org/jboss/cache/optimistic  WorkspaceNodeImpl.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.32      +6 -1      JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- WorkspaceNodeImpl.java	14 Dec 2006 17:18:48 -0000	1.31
  +++ WorkspaceNodeImpl.java	20 Dec 2006 13:56:49 -0000	1.32
  @@ -64,6 +64,11 @@
         this.node = node;
         this.workspace = workspace;
         optimisticDataMap = new HashMap(node.getNodeSPI().getRawData());
  +      //log.fatal("Children map is " + node.getNodeSPI().getChildrenMap());
  +      Map childrenMap = node.getNodeSPI().getChildrenMap();
  +      if (childrenMap == null)
  +         optimisticChildNodeMap = new ConcurrentHashMap();
  +      else
         optimisticChildNodeMap = new ConcurrentHashMap(node.getNodeSPI().getChildrenMap());
         this.version = ((OptimisticTreeNode) node).getVersion();
         if (version == null)
  
  
  


From msurtani at jboss.com  Wed Dec 20 08:56:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 08:56:49 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache  ...
Message-ID: <E1Gx1w9-0004xK-KZ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 08:56:49

  Modified:    tests/stress/org/jboss/cache  LocalStressTest.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.8       +34 -35    JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- LocalStressTest.java	6 Sep 2006 15:31:02 -0000	1.7
  +++ LocalStressTest.java	20 Dec 2006 13:56:49 -0000	1.8
  @@ -15,6 +15,7 @@
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.LockStrategyFactory;
  +import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
  @@ -26,6 +27,7 @@
   import javax.transaction.SystemException;
   import javax.transaction.UserTransaction;
   import java.util.ArrayList;
  +import java.util.List;
   import java.util.Properties;
   import java.util.Random;
   
  @@ -36,7 +38,7 @@
    * Local mode stress test for TreeCache.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   public class LocalStressTest extends TestCase
   {
  @@ -46,7 +48,7 @@
      //   final static Log log_=LogFactory.getLog(LocalStressTestCase.class);
      String oldFactory_ = null;
      final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
  -   static ArrayList nodeList_;
  +   static List<String> nodeList_;
      static final int depth_ = 4;
      static final int children_ = 4;
      DummyTransactionManager tm_;
  @@ -141,6 +143,13 @@
         UserTransaction tx = null;
         tx = (UserTransaction) new InitialContext(p_).lookup("UserTransaction");
   
  +      // create "root" nodes to remove WL contention on /
  +      cache_.put("/", null);
  +      cache_.put("/0", null);
  +      cache_.put("/1", null);
  +      cache_.put("/2", null);
  +      cache_.put("/3", null);
  +
         RunThread t1 = new RunThread(tx, 1);
         RunThread t2 = new RunThread(tx, 2);
   
  @@ -184,13 +193,13 @@
         {
            for (int loop = 0; loop < MAX_LOOP; loop++)
            {
  -            sleep_(random_.nextInt(50));
  +            TestingUtil.sleepRandom(50);
               log("Executing op1. Loop-" + loop);
               op1();
  -            sleep_(random_.nextInt(50));
  +            TestingUtil.sleepRandom(50);
               log("Executing op2...");
               op2();
  -            sleep_(random_.nextInt(50));
  +            TestingUtil.sleepRandom(50);
               log("Executing op3...");
               op3();
            }
  @@ -202,15 +211,17 @@
         {
            int i = random_.nextInt(nodeList_.size() - 1);
            String key = Integer.toString(i);
  -         String value = Integer.toString(i);
   
            tx_.begin();
  -         String node = (String) nodeList_.get(i);
  +         String node = nodeList_.get(i);
            cache_.get(node, key);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  -         cache_.put(node, key, value);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  -         cache_.remove(node, key);
  +         TestingUtil.sleepRandom(SLEEP_TIME);
  +
  +         // uncommenting these leads to a classic deadlock.
  +
  +//         cache_.put(node, key, value);
  +//         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +//         cache_.remove(node, key);
            tx_.commit();
         }
   
  @@ -222,11 +233,11 @@
            String key = Integer.toString(i);
   
            tx_.begin();
  -         String node = (String) nodeList_.get(i);
  +         String node = nodeList_.get(i);
            cache_.get(node, key);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +         TestingUtil.sleepRandom(SLEEP_TIME);
            cache_.get(node, key);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +         TestingUtil.sleepRandom(SLEEP_TIME);
            tx_.commit();
         }
   
  @@ -239,23 +250,12 @@
            String value = Integer.toString(i);
   
            tx_.begin();
  -         String node = (String) nodeList_.get(i);
  +         String node = nodeList_.get(i);
            cache_.put(node, key, value);
  -         sleep_(random_.nextInt(SLEEP_TIME)); // sleep for max 200 millis
  +         TestingUtil.sleepRandom(SLEEP_TIME);
            cache_.remove(node, key);
            tx_.commit();
         }
  -
  -      private void sleep_(long msecs)
  -      {
  -         try
  -         {
  -            Thread.sleep(msecs);
  -         }
  -         catch (Exception ex)
  -         {
  -         }
  -      }
      }
   
      /**
  @@ -263,11 +263,11 @@
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  -   private ArrayList nodeGen(int depth, int children)
  +   private List<String> nodeGen(int depth, int children)
      {
  -      ArrayList strList = new ArrayList();
  -      ArrayList oldList = new ArrayList();
  -      ArrayList newList = new ArrayList();
  +      List<String> strList = new ArrayList<String>();
  +      List<String> oldList = new ArrayList<String>();
  +      List<String> newList = new ArrayList<String>();
   
         oldList.add("/");
         newList.add("/");
  @@ -276,12 +276,12 @@
         while (depth > 0)
         {
            // Trying to produce node name at this depth.
  -         newList = new ArrayList();
  -         for (int i = 0; i < oldList.size(); i++)
  +         newList = new ArrayList<String>();
  +         for (String anOldList : oldList)
            {
               for (int j = 0; j < children; j++)
               {
  -               String tmp = (String) oldList.get(i);
  +               String tmp = anOldList;
                  tmp += Integer.toString(j);
                  if (depth != 1)
                     tmp += "/";
  @@ -305,7 +305,6 @@
      private static void log(String str)
      {
         System.out.println("Thread: " + Thread.currentThread() + ": " + str);
  -//        System.out.println(str);
      }
   
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 08:58:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 08:58:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r59178 -
	projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test
Message-ID: <E1Gx1xz-0004zz-0f@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-20 08:58:40 -0500 (Wed, 20 Dec 2006)
New Revision: 59178

Modified:
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java
Log:
fixed comment

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java	2006-12-20 12:10:36 UTC (rev 59177)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/javabean/test/PropertyTestCase.java	2006-12-20 13:58:40 UTC (rev 59178)
@@ -38,21 +38,21 @@
 
 /**
  * PropertyTestCase.
- * 
+ *
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
 public class PropertyTestCase extends AbstractJavaBeanTest
 {
 //   private static DateFormat dateFormat = new SimpleDateFormat("EEE MMM d HH:mm:ss z yyyy");
-   // even example from API doesn't work for me (alesj) - with EEE
+   // EEE names - Locale configured
    private static DateFormat dateFormat = new SimpleDateFormat("MMM d HH:mm:ss z yyyy");
 
    String stringValue =  "StringValue";
    Byte byteValue = new Byte("12");
    Boolean booleanValue = Boolean.TRUE;
    // TODO character
-   // Character characterValue = new Character('a'); 
+   // Character characterValue = new Character('a');
    Short shortValue = new Short("123");
    Integer integerValue = new Integer("1234");
    Long longValue = new Long("12345");
@@ -70,11 +70,11 @@
       // check bean
       SimpleBean bean = unmarshal("TestConfigure.xml", SimpleBean.class);
       assertEquals("()", bean.getConstructorUsed());
-      
+
       assertEquals(stringValue, bean.getAString());
       assertEquals(byteValue, bean.getAByte());
       assertEquals(booleanValue, bean.getABoolean());
-      // TODO character 
+      // TODO character
       // assertEquals(characterValue, bean.getACharacter());
       assertEquals(shortValue, bean.getAShort());
       assertEquals(integerValue, bean.getAnInt());
@@ -87,7 +87,7 @@
       assertEquals(byteValue.byteValue(), bean.getAbyte());
       assertEquals(booleanValue.booleanValue(), bean.isAboolean());
       // TODO character
-      // assertEquals(characterValue.charValue(), bean.getAchar()); 
+      // assertEquals(characterValue.charValue(), bean.getAchar());
       assertEquals(shortValue.shortValue(), bean.getAshort());
       assertEquals(integerValue.intValue(), bean.getAnint());
       assertEquals(longValue.longValue(), bean.getAlong());



From msurtani at jboss.com  Wed Dec 20 11:04:02 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Wed, 20 Dec 2006 11:04:02 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache   ...
Message-ID: <E1Gx3vG-0007nL-OV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/20 11:04:02

  Modified:    src/org/jboss/cache   TreeCache.java NodeImpl.java
  Log:
  fixed getChildren()
  
  Revision  Changes    Path
  1.297     +6 -6      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.296
  retrieving revision 1.297
  diff -u -b -r1.296 -r1.297
  --- TreeCache.java	20 Dec 2006 09:07:15 -0000	1.296
  +++ TreeCache.java	20 Dec 2006 16:04:02 -0000	1.297
  @@ -95,7 +95,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.296 2006/12/20 09:07:15 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.297 2006/12/20 16:04:02 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1842,19 +1842,19 @@
       */
      public int getNumberOfLocksHeld()
      {
  -      return numLocks(root.getNodeSPI());
  +      return numLocks(root);
      }
   
  -   private int numLocks(NodeSPI n)
  +   private int numLocks(Node n)
      {
         int num = 0;
  -      if (n.getLock().isLocked())
  +      if (n.getNodeSPI().getLock().isLocked())
         {
            num++;
         }
  -      for (Node cn : n.getChildrenMap().values())
  +      for (Node cn : ((NodeImpl) n).getChildren(true))
         {
  -         num += numLocks(cn.getNodeSPI());
  +         num += numLocks(cn);
         }
         return num;
      }
  
  
  
  1.27      +17 -1     JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- NodeImpl.java	15 Dec 2006 17:30:32 -0000	1.26
  +++ NodeImpl.java	20 Dec 2006 16:04:02 -0000	1.27
  @@ -785,7 +785,21 @@
   
      public Set<Node> getChildren()
      {
  -      return new ChildrenNodes<Node>(false);
  +      //return new ChildrenNodes<Node>(false);
  +      // strip out deleted child nodes...
  +      if (children == null || children.size() == 0) return new HashSet<Node>();
  +
  +      Set<Node> exclDeleted = new HashSet<Node>();
  +      for (AbstractNode n : children.values())
  +      {
  +         if (!n.isDeleted()) exclDeleted.add(n);
  +      }
  +      return exclDeleted;
  +   }
  +
  +   public Set<Node> getChildren(boolean includeMarkedForRemoval)
  +   {
  +      return includeMarkedForRemoval ? new HashSet<Node>(children.values()) : getChildren();
      }
   
      public synchronized Map<Object, Object> getRawData()
  @@ -904,6 +918,7 @@
   
      }
   
  +   /*
      private class ChildrenNodes<T> extends AbstractSet
      {
         private boolean includeDeleted;
  @@ -947,5 +962,6 @@
         }
   
      }
  +   */
   
   }
  
  
  


From gavin.king at jboss.com  Wed Dec 20 11:50:14 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 20 Dec 2006 11:50:14 -0500
Subject: [jboss-cvs] jboss-seam/examples/drools/resources/WEB-INF  ...
Message-ID: <E1Gx4dy-00005j-Bz@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/20 11:50:14

  Modified:    examples/drools/resources/WEB-INF  components.xml
  Log:
  schema
  
  Revision  Changes    Path
  1.7       +6 -1      jboss-seam/examples/drools/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/drools/resources/WEB-INF/components.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- components.xml	10 Dec 2006 16:01:58 -0000	1.6
  +++ components.xml	20 Dec 2006 16:50:14 -0000	1.7
  @@ -1,6 +1,11 @@
   <components xmlns="http://jboss.com/products/seam/components" 
               xmlns:core="http://jboss.com/products/seam/core"
  -            xmlns:drools="http://jboss.com/products/seam/drools">
  +            xmlns:drools="http://jboss.com/products/seam/drools"
  +            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  +            xsi:schemaLocation=
  +                "http://jboss.com/products/seam/drools http://jboss.com/products/seam/drools-1.1.xsd 
  +                 http://jboss.com/products/seam/core http://jboss.com/products/seam/core-1.1.xsd 
  +                 http://jboss.com/products/seam/components http://jboss.com/products/seam/components-1.1.xsd">
               
       <drools:rule-base name="ruleBase" rule-files="numberguess.drl"/>
       <drools:managed-working-memory name="workingMemory" rule-base="#{ruleBase}"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 11:59:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 11:59:33 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59179 - branches
Message-ID: <E1Gx4mz-0000Cy-07@committer01.frg.pub.inap.atl.jboss.com>

Author: alex.pinkin at jboss.com
Date: 2006-12-20 11:59:31 -0500 (Wed, 20 Dec 2006)
New Revision: 59179

Added:
   branches/JBoss_4_0_5_GA_CP/
Log:
4.0.5.GA CP branch

Copied: branches/JBoss_4_0_5_GA_CP (from rev 59178, tags/JBoss_4_0_5_GA)



From gavin.king at jboss.com  Wed Dec 20 12:01:53 2006
From: gavin.king at jboss.com (Gavin King)
Date: Wed, 20 Dec 2006 12:01:53 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1Gx4pF-0000H9-LK@committer01.frg.pub.inap.atl.jboss.com>

  User: gavin   
  Date: 06/12/20 12:01:53

  Modified:    src/main/org/jboss/seam/core  Interpolator.java
  Log:
  JBSEAM-624
  
  Revision  Changes    Path
  1.14      +13 -11    jboss-seam/src/main/org/jboss/seam/core/Interpolator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Interpolator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Interpolator.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- Interpolator.java	16 Dec 2006 02:58:10 -0000	1.13
  +++ Interpolator.java	20 Dec 2006 17:01:53 -0000	1.14
  @@ -49,19 +49,21 @@
       * @return the interpolated string
       */
      public String interpolate(String string, Object... params) {
  +      if ( params!=null && params.length>0 )
  +      {
         if ( params.length>10 ) 
         {
            throw new IllegalArgumentException("more than 10 parameters");
         }
  -      
         if ( string.indexOf('#')>=0 )
         {
            string = interpolateExpressions(string, params);
         }
  -      if ( params.length>1 && string.indexOf('{')>=0 )
  +         if ( string.indexOf('{')>=0 )
         {
            string = new MessageFormat(string, Locale.instance()).format(params);
         }
  +      }
         return string;
      }
   
  
  
  


From scott.stark at jboss.com  Wed Dec 20 12:53:34 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Wed, 20 Dec 2006 12:53:34 -0500
Subject: [jboss-cvs]
	repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA ...
Message-ID: <E1Gx5dG-0001IW-Aw@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/20 12:53:34

  Added:       maven2/jboss/jboss-common-core/2.0.3.GA 
                        jboss-common-core-2.0.3.GA.pom
  Log:
  Add the missing pom
  
  Revision  Changes    Path
  1.1      date: 2006/12/20 17:53:34;  author: starksm;  state: Exp;repository.jboss.com/maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.pom
  
  Index: jboss-common-core-2.0.3.GA.pom
  ===================================================================
  <?xml version="1.0"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>jboss</groupId>
    <artifactId>jboss-common-core</artifactId>
    <name>JBoss Common Classes</name>
    <version>2.0.3.GA</version>
    <description>A set of commonly used classed classes</description>
    <url>http://www.jboss.org</url>
    <licenses>
      <license>
        <name>lgpl</name>
        <url>http://repository.jboss.com/licenses/lgpl.txt</url>
      </license>
    </licenses>
    <organization>
      <name>JBoss Inc.</name>
      <url>http://www.jboss.org</url>
    </organization>
    <build>
      <sourceDirectory>src/main/java</sourceDirectory>
      <finalName>${artifactId}</finalName>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.0</version>
          <configuration>
            <optimize>true</optimize>
            <source>1.4</source>
            <target>1.4</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <executions>
            <execution>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
          <inherited>true</inherited>
        </plugin>
      </plugins>
    </build>
    <repositories>
      <repository>
        <snapshots />
        <id>jboss</id>
        <name>JBoss Inc. Repository</name>
        <url>http://repository.jboss.com/maven2/</url>
      </repository>
    </repositories>
    <pluginRepositories>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>jbosspluginrepo</id>
        <name>jboss plugin repository</name>
        <url>http://repository.jboss.com/maven2</url>
      </pluginRepository>
      <pluginRepository>
        <snapshots>
          <enabled>false</enabled>
          <updatePolicy>never</updatePolicy>
        </snapshots>
        <id>central</id>
        <url>http://mirrors.ibiblio.org/pub/mirrors/maven2</url>
      </pluginRepository>
    </pluginRepositories>
    <dependencies>
      <dependency>
        <groupId>apache-xerces</groupId>
        <artifactId>xml-apis</artifactId>
        <version>2.7.1</version>
      </dependency>
      <dependency>
        <groupId>apache-httpclient</groupId>
        <artifactId>commons-httpclient</artifactId>
        <version>2.0.2</version>
      </dependency>
      <dependency>
        <groupId>oswego-concurrent</groupId>
        <artifactId>concurrent</artifactId>
        <version>1.3.4</version>
      </dependency>
      <dependency>
        <groupId>apache-slide</groupId>
        <artifactId>webdavlib</artifactId>
        <version>2.0</version>
      </dependency>
      <dependency>
        <groupId>jboss</groupId>
        <artifactId>jboss-logging-spi</artifactId>
        <version>2.0.3.GA</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>3.8.1</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
    <distributionManagement>
      <repository>
        <id>cvs-file-repository</id>
        <url>file://${maven.cvs.root}</url>
      </repository>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 13:50:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 13:50:49 -0500
Subject: [jboss-cvs] JBossAS SVN: r59180 -
	projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context
Message-ID: <E1Gx6Wf-0002Nv-Hl@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-20 13:50:48 -0500 (Wed, 20 Dec 2006)
New Revision: 59180

Modified:
   projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractURLHandler.java
Log:
initializeCacheLastModified was not called.

Modified: projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractURLHandler.java
===================================================================
--- projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractURLHandler.java	2006-12-20 16:59:31 UTC (rev 59179)
+++ projects/vfs/trunk/src/main/java/org/jboss/virtual/plugins/context/AbstractURLHandler.java	2006-12-20 18:50:48 UTC (rev 59180)
@@ -62,6 +62,7 @@
       if (url == null)
          throw new IllegalArgumentException("Null url");
       this.url = url;
+      initCacheLastModified();
    }
 
    protected void initCacheLastModified()



From validimir.ralev at jboss.com  Wed Dec 20 14:41:25 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Wed, 20 Dec 2006 14:41:25 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin ...
Message-ID: <E1Gx7Jd-0003Oj-6K@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/20 14:41:25

  Modified:    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin 
                        ejb3.deployer
  Log:
  replaceing with the original patch1 binaries
  
  Revision  Changes    Path
  1.2       +2725 -2702/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin/ejb3.deployer
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Wed Dec 20 14:41:25 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Wed, 20 Dec 2006 14:41:25 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 ...
Message-ID: <E1Gx7Jd-0003Oq-9r@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/20 14:41:25

  Modified:    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 
                        component-info.xml
  Log:
  replaceing with the original patch1 binaries
  
  Revision  Changes    Path
  1.2       +7 -5      /repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	19 Dec 2006 15:12:50 -0000	1.1
  +++ component-info.xml	20 Dec 2006 19:41:25 -0000	1.2
  @@ -2,11 +2,9 @@
   
      <component id="jboss/ejb3"
                 licenseType="lgpl"
  -              version="1.0.0.CR9-patch1-jboss4.0.5"
  +              version="1.0.0.CR9-jboss4.0.5-patch1-VR"
                 description="The EJB3 deployer for integration with jboss-4.0.x">
  -      <!-- cvsroot=":ext:cvs.devel.redhat.com:/cvs/dist/jbossas-ejb3"
  -           tag="jbossas-ejb3-1_0_0-0_1_rc9_el4s1_5"
  -        -->
  +
         <artifact id="ejb3-clustered-sfsbcache-service.xml"/>
         <artifact id="ejb3-entity-cache-service.xml"/>
         <artifact id="ejb3-interceptors-aop.xml"/>
  @@ -17,6 +15,8 @@
         <import componentref="javassist">
           <compatible version="3.2.0.CR1"/>
           <compatible version="3.2.0.CR2"/>
  +        <compatible version="3.2.0.GA"/>
  +        <compatible version="3.3.0.GA"/>
         </import>
         <import componentref="hibernate-annotations">
           <compatible version="3.2.0.GA"/>
  @@ -27,6 +27,8 @@
         <import componentref="jboss/remoting">
           <compatible version="1.4.1_final"/>
           <compatible version="1.4.2.GA"/>
  +        <compatible version="1.4.3.GA"/>
  +        <compatible version="1.4.4.GA"/>
         </import>
         <import componentref="jboss/aop">
           <compatible version="1.5.1.GA"/>
  
  
  


From validimir.ralev at jboss.com  Wed Dec 20 14:41:25 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Wed, 20 Dec 2006 14:41:25 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib ...
Message-ID: <E1Gx7Jd-0003Oy-EY@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/20 14:41:25

  Modified:    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib  
                        jboss-ejb3-client.jar hibernate-client.jar
  Log:
  replaceing with the original patch1 binaries
  
  Revision  Changes    Path
  1.2       +156 -155  /repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/jboss-ejb3-client.jar
  
  	<<Binary file>>
  
  
  1.2       +252 -255  /repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/hibernate-client.jar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Wed Dec 20 14:45:02 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Wed, 20 Dec 2006 14:45:02 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 ...
Message-ID: <E1Gx7N8-0003ST-JO@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/20 14:45:02

  Modified:    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5 
                        component-info.xml
  Log:
  replaceing with the original patch1 binaries
  
  Revision  Changes    Path
  1.3       +1 -1      /repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss//repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- component-info.xml	20 Dec 2006 19:41:25 -0000	1.2
  +++ component-info.xml	20 Dec 2006 19:45:02 -0000	1.3
  @@ -2,7 +2,7 @@
   
      <component id="jboss/ejb3"
                 licenseType="lgpl"
  -              version="1.0.0.CR9-jboss4.0.5-patch1-VR"
  +              version="1.0.0.CR9-patch1-jboss4.0.5"
                 description="The EJB3 deployer for integration with jboss-4.0.x">
   
         <artifact id="ejb3-clustered-sfsbcache-service.xml"/>
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:40 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/xb
	...
Message-ID: <E1Gx7YO-0003f4-SO@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/xb 
                        XbPackageNode.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.3       +1 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/xb/XbPackageNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: XbPackageNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/xb/XbPackageNode.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- XbPackageNode.java	8 Nov 2006 19:54:41 -0000	1.2
  +++ XbPackageNode.java	20 Dec 2006 19:56:40 -0000	1.3
  @@ -91,7 +91,7 @@
   		return parent;
   	}
   	
  -	protected void setParent (XbPackageNode parent)
  +	public void setParent (XbPackageNode parent)
   	{
   		this.parent = parent;
   	}
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:40 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types
	...
Message-ID: <E1Gx7YO-0003ex-OX@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types 
                        JARPackageType.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.4       +8 -14     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JARPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- JARPackageType.java	21 Nov 2006 17:40:31 -0000	1.3
  +++ JARPackageType.java	20 Dec 2006 19:56:40 -0000	1.4
  @@ -2,7 +2,6 @@
   
   import org.eclipse.core.resources.IContainer;
   import org.eclipse.core.resources.IProject;
  -import org.eclipse.core.resources.ResourcesPlugin;
   import org.eclipse.core.runtime.Assert;
   import org.eclipse.core.runtime.IPath;
   import org.eclipse.core.runtime.IProgressMonitor;
  @@ -13,8 +12,6 @@
   import org.jboss.ide.eclipse.packages.core.Trace;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFileSetWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   
   /**
  @@ -48,20 +45,17 @@
   		outputPath = outputPath.removeFirstSegments(1);
   		IContainer outputContainer = project.getFolder(outputPath);
   		
  -		IPackage jar = PackagesCore.createPackage(project, true);
  -		IPackageWorkingCopy jarWC = jar.createPackageWorkingCopy();
  +		IPackage jar = PackagesCore.createDetachedPackage(project, true);
   		
  -		jarWC.setDestinationContainer(project);
  -		jarWC.setExploded(false);
  -		jarWC.setName(project.getName() + ".jar");
  -		jarWC.setPackageType(this);
  -		jar = jarWC.savePackage();
  +		jar.setDestinationContainer(project);
  +		jar.setExploded(false);
  +		jar.setName(project.getName() + ".jar");
  +		jar.setPackageType(this);
   		
   		IPackageFileSet classes = PackagesCore.createPackageFileSet(project);
  -		IPackageFileSetWorkingCopy classesWC = classes.createFileSetWorkingCopy();
  -		classesWC.setIncludesPattern("**/*");
  -		classesWC.setSourceContainer(outputContainer);
  -		classes = classesWC.saveFileSet();
  +		classes.setIncludesPattern("**/*");
  +		classes.setSourceContainer(outputContainer);
  +		
   		jar.addChild(classes);
   		
   		monitor.worked(1);
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:40 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model
	...
Message-ID: <E1Gx7YO-0003eU-G2@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model           
                        PackagesCore.java IPackageFileSet.java
                        IPackageFolder.java IPackagesModelListener.java
                        IPackageNode.java IPackage.java
  Removed:     core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model           
                        IPackageNodeWorkingCopy.java
                        IPackageFileSetWorkingCopy.java
                        IPackageFolderWorkingCopy.java
                        IPackageWorkingCopy.java IPackageNodeBase.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.11      +24 -2     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesCore.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- PackagesCore.java	6 Dec 2006 17:02:56 -0000	1.10
  +++ PackagesCore.java	20 Dec 2006 19:56:40 -0000	1.11
  @@ -34,7 +34,6 @@
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.core.runtime.Path;
  -import org.eclipse.core.runtime.Platform;
   import org.eclipse.core.runtime.QualifiedName;
   import org.jboss.ide.eclipse.packages.core.Trace;
   import org.jboss.ide.eclipse.packages.core.model.internal.PackageBuildDelegate;
  @@ -190,7 +189,7 @@
   	
   	public static IPackage getTopLevelPackage (IPackageNode node)
   	{
  -		IPackageNodeBase tmp = node.getParent(), top = tmp;
  +		IPackageNode tmp = node.getParent(), top = tmp;
   		while (tmp != null)
   		{
   			top = tmp;
  @@ -294,16 +293,31 @@
   		return PackagesModel.instance().createPackage(project, isTopLevel);
   	}
   	
  +	public static IPackage createDetachedPackage (IProject project, boolean isTopLevel)
  +	{
  +		return PackagesModel.instance().createDetachedPackage(project, isTopLevel);
  +	}
  +	
   	public static IPackageFolder createPackageFolder (IProject project)
   	{
   		return PackagesModel.instance().createPackageFolder(project);
   	}
   	
  +	public static IPackageFolder createDetachedFolder (IProject project)
  +	{
  +		return PackagesModel.instance().createDetachedFolder(project);
  +	}
  +	
   	public static IPackageFileSet createPackageFileSet (IProject project)
   	{
   		return PackagesModel.instance().createPackageFileSet(project);
   	}
   	
  +	public static IPackageFileSet createDetachedPackageFileSet (IProject project)
  +	{
  +		return PackagesModel.instance().createDetachedFileSet(project);
  +	}
  +	
   	public static void addPackagesModelListener (IPackagesModelListener listener)
   	{
   		PackagesModel.instance().addPackagesModelListener(listener);
  @@ -324,4 +338,12 @@
   		PackagesModel.instance().removePackagesBuildListener(listener);
   	}
   	
  +	/**
  +	 * Attach a detached node to the model. This node will be saved and added to the next build.
  +	 * @param nodeToAttach
  +	 */
  +	public static void attach (IPackageNode nodeToAttach, IProgressMonitor monitor)
  +	{
  +		PackagesModel.instance().attach(nodeToAttach, monitor);
  +	}
   }
  
  
  
  1.3       +66 -3     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageFileSet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSet.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IPackageFileSet.java	6 Dec 2006 17:02:56 -0000	1.2
  +++ IPackageFileSet.java	20 Dec 2006 19:56:40 -0000	1.3
  @@ -32,7 +32,7 @@
    * </p>
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public interface IPackageFileSet extends IPackageNode {
   
  @@ -113,7 +113,70 @@
   	public boolean matchesPath(IPath path);
   	
   	/**
  -	 * @return A working copy of this fileset
  +	 * Set this fileset to be a single file in the workspace
  +	 * Equivalent to:
  +	 * <code>setSingleFile(file, null);</code>
  +	 * 
  +	 * @param file the single file for this fileset
   	 */
  -	public IPackageFileSetWorkingCopy createFileSetWorkingCopy();
  +	public void setSingleFile(IFile file);
  +	
  +	/**
  +	 * Set this fileset to be a single file in the workspace, using the specified destination filename
  +	 * @param file The single file to be included in this fileset
  +	 * @param destinationFilename The filename that the file will be called in the package
  +	 */
  +	public void setSingleFile(IFile file, String destinationFilename);
  +	
  +	/**
  +	 * Set this fileset to be a single file in the filesystem
  +	 * Equivalent to:
  +	 * <code>setSingleFile(path, null);</code>
  +	 * @param path An absolute path to a file on the filesystem 
  +	 */
  +	public void setSingleFile(IPath path);
  +	
  +	/**
  +	 * Set this fileset to be a single file in the filesystem, using the specified destination filename
  +	 * @param path An absolute path to a file on the filesystem
  +	 * @param destinationFilename The filename that the file will be called in the package
  +	 */
  +	public void setSingleFile(IPath path, String destinationFilename);
  +	
  +	/**
  +	 * Sets the "root" or "source" of this fileset to be the passed-in project
  +	 * @param project The project that is the source of this fileset
  +	 */
  +	public void setSourceProject(IProject project);
  +	
  +	/**
  +	 * Sets the "root" or "source" of this fileset to the be the passed-in container
  +	 * @param container The container that is the source of this fileset
  +	 */
  +	public void setSourceContainer(IContainer container);
  +	
  +	/**
  +	 * Sets the "root" or "source" of this fileset to be an absolute path on the filesystem
  +	 * @param path The absolute path that is the source of this fileset
  +	 */
  +	public void setSourceFolder(IPath path);
  +	
  +	/**
  +	 * Set the includes pattern for this fileset. This pattern uses the same syntax as Ant's include pattern.
  +	 * @param includes The includes pattern for this fileset
  +	 */
  +	public void setIncludesPattern(String includes);
  +	
  +	/**
  +	 * Set the excludes pattern for this fileset. This pattern uses the same syntax as Ant's exclude pattern.
  +	 * @param excludes The excludes pattern for this fileset
  +	 */
  +	public void setExcludesPattern(String excludes);
  +	
  +	/**
  +	 * Set whether or not this fileset's source is in the workspace. This will automatically be handled if you
  +	 * use setSingleFile, setSourceProject, setSourceContainer, or setSourceFolder.
  +	 * @param isInWorkspace Whether or not this fileset's source is in the workspace
  +	 */
  +	public void setInWorkspace(boolean isInWorkspace);
   }
  
  
  
  1.2       +21 -2     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolder.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageFolder.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolder.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackageFolder.java	6 Nov 2006 21:35:27 -0000	1.1
  +++ IPackageFolder.java	20 Dec 2006 19:56:40 -0000	1.2
  @@ -30,19 +30,38 @@
    * </p>
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    */
   public interface IPackageFolder extends IPackageNode {
   
  +	/**
  +	 * @return The name of this folder
  +	 */
   	public String getName();
   	
  +	/**
  +	 * Set the name of this folder
  +	 * @param name The name of this folder
  +	 */
  +	public void setName(String name);
  +	
  +	/**
  +	 * @return An array of sub-packages of this folder
  +	 */
   	public IPackage[] getPackages();
   	
  +	/**
  +	 * @return An array of sub-folders of this folder
  +	 */
   	public IPackageFolder[] getFolders();
   	
  +	/**
  +	 * @return An array of filesets whose destination is this folder
  +	 */
   	public IPackageFileSet[] getFileSets();
   	
  -	public IPackageFolderWorkingCopy createFolderWorkingCopy();
  -	
  +	/**
  +	 * @return The path within the package to this folder
  +	 */
   	public IPath getPackageRelativePath();
   }
  
  
  
  1.2       +28 -0     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackagesModelListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackagesModelListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackagesModelListener.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackagesModelListener.java	6 Nov 2006 21:35:27 -0000	1.1
  +++ IPackagesModelListener.java	20 Dec 2006 19:56:40 -0000	1.2
  @@ -1,10 +1,38 @@
   package org.jboss.ide.eclipse.packages.core.model;
   
  +/**
  + * Implementations of this interface should register themselves to listen with:
  + * <code>
  + * 	PackagesCore.registerPackagesModelListener(listener)
  + * </code>
  + * 
  + * @author Marshall
  + */
   public interface IPackagesModelListener {
   
  +	/**
  +	 * A node was added to the model
  +	 * @param added The added node
  +	 */
   	public void packageNodeAdded (IPackageNode added);
   	
  +	/**
  +	 * A node was removed from the model
  +	 * @param removed The removed node
  +	 */
   	public void packageNodeRemoved (IPackageNode removed);
   	
  +	/**
  +	 * A node's data/attirbutes were changed
  +	 * @param changed The changed node
  +	 */
   	public void packageNodeChanged (IPackageNode changed);
  +	
  +	/**
  +	 * A node has been attached to the model. This will only be called once
  +	 * for the top level attached node, any processing of sub-nodes will need to happen using IPackageNode.accept.
  +	 * 
  +	 * @param attached The node that was attached
  +	 */
  +	public void packageNodeAttached (IPackageNode attached);
   }
  
  
  
  1.4       +82 -2     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNode.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- IPackageNode.java	6 Dec 2006 17:02:56 -0000	1.3
  +++ IPackageNode.java	20 Dec 2006 19:56:40 -0000	1.4
  @@ -21,15 +21,95 @@
    */
   package org.jboss.ide.eclipse.packages.core.model;
   
  +import org.eclipse.core.resources.IProject;
  +
   /**
    * The super type of all package nodes (IPackage, IPackageFileSet, IPackageFolder)
    * 
    * Each node in a package may have arbitrary properties that can be reflected upon by other plug-ins
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
  + */
  +public interface IPackageNode {
  +	
  +	/**
  +	 * The node type that represents an IPackage
  +	 */
  +	public static final int TYPE_PACKAGE = 0;
  +	
  +	/**
  +	 * The node type that represents an IPackageFileSet
  +	 */
  +	public static final int TYPE_PACKAGE_FILESET = 1;
  +	
  +	/**
  +	 * The node type that represents an IPackageFolder
  +	 */
  +	public static final int TYPE_PACKAGE_FOLDER = 2;
  +	
  +	/**
  +	 * @return The parent of this package node, or null if this node is top level
  +	 */
  +	public IPackageNode getParent();
  +	
  +	/**
  +	 * Set the parent of this package node 
  +	 * @param parent The new parent of this node
  +	 */
  +	public void setParent(IPackageNode parent);
  +	
  +	/**
  +	 * @param type TYPE_PACKAGE, TYPE_PACKAGE_FILESET, or TYPE_PACKAGE_FOLDER
  +	 * @return An array of child nodes of the passed in type
  +	 */
  +	public IPackageNode[] getChildren(int type);
  +	
  +	/**
  +	 * @return An array of all children nodes
  +	 */
  +	public IPackageNode[] getAllChildren();
  +	
  +	/**
  +	 * @return Whether or not this node has children
  +	 */
  +	public boolean hasChildren();
  +	
  +	/**
  +	 * @param child A possible child node
  +	 * @return Whether or not the passed-in node is a child of this node
  +	 */
  +	public boolean hasChild(IPackageNode child);
  +	
  +	/**
  +	 * @return The type of this package node
  +	 */
  +	public int getNodeType();
  +	
  +	/**
  +	 * @param property The name of the property to fetch
  +	 * @return The value of the specified property
  +	 */
  +	public String getProperty(String property);
  +	
  +	/**
  +	 * @return The project that this node is defined in (not necessarily the project where this is based if this is a fileset)
  +	 */
  +	public IProject getProject();
  +	
  +	/**
  +	 * Recursively visit the package node tree below this node with the passed-in package node visitor.
  +	 * @param visitor A package node visitor
  +	 * @return Whether or not the entire sub-tree was visited
  +	 */
  +	public boolean accept(IPackageNodeVisitor visitor);
  +	
  +	/**
  +	 * Recursively visit the package node tree below this node with the passed-in package node visitor, using depth-first ordering
  +	 * @param visitor A package node visitor
  +	 * @return Whether or not the entire sub-tree was visited
    */
  -public interface IPackageNode extends IPackageNodeBase {
  +	public boolean accept(IPackageNodeVisitor visitor, boolean depthFirst);
   	
   	/**
   	 * Add a child node to this node
  
  
  
  1.5       +37 -8     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackage.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- IPackage.java	6 Dec 2006 20:17:55 -0000	1.4
  +++ IPackage.java	20 Dec 2006 19:56:40 -0000	1.5
  @@ -35,7 +35,7 @@
    * </p>
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public interface IPackage extends IPackageNode {
   
  @@ -115,13 +115,6 @@
   	public IPackageFileSet[] getFileSets();
   	
   	/**
  -	 * Create a working copy of this IPackage. This will allow you to work on a disconnected model object until
  -	 * you are ready to make the changes live, at which point you can use workingCopy.save()
  -	 * @return A working copy of this package
  -	 */
  -	public IPackageWorkingCopy createPackageWorkingCopy();
  -
  -	/**
   	 * Get the IFile that corresponds with this package. Note that this method only works for in-workspace packages (null will be returned otherwise)
   	 * @return The corresponding IFile in the workspace (note that this file may not exist)
   	 */
  @@ -139,4 +132,40 @@
   	 * @return a relative IPath to this package's top level parent
   	 */
   	public IPath getPackageRelativePath();
  +	
  +	/**
  +	 * Set the package type of this package
  +	 * @param type The package type
  +	 */
  +	public void setPackageType(IPackageType type);
  +
  +	/**
  +	 * Set the name of this package
  +	 * @param name This package's name
  +	 */
  +	public void setName(String name);
  +	
  +	/**
  +	 * Set whether or not this package is generated as a folder
  +	 * @param exploded
  +	 */
  +	public void setExploded(boolean exploded);
  +	
  +	/**
  +	 * Set a path to a custom manifest for this package. This is usefulf or runnable JARs etc.
  +	 * @param manifestFile The manifest file in the workspace
  +	 */
  +	public void setManifest(IFile manifestFile);
  +	
  +	/**
  +	 * Sets the destination folder in the filesystem for this package
  +	 * @param path The absolute path where this package will be built
  +	 */
  +	public void setDestinationFolder (IPath path);
  +	
  +	/**
  +	 * Sets the destination container in the workspace for this package
  +	 * @param container The container where this package will be built
  +	 */
  +	public void setDestinationContainer(IContainer container);
   }
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:42 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:42 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards
	...
Message-ID: <E1Gx7YQ-0003fR-94@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:42

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards    
                        NewJARWizard.java AbstractPackageWizard.java
                        NewWARWizard.java FilesetWizard.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.3       +9 -3      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/NewJARWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewJARWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/NewJARWizard.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- NewJARWizard.java	20 Nov 2006 21:06:05 -0000	1.2
  +++ NewJARWizard.java	20 Dec 2006 19:56:42 -0000	1.3
  @@ -2,17 +2,21 @@
   
   import org.eclipse.jface.resource.ImageDescriptor;
   import org.eclipse.jface.wizard.WizardPage;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
  +import org.jboss.ide.eclipse.packages.core.Trace;
  +import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.core.model.types.JARPackageType;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIMessages;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
  +import org.jboss.ide.eclipse.packages.ui.wizards.pages.DefaultJARConfigWizardPage;
   
   public class NewJARWizard extends AbstractPackageWizard
   {
   	public WizardPage[] createWizardPages() {
   		
  -		return new WizardPage[0];
  +		return new WizardPage[] {
  +				new DefaultJARConfigWizardPage(this)
  +		};
   	}
   
   	public NewJARWizard ()
  @@ -20,7 +24,9 @@
   		setWindowTitle(PackagesUIMessages.NewJARWizard_windowTitle);
   	}
   	
  -	public boolean performFinish(IPackageWorkingCopy pkg) {
  +	public boolean performFinish(IPackage pkg) {
  +		Trace.trace(getClass(), "performing finish");
  +		
   		pkg.setPackageType(PackagesCore.getPackageType(JARPackageType.TYPE_ID));
   		return true;
   	}
  
  
  
  1.5       +42 -25    jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/AbstractPackageWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractPackageWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/AbstractPackageWizard.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- AbstractPackageWizard.java	16 Nov 2006 20:56:57 -0000	1.4
  +++ AbstractPackageWizard.java	20 Dec 2006 19:56:42 -0000	1.5
  @@ -1,22 +1,27 @@
   package org.jboss.ide.eclipse.packages.ui.wizards;
   
  +import java.lang.reflect.InvocationTargetException;
  +
   import org.eclipse.core.resources.IContainer;
   import org.eclipse.core.resources.IProject;
  -import org.eclipse.core.runtime.IPath;
  +import org.eclipse.core.runtime.IProgressMonitor;
  +import org.eclipse.jface.operation.IRunnableWithProgress;
   import org.eclipse.jface.resource.ImageDescriptor;
   import org.eclipse.jface.viewers.IStructuredSelection;
  -import org.eclipse.jface.wizard.Wizard;
  +import org.eclipse.jface.wizard.IWizardPage;
   import org.eclipse.jface.wizard.WizardPage;
   import org.eclipse.ui.INewWizard;
   import org.eclipse.ui.IWorkbench;
   import org.jboss.ide.eclipse.core.util.ProjectUtil;
  +import org.jboss.ide.eclipse.packages.core.Trace;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.ui.wizards.pages.PackageInfoWizardPage;
  +import org.jboss.ide.eclipse.ui.wizards.WizardPageWithNotification;
  +import org.jboss.ide.eclipse.ui.wizards.WizardWithNotification;
   
  -public abstract class AbstractPackageWizard extends Wizard implements INewWizard
  +public abstract class AbstractPackageWizard extends WizardWithNotification implements INewWizard
   {
   	private PackageInfoWizardPage firstPage;
   	private WizardPage pages[];
  @@ -48,34 +53,34 @@
   	}
   	
   	public boolean performFinish() {
  -		Object destContainer = firstPage.getPackageDestination();
  -		
  -		boolean isTopLevel = (destContainer == null || (!(destContainer instanceof IPackageNode)));
  -		IPackage pkg = PackagesCore.createPackage(project, isTopLevel);
  -		IPackageWorkingCopy packageWC = pkg.createPackageWorkingCopy();
  +		IWizardPage currentPage = getContainer().getCurrentPage();
   		
  -		packageWC.setName(firstPage.getPackageName());
  -		packageWC.setExploded(firstPage.isPackageExploded());
  -		if (firstPage.isManifestEnabled())
  +		if (currentPage instanceof WizardPageWithNotification)
   		{
  -			packageWC.setManifest(firstPage.getManifestFile());
  +			((WizardPageWithNotification)currentPage).pageExited(WizardWithNotification.FINISH);
   		}
   		
  -		if (!destContainer.equals(project) && destContainer instanceof IContainer) {
  -			packageWC.setDestinationContainer((IContainer)destContainer);
  -		}
  -		else if (destContainer instanceof IPath)
  -		{
  -			packageWC.setDestinationFolder((IPath) destContainer);
  -		}
  +		final IPackage pkg = firstPage.getPackage();
  +		Object destination = firstPage.getPackageDestination();
   		
  -		boolean performed = performFinish(packageWC);
  +		boolean performed = performFinish(pkg);
   		
   		if (performed)
   		{
  -			pkg = packageWC.savePackage();
  -			if (destContainer instanceof IPackageNode) {
  -				IPackageNode node = (IPackageNode) destContainer;
  +			try {
  +				getContainer().run(false, false, new IRunnableWithProgress () {
  +					public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
  +						PackagesCore.attach(pkg, monitor);	
  +					}
  +				});
  +			} catch (InvocationTargetException e) {
  +				Trace.trace(getClass(), e);
  +			} catch (InterruptedException e) {
  +				Trace.trace(getClass(), e);
  +			}
  +			
  +			if (destination instanceof IPackageNode) {
  +				IPackageNode node = (IPackageNode) destination;
   				node.addChild(pkg);
   			}
   		}
  @@ -102,6 +107,8 @@
   		else {
   			selectedDestination = project;
   		}
  +		
  +		setNeedsProgressMonitor(true);
   	}
   	
   	public Object getSelectedDestination ()
  @@ -109,7 +116,7 @@
   		return selectedDestination;
   	}
   	
  -	public abstract boolean performFinish(IPackageWorkingCopy pkg);
  +	public abstract boolean performFinish(IPackage pkg);
   	public abstract WizardPage[] createWizardPages();
   	public abstract ImageDescriptor getImageDescriptor();
   	public abstract String getPackageExtension();
  @@ -117,4 +124,14 @@
   	public IProject getProject() {
   		return project;
   	}
  +	
  +	/**
  +	 * Returns the package created by this wizard.
  +	 * Note: This should only be called after the first page has been completed
  +	 * @return The package
  +	 */
  +	public IPackage getPackage ()
  +	{
  +		return firstPage.getPackage();
  +	}
   }
  
  
  
  1.2       +3 -3      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/NewWARWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewWARWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/NewWARWizard.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- NewWARWizard.java	6 Nov 2006 21:36:50 -0000	1.1
  +++ NewWARWizard.java	20 Dec 2006 19:56:42 -0000	1.2
  @@ -2,7 +2,7 @@
   
   import org.eclipse.jface.resource.ImageDescriptor;
   import org.eclipse.jface.wizard.WizardPage;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
  +import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
   import org.jboss.ide.eclipse.packages.ui.wizards.pages.WARInfoWizardPage;
   
  @@ -25,8 +25,8 @@
   		return new WizardPage[] { warInfoPage };
   	}
   
  -	public boolean performFinish(IPackageWorkingCopy pkg) {
  -		pkg.setPackageType("war");
  +	public boolean performFinish(IPackage pkg) {
  +		//pkg.setPackageType("war");
   		return true;
   	}
   	
  
  
  
  1.5       +24 -12    jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/FilesetWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FilesetWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/FilesetWizard.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- FilesetWizard.java	6 Dec 2006 17:02:58 -0000	1.4
  +++ FilesetWizard.java	20 Dec 2006 19:56:42 -0000	1.5
  @@ -1,11 +1,15 @@
   package org.jboss.ide.eclipse.packages.ui.wizards;
   
  +import java.lang.reflect.InvocationTargetException;
  +
   import org.eclipse.core.resources.IContainer;
  +import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.Path;
  +import org.eclipse.jface.operation.IRunnableWithProgress;
   import org.eclipse.jface.wizard.Wizard;
  +import org.jboss.ide.eclipse.packages.core.Trace;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFileSetWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
  +import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.ui.wizards.pages.FilesetInfoWizardPage;
   
  @@ -13,9 +17,9 @@
   
   	private FilesetInfoWizardPage page1;
   	private IPackageFileSet fileset;
  -	private IPackageNodeBase parentNode;
  +	private IPackageNode parentNode;
   	
  -	public FilesetWizard(IPackageFileSet fileset, IPackageNodeBase parentNode)
  +	public FilesetWizard(IPackageFileSet fileset, IPackageNode parentNode)
   	{
   		this.fileset = fileset;
   		this.parentNode = parentNode;
  @@ -25,21 +29,29 @@
   		boolean createFileset = this.fileset == null;
   		
   		if (createFileset)
  -			this.fileset = PackagesCore.createPackageFileSet(parentNode.getProject());
  -		
  -		IPackageFileSetWorkingCopy filesetWC = fileset.createFileSetWorkingCopy();
  -		
  -		fillFilesetFromPage(filesetWC);
  +			this.fileset = PackagesCore.createDetachedPackageFileSet(parentNode.getProject());
   
  -		filesetWC.save();
  +		fillFilesetFromPage(fileset);
   		
   		if (createFileset)
   			page1.getRootNode().addChild(this.fileset);
   		
  +		try {
  +			getContainer().run(false, false, new IRunnableWithProgress () {
  +				public void run(IProgressMonitor monitor) throws InvocationTargetException, InterruptedException {
  +					PackagesCore.attach(fileset, monitor);	
  +				}
  +			});
  +		} catch (InvocationTargetException e) {
  +			Trace.trace(getClass(), e);
  +		} catch (InterruptedException e) {
  +			Trace.trace(getClass(), e);
  +		}
  +		
   		return true;
   	}
   	
  -	private void fillFilesetFromPage (IPackageFileSetWorkingCopy fileset)
  +	private void fillFilesetFromPage (IPackageFileSet fileset)
   	{
   		if (page1.isSingleFile())
   		{
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:42 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:42 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages
	...
Message-ID: <E1Gx7YQ-0003fe-DA@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:42

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages   
                        FilesetInfoWizardPage.java
                        PackageInfoWizardPage.java
  Added:       core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages   
                        DefaultJARConfigWizardPage.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.4       +2 -3      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/FilesetInfoWizardPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FilesetInfoWizardPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/FilesetInfoWizardPage.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- FilesetInfoWizardPage.java	6 Dec 2006 17:02:58 -0000	1.3
  +++ FilesetInfoWizardPage.java	20 Dec 2006 19:56:42 -0000	1.4
  @@ -42,7 +42,6 @@
   import org.eclipse.ui.part.PageBook;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIMessages;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
  @@ -51,7 +50,7 @@
   public class FilesetInfoWizardPage extends WizardPage {
   
   	private IPackageFileSet fileset;
  -	private IPackageNodeBase parentNode;
  +	private IPackageNode parentNode;
   	private Text includesText;
   	private Text excludesText;
   	private TableViewer previewTable;
  @@ -78,7 +77,7 @@
   	private Composite singleFileComposite;
   	private Label singleFileProjectLabel;
   	
  -	public FilesetInfoWizardPage (Shell parent, IPackageFileSet fileset, IPackageNodeBase parentNode)
  +	public FilesetInfoWizardPage (Shell parent, IPackageFileSet fileset, IPackageNode parentNode)
   	{
   		super(PackagesUIMessages.FilesetInfoWizardPage_new_title, PackagesUIMessages.FilesetInfoWizardPage_new_title, null);
   		
  
  
  
  1.3       +64 -4     jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/PackageInfoWizardPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageInfoWizardPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/PackageInfoWizardPage.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackageInfoWizardPage.java	29 Nov 2006 18:58:45 -0000	1.2
  +++ PackageInfoWizardPage.java	20 Dec 2006 19:56:42 -0000	1.3
  @@ -2,7 +2,8 @@
   
   import org.eclipse.core.resources.IContainer;
   import org.eclipse.core.resources.IFile;
  -import org.eclipse.jface.wizard.WizardPage;
  +import org.eclipse.core.resources.IProject;
  +import org.eclipse.core.runtime.IPath;
   import org.eclipse.swt.SWT;
   import org.eclipse.swt.events.ModifyEvent;
   import org.eclipse.swt.events.ModifyListener;
  @@ -16,13 +17,17 @@
   import org.eclipse.swt.widgets.Group;
   import org.eclipse.swt.widgets.Label;
   import org.eclipse.swt.widgets.Text;
  +import org.jboss.ide.eclipse.packages.core.Trace;
  +import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  +import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.ui.PackagesUIMessages;
   import org.jboss.ide.eclipse.packages.ui.util.PackageDestinationComposite;
  -import org.jboss.ide.eclipse.packages.ui.util.PackageNodeDestinationComposite;
   import org.jboss.ide.eclipse.packages.ui.wizards.AbstractPackageWizard;
  +import org.jboss.ide.eclipse.ui.wizards.WizardPageWithNotification;
  +import org.jboss.ide.eclipse.ui.wizards.WizardWithNotification;
   
  -public class PackageInfoWizardPage extends WizardPage {
  +public class PackageInfoWizardPage extends WizardPageWithNotification {
   
   	private AbstractPackageWizard wizard;
   	private Text packageNameText;
  @@ -36,6 +41,7 @@
   	private boolean manifestEnabled;
   	private IFile manifestFile;
   	private PackageDestinationComposite destinationComposite;
  +	private IPackage pkg;
   
   	public PackageInfoWizardPage (AbstractPackageWizard wizard)
   	{
  @@ -156,6 +162,55 @@
   		return true;
   	}
   	
  +	
  +	public void pageExited(int button) {
  +		Trace.trace(getClass(), "pageExited");
  +		if (button == WizardWithNotification.NEXT || button == WizardWithNotification.FINISH)
  +		{
  +			createPackage();
  +		}
  +	}
  +	
  +	private void createPackage ()
  +	{
  +		Trace.trace(getClass(), "creating package");
  +		
  +		Object destContainer = getPackageDestination();
  +		
  +		boolean isTopLevel = (destContainer == null || (!(destContainer instanceof IPackageNode)));
  +		
  +		IProject project = null;
  +		
  +		if (destContainer instanceof IPackageNode)
  +		{
  +			project = ((IPackageNode)destContainer).getProject();
  +		}
  +		else if (destContainer instanceof IContainer)
  +		{
  +			project = ((IContainer)destContainer).getProject();
  +		}
  +		else {
  +			project = wizard.getProject();
  +		}
  +		
  +		pkg = PackagesCore.createDetachedPackage(project, isTopLevel);
  +		
  +		pkg.setName(getPackageName());
  +		pkg.setExploded(isPackageExploded());
  +		if (isManifestEnabled())
  +		{
  +			pkg.setManifest(getManifestFile());
  +		}
  +		
  +		if (!destContainer.equals(wizard.getProject()) && destContainer instanceof IContainer) {
  +			pkg.setDestinationContainer((IContainer)destContainer);
  +		}
  +		else if (destContainer instanceof IPath)
  +		{
  +			pkg.setDestinationFolder((IPath) destContainer);
  +		}
  +	}
  +	
   	private void expand(Control control)
   	{
   		control.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
  @@ -185,4 +240,9 @@
   	{
   		this.wizard = wizard;
   	}
  +	
  +	public IPackage getPackage ()
  +	{
  +		return pkg;
  +	}
   }
  
  
  
  1.1      date: 2006/12/20 19:56:42;  author: mculpepper;  state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/DefaultJARConfigWizardPage.java
  
  Index: DefaultJARConfigWizardPage.java
  ===================================================================
  package org.jboss.ide.eclipse.packages.ui.wizards.pages;
  
  import org.eclipse.jface.viewers.TreeViewer;
  import org.eclipse.swt.SWT;
  import org.eclipse.swt.layout.GridLayout;
  import org.eclipse.swt.widgets.Button;
  import org.eclipse.swt.widgets.Composite;
  import org.eclipse.swt.widgets.Label;
  import org.jboss.ide.eclipse.packages.ui.PackagesUIPlugin;
  import org.jboss.ide.eclipse.packages.ui.providers.PackagesContentProvider;
  import org.jboss.ide.eclipse.packages.ui.providers.PackagesLabelProvider;
  import org.jboss.ide.eclipse.packages.ui.wizards.AbstractPackageWizard;
  import org.jboss.ide.eclipse.ui.wizards.WizardPageWithNotification;
  import org.jboss.ide.eclipse.ui.wizards.WizardWithNotification;
  
  public class DefaultJARConfigWizardPage extends WizardPageWithNotification {
  
  	private AbstractPackageWizard wizard;
  	
  	public DefaultJARConfigWizardPage (AbstractPackageWizard wizard)
  	{
  		super ("Default JAR Configuration", "Default JAR Configuration", PackagesUIPlugin.getImageDescriptor(PackagesUIPlugin.IMG_NEW_JAR_WIZARD));
  		
  		this.wizard = wizard;
  	}
  	
  	public void createControl(Composite parent) {
  
  		Composite main = new Composite(parent, SWT.NONE);
  		main.setLayout(new GridLayout(1, false));
  		
  		Button createDefaultConfig = new Button(main, SWT.CHECK);
  		createDefaultConfig.setText("Use default JAR configuration");
  		
  		new Label(main, SWT.NONE).setText("Preview");
  		
  		TreeViewer previewTree = new TreeViewer(main);
  		previewTree.setContentProvider(new PackagesContentProvider());
  		previewTree.setLabelProvider(new PackagesLabelProvider());
  		previewTree.setInput(wizard.getPackage());
  		
  		setControl(main);
  	}
  
  }
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:42 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:42 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/providers
	...
Message-ID: <E1Gx7YQ-0003fl-Gs@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:42

  Added:       core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/providers 
                        PackagePreviewContentProvider.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.1      date: 2006/12/20 19:56:42;  author: mculpepper;  state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/providers/PackagePreviewContentProvider.java
  
  Index: PackagePreviewContentProvider.java
  ===================================================================
  package org.jboss.ide.eclipse.packages.ui.providers;
  
  import java.util.ArrayList;
  import java.util.Arrays;
  import java.util.Collection;
  
  import org.eclipse.jface.viewers.ITreeContentProvider;
  import org.eclipse.jface.viewers.Viewer;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  
  public class PackagePreviewContentProvider implements ITreeContentProvider {
  
  	public Object[] getChildren(Object parentElement) {
  		if (parentElement instanceof IPackageNode)
  		{	
  			IPackageNode node = (IPackageNode) parentElement;
  			if (node.getNodeType() == IPackageNode.TYPE_PACKAGE || node.getNodeType() == IPackageNode.TYPE_PACKAGE_FOLDER)
  			{
  				ArrayList children = new ArrayList();
  				IPackageNode[] childNodes = node.getAllChildren();
  				
  				for (int i = 0; i < childNodes.length; i++)
  				{
  					int nodeType = childNodes[i].getNodeType();
  					
  					if (nodeType == IPackageNode.TYPE_PACKAGE || nodeType == IPackageNode.TYPE_PACKAGE_FOLDER)
  					{
  						children.add(childNodes[i]);
  					}
  				}
  			}
  			else {
  				return getFilesInFileset((IPackageFileSet)node);
  			}
  		}
  		
  		return new Object[0];
  	}
  	
  	private Object[] getFilesInFileset (IPackageFileSet fileset)
  	{
  		ArrayList files = new ArrayList ();
  		
  		if (!fileset.isSingleFile())
  		{
  			if (fileset.isInWorkspace())
  			{
  				files.addAll(Arrays.asList(fileset.findMatchingFiles()));
  			}
  			else {
  				files.addAll(Arrays.asList(fileset.findMatchingPaths()));
  			}
  		}
  		else {
  			if (fileset.isInWorkspace())
  			{
  				files.add(fileset.getFile());
  			}
  			else {
  				files.add(fileset.getFilePath());
  			}
  		}
  		
  		return (Object[]) files.toArray(new Object[files.size()]);
  	}
  
  	public Object getParent(Object element) {
  		// TODO Auto-generated method stub
  		return null;
  	}
  
  	public boolean hasChildren(Object element) {
  		if (element instanceof IPackageNode)
  		{	
  			IPackageNode node = (IPackageNode) element;
  			if (node.getNodeType() == IPackageNode.TYPE_PACKAGE || node.getNodeType() == IPackageNode.TYPE_PACKAGE_FOLDER)
  			{
  				return node.hasChildren();
  			}
  			else {
  				IPackageFileSet fileset = (IPackageFileSet) node;
  				
  			}
  		}
  		return false;
  	}
  
  	public Object[] getElements(Object inputElement) {
  		if (inputElement instanceof Collection)
  		{
  			return ((Collection)inputElement).toArray();
  		}
  		else if (inputElement instanceof Object[])
  		{
  			return (Object[])inputElement;
  		}
  		else return new Object[]{ inputElement };
  	}
  
  	public void dispose() {
  		// TODO Auto-generated method stub
  		
  	}
  
  	public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
  		// TODO Auto-generated method stub
  		
  	}
  
  	
  }
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:42 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:42 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util
	...
Message-ID: <E1Gx7YQ-0003fv-L6@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:42

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util  
                        PackagesListenerProxy.java
  Added:       core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util  
                        PackagePreviewComposite.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.2       +8 -0      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util/PackagesListenerProxy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesListenerProxy.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util/PackagesListenerProxy.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- PackagesListenerProxy.java	15 Nov 2006 03:36:32 -0000	1.1
  +++ PackagesListenerProxy.java	20 Dec 2006 19:56:42 -0000	1.2
  @@ -13,6 +13,8 @@
   		public static final int ADDED = 0;
   		public static final int REMOVED = 1;
   		public static final int CHANGED = 2;
  +		public static final int ATTACHED = 3;
  +		
   		public IPackageNode node;
   		public int event;
   		public void run ()
  @@ -23,6 +25,7 @@
   				case ADDED: listener.packageNodeAdded(node); break;
   				case REMOVED: listener.packageNodeRemoved(node); break;
   				case CHANGED: listener.packageNodeChanged(node); break;
  +				case ATTACHED: listener.packageNodeAttached(node); break;
   				}
   			}
   			
  @@ -54,4 +57,9 @@
   		Display.getDefault().syncExec(internalListener);
   	}
   
  +	public void packageNodeAttached(IPackageNode attached) {
  +		internalListener.node = attached;
  +		internalListener.event = Listener.ATTACHED;
  +		Display.getDefault().syncExec(internalListener);
  +	}
   }
  
  
  
  1.1      date: 2006/12/20 19:56:42;  author: mculpepper;  state: Exp;jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util/PackagePreviewComposite.java
  
  Index: PackagePreviewComposite.java
  ===================================================================
  package org.jboss.ide.eclipse.packages.ui.util;
  
  import org.eclipse.swt.SWT;
  import org.eclipse.swt.widgets.Composite;
  
  public class PackagePreviewComposite extends Composite {
  
  	public PackagePreviewComposite (Composite parent, int style)
  	{
  		super(parent, style);
  	}
  	
  	public PackagePreviewComposite (Composite parent)
  	{
  		this(parent, SWT.NONE);
  	}
  	
  	
  }
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:42 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:42 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views
	...
Message-ID: <E1Gx7YQ-0003g2-Pn@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:42

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views 
                        ProjectPackagesView.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.8       +6 -7      jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views/ProjectPackagesView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProjectPackagesView.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views/ProjectPackagesView.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ProjectPackagesView.java	6 Dec 2006 17:02:58 -0000	1.7
  +++ ProjectPackagesView.java	20 Dec 2006 19:56:42 -0000	1.8
  @@ -34,7 +34,6 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFolderWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
   import org.jboss.ide.eclipse.packages.core.model.IPackagesModelListener;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  @@ -316,9 +315,7 @@
   		{
   			IPackageNode selected = getSelectedNode();
   			IPackageFolder folder = PackagesCore.createPackageFolder(selected.getProject());
  -			IPackageFolderWorkingCopy folderWC = folder.createFolderWorkingCopy();
  -			folderWC.setName(dialog.getValue());
  -			folder = folderWC.saveFolder();
  +			folder.setName(dialog.getValue());
   			
   			selected.addChild(folder);
   		}
  @@ -365,9 +362,7 @@
   				int response = dialog.open();
   				if (response == Dialog.OK)
   				{
  -					IPackageFolderWorkingCopy wc = folder.createFolderWorkingCopy();
  -					wc.setName(dialog.getValue());
  -					wc.save();
  +					folder.setName(dialog.getValue());
   				}
   			}
   		}
  @@ -436,6 +431,10 @@
   		}
   	}
   	
  +	public void packageNodeAttached(IPackageNode attached) {
  +		packageNodeAdded(attached);
  +	}
  +	
   	public IProject getCurrentProject ()
   	{
   		return currentProject;
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:43 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:43 -0500
Subject: [jboss-cvs]
	jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test
	...
Message-ID: <E1Gx7YR-0003gF-QP@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:43

  Modified:    core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test  
                        AllTests.java PackagesEARTest.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.3       +1 -2      jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/AllTests.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AllTests.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/AllTests.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- AllTests.java	4 Dec 2006 22:21:28 -0000	1.2
  +++ AllTests.java	20 Dec 2006 19:56:43 -0000	1.3
  @@ -9,9 +9,8 @@
   	{
   		TestSuite suite = new TestSuite();
   		suite.addTest(new PackagesEARTest("testCorrectBinding"));
  -		suite.addTest(new PackagesEARTest("testModelBridge"));
  +		suite.addTest(new PackagesEARTest("testModel"));
   		suite.addTest(new PackagesEARTest("testSave"));
  -		suite.addTest(new PackagesEARTest("testWorkingCopies"));
   		suite.addTest(new PackagesEARTest("testBuild"));
   		suite.addTest(new PackagesEARTest("testJARDefaultConfig"));
   		
  
  
  
  1.4       +23 -25    jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/PackagesEARTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesEARTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/PackagesEARTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PackagesEARTest.java	4 Dec 2006 22:21:28 -0000	1.3
  +++ PackagesEARTest.java	20 Dec 2006 19:56:43 -0000	1.4
  @@ -31,8 +31,6 @@
   
   import org.eclipse.core.resources.IFile;
   import org.eclipse.core.resources.IResource;
  -import org.eclipse.core.resources.IncrementalProjectBuilder;
  -import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.jdt.core.IJavaProject;
   import org.jboss.ide.eclipse.core.test.util.JavaProjectHelper;
  @@ -41,7 +39,6 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.core.model.internal.PackagesModel;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XMLBinding;
  @@ -223,7 +220,7 @@
   		}
   	}
   	
  -	public void testModelBridge ()
  +	public void testModel ()
   	{
   		PackagesModel.instance().registerProject(testPackagesProject.getProject(), new NullProgressMonitor());
   		List packages = PackagesModel.instance().getProjectPackages(testPackagesProject.getProject());
  @@ -235,7 +232,7 @@
   		assertEquals(earPackage.getProject(), testPackagesProject.getProject());
   		assertEquals(earPackage.getName(), "MyApp.ear");
   		assertEquals(earPackage.getNodeType(), IPackageNode.TYPE_PACKAGE);
  -		assertEquals(earPackage.getPackageType(), "j2ee.ear");
  +//		assertEquals(earPackage.getPackageType(), "j2ee.ear");
   		
   		IPackageFolder earPackageFolders[] = earPackage.getFolders();
   		assertNotNull(earPackageFolders);
  @@ -253,7 +250,7 @@
   		assertEquals(ejbJarPackage.getProject(), testPackagesProject.getProject());
   		assertEquals(ejbJarPackage.getName(), "MyEJBs.jar");
   		assertEquals(ejbJarPackage.getNodeType(), IPackageNode.TYPE_PACKAGE);
  -		assertEquals(ejbJarPackage.getPackageType(), "j2ee.ejbjar");
  +//		assertEquals(ejbJarPackage.getPackageType(), "j2ee.ejbjar");
   		
   		IPackageFileSet ejbJarFilesets[] = ejbJarPackage.getFileSets();
   		IPackageFolder ejbJarFolders[] = ejbJarPackage.getFolders();
  @@ -275,7 +272,7 @@
   		assertEquals(warPackage.getProject(), testPackagesProject.getProject());
   		assertEquals(warPackage.getName(), "MyApp.war");
   		assertEquals(warPackage.getNodeType(), IPackageNode.TYPE_PACKAGE);
  -		assertEquals(warPackage.getPackageType(), "j2ee.war");
  +//		assertEquals(warPackage.getPackageType(), "j2ee.war");
   		
   		IPackageFolder[] warFolders = warPackage.getFolders();
   		assertNotNull(warFolders);
  @@ -293,23 +290,6 @@
   		assertFileset(webInfFilesets[0], "descriptors", new String[] { "descriptors/web.xml","descriptors/jboss-web.xml"}, "*web.xml", null);
   	}
   	
  -	public void testWorkingCopies ()
  -	{
  -		List packages = PackagesModel.instance().getProjectPackages(testPackagesProject.getProject());
  -		assertEquals(packages.size(), 1);
  -		
  -		IPackage pkg = (IPackage) packages.get(0);
  -		assertNotNull(pkg);
  -		
  -		IPackageWorkingCopy wc = pkg.createPackageWorkingCopy();
  -		
  -		wc.setName("MyApp2.ear");	
  -		assertEquals(pkg.getName(), "MyApp.ear");
  -		wc.save();
  -		assertEquals(pkg.getName(), "MyApp2.ear");
  -		
  -	}
  -	
   	public void testSave()
   	{	
   		StringWriter writer = new StringWriter();
  @@ -332,7 +312,7 @@
   		IFile packageFile = pkg.getPackageFile();
   		
   		assertTrue(packageFile.exists());
  -		assertEquals(packageFile.getName(), "MyApp2.ear");
  +		assertEquals(packageFile.getName(), "MyApp.ear");
   		assertEquals(packageFile.getParent(), pkg.getDestinationContainer());
   		
   		de.schlichtherle.io.File packageZipFile = new de.schlichtherle.io.File(packageFile.getRawLocation().toString());
  @@ -388,4 +368,22 @@
   		assertTrue(jarFile.exists());
   		
   	}
  +	
  +	public void testDetachedNodes ()
  +	{
  +		NullProgressMonitor nullMonitor = new NullProgressMonitor();
  +		
  +		IPackage detachedPackage = PackagesCore.createDetachedPackage(testPackagesProject.getProject(), true);
  +		
  +		detachedPackage.setName("testPackagesProject.jar");
  +		detachedPackage.setPackageType(PackagesCore.getPackageType(JARPackageType.TYPE_ID));
  +		
  +		IPackageFileSet detachedFileset = PackagesCore.createDetachedPackageFileSet(testPackagesProject.getProject());
  +		detachedPackage.addChild(detachedFileset);
  +		
  +		IPackage[] packages = PackagesCore.getProjectPackages(testPackagesProject.getProject(), nullMonitor);
  +		int index = Arrays.binarySearch(packages, detachedPackage);
  +		
  +		assertTrue(index >= 0);
  +	}
   }
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:56:40 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:56:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal
	...
Message-ID: <E1Gx7YO-0003eq-LQ@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:56:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal      
                        PackagesModel.java PackageNodeImpl.java
                        PackageBuildDelegate.java PackageFolderImpl.java
                        PackageImpl.java PackageFileSetImpl.java
  Log:
  got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:
  
  pkg = PackagesCore.createDetachedPackage(project, true);
  pkg.setXXX..
  PackagesCore.attach(pkg, monitor);
  
  Revision  Changes    Path
  1.11      +102 -119  jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- PackagesModel.java	8 Dec 2006 16:45:50 -0000	1.10
  +++ PackagesModel.java	20 Dec 2006 19:56:40 -0000	1.11
  @@ -64,7 +64,6 @@
   	
   	public static final String PROJECT_PACKAGES_FILE = ".packages";
   	
  -	private Hashtable modelBridge;
   	private Hashtable projectPackages;
   	private Hashtable packageTypes;
   	private Hashtable xbPackages;
  @@ -74,7 +73,6 @@
   	 
   	private PackagesModel ()
   	{
  -		modelBridge = new Hashtable();
   		projectPackages = new Hashtable();
   		xbPackages = new Hashtable();
   		packageTypes = new Hashtable();
  @@ -150,10 +148,6 @@
   			if (getProjectPackages(pkg.getProject()).contains(pkg))
   				getProjectPackages(pkg.getProject()).remove(pkg);
   		}
  -		if (modelBridge.containsKey(pkg))
  -		{
  -			modelBridge.remove(pkg);
  -		}
   		if (xbPackages.containsKey(pkg.getProject()))
   		{
   			PackageImpl packageImpl = (PackageImpl) pkg;
  @@ -162,8 +156,8 @@
   			packages.removeChild(packageImpl.getNodeDelegate());
   		}
   		
  -		saveModel(pkg.getProject());
  -		fireNodeRemoved(pkg, true);
  +		saveModel(pkg.getProject(), null);
  +		fireNodeRemoved(pkg);
   	}
   	
   	public XbPackages getXbPackages(IProject project)
  @@ -264,59 +258,33 @@
   		}
   	}
   	
  -	protected void saveAndRegister (PackageNodeImpl node)
  -	{
  -		if (node.getNodeType() == IPackageNode.TYPE_PACKAGE)
  -		{
  -			PackageImpl pkg = (PackageImpl) node;
  -			if (pkg.isTopLevel())
  -			{
  -				XbPackages packages = getXbPackages(node.getProject());
  -				if (packages == null) {
  -					packages = new XbPackages();
  -					xbPackages.put(node.getProject(), packages);
  -				}
  -				
  -				if (packages.getChildren(XbPackage.class) == null || !packages.getChildren(XbPackage.class).contains(node.getNodeDelegate()))
  -				{	
  -					packages.addChild(node.getNodeDelegate());
  -				}
  -			}
  -		}
  -		
  -		if (!isPackageNodeRegistered(node)) {
  -			registerPackageNode(node, node.getNodeDelegate());
  -		}
  -		
  -		saveModel(node.getProject());
  -	}
  -	
   	protected void clearModel (IProject project)
   	{
   		List packages = getProjectPackages(project);
   		for (Iterator iter = packages.iterator(); iter.hasNext(); )
   		{
   			PackageImpl pkg = (PackageImpl) iter.next();
  -			unregisterPackageNode(pkg, pkg.getNodeDelegate());
  +			unregisterPackage(pkg);
   		}
   	}
   	
  -	protected void saveModel (IProject project)
  +	protected void saveModel (IProject project, IProgressMonitor monitor)
   	{
   		try {
  -			IProgressMonitor nullMonitor = new NullProgressMonitor();
  +			if (monitor == null)
  +				monitor = new NullProgressMonitor();
   			
   			ByteArrayOutputStream bytesOut = new ByteArrayOutputStream();
   			OutputStreamWriter writer = new OutputStreamWriter(bytesOut);
  -			XMLBinding.marshal(PackagesModel.instance().getXbPackages(project), writer, nullMonitor);
  +			XMLBinding.marshal(PackagesModel.instance().getXbPackages(project), writer, monitor);
   			writer.close();
   			
   			ByteArrayInputStream bytesIn = new ByteArrayInputStream(bytesOut.toByteArray());
   			IFile packagesFile = project.getFile(PackagesModel.PROJECT_PACKAGES_FILE);
   			if (!packagesFile.exists())
  -				packagesFile.create(bytesIn, true, nullMonitor);
  +				packagesFile.create(bytesIn, true, monitor);
   			else
  -				packagesFile.setContents(bytesIn, true, true, nullMonitor);
  +				packagesFile.setContents(bytesIn, true, true, monitor);
   			
   			bytesIn.close();
   			bytesOut.close();
  @@ -332,8 +300,6 @@
   			// TODO Auto-generated catch block
   			e.printStackTrace();
   		}
  -		
  -		
   	}
   	
   	protected PackageNodeImpl createPackageNodeImpl (IProject project, XbPackageNode node)
  @@ -362,14 +328,17 @@
   		{
   			XbPackageNode child = (XbPackageNode) iter.next();
   			
  -			// we don't need to do anything with child node impl's as they will 
  -			// be retrieved via lookup from the node delegates
  -			createPackageNodeImpl(project, child);
  -		}
  +			PackageNodeImpl childImpl = createPackageNodeImpl(project, child);
   		
   		if (nodeImpl != null)
   		{
  -			registerPackageNode(nodeImpl, node);
  +				nodeImpl.addChildImpl(childImpl);
  +			}
  +		}
  +		
  +		if (nodeImpl != null && nodeImpl.getNodeType() == IPackageNode.TYPE_PACKAGE)
  +		{
  +			registerPackage((PackageImpl)nodeImpl);
   		}
   		
   		return nodeImpl;
  @@ -409,8 +378,8 @@
   		});
   	}
   	
  -	protected void fireNodeRemoved (final IPackageNode removed, boolean force) {
  -		fireEvent(removed, force, new Runnable() {
  +	protected void fireNodeRemoved (final IPackageNode removed) {
  +		fireEvent(removed, new Runnable() {
   			public void run() {
   				for (Iterator iter = modelListeners.iterator(); iter.hasNext(); )
   				{
  @@ -420,9 +389,6 @@
   			}
   		});
   	}
  -	protected void fireNodeRemoved (final IPackageNode removed) {
  -		fireNodeRemoved(removed, false);
  -	}
   	
   	protected void fireNodeChanged (final IPackageNode changed)
   	{
  @@ -437,39 +403,29 @@
   		});
   	}
   	
  -	protected void fireEvent (IPackageNode source, boolean force, Runnable runnable) {
  -		if (!force && !modelBridge.containsKey(source)) //not registered in the model, no event should be broadcast
  -			return;
  -		
  -		if (projectBeingRegistered != null && source.getProject().equals(projectBeingRegistered))
  -			return;
  -		
  -		PackageNodeImpl nodeImpl = (PackageNodeImpl) source;
  -		if (!nodeImpl.isWorkingCopy())
  +	protected void fireNodeAttached (final IPackageNode attached)
   		{
  -			runnable.run();
  +		fireEvent(attached, new Runnable() {
  +			public void run ()
  +			{
  +				for (Iterator iter = modelListeners.iterator(); iter.hasNext(); )
  +				{
  +					IPackagesModelListener listener = (IPackagesModelListener) iter.next();
  +					listener.packageNodeAttached(attached);
   		}
   	}
  -	
  -	protected void fireEvent (IPackageNode source, Runnable runnable)
  -	{
  -		fireEvent(source, false, runnable);
  +		});
   	}
   	
  -	public boolean isPackageNodeRegistered (IPackageNode node)
  -	{
  -		return modelBridge.containsKey(node);
  -	}
  +	protected void fireEvent (IPackageNode source, Runnable runnable) {
  +		if (projectBeingRegistered != null && source.getProject().equals(projectBeingRegistered))
  +			return;
   	
  -	protected void registerPackageNode(PackageNodeImpl nodeImpl, XbPackageNode node)
  -	{
  -		if (!modelBridge.containsKey(nodeImpl))
  -		{
  -			modelBridge.put(nodeImpl, node);
  +		runnable.run();
  +	}
   			
  -			if (nodeImpl.getNodeType() == IPackageNode.TYPE_PACKAGE)
  +	protected void registerPackage (PackageImpl pkg)
   			{
  -				PackageImpl pkg = (PackageImpl) nodeImpl;
   				if (pkg.isTopLevel() && pkg.shouldParentBeNull()) {
   					if (!projectPackages.containsKey(pkg.getProject()))
   					{
  @@ -477,20 +433,24 @@
   					}
   					getProjectPackages(pkg.getProject()).add(pkg);
   				}
  -			}
   			
  -			fireNodeAdded(nodeImpl);
  -		}
  +		if (pkg.isTopLevel())
  +		{
  +			XbPackages packages = getXbPackages(pkg.getProject());
  +			if (packages == null) {
  +				packages = new XbPackages();
  +				xbPackages.put(pkg.getProject(), packages);
   	}
   	
  -	protected void unregisterPackageNode(PackageNodeImpl nodeImpl, XbPackageNode node) {
  -		if (modelBridge.containsKey(nodeImpl))
  +			if (packages.getChildren(XbPackage.class) == null || !packages.getChildren(XbPackage.class).contains(pkg.getNodeDelegate()))
   		{
  -			modelBridge.remove(nodeImpl);
  +				packages.addChild(pkg.getNodeDelegate());
  +			}
  +		}
  +	}
   		
  -			if (nodeImpl.getNodeType() == IPackageNode.TYPE_PACKAGE)
  +	protected void unregisterPackage (PackageImpl pkg)
   			{
  -				IPackage pkg = (IPackage) nodeImpl;
   				if (pkg.isTopLevel()) {
   					if (projectPackages.containsKey(pkg.getProject()))
   					{
  @@ -503,30 +463,53 @@
   				}
   			}
   			
  -			fireNodeRemoved(nodeImpl);
  -		}
  +	public IPackageType getPackageType (String packageType)
  +	{
  +		return (IPackageType) packageTypes.get(packageType);
   	}
   	
  -	protected PackageNodeImpl getPackageNodeImpl(XbPackageNode node)
  -	{
  -		for (Iterator iter = modelBridge.keySet().iterator(); iter.hasNext(); )
  +	public IPackage createDetachedPackage (IProject project, boolean isTopLevel)
   		{
  -			PackageNodeImpl nodeImpl = (PackageNodeImpl)iter.next();
  -			if (modelBridge.get(nodeImpl).equals(node))
  -			{
  -				return nodeImpl;
  -			}
  +		IPackage pkg = createPackage(project, isTopLevel);
  +		PackageImpl pkgImpl = (PackageImpl) pkg;
  +		
  +		pkgImpl.setDetached(true);
  +		return pkgImpl;
   		}
  -		return null;
  +
  +	public IPackageFolder createDetachedFolder (IProject project)
  +	{
  +		IPackageFolder folder = createPackageFolder(project);
  +		PackageFolderImpl folderImpl = (PackageFolderImpl) folder;
  +		
  +		folderImpl.setDetached(true);
  +		return folderImpl;
   	}
   	
  -	protected XbPackageNode getPackageNode(PackageNodeImpl nodeImpl)
  +	public IPackageFileSet createDetachedFileSet (IProject project)
   	{
  -		return (XbPackageNode) modelBridge.get(nodeImpl);
  +		IPackageFileSet fileset = createPackageFileSet(project);
  +		PackageFileSetImpl filesetImpl = (PackageFileSetImpl) fileset;
  +		
  +		filesetImpl.setDetached(true);
  +		return filesetImpl;
   	}
   
  -	public IPackageType getPackageType(String packageType)
  +	public void attach (IPackageNode nodeToAttach, IProgressMonitor monitor)
   	{
  -		return (IPackageType) packageTypes.get(packageType);
  +		PackageNodeImpl node = (PackageNodeImpl) nodeToAttach;
  +		
  +		if (node.isDetached())
  +		{
  +			node.setDetached(false);
  +			
  +			fireNodeAttached(node);
  +			if (node.getNodeType() == IPackageNode.TYPE_PACKAGE)
  +			{
  +				registerPackage((PackageImpl) node);
  +			}
  +			
  +			saveModel(node.getProject(), monitor);
  +		}
   	}
   }
  
  
  
  1.4       +66 -43    jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageNodeImpl.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PackageNodeImpl.java	6 Dec 2006 17:02:56 -0000	1.3
  +++ PackageNodeImpl.java	20 Dec 2006 19:56:40 -0000	1.4
  @@ -29,21 +29,21 @@
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.runtime.Assert;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeVisitor;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFileSet;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFolder;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackage;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackageNode;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackageNodeWithProperties;
  +import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackages;
   
  -public abstract class PackageNodeImpl implements IPackageNode, IPackageNodeWorkingCopy {
  +public abstract class PackageNodeImpl implements IPackageNode {
   
   	protected XbPackageNodeWithProperties nodeDelegate;
   	protected IProject project;
  -	protected ArrayList childrenToRegister, childrenToUnregister;
  -	protected boolean hasWorkingCopy;
  +	protected IPackageNode parent;
  +	protected ArrayList children;
  +	protected boolean detached, hasWorkingCopy;
   	
   	protected static int nodeTypeToIntType (Class type)
   	{
  @@ -70,9 +70,10 @@
   	{
   		nodeDelegate = delegate;
   		this.project = project;
  -		childrenToRegister = new ArrayList();
  -		childrenToUnregister = new ArrayList();
   		hasWorkingCopy = false;
  +		detached = false;
  +		
  +		children = new ArrayList();
   	}
   	
   	public PackageNodeImpl ()
  @@ -85,46 +86,51 @@
   		return nodeDelegate;
   	}
   	
  -	private IPackageNode[] nodesToChildren (List nodes)
  -	{
  -		IPackageNode children[] = new IPackageNode[nodes.size()];
  -		int i = 0;
  -		
  -		for (Iterator iter = nodes.iterator(); iter.hasNext();)
  +	public IPackageNode[] getAllChildren ()
   		{
  -			XbPackageNode node = (XbPackageNode) iter.next();
  -			children[i] = PackagesModel.instance().getPackageNodeImpl(node);
  -			i++;
  +		return (IPackageNode[]) children.toArray(new IPackageNode[children.size()]);
   		}
   		
  -		return children;
  -	}
  -	
  -	public IPackageNodeBase[] getAllChildren ()
  +	public IPackageNode[] getChildren(int type) {
  +		ArrayList typedChildren = new ArrayList();
  +		for (Iterator iter = children.iterator(); iter.hasNext(); )
  +		{
  +			IPackageNode child = (IPackageNode) iter.next();
  +			if (child.getNodeType() == type)
   	{
  -		return nodesToChildren(nodeDelegate.getAllChildren());
  +				typedChildren.add(child);
  +			}
   	}
   	
  -	public IPackageNodeBase[] getChildren(int type) {
  -		return nodesToChildren(nodeDelegate.getChildren(intTypeToNodeType(type)));
  +		return (IPackageNode[]) typedChildren.toArray(new IPackageNode[typedChildren.size()]);
   	}
   	
   	public boolean hasChildren () {
   		return nodeDelegate.hasChildren();
   	}
   	
  -	public boolean hasChild (IPackageNodeBase child)
  +	public boolean hasChild (IPackageNode child)
   	{
   		PackageNodeImpl childImpl = (PackageNodeImpl)child;
   		return nodeDelegate.getAllChildren().contains(childImpl.nodeDelegate);
   	}
   
  -	public IPackageNodeBase getParent() {
  -		XbPackageNode parent = nodeDelegate.getParent();
  -		if (parent != null)
  -			return PackagesModel.instance().getPackageNodeImpl(parent);
  +	public IPackageNode getParent() {
  +		return parent;
  +	}
   		
  -		return null;
  +	public void setParent (IPackageNode parent)
  +	{
  +		if (parent != null)
  +		{
  +			this.parent = parent;
  +			nodeDelegate.setParent(((PackageNodeImpl)parent).getNodeDelegate());
  +		}
  +		else if (getNodeType() == TYPE_PACKAGE) {
  +			this.parent = null;
  +			XbPackages packages = PackagesModel.instance().getXbPackages(getProject());
  +			nodeDelegate.setParent(packages);
  +		}
   	}
   
   	public IProject getProject() {
  @@ -148,7 +154,7 @@
   	}
   	
   	public boolean accept(IPackageNodeVisitor visitor, boolean depthFirst) {
  -		IPackageNodeBase children[] = getAllChildren();
  +		IPackageNode children[] = getAllChildren();
   		boolean keepGoing = true;
   		
   		if (!depthFirst)
  @@ -177,9 +183,21 @@
   		
   		nodeDelegate.addChild(impl.nodeDelegate);
   		
  -		PackagesModel.instance().saveModel(node.getProject());
  +		addChildImpl(impl);
  +		
  +		if (!detached)
  +		{
  +			PackagesModel.instance().saveModel(node.getProject(), null);
   		PackagesModel.instance().fireNodeAdded(node);
   	}
  +	}
  +	
  +	// convenience so we can skip adding in the delegate
  +	protected void addChildImpl (PackageNodeImpl childImpl)
  +	{
  +		children.add(childImpl);
  +		childImpl.setParent(this);
  +	}
   	
   	public void removeChild(IPackageNode node) {
   		Assert.isNotNull(node);
  @@ -190,9 +208,15 @@
   			nodeDelegate.removeChild(impl.nodeDelegate);
   		}
   		
  -		PackagesModel.instance().saveModel(node.getProject());
  +		if (children.contains(node))
  +			children.remove(node);
  +		
  +		if (!detached)
  +		{
  +			PackagesModel.instance().saveModel(node.getProject(), null);
   		PackagesModel.instance().fireNodeRemoved(node);
   	}
  +	}
   	
   	public Object getAdapter(Class adapter) {
   		if (adapter.equals(IProject.class))
  @@ -202,12 +226,11 @@
   		else return null;
   	}
   	
  -	public boolean isWorkingCopy ()
  -	{
  -		return getOriginal() != null;
  +	public boolean isDetached() {
  +		return detached;
   	}
   	
  -	protected void finalize() throws Throwable {
  -		if (getOriginal() != null) ((PackageNodeImpl)getOriginal()).hasWorkingCopy = false;
  +	public void setDetached(boolean detached) {
  +		this.detached = detached;
   	}
   }
  
  
  
  1.7       +7 -3      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageBuildDelegate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageBuildDelegate.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageBuildDelegate.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- PackageBuildDelegate.java	6 Dec 2006 17:02:56 -0000	1.6
  +++ PackageBuildDelegate.java	20 Dec 2006 19:56:40 -0000	1.7
  @@ -50,7 +50,6 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNodeVisitor;
   import org.jboss.ide.eclipse.packages.core.model.IPackagesBuildListener;
   import org.jboss.ide.eclipse.packages.core.model.IPackagesModelListener;
  @@ -104,6 +103,11 @@
   		nodesToRemove.add(removed);
   	}
   	
  +	public void packageNodeAttached(IPackageNode attached) {
  +		// TODO Auto-generated method stub
  +		
  +	}
  +	
   	private void fireStartedBuild (IProject project)
   	{
   		for (Iterator iter = PackagesModel.instance().getBuildListeners().iterator(); iter.hasNext(); )
  @@ -457,7 +461,7 @@
   		{
   			// Is this right?? Is the parent guarenteed to be a package?
   			for( int i = 0; i < filesets.length; i++ ) {
  -				IPackageNodeBase n = filesets[i].getParent();
  +				IPackageNode n = filesets[i].getParent();
   				if( n instanceof IPackage ) 
   					packagesBeingChanged.add(n);
   			}
  @@ -482,7 +486,7 @@
   	{
   		ArrayList parents = new ArrayList();
   		
  -		IPackageNodeBase parent = fileset.getParent();
  +		IPackageNode parent = fileset.getParent();
   		while (parent != null)
   		{
   			parents.add(0, parent);
  
  
  
  1.4       +6 -48     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFolderImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageFolderImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFolderImpl.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PackageFolderImpl.java	6 Dec 2006 17:02:56 -0000	1.3
  +++ PackageFolderImpl.java	20 Dec 2006 19:56:40 -0000	1.4
  @@ -27,23 +27,19 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFolderWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFolder;
   
   /**
    * A PackageFolderImpl.
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    */
   public class PackageFolderImpl extends PackageNodeImpl implements
  -		IPackageFolder, IPackageFolderWorkingCopy {
  +		IPackageFolder {
   
   	private XbFolder folderDelegate;
  -	private PackageFolderImpl original;
   	
   	public PackageFolderImpl(IProject project, XbFolder delegate)
   	{
  @@ -57,20 +53,20 @@
   	}
   
   	public IPackageFileSet[] getFileSets() {
  -		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FILESET);
  +		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FILESET);
   		IPackageFileSet filesets[] = new IPackageFileSet[nodes.length];
   		System.arraycopy(nodes, 0, filesets, 0, nodes.length);
   		return filesets;
   	}
   
   	public IPackageFolder[] getFolders() {
  -		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
  +		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
   		IPackageFolder folders[] = new IPackageFolder[nodes.length];
   		System.arraycopy(nodes, 0, folders, 0, nodes.length);
   		return folders;
   	}
   	public IPackage[] getPackages() {
  -		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE);
  +		IPackageNode nodes[] = getChildren(TYPE_PACKAGE);
   		IPackage pkgs[] = new IPackage[nodes.length];
   		System.arraycopy(nodes, 0, pkgs, 0, nodes.length);
   		return pkgs;
  @@ -96,48 +92,10 @@
   		folderDelegate.setName(name);
   	}
   
  -	public IPackageNodeWorkingCopy createWorkingCopy() {
  -		return createFolderWorkingCopy();
  -	}
  -	
  -	public IPackageFolderWorkingCopy createFolderWorkingCopy() {
  -		PackageFolderImpl copy = new PackageFolderImpl(project, new XbFolder(folderDelegate));
  -		copy.original = this;
  -		hasWorkingCopy = true;
  -		
  -		return copy;
  -	}
  -	
  -	public boolean hasWorkingCopy() {
  -		return hasWorkingCopy;
  -	}
  -
  -	public IPackageNode save() {
  -		return saveFolder();
  -	}
  -	
  -	public IPackageFolder saveFolder() {
  -		PackageFolderImpl originalImpl = (PackageFolderImpl) original;
  -		originalImpl.getFolderDelegate().copyFrom(folderDelegate);
  -
  -		PackagesModel.instance().saveAndRegister(original);		
  -		PackagesModel.instance().fireNodeChanged(original);
  -		original.hasWorkingCopy = false;
  -		return original;
  -	}
  -
  -	public IPackageNode getOriginal() {
  -		return getOriginalFolder();
  -	}
  -	
  -	public IPackageFolder getOriginalFolder() {
  -		return original;
  -	}
  -	
   	public IPath getPackageRelativePath() {
   		String path = new String(getName());
   		
  -		IPackageNodeBase parent = getParent(), save = null;
  +		IPackageNode parent = getParent(), save = null;
   		while (true) {
   			if (parent.getNodeType() == IPackageNode.TYPE_PACKAGE)
   				path = ((IPackage)parent).getName() + "/" + path;
  
  
  
  1.7       +6 -47     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- PackageImpl.java	6 Dec 2006 20:17:55 -0000	1.6
  +++ PackageImpl.java	20 Dec 2006 19:56:40 -0000	1.7
  @@ -35,9 +35,6 @@
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
   import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeBase;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackage;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbPackages;
   import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  @@ -46,12 +43,11 @@
    * A Package.
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
  -public class PackageImpl extends PackageNodeImpl implements IPackage, IPackageWorkingCopy {
  +public class PackageImpl extends PackageNodeImpl implements IPackage {
   
   	private XbPackage packageDelegate;
  -	private PackageImpl original;
   	private boolean parentShouldBeNull;
   	
   	public PackageImpl(IProject project, XbPackage delegate)
  @@ -90,14 +86,14 @@
   	}
   
   	public IPackageFileSet[] getFileSets() {
  -		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FILESET);
  +		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FILESET);
   		IPackageFileSet filesets[] = new IPackageFileSet[nodes.length];
   		System.arraycopy(nodes, 0, filesets, 0, nodes.length);
   		return filesets;
   	}
   
   	public IPackageFolder[] getFolders() {
  -		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
  +		IPackageNode nodes[] = getChildren(TYPE_PACKAGE_FOLDER);
   		IPackageFolder folders[] = new IPackageFolder[nodes.length];
   		System.arraycopy(nodes, 0, folders, 0, nodes.length);
   		return folders;
  @@ -108,7 +104,7 @@
   	}
   
   	public IPackage[] getPackages() {
  -		IPackageNodeBase nodes[] = getChildren(TYPE_PACKAGE);
  +		IPackageNode nodes[] = getChildren(TYPE_PACKAGE);
   		IPackage pkgs[] = new IPackage[nodes.length];
   		System.arraycopy(nodes, 0, pkgs, 0, nodes.length);
   		return pkgs;
  @@ -163,35 +159,6 @@
   		return packageDelegate.getManifest() != null;
   	}
   	
  -	public IPackageNodeWorkingCopy createWorkingCopy() {
  -		return createPackageWorkingCopy();
  -	}
  -	
  -	public IPackageWorkingCopy createPackageWorkingCopy() {
  -		PackageImpl copy = new PackageImpl(project, new XbPackage(packageDelegate));
  -		copy.original = this;
  -		hasWorkingCopy = true;
  -		return copy;
  -	}
  -
  -	public boolean hasWorkingCopy() {
  -		return hasWorkingCopy;
  -	}
  -	
  -	public IPackageNode save() {
  -		return savePackage();
  -	}
  -	
  -	public IPackage savePackage() {
  -		PackageImpl originalImpl = (PackageImpl) original;
  -		originalImpl.getPackageDelegate().copyFrom(packageDelegate);
  -		
  -		PackagesModel.instance().saveAndRegister(original);
  -		PackagesModel.instance().fireNodeChanged(original);
  -		original.hasWorkingCopy = false;
  -		return original;
  -	}
  -
   	public void addFileSet(IPackageFileSet fileset) {
   		addChild(fileset);
   	}
  @@ -233,20 +200,12 @@
   		packageDelegate.setPackageType(type.getId());
   	}
   	
  -	public IPackageNode getOriginal() {
  -		return getOriginalPackage();
  -	}
  -	
  -	public IPackage getOriginalPackage() {
  -		return original;
  -	}
  -	
   	public IPath getPackageRelativePath() {
   		if (getParent() == null) return null;
   		
   		String path = new String(getName());
   		
  -		IPackageNodeBase parent = getParent(), save = null;
  +		IPackageNode parent = getParent(), save = null;
   		while (true) {
   			if (parent.getNodeType() == IPackageNode.TYPE_PACKAGE)
   				path = ((IPackage)parent).getName() + "/" + path;
  
  
  
  1.3       +2 -43     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFileSetImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackageFileSetImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFileSetImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PackageFileSetImpl.java	8 Nov 2006 19:54:41 -0000	1.2
  +++ PackageFileSetImpl.java	20 Dec 2006 19:56:40 -0000	1.3
  @@ -30,9 +30,6 @@
   import org.eclipse.core.runtime.IPath;
   import org.eclipse.core.runtime.Path;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFileSetWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNodeWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   import org.jboss.ide.eclipse.packages.core.model.internal.xb.XbFileSet;
   
  @@ -40,13 +37,12 @@
    * A PackageFileSetImpl.
    * 
    * @author <a href="marshall at jboss.org">Marshall Culpepper</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public class PackageFileSetImpl extends PackageNodeImpl implements
  -		IPackageFileSet, IPackageFileSetWorkingCopy {
  +		IPackageFileSet {
   
   	private XbFileSet filesetDelegate;
  -	private PackageFileSetImpl original;
   	
   	public PackageFileSetImpl (IProject project, XbFileSet delegate)
   	{
  @@ -269,43 +265,6 @@
   		filesetDelegate.setProject(project.getName());
   	}
   
  -	public IPackageNodeWorkingCopy createWorkingCopy() {
  -		return createFileSetWorkingCopy();
  -	}
  -	
  -	public IPackageFileSetWorkingCopy createFileSetWorkingCopy() {
  -		PackageFileSetImpl copy = new PackageFileSetImpl(project, new XbFileSet(filesetDelegate));
  -		copy.original = this;
  -		hasWorkingCopy = true;
  -		return copy;
  -	}
  -	
  -	public boolean hasWorkingCopy() {
  -		return hasWorkingCopy;
  -	}
  -	
  -	public IPackageNode save() {
  -		return saveFileSet();
  -	}
  -	
  -	public IPackageFileSet saveFileSet() {
  -		PackageFileSetImpl originalImpl = (PackageFileSetImpl) original;
  -		originalImpl.getFileSetDelegate().copyFrom(filesetDelegate);
  -		
  -		PackagesModel.instance().saveAndRegister(original);
  -		PackagesModel.instance().fireNodeChanged(original);
  -		original.hasWorkingCopy = false;
  -		return original;
  -	}
  -	
  -	public IPackageNode getOriginal() {
  -		return getOriginalFileSet();
  -	}
  -	
  -	public IPackageFileSet getOriginalFileSet() {
  -		return original;
  -	}
  -
   	protected XbFileSet getFileSetDelegate () {
   		return filesetDelegate;
   	}
  
  
  


From mculpepper at jboss.com  Wed Dec 20 14:57:35 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 14:57:35 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/META-INF ...
Message-ID: <E1Gx7ZH-0003gV-OY@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 14:57:35

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/META-INF 
                        MANIFEST.MF
  Log:
  re-exporting the ant dependency and the truezip classes now
  
  Revision  Changes    Path
  1.4       +23 -2     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/META-INF/MANIFEST.MF,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MANIFEST.MF	20 Nov 2006 21:06:48 -0000	1.3
  +++ MANIFEST.MF	20 Dec 2006 19:57:35 -0000	1.4
  @@ -9,14 +9,35 @@
   Require-Bundle: org.eclipse.core.runtime,
    org.eclipse.core.resources,
    org.eclipse.core.filesystem,
  - org.apache.ant,
  + org.apache.ant;visibility:=reexport,
    org.jboss.ide.eclipse.core,
    org.eclipse.ant.core,
    org.apache.jakarta_log4j,
    org.eclipse.core.commands,
    org.eclipse.jdt.core
   Eclipse-LazyStart: true
  -Export-Package: org.jboss.ide.eclipse.packages.core,
  +Export-Package: de.schlichtherle.crypto,
  + de.schlichtherle.crypto.generators,
  + de.schlichtherle.crypto.io,
  + de.schlichtherle.crypto.io.raes,
  + de.schlichtherle.crypto.modes,
  + de.schlichtherle.io,
  + de.schlichtherle.io.archive,
  + de.schlichtherle.io.archive.spi,
  + de.schlichtherle.io.archive.tar,
  + de.schlichtherle.io.archive.zip,
  + de.schlichtherle.io.archive.zip.raes,
  + de.schlichtherle.io.rof,
  + de.schlichtherle.io.swing,
  + de.schlichtherle.io.swing.tree,
  + de.schlichtherle.io.util,
  + de.schlichtherle.key,
  + de.schlichtherle.key.passwd.swing,
  + de.schlichtherle.nio.charset,
  + de.schlichtherle.nio.charset.spi,
  + de.schlichtherle.util,
  + de.schlichtherle.util.zip,
  + org.jboss.ide.eclipse.packages.core,
    org.jboss.ide.eclipse.packages.core.model,
    org.jboss.ide.eclipse.packages.core.model.internal,
    org.jboss.ide.eclipse.packages.core.model.internal.xb,
  
  
  


From mculpepper at jboss.com  Wed Dec 20 15:31:43 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 15:31:43 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types
	...
Message-ID: <E1Gx86J-0004PC-EF@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 15:31:43

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types  
                        JARPackageType.java IPackageType.java
  Log:
  added getSupportFor so we can prompt users if/when a project that might need extra setup can be  determined
  
  Revision  Changes    Path
  1.5       +11 -1     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JARPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- JARPackageType.java	20 Dec 2006 19:56:40 -0000	1.4
  +++ JARPackageType.java	20 Dec 2006 20:31:43 -0000	1.5
  @@ -15,7 +15,7 @@
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   
   /**
  - * The default JAR package type will simply jar-up all the classes in a project's output directory, and place it in the top-level of the project.
  + * The default JAR package type will simply jar-up all the classes in a java project's output directory, and place it in the top-level of the project.
    * The name of the resulting JAR will be the project's name followed by a ".jar" extension.
    * @author Marshall
    */
  @@ -63,4 +63,14 @@
   		
   		return jar;
   	}
  +	
  +	public int getSupportFor(IProject project) {
  +		IJavaProject javaProject = JavaCore.create(project);
  +		
  +		if (javaProject == null)
  +		{
  +			return SUPPORT_NONE;
  +		}
  +		return SUPPORT_FULL;
  +	}
   }
  
  
  
  1.2       +23 -0     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/IPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/IPackageType.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IPackageType.java	20 Nov 2006 21:06:03 -0000	1.1
  +++ IPackageType.java	20 Dec 2006 20:31:43 -0000	1.2
  @@ -15,6 +15,21 @@
   public interface IPackageType {
   
   	/**
  +	 * Represents full support for a project
  +	 */
  +	public static final int SUPPORT_FULL = 0;
  +	
  +	/**
  +	 * Represents no support for a project
  +	 */
  +	public static final int SUPPORT_NONE = 1;
  +	
  +	/**
  +	 * Represents conditional support for a project
  +	 */
  +	public static final int SUPPORT_CONDITIONAL = 2;
  +	
  +	/**
   	 * @return The ID for this PackageType, i.e. "jar", "war" etc
   	 */
   	public String getId();
  @@ -34,4 +49,12 @@
   	 */
   	public IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor);
   	
  +	/**
  +	 * This will return the type of support this package type has for the passed in project.
  +	 * The type of support can be FULL (should be no problems), NONE (this project is not supported),
  +	 *  or CONDITIONAL (there might be some user input needed before the project supports this package type)
  +	 * @param project The project to check
  +	 * @return The support type this package type has for the project
  +	 */
  +	public int getSupportFor (IProject project);
   }
  
  
  


From mculpepper at jboss.com  Wed Dec 20 15:32:20 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 15:32:20 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards
	...
Message-ID: <E1Gx86u-0004QD-TE@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 15:32:20

  Modified:    core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards 
                        WizardWithNotification.java
  Log:
  added "FINISH" constant
  
  Revision  Changes    Path
  1.2       +1 -0      jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardWithNotification.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WizardWithNotification.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardWithNotification.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- WizardWithNotification.java	6 Dec 2006 19:24:35 -0000	1.1
  +++ WizardWithNotification.java	20 Dec 2006 20:32:20 -0000	1.2
  @@ -36,6 +36,7 @@
   public abstract class WizardWithNotification extends Wizard implements IPageChangedListener {
   	public static final int NEXT = 1;
   	public static final int PREVIOUS = 2;
  +	public static final int FINISH = 3;
   	public static final int UNKNOWN = 4;
   	
   	
  
  
  


From mculpepper at jboss.com  Wed Dec 20 15:43:47 2006
From: mculpepper at jboss.com (Marshall Culpepper)
Date: Wed, 20 Dec 2006 15:43:47 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types
	...
Message-ID: <E1Gx8Hz-0004aa-Ub@committer01.frg.pub.inap.atl.jboss.com>

  User: mculpepper
  Date: 06/12/20 15:43:47

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types 
                        JARPackageType.java
  Log:
  changed getSupportFor to check for nature instead of using JavaCore.create
  
  Revision  Changes    Path
  1.6       +11 -5     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JARPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- JARPackageType.java	20 Dec 2006 20:31:43 -0000	1.5
  +++ JARPackageType.java	20 Dec 2006 20:43:47 -0000	1.6
  @@ -3,12 +3,14 @@
   import org.eclipse.core.resources.IContainer;
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.runtime.Assert;
  +import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IPath;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.jdt.core.IJavaProject;
   import org.eclipse.jdt.core.JavaCore;
   import org.eclipse.jdt.core.JavaModelException;
  +import org.jboss.ide.eclipse.core.util.ProjectUtil;
   import org.jboss.ide.eclipse.packages.core.Trace;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  @@ -65,12 +67,16 @@
   	}
   	
   	public int getSupportFor(IProject project) {
  -		IJavaProject javaProject = JavaCore.create(project);
   		
  -		if (javaProject == null)
  +		try {
  +			if (project.hasNature(JavaCore.NATURE_ID))
   		{
  -			return SUPPORT_NONE;
  -		}
   		return SUPPORT_FULL;
   	}
  +		} catch (CoreException e) {
  +			Trace.trace(getClass(), e);
  +		}
  +		
  +		return SUPPORT_NONE;
  +	}
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 15:49:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 15:49:42 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1842 - trunk
Message-ID: <E1Gx8Ni-0004eu-9O@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-20 15:49:40 -0500 (Wed, 20 Dec 2006)
New Revision: 1842

Modified:
   trunk/build-messaging.xml
Log:
preparing beta2

Modified: trunk/build-messaging.xml
===================================================================
--- trunk/build-messaging.xml	2006-12-20 12:19:54 UTC (rev 1841)
+++ trunk/build-messaging.xml	2006-12-20 20:49:40 UTC (rev 1842)
@@ -49,9 +49,9 @@
    <property name="messaging.version.minor" value="2"/>
    <property name="messaging.version.revision" value="0"/>
    <property name="messaging.version.incrementing" value="8"/>
-   <property name="messaging.version.tag" value="Beta1"/>
-   <property name="messaging.version.name" value="Berlin"/>
-   <property name="messaging.version.cvstag" value="JBossMessaging_1_2_0_Beta1"/>
+   <property name="messaging.version.tag" value="Beta2"/>
+   <property name="messaging.version.name" value="Alkali"/>
+   <property name="messaging.version.cvstag" value="JBossMessaging_1_2_0_Beta2"/>
    <property name="module.name" value="messaging"/>
    <property name="module.Name" value="JBoss Messaging"/>
    <property name="module.version" value="${messaging.version.major}.${messaging.version.minor}.${messaging.version.revision}.${messaging.version.tag}"/>



From brian.stansberry at jboss.com  Wed Dec 20 16:26:16 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Wed, 20 Dec 2006 16:26:16 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1Gx8x6-0005QK-L9@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/20 16:26:16

  Modified:    src/org/jboss/cache/interceptors  Tag:
                        Branch_JBossCache_1_4_0 TxInterceptor.java
  Log:
  Prevent NPE in cleanupStaleLocks
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.48.2.11 +2 -1      JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java,v
  retrieving revision 1.48.2.10
  retrieving revision 1.48.2.11
  diff -u -b -r1.48.2.10 -r1.48.2.11
  --- TxInterceptor.java	13 Nov 2006 13:00:03 -0000	1.48.2.10
  +++ TxInterceptor.java	20 Dec 2006 21:26:16 -0000	1.48.2.11
  @@ -776,6 +776,7 @@
       private void cleanupStaleLocks(GlobalTransaction gtx) throws Throwable
       {
           TransactionEntry entry = txTable.get(gtx);
  +        if (entry != null)
           entry.releaseAllLocksLIFO(gtx);
       }
   
  
  
  


From dg98asdf4a at kittymail.com  Wed Dec 20 17:11:09 2006
From: dg98asdf4a at kittymail.com (dg98asdf4a at kittymail.com)
Date: Wed, 20 Dec 2006 17:11:09 -0500
Subject: [jboss-cvs] =?utf-8?b?wpXCgsKLQ8KCw4HCgsOEwoLDosKCw4HCgsOPwoI=?=
	=?utf-8?b?w6jCgsK+woLDn8KCw4XCgsK3woLCqcKBSA==?=
Message-ID: 20061221073822.35642mail@mail.ertoiluerituruwelroiewtitrirt197179680.com

?????????????????l?X???????`???????????B??????????????
?????????M?????????????`?????????????????????H????????
???????????o???????K?????????????o???????B????????????
???????????????M?????????????????????H????????????????

http://www.freeweb.allfreemail.net.tonderuyo.com/hw/

-------------------------------------------------
???T?C?g???????C???????l?????A???????l?????o?????????j????
?X???[?Y???o???????????????????????????B

http://www.freeweb.allfreemail.net.tonderuyo.com/hw/

-------------------------------------------------

?????????????????w?o?????v?????A???????????????????????B
???????????]?????????l???????X???A?h?????Q???????????B

?u???????????????A?y?????????????????B?v45???@???????w
?u???????????????????????????U???????????B?v34???@???????w
?u???C???]???????????B?g?????l???????
???????????????????????????B?v36???@?o??
?u???l???o?????w?Y???????????x???J?????????????B???l?????????????????B?v40???@???????w

http://www.freeweb.allfreemail.net.tonderuyo.com/hw/

-------------------------------------------------

?u???C?????????????_???H?v
?l?????{???????????????????B
???????????????????????B?C???????????????????????????B

?p?F???C???????????????A?????v?????????H
38???F???x???o?????????????????@
27???F?o???????????????????@
20???F?????????????????????????@
15???F???????i?~?????????????????????j?@

http://www.freeweb.allfreemail.net.tonderuyo.com/hw/

-------------------------------------------------

?????????o?^???w?l???????x?????B
???????o???????T???????????????????????????????????o???????????????????????B

http://www.freeweb.allfreemail.net.tonderuyo.com/hw/



From vladimir.blagojevic at jboss.com  Wed Dec 20 17:27:08 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Wed, 20 Dec 2006 17:27:08 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gx9u0-0006aw-Iu@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/20 17:27:08

  Modified:    src/org/jboss/cache  NodeImpl.java
  Log:
  fix NPE
  
  Revision  Changes    Path
  1.28      +15 -1     JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- NodeImpl.java	20 Dec 2006 16:04:02 -0000	1.27
  +++ NodeImpl.java	20 Dec 2006 22:27:08 -0000	1.28
  @@ -799,7 +799,21 @@
   
      public Set<Node> getChildren(boolean includeMarkedForRemoval)
      {
  -      return includeMarkedForRemoval ? new HashSet<Node>(children.values()) : getChildren();
  +      if (includeMarkedForRemoval)
  +      {
  +         if (children != null && !children.isEmpty())
  +         {
  +            return new HashSet<Node>(children.values());
  +         }
  +         else
  +         {
  +            return new HashSet<Node>();
  +         }
  +      }
  +      else
  +      {
  +         return getChildren();
  +      }
      }
   
      public synchronized Map<Object, Object> getRawData()
  
  
  


From vladimir.blagojevic at jboss.com  Wed Dec 20 17:28:13 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Wed, 20 Dec 2006 17:28:13 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1Gx9v3-0006bD-0N@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/20 17:28:13

  Modified:    src/org/jboss/cache/marshall  MethodDeclarations.java
  Log:
  final state transfer refactoring
  
  Revision  Changes    Path
  1.27      +2 -7      JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodDeclarations.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- MethodDeclarations.java	20 Dec 2006 04:02:09 -0000	1.26
  +++ MethodDeclarations.java	20 Dec 2006 22:28:12 -0000	1.27
  @@ -31,7 +31,7 @@
    * allowing lookup operations both ways.
    *
    * @author <a href="galder.zamarreno at jboss.com">Galder Zamarreno</a>
  - * @version $Revision: 1.26 $
  + * @version $Revision: 1.27 $
    */
   public class MethodDeclarations
   {
  @@ -96,8 +96,6 @@
   
      public static final Method optimisticPrepareMethod;
   
  -   public static final Method getPartialStateMethod;
  -
      public static final Method clusteredGetMethod;
   
      public static final Method remoteAssignToBuddyGroupMethod;
  @@ -251,8 +249,6 @@
   
            optimisticPrepareMethod = TreeCache.class.getDeclaredMethod("optimisticPrepare", GlobalTransaction.class, List.class, Map.class, Address.class, boolean.class);
   
  -         getPartialStateMethod = TreeCache.class.getDeclaredMethod("_getState", Fqn.class, long.class, boolean.class, boolean.class);
  -
            clusteredGetMethod = TreeCache.class.getDeclaredMethod("_clusteredGet", MethodCall.class, Boolean.class);
   
            // ------------ buddy replication
  @@ -303,7 +299,6 @@
         methods.put(existsMethod_id, existsMethod);
         methods.put(releaseAllLocksMethodLocal_id, releaseAllLocksMethodLocal);
         methods.put(optimisticPrepareMethod_id, optimisticPrepareMethod);
  -      methods.put(getPartialStateMethod_id, getPartialStateMethod);
         methods.put(clusteredGetMethod_id, clusteredGetMethod);
         methods.put(getChildrenNamesMethodLocal_id, getChildrenNamesMethodLocal);
         methods.put(getDataMapMethodLocal_id, getDataMapMethodLocal);
  
  
  


From vladimir.blagojevic at jboss.com  Wed Dec 20 17:28:13 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Wed, 20 Dec 2006 17:28:13 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1Gx9v3-0006bK-4F@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/20 17:28:13

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  final state transfer refactoring
  
  Revision  Changes    Path
  1.50      +19 -2     JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.49
  retrieving revision 1.50
  diff -u -b -r1.49 -r1.50
  --- BuddyManager.java	8 Dec 2006 18:49:18 -0000	1.49
  +++ BuddyManager.java	20 Dec 2006 22:28:13 -0000	1.50
  @@ -21,10 +21,12 @@
   import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.marshall.VersionAwareMarshaller;
   import org.jboss.cache.statetransfer.StateTransferManager;
  +import org.jboss.util.stream.MarshalledValueInputStream;
   import org.jgroups.Address;
   import org.jgroups.View;
   import org.jgroups.stack.IpAddress;
   
  +import java.io.ByteArrayInputStream;
   import java.util.ArrayList;
   import java.util.Arrays;
   import java.util.Collection;
  @@ -397,7 +399,22 @@
            {
               ClassLoader cl = (marshaller == null) ? null : marshaller.getClassLoader(fqnS);
               Fqn integrationRoot = new Fqn(integrationBase, fqn);
  -            stateMgr.setState((byte[]) entry.getValue(), integrationRoot, cl);
  +            
  +            byte [] stateBuffer = (byte[]) entry.getValue();
  +            MarshalledValueInputStream in = null;
  +            try
  +            {
  +               ByteArrayInputStream bais = new ByteArrayInputStream(stateBuffer);
  +               in = new MarshalledValueInputStream(bais);
  +               stateMgr.setState(in, integrationRoot, cl);
  +            }
  +            finally
  +            {
  +               if (in != null)
  +               {
  +                  in.close();
  +               }
  +            }
            }
         }
      }
  @@ -620,7 +637,7 @@
   
            try
            {
  -            byte[] state = cache._getState(fqn, timeouts[i], force, false);
  +            byte[] state = cache.generateState(fqn, timeouts[i], force, false);
               if (log.isDebugEnabled())
               {
                  log.debug("acquireState(): got state");
  
  
  


From vladimir.blagojevic at jboss.com  Wed Dec 20 17:28:13 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Wed, 20 Dec 2006 17:28:13 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer   ...
Message-ID: <E1Gx9v3-0006bU-9t@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/20 17:28:13

  Modified:    src/org/jboss/cache/statetransfer  
                        DefaultStateTransferIntegrator.java
                        StateTransferManager.java
  Log:
  final state transfer refactoring
  
  Revision  Changes    Path
  1.8       +2 -9      JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferIntegrator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- DefaultStateTransferIntegrator.java	14 Dec 2006 17:18:48 -0000	1.7
  +++ DefaultStateTransferIntegrator.java	20 Dec 2006 22:28:13 -0000	1.8
  @@ -64,16 +64,9 @@
         {
            cause = t;
            log.error("Failed integrating state.", t);
  -      }
  -      finally
  -      {
  -         ois.close();
  -         if (cause != null)
  -         {
               throw new Exception("State transfer failed ", cause);
            }
         }
  -   }
   
      protected void integrateTransientState(ObjectInputStream in, Node target, ClassLoader cl) throws Exception
      {
  
  
  
  1.18      +43 -134   JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- StateTransferManager.java	14 Dec 2006 17:18:48 -0000	1.17
  +++ StateTransferManager.java	20 Dec 2006 22:28:13 -0000	1.18
  @@ -18,14 +18,10 @@
   import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.lock.TimeoutException;
   import org.jboss.cache.marshall.VersionAwareMarshaller;
  -import org.jboss.cache.util.ExposedByteArrayOutputStream;
  -import org.jboss.util.stream.MarshalledValueInputStream;
  -import org.jboss.util.stream.MarshalledValueOutputStream;
   
  -import java.io.ByteArrayInputStream;
  -import java.io.InputStream;
   import java.io.ObjectInputStream;
  -import java.io.OutputStream;
  +import java.io.ObjectOutputStream;
  +
   
   public class StateTransferManager
   {
  @@ -33,42 +29,25 @@
   
      public static final NodeData STREAMING_DELIMETER_NODE = new NodeDataMarker();
   
  -
      public static final String PARTIAL_STATE_DELIMETER = "_PARTIAL_STATE_DELIMETER";
   
  -   private TreeCache treeCache;
  -   private long[] loadStateTimeouts = {400, 800, 1200};
  +   private final TreeCache cache;
   
      public StateTransferManager(TreeCache cache)
      {
  -      this.treeCache = cache;
  +      this.cache = cache;
      }
   
      public TreeCache getTreeCache()
      {
  -      return treeCache;
  -   }
  -
  -   public void setTreeCache(TreeCache cache)
  -   {
  -      this.treeCache = cache;
  -   }
  -
  -   public long[] getLoadStateTimeouts()
  -   {
  -      return loadStateTimeouts;
  -   }
  -
  -   public void setLoadStateTimeouts(long[] loadStateTimeouts)
  -   {
  -      this.loadStateTimeouts = loadStateTimeouts;
  +      return cache;
      }
   
      /**
  -    * Returns the state for the portion of the tree named by <code>fqn</code>.
  +    * Writes the state for the portion of the tree named by <code>fqn</code> to 
  +    * the provided OutputStream.
  +    * 
       * <p/>
  -    * State returned is a serialized byte[][], element 0 is the transient state
  -    * (or null), and element 1 is the persistent state (or null).
       *
       * @param fqn            Fqn indicating the uppermost node in the
       *                       portion of the tree whose state should be returned.
  @@ -83,85 +62,41 @@
       * @return a serialized byte[][], element 0 is the transient state
       *         (or null), and element 1 is the persistent state (or null).
       */
  -   public byte[] getState(OutputStream os, Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
  +   public void getState(ObjectOutputStream out, Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
      {
  -      boolean usingStreamingStateTransfer = os != null;
  -      TreeCache cache = getTreeCache();
  +      VersionAwareMarshaller marshaller = cache.getMarshaller();
   
  -      VersionAwareMarshaller marshaller_ = null;
  -      if (cache.getConfiguration().isUseRegionBasedMarshalling())
  -      {
  -         marshaller_ = cache.getMarshaller();
  -      }
  -
  -      if (marshaller_ != null)
  -      {
            // can't give state for regions currently being activated/inactivated
  -         if (marshaller_.isInactive(fqn.toString()))
  -         {
  -            if (log.isDebugEnabled())
  -            {
  -               log.debug("ignoring _getState() for " + fqn + " as it is being activated/inactivated");
  -            }
  -            if (usingStreamingStateTransfer)
  -            {
  -               MarshalledValueOutputStream out = new MarshalledValueOutputStream(os);
  -               out.writeBoolean(false);
  -               out.close();
  -            }
  -            return null;
  -         }
  -      }
  -
  -      Node rootNode = cache.findNode(fqn);
  -      if (rootNode == null)
  -      {
  -         return null;
  -      }
  +      boolean canProvideState = !(marshaller.isInactive(fqn.toString()) || cache.findNode(fqn) == null);
   
         boolean fetchTransientState = cache.getConfiguration().isFetchInMemoryState();
         CacheLoaderManager cacheLoaderManager = cache.getCacheLoaderManager();
         boolean fetchPersistentState = cacheLoaderManager != null && cacheLoaderManager.isFetchPersistentState();
   
  +      if (canProvideState && (fetchPersistentState || fetchTransientState))
  +      {
  +         out.writeBoolean(true);
  +         StateTransferGenerator generator = getStateTransferGenerator();
         Object owner = getOwnerForLock();
  +         long startTime = System.currentTimeMillis();
  +         Node rootNode = cache.findNode(fqn);
   
         try
         {
  -         if (fetchTransientState || fetchPersistentState)
  -         {
               log.info("locking the " + fqn + " subtree to return the in-memory (transient) state");
               acquireLocksForStateTransfer(rootNode, owner, timeout, true, force);
  -         }
  -
  -         MarshalledValueOutputStream out = null;
  -         byte resultBuffer[] = new byte[0];
  -         StateTransferGenerator generator = getStateTransferGenerator();
  -         long startTime = System.currentTimeMillis();
  -         if (usingStreamingStateTransfer)
  -         {
  -            out = new MarshalledValueOutputStream(os);
  -            out.writeBoolean(true);
               generator.generateState(out, rootNode, fetchTransientState, fetchPersistentState, suppressErrors);
  -         }
  -         else
  -         {
  -            ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
  -            out = new MarshalledValueOutputStream(baos);
  -            generator.generateState(out, rootNode, fetchTransientState, fetchPersistentState, suppressErrors);
  -            resultBuffer = baos.getRawBuffer();
  -         }
            log.info("Successfully generated state in " + (System.currentTimeMillis() - startTime) + " msec");
  -         return resultBuffer;
         }
         finally
         {
            releaseStateTransferLocks(rootNode, owner, true);
         }
      }
  -
  -   public byte[] getState(Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
  +      else
      {
  -      return getState(null, fqn, timeout, force, suppressErrors);
  +         out.writeBoolean(false);
  +      }
      }
   
      /**
  @@ -185,7 +120,7 @@
                            Object[] sources, ClassLoader cl)
              throws Exception
      {
  -      treeCache.fetchPartialState(sources, subtreeRoot, integrationRoot.getFqn());
  +      cache.fetchPartialState(sources, subtreeRoot, integrationRoot.getFqn());
      }
   
      /**
  @@ -204,8 +139,7 @@
       * @param cl         classloader to use to unmarshal the state, or
       *                   <code>null</code> if the TCCL should be used
       */
  -   public void setState(Object state, Fqn targetRoot, ClassLoader cl)
  -           throws Exception
  +   public void setState(ObjectInputStream state, Fqn targetRoot, ClassLoader cl) throws Exception
      {
         TreeCache cache = getTreeCache();
         Node target = cache.findNode(targetRoot);
  @@ -216,7 +150,6 @@
            cache.put(targetRoot, null);
            target = cache.findNode(targetRoot);
         }
  -
         setState(state, target, cl);
      }
   
  @@ -236,39 +169,16 @@
       * @param cl         classloader to use to unmarshal the state, or
       *                   <code>null</code> if the TCCL should be used
       */
  -   private void setState(Object state, Node targetRoot, ClassLoader cl)
  -           throws Exception
  -   {
  -      if (state == null)
  +   private void setState(ObjectInputStream state, Node targetRoot, ClassLoader cl) throws Exception
         {
  -         log.info("new_state is null (may be first member in cluster)");
  -         return;
  -      }
  -
  -      boolean usingStreamTransfer = (state instanceof InputStream) ? true : false;
  -
         Object owner = getOwnerForLock();
  +      long startTime = System.currentTimeMillis();
  +
         try
         {
            // Acquire a lock on the root node
  -         acquireLocksForStateTransfer(targetRoot, owner,
  -                 getTreeCache().getConfiguration().getInitialStateRetrievalTimeout(),
  -                 true, true);
  -
  -         StateTransferIntegrator integrator = null;
  -         MarshalledValueInputStream in = null;
  -         if (usingStreamTransfer)
  -         {
  -            in = (MarshalledValueInputStream) state;
  -         }
  -         else
  -         {
  -            ByteArrayInputStream bais = new ByteArrayInputStream((byte[]) state);
  -            in = new MarshalledValueInputStream(bais);
  -         }
  -
  -         integrator = getStateTransferIntegrator(in, targetRoot.getFqn());
  -         long startTime = System.currentTimeMillis();
  +         acquireLocksForStateTransfer(targetRoot, owner, getTreeCache().getConfiguration()
  +               .getInitialStateRetrievalTimeout(), true, true);
   
            /*
            * Vladimir/Manik/Brian (Dec 7,2006)
  @@ -281,12 +191,13 @@
   
            Option option = new Option();
            option.setBypassInterceptorChain(true);
  -         treeCache.getInvocationContext().setOptionOverrides(option);
  +         cache.getInvocationContext().setOptionOverrides(option);
   
            try
            {
  +            StateTransferIntegrator integrator = getStateTransferIntegrator(state, targetRoot.getFqn());
               log.info("starting state integration at node " + targetRoot);
  -            integrator.integrateState(in, targetRoot, cl);
  +            integrator.integrateState(state, targetRoot, cl);
               log.info("successfully integrated state in " + (System.currentTimeMillis() - startTime) + " msec");
            }
            catch (Throwable t)
  @@ -298,7 +209,6 @@
         {
            releaseStateTransferLocks(targetRoot, owner, true);
         }
  -
      }
   
   
  @@ -388,7 +298,6 @@
         {
            owner = Thread.currentThread();
         }
  -
         return owner;
      }
   }
  
  
  


From vladimir.blagojevic at jboss.com  Wed Dec 20 17:28:13 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Wed, 20 Dec 2006 17:28:13 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1Gx9v3-0006bb-FU@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/20 17:28:13

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  final state transfer refactoring
  
  Revision  Changes    Path
  1.298     +127 -72   JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.297
  retrieving revision 1.298
  diff -u -b -r1.297 -r1.298
  --- TreeCache.java	20 Dec 2006 16:04:02 -0000	1.297
  +++ TreeCache.java	20 Dec 2006 22:28:13 -0000	1.298
  @@ -39,6 +39,7 @@
   import org.jboss.cache.notifications.Notifier;
   import org.jboss.cache.optimistic.DataVersion;
   import org.jboss.cache.statetransfer.StateTransferManager;
  +import org.jboss.cache.util.ExposedByteArrayOutputStream;
   import org.jboss.cache.util.MapCopy;
   import org.jboss.util.stream.MarshalledValueInputStream;
   import org.jboss.util.stream.MarshalledValueOutputStream;
  @@ -58,6 +59,7 @@
   import org.jgroups.stack.IpAddress;
   import org.jgroups.util.Rsp;
   import org.jgroups.util.RspList;
  +import org.jgroups.util.Util;
   import org.w3c.dom.Element;
   
   import javax.management.MBeanServer;
  @@ -66,6 +68,8 @@
   import javax.transaction.SystemException;
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  +
  +import java.io.ByteArrayInputStream;
   import java.io.ByteArrayOutputStream;
   import java.io.IOException;
   import java.io.InputStream;
  @@ -95,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.297 2006/12/20 16:04:02 msurtani Exp $
  + * @version $Id: TreeCache.java,v 1.298 2006/12/20 22:28:13 vblagojevic Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1136,15 +1140,30 @@
       * @param suppressErrors should any Throwable thrown be suppressed?
       * @return a serialized byte[][], element 0 is the transient state
       *         (or null), and element 1 is the persistent state (or null).
  +    *         
  +    *         
  +    *TODO here only because of BuddyManager state transfer  
  +    *Consider for removal if BuddyManager transfer changes      
  +    *         
       */
  -   public byte[] _getState(Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
  +   public byte[] generateState(Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
      {
  -      return getStateTransferManager().getState(fqn, timeout, force, suppressErrors);
  -   }
   
  -   public void _getState(OutputStream os, Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
  +      MarshalledValueOutputStream out = null;
  +      byte[] result = null;
  +      try
  +      {
  +         ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
  +         out = new MarshalledValueOutputStream(baos);
  +         getStateTransferManager().getState(out, fqn, timeout, force, suppressErrors);
  +         result = baos.getRawBuffer();
  +      }
  +      finally
      {
  -      getStateTransferManager().getState(os, fqn, timeout, force, suppressErrors);
  +         Util.close(out);
  +      }
  +
  +      return result;
      }
   
      private void removeLocksForDeadMembers(Node node,
  @@ -3248,25 +3267,17 @@
            }
         }
   
  -      /**
  -       * Returns a copy of the current cache (tree). It actually returns a 2
  -       * element array of byte[], element 0 being the transient state (or null)
  -       * and element 1 being the persistent state (or null)
  -       */
         public byte[] getState()
         {
  +         MarshalledValueOutputStream out = null;
  +         byte[] result = null;
            try
            {
  -            //            // We use the lock acquisition timeout rather than the
  -            //            // state transfer timeout, otherwise we'd never try
  -            //            // to break locks before the requesting node gives up
  -            //            return cache._getState(Fqn.fromString(SEPARATOR),
  -            //               cache.getLockAcquisitionTimeout(),
  -            //               true,
  -            //               true);
  -            // Until flush is in place, use the old mechanism
  -            // where we wait the full state retrieval timeout
  -            return _getState(Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
  +            ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
  +            out = new MarshalledValueOutputStream(baos);
  +
  +            getStateTransferManager().getState(out,Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
  +            result = baos.getRawBuffer();
            }
            catch (Throwable t)
            {
  @@ -3275,8 +3286,12 @@
               my_log.error("Caught " + t.getClass().getName() +
                       " while responding to initial state transfer request;" +
                       " returning null", t);
  -            return null;
            }
  +         finally
  +         {
  +            Util.close(out);
  +         }
  +         return result;
         }
   
         public void setState(byte[] new_state)
  @@ -3286,9 +3301,16 @@
               my_log.debug("transferred state is null (may be first member in cluster)");
               return;
            }
  +         ByteArrayInputStream bais = new ByteArrayInputStream(new_state);
  +         MarshalledValueInputStream in = null;
            try
            {
  -            getStateTransferManager().setState(new_state, Fqn.ROOT, null);
  +            in = new MarshalledValueInputStream(bais);
  +            boolean hasState = in.readBoolean();
  +            if(hasState)
  +            {
  +               getStateTransferManager().setState(in, Fqn.ROOT, null);
  +            }
               isStateSet = true;
            }
            catch (Throwable t)
  @@ -3305,6 +3327,7 @@
            }
            finally
            {
  +            Util.close(in);
               synchronized (stateLock)
               {
                  // Notify wait that state has been set.
  @@ -3315,15 +3338,24 @@
   
         public byte[] getState(String state_id)
         {
  +         MarshalledValueOutputStream out = null;
            String sourceRoot = state_id;
  +         byte[] result = null;
  +         
            boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
            if (hasDifferentSourceAndIntegrationRoots)
            {
               sourceRoot = state_id.split(StateTransferManager.PARTIAL_STATE_DELIMETER)[0];
            }
  +         
            try
            {
  -            return _getState(Fqn.fromString(sourceRoot), configuration.getInitialStateRetrievalTimeout(), true, true);
  +            ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
  +            out = new MarshalledValueOutputStream(baos);
  +
  +            getStateTransferManager().getState(out, Fqn.fromString(sourceRoot),
  +                  configuration.getInitialStateRetrievalTimeout(), true, true);
  +            result = baos.getRawBuffer();
            }
            catch (Throwable t)
            {
  @@ -3332,15 +3364,21 @@
               my_log.error("Caught " + t.getClass().getName() +
                       " while responding to partial state transfer request;" +
                       " returning null", t);
  -            return null;
            }
  +         finally
  +         {
  +            Util.close(out);
  +         }
  +         return result;
         }
   
         public void getState(OutputStream ostream)
         {
  +         MarshalledValueOutputStream out = null;
            try
            {
  -            _getState(ostream, Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
  +            out = new MarshalledValueOutputStream(ostream);            
  +            getStateTransferManager().getState(out, Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
            }
            catch (Throwable t)
            {
  @@ -3350,11 +3388,16 @@
                       " while responding to initial state transfer request;" +
                       " returning null", t);
            }
  +         finally
  +         {
  +            Util.close(out);
  +         }
         }
   
         public void getState(String state_id, OutputStream ostream)
         {
            String sourceRoot = state_id;
  +         MarshalledValueOutputStream out = null;
            boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
            if (hasDifferentSourceAndIntegrationRoots)
            {
  @@ -3362,7 +3405,8 @@
            }
            try
            {
  -            _getState(ostream, Fqn.fromString(sourceRoot), configuration.getInitialStateRetrievalTimeout(), true, true);
  +            out = new MarshalledValueOutputStream(ostream);       
  +            getStateTransferManager().getState(out, Fqn.fromString(sourceRoot), configuration.getInitialStateRetrievalTimeout(), true, true);
            }
            catch (Throwable t)
            {
  @@ -3372,6 +3416,10 @@
                       " while responding to partial state transfer request;" +
                       " returning null", t);
            }
  +         finally
  +         {
  +            Util.close(out);
  +         }
         }
   
         public void setState(InputStream istream)
  @@ -3381,19 +3429,16 @@
               my_log.debug("stream is null (may be first member in cluster)");
               return;
            }
  +         MarshalledValueInputStream in = null;
            try
            {
  -            MarshalledValueInputStream in = new MarshalledValueInputStream(istream);
  +            in = new MarshalledValueInputStream(istream);   
               boolean hasState = in.readBoolean();
  -            if (!hasState)
  -            {
  -               in.close();
  -            }
  -            else
  +            if(hasState)
               {
                  getStateTransferManager().setState(in, Fqn.ROOT, null);
  -               isStateSet = true;
               }
  +            isStateSet = true;           
            }
            catch (Throwable t)
            {
  @@ -3409,6 +3454,7 @@
            }
            finally
            {
  +            Util.close(in);
               synchronized (stateLock)
               {
                  // Notify wait that state has been set.
  @@ -3419,6 +3465,13 @@
   
         public void setState(String state_id, byte[] state)
         {
  +         if (state == null)
  +         {
  +            my_log.debug("partial transferred state is null");
  +            return;
  +         }
  +         
  +         MarshalledValueInputStream in = null;
            String targetRoot = state_id;
            boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
            if (hasDifferentSourceAndIntegrationRoots)
  @@ -3428,8 +3481,6 @@
            try
            {
   
  -            if (state != null)
  -            {
                  my_log.debug("Setting received partial state for subroot " + state_id);
                  Fqn subroot = Fqn.fromString(targetRoot);
                  Region region = regionManager.getRegion(subroot, false);
  @@ -3439,9 +3490,14 @@
                     // If a classloader is registered for the node's region, use it
                     cl = region.getClassLoader();
                  }
  -               getStateTransferManager().setState(state, subroot, cl);
  -               isStateSet = true;
  +            ByteArrayInputStream bais = new ByteArrayInputStream(state);
  +            in = new MarshalledValueInputStream(bais);
  +            boolean hasState = in.readBoolean();
  +            if(hasState)
  +            {
  +               getStateTransferManager().setState(in, subroot, cl);
               }
  +            isStateSet = true;
            }
            catch (Throwable t)
            {
  @@ -3457,6 +3513,7 @@
            }
            finally
            {
  +            Util.close(in);
               synchronized (stateLock)
               {
                  // Notify wait that state has been set.
  @@ -3468,6 +3525,7 @@
         public void setState(String state_id, InputStream istream)
         {
            String targetRoot = state_id;
  +         MarshalledValueInputStream in = null;
            boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
            if (hasDifferentSourceAndIntegrationRoots)
            {
  @@ -3481,15 +3539,8 @@
   
            try
            {
  -            MarshalledValueInputStream in = new MarshalledValueInputStream(istream);
  -            boolean hasState = in.readBoolean();
  -            if (!hasState)
  -            {
  -               in.close();
  -            }
  -            else
  -            {
                  my_log.debug("Setting received partial state for subroot " + state_id);
  +            in = new MarshalledValueInputStream(istream);                      
                  Fqn subroot = Fqn.fromString(targetRoot);
                  Region region = regionManager.getRegion(subroot, false);
                  ClassLoader cl = null;
  @@ -3498,9 +3549,12 @@
                     // If a classloader is registered for the node's region, use it
                     cl = region.getClassLoader();
                  }
  -               getStateTransferManager().setState(in, Fqn.fromString(state_id), cl);
  -               isStateSet = true;
  +            boolean hasState = in.readBoolean();
  +            if(hasState)
  +            {
  +               getStateTransferManager().setState(in,subroot, cl);
               }
  +            isStateSet = true;           
            }
            catch (Throwable t)
            {
  @@ -3516,6 +3570,7 @@
            }
            finally
            {
  +            Util.close(in);
               synchronized (stateLock)
               {
                  // Notify wait that state has been set.
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 19:05:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 19:05:41 -0500
Subject: [jboss-cvs] JBossAS SVN: r59181 - in trunk:
	aspects/src/main/org/jboss/aop/deployers
	ejb3/src/main/org/jboss/ejb3
Message-ID: <E1GxBRN-0008VF-BX@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-20 19:05:39 -0500 (Wed, 20 Dec 2006)
New Revision: 59181

Modified:
   trunk/aspects/src/main/org/jboss/aop/deployers/AspectDeployer.java
   trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java
   trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java
Log:
wrap input stream in a BufferedInputStream as it is faster for scanning.

Modified: trunk/aspects/src/main/org/jboss/aop/deployers/AspectDeployer.java
===================================================================
--- trunk/aspects/src/main/org/jboss/aop/deployers/AspectDeployer.java	2006-12-20 18:50:48 UTC (rev 59180)
+++ trunk/aspects/src/main/org/jboss/aop/deployers/AspectDeployer.java	2006-12-21 00:05:39 UTC (rev 59181)
@@ -40,6 +40,7 @@
 import java.io.DataInputStream;
 import java.io.IOException;
 import java.io.InputStream;
+import java.io.BufferedInputStream;
 import java.util.List;
 
 import javassist.bytecode.ClassFile;
@@ -236,7 +237,7 @@
       try
       {
          InputStream in = file.openStream();
-         din = new DataInputStream(in);
+         din = new DataInputStream(new BufferedInputStream(in));
          cf = new ClassFile(din);
       }
       catch (IOException e)

Modified: trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java	2006-12-20 18:50:48 UTC (rev 59180)
+++ trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java	2006-12-21 00:05:39 UTC (rev 59181)
@@ -26,6 +26,7 @@
 import java.io.IOException;
 import java.io.InputStream;
 import java.io.InputStreamReader;
+import java.io.BufferedInputStream;
 import java.net.URL;
 import java.net.URLClassLoader;
 import java.util.ArrayList;
@@ -198,7 +199,7 @@
          while (it.hasNext())
          {
             InputStream stream = (InputStream) it.next();
-            DataInputStream dstream = new DataInputStream(stream);
+            DataInputStream dstream = new DataInputStream(new BufferedInputStream(stream));
             ClassFile cf = null;
             try
             {

Modified: trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java	2006-12-20 18:50:48 UTC (rev 59180)
+++ trunk/ejb3/src/main/org/jboss/ejb3/Ejb3Deployment.java	2006-12-21 00:05:39 UTC (rev 59181)
@@ -41,6 +41,7 @@
 import javax.security.jacc.PolicyConfigurationFactory;
 import java.io.DataInputStream;
 import java.io.InputStream;
+import java.io.BufferedInputStream;
 import java.net.URL;
 import java.util.ArrayList;
 import java.util.HashMap; 
@@ -384,7 +385,7 @@
    protected void deployElement(InputStream stream, Ejb3HandlerFactory factory, InitialContext ctx)
            throws Exception
    {
-      DataInputStream dstream = new DataInputStream(stream);
+      DataInputStream dstream = new DataInputStream(new BufferedInputStream(stream));
       ClassFile cf = null;
       try
       {



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 20:55:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 20:55:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r59182 -
	projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support
Message-ID: <E1GxD9e-0001u4-6o@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-20 20:55:28 -0500 (Wed, 20 Dec 2006)
New Revision: 59182

Modified:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
Log:
Fix the vfs iterator

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java	2006-12-21 00:05:39 UTC (rev 59181)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/support/ClassPathIterator.java	2006-12-21 01:55:28 UTC (rev 59182)
@@ -36,6 +36,7 @@
 import org.jboss.virtual.VFS;
 import org.jboss.virtual.VirtualFile;
 import org.jboss.virtual.VirtualFileFilter;
+import org.jboss.virtual.plugins.vfs.VirtualFileURLConnection;
 
 /**
  * ClassPathIterator logic used by UCL package mapping
@@ -75,8 +76,8 @@
       }
       else if( protocol.startsWith("vfs") )
       {
-         VFS vfs = VFS.getVFS(url);
-         vf = vfs.getRoot();
+         VirtualFileURLConnection conn = (VirtualFileURLConnection)url.openConnection();
+         vf = conn.getVirtualFile();
          rootLength = vf.getPathName().length() + 1;
          vfIter = new VirtualFileIterator(vf);
       }
@@ -221,6 +222,7 @@
          if( index < currentListing.size() )
          {
             next = currentListing.get(index);
+            index ++;
             if( next.isLeaf() == false )
                subDirectories.addLast(next);
          }



From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 21:01:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 21:01:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r59183 -
	projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test
Message-ID: <E1GxDFn-00020f-3u@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-20 21:01:49 -0500 (Wed, 20 Dec 2006)
New Revision: 59183

Modified:
   projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
Log:
Validate the files only war classes/pkgs seen by the ClassPathIterator

Modified: projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java
===================================================================
--- projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-21 01:55:28 UTC (rev 59182)
+++ projects/vfs/trunk/src/test/java/org/jboss/test/virtual/test/FileVFSUnitTestCase.java	2006-12-21 02:01:49 UTC (rev 59183)
@@ -1,4 +1,3 @@
-
 /*
  * JBoss, Home of Professional Open Source
  * Copyright 2006, Red Hat Middleware LLC, and individual contributors
@@ -338,7 +337,7 @@
    }
 
    /**
-    * Validate iterating over a vfs url
+    * Validate iterating over a vfs url from a files only war.
     * 
     * @throws Exception
     */
@@ -361,6 +360,9 @@
          names.add(entry.name);
       }
       log.debug(names);
+      assertTrue("org/jboss/test/vfs/support/jar1", names.contains("org/jboss/test/vfs/support/jar1"));
+      assertTrue("ClassInJar1.class", names.contains("org/jboss/test/vfs/support/jar1/ClassInJar1.class"));
+      assertTrue("ClassInJar1$InnerClass.class", names.contains("org/jboss/test/vfs/support/jar1/ClassInJar1$InnerClass.class"));
    }
 
    public void testFindResourceUnpackedJar()



From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:25 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:25 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/actionparam  ...
Message-ID: <E1GxDpB-0002nP-Qj@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:25

  Modified:    src/main/org/jboss/seam/actionparam 
                        MethodExpressionParser.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.4       +3 -2      jboss-seam/src/main/org/jboss/seam/actionparam/MethodExpressionParser.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodExpressionParser.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/actionparam/MethodExpressionParser.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MethodExpressionParser.java	18 Dec 2006 15:38:49 -0000	1.3
  +++ MethodExpressionParser.java	21 Dec 2006 02:38:25 -0000	1.4
  @@ -44,6 +44,7 @@
    */
   public class MethodExpressionParser implements Serializable 
   {
  +   private static final long serialVersionUID = 7145647492529261758L;
       
       private String unparsedExpression;
       private String baseExpression = "";
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:25 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:25 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/contexts   ...
Message-ID: <E1GxDpB-0002nZ-VA@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:25

  Modified:    src/main/org/jboss/seam/contexts   EntityBean.java
                        PassivatedEntity.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.5       +44 -47    jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/EntityBean.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- EntityBean.java	15 Dec 2006 06:01:15 -0000	1.4
  +++ EntityBean.java	21 Dec 2006 02:38:25 -0000	1.5
  @@ -1,17 +1,14 @@
   package org.jboss.seam.contexts;
  -
   import org.jboss.seam.core.Mutable;
  -
   public class EntityBean implements Mutable
   {
  +   private static final long serialVersionUID = -2884601453783925804L;
      private Object instance;
      private PassivatedEntity passivatedEntity;
  -
      public EntityBean(Object instance)
      {
         this.instance = instance;
      }
  -
      //TODO: use @Unwrap
      public Object getInstance()
      {
  
  
  
  1.4       +143 -143  jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivatedEntity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/contexts/PassivatedEntity.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PassivatedEntity.java	15 Dec 2006 06:01:15 -0000	1.3
  +++ PassivatedEntity.java	21 Dec 2006 02:38:25 -0000	1.4
  @@ -16,7 +16,7 @@
   
   public class PassivatedEntity implements Serializable
   {
  -   
  +   private static final long serialVersionUID = 6565440294007267788L;
      private Object id;
      private String persistenceContext;
      private String fieldName;
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:26 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core ...
Message-ID: <E1GxDpC-0002oe-Ac@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:26

  Modified:    src/main/org/jboss/seam/core                      Actor.java
                        BusinessProcess.java Conversation.java
                        ConversationEntries.java ConversationEntry.java
                        ConversationList.java ConversationStack.java
                        Dispatcher.java Expressions.java FacesMessages.java
                        FacesPage.java LocaleSelector.java
                        ManagedPersistenceContext.java Messages.java
                        Pageflow.java PersistenceContexts.java
                        Redirect.java ResourceBundle.java Switcher.java
                        TimeZoneSelector.java Transition.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.13      +58 -67    jboss-seam/src/main/org/jboss/seam/core/Actor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Actor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Actor.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- Actor.java	24 Nov 2006 23:15:17 -0000	1.12
  +++ Actor.java	21 Dec 2006 02:38:26 -0000	1.13
  @@ -1,12 +1,9 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
   import java.util.HashSet;
   import java.util.Set;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -14,7 +11,6 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -
   /**
    * Allows the application to specify the jBPM actorId
    * during the login cycle.
  @@ -27,17 +23,14 @@
   @Install(dependencies="org.jboss.seam.core.jbpm", precedence=BUILT_IN)
   public class Actor extends AbstractMutable implements Serializable
   {
  -   
  +   private static final long serialVersionUID = -6515302276074415520L;
      private String id;
      private Set<String> groupActorIds = new HashSet<String>();
  -   
      //TODO: dirtyness for groupActorIds
  -
      public String getId() 
      {
         return id;
      }
  -
      public void setId(String id) 
      {
         setDirty(this.id, id);
  @@ -48,7 +41,6 @@
      {
         return groupActorIds;
      }
  -
      public static Actor instance()
      {
         if ( !Contexts.isSessionContextActive() )
  @@ -63,5 +55,4 @@
      {
         return "Actor(" + id + ")";
      }
  -   
   }
  
  
  
  1.17      +307 -328  jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcess.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/BusinessProcess.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- BusinessProcess.java	18 Dec 2006 20:23:08 -0000	1.16
  +++ BusinessProcess.java	21 Dec 2006 02:38:26 -0000	1.17
  @@ -1,12 +1,8 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
  -
   import javax.faces.application.FacesMessage;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -16,7 +12,6 @@
   import org.jboss.seam.contexts.Contexts;
   import org.jbpm.graph.exe.ProcessInstance;
   import org.jbpm.taskmgmt.exe.TaskInstance;
  -
   /**
    * Holds the task and process ids for the current conversation,
    * and provides programmatic control over the business process.
  @@ -29,7 +24,7 @@
   @Intercept(NEVER)
   @Install(dependencies="org.jboss.seam.core.jbpm", precedence=BUILT_IN)
   public class BusinessProcess extends AbstractMutable implements Serializable {
  -   
  +   private static final long serialVersionUID = 4722350870845851070L;
      private Long processId;
      private Long taskId;
      
  @@ -60,7 +55,6 @@
         return hasCurrentProcess() && 
               !org.jboss.seam.core.ProcessInstance.instance().hasEnded();
      }
  -
      /**
       * Is there a task instance associated with 
       * the current conversation?
  @@ -69,7 +63,6 @@
      {
         return taskId!=null;
      }
  -
      /**
       * The jBPM process instance id associated with
       * the current conversation.
  @@ -77,7 +70,6 @@
      public Long getProcessId() {
         return processId;
      }
  -
      /**
       * Set the process instance id, without validating
       * that the process instance actually exists.
  @@ -86,7 +78,6 @@
         setDirty(this.processId, processId);
         this.processId = processId;
      }
  -
      /**
       * The jBPM task instance id associated with
       * the current conversation.
  @@ -94,7 +85,6 @@
      public Long getTaskId() {
         return taskId;
      }
  -
      /**
       * Set the task instance id, without validating
       * that the task instance actually exists.
  @@ -103,7 +93,6 @@
         setDirty(this.taskId, taskId);
         this.taskId = taskId;
      }
  -
      /**
       * Create a process instance and associate it with the
       * current conversation.
  @@ -120,7 +109,6 @@
         
         Events.instance().raiseEvent("org.jboss.seam.createProcess." + processDefinitionName);
      }
  -
      /**
       * Start the current task, using the current actor id
       * 
  @@ -141,7 +129,6 @@
         
         Events.instance().raiseEvent("org.jboss.seam.startTask." + task.getTask().getName());
      }
  -
      /**
       * End the current task, via the given transition. If no transition name 
       * is given, check the Transition component for a transition, or use the 
  @@ -174,7 +161,6 @@
         setTaskId(null); //TODO: do I really need this???!
         
         Events.instance().raiseEvent("org.jboss.seam.endTask." + task.getTask().getName());
  -
         ProcessInstance process = org.jboss.seam.core.ProcessInstance.instance();
         if ( process.hasEnded() )
         {
  @@ -254,7 +240,6 @@
            return true;
         }
      }
  -
      /**
       * Check that the task currently associated with the conversation
       * exists and has not ended.
  @@ -278,7 +263,6 @@
            return true;
         }
      }
  -
      protected void taskNotFound(Long taskId)
      {
         FacesMessages.instance().addFromResourceBundle(
  @@ -288,7 +272,6 @@
               taskId
            );
      }
  -
      protected void taskEnded(Long taskId)
      {
         FacesMessages.instance().addFromResourceBundle(
  @@ -298,7 +281,6 @@
               taskId
            );
      }
  -
      protected void processEnded(Long processId)
      {
         FacesMessages.instance().addFromResourceBundle(
  @@ -308,7 +290,6 @@
               processId
            );
      }
  -
      protected void processNotFound(Long processId)
      {
         FacesMessages.instance().addFromResourceBundle(
  @@ -318,11 +299,9 @@
               processId
            );
      }
  -
      @Override
      public String toString()
      {
         return "BusinessProcess(processId=" + processId + ",taskId=" + taskId + ")";
      }
  -
   }
  
  
  
  1.33      +372 -372  jboss-seam/src/main/org/jboss/seam/core/Conversation.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Conversation.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Conversation.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- Conversation.java	17 Dec 2006 15:03:29 -0000	1.32
  +++ Conversation.java	21 Dec 2006 02:38:26 -0000	1.33
  @@ -29,7 +29,7 @@
   @Install(precedence=BUILT_IN)
   @Intercept(NEVER)
   public class Conversation implements Serializable {
  -   
  +   private static final long serialVersionUID = -6131304128727444876L;
      private Integer timeout;
      String description;
      String viewId;
  
  
  
  1.6       +82 -85    jboss-seam/src/main/org/jboss/seam/core/ConversationEntries.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationEntries.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ConversationEntries.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ConversationEntries.java	19 Dec 2006 16:57:05 -0000	1.5
  +++ ConversationEntries.java	21 Dec 2006 02:38:26 -0000	1.6
  @@ -1,8 +1,6 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
   import java.util.Collection;
   import java.util.Collections;
  @@ -10,7 +8,6 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -18,7 +15,6 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -
   /**
    * Manages a map of conversation id to ConversationEntry 
    * in the session context.
  @@ -31,6 +27,7 @@
   @Intercept(NEVER)
   public class ConversationEntries extends AbstractMutable implements Serializable
   {
  +   private static final long serialVersionUID = 7996835952419813634L;
      private Map<String, ConversationEntry> conversationIdEntryMap = new HashMap<String, ConversationEntry>();
      
      public synchronized Collection<ConversationEntry> getConversationEntries()
  
  
  
  1.33      +241 -267  jboss-seam/src/main/org/jboss/seam/core/ConversationEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ConversationEntry.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- ConversationEntry.java	15 Dec 2006 12:52:45 -0000	1.32
  +++ ConversationEntry.java	21 Dec 2006 02:38:26 -0000	1.33
  @@ -2,14 +2,12 @@
    *
    */
   package org.jboss.seam.core;
  -
   import java.io.Serializable;
   import java.util.Collections;
   import java.util.Date;
   import java.util.List;
   import java.util.concurrent.TimeUnit;
   import java.util.concurrent.locks.ReentrantLock;
  -
   /**
    * Metadata about an active conversation. Also used
    * by the conversation list and breadcrumbs.
  @@ -19,6 +17,7 @@
    */
   public final class ConversationEntry implements Serializable, Comparable<ConversationEntry>
   {
  +   private static final long serialVersionUID = 3624635335271963568L;
      private long lastRequestTime;
      private String description;
      private String id;
  @@ -34,7 +33,6 @@
      private ConversationEntries entries;
      
      private ReentrantLock lock;
  -
      public ConversationEntry(String id, List<String> stack, ConversationEntries entries)
      {
         this.id = id;
  @@ -53,49 +51,40 @@
         {
            lock = new ReentrantLock(true);
         }
  -
         touch();
      }
  -
      public String getDescription() 
      {
         return description;
      }
  -
      void setDescription(String description) 
      {
         entries.setDirty(this.description, description);
         this.description = description;
      }
  -
      public synchronized long getLastRequestTime() 
      {
         return lastRequestTime;
      }
  -
      synchronized void touch() 
      {
         entries.setDirty();
         lastRequestTime = System.currentTimeMillis();
         lastDatetime = new Date();
      }
  -
      public String getId() 
      {
         return id;
      }
  -
      public Date getStartDatetime() 
      {
         return startDatetime;
      }
  -
      public void destroy() 
      {
         boolean success = Manager.instance().switchConversation( getId() );
         if (success) Manager.instance().endConversation(false);
      }
  -
      public void select() 
      {
         switchConversation();
  @@ -122,28 +111,23 @@
            return false;
         }
      }
  -
      void setViewId(String viewId) 
      {
         entries.setDirty(this.viewId, viewId);
         this.viewId = viewId;
      }
  -
      public String getViewId()
      {
         return viewId;
      }
  -
      public synchronized Date getLastDatetime() 
      {
         return lastDatetime;
      }
  -
      public List<String> getConversationIdStack() 
      {
         return conversationIdStack;
      }
  -
      /**
       * @deprecated
       * @return a component name
  @@ -152,7 +136,6 @@
      {
         return initiatorComponentName;
      }
  -
      /**
       * @deprecated
       */
  @@ -160,7 +143,6 @@
         entries.setDirty(this.initiatorComponentName, ownerComponentName);
         this.initiatorComponentName = ownerComponentName;
      }
  -
      public boolean isDisplayable() 
      {
         return !isEnded() && getDescription()!=null;
  @@ -182,30 +164,25 @@
            return false;
         }
      }
  -
      public int compareTo(ConversationEntry entry) 
      {
         int result = new Long ( getLastRequestTime() ).compareTo( entry.getLastRequestTime() );
         return - ( result==0 ? getId().compareTo( entry.getId() ) : result );
      }
  -
      public int getTimeout() 
      {
         return timeout==null ?
               Manager.instance().getConversationTimeout() : timeout;
      }
  -
      void setTimeout(int conversationTimeout) 
      {
         entries.setDirty(this.timeout, timeout);
         this.timeout = conversationTimeout;
      }
  -
      public boolean isRemoveAfterRedirect() 
      {
         return removeAfterRedirect;
      }
  -
      public void setRemoveAfterRedirect(boolean removeAfterRedirect) 
      {
         entries.setDirty();
  @@ -221,7 +198,6 @@
      {
         return lock.tryLock();
      }
  -
      public boolean lock() //not synchronized!
      {
         try
  @@ -258,11 +234,9 @@
      {
         return conversationIdStack.size()>1;
      }
  -
      @Override
      public String toString()
      {
         return "ConversationEntry(" + id + ")";
      }
  -
   }
  \ No newline at end of file
  
  
  
  1.11      +51 -54    jboss-seam/src/main/org/jboss/seam/core/ConversationList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ConversationList.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ConversationList.java	24 Nov 2006 23:15:17 -0000	1.10
  +++ ConversationList.java	21 Dec 2006 02:38:26 -0000	1.11
  @@ -1,14 +1,11 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.List;
   import java.util.Set;
   import java.util.TreeSet;
  -
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
   import org.jboss.seam.annotations.Create;
  @@ -17,10 +14,9 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.annotations.Unwrap;
  -
   /**
    * @author Gavin King
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   @Scope(ScopeType.PAGE)
   @Name("org.jboss.seam.core.conversationList")
  @@ -28,6 +24,7 @@
   @Intercept(NEVER)
   public class ConversationList implements Serializable {
      
  +   private static final long serialVersionUID = -1515889862229134356L;
      private List<ConversationEntry> conversationEntryList;
      
      @Create
  
  
  
  1.8       +57 -61    jboss-seam/src/main/org/jboss/seam/core/ConversationStack.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationStack.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ConversationStack.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ConversationStack.java	24 Nov 2006 23:15:17 -0000	1.7
  +++ ConversationStack.java	21 Dec 2006 02:38:26 -0000	1.8
  @@ -1,13 +1,10 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.List;
   import java.util.ListIterator;
  -
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
   import org.jboss.seam.annotations.Create;
  @@ -16,19 +13,18 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.annotations.Unwrap;
  -
   /**
    * Support for "breadcrumbs".
    * 
    * @author Gavin King
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   @Scope(ScopeType.PAGE)
   @Name("org.jboss.seam.core.conversationStack")
   @Install(precedence=BUILT_IN)
   @Intercept(NEVER)
   public class ConversationStack implements Serializable {
  -   
  +   private static final long serialVersionUID = 7941458529299691801L;
      private List<ConversationEntry> conversationEntryStack;
      
      @Create
  
  
  
  1.15      +370 -368  jboss-seam/src/main/org/jboss/seam/core/Dispatcher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Dispatcher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Dispatcher.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- Dispatcher.java	16 Dec 2006 16:05:20 -0000	1.14
  +++ Dispatcher.java	21 Dec 2006 02:38:26 -0000	1.15
  @@ -342,6 +342,8 @@
           implements TimerHandle, 
                      Serializable
       {
  +      private static final long serialVersionUID = 6913362944260154627L;
  +      
           TimerHandle handle;
   
           public TimerHandleProxy(TimerHandle handle) {
  
  
  
  1.13      +157 -153  jboss-seam/src/main/org/jboss/seam/core/Expressions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Expressions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Expressions.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- Expressions.java	24 Nov 2006 23:15:17 -0000	1.12
  +++ Expressions.java	21 Dec 2006 02:38:26 -0000	1.13
  @@ -1,4 +1,4 @@
  -//$Id: Expressions.java,v 1.12 2006/11/24 23:15:17 gavin Exp $
  +//$Id: Expressions.java,v 1.13 2006/12/21 02:38:26 sbryzak2 Exp $
   package org.jboss.seam.core;
   
   import static org.jboss.seam.InterceptionType.NEVER;
  @@ -34,6 +34,8 @@
         
         return new ValueBinding() 
         {
  +         private static final long serialVersionUID = -8655967672318993009L;
  +         
            private transient javax.faces.el.ValueBinding cachedValueBinding;
            
            public String getExpressionString()
  @@ -86,6 +88,8 @@
      {
         return new MethodBinding() 
         {
  +         private static final long serialVersionUID = 7314202661786534543L;
  +         
            private transient javax.faces.el.MethodBinding cachedMethodBinding;
   
            public String getExpressionString()
  
  
  
  1.26      +323 -323  jboss-seam/src/main/org/jboss/seam/core/FacesMessages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FacesMessages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/FacesMessages.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- FacesMessages.java	17 Dec 2006 20:33:19 -0000	1.25
  +++ FacesMessages.java	21 Dec 2006 02:38:26 -0000	1.26
  @@ -36,7 +36,7 @@
   @Intercept(NEVER)
   public class FacesMessages implements Serializable
   {
  -   
  +   private static final long serialVersionUID = -5395975397632138270L;
      private transient List<Runnable> tasks;
      
      private List<FacesMessage> facesMessages = new ArrayList<FacesMessage>();
  
  
  
  1.6       +170 -169  jboss-seam/src/main/org/jboss/seam/core/FacesPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FacesPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/FacesPage.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- FacesPage.java	24 Nov 2006 23:15:17 -0000	1.5
  +++ FacesPage.java	21 Dec 2006 02:38:26 -0000	1.6
  @@ -28,6 +28,7 @@
   @Scope(ScopeType.PAGE)
   public class FacesPage implements Serializable
   {
  +   private static final long serialVersionUID = 4807114041808347239L;
      private String pageflowName;
      private Integer pageflowCounter;
      private String pageflowNodeName;
  
  
  
  1.18      +2 -1      jboss-seam/src/main/org/jboss/seam/core/LocaleSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocaleSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/LocaleSelector.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- LocaleSelector.java	18 Dec 2006 11:52:49 -0000	1.17
  +++ LocaleSelector.java	21 Dec 2006 02:38:26 -0000	1.18
  @@ -37,6 +37,7 @@
   @Install(precedence=BUILT_IN)
   public class LocaleSelector extends Selector
   {
  +   private static final long serialVersionUID = -6087667065688208261L;
   
      private String language;
      private String country;
  
  
  
  1.30      +206 -221  jboss-seam/src/main/org/jboss/seam/core/ManagedPersistenceContext.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedPersistenceContext.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ManagedPersistenceContext.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- ManagedPersistenceContext.java	16 Dec 2006 02:58:10 -0000	1.29
  +++ ManagedPersistenceContext.java	21 Dec 2006 02:38:26 -0000	1.30
  @@ -1,19 +1,15 @@
  -//$Id: ManagedPersistenceContext.java,v 1.29 2006/12/16 02:58:10 nrichards Exp $
  +//$Id: ManagedPersistenceContext.java,v 1.30 2006/12/21 02:38:26 sbryzak2 Exp $
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
  -
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.List;
  -
   import javax.naming.NamingException;
   import javax.persistence.EntityManager;
   import javax.persistence.EntityManagerFactory;
   import javax.servlet.http.HttpSessionActivationListener;
   import javax.servlet.http.HttpSessionEvent;
   import javax.transaction.SystemException;
  -
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   import org.jboss.seam.Component;
  @@ -29,7 +25,6 @@
   import org.jboss.seam.persistence.PersistenceProvider;
   import org.jboss.seam.util.Naming;
   import org.jboss.seam.util.Transactions;
  -
   /**
    * A Seam component that manages a conversation-scoped extended
    * persistence context that can be shared by arbitrary other
  @@ -43,7 +38,7 @@
   public class ManagedPersistenceContext 
      implements Serializable, HttpSessionActivationListener, Mutable, PersistenceContextManager
   {
  -
  +   private static final long serialVersionUID = -4972387440275848126L;
      private static final LogProvider log = Logging.getLogProvider(ManagedPersistenceContext.class);
      
      private EntityManager entityManager;
  @@ -56,7 +51,6 @@
      {
         return true;
      }
  -
      @Create
      public void create(Component component)
      {
  @@ -82,7 +76,6 @@
            }
         }
      }
  -
      private void createEntityManager()
      {
         entityManager = getEntityManagerFactoryFromJndiOrValueBinding().createEntityManager();      
  @@ -92,7 +85,6 @@
            PersistenceProvider.instance().enableFilter(f, entityManager);
         }
      }
  -
      @Unwrap
      public EntityManager getEntityManager() throws NamingException, SystemException
      {
  @@ -159,7 +151,6 @@
      {
         return entityManagerFactory;
      }
  -
      public void setEntityManagerFactory(ValueBinding<EntityManagerFactory> entityManagerFactory)
      {
         this.entityManagerFactory = entityManagerFactory;
  @@ -173,16 +164,13 @@
      {
         return persistenceUnitJndiName;
      }
  -
      public void setPersistenceUnitJndiName(String persistenceUnitName)
      {
         this.persistenceUnitJndiName = persistenceUnitName;
      }
  -
      public String getComponentName() {
         return componentName;
      }
  -
      /**
       * Hibernate filters to enable automatically
       */
  @@ -190,12 +178,10 @@
      {
         return filters;
      }
  -
      protected void setFilters(List<Filter> filters)
      {
         this.filters = filters;
      }
  -
      public void setFlushMode(org.jboss.seam.annotations.FlushModeType flushMode)
      {
         switch (flushMode)
  @@ -217,5 +203,4 @@
      {
         return "ManagedPersistenceContext(" + persistenceUnitJndiName + ")";
      }
  -
   }
  
  
  
  1.10      +110 -109  jboss-seam/src/main/org/jboss/seam/core/Messages.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Messages.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Messages.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- Messages.java	24 Nov 2006 23:15:17 -0000	1.9
  +++ Messages.java	21 Dec 2006 02:38:26 -0000	1.10
  @@ -29,6 +29,7 @@
   @Name("org.jboss.seam.core.messages")
   @Install(precedence=BUILT_IN)
   public class Messages implements Serializable {
  +   private static final long serialVersionUID = 1292464253307553295L;
      
      private transient Map<String, String> messages;
      
  
  
  
  1.49      +2 -0      jboss-seam/src/main/org/jboss/seam/core/Pageflow.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Pageflow.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Pageflow.java,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -b -r1.48 -r1.49
  --- Pageflow.java	18 Dec 2006 15:38:49 -0000	1.48
  +++ Pageflow.java	21 Dec 2006 02:38:26 -0000	1.49
  @@ -45,6 +45,8 @@
   @Install(dependencies="org.jboss.seam.core.jbpm", precedence=BUILT_IN)
   public class Pageflow extends AbstractMutable implements Serializable
   {
  +   private static final long serialVersionUID = -2337682140346213333L;
  +
      private static final LogProvider log = Logging.getLogProvider(Pageflow.class);
      
      private int counter;
  
  
  
  1.3       +66 -70    jboss-seam/src/main/org/jboss/seam/core/PersistenceContexts.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PersistenceContexts.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/PersistenceContexts.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PersistenceContexts.java	24 Nov 2006 23:15:17 -0000	1.2
  +++ PersistenceContexts.java	21 Dec 2006 02:38:26 -0000	1.3
  @@ -1,13 +1,10 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
   import java.util.Collections;
   import java.util.HashSet;
   import java.util.Set;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.FlushModeType;
  @@ -16,13 +13,13 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -
   @Name("org.jboss.seam.core.persistenceContexts")
   @Scope(ScopeType.CONVERSATION)
   @Intercept(NEVER)
   @Install(precedence=BUILT_IN)
   public class PersistenceContexts extends AbstractMutable implements Serializable
   {
  +   private static final long serialVersionUID = -4897350516435283182L;
      private Set<String> set = new HashSet<String>();
      private FlushModeType flushMode = FlushModeType.AUTO;
      
  @@ -52,7 +49,6 @@
            return null;
         }
      }
  -
      public void changeFlushMode(FlushModeType flushMode)
      {
         this.flushMode = flushMode;
  
  
  
  1.10      +117 -122  jboss-seam/src/main/org/jboss/seam/core/Redirect.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Redirect.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Redirect.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- Redirect.java	24 Nov 2006 23:15:17 -0000	1.9
  +++ Redirect.java	21 Dec 2006 02:38:26 -0000	1.10
  @@ -1,13 +1,9 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
   import java.util.HashMap;
   import java.util.Map;
  -
   import javax.faces.context.FacesContext;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.InterceptionType;
   import org.jboss.seam.ScopeType;
  @@ -16,7 +12,6 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -
   /**
    * Convenient API for performing browser redirects with
    * parameters.
  @@ -29,6 +24,7 @@
   @Install(precedence=BUILT_IN)
   public class Redirect extends AbstractMutable implements Serializable
   {
  +   private static final long serialVersionUID = 6947384474861235210L;
      private String viewId;
      private Map<String, Object> parameters = new HashMap<String, Object>();
      private boolean conversationPropagationEnabled = true;
  @@ -118,5 +114,4 @@
         }
         return (Redirect) Component.getInstance(Redirect.class, ScopeType.CONVERSATION);
      }
  -
   }
  
  
  
  1.25      +199 -199  jboss-seam/src/main/org/jboss/seam/core/ResourceBundle.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ResourceBundle.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/ResourceBundle.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- ResourceBundle.java	16 Dec 2006 02:58:10 -0000	1.24
  +++ ResourceBundle.java	21 Dec 2006 02:38:26 -0000	1.25
  @@ -35,7 +35,7 @@
   @Name("org.jboss.seam.core.resourceBundle")
   @Install(precedence=BUILT_IN)
   public class ResourceBundle implements Serializable {
  -   
  +   private static final long serialVersionUID = -3236251335438092538L;
      private static final LogProvider log = Logging.getLogProvider(ResourceBundle.class);
   
      private String[] bundleNames = {"messages"};
  
  
  
  1.17      +119 -119  jboss-seam/src/main/org/jboss/seam/core/Switcher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Switcher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Switcher.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- Switcher.java	24 Nov 2006 23:15:17 -0000	1.16
  +++ Switcher.java	21 Dec 2006 02:38:26 -0000	1.17
  @@ -25,14 +25,14 @@
    * Support for the conversation switcher drop-down menu.
    * 
    * @author Gavin King
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    */
   @Scope(ScopeType.PAGE)
   @Name("org.jboss.seam.core.switcher")
   @Install(precedence=BUILT_IN)
   @Intercept(NEVER)
   public class Switcher implements Serializable {
  -   
  +   private static final long serialVersionUID = -6403911073853051938L;
      private List<SelectItem> selectItems;
      private String conversationIdOrOutcome;
      private String resultingConversationIdOrOutcome;
  
  
  
  1.8       +2 -1      jboss-seam/src/main/org/jboss/seam/core/TimeZoneSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TimeZoneSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/TimeZoneSelector.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- TimeZoneSelector.java	18 Dec 2006 11:52:49 -0000	1.7
  +++ TimeZoneSelector.java	21 Dec 2006 02:38:26 -0000	1.8
  @@ -24,6 +24,7 @@
   @Install(value=false, precedence=BUILT_IN)
   public class TimeZoneSelector extends Selector
   {
  +   private static final long serialVersionUID = -5013819375360015369L;
   
      private String id;
      
  
  
  
  1.11      +53 -58    jboss-seam/src/main/org/jboss/seam/core/Transition.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Transition.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Transition.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- Transition.java	24 Nov 2006 23:15:17 -0000	1.10
  +++ Transition.java	21 Dec 2006 02:38:26 -0000	1.11
  @@ -1,10 +1,7 @@
   package org.jboss.seam.core;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
   import static org.jboss.seam.annotations.Install.BUILT_IN;
  -
   import java.io.Serializable;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Install;
  @@ -12,7 +9,6 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.contexts.Contexts;
  -
   /**
    * Allows the application to set the jBPM transition to be used when
    * @EndTask is encountered.
  @@ -24,9 +20,9 @@
   @Intercept(NEVER)
   @Install(precedence=BUILT_IN, dependencies="org.jboss.seam.core.jbpm")
   public class Transition extends AbstractMutable implements Serializable {
  +   private static final long serialVersionUID = -3054558654376670239L;
      
      private String name;
  -
      public String getName() 
      {
         return name;
  @@ -49,7 +45,6 @@
         }
         return (Transition) Component.getInstance(Transition.class, ScopeType.CONVERSATION);
      }
  -
      @Override
      public String toString()
      {
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:26 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/drools     ...
Message-ID: <E1GxDpC-0002ou-F5@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:26

  Modified:    src/main/org/jboss/seam/drools     DroolsActionHandler.java
                        DroolsAssignmentHandler.java
                        DroolsDecisionHandler.java
                        ManagedWorkingMemory.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.4       +26 -30    jboss-seam/src/main/org/jboss/seam/drools/DroolsActionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DroolsActionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/drools/DroolsActionHandler.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DroolsActionHandler.java	15 Jun 2006 08:03:53 -0000	1.3
  +++ DroolsActionHandler.java	21 Dec 2006 02:38:26 -0000	1.4
  @@ -1,10 +1,7 @@
   package org.jboss.seam.drools;
  -
   import java.util.List;
  -
   import org.jbpm.graph.def.ActionHandler;
   import org.jbpm.graph.exe.ExecutionContext;
  -
   /**
    * A jBPM ActionHandler that delegates to a Drools WorkingMemory
    * held in a Seam context variable.
  @@ -15,10 +12,9 @@
    */
   public class DroolsActionHandler extends DroolsHandler implements ActionHandler
   {
  -
  +   private static final long serialVersionUID = 7752070876220597913L;
      public List<String> assertObjects;
      public String workingMemoryName;
  -
      /**
       * The FireRulesActionHandler gets variables from the Instance, and asserts
       * them into the Rules Engine and invokes the rules.
  
  
  
  1.4       +26 -31    jboss-seam/src/main/org/jboss/seam/drools/DroolsAssignmentHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DroolsAssignmentHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/drools/DroolsAssignmentHandler.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DroolsAssignmentHandler.java	15 Jun 2006 08:03:53 -0000	1.3
  +++ DroolsAssignmentHandler.java	21 Dec 2006 02:38:26 -0000	1.4
  @@ -1,12 +1,9 @@
   package org.jboss.seam.drools;
  -
   import java.util.List;
  -
   import org.drools.WorkingMemory;
   import org.jbpm.graph.exe.ExecutionContext;
   import org.jbpm.taskmgmt.def.AssignmentHandler;
   import org.jbpm.taskmgmt.exe.Assignable;
  -
   /**
    * A jBPM AssignmentHandler that delegates to a Drools WorkingMemory
    * held in a Seam context variable.
  @@ -17,10 +14,9 @@
    */
   public class DroolsAssignmentHandler extends DroolsHandler implements AssignmentHandler
   {
  -
  +   private static final long serialVersionUID = -7114640047036854546L;
      public String workingMemoryName;
      public List<String> assertObjects;
  -
      public void assign(Assignable assignable, ExecutionContext executionContext)
            throws Exception
      {
  @@ -28,5 +24,4 @@
         workingMemory.setGlobal( "assignable", assignable );
         workingMemory.fireAllRules();
      }
  -
   }
  \ No newline at end of file
  
  
  
  1.4       +30 -34    jboss-seam/src/main/org/jboss/seam/drools/DroolsDecisionHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DroolsDecisionHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/drools/DroolsDecisionHandler.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DroolsDecisionHandler.java	15 Jun 2006 08:03:53 -0000	1.3
  +++ DroolsDecisionHandler.java	21 Dec 2006 02:38:26 -0000	1.4
  @@ -1,11 +1,8 @@
   package org.jboss.seam.drools;
  -
   import java.util.List;
  -
   import org.drools.WorkingMemory;
   import org.jbpm.graph.exe.ExecutionContext;
   import org.jbpm.graph.node.DecisionHandler;
  -
   /**
    * A jBPM DecisionHandler that delegates to a Drools WorkingMemory
    * held in a Seam context variable. The decision outcome is returned
  @@ -16,10 +13,9 @@
    */
   public class DroolsDecisionHandler extends DroolsHandler implements DecisionHandler
   {
  -
  +   private static final long serialVersionUID = -8900810376838166513L;
      public List<String> assertObjects;
      public String workingMemoryName;
  -
      /**
       * The FireRulesActionHandler gets variables from the Instance, and asserts
       * them into the Rules Engine and invokes the rules.
  
  
  
  1.8       +99 -107   jboss-seam/src/main/org/jboss/seam/drools/ManagedWorkingMemory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedWorkingMemory.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/drools/ManagedWorkingMemory.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ManagedWorkingMemory.java	14 Oct 2006 18:30:27 -0000	1.7
  +++ ManagedWorkingMemory.java	21 Dec 2006 02:38:26 -0000	1.8
  @@ -1,9 +1,6 @@
   package org.jboss.seam.drools;
  -
   import static org.jboss.seam.InterceptionType.NEVER;
  -
   import java.io.Serializable;
  -
   import org.drools.RuleBase;
   import org.drools.WorkingMemory;
   import org.jboss.seam.Component;
  @@ -14,7 +11,6 @@
   import org.jboss.seam.annotations.Unwrap;
   import org.jboss.seam.core.Mutable;
   import org.jboss.seam.core.Expressions.ValueBinding;
  -
   /**
    * A conversation-scoped Drools WorkingMemory for a named RuleBase
    * 
  @@ -25,16 +21,15 @@
   @Intercept(NEVER)
   public class ManagedWorkingMemory implements Mutable, Serializable
   {
  +   private static final long serialVersionUID = -1746942080571374743L;
      
      private String ruleBaseName;
      private WorkingMemory workingMemory;
      private ValueBinding<RuleBase> ruleBase;
  -
      public boolean clearDirty()
      {
         return true;
      }
  -
      /**
       * The name of a Seam context variable holding an
       * instance of org.drools.RuleBase
  @@ -93,15 +88,12 @@
      {
         workingMemory.dispose();
      }
  -
      public ValueBinding<RuleBase> getRuleBase()
      {
         return ruleBase;
      }
  -
      public void setRuleBase(ValueBinding<RuleBase> ruleBase)
      {
         this.ruleBase = ruleBase;
      }
  -
   }
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:26 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/ejb  ...
Message-ID: <E1GxDpC-0002p1-JX@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:26

  Modified:    src/main/org/jboss/seam/ejb  SeamInterceptor.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.49      +19 -20    jboss-seam/src/main/org/jboss/seam/ejb/SeamInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/ejb/SeamInterceptor.java,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -b -r1.48 -r1.49
  --- SeamInterceptor.java	10 Oct 2006 06:43:16 -0000	1.48
  +++ SeamInterceptor.java	21 Dec 2006 02:38:26 -0000	1.49
  @@ -5,9 +5,7 @@
    * See terms of license at gnu.org.
    */
   package org.jboss.seam.ejb;
  -
   import org.jboss.seam.intercept.SessionBeanInterceptor;
  -
   /**
    * Controller interceptor for server-side interceptors of
    * EJB3 session bean components.
  @@ -16,5 +14,6 @@
    */
   public class SeamInterceptor extends SessionBeanInterceptor
   {
  +   private static final long serialVersionUID = 4250146024419999221L;
      
   }
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:26 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:26 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/framework     ...
Message-ID: <E1GxDpC-0002pH-QU@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:26

  Modified:    src/main/org/jboss/seam/framework     EntityHome.java
                        EntityNotFoundException.java
                        HibernateEntityHome.java Home.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.10      +78 -84    jboss-seam/src/main/org/jboss/seam/framework/EntityHome.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityHome.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/EntityHome.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- EntityHome.java	3 Nov 2006 02:50:58 -0000	1.9
  +++ EntityHome.java	21 Dec 2006 02:38:26 -0000	1.10
  @@ -1,13 +1,12 @@
   package org.jboss.seam.framework;
  -
   import javax.persistence.EntityManager;
  -
   import org.jboss.seam.Component;
   import org.jboss.seam.annotations.Transactional;
   import org.jboss.seam.persistence.PersistenceProvider;
  -
   public class EntityHome<E> extends Home<E>
   {
  +   private static final long serialVersionUID = -3140094990727574632L;
  +   
      private EntityManager entityManager;
      
      @Override
  @@ -26,7 +25,6 @@
         return getInstance()!=null && 
               getEntityManager().contains( getInstance() );
      }
  -
      @Transactional
      public String update()
      {
  @@ -46,7 +44,6 @@
         createdMessage();
         return "persisted";
      }
  -
      @Transactional
      public String remove()
      {
  @@ -66,7 +63,6 @@
         if (result==null) result = handleNotFound();
         return result;
      }
  -
      public EntityManager getEntityManager()
      {
         if (entityManager==null)
  @@ -75,10 +71,8 @@
         }
         return entityManager;
      }
  -
      public void setEntityManager(EntityManager entityManager)
      {
         this.entityManager = entityManager;
      }
  -
   }
  
  
  
  1.4       +9 -11     jboss-seam/src/main/org/jboss/seam/framework/EntityNotFoundException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EntityNotFoundException.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/EntityNotFoundException.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- EntityNotFoundException.java	1 Nov 2006 01:52:09 -0000	1.3
  +++ EntityNotFoundException.java	21 Dec 2006 02:38:26 -0000	1.4
  @@ -1,11 +1,9 @@
   package org.jboss.seam.framework;
  -
   import javax.ejb.ApplicationException;
  -
   import org.jboss.seam.annotations.HttpError;
  -
   @HttpError(errorCode=404)
   @ApplicationException(rollback=true) 
   public class EntityNotFoundException extends RuntimeException
   {
  +   private static final long serialVersionUID = -3469578090343847583L;
   }
  
  
  
  1.7       +69 -80    jboss-seam/src/main/org/jboss/seam/framework/HibernateEntityHome.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HibernateEntityHome.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/HibernateEntityHome.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- HibernateEntityHome.java	3 Nov 2006 02:50:58 -0000	1.6
  +++ HibernateEntityHome.java	21 Dec 2006 02:38:26 -0000	1.7
  @@ -1,15 +1,12 @@
   package org.jboss.seam.framework;
  -
   import java.io.Serializable;
  -
   import org.hibernate.Session;
   import org.jboss.seam.Component;
   import org.jboss.seam.annotations.Transactional;
  -
   public class HibernateEntityHome<E> extends Home<E>
   {
  +   private static final long serialVersionUID = 6071072408602519385L;
      private Session session;
  -
      @Override
      public void create()
      {
  @@ -19,14 +16,12 @@
            throw new IllegalStateException("session is null");
         }
      }
  -
      @Transactional
      public boolean isManaged()
      {
         return getInstance()!=null && 
               getSession().contains( getInstance() );
      }
  -
      @Transactional
      public String update()
      {
  @@ -34,7 +29,6 @@
         updatedMessage();
         return "updated";
      }
  -
      @Transactional
      public String persist()
      {
  @@ -44,7 +38,6 @@
         createdMessage();
         return "persisted";
      }
  -
      @Transactional
      public String remove()
      {
  @@ -53,7 +46,6 @@
         deletedMessage();
         return "removed";
      }
  -
      @Transactional
      @Override
      public E find()
  @@ -62,7 +54,6 @@
         if (result==null) result = handleNotFound();
         return result;
      }
  -
      public Session getSession()
      {
         if (session==null)
  @@ -71,10 +62,8 @@
         }
         return session;
      }
  -
      public void setSession(Session session)
      {
         this.session = session;
      }
  -
   }
  
  
  
  1.10      +228 -227  jboss-seam/src/main/org/jboss/seam/framework/Home.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Home.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/framework/Home.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- Home.java	3 Nov 2006 02:50:58 -0000	1.9
  +++ Home.java	21 Dec 2006 02:38:26 -0000	1.10
  @@ -24,6 +24,7 @@
   @Scope(ScopeType.CONVERSATION)
   public class Home<E> extends AbstractMutable implements Serializable
   {
  +   private static final long serialVersionUID = -5462396456614090423L;
      private Object id;
      protected E instance;
      private Class<E> entityClass;
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:27 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:27 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/intercept     ...
Message-ID: <E1GxDpD-0002pX-4z@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:27

  Modified:    src/main/org/jboss/seam/intercept    
                        ClientSideInterceptor.java JavaBeanInterceptor.java
                        RootInterceptor.java SessionBeanInterceptor.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.9       +2 -1      jboss-seam/src/main/org/jboss/seam/intercept/ClientSideInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClientSideInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/ClientSideInterceptor.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ClientSideInterceptor.java	6 Dec 2006 06:07:31 -0000	1.8
  +++ ClientSideInterceptor.java	21 Dec 2006 02:38:27 -0000	1.9
  @@ -1,4 +1,4 @@
  -//$Id: ClientSideInterceptor.java,v 1.8 2006/12/06 06:07:31 gavin Exp $
  +//$Id: ClientSideInterceptor.java,v 1.9 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.intercept;
   
   import java.lang.reflect.Method;
  @@ -21,6 +21,7 @@
   public class ClientSideInterceptor extends RootInterceptor 
         implements MethodInterceptor
   {
  +   private static final long serialVersionUID = -1578313703571846699L;
      
      private final Object bean;
      private final Class beanClass;
  
  
  
  1.11      +2 -1      jboss-seam/src/main/org/jboss/seam/intercept/JavaBeanInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JavaBeanInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/JavaBeanInterceptor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- JavaBeanInterceptor.java	6 Dec 2006 06:07:32 -0000	1.10
  +++ JavaBeanInterceptor.java	21 Dec 2006 02:38:27 -0000	1.11
  @@ -1,4 +1,4 @@
  -//$Id: JavaBeanInterceptor.java,v 1.10 2006/12/06 06:07:32 gavin Exp $
  +//$Id: JavaBeanInterceptor.java,v 1.11 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.intercept;
   
   import java.lang.reflect.Method;
  @@ -21,6 +21,7 @@
   public class JavaBeanInterceptor extends RootInterceptor
         implements MethodInterceptor
   {
  +   private static final long serialVersionUID = -771725005103740533L;
      
      private final Object bean;
      private final Class beanClass;
  
  
  
  1.8       +177 -177  jboss-seam/src/main/org/jboss/seam/intercept/RootInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RootInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/RootInterceptor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- RootInterceptor.java	16 Dec 2006 02:58:11 -0000	1.7
  +++ RootInterceptor.java	21 Dec 2006 02:38:27 -0000	1.8
  @@ -25,7 +25,7 @@
    */
   public class RootInterceptor implements Serializable
   {
  -   
  +   private static final long serialVersionUID = 8041533870186694663L;
      private static final LogProvider log = Logging.getLogProvider(RootInterceptor.class);
      
      private final InterceptorType type;
  
  
  
  1.11      +117 -116  jboss-seam/src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SessionBeanInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- SessionBeanInterceptor.java	16 Dec 2006 02:58:11 -0000	1.10
  +++ SessionBeanInterceptor.java	21 Dec 2006 02:38:27 -0000	1.11
  @@ -28,6 +28,7 @@
    */
   public class SessionBeanInterceptor extends RootInterceptor
   {
  +   private static final long serialVersionUID = -7474586917199426345L;
      private static final LogProvider log = Logging.getLogProvider(SessionBeanInterceptor.class);
      
      public static ThreadLocal<Component> COMPONENT = new ThreadLocal<Component>();
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:27 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:27 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/interceptors ...
Message-ID: <E1GxDpD-0002qQ-E5@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:27

  Modified:    src/main/org/jboss/seam/interceptors                 
                        AbstractInterceptor.java
                        AsynchronousInterceptor.java
                        BijectionInterceptor.java
                        BusinessProcessInterceptor.java
                        ConversationInterceptor.java
                        ConversationalInterceptor.java
                        EventInterceptor.java ExceptionInterceptor.java
                        ManagedEntityIdentityInterceptor.java
                        MethodContextInterceptor.java
                        OutcomeInterceptor.java RemoveInterceptor.java
                        RollbackInterceptor.java SecurityInterceptor.java
                        SynchronizationInterceptor.java
                        TransactionInterceptor.java
                        ValidationInterceptor.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.8       +34 -33    jboss-seam/src/main/org/jboss/seam/interceptors/AbstractInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/AbstractInterceptor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- AbstractInterceptor.java	10 Oct 2006 06:43:16 -0000	1.7
  +++ AbstractInterceptor.java	21 Dec 2006 02:38:27 -0000	1.8
  @@ -1,4 +1,4 @@
  -//$Id: AbstractInterceptor.java,v 1.7 2006/10/10 06:43:16 gavin Exp $
  +//$Id: AbstractInterceptor.java,v 1.8 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import java.io.Serializable;
  @@ -12,6 +12,7 @@
    */
   public class AbstractInterceptor implements Serializable
   {
  +   private static final long serialVersionUID = -8838873111255032911L;
      private transient Component component; //a cache of the Component reference
      private String componentName;
   
  
  
  
  1.9       +36 -38    jboss-seam/src/main/org/jboss/seam/interceptors/AsynchronousInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsynchronousInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/AsynchronousInterceptor.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- AsynchronousInterceptor.java	14 Dec 2006 10:27:00 -0000	1.8
  +++ AsynchronousInterceptor.java	21 Dec 2006 02:38:27 -0000	1.9
  @@ -1,7 +1,5 @@
   package org.jboss.seam.interceptors;
  -
   import javax.ejb.Timer;
  -
   import org.jboss.seam.InterceptorType;
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Asynchronous;
  @@ -10,10 +8,10 @@
   import org.jboss.seam.core.Dispatcher;
   import org.jboss.seam.core.LocalDispatcher;
   import org.jboss.seam.intercept.InvocationContext;
  -
   @Interceptor(type=InterceptorType.CLIENT)
   public class AsynchronousInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 9194177339867853303L;
      @AroundInvoke
      public Object invokeAsynchronouslyIfNecessary(InvocationContext invocation) throws Exception
      {
  
  
  
  1.25      +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/BijectionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BijectionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/BijectionInterceptor.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- BijectionInterceptor.java	16 Dec 2006 02:58:11 -0000	1.24
  +++ BijectionInterceptor.java	21 Dec 2006 02:38:27 -0000	1.25
  @@ -1,4 +1,4 @@
  -//$Id: BijectionInterceptor.java,v 1.24 2006/12/16 02:58:11 nrichards Exp $
  +//$Id: BijectionInterceptor.java,v 1.25 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import static org.jboss.seam.util.EJB.POST_ACTIVATE;
  @@ -25,6 +25,7 @@
   @Interceptor(stateless=true)
   public class BijectionInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 4686458105931528659L;
      
      private static final LogProvider log = Logging.getLogProvider(BijectionInterceptor.class);
      
  
  
  
  1.49      +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BusinessProcessInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -b -r1.48 -r1.49
  --- BusinessProcessInterceptor.java	18 Dec 2006 20:23:08 -0000	1.48
  +++ BusinessProcessInterceptor.java	21 Dec 2006 02:38:27 -0000	1.49
  @@ -29,12 +29,13 @@
    * Interceptor which handles interpretation of jBPM-related annotations.
    *
    * @author <a href="mailto:steve at hibernate.org">Steve Ebersole </a>
  - * @version $Revision: 1.48 $
  + * @version $Revision: 1.49 $
    */
   @Interceptor(stateless=true,
                around={ValidationInterceptor.class, BijectionInterceptor.class, OutcomeInterceptor.class})
   public class BusinessProcessInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 758197867958840918L;
      
      private static final LogProvider log = Logging.getLogProvider( BusinessProcessInterceptor.class );
   
  
  
  
  1.57      +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/ConversationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ConversationInterceptor.java,v
  retrieving revision 1.56
  retrieving revision 1.57
  diff -u -b -r1.56 -r1.57
  --- ConversationInterceptor.java	19 Dec 2006 16:57:04 -0000	1.56
  +++ ConversationInterceptor.java	21 Dec 2006 02:38:27 -0000	1.57
  @@ -1,4 +1,4 @@
  -//$Id: ConversationInterceptor.java,v 1.56 2006/12/19 16:57:04 gavin Exp $
  +//$Id: ConversationInterceptor.java,v 1.57 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -31,6 +31,7 @@
                within=BusinessProcessInterceptor.class)
   public class ConversationInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = -5405533438107796414L;
   
      @AroundInvoke
      public Object endOrBeginLongRunningConversation(InvocationContext invocation) throws Exception
  
  
  
  1.12      +3 -2      jboss-seam/src/main/org/jboss/seam/interceptors/ConversationalInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversationalInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ConversationalInterceptor.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- ConversationalInterceptor.java	16 Dec 2006 02:58:11 -0000	1.11
  +++ ConversationalInterceptor.java	21 Dec 2006 02:38:27 -0000	1.12
  @@ -1,4 +1,4 @@
  -//$Id: ConversationalInterceptor.java,v 1.11 2006/12/16 02:58:11 nrichards Exp $
  +//$Id: ConversationalInterceptor.java,v 1.12 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -31,6 +31,7 @@
                around={ValidationInterceptor.class, BijectionInterceptor.class, OutcomeInterceptor.class, BusinessProcessInterceptor.class})
   public class ConversationalInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 1127583515811479385L;
   
      private static final LogProvider log = Logging.getLogProvider(ConversationalInterceptor.class);
   
  
  
  
  1.5       +59 -63    jboss-seam/src/main/org/jboss/seam/interceptors/EventInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EventInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/EventInterceptor.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- EventInterceptor.java	1 Nov 2006 02:54:02 -0000	1.4
  +++ EventInterceptor.java	21 Dec 2006 02:38:27 -0000	1.5
  @@ -1,13 +1,10 @@
   package org.jboss.seam.interceptors;
  -
   import java.lang.reflect.Method;
  -
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.annotations.RaiseEvent;
   import org.jboss.seam.core.Events;
   import org.jboss.seam.intercept.InvocationContext;
  -
   /**
    * Raises Seam events connected with a bean lifecycle.
    * 
  @@ -20,18 +17,18 @@
                        RollbackInterceptor.class})
   public class EventInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = -136300200838134612L;
  +   
      /*@PostConstruct
      public void postConstruct(InvocationContext ctx)
      {
         Events.instance().raiseEvent("org.jboss.seam.postConstruct." + component.getName());
      }
  -
      @PreDestroy
      public void preDestroy(InvocationContext ctx)
      {
         Events.instance().raiseEvent("org.jboss.seam.preDestroy." + component.getName());
      }
  -
      @PrePassivate
      public void prePassivate(InvocationContext ctx)
      {
  @@ -43,7 +40,6 @@
      {
         Events.instance().raiseEvent("org.jboss.seam.postActivate." + component.getName());
      }*/
  -   
      @AroundInvoke
      public Object aroundInvoke(InvocationContext ctx) throws Exception
      {
  
  
  
  1.15      +3 -2      jboss-seam/src/main/org/jboss/seam/interceptors/ExceptionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExceptionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ExceptionInterceptor.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- ExceptionInterceptor.java	29 Nov 2006 12:43:22 -0000	1.14
  +++ ExceptionInterceptor.java	21 Dec 2006 02:38:27 -0000	1.15
  @@ -1,4 +1,4 @@
  -// $Id: ExceptionInterceptor.java,v 1.14 2006/11/29 12:43:22 gavin Exp $
  +// $Id: ExceptionInterceptor.java,v 1.15 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import static org.jboss.seam.contexts.Contexts.getEventContext;
  @@ -21,6 +21,7 @@
   @Interceptor(stateless = true, type = InterceptorType.CLIENT)
   public class ExceptionInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 748337911616171944L;
   
      private static final String OUTERMOST_EXCEPTION_INTERCEPTOR = "org.jboss.seam.outermostExceptionInterceptor";
   
  
  
  
  1.18      +106 -110  jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ManagedEntityIdentityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- ManagedEntityIdentityInterceptor.java	16 Dec 2006 10:17:14 -0000	1.17
  +++ ManagedEntityIdentityInterceptor.java	21 Dec 2006 02:38:27 -0000	1.18
  @@ -1,10 +1,8 @@
   package org.jboss.seam.interceptors;
  -
   import java.lang.reflect.Field;
   import java.lang.reflect.Modifier;
   import java.util.ArrayList;
   import java.util.List;
  -
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Interceptor;
  @@ -12,7 +10,6 @@
   import org.jboss.seam.core.PersistenceContexts;
   import org.jboss.seam.intercept.InvocationContext;
   import org.jboss.seam.util.Reflections;
  -
   /**
    * Swizzles entity references around each invocation, maintaining
    * referential integrity even across passivation of the stateful 
  @@ -25,9 +22,9 @@
   @Interceptor(around=BijectionInterceptor.class)
   public class ManagedEntityIdentityInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 3105217046803964083L;
      
      //TODO: cache much more - the list of fields, PassivatedEntity obects, etc
  -   
      private List<PassivatedEntity> passivatedEntities = new ArrayList<PassivatedEntity>();
      
      @AroundInvoke
  @@ -80,7 +77,6 @@
            }
         }
      }
  -
      public void entityIdsToRefs(InvocationContext ctx) throws Exception
      {
         if ( passivatedEntities.size()>0 )
  
  
  
  1.3       +34 -35    jboss-seam/src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodContextInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MethodContextInterceptor.java	16 Dec 2006 10:17:14 -0000	1.2
  +++ MethodContextInterceptor.java	21 Dec 2006 02:38:27 -0000	1.3
  @@ -1,12 +1,10 @@
   package org.jboss.seam.interceptors;
  -
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.intercept.InvocationContext;
  -
   /**
    * Sets up the METHOD context and unproxies the SFSB 
    * for the duration of the call.
  @@ -17,6 +15,7 @@
   @Interceptor(stateless=true, around={BijectionInterceptor.class, EventInterceptor.class, SecurityInterceptor.class})
   public class MethodContextInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 6833040683938889232L;
      @AroundInvoke
      public Object aroundInvoke(InvocationContext ctx) throws Exception
      {
  
  
  
  1.7       +26 -28    jboss-seam/src/main/org/jboss/seam/interceptors/OutcomeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OutcomeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/OutcomeInterceptor.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- OutcomeInterceptor.java	1 Nov 2006 02:54:02 -0000	1.6
  +++ OutcomeInterceptor.java	21 Dec 2006 02:38:27 -0000	1.7
  @@ -1,14 +1,11 @@
  -//$Id: OutcomeInterceptor.java,v 1.6 2006/11/01 02:54:02 gavin Exp $
  +//$Id: OutcomeInterceptor.java,v 1.7 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
  -
   import javax.faces.event.PhaseId;
  -
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.annotations.Outcome;
   import org.jboss.seam.contexts.Lifecycle;
   import org.jboss.seam.intercept.InvocationContext;
  -
   /**
    * Translates Outcome.RETRY to null for JSF
    * 
  @@ -17,6 +14,7 @@
   @Interceptor(stateless=true)
   public class OutcomeInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 3964713422043590510L;
      @AroundInvoke
      public Object interceptOutcome(InvocationContext invocation) throws Exception
      {
  
  
  
  1.19      +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/RemoveInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/RemoveInterceptor.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- RemoveInterceptor.java	16 Dec 2006 02:58:11 -0000	1.18
  +++ RemoveInterceptor.java	21 Dec 2006 02:38:27 -0000	1.19
  @@ -1,4 +1,4 @@
  -//$Id: RemoveInterceptor.java,v 1.18 2006/12/16 02:58:11 nrichards Exp $
  +//$Id: RemoveInterceptor.java,v 1.19 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import java.lang.reflect.Method;
  @@ -24,6 +24,7 @@
   @Interceptor(type=InterceptorType.CLIENT)
   public class RemoveInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = -6693606158918954699L;
      
      private static final LogProvider log = Logging.getLogProvider(RemoveInterceptor.class);
   
  
  
  
  1.15      +69 -75    jboss-seam/src/main/org/jboss/seam/interceptors/RollbackInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RollbackInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/RollbackInterceptor.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- RollbackInterceptor.java	8 Nov 2006 17:32:43 -0000	1.14
  +++ RollbackInterceptor.java	21 Dec 2006 02:38:27 -0000	1.15
  @@ -1,21 +1,17 @@
  -//$Id: RollbackInterceptor.java,v 1.14 2006/11/08 17:32:43 gavin Exp $
  +//$Id: RollbackInterceptor.java,v 1.15 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
  -
   import static org.jboss.seam.ComponentType.JAVA_BEAN;
   import static org.jboss.seam.util.EJB.APPLICATION_EXCEPTION;
   import static org.jboss.seam.util.EJB.rollback;
  -
   import java.lang.reflect.Method;
   import java.util.Arrays;
   import java.util.List;
  -
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.annotations.Outcome;
   import org.jboss.seam.annotations.Rollback;
   import org.jboss.seam.intercept.InvocationContext;
   import org.jboss.seam.util.Transactions;
  -
   /**
    * Automatically sets transactions to rollback only.
    * 
  @@ -24,7 +20,7 @@
   @Interceptor(stateless=true, around=OutcomeInterceptor.class)
   public class RollbackInterceptor extends AbstractInterceptor 
   {
  -   
  +   private static final long serialVersionUID = 5551801508325093417L;
      @AroundInvoke
      public Object rollbackIfNecessary(InvocationContext invocation) throws Exception 
      {
  @@ -54,7 +50,6 @@
            throw e;
         }
      }
  -
      private boolean isRollbackRequired(Method method, final Object result)
      {
         if ( !method.isAnnotationPresent(Rollback.class) ) return false;
  @@ -64,7 +59,6 @@
               ( result==null && outcomeList.contains(Outcome.REDISPLAY) ) || 
               outcomeList.contains(result);
      }
  -
      private boolean isRollbackRequired(Exception e)
      {
         Class<? extends Exception> clazz = e.getClass();
  
  
  
  1.15      +27 -29    jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/SecurityInterceptor.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- SecurityInterceptor.java	13 Dec 2006 04:59:31 -0000	1.14
  +++ SecurityInterceptor.java	21 Dec 2006 02:38:27 -0000	1.15
  @@ -14,15 +14,13 @@
    *
    * @author Shane Bryzak
    */
  - at Interceptor(stateless = true,
  -             around = ValidationInterceptor.class,
  -             within = BijectionInterceptor.class)
  + at Interceptor(stateless = true, around = ValidationInterceptor.class, within = BijectionInterceptor.class)
   public class SecurityInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = -6567750187000766925L;
   
     @AroundInvoke
  -  public Object checkSecurity(InvocationContext invocation)
  -      throws Exception
  +   public Object checkSecurity(InvocationContext invocation) throws Exception
     {
       Restrict r = null;
   
  
  
  
  1.5       +2 -1      jboss-seam/src/main/org/jboss/seam/interceptors/SynchronizationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SynchronizationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/SynchronizationInterceptor.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- SynchronizationInterceptor.java	1 Nov 2006 02:54:02 -0000	1.4
  +++ SynchronizationInterceptor.java	21 Dec 2006 02:38:27 -0000	1.5
  @@ -1,4 +1,4 @@
  -//$Id: SynchronizationInterceptor.java,v 1.4 2006/11/01 02:54:02 gavin Exp $
  +//$Id: SynchronizationInterceptor.java,v 1.5 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
   
   import java.util.concurrent.TimeUnit;
  @@ -17,6 +17,7 @@
   @Interceptor(type=InterceptorType.CLIENT)
   public class SynchronizationInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = -4173880108889358566L;
      
      private ReentrantLock lock = new ReentrantLock(true);
      
  
  
  
  1.12      +52 -61    jboss-seam/src/main/org/jboss/seam/interceptors/TransactionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/TransactionInterceptor.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- TransactionInterceptor.java	16 Dec 2006 10:17:14 -0000	1.11
  +++ TransactionInterceptor.java	21 Dec 2006 02:38:27 -0000	1.12
  @@ -1,14 +1,11 @@
   package org.jboss.seam.interceptors;
  -
   import java.lang.reflect.AnnotatedElement;
   import java.lang.reflect.Method;
  -
   import org.jboss.seam.annotations.AroundInvoke;
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.annotations.Transactional;
   import org.jboss.seam.intercept.InvocationContext;
   import org.jboss.seam.util.Work;
  -
   /**
    * Implements transaction propagation rules for Seam JavaBean components.
    * 
  @@ -19,37 +16,32 @@
                around={RollbackInterceptor.class, BusinessProcessInterceptor.class, ConversationInterceptor.class})
   public class TransactionInterceptor extends AbstractInterceptor
   {
  -   
  +   private static final long serialVersionUID = -4364203056333738988L;
      @AroundInvoke
      public Object doInTransactionIfNecessary(final InvocationContext invocation) throws Exception
      {
         return new Work()
         {
  -
            @Override
            protected Object work() throws Exception
            {
               return invocation.proceed();
            }
  -
            @Override
            protected boolean isNewTransactionRequired(boolean transactionActive)
            {
               return isNewTransactionRequired( invocation.getMethod(), getComponent().getBeanClass(), transactionActive );
            }
  -
            private boolean isNewTransactionRequired(Method method, Class beanClass, boolean transactionActive)
            {
               return isTransactionAnnotationPresent(method) ? 
                     isNewTransactionRequired(method, transactionActive) :
                     isTransactionAnnotationPresent(beanClass) && isNewTransactionRequired(beanClass, transactionActive);
            }
  -
            private boolean isTransactionAnnotationPresent(AnnotatedElement element)
            {
               return element.isAnnotationPresent(Transactional.class);
            }
  -
            private boolean isNewTransactionRequired(AnnotatedElement element, boolean transactionActive)
            {
               return element.getAnnotation(Transactional.class).value().isNewTransactionRequired(transactionActive);
  @@ -57,5 +49,4 @@
            
         }.workInTransaction();      
      }
  -
   }
  
  
  
  1.26      +96 -101   jboss-seam/src/main/org/jboss/seam/interceptors/ValidationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ValidationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/interceptors/ValidationInterceptor.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- ValidationInterceptor.java	16 Dec 2006 10:17:14 -0000	1.25
  +++ ValidationInterceptor.java	21 Dec 2006 02:38:27 -0000	1.26
  @@ -1,11 +1,8 @@
  -//$Id: ValidationInterceptor.java,v 1.25 2006/12/16 10:17:14 gavin Exp $
  +//$Id: ValidationInterceptor.java,v 1.26 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.interceptors;
  -
   import java.lang.reflect.Method;
  -
   import javax.persistence.Entity;
   import javax.persistence.EntityManager;
  -
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
   import org.hibernate.Session;
  @@ -16,7 +13,6 @@
   import org.jboss.seam.annotations.Interceptor;
   import org.jboss.seam.core.FacesMessages;
   import org.jboss.seam.intercept.InvocationContext;
  -
   /**
    * Validate the method receiver using Hibernate validator before
    * invoking the method. If a validation failure occurs, put
  @@ -31,9 +27,9 @@
   @SuppressWarnings("deprecation")
   public class ValidationInterceptor extends AbstractInterceptor
   {
  +   private static final long serialVersionUID = 4724500409653141512L;
   
      private static final LogProvider log = Logging.getLogProvider(ValidationInterceptor.class);
  -
      @AroundInvoke
      public Object validateTargetComponent(InvocationContext invocation) throws Exception
      {
  @@ -67,7 +63,6 @@
            return invocation.proceed();
         }
      }
  -
      private void refreshInvalidEntity(IfInvalid ifInvalid, Object entity) {
         Object persistenceContext = Component.getInstance( ifInvalid.persistenceContext(), false );
         if (persistenceContext==null) 
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:27 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:27 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/jsf           ...
Message-ID: <E1GxDpD-0002qy-JN@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:27

  Modified:    src/main/org/jboss/seam/jsf           ArrayDataModel.java
                        ListDataModel.java MapDataModel.java
                        SeamExtendedManagedPersistencePhaseListener.java
                        SeamExtendedManagedPersistencePortletPhaseListener.java
                        SeamPhaseListener.java
                        SeamPortletPhaseListener.java SetDataModel.java
                        TransactionalSeamPhaseListener.java
                        TransactionalSeamPortletPhaseListener.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.2       +30 -33    jboss-seam/src/main/org/jboss/seam/jsf/ArrayDataModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ArrayDataModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/ArrayDataModel.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ArrayDataModel.java	27 Dec 2005 00:42:54 -0000	1.1
  +++ ArrayDataModel.java	21 Dec 2006 02:38:27 -0000	1.2
  @@ -1,33 +1,30 @@
  -//$Id: ArrayDataModel.java,v 1.1 2005/12/27 00:42:54 gavin Exp $
  +//$Id: ArrayDataModel.java,v 1.2 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.jsf;
  -
   import java.io.IOException;
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
   import java.io.Serializable;
  -
  -public class ArrayDataModel extends javax.faces.model.ArrayDataModel implements Serializable
  +public class ArrayDataModel extends javax.faces.model.ArrayDataModel implements
  +      Serializable
   {
  +   private static final long serialVersionUID = -1369792328129853864L;
      private void writeObject(ObjectOutputStream oos) throws IOException 
      {
  -      oos.writeObject( getWrappedData() );
  -      oos.writeInt( getRowIndex() );
  +      oos.writeObject(getWrappedData());
  +      oos.writeInt(getRowIndex());
      }
  -
  -   private void readObject(ObjectInputStream ois) throws IOException, ClassNotFoundException 
  +   private void readObject(ObjectInputStream ois) throws IOException,
  +         ClassNotFoundException
      {
  -      this.setWrappedData( ois.readObject() );
  -      this.setRowIndex( ois.readInt() );
  +      this.setWrappedData(ois.readObject());
  +      this.setRowIndex(ois.readInt());
      }
  -
      public ArrayDataModel()
      {
         super();
      }
  -
      public ArrayDataModel(Object[] array)
      {
         super(array);
      }
  -   
   }
  
  
  
  1.2       +30 -34    jboss-seam/src/main/org/jboss/seam/jsf/ListDataModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ListDataModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/ListDataModel.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ListDataModel.java	17 Sep 2005 20:19:53 -0000	1.1
  +++ ListDataModel.java	21 Dec 2006 02:38:27 -0000	1.2
  @@ -1,31 +1,27 @@
  -//$Id: ListDataModel.java,v 1.1 2005/09/17 20:19:53 gavin Exp $
  +//$Id: ListDataModel.java,v 1.2 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.jsf;
  -
   import java.io.IOException;
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
   import java.io.Serializable;
   import java.util.List;
  -
   public class ListDataModel extends javax.faces.model.ListDataModel implements Serializable
   {
  +   private static final long serialVersionUID = 5156131434571541698L;
      private void writeObject(ObjectOutputStream oos) throws IOException 
      {
         oos.writeObject( getWrappedData() );
         oos.writeInt( getRowIndex() );
      }
  -
      private void readObject(ObjectInputStream ois) throws IOException, ClassNotFoundException 
      {
         this.setWrappedData( ois.readObject() );
         this.setRowIndex( ois.readInt() );
      }
  -
      public ListDataModel()
      {
         super();
      }
  -
      public ListDataModel(List list)
      {
         super(list);
  
  
  
  1.3       +113 -126  jboss-seam/src/main/org/jboss/seam/jsf/MapDataModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MapDataModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/MapDataModel.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MapDataModel.java	25 Oct 2006 15:14:36 -0000	1.2
  +++ MapDataModel.java	21 Dec 2006 02:38:27 -0000	1.3
  @@ -1,6 +1,5 @@
  -//$Id: MapDataModel.java,v 1.2 2006/10/25 15:14:36 gavin Exp $
  +//$Id: MapDataModel.java,v 1.3 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.jsf;
  -
   import java.io.IOException;
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
  @@ -8,22 +7,20 @@
   import java.util.ArrayList;
   import java.util.List;
   import java.util.Map;
  -
   import javax.faces.model.DataModelEvent;
   import javax.faces.model.DataModelListener;
  -
   public class MapDataModel extends javax.faces.model.DataModel implements
         Serializable
   {
  +   private static final long serialVersionUID = -4888962547222002402L;
  +   
      private int rowIndex = -1;
      private Map map;
      private List<Map.Entry> entries;
  -
      public MapDataModel()
      {
         super();
      }
  -
      public MapDataModel(Map map)
      {
         if (map == null)
  @@ -32,7 +29,6 @@
         }
         setWrappedData(map);
      }
  -
      @Override
      public int getRowCount()
      {
  @@ -42,7 +38,6 @@
         }
         return map.size();
      }
  -
      /**
       * Returns a Map.Entry
       */
  @@ -59,25 +54,21 @@
         }
         return entries.get(rowIndex);
      }
  -
      @Override
      public int getRowIndex()
      {
         return rowIndex;
      }
  -
      @Override
      public Object getWrappedData()
      {
         return map;
      }
  -
      @Override
      public boolean isRowAvailable()
      {
         return entries!=null && rowIndex >= 0 && rowIndex < entries.size();
      }
  -
      @Override
      public void setRowIndex(int newRowIndex)
      {
  @@ -98,7 +89,6 @@
            }
         }
      }
  -
      @Override
      public void setWrappedData(Object data)
      {
  @@ -107,14 +97,12 @@
         int rowIndex = data != null ? 0 : -1;
         setRowIndex(rowIndex);
      }
  -
      private void writeObject(ObjectOutputStream oos) throws IOException
      {
         oos.writeObject(map);
         oos.writeInt(rowIndex);
         oos.writeObject(entries);
      }
  -
      private void readObject(ObjectInputStream ois) throws IOException,
            ClassNotFoundException
      {
  @@ -122,5 +110,4 @@
         rowIndex = ois.readInt();
         entries = (List<Map.Entry>) ois.readObject();
      }
  -
   }
  
  
  
  1.24      +12 -9     jboss-seam/src/main/org/jboss/seam/jsf/SeamExtendedManagedPersistencePhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamExtendedManagedPersistencePhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamExtendedManagedPersistencePhaseListener.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- SeamExtendedManagedPersistencePhaseListener.java	4 Nov 2006 01:27:43 -0000	1.23
  +++ SeamExtendedManagedPersistencePhaseListener.java	21 Dec 2006 02:38:27 -0000	1.24
  @@ -1,9 +1,12 @@
   package org.jboss.seam.jsf;
  -
   /**
    * @deprecated use TransactionalSeamPhaseListener
    * @author Gavin King
    *
    */
   public class SeamExtendedManagedPersistencePhaseListener extends
  -      TransactionalSeamPhaseListener {}
  +      TransactionalSeamPhaseListener 
  +{
  +   private static final long serialVersionUID = -3050332015324532147L;
  +   
  +}
  
  
  
  1.8       +11 -12    jboss-seam/src/main/org/jboss/seam/jsf/SeamExtendedManagedPersistencePortletPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamExtendedManagedPersistencePortletPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamExtendedManagedPersistencePortletPhaseListener.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- SeamExtendedManagedPersistencePortletPhaseListener.java	4 Nov 2006 01:27:43 -0000	1.7
  +++ SeamExtendedManagedPersistencePortletPhaseListener.java	21 Dec 2006 02:38:27 -0000	1.8
  @@ -1,5 +1,4 @@
   package org.jboss.seam.jsf;
  -
   /**
    * @deprecated use TransactionalSeamPortletPhaseListener
    * @author Gavin King
  @@ -8,5 +7,5 @@
   public class SeamExtendedManagedPersistencePortletPhaseListener extends
         TransactionalSeamPortletPhaseListener
   {
  -
  +   private static final long serialVersionUID = 934882938114880667L;
   }
  
  
  
  1.96      +2 -1      jboss-seam/src/main/org/jboss/seam/jsf/SeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamPhaseListener.java,v
  retrieving revision 1.95
  retrieving revision 1.96
  diff -u -b -r1.95 -r1.96
  --- SeamPhaseListener.java	18 Dec 2006 01:46:24 -0000	1.95
  +++ SeamPhaseListener.java	21 Dec 2006 02:38:27 -0000	1.96
  @@ -30,6 +30,7 @@
    */
   public class SeamPhaseListener extends AbstractSeamPhaseListener
   {
  +   private static final long serialVersionUID = -9127555729455066493L;
   
      private static final LogProvider log = Logging.getLogProvider(SeamPhaseListener.class);
      
  
  
  
  1.19      +2 -1      jboss-seam/src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamPortletPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- SeamPortletPhaseListener.java	18 Dec 2006 01:46:24 -0000	1.18
  +++ SeamPortletPhaseListener.java	21 Dec 2006 02:38:27 -0000	1.19
  @@ -33,6 +33,7 @@
    */
   public class SeamPortletPhaseListener extends AbstractSeamPhaseListener
   {
  +   private static final long serialVersionUID = 262187729483387144L;
   
      private static final LogProvider log = Logging.getLogProvider( SeamPortletPhaseListener.class );
   
  
  
  
  1.3       +124 -123  jboss-seam/src/main/org/jboss/seam/jsf/SetDataModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SetDataModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/SetDataModel.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SetDataModel.java	25 Oct 2006 15:14:36 -0000	1.2
  +++ SetDataModel.java	21 Dec 2006 02:38:27 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: SetDataModel.java,v 1.2 2006/10/25 15:14:36 gavin Exp $
  +//$Id: SetDataModel.java,v 1.3 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.jsf;
   
   import java.io.IOException;
  @@ -15,6 +15,7 @@
   public class SetDataModel extends javax.faces.model.DataModel implements
         Serializable
   {
  +   private static final long serialVersionUID = -616367764778689337L;
      private int rowIndex = -1;
      private Set set;
      private List entries;
  
  
  
  1.3       +58 -64    jboss-seam/src/main/org/jboss/seam/jsf/TransactionalSeamPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionalSeamPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/TransactionalSeamPhaseListener.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- TransactionalSeamPhaseListener.java	8 Nov 2006 17:32:43 -0000	1.2
  +++ TransactionalSeamPhaseListener.java	21 Dec 2006 02:38:27 -0000	1.3
  @@ -1,11 +1,8 @@
  -//$Id: TransactionalSeamPhaseListener.java,v 1.2 2006/11/08 17:32:43 gavin Exp $
  +//$Id: TransactionalSeamPhaseListener.java,v 1.3 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.jsf;
  -
   import javax.faces.event.PhaseEvent;
   import javax.faces.event.PhaseId;
  -
   import org.jboss.seam.core.Init;
  -
   /**
    * Transaction management for extended persistence contexts.
    * A transaction spans the restore view, apply request values, process validations,
  @@ -17,7 +14,7 @@
    */
   public class TransactionalSeamPhaseListener extends SeamPhaseListener
   {
  -   
  +   private static final long serialVersionUID = -1069952157355781194L;
      @Override
      public void handleTransactionsBeforePhase(PhaseEvent event)
      {
  @@ -30,7 +27,6 @@
            begin(phaseId);
         }
      }
  -
      @Override
      public void handleTransactionsAfterPhase(PhaseEvent event)
      {
  @@ -45,7 +41,6 @@
            commitOrRollback(phaseId); //we commit before destroying contexts, cos the contexts have the PC in them
         }     
      }
  -
      @Override
      protected void handleTransactionsAfterPageActions(PhaseEvent event)
      {
  @@ -60,5 +55,4 @@
      protected void afterInvokeApplication() {
         addTransactionFailedMessage();
      }
  -
   }
  
  
  
  1.3       +57 -63    jboss-seam/src/main/org/jboss/seam/jsf/TransactionalSeamPortletPhaseListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionalSeamPortletPhaseListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/jsf/TransactionalSeamPortletPhaseListener.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- TransactionalSeamPortletPhaseListener.java	8 Nov 2006 17:32:43 -0000	1.2
  +++ TransactionalSeamPortletPhaseListener.java	21 Dec 2006 02:38:27 -0000	1.3
  @@ -1,9 +1,7 @@
  -//$Id: TransactionalSeamPortletPhaseListener.java,v 1.2 2006/11/08 17:32:43 gavin Exp $
  +//$Id: TransactionalSeamPortletPhaseListener.java,v 1.3 2006/12/21 02:38:27 sbryzak2 Exp $
   package org.jboss.seam.jsf;
  -
   import javax.faces.event.PhaseEvent;
   import javax.faces.event.PhaseId;
  -
   /**
    * Transaction management for extended persistence contexts.
    * A transaction spans the restore view, apply request values, process validations,
  @@ -15,7 +13,7 @@
    */
   public class TransactionalSeamPortletPhaseListener extends SeamPortletPhaseListener
   {
  -   
  +   private static final long serialVersionUID = -7594991008561871577L;
      @Override
      public void handleTransactionsBeforePhase(PhaseEvent event)
      {
  @@ -29,7 +27,6 @@
            begin(phaseId);
         }
      }
  -
      @Override
      public void handleTransactionsAfterPhase(PhaseEvent event)
      {
  @@ -44,7 +41,6 @@
            commitOrRollback(phaseId); //we commit before destroying contexts, cos the contexts have the PC in them
         }    
      }
  -
      @Override
      protected void handleTransactionsAfterPageActions(PhaseEvent event)
      {
  @@ -54,10 +50,8 @@
            begin(PhaseId.INVOKE_APPLICATION);
         }
      }
  -
      @Override
      protected void afterInvokeApplication() {
         addTransactionFailedMessage();
      }
  -
   }
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:27 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:27 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/log  ...
Message-ID: <E1GxDpD-0002r5-Mq@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:27

  Modified:    src/main/org/jboss/seam/log  LogImpl.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.9       +159 -187  jboss-seam/src/main/org/jboss/seam/log/LogImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LogImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/log/LogImpl.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- LogImpl.java	16 Dec 2006 02:16:28 -0000	1.8
  +++ LogImpl.java	21 Dec 2006 02:38:27 -0000	1.9
  @@ -1,12 +1,9 @@
   package org.jboss.seam.log;
  -
   import java.io.Externalizable;
   import java.io.IOException;
   import java.io.ObjectInput;
   import java.io.ObjectOutput;
  -
   import org.jboss.seam.core.Interpolator;
  -
   /**
    * Implementation of the Log interface using commons logging.
    * 
  @@ -14,48 +11,39 @@
    */
   public class LogImpl implements Log, Externalizable
   {
  -   
  +   private static final long serialVersionUID = -1664298172030714342L;
      private transient LogProvider log;
      private String category;
  -
      public LogImpl() {} //for Externalizable
  -
      LogImpl(String category)
      {
         this.category = category;
         this.log = Logging.getLogProvider(category);
      }
  -
      public boolean isDebugEnabled()
      {
         return log.isDebugEnabled();
      }
  -
      public boolean isErrorEnabled()
      {
         return log.isErrorEnabled();
      }
  -
      public boolean isFatalEnabled()
      {
         return log.isFatalEnabled();
      }
  -
      public boolean isInfoEnabled()
      {
         return log.isInfoEnabled();
      }
  -
      public boolean isTraceEnabled()
      {
         return log.isTraceEnabled();
      }
  -
      public boolean isWarnEnabled()
      {
         return log.isWarnEnabled();
      }
  -
      public void trace(Object object, Object... params)
      {
         if ( isTraceEnabled() )
  @@ -63,7 +51,6 @@
            log.trace(  interpolate(object, params) );
         }
      }
  -
      public void trace(Object object, Throwable t, Object... params)
      {
         if ( isTraceEnabled() )
  @@ -71,7 +58,6 @@
            log.trace(  interpolate(object, params), t );
         }
      }
  -
      public void debug(Object object, Object... params)
      {
         if ( isDebugEnabled() )
  @@ -79,7 +65,6 @@
            log.debug(  interpolate(object, params) );
         }
      }
  -
      public void debug(Object object, Throwable t, Object... params)
      {
         if ( isDebugEnabled() )
  @@ -87,7 +72,6 @@
            log.debug(  interpolate(object, params), t );
         }
      }
  -
      public void info(Object object, Object... params)
      {
         if ( isInfoEnabled() )
  @@ -95,7 +79,6 @@
            log.info( interpolate(object, params) );
         }
      }
  -
      public void info(Object object, Throwable t, Object... params)
      {
         if ( isInfoEnabled() )
  @@ -103,7 +86,6 @@
            log.info( interpolate(object, params), t );
         }
      }
  -
      public void warn(Object object, Object... params)
      {
         if ( isWarnEnabled() )
  @@ -111,7 +93,6 @@
            log.warn( interpolate(object, params) );
         }
      }
  -
      public void warn(Object object, Throwable t, Object... params)
      {
         if ( isWarnEnabled() )
  @@ -119,7 +100,6 @@
            log.warn( interpolate(object, params), t );
         }
      }
  -
      public void error(Object object, Object... params)
      {
         if ( isErrorEnabled() )
  @@ -127,7 +107,6 @@
            log.error( interpolate(object, params) );
         }
      }
  -
      public void error(Object object, Throwable t, Object... params)
      {
         if ( isErrorEnabled() )
  @@ -135,7 +114,6 @@
            log.error( interpolate(object, params), t );
         }
      }
  -
      public void fatal(Object object, Object... params)
      {
         if ( isFatalEnabled() )
  @@ -143,7 +121,6 @@
            log.fatal( interpolate(object, params) );
         }
      }
  -
      public void fatal(Object object, Throwable t, Object... params)
      {
         if ( isFatalEnabled() )
  @@ -163,13 +140,11 @@
            return object;
         }
      }
  -
      public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
      {
         category = (String) in.readObject();
         log = Logging.getLogProvider(category);
      }
  -
      public void writeExternal(ObjectOutput out) throws IOException
      {
         out.writeObject(category);
  @@ -181,7 +156,4 @@
         ois.defaultReadObject();
         log = LogFactory.getLog(category);
      }*/
  -   
  -   
  -
   }
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:27 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:27 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/mock    ...
Message-ID: <E1GxDpD-0002rI-Ss@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:27

  Modified:    src/main/org/jboss/seam/mock    MockAclObjectIdentity.java
                        MockAclPermission.java MockSecureEntity.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.2       +26 -23    jboss-seam/src/main/org/jboss/seam/mock/MockAclObjectIdentity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockAclObjectIdentity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockAclObjectIdentity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MockAclObjectIdentity.java	13 Nov 2006 00:05:58 -0000	1.1
  +++ MockAclObjectIdentity.java	21 Dec 2006 02:38:27 -0000	1.2
  @@ -12,7 +12,10 @@
   @Entity
   public class MockAclObjectIdentity implements Serializable
   {
  +   private static final long serialVersionUID = 1789344626238767199L;
  +
     private Integer id;
  +
     private String objectIdentity;
   
     @Id
  
  
  
  1.4       +64 -58    jboss-seam/src/main/org/jboss/seam/mock/MockAclPermission.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockAclPermission.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockAclPermission.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MockAclPermission.java	4 Dec 2006 01:10:19 -0000	1.3
  +++ MockAclPermission.java	21 Dec 2006 02:38:27 -0000	1.4
  @@ -15,10 +15,16 @@
   @Entity
   public class MockAclPermission implements Serializable
   {
  +   private static final long serialVersionUID = -1399973698080227493L;
  +
     private Integer id;
  +
     private MockAclObjectIdentity identity;
  +
     private RecipientType recipientType;
  +
     private String recipient;
  +
     private int mask;
   
     @Id
  
  
  
  1.4       +30 -28    jboss-seam/src/main/org/jboss/seam/mock/MockSecureEntity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockSecureEntity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/mock/MockSecureEntity.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- MockSecureEntity.java	4 Dec 2006 01:06:50 -0000	1.3
  +++ MockSecureEntity.java	21 Dec 2006 02:38:27 -0000	1.4
  @@ -16,15 +16,17 @@
    */
   @Name("mockSecureEntity")
   @Install(false)
  - at Permissions({
  + at Permissions( {
     @Permission(action = "read", expr = "#{aclPermissionChecker.checkPermission}"),
     @Permission(action = "delete", expr = "#{aclPermissionChecker.checkPermission}"),
  -  @Permission(action = "special", expr = "#{aclPermissionChecker.checkPermission}")
  -})
  +      @Permission(action = "special", expr = "#{aclPermissionChecker.checkPermission}") })
   @Entity
   public class MockSecureEntity implements Serializable
   {
  +   private static final long serialVersionUID = -6885685305122412324L;
  +
     private Integer id;
  +
     private String value;
   
     @Id
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/remoting  ...
Message-ID: <E1GxDpE-0002rP-0p@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/remoting  SeamRemotingServlet.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.13      +143 -142  jboss-seam/src/main/org/jboss/seam/remoting/SeamRemotingServlet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamRemotingServlet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/SeamRemotingServlet.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- SeamRemotingServlet.java	16 Dec 2006 02:58:12 -0000	1.12
  +++ SeamRemotingServlet.java	21 Dec 2006 02:38:27 -0000	1.13
  @@ -28,7 +28,10 @@
    */
   public class SeamRemotingServlet extends HttpServlet
   {
  -  private static final LogProvider log = Logging.getLogProvider(SeamServletFilter.class);
  +   private static final long serialVersionUID = -701000241772063743L;
  +
  +   private static final LogProvider log = Logging
  +         .getLogProvider(SeamServletFilter.class);
   
     private static final Pattern pathPattern = Pattern.compile("/(.*?)/([^/]+)");
   
  @@ -37,10 +40,10 @@
     private ServletContext servletContext;
   
     /**
  -   *  We use a Map for this because a Servlet can serve
  -   *  requests for more than one context path.
  +    * We use a Map for this because a Servlet can serve requests for more than
  +    * one context path.
      */
  -  private Map<String,byte[]> cachedConfig = new HashMap<String,byte[]>();
  +   private Map<String, byte[]> cachedConfig = new HashMap<String, byte[]>();
   
     /**
      * Initialise the Remoting servlet
  @@ -49,8 +52,7 @@
      * @throws ServletException
      */
     @Override
  -  public void init(ServletConfig config)
  -      throws ServletException
  +   public void init(ServletConfig config) throws ServletException
     {
       servletContext = config.getServletContext();
     }
  @@ -64,13 +66,12 @@
   
     @Override
     protected void doPost(HttpServletRequest request,
  -                        HttpServletResponse response)
  -      throws ServletException, IOException
  +         HttpServletResponse response) throws ServletException, IOException
     {
       try
       {
  -      RequestHandler handler = RequestHandlerFactory.getInstance().
  -          getRequestHandler(request.getPathInfo());
  +         RequestHandler handler = RequestHandlerFactory.getInstance()
  +               .getRequestHandler(request.getPathInfo());
         if (handler != null)
         {
           handler.setServletContext(servletContext);
  @@ -89,8 +90,8 @@
               writeResource(resource, response.getOutputStream());
               if ("remote.js".equals(resource))
               {
  -              appendConfig(response.getOutputStream(), request.getContextPath(),
  -                  request.getSession(), request);
  +                     appendConfig(response.getOutputStream(), request
  +                           .getContextPath(), request.getSession(), request);
               }
             }
           }
  @@ -103,13 +104,13 @@
     }
   
     /**
  -   * Appends various configuration options to the remoting javascript client api.
  +    * Appends various configuration options to the remoting javascript client
  +    * api.
      *
      * @param out OutputStream
      */
     private void appendConfig(OutputStream out, String contextPath,
  -                            HttpSession session, ServletRequest request)
  -      throws IOException
  +         HttpSession session, ServletRequest request) throws IOException
     {
       if (!cachedConfig.containsKey(contextPath))
         initConfig(contextPath, session, request);
  @@ -123,8 +124,8 @@
      *
      * @param contextPath String
      */
  -  private synchronized void initConfig(String contextPath, HttpSession session,
  -                                       ServletRequest request)
  +   private synchronized void initConfig(String contextPath,
  +         HttpSession session, ServletRequest request)
     {
       if (!cachedConfig.containsKey(contextPath))
       {
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/remoting/wrapper  ...
Message-ID: <E1GxDpE-0002rW-4i@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/remoting/wrapper 
                        ConversionException.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.3       +11 -9     jboss-seam/src/main/org/jboss/seam/remoting/wrapper/ConversionException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConversionException.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/remoting/wrapper/ConversionException.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ConversionException.java	24 Apr 2006 06:43:58 -0000	1.2
  +++ ConversionException.java	21 Dec 2006 02:38:28 -0000	1.3
  @@ -7,6 +7,8 @@
    */
   public class ConversionException extends Exception
   {
  +   private static final long serialVersionUID = 5584559762846984501L;
  +
     public ConversionException(String message)
     {
       super(message);
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security     ...
Message-ID: <E1GxDpE-0002rm-9o@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/security    
                        AuthenticationException.java Role.java
                        SeamSecurityManager.java UsernamePasswordToken.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.6       +16 -12    jboss-seam/src/main/org/jboss/seam/security/AuthenticationException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AuthenticationException.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/AuthenticationException.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- AuthenticationException.java	24 Oct 2006 14:58:04 -0000	1.5
  +++ AuthenticationException.java	21 Dec 2006 02:38:28 -0000	1.6
  @@ -3,11 +3,15 @@
   import javax.ejb.ApplicationException;
   
   /**
  + * Thrown by the
  + * 
    * @author Shane Bryzak
    */
   @ApplicationException
   public class AuthenticationException extends RuntimeException
   {
  +   private static final long serialVersionUID = -4150337120205930755L;
  +
     public AuthenticationException()
     {
       super();
  
  
  
  1.2       +86 -83    jboss-seam/src/main/org/jboss/seam/security/Role.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Role.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/Role.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- Role.java	4 Dec 2006 04:23:51 -0000	1.1
  +++ Role.java	21 Dec 2006 02:38:28 -0000	1.2
  @@ -16,14 +16,17 @@
    */
   public class Role implements Group, Serializable
   {
  +   private static final long serialVersionUID = 5766373925836425908L;
  +
     /**
      * The name of the role
      */
     private String name;
   
     /**
  -   * The members of this role.  This role has the authority to perform any action
  -   * that any of its members (or member's members, ad infinitum) can perform.
  +    * The members of this role. This role has the authority to perform any
  +    * action that any of its members (or member's members, ad infinitum) can
  +    * perform.
      */
     private Set<Principal> members = new HashSet<Principal>();
   
  
  
  
  1.29      +0 -5      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- SeamSecurityManager.java	20 Dec 2006 03:35:21 -0000	1.28
  +++ SeamSecurityManager.java	21 Dec 2006 02:38:28 -0000	1.29
  @@ -58,11 +58,6 @@
      private RuleBase securityRules;
   
      /**
  -    * Map roles to permissions
  -    */
  -   private Map<String, Set<Permission>> rolePermissions = new HashMap<String, Set<Permission>>();
  -
  -   /**
       * Initialise the security manager
       * 
       * @throws Exception
  
  
  
  1.9       +54 -47    jboss-seam/src/main/org/jboss/seam/security/UsernamePasswordToken.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UsernamePasswordToken.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/UsernamePasswordToken.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- UsernamePasswordToken.java	4 Dec 2006 04:23:51 -0000	1.8
  +++ UsernamePasswordToken.java	21 Dec 2006 02:38:28 -0000	1.9
  @@ -1,12 +1,18 @@
   package org.jboss.seam.security;
   
   /**
  + * An Identity that supports traditional username and password authentication.
  + * 
    * @author Shane Bryzak
    */
   public class UsernamePasswordToken extends Identity
   {
  +   private static final long serialVersionUID = -891900764186531420L;
  +
     private Role[] roles;
  +
     private Object credentials;
  +
     private Object principal;
   
     public UsernamePasswordToken(Object principal, Object credentials)
  @@ -16,7 +22,8 @@
       this.authenticated = false;
     }
   
  -  public UsernamePasswordToken(Object principal, Object credentials, Role[] roles)
  +   public UsernamePasswordToken(Object principal, Object credentials,
  +         Role[] roles)
     {
       this(principal, credentials);
       this.roles = roles;
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/acl  ...
Message-ID: <E1GxDpE-0002rt-Dm@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/security/acl  IdentityException.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.2       +12 -10    jboss-seam/src/main/org/jboss/seam/security/acl/IdentityException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdentityException.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/acl/IdentityException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- IdentityException.java	9 Nov 2006 07:37:04 -0000	1.1
  +++ IdentityException.java	21 Dec 2006 02:38:28 -0000	1.2
  @@ -1,12 +1,14 @@
   package org.jboss.seam.security.acl;
   
   /**
  - *
  + * Thrown while generating identities for domain objects.
    *
    * @author Shane Bryzak
    */
   public class IdentityException extends RuntimeException
   {
  +   private static final long serialVersionUID = 3095635738822653218L;
  +
     public IdentityException(String message)
     {
       super(message);
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1GxDpE-0002s0-I0@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/security/config 
                        SecurityConfigException.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.2       +11 -9     jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfigException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfigException.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfigException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SecurityConfigException.java	24 Jul 2006 07:13:39 -0000	1.1
  +++ SecurityConfigException.java	21 Dec 2006 02:38:28 -0000	1.2
  @@ -8,6 +8,8 @@
    */
   public class SecurityConfigException extends Exception
   {
  +   private static final long serialVersionUID = -5703807591449246104L;
  +
     public SecurityConfigException(String message)
     {
       super(message);
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/filter  ...
Message-ID: <E1GxDpE-0002s7-NA@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/security/filter 
                        SeamSecurityFilter.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.16      +0 -3      jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityFilter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- SeamSecurityFilter.java	16 Dec 2006 02:58:12 -0000	1.15
  +++ SeamSecurityFilter.java	21 Dec 2006 02:38:28 -0000	1.16
  @@ -30,8 +30,6 @@
    */
   public class SeamSecurityFilter implements Filter
   {
  -  private static final LogProvider log = Logging.getLogProvider(SeamSecurityFilter.class);
  -
     private SecurityConfiguration config;
   
     private ServletContext servletContext;
  @@ -64,7 +62,6 @@
   
       Identity ident = (Identity)sessionContext.get(Seam.getComponentName(Identity.class));
   
  -    /** @todo Make the redirection configurable */
       if (!checkSecurityConstraints(hRequest.getServletPath(), hRequest.getMethod(), ident))
         hResponse.sendRedirect(String.format("%s%s", hRequest.getContextPath(),
                                              config.getSecurityErrorPage()));
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:28 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:28 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/theme   ...
Message-ID: <E1GxDpE-0002sH-So@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:28

  Modified:    src/main/org/jboss/seam/theme   Theme.java
                        ThemeSelector.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.4       +113 -112  jboss-seam/src/main/org/jboss/seam/theme/Theme.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Theme.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/theme/Theme.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- Theme.java	24 Nov 2006 23:15:19 -0000	1.3
  +++ Theme.java	21 Dec 2006 02:38:28 -0000	1.4
  @@ -30,6 +30,7 @@
   @Name("org.jboss.seam.theme.theme")
   @Install(precedence=BUILT_IN)
   public class Theme implements Serializable {
  +   private static final long serialVersionUID = -7003055918970882103L;
      
      private transient Map messages;
      
  
  
  
  1.11      +2 -0      jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThemeSelector.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/theme/ThemeSelector.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ThemeSelector.java	18 Dec 2006 11:52:50 -0000	1.10
  +++ ThemeSelector.java	21 Dec 2006 02:38:28 -0000	1.11
  @@ -39,6 +39,8 @@
   @Install(precedence=BUILT_IN)
   public class ThemeSelector extends Selector
   {
  +   private static final long serialVersionUID = 3920407140011388341L;
  +
      private static final LogProvider log = Logging.getLogProvider(ThemeSelector.class);
      
      private String theme;
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:29 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:29 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/util   ...
Message-ID: <E1GxDpF-0002sR-1W@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:29

  Modified:    src/main/org/jboss/seam/util   Conversions.java
                        DTDEntityResolver.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.10      +360 -377  jboss-seam/src/main/org/jboss/seam/util/Conversions.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Conversions.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/Conversions.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- Conversions.java	19 Dec 2006 16:23:38 -0000	1.9
  +++ Conversions.java	21 Dec 2006 02:38:29 -0000	1.10
  @@ -1,5 +1,4 @@
   package org.jboss.seam.util;
  -
   import java.io.Serializable;
   import java.lang.reflect.Array;
   import java.lang.reflect.Type;
  @@ -10,10 +9,9 @@
   import java.util.Map;
   import java.util.Properties;
   import java.util.Set;
  -
   import java.math.BigInteger;
   import java.math.BigDecimal;
  -
  + at SuppressWarnings("serial")
   public class Conversions
   {
      
  @@ -119,7 +117,6 @@
            return  value.getSingleValue() ;
         }
      }
  -
      public static class BigDecimalConverter implements Converter<BigDecimal>
      {
         public BigDecimal toObject(PropertyValue value, Type type)
  @@ -127,7 +124,6 @@
            return new BigDecimal(value.getSingleValue());
         }
      }
  -
      public static class BigIntegerConverter implements Converter<BigInteger>
      {
         public BigInteger toObject(PropertyValue value, Type type)
  @@ -258,7 +254,6 @@
      {
         
         private String string;
  -
         public FlatPropertyValue(String string)
         {
            if (string==null)
  @@ -267,12 +262,10 @@
            }
            this.string = string;
         }
  -
         public String[] getMultiValues()
         {
            return Strings.split(string, ", \r\n\f\t");
         }
  -
         public String getSingleValue()
         {
            return string;
  @@ -282,7 +275,6 @@
         {
            return string.startsWith("#{");
         }
  -
         public Map<String, String> getKeyedValues()
         {
            throw new UnsupportedOperationException("not a keyed property value");
  @@ -298,20 +290,16 @@
      
      public static class MultiPropertyValue implements PropertyValue
      {
  -      
         private String[] strings;
  -
         public MultiPropertyValue(String[] strings)
         {
            if (strings==null) throw new IllegalArgumentException();
            this.strings = strings;
         }
  -
         public String[] getMultiValues()
         {
            return strings;
         }
  -
         public String getSingleValue()
         {
            throw new UnsupportedOperationException("not a flat property value");
  @@ -321,7 +309,6 @@
         {
            throw new UnsupportedOperationException("not a keyed property value");
         }
  -
         public boolean isExpression()
         {
            return false;
  @@ -337,20 +324,16 @@
      
      public static class AssociativePropertyValue implements PropertyValue
      {
  -      
         private Map<String, String> keyedValues;
  -
         public AssociativePropertyValue(Map<String, String> keyedValues)
         {
            if (keyedValues==null) throw new IllegalArgumentException();
            this.keyedValues = keyedValues;
         }
  -
         public String[] getMultiValues()
         {
            throw new UnsupportedOperationException("not a multi-valued property value");
         }
  -
         public String getSingleValue()
         {
            throw new UnsupportedOperationException("not a flat property value");
  
  
  
  1.3       +4 -2      jboss-seam/src/main/org/jboss/seam/util/DTDEntityResolver.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DTDEntityResolver.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/util/DTDEntityResolver.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- DTDEntityResolver.java	16 Dec 2006 02:58:13 -0000	1.2
  +++ DTDEntityResolver.java	21 Dec 2006 02:38:29 -0000	1.3
  @@ -1,4 +1,4 @@
  -//$Id: DTDEntityResolver.java,v 1.2 2006/12/16 02:58:13 nrichards Exp $
  +//$Id: DTDEntityResolver.java,v 1.3 2006/12/21 02:38:29 sbryzak2 Exp $
   //Contributed by Markus Meissner
   package org.jboss.seam.util;
   
  @@ -28,6 +28,8 @@
    */
   public class DTDEntityResolver implements EntityResolver, Serializable {
   
  +   private static final long serialVersionUID = -4553926061006790714L;
  +
   	private static final LogProvider log = Logging.getLogProvider(DTDEntityResolver.class );
   
   	private static final String HIBERNATE_NAMESPACE = "http://jboss.com/products/seam/";
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 20 21:38:29 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 20 Dec 2006 21:38:29 -0500
Subject: [jboss-cvs] jboss-seam/src/test/misc/org/jboss/seam/test     ...
Message-ID: <E1GxDpF-0002sh-7W@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/20 21:38:29

  Modified:    src/test/misc/org/jboss/seam/test     Bar.java Foo.java
                        PhaseListenerTest.java RemotingTest.java
  Log:
  fixed compiler warnings
  
  Revision  Changes    Path
  1.6       +3 -2      jboss-seam/src/test/misc/org/jboss/seam/test/Bar.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Bar.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/Bar.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- Bar.java	20 Nov 2006 23:44:23 -0000	1.5
  +++ Bar.java	21 Dec 2006 02:38:29 -0000	1.6
  @@ -21,13 +21,14 @@
   
   /**
    * @author <a href="mailto:theute at jboss.org">Thomas Heute </a>
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   @Name("bar")
   @Scope(ScopeType.CONVERSATION)
   @Conversational(ifNotBegunOutcome="error")
   public class Bar implements Serializable
   {
  +   private static final long serialVersionUID = -5325217160542604204L;
      
      @In(required=true)
      Foo otherFoo;
  
  
  
  1.7       +2 -1      jboss-seam/src/test/misc/org/jboss/seam/test/Foo.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Foo.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/Foo.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- Foo.java	20 Nov 2006 23:44:23 -0000	1.6
  +++ Foo.java	21 Dec 2006 02:38:29 -0000	1.7
  @@ -20,13 +20,14 @@
   
   /**
    * @author <a href="mailto:theute at jboss.org">Thomas Heute </a>
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   @Name("foo")
   @Scope(ScopeType.SESSION)
   @SuppressWarnings("deprecation")
   public class Foo implements Serializable
   {
  +   private static final long serialVersionUID = -5448030633067107049L;
      
      private String value;
      
  
  
  
  1.29      +2 -1      jboss-seam/src/test/misc/org/jboss/seam/test/PhaseListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PhaseListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/PhaseListenerTest.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- PhaseListenerTest.java	17 Nov 2006 01:14:31 -0000	1.28
  +++ PhaseListenerTest.java	21 Dec 2006 02:38:29 -0000	1.29
  @@ -1,4 +1,4 @@
  -//$Id: PhaseListenerTest.java,v 1.28 2006/11/17 01:14:31 gavin Exp $
  +//$Id: PhaseListenerTest.java,v 1.29 2006/12/21 02:38:29 sbryzak2 Exp $
   package org.jboss.seam.test;
   
   import java.util.ArrayList;
  @@ -126,6 +126,7 @@
         return ScopeType.PAGE.getPrefix() + '$';
      }
   
  +   @SuppressWarnings("serial")
      @Test
      public void testSeamPhaseListenerLongRunning()
      {
  
  
  
  1.9       +965 -744  jboss-seam/src/test/misc/org/jboss/seam/test/RemotingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemotingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/RemotingTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- RemotingTest.java	18 Nov 2006 00:38:23 -0000	1.8
  +++ RemotingTest.java	21 Dec 2006 02:38:29 -0000	1.9
  @@ -60,7 +60,9 @@
    */
   public class RemotingTest
   {
  -  private class InvalidClass {}
  +   private class InvalidClass
  +   {
  +   }
   
     public Element createElement(String name, String value)
         throws UnsupportedEncodingException
  @@ -71,11 +73,13 @@
       return e;
     }
   
  -  private enum TestEnum {red, green, blue}
  +   private enum TestEnum
  +   {
  +      red, green, blue
  +   }
   
     @Test
  -  public void testBooleanWrapper()
  -      throws Exception
  +   public void testBooleanWrapper() throws Exception
     {
       BooleanWrapper wrapper = new BooleanWrapper();
       wrapper.setElement(createElement("bool", Boolean.toString(true)));
  @@ -83,29 +87,34 @@
       assert (Boolean) wrapper.convert(Boolean.class);
       assert (Boolean) wrapper.convert(Boolean.TYPE);
   
  -    try {
  +      try
  +      {
         // Try an invalid conversion
         wrapper.convert(InvalidClass.class);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
       // test the marshal() method
       ByteArrayOutputStream out = new ByteArrayOutputStream();
       wrapper.marshal(out);
  -    byte[] expected = ("<bool>" + Boolean.toString(true) + "</bool>").getBytes();
  +      byte[] expected = ("<bool>" + Boolean.toString(true) + "</bool>")
  +            .getBytes();
       assertEquals(expected, out.toByteArray());
   
       // test the conversionScore() method
       assert ConversionScore.exact == wrapper.conversionScore(Boolean.class);
       assert ConversionScore.exact == wrapper.conversionScore(Boolean.TYPE);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Object.class);
  -    assert ConversionScore.nomatch == wrapper.conversionScore(InvalidClass.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Object.class);
  +      assert ConversionScore.nomatch == wrapper
  +            .conversionScore(InvalidClass.class);
     }
   
     @Test
  -  public void testDateWrapper()
  -      throws Exception
  +   public void testDateWrapper() throws Exception
     {
       DateWrapper wrapper = new DateWrapper();
       String value = "20061231123045150";
  @@ -128,45 +137,57 @@
       byte[] expected = ("<date>" + value + "</date>").getBytes();
       assertEquals(expected, out.toByteArray());
   
  -    try {
  +      try
  +      {
         // this should throw an exception
         wrapper.convert(InvalidClass.class);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
  -    try {
  +      try
  +      {
         // this should throw an exception
         wrapper.setElement(createElement("date", "foobar"));
         wrapper.convert(Date.class);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
       // test conversionScore() method
       assert ConversionScore.exact == wrapper.conversionScore(Date.class);
  -    assert ConversionScore.exact == wrapper.conversionScore(java.sql.Date.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Object.class);
  -    assert ConversionScore.nomatch == wrapper.conversionScore(InvalidClass.class);
  +      assert ConversionScore.exact == wrapper
  +            .conversionScore(java.sql.Date.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Object.class);
  +      assert ConversionScore.nomatch == wrapper
  +            .conversionScore(InvalidClass.class);
     }
   
     @Test
  -  public void testStringWrapper()
  -    throws Exception
  +   public void testStringWrapper() throws Exception
     {
  -    String value = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789" +
  -                   "!@#$%^&*()_+-=`~[]{}|;:\"',./<>?\\ ";
  +      String value = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"
  +            + "!@#$%^&*()_+-=`~[]{}|;:\"',./<>?\\ ";
       StringWrapper wrapper = new StringWrapper();
       wrapper.setElement(createElement("str", value));
   
       assert value.equals(wrapper.convert(String.class));
  -    assert value.equals(((StringBuilder) wrapper.convert(StringBuilder.class)).toString());
  -    assert value.equals(((StringBuffer) wrapper.convert(StringBuffer.class)).toString());
  +      assert value
  +            .equals(((StringBuilder) wrapper.convert(StringBuilder.class))
  +                  .toString());
  +      assert value.equals(((StringBuffer) wrapper.convert(StringBuffer.class))
  +            .toString());
   
       ByteArrayOutputStream out = new ByteArrayOutputStream();
       wrapper.marshal(out);
  -    byte[] expected = ("<str>" + URLEncoder.encode(value, StringWrapper.DEFAULT_ENCODING) +
  -                       "</str>").replace("+", "%20").getBytes();
  +      byte[] expected = ("<str>"
  +            + URLEncoder.encode(value, StringWrapper.DEFAULT_ENCODING) + "</str>")
  +            .replace("+", "%20").getBytes();
   
       assertEquals(expected, out.toByteArray());
   
  @@ -198,64 +219,81 @@
       assert !(Boolean) wrapper.convert(Boolean.class);
       assert !(Boolean) wrapper.convert(Boolean.TYPE);
   
  -    try {
  +      try
  +      {
         // Attempt an invalid conversion
         wrapper.convert(Integer.class);
         assert false;
       }
  -    catch (ConversionException ex) {}
  +      catch (ConversionException ex)
  +      {
  +      }
   
       value = "A";
       wrapper.setElement(createElement("str", value));
   
  -    assert Character.valueOf(value.charAt(0)).equals(wrapper.convert(Character.class));
  -    assert Character.valueOf(value.charAt(0)).equals(wrapper.convert(Character.TYPE));
  +      assert Character.valueOf(value.charAt(0)).equals(
  +            wrapper.convert(Character.class));
  +      assert Character.valueOf(value.charAt(0)).equals(
  +            wrapper.convert(Character.TYPE));
   
       value = "green";
       wrapper.setElement(createElement("str", value));
   
       assert TestEnum.valueOf(value).equals(wrapper.convert(TestEnum.class));
   
  -    try {
  +      try
  +      {
         wrapper.setElement(createElement("str", "foo"));
         // Attempt an invalid conversion
         wrapper.convert(InvalidClass.class);
         assert false;
       }
  -    catch (ConversionException ex) {}
  +      catch (ConversionException ex)
  +      {
  +      }
   
       // Test conversionScore() method
       wrapper = new StringWrapper();
   
       assert ConversionScore.exact == wrapper.conversionScore(String.class);
  -    assert ConversionScore.exact == wrapper.conversionScore(StringBuffer.class);
  -    assert ConversionScore.exact == wrapper.conversionScore(StringBuffer.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Integer.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Integer.TYPE);
  +      assert ConversionScore.exact == wrapper
  +            .conversionScore(StringBuffer.class);
  +      assert ConversionScore.exact == wrapper
  +            .conversionScore(StringBuffer.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Integer.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Integer.TYPE);
       assert ConversionScore.compatible == wrapper.conversionScore(Long.class);
       assert ConversionScore.compatible == wrapper.conversionScore(Long.TYPE);
       assert ConversionScore.compatible == wrapper.conversionScore(Short.class);
       assert ConversionScore.compatible == wrapper.conversionScore(Short.TYPE);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Boolean.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Boolean.TYPE);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Boolean.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Boolean.TYPE);
       assert ConversionScore.compatible == wrapper.conversionScore(Float.class);
       assert ConversionScore.compatible == wrapper.conversionScore(Float.TYPE);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Character.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Character.TYPE);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Character.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Character.TYPE);
       assert ConversionScore.compatible == wrapper.conversionScore(Byte.class);
       assert ConversionScore.compatible == wrapper.conversionScore(Byte.TYPE);
   
       wrapper.setElement(createElement("str", "green"));
  -    assert ConversionScore.compatible == wrapper.conversionScore(TestEnum.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(TestEnum.class);
       wrapper.setElement(createElement("str", "foo"));
       assert ConversionScore.nomatch == wrapper.conversionScore(TestEnum.class);
   
  -    assert ConversionScore.nomatch == wrapper.conversionScore(InvalidClass.class);
  +      assert ConversionScore.nomatch == wrapper
  +            .conversionScore(InvalidClass.class);
     }
   
     @Test
  -  public void testNumberWrapper()
  -      throws Exception
  +   public void testNumberWrapper() throws Exception
     {
       String value = "123";
   
  @@ -301,15 +339,20 @@
         wrapper.convert(InvalidClass.class);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
       assert ConversionScore.exact == wrapper.conversionScore(Integer.class);
       assert ConversionScore.exact == wrapper.conversionScore(Integer.TYPE);
   
  -    assert ConversionScore.compatible == wrapper.conversionScore(String.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Object.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(String.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Object.class);
   
  -    assert ConversionScore.nomatch == wrapper.conversionScore(InvalidClass.class);
  +      assert ConversionScore.nomatch == wrapper
  +            .conversionScore(InvalidClass.class);
     }
   
     /**
  @@ -317,20 +360,30 @@
      *
      * @return List
      */
  -  public List<String> dummy() { return null; }
  +   public List<String> dummy()
  +   {
  +      return null;
  +   }
   
  -  public InvalidList<String> dummyInvalid() { return null; }
  +   public InvalidList<String> dummyInvalid()
  +   {
  +      return null;
  +   }
   
     /**
      * Used in testBagWrapper()
      */
  -  private class InvalidList<E> extends ArrayList<E> {
  -    public InvalidList() { throw new InstantiationError(); }
  +   @SuppressWarnings("serial")
  +   private class InvalidList<E> extends ArrayList<E>
  +   {
  +      public InvalidList()
  +      {
  +         throw new InstantiationError();
  +      }
     }
   
     @Test
  -  public void testBagWrapper()
  -      throws Exception
  +   public void testBagWrapper() throws Exception
     {
       BagWrapper wrapper = new BagWrapper();
       wrapper.setCallContext(new CallContext());
  @@ -384,20 +437,26 @@
       assertEquals(values[0], l.get(0));
       assertEquals(values[1], l.get(1));
   
  -    try {
  +      try
  +      {
         // This should throw a ConversionException
         wrapper.convert(InvalidList.class);
         assert false;
       }
  -    catch (ConversionException ex) {}
  +      catch (ConversionException ex)
  +      {
  +      }
   
       t = RemotingTest.class.getMethod("dummyInvalid").getGenericReturnType();
  -    try {
  +      try
  +      {
         // This should throw a ConversionException also
         wrapper.convert(t);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
       int[] intValues = new int[2];
       intValues[0] = 44444;
  @@ -416,8 +475,9 @@
   
       // Test marshal()
   
  -    byte[] expected = ("<bag><element><number>" + intValues[0] + "</number></element>" +
  -                       "<element><number>" + intValues[1] + "</number></element></bag>").getBytes();
  +      byte[] expected = ("<bag><element><number>" + intValues[0]
  +            + "</number></element>" + "<element><number>" + intValues[1] + "</number></element></bag>")
  +            .getBytes();
       ByteArrayOutputStream out = new ByteArrayOutputStream();
       wrapper.marshal(out);
       assertEquals(expected, out.toByteArray());
  @@ -430,25 +490,32 @@
       wrapper.marshal(out);
       assertEquals(expected, out.toByteArray());
   
  -    try {
  +      try
  +      {
         // This should throw a RuntimeException
         wrapper.setValue(new InvalidClass());
         wrapper.marshal(out);
         assert false;
       }
  -    catch (RuntimeException ex) { }
  +      catch (RuntimeException ex)
  +      {
  +      }
   
       // test conversionScore() method
  -    assert ConversionScore.compatible == wrapper.conversionScore(String[].class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Object.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Collection.class);
  -    assert ConversionScore.nomatch == wrapper.conversionScore(InvalidClass.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(String[].class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Object.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Collection.class);
  +      assert ConversionScore.nomatch == wrapper
  +            .conversionScore(InvalidClass.class);
     }
   
     @Test
     public void testBeanWrapper()
     {
  -    BeanWrapper wrapper = new BeanWrapper();
  +      // BeanWrapper wrapper = new BeanWrapper();
   
       /** @todo Write tests for BeanWrapper */
     }
  @@ -456,18 +523,25 @@
     /**
      * Used in testMapWrapper()
      */
  -  public Map<String,String> dummyMap() { return null; }
  +   public Map<String, String> dummyMap()
  +   {
  +      return null;
  +   }
   
     /**
      * Used in testMapWrapper()
      */
  -  private class InvalidMap extends HashMap {
  -    public InvalidMap() { throw new InstantiationError(); }
  +   @SuppressWarnings("serial")
  +   private class InvalidMap extends HashMap
  +   {
  +      public InvalidMap()
  +      {
  +         throw new InstantiationError();
  +      }
     }
   
     @Test
  -  public void testMapWrapper()
  -      throws Exception
  +   public void testMapWrapper() throws Exception
     {
       MapWrapper wrapper = new MapWrapper();
       wrapper.setCallContext(new CallContext());
  @@ -503,22 +577,29 @@
       assert "aaaaa".equals(m.get("foo"));
       assert "zzzzz".equals(m.get("bar"));
   
  -    try {
  +      try
  +      {
         // This should throw a ConversionException
         wrapper.convert(InvalidClass.class);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
  -    try {
  +      try
  +      {
         // This should throw a ConversionException also
         wrapper.convert(InvalidMap.class);
         assert false;
       }
  -    catch (ConversionException ex) { }
  +      catch (ConversionException ex)
  +      {
  +      }
   
  -    byte[] expected = ("<map><element><k><str>foo</str></k><v><str>aaaaa</str></v></element>" +
  -                      "<element><k><str>bar</str></k><v><str>zzzzz</str></v></element></map>").getBytes();
  +      byte[] expected = ("<map><element><k><str>foo</str></k><v><str>aaaaa</str></v></element>"
  +            + "<element><k><str>bar</str></k><v><str>zzzzz</str></v></element></map>")
  +            .getBytes();
       ByteArrayOutputStream out = new ByteArrayOutputStream();
       wrapper.marshal(out);
       assertEquals(expected, out.toByteArray());
  @@ -526,13 +607,14 @@
       // test conversionScore() method
       assert ConversionScore.exact == wrapper.conversionScore(Map.class);
       assert ConversionScore.exact == wrapper.conversionScore(HashMap.class);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Object.class);
  -    assert ConversionScore.nomatch == wrapper.conversionScore(InvalidClass.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Object.class);
  +      assert ConversionScore.nomatch == wrapper
  +            .conversionScore(InvalidClass.class);
     }
   
     @Test
  -  public void testNullWrapper()
  -      throws Exception
  +   public void testNullWrapper() throws Exception
     {
       NullWrapper wrapper = new NullWrapper();
       assert wrapper.convert(null) == null;
  @@ -543,15 +625,28 @@
       assertEquals(expected, out.toByteArray());
   
       assert ConversionScore.compatible == wrapper.conversionScore(null);
  -    assert ConversionScore.compatible == wrapper.conversionScore(Object.class);
  +      assert ConversionScore.compatible == wrapper
  +            .conversionScore(Object.class);
     }
   
     @Test
  -  public void testBaseWrapper() {
  -    BaseWrapper wrapper = new BaseWrapper() {
  -      public ConversionScore conversionScore(Class cls) { return ConversionScore.nomatch; }
  -      public void marshal(OutputStream out) {}
  -      public Object convert(Type type) { return null; }
  +   public void testBaseWrapper()
  +   {
  +      BaseWrapper wrapper = new BaseWrapper()
  +      {
  +         public ConversionScore conversionScore(Class cls)
  +         {
  +            return ConversionScore.nomatch;
  +         }
  +
  +         public void marshal(OutputStream out)
  +         {
  +         }
  +
  +         public Object convert(Type type)
  +         {
  +            return null;
  +         }
       };
   
       Object value = new Object();
  @@ -566,24 +661,30 @@
       {
         wrapper.serialize(null);
       }
  -    catch (IOException ex) { }
  +      catch (IOException ex)
  +      {
  +      }
     }
   
     @Test
  -  public void testWrapperFactory() {
  +   public void testWrapperFactory()
  +   {
       try
       {
         // This should throw a RuntimeException
         WrapperFactory.getInstance().createWrapper("invalid");
         assert false;
       }
  -    catch (RuntimeException ex){ }
  +      catch (RuntimeException ex)
  +      {
  +      }
   
       assert WrapperFactory.getInstance().getWrapperForObject(null) instanceof NullWrapper;
       assert WrapperFactory.getInstance().getWrapperForObject(new HashMap()) instanceof MapWrapper;
       assert WrapperFactory.getInstance().getWrapperForObject(new String[2]) instanceof BagWrapper;
       assert WrapperFactory.getInstance().getWrapperForObject(new ArrayList()) instanceof BagWrapper;
  -    assert WrapperFactory.getInstance().getWrapperForObject(new Boolean(true)) instanceof BooleanWrapper;
  +      assert WrapperFactory.getInstance()
  +            .getWrapperForObject(new Boolean(true)) instanceof BooleanWrapper;
       assert WrapperFactory.getInstance().getWrapperForObject(true) instanceof BooleanWrapper;
       assert WrapperFactory.getInstance().getWrapperForObject(TestEnum.blue) instanceof StringWrapper;
       assert WrapperFactory.getInstance().getWrapperForObject(new Date()) instanceof DateWrapper;
  @@ -591,9 +692,12 @@
   
       // All the String types
       assert WrapperFactory.getInstance().getWrapperForObject("foo") instanceof StringWrapper;
  -    assert WrapperFactory.getInstance().getWrapperForObject(new StringBuffer("foo")) instanceof StringWrapper;
  -    assert WrapperFactory.getInstance().getWrapperForObject(new StringBuilder("foo")) instanceof StringWrapper;
  -    assert WrapperFactory.getInstance().getWrapperForObject(new Character('a')) instanceof StringWrapper;
  +      assert WrapperFactory.getInstance().getWrapperForObject(
  +            new StringBuffer("foo")) instanceof StringWrapper;
  +      assert WrapperFactory.getInstance().getWrapperForObject(
  +            new StringBuilder("foo")) instanceof StringWrapper;
  +      assert WrapperFactory.getInstance().getWrapperForObject(
  +            new Character('a')) instanceof StringWrapper;
   
       // All the number types
       assert WrapperFactory.getInstance().getWrapperForObject(111) instanceof NumberWrapper;
  @@ -606,7 +710,8 @@
     }
   
     @Test
  -  public void testConversionScore() {
  +   public void testConversionScore()
  +   {
       // For code-coverage completeness
       assert 0 == ConversionScore.nomatch.getScore();
       assert 1 == ConversionScore.compatible.getScore();
  @@ -615,8 +720,7 @@
     }
   
     @Test
  -  public void testConstraints()
  -      throws Exception
  +   public void testConstraints() throws Exception
     {
       // Initialize Seam
       MockServletContext servletContext = new MockServletContext();
  @@ -635,13 +739,16 @@
         ByteArrayOutputStream out = new ByteArrayOutputStream();
   
         // Constrain a single field of the result
  -      List<String> constraints = Arrays.asList(new String[] {"secret"});
  -      MarshalUtils.marshalResult(null, new CallContext(), out, result, constraints);
  +         List<String> constraints = Arrays.asList(new String[] { "secret" });
  +         MarshalUtils.marshalResult(null, new CallContext(), out, result,
  +               constraints);
   
         SAXReader xmlReader = new SAXReader();
  -      Document doc = xmlReader.read(new StringReader(new String(out.toByteArray())));
  +         Document doc = xmlReader.read(new StringReader(new String(out
  +               .toByteArray())));
   
  -      Widget widget = (Widget) ParserUtils.unmarshalResult(doc.getRootElement());
  +         Widget widget = (Widget) ParserUtils.unmarshalResult(doc
  +               .getRootElement());
   
         // value field should equal "foo"
         assert "foo".equals(widget.getValue());
  @@ -658,8 +765,9 @@
         out.reset();
   
         // Now we're going to constrain result.child's secret field
  -      constraints = Arrays.asList(new String[] {"child.secret"});
  -      MarshalUtils.marshalResult(null, new CallContext(), out, result, constraints);
  +         constraints = Arrays.asList(new String[] { "child.secret" });
  +         MarshalUtils.marshalResult(null, new CallContext(), out, result,
  +               constraints);
   
         doc = xmlReader.read(new StringReader(new String(out.toByteArray())));
         widget = (Widget) ParserUtils.unmarshalResult(doc.getRootElement());
  @@ -669,7 +777,7 @@
         assert widget.getChild().getSecret() == null;
   
         // Add a map to our result
  -      result.setWidgetMap(new HashMap<String,Widget>());
  +         result.setWidgetMap(new HashMap<String, Widget>());
         Widget val = new Widget();
         val.setValue("foo");
         val.setSecret("bar");
  @@ -678,9 +786,12 @@
         // Reset our output stream again
         out.reset();
   
  -      // Constrain the "secret" field of the widgetMap map's values (sounds confusing, I know...)
  -      constraints = Arrays.asList(new String[] {"widgetMap[value].secret"});
  -      MarshalUtils.marshalResult(null, new CallContext(), out, result, constraints);
  +         // Constrain the "secret" field of the widgetMap map's values (sounds
  +         // confusing, I know...)
  +         constraints = Arrays
  +               .asList(new String[] { "widgetMap[value].secret" });
  +         MarshalUtils.marshalResult(null, new CallContext(), out, result,
  +               constraints);
   
         doc = xmlReader.read(new StringReader(new String(out.toByteArray())));
         widget = (Widget) ParserUtils.unmarshalResult(doc.getRootElement());
  @@ -700,8 +811,9 @@
         result.getWidgetList().add(item);
   
         // Constraint the "secret" field of widgetList
  -      constraints = Arrays.asList(new String[] {"widgetList.secret"});
  -      MarshalUtils.marshalResult(null, new CallContext(), out, result, constraints);
  +         constraints = Arrays.asList(new String[] { "widgetList.secret" });
  +         MarshalUtils.marshalResult(null, new CallContext(), out, result,
  +               constraints);
   
         doc = xmlReader.read(new StringReader(new String(out.toByteArray())));
         widget = (Widget) ParserUtils.unmarshalResult(doc.getRootElement());
  @@ -714,8 +826,10 @@
         out.reset();
   
         // Now constrain all secrets
  -      constraints = Arrays.asList(new String[] {"[org.jboss.seam.test.Widget].secret"});
  -      MarshalUtils.marshalResult(null, new CallContext(), out, result, constraints);
  +         constraints = Arrays
  +               .asList(new String[] { "[org.jboss.seam.test.Widget].secret" });
  +         MarshalUtils.marshalResult(null, new CallContext(), out, result,
  +               constraints);
   
         doc = xmlReader.read(new StringReader(new String(out.toByteArray())));
         widget = (Widget) ParserUtils.unmarshalResult(doc.getRootElement());
  @@ -748,32 +862,132 @@
       }
     }
   
  -  static class Dummy {
  -    enum TestEnum {foo, bar}
  -    public String getString() { return null; }
  -    public TestEnum getEnum() { return null; }
  -    public BigInteger getBigInteger() { return null; }
  -    public BigDecimal getBigDecimal() { return null; }
  -    public Boolean getBoolean() { return null; }
  -    public boolean getBool() { return false; }
  -    public Short getShort() { return null; }
  -    public short getSht() { return 0; }
  -    public Integer getInteger() { return null; }
  -    public int getInt() { return 0; }
  -    public Long getLong() { return null; }
  -    public long getLng() { return 0; }
  -    public Float getFloat() { return null; }
  -    public float getFlt() { return 0; }
  -    public Double getDouble() { return null; }
  -    public double getDbl() { return 0; }
  -    public Byte getByte() { return null; }
  -    public byte getByt() { return 0; }
  -    public Date getDate() { return null; }
  -    public int[] getIntArray() { return null; }
  -    public Map getMap() { return null; }
  -    public Collection getCollection() { return null; }
  -    public Map<String,String> getGenericMap() { return null; }
  -    public Collection<String> getGenericCollection() { return null; }
  +   static class Dummy
  +   {
  +      enum TestEnum
  +      {
  +         foo, bar
  +      }
  +
  +      public String getString()
  +      {
  +         return null;
  +      }
  +
  +      public TestEnum getEnum()
  +      {
  +         return null;
  +      }
  +
  +      public BigInteger getBigInteger()
  +      {
  +         return null;
  +      }
  +
  +      public BigDecimal getBigDecimal()
  +      {
  +         return null;
  +      }
  +
  +      public Boolean getBoolean()
  +      {
  +         return null;
  +      }
  +
  +      public boolean getBool()
  +      {
  +         return false;
  +      }
  +
  +      public Short getShort()
  +      {
  +         return null;
  +      }
  +
  +      public short getSht()
  +      {
  +         return 0;
  +      }
  +
  +      public Integer getInteger()
  +      {
  +         return null;
  +      }
  +
  +      public int getInt()
  +      {
  +         return 0;
  +      }
  +
  +      public Long getLong()
  +      {
  +         return null;
  +      }
  +
  +      public long getLng()
  +      {
  +         return 0;
  +      }
  +
  +      public Float getFloat()
  +      {
  +         return null;
  +      }
  +
  +      public float getFlt()
  +      {
  +         return 0;
  +      }
  +
  +      public Double getDouble()
  +      {
  +         return null;
  +      }
  +
  +      public double getDbl()
  +      {
  +         return 0;
  +      }
  +
  +      public Byte getByte()
  +      {
  +         return null;
  +      }
  +
  +      public byte getByt()
  +      {
  +         return 0;
  +      }
  +
  +      public Date getDate()
  +      {
  +         return null;
  +      }
  +
  +      public int[] getIntArray()
  +      {
  +         return null;
  +      }
  +
  +      public Map getMap()
  +      {
  +         return null;
  +      }
  +
  +      public Collection getCollection()
  +      {
  +         return null;
  +      }
  +
  +      public Map<String, String> getGenericMap()
  +      {
  +         return null;
  +      }
  +
  +      public Collection<String> getGenericCollection()
  +      {
  +         return null;
  +      }
     }
   
     private Type getDummyReturnType(String methodName)
  @@ -795,29 +1009,36 @@
     public void testInterfaceGenerator()
     {
       ProxyInterfaceGenerator gen = new ProxyInterfaceGenerator();
  -    assert("str".equals(gen.getFieldType(getDummyReturnType("getString"))));
  -    assert("str".equals(gen.getFieldType(getDummyReturnType("getEnum"))));
  -    assert("str".equals(gen.getFieldType(getDummyReturnType("getBigInteger"))));
  -    assert("str".equals(gen.getFieldType(getDummyReturnType("getBigDecimal"))));
  -    assert("bool".equals(gen.getFieldType(getDummyReturnType("getBoolean"))));
  -    assert("bool".equals(gen.getFieldType(getDummyReturnType("getBool"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getShort"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getSht"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getInteger"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getInt"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getLong"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getLng"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getFloat"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getFlt"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getDouble"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getDbl"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getByte"))));
  -    assert("number".equals(gen.getFieldType(getDummyReturnType("getByt"))));
  -    assert("date".equals(gen.getFieldType(getDummyReturnType("getDate"))));
  -    assert("bag".equals(gen.getFieldType(getDummyReturnType("getIntArray"))));
  -    assert("map".equals(gen.getFieldType(getDummyReturnType("getMap"))));
  -    assert("bag".equals(gen.getFieldType(getDummyReturnType("getCollection"))));
  -    assert("map".equals(gen.getFieldType(getDummyReturnType("getGenericMap"))));
  -    assert("bag".equals(gen.getFieldType(getDummyReturnType("getGenericCollection"))));
  +      assert ("str".equals(gen.getFieldType(getDummyReturnType("getString"))));
  +      assert ("str".equals(gen.getFieldType(getDummyReturnType("getEnum"))));
  +      assert ("str".equals(gen
  +            .getFieldType(getDummyReturnType("getBigInteger"))));
  +      assert ("str".equals(gen
  +            .getFieldType(getDummyReturnType("getBigDecimal"))));
  +      assert ("bool".equals(gen.getFieldType(getDummyReturnType("getBoolean"))));
  +      assert ("bool".equals(gen.getFieldType(getDummyReturnType("getBool"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getShort"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getSht"))));
  +      assert ("number".equals(gen
  +            .getFieldType(getDummyReturnType("getInteger"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getInt"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getLong"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getLng"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getFloat"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getFlt"))));
  +      assert ("number"
  +            .equals(gen.getFieldType(getDummyReturnType("getDouble"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getDbl"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getByte"))));
  +      assert ("number".equals(gen.getFieldType(getDummyReturnType("getByt"))));
  +      assert ("date".equals(gen.getFieldType(getDummyReturnType("getDate"))));
  +      assert ("bag".equals(gen.getFieldType(getDummyReturnType("getIntArray"))));
  +      assert ("map".equals(gen.getFieldType(getDummyReturnType("getMap"))));
  +      assert ("bag".equals(gen
  +            .getFieldType(getDummyReturnType("getCollection"))));
  +      assert ("map".equals(gen
  +            .getFieldType(getDummyReturnType("getGenericMap"))));
  +      assert ("bag".equals(gen
  +            .getFieldType(getDummyReturnType("getGenericCollection"))));
     }
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 20 21:54:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 20 Dec 2006 21:54:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r59184 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test
Message-ID: <E1GxE5B-00035v-3P@committer01.frg.pub.inap.atl.jboss.com>

Author: bstansberry at jboss.com
Date: 2006-12-20 21:54:55 -0500 (Wed, 20 Dec 2006)
New Revision: 59184

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/SessionBasedConcurrentTestCase.java
Log:
Add a sleep for async repl

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/SessionBasedConcurrentTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/SessionBasedConcurrentTestCase.java	2006-12-21 02:01:49 UTC (rev 59183)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/SessionBasedConcurrentTestCase.java	2006-12-21 02:54:55 UTC (rev 59184)
@@ -150,6 +150,9 @@
             // Get the Attribute set by testsessionreplication.jsp
             attr = makeGetWithState(client, baseURL0 +getURLName);
 
+            // Give a lot of time for async replication to avoid spurious failures
+            sleepThread(1000);
+
             // Let's switch to server 2 to retrieve the session attribute.
             getLog().debug("Switching to server " +server2);
             setCookieDomainToThisServer(client, server2);



From brian.stansberry at jboss.com  Wed Dec 20 21:57:52 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Wed, 20 Dec 2006 21:57:52 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors  ...
Message-ID: <E1GxE80-0003B1-9H@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/20 21:57:52

  Modified:    src/org/jboss/cache/interceptors  TxInterceptor.java
  Log:
  Avoid NPE in clearStaleLocks
  
  Revision  Changes    Path
  1.68      +2 -1      JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java,v
  retrieving revision 1.67
  retrieving revision 1.68
  diff -u -b -r1.67 -r1.68
  --- TxInterceptor.java	8 Dec 2006 18:49:17 -0000	1.67
  +++ TxInterceptor.java	21 Dec 2006 02:57:52 -0000	1.68
  @@ -719,6 +719,7 @@
      private void cleanupStaleLocks(GlobalTransaction gtx) throws Throwable
      {
         TransactionEntry entry = txTable.get(gtx);
  +      if (entry != null)
         entry.releaseAllLocksLIFO(gtx);
      }
   
  
  
  


From c56 at fullmailmarket.com  Wed Dec 20 22:31:23 2006
From: c56 at fullmailmarket.com (FonoIP.com)
Date: Thu, 21 Dec 2006 00:31:23 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?Hable_por_Tel=E9fono_y_ahorre_plata!!?=
Message-ID: <200612210331.kBL3VQHB024701@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061221/0fe4cfb5/attachment.html 

From brian.stansberry at jboss.com  Wed Dec 20 23:40:07 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Wed, 20 Dec 2006 23:40:07 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1GxFix-0004w2-9J@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/20 23:40:07

  Added:       tests/functional/org/jboss/cache/eviction  Tag:
                        Branch_JBossCache_1_4_0
                        StateTransferIntegrationTest.java
  Log:
  [JBCACHE-913] Notify eviction policies of nodes added via state transfer
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +62 -0     JBossCache/tests/functional/org/jboss/cache/eviction/Attic/StateTransferIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrationTest.java
  ===================================================================
  RCS file: StateTransferIntegrationTest.java
  diff -N StateTransferIntegrationTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ StateTransferIntegrationTest.java	21 Dec 2006 04:40:07 -0000	1.1.2.1
  @@ -0,0 +1,62 @@
  +/*
  + * JBoss, Home of Professional Open Source.
  + * Copyright 2006, 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.cache.eviction;
  +
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.PropertyConfigurator;
  +import org.jboss.cache.TreeCache;
  +
  +import junit.framework.TestCase;
  +
  +/**
  + * Tests that eviction policies are aware of events related to state transfer.
  + * 
  + * @author Brian Stansberry
  + */
  +public class StateTransferIntegrationTest extends TestCase
  +{
  +
  +   /**
  +    * Test for JBCACHE-913
  +    * 
  +    * @throws Exception
  +    */
  +   public void testEvictionSeesStateTransfer() throws Exception
  +   {
  +      TreeCache cache1 = new TreeCache();
  +      PropertyConfigurator config = new PropertyConfigurator();
  +      config.configure(cache1, "META-INF/replSync-eviction-service.xml");      
  +      cache1.startService();
  +      
  +      cache1.put("/a/b/c", "key", "value");
  +      
  +      TreeCache cache2 = new TreeCache();
  +      config.configure(cache2, "META-INF/replSync-eviction-service.xml");
  +      cache2.startService();
  +      
  +      RegionManager erm = cache2.getEvictionRegionManager();
  +      Region region = erm.getRegion(Fqn.ROOT);
  +      // We expect events for ROOT , /a, /a/b and /a/b/c
  +      assertEquals("Saw the expected number of node events", 4, region.nodeEventQueueSize());
  +   }
  +}
  
  
  


From brian.stansberry at jboss.com  Wed Dec 20 23:40:07 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Wed, 20 Dec 2006 23:40:07 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxFix-0004wJ-M2@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/20 23:40:07

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  [JBCACHE-913] Notify eviction policies of nodes added via state transfer
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.38 +15 -2     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.37
  retrieving revision 1.195.2.38
  diff -u -b -r1.195.2.37 -r1.195.2.38
  --- TreeCache.java	20 Dec 2006 04:55:39 -0000	1.195.2.37
  +++ TreeCache.java	21 Dec 2006 04:40:07 -0000	1.195.2.38
  @@ -15,6 +15,7 @@
   import org.jboss.cache.buddyreplication.BuddyNotInitException;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Option;
  +import org.jboss.cache.eviction.EvictedEventNode;
   import org.jboss.cache.eviction.EvictionPolicy;
   import org.jboss.cache.factories.InterceptorChainFactory;
   import org.jboss.cache.factories.NodeFactory;
  @@ -99,7 +100,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.37 2006/12/20 04:55:39 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.38 2006/12/21 04:40:07 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -6078,7 +6079,19 @@
         Map children;
   
         if (curr == null) return;
  -      notifyNodeCreated(curr.getFqn());
  +      Fqn fqn = curr.getFqn();
  +      notifyNodeCreated(fqn);
  +      
  +      // JBCACHE-913
  +      if (evictionRegionManager_ != null)
  +      {
  +         org.jboss.cache.eviction.Region region = evictionRegionManager_.getRegion(fqn);
  +         if (region != null)
  +         {
  +            region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT));
  +         }
  +      }
  +      
         if ((children = curr.getChildren()) != null)
         {
            for (Iterator it = children.values().iterator(); it.hasNext();)
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 00:04:51 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 00:04:51 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1GxG6t-0005QR-Ap@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 00:04:51

  Added:       tests/functional/org/jboss/cache/eviction 
                        StateTransferIntegrationTest.java
  Log:
  [JBCACHE-913] Add test of notifying eviction policies of nodes added via state transfer
  
  Revision  Changes    Path
  1.2       +64 -0     JBossCache/tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrationTest.java
  ===================================================================
  RCS file: StateTransferIntegrationTest.java
  diff -N StateTransferIntegrationTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ StateTransferIntegrationTest.java	21 Dec 2006 05:04:51 -0000	1.2
  @@ -0,0 +1,64 @@
  +/*
  + * JBoss, Home of Professional Open Source.
  + * Copyright 2006, 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.cache.eviction;
  +
  +import org.jboss.cache.Cache;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.Region;
  +import org.jboss.cache.config.Configuration;
  +import org.jboss.cache.factories.DefaultCacheFactory;
  +import org.jboss.cache.factories.XmlConfigurationParser;
  +
  +import junit.framework.TestCase;
  +
  +/**
  + * Tests that eviction policies are aware of events related to state transfer.
  + * 
  + * @author Brian Stansberry
  + */
  +public class StateTransferIntegrationTest extends TestCase
  +{
  +
  +   /**
  +    * Test for JBCACHE-913
  +    * 
  +    * @throws Exception
  +    */
  +   public void testEvictionSeesStateTransfer() throws Exception
  +   {
  +      XmlConfigurationParser parser = new XmlConfigurationParser();
  +      Configuration c = parser.parseFile("META-INF/replSync-eviction-service.xml");
  +      Cache cache1 = DefaultCacheFactory.createCache(c, false);  
  +      cache1.start();
  +      
  +      cache1.put(Fqn.fromString("/a/b/c"), "key", "value");
  +      
  +      c = parser.parseFile("META-INF/replSync-eviction-service.xml");
  +      Cache cache2 = DefaultCacheFactory.createCache(c, false);
  +      cache2.start();
  +      
  +      Region region = cache2.getRegion(Fqn.ROOT, false);
  +      // We expect events for ROOT , /a, /a/b and /a/b/c
  +      assertEquals("Saw the expected number of node events", 4, region.nodeEventQueueSize());
  +   }
  +}
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 00:32:54 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 00:32:54 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security   ...
Message-ID: <E1GxGY2-0005r8-O5@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 00:32:54

  Modified:    src/main/org/jboss/seam/security   Identity.java
                        SeamSecurityManager.java
  Log:
  assert Identity into working memory only if it exists
  
  Revision  Changes    Path
  1.5       +66 -55    jboss-seam/src/main/org/jboss/seam/security/Identity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Identity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/Identity.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- Identity.java	13 Dec 2006 05:19:40 -0000	1.4
  +++ Identity.java	21 Dec 2006 05:32:54 -0000	1.5
  @@ -8,6 +8,7 @@
   
   import org.jboss.seam.Component;
   import org.jboss.seam.ScopeType;
  +import org.jboss.seam.Seam;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  @@ -15,10 +16,11 @@
   
   @Name("org.jboss.seam.security.identity")
   @Scope(SESSION)
  - at Install(precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
  + at Install(precedence = BUILT_IN, dependencies = "org.jboss.seam.securityManager")
   public abstract class Identity implements Principal, Serializable
   {
     protected boolean authenticated;
  +
     protected boolean valid;
   
     public static Identity instance()
  @@ -26,10 +28,10 @@
       if (!Contexts.isSessionContextActive())
          throw new IllegalStateException("No active session context");
   
  -    Identity instance = (Identity) Component.getInstance(
  -        Identity.class, ScopeType.SESSION, true);
  +      Identity instance = (Identity) Component.getInstance(Identity.class,
  +            ScopeType.SESSION, true);
   
  -    if (instance==null)
  +      if (instance == null)
       {
         throw new AuthenticationException(
             "No Identity exists in session scope");
  @@ -38,8 +40,17 @@
       return instance;
     }
   
  +   public static boolean isSet()
  +   {
  +      return Contexts.isSessionContextActive()
  +            && Contexts.getSessionContext().isSet(
  +                  Seam.getComponentName(Identity.class));
  +   }
  +
     public abstract Role[] getRoles();
  +
     public abstract Object getCredentials();
  +
     public abstract Object getPrincipal();
   
     public final boolean isAuthenticated()
  
  
  
  1.30      +25 -16    jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- SeamSecurityManager.java	21 Dec 2006 02:38:28 -0000	1.29
  +++ SeamSecurityManager.java	21 Dec 2006 05:32:54 -0000	1.30
  @@ -159,7 +159,10 @@
         handles.add(wm.assertObject(check));
   
         for (Object o : args)
  +      {
  +         if (o != null)
            handles.add(wm.assertObject(o));
  +      }
   
         wm.fireAllRules();
   
  @@ -179,26 +182,32 @@
         if (!Contexts.isSessionContextActive())
            throw new IllegalStateException("No active session context found.");
   
  -      Context session = Contexts.getSessionContext();
  +      Identity ident = Identity.isSet() ? Identity.instance() : null;
  +      WorkingMemory wm;
   
  -      if (!session.isSet(SECURITY_CONTEXT_NAME))
  +      if (Contexts.getSessionContext().isSet(SECURITY_CONTEXT_NAME))
  +         wm = (WorkingMemory) Contexts.getSessionContext().get(SECURITY_CONTEXT_NAME);
  +      else         
         {
  -         if (!Identity.instance().isValid())
  -            throw new IllegalStateException(
  -                  "Authenticated Identity is not valid");
  +         if (ident != null && !ident.isValid())
  +            throw new IllegalStateException("Authenticated Identity is not valid");
  +
  +         wm = securityRules.newWorkingMemory();
  +         Contexts.getSessionContext().set(SECURITY_CONTEXT_NAME, wm);
  +      }
   
  -         WorkingMemory wm = securityRules.newWorkingMemory();
  -         wm.assertObject(Identity.instance());
  +      // Assert the identity into the working memory if one exists and it hasn't
  +      // been asserted before
  +      if (ident != null && wm.getObjects(ident.getClass()).size() > 0)
  +      {
  +         wm.assertObject(ident);
   
  -         for (Role r : Identity.instance().getRoles())
  +         for (Role r : ident.getRoles())
               wm.assertObject(r);
   
            /** @todo Assert the Identity's explicit permissions also? */
  -
  -         session.set(SECURITY_CONTEXT_NAME, wm);
  -         return wm;
         }
   
  -      return (WorkingMemory) session.get(SECURITY_CONTEXT_NAME);
  +      return wm;
      }
   }
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 00:34:03 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 00:34:03 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxGZ9-0005rQ-GQ@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 00:34:03

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  Fix bizarre args to createDataNode
  
  Revision  Changes    Path
  1.299     +2 -2      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.298
  retrieving revision 1.299
  diff -u -b -r1.298 -r1.299
  --- TreeCache.java	20 Dec 2006 22:28:13 -0000	1.298
  +++ TreeCache.java	21 Dec 2006 05:34:03 -0000	1.299
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.298 2006/12/20 22:28:13 vblagojevic Exp $
  + * @version $Id: TreeCache.java,v 1.299 2006/12/21 05:34:03 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1053,7 +1053,7 @@
               {
                  child = factory.createDataNode(type, name,
                          subtree.getFqnChild(i + 1),
  -                       parent, lock_table, coordinator, null, this.rootSpi);
  +                       parent, null, true, null, this.rootSpi);
                  parent.addChild(name, child);
               }
               finally
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 00:34:47 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 00:34:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF  ...
Message-ID: <E1GxGZr-0005re-8I@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 00:34:47

  Modified:    examples/seamspace/resources/WEB-INF  web.xml
  Log:
  added content servlet for serving images
  
  Revision  Changes    Path
  1.5       +22 -0     jboss-seam/examples/seamspace/resources/WEB-INF/web.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: web.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/web.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- web.xml	20 Dec 2006 03:36:55 -0000	1.4
  +++ web.xml	21 Dec 2006 05:34:47 -0000	1.5
  @@ -82,6 +82,28 @@
           <url-pattern>*.seam</url-pattern>
       </servlet-mapping>
       
  +    <!-- Content Servlet -->
  +    
  +    <servlet>
  +        <servlet-name>Content Servlet</servlet-name>
  +        <servlet-class>org.jboss.seam.example.seamspace.ContentServlet</servlet-class>
  +    </servlet>
  +    
  +    <servlet-mapping>
  +        <servlet-name>Content Servlet</servlet-name>
  +        <url-pattern>/content/*</url-pattern>
  +    </servlet-mapping>
  +    
  +    <filter>
  +        <filter-name>Seam Servlet Filter</filter-name>
  +        <filter-class>org.jboss.seam.servlet.SeamServletFilter</filter-class>
  +    </filter>
  +    
  +    <filter-mapping>
  +        <filter-name>Seam Servlet Filter</filter-name>
  +        <url-pattern>/content/*</url-pattern>
  +    </filter-mapping>      
  +    
       <!-- Seam Remoting -->
       
       <servlet>
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 00:34:47 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 00:34:47 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxGZr-0005sC-Dy@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 00:34:47

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace          
                        AclObjectIdentity.java AclPermission.java
                        LoginAction.java Member.java MemberImage.java
                        MemberRole.java ProfileAction.java
  Added:       examples/seamspace/src/org/jboss/seam/example/seamspace          
                        ContentServlet.java ImageAction.java
                        ImageLocal.java
  Log:
  added content servlet for serving images
  
  Revision  Changes    Path
  1.2       +26 -23    jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AclObjectIdentity.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AclObjectIdentity.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AclObjectIdentity.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- AclObjectIdentity.java	25 Oct 2006 09:46:18 -0000	1.1
  +++ AclObjectIdentity.java	21 Dec 2006 05:34:47 -0000	1.2
  @@ -12,7 +12,10 @@
   @Entity
   public class AclObjectIdentity implements Serializable
   {
  +   private static final long serialVersionUID = 1L;
  +
     private Integer id;
  +
     private String objectIdentity;
   
     @Id
  
  
  
  1.3       +64 -58    jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AclPermission.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AclPermission.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AclPermission.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- AclPermission.java	9 Nov 2006 00:48:41 -0000	1.2
  +++ AclPermission.java	21 Dec 2006 05:34:47 -0000	1.3
  @@ -14,10 +14,16 @@
   @Entity
   public class AclPermission implements Serializable
   {
  +   private static final long serialVersionUID = 1L;
  +
     private Integer id;
  +
     private AclObjectIdentity identity;
  +
     private RecipientType recipientType;
  +
     private String recipient;
  +
     private int mask;
   
     @Id
  
  
  
  1.4       +0 -2      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- LoginAction.java	20 Dec 2006 11:40:25 -0000	1.3
  +++ LoginAction.java	21 Dec 2006 05:34:47 -0000	1.4
  @@ -2,8 +2,6 @@
   
   import javax.ejb.Remove;
   import javax.ejb.Stateful;
  -import javax.persistence.EntityManager;
  -import javax.persistence.PersistenceContext;
   
   import org.jboss.seam.ScopeType;
   import org.jboss.seam.Seam;
  
  
  
  1.8       +2 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Member.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- Member.java	20 Dec 2006 11:40:25 -0000	1.7
  +++ Member.java	21 Dec 2006 05:34:47 -0000	1.8
  @@ -28,6 +28,8 @@
   @Table(uniqueConstraints = @UniqueConstraint(columnNames = "name"))
   public class Member implements Serializable
   {
  +   private static final long serialVersionUID = 5179242727836683375L;
  +   
      private Integer memberId;
      private String username;
      private String password;
  
  
  
  1.2       +2 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MemberImage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- MemberImage.java	20 Dec 2006 11:40:25 -0000	1.1
  +++ MemberImage.java	21 Dec 2006 05:34:47 -0000	1.2
  @@ -12,6 +12,8 @@
   @Name("memberImage")
   public class MemberImage implements Serializable
   {
  +   private static final long serialVersionUID = -8088455267213832920L;
  +   
      private Integer imageId;
      private Member member;
      private byte[] data;
  
  
  
  1.3       +26 -23    jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MemberRole.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MemberRole.java	20 Dec 2006 03:36:56 -0000	1.2
  +++ MemberRole.java	21 Dec 2006 05:34:47 -0000	1.3
  @@ -15,7 +15,10 @@
   @Name("memberRole")
   public class MemberRole implements Serializable
   {
  +   private static final long serialVersionUID = 9177366120789064801L;
  +
     private Integer roleId;
  +
     private String name;
   
     @Id
  
  
  
  1.2       +1 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProfileAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ProfileAction.java	20 Dec 2006 11:40:25 -0000	1.1
  +++ ProfileAction.java	21 Dec 2006 05:34:47 -0000	1.2
  @@ -49,4 +49,5 @@
               FacesMessages.instance().add("The member name you specified does not exist.");
            }   
         }
  +   }
   }
  
  
  
  1.1      date: 2006/12/21 05:34:47;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java
  
  Index: ContentServlet.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import java.io.IOException;
  
  import javax.servlet.ServletException;
  import javax.servlet.http.HttpServlet;
  import javax.servlet.http.HttpServletRequest;
  import javax.servlet.http.HttpServletResponse;
  
  import org.jboss.seam.Component;
  
  public class ContentServlet extends HttpServlet
  {
     private static final long serialVersionUID = -8461940507242022217L;
  
     @Override
     protected void doGet(HttpServletRequest request, HttpServletResponse response)
         throws ServletException, IOException
     {
        ImageLocal local = (ImageLocal) Component.getInstance(ImageAction.class);
        
        MemberImage img = local.getImage(Integer.parseInt(request.getParameter("id")));
        
        if (img != null)
        {
          response.setContentType(img.getContentType());
          response.getOutputStream().write(img.getData());
          response.getOutputStream().flush();
        }
     }
  }
  
  
  
  1.1      date: 2006/12/21 05:34:47;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ImageAction.java
  
  Index: ImageAction.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import javax.ejb.Stateless;
  import javax.persistence.EntityManager;
  
  import org.jboss.seam.annotations.In;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.security.SeamSecurityManager;
  
  @Stateless
  @Name("imageAction")
  public class ImageAction implements ImageLocal
  {
     @In(create = true) EntityManager entityManager;
     
     public MemberImage getImage(int imageId)
     {
        MemberImage img = entityManager.find(MemberImage.class, imageId);
  
        if (img != null && SeamSecurityManager.hasPermission("MemberImage", "view", img))      
           return img;
        else
           return null;
     }
  }
  
  
  
  1.1      date: 2006/12/21 05:34:47;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ImageLocal.java
  
  Index: ImageLocal.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import javax.ejb.Local;
  
  @Local
  public interface ImageLocal
  {
    MemberImage getImage(int imageId);
  }
  
  
  


From forge-admin at jboss.com  Thu Dec 21 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Thu, 21 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GxGyi-0006FX-JZ@committer01.frg.pub.inap.atl.jboss.com>

Commit from rsigal on branch remoting_2_x (2006-12-20 03:21 EST)
-----------------------------------------

JBREM-650:  In createControlConnection() send Bisocket.CREATE_CONTROL_SOCKET after first invocation.

  JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java  1.1.2.3


Commit from rsigal on branch remoting_2_x (2006-12-20 03:54 EST)
-----------------------------------------

JBREM-650:  Renamed misspelled unit test case.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestCase.java  1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-20 03:57 EST)
-----------------------------------------

JBREM-650: Added test for new server side control socket after control connection failure in two failure test methods.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java  1.1.2.3


Commit from rsigal on branch remoting_2_x (2006-12-20 03:59 EST)
-----------------------------------------

JBREM-650: Changed names of keystore and truststore files.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketTestCase.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-20 04:00 EST)
-----------------------------------------

JBREM-650: Fixed transport name and added addExtraCallbackConfig().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/FactoryConfigTestCase.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-20 04:01 EST)
-----------------------------------------

JBREM-650: Added overriding testCallbacks().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerClientTest.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-20 04:02 EST)
-----------------------------------------

JBREM-650: Added main().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerServerTest.java  1.1.2.2


Commit from rsigal on branch remoting_2_x (2006-12-20 04:03 EST)
-----------------------------------------

JBREM-650: Added calls to addExtraCallbackConfig().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseParent.java     1.5.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseSSLParent.java  1.7.4.1


Commit from rsigal (2006-12-20 04:07 EST)
------------------

file BiocketConnectionCheckTestCase.java was initially added on branch remoting_2_x.

- JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BiocketConnectionCheckTestCase.java  1.1


Commit from msurtani (2006-12-20 04:07 EST)
--------------------

Made _block and _unblock public

  JBossCache  src/org/jboss/cache/TreeCache.java  1.296


Commit from rsigal (2006-12-20 04:08 EST)
------------------

file keystore was initially added on branch remoting_2_x.

- JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/keystore  1.1


Commit from rsigal (2006-12-20 04:08 EST)
------------------

file truststore was initially added on branch remoting_2_x.

- JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/truststore  1.1


Commit from rsigal on branch remoting_2_x (2006-12-20 04:08 EST)
-----------------------------------------

JBREM-650: Renamed keystore and truststore files.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/.truststore  1.1.2.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/.keystore    1.1.2.1


Commit from rsigal on branch remoting_2_x (2006-12-20 04:09 EST)
-----------------------------------------

JBREM-650: Added getTransport().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/load/PooledConnectionTestCase.java  1.2.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/load/SocketLoadTestCase.java        1.2.6.1


Commit from rsigal on branch remoting_2_x (2006-12-20 04:10 EST)
-----------------------------------------

JBREM-650: Made createServerSocketFactory() protected.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerClientTest.java  1.12.4.1


Commit from rsigal on branch remoting_2_x (2006-12-20 04:11 EST)
-----------------------------------------

JBREM-650: Added getTransport().

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutClientTest.java                   1.6.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutServerTest.java                   1.5.4.1
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutClientTest.java          1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutTestServer.java          1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutClientTest.java  1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutTestServer.java  1.1.2.2


Commit from sbryzak2 (2006-12-20 06:40 EST)
--------------------

added profile page

  jboss-seam  examples/seamspace/resources/import.sql                                     1.4
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java    1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java         1.7
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java    1.1
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java  1.1
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileLocal.java   1.1
  jboss-seam  examples/seamspace/view/template.xhtml                                      1.4
+ jboss-seam  examples/seamspace/view/profile.xhtml                                       1.1


Commit from msurtani (2006-12-20 08:16 EST)
--------------------

Should help with CC runs now...

  JBossCache  tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java  1.3


Commit from ovidiu (2006-12-20 08:28 EST)
------------------

added JBoss Messaging 1.2.0.Beta1

+ repository.jboss.com  jboss/messaging/1.2.0.Beta1/component-info.xml       1.1
+ repository.jboss.com  jboss/messaging/1.2.0.Beta1/lib/jboss-messaging.jar  1.1


Commit from msurtani (2006-12-20 08:29 EST)
--------------------

added async sleep

  JBossCache  tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java  1.3


Commit from msurtani (2006-12-20 08:34 EST)
--------------------

Added sufficient clean ups to unit tests

  JBossCache  tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java        1.6
  JBossCache  tests/functional/org/jboss/cache/passivation/BasicPassivationTest.java             1.12
  JBossCache  tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java  1.11
  JBossCache  tests/functional/org/jboss/cache/misc/TestingUtil.java                             1.10
  JBossCache  tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java              1.5


Commit from msurtani (2006-12-20 08:40 EST)
--------------------

added time for tcp cache server to start up

  JBossCache  tests/functional/org/jboss/cache/loader/TcpCacheLoaderTest.java  1.12


Commit from msurtani (2006-12-20 08:56 EST)
--------------------

refactored

  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java  1.32
  JBossCache  tests/stress/org/jboss/cache/LocalStressTest.java      1.8


Commit from msurtani (2006-12-20 11:04 EST)
--------------------

fixed getChildren()

  JBossCache  src/org/jboss/cache/TreeCache.java  1.297
  JBossCache  src/org/jboss/cache/NodeImpl.java   1.27


Commit from gavin (2006-12-20 11:50 EST)
-----------------

schema

  jboss-seam  examples/drools/resources/WEB-INF/components.xml  1.7


Commit from gavin (2006-12-20 12:01 EST)
-----------------

JBSEAM-624

  jboss-seam  src/main/org/jboss/seam/core/Interpolator.java  1.14


Commit from starksm (2006-12-20 12:53 EST)
-------------------

Add the missing pom

+ repository.jboss.com  maven2/jboss/jboss-common-core/2.0.3.GA/jboss-common-core-2.0.3.GA.pom  1.1


Commit from vralev (2006-12-20 14:41 EST)
------------------

replaceing with the original patch1 binaries

    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/bin/ejb3.deployer          1.2
    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml         1.2
    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/jboss-ejb3-client.jar  1.2
    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/lib/hibernate-client.jar   1.2


Commit from vralev (2006-12-20 14:45 EST)
------------------

replaceing with the original patch1 binaries

    repository.jboss.com/jboss/ejb3/1.0.0.CR9-patch1-jboss4.0.5/component-info.xml  1.3


Commit from mculpepper (2006-12-20 14:56 EST)
----------------------

got rid of the working copies idea, and eliminated the model bridge as it was making things too complicated. package nodes now keep references to their parents and children, (just like delegates). there shouldn't be any need for synch as addChild/removeChild take care of all the details there. the way to create a package node that isn't attached to the model yet is:

pkg = PackagesCore.createDetachedPackage(project, true);
pkg.setXXX..
PackagesCore.attach(pkg, monitor);

- jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeWorkingCopy.java         1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/PackagesCore.java                    1.11
- jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSetWorkingCopy.java      1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFileSet.java                 1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolder.java                  1.2
- jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageFolderWorkingCopy.java       1.3
- jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageWorkingCopy.java             1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackagesModelListener.java          1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNode.java                    1.4
- jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackageNodeBase.java                1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/IPackage.java                        1.5
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackagesModel.java          1.11
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageNodeImpl.java        1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageBuildDelegate.java   1.7
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFolderImpl.java      1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageImpl.java            1.7
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/PackageFileSetImpl.java     1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java            1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/internal/xb/XbPackageNode.java       1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/NewJARWizard.java                      1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/AbstractPackageWizard.java             1.5
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/NewWARWizard.java                      1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/FilesetWizard.java                     1.5
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/FilesetInfoWizardPage.java       1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/PackageInfoWizardPage.java       1.3
+ jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/wizards/pages/DefaultJARConfigWizardPage.java  1.1
+ jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/providers/PackagePreviewContentProvider.java   1.1
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util/PackagesListenerProxy.java                1.2
+ jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/util/PackagePreviewComposite.java              1.1
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.ui/src/main/org/jboss/ide/eclipse/packages/ui/views/ProjectPackagesView.java                 1.8
  jbosside  core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/AllTests.java                                     1.3
  jbosside  core/tests/org.jboss.ide.eclipse.packages.test/src/org/jboss/ide/eclipse/packages/test/PackagesEARTest.java                              1.4


Commit from mculpepper (2006-12-20 14:57 EST)
----------------------

re-exporting the ant dependency and the truezip classes now

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/META-INF/MANIFEST.MF  1.4


Commit from mculpepper (2006-12-20 15:31 EST)
----------------------

added getSupportFor so we can prompt users if/when a project that might need extra setup can be  determined

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java  1.5
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/IPackageType.java    1.2


Commit from mculpepper (2006-12-20 15:32 EST)
----------------------

added "FINISH" constant

  jbosside  core/plugins/org.jboss.ide.eclipse.ui/src/main/org/jboss/ide/eclipse/ui/wizards/WizardWithNotification.java  1.2


Commit from mculpepper (2006-12-20 15:43 EST)
----------------------

changed getSupportFor to check for nature instead of using JavaCore.create

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java  1.6


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-20 16:26 EST)
---------------------------------------------------------

Prevent NPE in cleanupStaleLocks

  JBossCache  src/org/jboss/cache/interceptors/TxInterceptor.java  1.48.2.11


Commit from vblagojevic (2006-12-20 17:27 EST)
-----------------------

fix NPE

  JBossCache  src/org/jboss/cache/NodeImpl.java  1.28


Commit from vblagojevic (2006-12-20 17:28 EST)
-----------------------

final state transfer refactoring

  JBossCache  src/org/jboss/cache/marshall/MethodDeclarations.java                   1.27
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                 1.50
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java  1.8
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferManager.java            1.18
  JBossCache  src/org/jboss/cache/TreeCache.java                                     1.298


Commit from sbryzak2 (2006-12-20 21:38 EST)
--------------------

fixed compiler warnings

  jboss-seam  src/main/org/jboss/seam/actionparam/MethodExpressionParser.java                      1.4
  jboss-seam  src/main/org/jboss/seam/contexts/EntityBean.java                                     1.5
  jboss-seam  src/main/org/jboss/seam/contexts/PassivatedEntity.java                               1.4
  jboss-seam  src/main/org/jboss/seam/core/Actor.java                                              1.13
  jboss-seam  src/main/org/jboss/seam/core/BusinessProcess.java                                    1.17
  jboss-seam  src/main/org/jboss/seam/core/Conversation.java                                       1.33
  jboss-seam  src/main/org/jboss/seam/core/ConversationEntries.java                                1.6
  jboss-seam  src/main/org/jboss/seam/core/ConversationEntry.java                                  1.33
  jboss-seam  src/main/org/jboss/seam/core/ConversationList.java                                   1.11
  jboss-seam  src/main/org/jboss/seam/core/ConversationStack.java                                  1.8
  jboss-seam  src/main/org/jboss/seam/core/Dispatcher.java                                         1.15
  jboss-seam  src/main/org/jboss/seam/core/Expressions.java                                        1.13
  jboss-seam  src/main/org/jboss/seam/core/FacesMessages.java                                      1.26
  jboss-seam  src/main/org/jboss/seam/core/FacesPage.java                                          1.6
  jboss-seam  src/main/org/jboss/seam/core/LocaleSelector.java                                     1.18
  jboss-seam  src/main/org/jboss/seam/core/ManagedPersistenceContext.java                          1.30
  jboss-seam  src/main/org/jboss/seam/core/Messages.java                                           1.10
  jboss-seam  src/main/org/jboss/seam/core/Pageflow.java                                           1.49
  jboss-seam  src/main/org/jboss/seam/core/PersistenceContexts.java                                1.3
  jboss-seam  src/main/org/jboss/seam/core/Redirect.java                                           1.10
  jboss-seam  src/main/org/jboss/seam/core/ResourceBundle.java                                     1.25
  jboss-seam  src/main/org/jboss/seam/core/Switcher.java                                           1.17
  jboss-seam  src/main/org/jboss/seam/core/TimeZoneSelector.java                                   1.8
  jboss-seam  src/main/org/jboss/seam/core/Transition.java                                         1.11
  jboss-seam  src/main/org/jboss/seam/drools/DroolsActionHandler.java                              1.4
  jboss-seam  src/main/org/jboss/seam/drools/DroolsAssignmentHandler.java                          1.4
  jboss-seam  src/main/org/jboss/seam/drools/DroolsDecisionHandler.java                            1.4
  jboss-seam  src/main/org/jboss/seam/drools/ManagedWorkingMemory.java                             1.8
  jboss-seam  src/main/org/jboss/seam/ejb/SeamInterceptor.java                                     1.49
  jboss-seam  src/main/org/jboss/seam/framework/EntityHome.java                                    1.10
  jboss-seam  src/main/org/jboss/seam/framework/EntityNotFoundException.java                       1.4
  jboss-seam  src/main/org/jboss/seam/framework/HibernateEntityHome.java                           1.7
  jboss-seam  src/main/org/jboss/seam/framework/Home.java                                          1.10
  jboss-seam  src/main/org/jboss/seam/intercept/ClientSideInterceptor.java                         1.9
  jboss-seam  src/main/org/jboss/seam/intercept/JavaBeanInterceptor.java                           1.11
  jboss-seam  src/main/org/jboss/seam/intercept/RootInterceptor.java                               1.8
  jboss-seam  src/main/org/jboss/seam/intercept/SessionBeanInterceptor.java                        1.11
  jboss-seam  src/main/org/jboss/seam/interceptors/AbstractInterceptor.java                        1.8
  jboss-seam  src/main/org/jboss/seam/interceptors/AsynchronousInterceptor.java                    1.9
  jboss-seam  src/main/org/jboss/seam/interceptors/BijectionInterceptor.java                       1.25
  jboss-seam  src/main/org/jboss/seam/interceptors/BusinessProcessInterceptor.java                 1.49
  jboss-seam  src/main/org/jboss/seam/interceptors/ConversationInterceptor.java                    1.57
  jboss-seam  src/main/org/jboss/seam/interceptors/ConversationalInterceptor.java                  1.12
  jboss-seam  src/main/org/jboss/seam/interceptors/EventInterceptor.java                           1.5
  jboss-seam  src/main/org/jboss/seam/interceptors/ExceptionInterceptor.java                       1.15
  jboss-seam  src/main/org/jboss/seam/interceptors/ManagedEntityIdentityInterceptor.java           1.18
  jboss-seam  src/main/org/jboss/seam/interceptors/MethodContextInterceptor.java                   1.3
  jboss-seam  src/main/org/jboss/seam/interceptors/OutcomeInterceptor.java                         1.7
  jboss-seam  src/main/org/jboss/seam/interceptors/RemoveInterceptor.java                          1.19
  jboss-seam  src/main/org/jboss/seam/interceptors/RollbackInterceptor.java                        1.15
  jboss-seam  src/main/org/jboss/seam/interceptors/SecurityInterceptor.java                        1.15
  jboss-seam  src/main/org/jboss/seam/interceptors/SynchronizationInterceptor.java                 1.5
  jboss-seam  src/main/org/jboss/seam/interceptors/TransactionInterceptor.java                     1.12
  jboss-seam  src/main/org/jboss/seam/interceptors/ValidationInterceptor.java                      1.26
  jboss-seam  src/main/org/jboss/seam/jsf/ArrayDataModel.java                                      1.2
  jboss-seam  src/main/org/jboss/seam/jsf/ListDataModel.java                                       1.2
  jboss-seam  src/main/org/jboss/seam/jsf/MapDataModel.java                                        1.3
  jboss-seam  src/main/org/jboss/seam/jsf/SeamExtendedManagedPersistencePhaseListener.java         1.24
  jboss-seam  src/main/org/jboss/seam/jsf/SeamExtendedManagedPersistencePortletPhaseListener.java  1.8
  jboss-seam  src/main/org/jboss/seam/jsf/SeamPhaseListener.java                                   1.96
  jboss-seam  src/main/org/jboss/seam/jsf/SeamPortletPhaseListener.java                            1.19
  jboss-seam  src/main/org/jboss/seam/jsf/SetDataModel.java                                        1.3
  jboss-seam  src/main/org/jboss/seam/jsf/TransactionalSeamPhaseListener.java                      1.3
  jboss-seam  src/main/org/jboss/seam/jsf/TransactionalSeamPortletPhaseListener.java               1.3
  jboss-seam  src/main/org/jboss/seam/log/LogImpl.java                                             1.9
  jboss-seam  src/main/org/jboss/seam/mock/MockAclObjectIdentity.java                              1.2
  jboss-seam  src/main/org/jboss/seam/mock/MockAclPermission.java                                  1.4
  jboss-seam  src/main/org/jboss/seam/mock/MockSecureEntity.java                                   1.4
  jboss-seam  src/main/org/jboss/seam/remoting/SeamRemotingServlet.java                            1.13
  jboss-seam  src/main/org/jboss/seam/remoting/wrapper/ConversionException.java                    1.3
  jboss-seam  src/main/org/jboss/seam/security/AuthenticationException.java                        1.6
  jboss-seam  src/main/org/jboss/seam/security/Role.java                                           1.2
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java                            1.29
  jboss-seam  src/main/org/jboss/seam/security/UsernamePasswordToken.java                          1.9
  jboss-seam  src/main/org/jboss/seam/security/acl/IdentityException.java                          1.2
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfigException.java                 1.2
  jboss-seam  src/main/org/jboss/seam/security/filter/SeamSecurityFilter.java                      1.16
  jboss-seam  src/main/org/jboss/seam/theme/Theme.java                                             1.4
  jboss-seam  src/main/org/jboss/seam/theme/ThemeSelector.java                                     1.11
  jboss-seam  src/main/org/jboss/seam/util/Conversions.java                                        1.10
  jboss-seam  src/main/org/jboss/seam/util/DTDEntityResolver.java                                  1.3
  jboss-seam  src/test/misc/org/jboss/seam/test/Bar.java                                           1.6
  jboss-seam  src/test/misc/org/jboss/seam/test/Foo.java                                           1.7
  jboss-seam  src/test/misc/org/jboss/seam/test/PhaseListenerTest.java                             1.29
  jboss-seam  src/test/misc/org/jboss/seam/test/RemotingTest.java                                  1.9


Commit from bstansberry (2006-12-20 21:57 EST)
-----------------------

Avoid NPE in clearStaleLocks

  JBossCache  src/org/jboss/cache/interceptors/TxInterceptor.java  1.68


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-20 23:40 EST)
---------------------------------------------------------

[JBCACHE-913] Notify eviction policies of nodes added via state transfer

+ JBossCache  tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java  1.1.2.1
  JBossCache  src/org/jboss/cache/TreeCache.java                                           1.195.2.38


Commit from bstansberry (2006-12-21 00:04 EST)
-----------------------

[JBCACHE-913] Add test of notifying eviction policies of nodes added via state transfer

+ JBossCache  tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java  1.2


Commit from sbryzak2 (2006-12-21 00:32 EST)
--------------------

assert Identity into working memory only if it exists

  jboss-seam  src/main/org/jboss/seam/security/Identity.java             1.5
  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java  1.30


Commit from bstansberry (2006-12-21 00:34 EST)
-----------------------

Fix bizarre args to createDataNode

  JBossCache  src/org/jboss/cache/TreeCache.java  1.299


Commit from sbryzak2 (2006-12-21 00:34 EST)
--------------------

added content servlet for serving images

  jboss-seam  examples/seamspace/resources/WEB-INF/web.xml                                    1.5
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/AclObjectIdentity.java  1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/AclPermission.java      1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java        1.4
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java             1.8
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java        1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/MemberRole.java         1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java      1.2
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java     1.1
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ImageAction.java        1.1
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ImageLocal.java         1.1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061221/26206ab1/attachment.html 

From hg8rte8w456rtew at Safe-mail.net  Thu Dec 21 02:10:34 2006
From: hg8rte8w456rtew at Safe-mail.net (hg8rte8w456rtew at Safe-mail.net)
Date: Thu, 21 Dec 2006 02:10:34 -0500
Subject: [jboss-cvs] =?utf-8?b?MjDClsKcwpdwwojDk8KCwrXCgsOcwoLCtcKCwr0=?=
	=?utf-8?b?woFCwo3CocKTw7rCgsOIwoLDp8KJwr3CjsKewoLDicKIwqfCgsKmwoI=?=
	=?utf-8?b?w5zCgsK3woLCqcKBSA==?=
Message-ID: 20061221163701.48132mail@mail.mlpnkobjivhucgyxftzdrseawqpoiuytrewq.com

???????A???????????????????X?????????v???????????????????A
?????????????X???????H???????????????????????????s???????B
?????\??????20???p???????????B20?????????????????????????H
??????????????20???????n???????????????c?B
?????????p?\?R?????G???????????g?????A???????????????H
http://www.go-perfectfree.com.tonderuyo.com/kin/
?????????d?b???????m?F?????????????B





From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 02:38:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 02:38:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r59185 -
	projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/attachments
Message-ID: <E1GxIVm-00081w-NE@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-21 02:38:40 -0500 (Thu, 21 Dec 2006)
New Revision: 59185

Modified:
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/attachments/AttachmentsImpl.java
Log:
Add a setAttachments method and set the serialVersionUID

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/attachments/AttachmentsImpl.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/attachments/AttachmentsImpl.java	2006-12-21 02:54:55 UTC (rev 59184)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/attachments/AttachmentsImpl.java	2006-12-21 07:38:40 UTC (rev 59185)
@@ -33,6 +33,8 @@
  */
 public class AttachmentsImpl extends AbstractAttachments
 {
+   private static final long serialVersionUID = 1;
+
    /** The attachments */
    private Map<String, Object> attachments = new ConcurrentHashMap<String, Object>();
 
@@ -40,6 +42,11 @@
    {
       return Collections.unmodifiableMap(attachments);
    }
+   public void setAttachments(Map<String, Object> map)
+   {
+      attachments.clear();
+      attachments.putAll(map);
+   }
 
    public Object addAttachment(String name, Object attachment)
    {



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 02:44:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 02:44:00 -0500
Subject: [jboss-cvs] JBossAS SVN: r59186 - in
	projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers:
	plugins/structure spi/structure
Message-ID: <E1GxIau-000873-4S@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-21 02:43:55 -0500 (Thu, 21 Dec 2006)
New Revision: 59186

Modified:
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/AbstractDeploymentContext.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ComponentDeploymentContext.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/DeploymentContext.java
Log:
Add a setPredeterminedManagedObjects to the DeploymentContext

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/AbstractDeploymentContext.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/AbstractDeploymentContext.java	2006-12-21 07:38:40 UTC (rev 59185)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/AbstractDeploymentContext.java	2006-12-21 07:43:55 UTC (rev 59186)
@@ -46,7 +46,8 @@
  * AbstractDeploymentContext.
  * 
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
  */
 public class AbstractDeploymentContext
    implements DeploymentContext, Serializable
@@ -586,7 +587,12 @@
    {
       return predeterminedManagedObjects;
    }
-   
+   public void setPredeterminedManagedObjects(Attachments objects)
+   {
+      predeterminedManagedObjects.clear();
+      ((AttachmentsImpl)predeterminedManagedObjects).setAttachments(objects.getAttachments());
+   }
+
    public Attachments getTransientManagedObjects()
    {
       return transientManagedObjects;


Property changes on: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/AbstractDeploymentContext.java
___________________________________________________________________
Name: svn:keywords
   + Id, Revision

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ComponentDeploymentContext.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ComponentDeploymentContext.java	2006-12-21 07:38:40 UTC (rev 59185)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ComponentDeploymentContext.java	2006-12-21 07:43:55 UTC (rev 59186)
@@ -43,7 +43,8 @@
  * AbstractDeploymentContext.
  * 
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
  */
 public class ComponentDeploymentContext
    implements DeploymentContext, Serializable
@@ -348,6 +349,10 @@
    {
       return parent.getPredeterminedManagedObjects();
    }
+   public void setPredeterminedManagedObjects(Attachments objects)
+   {
+      // TODO should throw an exception or support this at the component
+   }
    
    public Attachments getTransientManagedObjects()
    {


Property changes on: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ComponentDeploymentContext.java
___________________________________________________________________
Name: svn:keywords
   + Id, Revision

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/DeploymentContext.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/DeploymentContext.java	2006-12-21 07:38:40 UTC (rev 59185)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/DeploymentContext.java	2006-12-21 07:43:55 UTC (rev 59186)
@@ -34,7 +34,8 @@
  * DeploymentContext.
  * 
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @version $Revision: 1.1 $
+ * @author Scott.Stark at jboss.org
+ * @version $Revision$
  */
 public interface DeploymentContext
 {
@@ -304,6 +305,11 @@
     * @return the predetermined managed objects
     */
    Attachments getPredeterminedManagedObjects();
+   /**
+    * Sst the predetermined managed objects
+    * @param objects the predetermined managed objects
+    */
+   void setPredeterminedManagedObjects(Attachments objects);
 
    /**
     * Get the managed objects


Property changes on: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/DeploymentContext.java
___________________________________________________________________
Name: svn:keywords
   + Id, Revision



From Shane_Bryzak at symantec.com  Thu Dec 21 03:16:42 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 03:16:42 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxJ6Y-0000M9-0X@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 03:16:41

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace     
                        ContentServlet.java
  Added:       examples/seamspace/src/org/jboss/seam/example/seamspace     
                        ContentAction.java ContentLocal.java
  Removed:     examples/seamspace/src/org/jboss/seam/example/seamspace     
                        ImageAction.java ImageLocal.java
  Log:
  renamed ImageAction to ContentAction
  
  Revision  Changes    Path
  1.2       +13 -8     jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ContentServlet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ContentServlet.java	21 Dec 2006 05:34:47 -0000	1.1
  +++ ContentServlet.java	21 Dec 2006 08:16:41 -0000	1.2
  @@ -13,13 +13,17 @@
   {
      private static final long serialVersionUID = -8461940507242022217L;
   
  +   private static final String IMAGES_PATH = "/images";
  +
      @Override
      protected void doGet(HttpServletRequest request, HttpServletResponse response)
          throws ServletException, IOException
      {
  -      ImageLocal local = (ImageLocal) Component.getInstance(ImageAction.class);
  +      if (IMAGES_PATH.equals(request.getPathInfo()))
  +      {
  +         ContentLocal contentAction = (ContentLocal) Component.getInstance(ContentAction.class);
         
  -      MemberImage img = local.getImage(Integer.parseInt(request.getParameter("id")));
  +         MemberImage img = contentAction.getImage(Integer.parseInt(request.getParameter("id")));
         
         if (img != null)
         {
  @@ -28,4 +32,5 @@
           response.getOutputStream().flush();
         }
      }
  +   }
   }
  
  
  
  1.1      date: 2006/12/21 08:16:41;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java
  
  Index: ContentAction.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import javax.ejb.Stateless;
  import javax.persistence.EntityManager;
  
  import org.jboss.seam.annotations.In;
  import org.jboss.seam.annotations.Name;
  import org.jboss.seam.security.SeamSecurityManager;
  
  @Stateless
  @Name("contentAction")
  public class ContentAction implements ContentLocal
  {
     @In(create = true) EntityManager entityManager;
     
     public MemberImage getImage(int imageId)
     {
        MemberImage img = entityManager.find(MemberImage.class, imageId);
  
        if (img != null && SeamSecurityManager.hasPermission("MemberImage", "view", img))      
           return img;
        else
           return null;
     }
  }
  
  
  
  1.1      date: 2006/12/21 08:16:41;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentLocal.java
  
  Index: ContentLocal.java
  ===================================================================
  package org.jboss.seam.example.seamspace;
  
  import javax.ejb.Local;
  
  @Local
  public interface ContentLocal
  {
    MemberImage getImage(int imageId);
  }
  
  
  


From t2-okada at nri.co.jp  Thu Dec 21 06:18:20 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 21 Dec 2006 06:18:20 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/model
	...
Message-ID: <E1GxLwK-0003ej-7b@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/21 06:18:20

  Modified:    java/src/expansion/org/jboss/profiler/exp/agent/collector/model 
                        Tag: JBossProfiler_Expansion ThreadMetric.java
  Log:
  Modified an implementation concerned the sorting.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +8 -2      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/model/Attic/ThreadMetric.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThreadMetric.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/model/Attic/ThreadMetric.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- ThreadMetric.java	31 Oct 2006 11:27:51 -0000	1.1.2.2
  +++ ThreadMetric.java	21 Dec 2006 11:18:20 -0000	1.1.2.3
  @@ -25,6 +25,7 @@
   import java.io.Serializable;
   import java.util.ArrayList;
   import java.util.Collections;
  +import java.util.Comparator;
   import java.util.HashMap;
   import java.util.List;
   import java.util.Map;
  @@ -54,8 +55,7 @@
       }
       
       public List<Entry> getEntries() {
  -        Collections.reverse(entries);
  -        Collections.sort(entries);
  +        Collections.sort(entries, new TimestampComparator());
           return entries;
       }
       
  @@ -139,4 +139,10 @@
           }
       }
   
  +    private class TimestampComparator implements Comparator<Entry>, Serializable {
  +        public int compare(Entry o1, Entry o2) {
  +            return Long.valueOf(o1.getTimestamp()).compareTo(Long.valueOf(o2.getTimestamp()));
  +        }
  +    }
  +
   }
  
  
  


From t2-okada at nri.co.jp  Thu Dec 21 06:21:09 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 21 Dec 2006 06:21:09 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/lzx     ...
Message-ID: <E1GxLz3-0003iC-6Y@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/21 06:21:09

  Modified:    java/webapp/lzx     Tag: JBossProfiler_Expansion
                        borderedpane.lzx stacktracediagram.lzx
                        httprequeststatistics.lzx dataaccessstatistics.lzx
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +24 -12    jboss-profiler/java/webapp/lzx/Attic/borderedpane.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: borderedpane.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/borderedpane.lzx,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- borderedpane.lzx	26 Oct 2006 09:02:25 -0000	1.1.2.1
  +++ borderedpane.lzx	21 Dec 2006 11:21:09 -0000	1.1.2.2
  @@ -30,28 +30,40 @@
   <library>
     <class name="borderedpane" extends="basecomponent">
       
  +    <attribute name="bordersize" type="number" value="1"/>
       <attribute name="padding" type="number" value="8"/>
       
       <view name="innerpane">
         <view name="contents"/>
       </view>
       
  -    <!--- @keywords private -->
  -    <method name="_applystyle" args="s">
  -      this.setWidth(this.width+(s.bordersize*2+this.padding*2));
  -      this.setHeight(this.height+(s.bordersize*2+this.padding*2));
  -      this.setBGColor(s.bordercolor);
  -      
  -      innerpane.setX(innerpane.x+s.bordersize);
  -      innerpane.setY(innerpane.y+s.bordersize);
  -      innerpane.setWidth(this.width-s.bordersize*2);
  -      innerpane.setHeight(this.height-s.bordersize*2);
  -      innerpane.setBGColor(s.basecolor);
  -      
  +    <handler name="oninit">
  +      innerpane.setX(innerpane.x+this.bordersize);
         innerpane.contents.setX(innerpane.contents.x+this.padding);
  +      updateWidth(innerpane.contents.width);
  +      
  +      innerpane.setY(innerpane.y+this.bordersize);
         innerpane.contents.setY(innerpane.contents.y+this.padding);
  +      updateHeight(innerpane.contents.height);
  +    </handler>
  +    
  +    <method name="updateWidth" args="w">
  +      this.setWidth(w+(this.bordersize*2+this.padding*2));
  +      innerpane.setWidth(this.width-this.bordersize*2);
         innerpane.contents.setWidth(innerpane.width-this.padding*2);
  +    </method>
  +    
  +    <method name="updateHeight" args="h">
  +      this.setHeight(h+(bordersize*2+this.padding*2));
  +      innerpane.setHeight(this.height-this.bordersize*2);
         innerpane.contents.setHeight(innerpane.height-this.padding*2);
  +    </method>
  +    
  +    <!--- @keywords private -->
  +    <method name="_applystyle" args="s">
  +      this.setAttribute("bordersize", s.bordersize);
  +      this.setBGColor(s.bordercolor);
  +      innerpane.setBGColor(s.basecolor);
         innerpane.contents.setBGColor(s.basecolor);
       </method>
     </class>
  
  
  
  1.1.2.6   +7 -6      jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: stacktracediagram.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/stacktracediagram.lzx,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -b -r1.1.2.5 -r1.1.2.6
  --- stacktracediagram.lzx	15 Dec 2006 06:14:44 -0000	1.1.2.5
  +++ stacktracediagram.lzx	21 Dec 2006 11:21:09 -0000	1.1.2.6
  @@ -33,7 +33,7 @@
     <include href="linedrawview.lzx"/>
     <include href="floatingmessage.lzx"/>
     
  -  <class name="popupmessage" extends="basecomponent" bgcolor="0xffffff">
  +  <class name="std_popupmessage" extends="basecomponent" bgcolor="0xffffff">
       <simplelayout axis="y"/>
       <method name="setMessage" args="message">
         <![CDATA[
  @@ -239,6 +239,7 @@
         this.lanes.height = this.height - this.padding*2;
         this.drawview.height = this.height - (this.padding+2)*2;
         
  +      var activations = new Array();
         var messages = new Array();
         
         for(var i=0; i<d.childNodes.length; i++) {
  @@ -298,16 +299,16 @@
                                             detail);
           }else {
             updateLane.setActivation(beginPixel, elapsedPixel, detail);
  -          if(i!=0) {
  +          if(callerClassName=="<servlet>") {
  +            messages.unshift({lane:updateLane, caller:null, begin:beginPixel, elapsed:elapsedPixel, id:id, method:name});
  +          }else {
               messages.push({lane:updateLane, caller:callerClassName, begin:beginPixel, elapsed:elapsedPixel, id:id, method:name});
             }
           }
         }
         for(var i=0; i<messages.length; i++) {
           var callerLane = null;
  -        if(messages[i]["caller"]=="<servlet>") {
  -          callerLane = this.lanes.subviews[0];
  -        }else {
  +        if(messages[i]["caller"]!=null) {
             callerLane = selectLane(messages[i]["caller"]);
           }
           if(callerLane!=null) {
  @@ -336,7 +337,7 @@
       </method>
       
       <method name="openMessage" args="activation">
  -      var pm = new popupmessage(this, {name:"popupmessage", x:this.getMouse("x")+4, y:this.getMouse("y")-88});
  +      var pm = new std_popupmessage(this, {name:"popupmessage", x:this.getMouse("x")+4, y:this.getMouse("y")-88});
         pm.setMessage(activation.message);
       </method>
       
  
  
  
  1.1.2.4   +5 -1      jboss-profiler/java/webapp/lzx/Attic/httprequeststatistics.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: httprequeststatistics.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/httprequeststatistics.lzx,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- httprequeststatistics.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.3
  +++ httprequeststatistics.lzx	21 Dec 2006 11:21:09 -0000	1.1.2.4
  @@ -54,7 +54,8 @@
               multiselect="false">
           <notifygridtext width="60" datapath="@id" textalign="right"
                           sourceevent="ondblclick"
  -                        target="${parent.parent.parent}" targetevent="onselect">
  +                        target="${parent.parent.parent}" targetevent="onselect"
  +                        datatype="number">
             ID
           </notifygridtext>
           <notifygridtext width="${parent.width-(6+580)}" datapath="@name"
  @@ -89,6 +90,9 @@
             selectionString += selectionDp.getNodeAttribute("value");
             LzBrowser.setClipboard(selectionString);
           </method>
  +        <handler name="ondata">
  +          this.columns[0].doSort();
  +        </handler>
         </grid>
         <method name="_applystyle" args="s">
           this.setBGColor(s.bordercolor);
  
  
  
  1.1.2.5   +2 -1      jboss-profiler/java/webapp/lzx/Attic/dataaccessstatistics.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: dataaccessstatistics.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/dataaccessstatistics.lzx,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -b -r1.1.2.4 -r1.1.2.5
  --- dataaccessstatistics.lzx	13 Dec 2006 10:13:38 -0000	1.1.2.4
  +++ dataaccessstatistics.lzx	21 Dec 2006 11:21:09 -0000	1.1.2.5
  @@ -54,7 +54,8 @@
               multiselect="false">
           <notifygridtext width="60" datapath="@id" textalign="right"
                           sourceevent="ondblclick"
  -                        target="${parent.parent.parent}" targetevent="onselect">
  +                        target="${parent.parent.parent}" targetevent="onselect"
  +                        datatype="number">
             ID
           </notifygridtext>
           <notifygridtext width="${parent.width-(6+580)}" datapath="@name"
  
  
  


From t2-okada at nri.co.jp  Thu Dec 21 06:22:05 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 21 Dec 2006 06:22:05 -0500
Subject: [jboss-cvs] jboss-profiler/java/webapp/lzx     ...
Message-ID: <E1GxLzx-0003k5-6t@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/21 06:22:05

  Modified:    java/webapp/lzx     Tag: JBossProfiler_Expansion
                        settingdialog.lzx loadingsplash.lzx
  Added:       java/webapp/lzx     Tag: JBossProfiler_Expansion
                        popupmessage.lzx hintededittext.lzx
  Log:
  Added some functions.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.6   +15 -5     jboss-profiler/java/webapp/lzx/Attic/settingdialog.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: settingdialog.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/settingdialog.lzx,v
  retrieving revision 1.1.2.5
  retrieving revision 1.1.2.6
  diff -u -b -r1.1.2.5 -r1.1.2.6
  --- settingdialog.lzx	15 Dec 2006 06:14:44 -0000	1.1.2.5
  +++ settingdialog.lzx	21 Dec 2006 11:22:05 -0000	1.1.2.6
  @@ -30,6 +30,7 @@
   <library>
   
     <include href="borderedpane.lzx"/>
  +  <include href="hintededittext.lzx"/>
     
     <dataset name="initializeData"
              request="false" timeout="5000" type="http" querytype="POST"
  @@ -168,6 +169,9 @@
         </tabpane>
         <!-- ##### Warning Tab ##### -->
         <tabpane text="Warning" fontsize="10">
  +        <view width="${parent.width}" height="${parent.height}">
  +        </view>
  +        <view>
           <simplelayout axis="y" spacing="4"/>
           <text>Execution Statistics</text>
           <borderedpane x="${this.x+4}">
  @@ -182,7 +186,8 @@
                 </checkbox>
                 <view width="4"/>
                 <text valign="middle">Threshold</text>
  -              <edittext name="threshold" width="100" height="22"/>
  +              <hintededittext name="threshold" width="100" height="22"
  +                              hint="nano seconds" target="${classroot.searchSubviews('mdcontent')}"/>
                 <text valign="middle">Color</text>
                 <combobox name="color" width="60" editable="false">
                   <textlistitem text="red" value="0xff0000" selected="true"/>
  @@ -199,7 +204,8 @@
                 </checkbox>
                 <view width="1"/>
                 <text valign="middle">Threshold</text>
  -              <edittext name="threshold" width="100" height="22"/>
  +              <hintededittext name="threshold" width="100" height="22"
  +                              hint="frequency" target="${classroot.searchSubviews('mdcontent')}"/>
                 <text valign="middle">Color</text>
                 <combobox name="color" width="60" editable="false">
                   <textlistitem text="red" value="0xff0000" selected="true"/>
  @@ -223,7 +229,8 @@
                 </checkbox>
                 <view width="1"/>
                 <text valign="middle">Threshold</text>
  -              <edittext name="threshold" width="100" height="22"/>
  +              <hintededittext name="threshold" width="100" height="22"
  +                              hint="frequency" target="${classroot.searchSubviews('mdcontent')}"/>
                 <text valign="middle">Color</text>
                 <combobox name="color" width="60" editable="false">
                   <textlistitem text="red" value="0xff0000" selected="true"/>
  @@ -247,7 +254,8 @@
                 </checkbox>
                 <view width="6"/>
                 <text valign="middle">Threshold</text>
  -              <edittext name="threshold" width="100" height="22"/>
  +              <hintededittext name="threshold" width="100" height="22"
  +                              hint="bytes" target="${classroot.searchSubviews('mdcontent')}"/>
                 <text valign="middle">Color</text>
                 <combobox name="color" width="60" editable="false">
                   <textlistitem text="red" value="0xff0000" selected="true"/>
  @@ -271,7 +279,8 @@
                 </checkbox>
                 <view width="3"/>
                 <text valign="middle">Threshold</text>
  -              <edittext name="threshold" width="100" height="22"/>
  +              <hintededittext name="threshold" width="100" height="22"
  +                              hint="nano seconds" target="${classroot.searchSubviews('mdcontent')}"/>
                 <text valign="middle">Color</text>
                 <combobox name="color" width="60" editable="false">
                   <textlistitem text="red" value="0xff0000" selected="true"/>
  @@ -281,6 +290,7 @@
               </view>
             </view>
           </borderedpane>
  +      </view>
         </tabpane>
       </tabs>
       <button y="${parent.height-90}" align="center">Profile
  
  
  
  1.1.2.2   +12 -8     jboss-profiler/java/webapp/lzx/Attic/loadingsplash.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: loadingsplash.lzx
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/webapp/lzx/Attic/loadingsplash.lzx,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- loadingsplash.lzx	26 Oct 2006 09:02:25 -0000	1.1.2.1
  +++ loadingsplash.lzx	21 Dec 2006 11:22:05 -0000	1.1.2.2
  @@ -30,24 +30,28 @@
   <library>
   
     <class name="loadingsplash" extends="borderedpane"
  -         x="${parent.width/2-this.width/2}" y="${parent.height/2-this.height/2}"
  -         width="200" height="20">
  -    <text name="label" align="center" valign="middle" font="vera" fontsize="12">Loading
  +         x="${parent.width/2-this.width/2}" y="${parent.height/2-this.height/2}">
  +    <view placement="contents" align="center">
  +      <text name="label" fontsize="12">Loading
         <animator name="blinker" attribute="opacity" motion="linear"
                   from="1" to="0" duration="200" repeat="Infinity" start="true"/>
       </text>
  +    </view>
  +    <handler name="oninit">
  +      this.updateWidth(160);
  +    </handler>
       <!--- @keywords private -->
       <method name="_applystyle" args="s">
         super._applystyle(s);
  -      this.label.setColor(s.bordercolor);
  +      this.innerpane.contents.subviews[0].label.setColor(s.bordercolor);
       </method>
       <method name="close">
  -      this.label.blinker.stop();
  +      this.innerpane.contents.subviews[0].label.blinker.stop();
         this.setAttribute("visible", false);
       </method>
       <method name="restart">
         this.setAttribute("visible", true);
  -      this.label.blinker.doStart();
  +      this.innerpane.contents.subviews[0].label.blinker.doStart();
       </method>
     </class>
     
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +41 -0     jboss-profiler/java/webapp/lzx/Attic/popupmessage.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: popupmessage.lzx
  ===================================================================
  RCS file: popupmessage.lzx
  diff -N popupmessage.lzx
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ popupmessage.lzx	21 Dec 2006 11:22:05 -0000	1.1.2.1
  @@ -0,0 +1,41 @@
  +<?xml version="1.0" encoding="UTF-8" ?>
  +<!--
  +  JBoss, Home of Professional Open Source
  +  Copyright 2006, JBoss Inc., and individual contributors as indicated
  +  by the @authors tag. See the copyright.txt 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.
  +-->
  +<!--
  +  
  +  @author Takuro Okada (Nomura Research Institute, Ltd.)
  +  Copyright 2006 Nomura Research Institute, Ltd. All Rights Reserved.
  +  Copyright(c) Information-technology Promotion Agency, Japan. All rights reserved 2006.
  +  Result of Open Source Software Development Activities of Information-technology Promotion Agency, Japan.
  +-->
  +<library>
  +  <class name="popupmessage" extends="borderedpane"
  +         padding="2">
  +    <view placement="contents">
  +      <text name="message" resize="true" fontsize="9" text=""/>
  +    </view>
  +    <method name="setMessage" args="message">
  +      this.innerpane.contents.subviews[0].message.setText(message);
  +      this.updateWidth(this.innerpane.contents.subviews[0].message.width);
  +    </method>
  +  </class>
  +</library>
  \ No newline at end of file
  
  
  
  1.1.2.1   +52 -0     jboss-profiler/java/webapp/lzx/Attic/hintededittext.lzx
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: hintededittext.lzx
  ===================================================================
  RCS file: hintededittext.lzx
  diff -N hintededittext.lzx
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ hintededittext.lzx	21 Dec 2006 11:22:05 -0000	1.1.2.1
  @@ -0,0 +1,52 @@
  +<?xml version="1.0" encoding="UTF-8" ?>
  +<!--
  +  JBoss, Home of Professional Open Source
  +  Copyright 2006, JBoss Inc., and individual contributors as indicated
  +  by the @authors tag. See the copyright.txt 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.
  +-->
  +<!--
  +  
  +  @author Takuro Okada (Nomura Research Institute, Ltd.)
  +  Copyright 2006 Nomura Research Institute, Ltd. All Rights Reserved.
  +  Copyright(c) Information-technology Promotion Agency, Japan. All rights reserved 2006.
  +  Result of Open Source Software Development Activities of Information-technology Promotion Agency, Japan.
  +-->
  +<library>
  +  
  +  <include href="popupmessage.lzx"/>
  +  
  +  <class name="hintededittext" extends="edittext">
  +    <attribute name="target" value="${this.classroot}"/>
  +    <attribute name="hint" type="string"/>
  +    <view width="${parent.width}" height="${parent.height}">
  +      <handler name="onmouseover">
  +          this.setAttribute("hinted", true);
  +          var message = new popupmessage(classroot.target, {name:"pm", x:classroot.target.getMouse("x"), y:classroot.target.getMouse("y")-16});
  +          message.setMessage(classroot.hint);
  +      </handler>
  +      <handler name="onmouseout">
  +        classroot.target.searchSubnodes("name", "pm").destroy(true);
  +      </handler>
  +      <handler name="onclick">
  +        LzFocus.setFocus(classroot);
  +      </handler>
  +    </view>
  +  </class>
  +  
  +</library>
  \ No newline at end of file
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 06:41:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 06:41:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r59187 - in projects/aop/branches: .
	arrays/aop arrays/aop/src/main/org/jboss/aop
	arrays/aop/src/main/org/jboss/aop/instrument
	arrays/aop/src/main/org/jboss/aop/proxy/container
Message-ID: <E1GxMJB-00048f-H6@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-21 06:41:51 -0500 (Thu, 21 Dec 2006)
New Revision: 59187

Added:
   projects/aop/branches/arrays/
   projects/aop/branches/arrays/aop/.classpath
   projects/aop/branches/arrays/aop/build-tests-jdk50.xml
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java
Removed:
   projects/aop/branches/arrays/aop/.classpath
   projects/aop/branches/arrays/aop/build-tests-jdk50.xml
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java
Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/Domain.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/ContainerCache.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/GeneratedAOPProxyFactory.java
Log:
made a copy

Copied: projects/aop/branches/arrays (from rev 59138, projects/aop/trunk)

Deleted: projects/aop/branches/arrays/aop/.classpath
===================================================================
--- projects/aop/trunk/aop/.classpath	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/.classpath	2006-12-21 11:41:51 UTC (rev 59187)
@@ -1,23 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
-	<classpathentry excluding="org/jboss/aop/AnnotationIntroductionDef.java|org/jboss/aop/Aspect.java|org/jboss/aop/Bind.java|org/jboss/aop/CFlowDef.java|org/jboss/aop/CFlowStackDef.java|org/jboss/aop/DeclareError.java|org/jboss/aop/DeclareWarning.java|org/jboss/aop/DynamicCFlowDef.java|org/jboss/aop/InterceptorDef.java|org/jboss/aop/Introduction.java|org/jboss/aop/Mixin.java|org/jboss/aop/PointcutDef.java|org/jboss/aop/Precedence.java|org/jboss/aop/PrecedenceAdvice.java|org/jboss/aop/PrecedenceInterceptor.java|org/jboss/aop/Prepare.java|org/jboss/aop/TypeDef.java|org/jboss/aop/advice/Scope.java|org/jboss/aop/annotation/AnnotationElement.java|org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java|org/jboss/aspects/Threadbased.java" kind="src" path="src/main"/>
-	<classpathentry kind="src" path="src/jdk15"/>
-	<classpathentry kind="src" path="src/test"/>
-	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
-	<classpathentry kind="lib" path="/tools/lib/ant.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/qdox/lib/qdox.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
-	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
-	<classpathentry kind="lib" path="docs"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
-	<classpathentry sourcepath="/javassist" kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
-	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
-	<classpathentry kind="output" path="output/eclipse-classes"/>
-</classpath>

Copied: projects/aop/branches/arrays/aop/.classpath (from rev 59144, projects/aop/trunk/aop/.classpath)
===================================================================
--- projects/aop/trunk/aop/.classpath	2006-12-19 13:42:42 UTC (rev 59144)
+++ projects/aop/branches/arrays/aop/.classpath	2006-12-21 11:41:51 UTC (rev 59187)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+	<classpathentry excluding="org/jboss/aop/hook/JRockitClassPreProcessor.java|org/jboss/aop/hook/JRockitPluggableClassPreProcessor.java" kind="src" path="src/main"/>
+	<classpathentry kind="src" path="src/test"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/javassist"/>
+	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/dom4j/lib/dom4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
+	<classpathentry kind="lib" path="/tools/lib/ant.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/qdox/lib/qdox.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
+	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
+	<classpathentry kind="lib" path="docs"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar" sourcepath="/javassist"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-container.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
+	<classpathentry kind="output" path="output/eclipse-classes"/>
+</classpath>

Deleted: projects/aop/branches/arrays/aop/build-tests-jdk50.xml
===================================================================
--- projects/aop/trunk/aop/build-tests-jdk50.xml	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/build-tests-jdk50.xml	2006-12-21 11:41:51 UTC (rev 59187)
@@ -1,1310 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE project [
-   <!ENTITY buildmagic SYSTEM "../tools/etc/buildmagic/buildmagic.ent">
-   <!ENTITY libraries SYSTEM "../thirdparty/libraries.ent">
-   <!ENTITY modules SYSTEM "../tools/etc/buildmagic/modules.ent">
-]>
-
-<!-- ====================================================================== -->
-<!--                                                                        -->
-<!--  JBoss, the OpenSource J2EE webOS                                      -->
-<!--                                                                        -->
-<!--  Distributable under LGPL license.                                     -->
-<!--  See terms of license at http://www.gnu.org.                           -->
-<!--                                                                        -->
-<!-- ====================================================================== -->
-
-<!-- $Id$ -->
-
-<project default="main" name="JBoss/AOP">
-
-   <!-- ================================================================== -->
-   <!-- Setup                                                              -->
-   <!-- ================================================================== -->
-
-   <!--
-      | Include the common Buildmagic elements.
-      |
-      | This defines several different targets, properties and paths.
-      | It also sets up the basic extention tasks amoung other things.
-    -->
-
-   &buildmagic;
-
-   <import file="base-tests.xml"/>
-
-   <!-- ================================================================== -->
-   <!-- Initialization                                                     -->
-   <!-- ================================================================== -->
-
-   <!--
-      | Initialize the build system.  Must depend on '_buildmagic:init'.
-      | Other targets should depend on 'init' or things will mysteriously fail.
-    -->
-
-   <target name="init" unless="init.disable" depends="_buildmagic:init">
-   </target>
-
-
-   <!-- ================================================================== -->
-   <!-- Configuration                                                      -->
-   <!-- ================================================================== -->
-
-   <!--
-      | Configure the build system.
-      |
-      | This target is invoked by the Buildmagic initialization logic and
-      | should contain module specific configuration elements.
-    -->
-
-   <target name="configure" unless="configure.disable">
-      <property name="aop.version" value="jboss-aop-1.5.0.GA"/>
-      <property name="aop.title" value="JBoss AOP Framework"/>
-
-      <!-- =================== -->
-      <!-- Basic Configuration -->
-      <!-- =================== -->
-
-      <!-- Module name(s) & version -->
-      <property name="module.name" value="aop"/>
-      <property name="module.Name" value="JBoss AOP"/>
-      <property name="module.version" value="1.5.0.GA"/>
-
-      <!-- ========= -->
-      <!-- Libraries -->
-      <!-- ========= -->
-
-      &libraries;
-      &modules;
-      <!-- The combined library classpath -->
-      <path id="library.classpath">
-         <path refid="apache.ant.classpath"/>
-         <path refid="apache.log4j.classpath"/>
-         <path refid="javassist.classpath"/>
-         <path refid="jboss.profiler.jvmti.classpath"/>
-         <path refid="jboss/common.core.classpath"/>
-         <path refid="jboss/common.logging.log4j.classpath"/>
-         <path refid="jboss/common.logging.jdk.classpath"/>
-         <path refid="jboss/common.logging.spi.classpath"/>
-         <!--<path refid="jboss.microcontainer.classpath"/>-->
-         <path refid="jboss.test.classpath"/>
-          <path refid="junit.junit.classpath"/>
-         <path refid="oswego.concurrent.classpath"/>
-         <path refid="qdox.classpath"/>
-         <path refid="trove.classpath"/>
-         <path refid="xdoclet.xdoclet.classpath"/>
-      </path>
-
-      <!-- Defines jrockit.home -->
-      <property file="local.properties"/>
-
-      <available file="${jrockit.home}/jre/lib/managementapi.jar" property="JROCKIT_AVAILABLE"/>
-
-      <!-- ======= -->
-      <!-- Modules -->
-      <!-- ======= -->
-
-      <!-- The combined dependent module classpath -->
-      <path id="dependentmodule.classpath">
-      </path>
-
-      <!-- ===== -->
-      <!-- Tasks -->
-      <!-- ===== -->
-
-      <!-- Where source files live -->
-      <property name="source.tests.java" value="${module.source}/test"/>
-      <property name="source.etc" value="${module.source}/etc"/>
-      <property name="source.res" value="${module.source}/resources"/>
-      <property name="source.stylesheets" value="src/stylesheets"/>
-
-      <!-- Where build generated files will go -->
-      <property name="build.reports" value="output/reports"/>
-      <property name="build.stylesheets" value="${module.output}/stylesheets"/>
-      <property name="build.tests.classes" value="${module.output}/tests.classes"/>
-      <property name="build.lib" value="${module.output}/lib"/>
-
-      <!-- Install/Release structure -->
-      <property name="install.id" value="${module.name}-${module.version}"/>
-      <property name="release.id" value="${install.id}"/>
-      <property name="install.root" value="${module.output}/${install.id}"/>
-
-      <!-- The combined thirdparty classpath -->
-      <path id="thirdparty.classpath">
-         <path refid="library.classpath"/>
-         <path refid="dependentmodule.classpath"/>
-      </path>
-
-      <!-- classpath and local.classpath must have a value using with a path -->
-      <property name="classpath" value=""/>
-      <property name="local.classpath" value=""/>
-
-      <!-- The classpath required to build classes. -->
-      <path id="javac.classpath">
-         <pathelement path="${classpath}"/>
-         <pathelement path="${local.classpath}"/>
-         <path refid="thirdparty.classpath"/>
-         <pathelement path="${build.lib}/jboss-aop-jdk50.jar"/>
-      </path>
-
-      <path id="javac.jrockit.classpath">
-         <path refid="javac.classpath"/>
-         <path path="${jrockit.home}/jre/lib/managementapi.jar"/>
-      </path>
-
-      <path id="test.classpath">
-         <path refid="thirdparty.classpath"/>
-         <pathelement path="${build.lib}/jboss-aop-jdk50.jar"/>
-      </path>
-
-      <path id="test.jrockit.classpath">
-         <path refid="test.classpath"/>
-         <path path="${jrockit.home}/jre/lib/managementapi.jar"/>
-      </path>
-
-      <!-- The classpath required to build javadocs. -->
-      <path id="javadoc.classpath">
-         <path refid="javac.classpath"/>
-      </path>
-
-      <!-- Packages to include when generating api documentation -->
-      <property name="javadoc.packages" value="org.jbos.aop.*"/>
-
-      <!-- Override JUnit defaults -->
-      <property name="junit.timeout" value="240000"/> <!-- 4 minutes -->
-      <property name="junit.batchtest.todir" value="${build.reports}"/>
-      <property name="junit.jvm.options" value="-Ddummy"/>
-   </target>
-
-
-   <!-- ================================================================== -->
-   <!-- Compile                                                            -->
-   <!-- ================================================================== -->
-
-   <!--
-      | Compile everything.
-      |
-      | This target should depend on other compile-* targets for each
-      | different type of compile that needs to be performed, short of
-      | documentation compiles.
-    -->
-
-   <target name="compile"
-      description="Compile all source files."
-      depends="compile-test-classes"/>
-
-   <!-- Compile all class files -->
-   <target name="compile-test-classes" depends="init">
-      <mkdir dir="${build.tests.classes}"/>
-      <javac destdir="${build.tests.classes}"
-         optimize="${javac.optimize}"
-         target="1.5"
-         source="1.5"
-         debug="${javac.debug}"
-         depend="${javac.depend}"
-         verbose="${javac.verbose}"
-         deprecation="${javac.deprecation}"
-         includeAntRuntime="${javac.include.ant.runtime}"
-         includeJavaRuntime="${javac.include.java.runtime}"
-         failonerror="${javac.fail.onerror}">
-         <src path="${source.tests.java}"/>
-         <classpath refid="test.classpath"/>
-         <include name="**/*.java"/>
-         <exclude name="org/jboss/test/aop/memoryleaks/**/*.java"/>
-         <exclude name="**/methodhashing/*"/>
-      </javac>
-   </target>
-
-   <!-- ================================================================== -->
-   <!-- Cleaning                                                           -->
-   <!-- ================================================================== -->
-
-   <!-- Clean up all build output -->
-   <target name="clean"
-      description="Cleans up most generated files."
-      depends="init">
-      <delete dir="${build.tests.classes}"/>
-   </target>
-
-   <target name="clean-tests" depends="init">
-      <delete dir="${build.tests.classes}"/>
-   </target>
-
-   <!-- Clean up all generated files -->
-   <target name="clobber"
-      description="Cleans up all generated files."
-      depends="_buildmagic:clobber, clean">
-   </target>
-
-
-   <!-- ===============================================================p=== -->
-   <!-- Misc.                                                              -->
-   <!-- ================================================================== -->
-
-   <target name="main" depends="most"
-      description="Executes the default target (most)."/>
-
-   <target name="all" depends="compile"
-      description="Builds everything."/>
-
-   <target name="most" depends="compile"
-      description="Builds almost everything."/>
-
-   <target name="help"
-      description="Show this help message."
-      depends="_buildmagic:help:standard"/>
-
-   <!-- ==================================================================================== -->
-   <!-- JDK 5.0 TESTS                                                                        -->
-   <!-- ==================================================================================== -->
-
-   <target name="tests" depends="main">
-
-      <delete dir="${build.tests.classes}"/>
-      <antcall target="javaagent-genadvisor-tests" inheritRefs="true"/>
-      <antcall target="javaagent-tests" inheritRefs="true"/>
-
-      <antcall target="system-classloader-test" inheritRefs="true"/>
-      <antcall target="not-woven-tests" inheritRefs="true"/>
-
-      <antcall target="precompiled-tests" inheritRefs="true"/>
-
-      <delete dir="${build.tests.classes}"/>
-      <antcall target="precompiled-genadvisor-tests" inheritRefs="true"/>
-
-      <delete dir="${build.tests.classes}"/>
-      <antcall target="non-optimized-precompiled-tests" inheritRefs="true"/>
-   </target>
-
-   <target name="all-tests" depends="tests">
-		<!-- Should move the remaining tests into something similar to _base-tests.xml and run them from the main targets once JBAOP-268 has been done -->
-      <delete dir="${build.tests.classes}/org/jboss/test"/>
-      <antcall target="jdk15-loadtime-tests" inheritRefs="true"/>
-
-      <delete dir="${build.tests.classes}/org/jboss/test"/>
-      <antcall target="jdk15-precompiled-tests" inheritRefs="true"/>
-
-      <delete dir="${build.tests.classes}"/>
-      <antcall target="jrockit-tests" inheritRefs="true"/>
-      <antcall target="jrockit-genadvisor-tests" inheritRefs="true"/>
-   </target>
-
-   <target name="_base-jdk50-tests">
-      <antcall target="${test-target}" inheritRefs="true">
-         <param name="test" value="bridgemethod"/>
-         <param name="caller" value="${caller}"/>
-         <param name="exclude" value="**/notwoven/BridgeMethodTestCase.class"/>
-      </antcall>
-      <antcall target="_base-tests" inheritRefs="true">
-         <param name="caller" value="${caller}"/>
-         <param name="test-target" value="${test-target}"/>
-      </antcall>
-   </target>
-
-
-   <!-- ==================================================================================== -->
-   <!-- JAVAAGENT TESTS (JDK 5.0)                                                        -->
-   <!-- ==================================================================================== -->
-   <target name="javaagent-tests" depends="compile-test-classes">
-      <!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-javaagent-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="javaagent-tests"/>
-         <param name="exclude" value="**/GenAdvisorOverrideTestCase.class"/>
-      </antcall>
-
-   	<!-- Add tests in _base-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="javaagent-tests"/>
-         <param name="test-target" value="_run-javaagent-test"/>
-      </antcall>
-   </target>
-
-   <target name="loadtime-test" depends="init">
-      <antcall  target="_run-javaagent-test" inheritRefs="true">
-         <param name="test" value="${test}"/>
-         <param name="caller" value="javaagent-tests"/>
-      </antcall>
-   </target>
-
-
-   <!-- ==================================================================================== -->
-   <!-- GENERATED ADVISOR JAVAGENT TESTS (JDK 5.0)                                           -->
-   <!-- ==================================================================================== -->
-   <target name="javaagent-genadvisor-tests" depends="compile-test-classes">
-      <!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-javaagent-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="javaagent-genadvisor-tests"/>
-         <param name="exclude" value="**/OverrideTestCase.class"/>
-      </antcall>
-      <antcall target="_run-javaagent-test" inheritRefs="true">
-         <param name="test" value="nameddomain"/>
-         <param name="caller" value="javaagent-genadvisor-tests"/>
-      </antcall>
-
-	   <!-- Add tests in _base-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="javaagent-genadvisor-tests"/>
-         <param name="test-target" value="_run-javaagent-test"/>
-      </antcall>
-   </target>
-
-   <target name="loadtime-ga-test" depends="init">
-      <antcall  target="_run-javaagent-test" inheritRefs="true">
-         <param name="test" value="${test}"/>
-         <param name="caller" value="javaagent-genadvisor-tests"/>
-      </antcall>
-   </target>
-
-   <!-- ==================================================================================== -->
-   <!-- JDK 5.0 JAVAAGENT TEST COMMONS                                                   -->
-   <!-- These targets should not be called directly, use bootclasspath-tests or              -->
-   <!-- bootclasspath-genadvisor-tests                                                       -->
-   <!-- ==================================================================================== -->
-
-   <target name="_run-javaagent-test">
-
-      <!-- Check for jboss-aop.xml override -->
-	   <condition property="jboss.aop.path" value="${aop.xml}">
-	      <isset property="aop.xml"/>
-	   </condition>
-	   <condition property="jboss.aop.path" value="">
-	      <isset property="no.xml"/>
-	   </condition>
-	   <condition property="jboss.aop.path" value="${source.res}/test/${test}/jboss-aop.xml">
-	      <not>
-	         <isset property="aop.xml"/>
-	      </not>
-	   </condition>
-
-      <!-- Get -Djboss.aop.class.path from passed in parameters -->
-      <condition property="jboss.aop.class.path" value="${build.tests.classes}">
-         <isset property="use.annotations"/>
-      </condition>
-      <condition property="jboss.aop.class.path" value="">
-         <not>
-            <isset property="use.annotations"/>
-         </not>
-      </condition>
-
-   	<!-- Set the weaving mode and instrumentor to use-->
-      <condition property="instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor">
-         <equals arg1="${caller}" arg2="javaagent-tests"/>
-      </condition>
-      <condition property="instrumentor" value="org.jboss.aop.instrument.GeneratedAdvisorInstrumentor">
-         <equals arg1="${caller}" arg2="javaagent-genadvisor-tests"/>
-      </condition>
-
-      <echo>Running ${test} with instrumentor ${instrumentor}</echo>
-
-      <mkdir dir="${build.reports}"/>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <sysproperty key="jboss.aop.path" value="${jboss.aop.path}"/>
-         <sysproperty key="jboss.aop.class.path" value="${jboss.aop.class.path}"/>
-         <sysproperty key="jboss.aop.instrumentor" value="${instrumentor}"/>
-         <sysproperty key="jboss.aop.debug.classes" value="true"/>
-         <sysproperty key="jboss-junit-configuration" value="${caller}"/>
-      	<formatter type="plain" extension="-${caller}.txt"/>
-      	<classpath refid="test.classpath"/>
-         <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter" extension="-${caller}.xml"/>
-         <classpath>
-            <pathelement location="${build.tests.classes}"/>
-         </classpath>
-         <batchtest todir="${build.reports}"
-            haltonfailure="false"
-            fork="true">
-            <fileset dir="${build.tests.classes}">
-               <include name="org/jboss/test/aop/${test}/**/*TestCase.class"/>
-               <include name="org/jboss/test/aop/${test}/**/*Tester.class"/>
-               <exclude name="${exclude}"/>
-
-               <!-- These are not test cases, and so they will fail when junit tries to run them. Should really rename all tests to *TestCase -->
-               <exclude name="org/jboss/test/aop/reflection/ReflectionAspectTester.class"/>
-               <exclude name="org/jboss/test/aop/basic/POJOAspectTester.class"/>
-            </fileset>
-         </batchtest>
-      </junit>
-   </target>
-
-   <!-- ==================================================================================== -->
-   <!-- OPTIMIZED PRECOMPILED TESTS (JDK 5.0)                                                -->
-   <!-- ==================================================================================== -->
-
-   <target name="precompiled-tests" depends="compile-test-classes">
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <path id="aop.task.classpath">
-         <path refid="library.classpath"/>
-         <path refid="dependentmodule.classpath"/>
-         <path refid="jboss.aop.classpath"/>
-      </path>
-
-      <!-- Add tests in _base-precompiled-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="precompiled-tests"/>
-         <param name="test-target" value="_run-precompiled-test"/>
-      </antcall>
-
-   	<!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="args"/>
-         <param name="caller" value="precompiled-tests"/>
-      </antcall>
-	   <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="precompiled-tests"/>
-         <param name="exclude" value="**/GenAdvisorOverrideTestCase.class"/>
-      </antcall>
-   </target>
-
-   <!-- ==================================================================================== -->
-   <!-- NON OPTIMIZED PRECOMPILED TESTS (JDK 5.0)                                            -->
-   <!-- ==================================================================================== -->
-
-   <target name="non-optimized-precompiled-tests" depends="compile-test-classes">
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <path id="aop.task.classpath">
-         <path refid="library.classpath"/>
-         <path refid="dependentmodule.classpath"/>
-         <path refid="jboss.aop.classpath"/>
-      </path>
-
-      <!-- Add tests in _base-precompiled-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="non-optimized-precompiled-tests"/>
-         <param name="test-target" value="_run-precompiled-test"/>
-      </antcall>
-
-      <!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="non-optimized-precompiled-tests"/>
-         <param name="exclude" value="**/GenAdvisorOverrideTestCase.class"/>
-      </antcall>
-   </target>
-
-   <!-- ==================================================================================== -->
-   <!-- JDK 5.0 GENERATED ADVISOR PRECOMPILED TESTS                                          -->
-   <!-- ==================================================================================== -->
-
-   <target name="precompiled-genadvisor-tests" depends="compile-test-classes">
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <path id="aop.task.classpath">
-         <path refid="library.classpath"/>
-         <path refid="dependentmodule.classpath"/>
-         <path refid="jboss.aop.classpath"/>
-      </path>
-
-      <!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="args"/>
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-      </antcall>
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="beforeafter"/>
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-      </antcall>
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="beforeafterArgs"/>
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-      </antcall>
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="dynamicgenadvisor"/>
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-      </antcall>
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-         <param name="exclude" value="**/OverrideTestCase.class"/>
-      </antcall>
-      <antcall target="_run-javaagent-test" inheritRefs="true">
-         <param name="test" value="nameddomain"/>
-         <param name="caller" value="javaagent-genadvisor-tests"/>
-      </antcall>
-
-      <!-- Add tests in _base-precompiled-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-         <param name="test-target" value="_run-precompiled-test"/>
-      </antcall>
-   </target>
-
-   <target name="precompiled-test" depends="init">
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <antcall  target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="${test}"/>
-         <param name="caller" value="precompiled-tests"/>
-      </antcall>
-   </target>
-
-   <target name="precompiled-genadvisor-test" depends="init">
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <antcall target="_run-precompiled-test" inheritRefs="true">
-         <param name="test" value="args"/>
-         <param name="caller" value="precompiled-genadvisor-tests"/>
-      </antcall>
-	</target>
-
-   <target name="_run-precompiled-test">
-
-      <!-- Check for jboss-aop.xml override for compiler -->
-      <condition property="aoppath" value="${aop.xml}">
-         <isset property="aop.xml"/>
-      </condition>
-      <condition property="aoppath" value="">
-         <isset property="no.xml"/>
-      </condition>
-      <condition property="aoppath" value="${source.res}/test/${test}/jboss-aop.xml">
-         <not>
-            <isset property="aop.xml"/>
-         </not>
-      </condition>
-
-      <!-- Set the weaving mode and instrumentor to use-->
-      <condition property="optimized" value="true">
-         <or>
-            <equals arg1="${caller}" arg2="precompiled-tests"/>
-            <equals arg1="${caller}" arg2="precompiled-genadvisor-tests"/>
-         </or>
-      </condition>
-      <condition property="optimized" value="false">
-         <equals arg1="${caller}" arg2="non-optimized-precompiled-tests"/>
-      </condition>
-      <condition property="instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor">
-         <not>
-            <equals arg1="${caller}" arg2="precompiled-genadvisor-tests"/>
-         </not>
-      </condition>
-      <condition property="instrumentor" value="org.jboss.aop.instrument.GeneratedAdvisorInstrumentor">
-         <equals arg1="${caller}" arg2="precompiled-genadvisor-tests"/>
-      </condition>
-
-      <echo>Compiling ${test} with optimized=${optimized} and instrumentor ${instrumentor}</echo>
-
-      <!-- aopc -->
-      <aopc optimized="${optimized}" compilerclasspathref="aop.task.classpath">
-         <classpath refid="aop.task.classpath"/>
-         <classpath refid="test.classpath"/>
-         <classpath path="${build.tests.classes}"/>
-         <aoppath path="${aoppath}"/>
-         <sysproperty key="jboss.aop.instrumentor" value="${instrumentor}"/>
-         <src path="${build.tests.classes}"/>
-         <include name="org/jboss/test/aop/${test}/**"/>
-         <exclude name="${exclude}"/>
-         <aopclasspath path="${build.tests.classes}"/>
-      </aopc>
-
-      <!-- Get -Djboss.aop.path from passed in parameters -->
-      <condition property="jboss.aop.path" value="${aop.xml}">
-         <isset property="aop.xml"/>
-      </condition>
-      <condition property="jboss.aop.path" value="">
-         <isset property="no.xml"/>
-      </condition>
-      <condition property="jboss.aop.path" value="${source.res}/test/${test}/jboss-aop.xml">
-         <not>
-            <isset property="aop.xml"/>
-         </not>
-      </condition>
-
-      <!-- Get -Djboss.aop.class.path from passed in parameters -->
-      <condition property="jboss.aop.class.path" value="${build.tests.classes}">
-         <isset property="use.annotations"/>
-      </condition>
-      <condition property="jboss.aop.class.path" value="">
-         <not>
-            <isset property="use.annotations"/>
-         </not>
-      </condition>
-
-      <!-- determine output directory from weaving mode -->
-      <mkdir dir="${build.reports}"/>
-
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${jboss.aop.path}"/>
-         <sysproperty key="jboss.aop.class.path" value="${jboss.aop.class.path}"/>
-         <sysproperty key="jboss-junit-configuration" value="${caller}"/>
-         <formatter type="plain" extension="-${caller}-jdk50.txt"/>
-         <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter" extension="-${caller}-jdk50.xml"/>
-         <classpath>
-            <path refid="test.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <batchtest todir="${build.reports}"
-            haltonerror="false"
-            haltonfailure="false"
-            fork="true">
-            <fileset dir="${build.tests.classes}">
-               <include name="org/jboss/test/aop/${test}/**/*TestCase.class"/>
-               <include name="org/jboss/test/aop/${test}/**/*Tester.class"/>
-               <exclude name="${exclude}"/>
-
-               <!-- These are not test cases, and so they will fail when junit tries to run them. Should really rename all tests to *TestCase -->
-               <exclude name="org/jboss/test/aop/reflection/ReflectionAspectTester.class"/>
-               <exclude name="org/jboss/test/aop/basic/POJOAspectTester.class"/>
-            </fileset>
-         </batchtest>
-      </junit>
-   </target>
-
-
-   <!-- ==================================================================================== -->
-   <!-- NON-WOVEN TESTS                                                                      -->
-   <!-- ==================================================================================== -->
-
-   <target name="not-woven-tests" depends="compile-test-classes">
-      <mkdir dir="${build.reports}"/>
-
-      <taskdef name="annotationc" classname="org.jboss.aop.ant.AnnotationC" classpathref="jboss.aop.classpath"/>
-      <path id="aop.task.classpath">
-         <path refid="test.classpath"/>
-      </path>
-      <annotationc compilerclasspathref="aop.task.classpath" bytecode="true">
-         <classpath refid="aop.task.classpath"/>
-         <classpath path="${build.tests.classes}"/>
-         <src path="${source.tests.java}/org/jboss/test/aop/annotationc"/>
-      </annotationc>
-
-      <echo>org/jboss/test/aop/methodhashing/MethodHashingTestCase will fail until the microcontainer has been updated in the repository</echo>
-
-      <junit printsummary="yes" fork="no" haltonfailure="no" >
-         <sysproperty key="jboss.aop.debug.classes" value="false"/>
-         <classpath>
-            <path refid="javac.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <sysproperty key="jboss-junit-configuration" value="jdk50"/>
-         <formatter type="plain" extension="-jdk50.txt"/>
-         <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter" extension="-jdk50.xml"/>
-
-		   <batchtest todir="${build.reports}"
-		      haltonerror="false"
-		      haltonfailure="false"
-		      fork="true">
-		      <fileset dir="${build.tests.classes}">
-		         <include name="org/jboss/test/aop/proxy/ProxyTestCase.class"/>
-      		   <include name="org/jboss/test/aop/methodhashing/MethodHashingTestCase.class"/>
-      		   <include name="org/jboss/test/aop/annotationc/AnnotationTester.class"/>
-      		   <include name="org/jboss/test/aop/bridgemethodnotwoven/BridgeMethodTestCase.class"/>
-		      </fileset>
-		   </batchtest>
-
-      </junit>
-   </target>
-
-   <!-- ==================================================================================== -->
-   <!-- JDK 5 TESTS                                                                          -->
-   <!-- ==================================================================================== -->
-
-   <target name="jdk15-loadtime-tests" depends="compile">
-
-      <property name="report.dir" value="${build.reports}"/>
-      <mkdir dir="${report.dir}"/>
-
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareAll/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="java5Agent" value="true"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-loadtime-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-loadtime-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareAll.HotSwapDisabledTester" />
-      </junit>
-
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareConstructor/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="java5Agent" value="true"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-loadtime-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-loadtime-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareConstructor.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareMethod/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="java5Agent" value="true"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-loadtime-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-loadtime-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareMethod.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareField/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="java5Agent" value="true"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-loadtime-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-loadtime-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareField.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareFieldGet/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="java5Agent" value="true"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-loadtime-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-loadtime-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareFieldGet.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareFieldSet/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="java5Agent" value="true"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-loadtime-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-loadtime-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareFieldSet.HotSwapDisabledTester" />
-      </junit>
-
-   </target>
-
-   <target name="jdk15-precompiled-tests" depends="compile">
-
-      <property name="report.dir" value="${build.reports}"/>
-      <mkdir dir="${report.dir}"/>
-
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <path id="aop.task.classpath">
-         <path refid="test15.classpath"/>
-         <pathelement location="${build.tests.classes}"/>
-         <pathelement location="docs"/>
-      </path>
-
-      <aopc compilerclasspathref="aop.task.classpath">
-         <classpath refid="aop.task.classpath"/>
-         <classpath path="${build.tests.classes}"/>
-         <src path="${build.tests.classes}"/>
-         <include name="org/jboss/test/aop/jdk15/**"/>
-         <exclude name="org/jboss/test/aop/jdk15/dynamic/**"/>
-         <aoppath path="${source.res}/test/jdk15/jboss-aop.xml"/>
-         <aopclasspath path="${build.tests.classes}"/>
-      </aopc>
-
-      <aopc compilerclasspathref="aop.task.classpath">
-         <classpath refid="aop.task.classpath"/>
-         <classpath path="${build.tests.classes}"/>
-         <src path="${build.tests.classes}"/>
-         <include name="org/jboss/test/aop/basic/**"/>
-         <aoppath path="${source.res}/test/basic/jboss-aop.xml"/>
-      </aopc>
-      <mkdir dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-        <!-- process jdk15/dynamic/common/scenario with prepareAll jboss-aop.xml file -->
-      <unjar src="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"
-             dest="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-        <aopc verbose="false" compilerclasspathref="aop.task.classpath">
-        <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-        <classpath path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <src path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <aoppath path="${source.res}/test/jdk15/dynamic/prepareAll/jboss-aop.xml"/>
-      </aopc>
-      <jar destfile="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareAll.jar"
-           basedir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-      <delete includeemptydirs="true">
-         <fileset dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario" includes="**/*"/>
-        </delete>
-     <!-- process jdk15/dynamic/common/scenario with prepareConstructor jboss-aop.xml file -->
-      <unjar src="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"
-             dest="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-     <aopc verbose="false" compilerclasspathref="aop.task.classpath">
-        <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-        <classpath path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <src path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <aoppath path="${source.res}/test/jdk15/dynamic/prepareConstructor/jboss-aop.xml"/>
-      </aopc>
-      <jar destfile="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareConstructor.jar"
-           basedir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-      <delete includeemptydirs="true">
-         <fileset dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario" includes="**/*"/>
-        </delete>
-     <!-- process jdk15/dynamic/common/scenario with prepareField jboss-aop.xml file -->
-      <unjar src="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"
-             dest="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-     <aopc verbose="false" compilerclasspathref="aop.task.classpath">
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <classpath path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <src path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <aoppath path="${source.res}/test/jdk15/dynamic/prepareField/jboss-aop.xml"/>
-      </aopc>
-      <jar destfile="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareField.jar"
-           basedir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-      <delete includeemptydirs="true">
-         <fileset dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario" includes="**/*"/>
-        </delete>
-     <!-- process jdk15/dynamic/common/scenario with prepareFieldGet jboss-aop.xml file -->
-      <unjar src="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"
-             dest="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-       <aopc verbose="false" compilerclasspathref="aop.task.classpath">
-        <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-        <classpath path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-        <src path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <aoppath path="${source.res}/test/jdk15/dynamic/prepareFieldGet/jboss-aop.xml"/>
-      </aopc>
-      <jar destfile="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareFieldGet.jar"
-           basedir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-      <delete includeemptydirs="true">
-         <fileset dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario" includes="**/*"/>
-     </delete>
-     <!-- process jdk15/dynamic/common/scenario with prepareFieldSet jboss-aop.xml file -->
-      <unjar src="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"
-             dest="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-     <aopc verbose="false" compilerclasspathref="aop.task.classpath">
-        <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-        <classpath path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-        <src path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <aoppath path="${source.res}/test/jdk15/dynamic/prepareFieldSet/jboss-aop.xml"/>
-      </aopc>
-      <jar destfile="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareFieldSet.jar"
-           basedir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-      <delete includeemptydirs="true">
-         <fileset dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario" includes="**/*"/>
-     </delete>
-     <!-- process jdk15/dynamic/common/scenario with prepareMethod jboss-aop.xml file -->
-      <unjar src="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"
-             dest="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-      <aopc verbose="false" compilerclasspathref="aop.task.classpath">
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <classpath path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <src path="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-         <aoppath path="${source.res}/test/jdk15/dynamic/prepareMethod/jboss-aop.xml"/>
-      </aopc>
-      <jar destfile="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareMethod.jar"
-           basedir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario/"/>
-      <delete dir="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario"/>
-
-        <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/jboss-aop.xml"/>
-         <sysproperty key="jboss.aop.class.path" value="${build.tests.classes}"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.AOPTester"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.annotated.AnnotatedTestCase"/>
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/basic/jboss-aop.xml"/>
-         <sysproperty key="jboss.aop.class.path" value="${build.tests.classes}"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.basic.AOPTester"/>
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareAll/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar"
-            value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareAll.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareAll.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareConstructor/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar"
-            value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareConstructor.jar"/>
-           <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareConstructor.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareField/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar"
-             value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareField.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareField.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareFieldGet/jboss-aop.xml"/>
-        <sysproperty key="scenario.jar"
-            value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareFieldGet.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareFieldGet.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareFieldSet/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar"
-            value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareFieldSet.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareFieldSet.HotSwapDisabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareMethod/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar"
-            value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenarioAopcPrepareMethod.jar"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain" extension="-jdk15-precompiled-tests.txt"/>
-         <formatter usefile="true" type="xml" extension="-jdk15-precompiled-tests.xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareMethod.HotSwapDisabledTester" />
-      </junit>
-   </target>
-   <target name="jdk15-hotswap-tests" depends="compile">
-
-      <property name="report.dir" value="${build.reports}/jdk15-hotswap-tests"/>
-      <mkdir dir="${report.dir}"/>
-
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareAll/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <!-- don't prune it so that we can inspect the bytecodes state during tests execution -->
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar=-hotSwap"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain"/>
-         <formatter usefile="true" type="xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareAll.HotSwapEnabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareConstructor/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar=-hotSwap"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain"/>
-         <formatter usefile="true" type="xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareConstructor.HotSwapEnabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareMethod/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar=-hotSwap"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain"/>
-         <formatter usefile="true" type="xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareMethod.HotSwapEnabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareField/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar=-hotSwap"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain"/>
-         <formatter usefile="true" type="xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareField.HotSwapEnabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareFieldGet/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar=-hotSwap"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain"/>
-         <formatter usefile="true" type="xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareFieldGet.HotSwapEnabledTester" />
-      </junit>
-      <junit printsummary="yes" fork="yes" haltonfailure="no">
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/jdk15/dynamic/prepareFieldSet/jboss-aop.xml"/>
-         <sysproperty key="scenario.jar" value="${build.tests.classes}/org/jboss/test/aop/jdk15/dynamic/common/scenario.jar"/>
-         <sysproperty key="jboss.aop.prune" value="false"/>
-         <jvmarg value="-javaagent:${build.lib}/jboss-aop-jdk50.jar=-hotSwap"/>
-         <classpath>
-            <path refid="test15.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter usefile="true" type="plain"/>
-         <formatter usefile="true" type="xml"/>
-         <test todir="${report.dir}" name="org.jboss.test.aop.jdk15.dynamic.prepareFieldSet.HotSwapEnabledTester" />
-      </junit>
-   </target>
-
-
-   <!-- ==================================================================================== -->
-   <!-- JROCKIT TESTS (JDK 5.0)                                                        -->
-   <!-- ==================================================================================== -->
-   <target name="jrockit-tests" depends="compile-test-classes" if="JROCKIT_AVAILABLE">
-
-   	<!-- Add tests in _base-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="jrockit-tests"/>
-         <param name="test-target" value="_run-jrockit-test"/>
-      </antcall>
-
-      <!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-jrockit-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="jrockit-tests"/>
-         <param name="exclude" value="**/GenAdvisorOverrideTestCase.class"/>
-      </antcall>
-
-   </target>
-
-   <!-- ==================================================================================== -->
-   <!-- GENERATED ADVISOR JROCKIT TESTS (JDK 5.0)                                           -->
-   <!-- ==================================================================================== -->
-   <target name="jrockit-genadvisor-tests" depends="compile-test-classes" if="JROCKIT_AVAILABLE">
-
-	   <!-- Add tests in _base-tests unless they should only be run in this weaving mode -->
-      <antcall target="_base-jdk50-tests" inheritRefs="true">
-         <param name="caller" value="jrockit-genadvisor-tests"/>
-         <param name="test-target" value="_run-jrockit-test"/>
-      </antcall>
-
-      <!-- Tests only applicable for this weaving mode -->
-      <antcall target="_run-jrockit-test" inheritRefs="true">
-         <param name="test" value="override"/>
-         <param name="caller" value="jrockit-genadvisor-tests"/>
-         <param name="exclude" value="**/OverrideTestCase.class"/>
-      </antcall>
-   </target>
-
-
-   <target name="_run-jrockit-test">
-
-      <!-- Check for jboss-aop.xml override -->
-	   <condition property="jboss.aop.path" value="${aop.xml}">
-	      <isset property="aop.xml"/>
-	   </condition>
-	   <condition property="jboss.aop.path" value="">
-	      <isset property="no.xml"/>
-	   </condition>
-	   <condition property="jboss.aop.path" value="${source.res}/test/${test}/jboss-aop.xml">
-	      <not>
-	         <isset property="aop.xml"/>
-	      </not>
-	   </condition>
-
-      <!-- Get -Djboss.aop.class.path from passed in parameters -->
-      <condition property="jboss.aop.class.path" value="${build.tests.classes}">
-         <isset property="use.annotations"/>
-      </condition>
-      <condition property="jboss.aop.class.path" value="">
-         <not>
-            <isset property="use.annotations"/>
-         </not>
-      </condition>
-
-   	<!-- Set the weaving mode and instrumentor to use-->
-      <condition property="instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor">
-         <equals arg1="${caller}" arg2="jrockit-tests"/>
-      </condition>
-      <condition property="instrumentor" value="org.jboss.aop.instrument.GeneratedAdvisorInstrumentor">
-         <equals arg1="${caller}" arg2="jrockit-genadvisor-tests"/>
-      </condition>
-
-      <echo>Running ${test} with instrumentor ${instrumentor}</echo>
-
-      <mkdir dir="${build.reports}"/>
-      <junit printsummary="yes" fork="yes" haltonfailure="no" jvm="${jrockit.home}/bin/java">
-         <jvmarg value="-Xmanagement:class=org.jboss.aop.hook.JRockitClassPreProcessor"/>
-         <sysproperty key="jboss-junit-configuration" value="${caller}"/>
-         <sysproperty key="jboss.aop.path" value="${jboss.aop.path}"/>
-         <sysproperty key="jboss.aop.class.path" value="${jboss.aop.class.path}"/>
-         <sysproperty key="jboss.aop.instrumentor" value="${instrumentor}"/>
-         <sysproperty key="jboss.aop.debug.classes" value="true"/>
-      	<formatter type="plain" extension="-${caller}.txt"/>
-      	<classpath refid="test.classpath"/>
-         <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter" extension="-${caller}.xml"/>
-         <classpath>
-            <path refid="test.jrockit.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-         </classpath>
-         <batchtest todir="${build.reports}"
-            haltonerror="false"
-            haltonfailure="false"
-            fork="true">
-            <fileset dir="${build.tests.classes}">
-               <include name="org/jboss/test/aop/${test}/**/*TestCase.class"/>
-               <include name="org/jboss/test/aop/${test}/**/*Tester.class"/>
-               <exclude name="${exclude}"/>
-
-               <!-- These are not test cases, and so they will fail when junit tries to run them. Should really rename all tests to *TestCase -->
-               <exclude name="org/jboss/test/aop/reflection/ReflectionAspectTester.class"/>
-               <exclude name="org/jboss/test/aop/basic/POJOAspectTester.class"/>
-            </fileset>
-         </batchtest>
-      </junit>
-   </target>
-
-
-   <target name="compiletime-declare" depends="compile-test-classes">
-      <taskdef name="aopc" classname="org.jboss.aop.ant.AopC" classpathref="jboss.aop.classpath"/>
-      <taskdef name="annotationc" classname="org.jboss.aop.ant.AnnotationC" classpathref="jboss.aop.classpath"/>
-      <path id="aop.task.classpath">
-         <path refid="library.classpath"/>
-         <path refid="dependentmodule.classpath"/>
-         <path refid="jboss.aop.classpath"/>
-      </path>
-
-      <annotationc compilerclasspathref="aop.task.classpath" bytecode="true">
-         <classpath refid="aop.task.classpath"/>
-         <classpath path="${build.tests.classes}"/>
-         <src path="${source.tests.java}"/>
-        <include name="org/jboss/test/aop/annotated/declare/*.java"/>
-      </annotationc>
-
-     <echo>
-       ===== The output of the aopc task should look as follows: ====
-         4 x This is an expected warning: Cannot call business layer from datalayer.
-         1 x This is an expected warning: CAR should be mentioned in msg
-         1 x This is an expected warning: Cannot call business layer from Car.badMethod()
-         1 x This is an expected warning: FOURWHEELER should be mentioned in msg
-         1 x This is an expected warning: TRUCK should be mentioned in msg
-         1 x Expected annotated warning
-      </echo>
-
-      <echo>
-         =======================================================
-
-         RUNNING AOPC TASK
-      </echo>
-
-      <aopc compilerclasspathref="aop.task.classpath">
-         <classpath refid="aop.task.classpath"/>
-         <classpath path="${build.tests.classes}"/>
-         <src path="${build.tests.classes}"/>
-         <include name="org/jboss/test/aop/declare/**"/>
-         <include name="org/jboss/test/aop/annotated/declare/**"/>
-         <aoppath path="${source.res}/test/declare/jboss-aop.xml"/>
-         <aopclasspath path="${build.tests.classes}"/>
-      </aopc>
-   </target>
-
-
-   <target name="system-classloader-test" depends="compile-test-classes">
-      <!-- Even though this is deprecated we should still make sure it works from time to time -->
-      <junit printsummary="yes" fork="no" haltonfailure="false">
-         <sysproperty key="java.system.class.loader" value="org.jboss.aop.standalone.SystemClassLoader"/>
-         <sysproperty key="jboss.aop.path" value="${source.res}/test/basic/jboss-aop.xml"/>
-         <sysproperty key="jboss.aop.instrumentor" value="org.jboss.aop.instrument.ClassicInstrumentor"/>
-         <sysproperty key="jboss-junit-configuration" value="-system-classloader-jdk50.xml"/>
-         <classpath>
-            <path refid="test.classpath"/>
-            <pathelement location="${build.tests.classes}"/>
-            <pathelement location="docs"/>
-         </classpath>
-         <formatter type="plain" extension="-system-classloader-jdk50.txt"/>
-         <formatter classname="org.jboss.ant.taskdefs.XMLJUnitMultipleResultFormatter" extension="-system-classloader-jdk50.xml"/>
-         <test fork="yes" name="org.jboss.test.aop.basic.AOPTester" todir="${build.reports}"/>
-      </junit>
-   </target>
-
-   <target name="compile-stylesheets" depends="configure">
-      <mkdir dir="${build.stylesheets}"/>
-      <copy todir="${build.stylesheets}" filtering="yes">
-         <fileset dir="${source.stylesheets}">
-            <include name="**/*"/>
-         </fileset>
-      </copy>
-   </target>
-
-   <target name="tests-report-html" depends="compile-stylesheets">
-      <mkdir dir="${build.reports}/html"/>
-
-      <junitreport todir="${build.reports}">
-         <fileset dir="${build.reports}">
-            <include name="TEST-*.xml"/>
-         </fileset>
-         <report format="frames"
-            todir="${build.reports}/html"
-            styledir="${build.stylesheets}"
-            />
-      </junitreport>
-   </target>
-
-</project>

Copied: projects/aop/branches/arrays/aop/build-tests-jdk50.xml (from rev 59144, projects/aop/trunk/aop/build-tests-jdk50.xml)

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -50,6 +50,7 @@
 import org.jboss.aop.advice.PrecedenceDefEntry;
 import org.jboss.aop.advice.PrecedenceSorter;
 import org.jboss.aop.advice.Scope;
+import org.jboss.aop.array.ArrayReplacement;
 import org.jboss.aop.classpool.AOPClassPoolRepository;
 import org.jboss.aop.classpool.AOPScopedClassLoaderHelper;
 import org.jboss.aop.instrument.GeneratedAdvisorInstrumentor;
@@ -116,6 +117,7 @@
    protected int subscribedDomainQueueRef;
 
    protected final LinkedHashMap interfaceIntroductions = new LinkedHashMap();
+   protected final LinkedHashMap arrayReplacements = new LinkedHashMap();
    protected final LinkedHashMap annotationIntroductions = new LinkedHashMap();
    protected final LinkedHashMap annotationOverrides = new LinkedHashMap();
    protected final LinkedHashMap bindings = new LinkedHashMap();
@@ -1508,6 +1510,41 @@
    }
 
    /**
+    * Retrieve an introduction pointcut of a certain name
+    */
+   public InterfaceIntroduction getArrayReplacement(String name)
+   {
+      synchronized (arrayReplacements)
+      {
+         return (InterfaceIntroduction) arrayReplacements.get(name);
+      }
+   }
+
+   /**
+    * Register an introduction pointcut
+    */
+   public synchronized void addArrayReplacement(ArrayReplacement pointcut)
+   {
+      removeArrayReplacement(pointcut.getName());
+      synchronized (arrayReplacements)
+      {
+         arrayReplacements.put(pointcut.getName(), pointcut);
+      }
+   }
+
+   /**
+    * remove an introduction pointcut of a certain name
+    */
+   public void removeArrayReplacement(String name)
+   {
+      synchronized (arrayReplacements)
+      {
+         ArrayReplacement pointcut = (ArrayReplacement) arrayReplacements.remove(name);
+         if (pointcut == null) return;
+      }
+   }
+
+   /**
     * Register an annotation introduction
     */
    public synchronized void addAnnotationIntroduction(AnnotationIntroduction pointcut)
@@ -1772,6 +1809,11 @@
       return interfaceIntroductions;
    }
 
+   public Map getArrayReplacements()
+   {
+      return arrayReplacements;
+   }
+
    public Map getTypedefs()
    {
       return typedefs;

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/AspectXmlLoader.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -50,6 +50,7 @@
 import org.jboss.aop.advice.ScopeUtil;
 import org.jboss.aop.advice.ScopedInterceptorFactory;
 import org.jboss.aop.advice.ThrowingFactory;
+import org.jboss.aop.array.ArrayReplacement;
 import org.jboss.aop.introduction.AnnotationIntroduction;
 import org.jboss.aop.introduction.InterfaceIntroduction;
 import org.jboss.aop.metadata.ClassMetaDataBinding;
@@ -673,6 +674,50 @@
       manager.addPointcut(p);
    }
 
+   public void undeployArrayReplacement(Element pointcut) throws Exception
+   {
+      String name = getName(pointcut, "arrayReplacement");
+      manager.removeArrayReplacement(name);
+   }
+   
+   public void deployArrayReplacement(Element pointcut) throws Exception
+   {
+      String name = getName(pointcut, "arrayReplacement");
+      String classExpr = pointcut.getAttribute("class");
+      if (classExpr != null && classExpr.trim().equals(""))
+      {
+         classExpr = null;
+      }
+
+      String ast = pointcut.getAttribute("expr");
+      if (ast != null && ast.trim().equals(""))
+      {
+         ast = null;
+      }
+
+      if (classExpr == null && ast == null)
+      {
+         throw new RuntimeException("A class nor a expr attribute is defined for this <arrayreplacement>");
+      }
+
+      if (classExpr != null && ast != null)
+      {
+         throw new RuntimeException("You cannot define both a class and expr attribute in the same <arrayreplacement>");
+      }
+
+      ArrayReplacement pcut = null;
+      if (classExpr != null)
+      {
+         pcut = new ArrayReplacement(name, classExpr);
+      }
+      else
+      {
+         ASTStart start = new TypeExpressionParser(new StringReader(ast)).Start();
+         pcut = new ArrayReplacement(name, start);
+      }
+      manager.addArrayReplacement(pcut);
+   }
+   
    public void deployAnnotationIntroduction(Element pointcut) throws Exception
    {
       manager.addAnnotationIntroduction(loadAnnotationIntroduction(pointcut));
@@ -1075,6 +1120,10 @@
             {
                deployDeclare(element, tag);
             }
+            else if (tag.equals("arrayreplacement"))
+            {
+               deployArrayReplacement(element);
+            }
             else
             {
                throw new IllegalArgumentException("Unknown AOP tag: " + tag);
@@ -1189,6 +1238,10 @@
             {
                undeployDeclare(element);
             }
+            else if (tag.equals("arrayreplacement"))
+            {
+               undeployArrayReplacement(element);
+            }
          }
       }
    }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/Domain.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/Domain.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/Domain.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -275,6 +275,34 @@
       return super.getInterfaceIntroductions();
    }
 
+   public Map getArrayReplacements()
+   {
+      if (inheritsBindings)
+      {
+         HashMap map = new HashMap();
+         if (!parentFirst)
+         {
+            // when child first, parent bindings go in first so that they can be overridden by child.
+            map.putAll(parent.getArrayReplacements());
+            synchronized (arrayReplacements)
+            {
+               map.putAll(arrayReplacements);
+            }
+            return map;
+         }
+         else
+         {
+            synchronized (arrayReplacements)
+            {
+               map.putAll(arrayReplacements);
+            }
+            map.putAll(parent.getArrayReplacements());
+            return map;
+         }
+      }
+      return super.getArrayReplacements();
+   }
+
    public Map getTypedefs()
    {
       if (inheritsBindings)

Deleted: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -1,273 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.aop;
-
-import java.util.Map;
-
-import org.jboss.aop.classpool.AOPClassPool;
-import org.jboss.aop.instrument.Instrumentor;
-import org.jboss.aop.instrument.InstrumentorFactory;
-
-import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
-import javassist.ByteArrayClassPath;
-import javassist.ClassPool;
-import javassist.CtClass;
-import javassist.NotFoundException;
-
-/**
- * Generated advisors need to load all the superclasses
- * before we load the actual class.
- *
- * @author <a href="stalep at conduct.no">Stale W. Pedersen</a>
- * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
- * @version $Revision:
- */
-public class SuperClassesFirstWeavingStrategy extends WeavingStrategySupport {
-
-	private boolean verbose = AspectManager.verbose;
-	public static final String AOP_PACKAGE = Advised.class.getPackage().getName();
-
-   public byte[] translate(AspectManager manager, String className, ClassLoader loader, byte[] classfileBuffer) throws Exception
-	{
-		if (isReEntry())
-		{
-			return null;
-		}
-		setReEntry();
-		manager.transformationStarted = true;
-		try
-		{
-			if (manager.isNonAdvisableClassName(className))
-			{
-				return null;
-			}
-
-			AOPClassPool pool = (AOPClassPool) manager.registerClassLoader(loader);
-
-			CtClassTransformationInfo info = obtainCtClassInfo(pool, className, classfileBuffer);
-			CtClass clazz = instrumentClass(manager, pool, info, true);
-			if (clazz != null)
-			{
-				pool.lockInCache(info.getClazz());
-            if (AspectManager.debugClasses)
-            {
-               info.getClazz().debugWriteFile();
-            }
-				byte[] rtn = info.getClazz().toBytecode();
-				if (AspectManager.getPrune()) info.getClazz().prune();
-				return rtn;
-			}
-			else
-			{
-				pool.soften(info.getClazz());
-			}
-			return null;
-		}
-		catch (Exception ex)
-		{
-			if (!(ex instanceof NotFoundException))
-			{
-				if (verbose)
-					ex.printStackTrace();
-				else
-					System.err.println("[error] " + ex.getMessage() +
-                                       ".. Do verbose mode if you want full stack trace.");
-
-			}
-			throw ex;
-		}
-		finally
-		{
-			clearReEntry();
-		}
-	}
-
-	private CtClassTransformationInfo obtainCtClassInfo(AOPClassPool pool, String className, byte[] classfileBuffer) throws NotFoundException
-	{
-		try
-		{
-			return new CtClassTransformationInfo(pool.getLocally(className), className);
-		}
-		catch (NotFoundException e)
-		{
-			// todo Bill Burke: this scares the shit out of me, but it must be done
-			// I think it will screw up hotdeployment at some time.  Then again, maybe not ;)
-			ByteArrayClassPath cp = new ByteArrayClassPath(className, classfileBuffer);
-			pool.insertClassPath(cp);
-			return new CtClassTransformationInfo(pool.getLocally(className), className);
-		}
-      catch(Error e)
-      {
-         return null;
-      }
-	}
-
-	private CtClass instrumentClass(AspectManager manager, AOPClassPool pool, CtClassTransformationInfo info, boolean isLoadedClass) throws NotFoundException, Exception
-	{
-		try
-		{
-			CtClass superClass = info.getClazz().getSuperclass();
-			if (superClass != null && !Instrumentor.implementsAdvised(info.getClazz()))
-			{
-				CtClassTransformationInfo superInfo = new CtClassTransformationInfo(superClass, superClass.getName());
-
-            ClassPool superPool = superClass.getClassPool();
-            if (superPool instanceof AOPClassPool)
-            {
-               AspectManager aspectManager = manager;
-               if (manager instanceof Domain && superPool != pool)
-               {
-                  //We are in a scoped classloader and the superclass is not
-                  aspectManager = AspectManager.instance(superPool.getClassLoader());
-               }
-               instrumentClass(aspectManager, (AOPClassPool)superPool, superInfo, false);
-            }
-			}
-
-			if (manager.isNonAdvisableClassName(info.getClassName()))
-			{
-				return null;
-			}
-
-			if (info.getClass().isArray())
-			{
-				if (verbose) System.out.println("[cannot compile] isArray: " + info.getClassName());
-				pool.flushClass(info.getClassName());
-				return null;
-			}
-			if (info.getClazz().isInterface())
-			{
-				if (verbose) System.out.println("[cannot compile] isInterface: " + info.getClassName());
-				//pool.flushClass(info.getClassName());
-				info.getClazz().prune();
-				return null;
-			}
-			if (info.getClazz().isFrozen())
-			{
-				if(isAdvised(pool, info.getClazz()))
-					return null;
-				if (verbose) System.out.println("[warning] isFrozen: " + info.getClassName() + " " + info.getClazz().getClassPool());
-				if (!isLoadedClass)
-				{
-					info = obtainCtClassInfo(pool, info.getClassName(), null);
-				}
-				else
-					return null;
-				//info.getClazz().defrost();
-			}
-
-         boolean transformed = info.getClazz().isModified();
-         if (!transformed)
-         {
-            ClassAdvisor advisor =
-                   AdvisorFactory.getClassAdvisor(info.getClazz(), manager);
-				Instrumentor instrumentor = InstrumentorFactory.getInstrumentor(
-				      pool,
-                  manager,
-                  manager.dynamicStrategy.getJoinpointClassifier(),
-                  manager.dynamicStrategy.getDynamicTransformationObserver(info.getClazz()));
-
-				if (!Instrumentor.isTransformable(info.getClazz()))
-				{
-					if (verbose) System.out.println("[cannot compile] implements Untransformable: " + info.getClassName());
-					//Flushing the generated invocation classes breaks things further down the line
-					//pool.flushClass(info.getClassName());
-					return null;
-				}
-
-            manager.attachMetaData(advisor, info.getClazz(), true);
-            manager.applyInterfaceIntroductions(advisor, info.getClazz());
-				transformed = instrumentor.transform(info.getClazz(), advisor);
-         }
-			if (transformed)
-			{
-				if (!isLoadedClass )
-				{
-					info.setTransformed(transformed);
-				}
-				return info.getClazz();
-			}
-			return null;
-		}
-		catch(Exception e)
-		{
-			throw new RuntimeException("Error converting class ", e);
-		}
-		finally
-		{
-		}
-	}
-
-	public boolean isAdvised(ClassPool pool, CtClass clazz) throws NotFoundException
-	{
-	   CtClass[] interfaces = clazz.getInterfaces();
-	   CtClass advised = pool.get(AOP_PACKAGE + ".Advised");
-	   for (int i = 0; i < interfaces.length; i++)
-	   {
-	      if (interfaces[i].equals(advised)) return true;
-	      if (interfaces[i].getName().equals(AOP_PACKAGE + ".Advised")) return true;
-	   }
-	   return false;
-	}
-
-
-	private class CtClassTransformationInfo
-	{
-		boolean transformed;
-		CtClass clazz;
-		String className;
-		private CtClassTransformationInfo(CtClass clazz, String className)
-		{
-			this.clazz = clazz;
-			this.className = className;
-		}
-
-		private CtClassTransformationInfo(CtClass clazz, String className, boolean transformed)
-		{
-			this.clazz = clazz;
-			this.className = className;
-			this.transformed = transformed;
-		}
-
-		private CtClass getClazz()
-		{
-			return clazz;
-		}
-
-		private boolean isTransformed()
-		{
-			return transformed;
-		}
-
-		private void setTransformed(boolean transformed)
-		{
-			this.transformed = transformed;
-		}
-
-		private String getClassName()
-		{
-			return className;
-		}
-	}
-
-
-}

Copied: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java (from rev 59143, projects/aop/trunk/aop/src/main/org/jboss/aop/SuperClassesFirstWeavingStrategy.java)

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/Instrumentor.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -35,6 +35,8 @@
 import org.jboss.aop.AspectManager;
 import org.jboss.aop.ClassAdvisor;
 import org.jboss.aop.annotation.compiler.AnnotationInfoCreator;
+import org.jboss.aop.array.ArrayAdvisor;
+import org.jboss.aop.array.ArrayReplacement;
 import org.jboss.aop.classpool.AOPClassPool;
 import org.jboss.aop.classpool.AOPClassPoolRepository;
 import org.jboss.aop.introduction.AnnotationIntroduction;
@@ -662,6 +664,9 @@
          instrumentIntroductions(clazz, advisor);
 
          converted = convertReferences(clazz) || converted;
+         
+         converted = converted || replaceArrayAccess(clazz, advisor);
+         
          // need to instrument no matter what so that
          // previously declared field and constructor interceptions
          // get instrumented within this class.
@@ -940,6 +945,27 @@
       }
    }
 
+   private boolean replaceArrayAccess(CtClass clazz, Advisor advisor) throws Exception
+   {
+      boolean shouldReplace = false;
+      Map arrayReplacements = manager.getArrayReplacements();
+      for (Iterator it = arrayReplacements.values().iterator() ; it.hasNext() ; )
+      {
+         ArrayReplacement arrayReplacement = (ArrayReplacement)it.next();
+         if (arrayReplacement.matches(advisor, clazz))
+         {
+            shouldReplace = true;
+            break;
+         }
+      }
+      
+      if (shouldReplace)
+      {
+         System.out.println("---> Should replace access for " + clazz.getName());
+         converter.replaceArrayAccess(classPool.get(ArrayAdvisor.class.getName()), "arrayRead", "arrayWrite");
+      }
+      return shouldReplace;
+   }
    
    /**
     * Converts all processed classes to make wrapping of the appropriate joinpoints.

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/AOPProxyFactoryParameters.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -24,7 +24,7 @@
 import java.lang.reflect.Constructor;
 
 import org.jboss.aop.metadata.SimpleMetaData;
-//import org.jboss.repository.spi.MetaDataContext;
+import org.jboss.metadata.spi.MetaData;
 
 /**
  * 
@@ -35,9 +35,7 @@
 {
    private Class proxiedClass;
    private Object target;
-   //FIXME convert back to MetaDataContext once the mc 2.0 has been released 
-   //private MetaData metaDataContext;
-   private Object metaDataContext;
+   private MetaData metaDataContext;
    private Class[] interfaces;
    private AOPProxyFactoryMixin[] mixins; 
    private boolean objectAsSuperClass;
@@ -54,7 +52,7 @@
          Object target, 
          Class[] interfaces,
          AOPProxyFactoryMixin[] mixins,
-         Object context, 
+         MetaData context, 
          boolean objectAsSuperClass,
          SimpleMetaData simpleMetaData,
          ContainerCache containerCache,
@@ -81,12 +79,12 @@
       this.interfaces = interfaces;
    }
 
-   public Object getMetaDataContext()
+   public MetaData getMetaDataContext()
    {
       return metaDataContext;
    }
 
-   public void setMetaDataContext(Object metaDataContext)
+   public void setMetaDataContext(MetaData metaDataContext)
    {
       this.metaDataContext = metaDataContext;
    }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/ContainerCache.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ContainerCache.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/ContainerCache.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -29,7 +29,7 @@
 import org.jboss.aop.Domain;
 import org.jboss.aop.introduction.InterfaceIntroduction;
 import org.jboss.aop.metadata.SimpleMetaData;
-//import org.jboss.repository.spi.MetaDataContext;
+import org.jboss.metadata.spi.MetaData;
 
 /**
  * 
@@ -51,12 +51,10 @@
    Class[] interfaces;
    AOPProxyFactoryMixin[] mixins;
 
-   //FIXME - make metaDataContext a MetaDataContext once MC 2.0 is released
-   //MetaDataContext metaDataContext;
-   Object metaDataContext;
+   MetaData metaDataContext;
    SimpleMetaData simpleMetaData;
 
-   private ContainerCache(AspectManager manager, Class proxiedClass, Class[] interfaces, AOPProxyFactoryMixin[] mixins, /*MetaDataContext*/ Object metaDataContext, SimpleMetaData simpleMetaData)
+   private ContainerCache(AspectManager manager, Class proxiedClass, Class[] interfaces, AOPProxyFactoryMixin[] mixins, MetaData metaDataContext, SimpleMetaData simpleMetaData)
    {
       this.manager = manager;
       this.interfaces = interfaces;
@@ -66,13 +64,13 @@
       key = new ContainerProxyCacheKey(proxiedClass, interfaces, mixins, metaDataContext);
    }
    
-   public static ContainerCache initialise(AspectManager manager, Class proxiedClass, /*MetaDataContext*/ Object metaDataContext)
+   public static ContainerCache initialise(AspectManager manager, Class proxiedClass, MetaData metaDataContext)
    {
       return initialise(manager, proxiedClass, null, null, metaDataContext, null);
    }
    
    //FIXME - make metaDataContext a MetaDataContext once MC 2.0 is released
-   public static ContainerCache initialise(AspectManager manager, Class proxiedClass, Class[] interfaces, AOPProxyFactoryMixin[] mixins, /*MetaDataContext*/ Object metaDataContext, SimpleMetaData simpleMetaData)
+   public static ContainerCache initialise(AspectManager manager, Class proxiedClass, Class[] interfaces, AOPProxyFactoryMixin[] mixins, MetaData metaDataContext, SimpleMetaData simpleMetaData)
    {
       ContainerCache factory = new ContainerCache(manager, proxiedClass, interfaces, mixins, metaDataContext, simpleMetaData);
       synchronized (mapLock)

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/GeneratedAOPProxyFactory.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/GeneratedAOPProxyFactory.java	2006-12-19 11:33:03 UTC (rev 59138)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/proxy/container/GeneratedAOPProxyFactory.java	2006-12-21 11:41:51 UTC (rev 59187)
@@ -38,23 +38,6 @@
 {
    public Object createAdvisedProxy(AOPProxyFactoryParameters params)
    {
-//      return createAdvisedProxy(
-//            params.isObjectAsSuperClass(), 
-//            params.getProxiedClass(), 
-//            params.getInterfaces(), 
-//            params.getMixins(),
-//            params.getSimpleMetaData(), 
-//            params.getTarget(),
-//            params.getMetaDataContext(),
-//            params.getContainerCache(),
-//            params.getCtor(),
-//            params.getCtorArguments());
-//   }
-//   
-//   //FIXME - make metaDataContext a MetaDataContext once MC 2.0 is released
-//   private Object createAdvisedProxy(boolean objectAsSuper, Class proxiedClass, Class[] interfaces, 
-//         AOPProxyFactoryMixin[] mixins, SimpleMetaData simpleMetaData, Object target, /*MetaDataContext*/Object metaDataContext, ContainerCache containerCache, Constructor ctor, Object[] ctorArguments)
-//   {
       if (params.getTarget() != null)
       {
          if (params.getProxiedClass() != null)
@@ -74,13 +57,9 @@
          params.setProxiedClass(Object.class);
       }
       
-//      return getProxy(objectAsSuper, manager, proxiedClass, interfaces, mixins, simpleMetaData, target, metaDataContext, containerCache, ctor, ctorArguments);
       return getProxy(params);
    }
 
-   //FIXME - make metaDataContext a MetaDataContext once MC 2.0 is released
-//   private Object getProxy(boolean objectAsSuper, AspectManager manager, Class proxiedClass,  
-//         Class[] interfaces, AOPProxyFactoryMixin[] mixins, SimpleMetaData simpleMetaData, Object target, /*MetaDataContext*/ Object metaDataContext, ContainerCache containerCache, Constructor ctor, Object[] ctorArguments)
    private Object getProxy(AOPProxyFactoryParameters params)
    {
       try



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 06:59:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 06:59:48 -0500
Subject: [jboss-cvs] JBossAS SVN: r59188 -
	branches/Branch_4_2/system/src/main/org/jboss/system
Message-ID: <E1GxMaS-0004Ni-E3@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 06:59:45 -0500 (Thu, 21 Dec 2006)
New Revision: 59188

Modified:
   branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java
Log:
tidy up

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 11:41:51 UTC (rev 59187)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 11:59:45 UTC (rev 59188)
@@ -21,72 +21,52 @@
  */
 package org.jboss.system;
 
+import javax.management.ObjectName;
+
+import org.jboss.mx.util.ObjectNameFactory;
+
 /**
- * MBean interface.
+ * BarrierController MBean interface.
+ * 
+ * @see BarrierController
+ * 
+ * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision$
  */
-public interface BarrierControllerMBean extends org.jboss.system.ListenerServiceMBean
+public interface BarrierControllerMBean extends ListenerServiceMBean
 {
+   // The default object name
+   static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss:service=BarrierController");
 
-   //default object name
-   public static final javax.management.ObjectName OBJECT_NAME = org.jboss.mx.util.ObjectNameFactory
-         .create("jboss:service=BarrierController");
+   // Attributes ----------------------------------------------------
+   
+   /** The controlled barrier StateString. */
+   String getBarrierStateString();
+   
+   /** The controlled barrier ObjectName. */
+   void setBarrierObjectName(ObjectName barrierName);   
+   ObjectName getBarrierObjectName();
+   
+   /** The initial state of the barrier. If set, it overrides the internal call
+    * to enableOnStartup() which will never get called. */
+   void setBarrierEnabledOnStartup(Boolean enableOnStartup);
+   Boolean getBarrierEnabledOnStartup();
+   
+   /** The notification subscription handback string that starts the barrier. */
+   void setStartBarrierHandback(String startHandback);
+   String getStartBarrierHandback();
 
-   /**
-    * The controlled barrier StateString.
-    */
-   java.lang.String getBarrierStateString();
+   /** The notification subscription handback string that stops the barrier. */
+   void setStopBarrierHandback(String stopHandback);
+   String getStopBarrierHandback();
 
-   /**
-    * The controlled barrier ObjectName.
-    */
-   void setBarrierObjectName(javax.management.ObjectName barrierName);
+   /** The ability to dynamically subscribe for notifications. */
+   void setDynamicSubscriptions(Boolean dynamicSubscriptions);
+   Boolean getDynamicSubscriptions();
 
+   // Operations ----------------------------------------------------
+   
    /**
-    * The controlled barrier ObjectName.
-    */
-   javax.management.ObjectName getBarrierObjectName();
-
-   /**
-    * The initial state of the barrier. If set, it overrides the internal call to enableOnStartup() which will never get called.
-    */
-   void setBarrierEnabledOnStartup(java.lang.Boolean enableOnStartup);
-
-   /**
-    * The initial state of the barrier. Use the value set through setBarrierEnabledOnStartup() otherwise call the internal enableOnStartup() override to make a decision.
-    */
-   java.lang.Boolean getBarrierEnabledOnStartup();
-
-   /**
-    * The notification subscription handback string that starts the barrier.
-    */
-   void setStartBarrierHandback(java.lang.String startHandback);
-
-   /**
-    * The notification subscription handback string that starts the barrier.
-    */
-   java.lang.String getStartBarrierHandback();
-
-   /**
-    * The notification subscription handback string that stops the barrier.
-    */
-   void setStopBarrierHandback(java.lang.String stopHandback);
-
-   /**
-    * The notification subscription handback string that stops the barrier.
-    */
-   java.lang.String getStopBarrierHandback();
-
-   /**
-    * The ability to dynamically subscribe for notifications.
-    */
-   void setDynamicSubscriptions(java.lang.Boolean dynamicSubscriptions);
-
-   /**
-    * The ability to dynamically subscribe for notifications.
-    */
-   java.lang.Boolean getDynamicSubscriptions();
-
-   /**
     * Manually start the controlled barrier
     */
    void startBarrier();



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 07:00:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 07:00:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r59189 -
	branches/Branch_4_0/system/src/main/org/jboss/system
Message-ID: <E1GxMbD-0004Pb-PU@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 07:00:33 -0500 (Thu, 21 Dec 2006)
New Revision: 59189

Modified:
   branches/Branch_4_0/system/src/main/org/jboss/system/BarrierControllerMBean.java
Log:
tidy up

Modified: branches/Branch_4_0/system/src/main/org/jboss/system/BarrierControllerMBean.java
===================================================================
--- branches/Branch_4_0/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 11:59:45 UTC (rev 59188)
+++ branches/Branch_4_0/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 12:00:33 UTC (rev 59189)
@@ -21,72 +21,52 @@
  */
 package org.jboss.system;
 
+import javax.management.ObjectName;
+
+import org.jboss.mx.util.ObjectNameFactory;
+
 /**
- * MBean interface.
+ * BarrierController MBean interface.
+ * 
+ * @see BarrierController
+ * 
+ * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision$
  */
-public interface BarrierControllerMBean extends org.jboss.system.ListenerServiceMBean
+public interface BarrierControllerMBean extends ListenerServiceMBean
 {
+   // The default object name
+   static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss:service=BarrierController");
 
-   //default object name
-   public static final javax.management.ObjectName OBJECT_NAME = org.jboss.mx.util.ObjectNameFactory
-         .create("jboss:service=BarrierController");
+   // Attributes ----------------------------------------------------
+   
+   /** The controlled barrier StateString. */
+   String getBarrierStateString();
+   
+   /** The controlled barrier ObjectName. */
+   void setBarrierObjectName(ObjectName barrierName);   
+   ObjectName getBarrierObjectName();
+   
+   /** The initial state of the barrier. If set, it overrides the internal call
+    * to enableOnStartup() which will never get called. */
+   void setBarrierEnabledOnStartup(Boolean enableOnStartup);
+   Boolean getBarrierEnabledOnStartup();
+   
+   /** The notification subscription handback string that starts the barrier. */
+   void setStartBarrierHandback(String startHandback);
+   String getStartBarrierHandback();
 
-   /**
-    * The controlled barrier StateString.
-    */
-   java.lang.String getBarrierStateString();
+   /** The notification subscription handback string that stops the barrier. */
+   void setStopBarrierHandback(String stopHandback);
+   String getStopBarrierHandback();
 
-   /**
-    * The controlled barrier ObjectName.
-    */
-   void setBarrierObjectName(javax.management.ObjectName barrierName);
+   /** The ability to dynamically subscribe for notifications. */
+   void setDynamicSubscriptions(Boolean dynamicSubscriptions);
+   Boolean getDynamicSubscriptions();
 
+   // Operations ----------------------------------------------------
+   
    /**
-    * The controlled barrier ObjectName.
-    */
-   javax.management.ObjectName getBarrierObjectName();
-
-   /**
-    * The initial state of the barrier. If set, it overrides the internal call to enableOnStartup() which will never get called.
-    */
-   void setBarrierEnabledOnStartup(java.lang.Boolean enableOnStartup);
-
-   /**
-    * The initial state of the barrier. Use the value set through setBarrierEnabledOnStartup() otherwise call the internal enableOnStartup() override to make a decision.
-    */
-   java.lang.Boolean getBarrierEnabledOnStartup();
-
-   /**
-    * The notification subscription handback string that starts the barrier.
-    */
-   void setStartBarrierHandback(java.lang.String startHandback);
-
-   /**
-    * The notification subscription handback string that starts the barrier.
-    */
-   java.lang.String getStartBarrierHandback();
-
-   /**
-    * The notification subscription handback string that stops the barrier.
-    */
-   void setStopBarrierHandback(java.lang.String stopHandback);
-
-   /**
-    * The notification subscription handback string that stops the barrier.
-    */
-   java.lang.String getStopBarrierHandback();
-
-   /**
-    * The ability to dynamically subscribe for notifications.
-    */
-   void setDynamicSubscriptions(java.lang.Boolean dynamicSubscriptions);
-
-   /**
-    * The ability to dynamically subscribe for notifications.
-    */
-   java.lang.Boolean getDynamicSubscriptions();
-
-   /**
     * Manually start the controlled barrier
     */
    void startBarrier();



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 07:02:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 07:02:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59190 - in
	projects/aop/branches/arrays/aop/src: main/org/jboss/aop
	main/org/jboss/aop/array main/org/jboss/aop/instrument
	main/org/jboss/aop/pointcut/ast resources/test
	resources/test/array test/org/jboss/test/aop
	test/org/jboss/test/aop/array
Message-ID: <E1GxMcj-0004f7-KJ@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-21 07:02:00 -0500 (Thu, 21 Dec 2006)
New Revision: 59190

Added:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReplacement.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/ArrayAccessTransformer.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayAccess.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayGet.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArraySet.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/pointcut.jj
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/typeExpression.jj
   projects/aop/branches/arrays/aop/src/resources/test/array/
   projects/aop/branches/arrays/aop/src/resources/test/array/MANIFEST.MF
   projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/META-INF/
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java
Log:
Add initial tests for array interception

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,156 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayAdvisor
+{
+   public static Object array;
+   public static String value;
+   public static int index;
+   
+   public static void clear()
+   {
+      array = null;
+      value = null;
+      index = -1;
+   }
+   
+   private static void recordAccess(Object array, int index, String value)
+   {
+      System.out.println("Accessing array");
+      ArrayAdvisor.array = array;
+      ArrayAdvisor.index = index;
+      ArrayAdvisor.value = value;
+   }
+   
+   //Write operations
+   public static void arrayWrite(boolean[] array, int index, boolean value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+
+   public static void arrayWrite(short[] array, int index, short value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+
+   public static void arrayWrite(int[] array, int index, int value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(long[] array, int index, long value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(float[] array, int index, float value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(double[] array, int index, double value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(char[] array, int index, char value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(Object[] array, int index, Object value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+
+   //Read operations
+   public static boolean arrayRead(boolean[] array, int index)
+   {
+      
+      boolean value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+
+   public static short arrayRead(short[] array, int index)
+   {
+      short value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+
+   public static int arrayRead(int[] array, int index)
+   {
+      int value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static long arrayRead(long[] array, int index)
+   {
+      long value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static float arrayRead(float[] array, int index)
+   {
+      float value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static double arrayRead(double[] array, int index)
+   {
+      double value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static char arrayRead(char[] array, int index)
+   {
+      char value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static Object arrayRead(Object[] array, int index)
+   {
+      Object value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReplacement.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReplacement.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReplacement.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,104 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import javassist.CtClass;
+
+import org.jboss.aop.Advisor;
+import org.jboss.aop.pointcut.TypeMatcher;
+import org.jboss.aop.pointcut.Util;
+import org.jboss.aop.pointcut.ast.ASTStart;
+import org.jboss.aop.pointcut.ast.ClassExpression;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayReplacement
+{
+   private String name;
+   protected ClassExpression classExpr;
+   protected ASTStart ast;
+
+   public ArrayReplacement(String name, String exp)
+   {
+      this.name = name;
+      this.classExpr = new ClassExpression(exp);
+   }
+
+   public ArrayReplacement(String name, ASTStart ast)
+   {
+      this.name = name;
+      this.ast = ast;
+   }
+
+   public boolean equals(Object obj)
+   {
+      if (obj == this) return true;
+      if (!(obj instanceof ArrayReplacement)) return false;
+      return ((ArrayReplacement) obj).getName().equals(name);
+   }
+
+   public int hashCode()
+   {
+      return name.hashCode();
+   }
+
+   public String getName()
+   {
+      return name;
+   }
+
+   public String getClassExpr()
+   {
+      if (classExpr == null) return null;
+      return classExpr.getOriginal();
+   }
+
+   public ASTStart getAst()
+   {
+      return ast;
+   }
+
+   public boolean matches(Advisor advisor, CtClass clazz) throws Exception
+   {
+      if (classExpr != null)
+         return Util.matchesClassExpr(classExpr, clazz, advisor);
+      else
+      {
+         TypeMatcher matcher = new TypeMatcher(advisor, clazz);
+         return ((Boolean) ast.jjtAccept(matcher, null)).booleanValue();
+      }
+   }
+
+   public boolean matches(Advisor advisor, Class clazz)
+   {
+      if (classExpr != null)
+         return Util.matchesClassExpr(classExpr, clazz, advisor);
+      else
+      {
+         TypeMatcher matcher = new TypeMatcher(advisor, clazz);
+         return ((Boolean) ast.jjtAccept(matcher, null)).booleanValue();
+      }
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/ArrayAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/ArrayAccessTransformer.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/ArrayAccessTransformer.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.instrument;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayAccessTransformer
+{
+
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayAccess.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayAccess.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayAccess.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,19 @@
+/* Generated By:JJTree: Do not edit this line. ASTArrayAccess.java */
+
+package org.jboss.aop.pointcut.ast;
+
+public class ASTArrayAccess extends SimpleNode {
+  public ASTArrayAccess(int id) {
+    super(id);
+  }
+
+  public ASTArrayAccess(PointcutExpressionParser p, int id) {
+    super(p, id);
+  }
+
+
+  /** Accept the visitor. **/
+  public Object jjtAccept(PointcutExpressionParserVisitor visitor, Object data) {
+    return visitor.visit(this, data);
+  }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayGet.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayGet.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArrayGet.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,19 @@
+/* Generated By:JJTree: Do not edit this line. ASTArrayGet.java */
+
+package org.jboss.aop.pointcut.ast;
+
+public class ASTArrayGet extends SimpleNode {
+  public ASTArrayGet(int id) {
+    super(id);
+  }
+
+  public ASTArrayGet(PointcutExpressionParser p, int id) {
+    super(p, id);
+  }
+
+
+  /** Accept the visitor. **/
+  public Object jjtAccept(PointcutExpressionParserVisitor visitor, Object data) {
+    return visitor.visit(this, data);
+  }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArraySet.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArraySet.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/ASTArraySet.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,19 @@
+/* Generated By:JJTree: Do not edit this line. ASTArraySet.java */
+
+package org.jboss.aop.pointcut.ast;
+
+public class ASTArraySet extends SimpleNode {
+  public ASTArraySet(int id) {
+    super(id);
+  }
+
+  public ASTArraySet(PointcutExpressionParser p, int id) {
+    super(p, id);
+  }
+
+
+  /** Accept the visitor. **/
+  public Object jjtAccept(PointcutExpressionParserVisitor visitor, Object data) {
+    return visitor.visit(this, data);
+  }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/pointcut.jj
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/pointcut.jj	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/pointcut.jj	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,1546 @@
+/*@bgen(jjtree) Generated By:JJTree: Do not edit this line. C:/cygwin/home/Kabir/sourcecontrol/jboss-aop/aop/src/main/org/jboss/aop/pointcut/ast\pointcut.jj */
+/*@egen*//**
+ *
+ */
+options {                                                           
+  STATIC=false;
+}
+
+PARSER_BEGIN(PointcutExpressionParser)
+package org.jboss.aop.pointcut.ast;
+
+import java.lang.reflect.Modifier;
+
+public class PointcutExpressionParser/*@bgen(jjtree)*/implements PointcutExpressionParserTreeConstants/*@egen*/ {/*@bgen(jjtree)*/
+  protected JJTPointcutExpressionParserState jjtree = new JJTPointcutExpressionParserState();
+
+/*@egen*/
+  public static void main(String args[]) {
+    System.out.println("Reading from standard input...");
+    PointcutExpressionParser t = new PointcutExpressionParser(System.in);
+    try {
+      ASTStart n = t.Start();
+      //PointcutExpressionParserVisitor v = new PointcutExpressionDumpVisitor();
+      //n.jjtAccept(v, null);
+    } catch (Exception e) {
+      System.out.println("Oops.");
+      System.out.println(e.getMessage());
+      e.printStackTrace();
+    }
+  }
+}
+
+PARSER_END(PointcutExpressionParser)
+
+
+SKIP :
+{
+  " "
+| "\t"
+}
+
+TOKEN : /* IDENTIFIERS */
+{
+< AND: ["A","a"]["N","n"]["D","d"] >
+| < OR:  ["O","o"]["R","r"] >
+| < CALL: "call(" > : BEHAVIOR
+| < ALL: "all(" >  : FIELD_DECLARATION
+| < EXECUTION: "execution(" > : BEHAVIOR
+| < CONSTRUCTION: "construction(" > : BEHAVIOR
+| < HAS: "has(" > : BEHAVIOR
+| < HAS_FIELD: "hasfield(" > : FIELD_DECLARATION
+| < GET: "get(" > : FIELD_DECLARATION
+| < SET: "set(" > : FIELD_DECLARATION
+| < FIELD: "field(" > : FIELD_DECLARATION
+| < ARRAYGET: "arrayget(" > : FIELD_DECLARATION
+| < ARRAYSET: "arrayset(" > : FIELD_DECLARATION
+| < ARRAYACCESS: "array(" > : FIELD_DECLARATION
+| < WITHIN: "within(" > : FIELD_DECLARATION
+| < WITHINCODE: "withincode(" > : BEHAVIOR
+| < POINTCUT: <POINTCUT_IDENTIFIER> (<POINTCUT_DOT> <POINTCUT_IDENTIFIER>)*>
+| < POINTCUT_IDENTIFIER: (<POINTCUT_WILD_LETTER>)+ >
+|
+  < #POINTCUT_WILD_LETTER: ["_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #POINTCUT_DOT: ["."] >
+| <NOT: "!">
+}
+
+<PARAMS> SKIP :
+{
+  " "
+| "\t"
+}
+
+<PARAMS> TOKEN:
+{
+  < ALL_PARAMS: ".." >
+|
+  < PARAM_CLASS: <PARAM_IDENTIFIER> (<PARAM_DOT> <PARAM_IDENTIFIER>)+ (<PARAM_ARRAY>)*>
+|
+  < PARAM_ARRAY_CLASS: <PARAM_IDENTIFIER> (<PARAM_ARRAY>)+>
+|
+  < PARAM_ANNOTATION: "@" <PARAM_IDENTIFIER> (<PARAM_DOT> <PARAM_IDENTIFIER>)+ >
+|
+  < PARAM_INSTANCEOF: "$instanceof{" (<PARAM_IDENTIFIER> | <PARAM_CLASS> | <PARAM_ANNOTATION>) "}">
+|
+  < PARAM_TYPEDEF: "$typedef{" <POINTCUT> "}">
+|
+  < PARAM_IDENTIFIER: (<PARAM_WILD_LETTER>)+ >
+|
+  < COMMA: "," >
+|
+  < #PARAM_WILD_LETTER: ["$", "*","_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #PARAM_DOT: ["."] >
+|
+  < #PARAM_ARRAY: "[]" >
+| <PARAMS_CLOSE: ")"> : BEHAVIOR
+}
+
+
+<BEHAVIOR> SKIP :
+{
+  " "
+| "\t"
+}
+
+<BEHAVIOR> TOKEN : /* IDENTIFIERS */
+{
+  < ABSTRACT: "abstract" >
+| < FINAL: "final" >
+| < PRIVATE: "private" >
+| < PROTECTED: "protected" >
+| < PUBLIC: "public" >
+| < STATIC: "static" >
+| < NATIVE: "native" >
+| < SYNCHRONIZED: "synchronized" >
+| < NEW: "new" >
+| < THROWS: "throws" >
+|
+  < INSTANCEOF: "$instanceof{" (<IDENTIFIER> | <CLASS> | <ANNOTATION>) "}">
+|
+  < TYPEDEF: "$typedef{" <POINTCUT> "}">
+|
+  < CLASS: <IDENTIFIER> (<DOT> <IDENTIFIER>)+ (<ARRAY>)*>
+| 
+  < EXCEPTION_SEPERATOR: "," >
+|
+  < ARRAY_CLASS: <IDENTIFIER> (<ARRAY>)+>
+|
+  < ANNOTATION: "@" <IDENTIFIER> (<DOT> <IDENTIFIER>)*>
+|
+  <IMPLEMENTS: "$implements{" (<CLASS> | <ANNOTATION>) "}">
+|
+  <IMPLEMENTING: "$implementing{" (<CLASS> | <ANNOTATION>) "}">
+|
+  < IDENTIFIER: (<WILD_LETTER>)+ >
+|
+  < #WILD_LETTER: ["$","*","_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #DOT: ["."] >
+|
+  < #ARRAY: "[]" >
+| < SEPARATOR: "->" >
+| <BEHAVIOR_NOT: "!">
+| < PARAMS_OPEN: "("> : PARAMS
+| <BEHAVIOR_CLOSE: ")"> : DEFAULT
+}
+
+<FIELD_DECLARATION> SKIP :
+{
+  " "
+| "\t"
+}
+
+<FIELD_DECLARATION> TOKEN : /* IDENTIFIERS */
+{
+  < FIELD_ABSTRACT: "abstract" >
+| < FIELD_FINAL: "final" >
+| < FIELD_PRIVATE: "private" >
+| < FIELD_PROTECTED: "protected" >
+| < FIELD_PUBLIC: "public" >
+| < FIELD_STATIC: "static" >
+| < FIELD_TRANSIENT: "transient" >
+| < FIELD_NATIVE: "native" >
+| < FIELD_SYNCHRONIZED: "synchronized" >
+|
+  < FIELD_INSTANCEOF: "$instanceof{" (<FIELD_IDENTIFIER> | <FIELD_CLASS> | <FIELD_ANNOTATION>) "}">
+|
+  < FIELD_TYPEDEF: "$typedef{" <POINTCUT> "}">
+|
+  < FIELD_CLASS: <FIELD_IDENTIFIER> (<FIELD_DOT> <FIELD_IDENTIFIER>)+ (<FIELD_ARRAY>)*>
+|
+  < FIELD_ARRAY_CLASS: <FIELD_IDENTIFIER> (<FIELD_ARRAY>)+>
+|
+  < FIELD_ANNOTATION: "@" <FIELD_IDENTIFIER> (<FIELD_DOT> <FIELD_IDENTIFIER>)* >
+|
+  < FIELD_IDENTIFIER: (<FIELD_WILD_LETTER>)+ >
+|
+  < #FIELD_WILD_LETTER: ["$","*","_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #FIELD_DOT: ["."] >
+|
+  < #FIELD_ARRAY: "[]" >
+| < FIELD_SEPARATOR: "->" >
+| < FIELD_NOT: "!" >
+| <FIELD_CLOSE: ")"> : DEFAULT
+}
+
+ASTStart Start()        : {/*@bgen(jjtree) Start */
+  ASTStart jjtn000 = new ASTStart(JJTSTART);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Start */
+  try {
+/*@egen*/
+  Expression() <EOF>/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  { return jjtn000; }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+ASTExecution execution()                : {/*@bgen(jjtree) ExecutionOnly */
+  ASTExecutionOnly jjtn000 = new ASTExecutionOnly(JJTEXECUTIONONLY);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) ExecutionOnly */
+  try {
+/*@egen*/
+  Execution() <EOF>/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  { return (ASTExecution)jjtn000.jjtGetChild(0); }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Expression()       : {}
+{
+  LOOKAHEAD(234234234) BooleanExpression() | Concrete() |  Not()
+}
+
+void BooleanExpression()          : {/*@bgen(jjtree) Boolean */
+  ASTBoolean jjtn000 = new ASTBoolean(JJTBOOLEAN);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Boolean */
+   try {
+/*@egen*/
+   LOOKAHEAD(3) SubExpression() | LOOKAHEAD(3) CompositeExpression()/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void CompositeExpression()            : {/*@bgen(jjtree) Composite */
+  ASTComposite jjtn000 = new ASTComposite(JJTCOMPOSITE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Composite */
+   try {
+/*@egen*/
+   "(" SubExpression() ")"/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Not()      : {/*@bgen(jjtree) Not */
+  ASTNot jjtn000 = new ASTNot(JJTNOT);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Not */
+   try {
+/*@egen*/
+   <NOT> (LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression())/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void SubExpression()      : {/*@bgen(jjtree) Sub */
+  ASTSub jjtn000 = new ASTSub(JJTSUB);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Sub */
+  try {
+/*@egen*/
+  (LOOKAHEAD(3) Not() | LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression() ) ( And() | Or())+/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void And()      : {/*@bgen(jjtree) And */
+  ASTAnd jjtn000 = new ASTAnd(JJTAND);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) And */
+  try {
+/*@egen*/
+  <AND> (LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression() | LOOKAHEAD(3) Not())/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Or()     : {/*@bgen(jjtree) Or */
+  ASTOr jjtn000 = new ASTOr(JJTOR);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Or */
+  try {
+/*@egen*/
+  <OR> (LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression() | LOOKAHEAD(3) Not())/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+ASTCFlowExpression CFlowExpression()                  : {/*@bgen(jjtree) CFlowExpression */
+  ASTCFlowExpression jjtn000 = new ASTCFlowExpression(JJTCFLOWEXPRESSION);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) CFlowExpression */
+  try {
+/*@egen*/
+  (LOOKAHEAD(3) CFlowBoolean() | LOOKAHEAD(3) CFlow() |  LOOKAHEAD(3) NotCFlow()) <EOF>/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  { return jjtn000; }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void CFlowBoolean()               : {/*@bgen(jjtree) CFlowBoolean */
+  ASTCFlowBoolean jjtn000 = new ASTCFlowBoolean(JJTCFLOWBOOLEAN);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) CFlowBoolean */
+   try {
+/*@egen*/
+   CompositeCFlow()/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void NotCFlow()           : {/*@bgen(jjtree) NotCFlow */
+  ASTNotCFlow jjtn000 = new ASTNotCFlow(JJTNOTCFLOW);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) NotCFlow */
+   try {
+/*@egen*/
+   <NOT> (LOOKAHEAD(3) CFlow() | LOOKAHEAD(3) CompositeCFlow())/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void CompositeCFlow()                 : {/*@bgen(jjtree) CompositeCFlow */
+  ASTCompositeCFlow jjtn000 = new ASTCompositeCFlow(JJTCOMPOSITECFLOW);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) CompositeCFlow */
+   try {
+/*@egen*/
+   "(" SubCFlow() ")"/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void SubCFlow()           : {/*@bgen(jjtree) SubCFlow */
+  ASTSubCFlow jjtn000 = new ASTSubCFlow(JJTSUBCFLOW);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) SubCFlow */
+   try {
+/*@egen*/
+   (LOOKAHEAD(3) NotCFlow() | LOOKAHEAD(3) CFlow()) ( AndCFlow() | OrCFlow())+/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void AndCFlow()           : {/*@bgen(jjtree) AndCFlow */
+  ASTAndCFlow jjtn000 = new ASTAndCFlow(JJTANDCFLOW);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) AndCFlow */
+  try {
+/*@egen*/
+  <AND> (LOOKAHEAD(3) CFlow() | LOOKAHEAD(3) CompositeCFlow())/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void OrCFlow()          : {/*@bgen(jjtree) OrCFlow */
+  ASTOrCFlow jjtn000 = new ASTOrCFlow(JJTORCFLOW);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) OrCFlow */
+  try {
+/*@egen*/
+  <OR> (LOOKAHEAD(3) CFlow() | LOOKAHEAD(3) CompositeCFlow())/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void ConcreteExpression()       : {}
+{
+  Concrete()
+}
+
+void Concrete()       : {}
+{
+   ( LOOKAHEAD(4) Call() | LOOKAHEAD(4) Within() | LOOKAHEAD(4) Withincode() | LOOKAHEAD(4) Execution() | LOOKAHEAD(4) Construction() | LOOKAHEAD(4) Set() | LOOKAHEAD(4) Get() | LOOKAHEAD(4) FieldExecution() | LOOKAHEAD(4) ArraySet() | LOOKAHEAD(4) ArrayGet() | LOOKAHEAD(4) ArrayAccess() | LOOKAHEAD(4) Pointcut() | LOOKAHEAD(4) All()| LOOKAHEAD(4) Has()| LOOKAHEAD(4) HasField())
+}
+
+void Pointcut()           :
+{/*@bgen(jjtree) Pointcut */
+  ASTPointcut jjtn000 = new ASTPointcut(JJTPOINTCUT);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token pointcut;
+}
+{/*@bgen(jjtree) Pointcut */
+   try {
+/*@egen*/
+   pointcut=<POINTCUT>/*@bgen(jjtree)*/
+   {
+     jjtree.closeNodeScope(jjtn000, true);
+     jjtc000 = false;
+   }
+/*@egen*/
+   {
+      jjtn000.setPointcutName(pointcut.image);
+   }/*@bgen(jjtree)*/
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void CFlow()        :
+{/*@bgen(jjtree) CFlow */
+  ASTCFlow jjtn000 = new ASTCFlow(JJTCFLOW);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token pointcut;
+}
+{/*@bgen(jjtree) CFlow */
+   try {
+/*@egen*/
+   pointcut=<POINTCUT>/*@bgen(jjtree)*/
+   {
+     jjtree.closeNodeScope(jjtn000, true);
+     jjtc000 = false;
+   }
+/*@egen*/
+   {
+      jjtn000.setPointcutName(pointcut.image);
+   }/*@bgen(jjtree)*/
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void All()      :
+{/*@bgen(jjtree) All */
+  ASTAll jjtn000 = new ASTAll(JJTALL);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token pointcut;
+}
+{/*@bgen(jjtree) All */
+   try {
+/*@egen*/
+   <ALL>
+
+   (pointcut=<FIELD_CLASS>|pointcut=<FIELD_IDENTIFIER>|pointcut=<FIELD_ANNOTATION>|pointcut=<FIELD_INSTANCEOF>|pointcut=<FIELD_TYPEDEF>)
+   {
+      jjtn000.setClassExpression(pointcut.image);
+   }
+
+   <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Call()       : {/*@bgen(jjtree) Call */
+  ASTCall jjtn000 = new ASTCall(JJTCALL);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Call */
+   try {
+/*@egen*/
+   <CALL> (LOOKAHEAD(4) Method() | LOOKAHEAD(4) Constructor()) <BEHAVIOR_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Within()         :
+{/*@bgen(jjtree) Within */
+   ASTWithin jjtn000 = new ASTWithin(JJTWITHIN);
+   boolean jjtc000 = true;
+   jjtree.openNodeScope(jjtn000);
+/*@egen*/
+   Token clazz;
+}
+{/*@bgen(jjtree) Within */
+  try {
+/*@egen*/
+  <WITHIN>
+  (clazz=<FIELD_CLASS> | clazz=<FIELD_IDENTIFIER> | clazz=<FIELD_ANNOTATION> | clazz=<FIELD_INSTANCEOF>| clazz=<FIELD_TYPEDEF>)
+  <FIELD_CLOSE>/*@bgen(jjtree)*/
+   {
+     jjtree.closeNodeScope(jjtn000, true);
+     jjtc000 = false;
+   }
+/*@egen*/
+   { jjtn000.setClassExpression(clazz.image); }/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Withincode()             : {/*@bgen(jjtree) Withincode */
+  ASTWithincode jjtn000 = new ASTWithincode(JJTWITHINCODE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Withincode */
+   try {
+/*@egen*/
+   <WITHINCODE> (LOOKAHEAD(3) Method() | LOOKAHEAD(3) Constructor()) <BEHAVIOR_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Execution()            : {/*@bgen(jjtree) Execution */
+  ASTExecution jjtn000 = new ASTExecution(JJTEXECUTION);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Execution */
+   try {
+/*@egen*/
+   <EXECUTION> (LOOKAHEAD(3) Method() | LOOKAHEAD(3) Constructor()) <BEHAVIOR_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Construction()               : {/*@bgen(jjtree) Construction */
+  ASTConstruction jjtn000 = new ASTConstruction(JJTCONSTRUCTION);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Construction */
+   try {
+/*@egen*/
+   <CONSTRUCTION> (Constructor()) <BEHAVIOR_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Has()      : {/*@bgen(jjtree) Has */
+  ASTHas jjtn000 = new ASTHas(JJTHAS);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Has */
+   try {
+/*@egen*/
+   <HAS> (LOOKAHEAD(4) Method() | LOOKAHEAD(4) Constructor()) <BEHAVIOR_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void HasField()           : {/*@bgen(jjtree) HasField */
+  ASTHasField jjtn000 = new ASTHasField(JJTHASFIELD);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) HasField */
+   try {
+/*@egen*/
+   <HAS_FIELD> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Get()      : {/*@bgen(jjtree) Get */
+  ASTGet jjtn000 = new ASTGet(JJTGET);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Get */
+   try {
+/*@egen*/
+   <GET> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Set()      : {/*@bgen(jjtree) Set */
+  ASTSet jjtn000 = new ASTSet(JJTSET);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Set */
+   try {
+/*@egen*/
+   <SET> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void FieldExecution()                 : {/*@bgen(jjtree) FieldExecution */
+  ASTFieldExecution jjtn000 = new ASTFieldExecution(JJTFIELDEXECUTION);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) FieldExecution */
+   try {
+/*@egen*/
+   <FIELD> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void ArrayGet()           : {/*@bgen(jjtree) ArrayGet */
+  ASTArrayGet jjtn000 = new ASTArrayGet(JJTARRAYGET);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) ArrayGet */
+   try {
+/*@egen*/
+   <ARRAYGET> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void ArraySet()           : {/*@bgen(jjtree) ArraySet */
+  ASTArraySet jjtn000 = new ASTArraySet(JJTARRAYSET);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) ArraySet */
+   try {
+/*@egen*/
+   <ARRAYSET> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void ArrayAccess()              : {/*@bgen(jjtree) ArrayAccess */
+  ASTArrayAccess jjtn000 = new ASTArrayAccess(JJTARRAYACCESS);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) ArrayAccess */
+   try {
+/*@egen*/
+   <ARRAYACCESS> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Method()         :
+{/*@bgen(jjtree) Method */
+  ASTMethod jjtn000 = new ASTMethod(JJTMETHOD);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token ret, clazz, body;
+}
+{/*@bgen(jjtree) Method */
+  try {
+/*@egen*/
+  (Attribute())* (ret=<CLASS>|ret=<IDENTIFIER>|ret=<ANNOTATION>|ret=<ARRAY_CLASS>|ret=<INSTANCEOF>|ret=<TYPEDEF>) (clazz=<CLASS>|clazz=<IDENTIFIER>|clazz=<ANNOTATION>|clazz=<INSTANCEOF>|clazz=<TYPEDEF>) <SEPARATOR> (body=<IDENTIFIER>|body=<ANNOTATION>|body=<IMPLEMENTS>|body=<IMPLEMENTING>) Parameters() Throws()/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setReturnTypeExpression(ret.image);
+    jjtn000.setClassExpression(clazz.image);
+    jjtn000.setMethodExpression(body.image);
+  }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Throws()       : {}
+{
+   (<THROWS> Exception() (<EXCEPTION_SEPERATOR> Exception())*)?
+}
+
+void Exception()           : 
+{/*@bgen(jjtree) Exception */
+   ASTException jjtn000 = new ASTException(JJTEXCEPTION);
+   boolean jjtc000 = true;
+   jjtree.openNodeScope(jjtn000);
+/*@egen*/
+   Token ex;
+}
+{/*@bgen(jjtree) Exception */
+        try {
+/*@egen*/
+	(ex=<CLASS> | ex=<IDENTIFIER>)/*@bgen(jjtree)*/
+        {
+          jjtree.closeNodeScope(jjtn000, true);
+          jjtc000 = false;
+        }
+/*@egen*/
+	{
+		jjtn000.setTypeExpression(ex.image);
+	}/*@bgen(jjtree)*/
+        } finally {
+          if (jjtc000) {
+            jjtree.closeNodeScope(jjtn000, true);
+          }
+        }
+/*@egen*/
+}
+
+void Attribute()            :
+{/*@bgen(jjtree) Attribute */
+  ASTAttribute jjtn000 = new ASTAttribute(JJTATTRIBUTE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) Attribute */
+  try {
+/*@egen*/
+  [<BEHAVIOR_NOT> { jjtn000.not=true; } ]
+  (<PUBLIC>/*@bgen(jjtree)*/
+            {
+              jjtree.closeNodeScope(jjtn000, true);
+              jjtc000 = false;
+            }
+/*@egen*/ { jjtn000.setValue(Modifier.PUBLIC); } | <PROTECTED>/*@bgen(jjtree)*/
+                                                                 {
+                                                                   jjtree.closeNodeScope(jjtn000, true);
+                                                                   jjtc000 = false;
+                                                                 }
+/*@egen*/ { jjtn000.setValue(Modifier.PROTECTED); } | <PRIVATE>/*@bgen(jjtree)*/
+                                                                                                                       {
+                                                                                                                         jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                         jjtc000 = false;
+                                                                                                                       }
+/*@egen*/ { jjtn000.setValue(Modifier.PRIVATE); } | <STATIC>/*@bgen(jjtree)*/
+                                                                                                                                                                          {
+                                                                                                                                                                            jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                            jjtc000 = false;
+                                                                                                                                                                          }
+/*@egen*/ { jjtn000.setValue(Modifier.STATIC); } | <ABSTRACT>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                              {
+                                                                                                                                                                                                                                jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                jjtc000 = false;
+                                                                                                                                                                                                                              }
+/*@egen*/ { jjtn000.setValue(Modifier.ABSTRACT); } | <FINAL>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                 {
+                                                                                                                                                                                                                                                                                   jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                   jjtc000 = false;
+                                                                                                                                                                                                                                                                                 }
+/*@egen*/ { jjtn000.setValue(Modifier.FINAL); } | <NATIVE>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                                                                  {
+                                                                                                                                                                                                                                                                                                                                    jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                                                                    jjtc000 = false;
+                                                                                                                                                                                                                                                                                                                                  }
+/*@egen*/ { jjtn000.setValue(Modifier.NATIVE); } | <SYNCHRONIZED>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                                                                                                                          {
+                                                                                                                                                                                                                                                                                                                                                                                            jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                                                                                                                            jjtc000 = false;
+                                                                                                                                                                                                                                                                                                                                                                                          }
+/*@egen*/ { jjtn000.setValue(Modifier.SYNCHRONIZED); })/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Constructor()              :
+{/*@bgen(jjtree) Constructor */
+  ASTConstructor jjtn000 = new ASTConstructor(JJTCONSTRUCTOR);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token clazz, danew;
+}
+{/*@bgen(jjtree) Constructor */
+  try {
+/*@egen*/
+  (ConstructorAttribute())* (clazz=<CLASS> | clazz=<IDENTIFIER> | clazz=<ANNOTATION> | clazz=<INSTANCEOF> | clazz=<TYPEDEF>)
+  {
+    jjtn000.setClassExpression(clazz.image);
+  }
+  <SEPARATOR> (danew=<NEW> | danew=<ANNOTATION>) Parameters() Throws()/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setNewExpression(danew.image);
+  }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void ConstructorAttribute()            :
+{/*@bgen(jjtree) Attribute */
+  ASTAttribute jjtn000 = new ASTAttribute(JJTATTRIBUTE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) Attribute */
+  try {
+/*@egen*/
+  <PUBLIC>/*@bgen(jjtree)*/
+           {
+             jjtree.closeNodeScope(jjtn000, true);
+             jjtc000 = false;
+           }
+/*@egen*/ { jjtn000.setValue(Modifier.PUBLIC); } | <PROTECTED>/*@bgen(jjtree)*/
+                                                                {
+                                                                  jjtree.closeNodeScope(jjtn000, true);
+                                                                  jjtc000 = false;
+                                                                }
+/*@egen*/ { jjtn000.setValue(Modifier.PROTECTED); } | <PRIVATE>/*@bgen(jjtree)*/
+                                                                                                                      {
+                                                                                                                        jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                        jjtc000 = false;
+                                                                                                                      }
+/*@egen*/ { jjtn000.setValue(Modifier.PRIVATE); }/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Parameters()       :
+{
+}
+{
+   (LOOKAHEAD(3) <PARAMS_OPEN> AllParams()<PARAMS_CLOSE> | LOOKAHEAD(3) <PARAMS_OPEN> [Parameter() ( <COMMA> Parameter() )* ] <PARAMS_CLOSE>)
+}
+
+void Parameter()            :
+{/*@bgen(jjtree) Parameter */
+  ASTParameter jjtn000 = new ASTParameter(JJTPARAMETER);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token t;
+}
+{/*@bgen(jjtree) Parameter */
+  try {
+/*@egen*/
+  (t=<ALL_PARAMS> | t=<PARAM_CLASS> | t=<PARAM_IDENTIFIER> | t=<PARAM_ARRAY_CLASS> | t=<PARAM_ANNOTATION> | t=<PARAM_TYPEDEF> | t=<PARAM_INSTANCEOF>)/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setTypeExpression(t.image);
+  }/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void AllParams()               :
+{/*@bgen(jjtree) AllParameter */
+  ASTAllParameter jjtn000 = new ASTAllParameter(JJTALLPARAMETER);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) AllParameter */
+   try {
+/*@egen*/
+   <ALL_PARAMS>/*@bgen(jjtree)*/
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Field()        :
+{/*@bgen(jjtree) Field */
+  ASTField jjtn000 = new ASTField(JJTFIELD);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token type, clazz, body;
+}
+{/*@bgen(jjtree) Field */
+  try {
+/*@egen*/
+  (FieldAttribute())*
+  (type=<FIELD_CLASS> | type=<FIELD_IDENTIFIER> | type=<FIELD_ANNOTATION> | type=<FIELD_ARRAY_CLASS>| type=<FIELD_INSTANCEOF> | type=<FIELD_TYPEDEF>)
+  {
+    jjtn000.setTypeExpression(type.image);
+  }
+  (clazz=<FIELD_CLASS> | clazz=<FIELD_IDENTIFIER> | clazz=<FIELD_ANNOTATION> | clazz=<FIELD_INSTANCEOF> | clazz=<FIELD_TYPEDEF>)
+  {
+    jjtn000.setClassExpr(clazz.image);
+  }
+  <FIELD_SEPARATOR>
+  (body=<FIELD_IDENTIFIER> | body=<FIELD_ANNOTATION>)/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setFieldExpr(body.image);
+  }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void FieldAttribute()            :
+{/*@bgen(jjtree) Attribute */
+  ASTAttribute jjtn000 = new ASTAttribute(JJTATTRIBUTE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) Attribute */
+  try {
+/*@egen*/
+  [<FIELD_NOT> { jjtn000.not = true; }]
+  (<FIELD_PUBLIC>/*@bgen(jjtree)*/
+                  {
+                    jjtree.closeNodeScope(jjtn000, true);
+                    jjtc000 = false;
+                  }
+/*@egen*/ { jjtn000.setValue(Modifier.PUBLIC); } | <FIELD_PROTECTED>/*@bgen(jjtree)*/
+                                                                             {
+                                                                               jjtree.closeNodeScope(jjtn000, true);
+                                                                               jjtc000 = false;
+                                                                             }
+/*@egen*/ { jjtn000.setValue(Modifier.PROTECTED); } | <FIELD_PRIVATE>/*@bgen(jjtree)*/
+                                                                                                                                         {
+                                                                                                                                           jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                           jjtc000 = false;
+                                                                                                                                         }
+/*@egen*/ { jjtn000.setValue(Modifier.PRIVATE); } | <FIELD_STATIC>/*@bgen(jjtree)*/
+                                                                                                                                                                                                  {
+                                                                                                                                                                                                    jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                    jjtc000 = false;
+                                                                                                                                                                                                  }
+/*@egen*/ { jjtn000.setValue(Modifier.STATIC); } | <FIELD_FINAL>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                         {
+                                                                                                                                                                                                                                                           jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                           jjtc000 = false;
+                                                                                                                                                                                                                                                         }
+/*@egen*/ { jjtn000.setValue(Modifier.FINAL); } | <FIELD_TRANSIENT>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                                                   {
+                                                                                                                                                                                                                                                                                                                     jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                                                     jjtc000 = false;
+                                                                                                                                                                                                                                                                                                                   }
+/*@egen*/ { jjtn000.setValue(Modifier.TRANSIENT); } )/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+
+
+

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/typeExpression.jj
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/typeExpression.jj	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/pointcut/ast/typeExpression.jj	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,876 @@
+/*@bgen(jjtree) Generated By:JJTree: Do not edit this line. C:/cygwin/home/Kabir/sourcecontrol/jboss-aop/aop/src/main/org/jboss/aop/pointcut/ast\typeExpression.jj */
+/*@egen*//**
+ *
+ */
+options {                                                           
+  STATIC=false;
+}
+
+PARSER_BEGIN(TypeExpressionParser)
+package org.jboss.aop.pointcut.ast;
+
+import java.lang.reflect.Modifier;
+
+public class TypeExpressionParser/*@bgen(jjtree)*/implements TypeExpressionParserTreeConstants/*@egen*/ {/*@bgen(jjtree)*/
+  protected JJTTypeExpressionParserState jjtree = new JJTTypeExpressionParserState();
+
+/*@egen*/
+}
+
+PARSER_END(TypeExpressionParser)
+
+
+SKIP :
+{
+  " "
+| "\t"
+}
+
+TOKEN : /* IDENTIFIERS */
+{
+< AND: ["A","a"]["N","n"]["D","d"] >
+| < OR:  ["O","o"]["R","r"] >
+| < HAS: "has(" > : BEHAVIOR
+| < HAS_FIELD: "hasfield(" > : FIELD_DECLARATION
+| < FIELD: "field(" > : FIELD_DECLARATION
+| < CLASS_EXPR: "class(" > : FIELD_DECLARATION
+| < METHOD_EXPR: "method(" > : BEHAVIOR
+| < CONSTRUCTOR_EXPR: "constructor(" > : BEHAVIOR
+| <NOT: "!">
+}
+
+<PARAMS> SKIP :
+{
+  " "
+| "\t"
+}
+
+<PARAMS> TOKEN:
+{
+  < ALL_PARAMS: ".." >
+|
+  < PARAM_INSTANCEOF: "$instanceof{" (<PARAM_IDENTIFIER> | <PARAM_CLASS> | <PARAM_ANNOTATION>) "}">
+|
+  < PARAM_TYPEDEF: "$typedef{" (<PARAM_IDENTIFIER> | <PARAM_CLASS>) "}">
+|
+  < PARAM_CLASS: <PARAM_IDENTIFIER> (<PARAM_DOT> <PARAM_IDENTIFIER>)+ (<PARAM_ARRAY>)*>
+|
+  < PARAM_ARRAY_CLASS: <PARAM_IDENTIFIER> (<PARAM_ARRAY>)+>
+|
+  < PARAM_ANNOTATION: "@" <PARAM_IDENTIFIER> (<DOT> <IDENTIFIER>)*>
+|
+  < PARAM_IDENTIFIER: (<PARAM_WILD_LETTER>)+ >
+|
+  < COMMA: "," >
+|
+  < #PARAM_WILD_LETTER: ["*","_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #PARAM_DOT: ["."] >
+|
+  < #PARAM_ARRAY: "[]" >
+| <PARAMS_CLOSE: ")"> : BEHAVIOR
+}
+
+
+<BEHAVIOR> SKIP :
+{
+  " "
+| "\t"
+}
+
+<BEHAVIOR> TOKEN : /* IDENTIFIERS */
+{
+  < ABSTRACT: "abstract" >
+| < FINAL: "final" >
+| < PRIVATE: "private" >
+| < PROTECTED: "protected" >
+| < PUBLIC: "public" >
+| < STATIC: "static" >
+| < NATIVE: "native" >
+| < SYNCHRONIZED: "synchronized" >
+| < NEW: "new" >
+| < THROWS: "throws" >
+|
+  < INSTANCEOF: "$instanceof{" (<IDENTIFIER> | <CLASS> | <ANNOTATION>) "}">
+|
+  < TYPEDEF: "$typedef{" (<IDENTIFIER> | <CLASS>) "}">
+|
+  < CLASS: <IDENTIFIER> (<DOT> <IDENTIFIER>)+ (<ARRAY>)*>
+|
+  < ARRAY_CLASS: <IDENTIFIER> (<ARRAY>)+>
+|
+  < ANNOTATION: "@" <IDENTIFIER> (<DOT> <IDENTIFIER>)*>
+|
+  < IDENTIFIER: (<WILD_LETTER>)+ >
+|
+  < #WILD_LETTER: ["$","*","_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #DOT: ["."] >
+|
+  < EXCEPTION_SEPERATOR: "," >
+|
+  < #ARRAY: "[]" >
+| < SEPARATOR: "->" >
+| <BEHAVIOR_NOT: "!">
+| < PARAMS_OPEN: "("> : PARAMS
+| <BEHAVIOR_CLOSE: ")"> : DEFAULT
+}
+
+<FIELD_DECLARATION> SKIP :
+{
+  " "
+| "\t"
+}
+
+<FIELD_DECLARATION> TOKEN : /* IDENTIFIERS */
+{
+  < FIELD_ABSTRACT: "abstract" >
+| < FIELD_FINAL: "final" >
+| < FIELD_PRIVATE: "private" >
+| < FIELD_PROTECTED: "protected" >
+| < FIELD_PUBLIC: "public" >
+| < FIELD_STATIC: "static" >
+| < FIELD_TRANSIENT: "transient" >
+| < FIELD_NATIVE: "native" >
+| < FIELD_SYNCHRONIZED: "synchronized" >
+|
+  < FIELD_INSTANCEOF: "$instanceof{" (<FIELD_IDENTIFIER> | <FIELD_CLASS> | <FIELD_ANNOTATION>) "}">
+|
+  < FIELD_TYPEDEF: "$typedef{" (<FIELD_IDENTIFIER> | <FIELD_CLASS>) "}">
+|
+  < FIELD_CLASS: <FIELD_IDENTIFIER> (<FIELD_DOT> <FIELD_IDENTIFIER>)+ (<FIELD_ARRAY>)*>
+|
+  < FIELD_ARRAY_CLASS: <FIELD_IDENTIFIER> (<FIELD_ARRAY>)+>
+|
+  < FIELD_ANNOTATION: "@" <FIELD_IDENTIFIER> (<FIELD_DOT> <FIELD_IDENTIFIER>)* >
+|
+  < FIELD_IDENTIFIER: (<FIELD_WILD_LETTER>)+ >
+|
+  < #FIELD_WILD_LETTER: ["$","*","_","a"-"z","A"-"Z","0"-"9"] >
+|
+  < #FIELD_DOT: ["."] >
+|
+  < #FIELD_ARRAY: "[]" >
+| < FIELD_SEPARATOR: "->" >
+| < FIELD_NOT: "!" >
+| <FIELD_CLOSE: ")"> : DEFAULT
+}
+
+ASTStart Start()        : {/*@bgen(jjtree) Start */
+  ASTStart jjtn000 = new ASTStart(JJTSTART);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Start */
+  try {
+/*@egen*/
+  Expression() <EOF>/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  { return jjtn000; }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Expression()       : {}
+{
+  LOOKAHEAD(234234234) BooleanExpression() | Concrete() |  Not()
+}
+
+void BooleanExpression()          : {/*@bgen(jjtree) Boolean */
+  ASTBoolean jjtn000 = new ASTBoolean(JJTBOOLEAN);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Boolean */
+   try {
+/*@egen*/
+   LOOKAHEAD(3) SubExpression() | LOOKAHEAD(3) CompositeExpression()/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void CompositeExpression()            : {/*@bgen(jjtree) Composite */
+  ASTComposite jjtn000 = new ASTComposite(JJTCOMPOSITE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Composite */
+   try {
+/*@egen*/
+   "(" SubExpression() ")"/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Not()      : {/*@bgen(jjtree) Not */
+  ASTNot jjtn000 = new ASTNot(JJTNOT);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Not */
+   try {
+/*@egen*/
+   <NOT> (LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression())/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void SubExpression()      : {/*@bgen(jjtree) Sub */
+  ASTSub jjtn000 = new ASTSub(JJTSUB);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Sub */
+  try {
+/*@egen*/
+  (LOOKAHEAD(3) Not() | LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression() ) ( And() | Or())+/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void And()      : {/*@bgen(jjtree) And */
+  ASTAnd jjtn000 = new ASTAnd(JJTAND);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) And */
+  try {
+/*@egen*/
+  <AND> (LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression() | LOOKAHEAD(3) Not())/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Or()     : {/*@bgen(jjtree) Or */
+  ASTOr jjtn000 = new ASTOr(JJTOR);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Or */
+  try {
+/*@egen*/
+  <OR> (LOOKAHEAD(3) ConcreteExpression() | LOOKAHEAD(3) CompositeExpression() | LOOKAHEAD(3) Not())/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void ConcreteExpression()       : {}
+{
+  Concrete()
+}
+
+void Concrete()       : {}
+{
+   (LOOKAHEAD(4) Class() | LOOKAHEAD(4) MethodWrapper() | LOOKAHEAD(4) FieldWrapper() | LOOKAHEAD(4) ConstructorWrapper() | LOOKAHEAD(4) Has() | LOOKAHEAD(4) HasField())
+}
+
+void Has()      : {/*@bgen(jjtree) Has */
+  ASTHas jjtn000 = new ASTHas(JJTHAS);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) Has */
+   try {
+/*@egen*/
+   <HAS> (LOOKAHEAD(4) Method() | LOOKAHEAD(4) Constructor()) <BEHAVIOR_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void HasField()           : {/*@bgen(jjtree) HasField */
+  ASTHasField jjtn000 = new ASTHasField(JJTHASFIELD);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/}
+{/*@bgen(jjtree) HasField */
+   try {
+/*@egen*/
+   <HAS_FIELD> Field() <FIELD_CLOSE>/*@bgen(jjtree)*/
+   } catch (Throwable jjte000) {
+     if (jjtc000) {
+       jjtree.clearNodeScope(jjtn000);
+       jjtc000 = false;
+     } else {
+       jjtree.popNode();
+     }
+     if (jjte000 instanceof RuntimeException) {
+       throw (RuntimeException)jjte000;
+     }
+     if (jjte000 instanceof ParseException) {
+       throw (ParseException)jjte000;
+     }
+     throw (Error)jjte000;
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void FieldWrapper()       : {}
+{
+   <FIELD> Field() <FIELD_CLOSE>
+}
+
+void MethodWrapper()       : {}
+{
+   <METHOD_EXPR> Method() <BEHAVIOR_CLOSE>
+}
+
+void ConstructorWrapper()       : {}
+{
+   <CONSTRUCTOR_EXPR> Constructor() <BEHAVIOR_CLOSE>
+}
+
+void Method()         :
+{/*@bgen(jjtree) Method */
+  ASTMethod jjtn000 = new ASTMethod(JJTMETHOD);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token ret, clazz, body;
+}
+{/*@bgen(jjtree) Method */
+  try {
+/*@egen*/
+  (Attribute())* (ret=<CLASS>|ret=<IDENTIFIER>|ret=<ANNOTATION>|ret=<ARRAY_CLASS>|ret=<INSTANCEOF>|ret=<TYPEDEF>) (clazz=<CLASS>|clazz=<IDENTIFIER>|clazz=<ANNOTATION>|clazz=<INSTANCEOF>|clazz=<TYPEDEF>) <SEPARATOR> (body=<IDENTIFIER>|body=<ANNOTATION>) Parameters() Throws()/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setReturnTypeExpression(ret.image);
+    jjtn000.setClassExpression(clazz.image);
+    jjtn000.setMethodExpression(body.image);
+  }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Attribute()            :
+{/*@bgen(jjtree) Attribute */
+  ASTAttribute jjtn000 = new ASTAttribute(JJTATTRIBUTE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) Attribute */
+  try {
+/*@egen*/
+  [<BEHAVIOR_NOT> { jjtn000.not=true; } ]
+  (<PUBLIC>/*@bgen(jjtree)*/
+            {
+              jjtree.closeNodeScope(jjtn000, true);
+              jjtc000 = false;
+            }
+/*@egen*/ { jjtn000.setValue(Modifier.PUBLIC); } | <PROTECTED>/*@bgen(jjtree)*/
+                                                                 {
+                                                                   jjtree.closeNodeScope(jjtn000, true);
+                                                                   jjtc000 = false;
+                                                                 }
+/*@egen*/ { jjtn000.setValue(Modifier.PROTECTED); } | <PRIVATE>/*@bgen(jjtree)*/
+                                                                                                                       {
+                                                                                                                         jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                         jjtc000 = false;
+                                                                                                                       }
+/*@egen*/ { jjtn000.setValue(Modifier.PRIVATE); } | <STATIC>/*@bgen(jjtree)*/
+                                                                                                                                                                          {
+                                                                                                                                                                            jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                            jjtc000 = false;
+                                                                                                                                                                          }
+/*@egen*/ { jjtn000.setValue(Modifier.STATIC); } | <ABSTRACT>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                              {
+                                                                                                                                                                                                                                jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                jjtc000 = false;
+                                                                                                                                                                                                                              }
+/*@egen*/ { jjtn000.setValue(Modifier.ABSTRACT); } | <FINAL>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                 {
+                                                                                                                                                                                                                                                                                   jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                   jjtc000 = false;
+                                                                                                                                                                                                                                                                                 }
+/*@egen*/ { jjtn000.setValue(Modifier.FINAL); } | <NATIVE>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                                                                  {
+                                                                                                                                                                                                                                                                                                                                    jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                                                                    jjtc000 = false;
+                                                                                                                                                                                                                                                                                                                                  }
+/*@egen*/ { jjtn000.setValue(Modifier.NATIVE); } | <SYNCHRONIZED>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                                                                                                                          {
+                                                                                                                                                                                                                                                                                                                                                                                            jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                                                                                                                            jjtc000 = false;
+                                                                                                                                                                                                                                                                                                                                                                                          }
+/*@egen*/ { jjtn000.setValue(Modifier.SYNCHRONIZED); })/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Constructor()              :
+{/*@bgen(jjtree) Constructor */
+  ASTConstructor jjtn000 = new ASTConstructor(JJTCONSTRUCTOR);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token clazz, danew;
+}
+{/*@bgen(jjtree) Constructor */
+  try {
+/*@egen*/
+  (ConstructorAttribute())* (clazz=<CLASS> | clazz=<IDENTIFIER> | clazz=<ANNOTATION> | clazz=<INSTANCEOF> | clazz=<TYPEDEF>)
+  {
+    jjtn000.setClassExpression(clazz.image);
+  }
+  <SEPARATOR> (danew=<NEW> | danew=<ANNOTATION>) Parameters() Throws()/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setNewExpression(danew.image);
+  }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void ConstructorAttribute()            :
+{/*@bgen(jjtree) Attribute */
+  ASTAttribute jjtn000 = new ASTAttribute(JJTATTRIBUTE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) Attribute */
+  try {
+/*@egen*/
+  <PUBLIC>/*@bgen(jjtree)*/
+           {
+             jjtree.closeNodeScope(jjtn000, true);
+             jjtc000 = false;
+           }
+/*@egen*/ { jjtn000.setValue(Modifier.PUBLIC); } | <PROTECTED>/*@bgen(jjtree)*/
+                                                                {
+                                                                  jjtree.closeNodeScope(jjtn000, true);
+                                                                  jjtc000 = false;
+                                                                }
+/*@egen*/ { jjtn000.setValue(Modifier.PROTECTED); } | <PRIVATE>/*@bgen(jjtree)*/
+                                                                                                                      {
+                                                                                                                        jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                        jjtc000 = false;
+                                                                                                                      }
+/*@egen*/ { jjtn000.setValue(Modifier.PRIVATE); }/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+
+void Parameters()       :
+{
+}
+{
+   (LOOKAHEAD(3) <PARAMS_OPEN> AllParams()<PARAMS_CLOSE> | LOOKAHEAD(3) <PARAMS_OPEN> [Parameter() ( <COMMA> Parameter() )* ] <PARAMS_CLOSE>)
+}
+
+void Parameter()            :
+{/*@bgen(jjtree) Parameter */
+  ASTParameter jjtn000 = new ASTParameter(JJTPARAMETER);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token t;
+}
+{/*@bgen(jjtree) Parameter */
+  try {
+/*@egen*/
+  (t=<ALL_PARAMS> | t=<PARAM_CLASS> | t=<PARAM_IDENTIFIER> | t=<PARAM_ARRAY_CLASS> | t=<PARAM_ANNOTATION> | t=<PARAM_TYPEDEF> | t=<PARAM_INSTANCEOF>)/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setTypeExpression(t.image);
+  }/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void AllParams()               :
+{/*@bgen(jjtree) AllParameter */
+  ASTAllParameter jjtn000 = new ASTAllParameter(JJTALLPARAMETER);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) AllParameter */
+   try {
+/*@egen*/
+   <ALL_PARAMS>/*@bgen(jjtree)*/
+   } finally {
+     if (jjtc000) {
+       jjtree.closeNodeScope(jjtn000, true);
+     }
+   }
+/*@egen*/
+}
+
+void Field()        :
+{/*@bgen(jjtree) Field */
+  ASTField jjtn000 = new ASTField(JJTFIELD);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token type, clazz, body;
+}
+{/*@bgen(jjtree) Field */
+  try {
+/*@egen*/
+  (FieldAttribute())*
+  (type=<FIELD_CLASS> | type=<FIELD_IDENTIFIER> | type=<FIELD_ANNOTATION> | type=<FIELD_ARRAY_CLASS>| type=<FIELD_INSTANCEOF> | type=<FIELD_TYPEDEF>)
+  {
+    jjtn000.setTypeExpression(type.image);
+  }
+  (clazz=<FIELD_CLASS> | clazz=<FIELD_IDENTIFIER> | clazz=<FIELD_ANNOTATION> | clazz=<FIELD_INSTANCEOF> | clazz=<FIELD_TYPEDEF>)
+  {
+    jjtn000.setClassExpr(clazz.image);
+  }
+  <FIELD_SEPARATOR>
+  (body=<FIELD_IDENTIFIER> | body=<FIELD_ANNOTATION>)/*@bgen(jjtree)*/
+  {
+    jjtree.closeNodeScope(jjtn000, true);
+    jjtc000 = false;
+  }
+/*@egen*/
+  {
+    jjtn000.setFieldExpr(body.image);
+  }/*@bgen(jjtree)*/
+  } catch (Throwable jjte000) {
+    if (jjtc000) {
+      jjtree.clearNodeScope(jjtn000);
+      jjtc000 = false;
+    } else {
+      jjtree.popNode();
+    }
+    if (jjte000 instanceof RuntimeException) {
+      throw (RuntimeException)jjte000;
+    }
+    if (jjte000 instanceof ParseException) {
+      throw (ParseException)jjte000;
+    }
+    throw (Error)jjte000;
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void FieldAttribute()            :
+{/*@bgen(jjtree) Attribute */
+  ASTAttribute jjtn000 = new ASTAttribute(JJTATTRIBUTE);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+}
+{/*@bgen(jjtree) Attribute */
+  try {
+/*@egen*/
+  [<FIELD_NOT> { jjtn000.not = true; }]
+  (<FIELD_PUBLIC>/*@bgen(jjtree)*/
+                  {
+                    jjtree.closeNodeScope(jjtn000, true);
+                    jjtc000 = false;
+                  }
+/*@egen*/ { jjtn000.setValue(Modifier.PUBLIC); } | <FIELD_PROTECTED>/*@bgen(jjtree)*/
+                                                                             {
+                                                                               jjtree.closeNodeScope(jjtn000, true);
+                                                                               jjtc000 = false;
+                                                                             }
+/*@egen*/ { jjtn000.setValue(Modifier.PROTECTED); } | <FIELD_PRIVATE>/*@bgen(jjtree)*/
+                                                                                                                                         {
+                                                                                                                                           jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                           jjtc000 = false;
+                                                                                                                                         }
+/*@egen*/ { jjtn000.setValue(Modifier.PRIVATE); } | <FIELD_STATIC>/*@bgen(jjtree)*/
+                                                                                                                                                                                                  {
+                                                                                                                                                                                                    jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                    jjtc000 = false;
+                                                                                                                                                                                                  }
+/*@egen*/ { jjtn000.setValue(Modifier.STATIC); } | <FIELD_FINAL>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                         {
+                                                                                                                                                                                                                                                           jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                           jjtc000 = false;
+                                                                                                                                                                                                                                                         }
+/*@egen*/ { jjtn000.setValue(Modifier.FINAL); } | <FIELD_TRANSIENT>/*@bgen(jjtree)*/
+                                                                                                                                                                                                                                                                                                                   {
+                                                                                                                                                                                                                                                                                                                     jjtree.closeNodeScope(jjtn000, true);
+                                                                                                                                                                                                                                                                                                                     jjtc000 = false;
+                                                                                                                                                                                                                                                                                                                   }
+/*@egen*/ { jjtn000.setValue(Modifier.TRANSIENT); } )/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Class()        :
+{/*@bgen(jjtree) Class */
+  ASTClass jjtn000 = new ASTClass(JJTCLASS);
+  boolean jjtc000 = true;
+  jjtree.openNodeScope(jjtn000);
+/*@egen*/
+  Token clazz;
+}
+{/*@bgen(jjtree) Class */
+  try {
+/*@egen*/
+  <CLASS_EXPR>
+  (clazz=<FIELD_CLASS> | clazz=<FIELD_IDENTIFIER> | clazz=<FIELD_ANNOTATION> | clazz=<FIELD_INSTANCEOF> | clazz=<FIELD_TYPEDEF>)
+  {
+    jjtn000.setClassExpr(clazz.image);
+  }
+  <FIELD_CLOSE>/*@bgen(jjtree)*/
+  } finally {
+    if (jjtc000) {
+      jjtree.closeNodeScope(jjtn000, true);
+    }
+  }
+/*@egen*/
+}
+
+void Throws()       : {}
+{
+   (<THROWS> Exception() (<EXCEPTION_SEPERATOR> Exception())*)?
+}
+
+void Exception()           : 
+{/*@bgen(jjtree) Exception */
+   ASTException jjtn000 = new ASTException(JJTEXCEPTION);
+   boolean jjtc000 = true;
+   jjtree.openNodeScope(jjtn000);
+/*@egen*/
+   Token ex;
+}
+{/*@bgen(jjtree) Exception */
+        try {
+/*@egen*/
+	(ex=<CLASS> | ex=<IDENTIFIER>)/*@bgen(jjtree)*/
+        {
+          jjtree.closeNodeScope(jjtn000, true);
+          jjtc000 = false;
+        }
+/*@egen*/
+	{
+		jjtn000.setTypeExpression(ex.image);
+	}/*@bgen(jjtree)*/
+        } finally {
+          if (jjtc000) {
+            jjtree.closeNodeScope(jjtn000, true);
+          }
+        }
+/*@egen*/
+}
+
+
+
+
+

Added: projects/aop/branches/arrays/aop/src/resources/test/array/MANIFEST.MF
===================================================================
--- projects/aop/branches/arrays/aop/src/resources/test/array/MANIFEST.MF	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/resources/test/array/MANIFEST.MF	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1 @@
+Premain-Class: org.jboss.test.aop.array.Agent

Added: projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
===================================================================
--- projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,3 @@
+<aop>
+   <arrayreplacement class="org.jboss.test.aop.array.AOPArrayTestCase"/>
+</aop>
\ No newline at end of file

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class AOPArrayTestCase extends AOPTestWithSetup
+{
+   ClassWithArrayFields obj = new ClassWithArrayFields();
+   
+   public AOPArrayTestCase(String name)
+   {
+      super(name);
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("AOPArrayTestCase");
+      suite.addTestSuite(AOPArrayTestCase.class);
+      return suite;
+   }
+
+   public void testIntWrite()
+   {
+      obj.ifield[1] = 100; 
+   }
+   
+   public void testIntRead()
+   {
+      obj.ifield[1] = 100;
+      int val = obj.ifield[1];
+      assertEquals(100, val);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,314 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.array;
+
+import org.jboss.aop.AspectManager;
+import org.jboss.aop.classpool.AOPClassPool;
+
+import java.lang.instrument.ClassFileTransformer;
+import java.lang.instrument.IllegalClassFormatException;
+import java.security.ProtectionDomain;
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Iterator;
+
+import javassist.CodeConverter;
+import javassist.CtClass;
+import javassist.CtField;
+import javassist.CtMethod;
+import javassist.CtNewMethod;
+import javassist.Modifier;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision: 44099 $
+ */
+public class AOPTransformer implements ClassFileTransformer
+{
+   private static HashMap<String, HashSet<String>> simpleClassFields = new HashMap<String, HashSet<String>>(); 
+//   private static HashMap<String, HashSet<String>> arrayClassFields = new HashMap<String, HashSet<String>>();
+   private static HashSet<String> arrayClasses = new HashSet<String>();
+
+   public static void addArrayClass(String clazz)
+   {
+      arrayClasses.add(clazz);
+   }
+   
+   public static void addSimpleField(String clazz, String field)
+   {
+      addField(simpleClassFields, clazz, field);
+   }
+   
+//   public static void addArrayField(String clazz, String field)
+//   {
+//      addField(arrayClassFields, clazz, field);
+//   }
+   
+   private static void addField(HashMap<String, HashSet<String>> classFields, String clazz, String field)
+   {
+      HashSet<String> fields = classFields.get(clazz); 
+      if (fields == null)
+      {
+         fields = new HashSet<String>();
+         classFields.put(clazz, fields);
+      }
+      
+      fields.add(field);
+   }
+   
+   private static boolean isAdvisableField(HashMap<String, HashSet<String>> classFields, String clazz, String field)
+   {
+      HashSet<String> fields = classFields.get(clazz);
+      if (fields == null)
+      {
+         return false;
+      }
+      
+      return fields.contains(field);
+   }
+   
+   public static boolean isAdvisableSimpleField(CtField field)
+   {
+      return isAdvisableField(simpleClassFields, field.getDeclaringClass().getName(), field.getName());
+   }
+   
+//   public static boolean isAdvisableArrayField(CtField field)
+//   {
+//      return isAdvisableField(arrayClassFields, field.getDeclaringClass().getName(), field.getName());
+//   }
+   
+   public boolean isNonAdvisableClassName(String classname)
+   {
+      return (classname.startsWith("org.jboss.aop") ||
+      classname.endsWith("$aop") ||
+      classname.startsWith("javassist") ||
+      classname.startsWith("org.jboss.util.") ||
+      classname.startsWith("gnu.trove.") ||
+      classname.startsWith("EDU.oswego.cs.dl.util.concurrent.") ||
+      // System classes
+      classname.startsWith("org.apache.crimson") ||
+      classname.startsWith("org.apache.xalan") ||
+      classname.startsWith("org.apache.xml") ||
+      classname.startsWith("org.apache.xpath") ||
+      classname.startsWith("org.ietf.") ||
+      classname.startsWith("org.omg.") ||
+      classname.startsWith("org.w3c.") ||
+      classname.startsWith("org.xml.sax.") ||
+      classname.startsWith("sunw.") ||
+      classname.startsWith("sun.") ||
+      classname.startsWith("java.") ||
+      classname.startsWith("javax.") ||
+      classname.startsWith("com.sun.")
+      );
+   }
+
+   public byte[] transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) throws IllegalClassFormatException
+   {
+      className = className.replace('/', '.');
+      System.out.println("<<< loading " + className + " " + loader);
+      try
+      {
+         if (classBeingRedefined != null || isNonAdvisableClassName(className))
+         {
+            //System.out.println(" ignoring");
+            return null;
+         }
+         //System.out.println(" transforming");
+         return aspectTransform(className, loader, classBeingRedefined, protectionDomain, classfileBuffer);
+      }
+      catch(Exception e)
+      {
+         return null;
+      }
+      finally
+      {
+         //System.out.println("finished " + className + ">>>");
+      }
+   }
+
+   private byte[] aspectTransform(String className, ClassLoader loader, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer)
+   {
+      try
+      {
+         //Make sure that we use the correct classloader, in order to get the correct domain if it is a scoped loader
+         AspectManager manager = AspectManager.instance();
+         AOPClassPool pool = (AOPClassPool) manager.registerClassLoader(loader);
+         
+         CtClass clazz = pool.getLocally(className);
+         
+         createFieldWrappers(pool, clazz);
+         convertReferences(pool, clazz);
+         clazz.debugWriteFile();
+         return clazz.toBytecode();
+         
+      }
+      catch (Exception e)
+      {
+         System.err.println("Error " + e.getMessage());
+         e.printStackTrace();
+         throw new RuntimeException(e);
+      }
+   }
+   
+   private void createFieldWrappers(AOPClassPool pool, CtClass clazz) throws Exception
+   {
+      CtClass objectClass = pool.get("java.lang.Object");
+      CtField[] fields = clazz.getFields();
+      for (int i = 0 ; i < fields.length ; i++)
+      {
+         if (isAdvisableSimpleField(fields[i]))
+         {
+            CtMethod write = CtNewMethod.make(
+                  Modifier.STATIC, 
+                  CtClass.voidType, 
+                  getWriteWrapperName(fields[i]), 
+                  new CtClass[] {objectClass, fields[i].getType()}, 
+                  new CtClass[0],
+                  !Modifier.isStatic(fields[i].getModifiers()) ?
+                        "{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_written = true; ((" + clazz.getName() + ")$1)." + fields[i].getName() + "= $2;}" :
+                        "{" + clazz.getName() + "." + fields[i].getName() + "_written = true; " + clazz.getName() + "." + fields[i].getName() + "= $2;}",
+                  fields[i].getDeclaringClass());
+            fields[i].getDeclaringClass().addMethod(write);
+            
+            CtMethod read = CtNewMethod.make(
+                  Modifier.STATIC, 
+                  fields[i].getType(), 
+                  getReadWrapperName(fields[i]), 
+                  new CtClass[] {objectClass}, 
+                  new CtClass[0],
+                  !Modifier.isStatic(fields[i].getModifiers()) ?
+                        "{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_read = true; return ((" + clazz.getName() + ")$1)." + fields[i].getName() + ";}" :
+                        "{" + clazz.getName() + "." + fields[i].getName() + "_read = true; return " + clazz.getName() + "." + fields[i].getName() + ";}",
+                  fields[i].getDeclaringClass());
+            fields[i].getDeclaringClass().addMethod(read);
+         }
+//         if (isAdvisableArrayField(fields[i]))
+//         {
+//            //Create read method
+//            CtClass componentType = fields[i].getType();
+//            while (componentType.isArray())
+//            {
+//               componentType = componentType.getComponentType();
+//            }
+//
+//            CtClass[] readParameters = new CtClass[3];
+//            readParameters[0] = objectClass;
+//            readParameters[1] = fields[i].getType();
+//            readParameters[2] = CtClass.intType;
+//            StringBuffer readBody = new StringBuffer("{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_read_index=$3; return ((" + clazz.getName() + ")$1)." + fields[i].getName() + "[$3];}");
+//            
+//            System.out.println("READ BODY-----> " + readBody);
+//            
+//            CtMethod read = CtNewMethod.make(
+//                  Modifier.STATIC, 
+//                  componentType, 
+//                  getArrayReadWrapperName(fields[i]), 
+//                  readParameters, 
+//                  new CtClass[0],
+//                  readBody.toString(),
+//                  fields[i].getDeclaringClass());
+//            fields[i].getDeclaringClass().addMethod(read);
+//            
+//            //Create write method
+//            CtClass[] writeParameters = new CtClass[4];
+//            writeParameters[0] = objectClass;
+//            writeParameters[1] = fields[i].getType();
+//            writeParameters[2] = CtClass.intType;
+//            writeParameters[3] = componentType;
+//            StringBuffer writeBody = new StringBuffer("{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_write_index=$3;((" + clazz.getName() + ")$1)." + fields[i].getName() + "_write_value=$4;((" + clazz.getName() + ")$1)." + fields[i].getName() + "[$3]=$4;}");
+//            
+//            System.out.println("WRITE BODY-----> " + writeBody);
+//            CtMethod write = CtNewMethod.make(
+//                  Modifier.STATIC, 
+//                  CtClass.voidType, 
+//                  getArrayWriteWrapperName(fields[i]), 
+//                  writeParameters, 
+//                  new CtClass[0],
+//                  writeBody.toString(),
+//                  fields[i].getDeclaringClass());
+//            fields[i].getDeclaringClass().addMethod(write);
+//         }
+      }
+   }
+   
+   private void convertReferences(AOPClassPool pool, CtClass clazz) throws Exception
+   {
+      boolean replaced = false;
+      Collection refClasses = clazz.getRefClasses();
+      for (Iterator it = refClasses.iterator() ; it.hasNext() ; )
+      {
+         String name = (String)it.next();
+         if (name.equals(clazz.getName()))
+         {
+            continue;
+         }
+         CtClass refClazz = pool.get(name);
+         
+         
+         CtField[] fields = refClazz.getFields();
+         CodeConverter converter = new CodeConverter();
+         for (int i = 0 ; i < fields.length ; i++)
+         {
+            if (isAdvisableSimpleField(fields[i]))
+            {
+               replaced = true;
+               converter.replaceFieldRead(fields[i], refClazz, getReadWrapperName(fields[i]));
+               converter.replaceFieldWrite(fields[i], refClazz, getWriteWrapperName(fields[i]));
+            }
+         }
+         
+         if (arrayClasses.contains(clazz.getName()))
+         {
+            replaced = true;
+            converter.replaceArrayAccess(pool.get(ArrayAdvisor.class.getName()), "arrayRead", "arrayWrite");
+         }
+
+         if (replaced)
+         {
+            clazz.instrument(converter);
+         }
+      }
+   }
+   
+   private String getWriteWrapperName(CtField field)
+   {
+      return "aop$_w_" + field.getName(); 
+   }
+   
+   private String getReadWrapperName(CtField field)
+   {
+      return "aop$_r_" + field.getName(); 
+   }
+
+//   private String getArrayWriteWrapperName(CtField field)
+//   {
+//      return "aop$_array_w_" + field.getName(); 
+//   }
+//   
+//   private String getArrayReadWrapperName(CtField field)
+//   {
+//      return "aop$_array_r_" + field.getName(); 
+//   }
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,46 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.array;
+
+import org.jboss.aop.AspectManager;
+import org.jboss.aop.standalone.StandaloneClassPoolFactory;
+
+import java.lang.instrument.Instrumentation;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision: 46253 $
+ */
+public class Agent
+{
+
+   public static void premain(String agentArgs, Instrumentation inst)
+   {
+      StandaloneClassPoolFactory factory = new StandaloneClassPoolFactory(); 
+      AspectManager.setClassPoolFactory(factory);
+      // necessary for configuration
+      AspectManager.instance();
+      inst.addTransformer(new AOPTransformer());
+   }
+}
\ No newline at end of file

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,157 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayAdvisor
+{
+   public static Object array;
+   public static String value;
+   public static int index;
+   
+   public static void clear()
+   {
+      array = null;
+      value = null;
+      index = -1;
+   }
+   
+   private static void recordAccess(Object array, int index, String value)
+   {
+      ArrayAdvisor.array = array;
+      ArrayAdvisor.index = index;
+      ArrayAdvisor.value = value;
+   }
+   
+   //Write operations
+   public static void arrayWrite(boolean[] array, int index, boolean value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+
+   public static void arrayWrite(short[] array, int index, short value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+
+   public static void arrayWrite(int[] array, int index, int value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(long[] array, int index, long value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(float[] array, int index, float value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(double[] array, int index, double value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(char[] array, int index, char value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+   
+   public static void arrayWrite(Object[] array, int index, Object value)
+   {
+      recordAccess(array, index, String.valueOf(value));
+      array[index] = value; 
+   }
+
+   //Read operations
+   public static boolean arrayRead(boolean[] array, int index)
+   {
+      
+      boolean value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+
+   public static short arrayRead(short[] array, int index)
+   {
+      short value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+
+   public static int arrayRead(int[] array, int index)
+   {
+      int value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static long arrayRead(long[] array, int index)
+   {
+      long value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static float arrayRead(float[] array, int index)
+   {
+      float value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static double arrayRead(double[] array, int index)
+   {
+      double value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static char arrayRead(char[] array, int index)
+   {
+      char value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   public static Object arrayRead(Object[] array, int index)
+   {
+      Object value = array[index];
+      recordAccess(array, index, String.valueOf(value));
+      return value;
+   }
+   
+   
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,91 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.array;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+
+/**
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision: 45977 $
+ */
+public class ArrayTestCase extends AOPTestWithSetup
+{
+   Main main = new Main();
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("ArrayTestCase");
+      suite.addTestSuite(ArrayTestCase.class);
+      return suite;
+   }
+
+   public ArrayTestCase(String name)
+   {
+      super(name);
+      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "field");
+      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "staticfield");
+
+      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFields");
+      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFieldCaller");
+   }
+
+   public void testSimpleField() throws Exception
+   {
+      main.testSimpleField();
+   }
+
+   
+   public void testArrayWrite() throws Exception
+   {
+      main.testArrayWrite();
+   }
+   
+   public void testArrayRead() throws Exception
+   {
+      main.testArrayRead();
+   }
+//   
+//   public void testArrayReadWriteSelf() throws Exception
+//   {
+//      main.testArrayReadWriteSelf();
+//   }
+//
+//   public void testArrayReadWriteFromNonAdvised() throws Exception
+//   {
+//      main.testArrayReadWriteFromNonAdvised();
+//   }
+//
+//   
+//   public void testArrayField() throws Exception
+//   {
+//      main.testArrayField();
+//   }
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,97 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+import java.lang.reflect.Array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithArrayFieldCaller
+{
+   ClassWithArrayFields obj = new ClassWithArrayFields();
+   
+   public void testArrayWrite() throws Exception
+   {
+      ArrayAdvisor.clear();
+      obj.setValue(1, 100);
+      checkStatus(obj.ifield, 1, String.valueOf(100));
+      
+      ArrayAdvisor.clear();
+      obj.ifield[0] = 75;
+      checkStatus(obj.ifield, 0, String.valueOf(75));
+   }
+   
+   public void testArrayRead() throws Exception
+   {
+      obj.ifield[0] = 100;
+      obj.ifield[1] = 200;
+      
+      ArrayAdvisor.clear();
+      int val = obj.getValue(0);
+      if (val != 100) throw new RuntimeException("Wrong val " + 100);
+      checkStatus(obj.ifield, 0, String.valueOf(100));
+      
+      ArrayAdvisor.clear();
+      val = obj.ifield[1];
+      checkStatus(obj.ifield, 1, String.valueOf(200));
+   }
+
+   public void testDifferentTypes() throws Exception
+   {
+//      ArrayAdvisor.clear();
+//      obj.afield[1] = "Hello";
+//      checkStatus(obj.afield, 1, "Hello");
+//      ArrayAdvisor.clear();
+//      Object aval = obj.afield[1];
+//      if (!aval.equals("Hello")) throw new RuntimeException("Wrong val " + aval);
+//      checkStatus(obj.afield, 1, "Hello");
+//      
+//      ArrayAdvisor.clear();
+//      obj.bfield[2] = true;
+//
+//      ArrayAdvisor.clear();
+//      obj.cfield[1] = 'x';
+//      
+//      ArrayAdvisor.clear();
+//      obj.dfield[2] = 69.0d;
+//      
+//      
+//      ArrayAdvisor.clear();
+//      obj.ffield[1] = 3.9f;
+//      
+//      ArrayAdvisor.clear();
+//      obj.lfield[2] = 100L;
+//      
+      ArrayAdvisor.clear();
+      obj.sfield[1] = 5;
+   }
+  
+   private void checkStatus(Object array, int index, String value)
+   {
+      if (array != ArrayAdvisor.array) throw new RuntimeException("Wrong array " + ArrayAdvisor.array);
+      if (index != ArrayAdvisor.index) throw new RuntimeException("Wrong index " + ArrayAdvisor.index);
+      if (!value.equals(ArrayAdvisor.value)) throw new RuntimeException("Wrong string " + ArrayAdvisor.index);
+   }
+}
\ No newline at end of file

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,57 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithArrayFields
+{
+   
+   
+   public Object[] afield = new Object[] {"1", "2", "3"};
+   public boolean[] bfield = new boolean[] {true, false};
+   public char[] cfield = new char[] {'a', 'b', 'c'};
+   public double[] dfield = new double[] {1.5d, 1.9d};
+   public float[] ffield = new float[] {1.5f, 1.9f};
+   public int[] ifield = new int[] {0, 0, 0};
+   public long[] lfield = new long[] {0L, 0L, 0L};
+   public short[] sfield = new short[] {0, 0, 0};
+   
+   
+   public void setValue(int index, int value)
+   {
+      ifield[index] = value;
+   }
+   
+   public int getValue(int index)
+   {
+      return ifield[index];
+   }
+   
+   public void test(short s)
+   {
+      test(s);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,94 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithSimpleFieldCaller
+{
+   ClassWithSimpleFields obj = new ClassWithSimpleFields();
+   public void testSimple() throws Exception
+   {
+      checkStatus("field", false, false);
+      obj.field = false;
+      checkStatus("field", true, false);
+      if (obj.field)
+      {
+         throw new RuntimeException("Should have been false!");
+      }
+      checkStatus("field", true, true);
+      boolean b = obj.field;
+   }
+
+   public void testSimpleNotCalled() throws Exception
+   {
+      obj.nonfield = false;
+      if (obj.nonfield)
+      {
+         throw new RuntimeException("Should have been false!");
+      }
+      boolean b = obj.nonfield;
+   }
+   
+   public void testSimpleStatic() throws Exception
+   {
+      checkStatus("staticfield", false, false);
+      ClassWithSimpleFields.staticfield = false;
+      checkStatus("staticfield", true, false);
+      if (obj.staticfield)
+      {
+         throw new RuntimeException("Should have been false!");
+      }
+      checkStatus("staticfield", true, true);
+      
+      boolean b = ClassWithSimpleFields.staticfield;
+   }
+
+   public void testSimpleStaticNotCalled() throws Exception
+   {
+      ClassWithSimpleFields.staticnonfield = false;
+      if (obj.nonfield)
+      {
+         throw new RuntimeException("Should have been false!");
+      }
+
+      boolean b = ClassWithSimpleFields.staticnonfield;
+   }
+   
+   private void checkStatus(String field, boolean written, boolean read)
+   {
+      if (field.equals("field"))
+      {
+         if (obj.field_written != written) throw new RuntimeException("Expected written " + written);
+         if (obj.field_read != read) throw new RuntimeException("Expected read " + read);
+      }
+      else if (field.equals("staticfield"))
+      {
+         if (obj.staticfield_written != written) throw new RuntimeException("Expected written " + written);
+         if (obj.staticfield_read != read) throw new RuntimeException("Expected read " + read);
+      }
+   }
+   
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,42 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithSimpleFields
+{
+   public boolean field;
+   public boolean field_written;
+   public boolean field_read;
+   
+   public static boolean staticfield;
+   public static boolean staticfield_written;
+   public static boolean staticfield_read;
+   
+   
+   public boolean nonfield;
+   public static boolean staticnonfield;
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java	2006-12-21 12:00:33 UTC (rev 59189)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java	2006-12-21 12:02:00 UTC (rev 59190)
@@ -0,0 +1,68 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class Main
+{
+   public Main()
+   {
+   }
+
+   public static void main(String[] args)throws Exception
+   {
+      Main main = new Main();
+      main.testSimpleField();
+      main.testArrayField();
+   }
+
+   public void testSimpleField() throws Exception
+   {
+      ClassWithSimpleFieldCaller caller = new ClassWithSimpleFieldCaller();
+      caller.testSimple();
+      caller.testSimpleStatic();
+   }
+
+   
+   public void testArrayField() throws Exception
+   {
+//      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
+//      caller.testArray();
+//      caller.testArrayStatic();
+   }
+   
+   public void testArrayWrite() throws Exception
+   {
+      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
+      caller.testArrayWrite();
+   }
+   
+   public void testArrayRead() throws Exception
+   {
+      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
+      caller.testArrayRead();
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 07:02:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 07:02:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59191 -
	branches/Branch_3_2/system/src/main/org/jboss/system
Message-ID: <E1GxMcw-0004fQ-4W@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 07:02:20 -0500 (Thu, 21 Dec 2006)
New Revision: 59191

Modified:
   branches/Branch_3_2/system/src/main/org/jboss/system/BarrierControllerMBean.java
Log:
tidy up

Modified: branches/Branch_3_2/system/src/main/org/jboss/system/BarrierControllerMBean.java
===================================================================
--- branches/Branch_3_2/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 12:02:00 UTC (rev 59190)
+++ branches/Branch_3_2/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 12:02:20 UTC (rev 59191)
@@ -1,97 +1,79 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source.
+ * Copyright 2006, 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.system;
 
+import javax.management.ObjectName;
+
+import org.jboss.mx.util.ObjectNameFactory;
+
 /**
- * MBean interface.
+ * BarrierController MBean interface.
+ * 
+ * @see BarrierController
+ * 
+ * @author <a href="dimitris at jboss.org">Dimitris Andreadis</a>
+ * @version $Revision$
  */
-public interface BarrierControllerMBean extends org.jboss.system.ListenerServiceMBean {
+public interface BarrierControllerMBean extends ListenerServiceMBean
+{
+   // The default object name
+   static final ObjectName OBJECT_NAME = ObjectNameFactory.create("jboss:service=BarrierController");
 
-   //default object name
-   public static final javax.management.ObjectName OBJECT_NAME = org.jboss.mx.util.ObjectNameFactory.create("jboss:service=BarrierController");
+   // Attributes ----------------------------------------------------
+   
+   /** The controlled barrier StateString. */
+   String getBarrierStateString();
+   
+   /** The controlled barrier ObjectName. */
+   void setBarrierObjectName(ObjectName barrierName);   
+   ObjectName getBarrierObjectName();
+   
+   /** The initial state of the barrier. If set, it overrides the internal call
+    * to enableOnStartup() which will never get called. */
+   void setBarrierEnabledOnStartup(Boolean enableOnStartup);
+   Boolean getBarrierEnabledOnStartup();
+   
+   /** The notification subscription handback string that starts the barrier. */
+   void setStartBarrierHandback(String startHandback);
+   String getStartBarrierHandback();
 
-   /**
-    * The controlled barrier StateString.
-    */
-  java.lang.String getBarrierStateString() ;
+   /** The notification subscription handback string that stops the barrier. */
+   void setStopBarrierHandback(String stopHandback);
+   String getStopBarrierHandback();
 
-   /**
-    * The controlled barrier ObjectName.
-    */
-  void setBarrierObjectName(javax.management.ObjectName barrierName) ;
+   /** The ability to dynamically subscribe for notifications. */
+   void setDynamicSubscriptions(Boolean dynamicSubscriptions);
+   Boolean getDynamicSubscriptions();
 
+   // Operations ----------------------------------------------------
+   
    /**
-    * The controlled barrier ObjectName.
-    */
-  javax.management.ObjectName getBarrierObjectName() ;
-
-   /**
-    * The initial state of the barrier. If set, it overrides the internal call to enableOnStartup() which will never get called.
-    */
-  void setBarrierEnabledOnStartup(java.lang.Boolean enableOnStartup) ;
-
-   /**
-    * The initial state of the barrier. Use the value set through setBarrierEnabledOnStartup() otherwise call the internal enableOnStartup() override to make a decision.
-    */
-  java.lang.Boolean getBarrierEnabledOnStartup() ;
-
-   /**
-    * The notification subscription handback string that starts the barrier.
-    */
-  void setStartBarrierHandback(java.lang.String startHandback) ;
-
-   /**
-    * The notification subscription handback string that starts the barrier.
-    */
-  java.lang.String getStartBarrierHandback() ;
-
-   /**
-    * The notification subscription handback string that stops the barrier.
-    */
-  void setStopBarrierHandback(java.lang.String stopHandback) ;
-
-   /**
-    * The notification subscription handback string that stops the barrier.
-    */
-  java.lang.String getStopBarrierHandback() ;
-
-   /**
-    * The ability to dynamically subscribe for notifications.
-    */
-  void setDynamicSubscriptions(java.lang.Boolean dynamicSubscriptions) ;
-
-   /**
-    * The ability to dynamically subscribe for notifications.
-    */
-  java.lang.Boolean getDynamicSubscriptions() ;
-
-   /**
     * Manually start the controlled barrier
     */
-  void startBarrier() ;
+   void startBarrier();
 
    /**
     * Manually stop the controlled barrier
     */
-  void stopBarrier() ;
+   void stopBarrier();
 
 }



From t2-okada at nri.co.jp  Thu Dec 21 07:27:19 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 21 Dec 2006 07:27:19 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet
	...
Message-ID: <E1GxN15-00053V-VE@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/21 07:27:19

  Modified:    java/src/expansion/org/jboss/profiler/exp/view/servlet   
                        Tag: JBossProfiler_Expansion
                        ConcurrencyMetrics.java ExecutionMetrics.java
                        MemoryMetrics.java
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +4 -4      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ConcurrencyMetrics.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrencyMetrics.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ConcurrencyMetrics.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- ConcurrencyMetrics.java	6 Nov 2006 07:36:59 -0000	1.1.2.2
  +++ ConcurrencyMetrics.java	21 Dec 2006 12:27:19 -0000	1.1.2.3
  @@ -193,22 +193,22 @@
                               if(metric==null) continue;
                               if(metricName.equals(MetricName.BLOCK_COUNT)) {
                                   if(metric.getHigh() > bcMax) bcMax = metric.getHigh();
  -                                if(metric.getLow() < bcMin) bcMin = metric.getLow();
  +                                if(metric.getLow() < bcMin || bcc==0) bcMin = metric.getLow();
                                   bcAvg += metric.getAverage();
                                   bcc++;
                               }else if(metricName.equals(MetricName.BLOCK_TIME)) {
                                   if(metric.getHigh() > btMax) btMax = metric.getHigh();
  -                                if(metric.getLow() < btMin) btMin = metric.getLow();
  +                                if(metric.getLow() < btMin || btc==0) btMin = metric.getLow();
                                   btAvg += metric.getAverage();
                                   btc++;
                               }else if(metricName.equals(MetricName.WAIT_COUNT)) {
                                   if(metric.getHigh() > wcMax) wcMax = metric.getHigh();
  -                                if(metric.getLow() < wcMin) wcMin = metric.getLow();
  +                                if(metric.getLow() < wcMin || wcc==0) wcMin = metric.getLow();
                                   wcAvg += metric.getAverage();
                                   wcc++;
                               }else if(metricName.equals(MetricName.WAIT_TIME)) {
                                   if(metric.getHigh() > wtMax) wtMax = metric.getHigh();
  -                                if(metric.getLow() < wtMin) wtMin = metric.getLow();
  +                                if(metric.getLow() < wtMin || wtc==0) wtMin = metric.getLow();
                                   wtAvg += metric.getAverage();
                                   wtc++;
                               }
  
  
  
  1.1.2.3   +1 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionMetrics.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExecutionMetrics.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionMetrics.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- ExecutionMetrics.java	6 Nov 2006 07:36:59 -0000	1.1.2.2
  +++ ExecutionMetrics.java	21 Dec 2006 12:27:19 -0000	1.1.2.3
  @@ -175,7 +175,7 @@
                              metricName.equals(MetricName.REAL_TIME)) {
                               invocationCount += metric.getCount();
                               if(metric.getHigh() > maxTime) maxTime = metric.getHigh();
  -                            if(metric.getLow() < minTime) minTime = metric.getLow();
  +                            if(metric.getLow() < minTime || count==0) minTime = metric.getLow();
                               averageTime += metric.getAverage();
                               count++;
                           }
  
  
  
  1.1.2.3   +1 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/MemoryMetrics.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MemoryMetrics.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/MemoryMetrics.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- MemoryMetrics.java	6 Nov 2006 07:36:59 -0000	1.1.2.2
  +++ MemoryMetrics.java	21 Dec 2006 12:27:19 -0000	1.1.2.3
  @@ -161,7 +161,7 @@
                           ScaleMetric metric = (ScaleMetric)mmap.get(MetricName.MEMORY_USED);
                           if(metric==null) continue;
                           if(metric.getHigh() > max) max = metric.getHigh();
  -                        if(metric.getLow() < min) min = metric.getLow();
  +                        if(metric.getLow() < min || count==0) min = metric.getLow();
                           average += metric.getAverage();
                           count++;
                       }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 07:33:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 07:33:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r59192 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test
Message-ID: <E1GxN76-000587-BM@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 07:33:29 -0500 (Thu, 21 Dec 2006)
New Revision: 59192

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/BaseTest.java
Log:
fix the build after the commons-httpclient update

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/BaseTest.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/BaseTest.java	2006-12-21 12:02:20 UTC (rev 59191)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/BaseTest.java	2006-12-21 12:33:29 UTC (rev 59192)
@@ -37,8 +37,7 @@
  * @author Ben Wang
  * @version $Revision: 1.0
  */
-public abstract class BaseTest
-      extends JBossClusteredTestCase
+public abstract class BaseTest extends JBossClusteredTestCase
 {
    /** 
     * Standard number of ms to pause between http requests
@@ -114,8 +113,17 @@
       assertTrue("Get OK with url: " +url + " responseCode: " +responseCode
         , responseCode == HttpURLConnection.HTTP_OK);
 
-      // Read the response body.
-      byte[] responseBody = method.getResponseBody();
+      byte[] responseBody = null;
+      try
+      {
+         // Read the response body.
+         responseBody = method.getResponseBody();
+      }
+      catch (IOException e)
+      {
+         e.printStackTrace();
+         fail("HttpClient getResponseBody fails." + e.toString());
+      }
 
       // Release the connection.
 //      method.releaseConnection();
@@ -151,8 +159,17 @@
       assertTrue("Should not be OK code with url: " +url + " responseCode: " +responseCode
         , responseCode != HttpURLConnection.HTTP_OK);
 
-      // Read the response body.
-      byte[] responseBody = method.getResponseBody();
+      byte[] responseBody = null;
+      try
+      {
+         // Read the response body.
+         responseBody = method.getResponseBody();
+      }
+      catch (IOException e)
+      {
+         e.printStackTrace();
+         fail("HttpClient getResponseBody fails." + e.toString());
+      }
 
       // Release the connection.
 //      method.releaseConnection();
@@ -190,8 +207,18 @@
       assertTrue("Get OK with url: " +url + " responseCode: " +responseCode
         , responseCode == HttpURLConnection.HTTP_OK);
 
-      // Read the response body.
-      byte[] responseBody = method.getResponseBody();
+      byte[] responseBody = null;
+      try
+      {
+         // Read the response body.
+         responseBody = method.getResponseBody();
+      }
+      catch (IOException e)
+      {
+         e.printStackTrace();
+         fail("HttpClient getResponseBody fails." + e.toString());
+      }
+      
       /* Validate that the attribute was actually seen. An absence of the
          header is treated as true since there are pages used that done't
          add it.



From Shane_Bryzak at symantec.com  Thu Dec 21 08:05:01 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 08:05:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources  ...
Message-ID: <E1GxNbZ-0005nc-Gl@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 08:05:01

  Modified:    examples/seamspace/resources  import.sql
  Log:
  display member's picture on profile page using content servlet
  
  Revision  Changes    Path
  1.5       +5 -1      jboss-seam/examples/seamspace/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/import.sql,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- import.sql	20 Dec 2006 11:40:23 -0000	1.4
  +++ import.sql	21 Dec 2006 13:05:01 -0000	1.5
  @@ -4,3 +4,7 @@
   
   insert into MemberRoles (member_id, role_id) values (1, 1);
   insert into MemberRoles (member_id, role_id) values (1, 2);
  \ No newline at end of file
  +
  +insert into MemberImage (imageid, member_id, contentType, data) values (1, 1, 'image/png', ' !
  !
 4EA7032FA66A6B97A9B4D63AB676C6B9DE56EF73CEFB2679134001BDF37DF380D4F90D
 !
  !
 803C78E746CDAC041114A8E40C181887BA3B20743C56AE50A1B5829600448AF9153934
 !
  !
 855C072AB01A507005B54E5F166E1C3A6AA1A6C5501E02995F04E9B4B7F3FC00A8B0F8
 !
  !
 733C45C81EA1D66EF1F9F1CEBFFDF8FA1A47AD1C74A9BF951ACB4490A359F60B3972C2
 !
  !
 7F5D5C7FA1A767CD9A81B627703A752695EB6C731FDB7C4A0F3D7FB1AC41F7BC9DD592
 !
  !
 ED6DCD0FBDBAAD06E00CBAD3EC858BB3DFC6711FB680995DCF453F5DBEFA7D5540E509
 !
  !
 7FDFC183B3A8ED16FFF795CA77FAA1F29D510720E5D09C1F82D47B58A757F26EA5E5E6
 !
  !
 B6DBBBA16FF8FDF57A974073ED7E75C5EBDA2780516A1935ED1618F4D9B4220526DDA5
 !
  !
 C3A850553534404A6DC8D1EBB43F8EDBD5D76719D00E502C85E0307E668ADFD7656935
 !
  !
 65B73039CF3BF959647911E4581EA5B0C5A04A914652844EAE5355AC11CC2137C43453
 !
  ');
  +
  +update Member set picture_id = 1 where memberid = 1;
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 08:05:01 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 08:05:01 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxNbZ-0005nv-NJ@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 08:05:01

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace     
                        ContentAction.java ContentServlet.java Member.java
                        MemberImage.java ProfileAction.java
  Log:
  display member's picture on profile page using content servlet
  
  Revision  Changes    Path
  1.2       +1 -1      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ContentAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ContentAction.java	21 Dec 2006 08:16:41 -0000	1.1
  +++ ContentAction.java	21 Dec 2006 13:05:01 -0000	1.2
  @@ -17,7 +17,7 @@
      {
         MemberImage img = entityManager.find(MemberImage.class, imageId);
   
  -      if (img != null && SeamSecurityManager.hasPermission("MemberImage", "view", img))      
  +      if (img != null)// && SeamSecurityManager.hasPermission("memberImage", "view", img))      
            return img;
         else
            return null;
  
  
  
  1.3       +5 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ContentServlet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ContentServlet.java	21 Dec 2006 08:16:41 -0000	1.2
  +++ ContentServlet.java	21 Dec 2006 13:05:01 -0000	1.3
  @@ -9,6 +9,11 @@
   
   import org.jboss.seam.Component;
   
  +/**
  + * Serves images and other member content
  + * 
  + * @author Shane Bryzak
  + */
   public class ContentServlet extends HttpServlet
   {
      private static final long serialVersionUID = -8461940507242022217L;
  
  
  
  1.9       +1 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Member.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- Member.java	21 Dec 2006 05:34:47 -0000	1.8
  +++ Member.java	21 Dec 2006 13:05:01 -0000	1.9
  @@ -98,6 +98,7 @@
      }
   
      @OneToOne(fetch = FetchType.LAZY)
  +   @JoinColumn(name = "PICTURE_ID")
      public MemberImage getPicture()
      {
         return picture;
  
  
  
  1.3       +2 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MemberImage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MemberImage.java	21 Dec 2006 05:34:47 -0000	1.2
  +++ MemberImage.java	21 Dec 2006 13:05:01 -0000	1.3
  @@ -4,6 +4,7 @@
   
   import javax.persistence.Entity;
   import javax.persistence.Id;
  +import javax.persistence.JoinColumn;
   import javax.persistence.ManyToOne;
   
   import org.jboss.seam.annotations.Name;
  @@ -31,6 +32,7 @@
      }
      
      @ManyToOne
  +   @JoinColumn(name = "MEMBER_ID")
      public Member getMember()
      {
         return member;
  
  
  
  1.3       +1 -1      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProfileAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ProfileAction.java	21 Dec 2006 05:34:47 -0000	1.2
  +++ ProfileAction.java	21 Dec 2006 13:05:01 -0000	1.3
  @@ -19,7 +19,7 @@
      @RequestParameter
      private String name;
   
  -   @Out
  +   @Out(required = false)
      private Member selectedMember;
      
      @In(create=true)
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 08:05:01 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 08:05:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view  ...
Message-ID: <E1GxNbZ-0005o2-V3@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 08:05:01

  Modified:    examples/seamspace/view  profile.xhtml
  Log:
  display member's picture on profile page using content servlet
  
  Revision  Changes    Path
  1.2       +1 -8      jboss-seam/examples/seamspace/view/profile.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: profile.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/profile.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- profile.xhtml	20 Dec 2006 11:40:25 -0000	1.1
  +++ profile.xhtml	21 Dec 2006 13:05:01 -0000	1.2
  @@ -11,15 +11,8 @@
   			
   			  <div class="errors"><h:messages globalOnly="true"/></div> 
   			  
  +			  <h:graphicImage value="/content/images?id=#{selectedMember.picture.imageId}"/>
   			  
  -			  
  -			  <s:div rendered="#{s:hasRole('user')}">
  -			    You are a member of the 'user' role.
  -			  </s:div>
  -			  
  -			  <s:div rendered="#{s:hasRole('admin')}">
  -			    You are a member of the 'admin' role.
  -			  </s:div>  
         </div>
       
       </ui:define>
  
  
  


From msurtani at jboss.com  Thu Dec 21 08:11:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 08:11:57 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxNiH-0005xP-8Q@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 08:11:57

  Modified:    src/org/jboss/cache  NodeImpl.java
  Log:
  updated tostring
  
  Revision  Changes    Path
  1.29      +4 -1      JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- NodeImpl.java	20 Dec 2006 22:27:08 -0000	1.28
  +++ NodeImpl.java	21 Dec 2006 13:11:57 -0000	1.29
  @@ -443,6 +443,9 @@
      public String toString()
      {
         StringBuffer sb = new StringBuffer();
  +      if (deleted)
  +         sb.append("Node (deleted) [ ").append(fqn);
  +      else
         sb.append("Node[ ").append(fqn);
         synchronized (this)
         {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 09:08:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 09:08:26 -0500
Subject: [jboss-cvs] JBossAS SVN: r59193 - in
	projects/microcontainer/trunk/kernel/src:
	main/org/jboss/test/kernel/junit
	tests/org/jboss/test/kernel/deployment/test
Message-ID: <E1GxOaw-00070B-A9@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-21 09:08:20 -0500 (Thu, 21 Dec 2006)
New Revision: 59193

Removed:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/ManualMicrocontainerTestDelegate.java
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/AnnotatedLifecycleTestCase.java
Log:
Move the manual test helper into the main test class.

Deleted: projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/ManualMicrocontainerTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/ManualMicrocontainerTestDelegate.java	2006-12-21 12:33:29 UTC (rev 59192)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/ManualMicrocontainerTestDelegate.java	2006-12-21 14:08:20 UTC (rev 59193)
@@ -1,45 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.test.kernel.junit;
-
-import org.jboss.kernel.spi.dependency.KernelControllerContext;
-import org.jboss.dependency.spi.ControllerState;
-import org.jboss.dependency.spi.Controller;
-
-/**
- * @author <a href="mailto:ales.justin at gmail.com">Ales Justin</a>
- */
-public class ManualMicrocontainerTestDelegate extends MicrocontainerTestDelegate
-{
-   public ManualMicrocontainerTestDelegate(Class clazz)
-         throws Exception
-   {
-      super(clazz);
-   }
-
-   public void change(KernelControllerContext context, ControllerState requied) throws Throwable
-   {
-      Controller controller = kernel.getController();
-      controller.change(context, requied);
-   }
-
-}

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java	2006-12-21 12:33:29 UTC (rev 59192)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTest.java	2006-12-21 14:08:20 UTC (rev 59193)
@@ -104,7 +104,7 @@
    {
       return getControllerContext(name, ControllerState.INSTALLED);
    }
-   
+
    /**
     * Get a context
     * 
@@ -117,6 +117,19 @@
    {
       return getMCDelegate().getControllerContext(name, state);
    }
+
+   /**
+    * Change the context to the given state
+    * 
+    * @param context the context
+    * @param required the required state
+    * @return the actual state
+    * @throws Throwable for any error
+    */
+   public ControllerState change(KernelControllerContext context, ControllerState required) throws Throwable
+   {
+      return getMCDelegate().change(context, required);
+   }
    
    /**
     * Deploy a url

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java	2006-12-21 12:33:29 UTC (rev 59192)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/test/kernel/junit/MicrocontainerTestDelegate.java	2006-12-21 14:08:20 UTC (rev 59193)
@@ -23,6 +23,7 @@
 
 import java.net.URL;
 
+import org.jboss.dependency.spi.Controller;
 import org.jboss.dependency.spi.ControllerState;
 import org.jboss.kernel.Kernel;
 import org.jboss.kernel.plugins.bootstrap.AbstractBootstrap;
@@ -151,8 +152,23 @@
          throw new IllegalStateException("Bean not found " + name + " at state " + state);
       return context;
    }
-   
+
    /**
+    * Change the context to the given state
+    * 
+    * @param context the context
+    * @param required the required state
+    * @return the actual state
+    * @throws Throwable for any error
+    */
+   protected ControllerState change(KernelControllerContext context, ControllerState required) throws Throwable
+   {
+      Controller controller = kernel.getController();
+      controller.change(context, required);
+      return context.getState();
+   }
+
+   /**
     * Validate
     * 
     * @throws Exception for any error

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/AnnotatedLifecycleTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/AnnotatedLifecycleTestCase.java	2006-12-21 12:33:29 UTC (rev 59192)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/AnnotatedLifecycleTestCase.java	2006-12-21 14:08:20 UTC (rev 59193)
@@ -21,14 +21,12 @@
 */
 package org.jboss.test.kernel.deployment.test;
 
+import junit.framework.Test;
+
 import org.jboss.dependency.spi.ControllerState;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
-import org.jboss.test.AbstractTestDelegate;
 import org.jboss.test.kernel.deployment.support.AnnotatedLifecycleBean;
-import org.jboss.test.kernel.junit.ManualMicrocontainerTestDelegate;
 
-import junit.framework.Test;
-
 /**
  * @author <a href="mailto:ales.justin at gmail.com">Ales Justin</a>
  */
@@ -47,47 +45,38 @@
       return suite(AnnotatedLifecycleTestCase.class);
    }
 
-   public void testAnnotetedLifecycle() throws Throwable
+   public void testAnnotatedLifecycle() throws Throwable
    {
       AnnotatedLifecycleBean target;
 
       KernelControllerContext context = getControllerContext(BEAN_NAME, ControllerState.NOT_INSTALLED);
 
-      ManualMicrocontainerTestDelegate delegate = (ManualMicrocontainerTestDelegate) getMCDelegate();
-
-      delegate.change(context, ControllerState.CREATE);
+      change(context, ControllerState.CREATE);
       target = (AnnotatedLifecycleBean) context.getTarget();
       assertTrue(target.isCreate());
       assertFalse(target.isStart());
       assertFalse(target.isStop());
       assertFalse(target.isDestroy());
 
-      delegate.change(context, ControllerState.START);
+      change(context, ControllerState.START);
       target = (AnnotatedLifecycleBean) context.getTarget();
       assertTrue(target.isCreate());
       assertTrue(target.isStart());
       assertFalse(target.isStop());
       assertFalse(target.isDestroy());
 
-      delegate.change(context, ControllerState.CREATE);
+      change(context, ControllerState.CREATE);
       target = (AnnotatedLifecycleBean) context.getTarget();
       assertTrue(target.isCreate());
       assertFalse(target.isStart());
       assertTrue(target.isStop());
       assertFalse(target.isDestroy());
 
-      delegate.change(context, ControllerState.CONFIGURED);
+      change(context, ControllerState.CONFIGURED);
       target = (AnnotatedLifecycleBean) context.getTarget();
       assertFalse(target.isCreate());
       assertFalse(target.isStart());
       assertTrue(target.isStop());
       assertTrue(target.isDestroy());
-
    }
-
-   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
-   {
-      return new ManualMicrocontainerTestDelegate(clazz);
-   }
-
 }



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 09:09:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 09:09:56 -0500
Subject: [jboss-cvs] JBossAS SVN: r59194 - in
	projects/microcontainer/trunk/managed: . src
	src/main/org/jboss/managed src/main/org/jboss/managed/api
	src/main/org/jboss/managed/plugins
	src/main/org/jboss/managed/plugins/advice src/resources
	src/resources/tests src/resources/tests/org
	src/resources/tests/org/jboss src/resources/tests/org/jboss/test
	src/resources/tests/org/jboss/test/managed
	src/tests/org/jboss/test src/tests/org/jboss/test/managed
	src/tests/org/jboss/test/managed/mock
Message-ID: <E1GxOcO-00070U-I0@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-21 09:09:44 -0500 (Thu, 21 Dec 2006)
New Revision: 59194

Added:
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/TraceAdvice.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperAdvice.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperIterator.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperSet.java
   projects/microcontainer/trunk/managed/src/resources/
   projects/microcontainer/trunk/managed/src/resources/tests/
   projects/microcontainer/trunk/managed/src/resources/tests/org/
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedAdvices-aop.xml
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedObjectWrapper-aop.xml
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedPropertyWrapper-aop.xml
   projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedTest-aop.xml
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedAllTestSuite.java
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTest.java
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDOMFields.java
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockTest.java
Removed:
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/
Modified:
   projects/microcontainer/trunk/managed/.classpath
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java
Log:
Update the managed api to implement the AOP structure.
Need to implement the advices for interaction with the profile service and server.

Modified: projects/microcontainer/trunk/managed/.classpath
===================================================================
--- projects/microcontainer/trunk/managed/.classpath	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/.classpath	2006-12-21 14:09:44 UTC (rev 59194)
@@ -2,13 +2,19 @@
 <classpath>
 	<classpathentry kind="src" path="src/main"/>
 	<classpathentry kind="src" path="src/tests"/>
+	<classpathentry kind="lib" path="src/resources/tests"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/aop/lib/jboss-aop-jdk50.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/oswego-concurrent/lib/concurrent.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/javassist/lib/javassist.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/junit/lib/junit.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/apache-log4j/lib/log4j.jar"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/metatype"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/container"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -22,8 +22,6 @@
 package org.jboss.managed.api;
 
 import java.io.Serializable;
-import java.util.Collections;
-import java.util.HashSet;
 import java.util.Set;
 
 /**
@@ -32,40 +30,14 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision: 1.1 $
  */
-public class ManagedObject implements Serializable
+public interface ManagedObject extends Serializable
 {
-   /** The serialVersionUID */
-   private static final long serialVersionUID = -2588364350006686542L;
-
-   /** The properties */
-   private Set<ManagedProperty> properties;
-   
    /**
-    * Create a new ManagedObject
-    * 
-    * @param properties the properties 
-    */
-   public ManagedObject(Set<ManagedProperty> properties)
-   {
-      if (properties == null)
-         properties = Collections.emptySet();
-      this.properties = properties;
-   }
-   
-   // TODO identity, deployment info, scope, etc.
-   
-   /**
     * Get the property names
     * 
     * @return the property names
     */
-   public Set<String> getPropertyNames()
-   {
-      Set<String> result = new HashSet<String>(properties.size());
-      for (ManagedProperty property : properties)
-         result.add(property.getName());
-      return result;
-   }
+   Set<String> getPropertyNames();
    
    /**
     * Get a property
@@ -73,42 +45,12 @@
     * @param name the name
     * @return the property
     */
-   public ManagedProperty getProperty(String name)
-   {
-      if (name == null)
-         throw new IllegalArgumentException("Null name");
-
-      for (ManagedProperty property : properties)
-      {
-         if (name.equals(property.getName()))
-            return property;
-      }
-      return null;
-   }
+   ManagedProperty getProperty(String name);
    
    /**
     * Get the properties
     * 
     * @return the properties
     */
-   public Set<ManagedProperty> getProperties()
-   {
-      return Collections.unmodifiableSet(properties);
-   }
-
-   /**
-    * Get the real properties
-    * 
-    * @return the properties
-    */
-   protected Set<ManagedProperty> getManagedProperties()
-   {
-      return properties;
-   }
-   
-   // TODO state, lifecycle, on-demand, etc.
-   
-   // TODO statistics
-   
-   // TODO listener api
+   Set<ManagedProperty> getProperties();
 }

Modified: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedProperty.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -21,15 +21,11 @@
 */
 package org.jboss.managed.api;
 
-import java.io.IOException;
-import java.io.ObjectInputStream;
-import java.io.ObjectStreamField;
 import java.io.Serializable;
 import java.util.Set;
 
 import org.jboss.metatype.api.types.MetaType;
 import org.jboss.metatype.api.values.MetaValue;
-import org.jboss.metatype.api.values.SimpleValue;
 
 /**
  * ManagedProperty.
@@ -37,183 +33,95 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision: 1.1 $
  */
-public class ManagedProperty implements Serializable
+public interface ManagedProperty extends Serializable
 {
-   /** The serialVersionUID */
-   private static final long serialVersionUID = 2268454772998030799L;
-   
-   /** The serialized form */
-   private static final ObjectStreamField[] serialPersistentFields =
-      new ObjectStreamField[]
-      {
-         new ObjectStreamField("fields", Fields.class),
-      };
-
-   /** The fields */
-   private Fields fields;
-
-   /** The property name */
-   private transient String name;
-   
    /**
-    * Create a new ManagedProperty.
+    * Get the managed object
     * 
-    * @param fields the fields
-    * @throws IllegalArgumentException for null fields
+    * @return the managed object
     */
-   public ManagedProperty(Fields fields)
-   {
-      if (fields == null)
-         throw new IllegalArgumentException("Null fields");
-      this.fields = fields;
-      
-      name = getField(Fields.NAME, String.class);
-      if (name == null)
-         throw new IllegalArgumentException("No " + Fields.NAME + " in fields");
-   }
+   ManagedObject getManagedObject();
    
    /**
     * Get the fields
     * 
     * @return the fields
     */
-   public Fields getFields()
-   {
-      return fields;
-   }
+   Fields getFields();
    
    /**
     * Get a field
     *
-    * TODO general reconstruction code for metatypes
     * @param <T> the expected type
     * @param fieldName the field name
     * @param expected the expected type
     * @return the value
     */
-   @SuppressWarnings("unchecked")
-   public <T> T getField(String fieldName, Class<T> expected)
-   {
-      if (fieldName == null)
-         throw new IllegalArgumentException("Null field name");
-      if (expected == null)
-         throw new IllegalArgumentException("Null expected type");
-      
-      Serializable field = getFields().getField(fieldName);
-      
-      if (field == null)
-         return null;
-
-      if (expected.isInstance(field))
-         return expected.cast(field);
-      
-      if (field instanceof SimpleValue)
-      {
-         SimpleValue value = (SimpleValue) field;
-         Object result = value.getValue();
-         if (result == null)
-            return null;
-         return expected.cast(result);
-      }
-      
-      throw new IllegalStateException("Field " + fieldName + " with value " + field + " is  a of the expected type: " + expected.getName());
-   }
+   <T> T getField(String fieldName, Class<T> expected);
    
    /**
     * Set a field
     *
-    * TODO metaType stuff
     * @param fieldName the field name
     * @param value the value
     */
-   public void setField(String fieldName, Serializable value)
-   {
-      if (fieldName == null)
-         throw new IllegalArgumentException("Null field name");
-      
-      getFields().setField(fieldName, value);
-   }
+   void setField(String fieldName, Serializable value);
    
    /**
     * Get the property's name
     * 
     * @return the property's name
     */
-   public String getName()
-   {
-      return name;
-   }
+   String getName();
 
    /**
     * Get the description
     * 
     * @return the description
     */
-   public String getDescription()
-   {
-      return getField(Fields.DESCRIPTION, String.class);
-   }
+   String getDescription();
 
    /**
     * Get the type
     * 
     * @return the type
     */
-   public MetaType getMetaType()
-   {
-      return getField(Fields.META_TYPE, MetaType.class);
-   }
+   MetaType getMetaType();
 
    /**
     * Get the value
     * 
     * @return the value
     */
-   public Object getValue()
-   {
-      return getField(Fields.VALUE, Object.class);
-   }
+   Object getValue();
 
    /**
     * Set the value
     * 
     * @param value the value
     */
-   public void setValue(Serializable value)
-   {
-      setField(Fields.VALUE, value);
-   }
+   void setValue(Serializable value);
 
    /**
     * Get the legal values
     * 
     * @return the legal values
     */
-   @SuppressWarnings("unchecked")
-   public Set<MetaValue> getLegalValues()
-   {
-      return getField(Fields.LEGAL_VALUES, Set.class);
-   }
+   Set<MetaValue> getLegalValues();
 
    /**
     * Get the minimum value
     * 
     * @return the minimum value
     */
-   public MetaValue getMinimumValue()
-   {
-      return getField(Fields.MINIMUM_VALUE, MetaValue.class);
-   }
+   Comparable getMinimumValue();
 
    /**
     * Get the miximum value
     * 
     * @return the maximum value
     */
-   public MetaValue getMaximumValue()
-   {
-      return getField(Fields.MAXIMUM_VALUE, MetaValue.class);
-   }
+   Comparable getMaximumValue();
 
    /**
     * Check whether this is a valid value
@@ -221,77 +129,12 @@
     * @param value the value
     * @return null for a valid value, an error message otherwise
     */
-   public String checkValidValue(Serializable value)
-   {
-      // TODO check min/max/etc.
-      return null;
-   }
+   String checkValidValue(Serializable value);
    
    /**
     * Whether the property is mandatory
     * 
     * @return true when mandatory
     */
-   public boolean isMandatory()
-   {
-      Boolean result = getField(Fields.MANDATORY, Boolean.class);
-      if (result == null)
-         return false;
-      return result.booleanValue();
-   }
-
-   @Override
-   public String toString()
-   {
-      return "ManagedProperty{" + name + "}"; 
-   }
-
-   @Override
-   public int hashCode()
-   {
-      return name.hashCode(); 
-   }
-
-   @Override
-   public boolean equals(Object obj)
-   {
-      if (obj == this)
-         return true;
-      if (obj == null || obj instanceof ManagedProperty == false)
-         return false;
-      
-      ManagedProperty other = (ManagedProperty) obj;
-      return name.equals(other.getName());
-   }
-   
-   /**
-    * Create a new ManagedProperty.
-    * 
-    * @param fields the fields
-    * @throws IllegalArgumentException for null fields
-    */
-   private void init(Fields fields)
-   {
-      if (fields == null)
-         throw new IllegalArgumentException("Null fields");
-      this.fields = fields;
-      
-      name = getField(Fields.NAME, String.class);
-      if (name == null)
-         throw new IllegalArgumentException("No " + Fields.NAME + " in fields");
-   }
-
-   private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
-   {
-      ObjectInputStream.GetField getField = in.readFields();
-      Fields fields = (Fields) getField.get("fields", null);
-      try
-      {
-         init(fields);
-      }
-      catch (Exception e)
-      {
-         throw new RuntimeException("Error deserializing managed property", e);
-      }
-   }
+   boolean isMandatory();
 }

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,82 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.plugins;
+
+import java.util.Collections;
+import java.util.HashSet;
+import java.util.Set;
+
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.managed.api.ManagedProperty;
+
+/**
+ * ManagedObjectImpl.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ManagedObjectImpl implements ManagedObject
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -2588364350006686542L;
+
+   /** The properties */
+   private Set<ManagedProperty> properties;
+   
+   /**
+    * Create a new ManagedObjectImpl
+    * 
+    * @param properties the properties 
+    */
+   public ManagedObjectImpl(Set<ManagedProperty> properties)
+   {
+      if (properties == null)
+         properties = Collections.emptySet();
+      this.properties = properties;
+   }
+   
+   public Set<String> getPropertyNames()
+   {
+      Set<String> result = new HashSet<String>(properties.size());
+      for (ManagedProperty property : properties)
+         result.add(property.getName());
+      return result;
+   }
+   
+   public ManagedProperty getProperty(String name)
+   {
+      if (name == null)
+         throw new IllegalArgumentException("Null name");
+      
+      for (ManagedProperty property : properties)
+      {
+         if (name.equals(property.getName()))
+            return property;
+      }
+      return null;
+   }
+   
+   public Set<ManagedProperty> getProperties()
+   {
+      return properties;
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,247 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.plugins;
+
+import java.io.IOException;
+import java.io.ObjectInputStream;
+import java.io.ObjectStreamField;
+import java.io.Serializable;
+import java.util.Set;
+
+import org.jboss.managed.api.Fields;
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.managed.api.ManagedProperty;
+import org.jboss.metatype.api.types.MetaType;
+import org.jboss.metatype.api.values.MetaValue;
+import org.jboss.metatype.api.values.SimpleValue;
+
+/**
+ * ManagedProperty.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class ManagedPropertyImpl implements ManagedProperty
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 2268454772998030799L;
+   
+   /** The serialized form */
+   private static final ObjectStreamField[] serialPersistentFields =
+      new ObjectStreamField[]
+      {
+         new ObjectStreamField("managedObject", ManagedObjectImpl.class),
+         new ObjectStreamField("fields", Fields.class),
+      };
+
+   /** The managed object */
+   private ManagedObjectImpl managedObject;
+   
+   /** The fields */
+   private Fields fields;
+
+   /** The property name */
+   private transient String name;
+   
+   /**
+    * Create a new ManagedProperty.
+    * 
+    * @param managedObject the managed object
+    * @param fields the fields
+    * @throws IllegalArgumentException for null fields
+    */
+   public ManagedPropertyImpl(ManagedObjectImpl managedObject, Fields fields)
+   {
+      init(managedObject, fields);
+   }
+   
+   public ManagedObject getManagedObject()
+   {
+      return managedObject;
+   }
+
+   public Fields getFields()
+   {
+      return fields;
+   }
+   
+   // TODO general reconstruction code for metatypes
+   @SuppressWarnings("unchecked")
+   public <T> T getField(String fieldName, Class<T> expected)
+   {
+      if (fieldName == null)
+         throw new IllegalArgumentException("Null field name");
+      if (expected == null)
+         throw new IllegalArgumentException("Null expected type");
+      
+      Serializable field = getFields().getField(fieldName);
+      
+      if (field == null)
+         return null;
+
+      if (expected.isInstance(field))
+         return expected.cast(field);
+      
+      if (field instanceof SimpleValue)
+      {
+         SimpleValue value = (SimpleValue) field;
+         Object result = value.getValue();
+         if (result == null)
+            return null;
+         return expected.cast(result);
+      }
+      
+      throw new IllegalStateException("Field " + fieldName + " with value " + field + " is  a of the expected type: " + expected.getName());
+   }
+   
+   // TODO metaType stuff
+   public void setField(String fieldName, Serializable value)
+   {
+      if (fieldName == null)
+         throw new IllegalArgumentException("Null field name");
+      
+      getFields().setField(fieldName, value);
+   }
+   
+   public String getName()
+   {
+      return name;
+   }
+
+   public String getDescription()
+   {
+      return getField(Fields.DESCRIPTION, String.class);
+   }
+
+   public MetaType getMetaType()
+   {
+      return getField(Fields.META_TYPE, MetaType.class);
+   }
+
+   public Object getValue()
+   {
+      return getField(Fields.VALUE, Object.class);
+   }
+
+   public void setValue(Serializable value)
+   {
+      setField(Fields.VALUE, value);
+   }
+
+   @SuppressWarnings("unchecked")
+   public Set<MetaValue> getLegalValues()
+   {
+      return getField(Fields.LEGAL_VALUES, Set.class);
+   }
+
+   public Comparable getMinimumValue()
+   {
+      return getField(Fields.MINIMUM_VALUE, Comparable.class);
+   }
+
+   public Comparable getMaximumValue()
+   {
+      return getField(Fields.MAXIMUM_VALUE, Comparable.class);
+   }
+
+   public String checkValidValue(Serializable value)
+   {
+      // TODO check min/max/etc.
+      return null;
+   }
+   
+   public boolean isMandatory()
+   {
+      Boolean result = getField(Fields.MANDATORY, Boolean.class);
+      if (result == null)
+         return false;
+      return result.booleanValue();
+   }
+
+   @Override
+   public String toString()
+   {
+      return "ManagedProperty{" + name + "}"; 
+   }
+
+   @Override
+   public int hashCode()
+   {
+      return name.hashCode(); 
+   }
+
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null || obj instanceof ManagedProperty == false)
+         return false;
+      
+      ManagedProperty other = (ManagedProperty) obj;
+      return getName().equals(other.getName()) && getManagedObject().equals(other.getManagedObject()) ;
+   }
+   
+   /**
+    * Initialise a ManagedPropertyImpl.
+    * 
+    * @param managedObject the managed object
+    * @param fields the fields
+    * @throws IllegalArgumentException for null fields
+    */
+   private void init(ManagedObjectImpl managedObject, Fields fields)
+   {
+      if (managedObject == null)
+         throw new IllegalArgumentException("Null managed object");
+      if (fields == null)
+         throw new IllegalArgumentException("Null fields");
+      
+      this.managedObject = managedObject;
+      this.fields = fields;
+      
+      name = getField(Fields.NAME, String.class);
+      if (name == null)
+         throw new IllegalArgumentException("No " + Fields.NAME + " in fields");
+   }
+
+   /**
+    * Read from a stream
+    * 
+    * @param in the stream
+    * @throws IOException for IO problem
+    * @throws ClassNotFoundException for a classloading problem
+    */
+   private void readObject(ObjectInputStream in) throws IOException, ClassNotFoundException
+   {
+      ObjectInputStream.GetField getField = in.readFields();
+      ManagedObjectImpl managedObject = (ManagedObjectImpl) getField.get("managedObject", null);
+      Fields fields = (Fields) getField.get("fields", null);
+      try
+      {
+         init(managedObject, fields);
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Error deserializing managed property", e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/TraceAdvice.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/TraceAdvice.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/TraceAdvice.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,92 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.plugins.advice;
+
+import java.util.Arrays;
+
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.logging.Logger;
+
+/**
+ * TraceAdvice.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class TraceAdvice
+{
+   /** The log */
+   private static final Logger log = Logger.getLogger(TraceAdvice.class);
+   
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+      boolean trace = log.isTraceEnabled();
+      if (trace)
+         logMethod(false, invocation, null, null);
+      
+      Throwable e = null;
+      Object result = null;
+      try
+      {
+         result = invocation.invokeNext();
+         return result;
+      }
+      catch (Throwable t)
+      {
+         e = t;
+         throw t;
+      }
+      finally
+      {
+         logMethod(true, invocation, result, e);
+      }
+   }
+   
+   private void logMethod(boolean beforeAfter, Invocation invocation, Object result, Throwable t)
+   {
+      MethodInvocation mi = (MethodInvocation) invocation;
+      StringBuilder builder = new StringBuilder();
+      Object target = mi.getTargetObject();
+      builder.append(target.getClass().getSimpleName());
+      builder.append('@');
+      builder.append(System.identityHashCode(target));
+      if (beforeAfter == false)
+         builder.append(" before ");
+      else
+         builder.append(" after  ");
+      builder.append(mi.getActualMethod().getName());
+      if (beforeAfter == false)
+      {
+         builder.append(" params=");
+         builder.append(Arrays.asList(mi.getArguments()));
+      }
+      else if (t == null)
+      {
+         builder.append(" result=");
+         builder.append(result);
+      }
+      if (t != null)
+         builder.append(" ended in error:");
+      log.trace(builder.toString(), t);
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperAdvice.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperAdvice.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperAdvice.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,149 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.plugins.advice;
+
+import java.util.Set;
+
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.proxy.container.AOPProxyFactoryParameters;
+import org.jboss.aop.proxy.container.GeneratedAOPProxyFactory;
+import org.jboss.managed.api.Fields;
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.managed.api.ManagedProperty;
+
+/**
+ * WrapperAdvice, intercepts methods that produce objects
+ * that require proxies.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class WrapperAdvice
+{
+   /**
+    * Wrap a managed object
+    * 
+    * @param managedObject the managed object
+    * @return the managed object wrapper
+    */
+   public static ManagedObject wrapManagedObject(ManagedObject managedObject)
+   {
+      return createProxy(managedObject, ManagedObject.class);
+   }
+   
+   /**
+    * Wrap a managed property
+    * 
+    * @param managedProperty the managed property
+    * @return the managed property wrapper
+    */
+   public static ManagedProperty wrapManagedProperty(ManagedProperty managedProperty)
+   {
+      return createProxy(managedProperty, ManagedProperty.class);
+   }
+   
+   /**
+    * Wrap fields
+    * 
+    * @param fields the fields
+    * @return the fields wrapper
+    */
+   public static Fields wrapFields(Fields fields)
+   {
+      return createProxy(fields, Fields.class);
+   }
+
+   /**
+    * Wrap a returned managed object
+    * 
+    * @param invocation the invocation
+    * @return the wrapped managed object
+    * @throws Throwable for any error
+    */
+   public ManagedObject wrapManagedObject(Invocation invocation) throws Throwable
+   {
+      ManagedObject result = (ManagedObject) invocation.invokeNext();
+      return wrapManagedObject(result);
+   }
+
+   /**
+    * Wrap a returned managed property
+    * 
+    * @param invocation the invocation
+    * @return the wrapped managed property
+    * @throws Throwable for any error
+    */
+   public ManagedProperty wrapManagedProperty(Invocation invocation) throws Throwable
+   {
+      ManagedProperty result = (ManagedProperty) invocation.invokeNext();
+      return wrapManagedProperty(result);
+   }
+
+   /**
+    * Wrap a returned managed property set
+    * 
+    * @param invocation the invocation
+    * @return the wrapped managed property set
+    * @throws Throwable for any error
+    */
+   @SuppressWarnings("unchecked")
+   public Set<ManagedProperty> wrapManagedPropertySet(Invocation invocation) throws Throwable
+   {
+      Set<ManagedProperty> result = (Set<ManagedProperty>) invocation.invokeNext();
+      return new WrapperSet<ManagedProperty>(result, ManagedProperty.class);
+   }
+
+   /**
+    * Wrap fields
+    * 
+    * @param invocation the invocation
+    * @return the wrapped managed property
+    * @throws Throwable for any error
+    */
+   public Fields wrapFields(Invocation invocation) throws Throwable
+   {
+      Fields result = (Fields) invocation.invokeNext();
+      return wrapFields(result);
+   }
+   
+   /**
+    * Create a proxy 
+    * 
+    * @param <T> the expected type
+    * @param target the target
+    * @param interfaceClass the interface class
+    * @return the proxy
+    */
+   static <T> T createProxy(T target, Class<T> interfaceClass)
+   {
+      if (target == null)
+         return null;
+      
+      GeneratedAOPProxyFactory proxyFactory = new GeneratedAOPProxyFactory();
+      AOPProxyFactoryParameters params = new AOPProxyFactoryParameters();
+      params.setInterfaces(new Class[] { interfaceClass });
+      params.setObjectAsSuperClass(true);
+      params.setTarget(target);
+      Object proxy = proxyFactory.createAdvisedProxy(params);
+      return interfaceClass.cast(proxy);
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperIterator.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperIterator.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperIterator.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,73 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.plugins.advice;
+
+import java.util.Iterator;
+
+/**
+ * WrapperIterator.
+ * 
+ * @param <T> the interface
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class WrapperIterator<T> implements Iterator<T>
+{
+   /** The delegate */
+   private Iterator<T> delegate;
+
+   /** The interface class */
+   private Class<T> interfaceClass;
+   
+   /**
+    * Create a new WrapperIterator.
+    * 
+    * @param delegate the delegate
+    * @param interfaceClass the interface class
+    */
+   public WrapperIterator(Iterator<T> delegate, Class<T> interfaceClass)
+   {
+      if (delegate == null)
+         throw new IllegalArgumentException("Null delegate");
+      if (interfaceClass == null)
+         throw new IllegalArgumentException("Null interface class");
+      
+      this.delegate = delegate;
+      this.interfaceClass = interfaceClass;
+   }
+
+   public boolean hasNext()
+   {
+      return delegate.hasNext();
+   }
+
+   public T next()
+   {
+      T next = delegate.next();
+      return WrapperAdvice.createProxy(next, interfaceClass);
+   }
+
+   public void remove()
+   {
+      throw new UnsupportedOperationException();
+   }
+}

Added: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperSet.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperSet.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/advice/WrapperSet.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,73 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.managed.plugins.advice;
+
+import java.io.Serializable;
+import java.util.AbstractSet;
+import java.util.Iterator;
+import java.util.Set;
+
+/**
+ * WrapperSet.
+ * 
+ * @param <T> the interface type
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+class WrapperSet<T> extends AbstractSet<T> implements Serializable
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = -5588975054846538928L;
+
+   /** The delegate */
+   private Set<T> delegate;
+
+   /** The interface class */
+   private Class<T> interfaceClass;
+   
+   /**
+    * Create a new WrapperSet.
+    * 
+    * @param delegate the delegate
+    * @param interfaceClass the interface class
+    */
+   public WrapperSet(Set<T> delegate, Class<T> interfaceClass)
+   {
+      if (delegate == null)
+         throw new IllegalArgumentException("Null delegate");
+      if (interfaceClass == null)
+         throw new IllegalArgumentException("Null interface class");
+
+      this.delegate = delegate;
+      this.interfaceClass = interfaceClass;
+   }
+
+   public Iterator<T> iterator()
+   {
+      return new WrapperIterator<T>(delegate.iterator(), interfaceClass);
+   }
+
+   public int size()
+   {
+      return delegate.size();
+   }
+}

Added: projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedAdvices-aop.xml
===================================================================
--- projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedAdvices-aop.xml	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedAdvices-aop.xml	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+   <!-- A trace advice for debugging -->
+   <aspect name="trace" class="org.jboss.managed.plugins.advice.TraceAdvice"/>
+
+   <!-- A wrapping advice -->
+   <aspect name="wrap" class="org.jboss.managed.plugins.advice.WrapperAdvice"/>

Added: projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedObjectWrapper-aop.xml
===================================================================
--- projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedObjectWrapper-aop.xml	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedObjectWrapper-aop.xml	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+   <!-- Wrapper methods for managed object -->
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.ManagedObject}->getProperty(..))">
+      <advice name="wrapManagedProperty" aspect="wrap"/>
+   </bind>
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.ManagedObject}->getProperties(..))">
+      <advice name="wrapManagedPropertySet" aspect="wrap"/>
+   </bind>

Added: projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedPropertyWrapper-aop.xml
===================================================================
--- projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedPropertyWrapper-aop.xml	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedPropertyWrapper-aop.xml	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+   <!-- Wrapper methods for managed property -->
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.ManagedProperty}->getManagedObject(..))">
+      <advice name="wrapManagedObject" aspect="wrap"/>
+   </bind>
+
+   <!-- Wrapper methods for managed property -->
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.ManagedProperty}->getFields(..))">
+      <advice name="wrapFields" aspect="wrap"/>
+   </bind>

Added: projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedTest-aop.xml
===================================================================
--- projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedTest-aop.xml	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/resources/tests/org/jboss/test/managed/ManagedTest-aop.xml	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,43 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE aop SYSTEM "jboss-aop_1_0.dtd" [
+   <!ENTITY ManagedAdvices SYSTEM "resource:org/jboss/test/managed/ManagedAdvices-aop.xml">
+   <!ENTITY ManagedObjectWrapper SYSTEM "resource:org/jboss/test/managed/ManagedObjectWrapper-aop.xml">
+   <!ENTITY ManagedPropertyWrapper SYSTEM "resource:org/jboss/test/managed/ManagedPropertyWrapper-aop.xml">
+]>
+
+<aop>
+
+   <!-- This is the default AOP setup when the test doesn't having anything specific -->
+
+   <!-- ==== Advices ==== -->
+
+   &ManagedAdvices;
+
+   <!-- ==== Managed Object ==== -->
+
+   <!-- The managed object advice stack -->
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.ManagedObject}->$implements{org.jboss.managed.api.ManagedObject}(..))">
+      <advice name="invoke" aspect="trace"/>
+   </bind>
+
+   <!-- Wrapper methods for managed object -->
+   &ManagedObjectWrapper;
+
+   <!-- ==== Managed Property ==== -->
+
+   <!-- The managed property advice stack -->
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.ManagedProperty}->$implements{org.jboss.managed.api.ManagedProperty}(..))">
+      <advice name="invoke" aspect="trace"/>
+   </bind>
+
+   <!-- Wrapper methods for managed object -->
+   &ManagedPropertyWrapper;
+
+   <!-- ==== Fields ==== -->
+
+   <!-- The fields advice stack -->
+   <bind pointcut="execution(* $instanceof{org.jboss.managed.api.Fields}->$implements{org.jboss.managed.api.Fields}(..))">
+      <advice name="invoke" aspect="trace"/>
+   </bind>
+
+</aop>

Added: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedAllTestSuite.java
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedAllTestSuite.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedAllTestSuite.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,49 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.managed;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+/**
+ * Managed All Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 37459 $
+ */
+public class ManagedAllTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("Managed All Tests");
+
+      //suite.addTest(TypesTestSuite.suite());
+
+      return suite;
+   }
+}

Added: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTest.java
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTest.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTest.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,62 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.managed;
+
+import org.jboss.test.AbstractTestCaseWithSetup;
+import org.jboss.test.AbstractTestDelegate;
+
+/**
+ * ManagedTest.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ManagedTest extends AbstractTestCaseWithSetup
+{
+   /**
+    * Get the test delegate
+    * 
+    * @param clazz the test class
+    * @return the delegate
+    * @throws Exception for any error
+    */
+   public static AbstractTestDelegate getDelegate(Class clazz) throws Exception
+   {
+      return new ManagedTestDelegate(clazz);
+   }
+   
+   /**
+    * Create a new Managed test
+    * 
+    * @param name the test name
+    */
+   public ManagedTest(String name)
+   {
+      super(name);
+   }
+   
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+      configureLogging();
+   }
+}

Added: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,138 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.managed;
+
+import java.net.URL;
+
+import org.jboss.aop.AspectXmlLoader;
+import org.jboss.net.protocol.URLStreamHandlerFactory;
+import org.jboss.test.AbstractTestDelegate;
+
+/**
+ * 
+ * ManagedTestDelegate.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 58245 $
+ */
+public class ManagedTestDelegate extends AbstractTestDelegate
+{
+   /** The AOP URL used */
+   private URL aopURL;
+   
+   /**
+    * Create a new ManagedTestDelegate.
+    * 
+    * @param clazz the class
+    * @throws Exception for any error
+    */
+   public ManagedTestDelegate(Class clazz) throws Exception
+   {
+      super(clazz);
+   }
+
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      if (deployAOP(clazz) == false)
+         deployAOP(ManagedTest.class);
+   }
+
+   public void tearDown() throws Exception
+   {
+      super.tearDown();
+      undeployAOP();
+   }
+
+   protected boolean deployAOP(Class referenceClass) throws Exception
+   {
+      String testName = referenceClass.getName();
+      testName = testName.replace('.', '/') + "-aop.xml";
+      URL url = clazz.getClassLoader().getResource(testName);
+      if (url != null)
+      {
+         log.debug("Deploying " + url);
+         aopURL = url;
+         try
+         {
+            initURLHandlers();
+            AspectXmlLoader.deployXML(aopURL);
+         }
+         catch (Throwable t)
+         {
+            throw new RuntimeException("Error deploying: " + url, t);
+         }
+         return true;
+      }
+      else
+      {
+         log.debug("No test specific deployment " + testName);
+         return false;
+      }
+   }
+
+   protected void undeployAOP()
+   {
+      if (aopURL == null)
+         return;
+      try
+      {
+         log.debug("Undeploying " + aopURL);
+         AspectXmlLoader.undeployXML(aopURL);
+      }
+      catch (Exception e)
+      {
+         log.warn("Ignored error undeploying " + aopURL, e);
+      }
+   }
+
+   private void initURLHandlers()
+   {
+      try
+      {
+         // Install a URLStreamHandlerFactory that uses the TCL
+         URL.setURLStreamHandlerFactory(new URLStreamHandlerFactory());
+   
+         // Preload JBoss URL handlers
+         URLStreamHandlerFactory.preload();
+      }
+      catch (Error error)
+      { //very naughty but we HAVE to do this or
+         //we'll fail if we ever try to do this again
+         log.warn("Caught Throwable Error, this probably means " +
+            "we've already set the URLStreamHAndlerFactory before"); 
+         //Sys.out because we don't have logging yet
+      }
+
+      // Include the default JBoss protocol handler package
+      String handlerPkgs = System.getProperty("java.protocol.handler.pkgs");
+      if (handlerPkgs != null)
+      {
+         handlerPkgs += "|org.jboss.net.protocol";
+      }
+      else
+      {
+         handlerPkgs = "org.jboss.net.protocol";
+      }
+      System.setProperty("java.protocol.handler.pkgs", handlerPkgs);
+   }
+}

Copied: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDOMFields.java (from rev 59145, projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDOMFields.java)
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDOMFields.java	2006-12-19 14:12:21 UTC (rev 59145)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDOMFields.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,105 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.managed.mock;
+
+import java.io.Serializable;
+
+import org.jboss.managed.api.Fields;
+import org.w3c.dom.Element;
+import org.w3c.dom.NodeList;
+
+/**
+ * DOMFields.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockDOMFields implements Fields
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   /** The datasource element */
+   private Element element; 
+   
+   /** The element name */
+   private String elementName;
+   
+   /**
+    * Create a new DOMFields.
+    *
+    * @param element the data source element
+    * @param elementName the element name
+    */
+   public MockDOMFields(Element element, String elementName)
+   {
+      this.element = element;
+      this.elementName = elementName;
+   }
+   
+   public Serializable getField(String name)
+   {
+      if (NAME.equals(name))
+         return elementName;
+      if (VALUE.equals(name))
+      {
+         NodeList nodes = element.getElementsByTagName(elementName);
+         if (nodes.getLength() == 0)
+            return null;
+         else
+         {
+            Element element = (Element) nodes.item(0);
+            return element.getTextContent();
+         }
+      }
+      return null;
+   }
+
+   public void setField(String name, Serializable value)
+   {
+      if (VALUE.equals(name))
+      {
+         String string = (String) value;
+         NodeList nodes = element.getElementsByTagName(elementName);
+         Element childElement = null;
+         if (nodes.getLength() == 0)
+         {
+            if (string == null || string.length() == 0)
+               return;
+            childElement = element.getOwnerDocument().createElement(elementName);
+            element.appendChild(childElement);
+         }
+         else
+         {
+            childElement = (Element) nodes.item(0);
+            if (string == null || string.length() == 0)
+            {
+               element.removeChild(childElement);
+               return;
+            }
+         }
+         childElement.setTextContent(string);
+         return;
+      }
+      throw new UnsupportedOperationException("setField " + name);
+   }
+}

Copied: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java (from rev 59145, projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDataSourceManagedObject.java)
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/mock/MockDataSourceManagedObject.java	2006-12-19 14:12:21 UTC (rev 59145)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,89 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.managed.mock;
+
+import java.util.HashSet;
+import java.util.Set;
+
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+
+import org.jboss.managed.api.ManagedProperty;
+import org.jboss.managed.plugins.ManagedObjectImpl;
+import org.jboss.managed.plugins.ManagedPropertyImpl;
+import org.jboss.util.xml.DOMWriter;
+import org.w3c.dom.DOMImplementation;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+
+/**
+ * MockDataSourceManagedObject.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockDataSourceManagedObject extends ManagedObjectImpl
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   /** The document */
+   private Document document;
+   
+   /**
+    * Create a new MockDataSourceManagedObject.
+    */
+   public MockDataSourceManagedObject()
+   {
+      super(new HashSet<ManagedProperty>());
+      Element element;
+      try
+      {
+         DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
+         DocumentBuilder builder = factory.newDocumentBuilder();
+         DOMImplementation impl = builder.getDOMImplementation();
+         document = impl.createDocument(null, null, null);
+         
+         element = document.createElement("data-source");
+         document.appendChild(element);
+      }
+      catch (RuntimeException e)
+      {
+         throw e;
+      }
+      catch (Exception e)
+      {
+         throw new RuntimeException("Error creating dom", e);
+      }
+      
+      Set<ManagedProperty> properties = getProperties();
+      properties.add(new ManagedPropertyImpl(this, new MockDOMFields(element, "jndi-name")));
+      properties.add(new ManagedPropertyImpl(this, new MockDOMFields(element, "connection-url")));
+      properties.add(new ManagedPropertyImpl(this, new MockDOMFields(element, "user")));
+      properties.add(new ManagedPropertyImpl(this, new MockDOMFields(element, "password")));
+   }
+   
+   public String prettyPrint()
+   {
+      return DOMWriter.printNode(document, true);
+   }
+}

Added: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockTest.java
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockTest.java	2006-12-21 14:08:20 UTC (rev 59193)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockTest.java	2006-12-21 14:09:44 UTC (rev 59194)
@@ -0,0 +1,96 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.managed.mock;
+
+import junit.framework.Test;
+
+import org.jboss.managed.api.Fields;
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.managed.api.ManagedProperty;
+import org.jboss.managed.plugins.advice.WrapperAdvice;
+import org.jboss.test.managed.ManagedTest;
+
+/**
+ * MockTest
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class MockTest extends ManagedTest
+{
+   public static Test suite()
+   {
+      return suite(MockTest.class);
+   }
+   
+   public MockTest(String name)
+   {
+      super(name);
+   }
+
+   public void testMock() throws Exception
+   {
+      MockDataSourceManagedObject mock = new MockDataSourceManagedObject();
+
+      ManagedObject mo = WrapperAdvice.wrapManagedObject(mock);
+      
+      getLog().debug("MockDataSourceManagedObject, available propertes...");
+      getLog().debug(mock.getPropertyNames());
+
+      getLog().debug("Initial MetaData...");
+      getLog().debug(mock.prettyPrint());
+      
+      getLog().debug("Adding jndi-name...");
+      mo.getProperty("jndi-name").setValue("DefaultDS");
+      getLog().debug(mock.prettyPrint());
+
+      getLog().debug("Adding user and password...");
+      mo.getProperty("user").setValue("Scott");
+      mo.getProperty("password").setValue("Tiger");
+      getLog().debug(mock.prettyPrint());
+
+      getLog().debug("Changing jndi-name...");
+      mo.getProperty("jndi-name").setValue("ChangedDS");
+      getLog().debug(mock.prettyPrint());
+
+      getLog().debug("Removing jndi-name...");
+      mo.getProperty("jndi-name").setValue(null);
+      getLog().debug(mock.prettyPrint());
+      
+      getLog().debug("Displaying properties...");
+      for (ManagedProperty property : mo.getProperties())
+         getLog().debug(property.getName() + "=" + property.getValue());
+      
+      ManagedProperty jndiName = mo.getProperty("jndi-name");
+      
+      getLog().debug("Displaying jndi-name field values...");
+      getLog().debug("jndi-name name  field is: " + jndiName.getFields().getField(Fields.NAME));
+      getLog().debug("jndi-name value field is: " + jndiName.getFields().getField(Fields.VALUE));
+      
+      assertEquals(mo, jndiName.getManagedObject());
+   }
+
+   protected void configureLogging()
+   {
+      //enableTrace("org.jboss.managed.plugins.advice");
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 09:26:09 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 09:26:09 -0500
Subject: [jboss-cvs] JBossAS SVN: r59195 -
	projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container
Message-ID: <E1GxOs5-0007Fg-6b@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-21 09:26:06 -0500 (Thu, 21 Dec 2006)
New Revision: 59195

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ContainerProxyFactory.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ProxyTemplate.java
Log:
Fix the object override methods for proxies that don't extends object.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ContainerProxyFactory.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ContainerProxyFactory.java	2006-12-21 14:09:44 UTC (rev 59194)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ContainerProxyFactory.java	2006-12-21 14:26:06 UTC (rev 59195)
@@ -237,6 +237,14 @@
       
       addMethodFromTemplate(template, "writeObject", writeObjectBody());
       addMethodFromTemplate(template, "readObject", readObjectBody(superclass));
+      
+      if (objectAsSuper)
+      {
+         addMethodFromTemplate(template, "equals", equalsBody());
+         addMethodFromTemplate(template, "hashCode", hashCodeBody());
+         addMethodFromTemplate(template, "toString", toStringBody());
+      }
+      
       return proxy;
    }
    
@@ -302,6 +310,43 @@
          "}";
        //TODO add support for instance advisors
    }
+   
+   private String equalsBody()
+   {
+      return 
+         "{" +
+         "   if (delegate != null)" +
+         "   {" +
+         "      if ($1 != null && $1 instanceof org.jboss.aop.proxy.container.Delegate)" +
+         "         $1 = ((org.jboss.aop.proxy.container.Delegate) $1).getDelegate();" +
+         "      return delegate.equals($1);" +
+         "   }" +
+         "   else" +
+         "      return super.equals($1);" +
+         "}";
+   }
+   
+   private String hashCodeBody()
+   {
+      return 
+         "{" +
+         "   if (delegate != null)" +
+         "      return delegate.hashCode();" +
+         "   else" +
+         "      return super.hashCode();" +
+         "}";
+   }
+   
+   private String toStringBody()
+   {
+      return 
+         "{" +
+         "   if (delegate != null)" +
+         "      return delegate.toString();" +
+         "   else" +
+         "      return super.toString();" +
+         "}";
+   }
 
    private CtField addFieldFromTemplate(CtClass template, String name) throws Exception
    {

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ProxyTemplate.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ProxyTemplate.java	2006-12-21 14:09:44 UTC (rev 59194)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/proxy/container/ProxyTemplate.java	2006-12-21 14:26:06 UTC (rev 59195)
@@ -106,6 +106,34 @@
       return instanceAdvisor;
    }
    
+   public boolean equals(Object obj)
+   {
+      if (delegate != null)
+      {
+         if (obj != null && obj instanceof Delegate)
+            obj = ((Delegate) obj).getDelegate();
+         return delegate.equals(obj);
+      }
+      else
+         return super.equals(obj);
+   }
+   
+   public int hashCode()
+   {
+      if (delegate != null)
+         return delegate.hashCode();
+      else
+         return super.hashCode();
+   }
+   
+   public String toString()
+   {
+      if (delegate != null)
+         return delegate.toString();
+      else
+         return super.toString();
+   }
+   
    private void writeObject(java.io.ObjectOutputStream out) throws IOException
    {
       out.writeObject(delegate);



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 09:34:03 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 09:34:03 -0500
Subject: [jboss-cvs] JBossAS SVN: r59196 -
	projects/microcontainer/trunk/managed
Message-ID: <E1GxOzj-0007PB-Qy@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-21 09:34:01 -0500 (Thu, 21 Dec 2006)
New Revision: 59196

Modified:
   projects/microcontainer/trunk/managed/build.xml
Log:
Fix the build

Modified: projects/microcontainer/trunk/managed/build.xml
===================================================================
--- projects/microcontainer/trunk/managed/build.xml	2006-12-21 14:26:06 UTC (rev 59195)
+++ projects/microcontainer/trunk/managed/build.xml	2006-12-21 14:34:01 UTC (rev 59196)
@@ -70,6 +70,7 @@
       <path refid="jboss/common.core.classpath"/>
       <path refid="jboss/common.logging.spi.classpath"/>
       <path refid="jboss/common.logging.log4j.classpath"/>
+      <path refid="jboss.aop.classpath"/>
     </path>
 
     &modules;



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 10:10:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 10:10:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r59197 - in trunk/ejb3/src:
	main/org/jboss/ejb3 main/org/jboss/ejb3/naming
	test/org/jboss/ejb3/test/enventry
	test/org/jboss/ejb3/test/enventry/unit
Message-ID: <E1GxPYz-0008CR-Pd@committer01.frg.pub.inap.atl.jboss.com>

Author: wolfc
Date: 2006-12-21 10:10:12 -0500 (Thu, 21 Dec 2006)
New Revision: 59197

Added:
   trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java
   trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java
   trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java
Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java
   trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java
Log:
EJBTHREE-812: multiplexer context

Modified: trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -45,6 +45,9 @@
 import org.jboss.deployment.DeploymentInfo;
 import org.jboss.deployment.SubDeployer;
 import org.jboss.deployment.SubDeployerSupport;
+import org.jboss.ejb3.naming.MultiplexerContext;
+import org.jboss.ejb3.naming.SimpleMultiplexer;
+import org.jboss.logging.Logger;
 import org.jboss.metadata.MetaData;
 import org.jboss.metadata.XmlFileLoader;
 import org.jboss.mx.loading.LoaderRepositoryFactory;
@@ -67,6 +70,8 @@
 public class EJB3Deployer extends SubDeployerSupport
    implements SubDeployer, EJB3DeployerMBean
 {
+   private final static Logger log = Logger.getLogger(EJB3Deployer.class);
+   
    private ServiceControllerMBean serviceController;
 
    /** A map of current deployments */
@@ -312,6 +317,16 @@
       initializeJavaComp(iniCtx);
    }
 
+   private static void hackJNDI(Context ctx) throws NamingException
+   {
+      log.info("Starting java:comp hack");
+      // rename to something SimpleMultiPlexer knows.
+      ctx.rename("comp", "comp.original");
+      RefAddr refAddr = new StringRefAddr("nns", "ENC-MULTIPLEXER");
+      Reference ref = new Reference("javax.naming.Context", refAddr, SimpleMultiplexer.class.getName(), null);
+      ctx.bind("comp", ref);
+   }
+   
    public static void initializeJavaComp(InitialContext iniCtx)
            throws NamingException
    {
@@ -319,6 +334,8 @@
       Reference envRef = new Reference("javax.naming.Context", refAddr, ThreadLocalENCFactory.class.getName(), null);
       Context ctx = (Context) iniCtx.lookup("java:");
       ctx.rebind("comp.ejb3", envRef);
+      
+      hackJNDI(ctx);
    }
 
    /**

Modified: trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -39,8 +39,8 @@
 public class ThreadLocalENCFactory
         implements ObjectFactory
 {
-   private static ThreadLocal enc = new ThreadLocal();
-   private static ThreadLocal stack = new ThreadLocal();
+   private static ThreadLocal<Context> enc = new ThreadLocal<Context>();
+   private static ThreadLocal<LinkedList<Context>> stack = new ThreadLocal<LinkedList<Context>>();
 
    public static Context create(Context parent) throws Exception
    {
@@ -55,10 +55,10 @@
          enc.set(ctx);
          return;
       }
-      LinkedList currentStack = (LinkedList) stack.get();
+      LinkedList<Context> currentStack = stack.get();
       if (currentStack == null)
       {
-         currentStack = new LinkedList();
+         currentStack = new LinkedList<Context>();
          stack.set(currentStack);
       }
       currentStack.addLast(enc.get());
@@ -67,7 +67,7 @@
 
    public static void pop()
    {
-      LinkedList currentStack = (LinkedList) stack.get();
+      LinkedList<Context> currentStack = stack.get();
       if (currentStack == null)
       {
          enc.set(null);
@@ -78,7 +78,7 @@
          enc.set(null);
          return;
       }
-      Object previous = currentStack.removeLast();
+      Context previous = currentStack.removeLast();
       enc.set(previous);
    }
    // Constructors --------------------------------------------------

Added: trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -0,0 +1,283 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.naming;
+
+import java.io.Serializable;
+import java.util.ArrayList;
+import java.util.Collection;
+import java.util.Hashtable;
+
+import javax.naming.Binding;
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.Name;
+import javax.naming.NameClassPair;
+import javax.naming.NameParser;
+import javax.naming.NamingEnumeration;
+import javax.naming.NamingException;
+import javax.naming.OperationNotSupportedException;
+
+/**
+ * A context which combines two contexts.
+ * 
+ * Read operations are combined, write operations are done on the first context.
+ * All other operations are not supported.
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class MultiplexerContext implements Context, Serializable
+{
+   private static final long serialVersionUID = -2306711582586456135L;
+   
+   private transient InitialContext initialCtx;
+   
+   private String contextOneName;
+   private String contextTwoName;
+
+   public MultiplexerContext(String contextOneName, String contextTwoName) throws NamingException
+   {
+      assert contextOneName != null;
+      assert contextTwoName != null;
+      
+      this.contextOneName = contextOneName;
+      this.contextTwoName = contextTwoName;
+      
+      // make sure this works further down the line
+      getContextOne();
+      getContextTwo();
+   }
+   
+   private <T extends NameClassPair> void addAll(Collection<T> collection, NamingEnumeration<T> ne) throws NamingException
+   {
+      // TODO: how about duplicates?
+      while(ne.hasMore())
+      {
+         T ncp = ne.next();
+         collection.add(ncp);
+      }
+   }
+   
+   public Object addToEnvironment(String propName, Object propVal) throws NamingException
+   {
+      throw new OperationNotSupportedException();
+   }
+
+   public void bind(Name name, Object obj) throws NamingException
+   {
+      getContextOne().bind(name, obj);  
+   }
+
+   public void bind(String name, Object obj) throws NamingException
+   {
+      getContextOne().bind(name, obj);
+   }
+
+   public void close() throws NamingException
+   {
+      // do nothing
+   }
+
+   public Name composeName(Name name, Name prefix) throws NamingException
+   {
+      return getContextOne().composeName(name, prefix);
+   }
+
+   public String composeName(String name, String prefix) throws NamingException
+   {
+      return getContextOne().composeName(name, prefix);
+   }
+
+   public Context createSubcontext(Name name) throws NamingException
+   {
+      return getContextOne().createSubcontext(name);
+   }
+
+   public Context createSubcontext(String name) throws NamingException
+   {
+      return getContextOne().createSubcontext(name);
+   }
+
+   public void destroySubcontext(Name name) throws NamingException
+   {
+      getContextOne().destroySubcontext(name);
+   }
+
+   public void destroySubcontext(String name) throws NamingException
+   {
+      getContextOne().destroySubcontext(name);
+   }
+
+   private Context getContextOne() throws NamingException
+   {
+      return (Context) getInitialContext().lookup(contextOneName);
+   }
+   
+   private Context getContextTwo() throws NamingException
+   {
+      return (Context) getInitialContext().lookup(contextTwoName);
+   }
+   
+   public Hashtable<?, ?> getEnvironment() throws NamingException
+   {
+      throw new UnsupportedOperationException();
+   }
+
+   private InitialContext getInitialContext() throws NamingException
+   {
+      if(initialCtx == null)
+      {
+         initialCtx = new InitialContext();
+      }
+      return initialCtx;
+   }
+   
+   public String getNameInNamespace() throws NamingException
+   {
+      throw new UnsupportedOperationException();
+   }
+
+   public NameParser getNameParser(Name name) throws NamingException
+   {
+      return getContextOne().getNameParser(name);
+   }
+
+   public NameParser getNameParser(String name) throws NamingException
+   {
+      return getContextOne().getNameParser(name);
+   }
+
+   public NamingEnumeration<NameClassPair> list(Name name) throws NamingException
+   {
+      Collection<NameClassPair> set = new ArrayList<NameClassPair>();
+      addAll(set, getContextOne().list(name));
+      addAll(set, getContextTwo().list(name));
+      return new NamingEnumerationImpl<NameClassPair>(set);
+   }
+
+   public NamingEnumeration<NameClassPair> list(String name) throws NamingException
+   {
+      Collection<NameClassPair> set = new ArrayList<NameClassPair>();
+      addAll(set, getContextOne().list(name));
+      addAll(set, getContextTwo().list(name));
+      return new NamingEnumerationImpl<NameClassPair>(set);
+   }
+
+   public NamingEnumeration<Binding> listBindings(Name name) throws NamingException
+   {
+      Collection<Binding> set = new ArrayList<Binding>();
+      addAll(set, getContextOne().listBindings(name));
+      addAll(set, getContextTwo().listBindings(name));
+      return new NamingEnumerationImpl<Binding>(set);
+   }
+
+   public NamingEnumeration<Binding> listBindings(String name) throws NamingException
+   {
+      Collection<Binding> set = new ArrayList<Binding>();
+      addAll(set, getContextOne().listBindings(name));
+      addAll(set, getContextTwo().listBindings(name));
+      return new NamingEnumerationImpl<Binding>(set);
+   }
+
+   public Object lookup(Name name) throws NamingException
+   {
+      try
+      {
+         return getContextOne().lookup(name);
+      }
+      catch(NamingException e)
+      {
+         return getContextTwo().lookup(name);
+      }
+   }
+
+   public Object lookup(String name) throws NamingException
+   {
+      try
+      {
+         return getContextOne().lookup(name);
+      }
+      catch(NamingException e)
+      {
+         return getContextTwo().lookup(name);
+      }
+   }
+
+   public Object lookupLink(Name name) throws NamingException
+   {
+      try
+      {
+         return getContextOne().lookupLink(name);
+      }
+      catch(NamingException e)
+      {
+         return getContextTwo().lookupLink(name);
+      }
+   }
+
+   public Object lookupLink(String name) throws NamingException
+   {
+      try
+      {
+         return getContextOne().lookupLink(name);
+      }
+      catch(NamingException e)
+      {
+         return getContextTwo().lookupLink(name);
+      }
+   }
+
+   public void rebind(Name name, Object obj) throws NamingException
+   {
+      getContextOne().rebind(name, obj);
+   }
+
+   public void rebind(String name, Object obj) throws NamingException
+   {
+      getContextOne().rebind(name, obj);
+   }
+
+   public Object removeFromEnvironment(String propName) throws NamingException
+   {
+      throw new UnsupportedOperationException();
+   }
+
+   public void rename(Name oldName, Name newName) throws NamingException
+   {
+      getContextOne().rename(oldName, newName);
+   }
+
+   public void rename(String oldName, String newName) throws NamingException
+   {
+      getContextOne().rename(oldName, newName);
+   }
+
+   public void unbind(Name name) throws NamingException
+   {
+      getContextOne().unbind(name);
+   }
+
+   public void unbind(String name) throws NamingException
+   {
+      getContextOne().unbind(name);
+   }
+}

Added: trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -0,0 +1,85 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.naming;
+
+import java.util.Collection;
+import java.util.Iterator;
+
+import javax.naming.NameClassPair;
+import javax.naming.NamingEnumeration;
+import javax.naming.NamingException;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class NamingEnumerationImpl<T extends NameClassPair> implements NamingEnumeration<T>
+{
+   private Iterator<T> iterator;
+   
+   NamingEnumerationImpl(Collection<T> set)
+   {
+      this.iterator = set.iterator();
+   }
+
+   /* (non-Javadoc)
+    * @see javax.naming.NamingEnumeration#close()
+    */
+   public void close() throws NamingException
+   {
+      // do nothing
+   }
+
+   /* (non-Javadoc)
+    * @see javax.naming.NamingEnumeration#hasMore()
+    */
+   public boolean hasMore() throws NamingException
+   {
+      return hasMoreElements();
+   }
+
+   /* (non-Javadoc)
+    * @see javax.naming.NamingEnumeration#next()
+    */
+   public T next() throws NamingException
+   {
+      return nextElement();
+   }
+
+   /* (non-Javadoc)
+    * @see java.util.Enumeration#hasMoreElements()
+    */
+   public boolean hasMoreElements()
+   {
+      return iterator.hasNext();
+   }
+
+   /* (non-Javadoc)
+    * @see java.util.Enumeration#nextElement()
+    */
+   public T nextElement()
+   {
+      return iterator.next();
+   }
+}

Added: trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -0,0 +1,51 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.ejb3.naming;
+
+import java.util.Hashtable;
+
+import javax.naming.Context;
+import javax.naming.Name;
+import javax.naming.NamingException;
+import javax.naming.spi.ObjectFactory;
+
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
+ * @version $Revision: $
+ */
+public class SimpleMultiplexer implements ObjectFactory
+{
+   private Context context;
+   
+   public SimpleMultiplexer() throws NamingException
+   {
+      this.context = new MultiplexerContext("java:comp.original", "java:comp.ejb3");
+   }
+   
+   public Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable<?, ?> environment) throws Exception
+   {
+      return context;
+   }
+}

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -21,12 +21,16 @@
   */
 package org.jboss.ejb3.test.enventry;
 
+import javax.naming.NamingException;
+
 /**
  * @author <a href="mailto:bdecoste at jboss.com">William DeCoste</a>
  * @version <tt>$Revision$</tt>
  */
 public interface TestEnvEntry
 {
+   void checkJNDI() throws NamingException;
+   
    int getMaxExceptions();
    
    int getMinExceptions();

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -24,6 +24,8 @@
 import javax.annotation.Resource;
 import javax.ejb.Stateless;
 import javax.ejb.Remote;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
 
 import org.jboss.annotation.ejb.RemoteBinding;
 
@@ -47,6 +49,13 @@
    
    private int minExceptions = 1;
    
+   public void checkJNDI() throws NamingException
+   {
+      InitialContext ctx = new InitialContext();
+      Integer i = (Integer) ctx.lookup("java:comp/env/maxExceptions");
+      log.info("maxExceptions = " + i);
+   }
+   
    public int getMaxExceptions()
    {
       return maxExceptions;

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java	2006-12-21 14:34:01 UTC (rev 59196)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java	2006-12-21 15:10:12 UTC (rev 59197)
@@ -107,6 +107,14 @@
       }
    }
 
+   public void testJNDI() throws Exception
+   {
+      TestEnvEntry test = (TestEnvEntry)getInitialContext().lookup("TestEnvEntry");
+      assertNotNull(test);
+      
+      test.checkJNDI();
+   }
+   
    public static Test suite() throws Exception
    {
       return getDeploySetup(EnvEntryTestCase.class, "enventry.jar");



From vladimir.blagojevic at jboss.com  Thu Dec 21 10:14:16 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 21 Dec 2006 10:14:16 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1GxPce-0008Gz-Nr@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/21 10:14:16

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  fixed state transfer
  
  Revision  Changes    Path
  1.51      +5 -1      JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -b -r1.50 -r1.51
  --- BuddyManager.java	20 Dec 2006 22:28:13 -0000	1.50
  +++ BuddyManager.java	21 Dec 2006 15:14:16 -0000	1.51
  @@ -406,8 +406,12 @@
               {
                  ByteArrayInputStream bais = new ByteArrayInputStream(stateBuffer);
                  in = new MarshalledValueInputStream(bais);
  +               boolean hasState = in.readBoolean();
  +               if(hasState)
  +               {
                  stateMgr.setState(in, integrationRoot, cl);
               }
  +            }
               finally
               {
                  if (in != null)
  
  
  


From msurtani at jboss.com  Thu Dec 21 10:42:18 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 10:42:18 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1GxQ3m-0000H9-11@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 10:42:18

  Modified:    src/org/jboss/cache/buddyreplication  Tag:
                        Branch_JBossCache_1_4_0 BuddyManager.java
  Log:
  refactored
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.33.2.9  +19 -10    JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.33.2.8
  retrieving revision 1.33.2.9
  diff -u -b -r1.33.2.8 -r1.33.2.9
  --- BuddyManager.java	9 Dec 2006 15:14:46 -0000	1.33.2.8
  +++ BuddyManager.java	21 Dec 2006 15:42:17 -0000	1.33.2.9
  @@ -72,11 +72,11 @@
      /**
       * Map of buddy pools received from broadcasts
       */
  -   Map buddyPool;
  +   Map buddyPool = new ConcurrentReaderHashMap();
      /**
       * The nullBuddyPool is a set of addresses that have not specified buddy pools.
       */
  -   Set nullBuddyPool;
  +   final Set nullBuddyPool = new HashSet();
      /**
       * Name of the buddy pool for current instance.  May be null if buddy pooling is not used.
       */
  @@ -153,10 +153,6 @@
         buddyPoolName = XmlHelper.readStringContents(element, "buddyPoolName");
         if (buddyPoolName != null && buddyPoolName.equals("")) buddyPoolName = null;
   
  -      // initialise buddy pool map
  -      buddyPool = new ConcurrentReaderHashMap();
  -      nullBuddyPool = new HashSet();
  -
         // now read the buddy locator details and create accordingly.
         String buddyLocatorClass = null;
         Properties buddyLocatorProperties = null;
  @@ -396,9 +392,17 @@
            log.debug(buddyGroup.getDataOwner() + ": received announcement that cache instance " + address + " is in buddy pool " + poolName);
         }
         if (poolName != null)
  +      {
            buddyPool.put(address, poolName);
  +      }
         else
  -         nullBuddyPool.add(address);
  +      {
  +         synchronized(nullBuddyPool)
  +         {
  +            // writes to this concurrent set are expensive.  Don't write unnecessarily.
  +            if (!nullBuddyPool.contains(address)) nullBuddyPool.add(address);
  +         }
  +      }
   
         // notify any waiting view change threads that buddy pool info has been received.
         synchronized (poolInfoNotifierLock)
  @@ -936,10 +940,15 @@
            while (i.hasNext())
            {
               Object address = i.next();
  +
  +            // make sure no one is concurrently writing to nullBuddyPool.
  +            synchronized(nullBuddyPool)
  +            {
               infoReceived = infoReceived && (address.equals(cache.getLocalAddress()) || buddyPool.keySet().contains(address) || nullBuddyPool.contains(address));
            }
  +         }
   
  -         log.trace(buddyGroup.getDataOwner() + " received buddy pool info for new members " + newMembers + "?  " + infoReceived);
  +         if (log.isTraceEnabled()) log.trace(buddyGroup.getDataOwner() + " received buddy pool info for new members " + newMembers + "?  " + infoReceived);
   
            return infoReceived;
         }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 10:59:02 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 10:59:02 -0500
Subject: [jboss-cvs] JBossAS SVN: r59198 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test
Message-ID: <E1GxQJy-0000W5-Ns@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 10:58:59 -0500 (Thu, 21 Dec 2006)
New Revision: 59198

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/CrossContextCallsTestCase.java
Log:
Commit to fix the build after upgrading commons-httpclient

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/CrossContextCallsTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/CrossContextCallsTestCase.java	2006-12-21 15:10:12 UTC (rev 59197)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/test/CrossContextCallsTestCase.java	2006-12-21 15:58:59 UTC (rev 59198)
@@ -148,8 +148,18 @@
       
       result.concat(second);
       
-      // Read the response body.
-      byte[] responseBody = method.getResponseBody();
+      byte[] responseBody = null;
+      try
+      {
+         // Read the response body.
+         responseBody = method.getResponseBody();
+      }
+      catch (IOException e)
+      {
+         e.printStackTrace();
+         fail("HttpClient getResponseBody fails." + e.toString());
+      }
+      
       // Use caution: ensure correct character encoding and is not binary data
       result.concat(new String(responseBody));
    



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 11:01:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 11:01:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r59199 -
	branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/web/jk/test
Message-ID: <E1GxQMO-0000Zb-TX@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 11:01:30 -0500 (Thu, 21 Dec 2006)
New Revision: 59199

Modified:
   branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/web/jk/test/JvmRouteURLRewritingTestCase.java
Log:
Commit to fix the build after upgrading commons-httpclient

Modified: branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/web/jk/test/JvmRouteURLRewritingTestCase.java
===================================================================
--- branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/web/jk/test/JvmRouteURLRewritingTestCase.java	2006-12-21 15:58:59 UTC (rev 59198)
+++ branches/Branch_4_2/testsuite/src/main/org/jboss/test/cluster/web/jk/test/JvmRouteURLRewritingTestCase.java	2006-12-21 16:01:30 UTC (rev 59199)
@@ -107,9 +107,19 @@
          // Check the session id has changed
          assertFalse("Session id has changed", sessionId.equals(id));
       }
-      
+
       // Read the response body and confirm the URL was properly encoded.
-      byte[] responseBody = method.getResponseBody();
+      byte[] responseBody = null;
+      try
+      {
+         // Read the response body.
+         responseBody = method.getResponseBody();
+      }
+      catch (IOException e)
+      {
+         e.printStackTrace();
+         fail("HttpClient getResponseBody fails." + e.toString());
+      }
       String body = new String(responseBody);      
       String expectedURL = "accessSession.jsp;jsessionid=" + id;
       assertTrue("URL encoded properly: " + body, body.indexOf(expectedURL) > -1);



From msurtani at jboss.com  Thu Dec 21 11:19:33 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 11:19:33 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication     ...
Message-ID: <E1GxQdp-00015h-CI@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 11:19:33

  Modified:    src/org/jboss/cache/buddyreplication     BuddyLocator.java
                        BuddyManager.java BuddyGroup.java
                        NextMemberBuddyLocator.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.5       +9 -8      JBossCache/src/org/jboss/cache/buddyreplication/BuddyLocator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyLocator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyLocator.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- BuddyLocator.java	23 Oct 2006 05:46:39 -0000	1.4
  +++ BuddyLocator.java	21 Dec 2006 16:19:33 -0000	1.5
  @@ -8,7 +8,7 @@
   
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.config.BuddyReplicationConfig.BuddyLocatorConfig;
  -import org.jgroups.stack.IpAddress;
  +import org.jgroups.Address;
   
   import java.util.List;
   import java.util.Map;
  @@ -36,6 +36,7 @@
      
      /**
       * Initialize this <code>BuddyLocator</code>.
  +    *
       * @param config configuration for this <code>BuddyLocator</code>. May be
       *               <code>null</code>, in which case the implementation should
       *               use its default configuration.
  @@ -46,17 +47,17 @@
       * Choose a set of buddies for the given node.  Invoked when a change in
       * cluster membership is detected.
       *
  -    * @param buddyPoolMap      Map<IpAddress, String> mapping nodes in the cluster to
  +    * @param buddyPoolMap      Map<Address, String> mapping nodes in the cluster to
       *                          the "buddy pool" they have identified themselves as
       *                          belonging too.  A BuddyLocator implementation can use
       *                          this information to preferentially assign buddies from
       *                          the same buddy pool as <code>dataOwner</code>.  May be
       *                          <code>null</code> if buddy pools aren't configured.
  -    * @param currentMembership List<IpAddress> of the current cluster members
  -    * @param dataOwner         IpAddress of the node for which buddies should be selected
  -    * @return List<IpAddress> of the nodes that should serve as buddies for
  +    * @param currentMembership List<Address> of the current cluster members
  +    * @param dataOwner         Address of the node for which buddies should be selected
  +    * @return List<Address> of the nodes that should serve as buddies for
       *         <code>dataOwner</code>. Will not be <code>null</code>, may
       *         be empty.
       */
  -   public List<IpAddress> locateBuddies(Map<IpAddress, String> buddyPoolMap, List<IpAddress> currentMembership, IpAddress dataOwner);
  +   public List<Address> locateBuddies(Map<Address, String> buddyPoolMap, List<Address> currentMembership, Address dataOwner);
   }
  
  
  
  1.52      +111 -57   JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -b -r1.51 -r1.52
  --- BuddyManager.java	21 Dec 2006 15:14:16 -0000	1.51
  +++ BuddyManager.java	21 Dec 2006 16:19:33 -0000	1.52
  @@ -24,21 +24,22 @@
   import org.jboss.util.stream.MarshalledValueInputStream;
   import org.jgroups.Address;
   import org.jgroups.View;
  -import org.jgroups.stack.IpAddress;
   
   import java.io.ByteArrayInputStream;
   import java.util.ArrayList;
   import java.util.Arrays;
   import java.util.Collection;
   import java.util.HashMap;
  +import java.util.HashSet;
   import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
  +import java.util.Set;
   import java.util.Vector;
  -import java.util.concurrent.atomic.AtomicInteger;
   import java.util.concurrent.BlockingQueue;
   import java.util.concurrent.ConcurrentHashMap;
   import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.atomic.AtomicInteger;
   
   /**
    * Class that manages buddy replication groups.
  @@ -72,19 +73,24 @@
      /**
       * Map of buddy pools received from broadcasts
       */
  -   Map<IpAddress, String> buddyPool;
  +   Map<Address, String> buddyPool = new ConcurrentHashMap<Address, String>();
  +
  +   /**
  +    * The nullBuddyPool is a set of addresses that have not specified buddy pools.
  +    */
  +   final Set<Address> nullBuddyPool = new HashSet<Address>();
   
      /**
       * Map of bddy groups the current instance participates in as a backup node.
       * Keyed on String group name, values are BuddyGroup objects.
       * Needs to deal with concurrent access - concurrent assignTo/removeFrom buddy grp
       */
  -   Map<String, BuddyGroup> buddyGroupsIParticipateIn = new ConcurrentHashMap();
  +   Map<String, BuddyGroup> buddyGroupsIParticipateIn = new ConcurrentHashMap<String, BuddyGroup>();
   
      /**
       * Queue to deal with queued up view change requests - which are handled asynchronously
       */
  -   private final BlockingQueue<MembershipChange> queue = new LinkedBlockingQueue();
  +   private final BlockingQueue<MembershipChange> queue = new LinkedBlockingQueue<MembershipChange>();
   
      /**
       * Async thread that handles items on the view change queue
  @@ -101,11 +107,17 @@
      /**
       * number of times to retry communicating with a selected buddy if the buddy has not been initialised.
       */
  -   private static int UNINIT_BUDDIES_RETRIES = 3;
  +   private static int UNINIT_BUDDIES_RETRIES = 5;
      /**
       * wait time between retries
       */
  -   private static final long UNINIT_BUDDIES_RETRY_NAPTIME = 500;
  +   private static final long[] UNINIT_BUDDIES_RETRY_NAPTIME = {500, 1000, 1500, 2000, 2500};
  +
  +   /**
  +    * Lock to synchronise on to ensure buddy pool info is received before buddies are assigned to groups.
  +    */
  +   private final Object poolInfoNotifierLock = new Object();
  +
   
      /**
       * Flag to prevent us receiving and processing remote calls before we've started
  @@ -117,9 +129,6 @@
      {
         this.config = config;
   
  -      if (config.getBuddyPoolName() != null)
  -         buddyPool = new ConcurrentHashMap();
  -
         BuddyLocatorConfig blc = config.getBuddyLocatorConfig();
         try
         {
  @@ -178,7 +187,7 @@
         log.debug("Starting buddy manager");
         this.cache = cache;
         buddyGroup = new BuddyGroup();
  -      buddyGroup.setDataOwner((IpAddress) cache.getLocalAddress());
  +      buddyGroup.setDataOwner((Address) cache.getLocalAddress());
         buddyGroup.setGroupName(getGroupNameFromAddress(cache.getLocalAddress()));
   
         if (config.getBuddyPoolName() != null)
  @@ -186,20 +195,19 @@
            buddyPool.put(buddyGroup.getDataOwner(), config.getBuddyPoolName());
         }
   
  +      broadcastBuddyPoolMembership();
  +
         // allow waiting threads to process.
         initialised = true;
  -      broadcastBuddyPoolMembership();
  -//        initLatch.release();
   
         // register a TreeCache Listener to reassign buddies as and when view changes occur
  -
         cache.getNotifier().addCacheListener(new AbstractCacheListener()
         {
  -         private Vector oldMembers;
  +         private Vector<Address> oldMembers;
   
            public void viewChange(View newView)
            {
  -            Vector newMembers = newView.getMembers();
  +            Vector<Address> newMembers = newView.getMembers();
   
               // the whole 'oldMembers' concept is only used for buddy pool announcements.
               if (config.getBuddyPoolName() == null)
  @@ -208,8 +216,8 @@
               }
               else
               {
  -               enqueueViewChange(oldMembers == null ? null : new Vector(oldMembers), new Vector(newMembers));
  -               if (oldMembers == null) oldMembers = new Vector();
  +               enqueueViewChange(oldMembers == null ? null : new Vector<Address>(oldMembers), new Vector<Address>(newMembers));
  +               if (oldMembers == null) oldMembers = new Vector<Address>();
                  oldMembers.clear();
                  oldMembers.addAll(newMembers);
               }
  @@ -243,17 +251,19 @@
   
      // -------------- methods to be called by the tree cache listener --------------------
   
  -   static class MembershipChange {
  -      List oldMembers;
  -      List newMembers;
  -      public MembershipChange(List oldMembers, List newMembers)
  +   static class MembershipChange
  +   {
  +      List<Address> oldMembers;
  +      List<Address> newMembers;
  +
  +      public MembershipChange(List<Address> oldMembers, List<Address> newMembers)
         {
            this.oldMembers = oldMembers;
            this.newMembers = newMembers;
         }
      }
      
  -   private void enqueueViewChange(List oldMembers, List newMembers)
  +   private void enqueueViewChange(List<Address> oldMembers, List<Address> newMembers)
      {
         // put this on a queue
         try
  @@ -273,7 +283,7 @@
       * have been added.  Makes use of the BuddyLocator and then
       * makes RPC calls to remote nodes to assign/remove buddies.
       */
  -   private void reassignBuddies(List membership) throws Exception
  +   private void reassignBuddies(List<Address> membership) throws Exception
      {
         if (log.isDebugEnabled())
         {
  @@ -281,24 +291,20 @@
            log.debug("Entering updateGroup.  Current group: " + buddyGroup + ".  Current View membership: " + membership);
         }
         // some of my buddies have died!
  -      List newBuddies = buddyLocator.locateBuddies(buddyPool, membership, buddyGroup.getDataOwner());
  -      List uninitialisedBuddies = new ArrayList();
  -      Iterator newBuddiesIt = newBuddies.iterator();
  -      while (newBuddiesIt.hasNext())
  +      List<Address> newBuddies = buddyLocator.locateBuddies(buddyPool, membership, buddyGroup.getDataOwner());
  +      List<Address> uninitialisedBuddies = new ArrayList<Address>();
  +      for (Address newBuddy : newBuddies)
         {
  -         Object newBuddy = newBuddiesIt.next();
            if (!buddyGroup.buddies.contains(newBuddy))
            {
               uninitialisedBuddies.add(newBuddy);
            }
         }
   
  -      List obsoleteBuddies = new ArrayList();
  +      List<Address> obsoleteBuddies = new ArrayList<Address>();
         // find obsolete buddies
  -      Iterator originalBuddies = buddyGroup.buddies.iterator();
  -      while (originalBuddies.hasNext())
  +      for (Address origBuddy : buddyGroup.buddies)
         {
  -         Object origBuddy = originalBuddies.next();
            if (!newBuddies.contains(origBuddy))
            {
               obsoleteBuddies.add(origBuddy);
  @@ -332,13 +338,28 @@
       * Called by TreeCache._remoteAnnounceBuddyPoolName(Address address, String buddyPoolName)
       * when a view change occurs and caches need to inform the cluster of which buddy pool it is in.
       */
  -   public void handlePoolNameBroadcast(IpAddress address, String poolName)
  +   public void handlePoolNameBroadcast(Address address, String poolName)
      {
         if (log.isDebugEnabled())
         {
  -         log.debug("Received announcement that cache instance " + address + " is in buddy pool " + poolName);
  +         log.debug(buddyGroup.getDataOwner() + ": received announcement that cache instance " + address + " is in buddy pool " + poolName);
  +      }
  +      if (poolName != null)
  +         buddyPool.put(address, poolName);
  +      else
  +      {
  +         synchronized (nullBuddyPool)
  +         {
  +            if (!nullBuddyPool.contains(address)) nullBuddyPool.add(address);
  +         }
  +      }
  +
  +      // notify any waiting view change threads that buddy pool info has been received.
  +      synchronized (poolInfoNotifierLock)
  +      {
  +         log.trace("Notifying any waiting view change threads that we have received buddy pool info.");
  +         poolInfoNotifierLock.notifyAll();
         }
  -      if (poolName != null) buddyPool.put(address, poolName);
      }
   
      /**
  @@ -400,14 +421,14 @@
               ClassLoader cl = (marshaller == null) ? null : marshaller.getClassLoader(fqnS);
               Fqn integrationRoot = new Fqn(integrationBase, fqn);
               
  -            byte [] stateBuffer = (byte[]) entry.getValue();
  +            byte[] stateBuffer = (byte[]) entry.getValue();
               MarshalledValueInputStream in = null;
               try
               {
                  ByteArrayInputStream bais = new ByteArrayInputStream(stateBuffer);
                  in = new MarshalledValueInputStream(bais);
                  boolean hasState = in.readBoolean();
  -               if(hasState)
  +               if (hasState)
                  {
                     stateMgr.setState(in, integrationRoot, cl);
                  }
  @@ -427,7 +448,7 @@
   
      public static Fqn getBackupFqn(Object buddyGroupName, Fqn origFqn)
      {
  -      List elements = new ArrayList();
  +      List<Object> elements = new ArrayList<Object>();
         elements.add(BUDDY_BACKUP_SUBTREE);
         elements.add(buddyGroupName);
         elements.addAll(origFqn.peekElements());
  @@ -442,7 +463,7 @@
            return origFqn;
         }
   
  -      List elements = new ArrayList();
  +      List<Object> elements = new ArrayList<Object>();
         elements.add(BUDDY_BACKUP_SUBTREE);
         elements.add(buddyGroupRoot.get(1));
         elements.addAll(origFqn.peekElements());
  @@ -504,6 +525,7 @@
         MethodCall replicateCall = MethodCallFactory.create(MethodDeclarations.replicateMethod, membershipCall);
   
         int attemptsLeft = UNINIT_BUDDIES_RETRIES;
  +      int currentAttempt = 0;
   
         while (attemptsLeft-- > 0)
         {
  @@ -519,7 +541,7 @@
                  if (attemptsLeft > 0)
                  {
                     log.info("One of the buddies have not been initialised.  Will retry after a short nap.");
  -                  Thread.sleep(UNINIT_BUDDIES_RETRY_NAPTIME);
  +                  Thread.sleep(UNINIT_BUDDIES_RETRY_NAPTIME[currentAttempt++]);
                  }
                  else
                  {
  @@ -535,7 +557,7 @@
         log.trace("removeFromGroup notification complete");
      }
   
  -   private void addBuddies(List buddies) throws Exception
  +   private void addBuddies(List<Address> buddies) throws Exception
      {
         // this check is redundant - if buddies is empty this method will not be called. - Manik
   
  @@ -592,6 +614,7 @@
         MethodCall replicateCall = MethodCallFactory.create(MethodDeclarations.replicateMethod, membershipCall);
   
         int attemptsLeft = UNINIT_BUDDIES_RETRIES;
  +      int currentAttempt = 0;
   
         while (attemptsLeft-- > 0)
         {
  @@ -607,7 +630,8 @@
                  if (attemptsLeft > 0)
                  {
                     log.info("One of the buddies have not been initialised.  Will retry after a short nap.");
  -                  Thread.sleep(UNINIT_BUDDIES_RETRY_NAPTIME);
  +                  Thread.sleep(UNINIT_BUDDIES_RETRY_NAPTIME[currentAttempt++]);
  +
                  }
                  else
                  {
  @@ -690,7 +714,7 @@
         broadcastBuddyPoolMembership(null);
      }
   
  -   private void broadcastBuddyPoolMembership(List recipients)
  +   private void broadcastBuddyPoolMembership(List<Address> recipients)
      {
         // broadcast to other caches
         if (log.isDebugEnabled())
  @@ -849,24 +873,54 @@
   
         private void handleEnqueuedViewChange() throws Exception
         {
  -         log.trace("Handling queued view change");
  +         log.trace("Waiting for enqueued view change events");
            MembershipChange members = queue.take();
   
  -         // always refresh buddy list.
  -         reassignBuddies(members.newMembers);
  -
  -         if (config.getBuddyPoolName() != null)
  +         // make sure new buddies have broadcast their pool memberships.
  +         while (!buddyPoolInfoAvailable(members.newMembers))
  +         {
  +            synchronized (poolInfoNotifierLock)
            {
  +               log.trace("Not received necessary buddy pool info for all new members yet; waiting on poolInfoNotifierLock.");
  +               poolInfoNotifierLock.wait();
  +            }
  +         }
  +
               log.trace("Broadcasting pool membership details, triggered by view change.");
  +         //if (members.oldMembers == null)
               broadcastBuddyPoolMembership();
  -//                if (members[0] == null)
  -//                    broadcastBuddyPoolMembership();
   //                else
   //                {
  -//                    members[1].removeAll(members[0]);
  -//                    broadcastBuddyPoolMembership(members[1]);
  +//            List<Address> delta = new ArrayList<Address>();
  +//            delta.addAll(members.newMembers);
  +//            delta.removeAll(members.oldMembers);
  +//            broadcastBuddyPoolMembership(delta);
   //                }
  +
  +         // always refresh buddy list.
  +         reassignBuddies(members.newMembers);
            }
  +
  +      private boolean buddyPoolInfoAvailable(List<Address> newMembers)
  +      {
  +         boolean infoReceived = true;
  +         for (Address address : newMembers)
  +         {
  +            // make sure no one is concurrently writing to nullBuddyPool.
  +            synchronized (nullBuddyPool)
  +            {
  +//               log.trace("Testing on node " + buddyGroup.getDataOwner() + " for candidate " + address);
  +//               log.trace("Is me? " + address.equals(cache.getLocalAddress()));
  +//               log.trace("is in bP? " + buddyPool.keySet().contains(address));
  +//               log.trace("is in nBP? " + nullBuddyPool.contains(address));
  +               infoReceived = infoReceived && (address.equals(cache.getLocalAddress()) || buddyPool.keySet().contains(address) || nullBuddyPool.contains(address));
  +            }
  +         }
  +
  +         if (log.isTraceEnabled())
  +            log.trace(buddyGroup.getDataOwner() + " received buddy pool info for new members " + newMembers + "?  " + infoReceived);
  +
  +         return infoReceived;
         }
      }
   }
  \ No newline at end of file
  
  
  
  1.9       +7 -8      JBossCache/src/org/jboss/cache/buddyreplication/BuddyGroup.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyGroup.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyGroup.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- BuddyGroup.java	11 Dec 2006 21:14:34 -0000	1.8
  +++ BuddyGroup.java	21 Dec 2006 16:19:33 -0000	1.9
  @@ -6,12 +6,11 @@
    */
   package org.jboss.cache.buddyreplication;
   
  -import org.jgroups.stack.IpAddress;
  +import org.jgroups.Address;
   
   import java.io.Serializable;
  -import java.util.ArrayList;
   import java.util.List;
  -import java.util.Collections;
  +import java.util.Vector;
   
   /**
    * Value object that represents a buddy group
  @@ -27,12 +26,12 @@
   
      private String groupName;
   
  -   private IpAddress dataOwner;
  +   private Address dataOwner;
   
      /**
       * Vector<Address> - a list of JGroups addresses
       */
  -   List buddies = Collections.synchronizedList(new ArrayList());
  +   List<Address> buddies = new Vector<Address>();//Collections.synchronizedList(new ArrayList());
   
      //    List buddies = new ArrayList();
   
  @@ -46,12 +45,12 @@
         this.groupName = groupName;
      }
   
  -   public IpAddress getDataOwner()
  +   public Address getDataOwner()
      {
         return dataOwner;
      }
   
  -   public void setDataOwner(IpAddress dataOwner)
  +   public void setDataOwner(Address dataOwner)
      {
         this.dataOwner = dataOwner;
      }
  @@ -61,7 +60,7 @@
         return buddies;
      }
   
  -   public void setBuddies(List buddies)
  +   public void setBuddies(List<Address> buddies)
      {
         this.buddies = buddies;
      }
  
  
  
  1.8       +9 -8      JBossCache/src/org/jboss/cache/buddyreplication/NextMemberBuddyLocator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NextMemberBuddyLocator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/NextMemberBuddyLocator.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- NextMemberBuddyLocator.java	4 Nov 2006 22:03:24 -0000	1.7
  +++ NextMemberBuddyLocator.java	21 Dec 2006 16:19:33 -0000	1.8
  @@ -9,6 +9,7 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.config.BuddyReplicationConfig.BuddyLocatorConfig;
  +import org.jgroups.Address;
   import org.jgroups.stack.IpAddress;
   
   import java.net.InetAddress;
  @@ -61,10 +62,10 @@
         }
      }
   
  -   public List<IpAddress> locateBuddies(Map<IpAddress, String> buddyPoolMap, List<IpAddress> currentMembership, IpAddress dataOwner)
  +   public List<Address> locateBuddies(Map<Address, String> buddyPoolMap, List<Address> currentMembership, Address dataOwner)
      {
         int numBuddiesToFind = Math.min(config.getNumBuddies(), currentMembership.size());
  -      List<IpAddress> buddies = new ArrayList<IpAddress>(numBuddiesToFind);
  +      List<Address> buddies = new ArrayList<Address>(numBuddiesToFind);
   
         // find where we are in the list.
         int dataOwnerSubscript = currentMembership.indexOf(dataOwner);
  @@ -110,7 +111,7 @@
               break;
            }
   
  -         IpAddress candidate = currentMembership.get(subscript);
  +         Address candidate = currentMembership.get(subscript);
            if (
                    !candidate.equals(dataOwner) && // ignore self from selection as buddy
                            !buddies.contains(candidate) && // havent already considered this candidate
  @@ -136,11 +137,11 @@
         return ownerPoolName.equals(candidatePoolName);
      }
   
  -   private boolean isColocated(IpAddress candidate, IpAddress dataOwner)
  +   private boolean isColocated(Address candidate, Address dataOwner)
      {
         // assume they're both IpAddresses??
  -      InetAddress inetC = candidate.getIpAddress();
  -      InetAddress inetD = dataOwner.getIpAddress();
  +      InetAddress inetC = ((IpAddress) candidate).getIpAddress();
  +      InetAddress inetD = ((IpAddress) dataOwner).getIpAddress();
   
         if (inetC.equals(inetD)) return true;
   
  
  
  


From msurtani at jboss.com  Thu Dec 21 11:19:33 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 11:19:33 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/buddyreplication ...
Message-ID: <E1GxQdp-00015r-GS@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 11:19:33

  Modified:    tests/functional/org/jboss/cache/buddyreplication  
                        BuddyReplicationTestsBase.java
                        BuddyGroupAssignmentTest.java
  Log:
  refactored
  
  Revision  Changes    Path
  1.33      +6 -4      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationTestsBase.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- BuddyReplicationTestsBase.java	10 Nov 2006 20:32:52 -0000	1.32
  +++ BuddyReplicationTestsBase.java	21 Dec 2006 16:19:33 -0000	1.33
  @@ -16,6 +16,7 @@
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.xml.XmlHelper;
  +import org.jgroups.Address;
   import org.w3c.dom.Element;
   
   import javax.transaction.TransactionManager;
  @@ -226,7 +227,10 @@
   
      protected void assertIsBuddy(TreeCache dataOwner, TreeCache buddy, boolean onlyBuddy)
      {
  -      System.out.println("*** assert with groups");
  +      Address dataOwnerLocalAddress = (Address) dataOwner.getLocalAddress();
  +      Address buddyLocalAddress = (Address) buddy.getLocalAddress();
  +
  +      System.out.println("*** assert with groups.  Testing that " + buddyLocalAddress + " is a buddy for owner " + dataOwnerLocalAddress + " only buddy? " + onlyBuddy);
         printBuddyGroup(dataOwner);
   
         BuddyManager dataOwnerBuddyManager = dataOwner.getBuddyManager();
  @@ -234,13 +238,11 @@
   
         // lets test things on the data owner's side of things
         if (onlyBuddy) assertEquals("Should only have one buddy", 1, dataOwnerBuddyManager.getBuddyAddresses().size());
  -      Object dataOwnerLocalAddress = dataOwner.getLocalAddress();
  -      Object buddyLocalAddress = buddy.getLocalAddress();
   
         assertTrue(buddyLocalAddress + " should be a buddy to " + dataOwnerLocalAddress, dataOwnerBuddyManager.getBuddyAddresses().contains(buddyLocalAddress));
   
         // and now on the buddy end
  -      BuddyGroup group = (BuddyGroup) buddyBuddyManager.buddyGroupsIParticipateIn.get(BuddyManager.getGroupNameFromAddress(dataOwnerLocalAddress));
  +      BuddyGroup group = buddyBuddyManager.buddyGroupsIParticipateIn.get(BuddyManager.getGroupNameFromAddress(dataOwnerLocalAddress));
         System.out.println("*** Buddy's version of dataOwner's group " + group);
   
         assertTrue("buddy's list of groups it participates in should contain data owner's group name", buddyBuddyManager.buddyGroupsIParticipateIn.containsKey(BuddyManager.getGroupNameFromAddress(dataOwnerLocalAddress)));
  
  
  
  1.13      +2 -0      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyGroupAssignmentTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyGroupAssignmentTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyGroupAssignmentTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- BuddyGroupAssignmentTest.java	20 Sep 2006 14:45:32 -0000	1.12
  +++ BuddyGroupAssignmentTest.java	21 Dec 2006 16:19:33 -0000	1.13
  @@ -60,6 +60,8 @@
         log.debug("Running test2Buddies");
         caches = createCaches(2, 3, false);
   
  +      TestingUtil.sleepThread(2000);
  +
         System.out.println("*** Testing cache 0");
         assertIsBuddy(caches[0], caches[1], false);
         assertIsBuddy(caches[0], caches[2], false);
  
  
  


From tom.elrod at jboss.com  Thu Dec 21 11:40:35 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Thu, 21 Dec 2006 11:40:35 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/socket ...
Message-ID: <E1GxQyB-0001Qo-Ev@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/21 11:40:35

  Modified:    src/main/org/jboss/remoting/transport/socket  Tag:
                        remoting_2_x ServerThread.java
  Log:
  JBREM-655 - make sure server thread name gets updated with new client address when woken up with new client socket connection.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.29.2.4  +3 -3      JBossRemoting/src/main/org/jboss/remoting/transport/socket/ServerThread.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerThread.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/socket/ServerThread.java,v
  retrieving revision 1.29.2.3
  retrieving revision 1.29.2.4
  diff -u -b -r1.29.2.3 -r1.29.2.4
  --- ServerThread.java	6 Nov 2006 15:21:51 -0000	1.29.2.3
  +++ ServerThread.java	21 Dec 2006 16:40:35 -0000	1.29.2.4
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
    * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  - * @version $Revision: 1.29.2.3 $
  + * @version $Revision: 1.29.2.4 $
    */
   public class ServerThread extends Thread
   {
  @@ -273,8 +273,8 @@
      public synchronized void wakeup(Socket socket, int timeout, Map metadata) throws Exception
      {
         this.socketWrapper = createServerSocket(socket, timeout, metadata);
  -//      String name = "SocketServerInvokerThread-" + socket.getInetAddress().getHostAddress() + "-" + nextID();
  -//      super.setName(name);
  +      String name = "SocketServerInvokerThread-" + socket.getInetAddress().getHostAddress() + "-" + nextID();
  +      super.setName(name);
         running = true;
         handlingResponse = true;
         this.notify();
  
  
  


From tom.elrod at jboss.com  Thu Dec 21 11:43:33 2006
From: tom.elrod at jboss.com (Tom Elrod)
Date: Thu, 21 Dec 2006 11:43:33 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/socket ...
Message-ID: <E1GxR13-0001Tw-QM@committer01.frg.pub.inap.atl.jboss.com>

  User: telrod  
  Date: 06/12/21 11:43:33

  Modified:    src/main/org/jboss/remoting/transport/socket 
                        ServerThread.java
  Log:
  JBREM-655 - updated server thread to update its thread name with client address when woken up with new client socket connection.
  
  Revision  Changes    Path
  1.31      +3 -3      JBossRemoting/src/main/org/jboss/remoting/transport/socket/ServerThread.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerThread.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/socket/ServerThread.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- ServerThread.java	3 Nov 2006 16:19:16 -0000	1.30
  +++ ServerThread.java	21 Dec 2006 16:43:33 -0000	1.31
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
    * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  - * @version $Revision: 1.30 $
  + * @version $Revision: 1.31 $
    */
   public class ServerThread extends Thread
   {
  @@ -271,8 +271,8 @@
      public synchronized void wakeup(Socket socket, int timeout, Map metadata) throws Exception
      {
         this.socketWrapper = createServerSocket(socket, timeout, metadata);
  -//      String name = "SocketServerInvokerThread-" + socket.getInetAddress().getHostAddress() + "-" + nextID();
  -//      super.setName(name);
  +      String name = "SocketServerInvokerThread-" + socket.getInetAddress().getHostAddress() + "-" + nextID();
  +      super.setName(name);
         running = true;
         handlingResponse = true;
         this.notify();
  
  
  


From msurtani at jboss.com  Thu Dec 21 12:59:01 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 12:59:01 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/buddyreplication ...
Message-ID: <E1GxSC5-0002n8-P8@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 12:59:01

  Modified:    tests/functional/org/jboss/cache/buddyreplication 
                        BuddyPoolBroadcastTest.java
  Log:
  Increased robustness
  
  Revision  Changes    Path
  1.16      +4 -3      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyPoolBroadcastTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- BuddyPoolBroadcastTest.java	15 Sep 2006 15:11:35 -0000	1.15
  +++ BuddyPoolBroadcastTest.java	21 Dec 2006 17:59:01 -0000	1.16
  @@ -135,7 +135,7 @@
      public void testConcurrency() throws Exception
      {
         log.debug("Running testConcurrency");
  -      int numCaches = 10;
  +      int numCaches = 15;
         caches = new TreeCache[numCaches];
         Latch latch = new Latch();
         CacheStarter[] starters = new CacheStarter[numCaches];
  @@ -153,13 +153,14 @@
   
         // allow a generous sleep time
         TestingUtil.blockUntilViewsReceived(caches, 240000);
  -      TestingUtil.sleepThread(15000);
  +      TestingUtil.sleepThread(1000 * numCaches); // the max timeout we can expect is 2500ms * 10 nodes
   
         // and now look at the state of things.
         Map map = caches[0].getBuddyManager().buddyPool;
  +      System.out.println(map);
         for (int i = 0; i < numCaches; i++)
         {
  -         assertEquals("Failed on cache " + i, new String(new char[]{(char) ('A' + i)}), map.get(caches[i].getLocalAddress()));
  +         assertEquals("Failed on cache " + i + "(" + caches[i].getLocalAddress() + ")", new String(new char[]{(char) ('A' + i)}), map.get(caches[i].getLocalAddress()));
         }
   
         checkConsistentPoolState(caches);
  
  
  


From msurtani at jboss.com  Thu Dec 21 12:59:01 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 12:59:01 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1GxSC5-0002nF-UE@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 12:59:01

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  Increased robustness
  
  Revision  Changes    Path
  1.53      +11 -11    JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.52
  retrieving revision 1.53
  diff -u -b -r1.52 -r1.53
  --- BuddyManager.java	21 Dec 2006 16:19:33 -0000	1.52
  +++ BuddyManager.java	21 Dec 2006 17:59:01 -0000	1.53
  @@ -876,6 +876,17 @@
            log.trace("Waiting for enqueued view change events");
            MembershipChange members = queue.take();
   
  +         log.trace("Broadcasting pool membership details, triggered by view change.");
  +         if (members.oldMembers == null)
  +            broadcastBuddyPoolMembership();
  +         else
  +         {
  +            List<Address> delta = new ArrayList<Address>();
  +            delta.addAll(members.newMembers);
  +            delta.removeAll(members.oldMembers);
  +            broadcastBuddyPoolMembership(delta);
  +         }
  +
            // make sure new buddies have broadcast their pool memberships.
            while (!buddyPoolInfoAvailable(members.newMembers))
            {
  @@ -886,17 +897,6 @@
               }
            }
   
  -         log.trace("Broadcasting pool membership details, triggered by view change.");
  -         //if (members.oldMembers == null)
  -         broadcastBuddyPoolMembership();
  -//         else
  -//         {
  -//            List<Address> delta = new ArrayList<Address>();
  -//            delta.addAll(members.newMembers);
  -//            delta.removeAll(members.oldMembers);
  -//            broadcastBuddyPoolMembership(delta);
  -//         }
  -
            // always refresh buddy list.
            reassignBuddies(members.newMembers);
         }
  
  
  


From msurtani at jboss.com  Thu Dec 21 13:10:24 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 13:10:24 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1GxSN6-0003Bo-5M@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 13:10:24

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  Increased robustness
  
  Revision  Changes    Path
  1.54      +20 -10    JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.53
  retrieving revision 1.54
  diff -u -b -r1.53 -r1.54
  --- BuddyManager.java	21 Dec 2006 17:59:01 -0000	1.53
  +++ BuddyManager.java	21 Dec 2006 18:10:24 -0000	1.54
  @@ -876,20 +876,14 @@
            log.trace("Waiting for enqueued view change events");
            MembershipChange members = queue.take();
   
  -         log.trace("Broadcasting pool membership details, triggered by view change.");
  -         if (members.oldMembers == null)
  -            broadcastBuddyPoolMembership();
  -         else
  -         {
  -            List<Address> delta = new ArrayList<Address>();
  -            delta.addAll(members.newMembers);
  -            delta.removeAll(members.oldMembers);
  -            broadcastBuddyPoolMembership(delta);
  -         }
  +         broadcastPoolMembership(members);
  +
  +         boolean rebroadcast = false;
   
            // make sure new buddies have broadcast their pool memberships.
            while (!buddyPoolInfoAvailable(members.newMembers))
            {
  +            rebroadcast = true;
               synchronized (poolInfoNotifierLock)
               {
                  log.trace("Not received necessary buddy pool info for all new members yet; waiting on poolInfoNotifierLock.");
  @@ -897,10 +891,26 @@
               }
            }
   
  +         if (rebroadcast) broadcastPoolMembership(members);
  +
            // always refresh buddy list.
            reassignBuddies(members.newMembers);
         }
   
  +      private void broadcastPoolMembership(MembershipChange members)
  +      {
  +         log.trace("Broadcasting pool membership details, triggered by view change.");
  +         if (members.oldMembers == null)
  +            broadcastBuddyPoolMembership();
  +         else
  +         {
  +            List<Address> delta = new ArrayList<Address>();
  +            delta.addAll(members.newMembers);
  +            delta.removeAll(members.oldMembers);
  +            broadcastBuddyPoolMembership(delta);
  +         }
  +      }
  +
         private boolean buddyPoolInfoAvailable(List<Address> newMembers)
         {
            boolean infoReceived = true;
  
  
  


From msurtani at jboss.com  Thu Dec 21 13:16:17 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 13:16:17 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/buddyreplication ...
Message-ID: <E1GxSSn-0003IE-HO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 13:16:17

  Modified:    tests/functional/org/jboss/cache/buddyreplication  Tag:
                        Branch_JBossCache_1_4_0 BuddyPoolBroadcastTest.java
  Log:
  improved robustness
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.12.2.2  +2 -2      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyPoolBroadcastTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java,v
  retrieving revision 1.12.2.1
  retrieving revision 1.12.2.2
  diff -u -b -r1.12.2.1 -r1.12.2.2
  --- BuddyPoolBroadcastTest.java	11 Dec 2006 10:50:03 -0000	1.12.2.1
  +++ BuddyPoolBroadcastTest.java	21 Dec 2006 18:16:17 -0000	1.12.2.2
  @@ -135,7 +135,7 @@
   
       public void testConcurrency() throws Exception
       {
  -        int numCaches = 5;
  +        int numCaches = 15;
           TreeCache[] caches = new TreeCache[numCaches];
           try
           {
  @@ -155,7 +155,7 @@
   
               // allow a generous sleep time
               TestingUtil.blockUntilViewsReceived(caches, 180000);
  -            TestingUtil.sleepThread(15000);
  +            TestingUtil.sleepThread(1000 * numCaches);
   
               // and now look at the state of things.
               Map map = caches[0].getBuddyManager().buddyPool;
  
  
  


From msurtani at jboss.com  Thu Dec 21 13:16:17 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 13:16:17 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1GxSSn-0003IP-M2@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 13:16:17

  Modified:    src/org/jboss/cache/buddyreplication  Tag:
                        Branch_JBossCache_1_4_0 BuddyManager.java
  Log:
  improved robustness
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.33.2.10 +13 -3     JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.33.2.9
  retrieving revision 1.33.2.10
  diff -u -b -r1.33.2.9 -r1.33.2.10
  --- BuddyManager.java	21 Dec 2006 15:42:17 -0000	1.33.2.9
  +++ BuddyManager.java	21 Dec 2006 18:16:17 -0000	1.33.2.10
  @@ -908,9 +908,14 @@
            log.trace("Waiting for enqueued view change events");
            List[] members = (List[]) queue.take(); // 2 element array - 0 - oldMembers, 1 - newMembers
   
  +         broadcastPoolMembership(members);
  +
  +         boolean rebroadcast = false;
  +
            // make sure new buddies have broadcast their pool memberships.
            while (!buddyPoolInfoAvailable(members[1]))
            {
  +            rebroadcast = true;
               synchronized (poolInfoNotifierLock)
               {
                  log.trace("Not received necessary buddy pool info for all new members yet; waiting on poolInfoNotifierLock.");
  @@ -918,6 +923,14 @@
               }
            }
   
  +         if (rebroadcast) broadcastPoolMembership(members);
  +
  +         // always refresh buddy list.
  +         reassignBuddies(members[1]);
  +      }
  +
  +      private void broadcastPoolMembership(List[] members)
  +      {
            log.trace("Broadcasting pool membership details, triggered by view change.");
            if (members[0] == null)
               broadcastBuddyPoolMembership();
  @@ -928,9 +941,6 @@
               delta.removeAll(members[0]);
               broadcastBuddyPoolMembership(delta);
            }
  -
  -         // always refresh buddy list.
  -         reassignBuddies(members[1]);
         }
   
         private boolean buddyPoolInfoAvailable(List newMembers)
  
  
  


From msurtani at jboss.com  Thu Dec 21 13:17:12 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 13:17:12 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxSTg-0003Jr-8d@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 13:17:12

  Modified:    src/org/jboss/cache  Version.java
  Log:
  versioning info
  
  Revision  Changes    Path
  1.25      +3 -3      JBossCache/src/org/jboss/cache/Version.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Version.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Version.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- Version.java	13 Dec 2006 18:00:00 -0000	1.24
  +++ Version.java	21 Dec 2006 18:17:12 -0000	1.25
  @@ -6,14 +6,14 @@
    * Contains version information about this release of TreeCache.
    *
    * @author Bela Ban
  - * @version $Id: Version.java,v 1.24 2006/12/13 18:00:00 msurtani Exp $
  + * @version $Id: Version.java,v 1.25 2006/12/21 18:17:12 msurtani Exp $
    */
   public class Version
   {
  -   public static final String version = "2.0.0.ALPHA1";
  +   public static final String version = "2.0.0.ALPHA2";
      public static final String codename = "Habanero";
      public static byte[] version_id = {'0', '2', '0', '0', 'a'};
  -   public static final String cvs = "$Id: Version.java,v 1.24 2006/12/13 18:00:00 msurtani Exp $";
  +   public static final String cvs = "$Id: Version.java,v 1.25 2006/12/21 18:17:12 msurtani Exp $";
   
      private static final int MAJOR_SHIFT = 11;
      private static final int MINOR_SHIFT = 6;
  
  
  


From msurtani at jboss.com  Thu Dec 21 13:17:12 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 13:17:12 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GxSTg-0003Jy-Fn@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 13:17:12

  Modified:    JBossCache  build.xml
  Log:
  versioning info
  
  Revision  Changes    Path
  1.155     +2 -2      JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.154
  retrieving revision 1.155
  diff -u -b -r1.154 -r1.155
  --- build.xml	18 Dec 2006 12:27:51 -0000	1.154
  +++ build.xml	21 Dec 2006 18:17:12 -0000	1.155
  @@ -1,12 +1,12 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.154 2006/12/18 12:27:51 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.155 2006/12/21 18:17:12 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
      <property name="module.name" value="JBossCache"/>
      <!--We now requires version to have no white space since Ant+JBossAop will sometime choke. -->
  -   <property name="module.version" value="2.0.0.ALPHA1"/>
  +   <property name="module.version" value="2.0.0.ALPHA2"/>
      <property name="implementation.url" value="http://www.jboss.com/products/jbosscache"/>
      <property file="build.properties"/>
      <property name="root.dir" value="${basedir}"/>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 13:22:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 13:22:46 -0500
Subject: [jboss-cvs] JBossAS SVN: r59200 - in projects/microcontainer/trunk:
	container/src/main/org/jboss/reflect/plugins
	container/src/main/org/jboss/reflect/plugins/introspection
	container/src/main/org/jboss/reflect/plugins/javassist
	container/src/main/org/jboss/reflect/spi
	kernel/src/main/org/jboss/beans/metadata/plugins
	kernel/src/main/org/jboss/kernel/plugins/config
	kernel/src/resources/xml-test/org/jboss/test/kernel/config/test
	kernel/src/tests/org/jboss/test/kernel/config/test
Message-ID: <E1GxSZ4-0003Q8-E1@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-21 13:22:23 -0500 (Thu, 21 Dec 2006)
New Revision: 59200

Added:
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/NullProgressionConvertor.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertor.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/SimpleProgressionConvertor.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java
   projects/microcontainer/trunk/kernel/src/resources/xml-test/org/jboss/test/kernel/config/test/testProgressionFromOtherBean.xml
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionXMLTestCase.java
Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractBeanMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractDependencyValueMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractInjectionValueMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractValueMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ThisValueMetaData.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java
Log:
JBMICROCONT-119; added flexible progression convertor, NumberInfo SPI class

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/NullProgressionConvertor.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/NullProgressionConvertor.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/NullProgressionConvertor.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,40 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.plugins;
+
+/**
+ * Null progression implementation - doesn't progress at all.
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class NullProgressionConvertor implements ProgressionConvertor
+{
+   public boolean canProgress(Class<? extends Object> target, Class<? extends Object> source)
+   {
+      return false;
+   }
+
+   public Object doProgression(Class<? extends Object> target, Object value) throws Throwable
+   {
+      return value;
+   }
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertor.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertor.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertor.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,51 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.plugins;
+
+/**
+ * JBMICROCONT-119 issue
+ * Support integer progression, e.g. float -> int or Float -> Integer and vice versa
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface ProgressionConvertor
+{
+
+   /**
+    * Check if progression is supported.
+    *
+    * @param target
+    * @param source
+    * @return true, if we can progress source's value class type to target class
+    */
+   boolean canProgress(Class<? extends Object> target, Class<? extends Object> source);
+
+   /**
+    * Do the actual progression.
+    *
+    * @param target class type
+    * @param value to progress
+    * @return progressed value - it's class type now equals to target
+    */
+   Object doProgression(Class<? extends Object> target, Object value) throws Throwable;
+
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,74 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.plugins;
+
+import java.security.PrivilegedExceptionAction;
+import java.security.AccessController;
+
+import org.jboss.reflect.plugins.introspection.ReflectionUtils;
+
+/**
+ * Singleton progression instance factory.
+ * We can change the progression convertor with system property
+ * or setting the convertor class name at the singleton factory instance.
+ * This way we can still change the convertor at runtime before actual usage -
+ * in MC beans definition or other IoC - via XML.
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ProgressionConvertorFactory
+{
+   private static ProgressionConvertorFactory instance = new ProgressionConvertorFactory();
+
+   private String convertorClassName = SimpleProgressionConvertor.class.getName();
+   private ProgressionConvertor convertor;
+
+   public static ProgressionConvertorFactory getInstance()
+   {
+      return instance;
+   }
+
+   public ProgressionConvertor getConvertor() throws Throwable
+   {
+      if (convertor == null)
+      {
+         ConvertorLookup lookup = new ConvertorLookup();
+         String convertorClass = AccessController.doPrivileged(lookup);
+         convertor = (ProgressionConvertor) ReflectionUtils.newInstance(convertorClass);
+      }
+      return convertor;
+   }
+
+   public void setConvertorClassName(String convertorClassName)
+   {
+      this.convertorClassName = convertorClassName;
+   }
+
+   private class ConvertorLookup implements PrivilegedExceptionAction<String>
+   {
+      public String run() throws Exception
+      {
+         return System.getProperty("org.jboss.reflect.plugins.progressionConvertor", convertorClassName);
+      }
+   }
+
+}

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/SimpleProgressionConvertor.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/SimpleProgressionConvertor.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/SimpleProgressionConvertor.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,110 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.plugins;
+
+import java.util.concurrent.atomic.AtomicInteger;
+import java.util.concurrent.atomic.AtomicLong;
+import java.math.BigInteger;
+import java.math.BigDecimal;
+
+/**
+ * Simple progression code.
+ * @see javax.management.monitor.GaugeMonitor
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class SimpleProgressionConvertor implements ProgressionConvertor
+{
+
+   public boolean canProgress(Class<? extends Object> target, Class<? extends Object> source)
+   {
+      // see progression comment
+      if (target == null || source == null || BigInteger.class == target || BigDecimal.class == target)
+      {
+         return false;
+      }
+      // ipnbX = is primitive non boolean X
+      boolean ipnbt = target.isPrimitive() && target != Boolean.TYPE;
+      boolean ipnbs = source.isPrimitive() && source != Boolean.TYPE;
+      return (ipnbt || Number.class.isAssignableFrom(target)) && (ipnbs || Number.class.isAssignableFrom(source));
+   }
+
+   public Object doProgression(Class<? extends Object> target, Object value) throws Throwable
+   {
+      if (value == null || target == value.getClass())
+      {
+         return value;
+      }
+      if (canProgress(target, value.getClass()) == false)
+      {
+         throw new IllegalArgumentException("This convertor only handles Numbers: " + target + "/" + value);
+      }
+
+      Number source = (Number) value;
+      // set the right value
+      if (Byte.class == target || byte.class == target)
+      {
+         return source.byteValue();
+      }
+      else if (Double.class == target || double.class == target)
+      {
+         return source.doubleValue();
+      }
+      else if (Float.class == target || float.class == target)
+      {
+         return source.floatValue();
+      }
+      else if (Integer.class == target || int.class == target)
+      {
+         return source.intValue();
+      }
+      else if (Long.class == target || long.class == target)
+      {
+         return source.longValue();
+      }
+      else if (Short.class == target || short.class == target)
+      {
+         return source.shortValue();
+      }
+      else if (AtomicInteger.class == target)
+      {
+         return new AtomicInteger(source.intValue());
+      }
+      else if (AtomicLong.class == target)
+      {
+         return new AtomicLong(source.longValue());
+      }
+/*
+      // maybe leave this two off - with String constructor
+      if (BigInteger.class == target)
+      {
+         return new BigInteger(source.intValue());
+      }
+      else if (BigDecimal.class == target)
+      {
+         return new BigDecimal(source.doubleValue());
+      }
+*/
+      throw new IllegalArgumentException("Unsupported Number subclass: " + target);
+   }
+
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ValueConvertor.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -33,16 +33,19 @@
 
 /**
  * PropertyEditorHelper.
+ * <p/>
+ * TODO JBMICROCONT-118 fix the introspection assumption
  *
- * TODO JBMICROCONT-118 fix the introspection assumption
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision$
  */
 public class ValueConvertor
 {
-   /** The log */
+   /**
+    * The log
+    */
    private static final Logger log = Logger.getLogger(ValueConvertor.class);
-   
+
    static
    {
       try
@@ -54,11 +57,11 @@
          log.debug("Unable to initialise property editors", t);
       }
    }
-   
+
    /**
     * Convert a value
-    * 
-    * TODO JBMICROCONT-119 look at integer progression, e.g. Integer.longValue()
+    * <p/>
+    *
     * @param clazz the class
     * @param value the value
     * @return the value or null if there is no editor
@@ -71,7 +74,7 @@
          throw new IllegalArgumentException("Null class");
       if (value == null)
          return null;
-      
+
       Class<? extends Object> valueClass = value.getClass();
       if (clazz.isAssignableFrom(valueClass))
          return value;
@@ -97,31 +100,57 @@
       // Try a static clazz.valueOf(value)
       try
       {
-         Method method = clazz.getMethod("valueOf", new Class[] { valueClass });
+         Method method = clazz.getMethod("valueOf", valueClass);
          int modifiers = method.getModifiers();
-         if (Modifier.isPublic(modifiers) && Modifier.isStatic(modifiers) 
+         if (Modifier.isPublic(modifiers) && Modifier.isStatic(modifiers)
                && clazz.isAssignableFrom(method.getReturnType()))
-            return ReflectionUtils.invoke(null, method, new Object[] { value });
+            return ReflectionUtils.invoke(null, method, new Object[]{value});
       }
       catch (Exception ignored)
       {
       }
-      
 
       // TODO JBMICROCONT-132 improve <init>(String) might not be relevent?
       if (valueClass == String.class)
       {
          try
          {
-            Constructor constructor = clazz.getConstructor(new Class[] { String.class });
+            Constructor constructor = clazz.getConstructor(valueClass);
             if (Modifier.isPublic(constructor.getModifiers()))
-               return ReflectionUtils.newInstance(constructor, new Object[] { value });
+               return ReflectionUtils.newInstance(constructor, new Object[]{value});
          }
          catch (Exception ignored)
          {
          }
       }
-      
+
       return value;
    }
+
+   /**
+    * Progress a value
+    * <p/>
+    *
+    * @param clazz the class
+    * @param value the value
+    * @return the progressed value or null if unsupported
+    * @throws Throwable for any error
+    */
+   public static Object progressValue(Class<? extends Object> clazz, Object value) throws Throwable
+   {
+      if (value != null)
+      {
+         ProgressionConvertor convertor = ProgressionConvertorFactory.getInstance().getConvertor();
+         if (convertor.canProgress(clazz, value.getClass()))
+         {
+            return convertor.doProgression(clazz, value);
+         }
+         else
+         {
+            return null;
+         }
+      }
+      return value;
+   }
+
 }

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/introspection/IntrospectionTypeInfoFactoryImpl.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -43,14 +43,7 @@
 import org.jboss.reflect.plugins.EnumInfoImpl;
 import org.jboss.reflect.plugins.FieldInfoImpl;
 import org.jboss.reflect.plugins.MethodInfoImpl;
-import org.jboss.reflect.spi.AnnotationInfo;
-import org.jboss.reflect.spi.AnnotationValue;
-import org.jboss.reflect.spi.ArrayInfo;
-import org.jboss.reflect.spi.ClassInfo;
-import org.jboss.reflect.spi.InterfaceInfo;
-import org.jboss.reflect.spi.PrimitiveInfo;
-import org.jboss.reflect.spi.TypeInfo;
-import org.jboss.reflect.spi.TypeInfoFactory;
+import org.jboss.reflect.spi.*;
 import org.jboss.util.collection.temp.WeakTypeCache;
 
 /**
@@ -169,7 +162,7 @@
          infos[i] = new ReflectFieldInfoImpl(annotations, fields[i].getName(), getTypeInfo(fields[i].getGenericType()), fields[i].getModifiers(), (ClassInfo) getTypeInfo(fields[i].getDeclaringClass()));
          infos[i].setField(fields[i]);
       }
-      
+
       return infos;
    }
 
@@ -261,6 +254,16 @@
       if (primitive != null)
          return primitive;
 
+      NumberInfo number = NumberInfo.valueOf(clazz.getName());
+      if (number != null)
+      {
+         if (number.isInitialized() == false)
+         {
+            number.setDelegate(get(clazz));
+         }
+         return number;
+      }
+
       return get(clazz);
    }
 
@@ -277,6 +280,16 @@
          TypeInfo primitive = PrimitiveInfo.valueOf(((Class) type).getName());
          if (primitive != null)
             return primitive;
+
+         NumberInfo number = NumberInfo.valueOf(((Class) type).getName());
+         if (number != null)
+         {
+            if (number.isInitialized() == false)
+            {
+               number.setDelegate(get(type));
+            }
+            return number;
+         }
       }
 
       return get(type);
@@ -291,6 +304,22 @@
       if (primitive != null)
          return primitive;
 
+      NumberInfo number = NumberInfo.valueOf(name);
+      if (number != null)
+      {
+         if (number.isInitialized() == false)
+         {
+            number.setDelegate(resolveComplexTypeInfo(cl, name));
+         }
+         return number;
+      }
+
+      return resolveComplexTypeInfo(cl, name);
+   }
+
+   private TypeInfo resolveComplexTypeInfo(ClassLoader cl, String name)
+         throws ClassNotFoundException
+   {
       if (cl == null)
          cl = Thread.currentThread().getContextClassLoader();
 
@@ -308,8 +337,8 @@
       }
       else if (clazz.isEnum())
       {
-         EnumInfoImpl enumInfoImpl = new EnumInfoImpl(clazz.getName(), clazz.getModifiers()); 
-         result = enumInfoImpl; 
+         EnumInfoImpl enumInfoImpl = new EnumInfoImpl(clazz.getName(), clazz.getModifiers());
+         result = enumInfoImpl;
          Field[] fields = clazz.getFields();
          EnumConstantInfoImpl[] constants = new EnumConstantInfoImpl[fields.length];
          int i = 0;

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/javassist/JavassistTypeInfoFactoryImpl.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -37,11 +37,7 @@
 import org.jboss.reflect.plugins.AnnotationValueFactory;
 import org.jboss.reflect.plugins.AnnotationValueImpl;
 import org.jboss.reflect.plugins.EnumConstantInfoImpl;
-import org.jboss.reflect.spi.AnnotationInfo;
-import org.jboss.reflect.spi.AnnotationValue;
-import org.jboss.reflect.spi.PrimitiveInfo;
-import org.jboss.reflect.spi.TypeInfo;
-import org.jboss.reflect.spi.TypeInfoFactory;
+import org.jboss.reflect.spi.*;
 import org.jboss.util.JBossStringBuilder;
 import org.jboss.util.collection.WeakClassCache;
 
@@ -57,11 +53,11 @@
    static final AnnotationValue[] NO_ANNOTATIONS = new AnnotationValue[0];
    /**
     * Raise NoClassDefFoundError for javassist not found
-    * 
+    *
     * @param name the name
     * @param e the not found error
     * @return never
-    * @throws NoClassDefFoundError always 
+    * @throws NoClassDefFoundError always
     */
    public static NoClassDefFoundError raiseClassNotFound(String name, NotFoundException e) throws NoClassDefFoundError
    {
@@ -73,11 +69,11 @@
 
    /**
     * Raise NoClassDefFoundError for javassist not found
-    * 
+    *
     * @param name the name
     * @param e the not found error
     * @return never
-    * @throws NoClassDefFoundError always 
+    * @throws NoClassDefFoundError always
     */
    public static NoClassDefFoundError raiseClassNotFound(String name, ClassNotFoundException e) throws NoClassDefFoundError
    {
@@ -88,11 +84,11 @@
 
    /**
     * Raise NoClassDefFoundError for javassist not found
-    * 
+    *
     * @param name the name
     * @param e the not found error
     * @return never
-    * @throws NoClassDefFoundError always 
+    * @throws NoClassDefFoundError always
     */
    public static NoClassDefFoundError raiseMethodNotFound(String name, NotFoundException e) throws NoClassDefFoundError
    {
@@ -104,11 +100,11 @@
 
    /**
     * Raise NoClassDefFoundError for javassist not found
-    * 
+    *
     * @param name the name
     * @param e the not found error
     * @return never
-    * @throws NoClassDefFoundError always 
+    * @throws NoClassDefFoundError always
     */
    public static NoClassDefFoundError raiseFieldNotFound(String name, NotFoundException e) throws NoClassDefFoundError
    {
@@ -156,7 +152,7 @@
             return enumInfo;
          }
 
-         
+
          return new JavassistTypeInfo(this, ctClass, clazz);
       }
       catch (NotFoundException e)
@@ -167,7 +163,7 @@
 
    /**
     * Get the type info
-    * 
+    *
     * @param ctClass the ctClass
     * @return the typeinfo
     */
@@ -186,7 +182,7 @@
 
    /**
     * Convert name
-    * 
+    *
     * @param clazz the class
     * @return the converted name
     */
@@ -226,7 +222,7 @@
 
    /**
     * Get the CtClass
-    * 
+    *
     * @param name the name
     * @return the CtClass
     */
@@ -256,6 +252,16 @@
       if (primitive != null)
          return primitive;
 
+      NumberInfo number = NumberInfo.valueOf(clazz.getName());
+      if (number != null)
+      {
+         if (number.isInitialized() == false)
+         {
+            number.setDelegate((TypeInfo) get(clazz));
+         }
+         return number;
+      }
+
       return (TypeInfo) get(clazz);
    }
 
@@ -270,6 +276,16 @@
       if (primitive != null)
          return primitive;
 
+      NumberInfo number = NumberInfo.valueOf(name);
+      if (number != null)
+      {
+         if (number.isInitialized() == false)
+         {
+            number.setDelegate((TypeInfo) get(cl.loadClass(name)));
+         }
+         return number;
+      }
+
       Class clazz = cl.loadClass(name);
       return getTypeInfo(clazz);
    }
@@ -279,7 +295,7 @@
       if (type instanceof Class)
          return getTypeInfo((Class) type);
 
-      // TODO JBMICROCONT-129 getTypeInfo
+      // TODO JBMICROCONT-129 getTypeInfo + NumberInfo
       throw new org.jboss.util.NotImplementedException("getTypeInfo");
    }
 

Added: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,276 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.reflect.spi;
+
+import java.io.ObjectStreamException;
+import java.util.HashMap;
+import java.util.concurrent.atomic.AtomicInteger;
+import java.util.concurrent.atomic.AtomicLong;
+
+import org.jboss.util.JBossStringBuilder;
+
+/**
+ * Number info
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class NumberInfo extends PrimitiveInfo implements ClassInfo
+{
+   /** serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   /** The byte info */
+   public static final NumberInfo BYTE_OBJECT = new NumberInfo(0, Byte.class);
+
+   /** The double info */
+   public static final NumberInfo DOUBLE_OBJECT = new NumberInfo(1, Double.class);
+
+   /** The float info */
+   public static final NumberInfo FLOAT_OBJECT = new NumberInfo(2, Float.class);
+
+   /** The int info */
+   public static final NumberInfo INT_OBJECT = new NumberInfo(3, Integer.class);
+
+   /** The long info */
+   public static final NumberInfo LONG_OBJECT = new NumberInfo(4, Long.class);
+
+   /** The short info */
+   public static final NumberInfo SHORT_OBJECT = new NumberInfo(5, Short.class);
+
+   /** The atomic int info */
+   public static final NumberInfo ATOMIC_INT = new NumberInfo(6, AtomicInteger.class);
+
+   /** The atomic long info */
+   public static final NumberInfo ATOMIC_LONG = new NumberInfo(7, AtomicLong.class);
+
+   /** The primitives */
+   private static final NumberInfo[] values = {
+         BYTE_OBJECT,
+         DOUBLE_OBJECT,
+         FLOAT_OBJECT,
+         INT_OBJECT,
+         LONG_OBJECT,
+         SHORT_OBJECT,
+         ATOMIC_INT,
+         ATOMIC_LONG
+   };
+
+   /** The primitives */
+   private static final HashMap<String, NumberInfo> map = new HashMap<String, NumberInfo>();
+
+   static
+   {
+      map.put(Byte.class.getName(), NumberInfo.BYTE_OBJECT);
+      map.put(Double.class.getName(), NumberInfo.DOUBLE_OBJECT);
+      map.put(Float.class.getName(), NumberInfo.FLOAT_OBJECT);
+      map.put(Integer.class.getName(), NumberInfo.INT_OBJECT);
+      map.put(Long.class.getName(), NumberInfo.LONG_OBJECT);
+      map.put(Short.class.getName(), NumberInfo.SHORT_OBJECT);
+      map.put(AtomicInteger.class.getName(), NumberInfo.ATOMIC_INT);
+      map.put(AtomicLong.class.getName(), NumberInfo.ATOMIC_LONG);
+   }
+
+   private transient ClassInfo delegate;
+
+   /**
+    * Get the primitive info for a type
+    *
+    * @param name the name
+    * @return the info
+    */
+   public static NumberInfo valueOf(String name)
+   {
+      return map.get(name);
+   }
+
+   /**
+    * Create a new number info
+    *
+    * @param ordinal the oridinal
+    * @param type the class
+    */
+   protected NumberInfo(int ordinal, Class<? extends Object> type)
+   {
+      super(type.getName(), ordinal, type);
+   }
+
+   public void setDelegate(TypeInfo info)
+   {
+      if (info instanceof ClassInfo == false)
+      {
+         throw new IllegalArgumentException("Should be of classType instance: " + info);
+      }
+      delegate = (ClassInfo) info;
+   }
+
+   public boolean isInitialized()
+   {
+      return (delegate != null);
+   }
+
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null)
+         return false;
+      if (!(obj instanceof NumberInfo))
+         return false;
+      if (!obj.getClass().equals(this.getClass()))
+         return false;
+      NumberInfo other = (NumberInfo) obj;
+      return other.ordinal == this.ordinal;
+   }
+
+   Object readResolve() throws ObjectStreamException
+   {
+      return values[ordinal];
+   }
+
+   // --- delegate
+
+   public ConstructorInfo getDeclaredConstructor(TypeInfo[] parameters)
+   {
+      return delegate.getDeclaredConstructor(parameters);
+   }
+
+   public ConstructorInfo[] getDeclaredConstructors()
+   {
+      return delegate.getDeclaredConstructors();
+   }
+
+   public FieldInfo getDeclaredField(String name)
+   {
+      return delegate.getDeclaredField(name);
+   }
+
+   public FieldInfo[] getDeclaredFields()
+   {
+      return delegate.getDeclaredFields();
+   }
+
+   public MethodInfo getDeclaredMethod(String name, TypeInfo[] parameters)
+   {
+      return delegate.getDeclaredMethod(name, parameters);
+   }
+
+   public MethodInfo[] getDeclaredMethods()
+   {
+      return delegate.getDeclaredMethods();
+   }
+
+   public InterfaceInfo[] getGenericInterfaces()
+   {
+      return delegate.getGenericInterfaces();
+   }
+
+   public ClassInfo getGenericSuperclass()
+   {
+      return delegate.getGenericSuperclass();
+   }
+
+   public InterfaceInfo[] getInterfaces()
+   {
+      return delegate.getInterfaces();
+   }
+
+   public ClassInfo getSuperclass()
+   {
+      return delegate.getSuperclass();
+   }
+
+   public boolean isInterface()
+   {
+      return delegate.isInterface();
+   }
+
+   public AnnotationValue getAnnotation(String name)
+   {
+      return delegate.getAnnotation(name);
+   }
+
+   public AnnotationValue[] getAnnotations()
+   {
+      return delegate.getAnnotations();
+   }
+
+   public boolean isAnnotationPresent(String name)
+   {
+      return delegate.isAnnotationPresent(name);
+   }
+
+   public int getModifiers()
+   {
+      return delegate.getModifiers();
+   }
+
+   public boolean isPublic()
+   {
+      return delegate.isPublic();
+   }
+
+   public boolean isStatic()
+   {
+      return delegate.isStatic();
+   }
+
+   public boolean isPrimitive()
+   {
+      return delegate.isPrimitive();
+   }
+
+   public TypeInfo[] getActualTypeArguments()
+   {
+      return delegate.getActualTypeArguments();
+   }
+
+   public TypeInfo getOwnerType()
+   {
+      return delegate.getOwnerType();
+   }
+
+   public ClassInfo getRawType()
+   {
+      return delegate;
+   }
+
+   protected int getHashCode()
+   {
+      return delegate.hashCode();
+   }
+
+   public String toShortString()
+   {
+      return name;
+   }
+
+   public void toShortString(JBossStringBuilder builder)
+   {
+      builder.append(name);
+   }
+  
+   public Object clone()
+   {
+      return this;
+   }
+
+}

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/PrimitiveInfo.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -146,6 +146,11 @@
    
    public Object convertValue(Object value) throws Throwable
    {
+      Object progressResult = ValueConvertor.progressValue(type, value);
+      if (progressResult != null)
+      {
+         return progressResult;
+      }
       return ValueConvertor.convertValue(type, value);
    }
 

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractBeanMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractBeanMetaData.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractBeanMetaData.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -506,6 +506,7 @@
          throw new IllegalArgumentException("Bean not yet installed: " + name);
       }
       Object target = context.getTarget();
+      // TODO - add progression here as well?
       if (info != null && info.getType().isAssignableFrom(target.getClass()) == false)
       {
          throw new ClassCastException(target + " is not a " + info);

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractDependencyValueMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractDependencyValueMetaData.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractDependencyValueMetaData.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -150,9 +150,9 @@
          BeanInfo beanInfo = configurator.getBeanInfo(result.getClass());
          TargettedJoinpoint joinpoint = configurator.getPropertyGetterJoinPoint(beanInfo, property);
          joinpoint.setTarget(result);
-         return joinpoint.dispatch();
+         result = joinpoint.dispatch();
       }
-      return result;
+      return info != null ? info.convertValue(result) : result;
    }
 
    public void initialVisit(MetaDataVisitor visitor)

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractInjectionValueMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractInjectionValueMetaData.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractInjectionValueMetaData.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -102,6 +102,7 @@
          {
             throw new IllegalArgumentException("Possible multiple matching beans, see log for info.");
          }
+         // TODO - add progression here, then fix BeanMetaData as well
          return context.getTarget();
       }
       return super.getValue(info, cl);

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractValueMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractValueMetaData.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/AbstractValueMetaData.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -80,7 +80,7 @@
 
    public Object getValue(TypeInfo info, ClassLoader cl) throws Throwable
    {
-      return value;
+      return info != null ? info.convertValue(value) : value;
    }
 
    public void initialVisit(MetaDataVisitor visitor)

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ThisValueMetaData.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ThisValueMetaData.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ThisValueMetaData.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -53,6 +53,7 @@
       ControllerContext context = controller.getContext(value, ControllerState.INSTANTIATED);
       if (context == null)
          throw new Error("Could not deference this " + this);
+      // TODO - add progression, see BeanMetaData, InjectionMetaData
       return context.getTarget();
    }
 

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/config/Configurator.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -46,6 +46,8 @@
 import org.jboss.reflect.spi.ConstructorInfo;
 import org.jboss.reflect.spi.MethodInfo;
 import org.jboss.reflect.spi.TypeInfo;
+import org.jboss.reflect.plugins.ProgressionConvertor;
+import org.jboss.reflect.plugins.ProgressionConvertorFactory;
 
 /**
  * Configuration utilities.
@@ -71,7 +73,7 @@
          configure(result, info, metaData);
       return result;
    }
-   
+
    /**
     * Instantiate a bean
     * 
@@ -93,7 +95,7 @@
       Joinpoint joinPoint = getConstructorJoinPoint(config, info, constructor, metaData);
       return joinPoint.dispatch();
    }
-   
+
    /**
     * Get a constructor joinpoint
     * 
@@ -108,7 +110,7 @@
       throws Throwable
    {
       boolean trace = log.isTraceEnabled();
-      
+
       if (trace)
          log.trace("Get constructor joinpoint info=" + info + " constructor=" + metaData);
 
@@ -127,7 +129,7 @@
                typeInfo = info.getClassInfo();
             return new ValueJoinpoint(vmd, typeInfo, cl);
          }
-         
+
          vmd = metaData.getFactory();
          if (vmd != null)
          {
@@ -139,7 +141,7 @@
 
             // Describe the factory
             BeanInfo factoryInfo = config.getBeanInfo(factory.getClass());
-            
+
             // Find the method
             MethodJoinpoint joinPoint = findMethod(trace, factoryInfo, cl, metaData.getFactoryMethod(), parameters, false, true);
             joinPoint.setTarget(factory);
@@ -154,7 +156,7 @@
             }
             return joinPoint;
          }
-         
+
          String factoryClassName = metaData.getFactoryClass();
          if (factoryClassName != null)
          {
@@ -176,11 +178,11 @@
             }
             return joinPoint;
          }
-         
+
          // Find the constructor
          ConstructorJoinpoint joinPoint = findConstructor(trace, info, metaData, beanMetaData);
          ConstructorInfo cinfo = joinPoint.getConstructorInfo();
-         
+
          // Set the parameters
          if (cinfo != null)
          {
@@ -190,11 +192,11 @@
          }
          return joinPoint;
       }
-      
+
       // Default constructor
       return findConstructor(trace, info, metaData, beanMetaData);
    }
-   
+
    /**
     * Find a constructor
     * 
@@ -211,7 +213,7 @@
       JoinpointFactory jpf = info.getJoinpointFactory();
       return jpf.getConstructorJoinpoint(cinfo);
    }
-   
+
    /**
     * Resolve a constructor
     * 
@@ -264,7 +266,7 @@
       if (properties != null && properties.isEmpty() == false)
       {
          ClassLoader cl = getClassLoader(metaData);
-         
+
          for (Iterator i = metaData.getProperties().iterator(); i.hasNext();)
          {
             PropertyMetaData property = (PropertyMetaData) i.next();
@@ -333,13 +335,13 @@
    {
       if (trace)
          log.trace("Configuring info=" + info + " metaData=" + metaData);
-      
+
       TargettedJoinpoint joinPoint = getPropertySetterJoinPoint(trace, info, cl, metaData.getValue());
       joinPoint.setTarget(object);
-      
+
       if (trace)
          log.trace("Setting property " + joinPoint);
-      
+
       joinPoint.dispatch();
    }
 
@@ -373,7 +375,7 @@
 
       if (info == null)
          throw new IllegalArgumentException("Null property info");
-      
+
       JoinpointFactory jpf = info.getBeanInfo().getJoinpointFactory();
       MethodInfo minfo = info.getGetter();
       return getMethodJoinpoint(null, jpf, minfo.getName(), null, null);
@@ -395,13 +397,13 @@
          throw new IllegalArgumentException("Null bean info");
       if (metaData == null)
          throw new IllegalArgumentException("Null bean metadata");
-      
+
       Set<TargettedJoinpoint> result = new HashSet<TargettedJoinpoint>();
       Set<PropertyMetaData> propertys = metaData.getProperties();
       if (propertys != null && propertys.isEmpty() == false)
       {
          ClassLoader cl = getClassLoader(metaData);
-         
+
          for (Iterator i = metaData.getProperties().iterator(); i.hasNext();)
          {
             PropertyMetaData property = (PropertyMetaData) i.next();
@@ -409,7 +411,7 @@
             result.add(joinPoint);
          }
       }
-      
+
       return result;
    }
 
@@ -495,7 +497,7 @@
          throw new IllegalArgumentException("Null property info");
       if (metaData == null)
          throw new IllegalArgumentException("Null value metadata");
-      
+
       TypeInfo type = info.getType();
       Object value = metaData.getValue(type, cl);
       JoinpointFactory jpf = info.getBeanInfo().getJoinpointFactory();
@@ -505,7 +507,7 @@
       String[] parameterTypes = getParameterTypes(trace, minfo.getParameterTypes());
       return getMethodJoinpoint(null, jpf, minfo.getName(), parameterTypes, new Object[] { value });
    }
-   
+
    /**
     * Unconfigure a bean
     * 
@@ -563,16 +565,16 @@
    {
       if (trace)
          log.trace("Unconfiguring info=" + info + " metaData=" + metaData);
-      
+
       TargettedJoinpoint joinPoint = getPropertyNullerJoinPoint(info, metaData);
       joinPoint.setTarget(object);
-      
+
       if (trace)
          log.trace("Unsetting property " + joinPoint);
-      
+
       joinPoint.dispatch();
    }
-   
+
    /**
     * Get property nuller joinpoints for a bean
     * 
@@ -646,16 +648,16 @@
       boolean trace = log.isTraceEnabled();
       if (trace)
          log.trace("Get property nuller join point info=" + info + " metaData=" + metaData);
-      
+
       if (info == null)
          throw new IllegalArgumentException("Null property info");
-      
+
       JoinpointFactory jpf = info.getBeanInfo().getJoinpointFactory();
       MethodInfo minfo = info.getSetter();
       String[] parameterTypes = getParameterTypes(trace, minfo.getParameterTypes());
       return getMethodJoinpoint(null, jpf, minfo.getName(), parameterTypes, new Object[] { null });
    }
-   
+
    /**
     * Get the property info
     * 
@@ -707,10 +709,10 @@
             }
          }
       }
-      
+
       throw new JoinpointException("Property " + name + " not found for " + info);
    }
-   
+
    /**
     * Find a method
     * 
@@ -728,7 +730,7 @@
       boolean trace = log.isTraceEnabled();
       return findMethod(trace, info, cl, name, parameters, isStatic, isPublic);
    }
-   
+
    /**
     * Find a method
     * 
@@ -761,10 +763,10 @@
          Object[] params = getParameters(trace, cl, pinfos, parameters);
          joinPoint.setArguments(params);
       }
-      
+
       return joinPoint;
    }
-   
+
    /**
     * Get the parameters types
     * 
@@ -777,7 +779,7 @@
    {
       if (parameters == null)
          return null;
-      
+
       String[] paramTypes = new String[parameters.size()];
       int x = 0;
       for (Iterator i = parameters.iterator(); i.hasNext();)
@@ -787,7 +789,7 @@
       }
       return paramTypes;
    }
-   
+
    /**
     * Get the parameters types
     * 
@@ -800,14 +802,14 @@
    {
       if (parameters == null)
          return null;
-      
+
       String[] paramTypes = new String[parameters.length];
       int x = 0;
       for (int i = 0; i < parameters.length; ++i)
          paramTypes[x++] = parameters[i].getName();
       return paramTypes;
    }
-   
+
    /**
     * Get the parameters
     * 
@@ -822,7 +824,7 @@
    {
       if (parameters == null)
          return null;
-      
+
       Object[] params = new Object[parameters.size()];
       int x = 0;
       for (Iterator i = parameters.iterator(); i.hasNext();)
@@ -916,7 +918,7 @@
     * @param typeInfos the type infos
     * @return true when we can use progression
     */
-   public static boolean progression(ClassLoader cl, String[] typeNames, TypeInfo[] typeInfos)
+   public static boolean progression(ClassLoader cl, String[] typeNames, TypeInfo[] typeInfos) throws Throwable
    {
       if (cl == null)
          return false;
@@ -924,7 +926,20 @@
       if (simpleCheck(typeNames, typeInfos) == false)
          return false;
 
-      // JBMICROCONT-119: todo - write this + actual progression code at value injection
+      // convertor
+      ProgressionConvertor convertor = ProgressionConvertorFactory.getInstance().getConvertor();
+
+      for (int i = 0; i < typeNames.length; ++i)
+      {
+         if (typeNames[i] != null)
+         {
+            Class clazz = Class.forName(typeNames[i], true, cl);
+            if (convertor.canProgress(typeInfos[i].getType(), clazz) == false)
+            {
+               return false;
+            }
+         }
+      }
       return false;
    }
 
@@ -934,14 +949,14 @@
    private static class ValueJoinpoint implements Joinpoint
    {
       /** The value metadata */
-      private ValueMetaData vmd; 
-      
+      private ValueMetaData vmd;
+
       /** The type info */
       private TypeInfo info;
-      
+
       /** The classloader */
       private ClassLoader cl;
-      
+
       /**
        * Create a new ValueJoinpoint.
        * 
@@ -955,7 +970,7 @@
          this.info = info;
          this.cl = cl;
       }
-      
+
       public Object dispatch() throws Throwable
       {
          return vmd.getValue(info, cl);
@@ -977,6 +992,6 @@
             throw new Error(e);
          }
       }
-      
+
    }
 }

Added: projects/microcontainer/trunk/kernel/src/resources/xml-test/org/jboss/test/kernel/config/test/testProgressionFromOtherBean.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/xml-test/org/jboss/test/kernel/config/test/testProgressionFromOtherBean.xml	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/resources/xml-test/org/jboss/test/kernel/config/test/testProgressionFromOtherBean.xml	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,19 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+            xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd"
+            xmlns="urn:jboss:bean-deployer">
+
+   <bean name="FromBean" class="org.jboss.test.kernel.config.support.SimpleBean">
+      <property name="adouble">123.456</property>
+      <property name="AFloat" class="java.lang.Float">987.6543</property>
+      <property name="anInt">314159</property>
+   </bean>
+
+   <bean name="SimpleBean" class="org.jboss.test.kernel.config.support.SimpleBean">
+      <property name="anint"><inject bean="FromBean" property="adouble" /></property>
+      <property name="AShort"><inject bean="FromBean" property="AFloat" /></property>
+      <property name="AFloat"><inject bean="FromBean" property="anInt" /></property>
+   </bean>
+
+</deployment>

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ConfigTestSuite.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -62,7 +62,9 @@
       suite.addTest(ArrayXMLTestCase.suite());
       suite.addTest(MapTestCase.suite());
       suite.addTest(MapXMLTestCase.suite());
-      
+      suite.addTest(ProgressionTestCase.suite());
+      suite.addTest(ProgressionXMLTestCase.suite());
+
       return suite;
    }
 }

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,74 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.config.test;
+
+import junit.framework.Test;
+import org.jboss.beans.metadata.plugins.AbstractBeanMetaData;
+import org.jboss.beans.metadata.plugins.AbstractPropertyMetaData;
+import org.jboss.kernel.Kernel;
+import org.jboss.kernel.spi.config.KernelConfigurator;
+import org.jboss.test.kernel.config.support.SimpleBean;
+
+/**
+ * Progression Test Case.
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ProgressionTestCase extends AbstractKernelConfigTest
+{
+   public static Test suite()
+   {
+      return suite(ProgressionTestCase.class);
+   }
+
+   public ProgressionTestCase(String name)
+   {
+      super(name);
+   }
+
+   public ProgressionTestCase(String name, boolean xmltest)
+   {
+      super(name, xmltest);
+   }
+
+   public void testProgressionFromOtherBean() throws Throwable
+   {
+      SimpleBean bean = instantiateProgressionBeans();
+      assertEquals(123, bean.getAnint());
+      assertEquals((short)987, bean.getAShort().shortValue());
+      assertEquals(314159f, bean.getAFloat().floatValue());
+   }
+
+   protected SimpleBean instantiateProgressionBeans() throws Throwable
+   {
+      Kernel kernel = bootstrap();
+      KernelConfigurator configurator = kernel.getConfigurator();
+
+      AbstractBeanMetaData bmd = new AbstractBeanMetaData(SimpleBean.class.getName());
+      bmd.addProperty(new AbstractPropertyMetaData("anint", 123.456));
+      bmd.addProperty(new AbstractPropertyMetaData("AShort", 987.6543));
+      bmd.addProperty(new AbstractPropertyMetaData("AFloat", 314159));
+
+      return (SimpleBean) instantiateAndConfigure(configurator, bmd);
+   }
+
+}

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionXMLTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionXMLTestCase.java	2006-12-21 16:01:30 UTC (rev 59199)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionXMLTestCase.java	2006-12-21 18:22:23 UTC (rev 59200)
@@ -0,0 +1,51 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.config.test;
+
+import junit.framework.Test;
+import org.jboss.test.kernel.config.support.SimpleBean;
+import org.jboss.test.kernel.config.support.XMLUtil;
+
+/**
+ * Progression XML Test Case.
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ProgressionXMLTestCase extends ProgressionTestCase
+{
+   public static Test suite()
+   {
+      return suite(ProgressionXMLTestCase.class);
+   }
+
+   public ProgressionXMLTestCase(String name)
+   {
+      super(name, true);
+   }
+
+   protected SimpleBean instantiateProgressionBeans() throws Throwable
+   {
+      XMLUtil util = bootstrapXML(true);
+      return (SimpleBean) util.getBean("SimpleBean");
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 14:03:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 14:03:49 -0500
Subject: [jboss-cvs] JBossAS SVN: r59201 -
	branches/Branch_4_2/system/src/main/org/jboss/system
Message-ID: <E1GxTCn-0004EA-AS@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-21 14:03:46 -0500 (Thu, 21 Dec 2006)
New Revision: 59201

Modified:
   branches/Branch_4_2/system/src/main/org/jboss/system/BarrierController.java
   branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java
Log:
JBAS-3469, Enhance the BarrierController with the ability to destroy/re-create the Barrier

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/BarrierController.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/BarrierController.java	2006-12-21 18:22:23 UTC (rev 59200)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/BarrierController.java	2006-12-21 19:03:46 UTC (rev 59201)
@@ -61,14 +61,23 @@
    private ObjectName barrierName;
 
    /** The initial state of the barrier */
+   private Boolean createOnStartup;
+   
+   /** The initial state of the barrier */
    private Boolean enableOnStartup;
    
+   /** The notification subscription handback string that creates the barrier */ 
+   private String createHandback;
+   
    /** The notification subscription handback string that starts the barrier */ 
    private String startHandback;
    
    /** The notification subscription handback string that stops the barrier */
    private String stopHandback;
    
+   /** The notification subscription handback string that destroys the barrier */ 
+   private String destroyHandback;
+   
    /** The dynamic subscriptions flag */
    private Boolean dynamicSubscriptions;
    
@@ -123,8 +132,35 @@
       return barrierName;
    }
 
-
    /**
+    * Whether the Barrier should be created on startup
+    * 
+    * @jmx.managed-attribute
+    */
+   public void setBarrierCreatedOnStartup(Boolean createOnStartup)
+   {
+      // set once
+      if (this.createOnStartup == null)
+      {
+         this.createOnStartup = createOnStartup;
+      }
+   }
+   
+   /**
+    * Whether the Barrier should be created on startup
+    * 
+    * @jmx.managed-attribute
+    */   
+   public Boolean getBarrierCreatedOnStartup()
+   {
+      if (createOnStartup == null)
+      {
+         createOnStartup = Boolean.TRUE;
+      }
+      return createOnStartup;
+   }
+   
+   /**
     * The initial state of the barrier.
     * 
     * If set, it overrides the internal call to enableOnStartup()
@@ -140,7 +176,7 @@
          this.enableOnStartup = enableOnStartup;
       }
    }
-
+   
    /**
     * The initial state of the barrier.
     * 
@@ -162,6 +198,30 @@
    }
    
    /**
+    * The notification subscription handback string that creates the barrier.
+    * 
+    * @jmx.managed-attribute
+    */   
+   public void setCreateBarrierHandback(String createHandback)
+   {
+      // set once
+      if (this.createHandback == null)
+      {
+         this.createHandback = createHandback;
+      }
+   }
+
+   /**
+    * The notification subscription handback string that creates the barrier.
+    * 
+    * @jmx.managed-attribute
+    */   
+   public String getCreateBarrierHandback()
+   {
+      return createHandback;
+   }
+   
+   /**
     * The notification subscription handback string that starts the barrier.
     * 
     * @jmx.managed-attribute
@@ -210,6 +270,30 @@
    }
    
    /**
+    * The notification subscription handback string that destroys the barrier.
+    * 
+    * @jmx.managed-attribute
+    */   
+   public void setDestroyBarrierHandback(String destroyHandback)
+   {
+      // set once
+      if (this.destroyHandback == null)
+      {
+         this.destroyHandback = destroyHandback;
+      }
+   }
+   
+   /**
+    * The notification subscription handback string that destroys the barrier.
+    * 
+    * @jmx.managed-attribute
+    */   
+   public String getDestroyBarrierHandback()
+   {
+      return destroyHandback;
+   }
+   
+   /**
     * The ability to dynamically subscribe for notifications.
     *
     * @jmx.managed-attribute
@@ -263,14 +347,19 @@
       // register with the MBeanServer
       getServer().registerMBean(barrier, barrierName);
       
-      // implicitly call the ServiceController
-      barrier.create();
+      // conditionally put the Barrier in create state
+      if (getBarrierCreatedOnStartup().booleanValue())
+      {
+         // implicitly call the ServiceController
+         barrier.create();
+      }
       
-      // conditionally start the barrier
+      // conditionally put the Barrier in start state
       if (getBarrierEnabledOnStartup().booleanValue())
       {
          startBarrier();
       }
+      
       // subscribe for notifications
       subscribe(getDynamicSubscriptions().booleanValue());
    }
@@ -280,17 +369,17 @@
       // unsubscribe for notifications
       unsubscribe();
 
+      // put the Barrier in destroy state
+      destroyBarrier();
+      
       try
       {
-         // implicitly call the ServiceController
-         barrier.destroy();
-      
          // remove from MBeanServer
          getServer().unregisterMBean(barrierName);
       }
       catch (Throwable e)
       {
-         log.debug("Unexpected error during destroy", e);
+         log.debug("Unexpected error during Barrier unregister", e);
       }
       
       // cleanup
@@ -307,8 +396,13 @@
    {
       log.debug("Got notification: " + n);
       
-      if (startHandback != null && startHandback.equals(handback))
+      if (createHandback != null && createHandback.equals(handback))
       {
+         log.debug("Saw '" + handback + "' handback, creating barrier");
+         createBarrier();
+      }      
+      else if (startHandback != null && startHandback.equals(handback))
+      {
          log.debug("Saw '" + handback + "' handback, starting barrier");
          startBarrier();
       }
@@ -317,11 +411,34 @@
          log.debug("Saw '" + handback + "' handback, stopping barrier");
          stopBarrier();
       }
+      else if (destroyHandback != null && destroyHandback.equals(handback))
+      {
+         log.debug("Saw '" + handback + "' handback, destroying barrier");
+         destroyBarrier();
+      }
    }
    
    // Operations ----------------------------------------------------
 
    /**
+    * Manually create the controlled barrier
+    * 
+    * @jmx:managed-operation
+    */
+   public void createBarrier()
+   {
+      try
+      {
+         // implicitly call the ServiceController
+         barrier.create();
+      }
+      catch (Throwable e)
+      {
+         log.warn("Failed to create barrier: " + barrierName, e);
+      }
+   }
+   
+   /**
     * Manually start the controlled barrier
     * 
     * @jmx:managed-operation
@@ -357,6 +474,24 @@
       }
    }
    
+   /**
+    * Manually destroy the controlled barrier
+    * 
+    * @jmx:managed-operation
+    */
+   public void destroyBarrier()
+   {
+      try
+      {
+         // implicitly call the ServiceController
+         barrier.destroy();
+      }
+      catch (Throwable e)
+      {
+         log.warn("Failed to destroy barrier: " + barrierName, e);
+      }
+   }
+   
    // Inner Class ---------------------------------------------------
    
    /**

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 18:22:23 UTC (rev 59200)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/BarrierControllerMBean.java	2006-12-21 19:03:46 UTC (rev 59201)
@@ -47,11 +47,18 @@
    void setBarrierObjectName(ObjectName barrierName);   
    ObjectName getBarrierObjectName();
    
-   /** The initial state of the barrier. If set, it overrides the internal call
-    * to enableOnStartup() which will never get called. */
-   void setBarrierEnabledOnStartup(Boolean enableOnStartup);
+   /** Whether the Barrier should be created on startup */
+   void setBarrierCreatedOnStartup(Boolean createdOnStartup);
+   Boolean getBarrierCreatedOnStartup();
+   
+   /** Whether the Barrier should be started on startup. */
+   void setBarrierEnabledOnStartup(Boolean startedOnStartup);
    Boolean getBarrierEnabledOnStartup();
    
+   /** The notification subscription handback string that creates the barrier. */
+   void setCreateBarrierHandback(String createHandback);
+   String getCreateBarrierHandback();
+   
    /** The notification subscription handback string that starts the barrier. */
    void setStartBarrierHandback(String startHandback);
    String getStartBarrierHandback();
@@ -59,6 +66,10 @@
    /** The notification subscription handback string that stops the barrier. */
    void setStopBarrierHandback(String stopHandback);
    String getStopBarrierHandback();
+   
+   /** The notification subscription handback string that destroys the barrier. */
+   void setDestroyBarrierHandback(String destroyHandback);
+   String getDestroyBarrierHandback();   
 
    /** The ability to dynamically subscribe for notifications. */
    void setDynamicSubscriptions(Boolean dynamicSubscriptions);
@@ -67,6 +78,11 @@
    // Operations ----------------------------------------------------
    
    /**
+    * Manually create the controlled barrier
+    */
+   void createBarrier();
+   
+   /**
     * Manually start the controlled barrier
     */
    void startBarrier();
@@ -76,4 +92,9 @@
     */
    void stopBarrier();
 
+   /**
+    * Manually destroy the controlled barrier
+    */
+   void destroyBarrier();
+   
 }



From sohil.shah at jboss.com  Thu Dec 21 14:26:20 2006
From: sohil.shah at jboss.com (Sohil Shah)
Date: Thu, 21 Dec 2006 14:26:20 -0500
Subject: [jboss-cvs] repository.jboss.com/jbpm/3.1.2/lib  ...
Message-ID: <E1GxTYa-0004dB-IB@committer01.frg.pub.inap.atl.jboss.com>

  User: sshah   
  Date: 06/12/21 14:26:20

  Added:       jbpm/3.1.2/lib  jbpm-3.1.2.jar
  Log:
  adding
  
  Revision  Changes    Path
  1.1      date: 2006/12/21 19:26:20;  author: sshah;  state: Exp;repository.jboss.com/jbpm/3.1.2/lib/jbpm-3.1.2.jar
  
  	<<Binary file>>
  
  


From sohil.shah at jboss.com  Thu Dec 21 14:26:45 2006
From: sohil.shah at jboss.com (Sohil Shah)
Date: Thu, 21 Dec 2006 14:26:45 -0500
Subject: [jboss-cvs] repository.jboss.com/jbpm/3.1.2/lib  ...
Message-ID: <E1GxTYz-0004dw-Tr@committer01.frg.pub.inap.atl.jboss.com>

  User: sshah   
  Date: 06/12/21 14:26:45

  Added:       jbpm/3.1.2/lib  jbpm-identity-3.1.2.jar
  Log:
  adding
  
  Revision  Changes    Path
  1.1      date: 2006/12/21 19:26:45;  author: sshah;  state: Exp;repository.jboss.com/jbpm/3.1.2/lib/jbpm-identity-3.1.2.jar
  
  	<<Binary file>>
  
  


From sohil.shah at jboss.com  Thu Dec 21 14:28:52 2006
From: sohil.shah at jboss.com (Sohil Shah)
Date: Thu, 21 Dec 2006 14:28:52 -0500
Subject: [jboss-cvs] repository.jboss.com/jbpm/3.1.2  ...
Message-ID: <E1GxTb2-0004fk-OH@committer01.frg.pub.inap.atl.jboss.com>

  User: sshah   
  Date: 06/12/21 14:28:52

  Modified:    jbpm/3.1.2  component-info.xml
  Log:
  adding_jars
  
  Revision  Changes    Path
  1.2       +5 -0      repository.jboss.com/jbpm/3.1.2/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jbpm/3.1.2/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	9 Oct 2006 09:52:16 -0000	1.1
  +++ component-info.xml	21 Dec 2006 19:28:52 -0000	1.2
  @@ -6,8 +6,13 @@
                 projectHome="http://jbpm.org/"
                 description="Powerfull BPM and workflow engine in Java">
         <artifact id="jbpm.zip"/>
  +      <artifact id="jbpm-3.1.2.jar"/>
  +      <artifact id="jbpm-identity-3.1.2.jar"/>
  +      
         <export>
           <include input="jbpm.zip"/>
  +        <include input="jbpm-3.1.2.jar"/>
  +        <include input="jbpm-identity-3.1.2.jar"/>
         </export>
   
      </component>
  
  
  


From validimir.ralev at jboss.com  Thu Dec 21 14:58:33 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Thu, 21 Dec 2006 14:58:33 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib ...
Message-ID: <E1GxU3l-00058P-9h@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/21 14:58:33

  Modified:    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib     
                        installer.jar izevent.jar standalone-compiler.jar
                        uninstaller.jar uninstaller-ext.jar
  Log:
  http://jira.jboss.com/jira/browse/JBINSTALL-166
  
  Revision  Changes    Path
  1.3       +115 -119  /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/installer.jar
  
  	<<Binary file>>
  
  
  1.2       +6 -6      /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/izevent.jar
  
  	<<Binary file>>
  
  
  1.3       +2636 -2596/repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar
  
  	<<Binary file>>
  
  
  1.3       +39 -43    /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller.jar
  
  	<<Binary file>>
  
  
  1.3       +34 -38    /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller-ext.jar
  
  	<<Binary file>>
  
  


From norman.richards at jboss.com  Thu Dec 21 15:19:03 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Thu, 21 Dec 2006 15:19:03 -0500
Subject: [jboss-cvs] jboss-seam/src/ui/org/jboss/seam/ui   ...
Message-ID: <E1GxUNb-0005dd-Lg@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/21 15:19:03

  Modified:    src/ui/org/jboss/seam/ui   SelectDate.java selectDate.js
  Log:
  JBSEAM-623: support locales for selectDate display
  
  Revision  Changes    Path
  1.4       +52 -2     jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SelectDate.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/SelectDate.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SelectDate.java	14 Dec 2006 09:10:55 -0000	1.3
  +++ SelectDate.java	21 Dec 2006 20:19:03 -0000	1.4
  @@ -3,6 +3,9 @@
   import java.io.IOException;
   import java.io.InputStream;
   import java.io.InputStreamReader;
  +import java.text.DateFormatSymbols;
  +import java.util.Calendar;
  +import java.util.Locale;
   import java.util.Map;
   
   import javax.faces.component.UIComponent;
  @@ -95,6 +98,15 @@
           request.put("SELECTDATE_SCRIPT", scriptResource);
           
           ResponseWriter response = context.getResponseWriter();
  +
  +        writeLocaleInformation(response, context.getViewRoot().getLocale());        
  +        writeScriptFromResource(response, scriptResource);
  +    }
  +
  +    private void writeScriptFromResource(ResponseWriter response, 
  +                                         String scriptResource) 
  +        throws IOException 
  +    {
           response.startElement("script", null);
           response.writeAttribute("type", "text/javascript", null);
           InputStream is = this.getClass().getClassLoader().getResourceAsStream(scriptResource);
  @@ -117,4 +129,42 @@
           response.endElement("script");
       }
                               
  +
  +
  +    private void writeLocaleInformation(ResponseWriter response, 
  +                                        Locale locale) throws IOException 
  +    {
  +        response.startElement("script", null);
  +        response.writeAttribute("type", "text/javascript", null);
  +        
  +        Calendar cal = Calendar.getInstance(locale);
  +        DateFormatSymbols symbols = new DateFormatSymbols(locale);
  +                
  +        // Note: Calendar and DateFormatSymbols use 1 for the first day of the week, not 0.
  +        
  +        response.write("\r");
  +        response.write("var dayArrayShort = " + getArray(symbols.getShortWeekdays(), 1) + ";\r");
  +        response.write("var dayArrayMed = " + getArray(symbols.getShortWeekdays(), 1) + ";\r");
  +        response.write("var dayArrayLong = " + getArray(symbols.getWeekdays(), 1) + ";\r");
  +        response.write("var monthArrayShort = " + getArray(symbols.getShortMonths(), 0) + ";\r");
  +        response.write("var monthArrayMed = " + getArray(symbols.getShortMonths(), 0) + ";\r");
  +        response.write("var monthArrayLong = " + getArray(symbols.getMonths(), 0) + ";\r");
  +        response.write("var firstDayInWeek = " + (cal.getFirstDayOfWeek() - 1) + ";\r");
  +        
  +        response.endElement("script");
  +    }
  +    
  +    private StringBuilder getArray(String[] values, int start) throws IOException {
  +        StringBuilder s = new StringBuilder();
  +        s.append("new Array(");
  +        for (int i = start; i < values.length; i++) {
  +            if (i > start) {
  +                s.append(", ");
  +            }
  +            s.append("'").append(values[i]).append("'");
  +        }
  +        s.append(")");
  +        return s;
  +    }
  +                         
   }
  
  
  
  1.3       +38 -18    jboss-seam/src/ui/org/jboss/seam/ui/selectDate.js
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: selectDate.js
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/ui/org/jboss/seam/ui/selectDate.js,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- selectDate.js	8 Dec 2006 00:37:04 -0000	1.2
  +++ selectDate.js	21 Dec 2006 20:19:03 -0000	1.3
  @@ -6,12 +6,7 @@
   var datePickerDivID = "datepicker";
   var iFrameDivID = "datepickeriframe";
   
  -var dayArrayShort = new Array('Su', 'Mo', 'Tu', 'We', 'Th', 'Fr', 'Sa');
  -var dayArrayMed = new Array('Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat');
  -var dayArrayLong = new Array('Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday');
  -var monthArrayShort = new Array('Jan', 'Feb', 'Mar', 'Apr', 'May', 'Jun', 'Jul', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec');
  -var monthArrayMed = new Array('Jan', 'Feb', 'Mar', 'Apr', 'May', 'June', 'July', 'Aug', 'Sept', 'Oct', 'Nov', 'Dec');
  -var monthArrayLong = new Array('January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December');
  +// text label variables generate by selectDate component
    
   // these variables define the date formatting we're expecting and outputting.
   // If you want to use a different format by default, change the defaultDateSeparator
  @@ -129,7 +124,9 @@
     var xTR = "</tr>" + crlf;
   
     var TD = "<td class='seam-date-day' onmouseout='this.className=\"seam-date-day\";' onmouseover='this.className=\"seam-date-hover\";' ";    // leave this tag open, because we'll be adding an onclick event
  +  var TD_weekend = "<td class='seam-date-day weekend' onmouseout='this.className=\"seam-date-day weekend\";' onmouseover='this.className=\"seam-date-hover\";' ";    // leave this tag open, because we'll be adding an onclick event
     var TD_selected = "<td class='seam-date-selected' onmouseout='this.className=\"seam-date-selected\";' onmouseover='this.className=\"seam-date-hover\";' ";    // leave this tag open, because we'll be adding an onclick event
  +  var TD_selected_weekend = "<td class='seam-date-selected weekend' onmouseout='this.className=\"seam-date-selected weekend\";' onmouseover='this.className=\"seam-date-hover\";' ";    // leave this tag open, because we'll be adding an onclick event
     var TD_blank = "<td";
     var TD_title = "<td colspan='5'>";
     var TD_buttons = "<td>";
  @@ -151,40 +148,47 @@
    
     // this is the row that indicates which day of the week we're on
     html += TR_days;
  -  for(i = 0; i < dayArrayShort.length; i++)
  -    html += TD_days + dayArrayShort[i] + xTD;
  +  for(i = 0; i < 7; i++) {
  +    html += TD_days + getDayName(i) + xTD;
  +  }
     html += xTR;
    
     // now we'll start populating the table with days of the month
     html += TR;
    
     // first, the leading blanks
  -  for (i = 0; i < thisDay.getDay(); i++)
  +  for (i = 0; i < getDay(thisDay.getDay()); i++) {
       html += TD_blank + "> " + xTD;
  +  }
    
     // now, the days of the month
     do {
       dayNum = thisDay.getDate();
  +    var weekend = isWeekend(thisDay.getDay());
  +
       TD_onclick = " onclick=\"updateDateField('" + dateFieldName + "', '" + getDateString(thisDay) + "');\">";
       
  -    if (dayNum == day)
  -      html += TD_selected + TD_onclick + dayNum + xTD;
  -    else
  -      html += TD + TD_onclick + dayNum + xTD;
  +    if (dayNum == day) {
  +      html += (weekend ? TD_selected_weekend : TD_selected) + TD_onclick + dayNum + xTD;
  +    } else {
  +      html += (weekend ? TD_weekend : TD) + TD_onclick + dayNum + xTD;
  +    }    
       
       // if this is a Saturday, start a new row
  -    if (thisDay.getDay() == 6)
  +    if (getDay(thisDay.getDay()) == 6) {
         html += xTR + TR;
  +    }
       
       // increment the day
       thisDay.setDate(thisDay.getDate() + 1);
     } while (thisDay.getDate() > 1)
    
     // fill in any trailing blanks
  -  if (thisDay.getDay() > 0) {
  -    for (i = 6; i > thisDay.getDay(); i--)
  +  if (getDay(thisDay.getDay()) > 0) {
  +    for (i = 7; i > getDay(thisDay.getDay()); i--) {
         html += TD_blank + "> " + xTD;
     }
  +  }
     html += xTR;
    
     // add a button to allow the user to easily return to today, or close the calendar
  @@ -204,6 +208,22 @@
   }
   
   
  +function getDayName(day) {
  +    return dayArrayShort[(day + firstDayInWeek) % 7];
  +}
  +
  +function getDay(day) {
  +     var convertedDay = day - firstDayInWeek;
  +     if (convertedDay < 0) {
  +         convertedDay += 7;
  +     }
  +     return convertedDay;
  +}
  +
  +function isWeekend(day) {
  +    return (day == 0) || (day == 6);
  +}
  +
   /**
   Convenience function for writing the code for the buttons that bring us back or forward
   a month.
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 15:52:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 15:52:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r59202 -
	trunk/system/src/main/org/jboss/system/server/profileservice/repository
Message-ID: <E1GxUuL-0006To-Cv@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-21 15:52:50 -0500 (Thu, 21 Dec 2006)
New Revision: 59202

Modified:
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/FileProfleRepository.java
   trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java
Log:
Save current work


Property changes on: trunk/system/src/main/org/jboss/system/server/profileservice/repository/FileProfleRepository.java
___________________________________________________________________
Name: svn:keywords
   + Id, Revision

Modified: trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java
===================================================================
--- trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java	2006-12-21 19:03:46 UTC (rev 59201)
+++ trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java	2006-12-21 20:52:50 UTC (rev 59202)
@@ -22,21 +22,29 @@
 package org.jboss.system.server.profileservice.repository;
 
 import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
 import java.io.FileOutputStream;
 import java.io.IOException;
-import java.io.InputStream;
+import java.io.ObjectInputStream;
 import java.io.ObjectOutputStream;
 import java.net.URI;
 import java.util.Collection;
+import java.util.LinkedHashMap;
+import java.util.List;
 import java.util.Map;
 import java.util.zip.ZipInputStream;
 
+import org.jboss.deployers.plugins.structure.AbstractDeploymentContext;
 import org.jboss.deployers.spi.attachments.Attachments;
+import org.jboss.deployers.spi.deployment.MainDeployer;
 import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.logging.Logger;
 import org.jboss.profileservice.spi.DeploymentRepository;
 import org.jboss.profileservice.spi.NoSuchProfileException;
 import org.jboss.profileservice.spi.ProfileKey;
 import org.jboss.util.file.Files;
+import org.jboss.virtual.VFS;
 import org.jboss.virtual.VirtualFile;
 
 /**
@@ -51,18 +59,28 @@
  * + server/{name}/admin - admin edits to deployments
  * 
  * @author Scott.Stark at jboss.org
- * @version $Revision:$
+ * @version $Revision$
  */
 public class SerializableDeploymentRepository implements DeploymentRepository
 {
+   private static final Logger log = Logger.getLogger(SerializableDeploymentRepository.class);
+
+   private MainDeployer mainDeployer;
+   /** */
    private File root;
    private File confDir;
    private File libDir;
    private File deployersDir;
    private File deployDir;
-   private File metaDataRoot;
+   private File deploymentCtxDir;
    private File adminEditsRoot;
    private ProfileKey key;
+   private LinkedHashMap<String,DeploymentContext> bootstraps = new LinkedHashMap<String,DeploymentContext>();
+   private LinkedHashMap<String,DeploymentContext> deployments = new LinkedHashMap<String,DeploymentContext>();
+   private LinkedHashMap<String,DeploymentContext> deployers = new LinkedHashMap<String,DeploymentContext>();
+   private LinkedHashMap<String,DeploymentContext> bootstrapCtxs = new LinkedHashMap<String,DeploymentContext>();
+   private LinkedHashMap<String,DeploymentContext> deploymentCtxs = new LinkedHashMap<String,DeploymentContext>();
+   private LinkedHashMap<String,DeploymentContext> deployerCtxs = new LinkedHashMap<String,DeploymentContext>();
 
    public SerializableDeploymentRepository(File root, ProfileKey key)
    {
@@ -74,17 +92,19 @@
    {
       File profileRoot = new File(root, "server/"+key.getName());
       if( profileRoot.exists() == true )
-         throw new IOException("Profile root alread exists: "+profileRoot);
+         throw new IOException("Profile root already exists: "+profileRoot);
       if( profileRoot.mkdirs() == false )
          throw new IOException("Failed to create profile root: "+profileRoot);
       // server/{name}/conf
       confDir = new File(profileRoot, "conf");
       if( confDir.mkdirs() == false )
          throw new IOException("Failed to create profile conf dir: "+confDir);
+
       // server/{name}/deployers
       deployersDir = new File(profileRoot, "deployers");
       if( deployersDir.mkdirs() == false )
          throw new IOException("Failed to create profile deployers dir: "+deployersDir);
+
       // server/{name}/deploy
       deployDir = new File(profileRoot, "deploy");
       if( deployDir.mkdirs() == false )
@@ -93,24 +113,63 @@
       libDir = new File(profileRoot, "lib");
       if( libDir.mkdirs() == false )
          throw new IOException("Failed to create profile lib dir: "+libDir);
-      metaDataRoot = new File(profileRoot, "metaData");
-      if( metaDataRoot.mkdirs() == false )
-         throw new IOException("Failed to create profile metaData dir: "+metaDataRoot);
-      
-      adminEditsRoot = new File(profileRoot, "adminEdits");
+      deploymentCtxDir = new File(profileRoot, "profile/ctxs");
+      if( deploymentCtxDir.mkdirs() == false )
+         throw new IOException("Failed to create profile metaData dir: "+deploymentCtxDir);
+
+      adminEditsRoot = new File(profileRoot, "profile/edits");
       if( adminEditsRoot.mkdirs() == false )
          throw new IOException("Failed to create profile adminEdits dir: "+adminEditsRoot);
    }
 
+   /**
+    * Load the profile deployments
+    * 
+    * @throws IOException
+    * @throws NoSuchProfileException
+    */
    void load() throws IOException, NoSuchProfileException
    {
       File profileRoot = new File(root, "server/"+key.getName());
-      if( profileRoot.exists() == true )
-         throw new NoSuchProfileException("Profile root alread exists: "+profileRoot);
-      //
-      
+      if( profileRoot.exists() == false )
+         throw new NoSuchProfileException("Profile root does not exists: "+profileRoot);
+      // server/{name}/conf
+      confDir = new File(profileRoot, "conf");
+      if( confDir.exists() == false )
+         throw new FileNotFoundException("Profile contains no conf dir: "+confDir);
+
+      // server/{name}/deployers
+      deployersDir = new File(profileRoot, "deployers");
+      if( deployersDir.exists() == false )
+         throw new FileNotFoundException("Profile contains no deployers dir: "+deployersDir);
+
+      // server/{name}/deploy
+      deployDir = new File(profileRoot, "deploy");
+      if( deployDir.exists() == false )
+         throw new FileNotFoundException("Profile contains no deploy dir: "+deployDir);
+
+      deploymentCtxDir = new File(profileRoot, "profile/ctxs");
+      if( deploymentCtxDir.exists() == false )
+      {
+         if( deploymentCtxDir.mkdirs() == false )
+            throw new IOException("Failed to create profile metaData dir: "+deploymentCtxDir);
+      }
+
+      adminEditsRoot = new File(profileRoot, "profile/edits");
+
+      VFS confVFS = VFS.getVFS(confDir.toURI());
+      loadBootstraps(confVFS.getRoot());
+      VFS deployersVFS = VFS.getVFS(deployersDir.toURI());
+      loadDeployers(deployersVFS.getRoot());
+      VFS deployVFS = VFS.getVFS(deployDir.toURI());
+      loadDeployers(deployVFS.getRoot());
    }
 
+   /**
+    * 
+    * @throws IOException
+    * @throws NoSuchProfileException
+    */
    void remove() throws IOException, NoSuchProfileException
    {
       File profileRoot = new File(root, "server/"+key.getName());
@@ -150,13 +209,10 @@
       oos.writeObject(map);
       oos.close();
       fos.close();
-
    }
 
    public void addDeployer(String vfsPath, DeploymentContext ctx) throws IOException
    {
-      // TODO Auto-generated method stub
-      
    }
 
    public void addDeployment(String vfsPath, DeploymentContext ctx) throws IOException
@@ -269,20 +325,20 @@
       if( transientAttachments.getAttachments().size() > 0 )
       {
          Map<String, Object> map = transientAttachments.getAttachments();
-         File attachments = new File(metaDataRoot, vfsPath+".transientAttachments");
+         File attachments = new File(deploymentCtxDir, vfsPath+".transientAttachments");
          FileOutputStream fos = new FileOutputStream(attachments);
          ObjectOutputStream oos = new ObjectOutputStream(fos);
          oos.writeObject(map);
          oos.close();
          fos.close();
       }
-   
+
       // Write out the base transient managed objects
       Attachments transientManagedObjects = ctx.getTransientManagedObjects();
       if( transientManagedObjects.getAttachments().size() > 0 )
       {
          Map<String, Object> map = transientManagedObjects.getAttachments();
-         File attachments = new File(metaDataRoot, vfsPath+".transientManagedObjects");
+         File attachments = new File(deploymentCtxDir, vfsPath+".transientManagedObjects");
          FileOutputStream fos = new FileOutputStream(attachments);
          ObjectOutputStream oos = new ObjectOutputStream(fos);
          oos.writeObject(map);
@@ -291,4 +347,106 @@
       }
    }
 
+   private void loadAttachments(String vfsPath, DeploymentContext ctx)
+      throws ClassNotFoundException, IOException
+   {
+      File transientAttachments = new File(deploymentCtxDir, vfsPath+".transientAttachments");
+      if( transientAttachments.exists() )
+      {
+         FileInputStream fis = new FileInputStream(transientAttachments);
+         ObjectInputStream ois = new ObjectInputStream(fis);
+         Map<String, Object> map = (Map<String, Object>) ois.readObject();
+         ois.close();
+         fis.close();
+         for(String key : map.keySet())
+         {
+            Object value = map.get(key);
+            ctx.getTransientAttachments().addAttachment(key, value);
+         }
+      }
+
+      File transientManagedObjects = new File(deploymentCtxDir, vfsPath+".transientManagedObjects");
+      if( transientManagedObjects.exists() )
+      {
+         FileInputStream fis = new FileInputStream(transientManagedObjects);
+         ObjectInputStream ois = new ObjectInputStream(fis);
+         Map<String, Object> map = (Map<String, Object>) ois.readObject();
+         ois.close();
+         fis.close();
+         for(String key : map.keySet())
+         {
+            Object value = map.get(key);
+            ctx.getTransientManagedObjects().addAttachment(key, value);
+         }         
+      }
+   }
+
+   /**
+    * Load the know bootstrap descriptors under confDir, bootstrap-beans.xml
+    * and jboss-service.xml. The jboss-service.xml is optional.
+    * 
+    * @param confDir
+    * @throws IOException
+    */
+   private void loadBootstraps(VirtualFile confDir)
+      throws IOException
+   {
+      VirtualFile bootstrapBeans = confDir.findChild("bootstrap-beans.xml");
+      DeploymentContext bootstrapBeansCtx = loadDeploymentData(bootstrapBeans);
+      bootstrapCtxs.put(bootstrapBeans.getPathName(), bootstrapBeansCtx);
+      try
+      {
+         VirtualFile jbossService = confDir.findChild("jboss-service.xml");
+         DeploymentContext jbossServiceCtx = loadDeploymentData(bootstrapBeans);
+         bootstrapCtxs.put(jbossService.getPathName(), jbossServiceCtx);
+      }
+      catch(IOException e)
+      {
+         log.debug("No jboss-service.xml bootstrap found", e);
+      }
+   }
+
+   /**
+    * Load all the deployments under the deployersDir.
+    * 
+    * @param deployersDir
+    * @throws IOException
+    */
+   private void loadDeployers(VirtualFile deployersDir)
+      throws IOException
+   {
+      List<VirtualFile> children = deployersDir.getChildren();
+      for(VirtualFile vf : children)
+      {
+         DeploymentContext vfCtx = loadDeploymentData(vf);
+         bootstrapCtxs.put(vf.getPathName(), vfCtx);         
+      }
+   }
+
+   /**
+    * Load all the deployments under the deployersDir.
+    * 
+    * @param deployDir
+    * @throws IOException
+    */
+   private void loadDeployments(VirtualFile deployDir)
+      throws IOException
+   {
+      List<VirtualFile> children = deployDir.getChildren();
+      for(VirtualFile vf : children)
+      {
+         DeploymentContext vfCtx = loadDeploymentData(vf);
+         bootstrapCtxs.put(vf.getPathName(), vfCtx);         
+      }
+   }
+
+   private DeploymentContext loadDeploymentData(VirtualFile file)
+   {
+      // Check for a persisted context
+      // Load the base deployment
+      DeploymentContext deployment = new AbstractDeploymentContext(file);
+      // Load any attachments
+      return deployment;
+   }
+
 }


Property changes on: trunk/system/src/main/org/jboss/system/server/profileservice/repository/SerializableDeploymentRepository.java
___________________________________________________________________
Name: svn:keywords
   + Id, Revision



From smcgowan at redhat.com  Thu Dec 21 16:19:16 2006
From: smcgowan at redhat.com (Shelly McGowan)
Date: Thu, 21 Dec 2006 16:19:16 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.4.1.CR1 - New
	directory ...
Message-ID: <E1GxVJs-00075h-P8@committer01.frg.pub.inap.atl.jboss.com>

  User: smcgowan
  Date: 06/12/21 16:19:16

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/cache/1.4.1.CR1 added to the repository


From brian.stansberry at jboss.com  Thu Dec 21 16:19:42 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 16:19:42 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1GxVKI-00075y-GK@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 16:19:42

  Modified:    tests/functional/org/jboss/cache/eviction  Tag:
                        Branch_JBossCache_1_4_0
                        StateTransferIntegrationTest.java
  Log:
  [JBCACHE-913] Add a test that eviction actually occurs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +36 -2     JBossCache/tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- StateTransferIntegrationTest.java	21 Dec 2006 04:40:07 -0000	1.1.2.1
  +++ StateTransferIntegrationTest.java	21 Dec 2006 21:19:42 -0000	1.1.2.2
  @@ -22,9 +22,12 @@
   
   package org.jboss.cache.eviction;
   
  +import java.util.Set;
  +
   import org.jboss.cache.Fqn;
   import org.jboss.cache.PropertyConfigurator;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.misc.TestingUtil;
   
   import junit.framework.TestCase;
   
  @@ -56,7 +59,38 @@
         
         RegionManager erm = cache2.getEvictionRegionManager();
         Region region = erm.getRegion(Fqn.ROOT);
  -      // We expect events for ROOT , /a, /a/b and /a/b/c
  -      assertEquals("Saw the expected number of node events", 4, region.nodeEventQueueSize());
  +      // We expect events for /a, /a/b and /a/b/c
  +      assertEquals("Saw the expected number of node events", 3, region.nodeEventQueueSize());
  +   }
  +   
  +   /**
  +    * Further test for JBCACHE-913
  +    * 
  +    * @throws Exception
  +    */
  +   public void testEvictionAfterStateTransfer() throws Exception
  +   {
  +      TreeCache cache1 = new TreeCache();
  +      PropertyConfigurator config = new PropertyConfigurator();
  +      config.configure(cache1, "META-INF/replSync-eviction-service.xml");      
  +      cache1.startService();
  +      
  +      for (int i = 0; i < 4; i++)
  +         cache1.put("/org/jboss/test/data/" + i, "key", "value");
  +      
  +      TreeCache cache2 = new TreeCache();
  +      config.configure(cache2, "META-INF/replSync-eviction-service.xml");
  +      cache2.startService();
  +      
  +      Set children = cache2.getChildrenNames("/org/jboss/test/data");
  +      assertEquals("All children transferred", 4, children.size());
  +      
  +      // Sleep 10.1 secs to let the eviction thread run at least twice,
  +      // which will evict all 4 nodes due to their ttl of 4 secs
  +      TestingUtil.sleepThread(10500);
  +      
  +      children = cache2.getChildrenNames("/org/jboss/test/data");
  +      if (children != null)
  +         assertEquals("All children evicted", 0, children.size());
      }
   }
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 16:21:05 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 16:21:05 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer  ...
Message-ID: <E1GxVLd-0007A2-Fr@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 16:21:05

  Modified:    src/org/jboss/cache/statetransfer  Tag:
                        Branch_JBossCache_1_4_0
                        StateTransferIntegrator_140.java
  Log:
  [JBCACHE-913] Do the TreeCacheListener and eviction region notifications as part of the basic state transfer node creation
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.6.2.1   +21 -1     JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_140.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrator_140.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_140.java,v
  retrieving revision 1.6
  retrieving revision 1.6.2.1
  diff -u -b -r1.6 -r1.6.2.1
  --- StateTransferIntegrator_140.java	27 Apr 2006 07:18:37 -0000	1.6
  +++ StateTransferIntegrator_140.java	21 Dec 2006 21:21:05 -0000	1.6.2.1
  @@ -23,6 +23,9 @@
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.aop.InternalDelegate;
   import org.jboss.cache.aop.PojoCache;
  +import org.jboss.cache.eviction.EvictedEventNode;
  +import org.jboss.cache.eviction.Region;
  +import org.jboss.cache.eviction.RegionManager;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.loader.ExtendedCacheLoader;
  @@ -255,17 +258,34 @@
   
               name = fqn.get(size - 1);
               
  +            Map attrs = nd.getAttributes();
  +            
               // We handle this NodeData.  Create a DataNode and
               // integrate its data            
               DataNode target = factory.createDataNode(nodeType, 
                                                        name, 
                                                        fqn, 
                                                        parent, 
  -                                                     nd.getAttributes(), 
  +                                                     attrs, 
                                                        true,
                                                        cache);
               parent.addChild(name, target);
               
  +            // Send out the TreeCacheListener notification
  +            cache.notifyNodeCreated(fqn);
  +            
  +            // Make sure any eviction policy is aware of this node
  +            RegionManager rm = cache.getEvictionRegionManager();
  +            if (rm != null)
  +            {               
  +               Region region = rm.getRegion(fqn);
  +               if (region != null)
  +               {
  +                  region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT, 
  +                                                           attrs == null ? 0 : attrs.size()));
  +               }
  +            }
  +            
               // Recursively call, which will walk down the tree
               // and return the next NodeData that's a child of our parent
               nd = integrateStateTransferChildren(target, offset, in);
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 16:21:05 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 16:21:05 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxVLd-0007AD-W7@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 16:21:05

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  [JBCACHE-913] Do the TreeCacheListener and eviction region notifications as part of the basic state transfer node creation
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.39 +5 -13     JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.38
  retrieving revision 1.195.2.39
  diff -u -b -r1.195.2.38 -r1.195.2.39
  --- TreeCache.java	21 Dec 2006 04:40:07 -0000	1.195.2.38
  +++ TreeCache.java	21 Dec 2006 21:21:05 -0000	1.195.2.39
  @@ -100,7 +100,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.38 2006/12/21 04:40:07 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.39 2006/12/21 21:21:05 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -2753,6 +2753,7 @@
            try
            {
               integrator.integrateTransientState(targetRoot, cl);
  +            // JBCACHE-913 -- the integrator now makes this call
               notifyAllNodesCreated(targetRoot);
            }
            catch (Throwable t)
  @@ -6072,6 +6073,8 @@
      /**
       * Generates NodeAdded notifications for all nodes of the tree. This is
       * called whenever the tree is initially retrieved (state transfer)
  +    * 
  +    * @deprecated No longer called
       */
      protected void notifyAllNodesCreated(DataNode curr)
      {
  @@ -6079,18 +6082,7 @@
         Map children;
   
         if (curr == null) return;
  -      Fqn fqn = curr.getFqn();
  -      notifyNodeCreated(fqn);
  -      
  -      // JBCACHE-913
  -      if (evictionRegionManager_ != null)
  -      {
  -         org.jboss.cache.eviction.Region region = evictionRegionManager_.getRegion(fqn);
  -         if (region != null)
  -         {
  -            region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT));
  -         }
  -      }
  +      notifyNodeCreated(curr.getFqn());
         
         if ((children = curr.getChildren()) != null)
         {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 16:23:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 16:23:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r59203 - in trunk:
	ejb3/src/main/org/jboss/ejb3 ejb3/src/main/org/jboss/ejb3/client
	ejb3/src/main/org/jboss/ejb3/clientmodule
	ejb3/src/main/org/jboss/ejb3/mdb ejb3/src/main/org/jboss/ejb3/naming
	ejb3/src/main/org/jboss/ejb3/service
	ejb3/src/main/org/jboss/ejb3/stateful
	ejb3/src/main/org/jboss/injection
	ejb3/src/test/org/jboss/ejb3/test/enventry
	ejb3/src/test/org/jboss/ejb3/test/enventry/unit
	server/src/main/org/jboss/ejb server/src/main/org/jboss/naming
	testsuite/src/main/org/jboss/test/naming/ejb
	tomcat/src/main/org/jboss/web/tomcat/tc6
Message-ID: <E1GxVNx-0007Ab-Td@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-21 16:23:17 -0500 (Thu, 21 Dec 2006)
New Revision: 59203

Added:
   trunk/ejb3/src/main/org/jboss/ejb3/DefaultEjbEncFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/EjbEncFactory.java
   trunk/server/src/main/org/jboss/naming/ThreadLocalStack.java
Removed:
   trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java
   trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java
   trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java
   trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java
Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
   trunk/ejb3/src/main/org/jboss/ejb3/Container.java
   trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java
   trunk/ejb3/src/main/org/jboss/ejb3/EJBContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/ENCPropagationInterceptor.java
   trunk/ejb3/src/main/org/jboss/ejb3/SessionContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/client/ClientContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/clientmodule/ClientENCInjectionContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/mdb/ConsumerContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/mdb/MessagingContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/service/ServiceContainer.java
   trunk/ejb3/src/main/org/jboss/ejb3/stateful/StatefulContainer.java
   trunk/ejb3/src/main/org/jboss/injection/InjectionContainer.java
   trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java
   trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java
   trunk/server/src/main/org/jboss/ejb/EjbUtil.java
   trunk/server/src/main/org/jboss/naming/ENCFactory.java
   trunk/server/src/main/org/jboss/naming/JNDIView.java
   trunk/testsuite/src/main/org/jboss/test/naming/ejb/TestENCBean.java
   trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/TomcatInjectionContainer.java
Log:
Revamp java:comp namespace and add EJB3 to this namespace.
Fixed a minor bug in EJB3 env-entry processing
Fixed a minor bug in EJB 2.1 container's messageLink processing

Modified: trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/BaseSessionContext.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -141,15 +141,15 @@
       String newName;
       if (name.startsWith("/"))
       {
-         newName = Container.ENC_CTX_NAME + "/env" + name;
+         newName = "env" + name;
       }
       else
       {
-         newName = Container.ENC_CTX_NAME + "/env/" + name;
+         newName = "env/" + name;
       }
       try
       {
-         return getContainer().getInitialContext().lookup(newName);
+         return getContainer().getEnc().lookup(newName);
       }
       catch (NamingException ignored)
       {

Modified: trunk/ejb3/src/main/org/jboss/ejb3/Container.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/Container.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/Container.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -37,7 +37,7 @@
  */
 public interface Container
 {
-   String ENC_CTX_NAME = "java:comp.ejb3";
+   String ENC_CTX_NAME = "java:comp";
 
    Class getBeanClass();
 

Added: trunk/ejb3/src/main/org/jboss/ejb3/DefaultEjbEncFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/DefaultEjbEncFactory.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/DefaultEjbEncFactory.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -0,0 +1,73 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.ejb3;
+
+import org.jboss.ejb.EjbUtil;
+import org.jboss.naming.ENCFactory;
+
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.naming.NamingException;
+
+/**
+ * comment
+ *
+ * @author <a href="bill at jboss.com">Bill Burke</a>
+ * @version $Revision: 1.1 $
+ */
+public class DefaultEjbEncFactory implements EjbEncFactory
+{
+
+   public Context getEnc(EJBContainer container)
+   {
+      pushEnc(container);
+      InitialContext ctx = container.getInitialContext();
+      try
+      {
+         return (Context)ctx.lookup("java:comp");
+      }
+      catch (NamingException e)
+      {
+         throw new RuntimeException(e);
+      }
+      finally
+      {
+         popEnc(container);   
+      }
+   }
+
+   public void pushEnc(EJBContainer container)
+   {
+      ENCFactory.pushContextId(container.getObjectName());
+   }
+
+   public void popEnc(EJBContainer container)
+   {
+      ENCFactory.popContextId();
+   }
+
+
+   public void cleanupEnc(EJBContainer container)
+   {
+      ENCFactory.getEncById().remove(container.getObjectName());
+   }
+}

Modified: trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/EJB3Deployer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -38,15 +38,12 @@
 import javax.naming.Context;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
-import javax.naming.RefAddr;
-import javax.naming.Reference;
-import javax.naming.StringRefAddr;
+import javax.naming.LinkRef;
+
 import org.jboss.deployment.DeploymentException;
 import org.jboss.deployment.DeploymentInfo;
 import org.jboss.deployment.SubDeployer;
 import org.jboss.deployment.SubDeployerSupport;
-import org.jboss.ejb3.naming.MultiplexerContext;
-import org.jboss.ejb3.naming.SimpleMultiplexer;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.MetaData;
 import org.jboss.metadata.XmlFileLoader;
@@ -317,25 +314,11 @@
       initializeJavaComp(iniCtx);
    }
 
-   private static void hackJNDI(Context ctx) throws NamingException
-   {
-      log.info("Starting java:comp hack");
-      // rename to something SimpleMultiPlexer knows.
-      ctx.rename("comp", "comp.original");
-      RefAddr refAddr = new StringRefAddr("nns", "ENC-MULTIPLEXER");
-      Reference ref = new Reference("javax.naming.Context", refAddr, SimpleMultiplexer.class.getName(), null);
-      ctx.bind("comp", ref);
-   }
-   
    public static void initializeJavaComp(InitialContext iniCtx)
            throws NamingException
    {
-      RefAddr refAddr = new StringRefAddr("nns", "ENC-EJB3");
-      Reference envRef = new Reference("javax.naming.Context", refAddr, ThreadLocalENCFactory.class.getName(), null);
       Context ctx = (Context) iniCtx.lookup("java:");
-      ctx.rebind("comp.ejb3", envRef);
-      
-      hackJNDI(ctx);
+      ctx.rebind("comp.ejb3", new LinkRef("java:comp"));
    }
 
    /**

Modified: trunk/ejb3/src/main/org/jboss/ejb3/EJBContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/EJBContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/EJBContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -23,12 +23,10 @@
 
 import org.jboss.annotation.ejb.PoolClass;
 import org.jboss.aop.AspectManager;
-import org.jboss.aop.ClassAdvisor;
 import org.jboss.aop.ClassContainer;
 import org.jboss.aop.advice.Interceptor;
 import org.jboss.aop.annotation.AnnotationElement;
 import org.jboss.aop.joinpoint.ConstructorInvocation;
-import org.jboss.aop.util.MethodHashing;
 import org.jboss.ejb3.entity.PersistenceUnitDeployment;
 import org.jboss.ejb3.interceptor.InterceptorInfo;
 import org.jboss.ejb3.interceptor.InterceptorInfoRepository;
@@ -52,9 +50,9 @@
 import org.jboss.injection.ResourceHandler;
 import org.jboss.injection.WebServiceRefHandler;
 import org.jboss.logging.Logger;
-import org.jboss.metamodel.descriptor.PersistenceContextRef;
 import org.jboss.metamodel.descriptor.EnvironmentRefGroup;
 import org.jboss.naming.Util;
+import org.jboss.naming.ENCFactory;
 
 import javax.annotation.PostConstruct;
 import javax.annotation.PreDestroy;
@@ -65,7 +63,6 @@
 import javax.management.ObjectName;
 import javax.naming.Context;
 import javax.naming.InitialContext;
-import javax.naming.LinkRef;
 import javax.naming.NameNotFoundException;
 import javax.naming.NamingException;
 
@@ -97,6 +94,8 @@
 
    private static final Logger log = Logger.getLogger(EJBContainer.class);
 
+   protected EjbEncFactory encFactory = new DefaultEjbEncFactory();
+
    protected Pool pool;
 
    protected String ejbName;
@@ -113,7 +112,6 @@
    protected List<Injector> injectors = new ArrayList<Injector>();
 
    protected Context enc;
-   protected Context encEnv;
 
    protected Class beanContextClass;
 
@@ -185,11 +183,9 @@
          throw new RuntimeException("failed to create object name for: " + on, e);
       }
       initialContextProperties = ctxProperties;
-      Context ctx = getInitialContext();
       try
       {
-         enc = ThreadLocalENCFactory.create(ctx);
-         encEnv = Util.createSubcontext(enc, "env");
+         Util.createSubcontext(getEnc(), "env");
       }
       catch (Exception e)
       {
@@ -198,6 +194,39 @@
       this.interceptorRepository = interceptorRepository;
       this.interceptorRepository.addBeanClass(clazz.getName());
    }
+
+
+   public EjbEncFactory getEncFactory()
+   {
+      return encFactory;
+   }
+
+   public void setEncFactory(EjbEncFactory encFactory)
+   {
+      this.encFactory = encFactory;
+   }
+
+   /**
+    * Makes sure that EJB's ENC is available
+    * Delegates to whatever implementation is used to push the ENC of the EJB
+    * onto the stack
+    *
+    */
+   public void pushEnc()
+   {
+      encFactory.pushEnc(this);
+   }
+
+
+   /**
+    * Pops EJB's ENC from the stack.  Delegates to whatever implementation
+    * is used to pop the EJB's ENC from the stock
+    *
+    */
+   public void popEnc()
+   {
+      encFactory.popEnc(this);
+   }
    
    public EnvironmentRefGroup getEnvironmentRefGroup()
    {
@@ -370,14 +399,13 @@
 
    public Context getEnc()
    {
+      if (enc == null)
+      {
+         enc = encFactory.getEnc(this);
+      }
       return enc;
    }
 
-   public Context getEncEnv()
-   {
-      return enc;
-   }
-
    public Hashtable getInitialContextProperties()
    {
       return initialContextProperties;
@@ -485,6 +513,7 @@
 
    public void stop() throws Exception
    {
+      encFactory.cleanupEnc(this);
    }
 
    public void destroy() throws Exception
@@ -541,24 +570,24 @@
 
    protected void resolveInjectors() throws Exception
    {
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          Thread.currentThread().setContextClassLoader(classloader);
          try
          {
-            Util.rebind(enc, "UserTransaction", new UserTransactionImpl());
+            Util.rebind(getEnc(), "UserTransaction", new UserTransactionImpl());
          }
          catch (NamingException e)
          {
-            NamingException namingException = new NamingException("Could not bind user transaction for ejb name " + ejbName + " into JNDI under jndiName: " + enc.getNameInNamespace() + "/" + "UserTransaction");
+            NamingException namingException = new NamingException("Could not bind user transaction for ejb name " + ejbName + " into JNDI under jndiName: " + getEnc().getNameInNamespace() + "/" + "UserTransaction");
             namingException.setRootCause(e);
             throw namingException;
          }
       }
       finally
       {
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 

Modified: trunk/ejb3/src/main/org/jboss/ejb3/ENCPropagationInterceptor.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/ENCPropagationInterceptor.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/ENCPropagationInterceptor.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -39,16 +39,15 @@
 
    public Object invoke(Invocation invocation) throws Throwable
    {
+      EJBContainer container = (EJBContainer) invocation.getAdvisor();
       try
       {
-         Container container = (Container) invocation.getAdvisor();
-         ThreadLocalENCFactory.push(container.getEnc());
-
+         container.pushEnc();
          return invocation.invokeNext();
       }
       finally
       {
-         ThreadLocalENCFactory.pop();
+         container.popEnc();
       }
    }
 }

Added: trunk/ejb3/src/main/org/jboss/ejb3/EjbEncFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/EjbEncFactory.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/EjbEncFactory.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -0,0 +1,55 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.ejb3;
+
+import javax.naming.Context;
+
+/**
+ * ENC Abstraction for EJB Container
+ *
+ * @author <a href="bill at jboss.com">Bill Burke</a>
+ * @version $Revision: 1.1 $
+ */
+public interface EjbEncFactory
+{
+   Context getEnc(EJBContainer container);
+
+   /**
+    * Push the EJB's ENC onto the current thread
+    *
+    * @param container
+    */
+   void pushEnc(EJBContainer container);
+
+   /**
+    * pop the EJB's ENC from the current thread
+    *
+    * @param container
+    */
+   void popEnc(EJBContainer container);
+
+   /**
+    * 
+    * @param container
+    */
+   void cleanupEnc(EJBContainer container);
+}

Modified: trunk/ejb3/src/main/org/jboss/ejb3/SessionContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/SessionContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/SessionContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -264,7 +264,7 @@
    public Object invoke(ProxyFactory factory, Object id, Method method, Object args[], FutureHolder provider) throws Throwable
    {
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          long hash = MethodHashing.calculateHash(method);
@@ -310,7 +310,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
    

Deleted: trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/ThreadLocalENCFactory.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -1,96 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.ejb3;
-
-import java.util.Hashtable;
-import java.util.LinkedList;
-import javax.naming.Context;
-import javax.naming.Name;
-import javax.naming.spi.ObjectFactory;
-import org.jnp.interfaces.NamingContext;
-import org.jnp.server.NamingServer;
-
-/**
- * Implementation of "java:comp" namespace factory. The context is associated
- * with the thread class loader.
- *
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision$
- */
-public class ThreadLocalENCFactory
-        implements ObjectFactory
-{
-   private static ThreadLocal<Context> enc = new ThreadLocal<Context>();
-   private static ThreadLocal<LinkedList<Context>> stack = new ThreadLocal<LinkedList<Context>>();
-
-   public static Context create(Context parent) throws Exception
-   {
-      NamingServer srv = new NamingServer();
-      return new NamingContext(parent.getEnvironment(), null, srv);
-   }
-
-   public static void push(Context ctx)
-   {
-      if (enc.get() == null)
-      {
-         enc.set(ctx);
-         return;
-      }
-      LinkedList<Context> currentStack = stack.get();
-      if (currentStack == null)
-      {
-         currentStack = new LinkedList<Context>();
-         stack.set(currentStack);
-      }
-      currentStack.addLast(enc.get());
-      enc.set(ctx);
-   }
-
-   public static void pop()
-   {
-      LinkedList<Context> currentStack = stack.get();
-      if (currentStack == null)
-      {
-         enc.set(null);
-         return;
-      }
-      if (currentStack.size() == 0)
-      {
-         enc.set(null);
-         return;
-      }
-      Context previous = currentStack.removeLast();
-      enc.set(previous);
-   }
-   // Constructors --------------------------------------------------
-
-   // Public --------------------------------------------------------
-
-   // ObjectFactory implementation ----------------------------------
-   public Object getObjectInstance(Object obj, Name name, Context nameCtx,
-                                   Hashtable environment)
-           throws Exception
-   {
-      return enc.get();
-   }
-
-}

Modified: trunk/ejb3/src/main/org/jboss/ejb3/client/ClientContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/client/ClientContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/client/ClientContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -215,14 +215,6 @@
    }
 
    /* (non-Javadoc)
-    * @see org.jboss.injection.InjectionContainer#getEncEnv()
-    */
-   public Context getEncEnv()
-   {
-      return encEnv;
-   }
-
-   /* (non-Javadoc)
     * @see org.jboss.injection.InjectionContainer#getEncInjections()
     */
    public Map<String, Map<AccessibleObject, Injector>> getEncInjections()

Modified: trunk/ejb3/src/main/org/jboss/ejb3/clientmodule/ClientENCInjectionContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/clientmodule/ClientENCInjectionContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/clientmodule/ClientENCInjectionContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -214,11 +214,6 @@
       return enc;
    }
 
-   public Context getEncEnv()
-   {
-      return encEnv;
-   }
-
    public Map<String, Map<AccessibleObject, Injector>> getEncInjections()
    {
       return encInjections;

Modified: trunk/ejb3/src/main/org/jboss/ejb3/mdb/ConsumerContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/mdb/ConsumerContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/mdb/ConsumerContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -21,45 +21,8 @@
 */ 
 package org.jboss.ejb3.mdb;
 
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.ArrayList;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Hashtable;
-import java.util.Map;
-
-import javax.ejb.ActivationConfigProperty;
-import javax.ejb.EJBException;
-import javax.ejb.MessageDriven;
-import javax.ejb.Timer;
-import javax.ejb.TimerService;
-import javax.ejb.TransactionAttribute;
-import javax.ejb.TransactionAttributeType;
-import javax.ejb.TransactionManagement;
-import javax.ejb.TransactionManagementType;
-import javax.jms.Connection;
-import javax.jms.ConnectionConsumer;
-import javax.jms.Destination;
-import javax.jms.ExceptionListener;
-import javax.jms.JMSException;
-import javax.jms.Message;
-import javax.jms.MessageListener;
-import javax.jms.ObjectMessage;
-import javax.jms.Queue;
-import javax.jms.QueueConnection;
-import javax.jms.ServerSessionPool;
-import javax.jms.Topic;
-import javax.jms.TopicConnection;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.naming.Context;
-import javax.naming.NamingException;
-import javax.transaction.Transaction;
-import org.jboss.annotation.ejb.AcknowledgementMode;
 import org.jboss.annotation.ejb.Consumer;
 import org.jboss.annotation.ejb.DefaultActivationSpecs;
-import org.jboss.annotation.ejb.Durability;
 import org.jboss.annotation.ejb.Local;
 import org.jboss.annotation.ejb.MessageProperties;
 import org.jboss.annotation.ejb.MessagePropertiesImpl;
@@ -71,27 +34,23 @@
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.InvocationResponse;
 import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.aop.util.MethodHashing;
 import org.jboss.aop.util.PayloadKey;
-import org.jboss.deployment.DeploymentException;
 import org.jboss.ejb3.Container;
-import org.jboss.ejb3.EJBContainer;
 import org.jboss.ejb3.EJBContainerInvocation;
-import org.jboss.ejb3.Ejb3Module;
-import org.jboss.ejb3.ProxyFactoryHelper;
-import org.jboss.ejb3.ThreadLocalENCFactory;
 import org.jboss.ejb3.Ejb3Deployment;
 import org.jboss.ejb3.interceptor.InterceptorInfoRepository;
-import org.jboss.ejb3.mdb.inflow.JBossMessageEndpointFactory;
-import org.jboss.ejb3.timerservice.TimedObjectInvoker;
-import org.jboss.ejb3.timerservice.TimerServiceFactory;
-import org.jboss.ejb3.tx.TxUtil;
-import org.jboss.jms.ConnectionFactoryHelper;
-import org.jboss.jms.asf.ServerSessionPoolFactory;
-import org.jboss.jms.asf.StdServerSessionPool;
-import org.jboss.jms.jndi.JMSProviderAdapter;
 import org.jboss.logging.Logger;
 
+import javax.ejb.ActivationConfigProperty;
+import javax.jms.Destination;
+import javax.jms.Message;
+import javax.jms.ObjectMessage;
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.Hashtable;
+import java.util.Map;
+
 /**
  * Comment
  *
@@ -133,7 +92,7 @@
    {
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
       EJBContainerInvocation newSi = null;
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          Thread.currentThread().setContextClassLoader(classloader);
@@ -157,7 +116,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
    
@@ -185,7 +144,7 @@
       if (info.getAdvisedMethod().equals(getOnMessage()))
       {
          ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-         ThreadLocalENCFactory.push(enc);
+         pushEnc();
          
          try
          {
@@ -197,7 +156,7 @@
          finally
          {
             Thread.currentThread().setContextClassLoader(oldLoader);
-            ThreadLocalENCFactory.pop();
+            popEnc();
          }
       }
       else

Modified: trunk/ejb3/src/main/org/jboss/ejb3/mdb/MessagingContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/mdb/MessagingContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/mdb/MessagingContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -236,7 +236,7 @@
    public Object localInvoke(MethodInfo info, Object[] args) throws Throwable
    {     
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          Interceptor[] aspects = info.getInterceptors();
@@ -248,7 +248,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 

Deleted: trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/naming/MultiplexerContext.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -1,283 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ejb3.naming;
-
-import java.io.Serializable;
-import java.util.ArrayList;
-import java.util.Collection;
-import java.util.Hashtable;
-
-import javax.naming.Binding;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import javax.naming.Name;
-import javax.naming.NameClassPair;
-import javax.naming.NameParser;
-import javax.naming.NamingEnumeration;
-import javax.naming.NamingException;
-import javax.naming.OperationNotSupportedException;
-
-/**
- * A context which combines two contexts.
- * 
- * Read operations are combined, write operations are done on the first context.
- * All other operations are not supported.
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class MultiplexerContext implements Context, Serializable
-{
-   private static final long serialVersionUID = -2306711582586456135L;
-   
-   private transient InitialContext initialCtx;
-   
-   private String contextOneName;
-   private String contextTwoName;
-
-   public MultiplexerContext(String contextOneName, String contextTwoName) throws NamingException
-   {
-      assert contextOneName != null;
-      assert contextTwoName != null;
-      
-      this.contextOneName = contextOneName;
-      this.contextTwoName = contextTwoName;
-      
-      // make sure this works further down the line
-      getContextOne();
-      getContextTwo();
-   }
-   
-   private <T extends NameClassPair> void addAll(Collection<T> collection, NamingEnumeration<T> ne) throws NamingException
-   {
-      // TODO: how about duplicates?
-      while(ne.hasMore())
-      {
-         T ncp = ne.next();
-         collection.add(ncp);
-      }
-   }
-   
-   public Object addToEnvironment(String propName, Object propVal) throws NamingException
-   {
-      throw new OperationNotSupportedException();
-   }
-
-   public void bind(Name name, Object obj) throws NamingException
-   {
-      getContextOne().bind(name, obj);  
-   }
-
-   public void bind(String name, Object obj) throws NamingException
-   {
-      getContextOne().bind(name, obj);
-   }
-
-   public void close() throws NamingException
-   {
-      // do nothing
-   }
-
-   public Name composeName(Name name, Name prefix) throws NamingException
-   {
-      return getContextOne().composeName(name, prefix);
-   }
-
-   public String composeName(String name, String prefix) throws NamingException
-   {
-      return getContextOne().composeName(name, prefix);
-   }
-
-   public Context createSubcontext(Name name) throws NamingException
-   {
-      return getContextOne().createSubcontext(name);
-   }
-
-   public Context createSubcontext(String name) throws NamingException
-   {
-      return getContextOne().createSubcontext(name);
-   }
-
-   public void destroySubcontext(Name name) throws NamingException
-   {
-      getContextOne().destroySubcontext(name);
-   }
-
-   public void destroySubcontext(String name) throws NamingException
-   {
-      getContextOne().destroySubcontext(name);
-   }
-
-   private Context getContextOne() throws NamingException
-   {
-      return (Context) getInitialContext().lookup(contextOneName);
-   }
-   
-   private Context getContextTwo() throws NamingException
-   {
-      return (Context) getInitialContext().lookup(contextTwoName);
-   }
-   
-   public Hashtable<?, ?> getEnvironment() throws NamingException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   private InitialContext getInitialContext() throws NamingException
-   {
-      if(initialCtx == null)
-      {
-         initialCtx = new InitialContext();
-      }
-      return initialCtx;
-   }
-   
-   public String getNameInNamespace() throws NamingException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public NameParser getNameParser(Name name) throws NamingException
-   {
-      return getContextOne().getNameParser(name);
-   }
-
-   public NameParser getNameParser(String name) throws NamingException
-   {
-      return getContextOne().getNameParser(name);
-   }
-
-   public NamingEnumeration<NameClassPair> list(Name name) throws NamingException
-   {
-      Collection<NameClassPair> set = new ArrayList<NameClassPair>();
-      addAll(set, getContextOne().list(name));
-      addAll(set, getContextTwo().list(name));
-      return new NamingEnumerationImpl<NameClassPair>(set);
-   }
-
-   public NamingEnumeration<NameClassPair> list(String name) throws NamingException
-   {
-      Collection<NameClassPair> set = new ArrayList<NameClassPair>();
-      addAll(set, getContextOne().list(name));
-      addAll(set, getContextTwo().list(name));
-      return new NamingEnumerationImpl<NameClassPair>(set);
-   }
-
-   public NamingEnumeration<Binding> listBindings(Name name) throws NamingException
-   {
-      Collection<Binding> set = new ArrayList<Binding>();
-      addAll(set, getContextOne().listBindings(name));
-      addAll(set, getContextTwo().listBindings(name));
-      return new NamingEnumerationImpl<Binding>(set);
-   }
-
-   public NamingEnumeration<Binding> listBindings(String name) throws NamingException
-   {
-      Collection<Binding> set = new ArrayList<Binding>();
-      addAll(set, getContextOne().listBindings(name));
-      addAll(set, getContextTwo().listBindings(name));
-      return new NamingEnumerationImpl<Binding>(set);
-   }
-
-   public Object lookup(Name name) throws NamingException
-   {
-      try
-      {
-         return getContextOne().lookup(name);
-      }
-      catch(NamingException e)
-      {
-         return getContextTwo().lookup(name);
-      }
-   }
-
-   public Object lookup(String name) throws NamingException
-   {
-      try
-      {
-         return getContextOne().lookup(name);
-      }
-      catch(NamingException e)
-      {
-         return getContextTwo().lookup(name);
-      }
-   }
-
-   public Object lookupLink(Name name) throws NamingException
-   {
-      try
-      {
-         return getContextOne().lookupLink(name);
-      }
-      catch(NamingException e)
-      {
-         return getContextTwo().lookupLink(name);
-      }
-   }
-
-   public Object lookupLink(String name) throws NamingException
-   {
-      try
-      {
-         return getContextOne().lookupLink(name);
-      }
-      catch(NamingException e)
-      {
-         return getContextTwo().lookupLink(name);
-      }
-   }
-
-   public void rebind(Name name, Object obj) throws NamingException
-   {
-      getContextOne().rebind(name, obj);
-   }
-
-   public void rebind(String name, Object obj) throws NamingException
-   {
-      getContextOne().rebind(name, obj);
-   }
-
-   public Object removeFromEnvironment(String propName) throws NamingException
-   {
-      throw new UnsupportedOperationException();
-   }
-
-   public void rename(Name oldName, Name newName) throws NamingException
-   {
-      getContextOne().rename(oldName, newName);
-   }
-
-   public void rename(String oldName, String newName) throws NamingException
-   {
-      getContextOne().rename(oldName, newName);
-   }
-
-   public void unbind(Name name) throws NamingException
-   {
-      getContextOne().unbind(name);
-   }
-
-   public void unbind(String name) throws NamingException
-   {
-      getContextOne().unbind(name);
-   }
-}

Deleted: trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/naming/NamingEnumerationImpl.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -1,85 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ejb3.naming;
-
-import java.util.Collection;
-import java.util.Iterator;
-
-import javax.naming.NameClassPair;
-import javax.naming.NamingEnumeration;
-import javax.naming.NamingException;
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class NamingEnumerationImpl<T extends NameClassPair> implements NamingEnumeration<T>
-{
-   private Iterator<T> iterator;
-   
-   NamingEnumerationImpl(Collection<T> set)
-   {
-      this.iterator = set.iterator();
-   }
-
-   /* (non-Javadoc)
-    * @see javax.naming.NamingEnumeration#close()
-    */
-   public void close() throws NamingException
-   {
-      // do nothing
-   }
-
-   /* (non-Javadoc)
-    * @see javax.naming.NamingEnumeration#hasMore()
-    */
-   public boolean hasMore() throws NamingException
-   {
-      return hasMoreElements();
-   }
-
-   /* (non-Javadoc)
-    * @see javax.naming.NamingEnumeration#next()
-    */
-   public T next() throws NamingException
-   {
-      return nextElement();
-   }
-
-   /* (non-Javadoc)
-    * @see java.util.Enumeration#hasMoreElements()
-    */
-   public boolean hasMoreElements()
-   {
-      return iterator.hasNext();
-   }
-
-   /* (non-Javadoc)
-    * @see java.util.Enumeration#nextElement()
-    */
-   public T nextElement()
-   {
-      return iterator.next();
-   }
-}

Deleted: trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/naming/SimpleMultiplexer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -1,51 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2006, Red Hat Middleware LLC, and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.ejb3.naming;
-
-import java.util.Hashtable;
-
-import javax.naming.Context;
-import javax.naming.Name;
-import javax.naming.NamingException;
-import javax.naming.spi.ObjectFactory;
-
-
-/**
- * Comment
- *
- * @author <a href="mailto:carlo.dewolf at jboss.com">Carlo de Wolf</a>
- * @version $Revision: $
- */
-public class SimpleMultiplexer implements ObjectFactory
-{
-   private Context context;
-   
-   public SimpleMultiplexer() throws NamingException
-   {
-      this.context = new MultiplexerContext("java:comp.original", "java:comp.ejb3");
-   }
-   
-   public Object getObjectInstance(Object obj, Name name, Context nameCtx, Hashtable<?, ?> environment) throws Exception
-   {
-      return context;
-   }
-}

Modified: trunk/ejb3/src/main/org/jboss/ejb3/service/ServiceContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/service/ServiceContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/service/ServiceContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -21,25 +21,6 @@
 */
 package org.jboss.ejb3.service;
 
-import java.lang.reflect.Method;
-import java.util.Hashtable;
-
-import javax.ejb.EJBException;
-import javax.ejb.Handle;
-import javax.ejb.Timer;
-import javax.ejb.TimerService;
-import javax.management.Attribute;
-import javax.management.AttributeList;
-import javax.management.AttributeNotFoundException;
-import javax.management.InstanceNotFoundException;
-import javax.management.InvalidAttributeValueException;
-import javax.management.MBeanException;
-import javax.management.MBeanInfo;
-import javax.management.MBeanRegistrationException;
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
-import javax.management.ReflectionException;
-
 import org.jboss.annotation.ejb.Management;
 import org.jboss.annotation.ejb.Service;
 import org.jboss.aop.AspectManager;
@@ -58,14 +39,31 @@
 import org.jboss.ejb3.Ejb3Deployment;
 import org.jboss.ejb3.ProxyFactory;
 import org.jboss.ejb3.SessionContainer;
-import org.jboss.ejb3.ThreadLocalENCFactory;
 import org.jboss.ejb3.asynchronous.AsynchronousInterceptor;
 import org.jboss.ejb3.interceptor.InterceptorInfoRepository;
 import org.jboss.ejb3.timerservice.TimedObjectInvoker;
 import org.jboss.ejb3.timerservice.TimerServiceFactory;
-import org.jboss.logging.Logger;
 import org.jboss.injection.Injector;
+import org.jboss.logging.Logger;
 
+import javax.ejb.EJBException;
+import javax.ejb.Handle;
+import javax.ejb.Timer;
+import javax.ejb.TimerService;
+import javax.management.Attribute;
+import javax.management.AttributeList;
+import javax.management.AttributeNotFoundException;
+import javax.management.InstanceNotFoundException;
+import javax.management.InvalidAttributeValueException;
+import javax.management.MBeanException;
+import javax.management.MBeanInfo;
+import javax.management.MBeanRegistrationException;
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+import javax.management.ReflectionException;
+import java.lang.reflect.Method;
+import java.util.Hashtable;
+
 /**
  * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
  * @version $Revision$
@@ -417,7 +415,7 @@
       {
          try
          {
-            ThreadLocalENCFactory.push(enc);
+            pushEnc();
             for (Injector injector : injectors)
             {
                injector.inject(ctx);
@@ -425,7 +423,7 @@
          }
          finally
          {
-            ThreadLocalENCFactory.pop();
+            popEnc();
          }
       }
       injected = true;

Modified: trunk/ejb3/src/main/org/jboss/ejb3/stateful/StatefulContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/stateful/StatefulContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/ejb3/stateful/StatefulContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -39,13 +39,12 @@
 import org.jboss.ejb3.ProxyFactoryHelper;
 import org.jboss.ejb3.ProxyUtils;
 import org.jboss.ejb3.SessionContainer;
-import org.jboss.ejb3.ThreadLocalENCFactory;
 import org.jboss.ejb3.cache.StatefulCache;
-import org.jboss.injection.Injector;
-import org.jboss.injection.JndiFieldInjector;
 import org.jboss.ejb3.interceptor.InterceptorInfoRepository;
 import org.jboss.ejb3.proxy.EJBMetaDataImpl;
 import org.jboss.ejb3.proxy.handle.HomeHandleImpl;
+import org.jboss.injection.Injector;
+import org.jboss.injection.JndiFieldInjector;
 import org.jboss.logging.Logger;
 
 import javax.annotation.PostConstruct;
@@ -136,7 +135,7 @@
    public Object localHomeInvoke(Method method, Object[] args) throws Throwable
    {
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          long hash = MethodHashing.calculateHash(method);
@@ -152,7 +151,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 
@@ -167,7 +166,7 @@
       long start = System.currentTimeMillis();
 
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          long hash = MethodHashing.calculateHash(method);
@@ -223,7 +222,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 
@@ -235,7 +234,7 @@
    public Object createSession()
    {
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          Thread.currentThread().setContextClassLoader(classloader);
@@ -244,7 +243,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 
@@ -256,7 +255,7 @@
    public Object createSession(Class[] initTypes, Object[] initValues)
    {
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          Thread.currentThread().setContextClassLoader(classloader);
@@ -265,7 +264,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 
@@ -287,7 +286,7 @@
       
       ClassLoader oldLoader = Thread.currentThread().getContextClassLoader();
       EJBContainerInvocation newSi = null;
-      ThreadLocalENCFactory.push(enc);
+      pushEnc();
       try
       {
          Thread.currentThread().setContextClassLoader(classloader);
@@ -372,7 +371,7 @@
       finally
       {
          Thread.currentThread().setContextClassLoader(oldLoader);
-         ThreadLocalENCFactory.pop();
+         popEnc();
       }
    }
 

Modified: trunk/ejb3/src/main/org/jboss/injection/InjectionContainer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/InjectionContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/injection/InjectionContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -67,7 +67,6 @@
    List<Injector> getInjectors();
 
    Context getEnc();
-   Context getEncEnv();
 
 
    PersistenceUnitDeployment getPersistenceUnitDeployment(String unitName) throws NameNotFoundException;

Modified: trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/main/org/jboss/injection/ResourceHandler.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -423,7 +423,7 @@
          //encName = InjectionUtil.getEncName(field);
          encName = property.getDeclaringClass().getName() + "/" + property.getName();
       }
-      else
+      if (!encName.startsWith("env/"))
       {
          encName = "env/" + encName;
       }

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntry.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -29,7 +29,7 @@
  */
 public interface TestEnvEntry
 {
-   void checkJNDI() throws NamingException;
+   int checkJNDI() throws NamingException;
    
    int getMaxExceptions();
    

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/TestEnvEntryBean.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -24,6 +24,7 @@
 import javax.annotation.Resource;
 import javax.ejb.Stateless;
 import javax.ejb.Remote;
+import javax.ejb.SessionContext;
 import javax.naming.InitialContext;
 import javax.naming.NamingException;
 
@@ -46,14 +47,18 @@
    @Resource(name="maxExceptions") private int maxExceptions = 4;
    
    @Resource private int numExceptions = 3;
+
+   @Resource
+   SessionContext sessionCtx;
    
    private int minExceptions = 1;
    
-   public void checkJNDI() throws NamingException
+   public int checkJNDI() throws NamingException
    {
       InitialContext ctx = new InitialContext();
-      Integer i = (Integer) ctx.lookup("java:comp/env/maxExceptions");
-      log.info("maxExceptions = " + i);
+      int rtn = (Integer) ctx.lookup("java:comp/env/maxExceptions");
+      if (rtn != (Integer)sessionCtx.lookup("maxExceptions")) throw new RuntimeException("Failed to match env lookup");
+      return rtn;
    }
    
    public int getMaxExceptions()

Modified: trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java
===================================================================
--- trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/ejb3/src/test/org/jboss/ejb3/test/enventry/unit/EnvEntryTestCase.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -112,7 +112,7 @@
       TestEnvEntry test = (TestEnvEntry)getInitialContext().lookup("TestEnvEntry");
       assertNotNull(test);
       
-      test.checkJNDI();
+      assertEquals(15, test.checkJNDI());
    }
    
    public static Test suite() throws Exception

Modified: trunk/server/src/main/org/jboss/ejb/EjbUtil.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EjbUtil.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/server/src/main/org/jboss/ejb/EjbUtil.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -388,7 +388,7 @@
       {
          // link contains a Bean Name, scan the DeploymentInfo tree
          DeploymentContext top = unit.getDeploymentContext();
-         while (top != null)
+         while (top.getParent() != null)
          {
             top = top.getParent();
          }

Modified: trunk/server/src/main/org/jboss/naming/ENCFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/naming/ENCFactory.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/server/src/main/org/jboss/naming/ENCFactory.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -23,6 +23,9 @@
 
 import java.util.Hashtable;
 import java.util.WeakHashMap;
+import java.util.LinkedList;
+import java.util.List;
+import java.util.concurrent.ConcurrentHashMap;
 import java.security.PrivilegedAction;
 import java.security.AccessController;
 import javax.naming.Context;
@@ -38,6 +41,7 @@
  *     
  *   @author <a href="mailto:rickard.oberg at telkel.com">Rickard Oberg</a>
  *   @author <a href="mailto:scott.stark at jboss.org">Scott Stark</a>
+ *   @author <a href="mailto:bill at jboss.org">Bill Burke</a>
  *   @version $Revision$
  */
 public class ENCFactory
@@ -46,9 +50,31 @@
    // Constants -----------------------------------------------------
     
    // Attributes ----------------------------------------------------
-   private static WeakHashMap encs = new WeakHashMap();
+   private static WeakHashMap classloaderKeyedEncs = new WeakHashMap();
    private static ClassLoader topLoader;
+   private static ThreadLocalStack<Object> encIdStack = new ThreadLocalStack<Object>();
+   private static ConcurrentHashMap<Object, Context> encById = new ConcurrentHashMap<Object, Context>();
 
+   public static List<Object> getIdStack()
+   {
+      return encIdStack.getList();
+   }
+
+   public static ConcurrentHashMap<Object, Context> getEncById()
+   {
+      return encById;
+   }
+
+   public static void pushContextId(Object id)
+   {
+      encIdStack.push(id);
+   }
+
+   public static Object popContextId()
+   {
+      return encIdStack.pop();
+   }
+
    // Static --------------------------------------------------------
    public static void setTopClassLoader(ClassLoader topLoader)
    {
@@ -69,11 +95,23 @@
       Hashtable environment)
       throws Exception
    {
+      Object currentId = encIdStack.get();
+      if (currentId != null)
+      {
+         Context compCtx = encById.get(currentId);
+         if (compCtx == null)
+         {
+            NamingServer srv = new NamingServer();
+            compCtx = new NamingContext(environment, null, srv);
+            encById.put(currentId, compCtx);
+         }
+         return compCtx;
+      }
       // Get naming for this component
       ClassLoader ctxClassLoader = GetTCLAction.getContextClassLoader();
-      synchronized (encs)
+      synchronized (classloaderKeyedEncs)
       {
-         Context compCtx = (Context) encs.get(ctxClassLoader);
+         Context compCtx = (Context) classloaderKeyedEncs.get(ctxClassLoader);
 
          /* If this is the first time we see ctxClassLoader first check to see
           if a parent ClassLoader has created an ENC namespace.
@@ -84,7 +122,7 @@
             GetParentAction action = new GetParentAction(ctxClassLoader);
             while( loader != null && loader != topLoader && compCtx == null )
             {
-               compCtx = (Context) encs.get(loader);
+               compCtx = (Context) classloaderKeyedEncs.get(loader);
                loader = action.getParent();
             }
             // If we did not find an ENC create it
@@ -92,7 +130,7 @@
             {
                NamingServer srv = new NamingServer();
                compCtx = new NamingContext(environment, null, srv);
-               encs.put(ctxClassLoader, compCtx);
+               classloaderKeyedEncs.put(ctxClassLoader, compCtx);
             }
          }
          return compCtx;

Modified: trunk/server/src/main/org/jboss/naming/JNDIView.java
===================================================================
--- trunk/server/src/main/org/jboss/naming/JNDIView.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/server/src/main/org/jboss/naming/JNDIView.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -27,6 +27,7 @@
 import java.util.Collection;
 import java.util.Iterator;
 import java.util.Set;
+import java.util.HashSet;
 
 import javax.management.Attribute;
 import javax.management.AttributeList;
@@ -50,25 +51,28 @@
  * A simple utlity mbean that allows one to recursively list the default
  * JBoss InitialContext.
  *
+ * @author <a href="mailto:Scott.Stark at jboss.org">Scott Stark</a>.
+ * @author Vladimir Blagojevic <vladimir at xisnext.2y.net>
+ * @author <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
+ * @version <tt>$Revision$</tt>
  * @jmx:mbean name="jboss:type=JNDIView"
- *            extends="org.jboss.system.ServiceMBean"
- *            
- * @version <tt>$Revision$</tt>
- * @author  <a href="mailto:Scott.Stark at jboss.org">Scott Stark</a>.
- * @author  Vladimir Blagojevic <vladimir at xisnext.2y.net>
- * @author  <a href="mailto:d_jencks at users.sourceforge.net">David Jencks</a>
+ * extends="org.jboss.system.ServiceMBean"
  */
 public class JNDIView
-      extends ServiceMBeanSupport
-      implements JNDIViewMBean
+        extends ServiceMBeanSupport
+        implements JNDIViewMBean
 {
-   /** The HANamingService attributes, order is significant in getHAUrl() */
+   /**
+    * The HANamingService attributes, order is significant in getHAUrl()
+    */
    protected static final String[] g_haAttributes = new String[]{"BindAddress", "Port"};
-   
-   /** The HANamingService service name */
-   protected String haNamingService;  
-  
+
    /**
+    * The HANamingService service name
+    */
+   protected String haNamingService;
+
+   /**
     * Provided for JMX compliance.
     */
    public JNDIView()
@@ -79,13 +83,12 @@
     * List deployed application java:comp namespaces, the java:
     * namespace as well as the global InitialContext JNDI namespace.
     *
+    * @param verbose, if true, list the class of each object in addition to its name
     * @jmx:managed-operation
-    * 
-    * @param verbose, if true, list the class of each object in addition to its name
     */
    public String list(boolean verbose)
    {
-      StringBuffer buffer = new StringBuffer(4096);      
+      StringBuffer buffer = new StringBuffer(4096);
       Context context = null;
       ClassLoader currentLoader = Thread.currentThread().getContextClassLoader();
 
@@ -103,11 +106,11 @@
          while (it.hasNext() == true)
          {
             WebApplication webApplication = (WebApplication) it.next();
-            
+
             Thread.currentThread().setContextClassLoader(webApplication.getMetaData().getENCLoader());
 
             buffer.append("<h2>java:comp namespace of the " + webApplication.getCanonicalName()
-                  + " application:</h2>\n");
+                    + " application:</h2>\n");
 
             try
             {
@@ -129,8 +132,8 @@
       catch (Throwable e)
       {
          log.debug("Unable to list web applications ENC", e);
-      }      
-      
+      }
+
       // Get all deployed applications so that we can list their
       // java: namespaces which are ClassLoader local
       Set ejbModules = null;
@@ -149,13 +152,14 @@
       }
 
       // List each application JNDI namespace
+      HashSet ejb2Ids = new HashSet();
       for (Iterator i = ejbModules.iterator(); i.hasNext();)
       {
          ObjectName app = (ObjectName) i.next();
          String module = app.getKeyProperty("module");
-         if( module == null )
+         if (module == null)
             module = app.toString();
-         buffer.append("<h1>Ejb Module: " + module + "</h1>\n");
+         buffer.append("<h1>Ejb 2.1 Module: " + module + "</h1>\n");
          try
          {
             Collection containers = (Collection) server.getAttribute(app, "Containers");
@@ -168,11 +172,13 @@
                */
                Thread.currentThread().setContextClassLoader(con.getClassLoader());
                String bean = con.getBeanMetaData().getEjbName();
+               Object on = con.getJmxName();
                buffer.append("<h2>java:comp namespace of the " + bean + " bean:</h2>\n");
 
                try
                {
-                  context = new InitialContext();
+                  context = ENCFactory.getEncById().get(on);
+                  ejb2Ids.add(on);
                   context = (Context) context.lookup("java:comp");
                }
                catch (NamingException e)
@@ -196,6 +202,18 @@
          }
       }
 
+      buffer.append("<h1> Other components with java:comp namespace</h1>\n");
+      for (Object key : ENCFactory.getEncById().keySet())
+      {
+         // skip EJB 2.1 keys
+         if (ejb2Ids.contains(key)) continue;
+         context = ENCFactory.getEncById().get(key);
+         buffer.append("<h2>java:comp namespace of the component " + key + " :</h2>\n");
+         buffer.append("<pre>\n");
+         list(context, " ", buffer, verbose);
+         buffer.append("</pre>\n");
+      }
+
       // List the java: namespace
       Thread.currentThread().setContextClassLoader(currentLoader);
       try
@@ -217,7 +235,7 @@
       // List the global JNDI namespace
       try
       {
-         context = new InitialContext();         
+         context = new InitialContext();
          buffer.append("<h1>Global JNDI Namespace</h1>\n");
          buffer.append("<pre>\n");
          list(context, " ", buffer, verbose);
@@ -229,14 +247,14 @@
          buffer.append("Failed to get InitialContext, " + e.toString(true));
          formatException(buffer, e);
       }
-      
+
       // List the HA-JNDI namespace if the HAJNDI service is available
       try
-      {  
-         String url = getHAUrl();            
+      {
+         String url = getHAUrl();
          if (url != null)
          {
-            java.util.Hashtable env = new java.util.Hashtable();        
+            java.util.Hashtable env = new java.util.Hashtable();
             env.put(Context.PROVIDER_URL, url);
             context = new InitialContext(env);
             buffer.append("<h1>HA-JNDI Namespace</h1>\n");
@@ -260,9 +278,7 @@
     * XML Format.
     *
     * @jmx:managed-operation
-    *
-    * @param verbose, if true, list the class of each object in addition to its name
-    **/
+    */
    public String listXML()
    {
       StringBuffer buffer = new StringBuffer(4096);
@@ -275,39 +291,39 @@
       {
          // Get all deployed web applications so that we can list their
          // java: namespaces which are ClassLoader local
-         Iterator it = (Iterator) server.getAttribute(AbstractWebDeployerMBean.OBJECT_NAME, "DeployedApplications"); 
-                  
-         while ( it.hasNext()==true )
+         Iterator it = (Iterator) server.getAttribute(AbstractWebDeployerMBean.OBJECT_NAME, "DeployedApplications");
+
+         while (it.hasNext() == true)
          {
             WebApplication webApplication = (WebApplication) it.next();
             openWebModuleTag(buffer, webApplication.getCanonicalName());
-            
+
             Thread.currentThread().setContextClassLoader(webApplication.getMetaData().getENCLoader());
-            
+
             try
-            {                              
+            {
                context = new InitialContext();
                context = (Context) context.lookup("java:comp");
-               
+
                listXML(context, buffer);
             }
-               catch (NamingException e)
-               {
-                  buffer.append("Failed on lookup, " + e.toString(true));
-                  formatException(buffer, e);
-                  continue;
-               }
-             finally 
+            catch (NamingException e)
             {
+               buffer.append("Failed on lookup, " + e.toString(true));
+               formatException(buffer, e);
+               continue;
+            }
+            finally
+            {
                closeWebModuleTag(buffer);
-            }            
-         }            
+            }
+         }
       }
       catch (Throwable e)
       {
          log.debug("Unable to list web applications ENC", e);
-      }      
-      
+      }
+
       /* Get all deployed applications so that we can list their
          java: namespaces which are ClassLoader local
       */
@@ -317,24 +333,85 @@
       }
       catch (Exception e)
       {
-         log.error("getDeployedApplications failed", e);         
+         log.error("getDeployedApplications failed", e);
          appendErrorTag(buffer,
-               "Failed to getDeployedApplications " + e.toString());
+                 "Failed to getDeployedApplications " + e.toString());
          closeJndiTag(buffer);
          return buffer.toString();
       }
 
+      HashSet ejb2Ids = new HashSet();
       // List each application JNDI namespace
       for (Iterator i = ejbModules.iterator(); i.hasNext();)
       {
          ObjectName app = (ObjectName) i.next();
          openEjbModuleTag(buffer, app.getKeyProperty("url"));
 
-         listModuleContainers(buffer, app);
+         Collection containers = null;
 
+         try
+         {
+            containers = (Collection) server.getAttribute(app, "Containers");
+         }
+         catch (Throwable t)
+         {
+            log.error("getContainers failed", t);
+            appendPreExceptionTag(buffer, "Failed to get ejbs in module", t);
+         }
+
+         for (Iterator iter = containers.iterator(); iter.hasNext();)
+         {
+            Container con = (Container) iter.next();
+            Object on = con.getJmxName();
+            ejb2Ids.add(on);
+            /* Set the thread class loader to that of the container as
+                     the class loader is used by the java: context object
+                     factory to partition the container namespaces.
+                  */
+            Thread.currentThread().setContextClassLoader(con.getClassLoader());
+            String bean = con.getBeanMetaData().getEjbName();
+            openContextTag(buffer);
+            appendBeanTag(buffer, bean);
+            Context context1 = ENCFactory.getEncById().get(on);
+            if (context1 == null)
+            {
+               appendErrorTag(buffer,
+                       "Failed to find ENC of EJB: " + on);
+               context1 = null;
+            }
+
+            if (context1 != null)
+            {
+               try
+               {
+                  listXML(context1, buffer);
+               }
+               catch (Throwable t)
+               {
+                  appendErrorTag(buffer,
+                          "Failed on list contents, " + t.toString());
+               }
+            }   //   if ( context != null )
+
+            closeContextTag(buffer);
+         }
+
          closeEjbModuleTag(buffer);
       }
 
+      //buffer.append("<h1> Other components with java:comp namespace</h1>\n");
+      for (Object key : ENCFactory.getEncById().keySet())
+      {
+         // skip EJB 2.1 keys
+         if (ejb2Ids.contains(key)) continue;
+         context = ENCFactory.getEncById().get(key);
+         buffer.append("<other-encs>");
+         openContextTag(buffer);
+         appendBeanTag(buffer, key.toString());
+         listXML(context, buffer);
+         closeContextTag(buffer);
+         buffer.append("</other-encs>");
+      }
       // List the java: namespace
       Thread.currentThread().setContextClassLoader(currentLoader);
       try
@@ -346,8 +423,8 @@
       {
          log.error("Failed to get InitialContext for (java:)", e);
          appendErrorTag(buffer,
-               "Failed to get InitialContext for (java:), " +
-               e.toString(true));
+                 "Failed to get InitialContext for (java:), " +
+                         e.toString(true));
       }
 
       if (context != null)
@@ -362,8 +439,8 @@
          {
             log.error("Failed to list contents of (java:)", t);
             appendErrorTag(buffer,
-                  "Failed to list contents of (java:), " +
-                  t.toString());
+                    "Failed to list contents of (java:), " +
+                            t.toString());
          }
          closeContextTag(buffer);
 
@@ -378,7 +455,7 @@
       {
          log.error("Failed to get InitialContext", e);
          appendErrorTag(buffer,
-               "Failed to get InitialContext, " + e.toString(true));
+                 "Failed to get InitialContext, " + e.toString(true));
       }
 
       if (context != null)
@@ -393,20 +470,20 @@
          {
             log.error("Failed to list global contents ", t);
             appendErrorTag(buffer,
-                  "Failed to list global contents, " + t.toString());
+                    "Failed to list global contents, " + t.toString());
          }
          closeContextTag(buffer);
 
       }   //   if ( context != null )
-      
+
       // List the HA-JNDI namespace if the HAJNDI service is available
       String url = null;
       try
       {
-         url = getHAUrl();            
+         url = getHAUrl();
          if (url != null)
-         {   
-            java.util.Hashtable env = new java.util.Hashtable();        
+         {
+            java.util.Hashtable env = new java.util.Hashtable();
             env.put(Context.PROVIDER_URL, url);
             context = new InitialContext(env);
          }
@@ -415,7 +492,7 @@
       {
          log.error("Failed to get InitialContext", e);
          appendErrorTag(buffer,
-               "Failed to get InitialContext, " + e.toString(true));
+                 "Failed to get InitialContext, " + e.toString(true));
       }
 
       if (url != null && context != null)
@@ -430,28 +507,29 @@
          {
             log.error("Failed to list HA-JNDI contents ", t);
             appendErrorTag(buffer,
-                  "Failed to list HA-JNDI contents, " + t.toString());
+                    "Failed to list HA-JNDI contents, " + t.toString());
          }
          closeContextTag(buffer);
 
       }   //   if ( url != null && context != null )
 
       closeJndiTag(buffer);
-      
+
       return buffer.toString();
    }
-   
+
    public String getHANamingService()
    {
       return haNamingService;
    }
+
    public void setHANamingService(String serviceName)
    {
       haNamingService = serviceName;
    }
 
    protected ObjectName getObjectName(MBeanServer server, ObjectName name)
-         throws javax.management.MalformedObjectNameException
+           throws javax.management.MalformedObjectNameException
    {
       return name == null ? OBJECT_NAME : name;
    }
@@ -651,8 +729,8 @@
                   catch (Throwable t)
                   {
                      appendErrorTag(buffer,
-                           "Failed to lookup: " + name +
-                           ", errmsg=" + t.getMessage());
+                             "Failed to lookup: " + name +
+                                     ", errmsg=" + t.getMessage());
                   }
 
                   if (value instanceof Context)
@@ -668,8 +746,8 @@
                      catch (Throwable t)
                      {
                         appendErrorTag(buffer,
-                              "Failed to list contents of: " + name +
-                              ", errmsg=" + t.getMessage());
+                                "Failed to list contents of: " + name +
+                                        ", errmsg=" + t.getMessage());
                      }
 
                      closeContextTag(buffer);
@@ -690,72 +768,11 @@
       catch (NamingException ne)
       {
          appendErrorTag(buffer,
-               "error while listing context " +
-               ctx.toString() + ": " + ne.toString(true));
+                 "error while listing context " +
+                         ctx.toString() + ": " + ne.toString(true));
       }
    }
 
-   private void listModuleContainers(StringBuffer buffer, ObjectName app)
-   {
-      Collection containers = null;
-
-      try
-      {
-         containers = (Collection) server.getAttribute(app, "Containers");
-      }
-      catch (Throwable t)
-      {
-         log.error("getContainers failed", t);
-         appendPreExceptionTag(buffer, "Failed to get ejbs in module", t);
-      }
-
-      for (Iterator iter = containers.iterator(); iter.hasNext();)
-      {
-         listContainerContext(buffer, (Container) iter.next());
-      }
-
-   }   //   listModuleContainers()
-
-   private void listContainerContext(StringBuffer buffer, Container con)
-   {
-      /* Set the thread class loader to that of the container as
-         the class loader is used by the java: context object
-         factory to partition the container namespaces.
-      */
-      Thread.currentThread().setContextClassLoader(con.getClassLoader());
-      String bean = con.getBeanMetaData().getEjbName();
-      openContextTag(buffer);
-      appendBeanTag(buffer, bean);
-      Context context = null;
-      try
-      {
-         context = new InitialContext();
-         context = (Context) context.lookup("java:comp");
-      }
-      catch (NamingException e)
-      {
-         appendErrorTag(buffer,
-               "Failed on lookup " + e.toString(true));
-         context = null;
-      }
-
-      if (context != null)
-      {
-         try
-         {
-            listXML(context, buffer);
-         }
-         catch (Throwable t)
-         {
-            appendErrorTag(buffer,
-                  "Failed on list contents, " + t.toString());
-         }
-      }   //   if ( context != null )
-
-      closeContextTag(buffer);
-
-   }   //   listContainerContext()
-
    private void openJndiTag(StringBuffer buffer)
    {
       buffer.append("<jndi>\n");
@@ -776,7 +793,7 @@
    {
       buffer.append("</webmodule>\n");
    }
-   
+
    private void openEjbModuleTag(StringBuffer buffer, String file)
    {
       buffer.append("<ejbmodule>\n");
@@ -792,7 +809,7 @@
                                       String msg,
                                       Throwable t)
    {
-      buffer.append("<pre>\n" + msg+"\n");
+      buffer.append("<pre>\n" + msg + "\n");
       formatException(buffer, t);
       buffer.append("</pre>\n");
    }
@@ -812,7 +829,7 @@
    {
       buffer.append("<name>Global</name>\n");
    }
-   
+
    private void appendHANameTag(StringBuffer buffer)
    {
       buffer.append("<name>HA</name>\n");
@@ -832,10 +849,10 @@
       catch (NamingException e)
       {
          appendErrorTag(buffer,
-               "Failed to getLinkName, " + e.toString(true));
+                 "Failed to getLinkName, " + e.toString(true));
       }
       buffer.append("<attribute name='class'>" + ncp.getClassName() +
-            "</attribute>\n");
+              "</attribute>\n");
       buffer.append("</link-ref>\n");
    }
 
@@ -874,7 +891,7 @@
    {
       buffer.append("<name>" + ncp.getName() + "</name>\n");
       buffer.append("<attribute name='class'>" + ncp.getClassName() +
-            "</attribute>\n");
+              "</attribute>\n");
    }
 
    private void appendErrorTag(StringBuffer buffer, String msg)
@@ -893,12 +910,12 @@
       buffer.append(sw.toString());
       buffer.append("</pre>\n");
    }
-   
+
    private String getHAUrl()
    {
       String bindAddress = null;
       String portNumber = null;
-      
+
       AttributeList list = getHAJndiAttributes();
       // list will be null if HA-JNDI service couldn't be retrieved
       if (list == null)
@@ -907,29 +924,29 @@
       // list[0] is BindAddress
       Object o = list.get(0);
       if (o != null)
-         bindAddress = ((Attribute)o).getValue().toString();
-      
+         bindAddress = ((Attribute) o).getValue().toString();
+
       // list[1] is Port
       o = list.get(1);
       if (o != null)
-         portNumber = ((Attribute)o).getValue().toString();
+         portNumber = ((Attribute) o).getValue().toString();
 
       if (bindAddress != null && portNumber != null)
-         return "jnp://"+bindAddress+":"+portNumber;
+         return "jnp://" + bindAddress + ":" + portNumber;
 
       return null;
    }
-   
+
    private AttributeList getHAJndiAttributes()
    {
       if (haNamingService == null)
-	  {
+      {
          // HA-JNDI is not deployed, so there will be no attributes
          return null;
       }
 
       try
-      {        
+      {
          ObjectName name = new ObjectName(haNamingService);
          return server.getAttributes(name, g_haAttributes);
       }

Added: trunk/server/src/main/org/jboss/naming/ThreadLocalStack.java
===================================================================
--- trunk/server/src/main/org/jboss/naming/ThreadLocalStack.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/server/src/main/org/jboss/naming/ThreadLocalStack.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -0,0 +1,78 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.naming;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * Comment
+ *
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision: 42263 $
+ */
+public class ThreadLocalStack<T>
+{
+   private ThreadLocal<ArrayList<T>> stack = new ThreadLocal<ArrayList<T>>();
+
+   public void push(T obj)
+   {
+      ArrayList<T> list = stack.get();
+      if (list == null)
+      {
+         list = new ArrayList<T>(1);
+         stack.set(list);
+      }
+      list.add(obj);
+   }
+
+   public T pop()
+   {
+      ArrayList<T> list = stack.get();
+      if (list == null)
+      {
+         return null;
+      }
+      T rtn = list.remove(list.size() - 1);
+      if (list.size() == 0)
+      {
+         stack.set(null);
+         list.clear();
+      }
+      return rtn;
+   }
+
+   public T get()
+   {
+      ArrayList<T> list = (ArrayList<T>)stack.get();
+      if (list == null)
+      {
+         return null;
+      }
+      return list.get(list.size() - 1);
+   }
+
+   public List<T> getList()
+   {
+      return stack.get();
+   }
+}

Modified: trunk/testsuite/src/main/org/jboss/test/naming/ejb/TestENCBean.java
===================================================================
--- trunk/testsuite/src/main/org/jboss/test/naming/ejb/TestENCBean.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/testsuite/src/main/org/jboss/test/naming/ejb/TestENCBean.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -117,7 +117,7 @@
       }
       catch (NamingException e)
       {
-         log.debug("failed", e);
+         log.error("failed", e);
          throw new EJBException(e.toString(true));
       }
       catch (JMSException e)

Modified: trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/TomcatInjectionContainer.java
===================================================================
--- trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/TomcatInjectionContainer.java	2006-12-21 20:52:50 UTC (rev 59202)
+++ trunk/tomcat/src/main/org/jboss/web/tomcat/tc6/TomcatInjectionContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
@@ -404,27 +404,6 @@
       }
    }
 
-   public Context getEncEnv()
-   {
-      ClassLoader old = Thread.currentThread().getContextClassLoader();
-      try
-      {
-         Thread.currentThread().setContextClassLoader(getClassloader());
-         try
-         {
-            return (Context) new InitialContext().lookup("java:comp/env");
-         }
-         catch (NamingException e)
-         {
-            throw new RuntimeException(e);
-         }
-      }
-      finally
-      {
-         Thread.currentThread().setContextClassLoader(old);
-      }
-   }
-
    public PersistenceUnitDeployment getPersistenceUnitDeployment(String unitName) throws NameNotFoundException
    {
       return persistenceUnitResolver.getPersistenceUnitDeployment(unitName);



From smcgowan at redhat.com  Thu Dec 21 16:29:05 2006
From: smcgowan at redhat.com (Shelly McGowan)
Date: Thu, 21 Dec 2006 16:29:05 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.4.1.CR1/lib - New
	directory ...
Message-ID: <E1GxVTN-0007J9-0A@committer01.frg.pub.inap.atl.jboss.com>

  User: smcgowan
  Date: 06/12/21 16:29:04

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/cache/1.4.1.CR1/lib added to the repository


From smcgowan at redhat.com  Thu Dec 21 16:41:04 2006
From: smcgowan at redhat.com (Shelly McGowan)
Date: Thu, 21 Dec 2006 16:41:04 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.4.1.CR1   ...
Message-ID: <E1GxVey-0007Xi-Bs@committer01.frg.pub.inap.atl.jboss.com>

  User: smcgowan
  Date: 06/12/21 16:41:04

  Added:       jboss/cache/1.4.1.CR1   README.txt component-info.xml
  Log:
  created
  
  Revision  Changes    Path
  1.1      date: 2006/12/21 21:41:04;  author: smcgowan;  state: Exp;repository.jboss.com/jboss/cache/1.4.1.CR1/README.txt
  
  Index: README.txt
  ===================================================================
  $Id: README.txt,v 1.1 2006/12/21 21:41:04 smcgowan Exp $
  
  NAME:    JBossCache
  VERSION: 1.4.1.CR1
  PROJECT: http://www.jboss.com/products/jbosscache
  PURPOSE: Used by Clustering in JBossAS, HTTP session replication
  
  
  
  
  1.1      date: 2006/12/21 21:41:04;  author: smcgowan;  state: Exp;repository.jboss.com/jboss/cache/1.4.1.CR1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-cache-component-info">
  
     <!-- ============================================================ -->
     <!-- jboss/cache                                                      -->
     <!-- ============================================================ -->
  
     <component id="jboss/cache"
                version="1.4.1.CR1"
                licenseType="lgpl"
                projectHome="http://www.jboss.org/products/jbosscache"
                description="JBoss Cache is a product designed to cache 
                frequently accessed Java objects in order to dramatically improve 
                the performance of e-business applications."
     >
        <artifact id="jboss-cache.jar"/>
        <artifact id="jboss-cache-jdk50.jar"/>
        <export>
           <include input="jboss-cache.jar"/>
           <include input="jboss-cache-jdk50.jar"/>
        </export>
     </component>
  </project>
  
  
  


From smcgowan at redhat.com  Thu Dec 21 16:41:04 2006
From: smcgowan at redhat.com (Shelly McGowan)
Date: Thu, 21 Dec 2006 16:41:04 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/cache/1.4.1.CR1/lib   ...
Message-ID: <E1GxVey-0007Xq-Gz@committer01.frg.pub.inap.atl.jboss.com>

  User: smcgowan
  Date: 06/12/21 16:41:04

  Added:       jboss/cache/1.4.1.CR1/lib   jboss-cache-jdk50.jar
                        jboss-cache.jar
  Log:
  created
  
  Revision  Changes    Path
  1.1      date: 2006/12/21 21:41:04;  author: smcgowan;  state: Exp;repository.jboss.com/jboss/cache/1.4.1.CR1/lib/jboss-cache-jdk50.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/21 21:41:04;  author: smcgowan;  state: Exp;repository.jboss.com/jboss/cache/1.4.1.CR1/lib/jboss-cache.jar
  
  	<<Binary file>>
  
  


From vladimir.blagojevic at jboss.com  Thu Dec 21 16:41:10 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 21 Dec 2006 16:41:10 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer    ...
Message-ID: <E1GxVf4-0007Y8-MP@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/21 16:41:10

  Modified:    src/org/jboss/cache/statetransfer   
                        DefaultStateTransferGenerator.java
                        DefaultStateTransferIntegrator.java
                        StateTransferManager.java
  Log:
  final state transfer polishing (all tests pass now)
  
  Revision  Changes    Path
  1.7       +5 -17     JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferGenerator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- DefaultStateTransferGenerator.java	14 Dec 2006 17:18:48 -0000	1.6
  +++ DefaultStateTransferGenerator.java	21 Dec 2006 21:41:10 -0000	1.7
  @@ -8,7 +8,6 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
  @@ -43,8 +42,6 @@
                                boolean generatePersistent, boolean suppressErrors) throws Throwable
      {
         Fqn fqn = rootNode.getFqn();
  -      Throwable encouteredException = null;
  -
         try
         {
            out.writeShort(STATE_TRANSFER_VERSION);
  @@ -106,17 +103,8 @@
         }
         catch (Throwable t)
         {
  -         encouteredException = t;
  -         log.error("failed writing state", t);
            out.writeObject(new NodeDataExceptionMarker(t, cache.getLocalAddress()));
  -      }
  -      finally
  -      {
  -         out.close();
  -         if (encouteredException != null && !suppressErrors)
  -         {
  -            throw encouteredException;
  -         }
  +         throw t;
         }
      }
   
  @@ -158,7 +146,7 @@
         for (Iterator it = children.entrySet().iterator(); it.hasNext();)
         {
            Map.Entry entry = (Map.Entry) it.next();
  -         marshallTransientState((DataNode) entry.getValue(), out);
  +         marshallTransientState((Node) entry.getValue(), out);
         }
      }
   
  
  
  
  1.9       +19 -29    JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferIntegrator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- DefaultStateTransferIntegrator.java	20 Dec 2006 22:28:13 -0000	1.8
  +++ DefaultStateTransferIntegrator.java	21 Dec 2006 21:41:10 -0000	1.9
  @@ -9,10 +9,10 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.TreeNode;
   import org.jboss.cache.buddyreplication.BuddyManager;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.loader.CacheLoader;
  @@ -53,20 +53,10 @@
   
      public void integrateState(ObjectInputStream ois, Node target, ClassLoader cl) throws Exception
      {
  -      Throwable cause = null;
  -      try
  -      {
            integrateTransientState(ois, target, cl);
            integrateAssociatedState(ois);
            integratePersistentState(ois);
         }
  -      catch (Throwable t)
  -      {
  -         cause = t;
  -         log.error("Failed integrating state.", t);
  -         throw new Exception("State transfer failed ", cause);
  -      }      
  -   }
   
      protected void integrateTransientState(ObjectInputStream in, Node target, ClassLoader cl) throws Exception
      {
  @@ -97,7 +87,7 @@
               // Clear any existing state from the targetRoot
               log.warn("transient state integration failed, removing all children of " + target);
               target.clearData();
  -            ((DataNode) target).removeChildren();
  +            ((TreeNode) target).removeChildren();
            }
   
            resetClassLoader(oldCL);
  @@ -197,7 +187,7 @@
       */
      private void notifyAllNodesCreated(Node curr)
      {
  -      DataNode n;
  +      TreeNode n;
   
         if (curr == null) return;
         getCache().getNotifier().notifyNodeCreated(curr.getFqn(), true);
  @@ -205,7 +195,7 @@
         Set children = curr.getChildren();
         for (Iterator it = children.iterator(); it.hasNext();)
         {
  -         n = (DataNode) it.next();
  +         n = (TreeNode) it.next();
            notifyAllNodesCreated(n);
         }
      }
  @@ -234,7 +224,7 @@
      {
         Set retainedNodes = retainInternalNodes(target);
   
  -      ((DataNode) target).removeChildren();
  +      ((TreeNode) target).removeChildren();
   
         // Read the first NodeData and integrate into our target     
         NodeData nd = readNode(in);
  @@ -242,7 +232,7 @@
         //are there any transient nodes at all?
         if (nd != null && !nd.isMarker())
         {
  -         target.put(nd.getAttributes(), true);
  +         target.put(nd.getAttributes());
   
            // Check whether this is an integration into the buddy backup
            // subtree
  @@ -301,10 +291,10 @@
   
            name = fqn.get(size - 1);
   
  -         // We handle this NodeData.  Create a DataNode and
  +         // We handle this NodeData.  Create a TreeNode and
            // integrate its data            
            Node target = factory.createDataNode(nodeType, name, fqn, parent, nd.getAttributes(), false, null, cache.getCacheSPI());
  -         ((DataNode) parent).addChild(name, target);
  +         ((TreeNode) parent).addChild(name, target);
   
            // Recursively call, which will walk down the tree
            // and return the next NodeData that's a child of our parent
  @@ -322,7 +312,7 @@
            Fqn internalFqn = (Fqn) it.next();
            if (internalFqn.isChildOf(targetFqn))
            {
  -            DataNode internalNode = getInternalNode(target, internalFqn);
  +            TreeNode internalNode = getInternalNode(target, internalFqn);
               if (internalNode != null)
               {
                  result.add(internalNode);
  @@ -333,10 +323,10 @@
         return result;
      }
   
  -   private DataNode getInternalNode(Node parent, Fqn internalFqn)
  +   private TreeNode getInternalNode(Node parent, Fqn internalFqn)
      {
         Object name = internalFqn.get(parent.getFqn().size());
  -      DataNode result = (DataNode) parent.getChild(new Fqn(name));
  +      TreeNode result = (TreeNode) parent.getChild(new Fqn(name));
         if (result != null)
         {
            if (internalFqn.size() < result.getFqn().size())
  @@ -353,7 +343,7 @@
         Fqn rootFqn = root.getFqn();
         for (Iterator it = retainedNodes.iterator(); it.hasNext();)
         {
  -         DataNode retained = (DataNode) it.next();
  +         TreeNode retained = (TreeNode) it.next();
            if (retained.getFqn().isChildOf(rootFqn))
            {
               integrateRetainedNode(root, retained);
  @@ -361,17 +351,17 @@
         }
      }
   
  -   private void integrateRetainedNode(Node ancestor, DataNode descendant)
  +   private void integrateRetainedNode(Node ancestor, TreeNode descendant)
      {
         Fqn descFqn = descendant.getFqn();
         Fqn ancFqn = ancestor.getFqn();
         Object name = descFqn.get(ancFqn.size());
  -      DataNode child = (DataNode) ancestor.getChild(new Fqn(name));
  +      TreeNode child = (TreeNode) ancestor.getChild(new Fqn(name));
         if (ancFqn.size() == descFqn.size() + 1)
         {
            if (child == null)
            {
  -            ((DataNode) ancestor).addChild(name, descendant);
  +            ((TreeNode) ancestor).addChild(name, descendant);
            }
            else
            {
  @@ -386,7 +376,7 @@
               // This shouldn't really happen -- internal fqns should
               // be immediately under the root
               child = factory.createDataNode(nodeType, name, new Fqn(ancFqn, name), ancestor, null, true, null, cache.getCacheSPI());
  -            ((DataNode) ancestor).addChild(name, child);
  +            ((TreeNode) ancestor).addChild(name, child);
            }
   
            // Keep walking down the tree
  
  
  
  1.19      +42 -20    JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- StateTransferManager.java	20 Dec 2006 22:28:13 -0000	1.18
  +++ StateTransferManager.java	21 Dec 2006 21:41:10 -0000	1.19
  @@ -8,6 +8,7 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheException;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
  @@ -67,7 +68,7 @@
         VersionAwareMarshaller marshaller = cache.getMarshaller();
   
         // can't give state for regions currently being activated/inactivated
  -      boolean canProvideState = !(marshaller.isInactive(fqn.toString()) || cache.findNode(fqn) == null);
  +      boolean canProvideState = (!marshaller.isInactive(fqn.toString()) && cache.findNode(fqn) != null);
   
         boolean fetchTransientState = cache.getConfiguration().isFetchInMemoryState();
         CacheLoaderManager cacheLoaderManager = cache.getCacheLoaderManager();
  @@ -96,12 +97,31 @@
         else
         {
            out.writeBoolean(false);
  +         Exception e = null;
  +         if(!canProvideState)
  +         {
  +            String exceptionMessage = "Cache instance at " + cache.getLocalAddress() + " cannot provide state for fqn " + fqn +".";
  +            
  +            if(marshaller.isInactive(fqn.toString()))
  +            {
  +               exceptionMessage += " Region for fqn " + fqn + " is inactive.";
  +            }
  +            if(cache.findNode(fqn) == null)
  +            {
  +               exceptionMessage += " There is no cache node at fqn " + fqn;
  +            }
  +            e = new CacheException(exceptionMessage);           
  +         }
  +         if(!fetchPersistentState && !fetchTransientState)
  +         {
  +            e = new CacheException("Cache instance at " + cache.getLocalAddress() + " is not configured to provide state");
  +         }
  +         out.writeObject(e);
  +         throw e;
         }
      }   
   
      /**
  -    * TODO change this javadoc
  -    * <p/>
       * Requests state from each of the given source nodes in the cluster
       * until it gets it or no node replies with a timeout exception.  If state
       * is returned, integrates it into the given DataNode.  If no state is
  @@ -132,14 +152,14 @@
       * is up to the caller to lock <code>targetRoot</code> before calling
       * this method.
       *
  -    * @param state      a serialized byte[][] array where element 0 is the
  +    * @param in      a serialized byte[][] array where element 0 is the
       *                   transient state (or null) , and element 1 is the
       *                   persistent state (or null)
       * @param targetRoot fqn of the node into which the state should be integrated
       * @param cl         classloader to use to unmarshal the state, or
       *                   <code>null</code> if the TCCL should be used
       */
  -   public void setState(ObjectInputStream state, Fqn targetRoot, ClassLoader cl) throws Exception
  +   public void setState(ObjectInputStream in, Fqn targetRoot, ClassLoader cl) throws Exception
      {
         TreeCache cache = getTreeCache();
         Node target = cache.findNode(targetRoot);
  @@ -150,7 +170,16 @@
            cache.put(targetRoot, null);
            target = cache.findNode(targetRoot);
         }
  -      setState(state, target, cl);
  +      boolean hasState = in.readBoolean();
  +      if(hasState)
  +      {
  +         setState(in, target, cl);
  +      }
  +      else
  +      {
  +         throw new CacheException("Cache instance at " + cache.getLocalAddress()
  +               + " cannot integrate state since state provider could not provide state due to " + in.readObject());
  +      }
      }
   
      /**
  @@ -172,13 +201,13 @@
      private void setState(ObjectInputStream state, Node targetRoot, ClassLoader cl) throws Exception
      {
         Object owner = getOwnerForLock();
  +      long timeout = cache.getConfiguration().getInitialStateRetrievalTimeout();
         long startTime = System.currentTimeMillis();
   
         try
         {
            // Acquire a lock on the root node
  -         acquireLocksForStateTransfer(targetRoot, owner, getTreeCache().getConfiguration()
  -               .getInitialStateRetrievalTimeout(), true, true);
  +         acquireLocksForStateTransfer(targetRoot, owner, timeout, true, true);
   
            /*
             * Vladimir/Manik/Brian (Dec 7,2006)
  @@ -193,18 +222,11 @@
            option.setBypassInterceptorChain(true);
            cache.getInvocationContext().setOptionOverrides(option);
   
  -         try
  -         {
               StateTransferIntegrator integrator = getStateTransferIntegrator(state, targetRoot.getFqn());
               log.info("starting state integration at node " + targetRoot);
               integrator.integrateState(state, targetRoot, cl);
               log.info("successfully integrated state in " + (System.currentTimeMillis() - startTime) + " msec");
            }
  -         catch (Throwable t)
  -         {
  -            log.error("failed integrating state", t);
  -         }
  -      }
         finally
         {
            releaseStateTransferLocks(targetRoot, owner, true);
  
  
  


From vladimir.blagojevic at jboss.com  Thu Dec 21 16:41:10 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 21 Dec 2006 16:41:10 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1GxVf4-0007YF-QR@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/21 16:41:10

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  final state transfer polishing (all tests pass now)
  
  Revision  Changes    Path
  1.55      +6 -6      JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.54
  retrieving revision 1.55
  diff -u -b -r1.54 -r1.55
  --- BuddyManager.java	21 Dec 2006 18:10:24 -0000	1.54
  +++ BuddyManager.java	21 Dec 2006 21:41:10 -0000	1.55
  @@ -427,11 +427,11 @@
               {
                  ByteArrayInputStream bais = new ByteArrayInputStream(stateBuffer);
                  in = new MarshalledValueInputStream(bais);
  -               boolean hasState = in.readBoolean();
  -               if (hasState)
  -               {
                     stateMgr.setState(in, integrationRoot, cl);
                  }
  +            catch(Throwable t)
  +            {
  +               log.error("State for fqn " + fqn + " could not be transferred to a buddy at " + cache.getLocalAddress());
               }
               finally
               {
  
  
  


From vladimir.blagojevic at jboss.com  Thu Dec 21 16:41:10 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 21 Dec 2006 16:41:10 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxVf4-0007YM-WF@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/21 16:41:10

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  final state transfer polishing (all tests pass now)
  
  Revision  Changes    Path
  1.300     +86 -107   JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.299
  retrieving revision 1.300
  diff -u -b -r1.299 -r1.300
  --- TreeCache.java	21 Dec 2006 05:34:03 -0000	1.299
  +++ TreeCache.java	21 Dec 2006 21:41:10 -0000	1.300
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.299 2006/12/21 05:34:03 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.300 2006/12/21 21:41:10 vblagojevic Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -151,7 +151,7 @@
      /**
       * JGroups message listener.
       */
  -   protected MessageListenerAdaptor ml = new MessageListenerAdaptor(log);
  +   protected MessageListenerAdaptor ml = new MessageListenerAdaptor();
   
      /**
       * Maintains mapping of transactions (keys) and Modifications/Undo-Operations
  @@ -172,7 +172,7 @@
      /**
       * True if state was initialized during start-up.
       */
  -   protected boolean isStateSet = false;
  +   protected volatile boolean isStateSet = false;
   
      protected String evictionInterceptorClass = "org.jboss.cache.interceptors.EvictionInterceptor";
   
  @@ -580,7 +580,19 @@
         {
            Address target = (Address) iter.next();
            log.debug("Node " + getLocalAddress() + " fetching partial state " + stateId + " from member " + target);
  +         isStateSet = false;
            successfulTransfer = channel.getState(target, stateId, stateFetchTimeout);
  +         if (successfulTransfer)
  +         {
  +            try
  +            {
  +               ml.waitForState();
  +            }
  +            catch(Exception transferFailed)
  +            {
  +               successfulTransfer = false;
  +            }
  +         }
            log.debug("Node " + getLocalAddress() + " fetching partial state " + stateId + " from member " + target + (successfulTransfer ? " successful" : " failed"));
         }
   
  @@ -3217,22 +3229,15 @@
         node.getNodeSPI().setFqn(newFqn);
      }
   
  -   class MessageListenerAdaptor implements ExtendedMessageListener
  +   protected class MessageListenerAdaptor implements ExtendedMessageListener
      {
  -      final Log my_log;// Need this to run under jdk1.3
  -      final boolean trace;
  -
         /**
          * An exception occuring upon fetch state.
          */
  -      protected Exception setStateException;
  +      protected volatile Exception setStateException;
         private final Object stateLock = new Object();
   
  -      MessageListenerAdaptor(Log log)
  -      {
  -         this.my_log = log;
  -         this.trace = my_log.isTraceEnabled();
  -      }
  +      protected MessageListenerAdaptor(){}
   
         public void waitForState() throws Exception
         {
  @@ -3256,14 +3261,53 @@
            }
         }
   
  +      protected void stateReceivedSuccess()
  +      {         
  +         isStateSet = true;
  +         setStateException = null;        
  +      }
  +      
  +      protected void stateReceivingFailed(Throwable t)
  +      {         
  +         if(t instanceof CacheException)
  +         {
  +            log.debug(t);
  +         }
  +         else
  +         {
  +            log.error("failed setting state", t);
  +         }
  +         if (t instanceof Exception)
  +         {
  +            setStateException = (Exception) t;
  +         }
  +         else
  +         {
  +            setStateException = new Exception(t);
  +         }
  +      }
  +      
  +      protected void stateProducingFailed(Throwable t)
  +      {
  +         if (t instanceof CacheException)
  +         {
  +            log.debug(t);
  +         }
  +         else
  +         {
  +            log.error("Caught " + t.getClass().getName()
  +                  + " while responding to partial byte based state transfer request", t);
  +         }
  +      }
  +
         /**
          * Callback, does nothing.
          */
         public void receive(Message msg)
         {
  -         if (trace)
  +         if (log.isTraceEnabled())
            {
  -            my_log.trace("Received message " + msg);
  +            log.trace("Received message " + msg);
            }
         }
         
  @@ -3281,11 +3325,7 @@
            }
            catch (Throwable t)
            {
  -            // This shouldn't happen as we set "suppressErrors" to true,
  -            // but we have to catch the Throwable declared in the method sig
  -            my_log.error("Caught " + t.getClass().getName() +
  -                    " while responding to initial state transfer request;" +
  -                    " returning null", t);            
  +            stateProducingFailed(t); 
            }
            finally
            {
  @@ -3298,7 +3338,7 @@
         {
            if (new_state == null)
            {
  -            my_log.debug("transferred state is null (may be first member in cluster)");
  +            log.debug("transferred state is null (may be first member in cluster)");
               return;
            }
            ByteArrayInputStream bais = new ByteArrayInputStream(new_state);
  @@ -3306,24 +3346,12 @@
            try
            {                               
               in = new MarshalledValueInputStream(bais);
  -            boolean hasState = in.readBoolean();
  -            if(hasState)
  -            {
                  getStateTransferManager().setState(in, Fqn.ROOT, null);
  -            }
  -            isStateSet = true;           
  +            stateReceivedSuccess();           
            }
            catch (Throwable t)
            {
  -            my_log.error("failed setting state", t);
  -            if (t instanceof Exception)
  -            {
  -               setStateException = (Exception) t;
  -            }
  -            else
  -            {
  -               setStateException = new Exception(t);
  -            }
  +            stateReceivingFailed(t);
            }
            finally
            {
  @@ -3359,11 +3387,7 @@
            }
            catch (Throwable t)
            {
  -            // This shouldn't happen as we set "suppressErrors" to true,
  -            // but we have to catch the Throwable declared in the method sig
  -            my_log.error("Caught " + t.getClass().getName() +
  -                    " while responding to partial state transfer request;" +
  -                    " returning null", t);            
  +            stateProducingFailed(t); 
            }
            finally
            {
  @@ -3382,11 +3406,7 @@
            }
            catch (Throwable t)
            {
  -            // This shouldn't happen as we set "suppressErrors" to true,
  -            // but we have to catch the Throwable declared in the method sig
  -            my_log.error("Caught " + t.getClass().getName() +
  -                    " while responding to initial state transfer request;" +
  -                    " returning null", t);
  +            stateProducingFailed(t); 
            }
            finally
            {
  @@ -3410,11 +3430,7 @@
            }
            catch (Throwable t)
            {
  -            // This shouldn't happen as we set "suppressErrors" to true,
  -            // but we have to catch the Throwable declared in the method sig
  -            my_log.error("Caught " + t.getClass().getName() +
  -                    " while responding to partial state transfer request;" +
  -                    " returning null", t);
  +            stateProducingFailed(t); 
            }
            finally
            {
  @@ -3426,31 +3442,19 @@
         {
            if (istream == null)
            {
  -            my_log.debug("stream is null (may be first member in cluster)");
  +            log.debug("stream is null (may be first member in cluster)");
               return;
            }
            MarshalledValueInputStream in = null;
            try
            {
               in = new MarshalledValueInputStream(istream);   
  -            boolean hasState = in.readBoolean();
  -            if(hasState)
  -            {
                  getStateTransferManager().setState(in, Fqn.ROOT, null);
  -            }
  -            isStateSet = true;           
  +            stateReceivedSuccess();          
            }
            catch (Throwable t)
            {
  -            my_log.error("failed setting state", t);
  -            if (t instanceof Exception)
  -            {
  -               setStateException = (Exception) t;
  -            }
  -            else
  -            {
  -               setStateException = new Exception(t);
  -            }
  +            stateReceivingFailed(t);
            }
            finally
            {
  @@ -3467,7 +3471,7 @@
         {
            if (state == null)
            {
  -            my_log.debug("partial transferred state is null");
  +            log.debug("partial transferred state is null");
               return;
            }
            
  @@ -3480,8 +3484,7 @@
            }
            try
            {
  -
  -            my_log.debug("Setting received partial state for subroot " + state_id);
  +            log.debug("Setting received partial state for subroot " + state_id);
               Fqn subroot = Fqn.fromString(targetRoot);
               Region region = regionManager.getRegion(subroot, false);
               ClassLoader cl = null;
  @@ -3492,24 +3495,12 @@
               }
               ByteArrayInputStream bais = new ByteArrayInputStream(state);
               in = new MarshalledValueInputStream(bais);
  -            boolean hasState = in.readBoolean();
  -            if(hasState)
  -            {
                  getStateTransferManager().setState(in, subroot, cl);
  -            }
  -            isStateSet = true;
  +            stateReceivedSuccess();
            }
            catch (Throwable t)
            {
  -            my_log.error("failed setting state", t);
  -            if (t instanceof Exception)
  -            {
  -               setStateException = (Exception) t;
  -            }
  -            else
  -            {
  -               setStateException = new Exception(t);
  -            }
  +            stateReceivingFailed(t);
            }
            finally
            {
  @@ -3533,13 +3524,13 @@
            }
            if (istream == null)
            {
  -            my_log.debug("stream is null (may be first member in cluster). State is not set");
  +            log.debug("stream is null (may be first member in cluster). State is not set");
               return;
            }
   
            try
            {
  -            my_log.debug("Setting received partial state for subroot " + state_id);
  +            log.debug("Setting received partial state for subroot " + state_id);
               in = new MarshalledValueInputStream(istream);                      
               Fqn subroot = Fqn.fromString(targetRoot);
               Region region = regionManager.getRegion(subroot, false);
  @@ -3549,24 +3540,12 @@
                  // If a classloader is registered for the node's region, use it
                  cl = region.getClassLoader();
               }
  -            boolean hasState = in.readBoolean();
  -            if(hasState)
  -            {
                  getStateTransferManager().setState(in,subroot, cl);
  -            }
  -            isStateSet = true;           
  +            stateReceivedSuccess();          
            }
            catch (Throwable t)
            {
  -            my_log.error("failed setting partial state", t);
  -            if (t instanceof Exception)
  -            {
  -               setStateException = (Exception) t;
  -            }
  -            else
  -            {
  -               setStateException = new Exception(t);
  -            }
  +            stateReceivingFailed(t);
            }
            finally
            {
  
  
  


From vladimir.blagojevic at jboss.com  Thu Dec 21 16:41:36 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Thu, 21 Dec 2006 16:41:36 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/statetransfer
	...
Message-ID: <E1GxVfU-0007Yf-3j@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/21 16:41:36

  Modified:    tests/functional/org/jboss/cache/statetransfer    
                        FailedStateTransferTest.java VersionedTestBase.java
                        StateTransferTestBase.java
                        StateTransfer200Test.java
  Log:
  test update
  
  Revision  Changes    Path
  1.7       +46 -15    JBossCache/tests/functional/org/jboss/cache/statetransfer/FailedStateTransferTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FailedStateTransferTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/FailedStateTransferTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- FailedStateTransferTest.java	11 Sep 2006 17:42:41 -0000	1.6
  +++ FailedStateTransferTest.java	21 Dec 2006 21:41:36 -0000	1.7
  @@ -22,9 +22,9 @@
   
   package org.jboss.cache.statetransfer;
   
  +import java.io.InputStream;
  +
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.Version;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -55,9 +55,21 @@
         tree.create();
         tree.start();
   
  -      CacheSPI recipient = createCache("recipient", false, false, false, false, false);
  +      
  +      TreeCache recipient = new SecretiveStateCache();
  +      recipient.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  +      recipient.getConfiguration().setClusterName("VersionedTestBase");
  +      recipient.getConfiguration().setReplVersionString(getReplicationVersion());
  +      // Use a long timeout to facilitate setting debugger breakpoints
  +      recipient.getConfiguration().setInitialStateRetrievalTimeout(60000);
  +      
  +      //Put the cache in the map before starting, so if it fails in
  +      // start it can still be destroyed later
  +      caches.put("secretive2", recipient.getCacheSPI());
  +      
         try
         {
  +         recipient.create();
            recipient.start();
            fail("start() should throw an exception");
         }
  @@ -72,20 +84,39 @@
         return Version.version;
      }
   
  -   /**
  -    * Overrides the superclass to always throw an exception in _getState
  -    */
      private static class SecretiveStateCache extends TreeCache
      {
         SecretiveStateCache() throws Exception
         {
            super();
  +         ml = new Adaptor();
         }
  +      class Adaptor extends MessageListenerAdaptor
  +      {
   
  -      public byte[] _getState(Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
  +         @Override
  +         public void setState(byte[] new_state)
         {
  -         throw new TimeoutException("Planned Timeout");
  +            setStateException = new TimeoutException("Planned Timeout");
         }
   
  +         @Override
  +         public void setState(InputStream istream)
  +         {
  +            setStateException = new TimeoutException("Planned Timeout");
  +         }
  +
  +         @Override
  +         public void setState(String state_id, byte[] state)
  +         {
  +            setStateException = new TimeoutException("Planned Timeout");
  +         }
  +
  +         @Override
  +         public void setState(String state_id, InputStream istream)
  +         {
  +            setStateException = new TimeoutException("Planned Timeout");
  +         }         
  +      }
      }
   }
  
  
  
  1.20      +10 -85    JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: VersionedTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- VersionedTestBase.java	14 Nov 2006 19:56:09 -0000	1.19
  +++ VersionedTestBase.java	21 Dec 2006 21:41:36 -0000	1.20
  @@ -7,7 +7,6 @@
   
   package org.jboss.cache.statetransfer;
   
  -import EDU.oswego.cs.dl.util.concurrent.Semaphore;
   import org.jboss.cache.CacheException;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  @@ -18,6 +17,8 @@
   
   import java.lang.reflect.Method;
   import java.util.Random;
  +import java.util.concurrent.Semaphore;
  +import java.util.concurrent.TimeUnit;
   
   /**
    * Abstract superclass of "StateTransferVersion"-specific tests
  @@ -454,7 +455,7 @@
      {
         // TODO: Needs revisiting after concurrent FLUSH is supported
         //http://jira.jboss.com/jira/browse/JGRP-332
  -      //concurrentActivationTest(true);
  +      concurrentActivationTest(true);
      }
   
      /**
  @@ -468,7 +469,7 @@
      {
         // TODO: Needs revisiting after concurrent FLUSH is supported
         //http://jira.jboss.com/jira/browse/JGRP-332
  -      //concurrentActivationTest(false);
  +      concurrentActivationTest(false);
      }
   
      /**
  @@ -522,7 +523,7 @@
            // we know the threads are done         
            for (int i = 0; i < count; i++)
            {
  -            boolean acquired = semaphore.attempt(60000);
  +            boolean acquired = semaphore.tryAcquire(60, TimeUnit.SECONDS);
               if (!acquired)
                  fail("failed to acquire semaphore " + i);
            }
  @@ -623,7 +624,7 @@
            // we know the threads are done         
            for (int i = 0; i < count; i++)
            {
  -            boolean acquired = semaphore.attempt(60000);
  +            boolean acquired = semaphore.tryAcquire(60, TimeUnit.SECONDS);
               if (!acquired)
                  fail("failed to acquire semaphore " + i);
            }
  @@ -718,7 +719,7 @@
      {
         // TODO: Needs revisiting after concurrent FLUSH is supported
         //http://jira.jboss.com/jira/browse/JGRP-332
  -      //concurrentUseTest(true);
  +      concurrentUseTest(true);
      }
   
      /**
  @@ -731,7 +732,7 @@
      {
         // TODO: Needs revisiting after concurrent FLUSH is supported
         //http://jira.jboss.com/jira/browse/JGRP-332
  -      //concurrentUseTest(false);
  +      concurrentUseTest(false);
      }
   
      /**
  @@ -812,7 +813,7 @@
                  stressors[i].stopPuts();
                  System.out.println("Run " + x + "-- /" + names[i] + " activated on A");
                  // Reacquire one semaphore ticket
  -               boolean acquired = semaphore.attempt(60000);
  +               boolean acquired = semaphore.tryAcquire(60, TimeUnit.SECONDS);
                  if (!acquired)
                     fail("failed to acquire semaphore " + i);
   
  @@ -973,7 +974,7 @@
            {
               if (i > 0)
               {
  -               acquired = semaphore.attempt(60000);
  +               acquired = semaphore.tryAcquire(60, TimeUnit.SECONDS);
                  if (!acquired)
                     throw new Exception(name + " cannot acquire semaphore");
               }
  @@ -1020,80 +1021,4 @@
   
   
      }
  -
  -   private abstract class CacheUser implements Runnable
  -   {
  -      protected Semaphore semaphore;
  -      protected CacheSPI cache;
  -      protected String name;
  -      protected Exception exception;
  -      protected Thread thread;
  -
  -      CacheUser(Semaphore semaphore,
  -                String name,
  -                boolean sync,
  -                boolean activateRoot)
  -              throws Exception
  -      {
  -         this.cache = createCache(name, sync, true, false);
  -         this.semaphore = semaphore;
  -         this.name = name;
  -
  -         if (activateRoot)
  -            cache.getRegion(Fqn.ROOT, true).activate();
  -      }
  -
  -      public void run()
  -      {
  -         boolean acquired = false;
  -         try
  -         {
  -            acquired = semaphore.attempt(60000);
  -            if (!acquired)
  -               throw new Exception(name + " cannot acquire semaphore");
  -            //System.out.println(name + " acquired semaphore");
  -
  -            useCache();
  -
  -         }
  -         catch (Exception e)
  -         {
  -            System.out.println(name + ": " + e.getLocalizedMessage());
  -            e.printStackTrace(System.out);
  -
  -            // Save it for the test to check
  -            exception = e;
  -         }
  -         finally
  -         {
  -            if (acquired)
  -               semaphore.release();
  -         }
  -
  -      }
  -
  -      abstract void useCache() throws Exception;
  -
  -      public Exception getException()
  -      {
  -         return exception;
  -      }
  -
  -      public CacheSPI getCacheSPI()
  -      {
  -         return cache;
  -      }
  -
  -      public void start()
  -      {
  -         thread = new Thread(this);
  -         thread.start();
  -      }
  -
  -      public void cleanup()
  -      {
  -         if (thread != null && thread.isAlive())
  -            thread.interrupt();
  -      }
  -   }
   }
  
  
  
  1.25      +85 -1     JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- StateTransferTestBase.java	31 Oct 2006 06:57:29 -0000	1.24
  +++ StateTransferTestBase.java	21 Dec 2006 21:41:36 -0000	1.25
  @@ -26,17 +26,19 @@
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.config.Configuration;
  -import org.jboss.cache.factories.CacheFactory;
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.loader.AbstractCacheLoaderTestBase;
   import org.jboss.cache.marshall.SelectedClassnameClassLoader;
   
  +
   import java.io.File;
   import java.util.HashMap;
   import java.util.Map;
   import java.util.Properties;
   import java.util.Set;
  +import java.util.concurrent.Semaphore;
  +import java.util.concurrent.TimeUnit;
   
   /**
    * Abstract superclass of the StateTransfer tests.
  @@ -293,4 +295,86 @@
         return new SelectedClassnameClassLoader(null, null, notFoundClasses, cl);
      }
   
  +   protected abstract class CacheUser implements Runnable
  +   {
  +      protected Semaphore semaphore;
  +      protected CacheSPI cache;
  +      protected String name;
  +      protected Exception exception;
  +      protected Thread thread;
  +
  +      CacheUser(){}
  +      
  +      CacheUser(Semaphore semaphore,
  +                String name,
  +                boolean sync,
  +                boolean activateRoot)
  +              throws Exception
  +      {
  +         this.cache = createCache(name, sync, true, false);
  +         this.semaphore = semaphore;
  +         this.name = name;
  +
  +         if (activateRoot)
  +            cache.getRegion(Fqn.ROOT, true).activate();
  +      }
  +
  +      public void run()
  +      {
  +         boolean acquired = false;
  +         try
  +         {
  +            acquired = semaphore.tryAcquire(60, TimeUnit.SECONDS);
  +            if (!acquired)
  +               throw new Exception(name + " cannot acquire semaphore");
  +            //System.out.println(name + " acquired semaphore");
  +
  +            useCache();
  +
  +         }
  +         catch (Exception e)
  +         {
  +            System.out.println(name + ": " + e.getLocalizedMessage());
  +            e.printStackTrace(System.out);
  +
  +            // Save it for the test to check
  +            exception = e;
  +         }
  +         finally
  +         {
  +            if (acquired)
  +               semaphore.release();
  +         }
  +
  +      }
  +
  +      abstract void useCache() throws Exception;
  +
  +      public Exception getException()
  +      {
  +         return exception;
  +      }
  +
  +      public CacheSPI getCacheSPI()
  +      {
  +         return cache;
  +      }
  +      
  +      public String getName()
  +      {
  +         return name;
  +      }
  +
  +      public void start()
  +      {
  +         thread = new Thread(this);
  +         thread.start();
  +      }
  +
  +      public void cleanup()
  +      {
  +         if (thread != null && thread.isAlive())
  +            thread.interrupt();
  +      }
  +   }
   }
  
  
  
  1.11      +14 -5     JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransfer200Test.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransfer200Test.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransfer200Test.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- StateTransfer200Test.java	20 Nov 2006 03:53:57 -0000	1.10
  +++ StateTransfer200Test.java	21 Dec 2006 21:41:36 -0000	1.11
  @@ -26,7 +26,7 @@
    * Tests that state transfer works properly if the version is 2.0.0.GA.
    *
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public class StateTransfer200Test extends VersionedTestBase
   {
  @@ -107,9 +107,18 @@
         cache1.put(A_C, "name", BOB);
         cache1.put(A_C, "age", FORTY);
   
  -      CacheSPI cache2 = createCache("cache2", false, false, true, false, true);
  -      // Pause to give caches time to see each other
  -      TestingUtil.blockUntilViewsReceived(new CacheSPI[]{cache1, cache2}, 60000);
  +      CacheSPI cache2 = null;
  +      try
  +      {
  +         cache2 = createCache("cache2", false, false, true, false, false);
  +         cache2.create();
  +         cache2.start();
  +         fail("Should have caused an exception");
  +      }
  +      catch(Exception e)
  +      {
  +         assertNotNull(e);
  +      }      
   
         //when persistent transfer fails as in this case state recipient cacheloader should be wiped clean
         assertFalse("/a/b is not in cache loader ", cache2.getCacheLoader().exists(A_B));
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 17:09:45 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 17:09:45 -0500
Subject: [jboss-cvs] JBossAS SVN: r59204 - in
	trunk/server/src/main/org/jboss/ejb: . plugins plugins/inflow
	plugins/jms plugins/local txtimer
Message-ID: <E1GxW6j-00086q-QG@committer01.frg.pub.inap.atl.jboss.com>

Author: bill.burke at jboss.com
Date: 2006-12-21 17:09:38 -0500 (Thu, 21 Dec 2006)
New Revision: 59204

Modified:
   trunk/server/src/main/org/jboss/ejb/Container.java
   trunk/server/src/main/org/jboss/ejb/EjbModule.java
   trunk/server/src/main/org/jboss/ejb/EntityContainer.java
   trunk/server/src/main/org/jboss/ejb/GlobalTxEntityMap.java
   trunk/server/src/main/org/jboss/ejb/MessageDrivenContainer.java
   trunk/server/src/main/org/jboss/ejb/SessionContainer.java
   trunk/server/src/main/org/jboss/ejb/plugins/EntityMultiInstanceSynchronizationInterceptor.java
   trunk/server/src/main/org/jboss/ejb/plugins/EntitySynchronizationInterceptor.java
   trunk/server/src/main/org/jboss/ejb/plugins/inflow/MessageEndpointInterceptor.java
   trunk/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java
   trunk/server/src/main/org/jboss/ejb/plugins/local/BaseLocalProxyFactory.java
   trunk/server/src/main/org/jboss/ejb/txtimer/TimedObjectInvokerImpl.java
Log:
Revamp java:comp processing EJB 2.1 containers now push/pop ENC ID onto ENCFactory ThreadLocal stack

Modified: trunk/server/src/main/org/jboss/ejb/Container.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/Container.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/Container.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -78,6 +78,7 @@
 import org.jboss.naming.ENCThreadLocalKey;
 import org.jboss.naming.NonSerializableFactory;
 import org.jboss.naming.Util;
+import org.jboss.naming.ENCFactory;
 import org.jboss.security.AnybodyPrincipal;
 import org.jboss.security.AuthenticationManager;
 import org.jboss.security.AuthorizationManager;
@@ -541,22 +542,43 @@
       this.metaData = metaData;
    }
 
+   /**
+    * push the ENC onto the stack so that java:comp works
+    *
+    */
+   public void pushENC()
+   {
+      ENCFactory.pushContextId(getJmxName());
+   }
+
+   public void popENC()
+   {
+      ENCFactory.popContextId();
+   }
+
+   /**
+    * cleanup ENC on shutdown
+    *
+    */
+   public void cleanENC()
+   {
+      ENCFactory.getEncById().remove(getJmxName());   
+   }
+
    /** Get the components environment context
     * @jmx.managed-attribute
     * @return Environment Context
     */
    public Context getEnvContext() throws NamingException
    {
-      ClassLoader ccl = SecurityActions.getContextClassLoader();
+      pushENC();
       try
       {
-         // The ENC is a map keyed on the class loader
-         SecurityActions.setContextClassLoader(classLoader);
          return (Context)new InitialContext().lookup("java:comp/env");
       }
       finally
       {
-         SecurityActions.setContextClassLoader(ccl);
+         popENC();
       }
    }
 
@@ -846,6 +868,7 @@
     */
    protected void destroyService() throws Exception
    {
+      cleanENC();
       localProxyFactory.destroy();
       ejbModule.removeLocalHome(this);
 
@@ -904,6 +927,7 @@
       String contextID = getJaccContextID();
       try
       {
+         pushENC();
          if(!this.classLoader.equals(callerClassLoader))
          {
             setCl = true;
@@ -1019,6 +1043,8 @@
          // stat gathering: concurrent calls
          this.invokeStats.callOut();
 
+         popENC();
+
          // Restore the incoming class loader
          if(setCl)
          {

Modified: trunk/server/src/main/org/jboss/ejb/EjbModule.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EjbModule.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/EjbModule.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -474,13 +474,14 @@
          {
             ClassLoader oldCl = SecurityActions.getContextClassLoader();
             SecurityActions.setContextClassLoader(con.getClassLoader());
-
+            con.pushENC();
             try
             {
                ((EntityContainer)con).getPersistenceManager().start();
             }
             finally
             {
+               con.popENC();
                // Reset classloader
                SecurityActions.setContextClassLoader(oldCl);
             }

Modified: trunk/server/src/main/org/jboss/ejb/EntityContainer.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/EntityContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/EntityContainer.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -244,7 +244,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Acquire classes from CL
@@ -322,6 +322,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -332,7 +333,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Call default start
@@ -364,6 +365,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -374,7 +376,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          //Stop items in reverse order from start
@@ -411,6 +413,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -421,7 +424,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Destroy container invoker
@@ -483,6 +486,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }

Modified: trunk/server/src/main/org/jboss/ejb/GlobalTxEntityMap.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/GlobalTxEntityMap.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/GlobalTxEntityMap.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -127,9 +127,16 @@
             EntityContainer container = (EntityContainer) instance.getContainer();
             // set the context class loader before calling the store method
             SecurityActions.setContextClassLoader(thread, container.getClassLoader());
-
-            // store it
-            container.invokeEjbStore(instance);
+            container.pushENC();
+            try
+            {
+               // store it
+               container.invokeEjbStore(instance);
+            }
+            finally
+            {
+               container.popENC();
+            }
          }
       }
 
@@ -144,11 +151,18 @@
 
             // set the context class loader before calling the store method
             SecurityActions.setContextClassLoader(thread, container.getClassLoader());
+            container.pushENC();
+            try
+            {
+               // store it
+               container.storeEntity(instance);
 
-            // store it
-            container.storeEntity(instance);
-
-            instance.setTxAssociation(SYNCHRONIZED);
+               instance.setTxAssociation(SYNCHRONIZED);
+            }
+            finally
+            {
+               container.popENC();
+            }
          }
       }
    };

Modified: trunk/server/src/main/org/jboss/ejb/MessageDrivenContainer.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/MessageDrivenContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/MessageDrivenContainer.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -162,7 +162,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Call default init
@@ -237,6 +237,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -247,7 +248,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Call default start
@@ -277,6 +278,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -287,7 +289,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Call default stop
@@ -314,6 +316,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -324,7 +327,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Destroy container invoker
@@ -377,6 +380,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }

Modified: trunk/server/src/main/org/jboss/ejb/SessionContainer.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/SessionContainer.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/SessionContainer.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -142,7 +142,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Acquire classes from CL
@@ -183,6 +183,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -388,7 +389,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Call default start
@@ -409,6 +410,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -461,7 +463,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          // Call default stop
@@ -479,6 +481,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }
@@ -527,7 +530,7 @@
       // Associate thread with classloader
       ClassLoader oldCl = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(getClassLoader());
-
+      pushENC();
       try
       {
          destroyInvokers();
@@ -552,6 +555,7 @@
       }
       finally
       {
+         popENC();
          // Reset classloader
          SecurityActions.setContextClassLoader(oldCl);
       }

Modified: trunk/server/src/main/org/jboss/ejb/plugins/EntityMultiInstanceSynchronizationInterceptor.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/EntityMultiInstanceSynchronizationInterceptor.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/plugins/EntityMultiInstanceSynchronizationInterceptor.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -124,7 +124,7 @@
          // thread is associated with the right context class loader
          ClassLoader oldCl = SecurityActions.getContextClassLoader();
          SecurityActions.setContextClassLoader(container.getClassLoader());
-
+         container.pushENC();
          ctx.hasTxSynchronization(false);
          ctx.setTransaction(null);
          try
@@ -168,6 +168,7 @@
          } // synchronized(lock)
          finally
          {
+            container.popENC();
             SecurityActions.setContextClassLoader(oldCl);
          }
       }

Modified: trunk/server/src/main/org/jboss/ejb/plugins/EntitySynchronizationInterceptor.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/EntitySynchronizationInterceptor.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/plugins/EntitySynchronizationInterceptor.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -441,6 +441,7 @@
          {
             SecurityActions.setContextClassLoader(container.getClassLoader());
          }
+         container.pushENC();
 
          int commitOption = ctx.isPassivateAfterCommit() ?
             ConfigurationMetaData.C_COMMIT_OPTION : EntitySynchronizationInterceptor.this.commitOption;
@@ -513,6 +514,7 @@
          {
             lock.releaseSync();
             container.getLockManager().removeLockRef(lock.getId());
+            container.popENC();
             if(setCl)
             {
                SecurityActions.setContextClassLoader(oldCl);

Modified: trunk/server/src/main/org/jboss/ejb/plugins/inflow/MessageEndpointInterceptor.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/inflow/MessageEndpointInterceptor.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/plugins/inflow/MessageEndpointInterceptor.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -244,6 +244,7 @@
      
       MessageDrivenContainer container = getContainer(mi);
       boolean commit = true;
+      container.pushENC();
       try
       {
          // Check for starting a transaction
@@ -265,6 +266,7 @@
       }
       finally
       {
+         container.popENC();
          // No before/after delivery, end any transaction and release the lock
          if (oldClassLoader == null)
          {
@@ -299,6 +301,7 @@
       {
          // Reset delivered flag
          delivered = false;
+
          // Change back to the original context classloader
          resetContextClassLoader(mi);
          // We no longer hold the lock

Modified: trunk/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/plugins/jms/JMSContainerInvoker.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -982,12 +982,14 @@
       // Set the right context classloader
       ClassLoader oldCL = TCLAction.UTIL.getContextClassLoader();
       TCLAction.UTIL.setContextClassLoader(container.getClassLoader());
+      container.pushENC();
       try
       {
          return container.invoke(invocation);
       }
       finally
       {
+         container.popENC();
          TCLAction.UTIL.setContextClassLoader(oldCL);
       }
    }

Modified: trunk/server/src/main/org/jboss/ejb/plugins/local/BaseLocalProxyFactory.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/plugins/local/BaseLocalProxyFactory.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/plugins/local/BaseLocalProxyFactory.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -344,6 +344,7 @@
       {
          TCLAction.UTIL.setContextClassLoader(container.getClassLoader());
       }
+      container.pushENC();
 
       SecurityActions sa = SecurityActions.UTIL.getSecurityActions();
       try
@@ -376,6 +377,7 @@
       }
       finally
       {
+         container.popENC();
          if(setCl)
          {
             TCLAction.UTIL.setContextClassLoader(oldCl);
@@ -415,6 +417,7 @@
       {
          TCLAction.UTIL.setContextClassLoader(container.getClassLoader());
       }
+      container.pushENC();
 
       SecurityActions sa = SecurityActions.UTIL.getSecurityActions();
       try
@@ -447,6 +450,7 @@
       }
       finally
       {
+         container.popENC();
          if(setCl)
          {
             TCLAction.UTIL.setContextClassLoader(oldCl);

Modified: trunk/server/src/main/org/jboss/ejb/txtimer/TimedObjectInvokerImpl.java
===================================================================
--- trunk/server/src/main/org/jboss/ejb/txtimer/TimedObjectInvokerImpl.java	2006-12-21 21:23:17 UTC (rev 59203)
+++ trunk/server/src/main/org/jboss/ejb/txtimer/TimedObjectInvokerImpl.java	2006-12-21 22:09:38 UTC (rev 59204)
@@ -78,6 +78,7 @@
    {
       ClassLoader callerClassLoader = SecurityActions.getContextClassLoader();
       SecurityActions.setContextClassLoader(container.getClassLoader());
+      container.pushENC();
       try
       {
          Invocation inv = new Invocation(timedObjectId.getInstancePk(), method, new Object[]{timer}, null, null, null);
@@ -100,6 +101,7 @@
       }
       finally
       {
+         container.popENC();
          SecurityActions.popRunAsIdentity();
          SecurityActions.setContextClassLoader(callerClassLoader);
       }



From brian.stansberry at jboss.com  Thu Dec 21 18:11:57 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 18:11:57 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1GxX4v-0000qe-JB@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 18:11:57

  Removed:     tests/functional/org/jboss/cache/eviction  Tag:
                        Branch_JBossCache_1_4_0
                        StateTransferIntegrationTest.java
  Log:
  Move the JBCACHE-913 tests to the versioned state transfer tests


From brian.stansberry at jboss.com  Thu Dec 21 18:11:57 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 18:11:57 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/statetransfer
	...
Message-ID: <E1GxX4v-0000qp-NZ@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 18:11:57

  Modified:    tests/functional/org/jboss/cache/statetransfer  Tag:
                        Branch_JBossCache_1_4_0 VersionedTestBase.java
  Log:
  Move the JBCACHE-913 tests to the versioned state transfer tests
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.6.2.3   +61 -0     JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: VersionedTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java,v
  retrieving revision 1.6.2.2
  retrieving revision 1.6.2.3
  diff -u -b -r1.6.2.2 -r1.6.2.3
  --- VersionedTestBase.java	4 Nov 2006 06:16:47 -0000	1.6.2.2
  +++ VersionedTestBase.java	21 Dec 2006 23:11:57 -0000	1.6.2.3
  @@ -10,9 +10,15 @@
   import java.lang.reflect.Method;
   import java.util.Map;
   import java.util.Random;
  +import java.util.Set;
   
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.PropertyConfigurator;
  +import org.jboss.cache.TreeCache;
   import org.jboss.cache.TreeCacheMBean;
  +import org.jboss.cache.eviction.Region;
  +import org.jboss.cache.eviction.RegionManager;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -611,6 +617,61 @@
         
      }
      
  +   /**
  +    * Test for JBCACHE-913
  +    * 
  +    * @throws Exception
  +    */
  +   public void testEvictionSeesStateTransfer() throws Exception
  +   {
  +      TreeCache cache1 = new TreeCache();
  +      PropertyConfigurator config = new PropertyConfigurator();
  +      config.configure(cache1, "META-INF/replSync-eviction-service.xml");      
  +      cache1.startService();
  +      
  +      cache1.put("/a/b/c", "key", "value");
  +      
  +      TreeCache cache2 = new TreeCache();
  +      config.configure(cache2, "META-INF/replSync-eviction-service.xml");
  +      cache2.startService();
  +      
  +      RegionManager erm = cache2.getEvictionRegionManager();
  +      Region region = erm.getRegion(Fqn.ROOT);
  +      // We expect events for /a, /a/b and /a/b/c
  +      assertEquals("Saw the expected number of node events", 3, region.nodeEventQueueSize());
  +   }
  +   
  +   /**
  +    * Further test for JBCACHE-913
  +    * 
  +    * @throws Exception
  +    */
  +   public void testEvictionAfterStateTransfer() throws Exception
  +   {
  +      TreeCache cache1 = new TreeCache();
  +      PropertyConfigurator config = new PropertyConfigurator();
  +      config.configure(cache1, "META-INF/replSync-eviction-service.xml");      
  +      cache1.startService();
  +      
  +      for (int i = 0; i < 4; i++)
  +         cache1.put("/org/jboss/test/data/" + i, "key", "value");
  +      
  +      TreeCache cache2 = new TreeCache();
  +      config.configure(cache2, "META-INF/replSync-eviction-service.xml");
  +      cache2.startService();
  +      
  +      Set children = cache2.getChildrenNames("/org/jboss/test/data");
  +      assertEquals("All children transferred", 4, children.size());
  +      
  +      // Sleep 10.1 secs to let the eviction thread run at least twice,
  +      // which will evict all 4 nodes due to their ttl of 4 secs
  +      TestingUtil.sleepThread(10500);
  +      
  +      children = cache2.getChildrenNames("/org/jboss/test/data");
  +      if (children != null)
  +         assertEquals("All children evicted", 0, children.size());
  +   }
  +   
      private Object createBen(ClassLoader loader) throws Exception
      {
         Class addrClazz = loader.loadClass("org.jboss.cache.marshall.Address");
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 18:14:06 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 18:14:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxX70-0000r8-NY@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 18:14:06

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        TreeCache.java
  Log:
  [JBCACHE-913] Handle TreeCacheListener notifications as before to reduce chance of introducing subtle regressions
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.195.2.40 +1 -4      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.195.2.39
  retrieving revision 1.195.2.40
  diff -u -b -r1.195.2.39 -r1.195.2.40
  --- TreeCache.java	21 Dec 2006 21:21:05 -0000	1.195.2.39
  +++ TreeCache.java	21 Dec 2006 23:14:06 -0000	1.195.2.40
  @@ -100,7 +100,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.195.2.39 2006/12/21 21:21:05 bstansberry Exp $
  + * @version $Id: TreeCache.java,v 1.195.2.40 2006/12/21 23:14:06 bstansberry Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -2753,7 +2753,6 @@
            try
            {
               integrator.integrateTransientState(targetRoot, cl);
  -            // JBCACHE-913 -- the integrator now makes this call
               notifyAllNodesCreated(targetRoot);
            }
            catch (Throwable t)
  @@ -6073,8 +6072,6 @@
      /**
       * Generates NodeAdded notifications for all nodes of the tree. This is
       * called whenever the tree is initially retrieved (state transfer)
  -    * 
  -    * @deprecated No longer called
       */
      protected void notifyAllNodesCreated(DataNode curr)
      {
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 18:14:36 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 18:14:36 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction  ...
Message-ID: <E1GxX7U-0000rP-AA@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 18:14:36

  Modified:    src/org/jboss/cache/eviction  Tag: Branch_JBossCache_1_4_0
                        RegionManager.java
  Log:
  Make the DEFAULT_REGION Fqn public
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.16.2.2  +2 -2      JBossCache/src/org/jboss/cache/eviction/Attic/RegionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/Attic/RegionManager.java,v
  retrieving revision 1.16.2.1
  retrieving revision 1.16.2.2
  diff -u -b -r1.16.2.1 -r1.16.2.2
  --- RegionManager.java	8 Aug 2006 15:50:49 -0000	1.16.2.1
  +++ RegionManager.java	21 Dec 2006 23:14:36 -0000	1.16.2.2
  @@ -34,7 +34,7 @@
    *
    * @author Ben Wang 02-2004
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: RegionManager.java,v 1.16.2.1 2006/08/08 15:50:49 msurtani Exp $
  + * @version $Id: RegionManager.java,v 1.16.2.2 2006/12/21 23:14:36 bstansberry Exp $
    */
   public class RegionManager
   {
  @@ -45,7 +45,7 @@
      public final static int CAPACITY = 200000;
   
      // There is global cache wide default values if no region is found.
  -   final static Fqn DEFAULT_REGION = new Fqn("_default_");
  +   public final static Fqn DEFAULT_REGION = new Fqn("_default_");
      private static final Log log_ = LogFactory.getLog(RegionManager.class);
   
      private final Map regionMap_ = Collections.synchronizedMap(new HashMap());
  
  
  


From brian.stansberry at jboss.com  Thu Dec 21 18:16:12 2006
From: brian.stansberry at jboss.com (Brian Stansberry)
Date: Thu, 21 Dec 2006 18:16:12 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer     ...
Message-ID: <E1GxX92-0000uK-Cf@committer01.frg.pub.inap.atl.jboss.com>

  User: bstansberry
  Date: 06/12/21 18:16:12

  Modified:    src/org/jboss/cache/statetransfer     Tag:
                        Branch_JBossCache_1_4_0
                        StateTransferIntegrator_123.java
                        StateTransferIntegrator_124.java
                        StateTransferIntegrator_140.java
                        StateTransferIntegrator_1241.java
  Log:
  [JBCACHE-913] Handle TreeCacheListener notifications as before to reduce chance of introducing subtle regressions
  Don't fail if there is no region defined
  Add the logic to all the STI impls
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.2.4.1   +58 -1     JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_123.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrator_123.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_123.java,v
  retrieving revision 1.2
  retrieving revision 1.2.4.1
  diff -u -b -r1.2 -r1.2.4.1
  --- StateTransferIntegrator_123.java	21 Feb 2006 01:12:50 -0000	1.2
  +++ StateTransferIntegrator_123.java	21 Dec 2006 23:16:12 -0000	1.2.4.1
  @@ -16,6 +16,9 @@
   import org.jboss.cache.Node;
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.TreeNode;
  +import org.jboss.cache.eviction.EvictedEventNode;
  +import org.jboss.cache.eviction.Region;
  +import org.jboss.cache.eviction.RegionManager;
   import org.jboss.cache.loader.CacheLoader;
   import org.jgroups.util.Util;
   
  @@ -79,11 +82,32 @@
                  for (Iterator iter = children.entrySet().iterator(); iter.hasNext();)
                  {
                     Map.Entry entry = (Map.Entry) iter.next();
  -                  target.addChild(entry.getKey(), (TreeNode) entry.getValue());
  +                  TreeNode child = (TreeNode) entry.getValue();
  +                  target.addChild(entry.getKey(), child);
                  }
               }
               
               target.setRecursiveTreeCacheInstance(cache);  // need to set this at root and set it recursively
  +            
  +            if (children != null)
  +            {
  +               RegionManager erm = cache.getEvictionRegionManager();
  +               if (erm != null)
  +               {
  +                  Region[] regions = erm.getRegions();
  +                  if (regions == null || regions.length == 0)
  +                     erm = null;
  +               }
  +               
  +               if (erm != null)
  +               {
  +                  for (Iterator iter = children.values().iterator(); iter.hasNext();)
  +                  {
  +                     sendEvictionNotifications((TreeNode) iter.next(), erm);
  +                  }
  +               }
  +            }
  +               
               log.info("setting the transient state was successful");
            }
            catch(Throwable t) 
  @@ -117,7 +141,40 @@
               }
            }
         }
  +   }
  +   
  +   private void sendEvictionNotifications(TreeNode node, RegionManager erm)
  +   {
  +      Fqn fqn = node.getFqn();      
   
  +      Region region = null;
  +      try
  +      {
  +         region = erm.getRegion(fqn);
  +      }
  +      catch (RuntimeException e)
  +      {
  +         if (erm.hasRegion(RegionManager.DEFAULT_REGION))
  +            throw e;
  +         // else the fqn is not associated with an eviction region
  +      }
  +      
  +      if (region != null)
  +      {
  +         Map attrs = node.getData();
  +         region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT, 
  +                                                  attrs == null ? 0 : attrs.size()));
  +      }
  +      
  +      // Walk the tree
  +      Map children = node.getChildren();
  +      if (children != null)
  +      {
  +         for (Iterator iter = children.values().iterator(); iter.hasNext();)
  +         {
  +            sendEvictionNotifications((TreeNode) iter.next(), erm);
  +         }
  +      }
      }
   
   }
  
  
  
  1.6.2.1   +39 -4     JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_124.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrator_124.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_124.java,v
  retrieving revision 1.6
  retrieving revision 1.6.2.1
  diff -u -b -r1.6 -r1.6.2.1
  --- StateTransferIntegrator_124.java	9 Apr 2006 12:33:49 -0000	1.6
  +++ StateTransferIntegrator_124.java	21 Dec 2006 23:16:12 -0000	1.6.2.1
  @@ -20,6 +20,9 @@
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.aop.InternalDelegate;
   import org.jboss.cache.aop.PojoCache;
  +import org.jboss.cache.eviction.EvictedEventNode;
  +import org.jboss.cache.eviction.Region;
  +import org.jboss.cache.eviction.RegionManager;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.loader.ExtendedCacheLoader;
  @@ -191,13 +194,21 @@
         else
            target.clear();
         
  -      integrateStateTransferChildren(target, in);
  +      RegionManager erm = cache.getEvictionRegionManager();
  +      if (erm != null)
  +      {
  +         Region[] regions = erm.getRegions();
  +         if (regions == null || regions.length == 0)
  +            erm = null;
  +      }
  +      integrateStateTransferChildren(target, in, erm);
         
         in.close();      
      }
      
      private NodeData integrateStateTransferChildren(DataNode parent, 
  -                                                   ObjectInputStream in)
  +                                                   ObjectInputStream in,
  +                                                   RegionManager erm)
            throws IOException, ClassNotFoundException
      {
         int parent_level = parent.getFqn().size();
  @@ -220,20 +231,44 @@
   
               name = fqn.get(size - 1);
               
  +            Map attrs = nd.getAttributes();
  +            
               // We handle this NodeData.  Create a DataNode and
               // integrate its data            
               DataNode target = factory.createDataNode(nodeType, 
                                                        name, 
                                                        fqn, 
                                                        parent, 
  -                                                     nd.getAttributes(), 
  +                                                     attrs, 
                                                        true,
                                                        cache);
               parent.addChild(name, target);
               
  +            // Make sure any eviction policy is aware of this node
  +            if (erm != null)
  +            {
  +               Region region = null;
  +               try
  +               {
  +                  region = erm.getRegion(fqn);
  +               }
  +               catch (RuntimeException e)
  +               {
  +                  if (erm.hasRegion(RegionManager.DEFAULT_REGION))
  +                     throw e;
  +                  // else the fqn is not associated with an eviction region
  +               }
  +               
  +               if (region != null)
  +               {
  +                  region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT, 
  +                                                           attrs == null ? 0 : attrs.size()));
  +               }
  +            }
  +            
               // Recursively call, which will walk down the tree
               // and return the next NodeData that's a child of our parent
  -            nd = integrateStateTransferChildren(target, in);
  +            nd = integrateStateTransferChildren(target, in, erm);
            }
         }
         catch (EOFException eof) {
  
  
  
  1.6.2.2   +25 -10    JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_140.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrator_140.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_140.java,v
  retrieving revision 1.6.2.1
  retrieving revision 1.6.2.2
  diff -u -b -r1.6.2.1 -r1.6.2.2
  --- StateTransferIntegrator_140.java	21 Dec 2006 21:21:05 -0000	1.6.2.1
  +++ StateTransferIntegrator_140.java	21 Dec 2006 23:16:12 -0000	1.6.2.2
  @@ -222,7 +222,14 @@
         // If it is an integration, calculate how many levels of offset
         int offset = move ? tgtFqn.size() - tferFqn.size() : 0;
         
  -      integrateStateTransferChildren(target, offset, in);
  +      RegionManager erm = cache.getEvictionRegionManager();
  +      if (erm != null)
  +      {
  +         Region[] regions = erm.getRegions();
  +         if (regions == null || regions.length == 0)
  +            erm = null;
  +      }
  +      integrateStateTransferChildren(target, offset, in, erm);
         
         in.close();
         
  @@ -231,7 +238,8 @@
      
      private NodeData integrateStateTransferChildren(DataNode parent,
                                                      int offset,
  -                                                   ObjectInputStream in)
  +                                                   ObjectInputStream in, 
  +                                                   RegionManager erm)
            throws IOException, ClassNotFoundException
      {
         int parent_level = parent.getFqn().size();
  @@ -271,14 +279,21 @@
                                                        cache);
               parent.addChild(name, target);
               
  -            // Send out the TreeCacheListener notification
  -            cache.notifyNodeCreated(fqn);
  -            
               // Make sure any eviction policy is aware of this node
  -            RegionManager rm = cache.getEvictionRegionManager();
  -            if (rm != null)
  +            if (erm != null)
  +            {
  +               Region region = null;
  +               try
               {               
  -               Region region = rm.getRegion(fqn);
  +                  region = erm.getRegion(fqn);
  +               }
  +               catch (RuntimeException e)
  +               {
  +                  if (erm.hasRegion(RegionManager.DEFAULT_REGION))
  +                     throw e;
  +                  // else the fqn is not associated with an eviction region
  +               }
  +               
                  if (region != null)
                  {
                     region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT, 
  @@ -288,7 +303,7 @@
               
               // Recursively call, which will walk down the tree
               // and return the next NodeData that's a child of our parent
  -            nd = integrateStateTransferChildren(target, offset, in);
  +            nd = integrateStateTransferChildren(target, offset, in, erm);
            }
         }
         catch (EOFException eof) {
  
  
  
  1.4.2.1   +39 -4     JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_1241.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferIntegrator_1241.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/Attic/StateTransferIntegrator_1241.java,v
  retrieving revision 1.4
  retrieving revision 1.4.2.1
  diff -u -b -r1.4 -r1.4.2.1
  --- StateTransferIntegrator_1241.java	22 Apr 2006 00:34:27 -0000	1.4
  +++ StateTransferIntegrator_1241.java	21 Dec 2006 23:16:12 -0000	1.4.2.1
  @@ -20,6 +20,9 @@
   import org.jboss.cache.TreeCache;
   import org.jboss.cache.aop.InternalDelegate;
   import org.jboss.cache.aop.PojoCache;
  +import org.jboss.cache.eviction.EvictedEventNode;
  +import org.jboss.cache.eviction.Region;
  +import org.jboss.cache.eviction.RegionManager;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.loader.ExtendedCacheLoader;
  @@ -203,13 +206,21 @@
         else
            target.clear();
         
  -      integrateStateTransferChildren(target, in);
  +      RegionManager erm = cache.getEvictionRegionManager();
  +      if (erm != null)
  +      {
  +         Region[] regions = erm.getRegions();
  +         if (regions == null || regions.length == 0)
  +            erm = null;
  +      }
  +      integrateStateTransferChildren(target, in, erm);
         
         in.close();      
      }
      
      private NodeData integrateStateTransferChildren(DataNode parent, 
  -                                                   ObjectInputStream in)
  +                                                   ObjectInputStream in,
  +                                                   RegionManager erm)
            throws IOException, ClassNotFoundException
      {
         int parent_level = parent.getFqn().size();
  @@ -232,20 +243,44 @@
   
               name = fqn.get(size - 1);
               
  +            Map attrs = nd.getAttributes();
  +            
               // We handle this NodeData.  Create a DataNode and
               // integrate its data            
               DataNode target = factory.createDataNode(nodeType, 
                                                        name, 
                                                        fqn, 
                                                        parent, 
  -                                                     nd.getAttributes(), 
  +                                                     attrs, 
                                                        true,
                                                        cache);
               parent.addChild(name, target);
               
  +            // Make sure any eviction policy is aware of this node
  +            if (erm != null)
  +            {
  +               Region region = null;
  +               try
  +               {
  +                  region = erm.getRegion(fqn);
  +               }
  +               catch (RuntimeException e)
  +               {
  +                  if (erm.hasRegion(RegionManager.DEFAULT_REGION))
  +                     throw e;
  +                  // else the fqn is not associated with an eviction region
  +               }
  +               
  +               if (region != null)
  +               {
  +                  region.putNodeEvent(new EvictedEventNode(fqn, EvictedEventNode.ADD_NODE_EVENT, 
  +                                                           attrs == null ? 0 : attrs.size()));
  +               }
  +            }
  +            
               // Recursively call, which will walk down the tree
               // and return the next NodeData that's a child of our parent
  -            nd = integrateStateTransferChildren(target, in);
  +            nd = integrateStateTransferChildren(target, in, erm);
            }
         }
         catch (EOFException eof) {
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 18:42:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 18:42:29 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1843 - in trunk: .
 docs/examples/common/src/org/jboss/example/jms/common
 docs/examples/common/src/org/jboss/example/jms/common/bean
 docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic
 docs/examples/ejb3mdb
 docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb
 docs/examples/http/src/org/jboss/example/jms/http
 docs/examples/mdb/src/org/jboss/example/jms/mdb
 docs/examples/queue/src/org/jboss/example/jms/queue
 docs/examples/queue-failover/src/org/jboss/example/jms/failover
 docs/examples/secure-socket/src/org/jboss/example/jms/securesocket
 docs/examples/stateless/src/org/jboss/example/jms/stateless/bean
 docs/examples/stateless/src/org/jboss/example/jms/stateless/client
 docs/examples/topic/src/org/jboss/example/jms/topic lib lib/jbossts
 src/etc/server/default/deploy src/main/org/jboss/jms
 src/main/org/jboss/jms/client/container
 src/main/org/jboss/jms/client/remoting src/main/org/jboss/jms/client/state
 src/main/org/jboss/jms/! recovery src/main/org/jboss/jms/server
 src/main/org/jboss/jms/server/endpoint src/main/org/jboss/jms/tx
 src/main/org/jboss/messaging/core src/main/org/jboss/messaging/core/memory
 src/main/org/jboss/messaging/core/plugin
 src/main/org/jboss/messaging/core/plugin/contract
 src/main/org/jboss/messaging/core/plugin/postoffice
 src/main/org/jboss/messaging/core/plugin/postoffice/cluster
 src/main/org/jboss/messaging/core/tx tests tests/smoke
 tests/src/org/jboss/test/messaging tests/src/org/jboss/test/messaging/core
 tests/src/org/jboss/test/messaging/core/local/base
 tests/src/org/jboss/test/messaging/core/paging
 tests/src/org/jboss/test/messaging/core/paging/base
 tests/src/org/jboss/test/messaging/core/plugin
 tests/src/org/jboss/test/messaging/core/plugin/base
 tests/src/org/jboss/test/messaging/core/plugin/postoffice
 tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
 tests/src/org/jboss/test/messaging/jms
 tests/src/org/jboss/test/messaging/jms/clustering tests/src/org/!
 jboss/test/messaging/jms/message
 tests/src/org/jboss/test/messaging/jms/stress
 tests/src/org/jboss/test/messaging/util util
Message-ID: <E1GxXYT-0001M8-UM@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-21 18:41:19 -0500 (Thu, 21 Dec 2006)
New Revision: 1843

Added:
   trunk/lib/jbossts/
   trunk/lib/jbossts/jboss-service.xml
   trunk/lib/jbossts/jbossjta-properties.xml
   trunk/src/main/org/jboss/jms/recovery/
   trunk/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java
   trunk/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java
   trunk/src/main/org/jboss/messaging/core/tx/PreparedTxInfo.java
   trunk/tests/src/org/jboss/test/messaging/jms/stress/ConcurrentCloseStressTest.java
   trunk/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java
Removed:
   trunk/lib/jbossts/jboss-service.xml
   trunk/lib/jbossts/jbossjta-properties.xml
   trunk/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java
   trunk/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java
   trunk/src/main/org/jboss/jms/tx/JMSRecoverable.java
Modified:
   trunk/.classpath
   trunk/build-messaging.xml
   trunk/build-thirdparty.xml
   trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java
   trunk/docs/examples/common/src/org/jboss/example/jms/common/Util.java
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java
   trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java
   trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java
   trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/ExampleListener.java
   trunk/docs/examples/ejb3mdb/do-not-distribute.properties
   trunk/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java
   trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java
   trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java
   trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/Sender.java
   trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
   trunk/docs/examples/queue/src/org/jboss/example/jms/queue/QueueExample.java
   trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleHome.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java
   trunk/docs/examples/topic/src/org/jboss/example/jms/topic/ExampleListener.java
   trunk/docs/examples/topic/src/org/jboss/example/jms/topic/TopicExample.java
   trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
   trunk/src/etc/server/default/deploy/mysql-persistence-service.xml
   trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
   trunk/src/main/org/jboss/jms/tx/MessagingXAResource.java
   trunk/src/main/org/jboss/jms/tx/ResourceManager.java
   trunk/src/main/org/jboss/jms/tx/TransactionRequest.java
   trunk/src/main/org/jboss/messaging/core/Channel.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/memory/SimpleMemoryManager.java
   trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
   trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   trunk/src/main/org/jboss/messaging/core/tx/Transaction.java
   trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   trunk/src/main/org/jboss/messaging/core/tx/XidImpl.java
   trunk/tests/build.xml
   trunk/tests/smoke/build.xml
   trunk/tests/src/org/jboss/test/messaging/MessagingTestCase.java
   trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
   trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
   trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/XATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java
   trunk/util/do-not-distribute.properties
   trunk/util/release-admin.xml
Log:
Merged XARecovery functionality into TRUNK, and reformatted examples



Modified: trunk/.classpath
===================================================================
--- trunk/.classpath	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/.classpath	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,6 +1,16 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <classpath>
 	<classpathentry kind="src" path="output/gen-parsers"/>
+	<classpathentry kind="src" path="docs/examples/queue-failover/src"/>
+	<classpathentry kind="src" path="docs/examples/common/src"/>
+	<classpathentry kind="src" path="docs/examples/distributed-topic/src"/>
+	<classpathentry kind="src" path="docs/examples/ejb3mdb/src"/>
+	<classpathentry kind="src" path="docs/examples/http/src"/>
+	<classpathentry kind="src" path="docs/examples/mdb/src"/>
+	<classpathentry kind="src" path="docs/examples/queue/src"/>
+	<classpathentry kind="src" path="docs/examples/secure-socket/src"/>
+	<classpathentry kind="src" path="docs/examples/stateless/src"/>
+	<classpathentry kind="src" path="docs/examples/topic/src"/>
 	<classpathentry excluding="**/.svn/**/*" kind="src" path="src/main"/>
 	<classpathentry excluding="**/.svn/**/*" kind="src" path="tests/src"/>
 	<classpathentry kind="lib" path="lib/jboss.jar"/>
@@ -50,5 +60,7 @@
 	<classpathentry kind="lib" path="thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/jbossts/lib/jbossjta.jar"/>
+	<classpathentry kind="var" path="ANT_HOME/lib/ant.jar"/>
 	<classpathentry kind="output" path="bin"/>
 </classpath>

Modified: trunk/build-messaging.xml
===================================================================
--- trunk/build-messaging.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/build-messaging.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -139,6 +139,7 @@
       <path refid="javassist.classpath"/>
       <path refid="jgroups.jgroups.classpath"/>
       <path refid="trove.trove.classpath"/>
+      <path refid="apache.logging.classpath"/>
    </path>
 
    <!--
@@ -155,6 +156,7 @@
       <path refid="jboss.aop.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
+      <path refid="jboss.jbossts.classpath"/>
    </path>
 
    <!--
@@ -193,6 +195,13 @@
       <pathelement location="${project.root}/lib/jboss-jmx.jar"/>
    </path>
 
+   <!--
+       This is for compiling the JBossAS JBossTS driven JMS recovery code which uses XAResourceWrapper implementation
+   -->
+   <path id="jboss.classpath">
+      <pathelement location="${project.root}/lib/jboss.jar"/>
+   </path>
+
    <property name="jboss.server.lib" value="${project.root}/lib/"/>
 
    <property name="jboss.naming.lib" value="${project.root}/lib/"/>
@@ -206,6 +215,7 @@
       <path refid="jboss.jmx.classpath"/>
       <path refid="jboss.remoting.classpath"/>
       <path refid="jboss.serialization.classpath"/>
+      <path refid="jboss.classpath"/>
    </path>
 
    <!--
@@ -400,13 +410,20 @@
 
       <mkdir dir="${build.lib}"/>
       <jar jarfile="${build.lib}/jboss-${module.name}.jar" manifest="${build.etc}/default.mf">
-         <fileset dir="${build.classes}" includes="**"/>
+         <fileset dir="${build.classes}" includes="**" excludes="org/jboss/jms/recovery/*.class"/>
          <fileset dir="${build.jar}">
             <exclude name="*-service.xml"/>
             <exclude name="*-ds.xml"/>
             <exclude name="messaging-*.properties"/>
          </fileset>
       </jar>
+
+      <!-- JBossTS integration layer for XA recovery -->
+
+      <jar jarfile="${build.lib}/jboss-${module.name}-integration.jar" manifest="${build.etc}/default.mf">
+         <fileset dir="${build.classes}" includes="org/jboss/jms/recovery/*.class"/>
+      </jar>
+
    </target>
 
    <target name="scoped-sar" depends="compile, jar, scoped-sar-structure, extract-server-dependencies">
@@ -491,6 +508,7 @@
            I also need org.jboss.util.stream.*
       -->
       <unjar dest="${build.scoped-sar}/tmp" src="${jboss.common.core.lib}/jboss-common-core.jar">
+
          <patternset>
             <include name="org/jboss/util/stream/**"/>
          </patternset>

Modified: trunk/build-thirdparty.xml
===================================================================
--- trunk/build-thirdparty.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/build-thirdparty.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -93,6 +93,7 @@
       <componentref name="jboss/aop" version="1.5.0.GA"/>
       <componentref name="jboss/serialization" version="1.0.3.GA"/>
       <componentref name="jboss/remoting" version="2.2.0.Alpha4"/>
+      <componentref name="jboss/jbossts" version="4.2.2.GA"/>
 
       <!-- Need this otherwise project doesn't build in Eclipse -->
       <componentref name="apache-logging" version="1.0.4.1jboss"/>

Modified: trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/ExampleSupport.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,16 +6,16 @@
  */
 package org.jboss.example.jms.common;
 
+import javax.jms.Connection;
+import javax.jms.ConnectionMetaData;
+import javax.naming.InitialContext;
+
+import org.jboss.example.jms.common.bean.Management;
+import org.jboss.example.jms.common.bean.ManagementHome;
 import org.jboss.jms.client.JBossConnection;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.example.jms.common.bean.ManagementHome;
-import org.jboss.example.jms.common.bean.Management;
 
-import javax.jms.ConnectionMetaData;
-import javax.jms.Connection;
-import javax.naming.InitialContext;
-
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
@@ -23,74 +23,74 @@
  * $Id$
  */
 public abstract class ExampleSupport
- {
+{
    // Constants -----------------------------------------------------
-
+   
    public static final String DEFAULT_QUEUE_NAME = "testQueue";
    public static final String DEFAULT_TOPIC_NAME = "testTopic";
-
+   
    // Static --------------------------------------------------------
-
+   
    public static int getServerID(Connection conn) throws Exception
    {
       if (!(conn instanceof JBossConnection))
       {
          throw new Exception("Connection not an instance of JBossConnection");
       }
-
+      
       JBossConnection jbconn = (JBossConnection)conn;
-
+      
       DelegateSupport del = (DelegateSupport)jbconn.getDelegate();
-
+      
       ConnectionState state = (ConnectionState)del.getState();
-
+      
       return state.getServerID();
    }
-
+   
    public static void assertEquals(Object o, Object o2)
    {
-       if (o == null && o2 == null)
-       {
-          return;
-       }
-
-       if (o.equals(o2))
-       {
-          return;
-       }
-
-       throw new RuntimeException("Assertion failed, " + o + " != " + o2);
+      if (o == null && o2 == null)
+      {
+         return;
+      }
+      
+      if (o.equals(o2))
+      {
+         return;
+      }
+      
+      throw new RuntimeException("Assertion failed, " + o + " != " + o2);
    }
-
+   
    public static void assertEquals(int i, int i2)
    {
-       if (i == i2)
-       {
-          return;
-       }
-
-       throw new RuntimeException("Assertion failed, " + i + " != " + i2);
+      if (i == i2)
+      {
+         return;
+      }
+      
+      throw new RuntimeException("Assertion failed, " + i + " != " + i2);
    }
-
+   
    public static void assertNotEquals(int i, int i2)
    {
-        if (i != i2)
-        {
-           return;
-        }
-
-        throw new RuntimeException("Assertion failed, " + i + " == " + i2);
+      if (i != i2)
+      {
+         return;
+      }
+      
+      throw new RuntimeException("Assertion failed, " + i + " == " + i2);
    }
-
-
+   
+   
    public static void killActiveNode() throws Exception
    {
       // Currently it will always kill the primary node, ignoring nodeID
-
+      
       try
       {
          InitialContext ic = new InitialContext();
-
+         
          ManagementHome home = (ManagementHome)ic.lookup("ejb/Management");
          Management bean = home.create();
          bean.killAS();
@@ -98,39 +98,37 @@
       catch(Exception e)
       {
          // OK, I expect exceptions following a VM kill
-
-         //e.printStackTrace();
       }
    }
-
-
+   
+   
    // Attributes ----------------------------------------------------
-
+   
    private boolean failure;
    private boolean deployed;
    private String jndiDestinationName;
-
+   
    // Constructors --------------------------------------------------
-
+   
    protected ExampleSupport()
    {
       failure = false;
    }
-
+   
    // Public --------------------------------------------------------
-
+   
    // Package protected ---------------------------------------------
-
+   
    // Protected -----------------------------------------------------
-
+   
    protected abstract void example() throws Exception;
    protected abstract boolean isQueueExample();
-
+   
    protected final boolean isTopicExample()
    {
       return !isQueueExample();
    }
-
+   
    protected void run()
    {
       try
@@ -144,52 +142,52 @@
          t.printStackTrace();
          setFailure(true);
       }
-
+      
       reportResultAndExit();
    }
-
+   
    protected void setFailure(boolean b)
    {
       failure = b;
    }
-
+   
    protected boolean isFailure()
    {
       return failure;
    }
-
+   
    protected String getDestinationJNDIName()
    {
       return jndiDestinationName;
    }
-
+   
    protected void log(String s)
    {
       System.out.println(s);
    }
-
+   
    protected void displayProviderInfo(ConnectionMetaData metaData) throws Exception
    {
       String info =
-            "The example connected to " + metaData.getJMSProviderName() +
-            " version " + metaData.getProviderVersion() + " (" +
-            metaData.getProviderMajorVersion() + "." + metaData.getProviderMinorVersion() +
-            ")";
-
-     System.out.println(info);
+         "The example connected to " + metaData.getJMSProviderName() +
+         " version " + metaData.getProviderVersion() + " (" +
+         metaData.getProviderMajorVersion() + "." + metaData.getProviderMinorVersion() +
+         ")";
+      
+      System.out.println(info);
    }
-
+   
    // Private -------------------------------------------------------
-
+   
    protected void setup() throws Exception
    {
-       setup(null);
+      setup(null);
    }
-
+   
    protected void setup(InitialContext ic) throws Exception
    {
       String destinationName;
-
+      
       if (isQueueExample())
       {
          destinationName = System.getProperty("example.queue.name");
@@ -202,7 +200,7 @@
          jndiDestinationName =
             "/topic/"  + (destinationName == null ? DEFAULT_TOPIC_NAME : destinationName);
       }
-
+      
       if (!Util.doesDestinationExist(jndiDestinationName,ic))
       {
          System.out.println("Destination " + jndiDestinationName + " does not exist, deploying it");
@@ -210,12 +208,12 @@
          deployed = true;
       }
    }
-
+   
    protected void tearDown() throws Exception
    {
-       tearDown(null);
+      tearDown(null);
    }
-
+   
    protected void tearDown(InitialContext ic) throws Exception
    {
       if (deployed)
@@ -223,7 +221,7 @@
          Util.undeployQueue(jndiDestinationName,ic);
       }
    }
-
+   
    protected void reportResultAndExit()
    {
       if (isFailure())
@@ -234,14 +232,14 @@
          System.err.println("#####################");
          System.exit(1);
       }
-
+      
       System.out.println();
       System.out.println("#####################");
       System.out.println("###    SUCCESS!   ###");
       System.out.println("#####################");
       System.exit(0);
    }
-
+   
    // Inner classes -------------------------------------------------
-
+   
 }

Modified: trunk/docs/examples/common/src/org/jboss/example/jms/common/Util.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/Util.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/Util.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,10 +21,10 @@
 */
 package org.jboss.example.jms.common;
 
+import javax.management.MBeanServerConnection;
+import javax.management.ObjectName;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
-import javax.management.MBeanServerConnection;
-import javax.management.ObjectName;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>

Modified: trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/Management.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,9 +6,10 @@
  */
 package org.jboss.example.jms.common.bean;
 
-import javax.ejb.EJBObject;
 import java.rmi.RemoteException;
 
+import javax.ejb.EJBObject;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 1766 $</tt>

Modified: trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementBean.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,23 +6,11 @@
  */
 package org.jboss.example.jms.common.bean;
 
+import java.rmi.RemoteException;
+
+import javax.ejb.EJBException;
 import javax.ejb.SessionBean;
 import javax.ejb.SessionContext;
-import javax.ejb.EJBException;
-import javax.jms.ConnectionFactory;
-import javax.jms.Queue;
-import javax.jms.Session;
-import javax.jms.Connection;
-import javax.jms.MessageConsumer;
-import javax.jms.Message;
-import javax.jms.MessageProducer;
-import javax.jms.TextMessage;
-import javax.jms.QueueBrowser;
-import javax.jms.JMSException;
-import javax.naming.InitialContext;
-import java.util.ArrayList;
-import java.util.Enumeration;
-import java.rmi.RemoteException;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -32,8 +20,6 @@
  */
 public class ManagementBean implements SessionBean
 {
-   private SessionContext ctx;
-
    public void killAS() throws Exception
    {
       System.out.println("######");
@@ -51,7 +37,6 @@
 
    public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
    {
-      this.ctx = ctx;
    }
 
    public void ejbCreate()

Modified: trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java
===================================================================
--- trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/common/src/org/jboss/example/jms/common/bean/ManagementHome.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,10 +6,11 @@
  */
 package org.jboss.example.jms.common.bean;
 
-import javax.ejb.EJBHome;
-import javax.ejb.CreateException;
 import java.rmi.RemoteException;
 
+import javax.ejb.CreateException;
+import javax.ejb.EJBHome;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision: 563 $</tt>

Modified: trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java
===================================================================
--- trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/DistributedTopicExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,20 +21,18 @@
 */
 package org.jboss.example.jms.distributedtopic;
 
-import javax.naming.InitialContext;
 import javax.jms.Connection;
 import javax.jms.ConnectionFactory;
-import javax.jms.Topic;
-import javax.jms.Session;
-import javax.jms.MessageProducer;
+import javax.jms.JMSException;
 import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
 import javax.jms.TextMessage;
-import javax.jms.JMSException;
+import javax.jms.Topic;
+import javax.naming.InitialContext;
 
 import org.jboss.example.jms.common.ExampleSupport;
 
-import java.util.Hashtable;
-
 /**
  * The example sends a message to a distributed topic depolyed on the JMS cluster. The message is
  * subsequently received by two different subscribers, connected to two distinct cluster nodes.
@@ -51,13 +49,10 @@
 {
    public void example() throws Exception
    {
-
       String destinationName = getDestinationJNDIName();
 
-
       InitialContext ic = null;
 
-
       Connection connection0 = null;
       Connection connection1 = null;
 
@@ -76,7 +71,6 @@
          // transparently creating physical connections to different cluster nodes, in a round
          // robin fashion ...
 
-
          // ... so this is a connection to a cluster node
          connection0 = cf.createConnection();
 
@@ -86,7 +80,6 @@
          // Let's make sure that (this example is also a smoke test)
          assertNotEquals(getServerID(connection0), getServerID(connection1));
 
-
          // Create a session, a producer and consumer for the distributed topic, using connection0
 
          Session session0 = connection0.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -95,11 +88,9 @@
          ExampleListener messageListener0 = new ExampleListener("MessageListener 0");
          subscriber0.setMessageListener(messageListener0);
 
-
          MessageProducer publisher = session0.createProducer(distributedTopic);
 
 
-
          // Create a session and a consumer for the distributed topic, using connection1
 
          Session session1 = connection1.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -137,7 +128,7 @@
       }
       finally
       {
-         if(ic != null)
+         if (ic != null)
          {
             try
             {

Modified: trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/ExampleListener.java
===================================================================
--- trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/ExampleListener.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/distributed-topic/src/org/jboss/example/jms/distributedtopic/ExampleListener.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,8 +6,8 @@
  */
 package org.jboss.example.jms.distributedtopic;
 
+import javax.jms.Message;
 import javax.jms.MessageListener;
-import javax.jms.Message;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>

Modified: trunk/docs/examples/ejb3mdb/do-not-distribute.properties
===================================================================
--- trunk/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-21 23:41:19 UTC (rev 1843)
@@ -4,5 +4,6 @@
 #
 messaging.client.jar.path=../../../output/lib
 messaging.client.jar.name=jboss-messaging-client.jar
-jboss.configuration=messaging-smoke-test
+jboss.configuration=messaging
 jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
+jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3

Modified: trunk/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java
===================================================================
--- trunk/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/ejb3mdb/src/org/jboss/example/jms/ejb3mdb/EJB3MDBExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -30,7 +30,8 @@
 @MessageDriven(activationConfig =
 {
       @ActivationConfigProperty(propertyName="destinationType", propertyValue="javax.jms.Queue"),
-      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue")
+      @ActivationConfigProperty(propertyName="destination", propertyValue="queue/testQueue"),
+      @ActivationConfigProperty(propertyName="DLQMaxResent", propertyValue="10")
 })
 public class EJB3MDBExample implements MessageListener
 {
@@ -39,7 +40,6 @@
       businessLogic(m);
    }
 
-
    private void businessLogic(Message m)
    {
       Connection conn = null;

Modified: trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java
===================================================================
--- trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,24 +1,24 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.example.jms.http;
 
 import org.jboss.example.jms.common.ExampleSupport;
@@ -50,93 +50,90 @@
  */
 public class HttpExample extends ExampleSupport
 {
-
+   
    public void example() throws Exception
    {
       String destinationName = getDestinationJNDIName();
-
-       InitialContext ic = null;
-       ConnectionFactory cf = null;
-       Connection connection =  null;
-       Connection connection2 =  null;
-
-       try
-       {
-
-           ic = new InitialContext();
-
-           cf = (ConnectionFactory)ic.lookup("/HttpConnectionFactory");
-           Queue queue = (Queue)ic.lookup(destinationName);
-           log("Queue " + destinationName + " exists");
-
-           connection = cf.createConnection();
-           Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-           MessageProducer sender = session.createProducer(queue);
-
-           TextMessage message = session.createTextMessage("Hello!");
-           sender.send(message);
-           log("The message was successfully sent to the " + queue.getQueueName() + " queue");
-
-           connection2 = cf.createConnection();
-           Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-           MessageConsumer consumer = session2.createConsumer(queue);
-
-           connection2.start();
-
-           message = (TextMessage)consumer.receive(2000);
-           log("Received message: " + message.getText());
-           assertEquals("Hello!", message.getText());
-
-           displayProviderInfo(connection2.getMetaData());
-
-       }
-       finally
-       {
-           if(ic != null)
-           {
-               try
-               {
-                   ic.close();
-               }
-               catch(Exception e)
-               {
-                   throw e;
-               }
-           }
-
-           //ALWAYS close your connection in a finally block to avoid leaks
-           //Closing connection also takes care of closing its related objects e.g. sessions
-           closeConnection(connection);
-           closeConnection(connection2);
-       }
+      
+      InitialContext ic = null;
+      ConnectionFactory cf = null;
+      Connection connection =  null;
+      Connection connection2 =  null;
+      
+      try
+      {
+         ic = new InitialContext();
+         
+         cf = (ConnectionFactory)ic.lookup("/HttpConnectionFactory");
+         Queue queue = (Queue)ic.lookup(destinationName);
+         log("Queue " + destinationName + " exists");
+         
+         connection = cf.createConnection();
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer sender = session.createProducer(queue);
+         
+         TextMessage message = session.createTextMessage("Hello!");
+         sender.send(message);
+         log("The message was successfully sent to the " + queue.getQueueName() + " queue");
+         
+         connection2 = cf.createConnection();
+         Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer consumer = session2.createConsumer(queue);
+         
+         connection2.start();
+         
+         message = (TextMessage)consumer.receive(2000);
+         log("Received message: " + message.getText());
+         assertEquals("Hello!", message.getText());
+         
+         displayProviderInfo(connection2.getMetaData());
+         
+      }
+      finally
+      {
+         if(ic != null)
+         {
+            try
+            {
+               ic.close();
+            }
+            catch(Exception e)
+            {
+               throw e;
+            }
+         }
+         
+         //ALWAYS close your connection in a finally block to avoid leaks
+         //Closing connection also takes care of closing its related objects e.g. sessions
+         closeConnection(connection);
+         closeConnection(connection2);
+      }
    }
-
+   
    private void closeConnection(Connection con) throws JMSException
    {
-       try
-       {
-		   if (con != null)
-		   {
-               con.close();
-	       }
-
-       }
-       catch(JMSException jmse)
-       {
-           log("Could not close connection " + con +" exception was " +jmse);
-           throw jmse;
-       }
+      try
+      {
+         if (con != null)
+         {
+            con.close();
+         }         
+      }
+      catch(JMSException jmse)
+      {
+         log("Could not close connection " + con +" exception was " +jmse);         
+      }
    }
-
-
+   
+   
    protected boolean isQueueExample()
    {
       return true;
    }
-
+   
    public static void main(String[] args)
    {
       new HttpExample().run();
    }
-
+   
 }

Modified: trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java
===================================================================
--- trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,49 +6,56 @@
  */
 package org.jboss.example.jms.mdb;
 
-import javax.jms.*;
+import javax.ejb.EJBException;
 import javax.ejb.MessageDrivenBean;
 import javax.ejb.MessageDrivenContext;
-import javax.ejb.EJBException;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.Destination;
+import javax.jms.JMSException;
+import javax.jms.Message;
+import javax.jms.MessageListener;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
 import javax.naming.InitialContext;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
-
+ 
  * $Id$
  */
 public class MDBExample implements MessageDrivenBean, MessageListener
 {
-
    private MessageDrivenContext ctx;
-
+   
    private ConnectionFactory cf = null;
-
+   
    public void onMessage(Message m)
    {
       Session session = null;
       Connection conn = null;
-
+      
       try
       {
          TextMessage tm = (TextMessage)m;
-
+         
          String text = tm.getText();
          System.out.println("message " + text + " received");
          String result = process(text);
          System.out.println("message processed, result: " + result);
-
+         
          conn = getConnection();
          session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
+         
          Destination replyTo = m.getJMSReplyTo();
          MessageProducer producer = session.createProducer(replyTo);
          TextMessage reply = session.createTextMessage(result);
-
+         
          producer.send(reply);
          producer.close();
-
+         
       }
       catch(Exception e)
       {
@@ -60,91 +67,101 @@
       {
          if (conn != null)
          {
-            try {
-                closeConnection(conn);
-            }catch(Exception e){
-                System.out.println("Could not close the connection!" +e);
+            try
+            {
+               closeConnection(conn);
             }
+            catch(Exception e)
+            {
+               System.out.println("Could not close the connection!" +e);
+            }
          }
       }
    }
-
+   
    private String process(String text)
    {
       // flip the string
-
+      
       String result = "";
-
+      
       for(int i = 0; i < text.length(); i++)
       {
          result = text.charAt(i) + result;
       }
       return result;
    }
-
-   public Connection getConnection() throws Exception {
-
-        Connection connection = null;
-
-        try {
-            connection = cf.createConnection();
-            connection.start();
-
-        }catch(Exception e ){
-           if(connection != null)
-               closeConnection(connection);
-           System.out.println("Failed to get connection...exception is " +e);
-           throw e;
-        }
-
-        return connection;
-    }
-
-    public void closeConnection(Connection con) throws Exception {
-
-       try {
-           con.close();
-
-       }catch(JMSException jmse) {
-           System.out.println("Could not close connection " + con +" exception was " +jmse);
-           throw jmse;
-       }
-    }
-
-    public void ejbCreate()
-    {
-       try
-       {
-          InitialContext ic = new InitialContext();
-
-          cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
-
-          ic.close();
-       }
-       catch(Exception e)
-       {
-          e.printStackTrace();
-          throw new EJBException("Failure to get connection factory: " + e.getMessage());
-       }
-    }
-
-    public void ejbRemove() throws EJBException
-    {
-       try
-       {
-          if(cf != null)
-              cf = null;
-       }
-       catch(Exception e)
-       {
-          throw new EJBException("ejbRemove", e);
-       }
-    }
-
-    public void setMessageDrivenContext(MessageDrivenContext ctx)
-    {
-       this.ctx = ctx;
-    }
-
-
+   
+   public Connection getConnection() throws Exception
+   {      
+      Connection connection = null;
+      
+      try
+      {
+         connection = cf.createConnection();
+         connection.start();        
+      }
+      catch(Exception e )
+      {
+         if(connection != null)
+         {
+            closeConnection(connection);
+         }
+         System.out.println("Failed to get connection...exception is " + e);
+         throw e;
+      }
+      
+      return connection;
+   }
+   
+   public void closeConnection(Connection con) throws Exception
+   {      
+      try
+      {
+         con.close();         
+      }
+      catch(JMSException jmse)
+      {
+         System.out.println("Could not close connection " + con + " exception was " + jmse);
+      }
+   }
+   
+   public void ejbCreate()
+   {
+      try
+      {
+         InitialContext ic = new InitialContext();
+         
+         cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
+         
+         ic.close();
+      }
+      catch(Exception e)
+      {
+         e.printStackTrace();
+         throw new EJBException("Failure to get connection factory: " + e.getMessage());
+      }
+   }
+   
+   public void ejbRemove() throws EJBException
+   {
+      try
+      {
+         if(cf != null)
+         {
+            cf = null;
+         }
+      }
+      catch(Exception e)
+      {
+         throw new EJBException("ejbRemove", e);
+      }
+   }
+   
+   public void setMessageDrivenContext(MessageDrivenContext ctx)
+   {
+      this.ctx = ctx;
+   }
+   
+   
 }

Modified: trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/Sender.java
===================================================================
--- trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/Sender.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/Sender.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,37 +1,37 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.example.jms.mdb;
 
-import org.jboss.example.jms.common.ExampleSupport;
-
-import javax.naming.InitialContext;
-import javax.jms.ConnectionFactory;
 import javax.jms.Connection;
-import javax.jms.Session;
+import javax.jms.ConnectionFactory;
+import javax.jms.MessageConsumer;
 import javax.jms.MessageProducer;
-import javax.jms.TextMessage;
 import javax.jms.Queue;
-import javax.jms.MessageConsumer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.naming.InitialContext;
 
+import org.jboss.example.jms.common.ExampleSupport;
+
 /**
  * This example deploys a simple Message Driven Bean that processes messages sent to a test queue.
  * Once it receives a message and "processes" it, the MDB sends an acknowledgment message to a
@@ -51,84 +51,64 @@
    public void example() throws Exception
    {
       String destinationName = getDestinationJNDIName();
-
-
-
+                  
       InitialContext ic = new InitialContext();
-
-
+            
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
       Queue queue = (Queue)ic.lookup(destinationName);
-
-
-
-      log("Queue " + destinationName + " exists");
-
-
-
-      Connection connection = cf.createConnection();
-      Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageProducer sender = session.createProducer(queue);
-
-
-
-      Queue temporaryQueue = session.createTemporaryQueue();
-      MessageConsumer consumer = session.createConsumer(temporaryQueue);
-
-
-
-      TextMessage message = session.createTextMessage("Hello!");
-      message.setJMSReplyTo(temporaryQueue);
-
-
-
-      sender.send(message);
-
-
-
-      log("The " + message.getText() + " message was successfully sent to the " + queue.getQueueName() + " queue");
-
-
-
-      connection.start();
-
-
-
-      message = (TextMessage)consumer.receive(5000);
-
-
-      if (message == null)
+                 
+      log("Queue " + destinationName + " exists");            
+      
+      Connection connection = null;
+      
+      try
       {
-         throw new Exception("Have not received any reply. The example failed!");
+         connection = cf.createConnection();
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer sender = session.createProducer(queue);      
+               
+         Queue temporaryQueue = session.createTemporaryQueue();
+         MessageConsumer consumer = session.createConsumer(temporaryQueue);            
+         
+         TextMessage message = session.createTextMessage("Hello!");
+         message.setJMSReplyTo(temporaryQueue);            
+         
+         sender.send(message);
+                     
+         log("The " + message.getText() + " message was successfully sent to the " + queue.getQueueName() + " queue");
+   
+         connection.start();
+         
+         message = (TextMessage)consumer.receive(5000);
+              
+         if (message == null)
+         {
+            throw new Exception("Have not received any reply. The example failed!");
+         }
+               
+         log("Received message: " + message.getText());
+         
+         assertEquals("!olleH", message.getText());
+                     
+         displayProviderInfo(connection.getMetaData());
       }
-
-
-      log("Received message: " + message.getText());
-
-
-
-      assertEquals("!olleH", message.getText());
-
-
-
-      displayProviderInfo(connection.getMetaData());
-
-
-
-      connection.close();
+      finally
+      {
+         if (connection != null)
+         {
+            connection.close();
+         }
+      }
    }
-
-
-
-
+           
    protected boolean isQueueExample()
    {
       return true;
    }
-
+   
    public static void main(String[] args)
    {
       new Sender().run();
    }
-
+   
 }

Modified: trunk/docs/examples/queue/src/org/jboss/example/jms/queue/QueueExample.java
===================================================================
--- trunk/docs/examples/queue/src/org/jboss/example/jms/queue/QueueExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/queue/src/org/jboss/example/jms/queue/QueueExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,38 +1,37 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.example.jms.queue;
 
-import org.jboss.example.jms.common.ExampleSupport;
-
-import javax.naming.InitialContext;
-import javax.jms.TextMessage;
-import javax.jms.Session;
+import javax.jms.Connection;
 import javax.jms.ConnectionFactory;
+import javax.jms.JMSException;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
 import javax.jms.Queue;
-import javax.jms.MessageProducer;
-import javax.jms.Connection;
-import javax.jms.MessageConsumer;
-import javax.jms.JMSException;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.naming.InitialContext;
 
+import org.jboss.example.jms.common.ExampleSupport;
 
 /**
  * The example creates a connection to the default provider and uses the connection to send a
@@ -51,87 +50,91 @@
  */
 public class QueueExample extends ExampleSupport
 {
-
+   
    public void example() throws Exception
    {
       String destinationName = getDestinationJNDIName();
-
-       InitialContext ic = null;
-       ConnectionFactory cf = null;
-       Connection connection =  null;
-       Connection connection2 =  null;
-
-       try {
-
-           ic = new InitialContext();
-
-           cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
-           Queue queue = (Queue)ic.lookup(destinationName);
-           log("Queue " + destinationName + " exists");
-
-           connection = cf.createConnection();
-           Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-           MessageProducer sender = session.createProducer(queue);
-
-           TextMessage message = session.createTextMessage("Hello!");
-           sender.send(message);
-           log("The message was successfully sent to the " + queue.getQueueName() + " queue");
-
-           connection2 = cf.createConnection();
-           Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-           MessageConsumer consumer =  session2.createConsumer(queue);
-
-           connection2.start();
-
-           message = (TextMessage)consumer.receive(2000);
-           log("Received message: " + message.getText());
-           assertEquals("Hello!", message.getText());
-
-           displayProviderInfo(connection2.getMetaData());
-
-
-       }finally{
-
-           if(ic != null) {
-               try {
-                   ic.close();
-               }catch(Exception e){
-                   throw e;
-               }
-           }
-
-           //ALWAYS close your connection in a finally block to avoid leaks
-           //Closing connection also takes care of closing its related objects e.g. sessions
-           closeConnection(connection);
-
-           closeConnection(connection2);
-
-       }
-
+      
+      InitialContext ic = null;
+      ConnectionFactory cf = null;
+      Connection connection =  null;
+      Connection connection2 =  null;
+      
+      try
+      {         
+         ic = new InitialContext();
+         
+         cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+         Queue queue = (Queue)ic.lookup(destinationName);
+         log("Queue " + destinationName + " exists");
+         
+         connection = cf.createConnection();
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer sender = session.createProducer(queue);
+         
+         TextMessage message = session.createTextMessage("Hello!");
+         sender.send(message);
+         log("The message was successfully sent to the " + queue.getQueueName() + " queue");
+         
+         connection2 = cf.createConnection();
+         Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer consumer =  session2.createConsumer(queue);
+         
+         connection2.start();
+         
+         message = (TextMessage)consumer.receive(2000);
+         log("Received message: " + message.getText());
+         assertEquals("Hello!", message.getText());
+         
+         displayProviderInfo(connection2.getMetaData());
+                 
+      }
+      finally
+      {         
+         if(ic != null)
+         {
+            try
+            {
+               ic.close();
+            }
+            catch(Exception e)
+            {
+               throw e;
+            }
+         }
+         
+         //ALWAYS close your connection in a finally block to avoid leaks
+         //Closing connection also takes care of closing its related objects e.g. sessions
+         closeConnection(connection);
+         
+         closeConnection(connection2);
+         
+      }      
    }
-
-   private void closeConnection(Connection con) throws JMSException {
-
-       try {
-		   if (con != null) {
-           		con.close();
-	       }
-
-       }catch(JMSException jmse) {
-           log("Could not close connection " + con +" exception was " +jmse);
-           throw jmse;
-       }
+   
+   private void closeConnection(Connection con) throws JMSException
+   {      
+      try
+      {
+         if (con != null)
+         {
+            con.close();
+         }         
+      }
+      catch(JMSException jmse)
+      {
+         log("Could not close connection " + con +" exception was " + jmse);
+      }
    }
-
-
+      
    protected boolean isQueueExample()
    {
       return true;
    }
-
+   
    public static void main(String[] args)
    {
       new QueueExample().run();
    }
-
+   
 }

Modified: trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java
===================================================================
--- trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/queue-failover/src/org/jboss/example/jms/failover/QueueFailoverExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,15 +21,15 @@
 */
 package org.jboss.example.jms.failover;
 
-import javax.naming.InitialContext;
 import javax.jms.Connection;
 import javax.jms.ConnectionFactory;
-import javax.jms.Session;
-import javax.jms.MessageProducer;
-import javax.jms.MessageConsumer;
-import javax.jms.TextMessage;
 import javax.jms.JMSException;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
 import javax.jms.Queue;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.naming.InitialContext;
 
 import org.jboss.example.jms.common.ExampleSupport;
 
@@ -51,7 +51,6 @@
 {
    public void example() throws Exception
    {
-
       String destinationName = getDestinationJNDIName();
 
       InitialContext ic = null;
@@ -62,7 +61,6 @@
       {
          // Create a connection to the clustered messaging instance
 
-
          ic = new InitialContext();
 
          ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
@@ -70,7 +68,6 @@
          Queue distributedQueue = (Queue)ic.lookup(destinationName);
          log("Distributed queue " + destinationName + " exists");
 
-
          // When connecting to a messaging cluster, the ConnectionFactory has the capability of
          // transparently creating physical connections to different cluster nodes, in a round
          // robin fashion ...
@@ -105,14 +102,11 @@
 
          assertEquals("Hello1!", rm1.getText());
 
-
          // Kill the active node
          killActiveNode();
 
-
          Thread.sleep(30000); // TODO not necesare after we install the client valve
 
-
          // receive the second message on the failed over node
 
          TextMessage rm2 = (TextMessage)consumer.receive(2000);
@@ -122,11 +116,10 @@
          assertEquals("Hello2!", rm2.getText());
 
          displayProviderInfo(connection.getMetaData());
-
       }
       finally
       {
-         if(ic != null)
+         if (ic != null)
          {
             try
             {
@@ -162,5 +155,4 @@
    {
       new QueueFailoverExample().run();
    }
-
 }

Modified: trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java
===================================================================
--- trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,24 +1,24 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.example.jms.securesocket;
 
 import org.jboss.example.jms.common.ExampleSupport;
@@ -33,7 +33,6 @@
 import javax.jms.MessageConsumer;
 import javax.jms.JMSException;
 
-
 /**
  * The example creates a connection to the default provider and uses the connection to send a
  * message to the queue "queue/testQueue". Then, the example creates a second connection to the
@@ -50,96 +49,92 @@
  */
 public class SecureSocketExample extends ExampleSupport
 {
-
+   
    public void example() throws Exception
    {
       String destinationName = getDestinationJNDIName();
-
-       InitialContext ic = null;
-       ConnectionFactory cf = null;
-       Connection connection =  null;
-       Connection connection2 =  null;
-
-       try
-       {
-
-           ic = new InitialContext();
-
-           cf = (ConnectionFactory)ic.lookup("/SecureConnectionFactory");
-           Queue queue = (Queue)ic.lookup(destinationName);
-           log("Queue " + destinationName + " exists");
-
-           connection = cf.createConnection();
-           Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
-           MessageProducer sender = session.createProducer(queue);
-
-           TextMessage message = session.createTextMessage("Hello!");
-           sender.send(message);
-           log("The message was successfully sent to the " + queue.getQueueName() + " queue");
-
-           connection2 = cf.createConnection();
-           Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-           MessageConsumer consumer =  session2.createConsumer(queue);
-
-           connection2.start();
-
-           message = (TextMessage)consumer.receive(2000);
-           log("Received message: " + message.getText());
-           assertEquals("Hello!", message.getText());
-
-           displayProviderInfo(connection2.getMetaData());
-
-
-       }
-       finally
-       {
-           if(ic != null)
-           {
-               try
-               {
-                   ic.close();
-               }
-               catch(Exception e)
-               {
-                   throw e;
-               }
-           }
-
-           //ALWAYS close your connection in a finally block to avoid leaks
-           //Closing connection also takes care of closing its related objects e.g. sessions
-           closeConnection(connection);
-
-           closeConnection(connection2);
-
-       }
-
+      
+      InitialContext ic = null;
+      ConnectionFactory cf = null;
+      Connection connection =  null;
+      Connection connection2 =  null;
+      
+      try
+      {         
+         ic = new InitialContext();
+         
+         cf = (ConnectionFactory)ic.lookup("/SecureConnectionFactory");
+         Queue queue = (Queue)ic.lookup(destinationName);
+         log("Queue " + destinationName + " exists");
+         
+         connection = cf.createConnection();
+         Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer sender = session.createProducer(queue);
+         
+         TextMessage message = session.createTextMessage("Hello!");
+         sender.send(message);
+         log("The message was successfully sent to the " + queue.getQueueName() + " queue");
+         
+         connection2 = cf.createConnection();
+         Session session2 = connection2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer consumer =  session2.createConsumer(queue);
+         
+         connection2.start();
+         
+         message = (TextMessage)consumer.receive(2000);
+         log("Received message: " + message.getText());
+         assertEquals("Hello!", message.getText());
+         
+         displayProviderInfo(connection2.getMetaData());                  
+      }
+      finally
+      {
+         if(ic != null)
+         {
+            try
+            {
+               ic.close();
+            }
+            catch(Exception e)
+            {
+               throw e;
+            }
+         }
+         
+         //ALWAYS close your connection in a finally block to avoid leaks
+         //Closing connection also takes care of closing its related objects e.g. sessions
+         closeConnection(connection);
+         
+         closeConnection(connection2);
+         
+      }
+      
    }
-
+   
    private void closeConnection(Connection con) throws JMSException
    {
-       try
-       {
-		   if (con != null)
-		   {
-          		con.close();
-	       }
-       }
-       catch(JMSException jmse)
-       {
-           log("Could not close connection " + con +" exception was " +jmse);
-           throw jmse;
-       }
+      try
+      {
+         if (con != null)
+         {
+            con.close();
+         }
+      }
+      catch(JMSException jmse)
+      {
+         log("Could not close connection " + con +" exception was " +jmse);
+      }
    }
-
-
+   
+   
    protected boolean isQueueExample()
    {
       return true;
    }
-
+   
    public static void main(String[] args)
    {
       new SecureSocketExample().run();
    }
-
+   
 }

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -7,6 +7,7 @@
 package org.jboss.example.jms.stateless.bean;
 
 import java.rmi.RemoteException;
+
 import javax.ejb.EJBObject;
 
 /**
@@ -19,7 +20,10 @@
 public interface StatelessSessionExample extends EJBObject
 {
    public void drain(String queueName) throws RemoteException, Exception;
+   
    public void send(String txt, String queueName) throws RemoteException, Exception;
+   
    public int browse(String queueName) throws RemoteException, Exception;
+   
    public String receive(String queueName) throws RemoteException, Exception;
 }

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -9,34 +9,41 @@
 import java.rmi.RemoteException;
 import java.util.ArrayList;
 import java.util.Enumeration;
+
 import javax.ejb.EJBException;
 import javax.ejb.SessionBean;
 import javax.ejb.SessionContext;
-import javax.jms.*;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.JMSException;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Queue;
+import javax.jms.QueueBrowser;
+import javax.jms.Session;
+import javax.jms.TextMessage;
 import javax.naming.InitialContext;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
-
+ 
  * $Id$
  */
 public class StatelessSessionExampleBean implements SessionBean
-{
-
-   private SessionContext ctx;
-
-    private ConnectionFactory cf = null;
-
+{   
+   private ConnectionFactory cf = null;
+   
    public void drain(String queueName) throws Exception
    {
       InitialContext ic = new InitialContext();
       Queue queue = (Queue)ic.lookup(queueName);
       ic.close();
-
+      
       Session session = null;
       Connection conn = null;
-
+      
       try
       {
          conn = getConnection();
@@ -57,28 +64,31 @@
          }
       }
    }
-
+   
    public void send(String txt, String queueName) throws Exception
    {
       InitialContext ic = new InitialContext();
+      
       Queue queue = (Queue)ic.lookup(queueName);
+      
       ic.close();
-
+      
       Session session = null;
       Connection conn = null;
-
-       try
+      
+      try
       {
          conn = getConnection();
+         
          session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
+         
          MessageProducer producer = session.createProducer(queue);
-
+         
          TextMessage tm = session.createTextMessage(txt);
-
+         
          producer.send(tm);
-         System.out.println("message " + txt + " sent to " + queueName);
-
+         
+         System.out.println("message " + txt + " sent to " + queueName);         
       }
       finally
       {
@@ -88,28 +98,28 @@
          }
       }
    }
-
+   
    public int browse(String queueName) throws Exception
    {
       InitialContext ic = new InitialContext();
       Queue queue = (Queue)ic.lookup(queueName);
       ic.close();
-
+      
       Session session = null;
       Connection conn = null;
-
+      
       try
       {
          conn = getConnection();
          session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
          QueueBrowser browser = session.createBrowser(queue);
-
+         
          ArrayList list = new ArrayList();
          for(Enumeration e = browser.getEnumeration(); e.hasMoreElements(); )
          {
             list.add(e.nextElement());
          }
-
+         
          return list.size();
       }
       finally
@@ -120,35 +130,34 @@
          }
       }
    }
-
+   
    public String receive(String queueName) throws Exception
    {
       InitialContext ic = new InitialContext();
       Queue queue = (Queue)ic.lookup(queueName);
       ic.close();
-
+      
       Session session = null;
       Connection conn = null;
-
+      
       try
       {
          conn = getConnection();
          session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
+         
          MessageConsumer consumer = session.createConsumer(queue);
-
+         
          System.out.println("blocking to receive message from queue " + queueName + " ...");
          TextMessage tm = (TextMessage)consumer.receive(5000);
-
+         
          if (tm == null)
          {
             throw new Exception("No message!");
          }
-
+         
          System.out.println("Message " + tm.getText() + " received");
-
-         return tm.getText();
-
+         
+         return tm.getText();         
       }
       finally
       {
@@ -158,81 +167,86 @@
          }
       }
    }
-
-    public Connection getConnection() throws Exception {
-
-        Connection connection = null;
-
-        try {
-            connection = cf.createConnection();
-            connection.start();
-
-        }catch(Exception e ){
-           if(connection != null)
-               closeConnection(connection);
-           System.out.println("Failed to get connection...exception is " +e);
-           throw e;
-        }
-
-        return connection;
-    }
-
-    public void closeConnection(Connection con) throws Exception {
-
-       try {
-           con.close();
-
-       }catch(JMSException jmse) {
-           System.out.println("Could not close connection " + con +" exception was " +jmse);
-           throw jmse;
-       }
-    }
-
-  public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
+   
+   public Connection getConnection() throws Exception
    {
-      this.ctx = ctx;
+      
+      Connection connection = null;
+      
+      try
+      {
+         connection = cf.createConnection();
+         
+         connection.start();         
+      }
+      catch(Exception e )
+      {
+         if(connection != null)
+         {
+            closeConnection(connection);
+         }
+         System.out.println("Failed to get connection...exception is " + e);
+         throw e;
+      }
+      
+      return connection;
    }
-
-
-
-
-    public void ejbCreate()
-    {
-       try
-       {
-          InitialContext ic = new InitialContext();
-
-          cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
-
-          ic.close();
-       }
-       catch(Exception e)
-       {
-          e.printStackTrace();
-          throw new EJBException("Initalization failure: " + e.getMessage());
-       }
-    }
-
+   
+   public void closeConnection(Connection con) throws Exception
+   {      
+      try
+      {
+         con.close();         
+      }
+      catch(JMSException jmse)
+      {
+         System.out.println("Could not close connection " + con +" exception was " + jmse);
+         throw jmse;
+      }
+   }
+   
+   public void setSessionContext(SessionContext ctx) throws EJBException, RemoteException
+   {      
+   }
+   
+   public void ejbCreate()
+   {
+      try
+      {
+         InitialContext ic = new InitialContext();
+         
+         cf = (ConnectionFactory)ic.lookup("java:/JmsXA");
+         
+         ic.close();
+      }
+      catch(Exception e)
+      {
+         e.printStackTrace();
+         throw new EJBException("Initalization failure: " + e.getMessage());
+      }
+   }
+   
    public void ejbRemove() throws EJBException
    {
       try
       {
-          if(cf != null)
-              cf = null;
-       }
+         if(cf != null)
+         {
+            cf = null;
+         }
+      }
       catch(Exception e)
       {
          throw new EJBException("ejbRemove ", e);
       }
    }
-
+   
    public void ejbActivate() throws EJBException, RemoteException
    {
    }
-
+   
    public void ejbPassivate() throws EJBException, RemoteException
    {
    }
-
-
+      
 }

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleHome.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleHome.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleHome.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,9 +6,10 @@
  */
 package org.jboss.example.jms.stateless.bean;
 
-import javax.ejb.EJBHome;
 import java.rmi.RemoteException;
+
 import javax.ejb.CreateException;
+import javax.ejb.EJBHome;
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/client/Client.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,24 +1,24 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.example.jms.stateless.client;
 
 import javax.naming.InitialContext;
@@ -41,71 +41,43 @@
 public class Client extends ExampleSupport
 {
    public void example() throws Exception
-   {
-
-
+   {            
       InitialContext ic = new InitialContext();
-
-
-
+                  
       StatelessSessionExampleHome home =
-         (StatelessSessionExampleHome)ic.lookup("ejb/StatelessSessionExample");
-
-
-
+         (StatelessSessionExampleHome)ic.lookup("ejb/StatelessSessionExample");            
+      
       StatelessSessionExample bean = home.create();
-
-
-
+                  
       String queueName = getDestinationJNDIName();
-      String text = "Hello!";
-
-
-
-
+      String text = "Hello!";                  
+      
       bean.drain(queueName);
-
-
-
-
+                       
       bean.send("Hello!", queueName);
       log("The " + text + " message was successfully sent to the " + queueName + " queue");
-
-
+          
       int num = bean.browse(queueName);
-
-
-
+                  
       assertEquals(1, num);
-
-
-      log("Queue browse result: " + num);
-
-
-
+          
+      log("Queue browse result: " + num);            
+      
       String result = bean.receive(queueName);
-      log("Received " + result);
-
-
-
-      assertEquals("Hello!", result);
-
-
-
+      log("Received " + result);            
+      
+      assertEquals("Hello!", result);            
+      
       bean.remove();
    }
-
-
-
-
+   
    protected boolean isQueueExample()
    {
       return true;
    }
-
+   
    public static void main(String[] args)
    {
       new Client().run();
-   }
-
+   }   
 }

Modified: trunk/docs/examples/topic/src/org/jboss/example/jms/topic/ExampleListener.java
===================================================================
--- trunk/docs/examples/topic/src/org/jboss/example/jms/topic/ExampleListener.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/topic/src/org/jboss/example/jms/topic/ExampleListener.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -6,40 +6,37 @@
  */
 package org.jboss.example.jms.topic;
 
-import javax.jms.MessageListener;
 import javax.jms.Message;
+import javax.jms.MessageListener;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
-
+ 
  * $Id$
  */
 public class ExampleListener implements MessageListener
-{
-
+{   
    private Message message;
-
-
+      
    public synchronized void onMessage(Message message)
    {
       this.message = message;
       notifyAll();
    }
-
+   
    public synchronized Message getMessage()
    {
       return message;
    }
-
-
+      
    protected synchronized void waitForMessage()
    {
       if (message != null)
       {
          return;
       }
-
+      
       try
       {
          wait(5000);

Modified: trunk/docs/examples/topic/src/org/jboss/example/jms/topic/TopicExample.java
===================================================================
--- trunk/docs/examples/topic/src/org/jboss/example/jms/topic/TopicExample.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/docs/examples/topic/src/org/jboss/example/jms/topic/TopicExample.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,31 +1,38 @@
 /*
-* JBoss, Home of Professional Open Source
-* Copyright 2005, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.
-*/
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.example.jms.topic;
 
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.JMSException;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.jms.Topic;
+import javax.naming.InitialContext;
+
 import org.jboss.example.jms.common.ExampleSupport;
 
-import javax.naming.InitialContext;
-import javax.jms.*;
-
 /**
  * The example creates a connection to the default provider and uses the connection to send a
  * message to the topic "queue/testTopic". The message must be received by a topic subscriber.
@@ -45,45 +52,46 @@
    public void example() throws Exception
    {
       String destinationName = getDestinationJNDIName();
-
+      
       InitialContext ic = null;
       Connection connection = null;
-
-      try {
-
+      
+      try
+      {         
          ic = new InitialContext();
-
+         
          ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
          Topic topic = (Topic)ic.lookup(destinationName);
          log("Topic " + destinationName + " exists");
-
+         
          connection = cf.createConnection();
          Session session = connection.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageProducer publisher = session.createProducer(topic);
          MessageConsumer subscriber = session.createConsumer(topic);
-
+         
          ExampleListener messageListener = new ExampleListener();
          subscriber.setMessageListener(messageListener);
          connection.start();
-
+         
          TextMessage message = session.createTextMessage("Hello!");
          publisher.send(message);
          log("The message was successfully published on the topic");
-
+         
          messageListener.waitForMessage();
-
+         
          message = (TextMessage)messageListener.getMessage();
          log("Received message: " + message.getText());
          assertEquals("Hello!", message.getText());
-
+         
          displayProviderInfo(connection.getMetaData());
-
+         
       }
       finally
       {
-         if(ic != null)
+         if (ic != null)
          {
-            try {
+            try
+            {
                ic.close();
             }
             catch(Exception e)
@@ -91,15 +99,16 @@
                throw e;
             }
          }
-
+         
          // ALWAYS close your connection in a finally block to avoid leaks.
          // Closing connection also takes care of closing its related objects e.g. sessions.
          closeConnection(connection);
       }
    }
-
-   private void closeConnection(Connection con) throws JMSException {
-
+   
+   private void closeConnection(Connection con) throws JMSException
+   {
+      
       try
       {
          if (con != null)
@@ -109,19 +118,18 @@
       }
       catch(JMSException jmse)
       {
-         log("Could not close connection " + con +" exception was " +jmse);
-         throw jmse;
+         log("Could not close connection " + con +" exception was " + jmse);
       }
    }
-
+   
    protected boolean isQueueExample()
    {
       return false;
    }
-
+   
    public static void main(String[] args)
    {
       new TopicExample().run();
    }
-
+   
 }

Copied: trunk/lib/jbossts (from rev 1823, branches/Branch_1_0/lib/jbossts)

Deleted: trunk/lib/jbossts/jboss-service.xml
===================================================================
--- branches/Branch_1_0/lib/jbossts/jboss-service.xml	2006-12-19 06:51:01 UTC (rev 1823)
+++ trunk/lib/jbossts/jboss-service.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,535 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-
-<!-- $Id: jboss-service.xml 38992 2005-12-13 15:29:35Z jerrygauth $ -->
-
-<!-- ===================================================================== -->
-<!--  JBoss Server Configuration                                           -->
-<!-- ===================================================================== -->
-
-<server>
-
-   <!-- Load all jars from the JBOSS_DIST/server/<config>/lib directory. This
-     can be restricted to specific jars by specifying them in the archives
-     attribute.
-    -->
-   <classpath codebase="${jboss.server.lib.url:lib}" archives="*"/>
-
-   <!-- ==================================================================== -->
-   <!-- JSR-77 Single JBoss Server Management Domain                         -->
-   <!-- ==================================================================== -->
-   <mbean code="org.jboss.management.j2ee.LocalJBossServerDomain"
-      name="jboss.management.local:j2eeType=J2EEDomain,name=Manager">
-      <attribute name="MainDeployer">jboss.system:service=MainDeployer</attribute>
-      <attribute name="SARDeployer">jboss.system:service=ServiceDeployer</attribute>
-      <attribute name="EARDeployer">jboss.j2ee:service=EARDeployer</attribute>
-      <attribute name="EJBDeployer">jboss.ejb:service=EJBDeployer</attribute>
-      <attribute name="RARDeployer">jboss.jca:service=RARDeployer</attribute>
-      <attribute name="CMDeployer">jboss.jca:service=ConnectionFactoryDeployer</attribute>
-      <attribute name="WARDeployer">jboss.web:service=WebServer</attribute>
-      <attribute name="CARDeployer">jboss.j2ee:service=ClientDeployer</attribute>
-      <attribute name="MailService">jboss:service=Mail</attribute>
-      <attribute name="JMSService">jboss.mq:service=DestinationManager</attribute>
-      <attribute name="JNDIService">jboss:service=Naming</attribute>
-      <attribute name="JTAService">jboss:service=TransactionManager</attribute>
-      <attribute name="UserTransactionService">jboss:service=ClientUserTransaction</attribute>
-      <attribute name="RMI_IIOPService">jboss:service=CorbaORB</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- XMBean Persistence                                                   -->
-   <!-- ==================================================================== -->   
-   <mbean code="org.jboss.system.pm.AttributePersistenceService"
-      name="jboss:service=AttributePersistenceService"
-      xmbean-dd="resource:xmdesc/AttributePersistenceService-xmbean.xml">
-      <!-- the AttributePersistenceService is persistent, itself -->
-           
-      <!--
-      <attribute name="AttributePersistenceManagerClass">org.jboss.system.pm.XMLAttributePersistenceManager</attribute>
-      <attribute name="AttributePersistenceManagerConfig">
-         <data-directory>data/xmbean-attrs</data-directory>
-      </attribute>      
-      <attribute name="ApmDestroyOnServiceStop">false</attribute>
-      <attribute name="VersionTag"></attribute>
-      -->
-   </mbean>
-
-   <!-- A Thread pool service -->
-   <mbean code="org.jboss.util.threadpool.BasicThreadPool"
-      name="jboss.system:service=ThreadPool">
-      <attribute name="Name">JBoss System Threads</attribute>
-      <attribute name="ThreadGroupName">System Threads</attribute>
-      <!-- How long a thread will live without any tasks in MS -->
-      <attribute name="KeepAliveTime">60000</attribute>
-      <!-- The max number of threads in the pool -->
-      <attribute name="MaximumPoolSize">10</attribute>
-      <!-- The max number of tasks before the queue is full -->
-      <attribute name="MaximumQueueSize">1000</attribute>
-      <!-- The behavior of the pool when a task is added and the queue is full.
-      abort - a RuntimeException is thrown
-      run - the calling thread executes the task
-      wait - the calling thread blocks until the queue has room
-      discard - the task is silently discarded without being run
-      discardOldest - check to see if a task is about to complete and enque
-         the new task if possible, else run the task in the calling thread
-      -->
-      <attribute name="BlockingMode">run</attribute>
-   </mbean>
-
-   <!-- Preload all custom editors for VMs that don't use the thread
-        context class loader when searching for PropertyEditors. Uncomment
-        if your JDK 1.3.0 VM fails to find JBoss PropertyEditors.
-   <mbean code="org.jboss.varia.property.PropertyEditorManagerService"
-     name="jboss:type=Service,name=BootstrapEditors">
-     <attribute name="BootstrapEditors">
-       java.math.BigDecimal=org.jboss.util.propertyeditor.BigDecimalEditor
-       java.lang.Boolean=org.jboss.util.propertyeditor.BooleanEditor
-       java.lang.Class=org.jboss.util.propertyeditor.ClassEditor
-       java.util.Date=org.jboss.util.propertyeditor.DateEditor
-       java.io.File=org.jboss.util.propertyeditor.FileEditor
-       java.net.InetAddress=org.jboss.util.propertyeditor.InetAddressEditor
-       java.lang.Integer=org.jboss.util.propertyeditor.IntegerEditor
-       javax.management.ObjectName=org.jboss.mx.util.propertyeditor.ObjectNameEditor
-       java.util.Properties=org.jboss.util.propertyeditor.PropertiesEditor
-       [Ljava.lang.String;=org.jboss.util.propertyeditor.StringArrayEditor
-       java.net.URL=org.jboss.util.propertyeditor.URLEditor
-     </attribute>
-   </mbean>
-   -->
-
-   <!-- ==================================================================== -->
-   <!-- Log4j Initialization                                                 -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.logging.Log4jService"
-      name="jboss.system:type=Log4jService,service=Logging"
-	  xmbean-dd="resource:xmdesc/Log4jService-xmbean.xml">
-      <attribute name="ConfigurationURL">resource:log4j.xml</attribute>
-      <!-- Set the org.apache.log4j.helpers.LogLog.setQuiteMode. As of log4j1.2.8
-      this needs to be set to avoid a possible deadlock on exception at the
-      appender level. See bug#696819.
-      -->
-      <attribute name="Log4jQuietMode">true</attribute>
-      <!-- How frequently in seconds the ConfigurationURL is checked for changes -->
-      <attribute name="RefreshPeriod">60</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Active Alarm Table                                                   -->
-   <!-- ==================================================================== -->
-
-   <!--
-      | The ActiveAlarmTable service is a simple JMX notification listener
-      | that maintains a table with the received notifications (alarms).
-      | The alarms can be acknowledged through the jmx or the web console.
-      | Modify the SubscriptionList below to subscribe for any notification
-      | in the system and treat it as an alarm.
-      | The JMXNotificationAppender is a log4j Appender that can be configured
-      | in log4j.xml, that trasforms logging events to JMX notification so they
-      | can be fed back into the table. By storing the WARN or higher level logging
-      | events you can have a quick view of important system faults.
-      |
-      | The following attributes may be set:
-      |
-      | MaxTableSize (default 1000)
-      |  - set an upper limit to the number of stored alarms
-      | LogLevel (default DEBUG)
-      |  - the log level to use for received notification, can be set to NONE
-      | ServerId (default jboss)
-      |  - used to construct unique alarm ids
-      | SubscriptionList
-      |  - subscribe for the notifications to be stored in the table
-
-   <mbean code="org.jboss.monitor.services.ActiveAlarmTable" 
-          name="jboss.monitor:service=ActiveAlarmTable">
-      <attribute name="SubscriptionList">
-         <subscription-list>
-            <mbean name="jboss.monitor:*">
-               <notification type="jboss.alarm"/>
-               <notification type="JBOSS_MONITOR_NOTIFICATION"/>               
-            </mbean>
-            <mbean name="jboss.system:service=Logging,type=JMXNotificationAppender"/>
-         </subscription-list>
-      </attribute>
-   </mbean>
-   -->
-  
-   <!-- ==================================================================== -->
-   <!-- JBoss RMI Classloader - only install when available                  -->
-   <!-- ==================================================================== -->
-   <mbean code="org.jboss.util.property.jmx.SystemPropertyClassValue"
-      name="jboss.rmi:type=RMIClassLoader">
-      <attribute name="Property">java.rmi.server.RMIClassLoaderSpi</attribute>
-      <attribute name="ClassName">org.jboss.system.JBossRMIClassLoader</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Service Binding                                                      -->
-   <!-- ==================================================================== -->
-
-   <!-- Automatically activated when generatting the clustering environment -->
-   <!-- @TESTSUITE_CLUSTER_CONFIG@ -->
-
-   <!--
-      | Binding service manager for port/host mapping. This is a sample
-      | config that demonstrates a JBoss instances with a server name 'ports-01'
-      | loading its bindings from an XML file using the ServicesStoreFactory
-      | implementation returned by the XMLServicesStoreFactory.
-      |
-      | ServerName: The unique name assigned to a JBoss server instance for
-      | lookup purposes. This allows a single ServicesStore to handle mulitiple
-      | JBoss servers.
-      |
-      | StoreURL: The URL string passed to org.jboss.services.binding.ServicesStore
-      | during initialization that specifies how to connect to the bindings store.
-      | StoreFactory: The org.jboss.services.binding.ServicesStoreFactory interface
-      | implementation to create to obtain the ServicesStore instance.
-
-   <mbean code="org.jboss.services.binding.ServiceBindingManager"
-     name="jboss.system:service=ServiceBindingManager">
-     <attribute name="ServerName">ports-01</attribute>
-     <attribute name="StoreURL">${jboss.home.url}/docs/examples/binding-manager/sample-bindings.xml</attribute>
-     <attribute name="StoreFactoryClassName">
-       org.jboss.services.binding.XMLServicesStoreFactory
-     </attribute>
-   </mbean>
-   -->
-
-   <!-- ==================================================================== -->
-   <!-- Class Loading                                                        -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.web.WebService"
-      name="jboss:service=WebService">
-      <attribute name="Port">8083</attribute>
-      <!-- Should non-EJB .class files be downloadable -->
-      <attribute name="DownloadServerClasses">true</attribute>
-      <!-- Should resources other than .class files be downloadable. Both
-         DownloadServerClasses and DownloadResources must be true for resources
-         to be downloadable. This is false by default because its generally a
-         bad idea as server configuration files that container security
-         information can be accessed.
-       -->
-      <attribute name="DownloadResources">false</attribute>
-      <attribute name="Host">${jboss.bind.address}</attribute>
-      <attribute name="BindAddress">${jboss.bind.address}</attribute>
-      <!-- Use the default thread pool for dynamic class loading -->
-      <depends optional-attribute-name="ThreadPool"
-         proxy-type="attribute">jboss.system:service=ThreadPool</depends>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- JNDI                                                                 -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.naming.NamingService"
-      name="jboss:service=Naming"
-      xmbean-dd="resource:xmdesc/NamingService-xmbean.xml">
-      <!-- The call by value mode. true if all lookups are unmarshalled using
-      the caller's TCL, false if in VM lookups return the value by reference.
-      -->
-      <attribute name="CallByValue">false</attribute>
-      <!-- The listening port for the bootstrap JNP service. Set this to -1
-        to run the NamingService without the JNP invoker listening port.
-      -->
-      <attribute name="Port">1099</attribute>
-      <!-- The bootstrap JNP server bind address. This also sets the default
-      RMI service bind address. Empty == all addresses
-       -->
-      <attribute name="BindAddress">${jboss.bind.address}</attribute>
-      <!-- The port of the RMI naming service, 0 == anonymous -->
-      <attribute name="RmiPort">1098</attribute>
-      <!-- The RMI service bind address. Empty == all addresses
-       -->
-      <attribute name="RmiBindAddress">${jboss.bind.address}</attribute>
-      <!-- The thread pool service used to control the bootstrap lookups -->
-      <depends optional-attribute-name="LookupPool"
-         proxy-type="attribute">jboss.system:service=ThreadPool</depends>
-   </mbean>
-
-   <mbean code="org.jboss.naming.JNDIView"
-   	name="jboss:service=JNDIView"
-   	xmbean-dd="resource:xmdesc/JNDIView-xmbean.xml">
-   	<!-- The HANamingService service name -->
-   	<attribute name="HANamingService">jboss:service=HAJNDI</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Security                                                             -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.security.plugins.SecurityConfig"
-      name="jboss.security:service=SecurityConfig">
-      <attribute name="LoginConfig">jboss.security:service=XMLLoginConfig</attribute>
-   </mbean>
-   <mbean code="org.jboss.security.auth.login.XMLLoginConfig"
-      name="jboss.security:service=XMLLoginConfig">
-      <attribute name="ConfigResource">login-config.xml</attribute>
-   </mbean>
-
-   <!-- JAAS security manager and realm mapping -->
-   <mbean code="org.jboss.security.plugins.JaasSecurityManagerService"
-      name="jboss.security:service=JaasSecurityManager">
-      <!-- A flag which indicates whether the SecurityAssociation server mode
-      is set on service creation. This is true by default since the
-      SecurityAssociation should be thread local for multi-threaded server
-      operation.
-      -->
-      <attribute name="ServerMode">true</attribute>
-      <attribute name="SecurityManagerClassName">org.jboss.security.plugins.JaasSecurityManager</attribute>
-      <attribute name="DefaultUnauthenticatedPrincipal">anonymous</attribute>
-      <!-- DefaultCacheTimeout: Specifies the default timed cache policy timeout
-      in seconds.
-      If you want to disable caching of security credentials, set this to 0 to
-      force authentication to occur every time. This has no affect if the
-      AuthenticationCacheJndiName has been changed from the default value.
-      -->
-      <attribute name="DefaultCacheTimeout">1800</attribute>
-      <!-- DefaultCacheResolution: Specifies the default timed cache policy
-      resolution in seconds. This controls the interval at which the cache
-      current timestamp is updated and should be less than the DefaultCacheTimeout
-      in order for the timeout to be meaningful. This has no affect if the
-      AuthenticationCacheJndiName has been changed from the default value.
-      -->
-      <attribute name="DefaultCacheResolution">60</attribute>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Transactions                                                         -->
-   <!-- ==================================================================== -->
-   <!-- The configurable Xid factory.  For use with Oracle, set pad to true -->
-   <mbean code="org.jboss.tm.XidFactory"
-      name="jboss:service=XidFactory">
-      <!--attribute name="Pad">true</attribute-->
-   </mbean>
-
-   <!--
-      | The fast in-memory transaction manager.
-    
-   <mbean code="org.jboss.tm.TransactionManagerService"
-      name="jboss:service=TransactionManager"
-      xmbean-dd="resource:xmdesc/TransactionManagerService-xmbean.xml">
-      <attribute name="TransactionTimeout">300</attribute>
-      <!- set to false to disable transaction demarcation over IIOP ->
-      <attribute name="GlobalIdsEnabled">true</attribute>
-      <depends optional-attribute-name="XidFactory">jboss:service=XidFactory</depends>
-
-      <!- Transaction Integrity Checking ->
-      <!- Force a rollback if another thread is associated with the transaction at commit ->
-      <!-depends optional-attribute-name="TransactionIntegrityFactory" 
-               proxy-type="org.jboss.tm.integrity.TransactionIntegrityFactory">
-         <mbean code="org.jboss.tm.integrity.FailIncompleteTransaction"
-                name="jboss:service=TransactionManager,plugin=TransactionIntegrity"/>
-      </depends->
-   </mbean-->
-   
-   <mbean code="com.arjuna.ats.jbossatx.jta.TransactionManagerService"
-      name="jboss:service=TransactionManager">
-      <attribute name="TransactionTimeout">300</attribute>
-   </mbean>
-   
-   <!--
-      | UserTransaction support.
-    -->
-   <mbean code="org.jboss.tm.usertx.server.ClientUserTransactionService"
-      name="jboss:service=ClientUserTransaction"
-      xmbean-dd="resource:xmdesc/ClientUserTransaction-xmbean.xml">
-      <depends>
-         <mbean code="org.jboss.invocation.jrmp.server.JRMPProxyFactory"
-            name="jboss:service=proxyFactory,target=ClientUserTransactionFactory">
-            <attribute name="InvokerName">jboss:service=invoker,type=jrmp</attribute>
-            <attribute name="TargetName">jboss:service=ClientUserTransaction</attribute>
-            <attribute name="JndiName">UserTransactionSessionFactory</attribute>
-            <attribute name="ExportedInterface">org.jboss.tm.usertx.interfaces.UserTransactionSessionFactory</attribute>
-            <attribute name="ClientInterceptors">
-               <interceptors>
-                  <interceptor>org.jboss.proxy.ClientMethodInterceptor</interceptor>
-                  <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
-               </interceptors>
-            </attribute>
-            <depends>jboss:service=invoker,type=jrmp</depends>
-         </mbean>
-      </depends>
-      <depends optional-attribute-name="TxProxyName">
-         <mbean code="org.jboss.invocation.jrmp.server.JRMPProxyFactory"
-            name="jboss:service=proxyFactory,target=ClientUserTransaction">
-            <attribute name="InvokerName">jboss:service=invoker,type=jrmp</attribute>
-            <attribute name="TargetName">jboss:service=ClientUserTransaction</attribute>
-            <attribute name="JndiName"></attribute>
-            <attribute name="ExportedInterface">org.jboss.tm.usertx.interfaces.UserTransactionSession</attribute>
-            <attribute name="ClientInterceptors">
-               <interceptors>
-                  <interceptor>org.jboss.proxy.ClientMethodInterceptor</interceptor>
-                  <interceptor>org.jboss.invocation.InvokerInterceptor</interceptor>
-               </interceptors>
-            </attribute>
-            <depends>jboss:service=invoker,type=jrmp</depends>
-         </mbean>
-      </depends>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Invokers to the JMX node                                             -->
-   <!-- ==================================================================== -->
-
-   <!-- RMI/JRMP invoker -->
-   <mbean code="org.jboss.invocation.jrmp.server.JRMPInvoker"
-      name="jboss:service=invoker,type=jrmp">
-      <attribute name="RMIObjectPort">4444</attribute>
-      <attribute name="ServerAddress">${jboss.bind.address}</attribute>
-      <!--
-      <attribute name="RMIClientSocketFactory">custom</attribute>
-      <attribute name="RMIServerSocketFactory">custom</attribute>
-      <attribute name="RMIServerSocketAddr">custom</attribute>
-      <attribute name="SecurityDomain">ssl-domain-name</attribute>
-      -->
-      <depends>jboss:service=TransactionManager</depends>
-   </mbean>
-
-   <mbean code="org.jboss.invocation.local.LocalInvoker"
-      name="jboss:service=invoker,type=local">
-
-      <depends>jboss:service=TransactionManager</depends>
-   </mbean>
-
-   <mbean code="org.jboss.invocation.pooled.server.PooledInvoker"
-      name="jboss:service=invoker,type=pooled">
-      <attribute name="NumAcceptThreads">1</attribute>
-      <attribute name="MaxPoolSize">300</attribute>
-      <attribute name="ClientMaxPoolSize">300</attribute>
-      <attribute name="SocketTimeout">60000</attribute>
-      <attribute name="ServerBindAddress">${jboss.bind.address}</attribute>
-      <attribute name="ServerBindPort">4445</attribute>
-      <attribute name="ClientConnectAddress">${jboss.bind.address}</attribute>
-      <attribute name="ClientConnectPort">0</attribute>
-      <attribute name="ClientRetryCount">1</attribute>
-      <attribute name="EnableTcpNoDelay">false</attribute>
-
-      <!-- Customized socket factory attributes
-      <attribute name="ClientSocketFactoryName">custom.client.factory</attribute>
-      <attribute name="ServerSocketFactoryName">custom.server.factory</attribute>
-      <attribute name="SslDomain">java:/jaas/pooledInvoker</attribute>
-      -->
-      <depends optional-attribute-name="TransactionManagerService">jboss:service=TransactionManager</depends>
-   </mbean>
-
-   <!-- ==================================================================== -->
-   <!-- Monitoring and Management                                            -->
-   <!-- ==================================================================== -->
-
-   <!-- Uncomment to enable JMX monitoring of the bean cache
-   <mbean code="org.jboss.monitor.BeanCacheMonitor"
-          name="jboss.monitor:name=BeanCacheMonitor"/>
-   -->
-
-   <!-- Uncomment to enable JMX monitoring of the entity bean locking
-   <mbean code="org.jboss.monitor.EntityLockMonitor"
-          name="jboss.monitor:name=EntityLockMonitor"/>
-   -->
-
-   <!-- ==================================================================== -->
-   <!-- An MBean that is a registry for JDBC type-mapping metadata           -->
-   <!-- ==================================================================== -->
-
-   <mbean code="org.jboss.ejb.plugins.cmp.jdbc.metadata.MetaDataLibrary"
-      name="jboss.jdbc:service=metadata"/>
-
-   <!-- ==================================================================== -->
-   <!-- Deployment Scanning                                                  -->
-   <!-- ==================================================================== -->
-
-   <!-- An mbean for hot deployment/undeployment of archives.
-   -->
-   <mbean code="org.jboss.deployment.scanner.URLDeploymentScanner"
-      name="jboss.deployment:type=DeploymentScanner,flavor=URL">
-
-      <!-- Uncomment (and comment/remove version below) to enable usage of the
-        DeploymentCache
-      <depends optional-attribute-name="Deployer">jboss.deployment:type=DeploymentCache</depends>
-      -->
-      <depends optional-attribute-name="Deployer">jboss.system:service=MainDeployer</depends>
-
-      <!-- The URLComparator can be used to specify a deployment ordering
-           for deployments found in a scanned directory.  The class specified
-           must be an implementation of java.util.Comparator, it must be able
-           to compare two URL objects, and it must have a no-arg constructor.
-           Two deployment comparators are shipped with JBoss:
-             - org.jboss.deployment.DeploymentSorter
-               Sorts by file extension, as follows:
-                 "sar", "service.xml", "rar", "jar", "war", "wsr", "ear", "zip",
-                 "*"
-             - org.jboss.deployment.scanner.PrefixDeploymentSorter
-               If the name portion of the url begins with 1 or more digits, those
-               digits are converted to an int (ignoring leading zeroes), and
-               files are deployed in that order.  Files that do not start with
-               any digits will be deployed first, and they will be sorted by
-               extension as above with DeploymentSorter.
-      -->
-      <attribute name="URLComparator">org.jboss.deployment.DeploymentSorter</attribute>
-      
-      <!--
-      <attribute name="URLComparator">org.jboss.deployment.scanner.PrefixDeploymentSorter</attribute>
-      -->
-
-      <!-- The FilterInstance specifies a URLLister.URLFilter for scanned
-           directories. This DeploymentFilter is initialized with the given
-           prefixes, suffixes and matches that define which URLs should be
-           ignored.
-      -->
-      <attribute name="FilterInstance"
-         attributeClass="org.jboss.deployment.scanner.DeploymentFilter"
-         serialDataType="javaBean">
-         <!-- Files starting with theses strings are ignored -->
-         <property name="prefixes">#,%,\,,.,_$</property>
-         <!-- Files ending with theses strings are ignored -->
-         <property name="suffixes">#,$,%,~,\,v,.BAK,.bak,.old,.orig,.tmp,.rej,.sh</property>
-         <!-- Files matching with theses strings are ignored -->
-         <property name="matches">.make.state,.nse_depinfo,CVS,CVS.admin,RCS,RCSLOG,SCCS,TAGS,core,tags</property>
-      </attribute>
-
-      <!-- Frequency in milliseconds to rescan the URLs for changes -->
-      <attribute name="ScanPeriod">5000</attribute>
-      
-      <!-- A flag to disable the scans -->
-      <attribute name="ScanEnabled">true</attribute>
-
-      <!-- URLs are comma separated and resolve relative to the server home URL
-         unless the given path is absolute. If the URL ends in "/" it is
-         considered a collection and scanned, otherwise it is simply deployed;
-         this follows RFC2518 convention and allows discrimination between
-         collections and directories that are simply unpacked archives.
-
-         URLs may be local (file:) or remote (http:). Scanning is supported
-         for remote URLs but unpacked deployment units are not.
-
-         Example URLs:
-            deploy/
-                 scans ${jboss.server.url}/deploy/, which is local or remote
-                 depending on the URL used to boot the server
-            ${jboss.server.home}/deploy/
-                 scans ${jboss.server.home)/deploy, which is always local
-            file:/var/opt/myapp.ear
-                 deploy myapp.ear from a local location
-            file:/var/opt/apps/
-                 scans the specified directory
-            http://www.test.com/netboot/myapp.ear
-                 deploys myapp.ear from a remote location
-            http://www.test.com/netboot/apps/
-                 scans the specified WebDAV location
-       -->
-      <attribute name="URLs">
-         deploy/
-      </attribute>
-
-      <!-- Indicates if the scanner should recursively scan directories that
-      contain no "." in their names. This can be used to group applications
-      and services that must be deployed and that have the same
-      logical function in the same directory i.e.
-        deploy/JMX/
-        deploy/JMS/
-        ...
-      -->
-      <attribute name="RecursiveSearch">True</attribute>
-
-   </mbean>
-
-</server>

Copied: trunk/lib/jbossts/jboss-service.xml (from rev 1823, branches/Branch_1_0/lib/jbossts/jboss-service.xml)

Deleted: trunk/lib/jbossts/jbossjta-properties.xml
===================================================================
--- branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml	2006-12-19 06:51:01 UTC (rev 1823)
+++ trunk/lib/jbossts/jbossjta-properties.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,278 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<transaction-service>
-    <properties depends="common" name="arjuna">
-        <!--
-        Transaction Reaper Timeout (default is 120000 microseconds).
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.coordinator.txReaperTimeout" value="120000"/>
-        <!--
-        Transaction Reaper Mode, can be: NORMAL or DYNAMIC (default is NORMAL).
-      -->
-        <property name="com.arjuna.ats.arjuna.coordinator.txReaperMode" value="NORMAL"/>
-        <!--
-        (default is NO)
-      -->
-        <property name="com.arjuna.ats.arjuna.coordinator.asyncCommit" value="NO"/>
-        <!--
-        (default is NO)
-      -->
-        <property name="com.arjuna.ats.arjuna.coordinator.asyncPrepare" value="NO"/>
-        <!--
-        (default is YES)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.coordinator.commitOnePhase" value="YES"/>
-        <!--
-        (default is defaultStore)
-      -->
-        <property name="com.arjuna.ats.arjuna.objectstore.localOSRoot" value="defaultStore"/>
-        <!--
-        default is under user.home - must be writeable!)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.objectStoreDir" value="PutObjectStoreDirHere"/>
-        <!--
-        (default is ON)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.objectStoreSync" value="ON"/>
-        <!--
-        (default is ShadowNoFileLockStore)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.objectStoreType" value="ShadowNoFileLockStore"/>
-        <!--
-        (default is 255)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.hashedDirectories" value="255"/>
-        <!--
-        (default is ON)
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.objectstore.transactionSync" value="ON"/>
-        <!--
-        (Must be unique across all Arjuna instances.)
-      -->
-        <property name="com.arjuna.ats.arjuna.xa.nodeIdentifier" value="1"/>
-        <!-- property
-        name="com.arjuna.ats.arjuna.coordinator.actionStore"
-		value="HashedActionStore"
-		value="JDBCActionStore"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcTxDbAccess"
-		value="JDBCAccess"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.objectStoreType"
-		value="ShadowNoFileLockStore"
-		value="JDBCStore"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcUserDbAccess"
-		value="JDBCAccess"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcPoolSizeInitial"
-		value="1"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcPoolSizeMaximum"
-		value="1"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.objectstore.jdbcPoolPutConnections"
-		value="false"
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.internal.arjuna.objectstore.cacheStore.size"
-		value=""
-      -->
-        <!-- property
-        name="com.arjuna.ats.arjuna.internal.arjuna.objectstore.cacheStore.period"
-		value=""
-      -->
-        <!--
-        The location for creating temporary files, e.g., Uids.
-        Default is under user.home.
-        IMPORTANT: make sure the directory is lockable, e.g., /tmp on Unix
-        may not be!
-      -->
-        <!--
-        <property
-          name="com.arjuna.ats.arjuna.common.varDir"
-          value="var"/>
-      -->
-    </properties>
-    <properties depends="arjuna" name="recoverymanager">
-        <!--
-        Properties used only by the RecoveryManager.
-      -->
-        <!--
-        Periodic recovery settings.
-        Time values in this section are in seconds.
-      -->
-        <!--
-        Interval in seconds between initiating the periodic recovery modules.
-        Default is 120 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.periodicRecoveryPeriod" value="120"/>
-        <!--
-        Interval in seconds between first and second pass of periodic recovery.
-        Default is 10 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.recoveryBackoffPeriod" value="10"/>
-        
-        <!--
-        Expired entry removal
-      -->
-        <!--
-        Expiry scanners to use (order of invocation is random).
-        Names must begin with "com.arjuna.ats.arjuna.recovery.expiryScanner"
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScannerTransactionStatusManager" value="com.arjuna.ats.internal.arjuna.recovery.ExpiredTransactionStatusManagerScanner"/>
-        <!--
-        Interval, in hours, between running the expiry scanners.
-        This can be quite long. The absolute value determines the interval -
-        if the value is negative, the scan will NOT be run until after one
-        interval has elapsed. If positive the first scan will be immediately
-        after startup. Zero will prevent any scanning.
-        Default  = 12 = run immediately, then every 12 hours.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScanInterval" value="12"/>
-        <!--
-        Age, in hours, for removal of transaction status manager item.
-        This should be longer than any ts-using process will remain running.
-        Zero = Never removed.  Default is 12.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerExpiryTime" value="12"/>
-        <!--
-        Use this to fix the port on which the TransactionStatusManager listens,
-        The default behaviour is to use any free port.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerPort" value="0"/>
-        <!--
-        Properties used only by the RecoveryManager.
-      -->
-        <!--
-        Periodic recovery settings.
-        Time values in this section are in seconds.
-      -->
-        <!--
-        Interval in seconds between initiating the periodic recovery modules.
-        Default is 120 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.periodicRecoveryPeriod" value="120"/>
-        <!--
-        Interval in seconds between first and second pass of periodic recovery.
-        Default is 10 seconds.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.recoveryBackoffPeriod" value="10"/>
-        <!--
-        Periodic recovery modules to use.  Invoked in sort-order of names.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.recoveryExtension1" value="com.arjuna.ats.internal.jta.recovery.arjunacore.XARecoveryModule"/>
-        <!--
-        Expired entry removal
-      -->
-        <!--
-        Expiry scanners to use (order of invocation is random).
-        Names must begin with "com.arjuna.ats.arjuna.recovery.expiryScanner"
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScannerTransactionStatusManager" value="com.arjuna.ats.internal.arjuna.recovery.ExpiredTransactionStatusManagerScanner"/>
-        <!--
-        Interval, in hours, between running the expiry scanners.
-        This can be quite long. The absolute value determines the interval -
-        if the value is negative, the scan will NOT be run until after one
-        interval has elapsed. If positive the first scan will be immediately
-        after startup. Zero will prevent any scanning.
-        Default  = 12 = run immediately, then every 12 hours.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.expiryScanInterval" value="12"/>
-        <!--
-        Age, in hours, for removal of transaction status manager item.
-        This should be longer than any ts-using process will remain running.
-        Zero = Never removed.  Default is 12.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerExpiryTime" value="12"/>
-        <!--
-        Use this to fix the port on which the TransactionStatusManager listens,
-        The default behaviour is to use any free port.
-      -->
-        <property
-            name="com.arjuna.ats.arjuna.recovery.transactionStatusManagerPort" value="0"/>
-    </properties>
-    <properties name="common">
-        <!-- CLF 2.0 properties -->
-        <property name="com.arjuna.common.util.logging.DebugLevel"
-            type="System" value="0x00000000"/>
-        <property name="com.arjuna.common.util.logging.FacilityLevel"
-            type="System" value="0xffffffff"/>
-        <property name="com.arjuna.common.util.logging.VisibilityLevel"
-            type="System" value="0xffffffff"/>
-        <property name="com.arjuna.common.util.logger" type="System" value="log4j"/>
-    </properties>
-    <properties depends="arjuna" name="txoj">
-        <!--
-        (default is LockStore of installation - must be writeable!)
-      -->
-        <!--
-        <property
-          name="com.arjuna.ats.txoj.lockstore.lockStoreDir"
-          value="LockStore"/>
-      -->
-        <!--
-        (default is BasicLockStore)
-      -->
-        <property name="com.arjuna.ats.txoj.lockstore.lockStoreType" value="BasicLockStore"/>
-        <!--
-        (default is NO)
-      -->
-        <property name="com.arjuna.ats.txoj.lockstore.multipleLockStore" value="NO"/>
-        <!--
-        (default is YES)
-      -->
-        <property name="com.arjuna.ats.txoj.lockstore.singleLockStore" value="YES"/>
-        <!--
-        (default is YES)
-      -->
-        <property
-            name="com.arjuna.ats.txoj.lockstore.allowNestedLocking" value="YES"/>
-    </properties>
-    <properties depends="arjuna" name="jta">
-        <property
-            name="com.arjuna.ats.jta.recovery.XAResourceRecovery.JBMESSAGING" value="org.jboss.jms.recovery.JMSProviderXAResourceRecovery"/>
-        <!--
-        Support subtransactions in the JTA layer?
-        Default is NO.
-      -->
-        <property name="com.arjuna.ats.jta.supportSubtransactions" value="NO"/>
-        <property name="com.arjuna.ats.jta.jtaTMImplementation" value="com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionManagerImple"/>
-        <!--
-			com.arjuna.ats.internal.jta.transaction.jts.TransactionManagerImple
-			-->
-        <property name="com.arjuna.ats.jta.jtaUTImplementation" value="com.arjuna.ats.internal.jta.transaction.arjunacore.UserTransactionImple"/>
-        <!--
-			com.arjuna.ats.internal.jta.transaction.jts.UserTransactionImple
-			-->
-    </properties>
-    <properties depends="jta" name="jdbc">
-        <!--
-           property name="com.arjuna.ats.jdbc.isolationLevel" value="TRANSACTION_SERIALIZABLE"/>
-        -->
-    </properties>
-</transaction-service>

Copied: trunk/lib/jbossts/jbossjta-properties.xml (from rev 1823, branches/Branch_1_0/lib/jbossts/jbossjta-properties.xml)

Modified: trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/etc/server/default/deploy/clustered-mysql-persistence-service.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -35,7 +35,7 @@
 ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
 ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
 LOAD_PAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, PAGE_ORD, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND PAGE_ORD BETWEEN ? AND ? ORDER BY PAGE_ORD
-LOAD_UNPAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE PAGE_ORD IS NULL and CHANNELID = ? ORDER BY ORD
+LOAD_UNPAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE STATE = 'C' AND CHANNELID = ? AND PAGE_ORD IS NULL ORDER BY ORD
 UPDATE_RELIABLE_REFS_NOT_PAGED=UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?
 SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?
 SELECT_EXISTS_REF=SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?
@@ -50,6 +50,8 @@
 INSERT_TRANSACTION=INSERT INTO JMS_TRANSACTION (TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID) VALUES(?, ?, ?, ?)
 DELETE_TRANSACTION=DELETE FROM JMS_TRANSACTION WHERE TRANSACTIONID = ?
 SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JMS_TRANSACTION
+SELECT_MESSAGEID_FOR_REF=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+SELECT_MESSAGEID_FOR_ACK=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'       
 UPDATE_COUNTER=UPDATE JMS_COUNTER SET NEXT_ID = ? WHERE NAME=?
 SELECT_COUNTER=SELECT NEXT_ID FROM JMS_COUNTER WHERE NAME=? FOR UPDATE
 INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)

Modified: trunk/src/etc/server/default/deploy/mysql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -35,7 +35,7 @@
    ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
    ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
    LOAD_PAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, PAGE_ORD, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND PAGE_ORD BETWEEN ? AND ? ORDER BY PAGE_ORD
-   LOAD_UNPAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE PAGE_ORD IS NULL and CHANNELID = ? ORDER BY ORD
+   LOAD_UNPAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE STATE = 'C' AND CHANNELID = ? AND PAGE_ORD IS NULL ORDER BY ORD
    UPDATE_RELIABLE_REFS_NOT_PAGED=UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?
    SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?
    SELECT_EXISTS_REF=SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?
@@ -49,7 +49,9 @@
    MESSAGE_EXISTS=SELECT MESSAGEID FROM JMS_MESSAGE WHERE MESSAGEID = ? FOR UPDATE
    INSERT_TRANSACTION=INSERT INTO JMS_TRANSACTION (TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID) VALUES(?, ?, ?, ?)
    DELETE_TRANSACTION=DELETE FROM JMS_TRANSACTION WHERE TRANSACTIONID = ?
-   SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JMS_TRANSACTION
+   SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JMS_TRANSACTION   
+   SELECT_MESSAGEID_FOR_REF=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+   SELECT_MESSAGEID_FOR_ACK=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'       
    UPDATE_COUNTER=UPDATE JMS_COUNTER SET NEXT_ID = ? WHERE NAME=?
    SELECT_COUNTER=SELECT NEXT_ID FROM JMS_COUNTER WHERE NAME=? FOR UPDATE
    INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
@@ -71,7 +73,7 @@
 CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))
 INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
 DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
-LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
+LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
       ]]></attribute>
    </mbean>
 

Modified: trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -32,6 +32,7 @@
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
+import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.Client;
 
@@ -185,6 +186,9 @@
        
       // Remove reference to message ID generator
       MessageIdGeneratorFactory.instance.checkInGenerator(state.getServerID());
+      
+      // And to resource manager
+      ResourceManagerFactory.instance.checkInResourceManager(state.getServerID());
 
       return ret;
    }

Modified: trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -25,7 +25,6 @@
 
 import org.jboss.aop.advice.Interceptor;
 import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.jms.util.MessagingJMSException;
 import org.jboss.logging.Logger;
 
 /**
@@ -70,40 +69,19 @@
       }       
       catch(JMSException e)
       {
-         if (trace)  { log.trace("Caught JMSException:" + e); }
-         Exception linked = e.getLinkedException();
-         if (linked != null)
-         {
-            log.error("Linked exception is: ", linked);
-         }
-         logCause(e);
+         // JMSException should not be logged unless trace is on
+         if (trace)  { log.trace("Caught JMSException:", e); }
+         
          throw e;
       }
-      catch (UnsupportedOperationException e)
+      catch (Throwable t)
       {
-         //These must be propagated to the client
-         throw e;         
-      }
-      catch (RuntimeException e)
-      {         
-         log.error("Caught RuntimeException", e);
-         logCause(e);
-         JMSException ex = new javax.jms.IllegalStateException(e.getMessage());
-         ex.setLinkedException(e);
-         throw ex; 
-      }
-      catch (Exception e)
-      {
-         log.error("Caught Exception: ", e);
-         logCause(e);         
-         throw new MessagingJMSException("Caught exception", e);
-      }
-      catch (Error e)
-      {
-         log.error("Caught Error: ", e);
-         logCause(e);
-         throw e;
-      }
+         //We log everything else
+         
+         log(t);
+         
+         throw t;         
+      }      
    }
 
    // Package protected ---------------------------------------------
@@ -112,13 +90,13 @@
 
    // Private -------------------------------------------------------
    
-   private void logCause(Throwable e)
+   private void log(Throwable e)
    {
+      log.error("Caught throwable", e);
       Throwable e2 = e.getCause();
       if (e2 != null)
       {
-         log.error("Cause of exception:", e2);
-         logCause(e2);
+         log(e2);
       }
    }
 

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -24,7 +24,6 @@
 
 import java.util.ArrayList;
 import java.util.Collections;
-import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
@@ -32,10 +31,10 @@
 import javax.jms.JMSException;
 import javax.jms.Session;
 
-import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.Advised;
 import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.delegate.ClientBrowserDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
@@ -58,9 +57,10 @@
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.ResourceManager;
+import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
-import org.jboss.remoting.ConnectionListener;
 import org.jboss.remoting.Client;
+import org.jboss.remoting.ConnectionListener;
 
 /**
  *
@@ -381,7 +381,7 @@
    }
 
    protected void performClientSideFailover(ClientConnectionDelegate failedConnDelegate,
-                                          ClientConnectionDelegate newConnDelegate)
+                                            ClientConnectionDelegate newConnDelegate)
       throws Exception
    {
       log.debug(this + " performing client side failover");
@@ -401,16 +401,24 @@
 
       // We need to update some of the attributes on the state
       failedState.copyState(newState);
+      
+      int failedServerId = failedConnDelegate.getServerID();
+      
+      int newServerId = newConnDelegate.getServerID();
+      
+      if (trace) { log.trace("Failing over from " + failedServerId + " to " + newServerId); }
+      
+      // There is one RM per server, so we need to merge the rms if necessary
+      ResourceManagerFactory.instance.handleFailover(failedServerId, newServerId);
+      
+      ResourceManager rm = failedState.getResourceManager();
 
-      // Map of old session ID to new session state
-      Map oldNewSessionStateMap = new HashMap();
-
       for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
       {
          SessionState failedSessionState = (SessionState)i.next();
+         
+         int oldSessionId = failedSessionState.getSessionId();
 
-         int oldSessionID = failedSessionState.getSessionId();
-
          ClientSessionDelegate failedSessionDelegate =
             (ClientSessionDelegate)failedSessionState.getDelegate();
 
@@ -420,11 +428,11 @@
                                   failedSessionState.isXA());
 
          SessionState newSessionState = (SessionState)newSessionDelegate.getState();
+         
+         int newSessionId = newSessionState.getSessionId();
 
          if (trace) { log.trace("new session state has " + newSessionState.getClientAckList().size() + " deliveries"); }
 
-         oldNewSessionStateMap.put(new Integer(oldSessionID), failedSessionState);
-
          failedSessionDelegate.copyAttributes(newSessionDelegate);
 
          // We need to update some of the attributes on the state
@@ -448,34 +456,26 @@
                 handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
             }
          }
-      }
-
-      // First we must tell the resource manager to substitute old session ID for new session ID.
-      // Note we MUST submit the entire mapping in one operation since there may be overlap between
-      // old and new session ID, and we don't want to overwrite keys in the map.
-
-      failedState.getResourceManager().handleFailover(oldNewSessionStateMap);
-
-      for(Iterator i = oldNewSessionStateMap.values().iterator(); i.hasNext(); )
-      {
+         
+         // We need to failover from one session id to another in the resource manager
+         rm.handleFailover(newServerId, oldSessionId, newSessionId);
+               
          List ackInfos = Collections.EMPTY_LIST;
 
-         SessionState state = (SessionState)i.next();
-
-         if (!state.isTransacted() ||
-             (state.isXA() && state.getCurrentTxId() == null))
+         if (!failedSessionState.isTransacted() ||
+             (failedSessionState.isXA() && failedSessionState.getCurrentTxId() == null))
          {
             // Non transacted session or an XA session with no transaction set (it falls back
             // to auto_ack)
 
-            if (trace) { log.trace(state + " is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
+            if (trace) { log.trace(failedSessionState + " is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
 
             // We remove any unacked non-persistent messages - this is because we don't want to ack
             // them since the server won't know about them and will get confused
 
-            if (state.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
+            if (failedSessionState.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
             {
-               for(Iterator j = state.getClientAckList().iterator(); j.hasNext(); )
+               for(Iterator j = failedSessionState.getClientAckList().iterator(); j.hasNext(); )
                {
                   DeliveryInfo info = (DeliveryInfo)j.next();
                   if (!info.getMessageProxy().getMessage().isReliable())
@@ -485,17 +485,17 @@
                   }
                }
 
-               ackInfos = state.getClientAckList();
+               ackInfos = failedSessionState.getClientAckList();
             }
             else
             {
-               DeliveryInfo autoAck = state.getAutoAckInfo();
+               DeliveryInfo autoAck = failedSessionState.getAutoAckInfo();
                if (autoAck != null)
                {
                   if (!autoAck.getMessageProxy().getMessage().isReliable())
                   {
                      // unreliable, discard
-                     state.setAutoAckInfo(null);
+                     failedSessionState.setAutoAckInfo(null);
                   }
                   else
                   {
@@ -513,13 +513,12 @@
             // Transacted session - we need to get the acks from the resource manager. BTW we have
             // kept the old resource manager
 
-            ResourceManager rm = failedState.getResourceManager();
-            ackInfos = rm.getDeliveriesForSession(state.getSessionId());
+            ackInfos = rm.getDeliveriesForSession(failedSessionState.getSessionId());
          }
 
          if (!ackInfos.isEmpty())
          {
-            SessionDelegate newDelegate = (SessionDelegate)state.getDelegate();
+            SessionDelegate newDelegate = (SessionDelegate)failedSessionState.getDelegate();
 
             List recoveryInfos = new ArrayList();
 
@@ -586,17 +585,6 @@
       // Update attributes on the old state
       failedConsumerState.copyState(newState);
 
-//      if (failedSessionState.isTransacted() || failedSessionState.isXA())
-//      {
-//         // Replace the old consumer id with the new consumer id
-//
-//         ResourceManager rm = failedConnectionState.getResourceManager();
-//
-//         todo - we need to replace the sesion id
-//
-//         rm.handleFailover(oldConsumerID, failedConsumerState.getConsumerID());
-//      }
-
       // We need to re-use the existing message callback handler
 
       MessageCallbackHandler oldHandler =

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -23,7 +23,6 @@
 
 import java.util.ArrayList;
 import java.util.Iterator;
-import java.util.LinkedList;
 import java.util.List;
 
 import javax.jms.IllegalStateException;
@@ -33,14 +32,15 @@
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
+import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.server.endpoint.DefaultCancel;
-import org.jboss.jms.server.endpoint.DefaultAck;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.jms.tx.ClientTransaction;
+import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.util.Util;
 
 /**
  * This aspect handles JMS session related logic
@@ -97,7 +97,33 @@
       MethodInvocation mi = (MethodInvocation)invocation;
       SessionState state = getState(invocation);
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
-      
+            
+      if (trace) { log.trace("In handleClosing"); }
+      //Sanity check
+      if (state.isXA())
+      {
+         if (trace) { log.trace("Session is XA"); }
+         
+         ConnectionState connState = (ConnectionState)state.getParent();
+         
+         ResourceManager rm = connState.getResourceManager();
+         
+         //An XASession should never be closed if there is prepared ack work that has not yet
+         //been committed or rolled back.
+         //Imagine if messages had been consumed in the session, and prepared but not committed.
+         //Then the connection was explicitly closed causing the session to close.
+         //Closing the session causes any outstanding delivered but unacked messages to be cancelled to
+         //the server which means they would be available for other consumers to consume.
+         //If another consumer then consumes them, then recover() is called and the original
+         //transaction is committed, then this means the same message has been delivered twice
+         //which breaks the once and only once delivery guarantee
+         
+         if (rm.checkForAcksInSession(state.getSessionId()))
+         {
+            throw new java.lang.IllegalStateException("Attempt to close an XASession when there are still uncommitted acknowledgements!");
+         }        
+      }
+            
       int ackMode = state.getAcknowledgeMode();
   
       //We need to either ack (for auto_ack) or cancel (for client_ack)
@@ -361,6 +387,12 @@
     *
     * So on rollback we do session recovery (local redelivery) in the same as if session.recover()
     * was called.
+    * 
+    * All cancellation at rollback is driven from the client side - we always attempt to redeliver
+    * messages to their original consumers if they are still open, or then cancel them to the server
+    * if they are not. Cancelling them to the server explicitly allows the delivery count to be updated.
+    * 
+    * 
     */
    public Object handleRedeliver(Invocation invocation) throws Throwable
    {            

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -210,8 +210,21 @@
     */
    public HandleMessageResponse handleMessage(List msgs) throws HandleCallbackException
    {                      
-      if (trace) { log.trace(this + " receiving " + msgs.size() + " message(s) from the remoting layer"); }
-            
+      if (trace)
+      {
+         StringBuffer sb = new StringBuffer(this + " receiving [");
+         for(int i = 0; i < msgs.size(); i++)
+         {
+            sb.append(((MessageProxy)msgs.get(i)).getMessage().getMessageID());
+            if (i < msgs.size() - 1)
+            {
+               sb.append(",");
+            }
+         }
+         sb.append("] from the remoting layer");
+         log.trace(sb.toString());
+      }
+
       synchronized (mainLock)
       {
          if (closed)
@@ -237,7 +250,7 @@
                    
          buffer.addAll(msgs);                  
          
-         if (trace) { log.trace(this + " added messages to the buffer"); }            
+         if (trace) { log.trace(this + " added message(s) to the buffer"); }
          
          boolean full = buffer.size() >= bufferSize;         
          
@@ -348,9 +361,9 @@
       {
          sessionExecutor.execute(new Closer(result));
 
-         if (trace) { log.trace("blocking wait for Closer execution"); }
+         if (trace) { log.trace(this + " blocking wait for Closer execution"); }
          result.getResult();
-         if (trace) { log.trace("got Closer result"); }
+         if (trace) { log.trace(this + " got Closer result"); }
       }
       catch (InterruptedException e)
       {
@@ -433,7 +446,7 @@
                   }
                }
                               
-               if (trace) { log.trace("received " + m + " after being blocked on buffer"); }
+               if (trace) { log.trace(this + " received " + m + " after being blocked on buffer"); }
                        
                // If message is expired we still call pre and post deliver. This makes sure the
                // message is acknowledged so it gets removed from the queue/subscription.
@@ -449,14 +462,14 @@
                
                if (!m.getMessage().isExpired())
                {
-                  if (trace) { log.trace("message " + m + " is not expired, pushing it to the caller"); }
+                  if (trace) { log.trace(this + ": message " + m + " is not expired, pushing it to the caller"); }
                   
                   break;
                }
                
                if (trace)
                {
-                  log.trace("message expired, discarding");
+                  log.trace(this + ": message expired, discarding");
                }
                
                // the message expired, so discard the message, adjust timeout and reenter the buffer

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -31,6 +31,7 @@
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.ResourceManager;
+import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
 
 import EDU.oswego.cs.dl.util.concurrent.SyncSet;
@@ -100,7 +101,7 @@
       // Each connection has its own resource manager. If we can failover all connections with the
       // same server id at the same time then we can maintain one rm per unique server as opposed to
       // per connection.
-      this.resourceManager = new ResourceManager();
+      this.resourceManager = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
 
       this.idGenerator = gen;
       this.serverID = serverID;

Copied: trunk/src/main/org/jboss/jms/recovery (from rev 1823, branches/Branch_1_0/src/main/org/jboss/jms/recovery)

Deleted: trunk/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java	2006-12-19 06:51:01 UTC (rev 1823)
+++ trunk/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,100 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2006, JBoss Inc., and individual contributors as indicated
-* by the @authors tag. See the copyright.txt 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.jms.recovery;
-
-import javax.transaction.xa.XAResource;
-
-import org.jboss.logging.Logger;
-
-import com.arjuna.ats.jta.recovery.XAResourceRecovery;
-
-/**
- * JMS Provider Adapter based recovery.
- *
- * @author <a href="adrian at jboss.com">Adrian Brock</a>
- * @author <a href="juha at jboss.com">Juha Lindfors</a>
- *
- * @version $Revision: 1.1 $
- */
-public class JMSProviderXAResourceRecovery implements XAResourceRecovery
-{
-   private boolean trace = log.isTraceEnabled();
-
-	private static final Logger log = Logger.getLogger(JMSProviderXAResourceRecovery.class);
-
-   /** The jms provider name */
-   private String providerName;
-
-   /** The delegate XAResource */
-   private XAResourceWrapper wrapper;
-
-   /** Whether the XAResource is working */
-   private boolean working = false;
-
-   public JMSProviderXAResourceRecovery()
-   {
-      if(trace)
-			log.trace("Constructing JMSProviderXAResourceRecovery..");
-   }
-
-   public boolean initialise(String p)
-   {
-      if(trace)
-			log.trace("Initialising JMSProviderXAResourceRecovery..");
-
-      this.providerName = p;
-      return true;
-   }
-
-   public boolean hasMoreResources()
-   {
-      // If the XAResource is already working
-      if (working)
-         return false;
-
-      // Have we initialized yet?
-      if (wrapper == null)
-      {
-         wrapper = new XAResourceWrapper();
-         wrapper.setProviderName(providerName);
-      }
-
-      // Test the connection
-      try
-      {
-         wrapper.getTransactionTimeout();
-         working = true;
-      }
-      catch (Exception ignored)
-      {
-         //System.out.println(ignored.getMessage());
-      }
-
-      // This will return false until we get a successful connection
-      return working;
-   }
-
-   public XAResource getXAResource()
-   {
-      return wrapper;
-   }
-}

Copied: trunk/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java (from rev 1823, branches/Branch_1_0/src/main/org/jboss/jms/recovery/JMSProviderXAResourceRecovery.java)

Deleted: trunk/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java	2006-12-19 06:51:01 UTC (rev 1823)
+++ trunk/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,133 +0,0 @@
-package org.jboss.jms.recovery;
-
-import java.sql.SQLException;
-import javax.jms.XAConnection;
-import javax.jms.XAConnectionFactory;
-import javax.jms.XASession;
-import javax.naming.Context;
-import javax.naming.InitialContext;
-import javax.transaction.xa.XAResource;
-
-import org.jboss.logging.Logger;
-
-import com.arjuna.ats.jta.recovery.XAResourceRecovery;
-
-public class MessagingXAResourceRecovery implements XAResourceRecovery {
-
-	private boolean trace = log.isTraceEnabled();
-
-	private static final Logger log = Logger.getLogger(MessagingXAResourceRecovery.class);
-
-	private boolean working = false;
-
-	private XAResource xaRes = null;
-
-	private String xaConnFactory = null;
-
-	public MessagingXAResourceRecovery() {
-	}
-
-	public XAResource getXAResource() throws SQLException {
-		if(trace)
-			log.trace("returning the xaresource "+xaRes);
-		return xaRes;
-	}
-
-	/**
-	 * This method returns the Messaging XAResource reference.
-	 * You have to pass the jndi name of the XAConnectionFactory
-	 * via the JBossTS RecoveryManager's properties
-	 * @return
-	 */
-	public XAResource initXAResource() {
-		if(trace)
-			log.trace("Initialising xaresource..");
-		try {
-			Context ctx = new InitialContext();
-
-			XAConnectionFactory cf = (XAConnectionFactory) ctx
-					.lookup(xaConnFactory);
-
-			XAConnection xaConn = cf.createXAConnection();
-
-			XASession session = xaConn.createXASession();
-			xaRes = session.getXAResource();
-
-			if(trace)
-				log.trace("Found the xares: "+xaRes);
-
-		} catch (Exception e) {
-			// You may get this exception when the messaging server
-			// is not fully booted up. Nothing to worry, it'll keep
-			// trying until successful.
-			log.warn("XAConnectionFactory is not found. \n" +
-					"The messaging server is not yet initialized.\n" +
-					"we'll try again once server is fully back");
-
-		}
-
-		return xaRes;
-	}
-
-	/**
-	 * This method is used to pass any
-	 * intialisation parameters to this
-	 * class
-	 * @param param
-	 * @return
-	 * @throws SQLException
-	 */
-	public boolean initialise(String param) throws SQLException
-  {
-		if(trace)
-			log.trace("Passed in parameter: "+param);
-
-		if(param != null)
-		{
-			// parama is in the form of name=value
-			String value = param.substring(param.indexOf("=")+1);
-
-			if(trace)
-				log.trace("The connection factory is "+value);
-
-      xaConnFactory = value;
-		}
-		else
-		{
-			log.debug("The XA connection factory parameter is null. " +
-					"Using the default 'XAConnectionFactory'");
-
-      xaConnFactory = "XAConnectionFactory";
-		}
-		return true;
-	}
-
-	/**
-	 * This method checks whether there's an xa resource available
-	 *
-	 * @return
-	 */
-	public boolean hasMoreResources() {
-
-		if (working)
-			return false;
-
-		if (xaRes == null) {
-			xaRes = initXAResource();
-		}
-
-		// test the resource
-		try {
-
-			xaRes.getTransactionTimeout();
-
-			working = true;
-
-		} catch (Exception ignored) {
-
-			// ignore this exception
-		}
-
-		return working;
-	}
-}

Copied: trunk/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java (from rev 1823, branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java)
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java	2006-12-19 06:51:01 UTC (rev 1823)
+++ trunk/src/main/org/jboss/jms/recovery/MessagingXAResourceRecovery.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -0,0 +1,152 @@
+package org.jboss.jms.recovery;
+
+import java.sql.SQLException;
+import javax.jms.XAConnection;
+import javax.jms.XAConnectionFactory;
+import javax.jms.XASession;
+import javax.naming.Context;
+import javax.naming.InitialContext;
+import javax.transaction.xa.XAResource;
+
+import org.jboss.logging.Logger;
+
+import com.arjuna.ats.jta.recovery.XAResourceRecovery;
+
+/**
+ * 
+ * A MessagingXAResourceRecovery
+ *
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class MessagingXAResourceRecovery implements XAResourceRecovery
+{   
+   private boolean trace = log.isTraceEnabled();
+   
+   private static final Logger log = Logger.getLogger(MessagingXAResourceRecovery.class);
+   
+   private boolean working = false;
+   
+   private XAResource xaRes = null;
+   
+   private String xaConnFactory = null;
+   
+   public MessagingXAResourceRecovery()
+   {
+   }
+   
+   public XAResource getXAResource() throws SQLException
+   {
+      if (trace) { log.trace("returning the xaresource " + xaRes); }
+      return xaRes;
+   }
+   
+   /**
+    * This method returns the Messaging XAResource reference.
+    * You have to pass the jndi name of the XAConnectionFactory
+    * via the JBossTS RecoveryManager's properties
+    * @return
+    */
+   public XAResource initXAResource()
+   {
+      if(trace)
+      {
+         log.trace("Initialising xaresource..");
+      }
+      try
+      {
+         Context ctx = new InitialContext();
+         
+         XAConnectionFactory cf = (XAConnectionFactory) ctx
+         .lookup(xaConnFactory);
+         
+         XAConnection xaConn = cf.createXAConnection();
+         
+         XASession session = xaConn.createXASession();
+         xaRes = session.getXAResource();
+         
+         if(trace)
+            log.trace("Found the xares: "+xaRes);
+         
+      }
+      catch (Exception e)
+      {
+         // You may get this exception when the messaging server
+         // is not fully booted up. Nothing to worry, it'll keep
+         // trying until successful.
+         log.warn("XAConnectionFactory is not found. \n" +
+                  "The messaging server is not yet initialized.\n" +
+         "we'll try again once server is fully back");
+         
+      }
+      
+      return xaRes;
+   }
+   
+   /**
+    * This method is used to pass any
+    * intialisation parameters to this
+    * class
+    * @param param
+    * @return
+    * @throws SQLException
+    */
+   public boolean initialise(String param) throws SQLException
+   {
+      if(trace) { log.trace("Passed in parameter: " + param); }
+      
+      if (param != null)
+      {
+         // param is in the form of name=value
+         String value = param.substring(param.indexOf("=") + 1);
+         
+         if(trace) { log.trace("The connection factory is " + value); }
+         
+         xaConnFactory = value;
+      }
+      else
+      {
+         log.debug("The XA connection factory parameter is null. " +
+         "Using the default 'XAConnectionFactory'");
+         
+         xaConnFactory = "XAConnectionFactory";
+      }
+      return true;
+   }
+   
+   /**
+    * This method checks whether there's an xa resource available
+    *
+    * @return
+    */
+   public boolean hasMoreResources()
+   {      
+      if (working)
+      {
+         return false;
+      }
+      
+      if (xaRes == null)
+      {
+         xaRes = initXAResource();
+      }
+      
+      // test the resource
+      try
+      {
+         
+         xaRes.getTransactionTimeout();
+         
+         working = true;         
+      }
+      catch (Exception ignored)
+      {
+         
+         // ignore this exception
+      }
+      
+      return working;
+   }
+}

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -73,6 +73,8 @@
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * 
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -83,8 +85,6 @@
 
    private static final Logger log = Logger.getLogger(ServerPeer.class);
 
-   public static final String RECOVERABLE_CTX_NAME = "jms-recoverables";
-
    // The "subsystem" label this ServerPeer uses to register its ServerInvocationHandler with the
    // Remoting connector
    public static final String REMOTING_JMS_SUBSYSTEM = "JMS";
@@ -220,7 +220,7 @@
          connectorManager = new SimpleConnectorManager();
          memoryManager = new SimpleMemoryManager();
          messageStore = new SimpleMessageStore();
-         txRepository = new TransactionRepository(persistenceManager, transactionIDManager);
+         txRepository = new TransactionRepository(persistenceManager, messageStore, transactionIDManager);
 
          // Start the wired components
 
@@ -235,11 +235,10 @@
          messageStore.start();
          securityStore.start();
          txRepository.start();
-
+         txRepository.loadPreparedTransactions();
+         
          initializeRemoting(mbeanServer);
 
-         //createRecoverable();
-
          started = true;
 
          log.info("JBoss Messaging " + getVersion().getProviderVersion() + " server [" +
@@ -264,8 +263,6 @@
 
          started = false;
 
-         //removeRecoverable();
-
          // Stop the wired components
 
          messageIDManager.stop();
@@ -484,8 +481,6 @@
       this.failoverCompleteTimeout = timeout;
    }
    
-   
-
    // JMX Operations ------------------------------------------------
 
    public String createQueue(String name, String jndiName) throws Exception
@@ -698,10 +693,12 @@
          if (!postOffice.isLocal())
          {
             Replicator rep = (Replicator)postOffice;
-            connFactoryJNDIMapper.injectReplicator(rep);
+            connFactoryJNDIMapper.injectReplicator(rep);            
             rep.registerListener(new FailoverListener());
-
          }
+         
+         //Also need to inject into txRepository
+         this.txRepository.injectPostOffice(postOffice);
       }
       return postOffice;
    }
@@ -850,61 +847,7 @@
    // Protected -----------------------------------------------------
 
    // Private -------------------------------------------------------
-
-   /**
-    * Place a Recoverable instance in the JNDI tree. This can be used by a transaction manager in
-    * order to obtain an XAResource so it can perform XA recovery.
-    */
-
-   //Commented out until XA Recovery is complete
-
-//   private void createRecoverable() throws Exception
-//   {
-//      //Disabled until XA Recovery is complete with Arjuna transaction integration
-//
-//      InitialContext ic = new InitialContext();
-//
-//      int connFactoryID = connFactoryJNDIMapper.registerConnectionFactory(null, null);
-//
-//      XAConnectionFactory xaConnFactory =
-//         (XAConnectionFactory)connFactoryJNDIMapper.getConnectionFactory(connFactoryID);
-//
-//      JMSRecoverable recoverable = new JMSRecoverable(serverPeerID, xaConnFactory);
-//
-//      Context recCtx = null;
-//      try
-//      {
-//         recCtx = (Context)ic.lookup(RECOVERABLE_CTX_NAME);
-//      }
-//      catch (NamingException e)
-//      {
-//         //Ignore
-//      }
-//
-//      if (recCtx == null)
-//      {
-//         recCtx = ic.createSubcontext(RECOVERABLE_CTX_NAME);
-//      }
-//
-//      recCtx.rebind(this.serverPeerID, recoverable);
-//   }
-//
-//   private void removeRecoverable() throws Exception
-//   {
-//      InitialContext ic = new InitialContext();
-//
-//      Context recCtx = null;
-//      try
-//      {
-//         recCtx = (Context)ic.lookup(RECOVERABLE_CTX_NAME);
-//         recCtx.unbind(serverPeerID);
-//      }
-//      catch (NamingException e)
-//      {
-//         //Ignore
-//      }
-//   }
-
+  
    private void initializeRemoting(MBeanServer mbeanServer) throws Exception
    {
       JMSWireFormat wf = new JMSWireFormat();

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionEndpoint.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -380,6 +380,9 @@
          {
             if (trace) { log.trace("Two phase commit rollback request received"); }
              
+            //For 2pc rollback - we just don't cancel any messages back to the channel
+            //this is driven from the client side
+             
             Transaction tx =  tr.getPreparedTx(request.getXid());              
             if (trace) { log.trace("Rolling back " + tx); }
             tx.rollback();
@@ -402,7 +405,7 @@
    {
       try
       {
-         List xids = tr.getPreparedTransactions();
+         List xids = tr.recoverPreparedTransactions();
          
          return (Xid[])xids.toArray(new Xid[xids.size()]);
       }
@@ -634,7 +637,7 @@
     
    private void processTransaction(ClientTransaction txState, Transaction tx) throws Throwable
    {
-      if (trace) { log.trace("processing transaction"); }
+      if (trace) { log.trace(tx + " :processing transaction"); }
       
       synchronized (sessions)
       {         
@@ -665,7 +668,7 @@
          }
       }
       
-      if (trace) { log.trace("Processed transaction"); }
+      if (trace) { log.trace(tx + " :Processed transaction"); }
    }   
 
    // Inner classes -------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -630,8 +630,21 @@
 
          try
          {
-            if (trace) { log.trace(ServerConsumerEndpoint.this + " handing " + list.size() + " message(s) over to the remoting layer"); }
-
+            if (trace)
+            {
+               StringBuffer sb = new StringBuffer(ServerConsumerEndpoint.this + " handing [");
+               for(int i = 0; i < list.size(); i++)
+               {
+                  sb.append(((MessageProxy)list.get(i)).getMessage().getMessageID());
+                  if (i < list.size() - 1)
+                  {
+                     sb.append(",");
+                  }
+               }
+               sb.append("] over to the remoting layer");
+               log.trace(sb.toString());
+            }
+            
             synchronized(messagesInTransitLock)
             {
                connection.getCallbackHandler().handleCallback(callback);

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -484,7 +484,7 @@
             
             Queue queue = binding.getQueue();
             
-            List dels = queue.createDeliveries(ids);
+            List dels = queue.recoverDeliveries(ids);
             
             Iterator iter2 = dels.iterator();
             
@@ -1343,7 +1343,10 @@
       
       public void afterRollback(boolean onePhase) throws TransactionException
       {                            
-         //NOOP
+         //One phase rollbacks never hit the server - they are dealt with locally only
+         //so this would only ever be executed for a two phase rollback.
+
+         //We don't do anything since cancellation is driven from the client.
       }
       
       synchronized void addDeliveryId(Long deliveryId)

Modified: trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -24,18 +24,17 @@
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
 import java.util.ArrayList;
-import java.util.Collection;
 import java.util.Collections;
-import java.util.HashMap;
 import java.util.Iterator;
+import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
 
-import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.endpoint.Ack;
 import org.jboss.jms.server.endpoint.DefaultAck;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.logging.Logger;
 import org.jboss.messaging.core.message.MessageFactory;
 
 /**
@@ -46,6 +45,9 @@
 public class ClientTransaction
 {  
    // Constants -----------------------------------------------------
+   
+   private static final Logger log = Logger.getLogger(ClientTransaction.class);
+   
 
    public final static byte TX_OPEN = 0;
    
@@ -59,7 +61,7 @@
    
    // Attributes ----------------------------------------------------
    
-   private int state = TX_OPEN;
+   private byte state = TX_OPEN;
    
    //Maintained on the client side
    private Map sessionStatesMap;
@@ -80,7 +82,7 @@
    
    // Public --------------------------------------------------------
    
-   public int getState()
+   public byte getState()
    {
       return state;
    }
@@ -113,17 +115,23 @@
       {
          throw new IllegalStateException("Cannot call this method on the server side");
       }
-      Iterator iter = sessionStatesMap.values().iterator();
       
-      while (iter.hasNext())
+      if (sessionStatesMap != null)
       {
-         SessionTxState sessionTxState = (SessionTxState)iter.next();
+         //This can be null if the tx was recreated on the client side due to recovery
          
-         sessionTxState.clearMessages();
+         Iterator iter = sessionStatesMap.values().iterator();
+         
+         while (iter.hasNext())
+         {
+            SessionTxState sessionTxState = (SessionTxState)iter.next();
+            
+            sessionTxState.clearMessages();
+         }
       }
    }
    
-   public void setState(int state)
+   public void setState(byte state)
    {
       if (!clientSide)
       {
@@ -132,7 +140,7 @@
       this.state = state;
    }
    
-   public Collection getSessionStates()
+   public List getSessionStates()
    {
       if (sessionStatesList != null)
       {
@@ -140,14 +148,14 @@
       }
       else
       {
-         return sessionStatesMap == null ? Collections.EMPTY_SET : sessionStatesMap.values();
+         return sessionStatesMap == null ? Collections.EMPTY_LIST : new ArrayList(sessionStatesMap.values());
       }
    }   
    
    /*
     * Substitute newSessionId for oldSessionId
     */
-   public void handleFailover(Map oldNewSessionMap)
+   public void handleFailover(int newServerId, int oldSessionId, int newSessionId)
    {    
       if (!clientSide)
       {
@@ -157,33 +165,15 @@
       //and we don't want to overwrite keys in the map
       
       if (sessionStatesMap != null)
-      {         
-         Map newMap = new HashMap();
+      {                          
+         Iterator iter = sessionStatesMap.values().iterator();
          
-         Iterator iter = oldNewSessionMap.entrySet().iterator();
-         
          while (iter.hasNext())
          {
-            Map.Entry entry = (Map.Entry)iter.next();
+            SessionTxState state = (SessionTxState)iter.next();
             
-            Integer oldSessionId = (Integer)entry.getKey();
-            
-            SessionState newSessionState = (SessionState)entry.getValue();
-            
-            int newSessionId = newSessionState.getSessionId();
-            
-            SessionTxState state = (SessionTxState)sessionStatesMap.get(oldSessionId);
-            
-            if (state != null)
-            {
-               state.handleFailover(newSessionId);
-            }
-            
-            newMap.put(new Integer(newSessionId), state);
-            
+            state.handleFailover(newServerId, oldSessionId, newSessionId);            
          }
-       
-         sessionStatesMap = newMap;
       }
    }
    
@@ -209,7 +199,7 @@
    
    public void write(DataOutputStream out) throws Exception
    {
-      out.writeInt(state);
+      out.writeByte(state);
 
       if (sessionStatesMap == null)
       {
@@ -264,7 +254,7 @@
    {
       clientSide = false;
       
-      state = in.readInt();
+      state = in.readByte();
       
       int numSessions = in.readInt();
       
@@ -314,7 +304,7 @@
    {                  
       if (sessionStatesMap == null)
       {
-         sessionStatesMap = new HashMap();
+         sessionStatesMap = new LinkedHashMap();
       }
       
       SessionTxState sessionTxState = (SessionTxState)sessionStatesMap.get(new Integer(sessionId));
@@ -328,8 +318,7 @@
       
       return sessionTxState;
    }
-   
-   
+         
       
    // Inner Classes -------------------------------------------------
    
@@ -365,23 +354,29 @@
          return sessionId;
       }
       
-      void handleFailover(int newSessionId)
+      void handleFailover(int newServerId, int oldSessionId, int newSessionId)
       {
-         this.sessionId = newSessionId;
-         
-         //Remove any non persistent acks
-         
-         Iterator iter = acks.iterator();
-         
-         while (iter.hasNext())
-         {
-            DeliveryInfo info = (DeliveryInfo)iter.next();
+         if (this.sessionId == oldSessionId && this.serverId != newServerId)
+         {            
+            this.sessionId = newSessionId;
             
-            if (!info.getMessageProxy().getMessage().isReliable())
+            this.serverId = newServerId;
+            
+            //Remove any non persistent acks
+            
+            Iterator iter = acks.iterator();
+            
+            while (iter.hasNext())
             {
-               iter.remove();
+               DeliveryInfo info = (DeliveryInfo)iter.next();
+               
+               if (!info.getMessageProxy().getMessage().isReliable())
+               {
+                  iter.remove();
+               }
             }
          }
+
       }
       
       void clearMessages()
@@ -391,6 +386,11 @@
       
       private int sessionId;
       
+      //we record the server id when doing failover to avoid overwriting the sesion id again
+      //if multiple connections fail on the same resource mamanger but fail onto old values of the session id
+      //this prevents the id being failed over more than once for the same server
+      private int serverId = -1;
+      
       private List msgs = new ArrayList();
       
       private List acks = new ArrayList();            

Deleted: trunk/src/main/org/jboss/jms/tx/JMSRecoverable.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/JMSRecoverable.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/tx/JMSRecoverable.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1,81 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.tx;
-
-import java.io.Serializable;
-
-import javax.jms.JMSException;
-import javax.jms.XAConnection;
-import javax.jms.XAConnectionFactory;
-import javax.jms.XASession;
-import javax.transaction.xa.XAResource;
-
-/**
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- *
- * @version $Revision$
- *
- * $Id$
- */
-public class JMSRecoverable implements Serializable
-{
-   private static final long serialVersionUID = -2007160911694821670L;
-
-   protected String serverID;
-   
-   protected XAConnectionFactory cf;
-   
-   protected XAConnection conn;
-   
-   public JMSRecoverable(String serverID, XAConnectionFactory cf)
-   {
-      this.serverID = serverID;
-      this.cf = cf; 
-   }
-
-   public String getName()
-   {
-      return "JBossMessaging-" + serverID;
-   }
-
-   public XAResource getResource() throws JMSException
-   {
-      cleanUp();
-      
-      conn = cf.createXAConnection();
-      
-      XASession sess = conn.createXASession();
-      
-      return sess.getXAResource();
-   }
-   
-   public void cleanUp() throws JMSException
-   {
-      if (conn != null)
-      {
-         conn.close();
-         
-         conn = null;
-      }
-   }
-
-}

Modified: trunk/src/main/org/jboss/jms/tx/MessagingXAResource.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/MessagingXAResource.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/tx/MessagingXAResource.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -28,6 +28,7 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.tx.XidImpl;
 
 /**
  * An XAResource implementation.
@@ -38,6 +39,10 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * 
+ * Parts based on JBoss MQ XAResource implementation by:
+ * 
  * @author Hiram Chirino (Cojonudo14 at hotmail.com)
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  * 
@@ -109,7 +114,12 @@
    public void commit(Xid xid, boolean onePhase) throws XAException
    {
       if (trace) { log.trace(this + " committing " + xid + (onePhase ? " (one phase)" : " (two phase)")); }
-      
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       rm.commit(xid, onePhase, connection);
 
       // leave the session in a 'clean' state, the currentTxId will be set when the XAResource will
@@ -122,6 +132,11 @@
    {
       if (trace) { log.trace(this + " ending " + xid + ", flags: " + flags); }
 
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       synchronized (this)
       {
          switch (flags)
@@ -145,11 +160,22 @@
    public void forget(Xid xid) throws XAException
    {
       if (trace) { log.trace(this + " forgetting " + xid + " (currently an NOOP)"); }
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
    }
 
    public int prepare(Xid xid) throws XAException
    {
       if (trace) { log.trace(this + " preparing " + xid); }
+
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       return rm.prepare(xid, connection);
    }
 
@@ -164,9 +190,11 @@
    {
       if (trace) { log.trace(this + " rolling back " + xid); }
 
-      // TODO on rollback should we also stop and start the consumers to remove any transient
-      // messages, like we do on local session rollback??
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
 
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       rm.rollback(xid, connection);
    }
 
@@ -174,6 +202,11 @@
    {
       if (trace) { log.trace(this + " starting " + xid + ", flags: " + flags); }
       
+      // Recreate Xid. See JBMESSAGING-661 [JPL]
+
+      if (!(xid instanceof XidImpl))
+         xid = new XidImpl(xid.getBranchQualifier(), xid.getFormatId(), xid.getGlobalTransactionId());
+
       boolean convertTx = false;
       
       if (sessionState.getCurrentTxId() != null)

Modified: trunk/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -22,7 +22,7 @@
 package org.jboss.jms.tx;
 
 import java.util.ArrayList;
-import java.util.Collection;
+import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
@@ -52,7 +52,9 @@
  * This is one instance of ResourceManager per JMS server. The ResourceManager instances are managed
  * by ResourceManagerFactory.
  * 
- * @author <a href="mailto:tim.fox at jboss.com>Tim Fox</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * @author <a href="mailto:Cojonudo14 at hotmail.com">Hiram Chirino</a>
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  * @version $Revision$
@@ -74,9 +76,21 @@
    private static final Logger log = Logger.getLogger(ResourceManager.class);
    
    // Constructors --------------------------------------------------
+   
+   ResourceManager()
+   {      
+   }
     
    // Public --------------------------------------------------------
    
+   /*
+    * Merge another resource manager into this one - used in failover
+    */
+   public void merge(ResourceManager other)
+   {
+      transactions.putAll(other.transactions);
+   }
+   
    /**
     * Remove a tx
     */
@@ -115,20 +129,17 @@
    }
    
    /*
-    * Failover session from old session -> new session
-    * This basically involves updating the session id
+    * Failover session from old session id -> new session id
     */
-   public void handleFailover(Map oldNewSessionMap)
+   public void handleFailover(int newServerId, int oldSessionId, int newSessionId)
    {
-      //Note we need to replace ids for *all* transactions - this is because, for XA
-      //the session might have done work in many transactions
       Iterator iter = this.transactions.values().iterator();
       
       while (iter.hasNext())
       {
          ClientTransaction tx = (ClientTransaction)iter.next();
          
-         tx.handleFailover(oldNewSessionMap);
+         tx.handleFailover(newServerId, oldSessionId, newSessionId);
       }                
    }   
    
@@ -162,8 +173,6 @@
     * 
     * @param xid - The id of the transaction to add the message to
     * @param ackInfo Information describing the acknowledgement
-    * @param sessionState - the session the ack is in - we need this so on rollback we can tell each session
-    * to redeliver it's messages
     */
    public void addAck(Object xid, int sessionId, DeliveryInfo ackInfo) throws JMSException
    {
@@ -245,6 +254,34 @@
    {
       return transactions.size();
    }
+      
+   
+   public boolean checkForAcksInSession(int sessionId)
+   {         
+      Iterator iter = transactions.entrySet().iterator();
+      
+      while (iter.hasNext())
+      {         
+         Map.Entry entry = (Map.Entry)iter.next();
+      
+         Object xid = entry.getKey();
+         
+         ClientTransaction tx = (ClientTransaction)entry.getValue();
+                  
+         if (tx.getState() == ClientTransaction.TX_PREPARED)
+         {            
+            List dels = tx.getDeliveriesForSession(sessionId);
+            
+            if (dels != null && !dels.isEmpty())
+            {
+               //There are outstanding prepared acks in this session
+               
+               return true;
+            }
+         }
+      }
+      return false;
+   }
     
    // Protected ------------------------------------------------------      
    
@@ -255,6 +292,8 @@
       if (trace) { log.trace("commiting xid " + xid + ", onePhase=" + onePhase); }
       
       ClientTransaction tx = removeTxInternal(xid);
+      
+      if (trace) { log.trace("Got tx: " + tx + " state " + tx.getState()); }
           
       if (onePhase)
       {
@@ -306,40 +345,59 @@
       if (trace) { log.trace("rolling back xid " + xid); }
       
       ClientTransaction tx = removeTxInternal(xid);
-          
+      
+      //It's possible we don't actually have the prepared tx here locally - this
+      //may happen if we have recovered from failure and the transaction manager
+      //is calling rollback on the transaction as part of the recovery process.
+      
       TransactionRequest request = null;
       
-      // we don't need to send the messages to the server on a rollback
+      //don't need the messages
       if (tx != null)
       {
-         //We don't clear the acks since we need to redeliver locally
          tx.clearMessages();
       }
-      
+             
       if ((tx == null) || tx.getState() == ClientTransaction.TX_PREPARED)
       {
+         //2PC rollback
+         
          request = new TransactionRequest(TransactionRequest.TWO_PHASE_ROLLBACK_REQUEST, xid, tx);
          
+         if (trace) { log.trace("Sending rollback to server, tx:" + tx); }
+                                  
          sendTransactionXA(request, connection);
       } 
       else
       {
+         //For one phase rollback there is nothing to do on the server 
+         
          if (tx == null)
          {     
             throw new MessagingXAException(XAException.XAER_NOTA, "Cannot find transaction with xid:" + xid);
          }
-         
-         //For one phase rollback there is nothing to do on the server
       }
+                  
+      //we redeliver the messages
+      //locally to their original consumers if they are still open or cancel them to the server
+      //if the original consumers have closed
       
+      if (trace) { log.trace("Redelivering messages, tx:" + tx); }
+      
       try
       {
-         redeliverMessages(tx);
+         if (tx != null)
+         {
+            redeliverMessages(tx);
+            
+            tx.setState(ClientTransaction.TX_ROLLEDBACK);  
+         }
+         
       }
       catch (JMSException e)
       {
          log.error("Failed to redeliver", e);
-      }
+      }                               
    }
    
    void endTx(Xid xid, boolean success) throws XAException
@@ -388,6 +446,8 @@
       
       state.setState(ClientTransaction.TX_PREPARED);
       
+      if (trace) { log.trace("State is now: " + state.getState()); }
+      
       return XAResource.XA_OK;
    }
    
@@ -469,6 +529,21 @@
          try
          {
             Xid[] txs = conn.getPreparedTransactions();
+
+            //populate with TxState --MK
+            for (int i = 0; i < txs.length;i++)
+            {
+               //Don't overwrite if it is already there
+               if (!transactions.containsKey(txs[i]))
+               {
+                  ClientTransaction tx = new ClientTransaction();
+   
+                  tx.setState(ClientTransaction.TX_PREPARED);
+   
+                  transactions.put(txs[i], tx);
+               }
+            }
+
             return txs;
          }
          catch (JMSException e)
@@ -499,11 +574,19 @@
    /*
     * Rollback has occurred so we need to redeliver any unacked messages corresponding to the acks
     * is in the transaction.
+    * NOTE! We only do this for 1PC rollback - for 2PC rollback we MUST rollback on the server
+    * but if we do this we cannot redeliver locally since then we might get the same message
+    * delievered twice. Therefore we must not redeliver locally.
+    * 
     */
    private void redeliverMessages(ClientTransaction ts) throws JMSException
    {
-      Collection sessionStates = ts.getSessionStates();
+      List sessionStates = ts.getSessionStates();
       
+      //Need to do this in reverse order
+      
+      Collections.reverse(sessionStates);
+      
       for (Iterator i = sessionStates.iterator(); i.hasNext();)
       {
          SessionTxState state = (SessionTxState)i.next();

Modified: trunk/src/main/org/jboss/jms/tx/TransactionRequest.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/TransactionRequest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/jms/tx/TransactionRequest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -30,7 +30,7 @@
 import org.jboss.messaging.util.Streamable;
 
 /**
- * This class contians all the data needed to perform a JMS transaction.
+ * This class contains all the data needed to perform a JMS transaction.
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * 

Modified: trunk/src/main/org/jboss/messaging/core/Channel.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -144,7 +144,10 @@
    
    boolean isActive();
    
-   List createDeliveries(List messageIds);
+   List recoverDeliveries(List messageIds);
+   
+   //This method will be defunct very soon when we remove the delivery list from inside the channel
+   void addDelivery(Delivery del);
 
 }
 

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -184,14 +184,8 @@
 
    public void cancel(Delivery d) throws Throwable
    {
-      // TODO We should also consider executing cancels on the event queue
-      synchronized (deliveryLock)
-      {
-         synchronized (refLock)
-         {
-            cancelInternal(d);
-         }
-      }      
+      // We put the cancellation on the event queue
+      this.executor.execute(new CancelRunnable(d));      
    }
 
    // Distributor implementation ------------------------------------
@@ -492,22 +486,20 @@
       }
    }
    
-   public List createDeliveries(List messageIds)
+   //This method will be defunct very soon when we remove the delivery list from inside the channel
+   public void addDelivery(Delivery del)
    {
+      synchronized (deliveryLock)
+      {
+         deliveries.add(del);
+      }
+   }
+   
+   public List recoverDeliveries(List messageIds)
+   {
       //debug
       Iterator iter = messageIds.iterator();
-      
-      log.info("***** createdeliveries:" + messageIds.size());
-      while (iter.hasNext())
-      {
-         Long l = (Long)iter.next();
-         
-         log.info("Creating delivery for " + l);
-      }
-      log.info("**** end dump");
-      
-      iter = messageIds.iterator();
-      
+                  
       List dels = new ArrayList();
       
       synchronized (refLock)
@@ -616,6 +608,8 @@
                   // Reference is not expired
 
                   // Attempt to push the ref to a receiver
+                  
+                  if (trace) { log.trace(this + " pushing " + ref); }                                  
 
                   Delivery del = router.handle(this, ref, null);
 
@@ -668,6 +662,8 @@
                               synchronized (deliveryLock)
                               {
                                  deliveries.add(del);
+                                 
+                                 if (trace) { log.trace(this + " starting to track  " + del); }
                               }
                            }
                         }
@@ -865,13 +861,17 @@
       return callback;
    }
 
-   
-   
+      
    protected boolean cancelInternal(Delivery del) throws Exception
    {
       if (trace) { log.trace(this + " cancelling " + del + " in memory"); }
 
-      boolean removed = deliveries.remove(del);      
+      boolean removed;
+      
+      synchronized (deliveryLock)
+      {
+         removed = deliveries.remove(del);      
+      }
 
       if (!removed)
       {         
@@ -886,7 +886,10 @@
       {
          MessageReference ref = del.getReference();
          
-         messageRefs.addFirst(ref, ref.getPriority());
+         synchronized (refLock)
+         {
+            messageRefs.addFirst(ref, ref.getPriority());
+         }
          
          //We may need to update the delivery count in the database
          if (ref.isReliable())
@@ -950,10 +953,14 @@
       {
          if (iter == null)
          {
+            if (trace) { log.trace(this + " removing first ref in memory"); } 
+            
             removeFirstInMemory();
          }
          else
          {
+            if (trace) { log.trace(this + " removed current message from iterator"); }                           
+                        
             iter.remove();                                
          }
       }
@@ -1275,7 +1282,29 @@
             }
          }
       }
-   }   
+   } 
+   
+   private class CancelRunnable implements Runnable
+   {
+      Delivery del;
+      
+      CancelRunnable(Delivery del)
+      {
+         this.del = del;
+      }
+      
+      public void run()
+      {
+         try
+         {
+            cancelInternal(del);
+         }
+         catch (Exception e)
+         {
+            log.error("Failed to cancel delivery", e);
+         }
+      }
+   }
 
    protected class HandleRunnable implements Runnable
    {

Modified: trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -249,8 +249,6 @@
             firstPagingOrder = nextPagingOrder = 0;
          }
          
-         log.info("Channel " + this.channelID + " loading " + ili.getRefInfos().size() + " references");
-         
          Map refMap = processReferences(ili.getRefInfos());
          
          Iterator iter = ili.getRefInfos().iterator();
@@ -373,23 +371,26 @@
    {
       if (trace) { log.trace(this + " cancelling " + del + " in memory"); }
 
-      boolean removed = super.cancelInternal(del);
-      
-      if (removed && paging)
-      {
-         // if paging and the in memory queue is exactly full we need to evict the end reference to storage to
-         // preserve the number of refs in the queue
-         if (messageRefs.size() == fullSize + 1)
+      synchronized (refLock)
+      {         
+         boolean removed = super.cancelInternal(del);
+         
+         if (removed && paging)
          {
-            MessageReference ref = (MessageReference)messageRefs.removeLast();
- 
-            addToDownCache(ref, true);
+            // if paging and the in memory queue is exactly full we need to evict the end reference to storage to
+            // preserve the number of refs in the queue
+            if (messageRefs.size() == fullSize + 1)
+            {
+               MessageReference ref = (MessageReference)messageRefs.removeLast();
+    
+               addToDownCache(ref, true);
+            }
          }
+               
+         if (trace) { log.trace(this + " added " + del.getReference() + " back into state"); }      
+         
+         return removed;
       }
-         
-      if (trace) { log.trace(this + " added " + del.getReference() + " back into state"); }      
-      
-      return removed;
    }
       
    protected MessageReference removeFirstInMemory() throws Exception

Modified: trunk/src/main/org/jboss/messaging/core/memory/SimpleMemoryManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/memory/SimpleMemoryManager.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/memory/SimpleMemoryManager.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -36,7 +36,7 @@
 {
    private static final Logger log = Logger.getLogger(SimpleMemoryManager.class);
    
-   private static final long DEFAULT_MEASURE_INTERVAL = 2000;
+   private static final long DEFAULT_MEASURE_INTERVAL = 3000;
    
    private static final int DEFAULT_FREE_MEMORY_PERCENT = 25;
        

Modified: trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -37,11 +37,13 @@
 import java.util.Collections;
 import java.util.Comparator;
 import java.util.HashMap;
+import java.util.HashSet;
 import java.util.Iterator;
 import java.util.LinkedHashMap;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
+import java.util.Set;
 
 import javax.sql.DataSource;
 import javax.transaction.TransactionManager;
@@ -58,6 +60,7 @@
 import org.jboss.messaging.core.message.MessageFactory;
 import org.jboss.messaging.core.message.MessageSupport;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
+import org.jboss.messaging.core.tx.PreparedTxInfo;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.core.tx.XidImpl;
@@ -72,6 +75,7 @@
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  *
  * @version <tt>1.1</tt>
  *
@@ -95,6 +99,9 @@
    
    private int maxParams;
    
+   private short orderCount;
+   
+   
    // Constructors --------------------------------------------------
     
    public JDBCPersistenceManager(DataSource ds, TransactionManager tm, Properties sqlProperties,
@@ -146,7 +153,7 @@
         
       //We can't remnove unreliable data since it might introduce holes into the paging order
       //removeUnreliableMessageData();
-        
+         
       log.debug(this + " started");
    }
    
@@ -157,6 +164,107 @@
    
    // PersistenceManager implementation -------------------------
    
+   // Related to XA Recovery
+   // ======================
+   
+   public List getMessageChannelPairRefsForTx(long transactionId) throws Exception
+   {
+      String sql = this.getSQLStatement("SELECT_MESSAGEID_FOR_REF");
+      return getMessageChannelPair(sql, transactionId);
+   }
+   
+   public List getMessageChannelPairAcksForTx(long transactionId) throws Exception
+   {
+      String sql = this.getSQLStatement("SELECT_MESSAGEID_FOR_ACK");
+      return getMessageChannelPair(sql, transactionId);
+   }
+   
+   public List retrievePreparedTransactions() throws Exception
+   {
+      /* Note the API change for 1.0.2 XA Recovery -- List now contains instances of PreparedTxInfo<TxId, Xid>
+       * instead of direct Xids [JPL] */
+      
+      Connection conn = null;
+      Statement st = null;
+      ResultSet rs = null;
+      PreparedTxInfo txInfo = null;
+      TransactionWrapper wrap = new TransactionWrapper();
+      
+      try
+      {
+         List transactions = new ArrayList();
+         
+         conn = ds.getConnection();
+         
+         st = conn.createStatement();
+         
+         String sql = this.getSQLStatement("SELECT_PREPARED_TRANSACTIONS");
+         
+         rs = st.executeQuery(sql);
+         
+         while (rs.next())
+         {
+            //get the existing tx id --MK START
+            long txId = rs.getLong(1);
+            
+            byte[] branchQual = rs.getBytes(2);
+            int formatId = rs.getInt(3);
+            byte[] globalTxId = rs.getBytes(4);
+            Xid xid = new XidImpl(branchQual, formatId, globalTxId);
+            
+            // create a tx info object with the result set detailsdetails
+            txInfo = new PreparedTxInfo(txId, xid);
+            transactions.add(txInfo);
+         }
+         
+         return transactions;
+         
+      }
+      catch (Exception e)
+      {
+         wrap.exceptionOccurred();
+         throw e;
+      }
+      finally
+      {
+         if (rs != null)
+         {
+            try
+            {
+               rs.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (st != null)
+         {
+            try
+            {
+               st.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         wrap.end();
+      }
+   }
+   
+   
+   
+   
+      
    // Related to counters
    // ===================
    
@@ -1181,7 +1289,7 @@
       PreparedStatement ps = null;
       ResultSet rs = null;
       TransactionWrapper wrap = new TransactionWrapper();
-      
+                                
       try
       {
          conn = ds.getConnection();         
@@ -1209,6 +1317,12 @@
             maxOrdering = null;
          }
          
+         //For unpaged refs we must make sure we only load refs with state='C' - i.e.
+         //they're not part of an XA transactions.
+         //Otherwise we could end up loading message that hadn't be committed
+         //or end up loading refs which are due to be acked by a transaction that's yet
+         //to be recovered.
+         
          ps = conn.prepareStatement(getSQLStatement("LOAD_UNPAGED_REFS"));
          
          ps.setLong(1, channelID);
@@ -1574,77 +1688,7 @@
       }
    }
    
-     
-   public List retrievePreparedTransactions() throws Exception
-   {
-      Connection conn = null;
-      Statement st = null;
-      ResultSet rs = null;
-      TransactionWrapper wrap = new TransactionWrapper();
-      
-      try
-      {
-         List transactions = new ArrayList();
-         
-         conn = ds.getConnection();
-         
-         st = conn.createStatement();
-         rs = st.executeQuery(getSQLStatement("SELECT_PREPARED_TRANSACTIONS"));
-         
-         while (rs.next())
-         {
-            byte[] branchQual = rs.getBytes(2);
-            int formatId = rs.getInt(3);
-            byte[] globalTxId = rs.getBytes(4);
-            Xid xid = new XidImpl(branchQual, formatId, globalTxId);
-            
-            transactions.add(xid);
-         }
-         
-         return transactions;
-         
-      }
-      catch (Exception e)
-      {
-         wrap.exceptionOccurred();
-         throw e;
-      }
-      finally
-      {
-         if (rs != null)
-         {
-            try
-            {
-               rs.close();
-            }
-            catch (Throwable e)
-            {
-            }
-         }
-         if (st != null)
-         {
-            try
-            {
-               st.close();
-            }
-            catch (Throwable e)
-            {
-            }
-         }
-         if (conn != null)
-         {
-            try
-            {
-               conn.close();
-            }
-            catch (Throwable e)
-            {
-            }
-         }
-         wrap.end();
-      }
-   }
-   
+           
    public boolean referenceExists(long channelID, long messageID) throws Exception
    {
       Connection conn = null;
@@ -2811,6 +2855,8 @@
    protected void commitPreparedTransaction(Transaction tx, Connection conn) throws Exception
    {
       PreparedStatement ps = null;
+      
+      if (trace) { log.trace(this + " commitPreparedTransaction, tx= " + tx); }
         
       try
       {
@@ -2833,7 +2879,7 @@
          
          if (trace)
          {
-            log.trace(JDBCUtil.statementToString(getSQLStatement("COMMIT_MESSAGE_REF2"), null, new Long(tx.getId())) + " updated " + rows
+            log.trace(JDBCUtil.statementToString(getSQLStatement("COMMIT_MESSAGE_REF2"), new Long(tx.getId())) + " updated " + rows
                   + " row(s)");
          }
          
@@ -2880,7 +2926,7 @@
          
          if (trace)
          {
-            log.trace(JDBCUtil.statementToString(getSQLStatement("ROLLBACK_MESSAGE_REF2"), null, new Long(tx.getId())) + " updated " + rows
+            log.trace(JDBCUtil.statementToString(getSQLStatement("ROLLBACK_MESSAGE_REF2"), new Long(tx.getId())) + " updated " + rows
                   + " row(s)");
          }
          
@@ -3248,8 +3294,8 @@
               "SELECT MESSAGEID, DELIVERYCOUNT, PAGE_ORD, RELIABLE FROM JMS_MESSAGE_REFERENCE " +
               "WHERE CHANNELID = ? AND PAGE_ORD BETWEEN ? AND ? ORDER BY PAGE_ORD");
       map.put("LOAD_UNPAGED_REFS",
-              "SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE " +
-              "WHERE PAGE_ORD IS NULL and CHANNELID = ? ORDER BY ORD");
+              "SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE STATE = 'C' " +
+              "AND CHANNELID = ? AND PAGE_ORD IS NULL ORDER BY ORD");
       map.put("UPDATE_RELIABLE_REFS_NOT_PAGED", "UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?");       
       map.put("SELECT_MIN_MAX_PAGE_ORD", "SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?");
       map.put("SELECT_EXISTS_REF", "SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?");
@@ -3276,6 +3322,9 @@
               "VALUES(?, ?, ?, ?)");
       map.put("DELETE_TRANSACTION", "DELETE FROM JMS_TRANSACTION WHERE TRANSACTIONID = ?");
       map.put("SELECT_PREPARED_TRANSACTIONS", "SELECT TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JMS_TRANSACTION");
+      map.put("SELECT_MESSAGEID_FOR_REF", "SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'");
+      map.put("SELECT_MESSAGEID_FOR_ACK", "SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'");
+      
       //Counter
       map.put("UPDATE_COUNTER", "UPDATE JMS_COUNTER SET NEXT_ID = ? WHERE NAME=?");
       map.put("SELECT_COUNTER", "SELECT NEXT_ID FROM JMS_COUNTER WHERE NAME=?");
@@ -3287,7 +3336,132 @@
    
    // Private -------------------------------------------------------
    
-   private short orderCount;
+   private List getMessageChannelPair(String sqlQuery, long transactionId) throws Exception
+   {
+      if (trace) log.trace("loading message and channel ids for tx [" + transactionId + "]");
+      
+      Connection conn = null;
+      PreparedStatement ps = null;
+      ResultSet rs = null;
+      TransactionWrapper wrap = new TransactionWrapper();
+      
+      try
+      {
+         conn = ds.getConnection();
+         
+         ps = conn.prepareStatement(sqlQuery);
+         
+         ps.setLong(1, transactionId);
+         
+         rs = ps.executeQuery();
+         
+         //Don't use a Map. A message could be in multiple channels in a tx, so if you use a map
+         //when you put the same message again it's going to overwrite the previous put!!
+         
+         List holders = new ArrayList();
+         
+         //Unique set of messages
+         Set msgIds = new HashSet();
+         
+         //TODO it would probably have been simpler just to have done all this in a SQL JOIN rather
+         //than do the join in memory.....
+         
+         class Holder
+         {
+            long messageId;
+            long channelId;
+            Holder(long messageId, long channelId)
+            {
+               this.messageId = messageId;
+               this.channelId = channelId;
+            }
+         }
+                  
+         while(rs.next())
+         {            
+            long messageId = rs.getLong(1);
+            long channelId = rs.getLong(2);
+            
+            Holder holder = new Holder(messageId, channelId);
+            
+            holders.add(holder);
+                        
+            msgIds.add(new Long(messageId));
+            
+            if (trace) log.trace("Loaded MsgID: " + messageId + " and ChannelID: " + channelId);
+         }
+         
+         Map messageMap = new HashMap();
+         
+         List messages = getMessages(new ArrayList(msgIds));
+         
+         for (Iterator iter = messages.iterator(); iter.hasNext(); )
+         {
+            Message msg = (Message)iter.next();
+            
+            messageMap.put(new Long(msg.getMessageID()), msg);            
+         }
+         
+         List returnList = new ArrayList();
+         
+         for (Iterator iter = holders.iterator(); iter.hasNext(); )
+         {
+            Holder holder = (Holder)iter.next();
+            
+            Message msg = (Message)messageMap.get(new Long(holder.messageId));
+            
+            if (msg == null)
+            {
+               throw new IllegalStateException("Cannot find message " + holder.messageId);
+            }
+            
+            MessageChannelPair pair = new MessageChannelPair(msg, holder.channelId);
+            
+            returnList.add(pair);
+         }
+         
+         return returnList;
+      }
+      catch (Exception e)
+      {
+         wrap.exceptionOccurred();
+         throw e;
+      }
+      finally
+      {
+         if (rs != null)
+         {
+            try
+            {
+               rs.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (ps != null)
+         {
+            try
+            {
+               ps.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         if (conn != null)
+         {
+            try
+            {
+               conn.close();
+            }
+            catch (Throwable e)
+            {
+            }
+         }
+         wrap.end();
+      }
+   }
    
    private synchronized long getOrdering()
    {

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/ClusteredPostOffice.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -61,7 +61,5 @@
     */
    Binding unbindClusteredQueue(String queueName) throws Throwable;
 
-   Collection listAllBindingsForCondition(Condition condition) throws Exception;
-
-   Binding getBindingforChannelId(long channelId) throws Exception;
+   Collection listAllBindingsForCondition(Condition condition) throws Exception;   
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -22,7 +22,9 @@
 package org.jboss.messaging.core.plugin.contract;
 
 import java.util.List;
+import java.util.Map;
 
+import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.tx.Transaction;
 
@@ -31,6 +33,9 @@
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ *
  * @version <tt>1.1</tt>
  *
  * PersistenceManager.java,v 1.1 2006/02/22 17:33:42 timfox Exp
@@ -43,10 +48,14 @@
    
    void updateDeliveryCount(long channelID, MessageReference ref) throws Exception;
    
-
    // XA Recovery functionality
    
    List retrievePreparedTransactions() throws Exception;
+   
+   List getMessageChannelPairRefsForTx(long transactionId) throws Exception;
+
+   List getMessageChannelPairAcksForTx(long transactionId) throws Exception;
+
       
    // Paging functionality - TODO we should split this out into its own interface
 
@@ -75,6 +84,30 @@
    // Interface value classes
    //---------------------------------------------------------------
    
+   class MessageChannelPair
+   {
+      private Message message;
+      
+      private long channelId;
+      
+      public MessageChannelPair(Message message, long channelId)
+      {
+         this.message = message;
+         
+         this.channelId = channelId;
+      }
+      
+      public Message getMessage()
+      {
+         return message;
+      }
+      
+      public long getChannelId()
+      {
+         return channelId;
+      }
+   }
+   
    class ReferenceInfo
    {
       private long messageId;
@@ -107,7 +140,6 @@
          return reliable;
       }
    }
-   
    class InitialLoadInfo
    {
       private Long minPageOrdering;

Modified: trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/contract/PostOffice.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -89,4 +89,6 @@
     * @return true if it is a non clustered post office
     */
    boolean isLocal();
+   
+   Binding getBindingforChannelId(long channelId) throws Exception;
 }

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/DefaultPostOffice.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -58,7 +58,7 @@
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
-import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.ReentrantWriterPreferenceReadWriteLock;
 
 /**
  * 
@@ -117,7 +117,7 @@
    {            
       super (ds, tm, sqlProperties, createTablesOnStartup);
       
-      lock = new WriterPreferenceReadWriteLock();
+      lock = new ReentrantWriterPreferenceReadWriteLock();
       
       nameMaps = new LinkedHashMap();
        
@@ -386,6 +386,40 @@
    {
       return true;
    }
+   
+   public Binding getBindingforChannelId(long channelId) throws Exception
+   {
+      lock.readLock().acquire();
+      
+      try
+      {         
+         Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
+   
+         if (nameMap == null)
+         {
+            throw new IllegalStateException("Cannot find name map for current node " + currentNodeId);
+         }
+         
+         Binding binding = null;
+         
+         for (Iterator iterbindings = nameMap.values().iterator(); iterbindings.hasNext();)
+         {
+            Binding itemBinding = (Binding)iterbindings.next();
+            
+            if (itemBinding.getQueue().getChannelID() == channelId)
+            {
+               binding = itemBinding;
+               break;
+            }
+         }
+         
+         return binding;
+      }
+      finally
+      {
+         lock.readLock().release();
+      }      
+   }
      
    // Protected -----------------------------------------------------
    

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOffice.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -542,25 +542,7 @@
 
          if (binding == null)
          {
-            //Not found in the failed map - look in the name map
-            Map nameMap = (Map)nameMaps.get(new Integer(currentNodeId));
-
-            if (nameMap != null)
-            {
-               for (Iterator iterbindings = nameMap.values().iterator(); iterbindings.hasNext();)
-               {
-                  Binding itemBinding = (Binding)iterbindings.next();
-                  if (itemBinding.getQueue().getChannelID() == channelId)
-                  {
-                     binding = itemBinding;
-                     break;
-                  }
-               }
-            }
-            else
-            {
-               log.info("nameMap is null");
-            }
+            binding = super.getBindingforChannelId(channelId);
          }
          log.info("Returned " + binding);
          return binding;

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -237,7 +237,7 @@
       throw new UnsupportedOperationException();
    }
 
-   public List createDeliveries(List messageIds)
+   public List recoverDeliveries(List messageIds)
    {
       throw new UnsupportedOperationException();
    }
@@ -288,6 +288,11 @@
       return "RemoteQueueStub[" + channelID + "/" + name + " -> " + nodeID + "]";
    }
 
+   public void addDelivery(Delivery del)
+   {
+      throw new UnsupportedOperationException();
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------

Copied: trunk/src/main/org/jboss/messaging/core/tx/PreparedTxInfo.java (from rev 1823, branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/PreparedTxInfo.java)

Modified: trunk/src/main/org/jboss/messaging/core/tx/Transaction.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/Transaction.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/tx/Transaction.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -52,15 +52,17 @@
    
    private boolean trace = log.isTraceEnabled();
      
-   protected long id;
+   private long id;
    
-   protected int state;
+   private int state;
    
-   protected Xid xid;
+   private Xid xid;
    
-   protected List callbacks;
+   private List callbacks;
    
-   protected Map callbackMap;
+   private Map callbackMap;
+   
+   private boolean loadedAtStartup;
       
    
    /**
@@ -225,7 +227,7 @@
       
       firstCallback = null;
       
-      if (repository !=null)
+      if (repository != null)
       {
          repository.deleteTransaction(this);
       }
@@ -344,6 +346,21 @@
    {
       return id;
    }
+   
+   public boolean isLoadedAtStartup()
+   {
+      return this.loadedAtStartup;
+   }
+   
+   public void setLoadedAtStartup(boolean loadedAtStartup)
+   {
+      this.loadedAtStartup = loadedAtStartup;
+   }
+   
+   public void setState(int state)
+   {
+      this.state = state;
+   }
       
    public String toString()
    {

Modified: trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -29,17 +29,27 @@
 import javax.transaction.xa.Xid;
 
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Delivery;
+import org.jboss.messaging.core.Message;
+import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.Queue;
+import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.IDManager;
+import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
+import org.jboss.messaging.core.plugin.contract.PostOffice;
+import org.jboss.messaging.core.plugin.postoffice.Binding;
 
 import EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap;
 
-
 /**
  * This class maintains JMS Server local transactions.
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:Konda.Madhu at uk.mizuho-sc.com">Madhu Konda</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ *
  * @version $Revision 1.1 $
  *
  * $Id$
@@ -57,22 +67,38 @@
    private Map globalToLocalMap;     
    
    private PersistenceManager persistenceManager;
+
+   protected MessageStore messageStore;
+
+   private IDManager idManager;
    
-   private IDManager idManager;
-
+   private PostOffice postOffice;
+   
    // Static --------------------------------------------------------
    
    // Constructors --------------------------------------------------
    
-   public TransactionRepository(PersistenceManager persistenceManager, IDManager idManager)
+   public TransactionRepository(PersistenceManager persistenceManager, MessageStore store, IDManager idManager)
    {
       this.persistenceManager = persistenceManager;
       
+      this.messageStore = store;
+      
       this.idManager = idManager;
-   
+      
       globalToLocalMap = new ConcurrentReaderHashMap();           
    }
    
+   // Injection ----------------------------------------
+   
+   //Unfortunately we have to do this for now, since PostOffice is not started until after this is constructed
+   //We will sort out dependencies properly when we go to the micro container
+   public void injectPostOffice(PostOffice po)
+   {
+      postOffice = po;
+   }
+   
+
    // MessagingComponent implementation --------------------------------
    
    public void start() throws Exception
@@ -80,6 +106,8 @@
       //NOOP
    }
    
+   // Public --------------------------------------------------------
+      
    public void stop() throws Exception
    {
       //NOOP
@@ -87,53 +115,94 @@
    
    // Public --------------------------------------------------------   
 
-   public List getPreparedTransactions()
+   /**
+    * Attempts to recover existing prepared transactions by redelivering unhandled messages and acknowledgements
+    * on the appropriate channels.
+    *
+    * @return  List of Xid instances
+    */
+   public synchronized List recoverPreparedTransactions()
    {
+      if (trace) { log.trace(this + " recoverPreparedTransactions()"); }
+      
       ArrayList prepared = new ArrayList();
-      
+
       Iterator iter = globalToLocalMap.values().iterator();
-      
+
       while (iter.hasNext())
       {
-         Transaction tx = (Transaction)iter.next();
-         
-         if (tx.xid != null && tx.getState() == Transaction.STATE_PREPARED)
+         Transaction tx = (Transaction) iter.next();
+
+         if (tx.getXid() != null && tx.getState() == Transaction.STATE_PREPARED)
          {
+            try
+            {
+               if (trace) log.trace("Loading and handling refs and acks to the Tx "+tx);
+
+               //The transaction might have been created, prepared, without the server crashing
+               //in which case the tx will already have the references and acks in them
+               //in this case we DO NOT want to replay them again, since they will end up in the transaction state
+               //twice
+               //In other words we only want to replay acks and sends if this tx was loaded at startup
+               if (tx.isLoadedAtStartup())
+               {
+                  handleReferences(tx);
+                  handleAcks(tx);
+                  
+                  tx.setLoadedAtStartup(false);
+               }
+            }
+            catch (Exception e)
+            {
+               log.warn("Failed to replay transaction (XID: " + tx.getXid() + ", LocalID: " + tx.getId() + ") during recovery.", e);
+            }
+
             prepared.add(tx.getXid());
          }
       }
+
       return prepared;
    }
-   
+
    /*
-    * Load any prepared transactions into the repository so they can be recovered
+    * Load any prepared transactions into the repository so they can be
+    * recovered
     */
    public void loadPreparedTransactions() throws Exception
    {
+      if (trace) log.trace("load prepared transactions...");
+
       List prepared = null;
-            
+
       prepared = persistenceManager.retrievePreparedTransactions();
-      
+
+      if (trace) log.trace ("Found " + prepared.size() + " transactions in prepared state:");
+
       if (prepared != null)
-      {         
+      {
          Iterator iter = prepared.iterator();
-         
+
          while (iter.hasNext())
          {
-            Xid xid = (Xid)iter.next();
+            PreparedTxInfo txInfo = (PreparedTxInfo) iter.next();
+
+            if (trace) log.trace("Reinstating TX(XID: " + txInfo.getXid() + ", LocalId " + txInfo.getTxId() +")");
             
-            Transaction tx = createTransaction(xid);   
+            Transaction tx = createTransaction(txInfo);
             
-            tx.state = Transaction.STATE_PREPARED;
+            tx.setState(Transaction.STATE_PREPARED);
             
-            //Load the references for this transaction
+            tx.setLoadedAtStartup(true);
+            
          }
       }
    }
-         
+
+
    public Transaction getPreparedTx(Xid xid) throws Exception
    {
       Transaction tx = (Transaction)globalToLocalMap.get(xid);
+
       if (tx == null)
       {
          throw new TransactionException("Cannot find local tx for xid:" + xid);
@@ -159,7 +228,7 @@
 	   {
 		   throw new TransactionException("Transaction with xid " + id + " can't be removed as it's not yet commited or rolledback: (Current state is " + Transaction.stateToString(state));
 	   }
-	   
+      
 	   globalToLocalMap.remove(id);	   
    }
    
@@ -186,7 +255,7 @@
 
       return tx;
    }
-   
+
    public boolean removeTransaction(Xid xid)
    {
       return globalToLocalMap.remove(xid) != null;
@@ -203,7 +272,220 @@
    // Protected -----------------------------------------------------         
    
    // Private -------------------------------------------------------
+
+	/**
+	 * Load the references and invoke the channel to handle those refs
+	 */
+	private void handleReferences(Transaction tx) throws Exception
+   {
+      if (trace) log.trace("Handle references for TX(XID: " + tx.getXid() + ", LocalID: " + tx.getId()+ "):");
+
+      long txId = tx.getId();
+
+		List pairs = persistenceManager.getMessageChannelPairRefsForTx(txId);
+
+      if (trace) log.trace("Found " + pairs.size() + " unhandled references.");
+
+      for (Iterator iter = pairs.iterator(); iter.hasNext();)
+      {
+         PersistenceManager.MessageChannelPair pair = (PersistenceManager.MessageChannelPair)iter.next();
+         
+         Message msg = pair.getMessage();
+         
+         long channelID = pair.getChannelId();
+         
+         MessageReference ref = null;
+         
+         try
+         {
+            ref = messageStore.reference(msg);         
+
+            //Need to get the post office reference lazily, cannot pass into constructor
+            Binding binding = postOffice.getBindingforChannelId(channelID);
+            
+            if (binding == null)
+            {
+               throw new IllegalStateException("Cannot find binding for channel id " + channelID);
+            }
+            
+            Queue queue = binding.getQueue();
+                        
+            if (trace) log.trace("Destination for message[ID=" + ref.getMessageID() + "] is: " + queue);
    
+            queue.handle(null, ref, tx);
+         }
+         finally
+         {
+            if (ref != null)
+            {
+               //Need to release reference
+               ref.releaseMemoryReference();
+            }
+         }
+		}
+	}
+
+	/**
+	 * Load the acks and acknowledge them
+	 */
+	private void handleAcks(Transaction tx) throws Exception
+   {
+      long txId = tx.getId();
+      
+      List pairs = persistenceManager.getMessageChannelPairAcksForTx(txId);
+
+      if (trace) log.trace("Found " + pairs.size() + " unhandled acks.");
+      
+      List dels = new ArrayList();
+
+      for (Iterator iter = pairs.iterator(); iter.hasNext();)
+      {
+         PersistenceManager.MessageChannelPair pair = (PersistenceManager.MessageChannelPair)iter.next();
+         
+         Message msg = pair.getMessage();
+         
+         long channelID = pair.getChannelId();
+         
+         MessageReference ref = null;
+         
+         try
+         {
+            ref = messageStore.reference(msg);         
+
+            // Need to get the post office reference lazily, cannot pass into constructor
+            Binding binding = postOffice.getBindingforChannelId(channelID);
+            
+            if (binding == null)
+            {
+               throw new IllegalStateException("Cannot find binding for channel id " + channelID);
+            }
+            
+            Queue queue = binding.getQueue();
+   
+            if (trace) log.trace("Destination for message[ID=" + ref.getMessageID() + "] is: " + queue);
+   
+            //Create a new delivery - note that it must have a delivery observer otherwise acknowledge will fail
+            Delivery del = new SimpleDelivery(queue, ref);
+
+            if (trace) log.trace("Acknowledging..");
+
+            try
+            {
+               //At this point there won't be a delivery in the channel for this ref - since
+               //we won't have loaded it when the queue was loaded (since the stat column would have been '-')
+               //so we add it
+               
+               queue.addDelivery(del);
+               
+               del.acknowledge(tx);
+            }
+            catch (Throwable t)
+            {
+               log.error("Failed to acknowledge " + del + " during recovery", t);
+            }
+            
+            dels.add(del);            
+         }
+         finally
+         {
+            if (ref != null)
+            {
+               //Need to release reference
+               ref.releaseMemoryReference();
+            }
+         }
+      }
+      
+      if (!dels.isEmpty())
+      {
+         //Add a callback so these dels get cancelled on rollback
+         tx.addCallback(new CancelCallback(dels), this);
+      }
+      
+   }         
+      
+	/**
+	 * Creates a prepared transaction
+	 *
+	 * @param txInfo
+	 * @return
+	 * @throws Exception
+	 */
+	private Transaction createTransaction(PreparedTxInfo txInfo) throws Exception
+   {
+		if (globalToLocalMap.containsKey(txInfo.getXid()))
+      {
+			throw new TransactionException(
+					"There is already a local tx for global tx "	+ txInfo.getXid());
+		}
+
+		// Resurrected tx
+		Transaction tx = new Transaction(txInfo.getTxId(), txInfo.getXid(), this);
+
+		if (trace) {
+			log.trace("created transaction " + tx);
+		}
+
+		globalToLocalMap.put(txInfo.getXid(), tx);
+
+		return tx;
+	}
+
    // Inner classes -------------------------------------------------
    
+   private class CancelCallback implements TxCallback
+   {
+      private List toCancel;
+      
+      private CancelCallback(List toCancel)
+      {
+         this.toCancel = toCancel;
+      }
+
+      public void afterCommit(boolean onePhase) throws Exception
+      {
+      }
+
+      public void afterPrepare() throws Exception
+      {
+      }
+
+      public void afterRollback(boolean onePhase) throws Exception
+      {
+         //On rollback we need to cancel the ref back into the channel
+         //We only need to do this if the tx was reloaded since otherwise the
+         //cancel will come from the SCE
+         
+         //Need to cancel in reverse
+         
+         for (int i = toCancel.size() - 1; i >= 0; i--)
+         {                     
+            Delivery del = (Delivery)toCancel.get(i);
+            
+            try
+            {
+               del.cancel();
+            }
+            catch (Throwable t)
+            {
+               log.error("Failed to cancel delivery", t);
+               throw new TransactionException(t.getMessage(), t);
+            }
+         }
+      }
+
+      public void beforeCommit(boolean onePhase) throws Exception
+      {
+      }
+
+      public void beforePrepare() throws Exception
+      {
+      }
+
+      public void beforeRollback(boolean onePhase) throws Exception
+      {
+      }
+      
+   }
+   
 }
\ No newline at end of file

Modified: trunk/src/main/org/jboss/messaging/core/tx/XidImpl.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/XidImpl.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/src/main/org/jboss/messaging/core/tx/XidImpl.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,6 +21,8 @@
   */
 package org.jboss.messaging.core.tx;
 
+import java.io.Serializable;
+
 import javax.transaction.xa.Xid;
 
 /**
@@ -29,11 +31,14 @@
  * 
  * @author <a href="mailto:adrian at jboss.org>Adrian Brock</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * 
  * @version $Revision 1.1 $
  */
-public class XidImpl implements Xid
+public class XidImpl implements Xid, Serializable
 {
+   private static final long serialVersionUID = -1893120702576869245L;
+
    protected byte[] branchQualifier;
    
    protected int formatId;
@@ -57,6 +62,11 @@
       return globalTransactionId;
    }
    
+   //For serialization
+   public XidImpl()
+   {      
+   }
+   
    public XidImpl(byte[] branchQualifier, int formatId, byte[] globalTransactionId)
    {
       this.branchQualifier = branchQualifier;
@@ -118,4 +128,11 @@
       return true;
    }
 
+   public String toString()
+   {
+      return getClass().getName() + "(GID: " + new String(getGlobalTransactionId()) +
+                                    ", Branch: " + new String(getBranchQualifier()) +
+                                    ", Format: " + getFormatId() + ")";
+   }
+
 }

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/build.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -191,6 +191,7 @@
       <path refid="test.compilation.classpath"/>
       <path refid="dom4j.dom4j.classpath"/>
       <path refid="apache.log4j.classpath"/>
+      <path refid="apache.logging.classpath"/>
       <path refid="apache.xerces.classpath"/>
       <path refid="jboss.mbeans.classpath"/>
       <path refid="jboss.naming.classpath"/>
@@ -410,6 +411,52 @@
       </junit>
    </target>
 
+   <target name="local-jms-tests" depends="tests-jar, prepare-testdirs, clear-test-logs"
+           description="Runs all available tests an in-VM configuration">
+
+      <echo message=""/>
+      <echo message="Running invm tests, fork=${junit.fork}, junit.batchtest.fork=${junit.batchtest.fork}"/>
+      <echo message=""/>
+
+      <junit printsummary="${junit.printsummary}"
+             fork="${junit.fork}"
+             includeantruntime="${junit.includeantruntime}"
+             haltonerror="${junit.haltonerror}"
+             haltonfailure="${junit.haltonfailure}"
+             showoutput="${junit.showoutput}"
+             timeout="${junit.timeout}">
+
+         <sysproperty key="remote" value="false"/>
+         <sysproperty key="module.output" value="${tests.output}"/>
+         <sysproperty key="test.bind.address" value="${test.bind.address}"/>
+         <sysproperty key="test.database" value="${functional.tests.database}"/>
+         <sysproperty key="test.serialization" value="${functional.tests.serialization}"/>
+         <sysproperty key="test.logfile.suffix" value="invm"/>
+         <sysproperty key="build.lib" value="${build.lib}"/>
+         <jvmarg value="-Xmx512M"/>
+         <!--
+         <jvmarg line="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_shmem,server=y,suspend=y,address=antjunit"/>
+         -->
+         <classpath refid="test.execution.classpath"/>
+         <formatter type="xml" usefile="${junit.formatter.usefile}"/>
+         <batchtest fork="${junit.batchtest.fork}"
+                    todir="${junit.batchtest.todir}"
+                    haltonfailure="${junit.batchtest.haltonfailure}"
+                    haltonerror="${junit.batchtest.haltonerror}">
+            <formatter type="plain" usefile="${junit.formatter.usefile}"/>
+            <fileset dir="${build.tests.classes}">
+               <include name="**/messaging/jms/**/*Test.class"/>
+               <exclude name="**/jms/stress/**"/>
+               <exclude name="**/jms/crash/*Test.class"/>
+               <exclude name="**/jms/MemLeakTest.class"/>
+               <exclude name="**/jms/manual/**/*Test.class"/>
+               <exclude name="**/jms/clustering/*Test.class"/>
+               <exclude name="**/jms/RemotingConnectionConfigurationTest.class"/>
+            </fileset>
+         </batchtest>
+      </junit>
+   </target>
+
    <target name="memory-leak-tests" depends="tests-jar, prepare-testdirs, clear-test-logs"
            description="Runs memory-leak tests using JBossProfiler in-VM configuration">
 
@@ -772,7 +819,7 @@
                <!--
                    <include name="**/jms/clustering/FailoverTest.class"/>
                -->
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/HATest.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: trunk/tests/smoke/build.xml
===================================================================
--- trunk/tests/smoke/build.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/smoke/build.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -77,6 +77,7 @@
 
       <!-- 4.0.0, 4.0.1 NOT SUPPORTED -->
 
+<<<<<<< .working
       <!--
           Note on installer versions.
           When installing versions to test via the JBoss installer, make sure call by value is *not*
@@ -84,17 +85,51 @@
           the arrangement where JBoss is configured for all pass by reference
       -->
 
+=======
+      <!--
+           4.0.1sp1
+      -->
+
+>>>>>>> .merge-right.r1823
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss401sp1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.2
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss402.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
+<<<<<<< .working
+=======
+<!--
+      <!--
+           4.0.3
+      -->
 
       <antcall target="installation-test">
+         <param name="jboss.home" value="${jboss403.home}"/>
+         <param name="run.secure-socket.example" value="false"/>
+      </antcall>
+>>>>>>> .merge-right.r1823
+
+      <antcall target="installation-test">
+<<<<<<< .working
+=======
+         <param name="jboss.home" value="${jboss403-installer.home}"/>
+         <param name="run.secure-socket.example" value="false"/>
+      </antcall>
+-->
+      <!--
+           4.0.3SP1
+      -->
+
+      <antcall target="installation-test">
+>>>>>>> .merge-right.r1823
          <param name="jboss.home" value="${jboss403SP1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
@@ -112,6 +147,10 @@
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
 
+      <!--
+           4.0.4.GA
+      -->
+
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss404GA.home}"/>
       </antcall>
@@ -127,12 +166,44 @@
          <param name="run.stateless.example" value="false"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
+<<<<<<< .working
+=======
+<!--
+      <!--
+           4.0.5.GA
+      -->
 
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss405GA.home}"/>
       </antcall>
+>>>>>>> .merge-right.r1823
+                                                                                                <!--
+      <antcall target="installation-test">
+<<<<<<< .working
+=======
+         <param name="jboss.home" value="${jboss405GA-installer.home}"/>
+      </antcall>
+                                                                                                 -->
+      <antcall target="installation-test">
+         <param name="jboss.home" value="${jboss405GA.home}"/>
+         <param name="release.admin.target" value="standalone"/>
+         <param name="run.mdb.example" value="false"/>
+         <param name="run.stateless.example" value="false"/>
+         <param name="run.secure-socket.example" value="false"/>
+      </antcall>
 
       <antcall target="installation-test">
+         <param name="jboss.home" value="${jboss405GAejb3.home}"/>
+         <param name="no.java4" value="true"/>
+         <param name="run.ejb3mdb.example" value="true"/>
+      </antcall>
+-->
+      <antcall target="installation-test">
+>>>>>>> .merge-right.r1823
+         <param name="jboss.home" value="${jboss405GA.home}"/>
+      </antcall>
+
+      <antcall target="installation-test">
          <param name="jboss.home" value="${jboss405GA-installer.home}"/>
       </antcall>
 

Modified: trunk/tests/src/org/jboss/test/messaging/MessagingTestCase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/MessagingTestCase.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/MessagingTestCase.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,6 +21,9 @@
 */
 package org.jboss.test.messaging;
 
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+
 import javax.jms.Connection;
 import javax.jms.ConnectionFactory;
 import javax.jms.Destination;
@@ -28,11 +31,15 @@
 import javax.jms.MessageConsumer;
 import javax.jms.Session;
 import javax.jms.Topic;
+import javax.naming.InitialContext;
+import javax.sql.DataSource;
+import javax.transaction.TransactionManager;
 
 import junit.framework.TestCase;
 
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.tm.TransactionManagerService;
 
 /**
  * The base case for messaging tests.
@@ -40,6 +47,8 @@
  * @author <a href="mailto:adrian at jboss.org">Adrian Brock</a>
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.org">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ *
  * @version <tt>$Revision$</tt>
  * $Id$
  */
@@ -47,6 +56,11 @@
 {
    // Constants -----------------------------------------------------
 
+   public final static int MAX_TIMEOUT = 1000 * 10 /* seconds */;
+
+   public final static int MIN_TIMEOUT = 1000 * 1 /* seconds */;
+   
+
    // Static --------------------------------------------------------
    
    // Attributes ----------------------------------------------------
@@ -144,8 +158,118 @@
          if (conn!= null) conn.close();
       }
    }
+   
+   protected boolean checkNoBindingData() throws Exception
+   {
+      InitialContext ctx = new InitialContext();
 
+      TransactionManager mgr = (TransactionManager)ctx.lookup(TransactionManagerService.JNDI_NAME);
+      DataSource ds = (DataSource)ctx.lookup("java:/DefaultDS");
+      
+      javax.transaction.Transaction txOld = mgr.suspend();
+      mgr.begin();
+      
+      java.sql.Connection conn = null;
+      
+      PreparedStatement ps = null;
+      
+      ResultSet rs = null;
 
+      try
+      {
+         conn = ds.getConnection();
+         String sql = "SELECT * FROM JMS_POSTOFFICE";
+         ps = conn.prepareStatement(sql);
+         
+         rs = ps.executeQuery();
+         
+         return rs.next();
+      }
+      finally
+      {
+         if (rs != null) rs.close();
+         
+         if (ps != null) ps.close();
+         
+         if (conn != null) conn.close();
+         
+         mgr.commit();
+
+         if (txOld != null)
+         {
+            mgr.resume(txOld);
+         }
+                  
+      } 
+   }
+   
+   protected boolean checkNoMessageData() throws Exception
+   {
+      //Can't do this remotely
+      
+      if (ServerManagement.isRemote())
+      {
+         return false;
+      }
+      
+      InitialContext ctx = new InitialContext();
+
+      TransactionManager mgr = (TransactionManager)ctx.lookup(TransactionManagerService.JNDI_NAME);
+      DataSource ds = (DataSource)ctx.lookup("java:/DefaultDS");
+      
+      javax.transaction.Transaction txOld = mgr.suspend();
+      mgr.begin();
+      
+      java.sql.Connection conn = null;
+      
+      PreparedStatement ps = null;
+      
+      ResultSet rs = null;
+
+      try
+      {
+         conn = ds.getConnection();
+         String sql = "SELECT * FROM JMS_MESSAGE_REFERENCE";
+         ps = conn.prepareStatement(sql);
+         
+         rs = ps.executeQuery();
+         
+         boolean exists = rs.next();
+         
+         if (!exists)
+         {
+            rs.close();
+            
+            ps.close();
+            
+            ps = conn.prepareStatement("SELECT * FROM JMS_MESSAGE");
+            
+            rs = ps.executeQuery();
+           
+            exists = rs.next();
+         }
+         
+         return exists;
+      }
+      finally
+      {
+         if (rs != null) rs.close();
+         
+         if (ps != null) ps.close();
+         
+         if (conn != null) conn.close();
+         
+         mgr.commit();
+
+         if (txOld != null)
+         {
+            mgr.resume(txOld);
+         }
+                  
+      } 
+   }
+
+
    /**
     * @return true if this test is ran in "remote" mode, i.e. the server side of the test runs in a
     *         different VM than this one (that is running the client side)

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -216,11 +216,16 @@
       throw new UnsupportedOperationException();
    }
 
-   public List createDeliveries(List messageIds)
+   public List recoverDeliveries(List messageIds)
    {
       throw new UnsupportedOperationException();
    }
 
+   public void addDelivery(Delivery del)
+   {
+      throw new UnsupportedOperationException();
+   }
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -26,6 +26,7 @@
 import org.jboss.messaging.core.SimpleDelivery;
 import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.JDBCPersistenceManager;
+import org.jboss.messaging.core.plugin.SimpleMessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TransactionRepository;
@@ -120,7 +121,7 @@
       IDManager idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
-      TransactionRepository tr = new TransactionRepository(pm, idm);
+      TransactionRepository tr = new TransactionRepository(pm, new SimpleMessageStore(), idm);
       tr.start();
       
       Transaction tx = tr.createTransaction();

Modified: trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -122,11 +122,12 @@
       idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
-      tr = new TransactionRepository(pm, idm);
+      ms = new SimpleMessageStore();
+      ms.start();
+      
+      tr = new TransactionRepository(pm, ms, idm);
       tr.start();
       
-      ms = new SimpleMessageStore();
-      ms.start();
    }
 
    public void tearDown() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -829,6 +829,9 @@
          dels[i].cancel();   
       }
       
+      //Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -860,6 +863,9 @@
          dels[i].cancel();
       }
       
+//    Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -894,6 +900,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);      
+
       //This should cause the down cache to be flushed
       
       //verify 20 ref in storage

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -781,6 +781,9 @@
          dels[i].cancel();  
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -814,6 +817,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -847,6 +853,8 @@
       {
          dels[i].cancel();
       }
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
       
       //consumeCount += 20;
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -819,6 +819,9 @@
          dels[i].cancel();  
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -852,6 +855,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -887,6 +893,9 @@
       }
       
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 20 ref in storage

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -926,6 +926,9 @@
          dels[i].cancel(); 
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -965,6 +968,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -1004,6 +1010,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //consumeCount += 20;
       
       //This should cause the down cache to be flushed

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -880,6 +880,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -918,6 +921,8 @@
       {
          dels[i].cancel();
       }
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
       
       //This should cause the down cache to be flushed
       
@@ -957,6 +962,9 @@
       {
          dels[i].cancel();
       }
+           
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);     
       
       //consumeCount += 20;
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -913,6 +913,9 @@
          dels[i].cancel();   
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250); 
+      
       //This should cause the refs corresponding to the deliveries to go the front of the in memory quuee
       //and the oldest refs in memory evicted off the end into the down cache
       
@@ -952,6 +955,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //This should cause the down cache to be flushed
       
       //verify 10 ref in storage
@@ -991,6 +997,9 @@
          dels[i].cancel();
       }
       
+      // Cancel is asynch, so need to wait a bit
+      Thread.sleep(250);       
+      
       //consumeCount += 20;
       
       //This should cause the down cache to be flushed

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -23,6 +23,7 @@
 
 import java.util.List;
 
+import org.jboss.messaging.core.ChannelSupport;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
@@ -40,6 +41,8 @@
  * A PagingTest_Reload.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * 
  * @version 1.1
  *
  * SingleChannel_Reload.java,v 1.1 2006/03/22 10:23:35 timfox Exp
@@ -120,14 +123,13 @@
                   true, true, true, 100);      
       pm.start();
       
-      tr = new TransactionRepository(pm, idm);
-      tr.start();
-      
       ms = new SimpleMessageStore();
       ms.start();
       
-      queue = null;
-      
+      tr = new TransactionRepository(pm, ms, idm);
+
+      tr.start();
+         
       PagingFilteredQueue queue2 = new PagingFilteredQueue("queue1", 1, ms, pm, true, true, new QueuedExecutor(), null, 100, 20, 10);
       queue2.deactivate();
       queue2.load();
@@ -218,12 +220,12 @@
                   true, true, true, 100);     
       pm.start();
       
-      tr = new TransactionRepository(pm, idm);
-      tr.start();
-      
       ms = new SimpleMessageStore();
       ms.start();
       
+      tr = new TransactionRepository(pm, ms, idm);
+      tr.start();
+
       PagingFilteredQueue queue2 = new PagingFilteredQueue("queue1", 1, ms, pm, true, true, new QueuedExecutor(), null, 100, 20, 10);
       queue2.deactivate();
       queue2.load();

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/base/PagingStateTestBase.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -103,11 +103,11 @@
       idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
-      tr = new TransactionRepository(pm, idm);
-      tr.start();
-      
       ms = new SimpleMessageStore();
       ms.start();
+      
+      tr = new TransactionRepository(pm, ms, idm);
+      tr.start();            
    }
    
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/JDBCPersistenceManagerTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1163,7 +1163,7 @@
       IDManager idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
-      TransactionRepository txRep = new TransactionRepository(pm, idm);
+      TransactionRepository txRep = new TransactionRepository(pm, ms, idm);
       txRep.start();
 
       log.debug("transaction log started");
@@ -1274,7 +1274,7 @@
       IDManager idm = new IDManager("TRANSACTION_ID", 10, pm);
       idm.start();
       
-      TransactionRepository txRep = new TransactionRepository(pm, idm);
+      TransactionRepository txRep = new TransactionRepository(pm, ms, idm);
       txRep.start();
  
       Message[] messages = createMessages(10);     

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/base/PostOfficeTestBase.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,16 +21,9 @@
   */
 package org.jboss.test.messaging.core.plugin.base;
 
-import java.sql.Connection;
-import java.sql.PreparedStatement;
-import java.sql.ResultSet;
 import java.util.ArrayList;
 import java.util.List;
 
-import javax.naming.InitialContext;
-import javax.sql.DataSource;
-import javax.transaction.TransactionManager;
-
 import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.messaging.core.FilterFactory;
 import org.jboss.messaging.core.Message;
@@ -54,7 +47,6 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.test.messaging.tools.jmx.ServiceContainer;
 import org.jboss.test.messaging.util.CoreMessageFactory;
-import org.jboss.tm.TransactionManagerService;
 
 /**
  * 
@@ -116,12 +108,12 @@
       transactionIDManager = new IDManager("TRANSACTION_ID", 10, pm);
       transactionIDManager.start();
       
-      tr = new TransactionRepository(pm, transactionIDManager);
-      tr.start();
-      
       ms = new SimpleMessageStore();
       ms.start();
       
+      tr = new TransactionRepository(pm, ms, transactionIDManager);
+      tr.start();
+            
       pool = new QueuedExecutorPool(10);
       
       channelIDManager = new IDManager("CHANNEL_ID", 10, pm);
@@ -165,108 +157,7 @@
       return postOffice;
    }
    
-   protected boolean checkNoBindingData() throws Exception
-   {
-      InitialContext ctx = new InitialContext();
-
-      TransactionManager mgr = (TransactionManager)ctx.lookup(TransactionManagerService.JNDI_NAME);
-      DataSource ds = (DataSource)ctx.lookup("java:/DefaultDS");
-      
-      javax.transaction.Transaction txOld = mgr.suspend();
-      mgr.begin();
-      
-      Connection conn = null;
-      
-      PreparedStatement ps = null;
-      
-      ResultSet rs = null;
-
-      try
-      {
-         conn = ds.getConnection();
-         String sql = "SELECT * FROM JMS_POSTOFFICE";
-         ps = conn.prepareStatement(sql);
-         
-         rs = ps.executeQuery();
-         
-         return rs.next();
-      }
-      finally
-      {
-         if (rs != null) rs.close();
-         
-         if (ps != null) ps.close();
-         
-         if (conn != null) conn.close();
-         
-         mgr.commit();
-
-         if (txOld != null)
-         {
-            mgr.resume(txOld);
-         }
-                  
-      } 
-   }
    
-   protected boolean checkNoMessageData() throws Exception
-   {
-      InitialContext ctx = new InitialContext();
-
-      TransactionManager mgr = (TransactionManager)ctx.lookup(TransactionManagerService.JNDI_NAME);
-      DataSource ds = (DataSource)ctx.lookup("java:/DefaultDS");
-      
-      javax.transaction.Transaction txOld = mgr.suspend();
-      mgr.begin();
-      
-      Connection conn = null;
-      
-      PreparedStatement ps = null;
-      
-      ResultSet rs = null;
-
-      try
-      {
-         conn = ds.getConnection();
-         String sql = "SELECT * FROM JMS_MESSAGE_REFERENCE";
-         ps = conn.prepareStatement(sql);
-         
-         rs = ps.executeQuery();
-         
-         boolean exists = rs.next();
-         
-         if (!exists)
-         {
-            rs.close();
-            
-            ps.close();
-            
-            ps = conn.prepareStatement("SELECT * FROM JMS_MESSAGE");
-            
-            rs = ps.executeQuery();
-           
-            exists = rs.next();
-         }
-         
-         return exists;
-      }
-      finally
-      {
-         if (rs != null) rs.close();
-         
-         if (ps != null) ps.close();
-         
-         if (conn != null) conn.close();
-         
-         mgr.commit();
-
-         if (txOld != null)
-         {
-            mgr.resume(txOld);
-         }
-                  
-      } 
-   }
    
    private static long msgCount;
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1078,7 +1078,7 @@
          if (checkNoMessageData())
          {
             fail("data still in database");
-         };
+         }
       }
    }
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -370,11 +370,17 @@
          return false;
       }
 
-      public List createDeliveries(List messageIds)
+      public List recoverDeliveries(List messageIds)
       {
          // TODO Auto-generated method stub
          return null;
       }
+
+      public void addDelivery(Delivery del)
+      {
+         // TODO Auto-generated method stub
+         
+      }
       
    }
 

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -610,11 +610,17 @@
          return false;
       }
 
-      public List createDeliveries(List messageIds)
+      public List recoverDeliveries(List messageIds)
       {
          // TODO Auto-generated method stub
          return null;
       }
+
+      public void addDelivery(Delivery del)
+      {
+         // TODO Auto-generated method stub
+         
+      }
       
    }
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -638,7 +638,10 @@
          assertTrue(office4.getHoldingTransactions().isEmpty());
          assertTrue(office5.getHoldingTransactions().isEmpty());
          
-         checkNoMessageData();
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }
       }
       finally
       { 
@@ -982,7 +985,10 @@
          assertTrue(office4.getHoldingTransactions().isEmpty());
          assertTrue(office5.getHoldingTransactions().isEmpty());
          
-         checkNoMessageData();
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }
       }
       finally
       { 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -44,6 +44,8 @@
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.message.MessageIdGeneratorFactory;
 import org.jboss.jms.server.ServerPeer;
+import org.jboss.jms.tx.ResourceManager;
+import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.logging.Logger;
 import org.jboss.remoting.InvocationRequest;
 import org.jboss.remoting.ServerInvocationHandler;
@@ -112,6 +114,88 @@
 
    // Public --------------------------------------------------------
    
+   public void testResourceManagersForSameServer() throws Exception
+   {
+      Connection conn1 = cf.createConnection();      
+            
+      ClientConnectionDelegate del1 = (ClientConnectionDelegate)((JBossConnection)conn1).getDelegate();
+      
+      ConnectionState state1 = (ConnectionState)del1.getState();
+      
+      ResourceManager rm1 = state1.getResourceManager();
+      
+      Connection conn2 = cf.createConnection();      
+      
+      ClientConnectionDelegate del2 = (ClientConnectionDelegate)((JBossConnection)conn2).getDelegate();
+      
+      ConnectionState state2 = (ConnectionState)del2.getState();
+      
+      ResourceManager rm2 = state2.getResourceManager();
+
+      //Two connections for same server should share the same resource manager
+      
+      assertTrue(rm1 == rm2);
+      
+      assertTrue(ResourceManagerFactory.instance.containsResourceManager(state2.getServerID()));
+      
+      conn1.close();
+      
+      //Check reference counting
+      assertTrue(ResourceManagerFactory.instance.containsResourceManager(state2.getServerID()));
+           
+      conn2.close();
+      
+      assertFalse(ResourceManagerFactory.instance.containsResourceManager(state2.getServerID()));  
+      
+      assertEquals(0, ResourceManagerFactory.instance.size());
+   }
+   
+   public void testResourceManagerFactory()
+   {
+      ResourceManager rm1 = ResourceManagerFactory.instance.checkOutResourceManager(1);
+      
+      ResourceManager rm2 = ResourceManagerFactory.instance.checkOutResourceManager(2);
+      
+      ResourceManager rm3 = ResourceManagerFactory.instance.checkOutResourceManager(3);
+      
+      ResourceManager rm4 = ResourceManagerFactory.instance.checkOutResourceManager(4);
+      
+      assertEquals(4, ResourceManagerFactory.instance.size());
+      
+      ResourceManager rm4_2 = ResourceManagerFactory.instance.checkOutResourceManager(4);
+      
+      assertEquals(4, ResourceManagerFactory.instance.size());
+      
+      ResourceManager rm4_3 = ResourceManagerFactory.instance.checkOutResourceManager(4);
+      
+      assertEquals(4, ResourceManagerFactory.instance.size());
+      
+      ResourceManagerFactory.instance.checkInResourceManager(4);
+      
+      assertEquals(4, ResourceManagerFactory.instance.size());
+      
+      ResourceManagerFactory.instance.checkInResourceManager(4);
+      
+      assertEquals(4, ResourceManagerFactory.instance.size());
+      
+      ResourceManagerFactory.instance.checkInResourceManager(4);
+      
+      assertEquals(3, ResourceManagerFactory.instance.size());
+      
+      ResourceManagerFactory.instance.checkInResourceManager(3);
+      
+      assertEquals(2, ResourceManagerFactory.instance.size());
+      
+      ResourceManagerFactory.instance.checkInResourceManager(2);
+      
+      assertEquals(1, ResourceManagerFactory.instance.size());
+      
+      ResourceManagerFactory.instance.checkInResourceManager(1);
+      
+      assertEquals(0, ResourceManagerFactory.instance.size());
+ 
+   }
+   
    public void testManyConnections() throws Exception
    {
       for (int i = 0; i < 1000; i++)

Modified: trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/JMSTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -199,6 +199,45 @@
       conn.close();
    }
 
+   public void test_Persistent_Transactional_Send() throws Exception
+   {
+      ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+
+      Queue queue = (Queue)ic.lookup("/queue/JMSTestQueue");
+
+      Connection conn = cf.createConnection();
+
+      Session session = conn.createSession(true, Session.SESSION_TRANSACTED);
+
+      MessageProducer prod = session.createProducer(queue);
+      prod.setDeliveryMode(DeliveryMode.PERSISTENT);
+
+      TextMessage m = session.createTextMessage("message one");
+      prod.send(m);
+      m = session.createTextMessage("message two");
+      prod.send(m);
+
+      session.commit();
+
+      conn.close();
+
+      conn = cf.createConnection();
+
+      session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+      MessageConsumer cons = session.createConsumer(queue);
+
+      conn.start();
+
+      TextMessage rm = (TextMessage)cons.receive();
+      assertEquals("message one", rm.getText());
+      rm = (TextMessage)cons.receive();
+      assertEquals("message two", rm.getText());
+
+      conn.close();
+   }
+
+
    public void test_NonPersistent_Transactional_Acknowledgment() throws Exception
    {
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
@@ -232,7 +271,6 @@
       conn.close();
    }
 
-
    public void test_Asynchronous_to_Client() throws Exception
    {
       ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -22,6 +22,7 @@
 package org.jboss.test.messaging.jms;
 
 import java.io.File;
+import java.util.Iterator;
 import java.util.Properties;
 import java.util.jar.Attributes;
 import java.util.jar.JarFile;
@@ -89,7 +90,7 @@
       
       // Compare the value from ConnectionMetaData and MANIFEST.MF
       Attributes attrs = manifest.getMainAttributes();
-      /*
+      
       System.out.println("META--> " + meta.getJMSMajorVersion()); 
       System.out.println("META--> " + meta.getJMSMinorVersion()); 
       System.out.println("META--> " + meta.getJMSProviderName()); 
@@ -103,7 +104,7 @@
          Object item = itr.next();
          System.out.println("MANIFEST--> " + item + " : " + attrs.get(item));
       }
-      */
+      
       assertEquals(attrs.getValue("Implementation-Title"), meta.getJMSProviderName());
       String ver = attrs.getValue("Implementation-Version");
       assertTrue(-1 != ver.indexOf(meta.getProviderVersion()));

Modified: trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,17 +21,38 @@
   */
 package org.jboss.test.messaging.jms;
 
-import EDU.oswego.cs.dl.util.concurrent.Latch;
 import java.util.ArrayList;
 import java.util.Collections;
 import java.util.Iterator;
 import java.util.List;
-import javax.jms.*;
+
+import javax.jms.BytesMessage;
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.DeliveryMode;
+import javax.jms.InvalidDestinationException;
+import javax.jms.JMSException;
+import javax.jms.MapMessage;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageListener;
+import javax.jms.MessageProducer;
+import javax.jms.ObjectMessage;
+import javax.jms.Queue;
+import javax.jms.QueueReceiver;
+import javax.jms.Session;
+import javax.jms.StreamMessage;
+import javax.jms.TextMessage;
+import javax.jms.Topic;
+import javax.jms.TopicSubscriber;
 import javax.naming.InitialContext;
+
 import org.jboss.jms.destination.JBossTopic;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
+import EDU.oswego.cs.dl.util.concurrent.Latch;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -886,6 +907,9 @@
 
           cons1.close();
 
+          //Cancelling is asynch so can take some time
+          Thread.sleep(500);
+          
           //rollback should cause redelivery of messages
 
           //in this case redelivery occurs to a different receiver
@@ -1000,6 +1024,9 @@
           assertEquals("hello1", rm1.getText());
 
           cons1.close();
+  
+          //Give time for asynch cancel to happen
+          Thread.sleep(500);
 
           log.debug("sess.recover()");
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -21,18 +21,36 @@
   */
 package org.jboss.test.messaging.jms;
 
+import javax.jms.Connection;
 import javax.jms.Destination;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageProducer;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.jms.Topic;
+import javax.jms.XAConnection;
+import javax.jms.XASession;
 import javax.naming.InitialContext;
+import javax.transaction.TransactionManager;
+import javax.transaction.xa.XAResource;
+import javax.transaction.xa.Xid;
 
 import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.messaging.core.tx.XidImpl;
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.tm.TransactionManagerLocator;
 
+import com.arjuna.ats.arjuna.common.Uid;
+import com.arjuna.ats.jta.xa.XidImple;
+
 /**
  * 
  * A XARecoveryTest
-
+ *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * @version <tt>$Revision: 1.1 $</tt>
  *
  * $Id$
@@ -49,8 +67,10 @@
    protected InitialContext initialContext;
    
    protected JBossConnectionFactory cf;
-   protected Destination queue;   
+   protected Destination queue, queueA, queueB, queueTX, topicTX;
 
+   TransactionManager tm;
+
    // Constructors --------------------------------------------------
 
    public XARecoveryTest(String name)
@@ -63,139 +83,3252 @@
    public void setUp() throws Exception
    {
       super.setUp();
-      ServerManagement.start("all");
+      ServerManagement.start("all");      
       
-      
       initialContext = new InitialContext(ServerManagement.getJNDIEnvironment());
       cf = (JBossConnectionFactory)initialContext.lookup("/ConnectionFactory");
       
       
-      //if (!ServerManagement.isRemote()) tm = TransactionManagerLocator.getInstance().locate();
+      if (!ServerManagement.isRemote()) tm = TransactionManagerLocator.getInstance().locate();
       
       ServerManagement.undeployQueue("Queue");
       ServerManagement.deployQueue("Queue");
-      queue = (Destination)initialContext.lookup("/queue/Queue"); 
 
+      ServerManagement.undeployQueue("QA");
+      ServerManagement.deployQueue("QA");
+
+      ServerManagement.undeployQueue("QB");
+      ServerManagement.deployQueue("QB");
+
+      ServerManagement.undeployQueue("TXQ");
+      ServerManagement.deployQueue("TXQ");
+      
+      ServerManagement.undeployTopic("TXTOPIC");
+      ServerManagement.deployTopic("TXTOPIC");
+
+      queue = (Destination)initialContext.lookup("/queue/Queue");
+      queueA = (Destination)initialContext.lookup("/queue/QA");
+      queueB = (Destination)initialContext.lookup("/queue/QB");
+      queueTX = (Destination)initialContext.lookup("/queue/TXQ");
+      
+      topicTX = (Destination)initialContext.lookup("/topic/TXTOPIC");
+
+      drainDestination(cf, queue);
+      drainDestination(cf, queueA);
+      drainDestination(cf, queueB);
+      drainDestination(cf, queueTX);
    }
 
    public void tearDown() throws Exception
    {
       ServerManagement.undeployQueue("Queue");
+      ServerManagement.undeployQueue("QA");
+      ServerManagement.undeployQueue("QB");
+      ServerManagement.undeployQueue("TXQ");
       
+      ServerManagement.undeployTopic("TXTOPIC");
+
       super.tearDown();
    }
 
 
    // Public --------------------------------------------------------
    
-   //TODO Re-enable when we complete XA Recovery
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it without restarting the server
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithoutRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn1.close();
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         log.trace("Preparing xid " + xid1);
+         res.prepare(xid1);
+         log.trace("Prepared xid " + xid1);
+            
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+         
+         conn1.close();
+         
+         conn2.close();
+         
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm9.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm10.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm11.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm12.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm13.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm14.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm15.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm16.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }               
+      }
+   }
    
-   public void testNoop()
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it without restarting the server, then rollback
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithoutRestartRollback() throws Exception
    {
+      Connection conn1 = null;
       
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+                  
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("rolling back the tx");
+         
+         //rollback
+         res3.rollback(xids[0]);
+         
+         log.trace("rolledb back the tx");
+         
+         Thread.sleep(1000);
+         
+         conn1.close();
+         
+         conn2.close();
+         
+         
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm1.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm2.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm3.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm4.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm5.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm6.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm7.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm8.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
    }
    
-//
-//   public void test1() throws Exception
-//   {
-//      
-//      XAConnection conn1 = cf.createXAConnection();
-//      
-//      XAConnection conn2 = cf.createXAConnection();
-//      
-//      XASession sess1 = conn1.createXASession();
-//      
-//      XASession sess2 = conn2.createXASession();
-//      
-//      XAResource res1 = sess1.getXAResource();
-//      
-//      XAResource res2 = sess2.getXAResource();
-//      
-//      //Pretend to be a transaction manager by interacting through the XAResources
-//      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
-//      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
-//      
-//      
-////    Send a message in each tx
-//      
-//      
-//      res1.start(xid1, XAResource.TMNOFLAGS);
-//      
-//      MessageProducer prod1 = sess1.createProducer(queue);
-//      
-//      TextMessage tm1 = sess1.createTextMessage("testing1");
-//      
-//      prod1.send(tm1);
-//      
-//      res1.end(xid1, XAResource.TMSUCCESS);
-//      
-//      
-//      
-//      
-//      res2.start(xid2, XAResource.TMNOFLAGS);
-//      
-//      MessageProducer prod2 = sess2.createProducer(queue);
-//      
-//      TextMessage tm2 = sess2.createTextMessage("testing2");
-//      
-//      prod2.send(tm2);
-//      
-//      res2.end(xid2, XAResource.TMSUCCESS);
-//      
-//      //prepare both txs
-//      
-//      
-//      res1.prepare(xid1);      
-//      res2.prepare(xid2);
-//      
-//      //Now "crash" the server
-//      
-//      ServerManagement.stopServerPeer();
-//
-//      ServerManagement.startServerPeer();
-//
-//      //Now lookup the recoverable in JNDI
-//      InitialContext ic = new InitialContext();
-//      JMSRecoverable recoverable = (JMSRecoverable)ic.lookup("/" +
-//            ServerPeer.RECOVERABLE_CTX_NAME + "/"+ ServerManagement.getServerPeer().getServerPeerID());
-//      
-//      XAResource res = recoverable.getResource();
-//      
-//      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-//      assertEquals(2, xids.length);
-//      
-//      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-//      assertEquals(0, xids2.length);
-//      
-//      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-//      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-//      
-//      res.commit(xid1, false);
-//      
-//      res.commit(xid2, false);
-//      
-//      recoverable.cleanUp();
-//      
-//      ServerManagement.deployQueue("Queue");
-//            
-//      Connection conn3 = cf.createConnection();
-//      
-//      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//      MessageConsumer cons = sessRec.createConsumer(queue);
-//      conn3.start();
-//      
-//      TextMessage m2 = (TextMessage)cons.receiveNoWait();
-//      assertNotNull(m2);
-//      assertEquals("testing1", m2.getText());
-//      
-//      
-//      TextMessage m3 = (TextMessage)cons.receiveNoWait();
-//      assertNotNull(m3);
-//      assertEquals("testing2", m3.getText());
-//      
-//      conn3.close();
-//
-//   }
- 
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it after restarting the server
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
+
+         ServerManagement.stopServerPeer();
+
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("QA");
+         
+         ServerManagement.deployQueue("QB");
+                           
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm9.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm10.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm11.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm12.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm13.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm14.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm15.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm16.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+            
+   
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it after restarting the server, then rollback
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithRestartRollback() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
+
+         ServerManagement.stopServerPeer();
+
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("QA");
+         
+         ServerManagement.deployQueue("QB");
+                           
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("rolling back the tx");
+         
+         //rollback
+         res3.rollback(xids[0]);
+         
+         log.trace("rolled back the tx");
+         
+         Thread.sleep(1000);
+
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm1.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm2.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm3.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm4.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm5.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm6.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm7.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm8.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         cons1.close();
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+   /* Not really necessary - but it does no harm */
+   public void testComplexTransactional() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         res.commit(xid1, false);
+         
+         conn1.close();
+         
+         conn2.close();
+                  
+         
+         
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm9.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm10.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm11.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm12.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm13.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm14.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm15.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm16.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+   
+   /* A simple send in a transaction - recovered without restarting the server */
+   public void testSimpleTransactionalSendRecoveryWithoutRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalDeliveryRecoveryWithoutRestart");
+      
+      XAConnection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createXAConnection();
+   
+         XASession sess1 = conn1.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+   
+         log.trace("Sending message");
+         
+         //Send message in tx
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueTX);
+   
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+   
+         prod1.send(tm1);
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         log.trace("Sent message");
+   
+         //prepare tx
+   
+         res1.prepare(xid1);
+   
+         log.trace("prepared tx");
+         
+         conn2 = cf.createConnection();
+         
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons2 = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Verify message can't be received
+         
+         Message m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+                  
+         // Verify message still can't be received
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         //Commit the tx
+         
+         res1.commit(xids[0], false);
+         
+         //The message should now be available
+         
+         TextMessage rm1 = (TextMessage)cons2.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }       
+   }
+   
+   /* A simple send in a transaction - recovered after restarting the server */
+   public void testSimpleTransactionalSendRecoveryWithRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalDeliveryRecoveryWithRestart");
+      
+      XAConnection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createXAConnection();
+   
+         XASession sess1 = conn1.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+   
+         log.trace("Sending message");
+         
+         //Send message in tx
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueTX);
+   
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+   
+         prod1.send(tm1);
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         log.trace("Sent message");
+   
+         //prepare tx
+   
+         res1.prepare(xid1);
+   
+         log.trace("prepared tx");
+         
+         conn2 = cf.createConnection();
+         
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons2 = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Verify message can't be received
+         
+         Message m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
+
+         ServerManagement.stopServerPeer();
+
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("TXQ");
+         
+         log.trace("Restarted");
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         log.trace("created connection");
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("recovered");
+         
+         conn2 = cf.createConnection();
+         
+         sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons2 = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+                  
+         // Verify message still can't be received
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         log.trace("still can't see message");
+         
+         //Commit the tx
+         
+         res3.commit(xids[0], false);
+         
+         log.trace("committed");
+         
+         //The message should now be available
+         
+         TextMessage rm1 = (TextMessage)cons2.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }        
+   }
+   
+   
+   
+   
+   /* A simple acknowledgement in a transaction, recovered without restart */
+   public void testSimpleTransactionalAcknowledgementRecoveryWithoutRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalAcknowledgementRecovery");
+      
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         //First send a message to the queue
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess1.createProducer(queueTX);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         
+         prod.send(tm1);
+                           
+         
+         conn2 = cf.createXAConnection();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageConsumer cons = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Consume the message
+         
+         TextMessage rm1 = (TextMessage)cons.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare the tx
+         
+         res1.prepare(xid1);
+         
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+                  
+         //Commit the tx
+         
+         res1.commit(xids[0], false);
+         
+         //The message should be acknowldged
+         
+         conn1.close();
+         
+         conn2.close();
+         
+         conn3.close();
+         
+         conn1 = cf.createConnection();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons1 = sess1.createConsumer(queueTX);
+         
+         conn1.start();
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }            
+   }
+   
+   
+   
+   /* A simple acknowledgement in a transaction, recovered with restart */
+   public void testSimpleTransactionalAcknowledgementRecoveryWithRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalAcknowledgementRecoveryWithRestart");
+      
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         //First send a message to the queue
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess1.createProducer(queueTX);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         
+         prod.send(tm1);
+                                    
+         conn2 = cf.createXAConnection();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageConsumer cons = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Consume the message
+         
+         TextMessage rm1 = (TextMessage)cons.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare the tx
+         
+         res1.prepare(xid1);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
+
+         ServerManagement.stopServerPeer();
+
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("TXQ");
+         
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+                  
+         //Commit the tx
+         
+         res3.commit(xids[0], false);
+         
+         //The message should be acknowldged
+         
+         conn3.close();
+         
+         conn1 = cf.createConnection();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons1 = sess1.createConsumer(queueTX);
+         
+         conn1.start();
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }                  
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }           
+   }
+   
+           
+   /*
+    * In this test, we have 4 messages in a 2 durable subs on the same topic.
+    * 
+    * We ack them, then add four more messages
+    * 
+    * This test tests for the recovery when the same message is in multiple channels
+    * 
+    * We don't restart in this test
+    * 
+    */
+   public void testRecoveryWithTwoDurableSubsWithoutRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(topicTX);
+         
+         MessageConsumer sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         MessageConsumer sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         //send four messages
+          
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         conn1.close();
+         
+         //The messages should now be in both durable subs
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.setClientID("wib1");
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         //Now send four more messages in a global tx
+         
+         MessageProducer prod2 = sess2.createProducer(topicTX);
+         
+         TextMessage tm5 = sess2.createTextMessage("tm5");
+         TextMessage tm6 = sess2.createTextMessage("tm6");
+         TextMessage tm7 = sess2.createTextMessage("tm7");
+         TextMessage tm8 = sess2.createTextMessage("tm8");
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+
+         //And consume the first four from each in the tx
+         
+         sub1 = sess2.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess2.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm1 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm1 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         rm2 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         rm3 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         rm4 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+                  
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         //recover
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+         
+         conn2.close();
+         
+         
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         //Should now see the last 4 messages
+         
+         sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm5 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm5 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         rm6 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         rm7 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         rm8 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+   
+   
+   /*
+    * In this test, we have 4 messages in a 2 durable subs on the same topic.
+    * 
+    * We ack them, then add four more messages
+    * 
+    * This test tests for the recovery when the same message is in multiple channels
+    * 
+    * We do restart in this test
+    * 
+    */
+   public void testRecoveryWithTwoDurableSubsWithRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(topicTX);
+         
+         MessageConsumer sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         MessageConsumer sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         //send four messages
+          
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         conn1.close();
+         
+         //The messages should now be in both durable subs
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.setClientID("wib1");
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         //Now send four more messages in a global tx
+         
+         MessageProducer prod2 = sess2.createProducer(topicTX);
+         
+         TextMessage tm5 = sess2.createTextMessage("tm5");
+         TextMessage tm6 = sess2.createTextMessage("tm6");
+         TextMessage tm7 = sess2.createTextMessage("tm7");
+         TextMessage tm8 = sess2.createTextMessage("tm8");
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+
+         //And consume the first four from each in the tx
+         
+         sub1 = sess2.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess2.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm1 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm1 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         rm2 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         rm3 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         rm4 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
+
+         ServerManagement.stopServerPeer();
+
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployTopic("TXTOPIC");
+         
+                           
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         //recover
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+                           
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         //Should now see the last 4 messages
+         
+         sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm5 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm5 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         rm6 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         rm7 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         rm8 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+         
+   
+
+   /*
+    * Send two messages in two transactions.
+    * Prepare tx
+    * Crash the server
+    * Restart the server
+    * Make sure the messages can be received
+    * NOTE this test only tests transactional sends, not transactional acknowledgments 
+    * 
+    */
+   public void testTransactionalDeliveryRecovery() throws Exception
+   {
+      log.trace("starting testTransactionalDeliveryRecovery");
+      
+      XAConnection conn1 = null;
+
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();         
+            
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 42, "frigtard".getBytes());
+   
+         log.trace("Sending messages");
+         
+         //Send two messages in transaction 1
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueTX);
+   
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+   
+         prod1.send(tm1);
+   
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+   
+         prod1.send(tm2);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+         //Send two messages in transaction 2
+         
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queueTX);
+   
+         TextMessage tm3 = sess2.createTextMessage("tm3");
+   
+         prod2.send(tm3);
+   
+         TextMessage tm4 = sess2.createTextMessage("tm4");
+   
+         prod2.send(tm4);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+         
+         log.trace("Sent messages");
+   
+         //prepare both txs
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+         
+         log.trace("prepared messages");
+   
+         //Now "crash" the server
+         
+         conn1 = null;
+         
+         conn2 = null;
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("TXQ");
+   
+         //Try and recover
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         log.trace("Recovering");
+         
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+         
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         //They may be in a different order
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+         
+         //Make sure can't receive the messages
+         
+         log.trace("Creating conn");
+         
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queueTX);
+         conn3.start();
+         
+         log.trace("Created conn3");
+   
+         TextMessage m1 = (TextMessage)cons.receive(1000);
+         assertNull(m1);
+         
+         log.trace("comitting");
+   
+         //Commit tx1
+         
+         res.commit(xid1, false);
+         
+         log.trace("comitted");
+         
+         
+         //Should now be able to receive tm1 and tm2
+         
+         m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         
+         assertEquals(tm1.getText(), m1.getText());
+         
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+         
+         assertEquals(tm2.getText(), m2.getText());
+         
+         TextMessage m3 = (TextMessage)cons.receive(1000);
+         assertNull(m3);
+         
+         //Now commit tx2
+         
+         res.commit(xid2, false);
+         
+         //Should now be able to receive tm3 and tm4
+         
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m3);
+         
+         assertEquals(tm3.getText(), m3.getText());
+         
+         TextMessage m4 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m4);
+         
+         assertEquals(tm4.getText(), m4.getText());
+         
+         TextMessage m5 = (TextMessage)cons.receive(1000);
+         assertNull(m5);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+
+
+   /*
+    * This test sends some messages in a couple of txs, crashes then recovers
+    * NOTE it does not test transactional acknowledgements
+    */
+   public void testMockCoordinatorRecovery() throws Exception
+   {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
+   
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "aapeli".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 42, "belsebub".getBytes());
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueA);
+   
+         TextMessage tm1 = sess1.createTextMessage("alpha");
+   
+         prod1.send(tm1);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queueA);
+   
+         TextMessage tm2 = sess2.createTextMessage("beta");
+   
+         prod2.send(tm2);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("QA");
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+   
+         res.commit(xid1, false);
+   
+         res.commit(xid2, false);
+   
+   
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queueA);
+         conn3.start();
+   
+         Message msg = cons.receive(MAX_TIMEOUT);
+   
+         TextMessage m1 = (TextMessage)msg;
+         assertNotNull(m1);
+   
+         assertTrue("alpha".equals(m1.getText()) ||
+                    "beta".equals(m1.getText()));
+   
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+   
+         assertTrue("alpha".equals(m2.getText()) ||
+                    "beta".equals(m2.getText()));
+   
+         assertTrue(!tm1.getText().equals(tm2.getText()));
+   
+         Message nullMessage = cons.receive(MIN_TIMEOUT);
+         assertTrue(nullMessage == null);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
+
+   }
+
+   
+   /*
+    * This test sends some messages in a couple of txs, crashes then recovers
+    * It uses the JBoss TS XId implementation - so we can show compatibility
+    * NOTE it does not test transactional acknowledgements
+    */
+   public void testMockCoordinatorRecoveryWithJBossTSXids() throws Exception
+   {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
+
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImple(new Uid("cadaver"), new Uid("bq1"), 666);
+         Xid xid2 = new XidImple(new Uid("dalidom"), new Uid("bq2"), 661);   // TODO
+   
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queue);
+   
+         TextMessage tm1 = sess1.createTextMessage("testing1");
+   
+         prod1.send(tm1);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queue);
+   
+         TextMessage tm2 = sess2.createTextMessage("testing2");
+   
+         prod2.send(tm2);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("Queue");
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+     
+         res.commit(xid1, false);
+   
+         res.commit(xid2, false);
+      
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queue);
+         conn3.start();
+   
+         TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         assertEquals("testing1", m1.getText());
+   
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+   
+         assertEquals("testing2", m2.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
+   }
+
+
+   public void testMockCoordinatorRecovery3() throws Exception
+   {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
+
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queue);
+   
+         TextMessage tm1 = sess1.createTextMessage("testing1");
+   
+         prod1.send(tm1);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queue);
+   
+         TextMessage tm2 = sess2.createTextMessage("testing2");
+   
+         prod2.send(tm2);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("Queue");
+   
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+   
+         res.commit(xids[0], false);
+   
+         res.commit(xids[1], false);
+      
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queue);
+         conn3.start();
+   
+         TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         assertEquals("testing1", m1.getText());
+   
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+   
+         assertEquals("testing2", m2.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
+   }
+
+
+   public void testMultiChannelRecovery() throws Exception
+   {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
+
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         MessageProducer prod2 = sess1.createProducer(queueB);
+   
+         TextMessage tm1 = sess1.createTextMessage("testing1");
+         TextMessage tm2 = sess1.createTextMessage("testing2");
+   
+         prod1.send(tm1);
+         prod2.send(tm2);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod3 = sess2.createProducer(queue);
+   
+         TextMessage tm3 = sess2.createTextMessage("testing3");
+   
+         prod3.send(tm3);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("Queue");
+         ServerManagement.deployQueue("QA");
+         ServerManagement.deployQueue("QB");
+   
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+   
+         res.commit(xids[0], false);
+   
+         res.commit(xids[1], false);
+   
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+         MessageConsumer cons1 = sessRec.createConsumer(queueA);
+         MessageConsumer cons2 = sessRec.createConsumer(queueB);
+         MessageConsumer cons3 = sessRec.createConsumer(queue);
+   
+         conn3.start();
+   
+         TextMessage m1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         assertEquals("testing1", m1.getText());
+   
+         TextMessage m2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+         assertEquals("testing2", m2.getText());
+   
+         TextMessage m3 = (TextMessage)cons3.receive(MAX_TIMEOUT);
+         assertNotNull(m3);
+         assertEquals("testing3", m3.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
+
+   }
+
 }
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -41,15 +41,17 @@
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.tx.MessagingXAResource;
 import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.util.TransactionManagerLocator;
 import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.tm.TransactionManagerLocator;
+import org.jboss.tm.TxUtils;
 
 /**
  * 
  * A XATest
-
+ *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision: 1.1 $</tt>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  *
  * $Id$
  *
@@ -88,13 +90,20 @@
       initialContext = new InitialContext(ServerManagement.getJNDIEnvironment());
       cf = (JBossConnectionFactory)initialContext.lookup("/ConnectionFactory");
             
-      if (!ServerManagement.isRemote()) tm = TransactionManagerLocator.getInstance().locate();
-      
+      if (!ServerManagement.isRemote())
+      {
+         tm = TransactionManagerLocator.getInstance().locate();
+      }
+
       ServerManagement.undeployQueue("Queue");
       ServerManagement.deployQueue("Queue");
       queue = (Destination)initialContext.lookup("/queue/Queue");
-      
-      if (!ServerManagement.isRemote()) suspendedTx = tm.suspend();
+
+
+      if (!ServerManagement.isRemote())
+      {
+         suspendedTx = tm.suspend();
+      }
    }
 
    public void tearDown() throws Exception
@@ -103,11 +112,17 @@
       
       if (!ServerManagement.isRemote())
       {
-         if (tm.getTransaction() != null)
+         if (TxUtils.isUncommitted(tm))
          {
             //roll it back
             tm.rollback();
          }
+         if (tm.getTransaction() != null)
+         {
+            Transaction tx = tm.suspend();
+            if (tx != null)
+               log.warn("Transaction still associated with thread " + tx + " at status " + TxUtils.getStatusAsString(tx.getStatus()));
+         }
       }
       
       if (suspendedTx != null)
@@ -122,7 +137,6 @@
 
 
    // Public --------------------------------------------------------
-
    
    public void test2PCSendCommit1PCOptimization() throws Exception
    {
@@ -134,8 +148,7 @@
       Connection conn2 = null;
       
       try
-      {
-      
+      {      
          conn = cf.createXAConnection();
          
          tm.begin();
@@ -156,7 +169,7 @@
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
          
-         tx.commit();
+         tm.commit();
          
          conn2 = cf.createConnection();
          conn2.start();
@@ -182,50 +195,52 @@
       }
 
    }
-   
+
+
+
    public void test2PCSendCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
-      
+
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
-         
-         MessagingXAResource res = (MessagingXAResource)sess.getXAResource();         
+
+         MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
          XAResource res2 = new DummyXAResource();
-         
+
          //To prevent 1PC optimization being used
          res.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
          prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
       }
@@ -242,47 +257,47 @@
       }
 
    }
-   
-   
+
+
    public void test2PCSendRollback1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m);   
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -296,59 +311,61 @@
          }
       }
    }
-   
-   
+
+
    public void test2PCSendFailOnPrepare() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
-         
+
          //prevent 1Pc optimisation
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource(true);
          XAResource res3 = new DummyXAResource();
          XAResource res4 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
          tx.enlistResource(res3);
          tx.enlistResource(res4);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m);   
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
+
          try
          {
-            tx.commit();         
+            tm.commit();
+
+            fail("should not get here");
          }
          catch (Exception e)
          {
             //We should expect this
          }
-         
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -362,47 +379,47 @@
          }
       }
    }
-   
+
    public void test2PCSendRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
-         
+
          //prevent 1Pc optimisation
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m);   
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -420,12 +437,12 @@
    public void test2PCReceiveCommit1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-            
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -436,49 +453,49 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
          conn.start();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         
-         m2 = (TextMessage)cons.receive(1000);
-         
+
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
-         Message m3 = cons.receive(1000);
-         
+
+         Message m3 = cons.receive(MIN_TIMEOUT);
+
          assertNull(m3);
-         
+
          tm.commit();
-         
 
+
       }
       finally
       {
@@ -491,16 +508,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test2PCReceiveCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-            
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -511,50 +528,50 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
          conn.start();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         
-         m2 = (TextMessage)cons.receive(1000);
-         
+
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
-         Message m3 = cons.receive(1000);
-         
+
+         Message m3 = cons.receive(MIN_TIMEOUT);
+
          assertNull(m3);
-         
+
          tm.commit();
-         
 
+
       }
       finally
       {
@@ -567,18 +584,18 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test2PCReceiveRollback1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -586,54 +603,54 @@
          MessageProducer prod  = sessProducer.createProducer(queue);
          Message m = sessProducer.createTextMessage("XATest1");
          prod.send(m);
-         
+
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);         
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          //Message should be redelivered
-         
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
-         TextMessage m3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         m3 = (TextMessage)cons.receive(1000);         
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
-         
+
          assertTrue(m3.getJMSRedelivered());
-         
+
          tm.commit();
 
       }
@@ -648,16 +665,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test2PCReceiveRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -665,55 +682,55 @@
          MessageProducer prod  = sessProducer.createProducer(queue);
          Message m = sessProducer.createTextMessage("XATest1");
          prod.send(m);
-         
+
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          MessagingXAResource res = (MessagingXAResource)sess.getXAResource();
          res.setPreventJoining(true);
-         
+
          XAResource res2 = new DummyXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);         
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          //Message should be redelivered
-         
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
          tx.enlistResource(res2);
-         
-         TextMessage m3 = (TextMessage)cons.receive(1000);         
+
+         TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         m3 = (TextMessage)cons.receive(1000);         
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
-         
+
          assertTrue(m3.getJMSRedelivered());
-         
+
          tm.commit();
 
       }
@@ -728,49 +745,49 @@
             conn2.close();
          }
       }
-      
+
    }
-   
-   
+
+
    public void test1PCSendCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
-      
+
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
-         
+
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
 
-         
+
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
          prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
          prod.send(queue, m);
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         TextMessage m2 = (TextMessage)cons.receive(1000);
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
       }
@@ -787,20 +804,20 @@
       }
 
    }
-   
-   
+
+
    public void test1PCSendRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
       try
       {
          conn = cf.createXAConnection();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
 
@@ -810,19 +827,19 @@
          MessageProducer prod = sess.createProducer(queue);
          prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
          Message m = sess.createTextMessage("XATest1");
-         prod.send(queue, m); 
+         prod.send(queue, m);
          m = sess.createTextMessage("XATest2");
-         prod.send(queue, m); 
-         
-         tx.rollback();
-         
+         prod.send(queue, m);
+
+         tm.rollback();
+
          conn2 = cf.createConnection();
          conn2.start();
          Session sessReceiver = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sessReceiver.createConsumer(queue);
-         Message m2 = cons.receive(1000);
+         Message m2 = cons.receive(MIN_TIMEOUT);
          assertNull(m2);
-   
+
       }
       finally
       {
@@ -840,10 +857,10 @@
    public void test1PCReceiveCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -854,44 +871,44 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
          conn.start();
-         
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
-         
+
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         m2 = (TextMessage)cons.receive(1000);
-         
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.commit();
-         
+
+         tm.commit();
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
-         
-         Message m3 = cons.receive(1000);
-         
+
+         Message m3 = cons.receive(MIN_TIMEOUT);
+
          assertNull(m3);
-         
+
          tm.commit();
-         
 
+
       }
       finally
       {
@@ -904,16 +921,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void test1PCReceiveRollback() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          conn2 = cf.createConnection();
@@ -923,53 +940,53 @@
          prod.send(m);
          m = sessProducer.createTextMessage("XATest2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          XASession sess = conn.createXASession();
          XAResource res = sess.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res);
 
          MessageConsumer cons = sess.createConsumer(queue);
-         
 
-         TextMessage m2 = (TextMessage)cons.receive(1000);
-         
+
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest1", m2.getText());
-         
-         m2 = (TextMessage)cons.receive(1000);
-         
+
+         m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m2);
          assertEquals("XATest2", m2.getText());
-         
-         tx.rollback();
-         
+
+         tm.rollback();
+
          //Message should be redelivered
-         
+
          //New tx
          tm.begin();
          tx = tm.getTransaction();
          tx.enlistResource(res);
-         
-         TextMessage m3 = (TextMessage)cons.receive(1000);
-         
+
+         TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m3);
          assertEquals("XATest1", m3.getText());
-         
-         m3 = (TextMessage)cons.receive(1000);
-         
+
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
+
          assertNotNull(m3);
          assertEquals("XATest2", m3.getText());
-         
+
          assertTrue(m3.getJMSRedelivered());
-         
+
          tm.commit();
 
       }
@@ -984,18 +1001,18 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitAcknowledge1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       try
       {
          //First send 2 messages
@@ -1006,49 +1023,47 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          XAResource res2 = sess2.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, one on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-                  
+
          cons1.close();
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
-         //commit        
-         tx.commit();
-         
+
+         //commit
+         tm.commit();
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+
+         TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
-       
-         
 
       }
       finally
@@ -1062,16 +1077,16 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       try
       {
          //First send 2 messages
@@ -1082,13 +1097,13 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1096,36 +1111,36 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, one on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-                  
+
          cons1.close();
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
-         //commit        
-         tx.commit();
-         
+
+         //commit
+         tm.commit();
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+
+         TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
-       
+
       }
       finally
       {
@@ -1138,19 +1153,19 @@
             conn2.close();
          }
       }
-      
+
    }
-   
-   
+
+
    public void testMultipleSessionsOneTxRollbackAcknowledge1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       try
       {
          //First send 2 messages
@@ -1165,74 +1180,128 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
- 
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, two on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
-         r1 = (TextMessage)cons1.receive(1000);
-         
+
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
-                  
+
          cons1.close();
-      
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+
          assertNotNull(r2);
          assertEquals("jellyfish3", r2.getText());
-         
-         r2 = (TextMessage)cons2.receive(1000);
-         
+
+         r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+
          assertNotNull(r2);
          assertEquals("jellyfish4", r2.getText());
+
+         cons2.close();
+
+         //rollback
+
+         tm.rollback();
+           
+         //Rollback causes cancel which is asynch
+         Thread.sleep(1000);
          
-         cons2.close();            
+         //We cannot assume anything about the order in which the transaction manager rollsback
+         //the sessions - this is implementation dependent
+
+         Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sess.createConsumer(queue);
+         conn2.start();         
          
-         //rollback                          
+         TextMessage r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(r);
          
-         tx.rollback();
+         boolean session1First = false;
          
-         Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageConsumer cons = sess.createConsumer(queue);
-         conn2.start();
+         if (r.getText().equals("jellyfish1"))
+         {
+            session1First = true;
+         }
+         else if (r.getText().equals("jellyfish3"))
+         {
+            session1First = false;
+         }
+         else
+         {
+            fail("Unexpected message");
+         }
          
-         TextMessage r3 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r3);
-         assertEquals("jellyfish1", r3.getText());
+         if (session1First)
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish3", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            
+         }
+         else
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish1", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+         }
          
-         r3 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r3);
-         assertEquals("jellyfish2", r3.getText());
-
-         TextMessage r4 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r4);
-         assertEquals("jellyfish3", r4.getText());
-
-         r4 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r4);
-         assertEquals("jellyfish4", r4.getText());
+         r = (TextMessage)cons.receive(MIN_TIMEOUT);
          
+         assertNull(r);
 
       }
       finally
@@ -1246,13 +1315,13 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxRollbackAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
 
@@ -1270,13 +1339,13 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
-         
-         
+
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1284,69 +1353,119 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          //Receive the messages, two on each consumer
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
-         r1 = (TextMessage)cons1.receive(1000);
-         
+
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
-                  
+
          cons1.close();
-         
+
          MessageConsumer cons2 = sess2.createConsumer(queue);
-         TextMessage r2 = (TextMessage)cons2.receive(1000);
-         
+         TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+
          assertNotNull(r2);
          assertEquals("jellyfish3", r2.getText());
-         
-         r2 = (TextMessage)cons2.receive(1000);
-         
+
+         r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+
          assertNotNull(r2);
          assertEquals("jellyfish4", r2.getText());
-         
-         //rollback                 
-         
+
+         //rollback
+
          cons2.close();
+
+         tm.rollback();
          
-         tx.rollback();
+         // Rollback causes cancel which is asynch
+         Thread.sleep(1000);
          
+         //We cannot assume anything about the order in which the transaction manager rollsback
+         //the sessions - this is implementation dependent
+
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
+
+         TextMessage r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(r);
          
-         //NOTE
-         //The order here is actually probably dependent on the transaction manager implementation
-         //In this case, rollback will be called on each session, but whether it is called first on res1
-         //or res2 determines the order the messages are put back in the queue
-         //This test assumes it is called in order res1, res2
+         boolean session1First = false;
          
-         TextMessage r3 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r3);
-         assertEquals("jellyfish3", r3.getText());
+         if (r.getText().equals("jellyfish1"))
+         {
+            session1First = true;
+         }
+         else if (r.getText().equals("jellyfish3"))
+         {
+            session1First = false;
+         }
+         else
+         {
+            fail("Unexpected message");
+         }
          
-         r3 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r3);
-         assertEquals("jellyfish4", r3.getText());
-
-         TextMessage r4 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r4);
-         assertEquals("jellyfish1", r4.getText());
-  
-         r4 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r4);
-         assertEquals("jellyfish2", r4.getText());
+         if (session1First)
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish3", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            
+         }
+         else
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish1", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+         }
          
+         r = (TextMessage)cons.receive(MIN_TIMEOUT);
+         
+         assertNull(r);
 
+
       }
       finally
       {
@@ -1359,13 +1478,13 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxRollbackAcknowledgeForceFailureInCommit() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
       Connection conn2 = null;
 
@@ -1375,6 +1494,7 @@
          conn2 = cf.createConnection();
          Session sessProducer = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageProducer prod  = sessProducer.createProducer(queue);
+         
          Message m = sessProducer.createTextMessage("jellyfish1");
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
@@ -1383,79 +1503,101 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
-         
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
+         conn.start();
          
          tm.begin();
-         
+
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
          DummyXAResource res2 = new DummyXAResource(true);
          res1.setPreventJoining(true);
-                  
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          MessageConsumer cons1 = sess1.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
-         
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
-         r1 = (TextMessage)cons1.receive(1000);
-         
+
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish2", r1.getText());
-         
-         r1 = (TextMessage)cons1.receive(1000);
-         
+
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
          assertNotNull(r1);
          assertEquals("jellyfish3", r1.getText());
+
+         r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+
+         assertNotNull(r1);
+         assertEquals("jellyfish4", r1.getText());
          
          r1 = (TextMessage)cons1.receive(1000);
          
-         assertNotNull(r1);
-         assertEquals("jellyfish4", r1.getText());
-                  
+         assertNull(r1);
+
          cons1.close();
+
+
+         //try and commit - and we're going to make the dummyxaresource throw an exception on commit,
+         //which should cause rollback to be called on the other resource
          
          
-         
-         //try and commit - and we're going to make the dummyxaresource throw an exception on commit,
-         //which should cause rollback to be called on the other resource
+         //rollback will cause an attemp to deliver messages locally to the original consumers.
+         //the original consumer has closed, so it will cancelled to the server
+         //the server cancel is asynch, so we need to sleep for a bit to make sure it completes
+         log.trace("Forcing failure");
          try
          {
-            tx.commit();
+            tm.commit();
+            fail("should not get here");
          }
          catch (Exception e)
          {
             //We should expect this
          }
          
+         Thread.sleep(1000);
+         
+         
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-          
-         TextMessage r3 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r3);
-         assertEquals("jellyfish1", r3.getText());
+
+         TextMessage r = (TextMessage)cons.receive(MAX_TIMEOUT);
          
-         r3 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r3);
-         assertEquals("jellyfish2", r3.getText());
-  
-         TextMessage r4 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r4);
-         assertEquals("jellyfish3", r4.getText());
-      
-         r4 = (TextMessage)cons.receive(1000);         
-         assertNotNull(r4);
-         assertEquals("jellyfish4", r4.getText());
+         assertNotNull(r);
          
-
+         assertEquals("jellyfish1", r.getText());
+         
+         r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish2", r.getText());
+         
+         r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish3", r.getText());
+         
+         r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish4", r.getText());         
+         
+         r = (TextMessage)cons.receive(MIN_TIMEOUT);
+         
+         assertNull(r);
       }
       finally
       {
@@ -1468,60 +1610,59 @@
             conn2.close();
          }
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitSend1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          XAResource res2 = sess2.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //commit
-         tx.commit();
-         
+         tm.commit();
+
          //Messages should be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+
+         TextMessage r1 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("echidna1", r1.getText());
-         
-         TextMessage r2 = (TextMessage)cons.receive(1000);
+
+         TextMessage r2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("echidna2", r2.getText());
 
@@ -1538,27 +1679,27 @@
          }
 
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxCommitSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1566,34 +1707,34 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //commit
-         tx.commit();
-         
+         tm.commit();
+
          //Messages should be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+
+         TextMessage r1 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("echidna1", r1.getText());
-         
-         TextMessage r2 = (TextMessage)cons.receive(1000);
+
+         TextMessage r2 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("echidna2", r2.getText());
 
@@ -1610,60 +1751,60 @@
          }
 
       }
-      
+
    }
-   
-   
+
+
    public void testMultipleSessionsOneTxRollbackSend1PCOptimization() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       //Since both resources have some RM, TM will probably use 1PC optimization
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
          XASession sess2 = conn.createXASession();
          XAResource res2 = sess2.getXAResource();
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //rollback
-         tx.rollback();
-         
+         tm.rollback();
+
          //Messages should not be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+
+         TextMessage r1 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r1);
-         
 
+
       }
       finally
       {
@@ -1677,25 +1818,25 @@
          }
 
       }
-      
+
    }
-   
+
    public void testMultipleSessionsOneTxRollbackSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
-         conn.start();   
-         
+         conn.start();
+
          tm.begin();
-         
+
          //Create 2 sessions and enlist them
          XASession sess1 = conn.createXASession();
          MessagingXAResource res1 = (MessagingXAResource)sess1.getXAResource();
@@ -1703,33 +1844,33 @@
          MessagingXAResource res2 = (MessagingXAResource)sess2.getXAResource();
          res1.setPreventJoining(true);
          res2.setPreventJoining(true);
-         
+
          Transaction tx = tm.getTransaction();
          tx.enlistResource(res1);
          tx.enlistResource(res2);
-         
+
          // Send 2 messages - one from each session
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
          MessageProducer prod2 = sess2.createProducer(queue);
-         
+
          prod1.send(sess1.createTextMessage("echidna1"));
          prod2.send(sess2.createTextMessage("echidna2"));
-         
+
          //rollback
-         tx.rollback();
-         
+         tm.rollback();
+
          //Messages should not be in queue
-         
+
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
-         
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+
+         TextMessage r1 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r1);
-         
 
+
       }
       finally
       {
@@ -1743,20 +1884,20 @@
          }
 
       }
-      
+
    }
-   
- 
+
+
    public void testOneSessionTwoTransactionsCommitAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
-      {         
+      {
          //First send 2 messages
          conn2 = cf.createConnection();
          Session sessProducer = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1765,56 +1906,56 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-                  
+
          conn.start();
          MessageConsumer cons1 = sess1.createConsumer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Receive one message in one tx
-         
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-                  
+
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Receive 2nd message in a different tx
-         TextMessage r2 = (TextMessage)cons1.receive(1000);
+         TextMessage r2 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
+
          //commit this transaction
-         tx2.commit();
-         
+         tm.commit();
+
          //verify that no messages are available
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
-         
+
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
-         
+         tm.commit();
 
+
       }
       finally
       {
@@ -1828,20 +1969,20 @@
          }
 
       }
-      
+
    }
-   
-   
+
+
    public void testOneSessionTwoTransactionsRollbackAcknowledge() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-       
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
-      {         
+      {
          //First send 2 messages
          conn2 = cf.createConnection();
          Session sessProducer = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
@@ -1850,70 +1991,70 @@
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
          prod.send(m);
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-                  
+
          conn.start();
          MessageConsumer cons1 = sess1.createConsumer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Receive one message in one tx
-         
-         TextMessage r1 = (TextMessage)cons1.receive(1000);
+
+         TextMessage r1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("jellyfish1", r1.getText());
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-                  
+
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Receive 2nd message in a different tx
-         TextMessage r2 = (TextMessage)cons1.receive(1000);
+         TextMessage r2 = (TextMessage)cons1.receive(MAX_TIMEOUT);
          assertNotNull(r2);
          assertEquals("jellyfish2", r2.getText());
-         
+
          cons1.close();
-         
+
          //rollback this transaction
-         tx2.rollback();
-     
+         tm.rollback();
+
          //verify that second message is available
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
 
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
 
          assertNotNull(r3);
          assertEquals("jellyfish2", r3.getText());
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
-         
-         
+
+
          //rollback the other tx
          tm.resume(suspended);
-         suspended.rollback();
-       
+         tm.rollback();
+
          //Verify the first message is now available
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("jellyfish1", r3.getText());
-         r3 = (TextMessage)cons.receive(1000);
+         r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
-         
+
       }
       finally
       {
@@ -1927,72 +2068,72 @@
          }
 
       }
-      
+
    }
-   
 
+
    public void testOneSessionTwoTransactionsCommitSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo1"));
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-         
+
          //Send another message in another tx using the same session
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo2"));
-         
+
          //commit this transaction
-         tx2.commit();
-         
+         tm.commit();
+
          //verify only kangaroo2 message is sent
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r1);
          assertEquals("kangaroo2", r1.getText());
-         TextMessage r2 = (TextMessage)cons.receive(1000);
+         TextMessage r2 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r2);
-         
+
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
-         
+         tm.commit();
+
          //verify that the first text message is received
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("kangaroo1", r3.getText());
-         
+
       }
       finally
       {
@@ -2006,70 +2147,71 @@
          }
 
       }
-      
+
    }
-   
-   
+
+
    public void testOneSessionTwoTransactionsRollbackSend() throws Exception
    {
       if (ServerManagement.isRemote()) return;
-      
+
       XAConnection conn = null;
-      
+
       Connection conn2 = null;
-      
+
       try
       {
-         
+
          conn = cf.createXAConnection();
 
          //Create a session
          XASession sess1 = conn.createXASession();
          XAResource res1 = sess1.getXAResource();
-         
+
          MessageProducer prod1 = sess1.createProducer(queue);
-                  
+
          tm.begin();
-         
+
          Transaction tx1 = tm.getTransaction();
          tx1.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo1"));
-         
+
          //suspend the tx
          Transaction suspended = tm.suspend();
-         
+
          tm.begin();
-         
+
          //Send another message in another tx using the same session
          Transaction tx2 = tm.getTransaction();
          tx2.enlistResource(res1);
-         
+
          //Send a message
          prod1.send(sess1.createTextMessage("kangaroo2"));
-         
+
          //rollback this transaction
-         tx2.rollback();
-         
+         tm.rollback();
+
          //verify no messages are sent
          conn2 = cf.createConnection();
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          conn2.start();
          MessageConsumer cons = sess.createConsumer(queue);
-         TextMessage r1 = (TextMessage)cons.receive(1000);
+         TextMessage r1 = (TextMessage)cons.receive(MIN_TIMEOUT);
+
          assertNull(r1);
-         
-         
+
+
          //now resume the first tx and then commit it
          tm.resume(suspended);
-         suspended.commit();
-         
+         tm.commit();
+
          //verify that the first text message is received
-         TextMessage r3 = (TextMessage)cons.receive(1000);
+         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
          assertNotNull(r3);
          assertEquals("kangaroo1", r3.getText());
-         
+
       }
       finally
       {
@@ -2083,9 +2225,9 @@
          }
 
       }
-      
+
    }
-   
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -1055,9 +1055,9 @@
       log.info("++testTopicSubscriber");
 
       log.info(">>Lookup Queue");
+      
       Destination destination = (Destination) topic[1];
 
-
       Connection conn1 = cf.createConnection();
       Connection conn2 = cf.createConnection();
 
@@ -1067,7 +1067,7 @@
       conn.setClientID("testClient");
       conn.start();
 
-      JBossSession session = (JBossSession) conn.createSession(true, Session.AUTO_ACKNOWLEDGE);
+      JBossSession session = (JBossSession) conn.createSession(true, Session.SESSION_TRANSACTED);
       ClientSessionDelegate clientSessionDelegate = (ClientSessionDelegate) session.getDelegate();
       SessionState sessionState = (SessionState) clientSessionDelegate.getState();
 
@@ -1080,7 +1080,6 @@
 
       log.info("subscriptionName=" + consumerState.getSubscriptionName());
 
-
       log.info(">>Creating Producer");
       MessageProducer producer = session.createProducer(destination);
       log.info(">>creating Message");
@@ -1104,7 +1103,7 @@
 
       ServerManagement.kill(1);
 
-      Thread.sleep(30000);
+      Thread.sleep(60000);
       // if failover happened, this object was replaced
       assertNotSame(originalRemoting, delegate.getRemotingConnection());
 
@@ -1125,7 +1124,6 @@
       receiveMessage("consumerHA", consumerHA, true, false);
       receiveMessage("consumerHA", consumerHA, true, true);
 
-
       session.commit();
       conn1.close();
       conn2.close();
@@ -1390,7 +1388,8 @@
       if (message != null)
       {
          log.info(text + ": messageID from messageReceived=" + message.getMessage().getMessageID() + " message = " + message + " content=" + txtMessage.getText());
-      } else
+      }
+      else
       {
          log.info(text + ": Message received was null");
       }
@@ -1399,7 +1398,8 @@
          if (shouldBeNull)
          {
             assertNull(message);
-         } else
+         }
+         else
          {
             assertNotNull(message);
          }

Modified: trunk/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/tests/src/org/jboss/test/messaging/jms/message/ObjectMessageDeliveryTest.java	2006-12-21 23:41:19 UTC (rev 1843)
@@ -37,11 +37,12 @@
 import org.jboss.test.messaging.MessagingTestCase;
 import org.jboss.test.messaging.tools.ServerManagement;
 
+
 /**
  * 
  * A ObjectMessageDeliveryTest
-
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -143,11 +144,11 @@
          
          publisher.send(om3);
          
-         ObjectMessage rm1 = (ObjectMessage)sub.receive(1000);
+         ObjectMessage rm1 = (ObjectMessage)sub.receive(MAX_TIMEOUT);
          
-         ObjectMessage rm2 = (ObjectMessage)sub.receive(1000);
+         ObjectMessage rm2 = (ObjectMessage)sub.receive(MAX_TIMEOUT);
          
-         ObjectMessage rm3 = (ObjectMessage)sub.receive(1000);
+         ObjectMessage rm3 = (ObjectMessage)sub.receive(MAX_TIMEOUT);
          
          assertNotNull(rm1);
          

Copied: trunk/tests/src/org/jboss/test/messaging/jms/stress/ConcurrentCloseStressTest.java (from rev 1823, branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/stress/ConcurrentCloseStressTest.java)

Copied: trunk/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java (from rev 1823, branches/Branch_1_0/tests/src/org/jboss/test/messaging/util/TransactionManagerLocator.java)

Modified: trunk/util/do-not-distribute.properties
===================================================================
--- trunk/util/do-not-distribute.properties	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/util/do-not-distribute.properties	2006-12-21 23:41:19 UTC (rev 1843)
@@ -2,7 +2,15 @@
 # This file provides values for in-workarea example testing.
 # DO NOT DISTRIBUTE!
 #
+<<<<<<< .working
 #jboss.home=/home/clebert/workspaces/jboss-4.0-tmp/build/output/jboss-4.0.5.GA
+=======
+#jboss.home=C:\\work/src/jboss-4.0.1sp1-src/build/output/jboss-4.0.1sp1
+#jboss.home=C:\\work/src/cvs/jboss-head/build/output/jboss-5.0.0.Alpha
+#jboss.home=C:\\work\\src\\jboss-4.0.3SP1-src\\build\\output\\jboss-4.0.3SP1
+jboss.home=C:\\work\\src\\jboss-4.0.4.GA-src\\build\\output\\jboss-4.0.4.GA
+jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3
+>>>>>>> .merge-right.r1823
 messaging.config.name=messaging
 main.artifact.location=../output/lib
 auxiliary.artifacts.location=../src/etc/server/default/deploy

Modified: trunk/util/release-admin.xml
===================================================================
--- trunk/util/release-admin.xml	2006-12-20 20:49:40 UTC (rev 1842)
+++ trunk/util/release-admin.xml	2006-12-21 23:41:19 UTC (rev 1843)
@@ -19,10 +19,20 @@
    <property name="messaging.config.name" value="messaging"/>
    <property name="id" value="0"/>
    <property name="database" value="mysql"/>
+   <property name="thirdparty.home" value="../thirdparty"/>
+   <property name="thirdparty.jbossts.home" value="${thirdparty.home}/jboss/jbossts"/>
+   <property name="lib.home" value="../lib"/>
+   <property name="lib.jbossts.home" value="${lib.home}/jbossts"/>
+   <property name="output.lib.home" value="../output/lib"/>
 
+<<<<<<< .working
    <!--
         DO NOT change these values here, otherwise the installation script won't work. If you need
         to change them, to it in do-not-distribute.properties.
+=======
+   <!-- DO NOT change this value here, otherwise the installation script won't work. Change it in
+        do-not-distribute.properties.
+>>>>>>> .merge-right.r1823
    -->
    <property name="main.artifact.location" value=".."/>
    <property name="auxiliary.artifacts.location" value="../examples/config"/>
@@ -116,6 +126,22 @@
          <substitution expression="&lt;category name=&quot;org.jboss.serial&quot;&gt;&#013;&#010;      &lt;priority value=&quot;INFO&quot;/&gt;&#013;&#010;   &lt;/category&gt;&#013;&#010;&#013;&#010;   \1"/>
       </replaceregexp>
 
+      <!-- Replace local TM with JBossTS -->
+      
+      <copy file="${thirdparty.jbossts.home}/lib/jbossjta.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+      <copy file="${thirdparty.jbossts.home}/lib/jbossjta-integration.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+      <copy file="${thirdparty.jbossts.home}/lib/jbossts-common.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+      <copy file="${lib.jbossts.home}/jbossjta-properties.xml"
+            todir="${jboss.home}/server/${messaging.config.name}/conf"/>
+      <copy overwrite="true" 
+            file="${lib.jbossts.home}/jboss-service.xml"
+            todir="${jboss.home}/server/${messaging.config.name}/conf"/>
+      <copy file="${output.lib.home}/jboss-messaging-integration.jar"
+            todir="${jboss.home}/server/${messaging.config.name}/lib"/>
+            
       <!-- copy the scoped sar
       <copy todir="${jboss.home}/server/${config.name}/deploy"
             file="${relative.sar.location}/${messaging.sar.name}"/>



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 18:43:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 18:43:17 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1844 -
	trunk/src/main/org/jboss/jms/tx
Message-ID: <E1GxXZF-0001MR-QF@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-21 18:43:16 -0500 (Thu, 21 Dec 2006)
New Revision: 1844

Added:
   trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
Log:
Added missing file



Added: trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-21 23:41:19 UTC (rev 1843)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-21 23:43:16 UTC (rev 1844)
@@ -0,0 +1,161 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.jms.tx;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * This class manages instances of ResourceManager. It ensures there is one instance per instance
+ * of JMS server as specified by the server id.
+ * 
+ * This allows different JMS connections to the same JMS server (the underlying resource is the JMS server)
+ * to use the same resource manager.
+ * 
+ * This means isSameRM() on XAResource returns true, allowing the Transaction manager to join work in one
+ * tx to another thus allowing 1PC optimization which should help performance.
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version $Revision: 1329 $
+ *
+ * $Id: ResourceManagerFactory.java 1329 2006-09-20 21:29:56Z ovidiu.feodorov at jboss.com $
+ */
+public class ResourceManagerFactory
+{      
+   public static ResourceManagerFactory instance = new ResourceManagerFactory();
+   
+   private Map holders;
+   
+   private ResourceManagerFactory()
+   {      
+      holders = new HashMap();
+   }
+   
+   /*
+    * Need to failover rm from old server id to new server id, merging resource managers if it already exists
+    */
+   public synchronized void handleFailover(int oldServerId, int newServerId)
+   {       
+      Holder hOld = (Holder)holders.remove(new Integer(oldServerId));
+      
+      if (hOld == null)
+      {
+         //This is ok - this would happen if there are more than one connections for the old server failing
+         //in which only the first one to fail would failover the resource manager factory - since they
+         //share the same rm
+         return;
+      }
+      
+      ResourceManager oldRM = hOld.rm;
+      
+      ResourceManager newRM = null;
+      
+      Holder hNew = (Holder)holders.get(new Integer(newServerId));      
+      
+      if (hNew != null)
+      {
+         //Need to merge into the new
+         
+         newRM = hNew.rm;
+         
+         newRM.merge(oldRM);         
+      }
+      else
+      {
+         //re-register the old rm with the new id
+         
+         Holder h = new Holder(oldRM);
+         
+         holders.put(new Integer(newServerId), h);
+      }  
+   }
+   
+   public synchronized int size()
+   {
+      return holders.size();
+   }
+      
+   public synchronized boolean containsResourceManager(int serverID)
+   {
+      return holders.containsKey(new Integer(serverID));
+   }
+   
+   /**
+    * @param serverID - server peer ID.
+    */
+   public synchronized ResourceManager checkOutResourceManager(int serverID)
+   {
+      Integer i = new Integer(serverID);
+      
+      Holder h = (Holder)holders.get(i);
+      
+      if (h == null)
+      {
+         h = new Holder();
+         
+         holders.put(i, h);
+      }
+      else
+      {
+         h.refCount++;
+      }
+      
+      return h.rm;
+   }
+   
+   public synchronized void checkInResourceManager(int serverID)
+   {
+      Integer i = new Integer(serverID);
+      
+      Holder h = (Holder)holders.get(i);
+      
+      if (h == null)
+      {
+         throw new IllegalArgumentException("Cannot find resource manager for server: " + serverID);
+      }
+      
+      h.refCount--;
+      
+      if (h.refCount == 0)
+      {
+         holders.remove(i);
+      }      
+   }
+   
+   private class Holder
+   {
+      ResourceManager rm;
+      
+      Holder()
+      {
+         rm = new ResourceManager();
+      }
+      
+      Holder(ResourceManager rm)
+      {
+         this.rm = rm;
+      }
+      
+      int refCount = 1;
+   }
+  
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 21 19:34:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 21 Dec 2006 19:34:26 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1845 - in branches/Branch_1_0: .
	src/etc/server/default/deploy
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/plugin
	src/main/org/jboss/jms/server/plugin/contract
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/plugin
	src/main/org/jboss/messaging/core/plugin/contract
	src/main/org/jboss/messaging/core/tx tests
	tests/src/org/jboss/test/messaging
	tests/src/org/jboss/test/messaging/core
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GxYMk-0002JC-LI@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-21 19:34:08 -0500 (Thu, 21 Dec 2006)
New Revision: 1845

Modified:
   branches/Branch_1_0/.classpath
   branches/Branch_1_0/src/etc/server/default/deploy/mssql-persistence-service.xml
   branches/Branch_1_0/src/etc/server/default/deploy/mysql-persistence-service.xml
   branches/Branch_1_0/src/etc/server/default/deploy/oracle-persistence-service.xml
   branches/Branch_1_0/src/etc/server/default/deploy/postgresql-persistence-service.xml
   branches/Branch_1_0/src/etc/server/default/deploy/sybase-persistence-service.xml
   branches/Branch_1_0/src/main/org/jboss/jms/client/container/SessionAspect.java
   branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/JDBCChannelMapper.java
   branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/contract/ChannelMapper.java
   branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/Channel.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/Transaction.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java
   branches/Branch_1_0/tests/build.xml
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
   branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
Log:
Backmerged xa recovery to 1_0 after changes made after merge from 1_0 to trunk



Modified: branches/Branch_1_0/.classpath
===================================================================
--- branches/Branch_1_0/.classpath	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/.classpath	2006-12-22 00:34:08 UTC (rev 1845)
@@ -21,7 +21,6 @@
 	<classpathentry kind="lib" path="lib/jboss-system.jar"/>
 	<classpathentry kind="lib" path="lib/jboss-transaction.jar"/>
 	<classpathentry kind="lib" path="lib/jnp-client.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/jboss-common.jar"/>
 	<classpathentry kind="lib" path="thirdparty/oswego-concurrent/lib/concurrent.jar"/>
 	<classpathentry kind="lib" path="tests/lib/jboss-common-jdbc-wrapper.jar"/>
 	<classpathentry kind="lib" path="tests/lib/jboss-jca.jar"/>
@@ -30,15 +29,13 @@
 	<classpathentry kind="lib" path="tests/lib/jms-ra.jar"/>
 	<classpathentry kind="lib" path="tests/lib/mysql-connector-java-3.1.13-bin.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jgroups/lib/jgroups.jar"/>
-	<classpathentry kind="lib" path="perf/resources/jcommon-1.0.0-rc1.jar"/>
-	<classpathentry kind="lib" path="perf/resources/jfreechart-1.0.0-rc1.jar"/>
 	<classpathentry kind="lib" path="thirdparty/apache-log4j/lib/log4j.jar"/>
 	<classpathentry sourcepath="/home/clebert/workspaces/jboss-head/aop/src/main" kind="lib" path="thirdparty/jboss/aop/lib/jboss-aop.jar"/>
 	<classpathentry kind="lib" path="thirdparty/junit/lib/junit.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/profiler/jvmti/lib/jboss-profiler-jvmti.jar"/>
 	<classpathentry kind="lib" path="thirdparty/hsqldb/lib/hsqldb.jar"/>
 	<classpathentry kind="lib" path="thirdparty/apache-logging/lib/commons-logging.jar"/>
-	<classpathentry kind="var" path="ANT_HOME/ant-junit.jar"/>
+	<classpathentry kind="var" path="ANT_HOME/lib/ant-junit.jar"/>
 	<classpathentry sourcepath="/JBossRemoting" kind="lib" path="thirdparty/jboss/remoting/lib/jboss-remoting.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/serialization/lib/jboss-serialization.jar"/>
 	<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
@@ -56,13 +53,14 @@
 	<classpathentry kind="lib" path="thirdparty/jboss/aop/lib/jdk14-pluggable-instrumentor.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/aop/lib/jrockit-pluggable-instrumentor.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/aop/lib/pluggable-instrumentor.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/jboss-archive-browsing.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/jboss-common-client.jar"/>
-	<classpathentry kind="lib" path="thirdparty/jboss/common/lib/namespace.jar"/>
 	<classpathentry kind="lib" path="thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
 	<classpathentry kind="lib" path="thirdparty/retrotranslator/lib/backport-util-concurrent.jar"/>
 	<classpathentry kind="lib" path="thirdparty/retrotranslator/lib/retrotranslator-runtime.jar"/>
 	<classpathentry kind="lib" path="thirdparty/retrotranslator/lib/retrotranslator-transformer.jar"/>
 	<classpathentry kind="lib" path="thirdparty/trove/lib/trove.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/jbossts/lib/jbossjta.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/common-logging-log4j/lib/jboss-logging-log4j.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/common-core/lib/jboss-common-core.jar"/>
+	<classpathentry kind="lib" path="thirdparty/jboss/common-logging-spi/lib/jboss-logging-spi.jar"/>
 	<classpathentry kind="output" path="bin"/>
 </classpath>

Modified: branches/Branch_1_0/src/etc/server/default/deploy/mssql-persistence-service.xml
===================================================================
--- branches/Branch_1_0/src/etc/server/default/deploy/mssql-persistence-service.xml	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/etc/server/default/deploy/mssql-persistence-service.xml	2006-12-22 00:34:08 UTC (rev 1845)
@@ -32,11 +32,11 @@
 COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
 ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
 ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
-LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
-SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'
-UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'
+LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
+SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED='N'
+UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE = 'C'
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?
-SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'
+SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N'
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
 UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY TINYINT, COREHEADERS IMAGE, PAYLOAD IMAGE, CHANNELCOUNT INTEGER, TYPE TINYINT, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES IMAGE, DESTINATION_ID BIGINT, REPLYTO_ID BIGINT, JMSPROPERTIES IMAGE, PRIMARY KEY (MESSAGEID))
@@ -58,6 +58,8 @@
 INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
 DELETE_ALL_COUNTERS=DELETE FROM JMS_COUNTER
 SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
+SELECT_MESSAGEID_FOR_REFS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+SELECT_MESSAGEID_FOR_ACKS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'
            ]]></attribute>
       <attribute name="MaxParams">500</attribute>
    </mbean>

Modified: branches/Branch_1_0/src/etc/server/default/deploy/mysql-persistence-service.xml
===================================================================
--- branches/Branch_1_0/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/etc/server/default/deploy/mysql-persistence-service.xml	2006-12-22 00:34:08 UTC (rev 1845)
@@ -32,11 +32,11 @@
 COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
 ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
 ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
-LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
-SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'      
-UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'      
+LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
+SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED='N'      
+UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE = 'C'      
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?  
-SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'          
+SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N'          
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
 UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY TINYINT, COREHEADERS MEDIUMBLOB, PAYLOAD LONGBLOB, CHANNELCOUNT INTEGER, TYPE TINYINT, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES VARBINARY(254), DESTINATION_ID BIGINT, REPLYTO_ID BIGINT, JMSPROPERTIES MEDIUMBLOB, PRIMARY KEY (MESSAGEID))
@@ -58,6 +58,8 @@
 INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
 DELETE_ALL_COUNTERS=DELETE FROM JMS_COUNTER
 SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
+SELECT_MESSAGEID_FOR_REFS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+SELECT_MESSAGEID_FOR_ACKS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'
       ]]></attribute>
       <attribute name="MaxParams">500</attribute>
    </mbean>

Modified: branches/Branch_1_0/src/etc/server/default/deploy/oracle-persistence-service.xml
===================================================================
--- branches/Branch_1_0/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/etc/server/default/deploy/oracle-persistence-service.xml	2006-12-22 00:34:08 UTC (rev 1845)
@@ -32,11 +32,11 @@
 COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
 ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
 ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
-LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
-SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'      
-UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'      
+LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
+SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED='N'      
+UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE = 'C'      
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?   
-SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'             
+SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N'             
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
 UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID INTEGER, RELIABLE CHAR(1), EXPIRATION INTEGER, TIMESTAMP INTEGER, PRIORITY INTEGER, COREHEADERS BLOB, PAYLOAD BLOB, CHANNELCOUNT INTEGER, TYPE INTEGER, JMSTYPE VARCHAR2(255), CORRELATIONID VARCHAR2(255), CORRELATIONID_BYTES RAW(254), DESTINATION_ID INTEGER, REPLYTO_ID INTEGER, JMSPROPERTIES BLOB, PRIMARY KEY (MESSAGEID))
@@ -58,6 +58,8 @@
 INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
 DELETE_ALL_COUNTERS=DELETE FROM JMS_COUNTER
 SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
+SELECT_MESSAGEID_FOR_REFS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+SELECT_MESSAGEID_FOR_ACKS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'
       ]]></attribute>
       <attribute name="MaxParams">500</attribute>
    </mbean>      

Modified: branches/Branch_1_0/src/etc/server/default/deploy/postgresql-persistence-service.xml
===================================================================
--- branches/Branch_1_0/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/etc/server/default/deploy/postgresql-persistence-service.xml	2006-12-22 00:34:08 UTC (rev 1845)
@@ -32,11 +32,11 @@
 COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
 ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
 ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
-LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
-SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'
-UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'
+LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
+SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED='N'
+UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE = 'C'
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?
-SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'
+SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N'
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
 UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY int2, COREHEADERS BYTEA, PAYLOAD BYTEA, CHANNELCOUNT INTEGER, TYPE int2, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES BYTEA, DESTINATION_ID BIGINT, REPLYTO_ID BIGINT, JMSPROPERTIES BYTEA, PRIMARY KEY (MESSAGEID))
@@ -58,6 +58,8 @@
 INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
 DELETE_ALL_COUNTERS=DELETE FROM JMS_COUNTER
 SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
+SELECT_MESSAGEID_FOR_REFS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+SELECT_MESSAGEID_FOR_ACKS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'
            ]]></attribute>
       <attribute name="MaxParams">500</attribute>
    </mbean>

Modified: branches/Branch_1_0/src/etc/server/default/deploy/sybase-persistence-service.xml
===================================================================
--- branches/Branch_1_0/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/etc/server/default/deploy/sybase-persistence-service.xml	2006-12-22 00:34:08 UTC (rev 1845)
@@ -41,11 +41,11 @@
 COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
 ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
 ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
-LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
-SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'
-UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'
+LOAD_REF_INFO=SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N' AND ORD BETWEEN ? AND ? ORDER BY ORD
+SELECT_COUNT_REFS=SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED='N'
+UPDATE_RELIABLE_REFS=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE = 'C'
 UPDATE_RELIABLE_REFS_NOT_LOADED=UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?
-SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N'
+SELECT_MIN_ORDERING=SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N'
 DELETE_UNRELIABLE_REFS=DELETE FROM JMS_MESSAGE_REFERENCE WHERE RELIABLE = 'N'
 UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
 CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID INTEGER, RELIABLE CHAR(1) NULL, EXPIRATION INTEGER NULL, TIMESTAMP NUMERIC(20,0) NULL, PRIORITY INTEGER NULL, COREHEADERS IMAGE NULL, PAYLOAD IMAGE NULL, CHANNELCOUNT INTEGER NULL, TYPE INTEGER NULL, JMSTYPE VARCHAR(255) NULL, CORRELATIONID VARCHAR(255) NULL, CORRELATIONID_BYTES VARBINARY(254) NULL, DESTINATION_ID INTEGER NULL, REPLYTO_ID INTEGER NULL, JMSPROPERTIES IMAGE NULL, PRIMARY KEY (MESSAGEID))
@@ -66,6 +66,8 @@
 INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
 DELETE_ALL_COUNTERS=DELETE FROM JMS_COUNTER
 SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
+SELECT_MESSAGEID_FOR_REFS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '+'
+SELECT_MESSAGEID_FOR_ACKS=SELECT MESSAGEID, CHANNELID FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID = ? AND STATE = '-'
       ]]>
 		</attribute>
 	</mbean>

Modified: branches/Branch_1_0/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -295,7 +295,7 @@
     */
    public Object handleRedeliver(Invocation invocation) throws Throwable
    {
-      if (trace) { log.trace("redeliver called"); }
+      if (trace) { log.trace(this + " redeliver called"); }
       
       MethodInvocation mi = (MethodInvocation)invocation;
       SessionState state = getState(invocation);
@@ -318,10 +318,15 @@
          {
             // This is ok. The original consumer has closed, this message wil get cancelled back
             // to the channel.
+            
+            if (trace) { log.trace("Original consumer has closed, ddding message " + proxy + " to list of messages to cancel"); }
+            
             toCancel.addFirst(info);
          }
          else
          {
+            if (trace) { log.trace("Adding message " + proxy + " back to front of buffer"); }
+            
             handler.addToFrontOfBuffer(proxy);
          }                                    
       }

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -481,6 +481,8 @@
         
    public synchronized void cancelDeliveries(List ackInfos) throws JMSException
    {
+      if (trace) { log.trace(this + " cancelDeliveries " + ackInfos); }
+      
       try
       {
          if (closed)
@@ -522,6 +524,8 @@
             }
             else
             {            
+               if (trace) { log.trace("Cancelling delivery " + ack.getMessageID()); }
+               
                consumer.cancelDelivery(new Long(ack.getMessageID()), ack.getDeliveryCount());
             }
             

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/JDBCChannelMapper.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/JDBCChannelMapper.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/JDBCChannelMapper.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -23,6 +23,7 @@
 import java.util.Map;
 import java.util.Properties;
 import java.util.Set;
+import java.util.concurrent.ConcurrentHashMap;
 
 import javax.jms.JMSException;
 import javax.management.MBeanServerInvocationHandler;
@@ -126,6 +127,8 @@
    // Map<clientID - Map<subscriptionName - CoreDurableSubscription>>
    protected Map subscriptions;
    
+   protected Map channelIdSubMap;
+   
    // Map<name - Queue>
    protected Map queues;
    
@@ -159,6 +162,8 @@
       
       idMap = new ConcurrentReaderHashMap();
       
+      channelIdSubMap = new ConcurrentHashMap();
+      
       sqlProperties = new Properties();
       
       populateTables = new ArrayList();
@@ -247,6 +252,12 @@
    {
       return (JBossDestination)idMap.get(new Long(coreDestinationId));
    }      
+   
+   public CoreSubscription getDurableSubscription(long channelID)
+   {
+      return (CoreSubscription)channelIdSubMap.get(new Long(channelID));
+      
+   }
     
    public void deployCoreDestination(boolean isQueue, 
                                      String destName,
@@ -835,6 +846,8 @@
       {
          return null;
       }
+      
+      this.channelIdSubMap.remove(new Long(removed.getChannelID()));
    
       if (subs.size() == 0)
       {
@@ -1167,6 +1180,8 @@
       
       subs.put(subscriptionName, subscription);
       
+      channelIdSubMap.put(new Long(id), subscription);
+      
       return subscription;
    }   
    

Modified: branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/contract/ChannelMapper.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/contract/ChannelMapper.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/jms/server/plugin/contract/ChannelMapper.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -15,6 +15,7 @@
 import org.jboss.jms.server.subscription.DurableSubscription;
 import org.jboss.jms.server.subscription.Subscription;
 import org.jboss.messaging.core.local.CoreDestination;
+import org.jboss.messaging.core.local.CoreSubscription;
 import org.jboss.messaging.core.memory.MemoryManager;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -99,5 +100,7 @@
    void setPersistenceManager(PersistenceManager pm) throws Exception;
    
    void setQueuedExecutorPool(QueuedExecutorPool pool) throws Exception;
+   
+   CoreSubscription getDurableSubscription(long channelID);
 
 }

Modified: branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/jms/tx/ResourceManager.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -246,6 +246,8 @@
          tx.clearMessages();
       }
       
+      //it's possible the tx may not be here since the transaction manager is calling commit
+      //as part of the recovery process before recover is called
       if ((tx == null) || tx.getState() == TxState.TX_PREPARED)
       {
          request = new TransactionRequest(TransactionRequest.TWO_PHASE_ROLLBACK_REQUEST, xid, tx);
@@ -264,7 +266,12 @@
       
       try
       {
-         redeliverMessages(tx);
+         if (tx != null)
+         {
+            redeliverMessages(tx);
+            
+            tx.setState(TxState.TX_ROLLEDBACK);
+         }
       }
       catch (JMSException e)
       {
@@ -282,6 +289,8 @@
       // Sort messages into lists, one for each session. We use a LinkedHashMap since we need to
       // preserve the order of the sessions.
 
+      if (trace) { log.trace("Redelivering messages locally: " + ts.getAcks()); }
+      
       Map toAck = new LinkedHashMap();
 
       for(Iterator i = ts.getAcks().iterator(); i.hasNext(); )
@@ -296,7 +305,7 @@
             toAck.put(del, acks);
          }
          acks.add(ack);
-      }
+      }            
       
       // Now tell each session to redeliver.
       
@@ -309,11 +318,15 @@
          l.addFirst(entry);
       }
       
+      if (trace) { log.trace("There are " + l.size() + " sessions to redeliver locally"); }
+      
       for(Iterator i = l.iterator(); i.hasNext();)
       {
          Map.Entry entry = (Map.Entry)i.next();
          SessionDelegate sess = (SessionDelegate)entry.getKey();
          List acks = (List)entry.getValue();
+         
+         if (trace) { log.trace("Redelivering to sess " + sess); }
          sess.redeliver(acks);
       }  
    }
@@ -452,15 +465,23 @@
          try
          {
             Xid[] txs = conn.getPreparedTransactions();
+            
+            //Note- we only want to do replace the tx, if it doesn't already exist -
+            //remember recover can be called when the connection is still alive -
+            //we do not want to lose the client side transactional state!
 
             //populate with TxState --MK
-            for(int i = 0; i < txs.length;i++)
+            for( int i = 0; i < txs.length;i++)
             {
-               TxState tx = new TxState();
-
-               tx.setState(TxState.TX_PREPARED);
-
-               transactions.put(txs[i], tx);
+               // Don't overwrite if it is already there
+               if (!transactions.containsKey(txs[i]))
+               {
+                  TxState tx = new TxState();
+   
+                  tx.setState(TxState.TX_PREPARED);
+      
+                  transactions.put(txs[i], tx);            
+               }
             }
 
             return txs;

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/Channel.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/Channel.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/Channel.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -141,6 +141,8 @@
     * @throws Throwable
     */
    void removeAllReferences() throws Throwable;
+   
+   void addDelivery(Delivery del);
 
 }
 

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -413,9 +413,18 @@
          router.clear();
          router = null;
       }
+   }
 
+   
+   public void addDelivery(Delivery del)
+   {
+      synchronized (deliveryLock)
+      {
+         deliveries.add(del);
+      }
    }
 
+
    /*
     * This method clears the channel.
     * Basically it acknowledges any outstanding deliveries and consumes the rest of the messages in the channel.

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -36,10 +36,12 @@
 import java.util.Collections;
 import java.util.Comparator;
 import java.util.HashMap;
+import java.util.HashSet;
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
 import java.util.Properties;
+import java.util.Set;
 
 import javax.management.MBeanServer;
 import javax.management.MBeanServerInvocationHandler;
@@ -54,6 +56,7 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.plugin.contract.ChannelMapper;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.CoreDestination;
@@ -63,10 +66,10 @@
 import org.jboss.messaging.core.message.RoutableSupport;
 import org.jboss.messaging.core.persistence.JDBCUtil;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
+import org.jboss.messaging.core.tx.PreparedTxInfo;
 import org.jboss.messaging.core.tx.Transaction;
 import org.jboss.messaging.core.tx.TxCallback;
 import org.jboss.messaging.core.tx.XidImpl;
-import org.jboss.messaging.core.tx.PreparedTxInfo;
 import org.jboss.messaging.util.Util;
 import org.jboss.serial.io.JBossObjectInputStream;
 import org.jboss.serial.io.JBossObjectOutputStream;
@@ -135,17 +138,17 @@
    
    protected String loadReferenceInfo = 
       "SELECT MESSAGEID, ORD, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE "
-      + "WHERE CHANNELID=? AND STATE <> '+' AND LOADED = 'N' AND "
+      + "WHERE CHANNELID=? AND STATE = 'C' AND LOADED = 'N' AND "
       + "ORD BETWEEN ? AND ? ORDER BY ORD";
    
    protected String selectMinOrdering = 
       "SELECT MIN(ORD) FROM JMS_MESSAGE_REFERENCE WHERE "
-      + "CHANNELID=? AND STATE <> '+' AND LOADED = 'N'";
+      + "CHANNELID=? AND STATE = 'C' AND LOADED = 'N'";
    
-   protected String selectCountReferences = "SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE <> '+' AND LOADED='N'";
+   protected String selectCountReferences = "SELECT COUNT(MESSAGEID) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID=? AND STATE = 'C' AND LOADED='N'";
    
    protected String updateReliableRefs = 
-      "UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE <> '+'";
+      "UPDATE JMS_MESSAGE_REFERENCE SET LOADED='Y' WHERE ORD BETWEEN ? AND ? AND CHANNELID=? AND RELIABLE='Y' AND STATE = 'C'";
     
    protected String updateReliableRefsNotLoaded = "UPDATE JMS_MESSAGE_REFERENCE SET LOADED='N' WHERE CHANNELID=?";
    
@@ -609,21 +612,23 @@
       }
    }
    
-   public ChannelMapper getChannels()
+   public List getMessageChannelPairRefsForTx(long transactionId) throws Exception
    {
-	   return cm;
+      return getMessageChannelPair(selectMessageIdForRef, transactionId);
    }
-
-   public Map getMessageChannelPairForTx(long transactionId) throws Exception
+   
+   public List getMessageChannelPairAcksForTx(long transactionId) throws Exception
    {
-	   return getMessageChannelPair(selectMessageIdForRef, transactionId);
+      return getMessageChannelPair(selectMessageIdForAck, transactionId);
    }
-   public List getAcksForTx(long transactionId) throws Exception
+   
+   public ChannelMapper getChannels()
    {
-	   return new ArrayList(getMessageChannelPair(selectMessageIdForAck, transactionId).keySet());
+      return cm;
    }
 
-
+   
+   
    /*
     * Retrieve a List of messages corresponding to the specified List of message ids.
     * The implementation here for HSQLDB does this by using a PreparedStatment with an IN clause
@@ -4483,49 +4488,91 @@
    }
 
 
-   private Map getMessageChannelPair(String sqlQuery, long transactionId) throws Exception
+   private List getMessageChannelPair(String sqlQuery, long transactionId) throws Exception
    {
       if (trace) log.trace("loading message and channel ids for tx [" + transactionId + "]");
-
+      
       Connection conn = null;
       PreparedStatement ps = null;
       ResultSet rs = null;
       TransactionWrapper wrap = new TransactionWrapper();
-
+      
       try
       {
          conn = ds.getConnection();
-
+         
          ps = conn.prepareStatement(sqlQuery);
-
+         
          ps.setLong(1, transactionId);
-
+         
          rs = ps.executeQuery();
-
-         Map messageChannelPair = new HashMap();
-
-
+         
+         //Don't use a Map. A message could be in multiple channels in a tx, so if you use a map
+         //when you put the same message again it's going to overwrite the previous put!!
+         
+         List holders = new ArrayList();
+         
+         //Unique set of messages
+         Set msgIds = new HashSet();
+         
+         //TODO it would probably have been simpler just to have done all this in a SQL JOIN rather
+         //than do the join in memory.....
+         
+         class Holder
+         {
+            long messageId;
+            long channelId;
+            Holder(long messageId, long channelId)
+            {
+               this.messageId = messageId;
+               this.channelId = channelId;
+            }
+         }
+                  
          while(rs.next())
-         {
-        	   long messageId = rs.getLong(1);
+         {            
+            long messageId = rs.getLong(1);
             long channelId = rs.getLong(2);
-
-            messageChannelPair.put(new Long(messageId), new Long(channelId));
-
+            
+            Holder holder = new Holder(messageId, channelId);
+            
+            holders.add(holder);
+                        
+            msgIds.add(new Long(messageId));
+            
             if (trace) log.trace("Loaded MsgID: " + messageId + " and ChannelID: " + channelId);
          }
-
-         List messages = getMessages(new ArrayList(messageChannelPair.keySet()));
-
-         Map returnSet = new HashMap();
-
+         
+         Map messageMap = new HashMap();
+         
+         List messages = getMessages(new ArrayList(msgIds));
+         
          for (Iterator iter = messages.iterator(); iter.hasNext(); )
          {
             Message msg = (Message)iter.next();
-            returnSet.put(msg, messageChannelPair.get(new Long(msg.getMessageID())));
+            
+            messageMap.put(new Long(msg.getMessageID()), msg);            
          }
-
-         return returnSet;
+         
+         List returnList = new ArrayList();
+         
+         for (Iterator iter = holders.iterator(); iter.hasNext(); )
+         {
+            Holder holder = (Holder)iter.next();
+            
+            Message msg = (Message)messageMap.get(new Long(holder.messageId));
+            
+            if (msg == null)
+            {
+               throw new IllegalStateException("Cannot find message " + holder.messageId);
+            }
+            
+            MessageChannelPair pair = new MessageChannelPair(msg, holder.channelId);
+            
+            returnList.add(pair);
+         }
+         
+         return returnList;
       }
       catch (Exception e)
       {

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/plugin/contract/PersistenceManager.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -22,11 +22,11 @@
 package org.jboss.messaging.core.plugin.contract;
 
 import java.util.List;
-import java.util.Map;
 
+import org.jboss.jms.server.plugin.contract.ChannelMapper;
+import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.tx.Transaction;
-import org.jboss.jms.server.plugin.contract.ChannelMapper;
 
 /**
  * The interface to the persistence manager
@@ -44,12 +44,13 @@
 {
    List retrievePreparedTransactions() throws Exception;
 
+   List getMessageChannelPairRefsForTx(long transactionId) throws Exception;
+
+   List getMessageChannelPairAcksForTx(long transactionId) throws Exception;
+   
    ChannelMapper getChannels();
+   
 
-   Map getMessageChannelPairForTx(long transactionId) throws Exception;
-
-   List getAcksForTx(long transactionId) throws Exception;
-
    void resetLoadedStatus(long channelID) throws Exception;
       
    void addReference(long channelID, MessageReference ref, Transaction tx) throws Exception;
@@ -82,6 +83,30 @@
    // Interface value classes
    //---------------------------------------------------------------
    
+   class MessageChannelPair
+   {
+      private Message message;
+      
+      private long channelId;
+      
+      public MessageChannelPair(Message message, long channelId)
+      {
+         this.message = message;
+         
+         this.channelId = channelId;
+      }
+      
+      public Message getMessage()
+      {
+         return message;
+      }
+      
+      public long getChannelId()
+      {
+         return channelId;
+      }
+   }
+   
    class ReferenceInfo
    {
       private long messageId;

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/Transaction.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/Transaction.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/Transaction.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -70,6 +70,10 @@
    
    protected Map keyedCallbackMap;
    
+   private boolean loadedAtStartup;
+   
+   
+   
    // Static --------------------------------------------------------
    
    public static final int STATE_ACTIVE = 0;
@@ -324,6 +328,16 @@
       sb.append(stateToString(state));
       return sb.toString();
    }
+   
+   public boolean isLoadedAtStartup()
+   {
+      return this.loadedAtStartup;
+   }
+   
+   public void setLoadedAtStartup(boolean loadedAtStartup)
+   {
+      this.loadedAtStartup = loadedAtStartup;
+   }
 
    // Package protected ---------------------------------------------
    

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -25,17 +25,21 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+
 import javax.transaction.xa.Xid;
 
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.plugin.contract.ChannelMapper;
 import org.jboss.logging.Logger;
-import org.jboss.messaging.core.Delivery;
+import org.jboss.messaging.core.Channel;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.SimpleDelivery;
+import org.jboss.messaging.core.SingleReceiverDelivery;
 import org.jboss.messaging.core.local.CoreDestination;
+import org.jboss.messaging.core.local.CoreSubscription;
 import org.jboss.messaging.core.plugin.IdManager;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
@@ -71,7 +75,9 @@
    protected MessageStore messageStore;
 
    protected IdManager idManager;
-
+   
+   protected ChannelMapper channelMapper;
+   
    // Static --------------------------------------------------------
    
    // Constructors --------------------------------------------------
@@ -87,6 +93,8 @@
    {
       this.persistenceManager = persistenceManager;
       this.messageStore = store;
+      
+      this.channelMapper = persistenceManager.getChannels();
 
       //TODO make this configurable
       idManager = new IdManager("TRANSACTION_ID", 4096, persistenceManager);
@@ -102,64 +110,82 @@
     *
     * @return  List of Xid instances
     */
-	public List recoverPreparedTransactions()
+   public synchronized List recoverPreparedTransactions()
    {
-		ArrayList prepared = new ArrayList();
+      if (trace) { log.trace(this + " recoverPreparedTransactions()"); }
+      
+      ArrayList prepared = new ArrayList();
 
-		Iterator iter = globalToLocalMap.values().iterator();
+      Iterator iter = globalToLocalMap.values().iterator();
 
-		while (iter.hasNext())
+      while (iter.hasNext())
       {
-			Transaction tx = (Transaction) iter.next();
+         Transaction tx = (Transaction) iter.next();
 
-			if (tx.xid != null && tx.getState() == Transaction.STATE_PREPARED)
+         if (tx.getXid() != null && tx.getState() == Transaction.STATE_PREPARED)
          {
             try
             {
-               if(trace) log.trace("Loading and handling refs and acks to the Tx "+tx);
+               if (trace) log.trace("Loading and handling refs and acks to the Tx "+tx);
 
-               handleReferences(tx);
-               handleAcks(tx);
+               //The transaction might have been created, prepared, without the server crashing
+               //in which case the tx will already have the references and acks in them
+               //in this case we DO NOT want to replay them again, since they will end up in the transaction state
+               //twice
+               //In other words we only want to replay acks and sends if this tx was loaded at startup
+               if (tx.isLoadedAtStartup())
+               {
+                  handleReferences(tx);
+                  handleAcks(tx);
+                  
+                  tx.setLoadedAtStartup(false);
+               }
             }
             catch (Exception e)
             {
                log.warn("Failed to replay transaction (XID: " + tx.getXid() + ", LocalID: " + tx.getId() + ") during recovery.", e);
             }
 
-				prepared.add(tx.getXid());
-			}
-		}
+            prepared.add(tx.getXid());
+         }
+      }
 
-		return prepared;
-	}
+      return prepared;
+   }
 
 	/*
 	 * Load any prepared transactions into the repository so they can be
 	 * recovered
 	 */
-	public void loadPreparedTransactions() throws Exception
+   public void loadPreparedTransactions() throws Exception
    {
       if (trace) log.trace("load prepared transactions...");
 
-		List prepared = null;
+      List prepared = null;
 
-		prepared = persistenceManager.retrievePreparedTransactions();
+      prepared = persistenceManager.retrievePreparedTransactions();
 
       if (trace) log.trace ("Found " + prepared.size() + " transactions in prepared state:");
 
-		if (prepared != null) {
-			Iterator iter = prepared.iterator();
+      if (prepared != null)
+      {
+         Iterator iter = prepared.iterator();
 
-			while (iter.hasNext()) {
-				PreparedTxInfo txInfo = (PreparedTxInfo) iter.next();
+         while (iter.hasNext())
+         {
+            PreparedTxInfo txInfo = (PreparedTxInfo) iter.next();
 
             if (trace) log.trace("Reinstating TX(XID: " + txInfo.getXid() + ", LocalId " + txInfo.getTxId() +")");
             
-				Transaction tx = createTransaction(txInfo);
-				tx.state = Transaction.STATE_PREPARED;
-			}
-		}
-	}
+            Transaction tx = createTransaction(txInfo);
+            
+            tx.state = Transaction.STATE_PREPARED;
+            
+            tx.setLoadedAtStartup(true);
+            
+         }
+      }
+   }
 
 
    public Transaction getPreparedTx(Xid xid) throws Exception
@@ -231,67 +257,152 @@
    
    // Private -------------------------------------------------------
 
-	/**
-	 * Load the references and invoke the channel to handle those refs
-	 */
-	private void handleReferences(Transaction tx) throws Exception {
-
+   private Receiver getQueue(long channelID) throws Exception
+   {
+      JBossDestination dest = channelMapper.getJBossDestination(channelID);
+      
+      Receiver ch = null;
+      
+      if (dest == null)
+      {
+         CoreSubscription sub = channelMapper.getDurableSubscription(channelID);
+         
+         if (sub == null)
+         {
+            throw new IllegalStateException("Cannot find queue for channel id: " + channelID);
+         }               
+         
+         ch = sub;
+      }
+      else
+      {
+         CoreDestination cd = channelMapper.getCoreDestination(dest);
+         
+         if (cd == null)
+         {
+            throw new IllegalStateException("Cannot find core destination for dest: " + dest);
+         }
+         
+         ch = cd;
+      }     
+      
+      return ch;
+   }
+   
+   /**
+    * Load the references and invoke the channel to handle those refs
+    */
+   private void handleReferences(Transaction tx) throws Exception
+   {
       if (trace) log.trace("Handle references for TX(XID: " + tx.getXid() + ", LocalID: " + tx.getId()+ "):");
 
       long txId = tx.getId();
 
-		Map messageChannelPair = persistenceManager.getMessageChannelPairForTx(txId);
+      List pairs = persistenceManager.getMessageChannelPairRefsForTx(txId);
 
-      if (trace) log.trace("Found " + messageChannelPair.size() + " unhandled messages.");
+      if (trace) log.trace("Found " + pairs.size() + " unhandled references.");
 
-      for (Iterator iter = messageChannelPair.keySet().iterator(); iter.hasNext();)
+      for (Iterator iter = pairs.iterator(); iter.hasNext();)
       {
-         Message msg = (Message)iter.next();
-         MessageReference ref = messageStore.reference(msg);
+         PersistenceManager.MessageChannelPair pair = (PersistenceManager.MessageChannelPair)iter.next();
+         
+         Message msg = pair.getMessage();
+         
+         long channelID = pair.getChannelId();
+         
+         MessageReference ref = null;
+         
+         try
+         {
+            ref = messageStore.reference(msg);    
+            
+            Receiver ch = getQueue(channelID);
+       
+            if (trace) log.trace("Destination for message[ID=" + ref.getMessageID() + "] is: " + ch);
+   
+            ch.handle(null, ref, tx);
+         }
+         finally
+         {
+            if (ref != null)
+            {
+               //Need to release reference
+               ref.releaseMemoryReference();
+            }
+         }
+      }
+   }
 
-         long channelID = ((Long)messageChannelPair.get(msg)).longValue();
-
-         ChannelMapper mapper = persistenceManager.getChannels();
-         JBossDestination destn = mapper.getJBossDestination(channelID);
-
-         CoreDestination d = mapper.getCoreDestination(destn);
-
-         if (trace) log.trace("Destination for message[ID=" + ref.getMessageID() + "] is: " + d);
-
-         d.handle(null, ref, tx);
-		}
-	}
-
-	/**
-	 * Load the acks and acknowledge them
-	 */
-	private void handleAcks(Transaction tx) throws Exception {
-
+   /**
+    * Load the acks and acknowledge them
+    */
+   private void handleAcks(Transaction tx) throws Exception
+   {
       long txId = tx.getId();
+      
+      List pairs = persistenceManager.getMessageChannelPairAcksForTx(txId);
 
-		List messages = persistenceManager.getAcksForTx(txId);
+      if (trace) log.trace("Found " + pairs.size() + " unhandled acks.");
+      
+      List dels = new ArrayList();
 
-      if (trace) log.trace("Found " + messages.size() + " unhandled acks.");
-
-      for (Iterator iter = messages.iterator(); iter.hasNext();)
+      for (Iterator iter = pairs.iterator(); iter.hasNext();)
       {
-         Message msg = (Message)iter.next();
-         MessageReference ref = messageStore.reference(msg);
+         PersistenceManager.MessageChannelPair pair = (PersistenceManager.MessageChannelPair)iter.next();
+         
+         Message msg = pair.getMessage();
+         
+         long channelID = pair.getChannelId();
+         
+         MessageReference ref = null;
+         
+         try
+         {
+            ref = messageStore.reference(msg);         
 
-			Delivery del = new SimpleDelivery(null, ref);
+            Receiver ch = getQueue(channelID);
+               
+            if (trace) log.trace("Destination for message[ID=" + ref.getMessageID() + "] is: " + ch);
+   
+            //Create a new delivery - note that it must have a delivery observer otherwise acknowledge will fail
+            SingleReceiverDelivery del = new SimpleDelivery((DeliveryObserver)ch, ref);
 
-			try
-         {
-				if(trace) log.trace("Acknowledging..");
+            if (trace) log.trace("Acknowledging..");
 
-				((DeliveryObserver)del).acknowledge(del, tx);
-			}
-         catch (Throwable e)
+            try
+            {
+               //At this point there won't be a delivery in the channel for this ref - since
+               //we won't have loaded it when the queue was loaded (since the stat column would have been '-')
+               //so we add it
+               
+               ((Channel)ch).addDelivery(del);
+               
+               del.acknowledge(tx);
+            }
+            catch (Throwable t)
+            {
+               log.error("Failed to acknowledge " + del + " during recovery", t);
+            }
+            
+            dels.add(del);            
+         }
+         finally
          {
-				log.debug("Acknowledgement failed.", e);
-			}
-		}
-	}
+            if (ref != null)
+            {
+               //Need to release reference
+               ref.releaseMemoryReference();
+            }
+         }
+      }
+      
+      if (!dels.isEmpty())
+      {
+         //Add a callback so these dels get cancelled on rollback
+         tx.addCallback(new CancelCallback(dels));
+      }
+      
+   }
 
 
 	/**
@@ -323,4 +434,58 @@
 
    // Inner classes -------------------------------------------------
    
+   private class CancelCallback implements TxCallback
+   {
+      private List toCancel;
+      
+      private CancelCallback(List toCancel)
+      {
+         this.toCancel = toCancel;
+      }
+
+      public void afterCommit(boolean onePhase) throws Exception
+      {
+      }
+
+      public void afterPrepare() throws Exception
+      {
+      }
+
+      public void afterRollback(boolean onePhase) throws Exception
+      {
+         //On rollback we need to cancel the ref back into the channel
+         //We only need to do this if the tx was reloaded 
+         
+         //Need to cancel in reverse
+         
+         for (int i = toCancel.size() - 1; i >= 0; i--)
+         {                     
+            SingleReceiverDelivery del = (SingleReceiverDelivery)toCancel.get(i);
+            
+            try
+            {
+               del.cancel();
+            }
+            catch (Throwable t)
+            {
+               log.error("Failed to cancel delivery", t);
+               throw new TransactionException(t.getMessage(), t);
+            }
+         }
+      }
+
+      public void beforeCommit(boolean onePhase) throws Exception
+      {
+      }
+
+      public void beforePrepare() throws Exception
+      {
+      }
+
+      public void beforeRollback(boolean onePhase) throws Exception
+      {
+      }
+      
+   }
+   
 }
\ No newline at end of file

Modified: branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java
===================================================================
--- branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/src/main/org/jboss/messaging/core/tx/XidImpl.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -61,6 +61,11 @@
       return globalTransactionId;
    }
    
+   //For serialization
+   public XidImpl()
+   {      
+   }
+   
    public XidImpl(byte[] branchQualifier, int formatId, byte[] globalTransactionId)
    {
       this.branchQualifier = branchQualifier;

Modified: branches/Branch_1_0/tests/build.xml
===================================================================
--- branches/Branch_1_0/tests/build.xml	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/tests/build.xml	2006-12-22 00:34:08 UTC (rev 1845)
@@ -134,7 +134,7 @@
        JDBC Drivers.
    -->
    <path id="any.jdbc.driver.classpath">
-	       <fileset dir="${tests.root}/lib/jdbc-drivers" includes="*.jar"/>
+          <fileset dir="${tests.root}/lib/jdbc-drivers" includes="*.jar"/>
    </path>
 
 
@@ -357,6 +357,7 @@
       </junit>
    </target>
 
+
    <target name="memory-leak-tests" depends="tests-jar, prepare-testdirs, clear-test-logs"
            description="Runs memory-leak tests using JBossProfiler in-VM configuration">
 
@@ -623,7 +624,7 @@
       <antcall target="crash-test">
          <param name="crash.test.name" value="org.jboss.test.messaging.jms.crash.ClientCrashTwoConnectionsTest"/>
       </antcall>
-   	
+
       <antcall target="start-rmi-server"/>
 
       <antcall target="crash-test">

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/MessagingTestCase.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -21,6 +21,9 @@
 */
 package org.jboss.test.messaging;
 
+import java.sql.PreparedStatement;
+import java.sql.ResultSet;
+
 import javax.jms.Connection;
 import javax.jms.ConnectionFactory;
 import javax.jms.Destination;
@@ -28,9 +31,13 @@
 import javax.jms.MessageConsumer;
 import javax.jms.Session;
 import javax.jms.Topic;
+import javax.naming.InitialContext;
+import javax.sql.DataSource;
+import javax.transaction.TransactionManager;
 
 import org.jboss.logging.Logger;
 import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.tm.TransactionManagerService;
 
 import junit.framework.TestCase;
 
@@ -160,7 +167,73 @@
    {
       return ServerManagement.isRemote();
    }
+   
+   protected boolean checkNoMessageData() throws Exception
+   {
+      //Can't do this remotely
+      
+      if (ServerManagement.isRemote())
+      {
+         return false;
+      }
+      
+      InitialContext ctx = new InitialContext();
 
+      TransactionManager mgr = (TransactionManager)ctx.lookup(TransactionManagerService.JNDI_NAME);
+      DataSource ds = (DataSource)ctx.lookup("java:/DefaultDS");
+      
+      javax.transaction.Transaction txOld = mgr.suspend();
+      mgr.begin();
+      
+      java.sql.Connection conn = null;
+      
+      PreparedStatement ps = null;
+      
+      ResultSet rs = null;
+
+      try
+      {
+         conn = ds.getConnection();
+         String sql = "SELECT * FROM JMS_MESSAGE_REFERENCE";
+         ps = conn.prepareStatement(sql);
+         
+         rs = ps.executeQuery();
+         
+         boolean exists = rs.next();
+         
+         if (!exists)
+         {
+            rs.close();
+            
+            ps.close();
+            
+            ps = conn.prepareStatement("SELECT * FROM JMS_MESSAGE");
+            
+            rs = ps.executeQuery();
+           
+            exists = rs.next();
+         }
+         
+         return exists;
+      }
+      finally
+      {
+         if (rs != null) rs.close();
+         
+         if (ps != null) ps.close();
+         
+         if (conn != null) conn.close();
+         
+         mgr.commit();
+
+         if (txOld != null)
+         {
+            mgr.resume(txOld);
+         }
+                  
+      } 
+   }
+
    // Private -------------------------------------------------------
    
    // Inner classes -------------------------------------------------   

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -191,6 +191,11 @@
       throw new NotYetImplementedException();
    }
 
+   public void addDelivery(Delivery del)
+   {
+      throw new NotYetImplementedException();
+   }
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XARecoveryTest.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -23,13 +23,14 @@
 
 import javax.jms.Connection;
 import javax.jms.Destination;
+import javax.jms.Message;
 import javax.jms.MessageConsumer;
 import javax.jms.MessageProducer;
 import javax.jms.Session;
 import javax.jms.TextMessage;
+import javax.jms.Topic;
 import javax.jms.XAConnection;
 import javax.jms.XASession;
-import javax.jms.Message;
 import javax.naming.InitialContext;
 import javax.transaction.TransactionManager;
 import javax.transaction.xa.XAResource;
@@ -41,12 +42,19 @@
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.tm.TransactionManagerLocator;
 
+import com.arjuna.ats.arjuna.common.Uid;
 import com.arjuna.ats.jta.xa.XidImple;
-import com.arjuna.ats.arjuna.common.Uid;
 
 /**
+ * 
+ * A XARecoveryTest
+ *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
  */
 public class XARecoveryTest extends MessagingTestCase
 {
@@ -59,7 +67,7 @@
    protected InitialContext initialContext;
    
    protected JBossConnectionFactory cf;
-   protected Destination queue, queueA, queueB, queueTX;
+   protected Destination queue, queueA, queueB, queueTX, topicTX;
 
    TransactionManager tm;
 
@@ -75,9 +83,8 @@
    public void setUp() throws Exception
    {
       super.setUp();
-      ServerManagement.start("all");
+      ServerManagement.start("all");      
       
-      
       initialContext = new InitialContext(ServerManagement.getJNDIEnvironment());
       cf = (JBossConnectionFactory)initialContext.lookup("/ConnectionFactory");
       
@@ -95,11 +102,16 @@
 
       ServerManagement.undeployQueue("TXQ");
       ServerManagement.deployQueue("TXQ");
+      
+      ServerManagement.undeployTopic("TXTOPIC");
+      ServerManagement.deployTopic("TXTOPIC");
 
       queue = (Destination)initialContext.lookup("/queue/Queue");
       queueA = (Destination)initialContext.lookup("/queue/QA");
       queueB = (Destination)initialContext.lookup("/queue/QB");
       queueTX = (Destination)initialContext.lookup("/queue/TXQ");
+      
+      topicTX = (Destination)initialContext.lookup("/topic/TXTOPIC");
 
       drainDestination(cf, queue);
       drainDestination(cf, queueA);
@@ -113,561 +125,3209 @@
       ServerManagement.undeployQueue("QA");
       ServerManagement.undeployQueue("QB");
       ServerManagement.undeployQueue("TXQ");
+      
+      ServerManagement.undeployTopic("TXTOPIC");
 
-
       super.tearDown();
    }
 
 
    // Public --------------------------------------------------------
+   
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it without restarting the server
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithoutRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn1.close();
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         log.trace("Preparing xid " + xid1);
+         res.prepare(xid1);
+         log.trace("Prepared xid " + xid1);
+            
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-/*
-   public void testJBossTSCoordinator() throws Exception
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+         
+         conn1.close();
+         
+         conn2.close();
+         
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm9.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm10.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm11.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm12.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm13.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm14.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm15.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm16.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            conn1.close();
+         }
+         
+         if (conn2 != null)
+         {
+            conn2.close();
+         }
+         
+         if (conn3 != null)
+         {
+            conn3.close();
+         }               
+      }
+   }
+   
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it without restarting the server, then rollback
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithoutRestartRollback() throws Exception
    {
-      UserTransaction ut = com.arjuna.ats.jta.UserTransaction.userTransaction();
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+                  
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      ut.begin();
-
-
-      ut.commit();
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("rolling back the tx");
+         
+         //rollback
+         res3.rollback(xids[0]);
+         
+         log.trace("rolledb back the tx");
+         
+         Thread.sleep(1000);
+         
+         conn1.close();
+         
+         conn2.close();
+         
+         
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm1.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm2.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm3.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm4.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm5.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm6.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm7.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm8.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
    }
-*/
-
-
-   public void testTransactionalDeliveryRecovery() throws Exception
+   
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it after restarting the server
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithRestart() throws Exception
    {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
 
-      XAConnection conn1 = cf.createXAConnection();
+         ServerManagement.stopServerPeer();
 
-      XAConnection conn2 = cf.createXAConnection();
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("QA");
+         
+         ServerManagement.deployQueue("QB");
+                           
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      XASession sess1 = conn1.createXASession();
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
 
-      XASession sess2 = conn2.createXASession();
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm9.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm10.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm11.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm12.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm13.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm14.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm15.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm16.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+            
+   
+   /*
+    * In this test, we have two queues, each with four messages already in them.
+    * 
+    * We send 4 more messages to each queue, and ack the original 4 in a tx
+    * 
+    * Then recover it after restarting the server, then rollback
+    * 
+    */
+   public void testComplexTransactionalRecoveryWithRestartRollback() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
 
-      XAResource res1 = sess1.getXAResource();
+         ServerManagement.stopServerPeer();
 
-      XAResource res2 = sess2.getXAResource();
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("QA");
+         
+         ServerManagement.deployQueue("QB");
+                           
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
-      Xid xid2 = new XidImpl("bq2".getBytes(), 42, "frigtard".getBytes());
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("rolling back the tx");
+         
+         //rollback
+         res3.rollback(xids[0]);
+         
+         log.trace("rolled back the tx");
+         
+         Thread.sleep(1000);
 
-      //    Send a message in each tx
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         log.trace("creating a consumer");
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         log.trace("created a consumer");
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm1.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm2.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm3.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm4.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm5.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm6.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm7.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm8.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         cons1.close();
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+   /* Not really necessary - but it does no harm */
+   public void testComplexTransactional() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         
+         MessageProducer prod2 = sess1.createProducer(queueB);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         TextMessage tm5 = sess1.createTextMessage("tm5");
+         TextMessage tm6 = sess1.createTextMessage("tm6");
+         TextMessage tm7 = sess1.createTextMessage("tm7");
+         TextMessage tm8 = sess1.createTextMessage("tm8");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageProducer prod3 = sess2.createProducer(queueA);
+         
+         TextMessage tm9 = sess2.createTextMessage("tm9");
+         TextMessage tm10 = sess2.createTextMessage("tm10");
+         TextMessage tm11 = sess2.createTextMessage("tm11");
+         TextMessage tm12 = sess2.createTextMessage("tm12");
+         
+         prod3.send(tm9);
+         prod3.send(tm10);
+         prod3.send(tm11);
+         prod3.send(tm12);
+         
+         MessageProducer prod4 = sess2.createProducer(queueB);
+         
+         TextMessage tm13 = sess2.createTextMessage("tm13");
+         TextMessage tm14 = sess2.createTextMessage("tm14");
+         TextMessage tm15 = sess2.createTextMessage("tm15");
+         TextMessage tm16 = sess2.createTextMessage("tm16");
+         
+         prod4.send(tm13);
+         prod4.send(tm14);
+         prod4.send(tm15);
+         prod4.send(tm16);
+         
+         MessageConsumer cons1 = sess2.createConsumer(queueA);
+         
+         TextMessage rm1 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         MessageConsumer cons2 = sess2.createConsumer(queueB);
+         
+         TextMessage rm5 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         res.commit(xid1, false);
+         
+         conn1.close();
+         
+         conn2.close();
+                  
+         
+         
+         conn1 = cf.createConnection();
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons1 = sess1.createConsumer(queueA);
+         
+         TextMessage rm9 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm9);
+         assertEquals(tm9.getText(), rm9.getText());
+         
+         TextMessage rm10 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm10);
+         assertEquals(tm10.getText(), rm10.getText());
+         
+         TextMessage rm11 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm11);
+         assertEquals(tm11.getText(), rm11.getText());
+         
+         TextMessage rm12 = (TextMessage)cons1.receive(1000);
+         assertNotNull(rm12);
+         assertEquals(tm12.getText(), rm12.getText());
+         
+         m = cons1.receive(1000);
+         
+         assertNull(m);
+                  
+         cons2 = sess1.createConsumer(queueB);
+         
+         TextMessage rm13 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm13);
+         assertEquals(tm13.getText(), rm13.getText());
+         
+         TextMessage rm14 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm14);
+         assertEquals(tm14.getText(), rm14.getText());
+         
+         TextMessage rm15 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm15);
+         assertEquals(tm15.getText(), rm15.getText());
+         
+         TextMessage rm16 = (TextMessage)cons2.receive(1000);
+         assertNotNull(rm16);
+         assertEquals(tm16.getText(), rm16.getText());
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+         
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+   
+   /* A simple send in a transaction - recovered without restarting the server */
+   public void testSimpleTransactionalSendRecoveryWithoutRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalDeliveryRecoveryWithoutRestart");
+      
+      XAConnection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createXAConnection();
+   
+         XASession sess1 = conn1.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+   
+         log.trace("Sending message");
+         
+         //Send message in tx
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueTX);
+   
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+   
+         prod1.send(tm1);
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         log.trace("Sent message");
+   
+         //prepare tx
+   
+         res1.prepare(xid1);
+   
+         log.trace("prepared tx");
+         
+         conn2 = cf.createConnection();
+         
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons2 = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Verify message can't be received
+         
+         Message m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      res1.start(xid1, XAResource.TMNOFLAGS);
+         assertEquals(xid1, xids[0]);
+                  
+         // Verify message still can't be received
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         //Commit the tx
+         
+         res1.commit(xids[0], false);
+         
+         //The message should now be available
+         
+         TextMessage rm1 = (TextMessage)cons2.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }       
+   }
+   
+   /* A simple send in a transaction - recovered after restarting the server */
+   public void testSimpleTransactionalSendRecoveryWithRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalDeliveryRecoveryWithRestart");
+      
+      XAConnection conn1 = null;
+      
+      Connection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createXAConnection();
+   
+         XASession sess1 = conn1.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+   
+         log.trace("Sending message");
+         
+         //Send message in tx
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueTX);
+   
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+   
+         prod1.send(tm1);
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         log.trace("Sent message");
+   
+         //prepare tx
+   
+         res1.prepare(xid1);
+   
+         log.trace("prepared tx");
+         
+         conn2 = cf.createConnection();
+         
+         Session sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons2 = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Verify message can't be received
+         
+         Message m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
 
-      MessageProducer prod1 = sess1.createProducer(queueTX);
+         ServerManagement.stopServerPeer();
 
-      TextMessage tm1 = sess1.createTextMessage("tm1");
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("TXQ");
+         
+         log.trace("Restarted");
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         log.trace("created connection");
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      prod1.send(tm1);
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("recovered");
+         
+         conn2 = cf.createConnection();
+         
+         sess2 = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         cons2 = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+                  
+         // Verify message still can't be received
+         
+         m = cons2.receive(1000);
+         
+         assertNull(m);
+         
+         log.trace("still can't see message");
+         
+         //Commit the tx
+         
+         res3.commit(xids[0], false);
+         
+         log.trace("committed");
+         
+         //The message should now be available
+         
+         TextMessage rm1 = (TextMessage)cons2.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }        
+   }
+   
+   
+   
+   
+   /* A simple acknowledgement in a transaction, recovered without restart */
+   public void testSimpleTransactionalAcknowledgementRecoveryWithoutRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalAcknowledgementRecovery");
+      
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         //First send a message to the queue
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess1.createProducer(queueTX);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         
+         prod.send(tm1);
+                           
+         
+         conn2 = cf.createXAConnection();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageConsumer cons = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Consume the message
+         
+         TextMessage rm1 = (TextMessage)cons.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare the tx
+         
+         res1.prepare(xid1);
+         
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      TextMessage tm2 = sess1.createTextMessage("tm2");
+         assertEquals(xid1, xids[0]);
+                  
+         //Commit the tx
+         
+         res1.commit(xids[0], false);
+         
+         //The message should be acknowldged
+         
+         conn1.close();
+         
+         conn2.close();
+         
+         conn3.close();
+         
+         conn1 = cf.createConnection();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons1 = sess1.createConsumer(queueTX);
+         
+         conn1.start();
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }            
+   }
+   
+   
+   
+   /* A simple acknowledgement in a transaction, recovered with restart */
+   public void testSimpleTransactionalAcknowledgementRecoveryWithRestart() throws Exception
+   {
+      log.trace("starting testSimpleTransactionalAcknowledgementRecoveryWithRestart");
+      
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         //First send a message to the queue
+         conn1 = cf.createConnection();
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod = sess1.createProducer(queueTX);
+         
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         
+         prod.send(tm1);
+                                    
+         conn2 = cf.createXAConnection();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+         
+         MessageConsumer cons = sess2.createConsumer(queueTX);
+         
+         conn2.start();
+         
+         //Consume the message
+         
+         TextMessage rm1 = (TextMessage)cons.receive(1000);
+         
+         assertNotNull(rm1);
+         
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         res1.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare the tx
+         
+         res1.prepare(xid1);
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
 
-      prod1.send(tm2);
+         ServerManagement.stopServerPeer();
 
-      res1.end(xid1, XAResource.TMSUCCESS);
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployQueue("TXQ");
+         
+         
+         //Now recover
+         
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
+         assertEquals(xid1, xids[0]);
+                  
+         //Commit the tx
+         
+         res3.commit(xids[0], false);
+         
+         //The message should be acknowldged
+         
+         conn3.close();
+         
+         conn1 = cf.createConnection();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageConsumer cons1 = sess1.createConsumer(queueTX);
+         
+         conn1.start();
+         
+         Message m = cons1.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }                  
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }           
+   }
+   
+           
+   /*
+    * In this test, we have 4 messages in a 2 durable subs on the same topic.
+    * 
+    * We ack them, then add four more messages
+    * 
+    * This test tests for the recovery when the same message is in multiple channels
+    * 
+    * We don't restart in this test
+    * 
+    */
+   public void testRecoveryWithTwoDurableSubsWithoutRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(topicTX);
+         
+         MessageConsumer sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         MessageConsumer sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         //send four messages
+          
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         conn1.close();
+         
+         //The messages should now be in both durable subs
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.setClientID("wib1");
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         //Now send four more messages in a global tx
+         
+         MessageProducer prod2 = sess2.createProducer(topicTX);
+         
+         TextMessage tm5 = sess2.createTextMessage("tm5");
+         TextMessage tm6 = sess2.createTextMessage("tm6");
+         TextMessage tm7 = sess2.createTextMessage("tm7");
+         TextMessage tm8 = sess2.createTextMessage("tm8");
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
 
-      res2.start(xid2, XAResource.TMNOFLAGS);
+         //And consume the first four from each in the tx
+         
+         sub1 = sess2.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess2.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm1 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm1 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         rm2 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         rm3 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         rm4 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+                  
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         //recover
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      MessageProducer prod2 = sess2.createProducer(queueTX);
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+         
+         conn2.close();
+         
+         
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         //Should now see the last 4 messages
+         
+         sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm5 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm5 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         rm6 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         rm7 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         rm8 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+   
+   
+   
+   /*
+    * In this test, we have 4 messages in a 2 durable subs on the same topic.
+    * 
+    * We ack them, then add four more messages
+    * 
+    * This test tests for the recovery when the same message is in multiple channels
+    * 
+    * We do restart in this test
+    * 
+    */
+   public void testRecoveryWithTwoDurableSubsWithRestart() throws Exception
+   {
+      Connection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      XAConnection conn3 = null;
+      
+      try
+      {
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         Session sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         MessageProducer prod1 = sess1.createProducer(topicTX);
+         
+         MessageConsumer sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         MessageConsumer sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         //send four messages
+          
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+         TextMessage tm3 = sess1.createTextMessage("tm3");
+         TextMessage tm4 = sess1.createTextMessage("tm4");
+         
+         prod1.send(tm1);
+         prod1.send(tm2);
+         prod1.send(tm3);         
+         prod1.send(tm4);
+         
+         conn1.close();
+         
+         //The messages should now be in both durable subs
+         
+         conn2 = cf.createXAConnection();
+         
+         conn2.setClientID("wib1");
+         
+         conn2.start();
+         
+         XASession sess2 = conn2.createXASession();
+         
+         XAResource res = sess2.getXAResource();
+         
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         
+         res.start(xid1, XAResource.TMNOFLAGS);
+         
+         //Now send four more messages in a global tx
+         
+         MessageProducer prod2 = sess2.createProducer(topicTX);
+         
+         TextMessage tm5 = sess2.createTextMessage("tm5");
+         TextMessage tm6 = sess2.createTextMessage("tm6");
+         TextMessage tm7 = sess2.createTextMessage("tm7");
+         TextMessage tm8 = sess2.createTextMessage("tm8");
+         
+         prod2.send(tm5);
+         prod2.send(tm6);
+         prod2.send(tm7);
+         prod2.send(tm8);
 
-      TextMessage tm3 = sess2.createTextMessage("tm3");
+         //And consume the first four from each in the tx
+         
+         sub1 = sess2.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess2.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm1 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         TextMessage rm2 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         TextMessage rm3 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         TextMessage rm4 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         Message m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm1 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm1);
+         assertEquals(tm1.getText(), rm1.getText());
+         
+         rm2 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm2);
+         assertEquals(tm2.getText(), rm2.getText());
+         
+         rm3 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm3);
+         assertEquals(tm3.getText(), rm3.getText());
+         
+         rm4 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm4);
+         assertEquals(tm4.getText(), rm4.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         res.end(xid1, XAResource.TMSUCCESS);
+         
+         //prepare it
+         
+         res.prepare(xid1);
+         
+         
+         conn1 = null;
+         
+         conn2 = null;
+         
+         // Now "crash" the server
 
-      prod2.send(tm3);
+         ServerManagement.stopServerPeer();
 
-      TextMessage tm4 = sess2.createTextMessage("tm4");
+         ServerManagement.startServerPeer();
+         
+         ServerManagement.deployTopic("TXTOPIC");
+         
+                           
+         conn3 = cf.createXAConnection();
+         
+         XASession sess3 = conn3.createXASession();
+         
+         XAResource res3 = sess3.getXAResource();
+         
+         //recover
+         
+         Xid[] xids = res3.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(1, xids.length);
+         
+         Xid[] xids2 = res3.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
 
-      prod2.send(tm4);
+         assertEquals(xid1, xids[0]);
+         
+         log.trace("Committing the tx");
+         
+         //Commit
+         res3.commit(xids[0], false);
+         
+         log.trace("committed the tx");
+                           
+         conn1 = cf.createConnection();
+         
+         conn1.setClientID("wib1");
+         
+         conn1.start();
+         
+         sess1 = conn1.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         
+         //Should now see the last 4 messages
+         
+         sub1 = sess1.createDurableSubscriber((Topic)topicTX, "sub1");
+         
+         sub2 = sess1.createDurableSubscriber((Topic)topicTX, "sub2");
+         
+         TextMessage rm5 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         TextMessage rm6 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         TextMessage rm7 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         TextMessage rm8 = (TextMessage)sub1.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub1.receive(1000);
+         
+         assertNull(m);
+                       
+         rm5 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm5);
+         assertEquals(tm5.getText(), rm5.getText());
+         
+         rm6 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm6);
+         assertEquals(tm6.getText(), rm6.getText());
+         
+         rm7 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm7);
+         assertEquals(tm7.getText(), rm7.getText());
+         
+         rm8 = (TextMessage)sub2.receive(1000);
+         assertNotNull(rm8);
+         assertEquals(tm8.getText(), rm8.getText());
+         
+         m = sub2.receive(1000);
+         
+         assertNull(m);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
+   }
+         
+   
 
-      res2.end(xid2, XAResource.TMSUCCESS);
+   /*
+    * Send two messages in two transactions.
+    * Prepare tx
+    * Crash the server
+    * Restart the server
+    * Make sure the messages can be received
+    * NOTE this test only tests transactional sends, not transactional acknowledgments 
+    * 
+    */
+   public void testTransactionalDeliveryRecovery() throws Exception
+   {
+      log.trace("starting testTransactionalDeliveryRecovery");
+      
+      XAConnection conn1 = null;
 
-      //prepare both txs
-
-
-      res1.prepare(xid1);
-      res2.prepare(xid2);
-
-      //Now "crash" the server
-
-      ServerManagement.stopServerPeer();
-
-      ServerManagement.startServerPeer();
-
-      ServerManagement.deployQueue("TXQ");
-
-
-
-      XAResource res = cf.createXAConnection().createXASession().getXAResource();
-
-      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-      assertEquals(2, xids.length);
-
-      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-      assertEquals(0, xids2.length);
-
-      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-
-      res.commit(xid1, false);
-
-      res.commit(xid2, false);
-
-
-      Connection conn3 = cf.createConnection();
-
-      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageConsumer cons = sessRec.createConsumer(queueTX);
-      conn3.start();
-
-      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m1);
-
-      assertTrue(tm1.getText().equals("tm1") ||
-                 tm1.getText().equals("tm2") ||
-                 tm1.getText().equals("tm3") ||
-                 tm1.getText().equals("tm4"));
-
-
-      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m2);
-
-      assertTrue(tm2.getText().equals("tm1") ||
-                 tm2.getText().equals("tm2") ||
-                 tm2.getText().equals("tm3") ||
-                 tm2.getText().equals("tm4"));
-      assertTrue(!tm1.getText().equals(tm2.getText()));
-
-
-      TextMessage m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m3);
-
-      assertTrue(tm3.getText().equals("tm1") ||
-                 tm3.getText().equals("tm2") ||
-                 tm3.getText().equals("tm3") ||
-                 tm3.getText().equals("tm4"));
-
-      assertTrue(!tm3.getText().equals(tm2.getText()));
-      assertTrue(!tm3.getText().equals(tm1.getText()));
-
-
-      TextMessage m4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m4);
-
-      assertTrue(tm4.getText().equals("tm1") ||
-                 tm4.getText().equals("tm2") ||
-                 tm4.getText().equals("tm3") ||
-                 tm4.getText().equals("tm4"));
-
-      assertTrue(!tm4.getText().equals(tm3.getText()));
-      assertTrue(!tm4.getText().equals(tm2.getText()));
-      assertTrue(!tm4.getText().equals(tm1.getText()));
-
-
-      TextMessage nullMessage = (TextMessage)cons.receive(MIN_TIMEOUT);
-
-      assertTrue(nullMessage == null);
-
-      conn3.close();
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();         
+            
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "eemeli".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 42, "frigtard".getBytes());
+   
+         log.trace("Sending messages");
+         
+         //Send two messages in transaction 1
+         
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueTX);
+   
+         TextMessage tm1 = sess1.createTextMessage("tm1");
+   
+         prod1.send(tm1);
+   
+         TextMessage tm2 = sess1.createTextMessage("tm2");
+   
+         prod1.send(tm2);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+         //Send two messages in transaction 2
+         
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queueTX);
+   
+         TextMessage tm3 = sess2.createTextMessage("tm3");
+   
+         prod2.send(tm3);
+   
+         TextMessage tm4 = sess2.createTextMessage("tm4");
+   
+         prod2.send(tm4);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+         
+         log.trace("Sent messages");
+   
+         //prepare both txs
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+         
+         log.trace("prepared messages");
+   
+         //Now "crash" the server
+         
+         conn1 = null;
+         
+         conn2 = null;
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("TXQ");
+   
+         //Try and recover
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         log.trace("Recovering");
+         
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+         
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         //They may be in a different order
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+         
+         //Make sure can't receive the messages
+         
+         log.trace("Creating conn");
+         
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queueTX);
+         conn3.start();
+         
+         log.trace("Created conn3");
+   
+         TextMessage m1 = (TextMessage)cons.receive(1000);
+         assertNull(m1);
+         
+         log.trace("comitting");
+   
+         //Commit tx1
+         
+         res.commit(xid1, false);
+         
+         log.trace("comitted");
+         
+         
+         //Should now be able to receive tm1 and tm2
+         
+         m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         
+         assertEquals(tm1.getText(), m1.getText());
+         
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+         
+         assertEquals(tm2.getText(), m2.getText());
+         
+         TextMessage m3 = (TextMessage)cons.receive(1000);
+         assertNull(m3);
+         
+         //Now commit tx2
+         
+         res.commit(xid2, false);
+         
+         //Should now be able to receive tm3 and tm4
+         
+         m3 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m3);
+         
+         assertEquals(tm3.getText(), m3.getText());
+         
+         TextMessage m4 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m4);
+         
+         assertEquals(tm4.getText(), m4.getText());
+         
+         TextMessage m5 = (TextMessage)cons.receive(1000);
+         assertNull(m5);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }               
+      }
    }
 
 
-
+   /*
+    * This test sends some messages in a couple of txs, crashes then recovers
+    * NOTE it does not test transactional acknowledgements
+    */
    public void testMockCoordinatorRecovery() throws Exception
    {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
+   
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 42, "aapeli".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 42, "belsebub".getBytes());
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueA);
+   
+         TextMessage tm1 = sess1.createTextMessage("alpha");
+   
+         prod1.send(tm1);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queueA);
+   
+         TextMessage tm2 = sess2.createTextMessage("beta");
+   
+         prod2.send(tm2);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("QA");
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+   
+         res.commit(xid1, false);
+   
+         res.commit(xid2, false);
+   
+   
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queueA);
+         conn3.start();
+   
+         Message msg = cons.receive(MAX_TIMEOUT);
+   
+         TextMessage m1 = (TextMessage)msg;
+         assertNotNull(m1);
+   
+         assertTrue("alpha".equals(m1.getText()) ||
+                    "beta".equals(m1.getText()));
+   
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+   
+         assertTrue("alpha".equals(m2.getText()) ||
+                    "beta".equals(m2.getText()));
+   
+         assertTrue(!tm1.getText().equals(tm2.getText()));
+   
+         Message nullMessage = cons.receive(MIN_TIMEOUT);
+         assertTrue(nullMessage == null);
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
 
-      XAConnection conn1 = cf.createXAConnection();
-
-      XAConnection conn2 = cf.createXAConnection();
-
-      XASession sess1 = conn1.createXASession();
-
-      XASession sess2 = conn2.createXASession();
-
-      XAResource res1 = sess1.getXAResource();
-
-      XAResource res2 = sess2.getXAResource();
-
-      //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImpl("bq1".getBytes(), 42, "aapeli".getBytes());
-      Xid xid2 = new XidImpl("bq2".getBytes(), 42, "belsebub".getBytes());
-
-      //    Send a message in each tx
-
-      res1.start(xid1, XAResource.TMNOFLAGS);
-
-      MessageProducer prod1 = sess1.createProducer(queueA);
-
-      TextMessage tm1 = sess1.createTextMessage("alpha");
-
-      prod1.send(tm1);
-
-      res1.end(xid1, XAResource.TMSUCCESS);
-
-
-      res2.start(xid2, XAResource.TMNOFLAGS);
-
-      MessageProducer prod2 = sess2.createProducer(queueA);
-
-      TextMessage tm2 = sess2.createTextMessage("beta");
-
-      prod2.send(tm2);
-
-      res2.end(xid2, XAResource.TMSUCCESS);
-
-      //prepare both txs
-
-
-      res1.prepare(xid1);
-      res2.prepare(xid2);
-
-      //Now "crash" the server
-
-      ServerManagement.stopServerPeer();
-
-      ServerManagement.startServerPeer();
-
-      ServerManagement.deployQueue("QA");
-
-
-      XAResource res = cf.createXAConnection().createXASession().getXAResource();
-
-      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-      assertEquals(2, xids.length);
-
-      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-      assertEquals(0, xids2.length);
-
-      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-
-      res.commit(xid1, false);
-
-      res.commit(xid2, false);
-
-
-      Connection conn3 = cf.createConnection();
-
-      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageConsumer cons = sessRec.createConsumer(queueA);
-      conn3.start();
-
-      Message msg = cons.receive(MAX_TIMEOUT);
-
-      TextMessage m1 = (TextMessage)msg;
-      assertNotNull(m1);
-
-      assertTrue("alpha".equals(m1.getText()) ||
-                 "beta".equals(m1.getText()));
-
-      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m2);
-
-      assertTrue("alpha".equals(m2.getText()) ||
-                 "beta".equals(m2.getText()));
-
-      assertTrue(!tm1.getText().equals(tm2.getText()));
-
-      Message nullMessage = cons.receive(MIN_TIMEOUT);
-      assertTrue(nullMessage == null);
-
-      conn3.close();
    }
 
+   
+   /*
+    * This test sends some messages in a couple of txs, crashes then recovers
+    * It uses the JBoss TS XId implementation - so we can show compatibility
+    * NOTE it does not test transactional acknowledgements
+    */
    public void testMockCoordinatorRecoveryWithJBossTSXids() throws Exception
    {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
 
-      XAConnection conn1 = cf.createXAConnection();
-
-      XAConnection conn2 = cf.createXAConnection();
-
-      XASession sess1 = conn1.createXASession();
-
-      XASession sess2 = conn2.createXASession();
-
-      XAResource res1 = sess1.getXAResource();
-
-      XAResource res2 = sess2.getXAResource();
-
-      //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImple(new Uid("cadaver"), new Uid("bq1"), 666);
-      Xid xid2 = new XidImple(new Uid("dalidom"), new Uid("bq2"), 661);   // TODO
-
-
-      //    Send a message in each tx
-
-      res1.start(xid1, XAResource.TMNOFLAGS);
-
-      MessageProducer prod1 = sess1.createProducer(queue);
-
-      TextMessage tm1 = sess1.createTextMessage("testing1");
-
-      prod1.send(tm1);
-
-      res1.end(xid1, XAResource.TMSUCCESS);
-
-
-      res2.start(xid2, XAResource.TMNOFLAGS);
-
-      MessageProducer prod2 = sess2.createProducer(queue);
-
-      TextMessage tm2 = sess2.createTextMessage("testing2");
-
-      prod2.send(tm2);
-
-      res2.end(xid2, XAResource.TMSUCCESS);
-
-      //prepare both txs
-
-
-      res1.prepare(xid1);
-      res2.prepare(xid2);
-
-      //Now "crash" the server
-
-      ServerManagement.stopServerPeer();
-
-      ServerManagement.startServerPeer();
-
-      ServerManagement.deployQueue("Queue");
-
-
-      XAResource res = cf.createXAConnection().createXASession().getXAResource();
-
-      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-      assertEquals(2, xids.length);
-
-      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-      assertEquals(0, xids2.length);
-
-      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-
-
-      res.commit(xid1, false);
-
-      res.commit(xid2, false);
-
-
-      Connection conn3 = cf.createConnection();
-
-      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageConsumer cons = sessRec.createConsumer(queue);
-      conn3.start();
-
-      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m1);
-      assertEquals("testing1", m1.getText());
-
-      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m2);
-
-      assertEquals("testing2", m2.getText());
-
-      conn3.close();
-
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImple(new Uid("cadaver"), new Uid("bq1"), 666);
+         Xid xid2 = new XidImple(new Uid("dalidom"), new Uid("bq2"), 661);   // TODO
+   
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queue);
+   
+         TextMessage tm1 = sess1.createTextMessage("testing1");
+   
+         prod1.send(tm1);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queue);
+   
+         TextMessage tm2 = sess2.createTextMessage("testing2");
+   
+         prod2.send(tm2);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("Queue");
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+     
+         res.commit(xid1, false);
+   
+         res.commit(xid2, false);
+      
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queue);
+         conn3.start();
+   
+         TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         assertEquals("testing1", m1.getText());
+   
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+   
+         assertEquals("testing2", m2.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
    }
 
 
    public void testMockCoordinatorRecovery3() throws Exception
    {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
 
-      XAConnection conn1 = cf.createXAConnection();
-
-      XAConnection conn2 = cf.createXAConnection();
-
-      XASession sess1 = conn1.createXASession();
-
-      XASession sess2 = conn2.createXASession();
-
-      XAResource res1 = sess1.getXAResource();
-
-      XAResource res2 = sess2.getXAResource();
-
-      //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
-      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
-
-      //    Send a message in each tx
-
-      res1.start(xid1, XAResource.TMNOFLAGS);
-
-      MessageProducer prod1 = sess1.createProducer(queue);
-
-      TextMessage tm1 = sess1.createTextMessage("testing1");
-
-      prod1.send(tm1);
-
-      res1.end(xid1, XAResource.TMSUCCESS);
-
-
-      res2.start(xid2, XAResource.TMNOFLAGS);
-
-      MessageProducer prod2 = sess2.createProducer(queue);
-
-      TextMessage tm2 = sess2.createTextMessage("testing2");
-
-      prod2.send(tm2);
-
-      res2.end(xid2, XAResource.TMSUCCESS);
-
-      //prepare both txs
-
-
-      res1.prepare(xid1);
-      res2.prepare(xid2);
-
-      //Now "crash" the server
-
-      ServerManagement.stopServerPeer();
-
-      ServerManagement.startServerPeer();
-
-      ServerManagement.deployQueue("Queue");
-
-
-
-      XAResource res = cf.createXAConnection().createXASession().getXAResource();
-
-      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-      assertEquals(2, xids.length);
-
-      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-      assertEquals(0, xids2.length);
-
-      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-
-      res.commit(xids[0], false);
-
-      res.commit(xids[1], false);
-
-
-      Connection conn3 = cf.createConnection();
-
-      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-      MessageConsumer cons = sessRec.createConsumer(queue);
-      conn3.start();
-
-      TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m1);
-      assertEquals("testing1", m1.getText());
-
-      TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
-      assertNotNull(m2);
-
-      assertEquals("testing2", m2.getText());
-
-      conn3.close();
-
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queue);
+   
+         TextMessage tm1 = sess1.createTextMessage("testing1");
+   
+         prod1.send(tm1);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod2 = sess2.createProducer(queue);
+   
+         TextMessage tm2 = sess2.createTextMessage("testing2");
+   
+         prod2.send(tm2);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("Queue");
+   
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+   
+         res.commit(xids[0], false);
+   
+         res.commit(xids[1], false);
+      
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageConsumer cons = sessRec.createConsumer(queue);
+         conn3.start();
+   
+         TextMessage m1 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         assertEquals("testing1", m1.getText());
+   
+         TextMessage m2 = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+   
+         assertEquals("testing2", m2.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
    }
 
 
    public void testMultiChannelRecovery() throws Exception
    {
+      XAConnection conn1 = null;
+      
+      XAConnection conn2 = null;
+      
+      Connection conn3 = null;
+      
+      try
+      {
+      
+         conn1 = cf.createXAConnection();
+   
+         conn2 = cf.createXAConnection();
 
-      XAConnection conn1 = cf.createXAConnection();
+         XASession sess1 = conn1.createXASession();
+   
+         XASession sess2 = conn2.createXASession();
+   
+         XAResource res1 = sess1.getXAResource();
+   
+         XAResource res2 = sess2.getXAResource();
+   
+         //Pretend to be a transaction manager by interacting through the XAResources
+         Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
+         Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
+   
+         //    Send a message in each tx
+   
+         res1.start(xid1, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod1 = sess1.createProducer(queueA);
+         MessageProducer prod2 = sess1.createProducer(queueB);
+   
+         TextMessage tm1 = sess1.createTextMessage("testing1");
+         TextMessage tm2 = sess1.createTextMessage("testing2");
+   
+         prod1.send(tm1);
+         prod2.send(tm2);
+   
+         res1.end(xid1, XAResource.TMSUCCESS);
+   
+   
+         res2.start(xid2, XAResource.TMNOFLAGS);
+   
+         MessageProducer prod3 = sess2.createProducer(queue);
+   
+         TextMessage tm3 = sess2.createTextMessage("testing3");
+   
+         prod3.send(tm3);
+   
+         res2.end(xid2, XAResource.TMSUCCESS);
+   
+         //prepare both txs
+   
+   
+         res1.prepare(xid1);
+         res2.prepare(xid2);
+   
+         //Now "crash" the server
+   
+         ServerManagement.stopServerPeer();
+   
+         ServerManagement.startServerPeer();
+   
+         ServerManagement.deployQueue("Queue");
+         ServerManagement.deployQueue("QA");
+         ServerManagement.deployQueue("QB");
+   
+   
+   
+         XAResource res = cf.createXAConnection().createXASession().getXAResource();
+   
+         Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
+         assertEquals(2, xids.length);
+   
+         Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
+         assertEquals(0, xids2.length);
+   
+         assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
+         assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
+   
+         res.commit(xids[0], false);
+   
+         res.commit(xids[1], false);
+   
+         conn3 = cf.createConnection();
+   
+         Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+         MessageConsumer cons1 = sessRec.createConsumer(queueA);
+         MessageConsumer cons2 = sessRec.createConsumer(queueB);
+         MessageConsumer cons3 = sessRec.createConsumer(queue);
+   
+         conn3.start();
+   
+         TextMessage m1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
+         assertNotNull(m1);
+         assertEquals("testing1", m1.getText());
+   
+         TextMessage m2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
+         assertNotNull(m2);
+         assertEquals("testing2", m2.getText());
+   
+         TextMessage m3 = (TextMessage)cons3.receive(MAX_TIMEOUT);
+         assertNotNull(m3);
+         assertEquals("testing3", m3.getText());
+         
+         if (checkNoMessageData())
+         {
+            fail("Data remains in database");
+         }
+      }
+      finally
+      {
+         if (conn1 != null)
+         {
+            try
+            {
+               conn1.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn2 != null)
+         {
+            try
+            {
+               conn2.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }
+         
+         if (conn3 != null)
+         {
+            try
+            {
+               conn3.close();
+            }
+            catch (Exception e)
+            {
+               //Ignore
+            }
+         }    
+      }
 
-      XAConnection conn2 = cf.createXAConnection();
-
-      XASession sess1 = conn1.createXASession();
-
-      XASession sess2 = conn2.createXASession();
-
-      XAResource res1 = sess1.getXAResource();
-
-      XAResource res2 = sess2.getXAResource();
-
-      //Pretend to be a transaction manager by interacting through the XAResources
-      Xid xid1 = new XidImpl("bq1".getBytes(), 123, "gbtxid1".getBytes());
-      Xid xid2 = new XidImpl("bq2".getBytes(), 124, "gbtxid2".getBytes());
-
-      //    Send a message in each tx
-
-      res1.start(xid1, XAResource.TMNOFLAGS);
-
-      MessageProducer prod1 = sess1.createProducer(queueA);
-      MessageProducer prod2 = sess1.createProducer(queueB);
-
-      TextMessage tm1 = sess1.createTextMessage("testing1");
-      TextMessage tm2 = sess1.createTextMessage("testing2");
-
-      prod1.send(tm1);
-      prod2.send(tm2);
-
-      res1.end(xid1, XAResource.TMSUCCESS);
-
-
-      res2.start(xid2, XAResource.TMNOFLAGS);
-
-      MessageProducer prod3 = sess2.createProducer(queue);
-
-      TextMessage tm3 = sess2.createTextMessage("testing3");
-
-      prod3.send(tm3);
-
-      res2.end(xid2, XAResource.TMSUCCESS);
-
-      //prepare both txs
-
-
-      res1.prepare(xid1);
-      res2.prepare(xid2);
-
-      //Now "crash" the server
-
-      ServerManagement.stopServerPeer();
-
-      ServerManagement.startServerPeer();
-
-      ServerManagement.deployQueue("Queue");
-      ServerManagement.deployQueue("QA");
-      ServerManagement.deployQueue("QB");
-
-
-
-      XAResource res = cf.createXAConnection().createXASession().getXAResource();
-
-      Xid[] xids = res.recover(XAResource.TMSTARTRSCAN);
-      assertEquals(2, xids.length);
-
-      Xid[] xids2 = res.recover(XAResource.TMENDRSCAN);
-      assertEquals(0, xids2.length);
-
-      assertTrue(xids[0].equals(xid1) || xids[1].equals(xid1));
-      assertTrue(xids[0].equals(xid2) || xids[1].equals(xid2));
-
-      res.commit(xids[0], false);
-
-      res.commit(xids[1], false);
-
-
-      Connection conn3 = cf.createConnection();
-
-      Session sessRec = conn3.createSession(false, Session.AUTO_ACKNOWLEDGE);
-
-      MessageConsumer cons1 = sessRec.createConsumer(queueA);
-      MessageConsumer cons2 = sessRec.createConsumer(queueB);
-      MessageConsumer cons3 = sessRec.createConsumer(queue);
-
-      conn3.start();
-
-      TextMessage m1 = (TextMessage)cons1.receive(MAX_TIMEOUT);
-      assertNotNull(m1);
-      assertEquals("testing1", m1.getText());
-
-      TextMessage m2 = (TextMessage)cons2.receive(MAX_TIMEOUT);
-      assertNotNull(m2);
-      assertEquals("testing2", m2.getText());
-
-      TextMessage m3 = (TextMessage)cons3.receive(MAX_TIMEOUT);
-      assertNotNull(m3);
-      assertEquals("testing3", m3.getText());
-
-      conn3.close();
-
    }
 
 }

Modified: branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-21 23:43:16 UTC (rev 1844)
+++ branches/Branch_1_0/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-22 00:34:08 UTC (rev 1845)
@@ -46,10 +46,15 @@
 import org.jboss.tm.TxUtils;
 
 /**
+ * 
+ * A XATest
+ *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
  * @author <a href="mailto:juha at jboss.org">Juha Lindfors</a>
  *
  * $Id$
+ *
  */
 public class XATest extends MessagingTestCase
 {
@@ -132,7 +137,6 @@
 
 
    // Public --------------------------------------------------------
-
    
    public void test2PCSendCommit1PCOptimization() throws Exception
    {
@@ -144,8 +148,7 @@
       Connection conn2 = null;
       
       try
-      {
-      
+      {      
          conn = cf.createXAConnection();
          
          tm.begin();
@@ -1062,8 +1065,6 @@
          TextMessage r3 = (TextMessage)cons.receive(MIN_TIMEOUT);
          assertNull(r3);
 
-
-
       }
       finally
       {
@@ -1226,28 +1227,82 @@
          //rollback
 
          tm.rollback();
+           
+         //Rollback causes cancel which is asynch
+         Thread.sleep(1000);
+         
+         //We cannot assume anything about the order in which the transaction manager rollsback
+         //the sessions - this is implementation dependent
 
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
-         conn2.start();
+         conn2.start();         
+         
+         TextMessage r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(r);
+         
+         boolean session1First = false;
+         
+         if (r.getText().equals("jellyfish1"))
+         {
+            session1First = true;
+         }
+         else if (r.getText().equals("jellyfish3"))
+         {
+            session1First = false;
+         }
+         else
+         {
+            fail("Unexpected message");
+         }
+         
+         if (session1First)
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish3", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            
+         }
+         else
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish1", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+         }
+         
+         r = (TextMessage)cons.receive(MIN_TIMEOUT);
+         
+         assertNull(r);
 
-         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r3);
-         assertEquals("jellyfish1", r3.getText());
-
-         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r3);
-         assertEquals("jellyfish2", r3.getText());
-
-         TextMessage r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r4);
-         assertEquals("jellyfish3", r4.getText());
-
-         r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r4);
-         assertEquals("jellyfish4", r4.getText());
-
-
       }
       finally
       {
@@ -1333,34 +1388,84 @@
          cons2.close();
 
          tm.rollback();
+         
+         // Rollback causes cancel which is asynch
+         Thread.sleep(1000);
+         
+         //We cannot assume anything about the order in which the transaction manager rollsback
+         //the sessions - this is implementation dependent
 
+
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         //NOTE
-         //The order here is actually probably dependent on the transaction manager implementation
-         //In this case, rollback will be called on each session, but whether it is called first on res1
-         //or res2 determines the order the messages are put back in the queue
-         //This test assumes it is called in order res1, res2
+         TextMessage r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         assertNotNull(r);
+         
+         boolean session1First = false;
+         
+         if (r.getText().equals("jellyfish1"))
+         {
+            session1First = true;
+         }
+         else if (r.getText().equals("jellyfish3"))
+         {
+            session1First = false;
+         }
+         else
+         {
+            fail("Unexpected message");
+         }
+         
+         if (session1First)
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish3", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            
+         }
+         else
+         {
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish4", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish1", r.getText());
+            
+            r = (TextMessage)cons.receive(MAX_TIMEOUT);
+            
+            assertNotNull(r);
+            
+            assertEquals("jellyfish2", r.getText());
+         }
+         
+         r = (TextMessage)cons.receive(MIN_TIMEOUT);
+         
+         assertNull(r);
 
-         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r3);
-         assertEquals("jellyfish3", r3.getText());
 
-         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r3);
-         assertEquals("jellyfish4", r3.getText());
-
-         TextMessage r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r4);
-         assertEquals("jellyfish1", r4.getText());
-
-         r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r4);
-         assertEquals("jellyfish2", r4.getText());
-
-
       }
       finally
       {
@@ -1389,6 +1494,7 @@
          conn2 = cf.createConnection();
          Session sessProducer = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageProducer prod  = sessProducer.createProducer(queue);
+         
          Message m = sessProducer.createTextMessage("jellyfish1");
          prod.send(m);
          m = sessProducer.createTextMessage("jellyfish2");
@@ -1398,10 +1504,9 @@
          m = sessProducer.createTextMessage("jellyfish4");
          prod.send(m);
 
-
          conn = cf.createXAConnection();
          conn.start();
-
+         
          tm.begin();
 
          XASession sess1 = conn.createXASession();
@@ -1433,13 +1538,22 @@
 
          assertNotNull(r1);
          assertEquals("jellyfish4", r1.getText());
+         
+         r1 = (TextMessage)cons1.receive(1000);
+         
+         assertNull(r1);
 
          cons1.close();
 
 
-
          //try and commit - and we're going to make the dummyxaresource throw an exception on commit,
          //which should cause rollback to be called on the other resource
+         
+         
+         //rollback will cause an attemp to deliver messages locally to the original consumers.
+         //the original consumer has closed, so it will cancelled to the server
+         //the server cancel is asynch, so we need to sleep for a bit to make sure it completes
+         log.trace("Forcing failure");
          try
          {
             tm.commit();
@@ -1449,28 +1563,41 @@
          {
             //We should expect this
          }
-
+         
+         Thread.sleep(1000);
+         
+         
          Session sess = conn2.createSession(false, Session.AUTO_ACKNOWLEDGE);
          MessageConsumer cons = sess.createConsumer(queue);
          conn2.start();
 
-         TextMessage r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r3);
-         assertEquals("jellyfish1", r3.getText());
-
-         r3 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r3);
-         assertEquals("jellyfish2", r3.getText());
-
-         TextMessage r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r4);
-         assertEquals("jellyfish3", r4.getText());
-
-         r4 = (TextMessage)cons.receive(MAX_TIMEOUT);
-         assertNotNull(r4);
-         assertEquals("jellyfish4", r4.getText());
-
-
+         TextMessage r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish1", r.getText());
+         
+         r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish2", r.getText());
+         
+         r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish3", r.getText());
+         
+         r = (TextMessage)cons.receive(MAX_TIMEOUT);
+         
+         assertNotNull(r);
+         
+         assertEquals("jellyfish4", r.getText());         
+         
+         r = (TextMessage)cons.receive(MIN_TIMEOUT);
+         
+         assertNull(r);
       }
       finally
       {
@@ -1498,7 +1625,6 @@
 
       try
       {
-
          conn = cf.createXAConnection();
          conn.start();
 



From rawblem at gmail.com  Thu Dec 21 20:08:40 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 21 Dec 2006 20:08:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types
	...
Message-ID: <E1GxYts-00032Y-H9@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/21 20:08:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types  
                        JARPackageType.java
  Removed:     core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types  
                        AbstractPackageType.java
  Log:
  The Extension Manager had several errors. It used the incorrect method of instantiating a provided class (Class.forName led to class not found errors. configElement.createExecutable("attribute") is the proper method)
  
  It also assumed all provided classes would be of type AbstractPackageType, instead of IPackageType. It then made use of methods not present in IPackageType (setId, setLabel). I've removed all references to AbstractPackageType, the JARPackageType now directly returns its information (jar, JAR), and the extension point data is essentially ignored.
  
  Suck It. 
  
  Revision  Changes    Path
  1.7       +9 -2      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JARPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- JARPackageType.java	20 Dec 2006 20:43:47 -0000	1.6
  +++ JARPackageType.java	22 Dec 2006 01:08:40 -0000	1.7
  @@ -21,10 +21,9 @@
    * The name of the resulting JAR will be the project's name followed by a ".jar" extension.
    * @author Marshall
    */
  -public class JARPackageType extends AbstractPackageType {
  +public class JARPackageType implements IPackageType {
   
   	public static final String TYPE_ID = "jar";
  -
   	public IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor)
   	{
   		Assert.isNotNull(project);
  @@ -79,4 +78,12 @@
   		
   		return SUPPORT_NONE;
   	}
  +	
  +	public String getId() {
  +		return "jar";
  +	}
  +
  +	public String getLabel() {
  +		return "JAR";
  +	}
   }
  
  
  


From rawblem at gmail.com  Thu Dec 21 20:08:40 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Thu, 21 Dec 2006 20:08:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core
	...
Message-ID: <E1GxYts-00032f-KG@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/21 20:08:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core 
                        ExtensionManager.java
  Log:
  The Extension Manager had several errors. It used the incorrect method of instantiating a provided class (Class.forName led to class not found errors. configElement.createExecutable("attribute") is the proper method)
  
  It also assumed all provided classes would be of type AbstractPackageType, instead of IPackageType. It then made use of methods not present in IPackageType (setId, setLabel). I've removed all references to AbstractPackageType, the JARPackageType now directly returns its information (jar, JAR), and the extension point data is essentially ignored.
  
  Suck It. 
  
  Revision  Changes    Path
  1.3       +9 -7      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExtensionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ExtensionManager.java	21 Nov 2006 16:15:24 -0000	1.2
  +++ ExtensionManager.java	22 Dec 2006 01:08:40 -0000	1.3
  @@ -2,13 +2,13 @@
   
   import java.util.ArrayList;
   
  +import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IConfigurationElement;
   import org.eclipse.core.runtime.IExtension;
   import org.eclipse.core.runtime.IExtensionPoint;
   import org.eclipse.core.runtime.IExtensionRegistry;
   import org.eclipse.core.runtime.InvalidRegistryObjectException;
   import org.eclipse.core.runtime.Platform;
  -import org.jboss.ide.eclipse.packages.core.model.types.AbstractPackageType;
   import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
   
   public class ExtensionManager {
  @@ -32,12 +32,10 @@
   			for (int j = 0; j < elements.length; j++)
   			{
   				try {
  -					Class packageTypeClass = Class.forName(elements[j].getAttribute("class"));
  -					AbstractPackageType packageType = (AbstractPackageType) packageTypeClass.newInstance();
  -					packageType.setId(elements[j].getAttribute("id"));
  -					packageType.setLabel(elements[j].getAttribute("label"));
  -					
  -					packageTypes.add(packageType);
  +					Object executable = elements[j].createExecutableExtension("class");
  +					if( !(executable instanceof IPackageType)) 
  +						throw new Exception("Provided class is not an IPackageType");
  +					packageTypes.add((IPackageType)executable);
   				} catch (InvalidRegistryObjectException e) {
   					Trace.trace(ExtensionManager.class, e);
   				} catch (ClassNotFoundException e) {
  @@ -46,6 +44,10 @@
   					Trace.trace(ExtensionManager.class, e);
   				} catch (IllegalAccessException e) {
   					Trace.trace(ExtensionManager.class, e);
  +				} catch( CoreException e ) {
  +					Trace.trace(ExtensionManager.class, e);
  +				} catch( Exception e ) {
  +					Trace.trace(ExtensionManager.class, e);
   				}
   			}
   		}
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:03:08 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:03:08 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1GxZka-00045M-Vn@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:03:08

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  fixed Identity working memory test
  
  Revision  Changes    Path
  1.31      +1 -6      jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- SeamSecurityManager.java	21 Dec 2006 05:32:54 -0000	1.30
  +++ SeamSecurityManager.java	22 Dec 2006 02:03:08 -0000	1.31
  @@ -5,12 +5,8 @@
   
   import java.io.InputStream;
   import java.io.InputStreamReader;
  -import java.security.acl.Permission;
   import java.util.ArrayList;
  -import java.util.HashMap;
   import java.util.List;
  -import java.util.Map;
  -import java.util.Set;
   
   import org.drools.FactHandle;
   import org.drools.RuleBase;
  @@ -28,7 +24,6 @@
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.annotations.Startup;
  -import org.jboss.seam.contexts.Context;
   import org.jboss.seam.contexts.Contexts;
   import org.jboss.seam.core.Expressions;
   import org.jboss.seam.log.LogProvider;
  @@ -198,7 +193,7 @@
         
         // Assert the identity into the working memory if one exists and it hasn't
         // been asserted before
  -      if (ident != null && wm.getObjects(ident.getClass()).size() > 0)
  +      if (ident != null && wm.getObjects(ident.getClass()).isEmpty())
         {
            wm.assertObject(ident);
   
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:04:48 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:04:48 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF   ...
Message-ID: <E1GxZmC-00046O-M6@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:04:48

  Modified:    examples/seamspace/resources/META-INF   application.xml
  Added:       examples/seamspace/resources/META-INF   security-rules.drl
  Log:
  added security rules
  
  Revision  Changes    Path
  1.6       +35 -27    jboss-seam/examples/seamspace/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/application.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- application.xml	15 Dec 2006 13:36:43 -0000	1.5
  +++ application.xml	22 Dec 2006 02:04:48 -0000	1.6
  @@ -57,4 +57,12 @@
       <java>stringtemplate-2.3b6.jar</java>
   	</module>	
   
  +  <module>
  +    <java>antlr-2.7.6.jar</java>
  +  </module>
  +
  +  <module>
  +    <java>antlr-3.0ea8.jar</java>
  +  </module>
  +  
   </application>
  \ No newline at end of file
  
  
  
  1.1      date: 2006/12/22 02:04:48;  author: sbryzak2;  state: Exp;jboss-seam/examples/seamspace/resources/META-INF/security-rules.drl
  
  Index: security-rules.drl
  ===================================================================
  package SeamSpacePermissions;
  
  import org.jboss.seam.security.Identity;
  import org.jboss.seam.security.rules.PermissionCheck;
  import org.jboss.seam.example.seamspace.MemberImage;
  
  rule AuthenticatedViewImage
  when
    c: PermissionCheck(name == "memberImage", action == "view")
    Identity()
    img: MemberImage()
    eval( img.getMember().getPicture() == img )
  then
    c.grant();
  end;
  
  rule UnauthenticatedViewImage
  when
    c: PermissionCheck(name == "memberImage", action == "view")
    not Identity()
    img: MemberImage()
    eval( img.getMember().getPicture() == img )
  then
    c.grant();
  end;  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:04:48 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:04:48 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF  ...
Message-ID: <E1GxZmC-00046V-PD@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:04:48

  Modified:    examples/seamspace/resources/WEB-INF  pages.xml
  Log:
  added security rules
  
  Revision  Changes    Path
  1.2       +6 -0      jboss-seam/examples/seamspace/resources/WEB-INF/pages.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pages.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/pages.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- pages.xml	20 Dec 2006 03:36:55 -0000	1.1
  +++ pages.xml	22 Dec 2006 02:04:48 -0000	1.2
  @@ -12,4 +12,10 @@
           </navigation>
       </page>
   
  +    <page view-id="*">
  +        <navigation from-action="#{login.logout}">
  +            <redirect view-id="/home.xhtml"/>
  +        </navigation>
  +    </page>
  +
   </pages>
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:04:48 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:04:48 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxZmC-00046l-Uq@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:04:48

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace    
                        ContentAction.java LoginAction.java LoginLocal.java
                        ProfileAction.java
  Log:
  added security rules
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ContentAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ContentAction.java	21 Dec 2006 13:05:01 -0000	1.2
  +++ ContentAction.java	22 Dec 2006 02:04:48 -0000	1.3
  @@ -17,7 +17,7 @@
      {
         MemberImage img = entityManager.find(MemberImage.class, imageId);
   
  -      if (img != null)// && SeamSecurityManager.hasPermission("memberImage", "view", img))      
  +      if (img != null && SeamSecurityManager.hasPermission("memberImage", "view", img))      
            return img;
         else
            return null;
  
  
  
  1.5       +34 -30    jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- LoginAction.java	21 Dec 2006 05:34:47 -0000	1.4
  +++ LoginAction.java	22 Dec 2006 02:04:48 -0000	1.5
  @@ -26,7 +26,9 @@
   @Name("login")
   public class LoginAction implements LoginLocal
   {
  -  @In(required = false) @Out(required = false) Member member;
  +   @In(required = false)
  +   @Out(required = false)
  +   Member member;
     
     private boolean loggedIn;
   
  @@ -34,7 +36,8 @@
     {
       try
       {
  -      Authenticator.instance().authenticate(member.getUsername(), member.getPassword());
  +         Authenticator.instance().authenticate(member.getUsername(),
  +               member.getPassword());
         loggedIn = true;      
       }
       catch (AuthenticationException ex)
  @@ -55,6 +58,7 @@
   	return loggedIn;
     }
     
  -  @Remove @Destroy
  +   @Remove
  +   @Destroy
     public void destroy() { }
   }
  
  
  
  1.3       +1 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginLocal.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LoginLocal.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/LoginLocal.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- LoginLocal.java	20 Dec 2006 03:36:56 -0000	1.2
  +++ LoginLocal.java	22 Dec 2006 02:04:48 -0000	1.3
  @@ -13,4 +13,5 @@
     void login();
     void logout();
     boolean isLoggedIn();
  +  void destroy();
   }
  
  
  
  1.4       +3 -6      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProfileAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ProfileAction.java	21 Dec 2006 13:05:01 -0000	1.3
  +++ ProfileAction.java	22 Dec 2006 02:04:48 -0000	1.4
  @@ -28,14 +28,14 @@
      @Factory("selectedMember")
      public void display()
      {
  -      if (name == null)
  +      if (name == null && Identity.isSet())
         {
            selectedMember = (Member) entityManager.createQuery(
                  "from Member where username = :username")
                  .setParameter("username", Identity.instance().getName())
                  .getSingleResult();
         }
  -      else
  +      else if (name != null)
         {
            try
            {
  @@ -44,10 +44,7 @@
               .setParameter("name", name)
               .getSingleResult();
            }
  -         catch (NoResultException ex) 
  -         {
  -            FacesMessages.instance().add("The member name you specified does not exist.");
  -         }   
  +         catch (NoResultException ex) { }   
         }
      }
   }
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:04:49 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:04:49 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view  ...
Message-ID: <E1GxZmD-00046s-2J@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:04:49

  Modified:    examples/seamspace/view  template.xhtml
  Log:
  added security rules
  
  Revision  Changes    Path
  1.5       +1 -0      jboss-seam/examples/seamspace/view/template.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: template.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/template.xhtml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- template.xhtml	20 Dec 2006 11:40:25 -0000	1.4
  +++ template.xhtml	22 Dec 2006 02:04:49 -0000	1.5
  @@ -16,6 +16,7 @@
       <div class="headerRight">
         <div class="headerMenu">
           <!--s:link action="" value="SignUp"/-->
  +        <s:link action="#{login.logout}" value="Log out" rendered="#{login.loggedIn}"/>
         </div>
         <br style="clear:both"/>
         <h:form>
  
  
  


From t2-okada at nri.co.jp  Thu Dec 21 21:25:49 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Thu, 21 Dec 2006 21:25:49 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/model
	...
Message-ID: <E1Gxa6X-0004Tr-5Q@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/21 21:25:49

  Modified:    java/src/expansion/org/jboss/profiler/exp/agent/collector/model 
                        Tag: JBossProfiler_Expansion ThreadMetric.java
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +3 -0      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/model/Attic/ThreadMetric.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThreadMetric.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/collector/model/Attic/ThreadMetric.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- ThreadMetric.java	21 Dec 2006 11:18:20 -0000	1.1.2.3
  +++ ThreadMetric.java	22 Dec 2006 02:25:49 -0000	1.1.2.4
  @@ -55,6 +55,9 @@
       }
       
       public List<Entry> getEntries() {
  +        // Permutes entries in reverse order of called.
  +        Collections.reverse(entries);
  +        // Permutes entries in order of timestamp.
           Collections.sort(entries, new TimestampComparator());
           return entries;
       }
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:50:24 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:50:24 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxaUK-0004uZ-QA@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:50:24

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace 
                        ContentServlet.java
  Log:
  support image rescaling
  
  Revision  Changes    Path
  1.4       +56 -8     jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ContentServlet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ContentServlet.java	21 Dec 2006 13:05:01 -0000	1.3
  +++ ContentServlet.java	22 Dec 2006 02:50:24 -0000	1.4
  @@ -1,11 +1,16 @@
   package org.jboss.seam.example.seamspace;
   
  +import java.awt.Graphics2D;
  +import java.awt.RenderingHints;
  +import java.awt.image.BufferedImage;
   import java.io.IOException;
   
  +import javax.imageio.ImageIO;
   import javax.servlet.ServletException;
   import javax.servlet.http.HttpServlet;
   import javax.servlet.http.HttpServletRequest;
   import javax.servlet.http.HttpServletResponse;
  +import javax.swing.ImageIcon;
   
   import org.jboss.seam.Component;
   
  @@ -20,6 +25,11 @@
      
      private static final String IMAGES_PATH = "/images";
   
  +   /**
  +    * The maximum width allowed for image rescaling
  +    */
  +   private static final int MAX_IMAGE_WIDTH = 1024;
  +
      @Override
      protected void doGet(HttpServletRequest request, HttpServletResponse response)
          throws ServletException, IOException
  @@ -28,12 +38,50 @@
         {
            ContentLocal contentAction = (ContentLocal) Component.getInstance(ContentAction.class);
            
  -         MemberImage img = contentAction.getImage(Integer.parseInt(request.getParameter("id")));
  +         MemberImage mi = contentAction.getImage(Integer.parseInt(request.getParameter("id")));
  +
  +         if (mi != null)
  +         {
  +            response.setContentType(mi.getContentType());
  +
  +            boolean rescale = false;
  +            int width = 0;
  +            ImageIcon icon = null;
            
  -         if (img != null)
  +            // Check if the image needs to be rescaled
  +            if (request.getParameter("width") != null)
            {
  -            response.setContentType(img.getContentType());
  -            response.getOutputStream().write(img.getData());
  +               width = Math.min(MAX_IMAGE_WIDTH, Integer.parseInt(request
  +                     .getParameter("width")));
  +               icon = new ImageIcon(mi.getData());
  +               if (width > 0 && width != icon.getIconWidth())
  +                  rescale = true;
  +            }
  +
  +            // Rescale the image if required
  +            if (rescale)
  +            {
  +               double ratio = (double) width / icon.getIconWidth();
  +               int height = (int) (icon.getIconHeight() * ratio);
  +               BufferedImage bImg = new BufferedImage(width, height,
  +                     BufferedImage.TYPE_INT_ARGB);
  +               Graphics2D g2d = bImg.createGraphics();
  +               g2d.setRenderingHint(RenderingHints.KEY_INTERPOLATION,
  +                     RenderingHints.VALUE_INTERPOLATION_BICUBIC);
  +               g2d.drawImage(icon.getImage(), 0, 0, width, height, null);
  +               g2d.dispose();
  +               String formatName = "";
  +
  +               if ("image/png".equals(mi.getContentType()))
  +                  formatName = "png";
  +               else if ("image/jpeg".equals(mi.getContentType()))
  +                  formatName = "jpg";
  +
  +               ImageIO.write(bImg, formatName, response.getOutputStream());
  +            }
  +            else
  +               response.getOutputStream().write(mi.getData());
  +
               response.getOutputStream().flush();
            }
         }
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 21:50:24 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 21:50:24 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view  ...
Message-ID: <E1GxaUK-0004ug-T8@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 21:50:24

  Modified:    examples/seamspace/view  profile.xhtml
  Log:
  support image rescaling
  
  Revision  Changes    Path
  1.3       +1 -1      jboss-seam/examples/seamspace/view/profile.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: profile.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/profile.xhtml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- profile.xhtml	21 Dec 2006 13:05:01 -0000	1.2
  +++ profile.xhtml	22 Dec 2006 02:50:24 -0000	1.3
  @@ -11,7 +11,7 @@
   			
   			  <div class="errors"><h:messages globalOnly="true"/></div> 
   			  
  -			  <h:graphicImage value="/content/images?id=#{selectedMember.picture.imageId}"/>
  +			  <h:graphicImage value="/content/images?id=#{selectedMember.picture.imageId}&amp;width=170"/>
   			  
         </div>
       
  
  
  


From msurtani at jboss.com  Thu Dec 21 22:16:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:16:49 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1Gxatt-0005Yg-JU@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:16:49

  Modified:    tests/functional/org/jboss/cache/passivation 
                        LocalPassivationIntegrationTest.java
  Log:
  properly sets file cache loader location
  
  Revision  Changes    Path
  1.12      +15 -1     JBossCache/tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalPassivationIntegrationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- LocalPassivationIntegrationTest.java	20 Dec 2006 13:34:28 -0000	1.11
  +++ LocalPassivationIntegrationTest.java	22 Dec 2006 03:16:49 -0000	1.12
  @@ -13,6 +13,8 @@
   import org.jboss.cache.AbstractCacheListener;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.config.CacheLoaderConfig;
  +import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -57,10 +59,22 @@
   
      void initCaches(TreeCache cache) throws Exception
      {
  -      cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
  +      cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  +      // hack in the path to the file store in the cache loaders
  +      injectCacheLoaderLocation(cache.getConfiguration(), "/tmp/JBossCacheFileCacheLoader");
  +
      }
   
  +   private void injectCacheLoaderLocation(Configuration configuration, String location)
  +   {
  +      for (CacheLoaderConfig.IndividualCacheLoaderConfig iclc : configuration.getCacheLoaderConfig().getIndividualCacheLoaderConfigs())
  +      {
  +         iclc.getProperties().put("location", location);
  +      }
  +   }
  +
  +
      public void tearDown() throws Exception
      {
         super.tearDown();
  
  
  


From msurtani at jboss.com  Thu Dec 21 22:17:15 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:17:15 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/config  ...
Message-ID: <E1GxauJ-0005Yv-QA@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:17:15

  Modified:    src/org/jboss/cache/config  CacheLoaderConfig.java
  Log:
  genericised
  
  Revision  Changes    Path
  1.18      +287 -286  JBossCache/src/org/jboss/cache/config/CacheLoaderConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/CacheLoaderConfig.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- CacheLoaderConfig.java	25 Oct 2006 04:50:20 -0000	1.17
  +++ CacheLoaderConfig.java	22 Dec 2006 03:17:15 -0000	1.18
  @@ -6,14 +6,14 @@
    */
   package org.jboss.cache.config;
   
  +import org.jboss.cache.xml.XmlHelper;
  +
   import java.io.ByteArrayInputStream;
   import java.io.IOException;
   import java.util.ArrayList;
   import java.util.List;
   import java.util.Properties;
   
  -import org.jboss.cache.xml.XmlHelper;
  -
   /**
    * Holds the configuration of the cache loader chain.  ALL cache loaders should be defined using this class, adding
    * individual cache loaders to the chain by calling {@see CacheLoaderConfig#addIndividualCacheLoaderConfig}
  @@ -65,7 +65,7 @@
           addChildConfig(clc);
       }
   
  -    public List getIndividualCacheLoaderConfigs()
  +   public List<IndividualCacheLoaderConfig> getIndividualCacheLoaderConfigs()
       {
           return cacheLoaderConfigs;
       }
  @@ -132,7 +132,6 @@
      }
   
   
  -
      /**
        * Configuration object that holds the confguration of an individual cache loader.
        *
  @@ -153,7 +152,9 @@
   
           private Properties properties;
   
  -        public IndividualCacheLoaderConfig() {}
  +      public IndividualCacheLoaderConfig()
  +      {
  +      }
           
           protected void populateFromBaseConfig(IndividualCacheLoaderConfig base)
           {
  @@ -281,7 +282,7 @@
           public boolean equals(Object obj)
           {
              return equalsExcludingProperties(obj) 
  -                  && safeEquals(this.properties, ((IndividualCacheLoaderConfig)obj).properties);
  +                 && safeEquals(this.properties, ((IndividualCacheLoaderConfig) obj).properties);
           }
           
           protected boolean equalsExcludingProperties(Object obj)
  
  
  


From msurtani at jboss.com  Thu Dec 21 22:23:15 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:23:15 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/config  ...
Message-ID: <E1Gxb07-0005eJ-PO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:23:15

  Modified:    src/org/jboss/cache/config  CacheLoaderConfig.java
  Log:
  genericised
  
  Revision  Changes    Path
  1.19      +1 -1      JBossCache/src/org/jboss/cache/config/CacheLoaderConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/CacheLoaderConfig.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- CacheLoaderConfig.java	22 Dec 2006 03:17:15 -0000	1.18
  +++ CacheLoaderConfig.java	22 Dec 2006 03:23:15 -0000	1.19
  @@ -81,7 +81,7 @@
      public IndividualCacheLoaderConfig getFirstCacheLoaderConfig()
      {
         if (cacheLoaderConfigs.size() == 0) return null;
  -      return (IndividualCacheLoaderConfig) cacheLoaderConfigs.get(0);
  +      return cacheLoaderConfigs.get(0);
      }
   
      public boolean useChainingCacheLoader()
  
  
  


From msurtani at jboss.com  Thu Dec 21 22:28:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:28:52 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1Gxb5Y-0005jv-IW@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:28:52

  Modified:    JBossCache  build.xml
  Log:
  updated known issues
  
  Revision  Changes    Path
  1.156     +5 -5      JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.155
  retrieving revision 1.156
  diff -u -b -r1.155 -r1.156
  --- build.xml	21 Dec 2006 18:17:12 -0000	1.155
  +++ build.xml	22 Dec 2006 03:28:52 -0000	1.156
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.155 2006/12/21 18:17:12 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.156 2006/12/22 03:28:52 msurtani Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -62,16 +62,16 @@
          Only one test per line.  Please add a comment with a reference to a JIRA task about this failure.
      -->
      <patternset id="known.failures">
  -      <!-- See JBCACHE-859 -->
  -      <exclude name="org/jboss/cache/buddyreplication/BuddyAssignmentStateTransferTest*"/>
  +
  +      <!-- See JBCACHE-814 -->
         <exclude name="org/jboss/cache/eviction/ConcurrentEvictionTest*"/>
  -      <exclude name="org/jboss/cache/eviction/MRUAlgorithmTest*"/>
  -      <exclude name="org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest*"/>
  +      <exclude name="org/jboss/cache/passivation/ConcurrentPassivationTest*"/>
   
         <!-- See JBCACHE-858 -->
         <exclude name="org/jboss/cache/pojo/collection/ReplicatedSyncMapTest*"/>
         <exclude name="org/jboss/cache/pojo/collection/ReplicatedSyncSetTest*"/>
         <exclude name="org/jboss/cache/pojo/region/LocalConcurrentTest*"/>
  +      <exclude name="org/jboss/cache/pojo/LocalConcurrentTest*"/>
   
         <!-- See JBCACHE-315 -->
         <exclude name="org/jboss/cache/statetransfer/StateTransferUnderLoadTest*"/>
  
  
  


From msurtani at jboss.com  Thu Dec 21 22:29:29 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:29:29 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1Gxb69-0005k8-66@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:29:29

  Modified:    tests/functional/org/jboss/cache/passivation 
                        ConcurrentPassivationTest.java
  Log:
  patched test to work with broken/incomplete config files
  
  Revision  Changes    Path
  1.7       +15 -1     JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ConcurrentPassivationTest.java	20 Dec 2006 13:34:28 -0000	1.6
  +++ ConcurrentPassivationTest.java	22 Dec 2006 03:29:29 -0000	1.7
  @@ -12,6 +12,8 @@
   import junit.framework.TestSuite;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.TreeCache;
  +import org.jboss.cache.config.CacheLoaderConfig;
  +import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -19,7 +21,7 @@
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class ConcurrentPassivationTest extends TestCase
   {
  @@ -47,9 +49,21 @@
         cache_ = new TreeCache();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  +
  +      // hack in the path to the file store in the cache loaders
  +      injectCacheLoaderLocation(cache_.getConfiguration(), "/tmp/JBossCacheFileCacheLoader");
         cache_.start();
      }
   
  +   private void injectCacheLoaderLocation(Configuration configuration, String location)
  +   {
  +      for (CacheLoaderConfig.IndividualCacheLoaderConfig iclc : configuration.getCacheLoaderConfig().getIndividualCacheLoaderConfigs())
  +      {
  +         iclc.getProperties().put("location", location);
  +      }
  +   }
  +
  +
      public void tearDown() throws Exception
      {
         super.tearDown();
  
  
  


From bwang at jboss.com  Thu Dec 21 22:44:22 2006
From: bwang at jboss.com (Ben Wang)
Date: Thu, 21 Dec 2006 22:44:22 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic
	- New directory ...
Message-ID: <E1GxbKY-0005wf-BC@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/21 22:44:22

  Log:
  Directory /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic added to the repository


From msurtani at jboss.com  Thu Dec 21 22:53:30 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:53:30 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/api   ...
Message-ID: <E1GxbTO-00065j-84@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:53:30

  Modified:    tests/functional/org/jboss/cache/api   NodeMoveAPITest.java
                        NodeAPITest.java
  Log:
  fixed breakages
  
  Revision  Changes    Path
  1.14      +10 -10    JBossCache/tests/functional/org/jboss/cache/api/NodeMoveAPITest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeMoveAPITest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeMoveAPITest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- NodeMoveAPITest.java	29 Nov 2006 04:16:13 -0000	1.13
  +++ NodeMoveAPITest.java	22 Dec 2006 03:53:30 -0000	1.14
  @@ -43,7 +43,7 @@
         cache.start();
         rootNode = cache.getRoot();
         tm = cache.getTransactionManager();
  -      treeCache = ((TreeCacheProxyImpl)cache).treeCache;
  +      treeCache = ((TreeCacheProxyImpl) cache).treeCache;
      }
   
      protected void tearDown()
  @@ -395,7 +395,7 @@
   
         System.out.println("LOCKS: " + treeCache.printLockInfo());
   
  -      assertEquals("nodeC should have a RL, nodeA should have a RL, nodeB should have a WL, nodeD should have a WL", 4, treeCache.getNumberOfLocksHeld());
  +      assertEquals("ROOT should have a RL, nodeC should have a RL, nodeA should have a RL, nodeB should have a WL, nodeD should have a WL", 5, treeCache.getNumberOfLocksHeld());
   
   
         tm.commit();
  @@ -416,7 +416,7 @@
   
         System.out.println("LOCKS: " + treeCache.printLockInfo());
   
  -      assertEquals("nodeC should have a RL, nodeA should have a RL, nodeB should have a WL", 3, treeCache.getNumberOfLocksHeld());
  +      assertEquals("ROOT should have a RL, nodeC should have a RL, nodeA should have a RL, nodeB should have a WL", 4, treeCache.getNumberOfLocksHeld());
   
   
         tm.commit();
  
  
  
  1.6       +3 -3      JBossCache/tests/functional/org/jboss/cache/api/NodeAPITest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeAPITest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeAPITest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- NodeAPITest.java	20 Nov 2006 03:53:56 -0000	1.5
  +++ NodeAPITest.java	22 Dec 2006 03:53:30 -0000	1.6
  @@ -96,13 +96,13 @@
         Node nodeC = nodeB.addChild(C);
   
         assertEquals(3, cache.getNumberOfNodes());
  -      assertEquals(3, treeCache.getNumberOfLocksHeld());
  +      assertEquals(4, treeCache.getNumberOfLocksHeld());
         tm.commit();
   
         tm.begin();
         assertEquals(0, treeCache.getNumberOfLocksHeld());
         nodeC.put("key", "value");
  -      assertEquals(3, treeCache.getNumberOfLocksHeld());
  +      assertEquals(4, treeCache.getNumberOfLocksHeld());
         tm.commit();
      }
   
  
  
  


From msurtani at jboss.com  Thu Dec 21 22:53:30 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Thu, 21 Dec 2006 22:53:30 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxbTO-00065q-BX@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/21 22:53:30

  Modified:    src/org/jboss/cache  NodeImpl.java
  Log:
  fixed breakages
  
  Revision  Changes    Path
  1.30      +4 -5      JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- NodeImpl.java	21 Dec 2006 13:11:57 -0000	1.29
  +++ NodeImpl.java	22 Dec 2006 03:53:30 -0000	1.30
  @@ -788,16 +788,15 @@
   
      public Set<Node> getChildren()
      {
  -      //return new ChildrenNodes<Node>(false);
         // strip out deleted child nodes...
  -      if (children == null || children.size() == 0) return new HashSet<Node>();
  +      if (children == null || children.size() == 0) return Collections.emptySet();
   
         Set<Node> exclDeleted = new HashSet<Node>();
         for (AbstractNode n : children.values())
         {
            if (!n.isDeleted()) exclDeleted.add(n);
         }
  -      return exclDeleted;
  +      return Collections.unmodifiableSet(exclDeleted);
      }
   
      public Set<Node> getChildren(boolean includeMarkedForRemoval)
  @@ -806,11 +805,11 @@
         {
            if (children != null && !children.isEmpty())
            {
  -            return new HashSet<Node>(children.values());
  +            return Collections.unmodifiableSet(new HashSet<Node>(children.values()));
            }
            else
            {
  -            return new HashSet<Node>();
  +            return Collections.emptySet();
            }
         }
         else
  
  
  


From Shane_Bryzak at symantec.com  Thu Dec 21 23:06:03 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Thu, 21 Dec 2006 23:06:03 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/authenticator
	...
Message-ID: <E1GxbfX-0006Rn-8T@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/21 23:06:03

  Modified:    src/main/org/jboss/seam/security/authenticator 
                        Authenticator.java
  Log:
  check if Identity is set during un-authentication
  
  Revision  Changes    Path
  1.17      +71 -70    jboss-seam/src/main/org/jboss/seam/security/authenticator/Authenticator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Authenticator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/authenticator/Authenticator.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- Authenticator.java	13 Dec 2006 05:08:53 -0000	1.16
  +++ Authenticator.java	22 Dec 2006 04:06:03 -0000	1.17
  @@ -17,12 +17,13 @@
   import org.jboss.seam.util.Reflections;
   
   /**
  - *
  + * Authenticates a user and creates an Identity for them within the session context
    *
    * @author Shane Bryzak
    */
   @Name("org.jboss.seam.security.authenticator")
  - at Install(value=false, precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
  + at Install(value = false, precedence = BUILT_IN, 
  +      dependencies = "org.jboss.seam.securityManager")
   public abstract class Authenticator
   {
     private List<AuthenticationAdapter> adapters = new ArrayList<AuthenticationAdapter>();
  @@ -35,7 +36,7 @@
       Authenticator instance = (Authenticator) Component.getInstance(
           Authenticator.class, ScopeType.APPLICATION);
   
  -    if (instance==null)
  +      if (instance == null)
       {
         throw new IllegalStateException(
             "No Authenticator could be created, make sure the Component exists in application scope");
  @@ -63,6 +64,7 @@
   
     public void unauthenticateSession()
     {
  +      if (Identity.isSet())
       Identity.instance().invalidate();
     }
   
  @@ -72,11 +74,10 @@
       {
         try
         {
  -        adapters.add((AuthenticationAdapter) Reflections.classForName(name).newInstance());
  -      }
  -      catch (Exception ex)
  -      {
  +            adapters.add((AuthenticationAdapter) Reflections.classForName(name)
  +                  .newInstance());
         }
  +         catch (Exception ex) { }
       }
     }
   
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 00:06:57 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 00:06:57 -0500
Subject: [jboss-cvs] JBossAS SVN: r59205 - in projects/microcontainer/trunk:
 deployers deployers/src/main/org/jboss/deployers/plugins/deployer
 deployers/src/main/org/jboss/deployers/plugins/deployers/helpers
 deployers/src/main/org/jboss/deployers/plugins/deployment
 deployers/src/main/org/jboss/deployers/plugins/structure
 deployers/src/main/org/jboss/deployers/plugins/structure/vfs
 deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar
 deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war
 deployers/src/main/org/jboss/deployers/spi
 deployers/src/main/org/jboss/deployers/spi/deployer
 deployers/src/main/org/jboss/deployers/spi/deployment
 deployers/src/main/org/jboss/deployers/spi/managed
 deployers/src/main/org/jboss/deployers/spi/structure/vfs
 deployers/src/tests/org/jboss/test/deployers
 deployers/src/tests/org/jboss/test/deployers/deployer
 deployers/src/tests/org/jboss/test/deployers/managed
 deployers/src/tests/org/jboss/test/deployers/managed/support
 deployers/src/te! sts/org/jboss/test/deployers/managed/test
 deployers/src/tests/org/jboss/test/deployers/structure
 deployers/src/tests/org/jboss/test/deployers/structure/ear/support
 deployers/src/tests/org/jboss/test/deployers/structure/ear/test
 deployers/src/tests/org/jboss/test/deployers/structure/main/test
 managed/src/main/org/jboss/managed/api
 managed/src/main/org/jboss/managed/plugins managed/src/tests/org/jboss/test
 managed/src/tests/org/jboss/test/managed/mock
Message-ID: <E1GxccT-0007Xo-NJ@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-22 00:06:26 -0500 (Fri, 22 Dec 2006)
New Revision: 59205

Added:
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/managed/
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/managed/ManagedObjectBuilder.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/ManagedTestSuite.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestAttachment.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestFields.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestManagedObjectDeployer.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/test/
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/test/DeployerManagedObjectUnitTestCase.java
Removed:
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty
Modified:
   projects/microcontainer/trunk/deployers/.classpath
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployer/DeployerWrapper.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AttachmentLocator.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployment/MainDeployerImpl.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ClassPathInfoImpl.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractCandidateStructureVisitor.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractStructureDeployer.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/CandidateStructureVisitorFactory.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/StructureDeployerWrapper.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARCandidateStructureVisitor.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WebInfLibFilter.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployer/Deployer.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployment/MainDeployer.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/ClassPathInfo.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructureBuilder.java
   projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructuredDeployers.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/deployer/DeployerTestSuite.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/StructureTestSuite.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/support/MockEarStructureDeployer.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/test/EARStructureUnitTestCase.java
   projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/main/test/MainDeployerStructureUnitTestCase.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java
Log:
Initial implementation of the hook between the MainDeployer/Deployers
and the ManagedObject creation.

Also some tidyup of the deployers project which has got messy.

Modified: projects/microcontainer/trunk/deployers/.classpath
===================================================================
--- projects/microcontainer/trunk/deployers/.classpath	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/.classpath	2006-12-22 05:06:26 UTC (rev 59205)
@@ -15,5 +15,6 @@
 	<classpathentry combineaccessrules="false" kind="src" path="/kernel"/>
 	<classpathentry combineaccessrules="false" kind="src" path="/dependency"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs.jar" sourcepath="/thirdparty/jboss/jboss-vfs/lib/jboss-vfs-sources.jar"/>
+	<classpathentry combineaccessrules="false" kind="src" path="/managed"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployer/DeployerWrapper.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployer/DeployerWrapper.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployer/DeployerWrapper.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -21,10 +21,14 @@
 */
 package org.jboss.deployers.plugins.deployer;
 
+import java.util.Map;
+
 import org.jboss.deployers.spi.DeploymentException;
 import org.jboss.deployers.spi.deployer.Deployer;
 import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.deployers.spi.managed.ManagedObjectBuilder;
 import org.jboss.logging.Logger;
+import org.jboss.managed.api.ManagedObject;
 
 /**
  * DeployerWrapper.<p>
@@ -35,7 +39,7 @@
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision: 1.1 $
  */
-public class DeployerWrapper implements Deployer
+public class DeployerWrapper implements Deployer, ManagedObjectBuilder
 {
    /** The log */
    private Logger log; 
@@ -43,6 +47,9 @@
    /** The deployer */
    private Deployer deployer;
    
+   /** The managed object builder */
+   private ManagedObjectBuilder managedObjectBuilder;
+   
    /**
     * Create a new DeployerWrapper.
     * 
@@ -54,6 +61,10 @@
          throw new IllegalArgumentException("Null deployer");
       this.deployer = deployer;
       this.log = Logger.getLogger(deployer.getClass());
+      
+      // Check to see whether the deployer also builds managed  objects
+      if (deployer instanceof ManagedObjectBuilder)
+         managedObjectBuilder = (ManagedObjectBuilder) deployer;
    }
    
    public boolean isRelevant(DeploymentUnit unit)
@@ -176,11 +187,35 @@
    {
       return deployer.getRelativeOrder();
    }
+
    public void setRelativeOrder(int order)
    {
       deployer.setRelativeOrder(order);
    }
 
+   public void build(DeploymentUnit unit, Map<String, ManagedObject> managedObjects) throws DeploymentException
+   {
+      // Not a managed object builder
+      if (managedObjectBuilder == null)
+         return;
+      
+      if (unit == null)
+         throw new IllegalArgumentException("Null unit");
+      if (managedObjects == null)
+         throw new IllegalArgumentException("Null managed objects");
+
+      try
+      {
+         log.trace("build: " + unit.getName());
+         managedObjectBuilder.build(unit, managedObjects);
+         log.trace("built: " + unit.getName());
+      }
+      catch (Throwable t)
+      {
+         log.warn("Error during commit undeployment: " + unit.getName(), t);
+      }
+   }
+
    @Override
    public boolean equals(Object obj)
    {

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AttachmentLocator.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AttachmentLocator.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AttachmentLocator.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -36,6 +36,7 @@
    /**
     * Get a named attachment
     * 
+    * @param unit the deployment unit
     * @param name the name of the attachment
     * @return the attachment or null if not present
     * @throws IllegalArgumentException for a null name
@@ -56,6 +57,7 @@
     * Get named attachment of a given type
     * 
     * @param <T> the expected type
+    * @param unit the deployment unit
     * @param name the name of the attachment
     * @param expectedType the expected type
     * @return the attachment or null if not present
@@ -74,6 +76,7 @@
     * 
     * @param <T> the expected type
     * @param type the type
+    * @param unit the deployment unit
     * @return the attachment or null if not present
     * @throws IllegalArgumentException for a null name or type
     */

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployment/MainDeployerImpl.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployment/MainDeployerImpl.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployment/MainDeployerImpl.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -33,6 +33,7 @@
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.Collections;
+import java.util.HashMap;
 import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
@@ -57,13 +58,18 @@
 import org.jboss.deployers.spi.structure.vfs.StructureDeployer;
 import org.jboss.deployers.spi.structure.vfs.StructureMetaData;
 import org.jboss.logging.Logger;
+import org.jboss.managed.api.ManagedObject;
 import org.jboss.virtual.VirtualFile;
 
 /**
  * MainDeployerImpl.
  * 
  * TODO full deployer protocol
+ * 
  * TODO sort out a proper state machine
+ * 
+ * TODO implement attachment flow see comment in {@link Deployer}
+ * 
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision: 1.1 $
  */
@@ -82,7 +88,7 @@
    private StructureBuilder structureBuilder = new DefaultStructureBuilder();
 
    /** The deployers */
-   private SortedSet<Deployer> deployers = new TreeSet<Deployer>(Deployer.COMPARATOR);
+   private SortedSet<DeployerWrapper> deployers = new TreeSet<DeployerWrapper>(Deployer.COMPARATOR);
    
    /** The deployments by name */
    private Map<String, DeploymentContext> topLevelDeployments = new ConcurrentHashMap<String, DeploymentContext>();
@@ -161,7 +167,9 @@
     */
    public synchronized Set<Deployer> getDeployers()
    {
-      return new TreeSet<Deployer>(deployers);
+      TreeSet<Deployer> result = new TreeSet<Deployer>(Deployer.COMPARATOR);
+      result.addAll(deployers);
+      return result;
    }
    
    /**
@@ -224,6 +232,18 @@
       return allDeployments.get(name);
    }
 
+   public Map<String, ManagedObject> getManagedObjects(DeploymentContext context) throws DeploymentException
+   {
+      if (context == null)
+         throw new IllegalArgumentException("Null context");
+      
+      Map<String, ManagedObject> managedObjects = new HashMap<String, ManagedObject>();
+      for (DeployerWrapper deployer : deployers)
+         deployer.build(context.getDeploymentUnit(), managedObjects);
+      
+      return managedObjects;
+   }
+
    public StructureBuilder getStructureBuilder()
    {
       return structureBuilder;

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ClassPathInfoImpl.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ClassPathInfoImpl.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/ClassPathInfoImpl.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -40,7 +40,7 @@
    private static final long serialVersionUID = 1;
 
    private String path;
-   private HashMap options = new HashMap();
+   private HashMap<Object, Object> options = new HashMap<Object, Object>();
 
    public ClassPathInfoImpl()
    {
@@ -65,7 +65,7 @@
       return options.get(key);
    }
 
-   public Map getOptions()
+   public Map<Object, Object> getOptions()
    {
       return options;
    }
@@ -75,7 +75,7 @@
       options.put(key, value);
    }
 
-   public void setOptions(Map options)
+   public void setOptions(Map<Object, Object> options)
    {
       this.options.clear();
       this.options.putAll(options);

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractCandidateStructureVisitor.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractCandidateStructureVisitor.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractCandidateStructureVisitor.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -60,6 +60,8 @@
     * Create a new CandidateStructureVisitor.
     * 
     * @param parent the parent
+    * @param metaData the structure meta data
+    * @param deployers the structure deployers
     * @throws IllegalArgumentException for a null parent
     */
    public AbstractCandidateStructureVisitor(VirtualFile parent, StructureMetaData metaData, StructuredDeployers deployers)
@@ -71,6 +73,8 @@
     * Create a new CandidateStructureVisitor.
     * 
     * @param parent the parent
+    * @param metaData the structure meta data
+    * @param deployers the structure deployers
     * @param attributes the attributes
     * @throws IllegalArgumentException for a null parent
     */

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractStructureDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractStructureDeployer.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/AbstractStructureDeployer.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -96,7 +96,8 @@
     * 
     * @param file
     * @param metaData
-    * @return
+    * @return true when it is top level
+    * @throws IOException for an error accessing the file
     */
    public boolean isTopLevel(VirtualFile file, StructureMetaData metaData)
       throws IOException
@@ -168,6 +169,8 @@
     * Add all children as candidates
     * 
     * @param parent the parent context
+    * @param metaData the structure meta data
+    * @param deployers the structure deployers
     * @throws Exception for any error
     */
    protected void addAllChildren(VirtualFile parent, StructureMetaData metaData, StructuredDeployers deployers)
@@ -180,6 +183,8 @@
     * Add all children as candidates
     * 
     * @param parent the parent context
+    * @param metaData the structure meta data
+    * @param deployers the structure deployers
     * @param attributes the visitor attributes uses {@link VisitorAttributes#DEFAULT} when null
     * @throws Exception for any error
     */

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/CandidateStructureVisitorFactory.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/CandidateStructureVisitorFactory.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/CandidateStructureVisitorFactory.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -38,6 +38,9 @@
    /**
     * Create the visitor
     * 
+    * @param parent the parent virtual file
+    * @param metaData the structure metaData
+    * @param deployers the structure deployers
     * @param context the deployment context
     * @param attributes the visitor attributes uses {@link VisitorAttributes#DEFAULT} when null
     * @return the visitor

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/StructureDeployerWrapper.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/StructureDeployerWrapper.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/StructureDeployerWrapper.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -21,7 +21,6 @@
 */
 package org.jboss.deployers.plugins.structure.vfs;
 
-import org.jboss.deployers.spi.structure.DeploymentContext;
 import org.jboss.deployers.spi.structure.vfs.StructureDeployer;
 import org.jboss.deployers.spi.structure.vfs.StructureMetaData;
 import org.jboss.deployers.spi.structure.vfs.StructuredDeployers;

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARCandidateStructureVisitor.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARCandidateStructureVisitor.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARCandidateStructureVisitor.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -39,6 +39,8 @@
     * Create a new JARCandidateStructureVisitor.
     * 
     * @param parent the parent
+    * @param metaData the structure meta data
+    * @param deployers the structure deployers
     * @param attributes the attributes
     * @throws IllegalArgumentException for a null parent
     * @throws Exception for any error

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -47,6 +47,7 @@
    /**
     * Sets the default relative order 10000.
     *
+    * @param suffixes the suffixes
     */
    public JARStructure(Set<String> suffixes)
    {

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WebInfLibFilter.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WebInfLibFilter.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WebInfLibFilter.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -21,7 +21,6 @@
   */
 package org.jboss.deployers.plugins.structure.vfs.war;
 
-import org.jboss.logging.Logger;
 import org.jboss.virtual.VirtualFile;
 import org.jboss.virtual.VirtualFileFilterWithAttributes;
 import org.jboss.virtual.VisitorAttributes;
@@ -35,9 +34,6 @@
  */
 public class WebInfLibFilter implements VirtualFileFilterWithAttributes
 {
-   /** The log */
-   private static final Logger log = Logger.getLogger(WebInfLibFilter.class);
-   
    /** The instance */
    public static final WebInfLibFilter INSTANCE = new WebInfLibFilter();
    

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployer/Deployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployer/Deployer.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployer/Deployer.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -21,8 +21,6 @@
 */
 package org.jboss.deployers.spi.deployer;
 
-import java.util.Comparator;
-
 import org.jboss.deployers.spi.DeploymentException;
 import org.jboss.deployers.spi.OrderedDeployer;
 
@@ -31,6 +29,12 @@
  * 
  * TODO contract for redeployment
  * 
+ * TODO the contract should really be based on attachment flow
+ *      i.e. input/output of attachments
+ *      e.g. - parsing deployer (creates an attachment)
+ *           - component deployers splits one attachment into mulitple attachments
+ *           - real deployer produces the real work for the attachment
+ * 
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
  * @version $Revision: 1.1 $
  */

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployment/MainDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployment/MainDeployer.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/deployment/MainDeployer.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -22,9 +22,11 @@
 package org.jboss.deployers.spi.deployment;
 
 import java.util.Collection;
+import java.util.Map;
 
 import org.jboss.deployers.spi.DeploymentException;
 import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.managed.api.ManagedObject;
 
 /**
  * MainDeployer.<p>
@@ -45,6 +47,15 @@
     * @return the context or null if not found
     */
    DeploymentContext getDeploymentContext(String name);
+
+   /**
+    * Get the managed object for a deployment context
+    *      
+    * @param context the context
+    * @return the managed object
+    * @throws DeploymentException for any error
+    */
+   Map<String, ManagedObject> getManagedObjects(DeploymentContext context) throws DeploymentException;
    
    /**
     * Get the top level deployments

Added: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/managed/ManagedObjectBuilder.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/managed/ManagedObjectBuilder.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/managed/ManagedObjectBuilder.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -0,0 +1,58 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.deployers.spi.managed;
+
+import java.util.Map;
+
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.managed.api.ManagedObject;
+
+/**
+ * ManagedObjectBuilder.
+ * 
+ * TODO Critique
+ *      Rather having the contexts create the managed objects directly
+ *      they should provide the underlying metadata, e.g. the Fields + other information
+ *      from which we can create the managed object.
+ *      This is important because it is likely that multiple builders/deployers will
+ *      play populate an object, e.g. (possibly?)
+ *      - the parsing deployer will describe the properties/metadata
+ *      - there maybe transformation, augmentation by some other deployers
+ *      - the component deployers will want to link their component metadata back into
+ *            the parent by reference, e.g. an mbean as part of sar/-service.xml  
+ *      - the real deployer will describe any runtime support, e.g. managed operations and statistics
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public interface ManagedObjectBuilder
+{
+   /**
+    * Build managed objects for this deployment context
+    * 
+    * @param unit the deployment unit
+    * @param managedObjects the managed objects
+    * @throws DeploymentException
+    */
+   void build(DeploymentUnit unit, Map<String, ManagedObject> managedObjects) throws DeploymentException;
+}

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/ClassPathInfo.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/ClassPathInfo.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/ClassPathInfo.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -32,31 +32,45 @@
 public interface ClassPathInfo
 {
    /**
-    * path relative to the context virtual file.
+    * Get the path relative to the context virtual file
+    * 
+    * @return the path.
     */
-   public String getPath();
-   public void setPath(String path);
+   String getPath();
+   
    /**
+    * Set the path relative to the context virtual file
+    * 
+    * @param path the path
+    */
+   void setPath(String path);
+   
+   /**
     * Get the options associated with the classpath entry.
+    * 
     * @return A map of entry options.
     */
-   public Map getOptions();
+   Map<Object, Object> getOptions();
+   
    /**
     * Set the options associated with the classpath entry.
+    * 
     * @param options - A map of entry options.
     */
-   public void setOptions(Map options);
+   void setOptions(Map<Object, Object> options);
 
    /**
     * Get a classpath entry option
     * @param key - the option key
     * @return the option if it exists, null otherwise
     */
-   public Object getOption(Object key);
+   Object getOption(Object key);
+   
    /**
     * Set a classpath entry option
+    * 
     * @param key - the option key
     * @param value - the option value
     */
-   public void setOption(Object key, Object value);
+   void setOption(Object key, Object value);
 }

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructureBuilder.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructureBuilder.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructureBuilder.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -40,7 +40,7 @@
     * @param context - the root deployment context to populate
     * @param metaData - the metadata from a structural parse of the context
     *    root VirtualFile
-    * @throws Exception for any error
+    * @throws DeploymentException for any error
     */
    public void populateContext(DeploymentContext context, StructureMetaData metaData)
       throws DeploymentException;

Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructuredDeployers.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructuredDeployers.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/spi/structure/vfs/StructuredDeployers.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -49,9 +49,10 @@
     * @return the ordered set of deployers.
     */
    public SortedSet<StructureDeployer> getDeployers();
+
    /**
     * Are there any deployers
-    * @return 
+    * @return true when empty
     */
    public boolean isEmpty();
 }

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/BaseDeployersTest.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -22,7 +22,6 @@
 package org.jboss.test.deployers;
 
 import java.io.IOException;
-import java.net.MalformedURLException;
 import java.net.URISyntaxException;
 import java.net.URL;
 import java.util.HashMap;
@@ -99,7 +98,7 @@
     * Get a vfs url string from a path
     * 
     * @param path
-    * @return
+    * @return the url
     * @throws Exception
     */
    protected String getVfsURL(String path) throws Exception
@@ -137,9 +136,11 @@
       deployers.addDeployer(getStrucutureDeployer());
       return deployers;
    }
+
    /**
     * Get the StructureVisitorFactory that translates the StructureMetaData into a DeploymentContext tree.
-    * @return
+    * 
+    * @return the builder
     */
    protected StructureBuilderFactory getStructureBuilderFactory()
    {
@@ -150,7 +151,9 @@
     * Determine the structure
     * 
     * @param context the context
+    * @param addTopLevelInfo whether to add top level info
     * @return the result
+    * @throws Exception for any error
     */
    protected boolean determineStructure(DeploymentContext context, boolean addTopLevelInfo)
       throws Exception
@@ -163,9 +166,10 @@
    /**
     * Determine the structure
     * 
-    * @param structure the structural deployer
+    * @param deployer the structural deployer
     * @param context the context
     * @return the result
+    * @throws Exception for any error
     */
    protected boolean determineStructure(StructureDeployer deployer,
          DeploymentContext context)
@@ -173,12 +177,15 @@
    {
       return determineStructure(deployer, getStrucuturedDeployers(), context, false);
    }
+
    /**
     * Determine the structure
     * 
-    * @param structure the structural deployer
+    * @param deployer the structural deployer
     * @param context the context
+    * @param addTopLevelInfo whether to add top level info
     * @return the result
+    * @throws Exception for any error
     */
    protected boolean determineStructure(StructureDeployer deployer,
          DeploymentContext context, boolean addTopLevelInfo)
@@ -187,14 +194,15 @@
       return determineStructure(deployer, getStrucuturedDeployers(), context, addTopLevelInfo);
    }
    /**
+    * Determine the structure
     * 
     * @param deployer
     * @param deployers
     * @param context
     * @param addTopLevelInfo - should a ContextInfo be created for the
     *    context root
-    * @return
-    * @throws Exception
+    * @return whether the structure was determined
+    * @throws Exception for any error
     */
    protected boolean determineStructure(StructureDeployer deployer,
          StructuredDeployers deployers, DeploymentContext context,
@@ -353,7 +361,8 @@
     * Translate a set of DeploymentContexts string paths relative to the root
     * URL.
     * 
-    * @param set
+    * @param set the deployment contexts
+    * @param root the root url
     * @return set of 
     * @throws URISyntaxException 
     * @throws IOException 
@@ -386,7 +395,9 @@
     * some.ear/child.jar
     * 
     * @param root ctx
-    * @return
+    * @return the map
+    * @throws IOException for an error accessing the vfs path
+    * @throws URISyntaxException for an error resolving the uri
     */
    protected Map<String, DeploymentContext> createDeploymentPathMap(DeploymentContext root)
       throws IOException, URISyntaxException

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/deployer/DeployerTestSuite.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/deployer/DeployerTestSuite.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/deployer/DeployerTestSuite.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -32,6 +32,7 @@
 import org.jboss.test.deployers.deployer.test.DeployerProtocolUnitTestCase;
 import org.jboss.test.deployers.deployer.test.DeployerWidthFirstUnitTestCase;
 import org.jboss.test.deployers.deployer.test.MainDeployerDeployerUnitTestCase;
+import org.jboss.test.deployers.managed.ManagedTestSuite;
 import org.jboss.test.deployers.metadata.test.MetaDataUnitTestCase;
 
 /**
@@ -57,6 +58,7 @@
       suite.addTest(DeployerClassLoaderUnitTestCase.suite());
       suite.addTest(MainDeployerDeployerUnitTestCase.suite());
       suite.addTest(MetaDataUnitTestCase.suite());
+      suite.addTest(ManagedTestSuite.suite());
       suite.addTest(BeanDeployerUnitTestCase.suite());
       suite.addTest(KernelDeployerUnitTestCase.suite());
 

Added: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/ManagedTestSuite.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/ManagedTestSuite.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/ManagedTestSuite.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -0,0 +1,51 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.deployers.managed;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.test.deployers.managed.test.DeployerManagedObjectUnitTestCase;
+
+/**
+ * Managed Test Suite.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 37459 $
+ */
+public class ManagedTestSuite extends TestSuite
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("Managed Tests");
+
+      suite.addTest(DeployerManagedObjectUnitTestCase.suite());
+
+      return suite;
+   }
+}

Added: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestAttachment.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestAttachment.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestAttachment.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.deployers.managed.support;
+
+import java.io.Serializable;
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * TestAttachment.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class TestAttachment implements Cloneable, Serializable
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+   
+   private Map<String, Serializable> fields = new HashMap<String, Serializable>();
+
+   public Serializable getProperty(String name)
+   {
+      return fields.get(name);
+   }
+
+   public void setProperty(String name, Serializable value)
+   {
+      fields.put(name, value);
+   }
+   
+   public TestAttachment clone()
+   {
+      try
+      {
+         TestAttachment clone = (TestAttachment) super.clone();
+         clone.fields = new HashMap<String, Serializable>(clone.fields);
+         return clone;
+      }
+      catch (CloneNotSupportedException e)
+      {
+         throw new Error("Unexpected", e);
+      }
+   }
+}

Added: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestFields.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestFields.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestFields.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.deployers.managed.support;
+
+import java.io.Serializable;
+
+import org.jboss.managed.api.Fields;
+
+/**
+ * TestFields.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class TestFields implements Fields
+{
+   /** The serialVersionUID */
+   private static final long serialVersionUID = 1L;
+
+   private TestAttachment attachment;
+   
+   private String property;
+   
+   public TestFields(TestAttachment attachment, String property)
+   {
+      this.attachment = attachment;
+      this.property = property;
+   }
+
+   public Serializable getField(String name)
+   {
+      if (name == Fields.NAME)
+         return property;
+      if (name == Fields.VALUE)
+         return attachment.getProperty(property);
+      return null;
+   }
+
+   public void setField(String name, Serializable value)
+   {
+      if (name == Fields.VALUE)
+      {
+         attachment.setProperty(property, value);
+         return;
+      }
+      throw new UnsupportedOperationException("setField: " + name);
+   }
+}

Added: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestManagedObjectDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestManagedObjectDeployer.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/support/TestManagedObjectDeployer.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -0,0 +1,72 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.deployers.managed.support;
+
+import java.util.Map;
+import java.util.Set;
+
+import org.jboss.deployers.plugins.deployer.AbstractSimpleDeployer;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.spi.deployer.DeploymentUnit;
+import org.jboss.deployers.spi.managed.ManagedObjectBuilder;
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.managed.api.ManagedProperty;
+import org.jboss.managed.plugins.ManagedObjectImpl;
+import org.jboss.managed.plugins.ManagedPropertyImpl;
+
+/**
+ * TestManagedObjectDeployer.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class TestManagedObjectDeployer extends AbstractSimpleDeployer implements ManagedObjectBuilder
+{
+   public static TestAttachment lastAttachment;
+   
+   public void deploy(DeploymentUnit unit) throws DeploymentException
+   {
+      lastAttachment = unit.getAttachment(TestAttachment.class);
+      if (lastAttachment == null)
+      {
+         lastAttachment = new TestAttachment();
+         lastAttachment.setProperty("string1", "initialString1");
+         lastAttachment.setProperty("string2", "initialString2");
+         unit.addAttachment(TestAttachment.class, lastAttachment);
+      }
+   }
+
+   public void build(DeploymentUnit unit, Map<String, ManagedObject> managedObjects) throws DeploymentException
+   {
+      TestAttachment attachment = unit.getAttachment(TestAttachment.class);
+      if (attachment != null)
+      {
+         attachment = attachment.clone();
+         ManagedObjectImpl managedObject = new ManagedObjectImpl(TestAttachment.class.getName());
+         managedObject.setAttachment(attachment);
+         Set<ManagedProperty> properties = managedObject.getProperties();
+         properties.add(new ManagedPropertyImpl(managedObject, new TestFields(attachment, "string1")));
+         properties.add(new ManagedPropertyImpl(managedObject, new TestFields(attachment, "string2")));
+         managedObjects.put(TestAttachment.class.getName(), managedObject);
+      }
+   }
+}

Added: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/test/DeployerManagedObjectUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/test/DeployerManagedObjectUnitTestCase.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/managed/test/DeployerManagedObjectUnitTestCase.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -0,0 +1,125 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.deployers.managed.test;
+
+import java.util.Map;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.jboss.deployers.plugins.deployment.MainDeployerImpl;
+import org.jboss.deployers.spi.deployment.MainDeployer;
+import org.jboss.deployers.spi.structure.DeploymentContext;
+import org.jboss.managed.api.ManagedObject;
+import org.jboss.test.deployers.BaseDeployersTest;
+import org.jboss.test.deployers.managed.support.TestAttachment;
+import org.jboss.test.deployers.managed.support.TestManagedObjectDeployer;
+
+/**
+ * DeployerManagedObjectUnitTestCase.
+ * 
+ * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @version $Revision: 1.1 $
+ */
+public class DeployerManagedObjectUnitTestCase extends BaseDeployersTest
+{
+   private MainDeployer mainDeployer;
+   
+   private TestManagedObjectDeployer deployer = new TestManagedObjectDeployer();
+   
+   public static Test suite()
+   {
+      return new TestSuite(DeployerManagedObjectUnitTestCase.class);
+   }
+   
+   public DeployerManagedObjectUnitTestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testManagedObject() throws Exception
+   {
+      MainDeployer main = getMainDeployer();
+      
+      // Deploy a context
+      DeploymentContext context = createSimpleDeployment("deploy");
+      main.addDeploymentContext(context);
+      main.process();
+      
+      // Check the default settings
+      assertNotNull(deployer.lastAttachment);
+      assertEquals("initialString1", deployer.lastAttachment.getProperty("string1"));
+      assertEquals("initialString2", deployer.lastAttachment.getProperty("string2"));
+      
+      // Get the managed object
+      Map<String, ManagedObject> mos = main.getManagedObjects(context);
+      assertNotNull(mos);
+      ManagedObject mo = mos.get(TestAttachment.class.getName());
+      assertNotNull(mo);
+      
+      // TODO the attachment should NOT be the top level managed object
+      //      that should be describing the structure and deployment state
+      //      with the attachments as sub managed objects
+      
+      // Check the managed object has the default settings
+      assertEquals("initialString1", mo.getProperty("string1").getValue());
+      assertEquals("initialString2", mo.getProperty("string2").getValue());
+      
+      // Change a value
+      mo.getProperty("string1").setValue("changedString1");
+      
+      // Get the changed attachment
+      TestAttachment attachment = (TestAttachment) mo.getAttachment();
+
+      // Redeploy with our changed attachment
+      context.getPredeterminedManagedObjects().addAttachment(TestAttachment.class, attachment);
+      main.addDeploymentContext(context);
+      main.process();
+
+      // Check the changed settings as seen by the deployer
+      assertNotNull(deployer.lastAttachment);
+      assertEquals("changedString1", deployer.lastAttachment.getProperty("string1"));
+      assertEquals("initialString2", deployer.lastAttachment.getProperty("string2"));
+      
+      // TODO shouldn't have to reget the managed object handles across redeploys?
+      mos = main.getManagedObjects(context);
+      assertNotNull(mos);
+      mo = mos.get(TestAttachment.class.getName());
+      assertNotNull(mo);
+
+      // Check the changed settings as described by the managed object
+      assertEquals("changedString1", mo.getProperty("string1").getValue());
+      assertEquals("initialString2", mo.getProperty("string2").getValue());
+   }
+   
+   protected MainDeployer getMainDeployer()
+   {
+      if (mainDeployer != null)
+         return mainDeployer;
+      
+      MainDeployerImpl result = new MainDeployerImpl();
+      result.addDeployer(deployer);
+      
+      mainDeployer = result;
+      return result;
+   }
+}

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/StructureTestSuite.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/StructureTestSuite.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/StructureTestSuite.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -26,6 +26,7 @@
 import junit.textui.TestRunner;
 
 import org.jboss.test.deployers.structure.ear.test.EARStructureUnitTestCase;
+import org.jboss.test.deployers.structure.explicit.test.DeclaredStructureUnitTestCase;
 import org.jboss.test.deployers.structure.file.test.FileStructureUnitTestCase;
 import org.jboss.test.deployers.structure.jar.test.JARStructureUnitTestCase;
 import org.jboss.test.deployers.structure.main.test.MainDeployerFileStructureUnitTestCase;
@@ -56,6 +57,7 @@
       suite.addTest(JARStructureUnitTestCase.suite());
       suite.addTest(WARStructureUnitTestCase.suite());
       suite.addTest(EARStructureUnitTestCase.suite());
+      suite.addTest(DeclaredStructureUnitTestCase.suite());
       suite.addTest(MainDeployerStructureUnitTestCase.suite());
       suite.addTest(MainDeployerStructureOrderingUnitTestCase.suite());
       suite.addTest(MainDeployerFileStructureUnitTestCase.suite());

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/support/MockEarStructureDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/support/MockEarStructureDeployer.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/support/MockEarStructureDeployer.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -26,7 +26,6 @@
 import java.util.ArrayList;
 import java.util.List;
 import java.util.Properties;
-import java.util.Set;
 
 import org.jboss.deployers.plugins.structure.ContextInfoImpl;
 import org.jboss.deployers.plugins.structure.vfs.AbstractStructureDeployer;

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/test/EARStructureUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/test/EARStructureUnitTestCase.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/ear/test/EARStructureUnitTestCase.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -35,7 +35,6 @@
 import org.jboss.deployers.plugins.structure.vfs.file.FileStructure;
 import org.jboss.deployers.plugins.structure.vfs.jar.JARStructure;
 import org.jboss.deployers.plugins.structure.vfs.war.WARStructure;
-import org.jboss.deployers.spi.deployer.DeploymentUnit;
 import org.jboss.deployers.spi.structure.DeploymentContext;
 import org.jboss.deployers.spi.structure.vfs.StructureDeployer;
 import org.jboss.deployers.spi.structure.vfs.StructuredDeployers;

Modified: projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/main/test/MainDeployerStructureUnitTestCase.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/main/test/MainDeployerStructureUnitTestCase.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/deployers/src/tests/org/jboss/test/deployers/structure/main/test/MainDeployerStructureUnitTestCase.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -23,10 +23,7 @@
 
 import java.util.Collections;
 import java.util.HashSet;
-import java.util.Iterator;
 import java.util.Set;
-import java.util.SortedSet;
-import java.util.TreeSet;
 
 import junit.framework.AssertionFailedError;
 import junit.framework.Test;
@@ -34,10 +31,6 @@
 
 import org.jboss.deployers.plugins.deployment.MainDeployerImpl;
 import org.jboss.deployers.plugins.structure.AbstractDeploymentContext;
-import org.jboss.deployers.plugins.structure.BasicStructuredDeployers;
-import org.jboss.deployers.plugins.structure.vfs.StructureDeployerWrapper;
-import org.jboss.deployers.plugins.structure.vfs.explicit.DeclaredStructure;
-import org.jboss.deployers.plugins.structure.vfs.file.FileStructure;
 import org.jboss.deployers.plugins.structure.vfs.jar.JARStructure;
 import org.jboss.deployers.plugins.structure.vfs.war.WARStructure;
 import org.jboss.deployers.spi.structure.DeploymentContext;

Modified: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/api/ManagedObject.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -33,6 +33,20 @@
 public interface ManagedObject extends Serializable
 {
    /**
+    * Get the attachment name
+    * 
+    * @return the name
+    */
+   String getName();
+   
+   /**
+    * Get the underlying object
+    * 
+    * @return the underlying object
+    */
+   Serializable getAttachment();
+
+   /**
     * Get the property names
     * 
     * @return the property names

Modified: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedObjectImpl.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -21,7 +21,7 @@
 */
 package org.jboss.managed.plugins;
 
-import java.util.Collections;
+import java.io.Serializable;
 import java.util.HashSet;
 import java.util.Set;
 
@@ -39,21 +39,70 @@
    /** The serialVersionUID */
    private static final long serialVersionUID = -2588364350006686542L;
 
+   /** The attachment name */
+   private String name;
+   
+   /** The attachment */
+   private Serializable attachment;
+   
    /** The properties */
    private Set<ManagedProperty> properties;
    
    /**
     * Create a new ManagedObjectImpl
     * 
+    * @param name the attachment name
+    */
+   public ManagedObjectImpl(String name)
+   {
+      if (name == null)
+         throw new IllegalArgumentException("Null name");
+      
+      this.name = name;
+      properties = new HashSet<ManagedProperty>();
+   }
+   
+   /**
+    * Create a new ManagedObjectImpl
+    * 
+    * @param name the attachment name
     * @param properties the properties 
     */
-   public ManagedObjectImpl(Set<ManagedProperty> properties)
+   public ManagedObjectImpl(String name, Set<ManagedProperty> properties)
    {
+      if (name == null)
+         throw new IllegalArgumentException("Null name");
       if (properties == null)
-         properties = Collections.emptySet();
+         throw new IllegalArgumentException("Null properties");
+      
+      this.name = name;
       this.properties = properties;
    }
    
+   /**
+    * Create a new ManagedObjectImpl
+    * 
+    * @param name the attachment name
+    * @param properties the properties 
+    * @param attachment the attachment
+    */
+   public ManagedObjectImpl(String name, Set<ManagedProperty> properties, Serializable attachment)
+   {
+      if (name == null)
+         throw new IllegalArgumentException("Null name");
+      if (properties == null)
+         throw new IllegalArgumentException("Null properties");
+      
+      this.name = name;
+      this.properties = properties;
+      setAttachment(attachment);
+   }
+   
+   public String getName()
+   {
+      return name;
+   }
+
    public Set<String> getPropertyNames()
    {
       Set<String> result = new HashSet<String>(properties.size());
@@ -79,4 +128,43 @@
    {
       return properties;
    }
+
+   public Serializable getAttachment()
+   {
+      return attachment;
+   }
+
+   /**
+    * Set the attachment.
+    * 
+    * @param attachment the attachment.
+    */
+   public void setAttachment(Serializable attachment)
+   {
+      this.attachment = attachment;
+   }
+   
+   @Override
+   public boolean equals(Object obj)
+   {
+      if (obj == this)
+         return true;
+      if (obj == null || obj instanceof ManagedObject == false)
+         return false;
+      
+      ManagedObject other = (ManagedObject) obj;
+      return getName().equals(other.getName()) && getProperties().equals(other.getProperties());
+   }
+   
+   @Override
+   public int hashCode()
+   {
+      return name.hashCode();
+   }
+   
+   @Override
+   public String toString()
+   {
+      return "ManagedObject{" + name + "}"; 
+   }
 }

Deleted: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/empty	2006-12-22 05:06:26 UTC (rev 59205)
@@ -1 +0,0 @@
-empty
\ No newline at end of file

Modified: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java	2006-12-21 22:09:38 UTC (rev 59204)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/mock/MockDataSourceManagedObject.java	2006-12-22 05:06:26 UTC (rev 59205)
@@ -21,7 +21,6 @@
 */
 package org.jboss.test.managed.mock;
 
-import java.util.HashSet;
 import java.util.Set;
 
 import javax.xml.parsers.DocumentBuilder;
@@ -54,7 +53,7 @@
     */
    public MockDataSourceManagedObject()
    {
-      super(new HashSet<ManagedProperty>());
+      super("Mock");
       Element element;
       try
       {



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 00:07:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 00:07:41 -0500
Subject: [jboss-cvs] JBossAS SVN: r59206 -
	projects/microcontainer/trunk/deployers
Message-ID: <E1GxcdB-0007Z5-Ry@committer01.frg.pub.inap.atl.jboss.com>

Author: adrian at jboss.org
Date: 2006-12-22 00:07:39 -0500 (Fri, 22 Dec 2006)
New Revision: 59206

Modified:
   projects/microcontainer/trunk/deployers/build-test.xml
   projects/microcontainer/trunk/deployers/build.xml
Log:
Initial implementation of the hook between the MainDeployer/Deployers
and the ManagedObject creation.

Also some tidyup of the deployers project which has got messy.

Modified: projects/microcontainer/trunk/deployers/build-test.xml
===================================================================
--- projects/microcontainer/trunk/deployers/build-test.xml	2006-12-22 05:06:26 UTC (rev 59205)
+++ projects/microcontainer/trunk/deployers/build-test.xml	2006-12-22 05:07:39 UTC (rev 59206)
@@ -72,7 +72,8 @@
       <path refid="jboss/common.logging.spi.classpath"/>
       <path refid="jboss/common.logging.log4j.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
-      <path refid="jboss.container.classpath"/>
+      <path refid="jboss/jboss.vfs.classpath"/>
+      <path refid="oswego.concurrent.classpath"/>
       <path refid="junit.junit.classpath"/>
       <path refid="apache.log4j.classpath"/>
       <path refid="jboss.test.classpath"/>
@@ -99,6 +100,8 @@
       <path refid="jboss.container.classpath"/>
       <path refid="jboss.dependency.classpath"/>
       <path refid="jboss.kernel.classpath"/>
+      <path refid="jboss.metatype.classpath"/>
+      <path refid="jboss.managed.classpath"/>
       <path refid="jboss.this.classpath"/>
     </path>
 

Modified: projects/microcontainer/trunk/deployers/build.xml
===================================================================
--- projects/microcontainer/trunk/deployers/build.xml	2006-12-22 05:06:26 UTC (rev 59205)
+++ projects/microcontainer/trunk/deployers/build.xml	2006-12-22 05:07:39 UTC (rev 59206)
@@ -71,6 +71,7 @@
       <path refid="jboss/common.logging.spi.classpath"/>
       <path refid="jboss/common.logging.log4j.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
+      <path refid="jboss/jboss.vfs.classpath"/>
     </path>
 
     &modules;
@@ -80,7 +81,7 @@
       <path refid="jboss.container.classpath"/>
       <path refid="jboss.dependency.classpath"/>
       <path refid="jboss.kernel.classpath"/>
-      <path refid="jboss/jboss.vfs.classpath"/>
+      <path refid="jboss.managed.classpath"/>
     </path>
      
     <!-- ===== -->
@@ -110,7 +111,7 @@
   <target name="compile"
 	  description="Compile all source files."
 	  depends="_default:compile-classes,
-	           _default:compile-resources,
+	           _default:compile-resources-no-filter,
               _default:compile-etc"
   />
    



From forge-admin at jboss.com  Fri Dec 22 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Fri, 22 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GxdSF-0008O5-9T@committer01.frg.pub.inap.atl.jboss.com>

Commit from sbryzak2 (2006-12-21 03:16 EST)
--------------------

renamed ImageAction to ContentAction

  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java  1.2
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java   1.1
+ jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentLocal.java    1.1
- jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ImageAction.java     1.2
- jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ImageLocal.java      1.2


Commit from tokada on branch JBossProfiler_Expansion (2006-12-21 06:18 EST)
----------------------------------------------------

Modified an implementation concerned the sorting.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/collector/model/ThreadMetric.java  1.1.2.3


Commit from tokada on branch JBossProfiler_Expansion (2006-12-21 06:21 EST)
----------------------------------------------------

Corrected some bugs.

  jboss-profiler  java/webapp/lzx/borderedpane.lzx           1.1.2.2
  jboss-profiler  java/webapp/lzx/stacktracediagram.lzx      1.1.2.6
  jboss-profiler  java/webapp/lzx/httprequeststatistics.lzx  1.1.2.4
  jboss-profiler  java/webapp/lzx/dataaccessstatistics.lzx   1.1.2.5


Commit from tokada on branch JBossProfiler_Expansion (2006-12-21 06:22 EST)
----------------------------------------------------

Added some functions.

+ jboss-profiler  java/webapp/lzx/popupmessage.lzx    1.1.2.1
  jboss-profiler  java/webapp/lzx/settingdialog.lzx   1.1.2.6
+ jboss-profiler  java/webapp/lzx/hintededittext.lzx  1.1.2.1
  jboss-profiler  java/webapp/lzx/loadingsplash.lzx   1.1.2.2


Commit from tokada on branch JBossProfiler_Expansion (2006-12-21 07:27 EST)
----------------------------------------------------

Corrected some bugs.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ConcurrencyMetrics.java  1.1.2.3
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ExecutionMetrics.java    1.1.2.3
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/MemoryMetrics.java       1.1.2.3


Commit from sbryzak2 (2006-12-21 08:05 EST)
--------------------

display member's picture on profile page using content servlet

  jboss-seam  examples/seamspace/resources/import.sql                                      1.5
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java   1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java  1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java          1.9
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/MemberImage.java     1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java   1.3
  jboss-seam  examples/seamspace/view/profile.xhtml                                        1.2


Commit from msurtani (2006-12-21 08:11 EST)
--------------------

updated tostring

  JBossCache  src/org/jboss/cache/NodeImpl.java  1.29


Commit from vblagojevic (2006-12-21 10:14 EST)
-----------------------

fixed state transfer

  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java  1.51


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-21 10:42 EST)
------------------------------------------------------

refactored

  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java  1.33.2.9


Commit from msurtani (2006-12-21 11:19 EST)
--------------------

refactored

  JBossCache  src/org/jboss/cache/buddyreplication/BuddyLocator.java                            1.5
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                            1.52
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyGroup.java                              1.9
  JBossCache  src/org/jboss/cache/buddyreplication/NextMemberBuddyLocator.java                  1.8
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationTestsBase.java  1.33
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyGroupAssignmentTest.java   1.13


Commit from telrod on branch remoting_2_x (2006-12-21 11:40 EST)
-----------------------------------------

JBREM-655 - make sure server thread name gets updated with new client address when woken up with new client socket connection.

  JBossRemoting  src/main/org/jboss/remoting/transport/socket/ServerThread.java  1.29.2.4


Commit from telrod (2006-12-21 11:43 EST)
------------------

JBREM-655 - updated server thread to update its thread name with client address when woken up with new client socket connection.

  JBossRemoting  src/main/org/jboss/remoting/transport/socket/ServerThread.java  1.31


Commit from msurtani (2006-12-21 12:59 EST)
--------------------

Increased robustness

  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java  1.16
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                         1.53


Commit from msurtani (2006-12-21 13:10 EST)
--------------------

Increased robustness

  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java  1.54


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-21 13:16 EST)
------------------------------------------------------

improved robustness

  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java  1.12.2.2
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                         1.33.2.10


Commit from msurtani (2006-12-21 13:17 EST)
--------------------

versioning info

  JBossCache  src/org/jboss/cache/Version.java  1.25
  JBossCache  build.xml                         1.155


Commit from sshah (2006-12-21 14:26 EST)
-----------------

adding

+ repository.jboss.com  jbpm/3.1.2/lib/jbpm-3.1.2.jar           1.1
+ repository.jboss.com  jbpm/3.1.2/lib/jbpm-identity-3.1.2.jar  1.1


Commit from sshah (2006-12-21 14:28 EST)
-----------------

adding_jars

  repository.jboss.com  jbpm/3.1.2/component-info.xml  1.2


Commit from vralev (2006-12-21 14:58 EST)
------------------

http://jira.jboss.com/jira/browse/JBINSTALL-166

    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/installer.jar            1.3
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/izevent.jar              1.2
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar  1.3
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller.jar          1.3
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/uninstaller-ext.jar      1.3


Commit from nrichards (2006-12-21 15:19 EST)
---------------------

JBSEAM-623: support locales for selectDate display

  jboss-seam  src/ui/org/jboss/seam/ui/SelectDate.java  1.4
  jboss-seam  src/ui/org/jboss/seam/ui/selectDate.js    1.3


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-21 16:19 EST)
---------------------------------------------------------

[JBCACHE-913] Add a test that eviction actually occurs.

  JBossCache  tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java  1.1.2.2


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-21 16:21 EST)
---------------------------------------------------------

[JBCACHE-913] Do the TreeCacheListener and eviction region notifications as part of the basic state transfer node creation

  JBossCache  src/org/jboss/cache/statetransfer/StateTransferIntegrator_140.java  1.6.2.1
  JBossCache  src/org/jboss/cache/TreeCache.java                                  1.195.2.39


Commit from smcgowan (2006-12-21 16:41 EST)
--------------------


created

+ repository.jboss.com  jboss/cache/1.4.1.CR1/README.txt                 1.1
+ repository.jboss.com  jboss/cache/1.4.1.CR1/component-info.xml         1.1
+ repository.jboss.com  jboss/cache/1.4.1.CR1/lib/jboss-cache-jdk50.jar  1.1
+ repository.jboss.com  jboss/cache/1.4.1.CR1/lib/jboss-cache.jar        1.1


Commit from vblagojevic (2006-12-21 16:41 EST)
-----------------------

final state transfer polishing (all tests pass now)

  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java   1.7
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java  1.9
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferManager.java            1.19
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                 1.55
  JBossCache  src/org/jboss/cache/TreeCache.java                                     1.300


Commit from vblagojevic (2006-12-21 16:41 EST)
-----------------------

test update

  JBossCache  tests/functional/org/jboss/cache/statetransfer/FailedStateTransferTest.java  1.7
  JBossCache  tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java        1.20
  JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java    1.25
  JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransfer200Test.java     1.11


Commit from bstansberry (2006-12-21 18:11 EST)
-----------------------

[JBCACHE-913] Add test of notifying eviction policies of nodes added via state transfer

- JBossCache  tests/functional/org/jboss/cache/eviction/StateTransferIntegrationTest.java  1.2


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-21 18:11 EST)
---------------------------------------------------------

Move the JBCACHE-913 tests to the versioned state transfer tests

  JBossCache  tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java  1.6.2.3


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-21 18:14 EST)
---------------------------------------------------------

[JBCACHE-913] Handle TreeCacheListener notifications as before to reduce chance of introducing subtle regressions

  JBossCache  src/org/jboss/cache/TreeCache.java  1.195.2.40


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-21 18:14 EST)
---------------------------------------------------------

Make the DEFAULT_REGION Fqn public

  JBossCache  src/org/jboss/cache/eviction/RegionManager.java  1.16.2.2


Commit from bstansberry on branch Branch_JBossCache_1_4_0 (2006-12-21 18:16 EST)
---------------------------------------------------------

[JBCACHE-913] Handle TreeCacheListener notifications as before to reduce chance of introducing subtle regressions
Don't fail if there is no region defined
Add the logic to all the STI impls

  JBossCache  src/org/jboss/cache/statetransfer/StateTransferIntegrator_123.java   1.2.4.1
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferIntegrator_124.java   1.6.2.1
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferIntegrator_140.java   1.6.2.2
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferIntegrator_1241.java  1.4.2.1


Commit from rawb (2006-12-21 20:08 EST)
----------------

The Extension Manager had several errors. It used the incorrect method of instantiating a provided class (Class.forName led to class not found errors. configElement.createExecutable("attribute") is the proper method)

It also assumed all provided classes would be of type AbstractPackageType, instead of IPackageType. It then made use of methods not present in IPackageType (setId, setLabel). I've removed all references to AbstractPackageType, the JARPackageType now directly returns its information (jar, JAR), and the extension point data is essentially ignored.

Suck It.

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java       1.7
- jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/AbstractPackageType.java  1.2
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java                 1.3


Commit from sbryzak2 (2006-12-21 21:03 EST)
--------------------

fixed Identity working memory test

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java  1.31


Commit from sbryzak2 (2006-12-21 21:04 EST)
--------------------

added security rules

  jboss-seam  examples/seamspace/resources/META-INF/application.xml                       1.6
+ jboss-seam  examples/seamspace/resources/META-INF/security-rules.drl                    1.1
  jboss-seam  examples/seamspace/resources/WEB-INF/pages.xml                              1.2
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentAction.java  1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/LoginAction.java    1.5
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/LoginLocal.java     1.3
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java  1.4
  jboss-seam  examples/seamspace/view/template.xhtml                                      1.5


Commit from tokada on branch JBossProfiler_Expansion (2006-12-21 21:25 EST)
----------------------------------------------------

Corrected some bugs.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/collector/model/ThreadMetric.java  1.1.2.4


Commit from sbryzak2 (2006-12-21 21:50 EST)
--------------------

support image rescaling

  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java  1.4
  jboss-seam  examples/seamspace/view/profile.xhtml                                        1.3


Commit from msurtani (2006-12-21 22:16 EST)
--------------------

properly sets file cache loader location

  JBossCache  tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java  1.12


Commit from msurtani (2006-12-21 22:17 EST)
--------------------

genericised

  JBossCache  src/org/jboss/cache/config/CacheLoaderConfig.java  1.18


Commit from msurtani (2006-12-21 22:23 EST)
--------------------

genericised

  JBossCache  src/org/jboss/cache/config/CacheLoaderConfig.java  1.19


Commit from msurtani (2006-12-21 22:28 EST)
--------------------

updated known issues

  JBossCache  build.xml  1.156


Commit from msurtani (2006-12-21 22:29 EST)
--------------------

patched test to work with broken/incomplete config files

  JBossCache  tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java  1.7


Commit from msurtani (2006-12-21 22:53 EST)
--------------------

fixed breakages

  JBossCache  tests/functional/org/jboss/cache/api/NodeMoveAPITest.java  1.14
  JBossCache  tests/functional/org/jboss/cache/api/NodeAPITest.java      1.6
  JBossCache  src/org/jboss/cache/NodeImpl.java                          1.30


Commit from sbryzak2 (2006-12-21 23:06 EST)
--------------------

check if Identity is set during un-authentication

  jboss-seam  src/main/org/jboss/seam/security/authenticator/Authenticator.java  1.17
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061222/2f883329/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 01:45:51 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 01:45:51 -0500
Subject: [jboss-cvs] JBossAS SVN: r59207 -
	projects/microcontainer/trunk/tools/etc/buildmagic
Message-ID: <E1GxeAB-0000nb-Gq@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-22 01:45:49 -0500 (Fri, 22 Dec 2006)
New Revision: 59207

Modified:
   projects/microcontainer/trunk/tools/etc/buildmagic/buildmagic.ent
Log:
Add missing _default:compile-resources-no-filter

Modified: projects/microcontainer/trunk/tools/etc/buildmagic/buildmagic.ent
===================================================================
--- projects/microcontainer/trunk/tools/etc/buildmagic/buildmagic.ent	2006-12-22 05:07:39 UTC (rev 59206)
+++ projects/microcontainer/trunk/tools/etc/buildmagic/buildmagic.ent	2006-12-22 06:45:49 UTC (rev 59207)
@@ -524,6 +524,14 @@
     </fileset>
   </copy>
 </target>
+<target name="_default:compile-resources-no-filter" depends="init" unless="compile.disable">
+  <mkdir dir="${build.resources}"/>
+  <copy todir="${build.resources}" filtering="no">
+    <fileset dir="${source.resources}">
+      <patternset refid="compile-resources.filter.pattern"/>
+    </fileset>
+  </copy>
+</target>
 
 <patternset id="compile-resources.filter.pattern">
   <include name="**/*"/>



From Shane_Bryzak at symantec.com  Fri Dec 22 01:53:46 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 22 Dec 2006 01:53:46 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources  ...
Message-ID: <E1GxeHq-0000vk-Rd@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/22 01:53:46

  Modified:    examples/seamspace/resources  import.sql
  Log:
  added member card
  
  Revision  Changes    Path
  1.6       +1 -1      jboss-seam/examples/seamspace/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/import.sql,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- import.sql	21 Dec 2006 13:05:01 -0000	1.5
  +++ import.sql	22 Dec 2006 06:53:46 -0000	1.6
  @@ -1,4 +1,4 @@
  -insert into Member (memberid, username, password, name) values (1, 'demo', 'demo', 'demo')
  +insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (1, 'demo', 'demo', 'Mr_Smiley', 'I smile because I care', 0, '1990-12-23', 'The moon')
   insert into MemberRole (roleid, name) values (1, 'user');
   insert into MemberRole (roleid, name) values (2, 'admin');
   
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 22 01:53:47 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 22 Dec 2006 01:53:47 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxeHr-0000vx-0B@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/22 01:53:47

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace   
                        Member.java ProfileAction.java ProfileLocal.java
  Log:
  added member card
  
  Revision  Changes    Path
  1.10      +87 -0     jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Member.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- Member.java	21 Dec 2006 13:05:01 -0000	1.9
  +++ Member.java	22 Dec 2006 06:53:46 -0000	1.10
  @@ -1,6 +1,9 @@
   package org.jboss.seam.example.seamspace;
   
   import java.io.Serializable;
  +import java.util.Calendar;
  +import java.util.Date;
  +import java.util.GregorianCalendar;
   import java.util.Set;
   
   import javax.persistence.Entity;
  @@ -12,10 +15,12 @@
   import javax.persistence.OneToMany;
   import javax.persistence.OneToOne;
   import javax.persistence.Table;
  +import javax.persistence.Transient;
   import javax.persistence.UniqueConstraint;
   
   import org.hibernate.validator.Length;
   import org.hibernate.validator.NotNull;
  +import org.hibernate.validator.Pattern;
   import org.jboss.seam.annotations.Name;
   
   /**
  @@ -30,11 +35,30 @@
   {
      private static final long serialVersionUID = 5179242727836683375L;
      
  +   public enum Gender {
  +      male("Male"), 
  +      female("Female");
  +      
  +     private String descr;
  +     Gender(String descr) {
  +       this.descr = descr;
  +      }
  +     public String getDescr() {
  +        return descr;
  +     }
  +   };
  +   
      private Integer memberId;
      private String username;
      private String password;
      private String name;
      private MemberImage picture;
  +   
  +   private String tagline;
  +   private Gender gender;
  +   private Date dob;
  +   private String location;
  +   
      private Set<MemberRole> roles;
      private Set<MemberImage> images;
   
  @@ -75,6 +99,8 @@
   
      @NotNull
      @Length(min = 3, max = 40)
  +   @Pattern(regex="[a-zA-Z]?[a-zA-Z0-9_]+", 
  +         message="Member name must start with a letter, and only contain letters, numbers or underscores")
      public String getName()
      {
         return name;
  @@ -109,6 +135,48 @@
         this.picture = picture;
      }
   
  +   @NotNull
  +   public Date getDob()
  +   {
  +      return dob;
  +   }
  +
  +   public void setDob(Date dob)
  +   {
  +      this.dob = dob;
  +   }
  +
  +   @NotNull
  +   public Gender getGender()
  +   {
  +      return gender;
  +   }
  +
  +   public void setGender(Gender gender)
  +   {
  +      this.gender = gender;
  +   }
  +
  +   public String getLocation()
  +   {
  +      return location;
  +   }
  +
  +   public void setLocation(String location)
  +   {
  +      this.location = location;
  +   }
  +
  +   public String getTagline()
  +   {
  +      return tagline;
  +   }
  +
  +   public void setTagline(String tagline)
  +   {
  +      this.tagline = tagline;
  +   }
  +
      @OneToMany(mappedBy = "member", fetch = FetchType.LAZY)
      public Set<MemberImage> getImages()
      {
  @@ -119,4 +187,23 @@
      {
         this.images = images;
      }
  +   
  +   @Transient
  +   public String getAge()
  +   {
  +      Calendar birthday = new GregorianCalendar();
  +      birthday.setTime(dob);
  +      int by = birthday.get(Calendar.YEAR);
  +      int bm = birthday.get(Calendar.MONTH);
  +      int bd = birthday.get(Calendar.DATE);
  +      
  +      Calendar now = new GregorianCalendar();
  +      now.setTimeInMillis(System.currentTimeMillis());
  +      int ny = now.get(Calendar.YEAR);
  +      int nm = now.get(Calendar.MONTH);
  +      int nd = now.get(Calendar.DATE);      
  +      
  +      int age = ny - by + (nm > bm || (nm == bm && nd >= bd) ? 0 : -1);                              
  +      return String.format("%d years old", age);                              
  +   }
   }
  
  
  
  1.5       +13 -6     jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProfileAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ProfileAction.java	22 Dec 2006 02:04:48 -0000	1.4
  +++ ProfileAction.java	22 Dec 2006 06:53:46 -0000	1.5
  @@ -1,19 +1,23 @@
   package org.jboss.seam.example.seamspace;
   
  -import javax.ejb.Stateless;
  +import javax.ejb.Remove;
  +import javax.ejb.Stateful;
   import javax.persistence.EntityManager;
   import javax.persistence.NoResultException;
   
  +import org.jboss.seam.ScopeType;
  +import org.jboss.seam.annotations.Destroy;
   import org.jboss.seam.annotations.Factory;
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Out;
   import org.jboss.seam.annotations.RequestParameter;
  -import org.jboss.seam.core.FacesMessages;
  +import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.security.Identity;
   
  - at Stateless
  + at Stateful
   @Name("profile")
  + at Scope(ScopeType.EVENT)
   public class ProfileAction implements ProfileLocal
   {
      @RequestParameter
  @@ -47,4 +51,7 @@
            catch (NoResultException ex) { }   
         }
      }
  +   
  +   @Remove @Destroy
  +   public void destroy() { }   
   }
  
  
  
  1.2       +1 -0      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileLocal.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProfileLocal.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileLocal.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ProfileLocal.java	20 Dec 2006 11:40:25 -0000	1.1
  +++ ProfileLocal.java	22 Dec 2006 06:53:46 -0000	1.2
  @@ -6,4 +6,5 @@
   public interface ProfileLocal
   {
     void display();
  +  void destroy();
   }
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 22 01:53:47 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 22 Dec 2006 01:53:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view  ...
Message-ID: <E1GxeHr-0000w4-54@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/22 01:53:47

  Modified:    examples/seamspace/view  profile.xhtml
  Log:
  added member card
  
  Revision  Changes    Path
  1.4       +31 -6     jboss-seam/examples/seamspace/view/profile.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: profile.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/profile.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- profile.xhtml	22 Dec 2006 02:50:24 -0000	1.3
  +++ profile.xhtml	22 Dec 2006 06:53:47 -0000	1.4
  @@ -7,11 +7,36 @@
     <ui:composition template="template.xhtml">
       <ui:define name="content">
         <div id="contentMain">
  -			  <h1>#{selectedMember.name}'s profile</h1>
   			
   			  <div class="errors"><h:messages globalOnly="true"/></div> 
   			  
  +        <s:div rendered="#{selectedMember != null}">
  +        
  +          <s:div id="memberCard">
  +            <h1>#{selectedMember.name}'s profile</h1>
  +                      
  +            <s:div id="memberCardPicture" rendered="#{selectedMember.picture != null}">
   			  <h:graphicImage value="/content/images?id=#{selectedMember.picture.imageId}&amp;width=170"/>
  +            </s:div>
  +            
  +            <div id="memberCardText">
  +              <span class="tagline">"#{selectedMember.tagline}"</span><br/><br/>
  +              #{selectedMember.gender.descr}<br/>
  +              #{selectedMember.age}<br/>
  +              #{selectedMember.location}<br/>
  +            </div>
  +            
  +            <br style="clear:both"/>
  +            
  +            View My: Pics | Videos
  +            
  +          </s:div>
  +          
  +        </s:div>
  +        
  +        <s:div rendered="#{selectedMember == null}">
  +          Sorry, but this member does not exist.
  +        </s:div>
   			  
         </div>
       
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 22 01:53:47 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 22 Dec 2006 01:53:47 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/view/style  ...
Message-ID: <E1GxeHr-0000wB-9a@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/22 01:53:47

  Modified:    examples/seamspace/view/style  seamspace.css
  Log:
  added member card
  
  Revision  Changes    Path
  1.6       +26 -0     jboss-seam/examples/seamspace/view/style/seamspace.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seamspace.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/view/style/seamspace.css,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- seamspace.css	20 Dec 2006 03:36:56 -0000	1.5
  +++ seamspace.css	22 Dec 2006 06:53:47 -0000	1.6
  @@ -5,6 +5,11 @@
     margin: 0;
   }
   
  +h1 {
  +  margin-top: 2px;
  +  margin-bottom: 6px;
  +}
  +
   #header {
     margin-left: auto;
     margin-right: auto;
  @@ -56,6 +61,23 @@
     margin-right: 10px;
   }
   
  +#memberCard {
  +  width: 350px;
  +  border: 2px solid #eeeeee;
  +  background-color: #f5f5f5;
  +  padding: 2px;
  +}
  +
  +#memberCardPicture {
  +  width: 170px;
  +  float: left;
  +}
  +
  +#memberCardText {
  +  width: 170px;
  +  float: right;
  +}
  +
   div.headerRight {
     float: right;
     width: 440px;
  @@ -73,6 +95,10 @@
     height: 86px;  
   }
   
  +span.tagline {
  +  font-style: italic;
  +}
  +
   a, a:visited, a:hover {
     color: #ffffff;
     text-decoration: none;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 01:57:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 01:57:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r59208 -
	projects/microcontainer/trunk/tools/etc/buildmagic
Message-ID: <E1GxeLe-00011F-3v@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-22 01:57:40 -0500 (Fri, 22 Dec 2006)
New Revision: 59208

Modified:
   projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent
Log:
Add jboss.managed.classpath

Modified: projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent
===================================================================
--- projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent	2006-12-22 06:45:49 UTC (rev 59207)
+++ projects/microcontainer/trunk/tools/etc/buildmagic/modules.ent	2006-12-22 06:57:40 UTC (rev 59208)
@@ -28,6 +28,15 @@
       <include name="jboss-dependency14.jar"/>
    </fileset>
 </path>
+<!-- managed -->
+<property name="jboss.managed.root" value="${project.root}/managed"/>
+<property name="jboss.managed.lib" value="${jboss.managed.root}/output/lib"/>
+<path id="jboss.managed.classpath">
+   <fileset dir="${jboss.managed.lib}">
+      <include name="jboss-managed.jar"/>
+   </fileset>
+</path>
+
 <!-- kernel -->
 <property name="jboss.kernel.root" value="${project.root}/kernel"/>
 <property name="jboss.kernel.lib" value="${jboss.kernel.root}/output/lib"/>



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 01:58:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 01:58:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r59209 -
	projects/microcontainer/trunk/build
Message-ID: <E1GxeM4-00011Y-PG@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-22 01:58:07 -0500 (Fri, 22 Dec 2006)
New Revision: 59209

Modified:
   projects/microcontainer/trunk/build/build.xml
Log:
Move the deployers module after the managed module

Modified: projects/microcontainer/trunk/build/build.xml
===================================================================
--- projects/microcontainer/trunk/build/build.xml	2006-12-22 06:57:40 UTC (rev 59208)
+++ projects/microcontainer/trunk/build/build.xml	2006-12-22 06:58:07 UTC (rev 59209)
@@ -78,11 +78,11 @@
       <!-- Modules -->
       <module name="container"/>
       <module name="dependency"/>
-      <module name="deployers"/>
       <module name="kernel"/>
       <module name="aop-mc-int"/>
       <module name="metatype"/>
       <module name="managed"/>
+      <module name="deployers"/>
       <module name="osgi-int"/>
 
       <!-- Module groups -->
@@ -95,7 +95,7 @@
       </group>
 
       <group name="core">
-        <include modules="container, dependency, kernel, aop-mc-int, deployers, metatype, managed, osgi-int"/>
+        <include modules="container, dependency, kernel, aop-mc-int, metatype, managed, deployers, osgi-int"/>
       </group>
 
       <group name="default">



From t2-okada at nri.co.jp  Fri Dec 22 02:04:17 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Fri, 22 Dec 2006 02:04:17 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet
	...
Message-ID: <E1GxeS1-0001Gx-JG@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/22 02:04:17

  Modified:    java/src/expansion/org/jboss/profiler/exp/view/servlet      
                        Tag: JBossProfiler_Expansion ExecutionStack.java
                        ConcurrencyMetrics.java ExecutionMetrics.java
                        MemoryMetrics.java ExecutionPassage.java
                        ExecutionPassageDetail.java
  Log:
  Corrected some bugs.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionStack.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExecutionStack.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionStack.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- ExecutionStack.java	6 Nov 2006 07:36:59 -0000	1.1.2.2
  +++ ExecutionStack.java	22 Dec 2006 07:04:17 -0000	1.1.2.3
  @@ -78,7 +78,8 @@
           // Invokes agent to get snapshot of metrics
           Object obj = ServiceManager.invokeLocal(profilerServiceName, "snapMetrics");
           if(obj==null) {
  -            logger.error("failed to snap the metrics data.");
  +            logger.info("The metrics data is null.");
  +            return;
           }
           Map metricsMap = (Map)obj;
           
  
  
  
  1.1.2.4   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ConcurrencyMetrics.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrencyMetrics.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ConcurrencyMetrics.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- ConcurrencyMetrics.java	21 Dec 2006 12:27:19 -0000	1.1.2.3
  +++ ConcurrencyMetrics.java	22 Dec 2006 07:04:17 -0000	1.1.2.4
  @@ -125,7 +125,8 @@
               obj = ServiceManager.invokeLocal(profilerServiceName, "snapMetrics");
           }
           if(obj==null) {
  -            logger.error("failed to snap the metrics data.");
  +            logger.info("The metrics data is null.");
  +            return;
           }
           Map metricsMap = (Map)obj;
           
  
  
  
  1.1.2.4   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionMetrics.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExecutionMetrics.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionMetrics.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- ExecutionMetrics.java	21 Dec 2006 12:27:19 -0000	1.1.2.3
  +++ ExecutionMetrics.java	22 Dec 2006 07:04:17 -0000	1.1.2.4
  @@ -115,7 +115,8 @@
               obj = ServiceManager.invokeLocal(profilerServiceName, "snapMetrics");
           }
           if(obj==null) {
  -            logger.error("failed to snap the metrics data.");
  +            logger.info("The metrics data is null.");
  +            return;
           }
           Map metricsMap = (Map)obj;
           
  
  
  
  1.1.2.4   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/MemoryMetrics.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MemoryMetrics.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/MemoryMetrics.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- MemoryMetrics.java	21 Dec 2006 12:27:19 -0000	1.1.2.3
  +++ MemoryMetrics.java	22 Dec 2006 07:04:17 -0000	1.1.2.4
  @@ -108,7 +108,8 @@
               obj = ServiceManager.invokeLocal(profilerServiceName, "snapMetrics");
           }
           if(obj==null) {
  -            logger.error("failed to snap the metrics data.");
  +            logger.info("The metrics data is null.");
  +            return;
           }
           Map metricsMap = (Map)obj;
           
  
  
  
  1.1.2.3   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionPassage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExecutionPassage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionPassage.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- ExecutionPassage.java	6 Nov 2006 07:36:59 -0000	1.1.2.2
  +++ ExecutionPassage.java	22 Dec 2006 07:04:17 -0000	1.1.2.3
  @@ -78,7 +78,8 @@
           // Invokes agent to get snapshot of metrics
           Object obj = ServiceManager.invokeLocal(profilerServiceName, "snapMetrics");
           if(obj==null) {
  -            logger.error("failed to snap the metrics data.");
  +            logger.info("The metrics data is null.");
  +            return;
           }
           Map metricsMap = (Map)obj;
           
  
  
  
  1.1.2.4   +2 -1      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionPassageDetail.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExecutionPassageDetail.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/view/servlet/Attic/ExecutionPassageDetail.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- ExecutionPassageDetail.java	13 Nov 2006 07:11:39 -0000	1.1.2.3
  +++ ExecutionPassageDetail.java	22 Dec 2006 07:04:17 -0000	1.1.2.4
  @@ -127,7 +127,8 @@
               obj = ServiceManager.invokeLocal(profilerServiceName, "snapMetrics");
           }
           if(obj==null) {
  -            logger.error("failed to snap the metrics data.");
  +            logger.info("The metrics data is null.");
  +            return;
           }
           Map metricsMap = (Map)obj;
           
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 22 02:21:01 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 22 Dec 2006 02:21:01 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources  ...
Message-ID: <E1GxeiD-0001Yc-Do@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/22 02:21:01

  Modified:    examples/seamspace/resources  import.sql
  Log:
  it wouldn't be a real demo without duke, plus fixed jpeg scaling bug
  
  Revision  Changes    Path
  1.7       +7 -2      jboss-seam/examples/seamspace/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/import.sql,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- import.sql	22 Dec 2006 06:53:46 -0000	1.6
  +++ import.sql	22 Dec 2006 07:21:01 -0000	1.7
  @@ -1,4 +1,6 @@
  -insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (1, 'demo', 'demo', 'Mr_Smiley', 'I smile because I care', 0, '1990-12-23', 'The moon')
  +insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (1, 'demo', 'demo', 'Mr_Smiley', 'I smile because I care', 0, '1953-03-10', 'The moon')
  +insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (2, 'duke', 'duke', 'duke', 'I love the smell of coffee', 0, '1995-01-01', 'Sun Microsystems')
  +
   insert into MemberRole (roleid, name) values (1, 'user');
   insert into MemberRole (roleid, name) values (2, 'admin');
   
  @@ -7,4 +9,7 @@
   
   insert into MemberImage (imageid, member_id, contentType, data) values (1, 1, 'image/png', ' !
  !
 4EA7032FA66A6B97A9B4D63AB676C6B9DE56EF73CEFB2679134001BDF37DF380D4F90D
 !
  !
 803C78E746CDAC041114A8E40C181887BA3B20743C56AE50A1B5829600448AF9153934
 !
  !
 855C072AB01A507005B54E5F166E1C3A6AA1A6C5501E02995F04E9B4B7F3FC00A8B0F8
 !
  !
 733C45C81EA1D66EF1F9F1CEBFFDF8FA1A47AD1C74A9BF951ACB4490A359F60B3972C2
 !
  !
 7F5D5C7FA1A767CD9A81B627703A752695EB6C731FDB7C4A0F3D7FB1AC41F7BC9DD592
 !
  !
 ED6DCD0FBDBAAD06E00CBAD3EC858BB3DFC6711FB680995DCF453F5DBEFA7D5540E509
 !
  !
 7FDFC183B3A8ED16FFF795CA77FAA1F29D510720E5D09C1F82D47B58A757F26EA5E5E6
 !
  !
 B6DBBBA16FF8FDF57A974073ED7E75C5EBDA2780516A1935ED1618F4D9B4220526DDA5
 !
  !
 C3A850553534404A6DC8D1EBB43F8EDBD5D76719D00E502C85E0307E668ADFD7656935
 !
  !
 65B73039CF3BF959647911E4581EA5B0C5A04A914652844EAE5355AC11CC2137C43453
 !
  ');
   
  +insert into MemberImage (imageid, member_id, contentType, data) values (2, 2, 'image/jpeg', ' !
  !
 AA19EB28B0A794A6C451010101049BE5F35E7E92E615AB2E64E1C566786C6F6A68D6B9
 !
  !
 BD6DCC1CAE5ADE392E05DCE63C7C31B5D23FE1E11C1106B5A09DAC6F16C1D28D30B94D
 !
  !
 AB744E54D966ED1F692827C0B96F7A0980F7A293D970ECDE3A4239B46FBEAB77527B6C
 !
  !
 DA8D265FFF00531FFA23BFE47F31F7BFC6FEEFFEDFEDA2611F7999E5DCDA7359FEA3B2
 !
  !
 FB3FE23FF0050889C751E96D3FA9718FC6676C62BFB27ED314A3711B9CC70A398EED69
 !
  !
 7B46D415679D1E5C6E74E43367F49364BCC2B2AFBBC71AC93DB346D2F611B6489BD3EF
 ');
  +
   update Member set picture_id = 1 where memberid = 1;
  \ No newline at end of file
  +update Member set picture_id = 2 where memberid = 2;
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Fri Dec 22 02:21:01 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Fri, 22 Dec 2006 02:21:01 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1GxeiD-0001Yj-Ht@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/22 02:21:01

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace 
                        ContentServlet.java
  Log:
  it wouldn't be a real demo without duke, plus fixed jpeg scaling bug
  
  Revision  Changes    Path
  1.5       +6 -4      jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ContentServlet.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ContentServlet.java	22 Dec 2006 02:50:24 -0000	1.4
  +++ ContentServlet.java	22 Dec 2006 07:21:01 -0000	1.5
  @@ -63,19 +63,21 @@
               {
                  double ratio = (double) width / icon.getIconWidth();
                  int height = (int) (icon.getIconHeight() * ratio);
  -               BufferedImage bImg = new BufferedImage(width, height,
  -                     BufferedImage.TYPE_INT_ARGB);
  +               
  +               int imageType = "image/png".equals(mi.getContentType()) ? 
  +                     BufferedImage.TYPE_INT_ARGB : BufferedImage.TYPE_INT_RGB;                  
  +               BufferedImage bImg = new BufferedImage(width, height, imageType);
                  Graphics2D g2d = bImg.createGraphics();
                  g2d.setRenderingHint(RenderingHints.KEY_INTERPOLATION,
                        RenderingHints.VALUE_INTERPOLATION_BICUBIC);
                  g2d.drawImage(icon.getImage(), 0, 0, width, height, null);
                  g2d.dispose();
  -               String formatName = "";
   
  +               String formatName = "";
                  if ("image/png".equals(mi.getContentType()))
                     formatName = "png";
                  else if ("image/jpeg".equals(mi.getContentType()))
  -                  formatName = "jpg";
  +                  formatName = "jpeg";
   
                  ImageIO.write(bImg, formatName, response.getOutputStream());
               }
  
  
  


From mazz at jboss.com  Fri Dec 22 02:51:06 2006
From: mazz at jboss.com (John Mazzitelli)
Date: Fri, 22 Dec 2006 02:51:06 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9 - New
	directory ...
Message-ID: <E1GxfBK-000213-WF@committer01.frg.pub.inap.atl.jboss.com>

  User: jmazzitelli
  Date: 06/12/22 02:51:06

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9 added to the repository


From mazz at jboss.com  Fri Dec 22 02:52:13 2006
From: mazz at jboss.com (John Mazzitelli)
Date: Fri, 22 Dec 2006 02:52:13 -0500
Subject: [jboss-cvs] repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9 ...
Message-ID: <E1GxfCP-00022x-KZ@committer01.frg.pub.inap.atl.jboss.com>

  User: jmazzitelli
  Date: 06/12/22 02:52:13

  Added:       maven2/i18nlog/i18nlog/1.0.9       i18nlog-1.0.9.jar
                        i18nlog-1.0.9.jar.md5 i18nlog-1.0.9.jar.sha1
                        i18nlog-1.0.9.pom i18nlog-1.0.9.pom.md5
                        i18nlog-1.0.9.pom.sha1
  Log:
  add <i18n-msg> ant task so ant scripts can obtain i18n messages and either echo them or store them in properties.  jon will be able to use this to internationalize its installer
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 07:52:13;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/22 07:52:13;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.jar.md5
  
  Index: i18nlog-1.0.9.jar.md5
  ===================================================================
  0dbc127066b49ad9b6fb85c136b2afd7
  
  
  1.1      date: 2006/12/22 07:52:13;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.jar.sha1
  
  Index: i18nlog-1.0.9.jar.sha1
  ===================================================================
  973a1aa5829c51f46f9b999eb904cd57e234bdc4
  
  
  1.1      date: 2006/12/22 07:52:13;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.pom
  
  Index: i18nlog-1.0.9.pom
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?><project>
    <modelVersion>4.0.0</modelVersion>
    <groupId>i18nlog</groupId>
    <artifactId>i18nlog</artifactId>
    <version>1.0.9</version>
    <distributionManagement>
      <status>deployed</status>
    </distributionManagement>
  </project>
  
  
  1.1      date: 2006/12/22 07:52:13;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.pom.md5
  
  Index: i18nlog-1.0.9.pom.md5
  ===================================================================
  c074f8bcaa8deae8c7d9a96539f7db0c
  
  
  1.1      date: 2006/12/22 07:52:13;  author: jmazzitelli;  state: Exp;repository.jboss.com/maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.pom.sha1
  
  Index: i18nlog-1.0.9.pom.sha1
  ===================================================================
  bfd79d2e3674a3a245d9b5b512529c2d0b351de8
  
  


From t2-okada at nri.co.jp  Fri Dec 22 03:38:49 2006
From: t2-okada at nri.co.jp (Takuro Okada)
Date: Fri, 22 Dec 2006 03:38:49 -0500
Subject: [jboss-cvs]
	jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent ...
Message-ID: <E1GxfvV-0002tZ-5u@committer01.frg.pub.inap.atl.jboss.com>

  User: tokada  
  Date: 06/12/22 03:38:49

  Modified:    java/src/expansion/org/jboss/profiler/exp/agent  Tag:
                        JBossProfiler_Expansion
                        DefaultProfilerServiceMBean.java
  Log:
  Added an interface.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.5   +5 -0      jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/Attic/DefaultProfilerServiceMBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultProfilerServiceMBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-profiler/java/src/expansion/org/jboss/profiler/exp/agent/Attic/DefaultProfilerServiceMBean.java,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -b -r1.1.2.4 -r1.1.2.5
  --- DefaultProfilerServiceMBean.java	6 Nov 2006 10:46:09 -0000	1.1.2.4
  +++ DefaultProfilerServiceMBean.java	22 Dec 2006 08:38:49 -0000	1.1.2.5
  @@ -89,4 +89,9 @@
        */
       MetricsMap snapMetrics(String metricClassName, String[] metricNames, Long fromDate, Long toDate);
   
  +    /**
  +     * Resets the metrics data.
  +     */
  +    void resetMetrics();
  +
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 04:42:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 04:42:00 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1846 - in trunk/tests: .
	src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	src/org/jboss/test/messaging/jms/server/destination
Message-ID: <E1Gxgue-0004Al-T1@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-22 04:41:56 -0500 (Fri, 22 Dec 2006)
New Revision: 1846

Modified:
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java
Log:
A couple of tweaks



Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-22 00:34:08 UTC (rev 1845)
+++ trunk/tests/build.xml	2006-12-22 09:41:56 UTC (rev 1846)
@@ -816,10 +816,7 @@
             <formatter classname="org.jboss.test.messaging.tools.ant.JUnitTestSuiteListener"/>
 
             <fileset dir="${build.tests.classes}">
-               <!--
-                   <include name="**/jms/clustering/FailoverTest.class"/>
-               -->
-               <include name="**/jms/clustering/HATest.class"/>
+               <include name="**/jms/clustering/*Test.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-22 00:34:08 UTC (rev 1845)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-22 09:41:56 UTC (rev 1846)
@@ -735,7 +735,7 @@
          routed = office1.route(ref3, new SimpleCondition("topic1"), null);      
          assertTrue(routed);
          
-         Thread.sleep(1000);
+         Thread.sleep(2000);
          
          List msgs = receiver1.getMessages();
          assertNotNull(msgs);

Modified: trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java	2006-12-22 00:34:08 UTC (rev 1845)
+++ trunk/tests/src/org/jboss/test/messaging/jms/server/destination/QueueManagementTest.java	2006-12-22 09:41:56 UTC (rev 1846)
@@ -420,6 +420,9 @@
 
          cons.receive();
          conn.close();
+         
+         //Cancel is asynch
+         Thread.sleep(500);
 
          // Test MessageCount again, should be 0 msg
          list = (List)ServerManagement.invoke(



From dimitris.andreadis at jboss.com  Fri Dec 22 04:43:03 2006
From: dimitris.andreadis at jboss.com (Dimitris Andreadis)
Date: Fri, 22 Dec 2006 04:43:03 -0500
Subject: [jboss-cvs] repository.jboss.com/apache-httpclient/3.0.1  ...
Message-ID: <E1Gxgvf-0004BR-47@committer01.frg.pub.inap.atl.jboss.com>

  User: dimitris
  Date: 06/12/22 04:43:03

  Modified:    apache-httpclient/3.0.1  component-info.xml
  Log:
  apache-httpclient depends on apache-codec.
  
  Revision  Changes    Path
  1.2       +6 -0      repository.jboss.com/apache-httpclient/3.0.1/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/apache-httpclient/3.0.1/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	23 Jun 2006 17:31:36 -0000	1.1
  +++ component-info.xml	22 Dec 2006 09:43:03 -0000	1.2
  @@ -4,7 +4,13 @@
                 version="3.0.1"
                 projectHome="http://jakarta.apache.org/commons/httpclient/"
                 description="Implementation of client side of the most recent HTTP standards">
  +
         <artifact id="commons-httpclient.jar"/>
  +
  +      <import componentref="apache-codec">
  +      	<compatible version="1.3.0"/>
  +      </import>
  +
         <export>
            <include input="commons-httpclient.jar"/>
         </export>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 05:23:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 05:23:31 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1847 - in trunk: .
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/messaging/core
Message-ID: <E1GxhYp-00050j-Jz@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-22 05:23:27 -0500 (Fri, 22 Dec 2006)
New Revision: 1847

Modified:
   trunk/build-thirdparty.xml
   trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
Log:
Minor tweaks + upgrade JGroups dependency to 2.4.1



Modified: trunk/build-thirdparty.xml
===================================================================
--- trunk/build-thirdparty.xml	2006-12-22 09:41:56 UTC (rev 1846)
+++ trunk/build-thirdparty.xml	2006-12-22 10:23:27 UTC (rev 1847)
@@ -85,7 +85,7 @@
       <componentref name="oswego-concurrent" version="1.3.4"/>
       <componentref name="apache-log4j" version="1.2.8"/>
       <componentref name="javassist" version="3.2.0.GA"/>
-      <componentref name="jgroups" version="2.4"/>
+      <componentref name="jgroups" version="2.4.1"/>
       <componentref name="trove" version="1.0.2"/>
       <componentref name="jboss/common-core" version="2.0.2.GA"/>
       <componentref name="jboss/common-logging-log4j" version="2.0.2.GA"/>

Modified: trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java	2006-12-22 09:41:56 UTC (rev 1846)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java	2006-12-22 10:23:27 UTC (rev 1847)
@@ -27,6 +27,10 @@
  * A Cancel.
  * 
  * Used to send a cancel (NACK) to the server
+ * 
+ * When we cancel we send delivery count info, this means delivery count
+ * can be updated on the server, and into storage if persistent, and the
+ * message can be sent to DLQ if appropriate
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision: 1.1 $</tt>

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-22 09:41:56 UTC (rev 1846)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-22 10:23:27 UTC (rev 1847)
@@ -592,7 +592,7 @@
 
          while (true)
          {           
-            synchronized (deliveryLock)
+            synchronized (refLock)
             {
                ref = nextReference(iter);               
             }



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 05:24:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 05:24:16 -0500
Subject: [jboss-cvs] JBossAS SVN: r59210 - in
	branches/Branch_4_2/ejb3/src/resources: META-INF
	test-configs/ejb3-ssl/deploy/ejb3.deployer/META-INF
	test-configs/ejb3-ssl-advanced/deploy/ejb3.deployer/META-INF
	test-configs/invoker/deploy/ejb3.deployer/META-INF
Message-ID: <E1GxhZY-000512-6H@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-22 05:23:57 -0500 (Fri, 22 Dec 2006)
New Revision: 59210

Modified:
   branches/Branch_4_2/ejb3/src/resources/META-INF/jboss-service.xml
   branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl-advanced/deploy/ejb3.deployer/META-INF/jboss-service.xml
   branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl/deploy/ejb3.deployer/META-INF/jboss-service.xml
   branches/Branch_4_2/ejb3/src/resources/test-configs/invoker/deploy/ejb3.deployer/META-INF/jboss-service.xml
Log:
Remove the version number from commons-codec.jar in the org.jboss.ejb3.JarsIgnoredForScanning IgnoredJars list

Modified: branches/Branch_4_2/ejb3/src/resources/META-INF/jboss-service.xml
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/META-INF/jboss-service.xml	2006-12-22 06:58:07 UTC (rev 59209)
+++ branches/Branch_4_2/ejb3/src/resources/META-INF/jboss-service.xml	2006-12-22 10:23:57 UTC (rev 59210)
@@ -64,7 +64,7 @@
          commons-beanutils.jar,
          jboss-ejb3.jar,
          dom4j.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          wsdl4j.jar,
          xmlsec.jar,
          jbossws.jar,
@@ -80,7 +80,7 @@
          myfaces-impl.jar,
          commons-beanutils.jar,
          myfaces-jsf-api.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          catalina-optional.jar,
          tomcat-util.jar,
          jasper-compiler.jar,

Modified: branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl/deploy/ejb3.deployer/META-INF/jboss-service.xml
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl/deploy/ejb3.deployer/META-INF/jboss-service.xml	2006-12-22 06:58:07 UTC (rev 59209)
+++ branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl/deploy/ejb3.deployer/META-INF/jboss-service.xml	2006-12-22 10:23:57 UTC (rev 59210)
@@ -59,7 +59,7 @@
          commons-beanutils.jar,
          jboss-ejb3.jar,
          dom4j.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          wsdl4j.jar,
          xmlsec.jar,
          jbossws.jar,
@@ -75,7 +75,7 @@
          myfaces-impl.jar,
          commons-beanutils.jar,
          myfaces-jsf-api.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          catalina-optional.jar,
          tomcat-util.jar,
          jasper-compiler.jar,

Modified: branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl-advanced/deploy/ejb3.deployer/META-INF/jboss-service.xml
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl-advanced/deploy/ejb3.deployer/META-INF/jboss-service.xml	2006-12-22 06:58:07 UTC (rev 59209)
+++ branches/Branch_4_2/ejb3/src/resources/test-configs/ejb3-ssl-advanced/deploy/ejb3.deployer/META-INF/jboss-service.xml	2006-12-22 10:23:57 UTC (rev 59210)
@@ -59,7 +59,7 @@
          commons-beanutils.jar,
          jboss-ejb3.jar,
          dom4j.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          wsdl4j.jar,
          xmlsec.jar,
          jbossws.jar,
@@ -75,7 +75,7 @@
          myfaces-impl.jar,
          commons-beanutils.jar,
          myfaces-jsf-api.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          catalina-optional.jar,
          tomcat-util.jar,
          jasper-compiler.jar,

Modified: branches/Branch_4_2/ejb3/src/resources/test-configs/invoker/deploy/ejb3.deployer/META-INF/jboss-service.xml
===================================================================
--- branches/Branch_4_2/ejb3/src/resources/test-configs/invoker/deploy/ejb3.deployer/META-INF/jboss-service.xml	2006-12-22 06:58:07 UTC (rev 59209)
+++ branches/Branch_4_2/ejb3/src/resources/test-configs/invoker/deploy/ejb3.deployer/META-INF/jboss-service.xml	2006-12-22 10:23:57 UTC (rev 59210)
@@ -64,7 +64,7 @@
          commons-beanutils.jar,
          jboss-ejb3.jar,
          dom4j.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          wsdl4j.jar,
          xmlsec.jar,
          jbossws.jar,
@@ -80,7 +80,7 @@
          myfaces-impl.jar,
          commons-beanutils.jar,
          myfaces-jsf-api.jar,
-         commons-codec-1.2.jar,
+         commons-codec.jar,
          catalina-optional.jar,
          tomcat-util.jar,
          jasper-compiler.jar,



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 06:00:14 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 06:00:14 -0500
Subject: [jboss-cvs] JBossAS SVN: r59211 -
	branches/Branch_4_2/system/src/main/org/jboss/system/server
Message-ID: <E1Gxi8M-0005c5-A2@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-22 06:00:11 -0500 (Fri, 22 Dec 2006)
New Revision: 59211

Modified:
   branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerLoader.java
Log:
JBAS-3955, commons-httpclient 3.0.1 needs commons-codec 1.3.0

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerLoader.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerLoader.java	2006-12-22 10:23:57 UTC (rev 59210)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerLoader.java	2006-12-22 11:00:11 UTC (rev 59211)
@@ -132,6 +132,7 @@
       {
          this.addLibrary("webdavlib.jar");
          this.addLibrary("commons-httpclient.jar");
+         this.addLibrary("commons-codec.jar");
          this.addLibrary("commons-logging.jar");
       }
    }



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 06:01:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 06:01:08 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59212 - branches/Branch_4_2/tomcat
Message-ID: <E1Gxi9E-0005dO-MU@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-22 06:01:05 -0500 (Fri, 22 Dec 2006)
New Revision: 59212

Modified:
   branches/Branch_4_2/tomcat/build.xml
Log:
JBAS-3955, commons-codec moves to server/xxx/lib as a dependency of commons-httpclient

Modified: branches/Branch_4_2/tomcat/build.xml
===================================================================
--- branches/Branch_4_2/tomcat/build.xml	2006-12-22 11:00:11 UTC (rev 59211)
+++ branches/Branch_4_2/tomcat/build.xml	2006-12-22 11:01:05 UTC (rev 59212)
@@ -243,8 +243,6 @@
      <copy todir="${build.deploy}/jbossweb-tomcat55.sar/jsf-libs"
         file="${apache.collections.lib}/commons-collections.jar" />
      <copy todir="${build.deploy}/jbossweb-tomcat55.sar/jsf-libs"
-        file="${apache.codec.lib}/commons-codec.jar" />
-     <copy todir="${build.deploy}/jbossweb-tomcat55.sar/jsf-libs"
         file="${apache.beanutils.lib}/commons-beanutils.jar" />
      <copy todir="${build.deploy}/jbossweb-tomcat55.sar/jsf-libs"
         file="${apache.digester.lib}/commons-digester-1.6.jar" />



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 06:01:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 06:01:37 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59213 - branches/Branch_4_2/build
Message-ID: <E1Gxi9h-0005ea-K2@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-22 06:01:34 -0500 (Fri, 22 Dec 2006)
New Revision: 59213

Modified:
   branches/Branch_4_2/build/build-distr.xml
   branches/Branch_4_2/build/build.xml
Log:
JBAS-3955, commons-codec moves to server/xxx/lib as a dependency of commons-httpclient

Modified: branches/Branch_4_2/build/build-distr.xml
===================================================================
--- branches/Branch_4_2/build/build-distr.xml	2006-12-22 11:01:05 UTC (rev 59212)
+++ branches/Branch_4_2/build/build-distr.xml	2006-12-22 11:01:34 UTC (rev 59213)
@@ -1374,6 +1374,9 @@
       <fileset dir="${apache.httpclient.lib}">
         <include name="commons-httpclient.jar"/>
       </fileset>
+      <fileset dir="${apache.codec.lib}">
+        <include name="commons-codec.jar"/>
+      </fileset>
       <fileset dir="${apache.logging.lib}">
         <include name="commons-logging.jar"/>
       </fileset>
@@ -1422,9 +1425,12 @@
       <fileset dir="${sun.javamail.lib}">
         <include name="mail.jar"/>
       </fileset>
-       <fileset dir="${apache.httpclient.lib}">
-         <include name="commons-httpclient.jar"/>
-       </fileset>
+      <fileset dir="${apache.httpclient.lib}">
+        <include name="commons-httpclient.jar"/>
+      </fileset>
+      <fileset dir="${apache.codec.lib}">
+        <include name="commons-codec.jar"/>
+      </fileset>
       <fileset dir="${jboss.common.lib}">
         <include name="jboss-common-client.jar"/>
         <include name="namespace.jar"/>
@@ -1447,38 +1453,40 @@
 
     <!-- copy thirdparty items to install/all/lib -->
     <mkdir dir="${install.all.lib}"/>
-      <copy todir="${install.all.lib}" filtering="no">
-        <fileset dir="${jboss.remoting.lib}">
-          <include name="jboss-remoting.jar"/>
-        </fileset>
-        <fileset dir="${jboss.serialization.lib}">
-          <include name="jboss-serialization.jar"/>
-        </fileset>
-        <fileset dir="${jboss.cache.lib}">
-          <include name="jboss-cache.jar"/>
-        </fileset>
-        <fileset dir="${javassist.javassist.lib}">
-          <include name="javassist.jar"/>
-        </fileset>
-        <fileset dir="${jboss.jbossretro.rt.lib}">
-          <include name="jbossretro-rt.jar"/>
-        </fileset>
+    <copy todir="${install.all.lib}" filtering="no">
+      <fileset dir="${jboss.remoting.lib}">
+        <include name="jboss-remoting.jar"/>
+      </fileset>
+      <fileset dir="${jboss.serialization.lib}">
+        <include name="jboss-serialization.jar"/>
+      </fileset>
+      <fileset dir="${jboss.cache.lib}">
+        <include name="jboss-cache.jar"/>
+      </fileset>
+      <fileset dir="${javassist.javassist.lib}">
+        <include name="javassist.jar"/>
+      </fileset>
+      <fileset dir="${jboss.jbossretro.rt.lib}">
+        <include name="jbossretro-rt.jar"/>
+      </fileset>
       <fileset dir="${jboss.jbossws14.lib}">
         <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-saaj.jar"/>
       </fileset>
-        <fileset dir="${jboss.backport.concurrent.lib}">
-          <include name="jboss-backport-concurrent.jar"/>
-        </fileset>
-        <fileset dir="${apache.httpclient.lib}">
-          <include name="commons-httpclient.jar"/>
-        </fileset>
-        <fileset dir="${apache.logging.lib}">
-          <include name="commons-logging.jar"/>
+      <fileset dir="${jboss.backport.concurrent.lib}">
+        <include name="jboss-backport-concurrent.jar"/>
       </fileset>
+      <fileset dir="${apache.httpclient.lib}">
+        <include name="commons-httpclient.jar"/>
+      </fileset>
+      <fileset dir="${apache.codec.lib}">
+        <include name="commons-codec.jar"/>
+      </fileset>
+      <fileset dir="${apache.logging.lib}">
+        <include name="commons-logging.jar"/>
+      </fileset>
       <!-- Here for backward compatibility in case clients directly
-      use cglib (seam for example).
-      -->
+           use cglib (seam for example). -->
       <fileset dir="${cglib.lib}">
         <include name="cglib.jar"/>
       </fileset>

Modified: branches/Branch_4_2/build/build.xml
===================================================================
--- branches/Branch_4_2/build/build.xml	2006-12-22 11:01:05 UTC (rev 59212)
+++ branches/Branch_4_2/build/build.xml	2006-12-22 11:01:34 UTC (rev 59213)
@@ -712,6 +712,7 @@
       <srcfiles dir="${install.client}">
         <include name="*-client.jar"/>
         <include name="commons-httpclient.jar"/>
+        <include name="commons-codec.jar"/>
         <include name="concurrent.jar"/>
         <include name="hibernate-annotations.jar"/>
         <include name="jboss-deployment.jar" />
@@ -744,6 +745,7 @@
       <fileset dir="${install.client}">
         <include name="*-client.jar"/>
         <include name="commons-httpclient.jar"/>
+        <include name="commons-codec.jar"/>
         <include name="concurrent.jar"/>
         <include name="hibernate-annotations.jar"/>
         <include name="jboss-deployment.jar" />



From validimir.ralev at jboss.com  Fri Dec 22 07:53:04 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 07:53:04 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1 -
	New directory ...
Message-ID: <E1GxjtY-0007oo-KH@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 07:53:04

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1 added to the repository


From validimir.ralev at jboss.com  Fri Dec 22 07:54:54 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 07:54:54 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/lib
	- New directory ...
Message-ID: <E1GxjvK-0007pH-Aq@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 07:54:54

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/lib added to the repository


From validimir.ralev at jboss.com  Fri Dec 22 07:55:03 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 07:55:03 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/resources
	- New directory ...
Message-ID: <E1GxjvT-0007pu-AC@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 07:55:03

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/resources added to the repository


From fdheru98342 at fastermail.com  Fri Dec 22 07:58:24 2006
From: fdheru98342 at fastermail.com (fdheru98342 at fastermail.com)
Date: Fri, 22 Dec 2006 07:58:24 -0500
Subject: [jboss-cvs] =?utf-8?b?wo3CocKTw7rCgsOMwpbDqcKPwq3CgsK1woLCvsKC?=
	=?utf-8?b?wq/CjsKEwoLDicKOwp7CisOUwoLDsMKCwq3CgsOqwoLDnMKCwrnCgsOx?=
	=?utf-8?b?woLCqcKBSA==?=
Message-ID: 20061222222832.98606mail@mail.buiuyejsjshsisysatysajsajmvndjsdhskjdh.com

?U?????q???????????X?g???X?????????????????????????B
???????o???????????????????????c?B
?????????????????????????????????????????H
?y???????b???????????????A?????????????????????????????????????B
?????????x?????????C???????c?B
?????????????????????????A???????????????H
http://allfreefree.hitodumadeai.jp.ksjer.com/toa/





From validimir.ralev at jboss.com  Fri Dec 22 08:09:50 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:09:50 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1 ...
Message-ID: <E1Gxk9m-0008HY-Kc@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:09:50

  Added:       repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1  
                        .project component-info.xml
  Log:
  portal 2.4.1.GA SP1
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 13:09:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/.project
  
  Index: .project
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <projectDescription>
  	<name>jboss-portal-2.4.1.GA-SP1</name>
  	<comment></comment>
  	<projects>
  	</projects>
  	<buildSpec>
  	</buildSpec>
  	<natures>
  	</natures>
  </projectDescription>
  
  
  
  1.1      date: 2006/12/22 13:09:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-portal-component-info">
  
     <!-- The component id is the repository path -->
     <!-- The license type for which there must be an *.txt in repository.jboss.com/licenses -->
     <!-- The version of the component -->
     <!-- The component home/info page -->
     <!-- A short description of the component -->
     <component id="jboss-portal"
                licenseType="lgpl"
                version="2.4.1.GA-SP1"
                projectHome="http://labs.jboss.com/portal/jbossportal/"
                description="JBoss Portal">
  
        <!-- Artifacts produced by this component -->
        <artifact id="jboss-portal.sar"/>
        <artifact id="portal-hsqldb-ds.xml"/>
        <!-- The artifacts exported by this component -->
        <export>
           <include input="jboss-portal.sar"/>
        </export>
     </component>
  </project>
  
  


From validimir.ralev at jboss.com  Fri Dec 22 08:09:50 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:09:50 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/lib ...
Message-ID: <E1Gxk9m-0008He-SL@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:09:50

  Added:       repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/lib 
                        jboss-portal.sar
  Log:
  portal 2.4.1.GA SP1
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 13:09:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/lib/jboss-portal.sar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Fri Dec 22 08:09:50 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:09:50 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/resources
	...
Message-ID: <E1Gxk9m-0008Hl-Vy@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:09:50

  Added:       repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/resources 
                        portal-hsqldb-ds.xml
  Log:
  portal 2.4.1.GA SP1
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 13:09:50;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml
  
  Index: portal-hsqldb-ds.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ~ JBoss, a division of Red Hat                                              ~
    ~ Copyright 2006, Red Hat Middleware, LLC, and individual                   ~
    ~ contributors as indicated by the @authors tag. See the                    ~
    ~ copyright.txt 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.                  ~
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
  
  <datasources>
    <local-tx-datasource>
      <jndi-name>PortalDS</jndi-name>
      <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}portal${/}hypersonic${/}database</connection-url>
      <driver-class>org.hsqldb.jdbcDriver</driver-class>
      <user-name>sa</user-name>
      <password><![CDATA[]]></password>
    </local-tx-datasource>
  </datasources>
  
  
  


From validimir.ralev at jboss.com  Fri Dec 22 08:16:32 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:16:32 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1 - New
	directory ...
Message-ID: <E1GxkGG-0008Q3-0k@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:16:32

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss-portal/2.4.1.GA-SP1 added to the repository


From validimir.ralev at jboss.com  Fri Dec 22 08:17:02 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:17:02 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib - New
	directory ...
Message-ID: <E1GxkGk-0008RX-6O@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:17:02

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib added to the repository


From validimir.ralev at jboss.com  Fri Dec 22 08:17:09 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:17:09 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources
	- New directory ...
Message-ID: <E1GxkGr-0008S3-Di@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:17:09

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources added to the repository


From validimir.ralev at jboss.com  Fri Dec 22 08:32:53 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:32:53 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1   ...
Message-ID: <E1GxkW5-0000IL-Pw@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:32:53

  Added:       repository.jboss.com/jboss-portal/2.4.1.GA-SP1   .project
                        component-info.xml
  Log:
  2.4.1.GA-SP1 with correct name
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 13:32:53;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/2.4.1.GA-SP1/.project
  
  Index: .project
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <projectDescription>
  	<name>jboss-portal-2.4.1.GA-SP1</name>
  	<comment></comment>
  	<projects>
  	</projects>
  	<buildSpec>
  	</buildSpec>
  	<natures>
  	</natures>
  </projectDescription>
  
  
  
  1.1      date: 2006/12/22 13:32:53;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/2.4.1.GA-SP1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-portal-component-info">
  
     <!-- The component id is the repository path -->
     <!-- The license type for which there must be an *.txt in repository.jboss.com/licenses -->
     <!-- The version of the component -->
     <!-- The component home/info page -->
     <!-- A short description of the component -->
     <component id="jboss-portal"
                licenseType="lgpl"
                version="2.4.1.GA-SP1"
                projectHome="http://labs.jboss.com/portal/jbossportal/"
                description="JBoss Portal">
  
        <!-- Artifacts produced by this component -->
        <artifact id="jboss-portal.sar"/>
        <artifact id="portal-hsqldb-ds.xml"/>
        <!-- The artifacts exported by this component -->
        <export>
           <include input="jboss-portal.sar"/>
        </export>
     </component>
  </project>
  
  


From validimir.ralev at jboss.com  Fri Dec 22 08:32:54 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:32:54 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib  ...
Message-ID: <E1GxkW6-0000IR-1B@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:32:54

  Added:       repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib 
                        jboss-portal.sar
  Log:
  2.4.1.GA-SP1 with correct name
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 13:32:53;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib/jboss-portal.sar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Fri Dec 22 08:32:54 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 08:32:54 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources
	...
Message-ID: <E1GxkW6-0000IY-4A@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 08:32:54

  Added:       repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources 
                        portal-hsqldb-ds.xml
  Log:
  2.4.1.GA-SP1 with correct name
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 13:32:54;  author: vralev;  state: Exp;/repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml
  
  Index: portal-hsqldb-ds.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!--~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    ~ JBoss, a division of Red Hat                                              ~
    ~ Copyright 2006, Red Hat Middleware, LLC, and individual                   ~
    ~ contributors as indicated by the @authors tag. See the                    ~
    ~ copyright.txt 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.                  ~
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~-->
  
  <datasources>
    <local-tx-datasource>
      <jndi-name>PortalDS</jndi-name>
      <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}portal${/}hypersonic${/}database</connection-url>
      <driver-class>org.hsqldb.jdbcDriver</driver-class>
      <user-name>sa</user-name>
      <password><![CDATA[]]></password>
    </local-tx-datasource>
  </datasources>
  
  
  


From validimir.ralev at jboss.com  Fri Dec 22 09:47:52 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 09:47:52 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources
	...
Message-ID: <E1Gxlge-0001l9-Qz@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 09:47:52

  Removed:     repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources 
                        portal-hsqldb-ds.xml
  Log:
  delete (doesn't work)


From validimir.ralev at jboss.com  Fri Dec 22 09:47:52 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 09:47:52 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1  ...
Message-ID: <E1Gxlge-0001l1-2N@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 09:47:52

  Removed:     repository.jboss.com/jboss-portal/2.4.1.GA-SP1 
                        component-info.xml
  Log:
  delete (doesn't work)


From validimir.ralev at jboss.com  Fri Dec 22 09:47:52 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 09:47:52 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib  ...
Message-ID: <E1Gxlge-0001l5-Lv@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 09:47:52

  Removed:     repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib 
                        jboss-portal.sar
  Log:
  delete (doesn't work)


From vladimir.blagojevic at jboss.com  Fri Dec 22 10:23:13 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Fri, 22 Dec 2006 10:23:13 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1GxmEr-0002W8-NG@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/22 10:23:13

  Modified:    src/org/jboss/cache  TreeCache.java
  Log:
  minor fixes in MessageListenerAdaptor
  
  Revision  Changes    Path
  1.301     +5 -8      JBossCache/src/org/jboss/cache/TreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCache.java,v
  retrieving revision 1.300
  retrieving revision 1.301
  diff -u -b -r1.300 -r1.301
  --- TreeCache.java	21 Dec 2006 21:41:10 -0000	1.300
  +++ TreeCache.java	22 Dec 2006 15:23:13 -0000	1.301
  @@ -99,7 +99,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: TreeCache.java,v 1.300 2006/12/21 21:41:10 vblagojevic Exp $
  + * @version $Id: TreeCache.java,v 1.301 2006/12/22 15:23:13 vblagojevic Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -3232,7 +3232,8 @@
      protected class MessageListenerAdaptor implements ExtendedMessageListener
      {      
         /**
  -       * An exception occuring upon fetch state.
  +       * Reference to an exception that was raised during 
  +       * state installation on this node.  
          */
         protected volatile Exception setStateException;
         private final Object stateLock = new Object();
  @@ -3296,7 +3297,7 @@
            else
            {
               log.error("Caught " + t.getClass().getName()
  -                  + " while responding to partial byte based state transfer request", t);
  +                  + " while responding to state transfer request", t);
            }
         }
   
  @@ -3305,10 +3306,6 @@
          */
         public void receive(Message msg)
         {
  -         if (log.isTraceEnabled())
  -         {
  -            log.trace("Received message " + msg);
  -         }
         }
         
         public byte[] getState()
  
  
  


From mandersen at jboss.com  Fri Dec 22 10:36:18 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 10:36:18 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/properties
	...
Message-ID: <E1GxmRW-0002ii-IT@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 10:36:18

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/properties 
                        HibernatePropertyPage.java
  Log:
  remove useless constant
  
  Revision  Changes    Path
  1.7       +2 -31     jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/properties/HibernatePropertyPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HibernatePropertyPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/properties/HibernatePropertyPage.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- HibernatePropertyPage.java	15 Sep 2006 12:49:18 -0000	1.6
  +++ HibernatePropertyPage.java	22 Dec 2006 15:36:18 -0000	1.7
  @@ -61,8 +61,6 @@
   
   public class HibernatePropertyPage extends PropertyPage {
   
  -	private static final int TEXT_FIELD_WIDTH = 50;
  -	
   	Control[] settings;
   
   	private Button enableHibernate;
  @@ -180,7 +178,7 @@
   
   		selectedConfiguration = new Combo(parent, SWT.DROP_DOWN);
   		GridData gd = new GridData();
  -		gd.widthHint = convertWidthInCharsToPixels(TEXT_FIELD_WIDTH);
  +		gd.widthHint = convertWidthInCharsToPixels(50);
   		selectedConfiguration.setLayoutData(gd);
   
   		// Populate owner text field
  @@ -265,34 +263,7 @@
   		
   	}
   	public boolean performOk() {
  -		IProject project = getProject();
  -		IScopeContext scope = new ProjectScope(project);
  -		
  -		Preferences node = scope.getNode("org.hibernate.eclipse.console");
  -		
  -		if(node!=null) {
  -			node.putBoolean("hibernate3.enabled", enableHibernate.getSelection() );
  -			node.put("default.configuration", selectedConfiguration.getText() );
  -			try {
  -				node.flush();
  -			} catch (BackingStoreException e) {
  -				HibernateConsolePlugin.getDefault().logErrorMessage("Could not save changes to preferences", e);
  -				return false;
  -			}
  -		} else {
  -			return false;
  -		}
  -		
  -		try {
  -			if(enableHibernate.getSelection() ) {
  -				ProjectUtils.addProjectNature(project, "org.hibernate.eclipse.console.hibernateNature", new NullProgressMonitor() );
  -			} else {
  -				ProjectUtils.removeProjectNature(project, "org.hibernate.eclipse.console.hibernateNature", new NullProgressMonitor() );
  -			}
  -		} catch(CoreException ce) {
  -			HibernateConsolePlugin.getDefault().logErrorMessage("Could not activate Hibernate nature on project " + project.getName(), ce);
  -			HibernateConsolePlugin.getDefault().log(ce.getStatus() );
  -		}
  +		ProjectUtils.toggleHibernateOnProject( getProject(), enableHibernate.getSelection(), selectedConfiguration.getText() );
   		return true;
   	}
   
  
  
  


From mandersen at jboss.com  Fri Dec 22 10:37:07 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 10:37:07 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test
	...
Message-ID: <E1GxmSJ-0002k4-Sb@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 10:37:07

  Modified:    hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test  
                        KnownConfigurationsTest.java
                        ConsoleConfigurationTest.java
  Log:
  fix compile errors
  
  Revision  Changes    Path
  1.3       +15 -0     jbosside/hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test/KnownConfigurationsTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: KnownConfigurationsTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test/KnownConfigurationsTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- KnownConfigurationsTest.java	8 Feb 2006 08:02:02 -0000	1.2
  +++ KnownConfigurationsTest.java	22 Dec 2006 15:37:07 -0000	1.3
  @@ -114,6 +114,21 @@
   				return null;
   			}
   		
  +			public ConfigurationMode getConfigurationMode() {
  +				// TODO Auto-generated method stub
  +				return null;
  +			}
  +
  +			public String getNamingStrategy() {
  +				// TODO Auto-generated method stub
  +				return null;
  +			}
  +
  +			public String getPersistenceUnitName() {
  +				// TODO Auto-generated method stub
  +				return null;
  +			}
  +		
   		};
   		ConsoleConfiguration configuration = new ConsoleConfiguration(preferences);
   		
  
  
  
  1.3       +31 -3     jbosside/hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test/ConsoleConfigurationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfigurationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test/ConsoleConfigurationTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ConsoleConfigurationTest.java	8 Feb 2006 08:02:02 -0000	1.2
  +++ ConsoleConfigurationTest.java	22 Dec 2006 15:37:07 -0000	1.3
  @@ -75,14 +75,27 @@
   			return "fake prefs";
   		}
   	
  -		public boolean useAnnotations() {
  -			return false;
  -		}
  +		
   
   		public String getEntityResolverName() {			
   			return "";
   		}
   	
  +		public ConfigurationMode getConfigurationMode() {
  +			
  +			return null;
  +		}
  +
  +		public String getNamingStrategy() {
  +			// TODO Auto-generated method stub
  +			return null;
  +		}
  +
  +		public String getPersistenceUnitName() {
  +			// TODO Auto-generated method stub
  +			return null;
  +		}
  +	
   	}
   	
   	
  @@ -137,4 +150,19 @@
   		
   	}
   	
  +	public void testCleanup() throws InterruptedException {
  +		
  +		for(int cnt=0;cnt<10000;cnt++) {
  +			if(cnt%2==0) {
  +				
  +				System.out.println("Cnt " + cnt + " " + Runtime.getRuntime().freeMemory()/1000);
  +				Thread.sleep( 2000 );
  +			}
  +			
  +			consoleCfg.build();
  +			consoleCfg.buildSessionFactory();
  +			consoleCfg.reset();
  +		}
  +		
  +	}
   }
  
  
  


From mandersen at jboss.com  Fri Dec 22 10:38:47 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 10:38:47 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/sql
	...
Message-ID: <E1GxmTv-0002kK-Ky@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 10:38:47

  Removed:     hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/sql 
                        ConsoleSQLLogFactory.java
  Log:
  Remove obsolete and never enabled ConsoleSQLLogFactory


From mandersen at jboss.com  Fri Dec 22 10:38:47 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 10:38:47 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console ...
Message-ID: <E1GxmTv-0002kR-OF@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 10:38:47

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console 
                        plugin.xml
  Log:
  Remove obsolete and never enabled ConsoleSQLLogFactory
  
  Revision  Changes    Path
  1.59      +0 -6      jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/plugin.xml,v
  retrieving revision 1.58
  retrieving revision 1.59
  diff -u -b -r1.58 -r1.59
  --- plugin.xml	17 Nov 2006 19:57:31 -0000	1.58
  +++ plugin.xml	22 Dec 2006 15:38:47 -0000	1.59
  @@ -534,12 +534,6 @@
    
    <!--
    <extension
  -       point="org.eclipse.ui.console.consoleFactories">
  -    <consoleFactory
  -          class="org.hibernate.eclipse.console.sql.ConsoleSQLLogFactory"
  -          label="Hibernate SQL Log"/>
  - </extension>
  - <extension
          point="org.eclipse.ui.themes">
       <themeElementCategory
             id="org.hibernate.eclipse.console.theme.HQLColors"
  
  
  


From mandersen at jboss.com  Fri Dec 22 10:39:48 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 10:39:48 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/utils
	...
Message-ID: <E1GxmUu-0002kp-LE@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 10:39:48

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/utils 
                        ProjectUtils.java
  Log:
  HBX-844 auto enable support projects linked to console configuration
  
  Revision  Changes    Path
  1.10      +37 -0     jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/utils/ProjectUtils.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProjectUtils.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/utils/ProjectUtils.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- ProjectUtils.java	23 Oct 2006 13:22:55 -0000	1.9
  +++ ProjectUtils.java	22 Dec 2006 15:39:48 -0000	1.10
  @@ -25,17 +25,22 @@
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.resources.IProjectDescription;
   import org.eclipse.core.resources.IWorkspaceRoot;
  +import org.eclipse.core.resources.ProjectScope;
   import org.eclipse.core.resources.ResourcesPlugin;
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.core.runtime.OperationCanceledException;
  +import org.eclipse.core.runtime.preferences.IScopeContext;
   import org.eclipse.jdt.core.IJavaProject;
   import org.eclipse.jdt.core.JavaCore;
   import org.eclipse.ui.IEditorInput;
   import org.eclipse.ui.IEditorPart;
   import org.eclipse.ui.IFileEditorInput;
  +import org.hibernate.eclipse.console.HibernateConsolePlugin;
   import org.hibernate.util.StringHelper;
  +import org.osgi.service.prefs.BackingStoreException;
  +import org.osgi.service.prefs.Preferences;
   
   public class ProjectUtils {
   
  @@ -43,6 +48,38 @@
   		
   	}
   	
  +	public static boolean toggleHibernateOnProject(IProject project, boolean enable,String defaultConsoleName) {
  +		IScopeContext scope = new ProjectScope(project);
  +		
  +		Preferences node = scope.getNode("org.hibernate.eclipse.console");
  +		
  +		if(node!=null) {
  +			node.putBoolean("hibernate3.enabled", enable );
  +			node.put("default.configuration", defaultConsoleName );
  +			try {
  +				node.flush();
  +			} catch (BackingStoreException e) {
  +				HibernateConsolePlugin.getDefault().logErrorMessage("Could not save changes to preferences", e);
  +				return false;
  +			}
  +		} else {
  +			return false;
  +		}
  +		
  +		try {
  +			if(enable) {
  +				return ProjectUtils.addProjectNature(project, "org.hibernate.eclipse.console.hibernateNature", new NullProgressMonitor() );
  +			} else {
  +				return ProjectUtils.removeProjectNature(project, "org.hibernate.eclipse.console.hibernateNature", new NullProgressMonitor() );
  +			}
  +		} catch(CoreException ce) {
  +			HibernateConsolePlugin.getDefault().logErrorMessage("Could not activate Hibernate nature on project " + project.getName(), ce);
  +			HibernateConsolePlugin.getDefault().log(ce.getStatus() );
  +			return false;
  +		}
  +		
  +	}
  +	
   	/**
   	 * Add the given project nature to the given project (if it isn't already added).
   	 * @return true if nature where added, false if not
  
  
  


From mandersen at jboss.com  Fri Dec 22 10:39:48 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 10:39:48 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards
	...
Message-ID: <E1GxmUu-0002kw-P5@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 10:39:48

  Modified:    hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards 
                        ConsoleConfigurationCreationWizard.java
  Log:
  HBX-844 auto enable support projects linked to console configuration
  
  Revision  Changes    Path
  1.14      +47 -9     jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationCreationWizard.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleConfigurationCreationWizard.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationCreationWizard.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ConsoleConfigurationCreationWizard.java	14 Dec 2006 11:52:54 -0000	1.13
  +++ ConsoleConfigurationCreationWizard.java	22 Dec 2006 15:39:48 -0000	1.14
  @@ -29,13 +29,15 @@
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.IStatus;
   import org.eclipse.core.runtime.MultiStatus;
  -import org.eclipse.core.runtime.Status;
  -import org.eclipse.jface.dialogs.ErrorDialog;
  +import org.eclipse.jdt.core.IJavaProject;
  +import org.eclipse.jface.dialogs.MessageDialog;
   import org.eclipse.jface.operation.IRunnableWithProgress;
   import org.eclipse.jface.viewers.ISelection;
   import org.eclipse.jface.viewers.IStructuredSelection;
   import org.eclipse.jface.wizard.IWizardContainer;
   import org.eclipse.jface.wizard.Wizard;
  +import org.eclipse.swt.widgets.Display;
  +import org.eclipse.swt.widgets.Shell;
   import org.eclipse.ui.INewWizard;
   import org.eclipse.ui.IWorkbench;
   import org.eclipse.ui.IWorkbenchWizard;
  @@ -48,6 +50,9 @@
   import org.hibernate.eclipse.console.EclipseConsoleConfigurationPreferences;
   import org.hibernate.eclipse.console.HibernateConsolePlugin;
   import org.hibernate.eclipse.console.utils.EclipseImages;
  +import org.hibernate.eclipse.console.utils.ProjectUtils;
  +import org.hibernate.eclipse.nature.HibernateNature;
  +import org.hibernate.util.StringHelper;
   
   /**
    * @author max
  @@ -101,7 +106,7 @@
   		IRunnableWithProgress op = new IRunnableWithProgress() {
   			public void run(IProgressMonitor monitor) throws InvocationTargetException {
   				try {
  -					createConsoleConfiguration(confPage.getOldConfiguration(), configName, annotations, projectName, useProjectClasspath, entityResolver, propertyFile, fileName, mappings, classpaths, persistenceUnitName, namingStrategy, monitor);
  +					createConsoleConfiguration(confPage.getShell(), confPage.getOldConfiguration(), configName, annotations, projectName, useProjectClasspath, entityResolver, propertyFile, fileName, mappings, classpaths, persistenceUnitName, namingStrategy, monitor);
   				} catch (CoreException e) {
   					throw new InvocationTargetException(e);
   				} finally {
  @@ -130,13 +135,14 @@
   	}
   	
   	static private void createConsoleConfiguration(
  -			EclipseConsoleConfiguration oldConfig,
  -			String configName,
  -			ConfigurationMode cmode, String projectName, boolean useProjectClasspath, String entityResolver, IPath propertyFilename,
  +			final Shell shell,
  +			final EclipseConsoleConfiguration oldConfig,
  +			final String configName,
  +			ConfigurationMode cmode, final String projectName, boolean useProjectClasspath, String entityResolver, IPath propertyFilename,
   			IPath cfgFile, IPath[] mappings, IPath[] classpaths, String persistenceUnitName, String namingStrategy, IProgressMonitor monitor)
   		throws CoreException {
   
  -		monitor.beginTask("Configuring Hibernate Console" + propertyFilename, IProgressMonitor.UNKNOWN);
  +		monitor.beginTask("Configuring Hibernate Console", IProgressMonitor.UNKNOWN);
   								
   		ConsoleConfigurationPreferences ccp = new EclipseConsoleConfigurationPreferences(
   				configName, cmode, projectName, useProjectClasspath,
  @@ -151,7 +157,39 @@
   			KnownConfigurations.getInstance().removeConfiguration(oldConfig);
   		} 
   		KnownConfigurations.getInstance().addConfiguration(cfg, true);
  +		
  +		// force save changes to console config
   		ResourcesPlugin.getWorkspace().save( false, monitor );
  +		Display.getDefault().syncExec(new Runnable() {
  +            public void run() {
  +            	if(StringHelper.isNotEmpty( projectName )) {
  +        			IJavaProject project = ProjectUtils.findJavaProject( projectName );
  +        			if(project.exists()) {				 
  +        				HibernateNature hibernateNature = HibernateNature.getHibernateNature( project );
  +        				if(hibernateNature==null) { // project not enabled at all
  +        					if( MessageDialog.openConfirm( shell, "Enable Hibernate features for project", "The project named " + projectName + " does not have Hibernate features enabled. Should it be updated to use " + configName + " ?")) {
  +        						ProjectUtils.toggleHibernateOnProject( project.getProject(), true, configName );
  +        					}
  +        				}
  +        				else {
  +        					String defaultConsoleConfigurationName = hibernateNature.getDefaultConsoleConfigurationName();
  +        					
  +        					if(oldConfig!=null && oldConfig.getName().equals(defaultConsoleConfigurationName)) { // an update so its just forced in there.
  +        						ProjectUtils.toggleHibernateOnProject( project.getProject(), true, configName );
  +        					} else if(defaultConsoleConfigurationName==null) {						
  +        						if(MessageDialog.openConfirm( shell, "Enable Hibernate features for project", "The project named " + projectName + " does not have a default Hibernate configuration specified. Should it be updated to use " + configName + " ?")) {
  +        							ProjectUtils.toggleHibernateOnProject( project.getProject(), true, configName );
  +        						}
  +        					} else { // hibernate enabled, but not this exact one
  +        						if(MessageDialog.openConfirm( shell, "Enable Hibernate features for project", "The project named " + projectName + " have the " + defaultConsoleConfigurationName + " specified. Should it be updated to use " + configName + " ?")) {
  +        							ProjectUtils.toggleHibernateOnProject( project.getProject(), true, configName );
  +        						}
  +        					} 
  +        				}
  +        			}		
  +        		}
  + 
  +            }});
   		monitor.worked(1);
   	} 
   	
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 11:26:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 11:26:53 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1848 - in trunk/tests: .
	src/org/jboss/test/messaging/jms/clustering
	src/org/jboss/test/messaging/jms/clustering/base
Message-ID: <E1GxnET-0003gz-LI@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-22 11:26:50 -0500 (Fri, 22 Dec 2006)
New Revision: 1848

Modified:
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
Log:
http://jira.jboss.org/jira/browse/JBMESSAGING-696 - Adding testcase

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-22 10:23:27 UTC (rev 1847)
+++ trunk/tests/build.xml	2006-12-22 16:26:50 UTC (rev 1848)
@@ -69,6 +69,7 @@
 
    <!-- Clustering tests -->
    <property name="clustering.tests.database" value="mysql"/>
+   <property name ="test-mask" value="*Test"/>
 
    <!--
         Default remoting configuration (must be overrided by tasks that need it set otherwise).
@@ -816,7 +817,7 @@
             <formatter classname="org.jboss.test.messaging.tools.ant.JUnitTestSuiteListener"/>
 
             <fileset dir="${build.tests.classes}">
-               <include name="**/jms/clustering/*Test.class"/>
+               <include name="**/jms/clustering/${test-mask}.class"/>
             </fileset>
          </batchtest>
       </junit>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-22 10:23:27 UTC (rev 1847)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-22 16:26:50 UTC (rev 1848)
@@ -94,6 +94,60 @@
       conn.close();
    }
 
+   /**
+    * This test was created as per http://jira.jboss.org/jira/browse/JBMESSAGING-696.
+    */
+   public void testCloseOnFailover() throws Exception
+   {
+      JBossConnectionFactory factory = (JBossConnectionFactory) ic[0].lookup("/ConnectionFactory");
+
+      Connection conn1 = factory.createConnection();
+      Connection conn2 = factory.createConnection();
+      Connection conn3 = factory.createConnection();
+
+      Connection[] conn = new Connection[]{conn1, conn2, conn3};
+
+      log.info("Connection delegate information after creation");
+      for (int i = 0; i < conn.length; i++)
+      {
+         log.info("conn" + i + ".serverid=" + getServerId(conn[i]) + " conn" + i + ".ObjectID=" + getObjectId(conn[i])
+            + " locatorURL=" + getLocatorURL(conn[i]));
+      }
+
+      log.info("Killing server 1 and waiting 30 seconds for failover to kick in on client (from Lease)");
+      ServerManagement.kill(1);
+      Thread.sleep(30000);
+
+      log.info("Connection delegate information after failover");
+      for (int i = 0; i < conn.length; i++)
+      {
+         log.info("conn" + i + ".serverid=" + getServerId(conn[i]) + " conn" + i + ".ObjectID=" + getObjectId(conn[i])
+            + " locatorURL=" + getLocatorURL(conn[i]));
+      }
+
+      ConnectionState state2 = getConnectionState(conn2);
+      ConnectionState state3 = getConnectionState(conn3);
+
+      assertNotSame(state2.getRemotingConnection(), state3.getRemotingConnection());
+      assertNotSame(state2.getRemotingConnection().getInvokingClient(), state3.getRemotingConnection().getInvokingClient());
+
+
+
+      conn1.close();
+      assertNotNull(state2.getRemotingConnection());
+      assertNotNull(state2.getRemotingConnection().getInvokingClient().getInvoker());
+      assertTrue(state2.getRemotingConnection().getInvokingClient().getInvoker().isConnected());
+      conn2.close();
+
+      log.info("Closing connection 3 now");
+
+      assertNotNull(state3.getRemotingConnection());
+      assertNotNull(state3.getRemotingConnection().getInvokingClient().getInvoker());
+      assertTrue(state3.getRemotingConnection().getInvokingClient().getInvoker().isConnected());
+      // When I created the testcase this was failing, throwing exceptions. This was basically why I created this testcase
+      conn3.close();
+   }
+
    /*
     * Test that connections created using a clustered connection factory are created round robin on
     * different servers

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-22 10:23:27 UTC (rev 1847)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-22 16:26:50 UTC (rev 1848)
@@ -130,6 +130,50 @@
       super.tearDown();
    }
 
+   protected String getLocatorURL(Connection conn)
+   {
+      return getConnectionState(conn).getRemotingConnection().getInvokingClient().getInvoker().getLocator().getLocatorURI();
+   }
+
+   protected int getServerId(Connection conn)
+   {
+      return getConnectionState(conn).getServerID();
+   }
+
+   protected int getObjectId(Connection conn)
+   {
+      return ((DelegateSupport) ((JBossConnection) conn).
+         getDelegate()).getID();
+   }
+
+   protected ConnectionState getConnectionState(Connection conn)
+   {
+      return (ConnectionState) (((DelegateSupport) ((JBossConnection) conn).
+         getDelegate()).getState());
+   }
+
+   protected Connection createConnectionOnServer(ConnectionFactory factory, int serverId) throws Exception
+   {
+      int count=0;
+
+      while (true)
+      {
+         if (count++>10)
+            return null;
+
+         Connection connection = factory.createConnection();
+
+         if (getServerId(connection) == serverId)
+         {
+            return connection;
+         }
+         else
+         {
+            connection.close();
+         }
+      }
+   }
+
    // lookup for the connection with the right serverID
    // I'm using this method to find the proper serverId so I won't relay on loadBalancing policies on testcases
    protected Connection getConnection(Connection[] conn, int serverId) throws Exception



From vladimir.blagojevic at jboss.com  Fri Dec 22 13:55:05 2006
From: vladimir.blagojevic at jboss.com (Vladmir Blagojevic)
Date: Fri, 22 Dec 2006 13:55:05 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/statetransfer
	...
Message-ID: <E1GxpXt-0008Qs-UE@committer01.frg.pub.inap.atl.jboss.com>

  User: vblagojevic
  Date: 06/12/22 13:55:05

  Modified:    tests/functional/org/jboss/cache/statetransfer   
                        VersionedTestBase.java StateTransferTestBase.java
  Added:       tests/functional/org/jboss/cache/statetransfer   
                        StateTransferCompatibilityTest.java
  Log:
  split tests to avoid timeout
  
  Revision  Changes    Path
  1.21      +0 -119    JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: VersionedTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- VersionedTestBase.java	21 Dec 2006 21:41:36 -0000	1.20
  +++ VersionedTestBase.java	22 Dec 2006 18:55:05 -0000	1.21
  @@ -69,93 +69,6 @@
         initialStateTferWithLoaderTest(false);
      }
   
  -
  -   /**
  -    * These tests ensure that http://jira.jboss.com/jira/browse/JBCACHE-738
  -    * compatibility between non-delegating cacheloaders is maintained. In the tests
  -    * below first cacheloader parameter is the state producer and the second cacheloader
  -    * parameter is the state receiver. By having each cacheloader be a state receiver
  -    * and a state producer we ensure complete cacheloader compatibility.
  -    */
  -   public void testCompatibilityBetweenFileAndJbdmCacheLoaders() throws Exception
  -   {
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
  -              "org.jboss.cache.loader.jdbm.JdbmCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenFileAndJDBCCacheLoaders() throws Exception
  -   {
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
  -              "org.jboss.cache.loader.JDBCCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenFileAndBdbjeCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
  -              "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenJbdmAndJDBCCacheLoaders() throws Exception
  -   {
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.jdbm.JdbmCacheLoader",
  -              "org.jboss.cache.loader.JDBCCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenJbdmAndBdbjeCacheLoaders() throws Exception
  -   {
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.jdbm.JdbmCacheLoader",
  -              "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenJbdmAndFileCacheLoaders() throws Exception
  -   {
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.jdbm.JdbmCacheLoader",
  -              "org.jboss.cache.loader.FileCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenJDBCAndBdjeCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.JDBCCacheLoader",
  -              "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenJDBCAndFileCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.JDBCCacheLoader",
  -              "org.jboss.cache.loader.FileCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenJDBCAndJbdmCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.JDBCCacheLoader",
  -              "org.jboss.cache.loader.jdbm.JdbmCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenBdbjeandJDBCCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.bdbje.BdbjeCacheLoader",
  -              "org.jboss.cache.loader.JDBCCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenBdbjeandFileCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.bdbje.BdbjeCacheLoader",
  -              "org.jboss.cache.loader.FileCacheLoader", false);
  -   }
  -
  -   public void testCompatibilityBetweenBdbjeandJbdmCacheLoaders() throws Exception
  -   {
  -
  -      initialStateTferWithLoaderTest("org.jboss.cache.loader.bdbje.BdbjeCacheLoader",
  -              "org.jboss.cache.loader.jdbm.JdbmCacheLoader", false);
  -   }
  -
      public void testInitialStateTferWithAsyncLoader() throws Exception
      {
         initialStateTferWithLoaderTest(true);
  @@ -167,38 +80,6 @@
                 "org.jboss.cache.loader.FileCacheLoader", asyncLoader);
      }
   
  -   protected void initialStateTferWithLoaderTest(String cacheLoaderClass1, String cacheLoaderClass2, boolean asyncLoader) throws Exception
  -   {
  -      CacheSPI cache1 = createCache("cache1", false, false, cacheLoaderClass1, false, true);
  -
  -      cache1.put(A_B, "name", JOE);
  -      cache1.put(A_B, "age", TWENTY);
  -      cache1.put(A_C, "name", BOB);
  -      cache1.put(A_C, "age", FORTY);
  -
  -      CacheSPI cache2 = createCache("cache2", false, false, cacheLoaderClass2, asyncLoader, false);
  -
  -      cache2.start();
  -
  -      // Pause to give caches time to see each other
  -      TestingUtil.blockUntilViewsReceived(new CacheSPI[]{cache1, cache2}, 60000);
  -
  -      if (asyncLoader)
  -         TestingUtil.sleepThread((long) 100);
  -
  -      CacheLoader loader = cache2.getCacheLoader();
  -
  -      assertEquals("Incorrect loader name for /a/b", JOE, loader.get(A_B).get("name"));
  -      assertEquals("Incorrect loader age for /a/b", TWENTY, loader.get(A_B).get("age"));
  -      assertEquals("Incorrect loader name for /a/c", BOB, loader.get(A_C).get("name"));
  -      assertEquals("Incorrect loader age for /a/c", FORTY, loader.get(A_C).get("age"));
  -
  -      assertEquals("Incorrect name for /a/b", JOE, cache2.get(A_B, "name"));
  -      assertEquals("Incorrect age for /a/b", TWENTY, cache2.get(A_B, "age"));
  -      assertEquals("Incorrect name for /a/c", BOB, cache2.get(A_C, "name"));
  -      assertEquals("Incorrect age for /a/c", FORTY, cache2.get(A_C, "age"));
  -   }
  -
      public void testPartialStateTransfer() throws Exception
      {
         CacheSPI cache1 = createCache("cache1", false, true, false);
  
  
  
  1.26      +35 -0     JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- StateTransferTestBase.java	21 Dec 2006 21:41:36 -0000	1.25
  +++ StateTransferTestBase.java	22 Dec 2006 18:55:05 -0000	1.26
  @@ -29,7 +29,9 @@
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.loader.AbstractCacheLoaderTestBase;
  +import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.marshall.SelectedClassnameClassLoader;
  +import org.jboss.cache.misc.TestingUtil;
   
   
   import java.io.File;
  @@ -189,6 +191,38 @@
         }
      }
   
  +   protected void initialStateTferWithLoaderTest(String cacheLoaderClass1, String cacheLoaderClass2, boolean asyncLoader) throws Exception
  +   {
  +      CacheSPI cache1 = createCache("cache1", false, false, cacheLoaderClass1, false, true);
  +
  +      cache1.put(A_B, "name", JOE);
  +      cache1.put(A_B, "age", TWENTY);
  +      cache1.put(A_C, "name", BOB);
  +      cache1.put(A_C, "age", FORTY);
  +
  +      CacheSPI cache2 = createCache("cache2", false, false, cacheLoaderClass2, asyncLoader, false);
  +
  +      cache2.start();
  +
  +      // Pause to give caches time to see each other
  +      TestingUtil.blockUntilViewsReceived(new CacheSPI[]{cache1, cache2}, 60000);
  +
  +      if (asyncLoader)
  +         TestingUtil.sleepThread((long) 100);
  +
  +      CacheLoader loader = cache2.getCacheLoader();
  +
  +      assertEquals("Incorrect loader name for /a/b", JOE, loader.get(A_B).get("name"));
  +      assertEquals("Incorrect loader age for /a/b", TWENTY, loader.get(A_B).get("age"));
  +      assertEquals("Incorrect loader name for /a/c", BOB, loader.get(A_C).get("name"));
  +      assertEquals("Incorrect loader age for /a/c", FORTY, loader.get(A_C).get("age"));
  +
  +      assertEquals("Incorrect name for /a/b", JOE, cache2.get(A_B, "name"));
  +      assertEquals("Incorrect age for /a/b", TWENTY, cache2.get(A_B, "age"));
  +      assertEquals("Incorrect name for /a/c", BOB, cache2.get(A_C, "name"));
  +      assertEquals("Incorrect age for /a/c", FORTY, cache2.get(A_C, "age"));
  +   }
  +
      protected String getTempLocation(String cacheID)
      {
         String tmp_location = System.getProperty("java.io.tmpdir", "c:\\tmp");
  @@ -239,6 +273,7 @@
         for (int i = 0; i < cacheIDs.length; i++)
         {
            stopCache((Cache) caches.get(cacheIDs[i]));
  +         TestingUtil.sleepThread(1500);
            File file = new File(getTempLocation(cacheIDs[i]));
            cleanFile(file);
         }
  
  
  
  1.1      date: 2006/12/22 18:55:05;  author: vblagojevic;  state: Exp;JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferCompatibilityTest.java
  
  Index: StateTransferCompatibilityTest.java
  ===================================================================
  package org.jboss.cache.statetransfer;
  
  public class StateTransferCompatibilityTest extends StateTransferTestBase
  {
  
     protected String getReplicationVersion()
     {
        return "2.0.0.GA";
     }
     
  
     /**
      * These tests ensure that http://jira.jboss.com/jira/browse/JBCACHE-738
      * compatibility between non-delegating cacheloaders is maintained. In the tests
      * below first cacheloader parameter is the state producer and the second cacheloader
      * parameter is the state receiver. By having each cacheloader be a state receiver
      * and a state producer we ensure complete cacheloader compatibility.
      */
     public void testCompatibilityBetweenFileAndJbdmCacheLoaders() throws Exception
     {
        initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
                "org.jboss.cache.loader.jdbm.JdbmCacheLoader", false);
     }
  
     public void testCompatibilityBetweenFileAndJDBCCacheLoaders() throws Exception
     {
        initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
                "org.jboss.cache.loader.JDBCCacheLoader", false);
     }
  
     public void testCompatibilityBetweenFileAndBdbjeCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
                "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", false);
     }
  
     public void testCompatibilityBetweenJbdmAndJDBCCacheLoaders() throws Exception
     {
        initialStateTferWithLoaderTest("org.jboss.cache.loader.jdbm.JdbmCacheLoader",
                "org.jboss.cache.loader.JDBCCacheLoader", false);
     }
  
     public void testCompatibilityBetweenJbdmAndBdbjeCacheLoaders() throws Exception
     {
        initialStateTferWithLoaderTest("org.jboss.cache.loader.jdbm.JdbmCacheLoader",
                "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", false);
     }
  
     public void testCompatibilityBetweenJbdmAndFileCacheLoaders() throws Exception
     {
        initialStateTferWithLoaderTest("org.jboss.cache.loader.jdbm.JdbmCacheLoader",
                "org.jboss.cache.loader.FileCacheLoader", false);
     }
  
     public void testCompatibilityBetweenJDBCAndBdjeCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.JDBCCacheLoader",
                "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", false);
     }
  
     public void testCompatibilityBetweenJDBCAndFileCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.JDBCCacheLoader",
                "org.jboss.cache.loader.FileCacheLoader", false);
     }
  
     public void testCompatibilityBetweenJDBCAndJbdmCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.JDBCCacheLoader",
                "org.jboss.cache.loader.jdbm.JdbmCacheLoader", false);
     }
  
     public void testCompatibilityBetweenBdbjeandJDBCCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.bdbje.BdbjeCacheLoader",
                "org.jboss.cache.loader.JDBCCacheLoader", false);
     }
  
     public void testCompatibilityBetweenBdbjeandFileCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.bdbje.BdbjeCacheLoader",
                "org.jboss.cache.loader.FileCacheLoader", false);
     }
  
     public void testCompatibilityBetweenBdbjeandJbdmCacheLoaders() throws Exception
     {
  
        initialStateTferWithLoaderTest("org.jboss.cache.loader.bdbje.BdbjeCacheLoader",
                "org.jboss.cache.loader.jdbm.JdbmCacheLoader", false);
     }
  
     protected void initialStateTferWithLoaderTest(boolean asyncLoader) throws Exception
     {
        initialStateTferWithLoaderTest("org.jboss.cache.loader.FileCacheLoader",
                "org.jboss.cache.loader.FileCacheLoader", asyncLoader);
     }
  }
  
  
  


From rawblem at gmail.com  Fri Dec 22 14:09:31 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 14:09:31 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types
	...
Message-ID: <E1Gxplr-0000gf-Oc@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 14:09:31

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types  
                        JARPackageType.java
  Added:       core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types  
                        AbstractPackageType.java
  Log:
  Further changes to the extension point infrastructure to adhere to newly-determined best practices. 
  
  Revision  Changes    Path
  1.8       +3 -11     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JARPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- JARPackageType.java	22 Dec 2006 01:08:40 -0000	1.7
  +++ JARPackageType.java	22 Dec 2006 19:09:31 -0000	1.8
  @@ -21,7 +21,7 @@
    * The name of the resulting JAR will be the project's name followed by a ".jar" extension.
    * @author Marshall
    */
  -public class JARPackageType implements IPackageType {
  +public class JARPackageType extends AbstractPackageType {
   
   	public static final String TYPE_ID = "jar";
   	public IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor)
  @@ -70,20 +70,12 @@
   		try {
   			if (project.hasNature(JavaCore.NATURE_ID))
   			{
  -				return SUPPORT_FULL;
  +				return IPackageType.SUPPORT_FULL;
   			}
   		} catch (CoreException e) {
   			Trace.trace(getClass(), e);
   		}
   		
  -		return SUPPORT_NONE;
  -	}
  -	
  -	public String getId() {
  -		return "jar";
  -	}
  -
  -	public String getLabel() {
  -		return "JAR";
  +		return IPackageType.SUPPORT_NONE;
   	}
   }
  
  
  
  1.3       +35 -20    jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/AbstractPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractPackageType.java
  ===================================================================
  RCS file: AbstractPackageType.java
  diff -N AbstractPackageType.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ AbstractPackageType.java	22 Dec 2006 19:09:31 -0000	1.3
  @@ -0,0 +1,47 @@
  +/**
  + * JBoss, a Division of Red Hat
  + * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.ide.eclipse.packages.core.model.types;
  +
  +import org.eclipse.core.resources.IProject;
  +import org.eclipse.core.runtime.IConfigurationElement;
  +import org.eclipse.core.runtime.IProgressMonitor;
  +import org.jboss.ide.eclipse.packages.core.model.IPackage;
  +
  +/**
  + *
  + * @author rob.stryker at jboss.com
  + */
  +public abstract class AbstractPackageType implements IPackageType {
  +	private String id;
  +	private String label;
  +	
  +	public void setInitializationData(IConfigurationElement el) {
  +		id = el.getAttribute("id");
  +		label = el.getAttribute("label");
  +	}
  +	
  +	public String getId() { return id; }
  +	public String getLabel() { return label; }
  +	
  +	public abstract int getSupportFor (IProject project);
  +	public abstract IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor);
  +}
  
  
  


From rawblem at gmail.com  Fri Dec 22 14:09:31 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 14:09:31 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core
	...
Message-ID: <E1Gxplr-0000gn-RT@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 14:09:31

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core 
                        ExtensionManager.java
  Log:
  Further changes to the extension point infrastructure to adhere to newly-determined best practices. 
  
  Revision  Changes    Path
  1.4       +4 -2      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExtensionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ExtensionManager.java	22 Dec 2006 01:08:40 -0000	1.3
  +++ ExtensionManager.java	22 Dec 2006 19:09:31 -0000	1.4
  @@ -9,6 +9,7 @@
   import org.eclipse.core.runtime.IExtensionRegistry;
   import org.eclipse.core.runtime.InvalidRegistryObjectException;
   import org.eclipse.core.runtime.Platform;
  +import org.jboss.ide.eclipse.packages.core.model.types.AbstractPackageType;
   import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
   
   public class ExtensionManager {
  @@ -33,8 +34,9 @@
   			{
   				try {
   					Object executable = elements[j].createExecutableExtension("class");
  -					if( !(executable instanceof IPackageType)) 
  -						throw new Exception("Provided class is not an IPackageType");
  +					if( !(executable instanceof AbstractPackageType)) 
  +						throw new Exception("Provided class (" + elements[j].getAttribute("class")+ ") is not an IPackageType");
  +					((AbstractPackageType)executable).setInitializationData(elements[j]);
   					packageTypes.add((IPackageType)executable);
   				} catch (InvalidRegistryObjectException e) {
   					Trace.trace(ExtensionManager.class, e);
  
  
  


From validimir.ralev at jboss.com  Fri Dec 22 15:14:49 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 15:14:49 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1  ...
Message-ID: <E1Gxqn3-0003DG-8H@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 15:14:49

  Added:       repository.jboss.com/jboss-portal/2.4.1.GA-SP1 
                        component-info.xml
  Log:
  2.4.1.GA-SP1 with correct resources
  
  Revision  Changes    Path
  1.3       +0 -0      /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: component-info.xml
  diff -N component-info.xml
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ component-info.xml	22 Dec 2006 20:14:49 -0000	1.3
  @@ -0,0 +1,22 @@
  +<project name="jboss-portal-component-info">
  +
  +   <!-- The component id is the repository path -->
  +   <!-- The license type for which there must be an *.txt in repository.jboss.com/licenses -->
  +   <!-- The version of the component -->
  +   <!-- The component home/info page -->
  +   <!-- A short description of the component -->
  +   <component id="jboss-portal"
  +              licenseType="lgpl"
  +              version="2.4.1.GA-SP1"
  +              projectHome="http://labs.jboss.com/portal/jbossportal/"
  +              description="JBoss Portal">
  +
  +      <!-- Artifacts produced by this component -->
  +      <artifact id="jboss-portal.sar"/>
  +      <artifact id="portal-hsqldb-ds.xml"/>
  +      <!-- The artifacts exported by this component -->
  +      <export>
  +         <include input="jboss-portal.sar"/>
  +      </export>
  +   </component>
  +</project>
  \ No newline at end of file
  
  
  


From validimir.ralev at jboss.com  Fri Dec 22 15:14:51 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 15:14:51 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib  ...
Message-ID: <E1Gxqn5-0003DN-8y@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 15:14:51

  Added:       repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib 
                        jboss-portal.sar
  Log:
  2.4.1.GA-SP1 with correct resources
  
  Revision  Changes    Path
  1.3       +1441 -1429/repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib/jboss-portal.sar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Fri Dec 22 15:14:51 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Fri, 22 Dec 2006 15:14:51 -0500
Subject: [jboss-cvs] /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources
	...
Message-ID: <E1Gxqn5-0003DU-Db@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/22 15:14:51

  Added:       repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources 
                        portal-hsqldb-ds.xml
  Log:
  2.4.1.GA-SP1 with correct resources
  
  Revision  Changes    Path
  1.3       +0 -23     /repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: portal-hsqldb-ds.xml
  ===================================================================
  RCS file: portal-hsqldb-ds.xml
  diff -N portal-hsqldb-ds.xml
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ portal-hsqldb-ds.xml	22 Dec 2006 20:14:51 -0000	1.3
  @@ -0,0 +1,10 @@
  +<?xml version="1.0" encoding="UTF-8"?>
  +<datasources>
  +  <local-tx-datasource>
  +    <jndi-name>PortalDS</jndi-name>
  +    <connection-url>jdbc:hsqldb:${jboss.server.data.dir}${/}portal${/}hypersonic${/}database</connection-url>
  +    <driver-class>org.hsqldb.jdbcDriver</driver-class>
  +    <user-name>sa</user-name>
  +    <password><![CDATA[]]></password>
  +  </local-tx-datasource>
  +</datasources>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 15:55:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 15:55:43 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1849 - in trunk:
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting tests
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/message
	tests/src/org/jboss/test/messaging/tools/jmx
Message-ID: <E1GxrQd-0004bE-6C@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-22 15:55:26 -0500 (Fri, 22 Dec 2006)
New Revision: 1849

Removed:
   trunk/src/main/org/jboss/jms/client/remoting/HandleMessageResponse.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
   trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java
   trunk/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
Log:
Mainly http://jira.jboss.com/jira/browse/JBMESSAGING-657



Modified: trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -72,10 +72,9 @@
       ConnectionState connectionState = (ConnectionState)sessionState.getParent();
       SessionDelegate sessionDelegate = (SessionDelegate)invocation.getTargetObject();
       ConsumerState consumerState = (ConsumerState)((DelegateSupport)consumerDelegate).getState();
-      int serverId = connectionState.getServerID();
       int consumerID = consumerState.getConsumerID();
       long channelID = consumerState.getChannelId();
-      int prefetchSize = consumerState.getPrefetchSize();
+      int prefetchSize = consumerState.getBufferSize();
       QueuedExecutor sessionExecutor = sessionState.getExecutor();
       int maxDeliveries = consumerState.getMaxDeliveries();
       
@@ -94,31 +93,43 @@
       
       //Now we have finished creating the client consumer, we can tell the SCD
       //we are ready
-      consumerDelegate.more();
+      consumerDelegate.changeRate(1);
 
       return consumerDelegate;
    }
    
    public Object handleClosing(Invocation invocation) throws Throwable
    {      
-      // First we make sure closing is called on the ServerConsumerEndpoint. This ensures that any
-      // in-transit messages are flushed out to the client side.
-
-      Object res = invocation.invokeNext();
+      ConsumerState consumerState = getState(invocation);
       
-      ConsumerState consumerState = getState(invocation);
-      SessionState sessionState = (SessionState)consumerState.getParent();
-      ConnectionState connectionState = (ConnectionState)sessionState.getParent();
-            
-      // Then we call close on the messagecallbackhandler which waits for onMessage invocations
+      // First we call close on the messagecallbackhandler which waits for onMessage invocations      
       // to complete and then cancels anything in the client buffer.
+      // any further messages received will be ignored
       consumerState.getMessageCallbackHandler().close();
       
+      long lastDeliveryId = consumerState.getMessageCallbackHandler().getLastDeliveryId();
+      
+      SessionState sessionState = (SessionState)consumerState.getParent();
+      ConnectionState connectionState = (ConnectionState)sessionState.getParent();
+                 
       sessionState.removeCallbackHandler(consumerState.getMessageCallbackHandler());
 
       CallbackManager cm = connectionState.getRemotingConnection().getCallbackManager();
       cm.unregisterHandler(consumerState.getConsumerID());
             
+      // Then we make sure closing is called on the ServerConsumerEndpoint.
+
+      Object res = invocation.invokeNext();
+      
+      //Now we send a message to the server consumer with the last delivery id so
+      //it can cancel any inflight messages after that
+      //This needs to be done *after* the call to closing has been executed on the server
+      //maybe it can be combined with closing
+      
+      ConsumerDelegate del = (ConsumerDelegate)invocation.getTargetObject();
+         
+      del.cancelInflightMessages(lastDeliveryId);
+                                   
       return res;
    }      
    

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -38,7 +38,6 @@
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
-import org.jboss.jms.tx.ClientTransaction;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
 
@@ -67,31 +66,7 @@
    // Constructors --------------------------------------------------
    
    // Public --------------------------------------------------------
-
-   private void ackDelivery(SessionDelegate sess, DeliveryInfo delivery) throws Exception
-   {
-      SessionDelegate connectionConsumerSession = delivery.getConnectionConsumerSession();
-      
-      //If the delivery was obtained via a connection consumer we need to ack via that
-      //otherwise we just use this session
-      
-      SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
-      
-      sessionToUse.acknowledgeDelivery(delivery);      
-   }
    
-   private void cancelDelivery(SessionDelegate sess, DeliveryInfo delivery) throws Exception
-   {
-      SessionDelegate connectionConsumerSession = delivery.getConnectionConsumerSession();
-      
-      //If the delivery was obtained via a connection consumer we need to cancel via that
-      //otherwise we just use this session
-      
-      SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
-      
-      sessionToUse.cancelDelivery(new DefaultCancel(delivery.getDeliveryId(), delivery.getMessageProxy().getDeliveryCount()));      
-   }
-   
    public Object handleClosing(Invocation invocation) throws Throwable
    {
       MethodInvocation mi = (MethodInvocation)invocation;
@@ -176,6 +151,11 @@
          state.getClientAckList().clear();
       }
       
+      
+      //TODO - we should also cancel any deliveries remaining in any transaction for the session
+      //so the delivery count gets updated to the server, and not rely on the server side close
+      //cancelling them
+      
       return invocation.invokeNext();
    }
 
@@ -460,6 +440,30 @@
    {
       return (SessionState)((DelegateSupport)inv.getTargetObject()).getState();
    }
+   
+   private void ackDelivery(SessionDelegate sess, DeliveryInfo delivery) throws Exception
+   {
+      SessionDelegate connectionConsumerSession = delivery.getConnectionConsumerSession();
+      
+      //If the delivery was obtained via a connection consumer we need to ack via that
+      //otherwise we just use this session
+      
+      SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
+      
+      sessionToUse.acknowledgeDelivery(delivery);      
+   }
+   
+   private void cancelDelivery(SessionDelegate sess, DeliveryInfo delivery) throws Exception
+   {
+      SessionDelegate connectionConsumerSession = delivery.getConnectionConsumerSession();
+      
+      //If the delivery was obtained via a connection consumer we need to cancel via that
+      //otherwise we just use this session
+      
+      SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
+      
+      sessionToUse.cancelDelivery(new DefaultCancel(delivery.getDeliveryId(), delivery.getMessageProxy().getDeliveryCount()));      
+   }
 
    // Inner Classes -------------------------------------------------
    

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -169,7 +169,7 @@
 
       int consumerID = consumerDelegate.getID();
 
-      int prefetchSize = consumerDelegate.getPrefetchSize();
+      int bufferSize = consumerDelegate.getBufferSize();
 
       int maxDeliveries = consumerDelegate.getMaxDeliveries();
 
@@ -177,7 +177,7 @@
 
       ConsumerState consumerState =
          new ConsumerState(sessionState, consumerDelegate, dest, selector, noLocal,
-                           subscriptionName, consumerID, connectionConsumer, prefetchSize,
+                           subscriptionName, consumerID, connectionConsumer, bufferSize,
                            maxDeliveries, channelId);
 
       delegate.setState(consumerState);

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -71,12 +71,12 @@
    }
 
    // ConsumerDelegate implementation -------------------------------
-
+   
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void more()
+   public void cancelInflightMessages(long lastDeliveryId) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -85,6 +85,15 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
+   public void changeRate(float newRate)
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
    public void close() throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
@@ -162,16 +171,6 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
-   /**
-    * This invocation should either be handled by the client-side interceptor chain or by the
-    * server-side endpoint.
-    */
-   public void confirmDelivery(int count)
-   {
-      throw new IllegalStateException("This invocation should not be handled here!");
-   }
-
-
    // Public --------------------------------------------------------
 
    public String toString()
@@ -179,7 +178,7 @@
       return "ConsumerDelegate[" + id + "](ChannelId=" + this.channelId+")" ;
    }
    
-   public int getPrefetchSize()
+   public int getBufferSize()
    {
       return bufferSize;
    }
@@ -198,7 +197,7 @@
    {
       super.copyAttributes(newDelegate);
       
-      this.bufferSize = ((ClientConsumerDelegate)newDelegate).getPrefetchSize();
+      this.bufferSize = ((ClientConsumerDelegate)newDelegate).getBufferSize();
       
       this.maxDeliveries = ((ClientConsumerDelegate)newDelegate).getMaxDeliveries();
       

Modified: trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -21,9 +21,9 @@
   */
 package org.jboss.jms.client.remoting;
 
-import java.util.List;
 import java.util.Map;
 
+import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.server.endpoint.ClientDelivery;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.logging.Logger;
@@ -53,13 +53,21 @@
 {
    // Constants -----------------------------------------------------
 
-   protected static final Logger log = Logger.getLogger(CallbackManager.class);
+   protected static final Logger log;
 
    public static final String JMS_CALLBACK_SUBSYSTEM = "CALLBACK";
 
    // Static --------------------------------------------------------
 
    protected static CallbackManager theManager;
+   
+   private static boolean trace;      
+   
+   static
+   {
+      log = Logger.getLogger(CallbackManager.class);
+      trace = log.isTraceEnabled();
+   }
 
    // Attributes ----------------------------------------------------
 
@@ -79,16 +87,20 @@
    {
       MessagingMarshallable mm = (MessagingMarshallable)callback.getParameter();
       ClientDelivery dr = (ClientDelivery)mm.getLoad();
-      List msgs = dr.getMessages();
+      MessageProxy msg = dr.getMessage();
 
       MessageCallbackHandler handler = (MessageCallbackHandler)callbackHandlers.get(new Integer(dr.getConsumerId()));
 
       if (handler == null)
       {
-         throw new IllegalStateException("Cannot find handler for consumer: " + dr.getConsumerId());
+         //This is OK and can happen if the callback handler is deregistered on consumer close,
+         //but there are messages still in transit which arrive later.
+         //In this case it is just safe to ignore the message
+         if (trace) { log.trace(this + " callback handler not found, message arrived after consumer is closed"); }
+         return;
       }
 
-      handler.handleMessage(msgs);
+      handler.handleMessage(msg);
    }
 
    // Public --------------------------------------------------------

Deleted: trunk/src/main/org/jboss/jms/client/remoting/HandleMessageResponse.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/HandleMessageResponse.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/remoting/HandleMessageResponse.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -1,86 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.client.remoting;
-
-import java.io.DataInputStream;
-import java.io.DataOutputStream;
-
-import org.jboss.messaging.util.Streamable;
-
-/**
- * A HandleMessageResponse
- * 
- * This is the response the server gets after delivering messages to a client consumer
-
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- *
- * $Id$
- *
- */
-public class HandleMessageResponse implements Streamable
-{
-   private static final long serialVersionUID = 2500443290413453569L;
-
-   private boolean full;
-   
-   private int messagesAccepted;
-   
-   public HandleMessageResponse()
-   {      
-   }
-   
-   public HandleMessageResponse(boolean full, int messagesAccepted)
-   {
-      this.full = full;
-      
-      this.messagesAccepted = messagesAccepted;
-   }
-   
-   public boolean clientIsFull()
-   {
-      return full;
-   }
-   
-   public int getNumberAccepted()
-   {
-      return messagesAccepted;
-   }
-   
-   
-   // Streamable implementation
-   // ---------------------------------------------------------------
-   
-   public void write(DataOutputStream out) throws Exception
-   {
-      out.writeBoolean(full);
-      
-      out.writeInt(messagesAccepted);
-   }
-
-   public void read(DataInputStream in) throws Exception
-   {
-      full = in.readBoolean();
-      
-      messagesAccepted = in.readInt();
-   }
-}

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -165,12 +165,14 @@
    private int ackMode;
    private boolean closed;
    private Object mainLock;
-   private boolean serverSending;
-   private int bufferSize;
+   private int maxBufferSize;
+   private int minBufferSize;
    private QueuedExecutor sessionExecutor;
    private boolean listenerRunning;
    private int maxDeliveries;
    private long channelID;
+   private boolean startSendingMessageSent;
+   private long lastDeliveryId = -1;
         
    // Constructors --------------------------------------------------
 
@@ -185,7 +187,8 @@
          throw new IllegalArgumentException(this + " bufferSize must be > 0");
       }
               
-      this.bufferSize = bufferSize;
+      this.maxBufferSize = bufferSize;
+      this.minBufferSize = bufferSize / 2;
       buffer = new LinkedList();
       isConnectionConsumer = isCC;
       this.ackMode = ackMode;
@@ -193,77 +196,55 @@
       this.consumerDelegate = cons;
       this.consumerID = consumerID;
       this.channelID = channelID;
-      this.serverSending = true;
       mainLock = new Object();
       this.sessionExecutor = sessionExecutor;
       this.maxDeliveries = maxDeliveries;
+      this.startSendingMessageSent = true;
    }
         
    // Public --------------------------------------------------------
       
 
    /**
-    * Handles a list of messages sent from the server
-    * @param msgs The list of messages
-    * @return The number of messages handled (placeholder for future - now we always accept all messages)
-    *         or -1 if closed
+    * Handles a message sent from the server
+    * @param msgs The message
     */
-   public HandleMessageResponse handleMessage(List msgs) throws HandleCallbackException
+   public void handleMessage(MessageProxy msg)
    {                      
-      if (trace)
-      {
-         StringBuffer sb = new StringBuffer(this + " receiving [");
-         for(int i = 0; i < msgs.size(); i++)
-         {
-            sb.append(((MessageProxy)msgs.get(i)).getMessage().getMessageID());
-            if (i < msgs.size() - 1)
-            {
-               sb.append(",");
-            }
-         }
-         sb.append("] from the remoting layer");
-         log.trace(sb.toString());
-      }
+      if (trace) { log.trace("Receiving message " + msg + " from the remoting layer"); }
 
       synchronized (mainLock)
       {
          if (closed)
          {             
             // Ignore
-            return new HandleMessageResponse(false, 0);
+            if (trace) { log.trace(this + " is closed, so ignore message"); }
+            return;
          }
 
-         // Asynchronously confirm delivery on client
-
-         try
-         {
-            sessionExecutor.execute(new ConfirmDelivery(msgs.size()));
-         }
-         catch (InterruptedException e)
-         {
-            log.warn("Thread interrupted", e);
-         }
-
-         // Put the messages in the buffer and notify any waiting receive()
-         
-         processMessages(msgs);
+         msg.setSessionDelegate(sessionDelegate, isConnectionConsumer);
+                  
+         msg.setReceived();                  
                    
-         buffer.addAll(msgs);                  
+         //Add it to the buffer
+         buffer.add(msg);         
          
+         lastDeliveryId = msg.getDeliveryId();
+         
          if (trace) { log.trace(this + " added message(s) to the buffer"); }
          
-         boolean full = buffer.size() >= bufferSize;         
+         messageAdded();
          
-         messagesAdded();
-         
-         if (full)
+         if (buffer.size() >= maxBufferSize)
          {
-            serverSending = false;
             if (trace) { log.trace(this + " is full"); }
+            
+            //We are full. Send message to server to tell it to stop sending
+            
+            startSendingMessageSent = false;
+            
+            sendChangeRateMessage(0);
          }
-                                          
-         // For now we always accept all messages - in the future this may change
-         return new HandleMessageResponse(full, msgs.size());
       }
    }
          
@@ -282,6 +263,7 @@
          if (listener != null && !buffer.isEmpty())
          {  
             listenerRunning = true;
+            
             this.queueRunner(new ListenerRunner());
          }        
       }   
@@ -331,7 +313,9 @@
          for(Iterator i = buffer.iterator(); i.hasNext();)
          {
             MessageProxy mp = (MessageProxy)i.next();
+            
             DefaultCancel ack = new DefaultCancel(mp.getDeliveryId(), mp.getDeliveryCount());
+            
             cancels.add(ack);
          }
                
@@ -342,34 +326,6 @@
       
       if (trace) { log.trace(this + " closed"); }
    }
-   
-   private void waitForOnMessageToComplete()
-   {
-      // Wait for any onMessage() executions to complete
-
-      if (Thread.currentThread().equals(sessionExecutor.getThread()))
-      {
-         // the current thread already closing this MessageCallbackHandler (this happens when the
-         // session is closed from within the MessageListener.onMessage(), for example), so no need
-         // to register another Closer (see http://jira.jboss.org/jira/browse/JBMESSAGING-542)
-         return;
-      }
-
-      Future result = new Future();
-      
-      try
-      {
-         sessionExecutor.execute(new Closer(result));
-
-         if (trace) { log.trace(this + " blocking wait for Closer execution"); }
-         result.getResult();
-         if (trace) { log.trace(this + " got Closer result"); }
-      }
-      catch (InterruptedException e)
-      {
-         log.warn("Thread interrupted", e);
-      }
-   }
      
    /**
     * Method used by the client thread to get a Message, if available.
@@ -458,8 +414,6 @@
                   sessionDelegate.postDeliver(false);
                }
                
-               //postDeliver(sessionDelegate, isConnectionConsumer, false);
-               
                if (!m.getMessage().isExpired())
                {
                   if (trace) { log.trace(this + ": message " + m + " is not expired, pushing it to the caller"); }
@@ -486,11 +440,13 @@
       } 
       
       //This needs to be outside the lock
-      if (buffer.isEmpty() && !serverSending)
+      if (!startSendingMessageSent && buffer.size() <= minBufferSize)
       {
-         //The server has previously stopped sending because the buffer was full
-         //but now it is empty, so we tell the server to start sending again
-         consumerDelegate.more();
+         //Tell the server we need more messages - but we don't want to keep sending the message
+         //if we've already sent it - hence the check
+         startSendingMessageSent = true;
+            
+         sendChangeRateMessage(1);                    
       }
       
       m.incDeliveryCount();
@@ -498,7 +454,6 @@
       return m;
    }    
    
-
    public MessageListener getMessageListener()
    {
       return listener;      
@@ -525,16 +480,121 @@
       {
          buffer.addFirst(proxy);
          
-         messagesAdded();
+         messageAdded();
       }
    }
+   
+   public void copyState(MessageCallbackHandler newHandler)
+   {
+      synchronized (mainLock)
+      {
+         this.consumerID = newHandler.consumerID;
+         
+         this.consumerDelegate = newHandler.consumerDelegate;
+         
+         this.sessionDelegate = newHandler.sessionDelegate;
+         
+         this.buffer.clear();
+      }
+   }
+   
+   public long getLastDeliveryId()
+   {
+      synchronized (mainLock)
+      {
+         return lastDeliveryId;
+      }
+   }
      
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------
+            
+   // Private -------------------------------------------------------
    
-   protected long waitOnLock(Object lock, long waitTime) throws InterruptedException
+   private void waitForOnMessageToComplete()
    {
+      // Wait for any onMessage() executions to complete
+
+      if (Thread.currentThread().equals(sessionExecutor.getThread()))
+      {
+         // the current thread already closing this MessageCallbackHandler (this happens when the
+         // session is closed from within the MessageListener.onMessage(), for example), so no need
+         // to register another Closer (see http://jira.jboss.org/jira/browse/JBMESSAGING-542)
+         return;
+      }
+
+      Future result = new Future();
+      
+      try
+      {
+         sessionExecutor.execute(new Closer(result));
+
+         if (trace) { log.trace(this + " blocking wait for Closer execution"); }
+         result.getResult();
+         if (trace) { log.trace(this + " got Closer result"); }
+      }
+      catch (InterruptedException e)
+      {
+         log.warn("Thread interrupted", e);
+      }
+   }
+   
+   private void sendChangeRateMessage(float newRate) 
+   {
+      //FIXME - We should be able to execute this invocation as a true
+      //remoting asynchronous invocation - i.e. it is written to the transport
+      //and no response is waited for
+      //Therefore there is no need to execute it here on a separate thread.
+      //Unfortunately remoting does not currently support this so this
+      //will be SLOW now.
+      try
+      {
+         consumerDelegate.changeRate(newRate);
+      }
+      catch (JMSException e)
+      {
+         log.error("Failed to send changeRate message", e);
+      }
+   }
+   
+   private void queueRunner(ListenerRunner runner)
+   {
+      try
+      {
+         this.sessionExecutor.execute(runner);
+      }
+      catch (InterruptedException e)
+      {
+         log.warn("Thread interrupted", e);
+      }
+   }
+   
+   private void messageAdded()
+   {
+      // If we have a thread waiting on receive() we notify it
+      if (receiverThread != null)
+      {
+         if (trace) { log.trace(this + " notifying receiver thread"); }            
+         mainLock.notify();
+      }     
+      else if (listener != null)
+      { 
+         // We have a message listener
+         if (!listenerRunning)
+         {
+            listenerRunning = true;
+
+            if (trace) { log.trace(this + " scheduled a new ListenerRunner"); }
+            this.queueRunner(new ListenerRunner());
+         }     
+         
+         //TODO - Execute onMessage on same thread for even better throughput 
+      }
+   }
+   
+   private long waitOnLock(Object lock, long waitTime) throws InterruptedException
+   {
       long start = System.currentTimeMillis();
       
       // Wait for last message to arrive
@@ -545,6 +605,7 @@
       if (waited < waitTime)
       {
          waitTime = waitTime - waited;
+         
          return waitTime;
       }
       else
@@ -553,7 +614,7 @@
       }     
    }
         
-   protected MessageProxy getMessage(long timeout) throws JMSException
+   private MessageProxy getMessage(long timeout) throws JMSException
    {
       if (timeout == -1)
       {
@@ -608,62 +669,8 @@
       return m;
    }
    
-   protected void processMessages(List msgs)
-   {
-      Iterator iter = msgs.iterator();
-      
-      while (iter.hasNext())
-      {         
-         MessageProxy msg = (MessageProxy)iter.next();
-      
-         // If this is the handler for a connection consumer we don't want to set the session
-         // delegate since this is only used for client acknowledgement which is illegal for a
-         // session used for an MDB
-         msg.setSessionDelegate(sessionDelegate, isConnectionConsumer);
-                  
-         msg.setReceived();
-      }
-   }
-   
-   // Private -------------------------------------------------------
-   
-   private void queueRunner(ListenerRunner runner)
-   {
-      try
-      {
-         this.sessionExecutor.execute(runner);
-      }
-      catch (InterruptedException e)
-      {
-         log.warn("Thread interrupted", e);
-      }
-   }
-   
-   private void messagesAdded()
-   {
-      // If we have a thread waiting on receive() we notify it
-      if (receiverThread != null)
-      {
-         if (trace) { log.trace(this + " notifying receiver thread"); }            
-         mainLock.notify();
-      }     
-      else if (listener != null)
-      { 
-         // We have a message listener
-         if (!listenerRunning)
-         {
-            listenerRunning = true;
-
-            if (trace) { log.trace(this + " scheduled a new ListenerRunner"); }
-            this.queueRunner(new ListenerRunner());
-         }     
-         
-         //TODO - Execute onMessage on same thread for even better throughput 
-      }
-   }
-   
    // Inner classes -------------------------------------------------   
-   
+         
    /*
     * This class is used to put on the listener executor to wait for onMessage
     * invocations to complete when closing
@@ -703,7 +710,9 @@
             if (listener == null)
             {
                listenerRunning = false;
+               
                if (trace) { log.trace("no listener, returning"); }
+               
                return;
             }
             
@@ -712,6 +721,7 @@
             if (buffer.isEmpty())
             {
                listenerRunning = false;
+               
                if (trace) { log.trace("no messages in buffer, marking listener as not running"); }
             }
             else
@@ -745,65 +755,23 @@
             } 
          }
          
+         
+         //Tell the server we need more messages - but we don't want to keep sending the message
+         //if we've already sent it - hence the check
+         if (!startSendingMessageSent && buffer.size() <= minBufferSize)
+         {                    
+            startSendingMessageSent = true;
+            
+            sendChangeRateMessage(1);
+         } 
+         
          if (again)
          {
             // Queue it up again
             queueRunner(this);
-         }
-         else
-         {
-            if (!serverSending)
-            {
-               // Ask server for more messages
-               try
-               {
-                  consumerDelegate.more();
-               }
-               catch (JMSException e)
-               {
-                  log.error("Failed to execute more()", e);
-               }
-               return;
-            }
-         }
+         }                                               
       }
-   }
-
-   /*
-    * Used to asynchronously confirm to the server message arrival (delivery) on client.
-    */
-   private class ConfirmDelivery implements Runnable
-   {
-      int count;
-
-      ConfirmDelivery(int count)
-      {
-         this.count = count;
-      }
-
-      public void run()
-      {
-         if (trace) { log.trace("confirming delivery on client of " + count + " message(s)"); }
-         consumerDelegate.confirmDelivery(count);
-      }
-   }
-   
-   public void copyState(MessageCallbackHandler newHandler)
-   {
-      synchronized (mainLock)
-      {
-         this.consumerID = newHandler.consumerID;
-         
-         this.consumerDelegate = newHandler.consumerDelegate;
-         
-         this.sessionDelegate = newHandler.sessionDelegate;
-         
-         this.serverSending = false;
-         
-         this.buffer.clear();
-      }
-   }
-
+   }   
 }
 
 

Modified: trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -55,7 +55,7 @@
 
    private MessageCallbackHandler messageCallbackHandler;
 
-   private int prefetchSize;
+   private int bufferSize;
    
    private SessionState parent;
    
@@ -68,7 +68,7 @@
    
    public ConsumerState(SessionState parent, ConsumerDelegate delegate, Destination dest,
                         String selector, boolean noLocal, String subscriptionName, int consumerID,
-                        boolean isCC, int prefetchSize, int maxDeliveries, long channelId)
+                        boolean isCC, int bufferSize, int maxDeliveries, long channelId)
    {
       super(parent, (DelegateSupport)delegate);
       children = Collections.EMPTY_SET;
@@ -77,7 +77,7 @@
       this.noLocal = noLocal;
       this.consumerID = consumerID;
       this.isConnectionConsumer = isCC;
-      this.prefetchSize = prefetchSize;
+      this.bufferSize = bufferSize;
       this.subscriptionName=subscriptionName;
       this.maxDeliveries = maxDeliveries;
       this.channelId = channelId;
@@ -134,9 +134,9 @@
       return parent.getVersionToUse();
    }
 
-   public int getPrefetchSize()
+   public int getBufferSize()
    {
-      return prefetchSize;
+      return bufferSize;
    }
 
    public HierarchicalState getParent()

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -223,12 +223,7 @@
    {
       callbackHandlers.remove(new Integer(handler.getConsumerId()));
    }
-   
-   public List getCallbackHandlers()
-   {
-      return new ArrayList(callbackHandlers.values());
-   }
-   
+      
    public int getSessionId()
    {
       return sessionId;

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ClientDelivery.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -23,9 +23,6 @@
 
 import java.io.DataInputStream;
 import java.io.DataOutputStream;
-import java.util.ArrayList;
-import java.util.Iterator;
-import java.util.List;
 
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
@@ -35,7 +32,7 @@
 /**
  * 
  * A ClientDelivery
- * Encapsulates a delivery of some messages to a client consumer
+ * Encapsulates a delivery of a messages to a client consumer
  * 
  * There is no need to specify the server id since the client side CallbackManager is
  * unique to the remoting connection
@@ -54,7 +51,7 @@
    
    // Attributes ----------------------------------------------------
    
-   private List msgs;
+   private MessageProxy msg;
          
    private int consumerId;
     
@@ -64,9 +61,9 @@
    {      
    }
 
-   public ClientDelivery(List msgs, int consumerId)
+   public ClientDelivery(MessageProxy msg, int consumerId)
    {
-      this.msgs = msgs;
+      this.msg = msg;
       
       this.consumerId = consumerId;
    }
@@ -78,55 +75,37 @@
    {
       out.writeInt(consumerId);
       
-      out.writeInt(msgs.size());
+      out.writeByte(msg.getMessage().getType());
+
+      out.writeInt(msg.getDeliveryCount());
       
-      Iterator iter = msgs.iterator();
-      
-      while (iter.hasNext())
-      {
-         MessageProxy mp = (MessageProxy)iter.next();
-         
-         out.writeByte(mp.getMessage().getType());
+      out.writeLong(msg.getDeliveryId());
 
-         out.writeInt(mp.getDeliveryCount());
-         
-         out.writeLong(mp.getDeliveryId());
-
-         mp.getMessage().write(out);
-      }      
+      msg.getMessage().write(out);          
    }
 
    public void read(DataInputStream in) throws Exception
    {
       consumerId = in.readInt();
       
-      int numMessages = in.readInt();
+      byte type = in.readByte();
       
-      msgs = new ArrayList(numMessages);
+      int deliveryCount = in.readInt();
       
-      for (int i = 0; i < numMessages; i++)
-      {
-         byte type = in.readByte();
-         
-         int deliveryCount = in.readInt();
-         
-         long deliveryId = in.readLong();
-         
-         JBossMessage m = (JBossMessage)MessageFactory.createMessage(type);
+      long deliveryId = in.readLong();
+      
+      JBossMessage m = (JBossMessage)MessageFactory.createMessage(type);
 
-         m.read(in);
+      m.read(in);
 
-         MessageProxy md = JBossMessage.createThinDelegate(deliveryId, m, deliveryCount);
-         
-         msgs.add(md);
-      }      
+      msg = JBossMessage.createThinDelegate(deliveryId, m, deliveryCount); 
    }
 
    // Public --------------------------------------------------------
    
-   public List getMessages()
+   public MessageProxy getMessage()
    {
-      return msgs;
+      return msg;
    }
    
    public int getConsumerId()

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ConsumerEndpoint.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -39,23 +39,15 @@
 public interface ConsumerEndpoint extends Closeable
 {  
    /**
-    * If the client buffer has previously become full because the server was sending at a faster
-    * rate than the client could consume, then the server will stop sending messages. When the
-    * client has emptied the buffer it then needs to inform the server that it can receive more
-    * messages by calling this method.
-    *
-    * @throws JMSException
+    * Sent to the server to specify a new maximum rate at which to send messages at
     */
-   void more() throws JMSException;
-
+   void changeRate(float newRate) throws JMSException;
+   
+   
    /**
-    * The server consumer endpoint needs to know at any time how messages are in transit between
-    * server and client. That is why it needs to receive confirmations every time the client
-    * received one (or more) messages. The confirmation is sent asynchronously from client to server.
-    * This is NOT a consumption acknowledgment.
-    *
-    * @param count - the number of messages received by the client in one batch.
+    * Cancels any deliveries with a delivery id > lastDeliveryId - these are inflight
+    * @param lastDeliveryId
     */
-   void confirmDelivery(int count);
+   void cancelInflightMessages(long lastDeliveryId) throws JMSException;
 
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -21,10 +21,6 @@
  */
 package org.jboss.jms.server.endpoint;
 
-
-import java.util.ArrayList;
-import java.util.List;
-
 import javax.jms.IllegalStateException;
 import javax.jms.InvalidSelectorException;
 import javax.jms.JMSException;
@@ -33,8 +29,6 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.selector.Selector;
-import org.jboss.jms.server.ConnectionManager;
-import org.jboss.jms.server.QueuedExecutorPool;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.util.ExceptionUtil;
@@ -49,15 +43,18 @@
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.Transaction;
-import org.jboss.messaging.util.Future;
 import org.jboss.remoting.callback.Callback;
+import org.jboss.remoting.callback.HandleCallbackException;
+import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
 
-import EDU.oswego.cs.dl.util.concurrent.Executor;
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
-
 /**
- * Concrete implementation of ConsumerEndpoint. Lives on the boundary between Messaging Core and the
+ * Concrete implementation of ConsumerEndpoint.
+ * 
+ * Lives on the boundary between Messaging Core and the
  * JMS Facade.
+ * 
+ * Handles delivery of messages from the server to the client side consumer.
+ * 
  *
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
@@ -73,8 +70,6 @@
 
    // Static --------------------------------------------------------  
 
-   private static final int MESSAGES_IN_TRANSIT_WAIT_COUNT = 100;
-
    // Attributes ----------------------------------------------------
 
    private boolean trace = log.isTraceEnabled();
@@ -86,84 +81,55 @@
    private String queueName;
 
    private ServerSessionEndpoint sessionEndpoint;
+   
+   private ServerInvokerCallbackHandler callbackHandler;
+   
+   private byte versionToUse;
 
    private boolean noLocal;
 
    private Selector messageSelector;
 
    private JBossDestination destination;
+   
+   private boolean started;
+   
+   //This lock protects starting and stopping
+   private Object startStopLock;
 
-   private List toDeliver;
-
    // Must be volatile
-   private volatile boolean clientConsumerFull;
-
-   // Must be volatile
-   private volatile boolean bufferFull;
-
-   // Must be volatile
-   private volatile boolean started;
-
-   // No need to be volatile - is protected by lock
-   private boolean closed;
-
-   private Executor executor;
-
-   private int prefetchSize;
-
-   private Object lock;
-
-   private Object messagesInTransitLock;
+   private volatile boolean clientAccepting;
    
-   private int messagesInTransitCount; // access only from a region guarded by messagesInTransitLock
-   
    // Constructors --------------------------------------------------
 
    ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
                          ServerSessionEndpoint sessionEndpoint,
-                         String selector, boolean noLocal, JBossDestination dest,
-                         int prefetchSize)
-      throws InvalidSelectorException
+                         String selector, boolean noLocal, JBossDestination dest)
+                         throws InvalidSelectorException
    {
       if (trace) { log.trace("constructing consumer endpoint " + id); }
 
       this.id = id;
+      
       this.messageQueue = messageQueue;
+      
       this.queueName = queueName;
+      
       this.sessionEndpoint = sessionEndpoint;
-      this.prefetchSize = prefetchSize;
       
-      // We always created with clientConsumerFull = true. This prevents the SCD sending messages to
-      // the client before the client has fully finished creating the MessageCallbackHandler.
-      this.clientConsumerFull = true;
-
-      // We allocate an executor from the rotating pool for each consumer based on it's id
-      // This gives better latency than each consumer for the destination using the same
-      // executor
-      QueuedExecutorPool pool =
-         sessionEndpoint.getConnectionEndpoint().getServerPeer().getQueuedExecutorPool();
-
-      this.executor = (QueuedExecutor)pool.get();
-             
-      // Note that using a PooledExecutor with a linked queue is not sufficient to ensure that
-      // deliveries for the same consumer happen serially, since even if they are queued serially
-      // the actual deliveries can happen in parallel, resulting in a later one "overtaking" an
-      // earlier non-deterministicly depending on thread scheduling.
-      // Consequently we use a QueuedExecutor to ensure the deliveries happen sequentially. We do
-      // not want each ServerConsumerEndpoint instance to have its own instance - since we would
-      // end up using too many threads, neither do we want to share the same instance amongst all
-      // consumers - we do not want to serialize delivery to all consumers. So we maintain a bag of
-      // QueuedExecutors and give them out to consumers as required. Different consumers can end up
-      // using the same queuedexecutor concurrently if there are a lot of active consumers.
-
+      this.callbackHandler = sessionEndpoint.getConnectionEndpoint().getCallbackHandler();
+      
+      this.versionToUse = sessionEndpoint.getConnectionEndpoint().getUsingVersion();
+            
       this.noLocal = noLocal;
       
       this.destination = dest;
       
-      this.toDeliver = new ArrayList();
+      //Always start as false - wait for consumer to initiate
+      this.clientAccepting = false;
       
-      this.lock = new Object();
-
+      this.startStopLock = new Object();
+      
       if (selector != null)
       {
          if (trace) log.trace("creating selector:" + selector);
@@ -179,9 +145,6 @@
       // prompt delivery
       promptDelivery();
 
-      messagesInTransitLock = new Object();
-      messagesInTransitCount = 0;
-      
       log.debug(this + " constructed");
    }
 
@@ -195,30 +158,26 @@
       if (trace) { log.trace(this + " receives " + ref + " for delivery"); }
       
       // This is ok to have outside lock - is volatile
-      if (bufferFull)
+      if (!clientAccepting)
       {
-         // We buffer a maximum of PREFETCH_LIMIT messages at once
+         if (trace) { log.trace(this + " the client is not currently accepting messages"); }
          
-         if (trace) { log.trace(this + " has reached prefetch size will not accept any more references"); }
-         
          return null;
       }
-       
-      // Need to synchronized around the whole block to prevent setting started = false
-      // but handle is already running and a message is deposited during the stop procedure.
-      synchronized (lock)
-      {  
+        
+      synchronized (startStopLock)
+      {         
          // If the consumer is stopped then we don't accept the message, it should go back into the
          // queue for delivery later.
          if (!started)
          {
             if (trace) { log.trace(this + " NOT started yet!"); }
-
+   
             return null;
          }
-
+   
          if (trace) { log.trace(this + " has the main lock, preparing the message for delivery"); }
-
+   
          JBossMessage message = (JBossMessage)ref.getMessage();
          
          boolean selectorRejected = !this.accept(message);
@@ -235,8 +194,8 @@
             return delivery;
          }
          
-         long deliveryId = sessionEndpoint.addDelivery(delivery);
-
+         long deliveryId = sessionEndpoint.addDelivery(delivery, id);
+   
          // We don't send the message as-is, instead we create a MessageProxy instance. This allows
          // local fields such as deliveryCount to be handled by the proxy but global data to be
          // fielded by the same underlying Message instance. This allows us to avoid expensive
@@ -244,37 +203,42 @@
    
          MessageProxy mp = JBossMessage.createThinDelegate(deliveryId, message, ref.getDeliveryCount());
     
-         // Add the proxy to the list to deliver
-                           
-         toDeliver.add(mp);     
-          
-         bufferFull = toDeliver.size() >= prefetchSize;
-             
-         if (!clientConsumerFull)
-         {            
-            try
-            {
-               Deliverer deliverer = new Deliverer();
-               if (trace) { log.trace(this + " scheduling a new " + deliverer); }
-               this.executor.execute(deliverer);
-            }
-            catch (InterruptedException e)
-            {
-               log.warn("Thread interrupted", e);
-            }
+         //We send the message to the client on the current thread.
+         //The message is written onto the transport and then the thread returns immediately
+         //without waiting for a response
+         
+         //FIXME - how can we ensure that a later send doesn't overtake an earlier send - this might
+         //happen if they are using different underlying TCP connections (e.g. from pool)
+         
+         ClientDelivery del = new ClientDelivery(mp, id);
+         
+         MessagingMarshallable mm = new MessagingMarshallable(versionToUse, del);
+         
+         Callback callback = new Callback(mm);
+   
+         try
+         {
+            //FIXME - we need to use the asynch callback API, this is the Sync one
+            callbackHandler.handleCallback(callback);
          }
+         catch (HandleCallbackException e)
+         {
+            log.error("Failed to handle callback", e);
+            
+            return null;
+         }
                              
-         return delivery;              
+         return delivery;      
       }
    }      
-   
 
    // Filter implementation -----------------------------------------
 
    public boolean accept(Routable r)
    {
       boolean accept = true;
-      if (this.destination.isQueue())
+      
+      if (destination.isQueue())
       {
          // For subscriptions message selection is handled in the Subscription itself
          // we do not want to do the check twice
@@ -323,9 +287,11 @@
    {      
       try
       {
+         if (trace) { log.trace(this + " close"); }
+         
          localClose();
          
-         sessionEndpoint.removeConsumer(id);
+         sessionEndpoint.removeConsumer(id);         
       }   
       catch (Throwable t)
       {
@@ -335,78 +301,66 @@
            
    // ConsumerEndpoint implementation -------------------------------
    
-   /*
-    * This is called by the client consumer to tell the server to wake up and start sending more
-    * messages if available
-    */
-   public void more() throws JMSException
-   {           
+   
+   public void changeRate(float newRate) throws JMSException
+   {
+      if (trace) { log.trace(this + " changeRate: " + newRate); }
+      
       try
-      {
-         // Set clientConsumerFull to false.
-         //
-         // NOTE! This must be done using a Runnable on the delivery executor - this is to prevent
-         // the following race condition:
-         //  1) Messages are delivered to the client, causing it to be full.
-         //  2) The messages are consumed very quickly on the client causing more() to be called.
-         //  3) more() hits the server BEFORE the deliverer thread has returned from delivering to
-         //     the client causing clientConsumerFull to be set to false and adding a deliverer to
-         //     the queue.
-         //  4) The deliverer thread returns and sets clientConsumerFull to true.
-         //  5) The next deliverer runs but doesn't do anything since clientConsumerFull = true even
-         //     though the client needs messages.
-
-         executor.execute(new Runnable()
-         {
-            public void run()
-            {
-               if (trace) { log.trace(ServerConsumerEndpoint.this + " is notified that client wants more() messages"); }
-               clientConsumerFull = false;
-            }
-         });
-                           
-         // Run a deliverer to deliver any existing ones
-         executor.execute(new Deliverer());
+      {      
+         //For now we just support a binary on/off
+         //The client will send newRate = 0, to say it does not want any more messages when it's client side
+         //buffer gets full
+         //or it will send an arbitrary non zero number to say it does want more messages, when it's client side
+         //buffer empties to half it's full size.
+         //Note the client does not wait until the client side buffer is empty before sending a newRate(+ve)
+         //message since this would add extra latency.
          
-         // TODO Why do we need to wait for it to execute? Why not just return immediately?
+         //In the future we can fine tune this by allowing the client to specify an actual rate in the newRate value
+         //so this is basically a placeholder for the future so we don't have to change the wire format when
+         //we support it
          
-         // Now wait for it to execute
-         Future result = new Future();
-         this.executor.execute(new Waiter(result));
-         result.getResult();
-                  
-         // Now we know the deliverer has delivered any outstanding messages to the client buffer
+         //No need to synchronize - clientAccepting is volatile
          
-         messageQueue.deliver(false);
-      }
-      catch (InterruptedException e)
-      {
-         log.warn("Thread interrupted", e);
-      }       
+         if (newRate == 0)
+         {
+            clientAccepting = false;
+         }
+         else
+         {
+            clientAccepting = true;
+            
+            promptDelivery();
+         }            
+      }   
       catch (Throwable t)
       {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " more");
+         throw ExceptionUtil.handleJMSInvocation(t, this + " changeRate");
       }
    }
-
-   public void confirmDelivery(int count)
+   
+   /*
+    * This method is always called between closing() and close() being called
+    * Instead of having a new method we could perhaps somehow pass the last delivery id
+    * in with closing - then we don't need another message
+    */
+   public void cancelInflightMessages(long lastDeliveryId) throws JMSException
    {
-      synchronized(messagesInTransitLock)
+      if (trace) { log.trace(this + " cancelInflightMessages: " + lastDeliveryId); }
+      
+      try
+      {      
+         //Cancel all deliveries made by this consumer with delivery id > lastDeliveryId
+         
+         sessionEndpoint.cancelDeliveriesForConsumerAfterDeliveryId(id, lastDeliveryId);      
+      }   
+      catch (Throwable t)
       {
-         messagesInTransitCount -= count;
-
-         if (trace) { log.trace("confirming delivery of " + count + " message(s), messages in transit " + messagesInTransitCount); }
-
-         if (messagesInTransitCount < 0)
-         {
-            log.error(this + " has an invalid messages in transit count (" +
-                      messagesInTransitCount + ")");
-         }
-
-         messagesInTransitLock.notifyAll();
-      }
+         throw ExceptionUtil.handleJMSInvocation(t, this + " cancelInflightMessages");
+      }            
    }
    
+   
    public boolean isClosed() throws JMSException
    {
       throw new IllegalStateException("isClosed should never be handled on the server side");
@@ -433,48 +387,38 @@
    
    void localClose() throws Throwable
    {      
-      synchronized (lock)
-      { 
-         if (trace) { log.trace(this + " grabbed the main lock in close() " + this); }
+      if (trace) { log.trace(this + " grabbed the main lock in close() " + this); }
 
-         messageQueue.remove(this); 
+      messageQueue.remove(this); 
+      
+      JMSDispatcher.instance.unregisterTarget(new Integer(id));
+      
+      // If this is a consumer of a non durable subscription then we want to unbind the
+      // subscription and delete all its data.
+
+      if (destination.isTopic())
+      {
+         PostOffice postOffice = 
+            sessionEndpoint.getConnectionEndpoint().getServerPeer().getPostOfficeInstance();
          
-         JMSDispatcher.instance.unregisterTarget(new Integer(id));
-         
-         // If this is a consumer of a non durable subscription then we want to unbind the
-         // subscription and delete all its data.
+         Binding binding = postOffice.getBindingForQueueName(queueName);
 
-         if (destination.isTopic())
+         //Note binding can be null since there can many competing subscribers for the subscription  - 
+         //in which case the first will have removed the subscription and subsequently
+         //ones won't find it
+         
+         if (binding != null && !binding.getQueue().isRecoverable())
          {
-            PostOffice postOffice = 
-               sessionEndpoint.getConnectionEndpoint().getServerPeer().getPostOfficeInstance();
-            
-            Binding binding = postOffice.getBindingForQueueName(queueName);
-
-            //Note binding can be null since there can many competing subscribers for the subscription  - 
-            //in which case the first will have removed the subscription and subsequently
-            //ones won't find it
-            
-            if (binding != null && !binding.getQueue().isRecoverable())
-            {
-               postOffice.unbindQueue(queueName);
-            }
+            postOffice.unbindQueue(queueName);
          }
-                     
-         closed = true;
       }
+     
    }        
            
    void start()
    {             
-      synchronized (lock)
-      {
-         // Can't start or stop it if it is closed.
-         if (closed)
-         {
-            return;
-         }
-         
+      synchronized (startStopLock)
+      {      
          if (started)
          {
             return;
@@ -482,96 +426,53 @@
          
          started = true;
       }
-      
+            
       // Prompt delivery
       promptDelivery();
    }
    
    void stop() throws Throwable
-   {     
-      // We need to:
-      // - Stop accepting any new messages in the SCE.
-      // - Flush any messages from the SCE to the buffer.
-      // If the client consumer is now full, then we need to cancel the ones in the toDeliver list.
-
-      // We need to lock since otherwise we could set started to false but the handle method was
-      // already executing and messages might get deposited after.
-      synchronized (lock)
-      {
+   {           
+      synchronized (startStopLock)
+      {         
          if (!started)
          {
             return;
          }
          
-         started = false;
-      }
-      
-      // Now we know no more messages will be accepted in the SCE.
-            
-      try
-      {
-         // Flush any messages waiting to be sent to the client.
-         this.executor.execute(new Deliverer());
+         started = false;                  
          
-         if (trace) { log.trace(this + " flushed all remaining messages (if any) to the client"); }
-
-         // Now we know any deliverer has delivered any outstanding messages to the client buffer.
-      }
-      catch (InterruptedException e)
-      {
-         log.warn("Thread interrupted", e);
-      }
-
-      // Make sure there are no messages in transit between server and client
-
-      synchronized(messagesInTransitLock)
-      {
-         int loopCount = 0;
-         while(messagesInTransitCount > 0 && loopCount < MESSAGES_IN_TRANSIT_WAIT_COUNT)
-         {
-            log.debug(this + " waiting for " + messagesInTransitCount + " message(s) in transit " +
-                      "to reach the client, " + (loopCount + 1) + " lock grab attempts.");
-            messagesInTransitLock.wait(500);
-            loopCount ++;
-         }
-
-         if (loopCount >= MESSAGES_IN_TRANSIT_WAIT_COUNT)
-         {
-            throw new IllegalStateException("Maximum number of lock grab attempts exceeded, " +
-                                            "giving up to wait for messages in transit");
-         }
-
-         if (trace) { log.trace(this + " has no messages in transit"); }
-      }
-
-      // Now we know that there are no in flight messages on the way to the client consumer, but
-      // there may be messages still in the toDeliver list since the client consumer might be full,
-      // so we need to cancel these.
-            
-      if (!toDeliver.isEmpty())
-      { 
-         synchronized (lock)
-         {
-            //Cancel in reverse order
-            for (int i = toDeliver.size() - 1; i >= 0; i--)
-            {
-               MessageProxy proxy = (MessageProxy)toDeliver.get(i);
-
-               sessionEndpoint.cancelDelivery(proxy.getDeliveryId());
-            }
-         }
-                 
-         toDeliver.clear();
+         /*
+          * 
+         Any message deliveries already transit to the consumer, will just
+         be ignored by the MessageCallbackHandler since it will be closed 
+   
+         To clarify, the close protocol (from connection) is as follows:
+                  
+         1) MessageCallbackHandler::close() - any messages in buffer are cancelled to the server session, and any
+            subsequent receive messages will be ignored         
          
-         bufferFull = false;
-      }      
-      
-      //Need to prompt delivery
-      promptDelivery();
+         2) ServerConsumerEndpoint::closing() causes stop() this flushes any deliveries yet to deliver to the client callback handler
+         
+         3) MessageCallbackHandler::cancelInflightMessages(long lastDeliveryId) - any deliveries after lastDeliveryId
+         for the consumer will be considered in flight and cancelled.
+         
+         4) ServerConsumerEndpoint:close() - endpoint is deregistered
+         
+         5) Session.close() - acks or cancels any remaining deliveries in the SessionState as appropriate
+         
+         6) ServerSessionEndpoint::close() - cancels any remaining deliveries and deregisters session
+         
+         7) Client side session executor is shutdown
+         
+         8) ServerConnectionEndpoint::close() - connection is deregistered.
+         
+         9) Remoting connection listener is removed and remoting connection stopped.
+         
+         */
+      }
    }
-   
-   
-   
+         
    // Protected -----------------------------------------------------         
       
    // Private -------------------------------------------------------
@@ -582,122 +483,5 @@
    }
    
    // Inner classes -------------------------------------------------   
-   
-   /*
-    * Delivers messages to the client 
-    * TODO - We can make this a bit more intelligent by letting it measure the rate
-    * the client is consuming messages and send messages at that rate.
-    * This would mean the client consumer wouldn't be full so often and more wouldn't have to be called
-    * This should give higher throughput.
-    */
-   private class Deliverer implements Runnable
-   {
-      public void run()
-      {
-         // Is there anything to deliver? This is ok outside lock - is volatile.
-         if (clientConsumerFull)
-         {
-            if (trace) { log.trace(this + " client consumer full, do nothing"); }
-            return;
-         }
-         
-         List list = null;
-             
-         synchronized (lock)
-         {
-            if (trace) { log.trace(this + " has the main lock, attempting delivery"); }
-
-            if (!toDeliver.isEmpty())
-            {
-               list = new ArrayList(toDeliver);
-               toDeliver.clear();
-               bufferFull = false;
-            }
-         }
-                                                           
-         if (list == null)
-         {
-            if (trace) { log.trace(this + " has a null list, returning"); }
-            return;
-         }
-
-         ServerConnectionEndpoint connection =
-            ServerConsumerEndpoint.this.sessionEndpoint.getConnectionEndpoint();
-         
-         ClientDelivery del = new ClientDelivery(list, id);
-         MessagingMarshallable mm = new MessagingMarshallable(connection.getUsingVersion(), del);
-         Callback callback = new Callback(mm);
-
-         try
-         {
-            if (trace)
-            {
-               StringBuffer sb = new StringBuffer(ServerConsumerEndpoint.this + " handing [");
-               for(int i = 0; i < list.size(); i++)
-               {
-                  sb.append(((MessageProxy)list.get(i)).getMessage().getMessageID());
-                  if (i < list.size() - 1)
-                  {
-                     sb.append(",");
-                  }
-               }
-               sb.append("] over to the remoting layer");
-               log.trace(sb.toString());
-            }
-            
-            synchronized(messagesInTransitLock)
-            {
-               connection.getCallbackHandler().handleCallback(callback);
-               messagesInTransitCount += list.size();
-            }
-
-            if (trace) { log.trace(ServerConsumerEndpoint.this + " handed messages over to the remoting layer"); }
-
-            // We are NOT using Remoting's facility of acknowledging callbacks. A callback is sent
-            // asynchronously, and there is no confirmation that the callback reached the client or
-            // not.
-
-            // TODO Previously, synchronous server-to-client invocations were used by the client
-            // to report back whether is full or not. This cannot be achieved with asynchronous
-            // callbacks, so the client must explicitely sent this information to the server,
-            // with an invocation on its own.
-         }
-         catch(Throwable t)
-         {
-            log.warn("Failed to deliver the message to the client. See the server log for more details.");
-            log.debug(ServerConsumerEndpoint.this + " failed to deliver the message to the client.", t);
-
-            ConnectionManager mgr = connection.getServerPeer().getConnectionManager();
-
-            mgr.handleClientFailure(connection.getRemotingClientSessionId());
-         }
-      }
-
-      public String toString()
-      {
-         return "Deliverer[" + Integer.toHexString(hashCode()) + "]";
-      }
-   }
-   
-   /*
-    * The purpose of this class is to put it on the QueuedExecutor and wait for it to run
-    * We can then ensure that all the Runnables in front of it on the queue have also executed
-    * We cannot just call shutdownAfterProcessingCurrentlyQueuedTasks() since the
-    * QueueExecutor might be share by other consumers and we don't want to wait for their
-    * tasks to complete
-    */
-   private static class Waiter implements Runnable
-   {
-      Future result;
-      
-      Waiter(Future result)
-      {
-         this.result = result;
-      }
-      
-      public void run()
-      {
-         result.setResult(null);
-      }
-   }   
+     
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -29,6 +29,7 @@
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
+import java.util.LinkedList;
 import java.util.List;
 import java.util.Map;
 import java.util.Set;
@@ -502,7 +503,7 @@
                
                if (trace) { log.trace(this + " Recovered delivery " + deliveryId + ", " + del); }
                
-               deliveries.put(new Long(deliveryId), del);
+               deliveries.put(new Long(deliveryId), new DeliveryRecord(del, -1));
             }
          }
          
@@ -702,6 +703,40 @@
    }
 
    // Package protected ---------------------------------------------
+      
+   void cancelDeliveriesForConsumerAfterDeliveryId(int consumerId, long lastDeliveryId) throws Throwable
+   {
+      //Need to cancel in reverse
+      
+      LinkedList toCancel = new LinkedList();
+      
+      Iterator iter = deliveries.entrySet().iterator();
+            
+      while (iter.hasNext())
+      {
+         Map.Entry entry = (Map.Entry)iter.next();
+         
+         Long deliveryId = (Long)entry.getKey();
+         
+         DeliveryRecord record = (DeliveryRecord)entry.getValue();
+         
+         if (record.consumerId == consumerId && deliveryId.longValue() > lastDeliveryId)
+         {
+            iter.remove();
+            
+            toCancel.addFirst(record);
+         }
+      }
+      
+      iter = toCancel.iterator();
+      
+      while (iter.hasNext())
+      {
+         DeliveryRecord record = (DeliveryRecord)iter.next();
+         
+         record.del.cancel();
+      }
+   }
    
    void removeBrowser(int browserId) throws Exception
    {
@@ -786,11 +821,11 @@
          
          if (trace) { log.trace(this + " cancelling delivery with delivery id: " + entry.getKey()); }
          
-         Delivery del = (Delivery)entry.getValue();
+         DeliveryRecord rec = (DeliveryRecord)entry.getValue();
          
-         del.cancel();
+         rec.del.cancel();
          
-         channels.add(del.getObserver());
+         channels.add(rec.del.getObserver());
       }
       
       promptDelivery(channels);
@@ -806,26 +841,26 @@
    
    void cancelDelivery(long deliveryId) throws Throwable
    {
-      Delivery del = (Delivery)deliveries.remove(new Long(deliveryId));
+      DeliveryRecord rec = (DeliveryRecord)deliveries.remove(new Long(deliveryId));
       
-      if (del == null)
+      if (rec == null)
       {
          throw new IllegalStateException("Cannot find delivery to cancel " + deliveryId);
       }
       
-      del.cancel();
+      rec.del.cancel();
    }
    
-   long addDelivery(Delivery del)
+   long addDelivery(Delivery del, int consumerId)
    {
       long deliveryId = deliveryIdSequence.increment();
       
-      deliveries.put(new Long(deliveryId), del);
+      deliveries.put(new Long(deliveryId), new DeliveryRecord(del, consumerId));
       
       if (trace) { log.trace(this + " added delivery " + deliveryId + ": " + del); }
       
       return deliveryId;      
-   }
+   }      
    
    void acknowledgeTransactionally(List acks, Transaction tx) throws Throwable
    {
@@ -847,16 +882,16 @@
          
          Long id = new Long(ack.getDeliveryId());
            
-         Delivery del = (Delivery)deliveries.get(id);
+         DeliveryRecord rec = (DeliveryRecord)deliveries.get(id);
          
-         if (del == null)
+         if (rec == null)
          {
             throw new IllegalStateException("Cannot find delivery to acknowledge " + ack);
          }
                            
          deliveryCallback.addDeliveryId(id);
          
-         del.acknowledge(tx);
+         rec.del.acknowledge(tx);
       }      
    }
    
@@ -890,21 +925,21 @@
    {
       if (trace) { log.trace(this + " acknowledging delivery " + ack.getDeliveryId()); }
       
-      Delivery del = (Delivery)deliveries.remove(new Long(ack.getDeliveryId()));
+      DeliveryRecord rec = (DeliveryRecord)deliveries.remove(new Long(ack.getDeliveryId()));
       
-      if (del == null)
+      if (rec == null)
       {
          throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
       }
       
-      del.acknowledge(null);    
+      rec.del.acknowledge(null);    
    } 
    
    private Delivery cancelDeliveryInternal(Cancel cancel) throws Throwable
    {
-      Delivery del = (Delivery)deliveries.remove(new Long(cancel.getDeliveryId()));
+      DeliveryRecord rec = (DeliveryRecord)deliveries.remove(new Long(cancel.getDeliveryId()));
       
-      if (del == null)
+      if (rec == null)
       {
          throw new IllegalStateException("Cannot find delivery to cancel " + cancel.getDeliveryId());
       }
@@ -922,17 +957,17 @@
             if (dlq != null)
             {         
                //reset delivery count to zero
-               del.getReference().setDeliveryCount(0);
+               rec.del.getReference().setDeliveryCount(0);
                
-               dlq.handle(null, del.getReference(), tx);
+               dlq.handle(null, rec.del.getReference(), tx);
                
-               del.acknowledge(tx);           
+               rec.del.acknowledge(tx);           
             }
             else
             {
                log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
                
-               del.acknowledge(tx);
+               rec.del.acknowledge(tx);
             }                              
                         
             tx.commit();
@@ -946,12 +981,12 @@
       }
       else
       {                                                   
-         del.getReference().setDeliveryCount(cancel.getDeliveryCount());
+         rec.del.getReference().setDeliveryCount(cancel.getDeliveryCount());
          
-         del.cancel();
+         rec.del.cancel();
       }
       
-      return del;
+      return rec.del;
    }
 
    private ConsumerDelegate failoverConsumer(JBossDestination jmsDestination,
@@ -991,7 +1026,7 @@
       ServerConsumerEndpoint ep =
          new ServerConsumerEndpoint(consumerID, binding.getQueue(),
                                     binding.getQueue().getName(), this, selectorString, noLocal,
-                                    jmsDestination, prefetchSize);
+                                    jmsDestination);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
 
@@ -1263,13 +1298,13 @@
       ServerConsumerEndpoint ep =
          new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
                   binding.getQueue().getName(), this, selectorString, noLocal,
-                  jmsDestination, prefetchSize);
+                  jmsDestination);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
       
       ClientConsumerDelegate stub =
          new ClientConsumerDelegate(consumerID, binding.getQueue().getChannelID(),
-                  prefetchSize, maxDeliveryAttempts);
+                                    prefetchSize, maxDeliveryAttempts);
       
       synchronized (consumers)
       {
@@ -1294,11 +1329,33 @@
       }
    }
    
+   // Inner classes -------------------------------------------------
    
+   /*
+    * Holds a record of a delivery - we need to store the consumer id as well
+    * hence this class
+    * The only reason we need to store the consumer id is that on consumer close, we need to 
+    * cancel any deliveries corresponding to that consumer.
+    * We can't rely on the cancel being driven from the MessageCallbackHandler since
+    * the deliveries may have got lost in transit (ignored) since the consumer might have closed
+    * when they were in transit.
+    * In such a case we might otherwise end up with the consumer closing but not all it's deliveries being
+    * cancelled, which would mean they wouldn't be cancelled until the session is closed which is too late
+    */
+   private class DeliveryRecord
+   {
+      Delivery del;
+      
+      int consumerId;
+      
+      DeliveryRecord(Delivery del, int consumerId)
+      {
+         this.del = del;
+         
+         this.consumerId = consumerId;
+      }            
+   }
    
-   
-   // Inner classes -------------------------------------------------
-   
    /**
     * 
     * The purpose of this class is to remove deliveries from the delivery list on commit

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ConsumerAdvised.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -64,16 +64,16 @@
       endpoint.closing();
    }
 
-   public void more() throws JMSException
+   public void changeRate(float newRate) throws JMSException
    {
-      endpoint.more();
+      endpoint.changeRate(newRate);
    }
-
-   public void confirmDelivery(int count)
+   
+   public void cancelInflightMessages(long lastDeliveryId) throws JMSException
    {
-      endpoint.confirmDelivery(count);
+      endpoint.cancelInflightMessages(lastDeliveryId);
    }
-   
+
    public boolean isClosed() throws JMSException
    {
       return endpoint.isClosed();

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -38,7 +38,6 @@
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.remoting.CallbackManager;
-import org.jboss.jms.client.remoting.HandleMessageResponse;
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
@@ -97,19 +96,23 @@
    protected static final byte CANCEL = 3;
    protected static final byte CANCEL_LIST = 4;
    protected static final byte SEND = 5;   
-   protected static final byte MORE = 6;
+   //protected static final byte MORE = 6;
+   
+   protected static final byte CHANGE_RATE = 6;
+   
    protected static final byte SEND_TRANSACTION = 7;
    protected static final byte GET_ID_BLOCK = 8;
    protected static final byte RECOVER_DELIVERIES = 9;
-   protected static final byte CONFIRM_DELIVERY = 10;
+   //protected static final byte CONFIRM_DELIVERY = 10;
+   
+   
  
 
    // The response codes - start from 100
 
-   protected static final byte CALLBACK = 100;
+   protected static final byte MESSAGE_DELIVERY = 100;
    protected static final byte NULL_RESPONSE = 101;
    protected static final byte ID_BLOCK_RESPONSE = 102;
-   protected static final byte HANDLE_MESSAGE_RESPONSE = 103;
    protected static final byte BROWSE_MESSAGE_RESPONSE = 104;
    protected static final byte BROWSE_MESSAGES_RESPONSE = 105;
    protected static final byte CALLBACK_LIST = 106;
@@ -223,11 +226,15 @@
    
                   if (trace) { log.trace("wrote send()"); }
                }
-               else if ("more".equals(methodName))
+               else if ("changeRate".equals(methodName))
                {
-                  dos.writeByte(MORE);
+                  dos.writeByte(CHANGE_RATE);
    
                   writeHeader(mi, dos);
+                  
+                  Float f = (Float)mi.getArguments()[0];
+                  
+                  dos.writeFloat(f.floatValue());
    
                   dos.flush();
    
@@ -332,20 +339,6 @@
    
                   if (trace) { log.trace("wrote sendUnackedAckInfos()"); }
                }
-               else if ("confirmDelivery".equals(methodName))
-               {
-                  dos.writeByte(CONFIRM_DELIVERY);
-   
-                  writeHeader(mi, dos);
-   
-                  Integer count = (Integer)mi.getArguments()[0];
-   
-                  dos.writeInt(count.intValue());
-                     
-                  dos.flush();
-   
-                  if (trace) { log.trace("wrote confirmDelivery()"); }
-               }
                else if ("sendTransaction".equals(methodName))
                {
                   dos.writeByte(SEND_TRANSACTION);
@@ -393,7 +386,7 @@
    
                ClientDelivery dr = (ClientDelivery)param;
    
-               dos.writeByte(CALLBACK);
+               dos.writeByte(MESSAGE_DELIVERY);
                
                dos.writeUTF(req.getSessionId());
    
@@ -455,19 +448,6 @@
    
                if (trace) { log.trace("wrote id block response"); }
             }
-            else if (res instanceof HandleMessageResponse)
-            {         
-               //Return value from delivering messages to client
-               dos.write(HANDLE_MESSAGE_RESPONSE);
-   
-               HandleMessageResponse response = (HandleMessageResponse)res;
-   
-               response.write(dos);
-   
-               dos.flush();
-   
-               if (trace) { log.trace("wrote handle message response"); }
-            }
             else if (res instanceof JBossMessage)
             {
                //Return value from browsing message
@@ -482,8 +462,7 @@
                dos.flush();
                
                if (trace) { log.trace("wrote browse message response"); }
-            }
-            
+            }            
             else if (res instanceof Message[])
             {
                //Return value from browsing messages
@@ -510,7 +489,7 @@
                      ((ArrayList) res).size() > 0 &&
                      ((ArrayList) res).get(0) instanceof Callback)
             {
-               // Comes from polled Callbacks.
+               // Comes from polled Callbacks. (HTTP transport??)
                ArrayList callbackList = (ArrayList)res;
                dos.write(CALLBACK_LIST);
                dos.writeUTF(resp.getSessionId());
@@ -627,10 +606,16 @@
    
                return request;
             }
-            case MORE:
+            case CHANGE_RATE:
             {
                MethodInvocation mi = readHeader(dis);
-   
+               
+               float f = dis.readFloat();
+               
+               Object[] args = new Object[] {new Float(f)};
+               
+               mi.setArguments(args);
+                  
                InvocationRequest request =
                   new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
                                         new MessagingMarshallable(version, mi), null, null, null);
@@ -802,24 +787,6 @@
    
                return request;
             }
-            case CONFIRM_DELIVERY:
-            {
-               MethodInvocation mi = readHeader(dis);
-   
-               int count = dis.readInt();                  
-   
-               Object[] args = new Object[] {new Integer(count)};
-   
-               mi.setArguments(args);
-   
-               InvocationRequest request =
-                  new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
-                                        new MessagingMarshallable(version, mi), null, null, null);
-   
-               if (trace) { log.trace("read confirmDelivery()"); }
-   
-               return request;
-            }
             case ID_BLOCK_RESPONSE:
             {
                IDBlock block = new IDBlock();
@@ -832,18 +799,6 @@
    
                return resp;
             }
-            case HANDLE_MESSAGE_RESPONSE:
-            {
-               HandleMessageResponse res = new HandleMessageResponse();
-   
-               res.read(dis);
-   
-               InvocationResponse resp = new InvocationResponse(null, new MessagingMarshallable(version, res), false, null);
-   
-               if (trace) { log.trace("read handle message response"); }
-   
-               return resp;
-            }
             case BROWSE_MESSAGE_RESPONSE:
             {
                byte type = dis.readByte();
@@ -890,7 +845,7 @@
    
                return resp;
             }
-            case CALLBACK:
+            case MESSAGE_DELIVERY:
             {
                String sessionId = dis.readUTF();
                ClientDelivery dr = new ClientDelivery();

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/tests/build.xml	2006-12-22 20:55:26 UTC (rev 1849)
@@ -356,6 +356,12 @@
       <antcall target="clustering-tests"/>
    </target>
 
+   <target name="http-tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
+      <antcall target="remote-tests">
+            <param name="test.remoting" value="http"/>
+      </antcall>
+   </target>
+
    <target name="stress-tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
       <antcall target="invm-stress-tests"/>
       <antcall target="remote-stress-tests"/>  <!-- default remoting configuration (socket) -->

Modified: trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/tests/src/org/jboss/test/messaging/jms/AcknowledgementTest.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -767,12 +767,18 @@
       Session sessSend = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
       MessageProducer prod = sessSend.createProducer(queue);
       prod.setDeliveryMode(DeliveryMode.NON_PERSISTENT);
+      
+      log.trace("Sending messages");
+      
       TextMessage tm1 = sessSend.createTextMessage("a");
       TextMessage tm2 = sessSend.createTextMessage("b");
       TextMessage tm3 = sessSend.createTextMessage("c");
       prod.send(tm1);
       prod.send(tm2);
       prod.send(tm3);
+      
+      log.trace("Sent messages");
+      
       sessSend.close();
       
       assertRemainingMessages(3);
@@ -780,10 +786,20 @@
       conn.start();
 
       Session sessReceive = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+      
+      log.trace("Creating consumer");
+      
       MessageConsumer cons = sessReceive.createConsumer(queue);
       
+      log.trace("Created consumer");
+      
       MessageListenerAutoAck listener = new MessageListenerAutoAck(sessReceive);
+      
+      log.trace("Setting message listener");
+      
       cons.setMessageListener(listener);
+      
+      log.trace("Set message listener");
 
       listener.waitForMessages();
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -1081,13 +1081,25 @@
           Session sess = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
 
           MessageProducer prod = sess.createProducer(queue);
-          prod.send(sess.createTextMessage("1"));
-          prod.send(sess.createTextMessage("2"));
-          prod.send(sess.createTextMessage("3"));
+          
+          TextMessage tm1 = sess.createTextMessage("1");
+          
+          TextMessage tm2 = sess.createTextMessage("2");
+          
+          TextMessage tm3 = sess.createTextMessage("3");
+          
+          prod.send(tm1);
+          prod.send(tm2);
+          prod.send(tm3);
 
+          log.trace("Creating consumer");
           MessageConsumer cons1 = sess.createConsumer(queue);
 
-          Message r1 = cons1.receive();
+          log.trace("Waiting for message");
+          
+          TextMessage r1 = (TextMessage)cons1.receive();
+          
+          assertEquals(tm1.getText(), r1.getText());
 
           log.trace("Got first message");
 
@@ -1097,12 +1109,16 @@
 
           MessageConsumer cons2 = sess.createConsumer(queue);
 
-          log.trace("Wairting for second message");
-          Message r2 = cons2.receive();
+          log.trace("Waiting for second message");
+          TextMessage r2 = (TextMessage)cons2.receive();
+          
+          assertEquals(tm2.getText(), r2.getText());
 
           log.trace("got second message");
 
-          Message r3 = cons2.receive();
+          TextMessage r3 = (TextMessage)cons2.receive();
+          
+          assertEquals(tm3.getText(), r3.getText());
 
           r1.acknowledge();
           r2.acknowledge();
@@ -1137,6 +1153,8 @@
           prod.send(sess.createTextMessage("1"));
           prod.send(sess.createTextMessage("2"));
           prod.send(sess.createTextMessage("3"));
+          
+          log.trace("Sent messages");
 
           conn.start();
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -38,7 +38,6 @@
 
 import org.jboss.aop.Dispatcher;
 import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.jms.client.remoting.HandleMessageResponse;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
@@ -104,7 +103,7 @@
    
    //Consumer
         
-   protected Method moreMethod;
+   protected Method changeRateMethod;
    
  
    //connection
@@ -150,7 +149,7 @@
             
       //Consumer
             
-      moreMethod = consumerDelegate.getMethod("more", null);
+      changeRateMethod = consumerDelegate.getMethod("changeRate", new Class[] { Float.TYPE });
 
       //Connection
       
@@ -193,9 +192,9 @@
    
    //Consumer
    
-   public void testMore() throws Exception
+   public void testChangeRate() throws Exception
    {
-      wf.testMore();
+      wf.testChangeRate();
    }
    
    
@@ -229,9 +228,9 @@
       wf.testSerializableResponse();
    }
    
-   public void testCallBack() throws Exception
+   public void testMessageDelivery() throws Exception
    {
-      wf.testCallback();
+      wf.testMessageDelivery();
    }
    
    public void testIDBlockResponse() throws Exception
@@ -239,11 +238,8 @@
       wf.testGetIdBlockResponse();
    }
    
-   public void testHandleMessageResponse() throws Exception
-   {
-      wf.testHandleMessageResponse();
-   }
-            
+   //TODO need a test for the polled callbacks
+          
    // Public --------------------------------------------------------
    
    public static class SerializableObject implements Serializable
@@ -269,7 +265,7 @@
    /**
     * We extend the class so we have access to protected fields
     */
-   class TestWireFormat extends JMSWireFormat
+   private class TestWireFormat extends JMSWireFormat
    {      
       public void testAcknowledgeDelivery() throws Exception
       {
@@ -564,7 +560,127 @@
          
       }
       
+      public void testCancelDeliveries() throws Exception
+      {                            
+         long methodHash = 62365354;
+         
+         int objectId = 54321;
+         
+         List cancels = new ArrayList();
+         
+         DefaultCancel cancel1 = new DefaultCancel(65654, 43);
+         DefaultCancel cancel2 = new DefaultCancel(65765, 2);
+         cancels.add(cancel1);
+         cancels.add(cancel2);
+         
+         MethodInvocation mi = new MethodInvocation(null, methodHash, cancelDeliveriesMethod, cancelDeliveriesMethod, null);
+         
+         mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
+         
+         mi.setArguments(new Object[] {cancels});
+         
+         MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi);
+         
+         InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null);
+         
+         ByteArrayOutputStream bos = new ByteArrayOutputStream();
+         
+         OutputStream oos = new DataOutputStream(bos);
+                  
+         wf.write(ir, oos);
+        
+         oos.flush();
+               
+         byte[] bytes = bos.toByteArray();
+              
+         ByteArrayInputStream bis = new ByteArrayInputStream(bytes);
+                  
+         DataInputStream dis = new DataInputStream(bis); 
+               
+         //Check the bytes
+             
+         //First byte should be version
+         assertEquals(77, dis.readByte());
+         
+         //Next byte should be CANCEL_MESSAGES
+         assertEquals(JMSWireFormat.CANCEL_LIST, dis.readByte());
+         
+         //Next int should be objectId
+         assertEquals(objectId, dis.readInt());
+         
+         //Next long should be methodHash
+         assertEquals(methodHash, dis.readLong());
+                  
+         //Next should the size of the list
+         
+         int size = dis.readInt();
+         
+         assertEquals(2, size);
+         
+         //then the AckInfos
+         long deliveryId = dis.readLong();
+         int deliveryCount = dis.readInt();
+         DefaultCancel rcancel1 = new DefaultCancel(deliveryId, deliveryCount);
+         
+         deliveryId = dis.readLong();
+         deliveryCount = dis.readInt();
+         DefaultCancel rcancel2 = new DefaultCancel(deliveryId, deliveryCount);
+
+         assertEquals(cancel1.getDeliveryCount(), rcancel1.getDeliveryCount());
+         
+         assertEquals(cancel1.getDeliveryId(), cancel1.getDeliveryId());
+         
+         assertEquals(cancel2.getDeliveryCount(), rcancel2.getDeliveryCount());
+         
+         assertEquals(cancel2.getDeliveryId(), cancel2.getDeliveryId());
+                   
+         //should be eos
+                
+         try
+         {
+            dis.readByte();
+            fail("End of stream expected");
+         }
+         catch (EOFException e)
+         {
+            //Ok
+         }
+         
+         
+         bis.reset();
+         
+         InputStream ois = new DataInputStream(bis);
+         
+         InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
+         
+         mm = (MessagingMarshallable)ir2.getParameter();
+         
+         assertEquals(77, mm.getVersion());
+         
+         MethodInvocation mi2 = (MethodInvocation)mm.getLoad();
+         
+         assertEquals(methodHash, mi2.getMethodHash());
+         
+         assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue());
+         
+         List list = (List)mi2.getArguments()[0];
+        
+         assertEquals(2, list.size());
+         
+         DefaultCancel xack1 = (DefaultCancel)list.get(0);
+         DefaultCancel xack2 = (DefaultCancel)list.get(1);
+         
+         assertEquals(cancel1.getDeliveryId(), xack1.getDeliveryId());
+         
+         assertEquals(cancel1.getDeliveryCount(), xack1.getDeliveryCount());
+         
+         assertEquals(cancel2.getDeliveryId(), xack2.getDeliveryId());
+         
+         assertEquals(cancel2.getDeliveryCount(), xack2.getDeliveryCount());
+         
+      }  
       
+      
       /*
        * Test that general serializable invocation requests are marshalled correctky
        */
@@ -961,127 +1077,7 @@
          
       }  
             
-      
-      public void testCancelDeliveries() throws Exception
-      {                            
-         long methodHash = 62365354;
-         
-         int objectId = 54321;
-         
-         List cancels = new ArrayList();
-         
-         DefaultCancel cancel1 = new DefaultCancel(65654, 43);
-         DefaultCancel cancel2 = new DefaultCancel(65765, 2);
-         cancels.add(cancel1);
-         cancels.add(cancel2);
-         
-         MethodInvocation mi = new MethodInvocation(null, methodHash, cancelDeliveriesMethod, cancelDeliveriesMethod, null);
-         
-         mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
-         
-         mi.setArguments(new Object[] {cancels});
-         
-         MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi);
-         
-         InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null);
-         
-         ByteArrayOutputStream bos = new ByteArrayOutputStream();
-         
-         OutputStream oos = new DataOutputStream(bos);
                   
-         wf.write(ir, oos);
-        
-         oos.flush();
-               
-         byte[] bytes = bos.toByteArray();
-              
-         ByteArrayInputStream bis = new ByteArrayInputStream(bytes);
-                  
-         DataInputStream dis = new DataInputStream(bis); 
-               
-         //Check the bytes
-             
-         //First byte should be version
-         assertEquals(77, dis.readByte());
-         
-         //Next byte should be CANCEL_MESSAGES
-         assertEquals(JMSWireFormat.CANCEL_LIST, dis.readByte());
-         
-         //Next int should be objectId
-         assertEquals(objectId, dis.readInt());
-         
-         //Next long should be methodHash
-         assertEquals(methodHash, dis.readLong());
-                  
-         //Next should the size of the list
-         
-         int size = dis.readInt();
-         
-         assertEquals(2, size);
-         
-         //then the AckInfos
-         long deliveryId = dis.readLong();
-         int deliveryCount = dis.readInt();
-         DefaultCancel rcancel1 = new DefaultCancel(deliveryId, deliveryCount);
-         
-         deliveryId = dis.readLong();
-         deliveryCount = dis.readInt();
-         DefaultCancel rcancel2 = new DefaultCancel(deliveryId, deliveryCount);
-
-         assertEquals(cancel1.getDeliveryCount(), rcancel1.getDeliveryCount());
-         
-         assertEquals(cancel1.getDeliveryId(), cancel1.getDeliveryId());
-         
-         assertEquals(cancel2.getDeliveryCount(), rcancel2.getDeliveryCount());
-         
-         assertEquals(cancel2.getDeliveryId(), cancel2.getDeliveryId());
-                   
-         //should be eos
-                
-         try
-         {
-            dis.readByte();
-            fail("End of stream expected");
-         }
-         catch (EOFException e)
-         {
-            //Ok
-         }
-         
-         
-         bis.reset();
-         
-         InputStream ois = new DataInputStream(bis);
-         
-         InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
-         
-         mm = (MessagingMarshallable)ir2.getParameter();
-         
-         assertEquals(77, mm.getVersion());
-         
-         MethodInvocation mi2 = (MethodInvocation)mm.getLoad();
-         
-         assertEquals(methodHash, mi2.getMethodHash());
-         
-         assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue());
-         
-         List list = (List)mi2.getArguments()[0];
-        
-         assertEquals(2, list.size());
-         
-         DefaultCancel xack1 = (DefaultCancel)list.get(0);
-         DefaultCancel xack2 = (DefaultCancel)list.get(1);
-         
-         assertEquals(cancel1.getDeliveryId(), xack1.getDeliveryId());
-         
-         assertEquals(cancel1.getDeliveryCount(), xack1.getDeliveryCount());
-         
-         assertEquals(cancel2.getDeliveryId(), xack2.getDeliveryId());
-         
-         assertEquals(cancel2.getDeliveryCount(), xack2.getDeliveryCount());
-         
-      }  
-      
       public void testNullResponse() throws Exception
       {
          MessagingMarshallable mm = new MessagingMarshallable((byte)77, null);
@@ -1129,19 +1125,23 @@
          assertNull(mm.getLoad());
             
       }
-      
-      
-      
-      public void testMore() throws Exception
+                  
+      public void testChangeRate() throws Exception
       {
          long methodHash = 62365354;
          
          int objectId = 54321;
          
-         MethodInvocation mi = new MethodInvocation(null, methodHash, moreMethod, moreMethod, null);
+         float rate = 123.45f;
          
-         mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
+         MethodInvocation mi = new MethodInvocation(null, methodHash, changeRateMethod, changeRateMethod, null);
          
+         mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId)); 
+         
+         Object[] args = new Object[] { new Float(rate) };
+         
+         mi.setArguments(args);
+         
          MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi);
          
          InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null);
@@ -1165,8 +1165,8 @@
          //First byte should be version
          assertEquals(77, dis.readByte());         
          
-         //Second byte should be MORE
-         assertEquals(JMSWireFormat.MORE, dis.readByte());
+         //Second byte should be CHANGE_RATE
+         assertEquals(JMSWireFormat.CHANGE_RATE, dis.readByte());
          
          //Next int should be objectId
          assertEquals(objectId, dis.readInt());
@@ -1174,6 +1174,11 @@
          //Next long should be methodHash
          assertEquals(methodHash, dis.readLong());
          
+         //Next should be the float
+         float f2 = dis.readFloat();
+         
+         assertTrue(rate == f2);
+         
          //Now eos
          try
          {
@@ -1196,37 +1201,28 @@
          
          MethodInvocation mi2 = (MethodInvocation)mm.getLoad();
          
+         Float f3 = (Float)mi2.getArguments()[0];
+         
+         assertTrue(rate == f3.floatValue());
+         
          assertEquals(methodHash, mi2.getMethodHash());
          
          assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue());         
       }
       
-      
-      
-      public void testCallback() throws Exception
+            
+      public void testMessageDelivery() throws Exception
       {
          int consumerID = 12345678;
          
          JBossMessage m1 = new JBossMessage(123);
-         JBossMessage m2 = new JBossMessage(456);
-         JBossMessage m3 = new JBossMessage(789);
-         
-         List msgs = new ArrayList();
-         
+
          MessageProxy del1 = JBossMessage.createThinDelegate(1, m1, 7);
-         MessageProxy del2 = JBossMessage.createThinDelegate(2, m2, 8);
-         MessageProxy del3 = JBossMessage.createThinDelegate(3, m3, 9);
          
          MessageTest.configureMessage(m1);
-         MessageTest.configureMessage(m2);
-         MessageTest.configureMessage(m3);
+
+         ClientDelivery dr = new ClientDelivery(del1, consumerID);
          
-         msgs.add(del1);
-         msgs.add(del2);
-         msgs.add(del3);         
-         
-         ClientDelivery dr = new ClientDelivery(msgs, consumerID);
-         
          ByteArrayOutputStream bos = new ByteArrayOutputStream();
          
          OutputStream oos = new DataOutputStream(bos);
@@ -1248,18 +1244,15 @@
          //First byte should be version
          assertEquals(77, dis.readByte());         
          
-         //Second byte should be CALLBACK
-         assertEquals(JMSWireFormat.CALLBACK, dis.readByte());
+         //Second byte should be MESSAGE_DELIVERY
+         assertEquals(JMSWireFormat.MESSAGE_DELIVERY, dis.readByte());
          
          //Next should be sessionID
          assertEquals("dummySessionId", dis.readUTF());
          
          //Next int should be consumer id
          assertEquals(12345678, dis.readInt());
-         
-         //Next int should be number of messages
-         assertEquals(3, dis.readInt());
-                           
+                     
          //Next byte should be type
          assertEquals(JBossMessage.TYPE, dis.readByte());
          
@@ -1272,41 +1265,9 @@
          //And now the message itself
          JBossMessage r1 = new JBossMessage();
          
-         r1.read(dis);
+         r1.read(dis);         
          
-         
-         //Next byte should be type
-         assertEquals(JBossMessage.TYPE, dis.readByte());
-         
-         //Next int should be delivery count
-         assertEquals(8, dis.readInt());
-         
-         // Delivery id
-         assertEquals(2, dis.readLong());
-         
-         //And now the message itself
-         JBossMessage r2 = new JBossMessage();
-         
-         r2.read(dis);
-         
-         
-         //Next byte should be type
-         assertEquals(JBossMessage.TYPE, dis.readByte());
-         
-         //Next int should be delivery count
-         assertEquals(9, dis.readInt());
-         
-         // Delivery id
-         assertEquals(3, dis.readLong());
-         
-         //And now the message itself
-         JBossMessage r3 = new JBossMessage();
-         
-         r3.read(dis);
-         
          MessageTest.ensureEquivalent(m1, r1);
-         MessageTest.ensureEquivalent(m2, r2);
-         MessageTest.ensureEquivalent(m3, r3);
          
          //eos
          try
@@ -1339,25 +1300,16 @@
                   
          ClientDelivery dr2 = (ClientDelivery)mm.getLoad();
          
-         List msgs2 = dr2.getMessages();
+         MessageProxy p1 = dr2.getMessage();
          
          assertEquals(consumerID, dr2.getConsumerId());
          
-         MessageProxy p1 = (MessageProxy)msgs2.get(0);
-         MessageProxy p2 = (MessageProxy)msgs2.get(1);
-         MessageProxy p3 = (MessageProxy)msgs2.get(2);
-         
+
          assertEquals(del1.getDeliveryCount(), p1.getDeliveryCount());
-         assertEquals(del2.getDeliveryCount(), p2.getDeliveryCount());
-         assertEquals(del3.getDeliveryCount(), p3.getDeliveryCount());
-         
+
          JBossMessage q1 = p1.getMessage();
-         JBossMessage q2 = p1.getMessage();
-         JBossMessage q3 = p1.getMessage();
-         
-         MessageTest.ensureEquivalent(m1, q1);
-         MessageTest.ensureEquivalent(m2, q2);
-         MessageTest.ensureEquivalent(m3, q3);         
+  
+         MessageTest.ensureEquivalent(m1, q1);      
       }
       
                   
@@ -1421,66 +1373,6 @@
          assertEquals(block.getLow(), block3.getLow());
          assertEquals(block.getHigh(), block3.getHigh());                  
       }    
-      
-      public void testHandleMessageResponse() throws Exception
-      {
-         HandleMessageResponse h = new HandleMessageResponse(true, 76876);
-         
-         MessagingMarshallable mm = new MessagingMarshallable((byte)77, h);
-                  
-         InvocationResponse ir = new InvocationResponse(null, mm, false, null);
-         
-         ByteArrayOutputStream bos = new ByteArrayOutputStream();
-         
-         OutputStream oos = new DataOutputStream(bos);
-         
-         wf.write(ir, oos);
-         
-         oos.flush();
-         
-         ByteArrayInputStream bis = new ByteArrayInputStream(bos.toByteArray());
-         
-         DataInputStream dis = new DataInputStream(bis);
-                   
-         // First byte should be version
-         assertEquals(77, dis.readByte());
-         
-         int b = dis.readByte();
-         
-         assertEquals(JMSWireFormat.HANDLE_MESSAGE_RESPONSE, b);
-         
-         HandleMessageResponse h2 = new HandleMessageResponse();
-         
-         h2.read(dis);
-         
-         assertEquals(h.clientIsFull(), h2.clientIsFull());
-         assertEquals(h.getNumberAccepted(), h2.getNumberAccepted());
-         
-         //eos
-         try
-         {
-            dis.readByte();
-            fail("End of stream expected");
-         }
-         catch (EOFException e)
-         {
-            //Ok
-         }
-         
-         bis.reset();
-         
-         InputStream ois = new DataInputStream(bis);
-         
-         InvocationResponse ir2 = (InvocationResponse)wf.read(ois, null);
-         
-         mm = (MessagingMarshallable)ir2.getResult();
-         
-         assertEquals(77, mm.getVersion());
-         
-         HandleMessageResponse h3 = (HandleMessageResponse)mm.getLoad();
-         
-         assertEquals(h.clientIsFull(), h3.clientIsFull());
-         assertEquals(h.getNumberAccepted(), h3.getNumberAccepted());                 
-      }    
+            
    }
 }
\ No newline at end of file

Modified: trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -88,7 +88,7 @@
    {
       Message m = queueProducerSession.createMessage();
       queueProducer.send(m, DeliveryMode.NON_PERSISTENT, 4, 5000);
-      Message result = queueConsumer.receive(100);
+      Message result = queueConsumer.receive(1000);
       assertEquals(m.getJMSMessageID(), result.getJMSMessageID());
    }
 
@@ -97,7 +97,7 @@
       Message m = queueProducerSession.createMessage();
       queueProducer.send(m, DeliveryMode.NON_PERSISTENT, 4, 1000);
       Thread.sleep(2000);
-      assertNull(queueConsumer.receive(100));
+      assertNull(queueConsumer.receive(1000));
    }
 
    public void testExpirationOnReceiveNoWait() throws Exception

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-22 16:26:50 UTC (rev 1848)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-22 20:55:26 UTC (rev 1849)
@@ -1157,6 +1157,8 @@
       //is always currently used - (we could make this configurable)
 
       String transport = config.getRemotingTransport();
+      
+      log.info("*** Using transport: " + transport);
 
       String params = "/?marshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
                       "unmarshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 17:03:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 17:03:56 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1850 -
	trunk/tests/src/org/jboss/test/messaging/tools
Message-ID: <E1GxsUe-0005x5-IR@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-22 17:03:55 -0500 (Fri, 22 Dec 2006)
New Revision: 1850

Modified:
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
Log:
Fixing testsuite for Linux

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-22 20:55:26 UTC (rev 1849)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-22 22:03:55 UTC (rev 1850)
@@ -378,7 +378,14 @@
 
       //System.out.println("CLASSPATH: " + classPath);
 
-      sb.append("-cp").append(" \"").append(classPath).append("\" ");
+      if (System.getProperty("os.name").equals("Linux"))
+      {
+         sb.append("-cp").append(" ").append(classPath).append(" ");
+      }
+      else
+      {
+         sb.append("-cp").append(" \"").append(classPath).append("\" ");
+      }
 
       sb.append("org.jboss.test.messaging.tools.jmx.rmi.RMITestServer");
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 17:50:46 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 17:50:46 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1851 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GxtDy-0006ku-0Z@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-22 17:50:45 -0500 (Fri, 22 Dec 2006)
New Revision: 1851

Modified:
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
Log:
I removed valveInstall in one of my cleanups. 
This class is not used on the main branch, but if we meant to use it, we need to install delegate on created delegates.

Modified: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-22 22:03:55 UTC (rev 1850)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-22 22:50:45 UTC (rev 1851)
@@ -92,16 +92,16 @@
       boolean failure = false;
 
       // Eventually retries in case of listed exceptions
-      for (int i = 0; i < MAX_IO_RETRY_COUNT; i++)
+      for (int invocationCount = 0; invocationCount < MAX_IO_RETRY_COUNT; invocationCount++)
       {
 
-         if (i > 0)
+         if (invocationCount > 0)
          {
-            log.info("Retrying a call " + i);
+            log.info("Retrying a call " + invocationCount);
          }
 
          // We shouldn't have any calls being made while the failover is being executed
-         if (i > 0)
+         if (invocationCount > 0)
          {
             // On retries we will use writeLocks, as the failover was already being processed
             lockValve.writeLock().acquire();
@@ -116,15 +116,20 @@
          try
          {
             returnObject = invocation.invokeNext();
+
+            if (returnObject instanceof DelegateSupport)
+            {
+               installValveAspect((DelegateSupport) returnObject, this);
+            }
          }
          catch (CannotConnectException e)
          {
-            log.error("Got an exception on HAAspect, retryCount=" + i, e);
+            log.error("Got an exception on HAAspect, retryCount=" + invocationCount, e);
             failure = true;
          }
          catch (IOException e)
          {
-            log.error("Got an exception on HAAspect, retryCount=" + i, e);
+            log.error("Got an exception on HAAspect, retryCount=" + invocationCount, e);
             failure = true;
          }
          catch (Throwable e)
@@ -134,7 +139,7 @@
          }
          finally
          {
-            if (i > 0)
+            if (invocationCount > 0)
             {
                lockValve.writeLock().release();
             }



From mandersen at jboss.com  Fri Dec 22 18:13:18 2006
From: mandersen at jboss.com (Max Rydahl Andersen)
Date: Fri, 22 Dec 2006 18:13:18 -0500
Subject: [jboss-cvs]
	jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy
	...
Message-ID: <E1GxtZm-0007Kn-En@committer01.frg.pub.inap.atl.jboss.com>

  User: mandersen
  Date: 06/12/22 18:13:18

  Added:       hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy     
                        hqleditorsetmaxresults.png consolelog.png
                        hbm2docwithgraph.jpg
                        hibernate-eclipse-news-3.2.0.beta9.html
                        easysetup.png
  Log:
  new and noteworthy for b9
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 23:13:18;  author: mandersen;  state: Exp;jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/hqleditorsetmaxresults.png
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/22 23:13:18;  author: mandersen;  state: Exp;jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/consolelog.png
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/22 23:13:18;  author: mandersen;  state: Exp;jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/hbm2docwithgraph.jpg
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/22 23:13:18;  author: mandersen;  state: Exp;jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/hibernate-eclipse-news-3.2.0.beta9.html
  
  Index: hibernate-eclipse-news-3.2.0.beta9.html
  ===================================================================
  <html>
  
  <head>
  <link rel="stylesheet" href="default_.css">
  <title>Hibernate Eclipse Tools 3.2.0.beta9 News</title>
  </head>
  
  <body>
  
  <h1>Hibernate Tools 3.2.0.beta9 - New and Noteworthy</h1>
  
    <p>Previous <a href="hibernate-eclipse-news-3.2.0.beta8.html">new and noteworthy for 3.1.0.beta8</a></p>
    <p><a href="http://opensource.atlassian.com/projects/hibernate/secure/IssueNavigator.jspa?reset=true&pid=10030&fixfor=10623">Release notes</a></p>
  <table border="0" cellpadding="10" cellspacing="0" width="80%">
      <tr>
      <td colspan="2">
        <hr>
        <h3>General</h3>
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Easier setup & full JPA support</b></td>
      <td valign="top">
        <p>A Console configuration can now be associcated with a Java
        project from which the plugin will read the classpath. This
        removes the requirement for users to specify an alternative
  	classpath.</p>
  
  	<p>Furthermore the user is no longer required to specify a
  	  <code>hibernate.cfg.xml</code> nor <code>hibernate.properties</code> since both can now
  	be looked up via the default project classpath.</p>
  
  	  <p>The UI have also been simplified, so now the only thing
  	  required now is to name the console configuration; and even
  	  that will be automatically filled out if you start the
  	  wizard on some resource.</p>
  
  	  <p><img src="easysetup.png"/></p>
  
  	    <p>Furthermore JPA/EJB 3 entity classes is now fully
  	      supported by simply choosing JPA as the configuration
  	      type and optionally enter a persistence unit name.
  	      Hibernate EntityManager will then be used to
  	      automatically scan the classpath for entities according
  	      to the setup in a <code>META-INF/persistence.xml</code></p>
      </td>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
      </td>
    </tr>
  
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Console logs per Configuration</b></td>
      <td valign="top">
        <p>The Error log could get flooded by error messages reported
        from Hibernate during normal usage; e.g. syntax errors in the
        entered HQL. The error log should now only show an error if it
        is an error situation in the Hibernate plugin.</p>
  
  	<p>The other "normal usage" logging is now sent to a seperate Eclipse Console log per Configuration; instead of one big log.</p>
  
  	  <p><img src="consolelog.png"/></p>
  
  	  <p>Since this log is just what Hibernate normally logs you
  	  can adjust what gets logged to these consoles by configuring
  	  the log4j configuration
  	  (<code>org.hibernate.eclipse/hibernate-log4j.properties</code>)
  	  in the plugins directory.</p>
      </td>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
        <h3>Query editing</h3>
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Max results support</b></td>
      <td valign="top">
        <p>Previously HQL and Criteria execution were done unbounded; meaning it could result in OutOfMemoryError's on large data set. To remedy this the query editors now have a "Max results" field which can be filled in to limit the amount of data being queried for.
        <p><img src="hqleditorsetmaxresults.png"/></p>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
        <h3>Reverse Engineering</h3>
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Oracle improvements</b></td>
      <td valign="top">
        <p>The OracleMetaDataDialect is now enabled by default for Oracle related dialects. The Oracle specific handling have also been improved greatly so now it is much faster than normal JDBC MetaData API.</p>
        <p>If you experience issues with the OracleMetaDataDialect you can fall back to using the JDBC MetaData API by adding the following property to your hibernate.properties or hibernate.cfg.xml: </p>
  	<p><code>hibernatetool.metadatadialect=org.hibernate.cfg.rveng.dialect.JDBCMetaDataDialect</code></p>	
      </td>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Automatic handling of identifier casing</b></td>
      <td valign="top">
        <p>Previously we performed lookups for tables, columns etc. verbatim even though the database might not support mixed case lookups e.g. "Category" instead of "CATEGORY" when a database stores identifiers in uppercase.</p>
        <p>This could result in some issues with respect to overrides specified in reveng.xml would not take effect because the casing did not match.</p>
  
  	<p>To remedy this the JDBCMetaDataDialect now perform lookups and comparisons according to what the <code>java.sql.DatabaseMetaData</code> reports with respect to casing of identifiers.</p>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
        <h3>Schema documentation</h3>
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>hbm2doc improvements</b></td>
      <td valign="top">
        <p>hbm2doc got a major overhaul for this release, thanks to Mark Hobson. The long list of improvements contain amongst other things: pure XHTML to allow it to be rendered correctly in all major browsers; better support for subclassed models and inner classes and in general a much cleaner layout.</p>
      </td>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Table and class diagrams</b></td>
      <td valign="top">
        <p>hbm2doc will now generate a two diagrams with GraphViz. A single class diagram for all entities and their associations and a single table diagram with the tables and the foreign key constraints.</p>
  
        <p><img src="hbm2docwithgraph.jpg"/></p>
  
  	<p>To enable this GraphViz needs to be available and the <code>dot.executable</code> property set to the GraphViz dot executable when running hbm2doc from Ant or Eclipse</p>
  
    </tr>
    <tr>
      <td colspan="2">
        <hr>
        <h3>Code generation</h3>
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Java formatting via Ant</b></td>
      <td valign="top">
        <p>When generating Java code from inside Eclipse we always formatted the source according to the current Java project; with Ant no such formatting took place.</p>
  	<p>This is now possible by using the Ant java formatter which utilizes Eclipses code formatter. See <a href="">HBX-811</a> for the details.</p>
  
  	  <code>
  	    &lt;taskdef name="javaformatter" classname="org.hibernate.tool.ant.JavaFormatterTask" classpathref="tasks.classpath"/&gt;<br>
  	    &lt;javaformatter configurationfile="optional-eclipse-formatting-settings"&gt;<br>
  	    &nbsp;&lt;fileset dir="${build.dir}"&gt;<br>
  	    &nbsp;&nbsp;&lt;include name="**/*.java"/&gt;<br>
  	    &nbsp;&lt;/fileset&gt;<br>
  	    &lt;/javaformatter&gt; <br>
  	  </code>
      </td>
    </tr>
    <tr>
      <td colspan="2">
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>Better &lt;meta&gt attributes</b></td>
      <td valign="top">
        <p>Multiple issues with respect to meta attributes have been
        fixed; especially inherited meta attributes are not broken
        anymore (HBX-793) plus meta attributes are now possible to
        specify in reveng.xml (HBX-575) for better customization of the
        resulting java code from a reverse engineered database.
    </tr>
    <tr>
      <td colspan="2">
        <hr>
      </td>
    </tr>
    <tr>
      <td valign="top" align="left">
        <p align="right"><b>More control in hbmtemplate</b></td>
      <td valign="top">
        <p>hbmtemplate can now control which elements should actually be passed into the template. Allowing you to e.g. only process entities and not any components/composite-id's.</p>
  	<p><code>&lt;hbmtemplate ... foreach="entity"/&gt;</code></p>
  
  	  <p>The foreach attribute supports a comma seperated list of the following values: configuration, entity and component.</p>
    </tr>
  
  </table>
  
  </body>
  
  </html>
  
  
  
  
  
  1.1      date: 2006/12/22 23:13:18;  author: mandersen;  state: Exp;jbosside/hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/easysetup.png
  
  	<<Binary file>>
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:39 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages
	- New directory ...
Message-ID: <E1Gxtkl-0007Tj-8a@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:39

  Log:
  Directory /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages added to the repository


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers
	...
Message-ID: <E1Gxtko-0007UJ-1s@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers    
                        PackagesPublisher.java PathPublisher.java
                        IJBossServerPublisher.java
                        JstPackagesPublisher.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.4       +147 -29   jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PackagesPublisher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- PackagesPublisher.java	11 Dec 2006 15:49:06 -0000	1.3
  +++ PackagesPublisher.java	22 Dec 2006 23:24:42 -0000	1.4
  @@ -28,13 +28,18 @@
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IPath;
   import org.eclipse.core.runtime.IProgressMonitor;
  +import org.eclipse.core.runtime.IStatus;
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.core.runtime.Path;
   import org.eclipse.wst.server.core.IModule;
   import org.eclipse.wst.server.core.IServer;
   import org.eclipse.wst.server.core.model.ServerBehaviourDelegate;
  -import org.jboss.ide.eclipse.as.core.server.JBossServer;
  +import org.jboss.ide.eclipse.as.core.model.EventLogModel;
  +import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogRoot;
  +import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
   import org.jboss.ide.eclipse.as.core.util.FileUtil;
  +import org.jboss.ide.eclipse.as.core.util.SimpleTreeItem;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
   
  @@ -43,9 +48,31 @@
    * @author rob.stryker at jboss.com
    */
   public class PackagesPublisher implements IJBossServerPublisher {
  -	private JBossServer server;
  -	public PackagesPublisher(JBossServer jbServer) {
  -		this.server = jbServer;
  +	
  +	// Event Constants
  +	public static final String REMOVE_TOP_EVENT = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.REMOVE_TOP_EVENT";
  +	public static final String REMOVE_PACKAGE_SUCCESS = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.REMOVE_PACKAGE_SUCCESS";
  +	public static final String REMOVE_PACKAGE_FAIL = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.REMOVE_PACKAGE_FAIL";
  +	public static final String REMOVE_PACKAGE_SKIPPED = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.REMOVE_PACKAGE_SKIPPED";
  +	
  +
  +	public static final String PUBLISH_TOP_EVENT = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.PUBLISH_TOP_EVENT";
  +	public static final String PROJECT_BUILD_EVENT = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.PROJECT_BUILD_EVENT";
  +	public static final String MOVE_PACKAGE_SUCCESS = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.MOVE_PACKAGE_SUCCESS";
  +	public static final String MOVE_PACKAGE_FAIL = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.MOVE_PACKAGE_FAIL";
  +	public static final String MOVE_PACKAGE_SKIP = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.MOVE_PACKAGE_SKIP";
  +	
  +//	public static final String PACKAGE_NOT_PUBLISHED = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.PACKAGE_NOT_PUBLISHED";
  +//	public static final String PACKAGE_NOT_REMOVED = "org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.PACKAGE_NOT_REMOVED";
  +	
  +	
  +	
  +	private IDeployableServer server;
  +	private EventLogRoot eventRoot;
  +
  +	public PackagesPublisher(IDeployableServer server) {
  +		this.server = server;
  +		eventRoot = EventLogModel.getModel(server.getServer()).getRoot();
   	}
   	public int getPublishState() {
   		return IServer.PUBLISH_STATE_NONE;
  @@ -82,57 +109,148 @@
   	}
   
   	protected void removeModule(IModule[] module, IProgressMonitor monitor) {
  +		
   		// remove all of the deployed items
  -		System.out.println("removing module " + module[0].getName());
  +		PublishEvent event = new PublishEvent(eventRoot, REMOVE_TOP_EVENT, module[0]);
  +		EventLogModel.markChanged(eventRoot);
   		
   		String projectName = module[0].getName();
   		IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
   		if( project.exists() ) {
   			IPackage[] packages = PackagesCore.getProjectPackages(project, new NullProgressMonitor());
   			for( int i = 0; i < packages.length; i++ ) {
  +				
  +				try {
  +				
   				if( packages[i].isDestinationInWorkspace()) {
   					IFile file = packages[i].getPackageFile();
   					IPath sourcePath = file.getLocation();
  -					IPath destPath = new Path(server.getDeployDirectory(true)).append(sourcePath.lastSegment());
  -					destPath.toFile().delete();
  +						IPath destPath = new Path(server.getDeployDirectory()).append(sourcePath.lastSegment());
  +						boolean success = destPath.toFile().delete();
  +						addRemoveEvent(event, packages[i], destPath, success ? SUCCESS : FAILURE);
   				} else {
   					IPath path = packages[i].getPackageFilePath();
  -					Path deployDir = new Path(server.getDeployDirectory(true));
  +						Path deployDir = new Path(server.getDeployDirectory());
   					if( path.toOSString().startsWith(deployDir.toOSString())) {
  -						try {
  -						path.toFile().delete();
  -						} catch( Exception e ) {
  -							e.printStackTrace();
  +							boolean success = path.toFile().delete();
  +							addRemoveEvent(event, packages[i], path, success ? SUCCESS : FAILURE);
  +						} else {
  +							addRemoveEvent(event, packages[i], path, SKIPPED, null);
   						}
   					}
  +				} catch( Exception e ) {
  +					IPath dest = packages[i].getPackageFile().getLocation();
  +					addRemoveEvent(event, packages[i], dest, FAILURE, e);
   				}
   			}
   		}
   	}
   	
  +
  +	
   	protected void publishModule(boolean incremental, IModule[] module, IProgressMonitor monitor) {
  -		System.out.println("publishing module " + module[0].getName());
  +		PublishEvent event = new PublishEvent(eventRoot, PUBLISH_TOP_EVENT, module[0]);
  +		EventLogModel.markChanged(eventRoot);
   
   		int inc2 = incremental ? IncrementalProjectBuilder.INCREMENTAL_BUILD : IncrementalProjectBuilder.FULL_BUILD;
   		String projectName = module[0].getName();
   		IProject project = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
   		try {
  +			addBuildEvent(event, project, inc2);
   		PackagesCore.buildProject(project, inc2, monitor);
   		IPackage[] packages = PackagesCore.getProjectPackages(project, new NullProgressMonitor());
   		for( int i = 0; i < packages.length; i++ ) {
   			if( packages[i].isDestinationInWorkspace()) {
  -				try {
   					// destination is workspace. Move it. 
   					IFile file = packages[i].getPackageFile();
   					IPath sourcePath = file.getLocation();
  -					IPath destPath = new Path(server.getDeployDirectory(true)).append(sourcePath.lastSegment());
  -					FileUtil.copyFile(sourcePath.toFile(), destPath.toFile());
  -				} catch( Exception e ) {
  -					e.printStackTrace();
  -				}
  +					IPath destPath = new Path(server.getDeployDirectory()).append(sourcePath.lastSegment());
  +					IStatus status = FileUtil.copyFile(sourcePath.toFile(), destPath.toFile());
  +					addMoveEvent(event, packages[i], packages[i].isDestinationInWorkspace(), sourcePath, destPath, status.isOK() ? SUCCESS : FAILURE, status.getException());
  +				} else {					
  +					IPath sourcePath = packages[i].getPackageFilePath();
  +					addMoveEvent(event, packages[i], packages[i].isDestinationInWorkspace(), sourcePath, sourcePath, SKIPPED, null);
   			}
   		}
   		}catch( Exception ce ) {
  +			ce.printStackTrace();
   		}
   	}
  +	
  +	protected void addBuildEvent(PublishEvent parent, IProject project, int incremental ) {
  +		EventLogModel.markChanged(parent);
  +	}
  +	protected void addMoveEvent(PublishEvent parent, IPackage pack, boolean inWorkspace, 
  +			IPath sourcePath, IPath destPath, int success, Throwable e) {
  +		String specType = null;
  +		switch( success ) {
  +			case SUCCESS: specType = MOVE_PACKAGE_SUCCESS; break;
  +			case FAILURE: specType = MOVE_PACKAGE_FAIL; break;
  +			case SKIPPED: specType = MOVE_PACKAGE_SKIP; break;
  +		}
  +		new PackagesPublisherMoveEvent(parent, specType, pack, sourcePath, destPath, e );
  +		EventLogModel.markChanged(parent);
  +	}
  +	
  +	
  +	
  +	protected void addRemoveEvent(PublishEvent parent, IPackage pack, IPath dest, int success ) {
  +		addRemoveEvent(parent, pack, dest, success, null);	
  +	}
  +	protected void addRemoveEvent(PublishEvent parent, IPackage pack, IPath dest, int success, Exception e ) {
  +		String specType = null;
  +		switch( success ) {
  +			case SUCCESS: specType = REMOVE_PACKAGE_SUCCESS; break;
  +			case FAILURE: specType = REMOVE_PACKAGE_FAIL; break;
  +			case SKIPPED: specType = REMOVE_PACKAGE_SKIPPED; break;
  +		}
  +		PackagesPublisherRemoveEvent event = 
  +			new PackagesPublisherRemoveEvent(parent, specType, pack, dest, e);
  +		EventLogModel.markChanged(parent);
  +	}
  +	
  +	public static class PackagesPublisherRemoveEvent extends EventLogTreeItem {
  +		// property names
  +		public static final String PACKAGE_NAME = "PackagesPublisherRemoveEvent.PACKAGE_NAME";
  +		public static final String DESTINATION = "PackagesPublisherRemoveEvent.DESTINATION";
  +		public static final String EXCEPTION_MESSAGE = "PackagesPublisherRemoveEvent.EXCEPTION_MESSAGE";
  +		
  +		
  +		public PackagesPublisherRemoveEvent(SimpleTreeItem parent, String specificType,
  +				IPackage pack, IPath dest, Exception e ) {
  +			super(parent, PUBLISH_MAJOR_TYPE, specificType);
  +			setProperty(PACKAGE_NAME, pack.getName());
  +			setProperty(DESTINATION, dest.toOSString());
  +			if( e != null )
  +				setProperty(EXCEPTION_MESSAGE, e.getLocalizedMessage());
  +		}
  +	}	
  +	public static class PackagesPublisherMoveEvent extends EventLogTreeItem {
  +		// property names
  +		public static final String PACKAGE_NAME = "PackagesPublisherRemoveEvent.PACKAGE_NAME";
  +		public static final String MOVE_DESTINATION = "PackagesPublisherRemoveEvent.MOVE_DESTINATION";
  +		public static final String MOVE_SOURCE = "PackagesPublisherRemoveEvent.MOVE_SOURCE";
  +		public static final String EXCEPTION_MESSAGE = "PackagesPublisherRemoveEvent.EXCEPTION_MESSAGE";
  +		
  +		
  +		public PackagesPublisherMoveEvent(SimpleTreeItem parent, String specificType,
  +				IPackage pack, IPath source, IPath dest, Throwable e ) {
  +			super(parent, PUBLISH_MAJOR_TYPE, specificType);
  +			setProperty(PACKAGE_NAME, pack.getName());
  +			setProperty(MOVE_SOURCE, source.toOSString());
  +			setProperty(MOVE_DESTINATION, dest.toOSString());
  +			if( e != null )
  +				setProperty(EXCEPTION_MESSAGE, e.getLocalizedMessage());
  +		}
  +	}	
  +	public static class PackagesPublisherBuildEvent extends EventLogTreeItem {
  +		// property names
  +		public static final String BUILD_TYPE = "PackagesPublisherRemoveEvent.BUILD_TYPE";
  +		
  +		public PackagesPublisherBuildEvent(SimpleTreeItem parent, String specificType, int type) {
  +			super(parent, PUBLISH_MAJOR_TYPE, specificType);
  +			setProperty(BUILD_TYPE, new Integer(type));
  +		}
  +	}
  +
   }
  
  
  
  1.3       +5 -3      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PathPublisher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PathPublisher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PathPublisher.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PathPublisher.java	30 Nov 2006 16:14:59 -0000	1.2
  +++ PathPublisher.java	22 Dec 2006 23:24:42 -0000	1.3
  @@ -35,12 +35,14 @@
   import org.jboss.ide.eclipse.as.core.module.JBossModuleDelegate;
   import org.jboss.ide.eclipse.as.core.server.JBossServer;
   import org.jboss.ide.eclipse.as.core.server.JBossServerBehavior;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
  +import org.jboss.ide.eclipse.as.core.server.stripped.DeployableServerBehavior;
   import org.jboss.ide.eclipse.as.core.util.FileUtil;
   
   public class PathPublisher implements IJBossServerPublisher  {
   	
  -	private JBossServer server;
  -	private JBossServerBehavior behavior;
  +	private IDeployableServer server;
  +	private DeployableServerBehavior behavior;
   	private int publishState;
   	
   	public static final String TARGET_FILENAME = "_TARGET_FILENAME_";
  @@ -48,7 +50,7 @@
   	public static final String DEST_FILENAME = "_DEST_FILENAME_";
   	
   	
  -	public PathPublisher(JBossServer server, JBossServerBehavior behavior) {
  +	public PathPublisher(IDeployableServer server, DeployableServerBehavior behavior) {
   		this.server = server;
   		this.behavior = behavior;
   		publishState = IServer.PUBLISH_STATE_NONE;
  
  
  
  1.3       +27 -0     jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/IJBossServerPublisher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IJBossServerPublisher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/IJBossServerPublisher.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IJBossServerPublisher.java	30 Nov 2006 16:14:59 -0000	1.2
  +++ IJBossServerPublisher.java	22 Dec 2006 23:24:42 -0000	1.3
  @@ -24,10 +24,37 @@
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.wst.server.core.IModule;
  +import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  +import org.jboss.ide.eclipse.as.core.util.SimpleTreeItem;
   
   public interface IJBossServerPublisher {
  +	// event constants
  +	public static final String PUBLISH_MAJOR_TYPE = "org.jboss.ide.eclipse.as.core.publishers.MajorType";
  +	public static final String MODULE_NAME = "org.jboss.ide.eclipse.as.core.publishers.ModuleName";
  +	public static final int PUBLISH = 0;
  +	public static final int REMOVE = 1;
  +	public static final int SUCCESS = 0;
  +	public static final int FAILURE = 1;
  +	public static final int SKIPPED = 2;
  +	
  +	
  +	
  +	
   	public void publishModule(int kind, int deltaKind, int modulePublishState,
   			IModule[] module, IProgressMonitor monitor) 
   								throws CoreException;
   	public int getPublishState();
  +	
  +	public class PublishEvent extends EventLogTreeItem {
  +		public PublishEvent(SimpleTreeItem parent, String specificType) {
  +			super(parent, PUBLISH_MAJOR_TYPE, specificType);
  +		}
  +		public PublishEvent(SimpleTreeItem parent, String specificType, IModule module) {
  +			super(parent, PUBLISH_MAJOR_TYPE, specificType);
  +			setProperty(MODULE_NAME, module.getName());
  +		}
  +		
  +		
  +	}
  +	
   }
  
  
  
  1.3       +42 -253   jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JstPackagesPublisher.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- JstPackagesPublisher.java	13 Dec 2006 18:35:49 -0000	1.2
  +++ JstPackagesPublisher.java	22 Dec 2006 23:24:42 -0000	1.3
  @@ -21,9 +21,6 @@
    */
   package org.jboss.ide.eclipse.as.core.publishers;
   
  -import org.eclipse.core.resources.IContainer;
  -import org.eclipse.core.resources.IProject;
  -import org.eclipse.core.runtime.Assert;
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IPath;
   import org.eclipse.core.runtime.IProgressMonitor;
  @@ -31,28 +28,16 @@
   import org.eclipse.core.runtime.NullProgressMonitor;
   import org.eclipse.core.runtime.Path;
   import org.eclipse.core.runtime.Status;
  -import org.eclipse.jdt.core.IJavaProject;
  -import org.eclipse.jdt.core.JavaCore;
  -import org.eclipse.jdt.core.JavaModelException;
  -import org.eclipse.jst.server.core.IEnterpriseApplication;
  -import org.eclipse.jst.server.core.IWebModule;
   import org.eclipse.wst.server.core.IModule;
   import org.eclipse.wst.server.core.IServer;
   import org.eclipse.wst.server.core.internal.DeletedModule;
   import org.eclipse.wst.server.core.model.ServerBehaviourDelegate;
   import org.jboss.ide.eclipse.as.core.JBossServerCorePlugin;
  -import org.jboss.ide.eclipse.as.core.server.JBossServer;
  -import org.jboss.ide.eclipse.packages.core.Trace;
  +import org.jboss.ide.eclipse.as.core.packages.ModulePackageTypeConverter;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFileSetWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageFolderWorkingCopy;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  -import org.jboss.ide.eclipse.packages.core.model.IPackageWorkingCopy;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  -import org.jboss.ide.eclipse.packages.core.model.internal.PackagesModel;
  -import org.jboss.ide.eclipse.packages.core.model.types.JARPackageType;
  +import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
   
   /**
    *  This class provides a default implementation for packaging different types of projects
  @@ -60,16 +45,10 @@
    */
   public class JstPackagesPublisher implements IJBossServerPublisher {
   
  -	private static final String METAINF = "META-INF";
  -	private static final String WEBINF = "WEB-INF";
  -	private static final String LIB = "lib";
  -	private static final String WEBCONTENT = "WebContent";
  -	private static final String EARCONTENT = "EarContent";
  -	
   	private int state;
  -	private JBossServer server;
  +	private IDeployableServer server;
   	
  -	public JstPackagesPublisher(JBossServer server) {
  +	public JstPackagesPublisher(IDeployableServer server) {
   		this.server = server;
   		state = IServer.PUBLISH_STATE_NONE;
   	}
  @@ -82,244 +61,54 @@
   			IModule[] module, IProgressMonitor monitor) throws CoreException {
       	checkClosed(module);
           if(ServerBehaviourDelegate.REMOVED == deltaKind){
  -        	JstPackagesAssembler publisher = new JstPackagesAssembler();
  -            publisher.initialize(module,server);
  -            publisher.unpublish(monitor);
  +        	unpublish(server, module, monitor);
           } else if( ServerBehaviourDelegate.NO_CHANGE != deltaKind || kind == IServer.PUBLISH_FULL || kind == IServer.PUBLISH_CLEAN ){
           	// if there's no change, do nothing. Otherwise, on change or add, re-publish
  -        	JstPackagesAssembler publisher = new JstPackagesAssembler();
  -            publisher.initialize(module,server);
  -            publisher.publish(monitor);
  -        }
  -	}
  -    private void checkClosed(IModule[] module) throws CoreException {
  -    	for(int i=0;i<module.length;i++) {
  -    		if(module[i] instanceof DeletedModule) {	
  -                IStatus status = new Status(IStatus.ERROR,JBossServerCorePlugin.PLUGIN_ID,0, "Failure", null);
  -                throw new CoreException(status);
  -    		}
  +        	publish(server, module, monitor);
       	}
       }
       
  -    public static class JstPackagesAssembler {
  -		public static final int WAR = 1;
  -		public static final int EAR = 2;
  -		public static final int SAR = 3;
  -		public static final int OTHER = 4;
  -		
  -		
  -		private IModule[] module;
  -		private JBossServer jbServer;
  -
  -		private int assembleType;
  -				
  -	    public void initialize(IModule[] module, JBossServer server) {
  -			this.module = module;
  -			this.jbServer = server;
  -			if( module.length == 1 ) {
  -				if(isModuleType(module[0], "jst.web")) {
  -					assembleType = WAR;
  -				} else if(isModuleType(module[0], "jst.ear")) {
  -					assembleType = EAR;
  -				} else {
  -					assembleType = OTHER;
  -				}
  -			}
  -	    }
  -	    
  -		private boolean isModuleType(IModule module, String moduleTypeId){	
  -			if(module.getModuleType()!=null && moduleTypeId.equals(module.getModuleType().getId()))
  -				return true;
  -			return false;
  -		}
  -
  -		public IPackage[] getPackages() {
  -			IProject proj = module[0].getProject();
  -			if( proj != null) {
  -				IPackage[] projPackages = PackagesCore.getProjectPackages(proj, new NullProgressMonitor());
  -				if( projPackages.length > 0 ) {
  -					return projPackages;
  -				}
  -			}
  -			
  -			return new IPackage[] { createTopPackage(new NullProgressMonitor())};
  -		}
  -		
  -		public IPackage createTopPackage(IProgressMonitor monitor) {
  -			IPackage topLevel = null;
  -			switch( assembleType ) {
  -			case WAR:
  -				topLevel = createWarPackages(module[0], monitor); break;
  -			case EAR:
  -				topLevel = createEarPackages(module[0], monitor); break;
  -			case OTHER:
  -				topLevel = createOtherPackages(module[0], monitor); break;
  -			default: break;
  -			}
  -			return topLevel;
  -		}
  -		
  -		public IStatus[] publish(IProgressMonitor monitor) throws CoreException {
  -			IPackage topLevel = createTopPackage(monitor);
  +	protected IStatus[] publish(IDeployableServer jbServer, IModule[] module, IProgressMonitor monitor) throws CoreException {
  +		IPackage topLevel = createTopPackage(module[0], jbServer.getDeployDirectory(), monitor);
   			if( topLevel != null ) {
   				PackagesCore.buildPackage(topLevel, new NullProgressMonitor());
  -				PackagesModel.instance().removePackage((IPackage)topLevel);
  -			}
  -			return null;
  -		}
  -		
  -		public static IPackage createGenericIPackage(IModule module, String deployDirectory, String packageName) {
  -			try {
  -
  -				IProject project = module.getProject();
  -				Assert.isNotNull(project);
  -				
  -				IJavaProject javaProject = JavaCore.create(project);
  -				Assert.isNotNull(javaProject);
  -				
  -				IPath sourcePath;
  -				try {
  -					sourcePath = javaProject.getOutputLocation();
  -				} catch (JavaModelException e) {
  -					e.printStackTrace();
  -					return null;
  -				}
  -				sourcePath = sourcePath.removeFirstSegments(1);
  -				IContainer sourcePathContainer = project.getFolder(sourcePath);
  -				return createGenericIPackage(module, deployDirectory, packageName, sourcePathContainer);
  -			} catch( Exception e ) {
  -				e.printStackTrace();
   			}
   			return null;
   		} 
  +	protected IStatus[] unpublish(IDeployableServer jbServer, IModule[] module, IProgressMonitor monitor) throws CoreException {
  +		IPackage topLevel = createTopPackage(module[0], jbServer.getDeployDirectory(), monitor);
  +		if( topLevel.isDestinationInWorkspace() ) {
  +			String deployDir = jbServer.getDeployDirectory();
   		
  -		public static IPackage createGenericIPackage(IModule module, String deployDirectory, String packageName, IContainer sourceContainer) {
  -			IProject project = module.getProject();
  -			Assert.isNotNull(project);
  -			IPackage jar = PackagesCore.createPackage(project, true);
  -			IPackageWorkingCopy jarWC = jar.createPackageWorkingCopy();
  -				
  -			if( deployDirectory != null ) {
  -				jarWC.setDestinationFolder(new Path(deployDirectory));
  -				jarWC.setExploded(false);
  -			}
  -			jarWC.setName(packageName);
  -			jar = jarWC.savePackage();
  -				
  -			IPackageFileSet classes = PackagesCore.createPackageFileSet(project);
  -			IPackageFileSetWorkingCopy classesWC = classes.createFileSetWorkingCopy();
  -			classesWC.setIncludesPattern("**/*");
  -			classesWC.setSourceContainer(sourceContainer);
  -			classes = classesWC.saveFileSet();
  -			jar.addChild(classes);
  -			return jar;
  -		}
  -		
  -		public IPackage createWarPackages(IModule module, IProgressMonitor monitor) {
  -			try {
  -				IProject proj = module.getProject();
  -				IPackage topLevel = createGenericIPackage(module, jbServer.getDeployDirectory(), proj.getName() + ".war");
  -				IPackageFolder webinf = addFolder(proj, topLevel, WEBINF);
  -				IPackageFolder metainf = addFolder(proj, topLevel, METAINF);
  -				IPackageFolder lib = addFolder(proj, metainf, LIB);
  -				addFileset(proj, metainf, WEBCONTENT + Path.SEPARATOR + METAINF, null);
  -				addFileset(proj, webinf, WEBCONTENT + Path.SEPARATOR + WEBINF, null);
  -				
  -				IWebModule webModule = (IWebModule)module.loadAdapter(IWebModule.class, monitor);
  -				IModule[] childModules = webModule.getModules();
  -				
  -				for (int i = 0; i < childModules.length; i++) {
  -					IModule child = childModules[i];
  -					JstPackagesAssembler assembler = new JstPackagesAssembler();
  -					assembler.initialize(new IModule[] {child}, jbServer);
  -					IPackage[] childPackages = assembler.getPackages();
  -					if( childPackages.length > 0 ) {
  -						for( int j = 0; j < childPackages.length; j++ ) {
  -							lib.addChild(childPackages[j]);
  -						}
  +			IPath path = topLevel.getPackageFile().getRawLocation();
  +			IPath p = new Path(deployDir).append(path.lastSegment());
  +			p.toFile().delete();
   					} else {
  -						lib.addChild(createGenericIPackage(child, null, child.getProject().getName() + ".jar"));
  -					}
  -				}
  -				return topLevel;
  -			} catch( Exception e ) {
  -				e.printStackTrace();
  +			IPath path = topLevel.getPackageFilePath();
  +			path.toFile().delete();
   			}
  +		
   			return null;
   		}
  -		public IPackage createEarPackages(IModule module, IProgressMonitor monitor) {
  -			IProject proj = module.getProject();
  -			IContainer sourceContainer = proj.getFolder(EARCONTENT);
  -
  -			IPackage topLevel = createGenericIPackage(module, jbServer.getDeployDirectory(), proj.getName() + ".ear", sourceContainer);
  -			addFileset(proj, topLevel, EARCONTENT, "**/*.*");
  -			
  -			// now add children
  -			IEnterpriseApplication earModule = (IEnterpriseApplication)module.loadAdapter(IEnterpriseApplication.class, monitor);
  -			IModule[] childModules = earModule.getModules();
  -			for( int i = 0; i < childModules.length; i++ ) {
  -				IModule child = childModules[i];
  -				JstPackagesAssembler assembler = new JstPackagesAssembler();
  -				assembler.initialize(new IModule[] {child}, jbServer);
  -				IPackage[] childPackages = assembler.getPackages();
  -				if( childPackages.length > 0 ) {
  -					for( int j = 0; j < childPackages.length; j++ ) {
  -						topLevel.addChild(childPackages[j]);
  -					}
  -				} else {
  -					topLevel.addChild(createGenericIPackage(child, null, child.getProject().getName() + ".jar"));
  -				}
  -			}
   			
  -			PackagesCore.buildPackage(topLevel, new NullProgressMonitor());
  -			PackagesModel.instance().removePackage((IPackage)topLevel);
  -			return null;
  +    protected void checkClosed(IModule[] module) throws CoreException {
  +    	for(int i=0;i<module.length;i++) {
  +    		if(module[i] instanceof DeletedModule) {	
  +                IStatus status = new Status(IStatus.ERROR,JBossServerCorePlugin.PLUGIN_ID,0, "Failure", null);
  +                throw new CoreException(status);
   		}
  -		public IPackage createOtherPackages(IModule module, IProgressMonitor monitor) {
  -			return createGenericIPackage(module, null, module.getName() + ".jar");
   		}
  -
  -		public IStatus[] unpublish(IProgressMonitor monitor) throws CoreException {
  -			String deployDir = jbServer.getDeployDirectory();
  -			String fileName = module[0].getProject().getName();
  -			String ext = ".jar";
  -			switch( assembleType ) {
  -				case WAR: ext = ".war"; break;
  -				case EAR: ext = ".ear"; break;
  -				case SAR: ext = ".sar"; break;
  -				case OTHER: ext = ".jar"; break;
  -				default: ext = ".jar"; break;
   			}
   			
  -			IPath filePath = new Path(deployDir).append(fileName + ext);
  -			filePath.toFile().delete();
  -			return null;
  +	protected IPackage createTopPackage(IModule module, String deployDir, IProgressMonitor monitor) {
  +		IPackageType type = ModulePackageTypeConverter.getPackageTypeFor(module);
  +		if( type != null ) {
  +    		IPackage topLevel = type.createDefaultConfiguration(module.getProject(), monitor);
  +    		topLevel.setDestinationFolder(new Path(deployDir));
  +    		//topLevel.setDestinationFolder(new Path("c:\\test"));
  +    		return topLevel;
   		}
  -		
  -		
  -		protected static IPackageFolder addFolder(IProject project, IPackageNode parent, String name) {
  -			IPackageFolder folder = PackagesCore.createPackageFolder(project);
  -			IPackageFolderWorkingCopy folderWC = folder.createFolderWorkingCopy();
  -			folderWC.setName(name);
  -			folder = folderWC.saveFolder();
  -			parent.addChild(folder);
  -			return folder;
  -		}
  -		protected static IPackageFileSet addFileset(IProject project, IPackageNode parent, String sourcePath, String includePattern) {
  -			IPackageFileSet fs = PackagesCore.createPackageFileSet(project);
  -			IPackageFileSetWorkingCopy fswc = fs.createFileSetWorkingCopy();
  -			Assert.isNotNull(project);
  -			IJavaProject javaProject = JavaCore.create(project);
  -			Assert.isNotNull(javaProject);
  -			IContainer sourceContainer = project.getFolder(new Path(sourcePath));
  -
  -			fswc.setSourceContainer(sourceContainer);
  -			fswc.setIncludesPattern(  includePattern == null ?  "**/*" : includePattern );
  -			fs = fswc.saveFileSet();
  -			parent.addChild(fs);
  -			return fs;
  +		return null;
   		}
  -}
  -
   
   }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server
	...
Message-ID: <E1Gxtko-0007UW-7h@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server   
                        JBossServerBehavior.java
                        JBossServerLaunchConfiguration.java
                        JBossServer.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.18      +2 -123    jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerBehavior.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- JBossServerBehavior.java	11 Dec 2006 15:43:39 -0000	1.17
  +++ JBossServerBehavior.java	22 Dec 2006 23:24:42 -0000	1.18
  @@ -21,8 +21,6 @@
    */
   package org.jboss.ide.eclipse.as.core.server;
   
  -import org.eclipse.core.resources.IProject;
  -import org.eclipse.core.resources.ResourcesPlugin;
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.NullProgressMonitor;
  @@ -30,29 +28,16 @@
   import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
   import org.eclipse.debug.core.ILaunchManager;
   import org.eclipse.debug.core.model.IProcess;
  -import org.eclipse.wst.server.core.IModule;
   import org.eclipse.wst.server.core.IServer;
  -import org.eclipse.wst.server.core.internal.Module;
  -import org.eclipse.wst.server.core.internal.Server;
  -import org.eclipse.wst.server.core.model.IModuleResourceDelta;
  -import org.eclipse.wst.server.core.model.ModuleFactoryDelegate;
  -import org.eclipse.wst.server.core.model.ServerBehaviourDelegate;
  -import org.jboss.ide.eclipse.as.core.JBossServerCore;
   import org.jboss.ide.eclipse.as.core.model.EventLogModel;
   import org.jboss.ide.eclipse.as.core.model.ServerProcessModel;
   import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  -import org.jboss.ide.eclipse.as.core.module.PathModuleFactory;
  -import org.jboss.ide.eclipse.as.core.publishers.IJBossServerPublisher;
  -import org.jboss.ide.eclipse.as.core.publishers.JstPackagesPublisher;
  -import org.jboss.ide.eclipse.as.core.publishers.NullPublisher;
  -import org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher;
  -import org.jboss.ide.eclipse.as.core.publishers.PathPublisher;
   import org.jboss.ide.eclipse.as.core.runtime.server.IServerStatePoller;
   import org.jboss.ide.eclipse.as.core.runtime.server.polling.PollThread;
   import org.jboss.ide.eclipse.as.core.runtime.server.polling.TwiddlePoller;
  -import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  +import org.jboss.ide.eclipse.as.core.server.stripped.DeployableServerBehavior;
   
  -public class JBossServerBehavior extends ServerBehaviourDelegate {
  +public class JBossServerBehavior extends DeployableServerBehavior {
   	public static final String LAUNCH_CONFIG_DEFAULT_CLASSPATH = "__JBOSS_SERVER_BEHAVIOR_LAUNCH_CONFIG_DEFAULT_CLASSPATH__";
   	
   	
  @@ -143,113 +128,7 @@
   			pollThread.cancel();
   		}
   		this.pollThread = new PollThread("Server Poller", new TwiddlePoller(), expectedState, this);
  -//		this.pollThread = new PollThread("Server Poller", new TimeoutPoller(), expectedState);
   		pollThread.start();
   	}
   	
  -	
  -	// By default, goes to check if the members are all the same or any changes
  -	public IModuleResourceDelta[] getPublishedResourceDelta(IModule[] module) {
  -		return ((Server)getServer()).getPublishedResourceDelta(module);
  -	}
  -	
  -	protected void publishModule(int kind, int deltaKind, IModule[] module, IProgressMonitor monitor) throws CoreException {
  -		// kind = [incremental, full, auto, clean] = [1,2,3,4]
  -		// delta = [no_change, added, changed, removed] = [0,1,2,3]
  -
  -		System.out.print("publishing module: ");
  -		switch( kind ) {
  -			case IServer.PUBLISH_INCREMENTAL: System.out.print("incremental, "); break;
  -			case IServer.PUBLISH_FULL: System.out.print("full, "); break;
  -			case IServer.PUBLISH_AUTO: System.out.print("auto, "); break;
  -			case IServer.PUBLISH_CLEAN: System.out.print("clean, "); break;
  -		}
  -		switch( deltaKind ) {
  -			case ServerBehaviourDelegate.NO_CHANGE: System.out.print("no change"); break;
  -			case ServerBehaviourDelegate.ADDED: System.out.print("added"); break;
  -			case ServerBehaviourDelegate.CHANGED: System.out.print("changed"); break;
  -			case ServerBehaviourDelegate.REMOVED: System.out.print("removed"); break;
  -		}
  -		System.out.println("");
  -		
  -		if( module.length == 0 ) return;
  -		IJBossServerPublisher publisher;
  -
  -		int modulePublishState = getServer().getModulePublishState(module) + 0;
  -		
  -		/**
  -		 * If our modules are already packaged as ejb jars, wars, aop files, 
  -		 * then go ahead and publish
  -		 */
  -		if( arePathModules(module)) {
  -			publisher = new PathPublisher(JBossServerCore.getServer(getServer()), this);
  -		} else if( hasPackagingConfiguration(module) ) {
  -			publisher = new PackagesPublisher(JBossServerCore.getServer(getServer()));
  -		} else if( areJstModules(module)){
  -			//publisher = new JstPublisher(JBossServerCore.getServer(getServer()));
  -			publisher = new JstPackagesPublisher(JBossServerCore.getServer(getServer()));
  -		} else {
  -			publisher = new NullPublisher();
  -		}
  -		
  -		publisher.publishModule(kind, deltaKind, modulePublishState, module, monitor);
  -		setModulePublishState(module, publisher.getPublishState());
  -	}
  -	
  -	// Is it just a file being deployed? 
  -	// .xml, or .jar specifically
  -	public boolean arePathModules(IModule[] module) {
  -		if( module.length == 1 && module[0] instanceof Module ) {
  -			ModuleFactoryDelegate delegate = 
  -				((Module)module[0]).getModuleFactory().getDelegate(new NullProgressMonitor());
  -			if( delegate instanceof PathModuleFactory ) return true;
  -		}
  -		return false;
  -	}
  -	
  -	/* Temporary and will need to be fixed */
  -	protected boolean areJstModules(IModule[] module) {
  -		String type;
  -		for( int i = 0; i < module.length; i++ ) {
  -			type = module[i].getModuleType().getId();
  -			if( type.equals("jst.ejb") || type.equals("jst.client") 
  -					|| type.equals("jst.web") || type.equals("jst.ear")) 
  -				continue;
  -			return false;
  -		}
  -		return true;
  -	}
  -	/* Temporary and will need to be fixed */
  -	protected boolean hasPackagingConfiguration(IModule[] module) {
  -		try {
  -			String projectName = module[0].getName();
  -			IProject proj = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
  -			return PackagesCore.getProjectPackages(proj, new NullProgressMonitor()).length == 0 ? false : true;
  -		} catch( Exception e ) {} 
  -		return false;
  -	}
  -		
  -	
  -	
  -	
  -	/*
  -	 * Change the state of the server
  -	 */
  -	public void setServerStarted() {
  -		setServerState(IServer.STATE_STARTED);
  -	}
  -	
  -	public void setServerStarting() {
  -		setServerState(IServer.STATE_STARTING);
  -	}
  -	
  -	public void setServerStopped() {
  -		setServerState(IServer.STATE_STOPPED);
  -	}
  -	
  -	public void setServerStopping() {
  -		setServerState(IServer.STATE_STOPPING);
  -	}
  -
  -	
   }
  
  
  
  1.2       +0 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerLaunchConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerLaunchConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerLaunchConfiguration.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- JBossServerLaunchConfiguration.java	10 Nov 2006 00:26:25 -0000	1.1
  +++ JBossServerLaunchConfiguration.java	22 Dec 2006 23:24:42 -0000	1.2
  @@ -72,7 +72,6 @@
   		IServer server = ServerUtil.getServer(configuration);
   		JBossServerBehavior jbossServerBehavior = (JBossServerBehavior) server.getAdapter(JBossServerBehavior.class);
   		return jbossServerBehavior;
  -
   	}
   	
   	public static JBossServer getJBossServer(ILaunchConfiguration configuration) throws CoreException {
  
  
  
  1.18      +3 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServer.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- JBossServer.java	13 Dec 2006 18:35:21 -0000	1.17
  +++ JBossServer.java	22 Dec 2006 23:24:42 -0000	1.18
  @@ -43,10 +43,12 @@
   import org.jboss.ide.eclipse.as.core.runtime.IJBossServerLaunchDefaults;
   import org.jboss.ide.eclipse.as.core.runtime.IJBossServerRuntime;
   import org.jboss.ide.eclipse.as.core.runtime.server.ServerLaunchDefaults;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
   import org.jboss.ide.eclipse.as.core.server.attributes.IServerStartupParameters;
   import org.jboss.ide.eclipse.as.core.util.ArgsUtil;
   
  -public class JBossServer extends ServerDelegate implements IServerStartupParameters {
  +public class JBossServer extends ServerDelegate 
  +		implements IServerStartupParameters, IDeployableServer {
   
   	
   	public JBossServer() {
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped
	...
Message-ID: <E1Gxtko-0007Um-Co@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Added:       as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped    
                        DeployableServerRuntime.java DeployableServer.java
                        DeployableLaunchConfiguration.java
                        DeployableServerBehavior.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableServerRuntime.java
  
  Index: DeployableServerRuntime.java
  ===================================================================
  package org.jboss.ide.eclipse.as.core.server.stripped;
  
  import org.eclipse.wst.server.core.model.RuntimeDelegate;
  
  public class DeployableServerRuntime extends RuntimeDelegate {
  
  	public DeployableServerRuntime() {
  		// TODO Auto-generated constructor stub
  	}
  
  }
  
  
  
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableServer.java
  
  Index: DeployableServer.java
  ===================================================================
  package org.jboss.ide.eclipse.as.core.server.stripped;
  
  import org.eclipse.core.runtime.CoreException;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.core.runtime.IStatus;
  import org.eclipse.wst.server.core.IModule;
  import org.eclipse.wst.server.core.IServerWorkingCopy;
  import org.eclipse.wst.server.core.model.ServerDelegate;
  import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper;
  import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
  
  public class DeployableServer extends ServerDelegate implements IDeployableServer {
  
  	public static final String DEPLOY_DIRECTORY = "org.jboss.ide.eclipse.as.core.server.stripped.deploy_directory";
  	
  	public DeployableServer() {
  		// TODO Auto-generated constructor stub
  	}
  
  	public IStatus canModifyModules(IModule[] add, IModule[] remove) {
  		// TODO Auto-generated method stub
  		return null;
  	}
  
  	public IModule[] getChildModules(IModule[] module) {
  		// TODO Auto-generated method stub
  		return null;
  	}
  
  	public IModule[] getRootModules(IModule module) throws CoreException {
  		// TODO Auto-generated method stub
  		return null;
  	}
  
  	public void modifyModules(IModule[] add, IModule[] remove,
  			IProgressMonitor monitor) throws CoreException {
  		// TODO Auto-generated method stub
  
  	}
  
  	/* (non-Javadoc)
  	 * @see org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer#getDeployDirectory()
  	 */
  	public String getDeployDirectory() {
  		return getAttribute(DEPLOY_DIRECTORY, "");
  	}
  	
  	public ServerAttributeHelper getAttributeHelper() {
  		IServerWorkingCopy copy = getServerWorkingCopy();
  		if( copy == null ) {
  			copy = getServer().createWorkingCopy();
  		}
  		return new ServerAttributeHelper(getServer(), copy);
  	}
  
  
  }
  
  
  
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableLaunchConfiguration.java
  
  Index: DeployableLaunchConfiguration.java
  ===================================================================
  package org.jboss.ide.eclipse.as.core.server.stripped;
  
  import org.eclipse.core.runtime.CoreException;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.debug.core.ILaunch;
  import org.eclipse.debug.core.ILaunchConfiguration;
  import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
  import org.eclipse.debug.core.model.ILaunchConfigurationDelegate;
  import org.eclipse.wst.server.core.IServer;
  import org.eclipse.wst.server.core.ServerUtil;
  import org.jboss.ide.eclipse.as.core.server.JBossServerBehavior;
  
  public class DeployableLaunchConfiguration implements
  		ILaunchConfigurationDelegate {
  
  	public static final String ACTION_KEY = "org.jboss.ide.eclipse.as.core.server.stripped.DeployableLaunchConfiguration.Action";
  	public static final String START = "_START_";
  	public static final String STOP = "_STOP_";
  
  	public static DeployableServerBehavior getServerBehavior(ILaunchConfiguration configuration) throws CoreException {
  		IServer server = ServerUtil.getServer(configuration);
  		DeployableServerBehavior jbossServerBehavior = (DeployableServerBehavior) server.getAdapter(DeployableServerBehavior.class);
  		return jbossServerBehavior;
  	}
  
  	public void launch(ILaunchConfiguration configuration, String mode,
  			ILaunch launch, IProgressMonitor monitor) throws CoreException {
  		String action = configuration.getAttribute(ACTION_KEY, START);
  		DeployableServerBehavior behavior = getServerBehavior(configuration);
  		if( START.equals(action)) behavior.setServerStarted();
  		if( STOP.equals(action)) behavior.setServerStopped();
  	}
  }
  
  
  
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableServerBehavior.java
  
  Index: DeployableServerBehavior.java
  ===================================================================
  package org.jboss.ide.eclipse.as.core.server.stripped;
  
  import org.eclipse.core.resources.IProject;
  import org.eclipse.core.resources.ResourcesPlugin;
  import org.eclipse.core.runtime.CoreException;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.core.runtime.NullProgressMonitor;
  import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
  import org.eclipse.wst.server.core.IModule;
  import org.eclipse.wst.server.core.IServer;
  import org.eclipse.wst.server.core.internal.Module;
  import org.eclipse.wst.server.core.internal.Server;
  import org.eclipse.wst.server.core.model.IModuleResourceDelta;
  import org.eclipse.wst.server.core.model.ModuleFactoryDelegate;
  import org.eclipse.wst.server.core.model.ServerBehaviourDelegate;
  import org.jboss.ide.eclipse.as.core.JBossServerCore;
  import org.jboss.ide.eclipse.as.core.module.PathModuleFactory;
  import org.jboss.ide.eclipse.as.core.publishers.IJBossServerPublisher;
  import org.jboss.ide.eclipse.as.core.publishers.JstPackagesPublisher;
  import org.jboss.ide.eclipse.as.core.publishers.NullPublisher;
  import org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher;
  import org.jboss.ide.eclipse.as.core.publishers.PathPublisher;
  import org.jboss.ide.eclipse.as.core.server.JBossServerLaunchConfiguration;
  import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  
  public class DeployableServerBehavior extends ServerBehaviourDelegate {
  
  	public DeployableServerBehavior() {
  	}
  
  	public void stop(boolean force) {
  		setServerStopped(); // simple enough
  	}
  	
  	public void setupLaunchConfiguration(ILaunchConfigurationWorkingCopy workingCopy, IProgressMonitor monitor) throws CoreException {
  		workingCopy.setAttribute(DeployableLaunchConfiguration.ACTION_KEY, DeployableLaunchConfiguration.START);
  	}
  
  
  	
  	// By default, goes to check if the members are all the same or any changes
  	public IModuleResourceDelta[] getPublishedResourceDelta(IModule[] module) {
  		return ((Server)getServer()).getPublishedResourceDelta(module);
  	}
  	
  	protected void publishModule(int kind, int deltaKind, IModule[] module, IProgressMonitor monitor) throws CoreException {
  		// kind = [incremental, full, auto, clean] = [1,2,3,4]
  		// delta = [no_change, added, changed, removed] = [0,1,2,3]
  
  		System.out.print("publishing module: ");
  		switch( kind ) {
  			case IServer.PUBLISH_INCREMENTAL: System.out.print("incremental, "); break;
  			case IServer.PUBLISH_FULL: System.out.print("full, "); break;
  			case IServer.PUBLISH_AUTO: System.out.print("auto, "); break;
  			case IServer.PUBLISH_CLEAN: System.out.print("clean, "); break;
  		}
  		switch( deltaKind ) {
  			case ServerBehaviourDelegate.NO_CHANGE: System.out.print("no change"); break;
  			case ServerBehaviourDelegate.ADDED: System.out.print("added"); break;
  			case ServerBehaviourDelegate.CHANGED: System.out.print("changed"); break;
  			case ServerBehaviourDelegate.REMOVED: System.out.print("removed"); break;
  		}
  		System.out.println("");
  		
  		if( module.length == 0 ) return;
  		IJBossServerPublisher publisher;
  
  		int modulePublishState = getServer().getModulePublishState(module) + 0;
  		
  		/**
  		 * If our modules are already packaged as ejb jars, wars, aop files, 
  		 * then go ahead and publish
  		 */
  		if( arePathModules(module)) {
  			publisher = new PathPublisher(JBossServerCore.getDeployableServer(getServer()), this);
  		} else if( hasPackagingConfiguration(module) ) {
  			publisher = new PackagesPublisher(JBossServerCore.getDeployableServer(getServer()));
  		} else if( areJstModules(module)){
  			publisher = new JstPackagesPublisher(JBossServerCore.getDeployableServer(getServer()));
  		} else {
  			publisher = new NullPublisher();
  		}
  		
  		publisher.publishModule(kind, deltaKind, modulePublishState, module, monitor);
  		setModulePublishState(module, publisher.getPublishState());
  	}
  	
  	// Is it just a file being deployed? 
  	// .xml, or .jar specifically
  	public boolean arePathModules(IModule[] module) {
  		if( module.length == 1 && module[0] instanceof Module ) {
  			ModuleFactoryDelegate delegate = 
  				((Module)module[0]).getModuleFactory().getDelegate(new NullProgressMonitor());
  			if( delegate instanceof PathModuleFactory ) return true;
  		}
  		return false;
  	}
  	
  	/* Temporary and will need to be fixed */
  	protected boolean areJstModules(IModule[] module) {
  		String type;
  		for( int i = 0; i < module.length; i++ ) {
  			type = module[i].getModuleType().getId();
  			if( type.equals("jst.ejb") || type.equals("jst.client") 
  					|| type.equals("jst.web") || type.equals("jst.ear")) 
  				continue;
  			return false;
  		}
  		return true;
  	}
  	/* Temporary and will need to be fixed */
  	protected boolean hasPackagingConfiguration(IModule[] module) {
  		try {
  			String projectName = module[0].getName();
  			IProject proj = ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
  			return PackagesCore.getProjectPackages(proj, new NullProgressMonitor()).length == 0 ? false : true;
  		} catch( Exception e ) {} 
  		return false;
  	}
  	
  	
  	
  	
  	
  	/*
  	 * Change the state of the server
  	 */
  	public void setServerStarted() {
  		setServerState(IServer.STATE_STARTED);
  	}
  	
  	public void setServerStarting() {
  		setServerState(IServer.STATE_STARTING);
  	}
  	
  	public void setServerStopped() {
  		setServerState(IServer.STATE_STOPPED);
  	}
  	
  	public void setServerStopping() {
  		setServerState(IServer.STATE_STOPPING);
  	}
  }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/META-INF ...
Message-ID: <E1Gxtko-0007Ut-Gl@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/META-INF 
                        MANIFEST.MF
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.14      +2 -0      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- MANIFEST.MF	22 Nov 2006 21:41:43 -0000	1.13
  +++ MANIFEST.MF	22 Dec 2006 23:24:42 -0000	1.14
  @@ -27,11 +27,13 @@
   Eclipse-LazyStart: true
   Export-Package: org.jboss.ide.eclipse.as.core,
    org.jboss.ide.eclipse.as.core.model,
  + org.jboss.ide.eclipse.as.core.publishers,
    org.jboss.ide.eclipse.as.core.runtime,
    org.jboss.ide.eclipse.as.core.runtime.server,
    org.jboss.ide.eclipse.as.core.runtime.server.polling,
    org.jboss.ide.eclipse.as.core.server,
    org.jboss.ide.eclipse.as.core.server.attributes,
  + org.jboss.ide.eclipse.as.core.server.stripped,
    org.jboss.ide.eclipse.as.core.util
   Bundle-ClassPath: dom4j-1.6.1.jar,
    jaxen-1.1-beta-6.jar,
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.core  ...
Message-ID: <E1Gxtko-0007V0-KK@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core  plugin.xml
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.23      +69 -1     jbosside/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- plugin.xml	11 Dec 2006 15:51:54 -0000	1.22
  +++ plugin.xml	22 Dec 2006 23:24:42 -0000	1.23
  @@ -43,6 +43,22 @@
               startTimeout="450000"
               stopTimeout="450000"
               supportsRemoteHosts="false"/>
  +      <serverType
  +            behaviourClass="org.jboss.ide.eclipse.as.core.server.stripped.DeployableServerBehavior"
  +            class="org.jboss.ide.eclipse.as.core.server.stripped.DeployableServer"
  +            description="A server who&apos;s only functionality is to deploy files"
  +            hasConfiguration="true"
  +            id="org.jboss.ide.eclipse.as.systemCopyServer"
  +            initialState="stopped"
  +            launchConfigId="org.jboss.ide.eclipse.as.core.server.stripped.launchConfiguration"
  +            launchModes="run,debug"
  +            name="JBoss System Copy Server"
  +            runtime="false"
  +            runtimeTypeId="org.jboss.ide.eclipse.as.runtime.stripped"
  +            startBeforePublish="false"
  +            startTimeout="100000"
  +            stopTimeout="100000"
  +            supportsRemoteHosts="true"/>
      </extension>
   
      <extension
  @@ -103,6 +119,36 @@
                   types="jboss.packaged.project"
                   versions="1.0"/>
         </runtimeType>
  +      <runtimeType
  +            class="org.jboss.ide.eclipse.as.core.server.stripped.DeployableServerRuntime"
  +            description="A jboss stripped server runtime"
  +            id="org.jboss.ide.eclipse.as.runtime.stripped"
  +            name="JBoss Stripped Server Runtime"
  +            vendor="%providerName"
  +            version="1.0">
  +          <moduleType
  +                types="jst.web"
  +                versions="2.2, 2.3, 2.4"/>
  +          <moduleType
  +                types="jst.ejb"
  +                versions="1.0, 1.1, 2.0, 2.1"/>
  +          <moduleType
  +                types="jst.ear"
  +                versions="1.2, 1.3, 1.4"/>
  +          <moduleType
  +                types="jboss.archive"
  +                versions="1.0"/>
  +          <moduleType
  +                types="jboss.ejb30"
  +                versions="1.0"/>
  +          <moduleType
  +                types="jboss.xml"
  +                versions="1.0"/>                
  +          <moduleType
  +                types="jboss.packaged.project"
  +                versions="1.0"/>
  +            
  +      </runtimeType>
      </extension>
   
   
  @@ -117,6 +163,13 @@
               name="JBoss Application Server"
               public="true"
               sourceLocatorId="org.eclipse.jdt.launching.sourceLocator.JavaSourceLookupDirector"/>
  +      <launchConfigurationType
  +            delegate="org.jboss.ide.eclipse.as.core.server.stripped.DeployableLaunchConfiguration"
  +            id="org.jboss.ide.eclipse.as.core.server.stripped.launchConfiguration"
  +            modes="run,debug"
  +            name="Stripped Server Launch Configuration"
  +            public="false"
  +            sourceLocatorId="org.eclipse.jdt.launching.sourceLocator.JavaSourceLookupDirector"/>
      </extension>
   	
   	
  @@ -146,7 +199,11 @@
         <moduleFactory
               class="org.jboss.ide.eclipse.as.core.module.PackagedProjectModuleFactory"
               id="org.jboss.ide.eclipse.as.core.PackagedModuleFactory"
  -            projects="true"/>
  +            projects="true">
  +         <moduleType
  +               types="jboss.packaged.project"
  +               versions="1.0"/>
  +      </moduleFactory>
      </extension>
      
      	<extension
  @@ -345,6 +402,17 @@
               id="jboss.packaged.project"
               name="Packaged Project"/>
      </extension>
  +   <extension
  +         point="org.jboss.ide.eclipse.packages.core.packageTypes">
  +      <packageType
  +            class="org.jboss.ide.eclipse.as.core.packages.WarPackageType"
  +            id="org.jboss.ide.eclipse.as.core.packages.warPackage"
  +            label="WAR"/>
  +      <packageType
  +            class="org.jboss.ide.eclipse.as.core.packages.EarPackageType"
  +            id="org.jboss.ide.eclipse.as.core.packages.earPackage"
  +            label="EAR"/>
  +   </extension>
      
   
   </plugin>
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages
	...
Message-ID: <E1Gxtko-0007VG-QD@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Added:       as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages    
                        WarPackageType.java
                        ObscurelyNamedPackageTypeSuperclass.java
                        EarPackageType.java ModulePackageTypeConverter.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/WarPackageType.java
  
  Index: WarPackageType.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.core.packages;
  
  import org.eclipse.core.resources.IContainer;
  import org.eclipse.core.resources.IProject;
  import org.eclipse.core.runtime.Assert;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.core.runtime.Path;
  import org.eclipse.jdt.core.IJavaProject;
  import org.eclipse.jdt.core.JavaCore;
  import org.eclipse.jst.server.core.IWebModule;
  import org.eclipse.wst.server.core.IModule;
  import org.eclipse.wst.server.core.IModuleArtifact;
  import org.eclipse.wst.server.core.internal.ServerPlugin;
  import org.jboss.ide.eclipse.packages.core.model.IPackage;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public class WarPackageType extends ObscurelyNamedPackageTypeSuperclass {
  
  	public String getAssociatedModuleType() {
  		return "jst.web";
  	}
  
  	public IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor) {
  		IModule mod = getModule(project);
  		if( mod == null ) 
  			return createDefaultConfiguration2(project, monitor);
  		else
  			return createDefaultConfigFromModule(mod, monitor);
  	}
  	
  	protected IPackage createDefaultConfiguration2(IProject project, IProgressMonitor monitor) {
  		IPackage topLevel = createGenericIPackage(project, null, project.getName() + ".war");
  		topLevel.setDestinationContainer(project);
  		IPackageFolder webinf = addFolder(project, topLevel, WEBINF);
  		IPackageFolder metainf = addFolder(project, topLevel, METAINF);
  		IPackageFolder lib = addFolder(project, metainf, LIB);
  		addFileset(project, metainf, WEBCONTENT + Path.SEPARATOR + METAINF, null);
  		addFileset(project, webinf, WEBCONTENT + Path.SEPARATOR + WEBINF, null);
  		return topLevel;
  	}
  
  	protected IPackage createDefaultConfigFromModule(IModule mod, IProgressMonitor monitor) {
  		try {
  			IProject project = mod.getProject();
  
  			IPackage topLevel = createGenericIPackage(project, null, project.getName() + ".war");
  			topLevel.setDestinationContainer(project);
  			IPackageFolder webinf = addFolder(project, topLevel, WEBINF);
  			IPackageFolder metainf = addFolder(project, topLevel, METAINF);
  			IPackageFolder lib = addFolder(project, metainf, LIB);
  			addFileset(project, metainf, WEBCONTENT + Path.SEPARATOR + METAINF, null);
  			addFileset(project, webinf, WEBCONTENT + Path.SEPARATOR + WEBINF, null);
  
  			IWebModule webModule = (IWebModule)mod.loadAdapter(IWebModule.class, monitor);
  			IModule[] childModules = webModule.getModules();
  			
  			for (int i = 0; i < childModules.length; i++) {
  				IModule child = childModules[i];
  				// package each child and add
  				lib.addChild(createGenericIPackage(child.getProject(), null, child.getProject().getName() + ".jar"));
  			}
  			return topLevel;
  		} catch( Exception e ) {
  			e.printStackTrace();
  		}
  		return null;
  	}
  }
  
  
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/ObscurelyNamedPackageTypeSuperclass.java
  
  Index: ObscurelyNamedPackageTypeSuperclass.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.core.packages;
  
  import org.eclipse.core.resources.IContainer;
  import org.eclipse.core.resources.IProject;
  import org.eclipse.core.runtime.Assert;
  import org.eclipse.core.runtime.IPath;
  import org.eclipse.core.runtime.Path;
  import org.eclipse.jdt.core.IJavaProject;
  import org.eclipse.jdt.core.JavaCore;
  import org.eclipse.jdt.core.JavaModelException;
  import org.eclipse.wst.server.core.IModule;
  import org.eclipse.wst.server.core.IModuleArtifact;
  import org.eclipse.wst.server.core.internal.ServerPlugin;
  import org.jboss.ide.eclipse.packages.core.model.IPackage;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFileSet;
  import org.jboss.ide.eclipse.packages.core.model.IPackageFolder;
  import org.jboss.ide.eclipse.packages.core.model.IPackageNode;
  import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  import org.jboss.ide.eclipse.packages.core.model.types.AbstractPackageType;
  import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public abstract class ObscurelyNamedPackageTypeSuperclass extends AbstractPackageType {
  	protected static final String METAINF = "META-INF";
  	protected static final String WEBINF = "WEB-INF";
  	protected static final String LIB = "lib";
  	protected static final String WEBCONTENT = "WebContent";
  	protected static final String EARCONTENT = "EarContent";
  
  
  	protected boolean isModuleType(IModule module, String moduleTypeId){	
  		if(module.getModuleType()!=null && moduleTypeId.equals(module.getModuleType().getId()))
  			return true;
  		return false;
  	}
  
  	protected IModule getModule(IProject project) {
  		IModuleArtifact moduleArtifact = ServerPlugin.loadModuleArtifact(project);
  		return moduleArtifact == null ? null : moduleArtifact.getModule();
  	}
  	
  	// Find the source folder, then create the IPackage appropriately
  	public static IPackage createGenericIPackage(IProject project, String deployDirectory, String packageName) {
  		try {
  			IJavaProject javaProject = JavaCore.create(project);
  			Assert.isNotNull(javaProject);
  			
  			IPath sourcePath;
  			try {
  				sourcePath = javaProject.getOutputLocation();
  			} catch (JavaModelException e) {
  				e.printStackTrace();
  				return null;
  			}
  			sourcePath = sourcePath.removeFirstSegments(1);
  			IContainer sourcePathContainer = project.getFolder(sourcePath);
  			return createGenericIPackage(project, deployDirectory, packageName, sourcePathContainer);
  		} catch( Exception e ) {
  			e.printStackTrace();
  		}
  		return null;
  	} 
  	
  	// Create a detached package with some generic settings
  	public static IPackage createGenericIPackage(IProject project, String deployDirectory, String packageName, IContainer sourceContainer) {
  		IPackage jar = PackagesCore.createDetachedPackage(project, true);
  			
  		if( deployDirectory != null ) {
  			jar.setDestinationFolder(new Path(deployDirectory));
  			jar.setExploded(false);
  		}
  		jar.setName(packageName);
  			
  		IPackageFileSet classes = PackagesCore.createDetachedPackageFileSet(project);
  		classes.setIncludesPattern("**/*");
  		classes.setSourceContainer(sourceContainer);
  		jar.addChild(classes);
  		return jar;
  	}
  
  	
  	protected static IPackageFolder addFolder(IProject project, IPackageNode parent, String name) {
  		IPackageFolder folder = PackagesCore.createPackageFolder(project);
  		folder.setName(name);
  		parent.addChild(folder);
  		return folder;
  	}
  	protected static IPackageFileSet addFileset(IProject project, IPackageNode parent, String sourcePath, String includePattern) {
  		IPackageFileSet fs = PackagesCore.createPackageFileSet(project);
  		Assert.isNotNull(project);
  		IJavaProject javaProject = JavaCore.create(project);
  		Assert.isNotNull(javaProject);
  		IContainer sourceContainer = project.getFolder(new Path(sourcePath));
  
  		fs.setSourceContainer(sourceContainer);
  		fs.setIncludesPattern(  includePattern == null ?  "**/*" : includePattern );
  		parent.addChild(fs);
  		return fs;
  	}
  	
  	public int getSupportFor(IProject project) {
  		String modType = getAssociatedModuleType();
  		IModule module = getModule(project);
  
  		if( modType == null )  // we require no module type
  			return IPackageType.SUPPORT_FULL;
  			
  		if( module == null ) // project is not a module
  			return IPackageType.SUPPORT_FULL;
  
  		// module and modType match
  		if( modType.equals(module.getModuleType().getId())) 
  			return IPackageType.SUPPORT_FULL;
  
  		// it's some other module type. Not Best Match
  		return IPackageType.SUPPORT_CONDITIONAL; 
  	}
  	public abstract String getAssociatedModuleType();
  	
  }
  
  
  
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/EarPackageType.java
  
  Index: EarPackageType.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.core.packages;
  
  import org.eclipse.core.resources.IContainer;
  import org.eclipse.core.resources.IProject;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.core.runtime.NullProgressMonitor;
  import org.eclipse.jst.server.core.IEnterpriseApplication;
  import org.eclipse.wst.server.core.IModule;
  import org.jboss.ide.eclipse.packages.core.model.IPackage;
  import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public class EarPackageType extends ObscurelyNamedPackageTypeSuperclass {
  	public String getAssociatedModuleType() {
  		return "jst.ear";
  	}
  
  	public IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor) {
  		IModule mod = getModule(project);
  		if( mod != null ) 
  			return createDefaultConfigFromModule(mod, monitor);
  		else
  			return createDefaultConfiguration2(project, monitor);
  	}
  	
  	public IPackage createDefaultConfiguration2(IProject project,
  			IProgressMonitor monitor) {
  		return null;
  	}
  
  	public IPackage createDefaultConfigFromModule(IModule module,
  			IProgressMonitor monitor) {
  		IProject project = module.getProject();
  		IContainer sourceContainer = project.getFolder(EARCONTENT);
  
  		IPackage topLevel = createGenericIPackage(project, null, project.getName() + ".ear", sourceContainer);
  		addFileset(project, topLevel, EARCONTENT, "**/*.*");
  		
  		// now add children
  		IEnterpriseApplication earModule = (IEnterpriseApplication)module.loadAdapter(IEnterpriseApplication.class, monitor);
  		IModule[] childModules = earModule.getModules();
  		for( int i = 0; i < childModules.length; i++ ) {
  			IModule child = childModules[i];
  			IPackageType type = ModulePackageTypeConverter.getPackageTypeFor(child);
  			IPackage childPack;
  			if( type == null ) {
  				childPack = createGenericIPackage(child.getProject(), null, child.getProject().getName() + ".jar");
  			} else {
  				childPack = type.createDefaultConfiguration(child.getProject(), new NullProgressMonitor());
  			}
  			topLevel.addChild(childPack);
  		}
  
  		return topLevel;
  	}
  }
  
  
  
  1.1      date: 2006/12/22 23:24:42;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/ModulePackageTypeConverter.java
  
  Index: ModulePackageTypeConverter.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.core.packages;
  
  import org.eclipse.wst.server.core.IModule;
  import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public class ModulePackageTypeConverter {
  	public static final String WAR_PACKAGE_TYPE = "org.jboss.ide.eclipse.as.core.packages.warPackage";
  	public static final String EAR_PACKAGE_TYPE = "org.jboss.ide.eclipse.as.core.packages.earPackage";
  	public static IPackageType getPackageTypeFor(IModule module) {
  		String modType = module.getModuleType().getId();
  		if("jst.web".equals(modType)) {
  			return PackagesCore.getPackageType(WAR_PACKAGE_TYPE);
  		} else if("jst.ear".equals(modType)) {
  			return PackagesCore.getPackageType(EAR_PACKAGE_TYPE);
  		}
  
  		return null;
  	}
  }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:42 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:42 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model
	...
Message-ID: <E1Gxtko-0007VQ-VA@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:42

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model  
                        ServerProcessModel.java EventLogModel.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.9       +2 -2      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/ServerProcessModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerProcessModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/ServerProcessModel.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ServerProcessModel.java	10 Nov 2006 00:26:25 -0000	1.8
  +++ ServerProcessModel.java	22 Dec 2006 23:24:42 -0000	1.9
  @@ -188,7 +188,7 @@
   	
   	
   	public void serverAdded(IServer server) {
  -		if( JBossServerCore.getServer(server) != null ) {
  +		if( JBossServerCore.getJBossServer(server) != null ) {
   			getModel(server.getId(), true);
   		}
   	}
  @@ -197,7 +197,7 @@
   	}
   
   	public void serverRemoved(IServer server) {
  -		if( JBossServerCore.getServer(server) != null ) {
  +		if( JBossServerCore.getJBossServer(server) != null ) {
   			ServerProcessModelEntity ent = getModel(server.getId());
   			map.remove(server.getId());
   		}
  
  
  
  1.4       +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/EventLogModel.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EventLogModel.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/EventLogModel.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- EventLogModel.java	22 Nov 2006 21:41:43 -0000	1.3
  +++ EventLogModel.java	22 Dec 2006 23:24:42 -0000	1.4
  @@ -109,7 +109,7 @@
   	
   	public static class EventLogTreeItem extends SimpleTreeItem {
   		public static final String DATE = "org.jboss.ide.eclipse.as.core.model.EventLogTreeItem.Date";
  -		private String specificType, majorType;
  +		protected String specificType, majorType;
   		public EventLogTreeItem(SimpleTreeItem parent, String majorType, String specificType) {
   			super(parent, null);
   			this.specificType = specificType;
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:43 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:43 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client
	...
Message-ID: <E1Gxtkp-0007Va-3R@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:43

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client  
                        DoNothingClient.java JBossLaunchAdapter.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.5       +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client/DoNothingClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DoNothingClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client/DoNothingClient.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- DoNothingClient.java	10 Nov 2006 00:26:25 -0000	1.4
  +++ DoNothingClient.java	22 Dec 2006 23:24:43 -0000	1.5
  @@ -48,7 +48,7 @@
   	}
   
   	public boolean supports(IServer server, Object launchable, String launchMode) {
  -		if( JBossServerCore.getServer(server) == null ) return false;
  +		if( JBossServerCore.getDeployableServer(server) == null ) return false;
   		return true;
   	}
   
  
  
  
  1.2       +5 -4      jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client/JBossLaunchAdapter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossLaunchAdapter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client/JBossLaunchAdapter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- JBossLaunchAdapter.java	10 Nov 2006 00:26:25 -0000	1.1
  +++ JBossLaunchAdapter.java	22 Dec 2006 23:24:43 -0000	1.2
  @@ -32,6 +32,7 @@
   import org.eclipse.wst.server.core.util.WebResource;
   import org.jboss.ide.eclipse.as.core.JBossServerCore;
   import org.jboss.ide.eclipse.as.core.server.JBossServer;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
   
   public class JBossLaunchAdapter extends LaunchableAdapterDelegate {
   	public JBossLaunchAdapter() {
  @@ -43,12 +44,12 @@
   			throws CoreException {
   		
   		// Only play to jboss servers
  -		JBossServer jbServer = JBossServerCore.getServer(server);
  -		if( jbServer == null ) 
  +		IDeployableServer dserver = JBossServerCore.getDeployableServer(server);
  +		if( dserver == null ) 
   			return null;
   		
  -		if( isJstArtifact(moduleArtifact))
  -			return prepareJstArtifact(moduleArtifact, jbServer);
  +//		if( isJstArtifact(moduleArtifact))
  +//			return prepareJstArtifact(moduleArtifact, dserver);
           
           return new NullLaunchable();
   	}
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:43 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:43 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core
	...
Message-ID: <E1Gxtkp-0007Vh-8g@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:43

  Modified:    as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core 
                        JBossServerCore.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.9       +41 -31    jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/JBossServerCore.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerCore.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/JBossServerCore.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- JBossServerCore.java	22 Nov 2006 21:41:42 -0000	1.8
  +++ JBossServerCore.java	22 Dec 2006 23:24:43 -0000	1.9
  @@ -39,13 +39,14 @@
   import org.jboss.ide.eclipse.as.core.model.PackagesBuildListener;
   import org.jboss.ide.eclipse.as.core.runtime.server.IServerPollerTimeoutListener;
   import org.jboss.ide.eclipse.as.core.server.JBossServer;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
   
   /**
    * 
    * @author rstryker
    *
    */
  -public class JBossServerCore implements IServerLifecycleListener, IRuntimeLifecycleListener {
  +public class JBossServerCore {
   
   	/*
   	 * Static portion
  @@ -59,7 +60,7 @@
   		return instance;
   	}
   	
  -	public static JBossServer getServer(IServer server) {
  +	public static JBossServer getJBossServer(IServer server) {
   		JBossServer jbServer = (JBossServer)server.getAdapter(JBossServer.class);
   		if (jbServer == null) {
   			jbServer = (JBossServer) server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  @@ -67,6 +68,14 @@
   		return jbServer;
   	}
   	
  +	public static IDeployableServer getDeployableServer(IServer server) {
  +		IDeployableServer dep = (IDeployableServer)server.getAdapter(IDeployableServer.class);
  +		if (dep == null) {
  +			dep = (IDeployableServer) server.loadAdapter(IDeployableServer.class, new NullProgressMonitor());
  +		}
  +		return dep;
  +	}
  +	
   	/**
   	 * Return all JBossServer instances from the ServerCore
   	 * @return
  @@ -75,8 +84,8 @@
   		ArrayList servers = new ArrayList();
   		IServer[] iservers = ServerCore.getServers();
   		for( int i = 0; i < iservers.length; i++ ) {
  -			if( getServer(iservers[i]) != null ) {
  -				servers.add(getServer(iservers[i]));
  +			if( getJBossServer(iservers[i]) != null ) {
  +				servers.add(getJBossServer(iservers[i]));
   			}
   		}
   		JBossServer[] ret = new JBossServer[servers.size()];
  @@ -84,11 +93,11 @@
   		return ret;
   	}
   	
  -	public static IServer[] getIServerJBossServers() {
  +	public static IServer[] getJBossServersAsIServers() {
   		ArrayList servers = new ArrayList();
   		IServer[] iservers = ServerCore.getServers();
   		for( int i = 0; i < iservers.length; i++ ) {
  -			if( getServer(iservers[i]) != null ) {
  +			if( getJBossServer(iservers[i]) != null ) {
   				servers.add(iservers[i]);
   			}
   		}
  @@ -97,9 +106,33 @@
   		return ret;
   	}
   	
  +	public static IDeployableServer[] getAllDeployableServers() {
  +		ArrayList servers = new ArrayList();
  +		IServer[] iservers = ServerCore.getServers();
  +		for( int i = 0; i < iservers.length; i++ ) {
  +			if( getDeployableServer(iservers[i]) != null ) {
  +				servers.add(getDeployableServer(iservers[i]));
  +			}
  +		}
  +		IDeployableServer[] ret = new IDeployableServer[servers.size()];
  +		servers.toArray(ret);
  +		return ret;
  +	}
  +	public static IServer[] getDeployableServersAsIServers() {
  +		ArrayList servers = new ArrayList();
  +		IServer[] iservers = ServerCore.getServers();
  +		for( int i = 0; i < iservers.length; i++ ) {
  +			if( getDeployableServer(iservers[i]) != null ) {
  +				servers.add(iservers[i]);
  +			}
  +		}
  +		IServer[] ret = new IServer[servers.size()];
  +		servers.toArray(ret);
  +		return ret;
  +	}
  +
  +	
   	public JBossServerCore() {
  -		ServerCore.addRuntimeLifecycleListener(this);
  -		ServerCore.addServerLifecycleListener(this);
   		ModuleModel.getDefault();
   		new PackagesBuildListener();
   	}
  @@ -138,27 +171,4 @@
   			}
   		}
   	}
  -	
  -	
  -	/*
  -	 * May implement these methods later on. For now, do nothing.
  -	 */
  -	public void serverAdded(IServer server) {
  -	}
  -
  -	public void serverChanged(IServer server) {
  -	}
  -
  -	public void serverRemoved(IServer server) {
  -	}
  -
  -
  -	public void runtimeAdded(IRuntime runtime) {
  -	}
  -
  -	public void runtimeChanged(IRuntime runtime) {
  -	}
  -
  -	public void runtimeRemoved(IRuntime runtime) {
  -	}
   }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:43 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:43 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/attributes
	...
Message-ID: <E1Gxtkp-0007Vo-DR@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:43

  Added:       as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/attributes 
                        IDeployableServer.java
  Log:
  New PackageTypes for marshall.
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 23:24:43;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/attributes/IDeployableServer.java
  
  Index: IDeployableServer.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.core.server.attributes;
  
  import org.eclipse.wst.server.core.IServer;
  import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public interface IDeployableServer {
  	public String getDeployDirectory();
  	public ServerAttributeHelper getAttributeHelper();
  	public IServer getServer();
  }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:24:39 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:24:39 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped
	- New directory ...
Message-ID: <E1Gxtkl-0007Tn-BB@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:24:39

  Log:
  Directory /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped added to the repository


From rawblem at gmail.com  Fri Dec 22 18:26:29 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:29 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events
	- New directory ...
Message-ID: <E1GxtmX-0007ZR-3H@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:29

  Log:
  Directory /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events added to the repository


From rawblem at gmail.com  Fri Dec 22 18:26:35 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:35 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events
	...
Message-ID: <E1Gxtmd-0007aB-Bv@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:35

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events    
                        PollingLabelProvider.java
                        ComplexEventLogLabelProvider.java
                        PublishLabelProvider.java
                        PackageBuildLabelProvider.java
  Log:
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 23:26:35;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/PollingLabelProvider.java
  
  Index: PollingLabelProvider.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.ui.views.server.providers.events;
  
  import java.util.ArrayList;
  import java.util.Date;
  import java.util.HashMap;
  import java.util.Iterator;
  import java.util.Properties;
  
  import org.eclipse.debug.core.ILaunchManager;
  import org.eclipse.jface.viewers.LabelProvider;
  import org.eclipse.swt.graphics.Image;
  import org.eclipse.ui.ISharedImages;
  import org.eclipse.ui.PlatformUI;
  import org.eclipse.wst.server.core.IServer;
  import org.eclipse.wst.server.ui.internal.provisional.UIDecoratorManager;
  import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  import org.jboss.ide.eclipse.as.core.runtime.server.IServerStatePoller;
  import org.jboss.ide.eclipse.as.core.runtime.server.polling.PollThread;
  import org.jboss.ide.eclipse.as.core.runtime.server.polling.TwiddlePoller;
  import org.jboss.ide.eclipse.as.core.runtime.server.polling.PollThread.PollThreadEvent;
  import org.jboss.ide.eclipse.as.core.server.JBossServerBehavior;
  import org.jboss.ide.eclipse.as.ui.views.server.extensions.IEventLogLabelProvider;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public class PollingLabelProvider extends ComplexEventLogLabelProvider implements IEventLogLabelProvider {
  
  	
  	protected void addSupportedTypes() {
  		supported = new ArrayList();
  		supported.add(PollThread.SERVER_STARTING);
  		supported.add(PollThread.SERVER_STOPPING);
  		supported.add(PollThread.FAILURE);
  		supported.add(PollThread.SUCCESS);
  		supported.add(PollThread.POLL_THREAD_ABORTED);
  		supported.add(PollThread.POLL_THREAD_TIMEOUT);
  		
  		supported.add(TwiddlePoller.TYPE_TERMINATED);
  		supported.add(TwiddlePoller.TYPE_RESULT);
  		
  		supported.add(JBossServerBehavior.FORCE_SHUTDOWN_EVENT_KEY);
  	}
  
  	public boolean supports(String type) {
  		return supported.contains(type);
  	}
  
  	public Image getImage(EventLogTreeItem element) {
  		if( element.getSpecificType().equals(PollThread.SERVER_STARTING)) return getStartingImage();
  		if( element.getSpecificType().equals(PollThread.SERVER_STOPPING)) return getStoppingImage();
  		
  		if( element instanceof PollThreadEvent ) {
  			boolean expected = ((PollThreadEvent)element).getExpectedState();
  			//String expectedString = expected == IServerStatePoller.SERVER_UP ? "startup" : "shutdown";
  			if( element.getSpecificType().equals(PollThread.POLL_THREAD_ABORTED)) return getErrorImage();
  			if( element.getSpecificType().equals(PollThread.POLL_THREAD_TIMEOUT)) return getErrorImage();
  			if( element.getSpecificType().equals(PollThread.SUCCESS)) {
  				if( expected == IServerStatePoller.SERVER_UP)
  					return getStartedImage();
  				return getStoppedImage();
  			}
  			if( element.getSpecificType().equals(PollThread.FAILURE)) 
  				return getErrorImage();
  		}
  		
  		if( element.getSpecificType().equals(TwiddlePoller.TYPE_TERMINATED)) return getErrorImage();
  		if( element.getSpecificType().equals(TwiddlePoller.TYPE_RESULT)) {
  			int state = ((Integer)element.getProperty(TwiddlePoller.STATUS)).intValue();
  			boolean expectedState = ((Boolean)element.getProperty(PollThread.EXPECTED_STATE)).booleanValue();
  			if( state == TwiddlePoller.STATE_STOPPED) 
  				return getStoppedImage();
  			if( state == TwiddlePoller.STATE_STARTED)
  				return getStartedImage();
  			if( state == TwiddlePoller.STATE_TRANSITION) {
  				if( expectedState == IServerStatePoller.SERVER_UP ) 
  					return getStartingImage();
  				return getStoppingImage();
  			}
  		}
  		
  		
  		if( element.getSpecificType().equals(JBossServerBehavior.FORCE_SHUTDOWN_EVENT_KEY)) 
  			return getErrorImage();
  		return null;
  	}
  
  	public String getText(EventLogTreeItem element) {
  		if( element.getSpecificType().equals(PollThread.SERVER_STARTING)) return "Starting the Server";
  		if( element.getSpecificType().equals(PollThread.SERVER_STOPPING)) return "Stopping the Server";
  		
  		if( element instanceof PollThreadEvent ) {
  			boolean expected = ((PollThreadEvent)element).getExpectedState();
  			String expectedString = expected == IServerStatePoller.SERVER_UP ? "startup" : "shutdown";
  			if( element.getSpecificType().equals(PollThread.POLL_THREAD_ABORTED)) return expectedString + " aborted";
  			if( element.getSpecificType().equals(PollThread.POLL_THREAD_TIMEOUT)) return expectedString + " timed out";
  			if( element.getSpecificType().equals(PollThread.SUCCESS)) return expectedString + " succeeded";
  			if( element.getSpecificType().equals(PollThread.FAILURE)) return expectedString + " failed";
  		}
  		
  		if( element.getSpecificType().equals(TwiddlePoller.TYPE_TERMINATED)) return "All processes have been terminated";
  		if( element.getSpecificType().equals(TwiddlePoller.TYPE_RESULT)) {
  			int state = ((Integer)element.getProperty(TwiddlePoller.STATUS)).intValue();
  			boolean expectedState = ((Boolean)element.getProperty(PollThread.EXPECTED_STATE)).booleanValue();
  			if( state == TwiddlePoller.STATE_STOPPED) 
  				return "The server is down.";
  			if( state == TwiddlePoller.STATE_STARTED)
  				return "The server is up.";
  			if( state == TwiddlePoller.STATE_TRANSITION) {
  				if( expectedState == IServerStatePoller.SERVER_UP ) 
  					return "The server is still starting";
  				return "The server is still stopping.";
  			}
  		}
  		
  		
  		if( element.getSpecificType().equals(JBossServerBehavior.FORCE_SHUTDOWN_EVENT_KEY)) 
  			return "The server was shutdown forcefully. All processes terminated.";
  		return null;
  	}
  	
  	protected Image getStateImage(int state) {
  		return UIDecoratorManager.getUIDecorator(null).getStateImage(state, ILaunchManager.RUN_MODE, 0);
  	}
  
  	protected Image getErrorImage() {
  		return PlatformUI.getWorkbench().getSharedImages().getImage(ISharedImages.IMG_OBJS_WARN_TSK);
  	}
  	public Image getStartedImage() {
  		return getStateImage(IServer.STATE_STARTED);
  	}
  	public Image getStartingImage() {
  		return getStateImage(IServer.STATE_STARTING);
  	}
  	public Image getStoppingImage() {
  		return getStateImage(IServer.STATE_STOPPING);
  	}
  	public Image getStoppedImage() {
  		return getStateImage(IServer.STATE_STOPPED);
  	}
  
  
  	
  	/*
  	 * Property Stuff
  	 */
  	protected void loadPropertyMap() {
  		// property names and their readable forms
  		propertyToMessageMap = new HashMap();
  		propertyToMessageMap.put(EventLogTreeItem.DATE, "Time");
  		propertyToMessageMap.put(TwiddlePoller.STATUS, "Status");
  		propertyToMessageMap.put(PollThread.EXPECTED_STATE, "Expected State");
  		
  		// now values and their readable forms
  		propertyToMessageMap.put(TwiddlePoller.STATUS + "::" + 0, "Server is Down");
  		propertyToMessageMap.put(TwiddlePoller.STATUS + "::" + 1, "Server is Up");
  		propertyToMessageMap.put(TwiddlePoller.STATUS + "::" + -1, "Server is in transition");
  		propertyToMessageMap.put(PollThread.EXPECTED_STATE + "::" + "true", "Up");
  		propertyToMessageMap.put(PollThread.EXPECTED_STATE + "::" + "false", "Down");
  	}
  }
  
  
  
  1.1      date: 2006/12/22 23:26:35;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/ComplexEventLogLabelProvider.java
  
  Index: ComplexEventLogLabelProvider.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.ui.views.server.providers.events;
  
  import java.util.ArrayList;
  import java.util.Date;
  import java.util.HashMap;
  import java.util.Iterator;
  import java.util.Properties;
  
  import org.eclipse.jface.viewers.LabelProvider;
  import org.eclipse.swt.graphics.Image;
  import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  import org.jboss.ide.eclipse.as.ui.views.server.extensions.IEventLogLabelProvider;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public abstract class ComplexEventLogLabelProvider 
  		extends LabelProvider implements IEventLogLabelProvider {
  
  	protected ArrayList supported;
  	protected HashMap propertyToMessageMap;
  	public ComplexEventLogLabelProvider() {
  		addSupportedTypes();
  		loadPropertyMap();
  	}
  	protected abstract void addSupportedTypes();
  	protected abstract void loadPropertyMap();
  
  	public Properties getProperties(EventLogTreeItem item) {
  		Properties p = new Properties();
  		HashMap map = item.getProperties();
  		Object key = null;
  		String keyString, valueStringKey, valueString;
  		for( Iterator i = map.keySet().iterator(); i.hasNext();) {
  			try {
  			key = i.next();
  			if( key.equals(EventLogTreeItem.DATE)) {
  				keyString = propertyToMessageMap.get(key) == null ? (String)key : propertyToMessageMap.get(key).toString();
  				valueString = getDateAsString(((Long)map.get(key)).longValue());
  				p.put(keyString, valueString);
  			} else {
  				keyString = propertyToMessageMap.get(key) == null ? (String)key : propertyToMessageMap.get(key).toString();
  				valueStringKey = key + "::" + toString2(map.get(key));
  				valueString = propertyToMessageMap.get(valueStringKey) == null ? toString2(map.get(key)) : toString2(propertyToMessageMap.get(valueStringKey));
  				p.put(keyString, valueString);
  			}
  			} catch( Exception e ) { e.printStackTrace(); }
  		}
  		return p;
  	}
  	
  	protected String getDateAsString(long date) {
  		long now = new Date().getTime();
  		long seconds = (now - date) / 1000;
  		long minutes = seconds / 60;
  		long hours = minutes / 60;
  		minutes -= (hours * 60);
  		String minString = minutes + "m ago";
  		if( hours == 0 )
  			return minString;
  		return hours + "h " + minString; 
  	}
  
  	private String toString2(Object o) {
  		return o == null ? "null" : o.toString();
  	}
  
  }
  
  
  
  1.1      date: 2006/12/22 23:26:35;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/PublishLabelProvider.java
  
  Index: PublishLabelProvider.java
  ===================================================================
  package org.jboss.ide.eclipse.as.ui.views.server.providers.events;
  
  import java.util.ArrayList;
  import java.util.HashMap;
  import java.util.Iterator;
  import java.util.Properties;
  
  import org.eclipse.jface.viewers.LabelProvider;
  import org.eclipse.swt.graphics.Image;
  import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  import org.jboss.ide.eclipse.as.core.publishers.IJBossServerPublisher;
  import org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher;
  import org.jboss.ide.eclipse.as.core.publishers.PackagesPublisher.PackagesPublisherBuildEvent;
  import org.jboss.ide.eclipse.as.ui.views.server.extensions.IEventLogLabelProvider;
  
  public class PublishLabelProvider extends ComplexEventLogLabelProvider implements
  		IEventLogLabelProvider {
  
  	protected void addSupportedTypes() {
  		supported = new ArrayList();
  		supported.add(PackagesPublisher.REMOVE_TOP_EVENT);
  		supported.add(PackagesPublisher.REMOVE_PACKAGE_SUCCESS);
  		supported.add(PackagesPublisher.REMOVE_PACKAGE_SKIPPED);
  		supported.add(PackagesPublisher.REMOVE_PACKAGE_FAIL);
  		
  		supported.add(PackagesPublisher.PUBLISH_TOP_EVENT);
  		supported.add(PackagesPublisher.PROJECT_BUILD_EVENT);
  		supported.add(PackagesPublisher.MOVE_PACKAGE_SUCCESS);
  		supported.add(PackagesPublisher.MOVE_PACKAGE_FAIL);
  		supported.add(PackagesPublisher.MOVE_PACKAGE_SKIP);
  	}
  	protected void loadPropertyMap() {
  		propertyToMessageMap = new HashMap();
  		propertyToMessageMap.put(IJBossServerPublisher.MODULE_NAME, "Module Name");
  		propertyToMessageMap.put(PackagesPublisher.PackagesPublisherRemoveEvent.PACKAGE_NAME, "Package Name");
  		propertyToMessageMap.put(PackagesPublisher.PackagesPublisherRemoveEvent.DESTINATION, "Package File");
  		propertyToMessageMap.put(PackagesPublisher.PackagesPublisherRemoveEvent.EXCEPTION_MESSAGE, "Exception Message");
  	}
  
  	public boolean supports(String type) {
  		return supported.contains(type);
  	}
  
  	public Image getImage(EventLogTreeItem item) {
  		return null;
  	}
  
  	public String getText(EventLogTreeItem item) {
  		String type = item.getSpecificType();
  		if( type.equals(PackagesPublisher.REMOVE_TOP_EVENT)) 
  			return "Removing Module: " + item.getProperty(IJBossServerPublisher.MODULE_NAME);
  		else if( type.equals(PackagesPublisher.REMOVE_PACKAGE_SUCCESS)) 
  			return "Deleted Package: " + item.getProperty(PackagesPublisher.PackagesPublisherRemoveEvent.PACKAGE_NAME);
  		else if( type.equals(PackagesPublisher.REMOVE_PACKAGE_FAIL)) 
  			return "Failed to Delete Package: " + item.getProperty(PackagesPublisher.PackagesPublisherRemoveEvent.PACKAGE_NAME);
  		else if( type.equals(PackagesPublisher.REMOVE_PACKAGE_SKIPPED)) 
  			return "Deletion Skipped: " + item.getProperty(PackagesPublisher.PackagesPublisherRemoveEvent.PACKAGE_NAME);
  		
  		
  		else if( type.equals(PackagesPublisher.PUBLISH_TOP_EVENT)) 
  			return "Publishing Module: " + item.getProperty(IJBossServerPublisher.MODULE_NAME);
  		else if( type.equals(PackagesPublisher.PROJECT_BUILD_EVENT)) 
  			return "Building Project: " + item.getProperty(PackagesPublisher.PackagesPublisherRemoveEvent.PACKAGE_NAME);
  		else if( type.equals(PackagesPublisher.MOVE_PACKAGE_SUCCESS))
  			return "Coppied File: " + item.getProperty(PackagesPublisher.PackagesPublisherMoveEvent.PACKAGE_NAME);
  		else if( type.equals(PackagesPublisher.MOVE_PACKAGE_FAIL))
  			return "File Copy Failed: " + item.getProperty(PackagesPublisher.PackagesPublisherMoveEvent.PACKAGE_NAME);
  		else if( type.equals(PackagesPublisher.MOVE_PACKAGE_SKIP))
  			return "File Copy Skipped: " + item.getProperty(PackagesPublisher.PackagesPublisherMoveEvent.PACKAGE_NAME);
  		
  		return item.toString();
  	}
  
  }
  
  
  
  1.1      date: 2006/12/22 23:26:35;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/PackageBuildLabelProvider.java
  
  Index: PackageBuildLabelProvider.java
  ===================================================================
  /**
   * JBoss, a Division of Red Hat
   * Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
   * by the @authors tag. See the copyright.txt 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.ide.eclipse.as.ui.views.server.providers.events;
  
  import java.util.ArrayList;
  import java.util.Properties;
  
  import org.eclipse.jface.viewers.LabelProvider;
  import org.eclipse.swt.graphics.Image;
  import org.jboss.ide.eclipse.as.core.model.PackagesBuildListener;
  import org.jboss.ide.eclipse.as.core.model.EventLogModel.EventLogTreeItem;
  import org.jboss.ide.eclipse.as.ui.views.server.extensions.IEventLogLabelProvider;
  
  /**
   *
   * @author rob.stryker at jboss.com
   */
  public class PackageBuildLabelProvider extends LabelProvider implements IEventLogLabelProvider {
  
  	public Image getImage(EventLogTreeItem item) {
  		return null;
  	}
  
  	public Properties getProperties(EventLogTreeItem item) {
  		return null;
  	}
  
  	public String getText(EventLogTreeItem item) {
  		if( item.getSpecificType().equals(PackagesBuildListener.PROJECT_BUILD_STARTED)) return "Build Started: " + item.getProperty("project.name");
  		if( item.getSpecificType().equals(PackagesBuildListener.PROJECT_BUILD_FINISHED)) return "Build Finished: " + item.getProperty("project.name");
  		if( item.getSpecificType().equals(PackagesBuildListener.PACKAGE_BUILD_STARTED)) return "Package Build Started: " + item.getProperty("package.name");
  		if( item.getSpecificType().equals(PackagesBuildListener.PACKAGE_BUILD_FINISHED)) return "Package Build Finished: " + item.getProperty("package.name");
  		if( item.getSpecificType().equals(PackagesBuildListener.PACKAGE_BUILD_FINISHED)) return "Package Build Failed: " + item.getProperty("package.name");
  		return "";
  	}
  
  	public boolean supports(String type) {
  		ArrayList list = new ArrayList();
  		list.add(PackagesBuildListener.PROJECT_BUILD_STARTED);
  		list.add(PackagesBuildListener.PROJECT_BUILD_FINISHED);
  		list.add(PackagesBuildListener.PACKAGE_BUILD_STARTED);
  		list.add(PackagesBuildListener.PACKAGE_BUILD_FINISHED);
  		list.add(PackagesBuildListener.PACKAGE_BUILD_FAILED);
  		
  		return list.contains(type);
  	}
  
  }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:26:35 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:35 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/wizards
	...
Message-ID: <E1Gxtmd-0007aI-Fh@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:35

  Added:       as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/wizards 
                        StrippedServerWizardFragment.java
  Log:
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.1      date: 2006/12/22 23:26:35;  author: rawb;  state: Exp;jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/wizards/StrippedServerWizardFragment.java
  
  Index: StrippedServerWizardFragment.java
  ===================================================================
  package org.jboss.ide.eclipse.as.ui.wizards;
  
  import java.io.File;
  
  import org.eclipse.core.resources.IFolder;
  import org.eclipse.core.runtime.CoreException;
  import org.eclipse.core.runtime.IProgressMonitor;
  import org.eclipse.core.runtime.IStatus;
  import org.eclipse.core.runtime.NullProgressMonitor;
  import org.eclipse.core.runtime.Status;
  import org.eclipse.swt.SWT;
  import org.eclipse.swt.events.ModifyEvent;
  import org.eclipse.swt.events.ModifyListener;
  import org.eclipse.swt.events.SelectionEvent;
  import org.eclipse.swt.events.SelectionListener;
  import org.eclipse.swt.layout.FormAttachment;
  import org.eclipse.swt.layout.FormData;
  import org.eclipse.swt.layout.FormLayout;
  import org.eclipse.swt.widgets.Button;
  import org.eclipse.swt.widgets.Composite;
  import org.eclipse.swt.widgets.DirectoryDialog;
  import org.eclipse.swt.widgets.Label;
  import org.eclipse.swt.widgets.Shell;
  import org.eclipse.swt.widgets.Text;
  import org.eclipse.wst.server.core.IServer;
  import org.eclipse.wst.server.core.IServerWorkingCopy;
  import org.eclipse.wst.server.core.ServerCore;
  import org.eclipse.wst.server.core.TaskModel;
  import org.eclipse.wst.server.core.internal.Server;
  import org.eclipse.wst.server.core.internal.ServerType;
  import org.eclipse.wst.server.core.internal.ServerWorkingCopy;
  import org.eclipse.wst.server.ui.wizard.IWizardHandle;
  import org.eclipse.wst.server.ui.wizard.WizardFragment;
  import org.jboss.ide.eclipse.as.core.server.stripped.DeployableServer;
  import org.jboss.ide.eclipse.as.ui.JBossServerUIPlugin;
  import org.jboss.ide.eclipse.as.ui.Messages;
  
  public class StrippedServerWizardFragment extends WizardFragment {
  
  	private IWizardHandle handle;
  	
  	private Label deployLabel, nameLabel;
  	private Text deployText, nameText;
  	private Button browse;
  	private String name, deployLoc;
  	public StrippedServerWizardFragment() {
  	}
  	
  	public Composite createComposite(Composite parent, IWizardHandle handle) {
  		this.handle = handle;
  		Composite main = new Composite(parent, SWT.NONE);
  		main.setLayout(new FormLayout());
  		
  
  		
  		
  		nameLabel = new Label(main, SWT.NONE);
  		nameText = new Text(main, SWT.BORDER);
  		nameLabel.setText("Deploy Folder");
  		
  		FormData namelData = new FormData();
  		namelData.top = new FormAttachment(0,5);
  		namelData.left = new FormAttachment(0,5);
  		nameLabel.setLayoutData(namelData);
  		
  		FormData nametData = new FormData();
  		nametData.top = new FormAttachment(0,5);
  		nametData.left = new FormAttachment(nameLabel,5);
  		nametData.right = new FormAttachment(100,0);
  		nameText.setLayoutData(nametData);
  
  		
  		
  		
  		
  		deployLabel = new Label(main, SWT.NONE);
  		deployText = new Text(main, SWT.BORDER);
  		Button browse = new Button(main, SWT.PUSH);
  		deployLabel.setText("Deploy Folder");
  		browse.setText(Messages.browse);
  		
  		FormData lData = new FormData();
  		lData.top = new FormAttachment(nameText,5);
  		lData.left = new FormAttachment(0,5);
  		deployLabel.setLayoutData(lData);
  		
  		FormData tData = new FormData();
  		tData.top = new FormAttachment(nameText,5);
  		tData.left = new FormAttachment(deployLabel,5);
  		tData.right = new FormAttachment(browse, -5);
  		deployText.setLayoutData(tData);
  		
  		FormData bData = new FormData();
  		bData.right = new FormAttachment(100,-5);
  		bData.top = new FormAttachment(nameText,5);
  		browse.setLayoutData(bData);
  		
  		ModifyListener ml = new ModifyListener() {
  			public void modifyText(ModifyEvent e) {
  				textChanged();
  			}
  		};
  		
  		browse.addSelectionListener(new SelectionListener() {
  			public void widgetDefaultSelected(SelectionEvent e) {
  			}
  			public void widgetSelected(SelectionEvent e) {
  				DirectoryDialog d = new DirectoryDialog(new Shell());
  				d.setFilterPath(deployText.getText());
  				String x = d.open();
  				if( x != null ) 
  					deployText.setText(x);
  			} 
  		});
  
  		
  		deployText.addModifyListener(ml);
  		nameText.addModifyListener(ml);
  		
  		nameText.setText(getDefaultNameText());
  
  			
  		return main;
  	}
  
  	protected void textChanged() {
  		IStatus status = checkErrors();
  		if( status.isOK() ) {
  			deployLoc = deployText.getText();
  			name = nameText.getText();
  			handle.setMessage("", IStatus.OK);
  			handle.update();
  		} else {
  			handle.setMessage(status.getMessage(), IStatus.WARNING);
  		}
  	}
  	
  	protected IStatus checkErrors() {
  		if( findServer(nameText.getText()) != null ) {
  			return new Status(IStatus.WARNING, JBossServerUIPlugin.PLUGIN_ID, IStatus.OK, "Name in use", null);
  		}
  		File f = new File(deployText.getText());
  		if( !f.exists() || !f.isDirectory() ) {
  			return new Status(IStatus.WARNING, JBossServerUIPlugin.PLUGIN_ID, IStatus.OK, "Folder does not exist", null);
  		}
  		return new Status(IStatus.OK, JBossServerUIPlugin.PLUGIN_ID, IStatus.OK, "", null);
  	}
  	
  	public void enter() {
  		handle.setTitle("Create a new System Copy Server");
  		IServer s = (IServer) getTaskModel().getObject(TaskModel.TASK_SERVER);
  		IServerWorkingCopy swc;
  		if( s instanceof IServerWorkingCopy)
  			swc = (IServerWorkingCopy)s;
  		else
  			swc = s.createWorkingCopy();
  		
  		ServerWorkingCopy swcInternal;
  		if( swc instanceof ServerWorkingCopy )  {
  			swcInternal = (ServerWorkingCopy)swc;
  			deployText.setText(swcInternal.getAttribute(DeployableServer.DEPLOY_DIRECTORY, ""));
  		}
  	}
  	public void exit() {
  		textChanged();
  	}
  	
  	public void performFinish(IProgressMonitor monitor) throws CoreException {
  		IServerWorkingCopy serverWC = (IServerWorkingCopy) getTaskModel().getObject(TaskModel.TASK_SERVER);
  		ServerWorkingCopy serverwc2 = (serverWC instanceof ServerWorkingCopy ? ((ServerWorkingCopy)serverWC) : null);
  		
  		IFolder folder = getJbossServerFolder(name);
  		if( !folder.exists()) {
  			folder.create(true,true, new NullProgressMonitor());
  		}
  		try {
  			serverwc2.setServerConfiguration(folder);
  			serverwc2.setName(name);
  			serverwc2.setAttribute(DeployableServer.DEPLOY_DIRECTORY, deployLoc);
  			IServer saved = serverwc2.save(true, monitor);
  			getTaskModel().putObject(TaskModel.TASK_SERVER, saved);
  		} catch( Exception ce ) {
  		}
  		
  	}
  	private IFolder getJbossServerFolder(String serverName) {
  		try {
  			return ServerType.getServerProject().getFolder(serverName);
  		} catch( Exception e) {
  			return null;
  		}
  	}
  
  	public boolean isComplete() {
  		return checkErrors().isOK();
  	}
  
  	public boolean hasComposite() {
  		return true;
  	}
  
  	
  	
  	
  	
  	private String getDefaultNameText() {
  		String base = "JBoss deployer";
  		if( findServer(base) == null ) return base;
  		int i = 1;
  		while( ServerCore.findServer(base + " " + i) != null ) 
  			i++;
  		return base + " " + i;
  	}
  	private IServer findServer(String name) {
  		IServer[] servers = ServerCore.getServers();
  		for( int i = 0; i < servers.length; i++ ) {
  			Server server = (Server) servers[i];
  			if (name.equals(server.getName()))
  				return server;
  		}
  		return null;
  	}
  
  	
  }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:26:35 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:35 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server
	...
Message-ID: <E1Gxtmd-0007aV-Jn@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:35

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server   
                        ServerTableViewer.java JBossServerTableViewer.java
                        JBossServerView.java
  Log:
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.6       +3 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ServerTableViewer.java	14 Dec 2006 19:34:44 -0000	1.5
  +++ ServerTableViewer.java	22 Dec 2006 23:26:35 -0000	1.6
  @@ -69,9 +69,11 @@
   	protected class ServerTableLabelProvider2 extends ServerTableLabelProvider {
   		private int myCount = 0;
   		protected Image getStateImage(IServerType serverType, int state, String mode) {
  +			if( serverType.getId().equals("org.jboss.ide.eclipse.as.systemCopyServer")) return null;
   			return UIDecoratorManager.getUIDecorator(serverType).getStateImage(state, mode, myCount);
   		}
   		protected String getStateLabel(IServerType serverType, int state, String mode) {
  +			if( serverType.getId().equals("org.jboss.ide.eclipse.as.systemCopyServer")) return "N/A";
   			return UIDecoratorManager.getUIDecorator(serverType).getStateLabel(state, mode, myCount);
   		}
   		protected void animate() {
  @@ -84,7 +86,7 @@
   	
   	public class TrimmedServerContentProvider implements IStructuredContentProvider, ITreeContentProvider {
   		public Object[] getElements(Object element) {
  -			return JBossServerCore.getIServerJBossServers();
  +			return JBossServerCore.getDeployableServersAsIServers();
   		}
   
   		public void inputChanged(Viewer theViewer, Object oldInput, Object newInput) {
  
  
  
  1.5       +13 -3     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerTableViewer.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- JBossServerTableViewer.java	14 Dec 2006 19:34:44 -0000	1.4
  +++ JBossServerTableViewer.java	22 Dec 2006 23:26:35 -0000	1.5
  @@ -45,7 +45,7 @@
   public class JBossServerTableViewer extends TreeViewer {
   
   	protected TableViewerPropertySheet propertySheet;
  -	protected Action disableCategoryAction, refreshAction;
  +	protected Action disableCategoryAction, refreshAction, refreshFullAction;
   	protected boolean suppressingRefresh = false;
   	public JBossServerTableViewer(Tree tree) {
   		super(tree);
  @@ -100,6 +100,13 @@
   			}
   		};
   		refreshAction.setText("Refresh Item");
  +		
  +		refreshFullAction = new Action() {
  +			public void run() {
  +				refresh(null);
  +			}
  +		};
  +		refreshFullAction.setText("Refresh Full Tree");
   	}
   	
   	public static class ContentWrapper {
  @@ -279,6 +286,7 @@
   	protected void fillJBContextMenu(Shell shell, IMenuManager menu) {
   		Object selected = getSelectedElement();
   		menu.add(refreshAction);
  +		menu.add(refreshFullAction);
   		if( selected instanceof ServerViewProvider ) {
   			menu.add(disableCategoryAction);
   		}
  @@ -413,8 +421,10 @@
   
   	// for testing
   	public void refresh(final Object element) {
  -		System.out.println("here: " + element);
  +		if(!suppressingRefresh) {
   		super.refresh(element);
  +		} else {
  +		}
   	}
   	
   
  
  
  
  1.6       +2 -18     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBossServerView.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerView.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- JBossServerView.java	14 Dec 2006 19:34:44 -0000	1.5
  +++ JBossServerView.java	22 Dec 2006 23:26:35 -0000	1.6
  @@ -54,11 +54,7 @@
   	protected Tree jbTreeTable;
   	
   	
  -	protected Action  refreshViewerAction, editLaunchConfigAction, twiddleAction, cloneServerAction;
  -
  -	
  -	private boolean suppressingRefresh = false;
  -	
  +	protected Action editLaunchConfigAction, twiddleAction, cloneServerAction;
   	
   	public static JBossServerView instance;
   	public static JBossServerView getDefault() {
  @@ -104,19 +100,6 @@
   	
   	
   	public void createActions() {
  -		refreshViewerAction = new Action() {
  -			public void run() {
  -				Display.getDefault().asyncExec(new Runnable() {
  -					public void run() {
  -						getJBViewer().refresh(null);
  -					} 
  -				});
  -			}
  -			
  -		};
  -		refreshViewerAction.setText(Messages.RefreshViewerAction);
  -		
  -		
   		editLaunchConfigAction = new Action() {
   			public void run() {
   				Display.getDefault().asyncExec(new Runnable() { 
  @@ -264,6 +247,7 @@
   				if( server != jbViewer.getInput()) {
   					jbViewer.setInput(server); 
   				} else {
  +					jbViewer.refresh();
   //					Object[] expanded = jbViewer.getExpandedElements();
   //					jbViewer.setInput(server);
   //					jbViewer.setExpandedElements(expanded);
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:26:35 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:35 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers
	...
Message-ID: <E1Gxtmd-0007al-OO@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:35

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers      
                        DescriptorXPathViewProvider.java
                        FilesetViewProvider.java ModuleViewProvider.java
                        EventLogViewProvider.java
  Removed:     as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers      
                        PackageBuildLabelProvider.java
                        PollingLabelProvider.java
  Log:
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.6       +7 -4      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DescriptorXPathViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- DescriptorXPathViewProvider.java	14 Dec 2006 19:34:44 -0000	1.5
  +++ DescriptorXPathViewProvider.java	22 Dec 2006 23:26:35 -0000	1.6
  @@ -150,8 +150,11 @@
   	protected class XPathTreeContentProvider implements ITreeContentProvider {
   		
   		public Object[] getChildren(Object parentElement) {
  -			if( parentElement instanceof ServerViewProvider ) 
  -				return getRoot().getChildren();
  +			if( parentElement instanceof ServerViewProvider ) {
  +				SimpleXPathPreferenceTreeItem root = getRoot();
  +				if( root == null ) return new Object[]{};
  +				return root.getChildren();
  +			}
   			return new Object[0];
   		}
   		public Object getParent(Object element) {
  @@ -168,7 +171,7 @@
   		public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
   			if( oldInput != newInput ) {
   				server = (IServer)newInput;
  -				jbServer = server == null ? null : JBossServerCore.getServer(server);
  +				jbServer = server == null ? null : JBossServerCore.getJBossServer(server);
   				root = null;
   			}
   		}
  @@ -195,7 +198,7 @@
   	}
   	
   	public SimpleXPathPreferenceTreeItem getRoot() {
  -		if( root == null ) {
  +		if( root == null && jbServer != null) {
   			root = jbServer.getAttributeHelper().getXPathPreferenceTree();
   		}
   		return root;
  
  
  
  1.3       +20 -8     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FilesetViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- FilesetViewProvider.java	14 Dec 2006 19:34:44 -0000	1.2
  +++ FilesetViewProvider.java	22 Dec 2006 23:26:35 -0000	1.3
  @@ -29,6 +29,7 @@
   import org.eclipse.swt.events.SelectionEvent;
   import org.eclipse.swt.events.SelectionListener;
   import org.eclipse.swt.graphics.Image;
  +import org.eclipse.swt.graphics.Point;
   import org.eclipse.swt.layout.GridData;
   import org.eclipse.swt.layout.GridLayout;
   import org.eclipse.swt.widgets.Button;
  @@ -48,9 +49,8 @@
   import org.eclipse.ui.internal.editors.text.JavaFileEditorInput;
   import org.eclipse.ui.internal.util.SWTResourceUtil;
   import org.eclipse.wst.server.core.IServer;
  -import org.jboss.ide.eclipse.as.core.server.JBossServer;
   import org.jboss.ide.eclipse.as.core.server.ServerAttributeHelper;
  -import org.jboss.ide.eclipse.as.ui.views.server.JBossServerView;
  +import org.jboss.ide.eclipse.as.core.server.attributes.IDeployableServer;
   import org.jboss.ide.eclipse.as.ui.views.server.extensions.ServerViewProvider;
   import org.jboss.ide.eclipse.as.ui.views.server.extensions.SimplePropertiesViewExtension;
   import org.jboss.ide.eclipse.packages.core.model.PackagesCore;
  @@ -75,7 +75,7 @@
   	protected void createActions() {
   		createFilter =  new Action() { 
   			public void run() {
  -				JBossServer server = (JBossServer)contentProvider.server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  +				IDeployableServer server = (IDeployableServer)contentProvider.server.loadAdapter(IDeployableServer.class, new NullProgressMonitor());
   				FilesetDialog d = new FilesetDialog(new Shell(), server);
   				if( d.open() == Window.OK ) {
   					Fileset fs = d.getFileset();
  @@ -224,7 +224,7 @@
   	public void loadFilesets() {
   		IServer server = contentProvider.server;
   		if( server != null ) {
  -			JBossServer jbs = (JBossServer)server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  +			IDeployableServer jbs = (IDeployableServer)server.loadAdapter(IDeployableServer.class, new NullProgressMonitor());
   			ServerAttributeHelper helper = jbs.getAttributeHelper();
   			List tmp = helper.getAttribute(FILESET_KEY, new ArrayList());
   			String[] asStrings = (String[]) tmp.toArray(new String[tmp.size()]);
  @@ -244,7 +244,7 @@
   					for( int i = 0; i < filesets.length; i++ ) {
   						list.add(filesets[i].toString());
   					}
  -					JBossServer jbs = (JBossServer)server.loadAdapter(JBossServer.class, new NullProgressMonitor());
  +					IDeployableServer jbs = (IDeployableServer)server.loadAdapter(IDeployableServer.class, new NullProgressMonitor());
   					ServerAttributeHelper helper = jbs.getAttributeHelper();
   					helper.setAttribute(FILESET_KEY, list);
   					helper.save();
  @@ -427,7 +427,8 @@
   		private String name, dir, includes, excludes;
   		private Button browse;
   		private Text includesText, excludesText, folderText, nameText;
  -		protected FilesetDialog(Shell parentShell, JBossServer server) {
  +		private Composite main;
  +		protected FilesetDialog(Shell parentShell, IDeployableServer server) {
   			super(parentShell);
   			this.fileset = new Fileset();
   			this.fileset.setFolder(server.getDeployDirectory());
  @@ -436,11 +437,17 @@
   			super(parentShell);
   			this.fileset = (Fileset)fileset.clone();
   		}
  +		protected Point getInitialSize() {
  +			//return new Point(400, 150);
  +			Point p = super.getInitialSize();
  +			return new Point(500, p.y);
  +		}
  +
   		protected Control createDialogArea(Composite parent) {
   			Composite sup = (Composite) super.createDialogArea(parent);
  -			Composite main = new Composite(sup, SWT.NONE);
  +			main = new Composite(sup, SWT.NONE);
   			main.setLayout(new GridLayout(3, false));
  -			
  +			main.setLayoutData(new GridData(GridData.FILL_BOTH));
   			fillArea(main);
   			
   			nameText.setText(fileset.getName());
  @@ -476,6 +483,10 @@
   			});
   		}
   		
  +		protected void layout() {
  +			int o, t;
  +		}
  +
   		protected void textModified() {
   			name = nameText.getText();
   			dir = folderText.getText();
  @@ -497,6 +508,7 @@
   			folderLabel.setText("Root Directory: ");
   			
   			folderText = new Text(main, SWT.BORDER);
  +			folderText.setLayoutData(new GridData(SWT.FILL, SWT.CENTER, true, true, 1, 1));
   			browse = new Button(main, SWT.PUSH);
   			browse.setText("Browse...");
   			
  
  
  
  1.3       +2 -2      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/ModuleViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ModuleViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/ModuleViewProvider.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ModuleViewProvider.java	28 Nov 2006 17:34:30 -0000	1.2
  +++ ModuleViewProvider.java	22 Dec 2006 23:26:35 -0000	1.3
  @@ -226,13 +226,13 @@
   	private void addListeners() {
   		serverResourceListener = new IServerLifecycleListener() {
   			public void serverAdded(IServer server) {
  -				if( JBossServerCore.getServer(server) != null ) 
  +				if( JBossServerCore.getJBossServer(server) != null ) 
   					server.addServerListener(serverListener);
   			}
   			public void serverChanged(IServer server) {
   			}
   			public void serverRemoved(IServer server) {
  -				if( JBossServerCore.getServer(server) != null ) 
  +				if( JBossServerCore.getJBossServer(server) != null ) 
   					server.removeServerListener(serverListener);
   			}
   		};
  
  
  
  1.6       +3 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EventLogViewProvider.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- EventLogViewProvider.java	11 Dec 2006 15:53:03 -0000	1.5
  +++ EventLogViewProvider.java	22 Dec 2006 23:26:35 -0000	1.6
  @@ -244,7 +244,9 @@
   			for( int i = 0; i < elements.length; i++ ) {
   				try {
   					labelProviderDelegates[i] = (IEventLogLabelProvider)elements[i].createExecutableExtension("class");
  -				} catch( CoreException ce ) {}
  +				} catch( CoreException ce ) {
  +					ce.printStackTrace();
  +				}
   			}
   	    }
   	}
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:26:35 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:35 -0500
Subject: [jboss-cvs]
	jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs
	...
Message-ID: <E1Gxtmd-0007as-Ru@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:35

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs 
                        XPathDialogs.java
  Log:
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.10      +1 -1      jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: XPathDialogs.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- XPathDialogs.java	4 Dec 2006 17:45:30 -0000	1.9
  +++ XPathDialogs.java	22 Dec 2006 23:26:35 -0000	1.10
  @@ -245,7 +245,7 @@
   		
   		protected void fillCombos() {
   			if( serverCombo != null ) {
  -				IServer servers[] = JBossServerCore.getIServerJBossServers();
  +				IServer servers[] = JBossServerCore.getJBossServersAsIServers();
   				String[] names = new String[servers.length];
   				for( int i = 0; i < servers.length; i++ ) {
   					names[i] = servers[i].getName();
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:26:36 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:26:36 -0500
Subject: [jboss-cvs] jbosside/as/plugins/org.jboss.ide.eclipse.as.ui  ...
Message-ID: <E1Gxtme-0007az-0P@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:26:36

  Modified:    as/plugins/org.jboss.ide.eclipse.as.ui  plugin.xml
  Log:
  Added deploy-only server (cannot start or stop)
  Other associated changes. 
  
  Revision  Changes    Path
  1.29      +16 -9     jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: plugin.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- plugin.xml	13 Dec 2006 18:34:37 -0000	1.28
  +++ plugin.xml	22 Dec 2006 23:26:35 -0000	1.29
  @@ -10,24 +10,23 @@
         <image
               icon="icons/jboss.gif"
               typeIds="org.jboss.ide.eclipse.as.32"
  -            id="org.jboss.ide.eclipse.as.ui.jboss32Image"/>
  +            id="org.jboss.ide.eclipse.as.ui.jbossIcon"/>
         <image
               icon="icons/jboss.gif"
               typeIds="org.jboss.ide.eclipse.as.40"
  -            id="org.jboss.ide.eclipse.as.ui.jboss40Image"/>
  +            id="org.jboss.ide.eclipse.as.ui.jbossIcon"/>
         <image
               icon="icons/jboss.gif"
               typeIds="org.jboss.ide.eclipse.as.runtime.32"
  -            id="org.jboss.ide.eclipse.as.ui.jboss32Image"/>
  +            id="org.jboss.ide.eclipse.as.ui.jbossIcon"/>
         <image
               icon="icons/jboss.gif"
               typeIds="org.jboss.ide.eclipse.as.runtime.40"
  -            id="org.jboss.ide.eclipse.as.ui.jboss40Image"/>
  +            id="org.jboss.ide.eclipse.as.ui.jbossIcon"/>
         <image
               icon="icons/jboss.gif"
  -            id="org.jboss.ide.eclipse.as.ui.jbossProjectRuntimeImage"
  -            typeIds="org.jboss.ide.eclipse.as.runtime.dynwebproject"/>
  -
  +            typeIds="org.jboss.ide.eclipse.as.systemCopyServer"
  +            id="org.jboss.ide.eclipse.as.ui.jbossIcon"/>
      </extension>
   
      <extension
  @@ -48,6 +47,10 @@
               class="org.jboss.ide.eclipse.as.ui.wizards.AbstractJBossServerWizardFragment"
               id="org.jboss.ide.eclipse.as.ui.jboss40ServerWizardFragment"
               typeIds="org.jboss.ide.eclipse.as.40"/>
  +       <fragment
  +             class="org.jboss.ide.eclipse.as.ui.wizards.StrippedServerWizardFragment"
  +             id="org.jboss.ide.eclipse.as.ui.strippedServerWizardFragment"
  +             typeIds="org.jboss.ide.eclipse.as.systemCopyServer"/>
      </extension>
   
      <extension
  @@ -206,8 +209,9 @@
         </extension>
         <extension
               point="org.jboss.ide.eclipse.as.ui.EventLogLabelProvider">
  -         <labelProvider class="org.jboss.ide.eclipse.as.ui.views.server.providers.PollingLabelProvider"/>
  -         <labelProvider class="org.jboss.ide.eclipse.as.ui.views.server.providers.PackageBuildLabelProvider"/>
  +         <labelProvider class="org.jboss.ide.eclipse.as.ui.views.server.providers.events.PollingLabelProvider"/>
  +         <labelProvider class="org.jboss.ide.eclipse.as.ui.views.server.providers.events.PackageBuildLabelProvider"/>
  +         <labelProvider class="org.jboss.ide.eclipse.as.ui.views.server.providers.events.PublishLabelProvider"/>
         </extension>
         <extension
               point="org.jboss.ide.eclipse.as.ui.EventLogMajorType">
  @@ -217,6 +221,9 @@
            <MajorType
                  name="Startup / Shutdown Events"
                  typeId="org.jboss.ide.eclipse.as.core.runtime.server.polling.MajorType"/>
  +         <MajorType
  +               name="Publish Events"
  +               typeId="org.jboss.ide.eclipse.as.core.publishers.MajorType"/>
         </extension>
         <extension
               point="org.jboss.ide.eclipse.as.ui.mbeans.ServiceXMLQuickFixProvider">
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:41:40 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:41:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types
	...
Message-ID: <E1Gxu1E-0007oX-JV@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:41:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types  
                        JARPackageType.java AbstractPackageType.java
  Log:
  CHanges to extension and how it is loaded
  
  Revision  Changes    Path
  1.9       +2 -0      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JARPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- JARPackageType.java	22 Dec 2006 19:09:31 -0000	1.8
  +++ JARPackageType.java	22 Dec 2006 23:41:40 -0000	1.9
  @@ -4,6 +4,8 @@
   import org.eclipse.core.resources.IProject;
   import org.eclipse.core.runtime.Assert;
   import org.eclipse.core.runtime.CoreException;
  +import org.eclipse.core.runtime.IConfigurationElement;
  +import org.eclipse.core.runtime.IExecutableExtension;
   import org.eclipse.core.runtime.IPath;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.eclipse.core.runtime.NullProgressMonitor;
  
  
  
  1.4       +17 -12    jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/AbstractPackageType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractPackageType.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/AbstractPackageType.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- AbstractPackageType.java	22 Dec 2006 19:09:31 -0000	1.3
  +++ AbstractPackageType.java	22 Dec 2006 23:41:40 -0000	1.4
  @@ -22,7 +22,9 @@
   package org.jboss.ide.eclipse.packages.core.model.types;
   
   import org.eclipse.core.resources.IProject;
  +import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IConfigurationElement;
  +import org.eclipse.core.runtime.IExecutableExtension;
   import org.eclipse.core.runtime.IProgressMonitor;
   import org.jboss.ide.eclipse.packages.core.model.IPackage;
   
  @@ -30,18 +32,21 @@
    *
    * @author rob.stryker at jboss.com
    */
  -public abstract class AbstractPackageType implements IPackageType {
  -	private String id;
  -	private String label;
  +public abstract class AbstractPackageType implements IPackageType, IExecutableExtension {
   	
  -	public void setInitializationData(IConfigurationElement el) {
  -		id = el.getAttribute("id");
  -		label = el.getAttribute("label");
  +	private IConfigurationElement element;
  +	public void setInitializationData(IConfigurationElement config, String propertyName, Object data) throws CoreException {
  +		if( element == null ) element = config;
  +	}
  +	public String getId() {
  +		return element.getAttribute("id");
   	}
   	
  -	public String getId() { return id; }
  -	public String getLabel() { return label; }
  +	public String getLabel() {
  +		return element.getAttribute("label");
  +	}
   	
  -	public abstract int getSupportFor (IProject project);
  +	public abstract int getSupportFor(IProject project);
   	public abstract IPackage createDefaultConfiguration(IProject project, IProgressMonitor monitor);
  +
   }
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:41:40 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:41:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/schema ...
Message-ID: <E1Gxu1E-0007oe-Mp@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:41:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/schema 
                        packageTypes.exsd
  Log:
  CHanges to extension and how it is loaded
  
  Revision  Changes    Path
  1.3       +1 -1      jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/schema/packageTypes.exsd
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: packageTypes.exsd
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/schema/packageTypes.exsd,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- packageTypes.exsd	20 Nov 2006 21:06:48 -0000	1.2
  +++ packageTypes.exsd	22 Dec 2006 23:41:40 -0000	1.3
  @@ -64,7 +64,7 @@
                     
                  </documentation>
                  <appInfo>
  -                  <meta.attribute kind="java" basedOn="org.jboss.ide.eclipse.packages.core.model.types.AbstractPackageType"/>
  +                  <meta.attribute kind="java" basedOn="org.jboss.ide.eclipse.packages.core.model.types.IPackageType"/>
                  </appInfo>
               </annotation>
            </attribute>
  
  
  


From rawblem at gmail.com  Fri Dec 22 18:41:40 2006
From: rawblem at gmail.com (Robert Stryker)
Date: Fri, 22 Dec 2006 18:41:40 -0500
Subject: [jboss-cvs]
	jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core
	...
Message-ID: <E1Gxu1E-0007ol-R0@committer01.frg.pub.inap.atl.jboss.com>

  User: rawb    
  Date: 06/12/22 18:41:40

  Modified:    core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core 
                        ExtensionManager.java
  Log:
  CHanges to extension and how it is loaded
  
  Revision  Changes    Path
  1.5       +1 -12     jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExtensionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jbosside/core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ExtensionManager.java	22 Dec 2006 19:09:31 -0000	1.4
  +++ ExtensionManager.java	22 Dec 2006 23:41:40 -0000	1.5
  @@ -4,12 +4,12 @@
   
   import org.eclipse.core.runtime.CoreException;
   import org.eclipse.core.runtime.IConfigurationElement;
  +import org.eclipse.core.runtime.IExecutableExtension;
   import org.eclipse.core.runtime.IExtension;
   import org.eclipse.core.runtime.IExtensionPoint;
   import org.eclipse.core.runtime.IExtensionRegistry;
   import org.eclipse.core.runtime.InvalidRegistryObjectException;
   import org.eclipse.core.runtime.Platform;
  -import org.jboss.ide.eclipse.packages.core.model.types.AbstractPackageType;
   import org.jboss.ide.eclipse.packages.core.model.types.IPackageType;
   
   public class ExtensionManager {
  @@ -34,22 +34,11 @@
   			{
   				try {
   					Object executable = elements[j].createExecutableExtension("class");
  -					if( !(executable instanceof AbstractPackageType)) 
  -						throw new Exception("Provided class (" + elements[j].getAttribute("class")+ ") is not an IPackageType");
  -					((AbstractPackageType)executable).setInitializationData(elements[j]);
   					packageTypes.add((IPackageType)executable);
   				} catch (InvalidRegistryObjectException e) {
   					Trace.trace(ExtensionManager.class, e);
  -				} catch (ClassNotFoundException e) {
  -					Trace.trace(ExtensionManager.class, e);
  -				} catch (InstantiationException e) {
  -					Trace.trace(ExtensionManager.class, e);
  -				} catch (IllegalAccessException e) {
  -					Trace.trace(ExtensionManager.class, e);
   				} catch( CoreException e ) {
   					Trace.trace(ExtensionManager.class, e);
  -				} catch( Exception e ) {
  -					Trace.trace(ExtensionManager.class, e);
   				}
   			}
   		}
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 22 18:45:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 22 Dec 2006 18:45:15 -0500
Subject: [jboss-cvs] JBossAS SVN: r59215 -
	branches/Branch_4_2/tools/etc/buildmagic
Message-ID: <E1Gxu4h-0007qD-OA@committer01.frg.pub.inap.atl.jboss.com>

Author: dimitris at jboss.org
Date: 2006-12-22 18:45:12 -0500 (Fri, 22 Dec 2006)
New Revision: 59215

Modified:
   branches/Branch_4_2/tools/etc/buildmagic/aliases.ent
Log:
JBAS-3955, commons-codec must appear on the testsuite classpath, too.

Modified: branches/Branch_4_2/tools/etc/buildmagic/aliases.ent
===================================================================
--- branches/Branch_4_2/tools/etc/buildmagic/aliases.ent	2006-12-22 17:57:30 UTC (rev 59214)
+++ branches/Branch_4_2/tools/etc/buildmagic/aliases.ent	2006-12-22 23:45:12 UTC (rev 59215)
@@ -5,6 +5,7 @@
   <pathelement path="${apache.collections.lib}/commons-collections.jar"/>
   <pathelement path="${apache.logging.lib}/commons-logging.jar"/>
   <pathelement path="${apache.httpclient.lib}/commons-httpclient.jar"/>
+  <pathelement path="${apache.codec.lib}/commons-codec.jar"/>
   <pathelement path="${apache.pool.lib}/commons-pool.jar"/>
   <pathelement path="${apache.discovery.lib}/commons-discovery.jar"/>
   <pathelement path="${apache.fileupload.lib}/commons-fileupload.jar"/>



From veer778ddd at lycos.com  Fri Dec 22 18:56:55 2006
From: veer778ddd at lycos.com (veer778ddd at lycos.com)
Date: Fri, 22 Dec 2006 18:56:55 -0500
Subject: [jboss-cvs] =?utf-8?b?wpPDusKBWMKNWMKQVsKCwrXCgsOEwoLCosKCw5w=?=
	=?utf-8?b?woLCt8KCw4zCgsOFwoLCqMKRwoHCgsOfwoLDicKCwrLCim3ClEbCgsKt?=
	=?utf-8?b?woLCvsKCwrPCgsKiwoFC?=
Message-ID: 20061223084329.73790mail@mail.disushsafjashsjasdhkajdhjdnasjdna.com


http://completeallfree.nearwoman.perpl.com/near/

?E???????@?l?@34???@?Z?????]?@??????????????70??
?E???????@?l?@40???@???????]?@???????z60???`???????? 
?E?????@?l?@29???@???????]?@???????]?z?????k

http://completeallfree.nearwoman.perpl.com/near/

?????t???????z?????z???T?O???~?I
???????????????????????????????V?????G?b?`?????????I

???S???????R?R?????I

http://completeallfree.nearwoman.perpl.com/near/

?????X?X?V?????????????????????????????A?????????v??????
http://completeallfree.nearwoman.perpl.com/near/





From gfds874sdgf at fastermail.com  Fri Dec 22 22:33:16 2006
From: gfds874sdgf at fastermail.com (gfds874sdgf at fastermail.com)
Date: Fri, 22 Dec 2006 22:33:16 -0500
Subject: [jboss-cvs] =?utf-8?b?woN1woPCjcKDT8KCw4nCjcOawoLCucKCwr3CjsOK?=
	=?utf-8?b?wpBewoLDjcKWwr7Ck8O6wo3DrcKPwpzCgsK1woLDpsKCwqTCgsOGwo52?=
	=?utf-8?b?woLDgcKCw4TCgsKiwoLDnMKCwrfCgUI=?=
Message-ID: 20061223123249.41824mail@mail.awuidaujdjfndjfuasdjfsabvudn_web.com

?{?????M?????????????????????????A?????????u???O???????F?????l??????????????????
???????????R?????g???????????????????A???^???????????v???????B
?????????????????????H?????????????????v?????????????A??????????????????
???????????????????????B?{???A?M?????????????????????????c?B
http://www.allcompletefree.com.tonderuyo.com/tom/
?}?C?u???O???}?C?t?H?g???????????????????B
?R?????g?????????????B





From dfsauierw9745sa at kittymail.com  Fri Dec 22 23:08:06 2006
From: dfsauierw9745sa at kittymail.com (dfsauierw9745sa at kittymail.com)
Date: Fri, 22 Dec 2006 23:08:06 -0500
Subject: [jboss-cvs] =?utf-8?b?wo7DisKQXsKCw7DClcOPwoLCpsKCwr3CgsOxwoI=?=
	=?utf-8?b?w4XCgsK3woLCr8KCw4fClcKqwoLCqcKCw6jCgsOcwoLCt8KCwqnCgUg=?=
Message-ID: 20061209133725.42748mail@mail.truwejsiksknhsijsjsnsjamjsnheussjha_web.com

???????????????????v???????????????A?S?R?C???????????????????????????????????????B
?}?C?t?H?g?????^?A???????????????????C???????????????????H
?R?????g???????????N?G?X?g???????B?????????????B
http://freeweb.lovelovesexywoman.tonderuyo.com/LH/
?????????}?C?t?H?g???????????????????????H
???????????^?Y?t?o?????????????????????????????????c?B
?R?????g????????????





From forge-admin at jboss.com  Sat Dec 23 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sat, 23 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gxzvn-00060q-Rw@committer01.frg.pub.inap.atl.jboss.com>

Commit from sbryzak2 (2006-12-22 01:53 EST)
--------------------

added member card

  jboss-seam  examples/seamspace/resources/import.sql                                     1.6
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/Member.java         1.10
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileAction.java  1.5
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ProfileLocal.java   1.2
  jboss-seam  examples/seamspace/view/profile.xhtml                                       1.4
  jboss-seam  examples/seamspace/view/style/seamspace.css                                 1.6


Commit from tokada on branch JBossProfiler_Expansion (2006-12-22 02:04 EST)
----------------------------------------------------

Corrected some bugs.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ExecutionStack.java          1.1.2.3
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ConcurrencyMetrics.java      1.1.2.4
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ExecutionMetrics.java        1.1.2.4
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/MemoryMetrics.java           1.1.2.4
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ExecutionPassage.java        1.1.2.3
  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/view/servlet/ExecutionPassageDetail.java  1.1.2.4


Commit from sbryzak2 (2006-12-22 02:21 EST)
--------------------

it wouldn't be a real demo without duke, plus fixed jpeg scaling bug

  jboss-seam  examples/seamspace/resources/import.sql                                      1.7
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/ContentServlet.java  1.5


Commit from jmazzitelli (2006-12-22 02:52 EST)
-----------------------

add <i18n-msg> ant task so ant scripts can obtain i18n messages and either echo them or store them in properties.  jon will be able to use this to internationalize its installer

+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.jar       1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.jar.md5   1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.jar.sha1  1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.pom       1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.pom.md5   1.1
+ repository.jboss.com  maven2/i18nlog/i18nlog/1.0.9/i18nlog-1.0.9.pom.sha1  1.1


Commit from tokada on branch JBossProfiler_Expansion (2006-12-22 03:38 EST)
----------------------------------------------------

Added an interface.

  jboss-profiler  java/src/expansion/org/jboss/profiler/exp/agent/DefaultProfilerServiceMBean.java  1.1.2.5


Commit from dimitris (2006-12-22 04:43 EST)
--------------------

apache-httpclient depends on apache-codec.

  repository.jboss.com  apache-httpclient/3.0.1/component-info.xml  1.2


Commit from vralev (2006-12-22 08:09 EST)
------------------

portal 2.4.1.GA SP1

+   repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/.project                        1.1
+   repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/component-info.xml              1.1
+   repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/lib/jboss-portal.sar            1.1
+   repository.jboss.com/jboss-portal/jboss-portal-2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml  1.1


Commit from vralev (2006-12-22 08:32 EST)
------------------

2.4.1.GA-SP1 with correct name

+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/.project                        1.1
+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/component-info.xml              1.1
+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib/jboss-portal.sar            1.1
+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml  1.1


Commit from vralev (2006-12-22 09:47 EST)
------------------

delete (doesn't work)

-   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/component-info.xml              1.2
-   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib/jboss-portal.sar            1.2
-   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml  1.2


Commit from vblagojevic (2006-12-22 10:23 EST)
-----------------------

minor fixes in MessageListenerAdaptor

  JBossCache  src/org/jboss/cache/TreeCache.java  1.301


Commit from mandersen (2006-12-22 10:36 EST)
---------------------

remove useless constant

  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/properties/HibernatePropertyPage.java  1.7


Commit from mandersen (2006-12-22 10:37 EST)
---------------------

fix compile errors

  jbosside  hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test/KnownConfigurationsTest.java   1.3
  jbosside  hibernatetools/tests/org.hibernate.eclipse.console.test/src/org/hibernate/eclipse/console/test/ConsoleConfigurationTest.java  1.3


Commit from mandersen (2006-12-22 10:38 EST)
---------------------

Remove obsolete and never enabled ConsoleSQLLogFactory

- jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/sql/ConsoleSQLLogFactory.java  1.3
  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/plugin.xml                                                       1.59


Commit from mandersen (2006-12-22 10:39 EST)
---------------------

HBX-844 auto enable support projects linked to console configuration

  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/utils/ProjectUtils.java                          1.10
  jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/src/org/hibernate/eclipse/console/wizards/ConsoleConfigurationCreationWizard.java  1.14


Commit from vblagojevic (2006-12-22 13:55 EST)
-----------------------

split tests to avoid timeout

  JBossCache  tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java               1.21
+ JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransferCompatibilityTest.java  1.1
  JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java           1.26


Commit from rawb (2006-12-22 14:09 EST)
----------------

Further changes to the extension point infrastructure to adhere to newly-determined best practices.

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java       1.8
+ jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/AbstractPackageType.java  1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java                 1.4


Commit from vralev (2006-12-22 15:14 EST)
------------------

2.4.1.GA-SP1 with correct resources

+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/component-info.xml              1.3
+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/lib/jboss-portal.sar            1.3
+   repository.jboss.com/jboss-portal/2.4.1.GA-SP1/resources/portal-hsqldb-ds.xml  1.3


Commit from mandersen (2006-12-22 18:13 EST)
---------------------

new and noteworthy for b9

+ jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/hqleditorsetmaxresults.png               1.1
+ jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/consolelog.png                           1.1
+ jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/hbm2docwithgraph.jpg                     1.1
+ jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/hibernate-eclipse-news-3.2.0.beta9.html  1.1
+ jbosside  hibernatetools/plugins/org.hibernate.eclipse.console/doc/newandnoteworthy/easysetup.png                            1.1


Commit from rawb (2006-12-22 18:24 EST)
----------------

New PackageTypes for marshall.
Added deploy-only server (cannot start or stop)
Other associated changes.

  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PackagesPublisher.java                   1.4
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/PathPublisher.java                       1.3
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/IJBossServerPublisher.java               1.3
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/publishers/JstPackagesPublisher.java                1.3
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerBehavior.java                     1.18
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServerLaunchConfiguration.java          1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/JBossServer.java                             1.18
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableServerRuntime.java        1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableServer.java               1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableLaunchConfiguration.java  1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/stripped/DeployableServerBehavior.java       1.1
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/META-INF/MANIFEST.MF                                                                        1.14
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/plugin.xml                                                                                  1.23
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/WarPackageType.java                        1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/ObscurelyNamedPackageTypeSuperclass.java   1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/EarPackageType.java                        1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/packages/ModulePackageTypeConverter.java            1.1
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/ServerProcessModel.java                       1.9
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/model/EventLogModel.java                            1.4
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client/DoNothingClient.java                         1.5
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/client/JBossLaunchAdapter.java                      1.2
  jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/JBossServerCore.java                                1.9
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/attributes/IDeployableServer.java            1.1


Commit from rawb (2006-12-22 18:26 EST)
----------------

Added deploy-only server (cannot start or stop)
Other associated changes.

+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/PollingLabelProvider.java          1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/ComplexEventLogLabelProvider.java  1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/PublishLabelProvider.java          1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/events/PackageBuildLabelProvider.java     1.1
+ jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/wizards/StrippedServerWizardFragment.java                        1.1
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/ServerTableViewer.java                              1.6
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerTableViewer.java                         1.5
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/JBossServerView.java                                1.6
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/DescriptorXPathViewProvider.java          1.6
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/FilesetViewProvider.java                  1.3
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/ModuleViewProvider.java                   1.3
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/EventLogViewProvider.java                 1.6
- jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/PackageBuildLabelProvider.java            1.2
- jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/views/server/providers/PollingLabelProvider.java                 1.5
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/jbossui/org/jboss/ide/eclipse/as/ui/dialogs/XPathDialogs.java                                        1.10
  jbosside  as/plugins/org.jboss.ide.eclipse.as.ui/plugin.xml                                                                                           1.29


Commit from rawb (2006-12-22 18:41 EST)
----------------

CHanges to extension and how it is loaded

  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/JARPackageType.java       1.9
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/model/types/AbstractPackageType.java  1.4
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/schema/packageTypes.exsd                                                           1.3
  jbosside  core/plugins/org.jboss.ide.eclipse.packages.core/src/main/org/jboss/ide/eclipse/packages/core/ExtensionManager.java                 1.5
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061223/06ce0813/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 01:21:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 01:21:00 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1852 - in trunk: .
	docs/examples/ejb3mdb
	docs/examples/http/src/org/jboss/example/jms/http
	docs/examples/mdb/src/org/jboss/example/jms/mdb
	docs/examples/secure-socket/src/org/jboss/example/jms/securesocket
	docs/examples/stateless/src/org/jboss/example/jms/stateless/bean
	tests/smoke tests/src/org/jboss/test/messaging/core/paging
	tests/src/org/jboss/test/messaging/core/plugin/postoffice
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/tools/jmx util
Message-ID: <E1Gy0Fg-0006Wv-Hw@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-23 01:20:50 -0500 (Sat, 23 Dec 2006)
New Revision: 1852

Modified:
   trunk/docs/examples/ejb3mdb/do-not-distribute.properties
   trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java
   trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java
   trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java
   trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java
   trunk/messaging.iml
   trunk/tests/smoke/build.xml
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
   trunk/util/release-admin.xml
Log:
minor touch ups

Modified: trunk/docs/examples/ejb3mdb/do-not-distribute.properties
===================================================================
--- trunk/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/docs/examples/ejb3mdb/do-not-distribute.properties	2006-12-23 06:20:50 UTC (rev 1852)
@@ -5,5 +5,4 @@
 messaging.client.jar.path=../../../output/lib
 messaging.client.jar.name=jboss-messaging-client.jar
 jboss.configuration=messaging
-jboss.home=C:\\work\\src\\jboss-4.0.5.CR1-src\\build\\output\\jboss-4.0.5.CR1-ejb3
 jboss.home=C:\\work\\src\\jboss-4.0.5.GA-src\\build\\output\\jboss-4.0.5.GA-ejb3

Modified: trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java
===================================================================
--- trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/docs/examples/http/src/org/jboss/example/jms/http/HttpExample.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -110,7 +110,7 @@
       }
    }
    
-   private void closeConnection(Connection con) throws JMSException
+   private void closeConnection(Connection con)
    {
       try
       {

Modified: trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java
===================================================================
--- trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/docs/examples/mdb/src/org/jboss/example/jms/mdb/MDBExample.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -120,9 +120,9 @@
       {
          con.close();         
       }
-      catch(JMSException jmse)
+      catch(JMSException e)
       {
-         System.out.println("Could not close connection " + con + " exception was " + jmse);
+         System.out.println("Could not close connection " + con + " exception was " + e);
       }
    }
    

Modified: trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java
===================================================================
--- trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/docs/examples/secure-socket/src/org/jboss/example/jms/securesocket/SecureSocketExample.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -111,7 +111,7 @@
       
    }
    
-   private void closeConnection(Connection con) throws JMSException
+   private void closeConnection(Connection con)
    {
       try
       {

Modified: trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java
===================================================================
--- trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/docs/examples/stateless/src/org/jboss/example/jms/stateless/bean/StatelessSessionExampleBean.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -33,6 +33,7 @@
  */
 public class StatelessSessionExampleBean implements SessionBean
 {   
+
    private ConnectionFactory cf = null;
    
    public void drain(String queueName) throws Exception

Modified: trunk/messaging.iml
===================================================================
--- trunk/messaging.iml	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/messaging.iml	2006-12-23 06:20:50 UTC (rev 1852)
@@ -7,6 +7,7 @@
     <content url="file://$MODULE_DIR$">
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/common/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/distributed-topic/src" isTestSource="false" />
+      <sourceFolder url="file://$MODULE_DIR$/docs/examples/ejb3mdb/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/http/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/mdb/src" isTestSource="false" />
       <sourceFolder url="file://$MODULE_DIR$/docs/examples/queue-failover/src" isTestSource="false" />

Modified: trunk/tests/smoke/build.xml
===================================================================
--- trunk/tests/smoke/build.xml	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/smoke/build.xml	2006-12-23 06:20:50 UTC (rev 1852)
@@ -77,7 +77,6 @@
 
       <!-- 4.0.0, 4.0.1 NOT SUPPORTED -->
 
-<<<<<<< .working
       <!--
           Note on installer versions.
           When installing versions to test via the JBoss installer, make sure call by value is *not*
@@ -85,12 +84,10 @@
           the arrangement where JBoss is configured for all pass by reference
       -->
 
-=======
       <!--
            4.0.1sp1
       -->
 
->>>>>>> .merge-right.r1823
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss401sp1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
@@ -104,9 +101,7 @@
          <param name="jboss.home" value="${jboss402.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
-<<<<<<< .working
-=======
-<!--
+
       <!--
            4.0.3
       -->
@@ -115,21 +110,17 @@
          <param name="jboss.home" value="${jboss403.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
->>>>>>> .merge-right.r1823
 
       <antcall target="installation-test">
-<<<<<<< .working
-=======
          <param name="jboss.home" value="${jboss403-installer.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
--->
+
       <!--
            4.0.3SP1
       -->
 
       <antcall target="installation-test">
->>>>>>> .merge-right.r1823
          <param name="jboss.home" value="${jboss403SP1.home}"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
@@ -166,9 +157,7 @@
          <param name="run.stateless.example" value="false"/>
          <param name="run.secure-socket.example" value="false"/>
       </antcall>
-<<<<<<< .working
-=======
-<!--
+
       <!--
            4.0.5.GA
       -->
@@ -176,34 +165,8 @@
       <antcall target="installation-test">
          <param name="jboss.home" value="${jboss405GA.home}"/>
       </antcall>
->>>>>>> .merge-right.r1823
-                                                                                                <!--
-      <antcall target="installation-test">
-<<<<<<< .working
-=======
-         <param name="jboss.home" value="${jboss405GA-installer.home}"/>
-      </antcall>
-                                                                                                 -->
-      <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405GA.home}"/>
-         <param name="release.admin.target" value="standalone"/>
-         <param name="run.mdb.example" value="false"/>
-         <param name="run.stateless.example" value="false"/>
-         <param name="run.secure-socket.example" value="false"/>
-      </antcall>
 
       <antcall target="installation-test">
-         <param name="jboss.home" value="${jboss405GAejb3.home}"/>
-         <param name="no.java4" value="true"/>
-         <param name="run.ejb3mdb.example" value="true"/>
-      </antcall>
--->
-      <antcall target="installation-test">
->>>>>>> .merge-right.r1823
-         <param name="jboss.home" value="${jboss405GA.home}"/>
-      </antcall>
-
-      <antcall target="installation-test">
          <param name="jboss.home" value="${jboss405GA-installer.home}"/>
       </antcall>
 

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -23,7 +23,6 @@
 
 import java.util.List;
 
-import org.jboss.messaging.core.ChannelSupport;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -25,8 +25,6 @@
 import java.util.Iterator;
 import java.util.List;
 
-import org.jboss.jms.selector.Selector;
-import org.jboss.messaging.core.Filter;
 import org.jboss.messaging.core.Message;
 import org.jboss.messaging.core.MessageReference;
 import org.jboss.messaging.core.local.PagingFilteredQueue;
@@ -96,19 +94,18 @@
          
          //Bind one durable
          
-         Filter filter1 = new Selector("x = 'cheese'");
-         Filter filter2 = new Selector("y = 'bread'");
+         PagingFilteredQueue queue1 =
+            new PagingFilteredQueue("durableQueue", channelIDManager.getID(), ms, pm, true, true,
+                                    (QueuedExecutor)pool.get(), null);
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("durableQueue", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
          
-         
          Binding binding1 =
             office1.bindQueue(new SimpleCondition("condition1"), queue1);
          
          //Binding twice with the same name should fail      
          try
          {
-            Binding bindFail = office1.bindQueue(new SimpleCondition("condition1"), queue1);
+            office1.bindQueue(new SimpleCondition("condition1"), queue1);
             fail();
          }
          catch (IllegalArgumentException e)
@@ -117,7 +114,9 @@
          }
                
          //Bind one non durable
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("nonDurableQueue", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 =
+            new PagingFilteredQueue("nonDurableQueue", channelIDManager.getID(), ms, pm, true,
+                                    false, (QueuedExecutor)pool.get(), null);
          
          Binding binding2 =
             office1.bindQueue(new SimpleCondition("condition2"), queue2);
@@ -333,35 +332,41 @@
       
          postOffice = createPostOffice();
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 =
+            new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding1 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 =
+            new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding2 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue3 =
+            new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding3 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
-         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue4 =
+            new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding4 =
-            postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
+         postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
-         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue5 =
+            new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding5 =
-            postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
+         postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
-         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue6 =
+            new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding6 =
-            postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
+         postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
       
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -485,10 +490,11 @@
       {      
          postOffice = createPostOffice();
          
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 =
+            new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding1 =
-            postOffice.bindQueue(new SimpleCondition("condition1"), queue1);
+         postOffice.bindQueue(new SimpleCondition("condition1"), queue1);
               
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -498,7 +504,8 @@
          Message msg1 = CoreMessageFactory.createCoreMessage(1);      
          MessageReference ref1 = ms.reference(msg1);
          
-         boolean routed = postOffice.route(ref1, new SimpleCondition("this won't match anything"), null);      
+         boolean routed =
+            postOffice.route(ref1, new SimpleCondition("this won't match anything"), null);
          
          assertFalse(routed);
                
@@ -537,20 +544,23 @@
          
          SimpleFilter filter = new SimpleFilter(2);
       
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), filter);
+         PagingFilteredQueue queue1 =
+            new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), filter);
          
-         Binding binding1 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 =
+            new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding2 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue3 =
+            new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding3 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);   
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          queue1.add(receiver1);
@@ -639,35 +649,41 @@
       {      
          postOffice = createPostOffice();
       
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 =
+            new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding1 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 =
+            new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding2 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
          
-         PagingFilteredQueue queue3 = new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue3 =
+            new PagingFilteredQueue("queue3", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding3 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue3);
          
-         PagingFilteredQueue queue4 = new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue4 =
+            new PagingFilteredQueue("queue4", channelIDManager.getID(), ms, pm, true, true,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding4 =
-            postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
+         postOffice.bindQueue(new SimpleCondition("topic2"), queue4);
          
-         PagingFilteredQueue queue5 = new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue5 =
+            new PagingFilteredQueue("queue5", channelIDManager.getID(), ms, pm, true, true,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding5 =
-            postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
+         postOffice.bindQueue(new SimpleCondition("topic2"), queue5);
          
-         PagingFilteredQueue queue6 = new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue6 =
+            new PagingFilteredQueue("queue6", channelIDManager.getID(), ms, pm, true, true,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding6 =
-            postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
+         postOffice.bindQueue(new SimpleCondition("topic2"), queue6);
       
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);
@@ -813,15 +829,17 @@
       {      
          postOffice = createPostOffice();
       
-         PagingFilteredQueue queue1 = new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue1 =
+            new PagingFilteredQueue("queue1", channelIDManager.getID(), ms, pm, true, false,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding1 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue1);
          
-         PagingFilteredQueue queue2 = new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, true, (QueuedExecutor)pool.get(), null);
+         PagingFilteredQueue queue2 =
+            new PagingFilteredQueue("queue2", channelIDManager.getID(), ms, pm, true, true,
+                                    (QueuedExecutor)pool.get(), null);
          
-         Binding binding2 =
-            postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
+         postOffice.bindQueue(new SimpleCondition("topic1"), queue2);
           
          SimpleReceiver receiver1 = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);;
          queue1.add(receiver1);

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -544,15 +544,12 @@
       {
          if (receiver != null)
          {
-            //Send to receiver
-            
-            Delivery del = receiver.handle(observer, reference, tx);
-            
-            return del;
+            // Send to receiver
+            return receiver.handle(observer, reference, tx);
          }
          else
          {
-            //Store internally
+            // Store internally
             refs.add(reference);
             
             return new SimpleDelivery(observer, reference);

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ConnectionTest.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -152,21 +152,21 @@
    
    public void testResourceManagerFactory()
    {
-      ResourceManager rm1 = ResourceManagerFactory.instance.checkOutResourceManager(1);
+      ResourceManagerFactory.instance.checkOutResourceManager(1);
       
-      ResourceManager rm2 = ResourceManagerFactory.instance.checkOutResourceManager(2);
+      ResourceManagerFactory.instance.checkOutResourceManager(2);
       
-      ResourceManager rm3 = ResourceManagerFactory.instance.checkOutResourceManager(3);
+      ResourceManagerFactory.instance.checkOutResourceManager(3);
       
-      ResourceManager rm4 = ResourceManagerFactory.instance.checkOutResourceManager(4);
+      ResourceManagerFactory.instance.checkOutResourceManager(4);
       
       assertEquals(4, ResourceManagerFactory.instance.size());
       
-      ResourceManager rm4_2 = ResourceManagerFactory.instance.checkOutResourceManager(4);
+      ResourceManagerFactory.instance.checkOutResourceManager(4);
       
       assertEquals(4, ResourceManagerFactory.instance.size());
       
-      ResourceManager rm4_3 = ResourceManagerFactory.instance.checkOutResourceManager(4);
+      ResourceManagerFactory.instance.checkOutResourceManager(4);
       
       assertEquals(4, ResourceManagerFactory.instance.size());
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ManifestTest.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -91,13 +91,13 @@
       // Compare the value from ConnectionMetaData and MANIFEST.MF
       Attributes attrs = manifest.getMainAttributes();
       
-      System.out.println("META--> " + meta.getJMSMajorVersion()); 
-      System.out.println("META--> " + meta.getJMSMinorVersion()); 
-      System.out.println("META--> " + meta.getJMSProviderName()); 
-      System.out.println("META--> " + meta.getJMSVersion()); 
-      System.out.println("META--> " + meta.getProviderMajorVersion()); 
-      System.out.println("META--> " + meta.getProviderMinorVersion()); 
-      System.out.println("META--> " + meta.getProviderVersion());
+      log.info("META--> " + meta.getJMSMajorVersion());
+      log.info("META--> " + meta.getJMSMinorVersion());
+      log.info("META--> " + meta.getJMSProviderName());
+      log.info("META--> " + meta.getJMSVersion());
+      log.info("META--> " + meta.getProviderMajorVersion());
+      log.info("META--> " + meta.getProviderMinorVersion());
+      log.info("META--> " + meta.getProviderVersion());
       
       Iterator itr = attrs.entrySet().iterator();
       while (itr.hasNext()) {

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-23 06:20:50 UTC (rev 1852)
@@ -1158,8 +1158,6 @@
 
       String transport = config.getRemotingTransport();
       
-      log.info("*** Using transport: " + transport);
-
       String params = "/?marshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
                       "unmarshaller=org.jboss.jms.server.remoting.JMSWireFormat&" +
                       "serializationtype=" + serializationType + "&" +

Modified: trunk/util/release-admin.xml
===================================================================
--- trunk/util/release-admin.xml	2006-12-22 22:50:45 UTC (rev 1851)
+++ trunk/util/release-admin.xml	2006-12-23 06:20:50 UTC (rev 1852)
@@ -25,14 +25,9 @@
    <property name="lib.jbossts.home" value="${lib.home}/jbossts"/>
    <property name="output.lib.home" value="../output/lib"/>
 
-<<<<<<< .working
    <!--
         DO NOT change these values here, otherwise the installation script won't work. If you need
         to change them, to it in do-not-distribute.properties.
-=======
-   <!-- DO NOT change this value here, otherwise the installation script won't work. Change it in
-        do-not-distribute.properties.
->>>>>>> .merge-right.r1823
    -->
    <property name="main.artifact.location" value=".."/>
    <property name="auxiliary.artifacts.location" value="../examples/config"/>



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 03:43:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 03:43:47 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1853 - in trunk:
	src/main/org/jboss/jms/server/endpoint
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1Gy2Tr-0000Uy-Ga@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-23 03:43:42 -0500 (Sat, 23 Dec 2006)
New Revision: 1853

Modified:
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/tests/src/org/jboss/test/messaging/jms/XATest.java
Log:
serialize deliveries


Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-23 06:20:50 UTC (rev 1852)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-23 08:43:42 UTC (rev 1853)
@@ -47,6 +47,9 @@
 import org.jboss.remoting.callback.HandleCallbackException;
 import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
 
+import EDU.oswego.cs.dl.util.concurrent.Executor;
+import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+
 /**
  * Concrete implementation of ConsumerEndpoint.
  * 
@@ -100,6 +103,8 @@
    // Must be volatile
    private volatile boolean clientAccepting;
    
+   private Executor executor; /// TEMPORARILY
+   
    // Constructors --------------------------------------------------
 
    ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
@@ -125,6 +130,9 @@
       
       this.destination = dest;
       
+      //TEMP
+      this.executor = new QueuedExecutor();
+      
       //Always start as false - wait for consumer to initiate
       this.clientAccepting = false;
       
@@ -216,21 +224,47 @@
          
          Callback callback = new Callback(mm);
    
+         //FIXME - we need to use the asynch callback API, this is the Sync one
+
+         //This is temporary - to ensure deliveries happen in sequence!!!!!!!!
+         
+         class Runner implements Runnable
+         {
+            Callback cb;
+            
+            Runner(Callback cb)
+            {
+               this.cb = cb;
+            }
+         
+            public void run()
+            {
+               try
+               {            
+                  callbackHandler.handleCallback(cb);               
+               }
+               catch (HandleCallbackException e)
+               {
+                  log.error("Failed to handle callback", e);
+               }
+               
+            }  
+         }
+         
          try
          {
-            //FIXME - we need to use the asynch callback API, this is the Sync one
-            callbackHandler.handleCallback(callback);
+            executor.execute(new Runner(callback));
          }
-         catch (HandleCallbackException e)
+         catch (InterruptedException e)
          {
-            log.error("Failed to handle callback", e);
-            
-            return null;
+            //Ignore
          }
-                             
+           
          return delivery;      
       }
    }      
+   
+   
 
    // Filter implementation -----------------------------------------
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/XATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-23 06:20:50 UTC (rev 1852)
+++ trunk/tests/src/org/jboss/test/messaging/jms/XATest.java	2006-12-23 08:43:42 UTC (rev 1853)
@@ -1371,6 +1371,9 @@
          assertEquals("jellyfish2", r1.getText());
 
          cons1.close();
+         
+         //Cancel is asynch
+         Thread.sleep(500);
 
          MessageConsumer cons2 = sess2.createConsumer(queue);
          TextMessage r2 = (TextMessage)cons2.receive(MAX_TIMEOUT);



From twq877sa45 at doramail.com  Sat Dec 23 04:17:20 2006
From: twq877sa45 at doramail.com (twq877sa45 at doramail.com)
Date: Sat, 23 Dec 2006 04:17:20 -0500
Subject: [jboss-cvs] =?utf-8?b?wo/CrcKCwrXCgsK+woLCr8KScMKCwrjCgsKpwoI=?=
	=?utf-8?b?wrXCgsKiwo7DisKQXsKCw7DCjMKpwoLDhMKCwq3CgsOqwoLDnMKCwrk=?=
	=?utf-8?b?woLDscKCwqnCgUg=?=
Message-ID: 20061223181623.70430mail@mail.asuyikmnisueyrutjdfhsnsisjdjdusjshdajm.com

?????????????????[?????????????????????B
???A?????G?b?`???????C???????c??
???????A?????????????????????????????????????H
???????c???????????^????????????????????????????????????????????????
http://www.go-perfectfree.com.tonderuyo.com/oosex/
???z??????????????
?????????A?????A???????????????????????????????????????I
?????????????A???~???????c??
?N???X?}?X?????O?????A?y??????????????????????





From fieru at kobej.zzn.com  Sat Dec 23 04:22:37 2006
From: fieru at kobej.zzn.com (fieru at kobej.zzn.com)
Date: Sat, 23 Dec 2006 04:22:37 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCscKCw4zCj1TClsKWwoLDicKJw6/CgsKmwoI=?=
	=?utf-8?b?w5zCgsK3woLCqcKBSA==?=
Message-ID: 20061223185312.78903mail@mail.ertyuisdfskjhjnuyiuhjsdfndsjyiterte.com

?N???X?}?X?????A?????\?????????????????????H
???????????????????????????A?????\?????????????c?B
???????????????????????H
???????????}?????s???????I
???l?????????????????????c?B
http://completefree.freeblog.com.tonderuyo.com/meets/




From ptsekov at jboss.org  Sat Dec 23 04:55:18 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 23 Dec 2006 04:55:18 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/tools  ...
Message-ID: <E1Gy3b4-0001j3-Q9@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/23 04:55:18

  Modified:    tests/compat/org/jboss/tools  Tag: Branch_JBossCache_1_4_0
                        ClassVersionInfo.java
  Log:
  Add a no-argument constructor and setter methods for each getter method. Make this class look more like a JavaBean so that it can be serialized via java.beans.XMLEncoder.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +20 -1     JBossCache/tests/compat/org/jboss/tools/Attic/ClassVersionInfo.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClassVersionInfo.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/compat/org/jboss/tools/Attic/ClassVersionInfo.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- ClassVersionInfo.java	16 Dec 2006 13:13:03 -0000	1.1.2.1
  +++ ClassVersionInfo.java	23 Dec 2006 09:55:18 -0000	1.1.2.2
  @@ -16,7 +16,7 @@
    * Encapsulates a class serialVersionUID and codebase.
    * 
    * @author Scott.Stark at jboss.org
  - * @version $Revision: 1.1.2.1 $
  + * @version $Revision: 1.1.2.2 $
    */
   public class ClassVersionInfo implements Serializable
   {
  @@ -28,6 +28,8 @@
      private String name;
      private boolean hasExplicitSerialVersionUID;
   
  +   public ClassVersionInfo() {}
  +
      public ClassVersionInfo(String name, ClassLoader loader)
         throws ClassNotFoundException
      {
  @@ -56,15 +58,32 @@
      {
         return serialVersion;
      }
  +
  +   public void setSerialVersion(long serialVersion)
  +   {
  +      this.serialVersion = serialVersion;
  +   }
  +
      public boolean getHasExplicitSerialVersionUID()
      {
         return hasExplicitSerialVersionUID;
      }
  +
  +   public void setHasExplicitSerialVersionUID(boolean flag)
  +   {
  +      hasExplicitSerialVersionUID = flag;
  +   }
  +
      public String getName()
      {
         return name;
      }
   
  +   public void setName(String name)
  +   {
  +      this.name = name;
  +   }
  +
      public String toString()
      {
         StringBuffer tmp = new StringBuffer("ClassVersionInfo");
  
  
  


From ptsekov at jboss.org  Sat Dec 23 05:40:48 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 23 Dec 2006 05:40:48 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/tools  ...
Message-ID: <E1Gy4J6-0002gz-Eo@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/23 05:40:48

  Modified:    tests/compat/org/jboss/tools  Tag: Branch_JBossCache_1_4_0
                        SerialVersionUID.java
  Log:
  * SerialVersionUID.java (SerialVersionUID::processProperties): Do not copy non-existing system properties.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +4 -1      JBossCache/tests/compat/org/jboss/tools/Attic/SerialVersionUID.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUID.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/compat/org/jboss/tools/Attic/SerialVersionUID.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SerialVersionUID.java	16 Dec 2006 13:13:03 -0000	1.1.2.1
  +++ SerialVersionUID.java	23 Dec 2006 10:40:48 -0000	1.1.2.2
  @@ -60,8 +60,11 @@
         {
            propName = (String) e.nextElement();
            propValue = System.getProperty(propName);
  +         if (propValue != null)
  +         {
            props.setProperty(propName, propValue);
         }
  +      }
   
         String tmpStr;
         tmpStr = props.getProperty("libdir.list");
  
  
  


From ptsekov at jboss.org  Sat Dec 23 05:47:33 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 23 Dec 2006 05:47:33 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/tools  ...
Message-ID: <E1Gy4Pd-0002on-7F@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/23 05:47:33

  Modified:    tests/compat/org/jboss/tools  Tag: Branch_JBossCache_1_4_0
                        SerialVersionUID.java
  Log:
  * SerialVersionUID.java (SerialVersionUID::outputXML): New class variable.
  (SerialVersionUID::processProperties): Add support for new boolean property 'output.xml'.
  (SerialVersionUID::main): Write the collected information as either serialized java object or as XML generated by java.beans.XMLEncoder.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +32 -4     JBossCache/tests/compat/org/jboss/tools/Attic/SerialVersionUID.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUID.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/compat/org/jboss/tools/Attic/SerialVersionUID.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- SerialVersionUID.java	23 Dec 2006 10:40:48 -0000	1.1.2.2
  +++ SerialVersionUID.java	23 Dec 2006 10:47:33 -0000	1.1.2.3
  @@ -6,6 +6,7 @@
    */
   package org.jboss.tools;
   
  +import java.beans.XMLEncoder;
   import java.io.File;
   import java.io.FileInputStream;
   import java.io.FileOutputStream;
  @@ -38,6 +39,8 @@
   
      static LinkedHashSet libdirList = new LinkedHashSet();
   
  +   static boolean outputXML = false;
  +
      static void parsePropertyList(String listValue, Set dst)
      {
         String elements[] = listValue.split(",");
  @@ -53,6 +56,7 @@
         Properties fallbackProps = new Properties();
         // A list of directories to scan for .jar files.
         fallbackProps.setProperty("libdir.list", "lib");
  +      fallbackProps.setProperty("output.xml", "true");
   
         Properties props = new Properties(fallbackProps);
         String propName, propValue;
  @@ -73,6 +77,17 @@
            tmpStr = fallbackProps.getProperty("libdir.list");
         }
         parsePropertyList(tmpStr, libdirList);
  +
  +      tmpStr = props.getProperty("output.xml");
  +      if (tmpStr.length() == 0)
  +      {
  +         tmpStr = fallbackProps.getProperty("output.xml");
  +      }
  +      tmpStr.trim();
  +      if (tmpStr == "yes" || tmpStr == "true")
  +      {
  +         outputXML = true;
  +      }
      }
   
      static void buildJarSet(File dir, LinkedHashSet jarFiles)
  @@ -199,10 +214,23 @@
         Map classVersionMap = processJars();
         log.info(classVersionMap.size() + " serialVersionUIDs stored into the database");
   
  -      // Write the map out the object file
         FileOutputStream fos = new FileOutputStream("serialuid.ser");
  +      if (outputXML == false)
  +      {
  +         // Write the map out the object file
         ObjectOutputStream oos = new ObjectOutputStream(fos);
         oos.writeObject(classVersionMap);
  -      fos.close();
  +         oos.close();
  +      }
  +      else
  +      {
  +         XMLEncoder xml = new XMLEncoder(fos);
  +         Iterator mapIterator = classVersionMap.values().iterator();
  +         while (mapIterator.hasNext())
  +         {
  +            xml.writeObject(mapIterator.next());
  +         }
  +         xml.close();
  +      }
      }
   }
  
  
  


From gfd654dsgf at Safe-mail.net  Sat Dec 23 06:39:07 2006
From: gfd654dsgf at Safe-mail.net (gfd654dsgf at Safe-mail.net)
Date: Sat, 23 Dec 2006 06:39:07 -0500
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCPi5AWjxqJEckYiEiJCQkJCRHJDkbKEI=?=
	=?iso-2022-jp?b?GyRCJCshKRsoQg==?=
Message-ID: 20061223184908.69185mail@mail.vreyeiisjdalskdjoutyerijdhfksdjfnasd.com

?????????????????????????????????
????????????????????????????????????????
??????????????????????????????????????????
????????????????????????
????????
http://www.go-perfectfree.com.tonderuyo.com/kin/



From ptsekov at jboss.org  Sat Dec 23 06:58:00 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 23 Dec 2006 06:58:00 -0500
Subject: [jboss-cvs] JBossCache/etc/svuid-db - New directory ...
Message-ID: <E1Gy5Vo-0004B0-36@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/23 06:58:00

  Log:
  Directory /cvsroot/jboss/JBossCache/etc/svuid-db added to the repository
  --> Using per-directory sticky tag `Branch_JBossCache_1_4_0'


From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 09:48:48 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 09:48:48 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1854 - in
	trunk/src/main/org/jboss: jms/client/container
	jms/client/remoting jms/server/endpoint messaging/core
Message-ID: <E1Gy8B6-0007JL-BW@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-23 09:48:44 -0500 (Sat, 23 Dec 2006)
New Revision: 1854

Modified:
   trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
Log:
Fixed cancellation order



Modified: trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-23 08:43:42 UTC (rev 1853)
+++ trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-23 14:48:44 UTC (rev 1854)
@@ -101,10 +101,10 @@
    public Object handleClosing(Invocation invocation) throws Throwable
    {      
       ConsumerState consumerState = getState(invocation);
+        
       
       // First we call close on the messagecallbackhandler which waits for onMessage invocations      
-      // to complete and then cancels anything in the client buffer.
-      // any further messages received will be ignored
+      // to complete any further messages received will be ignored
       consumerState.getMessageCallbackHandler().close();
       
       long lastDeliveryId = consumerState.getMessageCallbackHandler().getLastDeliveryId();
@@ -128,7 +128,13 @@
       
       ConsumerDelegate del = (ConsumerDelegate)invocation.getTargetObject();
          
+      //Now we need to cancel any inflight messages - this must be done before
+      //cancelling the message callback handler buffer, so that messages end up back in the channel
+      //in the right order
       del.cancelInflightMessages(lastDeliveryId);
+      
+      //And then we cancel any messages still in the message callback handler buffer
+      consumerState.getMessageCallbackHandler().cancelBuffer();
                                    
       return res;
    }      

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-23 08:43:42 UTC (rev 1853)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-23 14:48:44 UTC (rev 1854)
@@ -269,6 +269,43 @@
       }   
    }
    
+   public void cancelBuffer() throws JMSException
+   {
+      synchronized (mainLock)
+      {      
+         // Now we cancel anything left in the buffer. The reason we do this now is that otherwise the
+         // deliveries wouldn't get cancelled until session close (since we don't cancel consumer's
+         // deliveries until then), which is too late - since we need to preserve the order of messages
+         // delivered in a session.
+         
+         if (!buffer.isEmpty())
+         {            
+            // Now we cancel any deliveries that might be waiting in our buffer. This is because
+            // otherwise the messages wouldn't get cancelled until the corresponding session died.
+            // So if another consumer in another session tried to consume from the channel before that
+            // session died it wouldn't receive those messages.
+            // We can't just cancel all the messages in the SCE since some of those messages might
+            // have actually been delivered (unlike these) and we may want to acknowledge them
+            // later, after this consumer has been closed
+   
+            List cancels = new ArrayList();
+   
+            for(Iterator i = buffer.iterator(); i.hasNext();)
+            {
+               MessageProxy mp = (MessageProxy)i.next();
+               
+               DefaultCancel ack = new DefaultCancel(mp.getDeliveryId(), mp.getDeliveryCount());
+               
+               cancels.add(ack);
+            }
+                  
+            sessionDelegate.cancelDeliveries(cancels);
+            
+            buffer.clear();
+         }    
+      }
+   }
+   
    public void close() throws JMSException
    {   
       synchronized (mainLock)
@@ -291,39 +328,8 @@
          this.listener = null;
       }
 
-      waitForOnMessageToComplete();
+      waitForOnMessageToComplete();                  
       
-      // Now we cancel anything left in the buffer. The reason we do this now is that otherwise the
-      // deliveries wouldn't get cancelled until session close (since we don't cancel consumer's
-      // deliveries until then), which is too late - since we need to preserve the order of messages
-      // delivered in a session.
-      
-      if (!buffer.isEmpty())
-      {            
-         // Now we cancel any deliveries that might be waiting in our buffer. This is because
-         // otherwise the messages wouldn't get cancelled until the corresponding session died.
-         // So if another consumer in another session tried to consume from the channel before that
-         // session died it wouldn't receive those messages.
-         // We can't just cancel all the messages in the SCE since some of those messages might
-         // have actually been delivered (unlike these) and we may want to acknowledge them
-         // later, after this consumer has been closed
-
-         List cancels = new ArrayList();
-
-         for(Iterator i = buffer.iterator(); i.hasNext();)
-         {
-            MessageProxy mp = (MessageProxy)i.next();
-            
-            DefaultCancel ack = new DefaultCancel(mp.getDeliveryId(), mp.getDeliveryCount());
-            
-            cancels.add(ack);
-         }
-               
-         sessionDelegate.cancelDeliveries(cancels);
-         
-         buffer.clear();
-      }                
-      
       if (trace) { log.trace(this + " closed"); }
    }
      
@@ -665,7 +671,7 @@
          m = (MessageProxy)buffer.removeFirst();
       }
 
-      if (trace) { log.trace("InterruptedException, " + this + ".getMessage() returning " + m); }
+      if (trace) { log.trace(this + ".getMessage() returning " + m); }
       return m;
    }
    

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-23 08:43:42 UTC (rev 1853)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-23 14:48:44 UTC (rev 1854)
@@ -47,8 +47,8 @@
 import org.jboss.remoting.callback.HandleCallbackException;
 import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
 
-import EDU.oswego.cs.dl.util.concurrent.Executor;
-import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
+import EDU.oswego.cs.dl.util.concurrent.Sync;
 
 /**
  * Concrete implementation of ConsumerEndpoint.
@@ -102,9 +102,7 @@
 
    // Must be volatile
    private volatile boolean clientAccepting;
-   
-   private Executor executor; /// TEMPORARILY
-   
+
    // Constructors --------------------------------------------------
 
    ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
@@ -130,9 +128,6 @@
       
       this.destination = dest;
       
-      //TEMP
-      this.executor = new QueuedExecutor();
-      
       //Always start as false - wait for consumer to initiate
       this.clientAccepting = false;
       
@@ -223,43 +218,18 @@
          MessagingMarshallable mm = new MessagingMarshallable(versionToUse, del);
          
          Callback callback = new Callback(mm);
-   
-         //FIXME - we need to use the asynch callback API, this is the Sync one
-
-         //This is temporary - to ensure deliveries happen in sequence!!!!!!!!
-         
-         class Runner implements Runnable
-         {
-            Callback cb;
-            
-            Runner(Callback cb)
-            {
-               this.cb = cb;
-            }
-         
-            public void run()
-            {
-               try
-               {            
-                  callbackHandler.handleCallback(cb);               
-               }
-               catch (HandleCallbackException e)
-               {
-                  log.error("Failed to handle callback", e);
-               }
-               
-            }  
-         }
-         
+           
          try
          {
-            executor.execute(new Runner(callback));
+            callbackHandler.handleCallback(callback);  
          }
-         catch (InterruptedException e)
+         catch (HandleCallbackException e)
          {
-            //Ignore
+            log.error("Failed to handle callback", e);
+            
+            return null;
          }
-           
+              
          return delivery;      
       }
    }      

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-23 08:43:42 UTC (rev 1853)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-23 14:48:44 UTC (rev 1854)
@@ -645,8 +645,6 @@
                      // state but before delivery being added (observed).
                      synchronized (del)
                      {
-                        if (trace) { log.trace(this + " incrementing delivery count for " + del); }
-
                         // FIXME - It's actually possible the delivery could be cancelled before it reaches
                         // here, in which case we wouldn't get a delivery but we still need to increment the
                         // delivery count. TODO http://jira.jboss.com/jira/browse/JBMESSAGING-355



From ptsekov at jboss.org  Sat Dec 23 10:36:00 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 23 Dec 2006 10:36:00 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/cache/compat  ...
Message-ID: <E1Gy8um-0008B9-4V@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/23 10:36:00

  Modified:    tests/compat/org/jboss/cache/compat  Tag:
                        Branch_JBossCache_1_4_0
                        SerialVersionUIDUnitTestCase.java
  Log:
  * SerialVersionUIDUnitTestCase.java: Add tests for compatibility with JBossCache 1.3.0.GA and 1.4.0.GA.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +109 -0    JBossCache/tests/compat/org/jboss/cache/compat/Attic/SerialVersionUIDUnitTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUIDUnitTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/compat/org/jboss/cache/compat/Attic/SerialVersionUIDUnitTestCase.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SerialVersionUIDUnitTestCase.java	16 Dec 2006 13:13:03 -0000	1.1.2.1
  +++ SerialVersionUIDUnitTestCase.java	23 Dec 2006 15:36:00 -0000	1.1.2.2
  @@ -6,6 +6,7 @@
    */
   package org.jboss.cache.compat;
   
  +import java.beans.XMLDecoder;
   import java.io.File;
   import java.io.FileInputStream;
   import java.io.FileWriter;
  @@ -13,6 +14,7 @@
   import java.io.ObjectInputStream;
   import java.util.Iterator;
   import java.util.Map;
  +import java.util.TreeMap;
   
   import junit.framework.Test;
   import junit.framework.TestCase;
  @@ -30,11 +32,116 @@
    */
   public class SerialVersionUIDUnitTestCase extends TestCase
   {
  +   private static final String DB_DIR = "etc/svuid-db";
  +   private static final String DB_FILE_PREFIX = "svuid-";
  +   private static final String VERSION_STRING_1_3_0_GA = "1.3.0.GA";
  +   private static final String VERSION_STRING_1_4_0_GA = "1.4.0.GA";
  +   private static final String JAVA_VERSION_PREFIX_14 = "14";
  +   private static final String JAVA_VERSION_PREFIX_50 = "50";
  +
  +   int mismatchCount = 0;
  +
  +   StringBuffer messages = null;
  +
      public SerialVersionUIDUnitTestCase(String name)
      {
         super(name);
      }
   
  +   protected void setUp()
  +   {
  +      mismatchCount = 0;
  +
  +      if (messages == null)
  +      {
  +         messages = new StringBuffer();
  +      }
  +   }
  +
  +   protected void tearDown()
  +   {
  +      messages.setLength(0);
  +   }
  +
  +   public void testCompat_1_3_0_GA() throws Exception
  +   {
  +      String prefix = getFilePrefix() + VERSION_STRING_1_3_0_GA;
  +      Map db = readDatabase(prefix);
  +      mismatchCount = compare(db, calcClassInfoMap(), prefix,
  +			      new String[0], messages);
  +
  +      System.out.println("serialVersionUID mismatches = " + mismatchCount);
  +      if (mismatchCount != 0)
  +      {
  +         fail("Failures for :" + messages.toString());
  +      }
  +   }
  +
  +   public void testCompat_1_4_0_GA() throws Exception
  +   {
  +      String prefix = getFilePrefix() + VERSION_STRING_1_4_0_GA;
  +      Map db = readDatabase(prefix);
  +      mismatchCount = compare(db, calcClassInfoMap(), prefix,
  +			      new String[0], messages);
  +
  +      System.out.println("serialVersionUID mismatches = " + mismatchCount);
  +      if (mismatchCount != 0)
  +      {
  +         fail("Failures for :" + messages.toString());
  +      }
  +   }
  +
  +   private String getFilePrefix()
  +   {
  +      String javaVersion = System.getProperty("java.version").trim();
  +      if (javaVersion.startsWith("1.5."))
  +      {
  +         return DB_FILE_PREFIX + JAVA_VERSION_PREFIX_50 + ".";
  +      }
  +      else if (javaVersion.startsWith("1.4."))
  +      {
  +         return DB_FILE_PREFIX + JAVA_VERSION_PREFIX_14 + ".";
  +      }
  +      else
  +      {
  +         return "";
  +      }
  +   }
  +
  +   private Map readDatabase(String dbFilePrefix)
  +      throws Exception
  +   {
  +      File dbFile = new File(DB_DIR, dbFilePrefix + ".xml");
  +      FileInputStream inputStream = new FileInputStream(dbFile);
  +      XMLDecoder xmlObjects = new XMLDecoder(inputStream);
  +      ClassVersionInfo svuidInfo;
  +      TreeMap db = new TreeMap();
  +      boolean doQuit = false;
  +
  +      do
  +      {
  +         try
  +         {
  +            svuidInfo = (ClassVersionInfo) xmlObjects.readObject();
  +            db.put(svuidInfo.getName(), svuidInfo);
  +         }
  +         /*
  +          * TODO: Keep working ?
  +         catch (ClassCastException e)
  +         {
  +            ;
  +         }
  +         */
  +         catch (ArrayIndexOutOfBoundsException e)
  +         {
  +            // No more data
  +            doQuit = true;
  +         }
  +      } while (doQuit == false);
  +
  +      return db;
  +   }
  +
      /**
       Compare two sets of classes for serialVersionUID compatibility.
   
  @@ -109,6 +216,8 @@
      public static Test suite() throws Exception
      {
         TestSuite suite = new TestSuite();
  +      suite.addTest(new SerialVersionUIDUnitTestCase("testCompat_1_4_0_GA"));
  +      suite.addTest(new SerialVersionUIDUnitTestCase("testCompat_1_3_0_GA"));
   
         return suite;
      }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 13:38:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 13:38:10 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1855 - in trunk:
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/remoting tests/etc
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1GyBl4-0007B0-IR@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-23 13:38:04 -0500 (Sat, 23 Dec 2006)
New Revision: 1855

Modified:
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/tests/etc/log4j.xml
   trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
Log:
A few tweaks, new test



Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-23 14:48:44 UTC (rev 1854)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-23 18:38:04 UTC (rev 1855)
@@ -38,7 +38,6 @@
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.util.Future;
-import org.jboss.remoting.callback.HandleCallbackException;
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
@@ -452,11 +451,15 @@
          //if we've already sent it - hence the check
          startSendingMessageSent = true;
             
+         if (trace) { log.trace("Telling server to start resume sending messages, buffer size is " + buffer.size()); }
+         
          sendChangeRateMessage(1);                    
       }
       
       m.incDeliveryCount();
       
+      if (trace) { log.trace(this + " receive() returning " + m); }
+      
       return m;
    }    
    
@@ -548,12 +551,10 @@
    
    private void sendChangeRateMessage(float newRate) 
    {
-      //FIXME - We should be able to execute this invocation as a true
-      //remoting asynchronous invocation - i.e. it is written to the transport
-      //and no response is waited for
-      //Therefore there is no need to execute it here on a separate thread.
-      //Unfortunately remoting does not currently support this so this
-      //will be SLOW now.
+      // FIXME - when the latest remoting changes make it into a release, we need
+      //to use server side one way invocations here.
+      //I.e. we want to sent the invocation to the transport on the this thread and 
+      //return immediately without waiting for a response.
       try
       {
          consumerDelegate.changeRate(newRate);
@@ -671,7 +672,6 @@
          m = (MessageProxy)buffer.removeFirst();
       }
 
-      if (trace) { log.trace(this + ".getMessage() returning " + m); }
       return m;
    }
    
@@ -768,6 +768,8 @@
          {                    
             startSendingMessageSent = true;
             
+            if (trace) { log.trace("Telling server to start resume sending messages, buffer size is " + buffer.size()); }            
+            
             sendChangeRateMessage(1);
          } 
          

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-23 14:48:44 UTC (rev 1854)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-23 18:38:04 UTC (rev 1855)
@@ -47,9 +47,6 @@
 import org.jboss.remoting.callback.HandleCallbackException;
 import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
 
-import EDU.oswego.cs.dl.util.concurrent.FIFOSemaphore;
-import EDU.oswego.cs.dl.util.concurrent.Sync;
-
 /**
  * Concrete implementation of ConsumerEndpoint.
  * 
@@ -221,6 +218,10 @@
            
          try
          {
+            //FIXME - when the latest remoting changes make it into a release, we need
+            //to use server side one way callbacks here.
+            //I.e. we want to sent the invocation to the transport on the this thread and 
+            //return immediately without waiting for a response.
             callbackHandler.handleCallback(callback);  
          }
          catch (HandleCallbackException e)

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-23 14:48:44 UTC (rev 1854)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-23 18:38:04 UTC (rev 1855)
@@ -96,16 +96,13 @@
    protected static final byte CANCEL = 3;
    protected static final byte CANCEL_LIST = 4;
    protected static final byte SEND = 5;   
-   //protected static final byte MORE = 6;
-   
-   protected static final byte CHANGE_RATE = 6;
-   
+   protected static final byte CHANGE_RATE = 6; 
    protected static final byte SEND_TRANSACTION = 7;
    protected static final byte GET_ID_BLOCK = 8;
    protected static final byte RECOVER_DELIVERIES = 9;
-   //protected static final byte CONFIRM_DELIVERY = 10;
+   protected static final byte CANCEL_INFLIGHT_MESSAGES = 10;
    
-   
+
  
 
    // The response codes - start from 100
@@ -367,7 +364,18 @@
    
                   if (trace) { log.trace("wrote getIdBlock()"); }
                }           
-               
+               else if ("cancelInflightMessages".equals(methodName))
+               {
+                  dos.writeByte(CANCEL_INFLIGHT_MESSAGES);
+                  
+                  writeHeader(mi, dos);
+                  
+                  long lastDeliveryId = ((Long)mi.getArguments()[0]).longValue();
+                  
+                  dos.writeLong(lastDeliveryId);
+                  
+                  dos.flush();
+               }
                else
                {
                   dos.write(SERIALIZED);
@@ -787,6 +795,26 @@
    
                return request;
             }
+            case CANCEL_INFLIGHT_MESSAGES:
+            {
+               MethodInvocation mi = readHeader(dis);
+               
+               long lastDeliveryId = dis.readLong();
+               
+               Object[] args = new Object[] {new Long(lastDeliveryId)};
+               
+               mi.setArguments(args);
+   
+               InvocationRequest request =
+                  new InvocationRequest(null, ServerPeer.REMOTING_JMS_SUBSYSTEM,
+                                        new MessagingMarshallable(version, mi), null, null, null);
+   
+               if (trace) { log.trace("read cancelInflightMessages()"); }
+   
+               return request;
+               
+               
+            }
             case ID_BLOCK_RESPONSE:
             {
                IDBlock block = new IDBlock();

Modified: trunk/tests/etc/log4j.xml
===================================================================
--- trunk/tests/etc/log4j.xml	2006-12-23 14:48:44 UTC (rev 1854)
+++ trunk/tests/etc/log4j.xml	2006-12-23 18:38:04 UTC (rev 1855)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
 
-<!-- $Id: log4j.xml 1184 2006-08-03 18:52:12Z ovidiu.feodorov at jboss.com $ -->
+<!-- $Id: log4j.xml 1019 2006-07-17 17:15:04Z timfox $ -->
 
 <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
 
@@ -14,8 +14,9 @@
           "crash-server", etc.
       -->
       <param name="File" value="${module.output}/logs/messaging-${test.logfile.suffix}.log"/>
+
       <param name="DatePattern" value="'.'yyyy-MM-dd"/>
-      <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/>
+      <param name="Threshold" value="INFO"/>
 
       <!-- since majority of the tests are ran in fork mode by ant, the log file is overwritten
            for each test. We need to append if we want to preserve a full testsuite run log.
@@ -24,7 +25,7 @@
       <param name="Append" value="true"/>
 
       <layout class="org.apache.log4j.PatternLayout">
-         <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p @%t [%c{1}] %m%n"/>
+         <param name="ConversionPattern" value="%d %-5r %-5p [%c] @%t %m%n"/>
       </layout>
    </appender>
 
@@ -32,9 +33,8 @@
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
       <param name="Target" value="System.out"/>
       <param name="Threshold" value="INFO"/>
-      <!-- <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/> -->
       <layout class="org.apache.log4j.PatternLayout">
-         <param name="ConversionPattern" value="@%t %d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
+         <param name="ConversionPattern" value="%t %d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
       </layout>
    </appender>
 
@@ -46,44 +46,10 @@
       <priority value="WARN"/>
    </category>
 
-   <category name="org.jboss.remoting">
-      <priority value="INFO"/>
-   </category>
-
    <category name="org.jboss">
       <priority value="INFO"/>
    </category>
 
-   <category name="org.jboss.messaging">
-      <priority value="TRACE" class="org.jboss.logging.XLevel"/>
-   </category>
-
-   <category name="org.jboss.jms">
-      <priority value="TRACE" class="org.jboss.logging.XLevel"/>
-   </category>
-
-   <category name="org.jboss.test">
-      <priority value="TRACE" class="org.jboss.logging.XLevel"/>
-   </category>
-
-   <!-- Ignoring trace from these: -->
-
-   <category name="org.jboss.jms.server.remoting.JMSServerInvocationHandler">
-      <priority value="DEBUG"/>
-   </category>
-
-   <category name="org.jboss.messaging.core.plugin.JDBCSupport">
-      <priority value="INFO"/>
-   </category>
-
-   <category name="org.jboss.test.messaging.tools.jmx.MockJBossSecurityManager">
-      <priority value="DEBUG"/>
-   </category>
-
-   <category name="org.jboss.jms.server.remoting.JMSWireFormat">
-      <priority value="DEBUG"/>
-   </category>
-
    <root>
       <appender-ref ref="CONSOLE"/>
       <appender-ref ref="FILE"/>

Modified: trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-23 14:48:44 UTC (rev 1854)
+++ trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-23 18:38:04 UTC (rev 1855)
@@ -99,12 +99,14 @@
    
    protected Method cancelDeliveryMethod;
    
-   protected Method cancelDeliveriesMethod;
+   protected Method cancelDeliveriesMethod;      
    
    //Consumer
         
    protected Method changeRateMethod;
    
+   protected Method cancelInflightMessagesMethod;
+   
  
    //connection
    
@@ -150,6 +152,8 @@
       //Consumer
             
       changeRateMethod = consumerDelegate.getMethod("changeRate", new Class[] { Float.TYPE });
+      
+      cancelInflightMessagesMethod = consumerDelegate.getMethod("cancelInflightMessages", new Class[] { Long.TYPE });
 
       //Connection
       
@@ -197,7 +201,12 @@
       wf.testChangeRate();
    }
    
+   public void testCancelInflightMessages() throws Exception
+   {
+      wf.testCancelInflightMessages();
+   }
    
+   
    //Connection
    
    public void testSendTransaction() throws Exception
@@ -680,7 +689,92 @@
          
       }  
       
+      public void testCancelInflightMessages() throws Exception
+      {
+         long methodHash = 6236354;
+         
+         int objectId = 543271;
+         
+         MethodInvocation mi = new MethodInvocation(null, methodHash, cancelInflightMessagesMethod, cancelInflightMessagesMethod, null);
+         
+         mi.getMetaData().addMetaData(Dispatcher.DISPATCHER, Dispatcher.OID, new Integer(objectId));   
+         
+         long lastDeliveryId = 765;
+         
+         Object[] args = new Object[] { new Long(lastDeliveryId) };
+         
+         mi.setArguments(args);
+         
+         MessagingMarshallable mm = new MessagingMarshallable((byte)77, mi);
+         
+         InvocationRequest ir = new InvocationRequest(null, null, mm, null, null, null);
+         
+         ByteArrayOutputStream bos = new ByteArrayOutputStream();
+         
+         OutputStream oos = new DataOutputStream(bos);
+                  
+         wf.write(ir, oos);
+         
+         oos.flush();
+         
+         byte[] bytes = bos.toByteArray();
+         
+         ByteArrayInputStream bis = new ByteArrayInputStream(bytes);
+                  
+         DataInputStream dis = new DataInputStream(bis); 
+                 
+         //Check the bytes
+         
+         //First byte should be version
+         assertEquals(77, dis.readByte());
+         
+         //First byte should be CANCEL
+         assertEquals(JMSWireFormat.CANCEL_INFLIGHT_MESSAGES, dis.readByte());
+         
+         //Next int should be objectId
+         assertEquals(objectId, dis.readInt());
+         
+         //Next long should be methodHash
+         assertEquals(methodHash, dis.readLong());
+         
+         //Next should be the lastdeliveryid
+         long l = dis.readLong();
+         
+         assertEquals(lastDeliveryId, l);
+         
+         //Now eos
+         try
+         {
+            dis.readByte();
+            fail("End of stream expected");
+         }
+         catch (EOFException e)
+         {
+            //Ok
+         }
+         
+         bis.reset();
+         
+         InputStream ois = new DataInputStream(bis);
+         
+         InvocationRequest ir2 = (InvocationRequest)wf.read(ois, null);
+         
+         mm = (MessagingMarshallable)ir2.getParameter();
+         
+         assertEquals(77, mm.getVersion());
+         
+         MethodInvocation mi2 = (MethodInvocation)mm.getLoad();
+         
+         assertEquals(methodHash, mi2.getMethodHash());
+         
+         assertEquals(objectId, ((Integer)mi2.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID)).intValue());
+         
+         Long l2 = (Long)mi2.getArguments()[0];
+         
+         assertEquals(lastDeliveryId, l2.longValue());
+      }
       
+      
       /*
        * Test that general serializable invocation requests are marshalled correctky
        */



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 13:39:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 13:39:27 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1856 - trunk/tests/etc
Message-ID: <E1GyBmJ-0007Do-JW@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-23 13:39:26 -0500 (Sat, 23 Dec 2006)
New Revision: 1856

Modified:
   trunk/tests/etc/log4j.xml
Log:
Replaced log4j.xml i just overwrote



Modified: trunk/tests/etc/log4j.xml
===================================================================
--- trunk/tests/etc/log4j.xml	2006-12-23 18:38:04 UTC (rev 1855)
+++ trunk/tests/etc/log4j.xml	2006-12-23 18:39:26 UTC (rev 1856)
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
 
-<!-- $Id: log4j.xml 1019 2006-07-17 17:15:04Z timfox $ -->
+<!-- $Id: log4j.xml 1184 2006-08-03 18:52:12Z ovidiu.feodorov at jboss.com $ -->
 
 <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/" debug="false">
 
@@ -14,9 +14,8 @@
           "crash-server", etc.
       -->
       <param name="File" value="${module.output}/logs/messaging-${test.logfile.suffix}.log"/>
-
       <param name="DatePattern" value="'.'yyyy-MM-dd"/>
-      <param name="Threshold" value="INFO"/>
+      <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/>
 
       <!-- since majority of the tests are ran in fork mode by ant, the log file is overwritten
            for each test. We need to append if we want to preserve a full testsuite run log.
@@ -25,7 +24,7 @@
       <param name="Append" value="true"/>
 
       <layout class="org.apache.log4j.PatternLayout">
-         <param name="ConversionPattern" value="%d %-5r %-5p [%c] @%t %m%n"/>
+         <param name="ConversionPattern" value="%d{ABSOLUTE} %-5p @%t [%c{1}] %m%n"/>
       </layout>
    </appender>
 
@@ -33,8 +32,9 @@
       <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler"/>
       <param name="Target" value="System.out"/>
       <param name="Threshold" value="INFO"/>
+      <!-- <param name="Threshold" value="TRACE#org.jboss.logging.XLevel"/> -->
       <layout class="org.apache.log4j.PatternLayout">
-         <param name="ConversionPattern" value="%t %d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
+         <param name="ConversionPattern" value="@%t %d{ABSOLUTE} %-5p [%c{1}] %m%n"/>
       </layout>
    </appender>
 
@@ -46,10 +46,44 @@
       <priority value="WARN"/>
    </category>
 
+   <category name="org.jboss.remoting">
+      <priority value="INFO"/>
+   </category>
+
    <category name="org.jboss">
       <priority value="INFO"/>
    </category>
 
+   <category name="org.jboss.messaging">
+      <priority value="TRACE" class="org.jboss.logging.XLevel"/>
+   </category>
+
+   <category name="org.jboss.jms">
+      <priority value="TRACE" class="org.jboss.logging.XLevel"/>
+   </category>
+
+   <category name="org.jboss.test">
+      <priority value="TRACE" class="org.jboss.logging.XLevel"/>
+   </category>
+
+   <!-- Ignoring trace from these: -->
+
+   <category name="org.jboss.jms.server.remoting.JMSServerInvocationHandler">
+      <priority value="DEBUG"/>
+   </category>
+
+   <category name="org.jboss.messaging.core.plugin.JDBCSupport">
+      <priority value="INFO"/>
+   </category>
+
+   <category name="org.jboss.test.messaging.tools.jmx.MockJBossSecurityManager">
+      <priority value="DEBUG"/>
+   </category>
+
+   <category name="org.jboss.jms.server.remoting.JMSWireFormat">
+      <priority value="DEBUG"/>
+   </category>
+
    <root>
       <appender-ref ref="CONSOLE"/>
       <appender-ref ref="FILE"/>



From fsduyrehdsfa9874 at Safe-mail.net  Sat Dec 23 13:52:39 2006
From: fsduyrehdsfa9874 at Safe-mail.net (fsduyrehdsfa9874 at Safe-mail.net)
Date: Sat, 23 Dec 2006 13:52:39 -0500
Subject: [jboss-cvs] =?utf-8?b?wpbCvsKTw7rCgsOGwpbCvsKMw6PCk8O6woLDjMKC?=
	=?utf-8?b?w4zCl1zCksOowoLDsMKLwrPCgsKmwoLDhMKCwq3CgsOqwoLDnMKCwrk=?=
	=?utf-8?b?woLDscKCwqnCgUg=?=
Message-ID: 20061224032206.89414mail@mail.bsusofausdjasdkasdlaskdjsakdmask.com

??????????????????????????????????????????????????????????????????????  
   
?@?@?@?@?@?@?@?@?@?@???Z???u???p?R?~?
?j?e?B???@

?????????????????????????????????????????????????????????????????????? 

?@?@?@?@?@?@?@ ?????????j???????l?????S?i?v????????????
              ?i?????????l?????????????????????????????j

?@?@?@?@?@?@?@?????S?I???S?I???t?[?A?h???X?????o?^???\??
???????????????????????????????????????????????????????????????????????? 

???????????R?R???????@http://completefree.freesexparty.ksjer.com/adultonly/

???????????????????Z???u???}?_?????o??????????????????????????????????

?????S?i?v???????????@http://completefree.freesexparty.ksjer.com/adultonly/

????????????????????????????????????????????????????????????????????????




From thomas.diesler at jboss.com  Sat Dec 23 15:46:43 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Sat, 23 Dec 2006 15:46:43 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jaxb/2.1 - New directory ...
Message-ID: <E1GyDlT-0001Rq-Cq@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/23 15:46:43

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/sun-jaxb/2.1 added to the repository


From thomas.diesler at jboss.com  Sat Dec 23 15:47:03 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Sat, 23 Dec 2006 15:47:03 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jaxb/2.1/lib - New directory ...
Message-ID: <E1GyDln-0001Sa-Eg@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/23 15:47:03

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/sun-jaxb/2.1/lib added to the repository


From thomas.diesler at jboss.com  Sat Dec 23 15:48:22 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Sat, 23 Dec 2006 15:48:22 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jaxb/2.1  ...
Message-ID: <E1GyDn4-0001St-4r@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/23 15:48:22

  Added:       sun-jaxb/2.1  component-info.xml
  Log:
  jaxb-2.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="sun-jaxb-component-info">
    
    <!-- ============================================================ -->
    <!-- JAXB 2.1                                                     -->
    <!-- ============================================================ -->
    
    <component 
      id="sun-jaxb" 
      version="2.1" 
      licenseType="cddl" 
      projectHome="https://jaxb.dev.java.net/" 
      description="The JAXB 2.0 implementation">
      
      <artifact id="jaxb-api.jar"/>
      <artifact id="jaxb-xjc.jar"/>
      <artifact id="jaxb-impl.jar"/>
      
      <export>
        <include input="jaxb-api.jar"/>
      </export>
    </component>
    
  </project>
  
  
  


From thomas.diesler at jboss.com  Sat Dec 23 15:48:22 2006
From: thomas.diesler at jboss.com (Thomas Diesler)
Date: Sat, 23 Dec 2006 15:48:22 -0500
Subject: [jboss-cvs] repository.jboss.com/sun-jaxb/2.1/lib         ...
Message-ID: <E1GyDn4-0001TD-CI@committer01.frg.pub.inap.atl.jboss.com>

  User: tdiesler
  Date: 06/12/23 15:48:22

  Added:       sun-jaxb/2.1/lib         jaxb-api-doc.zip jaxb-api-src.zip
                        jaxb-api.jar jaxb-impl.jar jaxb-impl.src.zip
                        jaxb-xjc.jar jaxb-xjc.src.zip jsr173_1.0_api.jar
  Log:
  jaxb-2.1
  
  Revision  Changes    Path
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-api-doc.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-api-src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-api.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-impl.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-impl.src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-xjc.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jaxb-xjc.src.zip
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/23 20:48:22;  author: tdiesler;  state: Exp;repository.jboss.com/sun-jaxb/2.1/lib/jsr173_1.0_api.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 15:55:15 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 15:55:15 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59216 - branches/Branch_4_2/build
Message-ID: <E1GyDtj-0001Z9-Hk@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-23 15:55:13 -0500 (Sat, 23 Dec 2006)
New Revision: 59216

Modified:
   branches/Branch_4_2/build/build-thirdparty.xml
Log:
install jaxb2.1

Modified: branches/Branch_4_2/build/build-thirdparty.xml
===================================================================
--- branches/Branch_4_2/build/build-thirdparty.xml	2006-12-22 23:45:12 UTC (rev 59215)
+++ branches/Branch_4_2/build/build-thirdparty.xml	2006-12-23 20:55:13 UTC (rev 59216)
@@ -1,139 +1,134 @@
 <?xml version="1.0"?>
 <!-- $Id$ -->
-<project name="main.build"
-          default="synchronize"
-          basedir=".">
-
-   <!-- Property File definitions -->
-   <property file="local.properties"/>
-   <property file="synchronize.properties"/>
-   <property environment="env"/>
-   <!-- Allow jbossbuild.repository to be set from (in order or priority)
-      + Command line -Djbossbuild.repository=...
-      + synchronize.properties jbossbuild.repository setting
-      + JBOSS_REPOSITORY environment variable (e.g. JBOSS_REPOSITORY=file:///d:/projects/repository.jboss.com/)
-   -->
-   <condition property="jbossbuild.repository" value="${env.JBOSS_REPOSITORY}">
-      <isset property="env.JBOSS_REPOSITORY"/>
-   </condition>
-   <!-- Fall back to default -->
-   <property name="jbossbuild.repository" value="http://repository.jboss.com"/>
-
-   <!-- Property Definitions -->
-   <property name="generatedLibrariesFiles" value="../thirdparty/libraries.ent"/>
-
-   <!-- File Imports -->
-   <import file="../tools/etc/jbossbuild/tasks.xml"/>
-
-   <!-- Proxy Configuration for HTTP get operations
-   <setproxy proxyhost="<your.proxy.host>" proxyport="<your.proxy.port>"/>
-   -->
-
-   <!-- Main Definition of dependencies -->
-   <build id="jbossas-thirdparty"
-      impltitle="JBossAS"
-      implversion="4.2.0"
-      implvendor="JBoss Inc."
-      implurl="http://www.jboss.org"
-      description="JBoss Application Server"
-      cvsroot="${cvs.prefix}@cvs.forge.jboss.com:/cvsroot/jboss"
-      thirdpartypath="../thirdparty/"
-      location="${jbossbuild.repository}"
-      targetdefs="targets">
-
-      <!--
-        The repository is in CVS under the module repository.jboss.com whose contents
-        are pushed to the http://repository.jboss.com site.
-      -->
-
-      <componentref name="antlr" version="2.7.6.ga"/>
-      <componentref name="apache-addressing" version="cvsbuild-7-19"/>
-      <componentref name="apache-avalon" version="4.1.5"/>
-      <componentref name="apache-avalon-logkit" version="1.2"/>
-      <componentref name="apache-bcel" version="5.1"/>
-      <componentref name="apache-beanutils" version="1.7.0"/>
-      <componentref name="apache-bsf" version="2.3.0"/>
-      <componentref name="apache-codec" version="1.3.0"/>
-      <componentref name="apache-collections" version="3.1"/>
-      <componentref name="apache-digester" version="1.6"/>
-      <componentref name="apache-discovery" version="0.2"/>
-      <componentref name="apache-fileupload" version="1.0"/>
-      <componentref name="apache-httpclient" version="3.0.1"/>
-      <componentref name="apache-jaxme" version="0.2-cvs"/>
-      <componentref name="apache-log4j" version="1.2.14"/>
-      <componentref name="apache-logging" version="1.1"/>
-      <componentref name="apache-myfaces" version="1.1.4"/>
-      <componentref name="apache-pool" version="1.0.1"/>
-      <componentref name="apache-scout" version="0.7rc2"/>
-      <componentref name="apache-slide" version="1.0.16"/>
-      <componentref name="apache-tomcat" version="5.5.20"/>
-      <componentref name="apache-velocity" version="1.4jboss"/>
-      <componentref name="apache-wss4j" version="cvs-7-19"/>
-      <componentref name="apache-xalan" version="j_2.7.0"/>
-      <componentref name="apache-xerces" version="2.7.1"/>
-      <componentref name="apache-xmlsec" version="1.3.0"/>
-      <componentref name="cglib" version="2.1.3.nodep"/>
-      <componentref name="beanshell" version="1.3.0"/>
-      <componentref name="dom4j" version="1.6.1"/>
-      <componentref name="gjt-jpl-util" version="1.0"/>
-      <componentref name="gnu-getopt" version="1.0.10"/>
-      <componentref name="hibernate" version="3.2.1.GA"/>
-      <componentref name="hibernate-annotations" version="3.2.1.GA"/>
-      <componentref name="hibernate-entitymanager" version="3.2.1.GA"/>
-      <componentref name="hsqldb" version="1.8.0.2"/>
-      <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
-      <componentref name="jacorb" version="2.2.4jboss.patch1"/>
-      <componentref name="javassist" version="3.4.GA"/>
-      <componentref name="jaxen" version="1.1-beta-9"/>
-      <componentref name="jboss/aop" version="1.5.3.beta1"/>
-      <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
-      <componentref name="jboss/cache" version="1.4.0.SP1"/>
-      <componentref name="jboss/common" version="1.0.0.GA"/>
-      <componentref name="jboss/dom4j-jarjar" version="1.6.1"/>
-      <componentref name="jboss/jbossretro-rt" version="1.0.4.GA"/>
-      <!--<componentref name="jboss/jbossts" version="4.2.2.GA"/>-->
-      <componentref name="jboss/jbossws" version="1.0.4.GA"/>
-      <componentref name="jboss/jbossws14" version="1.0.4.GA"/>
-      <componentref name="jboss/jboss-ws4ee" version="4.0.4.SP1"/>
-      <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
-      <componentref name="jboss/microcontainer" version="1.0.2"/>
-      <componentref name="jboss/remoting" version="1.4.5.GA"/>
-      <componentref name="jboss/serialization" version="1.0.3.GA"/>
-      <componentref name="jfreechart" version="0.9.20"/>
-      <componentref name="jgroups" version="2.4.1"/>
-      <componentref name="joesnmp" version="0.3.4"/>
-      <componentref name="juddi" version="0.9RC4"/>
-      <componentref name="junit" version="3.8.1"/>
-      <componentref name="junitejb" version="1.4"/>
-      <componentref name="objectweb-joramtests" version="1.1"/>
-      <componentref name="odmg" version="3.0"/>
-      <componentref name="oswego-concurrent" version="1.3.4"/>
-      <componentref name="quartz" version="1.5.2"/>
-      <componentref name="qdox" version="1.4"/>
-      <componentref name="sleepycat" version="1.5.2"/>
-      <componentref name="sun-jaf" version="1.1"/>
-      <componentref name="sun-javacc" version="3.2"/>
-      <componentref name="sun-javamail" version="1.4"/>
-      <componentref name="sun-servlet" version="2.4"/>
-      <componentref name="trove" version="1.0.2"/>
-      <componentref name="wutka-dtdparser" version="1.2.1"/>
-      <componentref name="xdoclet" version="1.2b3"/>
-      <componentref name="xml-sax" version="2.0.x"/>
-
-    </build>
-
-   <synchronizeinfo/>
-
-   <!-- Generate the targets -->
-   <generate generate="jbossas-thirdparty"/>
-
-
-   <target name="generate-lib-file"
-      description="generate libraries.ent and thirdparty license info"
-      depends="synchronize">
-         <gen-lib-file filename="${generatedLibrariesFiles}" />
-      <visit-componentref-graph
-         componentVisitor="org.jboss.ant.util.graph.ComponentRefGraphLicenseVisitor" />
-   </target>
-
+<project name="main.build" default="synchronize" basedir=".">
+  
+  <!-- Property File definitions -->
+  <property file="local.properties"/>
+  <property file="synchronize.properties"/>
+  <property environment="env"/>
+  
+  <!-- Allow jbossbuild.repository to be set from (in order or priority)
+  + Command line -Djbossbuild.repository=...
+  + synchronize.properties jbossbuild.repository setting
+  + JBOSS_REPOSITORY environment variable (e.g. JBOSS_REPOSITORY=file:///d:/projects/repository.jboss.com/)
+  -->
+  <condition property="jbossbuild.repository" value="${env.JBOSS_REPOSITORY}">
+    <isset property="env.JBOSS_REPOSITORY"/>
+  </condition>
+  <!-- Fall back to default -->
+  <property name="jbossbuild.repository" value="http://repository.jboss.com"/>
+  
+  <!-- Property Definitions -->
+  <property name="generatedLibrariesFiles" value="../thirdparty/libraries.ent"/>
+  
+  <!-- File Imports -->
+  <import file="../tools/etc/jbossbuild/tasks.xml"/>
+  
+  <!-- Proxy Configuration for HTTP get operations
+  <setproxy proxyhost="<your.proxy.host>" proxyport="<your.proxy.port>"/>
+  -->
+  
+  <!-- Main Definition of dependencies -->
+  <build 
+    id="jbossas-thirdparty" 
+    impltitle="JBossAS" 
+    implversion="4.2.0" 
+    implvendor="JBoss Inc." 
+    implurl="http://www.jboss.org" 
+    description="JBoss Application Server"
+    cvsroot="${cvs.prefix}@cvs.forge.jboss.com:/cvsroot/jboss" 
+    thirdpartypath="../thirdparty/" 
+    location="${jbossbuild.repository}" 
+    targetdefs="targets">
+    
+    <!--
+    The repository is in CVS under the module repository.jboss.com whose contents
+    are pushed to the http://repository.jboss.com site.
+    -->
+    
+    <componentref name="antlr" version="2.7.6.ga"/>
+    <componentref name="apache-addressing" version="cvsbuild-7-19"/>
+    <componentref name="apache-avalon" version="4.1.5"/>
+    <componentref name="apache-avalon-logkit" version="1.2"/>
+    <componentref name="apache-bcel" version="5.1"/>
+    <componentref name="apache-beanutils" version="1.7.0"/>
+    <componentref name="apache-bsf" version="2.3.0"/>
+    <componentref name="apache-codec" version="1.3.0"/>
+    <componentref name="apache-collections" version="3.1"/>
+    <componentref name="apache-digester" version="1.6"/>
+    <componentref name="apache-discovery" version="0.2"/>
+    <componentref name="apache-fileupload" version="1.0"/>
+    <componentref name="apache-httpclient" version="3.0.1"/>
+    <componentref name="apache-jaxme" version="0.2-cvs"/>
+    <componentref name="apache-log4j" version="1.2.14"/>
+    <componentref name="apache-logging" version="1.1"/>
+    <componentref name="apache-myfaces" version="1.1.4"/>
+    <componentref name="apache-pool" version="1.0.1"/>
+    <componentref name="apache-scout" version="0.7rc2"/>
+    <componentref name="apache-slide" version="1.0.16"/>
+    <componentref name="apache-tomcat" version="5.5.20"/>
+    <componentref name="apache-velocity" version="1.4jboss"/>
+    <componentref name="apache-wss4j" version="cvs-7-19"/>
+    <componentref name="apache-xalan" version="j_2.7.0"/>
+    <componentref name="apache-xerces" version="2.7.1"/>
+    <componentref name="apache-xmlsec" version="1.3.0"/>
+    <componentref name="cglib" version="2.1.3.nodep"/>
+    <componentref name="beanshell" version="1.3.0"/>
+    <componentref name="dom4j" version="1.6.1"/>
+    <componentref name="gjt-jpl-util" version="1.0"/>
+    <componentref name="gnu-getopt" version="1.0.10"/>
+    <componentref name="hibernate" version="3.2.1.GA"/>
+    <componentref name="hibernate-annotations" version="3.2.1.GA"/>
+    <componentref name="hibernate-entitymanager" version="3.2.1.GA"/>
+    <componentref name="hsqldb" version="1.8.0.2"/>
+    <componentref name="ibm-wsdl4j" version="1.5.2jboss"/>
+    <componentref name="jacorb" version="2.2.4jboss.patch1"/>
+    <componentref name="javassist" version="3.4.GA"/>
+    <componentref name="jaxen" version="1.1-beta-9"/>
+    <componentref name="jboss/aop" version="1.5.3.beta1"/>
+    <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
+    <componentref name="jboss/cache" version="1.4.0.SP1"/>
+    <componentref name="jboss/common" version="1.0.0.GA"/>
+    <componentref name="jboss/dom4j-jarjar" version="1.6.1"/>
+    <componentref name="jboss/jbossretro-rt" version="1.0.4.GA"/>
+    <!--<componentref name="jboss/jbossts" version="4.2.2.GA"/>-->
+    <componentref name="jboss/jbossws" version="1.0.4.GA"/>
+    <componentref name="jboss/jbossxb" version="1.0.0.CR7"/>
+    <componentref name="jboss/microcontainer" version="1.0.2"/>
+    <componentref name="jboss/remoting" version="1.4.5.GA"/>
+    <componentref name="jboss/serialization" version="1.0.3.GA"/>
+    <componentref name="jfreechart" version="0.9.20"/>
+    <componentref name="jgroups" version="2.4.1"/>
+    <componentref name="joesnmp" version="0.3.4"/>
+    <componentref name="juddi" version="0.9RC4"/>
+    <componentref name="junit" version="3.8.1"/>
+    <componentref name="junitejb" version="1.4"/>
+    <componentref name="objectweb-joramtests" version="1.1"/>
+    <componentref name="odmg" version="3.0"/>
+    <componentref name="oswego-concurrent" version="1.3.4"/>
+    <componentref name="quartz" version="1.5.2"/>
+    <componentref name="qdox" version="1.4"/>
+    <componentref name="sleepycat" version="1.5.2"/>
+    <componentref name="sun-jaf" version="1.1"/>
+    <componentref name="sun-javacc" version="3.2"/>
+    <componentref name="sun-javamail" version="1.4"/>
+    <componentref name="sun-jaxb" version="2.0.3"/>
+    <componentref name="sun-servlet" version="2.4"/>
+    <componentref name="trove" version="1.0.2"/>
+    <componentref name="wutka-dtdparser" version="1.2.1"/>
+    <componentref name="xdoclet" version="1.2b3"/>
+    <componentref name="xml-sax" version="2.0.x"/>
+    
+  </build>
+  
+  <synchronizeinfo/>
+  
+  <!-- Generate the targets -->
+  <generate generate="jbossas-thirdparty"/>
+  
+  <target name="generate-lib-file" description="generate libraries.ent and thirdparty license info" depends="synchronize">
+    <gen-lib-file filename="${generatedLibrariesFiles}"/>
+    <visit-componentref-graph componentVisitor="org.jboss.ant.util.graph.ComponentRefGraphLicenseVisitor"/>
+  </target>
+  
 </project>



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 15:56:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 15:56:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59217 - in branches/Branch_4_2: . build
	j2ee server testsuite varia
Message-ID: <E1GyDuo-0001b6-De@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-23 15:56:17 -0500 (Sat, 23 Dec 2006)
New Revision: 59217

Removed:
   branches/Branch_4_2/webservice/
Modified:
   branches/Branch_4_2/build/build-distr.xml
   branches/Branch_4_2/build/build.xml
   branches/Branch_4_2/j2ee/build.xml
   branches/Branch_4_2/server/build.xml
   branches/Branch_4_2/testsuite/build.xml
   branches/Branch_4_2/varia/build.xml
Log:
remove jbossws14

Modified: branches/Branch_4_2/build/build-distr.xml
===================================================================
--- branches/Branch_4_2/build/build-distr.xml	2006-12-23 20:55:13 UTC (rev 59216)
+++ branches/Branch_4_2/build/build-distr.xml	2006-12-23 20:56:17 UTC (rev 59217)
@@ -1407,6 +1407,10 @@
       <fileset dir="${sun.jaf.lib}">
         <include name="activation.jar"/>
       </fileset>
+      <fileset dir="${sun.jaxb.lib}">
+        <include name="jaxb-api.jar"/>
+        <include name="jaxb-impl.jar"/>
+      </fileset>
       <fileset dir="${apache.logging.lib}">
         <include name="commons-logging.jar"/>
       </fileset>
@@ -1438,8 +1442,8 @@
       <fileset dir="${jboss.jbossxb.lib}">
         <include name="jboss-xml-binding.jar"/>
       </fileset>
-      <fileset dir="${jboss.jbossws14.lib}">
-        <include name="jbossws14-client.jar"/>
+      <fileset dir="${jboss.jbossws.lib}">
+        <include name="jbossws-client.jar"/>
         <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-saaj.jar"/>
       </fileset>
@@ -1469,7 +1473,7 @@
       <fileset dir="${jboss.jbossretro.rt.lib}">
         <include name="jbossretro-rt.jar"/>
       </fileset>
-      <fileset dir="${jboss.jbossws14.lib}">
+      <fileset dir="${jboss.jbossws.lib}">
         <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-saaj.jar"/>
       </fileset>
@@ -1502,7 +1506,7 @@
 
     <!-- install thirdparty items to install/bin -->
     <!-- install wstools shell scripts -->
-    <unjar dest="${install.bin}" src="${jboss.jbossws14.lib}/jbossws14-client.jar">
+    <unjar dest="${install.bin}" src="${jboss.jbossws.lib}/jbossws-client.jar">
       <patternset>
         <include name="wstools.*"/>
       </patternset>
@@ -1510,8 +1514,8 @@
 
     <!-- create deployments from thirdparty items -->
     <!-- copy the jbossws14.sar -->
-    <mkdir dir="${install.all.deploy}/jbossws14.sar"/>
-    <unjar dest="${install.all.deploy}/jbossws14.sar" src="${jboss.jbossws14.lib}/jbossws14.sar"/>
+    <mkdir dir="${install.all.deploy}/jbossws.sar"/>
+    <unjar dest="${install.all.deploy}/jbossws.sar" src="${jboss.jbossws.lib}/jbossws.sar"/>
   </target>
 
 
@@ -1529,7 +1533,7 @@
            <include name="bin/**" />
            <include name="client/**" />
            <exclude name="client/jboss-backport-concurrent.jar" />
-           <exclude name="client/jbossws14-client.jar" />
+           <exclude name="client/jbossws-client.jar" />
            <exclude name="client/jbossretro-rt.jar" />
            <exclude name="client/namespace.jar" />
            <include name="lib/**" />
@@ -1600,7 +1604,7 @@
         <fileset dir="${install.root}/server/default">
            <include name="conf/**" />
            <include name="deploy/**" />
-           <exclude name="deploy/jbossws14.sar/**" />
+           <exclude name="deploy/jbossws.sar/**" />
            <include name="lib/**" />
         </fileset>
      </copy>
@@ -1609,7 +1613,7 @@
         <fileset dir="${install.root}/server/all">
            <include name="conf/**" />
            <include name="deploy/**" />
-           <exclude name="deploy/jbossws14.sar/**" />
+           <exclude name="deploy/jbossws.sar/**" />
            <include name="deploy-hasingleton/**" />
            <include name="farm/**" />
            <include name="lib/**" />

Modified: branches/Branch_4_2/build/build.xml
===================================================================
--- branches/Branch_4_2/build/build.xml	2006-12-23 20:55:13 UTC (rev 59216)
+++ branches/Branch_4_2/build/build.xml	2006-12-23 20:56:17 UTC (rev 59217)
@@ -717,9 +717,7 @@
         <include name="hibernate-annotations.jar"/>
         <include name="jboss-deployment.jar" />
         <include name="jboss-j2ee.jar"/>
-        <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-remoting.jar"/>
-        <include name="jboss-saaj.jar"/>
         <include name="jboss-serialization.jar"/>
         <include name="jboss-xml-binding.jar"/>
         <include name="jbossmqha.jar"/>
@@ -727,7 +725,6 @@
         <include name="namespace.jar"/>
         <include name="wsdl4j.jar"/>
         <include name="xmlsec.jar"/>
-        <exclude name="jbossws14-client.jar"/>
         <exclude name="jbossws-client.jar"/>
       </srcfiles>
     </uptodate>
@@ -750,19 +747,15 @@
         <include name="hibernate-annotations.jar"/>
         <include name="jboss-deployment.jar" />
         <include name="jboss-j2ee.jar"/>
-        <include name="jboss-jaxrpc.jar"/>
         <include name="jboss-remoting.jar"/>
-        <include name="jboss-saaj.jar"/>
         <include name="jboss-serialization.jar"/>
-	<!-- Do not include jboss-xml-binding. Otherwise jbossws cannot be a drop in replacement.
-        <include name="jboss-xml-binding.jar"/> 
-	-->
+        <!-- Do not include jboss-xml-binding. Otherwise jbossws cannot be a drop in replacement.
+        <include name="jboss-xml-binding.jar"/--> 
         <include name="jbossmqha.jar"/>
         <include name="jmx-connector-client-factory.jar"/>
         <include name="namespace.jar"/>
         <include name="wsdl4j.jar"/>
         <include name="xmlsec.jar"/>
-        <exclude name="jbossws14-client.jar"/>
         <exclude name="jbossws-client.jar"/>
       </fileset>
     </unjar>

Modified: branches/Branch_4_2/j2ee/build.xml
===================================================================
--- branches/Branch_4_2/j2ee/build.xml	2006-12-23 20:55:13 UTC (rev 59216)
+++ branches/Branch_4_2/j2ee/build.xml	2006-12-23 20:56:17 UTC (rev 59217)
@@ -77,7 +77,7 @@
       <path refid="sun.jaf.classpath"/>
       <path refid="sun.servlet.classpath"/>
       <path refid="apache.xerces.classpath"/>
-      <path refid="jboss.jbossws14.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
     </path>
 
     <!-- ======= -->

Modified: branches/Branch_4_2/server/build.xml
===================================================================
--- branches/Branch_4_2/server/build.xml	2006-12-23 20:55:13 UTC (rev 59216)
+++ branches/Branch_4_2/server/build.xml	2006-12-23 20:56:17 UTC (rev 59217)
@@ -81,7 +81,7 @@
       <path refid="gjt.jpl-util.classpath"/>
       <path refid="gnu.getopt.classpath"/>
       <path refid="ibm.wsdl4j.classpath"/>
-      <path refid="jboss.jbossws14.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
       <path refid="junit.junit.classpath"/>
       <path refid="oswego.concurrent.classpath"/>

Modified: branches/Branch_4_2/testsuite/build.xml
===================================================================
--- branches/Branch_4_2/testsuite/build.xml	2006-12-23 20:55:13 UTC (rev 59216)
+++ branches/Branch_4_2/testsuite/build.xml	2006-12-23 20:56:17 UTC (rev 59217)
@@ -104,6 +104,7 @@
     <path refid="jboss.remoting.classpath"/>
     <path refid="jboss.jbossretro.rt.classpath"/>
     <path refid="jboss.backport.concurrent.classpath"/>
+    <path refid="jboss.jbossws.classpath"/>
     <path refid="jgroups.jgroups.classpath"/>
     <path refid="joesnmp.joesnmp.classpath"/>
     <path refid="junit.junit.classpath"/>
@@ -202,39 +203,6 @@
   <property name="release.id" value="${install.id}"/>
   <property name="install.root" value="${module.output}/${install.id}"/>
   
-  <!-- Set classpath for the webservice stack depending on ${jboss.dist.name} and client jar -->
-  <property name="jboss.dist.name" value="jboss-${version.major}.${version.minor}.${version.revision}.${version.tag}"/>
-  <property name="jboss.home" value="${module.root}/../build/output/${jboss.dist.name}"/>
-  <available property="jboss-ws4ee.available" file="${jboss.home}/client/jboss-ws4ee-client.jar"/>
-  <condition property="webservice.classpath" value="jboss-ws4ee.classpath">
-    <isset property="jboss-ws4ee.available"/>
-  </condition>
-  <condition property="webservice.classpath" value="jbossws14.classpath">
-    <not>
-      <isset property="HAVE_JDK_1.5"/>
-    </not>
-  </condition>
-  <condition property="webservice.classpath" value="jbossws.classpath">
-    <isset property="HAVE_JDK_1.5"/>
-  </condition>
-  <path id="jboss-ws4ee.classpath">
-    <pathelement path="${jboss/jboss.ws4ee.lib}/jboss-ws4ee-client.jar"/>
-    <pathelement path="${jboss/jboss.ws4ee.lib}/axis-ws4ee.jar"/>
-    <pathelement path="${jboss.jbossws14.lib}/jboss-jaxrpc.jar"/>
-    <pathelement path="${jboss.jbossws14.lib}/jboss-saaj.jar"/>
-  </path>
-  <path id="jbossws14.classpath">
-    <pathelement path="${jboss.jbossws14.lib}/jbossws14-client.jar"/>
-    <pathelement path="${jboss.jbossws14.lib}/jboss-jaxrpc.jar"/>
-    <pathelement path="${jboss.jbossws14.lib}/jboss-saaj.jar"/>
-  </path>
-  <path id="jbossws.classpath">
-    <pathelement path="${jboss.jbossws.lib}/jbossws-client.jar"/>
-    <pathelement path="${jboss.jbossws14.lib}/jboss-jaxrpc.jar"/>
-    <pathelement path="${jboss.jbossws14.lib}/jboss-saaj.jar"/>
-  </path>
-  <path id="webservice.classpath" refid="${webservice.classpath}"/>
-  
   <!-- classpath and local.classpath must have a value using with a path -->
   <property name="classpath" value=""/>
   <property name="local.classpath" value=""/>
@@ -243,7 +211,6 @@
   <path id="thirdparty.classpath">
     <path refid="library.classpath"/>
     <path refid="dependentmodule.classpath"/>
-    <path refid="webservice.classpath"/>
   </path>
   
   <!-- Classpath to build and run the tests -->
@@ -1638,7 +1605,7 @@
         <include name="deploy/hsqldb-ds.xml"/>
         <include name="deploy/jbossweb*.sar/**"/>
         <include name="deploy/jbossws.sar/**"/>
-        <include name="deploy/jbossws14.sar/**"/>
+        <include name="deploy/jbossws.sar/**"/>
         <include name="deploy/client-deployer-service.xml"/>
         <include name="deploy/ear-deployer.xml"/>
         <include name="deploy/ejb-deployer.xml"/>
@@ -1681,7 +1648,7 @@
         <include name="deploy/hsqldb-ds.xml"/>
         <include name="deploy/jbossweb*.sar/**"/>
         <include name="deploy/jbossws.sar/**"/>
-        <include name="deploy/jbossws14.sar/**"/>
+        <include name="deploy/jbossws.sar/**"/>
         <include name="deploy/client-deployer-service.xml"/>
         <include name="deploy/ear-deployer.xml"/>
         <include name="deploy/ejb-deployer.xml"/>
@@ -1744,7 +1711,7 @@
         <include name="deploy/hsqldb-ds.xml"/>
         <include name="deploy/jbossweb*.sar/**"/>
         <include name="deploy/jbossws.sar/**"/>
-        <include name="deploy/jbossws14.sar/**"/>
+        <include name="deploy/jbossws.sar/**"/>
         <include name="deploy/client-deployer-service.xml"/>
         <include name="deploy/ear-deployer.xml"/>
         <include name="deploy/ejb-deployer.xml"/>
@@ -1824,7 +1791,6 @@
         <include name="deploy/hsqldb-ds.xml"/>
         <include name="deploy/jbossweb*.sar/**"/>
         <include name="deploy/jbossws.sar/**"/>
-        <include name="deploy/jbossws14.sar/**"/>
         <include name="deploy/client-deployer-service.xml"/>
         <include name="deploy/ear-deployer.xml"/>
         <include name="deploy/ejb-deployer.xml"/>

Modified: branches/Branch_4_2/varia/build.xml
===================================================================
--- branches/Branch_4_2/varia/build.xml	2006-12-23 20:55:13 UTC (rev 59216)
+++ branches/Branch_4_2/varia/build.xml	2006-12-23 20:56:17 UTC (rev 59217)
@@ -83,7 +83,7 @@
       <path refid="beanshell.beanshell.classpath"/>
       <path refid="hsqldb.hsqldb.classpath"/>
       <path refid="jboss.microcontainer.classpath"/>
-      <path refid="jboss.jbossws14.classpath"/>
+      <path refid="jboss.jbossws.classpath"/>
       <path refid="jboss.jbossxb.classpath"/>
       <path refid="juddi.juddi.classpath"/>
       <path refid="junit.junit.classpath"/>



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 16:52:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 16:52:35 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1857 - trunk/tests
Message-ID: <E1GyEnD-0002cE-3r@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-23 16:52:31 -0500 (Sat, 23 Dec 2006)
New Revision: 1857

Modified:
   trunk/tests/build.xml
Log:
Change transport for stress tests back to socket



Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-23 18:39:26 UTC (rev 1856)
+++ trunk/tests/build.xml	2006-12-23 21:52:31 UTC (rev 1857)
@@ -366,7 +366,7 @@
       <antcall target="invm-stress-tests"/>
       <antcall target="remote-stress-tests"/>  <!-- default remoting configuration (socket) -->
       <antcall target="remote-stress-tests">
-         <param name="test.remoting" value="http"/>
+         <param name="test.remoting" value="socket"/>
       </antcall>
    </target>
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 17:55:17 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 17:55:17 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1858 - trunk/tests
Message-ID: <E1GyFlt-0003gs-DZ@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-23 17:55:15 -0500 (Sat, 23 Dec 2006)
New Revision: 1858

Modified:
   trunk/tests/build.xml
Log:
duh! put http back in



Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-23 21:52:31 UTC (rev 1857)
+++ trunk/tests/build.xml	2006-12-23 22:55:15 UTC (rev 1858)
@@ -366,7 +366,7 @@
       <antcall target="invm-stress-tests"/>
       <antcall target="remote-stress-tests"/>  <!-- default remoting configuration (socket) -->
       <antcall target="remote-stress-tests">
-         <param name="test.remoting" value="socket"/>
+         <param name="test.remoting" value="http"/>
       </antcall>
    </target>
 



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 18:27:50 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 18:27:50 -0500
Subject: [jboss-cvs] JBossAS SVN: r59218 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array main/org/jboss/aop/instrument
	resources/test/array test/org/jboss/test/aop/array
Message-ID: <E1GyGHO-0004Rq-RQ@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-23 18:27:35 -0500 (Sat, 23 Dec 2006)
New Revision: 59218

Added:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak
Removed:
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java
Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/NonOptimizedFieldAccessTransformer.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/OptimizedFieldAccessTransformer.java
   projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
Log:
Get array interception sorking for int arrays and basics for multidim arrays

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.aop.array;
 
+import org.jboss.aop.advice.Interceptor;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -28,6 +30,8 @@
  */
 public class ArrayAdvisor
 {
+   //TODO Make configurable
+   static Interceptor[] interceptors = new Interceptor[] {new TestArrayElementInterceptor()};
    public static Object array;
    public static String value;
    public static int index;
@@ -39,118 +43,157 @@
       index = -1;
    }
    
-   private static void recordAccess(Object array, int index, String value)
+   public static void updateArrayField(Object target, String fieldName, Object oldValue, Object newValue)
    {
-      System.out.println("Accessing array");
-      ArrayAdvisor.array = array;
-      ArrayAdvisor.index = index;
-      ArrayAdvisor.value = value;
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      registry.removeFieldReference(target, fieldName, oldValue);
+      registry.addFieldReference(target, fieldName, newValue);
    }
    
    //Write operations
-   public static void arrayWrite(boolean[] array, int index, boolean value)
+//   public static void arrayWrite(boolean[] array, int index, boolean value)
+//   {
+//      array[index] = value; 
+//   }
+//
+//   public static void arrayWrite(short[] array, int index, short value)
+//   {
+//      array[index] = value; 
+//   }
+//
+   public static void arrayWriteInt(Object array, int index, int value) throws Throwable
    {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         System.out.println("---------> Writing" + array + " advised");
+         IntArrayElementWriteInvocation invocation = new IntArrayElementWriteInvocation(interceptors, ((int[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((int[])array)[index] = value;
+      }
    }
 
-   public static void arrayWrite(short[] array, int index, short value)
+   public static void arrayWriteObject(Object array, int index, Object value) throws Throwable
    {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      if (registry.isRegistered(array))
+      {
+         System.out.println("---------> Writing" + array + " advised");
+         
+         if (value.getClass().isArray())
+         {
+            Object oldValue = ((Object[])array)[index];
+            registry.removeElementReference(array, index, oldValue);
+            registry.addElementReference(array, index, value);
+         
+         }
+         ObjectArrayElementWriteInvocation invocation = new ObjectArrayElementWriteInvocation(interceptors, (Object[])array, index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         System.out.println("---------> Writing" + array + " not advised");
+         ((Object[])array)[index] = value;
+      }
    }
-
-   public static void arrayWrite(int[] array, int index, int value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
    
-   public static void arrayWrite(long[] array, int index, long value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(float[] array, int index, float value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(double[] array, int index, double value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(char[] array, int index, char value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(Object[] array, int index, Object value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
+//   
+//   public static void arrayWrite(long[] array, int index, long value)
+//   {
+//      array[index] = value; 
+//   }
+//   
+//   public static void arrayWrite(float[] array, int index, float value)
+//   {
+//      array[index] = value; 
+//   }
+//   
+//   public static void arrayWrite(double[] array, int index, double value)
+//   {
+//      array[index] = value; 
+//   }
+//   
+//   public static void arrayWrite(char[] array, int index, char value)
+//   {
+//      array[index] = value; 
+//   }
+//   
+//   public static void arrayWrite(Object[] array, int index, Object value)
+//   {
+//      array[index] = value; 
+//   }
 
    //Read operations
-   public static boolean arrayRead(boolean[] array, int index)
+//   public static boolean arrayRead(boolean[] array, int index)
+//   {
+//      
+//      boolean value = array[index];
+//      return value;
+//   }
+//
+//   public static short arrayRead(short[] array, int index)
+//   {
+//      short value = array[index];
+//      return value;
+//   }
+//
+   public static int arrayReadInt(Object array, int index) throws Throwable
    {
-      
-      boolean value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         IntArrayElementReadInvocation invocation = new IntArrayElementReadInvocation(interceptors, (int[])array, index);
+         return ((Integer)invocation.invokeNext()).intValue();
+      }
+      else
+      {
+         return ((int[])array)[index];
+      }
    }
 
-   public static short arrayRead(short[] array, int index)
+   public static Object arrayReadObject(Object array, int index) throws Throwable
    {
-      short value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         ObjectArrayElementReadInvocation invocation = new ObjectArrayElementReadInvocation(interceptors, (Object[])array, index);
+         return invocation.invokeNext();
+      }
+      else
+      {
+         return ((Object[])array)[index];
+      }
    }
 
-   public static int arrayRead(int[] array, int index)
-   {
-      int value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static long arrayRead(long[] array, int index)
-   {
-      long value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static float arrayRead(float[] array, int index)
-   {
-      float value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static double arrayRead(double[] array, int index)
-   {
-      double value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static char arrayRead(char[] array, int index)
-   {
-      char value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static Object arrayRead(Object[] array, int index)
-   {
-      Object value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
+//   
+//   public static long arrayRead(long[] array, int index)
+//   {
+//      long value = array[index];
+//      return value;
+//   }
+//   
+//   public static float arrayRead(float[] array, int index)
+//   {
+//      float value = array[index];
+//      return value;
+//   }
+//   
+//   public static double arrayRead(double[] array, int index)
+//   {
+//      double value = array[index];
+//      return value;
+//   }
+//   
+//   public static char arrayRead(char[] array, int index)
+//   {
+//      char value = array[index];
+//      return value;
+//   }
+//   
+//   public static Object arrayRead(Object[] array, int index)
+//   {
+//      Object value = array[index];
+//      return value;
+//   }
+
 }

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,167 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import java.util.Map;
+
+import org.jboss.aop.Advisor;
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.InvocationBase;
+import org.jboss.aop.metadata.MetaDataResolver;
+import org.jboss.util.NotImplementedException;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ArrayElementInvocation extends InvocationBase
+{
+   int index;
+   
+   public ArrayElementInvocation(Interceptor[] interceptors, Object array, int index)
+   {
+      // FIXME ArrayElementInvocation constructor
+      super(interceptors);
+      super.setTargetObject(array);
+      this.index = index;
+   }
+
+   public int getIndex()
+   {
+      return index;
+   }
+   /**
+    * Invoke on the next interceptor in the chain.  If this is already
+    * the end of the chain, reflection will call the constructor, field, or
+    * method you are invoking on.
+    */
+   public Object invokeNext() throws Throwable
+   {
+      if (interceptors != null && currentInterceptor < interceptors.length)
+      {
+         try
+         {
+            return interceptors[currentInterceptor++].invoke(this);
+         }
+         finally
+         {
+            // so that interceptors like clustering can reinvoke down the chain
+            currentInterceptor--;
+         }
+      }
+
+      return invokeTarget();
+   }
+
+   public abstract Object invokeTarget();
+
+
+   @Override
+   public void addResponseAttachment(Object key, Object val)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Advisor getAdvisor()
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public int getCurrentInterceptor()
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public MetaDataResolver getInstanceResolver()
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Object getResponseAttachment(Object key)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Map getResponseContextInfo()
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Object resolveAnnotation(Class annotation)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Object resolveAnnotation(Class[] annotations)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Object resolveClassAnnotation(Class annotation)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public Object resolveClassMetaData(Object key, Object attr)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public void setAdvisor(Advisor advisor)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public void setInstanceResolver(MetaDataResolver instanceResolver)
+   {
+      throw new NotImplementedException();
+   }
+
+   @Override
+   public void setResponseContextInfo(Map responseContextInfo)
+   {
+      throw new NotImplementedException();
+   }
+
+   public Invocation copy()
+   {
+      throw new NotImplementedException();
+   }
+
+   public Invocation getWrapper(Interceptor[] newchain)
+   {
+      throw new NotImplementedException();
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementReadInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementReadInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,38 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ArrayElementReadInvocation extends ArrayElementInvocation
+{
+   public ArrayElementReadInvocation(Interceptor[] interceptors, Object array, int index)
+   {
+      // FIXME ArrayElementReadInvocation constructor
+      super(interceptors, array, index);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementWriteInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementWriteInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,39 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ArrayElementWriteInvocation extends ArrayElementInvocation
+{
+   public ArrayElementWriteInvocation(Interceptor[] interceptors, Object array, int index)
+   {
+      super(interceptors, array, index);
+   }
+
+   public abstract Object getValue();
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,254 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import java.util.HashSet;
+import java.util.Set;
+import java.util.WeakHashMap;
+import java.util.concurrent.locks.Lock;
+import java.util.concurrent.locks.ReadWriteLock;
+import java.util.concurrent.locks.ReentrantReadWriteLock;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayRegistry
+{
+   private static ArrayRegistry singleton = new ArrayRegistry();
+   private ReadWriteLock lock = new ReentrantReadWriteLock();
+   private WeakHashMap<Object, WeakHashMap<Object, ArrayRegistryEntry>> cache = new WeakHashMap<Object, WeakHashMap<Object, ArrayRegistryEntry>>();
+   
+   public static ArrayRegistry getInstance()
+   {
+      return singleton;
+   }
+   
+   private ArrayRegistry()
+   {
+      
+   }
+   
+   public void addFieldReference(Object owner, String fieldName, Object array)
+   {
+      System.out.println("----> Adding " + array + " to " + owner);
+      if (array == null)
+      {
+         return;
+      }
+      Lock writeLock = lock.writeLock();
+      writeLock.lock();
+      try
+      {
+         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         if (arrayReferences == null)
+         {
+            arrayReferences = new WeakHashMap<Object, ArrayRegistryEntry>();
+            cache.put(array, arrayReferences);
+         }
+         arrayReferences.put(owner, new FieldArrayRegistryEntry(owner, fieldName, array));
+         addNestedArrays(array);
+      }
+      finally
+      {
+         writeLock.unlock();
+      }
+   }
+   
+   public void removeFieldReference(Object owner, String field, Object array)
+   {
+      if (array == null)
+      {
+         return;
+      }
+
+      Lock writeLock = lock.writeLock();
+      writeLock.lock();
+      try
+      {
+         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         if (arrayReferences != null)
+         {
+            arrayReferences.remove(owner);
+         }
+         removeNestedArrays(owner, array);
+      }
+      finally
+      {
+         writeLock.unlock();
+      }
+   }
+
+   public void addElementReference(Object owner, int index, Object array)
+   {
+      System.out.println("----> Adding " + array + " to " + owner);
+      if (array == null)
+      {
+         return;
+      }
+      Lock writeLock = lock.writeLock();
+      writeLock.lock();
+      try
+      {
+         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         if (arrayReferences == null)
+         {
+            arrayReferences = new WeakHashMap<Object, ArrayRegistryEntry>();
+            cache.put(array, arrayReferences);
+         }
+         arrayReferences.put(owner, new ElementArrayRegistryEntry(owner, index, array));
+         addNestedArrays(array);
+      }
+      finally
+      {
+         writeLock.unlock();
+      }
+   }
+   
+   public void removeElementReference(Object owner, int index, Object array)
+   {
+      System.out.println("----> Removing " + array + " from " + owner);
+      if (array == null)
+      {
+         return;
+      }
+
+      Lock writeLock = lock.writeLock();
+      writeLock.lock();
+      try
+      {
+         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         if (arrayReferences != null)
+         {
+            arrayReferences.remove(owner);
+         }
+         removeNestedArrays(owner, array);
+      }
+      finally
+      {
+         writeLock.unlock();
+      }
+   }
+
+   public boolean isRegistered(Object array)
+   {
+      Lock readLock = lock.readLock();
+      readLock.lock();
+      
+      try
+      {
+         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         if (arrayReferences == null || arrayReferences.size() == 0)
+         {
+            return false;
+         }
+         return true;
+      }
+      finally
+      {
+         readLock.unlock();
+      }
+   }
+   
+   public Set getOwners(Object owner, Object array)
+   {
+      Lock readLock = lock.readLock();
+      readLock.lock();
+      
+      try
+      {
+         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         if (arrayReferences != null)
+         {
+            HashSet set = new HashSet();
+            set.addAll(arrayReferences.keySet());
+            return set;
+         }
+         return null;
+      }
+      finally
+      {
+         readLock.unlock();
+      }
+   }
+
+   private void addNestedArrays(Object array)
+   {
+      if (array == null)
+      {
+         return;
+      }
+      if (isArray(array))
+      {
+         for (int i = 0 ; i < ((Object[])array).length ; i++)
+         {
+            addElementReference(array, i, ((Object[])array)[i]);
+            addNestedArrays(((Object[])array)[i]);
+         }
+      }
+   }
+   
+   private void removeNestedArrays(Object owner, Object array)
+   {
+      if (array == null)
+      {
+         return;
+      }
+      if (isArray(array))
+      {
+         for (int i = 0 ; i < ((Object[])array).length ; i++)
+         {
+            removeElementReference(array, i, ((Object[])array)[i]);
+            removeNestedArrays(array, ((Object[])array)[i]);
+         }
+      }
+   }
+   
+   private boolean isArray(Object array)
+   {
+      Class componentType = array.getClass().getComponentType();
+      return componentType.isArray();
+   }
+   
+   public void dumpCache()
+   {
+//      System.out.println(cache);
+   }
+//    
+//   public static void main(String[] args)
+//   {
+//      ArrayRegistry registry = getInstance();
+//      
+//      System.out.println("============== 1 dim");
+//      int[] dim1 = new int[] {1,2,3};
+//      registry.addNestedArrays(dim1);
+//      
+//      System.out.println("============== 2 dim");
+//      int[][] dim2 = new int[][] {new int[] {1,2}, new int[] {1,2}};
+//      registry.addNestedArrays(dim2);
+//      
+//      System.out.println("============== 3 dim");
+//      int[][][] dim3 = new int[][][] {new int[][] {new int[] {1,2},new int[] {1,2}}, new int[][] {new int[] {1,2},new int[] {1,2}}};
+//      registry.addNestedArrays(dim3);
+//   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,69 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import java.lang.ref.WeakReference;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public abstract class ArrayRegistryEntry
+{
+   /** WeakReference to the object or array containing the reference */
+   WeakReference owner;
+   
+   /** WeakReference to the referenced array */
+   WeakReference array;
+   
+   /** True if the object referencing the array is a "normal" object, false if it ia an array */
+   boolean ownerIsRoot;
+   
+   ArrayRegistryEntry(Object owner, boolean ownerIsRoot, Object array)
+   {
+      this.owner = new WeakReference(owner);
+      this.array = new WeakReference(array);
+      this.ownerIsRoot = ownerIsRoot;
+      if (ownerIsRoot && owner.getClass().isArray()) {
+         throw new RuntimeException("Owner is root and an array was passed in");
+      }
+      if (!ownerIsRoot && !owner.getClass().isArray()) {
+         throw new RuntimeException("Owner is not root and no array was passed in");
+      }
+   }
+
+   public WeakReference getArray()
+   {
+      return array;
+   }
+
+   public WeakReference getOwner()
+   {
+      return owner;
+   }
+
+   public boolean isOwnerRoot()
+   {
+      return ownerIsRoot;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,38 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ElementArrayRegistryEntry extends ArrayRegistryEntry
+{
+   int index;
+   
+   ElementArrayRegistryEntry(Object owner, int index, Object array)
+   {
+      super(owner, false, array);
+      this.index = index; 
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,44 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class FieldArrayRegistryEntry extends ArrayRegistryEntry
+{
+   String fieldName;
+   
+   FieldArrayRegistryEntry(Object owner, String fieldName, Object array)
+   {
+      // FIXME FieldArrayRegistryEntry constructor
+      super(owner, true, array);
+      this.fieldName = fieldName;
+   }
+   
+   public String getFieldName()
+   {
+      return fieldName;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementReadInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementReadInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class IntArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = 407921822383443705L;
+   int[] array;
+   
+   public IntArrayElementReadInvocation(Interceptor[] interceptors, int[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Integer(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementWriteInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/IntArrayElementWriteInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class IntArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = -3311231820298166088L;
+   int[] array;
+   int value;
+   
+   public IntArrayElementWriteInvocation(Interceptor[] interceptors, int[] target, int index, int value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Integer(value);
+   }
+
+   public int getIntValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementReadInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementReadInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ObjectArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = 2579696791090966825L;
+   Object[] array;
+   
+   public ObjectArrayElementReadInvocation(Interceptor[] interceptors, Object[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return array[index];
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementWriteInvocation.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ObjectArrayElementWriteInvocation.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,56 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ObjectArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = 4256767659280908515L;
+   Object[] array;
+   Object value;
+   
+   public ObjectArrayElementWriteInvocation(Interceptor[] interceptors, Object[] target, int index, Object value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,64 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class TestArrayElementInterceptor implements Interceptor
+{
+   public static int index;
+   public static Object value;
+   
+   public static void clear()
+   {
+      index = -1;
+      value = null;
+   }
+   
+   public String getName()
+   {
+      return this.getClass().getName();
+   }
+
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+      if (invocation instanceof ArrayElementReadInvocation)
+      {
+         index = ((ArrayElementReadInvocation)invocation).getIndex();
+         value = null;
+      }
+      else if (invocation instanceof ArrayElementWriteInvocation)
+      {
+         index = ((ArrayElementWriteInvocation)invocation).getIndex();
+         value = ((ArrayElementWriteInvocation)invocation).getValue();
+      } 
+      
+      return invocation.invokeNext();
+   }
+
+}

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -74,7 +74,7 @@
 
    // Public --------------------------------------------------------
 
-   protected void buildFieldWrappers(CtClass clazz, ClassAdvisor advisor) throws NotFoundException, CannotCompileException
+   protected void buildFieldWrappers(CtClass clazz, ClassAdvisor advisor, boolean shouldReplaceArrayAccess) throws NotFoundException, CannotCompileException
    {
       List fields = Instrumentor.getAdvisableFields(clazz);
 
@@ -97,7 +97,7 @@
             skipFieldInterception = false;
          }
          
-         doBuildFieldWrappers(clazz, field, fieldIndex, classificationGet[index], classificationSet[index]);
+         doBuildFieldWrappers(clazz, field, fieldIndex, shouldReplaceArrayAccess, classificationGet[index], classificationSet[index]);
       }
       
       if (skipFieldInterception)
@@ -116,7 +116,17 @@
       return classification != JoinpointClassification.NOT_INSTRUMENTED;
    }
    
-   protected abstract void doBuildFieldWrappers(CtClass clazz, CtField field, int index, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException;
+   protected abstract void doBuildFieldWrappers(CtClass clazz, CtField field, int index, boolean shouldReplaceArrayAccess, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException;
+   
+   protected String getArrayWriteRegistration(boolean shouldReplaceArrayAccess, CtField field, String oldValue, String newValue) throws NotFoundException
+   {
+      if (field.getType().isArray() && shouldReplaceArrayAccess)
+      {
+         String target = Modifier.isStatic(field.getModifiers()) ? "java.lang.Class.forName(" + field.getType().getName() + ")" : "this";  
+         return "org.jboss.aop.array.ArrayAdvisor.updateArrayField(" + target + ", \"" + field.getName() + "\", " + oldValue + ", " + newValue + ");";
+      }
+      return "";
+   }
    /**
     * replace field access for possible public/protected fields that are intercepted
     * don't need to replace access for private fields.

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -47,7 +47,7 @@
       super(instrumentor);
    }
 
-   protected void doBuildFieldWrappers(CtClass clazz, CtField field, int index, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException
+   protected void doBuildFieldWrappers(CtClass clazz, CtField field, int index, boolean shouldReplaceArrayAccess, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException
    {
       instrumentor.setupBasics(clazz);
       boolean wrappedGet = classificationGet.equals(JoinpointClassification.WRAPPED);
@@ -106,7 +106,7 @@
 
       // executeWrapping
       replaceFieldAccessInternally(clazz, field, wrappedGet, wrappedSet, index);
-      buildWrappers(clazz, field, wrappedGet, wrappedSet, index);
+      buildWrappers(clazz, field, shouldReplaceArrayAccess, wrappedGet, wrappedSet, index);
    }
 
    protected String addFieldReadInfoFieldToGeneratedAdvisor(CtField field, int index)throws NotFoundException, CannotCompileException
@@ -298,7 +298,7 @@
       return code;
    }
 
-   private String getAdvisorWriteWrapperBody(CtClass clazz, CtField field, int index)
+   private String getAdvisorWriteWrapperBody(CtClass clazz, CtField field, int index, boolean shouldReplaceArrayAccess)
    throws NotFoundException, CannotCompileException
    {
       boolean isStatic = Modifier.isStatic(field.getModifiers());
@@ -307,15 +307,17 @@
       String generatorName = FieldJoinPointGenerator.getJoinPointGeneratorFieldName(field.getName(), false);
       if (isStatic)
       {
+         String fieldString = clazz.getName() + "." + field.getName();
          code =
             "{" +
+            "    " + getArrayWriteRegistration(shouldReplaceArrayAccess, field, fieldString, "$2") +
             "   if (" + infoName + " == null && " + generatorName + " != null)" +
             "   {" +
             "   " + generatorName + "." + JoinPointGenerator.GENERATE_JOINPOINT_CLASS + "(this.getClass().getClassLoader());" +
             "   }" +
             "   if (" + infoName + " == null)" +
             "   { " +
-            "   " + clazz.getName() + "." + field.getName() + " = $2;" +
+            "   " + fieldString + " = $2;" +
             "   }" +
             "   else" +
             "   {" +
@@ -325,15 +327,17 @@
       }
       else
       {
+         String fieldString = "((" + clazz.getName() + ")$1)." + field.getName();
          code =
             "{" +
+            "    " + getArrayWriteRegistration(shouldReplaceArrayAccess, field, fieldString, "$2") +
             "   if (" + infoName + " == null && " + generatorName + " != null)" +
             "   {" +
             "   " + generatorName + "." + JoinPointGenerator.GENERATE_JOINPOINT_CLASS + "(this.getClass().getClassLoader());" +
             "   }" +
             "   if (" + infoName + " == null)" +
             "   { " +
-            "   ((" + clazz.getName() + ")$1)." + field.getName() + " = $2;" +
+            "       " + fieldString + " = $2;" +
             "   }" +
             "   else" +
             "   {" +
@@ -376,7 +380,7 @@
 
 
 
-   private void buildWrappers(CtClass clazz, CtField field, boolean doGet, boolean doSet, int index) throws NotFoundException, CannotCompileException
+   private void buildWrappers(CtClass clazz, CtField field, boolean shouldReplaceArrayAccess, boolean doGet, boolean doSet, int index) throws NotFoundException, CannotCompileException
    {
       if (doGet)
       {
@@ -401,7 +405,7 @@
       if (doSet)
       {
          //Set wrapper code in advisor
-         String code = getAdvisorWriteWrapperBody(clazz, field, index);
+         String code = getAdvisorWriteWrapperBody(clazz, field, index, shouldReplaceArrayAccess);
          CtMethod method = getGenadvisor().getDeclaredMethod(advisorFieldWrite(getGenadvisor(), field.getName()));
          try
          {

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -59,6 +59,7 @@
 import javassist.bytecode.AnnotationsAttribute;
 import javassist.bytecode.FieldInfo;
 import javassist.bytecode.MethodInfo;
+import javassist.convert.TransformAccessArrayField.DefaultMethodNames;
 
 /**
  * Transforms byte code, making a class advisable. Implements
@@ -665,7 +666,8 @@
 
          converted = convertReferences(clazz) || converted;
          
-         converted = converted || replaceArrayAccess(clazz, advisor);
+         boolean shouldReplaceArrayAccess = replaceArrayAccess(clazz, advisor);
+         converted = converted || shouldReplaceArrayAccess;
          
          // need to instrument no matter what so that
          // previously declared field and constructor interceptions
@@ -677,7 +679,8 @@
 
          // create static wrapper methods after
          // clazz.instrument because the wrappers may call cons or fields
-         fieldAccessTransformer.buildFieldWrappers(clazz, advisor);
+         fieldAccessTransformer.buildFieldWrappers(clazz, advisor, shouldReplaceArrayAccess);
+         
          if (constructorAccessConverted)
          {
             constructorExecutionTransformer.codeConverted();
@@ -947,24 +950,24 @@
 
    private boolean replaceArrayAccess(CtClass clazz, Advisor advisor) throws Exception
    {
-      boolean shouldReplace = false;
+      boolean shouldReplaceArrayAccess = false;
       Map arrayReplacements = manager.getArrayReplacements();
       for (Iterator it = arrayReplacements.values().iterator() ; it.hasNext() ; )
       {
          ArrayReplacement arrayReplacement = (ArrayReplacement)it.next();
          if (arrayReplacement.matches(advisor, clazz))
          {
-            shouldReplace = true;
+            shouldReplaceArrayAccess = true;
             break;
          }
       }
-      
-      if (shouldReplace)
+
+      if (shouldReplaceArrayAccess)
       {
          System.out.println("---> Should replace access for " + clazz.getName());
-         converter.replaceArrayAccess(classPool.get(ArrayAdvisor.class.getName()), "arrayRead", "arrayWrite");
+         converter.replaceArrayAccess(classPool.get(ArrayAdvisor.class.getName()), new DefaultMethodNames());
       }
-      return shouldReplace;
+      return shouldReplaceArrayAccess;
    }
    
    /**

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/NonOptimizedFieldAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/NonOptimizedFieldAccessTransformer.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/NonOptimizedFieldAccessTransformer.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -50,7 +50,7 @@
       super(instrumentor);
    }
    
-   protected void doBuildFieldWrappers(CtClass clazz, CtField field, int fieldIndex, JoinpointClassification classificationGet, JoinpointClassification classificationSet)
+   protected void doBuildFieldWrappers(CtClass clazz, CtField field, int fieldIndex, boolean shouldReplaceArrayAccess, JoinpointClassification classificationGet, JoinpointClassification classificationSet)
    throws NotFoundException, CannotCompileException
    {
       instrumentor.setupBasics(clazz);

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/OptimizedFieldAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/OptimizedFieldAccessTransformer.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/OptimizedFieldAccessTransformer.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -43,7 +43,7 @@
       super(instrumentor);
    }
 
-   protected void doBuildFieldWrappers(CtClass clazz, CtField field, int fieldIndex, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException
+   protected void doBuildFieldWrappers(CtClass clazz, CtField field, int fieldIndex, boolean shouldReplaceArrayAccess, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException
    {
       instrumentor.setupBasics(clazz);
       boolean wrappedGet = classificationGet.equals(JoinpointClassification.WRAPPED);

Modified: projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
===================================================================
--- projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-23 23:27:35 UTC (rev 59218)
@@ -1,3 +1,6 @@
 <aop>
    <arrayreplacement class="org.jboss.test.aop.array.AOPArrayTestCase"/>
-</aop>
\ No newline at end of file
+   <arrayreplacement expr="class(org.jboss.test.aop.array.ClassWithArrayFields)"/>
+   <prepare expr="field(* org.jboss.test.aop.array.ClassWithArrayFields->*)"/>
+</aop>
+

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -24,6 +24,7 @@
 import junit.framework.Test;
 import junit.framework.TestSuite;
 
+import org.jboss.aop.array.TestArrayElementInterceptor;
 import org.jboss.test.aop.AOPTestWithSetup;
 
 /**
@@ -33,8 +34,6 @@
  */
 public class AOPArrayTestCase extends AOPTestWithSetup
 {
-   ClassWithArrayFields obj = new ClassWithArrayFields();
-   
    public AOPArrayTestCase(String name)
    {
       super(name);
@@ -47,15 +46,122 @@
       return suite;
    }
 
-   public void testIntWrite()
+   public void testIntArray()
    {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
       obj.ifield[1] = 100; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(100, ((Integer)TestArrayElementInterceptor.value).intValue());
+
+      obj.ifield[2] = 123;
+      
+      TestArrayElementInterceptor.clear();
+      int val = obj.ifield[2];
+      assertEquals(123, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
    }
    
-   public void testIntRead()
+   public void testCrap()
    {
-      obj.ifield[1] = 100;
-      int val = obj.ifield[1];
-      assertEquals(100, val);
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      System.out.println("created");
+      int[] orig = obj.iifield[0];
+      System.out.println("backed up");
+      int[] x = new int[] {45};
+      
+      obj.iifield[0] = x;
+      orig[1] = 1;
    }
+   
+   public void testMultiDimensionalTopLevelArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      System.out.println("----------> Constructed");
+      
+      //Create replacement array for top level, this is not registered yet so should be unadvised
+      TestArrayElementInterceptor.clear();
+      int[][] replacement0 = new int[][] {new int[]{11,22}, new int[] {33,44}};
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      System.out.println("----------> Created");
+
+      //Store reference to array to be replaced
+      TestArrayElementInterceptor.clear();
+      int[][] original_0 = obj.iiifield[0];
+      assertEquals(0, TestArrayElementInterceptor.index);
+      
+      //Replace array in top-level array, interception should happen now
+      TestArrayElementInterceptor.clear();
+      obj.iiifield[0] = replacement0;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(replacement0, TestArrayElementInterceptor.value);
+      System.out.println("----------> Replaced");
+      
+      TestArrayElementInterceptor.clear();
+      int i = obj.iiifield[0][0][1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(22, i);
+      
+      TestArrayElementInterceptor.clear();
+      obj.iiifield[0][0][1] = 99;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(99, ((Integer)TestArrayElementInterceptor.value).intValue());
+      
+      //The original array should no longer be registered
+      TestArrayElementInterceptor.clear();
+      i = original_0[0][1];
+      assertEquals(2, i);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      original_0[0][1] = 100;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+
+   public void testMultiDimensionalNestedArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+
+      //Create replacement for nested array 
+      TestArrayElementInterceptor.clear();
+      int[] replacement_0_1 = new int[] {111,222, 333};
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      //Store reference to array to be replaced
+      TestArrayElementInterceptor.clear();
+      int[] original_0_1 = obj.iiifield[0][1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+
+      //Replace nested array, interception should happen now
+      TestArrayElementInterceptor.clear();
+      obj.iiifield[0][1] = replacement_0_1;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(replacement_0_1, TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      int i = obj.iiifield[0][1][2];
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertEquals(333, i);
+
+      TestArrayElementInterceptor.clear();
+      obj.iiifield[0][0][1] = 99;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(99, ((Integer)TestArrayElementInterceptor.value).intValue());
+      
+      //The original array should no longer be registered
+      TestArrayElementInterceptor.clear();
+      original_0_1[1] = 100;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      i = original_0_1[0];
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
 }

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -38,6 +38,7 @@
 import javassist.CtMethod;
 import javassist.CtNewMethod;
 import javassist.Modifier;
+import javassist.convert.TransformAccessArrayField.DefaultMethodNames;
 
 /**
  * Comment
@@ -282,7 +283,7 @@
          if (arrayClasses.contains(clazz.getName()))
          {
             replaced = true;
-            converter.replaceArrayAccess(pool.get(ArrayAdvisor.class.getName()), "arrayRead", "arrayWrite");
+            converter.replaceArrayAccess(pool.get(ArrayAdvisor.class.getName()), new DefaultMethodNames());
          }
 
          if (replaced)

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,91 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.array;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+
+/**
+ * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
+ * @version $Revision: 45977 $
+ */
+public class ArrayTestCase extends AOPTestWithSetup
+{
+   Main main = new Main();
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("ArrayTestCase");
+      suite.addTestSuite(ArrayTestCase.class);
+      return suite;
+   }
+
+   public ArrayTestCase(String name)
+   {
+      super(name);
+      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "field");
+      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "staticfield");
+
+      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFields");
+      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFieldCaller");
+   }
+
+   public void testSimpleField() throws Exception
+   {
+      main.testSimpleField();
+   }
+
+   
+   public void testArrayWrite() throws Exception
+   {
+      main.testArrayWrite();
+   }
+   
+   public void testArrayRead() throws Exception
+   {
+      main.testArrayRead();
+   }
+//   
+//   public void testArrayReadWriteSelf() throws Exception
+//   {
+//      main.testArrayReadWriteSelf();
+//   }
+//
+//   public void testArrayReadWriteFromNonAdvised() throws Exception
+//   {
+//      main.testArrayReadWriteFromNonAdvised();
+//   }
+//
+//   
+//   public void testArrayField() throws Exception
+//   {
+//      main.testArrayField();
+//   }
+}

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -1,91 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.aop.array;
-
-import org.jboss.test.aop.AOPTestWithSetup;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-
-/**
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision: 45977 $
- */
-public class ArrayTestCase extends AOPTestWithSetup
-{
-   Main main = new Main();
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("ArrayTestCase");
-      suite.addTestSuite(ArrayTestCase.class);
-      return suite;
-   }
-
-   public ArrayTestCase(String name)
-   {
-      super(name);
-      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "field");
-      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "staticfield");
-
-      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFields");
-      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFieldCaller");
-   }
-
-   public void testSimpleField() throws Exception
-   {
-      main.testSimpleField();
-   }
-
-   
-   public void testArrayWrite() throws Exception
-   {
-      main.testArrayWrite();
-   }
-   
-   public void testArrayRead() throws Exception
-   {
-      main.testArrayRead();
-   }
-//   
-//   public void testArrayReadWriteSelf() throws Exception
-//   {
-//      main.testArrayReadWriteSelf();
-//   }
-//
-//   public void testArrayReadWriteFromNonAdvised() throws Exception
-//   {
-//      main.testArrayReadWriteFromNonAdvised();
-//   }
-//
-//   
-//   public void testArrayField() throws Exception
-//   {
-//      main.testArrayField();
-//   }
-}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,97 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+import java.lang.reflect.Array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithArrayFieldCaller
+{
+   ClassWithArrayFields obj = new ClassWithArrayFields();
+   
+   public void testArrayWrite() throws Exception
+   {
+      ArrayAdvisor.clear();
+      obj.setValue(1, 100);
+      checkStatus(obj.ifield, 1, String.valueOf(100));
+      
+      ArrayAdvisor.clear();
+      obj.ifield[0] = 75;
+      checkStatus(obj.ifield, 0, String.valueOf(75));
+   }
+   
+   public void testArrayRead() throws Exception
+   {
+      obj.ifield[0] = 100;
+      obj.ifield[1] = 200;
+      
+      ArrayAdvisor.clear();
+      int val = obj.getValue(0);
+      if (val != 100) throw new RuntimeException("Wrong val " + 100);
+      checkStatus(obj.ifield, 0, String.valueOf(100));
+      
+      ArrayAdvisor.clear();
+      val = obj.ifield[1];
+      checkStatus(obj.ifield, 1, String.valueOf(200));
+   }
+
+   public void testDifferentTypes() throws Exception
+   {
+//      ArrayAdvisor.clear();
+//      obj.afield[1] = "Hello";
+//      checkStatus(obj.afield, 1, "Hello");
+//      ArrayAdvisor.clear();
+//      Object aval = obj.afield[1];
+//      if (!aval.equals("Hello")) throw new RuntimeException("Wrong val " + aval);
+//      checkStatus(obj.afield, 1, "Hello");
+//      
+//      ArrayAdvisor.clear();
+//      obj.bfield[2] = true;
+//
+//      ArrayAdvisor.clear();
+//      obj.cfield[1] = 'x';
+//      
+//      ArrayAdvisor.clear();
+//      obj.dfield[2] = 69.0d;
+//      
+//      
+//      ArrayAdvisor.clear();
+//      obj.ffield[1] = 3.9f;
+//      
+//      ArrayAdvisor.clear();
+//      obj.lfield[2] = 100L;
+//      
+//      ArrayAdvisor.clear();
+//      obj.sfield[1] = 5;
+   }
+  
+   private void checkStatus(Object array, int index, String value)
+   {
+      if (array != ArrayAdvisor.array) throw new RuntimeException("Wrong array " + ArrayAdvisor.array);
+      if (index != ArrayAdvisor.index) throw new RuntimeException("Wrong index " + ArrayAdvisor.index);
+      if (!value.equals(ArrayAdvisor.value)) throw new RuntimeException("Wrong string " + ArrayAdvisor.index);
+   }
+}
\ No newline at end of file

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -1,97 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-import java.lang.reflect.Array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class ClassWithArrayFieldCaller
-{
-   ClassWithArrayFields obj = new ClassWithArrayFields();
-   
-   public void testArrayWrite() throws Exception
-   {
-      ArrayAdvisor.clear();
-      obj.setValue(1, 100);
-      checkStatus(obj.ifield, 1, String.valueOf(100));
-      
-      ArrayAdvisor.clear();
-      obj.ifield[0] = 75;
-      checkStatus(obj.ifield, 0, String.valueOf(75));
-   }
-   
-   public void testArrayRead() throws Exception
-   {
-      obj.ifield[0] = 100;
-      obj.ifield[1] = 200;
-      
-      ArrayAdvisor.clear();
-      int val = obj.getValue(0);
-      if (val != 100) throw new RuntimeException("Wrong val " + 100);
-      checkStatus(obj.ifield, 0, String.valueOf(100));
-      
-      ArrayAdvisor.clear();
-      val = obj.ifield[1];
-      checkStatus(obj.ifield, 1, String.valueOf(200));
-   }
-
-   public void testDifferentTypes() throws Exception
-   {
-//      ArrayAdvisor.clear();
-//      obj.afield[1] = "Hello";
-//      checkStatus(obj.afield, 1, "Hello");
-//      ArrayAdvisor.clear();
-//      Object aval = obj.afield[1];
-//      if (!aval.equals("Hello")) throw new RuntimeException("Wrong val " + aval);
-//      checkStatus(obj.afield, 1, "Hello");
-//      
-//      ArrayAdvisor.clear();
-//      obj.bfield[2] = true;
-//
-//      ArrayAdvisor.clear();
-//      obj.cfield[1] = 'x';
-//      
-//      ArrayAdvisor.clear();
-//      obj.dfield[2] = 69.0d;
-//      
-//      
-//      ArrayAdvisor.clear();
-//      obj.ffield[1] = 3.9f;
-//      
-//      ArrayAdvisor.clear();
-//      obj.lfield[2] = 100L;
-//      
-      ArrayAdvisor.clear();
-      obj.sfield[1] = 5;
-   }
-  
-   private void checkStatus(Object array, int index, String value)
-   {
-      if (array != ArrayAdvisor.array) throw new RuntimeException("Wrong array " + ArrayAdvisor.array);
-      if (index != ArrayAdvisor.index) throw new RuntimeException("Wrong index " + ArrayAdvisor.index);
-      if (!value.equals(ArrayAdvisor.value)) throw new RuntimeException("Wrong string " + ArrayAdvisor.index);
-   }
-}
\ No newline at end of file

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.test.aop.array;
 
+import java.util.Arrays;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -28,28 +30,55 @@
  */
 public class ClassWithArrayFields
 {
-   
-   
-   public Object[] afield = new Object[] {"1", "2", "3"};
-   public boolean[] bfield = new boolean[] {true, false};
-   public char[] cfield = new char[] {'a', 'b', 'c'};
-   public double[] dfield = new double[] {1.5d, 1.9d};
-   public float[] ffield = new float[] {1.5f, 1.9f};
+//   public Object[] afield = new Object[] {"1", "2", "3"};
+//   public boolean[] bfield = new boolean[] {true, false};
+//   public char[] cfield = new char[] {'a', 'b', 'c'};
+//   public double[] dfield = new double[] {1.5d, 1.9d};
+//   public float[] ffield = new float[] {1.5f, 1.9f};
    public int[] ifield = new int[] {0, 0, 0};
-   public long[] lfield = new long[] {0L, 0L, 0L};
-   public short[] sfield = new short[] {0, 0, 0};
-   
-   
-   public void setValue(int index, int value)
+   public int[][] iifield = new int[][]{new int[] {0, 0}, new int[] {0, 0}};
+   public int[][][] iiifield = new int[][][] {
+         new int[][] {
+               new int[] {1,2,3}, 
+               new int[] {4,5,6},
+               new int[] {7,8,9}
+         },
+         new int[][] {
+               new int[] {1,2,3}, 
+               new int[] {4,5,6},
+               new int[] {7,8,9}
+         },         
+   };
+
+   public ClassWithArrayFields()
    {
-      ifield[index] = value;
+
    }
-   
-   public int getValue(int index)
+   public static void main(String[] args)
    {
-      return ifield[index];
+//      ClassWithArrayFields tgt = new ClassWithArrayFields();
+//      for (int i = 0 ; i < tgt.iiifield.length ; i++) {
+//         for (int j = 0 ; j < tgt.iiifield[i].length ; j++) {
+//            for (int k = 0 ; k < tgt.iiifield[i][j].length ; k++) {
+//               System.out.println(tgt.iiifield[i][j][k]);
+//            }
+//         }
+//      }
    }
+//   public long[] lfield = new long[] {0L, 0L, 0L};
+//   public short[] sfield = new short[] {0, 0, 0};
    
+   
+//   public void setValue(int index, int value)
+//   {
+//      ifield[index] = value;
+//   }
+//   
+//   public int getValue(int index)
+//   {
+//      return ifield[index];
+//   }
+   
    public void test(short s)
    {
       test(s);

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak	2006-12-23 23:27:35 UTC (rev 59218)
@@ -0,0 +1,68 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class Main
+{
+   public Main()
+   {
+   }
+
+   public static void main(String[] args)throws Exception
+   {
+      Main main = new Main();
+      main.testSimpleField();
+      main.testArrayField();
+   }
+
+   public void testSimpleField() throws Exception
+   {
+      ClassWithSimpleFieldCaller caller = new ClassWithSimpleFieldCaller();
+      caller.testSimple();
+      caller.testSimpleStatic();
+   }
+
+   
+   public void testArrayField() throws Exception
+   {
+//      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
+//      caller.testArray();
+//      caller.testArrayStatic();
+   }
+   
+   public void testArrayWrite() throws Exception
+   {
+      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
+      caller.testArrayWrite();
+   }
+   
+   public void testArrayRead() throws Exception
+   {
+      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
+      caller.testArrayRead();
+   }
+}

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java	2006-12-23 20:56:17 UTC (rev 59217)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.java	2006-12-23 23:27:35 UTC (rev 59218)
@@ -1,68 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class Main
-{
-   public Main()
-   {
-   }
-
-   public static void main(String[] args)throws Exception
-   {
-      Main main = new Main();
-      main.testSimpleField();
-      main.testArrayField();
-   }
-
-   public void testSimpleField() throws Exception
-   {
-      ClassWithSimpleFieldCaller caller = new ClassWithSimpleFieldCaller();
-      caller.testSimple();
-      caller.testSimpleStatic();
-   }
-
-   
-   public void testArrayField() throws Exception
-   {
-//      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
-//      caller.testArray();
-//      caller.testArrayStatic();
-   }
-   
-   public void testArrayWrite() throws Exception
-   {
-      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
-      caller.testArrayWrite();
-   }
-   
-   public void testArrayRead() throws Exception
-   {
-      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
-      caller.testArrayRead();
-   }
-}



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 19:11:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 19:11:42 -0500
Subject: [jboss-cvs] JBossAS SVN: r59219 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array resources/test/array
	test/org/jboss/test/aop/array
Message-ID: <E1GyGxq-0005Hx-Gm@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-23 19:11:36 -0500 (Sat, 23 Dec 2006)
New Revision: 59219

Added:
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSeveralReferencesToSameArray.java
Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
Log:
Better reference counting in the case of an array referenced by several "owners"

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-24 00:11:36 UTC (rev 59219)
@@ -66,7 +66,15 @@
             arrayReferences = new WeakHashMap<Object, ArrayRegistryEntry>();
             cache.put(array, arrayReferences);
          }
-         arrayReferences.put(owner, new FieldArrayRegistryEntry(owner, fieldName, array));
+         ArrayRegistryEntry regEntry = arrayReferences.get(owner);
+         if (regEntry != null)
+         {
+            ((FieldArrayRegistryEntry)regEntry).addFieldName(fieldName);
+         }
+         else
+         {
+            arrayReferences.put(owner, new FieldArrayRegistryEntry(owner, fieldName, array));
+         }
          addNestedArrays(array);
       }
       finally
@@ -89,7 +97,15 @@
          WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
          if (arrayReferences != null)
          {
-            arrayReferences.remove(owner);
+            ArrayRegistryEntry regEntry = arrayReferences.get(owner);
+            if (owner != null)
+            {
+               ((FieldArrayRegistryEntry)regEntry).removeFieldName(field);
+               if (!regEntry.ownerHasReferences())
+               {
+                  arrayReferences.remove(owner);
+               }
+            }
          }
          removeNestedArrays(owner, array);
       }
@@ -116,7 +132,15 @@
             arrayReferences = new WeakHashMap<Object, ArrayRegistryEntry>();
             cache.put(array, arrayReferences);
          }
-         arrayReferences.put(owner, new ElementArrayRegistryEntry(owner, index, array));
+         ArrayRegistryEntry regEntry = arrayReferences.get(owner);
+         if (regEntry != null)
+         {
+            ((ElementArrayRegistryEntry)regEntry).addIndex(index);
+         }
+         else
+         {
+            arrayReferences.put(owner, new ElementArrayRegistryEntry(owner, index, array));
+         }
          addNestedArrays(array);
       }
       finally
@@ -140,7 +164,15 @@
          WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
          if (arrayReferences != null)
          {
-            arrayReferences.remove(owner);
+            ArrayRegistryEntry regEntry = arrayReferences.get(owner);
+            if (owner != null)
+            {
+               ((ElementArrayRegistryEntry)regEntry).removeIndex(index);
+               if (!regEntry.ownerHasReferences())
+               {
+                  arrayReferences.remove(owner);
+               }
+            }
          }
          removeNestedArrays(owner, array);
       }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java	2006-12-24 00:11:36 UTC (rev 59219)
@@ -66,4 +66,6 @@
    {
       return ownerIsRoot;
    }
+   
+   public abstract boolean ownerHasReferences();
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java	2006-12-24 00:11:36 UTC (rev 59219)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.aop.array;
 
+import java.util.HashSet;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -28,11 +30,27 @@
  */
 public class ElementArrayRegistryEntry extends ArrayRegistryEntry
 {
-   int index;
+   HashSet<Integer> indices = new HashSet<Integer>();
    
    ElementArrayRegistryEntry(Object owner, int index, Object array)
    {
       super(owner, false, array);
-      this.index = index; 
+      this.indices.add(index); 
    }
+   
+   public void addIndex(int index)
+   {
+      indices.add(index);
+   }
+   
+   public void removeIndex(int index)
+   {
+      indices.remove(index);
+   }
+
+   @Override
+   public boolean ownerHasReferences()
+   {
+      return indices.size() > 0;
+   }
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java	2006-12-24 00:11:36 UTC (rev 59219)
@@ -21,6 +21,8 @@
 */ 
 package org.jboss.aop.array;
 
+import java.util.HashSet;
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -28,17 +30,28 @@
  */
 public class FieldArrayRegistryEntry extends ArrayRegistryEntry
 {
-   String fieldName;
+   HashSet fields = new HashSet<String>();
    
    FieldArrayRegistryEntry(Object owner, String fieldName, Object array)
    {
       // FIXME FieldArrayRegistryEntry constructor
       super(owner, true, array);
-      this.fieldName = fieldName;
+      this.fields.add(fieldName);
    }
    
-   public String getFieldName()
+   public void addFieldName(String fieldName)
    {
-      return fieldName;
+      fields.add(fieldName);
    }
-}
+   
+   public void removeFieldName(String fieldName)
+   {
+      fields.remove(fieldName);
+   }
+   
+   @Override
+   public boolean ownerHasReferences()
+   {
+      return fields.size() > 0;
+   }
+}
\ No newline at end of file

Modified: projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
===================================================================
--- projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-24 00:11:36 UTC (rev 59219)
@@ -1,6 +1,7 @@
 <aop>
    <arrayreplacement class="org.jboss.test.aop.array.AOPArrayTestCase"/>
-   <arrayreplacement expr="class(org.jboss.test.aop.array.ClassWithArrayFields)"/>
+   <arrayreplacement expr="class(org.jboss.test.aop.array.ClassWithArrayFields) OR class(org.jboss.test.aop.array.ClassWithSeveralReferencesToSameArray)"/>
    <prepare expr="field(* org.jboss.test.aop.array.ClassWithArrayFields->*)"/>
+   <prepare expr="field(* org.jboss.test.aop.array.ClassWithSeveralReferencesToSameArray->*)"/> 
 </aop>
 

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-24 00:11:36 UTC (rev 59219)
@@ -27,6 +27,7 @@
 import org.jboss.aop.array.TestArrayElementInterceptor;
 import org.jboss.test.aop.AOPTestWithSetup;
 
+
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -64,18 +65,6 @@
       assertNull(TestArrayElementInterceptor.value);
    }
    
-   public void testCrap()
-   {
-      ClassWithArrayFields obj = new ClassWithArrayFields();
-      System.out.println("created");
-      int[] orig = obj.iifield[0];
-      System.out.println("backed up");
-      int[] x = new int[] {45};
-      
-      obj.iifield[0] = x;
-      orig[1] = 1;
-   }
-   
    public void testMultiDimensionalTopLevelArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
@@ -164,4 +153,157 @@
       assertNull(TestArrayElementInterceptor.value);
    }
    
+   public static void testMultipleFieldReferences()
+   {
+      ClassWithSeveralReferencesToSameArray obj = new ClassWithSeveralReferencesToSameArray();
+      assertEquals(obj.one, obj.two);
+      
+      int[] original = obj.one;
+      
+      TestArrayElementInterceptor.clear();
+      obj.one[1] = 100;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      int i = obj.one[1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+      TestArrayElementInterceptor.clear();
+      i = obj.two[1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+      
+      assertEquals(obj.one, obj.two);
+      
+      TestArrayElementInterceptor.clear();
+      int replacement1[] = new int[2];
+      replacement1[0] = 11;
+      replacement1[1] = 22;
+      
+      obj.one = replacement1;
+      TestArrayElementInterceptor.clear();
+      obj.one[1] = 99;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(99, TestArrayElementInterceptor.value);
+
+      //obj.two still references original, so make sure that we have interception 
+      TestArrayElementInterceptor.clear();
+      i = original[1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+
+      obj.two = replacement1;
+      TestArrayElementInterceptor.clear();
+      obj.one[1] = 101;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(101, TestArrayElementInterceptor.value);
+
+      //original is no longer referenced by and advised field, we should not have interception 
+      TestArrayElementInterceptor.clear();
+      i = original[1];
+      assertEquals(-1, TestArrayElementInterceptor.index);
+   }
+   
+   public static void testMultipleNestedReferences()
+   {
+      ClassWithSeveralReferencesToSameArray obj = new ClassWithSeveralReferencesToSameArray();
+      assertEquals(obj.multi[0], obj.multi[1]);
+      
+      int[] original = obj.multi[0];
+      
+      TestArrayElementInterceptor.clear();
+      obj.multi[0][1] = 100;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      int i = obj.multi[0][1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+      TestArrayElementInterceptor.clear();
+      i = obj.multi[1][1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+      
+      assertEquals(obj.multi[0], obj.multi[1]);
+      
+      TestArrayElementInterceptor.clear();
+      int replacement1[] = new int[2];
+      replacement1[0] = 11;
+      replacement1[1] = 22;
+      
+      obj.multi[0] = replacement1;
+      TestArrayElementInterceptor.clear();
+      obj.multi[0][1] = 99;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(99, TestArrayElementInterceptor.value);
+
+      //obj.multi[1] still references original, so make sure that we have interception 
+      TestArrayElementInterceptor.clear();
+      i = original[1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+
+      obj.multi[1] = replacement1;
+      TestArrayElementInterceptor.clear();
+      obj.multi[0][1] = 101;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(101, TestArrayElementInterceptor.value);
+
+      //original is no longer referenced by and advised field, we should not have interception 
+      TestArrayElementInterceptor.clear();
+      i = original[1];
+      assertEquals(-1, TestArrayElementInterceptor.index);
+   }
+   
+   public static void testMultipleMixedReferences()
+   {
+      ClassWithSeveralReferencesToSameArray obj = new ClassWithSeveralReferencesToSameArray();
+      obj.multi[0] = obj.one = new int[] {8,6,4};
+      
+      int[] original = obj.multi[0];
+      
+      TestArrayElementInterceptor.clear();
+      obj.multi[0][1] = 100;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      int i = obj.multi[0][1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+      TestArrayElementInterceptor.clear();
+      i = obj.one[1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+      
+      assertEquals(obj.multi[0], obj.one);
+      
+      TestArrayElementInterceptor.clear();
+      int replacement1[] = new int[2];
+      replacement1[0] = 11;
+      replacement1[1] = 22;
+      
+      obj.multi[0] = replacement1;
+      TestArrayElementInterceptor.clear();
+      obj.multi[0][1] = 99;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(99, TestArrayElementInterceptor.value);
+
+      //obj.one still references original, so make sure that we have interception 
+      TestArrayElementInterceptor.clear();
+      i = original[1];
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(100, i);
+
+      obj.one = replacement1;
+      TestArrayElementInterceptor.clear();
+      obj.multi[0][1] = 101;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(101, TestArrayElementInterceptor.value);
+
+      //original is no longer referenced by and advised field, we should not have interception 
+      TestArrayElementInterceptor.clear();
+      i = original[1];
+      assertEquals(-1, TestArrayElementInterceptor.index);
+   }
+   
 }

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSeveralReferencesToSameArray.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSeveralReferencesToSameArray.java	2006-12-23 23:27:35 UTC (rev 59218)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSeveralReferencesToSameArray.java	2006-12-24 00:11:36 UTC (rev 59219)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithSeveralReferencesToSameArray
+{
+   int[] one;
+   int[] two;
+   
+   int[][] multi;
+   
+   public ClassWithSeveralReferencesToSameArray()
+   {
+      one = new int[] {1,2,3};
+      two = one;
+      
+      int[] nested = new int[] {4,5,6};
+      multi = new int[2][];
+      multi[0] = nested;
+      multi[1] = nested;
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Sat Dec 23 19:42:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 23 Dec 2006 19:42:56 -0500
Subject: [jboss-cvs] JBossAS SVN: r59220 -
	branches/Branch_4_2/system/src/main/org/jboss/system/server
Message-ID: <E1GyHS4-0005mF-S6@committer01.frg.pub.inap.atl.jboss.com>

Author: thomas.diesler at jboss.com
Date: 2006-12-23 19:42:54 -0500 (Sat, 23 Dec 2006)
New Revision: 59220

Modified:
   branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImpl.java
   branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java
Log:
add specification/implementation title/version from the manifest

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImpl.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImpl.java	2006-12-24 00:11:36 UTC (rev 59219)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImpl.java	2006-12-24 00:42:54 UTC (rev 59220)
@@ -73,6 +73,11 @@
     */
    private Object patchURL;
 
+   private String serverSpecificationTitle;
+   private String serverSpecificationVersion;
+   private String serverImplementationTitle;
+   private String serverImplementationVersion;
+
    private String serverName;
    private File serverBaseDir;
    private File serverHomeDir;
@@ -83,7 +88,7 @@
    private URL serverHomeURL;
    private URL serverLibraryURL;
    private URL serverConfigURL;
-
+   
    /** Exit on shutdown flag. */
    private Boolean exitOnShutdown;
    private Boolean blockingShutdown;
@@ -110,6 +115,12 @@
       System.setProperty(ServerConfig.HOME_DIR, homeDir.toString());
       // Setup the SERVER_HOME_DIR system property
       getServerHomeDir();
+      
+      Package thisPackage = getClass().getPackage();
+      serverSpecificationTitle = thisPackage.getSpecificationTitle();
+      serverSpecificationVersion = thisPackage.getSpecificationVersion();
+      serverImplementationTitle = thisPackage.getImplementationTitle();
+      serverImplementationVersion = thisPackage.getImplementationVersion();
    }
 
    /** Breakout the initialization of URLs from the constructor as we need
@@ -131,6 +142,42 @@
    /////////////////////////////////////////////////////////////////////////
 
    /**
+    * Get the server Implementation-Title
+    * @jmx:managed-attribute
+    */
+   public String getImplementationTitle()
+   {
+      return serverImplementationTitle;
+   }
+
+   /**
+    * Get the server Implementation-Version
+    * @jmx:managed-attribute
+    */
+   public String getImplementationVersion()
+   {
+      return serverImplementationVersion;
+   }
+
+   /**
+    * Get the server Specification-Title
+    * @jmx:managed-attribute
+    */
+   public String getSpecificationTitle()
+   {
+      return serverSpecificationTitle;
+   }
+
+   /**
+    * Get the server Specification-Version
+    * @jmx:managed-attribute
+    */
+   public String getSpecificationVersion()
+   {
+      return serverSpecificationVersion;
+   }
+
+   /**
     * Get the local home directory which the server is running from.
     *
     * @jmx:managed-attribute

Modified: branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java
===================================================================
--- branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java	2006-12-24 00:11:36 UTC (rev 59219)
+++ branches/Branch_4_2/system/src/main/org/jboss/system/server/ServerConfigImplMBean.java	2006-12-24 00:42:54 UTC (rev 59220)
@@ -32,6 +32,26 @@
          .create("jboss.system:type=ServerConfig");
 
    /**
+    * Get the server Implementation-Title
+    */
+   String getImplementationTitle();
+
+   /**
+    * Get the server Implementation-Version
+    */
+   String getImplementationVersion();
+
+   /**
+    * Get the server Specification-Title
+    */
+   String getSpecificationTitle();
+
+   /**
+    * Get the server Specification-Version
+    */
+   String getSpecificationVersion();
+   
+   /**
     * Get the local home directory which the server is running from.
     */
    java.io.File getHomeDir();



From norman.richards at jboss.com  Sat Dec 23 21:19:14 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sat, 23 Dec 2006 21:19:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/core  ...
Message-ID: <E1GyIxG-0007Xv-65@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/23 21:19:14

  Modified:    src/main/org/jboss/seam/core  Interpolator.java
  Log:
  JBSEAM-624: again
  
  Revision  Changes    Path
  1.15      +16 -15    jboss-seam/src/main/org/jboss/seam/core/Interpolator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Interpolator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/core/Interpolator.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- Interpolator.java	20 Dec 2006 17:01:53 -0000	1.14
  +++ Interpolator.java	24 Dec 2006 02:19:14 -0000	1.15
  @@ -49,8 +49,10 @@
       * @return the interpolated string
       */
      public String interpolate(String string, Object... params) {
  -      if ( params!=null && params.length>0 )
  -      {
  +       if (params == null) {
  +           params = new Object[0];
  +       }
  +
            if ( params.length>10 ) 
            {
               throw new IllegalArgumentException("more than 10 parameters");
  @@ -59,11 +61,10 @@
            {
               string = interpolateExpressions(string, params);
            }
  -         if ( string.indexOf('{')>=0 )
  +       if (params.length>0 &&  string.indexOf('{')>=0 )
            {
               string = new MessageFormat(string, Locale.instance()).format(params);
            }
  -      }
         return string;
      }
   
  
  
  


From norman.richards at jboss.com  Sat Dec 23 22:46:57 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sat, 23 Dec 2006 22:46:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/booking/view/css   ...
Message-ID: <E1GyKK9-0000YG-6N@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/23 22:46:57

  Modified:    examples/booking/view/css   date.css screen.css
  Log:
  update css
  
  Revision  Changes    Path
  1.2       +8 -0      jboss-seam/examples/booking/view/css/date.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: date.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/css/date.css,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- date.css	8 Dec 2006 00:38:14 -0000	1.1
  +++ date.css	24 Dec 2006 03:46:57 -0000	1.2
  @@ -83,3 +83,11 @@
       border: 1px solid #AAAAAA;
       font-weight: bold;
   }
  +
  +/* style information for weekends */
  +/*
  +.seam-date td.weekend {
  +    color: #c00;
  +    border: 1px solid #f99;
  +}
  +*/
  
  
  
  1.9       +265 -265  jboss-seam/examples/booking/view/css/screen.css
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: screen.css
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/booking/view/css/screen.css,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  
  
  


From forge-admin at jboss.com  Sun Dec 24 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sun, 24 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GyMPL-0002pX-8i@committer01.frg.pub.inap.atl.jboss.com>

Commit from ptsekov on branch Branch_JBossCache_1_4_0 (2006-12-23 04:55 EST)
-----------------------------------------------------

Add a no-argument constructor and setter methods for each getter method. Make this class look more like a JavaBean so that it can be serialized via java.beans.XMLEncoder.

  JBossCache  tests/compat/org/jboss/tools/ClassVersionInfo.java  1.1.2.2


Commit from ptsekov on branch Branch_JBossCache_1_4_0 (2006-12-23 05:40 EST)
-----------------------------------------------------

* SerialVersionUID.java (SerialVersionUID::processProperties): Do not copy non-existing system properties.

  JBossCache  tests/compat/org/jboss/tools/SerialVersionUID.java  1.1.2.2


Commit from ptsekov on branch Branch_JBossCache_1_4_0 (2006-12-23 05:47 EST)
-----------------------------------------------------

* SerialVersionUID.java (SerialVersionUID::outputXML): New class variable.
(SerialVersionUID::processProperties): Add support for new boolean property 'output.xml'.
(SerialVersionUID::main): Write the collected information as either serialized java object or as XML generated by java.beans.XMLEncoder.

  JBossCache  tests/compat/org/jboss/tools/SerialVersionUID.java  1.1.2.3


Commit from ptsekov on branch Branch_JBossCache_1_4_0 (2006-12-23 07:03 EST)
-----------------------------------------------------

* etc/svuid-db/svuid-14.1.3.0.GA.xml: SVUID database for JBossCache 1.3.0
and JDK 1.4 .
* etc/svuid-db/svuid-14.1.4.0.GA.xml: SVUID database for JBossCache 1.4.0
and JDK 1.4 .
* etc/svuid-db/svuid-50.1.3.0.GA.xml: SVUID database for JBossCache 1.3.0
and JDK 5.
* etc/svuid-db/svuid-50.1.4.0.GA.xml: SVUID database for JBossCache 1.4.0
and JDK 5.

+ JBossCache  etc/svuid-db/svuid-14.1.3.0.GA.xml  1.1.2.1
+ JBossCache  etc/svuid-db/svuid-14.1.4.0.GA.xml  1.1.2.1
+ JBossCache  etc/svuid-db/svuid-50.1.3.0.GA.xml  1.1.2.1
+ JBossCache  etc/svuid-db/svuid-50.1.4.0.GA.xml  1.1.2.1


Commit from ptsekov on branch Branch_JBossCache_1_4_0 (2006-12-23 10:36 EST)
-----------------------------------------------------

* SerialVersionUIDUnitTestCase.java: Add tests for compatibility with JBossCache 1.3.0.GA and 1.4.0.GA.

  JBossCache  tests/compat/org/jboss/cache/compat/SerialVersionUIDUnitTestCase.java  1.1.2.2


Commit from tdiesler (2006-12-23 15:48 EST)
--------------------

jaxb-2.1

+ repository.jboss.com  sun-jaxb/2.1/component-info.xml      1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-api-doc.zip    1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-api-src.zip    1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-api.jar        1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-impl.jar       1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-impl.src.zip   1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-xjc.jar        1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jaxb-xjc.src.zip    1.1
+ repository.jboss.com  sun-jaxb/2.1/lib/jsr173_1.0_api.jar  1.1


Commit from nrichards (2006-12-23 21:19 EST)
---------------------

JBSEAM-624: again

  jboss-seam  src/main/org/jboss/seam/core/Interpolator.java  1.15


Commit from nrichards (2006-12-23 22:46 EST)
---------------------

update css

  jboss-seam  examples/booking/view/css/date.css    1.2
  jboss-seam  examples/booking/view/css/screen.css  1.9
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061224/45a8e390/attachment.html 

From yrjk9sda87f4 at doramail.com  Sun Dec 24 01:50:34 2006
From: yrjk9sda87f4 at doramail.com (yrjk9sda87f4 at doramail.com)
Date: Sun, 24 Dec 2006 01:50:34 -0500
Subject: [jboss-cvs] =?utf-8?b?woNOwoPCisKDWMKDfcKDWMKDQ8KDdcKCw4jCgsOM?=
	=?utf-8?b?woLDicKXXMKSw6jCgsOIwoLCtcKBY8KBQsKNwqHCk8O6wojCp8KCwqI=?=
	=?utf-8?b?woLCvcKCwqLCgsOIwoFjwoHDtA==?=
Message-ID: 20061224161945.65583mail@mail.kjhgfdsawertewuiytsdfadhafdgbhucdsyteudsf.com

???????N???X?}?X?C?u???????????????????????????????H
???????????C?u?????????l?????????????c?B
?????????????l???????????????v???????[???????????I
?S???????N???X?}?X???M????????????
?????C????????????????????(^^??
http://freeweb.lovelovesexywoman.tonderuyo.com/Scircle/





From jboss-cvs-commits at lists.jboss.org  Sun Dec 24 05:56:26 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 24 Dec 2006 05:56:26 -0500
Subject: [jboss-cvs] JBossAS SVN: r59221 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array test/org/jboss/test/aop/array
Message-ID: <E1GyR1m-00081d-Ku@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-24 05:56:21 -0500 (Sun, 24 Dec 2006)
New Revision: 59221

Removed:
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/META-INF/
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak
Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
Log:
Tidy up a bit

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-24 10:56:21 UTC (rev 59221)
@@ -49,31 +49,6 @@
       registry.removeFieldReference(target, fieldName, oldValue);
       registry.addFieldReference(target, fieldName, newValue);
    }
-   
-   //Write operations
-//   public static void arrayWrite(boolean[] array, int index, boolean value)
-//   {
-//      array[index] = value; 
-//   }
-//
-//   public static void arrayWrite(short[] array, int index, short value)
-//   {
-//      array[index] = value; 
-//   }
-//
-   public static void arrayWriteInt(Object array, int index, int value) throws Throwable
-   {
-      if (ArrayRegistry.getInstance().isRegistered(array))
-      {
-         System.out.println("---------> Writing" + array + " advised");
-         IntArrayElementWriteInvocation invocation = new IntArrayElementWriteInvocation(interceptors, ((int[])array), index, value);
-         invocation.invokeNext();
-      }
-      else
-      {
-         ((int[])array)[index] = value;
-      }
-   }
 
    public static void arrayWriteObject(Object array, int index, Object value) throws Throwable
    {
@@ -99,6 +74,31 @@
       }
    }
    
+   public static void arrayWriteInt(Object array, int index, int value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         System.out.println("---------> Writing" + array + " advised");
+         IntArrayElementWriteInvocation invocation = new IntArrayElementWriteInvocation(interceptors, ((int[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((int[])array)[index] = value;
+      }
+   }
+
+   //Write operations
+//   public static void arrayWrite(boolean[] array, int index, boolean value)
+//   {
+//      array[index] = value; 
+//   }
+//
+//   public static void arrayWrite(short[] array, int index, short value)
+//   {
+//      array[index] = value; 
+//   }
+//
 //   
 //   public static void arrayWrite(long[] array, int index, long value)
 //   {
@@ -139,29 +139,29 @@
 //      return value;
 //   }
 //
-   public static int arrayReadInt(Object array, int index) throws Throwable
+   public static Object arrayReadObject(Object array, int index) throws Throwable
    {
       if (ArrayRegistry.getInstance().isRegistered(array))
       {
-         IntArrayElementReadInvocation invocation = new IntArrayElementReadInvocation(interceptors, (int[])array, index);
-         return ((Integer)invocation.invokeNext()).intValue();
+         ObjectArrayElementReadInvocation invocation = new ObjectArrayElementReadInvocation(interceptors, (Object[])array, index);
+         return invocation.invokeNext();
       }
       else
       {
-         return ((int[])array)[index];
+         return ((Object[])array)[index];
       }
    }
 
-   public static Object arrayReadObject(Object array, int index) throws Throwable
+   public static int arrayReadInt(Object array, int index) throws Throwable
    {
       if (ArrayRegistry.getInstance().isRegistered(array))
       {
-         ObjectArrayElementReadInvocation invocation = new ObjectArrayElementReadInvocation(interceptors, (Object[])array, index);
-         return invocation.invokeNext();
+         IntArrayElementReadInvocation invocation = new IntArrayElementReadInvocation(interceptors, (int[])array, index);
+         return ((Integer)invocation.invokeNext()).intValue();
       }
       else
       {
-         return ((Object[])array)[index];
+         return ((int[])array)[index];
       }
    }
 

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-24 10:56:21 UTC (rev 59221)
@@ -68,14 +68,12 @@
    public void testMultiDimensionalTopLevelArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
-      System.out.println("----------> Constructed");
       
       //Create replacement array for top level, this is not registered yet so should be unadvised
       TestArrayElementInterceptor.clear();
       int[][] replacement0 = new int[][] {new int[]{11,22}, new int[] {33,44}};
       assertEquals(-1, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
-      System.out.println("----------> Created");
 
       //Store reference to array to be replaced
       TestArrayElementInterceptor.clear();
@@ -88,7 +86,6 @@
       assertEquals(0, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(replacement0, TestArrayElementInterceptor.value);
-      System.out.println("----------> Replaced");
       
       TestArrayElementInterceptor.clear();
       int i = obj.iiifield[0][0][1];

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPTransformer.java	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,315 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.aop.array;
-
-import org.jboss.aop.AspectManager;
-import org.jboss.aop.classpool.AOPClassPool;
-
-import java.lang.instrument.ClassFileTransformer;
-import java.lang.instrument.IllegalClassFormatException;
-import java.security.ProtectionDomain;
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-
-import javassist.CodeConverter;
-import javassist.CtClass;
-import javassist.CtField;
-import javassist.CtMethod;
-import javassist.CtNewMethod;
-import javassist.Modifier;
-import javassist.convert.TransformAccessArrayField.DefaultMethodNames;
-
-/**
- * Comment
- *
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision: 44099 $
- */
-public class AOPTransformer implements ClassFileTransformer
-{
-   private static HashMap<String, HashSet<String>> simpleClassFields = new HashMap<String, HashSet<String>>(); 
-//   private static HashMap<String, HashSet<String>> arrayClassFields = new HashMap<String, HashSet<String>>();
-   private static HashSet<String> arrayClasses = new HashSet<String>();
-
-   public static void addArrayClass(String clazz)
-   {
-      arrayClasses.add(clazz);
-   }
-   
-   public static void addSimpleField(String clazz, String field)
-   {
-      addField(simpleClassFields, clazz, field);
-   }
-   
-//   public static void addArrayField(String clazz, String field)
-//   {
-//      addField(arrayClassFields, clazz, field);
-//   }
-   
-   private static void addField(HashMap<String, HashSet<String>> classFields, String clazz, String field)
-   {
-      HashSet<String> fields = classFields.get(clazz); 
-      if (fields == null)
-      {
-         fields = new HashSet<String>();
-         classFields.put(clazz, fields);
-      }
-      
-      fields.add(field);
-   }
-   
-   private static boolean isAdvisableField(HashMap<String, HashSet<String>> classFields, String clazz, String field)
-   {
-      HashSet<String> fields = classFields.get(clazz);
-      if (fields == null)
-      {
-         return false;
-      }
-      
-      return fields.contains(field);
-   }
-   
-   public static boolean isAdvisableSimpleField(CtField field)
-   {
-      return isAdvisableField(simpleClassFields, field.getDeclaringClass().getName(), field.getName());
-   }
-   
-//   public static boolean isAdvisableArrayField(CtField field)
-//   {
-//      return isAdvisableField(arrayClassFields, field.getDeclaringClass().getName(), field.getName());
-//   }
-   
-   public boolean isNonAdvisableClassName(String classname)
-   {
-      return (classname.startsWith("org.jboss.aop") ||
-      classname.endsWith("$aop") ||
-      classname.startsWith("javassist") ||
-      classname.startsWith("org.jboss.util.") ||
-      classname.startsWith("gnu.trove.") ||
-      classname.startsWith("EDU.oswego.cs.dl.util.concurrent.") ||
-      // System classes
-      classname.startsWith("org.apache.crimson") ||
-      classname.startsWith("org.apache.xalan") ||
-      classname.startsWith("org.apache.xml") ||
-      classname.startsWith("org.apache.xpath") ||
-      classname.startsWith("org.ietf.") ||
-      classname.startsWith("org.omg.") ||
-      classname.startsWith("org.w3c.") ||
-      classname.startsWith("org.xml.sax.") ||
-      classname.startsWith("sunw.") ||
-      classname.startsWith("sun.") ||
-      classname.startsWith("java.") ||
-      classname.startsWith("javax.") ||
-      classname.startsWith("com.sun.")
-      );
-   }
-
-   public byte[] transform(ClassLoader loader, String className, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer) throws IllegalClassFormatException
-   {
-      className = className.replace('/', '.');
-      System.out.println("<<< loading " + className + " " + loader);
-      try
-      {
-         if (classBeingRedefined != null || isNonAdvisableClassName(className))
-         {
-            //System.out.println(" ignoring");
-            return null;
-         }
-         //System.out.println(" transforming");
-         return aspectTransform(className, loader, classBeingRedefined, protectionDomain, classfileBuffer);
-      }
-      catch(Exception e)
-      {
-         return null;
-      }
-      finally
-      {
-         //System.out.println("finished " + className + ">>>");
-      }
-   }
-
-   private byte[] aspectTransform(String className, ClassLoader loader, Class<?> classBeingRedefined, ProtectionDomain protectionDomain, byte[] classfileBuffer)
-   {
-      try
-      {
-         //Make sure that we use the correct classloader, in order to get the correct domain if it is a scoped loader
-         AspectManager manager = AspectManager.instance();
-         AOPClassPool pool = (AOPClassPool) manager.registerClassLoader(loader);
-         
-         CtClass clazz = pool.getLocally(className);
-         
-         createFieldWrappers(pool, clazz);
-         convertReferences(pool, clazz);
-         clazz.debugWriteFile();
-         return clazz.toBytecode();
-         
-      }
-      catch (Exception e)
-      {
-         System.err.println("Error " + e.getMessage());
-         e.printStackTrace();
-         throw new RuntimeException(e);
-      }
-   }
-   
-   private void createFieldWrappers(AOPClassPool pool, CtClass clazz) throws Exception
-   {
-      CtClass objectClass = pool.get("java.lang.Object");
-      CtField[] fields = clazz.getFields();
-      for (int i = 0 ; i < fields.length ; i++)
-      {
-         if (isAdvisableSimpleField(fields[i]))
-         {
-            CtMethod write = CtNewMethod.make(
-                  Modifier.STATIC, 
-                  CtClass.voidType, 
-                  getWriteWrapperName(fields[i]), 
-                  new CtClass[] {objectClass, fields[i].getType()}, 
-                  new CtClass[0],
-                  !Modifier.isStatic(fields[i].getModifiers()) ?
-                        "{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_written = true; ((" + clazz.getName() + ")$1)." + fields[i].getName() + "= $2;}" :
-                        "{" + clazz.getName() + "." + fields[i].getName() + "_written = true; " + clazz.getName() + "." + fields[i].getName() + "= $2;}",
-                  fields[i].getDeclaringClass());
-            fields[i].getDeclaringClass().addMethod(write);
-            
-            CtMethod read = CtNewMethod.make(
-                  Modifier.STATIC, 
-                  fields[i].getType(), 
-                  getReadWrapperName(fields[i]), 
-                  new CtClass[] {objectClass}, 
-                  new CtClass[0],
-                  !Modifier.isStatic(fields[i].getModifiers()) ?
-                        "{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_read = true; return ((" + clazz.getName() + ")$1)." + fields[i].getName() + ";}" :
-                        "{" + clazz.getName() + "." + fields[i].getName() + "_read = true; return " + clazz.getName() + "." + fields[i].getName() + ";}",
-                  fields[i].getDeclaringClass());
-            fields[i].getDeclaringClass().addMethod(read);
-         }
-//         if (isAdvisableArrayField(fields[i]))
-//         {
-//            //Create read method
-//            CtClass componentType = fields[i].getType();
-//            while (componentType.isArray())
-//            {
-//               componentType = componentType.getComponentType();
-//            }
-//
-//            CtClass[] readParameters = new CtClass[3];
-//            readParameters[0] = objectClass;
-//            readParameters[1] = fields[i].getType();
-//            readParameters[2] = CtClass.intType;
-//            StringBuffer readBody = new StringBuffer("{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_read_index=$3; return ((" + clazz.getName() + ")$1)." + fields[i].getName() + "[$3];}");
-//            
-//            System.out.println("READ BODY-----> " + readBody);
-//            
-//            CtMethod read = CtNewMethod.make(
-//                  Modifier.STATIC, 
-//                  componentType, 
-//                  getArrayReadWrapperName(fields[i]), 
-//                  readParameters, 
-//                  new CtClass[0],
-//                  readBody.toString(),
-//                  fields[i].getDeclaringClass());
-//            fields[i].getDeclaringClass().addMethod(read);
-//            
-//            //Create write method
-//            CtClass[] writeParameters = new CtClass[4];
-//            writeParameters[0] = objectClass;
-//            writeParameters[1] = fields[i].getType();
-//            writeParameters[2] = CtClass.intType;
-//            writeParameters[3] = componentType;
-//            StringBuffer writeBody = new StringBuffer("{((" + clazz.getName() + ")$1)." + fields[i].getName() + "_write_index=$3;((" + clazz.getName() + ")$1)." + fields[i].getName() + "_write_value=$4;((" + clazz.getName() + ")$1)." + fields[i].getName() + "[$3]=$4;}");
-//            
-//            System.out.println("WRITE BODY-----> " + writeBody);
-//            CtMethod write = CtNewMethod.make(
-//                  Modifier.STATIC, 
-//                  CtClass.voidType, 
-//                  getArrayWriteWrapperName(fields[i]), 
-//                  writeParameters, 
-//                  new CtClass[0],
-//                  writeBody.toString(),
-//                  fields[i].getDeclaringClass());
-//            fields[i].getDeclaringClass().addMethod(write);
-//         }
-      }
-   }
-   
-   private void convertReferences(AOPClassPool pool, CtClass clazz) throws Exception
-   {
-      boolean replaced = false;
-      Collection refClasses = clazz.getRefClasses();
-      for (Iterator it = refClasses.iterator() ; it.hasNext() ; )
-      {
-         String name = (String)it.next();
-         if (name.equals(clazz.getName()))
-         {
-            continue;
-         }
-         CtClass refClazz = pool.get(name);
-         
-         
-         CtField[] fields = refClazz.getFields();
-         CodeConverter converter = new CodeConverter();
-         for (int i = 0 ; i < fields.length ; i++)
-         {
-            if (isAdvisableSimpleField(fields[i]))
-            {
-               replaced = true;
-               converter.replaceFieldRead(fields[i], refClazz, getReadWrapperName(fields[i]));
-               converter.replaceFieldWrite(fields[i], refClazz, getWriteWrapperName(fields[i]));
-            }
-         }
-         
-         if (arrayClasses.contains(clazz.getName()))
-         {
-            replaced = true;
-            converter.replaceArrayAccess(pool.get(ArrayAdvisor.class.getName()), new DefaultMethodNames());
-         }
-
-         if (replaced)
-         {
-            clazz.instrument(converter);
-         }
-      }
-   }
-   
-   private String getWriteWrapperName(CtField field)
-   {
-      return "aop$_w_" + field.getName(); 
-   }
-   
-   private String getReadWrapperName(CtField field)
-   {
-      return "aop$_r_" + field.getName(); 
-   }
-
-//   private String getArrayWriteWrapperName(CtField field)
-//   {
-//      return "aop$_array_w_" + field.getName(); 
-//   }
-//   
-//   private String getArrayReadWrapperName(CtField field)
-//   {
-//      return "aop$_array_r_" + field.getName(); 
-//   }
-}

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Agent.java	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,46 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.aop.array;
-
-import org.jboss.aop.AspectManager;
-import org.jboss.aop.standalone.StandaloneClassPoolFactory;
-
-import java.lang.instrument.Instrumentation;
-
-/**
- * Comment
- *
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision: 46253 $
- */
-public class Agent
-{
-
-   public static void premain(String agentArgs, Instrumentation inst)
-   {
-      StandaloneClassPoolFactory factory = new StandaloneClassPoolFactory(); 
-      AspectManager.setClassPoolFactory(factory);
-      // necessary for configuration
-      AspectManager.instance();
-      inst.addTransformer(new AOPTransformer());
-   }
-}
\ No newline at end of file

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayTestCase.bak	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,91 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.test.aop.array;
-
-import org.jboss.test.aop.AOPTestWithSetup;
-
-import junit.framework.Test;
-import junit.framework.TestSuite;
-import junit.textui.TestRunner;
-
-
-/**
- * @author <a href="mailto:bill at jboss.org">Bill Burke</a>
- * @version $Revision: 45977 $
- */
-public class ArrayTestCase extends AOPTestWithSetup
-{
-   Main main = new Main();
-   public static void main(String[] args)
-   {
-      TestRunner.run(suite());
-   }
-
-   public static Test suite()
-   {
-      TestSuite suite = new TestSuite("ArrayTestCase");
-      suite.addTestSuite(ArrayTestCase.class);
-      return suite;
-   }
-
-   public ArrayTestCase(String name)
-   {
-      super(name);
-      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "field");
-      AOPTransformer.addSimpleField("org.jboss.test.aop.array.ClassWithSimpleFields", "staticfield");
-
-      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFields");
-      AOPTransformer.addArrayClass("org.jboss.test.aop.array.ClassWithArrayFieldCaller");
-   }
-
-   public void testSimpleField() throws Exception
-   {
-      main.testSimpleField();
-   }
-
-   
-   public void testArrayWrite() throws Exception
-   {
-      main.testArrayWrite();
-   }
-   
-   public void testArrayRead() throws Exception
-   {
-      main.testArrayRead();
-   }
-//   
-//   public void testArrayReadWriteSelf() throws Exception
-//   {
-//      main.testArrayReadWriteSelf();
-//   }
-//
-//   public void testArrayReadWriteFromNonAdvised() throws Exception
-//   {
-//      main.testArrayReadWriteFromNonAdvised();
-//   }
-//
-//   
-//   public void testArrayField() throws Exception
-//   {
-//      main.testArrayField();
-//   }
-}

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFieldCaller.bak	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,97 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-import java.lang.reflect.Array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class ClassWithArrayFieldCaller
-{
-   ClassWithArrayFields obj = new ClassWithArrayFields();
-   
-   public void testArrayWrite() throws Exception
-   {
-      ArrayAdvisor.clear();
-      obj.setValue(1, 100);
-      checkStatus(obj.ifield, 1, String.valueOf(100));
-      
-      ArrayAdvisor.clear();
-      obj.ifield[0] = 75;
-      checkStatus(obj.ifield, 0, String.valueOf(75));
-   }
-   
-   public void testArrayRead() throws Exception
-   {
-      obj.ifield[0] = 100;
-      obj.ifield[1] = 200;
-      
-      ArrayAdvisor.clear();
-      int val = obj.getValue(0);
-      if (val != 100) throw new RuntimeException("Wrong val " + 100);
-      checkStatus(obj.ifield, 0, String.valueOf(100));
-      
-      ArrayAdvisor.clear();
-      val = obj.ifield[1];
-      checkStatus(obj.ifield, 1, String.valueOf(200));
-   }
-
-   public void testDifferentTypes() throws Exception
-   {
-//      ArrayAdvisor.clear();
-//      obj.afield[1] = "Hello";
-//      checkStatus(obj.afield, 1, "Hello");
-//      ArrayAdvisor.clear();
-//      Object aval = obj.afield[1];
-//      if (!aval.equals("Hello")) throw new RuntimeException("Wrong val " + aval);
-//      checkStatus(obj.afield, 1, "Hello");
-//      
-//      ArrayAdvisor.clear();
-//      obj.bfield[2] = true;
-//
-//      ArrayAdvisor.clear();
-//      obj.cfield[1] = 'x';
-//      
-//      ArrayAdvisor.clear();
-//      obj.dfield[2] = 69.0d;
-//      
-//      
-//      ArrayAdvisor.clear();
-//      obj.ffield[1] = 3.9f;
-//      
-//      ArrayAdvisor.clear();
-//      obj.lfield[2] = 100L;
-//      
-//      ArrayAdvisor.clear();
-//      obj.sfield[1] = 5;
-   }
-  
-   private void checkStatus(Object array, int index, String value)
-   {
-      if (array != ArrayAdvisor.array) throw new RuntimeException("Wrong array " + ArrayAdvisor.array);
-      if (index != ArrayAdvisor.index) throw new RuntimeException("Wrong index " + ArrayAdvisor.index);
-      if (!value.equals(ArrayAdvisor.value)) throw new RuntimeException("Wrong string " + ArrayAdvisor.index);
-   }
-}
\ No newline at end of file

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFieldCaller.java	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,94 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class ClassWithSimpleFieldCaller
-{
-   ClassWithSimpleFields obj = new ClassWithSimpleFields();
-   public void testSimple() throws Exception
-   {
-      checkStatus("field", false, false);
-      obj.field = false;
-      checkStatus("field", true, false);
-      if (obj.field)
-      {
-         throw new RuntimeException("Should have been false!");
-      }
-      checkStatus("field", true, true);
-      boolean b = obj.field;
-   }
-
-   public void testSimpleNotCalled() throws Exception
-   {
-      obj.nonfield = false;
-      if (obj.nonfield)
-      {
-         throw new RuntimeException("Should have been false!");
-      }
-      boolean b = obj.nonfield;
-   }
-   
-   public void testSimpleStatic() throws Exception
-   {
-      checkStatus("staticfield", false, false);
-      ClassWithSimpleFields.staticfield = false;
-      checkStatus("staticfield", true, false);
-      if (obj.staticfield)
-      {
-         throw new RuntimeException("Should have been false!");
-      }
-      checkStatus("staticfield", true, true);
-      
-      boolean b = ClassWithSimpleFields.staticfield;
-   }
-
-   public void testSimpleStaticNotCalled() throws Exception
-   {
-      ClassWithSimpleFields.staticnonfield = false;
-      if (obj.nonfield)
-      {
-         throw new RuntimeException("Should have been false!");
-      }
-
-      boolean b = ClassWithSimpleFields.staticnonfield;
-   }
-   
-   private void checkStatus(String field, boolean written, boolean read)
-   {
-      if (field.equals("field"))
-      {
-         if (obj.field_written != written) throw new RuntimeException("Expected written " + written);
-         if (obj.field_read != read) throw new RuntimeException("Expected read " + read);
-      }
-      else if (field.equals("staticfield"))
-      {
-         if (obj.staticfield_written != written) throw new RuntimeException("Expected written " + written);
-         if (obj.staticfield_read != read) throw new RuntimeException("Expected read " + read);
-      }
-   }
-   
-}

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithSimpleFields.java	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,42 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class ClassWithSimpleFields
-{
-   public boolean field;
-   public boolean field_written;
-   public boolean field_read;
-   
-   public static boolean staticfield;
-   public static boolean staticfield_written;
-   public static boolean staticfield_read;
-   
-   
-   public boolean nonfield;
-   public static boolean staticnonfield;
-}

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak	2006-12-24 00:42:54 UTC (rev 59220)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/Main.bak	2006-12-24 10:56:21 UTC (rev 59221)
@@ -1,68 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class Main
-{
-   public Main()
-   {
-   }
-
-   public static void main(String[] args)throws Exception
-   {
-      Main main = new Main();
-      main.testSimpleField();
-      main.testArrayField();
-   }
-
-   public void testSimpleField() throws Exception
-   {
-      ClassWithSimpleFieldCaller caller = new ClassWithSimpleFieldCaller();
-      caller.testSimple();
-      caller.testSimpleStatic();
-   }
-
-   
-   public void testArrayField() throws Exception
-   {
-//      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
-//      caller.testArray();
-//      caller.testArrayStatic();
-   }
-   
-   public void testArrayWrite() throws Exception
-   {
-      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
-      caller.testArrayWrite();
-   }
-   
-   public void testArrayRead() throws Exception
-   {
-      ClassWithArrayFieldCaller caller = new ClassWithArrayFieldCaller();
-      caller.testArrayRead();
-   }
-}



From fdsia687564a at fastermail.com  Sun Dec 24 07:18:37 2006
From: fdsia687564a at fastermail.com (fdsia687564a at fastermail.com)
Date: Sun, 24 Dec 2006 07:18:37 -0500
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCJS8laiU5JV4lOSVXJWwlPCVzJUgbKEI=?=
	=?iso-2022-jp?b?GyRCR2MkQyQ/JE4kRzojJCskaTJxJCgkXiQ7JHMkKyEpGyhC?=
Message-ID: 20061224192825.87542mail@mail.mjiueysysusajsdjsaytuweriasjdasujsjasdnjan.com

??????????????????????
?????????????????????????????????
?????????????????
?????????????????????
?????????????????????????
????????
http://www.go-perfectfree.com.tonderuyo.com/hame/









???fdsia687564a at fastermail.com





From kkhan at jboss.com  Sun Dec 24 08:47:46 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Sun, 24 Dec 2006 08:47:46 -0500
Subject: [jboss-cvs] javassist/src/main/javassist  ...
Message-ID: <E1GyTha-0002jP-Oh@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/24 08:47:46

  Modified:    src/main/javassist  CodeConverter.java
  Log:
  Add ability to replace xASTORE and xALOAD calls with invokevirtual
  
  Revision  Changes    Path
  1.10      +7 -2      javassist/src/main/javassist/CodeConverter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CodeConverter.java
  ===================================================================
  RCS file: /cvsroot/jboss/javassist/src/main/javassist/CodeConverter.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- CodeConverter.java	23 Nov 2006 02:49:03 -0000	1.9
  +++ CodeConverter.java	24 Dec 2006 13:47:46 -0000	1.10
  @@ -17,6 +17,7 @@
   
   import javassist.bytecode.*;
   import javassist.convert.*;
  +import javassist.convert.TransformAccessArrayField.MethodNames;
   
   /**
    * Simple translator of method bodies
  @@ -202,6 +203,11 @@
                                                  calledMethod);
       }
   
  +    public void replaceArrayAccess(CtClass calledClass, MethodNames names) throws NotFoundException
  +    {
  +       transformers = new TransformAccessArrayField(transformers, calledClass.getName(), names);
  +    }
  +    
       /**
        * Modify method invocations in a method body so that a different
        * method will be invoked.
  @@ -366,7 +372,6 @@
           throws CannotCompileException
       {
           Transformer t;
  -
           CodeAttribute codeAttr = minfo.getCodeAttribute();
           if (codeAttr == null || transformers == null)
               return;
  
  
  


From kkhan at jboss.com  Sun Dec 24 08:47:46 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Sun, 24 Dec 2006 08:47:46 -0500
Subject: [jboss-cvs] javassist/src/main/javassist/convert  ...
Message-ID: <E1GyTha-0002jW-SL@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/24 08:47:46

  Added:       src/main/javassist/convert  TransformAccessArrayField.java
  Log:
  Add ability to replace xASTORE and xALOAD calls with invokevirtual
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 13:47:46;  author: kkhan;  state: Exp;javassist/src/main/javassist/convert/TransformAccessArrayField.java
  
  Index: TransformAccessArrayField.java
  ===================================================================
  /*
   * Javassist, a Java-bytecode translator toolkit.
   * Copyright (C) 1999-2006 Shigeru Chiba. All Rights Reserved.
   *
   * The contents of this file are subject to the Mozilla Public License Version
   * 1.1 (the "License"); you may not use this file except in compliance with
   * the License.  Alternatively, the contents of this file may be used under
   * the terms of the GNU Lesser General Public License Version 2.1 or later.
   *
   * Software distributed under the License is distributed on an "AS IS" basis,
   * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
   * for the specific language governing rights and limitations under the
   * License.
   */
  package javassist.convert;
  
  
  import javassist.CtClass;
  import javassist.NotFoundException;
  import javassist.bytecode.BadBytecode;
  import javassist.bytecode.CodeIterator;
  import javassist.bytecode.ConstPool;
  
  /**
   *  
   * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
   * @version $Revision: 1.1 $ 
   */
  public class TransformAccessArrayField extends Transformer 
  {
  //   CtClass componentType;
  
     String methodClassname;
     MethodNames names;
  
     public TransformAccessArrayField(Transformer next, String methodClassname, MethodNames names) throws NotFoundException
     {
         super(next);
         this.methodClassname = methodClassname;
         this.names = names;
     }
  
     public int transform(CtClass tclazz, int pos, CodeIterator iterator, ConstPool cp) throws BadBytecode
     {
        int c = iterator.byteAt(pos);
        
        if (c == AALOAD || c == BALOAD || c == CALOAD || c == DALOAD || c == FALOAD || c == IALOAD || c == LALOAD || c == SALOAD) 
        {
           replace(cp, iterator, pos, c, getLoadReplacementSignature(c));
        }
        else if (c == AASTORE || c == BASTORE || c == CASTORE || c == DASTORE || c == FASTORE || c == IASTORE || c == LASTORE || c == SASTORE)
        {
           replace(cp, iterator, pos, c, getStoreReplacementSignature(c));
        }
  
        return pos;
     }
     
     private void replace(ConstPool cp, CodeIterator iterator, int pos, int opcode, String signature) throws BadBytecode
     {
        String methodName = getMethodName(opcode);
        if (methodName != null)
        {
           iterator.insertGap(2);
           int mi = cp.addClassInfo(methodClassname);
           int methodref = cp.addMethodrefInfo(mi, methodName, signature);
           iterator.writeByte(INVOKESTATIC, pos);
           iterator.write16bit(methodref, pos + 1);
        }
     }
  
     private String getMethodName(int opcode)
     {
        String methodName = null;
        switch(opcode)
        {
           case AALOAD:
              methodName = names.objectRead();
              break;
           case BALOAD:
              methodName = names.byteOrBooleanRead();
              break;
           case CALOAD:
              methodName = names.charRead();
              break;
           case DALOAD:
              methodName = names.doubleRead();
              break;
           case FALOAD:
              methodName = names.floatRead();
              break;
           case IALOAD:
              methodName = names.intRead();
              break;
           case SALOAD:
              methodName = names.shortRead();
              break;
           case LALOAD:
              methodName = names.longRead();
              break;
           case AASTORE:
              methodName = names.objectWrite();
              break;
           case BASTORE:
              methodName = names.byteOrBooleanWrite();
              break;
           case CASTORE:
              methodName = names.charWrite();
              break;
           case DASTORE:
              methodName = names.doubleWrite();
              break;
           case FASTORE:
              methodName = names.floatWrite();
              break;
           case IASTORE:
              methodName = names.intWrite();
              break;
           case SASTORE:
              methodName = names.shortWrite();
              break;
           case LASTORE:
              methodName = names.longWrite();
              break;
        }
        
        if (methodName.equals(""))
        {
           methodName = null;
        }
        return methodName;
     }
  
     private String getLoadReplacementSignature(int opcode) throws BadBytecode
     {
        switch(opcode) 
        {
           case AALOAD:
              return "(Ljava/lang/Object;I)Ljava/lang/Object;";
           case BALOAD:
              return "(Ljava/lang/Object;I)B";
           case CALOAD:
              return "(Ljava/lang/Object;I)C";
           case DALOAD:
              return "(Ljava/lang/Object;I)D";
           case FALOAD:
              return "(Ljava/lang/Object;I)F";
           case IALOAD:
              return "(Ljava/lang/Object;I)I";
           case SALOAD:
              return "(Ljava/lang/Object;I)S";
           case LALOAD:
              return "(Ljava/lang/Object;I)J";
        }      
        
        throw new BadBytecode(opcode);
     }
     
     private String getStoreReplacementSignature(int opcode) throws BadBytecode
     {
        switch(opcode) 
        {
           case AASTORE:
              return "(Ljava/lang/Object;ILjava/lang/Object;)V";
           case BASTORE:
              return "(Ljava/lang/Object;IB)V";
           case CASTORE:
              return "(Ljava/lang/Object;IC)V";
           case DASTORE:
              return "(Ljava/lang/Object;ID)V";
           case FASTORE:
              return "(Ljava/lang/Object;IF)V";
           case IASTORE:
              return "(Ljava/lang/Object;II)V";
           case SASTORE:
              return "(Ljava/lang/Object;IS)V";
           case LASTORE:
              return "(Ljava/lang/Object;IJ)V";
        }      
        throw new BadBytecode(opcode);
     }
     
     public interface MethodNames
     {
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)Ljava/lang/Object;
         */
        String objectRead();
        
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)B"
         */
        String byteOrBooleanRead();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)C
         */
        String charRead();
        
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)D
         */
        String doubleRead();
        
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)F
         */
        String floatRead();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)I
         */
        String intRead();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)J
         */
        String longRead();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;I)S
         */
        String shortRead();
        
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;ILjava/lang/Object;)V
         */      
        String objectWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;IB)V
         */      
        String byteOrBooleanWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;IC)V
         */      
        String charWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;ID)V
         */      
        String doubleWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;IF)V
         */      
        String floatWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;II)V
         */      
        String intWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;IJ)V
         */      
        String longWrite();
  
        /**
         * Give the name of a static method with the signature (Ljava/lang/Object;IS)V
         */      
        String shortWrite();
     }
     
     public static class DefaultMethodNames implements MethodNames
     {
        public String byteOrBooleanRead()
        {
           return "arrayReadByteOrBoolean";
        }
  
        public String byteOrBooleanWrite()
        {
           return "arrayWriteByteOrBoolean";
        }
  
        public String charRead()
        {
           return "arrayReadChar";
        }
  
        public String charWrite()
        {
           return "arrayWriteChar";
        }
  
        public String doubleRead()
        {
           return "arrayReadDouble";
        }
  
        public String doubleWrite()
        {
           return "arrayWriteDouble";
        }
  
        public String floatRead()
        {
           return "arrayReadFloat";
        }
  
        public String floatWrite()
        {
           return "arrayWriteFloat";
        }
  
        public String intRead()
        {
           return "arrayReadInt";
        }
  
        public String intWrite()
        {
           return "arrayWriteInt";
        }
  
        public String longRead()
        {
           return "arrayReadLong";
        }
  
        public String longWrite()
        {
           return "arrayWriteLong";
        }
  
        public String objectRead()
        {
           return "arrayReadObject";
        }
  
        public String objectWrite()
        {
           return "arrayWriteObject";
        }
  
        public String shortRead()
        {
           return "arrayReadShort";
        }
  
        public String shortWrite()
        {
           return "arrayWriteShort";
        }
        
     }
  }
  
  
  


From kkhan at jboss.com  Sun Dec 24 08:51:38 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Sun, 24 Dec 2006 08:51:38 -0500
Subject: [jboss-cvs] repository.jboss.com/javassist/snapshot/lib  ...
Message-ID: <E1GyTlK-0002n3-Ur@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/24 08:51:38

  Modified:    javassist/snapshot/lib  javassist.jar
  Log:
  Add snapshot containing ability to replace xALOAD and xASTORE with INVOKEVIRTUAL
  
  Revision  Changes    Path
  1.10      +948 -919  repository.jboss.com/javassist/snapshot/lib/javassist.jar
  
  	<<Binary file>>
  
  


From kkhan at jboss.com  Sun Dec 24 08:53:09 2006
From: kkhan at jboss.com (Kabir Khan)
Date: Sun, 24 Dec 2006 08:53:09 -0500
Subject: [jboss-cvs] javassist/src/main/META-INF  ...
Message-ID: <E1GyTmn-0002oW-7f@committer01.frg.pub.inap.atl.jboss.com>

  User: kkhan   
  Date: 06/12/24 08:53:09

  Modified:    src/main/META-INF  MANIFEST.MF
  Log:
  bump up version to snapshot
  
  Revision  Changes    Path
  1.18      +1 -1      javassist/src/main/META-INF/MANIFEST.MF
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MANIFEST.MF
  ===================================================================
  RCS file: /cvsroot/jboss/javassist/src/main/META-INF/MANIFEST.MF,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- MANIFEST.MF	16 Nov 2006 14:39:56 -0000	1.17
  +++ MANIFEST.MF	24 Dec 2006 13:53:09 -0000	1.18
  @@ -2,7 +2,7 @@
   Specification-Title: Javassist
   Created-By: Shigeru Chiba, Tokyo Institute of Technology
   Specification-Vendor: Shigeru Chiba, Tokyo Institute of Technology
  -Specification-Version: 3.4
  +Specification-Version: snapshot
   Main-Class: javassist.CtClass
   
   Name: javassist/
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 24 08:53:31 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 24 Dec 2006 08:53:31 -0500
Subject: [jboss-cvs] JBossAS SVN: r59222 -
	projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins
Message-ID: <E1GyTn9-0002of-67@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-24 08:53:26 -0500 (Sun, 24 Dec 2006)
New Revision: 59222

Modified:
   projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java
Log:
autoboxing

Modified: projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java
===================================================================
--- projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java	2006-12-24 10:56:21 UTC (rev 59221)
+++ projects/microcontainer/trunk/managed/src/main/org/jboss/managed/plugins/ManagedPropertyImpl.java	2006-12-24 13:53:26 UTC (rev 59222)
@@ -174,7 +174,7 @@
       Boolean result = getField(Fields.MANDATORY, Boolean.class);
       if (result == null)
          return false;
-      return result.booleanValue();
+      return result;
    }
 
    @Override



From jboss-cvs-commits at lists.jboss.org  Sun Dec 24 08:56:43 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 24 Dec 2006 08:56:43 -0500
Subject: [jboss-cvs] JBossAS SVN: r59223 - in projects/aop/branches/arrays:
	aop/src/main/org/jboss/aop/array
	aop/src/main/org/jboss/aop/instrument
	aop/src/test/org/jboss/test/aop/array build
Message-ID: <E1GyTqF-0002sS-Go@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-24 08:56:30 -0500 (Sun, 24 Dec 2006)
New Revision: 59223

Added:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteBooleanConverter.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementReadInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithUnadvisedArrayFields.java
Removed:
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java
Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
   projects/aop/branches/arrays/build/build-thirdparty.xml
Log:
We are now able to intercept element accesses in all kinds of arrays.
Make use javassist snapshot

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -55,21 +55,20 @@
       ArrayRegistry registry = ArrayRegistry.getInstance();
       if (registry.isRegistered(array))
       {
-         System.out.println("---------> Writing" + array + " advised");
+         //The old value might be an array, remove references to that
+         Object oldValue = ((Object[])array)[index];
+         registry.removeElementReference(array, index, oldValue);
          
+         //The new value might be an array
          if (value.getClass().isArray())
          {
-            Object oldValue = ((Object[])array)[index];
-            registry.removeElementReference(array, index, oldValue);
             registry.addElementReference(array, index, value);
-         
          }
          ObjectArrayElementWriteInvocation invocation = new ObjectArrayElementWriteInvocation(interceptors, (Object[])array, index, value);
          invocation.invokeNext();
       }
       else
       {
-         System.out.println("---------> Writing" + array + " not advised");
          ((Object[])array)[index] = value;
       }
    }
@@ -78,7 +77,6 @@
    {
       if (ArrayRegistry.getInstance().isRegistered(array))
       {
-         System.out.println("---------> Writing" + array + " advised");
          IntArrayElementWriteInvocation invocation = new IntArrayElementWriteInvocation(interceptors, ((int[])array), index, value);
          invocation.invokeNext();
       }
@@ -88,57 +86,99 @@
       }
    }
 
-   //Write operations
-//   public static void arrayWrite(boolean[] array, int index, boolean value)
-//   {
-//      array[index] = value; 
-//   }
-//
-//   public static void arrayWrite(short[] array, int index, short value)
-//   {
-//      array[index] = value; 
-//   }
-//
-//   
-//   public static void arrayWrite(long[] array, int index, long value)
-//   {
-//      array[index] = value; 
-//   }
-//   
-//   public static void arrayWrite(float[] array, int index, float value)
-//   {
-//      array[index] = value; 
-//   }
-//   
-//   public static void arrayWrite(double[] array, int index, double value)
-//   {
-//      array[index] = value; 
-//   }
-//   
-//   public static void arrayWrite(char[] array, int index, char value)
-//   {
-//      array[index] = value; 
-//   }
-//   
-//   public static void arrayWrite(Object[] array, int index, Object value)
-//   {
-//      array[index] = value; 
-//   }
+   public static void arrayWriteByteOrBoolean(Object array, int index, byte value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         if (array instanceof boolean[])
+         {
+            BooleanArrayElementWriteInvocation invocation = new BooleanArrayElementWriteInvocation(interceptors, ((boolean[])array), index, ByteBooleanConverter.toBoolean(value));
+            invocation.invokeNext();
+         }
+         else
+         {
+            ByteArrayElementWriteInvocation invocation = new ByteArrayElementWriteInvocation(interceptors, ((byte[])array), index, value);
+            invocation.invokeNext();
+         }
+      }
+      else
+      {
+         if (array instanceof boolean[])
+         {
+            ((boolean[])array)[index] = ByteBooleanConverter.toBoolean(value);
+         }
+         else
+         {
+            ((byte[])array)[index] = value;
+         }
+      }
+   }
 
-   //Read operations
-//   public static boolean arrayRead(boolean[] array, int index)
-//   {
-//      
-//      boolean value = array[index];
-//      return value;
-//   }
-//
-//   public static short arrayRead(short[] array, int index)
-//   {
-//      short value = array[index];
-//      return value;
-//   }
-//
+   public static void arrayWriteChar(Object array, int index, char value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         CharArrayElementWriteInvocation invocation = new CharArrayElementWriteInvocation(interceptors, ((char[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((char[])array)[index] = value;
+      }
+   }
+
+   public static void arrayWriteDouble(Object array, int index, double value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         DoubleArrayElementWriteInvocation invocation = new DoubleArrayElementWriteInvocation(interceptors, ((double[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((double[])array)[index] = value;
+      }
+   }
+
+   public static void arrayWriteShort(Object array, int index, short value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         ShortArrayElementWriteInvocation invocation = new ShortArrayElementWriteInvocation(interceptors, ((short[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((short[])array)[index] = value;
+      }
+   }
+
+   public static void arrayWriteFloat(Object array, int index, float value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         FloatArrayElementWriteInvocation invocation = new FloatArrayElementWriteInvocation(interceptors, ((float[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((float[])array)[index] = value;
+      }
+   }
+
+   public static void arrayWriteLong(Object array, int index, long value) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         LongArrayElementWriteInvocation invocation = new LongArrayElementWriteInvocation(interceptors, ((long[])array), index, value);
+         invocation.invokeNext();
+      }
+      else
+      {
+         ((long[])array)[index] = value;
+      }
+   }
+
    public static Object arrayReadObject(Object array, int index) throws Throwable
    {
       if (ArrayRegistry.getInstance().isRegistered(array))
@@ -165,35 +205,97 @@
       }
    }
 
-//   
-//   public static long arrayRead(long[] array, int index)
-//   {
-//      long value = array[index];
-//      return value;
-//   }
-//   
-//   public static float arrayRead(float[] array, int index)
-//   {
-//      float value = array[index];
-//      return value;
-//   }
-//   
-//   public static double arrayRead(double[] array, int index)
-//   {
-//      double value = array[index];
-//      return value;
-//   }
-//   
-//   public static char arrayRead(char[] array, int index)
-//   {
-//      char value = array[index];
-//      return value;
-//   }
-//   
-//   public static Object arrayRead(Object[] array, int index)
-//   {
-//      Object value = array[index];
-//      return value;
-//   }
+   public static byte arrayReadByteOrBoolean(Object array, int index) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         if (array instanceof boolean[])
+         {
+            BooleanArrayElementReadInvocation invocation = new BooleanArrayElementReadInvocation(interceptors, (boolean[])array, index);
+            boolean b = ((Boolean)invocation.invokeNext()).booleanValue();
+            return ByteBooleanConverter.toByte(b);
+         }
+         else
+         {
+            ByteArrayElementReadInvocation invocation = new ByteArrayElementReadInvocation(interceptors, (byte[])array, index);
+            return ((Byte)invocation.invokeNext()).byteValue();
+         }
+      }
+      else
+      {
+         if (array instanceof boolean[])
+         {
+            return ByteBooleanConverter.toByte(((boolean[])array)[index]);
+         }
+         else
+         {
+            return ((byte[])array)[index];
+         }
+      }
+   }
 
+   public static char arrayReadChar(Object array, int index) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         CharArrayElementReadInvocation invocation = new CharArrayElementReadInvocation(interceptors, (char[])array, index);
+         return ((Character)invocation.invokeNext()).charValue();
+      }
+      else
+      {
+         return ((char[])array)[index];
+      }
+   }
+
+   public static double arrayReadDouble(Object array, int index) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         DoubleArrayElementReadInvocation invocation = new DoubleArrayElementReadInvocation(interceptors, (double[])array, index);
+         return ((Double)invocation.invokeNext()).doubleValue();
+      }
+      else
+      {
+         return ((double[])array)[index];
+      }
+   }
+
+   public static float arrayReadFloat(Object array, int index) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         FloatArrayElementReadInvocation invocation = new FloatArrayElementReadInvocation(interceptors, (float[])array, index);
+         return ((Float)invocation.invokeNext()).floatValue();
+      }
+      else
+      {
+         return ((float[])array)[index];
+      }
+   }
+
+   public static long arrayReadLong(Object array, int index) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         LongArrayElementReadInvocation invocation = new LongArrayElementReadInvocation(interceptors, (long[])array, index);
+         return ((Long)invocation.invokeNext()).longValue();
+      }
+      else
+      {
+         return ((long[])array)[index];
+      }
+   }
+
+   public static short arrayReadShort(Object array, int index) throws Throwable
+   {
+      if (ArrayRegistry.getInstance().isRegistered(array))
+      {
+         ShortArrayElementReadInvocation invocation = new ShortArrayElementReadInvocation(interceptors, (short[])array, index);
+         return ((Short)invocation.invokeNext()).shortValue();
+      }
+      else
+      {
+         return ((short[])array)[index];
+      }
+   }
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -51,7 +51,6 @@
    
    public void addFieldReference(Object owner, String fieldName, Object array)
    {
-      System.out.println("----> Adding " + array + " to " + owner);
       if (array == null)
       {
          return;
@@ -117,7 +116,6 @@
 
    public void addElementReference(Object owner, int index, Object array)
    {
-      System.out.println("----> Adding " + array + " to " + owner);
       if (array == null)
       {
          return;
@@ -151,7 +149,6 @@
    
    public void removeElementReference(Object owner, int index, Object array)
    {
-      System.out.println("----> Removing " + array + " from " + owner);
       if (array == null)
       {
          return;
@@ -256,31 +253,14 @@
       }
    }
    
-   private boolean isArray(Object array)
+   private boolean isArray(Object arrayCandidate)
    {
-      Class componentType = array.getClass().getComponentType();
-      return componentType.isArray();
+      Class candidateClass = arrayCandidate.getClass();
+      if (candidateClass.isArray())
+      {
+         Class componentType = candidateClass.getComponentType();
+         return componentType.isArray();
+      }
+      return false;
    }
-   
-   public void dumpCache()
-   {
-//      System.out.println(cache);
-   }
-//    
-//   public static void main(String[] args)
-//   {
-//      ArrayRegistry registry = getInstance();
-//      
-//      System.out.println("============== 1 dim");
-//      int[] dim1 = new int[] {1,2,3};
-//      registry.addNestedArrays(dim1);
-//      
-//      System.out.println("============== 2 dim");
-//      int[][] dim2 = new int[][] {new int[] {1,2}, new int[] {1,2}};
-//      registry.addNestedArrays(dim2);
-//      
-//      System.out.println("============== 3 dim");
-//      int[][][] dim3 = new int[][][] {new int[][] {new int[] {1,2},new int[] {1,2}}, new int[][] {new int[] {1,2},new int[] {1,2}}};
-//      registry.addNestedArrays(dim3);
-//   }
 }

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class BooleanArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = 4894358007089083877L;
+   boolean[] array;
+   
+   public BooleanArrayElementReadInvocation(Interceptor[] interceptors, boolean[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Boolean(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/BooleanArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class BooleanArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = -8806734067322751711L;
+   boolean[] array;
+   boolean value;
+   
+   public BooleanArrayElementWriteInvocation(Interceptor[] interceptors, boolean[] target, int index, boolean value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Boolean(value);
+   }
+
+   public boolean getBooleanValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ByteArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = 407921822383443705L;
+   byte[] array;
+   
+   public ByteArrayElementReadInvocation(Interceptor[] interceptors, byte[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Byte(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ByteArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = -3311231820298166088L;
+   byte[] array;
+   byte value;
+   
+   public ByteArrayElementWriteInvocation(Interceptor[] interceptors, byte[] target, int index, byte value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Byte(value);
+   }
+
+   public byte getByteValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteBooleanConverter.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteBooleanConverter.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ByteBooleanConverter.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ByteBooleanConverter
+{
+   private static final byte BOOLEAN_FALSE = 0;
+   private static final byte BOOLEAN_TRUE = 1;
+   
+   public static byte toByte(boolean b)
+   {
+      return (b) ? BOOLEAN_TRUE : BOOLEAN_FALSE;
+   }
+   
+   public static boolean toBoolean(byte b)
+   {
+      if (b == BOOLEAN_FALSE) return false;
+      else if (b == BOOLEAN_TRUE) return true;
+      
+      throw new RuntimeException("Invalid byte " + b + " cannot be converted to a boolean");
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class CharArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = -8421466785835226302L;
+   char[] array;
+   
+   public CharArrayElementReadInvocation(Interceptor[] interceptors, char[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Character(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/CharArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class CharArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = -7731135396849504354L;
+   char[] array;
+   char value;
+   
+   public CharArrayElementWriteInvocation(Interceptor[] interceptors, char[] target, int index, char value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Character(value);
+   }
+
+   public char getCharValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class DoubleArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = 4414714543578046462L;
+   double[] array;
+   
+   public DoubleArrayElementReadInvocation(Interceptor[] interceptors, double[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Double(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/DoubleArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class DoubleArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = 4952638087031381514L;
+   double[] array;
+   double value;
+   
+   public DoubleArrayElementWriteInvocation(Interceptor[] interceptors, double[] target, int index, double value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Double(value);
+   }
+
+   public double getDoubleValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class FloatArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = 1588317122571729022L;
+   float[] array;
+   
+   public FloatArrayElementReadInvocation(Interceptor[] interceptors, float[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Float(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FloatArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class FloatArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = 2124265298388536292L;
+   float[] array;
+   float value;
+   
+   public FloatArrayElementWriteInvocation(Interceptor[] interceptors, float[] target, int index, float value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Float(value);
+   }
+
+   public float getFloatValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class LongArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = -6196706501416214971L;
+   long[] array;
+   
+   public LongArrayElementReadInvocation(Interceptor[] interceptors, long[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Long(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/LongArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class LongArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = -609480261599580470L;
+   long[] array;
+   long value;
+   
+   public LongArrayElementWriteInvocation(Interceptor[] interceptors, long[] target, int index, long value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Long(value);
+   }
+
+   public long getLongValue()
+   {
+      return value;
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementReadInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementReadInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementReadInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,46 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ShortArrayElementReadInvocation extends ArrayElementReadInvocation
+{
+   private static final long serialVersionUID = -6743791579057380824L;
+   short[] array;
+   
+   public ShortArrayElementReadInvocation(Interceptor[] interceptors, short[] target, int index)
+   {
+      super(interceptors, target, index);
+      array = target;
+   }
+
+   public Object invokeTarget()
+   {
+      return new Short(array[index]);
+   }
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ShortArrayElementWriteInvocation extends ArrayElementWriteInvocation
+{
+   private static final long serialVersionUID = -8003520567342434348L;
+   short[] array;
+   short value;
+   
+   public ShortArrayElementWriteInvocation(Interceptor[] interceptors, short[] target, int index, short value)
+   {
+      super(interceptors, target, index);
+      this.value = value;
+      this.array = target;
+   }
+
+   @Override
+   public Object invokeTarget()
+   {
+      array[index] = value;
+      return null;
+   }
+
+   @Override
+   public Object getValue()
+   {
+      return new Short(value);
+   }
+
+   public float getShortValue()
+   {
+      return value;
+   }
+}

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/Instrumentor.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -964,7 +964,7 @@
 
       if (shouldReplaceArrayAccess)
       {
-         System.out.println("---> Should replace access for " + clazz.getName());
+         if (AspectManager.verbose) System.out.println("[debug] Replacing array access in " + clazz.getName());
          converter.replaceArrayAccess(classPool.get(ArrayAdvisor.class.getName()), new DefaultMethodNames());
       }
       return shouldReplaceArrayAccess;

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -47,24 +47,162 @@
       return suite;
    }
 
+   public void testObjectArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.objects[2] = "X";
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertEquals("X", TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      Object o = obj.objects[0];
+      assertEquals("1", o);
+      assertEquals(0, TestArrayElementInterceptor.index);
+   }
+   
    public void testIntArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
-      obj.ifield[1] = 100; 
+      obj.ints[1] = 100; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(100, ((Integer)TestArrayElementInterceptor.value).intValue());
 
-      obj.ifield[2] = 123;
+      obj.ints[2] = 123;
       
       TestArrayElementInterceptor.clear();
-      int val = obj.ifield[2];
+      int val = obj.ints[2];
       assertEquals(123, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
    }
    
+   public void testByteArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.bytes[1] = 100; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(100, ((Byte)TestArrayElementInterceptor.value).byteValue());
+
+      obj.bytes[2] = 123;
+      
+      TestArrayElementInterceptor.clear();
+      byte val = obj.bytes[2];
+      assertEquals(123, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testBooleanArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.booleans[1] = false; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(false, ((Boolean)TestArrayElementInterceptor.value).booleanValue());
+
+      TestArrayElementInterceptor.clear();
+      boolean val = obj.booleans[1];
+      assertEquals(false, val);
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testCharArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.chars[1] = 'z'; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals('z', ((Character)TestArrayElementInterceptor.value).charValue());
+
+      obj.chars[2] = 'x';
+      
+      TestArrayElementInterceptor.clear();
+      char val = obj.chars[2];
+      assertEquals('x', val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+
+   public void testDoubleArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.doubles[1] = 2.1d; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(2.1d, ((Double)TestArrayElementInterceptor.value).doubleValue());
+
+      obj.doubles[2] = 9.9d;
+      
+      TestArrayElementInterceptor.clear();
+      double val = obj.doubles[2];
+      assertEquals(9.9d, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testFloatArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.floats[1] = 2.1f; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(2.1f, ((Float)TestArrayElementInterceptor.value).floatValue());
+
+      obj.floats[2] = 9.9f;
+      
+      TestArrayElementInterceptor.clear();
+      double val = obj.floats[2];
+      assertEquals(9.9f, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testLongArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.longs[1] = 100L; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(100L, ((Long)TestArrayElementInterceptor.value).longValue());
+
+      obj.longs[2] = 200L;
+      
+      TestArrayElementInterceptor.clear();
+      double val = obj.longs[2];
+      assertEquals(200L, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testShortArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      TestArrayElementInterceptor.clear();
+      obj.shorts[1] = 50; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNotNull(TestArrayElementInterceptor.value);
+      assertEquals(50, ((Short)TestArrayElementInterceptor.value).shortValue());
+
+      obj.shorts[2] = 100;
+      
+      TestArrayElementInterceptor.clear();
+      double val = obj.shorts[2];
+      assertEquals(100, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
    public void testMultiDimensionalTopLevelArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
@@ -77,23 +215,23 @@
 
       //Store reference to array to be replaced
       TestArrayElementInterceptor.clear();
-      int[][] original_0 = obj.iiifield[0];
+      int[][] original_0 = obj.ints3d[0];
       assertEquals(0, TestArrayElementInterceptor.index);
       
       //Replace array in top-level array, interception should happen now
       TestArrayElementInterceptor.clear();
-      obj.iiifield[0] = replacement0;
+      obj.ints3d[0] = replacement0;
       assertEquals(0, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(replacement0, TestArrayElementInterceptor.value);
       
       TestArrayElementInterceptor.clear();
-      int i = obj.iiifield[0][0][1];
+      int i = obj.ints3d[0][0][1];
       assertEquals(1, TestArrayElementInterceptor.index);
       assertEquals(22, i);
       
       TestArrayElementInterceptor.clear();
-      obj.iiifield[0][0][1] = 99;
+      obj.ints3d[0][0][1] = 99;
       assertEquals(1, TestArrayElementInterceptor.index);
       assertEquals(99, ((Integer)TestArrayElementInterceptor.value).intValue());
       
@@ -120,23 +258,23 @@
 
       //Store reference to array to be replaced
       TestArrayElementInterceptor.clear();
-      int[] original_0_1 = obj.iiifield[0][1];
+      int[] original_0_1 = obj.ints3d[0][1];
       assertEquals(1, TestArrayElementInterceptor.index);
 
       //Replace nested array, interception should happen now
       TestArrayElementInterceptor.clear();
-      obj.iiifield[0][1] = replacement_0_1;
+      obj.ints3d[0][1] = replacement_0_1;
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(replacement_0_1, TestArrayElementInterceptor.value);
       
       TestArrayElementInterceptor.clear();
-      int i = obj.iiifield[0][1][2];
+      int i = obj.ints3d[0][1][2];
       assertEquals(2, TestArrayElementInterceptor.index);
       assertEquals(333, i);
 
       TestArrayElementInterceptor.clear();
-      obj.iiifield[0][0][1] = 99;
+      obj.ints3d[0][0][1] = 99;
       assertEquals(1, TestArrayElementInterceptor.index);
       assertEquals(99, ((Integer)TestArrayElementInterceptor.value).intValue());
       
@@ -302,5 +440,86 @@
       i = original[1];
       assertEquals(-1, TestArrayElementInterceptor.index);
    }
+
+   public void testObjectArrayWithArrayAsObjectEntry()
+   {
+      int[] replacement = new int[] {1,2,3};
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      
+      //Add an array as one of the elements in the object array
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = replacement;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(replacement, TestArrayElementInterceptor.value);
+      
+      //The sub array should be advised
+      TestArrayElementInterceptor.clear();
+      replacement[1] = 5;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(5, ((Integer)TestArrayElementInterceptor.value).intValue());
+      
+      //Put in a string object
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = "X";
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals("X", TestArrayElementInterceptor.value);
+      
+      //The nested array no longer is associated with array and should be unadvised
+      TestArrayElementInterceptor.clear();
+      replacement[1] = 10;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertEquals(null, TestArrayElementInterceptor.value);
+      
+   }
    
+   public void testUnadvisedArrayFields()
+   {
+      ClassWithUnadvisedArrayFields obj = new ClassWithUnadvisedArrayFields();
+
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = "X";
+      assertEquals("X", obj.objects[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.bytes[0] = 1;
+      assertEquals(1, obj.bytes[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.booleans[0] = true;
+      assertEquals(true, obj.booleans[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.chars[0] = 'z';
+      assertEquals('z', obj.chars[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.doubles[0] = 9.9d;
+      assertEquals(9.9d, obj.doubles[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.floats[0] = 9.9f;
+      assertEquals(9.9f, obj.floats[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.ints[0] = 100;
+      assertEquals(100, obj.ints[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.longs[0] = 100;
+      assertEquals(100, obj.longs[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      obj.shorts[0] = 100;
+      assertEquals(100, obj.shorts[0]);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+
+   }
 }

Deleted: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayAdvisor.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -1,157 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.test.aop.array;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class ArrayAdvisor
-{
-   public static Object array;
-   public static String value;
-   public static int index;
-   
-   public static void clear()
-   {
-      array = null;
-      value = null;
-      index = -1;
-   }
-   
-   private static void recordAccess(Object array, int index, String value)
-   {
-      ArrayAdvisor.array = array;
-      ArrayAdvisor.index = index;
-      ArrayAdvisor.value = value;
-   }
-   
-   //Write operations
-   public static void arrayWrite(boolean[] array, int index, boolean value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-
-   public static void arrayWrite(short[] array, int index, short value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-
-   public static void arrayWrite(int[] array, int index, int value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(long[] array, int index, long value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(float[] array, int index, float value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(double[] array, int index, double value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(char[] array, int index, char value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-   
-   public static void arrayWrite(Object[] array, int index, Object value)
-   {
-      recordAccess(array, index, String.valueOf(value));
-      array[index] = value; 
-   }
-
-   //Read operations
-   public static boolean arrayRead(boolean[] array, int index)
-   {
-      
-      boolean value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-
-   public static short arrayRead(short[] array, int index)
-   {
-      short value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-
-   public static int arrayRead(int[] array, int index)
-   {
-      int value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static long arrayRead(long[] array, int index)
-   {
-      long value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static float arrayRead(float[] array, int index)
-   {
-      float value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static double arrayRead(double[] array, int index)
-   {
-      double value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static char arrayRead(char[] array, int index)
-   {
-      char value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   public static Object arrayRead(Object[] array, int index)
-   {
-      Object value = array[index];
-      recordAccess(array, index, String.valueOf(value));
-      return value;
-   }
-   
-   
-}

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -30,14 +30,14 @@
  */
 public class ClassWithArrayFields
 {
-//   public Object[] afield = new Object[] {"1", "2", "3"};
-//   public boolean[] bfield = new boolean[] {true, false};
-//   public char[] cfield = new char[] {'a', 'b', 'c'};
-//   public double[] dfield = new double[] {1.5d, 1.9d};
-//   public float[] ffield = new float[] {1.5f, 1.9f};
-   public int[] ifield = new int[] {0, 0, 0};
-   public int[][] iifield = new int[][]{new int[] {0, 0}, new int[] {0, 0}};
-   public int[][][] iiifield = new int[][][] {
+   public Object[] objects = new Object[] {"1", "2", "3"};
+   public byte[] bytes = new byte[] {1, 2, 3};
+   public boolean[] booleans = new boolean[] {true, true, true};
+   public char[] chars = new char[] {'a', 'b', 'c'};
+   public double[] doubles = new double[] {1.5d, 1.9d, 6.9d};
+   public float[] floats = new float[] {1.5f, 1.9f, 6.9f};
+   public int[] ints = new int[] {0, 0, 0};
+   public int[][][] ints3d = new int[][][] {
          new int[][] {
                new int[] {1,2,3}, 
                new int[] {4,5,6},
@@ -49,38 +49,11 @@
                new int[] {7,8,9}
          },         
    };
-
+   public long[] longs = new long[] {1L, 2L, 3L};
+   public short[] shorts = new short[] {1,2,3};
+   
    public ClassWithArrayFields()
    {
 
    }
-   public static void main(String[] args)
-   {
-//      ClassWithArrayFields tgt = new ClassWithArrayFields();
-//      for (int i = 0 ; i < tgt.iiifield.length ; i++) {
-//         for (int j = 0 ; j < tgt.iiifield[i].length ; j++) {
-//            for (int k = 0 ; k < tgt.iiifield[i][j].length ; k++) {
-//               System.out.println(tgt.iiifield[i][j][k]);
-//            }
-//         }
-//      }
-   }
-//   public long[] lfield = new long[] {0L, 0L, 0L};
-//   public short[] sfield = new short[] {0, 0, 0};
-   
-   
-//   public void setValue(int index, int value)
-//   {
-//      ifield[index] = value;
-//   }
-//   
-//   public int getValue(int index)
-//   {
-//      return ifield[index];
-//   }
-   
-   public void test(short s)
-   {
-      test(s);
-   }
 }

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithUnadvisedArrayFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithUnadvisedArrayFields.java	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithUnadvisedArrayFields.java	2006-12-24 13:56:30 UTC (rev 59223)
@@ -0,0 +1,41 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassWithUnadvisedArrayFields
+{
+   public Object[] objects = new Object[] {"1", "2", "3"};
+   public byte[] bytes = new byte[] {1, 2, 3};
+   public boolean[] booleans = new boolean[] {true, true, true};
+   public char[] chars = new char[] {'a', 'b', 'c'};
+   public double[] doubles = new double[] {1.5d, 1.9d, 6.9d};
+   public float[] floats = new float[] {1.5f, 1.9f, 6.9f};
+   public int[] ints = new int[] {0, 0, 0};
+   public long[] longs = new long[] {1L, 2L, 3L};
+   public short[] shorts = new short[] {1,2,3};
+
+}

Modified: projects/aop/branches/arrays/build/build-thirdparty.xml
===================================================================
--- projects/aop/branches/arrays/build/build-thirdparty.xml	2006-12-24 13:53:26 UTC (rev 59222)
+++ projects/aop/branches/arrays/build/build-thirdparty.xml	2006-12-24 13:56:30 UTC (rev 59223)
@@ -45,7 +45,7 @@
       -->
       <componentref name="apache-log4j" version="1.2.8"/>
       <componentref name="dom4j" version="1.6.1jboss"/>
-      <componentref name="javassist" version="3.4.GA"/>
+      <componentref name="javassist" version="snapshot"/>
       <componentref name="jboss/backport-concurrent" version="2.1.0.GA"/>
       <componentref name="jboss/common-core" version="2.0.1.GA"/>
       <componentref name="jboss/common-logging-jdk" version="2.0.1.GA"/>



From ptsekov at jboss.org  Sun Dec 24 11:00:16 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sun, 24 Dec 2006 11:00:16 -0500
Subject: [jboss-cvs] JBossCache  ...
Message-ID: <E1GyVlo-00050M-Bf@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/24 11:00:16

  Modified:    JBossCache  build.xml
  Log:
  * build.xml: Merge the compat-tests target from the 1.4.0 branch.
  * tests/compat/*: Merge org.jboss.tools.SerialVersionUID and 
  org.jboss.cache.compat.SerialVersionUIDUnitTestCase from the 1.4.0 branch.
  
  Revision  Changes    Path
  1.157     +36 -1     JBossCache/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/build.xml,v
  retrieving revision 1.156
  retrieving revision 1.157
  diff -u -b -r1.156 -r1.157
  --- build.xml	22 Dec 2006 03:28:52 -0000	1.156
  +++ build.xml	24 Dec 2006 16:00:16 -0000	1.157
  @@ -1,6 +1,6 @@
   <?xml version="1.0" encoding="UTF-8"?>
   
  -<!-- $Id: build.xml,v 1.156 2006/12/22 03:28:52 msurtani Exp $ -->
  +<!-- $Id: build.xml,v 1.157 2006/12/24 16:00:16 ptsekov Exp $ -->
   
   <project default="compile" name="JBossCache">
   
  @@ -19,6 +19,7 @@
      <property name="interop.tests.dir" value="${tests.dir}/interop"/>
      <property name="perf.tests.dir" value="${tests.dir}/perf"/>
      <property name="interop.tests.dir" value="${tests.dir}/interop"/>
  +   <property name="compat.tests.dir" value="${tests.dir}/compat"/>
      <property name="etc.dir" value="${root.dir}/etc"/>
      <property name="dependencies" value="dependencies.xml"/>
      <property name="resources.dir" value="${root.dir}/src-50/resources"/>
  @@ -44,10 +45,18 @@
      <property name="junit.timeout" value="300000"/>
      <property name="junit.timeout.stresstest" value="6000000"/>
      <property name="junit.timeout.performance" value="60000"/>
  +   <property name="junit.timeout.compat" value="300000"/>
      <property name="junit.batchtest.todir" value="${build.reports}"/>
      <property name="junit.jvm.options" value="-Ddummy"/>
      <property name="ant.dir" value="${root.dir}/ant-dist"/>
      <property name="manifest.file" value="${dist.lib}/default.mf"/>
  +   <!-- -->
  +   <condition property="ENABLE_COMPAT_TESTS">
  +      <or>
  +         <equals arg1="${ant.java.version}" arg2="1.5"/>
  +         <equals arg1="${ant.java.version}" arg2="1.4"/>
  +      </or>
  +   </condition>
      <property name="src.dir.50" value="${root.dir}/src-50"/>
      <property name="tests.dir.50" value="${root.dir}/tests-50"/>
      <property name="output.resources.dir" value="${output.dir}/resources"/>
  @@ -194,6 +203,7 @@
            <src path="${stress.tests.dir}"/>
            <src path="${perf.tests.dir}"/>
            <src path="${interop.tests.dir}"/>
  +         <src path="${compat.tests.dir}"/>
            <classpath path="${compile.dir}"/>
            <classpath refid="library.classpath"/>
            <exclude name="**/obsolete/**"/>
  @@ -929,6 +939,31 @@
         </sequential>
      </macrodef>
   
  +   <target name="compat-tests" depends="jar, unittests-init"
  +           if="ENABLE_COMPAT_TESTS">
  +      <condition property="libdir.list" value="lib-50,lib, dist/lib-50">
  +         <equals arg1="${ant.java.version}" arg2="1.5"/>
  +      </condition>
  +      <condition property="libdir.list" value="lib, dist/lib">
  +         <equals arg1="${ant.java.version}" arg2="1.4"/>
  +      </condition>
  +
  +      <junit printsummary="yes" timeout="${junit.timeout.compat}" fork="yes"
  +             maxmemory="256m">
  +         <classpath>
  +            <pathelement path="${compiletest.dir}"/>
  +         </classpath>
  +         <sysproperty key="libdir.list" value="${libdir.list}"/>
  +         <formatter type="xml" usefile="true"/>
  +         <batchtest todir="${build.reports}">
  +            <fileset dir="${compat.tests.dir}">
  +               <exclude name="**/tools/**/*"/>
  +               <patternset refid="junit.excludes"/>
  +            </fileset>
  +         </batchtest>
  +      </junit>
  +   </target>
  +
      <target name="unittests"
              depends="functionaltests, perftests, stresstests"
              description="Run all non-AOP unit tests (functional, perf, stress)"/>
  
  
  


From ptsekov at jboss.org  Sun Dec 24 11:00:16 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sun, 24 Dec 2006 11:00:16 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/cache/compat  ...
Message-ID: <E1GyVlo-00050T-Mu@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/24 11:00:16

  Added:       tests/compat/org/jboss/cache/compat 
                        SerialVersionUIDUnitTestCase.java
  Log:
  * build.xml: Merge the compat-tests target from the 1.4.0 branch.
  * tests/compat/*: Merge org.jboss.tools.SerialVersionUID and 
  org.jboss.cache.compat.SerialVersionUIDUnitTestCase from the 1.4.0 branch.
  
  Revision  Changes    Path
  1.2       +229 -0    JBossCache/tests/compat/org/jboss/cache/compat/SerialVersionUIDUnitTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUIDUnitTestCase.java
  ===================================================================
  RCS file: SerialVersionUIDUnitTestCase.java
  diff -N SerialVersionUIDUnitTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SerialVersionUIDUnitTestCase.java	24 Dec 2006 16:00:16 -0000	1.2
  @@ -0,0 +1,229 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.cache.compat;
  +
  +import java.beans.XMLDecoder;
  +import java.io.File;
  +import java.io.FileInputStream;
  +import java.io.FileWriter;
  +import java.io.IOException;
  +import java.io.ObjectInputStream;
  +import java.util.Iterator;
  +import java.util.Map;
  +import java.util.TreeMap;
  +
  +import junit.framework.Test;
  +import junit.framework.TestCase;
  +import junit.framework.TestSuite;
  +
  +import org.jboss.tools.ClassVersionInfo;
  +import org.jboss.tools.SerialVersionUID;
  +
  +/** 
  + * Tests of serial version uid compatibility across jboss versions. The
  + * testsuite/etc/serialVersionUID/xxx.ser is created using the
  + * org.jboss.tools.SerialVersionUID utility.
  + *
  + * @author Scott.Stark at jboss.org
  + */
  +public class SerialVersionUIDUnitTestCase extends TestCase
  +{
  +   private static final String DB_DIR = "etc/svuid-db";
  +   private static final String DB_FILE_PREFIX = "svuid-";
  +   private static final String VERSION_STRING_1_3_0_GA = "1.3.0.GA";
  +   private static final String VERSION_STRING_1_4_0_GA = "1.4.0.GA";
  +   private static final String JAVA_VERSION_PREFIX_14 = "14";
  +   private static final String JAVA_VERSION_PREFIX_50 = "50";
  +
  +   int mismatchCount = 0;
  +
  +   StringBuffer messages = null;
  +
  +   public SerialVersionUIDUnitTestCase(String name)
  +   {
  +      super(name);
  +   }
  +
  +   protected void setUp()
  +   {
  +      mismatchCount = 0;
  +
  +      if (messages == null)
  +      {
  +         messages = new StringBuffer();
  +      }
  +   }
  +
  +   protected void tearDown()
  +   {
  +      messages.setLength(0);
  +   }
  +
  +   public void testCompat_1_3_0_GA() throws Exception
  +   {
  +      String prefix = getFilePrefix() + VERSION_STRING_1_3_0_GA;
  +      Map db = readDatabase(prefix);
  +      mismatchCount = compare(db, calcClassInfoMap(), prefix,
  +			      new String[0], messages);
  +
  +      System.out.println("serialVersionUID mismatches = " + mismatchCount);
  +      if (mismatchCount != 0)
  +      {
  +         fail("Failures for :" + messages.toString());
  +      }
  +   }
  +
  +   public void testCompat_1_4_0_GA() throws Exception
  +   {
  +      String prefix = getFilePrefix() + VERSION_STRING_1_4_0_GA;
  +      Map db = readDatabase(prefix);
  +      mismatchCount = compare(db, calcClassInfoMap(), prefix,
  +			      new String[0], messages);
  +
  +      System.out.println("serialVersionUID mismatches = " + mismatchCount);
  +      if (mismatchCount != 0)
  +      {
  +         fail("Failures for :" + messages.toString());
  +      }
  +   }
  +
  +   private String getFilePrefix()
  +   {
  +      String javaVersion = System.getProperty("java.version").trim();
  +      if (javaVersion.startsWith("1.5."))
  +      {
  +         return DB_FILE_PREFIX + JAVA_VERSION_PREFIX_50 + ".";
  +      }
  +      else if (javaVersion.startsWith("1.4."))
  +      {
  +         return DB_FILE_PREFIX + JAVA_VERSION_PREFIX_14 + ".";
  +      }
  +      else
  +      {
  +         return "";
  +      }
  +   }
  +
  +   private Map readDatabase(String dbFilePrefix)
  +      throws Exception
  +   {
  +      File dbFile = new File(DB_DIR, dbFilePrefix + ".xml");
  +      FileInputStream inputStream = new FileInputStream(dbFile);
  +      XMLDecoder xmlObjects = new XMLDecoder(inputStream);
  +      ClassVersionInfo svuidInfo;
  +      TreeMap db = new TreeMap();
  +      boolean doQuit = false;
  +
  +      do
  +      {
  +         try
  +         {
  +            svuidInfo = (ClassVersionInfo) xmlObjects.readObject();
  +            db.put(svuidInfo.getName(), svuidInfo);
  +         }
  +         /*
  +          * TODO: Keep working ?
  +         catch (ClassCastException e)
  +         {
  +            ;
  +         }
  +         */
  +         catch (ArrayIndexOutOfBoundsException e)
  +         {
  +            // No more data
  +            doQuit = true;
  +         }
  +      } while (doQuit == false);
  +
  +      return db;
  +   }
  +
  +   /**
  +    Compare two sets of classes for serialVersionUID compatibility.
  +
  +    @param classInfoMap - the legacy version classes
  +    @param currentClassInfoMap - the current build classes
  +    @param versionName - the legacy version name
  +    @param badPackages - a list of package prefixes to ignore for errors
  +    @return the number of serial version mismatches
  +    */
  +   private int compare(Map classInfoMap, Map currentClassInfoMap,
  +      String versionName, String[] badPackages, StringBuffer bufferMessages)
  +      throws IOException
  +   {
  +      File out = new File(versionName+".errors");
  +      System.out.println("Writing errors to: "+out.getAbsolutePath());
  +      FileWriter errors = new FileWriter(out);
  +      int mismatchCount = 0;
  +      Iterator iter = currentClassInfoMap.values().iterator();
  +      while( iter.hasNext() )
  +      {
  +         ClassVersionInfo cvi = (ClassVersionInfo) iter.next();
  +         String name = cvi.getName();
  +         ClassVersionInfo cviLegacy = (ClassVersionInfo) classInfoMap.get(name);
  +         if( cviLegacy != null && cvi.getSerialVersion() != cviLegacy.getSerialVersion() )
  +         {
  +            String msg = "serialVersionUID error for "+name
  +               +", " + versionName + ": " + cviLegacy.getSerialVersion()
  +               +", current: "+cvi.getSerialVersion();
  +
  +            // Don't count classes from badPackages
  +            boolean isInBadPkg = false;
  +            for(int n = 0; n < badPackages.length; n ++)
  +            {
  +               String pkg = badPackages[n];
  +               if( name.startsWith(pkg) )
  +               {
  +                  isInBadPkg = true;
  +                  break;
  +               }
  +            }
  +
  +            if (isInBadPkg)
  +               continue;
  +
  +            if (mismatchCount>0)
  +            {
  +               bufferMessages.append(",\n");
  +            }
  +            bufferMessages.append(name);
  +            mismatchCount ++;
  +            System.err.println(msg);
  +            errors.write(msg);
  +            errors.write('\n');
  +         }
  +      }
  +      errors.close();
  +      // If the mismatchCount is 0 remove the error file
  +      if( mismatchCount == 0 )
  +         out.delete();
  +
  +      return mismatchCount;
  +   }
  +
  +   static Map calcClassInfoMap()
  +      throws IOException
  +   {
  +      SerialVersionUID.processProperties();
  +      Map classInfoMap = SerialVersionUID.processJars();
  +      return classInfoMap;
  +   }
  +   
  +   public static Test suite() throws Exception
  +   {
  +      TestSuite suite = new TestSuite();
  +      suite.addTest(new SerialVersionUIDUnitTestCase("testCompat_1_4_0_GA"));
  +      suite.addTest(new SerialVersionUIDUnitTestCase("testCompat_1_3_0_GA"));
  +
  +      return suite;
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      junit.textui.TestRunner.run(SerialVersionUIDUnitTestCase.class);
  +   }
  +}
  
  
  


From ptsekov at jboss.org  Sun Dec 24 11:00:16 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sun, 24 Dec 2006 11:00:16 -0500
Subject: [jboss-cvs] JBossCache/tests/compat/org/jboss/tools   ...
Message-ID: <E1GyVlo-00050d-Rr@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/24 11:00:16

  Added:       tests/compat/org/jboss/tools   ClassVersionInfo.java
                        SerialVersionUID.java
  Log:
  * build.xml: Merge the compat-tests target from the 1.4.0 branch.
  * tests/compat/*: Merge org.jboss.tools.SerialVersionUID and 
  org.jboss.cache.compat.SerialVersionUIDUnitTestCase from the 1.4.0 branch.
  
  Revision  Changes    Path
  1.2       +137 -0    JBossCache/tests/compat/org/jboss/tools/ClassVersionInfo.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClassVersionInfo.java
  ===================================================================
  RCS file: ClassVersionInfo.java
  diff -N ClassVersionInfo.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ ClassVersionInfo.java	24 Dec 2006 16:00:16 -0000	1.2
  @@ -0,0 +1,137 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.tools;
  +
  +import java.io.ObjectStreamClass;
  +import java.io.Serializable;
  +import java.io.FileInputStream;
  +import java.io.ObjectInputStream;
  +import java.util.Map;
  +
  +/**
  + * Encapsulates a class serialVersionUID and codebase.
  + * 
  + * @author Scott.Stark at jboss.org
  + * @version $Revision: 1.2 $
  + */
  +public class ClassVersionInfo implements Serializable
  +{
  +   static final long serialVersionUID = 2036506209171911437L;
  +
  +   /** The named class serialVersionUID as returned by ObjectStreamClass */
  +   private long serialVersion;
  +   /** The binary class name */
  +   private String name;
  +   private boolean hasExplicitSerialVersionUID;
  +
  +   public ClassVersionInfo() {}
  +
  +   public ClassVersionInfo(String name, ClassLoader loader)
  +      throws ClassNotFoundException
  +   {
  +      this.name = name;
  +      Class c = loader.loadClass(name);
  +      if( c.isInterface() == false )
  +      {
  +         ObjectStreamClass osc = ObjectStreamClass.lookup(c);
  +         if( osc != null )
  +         {
  +            serialVersion = osc.getSerialVersionUID();
  +            try
  +            {
  +               c.getDeclaredField("serialVersionUID");
  +               hasExplicitSerialVersionUID = true;
  +            }
  +            catch(NoSuchFieldException e)
  +            {
  +               hasExplicitSerialVersionUID = false;
  +            }
  +         }
  +      }
  +   }
  +
  +   public long getSerialVersion()
  +   {
  +      return serialVersion;
  +   }
  +
  +   public void setSerialVersion(long serialVersion)
  +   {
  +      this.serialVersion = serialVersion;
  +   }
  +
  +   public boolean getHasExplicitSerialVersionUID()
  +   {
  +      return hasExplicitSerialVersionUID;
  +   }
  +
  +   public void setHasExplicitSerialVersionUID(boolean flag)
  +   {
  +      hasExplicitSerialVersionUID = flag;
  +   }
  +
  +   public String getName()
  +   {
  +      return name;
  +   }
  +
  +   public void setName(String name)
  +   {
  +      this.name = name;
  +   }
  +
  +   public String toString()
  +   {
  +      StringBuffer tmp = new StringBuffer("ClassVersionInfo");
  +      tmp.append('{');
  +      tmp.append("serialVersion=");
  +      tmp.append(serialVersion);
  +      tmp.append(", hasExplicitSerialVersionUID=");
  +      tmp.append(hasExplicitSerialVersionUID);
  +      tmp.append(", name=");
  +      tmp.append(name);
  +      tmp.append('}');
  +      return tmp.toString();
  +   }
  +
  +   /**
  +    * Utility main entry point that allows one to load a Map<String,ClassVersionInfo>
  +    * from a serialized object file to print a specific ClassVersionInfo
  +    * 
  +    * @param args [0] = map.ser file for serialized object image
  +    *    [1] = class name of the ClassVersionInfo to print 
  +    * @throws Exception
  +    */
  +   public static void main(String[] args)
  +      throws Exception
  +   {
  +      if( args.length != 2 )
  +      {
  +         throw new IllegalArgumentException("Usage ClassVersionInfo map.ser [-list|cvi_fqn]");
  +      }
  +      FileInputStream fis = new FileInputStream(args[0]);
  +      ObjectInputStream ois = new ObjectInputStream(fis);
  +      Map cvis = (Map) ois.readObject();
  +      ois.close();
  +
  +      if( args[1].equals("-list") )
  +      {
  +         System.out.println(cvis.keySet());
  +         System.exit(0);
  +      }
  +
  +      String fqn = args[1];
  +      if( cvis.containsKey(fqn) == false )
  +      {
  +         System.err.println("No entry found for: "+fqn);
  +         System.exit(1);
  +      }
  +      ClassVersionInfo cvi = (ClassVersionInfo) cvis.get(fqn);
  +      System.out.println(cvi);
  +      System.exit(0);
  +   }
  +}
  
  
  
  1.2       +236 -0    JBossCache/tests/compat/org/jboss/tools/SerialVersionUID.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SerialVersionUID.java
  ===================================================================
  RCS file: SerialVersionUID.java
  diff -N SerialVersionUID.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SerialVersionUID.java	24 Dec 2006 16:00:16 -0000	1.2
  @@ -0,0 +1,236 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + *
  + * Distributable under LGPL license.
  + * See terms of license at gnu.org.
  + */
  +package org.jboss.tools;
  +
  +import java.beans.XMLEncoder;
  +import java.io.File;
  +import java.io.FileInputStream;
  +import java.io.FileOutputStream;
  +import java.io.ObjectOutputStream;
  +import java.io.IOException;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.Enumeration;
  +import java.util.TreeMap;
  +import java.util.Map;
  +import java.util.Properties;
  +import java.util.Set;
  +import java.util.LinkedHashSet;
  +import java.util.logging.Logger;
  +import java.util.logging.Level;
  +import java.util.jar.JarFile;
  +import java.util.jar.JarEntry;
  +import java.net.URLClassLoader;
  +import java.net.MalformedURLException;
  +import java.net.URL;
  +
  +/** A tool that builds a databaase of serialVersionUIDs for a given set
  + *  of classes.
  + * 
  + * @author Scott.Stark at jboss.org
  + */
  +public class SerialVersionUID
  +{
  +   static Logger log = Logger.getLogger("SerialVersionUID");
  +
  +   static LinkedHashSet libdirList = new LinkedHashSet();
  +
  +   static boolean outputXML = false;
  +
  +   static void parsePropertyList(String listValue, Set dst)
  +   {
  +      String elements[] = listValue.split(",");
  +
  +      for (int i = 0; i < elements.length; i++)
  +      {
  +         dst.add(elements[i].trim());
  +      }
  +   }
  +
  +   public static void processProperties()
  +   {
  +      Properties fallbackProps = new Properties();
  +      // A list of directories to scan for .jar files.
  +      fallbackProps.setProperty("libdir.list", "lib");
  +      fallbackProps.setProperty("output.xml", "true");
  +
  +      Properties props = new Properties(fallbackProps);
  +      String propName, propValue;
  +      for (Enumeration e = fallbackProps.propertyNames(); e.hasMoreElements();)
  +      {
  +         propName = (String) e.nextElement();
  +         propValue = System.getProperty(propName);
  +         if (propValue != null)
  +         {
  +            props.setProperty(propName, propValue);
  +         }
  +      }
  +
  +      String tmpStr;
  +      tmpStr = props.getProperty("libdir.list");
  +      if (tmpStr.length() == 0)
  +      {
  +         tmpStr = fallbackProps.getProperty("libdir.list");
  +      }
  +      parsePropertyList(tmpStr, libdirList);
  +
  +      tmpStr = props.getProperty("output.xml");
  +      if (tmpStr.length() == 0)
  +      {
  +         tmpStr = fallbackProps.getProperty("output.xml");
  +      }
  +      tmpStr.trim();
  +      if (tmpStr == "yes" || tmpStr == "true")
  +      {
  +         outputXML = true;
  +      }
  +   }
  +
  +   static void buildJarSet(File dir, LinkedHashSet jarFiles)
  +      throws MalformedURLException
  +   {
  +      File[] files = dir.listFiles();
  +      for(int n = 0; n < files.length; n ++)
  +      {
  +         File child = files[n];
  +         if(child.isDirectory())
  +            buildJarSet(child, jarFiles);
  +         else if( child.getName().endsWith(".jar") )
  +            jarFiles.add(child.toURL());
  +      }
  +   }
  +
  +   /**
  +    * Build a TreeMap of the class name to ClassVersionInfo
  +    * @param jar
  +    * @param classVersionMap TreeMap<String, ClassVersionInfo> for serializable
  +    *    classes
  +    * @param cl - the class loader to use
  +    * @throws IOException thrown if the jar cannot be opened
  +    */ 
  +   static void generateJarSerialVersionUIDs(URL jar, TreeMap classVersionMap,
  +      ClassLoader cl, String pkgPrefix) throws IOException
  +   {
  +      String jarName = jar.getFile();
  +      JarFile jf = new JarFile(jarName);
  +      Enumeration entries = jf.entries();
  +      while( entries.hasMoreElements() )
  +      {
  +         JarEntry entry = (JarEntry) entries.nextElement();
  +         String name = entry.getName();
  +         if( name.endsWith(".class") && name.startsWith(pkgPrefix) )
  +         {
  +            name = name.substring(0, name.length() - 6);
  +            String classname = name.replace('/', '.');
  +            try
  +            {
  +               log.fine("Creating ClassVersionInfo for: "+classname);
  +               ClassVersionInfo cvi = new ClassVersionInfo(classname, cl);
  +               if( cvi.getSerialVersion() != 0 )
  +               {
  +                  ClassVersionInfo prevCVI = (ClassVersionInfo)
  +                     classVersionMap.put(classname, cvi);
  +                  if( prevCVI != null )
  +                  {
  +                     if( prevCVI.getSerialVersion() != cvi.getSerialVersion() )
  +                     {
  +                        log.severe("Found inconsistent classes, "
  +                           +prevCVI+" != "+cvi+", jar: "+jarName);
  +                     }
  +                  }
  +                  if( cvi.getHasExplicitSerialVersionUID() == false )
  +                  {
  +                     log.warning("No explicit serialVersionUID: "+cvi);
  +                  }
  +               }
  +            }
  +            catch(OutOfMemoryError e)
  +            {
  +               log.log(Level.SEVERE, "Check the MaxPermSize", e);
  +            }
  +            catch(Throwable e)
  +            {
  +               log.log(Level.FINE, "While loading: "+name, e);
  +            }
  +         }
  +      }
  +      jf.close();
  +   }
  +
  +   /**
  +    * Create a Map<String, ClassVersionInfo> for the dist jars.
  +    * 
  +    * @return Map<String, ClassVersionInfo>
  +    * @throws IOException
  + .   */ 
  +   public static Map processJars() throws IOException
  +   {
  +      LinkedHashSet jarFiles = new LinkedHashSet();
  +
  +      File dir;
  +      Iterator libdirIterator = libdirList.iterator();
  +      while (libdirIterator.hasNext())
  +      {
  +         dir = new File((String) libdirIterator.next());
  +         buildJarSet(dir, jarFiles);
  +      }
  +
  +      URL[] cp = new URL[jarFiles.size()];
  +      jarFiles.toArray(cp);
  +      ClassLoader parent = Thread.currentThread().getContextClassLoader();
  +      URLClassLoader completeClasspath = new URLClassLoader(cp, parent);
  +
  +      TreeMap classVersionMap = new TreeMap();
  +      Iterator jarIter = jarFiles.iterator();
  +      while( jarIter.hasNext() )
  +      {
  +         URL jar = (URL) jarIter.next();
  +         try
  +         {
  +            generateJarSerialVersionUIDs(jar, classVersionMap, completeClasspath, "");
  +         }
  +         catch(IOException e)
  +         {
  +            log.info("Failed to process jar: "+jar);
  +         }
  +      }
  +
  +      return classVersionMap;
  +   }
  +
  +   /**
  +    * Generate a mapping of the serial version UIDs for the serializable classes
  +    * under the dist directory (as specified by the dist.dir property).
  +    * @throws Exception
  +    */ 
  +   public static void main(String[] args) throws Exception
  +   {
  +      processProperties();
  +
  +      Map classVersionMap = processJars();
  +      log.info(classVersionMap.size() + " serialVersionUIDs stored into the database");
  +
  +      FileOutputStream fos = new FileOutputStream("serialuid.ser");
  +      if (outputXML == false)
  +      {
  +         // Write the map out the object file
  +         ObjectOutputStream oos = new ObjectOutputStream(fos);
  +         oos.writeObject(classVersionMap);
  +         oos.close();
  +      }
  +      else
  +      {
  +         XMLEncoder xml = new XMLEncoder(fos);
  +         Iterator mapIterator = classVersionMap.values().iterator();
  +         while (mapIterator.hasNext())
  +         {
  +            xml.writeObject(mapIterator.next());
  +         }
  +         xml.close();
  +      }
  +   }
  +}
  
  
  


From norman.richards at jboss.com  Sun Dec 24 11:08:27 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:08:27 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf - New directory ...
Message-ID: <E1GyVtj-0005KG-AP@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:08:27

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:09:48 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:09:48 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/META-INF - New directory ...
Message-ID: <E1GyVv2-0005KR-EZ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:09:48

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf/META-INF added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:09:48 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:09:48 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org - New directory ...
Message-ID: <E1GyVv2-0005KV-Hi@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:09:48

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf/org added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:10:26 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:10:26 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss - New directory ...
Message-ID: <E1GyVve-0005Mv-Ce@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:10:26

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf/org/jboss added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:10:53 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:10:53 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam - New directory ...
Message-ID: <E1GyVw5-0005OS-Of@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:10:53

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:11:11 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:11:11 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf - New directory ...
Message-ID: <E1GyVwN-0005PJ-Lp@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:11:11

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:12:40 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:12:40 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui - New directory
	...
Message-ID: <E1GyVxo-0005Pe-K3@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:12:40

  Log:
  Directory /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui added to the repository


From norman.richards at jboss.com  Sun Dec 24 11:21:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:21:32 -0500
Subject: [jboss-cvs] jboss-seam  ...
Message-ID: <E1GyW6O-0005Xy-IR@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:21:32

  Modified:    jboss-seam  build.xml
  Log:
  check in itext preview
  
  Revision  Changes    Path
  1.124     +80 -5     jboss-seam/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/build.xml,v
  retrieving revision 1.123
  retrieving revision 1.124
  diff -u -b -r1.123 -r1.124
  --- build.xml	16 Dec 2006 15:04:04 -0000	1.123
  +++ build.xml	24 Dec 2006 16:21:32 -0000	1.124
  @@ -20,6 +20,7 @@
       <property name="build.dir"            value="build"/>
       <property name="classes.dir"          value="${build.dir}/classes"/>    
       <property name="uiclasses.dir"        value="${build.dir}/uiclasses"/>
  +    <property name="pdfclasses.dir"       value="${build.dir}/pdfclasses"/>
       <property name="debugclasses.dir"     value="${build.dir}/debugclasses"/>
       <property name="coverage.dir"         value="${build.dir}/coverage"/>
       
  @@ -27,9 +28,10 @@
   
       <property name="src.java.dir"         value="src/main"/>
       <property name="src.ui.dir"           value="src/ui"/>
  +    <property name="src.pdf.dir"          value="src/pdf"/>
       <property name="src.debug.dir"        value="src/debug"/>
       <property name="src.gen.dir"          value="src/gen"/>
  -    <property name="src.test.dir"         value="src/test"/>
  +    <property name="src.test.dir"         value="src/test/misc"/>
   
       <property name="lib.dir"              value="${imported.basedir}/lib"/>
       <property name="drools.lib.dir"       value="${imported.basedir}/drools/lib"/>
  @@ -53,6 +55,7 @@
       <property name="dist.ref.dir"         value="${dist.dir}/doc/reference"/>
       <property name="dist.src.java.dir"    value="${dist.dir}/src/main"/>
       <property name="dist.src.ui.dir"      value="${dist.dir}/src/ui"/>
  +    <property name="dist.src.pdf.dir"     value="${dist.dir}/src/pdf"/>
       <property name="dist.src.debug.dir"   value="${dist.dir}/src/debug"/>
       <property name="dist.src.gen.dir"     value="${dist.dir}/src/gen"/>
       <property name="dist.src.test.dir"    value="${dist.dir}/src/test"/>
  @@ -92,8 +95,18 @@
          description="the Seam jars">
           <include name="jboss-seam-debug.jar" if="example.seam.debug.lib"/>
           <include name="jboss-seam-ui.jar" if="example.seam.ui.lib"/>
  +        <include name="jboss-seam-pdf.jar"   if="example.seam.pdf.lib"/>
       </zipfileset>
       
  +
  +    <zipfileset id="example.itext.jar"
  +               dir="${lib.dir}"
  +           prefix="WEB-INF/lib"
  +      description="the itext jar">
  +        <include name="itext-*.jar" if="example.seam.pdf.lib"/>
  +    </zipfileset>
  +
  +
       <zipfileset id="example.seam.main.jar" 
                  dir="${imported.basedir}"
          description="the main Seam jar">
  @@ -161,6 +174,8 @@
                  dir="${example.resources.dir}">
           <include name="META-INF/application.xml"/>
           <include name="META-INF/jboss-app.xml"/>
  +        <include name="META-INF/*-service.xml"/>
  +        <include name="META-INF/*-xmbean.xml"/>
           <include name="treecache.xml"/>
           <include name="*.jpdl.xml"/>
           <exclude name=".gpd.*"/>
  @@ -211,6 +226,7 @@
           <include name="${name}.jar"/>
           <include name="jboss-seam-debug.jar" if="example.seam.debug.lib"/>
           <include name="jboss-seam-ui.jar" if="example.seam.ui.lib"/>
  +        <include name="jboss-seam-pdf.jar"   if="example.seam.pdf.lib"/>
       </zipfileset>
       
       <zipfileset id="example.tomcat.drools.jar" 
  @@ -417,6 +433,19 @@
           
       </target>
   
  +    <target name="initpdf"
  +            description="Initialize the build for the PDF package">
  +        <echo message="Build ${Name} PDF ${version}"/>
  +
  +        <mkdir dir="${pdfclasses.dir}"/>
  +        <copy todir="${pdfclasses.dir}">
  +            <fileset dir="${src.pdf.dir}">
  +                <patternset refid="meta.files"/>
  +            </fileset>
  +        </copy>
  +        
  +    </target>
  +
       <target name="initdebug"
               description="Initialize the build for the debug package">
           <echo message="Build ${Name} Debug ${version}"/>
  @@ -477,6 +506,25 @@
           </javac>
       </target>
       
  +    <target name="compilepdf" depends="initpdf,select-compiler"
  +            description="Compile the Java source code for the PDF package">
  +        <javac
  +            source="1.5"
  +            target="1.5"
  +            destdir="${pdfclasses.dir}"
  +            debug="${javac.debug}"
  +            deprecation="${javac.deprecation}"
  +            nowarn="on">
  +            <src path="${src.pdf.dir}"/>
  +            <classpath>
  +                <path refid="build.classpath" />
  +                <fileset dir="${imported.basedir}">
  +                    <include name="jboss-seam-ui.jar" />
  +                </fileset>
  +            </classpath>
  +        </javac>
  +    </target>
  +    
       <target name="compiledebug" depends="initdebug,select-compiler"
               description="Compile the Java source code for the debug package">
           <javac
  @@ -600,6 +648,16 @@
               </fileset>
           </copy>
   
  +        <mkdir dir="${dist.src.pdf.dir}"/>
  +        <copy todir="${dist.src.pdf.dir}">
  +            <fileset dir="${src.pdf.dir}">
  +                <patternset refid="src.files"/>
  +            </fileset>
  +            <fileset dir="${src.pdf.dir}">
  +                <patternset refid="meta.files"/>
  +            </fileset>
  +        </copy>
  +
           <mkdir dir="${dist.src.debug.dir}"/>
           <copy todir="${dist.src.debug.dir}">
               <fileset dir="${src.debug.dir}">
  @@ -764,7 +822,7 @@
           </copy>
       </target>
       
  -    <target name="build" depends="jar,jarui,jardebug,jargen"
  +    <target name="build" depends="jar,jarui,jarpdf,jardebug,jargen"
           description="Build all four distribution .jar files"/>
   
       <target name="jar" depends="compile"
  @@ -798,6 +856,22 @@
           
       </target>
   
  +    <target name="jarpdf" depends="compilepdf"
  +            description="Build the distribution .jar file for the PDF package">
  +        <mkdir dir="${dist.dir}"/>
  +        
  +        <jar jarfile="${basedir}/${name}-pdf.jar" basedir="${pdfclasses.dir}">
  +            <include name="**/*.class"/>
  +            <patternset refid="meta.files"/>
  +            <manifest>
  +                <attribute name="Seam-Version" value="${version}.${patchlevel}"/>
  +            </manifest>
  +        </jar>
  +        <copy file="${basedir}/${name}-pdf.jar" todir="${dist.dir}"/>
  +        
  +    </target>
  +
  +
       <target name="jardebug" depends="compiledebug"
               description="Build the distribution .jar file for the debug package">
           <mkdir dir="${dist.dir}"/>
  @@ -924,6 +998,7 @@
               <zipfileset refid="example.war.webinf.lib"/>
               <zipfileset refid="example.seam.misc.jar"/>
               <zipfileset refid="example.facelets.jar"/>
  +            <zipfileset refid="example.itext.jar"/>
               <zipfileset dir="${build.dir}/resources">
                   <include name="WEB-INF/**/*.*"/>
               </zipfileset>
  
  
  


From norman.richards at jboss.com  Sun Dec 24 11:21:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:21:32 -0500
Subject: [jboss-cvs] jboss-seam/lib  ...
Message-ID: <E1GyW6O-0005Y9-Nd@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:21:32

  Added:       lib      itext-1.4.7.jar
  Log:
  check in itext preview
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 16:21:32;  author: nrichards;  state: Exp;jboss-seam/lib/itext-1.4.7.jar
  
  	<<Binary file>>
  
  


From norman.richards at jboss.com  Sun Dec 24 11:21:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:21:32 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf  ...
Message-ID: <E1GyW6O-0005YG-S5@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:21:32

  Added:       src/pdf  seam.properties
  Log:
  check in itext preview
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 16:21:32;  author: nrichards;  state: Exp;jboss-seam/src/pdf/seam.properties
  
  Index: seam.properties
  ===================================================================
  
  
  
  


From norman.richards at jboss.com  Sun Dec 24 11:21:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:21:32 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/META-INF   ...
Message-ID: <E1GyW6O-0005YR-W9@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:21:32

  Added:       src/pdf/META-INF   faces-config.xml seam.taglib.xml
  Log:
  check in itext preview
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 16:21:32;  author: nrichards;  state: Exp;jboss-seam/src/pdf/META-INF/faces-config.xml
  
  Index: faces-config.xml
  ===================================================================
  <?xml version="1.0"?>
  <!DOCTYPE faces-config PUBLIC
      "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
      "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
  
  <faces-config>
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIDocument</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIDocument</component-class>
      </component>
  
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIParagraph</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIParagraph</component-class>
      </component>
  
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIPage</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIPage</component-class>
      </component>
  
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIList</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIList</component-class>
      </component>
  
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIFont</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIFont</component-class>
      </component>
  
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIListItem</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIListItem</component-class>
      </component>
  
      <component>
          <component-type>org.jboss.seam.pdf.ui.UIImage</component-type>
          <component-class>org.jboss.seam.pdf.ui.UIImage</component-class>
      </component>
  
      <lifecycle>
          <phase-listener>org.jboss.seam.pdf.PDFPhaseListener</phase-listener>
      </lifecycle>
  
      <!--
      <render-kit>
          <render-kit-id>PDF</render-kit-id>
          <render-kit-class>org.jboss.seam.pdf.PDFRenderKit</render-kit-class>
  
          <renderer> 
              <component-family>javax.faces.Output</component-family>
              <renderer-type>javax.faces.Text</renderer-type>
              <renderer-class>
                  org.jboss.seam.pdf.ui.TextRenderer
              </renderer-class>
          </renderer>
  
      </render-kit>
      -->
  </faces-config>
  
  
  
  1.1      date: 2006/12/24 16:21:32;  author: nrichards;  state: Exp;jboss-seam/src/pdf/META-INF/seam.taglib.xml
  
  Index: seam.taglib.xml
  ===================================================================
  <?xml version="1.0"?>
  <!DOCTYPE facelet-taglib PUBLIC
     "-//Sun Microsystems, Inc.//DTD Facelet Taglib 1.0//EN"
     "facelet-taglib_1_0.dtd">
     
  <facelet-taglib>
      <namespace>http://jboss.com/products/seam/pdf</namespace>
  
      <tag>
          <tag-name>document</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIDocument</component-type>
          </component>
      </tag>
  
      <tag>
          <tag-name>paragraph</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIParagraph</component-type>
          </component>
      </tag>
  
      <tag>
          <tag-name>newPage</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIPage</component-type>
          </component>
      </tag>
  
      <tag>
          <tag-name>list</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIList</component-type>
          </component>
      </tag>
  
      <tag>
          <tag-name>listItem</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIListItem</component-type>
          </component>
      </tag>
  
      <tag>
          <tag-name>font</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIFont</component-type>
          </component>
      </tag>
      
      <tag>
          <tag-name>image</tag-name>
          <component>
              <component-type>org.jboss.seam.pdf.ui.UIImage</component-type>
          </component>
      </tag>
  </facelet-taglib>
  
  
  


From norman.richards at jboss.com  Sun Dec 24 11:21:33 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:21:33 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf   ...
Message-ID: <E1GyW6P-0005Yb-3o@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:21:33

  Added:       src/pdf/org/jboss/seam/pdf   PDFPhaseListener.java
                        PDFStore.java
  Log:
  check in itext preview
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/PDFPhaseListener.java
  
  Index: PDFPhaseListener.java
  ===================================================================
  package org.jboss.seam.pdf;
  
  import org.jboss.seam.util.Parameters;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  
  import java.io.*;
  import java.util.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  //import org.jboss.seam.ui.facelet.*;
  
  public class PDFPhaseListener 
      implements PhaseListener 
  {
      public PhaseId getPhaseId() {
          return PhaseId.RENDER_RESPONSE;
      }
  
  
      public void afterPhase(PhaseEvent phaseEvent) {
          String rootId = phaseEvent.getFacesContext().getViewRoot().getViewId();
      }
  
  
      public void beforePhase(PhaseEvent phaseEvent) {
          String rootId = phaseEvent.getFacesContext().getViewRoot().getViewId();
          
          if (rootId.startsWith("/seam-pdf")) {
              String id = (String)
                  Parameters.convertMultiValueRequestParameter(Parameters.getRequestParameters(),
                                                               "pdfId",
                                                               String.class);
              sendPDF(phaseEvent.getFacesContext(), id);
          }
      }
  
      public void sendPDF(FacesContext context, String id) {
          try {
              PDFStore store = PDFStore.instance();
              byte[] data = store.getData(id);
  
              HttpServletResponse response = (HttpServletResponse) context.getExternalContext().getResponse();
              response.setContentType("application/pdf");
              if (data != null) {
                  response.getOutputStream().write(data);
              }
              context.responseComplete();
          } catch (IOException e) {
              e.printStackTrace();
          }
      }
  
  //     public void sendPDF(PhaseEvent phaseEvent) {
  //         try {
  //             FacesContext context = phaseEvent.getFacesContext();
  //             UIViewRoot viewRoot = context.getViewRoot();
  
  //             SeamFaceletViewHandler handler = (SeamFaceletViewHandler) 
  //                 context.getApplication().getViewHandler();
  //             handler.myBuildView(context, viewRoot);
              
  //             ExternalContext externalContext = context.getExternalContext();            
  //             HttpServletResponse response = (HttpServletResponse) externalContext.getResponse();
  //             response.setContentType("application/pdf");
               
  //             Document document = new Document();
  
  //             PdfWriter.getInstance(document, response.getOutputStream());
  
  //             document.open();
  //             document.add(new Paragraph("Hello World " + new Date()));
  //             document.close();
  
  //             context.responseComplete();
  //         } catch (DocumentException e) {
  //             e.printStackTrace();
  //         } catch (IOException e) {
  //             e.printStackTrace();
  //         }
  //     }
  
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/PDFStore.java
  
  Index: PDFStore.java
  ===================================================================
  package org.jboss.seam.pdf;
  
  import java.util.*;
  
  import org.jboss.seam.*;
  import org.jboss.seam.annotations.*;
  
  @Name("pdfstore")
  @Scope(ScopeType.SESSION)
  public class PDFStore {
      Map<String,byte[]> dataStore = new HashMap<String,byte[]>();
  
      long nextId = 1;
      
      public String newId() {
          return String.valueOf(nextId++);
      }
  
      public void saveData(String id, byte[] data) {
          dataStore.put(id,data);
      }
  
      public byte[] getData(String id) {
          return dataStore.get(id);
      }
  
      public static PDFStore instance()
      {
          return (PDFStore) Component.getInstance(PDFStore.class, true);
      }
  }
  
  
  


From norman.richards at jboss.com  Sun Dec 24 11:21:33 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 11:21:33 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui         ...
Message-ID: <E1GyW6P-0005Z3-9i@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 11:21:33

  Added:       src/pdf/org/jboss/seam/pdf/ui         ITextComponent.java
                        UIDocument.java UIFont.java UIImage.java
                        UIList.java UIListItem.java UIPage.java
                        UIParagraph.java
  Log:
  check in itext preview
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java
  
  Index: ITextComponent.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  
  import javax.faces.*;
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.convert.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  
  import java.awt.Color;
  import java.io.*;
  import java.util.List;
  
  import org.jboss.seam.ui.JSF;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public abstract class ITextComponent
      extends UIComponentBase
  {
      public static final String COMPONENT_FAMILY = "org.jboss.seam.pdf";    
  
    
      /**
       * get the current Itext object
       */
      abstract public Object getITextObject();
  
      /**
       * signal that the component should create it's managed object
       */
      abstract public void createITextObject();
  
      /** 
       * subcomponents should implement this
       */ 
      abstract public void add(Object other);
  
  
      /**
       *  look up the tree for an itext font
       */
      public Font getFont() {
          UIFont fontComponent = (UIFont) findITextParent(this, UIFont.class);
          return fontComponent == null ? null : fontComponent.getFont();
      }
  
      /**
       * look up the tree for the itext document
       */
      public Document findDocument() {
          ITextComponent parent = findITextParent(this, UIDocument.class);
          if (parent != null) {
              return (Document) parent.getITextObject();
          } else {
              return null;
          }
      }
  
  
      /**
       * find the first parent that is an itext component);
       */
      public ITextComponent findITextParent(UIComponent parent) {
          return findITextParent(parent, null);
      }
  
      /**
       * find the first parent that is an itext component of a given type
       */
      public ITextComponent findITextParent(UIComponent parent, Class c) {
          if (parent == null) {
              return null;
          }
          
          if (parent instanceof ITextComponent) {
              if (c==null || parent.getClass().equals(c)) {
                  return (ITextComponent) parent;
              }
          }
  
          return findITextParent(parent.getParent(),c);
      }
  
  
      /**
       * add a component (usually the current itext object) to the itext parent's itext object
       */
      public void addToITextParent(Object obj) {
          ITextComponent parent = findITextParent(getParent());
          if (parent != null) {
              parent.add(obj);
          } else {
              throw new RuntimeException("Couldn't find ITextComponent parent for component " + 
                                         this.getClass().getName());
          }
          
      }
  
      // ------------------------------------------------------
  
      @Override
      public String getFamily()
      {
          return COMPONENT_FAMILY;
      }
  
      @Override
      public boolean getRendersChildren() {
          return true;
      }
  
      @Override
      public void encodeBegin(FacesContext context) 
          throws IOException
      {
          createITextObject();
      }
  
      @Override
      public void encodeEnd(FacesContext context) 
          throws IOException
      {
          Object obj = getITextObject();
          if (obj != null) {
              addToITextParent(getITextObject());
          }
      }
  
      @Override
      public void encodeChildren(FacesContext context)
          throws IOException
      {
          for (UIComponent child: (List<UIComponent>) this.getChildren()) {
              // ugly hack to be able to capture facelets text
              if (child.getFamily().equals("facelets.LiteralText")) {
                  ResponseWriter response = context.getResponseWriter();
                  StringWriter stringWriter = new StringWriter();
                  ResponseWriter cachingResponseWriter = response.cloneWithWriter(stringWriter);
                  context.setResponseWriter(cachingResponseWriter);
  
                  JSF.renderChild(context, child);
  
                  context.setResponseWriter(response);
  
                  String text = stringWriter.getBuffer().toString();
                  Font   font = getFont();
                  if (font == null) {
                      Chunk chunk = new Chunk(text);
                      //chunk.setBackground(new Color(140,50,50));
                      add(chunk);
                  } else {
                      add(new Chunk(text, getFont()));
                  }
              } else {
                  encode(context, child);
              }
          }
      }
  
  
      public void encode(FacesContext context,
                         UIComponent component) 
          throws IOException, 
                 FacesException 
      {
          if (!component.isRendered()) {
              return;
          }
  
          component.encodeBegin(context);
  
          if (component.getChildCount() > 0) {
              if (component.getRendersChildren()) {
                  component.encodeChildren(context);
              } else {
                  for (UIComponent child: (List<UIComponent>) this.getChildren()) {
                      encode(context, child);
                  }
              }
          }
  
          component.encodeEnd(context);
      }
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIDocument.java
  
  Index: UIDocument.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import org.jboss.seam.pdf.PDFStore;
  
  import javax.faces.context.*;
  import javax.faces.component.*;
  
  import java.io.*;
  import java.util.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIDocument 
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIDocument";
  
      Document document;
      ByteArrayOutputStream stream;
      String id;
  
      public Object getITextObject() {
          return document;
      }
  
      public void createITextObject() {
          document=new Document();
      }
  
      public void add(Object o) {
          if (o instanceof Element) {
              try {
                  document.add((Element) o);
              } catch (DocumentException e) {
                  throw new RuntimeException(e);
              }
          } else {
              throw new IllegalArgumentException("cannot add " + o);
          }
      }
  
      @Override
      public void encodeBegin(FacesContext context) 
          throws IOException
      {
          id = PDFStore.instance().newId();
          document = new Document();
          stream = new ByteArrayOutputStream();
  
          try {
              PdfWriter.getInstance(document, stream);
  
              document.open();
          } catch (DocumentException e) {
              throw new RuntimeException(e);
          }
  
          ResponseWriter response = context.getResponseWriter();
          response.startElement("html", this);
          response.startElement("head", this);
          response.startElement("meta", this);
          response.writeAttribute("http-equiv", "Refresh", null);
          response.writeAttribute("content", "0; URL=seam-pdf.seam?pdfId="+id, null);
  
          response.endElement("meta");
          response.endElement("head");
  
          response.startElement("body",this);
      }
  
      @Override
      public void encodeEnd(FacesContext context) 
          throws IOException
      {
          document.close();
  
          PDFStore.instance().saveData(id,stream.toByteArray());
          
          ResponseWriter response = context.getResponseWriter();
          response.endElement("body");
          response.endElement("html");
      }
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIFont.java
  
  Index: UIFont.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIFont
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIParagraph";
  
  
      Font   font; 
      int    family = Font.UNDEFINED;
      int    size   = Font.UNDEFINED;
      String style; 
  
      public void setFamily(String name) {
          family = Font.getFamilyIndex(name);
      }
  
      public void setSize(int size) {
          this.size = size;
      }
  
      public void setStyle(String style) {
          this.style = style;
      }
  
      public Font getFont() {
          return font;
      }
         
              
      public Object getITextObject() {
          return null; // we don't add to this component, so skip
      }
  
      public void createITextObject() {
          font = new Font(family, size);
          if (style != null) {
              font.setStyle(style);
          }
      }
  
      public void add(Object o) {
          addToITextParent(o);
      }
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java
  
  Index: UIImage.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  
  import java.io.*;
  import java.net.URL;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIImage
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIImage";
  
      Image image;
      
      String resource;
      float  rotation;
      float  height;
      float  width;
  
      public void setResource(String resource) {
          this.resource = resource;
      }
  
      public void setRotation(float rotation) {
          this.rotation = rotation;
      }
  
      public void setHeight(float height) {
          this.height = height;
      }
  
      public void setWidth(float width) {
          this.width = width;
      }
  
      public Object getITextObject() {
          return image;
      }
  
      public void createITextObject() {
          
          URL url = Thread.currentThread().getContextClassLoader().getResource(resource);
          if (url == null) {
              throw new RuntimeException("cannot locate image resource " + resource);
          }
          try {
              image = Image.getInstance(url);
          } catch (Exception e) {
              throw new RuntimeException(e);
          }
  
          if (rotation != 0) {
              image.setRotationDegrees(rotation);
          }
  
          if (height>0 || width > 0) {
              image.scaleAbsolute(width, height);
          }
      }
  
      public void add(Object o) {
          throw new RuntimeException("can't add " + o.getClass().getName() + " to image");
          //image.add(o);
      }
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java
  
  Index: UIList.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIList
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIList";
  
      List list;
      
      boolean numbered = true;
      boolean lettered = false;
      float   indent   = 20f;
  
      public void setNumbered(boolean numbered) {
          this.numbered = numbered;
      }
  
      public void setLettered(boolean lettered) {
          this.lettered = lettered;
      }
  
      public void setIndent(float indent) {
          this.indent = indent;
      }
  
      public Object getITextObject() {
          return list;
      }
  
      public void createITextObject() {
          list = new List(numbered, lettered, indent);
      }
  
      public void add(Object o) {
          list.add(o);
      }
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIListItem.java
  
  Index: UIListItem.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIListItem
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE = "org.jboss.seam.pdf.ui.UIListItem";
  
      ListItem listItem;
      
      public Object getITextObject() {
          return listItem;
      }
  
      public void createITextObject() {
          listItem = new ListItem();
      }
  
      public void add(Object o) {
          listItem.add(o);
      }
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIPage.java
  
  Index: UIPage.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIPage
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIParagraph";
  
      public Object getITextObject() {
          return null;
      }
  
      public void createITextObject() {
          
      }
  
      public void add(Object o) {
          addToITextParent(o);
      }
  
      @Override
      public void encodeBegin(FacesContext context) 
          throws IOException
      {
          super.encodeBegin(context);
          Document document = findDocument();
          if (document != null) {
              try {
                  document.newPage();
              } catch (DocumentException e) {
                  throw new RuntimeException(e);
              }
          } else {
              throw new IllegalArgumentException("Cannot find parent document");
          }
      }
  
  }
  
  
  
  1.1      date: 2006/12/24 16:21:33;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java
  
  Index: UIParagraph.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIParagraph
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIParagraph";
  
      Paragraph paragraph;
      String alignment;
  
      public void setAlignment(String alignment) {
          this.alignment = alignment;
      }
  
      public Object getITextObject() {
          return paragraph;
      }
  
      public void createITextObject() {
          Font font = getFont();
          if (font == null) {
              paragraph = new Paragraph();
          } else {
              paragraph = new Paragraph("", font);
          }
  
          if (alignment !=null) {
              paragraph.setAlignment(alignment);
          }
      }
  
      public void add(Object o) {
          paragraph.add(o);
      }
  }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 24 12:43:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 24 Dec 2006 12:43:55 -0500
Subject: [jboss-cvs] JBossAS SVN: r59224 -
	projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi
Message-ID: <E1GyXO7-0006sx-Vd@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-24 12:43:52 -0500 (Sun, 24 Dec 2006)
New Revision: 59224

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java
Log:
msg typo

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java	2006-12-24 13:56:30 UTC (rev 59223)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/spi/NumberInfo.java	2006-12-24 17:43:52 UTC (rev 59224)
@@ -117,7 +117,7 @@
    {
       if (info instanceof ClassInfo == false)
       {
-         throw new IllegalArgumentException("Should be of classType instance: " + info);
+         throw new IllegalArgumentException("Should be of ClassInfo instance: " + info);
       }
       delegate = (ClassInfo) info;
    }



From jboss-cvs-commits at lists.jboss.org  Sun Dec 24 14:25:00 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 24 Dec 2006 14:25:00 -0500
Subject: [jboss-cvs] JBossAS SVN: r59225 -
	trunk/ejb3/src/main/org/jboss/ejb3/deployers
Message-ID: <E1GyYxw-0000Bl-26@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-24 14:24:58 -0500 (Sun, 24 Dec 2006)
New Revision: 59225

Modified:
   trunk/ejb3/src/main/org/jboss/ejb3/deployers/EJBRegistrationDeployer.java
Log:
Make sure the stream used to check for ejb3 ejb-jar.xml is closed.

Modified: trunk/ejb3/src/main/org/jboss/ejb3/deployers/EJBRegistrationDeployer.java
===================================================================
--- trunk/ejb3/src/main/org/jboss/ejb3/deployers/EJBRegistrationDeployer.java	2006-12-24 17:43:52 UTC (rev 59224)
+++ trunk/ejb3/src/main/org/jboss/ejb3/deployers/EJBRegistrationDeployer.java	2006-12-24 19:24:58 UTC (rev 59225)
@@ -33,6 +33,8 @@
 import org.jboss.logging.Logger;
 
 import javax.management.MBeanServer;
+
+import java.io.InputStream;
 import java.util.HashSet;
 import java.util.Properties;
 import java.util.List;
@@ -137,7 +139,10 @@
          VirtualFile ejbjar = unit.getMetaDataFile("ejb-jar.xml");
          if (ejbjar != null)
          {
-            if (!EJB3Deployer.has30EjbJarXml(ejbjar.openStream())) return;
+            InputStream is = ejbjar.openStream();
+            boolean has30EjbJarXml = EJB3Deployer.has30EjbJarXml(is);
+            is.close();
+            if (!has30EjbJarXml) return;
          }
          DeploymentScope scope = null;
          DeploymentContext parent = unit.getDeploymentContext().getParent();



From norman.richards at jboss.com  Sun Dec 24 14:29:01 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:29:01 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf  ...
Message-ID: <E1GyZ1p-0000GM-IV@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:29:01

  Added:       src/pdf/org/jboss/seam/pdf  ITextUtils.java
  Log:
  update for the demo
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:29:01;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java
  
  Index: ITextUtils.java
  ===================================================================
  package org.jboss.seam.pdf;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class ITextUtils {
      /**
       *  not all itext objects accept a string value as input,
       *  so we'll copy that logic here. 
       */
      public static int alignmentValue(String alignment) {
          if (ElementTags.ALIGN_CENTER.equalsIgnoreCase(alignment)) {
              return Element.ALIGN_CENTER;
          }
          if (ElementTags.ALIGN_RIGHT.equalsIgnoreCase(alignment)) {
              return Element.ALIGN_RIGHT;
          }
          if (ElementTags.ALIGN_JUSTIFIED.equalsIgnoreCase(alignment)) {
              return Element.ALIGN_JUSTIFIED;
          }
          if (ElementTags.ALIGN_JUSTIFIED_ALL.equalsIgnoreCase(alignment)) {
              return Element.ALIGN_JUSTIFIED_ALL;
          }
  
          return Element.ALIGN_LEFT;
      }
  }
  
  
  


From norman.richards at jboss.com  Sun Dec 24 14:29:01 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:29:01 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui   ...
Message-ID: <E1GyZ1p-0000GW-M0@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:29:01

  Modified:    src/pdf/org/jboss/seam/pdf/ui   UIImage.java UIList.java
  Log:
  update for the demo
  
  Revision  Changes    Path
  1.2       +22 -0     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIImage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIImage.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIImage.java	24 Dec 2006 19:29:01 -0000	1.2
  @@ -1,5 +1,7 @@
   package org.jboss.seam.pdf.ui;
   
  +import org.jboss.seam.pdf.ITextUtils;
  +
   import javax.faces.event.*;
   import javax.faces.context.*;
   import javax.faces.component.*;
  @@ -22,6 +24,8 @@
       float  rotation;
       float  height;
       float  width;
  +    String alignment;
  +    String alt;
   
       public void setResource(String resource) {
           this.resource = resource;
  @@ -39,10 +43,20 @@
           this.width = width;
       }
   
  +    public void setAlignment(String alignment) {
  +        this.alignment = alignment;
  +    }
  +
  +    public void setAlt(String alt) {
  +        this.alt = alt;
  +    }
  +
       public Object getITextObject() {
           return image;
       }
   
  +    
  +
       public void createITextObject() {
           
           URL url = Thread.currentThread().getContextClassLoader().getResource(resource);
  @@ -62,6 +76,14 @@
           if (height>0 || width > 0) {
               image.scaleAbsolute(width, height);
           }
  +
  +        if (alignment != null) {
  +            image.setAlignment(ITextUtils.alignmentValue(alignment));
  +        }
  +
  +        if (alt != null) {
  +            image.setAlt(alt);
  +        }
       }
   
       public void add(Object o) {
  
  
  
  1.2       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIList.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIList.java	24 Dec 2006 19:29:01 -0000	1.2
  @@ -16,7 +16,7 @@
   
       List list;
       
  -    boolean numbered = true;
  +    boolean numbered = false;
       boolean lettered = false;
       float   indent   = 20f;
   
  
  
  


From norman.richards at jboss.com  Sun Dec 24 14:44:26 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:44:26 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf - New directory ...
Message-ID: <E1GyZGk-0000YJ-G5@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:44:26

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:44:55 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:44:55 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view - New directory ...
Message-ID: <E1GyZHD-0000YU-Fm@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:44:55

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/view added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:19 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:19 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/resources - New directory ...
Message-ID: <E1GyZMR-0000dj-61@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:19

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/resources added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:56 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src - New directory ...
Message-ID: <E1GyZN2-0000ec-GX@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:56

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/src added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:56 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src/org - New directory ...
Message-ID: <E1GyZN2-0000eg-JJ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:56

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/src/org added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:56 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src/org/jboss - New directory ...
Message-ID: <E1GyZN2-0000ek-NJ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:56

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/src/org/jboss added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:56 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src/org/jboss/seam - New
	directory ...
Message-ID: <E1GyZN2-0000eo-Rq@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:56

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/src/org/jboss/seam added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:56 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:56 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src/org/jboss/seam/example - New
	directory ...
Message-ID: <E1GyZN2-0000es-VH@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:56

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/src/org/jboss/seam/example added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:50:57 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:50:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src/org/jboss/seam/example/pdf -
	New directory ...
Message-ID: <E1GyZN3-0000ew-37@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:50:57

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/src/org/jboss/seam/example/pdf added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:52:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:52:32 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/resources/META-INF - New
	directory ...
Message-ID: <E1GyZOa-0000hc-L4@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:52:32

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/resources/META-INF added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:53:04 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:53:04 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/resources/WEB-INF - New directory
	...
Message-ID: <E1GyZP6-0000hq-Ex@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:53:04

  Log:
  Directory /cvsroot/jboss/jboss-seam/examples/pdf/resources/WEB-INF added to the repository


From norman.richards at jboss.com  Sun Dec 24 14:58:08 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:58:08 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf  ...
Message-ID: <E1GyZU0-0000m5-R0@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:58:08

  Added:       examples/pdf  build.xml
  Log:
  add pdf example
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:58:08;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/build.xml
  
  Index: build.xml
  ===================================================================
  <?xml version="1.0"?>
  
  <project name="pdf" default="deploy" basedir=".">
  
      <!-- Example name -->
      <property name="Name"                   value="PDF Example"/>
      <property name="example.name"           value="jboss-seam-pdf"/>
  
      <!-- Overrides -->
      <property name="example.webinf.lib.dir"  value="."/>
      <property name="example.seam.ui.lib"     value="yes"/>
      <property name="example.seam.pdf.lib"    value="yes"/>
      <property name="example.seam.debug.lib"  value="yes"/>
      <property name="example.facelets.lib"    value="yes"/>
      <property name="src.java.dir"            value="src"/>
      <property name="src.test.dir"            value="src"/>
      <property name="test.classpath"          value="test.eejb.classpath"/>
      <property name="tomcat.conf"             value="eejb.conf"/>  
      
      <import file="../../build.xml"/>
  </project>
  
  
  
  


From norman.richards at jboss.com  Sun Dec 24 14:58:08 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:58:08 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/resources    ...
Message-ID: <E1GyZU0-0000mH-Ux@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:58:08

  Added:       examples/pdf/resources    components.properties import.sql
                        seam.properties
  Log:
  add pdf example
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:58:08;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/components.properties
  
  Index: components.properties
  ===================================================================
  embeddedEjb true
  jndiPattern #{ejbName}/local
  
  
  1.1      date: 2006/12/24 19:58:08;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/import.sql
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/24 19:58:08;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/seam.properties
  
  	<<Binary file>>
  
  


From norman.richards at jboss.com  Sun Dec 24 14:58:09 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:58:09 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/resources/META-INF     ...
Message-ID: <E1GyZU1-0000mX-3d@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:58:09

  Added:       examples/pdf/resources/META-INF     application.xml
                        ejb-jar.xml jboss-app.xml persistence.xml
  Log:
  add pdf example
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/META-INF/application.xml
  
  Index: application.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <application xmlns="http://java.sun.com/xml/ns/javaee" 
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd"
               version="5">
      
      <display-name>Seam Pdf Example</display-name>
      
      <module>
          <web>
              <web-uri>jboss-seam-pdf.war</web-uri>
              <context-root>/seam-pdf</context-root>
          </web>
      </module>
      <module>
          <ejb>jboss-seam-pdf.jar</ejb>
      </module>
      <module>
          <java>jboss-seam.jar</java>
      </module>
      <module>
          <java>el-api.jar</java>
      </module>
      <module>
          <java>el-ri.jar</java>
      </module>
  
  </application>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/META-INF/ejb-jar.xml
  
  Index: ejb-jar.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <ejb-jar xmlns="http://java.sun.com/xml/ns/javaee"
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
           xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" 
           version="3.0">
  
      <interceptors>
          <interceptor>
              <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
          </interceptor>
      </interceptors>
      
      <assembly-descriptor>
          <interceptor-binding>
              <ejb-name>*</ejb-name>
              <interceptor-class>org.jboss.seam.ejb.SeamInterceptor</interceptor-class>
          </interceptor-binding>
      </assembly-descriptor>
  </ejb-jar>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/META-INF/jboss-app.xml
  
  Index: jboss-app.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE jboss-app PUBLIC "-//JBoss//DTD J2EE Application 1.4//EN"
                             "http://www.jboss.org/j2ee/dtd/jboss-app_4_0.dtd">
  <jboss-app>
      <loader-repository> 
          seam.jboss.org:loader=seam-pdf
      </loader-repository> 
  </jboss-app> 
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/META-INF/persistence.xml
  
  Index: persistence.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <persistence xmlns="http://java.sun.com/xml/ns/persistence"
               xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd" 
               version="1.0">
      <persistence-unit name="userDatabase">
          <provider>org.hibernate.ejb.HibernatePersistence</provider>
          <jta-data-source>java:/DefaultDS</jta-data-source>
          <properties>
              <property name="hibernate.hbm2ddl.auto" value="create-drop"/>
              <property name="hibernate.show_sql" value="true"/>
              <property name="jboss.entity.manager.factory.jndi.name" 
                        value="java:/seampdfEntityManagerFactory"/>
          </properties>
      </persistence-unit>
  </persistence>
  
  
  


From norman.richards at jboss.com  Sun Dec 24 14:58:09 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:58:09 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/resources/WEB-INF       ...
Message-ID: <E1GyZU1-0000mt-97@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:58:09

  Added:       examples/pdf/resources/WEB-INF       components.xml
                        components.xml.bak exceptions.xml faces-config.xml
                        pages.xml web.xml
  Log:
  add pdf example
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/WEB-INF/components.xml
  
  Index: components.xml
  ===================================================================
  <components xmlns:pay="http://jboss.com/products/seam/examples/seampay"
              xmlns:core="http://jboss.com/products/seam/core"
              xmlns:framework="http://jboss.com/products/seam/framework">
  
      <core:managed-persistence-context name="entityManager"
                                        persistence-unit-jndi-name="java:/seampdfEntityManagerFactory" />
  
      <core:dispatcher />
  
      <core:init debug="true" jndi-pattern="@jndiPattern@" />
      <core:ejb installed="@embeddedEjb@" /> 
  </components>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/WEB-INF/components.xml.bak
  
  Index: components.xml.bak
  ===================================================================
  <components xmlns:pay="http://jboss.com/products/seam/examples/seampay"
              xmlns:core="http://jboss.com/products/seam/core"
              xmlns:framework="http://jboss.com/products/seam/framework">
  
      <pay:foo the-value="wheeee!!" />
      <pay:paymentHome>
          <pay:newInstance>#{newPayment}</pay:newInstance>
          <pay:createdMessage>Created a new payment to #{newPayment.payee}</pay:createdMessage>
      </pay:paymentHome>
  
      <pay:Payment name="newPayment">
          <pay:payee>Somebody</pay:payee>
          <pay:account>#{selectedAccount}</pay:account>
          <pay:paymentDate>#{currentDatetime}</pay:paymentDate>
          <pay:createdDate>#{currentDatetime}</pay:createdDate>
      </pay:Payment>
  
      <factory name="selectedAccount" value="#{accountHome.instance}"/>
      <framework:EntityHome name="accountHome" 
                            entity-class="org.jboss.seam.example.seampay.Account"
                            entity-manager="#{entityManager}" />
  
      <framework:EntityQuery name="accounts">
          <framework:ejbql>from Account</framework:ejbql>
          <framework:order>accountNumber</framework:order>
          <framework:maxResults>20</framework:maxResults>
          <framework:entityManager>#{entityManager}</framework:entityManager>
      </framework:EntityQuery>
          
      <core:ManagedPersistenceContext name="entityManager" >
          <core:persistenceUnitJndiName>java:/seampayEntityManagerFactory</core:persistenceUnitJndiName>
      </core:ManagedPersistenceContext>
          
      <core:Dispatcher />
  
      <core:init></core:init>
      
      <core:init>
          <core:debug>true</core:debug>
          <core:jndiPattern>@jndiPattern@</core:jndiPattern>
      </core:init>
  
      <!-- <core:Ejb installed="@embeddedEjb@" />  -->
  </components>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/WEB-INF/exceptions.xml
  
  Index: exceptions.xml
  ===================================================================
  <!DOCTYPE exceptions PUBLIC
    "-//JBoss/Seam Exceptions Configuration DTD 1.1//EN"
    "http://jboss.com/products/seam/exceptions-1.1.dtd">
  
  <exceptions>
     <exception>
        <redirect view-id="/error.xhtml"/>
        <end-conversation/>
     </exception>
  </exceptions>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/WEB-INF/faces-config.xml
  
  Index: faces-config.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <!DOCTYPE faces-config PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN" 
                                "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
  <faces-config>
      <!-- Facelets support -->
      <application>
          <view-handler>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</view-handler>
      </application>
  
      <!-- Phase listener needed for all Seam applications -->
      <lifecycle>
          <phase-listener>org.jboss.seam.jsf.TransactionalSeamPhaseListener</phase-listener>
      </lifecycle>
  </faces-config>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/WEB-INF/pages.xml
  
  Index: pages.xml
  ===================================================================
  <!DOCTYPE pages PUBLIC
    "-//JBoss/Seam Pages Configuration DTD 1.1//EN"
    "http://jboss.com/products/seam/pages-1.1.dtd">
  
  <pages>
     <page view-id="/search.xhtml">
            <param name="accountId" value="#{accountHome.id}" converterId="javax.faces.Long" />
     </page>
  </pages>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/resources/WEB-INF/web.xml
  
  Index: web.xml
  ===================================================================
  <?xml version="1.0" encoding="UTF-8"?>
  <web-app version="2.4" 
           xmlns="http://java.sun.com/xml/ns/j2ee"
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
      <!-- Seam -->
      <listener>
          <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
      </listener>
      
      <filter>
          <filter-name>Seam Redirect Filter</filter-name>
          <filter-class>org.jboss.seam.servlet.SeamRedirectFilter</filter-class>
      </filter>
      
      <filter-mapping>
          <filter-name>Seam Redirect Filter</filter-name>
          <url-pattern>*.seam</url-pattern>
      </filter-mapping>
  
      <filter>
          <filter-name>Seam Exception Filter</filter-name>
          <filter-class>org.jboss.seam.servlet.SeamExceptionFilter</filter-class>
      </filter>
      <filter-mapping>
          <filter-name>Seam Exception Filter</filter-name>
          <url-pattern>*.seam</url-pattern>
      </filter-mapping>
  
      <context-param>
          <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
          <param-value>.xhtml</param-value>
      </context-param>
  
      <context-param>
          <param-name>facelets.DEVELOPMENT</param-name>
          <param-value>true</param-value>
      </context-param>
  
      <!-- MyFaces -->
  
      <listener>
          <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
      </listener>
      
      <context-param>
          <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
          <param-value>client</param-value>
      </context-param>
      
      <servlet>
          <servlet-name>Faces Servlet</servlet-name>
          <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
          <load-on-startup>1</load-on-startup>
      </servlet>
      
      <!-- Faces Servlet Mapping -->
      <servlet-mapping>
          <servlet-name>Faces Servlet</servlet-name>
          <url-pattern>*.seam</url-pattern>
      </servlet-mapping>
      
  </web-app>
  
  
  


From norman.richards at jboss.com  Sun Dec 24 14:58:09 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:58:09 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/src/org/jboss/seam/example/pdf ...
Message-ID: <E1GyZU1-0000n0-Cm@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:58:09

  Added:       examples/pdf/src/org/jboss/seam/example/pdf  Lists.java
  Log:
  add pdf example
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/src/org/jboss/seam/example/pdf/Lists.java
  
  Index: Lists.java
  ===================================================================
  package org.jboss.seam.example.pdf;
  
  import org.jboss.seam.annotations.*;
  
  @Name("lists")
  public class Lists{
  
      String[] numbers = {"one", "two", "three", "four", "five"};
      String[] daysOfWeek = {"Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"};
      
      public String[] getNumbers() {
          return numbers;
      }
  
      public String[] getDaysOfWeek() {
          return daysOfWeek;
      }
  
  }
  
  
  


From norman.richards at jboss.com  Sun Dec 24 14:58:09 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 14:58:09 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view       ...
Message-ID: <E1GyZU1-0000nL-HR@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 14:58:09

  Added:       examples/pdf/view       index.html index.xhtml jboss.jpg
                        lists.xhtml pages.xhtml whyseam.xhtml
  Log:
  add pdf example
  
  Revision  Changes    Path
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/index.html
  
  Index: index.html
  ===================================================================
  <html>
  <head>
    <meta http-equiv="Refresh" content="0; URL=index.seam" />
  </head>
  </html>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/index.xhtml
  
  Index: index.xhtml
  ===================================================================
  <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml"
        xmlns:ui="http://java.sun.com/jsf/facelets"
        xmlns:s="http://jboss.com/products/seam/taglib"
        xmlns:h="http://java.sun.com/jsf/html"
        xmlns:f="http://java.sun.com/jsf/core">
  
  <head>
      <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
      <title>Seam PDF</title>
      <ui:remove><link href="screen.css" rel="stylesheet" type="text/css" /></ui:remove>
  </head>
  <body>
        
      <ul>
          <li><s:link view="/whyseam.xhtml" value="Why Seam?" /></li>
          <li><s:link view="/lists.xhtml"   value="PDF Lists" /></li>
          <li><s:link view="/pages.xhtml"   value="Multiple Pages" /></li>
      </ul>
      
  </body>
  </html>
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/jboss.jpg
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/lists.xhtml
  
  Index: lists.xhtml
  ===================================================================
  <p:document xmlns="http://www.w3.org/1999/xhtml"
              xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:s="http://jboss.com/products/seam/taglib"
              xmlns:p="http://jboss.com/products/seam/pdf">
      <p:image alignment="right" resource="jboss.jpg" />
  
      <p:paragraph>Basic list:</p:paragraph>
      <p:list>
          <ui:repeat value="#{lists.numbers}" var="item">
              <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
          </ui:repeat>
      </p:list>
  
      <p:paragraph>Numbered:</p:paragraph>
      <p:list numbered="true">
          <ui:repeat value="#{lists.numbers}" var="item">
              <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
          </ui:repeat>
      </p:list>
  
      <p:paragraph>Lettered:</p:paragraph>
      <p:list lettered="true">
          <ui:repeat value="#{lists.numbers}" var="item">
              <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
          </ui:repeat>
      </p:list>
  
      <p:paragraph>SubLists:</p:paragraph>
      <p:list>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:listItem>Things to do on #{day}
                  <p:list>
                      <ui:repeat value="#{lists.numbers}" var="number">
                          <p:listItem>Do thing #{number}</p:listItem>
                      </ui:repeat>
                  </p:list>
              </p:listItem>
          </ui:repeat>
      </p:list>
  </p:document>    
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/pages.xhtml
  
  Index: pages.xhtml
  ===================================================================
  <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:s="http://jboss.com/products/seam/taglib"
              xmlns:p="http://jboss.com/products/seam/pdf">
  
      <ui:repeat value="#{lists.numbers}" var="number">
          <p:newPage />
          <p:image alignment="right" resource="jboss.jpg" />
          
          <p:font family="Helvetica" size="36">
              <p:paragraph alignment="center">Page #{number}</p:paragraph>
          </p:font>
  
          <p:font family="Helvetica">
              <p:paragraph alignment="justify">JBoss Seam is a powerful new application framework for building next generation Web 2.0 applications by unifying and integrating technologies such as Asynchronous JavaScript and XML (AJAX), Java Server Faces (JSF), Enterprise Java Beans (EJB3), Java Portlets and Business Process Management (BPM).</p:paragraph>
  
              <p:paragraph alignment="justify">Seam has been designed from the ground up to eliminate complexity at the architecture and the API level. It enables developers to assemble complex web applications with simple annotated Plain Old Java Objects (POJOs), componentized UI widgets and very little XML. The simplicity of Seam 1.0 will enable easy integration with the JBoss Enterprise Service Bus (ESB) and Java Business Integration (JBI) in the future.</p:paragraph>
          </p:font>
  
      </ui:repeat>
  </p:document>
  
  
  
  
  1.1      date: 2006/12/24 19:58:09;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/whyseam.xhtml
  
  Index: whyseam.xhtml
  ===================================================================
  <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:p="http://jboss.com/products/seam/pdf">
  
      <p:image alignment="right" resource="jboss.jpg" />
  
      <p:font size="24"><p:paragraph>Ten Good Reasons To Use Seam</p:paragraph></p:font>
  
      <p:font size="18"><p:paragraph>It's the quickest way to get "rich"</p:paragraph></p:font>
  
      <p:paragraph alignment="justify">AJAX fundamentally changes the interaction model of the web. The synchronous, coarse-grained requests used by traditional web clients let many server-side applications get away with minimal caching and no session-level concurrency. The "stateless" architecture is in many cases a viable solution. But not anymore! AJAX clients hit the server with many asynchronous, concurrent, fine-grained requests, which could easily bring your database to its knees. When state is held in memory between requests, it is highly vulnerable to concurrency-related bugs, since the Java EE platform provides no constructs for dealing with session-level concurrency.</p:paragraph>
  
      <p:paragraph alignment="justify">Seam's totally unique concurrency model and state-management model was conceived and designed with AJAX in mind. </p:paragraph>
  
      <p:paragraph alignment="justify">Seam 1.1 integrates open source JSF-based AJAX solutions like ICEfaces and Ajax4JSF with Seam's state and concurrency management engine. You can add AJAX to your applications with ease, without the need to learn JavaScript, and you will be protected from potential bugs and performance problems associated with the switch to AJAX. </p:paragraph>
  
      <p:font size="18"><p:paragraph>It's the easiest way to get started with EJB 3.0 </p:paragraph></p:font>
      <p:paragraph alignment="justify">EJB 3.0 is a great component model for transactional business components, the highlight being the brand new Java Persistence API (JPA). But Java web and application frameworks designed before the release of EJB 3.0 lack support for the new component model, leaving you to write your own integration code, and in many cases forcing you into the use of a layered architecture that may not be right for your application. </p:paragraph>
  
      <p:paragraph alignment="justify">Seam was designed for use with EJB 3.0 and lets you use the new component model everywhere. Since any class in a Seam application can be an EJB component, there is no need to introduce extra unwanted layers just to keep your frameworks happy. And, of course, there is no need to write code to integrate EJB 3.0 with your web framework, since Seam already has it. </p:paragraph>
  
      <p:paragraph alignment="justify">Note that you don't have to use EJB 3.0 to use Seam, and if you're developing in an environment that doesn't support EJB 3.0, Seam provides alternatives. </p:paragraph>
  
      <p:font size="18"><p:paragraph>It's the best way to leverage JSF </p:paragraph></p:font>
      <p:paragraph alignment="justify">JSF has created a vibrant ecosystem of component libraries and other addons, that make this easily the most exciting web framework in Java. But plain JSF is heavy on XML, and misses out on a number of important features, especially for people building internet-facing applications. Seam replaces the tedious XML configuration with a handful of annotations, reducing code and making you more productive. Seam extends JSF with extra functionality for multi-window operation and workspace management, model-based validation, jBPM-based pageflow, internationalization, page fragment caching. Seam even adds facilities for handling bookmarkable (REST-style) web pages - the number one user complaint against JSF. </p:paragraph>
  
      <p:paragraph alignment="justify">Since JSF does not address the problem of access to transactional resources, Seam's integration of JTA, JPA and EJB 3.0 is a must-have for most JSF users. </p:paragraph>
  
      <p:font size="18"><p:paragraph>And the easiest way to do BPM </p:paragraph></p:font>
      <p:paragraph alignment="justify">jBPM is an intuitive and powerful solution for enterprise applications with complex human collaboration, or web applications with complex user interactions. BPM technology not only makes it easier for developers and analysts to model, implement and optimize a business process, but also makes it possible for operations and management to analyse the efficiency of the business process, and be informed of problems. </p:paragraph>
  
      <p:paragraph alignment="justify">Seam deeply integrates jBPM and makes it incredibly simple to use jBPM for task management or pageflow, and is a great way to get started with BPM technology. The combination of Seam and jBPM can shrink development time of some kinds of projects by literally months. </p:paragraph>
  
      <p:font size="18"><p:paragraph>But CRUD is easy too </p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam takes on hard problems affecting complex enterprise applications. But that doesn't mean the easy stuff is any more difficult than it should be. Seam is every bit as productive as any of the current crop of CRUD frameworks when it comes to building simple data driven applications. Seam combines a simple data access framework (built around JPA and Hibernate) with a command line code generation and database reverse engineering tool to get you started in minutes. </p:paragraph>
  
      <p:font size="18"><p:paragraph>It makes persistence a breeze </p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam grew out of the Hibernate community, and was designed and implemented by the people who created Hibernate, the same people who coined the term "persistence context". Seam's conversation model solves a raft of persistence-related programming problems caused by traditional stateless web application architectures. Whether you use Hibernate or JPA, Seam makes it easy and natural to use extended persistence contexts, and helps you avoid unnecessary state replication when you use an extended persistence context in a clustered environment. </p:paragraph>
  
      <p:font size="18"><p:paragraph>Annotations </p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam is the first programming model that lets you use Java 5 annotations end to end, from the persistence layer to the UI. You'll never find yourself wrestling with unnecessary, noisy XML. Which is not to say that Seam doesn't use XML when appropriate (Seam has a sophisticated XML-based component configuration facility), just that you won't get lost in reams of XML for common programming tasks. </p:paragraph>
  
      <p:font size="18"><p:paragraph>Get hip to automated integration testing </p:paragraph></p:font>
      <p:paragraph alignment="justify">Automated unit tests certainly have their place in any project. But it's worse than dangerous to rely solely on unit testing. Most bugs concern the interaction between components, and the interaction between a component and the container environment. Unit tests are unable to properly capture container behavior, and usually don't capture complex inter-component interactions. Seam introduces an innovative approach to automated integration testing, where you can emulate the entire flow of a request or conversation, testing all layers of Java code in the application, from presentation to persistence. </p:paragraph>
  
      <p:font size="18"><p:paragraph>Marry open source with open standards </p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam is founded upon open source implementations of open standards like JSF and EJB 3.0, along with open source innovators like Hibernate, jBPM, Facelets, Drools, ICEfaces and Ajax4JSF. The creators of Seam are active in the EJB, JPA, Bean Validation and JSF expert groups and lead the Web Beans (JSR-299) expert group which aims to bring the ideas of Seam into the Java EE standard. The Seam project is totally committed to the idea of open source innovation driving new ideas and ehancements into the Java platform. </p:paragraph>
  
      <p:font size="18"><p:paragraph>It just works </p:paragraph></p:font>
      <p:paragraph alignment="justify">You'll love it if you try it.</p:paragraph>
  </p:document>
  
  
  
  


From norman.richards at jboss.com  Sun Dec 24 17:54:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 17:54:32 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/META-INF   ...
Message-ID: <E1GycEi-0003l2-9O@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 17:54:32

  Modified:    src/pdf/META-INF   faces-config.xml seam.taglib.xml
  Log:
  add UIAnchor, add UIParagraph properties
  
  Revision  Changes    Path
  1.2       +5 -0      jboss-seam/src/pdf/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/META-INF/faces-config.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- faces-config.xml	24 Dec 2006 16:21:32 -0000	1.1
  +++ faces-config.xml	24 Dec 2006 22:54:32 -0000	1.2
  @@ -39,6 +39,11 @@
           <component-class>org.jboss.seam.pdf.ui.UIImage</component-class>
       </component>
   
  +    <component>
  +        <component-type>org.jboss.seam.pdf.ui.UIAnchor</component-type>
  +        <component-class>org.jboss.seam.pdf.ui.UIAnchor</component-class>
  +    </component>
  +
       <lifecycle>
           <phase-listener>org.jboss.seam.pdf.PDFPhaseListener</phase-listener>
       </lifecycle>
  
  
  
  1.2       +8 -0      jboss-seam/src/pdf/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/META-INF/seam.taglib.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- seam.taglib.xml	24 Dec 2006 16:21:32 -0000	1.1
  +++ seam.taglib.xml	24 Dec 2006 22:54:32 -0000	1.2
  @@ -54,4 +54,12 @@
               <component-type>org.jboss.seam.pdf.ui.UIImage</component-type>
           </component>
       </tag>
  +
  +    <tag>
  +        <tag-name>anchor</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.pdf.ui.UIAnchor</component-type>
  +        </component>
  +    </tag>
  +
   </facelet-taglib>
  
  
  


From norman.richards at jboss.com  Sun Dec 24 17:54:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 17:54:32 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui   ...
Message-ID: <E1GycEi-0003lC-Cf@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 17:54:32

  Modified:    src/pdf/org/jboss/seam/pdf/ui   UIParagraph.java
  Added:       src/pdf/org/jboss/seam/pdf/ui   UIAnchor.java
  Log:
  add UIAnchor, add UIParagraph properties
  
  Revision  Changes    Path
  1.2       +72 -1     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIParagraph.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIParagraph.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIParagraph.java	24 Dec 2006 22:54:32 -0000	1.2
  @@ -17,10 +17,51 @@
       Paragraph paragraph;
       String alignment;
   
  +    
  +    Float firstLineIndent;
  +    Float extraParagraphSpace;
  +    Float leading;
  +    Float multipliedLeading;
  +    Float spacingBefore;
  +    Float spacingAfter;
  +    Float indentationLeft;
  +    Float indentationRight;
  +
  +    Boolean keepTogether;
  +
       public void setAlignment(String alignment) {
           this.alignment = alignment;
       }
   
  +    public void setFirstLineIndent(Float firstLineIndent) {
  +        this.firstLineIndent = firstLineIndent;
  +    }
  +
  +    public void setExtraParagraphSpace(Float extraParagraphSpace) {
  +        this.extraParagraphSpace = extraParagraphSpace;
  +    }
  +    public void setLeading(Float leading) {
  +        this.leading = leading;
  +    }
  +    public void setMultipliedLeading(Float multipliedLeading) {
  +        this.multipliedLeading = multipliedLeading;
  +    }
  +    public void setSpacingBefore(Float spacingBefore) {
  +        this.spacingBefore = spacingBefore;
  +    }
  +    public void setSpacingAfter(Float spacingAfter) {
  +        this.spacingAfter = spacingAfter;
  +    }
  +    public void setIndentationLeft(Float indentationLeft) {
  +        this.indentationLeft = indentationLeft;
  +    }
  +    public void setIndentationRight(Float indentationRight) {
  +        this.indentationRight = indentationRight;
  +    }
  +    public void setKeepTogether(Boolean keepTogether) {
  +        this.keepTogether = keepTogether;
  +    }
  +
       public Object getITextObject() {
           return paragraph;
       }
  @@ -33,9 +74,39 @@
               paragraph = new Paragraph("", font);
           }
   
  -        if (alignment !=null) {
  +        if (alignment != null) {
               paragraph.setAlignment(alignment);
           }
  +        
  +        if (firstLineIndent != null) {
  +            paragraph.setFirstLineIndent(firstLineIndent);
  +        }
  +
  +        if (extraParagraphSpace != null) {
  +            paragraph.setExtraParagraphSpace(extraParagraphSpace);
  +        }
  +        if (leading != null) {
  +            if (multipliedLeading != null) {
  +                paragraph.setLeading(leading, multipliedLeading);
  +            } else {
  +                paragraph.setLeading(leading);
  +            }
  +        }
  +        if (spacingBefore != null) {
  +            paragraph.setSpacingBefore(spacingBefore);
  +        }
  +        if (spacingAfter != null) {
  +            paragraph.setSpacingAfter(spacingAfter);
  +        }
  +        if (indentationLeft != null) {
  +            paragraph.setIndentationLeft(indentationLeft);
  +        }
  +        if (indentationRight != null) {
  +            paragraph.setIndentationRight(indentationRight);
  +        }
  +        if (keepTogether != null) {
  +            paragraph.setKeepTogether(keepTogether);
  +        }
       }
   
       public void add(Object o) {
  
  
  
  1.1      date: 2006/12/24 22:54:32;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java
  
  Index: UIAnchor.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIAnchor
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIAnchor";
  
      Anchor anchor;
      
      String name;
      String reference;
  
      public void setName(String name) {
          this.name = name;
      }
      public void setReference(String reference) {
          this.reference = reference;
      }
  
      public Object getITextObject() {
          return anchor;
      }
  
      public void createITextObject() {
          anchor = new Anchor();
  
          if (name != null) {
              anchor.setName(name);
          }
  
          if (reference != null) {
              anchor.setReference(reference);
          }
      }
  
      public void add(Object o) {
          anchor.add(o);
      }
  }
  
  
  


From norman.richards at jboss.com  Sun Dec 24 17:57:32 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 24 Dec 2006 17:57:32 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view   ...
Message-ID: <E1GycHc-0003pi-8x@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/24 17:57:32

  Modified:    examples/pdf/view   index.xhtml
  Added:       examples/pdf/view   anchor.xhtml
  Log:
  add anchor example
  
  Revision  Changes    Path
  1.2       +1 -0      jboss-seam/examples/pdf/view/index.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: index.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/index.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- index.xhtml	24 Dec 2006 19:58:09 -0000	1.1
  +++ index.xhtml	24 Dec 2006 22:57:32 -0000	1.2
  @@ -16,6 +16,7 @@
           <li><s:link view="/whyseam.xhtml" value="Why Seam?" /></li>
           <li><s:link view="/lists.xhtml"   value="PDF Lists" /></li>
           <li><s:link view="/pages.xhtml"   value="Multiple Pages" /></li>
  +        <li><s:link view="/anchor.xhtml"  value="Anchors" /></li>
       </ul>
       
   </body>
  
  
  
  1.1      date: 2006/12/24 22:57:32;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/anchor.xhtml
  
  Index: anchor.xhtml
  ===================================================================
  <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:p="http://jboss.com/products/seam/pdf">
  
      <p:image alignment="right" resource="jboss.jpg" />
  
      <p:font size="24"><p:paragraph>Ten Good Reasons To Use Seam</p:paragraph></p:font>
  
      <p:list>
          <p:listItem><p:anchor reference="#reason1">Reason 1</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason2">Reason 2</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason3">Reason 3</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason4">Reason 4</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason5">Reason 5</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason6">Reason 6</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason7">Reason 7</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason8">Reason 8</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason9">Reason 9</p:anchor></p:listItem>
          <p:listItem><p:anchor reference="#reason10">Reason 10</p:anchor></p:listItem>
      </p:list>
  
  
      
      <p:font size="18"><p:paragraph><p:anchor name="reason1">It's the quickest way to get "rich"</p:anchor></p:paragraph></p:font>
  
      <p:paragraph alignment="justify">AJAX fundamentally changes the interaction model of the web. The synchronous, coarse-grained requests used by traditional web clients let many server-side applications get away with minimal caching and no session-level concurrency. The "stateless" architecture is in many cases a viable solution. But not anymore! AJAX clients hit the server with many asynchronous, concurrent, fine-grained requests, which could easily bring your database to its knees. When state is held in memory between requests, it is highly vulnerable to concurrency-related bugs, since the Java EE platform provides no constructs for dealing with session-level concurrency.</p:paragraph>
  
      <p:paragraph alignment="justify">Seam's totally unique concurrency model and state-management model was conceived and designed with AJAX in mind. </p:paragraph>
  
      <p:paragraph alignment="justify">Seam 1.1 integrates open source JSF-based AJAX solutions like ICEfaces and Ajax4JSF with Seam's state and concurrency management engine. You can add AJAX to your applications with ease, without the need to learn JavaScript, and you will be protected from potential bugs and performance problems associated with the switch to AJAX. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason2">It's the easiest way to get started with EJB 3.0</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">EJB 3.0 is a great component model for transactional business components, the highlight being the brand new Java Persistence API (JPA). But Java web and application frameworks designed before the release of EJB 3.0 lack support for the new component model, leaving you to write your own integration code, and in many cases forcing you into the use of a layered architecture that may not be right for your application. </p:paragraph>
  
      <p:paragraph alignment="justify">Seam was designed for use with EJB 3.0 and lets you use the new component model everywhere. Since any class in a Seam application can be an EJB component, there is no need to introduce extra unwanted layers just to keep your frameworks happy. And, of course, there is no need to write code to integrate EJB 3.0 with your web framework, since Seam already has it. </p:paragraph>
  
      <p:paragraph alignment="justify">Note that you don't have to use EJB 3.0 to use Seam, and if you're developing in an environment that doesn't support EJB 3.0, Seam provides alternatives. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason3">It's the best way to leverage JSF</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">JSF has created a vibrant ecosystem of component libraries and other addons, that make this easily the most exciting web framework in Java. But plain JSF is heavy on XML, and misses out on a number of important features, especially for people building internet-facing applications. Seam replaces the tedious XML configuration with a handful of annotations, reducing code and making you more productive. Seam extends JSF with extra functionality for multi-window operation and workspace management, model-based validation, jBPM-based pageflow, internationalization, page fragment caching. Seam even adds facilities for handling bookmarkable (REST-style) web pages - the number one user complaint against JSF. </p:paragraph>
  
      <p:paragraph alignment="justify">Since JSF does not address the problem of access to transactional resources, Seam's integration of JTA, JPA and EJB 3.0 is a must-have for most JSF users. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason4">And the easiest way to do BPM</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">jBPM is an intuitive and powerful solution for enterprise applications with complex human collaboration, or web applications with complex user interactions. BPM technology not only makes it easier for developers and analysts to model, implement and optimize a business process, but also makes it possible for operations and management to analyse the efficiency of the business process, and be informed of problems. </p:paragraph>
  
      <p:paragraph alignment="justify">Seam deeply integrates jBPM and makes it incredibly simple to use jBPM for task management or pageflow, and is a great way to get started with BPM technology. The combination of Seam and jBPM can shrink development time of some kinds of projects by literally months. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason5">But CRUD is easy too</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam takes on hard problems affecting complex enterprise applications. But that doesn't mean the easy stuff is any more difficult than it should be. Seam is every bit as productive as any of the current crop of CRUD frameworks when it comes to building simple data driven applications. Seam combines a simple data access framework (built around JPA and Hibernate) with a command line code generation and database reverse engineering tool to get you started in minutes. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason6">It makes persistence a breeze</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam grew out of the Hibernate community, and was designed and implemented by the people who created Hibernate, the same people who coined the term "persistence context". Seam's conversation model solves a raft of persistence-related programming problems caused by traditional stateless web application architectures. Whether you use Hibernate or JPA, Seam makes it easy and natural to use extended persistence contexts, and helps you avoid unnecessary state replication when you use an extended persistence context in a clustered environment. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason7">Annotations</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam is the first programming model that lets you use Java 5 annotations end to end, from the persistence layer to the UI. You'll never find yourself wrestling with unnecessary, noisy XML. Which is not to say that Seam doesn't use XML when appropriate (Seam has a sophisticated XML-based component configuration facility), just that you won't get lost in reams of XML for common programming tasks. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason8">Get hip to automated integration testing</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">Automated unit tests certainly have their place in any project. But it's worse than dangerous to rely solely on unit testing. Most bugs concern the interaction between components, and the interaction between a component and the container environment. Unit tests are unable to properly capture container behavior, and usually don't capture complex inter-component interactions. Seam introduces an innovative approach to automated integration testing, where you can emulate the entire flow of a request or conversation, testing all layers of Java code in the application, from presentation to persistence. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason9">Marry open source with open standards</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">Seam is founded upon open source implementations of open standards like JSF and EJB 3.0, along with open source innovators like Hibernate, jBPM, Facelets, Drools, ICEfaces and Ajax4JSF. The creators of Seam are active in the EJB, JPA, Bean Validation and JSF expert groups and lead the Web Beans (JSR-299) expert group which aims to bring the ideas of Seam into the Java EE standard. The Seam project is totally committed to the idea of open source innovation driving new ideas and ehancements into the Java platform. </p:paragraph>
  
      <p:font size="18"><p:paragraph><p:anchor name="reason10">It just works</p:anchor></p:paragraph></p:font>
      <p:paragraph alignment="justify">You'll love it if you try it.</p:paragraph>
  </p:document>
  
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 24 18:01:16 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 24 Dec 2006 18:01:16 -0500
Subject: [jboss-cvs] JBoss Messaging SVN:  r1859 - branches
Message-ID: <E1GycLE-0003sZ-6x@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-24 18:01:01 -0500 (Sun, 24 Dec 2006)
New Revision: 1859

Added:
   branches/Branch_Bisocket_Experiment/
Log:
creating the bisocket branch for Ron to play with

Copied: branches/Branch_Bisocket_Experiment (from rev 1858, trunk)



From rtew654 at linuxmail.org  Sun Dec 24 20:43:34 2006
From: rtew654 at linuxmail.org (rtew654 at linuxmail.org)
Date: Sun, 24 Dec 2006 20:43:34 -0500
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCO2QkTiVXJW0lVSUjITwlayRLOlwbKEI=?=
	=?iso-2022-jp?b?GyRCJDskRiRrPEw/PyRPOCskRiQvJGwkPyEpGyhC?=
Message-ID: 20061225085314.90959mail@mail.vyruisisjsisuyshsghryrudjdbnfgdjskskmj.com

?????
?????????????????????????????????
????????????????????
http://allfree.todaywomanmeets.tonderuyo.com/LK/
????????????????????????????
???????????????????????




From sdfahty45 at uymail.com  Sun Dec 24 22:02:11 2006
From: sdfahty45 at uymail.com (sdfahty45 at uymail.com)
Date: Sun, 24 Dec 2006 22:02:11 -0500
Subject: [jboss-cvs] =?utf-8?b?wpV2woLDhsKOccKLwp/CgsKqwotBwovCvcKCwrU=?=
	=?utf-8?b?woLCvcKCw4zCgsOFwo7CqcKXUsKCw4jCgsOxwoLDhcKCwrfCgULCiMKn?=
	=?utf-8?b?woLCpsKCw5zCgsK3woLCqcKBSA==?=
Message-ID: 20040421131943.90645mail@mail.nusysuaisdjsahsbdsatyweiufhajsnskadmskamd.com

???????????l?????????????B
?v???A?????????????Q?W???B
?????O???????????????H
???????N???A???????????S???????????????B
???????????A???????????B
?}?C?v???t?????^?????????????????????A???????????????????B

http://allfreefree.hitodumadeai.jp.ksjer.com/toa/




From forge-admin at jboss.com  Mon Dec 25 01:00:26 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Mon, 25 Dec 2006 01:00:26 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gyiss-0002mv-QG@committer01.frg.pub.inap.atl.jboss.com>

Commit from kkhan (2006-12-24 08:47 EST)
-----------------

Add ability to replace xASTORE and xALOAD calls with invokevirtual

  javassist  src/main/javassist/CodeConverter.java                      1.10
+ javassist  src/main/javassist/convert/TransformAccessArrayField.java  1.1


Commit from kkhan (2006-12-24 08:51 EST)
-----------------

Add snapshot containing ability to replace xALOAD and xASTORE with INVOKEVIRTUAL

  repository.jboss.com  javassist/snapshot/lib/javassist.jar  1.10


Commit from kkhan (2006-12-24 08:53 EST)
-----------------

bump up version to snapshot

  javassist  src/main/META-INF/MANIFEST.MF  1.18


Commit from ptsekov (2006-12-24 11:00 EST)
-------------------

* build.xml: Merge the compat-tests target from the 1.4.0 branch.
* tests/compat/*: Merge org.jboss.tools.SerialVersionUID and
org.jboss.cache.compat.SerialVersionUIDUnitTestCase from the 1.4.0 branch.

  JBossCache  build.xml                                                              1.157
+ JBossCache  tests/compat/org/jboss/cache/compat/SerialVersionUIDUnitTestCase.java  1.2
+ JBossCache  tests/compat/org/jboss/tools/ClassVersionInfo.java                     1.2
+ JBossCache  tests/compat/org/jboss/tools/SerialVersionUID.java                     1.2


Commit from nrichards (2006-12-24 11:21 EST)
---------------------

check in itext preview

  jboss-seam  build.xml                                          1.124
+ jboss-seam  lib/itext-1.4.7.jar                                1.1
+ jboss-seam  src/pdf/seam.properties                            1.1
+ jboss-seam  src/pdf/META-INF/faces-config.xml                  1.1
+ jboss-seam  src/pdf/META-INF/seam.taglib.xml                   1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/PDFPhaseListener.java   1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/PDFStore.java           1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java  1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIDocument.java      1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIFont.java          1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIImage.java         1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIList.java          1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIListItem.java      1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIPage.java          1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java     1.1


Commit from nrichards (2006-12-24 14:29 EST)
---------------------

update for the demo

+ jboss-seam  src/pdf/org/jboss/seam/pdf/ITextUtils.java  1.1
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIImage.java  1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIList.java   1.2


Commit from nrichards (2006-12-24 14:58 EST)
---------------------

add pdf example

+ jboss-seam  examples/pdf/build.xml                                  1.1
+ jboss-seam  examples/pdf/resources/components.properties            1.1
+ jboss-seam  examples/pdf/resources/import.sql                       1.1
+ jboss-seam  examples/pdf/resources/seam.properties                  1.1
+ jboss-seam  examples/pdf/resources/META-INF/application.xml         1.1
+ jboss-seam  examples/pdf/resources/META-INF/ejb-jar.xml             1.1
+ jboss-seam  examples/pdf/resources/META-INF/jboss-app.xml           1.1
+ jboss-seam  examples/pdf/resources/META-INF/persistence.xml         1.1
+ jboss-seam  examples/pdf/resources/WEB-INF/components.xml           1.1
+ jboss-seam  examples/pdf/resources/WEB-INF/components.xml.bak       1.1
+ jboss-seam  examples/pdf/resources/WEB-INF/exceptions.xml           1.1
+ jboss-seam  examples/pdf/resources/WEB-INF/faces-config.xml         1.1
+ jboss-seam  examples/pdf/resources/WEB-INF/pages.xml                1.1
+ jboss-seam  examples/pdf/resources/WEB-INF/web.xml                  1.1
+ jboss-seam  examples/pdf/src/org/jboss/seam/example/pdf/Lists.java  1.1
+ jboss-seam  examples/pdf/view/index.html                            1.1
+ jboss-seam  examples/pdf/view/index.xhtml                           1.1
+ jboss-seam  examples/pdf/view/jboss.jpg                             1.1
+ jboss-seam  examples/pdf/view/lists.xhtml                           1.1
+ jboss-seam  examples/pdf/view/pages.xhtml                           1.1
+ jboss-seam  examples/pdf/view/whyseam.xhtml                         1.1


Commit from nrichards (2006-12-24 17:54 EST)
---------------------

add UIAnchor, add UIParagraph properties

  jboss-seam  src/pdf/META-INF/faces-config.xml               1.2
  jboss-seam  src/pdf/META-INF/seam.taglib.xml                1.2
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java     1.1
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java  1.2


Commit from nrichards (2006-12-24 17:57 EST)
---------------------

add anchor example

+ jboss-seam  examples/pdf/view/anchor.xhtml  1.1
  jboss-seam  examples/pdf/view/index.xhtml   1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061225/9d2a682f/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Mon Dec 25 08:21:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 25 Dec 2006 08:21:55 -0500
Subject: [jboss-cvs] JBossAS SVN: r59226 -
	projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test
Message-ID: <E1Gypm7-0002FU-Tw@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-25 08:21:50 -0500 (Mon, 25 Dec 2006)
New Revision: 59226

Modified:
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java
Log:
no progression

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java	2006-12-24 19:24:58 UTC (rev 59225)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/config/test/ProgressionTestCase.java	2006-12-25 13:21:50 UTC (rev 59226)
@@ -52,6 +52,8 @@
 
    public void testProgressionFromOtherBean() throws Throwable
    {
+      //Uncomment the line for no progression simple test.
+      //System.setProperty("org.jboss.reflect.plugins.progressionConvertor", NullProgressionConvertor.class.getName());
       SimpleBean bean = instantiateProgressionBeans();
       assertEquals(123, bean.getAnint());
       assertEquals((short)987, bean.getAShort().shortValue());



From jboss-cvs-commits at lists.jboss.org  Mon Dec 25 09:48:33 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 25 Dec 2006 09:48:33 -0500
Subject: [jboss-cvs] JBossAS SVN: r59227 - in
	projects/microcontainer/trunk/kernel/src:
	main/org/jboss/kernel/plugins/dependency
	main/org/jboss/kernel/spi/dependency
	resources/org/jboss/test/kernel/deployment/test
	tests/org/jboss/test/kernel/deployment/support
	tests/org/jboss/test/kernel/deployment/test
Message-ID: <E1Gyr7x-0003sN-5E@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-25 09:48:09 -0500 (Mon, 25 Dec 2006)
New Revision: 59227

Added:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/ConfigureKernelControllerContextAware.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/CreateKernelControllerContextAware.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/DescribeKernelControllerContextAware.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstallKernelControllerContextAware.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstantiateKernelControllerContextAware.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/StartKernelControllerContextAware.java
   projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.xml
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/support/FineGrainedBean.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.java
Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/ConfigureAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/CreateDestroyLifecycleAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstallAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/StartStopLifecycleAction.java
   projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/DeploymentTestSuite.java
Log:
JBMICROCONT-134; initial introduction of fine grained action aware interfaces

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/ConfigureAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/ConfigureAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/ConfigureAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -32,6 +32,7 @@
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
 import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
+import org.jboss.kernel.spi.dependency.ConfigureKernelControllerContextAware;
 
 /**
  * ConfigureAction.
@@ -41,7 +42,7 @@
  */
 public class ConfigureAction extends KernelControllerContextAction
 {
-   public void installAction(KernelControllerContext context) throws Throwable
+   protected void installActionInternal(KernelControllerContext context) throws Throwable
    {
       KernelController controller = (KernelController) context.getController();
       Kernel kernel = controller.getKernel();
@@ -52,14 +53,19 @@
       BeanMetaData metaData = context.getBeanMetaData();
       Set joinPoints = configurator.getPropertySetterJoinPoints(info, metaData);
       setAttributes(context, object, joinPoints, false);
-      
+
       if (object instanceof KernelControllerContextAware)
          ((KernelControllerContextAware) object).setKernelControllerContext(context);
 
    }
 
-   public void uninstallAction(KernelControllerContext context)
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
    {
+      return ConfigureKernelControllerContextAware.class;
+   }
+
+   protected void uninstallActionInternal(KernelControllerContext context)
+   {
       KernelController controller = (KernelController) context.getController();
       Kernel kernel = controller.getKernel();
       KernelConfigurator configurator = kernel.getConfigurator();
@@ -78,8 +84,7 @@
       {
          log.debug("Ignored error unsetting context ", ignored);
       }
-      
-      
+
       BeanInfo info = context.getBeanInfo();
       BeanMetaData metaData = context.getBeanMetaData();
       try

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/CreateDestroyLifecycleAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/CreateDestroyLifecycleAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/CreateDestroyLifecycleAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -28,6 +28,8 @@
 import org.jboss.beans.metadata.spi.ParameterMetaData;
 import org.jboss.beans.metadata.spi.annotations.CreateLifecycle;
 import org.jboss.beans.metadata.spi.annotations.DestroyLifecycle;
+import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
+import org.jboss.kernel.spi.dependency.CreateKernelControllerContextAware;
 
 /**
  * CreateDestroyLifecycleAction.
@@ -63,6 +65,11 @@
       return null;
    }
 
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
+   {
+      return CreateKernelControllerContextAware.class;
+   }
+
    public String getUninstallMethod(BeanMetaData beanMetaData)
    {
       LifecycleMetaData lifecycle = beanMetaData.getDestroy();

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/DescribeAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -32,6 +32,8 @@
 import org.jboss.kernel.spi.config.KernelConfigurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
+import org.jboss.kernel.spi.dependency.DescribeKernelControllerContextAware;
 import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
 import org.jboss.metadata.spi.MetaData;
 
@@ -43,7 +45,7 @@
  */
 public class DescribeAction extends KernelControllerContextAction
 {
-   public void installAction(KernelControllerContext context) throws Throwable
+   protected void installActionInternal(KernelControllerContext context) throws Throwable
    {
       KernelController controller = (KernelController) context.getController();
       Kernel kernel = controller.getKernel();
@@ -79,8 +81,13 @@
       }
    }
 
-   public void uninstallAction(KernelControllerContext context)
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
    {
+      return DescribeKernelControllerContextAware.class;
+   }
+
+   protected void uninstallActionInternal(KernelControllerContext context)
+   {
       removeMetaData(context);
       context.setBeanInfo(null);
    }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstallAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstallAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstallAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -33,6 +33,8 @@
 import org.jboss.kernel.spi.config.KernelConfigurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
+import org.jboss.kernel.spi.dependency.InstallKernelControllerContextAware;
 import org.jboss.kernel.spi.registry.KernelRegistry;
 
 /**
@@ -43,7 +45,7 @@
  */
 public class InstallAction extends KernelControllerContextAction
 {
-   public void installAction(KernelControllerContext context) throws Throwable
+   protected void installActionInternal(KernelControllerContext context) throws Throwable
    {
       KernelController controller = (KernelController) context.getController();
       Kernel kernel = controller.getKernel();
@@ -67,9 +69,14 @@
          }
       }
    }
-   
-   public void uninstallAction(KernelControllerContext context)
+
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
    {
+      return InstallKernelControllerContextAware.class;
+   }
+
+   protected void uninstallActionInternal(KernelControllerContext context)
+   {
       KernelController controller = (KernelController) context.getController();
       Kernel kernel = controller.getKernel();
       KernelRegistry registry = kernel.getRegistry();
@@ -99,7 +106,6 @@
             catch (Throwable t)
             {
                log.warn("Ignoring uninstall action on target " + uninstall, t);
-               continue;
             }
          }
       }

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/InstantiateAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -28,6 +28,8 @@
 import org.jboss.kernel.spi.config.KernelConfigurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
+import org.jboss.kernel.spi.dependency.InstantiateKernelControllerContextAware;
 
 /**
  * InstantiateAction.
@@ -37,7 +39,7 @@
  */
 public class InstantiateAction extends KernelControllerContextAction
 {
-   public void installAction(KernelControllerContext context) throws Throwable
+   protected void installActionInternal(KernelControllerContext context) throws Throwable
    {
       KernelController controller = (KernelController) context.getController();
       Kernel kernel = controller.getKernel();
@@ -73,8 +75,13 @@
       }
    }
 
-   public void uninstallAction(KernelControllerContext context)
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
    {
+      return InstantiateKernelControllerContextAware.class;
+   }
+
+   protected void uninstallActionInternal(KernelControllerContext context)
+   {
       try
       {
          Object object = context.getTarget();

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/KernelControllerContextAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -30,6 +30,7 @@
 import org.jboss.kernel.plugins.config.Configurator;
 import org.jboss.kernel.spi.dependency.KernelController;
 import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
 import org.jboss.kernel.spi.metadata.KernelMetaDataRepository;
 import org.jboss.logging.Logger;
 import org.jboss.metadata.spi.MetaData;
@@ -178,9 +179,56 @@
    
    public void installAction(KernelControllerContext context) throws Throwable
    {
+      installActionInternal(context);
+      Object target = context.getTarget();
+      if (target != null)
+      {
+         Class<? extends KernelControllerContextAware> awareInterface = getActionAwareInterface();
+         // only applying interfaces that explicitly extend KernelControllerContextAware
+         if (awareInterface != null &&
+             awareInterface.equals(KernelControllerContextAware.class) == false &&
+             awareInterface.isAssignableFrom(target.getClass()))
+         {
+            ((KernelControllerContextAware)target).setKernelControllerContext(context);
+         }
+      }
    }
 
+   protected void installActionInternal(KernelControllerContext context) throws Throwable
+   {
+   }
+
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
+   {
+      return null;
+   }
+
    public void uninstallAction(KernelControllerContext context)
    {
+      Object target = context.getTarget();
+      if (target != null)
+      {
+         Class<? extends KernelControllerContextAware> awareInterface = getActionAwareInterface();
+         // only applying interfaces that explicitly extend KernelControllerContextAware
+         if (awareInterface != null &&
+             awareInterface.equals(KernelControllerContextAware.class) == false &&
+             awareInterface.isAssignableFrom(target.getClass()))
+         {
+            try
+            {
+               ((KernelControllerContextAware)target).unsetKernelControllerContext(context);
+            }
+            catch (Exception ignored)
+            {
+               log.debug("Ignored error unsetting context ", ignored);
+            }
+         }
+      }
+      uninstallActionInternal(context);
    }
+
+   protected void uninstallActionInternal(KernelControllerContext context)
+   {
+   }
+
 }
\ No newline at end of file

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/LifecycleAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -111,7 +111,7 @@
     */
    public abstract List<ParameterMetaData> getUninstallParameters(BeanMetaData beanMetaData);
 
-   public void installAction(KernelControllerContext context) throws Throwable
+   protected void installActionInternal(KernelControllerContext context) throws Throwable
    {
       boolean trace = log.isTraceEnabled();
 
@@ -145,7 +145,7 @@
       dispatchJoinPoint(context, joinpoint);
    }
 
-   public void uninstallAction(KernelControllerContext context)
+   protected void uninstallActionInternal(KernelControllerContext context)
    {
       boolean trace = log.isTraceEnabled();
 

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/StartStopLifecycleAction.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/StartStopLifecycleAction.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/plugins/dependency/StartStopLifecycleAction.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -28,6 +28,8 @@
 import org.jboss.beans.metadata.spi.ParameterMetaData;
 import org.jboss.beans.metadata.spi.annotations.StartLifecycle;
 import org.jboss.beans.metadata.spi.annotations.StopLifecycle;
+import org.jboss.kernel.spi.dependency.KernelControllerContextAware;
+import org.jboss.kernel.spi.dependency.StartKernelControllerContextAware;
 
 /**
  * StartStopLifecycleAction.
@@ -63,6 +65,11 @@
       return null;
    }
 
+   protected Class<? extends KernelControllerContextAware> getActionAwareInterface()
+   {
+      return StartKernelControllerContextAware.class;
+   }
+
    public String getUninstallMethod(BeanMetaData beanMetaData)
    {
       LifecycleMetaData lifecycle = beanMetaData.getStop();

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/ConfigureKernelControllerContextAware.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/ConfigureKernelControllerContextAware.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/ConfigureKernelControllerContextAware.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.spi.dependency;
+
+/**
+ * A Configure KernelControllerContextAware.
+ * @see org.jboss.kernel.plugins.dependency.KernelControllerContextAction
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface ConfigureKernelControllerContextAware extends KernelControllerContextAware
+{
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/CreateKernelControllerContextAware.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/CreateKernelControllerContextAware.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/CreateKernelControllerContextAware.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.spi.dependency;
+
+/**
+ * A Create KernelControllerContextAware.
+ * @see org.jboss.kernel.plugins.dependency.KernelControllerContextAction
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface CreateKernelControllerContextAware extends KernelControllerContextAware
+{
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/DescribeKernelControllerContextAware.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/DescribeKernelControllerContextAware.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/DescribeKernelControllerContextAware.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.spi.dependency;
+
+/**
+ * A Describe KernelControllerContextAware.
+ * @see org.jboss.kernel.plugins.dependency.KernelControllerContextAction
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface DescribeKernelControllerContextAware extends KernelControllerContextAware
+{
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstallKernelControllerContextAware.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstallKernelControllerContextAware.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstallKernelControllerContextAware.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.spi.dependency;
+
+/**
+ * An Install KernelControllerContextAware.
+ * @see org.jboss.kernel.plugins.dependency.KernelControllerContextAction
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface InstallKernelControllerContextAware extends KernelControllerContextAware
+{
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstantiateKernelControllerContextAware.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstantiateKernelControllerContextAware.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/InstantiateKernelControllerContextAware.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.spi.dependency;
+
+/**
+ * An Instantiate KernelControllerContextAware.
+ * @see org.jboss.kernel.plugins.dependency.KernelControllerContextAction
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface InstantiateKernelControllerContextAware extends KernelControllerContextAware
+{
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/StartKernelControllerContextAware.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/StartKernelControllerContextAware.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/kernel/spi/dependency/StartKernelControllerContextAware.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,32 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.kernel.spi.dependency;
+
+/**
+ * A Start KernelControllerContextAware.
+ * @see org.jboss.kernel.plugins.dependency.KernelControllerContextAction
+ *
+ * @author <a href="ales.justin at jboss.com">Ales Justin</a>
+ */
+public interface StartKernelControllerContextAware extends KernelControllerContextAware
+{
+}

Added: projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.xml
===================================================================
--- projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.xml	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/resources/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.xml	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<deployment xmlns="urn:jboss:bean-deployer:2.0">
+
+   <bean name="FineGrainedBean" class="org.jboss.test.kernel.deployment.support.FineGrainedBean" mode="Manual" />
+
+</deployment>

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/support/FineGrainedBean.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/support/FineGrainedBean.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/support/FineGrainedBean.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,61 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.deployment.support;
+
+import org.jboss.kernel.spi.dependency.*;
+
+/**
+ * @author <a href="mailto:ales.justin at gmail.com">Ales Justin</a>
+ */
+public class FineGrainedBean implements
+      DescribeKernelControllerContextAware, InstantiateKernelControllerContextAware,
+      ConfigureKernelControllerContextAware, CreateKernelControllerContextAware,
+      StartKernelControllerContextAware, InstallKernelControllerContextAware
+{
+   private int index;
+
+   public static String[] states = {
+         "NOT_INSTALLED (DESCRIBED)",
+         "INSTANTIATED",
+         "CONFIGURED", // since ConfigureAction calls this as well, remove this once we remove that from CA
+         "CONFIGURED",
+         "CREATE",
+         "START",
+         "INSTALLED",
+   };
+
+   public String getStateString()
+   {
+      return states[index];
+   }
+
+   public void setKernelControllerContext(KernelControllerContext context) throws Exception
+   {
+      ++index;
+   }
+
+   public void unsetKernelControllerContext(KernelControllerContext context) throws Exception
+   {
+      --index;
+   }
+
+}

Modified: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/DeploymentTestSuite.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/DeploymentTestSuite.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/DeploymentTestSuite.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -48,6 +48,7 @@
       suite.addTest(WildcardClassLoaderTestCase.suite());
       suite.addTest(BeanMetaDataFactoryTestCase.suite());
       suite.addTest(AnnotatedLifecycleTestCase.suite());
+      suite.addTest(FineGrainedActionTestCase.suite());
 
       return suite;
    }

Added: projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.java	2006-12-25 13:21:50 UTC (rev 59226)
+++ projects/microcontainer/trunk/kernel/src/tests/org/jboss/test/kernel/deployment/test/FineGrainedActionTestCase.java	2006-12-25 14:48:09 UTC (rev 59227)
@@ -0,0 +1,109 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.kernel.deployment.test;
+
+import junit.framework.Test;
+import org.jboss.dependency.spi.ControllerState;
+import org.jboss.kernel.spi.dependency.KernelControllerContext;
+import org.jboss.test.kernel.deployment.support.FineGrainedBean;
+
+/**
+ * @author <a href="mailto:ales.justin at gmail.com">Ales Justin</a>
+ */
+public class FineGrainedActionTestCase extends AbstractDeploymentTest
+{
+
+   private static final String BEAN_NAME = "FineGrainedBean";
+
+   public FineGrainedActionTestCase(String name) throws Throwable
+   {
+      super(name);
+   }
+
+   public static Test suite()
+   {
+      return suite(FineGrainedActionTestCase.class);
+   }
+
+   public void testFineGrainedActions() throws Throwable
+   {
+      KernelControllerContext context = getControllerContext(FineGrainedActionTestCase.BEAN_NAME, ControllerState.NOT_INSTALLED);      
+      FineGrainedBean target;
+
+      change(context, ControllerState.DESCRIBED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNull(target);
+
+      change(context, ControllerState.INSTANTIATED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("INSTANTIATED", target.getStateString());
+
+      change(context, ControllerState.CONFIGURED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("CONFIGURED", target.getStateString());
+
+      change(context, ControllerState.CREATE);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("CREATE", target.getStateString());
+
+      change(context, ControllerState.START);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("START", target.getStateString());
+
+      change(context, ControllerState.INSTALLED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("INSTALLED", target.getStateString());
+
+      change(context, ControllerState.START);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("START", target.getStateString());
+
+      change(context, ControllerState.CREATE);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("CREATE", target.getStateString());
+
+      change(context, ControllerState.CONFIGURED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("CONFIGURED", target.getStateString());
+
+      change(context, ControllerState.INSTANTIATED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNotNull(target);
+      assertEquals("INSTANTIATED", target.getStateString());
+
+      change(context, ControllerState.DESCRIBED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNull(target);
+
+      change(context, ControllerState.NOT_INSTALLED);
+      target = (FineGrainedBean) context.getTarget();
+      assertNull(target);
+   }
+}



From norman.richards at jboss.com  Mon Dec 25 11:17:54 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Mon, 25 Dec 2006 11:17:54 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/META-INF   ...
Message-ID: <E1GysWQ-0005XM-EU@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/25 11:17:54

  Modified:    src/pdf/META-INF   faces-config.xml seam.taglib.xml
  Log:
  chapter,section,table,cell
  
  Revision  Changes    Path
  1.3       +20 -0     jboss-seam/src/pdf/META-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/META-INF/faces-config.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- faces-config.xml	24 Dec 2006 22:54:32 -0000	1.2
  +++ faces-config.xml	25 Dec 2006 16:17:54 -0000	1.3
  @@ -44,6 +44,26 @@
           <component-class>org.jboss.seam.pdf.ui.UIAnchor</component-class>
       </component>
   
  +    <component>
  +        <component-type>org.jboss.seam.pdf.ui.UIChapter</component-type>
  +        <component-class>org.jboss.seam.pdf.ui.UIChapter</component-class>
  +    </component>
  +
  +    <component>
  +        <component-type>org.jboss.seam.pdf.ui.UISection</component-type>
  +        <component-class>org.jboss.seam.pdf.ui.UISection</component-class>
  +    </component>
  +
  +    <component>
  +        <component-type>org.jboss.seam.pdf.ui.UITable</component-type>
  +        <component-class>org.jboss.seam.pdf.ui.UITable</component-class>
  +    </component>
  +
  +    <component>
  +        <component-type>org.jboss.seam.pdf.ui.UICell</component-type>
  +        <component-class>org.jboss.seam.pdf.ui.UICell</component-class>
  +    </component>
  +
       <lifecycle>
           <phase-listener>org.jboss.seam.pdf.PDFPhaseListener</phase-listener>
       </lifecycle>
  
  
  
  1.3       +28 -0     jboss-seam/src/pdf/META-INF/seam.taglib.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: seam.taglib.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/META-INF/seam.taglib.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- seam.taglib.xml	24 Dec 2006 22:54:32 -0000	1.2
  +++ seam.taglib.xml	25 Dec 2006 16:17:54 -0000	1.3
  @@ -62,4 +62,32 @@
           </component>
       </tag>
   
  +    <tag>
  +        <tag-name>chapter</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.pdf.ui.UIChapter</component-type>
  +        </component>
  +    </tag>
  +
  +    <tag>
  +        <tag-name>section</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.pdf.ui.UISection</component-type>
  +        </component>
  +    </tag>
  +
  +    <tag>
  +        <tag-name>table</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.pdf.ui.UITable</component-type>
  +        </component>
  +    </tag>
  +
  +    <tag>
  +        <tag-name>cell</tag-name>
  +        <component>
  +            <component-type>org.jboss.seam.pdf.ui.UICell</component-type>
  +        </component>
  +    </tag>
  +
   </facelet-taglib>
  
  
  


From norman.richards at jboss.com  Mon Dec 25 11:17:54 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Mon, 25 Dec 2006 11:17:54 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui ...
Message-ID: <E1GysWQ-0005Y3-Kg@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/25 11:17:54

  Modified:    src/pdf/org/jboss/seam/pdf/ui             
                        ITextComponent.java UIAnchor.java UIDocument.java
                        UIFont.java UIImage.java UIList.java
                        UIListItem.java UIPage.java UIParagraph.java
  Added:       src/pdf/org/jboss/seam/pdf/ui              UICell.java
                        UIChapter.java UISection.java UITable.java
  Log:
  chapter,section,table,cell
  
  Revision  Changes    Path
  1.2       +43 -11    jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ITextComponent.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ITextComponent.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ ITextComponent.java	25 Dec 2006 16:17:54 -0000	1.2
  @@ -34,6 +34,10 @@
       abstract public void createITextObject();
   
       /** 
  +     * remove the itext objext
  +     */
  +    abstract public void removeITextObject();
  +    /** 
        * subcomponents should implement this
        */ 
       abstract public void add(Object other);
  @@ -127,6 +131,7 @@
           if (obj != null) {
               addToITextParent(getITextObject());
           }
  +        removeITextObject();
       }
   
       @Override
  @@ -136,6 +141,23 @@
           for (UIComponent child: (List<UIComponent>) this.getChildren()) {
               // ugly hack to be able to capture facelets text
               if (child.getFamily().equals("facelets.LiteralText")) {
  +                String text = replaceEntities(extractText(context, child));
  +                Font   font = getFont();
  +                if (font == null) {
  +                    Chunk chunk = new Chunk(text);
  +                    add(chunk);
  +                } else {
  +                    add(new Chunk(text, getFont()));
  +                }
  +            } else {
  +                encode(context, child);
  +            }
  +        }
  +    }
  +
  +    public String extractText(FacesContext context, UIComponent child) 
  +        throws IOException
  +    {
                   ResponseWriter response = context.getResponseWriter();
                   StringWriter stringWriter = new StringWriter();
                   ResponseWriter cachingResponseWriter = response.cloneWithWriter(stringWriter);
  @@ -145,18 +167,28 @@
   
                   context.setResponseWriter(response);
   
  -                String text = stringWriter.getBuffer().toString();
  -                Font   font = getFont();
  -                if (font == null) {
  -                    Chunk chunk = new Chunk(text);
  -                    //chunk.setBackground(new Color(140,50,50));
  -                    add(chunk);
  -                } else {
  -                    add(new Chunk(text, getFont()));
  +        return stringWriter.getBuffer().toString();
                   }
  -            } else {
  -                encode(context, child);
  +
  +    /**
  +     * facelets automatically escapes text, so we have to undo the
  +     * the damage here.  This is just a placeholder for something
  +     * more intelligent.  The replacement strategy here is not
  +     * sufficient.
  +     */
  +    private String replaceEntities(String text) {
  +        StringBuffer buffer = new StringBuffer(text);
  +
  +        replaceAll(buffer, "&quot;", "\"");
  +        // XXX - etc....
  +
  +        return buffer.toString();
               }
  +
  +    private void replaceAll(StringBuffer buffer, String original, String changeTo) {
  +        int pos;
  +        while ((pos = buffer.indexOf(original)) != -1) {
  +            buffer.replace(pos,pos+original.length(), changeTo);
           }
       }
   
  
  
  
  1.2       +4 -0      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIAnchor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIAnchor.java	24 Dec 2006 22:54:32 -0000	1.1
  +++ UIAnchor.java	25 Dec 2006 16:17:54 -0000	1.2
  @@ -30,6 +30,10 @@
           return anchor;
       }
   
  +    public void removeITextObject() {
  +        anchor = null;
  +    }
  +
       public void createITextObject() {
           anchor = new Anchor();
   
  
  
  
  1.2       +5 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIDocument.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIDocument.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIDocument.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIDocument.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIDocument.java	25 Dec 2006 16:17:54 -0000	1.2
  @@ -25,7 +25,11 @@
       }
   
       public void createITextObject() {
  -        document=new Document();
  +        document = new Document();
  +    }
  +
  +    public void removeITextObject() {
  +        document = null;
       }
   
       public void add(Object o) {
  
  
  
  1.2       +4 -0      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIFont.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIFont.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIFont.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIFont.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIFont.java	25 Dec 2006 16:17:54 -0000	1.2
  @@ -41,6 +41,10 @@
           return null; // we don't add to this component, so skip
       }
   
  +    public void removeITextObject() {
  +        font = null;
  +    }
  +    
       public void createITextObject() {
           font = new Font(family, size);
           if (style != null) {
  
  
  
  1.3       +26 -3     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIImage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIImage.java	24 Dec 2006 19:29:01 -0000	1.2
  +++ UIImage.java	25 Dec 2006 16:17:54 -0000	1.3
  @@ -27,6 +27,9 @@
       String alignment;
       String alt;
   
  +    Boolean wrap;
  +    Boolean underlying;
  +
       public void setResource(String resource) {
           this.resource = resource;
       }
  @@ -51,11 +54,22 @@
           this.alt = alt;
       }
   
  +    public void setWrap(Boolean wrap) {
  +        this.wrap = wrap;
  +    }
  +
  +    public void setUnderlying(Boolean underlying) {
  +        this.underlying = underlying;
  +    }
  +
  +
       public Object getITextObject() {
           return image;
       }
   
  -    
  +    public void removeITextObject() {
  +        image = null;
  +    }
   
       public void createITextObject() {
           
  @@ -77,9 +91,18 @@
               image.scaleAbsolute(width, height);
           }
   
  +        int alignmentValue =0;
           if (alignment != null) {
  -            image.setAlignment(ITextUtils.alignmentValue(alignment));
  +            alignmentValue = (ITextUtils.alignmentValue(alignment));
  +        }
  +        if (wrap!=null && wrap.booleanValue()) {
  +            alignmentValue |= Image.TEXTWRAP;
           }
  +        if (underlying!= null && underlying.booleanValue()) {
  +            alignmentValue |= Image.UNDERLYING;
  +        }
  +
  +        image.setAlignment(alignmentValue);
   
           if (alt != null) {
               image.setAlt(alt);
  
  
  
  1.3       +52 -11    jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIList.java	24 Dec 2006 19:29:01 -0000	1.2
  +++ UIList.java	25 Dec 2006 16:17:54 -0000	1.3
  @@ -14,30 +14,71 @@
   {
       public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIList";
   
  -    List list;
  +    public static final String STYLE_NUMBERED  = "NUMBERED";
  +    public static final String STYLE_LETTERED  = "LETTERED";
  +    public static final String STYLE_GREEK     = "GREEK";
  +    public static final String STYLE_ROMAN     = "ROMAN";
       
  -    boolean numbered = false;
  -    boolean lettered = false;
  -    float   indent   = 20f;
  +    List list;
   
  -    public void setNumbered(boolean numbered) {
  -        this.numbered = numbered;
  -    }
  +    String style; 
  +    String listSymbol;
  +    float indent = 20;;
  +    Boolean lowerCase = false;
   
  -    public void setLettered(boolean lettered) {
  -        this.lettered = lettered;
  +    public void setStyle(String style) {
  +        this.style = style;
       }
   
       public void setIndent(float indent) {
           this.indent = indent;
       }
   
  +    public void setListSymbol(String listSymbol) {
  +        this.listSymbol = listSymbol;
  +    }
  +
  +    /* for ROMAN,GREEK */
  +    public void setLowerCase(Boolean lowerCase) {
  +        this.lowerCase = lowerCase;
  +    }
  +
       public Object getITextObject() {
           return list;
       }
   
  +    public void removeITextObject() {
  +        list = null;
  +    }
  +
       public void createITextObject() {
  -        list = new List(numbered, lettered, indent);
  +        if (style != null) {
  +            if (style.equalsIgnoreCase(STYLE_ROMAN)) {
  +                list = new RomanList((int) indent); // int? bug in text?
  +                if (lowerCase != null) {
  +                    ((RomanList) list).setRomanLower(lowerCase);
  +                }
  +            } else if (style.equalsIgnoreCase(STYLE_GREEK)) {
  +                list = new GreekList((int)indent); // int? bug in itext?
  +
  +                if (lowerCase != null) {
  +                    ((GreekList) list).setGreekLower(lowerCase);
  +                }
  +            } else if (style.equalsIgnoreCase(STYLE_NUMBERED)) {
  +                list = new List(true, indent);
  +                //setFirst(int)
  +            } else if (style.equalsIgnoreCase(STYLE_LETTERED)) {
  +                list = new List(false, true, indent);
  +                //setFirst(char)
  +            }
  +        }
  +        
  +        if (list == null) {
  +            list = new List(false, indent);
  +            if (listSymbol!=null) {
  +                list.setListSymbol(listSymbol);
  +            }
  +        }
       }
   
       public void add(Object o) {
  
  
  
  1.2       +4 -0      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIListItem.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIListItem.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIListItem.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIListItem.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIListItem.java	25 Dec 2006 16:17:54 -0000	1.2
  @@ -24,6 +24,10 @@
           listItem = new ListItem();
       }
   
  +    public void removeITextObject() {
  +        listItem = null;
  +    }
  +
       public void add(Object o) {
           listItem.add(o);
       }
  
  
  
  1.2       +4 -0      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIPage.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIPage.java	24 Dec 2006 16:21:33 -0000	1.1
  +++ UIPage.java	25 Dec 2006 16:17:54 -0000	1.2
  @@ -18,6 +18,10 @@
           return null;
       }
   
  +    public void removeITextObject() {
  +
  +    }
  +
       public void createITextObject() {
           
       }
  
  
  
  1.3       +4 -0      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIParagraph.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIParagraph.java	24 Dec 2006 22:54:32 -0000	1.2
  +++ UIParagraph.java	25 Dec 2006 16:17:54 -0000	1.3
  @@ -66,6 +66,10 @@
           return paragraph;
       }
   
  +    public void removeITextObject() {
  +        paragraph = null;
  +    }
  +
       public void createITextObject() {
           Font font = getFont();
           if (font == null) {
  
  
  
  1.1      date: 2006/12/25 16:17:54;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java
  
  Index: UICell.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UICell
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UICell";
  
      PdfPCell cell;
  
      public Object getITextObject() {
          return cell;
      }
  
      public void removeITextObject() {
          cell = null;
      }
  
      public void createITextObject() {
          cell = new PdfPCell();
      }
  
      public void add(Object o) {
          if (o instanceof Element) {
              cell.addElement((Element) o);
          } else {
              throw new RuntimeException("Can't add " + o.getClass().getName() +
                                         " to cell");
          }
      }
  }
  
  
  
  1.1      date: 2006/12/25 16:17:54;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIChapter.java
  
  Index: UIChapter.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UIChapter
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UIChapter";
  
      Chapter chapter;
      
      public Chapter getChapter() {
          return chapter;
      }
      public Object getITextObject() {
          return chapter;
      }
  
      public void removeITextObject() {
          chapter = null;
      }
  
      public void createITextObject() {
          chapter = new Chapter("*chapter title*",1);
      }
  
      public void add(Object o) {
          chapter.add(o);
      }
  }
  
  
  
  1.1      date: 2006/12/25 16:17:54;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UISection.java
  
  Index: UISection.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UISection
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UISection";
  
      Section section;
      
      public Object getITextObject() {
          return section;
      }
  
      public void removeITextObject() {
          section = null;
      }
  
      public void createITextObject() {
          Chapter chapter = ((UIChapter)findITextParent(this, UIChapter.class)).getChapter();
          section = chapter.addSection(new Paragraph("*fake title*"), 1);
          section.setTitle(new Paragraph("*section title*"));
      }
  
      public void add(Object o) {
          section.add(o);
      }
  }
  
  
  
  1.1      date: 2006/12/25 16:17:54;  author: nrichards;  state: Exp;jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UITable.java
  
  Index: UITable.java
  ===================================================================
  package org.jboss.seam.pdf.ui;
  
  import javax.faces.event.*;
  import javax.faces.context.*;
  import javax.faces.component.*;
  import javax.servlet.http.*;
  import java.io.*;
  
  import com.lowagie.text.*;
  import com.lowagie.text.pdf.*;
  
  public class UITable
      extends ITextComponent
  {
      public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UITable";
  
      PdfPTable table;
      int columns    = 1;
      Integer headerRows = 0;
      Integer footerRows = 0;
  
      public void setColumns(int columns) {
          this.columns = columns;
      }
  
      public void setHeaderRows(Integer headerRows) {
          this.headerRows = headerRows;
      }
  
      public void setFooterRows(Integer footerRows) {
          this.footerRows = footerRows;
      }
  
  
      public Object getITextObject() {
          return table;
      }
  
      public void removeITextObject() {
          table = null;
      }
  
      public void createITextObject() {
          table = new PdfPTable(columns);
          if (headerRows != null) {
              table.setHeaderRows(headerRows.intValue());
          }
          if (footerRows != null) {
              table.setFooterRows(footerRows.intValue());
          }
      }
  
      public void add(Object o) {
          if (o instanceof PdfPCell) {
              table.addCell((PdfPCell) o);
          } else {
              throw new RuntimeException("Can't add " + o.getClass().getName() +
                                         " to table");
          }
      }
  }
  
  
  


From gfd4d56sfa at Safe-mail.net  Mon Dec 25 11:27:29 2006
From: gfd4d56sfa at Safe-mail.net (gfd4d56sfa at Safe-mail.net)
Date: Mon, 25 Dec 2006 11:27:29 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCv8KCw6XCgsOBwoLDhsKRwoHCgsKiwoLCqMKU?=
	=?utf-8?b?TsKLw4rCgsOwwpdwwojDk8KCwrXCgsOcwoLCtcKCwr3CgcO0?=
Message-ID: 20061226012328.26202mail@mail.nsusyaiskdajsuatuyuertekjhdfkjasdnsjdha.com

?????x?A???????E???????????l???????????????A
?????S?????????????????????j???????W?????T?C?g???????????????B

?@?@?@?????c?j???????l?????A???????A???????V?????????v???????B?c????


?????S?????? http://freewebspace.freefree.tv.perpl.com/sereb/?@?????S??????


?@?@?@?@?@?????????T?C?g?????S?????p???????R????????????????

?@?t???[?A?h???X?????????????????Q?????l???????o?????????????I
?A?????p?????S?????I?????????????????????m???????????????I?I
?B???????????l?????g???I?????I?????????????O???????????????I?I

?????S?????? http://freewebspace.freefree.tv.perpl.com/sereb/?@?????S??????


????????????????????????????????????????????????????????????????????????????

?????q????(ID:876223)?????????b?Z?[?W???????????????B

?u?????????????B???????N?????????????????B
?@?f???????????A???????????????????????[?????????????????B
?@???????????l???????????????????A???????????H
?@???????????????????????????A???????????????????o????????????
?@???????????????????????????????????B
?@?????~?????????????????????H
?@?v???[???g?????????????????B?v

?????S?????? http://freewebspace.freefree.tv.perpl.com/sereb/?@?????S??????





From norman.richards at jboss.com  Mon Dec 25 11:28:52 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Mon, 25 Dec 2006 11:28:52 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view      ...
Message-ID: <E1Gysh2-0005hd-9j@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/25 11:28:52

  Modified:    examples/pdf/view      index.xhtml lists.xhtml whyseam.xhtml
  Added:       examples/pdf/view      chapters.xhtml table.xhtml
  Log:
  update examples
  
  Revision  Changes    Path
  1.3       +7 -4      jboss-seam/examples/pdf/view/index.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: index.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/index.xhtml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- index.xhtml	24 Dec 2006 22:57:32 -0000	1.2
  +++ index.xhtml	25 Dec 2006 16:28:52 -0000	1.3
  @@ -12,11 +12,14 @@
   </head>
   <body>
         
  +    <h1>Sample Documents:</h1>
       <ul>
           <li><s:link view="/whyseam.xhtml" value="Why Seam?" /></li>
           <li><s:link view="/lists.xhtml"   value="PDF Lists" /></li>
           <li><s:link view="/pages.xhtml"   value="Multiple Pages" /></li>
           <li><s:link view="/anchor.xhtml"  value="Anchors" /></li>
  +        <li><s:link view="/chapters.xhtml"  value="Chapters" /></li>
  +        <li><s:link view="/table.xhtml"     value="Tables" /></li>
       </ul>
       
   </body>
  
  
  
  1.2       +16 -2     jboss-seam/examples/pdf/view/lists.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: lists.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/lists.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- lists.xhtml	24 Dec 2006 19:58:09 -0000	1.1
  +++ lists.xhtml	25 Dec 2006 16:28:52 -0000	1.2
  @@ -12,14 +12,28 @@
       </p:list>
   
       <p:paragraph>Numbered:</p:paragraph>
  -    <p:list numbered="true">
  +    <p:list style="numbered">
           <ui:repeat value="#{lists.numbers}" var="item">
               <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
           </ui:repeat>
       </p:list>
   
       <p:paragraph>Lettered:</p:paragraph>
  -    <p:list lettered="true">
  +    <p:list style="lettered">
  +        <ui:repeat value="#{lists.numbers}" var="item">
  +            <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
  +        </ui:repeat>
  +    </p:list>
  +
  +    <p:paragraph>Roman:</p:paragraph>
  +    <p:list style="roman">
  +        <ui:repeat value="#{lists.numbers}" var="item">
  +            <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
  +        </ui:repeat>
  +    </p:list>
  +
  +    <p:paragraph>Greek:</p:paragraph>
  +    <p:list style="greek">
           <ui:repeat value="#{lists.numbers}" var="item">
               <p:listItem><p:font style="bold">#{item}</p:font>: This is some information...</p:listItem>
           </ui:repeat>
  
  
  
  1.2       +3 -2      jboss-seam/examples/pdf/view/whyseam.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: whyseam.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/whyseam.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- whyseam.xhtml	24 Dec 2006 19:58:09 -0000	1.1
  +++ whyseam.xhtml	25 Dec 2006 16:28:52 -0000	1.2
  @@ -1,9 +1,10 @@
   <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
               xmlns:p="http://jboss.com/products/seam/pdf">
   
  -    <p:image alignment="right" resource="jboss.jpg" />
   
  -    <p:font size="24"><p:paragraph>Ten Good Reasons To Use Seam</p:paragraph></p:font>
  +    <p:image alignment="right" wrap="true" resource="jboss.jpg" /> 
  +    <p:font size="24"><p:paragraph spacingAfter="50">Ten Good Reasons To Use Seam</p:paragraph></p:font>  
  +
   
       <p:font size="18"><p:paragraph>It's the quickest way to get "rich"</p:paragraph></p:font>
   
  
  
  
  1.1      date: 2006/12/25 16:28:52;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/chapters.xhtml
  
  Index: chapters.xhtml
  ===================================================================
  <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:p="http://jboss.com/products/seam/pdf">
  
      <p:image alignment="right" resource="jboss.jpg" />
  
      <p:font size="24"><p:paragraph>Ten Good Reasons To Use Seam</p:paragraph></p:font>
  
      <p:chapter>
          <p:font size="18"><p:paragraph>It's the quickest way to get "rich"</p:paragraph></p:font>
  
          <p:paragraph alignment="justify">AJAX fundamentally changes the interaction model of the web. The synchronous, coarse-grained requests used by traditional web clients let many server-side applications get away with minimal caching and no session-level concurrency. The "stateless" architecture is in many cases a viable solution. But not anymore! AJAX clients hit the server with many asynchronous, concurrent, fine-grained requests, which could easily bring your database to its knees. When state is held in memory between requests, it is highly vulnerable to concurrency-related bugs, since the Java EE platform provides no constructs for dealing with session-level concurrency.</p:paragraph>
  
          <p:paragraph alignment="justify">Seam's totally unique concurrency model and state-management model was conceived and designed with AJAX in mind. </p:paragraph>
  
          <p:paragraph alignment="justify">Seam 1.1 integrates open source JSF-based AJAX solutions like ICEfaces and Ajax4JSF with Seam's state and concurrency management engine. You can add AJAX to your applications with ease, without the need to learn JavaScript, and you will be protected from potential bugs and performance problems associated with the switch to AJAX. </p:paragraph>
      </p:chapter>
      <p:chapter>
  
          <p:font size="18"><p:paragraph>It's the easiest way to get started with EJB 3.0 </p:paragraph></p:font>
          <p:paragraph alignment="justify">EJB 3.0 is a great component model for transactional business components, the highlight being the brand new Java Persistence API (JPA). But Java web and application frameworks designed before the release of EJB 3.0 lack support for the new component model, leaving you to write your own integration code, and in many cases forcing you into the use of a layered architecture that may not be right for your application. </p:paragraph>
  
          <p:paragraph alignment="justify">Seam was designed for use with EJB 3.0 and lets you use the new component model everywhere. Since any class in a Seam application can be an EJB component, there is no need to introduce extra unwanted layers just to keep your frameworks happy. And, of course, there is no need to write code to integrate EJB 3.0 with your web framework, since Seam already has it. </p:paragraph>
  
          <p:paragraph alignment="justify">Note that you don't have to use EJB 3.0 to use Seam, and if you're developing in an environment that doesn't support EJB 3.0, Seam provides alternatives. </p:paragraph>
      </p:chapter>
      <p:chapter>
          <p:font size="18"><p:paragraph>It's the best way to leverage JSF </p:paragraph></p:font>
          <p:paragraph alignment="justify">JSF has created a vibrant ecosystem of component libraries and other addons, that make this easily the most exciting web framework in Java. But plain JSF is heavy on XML, and misses out on a number of important features, especially for people building internet-facing applications. Seam replaces the tedious XML configuration with a handful of annotations, reducing code and making you more productive. Seam extends JSF with extra functionality for multi-window operation and workspace management, model-based validation, jBPM-based pageflow, internationalization, page fragment caching. Seam even adds facilities for handling bookmarkable (REST-style) web pages - the number one user complaint against JSF. </p:paragraph>
  
          <p:paragraph alignment="justify">Since JSF does not address the problem of access to transactional resources, Seam's integration of JTA, JPA and EJB 3.0 is a must-have for most JSF users. </p:paragraph>
      </p:chapter>
      <p:chapter>
  
          <p:font size="18"><p:paragraph>And the easiest way to do BPM </p:paragraph></p:font>
          <p:paragraph alignment="justify">jBPM is an intuitive and powerful solution for enterprise applications with complex human collaboration, or web applications with complex user interactions. BPM technology not only makes it easier for developers and analysts to model, implement and optimize a business process, but also makes it possible for operations and management to analyse the efficiency of the business process, and be informed of problems. </p:paragraph>
          
          <p:paragraph alignment="justify">Seam deeply integrates jBPM and makes it incredibly simple to use jBPM for task management or pageflow, and is a great way to get started with BPM technology. The combination of Seam and jBPM can shrink development time of some kinds of projects by literally months. </p:paragraph>
      </p:chapter>
      <p:chapter>        
          <p:font size="18"><p:paragraph>But CRUD is easy too </p:paragraph></p:font>
          <p:paragraph alignment="justify">Seam takes on hard problems affecting complex enterprise applications. But that doesn't mean the easy stuff is any more difficult than it should be. Seam is every bit as productive as any of the current crop of CRUD frameworks when it comes to building simple data driven applications. Seam combines a simple data access framework (built around JPA and Hibernate) with a command line code generation and database reverse engineering tool to get you started in minutes. </p:paragraph>
      </p:chapter>
      <p:chapter>
          <p:font size="18"><p:paragraph>It makes persistence a breeze </p:paragraph></p:font>
          <p:paragraph alignment="justify">Seam grew out of the Hibernate community, and was designed and implemented by the people who created Hibernate, the same people who coined the term "persistence context". Seam's conversation model solves a raft of persistence-related programming problems caused by traditional stateless web application architectures. Whether you use Hibernate or JPA, Seam makes it easy and natural to use extended persistence contexts, and helps you avoid unnecessary state replication when you use an extended persistence context in a clustered environment. </p:paragraph>
      </p:chapter>
      <p:chapter>
          <p:font size="18"><p:paragraph>Annotations </p:paragraph></p:font>
          <p:paragraph alignment="justify">Seam is the first programming model that lets you use Java 5 annotations end to end, from the persistence layer to the UI. You'll never find yourself wrestling with unnecessary, noisy XML. Which is not to say that Seam doesn't use XML when appropriate (Seam has a sophisticated XML-based component configuration facility), just that you won't get lost in reams of XML for common programming tasks. </p:paragraph>
      </p:chapter>
      <p:chapter>
          <p:font size="18"><p:paragraph>Get hip to automated integration testing </p:paragraph></p:font>
          <p:paragraph alignment="justify">Automated unit tests certainly have their place in any project. But it's worse than dangerous to rely solely on unit testing. Most bugs concern the interaction between components, and the interaction between a component and the container environment. Unit tests are unable to properly capture container behavior, and usually don't capture complex inter-component interactions. Seam introduces an innovative approach to automated integration testing, where you can emulate the entire flow of a request or conversation, testing all layers of Java code in the application, from presentation to persistence. </p:paragraph>
      </p:chapter>
      <p:chapter>        
          <p:font size="18"><p:paragraph>Marry open source with open standards </p:paragraph></p:font>
          <p:paragraph alignment="justify">Seam is founded upon open source implementations of open standards like JSF and EJB 3.0, along with open source innovators like Hibernate, jBPM, Facelets, Drools, ICEfaces and Ajax4JSF. The creators of Seam are active in the EJB, JPA, Bean Validation and JSF expert groups and lead the Web Beans (JSR-299) expert group which aims to bring the ideas of Seam into the Java EE standard. The Seam project is totally committed to the idea of open source innovation driving new ideas and ehancements into the Java platform. </p:paragraph>
      </p:chapter>
      <p:chapter>
          <p:font size="18"><p:paragraph>It just works </p:paragraph></p:font>
          <p:paragraph alignment="justify">You'll love it if you try it.</p:paragraph>
      </p:chapter>
  </p:document>
  
  
  
  
  1.1      date: 2006/12/25 16:28:52;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/table.xhtml
  
  Index: table.xhtml
  ===================================================================
  <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:p="http://jboss.com/products/seam/pdf">
  
  
      <p:image alignment="right" wrap="true" resource="jboss.jpg" /> 
      <p:font size="24"><p:paragraph spacingAfter="50">Table Test</p:paragraph></p:font>  
  
  
      <p:table columns="3">
          <p:cell>cell 1</p:cell>
          <p:cell>cell 2</p:cell>
          <p:cell>cell 3</p:cell>
          <p:cell>cell 4</p:cell>
          <p:cell>cell 5</p:cell>
          <p:cell>cell 6</p:cell>
          <p:cell>cell 7</p:cell>
          <p:cell>cell 8</p:cell>
          <p:cell>cell 9</p:cell>
      </p:table>
  
      <p:paragraph spacingBefore="10" spacingAfter="10">This is another table.  It should be large enough to span multiple pages with the headers repeated on other page</p:paragraph>
  
      <p:table columns="2" headerRows="1">
          <p:cell><p:font size="20">This is a header</p:font></p:cell>
          <p:cell>This is also a header!</p:cell>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
          <ui:repeat value="#{lists.daysOfWeek}" var="day">
              <p:cell>#{day}</p:cell>
              <p:cell>Blah blah blah</p:cell>
          </ui:repeat>
      </p:table>
  </p:document>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Mon Dec 25 13:51:55 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Mon, 25 Dec 2006 13:51:55 -0500
Subject: [jboss-cvs] JBossAS SVN: r59228 -
	projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins
Message-ID: <E1GyuvT-00088j-H2@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-25 13:51:53 -0500 (Mon, 25 Dec 2006)
New Revision: 59228

Added:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/BeanMetaDataBuilder.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ParameterMetaDataBuilder.java
Log:
JBMICROCONT-136; initial helper/builder code, more added on demand

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/BeanMetaDataBuilder.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/BeanMetaDataBuilder.java	2006-12-25 14:48:09 UTC (rev 59227)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/BeanMetaDataBuilder.java	2006-12-25 18:51:53 UTC (rev 59228)
@@ -0,0 +1,231 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.beans.metadata.plugins;
+
+import java.util.Set;
+import java.util.HashSet;
+import java.util.List;
+import java.util.ArrayList;
+
+import org.jboss.beans.metadata.spi.*;
+import org.jboss.dependency.spi.ControllerMode;
+
+/**
+ * Helper class.
+ * Similar to StringBuffer, methods return current instance of BeanMetaDataBuilder.
+ *
+ * TODO - add on demand, when building OSGi, Spring, ...
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class BeanMetaDataBuilder
+{
+   private AbstractBeanMetaData beanMetaData;
+   // parameter builders
+   private ParameterMetaDataBuilder<ConstructorMetaData> constructorBuilder;
+   private LifecycleMetaDataBuilder createBuilder;
+   private LifecycleMetaDataBuilder startBuilder;
+   private LifecycleMetaDataBuilder stopBuilder;
+   private LifecycleMetaDataBuilder destroyBuilder;
+//   private ParameterMetaDataBuilder<InstallMetaData> installBuilder;
+//   private ParameterMetaDataBuilder<InstallMetaData> uninstallBuilder;
+
+   public BeanMetaDataBuilder(String bean)
+   {
+      this(new AbstractBeanMetaData(bean));
+   }
+
+   public BeanMetaDataBuilder(String name, String bean)
+   {
+      this(new AbstractBeanMetaData(name, bean));
+   }
+
+   public BeanMetaDataBuilder(AbstractBeanMetaData beanMetaData)
+   {
+      this.beanMetaData = beanMetaData;
+      // lifecycle builders
+      createBuilder = new LifecycleMetaDataBuilder(beanMetaData, LifecycleMetaDataBuilder.LifecycleType.CREATE);
+      startBuilder = new LifecycleMetaDataBuilder(beanMetaData, LifecycleMetaDataBuilder.LifecycleType.START);
+      stopBuilder = new LifecycleMetaDataBuilder(beanMetaData, LifecycleMetaDataBuilder.LifecycleType.STOP);
+      destroyBuilder = new LifecycleMetaDataBuilder(beanMetaData, LifecycleMetaDataBuilder.LifecycleType.DESTROY);
+   }
+
+   public BeanMetaData getBeanMetaData()
+   {
+      return beanMetaData;
+   }
+
+   public BeanMetaDataBuilder setMode(String modeString)
+   {
+      return setMode(new ControllerMode(modeString));
+   }
+
+   public BeanMetaDataBuilder setMode(ControllerMode mode)
+   {
+      beanMetaData.setMode(mode);
+      return this;
+   }
+
+   public BeanMetaDataBuilder setClassLoader(Object classLoader)
+   {
+      beanMetaData.setClassLoader(new AbstractClassLoaderMetaData(new AbstractValueMetaData(classLoader)));
+      return this;
+   }
+
+   public BeanMetaDataBuilder addConstructorParameter(String type, Object value)
+   {
+      ConstructorMetaData constructor = beanMetaData.getConstructor();
+      if (constructor == null)
+      {
+         constructor = new AbstractConstructorMetaData();
+         beanMetaData.setConstructor(constructor);
+         constructorBuilder = new ParameterMetaDataBuilder<ConstructorMetaData>(constructor);
+      }
+      constructorBuilder.addParameterMetaData(type, value);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addPropertyMetaData(String name, Object value)
+   {
+      Set<PropertyMetaData> properties = beanMetaData.getProperties();
+      if (properties == null)
+      {
+         properties = new HashSet<PropertyMetaData>();
+         beanMetaData.setProperties(properties);
+      }
+      properties.add(new AbstractPropertyMetaData(name, value));
+      return this;
+   }
+
+   public BeanMetaDataBuilder setCreate(String methodName)
+   {
+      createBuilder.createLifecycleMetaData(methodName);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addCreateParameter(String type, Object value)
+   {
+      createBuilder.addParameterMetaData(type, value);
+      return this;
+   }
+
+   public BeanMetaDataBuilder setStart(String methodName)
+   {
+      startBuilder.createLifecycleMetaData(methodName);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addStartParameter(String type, Object value)
+   {
+      startBuilder.addParameterMetaData(type, value);
+      return this;
+   }
+
+   public BeanMetaDataBuilder setStop(String methodName)
+   {
+      stopBuilder.createLifecycleMetaData(methodName);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addStopParameter(String type, Object value)
+   {
+      stopBuilder.addParameterMetaData(type, value);
+      return this;
+   }
+
+   public BeanMetaDataBuilder setDestroy(String methodName)
+   {
+      destroyBuilder.createLifecycleMetaData(methodName);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addDestroyParameter(String type, Object value)
+   {
+      destroyBuilder.addParameterMetaData(type, value);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addSupply(Object supply)
+   {
+      Set<SupplyMetaData> supplies = beanMetaData.getSupplies();
+      if (supplies == null)
+      {
+         supplies = new HashSet<SupplyMetaData>();
+         beanMetaData.setSupplies(supplies);
+      }
+      supplies.add(new AbstractSupplyMetaData(supply));
+      return this;
+   }
+
+   public BeanMetaDataBuilder addDemand(Object demand)
+   {
+      Set<DemandMetaData> demands = beanMetaData.getDemands();
+      if (demands == null)
+      {
+         demands = new HashSet<DemandMetaData>();
+         beanMetaData.setDemands(demands);
+      }
+      demands.add(new AbstractDemandMetaData(demand));
+      return this;
+   }
+
+   public BeanMetaDataBuilder addDependency(Object dependency)
+   {
+      Set<DependencyMetaData> dependencies = beanMetaData.getDepends();
+      if (dependencies == null)
+      {
+         dependencies = new HashSet<DependencyMetaData>();
+         beanMetaData.setDepends(dependencies);
+      }
+      dependencies.add(new AbstractDependencyMetaData(dependency));
+      return this;
+   }
+
+   public BeanMetaDataBuilder addInstall(String methodName)
+   {
+      List<InstallMetaData> installs = beanMetaData.getInstalls();
+      if (installs == null)
+      {
+         installs = new ArrayList<InstallMetaData>();
+         beanMetaData.setInstalls(installs);
+      }
+      AbstractInstallMetaData installMetaData = new AbstractInstallMetaData();
+      installMetaData.setMethodName(methodName);
+      installs.add(installMetaData);
+      return this;
+   }
+
+   public BeanMetaDataBuilder addUninstall(String methodName)
+   {
+      List<InstallMetaData> uninstalls = beanMetaData.getUninstalls();
+      if (uninstalls == null)
+      {
+         uninstalls = new ArrayList<InstallMetaData>();
+         beanMetaData.setUninstalls(uninstalls);
+      }
+      AbstractInstallMetaData uninstallMetaData = new AbstractInstallMetaData();
+      uninstallMetaData.setMethodName(methodName);
+      uninstalls.add(uninstallMetaData);
+      return this;
+   }
+
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java	2006-12-25 14:48:09 UTC (rev 59227)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java	2006-12-25 18:51:53 UTC (rev 59228)
@@ -0,0 +1,122 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.beans.metadata.plugins;
+
+import java.lang.reflect.Method;
+
+import org.jboss.beans.metadata.spi.LifecycleMetaData;
+
+/**
+ * Helper class.
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ * @see BeanMetaDataBuilder
+ * @see ParameterMetaDataBuilder
+ */
+public class LifecycleMetaDataBuilder
+{
+   private AbstractBeanMetaData beanMetaData;
+   private Method GET_METHOD;
+   private Method SET_METHOD;
+   private ParameterMetaDataBuilder<LifecycleMetaData> builder;
+
+   public enum LifecycleType
+   {
+      CREATE("Create"),
+      START("Start"),
+      STOP("Stop"),
+      DESTROY("Destroy");
+
+      private String type;
+
+      LifecycleType(String type)
+      {
+         this.type = type;
+      }
+
+      public String toString()
+      {
+         return type;
+      }
+   }
+
+   public LifecycleMetaDataBuilder(AbstractBeanMetaData beanMetaData, LifecycleType type) throws IllegalArgumentException
+   {
+      this.beanMetaData = beanMetaData;
+      try
+      {
+         GET_METHOD = AbstractBeanMetaData.class.getMethod("get" + type);
+         SET_METHOD = AbstractBeanMetaData.class.getMethod("set" + type, LifecycleMetaData.class);
+      }
+      catch (NoSuchMethodException e)
+      {
+         throw new IllegalArgumentException("Holder MetaData object doesn't implement get or set " + type + " method: " + e);
+      }
+   }
+
+   private LifecycleMetaData getLifecycle()
+   {
+      try
+      {
+         return (LifecycleMetaData) GET_METHOD.invoke(beanMetaData);
+      }
+      catch (Exception e)
+      {
+         throw new IllegalArgumentException(e);
+      }
+   }
+
+   private void setLifecycle(LifecycleMetaData lifecycle)
+   {
+      try
+      {
+         SET_METHOD.invoke(beanMetaData, lifecycle);
+      }
+      catch (Exception e)
+      {
+         throw new IllegalArgumentException(e);
+      }
+   }
+
+   public LifecycleMetaData createLifecycleMetaData(String methodName)
+   {
+      AbstractLifecycleMetaData lifecycle = new AbstractLifecycleMetaData();
+      if (methodName != null)
+      {
+         lifecycle.setMethodName(methodName);
+      }
+      setLifecycle(lifecycle);
+      builder = new ParameterMetaDataBuilder<LifecycleMetaData>(lifecycle);
+      return lifecycle;
+   }
+
+   public LifecycleMetaData addParameterMetaData(String type, Object value)
+   {
+      LifecycleMetaData lifecycle = getLifecycle();
+      if (lifecycle == null)
+      {
+         createLifecycleMetaData(null);
+      }
+      return builder.addParameterMetaData(type, value);
+   }
+
+}

Added: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ParameterMetaDataBuilder.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ParameterMetaDataBuilder.java	2006-12-25 14:48:09 UTC (rev 59227)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/ParameterMetaDataBuilder.java	2006-12-25 18:51:53 UTC (rev 59228)
@@ -0,0 +1,93 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2006, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.beans.metadata.plugins;
+
+import java.lang.reflect.Method;
+import java.util.ArrayList;
+import java.util.List;
+
+import org.jboss.beans.metadata.spi.ParameterMetaData;
+
+/**
+ * Helper class.
+ * @see BeanMetaDataBuilder
+ * @see LifecycleMetaDataBuilder
+ *
+ * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
+ */
+public class ParameterMetaDataBuilder<T>
+{
+   private T parameterHolder;
+   private Method GET_PARAMETERS;
+   private Method SET_PARAMETERS;
+
+   public ParameterMetaDataBuilder(T parameterHolder) throws IllegalArgumentException
+   {
+      this.parameterHolder = parameterHolder;
+      try
+      {
+         GET_PARAMETERS = parameterHolder.getClass().getMethod("getParameters");
+         SET_PARAMETERS = parameterHolder.getClass().getMethod("setParameters", List.class);
+      }
+      catch (NoSuchMethodException e)
+      {
+         throw new IllegalArgumentException("Holder MetaData object doesn't implement get or set parameters method: " + e);
+      }
+   }
+
+   private List<ParameterMetaData> getParameters()
+   {
+      try
+      {
+         return (List<ParameterMetaData>) GET_PARAMETERS.invoke(parameterHolder);
+      }
+      catch (Exception e)
+      {
+         throw new IllegalArgumentException(e);
+      }
+   }
+
+   private void setParameters(List<ParameterMetaData> parameters)
+   {
+      try
+      {
+         SET_PARAMETERS.invoke(parameterHolder, parameters);
+      }
+      catch (Exception e)
+      {
+         throw new IllegalArgumentException(e);
+      }
+   }
+
+   public T addParameterMetaData(String type, Object value)
+   {
+      List<ParameterMetaData> parameters = getParameters();
+      if (parameters == null)
+      {
+         parameters = new ArrayList<ParameterMetaData>();
+         setParameters(parameters);
+      }
+      parameters.add(new AbstractParameterMetaData(type, value));
+      return parameterHolder;
+   }
+
+}



From tr98e745dgs at lycos.com  Mon Dec 25 16:26:30 2006
From: tr98e745dgs at lycos.com (tr98e745dgs at lycos.com)
Date: Mon, 25 Dec 2006 16:26:30 -0500
Subject: [jboss-cvs] =?utf-8?b?wo3DsMKTw7rCgsKtwoLDqsKCwr3Cg1LCg8KBwoM=?=
	=?utf-8?b?wpPCg2fCj8OBwoLCtcKCwr/CgsOhwoLCosKCw5zCgsK1woLCvcKBY20o?=
	=?utf-8?b?X18pbQ==?=
Message-ID: 20061226062729.27773mail@mail.truwejsiksknhsijsjsnsjamjsnheussjha_web.com

?????R?????g???????????????H?????????????????????M???????v???????????????c?B
?????????R?????g???????O?????????????????????????????B?{?????????????????B
???????????R?????g?????????????????H???|???????????????????x?R?????g?????????????H
http://gogo-completevip.net.tonderuyo.com/megu/
?}?C?u???O???????????????B









?????@tr98e745dgs at lycos.com





From bwang at jboss.com  Mon Dec 25 22:41:11 2006
From: bwang at jboss.com (Ben Wang)
Date: Mon, 25 Dec 2006 22:41:11 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic ...
Message-ID: <E1Gz3Bf-00011r-7b@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/25 22:41:11

  Added:       tests-50/functional/org/jboss/cache/pojo/optimistic  
                        LocalTxTest.java AbstractOptimisticTestCase.java
  Log:
  Test case for optimistic locking
  
  Revision  Changes    Path
  1.1      date: 2006/12/26 03:41:11;  author: bwang;  state: Exp;JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic/LocalTxTest.java
  
  Index: LocalTxTest.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source.
   * Copyright 2006, 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.cache.pojo.optimistic;
  
  import junit.framework.TestCase;
  import junit.framework.Test;
  import junit.framework.TestSuite;
  import org.apache.commons.logging.Log;
  import org.apache.commons.logging.LogFactory;
  import org.jboss.cache.pojo.PojoCache;
  import org.jboss.cache.pojo.PojoCacheFactory;
  import org.jboss.cache.pojo.TestingUtil;
  import org.jboss.cache.pojo.test.Person;
  import org.jboss.cache.pojo.test.Address;
  import org.jboss.cache.transaction.DummyTransactionManager;
  
  import javax.naming.Context;
  import javax.naming.NamingException;
  import javax.naming.InitialContext;
  import javax.transaction.UserTransaction;
  import javax.transaction.SystemException;
  import javax.transaction.NotSupportedException;
  import javax.transaction.Transaction;
  import javax.transaction.RollbackException;
  import java.util.Properties;
  import java.util.List;
  import java.util.ArrayList;
  
  /**
   */
  public class LocalTxTest extends AbstractOptimisticTestCase
  {
     Log log = LogFactory.getLog(LocalTxTest.class);
     PojoCache cache;
     final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
     DummyTransactionManager tx_mgr;
     Throwable t1_ex, t2_ex;
     long start = 0;
  
  
     public LocalTxTest(String name)
     {
        super(name);
     }
  
     protected void setUp() throws Exception
     {
        super.setUp();
        log.info("setUp() ....");
  
        cache = createCache();
  
        System.setProperty(Context.INITIAL_CONTEXT_FACTORY, FACTORY);
  
        tx_mgr = DummyTransactionManager.getInstance();
        t1_ex = t2_ex = null;
     }
  
     protected void tearDown()
     {
        super.tearDown();
        cache.stop();
  
        DummyTransactionManager.destroy();
     }
  
  //   public void testDummy() {}
  
     UserTransaction getTransaction() throws SystemException, NotSupportedException, NamingException
     {
        Properties prop = new Properties();
        prop.put(Context.INITIAL_CONTEXT_FACTORY,
                "org.jboss.cache.transaction.DummyContextFactory");
        return (UserTransaction) new InitialContext(prop).lookup("UserTransaction");
     }
  
     private Person createPerson(String id, String name, int age)
     {
        Person p = new Person();
        p.setName(name);
        p.setAge(age);
        cache.attach(id, p);
        return p;
     }
  
     public void testSimple() throws Exception
     {
        log.info("testSimple() ....");
        UserTransaction tx = getTransaction();
        tx.begin();
        Person p = createPerson("/person/test1", "Harald Gliebe", 32);
        tx.commit();
        tx.begin();
        p.setName("Benoit");
        tx.commit();
        Person p1 = (Person) cache.find("/person/test1");
        assertEquals("Benoit", p.getName());
        assertEquals("Benoit", p1.getName());
        tx.begin();
        p1.setAge(61);
        tx.commit();
        assertEquals(61, p.getAge());
        assertEquals(61, p1.getAge());
     }
  
     public void testModification() throws Exception
     {
        UserTransaction tx = getTransaction();
        tx.begin();
        Person p = createPerson("/person/test2", "Harald", 32);
        p.setName("Harald Gliebe");
        tx.commit();
        Person p1 = (Person) cache.find("/person/test2");
        tx.begin();
        p1.setName("Benoit");
        tx.commit();
        assertEquals(p.getName(), "Benoit");
        assertEquals(p1.getName(), "Benoit");
        tx.begin();
        p1.setName("Harald");
        tx.rollback();
        assertEquals(p.getName(), "Benoit");
        assertEquals(p1.getName(), "Benoit");
     }
  
     public void testConcurrentSimplePuts() throws Exception
     {
        Thread t1 = new Thread("t1")
        {
           Transaction tx;
  
           public void run()
           {
              try
              {
                 Person p = (Person) cache.find("/person/test6");
                 Address addr = new Address();
                 addr.setCity("San Jose");
                 UserTransaction tx = getTransaction();
                 tx.begin();
                 p.setAddress(addr);
                 TestingUtil.sleepThread(17000);
                 tx.commit();
              }
              catch (RollbackException rollback)
              {
                 ;
              }
              catch (Exception ex)
              {
                 t1_ex = ex;
              }
           }
        };
  
        Thread t2 = new Thread("t2")
        {
           Transaction tx;
  
           public void run()
           {
              UserTransaction tx = null;
              try
              {
                 TestingUtil.sleepThread(1000); // give Thread1 time to createPerson
                 Person p = (Person) cache.find("/person/test6");
                 Address addr = new Address();
                 addr.setCity("Santa Clara");
                 tx = getTransaction();
                 tx.begin();
                 p.setAddress(addr);
                 tx.commit();
              }
              catch (RollbackException rollback)
              {
                 ;
              }
              catch (Exception ex)
              {
  //               t2_ex = ex;
                 try
                 {
                    tx.rollback();
                 } catch (SystemException e)
                 {
                    e.printStackTrace();
                    t2_ex = e;
                 }
              }
           }
        };
  
        Person p = createPerson("/person/test6", "p6", 50);
  
        t1.start();
        t2.start();
  
        t1.join();
        t2.join();
  
        // t2 should rollback due to timeout while t2 should succeed
        if (t2_ex != null)
           fail("Thread1 failed: " + t2_ex);
        if (t1_ex != null)
           fail("Thread2 failed: " + t1_ex);
  
        // This would fail because we are writing to __JBossInteral__ for every attach now.
        // As a result, there is version conflict for optimistic locking and cuasing
        // rollback.
        assertNotSame("City should be different ", "San Jose", p.getAddress().getCity());
     }
  
     public void testConcurrentPuts() throws Exception
     {
        Thread t1 = new Thread("t1")
        {
           Transaction tx;
  
           public void run()
           {
              try
              {
                 List<String> lang = ((Person) cache.find("/person/test6")).getLanguages();
                 UserTransaction tx = getTransaction();
                 tx.begin();
                 lang.add("German");
                 TestingUtil.sleepThread(17000);
                 tx.commit();
              }
              catch (RollbackException rollback)
              {
                 ;
              }
              catch (Exception ex)
              {
                 t1_ex = ex;
              }
           }
        };
  
        Thread t2 = new Thread("t2")
        {
           Transaction tx;
  
           public void run()
           {
              UserTransaction tx = null;
              try
              {
                 TestingUtil.sleepThread(1000); // give Thread1 time to createPerson
                 List<String> lang = ((Person) cache.find("/person/test6")).getLanguages();
                 tx = getTransaction();
                 tx.begin();
                 lang.add("English");
                 tx.commit();
              }
              catch (RollbackException rollback)
              {
                 ;
              }
              catch (Exception ex)
              {
                 try
                 {
                    tx.rollback();
                 } catch (SystemException e)
                 {
                    e.printStackTrace();
                    t2_ex = e;
                 }
              }
           }
        };
  
        Person p = createPerson("/person/test6", "p6", 50);
        List<String> lang = new ArrayList<String>();
        lang.add("German");
        p.setLanguages(lang);
  
        t1.start();
        t2.start();
  
        t1.join();
        t2.join();
  
        // t2 should rollback due to timeout while t2 should succeed
        if (t2_ex != null)
           fail("Thread1 failed: " + t2_ex);
        if (t1_ex != null)
           fail("Thread2 failed: " + t1_ex);
  
        int size = ((Person) cache.find("/person/test6")).getLanguages().size();
        assertEquals("number of languages ",
                2, size);
     }
  
     void log(String s)
     {
        long now;
        if (start == 0)
           start = System.currentTimeMillis();
        now = System.currentTimeMillis();
  
        System.out.println("[" + Thread.currentThread().getName() + "] [" + (now - start) + "] " + s);
     }
  
  
     public static Test suite() throws Exception
     {
        return new TestSuite(LocalTxTest.class);
     }
  
  
     public static void main(String[] args) throws Exception
     {
        junit.textui.TestRunner.run(suite());
     }
  
  }
  
  
  
  1.1      date: 2006/12/26 03:41:11;  author: bwang;  state: Exp;JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic/AbstractOptimisticTestCase.java
  
  Index: AbstractOptimisticTestCase.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source.
   * Copyright 2006, 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.cache.pojo.optimistic;
  
  import junit.framework.TestCase;
  import org.jboss.cache.Fqn;
  import org.jboss.cache.CacheListener;
  import org.jboss.cache.CacheSPI;
  import org.jboss.cache.pojo.PojoCache;
  import org.jboss.cache.pojo.PojoCacheFactory;
  import org.jboss.cache.marshall.MethodCall;
  import org.jboss.cache.marshall.MethodCallFactory;
  import org.jboss.cache.marshall.MethodDeclarations;
  import org.jboss.cache.interceptors.Interceptor;
  import org.jboss.cache.interceptors.InvocationContextInterceptor;
  import org.jboss.cache.interceptors.TxInterceptor;
  import org.jboss.cache.interceptors.OptimisticReplicationInterceptor;
  import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
  import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  import org.jboss.cache.transaction.DummyTransactionManager;
  import org.jboss.cache.misc.TestingUtil;
  import org.jboss.cache.lock.IsolationLevel;
  import org.jboss.cache.factories.XmlConfigurationParser;
  import org.jboss.cache.xml.XmlHelper;
  import org.jboss.cache.optimistic.TestListener;
  import org.jboss.cache.optimistic.DefaultDataVersion;
  import org.jboss.cache.config.Configuration;
  import org.jboss.cache.config.CacheLoaderConfig;
  import org.w3c.dom.Element;
  
  import javax.transaction.TransactionManager;
  import javax.transaction.SystemException;
  import java.io.File;
  import java.util.Random;
  import java.util.List;
  import java.util.ArrayList;
  import java.util.Iterator;
  
  /**
   * Base test for optimistic locking. Copied from Cache counterpart.
   */
  public abstract class AbstractOptimisticTestCase extends TestCase
  {
     private int instanceNumber;
  
     // some test data shared among all the test cases
     protected Fqn fqn = Fqn.fromString("/blah");
     protected String key = "myKey", value = "myValue";
  
     protected String getTempDir()
     {
        return getTempDir("tempdir");
     }
  
     private String getTempDir(String name)
     {
        String tempDir = System.getProperty("java.io.tmpdir", "/tmp");
        tempDir = tempDir + File.separator + name;
        System.out.println("tmpdir property: " + System.getProperty("java.io.tmpdir"));
        System.out.println("Attempting to create dir [" + tempDir + "]");
        File tempDirFile = new File(tempDir);
        if (!tempDirFile.exists())
        {
           tempDirFile.mkdirs();
        }
        return tempDir;
     }
  
     public AbstractOptimisticTestCase(String name)
     {
        super(name);
     }
  
     protected PojoCache createCacheUnstarted() throws Exception
     {
        return createCacheUnstarted(true);
     }
  
     protected PojoCache createCacheUnstarted(boolean optimistic) throws Exception
     {
        Configuration c = new Configuration();
        if (optimistic) c.setNodeLockingScheme("OPTIMISTIC");
  
        c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
        c.setCacheMode("LOCAL");
        PojoCache cache = PojoCacheFactory.createCache(c, false);
        return cache;
     }
  
     protected PojoCache createCacheWithListener() throws Exception
     {
        return createCacheWithListener(new TestListener());
     }
  
     protected PojoCache createCacheWithListener(CacheListener listener) throws Exception
     {
        PojoCache cache = createCacheUnstarted();
        cache.create();
        cache.start();
        cache.getCache().addCacheListener(listener);
        return cache;
     }
  
     /**
      * Returns a tree cache with passivation disabled in the loader.
      *
      * @return
      * @throws Exception
      */
     protected PojoCache createCacheWithLoader() throws Exception
     {
        return createCacheWithLoader(false);
     }
  
     protected CacheLoaderConfig getCacheLoaderConfig(boolean shared, String filename, boolean passivation) throws Exception
     {
        String xml = "            <config>\n" +
                "                <passivation>" + passivation + "</passivation>\n" +
                "                <preload></preload>\n" +
                "                <shared>" + shared + "</shared>\n" +
                "                <cacheloader>\n" +
                "                    <class>org.jboss.cache.loader.FileCacheLoader</class>\n" +
                "                    <properties>\n" +
                "                    </properties>\n" +
                "                    <async>false</async>\n" +
                "                    <fetchPersistentState>" + (!shared) + "</fetchPersistentState>\n" +
                "                    <ignoreModifications>false</ignoreModifications>\n" +
                "                </cacheloader>\n" +
                "            </config>";
        Element element = XmlHelper.stringToElement(xml);
        return XmlConfigurationParser.parseCacheLoaderConfig(element);
     }
  
     protected PojoCache createCacheWithLoader(boolean passivationEnabled) throws Exception
     {
        PojoCache cache = createCacheUnstarted();
        Configuration c = cache.getCache().getConfiguration();
        c.setCacheLoaderConfig(getCacheLoaderConfig(true, getTempDir(), passivationEnabled));
        cache.create();
        cache.start();
        return cache;
     }
  
     protected PojoCache createCache() throws Exception
     {
        PojoCache cache = createCacheUnstarted();
        cache.create();
        cache.start();
        return cache;
     }
  
     protected void destroyCache(PojoCache c)
     {
        c.stop();
        c.destroy();
     }
  
  
     protected PojoCache createPessimisticCache() throws Exception
     {
        Configuration c = new Configuration();
        c.setClusterName("name");
        c.setInitialStateRetrievalTimeout(5000);
        c.setClusterConfig(getDefaultProperties());
        c.setCacheMode(Configuration.CacheMode.REPL_SYNC);
        c.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
        c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
        
        PojoCache cache = PojoCacheFactory.createCache(c, false);
        cache.create();
        cache.start();
  
  
        return cache;
     }
  
     protected PojoCache createPessimisticCacheLocal() throws Exception
     {
        Configuration c = new Configuration();
  
        c.setClusterName("name");
        c.setInitialStateRetrievalTimeout(5000);
        c.setClusterConfig(getDefaultProperties());
  
        c.setCacheMode(Configuration.CacheMode.LOCAL);
        c.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
        c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
        PojoCache cache = PojoCacheFactory.createCache(c, false);
        cache.create();
        cache.start();
  
        return cache;
     }
  
     protected String getDefaultProperties()
     {
        return "UDP(mcast_addr=228.1.2.3;mcast_port=48866;ip_ttl=32;" +
                "mcast_send_buf_size=150000;mcast_recv_buf_size=80000;loopback=true;ip_mcast=true;bind_addr=127.0.0.1):" +
                "PING(timeout=1000;num_initial_members=2):" +
                "MERGE2(min_interval=5000;max_interval=10000):" +
                "FD_SOCK:" +
                "VERIFY_SUSPECT(timeout=1500):" +
                "pbcast.NAKACK(gc_lag=50;max_xmit_size=8192;retransmit_timeout=600,1200,2400,4800):" +
                "UNICAST(timeout=600,1200,2400,4800):" +
                "pbcast.STABLE(desired_avg_gossip=20000):" +
                "FRAG(frag_size=8192;down_thread=false;up_thread=false):" +
                "pbcast.GMS(join_timeout=5000;join_retry_timeout=2000;" +
                "shun=false;print_local_addr=true):" +
                "pbcast.STATE_TRANSFER";
     }
  
     protected PojoCache createReplicatedCache(Configuration.CacheMode mode) throws Exception
     {
        return createReplicatedCache("test", mode);
     }
  
     protected PojoCache createReplicatedCache(String name, Configuration.CacheMode mode) throws Exception
     {
        Configuration c = new Configuration();
  
        c.setClusterName(name);
        c.setInitialStateRetrievalTimeout(5000);
        c.setClusterConfig(getDefaultProperties());
        c.setCacheMode(mode);
        if (mode == Configuration.CacheMode.REPL_SYNC)
        {
           // make sure commits and rollbacks are sync as well
           c.setSyncCommitPhase(true);
           c.setSyncRollbackPhase(true);
        }
        c.setNodeLockingScheme("OPTIMISTIC");
        c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
        PojoCache cache = PojoCacheFactory.createCache(c, false);
        cache.create();
        cache.start();
  
        return cache;
     }
  
     protected PojoCache createReplicatedCacheWithLoader(boolean shared, Configuration.CacheMode cacheMode) throws Exception
     {
        return createReplicatedCacheWithLoader("temp-loader", shared, cacheMode);
     }
  
     protected PojoCache createReplicatedCacheWithLoader(boolean shared) throws Exception
     {
        return createReplicatedCacheWithLoader("temp-loader", shared, Configuration.CacheMode.REPL_SYNC);
     }
  
     protected PojoCache createReplicatedCacheWithLoader(String name, boolean shared) throws Exception
     {
        return createReplicatedCacheWithLoader(name, shared, Configuration.CacheMode.REPL_SYNC);
     }
  
     protected PojoCache createReplicatedCacheWithLoader(String name, boolean shared, Configuration.CacheMode cacheMode) throws Exception
     {
        Configuration c = new Configuration();
        c.setClusterName(name);
        c.setInitialStateRetrievalTimeout(5000);
        c.setClusterConfig(getDefaultProperties());
        c.setCacheMode(cacheMode);
        c.setSyncCommitPhase(true);
        c.setSyncRollbackPhase(true);
        c.setNodeLockingScheme("OPTIMISTIC");
        c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
        c.setCacheLoaderConfig(getCacheLoaderConfig(shared, shared ? getTempDir(name + "-shared") : getTempDir(name + instanceNumber++), false));
  
        PojoCache cache = PojoCacheFactory.createCache(c, false);
        cache.create();
        cache.start();
        return cache;
     }
  
     protected Random random;
  
     protected void randomSleep(int min, int max)
     {
        if (random == null) random = new Random();
        long l = -1;
        while (l < min) l = random.nextInt(max);
        TestingUtil.sleepThread(l);
     }
  
     protected void tearDown()
     {
        TransactionManager mgr = DummyTransactionManager.getInstance();
        try
        {
           if (mgr.getTransaction() != null)
           {
              mgr.rollback();
           }
        }
        catch (SystemException e)
        {
           // do nothing
        }
     }
  
     protected Interceptor getAlteredInterceptorChain(Interceptor newLast, CacheSPI spi, boolean replicated)
     {
        Interceptor ici = new InvocationContextInterceptor();
        ici.setCache(spi);
  
        Interceptor txInterceptor = new TxInterceptor();
        txInterceptor.setCache(spi);
  
        Interceptor replicationInterceptor = new OptimisticReplicationInterceptor();
        replicationInterceptor.setCache(spi);
  
        Interceptor createInterceptor = new OptimisticCreateIfNotExistsInterceptor();
        createInterceptor.setCache(spi);
  
        Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
        nodeInterceptor.setCache(spi);
  
        ici.setNext(txInterceptor);
        if (replicated)
        {
           txInterceptor.setNext(replicationInterceptor);
           replicationInterceptor.setNext(createInterceptor);
        }
        else
        {
           txInterceptor.setNext(createInterceptor);
        }
        createInterceptor.setNext(nodeInterceptor);
        nodeInterceptor.setNext(newLast);
  
        return ici;
     }
  
     public abstract class ExceptionThread extends Thread
     {
        protected Exception exception;
  
        public void setException(Exception e)
        {
           exception = e;
        }
  
        public Exception getException()
        {
           return exception;
        }
     }
  
     protected List injectDataVersion(List modifications)
     {
        List newList = new ArrayList();
        Iterator mi = modifications.iterator();
        while (mi.hasNext())
        {
           MethodCall c = (MethodCall) mi.next();
           Object[] oa = c.getArgs();
           Object[] na = new Object[oa.length + 1];
           System.out.println("*** " + oa.length);
           for (int i = 0; i < oa.length; i++) na[i] = oa[i];
           na[oa.length] = new DefaultDataVersion();
           newList.add(MethodCallFactory.create(MethodDeclarations.getVersionedMethod(c.getMethodId()), na));
        }
        return newList;
     }
  
  }
  
  
  


From bwang at jboss.com  Mon Dec 25 23:19:06 2006
From: bwang at jboss.com (Ben Wang)
Date: Mon, 25 Dec 2006 23:19:06 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic ...
Message-ID: <E1Gz3mM-0001kd-I1@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/25 23:19:06

  Added:       tests-50/functional/org/jboss/cache/pojo/optimistic 
                        CachedListTest.java
  Log:
  Test case for optimistic locking with List.
  
  Revision  Changes    Path
  1.1      date: 2006/12/26 04:19:06;  author: bwang;  state: Exp;JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic/CachedListTest.java
  
  Index: CachedListTest.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source.
   * Copyright 2006, 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.cache.pojo.optimistic;
  
  import junit.framework.TestCase;
  import junit.framework.Test;
  import junit.framework.TestSuite;
  import org.apache.commons.logging.Log;
  import org.apache.commons.logging.LogFactory;
  import org.jboss.cache.pojo.PojoCache;
  import org.jboss.cache.pojo.PojoCacheFactory;
  import org.jboss.cache.pojo.test.Address;
  
  import java.util.List;
  import java.util.ArrayList;
  import java.util.Iterator;
  import java.util.ListIterator;
  import java.util.NoSuchElementException;
  
  /**
   * List interface testing.
   *
   * @author Ben Wang
   */
  
  public class CachedListTest extends AbstractOptimisticTestCase
  {
     Log log = LogFactory.getLog(CachedListTest.class);
     PojoCache cache_;
     List languages;
     List languages2;
  
     public CachedListTest(String name)
     {
        super(name);
     }
  
  
     protected void setUp() throws Exception
     {
        super.setUp();
        cache_ = createCache();
  //      cache_ = createPessimisticCache();
        log.info("setUp() ....");
     }
  
     protected void tearDown()
     {
        super.tearDown();
        cache_.stop();
     }
  
     public void testAddAndRemoveIndex() throws Throwable
     {
        stage();
  
        languages.add(1, "Taiwanese");
        assertEquals("Languages size ", 4, languages.size());
        assertEquals("Language ", (Object) "Taiwanese", (Object) languages.get(1));
        languages.remove(2);
        assertEquals("Languages size ", 3, languages.size());
        assertEquals("Language ", (Object) "English", (Object) languages.get(2));
  
        languages.add("Mandarin");
        assertEquals("Languages size ", 4, languages.size());
        languages.remove("Mandarin");
        assertEquals("Languages size ", 3, languages.size());
     }
  
     protected void stage() throws Throwable
     {
        languages = new ArrayList();
        languages.add("English");
        languages.add("French");
        languages.add("English");
        cache_.attach("/person/test6", languages);
        languages = (List) cache_.find("/person/test6");
        int size = languages.size();
        assertEquals("Size of list ", 3, size);
  
        languages2 = new ArrayList();
        languages2.addAll(languages);
        assertEquals("New ArrayList().addAll(CachedList)", languages, languages2);
     }
  
     public void testAddAllAndClear() throws Throwable
     {
        stage();
        List list = new ArrayList();
        list.add("Taiwanese");
        list.add("Madarin");
  
        assertTrue("Language is Taiwanese ", list.contains("Taiwanese"));
  
        languages.addAll(list);
        assertEquals("Languages size ", 5, languages.size());
  
        languages.removeAll(list);
        assertEquals("Languages size ", 3, languages.size());
  
        assertEquals("Index of French ", 1, languages.indexOf("French"));
  
        languages.clear();
        assertEquals("Languages size ", 0, languages.size());
  
        assertTrue("Languages empty ", languages.isEmpty());
     }
  
     public void testEquals() throws Throwable
     {
        stage();
  
        List list = (List) cache_.find("/person/test6");
        assertTrue("List should be the same ", list.equals(languages));
        list = new ArrayList();
        list.add("German");
        list.add("test");
        list.add("English");
        assertFalse("List should not be the same ", languages.equals(list));
        assertFalse("List should not be the same ", list.equals(languages));
     }
  
     public void testIterator() throws Throwable
     {
        languages = new ArrayList();
        Iterator it0 = languages.iterator();
        assertFalse("Iterator should be empty ", it0.hasNext());
  
        stage();
  
        Iterator it = languages.iterator();
        Iterator it2 = languages2.iterator();
        int counter = 0;
        while (it.hasNext())
        {
           counter++;
           assertEquals(it.next(), it2.next());
           it.remove();
           it2.remove();
        }
  
        assertEquals("Size should be ", 3, counter);
        assertEquals("Skills should be empty ", 0, languages.size());
     }
  
     public void testListIterator() throws Throwable
     {
        languages = new ArrayList();
        ListIterator it0 = languages.listIterator();
        assertFalse("Iterator should be empty ", it0.hasNext());
        assertFalse("Iterator should be empty ", it0.hasPrevious());
  
        stage();
  
        ListIterator li = languages.listIterator();
        ListIterator li2 = languages2.listIterator();
        assertFalse("LI has no previous element ", li.hasPrevious());
        assertFalse("LI2 has no previous element ", li2.hasPrevious());
        assertTrue("LI has next element ", li.hasNext());
        assertTrue("LI2 has next element ", li2.hasNext());
        assertEquals(li.next(), li2.next());
        assertEquals("Index is ", 1, li.nextIndex());
        assertEquals("Index is ", 1, li2.nextIndex());
        assertEquals("Index is ", 0, li.previousIndex());
        assertEquals("Index is ", 0, li2.previousIndex());
        assertEquals(li.next(), li2.next());
        assertEquals(li.next(), li2.next()); // the end
        try
        {
           li.next();
           fail("Should throw an exception here ");
        }
        catch (NoSuchElementException ex)
        {
           ;
        }
        try
        {
           li2.next();
           fail("Should throw an exception here ");
        }
        catch (NoSuchElementException ex)
        {
           ;
        }
  
        assertEquals("Index is ", 3, li.nextIndex());
        assertEquals("Index is ", 3, li2.nextIndex());
        assertEquals("Index is ", 2, li.previousIndex());
        assertEquals("Index is ", 2, li2.previousIndex());
        li.previous();
        li2.previous();
        assertEquals("Index is ", 2, li.nextIndex());
        assertEquals("Index is ", 2, li2.nextIndex());
        assertEquals("Index is ", 1, li.previousIndex());
        assertEquals("Index is ", 1, li2.previousIndex());
        li.previous();
        li2.previous();
        li.previous();
        li2.previous();
  
        try
        {
           li.previous();
           fail("Should throw an exception here ");
        }
        catch (NoSuchElementException ex)
        {
           ;
        }
  
        try
        {
           li2.previous();
           fail("Should throw an exception here ");
        }
        catch (NoSuchElementException ex)
        {
           ;
        }
  
        try
        {
           assertEquals(li.next(), li2.next());
           li.remove();
           li2.remove();
        }
        catch (Exception e)
        {
           fail("ListIterator.remove failed" + e);
        }
  
  
        try
        {
           assertEquals(li.next(), li2.next());
           li.remove();
           li2.remove();
        }
        catch (Exception e)
        {
           fail("ListIterator.remove failed" + e);
        }
  
        try
        {
           assertEquals(li.next(), li2.next());
           assertEquals("ListIterator.remove test problem with nextIndex, cache next index=" + li.nextIndex() +
                   ", jdk next index=" + li2.nextIndex() + "cache list size = " + languages.size() + ", jdk list size = " + languages.size(),
                   li.nextIndex(), li2.nextIndex());
           li2.set("German");
           li.set("German");
           String s1 = (String) li.previous();
           String s2 = (String) li2.previous();
           assertEquals(s1, s2);
           assertEquals(s2, "German");
        }
        catch (Exception e)
        {
           fail("ListIterator.remove failed" + e + ", cache list size = " + languages.size() + ", jdk list size = " + languages.size());
        }
  
        try
        {
           assertEquals(li.next(), li2.next());
           li2.add("Vulcan");
           li.add("Vulcan");
           String s1 = (String) li.previous();
           String s2 = (String) li2.previous();
           assertEquals(s1, s2);
           assertEquals(s2, "Vulcan");
        }
        catch (Exception e)
        {
           fail("ListIterator.add failed" + e + ", cache list size = " + languages.size() + ", jdk list size = " + languages.size());
        }
  
     }
  
  
     public void testAttachAndDetach() throws Exception
     {
        List list = new ArrayList();
        list.add("English");
        list.add("French");
        list.add("Taiwanese");
  
        cache_.attach("/test", list); // attach
        list = (List) cache_.find("/test");
        assertEquals("Size ", 3, list.size());
  
        list = (List) cache_.detach("/test");
        assertEquals("Size ", 3, list.size());
  
        System.out.println("**** End of cache content **** ");
        list.remove(2);
        list.add("Hoklo");
        assertEquals("Size ", 3, list.size());
        assertEquals("Content ", "Hoklo", list.get(2));
  
        // Try to re-attach
        cache_.attach("/test", list);
        list.remove(2);
        assertEquals("Size ", 2, list.size());
     }
  
     public void testPojoAttachAndDetach() throws Exception
     {
        Address add1 = new Address();
        add1.setCity("San Jose");
        add1.setZip(95123);
  
        Address add2 = new Address();
        add2.setCity("Sunnyvale");
        add2.setZip(94086);
  
        Address add3 = new Address();
        add3.setCity("Santa Clara");
        add3.setZip(951131);
  
        List list = new ArrayList();
        list.add(add1);
        list.add(add2);
        list.add(add3);
  
        cache_.attach("/test", list); // attach
        list = (List) cache_.find("/test");
        assertEquals("Size ", 3, list.size());
  
        list = (List) cache_.detach("/test");
        assertEquals("Size ", 3, list.size());
  
        System.out.println("**** End of cache content **** ");
        list.remove(2);
        list.add(add2);
        assertEquals("Size ", 3, list.size());
        assertEquals("Content ", add2, list.get(2));
  
        // Try to re-attach
        cache_.attach("/test", list);
        list.remove(2);
        assertEquals("Size ", 2, list.size());
     }
  
     public void testEqual1() throws Exception
     {
        List list1 = new ArrayList();
        list1.add("ID1");
        list1.add("ID2");
        cache_.attach("test1", list1);
        list1 = (List)cache_.find("test1");
  
        List list2 = new ArrayList();
        list2.add("ID1");
        list2.add("ID2");
        cache_.attach("test2", list2);
        list2 = (List)cache_.find("test2");
  
        List list3 = new ArrayList();
        list3.add("ID2");
        list3.add("ID1");
        cache_.attach("test3", list3);
        list3 = (List)cache_.find("test3");
  
        assertEquals("List should be equal: ", list1, list1);
        assertTrue("List should be equal: ", list1.equals(list1));
        assertTrue("List should be equal: ", list1.equals(list2));
        assertFalse("List should not be equal: ", list1.equals(list3));
     }
  
     public void testEqual2() throws Exception
     {
        List list1 = new ArrayList();
        cache_.attach("test1", list1);
        list1 = (List)cache_.find("test1");
        list1.add("ID1");
        list1.add("ID2");
  
        List list2 = new ArrayList();
        cache_.attach("test2", list2);
        list2 = (List)cache_.find("test2");
        list2.add("ID1");
        list2.add("ID2");
  
        List list3 = new ArrayList();
        cache_.attach("test3", list3);
        list3 = (List)cache_.find("test3");
        list3.add("ID2");
        list3.add("ID1");
  
        assertEquals("List should be equal: ", list1, list1);
        assertTrue("List should be equal: ", list1.equals(list1));
        assertTrue("List should be equal: ", list1.equals(list2));
        assertFalse("List should not be equal: ", list1.equals(list3));
     }
  
     public static Test suite() throws Exception
     {
        return new TestSuite(CachedListTest.class);
     }
  
     public static void main(String[] args) throws Exception
     {
        junit.textui.TestRunner.run(suite());
     }
  
  }
  
  
  


From forge-admin at jboss.com  Tue Dec 26 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Tue, 26 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1Gz5MR-0003SW-7J@committer01.frg.pub.inap.atl.jboss.com>

Commit from nrichards (2006-12-25 11:17 EST)
---------------------

chapter,section,table,cell

  jboss-seam  src/pdf/META-INF/faces-config.xml                  1.3
  jboss-seam  src/pdf/META-INF/seam.taglib.xml                   1.3
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java  1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java        1.2
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UICell.java          1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIChapter.java       1.1
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIDocument.java      1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIFont.java          1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIImage.java         1.3
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIList.java          1.3
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIListItem.java      1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIPage.java          1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java     1.3
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UISection.java       1.1
+ jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UITable.java         1.1


Commit from nrichards (2006-12-25 11:28 EST)
---------------------

update examples

+ jboss-seam  examples/pdf/view/chapters.xhtml  1.1
  jboss-seam  examples/pdf/view/index.xhtml     1.3
  jboss-seam  examples/pdf/view/lists.xhtml     1.2
+ jboss-seam  examples/pdf/view/table.xhtml     1.1
  jboss-seam  examples/pdf/view/whyseam.xhtml   1.2


Commit from bwang (2006-12-25 22:41 EST)
-----------------

Test case for optimistic locking

+ JBossCache  tests-50/functional/org/jboss/cache/pojo/optimistic/LocalTxTest.java                 1.1
+ JBossCache  tests-50/functional/org/jboss/cache/pojo/optimistic/AbstractOptimisticTestCase.java  1.1


Commit from bwang (2006-12-25 23:19 EST)
-----------------

Test case for optimistic locking with List.

+ JBossCache  tests-50/functional/org/jboss/cache/pojo/optimistic/CachedListTest.java  1.1
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061226/d499b55d/attachment.html 

From norman.richards at jboss.com  Tue Dec 26 01:12:56 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 01:12:56 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui  ...
Message-ID: <E1Gz5YW-0003pw-Sr@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 01:12:56

  Modified:    src/pdf/org/jboss/seam/pdf/ui  UICell.java
  Log:
  cell params
  
  Revision  Changes    Path
  1.2       +183 -0    jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UICell.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UICell.java	25 Dec 2006 16:17:54 -0000	1.1
  +++ UICell.java	26 Dec 2006 06:12:56 -0000	1.2
  @@ -1,9 +1,12 @@
   package org.jboss.seam.pdf.ui;
   
  +import org.jboss.seam.pdf.ITextUtils;
  +
   import javax.faces.event.*;
   import javax.faces.context.*;
   import javax.faces.component.*;
   import javax.servlet.http.*;
  +
   import java.io.*;
   
   import com.lowagie.text.*;
  @@ -15,6 +18,119 @@
       public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UICell";
   
       PdfPCell cell;
  +    String  horizontalAlignment;
  +    String  verticalAlignment;
  +    Float   paddingLeft;
  +    Float   paddingRight;
  +    Float   paddingTop;
  +    Float   paddingBottom;
  +    Boolean useBorderPadding;
  +    Float   leading;
  +    Float   multipliedLeading;
  +    Float   indent;
  +    Float   extraParagraphSpace;
  +    Float   fixedHeight;
  +    Boolean noWrap;
  +    Float   minimumHeight;
  +    Integer colspan;
  +    Float   followingIndent;
  +    Float   rightIndent;
  +    Integer spaceCharRatio;
  +    Integer runDirection;
  +    Integer arabicOptions;
  +    Boolean useAscender;
  +    Integer rotation;
  +
  +
  +    public void setHorizontalAlignment(String horizontalAlignment) {
  +        this.horizontalAlignment = horizontalAlignment;
  +    }
  +
  +    public void setVerticalAlignment(String verticalAlignment) {
  +        this.verticalAlignment = verticalAlignment;
  +    }
  +
  +    public void setPaddingLeft(Float paddingLeft) {
  +        this.paddingLeft = paddingLeft;
  +    }
  +
  +    public void setPaddingRight(Float paddingRight) {
  +        this.paddingRight = paddingRight;
  +    }
  +
  +    public void setPaddingTop(Float paddingTop) {
  +        this.paddingTop = paddingTop;
  +    }
  +
  +    public void setPaddingBottom(Float paddingBottom) {
  +        this.paddingBottom = paddingBottom;
  +    }
  +
  +    public void setUseBorderPadding(Boolean useBorderPadding) {
  +        this.useBorderPadding = useBorderPadding;
  +    }
  +
  +    public void setLeading(Float leading) {
  +        this.leading = leading;
  +    }
  +
  +    public void setMultipliedLeading(Float multipliedLeading) {
  +        this.multipliedLeading = multipliedLeading;
  +    }
  +
  +    public void setIndent(Float indent) {
  +        this.indent = indent;
  +    }
  +
  +    public void setExtraParagraphSpace(Float extraParagraphSpace) {
  +        this.extraParagraphSpace = extraParagraphSpace;
  +    }
  +
  +    public void setFixedHeight(Float fixedHeight) {
  +        this.fixedHeight = fixedHeight;
  +    }
  +
  +    public void setNoWrap(Boolean noWrap) {
  +        this.noWrap = noWrap;
  +    }
  +
  +    public void setMinimumHeight(Float minimumHeight) {
  +        this.minimumHeight = minimumHeight;
  +    }
  +
  +    public void setColspan(Integer colspan) {
  +        this.colspan = colspan;
  +    }
  +
  +    public void setFollowingIndent(Float followingIndent) {
  +        this.followingIndent = followingIndent;
  +    }
  +
  +    public void setRightIndent(Float rightIndent) {
  +        this.rightIndent = rightIndent;
  +    }
  +
  +    public void setSpaceCharRatio(Integer spaceCharRatio) {
  +        this.spaceCharRatio = spaceCharRatio;
  +    }
  +
  +    public void setRunDirection(Integer runDirection) {
  +        this.runDirection = runDirection;
  +    }
  +
  +    public void setArabicOptions(Integer arabicOptions) {
  +        this.arabicOptions = arabicOptions;
  +    }
  +
  +    public void setUseAscender(Boolean useAscender) {
  +        this.useAscender = useAscender;
  +    }
  +
  +    public void setRotation(Integer rotation) {
  +        this.rotation = rotation;
  +    }
  +
  +
   
       public Object getITextObject() {
           return cell;
  @@ -26,6 +142,73 @@
   
       public void createITextObject() {
           cell = new PdfPCell();
  +
  +        if (horizontalAlignment != null) {
  +            cell.setHorizontalAlignment(ITextUtils.alignmentValue(horizontalAlignment));
  +            System.out.println("---> " + cell.getHorizontalAlignment());
  +        }
  +        if (verticalAlignment != null) {
  +            cell.setVerticalAlignment(ITextUtils.alignmentValue(verticalAlignment));
  +        }
  +        if (paddingLeft != null) {
  +            cell.setPaddingLeft(paddingLeft);
  +        }
  +        if (paddingRight != null) {
  +            cell.setPaddingRight(paddingRight);
  +        }
  +        if (paddingTop != null) {
  +            cell.setPaddingTop(paddingTop);
  +        }
  +        if (paddingBottom != null) {
  +            cell.setPaddingBottom(paddingBottom);
  +        }
  +        if (useBorderPadding != null) {
  +            cell.setUseBorderPadding(useBorderPadding);
  +        }
  +        if (leading != null || multipliedLeading != null) {            
  +            cell.setLeading(leading == null         ? 0 : leading.floatValue(), 
  +                            multipliedLeading==null ? 0 : multipliedLeading.floatValue());
  +        }
  +        if (indent != null) {
  +            cell.setIndent(indent);
  +        }
  +        if (extraParagraphSpace != null) {
  +            cell.setExtraParagraphSpace(extraParagraphSpace);
  +        }
  +        if (fixedHeight != null) {
  +            cell.setFixedHeight(fixedHeight);
  +        }
  +        if (noWrap != null) {
  +            cell.setNoWrap(noWrap);
  +        }
  +        if (minimumHeight != null) {
  +            cell.setMinimumHeight(minimumHeight);
  +        }
  +        if (colspan != null) {
  +            cell.setColspan(colspan);
  +        }
  +        if (followingIndent != null) {
  +            cell.setFollowingIndent(followingIndent);
  +        }
  +        if (rightIndent != null) {
  +            cell.setRightIndent(rightIndent);
  +        }
  +        if (spaceCharRatio != null) {
  +            cell.setSpaceCharRatio(spaceCharRatio);
  +        }
  +        if (runDirection != null) {
  +            cell.setRunDirection(runDirection);
  +        }
  +        if (arabicOptions != null) {
  +            cell.setArabicOptions(arabicOptions);
  +        }
  +        if (useAscender != null) {
  +            cell.setUseAscender(useAscender);
  +        }
  +        if (rotation != null) {
  +            cell.setRotation(rotation);
  +        }
  +
       }
   
       public void add(Object o) {
  
  
  


From norman.richards at jboss.com  Tue Dec 26 01:12:57 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 01:12:57 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf  ...
Message-ID: <E1Gz5YX-0003q3-05@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 01:12:56

  Modified:    src/pdf/org/jboss/seam/pdf  ITextUtils.java
  Log:
  cell params
  
  Revision  Changes    Path
  1.2       +13 -1     jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ITextUtils.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ITextUtils.java	24 Dec 2006 19:29:01 -0000	1.1
  +++ ITextUtils.java	26 Dec 2006 06:12:56 -0000	1.2
  @@ -21,7 +21,19 @@
           if (ElementTags.ALIGN_JUSTIFIED_ALL.equalsIgnoreCase(alignment)) {
               return Element.ALIGN_JUSTIFIED_ALL;
           }
  +        if (ElementTags.ALIGN_TOP.equalsIgnoreCase(alignment)) {
  +            return Element.ALIGN_TOP;
  +        }
  +        if (ElementTags.ALIGN_MIDDLE.equalsIgnoreCase(alignment)) {
  +            return Element.ALIGN_MIDDLE;
  +        }
  +        if (ElementTags.ALIGN_BOTTOM.equalsIgnoreCase(alignment)) {
  +            return Element.ALIGN_BOTTOM;
  +        }
  +        if (ElementTags.ALIGN_BASELINE.equalsIgnoreCase(alignment)) {
  +            return Element.ALIGN_BASELINE;
  +        }
   
  -        return Element.ALIGN_LEFT;
  +        return Element.ALIGN_UNDEFINED;
       }
   }
  
  
  


From norman.richards at jboss.com  Tue Dec 26 01:12:57 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 01:12:57 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view  ...
Message-ID: <E1Gz5YX-0003qA-44@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 01:12:57

  Modified:    examples/pdf/view  table.xhtml
  Log:
  cell params
  
  Revision  Changes    Path
  1.2       +5 -6      jboss-seam/examples/pdf/view/table.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: table.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/table.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- table.xhtml	25 Dec 2006 16:28:52 -0000	1.1
  +++ table.xhtml	26 Dec 2006 06:12:57 -0000	1.2
  @@ -6,23 +6,22 @@
       <p:font size="24"><p:paragraph spacingAfter="50">Table Test</p:paragraph></p:font>  
   
   
  -    <p:table columns="3">
  -        <p:cell>cell 1</p:cell>
  +    <p:table columns="4">
  +        <p:cell colspan="2">cell 1</p:cell>
           <p:cell>cell 2</p:cell>
           <p:cell>cell 3</p:cell>
           <p:cell>cell 4</p:cell>
  -        <p:cell>cell 5</p:cell>
  +        <p:cell colspan="2">cell 5</p:cell>
           <p:cell>cell 6</p:cell>
           <p:cell>cell 7</p:cell>
           <p:cell>cell 8</p:cell>
  -        <p:cell>cell 9</p:cell>
  +        <p:cell colspan="2">cell 9</p:cell>
       </p:table>
   
       <p:paragraph spacingBefore="10" spacingAfter="10">This is another table.  It should be large enough to span multiple pages with the headers repeated on other page</p:paragraph>
   
       <p:table columns="2" headerRows="1">
  -        <p:cell><p:font size="20">This is a header</p:font></p:cell>
  -        <p:cell>This is also a header!</p:cell>
  +        <p:cell colspan="2"><p:font size="20"><p:paragraph alignment="center">This is a header</p:paragraph></p:font></p:cell>
           <ui:repeat value="#{lists.daysOfWeek}" var="day">
               <p:cell>#{day}</p:cell>
               <p:cell>Blah blah blah</p:cell>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 05:46:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 05:46:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59229 -
	projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins
Message-ID: <E1Gz9p8-0008WQ-TL@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-26 05:46:20 -0500 (Tue, 26 Dec 2006)
New Revision: 59229

Modified:
   projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java
Log:
javadocs

Modified: projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java
===================================================================
--- projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java	2006-12-25 18:51:53 UTC (rev 59228)
+++ projects/microcontainer/trunk/kernel/src/main/org/jboss/beans/metadata/plugins/LifecycleMetaDataBuilder.java	2006-12-26 10:46:20 UTC (rev 59229)
@@ -27,10 +27,10 @@
 
 /**
  * Helper class.
+ * @see BeanMetaDataBuilder
+ * @see ParameterMetaDataBuilder
  *
  * @author <a href="mailto:ales.justin at jboss.com">Ales Justin</a>
- * @see BeanMetaDataBuilder
- * @see ParameterMetaDataBuilder
  */
 public class LifecycleMetaDataBuilder
 {



From norman.richards at jboss.com  Tue Dec 26 12:32:48 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 12:32:48 -0500
Subject: [jboss-cvs] jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/test
	...
Message-ID: <E1GzGAS-0007Rx-Tp@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 12:32:48

  Modified:    examples/dvdstore/src/com/jboss/dvd/seam/test  
                        BestSellersTest.java StoreManagerTest.java
  Log:
  fix unit tests for big decimal
  
  Revision  Changes    Path
  1.5       +7 -8      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/test/BestSellersTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BestSellersTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/test/BestSellersTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- BestSellersTest.java	2 Nov 2006 01:09:41 -0000	1.4
  +++ BestSellersTest.java	26 Dec 2006 17:32:48 -0000	1.5
  @@ -5,6 +5,7 @@
   import static org.testng.AssertJUnit.assertNotNull;
   import static org.testng.AssertJUnit.assertTrue;
   
  +import java.math.BigDecimal;
   import java.util.List;
   
   import javax.faces.model.ListDataModel;
  @@ -47,9 +48,9 @@
   
                   // 14.98/29.99/39.95
   
  -                assertEquals("price 1", 14.98f, products.get(0).getPrice());
  -                assertEquals("price 2", 29.99f, products.get(1).getPrice());
  -                assertEquals("price 3", 39.95f, products.get(2).getPrice());
  +                assertEquals("price 1", new BigDecimal("14.98"), products.get(0).getPrice());
  +                assertEquals("price 2", new BigDecimal("29.99"), products.get(1).getPrice());
  +                assertEquals("price 3", new BigDecimal("39.95"), products.get(2).getPrice());
               }               
           }.run();
       }
  @@ -65,8 +66,6 @@
                   ListDataModel model = (ListDataModel) getInstance("topProducts");
                   model.setRowIndex(1);
   
  -                System.out.println("**** PRODUCT" + ((Product)model.getRowData()).getProductId());
  -
                   BestSellers best = (BestSellers) getInstance("bestsellers");
                   best.addToCart();
               }
  @@ -78,7 +77,7 @@
                   assertFalse("cart shouldn't be empty", 
                               cart.getIsEmpty());
                   assertEquals("cart size", 1, cart.getCart().size());
  -                assertEquals("cart total", 29.99f, cart.getSubtotal());
  +                assertEquals("cart total", new BigDecimal("29.99"), cart.getSubtotal());
   
               }
           }.run();
  @@ -100,7 +99,7 @@
                   assertFalse("cart shouldn't be empty", 
                               cart.getIsEmpty());
                   assertEquals("cart size", 2, cart.getCart().size());
  -                assertEquals("cart total", 69.94f, cart.getSubtotal());
  +                assertEquals("cart total", new BigDecimal("69.94"), cart.getSubtotal());
               }
           }.run();
   
  @@ -123,7 +122,7 @@
   
                   // still two items, but total increase
                   assertEquals("cart size", 2, cart.getCart().size());
  -                assertEquals("cart total", 99.93f, cart.getSubtotal());
  +                assertEquals("cart total", new BigDecimal("99.93"), cart.getSubtotal());
               }
           }.run();
           
  
  
  
  1.4       +3 -1      jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/test/StoreManagerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StoreManagerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/dvdstore/src/com/jboss/dvd/seam/test/StoreManagerTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- StoreManagerTest.java	2 Nov 2006 01:09:41 -0000	1.3
  +++ StoreManagerTest.java	26 Dec 2006 17:32:48 -0000	1.4
  @@ -2,6 +2,8 @@
   
   import static org.testng.AssertJUnit.assertEquals;
   
  +import java.math.BigDecimal;
  +
   import org.jboss.seam.mock.SeamTest;
   import org.testng.annotations.Test;
   
  @@ -27,7 +29,7 @@
               {
                   // these are from order instances - 
                   assertEquals("number orders",   0L,    manager.getNumberOrders());
  -                assertEquals("total sales",     0.0,   manager.getTotalSales());
  +                assertEquals("total sales",     BigDecimal.ZERO,   manager.getTotalSales());
   
                   // these are from inventory
                   assertEquals("units sold",      5734,  manager.getUnitsSold());
  
  
  


From norman.richards at jboss.com  Tue Dec 26 12:36:43 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 12:36:43 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/src/test  ...
Message-ID: <E1GzGEF-0007Wd-8Z@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 12:36:43

  Modified:    examples/blog/src/test  BlogTest.java
  Log:
  post action no longer returns view id
  
  Revision  Changes    Path
  1.13      +8 -8      jboss-seam/examples/blog/src/test/BlogTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BlogTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/src/test/BlogTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- BlogTest.java	26 Oct 2006 17:55:52 -0000	1.12
  +++ BlogTest.java	26 Dec 2006 17:36:43 -0000	1.13
  @@ -21,7 +21,6 @@
      @Test
      public void testPost() throws Exception
      {
  -      
         new FacesRequest("/post.xhtml")
         {
   
  @@ -37,7 +36,9 @@
            @Override
            protected void invokeApplication() throws Exception
            {
  -            assert invokeMethod("#{postAction.post}").equals("/index.xhtml");
  +            // post now returns void
  +            // assert invokeMethod("#{postAction.post}").equals("/index.xhtml");
  +            invokeMethod("#{postAction.post}");
               setOutcome("/index.xhtml");
            }
            
  @@ -165,5 +166,4 @@
      {
         return new SeamExtendedManagedPersistencePhaseListener();
      }
  -
   }
  
  
  


From norman.richards at jboss.com  Tue Dec 26 12:37:18 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 12:37:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/META-INF   ...
Message-ID: <E1GzGEo-0007X7-4b@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 12:37:18

  Modified:    examples/blog/resources/META-INF   application.xml
                        jboss-beans.xml
  Log:
  cleanup
  
  Revision  Changes    Path
  1.5       +27 -28    jboss-seam/examples/blog/resources/META-INF/application.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: application.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/META-INF/application.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- application.xml	5 Dec 2006 13:29:37 -0000	1.4
  +++ application.xml	26 Dec 2006 17:37:18 -0000	1.5
  @@ -24,5 +24,4 @@
       <module>
           <java>el-ri.jar</java>
       </module>
  -    
   </application>
  \ No newline at end of file
  
  
  
  1.2       +2 -2      jboss-seam/examples/blog/resources/META-INF/jboss-beans.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jboss-beans.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/META-INF/jboss-beans.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- jboss-beans.xml	16 Apr 2006 15:47:49 -0000	1.1
  +++ jboss-beans.xml	26 Dec 2006 17:37:18 -0000	1.2
  @@ -2,7 +2,7 @@
   
   <deployment xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
               xsi:schemaLocation="urn:jboss:bean-deployer bean-deployer_1_0.xsd"
  -            xmlns="urn:jboss:bean-deployer">
  +            xmlns="urn:jboss:bean-deployer:2.0">
   
      <bean name="blogDatasourceBootstrap" class="org.jboss.resource.adapter.jdbc.local.LocalTxDataSource">
         <property name="driverClass">org.hsqldb.jdbcDriver</property>
  
  
  


From norman.richards at jboss.com  Tue Dec 26 12:37:18 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 12:37:18 -0500
Subject: [jboss-cvs] jboss-seam/examples/blog/resources/WEB-INF  ...
Message-ID: <E1GzGEo-0007XE-7L@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 12:37:18

  Modified:    examples/blog/resources/WEB-INF  faces-config.xml
  Log:
  cleanup
  
  Revision  Changes    Path
  1.10      +17 -18    jboss-seam/examples/blog/resources/WEB-INF/faces-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: faces-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/blog/resources/WEB-INF/faces-config.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- faces-config.xml	4 Nov 2006 01:29:22 -0000	1.9
  +++ faces-config.xml	26 Dec 2006 17:37:18 -0000	1.10
  @@ -4,15 +4,14 @@
       "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
       
   <faces-config>
  -
       <!-- Facelets support -->
  -
       <application>
           <message-bundle>messages</message-bundle>
           <view-handler>org.jboss.seam.ui.facelet.SeamFaceletViewHandler</view-handler>
       </application>
       
       <!-- Select one of the two standard persistence lifecycle models for the Seam application -->

  -    <lifecycle>
        <phase-listener>org.jboss.seam.jsf.TransactionalSeamPhaseListener</phase-listener>
  +    <lifecycle>
  +        <phase-listener>org.jboss.seam.jsf.TransactionalSeamPhaseListener</phase-listener>
       </lifecycle>

   </faces-config>
  
  
  


From norman.richards at jboss.com  Tue Dec 26 12:39:41 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 12:39:41 -0500
Subject: [jboss-cvs] jboss-seam/src/test/misc/org/jboss/seam/test  ...
Message-ID: <E1GzGH7-0007YC-2q@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 12:39:41

  Modified:    src/test/misc/org/jboss/seam/test  PhaseListenerTest.java
  Log:
  add validator component to init
  
  Revision  Changes    Path
  1.30      +3 -1      jboss-seam/src/test/misc/org/jboss/seam/test/PhaseListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PhaseListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/test/misc/org/jboss/seam/test/PhaseListenerTest.java,v
  retrieving revision 1.29
  retrieving revision 1.30
  diff -u -b -r1.29 -r1.30
  --- PhaseListenerTest.java	21 Dec 2006 02:38:29 -0000	1.29
  +++ PhaseListenerTest.java	26 Dec 2006 17:39:41 -0000	1.30
  @@ -1,4 +1,4 @@
  -//$Id: PhaseListenerTest.java,v 1.29 2006/12/21 02:38:29 sbryzak2 Exp $
  +//$Id: PhaseListenerTest.java,v 1.30 2006/12/26 17:39:41 nrichards Exp $
   package org.jboss.seam.test;
   
   import java.util.ArrayList;
  @@ -25,6 +25,7 @@
   import org.jboss.seam.core.Init;
   import org.jboss.seam.core.Manager;
   import org.jboss.seam.core.Pages;
  +import org.jboss.seam.core.Validation;
   import org.jboss.seam.jsf.AbstractSeamPhaseListener;
   import org.jboss.seam.jsf.SeamPhaseListener;
   import org.jboss.seam.jsf.SeamStateManager;
  @@ -47,6 +48,7 @@
         installComponent(appContext, FacesMessages.class);
         installComponent(appContext, Pages.class);
         installComponent(appContext, Events.class);
  +      installComponent(appContext, Validation.class);
      }
      
      private void installComponent(Context appContext, Class clazz)
  
  
  


From norman.richards at jboss.com  Tue Dec 26 13:41:43 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Tue, 26 Dec 2006 13:41:43 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay ...
Message-ID: <E1GzHF9-00009X-MS@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/26 13:41:43

  Modified:    examples/seampay/src/org/jboss/seam/example/seampay 
                        Payment.java
  Log:
  remove testing property
  
  Revision  Changes    Path
  1.6       +0 -7      jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Payment.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Payment.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seampay/src/org/jboss/seam/example/seampay/Payment.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- Payment.java	17 Dec 2006 05:10:40 -0000	1.5
  +++ Payment.java	26 Dec 2006 18:41:43 -0000	1.6
  @@ -50,13 +50,6 @@
           this.amount = amount;
       }
   
  -    public BigInteger getTesting() {
  -        return testing;
  -    }
  -    public void setTesting(BigInteger testing) {
  -        this.testing = testing;
  -    }
  -    
       public String getPayee()
       {
           return payee;
  
  
  


From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:07:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:07:18 -0500
Subject: [jboss-cvs] JBossAS SVN: r59230 -
	projects/security/security-spi/trunk/src/main/org/jboss/security/mapping
Message-ID: <E1GzJW2-0002pT-41@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:07:17 -0500 (Tue, 26 Dec 2006)
New Revision: 59230

Modified:
   projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingContext.java
   projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingProvider.java
Log:
use generics

Modified: projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingContext.java
===================================================================
--- projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingContext.java	2006-12-26 10:46:20 UTC (rev 59229)
+++ projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingContext.java	2006-12-26 21:07:17 UTC (rev 59230)
@@ -26,17 +26,26 @@
    }
    
    /**
+    * Get the set of mapping modules
+    * @return
+    */
+   public List getModules()
+   {
+      return this.modules;
+   }
+   
+   /**
     * Apply mapping semantics on the passed object
     * @param obj Read-only Contextual Map
     * @param mappedObject an object on which mapping will be applied 
     */
-   public void performMapping(Map obj, Object mappedObject)
+   public <T> void performMapping(Map obj, T mappedObject)
    {
       int len = modules.size(); 
       
       for(int i = 0 ; i < len; i++)
       {
-         MappingProvider mp = (MappingProvider)modules.get(i);
+         MappingProvider<T> mp = (MappingProvider<T>)modules.get(i);
          mp.performMapping(obj, mappedObject);
       } 
    } 

Modified: projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingProvider.java
===================================================================
--- projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingProvider.java	2006-12-26 10:46:20 UTC (rev 59229)
+++ projects/security/security-spi/trunk/src/main/org/jboss/security/mapping/MappingProvider.java	2006-12-26 21:07:17 UTC (rev 59230)
@@ -12,9 +12,10 @@
  *  A provider with mapping functionality
  *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
  *  @version $Revision$
+ * @param <T>
  *  @since  Aug 24, 2006
  */
-public interface MappingProvider
+public interface MappingProvider<T>
 {
    /**
     * Initialize the provider with the configured module options
@@ -29,5 +30,5 @@
     * @throws IllegalArgumentException if the mappedObject is not understood by the 
     * provider.
     */
-   void performMapping(Map map, Object mappedObject);
+    void performMapping(Map map, T mappedObject);
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:07:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:07:44 -0500
Subject: [jboss-cvs] JBossAS SVN: r59231 -
	projects/security/security-spi/trunk/src/main/org/jboss/security/authorization
Message-ID: <E1GzJWS-0002pm-Tr@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:07:44 -0500 (Tue, 26 Dec 2006)
New Revision: 59231

Added:
   projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/ResourceType.java
Modified:
   projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/Resource.java
Log:
pull out resource types

Modified: projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/Resource.java
===================================================================
--- projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/Resource.java	2006-12-26 21:07:17 UTC (rev 59230)
+++ projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/Resource.java	2006-12-26 21:07:44 UTC (rev 59231)
@@ -32,14 +32,9 @@
  *  @version $Revision$
  */
 public interface Resource
-{
-   // Web Resource
-   String WEB = "web";
-   //EJB Resource
-   String EJB = "ejb";
-   
+{ 
    //Get the Layer (Web/EJB etc)
-   public String getLayer();
+   public ResourceType getLayer();
    
    //Return the contextual map
    public Map getMap(); 

Added: projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/ResourceType.java
===================================================================
--- projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/ResourceType.java	2006-12-26 21:07:17 UTC (rev 59230)
+++ projects/security/security-spi/trunk/src/main/org/jboss/security/authorization/ResourceType.java	2006-12-26 21:07:44 UTC (rev 59231)
@@ -0,0 +1,35 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2006, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.security.authorization;
+
+//$Id$
+
+/**
+ *  Type of Resource for Authorization
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 13, 2006 
+ *  @version $Revision$
+ */
+public enum ResourceType
+{
+   WEB,EJB;
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:08:08 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:08:08 -0500
Subject: [jboss-cvs] JBossAS SVN: r59232 -
	projects/security/security-spi/trunk/src/main/org/jboss/security
Message-ID: <E1GzJWq-0002q5-62@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:08:07 -0500 (Tue, 26 Dec 2006)
New Revision: 59232

Added:
   projects/security/security-spi/trunk/src/main/org/jboss/security/SubjectInfo.java
Modified:
   projects/security/security-spi/trunk/src/main/org/jboss/security/SecurityContext.java
Log:
refactor and pull out SubjectInfo

Modified: projects/security/security-spi/trunk/src/main/org/jboss/security/SecurityContext.java
===================================================================
--- projects/security/security-spi/trunk/src/main/org/jboss/security/SecurityContext.java	2006-12-26 21:07:44 UTC (rev 59231)
+++ projects/security/security-spi/trunk/src/main/org/jboss/security/SecurityContext.java	2006-12-26 21:08:07 UTC (rev 59232)
@@ -5,97 +5,53 @@
  * See terms of license at gnu.org.
  */ 
 package org.jboss.security;
-
-import java.security.Principal;
-import java.util.Map;
-
-import javax.security.auth.Subject;
  
+import java.util.Map; 
+ 
 import org.jboss.security.audit.SecurityAuditManager;
 import org.jboss.security.mapping.MappingContext;
  
 
 /**
- *  Encapsulation of Authentication, Authorization and Role information
+ *  Encapsulation of Authentication, Authorization, Mapping and other
+ *  security aspects at the level of a security domain
  *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
  *  @version $Revision$
  *  @since  Aug 24, 2006
  */
-public abstract class SecurityContext
-{/*
-   protected static final Logger log = Logger.getLogger(SecurityContext.class);
-   
-   protected boolean trace = log.isTraceEnabled(); 
-   */
+public interface SecurityContext
+{   
    /**
-    * A map of roles (as a Group) keyed in by securityDomain
+    * Authentication Manager for the security domain
     */
-  /* private ConcurrentHashMap rolesMap = new ConcurrentHashMap();*/
+   public AuthenticationManager getAuthenticationManager(); 
+   /**
+    * Authorization Manager for the security domain 
+    */
+   public AuthorizationManager getAuthorizationManager();
    
-   public class SubjectInfo
-   {
-      private Principal authenticationPrincipal;
-      private Object authenticationCredential;
-      private Subject authenticatedSubject;
-      
-      public Principal getAuthenticationPrincipal()
-      {
-         return authenticationPrincipal;
-      }
-      
-      public void setAuthenticationPrincipal(Principal authenticationPrincipal)
-      {
-         this.authenticationPrincipal = authenticationPrincipal;
-      }
-      
-      public Object getAuthenticationCredential()
-      {
-         return authenticationCredential;
-      }
-      
-      public void setAuthenticationCredential(Object authenticationCredential)
-      {
-         this.authenticationCredential = authenticationCredential;
-      }
-      
-      public Subject getAuthenticatedSubject()
-      {
-         return authenticatedSubject;
-      }
-      
-      public void setAuthenticatedSubject(Subject authenticatedSubject)
-      {
-         this.authenticatedSubject = authenticatedSubject;
-      } 
-   } 
+   /** 
+    * Mapping Context configured with providers
+    */
+   public MappingContext getMappingContext(Class mappingType);
    
-   public interface MappingKeyInfo
-   {
-      public final static String ROLE_MAPPING = "RoleMapping";
-      public final static String IDENTITY_MAPPING = "IdentityMapping";
-      public final static String CERTIFICATE_MAPPING = "CertMapping";
-   }
+   /**
+    * AuditContext configured for the security domain 
+    */
+   public SecurityAuditManager getAuditManager();
    
-   public abstract AuthenticationManager getAuthenticationManager();
-    
-   public abstract AuthorizationManager getAuthorizationManager();
-   
-   public abstract Map getData();
-   
    /**
-    * @see MappingKeyInfo
-    * @param Key Key of the form MappingKeyInfo
-    * @return A Mapping Context configured with providers
+    * Context Map 
     */
-   public abstract MappingContext getMappingContext(String Key);
+   public Map getData();
    
    /**
-    * Return the AuditContext configured for the security domain
-    * @return
+    * Return the Security Domain
     */
-   public abstract SecurityAuditManager getAuditManager();
+   public String getSecurityDomain();
    
-   public abstract String getSecurityDomain();
-   
-   public abstract SubjectInfo getSubjectInfo(); 
+   /**
+    * Subject Info
+    */
+   public SubjectInfo getSubjectInfo(); 
 }

Added: projects/security/security-spi/trunk/src/main/org/jboss/security/SubjectInfo.java
===================================================================
--- projects/security/security-spi/trunk/src/main/org/jboss/security/SubjectInfo.java	2006-12-26 21:07:44 UTC (rev 59231)
+++ projects/security/security-spi/trunk/src/main/org/jboss/security/SubjectInfo.java	2006-12-26 21:08:07 UTC (rev 59232)
@@ -0,0 +1,71 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2006, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.security;
+
+import java.security.Principal;
+
+import javax.security.auth.Subject;
+
+//$Id$
+
+/**
+ *  Holds information - principal, credential and subject
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 26, 2006 
+ *  @version $Revision$
+ */
+public class SubjectInfo
+{
+   private Principal authenticationPrincipal;
+   private Object authenticationCredential;
+   private Subject authenticatedSubject;
+   
+   public Principal getAuthenticationPrincipal()
+   {
+      return authenticationPrincipal;
+   }
+   
+   public void setAuthenticationPrincipal(Principal authenticationPrincipal)
+   {
+      this.authenticationPrincipal = authenticationPrincipal;
+   }
+   
+   public Object getAuthenticationCredential()
+   {
+      return authenticationCredential;
+   }
+   
+   public void setAuthenticationCredential(Object authenticationCredential)
+   {
+      this.authenticationCredential = authenticationCredential;
+   }
+   
+   public Subject getAuthenticatedSubject()
+   {
+      return authenticatedSubject;
+   }
+   
+   public void setAuthenticatedSubject(Subject authenticatedSubject)
+   {
+      this.authenticatedSubject = authenticatedSubject;
+   } 
+} 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:09:03 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:09:03 -0500
Subject: [jboss-cvs] JBossAS SVN: r59233 - in
	projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test:
	. securitycontext
Message-ID: <E1GzJXj-0002qQ-KS@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:09:02 -0500 (Tue, 26 Dec 2006)
New Revision: 59233

Added:
   projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/
   projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/MappingContextTestCase.java
   projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextBaseTest.java
   projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextTestCase.java
Log:
Security Context tests

Added: projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/MappingContextTestCase.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/MappingContextTestCase.java	2006-12-26 21:08:07 UTC (rev 59232)
+++ projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/MappingContextTestCase.java	2006-12-26 21:09:02 UTC (rev 59233)
@@ -0,0 +1,70 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.securitycontext; 
+
+import java.security.acl.Group;
+import java.util.HashMap;
+import java.util.HashSet;
+
+import org.jboss.security.SecurityConstants;
+import org.jboss.security.SecurityContext;
+import org.jboss.security.SimpleGroup;
+import org.jboss.security.SimplePrincipal;
+import org.jboss.security.config.SecurityConfiguration;
+import org.jboss.security.mapping.MappingContext;
+
+//$Id$
+
+/**
+ *  Test the various mapping providers
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 26, 2006 
+ *  @version $Revision$
+ */
+public class MappingContextTestCase extends SecurityContextBaseTest
+{ 
+   public void testDeploymentRolesProvider()
+   {
+      SecurityConfiguration.addApplicationPolicy(securityDomain,
+            createApplicationPolicy(securityDomain));
+      SecurityContext sc= getSC(securityDomain);
+      HashSet hs = new HashSet();
+      hs.add("t1");
+      hs.add("t2");
+      
+      HashMap rolesMap = new HashMap();
+      rolesMap.put(principal.getName(), hs );
+      
+      HashMap map = new HashMap();
+      map.put(SecurityConstants.PRINCIPAL_IDENTIFIER, principal);
+      map.put(SecurityConstants.DEPLOYMENT_PRINCIPAL_ROLES_MAP, rolesMap);
+      
+      Group grp = new SimpleGroup(SecurityConstants.ROLES_IDENTIFIER);
+      grp.addMember(new SimplePrincipal("oldRole"));
+      MappingContext mc = sc.getMappingContext(Group.class);
+      mc.performMapping(map, grp);
+      
+      assertFalse("oldRole does not exist", grp.isMember(new SimplePrincipal("oldRole")));
+      assertTrue("t1 exists?",grp.isMember(new SimplePrincipal("t1")));
+      assertTrue("t2 exists?",grp.isMember(new SimplePrincipal("t2")));
+   }
+}

Added: projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextBaseTest.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextBaseTest.java	2006-12-26 21:08:07 UTC (rev 59232)
+++ projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextBaseTest.java	2006-12-26 21:09:02 UTC (rev 59233)
@@ -0,0 +1,97 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.securitycontext;
+ 
+import java.security.Principal;
+import java.util.List;
+
+import org.jboss.security.SimplePrincipal;
+import org.jboss.security.Util;
+import org.jboss.security.config.ApplicationPolicy;
+import org.jboss.security.config.RoleMappingInfo;
+import org.jboss.security.config.SecurityConfiguration;
+import org.jboss.security.mapping.config.MappingModuleEntry;
+import org.jboss.security.plugins.JBossSecurityContext;
+
+import junit.framework.TestCase;
+
+//$Id$
+
+/**
+ *  Base test class with common methods
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 26, 2006 
+ *  @version $Revision$
+ */
+public class SecurityContextBaseTest extends TestCase
+{ 
+   protected Principal principal = new SimplePrincipal("anil");
+   protected Object cred = "hello";
+   protected String securityDomain = "other";
+   
+   private String mappingModule = "org.jboss.security.mapping.providers.DeploymentRolesMappingProvider";
+   
+   public void testSecurityConfiguration()
+   {
+      ApplicationPolicy ap = createApplicationPolicy(null);
+      SecurityConfiguration.addApplicationPolicy(securityDomain, ap);
+      assertEquals(Util.getApplicationPolicy(securityDomain), ap);
+   }
+   
+   protected JBossSecurityContext getSC(String domain)
+   {
+      if(domain == null)
+         domain = securityDomain;
+      return new JBossSecurityContext(securityDomain);
+   }
+   
+   protected ApplicationPolicy createApplicationPolicy(String domain)
+   {
+      ApplicationPolicy ap = new ApplicationPolicy(domain);
+      ap.setRoleMappingInfo(createRoleMappingInfo(domain));
+      return ap; 
+   }
+   
+   protected ApplicationPolicy createApplicationPolicy(String domain, RoleMappingInfo rmi)
+   {
+      ApplicationPolicy ap = new ApplicationPolicy(domain);
+      ap.setRoleMappingInfo(rmi);
+      return ap; 
+   }
+   
+   protected RoleMappingInfo createRoleMappingInfo(String domain)
+   { 
+      RoleMappingInfo rmi = new RoleMappingInfo(domain);
+      rmi.add(new MappingModuleEntry(this.mappingModule));
+      return rmi;
+   }
+   
+   protected RoleMappingInfo createRoleMappingInfo(String domain, List<String> moduleNames)
+   {
+      RoleMappingInfo rmi = new RoleMappingInfo(domain);
+      for(String mod:moduleNames)
+      { 
+         rmi.add(new MappingModuleEntry(mod));
+      }
+      return rmi;
+   }
+}

Added: projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextTestCase.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextTestCase.java	2006-12-26 21:08:07 UTC (rev 59232)
+++ projects/security/security-jboss-sx/trunk/src/tests/org/jboss/test/securitycontext/SecurityContextTestCase.java	2006-12-26 21:09:02 UTC (rev 59233)
@@ -0,0 +1,86 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.securitycontext;
+
+import java.security.acl.Group;
+import java.util.List;
+
+import javax.security.auth.Subject;
+
+import org.jboss.security.SubjectInfo;
+import org.jboss.security.config.SecurityConfiguration;
+import org.jboss.security.mapping.MappingContext;
+import org.jboss.security.mapping.providers.DeploymentRolesMappingProvider;
+import org.jboss.security.plugins.JBossSecurityContext;
+
+//$Id$
+
+/**
+ *  Test the Security Context
+ *  @author <a href="mailto:Anil.Saldhana at jboss.org">Anil Saldhana</a>
+ *  @since  Dec 26, 2006 
+ *  @version $Revision$
+ */
+public class SecurityContextTestCase extends SecurityContextBaseTest
+{
+   public void setUp()
+   { 
+      SecurityConfiguration.addApplicationPolicy(securityDomain, createApplicationPolicy(securityDomain));
+   }
+   
+   public void testSecurityDomain()
+   { 
+      assertEquals("Security Domain == other", getSC(securityDomain).getSecurityDomain()
+            ,securityDomain);
+   }
+   
+   public void testSubjectInfo()
+   {
+      Subject sub = new Subject();
+      SubjectInfo si = new SubjectInfo(); 
+      si.setAuthenticationPrincipal(principal);
+      si.setAuthenticationCredential(cred);
+      sub.getPrincipals().add(principal);
+      si.setAuthenticatedSubject(sub); 
+      
+      JBossSecurityContext sc = getSC(securityDomain);
+      sc.setSubjectInfo(si);
+      
+      assertEquals("SubjectInfo is equal",sc.getSubjectInfo(),si); 
+      assertEquals("Subject is equal",sc.getSubjectInfo().getAuthenticatedSubject(),sub);
+      assertEquals("Principal is equal",sc.getSubjectInfo().getAuthenticationPrincipal(),principal);
+      assertEquals("Credential is equal",sc.getSubjectInfo().getAuthenticationCredential(),cred);
+   } 
+   
+   public void testMappingContext()
+   {
+      JBossSecurityContext sc = getSC(securityDomain);
+      MappingContext mc = sc.getMappingContext(Group.class);
+      assertNotNull("Mapping Context is not null", mc); 
+      List modules = mc.getModules();
+      assertNotNull("Mapping modules not null", modules);
+      assertEquals("Module size == 1", modules.size(),1);
+      assertTrue("Deployment Roles Provider is present", 
+            modules.get(0) instanceof DeploymentRolesMappingProvider);
+   }
+   
+}



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:11:56 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:11:56 -0500
Subject: [jboss-cvs] JBossAS SVN: r59234 - in
	projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization:
	. modules
Message-ID: <E1GzJaW-0002vq-TV@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:11:55 -0500 (Tue, 26 Dec 2006)
New Revision: 59234

Modified:
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/AuthorizationContext.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/EJBResource.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/AbstractAuthorizationModule.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/DelegatingAuthorizationModule.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/JACCAuthorizationModule.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/XACMLAuthorizationModule.java
Log:
use of ResourceType

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/AuthorizationContext.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/AuthorizationContext.java	2006-12-26 21:09:02 UTC (rev 59233)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/AuthorizationContext.java	2006-12-26 21:11:55 UTC (rev 59234)
@@ -291,7 +291,7 @@
    
    private AuthorizationInfo getAuthorizationInfo(String domainName, Resource resource)
    {
-      String layer = resource.getLayer();
+      ResourceType layer = resource.getLayer();
       
       //Check if an instance of ApplicationPolicy is available 
       if(this.applicationPolicy != null)
@@ -304,10 +304,10 @@
          if(trace)
             log.trace("Application Policy not obtained for domain="+ domainName +
                          ". Trying to obtain the App policy for the default domain of the layer:");
-         if(Resource.EJB.equals(layer))
+         if(layer == ResourceType.EJB)
             aPolicy = Util.getApplicationPolicy(SecurityConstants.DEFAULT_EJB_APPLICATION_POLICY); 
          else
-            if(Resource.WEB.equals(layer))
+            if(layer == ResourceType.WEB)
                aPolicy = Util.getApplicationPolicy(SecurityConstants.DEFAULT_WEB_APPLICATION_POLICY); 
       }
       if(aPolicy == null)

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/EJBResource.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/EJBResource.java	2006-12-26 21:09:02 UTC (rev 59233)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/EJBResource.java	2006-12-26 21:11:55 UTC (rev 59234)
@@ -49,9 +49,9 @@
    /**
     * @see Resource#getLayer()
     */
-   public String getLayer()
+   public ResourceType getLayer()
    {
-      return Resource.EJB;
+      return ResourceType.EJB;
    }
 
    /**

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/AbstractAuthorizationModule.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/AbstractAuthorizationModule.java	2006-12-26 21:09:02 UTC (rev 59233)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/AbstractAuthorizationModule.java	2006-12-26 21:11:55 UTC (rev 59234)
@@ -33,6 +33,7 @@
 import org.jboss.security.authorization.AuthorizationException;
 import org.jboss.security.authorization.AuthorizationModule;
 import org.jboss.security.authorization.Resource;
+import org.jboss.security.authorization.ResourceType;
 
 //$Id$
 
@@ -125,7 +126,7 @@
    {
       int authorizationDecision = AuthorizationContext.DENY;
 
-      String layer = resource.getLayer();
+      ResourceType layer = resource.getLayer();
       String delegateStr = (String)delegateMap.get(layer);
       if(delegateStr == null)
          throw new IllegalStateException("Delegate is missing for layer="+layer);

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/DelegatingAuthorizationModule.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/DelegatingAuthorizationModule.java	2006-12-26 21:09:02 UTC (rev 59233)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/DelegatingAuthorizationModule.java	2006-12-26 21:11:55 UTC (rev 59234)
@@ -23,6 +23,7 @@
 
 import org.jboss.logging.Logger;
 import org.jboss.security.authorization.Resource;
+import org.jboss.security.authorization.ResourceType;
 
 //$Id$
 
@@ -38,9 +39,9 @@
    public DelegatingAuthorizationModule()
    { 
       log = Logger.getLogger(getClass());
-      delegateMap.put(Resource.WEB,
+      delegateMap.put(ResourceType.WEB,
           "org.jboss.web.tomcat.security.authorization.delegates.WebPolicyModuleDelegate");
-      delegateMap.put(Resource.EJB,
+      delegateMap.put(ResourceType.EJB,
          "org.jboss.security.authorization.modules.ejb.EJBPolicyModuleDelegate");
    }
 

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/JACCAuthorizationModule.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/JACCAuthorizationModule.java	2006-12-26 21:09:02 UTC (rev 59233)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/JACCAuthorizationModule.java	2006-12-26 21:11:55 UTC (rev 59234)
@@ -23,6 +23,7 @@
   
 import org.jboss.logging.Logger; 
 import org.jboss.security.authorization.Resource;
+import org.jboss.security.authorization.ResourceType;
 
 //$Id$
 
@@ -37,9 +38,9 @@
    public JACCAuthorizationModule()
    { 
       log = Logger.getLogger(getClass());
-      delegateMap.put(Resource.WEB,
+      delegateMap.put(ResourceType.WEB,
           "org.jboss.web.tomcat.security.authorization.delegates.WebJACCPolicyModuleDelegate");
-      delegateMap.put(Resource.EJB,
+      delegateMap.put(ResourceType.EJB,
          "org.jboss.security.authorization.modules.ejb.EJBJACCPolicyModuleDelegate");
    }
 

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/XACMLAuthorizationModule.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/XACMLAuthorizationModule.java	2006-12-26 21:09:02 UTC (rev 59233)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/authorization/modules/XACMLAuthorizationModule.java	2006-12-26 21:11:55 UTC (rev 59234)
@@ -24,6 +24,7 @@
 import org.jboss.logging.Logger; 
 import org.jboss.security.authorization.AuthorizationModule;
 import org.jboss.security.authorization.Resource; 
+import org.jboss.security.authorization.ResourceType;
 
 //$Id$
 
@@ -40,9 +41,9 @@
    public XACMLAuthorizationModule()
    {
       log = Logger.getLogger(getClass());
-      delegateMap.put(Resource.WEB,
+      delegateMap.put(ResourceType.WEB,
           "org.jboss.web.tomcat.security.authorization.delegates.WebXACMLPolicyModuleDelegate");
-      delegateMap.put(Resource.EJB,
+      delegateMap.put(ResourceType.EJB,
       "org.jboss.security.authorization.modules.ejb.EJBXACMLPolicyModuleDelegate");
    }  
 



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:12:29 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:12:29 -0500
Subject: [jboss-cvs] JBossAS SVN: r59235 -
	projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/jacc
Message-ID: <E1GzJb3-0002wO-1d@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:12:28 -0500 (Tue, 26 Dec 2006)
New Revision: 59235

Modified:
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/jacc/JBossPolicyConfigurationFactory.java
Log:
use the exception in the ctr

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/jacc/JBossPolicyConfigurationFactory.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/jacc/JBossPolicyConfigurationFactory.java	2006-12-26 21:11:55 UTC (rev 59234)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/jacc/JBossPolicyConfigurationFactory.java	2006-12-26 21:12:28 UTC (rev 59235)
@@ -59,7 +59,7 @@
       }
       catch(Exception e)
       {
-         IllegalStateException ex = new IllegalStateException("Failed to parse jacc-policy-config-states.xml");
+         IllegalStateException ex = new IllegalStateException("Failed to parse jacc-policy-config-states.xml",e);
          ex.initCause(e);
          throw ex;
       }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:13:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:13:36 -0500
Subject: [jboss-cvs] JBossAS SVN: r59236 -
	projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins
Message-ID: <E1GzJc8-0002wh-VP@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:13:36 -0500 (Tue, 26 Dec 2006)
New Revision: 59236

Modified:
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossAuthorizationManager.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossSecurityContext.java
Log:
security context changes

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossAuthorizationManager.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossAuthorizationManager.java	2006-12-26 21:12:28 UTC (rev 59235)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossAuthorizationManager.java	2006-12-26 21:13:36 UTC (rev 59236)
@@ -321,7 +321,7 @@
        */
       if(subjectRoles != userRoles || emptyContextRoles)
       {
-         MappingContext mc = sc.getMappingContext(SecurityContext.MappingKeyInfo.ROLE_MAPPING);
+         MappingContext mc = sc.getMappingContext(Group.class);
          if(mc != null)
          {
             Map contextMap = new HashMap();

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossSecurityContext.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossSecurityContext.java	2006-12-26 21:12:28 UTC (rev 59235)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/plugins/JBossSecurityContext.java	2006-12-26 21:13:36 UTC (rev 59236)
@@ -18,6 +18,7 @@
 import org.jboss.security.AuthorizationManager;
 import org.jboss.security.SecurityConstants;
 import org.jboss.security.SecurityContext;  
+import org.jboss.security.SubjectInfo;
 import org.jboss.security.Util; 
 import org.jboss.security.audit.AuditManager;
 import org.jboss.security.audit.SecurityAuditManager;
@@ -33,7 +34,7 @@
  *  @version $Revision$
  *  @since  Aug 30, 2006
  */
-public class JBossSecurityContext extends SecurityContext
+public class JBossSecurityContext implements SecurityContext
 { 
    protected static final Logger log = Logger.getLogger(JBossSecurityContext.class); 
    protected boolean trace = log.isTraceEnabled();  
@@ -100,7 +101,7 @@
    /**
     * @see SecurityContext#getMappingContext(String)
     */
-   public MappingContext getMappingContext(String key)
+   public MappingContext getMappingContext(Class mappingType)
    { 
       //Apply Mapping Logic  
       ApplicationPolicy aPolicy = Util.getApplicationPolicy(securityDomain);
@@ -118,7 +119,7 @@
                + securityDomain);
       MappingInfo rmi = null;
       MappingContext mc = null;
-      if(MappingKeyInfo.ROLE_MAPPING.equals(key))
+      if(mappingType == Group.class)
       {
          rmi = aPolicy.getRoleMappingInfo();
          if(rmi != null)



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:14:35 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:14:35 -0500
Subject: [jboss-cvs] JBossAS SVN: r59237 -
	projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers
Message-ID: <E1GzJd5-0002x0-0n@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:14:33 -0500 (Tue, 26 Dec 2006)
New Revision: 59237

Modified:
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/DeploymentRolesMappingProvider.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/OptionsRoleMappingProvider.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PolicyContextIdRoleMappingProvider.java
   projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PrincipalToRoleMappingProvider.java
Log:
changes made to the perform mapping method

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/DeploymentRolesMappingProvider.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/DeploymentRolesMappingProvider.java	2006-12-26 21:13:36 UTC (rev 59236)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/DeploymentRolesMappingProvider.java	2006-12-26 21:14:33 UTC (rev 59237)
@@ -43,7 +43,7 @@
  *  @since  Nov 1, 2006 
  *  @version $Revision$
  */
-public class DeploymentRolesMappingProvider implements MappingProvider
+public class DeploymentRolesMappingProvider implements MappingProvider<Group>
 {
    private static Logger log = Logger.getLogger(DeploymentRolesMappingProvider.class);
    private boolean trace = log.isTraceEnabled();
@@ -56,14 +56,12 @@
     * Obtains the deployment roles via the context map and applies it
     * on the mappedObject
     * @see MappingProvider#performMapping(Map, Object)
-    */
-   public void performMapping(Map map, Object mappedObject)
+    */ 
+   public void performMapping(Map map, Group mappedObject)
    {  
       if(map == null || map.isEmpty())
          throw new IllegalArgumentException("Context Map is null or empty");
-      if(mappedObject instanceof Group == false)
-         throw new IllegalArgumentException("mapped Object is not an instance of java.security.acl.Group");
-      
+    
       //Obtain the principal to roles mapping
       Principal principal = (Principal) map.get(SecurityConstants.PRINCIPAL_IDENTIFIER);
       Map principalRolesMap = (Map)map.get(SecurityConstants.DEPLOYMENT_PRINCIPAL_ROLES_MAP);
@@ -71,7 +69,7 @@
          log.trace("Principal="+principal+":principalRolesMap="+principalRolesMap);
       
       if(principal == null || principalRolesMap == null || principalRolesMap.isEmpty())
-         return; // No Mapping
+         return ; // No Mapping
       
       Set roleset = (Set)principalRolesMap.get(principal.getName());
       if(roleset != null)
@@ -81,30 +79,30 @@
          while(iter.hasNext())
          {
             String rolename = (String)iter.next();
-            newRoles.addMember(createNewPrincipal((Group) mappedObject,rolename));
+            newRoles.addMember(createNewPrincipal(mappedObject,rolename));
          }
-         mappedObject = MappingProviderUtil.replacePrincipals((Group) mappedObject, newRoles);  
-      }  
+         mappedObject = MappingProviderUtil.replacePrincipals(mappedObject, newRoles);  
+      } 
    } 
    
    /**
     * Need to maintain the Principal type from the original group
-    * @param grp
+    * @param mappedObject
     * @param name
     * @return
     */
-   private Principal createNewPrincipal(Group grp, String name)
+   private Principal createNewPrincipal(Group mappedObject, String name)
    {
       Principal p = new SimplePrincipal(name);
       
       //If the original group had a different principal than simpleprincipal
-      if(grp.members().hasMoreElements())
+      if(mappedObject.members().hasMoreElements())
       {
-         Principal origp = grp.members().nextElement();
+         Principal origp = mappedObject.members().nextElement();
          p = MappingProviderUtil.instantiatePrincipal(origp.getClass(), name);
          if(p == null) 
             p = new SimplePrincipal(name); 
       }
       return p;
-   }
+   } 
 }

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/OptionsRoleMappingProvider.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/OptionsRoleMappingProvider.java	2006-12-26 21:13:36 UTC (rev 59236)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/OptionsRoleMappingProvider.java	2006-12-26 21:14:33 UTC (rev 59237)
@@ -25,7 +25,7 @@
  *  @version $Revision$
  *  @since  Aug 24, 2006
  */
-public class OptionsRoleMappingProvider implements MappingProvider
+public class OptionsRoleMappingProvider implements MappingProvider<Group> 
 {
    private static final Logger log = Logger.getLogger(OptionsRoleMappingProvider.class);
    
@@ -58,17 +58,13 @@
      } 
    }
 
-   public void performMapping(Map contextMap, Object mappedObject)
+   public void performMapping(Map contextMap, Group mappedObject)
    { 
       ArrayList<Principal> removeMembers = new ArrayList<Principal>();
-      ArrayList<Principal> addMembers = new ArrayList<Principal>();
+      ArrayList<Principal> addMembers = new ArrayList<Principal>(); 
 
-      Group roles = (Group)contextMap.get(SecurityConstants.ROLES_IDENTIFIER);
-      if(roles == null)
-         throw new IllegalArgumentException("Group called Roles not found");
-
       //Enumerate over the members
-      Enumeration enumer = roles.members();
+      Enumeration enumer = mappedObject.members();
       while(enumer.hasMoreElements())
       {
          Principal p = (Principal)enumer.nextElement();
@@ -89,14 +85,13 @@
       //Go through  the remove list
       for(Principal p:removeMembers)
       {
-         roles.removeMember(p);
+         mappedObject.removeMember(p);
       }
       //Go through the add list
       for(Principal p:addMembers)
       {
-         roles.addMember(p);
+         mappedObject.addMember(p);
       }
-
-      mappedObject = roles; 
+ 
    }   
 }

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PolicyContextIdRoleMappingProvider.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PolicyContextIdRoleMappingProvider.java	2006-12-26 21:13:36 UTC (rev 59236)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PolicyContextIdRoleMappingProvider.java	2006-12-26 21:14:33 UTC (rev 59237)
@@ -45,7 +45,7 @@
  *  @since  Oct 10, 2006 
  *  @version $Revision$
  */
-public class PolicyContextIdRoleMappingProvider implements MappingProvider
+public class PolicyContextIdRoleMappingProvider implements MappingProvider<Group>
 { 
    private static Logger log = Logger.getLogger(PolicyContextIdRoleMappingProvider.class);
    private boolean trace = log.isTraceEnabled();
@@ -85,14 +85,10 @@
       }
    }
 
-   public void performMapping(Map contextMap, Object mappedObject)
+   public void performMapping(Map contextMap, Group mappedObject)
    { 
-      ArrayList <Principal> tempPrincipalList = new ArrayList<Principal>();
+      ArrayList <Principal> tempPrincipalList = new ArrayList<Principal>(); 
       
-      Group roles = (Group)contextMap.get(SecurityConstants.ROLES_IDENTIFIER);
-      if(roles == null)
-         throw new IllegalArgumentException("Group called Roles not found");
-      
       Principal principal = null;
       Set<Principal> principals = (Set)contextMap.get(SecurityConstants.PRINCIPALS_SET_IDENTIFIER);
       for(Principal p:principals)
@@ -125,7 +121,7 @@
               addRoles = MappingProviderUtil.getRolesFromCommaSeparatedString(rolesToAdd); 
            
            //Create a temp list of principals stored in the role group
-           Enumeration<? extends Principal> groupMembers = roles.members();
+           Enumeration<? extends Principal> groupMembers = mappedObject.members();
            while(groupMembers.hasMoreElements())
            {
               tempPrincipalList.add(groupMembers.nextElement());
@@ -134,19 +130,18 @@
            //Remove all the previous roles from the Group
            for(Principal p:tempPrincipalList)
            {
-              roles.removeMember(p);
+              mappedObject.removeMember(p);
            }
            
            //Now add the new roles to the group
-           MappingProviderUtil.addRoles(roles, addRoles);
+           MappingProviderUtil.addRoles(mappedObject, addRoles);
         }
         catch (IOException e)
         {
            if(trace)
               log.trace("Exception:",e);
         }
-      } 
-      mappedObject = roles;
+      }   
    } 
    
    private Properties loadProperties(String filename) throws IOException

Modified: projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PrincipalToRoleMappingProvider.java
===================================================================
--- projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PrincipalToRoleMappingProvider.java	2006-12-26 21:13:36 UTC (rev 59236)
+++ projects/security/security-jboss-sx/trunk/src/main/org/jboss/security/mapping/providers/PrincipalToRoleMappingProvider.java	2006-12-26 21:14:33 UTC (rev 59237)
@@ -38,7 +38,7 @@
  *  @version $Revision$
  *  @since  Sep 27, 2006
  */
-public class PrincipalToRoleMappingProvider implements MappingProvider
+public class PrincipalToRoleMappingProvider implements MappingProvider<Group>
 {
    private static final Logger log = Logger.getLogger(PrincipalToRoleMappingProvider.class);
 
@@ -63,12 +63,8 @@
       } 
    }
 
-   public void performMapping(Map contextMap, Object mappedObject)
-   {  
-      Group roles = (Group)contextMap.get(SecurityConstants.ROLES_IDENTIFIER);
-      if(roles == null)
-         throw new IllegalArgumentException("Group called Roles not found");
-
+   public void performMapping(Map contextMap, Group mappedObject)
+   { 
       Set<Principal> principals = (Set<Principal>) contextMap.get(SecurityConstants.PRINCIPALS_SET_IDENTIFIER);
       for(Principal p:principals)
       {
@@ -83,9 +79,8 @@
          int len = tokens != null ? tokens.length : 0;
          for(int i = 0; i < len; i++)
          {
-            roles.addMember(MappingProviderUtil.instantiatePrincipal(p.getClass(),tokens[i]));
+            mappedObject.addMember(MappingProviderUtil.instantiatePrincipal(p.getClass(),tokens[i]));
          }
-      } 
-      mappedObject = roles;
+      }   
    }  
 }



From jboss-cvs-commits at lists.jboss.org  Tue Dec 26 16:15:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Tue, 26 Dec 2006 16:15:12 -0500
Subject: [jboss-cvs] JBossAS SVN: r59238 -
	projects/security/security-jboss-sx/trunk
Message-ID: <E1GzJdg-0002yP-LS@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-26 16:15:11 -0500 (Tue, 26 Dec 2006)
New Revision: 59238

Modified:
   projects/security/security-jboss-sx/trunk/pom.xml
Log:
support unit tests as well as site generation to see the test report in html

Modified: projects/security/security-jboss-sx/trunk/pom.xml
===================================================================
--- projects/security/security-jboss-sx/trunk/pom.xml	2006-12-26 21:14:33 UTC (rev 59237)
+++ projects/security/security-jboss-sx/trunk/pom.xml	2006-12-26 21:15:11 UTC (rev 59238)
@@ -64,8 +64,15 @@
        </pluginRepositories>
        <build>
            <sourceDirectory>src/main</sourceDirectory>
+           <testSourceDirectory>src/tests</testSourceDirectory>
+           <testOutputDirectory>target/test-classes</testOutputDirectory>
            <finalName>${artifactId}</finalName>
            <outputDirectory>output/classes</outputDirectory> 
+           <testResources>
+             <testResource>
+               <directory>src/tests/org/jboss/test</directory>
+             </testResource>
+           </testResources>
            <plugins>
            <!-- define how we want compilation to take place here, we accept most of the defaults but say that we want the optimization flag set, and define the source and target to be 1.4, these setting will be inherited by child projects -->
               <plugin>
@@ -253,6 +260,14 @@
          </plugin>
       </plugins>
    </build>
+   <reporting>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-surefire-report-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </reporting>
    <dependencies>
       <dependency>
          <groupId>jboss</groupId>



From Shane_Bryzak at symantec.com  Wed Dec 27 00:03:49 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 27 Dec 2006 00:03:49 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1GzQxB-0002rM-DP@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/27 00:03:49

  Modified:    src/main/org/jboss/seam/security/config 
                        SecurityConfiguration.java
  Log:
  changed members to memberships for roles
  
  Revision  Changes    Path
  1.7       +3 -3      jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- SecurityConfiguration.java	16 Dec 2006 02:58:12 -0000	1.6
  +++ SecurityConfiguration.java	27 Dec 2006 05:03:49 -0000	1.7
  @@ -62,7 +62,7 @@
     // roles
     private static final String SECURITY_ROLES = "roles";
     private static final String SECURITY_ROLE = "role";
  -  private static final String SECURITY_MEMBERS = "members";
  +  private static final String SECURITY_MEMBERSHIPS = "memberships";
     private static final String SECURITY_PERMISSIONS = "permissions";
     private static final String SECURITY_PERMISSION = "permission";
   
  @@ -175,7 +175,7 @@
      * @param elements List
      * @throws SecurityConfigurationException
      */
  -  private void loadSecurityConstraints(List elements)
  +  protected void loadSecurityConstraints(List elements)
         throws SecurityConfigException
     {
       try
  @@ -291,7 +291,7 @@
         Set<String> mbrs = new HashSet<String>();
         members.put(r.getName(), mbrs);
   
  -      Element m = role.element(SECURITY_MEMBERS);
  +      Element m = role.element(SECURITY_MEMBERSHIPS);
         if (m != null)
         {
           for (String member : m.getTextTrim().split("[,]"))
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 00:44:15 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 00:44:15 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1GzRaJ-0003Qv-0j@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 00:44:15

  Modified:    src/main/org/jboss/remoting  ServerInvoker.java
  Log:
  JBREM-650:  Made started and handleInternalInvocation() protected.
  
  Revision  Changes    Path
  1.55      +4 -4      JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java,v
  retrieving revision 1.54
  retrieving revision 1.55
  diff -u -b -r1.54 -r1.55
  --- ServerInvoker.java	9 Nov 2006 21:35:23 -0000	1.54
  +++ ServerInvoker.java	27 Dec 2006 05:44:14 -0000	1.55
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.54 $
  + * @version $Revision: 1.55 $
    */
   public abstract class ServerInvoker extends AbstractInvoker implements ServerInvokerMBean
   {
  @@ -162,7 +162,7 @@
      protected Map handlers = new HashMap();
      protected Map callbackHandlers = new HashMap();
      protected Map clientCallbackListener = new HashMap();
  -   private boolean started = false;
  +   protected boolean started = false;
      private boolean created = false;
   
      private MBeanServer mbeanServer = null;
  @@ -1155,7 +1155,7 @@
       * @return
       * @throws Throwable
       */
  -   private Object handleInternalInvocation(InternalInvocation param,
  +   protected Object handleInternalInvocation(InternalInvocation param,
                                              InvocationRequest invocation,
                                              ServerInvocationHandler handler)
            throws Throwable
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 00:45:50 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 00:45:50 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting/callback  ...
Message-ID: <E1GzRbq-0003Tf-OO@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 00:45:50

  Modified:    src/main/org/jboss/remoting/callback 
                        ServerInvokerCallbackHandler.java
  Log:
  JBREM-650: Add metadata to configuration map when creating callback Client.
  
  Revision  Changes    Path
  1.20      +1 -0      JBossRemoting/src/main/org/jboss/remoting/callback/ServerInvokerCallbackHandler.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvokerCallbackHandler.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/callback/ServerInvokerCallbackHandler.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- ServerInvokerCallbackHandler.java	28 Nov 2006 17:39:28 -0000	1.19
  +++ ServerInvokerCallbackHandler.java	27 Dec 2006 05:45:50 -0000	1.20
  @@ -154,6 +154,7 @@
            if(owner.getConfiguration() != null)
            {
               clientConfig.putAll(owner.getConfiguration());
  +            clientConfig.putAll(metadata);
            }
            // need to configure callback client with ssl config if one exists for server
            configureSocketFactory(clientConfig, owner);
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 00:56:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 00:56:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/socket ...
Message-ID: <E1GzRmT-0003dd-0X@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 00:56:49

  Modified:    src/main/org/jboss/remoting/transport/socket 
                        SocketServerInvoker.java
  Log:
  JBREM-650: Made MAX_POOLSIZE_DEFAULT and serverSocketClass protected.
  
  Revision  Changes    Path
  1.33      +8 -8      JBossRemoting/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- SocketServerInvoker.java	3 Nov 2006 19:04:40 -0000	1.32
  +++ SocketServerInvoker.java	27 Dec 2006 05:56:48 -0000	1.33
  @@ -45,7 +45,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.32 $
  + * @version $Revision: 1.33 $
    * @jmx:mbean
    */
   public class SocketServerInvoker extends ServerInvoker implements Runnable, SocketServerInvokerMBean
  @@ -57,7 +57,7 @@
      private Properties props = new Properties();
   
      private static int BACKLOG_DEFAULT = 200;
  -   private static int MAX_POOL_SIZE_DEFAULT = 300;
  +   protected static int MAX_POOL_SIZE_DEFAULT = 300;
   
      /**
       * Key for indicating if socket invoker should continue to keep socket connection between
  @@ -70,7 +70,7 @@
       * Specifies the fully qualified class name for the custom SocketWrapper implementation to use on the server.
       */
      public static final String SERVER_SOCKET_CLASS_FLAG = "serverSocketClass";
  -   private String serverSocketClass = ServerSocketWrapper.class.getName();
  +   protected String serverSocketClass = ServerSocketWrapper.class.getName();
   
      protected ServerSocket serverSocket = null;
      protected boolean running = false;
  @@ -693,7 +693,7 @@
            {
               Set svrThreads = clientpool.getContents();
               svrThreadArray = svrThreads.toArray();
  -}
  +         }
            if(trace)
            {
               if(svrThreadArray != null)
  @@ -749,7 +749,7 @@
               if(svrThreadArray != null)
               {
                  log.trace("Number of ServerThread in thead pool = " + svrThreadArray.length);
  -}
  +            }
            }
   
            if(svrThreadArray != null)
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 00:58:10 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 00:58:10 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1GzRnm-0003fJ-Bo@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 00:58:10

  Added:       src/main/org/jboss/remoting/transport/bisocket      
                        Bisocket.java BisocketServerInvoker.java
                        TransportClientFactory.java
                        BisocketClientInvoker.java
                        TransportServerFactory.java
                        BisocketServerThread.java
  Log:
  JBREM-650:  Added bisocket transport.
  
  Revision  Changes    Path
  1.2       +43 -0     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/Bisocket.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Bisocket.java
  ===================================================================
  RCS file: Bisocket.java
  diff -N Bisocket.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ Bisocket.java	27 Dec 2006 05:58:10 -0000	1.2
  @@ -0,0 +1,43 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 22, 2006
  + * </p>
  + */
  +public class Bisocket
  +{
  +   public static final String GET_SECONDARY_INVOKER_LOCATOR = "getSecondaryInvokerLocator";
  +
  +   public static final String IS_CALLBACK_SERVER = "isCallbackServer";
  +   
  +   public static final byte PING                   = 1;
  +   public static final byte CREATE_CONTROL_SOCKET  = 2;
  +   public static final byte CREATE_ORDINARY_SOCKET = 3;
  +   
  +   public static final String PING_FREQUENCY = "pingFrequency";
  +   public static final int PING_FREQUENCY_DEFAULT = 5000;
  +}
  
  
  
  1.2       +621 -0    JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketServerInvoker.java
  ===================================================================
  RCS file: BisocketServerInvoker.java
  diff -N BisocketServerInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketServerInvoker.java	27 Dec 2006 05:58:10 -0000	1.2
  @@ -0,0 +1,621 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +import java.io.DataInputStream;
  +import java.io.DataOutputStream;
  +import java.io.IOException;
  +import java.net.InetAddress;
  +import java.net.ServerSocket;
  +import java.net.Socket;
  +import java.util.Collection;
  +import java.util.Collections;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.LinkedList;
  +import java.util.Map;
  +import java.util.TimerTask;
  +
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.invocation.InternalInvocation;
  +import org.jboss.remoting.transport.PortUtil;
  +import org.jboss.remoting.transport.socket.LRUPool;
  +import org.jboss.remoting.transport.socket.ServerThread;
  +import org.jboss.remoting.transport.socket.SocketServerInvoker;
  +import org.jboss.remoting.util.TimerUtil;
  +
  +
  +/**
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 23, 2006
  + * </p>
  + */
  +public class BisocketServerInvoker extends SocketServerInvoker
  +{  
  +   private static Map listenerIdToServerInvokerMap = Collections.synchronizedMap(new HashMap());
  +
  +   private Map listenerIdToInvokerLocatorMap = new HashMap();
  +   private ServerSocket secondaryServerSocket;
  +   private InvokerLocator secondaryLocator;
  +   private SecondaryServerSocketThread secondaryServerSocketThread;
  +   private Map controlConnectionThreadMap = new HashMap();
  +   private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;
  +   private int pingWindow = 2 * pingFrequency;
  +   private ControlMonitorTimerTask controlMonitorTimerTask;
  +   protected boolean isCallbackServer = false;
  +   
  +   
  +   public static BisocketServerInvoker getBisocketServerInvoker(String listenerId)
  +   {
  +      return (BisocketServerInvoker) listenerIdToServerInvokerMap.get(listenerId);
  +   }
  +   
  +   
  +//   public static void addBisocketServerInvoker(String listenerId, BisocketServerInvoker invoker)
  +//   {
  +//      listenerIdToServerInvokerMap.put(listenerId, invoker);
  +//   }
  +   
  +   
  +   public BisocketServerInvoker(InvokerLocator locator)
  +   {
  +      super(locator);
  +   }
  +
  +   
  +   public BisocketServerInvoker(InvokerLocator locator, Map configuration)
  +   {
  +      super(locator, configuration);
  +   }
  +   
  +   
  +   public void start() throws IOException
  +   {  
  +      if (isCallbackServer)
  +      {
  +         if(maxPoolSize <= 0)
  +         {
  +            maxPoolSize = MAX_POOL_SIZE_DEFAULT;
  +         }
  +         clientpool = new LRUPool(2, maxPoolSize);
  +         clientpool.create();
  +         threadpool = new LinkedList();
  +         running = true;
  +         started = true;
  +      }
  +      else
  +      {
  +         super.start();
  +         InetAddress host = getServerSocket().getInetAddress();
  +         int freePort = PortUtil.findFreePort(host.getHostAddress());
  +         if (serverSocketFactory != null)
  +         {
  +            secondaryServerSocket = serverSocketFactory.createServerSocket(freePort, 0, host);
  +         }
  +         else
  +         {
  +            secondaryServerSocket = new ServerSocket(freePort, 0, host);  
  +         }
  +         secondaryLocator = new InvokerLocator(null, host.getHostAddress(), freePort, null, null); 
  +         secondaryServerSocketThread = new SecondaryServerSocketThread(secondaryServerSocket);
  +         secondaryServerSocketThread.setName("secondaryServerSocketThread");
  +         secondaryServerSocketThread.setDaemon(true);
  +         secondaryServerSocketThread.start();
  +         log.info("started secondary port: " + host + ":" + freePort);
  +      }
  +      log.info("started: " + this);
  +//    ServerInvocationHandler handler = new InternalInvocationHandler(secondaryServerSocket);
  +//    addInvocationHandler(Bisocket.BISOCKET_INTERNAL_SUBSYSTEM, handler);
  +   }
  +   
  +   
  +   public boolean isTransportBiDirectional()
  +   {
  +      return true;
  +   }
  +   
  +   
  +   public void createControlConnection(String listenerId, InvokerLocator locator)
  +   throws IOException
  +   {
  +      boolean firstConnection;
  +      
  +      // first connection
  +      if (locator == null)
  +      {
  +         firstConnection = false;
  +         locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +      }
  +      // restarted connection
  +      else
  +      {
  +         firstConnection = true;
  +         listenerIdToInvokerLocatorMap.put(listenerId, locator);
  +      }
  +      
  +      log.info(this + ": creating control connection: " + locator);
  +      
  +      Socket socket = null;
  +      if (socketFactory != null)
  +         socket = socketFactory.createSocket(locator.getHost(), locator.getPort());
  +      else
  +         socket = new Socket(locator.getHost(), locator.getPort());
  +      log.info(this + ": created socket: " + socket);
  +      
  +      DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
  +      log.info("got DataOutputStream: " + dos);
  +      if (firstConnection)
  +      {
  +         log.info("writing: " + Bisocket.CREATE_ORDINARY_SOCKET);
  +         dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +         log.info("wrote: " + Bisocket.CREATE_ORDINARY_SOCKET);
  +      }
  +      else
  +      {
  +         log.info("writing: " + Bisocket.CREATE_CONTROL_SOCKET);
  +         dos.write(Bisocket.CREATE_CONTROL_SOCKET);
  +         log.info("wrote: " + Bisocket.CREATE_CONTROL_SOCKET);
  +      }
  +      dos.writeUTF(listenerId);
  +      log.info(this + ": wrote listenerId: " + listenerId);
  +      Thread thread = new ControlConnectionThread(socket, listenerId);
  +      thread.setName("control: " + socket.toString());
  +      thread.setDaemon(true);
  +      
  +      synchronized (controlConnectionThreadMap)
  +      {
  +         controlConnectionThreadMap.put(listenerId, thread);
  +      }
  +      
  +      thread.start();
  +      log.info("created control connection: " + locator);
  +      
  +      if (controlMonitorTimerTask == null)
  +      {
  +         controlMonitorTimerTask = new ControlMonitorTimerTask();
  +         TimerUtil.schedule(controlMonitorTimerTask, pingFrequency);
  +         log.info(this + ": scheduled ControlMonitorTimerTask: " + controlMonitorTimerTask);
  +         log.info("pingFrequency: " + pingFrequency);
  +      }
  +   }
  +   
  +   
  +   public int getPingFrequency()
  +   {
  +      return pingFrequency;
  +   }
  +   
  +   
  +   public void setPingFrequency(int pingFrequency)
  +   {
  +      this.pingFrequency = pingFrequency;
  +      pingWindow = 2 * pingFrequency;
  +      log.info("set ping frequency: " + pingFrequency);
  +   }
  +   
  +   
  +   protected void setup() throws Exception
  +   {
  +      Object o = configuration.get(Bisocket.IS_CALLBACK_SERVER);
  +      
  +      if (o != null)
  +      {
  +         if (o instanceof String)
  +            isCallbackServer = Boolean.valueOf((String) o).booleanValue();
  +         else if (o instanceof Boolean)
  +            isCallbackServer = ((Boolean) o).booleanValue();
  +         else
  +            log.error("unrecognized value for configuration key \"" + 
  +                  Bisocket.IS_CALLBACK_SERVER + "\": " + o);
  +      }
  +      
  +      super.setup();
  +   }
  +   
  +   
  +   protected void cleanup()
  +   {
  +      super.cleanup();
  +      log.info(this + ": $$$entering cleanup()");
  +      log.info("controlMonitorTimerTask: " + this.controlMonitorTimerTask);
  +      
  +      if (controlMonitorTimerTask != null)
  +      {
  +         controlMonitorTimerTask.shutdown();
  +      }
  +      Iterator it = controlConnectionThreadMap.values().iterator();
  +      while (it.hasNext())
  +      {
  +         ControlConnectionThread t = (ControlConnectionThread) it.next();
  +         t.shutdown();
  +         it.remove();
  +      }
  +      log.info("secondaryServerSocketThread: " + secondaryServerSocketThread);
  +      if (secondaryServerSocketThread != null)
  +      {
  +         secondaryServerSocketThread.shutdown();
  +      }
  +      if (secondaryServerSocket != null)
  +      {
  +         try
  +         {
  +            secondaryServerSocket.close();
  +            log.info("closed secondary port: " +
  +                     secondaryServerSocket.getInetAddress() + ":" +
  +                     secondaryServerSocket.getLocalPort());
  +         }
  +         catch (IOException e)
  +         {
  +            log.info("Error closing secondary server socket: " + e.getMessage());
  +         }
  +      }
  +   }
  +   
  +   
  +   protected InvokerLocator getSecondaryLocator()
  +   {
  +      return secondaryLocator;
  +   }
  +   
  +   protected ServerSocket getServerSocket()
  +   {
  +      return serverSocket;
  +   }
  +   
  +   
  +   protected Object handleInternalInvocation(InternalInvocation ii,
  +                                             InvocationRequest ir,
  +                                             ServerInvocationHandler handler)
  +   throws Throwable
  +   {
  +      if(Bisocket.GET_SECONDARY_INVOKER_LOCATOR.equals(ii.getMethodName()))
  +      {
  +         log.info("returning secondaryLocator: " + secondaryLocator); 
  +         return secondaryLocator;
  +      }
  +      
  +      Object response = super.handleInternalInvocation(ii, ir, handler);
  +      
  +      if(InternalInvocation.ADDCLIENTLISTENER.equals(ii.getMethodName()))
  +      {
  +         Map metadata = ir.getRequestPayload();
  +         if(metadata != null)
  +         {
  +            String listenerId = (String) metadata.get(Client.LISTENER_ID_KEY);
  +            if (listenerId != null)
  +            {
  +               listenerIdToServerInvokerMap.put(listenerId, this);
  +               log.info("registered " + listenerId + " -> " + this);
  +//               new Exception().printStackTrace();
  +            }
  +         }
  +      }
  +      
  +      return response;
  +   }
  +   
  +   
  +   class ControlConnectionThread extends Thread
  +   {
  +      private Socket controlSocket;
  +      private String listenerId;
  +      private DataInputStream dis;
  +      private boolean running;
  +      private int errorCount;
  +      private long lastPing = -1;
  +      
  +      ControlConnectionThread(Socket socket, String listenerId) throws IOException
  +      {
  +         controlSocket = socket;
  +         this.listenerId = listenerId;
  +         dis = new DataInputStream(socket.getInputStream());
  +      }
  +      
  +      void shutdown()
  +      {
  +         running = false;
  +         synchronized (controlConnectionThreadMap)
  +         {
  +            controlConnectionThreadMap.remove(this);
  +         }
  +         try
  +         {
  +            controlSocket.close();
  +         }
  +         catch (IOException e)
  +         {
  +            log.warn("unable to close controlSocket");
  +         }
  +         interrupt();
  +      }
  +      
  +      boolean checkConnection()
  +      {
  +         if (lastPing < 0)
  +         {
  +            log.info("returning true");
  +            return true;
  +         }
  +         long currentTime = System.currentTimeMillis();
  +         log.info(this + ": elapsed: " + (currentTime - lastPing));
  +         log.info("returning: " + ((currentTime - lastPing > pingWindow) ? false : true)); 
  +         return (currentTime - lastPing <= pingWindow);
  +      }
  +      
  +      String getListenerId()
  +      {
  +         return listenerId;
  +      }
  +      
  +      public void run()
  +      {
  +         log.info(this + ": starting ControlConnectionThread");
  +         running = true;
  +         while (running)
  +         {
  +            Socket socket = null;
  +            
  +            try
  +            {
  +               int action = dis.read();
  +               lastPing = System.currentTimeMillis();
  +               
  +               switch (action)
  +               {
  +                  case Bisocket.CREATE_ORDINARY_SOCKET:
  +//                     String listenerId = dis.readUTF();
  +//                     dis.readUTF();
  +                     InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +                     if (socketFactory != null)
  +                        socket = socketFactory.createSocket(locator.getHost(), locator.getPort());
  +                     else
  +                        socket = new Socket(locator.getHost(), locator.getPort());
  +                     DataOutputStream dos = new DataOutputStream(socket.getOutputStream());
  +                     dos.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +                     dos.writeUTF(listenerId);
  +                     break;
  +                     
  +                  case Bisocket.PING:
  +                     log.info(this + ": got ping");
  +//                     log.info("lastPing: " + lastPing);
  +                     continue;
  +                     
  +                  case -1:
  +                     shutdown();
  +                     return;
  +                     
  +                  default:
  +                     log.error("unrecognized action: " + action);
  +                     continue;
  +               }
  +            }
  +            catch (IOException e)
  +            {
  +               if (running)
  +               {
  +                  if ("socket closed".equals(e.getMessage()) || 
  +                      "Socket is closed".equals(e.getMessage()))
  +                  {
  +                     shutdown();
  +                     return;
  +                  }
  +                  log.error("Unable to create new Socket: " + e.getMessage());
  +                  e.printStackTrace();
  +                  if (++errorCount > 5)
  +                  {
  +                     shutdown();
  +                     return;
  +                  }
  +                  continue;
  +               }
  +               
  +               return;
  +            }
  +            
  +            synchronized (clientpool)
  +            {
  +               if(clientpool.size() < maxPoolSize)
  +               {
  +                  Thread thread = null;
  +                  try
  +                  {
  +                     thread = new ServerThread(socket, BisocketServerInvoker.this,
  +                                               clientpool, threadpool,
  +                                               getTimeout(), serverSocketClass);
  +                     thread.start();
  +                     log.info("created: " + thread);
  +                  }
  +                  catch (Exception e)
  +                  {
  +                     log.error("Unable to create new ServerThread: " + e.getMessage());
  +                     e.printStackTrace();
  +                  }
  +                  
  +                  synchronized (threadpool)
  +                  {
  +                     threadpool.add(thread);
  +                  }
  +               }
  +            }
  +         }
  +      }
  +   }
  +   
  +   
  +//   protected ServerThread createServerThread(Socket socket) throws Exception
  +//   {
  +//      return new BisocketServerThread(socket, this, clientpool, threadpool, getTimeout(), serverSocketClass);
  +//   }
  +   
  +   
  +   class SecondaryServerSocketThread extends Thread
  +   {
  +      private ServerSocket secondaryServerSocket;
  +      boolean running = true;
  +      
  +      SecondaryServerSocketThread(ServerSocket secondaryServerSocket) throws IOException
  +      {
  +         this.secondaryServerSocket = secondaryServerSocket;
  +      }
  +      
  +      void shutdown()
  +      {
  +         running = false;
  +         interrupt();
  +         log.info(this + ": shut down");
  +      }
  +      
  +      public void run()
  +      {
  +         while (running)
  +         {
  +            try
  +            {
  +               Socket socket = secondaryServerSocket.accept();
  +               log.info(this + ": accepted: " + socket);
  +               DataInputStream dis = new DataInputStream(socket.getInputStream());
  +               int action = dis.read();
  +               log.info(this + ": action: " + action);
  +               String listenerId = dis.readUTF();
  +               log.info(this + ": listenerId: " + listenerId);
  +               
  +               switch (action)
  +               {
  +                  case Bisocket.CREATE_CONTROL_SOCKET:
  +                     BisocketClientInvoker invoker;
  +                     invoker =  BisocketClientInvoker.getBisocketClientInvoker(listenerId);
  +                     log.info("calling replaceControlSocket()");
  +                     if (invoker == null)
  +                     {
  +                        log.error("unrecognized listenerId: " + listenerId);
  +                        log.error("unable to create control socket");
  +                        continue;
  +                     }
  +                     invoker.replaceControlSocket(socket);
  +                     log.info("SecondaryServerSocketThread: created secondary socket: " + listenerId);
  +                     break;
  +                     
  +                  case Bisocket.CREATE_ORDINARY_SOCKET: 
  +                     BisocketClientInvoker.transferSocket(listenerId, socket);
  +                     log.info("SecondaryServerSocketThread: transferred socket: " + listenerId);
  +                     break;
  +                     
  +                  default:
  +                     log.error("unrecognized action: " + action);
  +               }
  +            }
  +            catch (IOException e)
  +            {
  +               if (running)
  +                  log.error("Failed to accept socket connection", e);
  +               else
  +                  return;
  +                  
  +            }
  +         }
  +      }
  +      
  +      ServerSocket getServerSocket()
  +      {
  +         return secondaryServerSocket;
  +      }
  +   }
  +   
  +   
  +   class ControlMonitorTimerTask extends TimerTask
  +   {
  +      private boolean running = true;
  +      
  +      void shutdown()
  +      {
  +         running = false;
  +         cancel();
  +         log.info("shutting down " + this);
  +      }
  +      
  +      public void run()
  +      {
  +         Collection controlConnectionThreads = null;
  +         synchronized (controlConnectionThreadMap)
  +         {
  +            controlConnectionThreads = new HashSet(controlConnectionThreadMap.values());
  +         }
  +         
  +         Iterator it = controlConnectionThreads.iterator();
  +         while (it.hasNext() & running)
  +         {
  +            ControlConnectionThread t = (ControlConnectionThread) it.next();
  +            if (!t.checkConnection())
  +            {
  +               log.info(this + ": detected failure on control connection: requesting new control connection");
  +               t.shutdown();
  +               it.remove();
  +               
  +               if (!running)
  +                  return;
  +               
  +               try
  +               {
  +                  createControlConnection(t.getListenerId(), null);
  +               }
  +               catch (IOException e)
  +               {
  +                  InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(t.getListenerId());
  +                  log.error(this + ": " + "Unable to recreate control connection: " + locator, e);
  +                  e.printStackTrace();
  +               }
  +            }
  +         }
  +      }
  +   }
  +   
  +   
  +//   class InternalInvocationHandler implements ServerInvocationHandler
  +//   {
  +//      InvokerLocator locator;
  +//      
  +//      InternalInvocationHandler(ServerSocket ss)
  +//      {
  +//         String host = ss.getInetAddress().getHostAddress();
  +//         int port = ss.getLocalPort();
  +//         locator = new InvokerLocator(null, host, port, null, null);   
  +//      }
  +//      
  +//      public Object invoke(InvocationRequest invocation) throws Throwable
  +//      {
  +//         return locator;
  +//      }
  +//
  +//      public void setMBeanServer(MBeanServer server) {}
  +//      public void setInvoker(ServerInvoker invoker) {}
  +//      public void addListener(InvokerCallbackHandler callbackHandler) {}
  +//      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +//   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +51 -0     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/TransportClientFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportClientFactory.java
  ===================================================================
  RCS file: TransportClientFactory.java
  diff -N TransportClientFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportClientFactory.java	27 Dec 2006 05:58:10 -0000	1.2
  @@ -0,0 +1,51 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.transport.ClientFactory;
  +import org.jboss.remoting.transport.ClientInvoker;
  +
  +import java.io.IOException;
  +import java.util.Map;
  +
  +/**
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class TransportClientFactory implements ClientFactory
  +{
  +   public ClientInvoker createClientInvoker(InvokerLocator locator, Map config)
  +         throws IOException
  +   {
  +      return new BisocketClientInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return false;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +401 -0    JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketClientInvoker.java
  ===================================================================
  RCS file: BisocketClientInvoker.java
  diff -N BisocketClientInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketClientInvoker.java	27 Dec 2006 05:58:10 -0000	1.2
  @@ -0,0 +1,401 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.bisocket;
  +
  +import java.io.IOException;
  +import java.io.OutputStream;
  +import java.net.Socket;
  +import java.util.Collections;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.Map;
  +import java.util.Set;
  +import java.util.TimerTask;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.ConnectionFailedException;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.invocation.InternalInvocation;
  +import org.jboss.remoting.marshal.Marshaller;
  +import org.jboss.remoting.marshal.UnMarshaller;
  +import org.jboss.remoting.transport.BidirectionalClientInvoker;
  +import org.jboss.remoting.transport.socket.SocketClientInvoker;
  +import org.jboss.remoting.util.TimerUtil;
  +
  +/**
  + * BisocketClientInvoker uses Sockets to remotely connect to the a remote ServerInvoker,
  + * which must be a BisocketServerInvoker.
  + * 
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketClientInvoker
  +extends SocketClientInvoker
  +implements BidirectionalClientInvoker
  +{  
  +   private static final Logger log = Logger.getLogger(BisocketClientInvoker.class);
  +   private static Map listenerIdToClientInvokerMap = Collections.synchronizedMap(new HashMap());
  +   private static Map listenerIdToSocketsMap = new HashMap();
  + 
  +   private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;;
  +   protected String listenerId;
  +   private InvokerLocator secondaryLocator;
  +   private Socket controlSocket;
  +   private OutputStream controlOutputStream;
  +   private Object controlLock = new Object();
  +   private PingTimerTask pingTimerTask;
  +
  +   
  +   static BisocketClientInvoker getBisocketClientInvoker(String listenerId)
  +   {
  +      return (BisocketClientInvoker) listenerIdToClientInvokerMap.get(listenerId);
  +   }
  +   
  +   
  +   static void transferSocket(String listenerId, Socket socket)
  +   {
  +      Set sockets = null;
  +      
  +      synchronized (listenerIdToSocketsMap)
  +      {
  +         sockets = (Set) listenerIdToSocketsMap.get(listenerId);
  +         if (sockets == null)
  +         {
  +            sockets = new HashSet();
  +            listenerIdToSocketsMap.put(listenerId, sockets);
  +         }
  +      }
  +      
  +      synchronized (sockets)
  +      {
  +         sockets.add(socket);
  +         sockets.notify();
  +      }
  +   }
  +   
  +   
  +   public BisocketClientInvoker(InvokerLocator locator) throws IOException
  +   {
  +      this(locator, null);
  +   }
  +
  +   
  +   public BisocketClientInvoker(InvokerLocator locator, Map config) throws IOException
  +   {
  +      super(locator, config);
  +      
  +      if (config != null)
  +      {
  +         listenerId = (String) config.get(Client.LISTENER_ID_KEY);
  +         if (listenerId != null)
  +         {
  +            listenerIdToClientInvokerMap.put(listenerId, this);
  +            
  +            synchronized (listenerIdToSocketsMap)
  +            {
  +               if (listenerIdToSocketsMap.get(listenerId) == null)
  +                  listenerIdToSocketsMap.put(listenerId, new HashSet());
  +            }
  +            
  +            log.info("registered " + listenerId + " -> " + this);
  +         }
  +
  +            // look for socketTimeout param
  +            Object val = config.get(Bisocket.PING_FREQUENCY);
  +            if (val != null)
  +            {
  +               try
  +               {
  +                  int nVal = Integer.valueOf((String) val).intValue();
  +                  pingFrequency = nVal;
  +                  log.debug("Setting ping frequency to: " + pingFrequency);
  +               }
  +               catch (Exception e)
  +               {
  +                  log.warn("Could not convert " + Bisocket.PING_FREQUENCY +
  +                           " value of " + val + " to an int value.");
  +               }
  +            }
  +      }
  +   }
  +   
  +   
  +   public int getPingFrequency()
  +   {
  +      return pingFrequency;
  +   }
  +   
  +   
  +   public void setPingFrequency(int pingFrequency)
  +   {
  +      this.pingFrequency = pingFrequency;
  +      log.info("set ping frequency: " + pingFrequency);
  +   }
  +   
  +   
  +   protected void handleConnect() throws ConnectionFailedException
  +   {
  +      super.handleConnect();
  +      
  +      // Callback client on server side.
  +      if (listenerId != null)
  +      {
  +//         pingTimerTask = new PingTimerTask();
  +//         TimerUtil.schedule(pingTimerTask, pingFrequency);
  +//         log.info("scheduled PingTimerTask");
  +         return;
  +      }
  +      
  +      // Client on client side.
  +      try
  +      {
  +         InternalInvocation ii = new InternalInvocation(Bisocket.GET_SECONDARY_INVOKER_LOCATOR, null);
  +         InvocationRequest r = new InvocationRequest(null, null, ii, null, null, null);
  +//         secondaryLocator = (InvokerLocator) invoke(r);
  +         Object o = invoke(r);
  +         log.info("secondary locator: " + o);
  +         secondaryLocator = (InvokerLocator) o;
  +         log.info("got secondary locator: " + secondaryLocator);
  +      }
  +      catch (Throwable e)
  +      {
  +         log.error("Unable to retrieve address/port of secondary server socket", e);
  +         throw new ConnectionFailedException(e.getMessage());
  +      }
  +   }
  +
  +   
  +   protected void handleDisconnect()
  +   {
  +      super.handleDisconnect();
  +      if (listenerId != null)
  +      {
  +         listenerIdToClientInvokerMap.remove(listenerId);
  +         listenerIdToSocketsMap.remove(listenerId);
  +         if (pingTimerTask != null)
  +            pingTimerTask.shutDown();
  +      }
  +   }
  +   
  +   
  +   protected Object transport(String sessionId, Object invocation, Map metadata,
  +                              Marshaller marshaller, UnMarshaller unmarshaller)
  +   throws IOException, ConnectionFailedException, ClassNotFoundException
  +   {  
  +      if (invocation instanceof InvocationRequest)
  +      {
  +         InvocationRequest ir = (InvocationRequest) invocation;
  +         Object o = ir.getParameter();
  +         if (o instanceof InternalInvocation)
  +         {
  +            InternalInvocation ii = (InternalInvocation) o;
  +            if (InternalInvocation.ADDLISTENER.equals(ii.getMethodName()))
  +            {
  +               Map requestPayload = ir.getRequestPayload();
  +               String listenerId = (String) requestPayload.get(Client.LISTENER_ID_KEY);
  +               BisocketServerInvoker callbackServerInvoker;
  +               callbackServerInvoker = BisocketServerInvoker.getBisocketServerInvoker(listenerId);
  +               callbackServerInvoker.createControlConnection(listenerId, secondaryLocator);
  +            }
  +         }
  +      }
  +      
  +      return super.transport(sessionId, invocation, metadata, marshaller, unmarshaller);
  +   }
  +   
  +   
  +   protected Socket createSocket(String address, int port) throws IOException
  +   {
  +      if (listenerId == null)
  +         return super.createSocket(address, port);
  +
  +      Set sockets = null;
  +      
  +      synchronized (listenerIdToSocketsMap)
  +      {
  +         sockets = (Set) listenerIdToSocketsMap.get(listenerId);
  +         if (sockets == null)
  +         {
  +            sockets = new HashSet();
  +            listenerIdToSocketsMap.put(listenerId, sockets);
  +         }
  +      }
  +      
  +      if (controlSocket == null)
  +      {
  +         synchronized (sockets)
  +         {
  +            if (sockets.isEmpty())
  +            {
  +               while (true)
  +               {
  +                  try
  +                  {
  +                     sockets.wait(1000);
  +                     break;
  +                  }
  +                  catch (InterruptedException ignored)
  +                  {
  +                     log.warn("unexpected interrupt");
  +                  }
  +               }
  +            }
  +            
  +            if (sockets.isEmpty())
  +               throw new IOException("Timed out trying to create control socket");
  +            
  +            Iterator it = sockets.iterator();
  +            controlSocket = (Socket) it.next();
  +            it.remove();
  +            controlOutputStream = controlSocket.getOutputStream();
  +            log.info("got control socket");
  +            pingTimerTask = new PingTimerTask();
  +            TimerUtil.schedule(pingTimerTask, pingFrequency);
  +            log.info("scheduled PingTimerTask: " + pingTimerTask);
  +         }
  +      }
  +  
  +      log.info("requesting socket");
  +      
  +      synchronized (controlLock)
  +      {
  +         log.info("writing CREATE_ORDINARY_SOCKET");
  +         controlOutputStream.write(Bisocket.CREATE_ORDINARY_SOCKET);
  +      }
  +
  +      synchronized (sockets)
  +      {
  +         if (sockets.isEmpty())
  +         {
  +            while (true)
  +            {
  +               try
  +               {
  +                  sockets.wait(1000);
  +                  break;
  +               }
  +               catch (InterruptedException ignored)
  +               {
  +                  log.warn("unexpected interrupt");
  +               }
  +            }
  +         }
  +         
  +         if (sockets.isEmpty())
  +            throw new IOException("Timed out trying to create socket");
  +         
  +         Iterator it = sockets.iterator();
  +         Socket socket = (Socket) it.next();
  +         it.remove();
  +         log.info("socket found");
  +         return socket;
  +      }
  +   }
  +   
  +   
  +   void replaceControlSocket(Socket socket) throws IOException
  +   {
  +      log.info("entering replaceControlSocket");
  +      synchronized (controlLock)
  +      {
  +         controlSocket = socket;
  +         controlOutputStream = controlSocket.getOutputStream();
  +         log.info("replaced control socket");
  +      }
  +      
  +      if (pingTimerTask != null)
  +         pingTimerTask.cancel();
  +      
  +      pingTimerTask = new PingTimerTask();
  +      TimerUtil.schedule(pingTimerTask, pingFrequency);
  +      log.info("replaced PingTimerTask: " + pingTimerTask);
  +   }
  +   
  +   
  +   protected Object checkType(Object o, Class c) throws IOException
  +   {
  +      if (c.isInstance(o))
  +         return o;
  +      
  +      throw new IOException(o + "is not an instance of " + c);
  +   }
  +   
  +   protected Object checkNull(Object o, String field) throws IOException
  +   {
  +      if (o == null)
  +         throw new IOException(field + " must not be null");
  +      
  +      return o;
  +   }
  +
  +
  +   public InvokerLocator getCallbackLocator(Map metadata)
  +   {
  +      String transport = (String) metadata.get(Client.CALLBACK_SERVER_PROTOCOL);
  +      String host = (String) metadata.get(Client.CALLBACK_SERVER_HOST);
  +      String sPort = (String) metadata.get(Client.CALLBACK_SERVER_PORT);
  +      int port = -1;
  +      if (sPort != null)
  +      {
  +         try
  +         {
  +            port = Integer.parseInt(sPort);
  +         }
  +         catch (NumberFormatException e)
  +         {
  +            throw new RuntimeException("Can not set internal callback server port as configuration value (" + sPort + " is not a number.");
  +         }
  +      }
  +
  +      return new InvokerLocator(transport, host, port, "callback", metadata);
  +   }
  +   
  +   
  +   class PingTimerTask extends TimerTask
  +   {
  +      public void shutDown()
  +      {
  +         cancel();
  +      }
  +      
  +      public void run()
  +      {
  +         synchronized (controlLock)
  +         {
  +            try
  +            {
  +               log.info(this + ": sending ping");
  +               controlOutputStream.write(Bisocket.PING);
  +            }
  +            catch (IOException e)
  +            {
  +               log.warn("Unable to send ping: shutting down PingTimerTask");
  +               pingTimerTask = null;
  +               cancel();
  +            }
  +         }
  +      }
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +28 -0     JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/TransportServerFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportServerFactory.java
  ===================================================================
  RCS file: TransportServerFactory.java
  diff -N TransportServerFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportServerFactory.java	27 Dec 2006 05:58:10 -0000	1.2
  @@ -0,0 +1,28 @@
  +package org.jboss.remoting.transport.bisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.transport.ServerFactory;
  +
  +import java.util.Map;
  +
  +/**
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class TransportServerFactory implements ServerFactory
  +{
  +   public ServerInvoker createServerInvoker(InvokerLocator locator, Map config)
  +   {
  +      return new BisocketServerInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return false;
  +   }
  +}
  
  
  
  1.1      date: 2006/12/27 05:58:10;  author: rsigal;  state: Exp;JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketServerThread.java
  
  	<<Binary file>>
  
  


From ron_sigal at yahoo.com  Wed Dec 27 00:58:39 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 00:58:39 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket ...
Message-ID: <E1GzRoF-0003fe-Bg@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 00:58:39

  Added:       src/main/org/jboss/remoting/transport/sslbisocket    
                        TransportServerFactory.java
                        SSLBisocketClientInvoker.java
                        SSLBisocketServerInvoker.java
                        TransportClientFactory.java
  Log:
  JBREM-650: Added sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +24 -0     JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/TransportServerFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportServerFactory.java
  ===================================================================
  RCS file: TransportServerFactory.java
  diff -N TransportServerFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportServerFactory.java	27 Dec 2006 05:58:39 -0000	1.2
  @@ -0,0 +1,24 @@
  +package org.jboss.remoting.transport.sslbisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.transport.ServerFactory;
  +
  +import java.util.Map;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class TransportServerFactory implements ServerFactory
  +{
  +   public ServerInvoker createServerInvoker(InvokerLocator locator, Map config)
  +   {
  +      return new SSLBisocketServerInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return true;
  +   }
  +}
  
  
  
  1.2       +137 -0    JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/SSLBisocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketClientInvoker.java
  ===================================================================
  RCS file: SSLBisocketClientInvoker.java
  diff -N SSLBisocketClientInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketClientInvoker.java	27 Dec 2006 05:58:39 -0000	1.2
  @@ -0,0 +1,137 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.sslbisocket;
  +
  +import java.io.IOException;
  +import java.net.Socket;
  +import java.util.Map;
  +
  +import javax.net.SocketFactory;
  +import javax.net.ssl.HandshakeCompletedListener;
  +import javax.net.ssl.SSLSocket;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.bisocket.BisocketClientInvoker;
  +import org.jboss.remoting.util.socket.HandshakeRepeater;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + *  * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketClientInvoker extends BisocketClientInvoker
  +{
  +   private static final Logger log = Logger.getLogger(SSLBisocketClientInvoker.class);
  +
  +   public SSLBisocketClientInvoker(InvokerLocator locator) throws IOException
  +   {
  +      super(locator);
  +      try
  +      {
  +         setup();
  +      }
  +      catch (Exception ex)
  +      {
  +         log.error("Error setting up ssl bisocket client invoker.", ex);
  +         throw new RuntimeException(ex.getMessage());
  +      }
  +   }
  +
  +   public SSLBisocketClientInvoker(InvokerLocator locator, Map configuration) throws IOException
  +   {
  +      super(locator, configuration);
  +      try
  +      {
  +         setup();
  +      }
  +      catch (Exception ex)
  +      {
  +         log.error("Error setting up ssl bisocket client invoker.", ex);
  +         throw new RuntimeException(ex.getMessage());
  +      }
  +   }
  +
  +   protected SocketFactory createSocketFactory(Map configuration)
  +   {
  +      SocketFactory sf = super.createSocketFactory(configuration);
  +
  +      if (sf != null)
  +      {
  +         return sf;
  +      }
  +
  +      try
  +      {
  +         SSLSocketBuilder server = new SSLSocketBuilder(configuration);
  +         sf = server.createSSLSocketFactory();
  +      }
  +      catch (Exception e)
  +      {
  +         log.error("Error creating SSL Socket Factory for client invoker.", e);
  +      }
  +
  +      return sf;
  +   }
  +
  +   
  +   
  +   protected Socket createSocket(String address, int port) throws IOException
  +   {
  +      log.info("listenerId: " + listenerId);
  +      if (listenerId != null)
  +         return super.createSocket(address, port);
  +      
  +      SocketFactory sf = getSocketFactory();
  +
  +      if (sf == null)
  +         sf = createSocketFactory(configuration);
  +
  +      Socket s = sf.createSocket(address, port);
  +log.info("socket factory: " + sf);
  +log.info("socket: " + s);
  +      if (s instanceof SSLSocket)
  +      {
  +         // need to check for handshake listener and add them if there is one
  +         Object obj = configuration.get(Client.HANDSHAKE_COMPLETED_LISTENER);
  +         if (obj != null && obj instanceof HandshakeCompletedListener)
  +         {
  +            SSLSocket sslSocket = (SSLSocket) s;
  +            HandshakeCompletedListener listener = (HandshakeCompletedListener) obj;
  +            establishHandshake(sslSocket, listener);
  +         }
  +      }
  +
  +      return s;
  +   }
  +
  +   private void establishHandshake(SSLSocket sslSocket, HandshakeCompletedListener listener)
  +         throws IOException
  +   {
  +      HandshakeRepeater repeater = new HandshakeRepeater(listener);
  +      sslSocket.addHandshakeCompletedListener(repeater);
  +      sslSocket.getSession();
  +      repeater.waitForHandshake();
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +107 -0    JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/SSLBisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketServerInvoker.java
  ===================================================================
  RCS file: SSLBisocketServerInvoker.java
  diff -N SSLBisocketServerInvoker.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketServerInvoker.java	27 Dec 2006 05:58:39 -0000	1.2
  @@ -0,0 +1,107 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.sslbisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.bisocket.BisocketServerInvoker;
  +import org.jboss.remoting.transport.sslsocket.SSLSocketServerInvokerMBean;
  +
  +import javax.net.ServerSocketFactory;
  +import javax.net.SocketFactory;
  +import javax.net.ssl.SSLServerSocketFactory;
  +import java.io.IOException;
  +import java.net.InetAddress;
  +import java.net.ServerSocket;
  +import java.util.Map;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketServerInvoker
  +   extends BisocketServerInvoker
  +   implements SSLSocketServerInvokerMBean
  +{
  +
  +   public SSLBisocketServerInvoker(InvokerLocator locator)
  +   {
  +      super(locator);
  +   }
  +
  +   public SSLBisocketServerInvoker(InvokerLocator locator, Map configuration)
  +   {
  +      super(locator, configuration);
  +   }
  +
  +   protected ServerSocketFactory getDefaultServerSocketFactory()
  +   {
  +      return SSLServerSocketFactory.getDefault();
  +   }
  +
  +   protected ServerSocketFactory createServerSocketFactory() throws IOException
  +   {
  +      if (isCallbackServer)
  +         return null;
  +      
  +      return super.createServerSocketFactory();
  +   }
  +   
  +   protected void setup() throws Exception
  +   {
  +      super.setup();
  +      if (isCallbackServer)
  +      {
  +         socketFactory = createSocketFactory(configuration);
  +      }
  +   }
  +   
  +   protected SocketFactory createSocketFactory(Map configuration)
  +   {
  +      SocketFactory sf = super.createSocketFactory(configuration);
  +
  +      if (sf != null)
  +      {
  +         return sf;
  +      }
  +
  +      try
  +      {
  +         SSLSocketBuilder server = new SSLSocketBuilder(configuration);
  +         sf = server.createSSLSocketFactory();
  +      }
  +      catch (Exception e)
  +      {
  +         log.error("Error creating SSL Socket Factory for client invoker.", e);
  +      }
  +
  +      return sf;
  +   }
  +   
  +   protected ServerSocket createServerSocket(int serverBindPort, int backlog, InetAddress bindAddress) throws IOException
  +   {
  +      ServerSocket svrSocket = getServerSocketFactory().createServerSocket(serverBindPort, backlog, bindAddress);
  +      return svrSocket;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.2       +46 -0     JBossRemoting/src/main/org/jboss/remoting/transport/sslbisocket/TransportClientFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransportClientFactory.java
  ===================================================================
  RCS file: TransportClientFactory.java
  diff -N TransportClientFactory.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ TransportClientFactory.java	27 Dec 2006 05:58:39 -0000	1.2
  @@ -0,0 +1,46 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.remoting.transport.sslbisocket;
  +
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.transport.ClientFactory;
  +import org.jboss.remoting.transport.ClientInvoker;
  +
  +import java.io.IOException;
  +import java.util.Map;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class TransportClientFactory implements ClientFactory
  +{
  +   public ClientInvoker createClientInvoker(InvokerLocator locator, Map config) throws IOException
  +   {
  +      return new SSLBisocketClientInvoker(locator, config);
  +   }
  +
  +   public boolean supportsSSL()
  +   {
  +      return true;
  +   }
  +}
  \ No newline at end of file
  
  
  


From forge-admin at jboss.com  Wed Dec 27 01:00:26 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Wed, 27 Dec 2006 01:00:26 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GzRpy-0003iD-PA@committer01.frg.pub.inap.atl.jboss.com>

Commit from nrichards (2006-12-26 01:12 EST)
---------------------

cell params

  jboss-seam  src/pdf/org/jboss/seam/pdf/ui/UICell.java   1.2
  jboss-seam  src/pdf/org/jboss/seam/pdf/ITextUtils.java  1.2
  jboss-seam  examples/pdf/view/table.xhtml               1.2


Commit from nrichards (2006-12-26 12:32 EST)
---------------------

fix unit tests for big decimal

  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/test/BestSellersTest.java   1.5
  jboss-seam  examples/dvdstore/src/com/jboss/dvd/seam/test/StoreManagerTest.java  1.4


Commit from nrichards (2006-12-26 12:36 EST)
---------------------

post action no longer returns view id

  jboss-seam  examples/blog/src/test/BlogTest.java  1.13


Commit from nrichards (2006-12-26 12:37 EST)
---------------------

cleanup

  jboss-seam  examples/blog/resources/META-INF/application.xml  1.5
  jboss-seam  examples/blog/resources/META-INF/jboss-beans.xml  1.2
  jboss-seam  examples/blog/resources/WEB-INF/faces-config.xml  1.10


Commit from nrichards (2006-12-26 12:39 EST)
---------------------

add validator component to init

  jboss-seam  src/test/misc/org/jboss/seam/test/PhaseListenerTest.java  1.30


Commit from nrichards (2006-12-26 13:41 EST)
---------------------

remove testing property

  jboss-seam  examples/seampay/src/org/jboss/seam/example/seampay/Payment.java  1.6


Commit from sbryzak2 (2006-12-27 00:03 EST)
--------------------

changed members to memberships for roles

  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java  1.7


Commit from rsigal (2006-12-27 00:44 EST)
------------------

JBREM-650:  Made started and handleInternalInvocation() protected.

  JBossRemoting  src/main/org/jboss/remoting/ServerInvoker.java  1.55


Commit from rsigal (2006-12-27 00:45 EST)
------------------

JBREM-650: Add metadata to configuration map when creating callback Client.

  JBossRemoting  src/main/org/jboss/remoting/callback/ServerInvokerCallbackHandler.java  1.20


Commit from rsigal (2006-12-27 00:56 EST)
------------------

JBREM-650: Made MAX_POOLSIZE_DEFAULT and serverSocketClass protected.

  JBossRemoting  src/main/org/jboss/remoting/transport/socket/SocketServerInvoker.java  1.33


Commit from rsigal (2006-12-27 00:58 EST)
------------------

JBREM-650:  Added bisocket transport.

+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/Bisocket.java                1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java   1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/TransportClientFactory.java  1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java   1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/TransportServerFactory.java  1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketServerThread.java    1.1


Commit from rsigal (2006-12-27 00:58 EST)
------------------

JBREM-650: Added sslbisocket transport.

+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/TransportServerFactory.java    1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/SSLBisocketClientInvoker.java  1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/SSLBisocketServerInvoker.java  1.2
+ JBossRemoting  src/main/org/jboss/remoting/transport/sslbisocket/TransportClientFactory.java    1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061227/19b42a45/attachment.html 

From Shane_Bryzak at symantec.com  Wed Dec 27 01:06:55 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 27 Dec 2006 01:06:55 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en  ...
Message-ID: <E1GzRwF-0003yW-3Z@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/27 01:06:54

  Modified:    doc/reference/en  master.xml
  Log:
  started security documentation
  
  Revision  Changes    Path
  1.49      +18 -16    jboss-seam/doc/reference/en/master.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: master.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/master.xml,v
  retrieving revision 1.48
  retrieving revision 1.49
  diff -u -b -r1.48 -r1.49
  --- master.xml	16 Dec 2006 15:04:04 -0000	1.48
  +++ master.xml	27 Dec 2006 06:06:54 -0000	1.49
  @@ -22,6 +22,7 @@
   <!ENTITY elenhancements         SYSTEM "modules/elenhancements.xml">
   <!ENTITY testing                SYSTEM "modules/testing.xml">
   <!ENTITY tools                  SYSTEM "modules/tools.xml">
  +<!ENTITY security               SYSTEM "modules/security.xml">
   ]>
   
   <book lang="en">
  @@ -267,6 +268,7 @@
       &elenhancements;
       &testing;
       &tools;
  +    &security;
   
   </book>
   
  
  
  


From Shane_Bryzak at symantec.com  Wed Dec 27 01:06:59 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 27 Dec 2006 01:06:59 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GzRwJ-0003ye-Q1@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/27 01:06:59

  Added:       doc/reference/en/modules  security.xml
  Log:
  started security documentation
  
  Revision  Changes    Path
  1.1      date: 2006/12/27 06:06:59;  author: sbryzak2;  state: Exp;jboss-seam/doc/reference/en/modules/security.xml
  
  Index: security.xml
  ===================================================================
  <chapter id="security">
    <title>Security</title>
  
    <para>
      The Seam Security API is an optional Seam module that provides authentication and authorization features
      for securing both domain and page resources within your Seam project.  It supports multiple levels of security
      <emphasis>granularity</emphasis>, making it capable of performing either simple role-based security checks,
      or at the other end of the scale complex rule-based permission checks on domain objects using JBoss Rules.
    </para>
  
    <sect1>
      <title>Configuration</title>
  
      <para>
        The first step in configuring Seam Security is to install the <literal>SeamSecurityManager</literal> and
        <literal>SecurityConfiguration</literal> components, as they are not installed by default.  The
        <literal>SeamSecurityManager</literal> component is the core of the Seam Security API, and is
        responsible for loading security rules, and performing role and permission checks.
        <literal>SecurityConfiguration</literal> is used to load role and page security configuration from
        a configuration file (or can be extended to load this configuration from an alternative source, such as
        a database). The following entries in <literal>components.xml</literal> will install these two components:
      </para>
  
      <programlisting>
        <![CDATA[
  <!DOCTYPE components PUBLIC "-//JBoss/Seam Component Configuration DTD 1.1//EN"
    "http://jboss.com/products/seam/components-1.1.dtd">
  
  <components>
    <!-- Install a Security Configuration -->
    <component class="org.jboss.seam.security.config.SecurityConfiguration"/>
  
    <!-- Install the Seam Security Manager -->
    <component class="org.jboss.seam.security.SeamSecurityManager"/>
  
  </components>
        ]]>
      </programlisting>
  
      <sect2>
        <title>security-config.xml</title>
  
  	    <para>
  	      The next step is to configure roles.  While this step is optional (it is possible for a user to
  	      belong to a role even if it is not configured in <literal>security-config.xml</literal>), it is
  	      necessary if either 1) explicit permissions are required by your application, or 2) roles require
  	      membership of other roles.	Create a file called <literal>security-config.xml</literal>, which goes in
  	      the <literal>META-INF</literal> directory of the Seam application's jar file.  Here's an example
  	      <literal>security-config.xml</literal> file with a few roles defined.
  	    </para>
  
  	    <programlisting>
  	      <![CDATA[
  <security-config>
  
    <roles>
      <role name="admin">
        <memberships>superuser</memberships>
  
        <permissions>
          <permission name="user" action="create"/>
          <permission name="user" action="modify"/>
          <permission name="user" action="delete"/>
        </permissions>
      </role>
  
      <role name="superuser">
        <memberships>user</memberships>
  
        <permissions>
          <permission name="account" action="create"/>
          <permission name="account" action="delete"/>
        </permissions>
      </role>
  
      <role name="user">
        <permissions>
          <permission name="customer" action="create"/>
          <permission name="customer" action="delete"/>
        </permissions>
      </role>
  
      <role name="guest">
  
      </role>
  
    </roles>
  
  </security-config>
  	      ]]>
  	    </programlisting>
  
  	    <para>
  	      In the above example, we can see that there are four distinct roles: <literal>admin</literal>,
  	      <literal>superuser</literal>, <literal>user</literal> and <literal>guest</literal>.  Technically
  	      speaking, the <literal>guest</literal> entry is redundant as it declares no permissions nor contains
  	      any memberships of other roles.  What is most of interest here are the permissions and role memberships,
  	      which are explained in further detail as follows.
  	    </para>
  
  	    <sect3>
  	      <title>Explicit Permissions</title>
  	      <para>
  	        These are permissions which are explicitly granted to members of a role.  Explicit permissions are
  	        used to address simple security concerns, such as <emphasis>may this user create a new customer
  	        record?</emphasis>, or <emphasis>may this user view customer details?</emphasis>.  While it is
  	        possible to perform a more complex contextual-based decision to grant a specific permission or not,
  	        explicit permissions allow simple decision-less permissions to be easily granted to certain groups
  	        of users.
  	      </para>
  	    </sect3>
  
  	    <sect3>
  	      <title>Role memberships</title>
  
  	      <para>
  	        Role memberships are a simple inheritence feature designed to make it easier to build a security
  	        model from the ground up.  In the above example, it can be seen that the <literal>admin</literal>
  	        role contains a membership of the <literal>superuser</literal> role.  What this means, is that any
  	        explicit permissions that the <literal>superuser</literal> has, whether they were granted to the
  	        <literal>superuser</literal> role directly or inherited from further up, are automatically granted
  	        to the <literal>admin</literal> user also, as a result of its membership.
  	      </para>
  
  	      <para>
  	        The following table shows the permissions granted to each role based on the above 
  	        <literal>security-config.xml</literal> example.
  	      </para>
  
  	      <table>
  	        <title>Permissions granted to example roles</title>
  
  	        <tgroup cols="3">
  	          <colspec colnum="1" colwidth="1*" />
  	          <colspec colnum="2" colwidth="1*" />
  	          <colspec colnum="3" colwidth="1*" />
  
  	          <thead>
  	            <row>
  	              <entry align="center">
  	                <para>Role</para>
  	              </entry>
  
  	              <entry align="center">
  	                <para>Permission</para>
  	              </entry>
  
  	              <entry align="center">
  	                <para>Source</para>
  	              </entry>
  	            </row>
  	          </thead>
  
  	          <tbody>
  	            <row>
  	              <entry>
  	                <para>user</para>
  	              </entry>
  	              <entry>
  	                <para>customer:create</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>user</para>
  	              </entry>
  	              <entry>
  	                <para>customer:delete</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>superuser</para>
  	              </entry>
  	              <entry>
  	                <para>customer:create</para>
  	              </entry>
  	              <entry>
  	                <para>Inherited from user</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>superuser</para>
  	              </entry>
  	              <entry>
  	                <para>customer:delete</para>
  	              </entry>
  	              <entry>
  	                <para>Inherited from user</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>superuser</para>
  	              </entry>
  	              <entry>
  	                <para>account:create</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>superuser</para>
  	              </entry>
  	              <entry>
  	                <para>account:delete</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>customer:create</para>
  	              </entry>
  	              <entry>
  	                <para>Inherited from superuser</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>customer:delete</para>
  	              </entry>
  	              <entry>
  	                <para>Inherited from superuser</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>account:create</para>
  	              </entry>
  	              <entry>
  	                <para>Inherited from superuser</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>account:delete</para>
  	              </entry>
  	              <entry>
  	                <para>Inherited from superuser</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>user:create</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>user:modify</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	            <row>
  	              <entry>
  	                <para>admin</para>
  	              </entry>
  	              <entry>
  	                <para>user:delete</para>
  	              </entry>
  	              <entry>
  	                <para>Assigned directly</para>
  	              </entry>
  	            </row>
  	          </tbody>
  
  	        </tgroup>
          </table>
  
  	    </sect3>
      </sect2>
  
    </sect1>
  
    <sect1>
      <title>Authentication</title>
  
      <para>
  
      </para>
    </sect1>
  
    <sect1>
      <title>Authorization</title>
  
      <para>
  
      </para>
    </sect1>
  
  </chapter>
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:13:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:13:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1GzS2v-00047P-5F@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:13:49

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket     
                        BisocketTestCase.java BisocketTestServer.java
                        BisocketPerformanceTestClient.java
                        BisocketTestClient.java
                        BisocketPerformanceTestServer.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +1410 -0   JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: BisocketTestCase.java
  diff -N BisocketTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTestCase.java	27 Dec 2006 06:13:49 -0000	1.2
  @@ -0,0 +1,1410 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket;
  +
  +import java.lang.reflect.Field;
  +import java.net.InetAddress;
  +import java.net.Socket;
  +import java.util.Collection;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Iterator;
  +import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
  +
  +import javax.management.MBeanServer;
  +
  +import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +import org.jboss.remoting.callback.ServerInvokerCallbackHandler;
  +import org.jboss.remoting.transport.ClientInvoker;
  +import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +import org.jboss.remoting.transport.bisocket.BisocketClientInvoker;
  +import org.jboss.remoting.transport.bisocket.BisocketServerInvoker;
  +import org.jboss.remoting.transport.socket.MicroSocketClientInvoker;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class BisocketTestCase extends TestCase
  +{
  +   public static int port = 5413;
  +   
  +   private static Logger log = Logger.getLogger(BisocketTestCase.class);
  +   
  +   private static final String INVOCATION_TEST =     "invocationTest";
  +   private static final String CALLBACK_TEST =       "callbackTest";
  +   private static final String COUNTER =             "counter";
  +   
  +   private static final String TEST_PING_FREQUENCY_STRING = "1000";
  +   private static final int    TEST_PING_FREQUENCY = 1000;
  +   private static final String TEST_MAX_POOL_SIZE_STRING = "5";
  +   private static final int    TEST_MAX_POOL_SIZE = 5;
  +   
  +   // remoting server connector
  +   private Connector connector;
  +   private SampleInvocationHandler invocationHandler;
  +
  +
  +   
  +   /**
  +    * Sets up target remoting server.
  +    */
  +   public void setUp() throws Exception
  +   {
  +      String locatorURI = getTransport() + "://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      config.put(MicroSocketClientInvoker.MAX_POOL_SIZE_FLAG, TEST_MAX_POOL_SIZE_STRING);
  +      addExtraServerConfig(config);
  +      connector = new Connector(serverLocator, config);
  +      connector.create();
  +      invocationHandler = new SampleInvocationHandler();
  +      connector.addInvocationHandler("sample", invocationHandler);
  +      connector.start();
  +   }
  +
  +   
  +   /**
  +    * Shuts down the server
  +    */
  +   public void tearDown()
  +   {
  +      connector.stop();
  +      connector.destroy();
  +   }
  +   
  +   
  +   public void testInvocations() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int invocationCount = 1000;
  +      HashMap metadata = new HashMap(1);
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         response.equals(count);
  +      }
  +      
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testInvocationsThenCallbacksThenInvocations() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      int invocationCount = 100;
  +      HashMap metadata = new HashMap(1);
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         assertTrue(response.equals(count));
  +      }
  +      
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         client.invoke(CALLBACK_TEST);
  +      }
  +      
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         assertTrue(response.equals(count));
  +      }
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testAlternatingInvocationsAndCallbacks() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      int invocationCount = 100;
  +      HashMap metadata = new HashMap(1);
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         Integer count = new Integer(i);
  +         metadata.put(COUNTER, count);
  +         Object response = client.invoke(INVOCATION_TEST, metadata);
  +         client.invoke(CALLBACK_TEST);
  +         assertTrue(response.equals(count));
  +      }
  +      
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testMaxSocketPoolSize() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      assertEquals(1, invocationHandler.callbackHandlers.size()); 
  +      log.info("client added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker);
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      assertEquals(0, pool.size());
  +      Long usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      int invocationCount = TEST_MAX_POOL_SIZE;
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         client.invokeOneway(CALLBACK_TEST);
  +      }
  +      
  +      Thread.sleep(100);
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      for (int i = 0; i < invocationCount; i++)
  +      {
  +         client.invokeOneway(CALLBACK_TEST);
  +      }
  +      
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      Thread.sleep(1000);
  +      assertEquals(invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      Thread.sleep(1500);
  +      assertEquals(2 * invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(invocationCount, usedPooled.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2 * invocationCount, callbackHandler.callbackCounter);
  +      assertEquals(invocationCount, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testOneClientOneConnectorOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      log.info("client is connected");
  +      
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(1, invocationHandler.callbackHandlers.size()); 
  +      log.info("client added callback handler");
  +      
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      Thread.sleep(100);
  +      assertEquals(3, callbackHandler.callbackCounter);
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker);
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      assertEquals(0, pool.size());
  +      Long usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(3, usedPooled.intValue());
  +      
  +      Thread.sleep(3000);
  +      assertEquals(3, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testOneClientOneConnectorTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +  
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      // Same pool because same address
  +      assertSame(pool, pool2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testOneClientTwoConnectorsOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      log.info("client is connected");
  +      
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI1));
  +      client.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("client added callback handlers");
  +      
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      Thread.sleep(100);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      assertTrue(callbackClient1.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker1 = (MicroSocketClientInvoker) callbackClient1.getInvoker();
  +      assertTrue(callbackClient2.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker2 = (MicroSocketClientInvoker) callbackClient2.getInvoker();
  +     
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      assertEquals(2, usedPooled1.intValue());
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      Thread.sleep(3000);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      assertEquals(0, usedPooled1.intValue());
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(3000);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      assertEquals(0, usedPooled1.intValue());
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +  
  +   public void testOneClientTwoConnectorsTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI1));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +  
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsOneConnectorOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client1 = new Client(serverLocator, config);
  +      client1.connect();
  +      Client client2 = new Client(serverLocator, config);
  +      client2.connect();
  +      log.info("clients are connected");
  +      assertTrue(client1.getInvoker() instanceof BisocketClientInvoker);
  +      assertTrue(client2.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client1.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI));
  +      client2.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(1, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      ClientInvoker clientInvoker = callbackClient.getInvoker();
  +      assertTrue(clientInvoker instanceof BisocketClientInvoker);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker);
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      Long usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.longValue());
  + 
  +      client1.invokeOneway(CALLBACK_TEST);
  +      client2.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(2, usedPooled.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      assertEquals(2, pool.size());
  +      usedPooled = (Long) field.get(clientInvoker);
  +      assertEquals(0, usedPooled.intValue());
  +      
  +      client1.removeListener(callbackHandler);
  +      client1.disconnect();
  +      client2.removeListener(callbackHandler);
  +      client2.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsOneConnectorTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      String callbackLocatorURI = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector = new Connector(callbackLocatorURI, config);
  +      callbackConnector.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      // Same pool because same address
  +      assertSame(pool, pool2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsTwoConnectorsOneHandler() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client1 = new Client(serverLocator, config);
  +      client1.connect();
  +      Client client2 = new Client(serverLocator, config);
  +      client2.connect();
  +      log.info("clients are connected");
  +      assertTrue(client1.getInvoker() instanceof BisocketClientInvoker);
  +      assertTrue(client2.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client1.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI1));
  +      client2.addListener(callbackHandler, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client1.invokeOneway(CALLBACK_TEST);
  +      client2.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(4, callbackHandler.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(4, callbackHandler.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client1.removeListener(callbackHandler);
  +      client1.disconnect();
  +      client2.removeListener(callbackHandler);
  +      client2.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +   
  +   public void testTwoClientsTwoConnectorsTwoHandlers() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      String callbackLocatorURI1 = getTransport() + "://" + host + ":1";
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      Connector callbackConnector1 = new Connector(callbackLocatorURI1, config);
  +      callbackConnector1.start();
  +      String callbackLocatorURI2 = getTransport() + "://" + host + ":2";
  +      Connector callbackConnector2 = new Connector(callbackLocatorURI2, config);
  +      callbackConnector2.start();
  +      
  +      DelayedCallbackHandler callbackHandler1 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler1, new InvokerLocator(callbackLocatorURI1));
  +      DelayedCallbackHandler callbackHandler2 = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler2, new InvokerLocator(callbackLocatorURI2));
  +      assertEquals(2, invocationHandler.callbackHandlers.size()); 
  +      log.info("clients added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler1 = (ServerInvokerCallbackHandler) it.next();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler2 = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient1 = serverInvokerCallbackHandler1.getCallbackClient();
  +      Client callbackClient2 = serverInvokerCallbackHandler2.getCallbackClient();
  +      assertNotSame(callbackClient1, callbackClient2);
  +      ClientInvoker clientInvoker1 = callbackClient1.getInvoker();
  +      assertTrue(clientInvoker1 instanceof BisocketClientInvoker);
  +      ClientInvoker clientInvoker2 = callbackClient2.getInvoker();
  +      assertTrue(clientInvoker2 instanceof BisocketClientInvoker);
  +      assertNotSame(clientInvoker1, clientInvoker2);
  +      
  +      Field field = MicroSocketClientInvoker.class.getDeclaredField("pool");
  +      field.setAccessible(true);
  +      List pool1 = (List) field.get(clientInvoker1);
  +      List pool2 = (List) field.get(clientInvoker2);
  +      
  +      field = MicroSocketClientInvoker.class.getDeclaredField("usedPooled");
  +      field.setAccessible(true);
  +      
  +      assertEquals(0, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      Long usedPooled1 = (Long) field.get(clientInvoker1);
  +      Long usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  + 
  +      client.invokeOneway(CALLBACK_TEST);
  +      client.invokeOneway(CALLBACK_TEST);
  +      
  +      Thread.sleep(500);
  +      int count1 = callbackHandler1.callbackCounter;
  +      int count2 = callbackHandler2.callbackCounter;
  +      assertTrue(count1 == 2 && count2 == 0 || count1 == 0 && count2 == 2);
  +      if (count1 == 0)
  +      {
  +         Object temp = callbackHandler1;
  +         callbackHandler1 = callbackHandler2;
  +         callbackHandler2 = (DelayedCallbackHandler) temp;;
  +      }
  +      
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(0, callbackHandler2.callbackCounter);
  +      assertEquals(0, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(2, usedPooled1.longValue());
  +      assertEquals(0, usedPooled2.longValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(0, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(2, usedPooled2.intValue());
  +      
  +      Thread.sleep(2000);
  +      assertEquals(2, callbackHandler1.callbackCounter);
  +      assertEquals(2, callbackHandler2.callbackCounter);
  +      assertEquals(2, pool1.size());
  +      assertEquals(2, pool2.size());
  +      usedPooled1 = (Long) field.get(clientInvoker1);
  +      usedPooled2 = (Long) field.get(clientInvoker2);
  +      assertEquals(0, usedPooled1.intValue());
  +      assertEquals(0, usedPooled2.intValue());
  +      
  +      client.removeListener(callbackHandler1);
  +      client.removeListener(callbackHandler2);
  +      client.disconnect();
  +      callbackConnector1.stop();
  +      callbackConnector2.stop();
  +   }
  +   
  +   
  +   public void testHearbeat() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      client.invoke(CALLBACK_TEST);
  +      client.invoke(CALLBACK_TEST);
  +      
  +      Thread.sleep(100);
  +      assertEquals(3, callbackHandler.callbackCounter);
  +      
  +      Field field = Client.class.getDeclaredField("callbackConnectors");
  +      field.setAccessible(true);
  +      Map callbackConnectors = (Map) field.get(client);
  +      assertEquals(1, callbackConnectors.size());
  +      Connector callbackConnector = (Connector) callbackConnectors.values().iterator().next();
  +      BisocketServerInvoker invoker = (BisocketServerInvoker) callbackConnector.getServerInvoker();
  +      field = BisocketServerInvoker.class.getDeclaredField("controlConnectionThreadMap");
  +      field.setAccessible(true);
  +      Map controlConnectionThreadMap = (Map) field.get(invoker);
  +      assertEquals(1, controlConnectionThreadMap.size());
  +      Thread t = (Thread) controlConnectionThreadMap.values().iterator().next();
  +      Class[] classes = BisocketServerInvoker.class.getDeclaredClasses();
  +      assertEquals(3, classes.length);
  +      Class invokerClass = null;
  +      for (int i = 0; i < classes.length; i++)
  +      {
  +         log.info(classes[i]);
  +         String fqn = classes[i].getName();
  +         String className = fqn.substring(fqn.lastIndexOf('.') + 1);
  +         log.info(className);
  +         if ("BisocketServerInvoker$ControlConnectionThread".equals(className))
  +         {
  +            invokerClass = classes[i];
  +            break;
  +         }
  +      }
  +      
  +      assertTrue(invokerClass != null);
  +      field = invokerClass.getDeclaredField("lastPing");
  +      field.setAccessible(true);
  +      int pingFrequency = Integer.parseInt(TEST_PING_FREQUENCY_STRING);
  +      Thread.sleep(2 * pingFrequency);
  +      Long lastPing = (Long) field.get(t);
  +      log.info("current: " + System.currentTimeMillis() + ", lastPing: " + lastPing);
  +      assertTrue((System.currentTimeMillis() - lastPing.longValue()) < pingFrequency);
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testControlConnectionFailureServerSide() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(1, callbackHandler.callbackCounter);
  +      
  +      ServerInvoker serverInvoker = connector.getServerInvoker();
  +      assertTrue(serverInvoker instanceof BisocketServerInvoker);
  +      Field field = ServerInvoker.class.getDeclaredField("callbackHandlers");
  +      field.setAccessible(true);
  +      Map callbackHandlers = (Map) field.get(serverInvoker);
  +      assertEquals(1, callbackHandlers.size());
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler;
  +      serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) callbackHandlers.values().toArray()[0]; 
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket controlSocket = (Socket) field.get(clientInvoker);
  +      controlSocket.close();
  +      
  +      Thread.sleep(TEST_PING_FREQUENCY * 2);
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      
  +      field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket newControlSocket = (Socket) field.get(clientInvoker);
  +      assertTrue(!controlSocket.equals(newControlSocket));
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testControlConnectionFailureClientSide() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      DelayedCallbackHandler callbackHandler = new DelayedCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(1, callbackHandler.callbackCounter);
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      BisocketClientInvoker clientInvoker = (BisocketClientInvoker) callbackClient.getInvoker();
  +      Field field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket serverSideControlSocket = (Socket) field.get(clientInvoker);
  +      
  +      field = Client.class.getDeclaredField("callbackConnectors");
  +      field.setAccessible(true);
  +      Map callbackConnectors = (Map) field.get(client);
  +      assertEquals(1, callbackConnectors.size());
  +      Connector callbackConnector = (Connector) callbackConnectors.values().iterator().next();
  +      BisocketServerInvoker invoker = (BisocketServerInvoker) callbackConnector.getServerInvoker();
  +      field = BisocketServerInvoker.class.getDeclaredField("controlConnectionThreadMap");
  +      field.setAccessible(true);
  +      Map controlConnectionThreadMap = (Map) field.get(invoker);
  +      assertEquals(1, controlConnectionThreadMap.size());
  +      Collection controlConnectionThreads = controlConnectionThreadMap.values();
  +      Thread controlConnectionThread = (Thread) controlConnectionThreads.iterator().next();
  +      Class[] classes = BisocketServerInvoker.class.getDeclaredClasses();
  +      assertEquals(3, classes.length);
  +      Class controlConnectionThreadClass = null;
  +      for (int i = 0; i < classes.length; i++)
  +      {
  +         log.info(classes[i]);
  +         String fqn = classes[i].getName();
  +         String className = fqn.substring(fqn.lastIndexOf('.') + 1);
  +         log.info(className);
  +         if ("BisocketServerInvoker$ControlConnectionThread".equals(className))
  +         {
  +            controlConnectionThreadClass = classes[i];
  +            break;
  +         }
  +      }
  +      
  +      assertTrue(controlConnectionThreadClass != null);
  +      field = controlConnectionThreadClass.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket clientSideControlSocket = (Socket) field.get(controlConnectionThread);
  +      clientSideControlSocket.close();
  +      
  +      Thread.sleep(TEST_PING_FREQUENCY * 2);
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +      Thread newControlConnectionThread = (Thread) controlConnectionThreads.iterator().next();
  +      assertTrue(!controlConnectionThread.equals(newControlConnectionThread));
  +      
  +      field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket newServerSideControlSocket = (Socket) field.get(clientInvoker);
  +      assertTrue(!serverSideControlSocket.equals(newServerSideControlSocket));
  +      
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testNoControlConnectionRestart() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      Field field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket controlSocketBefore = (Socket) field.get(clientInvoker);
  +
  +      Thread.sleep(4 * TEST_PING_FREQUENCY);
  +      Socket controlSocketAfter = (Socket) field.get(clientInvoker);      
  +      assertEquals(controlSocketBefore, controlSocketAfter);
  +      log.info("control socket: " + controlSocketBefore);
  +
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public static void main(String[] args)
  +   {
  +      BisocketTestCase testCase = new BisocketTestCase();
  +      try
  +      {
  +         testCase.setUp();
  +         Thread.sleep(600000);
  +         testCase.tearDown();
  +      }
  +      catch(Throwable e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +   
  +   
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   
  +   protected void addExtraClientConfig(Map config)
  +   {
  +   }
  +   
  +   
  +   protected void addExtraServerConfig(Map config)
  +   {
  +   }
  +   
  +
  +   /**
  +    * Simple invocation handler implementation.  When callback client's are registered, will
  +    * generate callbacks periodically.
  +    */
  +   static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +      public Set callbackHandlers = new HashSet();
  +      private int counter = 0;
  +      
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         System.out.println("Adding callback listener.");
  +         callbackHandlers.add(callbackHandler);
  +      }
  +
  +      public Object invoke(InvocationRequest invocation) throws Throwable
  +      {
  +         Object payload = invocation.getParameter();
  +         if (INVOCATION_TEST.equals(payload))
  +         {
  +            Map requestMap = invocation.getRequestPayload();
  +            Integer counter = (Integer) requestMap.get(COUNTER);
  +            return counter;
  +         }
  +         else if (CALLBACK_TEST.equals(payload))
  +         {
  +            try
  +            {
  +               Iterator it = callbackHandlers.iterator();
  +               while (it.hasNext())
  +               {
  +                  InvokerCallbackHandler callbackHandler = (InvokerCallbackHandler) it.next();
  +                  log.info("sending callback: " + ++counter);
  +                  callbackHandler.handleCallback(new Callback("callback"));
  +               }
  +               log.info("sent callback");
  +            }
  +            catch (HandleCallbackException e)
  +            {
  +               log.error("Unable to send callback");
  +            }
  +            return null;
  +         }
  +         else
  +         {
  +            throw new Exception("unrecognized invocation: " + payload);
  +         }
  +      }
  +      
  +      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +      public void setMBeanServer(MBeanServer server) {}
  +      public void setInvoker(ServerInvoker invoker) {}
  +   }
  +   
  +   
  +   static class SimpleCallbackHandler implements InvokerCallbackHandler
  +   {
  +      public int callbackCounter;
  +      private Object lock = new Object();
  +      
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         log.debug("received callback: " + callback.getParameter());
  +         synchronized (lock)
  +         {
  +            callbackCounter++;
  +         }
  +      }
  +   }
  +   
  +   
  +   static class DelayedCallbackHandler implements InvokerCallbackHandler
  +   {
  +      public int callbackCounter;
  +      private Object lock = new Object();
  +      
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         log.debug("received callback: " + callback.getParameter());
  +         synchronized (lock)
  +         {
  +            callbackCounter++;
  +         }
  +         try
  +         {
  +            Thread.sleep(2000);
  +         }
  +         catch (InterruptedException e)
  +         {
  +         }
  +      }
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.1      date: 2006/12/27 06:13:49;  author: rsigal;  state: Exp;JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestServer.java
  
  	<<Binary file>>
  
  
  1.2       +148 -0    JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPerformanceTestClient.java
  ===================================================================
  RCS file: BisocketPerformanceTestClient.java
  diff -N BisocketPerformanceTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPerformanceTestClient.java	27 Dec 2006 06:13:49 -0000	1.2
  @@ -0,0 +1,148 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket;
  +
  +import java.net.InetAddress;
  +import java.util.HashMap;
  +
  +import javax.management.MBeanServer;
  +
  +import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.Client;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class BisocketPerformanceTestClient extends TestCase
  +{
  +   private static Logger log = Logger.getLogger(BisocketPerformanceTestClient.class);
  +   private static String transport = "bisocket";
  +   private static int invocations = 1000;
  +   
  +   
  +   public void testBisocket() throws Throwable
  +   {
  +      String host = InetAddress.getLocalHost().getHostAddress();
  +      int port = BisocketPerformanceTestServer.port;
  +      String locatorURI = transport + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      System.out.println("Connecting to: " + serverLocator);
  +      Client client = new Client(serverLocator);
  +      client.connect();
  +      System.out.println("client is connected");
  +      InvokerCallbackHandler callbackHandler = new SampleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap(), null, true);
  +      System.out.println("client added callback handler");
  +      
  +      long start = System.currentTimeMillis();
  +      for (int i = 0; i < invocations; i++)
  +      {
  +         client.invoke("test");
  +      }
  +      long finish = System.currentTimeMillis();
  +      System.out.println("time to make " + invocations + " invocations: " + (finish - start));
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   /**
  +    * Can pass transport and port to be used as parameters.
  +    *
  +    * @param args
  +    */
  +   public static void main(String[] args)
  +   {
  +      if(args != null && args.length > 0)
  +      {
  +         transport = args[0];
  +         if (args.length > 1)
  +            invocations = Integer.parseInt(args[1]);
  +      }
  +      BisocketPerformanceTestClient testCase = new BisocketPerformanceTestClient();
  +      try
  +      {
  +         testCase.setUp();
  +         testCase.testBisocket();
  +         Thread.sleep(10000);
  +         testCase.tearDown();
  +         System.out.println("done");
  +      }
  +      catch(Throwable e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.  When callback client's are registered, will
  +    * generate callbacks periodically.
  +    */
  +   static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         System.out.println("Adding callback listener.");
  +         try
  +         {
  +            callbackHandler.handleCallback(new Callback("callback"));
  +         }
  +         catch (HandleCallbackException e)
  +         {
  +            log.error("Unable to send callback");
  +         }
  +      }
  +
  +      public Object invoke(InvocationRequest invocation) throws Throwable {return null;}
  +      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +      public void setMBeanServer(MBeanServer server) {}
  +      public void setInvoker(ServerInvoker invoker) {}
  +   }
  +   
  +   
  +   static class SampleCallbackHandler implements InvokerCallbackHandler
  +   {
  +      int counter;
  +      
  +      public void handleCallback(Callback callback) throws HandleCallbackException
  +      {
  +         counter++;
  +         if ((counter + 1) % 1000 == 0)
  +         {
  +            System.out.println("received callback " + (counter + 1));
  +         }
  +      }
  +   }
  +}
  
  
  
  1.1      date: 2006/12/27 06:13:49;  author: rsigal;  state: Exp;JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestClient.java
  
  	<<Binary file>>
  
  
  1.2       +140 -0    JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPerformanceTestServer.java
  ===================================================================
  RCS file: BisocketPerformanceTestServer.java
  diff -N BisocketPerformanceTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPerformanceTestServer.java	27 Dec 2006 06:13:49 -0000	1.2
  @@ -0,0 +1,140 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket;
  +
  +import java.net.InetAddress;
  +import java.util.HashMap;
  +
  +import javax.management.MBeanServer;
  +
  +import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
  +import org.jboss.remoting.InvocationRequest;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.ServerInvocationHandler;
  +import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.callback.Callback;
  +import org.jboss.remoting.callback.HandleCallbackException;
  +import org.jboss.remoting.callback.InvokerCallbackHandler;
  +import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Nov 25, 2006
  + * </p>
  + */
  +public class BisocketPerformanceTestServer extends TestCase
  +{
  +   public static int port = 5423;
  +   
  +   private static Logger log = Logger.getLogger(BisocketPerformanceTestServer.class);
  +   private static String transport = "bisocket";
  +   
  +   // remoting server connector
  +   private Connector connector;
  +
  +   
  +   /**
  +    * Sets up target remoting server.
  +    */
  +   public void setUp() throws Exception
  +   {
  +      String locatorURI = transport + "://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  +      HashMap config = new HashMap();
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "false");
  +      connector = new Connector(serverLocator, config);
  +      connector.create();
  +      SampleInvocationHandler invocationHandler = new SampleInvocationHandler();
  +      connector.addInvocationHandler("sample", invocationHandler);
  +      connector.start();
  +   }
  +
  +   
  +   /**
  +    * Shuts down the server
  +    */
  +   public void tearDown()
  +   {
  +      if (connector != null)
  +      {
  +         connector.stop();
  +         connector.destroy();
  +      }
  +   }
  +   
  +   
  +   public static void main(String[] args)
  +   {
  +      if (args.length == 1)
  +         transport = args[0];
  +         
  +      BisocketPerformanceTestServer testCase = new BisocketPerformanceTestServer();
  +      try
  +      {
  +         testCase.setUp();
  +         Thread.sleep(600000);
  +         testCase.tearDown();
  +      }
  +      catch(Throwable e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   /**
  +    * Simple invocation handler implementation.  When callback client's are registered, will
  +    * generate callbacks periodically.
  +    */
  +   static class SampleInvocationHandler implements ServerInvocationHandler
  +   {
  +      InvokerCallbackHandler callbackHandler;
  +      
  +      public void addListener(InvokerCallbackHandler callbackHandler)
  +      {
  +         System.out.println("Adding callback listener.");
  +         this.callbackHandler = callbackHandler;
  +      }
  +
  +      public Object invoke(InvocationRequest invocation) throws Throwable
  +      {
  +         try
  +         {
  +            callbackHandler.handleCallback(new Callback("callback"));
  +         }
  +         catch (HandleCallbackException e)
  +         {
  +            log.error("Unable to send callback");
  +         }
  +         return null;
  +      }
  +      
  +      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  +      public void setMBeanServer(MBeanServer server) {}
  +      public void setInvoker(ServerInvoker invoker) {}
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:29 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:29 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle
	...
Message-ID: <E1GzS3Z-00047y-Ek@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:29

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle      
                        BisocketIdleTimeoutTestCase.java
                        BisocketInactiveIdleTimeoutTestCase.java
                        BisocketIdleTimeoutClientTest.java
                        BisocketInactiveIdleTimeoutTestServer.java
                        BisocketInactiveIdleTimeoutClientTest.java
                        BisocketIdleTimeoutTestServer.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketIdleTimeoutTestCase.java
  ===================================================================
  RCS file: BisocketIdleTimeoutTestCase.java
  diff -N BisocketIdleTimeoutTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketIdleTimeoutTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,48 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +public class BisocketIdleTimeoutTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketIdleTimeoutClientTest.class.getName(),
  +                     2,
  +                     BisocketIdleTimeoutTestServer.class.getName());
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.2       +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInactiveIdleTimeoutTestCase.java
  ===================================================================
  RCS file: BisocketInactiveIdleTimeoutTestCase.java
  diff -N BisocketInactiveIdleTimeoutTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInactiveIdleTimeoutTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,48 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +public class BisocketInactiveIdleTimeoutTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketInactiveIdleTimeoutClientTest.class.getName(),
  +                     1,
  +                     BisocketInactiveIdleTimeoutTestServer.class.getName());
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 360000;
  +   }
  +
  +}
  
  
  
  1.2       +14 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketIdleTimeoutClientTest.java
  ===================================================================
  RCS file: BisocketIdleTimeoutClientTest.java
  diff -N BisocketIdleTimeoutClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketIdleTimeoutClientTest.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,14 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.IdleTimeoutClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketIdleTimeoutClientTest extends IdleTimeoutClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  
  
  
  1.2       +28 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInactiveIdleTimeoutTestServer.java
  ===================================================================
  RCS file: BisocketInactiveIdleTimeoutTestServer.java
  diff -N BisocketInactiveIdleTimeoutTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInactiveIdleTimeoutTestServer.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,28 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.InactiveIdleTimeoutTestServer;
  +
  +/**
  + * This is just like IdleTimeoutTestServer except instead of
  + * looking for server threads that are still in read mode waiting for
  + * data from client, want to test for idle server threads that finished with
  + * client/server connection and are just sitting in the thread pool waiting to
  + * be re-used.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketInactiveIdleTimeoutTestServer extends InactiveIdleTimeoutTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   public static void main(String[] args) throws Throwable
  +   {
  +      BisocketInactiveIdleTimeoutTestServer rt = new BisocketInactiveIdleTimeoutTestServer();
  +      rt.setUp();
  +      Thread.sleep(45000);
  +      rt.tearDown();
  +   }
  +}
  
  
  
  1.2       +14 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInactiveIdleTimeoutClientTest.java
  ===================================================================
  RCS file: BisocketInactiveIdleTimeoutClientTest.java
  diff -N BisocketInactiveIdleTimeoutClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInactiveIdleTimeoutClientTest.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,14 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.InactiveIdleTimeoutClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketInactiveIdleTimeoutClientTest extends InactiveIdleTimeoutClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  
  
  
  1.2       +21 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketIdleTimeoutTestServer.java
  ===================================================================
  RCS file: BisocketIdleTimeoutTestServer.java
  diff -N BisocketIdleTimeoutTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketIdleTimeoutTestServer.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,21 @@
  +package org.jboss.test.remoting.transport.bisocket.timeout.idle;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.idle.IdleTimeoutTestServer;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + */
  +public class BisocketIdleTimeoutTestServer extends IdleTimeoutTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   public static void main(String[] args) throws Throwable
  +   {
  +      BisocketIdleTimeoutTestServer rt = new BisocketIdleTimeoutTestServer();
  +      rt.startServer();
  +   }
  +}
  +
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:29 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:29 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry
	...
Message-ID: <E1GzS3Z-00048B-I6@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:29

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry   
                        BisocketRetryClient.java BisocketRetryTestCase.java
                        BisocketRetryServer.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketRetryClient.java
  ===================================================================
  RCS file: BisocketRetryClient.java
  diff -N BisocketRetryClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketRetryClient.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection.retry;
  +
  +import org.jboss.test.remoting.transport.socket.connection.retry.SocketRetryClient;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketRetryClient extends SocketRetryClient
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 13;
  +   }
  +}
  
  
  
  1.2       +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketRetryTestCase.java
  ===================================================================
  RCS file: BisocketRetryTestCase.java
  diff -N BisocketRetryTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketRetryTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,38 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection.retry;
  +
  +import org.jboss.test.remoting.transport.socket.connection.retry.SocketRetryTestCase;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketRetryTestCase extends SocketRetryTestCase
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketRetryClient.class.getName(),
  +                     1,
  +                     BisocketRetryServer.class.getName());
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketRetryServer.java
  ===================================================================
  RCS file: BisocketRetryServer.java
  diff -N BisocketRetryServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketRetryServer.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection.retry;
  +
  +import org.jboss.test.remoting.transport.socket.connection.retry.SocketRetryServer;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketRetryServer extends SocketRetryServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 13;
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:29 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:29 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load
	...
Message-ID: <E1GzS3Z-00048L-MK@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:29

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/load  
                        BisocketPooledConnectionTestCase.java
                        BisocketSocketLoadTestCase.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +11 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load/BisocketPooledConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPooledConnectionTestCase.java
  ===================================================================
  RCS file: BisocketPooledConnectionTestCase.java
  diff -N BisocketPooledConnectionTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPooledConnectionTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,11 @@
  +package org.jboss.test.remoting.transport.bisocket.load;
  +
  +import org.jboss.test.remoting.transport.socket.load.PooledConnectionTestCase;
  +
  +public class BisocketPooledConnectionTestCase extends PooledConnectionTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  
  
  
  1.2       +32 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/load/BisocketSocketLoadTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketSocketLoadTestCase.java
  ===================================================================
  RCS file: BisocketSocketLoadTestCase.java
  diff -N BisocketSocketLoadTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketSocketLoadTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,32 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.load;
  +
  +import org.jboss.test.remoting.transport.socket.load.SocketLoadTestCase;
  +
  +public class BisocketSocketLoadTestCase extends SocketLoadTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:29 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:29 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection
	...
Message-ID: <E1GzS3Z-00048h-Rf@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:29

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/connection      
                        BisocketConnectionCheckTestClient.java
                        BisocketConnectionTestCase.java
                        BisocketTestServer.java
                        BisocketConnectionCheckTestServer.java
                        BisocketConnectionCheckTestCase.java
                        BisocketTestClient.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionCheckTestClient.java
  ===================================================================
  RCS file: BisocketConnectionCheckTestClient.java
  diff -N BisocketConnectionCheckTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionCheckTestClient.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketConnectionCheckTestClient;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a> 
  + */
  +public class BisocketConnectionCheckTestClient extends SocketConnectionCheckTestClient
  +{  
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 17;
  +   }
  +}
  
  
  
  1.2       +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionTestCase.java
  ===================================================================
  RCS file: BisocketConnectionTestCase.java
  diff -N BisocketConnectionTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.connection;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketConnectionTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketTestClient.class.getName(),
  +                     1,
  +                     BisocketTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.2       +41 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestServer.java
  ===================================================================
  RCS file: BisocketTestServer.java
  diff -N BisocketTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTestServer.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,41 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketTestServer;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketTestServer extends SocketTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 18;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +20 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionCheckTestServer.java
  ===================================================================
  RCS file: BisocketConnectionCheckTestServer.java
  diff -N BisocketConnectionCheckTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionCheckTestServer.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,20 @@
  +package org.jboss.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketConnectionCheckTestServer;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketConnectionCheckTestServer extends SocketConnectionCheckTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 17;
  +   }
  +}
  
  
  
  1.2       +79 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketConnectionCheckTestCase.java
  ===================================================================
  RCS file: BisocketConnectionCheckTestCase.java
  diff -N BisocketConnectionCheckTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketConnectionCheckTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,79 @@
  +/*
  +* JBoss, a division of Red Hat
  +* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +import org.apache.log4j.Level;
  +
  +/**
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketConnectionCheckTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketConnectionCheckTestClient.class.getName(),
  +                     1,
  +                     BisocketConnectionCheckTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.INFO;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.2       +42 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestClient.java
  ===================================================================
  RCS file: BisocketTestClient.java
  diff -N BisocketTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTestClient.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,42 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.connection;
  +
  +import org.jboss.test.remoting.transport.socket.connection.SocketTestClient;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketTestClient extends SocketTestClient
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 18;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout
	...
Message-ID: <E1GzS3a-00048u-0I@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:30

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/timeout   
                        BisocketTimeoutTestCase.java
                        BisocketTimeoutServerTest.java
                        BisocketTimeoutClientTest.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTimeoutTestCase.java
  ===================================================================
  RCS file: BisocketTimeoutTestCase.java
  diff -N BisocketTimeoutTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTimeoutTestCase.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,38 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.timeout;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketTimeoutTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(BisocketTimeoutClientTest.class.getName(),
  +                     1,
  +                     BisocketTimeoutServerTest.class.getName());
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +50 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTimeoutServerTest.java
  ===================================================================
  RCS file: BisocketTimeoutServerTest.java
  diff -N BisocketTimeoutServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTimeoutServerTest.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,50 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.timeout;
  +
  +import org.jboss.jrunit.extensions.ServerTestCase;
  +import org.jboss.test.remoting.transport.socket.timeout.TimeoutServerTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketTimeoutServerTest extends TimeoutServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   public static void main(String[] args)
  +   {
  +      BisocketTimeoutServerTest server = new BisocketTimeoutServerTest();
  +      try
  +      {
  +         server.setUp();
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +36 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTimeoutClientTest.java
  ===================================================================
  RCS file: BisocketTimeoutClientTest.java
  diff -N BisocketTimeoutClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketTimeoutClientTest.java	27 Dec 2006 06:14:29 -0000	1.2
  @@ -0,0 +1,36 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.timeout;
  +
  +import org.jboss.test.remoting.transport.socket.timeout.TimeoutClientTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketTimeoutClientTest extends TimeoutClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool
	...
Message-ID: <E1GzS3a-000497-5L@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:30

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/socketpool   
                        BisocketPoolTestCase.java
                        BisocketPoolTestServer.java
                        BisocketPoolTestClient.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +88 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPoolTestCase.java
  ===================================================================
  RCS file: BisocketPoolTestCase.java
  diff -N BisocketPoolTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPoolTestCase.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,88 @@
  +/*
  +* JBoss, a division of Red Hat
  +* Copyright 2006, Red Hat Middleware, LLC, and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.socketpool;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.test.remoting.transport.InvokerTestDriver;
  +
  +/**
  + *  This unit test is introduced in response to JIRA issue JBREM-625.
  + *  It verifies that when a socket is discarded, the count of sockets
  + *  in use is decremented.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + *  
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class BisocketPoolTestCase extends InvokerTestDriver
  +{
  +   public void declareTestClasses()
  +   {  
  +      addTestClasses(BisocketPoolTestClient.class.getName(),
  +                     1,
  +                     BisocketPoolTestServer.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.2       +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPoolTestServer.java
  ===================================================================
  RCS file: BisocketPoolTestServer.java
  diff -N BisocketPoolTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPoolTestServer.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,48 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.socketpool;
  +
  +import org.jboss.test.remoting.transport.socket.socketpool.SocketPoolTestServer;
  +
  +/** 
  + * See SocketPoolTestCase for description.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * 
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class BisocketPoolTestServer extends SocketPoolTestServer
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 7;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +48 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketPoolTestClient.java
  ===================================================================
  RCS file: BisocketPoolTestClient.java
  diff -N BisocketPoolTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketPoolTestClient.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,48 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.socketpool;
  +
  +import org.jboss.test.remoting.transport.socket.socketpool.SocketPoolTestClient;
  +
  +/**
  + * See SocketPoolTestCase for description.
  + *  
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * 
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class BisocketPoolTestClient extends SocketPoolTestClient
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 7;
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress
	...
Message-ID: <E1GzS3a-00049K-AB@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:30

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/stress   
                        BisocketInvokerClientTest.java readme.txt
                        BisocketInvokerServerTest.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +28 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress/BisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInvokerClientTest.java
  ===================================================================
  RCS file: BisocketInvokerClientTest.java
  diff -N BisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInvokerClientTest.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,28 @@
  +package org.jboss.test.remoting.transport.bisocket.stress;
  +
  +import org.jboss.test.remoting.transport.socket.stress.SocketInvokerClientTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketInvokerClientTest extends SocketInvokerClientTest
  +{
  +
  +   public String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      BisocketInvokerClientTest client = new BisocketInvokerClientTest();
  +      try
  +      {
  +         client.testClientCalls();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +}
  
  
  
  1.2       +6 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress/readme.txt
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: readme.txt
  ===================================================================
  RCS file: readme.txt
  diff -N readme.txt
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ readme.txt	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,6 @@
  +This package directory contains client/server classes for testing concurrent invocations through the
  +socket transport.  These are not included as part of standard testsuite run and need to be run manually.
  +
  +6/29/06 - Ran with 250 threads on client, each looping 1M times making server invocations.  The test
  +itself finally timed out after two hours of running (per code in test classes), but was able over 35K invocations
  +per thread without error or leak in memory.
  \ No newline at end of file
  
  
  
  1.2       +31 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/stress/BisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInvokerServerTest.java
  ===================================================================
  RCS file: BisocketInvokerServerTest.java
  diff -N BisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInvokerServerTest.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,31 @@
  +package org.jboss.test.remoting.transport.bisocket.stress;
  +
  +import org.jboss.test.remoting.transport.socket.stress.SocketInvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public class BisocketInvokerServerTest extends SocketInvokerServerTest
  +{
  +   public String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +
  +   public static void main(String[] args)
  +   {
  +      BisocketInvokerServerTest server = new BisocketInvokerServerTest();
  +      try
  +      {
  +         server.setUp();
  +//         Thread.currentThread().sleep(300000);
  +         Thread.sleep(7200000);
  +         server.tearDown();
  +         System.out.println("Have torn down test.");
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration
	...
Message-ID: <E1GzS3a-00049R-FK@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:30

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/configuration 
                        FactoryConfigTestCase.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +47 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/configuration/FactoryConfigTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCase.java
  ===================================================================
  RCS file: FactoryConfigTestCase.java
  diff -N FactoryConfigTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ FactoryConfigTestCase.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,47 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + * Copyright 2006, JBoss Inc., and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.configuration;
  +
  +import java.util.Map;
  +
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +import org.jboss.test.remoting.transport.config.FactoryConfigTestCaseParent;
  +
  +/**
  + * 
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + * <p>
  + * Copyright (c) May 20, 2006
  + * </p>
  + */
  +public class FactoryConfigTestCase extends FactoryConfigTestCaseParent
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected void configureServer(Map config)
  +   {
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "false");
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/deadlock
	...
Message-ID: <E1GzS3a-00049Y-JU@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:30

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/deadlock 
                        BisocketShutdownDeadlockTestCase.java
  Log:
  JBREM-650: Unit tests for bisocket transport.
  
  Revision  Changes    Path
  1.2       +36 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/deadlock/BisocketShutdownDeadlockTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketShutdownDeadlockTestCase.java
  ===================================================================
  RCS file: BisocketShutdownDeadlockTestCase.java
  diff -N BisocketShutdownDeadlockTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketShutdownDeadlockTestCase.java	27 Dec 2006 06:14:30 -0000	1.2
  @@ -0,0 +1,36 @@
  +/***************************************
  + *                                     *
  + *  JBoss: The OpenSource J2EE WebOS   *
  + *                                     *
  + *  Distributable under LGPL license.  *
  + *  See terms of license at gnu.org.   *
  + *                                     *
  + ***************************************/
  +package org.jboss.test.remoting.transport.bisocket.deadlock;
  +
  +import org.jboss.test.remoting.transport.socket.deadlock.ShutdownDeadlockTestCase;
  +
  +/**
  + * This test case is for JBREM-576.
  + * Test trys to catch deadlock in shutdown where socket client
  + * invoker being use my multiple Clients.  Need one client making
  + * invocations (which will cause sync on pool) and another to
  + * shutdown, which will cause disconnect on socket client invoker,
  + * thus causing it to sync on pool for clearing out the pool.
  + * Since this is an issue of multithreading, is certainly possible
  + * this test will pass even though the deadlock issue still exists.
  + * @author <a href="mailto:tom at jboss.org">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.org">Ron Sigal</a>
  + */
  +public class BisocketShutdownDeadlockTestCase extends ShutdownDeadlockTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "bisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return super.getPort() + 11;
  +   }
  +}
  \ No newline at end of file
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:52 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:52 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate
	...
Message-ID: <E1GzS3w-0004A4-Ub@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:52

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate     
                        clientTrustStore clientKeyStore serverTrustStore2
                        serverTrustStore serverKeyStore
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +6 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/clientTrustStore
  
  	<<Binary file>>
  
  
  1.2       +7 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/clientKeyStore
  
  	<<Binary file>>
  
  
  1.2       +7 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverTrustStore2
  
  	<<Binary file>>
  
  
  1.2       +4 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverTrustStore
  
  	<<Binary file>>
  
  
  1.2       +9 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverKeyStore
  
  	<<Binary file>>
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check
	...
Message-ID: <E1GzS3x-0004AH-2Q@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check   
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
                        BisocketInvokerServerTest.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.no_connection_check;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     BisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.2       +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.no_connection_check;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.no_connection_check.InvokerClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest extends InvokerClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.2       +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/BisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketInvokerServerTest.java
  ===================================================================
  RCS file: BisocketInvokerServerTest.java
  diff -N BisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ BisocketInvokerServerTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.no_connection_check;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.no_connection_check.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class BisocketInvokerServerTest extends InvokerServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic
	...
Message-ID: <E1GzS3x-0004AU-79@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic   
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +81 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,81 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.basic;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  \ No newline at end of file
  
  
  
  1.2       +46 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,46 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.basic;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.basic.InvokerClientTest;
  +
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest
  +extends InvokerClientTest
  +implements SSLBisocketInvokerConstants
  +{ 
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.2       +59 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,59 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.basic;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.basic.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest extends InvokerServerTest implements SSLBisocketInvokerConstants
  +{
  +
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerServerTest server = new SSLBisocketInvokerServerTest();
  +      try
  +      {
  +         server.setUp();
  +
  +         Thread.sleep(1200000);
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder
	...
Message-ID: <E1GzS3x-0004Ah-Bb@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder   
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerTestServer.java
                        SSLBisocketInvokerTestClient.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,38 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.builder;
  +
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerTestClient.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerTestServer.class.getName());
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +43 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestServer.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestServer.java
  diff -N SSLBisocketInvokerTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestServer.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,43 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.builder;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.builder.SSLSocketInvokerTestServer;
  +
  +/**
  + * This is the server for the test case to verify can have push callbacks using ssl where
  + * the client mode is used for the client calling back on the callback server living within the
  + * client test instance.
  + *
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestServer
  +   extends SSLSocketInvokerTestServer
  +   implements SSLBisocketInvokerConstants
  +{
  +
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerTestServer server = new SSLBisocketInvokerTestServer();
  +      try
  +      {
  +         server.setUp();
  +
  +         Thread.sleep(600000);
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.2       +28 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestClient.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestClient.java
  diff -N SSLBisocketInvokerTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestClient.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,28 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.builder;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.builder.SSLSocketInvokerTestCase;
  +
  +/**
  + * This is the client for the test to make regular ssl based invocation to the server and
  + * have a ssl based callback server.  The special test in this case is want to have the callback
  + * client that lives on the server to be in client mode so that this client test only has to have
  + * a truststore locally, yet still use ssl.
  + *
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestClient
  +   extends SSLSocketInvokerTestCase
  +   implements SSLBisocketInvokerConstants
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh
	...
Message-ID: <E1GzS3x-0004Au-G7@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh   
                        SSLBisocketTestCase.java SSLBisocketTestClient.java
                        SSLBisocketTestServer.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +21 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestCase.java
  ===================================================================
  RCS file: SSLBisocketTestCase.java
  diff -N SSLBisocketTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,21 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.serversocketrefresh;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * JBREM-427 load a new keystore at runtime<br>
  + * server is refreshing its serversocket after a new ServerSocketFactory was set<br>
  + * second client connection attempt fails because client is not accepted by the new truststore
  + * @author Michael Voss
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + *
  + */
  +public class SSLBisocketTestCase extends TestDriver{
  +	
  +	public void declareTestClasses()
  +	   {
  +	      addTestClasses(SSLBisocketTestClient.class.getName(),
  +	                     1,
  +	                     SSLBisocketTestServer.class.getName());
  +
  +	   }
  +}
  
  
  
  1.2       +17 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestClient.java
  ===================================================================
  RCS file: SSLBisocketTestClient.java
  diff -N SSLBisocketTestClient.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestClient.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,17 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.serversocketrefresh;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.serversocketrefresh.TestClient;
  +
  +/**
  + * @author Michael Voss
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + *
  + */
  +public class SSLBisocketTestClient extends TestClient
  +{
  +	protected String getTransport()
  +	{
  +	   return "sslbisocket";
  +	}
  +	
  +}
  
  
  
  1.2       +32 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestServer.java
  ===================================================================
  RCS file: SSLBisocketTestServer.java
  diff -N SSLBisocketTestServer.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestServer.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,32 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.serversocketrefresh;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.serversocketrefresh.TestServer;
  +
  +
  +/**
  + * @author Michael Voss
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + *
  + */
  +public class SSLBisocketTestServer extends TestServer
  +{
  +   public static void main(String[] args)
  +   {
  +      TestServer server = new SSLBisocketTestServer();
  +      server.setUp();
  +      try
  +      {
  +         server.test();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +   
  +   
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl
	...
Message-ID: <E1GzS3x-0004B8-Kp@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl    
                        .truststore SSLBisocketTestCase.java
                        SSLBisocketInvokerConstants.java .keystore
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +34 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/.truststore
  
  	<<Binary file>>
  
  
  1.2       +61 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketTestCase.java
  ===================================================================
  RCS file: SSLBisocketTestCase.java
  diff -N SSLBisocketTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,61 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl;
  +
  +import java.util.Map;
  +
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.test.remoting.transport.bisocket.BisocketTestCase;
  +
  +
  +/** 
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright Dec 15, 2006
  + * </p>
  + */
  +public class SSLBisocketTestCase extends BisocketTestCase
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   
  +   protected void addExtraClientConfig(Map config)
  +   {
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  +      String trustStoreFilePath = this.getClass().getResource(".truststore").getFile();
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
  +   }
  +   
  +   
  +   protected void addExtraServerConfig(Map config)
  +   {
  +      config.put(SSLSocketBuilder.REMOTING_KEY_STORE_TYPE, "JKS");
  +      String keyStoreFilePath = this.getClass().getResource(".keystore").getFile();
  +      config.put(SSLSocketBuilder.REMOTING_KEY_STORE_FILE_PATH, keyStoreFilePath);
  +      config.put(SSLSocketBuilder.REMOTING_KEY_STORE_PASSWORD, "unit-tests-server");
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +32 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketInvokerConstants.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerConstants.java
  ===================================================================
  RCS file: SSLBisocketInvokerConstants.java
  diff -N SSLBisocketInvokerConstants.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerConstants.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,32 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl;
  +
  +/**
  + * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  + */
  +public interface SSLBisocketInvokerConstants
  +{
  +   int bisocketPort = 8091;
  +   int bisocketCallbackPort = 8092;
  +}
  \ No newline at end of file
  
  
  
  1.2       +57 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/.keystore
  
  	<<Binary file>>
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom
	...
Message-ID: <E1GzS3x-0004BL-Og@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom   
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +85 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,85 @@
  +                                                                      /*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.custom;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +
  +/**
  + * This should be used as the main test case for the invoker client/server.
  + * It will start one instance of the client and one of the server and will
  + * gather the test results and report them in standard JUnit format.  When
  + * wanting to run JUnit test for invoker, this is the class to use.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +}
  \ No newline at end of file
  
  
  
  1.2       +97 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,97 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + * Copyright 2005, JBoss Inc., and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.custom;
  +
  +import java.util.HashMap;
  +import java.util.List;
  +
  +import org.apache.log4j.Logger;
  +import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +import org.jboss.test.remoting.transport.socket.ssl.custom.InvokerClientTest;
  +
  +
  +/**
  + * @author <a href="mailto:tom at jboss.com">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + * @version $Revision: 1.2 $
  + * <p>
  + * Copyright (c) Dec 15, 2006
  + * </p>
  + */
  +public class SSLBisocketInvokerClientTest extends InvokerClientTest
  +{
  +   private static Logger log = Logger.getLogger(SSLBisocketInvokerClientTest.class);
  +   
  +   public void testCallbacks()
  +   {
  +      try
  +      {
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://localhost:" + callbackPort);
  +         HashMap config = new HashMap();
  +         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  +         String trustStoreFilePath = this.getClass().getResource("../.truststore").getFile();
  +         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
  +         config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
  +         config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +         Connector callbackConnector = new Connector(locator.getLocatorURI(), config);
  +         callbackConnector.setServerSocketFactory(createServerSocketFactory());
  +         callbackConnector.create();
  +         callbackConnector.addInvocationHandler("sample", new SampleInvocationHandler());
  +         callbackConnector.start();
  +
  +         CallbackHandler callbackHandler = new CallbackHandler();
  +         String callbackHandleObject = "myCallbackHandleObject";
  +         client.addListener(callbackHandler, locator, callbackHandleObject);
  +         solicitCallback("abc");
  +         
  +         // need to wait for brief moment so server can callback
  +         Thread.sleep(500);
  +         
  +         // remove callback handler from server
  +         client.removeListener(callbackHandler);
  +         
  +         // shut down callback server
  +         callbackConnector.stop();
  +         callbackConnector.destroy();
  +         callbackConnector = null;
  +         
  +         List callbacks = callbackHandler.getCallbacks();
  +         assertEquals(callbacks.size(), 1);
  +//         assertEquals(callbacks.get(0), "abc");
  +      }
  +      catch (Throwable t)
  +      {
  +         log.error(t);
  +         t.printStackTrace();
  +         fail();
  +      }
  +   }
  +   
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.2       +52 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,52 @@
  +/*
  +* JBoss, Home of Professional Open Source
  +* Copyright 2005, JBoss Inc., and individual contributors as indicated
  +* by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.custom;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.custom.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest extends InvokerServerTest
  +{
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerServerTest test = new SSLBisocketInvokerServerTest();
  +      try
  +      {
  +         test.setUp();
  +         Thread.sleep(20000);
  +         test.tearDown();
  +      }
  +      catch(Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +   
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check
	...
Message-ID: <E1GzS3x-0004BY-TZ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:53

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check   
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerServerTest.java
                        SSLBisocketInvokerTestCase.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +26 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,26 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.connection_check;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.connection_check.InvokerClientTest;
  +
  +/**
  + * This is the actual concrete test for the invoker client.  Uses socket transport by default.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest
  +   extends InvokerClientTest implements SSLBisocketInvokerConstants
  +{
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +
  +}
  
  
  
  1.2       +38 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,38 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.connection_check;
  +
  +import org.jboss.test.remoting.transport.bisocket.ssl.SSLBisocketInvokerConstants;
  +import org.jboss.test.remoting.transport.socket.ssl.connection_check.InvokerServerTest;
  +
  +/**
  + * This is the concrete test for invoker server.
  + *
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest
  +   extends InvokerServerTest implements SSLBisocketInvokerConstants
  +{
  +   
  +   public static void main(String[] args)
  +   {
  +      SSLBisocketInvokerServerTest server = new SSLBisocketInvokerServerTest();
  +      try
  +      {
  +         server.setUp();
  +      }
  +      catch (Exception e)
  +      {
  +         e.printStackTrace();
  +      }
  +   }
  +
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return bisocketPort;
  +   }
  +}
  
  
  
  1.2       +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	27 Dec 2006 06:14:53 -0000	1.2
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.connection_check;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake
	...
Message-ID: <E1GzS3y-0004Bl-1c@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:54

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake   
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerTestCase.java
                        SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerClientTest.java
  diff -N SSLBisocketInvokerClientTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:54 -0000	1.2
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.handshake;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.handshake.InvokerClientTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerClientTest extends InvokerClientTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  
  1.2       +58 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestCase.java
  ===================================================================
  RCS file: SSLBisocketInvokerTestCase.java
  diff -N SSLBisocketInvokerTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerTestCase.java	27 Dec 2006 06:14:54 -0000	1.2
  @@ -0,0 +1,58 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.handshake;
  +
  +import org.apache.log4j.Level;
  +import org.jboss.jrunit.harness.TestDriver;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerTestCase extends TestDriver
  +{
  +   public void declareTestClasses()
  +   {
  +      addTestClasses(SSLBisocketInvokerClientTest.class.getName(),
  +                     1,
  +                     SSLBisocketInvokerServerTest.class.getName());
  +   }
  +
  +   protected Level getTestLogLevel()
  +   {
  +      return Level.DEBUG;
  +   }
  +
  +   /**
  +    * How long to wait for test results to be returned from the client(s).  If goes longer than the
  +    * specified limit, will throw an exception and kill the running test cases.  Default value is
  +    * RESULTS_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getResultsTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long for the server test case to wait for tear down message.  If exceeds timeout,
  +    * will throw exception.  The default value is TEARDOWN_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getTearDownTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +   /**
  +    * How long to allow each of the test cases to run their tests.  If exceeds this timeout
  +    * will throw exception and kill tests.  The default value is RUN_TEST_TIMEOUT.
  +    *
  +    * @return
  +    */
  +   protected long getRunTestTimeout()
  +   {
  +      return 600000;
  +   }
  +
  +}
  
  
  
  1.2       +15 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: SSLBisocketInvokerServerTest.java
  diff -N SSLBisocketInvokerServerTest.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ SSLBisocketInvokerServerTest.java	27 Dec 2006 06:14:54 -0000	1.2
  @@ -0,0 +1,15 @@
  +package org.jboss.test.remoting.transport.bisocket.ssl.handshake;
  +
  +import org.jboss.test.remoting.transport.socket.ssl.handshake.InvokerServerTest;
  +
  +/**
  + * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  + * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  + */
  +public class SSLBisocketInvokerServerTest extends InvokerServerTest
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:14:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:14:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config
	...
Message-ID: <E1GzS3y-0004Bs-5h@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:14:54

  Added:       src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config 
                        FactoryConfigTestCase.java
  Log:
  JBREM-650: Unit tests for sslbisocket transport.
  
  Revision  Changes    Path
  1.2       +57 -0     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/FactoryConfigTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCase.java
  ===================================================================
  RCS file: FactoryConfigTestCase.java
  diff -N FactoryConfigTestCase.java
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ FactoryConfigTestCase.java	27 Dec 2006 06:14:54 -0000	1.2
  @@ -0,0 +1,57 @@
  +/*
  + * JBoss, Home of Professional Open Source
  + * Copyright 2006, JBoss Inc., and individual contributors as indicated
  + * by the @authors tag. See the copyright.txt 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.test.remoting.transport.bisocket.ssl.config;
  +
  +import java.util.Map;
  +
  +import org.jboss.remoting.security.SSLSocketBuilder;
  +import org.jboss.remoting.transport.bisocket.Bisocket;
  +import org.jboss.test.remoting.transport.config.FactoryConfigTestCaseSSLParent;
  +
  +
  +/**
  + * 
  + * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  + * <p>
  + * Copyright (c) May 20, 2006
  + * </p>
  + */
  +public class FactoryConfigTestCase extends FactoryConfigTestCaseSSLParent
  +{
  +   protected String getTransport()
  +   {
  +      return "sslbisocket";
  +   }
  +   
  +   protected void addExtraCallbackConfig(Map config)
  +   {
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      
  +      // Callback server invoker needs to create a socket factory to contact
  +      // secondary server socket on server side.
  +      config.put(SSLSocketBuilder.REMOTING_SOCKET_USE_CLIENT_MODE, "true");
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_TYPE, "JKS");
  +      String trustStoreFilePath = getTruststoreFilePath();
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_FILE_PATH, trustStoreFilePath);
  +      config.put(SSLSocketBuilder.REMOTING_TRUST_STORE_PASSWORD, "unit-tests-client");
  +   }
  +}
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:15:49 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:15:49 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/config ...
Message-ID: <E1GzS4r-0004FH-5Z@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:15:49

  Modified:    src/tests/org/jboss/test/remoting/transport/config  
                        FactoryConfigTestCaseSSLParent.java
                        FactoryConfigTestCaseParent.java
  Log:
  JBREM-650: Added ability to add transport specific configuration.
  
  Revision  Changes    Path
  1.8       +12 -4     JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseSSLParent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCaseSSLParent.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseSSLParent.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- FactoryConfigTestCaseSSLParent.java	7 Aug 2006 21:17:33 -0000	1.7
  +++ FactoryConfigTestCaseSSLParent.java	27 Dec 2006 06:15:49 -0000	1.8
  @@ -190,7 +190,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -353,7 +355,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -495,7 +499,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -605,7 +611,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  
  
  
  1.6       +20 -6     JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseParent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FactoryConfigTestCaseParent.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseParent.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- FactoryConfigTestCaseParent.java	1 Aug 2006 06:33:19 -0000	1.5
  +++ FactoryConfigTestCaseParent.java	27 Dec 2006 06:15:49 -0000	1.6
  @@ -65,7 +65,7 @@
   /**
    * 
    * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    * <p>
    * Copyright (c) Jun 13, 2006
    * </p>
  @@ -234,7 +234,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -397,7 +399,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -551,7 +555,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -702,7 +708,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -826,7 +834,9 @@
            Thread.sleep(500);
            freeport = PortUtil.findFreePort(getHostName());
            InvokerLocator callbackLocator = new InvokerLocator(getTransport() + "://" + getHostName() + ":" + freeport);
  -         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI());
  +         HashMap config = new HashMap();
  +         addExtraCallbackConfig(config);
  +         Connector callbackConnector = new Connector(callbackLocator.getLocatorURI(), config);
            ServerSocketFactory ssf3 = getDefaultCallbackServerSocketFactory();
            callbackConnector.setServerSocketFactory(ssf3);
            callbackConnector.create();
  @@ -919,6 +929,10 @@
         return UniqueSocketFactory.class;
      }
      
  +   protected void addExtraCallbackConfig(Map config)
  +   {
  +   }
  +   
      public static class UniqueServerSocketFactory
      extends ServerSocketFactory
      implements ServerSocketFactoryMBean
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:21:36 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:21:36 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom
	...
Message-ID: <E1GzSAS-0004Jb-Bf@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:21:36

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/custom 
                        InvokerClientTest.java
  Log:
  JBREM-650: Made createServerSocketFactory() protected.
  
  Revision  Changes    Path
  1.13      +2 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerClientTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- InvokerClientTest.java	20 Jun 2006 17:27:51 -0000	1.12
  +++ InvokerClientTest.java	27 Dec 2006 06:21:36 -0000	1.13
  @@ -55,7 +55,7 @@
   
   /**
    * @author <a href="mailto:tom at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.13 $
    * <p>
    * Copyright (c) Mar 23, 2006
    * </p>
  @@ -219,7 +219,7 @@
      }
      
      
  -   private ServerSocketFactory createServerSocketFactory()
  +   protected ServerSocketFactory createServerSocketFactory()
      throws NoSuchAlgorithmException, KeyManagementException, IOException,
      CertificateException, UnrecoverableKeyException, KeyStoreException
      {
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:23:40 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:23:40 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh
	...
Message-ID: <E1GzSCS-0004LX-2l@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:23:40

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh 
                        TestClient.java
  Log:
  JBREM-650: (1) Added ability to override transport, and (2) moved setUp() inside of try block.
  
  Revision  Changes    Path
  1.6       +7 -3      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestClient.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- TestClient.java	7 Jul 2006 18:47:43 -0000	1.5
  +++ TestClient.java	27 Dec 2006 06:23:40 -0000	1.6
  @@ -23,7 +23,7 @@
   	Map configuration;
   	
   	public void setUp() throws Exception{
  -		locator=new InvokerLocator("sslsocket://localHost:2001");
  +		locator=new InvokerLocator(getTransport() + "://localHost:2001");
   		
   		//the client side connection endpoint
   		configuration = new HashMap();
  @@ -53,8 +53,9 @@
   		Thread.sleep(10000);//let the server fetch his new truststore and refresh serversocket
   		client.disconnect();
   		Thread.sleep(5000);
  -		setUp();//secondPass -> client is not accepted by new truststore
  +
   		try {
  +            setUp();//secondPass -> client is not accepted by new truststore
   			test();//secondPass -> client is not accepted by new truststore
   		} catch (Throwable e) {
   			client.disconnect();
  @@ -73,6 +74,9 @@
   		System.err.println("Server answer is: "+client.invoke("something"));
   	}
   	
  -	
  +	protected String getTransport()
  +	{
  +	   return "sslsocket";
  +	}
   	
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:24:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:24:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh
	...
Message-ID: <E1GzSDd-0004Lk-Dl@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:24:53

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh 
                        TestServer.java
  Log:
  JBREM-650: (1) Added ability to override transport, and (2) made some private variables protected.
  
  Revision  Changes    Path
  1.8       +26 -26    JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestServer.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- TestServer.java	26 Jul 2006 16:28:45 -0000	1.7
  +++ TestServer.java	27 Dec 2006 06:24:53 -0000	1.8
  @@ -8,8 +8,7 @@
   import org.jboss.remoting.callback.InvokerCallbackHandler;
   import org.jboss.remoting.security.SSLSocketBuilder;
   import org.jboss.remoting.transport.Connector;
  -import org.jboss.remoting.transport.sslsocket.SSLSocketServerInvoker;
  -
  +import org.jboss.remoting.transport.socket.SocketServerInvoker;
   import javax.management.MBeanServer;
   import javax.management.MBeanServerFactory;
   import javax.management.ObjectName;
  @@ -36,15 +35,15 @@
    */
   public class TestServer extends ServerTestCase{
   	
  -	private String localHost="127.0.0.1";
  -	private String keyStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverKeyStore";
  -	private String trustStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverTrustStore";
  -	private String keyStorePassword="testpw";
  -	private String trustStorePassword="testpw";
  -	private String port="2001";
  -	private Connector connector;
  -	private MBeanServer server;
  -	private static boolean invocationDone=false;
  +   protected String localHost="127.0.0.1";
  +   protected String keyStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverKeyStore";
  +   protected String trustStorePath="src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverTrustStore";
  +   protected String keyStorePassword="testpw";
  +   protected String trustStorePassword="testpw";
  +   protected String port="2001";
  +   protected Connector connector;
  +   protected MBeanServer server;
  +   protected static boolean invocationDone=false;
   	
   	public void setUp(){	
   		
  @@ -67,7 +66,7 @@
   			configuration.put(SSLSocketBuilder.REMOTING_TRUST_STORE_ALGORITHM, "SunX509");
   		    connector = new Connector(configuration);
   			
  -		    InvokerLocator locator = new InvokerLocator("sslsocket://"+localHost+":"+port);
  +		    InvokerLocator locator = new InvokerLocator(getTransport() + "://"+localHost+":"+port);
   		    connector.setInvokerLocator(locator.getLocatorURI());
   			connector.create();
   			
  @@ -77,8 +76,8 @@
   				ServerSocketFactory svrSocketFactory = createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,trustStorePath);
   				
   				// notice that the invoker has to be explicitly cast to the
  -				// SSLSocketServerInvoker type								
  -				SSLSocketServerInvoker socketSvrInvoker = (SSLSocketServerInvoker) connector.getServerInvoker();
  +				// SocketServerInvoker type								
  +				SocketServerInvoker socketSvrInvoker = (SocketServerInvoker) connector.getServerInvoker();
   				socketSvrInvoker.setServerSocketFactory(svrSocketFactory);
   			}
   			catch(Exception e){
  @@ -104,18 +103,15 @@
   		connector.stop();
   	   }
   	
  -	/**
  -	 * @throws Exception
  -	 */
  +
   	public void test() throws Exception
      {
   		while(!invocationDone)
         {
   			Thread.sleep(1000);
   		}
  -		//((SSLSocketServerInvoker) connector.getServerInvoker()).setNewServerSocketFactory(createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,"src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/certificate/serverTrustStore2"));
         String keyStorePath2 = this.getClass().getResource("certificate/serverTrustStore2").getFile();
  -      ((SSLSocketServerInvoker) connector.getServerInvoker()).setNewServerSocketFactory(createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,keyStorePath2));
  +	   ((SocketServerInvoker) connector.getServerInvoker()).setNewServerSocketFactory(createServerSocketFactory(keyStorePassword,trustStorePassword,keyStorePath,keyStorePath2));
   		Thread.sleep(20000);//let client build up connection a second time
   	}
   
  @@ -133,6 +129,10 @@
         }
      }
   
  +    protected String getTransport()
  +    {
  +       return "sslsocket";
  +    }
   
      /**
   	 * @author Michael Voss
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check
	...
Message-ID: <E1GzSFZ-0004Pp-8N@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:53

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check  
                        InvokerServerTest.java InvokerClientTest.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.3       +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerServerTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- InvokerServerTest.java	16 May 2006 03:45:44 -0000	1.2
  +++ InvokerServerTest.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -30,13 +30,14 @@
    */
   public class InvokerServerTest extends ServerTestCase implements SSLInvokerConstants
   {
  -   private int serverPort = port;
  +   private int serverPort;
      private Connector connector = null;
   
      private static final Logger log = Logger.getLogger(InvokerServerTest.class);
   
      public void init(Map metatdata) throws Exception
      {
  +      serverPort = getPort();
         if (serverPort < 0)
         {
            serverPort = TestUtil.getRandomPort();
  @@ -60,6 +61,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private ServerSocketFactory createServerSocketFactory()
            throws NoSuchAlgorithmException, KeyManagementException, IOException,
                   CertificateException, UnrecoverableKeyException, KeyStoreException
  
  
  
  1.2       +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerClientTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- InvokerClientTest.java	14 May 2006 05:29:59 -0000	1.1
  +++ InvokerClientTest.java	27 Dec 2006 06:26:53 -0000	1.2
  @@ -28,7 +28,7 @@
            String trustStoreFilePath = this.getClass().getResource("../.truststore").getFile();
            System.setProperty("javax.net.ssl.trustStore", trustStoreFilePath);
   
  -         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE);
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + getPort() + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE);
            client = new Client(locator, "mock");
            client.connect();
         }
  @@ -64,6 +64,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private Object makeInvocation(String method, String param) throws Throwable
      {
         Object ret = client.invoke(new NameBasedInvocation(method,
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool
	...
Message-ID: <E1GzSFZ-0004Pz-Cb@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:53

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/socketpool  
                        SocketPoolTestServer.java SocketPoolTestClient.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.2       +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketPoolTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestServer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketPoolTestServer.java	3 Nov 2006 04:02:45 -0000	1.1
  +++ SocketPoolTestServer.java	27 Dec 2006 06:26:53 -0000	1.2
  @@ -38,7 +38,7 @@
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
    * 
  - * @version $Revision: 1.1 $
  + * @version $Revision: 1.2 $
    * <p>
    * Copyright Nov 2, 2006
    * </p>
  @@ -114,7 +114,7 @@
   
      public void setUp() throws Exception
      {
  -      String locatorURI = transport + "://" + host + ":" + port;
  +      String locatorURI = getTransport() + "://" + host + ":" + getPort();
         setupServer(locatorURI);
      }
   
  @@ -155,6 +155,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      /**
       * Simple invocation handler implementation.
       * This is the code that will be called with the invocation payload from the client.
  
  
  
  1.3       +12 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketPoolTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestClient.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SocketPoolTestClient.java	9 Nov 2006 02:23:54 -0000	1.2
  +++ SocketPoolTestClient.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -34,7 +34,7 @@
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
    * 
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    * <p>
    * Copyright Nov 2, 2006
    * </p>
  @@ -57,7 +57,7 @@
         {
            log.warn("EXCEPTIONS ARE EXPECTED");
   
  -         String locatorURI = transport + "://" + host + ":" + port + "/?timeout=1000";
  +         String locatorURI = getTransport() + "://" + host + ":" + getPort() + "/?timeout=1000";
            log.info("Calling remoting server with locator uri of: " + locatorURI);
   
            // create InvokerLocator with the url type string
  @@ -124,6 +124,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      class Invoker extends Thread
      {
         private Client client;
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder
	...
Message-ID: <E1GzSFZ-0004Q9-Ho@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:53

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/builder  
                        SSLSocketInvokerTestClient.java
                        SSLSocketInvokerTestServer.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.5       +7 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLSocketInvokerTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestClient.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- SSLSocketInvokerTestClient.java	20 Jun 2006 17:19:00 -0000	1.4
  +++ SSLSocketInvokerTestClient.java	27 Dec 2006 06:26:53 -0000	1.5
  @@ -44,12 +44,12 @@
         System.setProperty("javax.net.ssl.trustStorePassword", "unit-tests-client");
   //         System.setProperty("javax.net.ssl.trustStorePassword", "secureexample");
   
  -      InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + port);
  +      InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + getPort());
   
         // create callback connector
         Map config = new HashMap();
         config.put(SSLSocketBuilder.REMOTING_SERVER_SOCKET_USE_CLIENT_MODE, "true");
  -      callbackConnector = new Connector(getTransport() + "://" + host + ":" + (port + 5), config);
  +      callbackConnector = new Connector(getTransport() + "://" + host + ":" + (getPort() + 5), config);
         callbackConnector.create();
         callbackConnector.addInvocationHandler("callback", new CallbackInvokerHandler());
         callbackConnector.start();
  @@ -99,6 +99,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private Object makeInvocation(String method, String param) throws Throwable
      {
         Object ret = client.invoke(new NameBasedInvocation(method,
  
  
  
  1.4       +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLSocketInvokerTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestServer.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SSLSocketInvokerTestServer.java	26 May 2006 20:26:56 -0000	1.3
  +++ SSLSocketInvokerTestServer.java	27 Dec 2006 06:26:53 -0000	1.4
  @@ -29,7 +29,7 @@
    */
   public class SSLSocketInvokerTestServer extends ServerTestCase implements SSLInvokerConstants
   {
  -   private int serverPort = port;
  +   private int serverPort;
      private Connector connector = null;
      private SSLSocketBuilder socketBuilder = null;
   
  @@ -37,6 +37,7 @@
   
      public void init() throws Exception
      {
  +      serverPort = getPort();
         if (serverPort < 0)
         {
            serverPort = TestUtil.getRandomPort();
  @@ -117,6 +118,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      protected String getSubsystem()
      {
         return "mock";
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle
	...
Message-ID: <E1GzSFZ-0004QR-OW@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:53

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout/idle    
                        IdleTimeoutClientTest.java
                        IdleTimeoutTestServer.java
                        InactiveIdleTimeoutClientTest.java
                        InactiveIdleTimeoutTestServer.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.3       +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdleTimeoutClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutClientTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IdleTimeoutClientTest.java	3 Nov 2006 16:19:16 -0000	1.2
  +++ IdleTimeoutClientTest.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -18,6 +18,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +
      public static void main(String[] args) throws Throwable
      {
         IdleTimeoutClientTest rt = new IdleTimeoutClientTest();
  @@ -27,7 +32,7 @@
   
      public void testRunClients() throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  
  1.3       +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdleTimeoutTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutTestServer.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IdleTimeoutTestServer.java	3 Nov 2006 16:19:16 -0000	1.2
  +++ IdleTimeoutTestServer.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -14,6 +14,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         IdleTimeoutTestServer rt = new IdleTimeoutTestServer();
  @@ -37,7 +42,7 @@
      public void startServer() throws Exception
      {
   //      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&timeout=60000&backlog=0";
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&backlog=0&timeout=60000&idleTimeout=5";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=2&backlog=0&timeout=60000&idleTimeout=5";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  
  
  
  1.3       +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InactiveIdleTimeoutClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutClientTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- InactiveIdleTimeoutClientTest.java	3 Nov 2006 19:04:40 -0000	1.2
  +++ InactiveIdleTimeoutClientTest.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -18,6 +18,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +
      public static void main(String[] args) throws Throwable
      {
         InactiveIdleTimeoutClientTest rt = new InactiveIdleTimeoutClientTest();
  @@ -33,7 +38,7 @@
   
      public void runClient(String clientId) throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?clientMaxPoolSize=50&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  
  1.3       +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InactiveIdleTimeoutTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutTestServer.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- InactiveIdleTimeoutTestServer.java	3 Nov 2006 19:04:40 -0000	1.2
  +++ InactiveIdleTimeoutTestServer.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -21,6 +21,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         InactiveIdleTimeoutTestServer rt = new InactiveIdleTimeoutTestServer();
  @@ -66,7 +71,7 @@
      public void startServer() throws Exception
      {
   //      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&timeout=60000&backlog=0";
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&backlog=0&timeout=10000&idleTimeout=15";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=2&backlog=0&timeout=10000&idleTimeout=15";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:53 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:53 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic
	...
Message-ID: <E1GzSFZ-0004Qb-Rl@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:53

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/ssl/basic  
                        InvokerClientTest.java InvokerServerTest.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.6       +6 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerClientTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- InvokerClientTest.java	28 Mar 2006 02:43:49 -0000	1.5
  +++ InvokerClientTest.java	27 Dec 2006 06:26:53 -0000	1.6
  @@ -50,7 +50,7 @@
            String trustStoreFilePath = this.getClass().getResource("../.truststore").getFile();
            System.setProperty("javax.net.ssl.trustStore", trustStoreFilePath);
   
  -         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + port);
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://" + host + ":" + getPort());
            client = new Client(locator, "mock");
            client.connect();
         }
  @@ -86,6 +86,11 @@
         return transport;
      }
   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      private Object makeInvocation(String method, String param) throws Throwable
      {
         Object ret = client.invoke(new NameBasedInvocation(method,
  
  
  
  1.11      +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerServerTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- InvokerServerTest.java	16 May 2006 03:45:44 -0000	1.10
  +++ InvokerServerTest.java	27 Dec 2006 06:26:53 -0000	1.11
  @@ -50,13 +50,14 @@
    */
   public class InvokerServerTest extends ServerTestCase implements SSLInvokerConstants
   {
  -   private int serverPort = port;
  +   private int serverPort;
      private Connector connector = null;
   
      private static final Logger log = Logger.getLogger(InvokerServerTest.class);
   
      public void init(Map metatdata) throws Exception
      {
  +      serverPort = getPort();
         if(serverPort < 0)
         {
            serverPort = TestUtil.getRandomPort();
  @@ -80,6 +81,11 @@
         return transport;
      }
      
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      private ServerSocketFactory createServerSocketFactory()
            throws NoSuchAlgorithmException, KeyManagementException, IOException,
                   CertificateException, UnrecoverableKeyException, KeyStoreException
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load
	...
Message-ID: <E1GzSFa-0004Ql-0Q@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/load  
                        SocketLoadTestCase.java
                        PooledConnectionTestCase.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.3       +7 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/SocketLoadTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketLoadTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/SocketLoadTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SocketLoadTestCase.java	21 May 2006 04:47:33 -0000	1.2
  +++ SocketLoadTestCase.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -42,6 +42,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         SocketLoadTestCase rt = new SocketLoadTestCase();
  @@ -67,7 +72,7 @@
   
      public void startServer() throws Exception
      {
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=2&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=2&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  @@ -90,7 +95,7 @@
   
      public void runClient(String clientId) throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/";
  +      String locatorURI = getTransport() + "://localhost:54000/";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  
  1.3       +7 -2      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/PooledConnectionTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PooledConnectionTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/load/PooledConnectionTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- PooledConnectionTestCase.java	23 Aug 2006 03:57:38 -0000	1.2
  +++ PooledConnectionTestCase.java	27 Dec 2006 06:26:53 -0000	1.3
  @@ -23,6 +23,11 @@
   
      private Logger logger = Logger.getRootLogger();
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public static void main(String[] args) throws Throwable
      {
         PooledConnectionTestCase rt = new PooledConnectionTestCase();
  @@ -47,7 +52,7 @@
   
      public void startServer() throws Exception
      {
  -      String locatorURI = "socket://localhost:54000/?maxPoolSize=10&timeout=10000";
  +      String locatorURI = getTransport() + "://localhost:54000/?maxPoolSize=10&timeout=10000";
         InvokerLocator locator = new InvokerLocator(locatorURI);
   
         connector = new Connector();
  @@ -77,7 +82,7 @@
   
      public void runClient(String clientId) throws Throwable
      {
  -      String locatorURI = "socket://localhost:54000/?clientMaxPoolSize=2";
  +      String locatorURI = getTransport() + "://localhost:54000/?clientMaxPoolSize=2";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         Client client = new Client(locator);
         client.connect();
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection
	...
Message-ID: <E1GzSFa-0004R1-7U@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection    
                        SocketTestServer.java
                        SocketConnectionCheckTestClient.java
                        SocketTestClient.java
                        SocketConnectionCheckTestServer.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.6       +14 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestServer.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- SocketTestServer.java	9 Nov 2006 02:50:19 -0000	1.5
  +++ SocketTestServer.java	27 Dec 2006 06:26:54 -0000	1.6
  @@ -26,8 +26,10 @@
   import org.jboss.remoting.InvokerLocator;
   import org.jboss.remoting.ServerInvocationHandler;
   import org.jboss.remoting.ServerInvoker;
  +import org.jboss.remoting.Version;
   import org.jboss.remoting.callback.InvokerCallbackHandler;
   import org.jboss.remoting.transport.Connector;
  +import org.jboss.remoting.transport.socket.SocketServerInvoker;
   
   import javax.management.MBeanServer;
   
  @@ -83,7 +85,7 @@
      {
         //String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
         //String locatorURI = transport + "://" + host + ":" + port + "/?" + InvokerLocator.SERIALIZATIONTYPE + "=jboss";
  -      String locatorURI = transport + "://" + host + ":" + port;
  +      String locatorURI = getTransport() + "://" + host + ":" + getPort();
         setupServer(locatorURI);
      }
   
  @@ -119,6 +121,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      /**
       * Simple invocation handler implementation.
       * This is the code that will be called with the invocation payload from the client.
  
  
  
  1.4       +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionCheckTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestClient.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SocketConnectionCheckTestClient.java	9 Nov 2006 02:50:19 -0000	1.3
  +++ SocketConnectionCheckTestClient.java	27 Dec 2006 06:26:54 -0000	1.4
  @@ -23,7 +23,7 @@
         {
   
   
  -         String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
  +         String locatorURI = getTransport() + "://" + host + ":" + getPort() + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
   
            // create InvokerLocator with the url type string
            // indicating the target remoting server to call upon.
  @@ -66,6 +66,16 @@
   
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
      /**
       * Can pass transport and port to be used as parameters.
       * Valid transports are 'rmi' and 'socket'.
  
  
  
  1.9       +13 -4     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- SocketTestClient.java	12 Nov 2006 04:30:18 -0000	1.8
  +++ SocketTestClient.java	27 Dec 2006 06:26:54 -0000	1.9
  @@ -22,17 +22,16 @@
   package org.jboss.test.remoting.transport.socket.connection;
   
   import junit.framework.TestCase;
  -
  -import org.jboss.logging.Logger;
   import org.jboss.remoting.Client;
   import org.jboss.remoting.InvokerLocator;
  +import org.jboss.remoting.Version;
  +import org.jboss.remoting.transport.socket.SocketServerInvoker;
   
   /**
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
    */
   public class SocketTestClient extends TestCase
   {
  -   private static Logger log = Logger.getLogger(SocketTestClient.class);
      // Default locator values
      private static String transport = "socket";
      private static String host = "localhost";
  @@ -54,7 +53,7 @@
   
            //String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
            //String locatorURI = transport + "://" + host + ":" + port + "/?" + InvokerLocator.SERIALIZATIONTYPE + "=jboss";
  -         String locatorURI = transport + "://" + host + ":" + port;
  +         String locatorURI = getTransport() + "://" + host + ":" + getPort();
   
            // create InvokerLocator with the url type string
            // indicating the target remoting server to call upon.
  @@ -125,4 +124,14 @@
      }
   
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +
   }
  \ No newline at end of file
  
  
  
  1.4       +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketConnectionCheckTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestServer.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SocketConnectionCheckTestServer.java	9 Nov 2006 02:50:19 -0000	1.3
  +++ SocketConnectionCheckTestServer.java	27 Dec 2006 06:26:54 -0000	1.4
  @@ -58,7 +58,7 @@
   
      public void setUp() throws Exception
      {
  -      String locatorURI = transport + "://" + host + ":" + port + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
  +      String locatorURI = getTransport() + "://" + host + ":" + getPort() + "/?" + SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.TRUE;
         setupServer(locatorURI);
      }
   
  @@ -94,6 +94,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return transport;
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return port;
  +   }
  +   
      /**
       * Simple invocation handler implementation.
       * This is the code that will be called with the invocation payload from the client.
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout
	...
Message-ID: <E1GzSFa-0004RB-Aj@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/timeout  
                        TimeoutServerTest.java TimeoutClientTest.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.6       +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TimeoutServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutServerTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- TimeoutServerTest.java	8 Jun 2006 02:29:27 -0000	1.5
  +++ TimeoutServerTest.java	27 Dec 2006 06:26:54 -0000	1.6
  @@ -40,13 +40,19 @@
   public class TimeoutServerTest extends ServerTestCase
   {
   //   private String locatorURI = "socket://localhost:8899/?timeout=3000";
  -   private String locatorURI = "socket://localhost:8899";
  +//   private String locatorURI = "socket://localhost:8899";
      private Connector connector = null;
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
      public void setUp() throws Exception
      {
         Map config = new HashMap();
         config.put("timeout", "3000");
  +      String locatorURI = getTransport() + "://localhost:8899";
         InvokerLocator locator = new InvokerLocator(locatorURI);
         connector = new Connector(locator,  config);
         connector.create();
  
  
  
  1.7       +7 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TimeoutClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutClientTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- TimeoutClientTest.java	8 Jun 2006 02:29:17 -0000	1.6
  +++ TimeoutClientTest.java	27 Dec 2006 06:26:54 -0000	1.7
  @@ -35,12 +35,18 @@
   public class TimeoutClientTest extends TestCase
   {
   //   private String locatorURI = "socket://localhost:8899/?timeout=3000";
  -   private String locatorURI = "socket://localhost:8899";
  +//   private String locatorURI = "socket://localhost:8899";
  +
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
   
      public void testTimeout() throws Exception
      {
         Map config = new HashMap();
         config.put("timeout", "3000");
  +      String locatorURI = getTransport() + "://localhost:8899";
         Client client = new Client(new InvokerLocator(locatorURI), config);
         client.connect();
   
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry
	...
Message-ID: <E1GzSFa-0004RL-Ev@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection/retry  
                        SocketRetryServer.java SocketRetryClient.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.2       +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketRetryServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryServer.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketRetryServer.java	14 May 2006 05:29:57 -0000	1.1
  +++ SocketRetryServer.java	27 Dec 2006 06:26:54 -0000	1.2
  @@ -21,7 +21,7 @@
   
      public void setUp() throws Exception
      {
  -      String locatorUri = "socket://localhost:8888" + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
  +      String locatorUri = getTransport() + "://localhost:" + getPort() + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
                             SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.FALSE;
   
         connector = new Connector(locatorUri);
  @@ -59,6 +59,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return 8888;
  +   }
  +   
      public class TestInvocationHandler implements ServerInvocationHandler
      {
   
  
  
  
  1.2       +10 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketRetryClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryClient.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- SocketRetryClient.java	14 May 2006 05:29:57 -0000	1.1
  +++ SocketRetryClient.java	27 Dec 2006 06:26:54 -0000	1.2
  @@ -66,7 +66,7 @@
   
         public void makeCalls(int sleepTime, int numOfCalls) throws Throwable
         {
  -         InvokerLocator locator = new InvokerLocator("socket://localhost:8888" + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
  +         InvokerLocator locator = new InvokerLocator(getTransport() + "://localhost:" + getPort() + "/?" + SocketClientInvoker.SO_TIMEOUT_FLAG + "=" + 1000 + "&" +
                                                        SocketServerInvoker.CHECK_CONNECTION_KEY + "=" + Boolean.FALSE);
            Client client = new Client(locator);
            client.connect();
  @@ -116,4 +116,13 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return 8888;
  +   }
   }
  
  
  


From ron_sigal at yahoo.com  Wed Dec 27 01:26:54 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Wed, 27 Dec 2006 01:26:54 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/deadlock
	...
Message-ID: <E1GzSFa-0004RS-JR@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/27 01:26:54

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/deadlock 
                        ShutdownDeadlockTestCase.java
  Log:
  JBREM-650:  Added ability to override transport and, in some cases, port.
  
  Revision  Changes    Path
  1.2       +11 -1     JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/deadlock/ShutdownDeadlockTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ShutdownDeadlockTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/deadlock/ShutdownDeadlockTestCase.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ShutdownDeadlockTestCase.java	15 Aug 2006 15:57:08 -0000	1.1
  +++ ShutdownDeadlockTestCase.java	27 Dec 2006 06:26:54 -0000	1.2
  @@ -32,7 +32,7 @@
    */
   public class ShutdownDeadlockTestCase extends TestCase
   {
  -   private static String invokerLocatorUrl = "socket://localhost:7798/?" + InvokerLocator.FORCE_REMOTE + "=true";
  +   private String invokerLocatorUrl = getTransport() + "://localhost:" + getPort() + "/?" + InvokerLocator.FORCE_REMOTE + "=true";
   
      private Client shutdownClient;
      private Client invocationClient;
  @@ -138,6 +138,16 @@
         }
      }
   
  +   protected String getTransport()
  +   {
  +      return "socket";
  +   }
  +   
  +   protected int getPort()
  +   {
  +      return 7798;
  +   }
  +   
      public class TestInvocationHandler implements ServerInvocationHandler
      {
   
  
  
  


From bwang at jboss.com  Wed Dec 27 09:44:57 2006
From: bwang at jboss.com (Ben Wang)
Date: Wed, 27 Dec 2006 09:44:57 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic ...
Message-ID: <E1Gza1Z-0004jk-Fn@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/27 09:44:57

  Modified:    tests-50/functional/org/jboss/cache/pojo/optimistic 
                        LocalTxTest.java
  Log:
  Test case for optimistic locking with List.
  
  Revision  Changes    Path
  1.2       +93 -5     JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic/LocalTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/optimistic/LocalTxTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- LocalTxTest.java	26 Dec 2006 03:41:11 -0000	1.1
  +++ LocalTxTest.java	27 Dec 2006 14:44:57 -0000	1.2
  @@ -69,6 +69,7 @@
         log.info("setUp() ....");
   
         cache = createCache();
  +//      cache = createPessimisticCache();
   
         System.setProperty(Context.INITIAL_CONTEXT_FACTORY, FACTORY);
   
  @@ -117,10 +118,10 @@
         assertEquals("Benoit", p.getName());
         assertEquals("Benoit", p1.getName());
         tx.begin();
  -      p1.setAge(61);
  +      p1.setAge(41);
         tx.commit();
  -      assertEquals(61, p.getAge());
  -      assertEquals(61, p1.getAge());
  +      assertEquals(41, p.getAge());
  +      assertEquals(41, p1.getAge());
      }
   
      public void testModification() throws Exception
  @@ -143,7 +144,94 @@
         assertEquals(p1.getName(), "Benoit");
      }
   
  -   public void testConcurrentSimplePuts() throws Exception
  +   public void testConcurrentSimplePutsI() throws Exception
  +   {
  +      Thread t1 = new Thread("t1")
  +      {
  +         Transaction tx;
  +
  +         public void run()
  +         {
  +            try
  +            {
  +               Person p = createPerson("/person/test6", "p6", 41);
  +               Address addr = new Address();
  +               addr.setCity("San Jose");
  +               List list = new ArrayList();
  +               list.add("English");
  +               list.add("French");
  +               p.setLanguages(list);
  +               UserTransaction tx = getTransaction();
  +               tx.begin();
  +               p.setAddress(addr);
  +               TestingUtil.sleepThread(17000);
  +               tx.commit();
  +            }
  +            catch (RollbackException rollback)
  +            {
  +               ;
  +            }
  +            catch (Exception ex)
  +            {
  +               t1_ex = ex;
  +            }
  +         }
  +      };
  +
  +      Thread t2 = new Thread("t2")
  +      {
  +         Transaction tx;
  +
  +         public void run()
  +         {
  +            UserTransaction tx = null;
  +            try
  +            {
  +               TestingUtil.sleepThread(1000); // give Thread1 time to createPerson
  +               Person p = createPerson("/person/test7", "p7", 40);
  +               Address addr = new Address();
  +               addr.setCity("Santa Clara");
  +               tx = getTransaction();
  +               tx.begin();
  +               p.setAddress(addr);
  +               tx.commit();
  +            }
  +            catch (RollbackException rollback)
  +            {
  +               ;
  +            }
  +            catch (Exception ex)
  +            {
  +//               t2_ex = ex;
  +               try
  +               {
  +                  tx.rollback();
  +               } catch (SystemException e)
  +               {
  +                  e.printStackTrace();
  +                  t2_ex = e;
  +               }
  +            }
  +         }
  +      };
  +
  +      Person p = createPerson("/person/test5", "p5", 30);
  +
  +      t1.start();
  +      t2.start();
  +
  +      t1.join();
  +      t2.join();
  +
  +      // t2 should rollback due to timeout while t2 should succeed
  +      if (t2_ex != null)
  +         fail("Thread2 failed: " + t2_ex);
  +      if (t1_ex != null)
  +         fail("Thread1 failed: " + t1_ex);
  +
  +   }
  +
  +   public void testConcurrentSimplePutsII() throws Exception
      {
         Thread t1 = new Thread("t1")
         {
  @@ -210,7 +298,7 @@
            }
         };
   
  -      Person p = createPerson("/person/test6", "p6", 50);
  +      Person p = createPerson("/person/test6", "p6", 40);
   
         t1.start();
         t2.start();
  
  
  


From c58 at fullmailmarket.com  Wed Dec 27 11:09:04 2006
From: c58 at fullmailmarket.com (FonoIP)
Date: Wed, 27 Dec 2006 13:09:04 -0300
Subject: [jboss-cvs] =?iso-8859-1?q?=DAnase_Usted_tamb=EDen_al_=E9xito_de?=
	=?iso-8859-1?q?_FONOIP=2ECOM?=
Message-ID: <200612271609.kBRG9Exo015392@chief.prod.atl2.jboss.com>

An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061227/56bfb2ed/attachment.html 

From anil.saldhana at jboss.com  Wed Dec 27 11:50:08 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:50:08 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security/2.0.0.snapshot - New
	directory ...
Message-ID: <E1Gzbyi-00073C-Bl@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:50:08

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/security/2.0.0.snapshot added to the repository


From anil.saldhana at jboss.com  Wed Dec 27 11:50:21 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:50:21 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security/2.0.0.snapshot/lib -
	New directory ...
Message-ID: <E1Gzbyv-00073o-UR@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:50:21

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/security/2.0.0.snapshot/lib added to the repository


From anil.saldhana at jboss.com  Wed Dec 27 11:51:03 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:51:03 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security/2.0.0.snapshot  ...
Message-ID: <E1Gzbzb-00074r-Iv@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:51:03

  Added:       jboss/security/2.0.0.snapshot  component-info.xml
  Log:
  security jars for 2.0.0.snapshot
  
  Revision  Changes    Path
  1.1      date: 2006/12/27 16:51:03;  author: asaldhana;  state: Exp;repository.jboss.com/jboss/security/2.0.0.snapshot/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-security-info">
  
     <!-- ============================================================ -->
     <!-- JBoss Security                                           -->
     <!-- ============================================================ -->
     <component id="jboss/security"
                licenseType="lgpl"
                version="2.0.0.snapshot"
                projectHome="http://labs.jboss.org/portal/jbosssecurity/"
                description="JBoss Security">
        <artifact id="jbosssx.jar"/>
        <artifact id="jbosssx-client.jar"/>
        <export>
           <include input="jbosssx.jar"/>
           <include input="jbosssx-client.jar"/>
        </export>
     </component>
  </project>
  
  
  


From anil.saldhana at jboss.com  Wed Dec 27 11:51:03 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:51:03 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security/2.0.0.snapshot/lib ...
Message-ID: <E1Gzbzb-00074z-N9@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:51:03

  Added:       jboss/security/2.0.0.snapshot/lib   jbosssx-client.jar
                        jbosssx.jar
  Log:
  security jars for 2.0.0.snapshot
  
  Revision  Changes    Path
  1.1      date: 2006/12/27 16:51:03;  author: asaldhana;  state: Exp;repository.jboss.com/jboss/security/2.0.0.snapshot/lib/jbosssx-client.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/27 16:51:03;  author: asaldhana;  state: Exp;repository.jboss.com/jboss/security/2.0.0.snapshot/lib/jbosssx.jar
  
  	<<Binary file>>
  
  


From anil.saldhana at jboss.com  Wed Dec 27 11:52:21 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:52:21 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security-spi/2.0.0.snapshot -
	New directory ...
Message-ID: <E1Gzc0r-00077O-Lq@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:52:21

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/security-spi/2.0.0.snapshot added to the repository


From anil.saldhana at jboss.com  Wed Dec 27 11:52:30 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:52:30 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/security-spi/2.0.0.snapshot/lib -
	New directory ...
Message-ID: <E1Gzc10-00077v-FI@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:52:30

  Log:
  Directory /cvsroot/jboss/repository.jboss.com/jboss/security-spi/2.0.0.snapshot/lib added to the repository


From anil.saldhana at jboss.com  Wed Dec 27 11:52:56 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:52:56 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security-spi/2.0.0.snapshot ...
Message-ID: <E1Gzc1Q-00078k-Mv@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:52:56

  Added:       jboss/security-spi/2.0.0.snapshot  component-info.xml
  Log:
  security spi snapshot for 2.0.0.snapshot
  
  Revision  Changes    Path
  1.1      date: 2006/12/27 16:52:56;  author: asaldhana;  state: Exp;repository.jboss.com/jboss/security-spi/2.0.0.snapshot/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="jboss-security-spi-info">
  
     <!-- ============================================================ -->
     <!-- JBoss Security SPI                                           -->
     <!-- ============================================================ -->
     <component id="jboss/security-spi"
                licenseType="lgpl"
                version="2.0.0.snapshot"
                projectHome="http://labs.jboss.org/portal/jbosssecurity/"
                description="JBoss Security">
        <artifact id="jboss-security-spi.jar"/>
        <export>
           <include input="jboss-security-spi.jar"/>
        </export>
     </component>
  </project>
  
  
  


From anil.saldhana at jboss.com  Wed Dec 27 11:52:56 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 11:52:56 -0500
Subject: [jboss-cvs]
	repository.jboss.com/jboss/security-spi/2.0.0.snapshot/lib ...
Message-ID: <E1Gzc1Q-00078q-Pz@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 11:52:56

  Added:       jboss/security-spi/2.0.0.snapshot/lib 
                        jboss-security-spi.jar
  Log:
  security spi snapshot for 2.0.0.snapshot
  
  Revision  Changes    Path
  1.1      date: 2006/12/27 16:52:56;  author: asaldhana;  state: Exp;repository.jboss.com/jboss/security-spi/2.0.0.snapshot/lib/jboss-security-spi.jar
  
  	<<Binary file>>
  
  


From anil.saldhana at jboss.com  Wed Dec 27 12:56:29 2006
From: anil.saldhana at jboss.com (Anil Saldhana)
Date: Wed, 27 Dec 2006 12:56:29 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/security/2.0.0.snapshot/lib ...
Message-ID: <E1Gzd0v-0008IM-Sf@committer01.frg.pub.inap.atl.jboss.com>

  User: asaldhana
  Date: 06/12/27 12:56:29

  Modified:    jboss/security/2.0.0.snapshot/lib  jbosssx.jar
  Log:
  update the jar
  
  Revision  Changes    Path
  1.2       +2106 -1633repository.jboss.com/jboss/security/2.0.0.snapshot/lib/jbosssx.jar
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 13:02:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 13:02:25 -0500
Subject: [jboss-cvs] JBossAS SVN: r59239 -
	projects/security/security-jboss-sx/trunk
Message-ID: <E1Gzd6f-00005s-1i@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-27 13:02:24 -0500 (Wed, 27 Dec 2006)
New Revision: 59239

Modified:
   projects/security/security-jboss-sx/trunk/pom.xml
Log:
comment out the test stuff because maven does not build artifacts until tests pass

Modified: projects/security/security-jboss-sx/trunk/pom.xml
===================================================================
--- projects/security/security-jboss-sx/trunk/pom.xml	2006-12-26 21:15:11 UTC (rev 59238)
+++ projects/security/security-jboss-sx/trunk/pom.xml	2006-12-27 18:02:24 UTC (rev 59239)
@@ -64,15 +64,19 @@
        </pluginRepositories>
        <build>
            <sourceDirectory>src/main</sourceDirectory>
+      <!--
            <testSourceDirectory>src/tests</testSourceDirectory>
            <testOutputDirectory>target/test-classes</testOutputDirectory>
+       -->
            <finalName>${artifactId}</finalName>
            <outputDirectory>output/classes</outputDirectory> 
+       <!--
            <testResources>
              <testResource>
                <directory>src/tests/org/jboss/test</directory>
              </testResource>
            </testResources>
+       -->
            <plugins>
            <!-- define how we want compilation to take place here, we accept most of the defaults but say that we want the optimization flag set, and define the source and target to be 1.4, these setting will be inherited by child projects -->
               <plugin>
@@ -191,30 +195,9 @@
                              </fileset>
                             </copy>
 
-                            <!-- Define the pattern sets for the jbosssx impl -->
-                            <patternset id="jbosssx-includes">
-                               <include name="org/jboss/crypto/**"/>
-                               <include name="org/jboss/security/audit/providers/**"/>
-                               <include name="org/jboss/security/auth/**"/>
-                               <include name="org/jboss/security/authorization/config/**"/>
-                               <include name="org/jboss/security/authorization/modules/**"/>
-                               <include name="org/jboss/security/authorization/sunxacml/**"/>
-                               <include name="org/jboss/security/config/**"/>
-                              <include name="org/jboss/security/jce/**"/>
-                              <include name="org/jboss/security/jndi/**"/>
-                              <include name="org/jboss/security/mapping/config/**"/>
-                              <include name="org/jboss/security/mapping/providers/**"/>
-                              <include name="org/jboss/security/jacc/**"/>
-                              <include name="org/jboss/security/plugins/**"/>
-                              <include name="org/jboss/security/propertyeditor/**"/>
-                             <include name="org/jboss/security/ssl/**"/>
-                           </patternset>
-
                         <!-- Build jbosssx.jar -->
                         <jar jarfile="${basedir}/output/lib/jbosssx.jar" manifest="${basedir}/src/etc/default.mf">
-                           <fileset dir="${basedir}/output/classes">
-                              <patternset refid="jbosssx-includes"/>
-                           </fileset>
+                           <fileset dir="${basedir}/output/classes"/>
                            <fileset dir="${basedir}/src/resources">
                               <include name="dtd/security-policy.dtd"/>
                            </fileset>



From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 13:12:52 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 13:12:52 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1860 -
	trunk/src/main/org/jboss/jms/client/container
Message-ID: <E1GzdGm-0000Fw-5V@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-27 13:12:50 -0500 (Wed, 27 Dec 2006)
New Revision: 1860

Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
Log:
adding attribute to enable/disable the valve

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-24 23:01:01 UTC (rev 1859)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-27 18:12:50 UTC (rev 1860)
@@ -84,8 +84,11 @@
 
    public static final int MAX_RECONNECT_HOP_COUNT = 10;
 
-   public static final int MAX_IO_RETRY_COUNT = 10;
+   public static final int MAX_IO_RETRY_COUNT = 2;
 
+   // Setting this attribute to false will disable the valve
+   public static final boolean INSTALL_VALVE = false;
+
    // Static --------------------------------------------------------
 
    private static boolean trace = log.isTraceEnabled();
@@ -164,11 +167,17 @@
 
       ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
 
-      ((ConnectionState) ((DelegateSupport) cd).getState()).
-         getRemotingConnectionListener().addDelegateListener(new ConnectionFailureListener(cd));
+      // TODO: The valve is optional for now
+      if (INSTALL_VALVE)
+      {
+         installValveAspect(cd, new ValveAspect(cd, this));
+      }
+      else
+      {
+         ((ConnectionState) ((DelegateSupport) cd).getState()).
+            getRemotingConnectionListener().addDelegateListener(new ConnectionFailureListener(cd));
+      }
 
-      //installValveAspect(cd, new ValveAspect(cd, this));
-
       if(trace) { log.trace(this + " got local connection delegate " + cd); }
 
       // Add a connection listener to detect failure; the consolidated remoting connection listener



From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 16:07:42 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 16:07:42 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1861 - in
	trunk/tests/src/org/jboss/test/messaging/tools: . jmx/rmi
Message-ID: <E1Gzfzy-0003T5-Qe@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-27 16:07:40 -0500 (Wed, 27 Dec 2006)
New Revision: 1861

Modified:
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
Log:
Adding method to kill a server and wait until the Kill Thread is finished.

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-27 18:12:50 UTC (rev 1860)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-27 21:07:40 UTC (rev 1861)
@@ -260,6 +260,31 @@
       }
    }
 
+   /** 
+    * Kills the server and wait keep trying any dumb communication until the server is effectively killed.
+    * We had to implement this method as kill will actually schedule a thread that will perform System.exit
+    * after few milliseconds.
+    * We will use this method in places where we need the server killed.
+    * */
+   public static synchronized void killAndWait(int i) throws Exception
+   {
+      Server server = servers[i].getServer();
+      kill(i);
+      try
+      {
+         while(true)
+         {
+            server.ping();
+            log.info("Server still alive... pinging again");
+            Thread.sleep(10);
+         }
+      }
+      catch (Throwable e)
+      {
+         e.printStackTrace();
+      }
+   }
+
    /**
     * This method make sure that all servers that have been implicitely spawned when as a side
     * effect of create() and/or start() are killed. The method is important because a forked

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-27 18:12:50 UTC (rev 1860)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-27 21:07:40 UTC (rev 1861)
@@ -177,6 +177,12 @@
       return true;
    }
 
+
+   public void ping() throws Exception
+   {
+      // noop... do nothing
+   }
+
    public synchronized void kill() throws Exception
    {
       throw new IllegalStateException("Cannot KILL a local server. Consider using stop() instead.");

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-27 18:12:50 UTC (rev 1860)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/RMITestServer.java	2006-12-27 21:07:40 UTC (rev 1861)
@@ -157,6 +157,12 @@
       new Thread(new VMKiller(), "VM Killer").start();
    }
 
+
+   public void ping() throws Exception
+   {
+      //noop - nothing to be done
+   }
+
    public ObjectName deploy(String mbeanConfiguration) throws Exception
    {
       return server.deploy(mbeanConfiguration);

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-27 18:12:50 UTC (rev 1860)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/Server.java	2006-12-27 21:07:40 UTC (rev 1861)
@@ -62,6 +62,14 @@
    void kill() throws Exception;
 
    /**
+    * When kill is called you are actually schedulling the server to be killed in few milliseconds.
+    * There are certain cases where we need to assure the server was really killed.
+    * For that we have this dumb operation where we can verify if the server still alive or not.
+    * @throws Exception
+    */
+   void ping() throws Exception;
+
+   /**
     * Deploys and registers a service based on the MBean service descriptor element, specified as
     * a String. Supports XMBeans. The implementing class and the ObjectName are inferred from the
     * mbean element. If there are configuration attributed specified in the deployment descriptor,



From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 16:09:36 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 16:09:36 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1862 -
	trunk/tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1Gzg1o-0003TQ-LM@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-27 16:09:35 -0500 (Wed, 27 Dec 2006)
New Revision: 1862

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
Log:
Fixing the test, as we need to wait until the server was killed

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-27 21:07:40 UTC (rev 1861)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-27 21:09:35 UTC (rev 1862)
@@ -74,12 +74,21 @@
 
          // kill node 1
 
-         ServerManagement.kill(1);
 
          log.info("########");
          log.info("######## KILLED NODE 1");
          log.info("########");
 
+         ServerManagement.killAndWait(1);
+         try
+         {
+            ic[1].lookup("queue"); // looking up anything
+            fail("The server still alive, kill didn't work yet");
+         }
+         catch (Exception e)
+         {
+         }
+
          // TODO - this shouldn't be necessary if we have the client valve in place
          log.info("Sleeping for 60 sec");
          Thread.sleep(60000);



From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 16:16:47 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 16:16:47 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1863 -
	trunk/tests/src/org/jboss/test/messaging/tools
Message-ID: <E1Gzg8l-0003dN-60@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-27 16:16:46 -0500 (Wed, 27 Dec 2006)
New Revision: 1863

Modified:
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
Log:
Removing dumb log statement

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-27 21:09:35 UTC (rev 1862)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-27 21:16:46 UTC (rev 1863)
@@ -281,7 +281,7 @@
       }
       catch (Throwable e)
       {
-         e.printStackTrace();
+        // e.printStackTrace();
       }
    }
 



From Shane_Bryzak at symantec.com  Wed Dec 27 20:46:04 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Wed, 27 Dec 2006 20:46:04 -0500
Subject: [jboss-cvs] jboss-seam/doc/reference/en/modules  ...
Message-ID: <E1GzkLM-0008Dv-Vz@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/27 20:46:04

  Modified:    doc/reference/en/modules  security.xml
  Log:
  security docs
  
  Revision  Changes    Path
  1.2       +112 -11   jboss-seam/doc/reference/en/modules/security.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: security.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/doc/reference/en/modules/security.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- security.xml	27 Dec 2006 06:06:59 -0000	1.1
  +++ security.xml	28 Dec 2006 01:46:04 -0000	1.2
  @@ -42,11 +42,11 @@
   
   	    <para>
   	      The next step is to configure roles.  While this step is optional (it is possible for a user to
  -	      belong to a role even if it is not configured in <literal>security-config.xml</literal>), it is
  -	      necessary if either 1) explicit permissions are required by your application, or 2) roles require
  -	      membership of other roles.	Create a file called <literal>security-config.xml</literal>, which goes in
  -	      the <literal>META-INF</literal> directory of the Seam application's jar file.  Here's an example
  -	      <literal>security-config.xml</literal> file with a few roles defined.
  +	      belong to a role even if it is not configured here), it is necessary if either 1) explicit permissions 
  +	      are required by your application, or 2) roles require membership of other roles.	Create a file called 
  +	      <literal>security-config.xml</literal>, which goes in the <literal>META-INF</literal> directory of the 
  +	      Seam application's jar file.  Here's an example <literal>security-config.xml</literal> file with a few 
  +	      roles defined.
   	    </para>
   
   	    <programlisting>
  @@ -92,7 +92,7 @@
   
   	    <para>
   	      In the above example, we can see that there are four distinct roles: <literal>admin</literal>,
  -	      <literal>superuser</literal>, <literal>user</literal> and <literal>guest</literal>.  Technically
  +	      <literal>superuser</literal>, <literal>user</literal> and <literal>guest</literal>.  Strictly
   	      speaking, the <literal>guest</literal> entry is redundant as it declares no permissions nor contains
   	      any memberships of other roles.  What is most of interest here are the permissions and role memberships,
   	      which are explained in further detail as follows.
  @@ -102,11 +102,11 @@
   	      <title>Explicit Permissions</title>
   	      <para>
   	        These are permissions which are explicitly granted to members of a role.  Explicit permissions are
  -	        used to address simple security concerns, such as <emphasis>may this user create a new customer
  -	        record?</emphasis>, or <emphasis>may this user view customer details?</emphasis>.  While it is
  +	        used to address simple security concerns, such as <emphasis>"may this user create a new customer
  +	        record?"</emphasis>, or <emphasis>"may this user view customer details?"</emphasis>.  While it is
   	        possible to perform a more complex contextual-based decision to grant a specific permission or not,
   	        explicit permissions allow simple decision-less permissions to be easily granted to certain groups
  -	        of users.
  +	        of users.  How these permissions are used will be explained further on.
   	      </para>
   	    </sect3>
   
  @@ -123,8 +123,8 @@
   	      </para>
   
   	      <para>
  -	        The following table shows the permissions granted to each role based on the above 
  -	        <literal>security-config.xml</literal> example.
  +	        The following table illustrates this concept by showing the permissions granted to each role based 
  +	        on the above <literal>security-config.xml</literal> example.
   	      </para>
   
   	      <table>
  @@ -301,6 +301,107 @@
           </table>
   
   	    </sect3>
  +	    
  +	    <sect3>
  +	      <title>Page security</title>
  +	      
  +	      <para>
  +	        Page security is used to restrict direct access to web resources based on the user's roles. It
  +	        requires the Seam security filter (a servlet filter - see the next section) to be installed.  
  +	        To configure page security, <literal>security-constraint</literal> entries must be created within 
  +	        <literal>security-config.xml</literal> to control which web resources are accessible to which roles.
  +	        The restricted web resources are defined using a url-pattern expression.  The following example
  +	        demonstrates how all of the <literal>*.seam</literal> resources in the <literal>/secure</literal>
  +	        directory are restricted to users in the <literal>admin</literal> role.
  +	      </para>
  +	      
  +	      <programlisting>
  +	        <![CDATA[
  +<security-config>
  +	        
  +  <security-constraint>
  +    <web-resource-collection>
  +      <web-resource-name>Secure Page</web-resource-name>
  +      <url-pattern>/secure/*.seam</url-pattern>
  +    </web-resource-collection>
  +    
  +    <auth-constraint>
  +      <role-name>admin</role-name>
  +    </auth-constraint>
  +  </security-constraint>	        
  +  
  +</security-config>  
  +	        ]]>
  +	      </programlisting>
  +	      
  +	      <para>
  +	        This configuration may look familiar, because it is the same format defined by the servlet 
  +	        specification, and as such follows the same wildcard conventions.  I.e. at the end of a pattern, 
  +	        <literal>/*</literal> matches any sequence of characters from that point forward, and the pattern
  +	        <literal>*.extension</literal> matches any resources ending with <literal>.extension</literal>. An
  +	        asterisk in any other position is not a wildcard.
  +	      </para>   
  +	      
  +	      <para>
  +	        So what happens when a user tries to access a page that they don't have the necessary rights for? 
  +	        By default, the security filter redirects these requests to the <literal>/securityError.seam</literal>
  +	        page.  This can be configured though by overriding the <literal>securityErrorPage</literal> property
  +	        of the <literal>SecurityConfiguration</literal> component in <literal>components.xml</literal>:
  +	      </para>
  +	      
  +	      <programlisting>
  +	        <![CDATA[
  +  <component class="org.jboss.seam.security.config.SecurityConfiguration">
  +    <property name="securityErrorPage">/security/generalSecurityError.seam</property>
  +  </component>
  +	        ]]>	      
  +	      </programlisting>
  +	      
  +	    </sect3>	    
  +    </sect2>
  +
  +    <sect2>
  +      <title>Seam Security Filter</title>
  +    
  +      <para>
  +        The Seam security filter is a servlet filter that provides page security features.  It is an optional
  +        component in that if your application does not require page security, then there is no requirement to
  +        install the security filter.  To configure which pages are secure, see the previous section on page
  +        security.  To configure the security filter, add the following entries to <literal>web.xml</literal>:
  +      </para>
  +      
  +      <programlisting>
  +        <![CDATA[
  +    <!-- Seam security filter -->
  +    
  +    <filter>
  +      <filter-name>Seam Security Filter</filter-name>
  +      <filter-class>org.jboss.seam.security.filter.SeamSecurityFilter</filter-class>
  +    </filter>
  +    
  +    <filter-mapping>
  +      <filter-name>Seam Security Filter</filter-name>
  +      <url-pattern>*.seam</url-pattern>
  +    </filter-mapping>        
  +        ]]>
  +      </programlisting>
  +    </sect2>    
  +    
  +    <sect2>
  +      <title>security-rules.drl</title>
  +      
  +      <para>
  +        This file also goes into the Seam application's <literal>META-INF</literal> directory.  It contains
  +        all of the security rules 
  +      </para>
  +      
  +      <sect3>
  +        <title>Establishing a default security policy</title>
  +        
  +        <para>
  +        
  +        </para>
  +      </sect3>
       </sect2>
   
     </sect1>
  
  
  


From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 23:02:34 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 23:02:34 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1864 - in trunk:
	src/main/org/jboss/jms/client/container
	tests/src/org/jboss/test/messaging/jms/clustering
Message-ID: <E1GzmTS-0002CW-Fr@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-27 23:02:30 -0500 (Wed, 27 Dec 2006)
New Revision: 1864

Added:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java
Removed:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
Modified:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
Log:
Enabling Valve, changing FailoverTest and renaming ValveTest to HAStressTest

Modified: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-27 21:16:46 UTC (rev 1863)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-28 04:02:30 UTC (rev 1864)
@@ -87,7 +87,7 @@
    public static final int MAX_IO_RETRY_COUNT = 2;
 
    // Setting this attribute to false will disable the valve
-   public static final boolean INSTALL_VALVE = false;
+   public static final boolean INSTALL_VALVE = true;
 
    // Static --------------------------------------------------------
 

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-27 21:16:46 UTC (rev 1863)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-28 04:02:30 UTC (rev 1864)
@@ -89,10 +89,6 @@
          {
          }
 
-         // TODO - this shouldn't be necessary if we have the client valve in place
-         log.info("Sleeping for 60 sec");
-         Thread.sleep(60000);
-
          // we must receive the message
 
          TextMessage tm = (TextMessage)c1.receive(1000);

Copied: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java (from rev 1859, trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java)
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-24 23:01:01 UTC (rev 1859)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java	2006-12-28 04:02:30 UTC (rev 1864)
@@ -0,0 +1,279 @@
+/*
+   * JBoss, Home of Professional Open Source
+   * Copyright 2005, JBoss Inc., and individual contributors as indicated
+   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
+import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.jms.client.JBossConnectionFactory;
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.logging.Logger;
+import javax.jms.MessageConsumer;
+import javax.jms.Session;
+import javax.jms.Destination;
+import javax.jms.Connection;
+import javax.jms.MessageProducer;
+import javax.jms.Message;
+import javax.jms.DeliveryMode;
+import java.util.ArrayList;
+import java.util.Iterator;
+
+/**
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @version <tt>$Revision:$</tt>
+ *          <p/>
+ *          $Id:$
+ */
+public class HAStressTest extends ClusteringTestBase
+{
+
+   int NUMBER_OF_PRODUCER_THREADS=1;
+   int NUMBER_OF_CONSUMER_THREADS=1;
+
+   public HAStressTest(String name)
+   {
+      super(name);
+   }
+
+   int messageCounterConsumer = 0;
+   int messageCounterProducer = 0;
+
+
+   Object lockReader = new Object();
+   Object lockWriter = new Object();
+   Object semaphore = new Object();
+
+   boolean shouldStop = false;
+
+
+   class LocalThreadConsumer extends Thread
+   {
+      private final Logger log = Logger.getLogger(this.getClass());
+
+      int id;
+      MessageConsumer consumer;
+      Session session;
+
+      public LocalThreadConsumer(int id, Session session, Destination destination) throws Exception
+      {
+         super("LocalThreadConsumer-" + id);
+         consumer = session.createConsumer(destination);
+         this.session = session;
+         this.id = id;
+      }
+
+
+      public void run()
+      {
+         try
+         {
+            synchronized (semaphore)
+            {
+               semaphore.wait();
+            }
+
+            int counter = 0;
+            while (true)
+            {
+               Message message = consumer.receive(5000);
+               if (message == null && shouldStop)
+               {
+                  break;
+               }
+               if (message != null)
+               {
+                  synchronized (lockReader)
+                  {
+                     messageCounterConsumer++;
+                  }
+                  log.trace("ReceiverID=" + id + " received message " + message);
+                  if (counter++ % 10 == 0)
+                  {
+                     //log.info("Commit on id=" + id);
+                     //session.commit();
+                  }
+               }
+            }
+            //session.commit();
+         }
+         catch (Exception e)
+         {
+            log.info("Caught exception... finishing Thread " + id, e);
+         }
+      }
+   }
+
+   class LocalThreadProducer extends Thread
+   {
+      private final Logger log = Logger.getLogger(this.getClass());
+
+      MessageProducer producer;
+      Session session;
+      int id;
+
+      public LocalThreadProducer(int id, Session session, Destination destination) throws Exception
+      {
+         super("LocalThreadProducer-" + id);
+         this.session = session;
+         producer = session.createProducer(destination);
+         producer.setDeliveryMode(DeliveryMode.PERSISTENT);
+         this.id = id;
+      }
+
+      public void run()
+      {
+         try
+         {
+            synchronized (semaphore)
+            {
+               semaphore.wait();
+            }
+
+            int counter = 0;
+            while (!shouldStop)
+            {
+               log.trace("Producer ID=" + id + " send message");
+               producer.send(session.createTextMessage("Message from producer " + id + " counter=" + (counter)));
+
+               synchronized (lockWriter)
+               {
+                  messageCounterProducer++;
+               }
+
+               if (counter++ % 5 == 0)
+               {
+                  //log.info("Committing message");
+                  //session.commit();
+               }
+            }
+
+         }
+         catch (Exception e)
+         {
+            log.info("Caught exception... finishing Thread " + id, e);
+         }
+      }
+   }
+
+   /**
+    * This test will open several Consumers at the same Connection and it will kill the server, expecting failover
+    * to happen inside the Valve
+    */
+   public void testMultiThreadFailover() throws Exception
+   {
+      // This test will be disabled until we implement the valve
+      //JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
+
+      Connection conn1 = cf.createConnection();
+      Connection conn2 = cf.createConnection();
+      Connection conn3 = cf.createConnection();
+
+      log.info("Created connections");
+
+      checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
+
+      Connection conn = getConnection(new Connection[]{conn1, conn2, conn3}, 1);
+      conn.start();
+
+      for (int i = 0; i < 3; i++)
+      {
+         JBossConnection connTest = (JBossConnection) getConnection(new Connection[]{conn1, conn2, conn3}, i);
+
+         String locator = ((ClientConnectionDelegate) connTest.getDelegate()).getRemotingConnection().
+            getInvokingClient().getInvoker().getLocator().getLocatorURI();
+
+         log.info("Server " + i + " has locator=" + locator);
+
+      }
+
+
+      ArrayList threadList = new ArrayList();
+
+      for (int i = 0; i < NUMBER_OF_PRODUCER_THREADS; i++)
+      {
+         threadList.add(new LocalThreadProducer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
+      }
+
+      for (int i = 0; i < NUMBER_OF_CONSUMER_THREADS; i++)
+      {
+         threadList.add(new LocalThreadConsumer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
+      }
+
+      for (Iterator iter = threadList.iterator(); iter.hasNext();)
+      {
+         Thread t = (Thread) iter.next();
+         t.start();
+      }
+
+      Thread.sleep(1000);
+      synchronized (semaphore)
+      {
+         semaphore.notifyAll();
+      }
+
+      Thread.sleep(30000);
+
+      log.info("Killing server 1");
+      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed");
+      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed", 2);
+      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+
+      ServerManagement.kill(1);
+
+      Thread.sleep(50000);
+      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+      shouldStop = true;
+
+      for (Iterator iter = threadList.iterator(); iter.hasNext();)
+      {
+         Thread t = (Thread) iter.next();
+         t.join();
+      }
+
+      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
+
+      assertEquals(messageCounterProducer, messageCounterConsumer);
+
+      conn1.close();
+      conn2.close();
+      conn3.close();
+
+   }
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      nodeCount = 3;
+
+      super.setUp();
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+}

Deleted: trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-27 21:16:46 UTC (rev 1863)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/ValveTest.java	2006-12-28 04:02:30 UTC (rev 1864)
@@ -1,264 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.test.messaging.jms.clustering;
-
-import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
-import org.jboss.test.messaging.tools.ServerManagement;
-import org.jboss.jms.client.JBossConnectionFactory;
-import org.jboss.jms.client.JBossConnection;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.logging.Logger;
-import javax.jms.MessageConsumer;
-import javax.jms.Session;
-import javax.jms.Destination;
-import javax.jms.Connection;
-import javax.jms.MessageProducer;
-import javax.jms.Message;
-import java.util.ArrayList;
-import java.util.Iterator;
-
-/**
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
- */
-public class ValveTest extends ClusteringTestBase
-{
-
-   public ValveTest(String name)
-   {
-      super(name);
-   }
-
-   int messageCounterConsumer = 0;
-   int messageCounterProducer = 0;
-
-
-   Object lockReader = new Object();
-   Object lockWriter = new Object();
-   Object semaphore = new Object();
-
-   boolean shouldStop = false;
-
-
-   class LocalThreadConsumer extends Thread
-   {
-      private final Logger log = Logger.getLogger(this.getClass());
-
-      int id;
-      MessageConsumer consumer;
-      Session session;
-
-      public LocalThreadConsumer(int id, Session session, Destination destination) throws Exception
-      {
-         consumer = session.createConsumer(destination);
-         this.session = session;
-         this.id = id;
-      }
-
-
-      public void run()
-      {
-         try
-         {
-            synchronized (semaphore)
-            {
-               semaphore.wait();
-            }
-
-            int counter = 0;
-            while (true)
-            {
-               Message message = consumer.receive(5000);
-               if (message == null && shouldStop)
-               {
-                  break;
-               }
-               if (message != null)
-               {
-                  synchronized (lockReader)
-                  {
-                     messageCounterConsumer++;
-                  }
-                  log.trace("ReceiverID=" + id + " received message " + message);
-                  if (counter++ % 10 == 0)
-                  {
-                     //log.info("Commit on id=" + id);
-                     //session.commit();
-                  }
-               }
-            }
-            //session.commit();
-         }
-         catch (Exception e)
-         {
-            log.info("Caught exception... finishing Thread " + id, e);
-         }
-      }
-   }
-
-   class LocalThreadProducer extends Thread
-   {
-      private final Logger log = Logger.getLogger(this.getClass());
-
-      MessageProducer producer;
-      Session session;
-      int id;
-
-      public LocalThreadProducer(int id, Session session, Destination destination) throws Exception
-      {
-         this.session = session;
-         producer = session.createProducer(destination);
-         this.id = id;
-      }
-
-      public void run()
-      {
-         try
-         {
-            synchronized (semaphore)
-            {
-               semaphore.wait();
-            }
-
-            int counter = 0;
-            while (!shouldStop)
-            {
-               log.trace("Producer ID=" + id + " send message");
-               producer.send(session.createTextMessage("Message from producer " + id + " counter=" + (counter)));
-
-               synchronized (lockWriter)
-               {
-                  messageCounterProducer++;
-               }
-
-               if (counter++ % 5 == 0)
-               {
-                  //log.info("Committing message");
-                  //session.commit();
-               }
-            }
-
-         }
-         catch (Exception e)
-         {
-            log.info("Caught exception... finishing Thread " + id, e);
-         }
-      }
-   }
-
-   /**
-    * This test will open several Consumers at the same Connection and it will kill the server, expecting failover
-    * to happen inside the Valve
-    */
-   public void testMultiThreadFailover() throws Exception
-   {
-       // This test will be disabled until we implement the valve
-//      JBossConnectionFactory factory = (JBossConnectionFactory) ic[1].lookup("/ConnectionFactory");
-//
-//      Connection conn1 = cf.createConnection();
-//      Connection conn2 = cf.createConnection();
-//      Connection conn3 = cf.createConnection();
-//
-//      log.info("Created connections");
-//
-//      checkConnectionsDifferentServers(new Connection[]{conn1, conn2, conn3});
-//
-//      Connection conn = getConnection(new Connection[]{conn1, conn2, conn3}, 1);
-//      conn.start();
-//
-//      for (int i = 0; i < 3; i++)
-//      {
-//         JBossConnection connTest = (JBossConnection)getConnection(new Connection[]{conn1, conn2, conn3}, i);
-//
-//         String locator = ((ClientConnectionDelegate) connTest.getDelegate()).getRemotingConnection().
-//            getInvokingClient().getInvoker().getLocator().getLocatorURI();
-//
-//         log.info("Server " + i + " has locator=" + locator);
-//
-//      }
-//
-//
-//      ArrayList list = new ArrayList();
-//
-//      for (int i = 0; i < 5; i++)
-//      {
-//         list.add(new LocalThreadProducer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
-//         list.add(new LocalThreadConsumer(i, conn.createSession(false, Session.AUTO_ACKNOWLEDGE), queue[1]));
-//      }
-//
-//      for (Iterator iter = list.iterator(); iter.hasNext();)
-//      {
-//         Thread t = (Thread) iter.next();
-//         t.start();
-//      }
-//
-//      Thread.sleep(1000);
-//      synchronized (semaphore)
-//      {
-//         semaphore.notifyAll();
-//      }
-//
-//      Thread.sleep(30000);
-//
-//      log.info("Killing server 1");
-//      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed");
-//      ServerManagement.log(ServerManagement.INFO, "Server 1 will be killed", 2);
-//      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
-//
-//      ServerManagement.kill(1);
-//
-//      Thread.sleep(50000);
-//      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
-//      shouldStop = true;
-//
-//      for (Iterator iter = list.iterator(); iter.hasNext();)
-//      {
-//         Thread t = (Thread) iter.next();
-//         t.join();
-//      }
-//
-//      log.info("messageCounterConsumer=" + messageCounterConsumer + ", messageCounterProducer=" + messageCounterProducer);
-//
-//      assertEquals(messageCounterProducer, messageCounterConsumer);
-//
-   }
-
-   // Protected -----------------------------------------------------
-
-   protected void setUp() throws Exception
-   {
-      nodeCount = 3;
-
-      //super.setUp();
-
-      log.debug("setup done");
-   }
-
-   protected void tearDown() throws Exception
-   {
-      //super.tearDown();
-   }
-
-}



From jboss-cvs-commits at lists.jboss.org  Wed Dec 27 23:20:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Wed, 27 Dec 2006 23:20:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1865 - in trunk:
	src/main/org/jboss/messaging/util
	tests/src/org/jboss/test/messaging/util
Message-ID: <E1Gzml2-0002SZ-TI@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-27 23:20:39 -0500 (Wed, 27 Dec 2006)
New Revision: 1865

Removed:
   trunk/src/main/org/jboss/messaging/util/Valve.java
   trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java
   trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
Modified:
   trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java
Log:
Removing non used classes and tests

Deleted: trunk/src/main/org/jboss/messaging/util/Valve.java
===================================================================
--- trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-28 04:02:30 UTC (rev 1864)
+++ trunk/src/main/org/jboss/messaging/util/Valve.java	2006-12-28 04:20:39 UTC (rev 1865)
@@ -1,169 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.messaging.util;
-
-import org.jboss.logging.Logger;
-
-
-/**
- * This class is used to guarantee only one thread will be performing a given function, and if any other
- * thread tries to execute the same functionality it will just ignored
- * <pre>
-     Valve valve = new Valve();
-        if (valve.open())
-        {
-             try
-             {
-                doSomething();
-             }
-             finally
-             {
-                valve.close();
-             }
-        }
-        else
-        {
-             System.out.println("Nothing to be done
-        }
-  </pre>
-
-   <p>Notice that you can call close only once, so only call close if you were able to open the valve.</p>
-   <p>After its usage if you decide to reset you should just create a new Valve in a safe synchronized block, so
-        if any other thread still using the variable you do it in a safe way </p>
-
- * @see org.jboss.test.messaging.util.VeryBasicValveTest
- * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
- *  */
-public class Valve
-{
-   private static final Logger log = Logger.getLogger(Valve.class);
-   private boolean trace = log.isTraceEnabled();
-
-   boolean opened;
-   boolean closed;
-
-   Thread threadOwner;
-
-   int refereceCountOpen = 0;
-
-
-   public synchronized boolean isOpened()
-   {
-      return opened;
-   }
-
-   /**
-    * If the Valve is opened, will wait until the valve is closed
-    */
-   public synchronized boolean isOpened(boolean wait) throws Exception
-   {
-      if (wait && opened)
-      {
-         if (!closed && threadOwner != Thread.currentThread())
-         {
-            if (trace) log.trace("threadOwner= " + threadOwner + " and currentThread=" + Thread.currentThread());
-            if (trace) log.trace("Waiting valve to be closed");
-            this.wait();
-            if (trace) log.trace("Valve was closed");
-         } else
-         {
-            if (trace) log.trace("This is ThreadOwner, so Valve won't wait");
-         }
-         return opened;
-      } else
-      {
-         return false;
-      }
-
-   }
-
-   public boolean open() throws Exception
-   {
-      return open(true);
-   }
-
-   public synchronized boolean open(boolean wait) throws Exception
-   {
-      if (threadOwner == Thread.currentThread())
-      {
-         if (trace) log.trace("Valve was opened again by thread owner");
-         refereceCountOpen++;
-         return true;
-      }
-      // already opened? then needs to wait to be closed
-      if (opened)
-      {
-         if (trace) log.trace("Valve being opened and time.wait");
-         // if not closed yet, will wait to be closed
-         if (!closed)
-         {
-            if (wait)
-            {
-               this.wait();
-            }
-         }
-         return false;
-      } else
-      {
-         if (trace) log.trace("Valve being opened and this thread is the owner for this lock");
-         refereceCountOpen++;
-         opened = true;
-         threadOwner = Thread.currentThread();
-         return true;
-      }
-   }
-
-   public synchronized void close()
-   {
-      if (!opened)
-      {
-         throw new IllegalStateException("Open must be called first");
-      }
-      if (closed)
-      {
-         log.warn("Valve was already closed", new Exception());
-      }
-      refereceCountOpen--;
-      if (refereceCountOpen == 0)
-      {
-         if (trace) log.trace("Closing Valve");
-         closed = true;
-         notifyAll();
-      } else
-      {
-         if (trace) log.trace("Valve.close called but there referenceCountOpen=" + refereceCountOpen);
-      }
-   }
-
-   public synchronized void reset()
-   {
-      if (opened && !closed)
-      {
-         close();
-      }
-      opened = false;
-      closed = false;
-      threadOwner = null;
-      refereceCountOpen = 0;
-   }
-}

Modified: trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java	2006-12-28 04:02:30 UTC (rev 1864)
+++ trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicReadWriteTest.java	2006-12-28 04:20:39 UTC (rev 1865)
@@ -30,13 +30,8 @@
 
 /**
  *
- * ValidateValveLogicReadWriteTest and ValidateValveLogicValveTest were written
- * to validate lock mechanism to be used on ValveAspect.
+ * I have written this test just to validate the ReadWriteLock options I had while writing the valve feature on HAAspect
  *
- * ValidateValveLogicTestValveTest uses org.jboss.messaging.util.Valve which avoid locking on reading threads
- * ValidateValveLogicReadWriteTest uses oswego.concurrent.ReadWriteLock which adds synchronization into reading threads also
- *
- *
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @version <tt>$Revision:$</tt>
  *          <p/>

Deleted: trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java	2006-12-28 04:02:30 UTC (rev 1864)
+++ trunk/tests/src/org/jboss/test/messaging/util/ValidateValveLogicValveTest.java	2006-12-28 04:20:39 UTC (rev 1865)
@@ -1,202 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.test.messaging.util;
-
-import junit.framework.TestCase;
-import org.jboss.logging.Logger;
-import org.jboss.messaging.util.Valve;
-
-/**
- *
- * There is a relevant comment into <@link ValidateValveLogicReadWriteTest> 
- * @see ValidateValveLogicReadWriteTest
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
- */
-public class ValidateValveLogicValveTest extends TestCase
-{
-   private static Logger log = Logger.getLogger(ValidateValveLogicValveTest.class);
-
-   boolean useCounterA;
-
-   public synchronized boolean isUseCounterA()
-   {
-      return useCounterA;
-   }
-
-   public synchronized void setUseCounterA(boolean useCounterA)
-   {
-      this.useCounterA = useCounterA;
-   }
-
-
-   boolean keepRunning=true;
-
-   long counterA = 0;
-   long counterB = 0;
-
-   public synchronized void addCounterA()
-   {
-      counterA++;
-   }
-
-   public synchronized void addCounterB()
-   {
-      counterB++;
-   }
-
-
-   public synchronized long getCounterA()
-   {
-      return counterA;
-   }
-
-   public synchronized long getCounterB()
-   {
-      return counterB;
-   }
-
-   Valve valve = new Valve();
-
-   boolean started=false;
-   private Object startSemaphore = new Object();
-
-
-   public void testValveLogic() throws Exception
-   {
-      ValidateValveLogicValveTest.ThreadRead readThreads [] = new ValidateValveLogicValveTest.ThreadRead[1000];
-      for (int i=0; i<readThreads.length; i++)
-      {
-         readThreads[i] = new ValidateValveLogicValveTest.ThreadRead(i);
-      }
-
-      for (int i=0; i<readThreads.length; i++)
-      {
-         readThreads[i].start();
-      }
-
-      synchronized (startSemaphore)
-      {
-         started=true;
-         startSemaphore.notifyAll();
-      }
-
-
-      log.info("Sleeping 10 seconds");
-      Thread.sleep(10000);
-
-      log.info("Acquiring write lock");
-      valve.open();
-
-      // Time to wait current calls to finish
-      // As valve doesn't need synchronization on running threads,
-      // this sleep is necessary to wait everybody to be on the waiting condition.
-      // And this is meant to be this way. We don't want to stop threads ot calls that are already working,
-      // We want to stop new ones only 
-      Thread.sleep(1000);
-
-      setUseCounterA(false);
-
-      long counterAOriginal = getCounterA();
-      long counterBOriginal = getCounterB();
-
-
-      log.info ("Waiting 5 seconds");
-      Thread.sleep(5000);
-
-      assertEquals(counterAOriginal, getCounterA());
-      assertEquals(counterBOriginal, getCounterB());
-
-      valve.reset();
-
-      valve.isOpened(true);
-
-      log.info("Acquiring read lock");
-
-      counterBOriginal = getCounterB();
-
-      log.info ("Waiting 5 seconds");
-      Thread.sleep(5000);
-
-      log.info ("Threads produced " + (getCounterB() - counterBOriginal));
-      assertEquals(counterAOriginal, getCounterA());
-      assertTrue(getCounterB()>counterBOriginal);
-
-      keepRunning = false;
-
-
-      for (int i=0; i<readThreads.length; i++)
-      {
-         readThreads[i].join();
-      }
-
-   }
-
-   // multiple threads opening/closing a thread.
-   // only one should be able to open it
-   public class ThreadRead extends Thread
-   {
-      int threadId;
-      public ThreadRead(int threadId)
-      {
-         this.threadId = threadId;
-      }
-      public void run()
-      {
-         try
-         {
-            log.info("Starting Thread " + threadId);
-            synchronized (startSemaphore)
-            {
-               if (!started)
-               {
-                  startSemaphore.wait();
-               }
-            }
-
-            while (keepRunning)
-            {
-               valve.isOpened(true);
-               if (isUseCounterA())
-               {
-                  //log.info("Thread " + threadId + " adding A");
-                  addCounterA();
-               }
-               else
-               {
-                  //log.info("Thread " + threadId + " adding B");
-                  addCounterB();
-               }
-            }
-
-         }
-         catch (Exception e)
-         {
-            e.printStackTrace();
-         }
-      }
-   }
-
-}

Deleted: trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-28 04:02:30 UTC (rev 1864)
+++ trunk/tests/src/org/jboss/test/messaging/util/VeryBasicValveTest.java	2006-12-28 04:20:39 UTC (rev 1865)
@@ -1,152 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.test.messaging.util;
-
-import junit.framework.TestCase;
-import org.jboss.logging.Logger;
-import org.jboss.messaging.util.Valve;
-
-/**
- * This verifies the very basic functionality of ConnectionState.Valve.
- * Two functions can't enter at the same time, and this will test that routine
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
- */
-public class VeryBasicValveTest extends TestCase
-{
-   private static Logger log = Logger.getLogger(VeryBasicValveTest.class);
-
-   static int counter = 0;
-   static int counterWait = 0;
-   static int countIsOpen = 0;
-
-   static boolean started=false;
-   static Object startSemaphore = new Object();
-   static Valve valve = new Valve();
-
-   // multiple threads opening/closing a thread.
-   // only one should be able to open it
-   public static class SomeThread extends Thread
-   {
-      int threadId;
-      public SomeThread(int threadId)
-      {
-         this.threadId = threadId;
-      }
-      public void run()
-      {
-         try
-         {
-            log.info("Starting Thread " + threadId);
-            synchronized (startSemaphore)
-            {
-               if (!started)
-               {
-                  startSemaphore.wait();
-               }
-            }
-
-            if (valve.isOpened(true))
-            {
-               countIsOpen++;
-            }
-
-            //log.info("Thread " + threadId + "Opening valve");
-            if (!valve.open())
-            {
-               //log.info("Valve couldn't be opened at thread " + threadId);
-               synchronized (VeryBasicValveTest.class)
-               {
-                  counterWait ++;
-               }
-            } else
-            {
-
-               //log.info("Thread " + threadId + " could open the valve");
-
-               //Thread.sleep(1000);
-
-               valve.open(); // stack vavles
-               if (!valve.isOpened(true))
-               {
-                  fail("Valve should be opened");
-               }
-
-               synchronized (VeryBasicValveTest.class)
-               {
-                  counter ++;
-               }
-               valve.close();
-               valve.close();
-            }
-
-            //log.info("Thread " + threadId + " is now closing the valve");
-
-         }
-         catch (Exception e)
-         {
-            e.printStackTrace();
-         }
-      }
-   }
-
-
-   public void testValve() throws Exception
-   {
-      SomeThread thread[] = new SomeThread[2500];
-
-      for (int i=0; i<thread.length; i++)
-      {
-         thread[i] = new SomeThread(i);
-      }
-
-      for (int i=0; i<thread.length; i++)
-      {
-         thread[i].start();
-      }
-
-      Thread.sleep(1000);
-
-      synchronized (startSemaphore)
-      {
-         started=true;
-         startSemaphore.notifyAll();
-      }
-
-      for (int i = 0; i < thread.length; i++)
-      {
-         thread[i].join();
-      }
-
-      log.info("CountIsOpened=" + countIsOpen);
-      log.info("CounterWait=" + counterWait);
-      log.info("counter=" + counter);
-
-      assertEquals(1, counter);
-      assertEquals(thread.length-1, counterWait);
-
-   }
-
-}



From forge-admin at jboss.com  Thu Dec 28 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Thu, 28 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1GzoJY-00043j-In@committer01.frg.pub.inap.atl.jboss.com>

Commit from sbryzak2 (2006-12-27 01:06 EST)
--------------------

started security documentation

  jboss-seam  doc/reference/en/master.xml            1.49
+ jboss-seam  doc/reference/en/modules/security.xml  1.1


Commit from rsigal (2006-12-27 01:13 EST)
------------------

JBREM-650: Unit tests for bisocket transport.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java                                    1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestServer.java                                  1.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestClient.java                       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestClient.java                                  1.1
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketPerformanceTestServer.java                       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutTestCase.java            1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutTestCase.java    1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutClientTest.java          1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutTestServer.java  1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketInactiveIdleTimeoutClientTest.java  1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/idle/BisocketIdleTimeoutTestServer.java          1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryClient.java                1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryTestCase.java              1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/retry/BisocketRetryServer.java                1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/load/BisocketPooledConnectionTestCase.java               1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/load/BisocketSocketLoadTestCase.java                     1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestClient.java        1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionTestCase.java               1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketTestServer.java                       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestServer.java        1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketConnectionCheckTestCase.java          1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/connection/BisocketTestClient.java                       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutTestCase.java                     1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutServerTest.java                   1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/timeout/BisocketTimeoutClientTest.java                   1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestCase.java                     1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestServer.java                   1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/socketpool/BisocketPoolTestClient.java                   1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/stress/BisocketInvokerClientTest.java                    1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/stress/readme.txt                                        1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/stress/BisocketInvokerServerTest.java                    1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/configuration/FactoryConfigTestCase.java                 1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/deadlock/BisocketShutdownDeadlockTestCase.java           1.2


Commit from rsigal (2006-12-27 01:14 EST)
------------------

JBREM-650: Unit tests for sslbisocket transport.

+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/clientTrustStore       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/clientKeyStore         1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverTrustStore2      1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverTrustStore       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/certificate/serverKeyStore         1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/SSLBisocketInvokerTestCase.java    1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/SSLBisocketInvokerClientTest.java  1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/no_connection_check/BisocketInvokerServerTest.java     1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerTestCase.java                  1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java                1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java                1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestCase.java                1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java              1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java              1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestCase.java           1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestClient.java         1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/serversocketrefresh/SSLBisocketTestServer.java         1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/.truststore                                            1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketTestCase.java                               1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/SSLBisocketInvokerConstants.java                       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/.keystore                                              1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerTestCase.java                 1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerClientTest.java               1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/custom/SSLBisocketInvokerServerTest.java               1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java     1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java     1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerTestCase.java       1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerClientTest.java            1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerTestCase.java              1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/handshake/SSLBisocketInvokerServerTest.java            1.2
+ JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/config/FactoryConfigTestCase.java                      1.2


Commit from rsigal (2006-12-27 01:15 EST)
------------------

JBREM-650: Added ability to add transport specific configuration.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseSSLParent.java  1.8
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/config/FactoryConfigTestCaseParent.java     1.6


Commit from rsigal (2006-12-27 01:21 EST)
------------------

JBREM-650: Made createServerSocketFactory() protected.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/custom/InvokerClientTest.java  1.13


Commit from rsigal (2006-12-27 01:23 EST)
------------------

JBREM-650: (1) Added ability to override transport, and (2) moved setUp() inside of try block.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestClient.java  1.6


Commit from rsigal (2006-12-27 01:24 EST)
------------------

JBREM-650: (1) Added ability to override transport, and (2) made some private variables protected.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/serversocketrefresh/TestServer.java  1.8


Commit from rsigal (2006-12-27 01:26 EST)
------------------

JBREM-650:  Added ability to override transport and, in some cases, port.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerServerTest.java      1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/connection_check/InvokerClientTest.java      1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestServer.java             1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/socketpool/SocketPoolTestClient.java             1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestClient.java      1.5
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/builder/SSLSocketInvokerTestServer.java      1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutClientTest.java          1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/IdleTimeoutTestServer.java          1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutClientTest.java  1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/idle/InactiveIdleTimeoutTestServer.java  1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerClientTest.java                 1.6
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/ssl/basic/InvokerServerTest.java                 1.11
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/load/SocketLoadTestCase.java                     1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/load/PooledConnectionTestCase.java               1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestServer.java                 1.6
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestClient.java  1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java                 1.9
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketConnectionCheckTestServer.java  1.4
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutServerTest.java                   1.6
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/timeout/TimeoutClientTest.java                   1.7
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryServer.java          1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/retry/SocketRetryClient.java          1.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/deadlock/ShutdownDeadlockTestCase.java           1.2


Commit from bwang (2006-12-27 09:44 EST)
-----------------

Test case for optimistic locking with List.

  JBossCache  tests-50/functional/org/jboss/cache/pojo/optimistic/LocalTxTest.java  1.2


Commit from asaldhana (2006-12-27 11:51 EST)
---------------------

security jars for 2.0.0.snapshot

+ repository.jboss.com  jboss/security/2.0.0.snapshot/component-info.xml      1.1
+ repository.jboss.com  jboss/security/2.0.0.snapshot/lib/jbosssx-client.jar  1.1
+ repository.jboss.com  jboss/security/2.0.0.snapshot/lib/jbosssx.jar         1.1


Commit from asaldhana (2006-12-27 11:52 EST)
---------------------

security spi snapshot for 2.0.0.snapshot

+ repository.jboss.com  jboss/security-spi/2.0.0.snapshot/component-info.xml          1.1
+ repository.jboss.com  jboss/security-spi/2.0.0.snapshot/lib/jboss-security-spi.jar  1.1


Commit from asaldhana (2006-12-27 12:56 EST)
---------------------

update the jar

  repository.jboss.com  jboss/security/2.0.0.snapshot/lib/jbosssx.jar  1.2


Commit from sbryzak2 (2006-12-27 20:46 EST)
--------------------

security docs

  jboss-seam  doc/reference/en/modules/security.xml  1.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061228/2752efc7/attachment.html 

From ron_sigal at yahoo.com  Thu Dec 28 03:10:12 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 03:10:12 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection
	...
Message-ID: <E1GzqL6-0006QO-V4@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 03:10:12

  Modified:    src/tests/org/jboss/test/remoting/transport/socket/connection 
                        SocketTestClient.java
  Log:
  JBREM-631:  Restored missing logger static variable.
  
  Revision  Changes    Path
  1.10      +3 -0      JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SocketTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- SocketTestClient.java	27 Dec 2006 06:26:54 -0000	1.9
  +++ SocketTestClient.java	28 Dec 2006 08:10:12 -0000	1.10
  @@ -22,6 +22,8 @@
   package org.jboss.test.remoting.transport.socket.connection;
   
   import junit.framework.TestCase;
  +
  +import org.jboss.logging.Logger;
   import org.jboss.remoting.Client;
   import org.jboss.remoting.InvokerLocator;
   import org.jboss.remoting.Version;
  @@ -32,6 +34,7 @@
    */
   public class SocketTestClient extends TestCase
   {
  +   private static Logger log = Logger.getLogger(SocketTestClient.class);
      // Default locator values
      private static String transport = "socket";
      private static String host = "localhost";
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 11:34:41 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 11:34:41 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1866 -
	trunk/src/main/org/jboss/jms/client/remoting
Message-ID: <E1GzyDJ-0006oa-IP@committer01.frg.pub.inap.atl.jboss.com>

Author: clebert.suconic at jboss.com
Date: 2006-12-28 11:34:39 -0500 (Thu, 28 Dec 2006)
New Revision: 1866

Modified:
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
Log:
http://jira.jboss.org/jira/browse/JBMESSAGING-702

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-28 04:20:39 UTC (rev 1865)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-28 16:34:39 UTC (rev 1866)
@@ -495,8 +495,9 @@
    
    public void copyState(MessageCallbackHandler newHandler)
    {
-      synchronized (mainLock)
-      {
+      // removed the synchronized block due to http://jira.jboss.org/jira/browse/JBMESSAGING-702
+      //synchronized (mainLock)
+      //{
          this.consumerID = newHandler.consumerID;
          
          this.consumerDelegate = newHandler.consumerDelegate;
@@ -504,7 +505,7 @@
          this.sessionDelegate = newHandler.sessionDelegate;
          
          this.buffer.clear();
-      }
+      //}
    }
    
    public long getLastDeliveryId()



From 8twer7gf654gf5 at kittymail.com  Thu Dec 28 13:31:51 2006
From: 8twer7gf654gf5 at kittymail.com (8twer7gf654gf5 at kittymail.com)
Date: Thu, 28 Dec 2006 13:31:51 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCuMKCw4HCgsOGwpNkwphiwpfCiMKCw6nCgsOM?=
	=?utf-8?b?wpHDksKCw4HCgsOEwoLDqcKCw7HCgsOFwoLCt8KCwq/CgsOHwoFj?=
Message-ID: 20061229024110.73439mail@mail.usueososjsnsasahaysbh6.com

?????O?????????????A?h???X???????????????H?????????????????H
?????????????????????A?????????????M?????????????c?B???????????H
?????????A???o?????????????????H
???????????????????????????A???????x?A?????????????????I
http://www.go-perfectfree.com.ksjer.com/gpp/
???????}?C?v???t?????????????????????????B
?Z???????????????R?[???????????????????d?b?????????????H







From hg5df64rtefsd at fastermail.com  Thu Dec 28 13:56:22 2006
From: hg5df64rtefsd at fastermail.com (hg5df64rtefsd at fastermail.com)
Date: Thu, 28 Dec 2006 13:56:22 -0500
Subject: [jboss-cvs] =?utf-8?b?wojDqsKQbMKCwqvCgsOowoLDjcKOw6LCgsK1woI=?=
	=?utf-8?b?wqLCgWPCgULCjcKhwpROwpLChsKCw4nCicOvwoLCpsKCw5zCgsK5woI=?=
	=?utf-8?b?w7HCgsKpwoFI?=
Message-ID: 20061229042710.49690mail@mail.buisdoirtyrrewrpetoiasdiufsdjfnsdufsdjueyusefsd.com

?{???????????f?G?????l?????A?y?????F?B???????????????????????A
?????????????????????????????????B
?F?B???????????H?????A?????????????????????????????c?B
???????????????????????????B???????????????????????H
?????????????????????????????????B?{?S?????B
?????????????d?b?????????????????B???[?????????????????????B
http://www.freeweb.allfreemail.net.tonderuyo.com/WY/
?A?????????????????????????????????????????????????B






From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 15:58:25 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 15:58:25 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1867 - in trunk:
	src/etc/server/default/deploy
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/local
	src/main/org/jboss/messaging/core/plugin
	src/main/org/jboss/messaging/core/plugin/postoffice/cluster
	src/main/org/jboss/messaging/core/tx tests
	tests/src/org/jboss/test/messaging/core
	tests/src/org/jboss/test/messaging/core/local/base
	tests/src/org/jboss/test/messaging/core/paging
	tests/src/org/jboss/test/messaging/core/plugin/postoffice
	tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster
	tests/src/org/jboss/test/messaging/jms/server/destination
Message-ID: <E1H02KX-0002pb-K1@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-28 15:58:01 -0500 (Thu, 28 Dec 2006)
New Revision: 1867

Modified:
   trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
   trunk/src/main/org/jboss/messaging/core/Channel.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/Delivery.java
   trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/SimpleDelivery.java
   trunk/src/main/org/jboss/messaging/core/local/FirstReceiverPointToPointRouter.java
   trunk/src/main/org/jboss/messaging/core/local/RoundRobinPointToPointRouter.java
   trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
   trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
   trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
   trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryObserver.java
   trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
   trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_2PCTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_NTTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_TTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_2PCTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_NTTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_TTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
   trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
   trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java
Log:
Removed deliveries set from channel and re-added jdbc deadlock retry logic



Modified: trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/etc/server/default/deploy/hsqldb-persistence-service.xml	2006-12-28 20:58:01 UTC (rev 1867)
@@ -15,7 +15,7 @@
       <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
       <attribute name="DataSource">java:/DefaultDS</attribute>
       <attribute name="CreateTablesOnStartup">true</attribute>
-      <attribute name="UsingBatchUpdates">true</attribute>
+      <attribute name="UsingBatchUpdates">false</attribute>
       <attribute name="MaxParams">500</attribute>
    </mbean>
 

Modified: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -134,7 +134,7 @@
          }
          catch (Throwable e)
          {
-            log.error("ValveAspect didn't catch the exception " + e + ", and it will be forwarded", e);
+            // just rethrow
             throw e;
          }
          finally

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -189,11 +189,6 @@
             return delivery;
          }
                  
-         if (delivery.isDone())
-         {
-            return delivery;
-         }
-         
          long deliveryId = sessionEndpoint.addDelivery(delivery, id);
    
          // We don't send the message as-is, instead we create a MessageProxy instance. This allows

Modified: trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -141,7 +141,7 @@
       }      
    }
    
-   private class Holder
+   private static class Holder
    {
       ResourceManager rm;
       

Modified: trunk/src/main/org/jboss/messaging/core/Channel.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/Channel.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -76,8 +76,7 @@
    public boolean acceptReliableMessages();
 
    /**
-    * @return a List containing messages being held by the channel. The list includes messages in
-    *         process of being delivered and messages for which delivery hasn't been attempted yet.
+    * @return a List containing messages being held by the channel. 
     */
    List browse();
 
@@ -85,8 +84,7 @@
     * @param filter - may be null, in which case no filter is applied.
     *
     * @return a List containing message references of messages whose state is maintained by this
-    *         State instance. The list includes references of messages in process of being delivered
-    *         and references of messages for which delivery has not been attempted yet.
+    *         State instance. 
     */
    List browse(Filter filter);
 
@@ -103,20 +101,6 @@
    void close();
 
    /**
-    * Get a list of message references of messages in the process of being delivered, subject to the filter
-    * @param filter
-    * @return the list
-    */
-   List delivering(Filter filter);
-
-   /**
-    * Get a list of message references of messages not in the process of being delivered, subject to the filter
-    * @param filter
-    * @return the list
-    */
-   List undelivered(Filter filter);   
-
-   /**
     * Clears non-recoverable state but not persisted state, so a recovery of the channel is possible
     * TODO really?
     */
@@ -126,8 +110,10 @@
     * Message amount. 
     * @return message amount.
     */
-   int messageCount();   
+   int messageCount(); 
    
+   int deliveringCount();
+   
    /**
     * Remove all the references in the channel
     * @throws Throwable
@@ -145,10 +131,7 @@
    boolean isActive();
    
    List recoverDeliveries(List messageIds);
-   
-   //This method will be defunct very soon when we remove the delivery list from inside the channel
-   void addDelivery(Delivery del);
-
+  
 }
 
 

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -22,12 +22,9 @@
 package org.jboss.messaging.core;
 
 import java.util.ArrayList;
-import java.util.HashSet;
 import java.util.Iterator;
-import java.util.LinkedHashSet;
 import java.util.List;
 import java.util.ListIterator;
-import java.util.Set;
 
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
@@ -40,6 +37,7 @@
 import org.jboss.messaging.util.Future;
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
+import EDU.oswego.cs.dl.util.concurrent.SynchronizedInt;
 
 /**
  * 
@@ -82,8 +80,6 @@
 
    protected PrioritizedDeque messageRefs;
 
-   protected Set deliveries;
-
    protected boolean acceptReliableMessages;
 
    protected boolean recoverable;
@@ -92,10 +88,15 @@
 
    protected Object refLock;
 
-   protected Object deliveryLock;
-
    protected boolean active = true;
    
+   //TODO - I would like to get rid of this - the only reason we still keep a count of
+   //refs being delivered is because many tests require this
+   //Having to keep this count requires synchronization between delivery thread and acknowledgement
+   //thread which will hamper concurrency
+   //Suggest that we have a glag that disables this for production systems
+   protected SynchronizedInt deliveringCount;
+   
    // Constructors --------------------------------------------------
 
    protected ChannelSupport(long channelID, MessageStore ms,
@@ -129,11 +130,9 @@
 
       messageRefs = new BasicPrioritizedDeque(10);
 
-      deliveries = new LinkedHashSet();
-
       refLock = new Object();
-
-      deliveryLock = new Object();
+      
+      deliveringCount = new SynchronizedInt(0);
    }
 
    // Receiver implementation ---------------------------------------
@@ -178,7 +177,7 @@
    {
       if (trace) { log.trace("acknowledging " + d + (tx == null ? " non-transactionally" : " transactionally in " + tx)); }
 
-      this.acknowledgeInternal(d, tx, true, false);
+      acknowledgeInternal(d, tx, true, false);
    }
 
 
@@ -263,33 +262,26 @@
    {
       if (trace) { log.trace(this + " browse" + (filter == null ? "" : ", filter = " + filter)); }
 
-      synchronized (deliveryLock)
+      synchronized (refLock)
       {
-         synchronized (refLock)
-         {
-            //FIXME - This is currently broken since it doesn't take into account
-            // refs paged into persistent storage
-            // Also is very inefficient since it makes a copy
-            // The way to implement this properly is to use the Prioritized deque iterator
-            // combined with an iterator over the refs in storage
+         //FIXME - This is currently broken since it doesn't take into account
+         // refs paged into persistent storage
+         // Also is very inefficient since it makes a copy
+         // The way to implement this properly is to use the Prioritized deque iterator
+         // combined with an iterator over the refs in storage
 
-            //TODO use the ref queue iterator
-            List references = delivering(filter);
+         //TODO use the ref queue iterator
+         List references = undelivered(filter);
 
-            List undel = undelivered(filter);
-
-            references.addAll(undel);
-
-            // dereference pass
-            ArrayList messages = new ArrayList(references.size());
-            for (Iterator i = references.iterator(); i.hasNext();)
-            {
-               MessageReference ref = (MessageReference) i.next();
-               messages.add(ref.getMessage());
-            }
-            return messages;
+         // dereference pass
+         ArrayList messages = new ArrayList(references.size());
+         for (Iterator i = references.iterator(); i.hasNext();)
+         {
+            MessageReference ref = (MessageReference) i.next();
+            messages.add(ref.getMessage());
          }
-      }
+         return messages;
+      }      
    }
 
    public void deliver(boolean synchronous)
@@ -334,7 +326,7 @@
 
    /*
     * This method clears the channel.
-    * Basically it acknowledges any outstanding deliveries and consumes the rest of the messages in the channel.
+    * Basically it consumes the rest of the messages in the channel.
     * We can't just delete the corresponding references directly from the database since
     * a) We might be paging
     * b) The message might remain in the message store causing a leak
@@ -345,68 +337,27 @@
       log.debug(this + " remnoving all references");
       
       synchronized (refLock)
-      {
-         synchronized (deliveryLock)
-         {
-            //Ack the deliveries
+      {            
+         //Now we consume the rest of the messages
+         //This may take a while if we have a lot of messages including perhaps millions
+         //paged in the database - but there's no obvious other way to do it.
+         //We cannot just delete them directly from the database - because we may end up with messages leaking
+         //in the message store,
+         //also we might get race conditions when other channels are updating the same message in the db
 
-            //Clone to avoid ConcurrentModificationException
-            Set dels = new HashSet(deliveries);
+         //Note - we don't do this in a tx - because the tx could be too big if we have millions of refs
+         //paged in storage
 
-            Iterator iter = dels.iterator();
-            while (iter.hasNext())
-            {
-               SimpleDelivery d = (SimpleDelivery) iter.next();
-
-               d.acknowledge(null);
-            }
-
-            //Now we consume the rest of the messages
-            //This may take a while if we have a lot of messages including perhaps millions
-            //paged in the database - but there's no obvious other way to do it.
-            //We cannot just delete them directly from the database - because we may end up with messages leaking
-            //in the message store,
-            //also we might get race conditions when other channels are updating the same message in the db
-
-            //Note - we don't do this in a tx - because the tx could be too big if we have millions of refs
-            //paged in storage
-
-            MessageReference ref;
-            while ((ref = removeFirstInMemory()) != null)
-            {
-               SimpleDelivery del = new SimpleDelivery(this, ref, false);
-
-               del.acknowledge(null);
-            }
-
-         }
-      }
-   }
-
-   public List delivering(Filter filter)
-   {
-      List delivering = new ArrayList();
-
-      synchronized (deliveryLock)
-      {
-         for (Iterator i = deliveries.iterator(); i.hasNext();)
+         MessageReference ref;
+         while ((ref = removeFirstInMemory()) != null)
          {
-            Delivery d = (Delivery) i.next();
+            SimpleDelivery del = new SimpleDelivery(this, ref);
 
-            MessageReference r = d.getReference();
-
-            // TODO: I need to dereference the message each time I apply the
-            // filter. Refactor so the message reference will also contain JMS
-            // properties
-            if (filter == null || filter.accept(r.getMessage()))
-            {
-               delivering.add(r);
-            }
-         }
+            del.acknowledge(null);
+         }         
+         
+         deliveringCount.set(0);
       }
-      if (trace) { log.trace(this + ": the non-recoverable state has " + delivering.size() + " messages being delivered"); }
-
-      return delivering;
    }
 
    public List undelivered(Filter filter)
@@ -446,21 +397,20 @@
    {
       synchronized (refLock)
       {
-         synchronized (deliveryLock)
-         {
-            return messageRefs.size() + deliveries.size();
-         }
+         return messageRefs.size() + deliveringCount();     
       }
    }
+   
+   public int deliveringCount()
+   {
+      return deliveringCount.get();
+   }
 
    public void activate()
    {
       synchronized (refLock)
       {
-         synchronized (deliveryLock)
-         {
-            active = true;
-         }
+         active = true;         
       }
    }
 
@@ -468,10 +418,7 @@
    {
       synchronized (refLock)
       {
-         synchronized (deliveryLock)
-         {
-            active = false;
-         }
+         active = false;         
       }
    }
 
@@ -479,22 +426,10 @@
    {
       synchronized (refLock)
       {
-         synchronized (deliveryLock)
-         {
-            return active;
-         }
+         return active;         
       }
    }
    
-   //This method will be defunct very soon when we remove the delivery list from inside the channel
-   public void addDelivery(Delivery del)
-   {
-      synchronized (deliveryLock)
-      {
-         deliveries.add(del);
-      }
-   }
-   
    public List recoverDeliveries(List messageIds)
    {
       //debug
@@ -504,41 +439,36 @@
       
       synchronized (refLock)
       {
-         synchronized (deliveryLock)
+         ListIterator liter = messageRefs.iterator();
+                           
+         while (iter.hasNext())
          {
-            ListIterator liter = messageRefs.iterator();
-                              
-            while (iter.hasNext())
-            {
-               Long id = (Long)iter.next();
+            Long id = (Long)iter.next();
+            
+            //Scan the queue
+            while (true)
+            {               
+               if (!liter.hasNext())
+               {
+                  // TODO we need to look in paging state too - currently not supported
+                  
+                  throw new IllegalStateException("Cannot find ref in queue! (Might be paged!) " + id);
+               }
                
-               //Scan the queue
-               while (true)
-               {               
-                  if (!liter.hasNext())
-                  {
-                     // TODO we need to look in paging state too - currently not supported
-                     
-                     throw new IllegalStateException("Cannot find ref in queue! (Might be paged!) " + id);
-                  }
+               MessageReference ref = (MessageReference)liter.next();
+               
+               if (ref.getMessageID() == id.longValue())
+               {
+                  liter.remove();
                   
-                  MessageReference ref = (MessageReference)liter.next();
+                  Delivery del = new SimpleDelivery(this, ref);
                   
-                  if (ref.getMessageID() == id.longValue())
-                  {
-                     liter.remove();
-                     
-                     Delivery del = new SimpleDelivery(this, ref);
-                     
-                     dels.add(del);
-                                    
-                     this.deliveries.add(del);
-                     
-                     break;
-                  }
+                  dels.add(del);
+                                 
+                  break;
                }
-            }  
-         }
+            }
+         }           
       }
             
       return dels;
@@ -556,13 +486,6 @@
    }
 
    //Only used for testing
-   public int memoryDeliveryCount()
-   {
-      synchronized (deliveryLock)
-      {
-         return deliveries.size();
-      }
-   }
 
    public String toString()
    {
@@ -639,33 +562,9 @@
                      
                      // Receiver accepted the reference
                      
-                     // We must synchronize here to cope with a race condition where message
-                     // is cancelled/acked in flight while the following few actions are being
-                     // performed. e.g. delivery could be cancelled acked after being removed from
-                     // state but before delivery being added (observed).
-                     synchronized (del)
-                     {
-                        // FIXME - It's actually possible the delivery could be cancelled before it reaches
-                        // here, in which case we wouldn't get a delivery but we still need to increment the
-                        // delivery count. TODO http://jira.jboss.com/jira/browse/JBMESSAGING-355
-
-                        if (!del.isCancelled())
-                        {
-                           removeReference(iter);
-
-                           // delivered
-                           if (!del.isDone())
-                           {
-                              // Add the delivery to state
-                              synchronized (deliveryLock)
-                              {
-                                 deliveries.add(del);
-                                 
-                                 if (trace) { log.trace(this + " starting to track  " + del); }
-                              }
-                           }
-                        }
-                     }
+                     removeReference(iter);
+                     
+                     deliveringCount.increment();                     
                   }
                }
             }
@@ -794,18 +693,15 @@
                                       boolean synchronous) throws Exception
    {   
       if (tx == null)
-      {
-         synchronized (deliveryLock)
-         {
-            acknowledgeInMemory(d);
-         }
-            
+      {                  
          if (persist && recoverable && d.getReference().isReliable())
          {
             pm.removeReference(channelID, d.getReference(), null);
          }
               
-         d.getReference().releaseMemoryReference();             
+         d.getReference().releaseMemoryReference(); 
+         
+         deliveringCount.decrement();
       }
       else
       {
@@ -820,23 +716,6 @@
       }
    }
 
-   protected boolean acknowledgeInMemory(Delivery d)
-   {
-      if (d == null)
-      {
-         throw new IllegalArgumentException("Can't acknowledge a null delivery");
-      }
-
-      boolean removed = deliveries.remove(d);
-
-      // It's ok if the delivery couldn't be found - this might happen
-      // if the delivery is acked before the call to handle() has returned
-
-      if (trace) { log.trace(this + " removed " + d + " from memory:" + removed); }
-      
-      return removed;
-   }    
-   
    protected InMemoryCallback getCallback(Transaction tx, boolean synchronous)
    {
       InMemoryCallback callback = (InMemoryCallback) tx.getCallback(this);            
@@ -860,45 +739,26 @@
    }
 
       
-   protected boolean cancelInternal(Delivery del) throws Exception
+   protected void cancelInternal(Delivery del) throws Exception
    {
       if (trace) { log.trace(this + " cancelling " + del + " in memory"); }
 
-      boolean removed;
+      MessageReference ref = del.getReference();
       
-      synchronized (deliveryLock)
+      synchronized (refLock)
       {
-         removed = deliveries.remove(del);      
+         messageRefs.addFirst(ref, ref.getPriority());
       }
-
-      if (!removed)
-      {         
-         // This can happen if the message is cancelled before the result of
-         // ServerConsumerDelegate.handle has returned, in which case we won't have a record of the delivery
-         // In this case we don't want to add the message reference back into
-         // the state since it was never removed in the first place
-
-         if (trace) { log.trace(this + " can't find delivery " + del + " in state so not replacing messsage ref"); }
-      }
-      else
+      
+      //We may need to update the delivery count in the database
+      if (ref.isReliable())
       {
-         MessageReference ref = del.getReference();
-         
-         synchronized (refLock)
-         {
-            messageRefs.addFirst(ref, ref.getPriority());
-         }
-         
-         //We may need to update the delivery count in the database
-         if (ref.isReliable())
-         {
-            pm.updateDeliveryCount(this.channelID, ref);
-         }
-         
-         if (trace) { log.trace(this + " added " + ref + " back into state"); }
+         pm.updateDeliveryCount(this.channelID, ref);
       }
       
-      return removed;
+      deliveringCount.decrement();
+      
+      if (trace) { log.trace(this + " added " + ref + " back into state"); }
    }
    
    protected MessageReference removeFirstInMemory() throws Exception
@@ -1190,18 +1050,8 @@
             if (trace) { log.trace(this + " removing " + del + " after commit"); }
 
             del.getReference().releaseMemoryReference();
-
-            try
-            {
-               synchronized (deliveryLock)
-               {
-                  acknowledgeInMemory(del);
-               }
-            }
-            catch (Throwable t)
-            {
-               throw new TransactionException("Failed to ack message", t);
-            }
+            
+            deliveringCount.decrement();
          }
          
          //prompt delivery

Modified: trunk/src/main/org/jboss/messaging/core/Delivery.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/Delivery.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/Delivery.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -38,8 +38,6 @@
 
    boolean isDone();
    
-   boolean isCancelled();
-
    void setObserver(DeliveryObserver observer);
 
    DeliveryObserver getObserver();

Modified: trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/PagingChannelSupport.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -22,7 +22,6 @@
 package org.jboss.messaging.core;
 
 import java.util.ArrayList;
-import java.util.Collections;
 import java.util.HashMap;
 import java.util.Iterator;
 import java.util.List;
@@ -203,20 +202,17 @@
    public void setPagingParams(int fullSize, int pageSize, int downCacheSize)
    {
       synchronized (refLock)
-      {
-         synchronized (deliveryLock)
-         {      
-            if (active)
-            {
-               throw new IllegalStateException("Cannot set paging params when active");
-            }
-            
-            this.fullSize = fullSize;
-            
-            this.pageSize = pageSize;
-            
-            this.downCacheSize = downCacheSize;
+      { 
+         if (active)
+         {
+            throw new IllegalStateException("Cannot set paging params when active");
          }
+         
+         this.fullSize = fullSize;
+         
+         this.pageSize = pageSize;
+         
+         this.downCacheSize = downCacheSize;         
       }
    }
    
@@ -270,23 +266,18 @@
    {
       synchronized (refLock)
       {
-         synchronized (deliveryLock)
+         if (active)
          {
-            if (active)
-            {
-               throw new IllegalStateException("Cannot unload channel when active");
-            }
-            
-            messageRefs.clear();
-            
-            deliveries.clear();
-            
-            downCache.clear();
-            
-            paging = false;
-            
-            firstPagingOrder = nextPagingOrder = 0;
+            throw new IllegalStateException("Cannot unload channel when active");
          }
+         
+         messageRefs.clear();
+         
+         downCache.clear();
+         
+         paging = false;
+         
+         firstPagingOrder = nextPagingOrder = 0;         
       }
    }
    
@@ -367,15 +358,15 @@
       }    
    }
       
-   protected boolean cancelInternal(Delivery del) throws Exception
+   protected void cancelInternal(Delivery del) throws Exception
    {
       if (trace) { log.trace(this + " cancelling " + del + " in memory"); }
 
       synchronized (refLock)
       {         
-         boolean removed = super.cancelInternal(del);
+         super.cancelInternal(del);
          
-         if (removed && paging)
+         if (paging)
          {
             // if paging and the in memory queue is exactly full we need to evict the end reference to storage to
             // preserve the number of refs in the queue
@@ -388,8 +379,6 @@
          }
                
          if (trace) { log.trace(this + " added " + del.getReference() + " back into state"); }      
-         
-         return removed;
       }
    }
       

Modified: trunk/src/main/org/jboss/messaging/core/SimpleDelivery.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/SimpleDelivery.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/SimpleDelivery.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -43,8 +43,7 @@
    
    // Attributes ----------------------------------------------------
 
-   protected boolean done;
-   protected boolean cancelled;
+   protected volatile boolean done;
    protected boolean selectorAccepted;
    protected DeliveryObserver observer;
    protected MessageReference reference;
@@ -98,16 +97,11 @@
       return reference;
    }
 
-   public synchronized boolean isDone()
+   public boolean isDone()
    {
       return done;
    }
    
-   public synchronized boolean isCancelled()
-   {
-      return cancelled;
-   }
-
    public boolean isSelectorAccepted()
    {
       return selectorAccepted;
@@ -123,30 +117,22 @@
       return observer;
    }
 
-   public synchronized void acknowledge(Transaction tx) throws Throwable
+   public void acknowledge(Transaction tx) throws Throwable
    {        
       if (trace) { log.trace(this + " acknowledging delivery in tx:" + tx); }
       
-      // deals with the race condition when acknowledgment arrives before the delivery
-      // is returned back to the sending delivery observer      
       observer.acknowledge(this, tx);
 
-      //Important note! We must ALWAYS set done true irrespective of whether we are in a tx or not.
-      //Previously we were only setting done to true if there was no transaction.
-      //This meant that if the acknowledgement (in the tx) came in before the call to handle()
-      //had returned the delivery would end up in the delivery set in the channel and never
-      //get removed - causing a leak
       done = true;      
    }
 
-   public synchronized void cancel() throws Throwable
+   public void cancel() throws Throwable
    {
       if (trace) { log.trace(this + " cancelling delivery"); }
-      
-      // deals with the race condition when cancellation arrives before the delivery
-      // is returned back to the sending delivery observer      
+         
       observer.cancel(this);
-      cancelled = true;      
+      
+      done = true;
    }
    
    // Public --------------------------------------------------------
@@ -154,7 +140,7 @@
    public String toString()
    {
       return "Delivery" + (reference == null ? "" : "[" + reference + "]") +
-         "(" + (cancelled ? "cancelled" : done ? "done" : "active") + ")";
+         "(" + ( done ? "done" : "active") + ")";
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/messaging/core/local/FirstReceiverPointToPointRouter.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/local/FirstReceiverPointToPointRouter.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/local/FirstReceiverPointToPointRouter.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -100,7 +100,7 @@
 
             if (trace) { log.trace("receiver " + receiver + " handled " + ref + " and returned " + d); }
 
-            if (d != null && !d.isCancelled())
+            if (d != null)
             {
                if (d.isSelectorAccepted())
                {

Modified: trunk/src/main/org/jboss/messaging/core/local/RoundRobinPointToPointRouter.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/local/RoundRobinPointToPointRouter.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/local/RoundRobinPointToPointRouter.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -109,7 +109,7 @@
 
             if (trace) { log.trace("receiver " + r + " handled " + ref + " and returned " + d); }
 
-            if (d != null && !d.isCancelled())
+            if (d != null)
             {
                if (d.isSelectorAccepted())
                {

Modified: trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/plugin/JDBCPersistenceManager.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -261,10 +261,7 @@
       }
    }
    
-   
-   
-   
-      
+               
    // Related to counters
    // ===================
    
@@ -295,6 +292,7 @@
          ps.setString(1, counterName);
          
          rs = ps.executeQuery();
+         
          if (trace) { log.trace(JDBCUtil.statementToString(selectCounterSQL, counterName)); }         
          
          if (!rs.next())
@@ -311,7 +309,7 @@
             ps.setString(1, counterName);
             ps.setLong(2, size);
             
-            int rows = ps.executeUpdate();
+            int rows = updateWithRetry(ps);
             if (trace) { log.trace(JDBCUtil.statementToString(insertCounterSQL, counterName, new Integer(size)) + " inserted " + rows + " rows"); }
             
             ps.close();            
@@ -333,7 +331,7 @@
          ps.setLong(1, nextId + size);
          ps.setString(2, counterName);
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          if (trace) { log.trace(JDBCUtil.statementToString(updateCounterSQL, new Long(nextId + size), counterName) + " updated " + rows + " rows"); }
          
          return nextId;
@@ -627,7 +625,7 @@
             }
             else
             {
-               int rows = psInsertReference.executeUpdate();
+               int rows = updateWithRetry(psInsertReference);
                
                if (trace)
                {
@@ -709,7 +707,7 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                                       
                   if (trace)
                   {
@@ -718,7 +716,7 @@
                }
                else
                {               
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace)
                   {
@@ -734,19 +732,19 @@
          
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psInsertReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psInsertReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE_REF"), rowsReference, "inserted"); }
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE"), rowsMessage, "inserted"); }
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace) { logBatchUpdate(getSQLStatement("INC_CHANNELCOUNT"), rowsMessage, "updated"); }
             }
@@ -864,7 +862,7 @@
             }
             else
             {
-               int rows = psDeleteReference.executeUpdate();
+               int rows = updateWithRetry(psDeleteReference);
                
                if (trace) { log.trace("Deleted " + rows + " rows"); }
                
@@ -897,11 +895,11 @@
             }
             else
             {  
-               int rows = psUpdateMessage.executeUpdate();
+               int rows = updateWithRetry(psUpdateMessage);
                                                  
                if (trace) { log.trace("Updated " + rows + " rows"); }
                
-               rows = psDeleteMessage.executeUpdate();
+               rows = updateWithRetry(psDeleteMessage);
         
                if (trace) { log.trace("Deleted " + rows + " rows"); }
             
@@ -915,15 +913,15 @@
          
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psDeleteReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psDeleteReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE_REF"), rowsReference, "deleted"); }
             
-            rowsReference = psUpdateMessage.executeBatch();
+            rowsReference = updateWithRetryBatch(psUpdateMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DEC_CHANNELCOUNT"), rowsReference, "updated"); }
             
-            rowsReference = psDeleteMessage.executeBatch();
+            rowsReference = updateWithRetryBatch(psDeleteMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE"), rowsReference, "deleted"); }
                                     
@@ -1022,7 +1020,7 @@
          {
             try
             {
-               int rows = ps.executeUpdate();
+               int rows = updateWithRetry(ps);
                  
                if (trace) { log.trace(JDBCUtil.statementToString(getSQLStatement("UPDATE_RELIABLE_REFS_NOT_PAGED"), new Long(channelID),
                                       new Long(orderStart), new Long(orderEnd)) + " updated " + rows + " rows"); }
@@ -1130,7 +1128,7 @@
             }
             else
             {
-               int rows = psUpdateReference.executeUpdate();
+               int rows = updateWithRetry(psUpdateReference);
                
                if (trace) { log.trace("Updated " + rows + " rows"); }
                
@@ -1141,7 +1139,7 @@
                      
          if (usingBatchUpdates)
          {
-            int[] rowsReference = psUpdateReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psUpdateReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("UPDATE_PAGE_ORDER"), rowsReference, "updated"); }
                         
@@ -1435,7 +1433,7 @@
             // Add the reference
             addReference(channelID, ref, psReference, false);
             
-            int rows = psReference.executeUpdate();            
+            int rows = updateWithRetry(psReference);      
             
             if (trace) { log.trace("Inserted " + rows + " rows"); }
               
@@ -1456,7 +1454,7 @@
                incrementChannelCount(m, psMessage);
             }
                            
-            rows = psMessage.executeUpdate();
+            rows = updateWithRetry(psMessage);
             
             if (trace) { log.trace("Inserted/updated " + rows + " rows"); }     
             
@@ -1530,7 +1528,7 @@
          
          psReference.setLong(3, ref.getMessageID());
          
-         int rows = psReference.executeUpdate();
+         int rows = updateWithRetry(psReference);
 
          if (trace) { log.trace("Updated " + rows + " rows"); }
       }
@@ -1599,7 +1597,7 @@
             //Remove the message reference
             removeReference(channelID, ref, psReference);
             
-            int rows = psReference.executeUpdate();
+            int rows = updateWithRetry(psReference);
             
             if (rows != 1)
             {
@@ -1614,7 +1612,7 @@
             
             decrementChannelCount(m, psUpdate);
             
-            rows = psUpdate.executeUpdate();
+            rows = updateWithRetry(psUpdate);
             
             if (trace) { log.trace("Updated " + rows + " rows"); } 
             
@@ -1624,7 +1622,7 @@
             
             removeMessage(m, psMessage);
                        
-            rows = psMessage.executeUpdate();
+            rows = updateWithRetry(psMessage);
             
             if (trace) { log.trace("Delete " + rows + " rows"); }                           
          }
@@ -1864,7 +1862,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace) { log.trace("Inserted " + rows + " rows"); }                              
                
@@ -1912,12 +1910,12 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                   if (trace) { log.trace("Inserted " + rows + " rows"); }
                }
                else
                {
-                  int rows = psIncMessage.executeUpdate();
+                  int rows = updateWithRetry(psIncMessage);
                   if (trace) { log.trace("Updated " + rows + " rows"); }
                }
                psInsertMessage.close();
@@ -1931,21 +1929,19 @@
          {
             // Process the add batch
 
-
-
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE_REF"), rowsReference, "inserted"); }
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE"), rowsMessage, "inserted"); }
             }
 
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psIncMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psIncMessage);
                if (trace) { logBatchUpdate(getSQLStatement("INC_CHANNELCOUNT"), rowsMessage, "updated"); }
             }
             
@@ -1988,7 +1984,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                if (trace) { log.trace("Deleted " + rows + " rows"); }
                psReference.close();
                psReference = null;
@@ -2017,10 +2013,10 @@
             }
             else
             {
-               int rows = psDecMessage.executeUpdate();
+               int rows = updateWithRetry(psDecMessage);
                if (trace) { log.trace("Updated " + rows + " rows"); }
                
-               rows = psDeleteMessage.executeUpdate();
+               rows = updateWithRetry(psDeleteMessage);
                if (trace) { log.trace("Deleted " + rows + " rows"); }
 
                psDeleteMessage.close();
@@ -2034,15 +2030,15 @@
          {
             // Process the remove batch
 
-            int[] rows = psReference.executeBatch();
+            int[] rows = updateWithRetryBatch(psReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE_REF"), rows, "deleted"); }
             
-            rows = psDecMessage.executeBatch();
+            rows = updateWithRetryBatch(psDecMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DEC_CHANNELCOUNT"), rows, "updated"); }
 
-            rows = psDeleteMessage.executeBatch();
+            rows = updateWithRetryBatch(psDeleteMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE"), rows, "deleted"); }
 
@@ -2208,11 +2204,11 @@
             }
             else
             {
-               int rows = psUpdateMessage.executeUpdate();
+               int rows = updateWithRetry(psUpdateMessage);
                
                if (trace) { log.trace("Updated " + rows + " rows"); }
                
-               rows = psDeleteMessage.executeUpdate();
+               rows = updateWithRetry(psDeleteMessage);
                
                if (trace) { log.trace("Deleted " + rows + " rows"); }
                
@@ -2225,14 +2221,14 @@
          
          if (batch)
          {
-            int[] rows = psUpdateMessage.executeBatch();
+            int[] rows = updateWithRetryBatch(psUpdateMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DEC_CHANNELCOUNT"), rows, "updated"); }
             
             psUpdateMessage.close();
             psUpdateMessage = null;
             
-            rows = psDeleteMessage.executeBatch();
+            rows = updateWithRetryBatch(psDeleteMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE"), rows, "deleted"); }
             
@@ -2356,7 +2352,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace) { log.trace("Inserted " + rows + " rows"); }
                
@@ -2408,13 +2404,13 @@
             {
                if (added)
                {
-                  int rows = psInsertMessage.executeUpdate();
+                  int rows = updateWithRetry(psInsertMessage);
                   
                   if (trace) { log.trace("Inserted " + rows + " rows"); }
                }
                else
                {
-                  int rows = psUpdateMessage.executeUpdate();
+                  int rows = updateWithRetry(psUpdateMessage);
                   
                   if (trace) { log.trace("Updated " + rows + " rows"); }
                }
@@ -2427,19 +2423,19 @@
          
          if (batch)
          {
-            int[] rowsReference = psReference.executeBatch();
+            int[] rowsReference = updateWithRetryBatch(psReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE_REF"), rowsReference, "inserted"); }
             
             if (messageInsertsInBatch)
             {
-               int[] rowsMessage = psInsertMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psInsertMessage);
                
                if (trace) { logBatchUpdate(getSQLStatement("INSERT_MESSAGE"), rowsMessage, "inserted"); }
             }
             if (messageUpdatesInBatch)
             {
-               int[] rowsMessage = psUpdateMessage.executeBatch();
+               int[] rowsMessage = updateWithRetryBatch(psUpdateMessage);
                
                if (trace) { logBatchUpdate(getSQLStatement("INC_CHANNELCOUNT"), rowsMessage, "updated"); }
             }
@@ -2479,7 +2475,7 @@
             }
             else
             {
-               int rows = psReference.executeUpdate();
+               int rows = updateWithRetry(psReference);
                
                if (trace) { log.trace("updated " + rows + " rows"); }
                
@@ -2490,7 +2486,7 @@
          
          if (batch)
          {
-            int[] rows = psReference.executeBatch();
+            int[] rows = updateWithRetryBatch(psReference);
             
             if (trace) { logBatchUpdate(getSQLStatement("UPDATE_MESSAGE_REF"), rows, "updated"); }
             
@@ -2628,11 +2624,11 @@
             }
             else
             {
-               int rows = psUpdateMessage.executeUpdate();
+               int rows = updateWithRetry(psUpdateMessage);
                
                if (trace) { log.trace("updated " + rows + " rows"); }
                
-               rows = psDeleteMessage.executeUpdate();
+               rows = updateWithRetry(psDeleteMessage);
                
                if (trace) { log.trace("deleted " + rows + " rows"); }
                
@@ -2645,11 +2641,11 @@
          
          if (batch)
          {
-            int[] rows = psUpdateMessage.executeBatch();
+            int[] rows = updateWithRetryBatch(psUpdateMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DEC_CHANNELCOUNT"), rows, "updated"); }
             
-            rows = psDeleteMessage.executeBatch();
+            rows = updateWithRetryBatch(psDeleteMessage);
             
             if (trace) { logBatchUpdate(getSQLStatement("DELETE_MESSAGE"), rows, "deleted"); }
             
@@ -2735,7 +2731,7 @@
          ps.setInt(3, formatID);
          ps.setBytes(4, xid.getGlobalTransactionId());
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
       }
       finally
@@ -2760,7 +2756,7 @@
       }
    }
    
-   protected void removeTXRecord(Connection conn, Transaction tx) throws SQLException
+   protected void removeTXRecord(Connection conn, Transaction tx) throws Exception
    {
       PreparedStatement ps = null;
       try
@@ -2769,7 +2765,7 @@
          
          ps.setLong(1, tx.getId());
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -2864,7 +2860,7 @@
          
          ps.setLong(1, tx.getId());        
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -2875,7 +2871,7 @@
          ps = conn.prepareStatement(getSQLStatement("COMMIT_MESSAGE_REF2"));
          ps.setLong(1, tx.getId());         
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -2910,7 +2906,7 @@
          
          ps.setLong(1, tx.getId());         
          
-         int rows = ps.executeUpdate();
+         int rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -2922,7 +2918,7 @@
          ps = conn.prepareStatement(getSQLStatement("ROLLBACK_MESSAGE_REF2"));
          ps.setLong(1, tx.getId());
          
-         rows = ps.executeUpdate();
+         rows = updateWithRetry(ps);
          
          if (trace)
          {
@@ -3240,6 +3236,16 @@
       log.trace("Batch update " + name + ", " + action + " total of " + count + " rows");
    }
    
+   protected int updateWithRetry(PreparedStatement ps) throws Exception
+   {
+      return updateWithRetry(ps, false)[0];
+   }
+   
+   protected int[] updateWithRetryBatch(PreparedStatement ps) throws Exception
+   {
+      return updateWithRetry(ps, true);
+   }
+   
    //PersistentServiceSupport overrides ----------------------------
    
    protected Map getDefaultDDLStatements()
@@ -3336,6 +3342,60 @@
    
    // Private -------------------------------------------------------
    
+   private int[] updateWithRetry(PreparedStatement ps, boolean batch) throws Exception
+   {
+      final int MAX_TRIES = 25;      
+      
+      int rows = 0;
+      
+      int[] rowsArr = null;
+      
+      int tries = 0;
+      
+      while (true)
+      {
+         try
+         {
+            if (batch)
+            {
+               rowsArr = ps.executeBatch();
+            }
+            else
+            {
+               rows = ps.executeUpdate();
+            }
+            
+            if (tries > 0)
+            {
+               log.warn("Update worked after retry");
+            }
+            break;
+         }
+         catch (SQLException e)
+         {
+            log.warn("SQLException caught - assuming deadlock detected, try:" + (tries + 1), e);
+            tries++;
+            if (tries == MAX_TRIES)
+            {
+               log.error("Retried " + tries + " times, now giving up");
+               throw new IllegalStateException("Failed to update references");
+            }
+            log.warn("Trying again after a pause");
+            //Now we wait for a random amount of time to minimise risk of deadlock
+            Thread.sleep((long)(Math.random() * 500));
+         }  
+      }
+      
+      if (batch)
+      {
+         return rowsArr;
+      }
+      else
+      {
+         return new int[] { rows };
+      }
+   }
+   
    private List getMessageChannelPair(String sqlQuery, long transactionId) throws Exception
    {
       if (trace) log.trace("loading message and channel ids for tx [" + transactionId + "]");

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/LocalClusteredQueue.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -364,17 +364,14 @@
                
                synchronized (refLock)
                {
-                  synchronized (deliveryLock)
+                  ref = removeFirstInMemory();
+                  
+                  if (ref != null)
                   {
-                     ref = removeFirstInMemory();
+                     del = new SimpleDelivery(LocalClusteredQueue.this, ref);
                      
-                     if (ref != null)
-                     {
-                        del = new SimpleDelivery(LocalClusteredQueue.this, ref);
-                        
-                        deliveries.add(del);
-                     }                      
-                  }
+                     deliveringCount.increment();
+                  }                                        
                }                    
             }
             

Modified: trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/plugin/postoffice/cluster/RemoteQueueStub.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -109,7 +109,7 @@
       }
 
       if (trace) { log.trace(this + " accepting " + reference + " for delivery"); }
-      return new SimpleDelivery(this, reference, false);
+      return new SimpleDelivery(this, reference);
    }
 
    // Distributor implementation ------------------------------------
@@ -288,7 +288,7 @@
       return "RemoteQueueStub[" + channelID + "/" + name + " -> " + nodeID + "]";
    }
 
-   public void addDelivery(Delivery del)
+   public int deliveringCount()
    {
       throw new UnsupportedOperationException();
    }

Modified: trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -371,12 +371,6 @@
 
             try
             {
-               //At this point there won't be a delivery in the channel for this ref - since
-               //we won't have loaded it when the queue was loaded (since the stat column would have been '-')
-               //so we add it
-               
-               queue.addDelivery(del);
-               
                del.acknowledge(tx);
             }
             catch (Throwable t)

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/build.xml	2006-12-28 20:58:01 UTC (rev 1867)
@@ -364,7 +364,7 @@
 
    <target name="stress-tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
       <antcall target="invm-stress-tests"/>
-      <antcall target="remote-stress-tests"/>  <!-- default remoting configuration (socket) -->
+      <antcall target="remote-stress-tests"/> <!-- default remoting configuration (socket) -->
       <antcall target="remote-stress-tests">
          <param name="test.remoting" value="http"/>
       </antcall>

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleChannel.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -226,6 +226,11 @@
       throw new UnsupportedOperationException();
    }
 
+   public int deliveringCount()
+   {
+      throw new UnsupportedOperationException();
+   }
+
    // Package protected ---------------------------------------------
    
    // Protected -----------------------------------------------------

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryObserver.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryObserver.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryObserver.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -69,56 +69,6 @@
 
    // Public --------------------------------------------------------
 
-   public synchronized void waitForCancellation(Delivery delivery) throws Exception
-   {
-      waitForCancellation(delivery, 0);
-   }
-
-   /**
-    * Waits until the delivery is cancelled, or timeout expires. If the delivery is already
-    * cancelled, exits immediately.
-    */
-   public synchronized boolean waitForCancellation(Delivery delivery, long timeout) throws Exception
-   {
-      try
-      {
-         if (delivery.isCancelled())
-         {
-            return true;
-         }
-
-         if (toBeCancelled != null)
-         {
-            throw new IllegalStateException("already waiting for another delivery cancellation");
-         }
-
-         toBeCancelled = delivery;
-
-         if (timeout <= 0)
-         {
-            this.wait();
-         }
-         else
-         {
-            this.wait(timeout);
-         }
-
-         if (toBeCancelled == null)
-         {
-            return true;
-         }
-         else
-         {
-            log.warn("exiting on timeout");
-            return false;
-         }
-      }
-      finally
-      {
-         toBeCancelled = null;
-      }
-   }
-
    public synchronized boolean waitForAcknowledgment(Delivery delivery) throws Exception
    {
       return waitForAcknowledgment(delivery, 0);

Modified: trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/SimpleDeliveryTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -89,15 +89,6 @@
       assertTrue(delivery.isDone());
    }
    
-   public void testCancellation() throws Throwable
-   {
-      assertFalse(delivery.isCancelled());
-
-      delivery.cancel();
-
-      assertTrue(delivery.isCancelled());
-   }
-   
    public void testDoneIsSetWithTransaction() throws Throwable
    {
       //Calling acknowledge on a SimpleDelivery

Modified: trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/local/base/PagingFilteredQueueTestBase.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -2306,11 +2306,10 @@
       Delivery delivery = queue.handle(observer, ref, null);
 
       assertTrue(delivery.isDone());
+   
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
-
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
       Message ackm = (Message)acknowledging.get(0);
@@ -2389,9 +2388,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -2403,13 +2401,15 @@
       // transacted acknowledgment
       r.acknowledge(ackm, tx);
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       tx.commit();
 
       assertTrue(queue.browse().isEmpty());
+      
+      deliveringCount = queue.deliveringCount();
+      assertEquals(0, deliveringCount);
    }
 
 
@@ -2437,9 +2437,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -2451,15 +2450,13 @@
       // transacted acknowledgment
       r.acknowledge(ackm, tx);
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       tx.rollback();
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       // acknowledge non-transactionally
       r.acknowledge(ackm, null);
@@ -2501,7 +2498,6 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -2544,7 +2540,6 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -2556,8 +2551,6 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
-
       tx.commit();
 
       assertTrue(queue.browse().isEmpty());
@@ -2593,7 +2586,6 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -2605,12 +2597,8 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
-
       tx.rollback();
 
-      assertEqualSets(refs, queue.browse());
-
       // acknowledge non-transactionally
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
       {
@@ -2699,11 +2687,8 @@
 
       assertTrue(delivery.isDone());
 
-      List stored = queue.browse();
-      assertEquals(1, stored.size());
-      Message sm = (Message)stored.iterator().next();
-      assertTrue(sm.isReliable());
-      assertEquals(0, sm.getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List received = r.getMessages();
       assertEquals(1, received.size());
@@ -2759,11 +2744,8 @@
 
       assertTrue(delivery.isDone());
 
-      List stored = queue.browse();
-      assertEquals(1, stored.size());
-      Message sm = (Message)stored.iterator().next();
-      assertTrue(sm.isReliable());
-      assertEquals(0, sm.getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List received = r.getMessages();
       assertEquals(1, received.size());
@@ -2775,11 +2757,8 @@
 
       r.acknowledge(rm, tx);
 
-      stored = queue.browse();
-      assertEquals(1, stored.size());
-      sm = (Message)stored.iterator().next();
-      assertTrue(sm.isReliable());
-      assertEquals(0, sm.getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       tx.commit();
 
@@ -2869,7 +2848,6 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -2928,7 +2906,6 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -2939,8 +2916,6 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
-
       tx.commit();
 
       assertTrue(queue.browse().isEmpty());
@@ -2987,9 +2962,8 @@
 
       tx.commit();
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -3040,7 +3014,6 @@
 
       tx.commit();
 
-      assertEqualSets(refs, queue.browse());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -3156,11 +3129,8 @@
 
       tx.commit();
 
-      List stored = queue.browse();
-      assertEquals(1, stored.size());
-      Message sm = (Message)stored.iterator().next();
-      assertTrue(sm.isReliable());
-      assertEquals(0, sm.getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);      
 
       List received = r.getMessages();
       assertEquals(1, received.size());
@@ -3337,7 +3307,9 @@
 
       tx.commit();
 
-      assertEqualSets(refs, queue.browse());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(NUMBER_OF_MESSAGES, deliveringCount);
+      
       assertEqualSets(refs, r.getMessages());
    }
 
@@ -3386,7 +3358,8 @@
 
       tx.commit();
 
-      assertEqualSets(refs, queue.browse());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(NUMBER_OF_MESSAGES, deliveringCount);
       assertEqualSets(refs, r.getMessages());
    }
 
@@ -4882,9 +4855,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -4964,9 +4936,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -4978,9 +4949,8 @@
       // transacted acknowledgment
       r.acknowledge(ackm, tx);
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       tx.commit();
 
@@ -5012,9 +4982,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -5026,15 +4995,13 @@
       // transacted acknowledgment
       r.acknowledge(ackm, tx);
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       tx.rollback();
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       // acknowledge non-transactionally
       r.acknowledge(ackm, null);
@@ -5076,7 +5043,7 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -5119,7 +5086,7 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -5131,7 +5098,7 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
 
       tx.commit();
 
@@ -5168,7 +5135,7 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -5180,11 +5147,11 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
 
       tx.rollback();
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
 
       // acknowledge non-transactionally
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -5230,9 +5197,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -5366,9 +5332,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -5380,9 +5345,8 @@
       // transacted acknowledgment
       r.acknowledge(ackm, tx);
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       tx.commit();
 
@@ -5415,9 +5379,8 @@
 
       assertTrue(delivery.isDone());
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -5429,15 +5392,13 @@
       // transacted acknowledgment
       r.acknowledge(ackm, tx);
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       tx.rollback();
 
-      delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      deliveringCount = queue.deliveringCount();      
+      assertEquals(1, deliveringCount);
 
       // acknowledge non-transactionally
       r.acknowledge(ackm, null);
@@ -5480,7 +5441,8 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
+      
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -5523,7 +5485,7 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -5535,7 +5497,7 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
 
       tx.commit();
 
@@ -5572,7 +5534,7 @@
          assertTrue(delivery.isDone());
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       Transaction tx = tr.createTransaction();
@@ -5584,11 +5546,11 @@
          r.acknowledge(ackm, tx);
       }
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
 
       tx.rollback();
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
 
       // acknowledge non-transactionally
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -5644,9 +5606,8 @@
 
       tx.commit();
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -5698,7 +5659,7 @@
 
       tx.commit();
 
-      assertEqualSets(refs, queue.browse());
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -5750,9 +5711,8 @@
 
       tx.commit();
 
-      List delivering = queue.browse();
-      assertEquals(1, delivering.size());
-      assertEquals(0, ((Message)delivering.get(0)).getMessageID());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List acknowledging = r.getMessages();
       assertEquals(1, acknowledging.size());
@@ -5802,8 +5762,9 @@
       assertTrue(r.getMessages().isEmpty());
 
       tx.commit();
-
-      assertEqualSets(refs, queue.browse());
+      
+      
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -5855,8 +5816,8 @@
       assertTrue(r.getMessages().isEmpty());
 
       tx.commit();
-
-      assertEqualSets(refs, queue.browse());
+      
+      assertEquals(NUMBER_OF_MESSAGES, queue.deliveringCount());
       assertEqualSets(refs, r.getMessages());
 
       for(Iterator i = r.getMessages().iterator(); i.hasNext();)
@@ -6232,7 +6193,8 @@
       // receiver explicitely asks for message
       receiver.requestMessages();
 
-      assertEquals(1, queue.browse().size());
+      int deliveringCount = queue.deliveringCount();
+      assertEquals(1, deliveringCount);
 
       List messages = receiver.getMessages();
       assertEquals(1, messages.size());
@@ -6368,7 +6330,7 @@
       // receiver explicitely asks for message
       receiver.requestMessages();
 
-      assertEquals(1, queue.browse().size());
+      assertEquals(1, queue.deliveringCount());
 
       List messages = receiver.getMessages();
       assertEquals(1, messages.size());

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_2PCTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_2PCTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_2PCTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -76,7 +76,7 @@
       MessageReference[] refs2 = new MessageReference[150];
       
       //Send 50 refs to both channels
-  
+      
       Transaction tx = this.createXATx();
       for (int i = 0; i < 50; i++)
       {
@@ -94,7 +94,7 @@
       }
       tx.prepare();
       tx.commit();
-      
+        
       //Queue1
       List refIds = getReferenceIdsOrderedByPageOrd(queue1.getChannelID());
       assertEquals(0, refIds.size());
@@ -105,8 +105,8 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
-      
+      assertEquals(0, queue1.deliveringCount());
+       
       //Queue2
       
       refIds = getReferenceIdsOrderedByPageOrd(queue2.getChannelID());
@@ -118,8 +118,8 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
-            
+      assertEquals(0, queue2.deliveringCount());
+           
       //Msgs
       
       assertEquals(50, ms.size());
@@ -148,7 +148,7 @@
       }
       tx.prepare();
       tx.commit();
-      
+       
       //Queue1
       refIds = getReferenceIdsOrderedByPageOrd(queue1.getChannelID());
               
@@ -160,8 +160,8 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
-      
+      assertEquals(0, queue1.deliveringCount());
+        
       //Queue2
       
       refIds = getReferenceIdsOrderedByPageOrd(queue2.getChannelID());
@@ -173,7 +173,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -181,21 +181,19 @@
       
       msgIds = getMessageIds();
       assertEquals(25, msgIds.size());
-      
-      
-      
+       
       // Add 25 more
       tx = this.createXATx();
       for (int i = 75; i < 100; i++)
       {
          msgs[i] = CoreMessageFactory.createCoreMessage(i, false, null);
-         
+
          refs1[i] = ms.reference(msgs[i]);
                 
          queue1.handle(null, refs1[i], tx); 
          
          refs1[i].releaseMemoryReference();
-         
+
          refs2[i] = ms.reference(msgs[i]);
          
          queue2.handle(null, refs2[i], tx); 
@@ -216,7 +214,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -229,7 +227,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -238,7 +236,6 @@
       msgIds = getMessageIds();
       assertEquals(50, msgIds.size());
       
-      
       // Add 50 more
       tx = this.createXATx();
       for (int i = 100; i < 150; i++)
@@ -259,7 +256,7 @@
       }
       tx.prepare();
       tx.commit();
-      
+         
       //Queue1
       refIds = getReferenceIdsOrderedByPageOrd(queue1.getChannelID());
                 
@@ -271,7 +268,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -284,19 +281,20 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
-            
+      assertEquals(0, queue2.deliveringCount());
+               
       //Msgs
       
       assertEquals(100, ms.size()); 
-      
+        
       msgIds = getMessageIds();
       assertEquals(100, msgIds.size());
-          
+             
       cancelDeliveries(queue1, 100);
-    
+      
       cancelDeliveries(queue2, 100);
       
+
       //Now consume them all
       
       this.consumeIn2PCTx(queue1, 0, refs1, 150);
@@ -314,8 +312,8 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
-      
+      assertEquals(0, queue1.deliveringCount());
+        
       //Queue2
       
       refIds = getReferenceIdsOrderedByPageOrd(queue2.getChannelID());
@@ -327,7 +325,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_NTTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_NTTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_NTTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -103,7 +103,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -116,7 +116,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -155,7 +155,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -168,7 +168,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -209,7 +209,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -222,7 +222,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -262,7 +262,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -275,7 +275,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -306,7 +306,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -319,7 +319,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_TTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_TTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_NP_TTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -107,7 +107,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -120,7 +120,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -161,7 +161,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -174,7 +174,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -216,7 +216,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -229,7 +229,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -270,7 +270,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -283,7 +283,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -314,7 +314,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -327,7 +327,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_2PCTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_2PCTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_2PCTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -105,7 +105,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -121,7 +121,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -165,7 +165,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -181,7 +181,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -227,7 +227,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -243,7 +243,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -288,7 +288,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -304,7 +304,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -335,7 +335,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -348,7 +348,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_NTTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_NTTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_NTTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -107,7 +107,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -123,7 +123,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -165,7 +165,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -181,7 +181,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -225,7 +225,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -241,7 +241,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -284,7 +284,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -300,7 +300,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -331,7 +331,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -344,7 +344,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_TTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_TTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/ChannelShare_P_TTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -107,7 +107,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -123,7 +123,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -166,7 +166,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -182,7 +182,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -227,7 +227,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -243,7 +243,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -287,7 +287,7 @@
       
       assertTrue(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -303,7 +303,7 @@
       
       assertTrue(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       
@@ -334,7 +334,7 @@
       
       assertFalse(queue1.isPaging());      
       
-      assertEquals(0, queue1.memoryDeliveryCount());
+      assertEquals(0, queue1.deliveringCount());
       
       //Queue2
       
@@ -347,7 +347,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
             
       //Msgs
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_2PCTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -111,7 +111,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       //Send one more ref
@@ -148,7 +148,7 @@
       assertTrue(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       //Send 9 more
@@ -186,7 +186,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -225,7 +225,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -263,7 +263,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -304,7 +304,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       //    Send 100 more refs then roll back
       tx = this.createXATx();
@@ -356,7 +356,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -398,7 +398,7 @@
       assertTrue(queue.isPaging());  
 
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -437,7 +437,7 @@
       assertTrue(queue.isPaging());  
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
                 
       
@@ -471,7 +471,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -508,7 +508,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
 
       //Consume one more
@@ -542,7 +542,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -576,7 +576,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -608,7 +608,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -640,7 +640,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -672,7 +672,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -710,7 +710,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -749,7 +749,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -789,7 +789,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
        
@@ -819,7 +819,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 20 deliveries
-      assertEquals(20, queue.memoryDeliveryCount());;      
+      assertEquals(20, queue.deliveringCount());;      
       
       
        
@@ -854,7 +854,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 13 deliveries
-      assertEquals(13, queue.memoryDeliveryCount());;      
+      assertEquals(13, queue.deliveringCount());;      
                
       //Cancel 3 more
       
@@ -889,7 +889,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 10 deliveries
-      assertEquals(10, queue.memoryDeliveryCount());;      
+      assertEquals(10, queue.deliveringCount());;      
       
             
       
@@ -926,7 +926,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
       //Now there should be 120 message left to consume
@@ -955,7 +955,7 @@
       assertFalse(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
                   
       //Consume the rest

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_NTTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -104,7 +104,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       //Send one more ref
@@ -136,7 +136,7 @@
       assertTrue(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
                   
       //Send 9 more
       
@@ -170,7 +170,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -206,7 +206,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -241,7 +241,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -279,7 +279,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -318,7 +318,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -357,7 +357,7 @@
       assertTrue(queue.isPaging());  
 
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -393,7 +393,7 @@
       assertTrue(queue.isPaging());  
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
                 
       
@@ -427,7 +427,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -464,7 +464,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -501,7 +501,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -535,7 +535,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -567,7 +567,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -599,7 +599,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -631,7 +631,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -666,7 +666,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -702,7 +702,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -739,7 +739,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
        
@@ -771,7 +771,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 20 deliveries
-      assertEquals(20, queue.memoryDeliveryCount());;      
+      assertEquals(20, queue.deliveringCount());;      
       
       
        
@@ -806,7 +806,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 13 deliveries
-      assertEquals(13, queue.memoryDeliveryCount());;      
+      assertEquals(13, queue.deliveringCount());;      
       
       
    
@@ -843,7 +843,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 10 deliveries
-      assertEquals(10, queue.memoryDeliveryCount());;      
+      assertEquals(10, queue.deliveringCount());;      
       
             
       
@@ -881,7 +881,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       assertEquals(0, queue.downCacheCount());
 
@@ -907,7 +907,7 @@
       assertEquals(70, ms.size());
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       assertEquals(0, queue.downCacheCount());
                   

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_NP_TTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -109,7 +109,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       //Send one more ref
@@ -145,7 +145,7 @@
       assertTrue(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       //Send 9 more
@@ -182,7 +182,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -220,7 +220,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -257,7 +257,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -297,7 +297,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       //Send 100 more refs then roll back
       tx = tr.createTransaction();
@@ -348,7 +348,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -389,7 +389,7 @@
       assertTrue(queue.isPaging());  
 
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -427,7 +427,7 @@
       assertTrue(queue.isPaging());  
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
                 
       
@@ -461,7 +461,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -498,7 +498,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -534,7 +534,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -568,7 +568,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -600,7 +600,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -632,7 +632,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -664,7 +664,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -701,7 +701,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -739,7 +739,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -778,7 +778,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
        
@@ -809,7 +809,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 20 deliveries
-      assertEquals(20, queue.memoryDeliveryCount());;      
+      assertEquals(20, queue.deliveringCount());;      
       
       
        
@@ -844,7 +844,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 13 deliveries
-      assertEquals(13, queue.memoryDeliveryCount());;      
+      assertEquals(13, queue.deliveringCount());;      
       
       
    
@@ -881,7 +881,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 10 deliveries
-      assertEquals(10, queue.memoryDeliveryCount());;      
+      assertEquals(10, queue.deliveringCount());;      
       
             
       
@@ -919,7 +919,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
       //Now there should be 120 message left to consume
@@ -948,7 +948,7 @@
       assertFalse(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
                   
       //Consume the rest

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_2PCTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -114,7 +114,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       //Send one more ref
@@ -155,7 +155,7 @@
       assertTrue(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       //Send 9 more
@@ -199,7 +199,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -243,7 +243,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -285,7 +285,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -330,7 +330,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       //    Send 100 more refs then roll back
       tx = this.createXATx();
@@ -386,7 +386,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -432,7 +432,7 @@
       assertTrue(queue.isPaging());  
 
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -475,7 +475,7 @@
       assertTrue(queue.isPaging());  
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
                             
       //Consume 1
@@ -513,7 +513,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -555,7 +555,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -596,7 +596,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -635,7 +635,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -673,7 +673,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -711,7 +711,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -749,7 +749,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -791,7 +791,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -834,7 +834,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -879,7 +879,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
        
@@ -916,7 +916,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 20 deliveries
-      assertEquals(20, queue.memoryDeliveryCount());;      
+      assertEquals(20, queue.deliveringCount());;      
       
       
        
@@ -957,7 +957,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 13 deliveries
-      assertEquals(13, queue.memoryDeliveryCount());;      
+      assertEquals(13, queue.deliveringCount());;      
       
       
    
@@ -999,7 +999,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 10 deliveries
-      assertEquals(10, queue.memoryDeliveryCount());;      
+      assertEquals(10, queue.deliveringCount());;      
       
             
       
@@ -1043,7 +1043,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
 
@@ -1080,7 +1080,7 @@
       assertFalse(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_NTTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -110,7 +110,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       //Send one more ref
@@ -148,7 +148,7 @@
       assertTrue(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       //Send 9 more
@@ -189,7 +189,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       //Send one more ref - should clear the down cache
       
@@ -227,7 +227,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -267,7 +267,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -310,7 +310,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -354,7 +354,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -398,7 +398,7 @@
       assertTrue(queue.isPaging());  
 
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -439,7 +439,7 @@
       assertTrue(queue.isPaging());  
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
                 
       
@@ -478,7 +478,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -519,7 +519,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -560,7 +560,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -599,7 +599,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -637,7 +637,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -675,7 +675,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -712,7 +712,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -751,7 +751,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -791,7 +791,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -833,7 +833,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
        
@@ -870,7 +870,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 20 deliveries
-      assertEquals(20, queue.memoryDeliveryCount());;      
+      assertEquals(20, queue.deliveringCount());;      
       
       
        
@@ -911,7 +911,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 13 deliveries
-      assertEquals(13, queue.memoryDeliveryCount());;      
+      assertEquals(13, queue.deliveringCount());;      
       
       
    
@@ -952,7 +952,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 10 deliveries
-      assertEquals(10, queue.memoryDeliveryCount());;      
+      assertEquals(10, queue.deliveringCount());;      
       
             
       
@@ -996,7 +996,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
 
@@ -1033,7 +1033,7 @@
       assertFalse(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_P_TTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -113,7 +113,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       //Send one more ref
@@ -153,7 +153,7 @@
       assertTrue(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       //Send 9 more
@@ -196,7 +196,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -239,7 +239,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -280,7 +280,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -324,7 +324,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -369,7 +369,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       //Send 100 more refs then roll back
       tx = tr.createTransaction();
@@ -423,7 +423,7 @@
       assertTrue(queue.isPaging());  
 
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -465,7 +465,7 @@
       assertTrue(queue.isPaging());  
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
                             
       //Consume 1
@@ -503,7 +503,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -545,7 +545,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -586,7 +586,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -625,7 +625,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -663,7 +663,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -701,7 +701,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -739,7 +739,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
             
       
       
@@ -780,7 +780,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -822,7 +822,7 @@
       assertFalse(queue.isPaging());
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       
@@ -866,7 +866,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify no deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
        
@@ -903,7 +903,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 20 deliveries
-      assertEquals(20, queue.memoryDeliveryCount());;      
+      assertEquals(20, queue.deliveringCount());;      
       
       
        
@@ -944,7 +944,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 13 deliveries
-      assertEquals(13, queue.memoryDeliveryCount());;      
+      assertEquals(13, queue.deliveringCount());;      
       
       
    
@@ -986,7 +986,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 10 deliveries
-      assertEquals(10, queue.memoryDeliveryCount());;      
+      assertEquals(10, queue.deliveringCount());;      
       
             
       
@@ -1030,7 +1030,7 @@
       assertTrue(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());;      
+      assertEquals(0, queue.deliveringCount());;      
       
       
 
@@ -1067,7 +1067,7 @@
       assertFalse(queue.isPaging());      
       
       //Verify 0 deliveries
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/paging/SingleChannel_ReloadTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -107,7 +107,7 @@
       
       assertTrue(queue.isPaging());      
       
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       //Stop and restart the persistence manager
       //All the paged refs will survive
@@ -140,7 +140,7 @@
       assertEquals(0, queue2.downCacheCount());
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
                    
       this.consume(queue2, 100, refs, 100);
       
@@ -153,7 +153,7 @@
       
       assertFalse(queue2.isPaging());      
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
       
       assertEquals(0, queue2.messageCount());
       
@@ -203,7 +203,7 @@
       
       assertTrue(queue.isPaging());      
       
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       //Stop and restart the persistence manager
       //Only the paged messages will survive
@@ -243,7 +243,7 @@
       
       this.consume(queue2, 100, refs, 100);
       
-      assertEquals(0, queue2.memoryDeliveryCount());
+      assertEquals(0, queue2.deliveringCount());
       
       assertEquals(0, queue2.messageCount());
       
@@ -293,7 +293,7 @@
       
       assertTrue(queue.isPaging());      
       
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       queue.removeAllReferences();
       
@@ -309,7 +309,7 @@
       
       assertFalse(queue.isPaging());      
       
-      assertEquals(0, queue.memoryDeliveryCount());
+      assertEquals(0, queue.deliveringCount());
       
       assertEquals(0, queue.messageCount());
       

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/DefaultPostOfficeTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -466,6 +466,11 @@
          msgs = receiver6.getMessages();
          assertNotNull(msgs);
          assertTrue(msgs.isEmpty());
+         
+         if (checkNoMessageData())
+         {
+            fail("data still in database");
+         }
       }
       finally
       {
@@ -474,10 +479,6 @@
             postOffice.stop();
          }
          
-         if (checkNoMessageData())
-         {
-            fail("data still in database");
-         }
       }
    
    }
@@ -511,8 +512,13 @@
                
          List msgs = receiver1.getMessages();
          assertNotNull(msgs);
-         assertTrue(msgs.isEmpty());             
+         assertTrue(msgs.isEmpty());  
          
+         if (checkNoMessageData())
+         {
+            fail("data still in database");
+         }
+         
       }
       finally
       {
@@ -521,10 +527,6 @@
             postOffice.stop();
          }
          
-         if (checkNoMessageData())
-         {
-            fail("data still in database");
-         }
       }
    }
    
@@ -626,6 +628,11 @@
          assertNotNull(msgs);
          assertTrue(msgs.isEmpty()); 
          
+         if (checkNoMessageData())
+         {
+            fail("data still in database");
+         }
+         
       }
       finally
       {
@@ -633,11 +640,7 @@
          {
             postOffice.stop();
          }
-         
-         if (checkNoMessageData())
-         {
-            fail("data still in database");
-         }
+        
       }
    }
    
@@ -981,21 +984,11 @@
          receiver2.acknowledge(msgRec1, tx);
          receiver2.acknowledge(msgRec2, tx);
          
-         msgs = queue1.browse();
-         assertNotNull(msgs);
-         assertEquals(2, msgs.size());
-         msgRec1 = (Message)msgs.get(0);
-         msgRec2 = (Message)msgs.get(1);
-         assertTrue(msgRec1 == msg5);
-         assertTrue(msgRec2 == msg6);
+         int deliveringCount = queue1.deliveringCount();
+         assertEquals(2, deliveringCount);
          
-         msgs = queue2.browse();
-         assertNotNull(msgs);
-         assertEquals(2, msgs.size());
-         msgRec1 = (Message)msgs.get(0);
-         msgRec2 = (Message)msgs.get(1);
-         assertTrue(msgRec1 == msg5);
-         assertTrue(msgRec2 == msg6);
+         deliveringCount = queue2.deliveringCount();
+         assertEquals(2, deliveringCount);
          
          tx.commit();
          
@@ -1048,55 +1041,38 @@
          receiver2.acknowledge(msgRec1, tx);
          receiver2.acknowledge(msgRec2, tx);
          
-         msgs = queue1.browse();
-         assertNotNull(msgs);
-         assertEquals(2, msgs.size());
-         msgRec1 = (Message)msgs.get(0);
-         msgRec2 = (Message)msgs.get(1);
-         assertTrue(msgRec1 == msg7);
-         assertTrue(msgRec2 == msg8);
+         deliveringCount = queue1.deliveringCount();
+         assertEquals(2, deliveringCount);
          
-         msgs = queue2.browse();
-         assertNotNull(msgs);
-         assertEquals(2, msgs.size());
-         msgRec1 = (Message)msgs.get(0);
-         msgRec2 = (Message)msgs.get(1);
-         assertTrue(msgRec1 == msg7);
-         assertTrue(msgRec2 == msg8);
+         deliveringCount = queue2.deliveringCount();
+         assertEquals(2, deliveringCount);
          
          tx.rollback();
          
-         msgs = queue1.browse();
-         assertNotNull(msgs);
-         assertEquals(2, msgs.size());
-         msgRec1 = (Message)msgs.get(0);
-         msgRec2 = (Message)msgs.get(1);
-         assertTrue(msgRec1 == msg7);
-         assertTrue(msgRec2 == msg8);
+         deliveringCount = queue1.deliveringCount();
+         assertEquals(2, deliveringCount);                  
+         
          receiver1.acknowledge(msgRec1, null);
          receiver1.acknowledge(msgRec2, null);
          
-         msgs = queue2.browse();
-         assertNotNull(msgs);
-         assertEquals(2, msgs.size());
-         msgRec1 = (Message)msgs.get(0);
-         msgRec2 = (Message)msgs.get(1);
-         assertTrue(msgRec1 == msg7);
-         assertTrue(msgRec2 == msg8);    
+         deliveringCount = queue2.deliveringCount();
+         assertEquals(2, deliveringCount);     
+         
+         
          receiver2.acknowledge(msgRec1, null);
          receiver2.acknowledge(msgRec2, null);
+         
+         if (checkNoMessageData())
+         {
+            fail("data still in database");
+         }
       }
       finally
       {
          if (postOffice != null)
          {
             postOffice.stop();
-         }
-         
-         if (checkNoMessageData())
-         {
-            fail("data still in database");
-         }
+         }         
       }
    }
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultClusteredPostOfficeTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -773,7 +773,11 @@
          msgs = queue3.browse();
          assertNotNull(msgs);
          assertTrue(msgs.isEmpty()); 
-         
+                  
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }
       }
       finally
       {
@@ -787,10 +791,6 @@
             office2.stop();
          }
          
-         if (checkNoMessageData())
-         {
-            fail("Message data still in database");
-         }
       }
    }
    
@@ -932,6 +932,11 @@
             assertTrue(msgs.isEmpty()); 
             receivers[i].clear();
          }
+         
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }
 
       }
       finally
@@ -966,11 +971,7 @@
             }
             office2.stop();
          }
-         
-         if (checkNoMessageData())
-         {
-            fail("Message data still in database");
-         }
+        
       }
    }
    
@@ -1196,7 +1197,12 @@
          this.checkEmpty(receiver1);         
          this.checkEmpty(receiver2);
          checkContainsAndAcknowledge(msg, receiver3, sub2);           
-                 
+                         
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }
+         
       }
       finally
       {
@@ -1215,11 +1221,6 @@
             office3.stop();
          }
          
-         
-         if (checkNoMessageData())
-         {
-            fail("Message data still in database");
-         }
       }
    }
    
@@ -1581,7 +1582,11 @@
          
          //n7
          checkContainsAndAcknowledge(msgs, receiver14, sharedDurable5);
-        
+         
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }        
       }
       finally
       {
@@ -1661,11 +1666,7 @@
             }
             office7.stop();
          }
-         
-         if (checkNoMessageData())
-         {
-            fail("Message data still in database");
-         }
+        
       }
    }
    
@@ -1873,16 +1874,11 @@
                         
             receivers[i].acknowledge(msgRec1, tx);
             receivers[i].acknowledge(msgRec2, tx);
-                        
-            msgs = queues[i].browse();
+             
+            int deliveringCount = queues[i].deliveringCount();
             
-            assertNotNull(msgs);
-            assertEquals(2, msgs.size());
-            msgRec1 = (Message)msgs.get(0);
-            assertEquals(msg1.getMessageID(), msgRec1.getMessageID());
-            msgRec2 = (Message)msgs.get(1);
-            assertEquals(msg2.getMessageID(), msgRec2.getMessageID());
-            
+            assertEquals(2, deliveringCount);
+                       
             receivers[i].clear();
          }
          
@@ -1938,15 +1934,10 @@
                         
             receivers[i].acknowledge(msgRec1, tx);
             receivers[i].acknowledge(msgRec2, tx);
-                        
-            msgs = queues[i].browse();
+               
+            int deliveringCount = queues[i].deliveringCount();
             
-            assertNotNull(msgs);
-            assertEquals(2, msgs.size());
-            msgRec1 = (Message)msgs.get(0);
-            assertEquals(msg1.getMessageID(), msgRec1.getMessageID());
-            msgRec2 = (Message)msgs.get(1);
-            assertEquals(msg2.getMessageID(), msgRec2.getMessageID());
+            assertEquals(2, deliveringCount);
             
          }
          
@@ -1972,14 +1963,9 @@
             Message msgRec2 = (Message)msgs.get(1);
             assertEquals(msg2.getMessageID(), msgRec2.getMessageID());      
                                  
-            msgs = queues[i].browse();
+            int deliveringCount = queues[i].deliveringCount();
             
-            assertNotNull(msgs);
-            assertEquals(2, msgs.size());
-            msgRec1 = (Message)msgs.get(0);
-            assertEquals(msg1.getMessageID(), msgRec1.getMessageID());
-            msgRec2 = (Message)msgs.get(1);
-            assertEquals(msg2.getMessageID(), msgRec2.getMessageID());
+            assertEquals(2, deliveringCount);
             
             receivers[i].acknowledge(msgRec1, null);
             receivers[i].acknowledge(msgRec2, null);
@@ -2134,14 +2120,9 @@
             receivers[i].acknowledge(msgRec1, tx);
             receivers[i].acknowledge(msgRec2, tx);
                         
-            msgs = queues[i].browse();
+            int deliveringCount = queues[i].deliveringCount();
             
-            assertNotNull(msgs);
-            assertEquals(2, msgs.size());
-            msgRec1 = (Message)msgs.get(0);
-            assertEquals(msg1.getMessageID(), msgRec1.getMessageID());
-            msgRec2 = (Message)msgs.get(1);
-            assertEquals(msg2.getMessageID(), msgRec2.getMessageID());
+            assertEquals(2, deliveringCount);
             
             receivers[i].clear();
          }
@@ -2203,14 +2184,9 @@
             receivers[i].acknowledge(msgRec2, tx);
             
             
-            msgs = queues[i].browse();
+            int deliveringCount = queues[i].deliveringCount();
             
-            assertNotNull(msgs);
-            assertEquals(2, msgs.size());
-            msgRec1 = (Message)msgs.get(0);
-            assertEquals(msg1.getMessageID(), msgRec1.getMessageID());
-            msgRec2 = (Message)msgs.get(1);
-            assertEquals(msg2.getMessageID(), msgRec2.getMessageID());
+            assertEquals(2, deliveringCount);
          }
          
          
@@ -2237,20 +2213,19 @@
             Message msgRec2 = (Message)msgs.get(1);
             assertEquals(msg2.getMessageID(), msgRec2.getMessageID());      
                                               
-            msgs = queues[i].browse();
+            int deliveringCount = queues[i].deliveringCount();
             
-            assertNotNull(msgs);
-            assertEquals(2, msgs.size());
-            msgRec1 = (Message)msgs.get(0);
-            assertEquals(msg1.getMessageID(), msgRec1.getMessageID());
-            msgRec2 = (Message)msgs.get(1);
-            assertEquals(msg2.getMessageID(), msgRec2.getMessageID());
+            assertEquals(2, deliveringCount);
             
             receivers[i].acknowledge(msgRec1, null);
             receivers[i].acknowledge(msgRec2, null);             
             
             receivers[i].clear();
          }
+         if (checkNoMessageData())
+         {
+            fail("Message data still in database");
+         }
       }
       finally
       {
@@ -2286,10 +2261,6 @@
             office2.stop();
          }
          
-         if (checkNoMessageData())
-         {
-            fail("Message data still in database");
-         }
       }
    }
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultMessagePullPolicyTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -381,6 +381,12 @@
          // TODO Auto-generated method stub
          
       }
+
+      public int deliveringCount()
+      {
+         // TODO Auto-generated method stub
+         return 0;
+      }
       
    }
 

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/DefaultRouterTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -618,6 +618,12 @@
          // TODO Auto-generated method stub
          
       }
+
+      public int deliveringCount()
+      {
+         // TODO Auto-generated method stub
+         return 0;
+      }
       
    }
    

Modified: trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/core/plugin/postoffice/cluster/RedistributionWithDefaultMessagePullPolicyTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -194,19 +194,19 @@
          
          log.info("r2 " + receiver2.getMessages().size());
          
-         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());
+         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(0, queue2.memoryRefCount());
-         assertEquals(1, queue2.memoryDeliveryCount());
+         assertEquals(1, queue2.deliveringCount());
          
          this.acknowledgeAll(receiver2);
          
          assertEquals(0, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
          
          assertTrue(office1.getHoldingTransactions().isEmpty());         
          assertTrue(office2.getHoldingTransactions().isEmpty());
@@ -289,14 +289,14 @@
          assertEquals(1, office1.getHoldingTransactions().size());         
          assertTrue(office2.getHoldingTransactions().isEmpty());
          
-         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());
+         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(1, queue1.memoryDeliveryCount());
+         assertEquals(1, queue1.deliveringCount());
          
          assertEquals(0, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
          
          //Now kill office 2 - this should cause office1 to remove the dead held transaction
          
@@ -308,7 +308,7 @@
          //The delivery should be cancelled back to the queue too
          
          assertEquals(1, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
             
       }
@@ -389,11 +389,11 @@
          assertEquals(1, office1.getHoldingTransactions().size());         
          assertTrue(office2.getHoldingTransactions().isEmpty());
          
-         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());
+         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(1, queue1.memoryDeliveryCount());
+         assertEquals(1, queue1.deliveringCount());
             
          //Now kill office 2 - this should cause office1 to remove the dead held transaction
          
@@ -405,7 +405,7 @@
          //The delivery should be committed
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
       }
       finally
@@ -486,14 +486,14 @@
          assertTrue(office2.getHoldingTransactions().isEmpty());        
          assertTrue(office2.getHoldingTransactions().isEmpty());
          
-         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());
+         log.info("queue1 refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2 refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());
          
          assertEquals(1, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(0, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());                     
+         assertEquals(0, queue2.deliveringCount());                     
       }
       finally
       {
@@ -561,26 +561,26 @@
          //Check the sizes
          
          log.info("Here are the sizes:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
                
          assertEquals(NUM_MESSAGES, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(NUM_MESSAGES, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
            
          assertEquals(NUM_MESSAGES, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(NUM_MESSAGES, queue4.memoryRefCount());
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertEquals(NUM_MESSAGES, queue5.memoryRefCount());
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
          
          SimpleReceiver receiver = new SimpleReceiver("blah", SimpleReceiver.ACCEPTING);
          
@@ -591,26 +591,26 @@
          Thread.sleep(7000);
          
          log.info("Here are the sizes:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(NUM_MESSAGES * 5, queue1.memoryDeliveryCount());
+         assertEquals(NUM_MESSAGES * 5, queue1.deliveringCount());
          
          assertEquals(0, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
            
          assertEquals(0, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(0, queue4.memoryRefCount());
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertEquals(0, queue5.memoryRefCount());
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
          
          List messages = receiver.getMessages();
          
@@ -630,7 +630,7 @@
          receiver.clear();
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertTrue(office1.getHoldingTransactions().isEmpty());
          assertTrue(office2.getHoldingTransactions().isEmpty());
@@ -724,26 +724,26 @@
          //Check the sizes
          
          log.info("Here are the sizes 1:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
                
          assertEquals(NUM_MESSAGES, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(NUM_MESSAGES, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
            
          assertEquals(NUM_MESSAGES, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(NUM_MESSAGES, queue4.memoryRefCount());
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertEquals(NUM_MESSAGES, queue5.memoryRefCount());
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
          
          assertTrue(office1.getHoldingTransactions().isEmpty());
          assertTrue(office2.getHoldingTransactions().isEmpty());
@@ -766,17 +766,17 @@
          queue1.deliver(false);         
          Thread.sleep(1000);         
          assertEquals(NUM_MESSAGES - 5, queue1.memoryRefCount());
-         assertEquals(5, queue1.memoryDeliveryCount());
+         assertEquals(5, queue1.deliveringCount());
          
          acknowledgeAll(receiver1);
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          receiver1.setMaxRefs(0);
          
          receiver2.setMaxRefs(10);         
          queue2.deliver(false);         
          Thread.sleep(1000);
          assertEquals(NUM_MESSAGES - 10, queue2.memoryRefCount());
-         assertEquals(10, queue2.memoryDeliveryCount());
+         assertEquals(10, queue2.deliveringCount());
          acknowledgeAll(receiver2);
          receiver2.setMaxRefs(0);
                   
@@ -784,7 +784,7 @@
          queue3.deliver(false);         
          Thread.sleep(1000);
          assertEquals(NUM_MESSAGES - 15, queue3.memoryRefCount());
-         assertEquals(15, queue3.memoryDeliveryCount());
+         assertEquals(15, queue3.deliveringCount());
          acknowledgeAll(receiver3);
          receiver3.setMaxRefs(0);
          
@@ -792,7 +792,7 @@
          queue4.deliver(false);         
          Thread.sleep(1000);
          assertEquals(NUM_MESSAGES - 20, queue4.memoryRefCount());
-         assertEquals(20, queue4.memoryDeliveryCount());
+         assertEquals(20, queue4.deliveringCount());
          acknowledgeAll(receiver4);
          receiver4.setMaxRefs(0);
          
@@ -800,7 +800,7 @@
          queue5.deliver(false);         
          Thread.sleep(1000);
          assertEquals(NUM_MESSAGES - 25, queue5.memoryRefCount());
-         assertEquals(25, queue5.memoryDeliveryCount());
+         assertEquals(25, queue5.deliveringCount());
          acknowledgeAll(receiver5);
          receiver5.setMaxRefs(0);
          
@@ -813,11 +813,11 @@
          assertTrue(office5.getHoldingTransactions().isEmpty());
          
          log.info("Here are the sizes 2:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
      
          //Consume the rest from queue 5
          receiver5.setMaxRefs(NUM_MESSAGES - 25);
@@ -827,34 +827,34 @@
          log.info("receiver5 msgs:" + receiver5.getMessages().size());
          
          log.info("Here are the sizes 3:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
          
          //This will result in an extra one being pulled from queue1 - we cannot avoid this
          //This is because the channel does not know that the receiver is full unless it tries
          //with a ref so it needs to retrieve one
      
          assertEquals(NUM_MESSAGES - 6, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 10, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
           
          assertEquals(NUM_MESSAGES - 15, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 20, queue4.memoryRefCount());
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertEquals(1, queue5.memoryRefCount());         
-         assertEquals(NUM_MESSAGES - 25, queue5.memoryDeliveryCount());
+         assertEquals(NUM_MESSAGES - 25, queue5.deliveringCount());
          
          acknowledgeAll(receiver5);
          
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
          
          receiver5.setMaxRefs(0);
          
@@ -873,31 +873,31 @@
          Thread.sleep(5000);
            
          log.info("Here are the sizes 4:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 11, queue1.memoryRefCount());
           
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 10, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
           
          assertEquals(NUM_MESSAGES - 15, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 20, queue4.memoryRefCount());
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertEquals(1, queue5.memoryRefCount());          
-         assertEquals(5, queue5.memoryDeliveryCount());
+         assertEquals(5, queue5.deliveringCount());
                
          acknowledgeAll(receiver5);
 
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
          
          receiver1.setMaxRefs(0);
            
@@ -914,30 +914,30 @@
          Thread.sleep(2000);
           
          log.info("Here are the sizes 5:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 11, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 11, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
           
          assertEquals(NUM_MESSAGES - 15, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(NUM_MESSAGES - 20, queue4.memoryRefCount());
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertEquals(1, queue5.memoryRefCount());          
-         assertEquals(1, queue5.memoryDeliveryCount());
+         assertEquals(1, queue5.deliveringCount());
                   
          acknowledgeAll(receiver5);
          
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
          
          receiver5.setMaxRefs(0);
          
@@ -954,30 +954,30 @@
          Thread.sleep(7000);
          
          log.info("Here are the sizes 6:");         
-         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.memoryDeliveryCount());
-         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.memoryDeliveryCount());         
-         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.memoryDeliveryCount());         
-         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.memoryDeliveryCount());         
-         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.memoryDeliveryCount());
+         log.info("queue1, refs:" + queue1.memoryRefCount() + " dels:" + queue1.deliveringCount());
+         log.info("queue2, refs:" + queue2.memoryRefCount() + " dels:" + queue2.deliveringCount());         
+         log.info("queue3, refs:" + queue3.memoryRefCount() + " dels:" + queue3.deliveringCount());         
+         log.info("queue4, refs:" + queue4.memoryRefCount() + " dels:" + queue4.deliveringCount());         
+         log.info("queue5, refs:" + queue5.memoryRefCount() + " dels:" + queue5.deliveringCount());
          
          assertEquals(0, queue1.memoryRefCount());
-         assertEquals(0, queue1.memoryDeliveryCount());
+         assertEquals(0, queue1.deliveringCount());
          
          assertEquals(0, queue2.memoryRefCount());
-         assertEquals(0, queue2.memoryDeliveryCount());
+         assertEquals(0, queue2.deliveringCount());
           
          assertEquals(0, queue3.memoryRefCount());
-         assertEquals(0, queue3.memoryDeliveryCount());
+         assertEquals(0, queue3.deliveringCount());
          
          assertEquals(0, queue4.memoryRefCount());
-         assertEquals(NUM_MESSAGES - 15 + NUM_MESSAGES - 20 + NUM_MESSAGES - 11 + NUM_MESSAGES - 11 + 1, queue4.memoryDeliveryCount());
+         assertEquals(NUM_MESSAGES - 15 + NUM_MESSAGES - 20 + NUM_MESSAGES - 11 + NUM_MESSAGES - 11 + 1, queue4.deliveringCount());
          
          assertEquals(0, queue5.memoryRefCount());          
-         assertEquals(0, queue5.memoryDeliveryCount());
+         assertEquals(0, queue5.deliveringCount());
                   
          acknowledgeAll(receiver4);
          
-         assertEquals(0, queue4.memoryDeliveryCount());
+         assertEquals(0, queue4.deliveringCount());
          
          assertTrue(office1.getHoldingTransactions().isEmpty());
          assertTrue(office2.getHoldingTransactions().isEmpty());

Modified: trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java	2006-12-28 16:34:39 UTC (rev 1866)
+++ trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java	2006-12-28 20:58:01 UTC (rev 1867)
@@ -549,11 +549,11 @@
          prod.setDeliveryMode(DeliveryMode.PERSISTENT);
    
          // Create 1 durable subscription and 1 non-durable subscription
-         TopicSubscriber tsDurable = s.createDurableSubscriber(topic, "Durable1");
-         TopicSubscriber tsNonDurable = s.createSubscriber(topic);
+         s.createDurableSubscriber(topic, "Durable1");
+         s.createSubscriber(topic);
          
          // Send 1 message
-         prod.send(s.createTextMessage("First one"));
+         prod.send(s.createTextMessage("First one"));         
          
          ObjectName destObjectName = 
             new ObjectName("jboss.messaging.destination:service=Topic,name=TopicRemoveAllMessages");
@@ -578,18 +578,12 @@
    
          // Try to receive messages from the two subscriptions, should be null
          
-         //This is not valid - the messages will already be in the consumer endpoints and
-         //possibly the client consumers
-//         assertNull(tsDurable.receiveNoWait());
-//         assertNull(tsNonDurable.receiveNoWait());
-         
          listMsg = (List)ServerManagement.invoke(destObjectName, 
                   "listMessagesDurableSub",
                   new Object[] {"Durable1", "Client1", null},
                   new String[] {"java.lang.String", "java.lang.String", "java.lang.String"});         
          assertEquals(0, listMsg.size());
-         
-         
+                  
          // Now close the connection
          conn.close();
          
@@ -606,19 +600,16 @@
          listMsg = (List)ServerManagement.invoke(destObjectName, 
                   "listMessagesDurableSub",
                   new Object[] {"Durable1", "Client1", null},
-                  new String[] {"java.lang.String", "java.lang.String", "java.lang.String"});         
-         assertEquals(1, listMsg.size());
+                  new String[] {"java.lang.String", "java.lang.String", "java.lang.String"});   
          
+         assertEquals(2, listMsg.size());
+
          // Start the connection for delivery
          conn.start();
          
          // Remove all messages from the topic
          ServerManagement.invoke(destObjectName, "removeAllMessages", null, null);
    
-         // Restore the durable subscription now, the message should be already gone
-         tsDurable = s.createDurableSubscriber(topic, "Durable1");
-         //assertNull(tsDurable.receiveNoWait());
-         
          listMsg = (List)ServerManagement.invoke(destObjectName, 
                   "listMessagesDurableSub",
                   new Object[] {"Durable1", "Client1", null},
@@ -670,49 +661,26 @@
          // There should be 3 subscriptions
          ObjectName destObjectName = 
             new ObjectName("jboss.messaging.destination:service=Topic,name=TopicMessageList");
+         
          String strSub = (String)ServerManagement.invoke(destObjectName, "listSubscriptionsAsText", null, null);
-         // Each subscription will have the same message
-         // Durable sub
-         List listMsg = (List)ServerManagement.invoke(destObjectName, 
-               "listMessagesDurableSub",
-               new Object[] {"SubscriberA", "Client1", null},
-               new String[] {"java.lang.String", "java.lang.String", "java.lang.String"});
-         assertEquals(1, listMsg.size());
-         assertTrue(listMsg.get(0) instanceof TextMessage);
-         assertEquals(((TextMessage)listMsg.get(0)).getText(), "First one");
          
-         // Non-durable sub 1
-         int ptr1 = strSub.indexOf("Non-durable, subscriptionID=\"");
-         int ptr2 = strSub.indexOf("\"", ptr1 + 30);
-         String sub = strSub.substring(ptr1 + 29, ptr2);
-         long sID1 = Long.parseLong(sub);
-         listMsg = (List)ServerManagement.invoke(destObjectName, 
-               "listMessagesNonDurableSub",
-               new Object[] {new Long(sID1), null},
-               new String[] {"long", "java.lang.String"});
-         assertEquals(1, listMsg.size());
-         assertTrue(listMsg.get(0) instanceof TextMessage);
-         assertEquals(((TextMessage)listMsg.get(0)).getText(), "First one");
-   
-         // Non-durable sub 2
-         strSub = strSub.substring(ptr2 + 1);
-         ptr1 = strSub.indexOf("Non-durable, subscriptionID=\"");
-         ptr2 = strSub.indexOf("\"", ptr1 + 30);
-         sub = strSub.substring(ptr1 + 29, ptr2);
-         long sID2 = Long.parseLong(sub);
-         assertFalse(sID1 == sID2);
-         listMsg = (List)ServerManagement.invoke(destObjectName, 
-               "listMessagesNonDurableSub",
-               new Object[] {new Long(sID2), null},
-               new String[] {"long", "java.lang.String"});
-         assertEquals(1, listMsg.size());
-         assertTrue(listMsg.get(0) instanceof TextMessage);
-         assertEquals(((TextMessage)listMsg.get(0)).getText(), "First one");
          
+         // Note that listing the messages ONLY list those ones not in the process of delivery
+         // Therefore the following is invalid
+         
+         
          // Send another message
          prod.send(s.createTextMessage("Second one"));
+                  
          
-         // The durable subscription has 2 messages
+         List listMsg = (List)ServerManagement.invoke(destObjectName, 
+                  "listMessagesDurableSub",
+                  new Object[] {"SubscriberA", "", null},
+                  new String[] {"java.lang.String", "java.lang.String", "java.lang.String"});
+         assertEquals(0, listMsg.size());
+            
+         conn.close();
+         
          listMsg = (List)ServerManagement.invoke(destObjectName, 
                "listMessagesDurableSub",
                new Object[] {"SubscriberA", "", null},
@@ -723,8 +691,6 @@
          assertEquals(((TextMessage)listMsg.get(0)).getText(), "First one");
          assertEquals(((TextMessage)listMsg.get(1)).getText(), "Second one");
          
-         // Clean-up
-         conn.close();
       }
       finally
       {



From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 16:18:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 16:18:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r59240 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array main/org/jboss/aop/instrument
	resources/test/array test/org/jboss/test/aop/array
Message-ID: <E1H02dn-0003KA-8K@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-28 16:18:10 -0500 (Thu, 28 Dec 2006)
New Revision: 59240

Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java
   projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
Log:
Avoid duplicate interception if an array element is set to the same as its existing value
Add method to ArrayRegistry to get hold of references to an advised array

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -57,25 +57,27 @@
       {
          //The old value might be an array, remove references to that
          Object oldValue = ((Object[])array)[index];
-         registry.removeElementReference(array, index, oldValue);
-         
-         //The new value might be an array
-         if (value.getClass().isArray())
+         boolean ignoreUpdate = (oldValue == value);
+         if (!ignoreUpdate)
          {
-            registry.addElementReference(array, index, value);
+            registry.removeElementReference(array, index, oldValue);
+            
+            //The new value might be an array
+            if (value != null && value.getClass().isArray())
+            {
+               registry.addElementReference(array, index, value);
+            }
+            ObjectArrayElementWriteInvocation invocation = new ObjectArrayElementWriteInvocation(interceptors, (Object[])array, index, value);
+            invocation.invokeNext();
+            return;
          }
-         ObjectArrayElementWriteInvocation invocation = new ObjectArrayElementWriteInvocation(interceptors, (Object[])array, index, value);
-         invocation.invokeNext();
       }
-      else
-      {
-         ((Object[])array)[index] = value;
-      }
+      ((Object[])array)[index] = value;
    }
    
    public static void arrayWriteInt(Object array, int index, int value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      if (ArrayRegistry.getInstance().isRegistered(array) && ((int[])array)[index] != value)
       {
          IntArrayElementWriteInvocation invocation = new IntArrayElementWriteInvocation(interceptors, ((int[])array), index, value);
          invocation.invokeNext();
@@ -92,23 +94,23 @@
       {
          if (array instanceof boolean[])
          {
-            BooleanArrayElementWriteInvocation invocation = new BooleanArrayElementWriteInvocation(interceptors, ((boolean[])array), index, ByteBooleanConverter.toBoolean(value));
-            invocation.invokeNext();
-         }
-         else
-         {
-            ByteArrayElementWriteInvocation invocation = new ByteArrayElementWriteInvocation(interceptors, ((byte[])array), index, value);
-            invocation.invokeNext();
-         }
-      }
-      else
-      {
-         if (array instanceof boolean[])
-         {
+            if (((boolean[])array)[index] != ByteBooleanConverter.toBoolean(value))
+            
+            {
+               BooleanArrayElementWriteInvocation invocation = new BooleanArrayElementWriteInvocation(interceptors, ((boolean[])array), index, ByteBooleanConverter.toBoolean(value));
+               invocation.invokeNext();
+               return;
+            }
             ((boolean[])array)[index] = ByteBooleanConverter.toBoolean(value);
          }
-         else
+         else 
          {
+            if (((byte[])array)[index] != value)
+            {
+               ByteArrayElementWriteInvocation invocation = new ByteArrayElementWriteInvocation(interceptors, ((byte[])array), index, value);
+               invocation.invokeNext();
+               return;
+            }
             ((byte[])array)[index] = value;
          }
       }
@@ -116,7 +118,7 @@
 
    public static void arrayWriteChar(Object array, int index, char value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      if (ArrayRegistry.getInstance().isRegistered(array) && ((char[])array)[index] != value)
       {
          CharArrayElementWriteInvocation invocation = new CharArrayElementWriteInvocation(interceptors, ((char[])array), index, value);
          invocation.invokeNext();
@@ -129,7 +131,7 @@
 
    public static void arrayWriteDouble(Object array, int index, double value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      if (ArrayRegistry.getInstance().isRegistered(array) && ((double[])array)[index] != value)
       {
          DoubleArrayElementWriteInvocation invocation = new DoubleArrayElementWriteInvocation(interceptors, ((double[])array), index, value);
          invocation.invokeNext();
@@ -142,7 +144,7 @@
 
    public static void arrayWriteShort(Object array, int index, short value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      if (ArrayRegistry.getInstance().isRegistered(array) && ((short[])array)[index] != value)
       {
          ShortArrayElementWriteInvocation invocation = new ShortArrayElementWriteInvocation(interceptors, ((short[])array), index, value);
          invocation.invokeNext();
@@ -155,7 +157,7 @@
 
    public static void arrayWriteFloat(Object array, int index, float value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      if (ArrayRegistry.getInstance().isRegistered(array) && ((float[])array)[index] != value)
       {
          FloatArrayElementWriteInvocation invocation = new FloatArrayElementWriteInvocation(interceptors, ((float[])array), index, value);
          invocation.invokeNext();
@@ -168,7 +170,7 @@
 
    public static void arrayWriteLong(Object array, int index, long value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      if (ArrayRegistry.getInstance().isRegistered(array) && ((long[])array)[index] != value)
       {
          LongArrayElementWriteInvocation invocation = new LongArrayElementWriteInvocation(interceptors, ((long[])array), index, value);
          invocation.invokeNext();

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -164,4 +164,10 @@
    {
       throw new NotImplementedException();
    }
+   
+   public void getReferences()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      registry.getArrayOwners(targetObject);
+   }
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -21,8 +21,9 @@
 */ 
 package org.jboss.aop.array;
 
-import java.util.HashSet;
-import java.util.Set;
+import java.util.ArrayList;
+import java.util.HashMap;
+import java.util.List;
 import java.util.WeakHashMap;
 import java.util.concurrent.locks.Lock;
 import java.util.concurrent.locks.ReadWriteLock;
@@ -35,9 +36,12 @@
  */
 public class ArrayRegistry
 {
+   private final static ArrayRegistryEntryFactory ELEMENT_ARRAY_REGISTRY_ENTRY_FACTORY = new ElementArrayRegistryEntryFactory();
+   private final static ArrayRegistryEntryFactory FIELD_ARRAY_REGISTRY_ENTRY_FACTORY = new FieldArrayRegistryEntryFactory();
+   private ArrayReferenceBuilder referenceBuilder = new ArrayReferenceBuilder();
    private static ArrayRegistry singleton = new ArrayRegistry();
    private ReadWriteLock lock = new ReentrantReadWriteLock();
-   private WeakHashMap<Object, WeakHashMap<Object, ArrayRegistryEntry>> cache = new WeakHashMap<Object, WeakHashMap<Object, ArrayRegistryEntry>>();
+   private WeakHashMap<Object, WeakHashMap<Object, HashMap<Object, ArrayRegistryEntry>>> cache = new WeakHashMap<Object, WeakHashMap<Object, HashMap<Object, ArrayRegistryEntry>>>();
    
    public static ArrayRegistry getInstance()
    {
@@ -55,24 +59,47 @@
       {
          return;
       }
+      addReference(owner, fieldName, array, FIELD_ARRAY_REGISTRY_ENTRY_FACTORY);
+   }
+
+   public void addElementReference(Object owner, int index, Object array)
+   {
+      if (array == null)
+      {
+         return;
+      }
+      addReference(owner, new Integer(index), array, ELEMENT_ARRAY_REGISTRY_ENTRY_FACTORY);
+   }
+   
+   public void addReference(Object owner, Object qualifier, Object array, ArrayRegistryEntryFactory factory)
+   {
+      if (array == null)
+      {
+         return;
+      }
       Lock writeLock = lock.writeLock();
       writeLock.lock();
       try
       {
-         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         WeakHashMap<Object, HashMap<Object, ArrayRegistryEntry>> arrayReferences = cache.get(array);
          if (arrayReferences == null)
          {
-            arrayReferences = new WeakHashMap<Object, ArrayRegistryEntry>();
+            arrayReferences = new WeakHashMap<Object, HashMap<Object, ArrayRegistryEntry>>();
             cache.put(array, arrayReferences);
          }
-         ArrayRegistryEntry regEntry = arrayReferences.get(owner);
-         if (regEntry != null)
+         
+         HashMap<Object, ArrayRegistryEntry> ownerReferences = arrayReferences.get(owner);
+         if (ownerReferences == null)
          {
-            ((FieldArrayRegistryEntry)regEntry).addFieldName(fieldName);
+            ownerReferences = new HashMap<Object, ArrayRegistryEntry>();
+            arrayReferences.put(owner, ownerReferences);
          }
-         else
+         
+         ArrayRegistryEntry regEntry = ownerReferences.get(qualifier);
+         if (regEntry == null || regEntry.getArray() != array)
          {
-            arrayReferences.put(owner, new FieldArrayRegistryEntry(owner, fieldName, array));
+            ArrayRegistryEntry entry = factory.createArrayRegistryEntry(owner, qualifier, factory);
+            ownerReferences.put(qualifier, entry);
          }
          addNestedArrays(array);
       }
@@ -82,72 +109,27 @@
       }
    }
    
-   public void removeFieldReference(Object owner, String field, Object array)
+   public void removeFieldReference(Object owner, String fieldName, Object array)
    {
       if (array == null)
       {
          return;
       }
 
-      Lock writeLock = lock.writeLock();
-      writeLock.lock();
-      try
-      {
-         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
-         if (arrayReferences != null)
-         {
-            ArrayRegistryEntry regEntry = arrayReferences.get(owner);
-            if (owner != null)
-            {
-               ((FieldArrayRegistryEntry)regEntry).removeFieldName(field);
-               if (!regEntry.ownerHasReferences())
-               {
-                  arrayReferences.remove(owner);
-               }
-            }
-         }
-         removeNestedArrays(owner, array);
-      }
-      finally
-      {
-         writeLock.unlock();
-      }
+      removeReference(owner, fieldName, array);
    }
 
-   public void addElementReference(Object owner, int index, Object array)
+   public void removeElementReference(Object owner, int index, Object array)
    {
       if (array == null)
       {
          return;
       }
-      Lock writeLock = lock.writeLock();
-      writeLock.lock();
-      try
-      {
-         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
-         if (arrayReferences == null)
-         {
-            arrayReferences = new WeakHashMap<Object, ArrayRegistryEntry>();
-            cache.put(array, arrayReferences);
-         }
-         ArrayRegistryEntry regEntry = arrayReferences.get(owner);
-         if (regEntry != null)
-         {
-            ((ElementArrayRegistryEntry)regEntry).addIndex(index);
-         }
-         else
-         {
-            arrayReferences.put(owner, new ElementArrayRegistryEntry(owner, index, array));
-         }
-         addNestedArrays(array);
-      }
-      finally
-      {
-         writeLock.unlock();
-      }
+
+      removeReference(owner, new Integer(index), array);
    }
-   
-   public void removeElementReference(Object owner, int index, Object array)
+
+   public void removeReference(Object owner, Object qualifier, Object array)
    {
       if (array == null)
       {
@@ -158,20 +140,31 @@
       writeLock.lock();
       try
       {
-         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
+         WeakHashMap<Object, HashMap<Object,ArrayRegistryEntry>> arrayReferences = cache.get(array);
          if (arrayReferences != null)
          {
-            ArrayRegistryEntry regEntry = arrayReferences.get(owner);
-            if (owner != null)
+            HashMap<Object,ArrayRegistryEntry> ownerReferences = arrayReferences.get(owner);
+            if (ownerReferences != null)
             {
-               ((ElementArrayRegistryEntry)regEntry).removeIndex(index);
-               if (!regEntry.ownerHasReferences())
+               ArrayRegistryEntry regEntry = ownerReferences.remove(qualifier);
+               if (regEntry != null)
                {
-                  arrayReferences.remove(owner);
+                  if (ownerReferences.size() == 0)
+                  {
+                     arrayReferences.remove(owner);
+                     
+                     if (arrayReferences.size() == 0)
+                     {
+                        cache.remove(array);
+                     }
+                  }
+                  ///Should this be here or below?
+                  removeNestedArrays(array);
                }
+               
             }
          }
-         removeNestedArrays(owner, array);
+//         removeNestedArrays(owner, array);
       }
       finally
       {
@@ -186,8 +179,8 @@
       
       try
       {
-         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
-         if (arrayReferences == null || arrayReferences.size() == 0)
+         WeakHashMap<Object, HashMap<Object, ArrayRegistryEntry>> arrayReferences = cache.get(array);
+         if (arrayReferences == null)
          {
             return false;
          }
@@ -198,36 +191,31 @@
          readLock.unlock();
       }
    }
-   
-   public Set getOwners(Object owner, Object array)
+
+   public List<ArrayReference> getArrayOwners(Object array)
    {
+      System.out.println("----> getArrayOwners " + array);
       Lock readLock = lock.readLock();
       readLock.lock();
       
       try
       {
-         WeakHashMap<Object, ArrayRegistryEntry> arrayReferences = cache.get(array);
-         if (arrayReferences != null)
-         {
-            HashSet set = new HashSet();
-            set.addAll(arrayReferences.keySet());
-            return set;
-         }
-         return null;
+         return referenceBuilder.getArrayReferences(array);
       }
       finally
       {
          readLock.unlock();
       }
    }
-
+   
    private void addNestedArrays(Object array)
    {
       if (array == null)
       {
          return;
       }
-      if (isArray(array))
+      ArrayType type = isArray(array);
+      if (type == ArrayType.MULTIDIM_ARRAY)
       {
          for (int i = 0 ; i < ((Object[])array).length ; i++)
          {
@@ -235,32 +223,165 @@
             addNestedArrays(((Object[])array)[i]);
          }
       }
+      else if (type == ArrayType.OBJECT_ARRAY)
+      {
+         for (int i = 0 ; i < ((Object[])array).length ; i++)
+         {
+            Object val = ((Object[])array)[i];
+            if (val != null && val.getClass().isArray())
+            {
+               addElementReference(array, i, ((Object[])array)[i]);
+               addNestedArrays(((Object[])array)[i]);
+            }
+         }
+      }
    }
    
-   private void removeNestedArrays(Object owner, Object array)
+   private void removeNestedArrays(Object array)
    {
       if (array == null)
       {
          return;
       }
-      if (isArray(array))
+      ArrayType type = isArray(array);
+      if (type == ArrayType.MULTIDIM_ARRAY)
       {
          for (int i = 0 ; i < ((Object[])array).length ; i++)
          {
             removeElementReference(array, i, ((Object[])array)[i]);
-            removeNestedArrays(array, ((Object[])array)[i]);
+            removeNestedArrays(((Object[])array)[i]);
          }
       }
+      else if (type == ArrayType.OBJECT_ARRAY)
+      {
+         for (int i = 0 ; i < ((Object[])array).length ; i++)
+         {
+            Object val = ((Object[])array)[i];
+            if (val != null && val.getClass().isArray())
+            {
+               removeElementReference(array, i, ((Object[])array)[i]);
+               removeNestedArrays(((Object[])array)[i]);
+            }
+         }
+      }
    }
    
-   private boolean isArray(Object arrayCandidate)
+   private ArrayType isArray(Object arrayCandidate)
    {
       Class candidateClass = arrayCandidate.getClass();
       if (candidateClass.isArray())
       {
          Class componentType = candidateClass.getComponentType();
-         return componentType.isArray();
+         if (componentType.isArray())
+         {
+            return ArrayType.MULTIDIM_ARRAY;
+         }
+         if (componentType == Object.class)
+         {
+            return ArrayType.OBJECT_ARRAY;
+         }
       }
-      return false;
+      return ArrayType.NOT_ARRAY;
    }
+   
+   private interface ArrayRegistryEntryFactory
+   {
+      ArrayRegistryEntry createArrayRegistryEntry(Object owner, Object qualifier, Object array);
+   }
+   
+   private static class FieldArrayRegistryEntryFactory implements ArrayRegistryEntryFactory
+   {
+      public ArrayRegistryEntry createArrayRegistryEntry(Object owner, Object qualifier, Object array)
+      {
+         return new FieldArrayRegistryEntry(owner, (String)qualifier, array);
+      }
+   }
+
+   private static class ElementArrayRegistryEntryFactory implements ArrayRegistryEntryFactory
+   {
+      public ArrayRegistryEntry createArrayRegistryEntry(Object owner, Object qualifier, Object array)
+      {
+         return new ElementArrayRegistryEntry(owner, (Integer)qualifier, array);
+      }
+   }
+   
+   private class ArrayReferenceBuilder
+   {
+      private List<ArrayReference> getArrayReferences(Object array)
+      {
+         List<ArrayReference> references = null;
+         WeakHashMap<Object, HashMap<Object, ArrayRegistryEntry>> arrayReferences = cache.get(array);
+         if (arrayReferences != null && arrayReferences.size() > 0)
+         {
+            for (Object owner : arrayReferences.keySet())
+            {
+               HashMap<Object, ArrayRegistryEntry> ownerReferences = arrayReferences.get(owner);
+               for (Object qualifier : ownerReferences.keySet())
+               {
+                  ArrayRegistryEntry regEntry = ownerReferences.get(qualifier);
+                  
+                  if (regEntry.isOwnerRoot())
+                  {
+                     ArrayReference reference = getRootReference((FieldArrayRegistryEntry)regEntry);
+                     if (reference != null)
+                     {
+                        if (references == null)
+                        {
+                           references = new ArrayList<ArrayReference>();
+                        }
+                        references.add(reference);
+                     }
+                  }
+                  else
+                  {
+                     List<ArrayReference> parentReferences = getElementReferences((ElementArrayRegistryEntry)regEntry);
+                     if (parentReferences != null)
+                     {
+                        if (references == null)
+                        {
+                           references = new ArrayList<ArrayReference>();
+                        }
+                        references.addAll(parentReferences);
+                     }
+                  }
+               }
+            }
+         }
+         return references;
+      }
+      
+      private ArrayReference getRootReference(FieldArrayRegistryEntry regEntry)
+      {
+         Object root = regEntry.getOwner();
+         if (root != null)
+         {
+            String fieldName = regEntry.getFieldName();
+            return new ArrayReferenceImpl(root, fieldName);
+         }
+         return null;
+      }
+      
+      private List<ArrayReference> getElementReferences(ElementArrayRegistryEntry regEntry)
+      {
+         Object ownerArray = regEntry.getOwner();
+         if (ownerArray != null)
+         {
+            List<ArrayReference> references = getArrayReferences(ownerArray);
+            if (references != null && references.size() > 0)
+            {
+               for (ArrayReference reference : references)
+               {
+                  ((ArrayReferenceImpl)reference).addNestedArrayIndex(regEntry.getIndex());
+               }
+            }
+            return references;
+         }
+         return null;
+      }
+   }
+   
+   private enum ArrayType
+   {
+      NOT_ARRAY,MULTIDIM_ARRAY,OBJECT_ARRAY; 
+   }
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistryEntry.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -52,20 +52,26 @@
       }
    }
 
-   public WeakReference getArray()
+   public Object getArray()
    {
-      return array;
+      if (array != null)
+      {
+         return array.get();
+      }
+      return null;
    }
 
-   public WeakReference getOwner()
+   public Object getOwner()
    {
-      return owner;
+      if (owner != null)
+      {
+         return owner.get();
+      }
+      return null;
    }
 
    public boolean isOwnerRoot()
    {
       return ownerIsRoot;
    }
-   
-   public abstract boolean ownerHasReferences();
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ElementArrayRegistryEntry.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -30,27 +30,16 @@
  */
 public class ElementArrayRegistryEntry extends ArrayRegistryEntry
 {
-   HashSet<Integer> indices = new HashSet<Integer>();
+   Integer index;;
    
-   ElementArrayRegistryEntry(Object owner, int index, Object array)
+   ElementArrayRegistryEntry(Object owner, Integer index, Object array)
    {
       super(owner, false, array);
-      this.indices.add(index); 
+      this.index = index; 
    }
-   
-   public void addIndex(int index)
-   {
-      indices.add(index);
-   }
-   
-   public void removeIndex(int index)
-   {
-      indices.remove(index);
-   }
 
-   @Override
-   public boolean ownerHasReferences()
+   public Integer getIndex()
    {
-      return indices.size() > 0;
+      return index;
    }
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/FieldArrayRegistryEntry.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -30,28 +30,17 @@
  */
 public class FieldArrayRegistryEntry extends ArrayRegistryEntry
 {
-   HashSet fields = new HashSet<String>();
+   String fieldName;
    
    FieldArrayRegistryEntry(Object owner, String fieldName, Object array)
    {
       // FIXME FieldArrayRegistryEntry constructor
       super(owner, true, array);
-      this.fields.add(fieldName);
+      this.fieldName = fieldName;
    }
    
-   public void addFieldName(String fieldName)
+   public String getFieldName()
    {
-      fields.add(fieldName);
+      return fieldName;
    }
-   
-   public void removeFieldName(String fieldName)
-   {
-      fields.remove(fieldName);
-   }
-   
-   @Override
-   public boolean ownerHasReferences()
-   {
-      return fields.size() > 0;
-   }
 }
\ No newline at end of file

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/FieldAccessTransformer.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -118,11 +118,10 @@
    
    protected abstract void doBuildFieldWrappers(CtClass clazz, CtField field, int index, boolean shouldReplaceArrayAccess, JoinpointClassification classificationGet, JoinpointClassification classificationSet) throws NotFoundException, CannotCompileException;
    
-   protected String getArrayWriteRegistration(boolean shouldReplaceArrayAccess, CtField field, String oldValue, String newValue) throws NotFoundException
+   protected String getArrayWriteRegistration(boolean shouldReplaceArrayAccess, String target, CtField field, String oldValue, String newValue) throws NotFoundException
    {
-      if (field.getType().isArray() && shouldReplaceArrayAccess)
+      if (shouldReplaceArrayAccess && (field.getType().isArray() || field.getType().getName().equals("java.lang.Object")))
       {
-         String target = Modifier.isStatic(field.getModifiers()) ? "java.lang.Class.forName(" + field.getType().getName() + ")" : "this";  
          return "org.jboss.aop.array.ArrayAdvisor.updateArrayField(" + target + ", \"" + field.getName() + "\", " + oldValue + ", " + newValue + ");";
       }
       return "";

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/instrument/GeneratedAdvisorFieldAccessTransformer.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -307,10 +307,11 @@
       String generatorName = FieldJoinPointGenerator.getJoinPointGeneratorFieldName(field.getName(), false);
       if (isStatic)
       {
-         String fieldString = clazz.getName() + "." + field.getName();
+         String targetString = "java.lang.Class.forName(\"" + clazz.getName() + "\")";
+         String fieldString = clazz.getName() +  "." + field.getName();
          code =
             "{" +
-            "    " + getArrayWriteRegistration(shouldReplaceArrayAccess, field, fieldString, "$2") +
+            "    " + getArrayWriteRegistration(shouldReplaceArrayAccess, targetString, field, fieldString, "$2") +
             "   if (" + infoName + " == null && " + generatorName + " != null)" +
             "   {" +
             "   " + generatorName + "." + JoinPointGenerator.GENERATE_JOINPOINT_CLASS + "(this.getClass().getClassLoader());" +
@@ -327,10 +328,11 @@
       }
       else
       {
-         String fieldString = "((" + clazz.getName() + ")$1)." + field.getName();
+         String targetString = "((" + clazz.getName() + ")$1)";
+         String fieldString = targetString + "." + field.getName();
          code =
             "{" +
-            "    " + getArrayWriteRegistration(shouldReplaceArrayAccess, field, fieldString, "$2") +
+            "    " + getArrayWriteRegistration(shouldReplaceArrayAccess, targetString, field, fieldString, "$2") +
             "   if (" + infoName + " == null && " + generatorName + " != null)" +
             "   {" +
             "   " + generatorName + "." + JoinPointGenerator.GENERATE_JOINPOINT_CLASS + "(this.getClass().getClassLoader());" +

Modified: projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
===================================================================
--- projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-28 21:18:10 UTC (rev 59240)
@@ -1,7 +1,10 @@
 <aop>
    <arrayreplacement class="org.jboss.test.aop.array.AOPArrayTestCase"/>
+   <arrayreplacement class="org.jboss.test.aop.array.ArrayReferenceTestCase"/>
    <arrayreplacement expr="class(org.jboss.test.aop.array.ClassWithArrayFields) OR class(org.jboss.test.aop.array.ClassWithSeveralReferencesToSameArray)"/>
+   <arrayreplacement expr="class($instanceof{org.jboss.test.aop.array.ClassForReference})"/>
    <prepare expr="field(* org.jboss.test.aop.array.ClassWithArrayFields->*)"/>
    <prepare expr="field(* org.jboss.test.aop.array.ClassWithSeveralReferencesToSameArray->*)"/> 
+   <prepare expr="field(* org.jboss.test.aop.array.ClassForReference->*)"/> 
 </aop>
 

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -29,6 +29,7 @@
 
 
 /**
+ * Test that arrays get advised properly
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
  * @version $Revision: 1.1 $
@@ -101,14 +102,14 @@
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
-      obj.booleans[1] = false; 
+      obj.booleans[1] = true;
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
-      assertEquals(false, ((Boolean)TestArrayElementInterceptor.value).booleanValue());
+      assertEquals(true, ((Boolean)TestArrayElementInterceptor.value).booleanValue());
 
       TestArrayElementInterceptor.clear();
       boolean val = obj.booleans[1];
-      assertEquals(false, val);
+      assertEquals(true, val);
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
    }
@@ -472,6 +473,305 @@
       
    }
    
+   public void testObjectArrayWithArrayAsObjectEntry2()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      Object[] original = obj.objects;
+      obj.objects = new Object[] {new int[] {1,2,3}};
+      
+      //Add an array as one of the elements in the object array
+      TestArrayElementInterceptor.clear();
+      original[0] = "X";
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      Object val = original[0];
+      assertEquals("X", val);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      int[] i = (int[])obj.objects[0];
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      i[1] = 10;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(10, TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      int ival = i[1];
+      assertEquals(10, ival);
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testObjectFieldWithArray()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      obj.objectField = new int[] {1,2,3};
+      
+      TestArrayElementInterceptor.clear();
+      ((int[])obj.objectField)[1] = 10;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(10, TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      int val = ((int[])obj.objectField)[2];
+      assertEquals(3, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      int[] array = (int[])obj.objectField;
+      TestArrayElementInterceptor.clear();
+      val = array[2];
+      assertEquals(3, val);
+      assertEquals(2, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      obj.objectField = null;
+      TestArrayElementInterceptor.clear();
+      val = array[2];
+      assertEquals(3, val);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testObjectFieldWithNestedArrays()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      obj.objectField = new Object[] {new int[] {1, 2}, new Object[] {"X", "Y"}};
+      
+      Object[] objArray = (Object[])obj.objectField;
+      
+      TestArrayElementInterceptor.clear();
+      int[] intArray = (int[])((Object[])obj.objectField)[0]; 
+      assertEquals(0, TestArrayElementInterceptor.index);
+      
+      TestArrayElementInterceptor.clear();
+      Object[] objArray2 = (Object[])((Object[])obj.objectField)[1]; 
+      assertEquals(1, TestArrayElementInterceptor.index);
+
+      TestArrayElementInterceptor.clear();
+      intArray[1] = 10;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(10, TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      int val = intArray[1];
+      assertEquals(10, val);
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      objArray2[1] = "ZZZ";
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals("ZZZ", TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      Object oval = objArray2[1];
+      assertEquals("ZZZ", oval);
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      int[] intArray2 = new int[] {11, 22};
+      objArray[0] = intArray2;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(intArray2, TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      intArray2[1] = 10;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertEquals(10, TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      val = intArray2[1];
+      assertEquals(10, val);
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      intArray[1] = 10;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      val = intArray[1];
+      assertEquals(10, val);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      objArray[0] = null;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      objArray[1] = null;
+      assertEquals(1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      intArray2[1] = 10;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      val = intArray2[1];
+      assertEquals(10, val);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      objArray2[1] = "ZZZ";
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      TestArrayElementInterceptor.clear();
+      oval = objArray2[1];
+      assertEquals("ZZZ", oval);
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
+   public void testIgnoreDoubleUpdate()
+   {
+      ClassWithArrayFields obj = new ClassWithArrayFields();
+      
+      String sval = "X";
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = sval;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(sval, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = sval;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      byte byteVal = 10;
+      TestArrayElementInterceptor.clear();
+      obj.bytes[0] = byteVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(byteVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.bytes[0] = byteVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      //Set the value to be different
+      obj.booleans[0] = false;
+      boolean booleanVal = true;
+      TestArrayElementInterceptor.clear();
+      obj.booleans[0] = booleanVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(booleanVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.booleans[0] = booleanVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      booleanVal = false;
+      TestArrayElementInterceptor.clear();
+      obj.booleans[0] = booleanVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(booleanVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.booleans[0] = booleanVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      char charVal = 'h';
+      TestArrayElementInterceptor.clear();
+      obj.chars[0] = charVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(charVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.chars[0] = charVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      double doubleVal = 101.1d;
+      TestArrayElementInterceptor.clear();
+      obj.doubles[0] = doubleVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(doubleVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.doubles[0] = doubleVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      
+      float floatVal = 66.6f;
+      TestArrayElementInterceptor.clear();
+      obj.floats[0] = floatVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(floatVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.floats[0] = floatVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      int intVal = 1000;
+      TestArrayElementInterceptor.clear();
+      obj.ints[0] = intVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(intVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.ints[0] = intVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      int[][] intVal2d = new int[][]{new int[]{1}, new int[]{2}};
+      TestArrayElementInterceptor.clear();
+      obj.ints3d[0] = intVal2d;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(intVal2d, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.ints3d[0] = intVal2d;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      long longVal = 10001;
+      TestArrayElementInterceptor.clear();
+      obj.longs[0] = longVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(longVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.longs[0] = longVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      short shortVal = 999;
+      TestArrayElementInterceptor.clear();
+      obj.shorts[0] = shortVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(shortVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.shorts[0] = shortVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+
+      Object objectVal = new int[] {1,2,3};
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = objectVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(objectVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      obj.objects[0] = objectVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+      intVal = 100;
+      TestArrayElementInterceptor.clear();
+      ((int[])objectVal)[0] = intVal;
+      assertEquals(0, TestArrayElementInterceptor.index);
+      assertEquals(intVal, TestArrayElementInterceptor.value);
+      TestArrayElementInterceptor.clear();
+      ((int[])objectVal)[0] = intVal;
+      assertEquals(-1, TestArrayElementInterceptor.index);
+      assertNull(TestArrayElementInterceptor.value);
+   }
+   
    public void testUnadvisedArrayFields()
    {
       ClassWithUnadvisedArrayFields obj = new ClassWithUnadvisedArrayFields();
@@ -520,6 +820,6 @@
       obj.shorts[0] = 100;
       assertEquals(100, obj.shorts[0]);
       assertEquals(-1, TestArrayElementInterceptor.index);
-
    }
+   
 }

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-27 18:02:24 UTC (rev 59239)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassWithArrayFields.java	2006-12-28 21:18:10 UTC (rev 59240)
@@ -21,8 +21,6 @@
 */ 
 package org.jboss.test.aop.array;
 
-import java.util.Arrays;
-
 /**
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
@@ -51,6 +49,7 @@
    };
    public long[] longs = new long[] {1L, 2L, 3L};
    public short[] shorts = new short[] {1,2,3};
+   public Object objectField = new int[] {1, 2, 3};
    
    public ClassWithArrayFields()
    {



From gsdfa3482er7s at Safe-mail.net  Thu Dec 28 17:50:54 2006
From: gsdfa3482er7s at Safe-mail.net (gsdfa3482er7s at Safe-mail.net)
Date: Thu, 28 Dec 2006 17:50:54 -0500
Subject: [jboss-cvs] =?utf-8?b?wpZ7wpROwo3DhcKMw6PCgsOMwozDgMKSw6jCisK0?=
	=?utf-8?b?wo7Dk8KNw5XCgsOMwoLCqMKSbcKCw6fCgsK5woFJ?=
Message-ID: 20061229073605.65784mail@mail.eryuisdhfjkeryuisdbnjkxvnjckhsdjglyui.com

2006?N?????????????????????????B?@?????????????????????H
?????A?F?l???????Y?????b???????????????A?????g???????????????????W???l?????j?v?????????I
???????F?l???????p?????????A?e?????????????????????????A?X?^?b?t?????w???v???????B

?????A?????????????W???l???j???L?O?v?????????A?????????J???v???????I?I

http://completeallfree.nearwoman.perpl.com/ne/

???T???v?????????A

?@?????????????A????(?A?h???X?A?d?b????)?????????????J
http://completeallfree.nearwoman.perpl.com/ne/

?A?t???????]???????D??????
http://completeallfree.nearwoman.perpl.com/ne/

?????????????????B

?????????A???S?????????????????????????A???C?y???????p?????????????I

?????N?z???????}?????????????I





From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 18:31:38 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 18:31:38 -0500
Subject: [jboss-cvs] JBossAS SVN: r59241 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array test/org/jboss/test/aop/array
Message-ID: <E1H04io-0005gy-TF@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-28 18:31:34 -0500 (Thu, 28 Dec 2006)
New Revision: 59241

Added:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReferenceImpl.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java
Log:
Add the missing ArrayReference files

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java	2006-12-28 21:18:10 UTC (rev 59240)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java	2006-12-28 23:31:34 UTC (rev 59241)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import java.util.List;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public interface ArrayReference
+{
+   Object getRootObject();
+   String getRootField();
+   List<Integer> getNestedArrayIndices();
+}

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReferenceImpl.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReferenceImpl.java	2006-12-28 21:18:10 UTC (rev 59240)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReferenceImpl.java	2006-12-28 23:31:34 UTC (rev 59241)
@@ -0,0 +1,83 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import java.util.ArrayList;
+import java.util.List;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayReferenceImpl implements ArrayReference
+{
+   Object root;
+   String rootField;
+   ArrayList<Integer> nestedArrayIndices;
+   
+   public ArrayReferenceImpl(Object root, String rootField)
+   {
+      this.root = root;
+      this.rootField = rootField;
+   }
+   
+   public Object getRootObject()
+   {
+      return root;
+   }
+   
+   public String getRootField()
+   {
+      return rootField;
+   }
+   
+   public void addNestedArrayIndex(Integer index)
+   {
+      if (nestedArrayIndices == null)
+      {
+         nestedArrayIndices = new ArrayList<Integer>();
+      }
+      nestedArrayIndices.add(index);
+   }
+   
+   public List<Integer> getNestedArrayIndices()
+   {
+      return nestedArrayIndices;
+   }
+   
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer();
+      sb.append(root + "." + rootField);
+      
+      if (nestedArrayIndices != null && nestedArrayIndices.size() > 0)
+      {
+         for (Integer index : nestedArrayIndices)
+         {
+            sb.append("[" + index + "]");
+         }
+      }
+      
+      return sb.toString();
+   }
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java	2006-12-28 21:18:10 UTC (rev 59240)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java	2006-12-28 23:31:34 UTC (rev 59241)
@@ -0,0 +1,471 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+import java.util.HashSet;
+import java.util.List;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
+import org.jboss.aop.array.ArrayReference;
+import org.jboss.aop.array.ArrayRegistry;
+import org.jboss.test.aop.AOPTestWithSetup;
+
+
+/**
+ * Test that ArrayRegistry.getArrayOwners() returns the right data
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayReferenceTestCase extends AOPTestWithSetup
+{
+   public ArrayReferenceTestCase(String name)
+   {
+      super(name);
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("ArrayReferenceTestCase");
+      suite.addTestSuite(ArrayReferenceTestCase.class);
+      return suite;
+   }
+
+   public void testSimpleFieldReference()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      obj.fieldA = arr;
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(obj, reference.getRootObject());
+      assertEquals("fieldA", reference.getRootField());
+      assertNull(reference.getNestedArrayIndices());
+
+      obj.fieldA = null;
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+   
+   public void testMultipleFieldReferencesSameRootObjects()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      obj.fieldA = arr;
+      obj.fieldB = arr;
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      assertEquals(2, references.size());
+      
+      HashSet fields = new HashSet();
+      fields.add("fieldA");
+      fields.add("fieldB");
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertEquals(obj, owner);
+         assertTrue("Expeced 'fieldA' or 'fieldB'; was " + ref.getRootField(), ref.getRootField() == "fieldA" || ref.getRootField() == "fieldB");
+         assertNull(ref.getNestedArrayIndices());
+         fields.remove(ref.getRootField());
+      }
+      
+      assertTrue("Did not find all references " + fields, fields.size() == 0);
+      
+      obj.fieldA = null;
+      references = registry.getArrayOwners(arr);
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(obj, reference.getRootObject());
+      assertEquals("fieldB", reference.getRootField());
+      assertNull(reference.getNestedArrayIndices());
+      
+      obj.fieldB = null;
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testMultipleFieldReferencesDifferentRootObjects()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      ClassForReference obj2 = new ClassForReference();
+      obj.fieldA = arr;
+      obj2.fieldB = arr;
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      assertEquals(2, references.size());
+      
+      HashSet rootObjects = new HashSet();
+      rootObjects.add(obj);
+      rootObjects.add(obj2);
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertTrue("Expected " + obj + " or " + obj2 + "; was" + owner, owner == obj || owner == obj2);
+         if (owner == obj)
+         {
+            assertEquals("fieldA", ref.getRootField());
+         }
+         else if (owner == obj2)
+         {
+            assertEquals("fieldB", ref.getRootField());
+         }
+         assertNull(ref.getNestedArrayIndices());
+         rootObjects.remove(owner);
+      }
+      
+      assertTrue("Did not find all references " + rootObjects, rootObjects.size() == 0);
+      
+      obj.fieldA = null;
+      references = registry.getArrayOwners(arr);
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(obj2, reference.getRootObject());
+      assertEquals("fieldB", reference.getRootField());
+      assertNull(reference.getNestedArrayIndices());
+      
+      obj2.fieldB = null;
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testMultipleFieldReferencesStatic()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference.staticA = arr;
+      ClassForReference.staticB = arr;
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      assertEquals(2, references.size());
+      
+      HashSet fields = new HashSet();
+      fields.add("staticA");
+      fields.add("staticB");
+      
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertEquals(ClassForReference.class, owner);
+         assertTrue("Expected 'staticA' or 'staticB'; was " + ref.getRootField(), ref.getRootField() == "staticA" || ref.getRootField() == "staticB");
+         assertNull(ref.getNestedArrayIndices());
+         fields.remove(ref.getRootField());
+      }
+      
+      assertTrue("Did not find all references " + fields, fields.size() == 0);
+      
+      ClassForReference.staticA = null;
+      references = registry.getArrayOwners(arr);
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(ClassForReference.class, reference.getRootObject());
+      assertEquals("staticB", reference.getRootField());
+      assertNull(reference.getNestedArrayIndices());
+      
+      ClassForReference.staticB = null;
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testMultipleFieldReferencesStaticAndNonStatic()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      obj.fieldA = arr;
+      ClassForReference.staticA = arr;
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      assertEquals(2, references.size());
+      
+      HashSet rootObjects = new HashSet();
+      rootObjects.add(obj);
+      rootObjects.add(ClassForReference.class);
+      
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertTrue("Expected " + obj + " or " + ClassForReference.class + "; was" + owner, owner == obj || owner == ClassForReference.class);
+         if (owner == obj)
+         {
+            assertEquals("fieldA", ref.getRootField());
+         }
+         else if (owner == ClassForReference.class)
+         {
+            assertEquals("staticA", ref.getRootField());
+         }
+         assertNull(ref.getNestedArrayIndices());
+         rootObjects.remove(owner);
+      }
+      
+      assertTrue("Did not find all references " + rootObjects, rootObjects.size() == 0);
+      
+      obj.fieldA = null;
+      references = registry.getArrayOwners(arr);
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(ClassForReference.class, reference.getRootObject());
+      assertEquals("staticA", reference.getRootField());
+      assertNull(reference.getNestedArrayIndices());
+      
+      ClassForReference.staticA = null;
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+   
+   public void testSimpleElementReferences()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      obj.fieldA = new Object[] {arr};
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(obj, reference.getRootObject());
+      assertEquals("fieldA", reference.getRootField());
+      assertNotNull(reference.getNestedArrayIndices());
+      assertEquals(1, reference.getNestedArrayIndices().size()); 
+      assertEquals(new Integer(0), reference.getNestedArrayIndices().get(0));
+
+      obj.fieldA[0] = null;
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testMultipleElementReferencesSameArraySameRootObject()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      obj.fieldA = new Object[] {arr, null, arr};
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      
+      assertEquals(2, references.size());
+      
+      HashSet indeces = new HashSet();
+      indeces.add(new Integer(0));
+      indeces.add(new Integer(2));
+      
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertEquals(obj, owner);
+         assertEquals("fieldA", ref.getRootField());
+         assertNotNull(ref.getNestedArrayIndices());
+         assertEquals(1, ref.getNestedArrayIndices().size());
+         indeces.remove(ref.getNestedArrayIndices().get(0));
+      }
+      assertTrue("Did not find all references " + indeces, indeces.size() == 0);
+
+      obj.fieldA[2] = null; 
+      
+      references = registry.getArrayOwners(arr);
+      
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(obj, reference.getRootObject());
+      assertEquals("fieldA", reference.getRootField());
+      assertEquals(1, reference.getNestedArrayIndices().size());
+      assertEquals(new Integer(0), reference.getNestedArrayIndices().get(0));
+
+      obj.fieldA[0] = null; 
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testMultipleElementReferencesSameArrayDifferentRootObject()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference obj = new ClassForReference();
+      ClassForReference obj2 = new ClassForReference();
+      obj.fieldA = new Object[] {arr};
+      obj2.fieldA = new Object[] {arr};
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      
+      assertEquals(2, references.size());
+      
+      HashSet owners = new HashSet();
+      owners.add(obj);
+      owners.add(obj2);
+      
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertEquals("fieldA", ref.getRootField());
+         assertNotNull(ref.getNestedArrayIndices());
+         assertEquals(1, ref.getNestedArrayIndices().size());
+         assertEquals(new Integer(0), ref.getNestedArrayIndices().get(0));
+         owners.remove(owner);
+      }
+      assertTrue("Did not find all references " + owners, owners.size() == 0);
+
+      obj.fieldA[0] = null; 
+      
+      references = registry.getArrayOwners(arr);
+      
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(obj2, reference.getRootObject());
+      assertEquals("fieldA", reference.getRootField());
+      assertEquals(1, reference.getNestedArrayIndices().size());
+      assertEquals(new Integer(0), reference.getNestedArrayIndices().get(0));
+
+      obj2.fieldA[0] = null; 
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testMultipleElementReferencesStatic()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      Object[] arr = new Object[] {"1", "2", "3"};
+      ClassForReference.staticA = new Object[] {arr};
+      ClassForReference.staticB = new Object[] {null, arr};
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      
+      assertEquals(2, references.size());
+      
+      HashSet elements = new HashSet();
+      elements.add("staticA0");
+      elements.add("staticB1");
+      
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertEquals(ClassForReference.class, owner);
+         assertNotNull(ref.getNestedArrayIndices());
+         assertEquals(1, ref.getNestedArrayIndices().size());
+         elements.remove(ref.getRootField() + ref.getNestedArrayIndices().get(0));
+      }
+      assertTrue("Did not find all references " + elements, elements.size() == 0);
+
+      ClassForReference.staticA[0] = null; 
+      
+      references = registry.getArrayOwners(arr);
+      
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(ClassForReference.class, reference.getRootObject());
+      assertEquals("staticB", reference.getRootField());
+      assertEquals(1, reference.getNestedArrayIndices().size());
+      assertEquals(new Integer(1), reference.getNestedArrayIndices().get(0));
+
+      ClassForReference.staticB[1] = null; 
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+   
+   public void testNestedMultipleReferences()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      int[] arr = new int[] {1, 2, 3};
+      ClassForReference obj = new ClassForReference();
+      Object[][][][] fieldA = new Object[][][][] {null, null, new Object[][][] {null, new Object[][] {null, null, new Object[] {null, null, null, arr}}}}; //2, 1, 2, 3
+      obj.fieldA = fieldA;
+      Object[][][] staticA = new Object[][][] {new Object[][][] {null, new Object[][] {null, null, new Object[]{null, null, arr}}},null}; //0, 1, 2, 2
+      ClassForReference.staticA = staticA;
+      
+      final String FIELDA = "fieldA2123"; 
+      final String STATICA = "staticA0122";
+      
+      HashSet elements = new HashSet();
+      elements.add(FIELDA);
+      elements.add(STATICA);
+
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      
+      assertEquals(2, references.size());
+
+      for (ArrayReference ref : references)
+      {
+         Object owner = ref.getRootObject();
+         assertNotNull(ref.getNestedArrayIndices());
+         StringBuffer elem = new StringBuffer(ref.getRootField());
+         
+         List<Integer> indices = ref.getNestedArrayIndices();
+         for (Integer index : indices)
+         {
+            elem.append(index);
+         }
+         
+         System.out.println("----> elem " + elem.toString());
+         elements.remove(elem.toString());
+         if (elem.toString().equals(STATICA))
+         {
+            assertEquals(ClassForReference.class, owner);
+         }
+         else if (elem.toString().equals(FIELDA))
+         {
+            assertEquals(obj, owner);
+         }
+      }   
+      assertTrue("Did not find all references " + elements, elements.size() == 0);
+
+      fieldA[2][1][2][3] = null;
+      references = registry.getArrayOwners(arr);
+      assertEquals(1, references.size());
+      ArrayReference reference = references.get(0);
+      assertEquals(ClassForReference.class, reference.getRootObject());
+      assertEquals("staticA", reference.getRootField());
+      assertEquals(4, reference.getNestedArrayIndices().size());
+      assertEquals(new Integer(0), reference.getNestedArrayIndices().get(0));
+      assertEquals(new Integer(1), reference.getNestedArrayIndices().get(1));
+      assertEquals(new Integer(2), reference.getNestedArrayIndices().get(2));
+      assertEquals(new Integer(2), reference.getNestedArrayIndices().get(3));
+
+      ((Object[])staticA[0][1][2])[2] = null; 
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+
+   public void testNestedReferencesRemoveAtHigherLevel()
+   {
+      ArrayRegistry registry = ArrayRegistry.getInstance();
+      int[] arr = new int[] {1, 2, 3};
+      ClassForReference obj = new ClassForReference();
+      Object[][][][] fieldA = new Object[][][][] {null, null, new Object[][][] {null, new Object[][] {null, null, new Object[] {null, null, null, arr}}}}; //2, 1, 2, 3
+      obj.fieldA = fieldA;
+
+      List<ArrayReference> references = registry.getArrayOwners(arr);
+      
+      assertEquals(1, references.size());
+      
+      ArrayReference reference = references.get(0);
+      assertEquals(obj, reference.getRootObject());
+      assertEquals("fieldA", reference.getRootField());
+      assertEquals(4, reference.getNestedArrayIndices().size());
+      assertEquals(new Integer(2), reference.getNestedArrayIndices().get(0));
+      assertEquals(new Integer(1), reference.getNestedArrayIndices().get(1));
+      assertEquals(new Integer(2), reference.getNestedArrayIndices().get(2));
+      assertEquals(new Integer(3), reference.getNestedArrayIndices().get(3));
+
+      fieldA[2][1] = null; 
+      references = registry.getArrayOwners(arr);
+      assertNull(references);
+   }
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 18:32:32 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 18:32:32 -0500
Subject: [jboss-cvs] JBossAS SVN: r59242 -
	projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array
Message-ID: <E1H04jg-0005iF-G9@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-28 18:32:30 -0500 (Thu, 28 Dec 2006)
New Revision: 59242

Added:
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassForReference.java
Log:
Add the missing ArrayReference files

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassForReference.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassForReference.java	2006-12-28 23:31:34 UTC (rev 59241)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ClassForReference.java	2006-12-28 23:32:30 UTC (rev 59242)
@@ -0,0 +1,36 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ClassForReference
+{
+   public Object[] fieldA;
+   public Object[] fieldB;
+   
+   public static Object[] staticA;
+   public static Object[] staticB;
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 18:35:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 18:35:23 -0500
Subject: [jboss-cvs] JBossAS SVN: r59243 - in
	projects/aop/branches/arrays/aop/src: main/org/jboss/aop
	main/org/jboss/aop/advice main/org/jboss/aop/array
	resources/test/array test/org/jboss/test/aop/array
Message-ID: <E1H04mR-0005jw-B3@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-28 18:35:15 -0500 (Thu, 28 Dec 2006)
New Revision: 59243

Added:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayBinding.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AspectForPrecedence.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java
Removed:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java
Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/advice/PrecedenceSorter.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
   projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
Log:
Make the interceptors/advices applied to arrays configurable via the <arraybind> element, and enable precedence for the chains

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectManager.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -42,7 +42,6 @@
 import org.jboss.aop.advice.AdviceBinding;
 import org.jboss.aop.advice.AdviceStack;
 import org.jboss.aop.advice.AspectDefinition;
-import org.jboss.aop.advice.AspectFactory;
 import org.jboss.aop.advice.AspectFactoryWithClassLoader;
 import org.jboss.aop.advice.DynamicCFlowDefinition;
 import org.jboss.aop.advice.InterceptorFactory;
@@ -50,6 +49,8 @@
 import org.jboss.aop.advice.PrecedenceDefEntry;
 import org.jboss.aop.advice.PrecedenceSorter;
 import org.jboss.aop.advice.Scope;
+import org.jboss.aop.array.ArrayAdvisor;
+import org.jboss.aop.array.ArrayBinding;
 import org.jboss.aop.array.ArrayReplacement;
 import org.jboss.aop.classpool.AOPClassPoolRepository;
 import org.jboss.aop.classpool.AOPScopedClassLoaderHelper;
@@ -118,6 +119,7 @@
 
    protected final LinkedHashMap interfaceIntroductions = new LinkedHashMap();
    protected final LinkedHashMap arrayReplacements = new LinkedHashMap();
+   protected final LinkedHashMap arrayBindings = new LinkedHashMap();
    protected final LinkedHashMap annotationIntroductions = new LinkedHashMap();
    protected final LinkedHashMap annotationOverrides = new LinkedHashMap();
    protected final LinkedHashMap bindings = new LinkedHashMap();
@@ -130,7 +132,7 @@
    protected final ConcurrentReaderHashMap dynamicCFlows = new ConcurrentReaderHashMap();
    protected final ConcurrentReaderHashMap aspectDefinitions = new ConcurrentReaderHashMap();
    protected final ConcurrentReaderHashMap perVMAspects = new ConcurrentReaderHashMap();
-
+   
    /** class name prefixes to explicitly exclude unless contained in include. Maintained by top-level AspectManager */
    protected final ArrayList exclude = new ArrayList();
 
@@ -1545,6 +1547,43 @@
    }
 
    /**
+    * Retrieve an introduction pointcut of a certain name
+    */
+   public InterfaceIntroduction getArrayBinding(String name)
+   {
+      synchronized (arrayBindings)
+      {
+         return (InterfaceIntroduction) arrayBindings.get(name);
+      }
+   }
+
+   /**
+    * Register an introduction pointcut
+    */
+   public synchronized void addArrayBinding(ArrayBinding binding)
+   {
+      removeArrayBinding(binding.getName());
+      synchronized (arrayBindings)
+      {
+         arrayBindings.put(binding.getName(), binding);
+         ArrayAdvisor.addBinding(binding);
+      }
+   }
+
+   /**
+    * remove an introduction pointcut of a certain name
+    */
+   public void removeArrayBinding(String name)
+   {
+      synchronized (arrayBindings)
+      {
+         ArrayBinding pointcut = (ArrayBinding) arrayBindings.remove(name);
+         if (pointcut == null) return;
+         ArrayAdvisor.removeBinding(pointcut);
+      }
+   }
+
+   /**
     * Register an annotation introduction
     */
    public synchronized void addAnnotationIntroduction(AnnotationIntroduction pointcut)

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/AspectXmlLoader.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -50,6 +50,7 @@
 import org.jboss.aop.advice.ScopeUtil;
 import org.jboss.aop.advice.ScopedInterceptorFactory;
 import org.jboss.aop.advice.ThrowingFactory;
+import org.jboss.aop.array.ArrayBinding;
 import org.jboss.aop.array.ArrayReplacement;
 import org.jboss.aop.introduction.AnnotationIntroduction;
 import org.jboss.aop.introduction.InterfaceIntroduction;
@@ -300,6 +301,33 @@
       manager.removePointcut(pointcut);
    }
 
+   public void deployArrayBinding(Element element) throws Exception
+   {
+      String name = getName(element, "arraybinding");
+      ArrayList interceptors = loadInterceptors(element);
+      InterceptorFactory[] inters = (InterceptorFactory[]) interceptors.toArray(new InterceptorFactory[interceptors.size()]);
+      for (int i = 0 ; i < inters.length ; i++)
+      {
+         if (!inters[i].getAspect().getScope().equals(Scope.PER_VM))
+         {
+            throw new RuntimeException("Only PER_VM scoped aspects/interceptors can be used in arraybindings");
+         }
+      }
+      ArrayBinding binding = new ArrayBinding(name, inters);
+      manager.addArrayBinding(binding);
+   }
+
+   public void undeployArrayBinding(Element element) throws Exception
+   {
+      String binding = getName(element, "arraybinding");
+      if (binding == null) throw new RuntimeException("undeploying Arraybinding that is null!");
+      manager.removeArrayBinding(binding);//done in bulkUndeploy() step
+//      bindings.add(binding);
+//      unloadInterceptors(element);
+      String pointcut = getName("pointcut");
+      manager.removePointcut(pointcut);
+   }
+
    private void deployPrecedence(Element element) throws Exception
    {
       String name = getName(element, "precedence");
@@ -1124,6 +1152,10 @@
             {
                deployArrayReplacement(element);
             }
+            else if (tag.equals("arraybind"))
+            {
+               deployArrayBinding(element);
+            }
             else
             {
                throw new IllegalArgumentException("Unknown AOP tag: " + tag);
@@ -1242,6 +1274,10 @@
             {
                undeployArrayReplacement(element);
             }
+            else if (tag.equals("arraybind"))
+            {
+               undeployArrayBinding(element);
+            }
          }
       }
    }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/advice/PrecedenceSorter.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/advice/PrecedenceSorter.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/advice/PrecedenceSorter.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -245,6 +245,7 @@
       if (interceptors.length == 0)
          return interceptors;
       
+      System.out.println(interceptors[0].getClass().getName());
       ArrayList all = new ArrayList(interceptors.length);
       ArrayList precedence = new ArrayList(interceptors.length);
       PrecedenceDefEntry[] precedenceEntries = manager.getSortedPrecedenceDefEntries();

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayAdvisor.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -21,7 +21,22 @@
 */ 
 package org.jboss.aop.array;
 
+import java.util.ArrayList;
+import java.util.HashSet;
+import java.util.LinkedHashSet;
+import java.util.concurrent.locks.Lock;
+import java.util.concurrent.locks.ReadWriteLock;
+import java.util.concurrent.locks.ReentrantReadWriteLock;
+
+import org.jboss.aop.AspectManager;
+import org.jboss.aop.advice.AdviceFactory;
+import org.jboss.aop.advice.GeneratedAdvisorInterceptor;
+import org.jboss.aop.advice.GeneratedOnly;
 import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.advice.InterceptorFactory;
+import org.jboss.aop.advice.PerVmAdvice;
+import org.jboss.aop.advice.PrecedenceSorter;
+import org.jboss.aop.advice.ScopedInterceptorFactory;
 
 /**
  * 
@@ -30,19 +45,24 @@
  */
 public class ArrayAdvisor
 {
-   //TODO Make configurable
-   static Interceptor[] interceptors = new Interceptor[] {new TestArrayElementInterceptor()};
-   public static Object array;
-   public static String value;
-   public static int index;
+   static HashSet<ArrayBinding> bindings = new LinkedHashSet<ArrayBinding>();
+   static boolean updated;
    
-   public static void clear()
+   public static void addBinding(ArrayBinding arrayBinding)
    {
-      array = null;
-      value = null;
-      index = -1;
+      ChainCreator.addBinding(arrayBinding);
    }
    
+   public static void removeBinding(ArrayBinding arrayBinding)
+   {
+      ChainCreator.removeBinding(arrayBinding);
+   }
+   
+   public static Interceptor[] getInterceptors()
+   {
+      return ChainCreator.getInterceptors();
+   }
+   
    public static void updateArrayField(Object target, String fieldName, Object oldValue, Object newValue)
    {
       ArrayRegistry registry = ArrayRegistry.getInstance();
@@ -52,6 +72,7 @@
 
    public static void arrayWriteObject(Object array, int index, Object value) throws Throwable
    {
+      Interceptor[] interceptors = getInterceptors();
       ArrayRegistry registry = ArrayRegistry.getInstance();
       if (registry.isRegistered(array))
       {
@@ -67,9 +88,12 @@
             {
                registry.addElementReference(array, index, value);
             }
-            ObjectArrayElementWriteInvocation invocation = new ObjectArrayElementWriteInvocation(interceptors, (Object[])array, index, value);
-            invocation.invokeNext();
-            return;
+            if (interceptors != null)
+            {
+               ObjectArrayElementWriteInvocation invocation = new ObjectArrayElementWriteInvocation(interceptors, (Object[])array, index, value);
+               invocation.invokeNext();
+               return;
+            }
          }
       }
       ((Object[])array)[index] = value;
@@ -77,7 +101,8 @@
    
    public static void arrayWriteInt(Object array, int index, int value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array) && ((int[])array)[index] != value)
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array) && ((int[])array)[index] != value)
       {
          IntArrayElementWriteInvocation invocation = new IntArrayElementWriteInvocation(interceptors, ((int[])array), index, value);
          invocation.invokeNext();
@@ -90,7 +115,8 @@
 
    public static void arrayWriteByteOrBoolean(Object array, int index, byte value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          if (array instanceof boolean[])
          {
@@ -118,7 +144,8 @@
 
    public static void arrayWriteChar(Object array, int index, char value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array) && ((char[])array)[index] != value)
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array) && ((char[])array)[index] != value)
       {
          CharArrayElementWriteInvocation invocation = new CharArrayElementWriteInvocation(interceptors, ((char[])array), index, value);
          invocation.invokeNext();
@@ -131,7 +158,8 @@
 
    public static void arrayWriteDouble(Object array, int index, double value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array) && ((double[])array)[index] != value)
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array) && ((double[])array)[index] != value)
       {
          DoubleArrayElementWriteInvocation invocation = new DoubleArrayElementWriteInvocation(interceptors, ((double[])array), index, value);
          invocation.invokeNext();
@@ -144,7 +172,8 @@
 
    public static void arrayWriteShort(Object array, int index, short value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array) && ((short[])array)[index] != value)
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array) && ((short[])array)[index] != value)
       {
          ShortArrayElementWriteInvocation invocation = new ShortArrayElementWriteInvocation(interceptors, ((short[])array), index, value);
          invocation.invokeNext();
@@ -157,7 +186,8 @@
 
    public static void arrayWriteFloat(Object array, int index, float value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array) && ((float[])array)[index] != value)
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array) && ((float[])array)[index] != value)
       {
          FloatArrayElementWriteInvocation invocation = new FloatArrayElementWriteInvocation(interceptors, ((float[])array), index, value);
          invocation.invokeNext();
@@ -170,7 +200,8 @@
 
    public static void arrayWriteLong(Object array, int index, long value) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array) && ((long[])array)[index] != value)
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array) && ((long[])array)[index] != value)
       {
          LongArrayElementWriteInvocation invocation = new LongArrayElementWriteInvocation(interceptors, ((long[])array), index, value);
          invocation.invokeNext();
@@ -183,7 +214,8 @@
 
    public static Object arrayReadObject(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          ObjectArrayElementReadInvocation invocation = new ObjectArrayElementReadInvocation(interceptors, (Object[])array, index);
          return invocation.invokeNext();
@@ -196,7 +228,8 @@
 
    public static int arrayReadInt(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          IntArrayElementReadInvocation invocation = new IntArrayElementReadInvocation(interceptors, (int[])array, index);
          return ((Integer)invocation.invokeNext()).intValue();
@@ -209,7 +242,8 @@
 
    public static byte arrayReadByteOrBoolean(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          if (array instanceof boolean[])
          {
@@ -238,7 +272,8 @@
 
    public static char arrayReadChar(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          CharArrayElementReadInvocation invocation = new CharArrayElementReadInvocation(interceptors, (char[])array, index);
          return ((Character)invocation.invokeNext()).charValue();
@@ -251,7 +286,8 @@
 
    public static double arrayReadDouble(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          DoubleArrayElementReadInvocation invocation = new DoubleArrayElementReadInvocation(interceptors, (double[])array, index);
          return ((Double)invocation.invokeNext()).doubleValue();
@@ -264,7 +300,8 @@
 
    public static float arrayReadFloat(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          FloatArrayElementReadInvocation invocation = new FloatArrayElementReadInvocation(interceptors, (float[])array, index);
          return ((Float)invocation.invokeNext()).floatValue();
@@ -277,7 +314,8 @@
 
    public static long arrayReadLong(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          LongArrayElementReadInvocation invocation = new LongArrayElementReadInvocation(interceptors, (long[])array, index);
          return ((Long)invocation.invokeNext()).longValue();
@@ -290,7 +328,8 @@
 
    public static short arrayReadShort(Object array, int index) throws Throwable
    {
-      if (ArrayRegistry.getInstance().isRegistered(array))
+      Interceptor[] interceptors = getInterceptors();
+      if (interceptors != null && ArrayRegistry.getInstance().isRegistered(array))
       {
          ShortArrayElementReadInvocation invocation = new ShortArrayElementReadInvocation(interceptors, (short[])array, index);
          return ((Short)invocation.invokeNext()).shortValue();
@@ -300,4 +339,128 @@
          return ((short[])array)[index];
       }
    }
+   
+   private static class ChainCreator
+   {
+      private static ReadWriteLock lock = new ReentrantReadWriteLock(); 
+      static Interceptor[] interceptors;
+      public static void addBinding(ArrayBinding arrayBinding)
+      {
+         Lock writeLock = lock.writeLock();
+         writeLock.lock();
+         try
+         {
+            bindings.add(arrayBinding);
+            updated = true;
+         }
+         finally
+         {
+            writeLock.unlock();
+         }
+      }
+      
+      public static void removeBinding(ArrayBinding arrayBinding)
+      {
+         Lock writeLock = lock.writeLock();
+         writeLock.lock();
+         try
+         {
+            bindings.remove(arrayBinding);
+            updated = true;
+         }
+         finally
+         {
+            writeLock.unlock();
+         }
+      }
+      
+      public static Interceptor[] getInterceptors()
+      {
+         Lock readLock = lock.readLock();
+         readLock.lock();
+         boolean lockedRead = true;
+         try
+         {
+            if (updated)
+            {
+               readLock.unlock();
+               lockedRead = false;
+               Lock writeLock = lock.writeLock();
+               writeLock.lock();
+               try
+               {
+                  if (updated)
+                  {
+                     //Create the interceptor chains
+                     for (ArrayBinding binding : bindings)
+                     {
+                        InterceptorFactory[] factories = binding.getInterceptorFactories();
+                        ArrayList<Interceptor> newinterceptors = new ArrayList<Interceptor>();
+                        for (int i = 0; i < factories.length; i++)
+                        {
+                           Interceptor icptr = createInterceptor(factories[i]);
+                           if (icptr != null)
+                           {
+                              newinterceptors.add(icptr);
+                           }
+                        }
+                        interceptors = (newinterceptors.size() > 0) ? newinterceptors.toArray(new Interceptor[newinterceptors.size()]) : null;
+                        if (interceptors != null)
+                        {
+                           if (interceptors[0] instanceof GeneratedAdvisorInterceptor)
+                           {
+                              
+                           }
+                           interceptors = PrecedenceSorter.applyPrecedence(interceptors, AspectManager.instance());
+                        }
+                     }
+                     updated = false;
+                     return interceptors;
+                  }
+               }
+               finally
+               {
+                  writeLock.unlock();               
+               }
+            }
+            return interceptors;
+         }
+         finally
+         {
+            if (lockedRead)
+            {
+               readLock.unlock();
+            }
+         }
+      }
+      
+      private static Interceptor createInterceptor(InterceptorFactory factory)
+      {
+         if (factory instanceof GeneratedOnly)
+         {
+            throw new RuntimeException("Before/After/Throwing is only supported for Generated Advisors");
+         }
+
+         try
+         {
+            if (factory.isDeployed())
+            {
+               if (factory instanceof AdviceFactory)
+               {
+                  return PerVmAdvice.generateOptimized(null, AspectManager.instance(), factory.getAdvice(), factory.getAspect());
+               }
+               else if (factory instanceof ScopedInterceptorFactory)
+               {
+                  return (Interceptor) AspectManager.instance().getPerVMAspect(factory.getAspect());
+               }
+            }
+            
+            return null;
+         }
+         catch (Exception e)
+         {
+            throw new RuntimeException(e);
+         }
+      }
+   }
 }

Added: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayBinding.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayBinding.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayBinding.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -0,0 +1,83 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.aop.array;
+
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.List;
+
+import org.jboss.aop.advice.InterceptorFactory;
+import org.jboss.aop.pointcut.Pointcut;
+import org.jboss.aop.pointcut.ast.ParseException;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class ArrayBinding 
+{
+   private static volatile long counter = 0;
+
+   protected String name;
+//   protected Pointcut pointcut;
+
+   protected InterceptorFactory[] interceptorFactories = new InterceptorFactory[0];
+
+   public ArrayBinding(String name/*, Pointcut p*/, InterceptorFactory[] factories) throws ParseException
+   {
+      this.name = name;
+      interceptorFactories = factories;
+//      pointcut = p;
+   }
+
+   public void addInterceptorFactory(InterceptorFactory factory)
+   {
+      List list = Arrays.asList(interceptorFactories);
+      list = new ArrayList(list);
+      list.add(factory);
+      interceptorFactories = (InterceptorFactory[]) list.toArray(new InterceptorFactory[list.size()]);
+   }
+
+
+   public String getName()
+   {
+      return name;
+   }
+
+   public InterceptorFactory[] getInterceptorFactories()
+   {
+      return interceptorFactories;
+   }
+
+   public boolean equals(Object obj)
+   {
+      if (obj == this) return true;
+      if (!(obj instanceof ArrayBinding)) return false;
+      return ((ArrayBinding) obj).getName().equals(name);
+   }
+
+   public int hashCode()
+   {
+      return name.hashCode();
+   }
+}

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -96,12 +96,6 @@
    }
 
    @Override
-   public MetaDataResolver getInstanceResolver()
-   {
-      throw new NotImplementedException();
-   }
-
-   @Override
    public Object getResponseAttachment(Object key)
    {
       throw new NotImplementedException();

Deleted: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/TestArrayElementInterceptor.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -1,64 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source.
-* Copyright 2006, 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.aop.array;
-
-import org.jboss.aop.advice.Interceptor;
-import org.jboss.aop.joinpoint.Invocation;
-
-/**
- * 
- * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
- * @version $Revision: 1.1 $
- */
-public class TestArrayElementInterceptor implements Interceptor
-{
-   public static int index;
-   public static Object value;
-   
-   public static void clear()
-   {
-      index = -1;
-      value = null;
-   }
-   
-   public String getName()
-   {
-      return this.getClass().getName();
-   }
-
-   public Object invoke(Invocation invocation) throws Throwable
-   {
-      if (invocation instanceof ArrayElementReadInvocation)
-      {
-         index = ((ArrayElementReadInvocation)invocation).getIndex();
-         value = null;
-      }
-      else if (invocation instanceof ArrayElementWriteInvocation)
-      {
-         index = ((ArrayElementWriteInvocation)invocation).getIndex();
-         value = ((ArrayElementWriteInvocation)invocation).getValue();
-      } 
-      
-      return invocation.invokeNext();
-   }
-
-}

Modified: projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml
===================================================================
--- projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/resources/test/array/jboss-aop.xml	2006-12-28 23:35:15 UTC (rev 59243)
@@ -5,6 +5,19 @@
    <arrayreplacement expr="class($instanceof{org.jboss.test.aop.array.ClassForReference})"/>
    <prepare expr="field(* org.jboss.test.aop.array.ClassWithArrayFields->*)"/>
    <prepare expr="field(* org.jboss.test.aop.array.ClassWithSeveralReferencesToSameArray->*)"/> 
-   <prepare expr="field(* org.jboss.test.aop.array.ClassForReference->*)"/> 
+   <prepare expr="field(* org.jboss.test.aop.array.ClassForReference->*)"/>
+   
+   <aspect class="org.jboss.test.aop.array.AspectForPrecedence"/>
+   <interceptor class="org.jboss.test.aop.array.TestArrayElementInterceptor"/>
+
+   <precedence>
+   	<interceptor-ref name="org.jboss.test.aop.array.TestArrayElementInterceptor"/>
+   	<advice aspect="org.jboss.test.aop.array.AspectForPrecedence" name="advice"/>
+   </precedence>
+
+   <arraybind>
+   	<advice aspect="org.jboss.test.aop.array.AspectForPrecedence" name="advice"/>
+   	<interceptor-ref name="org.jboss.test.aop.array.TestArrayElementInterceptor"/>
+   </arraybind>
 </aop>
 

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AOPArrayTestCase.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -24,7 +24,6 @@
 import junit.framework.Test;
 import junit.framework.TestSuite;
 
-import org.jboss.aop.array.TestArrayElementInterceptor;
 import org.jboss.test.aop.AOPTestWithSetup;
 
 
@@ -52,156 +51,192 @@
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.objects[2] = "X";
       assertEquals(2, TestArrayElementInterceptor.index);
       assertEquals("X", TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       Object o = obj.objects[0];
       assertEquals("1", o);
       assertEquals(0, TestArrayElementInterceptor.index);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testIntArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.ints[1] = 100; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(100, ((Integer)TestArrayElementInterceptor.value).intValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.ints[2] = 123;
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       int val = obj.ints[2];
       assertEquals(123, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testByteArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.bytes[1] = 100; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(100, ((Byte)TestArrayElementInterceptor.value).byteValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.bytes[2] = 123;
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       byte val = obj.bytes[2];
       assertEquals(123, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testBooleanArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.booleans[1] = true;
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(true, ((Boolean)TestArrayElementInterceptor.value).booleanValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       boolean val = obj.booleans[1];
       assertEquals(true, val);
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testCharArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.chars[1] = 'z'; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals('z', ((Character)TestArrayElementInterceptor.value).charValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.chars[2] = 'x';
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       char val = obj.chars[2];
       assertEquals('x', val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
 
    public void testDoubleArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.doubles[1] = 2.1d; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(2.1d, ((Double)TestArrayElementInterceptor.value).doubleValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.doubles[2] = 9.9d;
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       double val = obj.doubles[2];
       assertEquals(9.9d, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testFloatArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.floats[1] = 2.1f; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(2.1f, ((Float)TestArrayElementInterceptor.value).floatValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.floats[2] = 9.9f;
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       double val = obj.floats[2];
       assertEquals(9.9f, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testLongArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.longs[1] = 100L; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(100L, ((Long)TestArrayElementInterceptor.value).longValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.longs[2] = 200L;
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       double val = obj.longs[2];
       assertEquals(200L, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testShortArray()
    {
       ClassWithArrayFields obj = new ClassWithArrayFields();
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       obj.shorts[1] = 50; 
       assertEquals(1, TestArrayElementInterceptor.index);
       assertNotNull(TestArrayElementInterceptor.value);
       assertEquals(50, ((Short)TestArrayElementInterceptor.value).shortValue());
+      assertTrue(AspectForPrecedence.invoked);
 
       obj.shorts[2] = 100;
       
       TestArrayElementInterceptor.clear();
+      AspectForPrecedence.invoked = false;
       double val = obj.shorts[2];
       assertEquals(100, val);
       assertEquals(2, TestArrayElementInterceptor.index);
       assertNull(TestArrayElementInterceptor.value);
+      assertTrue(AspectForPrecedence.invoked);
    }
    
    public void testMultiDimensionalTopLevelArray()

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AspectForPrecedence.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AspectForPrecedence.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/AspectForPrecedence.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -0,0 +1,49 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+import org.jboss.aop.joinpoint.Invocation;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class AspectForPrecedence
+{
+   public static boolean invoked = false;
+   public Object advice(Invocation invocation) throws Throwable
+   {
+      Object o = invocation.getMetaData("test", "invoked");
+      if (o == null)
+      {
+         throw new RuntimeException("Expected some metadata");
+      }
+      if (!o.equals("TestArrayElementInterceptor"))
+      {
+         throw new RuntimeException("Expected metadata to be 'TestArrayElementInterceptor', it was " + o);
+      }
+      invoked = true;
+      return invocation.invokeNext();
+   }
+
+}

Added: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java	2006-12-28 23:32:30 UTC (rev 59242)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java	2006-12-28 23:35:15 UTC (rev 59243)
@@ -0,0 +1,67 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, 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.test.aop.array;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.array.ArrayElementReadInvocation;
+import org.jboss.aop.array.ArrayElementWriteInvocation;
+import org.jboss.aop.joinpoint.Invocation;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class TestArrayElementInterceptor implements Interceptor
+{
+   public static int index;
+   public static Object value;
+   
+   public static void clear()
+   {
+      index = -1;
+      value = null;
+   }
+   
+   public String getName()
+   {
+      return this.getClass().getName();
+   }
+
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+      if (invocation instanceof ArrayElementReadInvocation)
+      {
+         index = ((ArrayElementReadInvocation)invocation).getIndex();
+         value = null;
+      }
+      else if (invocation instanceof ArrayElementWriteInvocation)
+      {
+         index = ((ArrayElementWriteInvocation)invocation).getIndex();
+         value = ((ArrayElementWriteInvocation)invocation).getValue();
+      } 
+      
+      invocation.getMetaData().addMetaData("test", "invoked", "TestArrayElementInterceptor");
+      return invocation.invokeNext();
+   }
+
+}



From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 21:02:18 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 21:02:18 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1868 -
	trunk/src/etc/server/default/deploy
Message-ID: <E1H074c-0008NC-VQ@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-28 21:02:17 -0500 (Thu, 28 Dec 2006)
New Revision: 1868

Added:
   trunk/src/etc/server/default/deploy/clustered-postgresql-persistence-service.xml
Log:
A clustered postgresql persistence config file. Contribution of Juergen Zimmermann. Not tested

Added: trunk/src/etc/server/default/deploy/clustered-postgresql-persistence-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/clustered-postgresql-persistence-service.xml	2006-12-28 20:58:01 UTC (rev 1867)
+++ trunk/src/etc/server/default/deploy/clustered-postgresql-persistence-service.xml	2006-12-29 02:02:17 UTC (rev 1868)
@@ -0,0 +1,92 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<!--
+     Postgres persistence deployment descriptor.
+
+     $Id: postgresql-persistence-service.xml 1766 2006-12-11 22:29:27Z ovidiu.feodorov at jboss.com $
+ -->
+
+<server>
+
+   <mbean code="org.jboss.messaging.core.plugin.JDBCPersistenceManagerService"
+          name="jboss.messaging:service=PersistenceManager"
+          xmbean-dd="xmdesc/JDBCPersistenceManager-xmbean.xml">
+      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
+      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
+      <attribute name="DataSource">java:/DefaultDS</attribute>
+      <attribute name="CreateTablesOnStartup">true</attribute>
+      <attribute name="UsingBatchUpdates">true</attribute>
+      <attribute name="SqlProperties"><![CDATA[
+CREATE_MESSAGE_REFERENCE=CREATE TABLE JMS_MESSAGE_REFERENCE (CHANNELID BIGINT, MESSAGEID BIGINT, TRANSACTIONID BIGINT, STATE CHAR(1), ORD BIGINT, PAGE_ORD BIGINT, DELIVERYCOUNT INTEGER, RELIABLE CHAR(1), LOADED CHAR(1), PRIMARY KEY(CHANNELID, MESSAGEID))
+CREATE_IDX_MESSAGE_REF_TX=CREATE INDEX JMS_MESSAGE_REF_TX ON JMS_MESSAGE_REFERENCE (TRANSACTIONID)
+CREATE_IDX_MESSAGE_REF_ORD=CREATE INDEX JMS_MESSAGE_REF_ORD ON JMS_MESSAGE_REFERENCE (ORD)
+CREATE_IDX_MESSAGE_REF_PAGE_ORD=CREATE INDEX JMS_MESSAGE_REF_LOADED ON JMS_MESSAGE_REFERENCE (PAGE_ORD)
+CREATE_IDX_MESSAGE_REF_MESSAGEID=CREATE INDEX JMS_MESSAGE_REF_MESSAGEID ON JMS_MESSAGE_REFERENCE (MESSAGEID)
+CREATE_IDX_MESSAGE_REF_RELIABLE=CREATE INDEX JMS_MESSAGE_REF_RELIABLE ON JMS_MESSAGE_REFERENCE (RELIABLE)
+CREATE_MESSAGE=CREATE TABLE JMS_MESSAGE (MESSAGEID BIGINT, RELIABLE CHAR(1), EXPIRATION BIGINT, TIMESTAMP BIGINT, PRIORITY SMALLINT, COREHEADERS BYTEA, PAYLOAD BYTEA, CHANNELCOUNT INTEGER, TYPE SMALLINT, JMSTYPE VARCHAR(255), CORRELATIONID VARCHAR(255), CORRELATIONID_BYTES BYTEA, DESTINATION VARCHAR(255), REPLYTO VARCHAR(255), JMSPROPERTIES BYTEA, PRIMARY KEY (MESSAGEID))
+CREATE_TRANSACTION=CREATE TABLE JMS_TRANSACTION (TRANSACTIONID BIGINT, BRANCH_QUAL BYTEA, FORMAT_ID INTEGER, GLOBAL_TXID BYTEA, PRIMARY KEY (TRANSACTIONID))
+CREATE_COUNTER=CREATE TABLE JMS_COUNTER (NAME VARCHAR(255), NEXT_ID BIGINT, PRIMARY KEY(NAME))
+INSERT_MESSAGE_REF=INSERT INTO JMS_MESSAGE_REFERENCE (CHANNELID, MESSAGEID, TRANSACTIONID, STATE, ORD, PAGE_ORD, DELIVERYCOUNT, RELIABLE) VALUES (?, ?, ?, ?, ?, ?, ?, ?)
+DELETE_MESSAGE_REF=DELETE FROM JMS_MESSAGE_REFERENCE WHERE MESSAGEID=? AND CHANNELID=? AND STATE='C'
+UPDATE_MESSAGE_REF=UPDATE JMS_MESSAGE_REFERENCE SET TRANSACTIONID=?, STATE='-' WHERE MESSAGEID=? AND CHANNELID=? AND STATE='C'
+UPDATE_PAGE_ORDER=UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = ? WHERE MESSAGEID=? AND CHANNELID=?
+COMMIT_MESSAGE_REF1=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='+'
+COMMIT_MESSAGE_REF2=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='-'
+ROLLBACK_MESSAGE_REF1=DELETE FROM JMS_MESSAGE_REFERENCE WHERE TRANSACTIONID=? AND STATE='+'
+ROLLBACK_MESSAGE_REF2=UPDATE JMS_MESSAGE_REFERENCE SET STATE='C', TRANSACTIONID = NULL WHERE TRANSACTIONID=? AND STATE='-'
+LOAD_PAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, PAGE_ORD, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND PAGE_ORD BETWEEN ? AND ? ORDER BY PAGE_ORD
+LOAD_UNPAGED_REFS=SELECT MESSAGEID, DELIVERYCOUNT, RELIABLE FROM JMS_MESSAGE_REFERENCE WHERE PAGE_ORD IS NULL and CHANNELID = ? ORDER BY ORD
+UPDATE_RELIABLE_REFS_NOT_PAGED=UPDATE JMS_MESSAGE_REFERENCE SET PAGE_ORD = NULL WHERE PAGE_ORD BETWEEN ? AND ? AND CHANNELID=?
+SELECT_MIN_MAX_PAGE_ORD=SELECT MIN(PAGE_ORD), MAX(PAGE_ORD) FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ?
+SELECT_EXISTS_REF=SELECT MESSAGEID FROM JMS_MESSAGE_REFERENCE WHERE CHANNELID = ? AND MESSAGEID = ?
+UPDATE_DELIVERYCOUNT=UPDATE JMS_MESSAGE_REFERENCE SET DELIVERYCOUNT = ? WHERE CHANNELID = ? AND MESSAGEID = ?
+LOAD_MESSAGES=SELECT MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION, REPLYTO, JMSPROPERTIES FROM JMS_MESSAGE
+INSERT_MESSAGE=INSERT INTO JMS_MESSAGE (MESSAGEID, RELIABLE, EXPIRATION, TIMESTAMP, PRIORITY, COREHEADERS, PAYLOAD, CHANNELCOUNT, TYPE, JMSTYPE, CORRELATIONID, CORRELATIONID_BYTES, DESTINATION, REPLYTO, JMSPROPERTIES) VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
+INC_CHANNELCOUNT=UPDATE JMS_MESSAGE SET CHANNELCOUNT = CHANNELCOUNT + 1 WHERE MESSAGEID=?
+DEC_CHANNELCOUNT=UPDATE JMS_MESSAGE SET CHANNELCOUNT = CHANNELCOUNT - 1 WHERE MESSAGEID=?
+DELETE_MESSAGE=DELETE FROM JMS_MESSAGE WHERE MESSAGEID=? AND CHANNELCOUNT=0
+MESSAGEID_COLUMN=MESSAGEID
+MESSAGE_EXISTS=SELECT MESSAGEID FROM JMS_MESSAGE WHERE MESSAGEID = ? FOR UPDATE
+INSERT_TRANSACTION=INSERT INTO JMS_TRANSACTION (TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID) VALUES(?, ?, ?, ?)
+DELETE_TRANSACTION=DELETE FROM JMS_TRANSACTION WHERE TRANSACTIONID = ?
+SELECT_PREPARED_TRANSACTIONS=SELECT TRANSACTIONID, BRANCH_QUAL, FORMAT_ID, GLOBAL_TXID FROM JMS_TRANSACTION
+UPDATE_COUNTER=UPDATE JMS_COUNTER SET NEXT_ID = ? WHERE NAME=?
+SELECT_COUNTER=SELECT NEXT_ID FROM JMS_COUNTER WHERE NAME=? FOR UPDATE
+INSERT_COUNTER=INSERT INTO JMS_COUNTER (NAME, NEXT_ID) VALUES (?, ?)
+SELECT_ALL_CHANNELS=SELECT DISTINCT(CHANNELID) FROM JMS_MESSAGE_REFERENCE
+           ]]></attribute>
+      <attribute name="MaxParams">500</attribute>
+   </mbean>
+
+   <mbean code="org.jboss.messaging.core.plugin.DefaultPostOfficeService"
+      name="jboss.messaging:service=PostOffice"
+      xmbean-dd="xmdesc/DefaultPostOffice-xmbean.xml">
+      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
+      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
+      <attribute name="PostOfficeName">JMS</attribute>
+      <attribute name="DataSource">java:/DefaultDS</attribute>
+      <attribute name="CreateTablesOnStartup">true</attribute>
+      <attribute name="SqlProperties"><![CDATA[
+CREATE_POSTOFFICE_TABLE=CREATE TABLE JMS_POSTOFFICE (POSTOFFICE_NAME VARCHAR(255), NODE_ID INTEGER, QUEUE_NAME VARCHAR(1023), COND VARCHAR(1023), SELECTOR VARCHAR(1023), CHANNEL_ID BIGINT, IS_FAILED_OVER CHAR(1))
+INSERT_BINDING=INSERT INTO JMS_POSTOFFICE (POSTOFFICE_NAME, NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID, IS_FAILED_OVER) VALUES (?, ?, ?, ?, ?, ?, ?)
+DELETE_BINDING=DELETE FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME=? AND NODE_ID=? AND QUEUE_NAME=?
+LOAD_BINDINGS=SELECT NODE_ID, QUEUE_NAME, COND, SELECTOR, CHANNEL_ID FROM JMS_POSTOFFICE WHERE POSTOFFICE_NAME  = ?
+      ]]></attribute>
+   </mbean>
+
+   <mbean code="org.jboss.jms.server.plugin.JDBCJMSUserManagerService"
+      name="jboss.messaging:service=JMSUserManager"
+      xmbean-dd="xmdesc/JMSUserManager-xmbean.xml">
+      <depends>jboss.jca:service=DataSourceBinding,name=DefaultDS</depends>
+      <depends optional-attribute-name="TransactionManager">jboss:service=TransactionManager</depends>
+      <attribute name="DataSource">java:/DefaultDS</attribute>
+      <attribute name="CreateTablesOnStartup">true</attribute>
+      <attribute name="SqlProperties"><![CDATA[
+CREATE_USER_TABLE=CREATE TABLE JMS_USER (USERID VARCHAR(32) NOT NULL, PASSWD VARCHAR(32) NOT NULL, CLIENTID VARCHAR(128), PRIMARY KEY(USERID))
+CREATE_ROLE_TABLE=CREATE TABLE JMS_ROLE (ROLEID VARCHAR(32) NOT NULL, USERID VARCHAR(32) NOT NULL, PRIMARY KEY(USERID, ROLEID))
+SELECT_PRECONF_CLIENTID=SELECT CLIENTID FROM JMS_USER WHERE USERID=?
+      ]]></attribute>
+   </mbean>
+
+</server>
\ No newline at end of file



From ron_sigal at yahoo.com  Thu Dec 28 21:23:36 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:23:36 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1H07PE-0000F9-Hs@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:23:36

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket 
                        BisocketTestCase.java
  Log:
  JBREM-650:  Raised log level to DEBUG.
  
  Revision  Changes    Path
  1.3       +19 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- BisocketTestCase.java	27 Dec 2006 06:13:49 -0000	1.2
  +++ BisocketTestCase.java	29 Dec 2006 02:23:36 -0000	1.3
  @@ -36,7 +36,12 @@
   
   import junit.framework.TestCase;
   
  -import org.jboss.logging.Logger;
  +import org.apache.log4j.BasicConfigurator;
  +import org.apache.log4j.Category;
  +import org.apache.log4j.ConsoleAppender;
  +import org.apache.log4j.Level;
  +import org.apache.log4j.PatternLayout;
  +import org.apache.log4j.Logger;
   import org.jboss.remoting.Client;
   import org.jboss.remoting.InvocationRequest;
   import org.jboss.remoting.InvokerLocator;
  @@ -55,7 +60,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -79,6 +84,8 @@
      private Connector connector;
      private SampleInvocationHandler invocationHandler;
   
  +   private boolean firstTime = true;
  +
   
      
      /**
  @@ -86,6 +93,16 @@
       */
      public void setUp() throws Exception
      {
  +      if (firstTime)
  +      {
  +         Logger.getLogger("org.jboss.remoting").setLevel(Level.DEBUG);
  +         Logger.getLogger("org.jboss.test.remoting").setLevel(Level.DEBUG);
  +         String pattern = "[%d{ABSOLUTE}] [%t] %5p (%F:%L) - %m%n";
  +         PatternLayout layout = new PatternLayout(pattern);
  +         ConsoleAppender consoleAppender = new ConsoleAppender(layout);
  +         Logger.getRootLogger().addAppender(consoleAppender);  
  +      }
  +      
         String locatorURI = getTransport() + "://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  
  
  


From ron_sigal at yahoo.com  Thu Dec 28 21:34:56 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:34:56 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder
	...
Message-ID: <E1H07aC-0000Nl-W3@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:34:56

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder  
                        SSLBisocketInvokerTestClient.java
                        SSLBisocketInvokerTestServer.java
  Log:
  JBREM-650:  Changed port to avoid collision.
  
  Revision  Changes    Path
  1.3       +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SSLBisocketInvokerTestClient.java	27 Dec 2006 06:14:53 -0000	1.2
  +++ SSLBisocketInvokerTestClient.java	29 Dec 2006 02:34:56 -0000	1.3
  @@ -23,6 +23,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 7;
      }
   }
  
  
  
  1.3       +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SSLBisocketInvokerTestServer.java	27 Dec 2006 06:14:53 -0000	1.2
  +++ SSLBisocketInvokerTestServer.java	29 Dec 2006 02:34:56 -0000	1.3
  @@ -38,6 +38,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 7;
      }
   }
  
  
  


From ron_sigal at yahoo.com  Thu Dec 28 21:34:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:34:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check
	...
Message-ID: <E1H07aD-0000Nv-3n@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:34:57

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check  
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650:  Changed port to avoid collision.
  
  Revision  Changes    Path
  1.3       +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:53 -0000	1.2
  +++ SSLBisocketInvokerClientTest.java	29 Dec 2006 02:34:57 -0000	1.3
  @@ -20,7 +20,7 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 11;
      }
   
   }
  
  
  
  1.3       +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SSLBisocketInvokerServerTest.java	27 Dec 2006 06:14:53 -0000	1.2
  +++ SSLBisocketInvokerServerTest.java	29 Dec 2006 02:34:57 -0000	1.3
  @@ -33,6 +33,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 11;
      }
   }
  
  
  


From ron_sigal at yahoo.com  Thu Dec 28 21:34:57 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:34:57 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic
	...
Message-ID: <E1H07aD-0000O5-8H@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:34:57

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic  
                        SSLBisocketInvokerClientTest.java
                        SSLBisocketInvokerServerTest.java
  Log:
  JBREM-650:  Changed port to avoid collision.
  
  Revision  Changes    Path
  1.3       +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SSLBisocketInvokerClientTest.java	27 Dec 2006 06:14:53 -0000	1.2
  +++ SSLBisocketInvokerClientTest.java	29 Dec 2006 02:34:57 -0000	1.3
  @@ -41,6 +41,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 3;
      }
   }
  
  
  
  1.3       +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SSLBisocketInvokerServerTest.java	27 Dec 2006 06:14:53 -0000	1.2
  +++ SSLBisocketInvokerServerTest.java	29 Dec 2006 02:34:57 -0000	1.3
  @@ -54,6 +54,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 3;
      }
   }
  
  
  


From ron_sigal at yahoo.com  Thu Dec 28 21:36:59 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:36:59 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check
	...
Message-ID: <E1H07cB-0000S9-VV@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:36:59

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check  
                        Tag: remoting_2_x SSLBisocketInvokerServerTest.java
                        SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650:  Changed port to avoid collision.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  +++ SSLBisocketInvokerServerTest.java	29 Dec 2006 02:36:59 -0000	1.1.2.2
  @@ -33,6 +33,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 11;
      }
   }
  
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:22 -0000	1.1.2.1
  +++ SSLBisocketInvokerClientTest.java	29 Dec 2006 02:36:59 -0000	1.1.2.2
  @@ -20,7 +20,7 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 11;
      }
   
   }
  
  
  


From ron_sigal at yahoo.com  Thu Dec 28 21:37:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:37:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder
	...
Message-ID: <E1H07cC-0000SN-2m@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:37:00

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder  
                        Tag: remoting_2_x SSLBisocketInvokerTestServer.java
                        SSLBisocketInvokerTestClient.java
  Log:
  JBREM-650:  Changed port to avoid collision.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerTestServer.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ SSLBisocketInvokerTestServer.java	29 Dec 2006 02:37:00 -0000	1.1.2.2
  @@ -38,6 +38,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 7;
      }
   }
  
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerTestClient.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerTestClient.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ SSLBisocketInvokerTestClient.java	29 Dec 2006 02:37:00 -0000	1.1.2.2
  @@ -23,6 +23,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 7;
      }
   }
  
  
  


From ron_sigal at yahoo.com  Thu Dec 28 21:37:00 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Thu, 28 Dec 2006 21:37:00 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic
	...
Message-ID: <E1H07cC-0000Sb-7O@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/28 21:37:00

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic  
                        Tag: remoting_2_x SSLBisocketInvokerServerTest.java
                        SSLBisocketInvokerClientTest.java
  Log:
  JBREM-650:  Changed port to avoid collision.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerServerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerServerTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ SSLBisocketInvokerServerTest.java	29 Dec 2006 02:37:00 -0000	1.1.2.2
  @@ -54,6 +54,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 3;
      }
   }
  
  
  
  1.1.2.2   +1 -1      JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SSLBisocketInvokerClientTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java,v
  retrieving revision 1.1.2.1
  retrieving revision 1.1.2.2
  diff -u -b -r1.1.2.1 -r1.1.2.2
  --- SSLBisocketInvokerClientTest.java	19 Dec 2006 06:19:23 -0000	1.1.2.1
  +++ SSLBisocketInvokerClientTest.java	29 Dec 2006 02:37:00 -0000	1.1.2.2
  @@ -41,6 +41,6 @@
      
      protected int getPort()
      {
  -      return bisocketPort;
  +      return bisocketPort + 3;
      }
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 21:39:44 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 21:39:44 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1869 -
	trunk/tests/src/org/jboss/test/messaging/jms/message
Message-ID: <E1H07eq-0000Sr-MS@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-28 21:39:43 -0500 (Thu, 28 Dec 2006)
New Revision: 1869

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java
Log:
reverted timeout changes; if test fails, I need to see the failure snapshot

Modified: trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java	2006-12-29 02:02:17 UTC (rev 1868)
+++ trunk/tests/src/org/jboss/test/messaging/jms/message/JMSExpirationHeaderTest.java	2006-12-29 02:39:43 UTC (rev 1869)
@@ -88,7 +88,7 @@
    {
       Message m = queueProducerSession.createMessage();
       queueProducer.send(m, DeliveryMode.NON_PERSISTENT, 4, 5000);
-      Message result = queueConsumer.receive(1000);
+      Message result = queueConsumer.receive(10);
       assertEquals(m.getJMSMessageID(), result.getJMSMessageID());
    }
 
@@ -97,7 +97,7 @@
       Message m = queueProducerSession.createMessage();
       queueProducer.send(m, DeliveryMode.NON_PERSISTENT, 4, 1000);
       Thread.sleep(2000);
-      assertNull(queueConsumer.receive(1000));
+      assertNull(queueConsumer.receive(100));
    }
 
    public void testExpirationOnReceiveNoWait() throws Exception



From jboss-cvs-commits at lists.jboss.org  Thu Dec 28 22:02:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Thu, 28 Dec 2006 22:02:12 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1870 - in
	trunk/tests/src/org/jboss/test/messaging: jms/clustering
	jms/server/destination tools tools/jmx/rmi
Message-ID: <E1H080a-00010L-I1@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-28 22:02:10 -0500 (Thu, 28 Dec 2006)
New Revision: 1870

Modified:
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
Log:
minor tweaks

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-29 02:39:43 UTC (rev 1869)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-29 03:02:10 UTC (rev 1870)
@@ -75,11 +75,13 @@
          // kill node 1
 
 
+
+         ServerManagement.killAndWait(1);
+
          log.info("########");
          log.info("######## KILLED NODE 1");
          log.info("########");
 
-         ServerManagement.killAndWait(1);
          try
          {
             ic[1].lookup("queue"); // looking up anything

Modified: trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java	2006-12-29 02:39:43 UTC (rev 1869)
+++ trunk/tests/src/org/jboss/test/messaging/jms/server/destination/TopicManagementTest.java	2006-12-29 03:02:10 UTC (rev 1870)
@@ -34,7 +34,6 @@
 import javax.jms.TopicConnection;
 import javax.jms.TopicConnectionFactory;
 import javax.jms.TopicSession;
-import javax.jms.TopicSubscriber;
 import javax.management.ObjectName;
 import javax.naming.InitialContext;
 
@@ -662,7 +661,7 @@
          ObjectName destObjectName = 
             new ObjectName("jboss.messaging.destination:service=Topic,name=TopicMessageList");
          
-         String strSub = (String)ServerManagement.invoke(destObjectName, "listSubscriptionsAsText", null, null);
+         ServerManagement.invoke(destObjectName, "listSubscriptionsAsText", null, null);
          
          
          // Note that listing the messages ONLY list those ones not in the process of delivery

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-29 02:39:43 UTC (rev 1869)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-29 03:02:10 UTC (rev 1870)
@@ -261,11 +261,11 @@
    }
 
    /** 
-    * Kills the server and wait keep trying any dumb communication until the server is effectively killed.
-    * We had to implement this method as kill will actually schedule a thread that will perform System.exit
-    * after few milliseconds.
-    * We will use this method in places where we need the server killed.
-    * */
+    * Kills the server and waits keep trying any dumb communication until the server is effectively
+    * killed. We had to implement this method as kill will actually schedule a thread that will
+    * perform System.exit after few milliseconds. We will use this method in places where we need
+    * the server killed.
+    */
    public static synchronized void killAndWait(int i) throws Exception
    {
       Server server = servers[i].getServer();

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-29 02:39:43 UTC (rev 1869)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/rmi/LocalTestServer.java	2006-12-29 03:02:10 UTC (rev 1870)
@@ -61,7 +61,7 @@
 
    private static final Logger log = Logger.getLogger(LocalTestServer.class);
 
-   // Static --------------------------------------------------------    4
+   // Static --------------------------------------------------------
 
    public static void setEnvironmentServerIndex(int serverIndex)
    {



From forge-admin at jboss.com  Fri Dec 29 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Fri, 29 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1H0An5-0003rD-14@committer01.frg.pub.inap.atl.jboss.com>

Commit from rsigal (2006-12-28 03:10 EST)
------------------

JBREM-631:  Restored missing logger static variable.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/socket/connection/SocketTestClient.java  1.10


Commit from rsigal (2006-12-28 21:23 EST)
------------------

JBREM-650:  Raised log level to DEBUG.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java  1.3


Commit from rsigal (2006-12-28 21:34 EST)
------------------

JBREM-650:  Changed port to avoid collision.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java           1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java           1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java  1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java  1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java             1.3
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java             1.3


Commit from rsigal on branch remoting_2_x (2006-12-28 21:36 EST)
-----------------------------------------

JBREM-650:  Changed port to avoid collision.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerServerTest.java  1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/connection_check/SSLBisocketInvokerClientTest.java  1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestServer.java           1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/builder/SSLBisocketInvokerTestClient.java           1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerServerTest.java             1.1.2.2
  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/ssl/basic/SSLBisocketInvokerClientTest.java             1.1.2.2
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061229/9293f9ba/attachment.html 

From ron_sigal at yahoo.com  Fri Dec 29 01:31:31 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Fri, 29 Dec 2006 01:31:31 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1H0BH9-0004V5-RJ@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/29 01:31:31

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        ServerInvoker.java
  Log:
  JBREM-650:  Remove some log statements accidentally commited.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.52.2.7  +2 -10     JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java,v
  retrieving revision 1.52.2.6
  retrieving revision 1.52.2.7
  diff -u -b -r1.52.2.6 -r1.52.2.7
  --- ServerInvoker.java	19 Dec 2006 06:00:28 -0000	1.52.2.6
  +++ ServerInvoker.java	29 Dec 2006 06:31:31 -0000	1.52.2.7
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.52.2.6 $
  + * @version $Revision: 1.52.2.7 $
    */
   public abstract class ServerInvoker extends AbstractInvoker implements ServerInvokerMBean
   {
  @@ -1025,13 +1025,6 @@
         }
         else
         {
  -         log.error(this + ": not started");
  -         log.error("request: " + invocation.getParameter());
  -         if (invocation.getParameter() instanceof InternalInvocation)
  -         {
  -            InternalInvocation ii = (InternalInvocation) invocation.getParameter();
  -            log.error("internal invocation: " + ii.getMethodName());
  -         }
            throw new InvalidStateException("Can not process invocation request since is not in started state.");
         }
      }
  @@ -1412,7 +1405,7 @@
      public void start() throws IOException
      {
         started = true;
  -      log.debug(this + ": Invoker started for locator: " + getLocator());
  +      log.debug("Invoker started for locator: " + getLocator());
      }
   
      /**
  @@ -1430,7 +1423,6 @@
       */
      public void stop()
      {
  -      log.info(this + ": stopping");
         started = false;
   
         Iterator it = callbackHandlers.values().iterator();
  
  
  


From ron_sigal at yahoo.com  Fri Dec 29 01:33:46 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Fri, 29 Dec 2006 01:33:46 -0500
Subject: [jboss-cvs] JBossRemoting/src/main/org/jboss/remoting  ...
Message-ID: <E1H0BJK-0004X3-T4@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/29 01:33:46

  Modified:    src/main/org/jboss/remoting  Tag: remoting_2_x
                        ServerInvoker.java
  Log:
  JBREM-650:  Removed log.info() accidentally committed.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.52.2.8  +1 -2      JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ServerInvoker.java,v
  retrieving revision 1.52.2.7
  retrieving revision 1.52.2.8
  diff -u -b -r1.52.2.7 -r1.52.2.8
  --- ServerInvoker.java	29 Dec 2006 06:31:31 -0000	1.52.2.7
  +++ ServerInvoker.java	29 Dec 2006 06:33:46 -0000	1.52.2.8
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:tom.elrod at jboss.com">Tom Elrod</a>
  - * @version $Revision: 1.52.2.7 $
  + * @version $Revision: 1.52.2.8 $
    */
   public abstract class ServerInvoker extends AbstractInvoker implements ServerInvokerMBean
   {
  @@ -1431,7 +1431,6 @@
            ServerInvokerCallbackHandler callbackHandler = (ServerInvokerCallbackHandler) it.next();
            callbackHandler.destroy();
         }
  -      log.info(this + ": stopped");
      }
   
      /**
  
  
  


From ron_sigal at yahoo.com  Fri Dec 29 01:46:30 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Fri, 29 Dec 2006 01:46:30 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1H0BVe-0004kx-DL@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/29 01:46:30

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketTestCase.java
  Log:
  JBREM-650:  Added test method for restarted Connector.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +107 -3    JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- BisocketTestCase.java	20 Dec 2006 08:57:15 -0000	1.1.2.3
  +++ BisocketTestCase.java	29 Dec 2006 06:46:30 -0000	1.1.2.4
  @@ -36,7 +36,12 @@
   
   import junit.framework.TestCase;
   
  -import org.jboss.logging.Logger;
  +import org.apache.log4j.BasicConfigurator;
  +import org.apache.log4j.Category;
  +import org.apache.log4j.ConsoleAppender;
  +import org.apache.log4j.Level;
  +import org.apache.log4j.PatternLayout;
  +import org.apache.log4j.Logger;
   import org.jboss.remoting.Client;
   import org.jboss.remoting.InvocationRequest;
   import org.jboss.remoting.InvokerLocator;
  @@ -55,7 +60,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.3 $
  + * @version $Revision: 1.1.2.4 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -79,6 +84,8 @@
      private Connector connector;
      private SampleInvocationHandler invocationHandler;
   
  +   private boolean firstTime = true;
  +
   
      
      /**
  @@ -86,6 +93,17 @@
       */
      public void setUp() throws Exception
      {
  +      if (firstTime)
  +      {
  +         firstTime = false;
  +         Logger.getLogger("org.jboss.remoting").setLevel(Level.DEBUG);
  +         Logger.getLogger("org.jboss.test.remoting").setLevel(Level.DEBUG);
  +         String pattern = "[%d{ABSOLUTE}] [%t] %5p (%F:%L) - %m%n";
  +         PatternLayout layout = new PatternLayout(pattern);
  +         ConsoleAppender consoleAppender = new ConsoleAppender(layout);
  +         Logger.getRootLogger().addAppender(consoleAppender);  
  +      }
  +      
         String locatorURI = getTransport() + "://" + InetAddress.getLocalHost().getHostAddress() + ":" + port; 
         InvokerLocator serverLocator = new InvokerLocator(locatorURI);
         System.out.println("Starting remoting server with locator uri of: " + locatorURI);
  @@ -269,7 +287,7 @@
            client.invokeOneway(CALLBACK_TEST);
         }
         
  -      Thread.sleep(100);
  +      Thread.sleep(500);
         assertEquals(invocationCount, callbackHandler.callbackCounter);
         assertEquals(0, pool.size());
         usedPooled = (Long) field.get(clientInvoker);
  @@ -1147,6 +1165,7 @@
         field.setAccessible(true);
         Socket controlSocket = (Socket) field.get(clientInvoker);
         controlSocket.close();
  +      log.info("CLOSED CONTROL SOCKET");
         
         Thread.sleep(TEST_PING_FREQUENCY * 2);
         client.invoke(CALLBACK_TEST);
  @@ -1226,6 +1245,7 @@
         field.setAccessible(true);
         Socket clientSideControlSocket = (Socket) field.get(controlConnectionThread);
         clientSideControlSocket.close();
  +      log.info("CLOSED CONTROL SOCKET");
         
         Thread.sleep(TEST_PING_FREQUENCY * 2);
         client.invoke(CALLBACK_TEST);
  @@ -1243,6 +1263,90 @@
      }
      
      
  +   public void testNoControlConnectionRestart() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      Iterator it = invocationHandler.callbackHandlers.iterator();
  +      ServerInvokerCallbackHandler serverInvokerCallbackHandler = (ServerInvokerCallbackHandler) it.next();
  +      Client callbackClient = serverInvokerCallbackHandler.getCallbackClient();
  +      assertTrue(callbackClient.getInvoker() instanceof BisocketClientInvoker);
  +      MicroSocketClientInvoker clientInvoker = (MicroSocketClientInvoker) callbackClient.getInvoker();
  +      Field field = BisocketClientInvoker.class.getDeclaredField("controlSocket");
  +      field.setAccessible(true);
  +      Socket controlSocketBefore = (Socket) field.get(clientInvoker);
  +
  +      Thread.sleep(4 * TEST_PING_FREQUENCY);
  +      Socket controlSocketAfter = (Socket) field.get(clientInvoker);      
  +      assertEquals(controlSocketBefore, controlSocketAfter);
  +      log.info("control socket: " + controlSocketBefore);
  +
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
  +   public void testServerRestart() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(1, callbackHandler.callbackCounter);
  +      
  +      Connector oldConnector = connector;
  +      connector.stop();
  +      log.info("STOPPED CONNECTOR");
  +      setUp();
  +      log.info("RESTARTED CONNECTOR");
  +      assertTrue(!connector.equals(oldConnector));
  +      
  +      Thread.sleep(TEST_PING_FREQUENCY * 3);
  +      
  +      // It is beyond the scope of Remoting to fail over to a new server,
  +      // complete with registered callback handlers.
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
      public static void main(String[] args)
      {
         BisocketTestCase testCase = new BisocketTestCase();
  
  
  


From ron_sigal at yahoo.com  Fri Dec 29 01:46:32 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Fri, 29 Dec 2006 01:46:32 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket ...
Message-ID: <E1H0BVg-0004lD-OS@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/29 01:46:32

  Modified:    src/tests/org/jboss/test/remoting/transport/bisocket 
                        BisocketTestCase.java
  Log:
  JBREM-650:  Added test method for restarted Connector.
  
  Revision  Changes    Path
  1.4       +49 -2     JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- BisocketTestCase.java	29 Dec 2006 02:23:36 -0000	1.3
  +++ BisocketTestCase.java	29 Dec 2006 06:46:32 -0000	1.4
  @@ -60,7 +60,7 @@
   
   /** 
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    * <p>
    * Copyright Nov 25, 2006
    * </p>
  @@ -95,6 +95,7 @@
      {
         if (firstTime)
         {
  +         firstTime = false;
            Logger.getLogger("org.jboss.remoting").setLevel(Level.DEBUG);
            Logger.getLogger("org.jboss.test.remoting").setLevel(Level.DEBUG);
            String pattern = "[%d{ABSOLUTE}] [%t] %5p (%F:%L) - %m%n";
  @@ -286,7 +287,7 @@
            client.invokeOneway(CALLBACK_TEST);
         }
         
  -      Thread.sleep(100);
  +      Thread.sleep(500);
         assertEquals(invocationCount, callbackHandler.callbackCounter);
         assertEquals(0, pool.size());
         usedPooled = (Long) field.get(clientInvoker);
  @@ -1164,6 +1165,7 @@
         field.setAccessible(true);
         Socket controlSocket = (Socket) field.get(clientInvoker);
         controlSocket.close();
  +      log.info("CLOSED CONTROL SOCKET");
         
         Thread.sleep(TEST_PING_FREQUENCY * 2);
         client.invoke(CALLBACK_TEST);
  @@ -1243,6 +1245,7 @@
         field.setAccessible(true);
         Socket clientSideControlSocket = (Socket) field.get(controlConnectionThread);
         clientSideControlSocket.close();
  +      log.info("CLOSED CONTROL SOCKET");
         
         Thread.sleep(TEST_PING_FREQUENCY * 2);
         client.invoke(CALLBACK_TEST);
  @@ -1300,6 +1303,50 @@
      }
      
      
  +   public void testServerRestart() throws Throwable
  +   {
  +      log.info("entering " + getName());
  +      String host = InetAddress.getLocalHost().getHostName();
  +      String locatorURI = getTransport() + "://" + host + ":" + port; 
  +      InvokerLocator serverLocator = new InvokerLocator(locatorURI);
  +      log.info("Connecting to: " + serverLocator);
  +      HashMap config = new HashMap();
  +      config.put(InvokerLocator.FORCE_REMOTE, "true");
  +      config.put(Bisocket.IS_CALLBACK_SERVER, "true");
  +      config.put(Bisocket.PING_FREQUENCY, TEST_PING_FREQUENCY_STRING);
  +      addExtraClientConfig(config);
  +      Client client = new Client(serverLocator, config);
  +      client.connect();
  +      log.info("client is connected");
  +      assertTrue(client.getInvoker() instanceof BisocketClientInvoker);
  +      SimpleCallbackHandler callbackHandler = new SimpleCallbackHandler();
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(1, callbackHandler.callbackCounter);
  +      
  +      Connector oldConnector = connector;
  +      connector.stop();
  +      log.info("STOPPED CONNECTOR");
  +      setUp();
  +      log.info("RESTARTED CONNECTOR");
  +      assertTrue(!connector.equals(oldConnector));
  +      
  +      Thread.sleep(TEST_PING_FREQUENCY * 3);
  +      
  +      // It is beyond the scope of Remoting to fail over to a new server,
  +      // complete with registered callback handlers.
  +      client.addListener(callbackHandler, new HashMap());
  +      log.info("client added callback handler");
  +      
  +      client.invoke(CALLBACK_TEST);
  +      assertEquals(2, callbackHandler.callbackCounter);
  +
  +      client.removeListener(callbackHandler);
  +      client.disconnect();
  +   }
  +   
  +   
      public static void main(String[] args)
      {
         BisocketTestCase testCase = new BisocketTestCase();
  
  
  


From dfser7w89qr at Safe-mail.net  Fri Dec 29 09:24:53 2006
From: dfser7w89qr at Safe-mail.net (dfser7w89qr at Safe-mail.net)
Date: Fri, 29 Dec 2006 09:24:53 -0500
Subject: [jboss-cvs] =?utf-8?b?wo3CocKTw7rCgsKpwoLDp8KJw4bCgsOJwpPDhsKC?=
	=?utf-8?b?w6jCgsKrwoLDqMKCw4jCgsOMwoLDhcKXVsKCw5HCgsOJwpfCiMKCw4Q=?=
	=?utf-8?b?woLCrcKCw6rCgsOcwoLCucKCw7HCgsKpwoFI?=
Message-ID: 20061229223422.60108mail@mail.asertieuyiasjdsaiudasdnjasdnasudmajmsjdad.com

?}?????U???????????????B
???????????????????????????????c?????A?????????A?????????l?????????B
???i?????????????????????????L???????????c?B
???????????????????V?????????????????????H
?????????????????????B
?H???E?Q???????????????????B
?N???????Z?????????v?????????????A?????????????????????????????B
http://freeweb.lovelovesexywoman.tonderuyo.com/Scircle/






From msurtani at jboss.com  Fri Dec 29 09:27:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 09:27:52 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1H0Ii8-0004fS-2y@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 09:27:52

  Modified:    src/org/jboss/cache/marshall  Tag: Branch_JBossCache_1_4_0
                        JBCMethodCall.java
  Log:
  JBCACHE-917
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.4.2.2   +1 -0      JBossCache/src/org/jboss/cache/marshall/Attic/JBCMethodCall.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JBCMethodCall.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/Attic/JBCMethodCall.java,v
  retrieving revision 1.4.2.1
  retrieving revision 1.4.2.2
  diff -u -b -r1.4.2.1 -r1.4.2.2
  --- JBCMethodCall.java	14 Dec 2006 11:55:06 -0000	1.4.2.1
  +++ JBCMethodCall.java	29 Dec 2006 14:27:51 -0000	1.4.2.2
  @@ -21,6 +21,7 @@
   public class JBCMethodCall extends MethodCall
   {
      private int methodId;
  +   private static final long serialVersionUID = -4826713878871338199L;
   
      public JBCMethodCall()
      {
  
  
  


From msurtani at jboss.com  Fri Dec 29 09:40:11 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 09:40:11 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1H0Iu3-0004qo-Lv@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 09:40:11

  Modified:    src/org/jboss/cache  Tag: Branch_JBossCache_1_4_0
                        OptimisticTreeNode.java
  Log:
  added svuid
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.13.2.1  +3 -1      JBossCache/src/org/jboss/cache/OptimisticTreeNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticTreeNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/OptimisticTreeNode.java,v
  retrieving revision 1.13
  retrieving revision 1.13.2.1
  diff -u -b -r1.13 -r1.13.2.1
  --- OptimisticTreeNode.java	8 Apr 2006 18:34:42 -0000	1.13
  +++ OptimisticTreeNode.java	29 Dec 2006 14:40:11 -0000	1.13.2.1
  @@ -8,8 +8,8 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.optimistic.DefaultDataVersion;
   import org.jboss.cache.optimistic.DataVersion;
  +import org.jboss.cache.optimistic.DefaultDataVersion;
   
   import java.util.Map;
   
  @@ -25,6 +25,8 @@
   
       private static Log log = LogFactory.getLog(OptimisticTreeNode.class);
   
  +    private static final long serialVersionUID = 7000622696587912654L;
  +
       /**
        * Although this object has a reference to the TreeCache, the optimistic
        * node is actually disconnected from the TreeCache itself.
  
  
  


From msurtani at jboss.com  Fri Dec 29 09:46:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 09:46:59 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1H0J0d-0004yT-UT@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 09:46:59

  Modified:    src/org/jboss/cache/optimistic  FqnComparator.java
  Log:
  Removed serializable
  
  Revision  Changes    Path
  1.6       +66 -58    JBossCache/src/org/jboss/cache/optimistic/FqnComparator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FqnComparator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/FqnComparator.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- FqnComparator.java	8 Dec 2006 19:03:56 -0000	1.5
  +++ FqnComparator.java	29 Dec 2006 14:46:59 -0000	1.6
  @@ -7,52 +7,55 @@
   package org.jboss.cache.optimistic;
   
   import org.jboss.cache.Fqn;
  -import java.io.Serializable;
  +
   import java.util.Comparator;
   
   /**
    * Compares the order of two FQN.
    * Sorts by name, then by depth, e.g. 
  - <pre>
  - aaa/bbb
  - xxx
  - xxx/ccc 
  - </pre>
  + * <pre>
  + * aaa/bbb
  + * xxx
  + * xxx/ccc
  + * </pre>
    *
    * @author Manik Surtani (<a href="mailto:manik at jboss.org">manik at jboss.org</a>)
    * @author Steve Woodcock (<a href="mailto:stevew at jofti.com">stevew at jofti.com</a>)
    */
  -public class FqnComparator implements Comparator<Fqn>, Serializable {
  -
  -   static final long serialVersionUID = -102183636437493134L;
  -
  +public class FqnComparator implements Comparator<Fqn>
  +{
      public static final FqnComparator INSTANCE = new FqnComparator();
   
      /**
       * Sorts by name, then depth.
       */
  -   public FqnComparator() {
  +   public FqnComparator()
  +   {
      }
   
      /**
       * Returns -1 if the first comes before; 0 if they are the same; 1 if the
       * second Fqn comes before.  <code>null</code> always comes first.
       */
  -	public int compare(Fqn fqn1, Fqn fqn2) {
  +   public int compare(Fqn fqn1, Fqn fqn2)
  +   {
   	   int s1 = fqn1.size();
   	   int s2 = fqn2.size();
   
  -	   if (s1 == 0) {
  +      if (s1 == 0)
  +      {
   	      return (s2 == 0) ? 0 : -1;
   	   }
   
  -	   if (s2 == 0) {
  +      if (s2 == 0)
  +      {
   	      return 1;
   	   }
   
   	   int size = Math.min(s1, s2);
   
  -	   for (int i = 0; i < size; i++) {
  +      for (int i = 0; i < size; i++)
  +      {
   	      Object e1 = fqn1.get(i);
   	      Object e2 = fqn2.get(i);
   	      if (e1 == e2)
  @@ -61,7 +64,8 @@
   	         return 0;
   	      if (e2 == null)
   	         return 1;
  -	      if (!e1.equals(e2)) {
  +         if (!e1.equals(e2))
  +         {
   	         int c = compareElements(e1, e2);
   	         if (c != 0)
   	            return c;
  @@ -77,10 +81,14 @@
      * returns e1.compareTo(e2).
      * Otherwise, returns e1.toString().compareTo(e2.toString()).
      */
  -  protected int compareElements(Object e1, Object e2) {
  -     if (e1.getClass() == e2.getClass() && e1 instanceof Comparable) {
  -        return ((Comparable)e1).compareTo(e2);
  -     } else {
  +   protected int compareElements(Object e1, Object e2)
  +   {
  +      if (e1.getClass() == e2.getClass() && e1 instanceof Comparable)
  +      {
  +         return ((Comparable) e1).compareTo(e2);
  +      }
  +      else
  +      {
           return e1.toString().compareTo(e2.toString());
        }
     }
  
  
  


From msurtani at jboss.com  Fri Dec 29 09:47:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 09:47:00 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache  ...
Message-ID: <E1H0J0e-0004ya-2w@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 09:47:00

  Modified:    src/org/jboss/cache  NodeImpl.java
  Log:
  Removed serializable
  
  Revision  Changes    Path
  1.31      +1 -3      JBossCache/src/org/jboss/cache/NodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeImpl.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- NodeImpl.java	22 Dec 2006 03:53:30 -0000	1.30
  +++ NodeImpl.java	29 Dec 2006 14:47:00 -0000	1.31
  @@ -31,11 +31,9 @@
   /**
    * Basic data node class.
    */
  -public class NodeImpl extends AbstractNode implements Node, Serializable
  +public class NodeImpl extends AbstractNode implements Node
   {
   
  -   private static final long serialVersionUID = -8200950905894940931L;
  -
      /**
       * Default output indent for printing.
       */
  
  
  


From msurtani at jboss.com  Fri Dec 29 10:11:16 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 10:11:16 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1H0JO8-0005Xs-Kb@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 10:11:16

  Modified:    src/org/jboss/cache/optimistic  DataVersion.java
  Log:
  Added javadoc
  
  Revision  Changes    Path
  1.3       +8 -4      JBossCache/src/org/jboss/cache/optimistic/DataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DataVersion.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- DataVersion.java	8 Apr 2006 20:30:08 -0000	1.2
  +++ DataVersion.java	29 Dec 2006 15:11:16 -0000	1.3
  @@ -12,6 +12,10 @@
    * When versioning data nodes in optimistic locking, a DataVersion is assigned
    * to each node.  Versions need to implement the {@link #newerThan} method so
    * they can be compared during the validation phase upon commit.
  + * <p/>
  + * It is recommended that implementations implement {@link java.io.Externalizable} and make use
  + * of a good marshalling/unmarshalling mechanism for the sake of efficiency, as these objects are
  + * frequently serialized to be replicated across the wire.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  
  
  


From msurtani at jboss.com  Fri Dec 29 10:18:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 10:18:20 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1H0JUy-0005fW-7R@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 10:18:20

  Modified:    src/org/jboss/cache/marshall  TreeCacheMarshaller200.java
  Log:
  Enhanced marshalling for default data versions
  
  Revision  Changes    Path
  1.11      +39 -31    JBossCache/src/org/jboss/cache/marshall/TreeCacheMarshaller200.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheMarshaller200.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/TreeCacheMarshaller200.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- TreeCacheMarshaller200.java	16 Nov 2006 17:11:46 -0000	1.10
  +++ TreeCacheMarshaller200.java	29 Dec 2006 15:18:20 -0000	1.11
  @@ -12,6 +12,7 @@
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
  +import org.jboss.cache.optimistic.DefaultDataVersion;
   import org.jboss.cache.rpc.RpcTreeCache;
   import org.jgroups.Address;
   import org.jgroups.stack.IpAddress;
  @@ -23,7 +24,6 @@
   import java.util.ArrayList;
   import java.util.Collections;
   import java.util.HashMap;
  -import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  @@ -49,6 +49,7 @@
      protected static final int MAGICNUMBER_BOOLEAN = 8;
      protected static final int MAGICNUMBER_STRING = 9;
      protected static final int MAGICNUMBER_MAP = 10;
  +   protected static final int MAGICNUMBER_DEFAULT_DATA_VERSION = 11;
      protected static final int MAGICNUMBER_NULL = 99;
      protected static final int MAGICNUMBER_SERIALIZABLE = 100;
      protected static final int MAGICNUMBER_REF = 101;
  @@ -69,7 +70,7 @@
      public void objectToStream(Object o, ObjectOutputStream out) throws Exception
      {
         if (log.isTraceEnabled()) log.trace("Marshalling object " + o);
  -      Map refMap = new HashMap();
  +      Map<Object, Integer> refMap = new HashMap<Object, Integer>();
   
         if (useRegionBasedMarshalling)
         {
  @@ -85,7 +86,7 @@
      public Object objectFromStream(ObjectInputStream in) throws Exception
      {
         Object retValue;
  -      Map refMap = new HashMap();
  +      Map<Integer, Object> refMap = new HashMap<Integer, Object>();
   
         if (useRegionBasedMarshalling)
         {
  @@ -160,7 +161,7 @@
   
      // --------- Marshalling methods
   
  -   private void marshallObject(Object o, ObjectOutputStream out, Map refMap) throws Exception
  +   private void marshallObject(Object o, ObjectOutputStream out, Map<Object, Integer> refMap) throws Exception
      {
         if (o == null)
         {
  @@ -205,6 +206,11 @@
            out.writeByte(TreeCacheMarshaller200.MAGICNUMBER_IPADDRESS);
            marshallIpAddress((IpAddress) o, out);
         }
  +      else if (o instanceof DefaultDataVersion)
  +      {
  +         out.writeByte(TreeCacheMarshaller200.MAGICNUMBER_DEFAULT_DATA_VERSION);
  +         out.writeLong(((DefaultDataVersion) o).getRawVersion());
  +      }
         else if (o instanceof List)
         {
            out.writeByte(TreeCacheMarshaller200.MAGICNUMBER_LIST);
  @@ -254,10 +260,10 @@
         }
      }
   
  -   private int createReference(Object o, Map refMap)
  +   private int createReference(Object o, Map<Object, Integer> refMap)
      {
         int reference = refMap.size();
  -      refMap.put(o, Integer.valueOf(reference));
  +      refMap.put(o, reference);
         return reference;
      }
   
  @@ -267,7 +273,7 @@
         out.writeObject(s);
      }
   
  -   private void marshallMethodCall(MethodCall methodCall, ObjectOutputStream out, Map refMap) throws Exception
  +   private void marshallMethodCall(MethodCall methodCall, ObjectOutputStream out, Map<Object, Integer> refMap) throws Exception
      {
         out.writeShort(methodCall.getMethodId());
         Object[] args = methodCall.getArgs();
  @@ -280,14 +286,14 @@
         }
      }
   
  -   private void marshallGlobalTransaction(GlobalTransaction globalTransaction, ObjectOutputStream out, Map refMap) throws Exception
  +   private void marshallGlobalTransaction(GlobalTransaction globalTransaction, ObjectOutputStream out, Map<Object, Integer> refMap) throws Exception
      {
         out.writeLong(globalTransaction.getId());
         marshallObject(globalTransaction.getAddress(), out, refMap);
      }
   
   
  -   private void marshallFqn(Fqn fqn, ObjectOutputStream out, Map refMap) throws Exception
  +   private void marshallFqn(Fqn fqn, ObjectOutputStream out, Map<Object, Integer> refMap) throws Exception
      {
         boolean isRoot = fqn.isRoot();
         out.writeBoolean(isRoot);
  @@ -306,17 +312,16 @@
         ipAddress.writeExternal(out);
      }
   
  -   private void marshallList(List l, ObjectOutputStream out, Map refMap) throws Exception
  +   private void marshallList(List l, ObjectOutputStream out, Map<Object, Integer> refMap) throws Exception
      {
         out.writeInt(l.size());
  -      Iterator i = l.iterator();
  -      while (i.hasNext())
  +      for (Object o : l)
         {
  -         marshallObject(i.next(), out, refMap);
  +         marshallObject(o, out, refMap);
         }
      }
   
  -   private void marshallMap(Map map, ObjectOutputStream out, Map refMap) throws Exception
  +   private void marshallMap(Map map, ObjectOutputStream out, Map<Object, Integer> refMap) throws Exception
      {
         int mapSize = map.size();
         out.writeInt(mapSize);
  @@ -331,7 +336,7 @@
   
      // --------- Unmarshalling methods
   
  -   private Object unmarshallObject(ObjectInputStream in, ClassLoader loader, Map refMap) throws Exception
  +   private Object unmarshallObject(ObjectInputStream in, ClassLoader loader, Map<Integer, Object> refMap) throws Exception
      {
         if (loader == null)
         {
  @@ -353,7 +358,7 @@
         }
      }
   
  -   private Object unmarshallObject(ObjectInputStream in, Map refMap) throws Exception
  +   private Object unmarshallObject(ObjectInputStream in, Map<Integer, Object> refMap) throws Exception
      {
         byte magicNumber = in.readByte();
         Integer reference;
  @@ -363,14 +368,14 @@
            case TreeCacheMarshaller200.MAGICNUMBER_NULL:
               return null;
            case TreeCacheMarshaller200.MAGICNUMBER_REF:
  -            reference = Integer.valueOf(in.readShort());
  +            reference = (int) in.readShort();
               if (!refMap.containsKey(reference))
               {
                  throw new IOException("Unable to locate object reference " + reference + " in byte stream!");
               }
               return refMap.get(reference);
            case TreeCacheMarshaller200.MAGICNUMBER_SERIALIZABLE:
  -            reference = Integer.valueOf(in.readShort());
  +            reference = (int) in.readShort();
               retVal = in.readObject();
               refMap.put(reference, retVal);
               return retVal;
  @@ -378,29 +383,32 @@
               retVal = unmarshallMethodCall(in, refMap);
               return retVal;
            case TreeCacheMarshaller200.MAGICNUMBER_FQN:
  -            reference = Integer.valueOf(in.readShort());
  +            reference = (int) in.readShort();
               retVal = unmarshallFqn(in, refMap);
               refMap.put(reference, retVal);
               return retVal;
            case TreeCacheMarshaller200.MAGICNUMBER_GTX:
  -            reference = Integer.valueOf(in.readShort());
  +            reference = (int) in.readShort();
               retVal = unmarshallGlobalTransaction(in, refMap);
               refMap.put(reference, retVal);
               return retVal;
            case TreeCacheMarshaller200.MAGICNUMBER_IPADDRESS:
               retVal = unmarshallIpAddress(in);
               return retVal;
  +         case TreeCacheMarshaller200.MAGICNUMBER_DEFAULT_DATA_VERSION:
  +            retVal = new DefaultDataVersion(in.readLong());
  +            return retVal;
            case TreeCacheMarshaller200.MAGICNUMBER_LIST:
               return unmarshallList(in, refMap);
            case TreeCacheMarshaller200.MAGICNUMBER_BOOLEAN:
               return in.readBoolean() ? Boolean.TRUE : Boolean.FALSE;
            case TreeCacheMarshaller200.MAGICNUMBER_INTEGER:
  -            return Integer.valueOf(in.readInt());
  +            return in.readInt();
            case TreeCacheMarshaller200.MAGICNUMBER_LONG:
  -            retVal = Long.valueOf(in.readLong());
  +            retVal = in.readLong();
               return retVal;
            case TreeCacheMarshaller200.MAGICNUMBER_STRING:
  -            reference = Integer.valueOf(in.readShort());
  +            reference = (int) in.readShort();
               retVal = unmarshallString(in);
               refMap.put(reference, retVal);
               return retVal;
  @@ -421,7 +429,7 @@
         return (String) in.readObject();
      }
   
  -   private MethodCall unmarshallMethodCall(ObjectInputStream in, Map refMap) throws Exception
  +   private MethodCall unmarshallMethodCall(ObjectInputStream in, Map<Integer, Object> refMap) throws Exception
      {
         short methodId = in.readShort();
         byte numArgs = in.readByte();
  @@ -439,7 +447,7 @@
         return MethodCallFactory.create(MethodDeclarations.lookupMethod(methodId), args);
      }
   
  -   private GlobalTransaction unmarshallGlobalTransaction(ObjectInputStream in, Map refMap) throws Exception
  +   private GlobalTransaction unmarshallGlobalTransaction(ObjectInputStream in, Map<Integer, Object> refMap) throws Exception
      {
         GlobalTransaction gtx = new GlobalTransaction();
         long id = in.readLong();
  @@ -449,7 +457,7 @@
         return gtx;
      }
   
  -   private Fqn unmarshallFqn(ObjectInputStream in, Map refMap) throws Exception
  +   private Fqn unmarshallFqn(ObjectInputStream in, Map<Integer, Object> refMap) throws Exception
      {
   
         boolean isRoot = in.readBoolean();
  @@ -457,7 +465,7 @@
         if (!isRoot)
         {
            int numElements = in.readShort();
  -         List elements = new ArrayList(numElements);
  +         List<Object> elements = new ArrayList<Object>(numElements);
            for (int i = 0; i < numElements; i++)
            {
               elements.add(unmarshallObject(in, refMap));
  @@ -478,10 +486,10 @@
         return ipAddress;
      }
   
  -   private List unmarshallList(ObjectInputStream in, Map refMap) throws Exception
  +   private List unmarshallList(ObjectInputStream in, Map<Integer, Object> refMap) throws Exception
      {
         int listSize = in.readInt();
  -      List list = new ArrayList(listSize);
  +      List<Object> list = new ArrayList<Object>(listSize);
         for (int i = 0; i < listSize; i++)
         {
            list.add(unmarshallObject(in, refMap));
  @@ -489,11 +497,11 @@
         return list;
      }
   
  -   private Map unmarshallMap(ObjectInputStream in, Map refMap) throws Exception
  +   private Map unmarshallMap(ObjectInputStream in, Map<Integer, Object> refMap) throws Exception
      {
         int mapSize = in.readInt();
         if (mapSize == 0) return Collections.emptyMap();
  -      Map map = new HashMap(mapSize);
  +      Map<Object, Object> map = new HashMap<Object, Object>(mapSize);
         for (int i = 0; i < mapSize; i++)
         {
            map.put(unmarshallObject(in, refMap), unmarshallObject(in, refMap));
  
  
  


From msurtani at jboss.com  Fri Dec 29 10:18:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Fri, 29 Dec 2006 10:18:20 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1H0JUy-0005fd-AZ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/29 10:18:20

  Modified:    src/org/jboss/cache/optimistic  DefaultDataVersion.java
  Log:
  Enhanced marshalling for default data versions
  
  Revision  Changes    Path
  1.7       +1 -16     JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultDataVersion.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/DefaultDataVersion.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- DefaultDataVersion.java	12 Dec 2006 14:51:44 -0000	1.6
  +++ DefaultDataVersion.java	29 Dec 2006 15:18:20 -0000	1.7
  @@ -6,11 +6,6 @@
    */
   package org.jboss.cache.optimistic;
   
  -import java.io.Externalizable;
  -import java.io.IOException;
  -import java.io.ObjectInput;
  -import java.io.ObjectOutput;
  -
   /**
    * The default implementation of a DataVersion, uses a <code>long</code> to
    * compare versions.
  @@ -22,7 +17,7 @@
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  -public class DefaultDataVersion implements DataVersion, Externalizable
  +public class DefaultDataVersion implements DataVersion
   {
      private static final long serialVersionUID = -6896315742831861046L;
      /**
  @@ -107,14 +102,4 @@
      {
         return version;
      }
  -
  -   public void writeExternal(ObjectOutput objectOutput) throws IOException
  -   {
  -      objectOutput.writeLong(version);
  -   }
  -
  -   public void readExternal(ObjectInput objectInput) throws IOException, ClassNotFoundException
  -   {
  -      version = objectInput.readLong();
  -   }
   }
  
  
  


From jboss-cvs-commits at lists.jboss.org  Fri Dec 29 11:48:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 29 Dec 2006 11:48:24 -0500
Subject: [jboss-cvs] JBossAS SVN: r59244 -
	branches/JBoss_4_0_2_CP/testsuite/src/main/org/jboss/test/util/test
Message-ID: <E1H0Ku8-0007FZ-4R@committer01.frg.pub.inap.atl.jboss.com>

Author: jaroslaw.kijanowski
Date: 2006-12-29 11:48:23 -0500 (Fri, 29 Dec 2006)
New Revision: 59244

Modified:
   branches/JBoss_4_0_2_CP/testsuite/src/main/org/jboss/test/util/test/PropertyEditorsUnitTestCase.java
Log:
applied ASPATCH-89

Modified: branches/JBoss_4_0_2_CP/testsuite/src/main/org/jboss/test/util/test/PropertyEditorsUnitTestCase.java
===================================================================
--- branches/JBoss_4_0_2_CP/testsuite/src/main/org/jboss/test/util/test/PropertyEditorsUnitTestCase.java	2006-12-28 23:35:15 UTC (rev 59243)
+++ branches/JBoss_4_0_2_CP/testsuite/src/main/org/jboss/test/util/test/PropertyEditorsUnitTestCase.java	2006-12-29 16:48:23 UTC (rev 59244)
@@ -191,8 +191,9 @@
       // The expected instance for each inputData value
       calendar.set(2005, 0, 4, 0, 0, 0);
       calendar.set(Calendar.MILLISECOND, 0);
+      //calendar.setTimeZone(TimeZone.getTimeZone("PST"));
+      Date date1 = calendar.getTime();
       calendar.setTimeZone(TimeZone.getTimeZone("PST"));
-      Date date1 = calendar.getTime();
       calendar.set(2005, 0, 4, 23, 38, 21);
       Date date2 = calendar.getTime();
       calendar.set(2005, 0, 4, 23, 38, 48);



From jboss-cvs-commits at lists.jboss.org  Fri Dec 29 12:08:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 29 Dec 2006 12:08:22 -0500
Subject: [jboss-cvs] JBossAS SVN: r59245 -
	projects/security/security-jboss-sx/trunk
Message-ID: <E1H0LDS-0007jt-3p@committer01.frg.pub.inap.atl.jboss.com>

Author: anil.saldhana at jboss.com
Date: 2006-12-29 12:08:21 -0500 (Fri, 29 Dec 2006)
New Revision: 59245

Modified:
   projects/security/security-jboss-sx/trunk/pom.xml
Log:
renable tests, add the test plugin with ignore test failures

Modified: projects/security/security-jboss-sx/trunk/pom.xml
===================================================================
--- projects/security/security-jboss-sx/trunk/pom.xml	2006-12-29 16:48:23 UTC (rev 59244)
+++ projects/security/security-jboss-sx/trunk/pom.xml	2006-12-29 17:08:21 UTC (rev 59245)
@@ -64,19 +64,15 @@
        </pluginRepositories>
        <build>
            <sourceDirectory>src/main</sourceDirectory>
-      <!--
            <testSourceDirectory>src/tests</testSourceDirectory>
            <testOutputDirectory>target/test-classes</testOutputDirectory>
-       -->
            <finalName>${artifactId}</finalName>
            <outputDirectory>output/classes</outputDirectory> 
-       <!--
            <testResources>
              <testResource>
                <directory>src/tests/org/jboss/test</directory>
              </testResource>
            </testResources>
-       -->
            <plugins>
            <!-- define how we want compilation to take place here, we accept most of the defaults but say that we want the optimization flag set, and define the source and target to be 1.4, these setting will be inherited by child projects -->
               <plugin>
@@ -177,6 +173,20 @@
                     </archive>
                  </configuration>
               </plugin>  
+
+             <plugin>
+                 <artifactId>maven-surefire-plugin</artifactId>
+                 <configuration>
+                   <printSummary>true</printSummary>
+                   <disableXmlReport>false</disableXmlReport>
+                   <testFailureIgnore>true</testFailureIgnore>
+                   <includes>
+                     <include>**/**TestCase.java</include>
+                   </includes>
+                   <forkMode>pertest</forkMode>
+                 </configuration>
+             </plugin>
+
            
               <plugin>
                   <artifactId>maven-antrun-plugin</artifactId>



From gsa4df564ersa at fastermail.com  Fri Dec 29 13:43:45 2006
From: gsa4df564ersa at fastermail.com (gsa4df564ersa at fastermail.com)
Date: Fri, 29 Dec 2006 13:43:45 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCqMKCw5DCgsKzwoLCtcKCw5TCgsOowoLDhcKC?=
	=?utf-8?b?wrc=?=
Message-ID: 20061230031229.62270mail@mail.bhusdiuykjdhfisaudyfsakdjfhsndkfsdkfsmj.com

?????C???????H???????????B
?????????????Y???????????????H
?O???????????????b???????????????????????A?f???????????M???????O?????????????????????????[???????????B
???????????????????????????????H
?F?X?b?????????????B
?????????????????????????B

http://freeweb-freewoman.tv.ksjer.com/fsex/




From norman.richards at jboss.com  Fri Dec 29 15:18:07 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Fri, 29 Dec 2006 15:18:07 -0500
Subject: [jboss-cvs] jboss-seam/examples/messages/resources  ...
Message-ID: <E1H0OB5-0002b3-Ad@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/29 15:18:07

  Modified:    examples/messages/resources  import.sql
  Log:
  date format appears to be incompatible with Java 6 (jdbc 4.0 issue?)
  
  Revision  Changes    Path
  1.2       +2 -2      jboss-seam/examples/messages/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/messages/resources/import.sql,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- import.sql	8 Jan 2006 01:24:17 -0000	1.1
  +++ import.sql	29 Dec 2006 20:18:07 -0000	1.2
  @@ -1,2 +1,2 @@
  -insert into Message (title, text, read, datetime) values ('Hello World', 'This is an example of a message.', 0, '2006-1-1 11:12')
  -insert into Message (title, text, read, datetime) values ('Greetings Earthling', 'This is another example of a message.', 0, '2006-2-4 03:04')
  \ No newline at end of file
  +insert into Message (title, text, read, datetime) values ('Hello World', 'This is an example of a message.', 0, '2006-01-01 11:12:00')
  +insert into Message (title, text, read, datetime) values ('Greetings Earthling', 'This is another example of a message.', 0, '2006-02-04 03:04:00')
  
  
  


From gdsadr4564dfsa at doramail.com  Fri Dec 29 15:25:16 2006
From: gdsadr4564dfsa at doramail.com (gdsadr4564dfsa at doramail.com)
Date: Fri, 29 Dec 2006 15:25:16 -0500
Subject: [jboss-cvs] =?utf-8?b?woPCgcKBW8KDwovCgsONwozCqcKCw4TCksK4woI=?=
	=?utf-8?b?wq/CgsOcwoLCtcKCwr3CgsOFwoLCtcKCw6XCgsKkwoLCqcKBSA==?=
Message-ID: 20061230052615.34366mail@mail.qwepoiusajdandaufuyertermjjnvcxsdfsdfn.com

???????????b?????????????????B?????S?????R???????B

???O?u???????v???????[???????????????v???????????A???????????????????????H
?????????????????????????????H
???????????????????????????A???????????????A?????????????????[???????????????????????B

???????????O?????????[?????????????????m?F?????????B??
http://gogo-completevip.net.tonderuyo.com/merux/

???????A?????????????[???????a?????????????????B

?u?O?????[?????????????????A???????????????H
?@?????????v???t?B?[?????A?h???X?????^???????????????????A?????????????????H
?@?????????????????????v

?????????v???t?B?[?????????????????m?F??????????
http://gogo-completevip.net.tonderuyo.com/merux/














?????@?@gfds87trgf4sd at Safe-mail.net






From jboss-cvs-commits at lists.jboss.org  Fri Dec 29 18:52:30 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 29 Dec 2006 18:52:30 -0500
Subject: [jboss-cvs] JBossAS SVN: r59246 - in
	projects/aop/trunk/aop/src/main/org/jboss/aop: advice
	advice/annotation instrument
Message-ID: <E1H0RWY-0006KR-Tx@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-29 18:52:03 -0500 (Fri, 29 Dec 2006)
New Revision: 59246

Modified:
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/ParameterAnnotationRule.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java
   projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java
Log:
[JBAOP-326] Target parameter support implemented

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/AdviceMethodProperties.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -46,15 +46,20 @@
    
    public static final CtClass[] EMPTY_PARAMETERS = {};
    
+   public static enum Context {STATIC, TARGET_AVAILABLE, CALLER_AVAILABLE,
+      TARGET_CALLER_AVAILABLE}
+   
    //find properties
    private Class aspectClass;
    private String adviceName;
    private Class infoType;
    private Class invocationType;
+   private Class target;
    private Class joinpointReturnType;
    private Class[] joinpointParameters;
    private Class[] joinpointExceptions;
-
+   private Context context;
+   
    //found properties
    private Method adviceMethod;
    private int[] args;
@@ -66,7 +71,9 @@
          Class invocationType,
          Class joinpointReturnType,
          Class[] joinpointParameters,
-         Class[] joinpointExceptions)
+         Class[] joinpointExceptions,
+         Class target,
+         Context context)
    {
       this.aspectClass = aspectClass;
       this.adviceName = adviceName;
@@ -75,6 +82,8 @@
       this.joinpointReturnType = joinpointReturnType;
       this.joinpointParameters = joinpointParameters;
       this.joinpointExceptions = joinpointExceptions;
+      this.target = target;
+      this.context = context;
    }
 
    public void setFoundProperties(Method adviceMethod, int[] args)
@@ -139,4 +148,13 @@
       return args;
    }
    
-}
+   public Class getTargetType()
+   {
+      return this.target;
+   }
+   
+   public Context getContext()
+   {
+      return this.context;
+   }
+}
\ No newline at end of file

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceInfo.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -246,25 +246,29 @@
     * contained in <code>properties</code>.
     * 
     * @param properties        contains information about the queried method
-    * @param mutuallyExclusive a list of mutually exclusive rules
     * @param returnType        the expected return type
     * @return                  <code>true</code> only if this advice is valid
     */
    public abstract boolean validate(AdviceMethodProperties properties,
-         int[][] mutuallyExclusive, ReturnType returnType);
+         ReturnType returnType);
 
    /**
     * Returns the distance in hierarchy between the annotated parameter identified by
     * <code>annotationIndex</code>, and the expected type of this parameter.
     * 
     * @param annotationIndex  identifies a parameter annotation rule
+    * @param isContextRule    is <code>true</code>, <code>annotationIndex</code>
+    *                         refers to a context rule, instead of a factory rule
+    *                         (context rules include target, caller, arg, etc;
+    *                         factory rule are dependent on the advice factory,
+    *                         and include join point, throwable, return and others)
     * @param properties       contains information about the queried advice method
     * @return                 the assignability degree if there is a parameter with the
     *                         annotation identified by <code>typeIndex</code>;
     *                         {@link AdviceMethodFactory#NOT_ASSIGNABLE_DEGREE} otherwise.
     */
    public abstract short getAssignabilityDegree(int annotationIndex,
-         AdviceMethodProperties properties);
+         boolean isContextRule, AdviceMethodProperties properties);
    
    /**
     * Assign information of this advice to <code>properties</code>.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AdviceMethodFactory.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -36,7 +36,7 @@
 import org.jboss.aop.util.ReflectUtils;
 
 /**
- * Utility class to figure out which advice method to use for a given joinpoint
+ * Utility class to select an advice method for a given joinpoint.
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
  * @author Flavia Rainone
@@ -53,23 +53,20 @@
     * Factory that selects advice methods for <i>before</i> interception.
     */
    public static final AdviceMethodFactory BEFORE = new AdviceMethodFactory (null,
-         new ParameterAnnotationRule[]{ParameterAnnotationRule.JOIN_POINT,
-         ParameterAnnotationRule.ARGS, ParameterAnnotationRule.ARG},
-         new int[][]{{1,2}}, ReturnType.VOID);
+         new ParameterAnnotationRule[]{ParameterAnnotationRule.JOIN_POINT},
+         ReturnType.VOID);
    /**
     * Factory that selects advice methods for <i>after</i> interception.
     */
    public static final AdviceMethodFactory AFTER = new AdviceMethodFactory (null,
          new ParameterAnnotationRule[]{ParameterAnnotationRule.JOIN_POINT,
-         ParameterAnnotationRule.RETURN, ParameterAnnotationRule.ARGS,
-         ParameterAnnotationRule.ARG}, new int[][]{{2, 3}}, ReturnType.ANY);
+         ParameterAnnotationRule.RETURN}, ReturnType.ANY);
    /**
     * Factory that selects advice methods for <i>throwing</i> interception.
     */
    public static final AdviceMethodFactory THROWING = new AdviceMethodFactory (null,
          new ParameterAnnotationRule[]{ParameterAnnotationRule.JOIN_POINT,
-         ParameterAnnotationRule.THROWABLE, ParameterAnnotationRule.ARGS,
-         ParameterAnnotationRule.ARG}, new int[][]{{2, 3}}, ReturnType.VOID);
+         ParameterAnnotationRule.THROWABLE}, ReturnType.VOID);
    /**
     * Factory that selects advice methods for <i>aroung</i> interception.
     */
@@ -131,7 +128,7 @@
                return new AdviceInfo(method, 500)
                {
                   public boolean validate(AdviceMethodProperties properties,
-                        int[][] mutuallyExclusive, ReturnType adviceReturn)
+                        ReturnType adviceReturn)
                   {
                      if(parameterTypes[0].isAssignableFrom(properties.getInvocationType()))
                      {
@@ -148,7 +145,7 @@
                   }
 
                   public short getAssignabilityDegree(int typeIndex,
-                        AdviceMethodProperties properties)
+                        boolean isContextRule, AdviceMethodProperties properties)
                   {
                      return getAssignabilityDegree(parameterTypes[0], properties.getInvocationType());
                   }
@@ -161,15 +158,36 @@
                };
             }
          },         
-         new ParameterAnnotationRule[]{ParameterAnnotationRule.INVOCATION,
-         ParameterAnnotationRule.ARGS, ParameterAnnotationRule.ARG},
-         new int[][]{{1, 2}}, ReturnType.NOT_VOID);
+         new ParameterAnnotationRule[]{ParameterAnnotationRule.INVOCATION},
+         ReturnType.NOT_VOID);
          
 
-   static StringBuffer adviceMatchingMessage;
    static final short NOT_ASSIGNABLE_DEGREE = Short.MAX_VALUE;
    static final short MAX_DEGREE = NOT_ASSIGNABLE_DEGREE - 1;
+   static final ParameterAnnotationRule[] FULLY_STATIC =
+      new ParameterAnnotationRule[] {ParameterAnnotationRule.ARGS,
+      ParameterAnnotationRule.ARG};
+   static final int[][] FS_INCOMPATIBILITY = new int[][]{{0, 1}};
    
+   static final ParameterAnnotationRule[] CALLER_AVAILABLE =
+      new ParameterAnnotationRule[] {ParameterAnnotationRule.CALLER,
+      ParameterAnnotationRule.ARGS, ParameterAnnotationRule.ARG};
+   static final int[][] CA_INCOMPATIBILITY = new int[][]{{1, 2}};
+   
+   static final ParameterAnnotationRule[] TARGET_AVAILABLE =
+      new ParameterAnnotationRule[] {ParameterAnnotationRule.TARGET,
+      ParameterAnnotationRule.ARGS, ParameterAnnotationRule.ARG};
+   static final int[][] TA_INCOMPATIBILITY = CA_INCOMPATIBILITY;
+   
+   static final ParameterAnnotationRule[] TARGET_CALLER_AVAILABLE =
+      new ParameterAnnotationRule[] {ParameterAnnotationRule.TARGET,
+      ParameterAnnotationRule.CALLER,
+      ParameterAnnotationRule.ARGS, ParameterAnnotationRule.ARG};
+   static final int[][] TCA_INCOMPATIBILITY = new int[][]{{2, 3}};
+   
+   /** Stores advice matching failure messages on verbose mode. */
+   static StringBuffer adviceMatchingMessage;
+   
    /**
     * Method that returns log information about the last matching process executed.
     * Should be called only if <code>Aspect.verbose</code> is <code>true</code>.
@@ -185,9 +203,8 @@
    private ReturnType returnType;
    private AdviceSignatureRule adviceSignatureRule;
    private ParameterAnnotationRule[] rules;
-   private int[][] mutuallyExclusive;
-
    
+   
    /**
     * Creates an advice method factory.
     * 
@@ -200,12 +217,12 @@
     *                            a value to overwrite the join point execution result.
     */
    private AdviceMethodFactory(AdviceSignatureRule adviceSignatureRule,
-         ParameterAnnotationRule[] rules, int[][] mutuallyExclusive,
+         ParameterAnnotationRule[] rules,/*, int[][] mutuallyExclusive,*/
          ReturnType returnType)
    {
       this.adviceSignatureRule = adviceSignatureRule;
       this.rules = rules;
-      this.mutuallyExclusive = mutuallyExclusive;
+      //this.mutuallyExclusive = mutuallyExclusive;
       this.returnType = returnType;
    }
    
@@ -238,6 +255,32 @@
          return null;
       }
       
+      ParameterAnnotationRule[] contextRules = null;
+      int[][] mutuallyExclusive = null;
+      switch(properties.getContext())
+      {
+         case STATIC:
+            contextRules = FULLY_STATIC;
+            mutuallyExclusive = FS_INCOMPATIBILITY;
+            break;
+         case TARGET_AVAILABLE:
+            contextRules = TARGET_AVAILABLE;
+            mutuallyExclusive = TA_INCOMPATIBILITY;
+            break;
+         case CALLER_AVAILABLE:
+            contextRules = CALLER_AVAILABLE;
+            mutuallyExclusive = CA_INCOMPATIBILITY;
+            break;
+         case TARGET_CALLER_AVAILABLE:
+            contextRules = TARGET_CALLER_AVAILABLE;
+            mutuallyExclusive = TCA_INCOMPATIBILITY;
+            break;
+         default:
+            throw new RuntimeException("Unexpected Context Type " +
+                  properties.getContext());
+      }
+      
+      
       LinkedList<AdviceInfo> rankedAdvices = new LinkedList<AdviceInfo>();
       for (int i = 0; i < methods.length; i++)
       {
@@ -252,7 +295,8 @@
             try
             {
                // advice applies to annotated parameter rules
-               rankedAdvices.add(new AnnotatedParameterAdviceInfo(methods[i], rules));
+               rankedAdvices.add(new AnnotatedParameterAdviceInfo(methods[i], rules,
+                     contextRules, mutuallyExclusive));
             }catch (ParameterAnnotationRuleException pare)
             {
                // no need to print messages -> exception prints automatically on verbose
@@ -267,7 +311,8 @@
       // sort according to rank
       Collections.sort(rankedAdvices);
       // validate and retrive best match
-      AdviceInfo bestAdvice = bestValidAdvice(rankedAdvices, properties);
+      AdviceInfo bestAdvice = bestValidAdvice(rankedAdvices, properties,
+            contextRules);
       if (bestAdvice == null)
       {
          return null;
@@ -282,17 +327,19 @@
     * 
     * @param rankedAdvices a sorted collection of advice infos
     * @param properties    contains information about the queried advice method
+    * @param contextRules  the parameter annotation rules that are dependent on the
+    *                      join point context
     * @return              information about the best advice method match
     */
    private AdviceInfo bestValidAdvice(LinkedList<AdviceInfo> rankedAdvices,
-         AdviceMethodProperties properties)
+         AdviceMethodProperties properties, ParameterAnnotationRule[] contextRules)
    {
       AdviceInfo bestAdvice = null;
       ListIterator<AdviceInfo> iterator = rankedAdvices.listIterator();
       while (iterator.hasNext())
       {
          AdviceInfo advice = iterator.next();
-         if (advice.validate(properties, mutuallyExclusive, returnType))
+         if (advice.validate(properties, returnType))
          {
             bestAdvice = advice;
             break;
@@ -318,7 +365,7 @@
          AdviceInfo advice = iterator.next();
          if (advice.getRank() == bestAdvice.getRank())
          {
-            if (!advice.validate(properties, mutuallyExclusive, returnType))
+            if (!advice.validate(properties, returnType))
             {
                iterator.remove();
             }
@@ -338,13 +385,12 @@
       // if not, retrive the list of all valid advices with the highest rank
       List<AdviceInfo> bestAdvices =
          rankedAdvices.subList(0, iterator.nextIndex());
-      Class returnType = properties.getJoinpointReturnType();
       // deep process these advices to find the best match
-      return bestMatch(bestAdvices, properties);
+      return bestMatch(bestAdvices, properties, contextRules);
    }
    
    /**
-    * Return the best advice method among the advices contained in <code>greatestRank
+    * Returns the best advice method among the advices contained in <code>greatestRank
     * </code>. The criteria used is the specificness of annotated parameters type,
     * i.e., the more specific type <code>MethodInvocation</code> is better than
     * <code>Invocation</code>.
@@ -352,22 +398,79 @@
     * @param greatestRank contains information about all valid advice methods with the
     *                     highest rank
     * @param properties   information about the queried advice method
+    * @param contextRules the context annotation rules (depend on the join point
+    *                     context)
     * @return             information about the best advice method match
     */
    AdviceInfo bestMatch(Collection<AdviceInfo> greatestRank,
-         AdviceMethodProperties properties)
+         AdviceMethodProperties properties, ParameterAnnotationRule[] contextRules)
    {
+      
+      // select the closest match according to assignability degree of parameters
+      // like Invocation, JoinPoint, Return, etc
+      AdviceInfo bestAdvice = selectBestRuleMatch(greatestRank, properties,
+            rules.length, false);
+      if (bestAdvice != null)
+      {
+         return bestAdvice;
+      }
+      // context rules are second priority
+      bestAdvice = selectBestRuleMatch(greatestRank, properties, contextRules.length,
+            true);
+      if (bestAdvice != null)
+      {
+         return bestAdvice;
+      }
       short bestDegree = NOT_ASSIGNABLE_DEGREE;
+      if (returnType == ReturnType.ANY || returnType == ReturnType.NOT_VOID)
+      {
+         for (AdviceInfo currentAdvice: greatestRank)
+         {
+            short currentDegree =  currentAdvice.getReturnAssignabilityDegree(properties);
+            if (currentDegree < bestDegree)
+            {
+               bestAdvice = currentAdvice;
+               bestDegree = currentDegree;
+            }
+         }
+         //in case of two or more advices with the same match degree, pick any one of them
+         return bestAdvice;
+      }
+      // we have more than one best advice; return any one of them
+      return greatestRank.iterator().next();
+   }
+   
+   /**
+    * Returns the best advice method among the advices contained in <code>greatestRank
+    * </code>. The criteria used in the assignability degree of parameters
+    * that follow a set of rules (defined by <code>useContextRules</code>).
+    * 
+    * @param greatestRank    contains information about all valid advice methods with
+    *                        the highest rank
+    * @param properties      information about the queried advice method
+    * @param totalRules      the total number of rules that will be used on matching
+    * @param useContextRules if <code>true</code>, context rules are used instead
+    *                        of factory rules
+    * @return                the best match. If there is more than one match, returns
+    *                        <code>null</code>
+    */
+   private AdviceInfo selectBestRuleMatch(Collection<AdviceInfo> greatestRank,
+         AdviceMethodProperties properties, int totalRules,
+         boolean isContextRule)
+   {
+      short bestDegree = NOT_ASSIGNABLE_DEGREE;
       AdviceInfo bestAdvice = null;
       Collection<AdviceInfo> removeList = new ArrayList<AdviceInfo>();
+      
       // rule i is more important than rule i + 1
-      for (int i = 0; i < rules.length; i++)
+      for (int i = 0; i < totalRules; i++)
       {
          for (Iterator<AdviceInfo> iterator = greatestRank.iterator();
                iterator.hasNext();)
          {
             AdviceInfo currentAdvice = iterator.next();
-            short currentDegree = currentAdvice.getAssignabilityDegree(i, properties);
+            short currentDegree = currentAdvice.getAssignabilityDegree(i,
+                  isContextRule, properties);
             if (currentDegree < bestDegree)
             {
                if (bestAdvice != null)
@@ -393,22 +496,7 @@
          bestAdvice = null;
          bestDegree = NOT_ASSIGNABLE_DEGREE;
       }
-      if (returnType == ReturnType.ANY || returnType == ReturnType.NOT_VOID)
-      {
-         for (AdviceInfo currentAdvice: greatestRank)
-         {
-            short currentDegree =  currentAdvice.getReturnAssignabilityDegree(properties);
-            if (currentDegree < bestDegree)
-            {
-               bestAdvice = currentAdvice;
-               bestDegree = currentDegree;
-            }
-         }
-         //in case of two or more advices with the same match degree, pick any one of them
-         return bestAdvice;
-      }
-      // we have more than one best advice; return any one of them
-      return greatestRank.iterator().next();
+      return null;
    }
    
    /**

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/AnnotatedParameterAdviceInfo.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -2,11 +2,6 @@
 
 import java.lang.annotation.Annotation;
 import java.lang.reflect.Method;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.LinkedList;
-import java.util.List;
-import java.util.Set;
 
 import org.jboss.aop.AspectManager;
 import org.jboss.aop.advice.AdviceMethodProperties;
@@ -22,109 +17,52 @@
 {
    // the annotated parameter types
    private ParameterAnnotationType paramTypes[];
+   // the context dependent annotated parameter types
+   private ParameterAnnotationType contextParamTypes[];
+   // muttually exclusive context parameter rules
+   private int[][] mutuallyExclusive;
    
    /**
     * Creates an annotated parameter advice info.
     * 
-    * @param method the advice method
-    * @param rules  the annnotated parameter rules this method should comply with
+    * @param method            the advice method
+    * @param rules             the annnotated parameter rules this method should
+    *                          comply with
+    * @param contextRules      second priority rules this method should comply with
+    * @param mutuallyExclusive a list of mutually exclusive context parameter rules
     * 
     * @throws ParameterAnnotationRuleException thrown when the advice method does not
     *         comply with a parameter annotation rule.
     */
-   public AnnotatedParameterAdviceInfo(Method method, ParameterAnnotationRule[] rules)
+   public AnnotatedParameterAdviceInfo(Method method, ParameterAnnotationRule[] rules,
+         ParameterAnnotationRule[] contextRules, int[][] mutuallyExclusive)
       throws ParameterAnnotationRuleException
    {
-      this(rules, method);
+      super(method, 0);
+      this.paramTypes = createParameterAnnotationTypes(rules);
+      this.contextParamTypes = createParameterAnnotationTypes(contextRules);
+      this.mutuallyExclusive = mutuallyExclusive;
       this.applyRules();
    }
-   
-   /**
-    * Private constructor. Called only internally, does not apply the parameter annotation
-    * rules to the advice method parameters.
-    * 
-    * @param rules  the parameter annotation rules this method should comply with
-    * @param method the advice method 
-    */
-   private AnnotatedParameterAdviceInfo(ParameterAnnotationRule[] rules, Method method)
+      
+   public boolean validate(AdviceMethodProperties properties, ReturnType returnType)
    {
-      super(method, 0);
-      this.paramTypes = new ParameterAnnotationType[rules.length];
-      // create appropriate annotated parameter types for each AP rule
-      for (int i = 0; i < rules.length; i++)
+      for (ParameterAnnotationType paramType: paramTypes)
       {
-         if (rules[i].isSingleEnforced())
+         if (!paramType.validate(properties))
          {
-            this.paramTypes[i] = new SingleParameterType(rules[i]);
+            return false;
          }
-         else
-         {
-            this.paramTypes[i] = new MultipleParameterType(rules[i],
-                  method.getParameterTypes().length);
-         }
       }
-   }
-   
-   /**
-    * Creates all advice info instances necessary for representing the multi-annotated
-    * parameters of <code>method</code>.
-    * <p>Should be invoked when the constructor of <code>AnnotatedParamereAdviceInfo
-    * </code> throws a <code>MultipleAdviceInfoException</code>.
-    * 
-    * @param method          the method that contains parameters with more than one
-    *                        valid annotations
-    * @param rules           the parameter annotation rules
-    * @param totalInstances  the total number of instances that must be created
-    * @param annotations     the list of annotated parameter indexes
-    * @return  all advice info instances representing <code>method</code>.
-    */
-   public static List<AnnotatedParameterAdviceInfo> createAllAdviceInfo(
-         Method method, ParameterAnnotationRule[] rules, int totalInstances,
-         int[][]annotations)
-   {
-      List<AnnotatedParameterAdviceInfo> allAdvices =
-         new LinkedList<AnnotatedParameterAdviceInfo>();
-      Set<AnnotatedParameterAdviceInfo> removeAdvices =
-         new HashSet<AnnotatedParameterAdviceInfo>();
-      // create instances
-      for (int i = 0; i < totalInstances; i++)
+      
+      for (ParameterAnnotationType paramType: contextParamTypes)
       {
-         allAdvices.add(new AnnotatedParameterAdviceInfo(rules, method));
-      }
-      // set all the possible combinations of parameter annotations to the instances
-      for (int i = 0; i < annotations.length; i++)
-      {
-         for (Iterator<AnnotatedParameterAdviceInfo> iterator = allAdvices.iterator();
-         iterator.hasNext();)
-         {
-            for (int j = 0; j < annotations[i].length; j++)
-            {
-               AnnotatedParameterAdviceInfo adviceInfo = iterator.next();
-               try
-               {
-                  adviceInfo.paramTypes[annotations[i][j]].setIndex(i);
-               } catch (ParameterAnnotationRuleException maoe)
-               {
-                  removeAdvices.add(adviceInfo);
-               }
-            }
-         }
-      }
-      // remove all combinations that resulted in multiple annotation exception
-      allAdvices.removeAll(removeAdvices);
-      return allAdvices;
-   }
-   
-   public boolean validate(AdviceMethodProperties properties,
-         int[][] mutuallyExclusive, ReturnType returnType)
-   {
-      for (ParameterAnnotationType paramType: paramTypes)
-      {
          if (!paramType.validate(properties))
          {
             return false;
          }
       }
+      
       switch (returnType)
       {
          case ANY:
@@ -155,16 +93,16 @@
          int found = -1;
          for (int j = 0; j < exclusiveParamTypes.length; j++)
          {
-            if (paramTypes[exclusiveParamTypes[j]].isSet())
+            if (contextParamTypes[exclusiveParamTypes[j]].isSet())
             {
                if (found != -1)
                {
                   if (AspectManager.verbose)
                   {
                      AdviceMethodFactory.adviceMatchingMessage.append("\n[warn] - the use of parameter annotations ");
-                     AdviceMethodFactory.adviceMatchingMessage.append(paramTypes[exclusiveParamTypes[found]].rule.getAnnotation());
+                     AdviceMethodFactory.adviceMatchingMessage.append(contextParamTypes[exclusiveParamTypes[found]].rule.getAnnotation());
                      AdviceMethodFactory.adviceMatchingMessage.append(" and ");
-                     AdviceMethodFactory.adviceMatchingMessage.append(paramTypes[exclusiveParamTypes[j]].rule.getAnnotation());
+                     AdviceMethodFactory.adviceMatchingMessage.append(contextParamTypes[exclusiveParamTypes[j]].rule.getAnnotation());
                      AdviceMethodFactory.adviceMatchingMessage.append(" is mutually exclusive");
                   }
                   return false;
@@ -176,9 +114,13 @@
       return true;
    }
    
-   public short getAssignabilityDegree(int annotationIndex,
+   public short getAssignabilityDegree(int annotationIndex, boolean isContextRule,
          AdviceMethodProperties properties)
    {
+      if (isContextRule)
+      {
+         return contextParamTypes[annotationIndex].getAssignabilityDegree(properties);
+      }
       return paramTypes[annotationIndex].getAssignabilityDegree(properties);
    }
    
@@ -189,10 +131,42 @@
       {
          paramTypes[i].assignParameterInfo(args);
       }
+      for (int i = 0; i < contextParamTypes.length; i++)
+      {
+         contextParamTypes[i].assignParameterInfo(args);
+      }
       properties.setFoundProperties(this.method, args);
    }
 
    /**
+    * Creates a parameter annotation type array correpondent to the parameter
+    * annotation rules contained in <code>rules</code>.
+    * 
+    * @param rules the parameter annotation rules
+    * 
+    * @return a parameter annotation type array correspondent to <code>rules</code>
+    */
+   private final ParameterAnnotationType[] createParameterAnnotationTypes(
+         ParameterAnnotationRule[] rules)
+   {
+      ParameterAnnotationType[] types = new ParameterAnnotationType[rules.length];
+      // create appropriate annotated parameter types for each AP rule
+      for (int i = 0; i < rules.length; i++)
+      {
+         if (rules[i].isSingleEnforced())
+         {
+            types[i] = new SingleParameterType(rules[i]);
+         }
+         else
+         {
+            types[i] = new MultipleParameterType(rules[i],
+                  method.getParameterTypes().length);
+         }
+      }
+      return types;
+   }
+   
+   /**
     * Applies all parameter annotation rules to the advice method parameters.
     * 
     * @throws ParameterAnnotationRuleException thrown when the advice method does not
@@ -201,86 +175,102 @@
    private void applyRules() throws ParameterAnnotationRuleException
    {
       Annotation[][] paramAnnotations = method.getParameterAnnotations();
-      boolean annotated;
+      boolean ruleFound;
       for (int i = 0; i < paramAnnotations.length; i++)
       {
-         annotated = false;
+         ruleFound = false;
          for (Annotation annotation: paramAnnotations[i])
          {
             // no valid annotation found for parameter i yet
-            if (!annotated)
-            for (int j = 0; j < paramTypes.length; j++)
+            if (!ruleFound)
             {
-               // found
-                if (paramTypes[j].applies(annotation, i))
-                {
-                   annotated = true;
-                   break;
-                }
+               ruleFound = findAnnotationRule(annotation, i);
             }
             else
             {
-               // look for an extra annotation
-               for (int j = 0; j < paramTypes.length; j++)
+               if (findAnnotationRule(annotation, i))
                {
-                  if (paramTypes[j].applies(annotation))
+                  if (AspectManager.verbose)
                   {
-                     throwMultiAnnotationFoundException(i);
+                     throw new ParameterAnnotationRuleException("\n[warn] -parameter " + i  +
+                           " of method " + method +  " contains more than one valid annotation");
                   }
+                  else
+                  {
+                     throw new ParameterAnnotationRuleException(null);
+                  }
                }
             }
          }
-         if (!annotated)
+         if (!ruleFound)
          {
-            throwAnnotationNotFoundException(i);
+            if (AspectManager.verbose)
+            {
+               if (paramAnnotations[i].length == 0)
+               {
+                  throw new ParameterAnnotationRuleException("\n[warn] -parameter "
+                        + i  + " of method " + method +  " is not annotated");
+               }
+               throw new ParameterAnnotationRuleException("\n[warn] -parameter "
+                     + i  + " of method " + method +  " is not annotated correctly" +
+                     "\n[warn]  Expecting one of: " + getDescription(paramTypes) +
+                     getDescription(contextParamTypes));
+            }
+            // no need to say the reason a rule's been broken
+            throw new ParameterAnnotationRuleException(null);
          }
-      }
-      
+      }      
    }
-
-   /**
-    * Throws an exception indicating the ith parameter of this advice contains
-    * multiple valid annotations.
-    * 
-    * @param i the index of the not annotated parameter.
-    * 
-    * @throws ParameterAnnotationRuleException
-    */
-   private final void throwMultiAnnotationFoundException(int i)
-      throws ParameterAnnotationRuleException
+   
+   private String getDescription(ParameterAnnotationType[] types)
    {
-      if (AspectManager.verbose)
+      StringBuffer buffer = new StringBuffer();
+      for (int i = 1; i < types.length; i++)
       {
-         throw new ParameterAnnotationRuleException("\n[warn] -parameter " + i  +
-               " of method " + method +  " contains more than one valid annotation");
+         buffer.append("\n          ");
+         buffer.append(types[i]);
       }
-      else
-      {
-         throw new ParameterAnnotationRuleException(null);
-      }
+      return buffer.toString();
    }
-   
+
    /**
-    * Throws an exception indicating the ith parameter of this advice is not annotated.
+    * Searches for an annotation <code>Annotation</code> on parameter annotation
+    * rules.
     * 
-    * @param i the index of the not annotated parameter.
+    * @param annotation the parameter annotation to be searched on the parameter
+    *                   annotation rules
+    * @param i          the number of the advice parameter that is annotated with
+    *                   <code>annotation</code>
     * 
-    * @throws ParameterAnnotationRuleException
+    * @return           <code>true</code> if there is a rule correspondent to
+    *                   <code>annotation</code>
+    * 
+    * @throws ParameterAnnotationRuleException if a parameter annotation is found
+    *         more than once and the annotation rule forbides multiple occurences
     */
-   private final void throwAnnotationNotFoundException(int i)
+   private final boolean findAnnotationRule(Annotation annotation, int i)
       throws ParameterAnnotationRuleException
    {
-      if (AspectManager.verbose)
+      
+      for (int j = 0; j < paramTypes.length; j++)
       {
-         throw new ParameterAnnotationRuleException("\n[warn] -parameter " + i  +
-               " of method " + method +  " is not annotated");
+         // found
+         if (paramTypes[j].applies(annotation, i))
+         {
+            return true;
+         }
       }
-      else
+      for (int j = 0; j < contextParamTypes.length; j++)
       {
-         throw new ParameterAnnotationRuleException(null);
+         // found
+         if (contextParamTypes[j].applies(annotation, i))
+         {
+            return true;
+         }
       }
+      return false;
    }
-   
+      
    /**
     * Contains validation data concerning a parameter annotation rule.
     */
@@ -348,6 +338,10 @@
          return internalValidate(properties);
       }
 
+      public String toString()
+      {
+         return rule.getAnnotation().toString();
+      }
       
       /**
        * Records that the parameter identified by <code>paramterIndex</code> is of this

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/ParameterAnnotationRule.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/ParameterAnnotationRule.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/advice/annotation/ParameterAnnotationRule.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -56,24 +56,30 @@
          return properties.getJoinpointReturnType();
       }
    },
-   
+      
    /**
-    * Rule for parameter annotation {@link Callee}.
-    */
-   CALLEE (
-        Callee.class, null, AdviceMethodProperties.CALLEE_ARG, 45, false, true),
-   
-   /**
     * Rule for parameter annotation {@link Caller}.
     */
    CALLER (
-         Caller.class, null, AdviceMethodProperties.CALLER_ARG, 45, false, true),
+         Caller.class, null, AdviceMethodProperties.CALLER_ARG, 45, false, true)
+   {
+      public Object getAssignableFrom(AdviceMethodProperties properties)
+      {
+         return null; // TODO caller
+      }
+   },
    
    /**
     * Rule for parameter annotation {@link Target}.
     */
    TARGET (
-         Target.class, null, AdviceMethodProperties.TARGET_ARG, 90, false, true),
+         Target.class, null, AdviceMethodProperties.TARGET_ARG, 90, false, true)
+   {
+      public Object getAssignableFrom(AdviceMethodProperties properties)
+      {
+         return properties.getTargetType();
+      }
+   },
    
    /**
     * Rule for parameter annotation {@link Arg}.

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByConJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -37,6 +37,7 @@
 import org.jboss.aop.GeneratedClassAdvisor;
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -120,7 +121,9 @@
             INVOCATION_TYPE,
             ctor.getDeclaringClass(),
             ctor.getParameterTypes(),
-            ctor.getExceptionTypes());
+            ctor.getExceptionTypes(),
+            null,
+            Context.CALLER_AVAILABLE);
    }
 
    protected boolean isCaller()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConByMethodJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -37,6 +37,7 @@
 import org.jboss.aop.GeneratedClassAdvisor;
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -128,7 +129,9 @@
             INVOCATION_TYPE,
             ctor.getDeclaringClass(),
             ctor.getParameterTypes(),
-            ctor.getExceptionTypes());
+            ctor.getExceptionTypes(),
+            null,
+            hasCallingObject()? Context.CALLER_AVAILABLE: Context.STATIC);
    }
 
    protected boolean isCaller()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructionJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -38,6 +38,7 @@
 import org.jboss.aop.GeneratedClassAdvisor;
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.ConstructionInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -113,7 +114,9 @@
             INVOCATION_TYPE,
             ctor.getDeclaringClass(),
             ctor.getParameterTypes(),
-            ctor.getExceptionTypes());
+            ctor.getExceptionTypes(),
+            ctor.getDeclaringClass(),
+            Context.TARGET_AVAILABLE);
    }
 
    protected boolean hasTargetObject()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/ConstructorJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -38,6 +38,7 @@
 import org.jboss.aop.GeneratedClassAdvisor;
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.ConstructorInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -114,7 +115,9 @@
             INVOCATION_TYPE,
             ctor.getDeclaringClass(),
             ctor.getParameterTypes(),
-            ctor.getExceptionTypes());
+            ctor.getExceptionTypes(),
+            null,
+            Context.STATIC);
    }
 
    protected boolean hasTargetObject()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/FieldJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -37,6 +37,7 @@
 import org.jboss.aop.GeneratedClassAdvisor;
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.FieldReadInvocation;
 import org.jboss.aop.joinpoint.FieldWriteInvocation;
 import org.jboss.aop.util.JavassistToReflect;
@@ -122,6 +123,19 @@
    protected AdviceMethodProperties getAdviceMethodProperties(AdviceSetup setup)
    {
       Field field = ((FieldInfo)info).getAdvisedField();
+      if (hasTargetObject())
+      {
+         return new AdviceMethodProperties(
+               setup.getAspectClass(),
+               setup.getAdviceName(),
+               info.getClass(),
+               (read()) ? READ_INVOCATION_TYPE : WRITE_INVOCATION_TYPE,
+               (read()) ? getReturnType() : Void.TYPE,
+               (read()) ? new Class[] {} : new Class[] {field.getType()},
+               null,
+               field.getDeclaringClass(),
+               Context.TARGET_AVAILABLE);
+      }
       return new AdviceMethodProperties(
             setup.getAspectClass(),
             setup.getAdviceName(),
@@ -129,7 +143,9 @@
             (read()) ? READ_INVOCATION_TYPE : WRITE_INVOCATION_TYPE,
             (read()) ? getReturnType() : Void.TYPE,
             (read()) ? new Class[] {} : new Class[] {field.getType()},
-            null);
+            null,
+            null,
+            Context.STATIC);
    }
 
    protected CtClass[] getJoinpointParameters() throws NotFoundException

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/JoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -64,13 +64,7 @@
 {
    // TODO replace by enum
    protected static class JoinPointParameters {
-      public static final JoinPointParameters ONLY_ARGS = new JoinPointParameters(false, -1, false, -1, 0, "")
-      {
-         /*public String declareArgsArray(int argsSize)
-         {
-            return "Object[] " + ARGUMENTS + " = new Object[]{$$};";
-         }*/
-      };
+      public static final JoinPointParameters ONLY_ARGS = new JoinPointParameters(false, -1, false, -1, 0, "");
       public static final JoinPointParameters TARGET_ARGS = new JoinPointParameters(true, 1, false, -1, 1, "$1");
       public static final JoinPointParameters CALLER_ARGS = new JoinPointParameters(false, -1, true, 1, 1, "$1");
       public static final JoinPointParameters TARGET_CALLER_ARGS = new JoinPointParameters(true, 1, true, 2, 2, "$1, $2");
@@ -1674,15 +1668,7 @@
          code.append(");");
          return argsFound;
       }
-      /**
-       * @param code
-       * @param isAround
-       * @param args
-       * @param adviceParams
-       * @param argsFound
-       * @param i
-       * @return
-       */
+      
       private final boolean appendParameters(StringBuffer code, final int arg,
             final Class adviceParam, boolean isAround, JoinPointGenerator generator)
       {
@@ -1704,6 +1690,16 @@
          case AdviceMethodProperties.THROWABLE_ARG:
             code.append(THROWABLE);
             break;
+         case AdviceMethodProperties.TARGET_ARG:
+            if (isAround)
+            {
+               code.append(TARGET_FIELD);
+            }
+            else
+            {
+               code.append("$1");
+            }
+            return true;
          case AdviceMethodProperties.ARGS_ARG:
             code.append(ARGUMENTS);
             return true;

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByConJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -37,6 +37,7 @@
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.MethodByConInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.MethodCalledByConstructorInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -116,6 +117,19 @@
    protected AdviceMethodProperties getAdviceMethodProperties(AdviceSetup setup)
    {
       Method method = ((MethodByConInfo)info).getMethod();
+      if (hasTargetObject())
+      {
+         return new AdviceMethodProperties(
+               setup.getAspectClass(),
+               setup.getAdviceName(),
+               info.getClass(),
+               INVOCATION_TYPE,
+               method.getReturnType(),
+               method.getParameterTypes(),
+               method.getExceptionTypes(),
+               method.getDeclaringClass(),
+               Context.TARGET_AVAILABLE);
+      }
       return new AdviceMethodProperties(
             setup.getAspectClass(),
             setup.getAdviceName(),
@@ -123,7 +137,9 @@
             INVOCATION_TYPE,
             method.getReturnType(),
             method.getParameterTypes(),
-            method.getExceptionTypes());
+            method.getExceptionTypes(),
+            null,
+            Context.STATIC);
    }
 
    protected boolean isCaller()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodByMethodJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -37,6 +37,7 @@
 import org.jboss.aop.JoinPointInfo;
 import org.jboss.aop.MethodByMethodInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.MethodCalledByMethodInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -123,6 +124,21 @@
    protected AdviceMethodProperties getAdviceMethodProperties(AdviceSetup setup)
    {
       Method method = ((MethodByMethodInfo)info).getMethod();
+      if (hasTargetObject())
+      {
+         return new AdviceMethodProperties(
+               setup.getAspectClass(),
+               setup.getAdviceName(),
+               info.getClass(),
+               INVOCATION_TYPE,
+               method.getReturnType(),
+               method.getParameterTypes(),
+               method.getExceptionTypes(),
+               method.getDeclaringClass(),
+               hasCallingObject()?
+               Context.TARGET_CALLER_AVAILABLE:
+               Context.TARGET_AVAILABLE);
+      }
       return new AdviceMethodProperties(
             setup.getAspectClass(),
             setup.getAdviceName(),
@@ -130,7 +146,9 @@
             INVOCATION_TYPE,
             method.getReturnType(),
             method.getParameterTypes(),
-            method.getExceptionTypes());
+            method.getExceptionTypes(),
+            null,
+            hasCallingObject()? Context.CALLER_AVAILABLE: Context.STATIC);
    }
 
    protected boolean isCaller()

Modified: projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java
===================================================================
--- projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java	2006-12-29 17:08:21 UTC (rev 59245)
+++ projects/aop/trunk/aop/src/main/org/jboss/aop/instrument/MethodJoinPointGenerator.java	2006-12-29 23:52:03 UTC (rev 59246)
@@ -36,6 +36,7 @@
 import org.jboss.aop.GeneratedClassAdvisor;
 import org.jboss.aop.MethodInfo;
 import org.jboss.aop.advice.AdviceMethodProperties;
+import org.jboss.aop.advice.AdviceMethodProperties.Context;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.util.ReflectToJavassist;
 
@@ -109,6 +110,19 @@
    protected AdviceMethodProperties getAdviceMethodProperties(AdviceSetup setup)
    {
       Method method = ((MethodInfo)info).getAdvisedMethod();
+      if (hasTargetObject())
+      {
+         return new AdviceMethodProperties(
+               setup.getAspectClass(), 
+               setup.getAdviceName(), 
+               info.getClass(), 
+               INVOCATION_TYPE, 
+               method.getReturnType(), 
+               method.getParameterTypes(), 
+               method.getExceptionTypes(),
+               method.getDeclaringClass(),
+               Context.TARGET_AVAILABLE);
+      }
       return new AdviceMethodProperties(
             setup.getAspectClass(), 
             setup.getAdviceName(), 
@@ -116,7 +130,9 @@
             INVOCATION_TYPE, 
             method.getReturnType(), 
             method.getParameterTypes(), 
-            method.getExceptionTypes());
+            method.getExceptionTypes(),
+            null,
+            Context.STATIC);
    }
    
 



From jboss-cvs-commits at lists.jboss.org  Fri Dec 29 19:06:59 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Fri, 29 Dec 2006 19:06:59 -0500
Subject: [jboss-cvs] JBossAS SVN: r59247 - in projects/aop/trunk/aop/src:
	resources/test/beforeafterArgs
	test/org/jboss/test/aop/beforeafterArgs
Message-ID: <E1H0RkZ-0006h4-3B@committer01.frg.pub.inap.atl.jboss.com>

Author: flavia.rainone
Date: 2006-12-29 19:06:51 -0500 (Fri, 29 Dec 2006)
New Revision: 59247

Added:
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetAspect.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetPOJO.java
   projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetTestCase.java
Modified:
   projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
Log:
[JBAOP-326] First Target parameter test

Modified: projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml
===================================================================
--- projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-29 23:52:03 UTC (rev 59246)
+++ projects/aop/trunk/aop/src/resources/test/beforeafterArgs/jboss-aop.xml	2006-12-30 00:06:51 UTC (rev 59247)
@@ -60,7 +60,7 @@
       <after name="after8" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
 	   <throwing name="throwing" aspect="org.jboss.test.aop.beforeafterArgs.ArgsAspect" />
 	</bind>
-	
+
    <!-- @JoinPoint test -->
 	<aspect class="org.jboss.test.aop.beforeafterArgs.JoinPointAspect" scope="PER_VM"/>
 
@@ -168,6 +168,15 @@
 		<after name="after11" aspect="org.jboss.test.aop.beforeafterArgs.ReturnAspect"/>
 	</bind>
 
+   <!-- @Target test -->
+	<aspect class="org.jboss.test.aop.beforeafterArgs.TargetAspect" scope="PER_VM"/>
+
+	<bind pointcut="execution(* org.jboss.test.aop.beforeafterArgs.TargetPOJO->method1(..))">
+		<before name="before1" aspect="org.jboss.test.aop.beforeafterArgs.TargetAspect"/>
+      <before name="before2" aspect="org.jboss.test.aop.beforeafterArgs.TargetAspect"/>
+   </bind>
+
+
    <!-- @Thrown test -->
 	<aspect class="org.jboss.test.aop.beforeafterArgs.ThrownAspect" scope="PER_VM"/>
 

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetAspect.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetAspect.java	2006-12-29 23:52:03 UTC (rev 59246)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetAspect.java	2006-12-30 00:06:51 UTC (rev 59247)
@@ -0,0 +1,55 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import org.jboss.aop.advice.annotation.Target;
+
+/**
+ * Aspect used on @Args parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class TargetAspect
+{
+   static boolean before1 = false;
+   static boolean before2 = false;
+ 
+   static Object before2Target = null;
+   
+   public static void clear()
+   {
+      before1 = false;
+      before2 = false;
+      before2Target = null;
+   }
+   
+   public void before1()
+   {
+      before1 = true;
+   }
+   
+   public void before2(@Target Object target)
+   {
+      before2 = true;
+      before2Target = target;
+   }
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetPOJO.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetPOJO.java	2006-12-29 23:52:03 UTC (rev 59246)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetPOJO.java	2006-12-30 00:06:51 UTC (rev 59247)
@@ -0,0 +1,33 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+
+/**
+ * Plain old java object used on @Target parameter tests.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class TargetPOJO
+{
+   public void method1(){}
+}
\ No newline at end of file

Added: projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetTestCase.java
===================================================================
--- projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetTestCase.java	2006-12-29 23:52:03 UTC (rev 59246)
+++ projects/aop/trunk/aop/src/test/org/jboss/test/aop/beforeafterArgs/TargetTestCase.java	2006-12-30 00:06:51 UTC (rev 59247)
@@ -0,0 +1,70 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.aop.beforeafterArgs;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+import org.jboss.test.aop.AOPTestWithSetup;
+
+/**
+ * Tests the use of @Target parameters.
+ * 
+ * @author <a href="flavia.rainone at jboss.com">Flavia Rainone</a>
+ */
+public class TargetTestCase extends AOPTestWithSetup
+{
+   private TargetPOJO pojo;
+   
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("TargetTestCase");
+      suite.addTestSuite(TargetTestCase.class);
+      return suite;
+   }
+   
+   public TargetTestCase(String name)
+   {
+      super(name);
+   }
+   
+   public void setUp() throws Exception
+   {
+      super.setUp();
+      TargetAspect.clear();
+      this.pojo = new TargetPOJO();
+   }
+   
+   public void test1()
+   {
+      pojo.method1();
+      assertTrue(TargetAspect.before1);
+      assertTrue(TargetAspect.before2);
+      assertSame(pojo, TargetAspect.before2Target);
+   }
+}
\ No newline at end of file



From bwang at jboss.com  Fri Dec 29 21:53:07 2006
From: bwang at jboss.com (Ben Wang)
Date: Fri, 29 Dec 2006 21:53:07 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/impl  ...
Message-ID: <E1H0ULL-0000tH-6L@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/29 21:53:07

  Modified:    src-50/org/jboss/cache/pojo/impl  PojoCacheDelegate.java
  Log:
  JBCACHE-919 Optimize __JBossInternal__ access.
  
  Revision  Changes    Path
  1.17      +33 -5     JBossCache/src-50/org/jboss/cache/pojo/impl/PojoCacheDelegate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoCacheDelegate.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/impl/PojoCacheDelegate.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- PojoCacheDelegate.java	13 Oct 2006 10:30:24 -0000	1.16
  +++ PojoCacheDelegate.java	30 Dec 2006 02:53:07 -0000	1.17
  @@ -18,6 +18,7 @@
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Node;
   import org.jboss.cache.Cache;
  +import org.jboss.cache.config.Option;
   import org.jboss.cache.pojo.interceptors.dynamic.AbstractCollectionInterceptor;
   import org.jboss.cache.pojo.memory.FieldPersistentReference;
   import org.jboss.cache.pojo.util.AopUtil;
  @@ -155,7 +156,12 @@
         }
   
         // This create a PojoReference to store a pointer to the real fqn.
  -      Fqn internalFqn = createPojoReference(fqn, obj);
  +      Fqn internalFqn = createInternalFqn(fqn, obj);
  +      setPojoReference(fqn, obj, internalFqn);
  +      // creates the internal node first without going thru the interceptor.
  +      // This way we don't block on __JBossInternal__ node.
  +      createChildNodeFirstWithoutLocking(internalFqn);
  +
         if (log.isDebugEnabled())
         {
            log.debug("putObject(): id: " + fqn + " will store the pojo in the internal area: "
  @@ -182,15 +188,20 @@
         return oldValue;
      }
   
  -   Fqn createPojoReference(Fqn fqn, Object obj) throws CacheException
  +   Fqn createInternalFqn(Fqn fqn, Object obj) throws CacheException
  +   {
  +      // Create an internal Fqn name
  +      Fqn internalFqn = AopUtil.createInternalFqn(fqn, (Cache)cache_);
  +      return internalFqn;
  +   }
  +
  +   Fqn setPojoReference(Fqn fqn, Object obj, Fqn internalFqn) throws CacheException
      {
         // Create PojoReference
         CachedType type = pCache_.getCachedType(obj.getClass());
         PojoReference pojoReference = new PojoReference();
         pojoReference.setPojoClass(type.getType());
   
  -      // Create an internal Fqn name
  -      Fqn internalFqn = AopUtil.createInternalFqn(fqn, (Cache)cache_);
         // store PojoReference
         pojoReference.setFqn(internalFqn);
         internal_.putPojoReference(fqn, pojoReference);
  @@ -202,6 +213,22 @@
         return internalFqn;
      }
   
  +   private void createChildNodeFirstWithoutLocking(Fqn internalFqn)
  +   {
  +      int size = internalFqn.size();
  +      Fqn f = internalFqn.getFqnChild(0, size-1);
  +      Fqn child = internalFqn.getFqnChild(size-1, size);
  +      Node base = cache_.getRoot().getChild(f);
  +      if(base == null)
  +      {
  +         log.debug("The node retrieved is null from fqn: " +f);
  +         return;
  +      }
  +      Option option = cache_.getInvocationContext().getOptionOverrides();
  +      option.setBypassInterceptorChain(true);
  +      base.addChild(child);
  +   }
  +
      /**
       * Note that caller of this method will take care of synchronization within the <code>fqn</code> sub-tree.
       *
  @@ -308,7 +335,8 @@
         PojoInstance pojoInstance = internal_.getAopInstance(internalFqn);
         if (pojoInstance == null)
         {
  -         throw new RuntimeException("PojoCacheDelegate.getObjectInternal(): null PojoInstance.");
  +         throw new RuntimeException("PojoCacheDelegate.getObjectInternal(): null PojoInstance for fqn: " +
  +         internalFqn);
         }
   
         // Check for both Advised and Collection classes for object graph.
  
  
  


From bwang at jboss.com  Fri Dec 29 22:56:36 2006
From: bwang at jboss.com (Ben Wang)
Date: Fri, 29 Dec 2006 22:56:36 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/interceptors  ...
Message-ID: <E1H0VKm-0001xo-MM@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/29 22:56:36

  Modified:    src-50/org/jboss/cache/pojo/interceptors 
                        PojoTxInterceptor.java
  Log:
  Throw a more verbose rollback exception in PojoCacheException.
  
  Revision  Changes    Path
  1.8       +3 -5      JBossCache/src-50/org/jboss/cache/pojo/interceptors/PojoTxInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoTxInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/interceptors/PojoTxInterceptor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- PojoTxInterceptor.java	17 Sep 2006 02:52:29 -0000	1.7
  +++ PojoTxInterceptor.java	30 Dec 2006 03:56:36 -0000	1.8
  @@ -22,7 +22,7 @@
    * Interceptor (done via aop advice) for transaction
    *
    * @author Ben Wang
  - * @version $Id: PojoTxInterceptor.java,v 1.7 2006/09/17 02:52:29 bwang Exp $
  + * @version $Id: PojoTxInterceptor.java,v 1.8 2006/12/30 03:56:36 bwang Exp $
    */
   public class PojoTxInterceptor extends AbstractInterceptor
   {
  @@ -87,10 +87,8 @@
                     exn.printStackTrace();
                  }
   
  -               if (!(e instanceof PojoCacheException))
  -                  throw new RuntimeException("PojoCache.putObject(): id: " + id, e);
  -               else
  -                  throw (PojoCacheException) e;
  +               throw new PojoCacheException("PojoCache operation will be rollback. id: " + id
  +                       + ". Operation: " +invocation.getMethod().getName(), e);
               }
            } else
            {
  
  
  


From bwang at jboss.com  Fri Dec 29 23:07:54 2006
From: bwang at jboss.com (Ben Wang)
Date: Fri, 29 Dec 2006 23:07:54 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/rollback ...
Message-ID: <E1H0VVi-0002Hm-Gu@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/29 23:07:54

  Added:       tests-50/functional/org/jboss/cache/pojo/rollback 
                        LocalExceptionUndoTest.java
  Log:
  Created to test lock time out exception for PojoCache rollback.
  
  Revision  Changes    Path
  1.1      date: 2006/12/30 04:07:54;  author: bwang;  state: Exp;JBossCache/tests-50/functional/org/jboss/cache/pojo/rollback/LocalExceptionUndoTest.java
  
  Index: LocalExceptionUndoTest.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source.
   * Copyright 2006, 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.cache.pojo.rollback;
  
  import junit.framework.TestCase;
  import junit.framework.Test;
  import junit.framework.TestSuite;
  import org.apache.commons.logging.Log;
  import org.apache.commons.logging.LogFactory;
  import org.jboss.cache.pojo.PojoCache;
  import org.jboss.cache.pojo.PojoCacheFactory;
  import org.jboss.cache.pojo.InternalConstant;
  import org.jboss.cache.pojo.PojoCacheException;
  import org.jboss.cache.pojo.test.Person;
  import org.jboss.cache.pojo.interceptors.PojoFailedTxMockupInterceptor;
  import org.jboss.cache.pojo.interceptors.dynamic.CacheFieldInterceptor;
  import org.jboss.cache.transaction.DummyTransactionManager;
  import org.jboss.cache.Fqn;
  import org.jboss.aop.advice.Interceptor;
  import org.jboss.aop.Advised;
  
  import javax.transaction.TransactionManager;
  import java.util.ArrayList;
  
  /**
   * Additional basic tests
   *
   * @author Ben Wang
   */
  
  public class LocalExceptionUndoTest extends TestCase
  {
     Log log_ = LogFactory.getLog(LocalExceptionUndoTest.class);
     PojoCache cache_;
     TransactionManager tx_mgr;
     boolean isTrue = false;
  
     public LocalExceptionUndoTest(String name)
     {
        super(name);
     }
  
     protected void setUp() throws Exception
     {
        super.setUp();
        log_.info("setUp() ....");
        String configFile = "META-INF/local-service.xml";
        boolean toStart = false;
        cache_ = PojoCacheFactory.createCache(configFile, toStart);
        cache_.getCache().getConfiguration().setLockAcquisitionTimeout(500); // timeout to 500 ms
        cache_.start();
        tx_mgr = DummyTransactionManager.getInstance();
     }
  
     private void startLockThread() throws Exception
     {
        // Lock thread to lock underlying node.
        (new LockThread()).start();
        Thread.sleep(300);
     }
  
     private void stopLockThread() throws Exception
     {
        isTrue = true;
        Thread.sleep(200);
     }
  
     protected void tearDown() throws Exception
     {
        super.tearDown();
        cache_.stop();
     }
  
     public void testSimpleTxWithRollback1() throws Exception
     {
        log_.info("testSimpleTxWithRollback1() ....");
        Person test = new Person();
        test.setName("Ben");
        test.setAge(10);
        ArrayList list = new ArrayList();
        list.add("English");
        test.setLanguages(list);
  
        startLockThread();
  
        try {
           cache_.attach("/a", test);
        } catch (PojoCacheException ex)
        {
  //         ex.printStackTrace();
        }
        assertFalse("Should not have cache interceptor ", hasCacheInterceptor(test));
        assertNull("Should be null", cache_.find("/a"));
  
        stopLockThread();
        cache_.attach("/a", test);
     }
  
     public void testSimpleTxWithRollback2() throws Exception
     {
        log_.info("testSimpleTxWithRollback1() ....");
        Person test = new Person();
        test.setName("Ben");
        test.setAge(10);
        ArrayList list = new ArrayList();
        list.add("English");
        test.setLanguages(list);
  
        try {
           cache_.attach("/a", test);
        } catch (PojoCacheException ex)
        {
  //         ex.printStackTrace();
        }
  
        startLockThread();
  
        try {
           cache_.detach("/a");
        } catch (PojoCacheException ex)
        {
  //         ex.printStackTrace();
        }
  
        stopLockThread();
        assertTrue("Should still have cache interceptor ", hasCacheInterceptor(test));
        cache_.detach("/a");
        assertNull("Should be null", cache_.find("/a"));
     }
  
     private boolean hasCacheInterceptor(Object pojo)
     {
        Interceptor[] interceptors = ((Advised)pojo)._getInstanceAdvisor().getInterceptors();
        for(int i=0; i < interceptors.length; i++)
        {
           if(interceptors[i] instanceof CacheFieldInterceptor)
              return true;
        }
        return false;
     }
  
     public static Test suite() throws Exception
     {
        return new TestSuite(LocalExceptionUndoTest.class);
     }
  
  
     public static void main(String[] args) throws Exception
     {
        junit.textui.TestRunner.run(suite());
     }
  
     public class LockThread extends Thread
     {
        public void run()
        {
           try
           {
              Fqn f = new Fqn(InternalConstant.JBOSS_INTERNAL_STRING);
              cache_.getCache().put(new Fqn(f, "123"), "key", "test");
              cache_.getCache().put(new Fqn("a"), "key", "test");
              tx_mgr.begin();
              cache_.getCache().put(new Fqn(f, "124"), "key", "test");
  
              while (!isTrue)
              {
                 sleep(100);
              }
              tx_mgr.commit();
           } catch (Exception ex)
           {
              ex.printStackTrace();
           }
  
        }
     }
  }
  
  
  


From ptsekov at jboss.org  Sat Dec 23 07:03:29 2006
From: ptsekov at jboss.org (Pavel Tsekov)
Date: Sat, 23 Dec 2006 07:03:29 -0500
Subject: [jboss-cvs] JBossCache/etc/svuid-db     ...
Message-ID: <E1Gy5b7-0004SJ-96@committer01.frg.pub.inap.atl.jboss.com>

  User: ptsekov 
  Date: 06/12/23 07:03:29

  Added:       etc/svuid-db     Tag: Branch_JBossCache_1_4_0
                        svuid-14.1.3.0.GA.xml svuid-14.1.4.0.GA.xml
                        svuid-50.1.3.0.GA.xml svuid-50.1.4.0.GA.xml
  Log:
  * etc/svuid-db/svuid-14.1.3.0.GA.xml: SVUID database for JBossCache 1.3.0 
  and JDK 1.4 . 
  * etc/svuid-db/svuid-14.1.4.0.GA.xml: SVUID database for JBossCache 1.4.0
  and JDK 1.4 .
  * etc/svuid-db/svuid-50.1.3.0.GA.xml: SVUID database for JBossCache 1.3.0
  and JDK 5. 
  * etc/svuid-db/svuid-50.1.4.0.GA.xml: SVUID database for JBossCache 1.4.0
  and JDK 5.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +8487 -0   JBossCache/etc/svuid-db/Attic/svuid-14.1.3.0.GA.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: svuid-14.1.3.0.GA.xml
  ===================================================================
  RCS file: svuid-14.1.3.0.GA.xml
  diff -N svuid-14.1.3.0.GA.xml
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ svuid-14.1.3.0.GA.xml	23 Dec 2006 12:03:28 -0000	1.1.2.1
  @@ -0,0 +1,8487 @@
  +<?xml version="1.0" encoding="UTF-8"?> 
  +<java version="1.4.2_10" class="java.beans.XMLDecoder"> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.BrokenBarrierException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-147457780021240026</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6714594232516465772</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-273293065942834887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4374456568832557570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap$BarrierLock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4525944060243092775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7462087621709176033</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArraySet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7377569541496517854</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.PropertyChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2015832332684279521</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3131847742139976720</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.VetoableChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1658935129351293677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAllocationExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5206070850678934963</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAmbiguousName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5463192617696168744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArguments</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-585523412586448725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayDimensions</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7421434457381110734</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayInitializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8700933638077559442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAssignment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5786492369725521120</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBinaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2762482415254161500</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBlock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6768276487850608921</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHCastExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7470063802377582745</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHClassDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937995350116520528</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHEnhancedForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6186147054579461507</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7948089581379394413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalComment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6286509731094061726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>885501998857403574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameters</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5377216513908772736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHIfStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8630320869909994701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHImportDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6358892934545928949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHLiteral</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9207502592290153353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3910140293232619649</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3850040841809657514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPackageDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3898847231539731472</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-503393472352053812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimarySuffix</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1787222033238474243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimitiveType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-329589427159246987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2752610538670204146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6533667932058465861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHStatementExpressionList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6321165101746983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchLabel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5975475021538911876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5655955042808726899</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTernaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1606563852196299305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHThrowStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1240271051305696705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTryStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7478089655732292849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3430943699278719269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTypedVariableDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1227389047756718948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHUnaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1356335365378375412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHVariableDeclarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8458315290118837535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHWhileStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-268607334595851302</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BlockNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2687158869589601405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6335918737638083070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Capabilities$Unavailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3399055441689407911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ClassPathException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4486900461219339615</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.DelayedEvalBshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3354511033240459040</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.EvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3716899742529067922</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ExternalNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5243541843670468747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Interpreter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8662818442204412948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.InterpreterError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>492955139343282635</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.LHS</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6459038804384583967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Modifiers</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8471185022017946576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Name</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1368962988105189185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.NameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2499232412105981353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7776137309758821134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Parser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1080445658583023363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1164390191642946889</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive$Special</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3358001335405681566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ReflectError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2866156013797271636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5443864013386003037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5414610443216917980</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2695405703637847608</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.This</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9164318017112736976</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Token</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1762483667756877906</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5931514358210053837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilEvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8152371752278016844</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilTargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3189155544820014872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3903315982083174172</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6803452281441498586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis$Handler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4949939576606791809</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.BshClassPath$UnqualifiedNameTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3781441989565933164</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.DiscreteFilesClassLoader$ClassSourceMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5512817511949635338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4449346005537544077</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4666331393709464197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8135609692397819965</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.BshCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5388205109589610178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7209531634233769565</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser$PackageTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5706938369034888760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4328339671783920384</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>511965521903648517</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8369148428197760566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4878413495152524714</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.NameCompletionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6402387817755043296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.JavaDocBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6416423833804352641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractInheritableJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9023782913479355888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2524636196290199193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.ClassLibrary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937822024500756265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3485584001530088379</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3826651908494651111</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaClass</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56717871423934265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaField</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5158976028974024460</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5243360122899135505</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>179251600928831072</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3633306177895408984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.Type</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1596228041010255947</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.parser.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5318681457549236818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5125104124988065132</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1696027756378506682</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6126250255117957129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3907099389150076506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259049612296041412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6072271561424686085</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6253738640542714864</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8341335540288476967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6541451738732568309</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5928371437429336297</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4989418639347196543</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4388663746486043332</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6774847732447034836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4531243655467066716</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8199402162587347927</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1867106235561680513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5182945951854128074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2353400642617702135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8009749324757823162</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1386004770507927487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6518377914521265924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5027933992067738953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3219031174271773941</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2983928040263651920</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8221776374808491901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2668179591598315903</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkableAdaptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5304617132327526103</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8255356362445153793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226598894953083600</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5836847517986682456</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3985641094402692577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1484566617740723084</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1131655762826131576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3534490007366143774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1604113897169961576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8218345469653233169</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1314195772401372924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4261907982787552070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6169609859379733351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIdentityHashingStrategy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9078971529298567003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5135986634343398216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7205369688399131238</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CannotCompileException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4347542786236949387</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.ClassMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804593026213805083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CtClass$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3010032700700443882</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.NotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3351646634891239203</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.AlignmentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8236846960668290894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.BadBytecode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3276990049810168442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.CodeAttribute$RuntimeCopyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6805061409088364619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.CompileError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3050226843070987526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.KeywordTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5199030078030817932</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.NoFieldException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4412708214950596625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SymbolTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5270810980735558192</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SyntaxError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>490889194191819310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3901587593786844134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2799997277816596178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ArrayInit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2455192015828220874</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.AssignExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4621657704473821336</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.BinExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>493705937276265737</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CallExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6467190087868486053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CastExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4282802057512523201</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CondExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5259064316096978698</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Declarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7623658853007847572</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.DoubleConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7520025738220931295</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Expr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4954272843196512706</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.FieldDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2740715577722591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.InstanceOfExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4884917690955972361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.IntConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8467565945324056444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Keyword</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-441109204299464211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Member</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8058663079822722722</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.MethodDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6143642298594142396</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.NewExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1149608066531689319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Pair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4983294681996546807</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Stmnt</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9161016440925075705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.StringL</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4872959613607194275</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Symbol</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6360767401848368660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3042823100727688513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4807719830136336780</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotInvokeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8414032860369172220</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotReflectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3829918668979165876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.ClassMetaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1446514439423711708</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.Metaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2488206368319211804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectImporter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6932897352659865446</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2947053296940077756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3933064703890332122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2414585153283929621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.web.BadHttpRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9044749387914005083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.AccessLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4089104928924996726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.CreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6295951740865457514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.DuplicateKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7287399994705270076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.EJBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>796770993296843510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.FinderException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8785983102057433621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchEntityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4815730078295420703</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchObjectLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9151491108833037318</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4624364141026778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.RemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4581849053220157910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRequiredLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884174204131319153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRolledbackLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2897658132751784821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.model.exceptions.DDBeanCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8433252794388831851</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.BeanNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3319141583318924489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ClientExecuteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3580202712793889609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6211997126760402756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3061110807000384518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DeploymentManagerCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1322593937994224595</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.InvalidModuleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3478551028858955312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8564794200621186554</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.TargetException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4774441890984466267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.status.ProgressEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7815118532096485937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6850763061112244487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidClientIDException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2410181719763491702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidDestinationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588063794606036755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidSelectorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6223038613086963841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8951994251593378324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSSecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7512859695190450217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageEOFException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4829621000056590895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3642297253594750138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotReadableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8044835867550650748</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotWriteableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4241931174711518830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1172695755360706776</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionInProgressException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5611340150426335231</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionRolledBackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9157976009672865857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AndQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Attribute</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2484220110589082382</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>535176054565814134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6347317584796410029</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4077085769279709076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6511584241791106926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7768025046539163385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadAttributeValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3105272988410493376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadBinaryOpValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5068475589449021227</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadStringOperationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7802201238441662100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BetweenQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2933597532866307444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryOpValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1216286847881456786</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryRelQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5690656271650491000</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BooleanValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7754922052666594581</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ClassAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5801329450358952434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8893743928912733931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-882579438394773049</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.IntrospectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1054516935875481725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidApplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3048022274675537269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidAttributeValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2164571879317142449</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>350520924977331825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6573344628407841861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ListenerNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7242605822448519061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8644704819898565848</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4433990064191844427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4066342430588744142</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanFeatureInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3952882688968447265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6451021435135161911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3888371564530107064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6178860474881375330</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanParameterInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7432616882776782338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2416928705275160661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanRegistrationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4482382455277067805</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2876477500475969677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5661980843569388590</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission$MBeanServerPermissionCollections</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4111836792595161197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanTrustPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2952178077029018140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MalformedObjectNameException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-572689714442915824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5175579583207963577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5269643775896723397</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Notification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7516092053498031989</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6579080007561786969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NumericValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4679739485102359104</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4099952623687795850</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4967597595580536216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OrQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2962973084421716523</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QualifiedAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8832517277410933254</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QueryEval</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2675899265640874796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ReflectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9170809325636915553</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeErrorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>704338937753949796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5274912751982730171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeOperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8408923047489133588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ServiceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3990675661956646827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.StringValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3256390509806284044</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.MLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3636148327800330130</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.PrivateMLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2503458973393711979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.DescriptorSupport$FieldName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2645619836053638810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.InvalidTargetObjectTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1190536278266811217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6181543027787327345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3862947819818064362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1935722590756516193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7445681389570207141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6532732096650090465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.XMLParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3176664577895105181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4608189663661929204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorSettingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8807913418190202007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.ArrayType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>720504429830309770</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8003518976613702244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5366242454346948798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4224269443946322062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidOpenTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2837312755412327534</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.KeyAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1845183636745282866</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenDataException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8346311255433349870</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanAttributeInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4867215622149721849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanConstructorInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4400441579007477003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4349395935420511492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanOperationInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4996859732565369366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanParameterInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7235016873758443122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9195195325186646468</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.SimpleType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2215577471957694503</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5720150593236309827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6554071860220659261</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationIdException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7115040321202754171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationServiceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3400722103759507559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3007446608299169961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleInfoException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7517834705158932074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2066091747301983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.MBeanServerNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2605900539589789736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5434016005679159613</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3793951411158559116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6871117877523310399</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationServiceNotRegisteredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8454744887157122910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1274155316284300752</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4611072955724144607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.Role</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-279985518429862552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2504952983494636987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfoNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4394092234999959939</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568344346499649313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2986406101364031481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6304063118040985512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolved</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-48350262537070138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolvedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4054902803091433324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerAlarmClockNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4841061275673620641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1798492029603825750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5433838894743521833</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.ResourceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>547071213627824490</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.cci.ResourceWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1233859030030360576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ApplicationServerInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7784532393279374430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.CommException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5000980212339163591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5611772461379563249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.EISSystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5753172122428814004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3473092818417322126</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.InvalidPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-485903720300735741</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.LocalTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7495828853103281459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAdapterInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1666678251804763325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9036793565852998502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7609456980660658364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SharingViolationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1280304091132682215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.UnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2495485036033570467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.security.PasswordCredential</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1770833344350711674</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkCompletedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-229158982387790244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3063612635015047218</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6360106395593829940</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkRejectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-687129544691878081</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBMethodPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.PolicyContextException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3925692572777572935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.WebRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4843217645290030002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.RowSetEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1875450876546332005</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicCommitException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3977609782149921760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicMixedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2345014349685956666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicRollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3483618944556408897</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.InvalidTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3597320220337691496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56870312332816390</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.RollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4151607774785285395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.SystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>839699079412719325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRequiredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1898806419937446439</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRolledbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3142798139623020577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.xa.XAException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249683284832867751</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.InvalidRequestException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125274674633362305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.JAXRException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396751348710944315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnexpectedObjectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2574981241743874017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnsupportedCapabilityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8122771280181567405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3564726132985118351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.Logo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259395942230563981</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7370065421049434357</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.AssertionFailedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6907951573723054750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.ComparisonFailure</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>544727012405451845</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6586601571607744836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.CounterPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2687873538635785002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackEntryRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1593293433761006310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackTraceListModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5938404479084696616</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.FailureRunView$FailureListCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2197075851577592477</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1311144803912540425</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7074177803853075316</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector$TestCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8570682962687709951</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>668800626104011524</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel$TestTreeCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8412767466216926631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.commons.logging.LogConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1571584275865309127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.BaseTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9158502896034797704</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DecimalTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5105356898480069452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DefaultInfoImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2139348259136830321</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.IndexDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6494051577638099660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.MethodAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2401184375662152654</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.ReferencedColumnsDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3179877360885574252</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.RoutineAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7497340624645489559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.StatisticsImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4230393571147690926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.SynonymAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7810655070530271744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.TypeDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1288873888464524292</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.UserDefinedTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1799056355106710647</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.PassThroughException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3924642559467241441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.StandardException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8401633304649510414</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.cache.ClassSizeCatalog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6685327926445367733</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.classfile.Attributes</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1099922852895717904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.context.ShutdownException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-645255578941026919</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableArrayHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7722110452690226158</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableBitSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5177032461701961274</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9217193027129228620</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableIntHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628901830438778174</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableLongHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2650935220890598731</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1261261812413152266</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.depend.ProviderList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1366316628366847681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ColumnDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7414254430400923209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3867714944990476760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConstraintDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9037236679505216655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.GenericDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5295661333964883709</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.IndexRowGenerator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396538115441163883</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.TriggerDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-32469460606663392</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BigIntegerDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6318859761250203938</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BinaryDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5065454889050820246</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>301846662550352624</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataTypeDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56556292147865290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.JSQLType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6451737721593126039</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.NumberDataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2066913646534046755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBinary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2008438053333525328</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6638242629038410928</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBlob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697148507752332091</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBoolean</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5355826037058878832</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7976942440508199363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1202486554803122153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131035439424602061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4378598181224076768</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDouble</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3822433179233268622</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLInteger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8029534526043984426</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1540374351701611931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8157908992464919846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6618410970032962999</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-446455822150186304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5494340817457030212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5729633983927814888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6114609753457690185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLReal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6662944418729556978</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7211707249890696662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLSmallint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656859080434357609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4960299321851845821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTimestamp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6699781998014238614</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTinyint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3346531739133554042</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7951316506023190146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9154682651959409373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.TypeId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6712082221658633481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.UserType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1509003486518586988</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.XML</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7971776932772322331</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.util.DoubleProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2076176637991999421</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1009680591218740739</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile4</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8284143012912643841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4219230464646904320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804867918856204209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.cache.Clock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4312236320685380467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1206928593820632969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7678562473138491542</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.SinglePool</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7590648805367396975</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.monitor.UpdateServiceProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3741799138583058</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.uuid.BasicUUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3718151411232522413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4205329841347723821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorTableReference</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3487536779172920366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericColumnDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7391106685059283619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericResultDescription</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3250426016516532351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericStorablePreparedStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3307116410564599887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDColumnDependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-307206005961795666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DD_Version</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2578720014869961765</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDdependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1247784083094214331</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1968719239585371136</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6181718236993016793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.depend.BasicProviderInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6374500732560413607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6434920470936692312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfoList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3728683433925045535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AvgAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6588649172656353059</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ColumnInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795056845881766606</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ConstraintInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>907666986420613861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.CountAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>992685372833802847</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.DeleteConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8798662232746826004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.FKInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3645578133017885992</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexColumnOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5381802041848503659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6243277153338447053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.InsertConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9215984254597417967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.MaxMinAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6200973283828785051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.OrderableAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2548979559445856799</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SumAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2191968389560168342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SystemAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3363041046814554907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.TriggerInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5992967508621942134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdatableVTIConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1069674386524766701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdateConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-304225507996092831</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ValueRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-603613513999118017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.WriteCursorConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2555675739166589204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.PC_XenaVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7676884750261258364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.StorableFormatId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1055887996755577717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.UTF</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5523513719371189796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.BTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2806000041739135492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.WaitError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5285171848922420095</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2I</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232442507446656804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IStaticCompiledInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8400452328864426824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IUndo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-762791196902980249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.conglomerate.GenericConglomerate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4250310482563395080</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.Heap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5902040921459274872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.HeapRowLocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4289598659775108088</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocExtent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-964942574996053618</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1904475501742389367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ChainAllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7025016240618679279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CompressSpacePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2686965541794407374</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4895368432786554430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>737643866048984133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1694580053106123087</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CopyRowsOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5298806023002438329</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.DeleteOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8634310601289456663</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InitPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-653697683164018124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InsertOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7372197412796385217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InvalidatePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3029903537053186655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>931621854183206917</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6379497936871106083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LongColumnException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8355712046325811247</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.NoSpaceOnPage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5705728020085434337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PageBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4495032194360898129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8395034761202954774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1629730437784173653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PurgeOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1815947391742392482</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.RemoveFileOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9128463506137321686</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.SetReservedSpaceOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452338843997645457</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateFieldOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8729716610518008479</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5022439034409403549</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.CheckpointOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3547334483634107987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.ChecksumOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2603075230783601529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6822213548599245381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6549540354718798294</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.BeginXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1675099279475574863</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.EndXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3814049087240034502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.GlobalXactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3675162292673048435</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7367956979044103797</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTableEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7684636587849580178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.XactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2802828528732192420</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedConnectionPoolDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7852784308039674160</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4945135214995641181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedXADataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5715798975598379738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.ReferenceableDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1872877359127597176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.ProvisionNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4479121426311014469</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.RollingCalendar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3560331770601814177</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5695670494782816506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.DetailPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-183716192697269830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>396456838584537074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.LoadXMLAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1959519697665333576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.Main</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6679218458268861656</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.MyTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2394739789728444307</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.config.PropertySetterException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1352613734254235861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.AbsoluteTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-388856345976723342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.DateTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5547637772208514971</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.ISO8601DateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-759840745298755296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.RelativeTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7055751607085611984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.Log4JLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6229073500826714757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5251735053323350105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevelFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4274666161838212273</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3544820201891844767</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.util.AdapterLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5682197585320945004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.FilteredLogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8992671089131499904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4867085140195148458</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4275827753626456547</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumnFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6529165785030431653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593300685868700894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableRowRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3951639953706443213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3413887384316015901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8066257446951323576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5958994817693177319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeEditorRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6094804684259929574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6046702673278595048</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LocationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1325822038990805636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LoggingEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-868428216207166145</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.ThrowableInformation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4748765566864322735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.ClassInstanceAdvisor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3057976129116723527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.DispatcherConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1502745917111812781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.NotFoundInDispatcherException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5020740195889379757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.advice.Scope</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7873910692644730377</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.AnnotationParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>122998472196736778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8256510811060336766</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.instrument.TransformationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9087730534133925094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.CallerInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303974658</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303875808</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7005423783330774114</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4671110715707463304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3045541205784967429</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1003170617993582707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6968523285026078131</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7880020293056198584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1092370003103163067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776393748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3337041720097890861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7595351292713886213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6795964118579848645</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5435217977419419783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationBase</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4880246394729260729</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2974596986988236395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6156314852981932065</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4578273471486761147</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7826653633415463825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3078730663855284320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1313717554016611763</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6399861718513077210</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3873275588469743345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData$MetaDataValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8024138149680591337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6640507307072022813</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.PointcutExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4076294802573243474</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7207593606482597998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TypeExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588935251567280090</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ClassProxyTemplate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7776009946350762531</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledClassProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4049171769644464715</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledInterfaceProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7939451715003985857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.Proxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040609385293748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2451434088790560691</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMixin</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6150046185716362835</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.standalone.Package</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6188655039267365373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7688683906350419871</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.CacheException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-343717717992472642</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ConfigureException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1937579864964670681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Fqn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5351930616956603651</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.GlobalTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8011434781266976149</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Modification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3074622985730129009</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5040432493172658796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.NodeNotExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>779376138690777440</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.OptimisticTreeNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3497174028709124136</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.RegionNotEmptyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ReplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2141504272926290430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.SuspectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2965599037371850141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8576324868563647538</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593129982953807846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568518714172267901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8895044368299888998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1578599138419577069</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5577441016277949170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3796901116451916116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8985697625953238855</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1242167331988194987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7656592171312920825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7084928639244438800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$CommitTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5426108920883879873</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$EvictAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6007500908549034215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5364163916172148038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$LoadAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6998760732995584428</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4882445905140460053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2171307516592250436</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6894888234400908985</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3746013603940497991</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RollbackTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4836748411400541430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$StartTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7059131008813144857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.AOPInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6492134565825613209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7044654602510185865</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8035968024123769723</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1846726449742865362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3309349735197545040</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3391522498362829190</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1547808705937201967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-856964838566617006</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>116863545772054467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-402153636437493134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.EvictionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4006783737166646935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6796150029431162837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.NodeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7571995794010294485</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.rmi.RemoteTreeCacheImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3096209368650710385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.DeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8651993450626741020</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5551396474793902133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.OwnerNotExistedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2837393571654438480</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8096787619908687038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.UpgradeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5683212651728276028</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.MarshallingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5991339859063633060</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7719282503234213209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7321547249627414140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.DefaultDataVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9086186758698005849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.FqnComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7907781088049142376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.rpc.NoHandlerForRPCException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.BatchModeTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656602677430350961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyBaseTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6716097342564237376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4396695354693176535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyUserTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6568400755677046127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1416258464473965574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131841473723490707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentState</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2319062412502366783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.IncompleteDeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1428860525880893167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SerializableDeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3847995513551913798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SubDeployerSupport$ClassConfiguration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2716929675748339631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7679468692447241311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3507018102770233526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5117370636698417671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6460196085190851775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-718723094688127810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5436722659170811314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.ServiceUnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3739642441706165948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.http.interfaces.HttpInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249272784108192267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3713605626489646730</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.server.JRMPInvoker_Stub</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-728630295444149842</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1265347772036749711</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.ServerAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7206359745950445445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.lang.Enum</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8923967787677833913</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.DynamicLogger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5963699806863917370</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.Logger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232175575988879434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.capability.OptimizedMBeanDispatcher$MethodEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1792631947840418314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.interceptor.InterceptorNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-696843094576327612</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.loading.LoaderRepositoryFactory$LoaderRepositoryConfig</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226952985429700362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.metadata.IllegalPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1025239559959501272</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.notification.NotificationFilterProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.ServerObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1829209376363828441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5392945073280632822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.InstanceOfQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5765353862268810105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7441880585611238427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6442164418782871672</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JMXInvocationHandler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3714728148040623702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.MBeanProxyCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1008637966352433381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.RuntimeProxyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1166909485463779459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.ExternalContext$SerializableInitialContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6512260531255770463</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.LinkRefPair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6036946190113161492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.DefaultSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7626239955727142958</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.QueuedClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6566809337830221375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.RMIMultiSocketClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-945837789475428529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-920483051658660269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutServerSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7006964274840965634</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1841403351768037738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.InvalidAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>785817154841571537</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.MissingAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2104972080882639099</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ServiceContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7461263042948325633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.filterfactory.DeploymentInfoNotificationFilterFactory$DeploymentInfoNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5067618040005609685</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.AbstractNestedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7384049506870825781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.CoercionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3248954334700890176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7736259185393081556</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6024309396861726945</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2161377898611431781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4683457706354663230</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1803971437884946242</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.DataConversionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6287439477349036488</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.EmptyStringException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7958716001355854762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.HashCode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2391396931740264021</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.JBossStringBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1874946609763446794</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1615297462859270139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8903330696503363758</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8902748795144754375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2584758778978644599</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6720507617603163762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4135571897343827853</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7003381223684751953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9017248167673450852</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8348882503434035185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NoSuchMethodException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3044955578250977290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotCoercibleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125062352267547279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotImplementedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3915801189311749818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-403173436435490144</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NullArgumentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2308503249278841584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6077429788585907990</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace$Entry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7013023772762859280</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628094303187435707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6284244000894114817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6859401939735540773</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnexpectedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4318032849691437298</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnreachableStatementException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6741968131968754812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ArrayIterator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6604583440222021075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1470947618739421094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CompoundKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1181463173922935047</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.EmptyCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4562591066479152759</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.FullCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795773071357559465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ListSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7333619218072079496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.SerializableEnumeration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8678951571196067510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.deadlock.ApplicationDeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-908428091244600395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.GUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3289509836244263718</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.UID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8093336932569424512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.VMID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4339675822939194520</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.platform.PID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6837013326314943907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyContainer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3347198703863412326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4956548740655706282</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5007209897739884086</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452085442436956822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyGroup</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2557641199743063159</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8747802918099008518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.state.IllegalTransitionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3392564168782896452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.BlockingMode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9102277941374138830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.StartTimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2287779538710535096</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.TaskStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5166095239829218680</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolFullException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1044683480627340299</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8732248855455909385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8229078720076583113</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-33504134223704483</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3196504305414545949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3813878809953971710</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-62219642166721806</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>615315465309975801</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.TypeBinding</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2815361862736153588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5172168752255182905</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3540265999209053491</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelNotConnectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6701630538465783064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3786054325601841062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.MergeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2682174976989815032</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.Message</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1137364035832847034</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.SuspectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6663279911010545655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3555655828017487825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.View</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4533382418778234665</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ViewId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2194604680465610696</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4974051451573194550</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$AcquireLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6598500471822545410</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$LockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5614003065708878672</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$ReleaseLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3535306842096930972</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4448104853965887333</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotGrantedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4074824788210185433</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotReleasedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-350403929687059570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-712594616520011007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$AllLinksDown</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3329785688905216843</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$NoLinksAvailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5250951711707663051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.MethodCall</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7873471327078957662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.NotificationBus$Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6133287486444083527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.PullPushAdapter$PullHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-425784033525973495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2719268809250178946</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8654791037075308304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6627736371945009800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7996418731426358548</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicationData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3945713445332028341</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.RequestCorrelator$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6218812100438796010</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.TwoPhaseVotingAdapter$TwoPhaseWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5874214163436160067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.UpdateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4196360091623991749</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-878345689312038489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$FailureVoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2809813561621497082</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$VoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3613490568129896140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.Xid</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4409463369646897707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.ProtocolSpecificView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7896517829304370211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.QUEUEView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7798060311888236141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.CausalMessage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>780718666884109552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedHashtableDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4702508639852294344</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedQueueDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7622390100963225361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedTreeDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-565717619547736367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2259064207678152243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw2Channels$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-159139558962652075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DrawCommand</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-539152912005072037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$Command</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4589357003632171240</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$MyPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3949118385264358535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>830341371019288303</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5880115553330291212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.QuoteClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6330572389849611533</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5845856017238569017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1981454998903219877</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-844842002708012312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4254284786559213346</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884349667401210895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7021074808114540717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Topology</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1573646619876712993</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotOrderRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8946333513205704225</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3913436032289156789</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-949231907799007987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ColorPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3802922492190502041</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7659975100736213568</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$StackPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7585339684267647405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TotalPayload</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-936838583748491815</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TransmitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4976326672958441937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.applets.DrawApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5424670476092532936</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.ApplFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3111759067157049661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.GraphPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2614867219673231568</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.MessageDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2502100249420840495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1397067405132982188</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.SendDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3758787152935146447</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.UserInfoDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4133061180336572911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Whiteboard</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2274303019457050327</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7472528586067210747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotCreateSchemaException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>291582260022140141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotPersistException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5157400778265186170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5777024088921236116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRetrieveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2523227229540681597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.BSH$BshHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4576592161896066369</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.CAUSAL$CausalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5498836339436997735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.COMPRESS$CompressHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9007677999985085671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1750370226005341630</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2196297653127166373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT14KeystoreTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>468730481838883343</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT1_4$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4903164192583500536</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPTAsymmetricTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1481286172666845689</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ExampleHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1142160965073499584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FC$FcHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7827029202013659594</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5616292129142554109</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PID$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4600042790162330443</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PROB$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6777017945644585942</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SIMPLE$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1167997177583945633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SOCK$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8516198663141898078</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FLOW_CONTROL$FCInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5533195698941348382</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FragHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>303445567493545979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.HTOTAL$HTotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5191852668378595581</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.JMS$JMSAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2665329356255842841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE$MergeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6346602920868031157</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE3$CoordAnnouncement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5948313354065175200</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGEFAST$MergefastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-782778793678079625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MyFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>487398390724731968</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8532981008982895761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PARTITIONER$PartitionerHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8563054383219742124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PIGGYBACK$PiggybackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1931866452789177725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1321354690148853821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2617261140193045024</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1958058124186816135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3634334590904551586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.SMACK$SmackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8177663976610985214</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.StateTransferRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5881488678259966263</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7091158323788670702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_OLD$TotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3457318931485225599</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$RingTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4983650106365326055</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$TotalTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697698829445754100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TcpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5866113771133701445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TransportedVectorTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1603566195889830614</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TunnelHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7822714431468070313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UNICAST$UnicastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5363480203591236450</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UdpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3935211140277615207</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.VERIFY_SUSPECT$VerifyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1941838263961448659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WANPIPE$WanPipeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1626305070273536659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WanPipeAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2704805420827050111</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7645538507245078868</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.GMS$GmsHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2448333506445159147</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Gossip</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7954243278668401185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.JoinRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6649266592397456151</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.MergeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1496122908046351262</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8624127273776057099</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.PbcastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6557298950278459935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STABLE$StableHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5722541602835160473</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STATE_TRANSFER$StateHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8634851404722847649</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.RingToken</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5130788718652902761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.TokenLostException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5113234317099931071</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.DenyResponseHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8163036803592200794</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseDeniedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-846586020199773038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6933466840087221613</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseFactoryService$LeaseInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3444050623220620496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseInfoReplicationHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5304536941840240874</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseRequestHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9209612480415121567</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseResponseHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3874052770561705701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.RecursiveLeaseRequestException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1831708130008979859</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.UnknownLeaseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6671687259988247051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.GossipData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2701708796024030817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.IpAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6332171047247548699</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.LogicalAddress1_4</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2275816655325808792</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryPacket</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2592954324310791792</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7587678128986493349</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6862354518175504139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.EncryptOrderTestHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-122667245978500378</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.GroupRequestPull$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2311007561500635146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PartitionerTest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4585450199569162213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PerfTest$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8693769141297219569</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.QueueTest2$MyQueue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5186485528289936315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Data</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8623669553705606167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$StartData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2149929336279677323</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Value</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1784650063567334404</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest2$UnicastTest2Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7649416783110380750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptjms.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3593032375684821491</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptudp.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1467866650151597943</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.perf.Data</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8306465039303685969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.perf.MemberInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1808690327914209633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.BoundedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7424651402352421757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.List</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2387756625721721326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Proxy1_4$MyInetSocketAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1915728442156280395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.QueueClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7575787375592873964</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Range</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1895551925607652646</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Stack</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2156560026798275993</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.TimedWriter$Timeout</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4848606759617898619</long> 
  +  </void> 
  + </object> 
  +</java> 
  
  
  
  1.1.2.1   +8779 -0   JBossCache/etc/svuid-db/Attic/svuid-14.1.4.0.GA.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: svuid-14.1.4.0.GA.xml
  ===================================================================
  RCS file: svuid-14.1.4.0.GA.xml
  diff -N svuid-14.1.4.0.GA.xml
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ svuid-14.1.4.0.GA.xml	23 Dec 2006 12:03:29 -0000	1.1.2.1
  @@ -0,0 +1,8779 @@
  +<?xml version="1.0" encoding="UTF-8"?> 
  +<java version="1.4.2_10" class="java.beans.XMLDecoder"> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.BrokenBarrierException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-147457780021240026</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6714594232516465772</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-273293065942834887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4374456568832557570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap$BarrierLock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4525944060243092775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7462087621709176033</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArraySet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7377569541496517854</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.PropertyChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2015832332684279521</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3131847742139976720</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.VetoableChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1658935129351293677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAllocationExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5206070850678934963</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAmbiguousName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5463192617696168744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArguments</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-585523412586448725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayDimensions</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7421434457381110734</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayInitializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8700933638077559442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAssignment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5786492369725521120</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBinaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2762482415254161500</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBlock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6768276487850608921</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHCastExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7470063802377582745</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHClassDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937995350116520528</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHEnhancedForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6186147054579461507</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7948089581379394413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalComment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6286509731094061726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>885501998857403574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameters</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5377216513908772736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHIfStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8630320869909994701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHImportDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6358892934545928949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHLiteral</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9207502592290153353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3910140293232619649</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3850040841809657514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPackageDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3898847231539731472</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-503393472352053812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimarySuffix</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1787222033238474243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimitiveType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-329589427159246987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2752610538670204146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6533667932058465861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHStatementExpressionList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6321165101746983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchLabel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5975475021538911876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5655955042808726899</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTernaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1606563852196299305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHThrowStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1240271051305696705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTryStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7478089655732292849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3430943699278719269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTypedVariableDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1227389047756718948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHUnaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1356335365378375412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHVariableDeclarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8458315290118837535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHWhileStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-268607334595851302</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BlockNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2687158869589601405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6335918737638083070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Capabilities$Unavailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3399055441689407911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ClassPathException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4486900461219339615</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.DelayedEvalBshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3354511033240459040</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.EvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3716899742529067922</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ExternalNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5243541843670468747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Interpreter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8662818442204412948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.InterpreterError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>492955139343282635</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.LHS</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6459038804384583967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Modifiers</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8471185022017946576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Name</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1368962988105189185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.NameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2499232412105981353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7776137309758821134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Parser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1080445658583023363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1164390191642946889</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive$Special</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3358001335405681566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ReflectError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2866156013797271636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5443864013386003037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5414610443216917980</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2695405703637847608</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.This</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9164318017112736976</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Token</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1762483667756877906</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5931514358210053837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilEvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8152371752278016844</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilTargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3189155544820014872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3903315982083174172</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6803452281441498586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis$Handler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4949939576606791809</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.BshClassPath$UnqualifiedNameTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3781441989565933164</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.DiscreteFilesClassLoader$ClassSourceMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5512817511949635338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4449346005537544077</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4666331393709464197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8135609692397819965</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.BshCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5388205109589610178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7209531634233769565</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser$PackageTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5706938369034888760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4328339671783920384</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>511965521903648517</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8369148428197760566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4878413495152524714</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.NameCompletionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6402387817755043296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.JavaDocBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6416423833804352641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractInheritableJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9023782913479355888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2524636196290199193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.ClassLibrary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937822024500756265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3485584001530088379</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3826651908494651111</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaClass</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56717871423934265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaField</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5158976028974024460</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5243360122899135505</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>179251600928831072</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3633306177895408984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.Type</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1596228041010255947</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.parser.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5318681457549236818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5125104124988065132</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1696027756378506682</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6126250255117957129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3907099389150076506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259049612296041412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6072271561424686085</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6253738640542714864</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8341335540288476967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6541451738732568309</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5928371437429336297</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4989418639347196543</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4388663746486043332</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6774847732447034836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4531243655467066716</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8199402162587347927</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1867106235561680513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5182945951854128074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2353400642617702135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8009749324757823162</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1386004770507927487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6518377914521265924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5027933992067738953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3219031174271773941</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2983928040263651920</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8221776374808491901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2668179591598315903</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkableAdaptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5304617132327526103</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8255356362445153793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226598894953083600</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5836847517986682456</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3985641094402692577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1484566617740723084</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1131655762826131576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3534490007366143774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1604113897169961576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8218345469653233169</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1314195772401372924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4261907982787552070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6169609859379733351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIdentityHashingStrategy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9078971529298567003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5135986634343398216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7205369688399131238</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CannotCompileException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4347542786236949387</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.ClassMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804593026213805083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CtClass$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3010032700700443882</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.NotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3351646634891239203</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.AlignmentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8236846960668290894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.BadBytecode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3276990049810168442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.CodeAttribute$RuntimeCopyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6805061409088364619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.CompileError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3050226843070987526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.KeywordTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5199030078030817932</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.NoFieldException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4412708214950596625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SymbolTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5270810980735558192</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SyntaxError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>490889194191819310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3901587593786844134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2799997277816596178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ArrayInit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2455192015828220874</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.AssignExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4621657704473821336</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.BinExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>493705937276265737</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CallExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6467190087868486053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CastExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4282802057512523201</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CondExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5259064316096978698</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Declarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7623658853007847572</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.DoubleConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7520025738220931295</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Expr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4954272843196512706</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.FieldDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2740715577722591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.InstanceOfExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4884917690955972361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.IntConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8467565945324056444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Keyword</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-441109204299464211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Member</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8058663079822722722</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.MethodDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6143642298594142396</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.NewExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1149608066531689319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Pair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4983294681996546807</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Stmnt</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9161016440925075705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.StringL</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4872959613607194275</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Symbol</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6360767401848368660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3042823100727688513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4807719830136336780</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotInvokeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8414032860369172220</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotReflectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3829918668979165876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.ClassMetaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1446514439423711708</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.Metaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2488206368319211804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectImporter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6932897352659865446</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2947053296940077756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3933064703890332122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2414585153283929621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.web.BadHttpRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9044749387914005083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.AccessLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4089104928924996726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.CreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6295951740865457514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.DuplicateKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7287399994705270076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.EJBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>796770993296843510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.FinderException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8785983102057433621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchEntityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4815730078295420703</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchObjectLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9151491108833037318</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4624364141026778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.RemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4581849053220157910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRequiredLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884174204131319153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRolledbackLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2897658132751784821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.model.exceptions.DDBeanCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8433252794388831851</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.BeanNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3319141583318924489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ClientExecuteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3580202712793889609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6211997126760402756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3061110807000384518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DeploymentManagerCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1322593937994224595</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.InvalidModuleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3478551028858955312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8564794200621186554</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.TargetException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4774441890984466267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.status.ProgressEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7815118532096485937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6850763061112244487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidClientIDException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2410181719763491702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidDestinationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588063794606036755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidSelectorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6223038613086963841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8951994251593378324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSSecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7512859695190450217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageEOFException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4829621000056590895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3642297253594750138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotReadableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8044835867550650748</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotWriteableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4241931174711518830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1172695755360706776</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionInProgressException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5611340150426335231</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionRolledBackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9157976009672865857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AndQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Attribute</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2484220110589082382</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>535176054565814134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6347317584796410029</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4077085769279709076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6511584241791106926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7768025046539163385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadAttributeValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3105272988410493376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadBinaryOpValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5068475589449021227</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadStringOperationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7802201238441662100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BetweenQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2933597532866307444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryOpValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1216286847881456786</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryRelQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5690656271650491000</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BooleanValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7754922052666594581</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ClassAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5801329450358952434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8893743928912733931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-882579438394773049</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.IntrospectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1054516935875481725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidApplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3048022274675537269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidAttributeValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2164571879317142449</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>350520924977331825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6573344628407841861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ListenerNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7242605822448519061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8644704819898565848</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4433990064191844427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4066342430588744142</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanFeatureInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3952882688968447265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6451021435135161911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3888371564530107064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6178860474881375330</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanParameterInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7432616882776782338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2416928705275160661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanRegistrationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4482382455277067805</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2876477500475969677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5661980843569388590</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission$MBeanServerPermissionCollections</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4111836792595161197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanTrustPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2952178077029018140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MalformedObjectNameException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-572689714442915824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5175579583207963577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5269643775896723397</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Notification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7516092053498031989</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6579080007561786969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NumericValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4679739485102359104</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4099952623687795850</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4967597595580536216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OrQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2962973084421716523</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QualifiedAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8832517277410933254</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QueryEval</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2675899265640874796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ReflectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9170809325636915553</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeErrorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>704338937753949796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5274912751982730171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeOperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8408923047489133588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ServiceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3990675661956646827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.StringValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3256390509806284044</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.MLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3636148327800330130</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.PrivateMLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2503458973393711979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.DescriptorSupport$FieldName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2645619836053638810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.InvalidTargetObjectTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1190536278266811217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6181543027787327345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3862947819818064362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1935722590756516193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7445681389570207141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6532732096650090465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.XMLParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3176664577895105181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4608189663661929204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorSettingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8807913418190202007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.ArrayType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>720504429830309770</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8003518976613702244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5366242454346948798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4224269443946322062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidOpenTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2837312755412327534</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.KeyAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1845183636745282866</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenDataException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8346311255433349870</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanAttributeInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4867215622149721849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanConstructorInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4400441579007477003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4349395935420511492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanOperationInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4996859732565369366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanParameterInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7235016873758443122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9195195325186646468</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.SimpleType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2215577471957694503</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5720150593236309827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6554071860220659261</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationIdException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7115040321202754171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationServiceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3400722103759507559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3007446608299169961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleInfoException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7517834705158932074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2066091747301983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.MBeanServerNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2605900539589789736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5434016005679159613</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3793951411158559116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6871117877523310399</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationServiceNotRegisteredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8454744887157122910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1274155316284300752</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4611072955724144607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.Role</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-279985518429862552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2504952983494636987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfoNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4394092234999959939</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568344346499649313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2986406101364031481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6304063118040985512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolved</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-48350262537070138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolvedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4054902803091433324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerAlarmClockNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4841061275673620641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1798492029603825750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5433838894743521833</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.ResourceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>547071213627824490</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.cci.ResourceWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1233859030030360576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ApplicationServerInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7784532393279374430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.CommException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5000980212339163591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5611772461379563249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.EISSystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5753172122428814004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3473092818417322126</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.InvalidPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-485903720300735741</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.LocalTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7495828853103281459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAdapterInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1666678251804763325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9036793565852998502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7609456980660658364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SharingViolationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1280304091132682215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.UnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2495485036033570467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.security.PasswordCredential</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1770833344350711674</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkCompletedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-229158982387790244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3063612635015047218</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6360106395593829940</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkRejectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-687129544691878081</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBMethodPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.PolicyContextException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3925692572777572935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.WebRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4843217645290030002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.RowSetEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1875450876546332005</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicCommitException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3977609782149921760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicMixedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2345014349685956666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicRollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3483618944556408897</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.InvalidTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3597320220337691496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56870312332816390</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.RollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4151607774785285395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.SystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>839699079412719325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRequiredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1898806419937446439</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRolledbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3142798139623020577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.xa.XAException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249683284832867751</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.InvalidRequestException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125274674633362305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.JAXRException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396751348710944315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnexpectedObjectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2574981241743874017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnsupportedCapabilityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8122771280181567405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.btree.BPage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.btree.BTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.ByteArrayComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.ByteArraySerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.CacheEvictionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6024886898553870353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.DefaultSerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3818545055661017388</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.IntegerComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.IntegerSerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8683732630163314356</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.IterationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5320108524567522710</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.LongComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.LongSerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7980451649962070585</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.ObjectBAComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.StringComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.WrappedRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4046883237946202808</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.htree.HashBucket</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.htree.HashDirectory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.htree.HashNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5640415117406368094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.recman.BlockIo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3564726132985118351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.Logo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259395942230563981</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7370065421049434357</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.AssertionFailedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6907951573723054750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.ComparisonFailure</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>544727012405451845</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6586601571607744836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.CounterPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2687873538635785002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackEntryRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1593293433761006310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackTraceListModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5938404479084696616</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.FailureRunView$FailureListCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2197075851577592477</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1311144803912540425</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7074177803853075316</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector$TestCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8570682962687709951</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>668800626104011524</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel$TestTreeCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8412767466216926631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.commons.logging.LogConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1571584275865309127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.BaseTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9158502896034797704</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DecimalTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5105356898480069452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DefaultInfoImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2139348259136830321</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.IndexDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6494051577638099660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.MethodAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2401184375662152654</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.ReferencedColumnsDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3179877360885574252</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.RoutineAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7497340624645489559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.StatisticsImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4230393571147690926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.SynonymAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7810655070530271744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.TypeDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1288873888464524292</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.UserDefinedTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1799056355106710647</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.PassThroughException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3924642559467241441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.StandardException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8401633304649510414</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.cache.ClassSizeCatalog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6685327926445367733</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.classfile.Attributes</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1099922852895717904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.context.ShutdownException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-645255578941026919</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableArrayHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7722110452690226158</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableBitSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5177032461701961274</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9217193027129228620</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableIntHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628901830438778174</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableLongHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2650935220890598731</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1261261812413152266</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.depend.ProviderList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1366316628366847681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ColumnDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7414254430400923209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3867714944990476760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConstraintDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9037236679505216655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.GenericDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5295661333964883709</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.IndexRowGenerator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396538115441163883</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.TriggerDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-32469460606663392</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BigIntegerDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6318859761250203938</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BinaryDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5065454889050820246</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>301846662550352624</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataTypeDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56556292147865290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.JSQLType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6451737721593126039</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.NumberDataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2066913646534046755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBinary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2008438053333525328</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6638242629038410928</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBlob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697148507752332091</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBoolean</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5355826037058878832</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7976942440508199363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1202486554803122153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131035439424602061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4378598181224076768</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDouble</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3822433179233268622</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLInteger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8029534526043984426</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1540374351701611931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8157908992464919846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6618410970032962999</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-446455822150186304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5494340817457030212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5729633983927814888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6114609753457690185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLReal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6662944418729556978</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7211707249890696662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLSmallint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656859080434357609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4960299321851845821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTimestamp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6699781998014238614</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTinyint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3346531739133554042</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7951316506023190146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9154682651959409373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.TypeId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6712082221658633481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.UserType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1509003486518586988</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.XML</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7971776932772322331</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.util.DoubleProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2076176637991999421</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1009680591218740739</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile4</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8284143012912643841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4219230464646904320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804867918856204209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.cache.Clock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4312236320685380467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1206928593820632969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7678562473138491542</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.SinglePool</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7590648805367396975</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.monitor.UpdateServiceProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3741799138583058</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.uuid.BasicUUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3718151411232522413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4205329841347723821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorTableReference</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3487536779172920366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericColumnDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7391106685059283619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericResultDescription</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3250426016516532351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericStorablePreparedStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3307116410564599887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDColumnDependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-307206005961795666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DD_Version</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2578720014869961765</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDdependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1247784083094214331</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1968719239585371136</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6181718236993016793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.depend.BasicProviderInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6374500732560413607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6434920470936692312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfoList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3728683433925045535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AvgAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6588649172656353059</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ColumnInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795056845881766606</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ConstraintInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>907666986420613861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.CountAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>992685372833802847</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.DeleteConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8798662232746826004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.FKInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3645578133017885992</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexColumnOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5381802041848503659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6243277153338447053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.InsertConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9215984254597417967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.MaxMinAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6200973283828785051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.OrderableAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2548979559445856799</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SumAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2191968389560168342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SystemAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3363041046814554907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.TriggerInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5992967508621942134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdatableVTIConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1069674386524766701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdateConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-304225507996092831</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ValueRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-603613513999118017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.WriteCursorConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2555675739166589204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.PC_XenaVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7676884750261258364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.StorableFormatId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1055887996755577717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.UTF</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5523513719371189796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.BTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2806000041739135492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.WaitError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5285171848922420095</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2I</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232442507446656804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IStaticCompiledInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8400452328864426824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IUndo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-762791196902980249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.conglomerate.GenericConglomerate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4250310482563395080</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.Heap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5902040921459274872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.HeapRowLocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4289598659775108088</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocExtent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-964942574996053618</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1904475501742389367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ChainAllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7025016240618679279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CompressSpacePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2686965541794407374</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4895368432786554430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>737643866048984133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1694580053106123087</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CopyRowsOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5298806023002438329</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.DeleteOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8634310601289456663</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InitPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-653697683164018124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InsertOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7372197412796385217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InvalidatePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3029903537053186655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>931621854183206917</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6379497936871106083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LongColumnException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8355712046325811247</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.NoSpaceOnPage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5705728020085434337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PageBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4495032194360898129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8395034761202954774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1629730437784173653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PurgeOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1815947391742392482</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.RemoveFileOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9128463506137321686</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.SetReservedSpaceOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452338843997645457</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateFieldOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8729716610518008479</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5022439034409403549</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.CheckpointOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3547334483634107987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.ChecksumOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2603075230783601529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6822213548599245381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6549540354718798294</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.BeginXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1675099279475574863</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.EndXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3814049087240034502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.GlobalXactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3675162292673048435</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7367956979044103797</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTableEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7684636587849580178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.XactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2802828528732192420</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedConnectionPoolDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7852784308039674160</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4945135214995641181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedXADataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5715798975598379738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.ReferenceableDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1872877359127597176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.ProvisionNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4479121426311014469</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.RollingCalendar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3560331770601814177</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5695670494782816506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.DetailPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-183716192697269830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>396456838584537074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.LoadXMLAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1959519697665333576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.Main</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6679218458268861656</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.MyTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2394739789728444307</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.config.PropertySetterException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1352613734254235861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.AbsoluteTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-388856345976723342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.DateTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5547637772208514971</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.ISO8601DateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-759840745298755296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.RelativeTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7055751607085611984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.Log4JLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6229073500826714757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5251735053323350105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevelFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4274666161838212273</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3544820201891844767</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.util.AdapterLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5682197585320945004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.FilteredLogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8992671089131499904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4867085140195148458</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4275827753626456547</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumnFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6529165785030431653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593300685868700894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableRowRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3951639953706443213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3413887384316015901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8066257446951323576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5958994817693177319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeEditorRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6094804684259929574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6046702673278595048</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LocationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1325822038990805636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LoggingEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-868428216207166145</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.ThrowableInformation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4748765566864322735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.ClassInstanceAdvisor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3057976129116723527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.DispatcherConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1502745917111812781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.NotFoundInDispatcherException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5020740195889379757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.advice.Scope</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7873910692644730377</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.AnnotationParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>122998472196736778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8256510811060336766</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.instrument.TransformationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9087730534133925094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.CallerInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303974658</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303875808</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7005423783330774114</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4671110715707463304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3045541205784967429</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1003170617993582707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6968523285026078131</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7880020293056198584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1092370003103163067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776393748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3337041720097890861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7595351292713886213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6795964118579848645</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5435217977419419783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationBase</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4880246394729260729</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2974596986988236395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6156314852981932065</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4578273471486761147</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7826653633415463825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3078730663855284320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1313717554016611763</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6399861718513077210</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3873275588469743345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData$MetaDataValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8024138149680591337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6640507307072022813</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.PointcutExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4076294802573243474</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7207593606482597998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TypeExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588935251567280090</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ClassProxyTemplate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7776009946350762531</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledClassProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4049171769644464715</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledInterfaceProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7939451715003985857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.Proxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040609385293748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2451434088790560691</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMixin</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6150046185716362835</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.standalone.Package</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6188655039267365373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7688683906350419871</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.CacheException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-343717717992472642</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ConfigureException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1937579864964670681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Fqn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5351930616956603651</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.GlobalTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8011434781266976149</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Modification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3074622985730129009</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5040432493172658796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.NodeNotExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>779376138690777440</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.OptimisticTreeNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7000622696587912654</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.RegionNotEmptyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ReplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2141504272926290430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.SuspectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2965599037371850141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8576324868563647538</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593129982953807846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568518714172267901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8895044368299888998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1578599138419577069</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5577441016277949170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3796901116451916116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8985697625953238855</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1242167331988194987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7656592171312920825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7084928639244438800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$CommitTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5426108920883879873</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$EvictAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6007500908549034215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5364163916172148038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$LoadAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6998760732995584428</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4882445905140460053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2171307516592250436</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6894888234400908985</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3746013603940497991</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RollbackTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4836748411400541430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$StartTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7059131008813144857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.AOPInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6492134565825613209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1242167331988194987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7656592171312920825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7084928639244438800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$CommitTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5426108920883879873</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$EvictAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6007500908549034215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5364163916172148038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$LoadAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6998760732995584428</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4882445905140460053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2171307516592250436</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6894888234400908985</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3746013603940497991</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$RollbackTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4836748411400541430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$StartTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7059131008813144857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-402153636437493134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.buddyreplication.BuddyGroup</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5391883716108410301</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.EvictionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4006783737166646935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6796150029431162837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.NodeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7571995794010294485</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.jdbm.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1337133713374690630</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.rmi.RemoteTreeCacheImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3096209368650710385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.DeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8651993450626741020</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5551396474793902133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.OwnerNotExistedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2837393571654438480</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8096787619908687038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.UpgradeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5683212651728276028</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.JBCMethodCall</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4826713878871338199</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.MarshallingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5991339859063633060</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7719282503234213209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7321547249627414140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.TreeCacheMarshaller140$InactiveRegionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9185166496920885771</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.DefaultDataVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6896315742831861046</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.FqnComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-102183636437493134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.rpc.NoHandlerForRPCException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.BatchModeTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656602677430350961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyBaseTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6716097342564237376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4396695354693176535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyUserTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6568400755677046127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1416258464473965574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131841473723490707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentState</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2319062412502366783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.IncompleteDeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1428860525880893167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SerializableDeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3847995513551913798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SubDeployerSupport$ClassConfiguration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2716929675748339631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7679468692447241311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3507018102770233526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5117370636698417671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6460196085190851775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-718723094688127810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5436722659170811314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.ServiceUnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3739642441706165948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.http.interfaces.HttpInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249272784108192267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3713605626489646730</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.server.JRMPInvoker_Stub</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-728630295444149842</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1265347772036749711</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.ServerAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7206359745950445445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.lang.Enum</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8923967787677833913</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.DynamicLogger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5963699806863917370</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.Logger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232175575988879434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.capability.OptimizedMBeanDispatcher$MethodEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1792631947840418314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.interceptor.InterceptorNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-696843094576327612</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.loading.LoaderRepositoryFactory$LoaderRepositoryConfig</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226952985429700362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.metadata.IllegalPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1025239559959501272</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.notification.NotificationFilterProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.ServerObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1829209376363828441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5392945073280632822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.InstanceOfQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5765353862268810105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7441880585611238427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6442164418782871672</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JMXInvocationHandler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3714728148040623702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.MBeanProxyCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1008637966352433381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.RuntimeProxyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1166909485463779459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.ExternalContext$SerializableInitialContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6512260531255770463</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.LinkRefPair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6036946190113161492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.DefaultSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7626239955727142958</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.QueuedClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6566809337830221375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.RMIMultiSocketClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-945837789475428529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-920483051658660269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutServerSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7006964274840965634</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.exception.SerializationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3062277762364420025</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.io.MarshalledObject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1433248532959364465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.io.MarshalledObjectForLocalCalls</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>785809358605094514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.objectmetamodel.DataContainer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3236513144029944743</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.util.ClassMetaConsts$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>667419958363983355</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.util.FastHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4949142555614032</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1841403351768037738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.InvalidAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>785817154841571537</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.MissingAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2104972080882639099</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ServiceContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7461263042948325633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.filterfactory.DeploymentInfoNotificationFilterFactory$DeploymentInfoNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5067618040005609685</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.AbstractNestedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7384049506870825781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.CoercionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3248954334700890176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7736259185393081556</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6024309396861726945</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2161377898611431781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4683457706354663230</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1803971437884946242</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.DataConversionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6287439477349036488</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.EmptyStringException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7958716001355854762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.HashCode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2391396931740264021</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.JBossStringBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1874946609763446794</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1615297462859270139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8903330696503363758</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8902748795144754375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2584758778978644599</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6720507617603163762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4135571897343827853</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7003381223684751953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9017248167673450852</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8348882503434035185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NoSuchMethodException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3044955578250977290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotCoercibleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125062352267547279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotImplementedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3915801189311749818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-403173436435490144</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NullArgumentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2308503249278841584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6077429788585907990</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace$Entry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7013023772762859280</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628094303187435707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6284244000894114817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6859401939735540773</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnexpectedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4318032849691437298</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnreachableStatementException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6741968131968754812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ArrayIterator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6604583440222021075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1470947618739421094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CompoundKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1181463173922935047</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.EmptyCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4562591066479152759</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.FullCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795773071357559465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ListSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7333619218072079496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.SerializableEnumeration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8678951571196067510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.deadlock.ApplicationDeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-908428091244600395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.GUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3289509836244263718</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.UID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8093336932569424512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.VMID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4339675822939194520</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.platform.PID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6837013326314943907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyContainer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3347198703863412326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4956548740655706282</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5007209897739884086</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452085442436956822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyGroup</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2557641199743063159</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8747802918099008518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.state.IllegalTransitionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3392564168782896452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.BlockingMode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9102277941374138830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.StartTimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2287779538710535096</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.TaskStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5166095239829218680</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolFullException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1044683480627340299</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8732248855455909385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8229078720076583113</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-33504134223704483</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3196504305414545949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3813878809953971710</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-62219642166721806</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>615315465309975801</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.TypeBinding</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2815361862736153588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5172168752255182905</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6041194633384856098</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelNotConnectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6701630538465783064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3786054325601841062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.MergeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8985324000079821575</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.Message</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1137364035832847034</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.SuspectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6663279911010545655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3555655828017487825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.View</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7951521970381323220</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ViewId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2406586625701309394</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4974051451573194550</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$AcquireLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6598500471822545410</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$LockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2390958863499216170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$MultiLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4891399452467586184</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$ReleaseLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3535306842096930972</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4448104853965887333</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockMultiLockedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3719208228960070835</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotGrantedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4074824788210185433</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotReleasedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-350403929687059570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-712594616520011007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$AllLinksDown</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3329785688905216843</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$NoLinksAvailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5250951711707663051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.MethodCall</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7873471327078957662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.NotificationBus$Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6133287486444083527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.PullPushAdapter$PullHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-425784033525973495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2839144558164277978</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8654791037075308304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6627736371945009800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7996418731426358548</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicationData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3945713445332028341</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.RequestCorrelator$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1355113470549886388</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.TwoPhaseVotingAdapter$TwoPhaseWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5874214163436160067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.UpdateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4196360091623991749</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-878345689312038489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$FailureVoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2809813561621497082</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$VoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3613490568129896140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.Xid</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4409463369646897707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.ProtocolSpecificView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7896517829304370211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.QUEUEView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7798060311888236141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.CausalMessage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>780718666884109552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedHashtableDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4702508639852294344</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedQueueDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7622390100963225361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedTreeDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-565717619547736367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2259064207678152243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw2Channels$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-159139558962652075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DrawCommand</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-539152912005072037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$Command</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4589357003632171240</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$MyPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3949118385264358535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>830341371019288303</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5880115553330291212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.QuoteClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6330572389849611533</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5845856017238569017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1981454998903219877</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-844842002708012312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4254284786559213346</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884349667401210895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7021074808114540717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Topology</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>236052619433869252</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotOrderRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8946333513205704225</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3913436032289156789</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-949231907799007987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ColorPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3802922492190502041</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7659975100736213568</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$StackPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7585339684267647405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TotalPayload</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-936838583748491815</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TransmitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4976326672958441937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.applets.DrawApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1812007671597941681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.ApplFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3111759067157049661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.GraphPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8781854313694553931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.MessageDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2502100249420840495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1397067405132982188</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.SendDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3758787152935146447</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.UserInfoDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4133061180336572911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Whiteboard</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3599910164817537912</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7472528586067210747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotCreateSchemaException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>291582260022140141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotPersistException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5157400778265186170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5777024088921236116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRetrieveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2523227229540681597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.BSH$BshHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4576592161896066369</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.CAUSAL$CausalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5498836339436997735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.COMPRESS$CompressHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9007677999985085671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1750370226005341630</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-493110511193765483</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT14KeystoreTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>468730481838883343</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT1_4$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4903164192583500536</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPTAsymmetricTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1481286172666845689</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ExampleHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8802317525466899597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FC$FcHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3840833975071138348</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3731636052308949891</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PID$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4600042790162330443</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PROB$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6777017945644585942</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SIMPLE$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1167997177583945633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SOCK$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6065036375091933922</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FLOW_CONTROL$FCInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8365016426836017979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FragHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>303445567493545979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.HTOTAL$HTotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8092873137976165925</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.JMS$JMSAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9151895560870256305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE$MergeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6346602920868031157</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE3$CoordAnnouncement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5948313354065175200</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGEFAST$MergefastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-782778793678079625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MyFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>487398390724731968</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8532981008982895761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PARTITIONER$PartitionerHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8563054383219742124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PIGGYBACK$PiggybackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1931866452789177725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5047065595618076465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5406011340890407404</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1958058124186816135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3634334590904551586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.SMACK$SmackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8177663976610985214</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.StateTransferRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7734608266762273116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7091158323788670702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_OLD$TotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3598787459743933165</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$RingTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4983650106365326055</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$TotalTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697698829445754100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TcpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5866113771133701445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1534098872369632339</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TransportedVectorTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5857647322589533545</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TunnelHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7822714431468070313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UNICAST$UnicastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4896559077682024829</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UdpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3935211140277615207</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.VERIFY_SUSPECT$VerifyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1941838263961448659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.VIEW_SYNC$ViewSyncHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5910687336210920515</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WANPIPE$WanPipeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1626305070273536659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WanPipeAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7341271304287013960</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2839796319279463477</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.GMS$GmsHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8861180924110146917</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Gossip</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7954243278668401185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.JoinRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2949193438640587597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.MergeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1496122908046351262</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5691816788765283064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.PbcastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6557298950278459935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STABLE$StableHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8197777278200741406</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STATE_TRANSFER$StateHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-842305656159159756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.RingToken</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5130788718652902761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.TokenLostException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5113234317099931071</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.GossipData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2701708796024030817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.IpAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2592301708270771474</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.LogicalAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>188526730199324927</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryPacket</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2592954324310791792</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7587678128986493349</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6862354518175504139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.EncryptOrderTestHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-122667245978500378</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.GroupRequestPull$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2311007561500635146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PartitionerTest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4585450199569162213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PerfTest$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8693769141297219569</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.QueueTest2$MyQueue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5186485528289936315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Data</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8623669553705606167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$StartData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2149929336279677323</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Value</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1784650063567334404</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest2$UnicastTest2Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7649416783110380750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptjms.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3593032375684821491</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptudp.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1467866650151597943</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.BoundedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7424651402352421757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.List</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2387756625721721326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Proxy$MyInetSocketAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6613080612560649839</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.QueueClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7575787375592873964</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Range</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1895551925607652646</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Stack</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2156560026798275993</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.TimedWriter$Timeout</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4848606759617898619</long> 
  +  </void> 
  + </object> 
  +</java> 
  
  
  
  1.1.2.1   +8596 -0   JBossCache/etc/svuid-db/Attic/svuid-50.1.3.0.GA.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: svuid-50.1.3.0.GA.xml
  ===================================================================
  RCS file: svuid-50.1.3.0.GA.xml
  diff -N svuid-50.1.3.0.GA.xml
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ svuid-50.1.3.0.GA.xml	23 Dec 2006 12:03:29 -0000	1.1.2.1
  @@ -0,0 +1,8596 @@
  +<?xml version="1.0" encoding="UTF-8"?> 
  +<java version="1.5.0_10" class="java.beans.XMLDecoder"> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.BrokenBarrierException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-147457780021240026</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6714594232516465772</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-273293065942834887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4374456568832557570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap$BarrierLock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4525944060243092775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7462087621709176033</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArraySet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7377569541496517854</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.PropertyChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2015832332684279521</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3131847742139976720</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.VetoableChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1658935129351293677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAllocationExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5206070850678934963</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAmbiguousName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5463192617696168744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArguments</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-585523412586448725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayDimensions</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7421434457381110734</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayInitializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8700933638077559442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAssignment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5786492369725521120</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBinaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2762482415254161500</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBlock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6768276487850608921</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHCastExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7470063802377582745</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHClassDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937995350116520528</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHEnhancedForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6186147054579461507</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7948089581379394413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalComment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6286509731094061726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>885501998857403574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameters</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5377216513908772736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHIfStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8630320869909994701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHImportDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6358892934545928949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHLiteral</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9207502592290153353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3910140293232619649</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3850040841809657514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPackageDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3898847231539731472</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-503393472352053812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimarySuffix</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1787222033238474243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimitiveType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-329589427159246987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2752610538670204146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6533667932058465861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHStatementExpressionList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6321165101746983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchLabel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5975475021538911876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5655955042808726899</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTernaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1606563852196299305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHThrowStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1240271051305696705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTryStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7478089655732292849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3430943699278719269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTypedVariableDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1227389047756718948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHUnaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1356335365378375412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHVariableDeclarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8458315290118837535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHWhileStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-268607334595851302</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BlockNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2687158869589601405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6335918737638083070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Capabilities$Unavailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3399055441689407911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ClassPathException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4486900461219339615</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.DelayedEvalBshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3354511033240459040</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.EvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3716899742529067922</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ExternalNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5243541843670468747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Interpreter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8662818442204412948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.InterpreterError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>492955139343282635</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.LHS</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6459038804384583967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Modifiers</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8471185022017946576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Name</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1368962988105189185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.NameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2499232412105981353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7776137309758821134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Parser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1080445658583023363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1164390191642946889</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive$Special</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3358001335405681566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ReflectError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2866156013797271636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5443864013386003037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5414610443216917980</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2695405703637847608</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.This</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9164318017112736976</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Token</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1762483667756877906</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5931514358210053837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilEvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8152371752278016844</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilTargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3189155544820014872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3903315982083174172</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6803452281441498586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis$Handler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4949939576606791809</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.BshClassPath$UnqualifiedNameTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3781441989565933164</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.DiscreteFilesClassLoader$ClassSourceMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5512817511949635338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4449346005537544077</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4666331393709464197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8135609692397819965</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.BshCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5388205109589610178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7209531634233769565</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser$PackageTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5706938369034888760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4328339671783920384</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>511965521903648517</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8369148428197760566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4878413495152524714</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.NameCompletionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6402387817755043296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.JavaDocBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6416423833804352641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractInheritableJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9023782913479355888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2524636196290199193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.ClassLibrary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937822024500756265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3485584001530088379</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3826651908494651111</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaClass</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56717871423934265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaField</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5158976028974024460</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5243360122899135505</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>179251600928831072</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3633306177895408984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.Type</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1596228041010255947</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.parser.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5318681457549236818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5125104124988065132</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1696027756378506682</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6126250255117957129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3907099389150076506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259049612296041412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6072271561424686085</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6253738640542714864</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8341335540288476967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6541451738732568309</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5928371437429336297</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4989418639347196543</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4388663746486043332</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6774847732447034836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4531243655467066716</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8199402162587347927</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1867106235561680513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5182945951854128074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2353400642617702135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8009749324757823162</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1386004770507927487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6518377914521265924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5027933992067738953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3219031174271773941</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2983928040263651920</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8221776374808491901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2668179591598315903</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkableAdaptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5304617132327526103</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8255356362445153793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226598894953083600</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5836847517986682456</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3985641094402692577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1484566617740723084</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1131655762826131576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3534490007366143774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1604113897169961576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8218345469653233169</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1314195772401372924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4261907982787552070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6169609859379733351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIdentityHashingStrategy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9078971529298567003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5135986634343398216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7205369688399131238</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CannotCompileException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4347542786236949387</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.ClassMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804593026213805083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CtClass$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3010032700700443882</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.NotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3351646634891239203</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.AlignmentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8236846960668290894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.BadBytecode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3276990049810168442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.CodeAttribute$RuntimeCopyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6805061409088364619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.CompileError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3050226843070987526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.KeywordTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5199030078030817932</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.NoFieldException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4412708214950596625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SymbolTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5270810980735558192</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SyntaxError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>490889194191819310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3901587593786844134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2799997277816596178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ArrayInit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2455192015828220874</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.AssignExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4621657704473821336</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.BinExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>493705937276265737</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CallExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6467190087868486053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CastExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4282802057512523201</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CondExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5259064316096978698</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Declarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7623658853007847572</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.DoubleConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7520025738220931295</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Expr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4954272843196512706</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.FieldDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2740715577722591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.InstanceOfExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4884917690955972361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.IntConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8467565945324056444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Keyword</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-441109204299464211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Member</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8058663079822722722</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.MethodDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6143642298594142396</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.NewExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1149608066531689319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Pair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4983294681996546807</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Stmnt</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9161016440925075705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.StringL</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4872959613607194275</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Symbol</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6360767401848368660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3042823100727688513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4807719830136336780</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotInvokeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8414032860369172220</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotReflectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3829918668979165876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.ClassMetaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1446514439423711708</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.Metaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2488206368319211804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectImporter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6932897352659865446</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2947053296940077756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3933064703890332122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2414585153283929621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.web.BadHttpRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9044749387914005083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.AccessLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4089104928924996726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.CreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6295951740865457514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.DuplicateKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7287399994705270076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.EJBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>796770993296843510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.FinderException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8785983102057433621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchEntityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4815730078295420703</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchObjectLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9151491108833037318</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4624364141026778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.RemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4581849053220157910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRequiredLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884174204131319153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRolledbackLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2897658132751784821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.model.exceptions.DDBeanCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8433252794388831851</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.BeanNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3319141583318924489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ClientExecuteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3580202712793889609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6211997126760402756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3061110807000384518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DeploymentManagerCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1322593937994224595</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.InvalidModuleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3478551028858955312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8564794200621186554</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.TargetException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4774441890984466267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.status.ProgressEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7815118532096485937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6850763061112244487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidClientIDException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2410181719763491702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidDestinationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588063794606036755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidSelectorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6223038613086963841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8951994251593378324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSSecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7512859695190450217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageEOFException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4829621000056590895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3642297253594750138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotReadableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8044835867550650748</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotWriteableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4241931174711518830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1172695755360706776</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionInProgressException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5611340150426335231</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionRolledBackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9157976009672865857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AndQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Attribute</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2484220110589082382</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>535176054565814134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6347317584796410029</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4077085769279709076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6511584241791106926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7768025046539163385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadAttributeValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3105272988410493376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadBinaryOpValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5068475589449021227</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadStringOperationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7802201238441662100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BetweenQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2933597532866307444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryOpValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1216286847881456786</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryRelQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5690656271650491000</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BooleanValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7754922052666594581</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ClassAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5801329450358952434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8893743928912733931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-882579438394773049</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.IntrospectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1054516935875481725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidApplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3048022274675537269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidAttributeValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2164571879317142449</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>350520924977331825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6573344628407841861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ListenerNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7242605822448519061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8644704819898565848</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4433990064191844427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4066342430588744142</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanFeatureInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3952882688968447265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6451021435135161911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3888371564530107064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6178860474881375330</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanParameterInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7432616882776782338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2416928705275160661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanRegistrationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4482382455277067805</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2876477500475969677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5661980843569388590</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission$MBeanServerPermissionCollections</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4111836792595161197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanTrustPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2952178077029018140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MalformedObjectNameException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-572689714442915824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MatchQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7156603696948215014</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5175579583207963577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5269643775896723397</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Notification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7516092053498031989</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6579080007561786969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NumericValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4679739485102359104</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4099952623687795850</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4967597595580536216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OrQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2962973084421716523</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QualifiedAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8832517277410933254</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QueryEval</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2675899265640874796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ReflectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9170809325636915553</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeErrorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>704338937753949796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5274912751982730171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeOperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8408923047489133588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ServiceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3990675661956646827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.StringValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3256390509806284044</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.MLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3636148327800330130</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.PrivateMLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2503458973393711979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.DescriptorSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6292969195866300415</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.DescriptorSupport$FieldName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2645619836053638810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.InvalidTargetObjectTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1190536278266811217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6181543027787327345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3862947819818064362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1935722590756516193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7445681389570207141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6532732096650090465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.XMLParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3176664577895105181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4608189663661929204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorSettingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8807913418190202007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.ArrayType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>720504429830309770</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8003518976613702244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5366242454346948798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4224269443946322062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidOpenTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2837312755412327534</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.KeyAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1845183636745282866</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenDataException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8346311255433349870</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanAttributeInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4867215622149721849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanConstructorInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4400441579007477003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4349395935420511492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanOperationInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4996859732565369366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanParameterInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7235016873758443122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9195195325186646468</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.SimpleType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2215577471957694503</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5720150593236309827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6554071860220659261</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationIdException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7115040321202754171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationServiceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3400722103759507559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3007446608299169961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleInfoException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7517834705158932074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2066091747301983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.MBeanServerNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2605900539589789736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5434016005679159613</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3793951411158559116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6871117877523310399</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationServiceNotRegisteredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8454744887157122910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1274155316284300752</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4611072955724144607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.Role</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-279985518429862552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2504952983494636987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfoNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4394092234999959939</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568344346499649313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2986406101364031481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6304063118040985512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolved</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-48350262537070138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolvedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4054902803091433324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerAlarmClockNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4841061275673620641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1798492029603825750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5433838894743521833</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.ResourceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>547071213627824490</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.cci.ResourceWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1233859030030360576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ApplicationServerInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7784532393279374430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.CommException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5000980212339163591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5611772461379563249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.EISSystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5753172122428814004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3473092818417322126</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.InvalidPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-485903720300735741</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.LocalTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7495828853103281459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAdapterInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1666678251804763325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9036793565852998502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7609456980660658364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SharingViolationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1280304091132682215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.UnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2495485036033570467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.security.PasswordCredential</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1770833344350711674</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkCompletedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-229158982387790244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3063612635015047218</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6360106395593829940</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkRejectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-687129544691878081</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBMethodPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.PolicyContextException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3925692572777572935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.WebRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4843217645290030002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.RowSetEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1875450876546332005</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicCommitException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3977609782149921760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicMixedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2345014349685956666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicRollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3483618944556408897</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.InvalidTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3597320220337691496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56870312332816390</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.RollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4151607774785285395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.SystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>839699079412719325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRequiredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1898806419937446439</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRolledbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3142798139623020577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.xa.XAException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249683284832867751</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.DeleteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8847684949621167130</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.FindException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-328565677274136182</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.InvalidRequestException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125274674633362305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.JAXRException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396751348710944315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.RegistryException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2972094643801708304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.SaveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2049281746282675377</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnexpectedObjectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2574981241743874017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnsupportedCapabilityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8122771280181567405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3564726132985118351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.Logo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259395942230563981</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7370065421049434357</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.AssertionFailedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6907951573723054750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.ComparisonFailure</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>544727012405451845</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6586601571607744836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.CounterPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2687873538635785002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackEntryRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1593293433761006310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackTraceListModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5938404479084696616</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.FailureRunView$FailureListCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2197075851577592477</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1311144803912540425</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.StatusLine</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5611683511998993645</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7074177803853075316</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector$TestCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8570682962687709951</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>668800626104011524</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel$TestTreeCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8412767466216926631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.commons.logging.LogConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1571584275865309127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.BaseTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9158502896034797704</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DecimalTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5105356898480069452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DefaultInfoImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2139348259136830321</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.IndexDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6494051577638099660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.MethodAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2401184375662152654</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.ReferencedColumnsDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3179877360885574252</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.RoutineAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7497340624645489559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.StatisticsImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4230393571147690926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.SynonymAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7810655070530271744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.TypeDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1288873888464524292</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.UserDefinedTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1799056355106710647</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.PassThroughException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3924642559467241441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.StandardException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8401633304649510414</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.cache.ClassSizeCatalog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6685327926445367733</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.classfile.Attributes</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1099922852895717904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.context.ShutdownException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-645255578941026919</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableArrayHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7722110452690226158</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableBitSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5177032461701961274</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9217193027129228620</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableIntHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628901830438778174</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableLongHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2650935220890598731</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1261261812413152266</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.depend.ProviderList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1366316628366847681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ColumnDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7414254430400923209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3867714944990476760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConstraintDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9037236679505216655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.GenericDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5295661333964883709</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.IndexRowGenerator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396538115441163883</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.TriggerDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-32469460606663392</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BigIntegerDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6318859761250203938</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BinaryDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5065454889050820246</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>301846662550352624</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataTypeDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56556292147865290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.JSQLType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6451737721593126039</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.NumberDataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2066913646534046755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBinary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2008438053333525328</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6638242629038410928</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBlob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697148507752332091</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBoolean</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5355826037058878832</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7976942440508199363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1202486554803122153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131035439424602061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4378598181224076768</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDouble</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3822433179233268622</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLInteger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8029534526043984426</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1540374351701611931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8157908992464919846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6618410970032962999</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-446455822150186304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5494340817457030212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5729633983927814888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6114609753457690185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLReal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6662944418729556978</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7211707249890696662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLSmallint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656859080434357609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4960299321851845821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTimestamp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6699781998014238614</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTinyint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3346531739133554042</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7951316506023190146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9154682651959409373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.TypeId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6712082221658633481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.UserType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1509003486518586988</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.util.DoubleProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2076176637991999421</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1009680591218740739</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile4</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8284143012912643841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4219230464646904320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804867918856204209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.cache.Clock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4312236320685380467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1206928593820632969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7678562473138491542</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.SinglePool</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7590648805367396975</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.monitor.UpdateServiceProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3741799138583058</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.uuid.BasicUUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3718151411232522413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4205329841347723821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorTableReference</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3487536779172920366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericColumnDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7391106685059283619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericResultDescription</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3250426016516532351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericStorablePreparedStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3307116410564599887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDColumnDependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-307206005961795666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DD_Version</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2578720014869961765</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDdependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1247784083094214331</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1968719239585371136</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6181718236993016793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.depend.BasicProviderInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6374500732560413607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6434920470936692312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfoList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3728683433925045535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AvgAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6588649172656353059</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ColumnInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795056845881766606</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ConstraintInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>907666986420613861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.CountAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>992685372833802847</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.DeleteConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8798662232746826004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.FKInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3645578133017885992</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexColumnOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5381802041848503659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6243277153338447053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.InsertConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9215984254597417967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.MaxMinAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6200973283828785051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.OrderableAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2548979559445856799</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SumAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2191968389560168342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SystemAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3363041046814554907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.TriggerInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5992967508621942134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdatableVTIConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1069674386524766701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdateConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-304225507996092831</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ValueRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-603613513999118017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.WriteCursorConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2555675739166589204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.PC_XenaVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7676884750261258364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.StorableFormatId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1055887996755577717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.UTF</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5523513719371189796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.BTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2806000041739135492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.WaitError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5285171848922420095</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2I</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232442507446656804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IStaticCompiledInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8400452328864426824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IUndo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-762791196902980249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.conglomerate.GenericConglomerate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4250310482563395080</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.Heap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5902040921459274872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.HeapRowLocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4289598659775108088</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocExtent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-964942574996053618</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1904475501742389367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ChainAllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7025016240618679279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CompressSpacePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2686965541794407374</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4895368432786554430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>737643866048984133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1694580053106123087</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CopyRowsOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5298806023002438329</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.DeleteOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8634310601289456663</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InitPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-653697683164018124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InsertOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7372197412796385217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InvalidatePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3029903537053186655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>931621854183206917</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6379497936871106083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LongColumnException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8355712046325811247</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.NoSpaceOnPage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5705728020085434337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PageBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4495032194360898129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8395034761202954774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1629730437784173653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PurgeOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1815947391742392482</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.RemoveFileOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9128463506137321686</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.SetReservedSpaceOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452338843997645457</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateFieldOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8729716610518008479</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5022439034409403549</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.CheckpointOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3547334483634107987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.ChecksumOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2603075230783601529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6822213548599245381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6549540354718798294</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.BeginXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1675099279475574863</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.EndXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3814049087240034502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.GlobalXactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3675162292673048435</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7367956979044103797</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTableEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7684636587849580178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.XactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2802828528732192420</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedConnectionPoolDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7852784308039674160</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4945135214995641181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedXADataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5715798975598379738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.ReferenceableDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1872877359127597176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.ProvisionNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4479121426311014469</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.RollingCalendar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3560331770601814177</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5695670494782816506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.DetailPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-183716192697269830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>396456838584537074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.LoadXMLAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1959519697665333576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.Main</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6679218458268861656</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.MyTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2394739789728444307</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.config.PropertySetterException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1352613734254235861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.AbsoluteTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-388856345976723342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.DateTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5547637772208514971</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.ISO8601DateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-759840745298755296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.RelativeTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7055751607085611984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.Log4JLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6229073500826714757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5251735053323350105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevelFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4274666161838212273</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3544820201891844767</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.util.AdapterLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5682197585320945004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.FilteredLogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8992671089131499904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5Dialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8659689967961501340</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5ErrorDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1308340769672017318</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5InputDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6751965584219214443</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5LoadingDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-477909513711973458</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4867085140195148458</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4275827753626456547</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumnFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6529165785030431653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593300685868700894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableRowRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3951639953706443213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3413887384316015901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8066257446951323576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5958994817693177319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeEditorRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6094804684259929574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6046702673278595048</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LocationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1325822038990805636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LoggingEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-868428216207166145</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.ThrowableInformation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4748765566864322735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.ClassInstanceAdvisor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3057976129116723527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.DispatcherConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1502745917111812781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.NotFoundInDispatcherException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5020740195889379757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.AnnotationParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>122998472196736778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8256510811060336766</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.instrument.TransformationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9087730534133925094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.CallerInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303974658</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303875808</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7005423783330774114</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4671110715707463304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3045541205784967429</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1003170617993582707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6968523285026078131</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7880020293056198584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1092370003103163067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776393748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3337041720097890861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7595351292713886213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6795964118579848645</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5435217977419419783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationBase</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4880246394729260729</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2974596986988236395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6156314852981932065</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4578273471486761147</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7826653633415463825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3078730663855284320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1313717554016611763</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6399861718513077210</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3873275588469743345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData$MetaDataValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8024138149680591337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6640507307072022813</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.PointcutExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4076294802573243474</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7207593606482597998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TypeExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588935251567280090</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ClassProxyTemplate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7776009946350762531</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledClassProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4049171769644464715</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledInterfaceProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7939451715003985857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.Proxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040609385293748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2451434088790560691</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMixin</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6150046185716362835</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.standalone.Package</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6188655039267365373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7688683906350419871</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.CacheException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-343717717992472642</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ConfigureException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1937579864964670681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Fqn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5351930616956603651</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.GlobalTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8011434781266976149</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Modification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3074622985730129009</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5040432493172658796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.NodeNotExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>779376138690777440</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.OptimisticTreeNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3497174028709124136</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.RegionNotEmptyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ReplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2141504272926290430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.SuspectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2965599037371850141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8576324868563647538</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593129982953807846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568518714172267901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8895044368299888998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1578599138419577069</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5577441016277949170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3796901116451916116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8985697625953238855</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1242167331988194987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7656592171312920825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7084928639244438800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$CommitTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5426108920883879873</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$EvictAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6007500908549034215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5364163916172148038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$LoadAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6998760732995584428</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4882445905140460053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2171307516592250436</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6894888234400908985</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3746013603940497991</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RollbackTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4836748411400541430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$StartTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7059131008813144857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.AOPInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6492134565825613209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7044654602510185865</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8035968024123769723</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1846726449742865362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3309349735197545040</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3391522498362829190</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1547808705937201967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-856964838566617006</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheAopGui$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>116863545772054467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-402153636437493134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.EvictionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4006783737166646935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6796150029431162837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.NodeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7571995794010294485</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.rmi.RemoteTreeCacheImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3096209368650710385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.DeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8651993450626741020</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5551396474793902133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.OwnerNotExistedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2837393571654438480</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8096787619908687038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.UpgradeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5683212651728276028</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.MarshallingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5991339859063633060</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7719282503234213209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7321547249627414140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.DefaultDataVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9086186758698005849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.FqnComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7907781088049142376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.rpc.NoHandlerForRPCException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.BatchModeTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656602677430350961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyBaseTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6716097342564237376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4396695354693176535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyUserTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6568400755677046127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1416258464473965574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131841473723490707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentState</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2319062412502366783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.IncompleteDeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1428860525880893167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SerializableDeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3847995513551913798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SubDeployerSupport$ClassConfiguration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2716929675748339631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7679468692447241311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3507018102770233526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5117370636698417671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6460196085190851775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-718723094688127810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5436722659170811314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.ServiceUnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3739642441706165948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.http.interfaces.HttpInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249272784108192267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3713605626489646730</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.server.JRMPInvoker_Stub</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-728630295444149842</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1265347772036749711</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.ServerAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7206359745950445445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.lang.Enum</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8923967787677833913</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.DynamicLogger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5963699806863917370</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.Logger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232175575988879434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.capability.OptimizedMBeanDispatcher$MethodEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1792631947840418314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.interceptor.InterceptorNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-696843094576327612</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.loading.LoaderRepositoryFactory$LoaderRepositoryConfig</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226952985429700362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.metadata.IllegalPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1025239559959501272</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.notification.NotificationFilterProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.ServerObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1829209376363828441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5392945073280632822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.InstanceOfQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5765353862268810105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7441880585611238427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6442164418782871672</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JMXInvocationHandler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3714728148040623702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.MBeanProxyCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1008637966352433381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.RuntimeProxyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1166909485463779459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.ExternalContext$SerializableInitialContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6512260531255770463</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.LinkRefPair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6036946190113161492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.DefaultSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7626239955727142958</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.QueuedClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6566809337830221375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.RMIMultiSocketClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-945837789475428529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-920483051658660269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutServerSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7006964274840965634</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1841403351768037738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.InvalidAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>785817154841571537</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.MissingAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2104972080882639099</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ServiceContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7461263042948325633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.filterfactory.DeploymentInfoNotificationFilterFactory$DeploymentInfoNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5067618040005609685</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.AbstractNestedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7384049506870825781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.CoercionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3248954334700890176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7736259185393081556</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6024309396861726945</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2161377898611431781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4683457706354663230</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1803971437884946242</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.DataConversionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6287439477349036488</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.EmptyStringException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7958716001355854762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.HashCode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2391396931740264021</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.JBossStringBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1874946609763446794</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1615297462859270139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8903330696503363758</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8902748795144754375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2584758778978644599</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6720507617603163762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4135571897343827853</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7003381223684751953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9017248167673450852</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8348882503434035185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NoSuchMethodException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3044955578250977290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotCoercibleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125062352267547279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotImplementedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3915801189311749818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-403173436435490144</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NullArgumentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2308503249278841584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6077429788585907990</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace$Entry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7013023772762859280</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628094303187435707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6284244000894114817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6859401939735540773</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnexpectedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4318032849691437298</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnreachableStatementException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6741968131968754812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ArrayIterator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6604583440222021075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1470947618739421094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CompoundKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1181463173922935047</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.EmptyCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4562591066479152759</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.FullCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795773071357559465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ListSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7333619218072079496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.SerializableEnumeration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8678951571196067510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.deadlock.ApplicationDeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-908428091244600395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.GUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3289509836244263718</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.UID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8093336932569424512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.VMID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4339675822939194520</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.platform.PID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6837013326314943907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyContainer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3347198703863412326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4956548740655706282</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5007209897739884086</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452085442436956822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyGroup</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2557641199743063159</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8747802918099008518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.state.IllegalTransitionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3392564168782896452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.BlockingMode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9102277941374138830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.StartTimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2287779538710535096</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.TaskStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5166095239829218680</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolFullException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1044683480627340299</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8732248855455909385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8229078720076583113</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-33504134223704483</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3196504305414545949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.SimpleTypeBindings</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4372272109355825813</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3813878809953971710</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-62219642166721806</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>615315465309975801</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.TypeBinding</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2815361862736153588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5172168752255182905</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3540265999209053491</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelNotConnectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6701630538465783064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3786054325601841062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.MergeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2682174976989815032</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.Message</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1137364035832847034</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.SuspectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6663279911010545655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3555655828017487825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.View</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4533382418778234665</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ViewId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2194604680465610696</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4974051451573194550</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$AcquireLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6598500471822545410</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$LockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5614003065708878672</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$ReleaseLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3535306842096930972</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4448104853965887333</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotGrantedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4074824788210185433</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotReleasedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-350403929687059570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-712594616520011007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$AllLinksDown</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3329785688905216843</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$NoLinksAvailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5250951711707663051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.MethodCall</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7873471327078957662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.NotificationBus$Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6133287486444083527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.PullPushAdapter$PullHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-425784033525973495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2719268809250178946</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8654791037075308304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6627736371945009800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7996418731426358548</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicationData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3945713445332028341</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.RequestCorrelator$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6218812100438796010</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.TwoPhaseVotingAdapter$TwoPhaseWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5874214163436160067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.UpdateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4196360091623991749</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-878345689312038489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$FailureVoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2809813561621497082</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$VoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3613490568129896140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.Xid</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4409463369646897707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.Debugger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4449823995417365266</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.ProtocolSpecificView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7896517829304370211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.QUEUEView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7798060311888236141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.CausalMessage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>780718666884109552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedHashtableDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4702508639852294344</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedQueueDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7622390100963225361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedTreeDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-565717619547736367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2259064207678152243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw2Channels$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-159139558962652075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DrawCommand</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-539152912005072037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$Command</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4589357003632171240</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$MyPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3949118385264358535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>830341371019288303</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5880115553330291212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.QuoteClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6330572389849611533</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5845856017238569017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1981454998903219877</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-844842002708012312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4254284786559213346</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884349667401210895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7021074808114540717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Topology</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1573646619876712993</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotOrderRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8946333513205704225</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3913436032289156789</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-949231907799007987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ColorPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3802922492190502041</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7659975100736213568</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$StackPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7585339684267647405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TotalPayload</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-936838583748491815</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TransmitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4976326672958441937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.applets.DrawApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5424670476092532936</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.ApplFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3111759067157049661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.GraphPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2614867219673231568</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.MessageDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2502100249420840495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1397067405132982188</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.SendDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3758787152935146447</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.UserInfoDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4133061180336572911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Whiteboard</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2274303019457050327</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7472528586067210747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotCreateSchemaException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>291582260022140141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotPersistException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5157400778265186170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5777024088921236116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRetrieveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2523227229540681597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.BSH$BshHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4576592161896066369</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.CAUSAL$CausalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5498836339436997735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.COMPRESS$CompressHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9007677999985085671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1750370226005341630</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2196297653127166373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT14KeystoreTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>468730481838883343</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT1_4$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4903164192583500536</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPTAsymmetricTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1481286172666845689</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ExampleHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1142160965073499584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FC$FcHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7827029202013659594</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5616292129142554109</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PID$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4600042790162330443</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PROB$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6777017945644585942</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SIMPLE$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1167997177583945633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SOCK$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8516198663141898078</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FLOW_CONTROL$FCInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5533195698941348382</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FragHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>303445567493545979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.HTOTAL$HTotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5191852668378595581</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.JMS$JMSAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2665329356255842841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE$MergeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6346602920868031157</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE3$CoordAnnouncement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5948313354065175200</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGEFAST$MergefastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-782778793678079625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MyFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>487398390724731968</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8532981008982895761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PARTITIONER$PartitionerHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8563054383219742124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PIGGYBACK$PiggybackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1931866452789177725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1321354690148853821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2617261140193045024</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1958058124186816135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3634334590904551586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.SMACK$SmackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8177663976610985214</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.StateTransferRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5881488678259966263</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7091158323788670702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_OLD$TotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3457318931485225599</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$RingTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4983650106365326055</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$TotalTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697698829445754100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TcpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5866113771133701445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TransportedVectorTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1603566195889830614</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TunnelHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7822714431468070313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UNICAST$UnicastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5363480203591236450</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UdpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3935211140277615207</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.VERIFY_SUSPECT$VerifyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1941838263961448659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WANPIPE$WanPipeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1626305070273536659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WanPipeAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2704805420827050111</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7645538507245078868</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.GMS$GmsHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2448333506445159147</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Gossip</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7954243278668401185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.JoinRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6649266592397456151</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.MergeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1496122908046351262</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8624127273776057099</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.PbcastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6557298950278459935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STABLE$StableHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5722541602835160473</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STATE_TRANSFER$StateHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8634851404722847649</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.RingToken</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5130788718652902761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.TokenLostException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5113234317099931071</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.DenyResponseHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8163036803592200794</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseDeniedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-846586020199773038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6933466840087221613</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseFactoryService$LeaseInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3444050623220620496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseInfoReplicationHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5304536941840240874</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseRequestHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9209612480415121567</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.LeaseResponseHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3874052770561705701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.RecursiveLeaseRequestException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1831708130008979859</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.service.lease.UnknownLeaseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6671687259988247051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.GossipData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2701708796024030817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.IpAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6332171047247548699</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.LogicalAddress1_4</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2275816655325808792</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryPacket</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2592954324310791792</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7587678128986493349</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6862354518175504139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.EncryptOrderTestHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-122667245978500378</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.GroupRequestPull$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2311007561500635146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PartitionerTest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4585450199569162213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PerfTest$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8693769141297219569</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.QueueTest2$MyQueue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5186485528289936315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Data</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8623669553705606167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$StartData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2149929336279677323</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Value</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1784650063567334404</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest2$UnicastTest2Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7649416783110380750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptjms.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3593032375684821491</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptudp.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1467866650151597943</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.perf.Data</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8306465039303685969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.perf.MemberInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1808690327914209633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.BoundedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7424651402352421757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.List</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2387756625721721326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Proxy1_4$MyInetSocketAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1915728442156280395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.QueueClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7575787375592873964</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Range</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1895551925607652646</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Stack</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2156560026798275993</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.TimedWriter$Timeout</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4848606759617898619</long> 
  +  </void> 
  + </object> 
  +</java> 
  
  
  
  1.1.2.1   +8888 -0   JBossCache/etc/svuid-db/Attic/svuid-50.1.4.0.GA.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: svuid-50.1.4.0.GA.xml
  ===================================================================
  RCS file: svuid-50.1.4.0.GA.xml
  diff -N svuid-50.1.4.0.GA.xml
  --- /dev/null	1 Jan 1970 00:00:00 -0000
  +++ svuid-50.1.4.0.GA.xml	23 Dec 2006 12:03:29 -0000	1.1.2.1
  @@ -0,0 +1,8888 @@
  +<?xml version="1.0" encoding="UTF-8"?> 
  +<java version="1.5.0_10" class="java.beans.XMLDecoder"> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.BrokenBarrierException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-147457780021240026</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6714594232516465772</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentHashMap$Segment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-273293065942834887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4374456568832557570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.ConcurrentReaderHashMap$BarrierLock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4525944060243092775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7462087621709176033</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.CopyOnWriteArraySet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7377569541496517854</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.PropertyChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2015832332684279521</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3131847742139976720</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>EDU.oswego.cs.dl.util.concurrent.VetoableChangeMulticaster</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1658935129351293677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAllocationExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5206070850678934963</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAmbiguousName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5463192617696168744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArguments</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-585523412586448725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayDimensions</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7421434457381110734</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHArrayInitializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8700933638077559442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHAssignment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5786492369725521120</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBinaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2762482415254161500</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHBlock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6768276487850608921</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHCastExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7470063802377582745</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHClassDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937995350116520528</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHEnhancedForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6186147054579461507</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHForStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7948089581379394413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalComment</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6286509731094061726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>885501998857403574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHFormalParameters</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5377216513908772736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHIfStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8630320869909994701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHImportDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6358892934545928949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHLiteral</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9207502592290153353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3910140293232619649</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3850040841809657514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPackageDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3898847231539731472</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-503393472352053812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimarySuffix</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1787222033238474243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHPrimitiveType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-329589427159246987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2752610538670204146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHReturnType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6533667932058465861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHStatementExpressionList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6321165101746983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchLabel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5975475021538911876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHSwitchStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5655955042808726899</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTernaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1606563852196299305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHThrowStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1240271051305696705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTryStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7478089655732292849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3430943699278719269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHTypedVariableDeclaration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1227389047756718948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHUnaryExpression</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1356335365378375412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHVariableDeclarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8458315290118837535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BSHWhileStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-268607334595851302</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BlockNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2687158869589601405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.BshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6335918737638083070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Capabilities$Unavailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3399055441689407911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ClassPathException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4486900461219339615</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.DelayedEvalBshMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3354511033240459040</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.EvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3716899742529067922</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ExternalNameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5243541843670468747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Interpreter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8662818442204412948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.InterpreterError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>492955139343282635</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.LHS</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6459038804384583967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Modifiers</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8471185022017946576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Name</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1368962988105189185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.NameSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2499232412105981353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7776137309758821134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Parser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1080445658583023363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1164390191642946889</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Primitive$Special</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3358001335405681566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.ReflectError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2866156013797271636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5443864013386003037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.SimpleNode$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5414610443216917980</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2695405703637847608</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.This</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9164318017112736976</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Token</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1762483667756877906</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5931514358210053837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilEvalError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8152371752278016844</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.UtilTargetError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3189155544820014872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3903315982083174172</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6803452281441498586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.XThis$Handler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4949939576606791809</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.BshClassPath$UnqualifiedNameTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3781441989565933164</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.classpath.DiscreteFilesClassLoader$ClassSourceMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5512817511949635338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4449346005537544077</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4666331393709464197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.AWTRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8135609692397819965</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.BshCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5388205109589610178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7209531634233769565</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.ClassBrowser$PackageTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5706938369034888760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4328339671783920384</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JConsole$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>511965521903648517</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JDemoApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8369148428197760566</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.JRemoteApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4878413495152524714</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>bsh.util.NameCompletionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6402387817755043296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.JavaDocBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6416423833804352641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractInheritableJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9023782913479355888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.AbstractJavaEntity</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2524636196290199193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.ClassLibrary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2937822024500756265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3485584001530088379</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.DefaultDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3826651908494651111</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaClass</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56717871423934265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaField</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5158976028974024460</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaMethod</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5243360122899135505</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaParameter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>179251600928831072</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.JavaSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3633306177895408984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.model.Type</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1596228041010255947</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>com.thoughtworks.qdox.parser.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5318681457549236818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5125104124988065132</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1696027756378506682</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6126250255117957129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3907099389150076506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259049612296041412</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6072271561424686085</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6253738640542714864</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TDoubleObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8341335540288476967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6541451738732568309</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5928371437429336297</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4989418639347196543</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4388663746486043332</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6774847732447034836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4531243655467066716</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8199402162587347927</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TFloatObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1867106235561680513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5182945951854128074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.THashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2353400642617702135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8009749324757823162</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1386004770507927487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6518377914521265924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5027933992067738953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3219031174271773941</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2983928040263651920</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8221776374808491901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TIntObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2668179591598315903</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkableAdaptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5304617132327526103</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLinkedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8255356362445153793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongArrayList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226598894953083600</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5836847517986682456</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3985641094402692577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1484566617740723084</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongHashSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1131655762826131576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3534490007366143774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1604113897169961576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TLongObjectHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8218345469653233169</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectDoubleHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1314195772401372924</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectFloatHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4261907982787552070</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectHash</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6169609859379733351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIdentityHashingStrategy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9078971529298567003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectIntHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5135986634343398216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>gnu.trove.TObjectLongHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7205369688399131238</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CannotCompileException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4347542786236949387</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.ClassMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804593026213805083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.CtClass$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3010032700700443882</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.NotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3351646634891239203</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.AlignmentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8236846960668290894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.BadBytecode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3276990049810168442</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.bytecode.CodeAttribute$RuntimeCopyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6805061409088364619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.CompileError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3050226843070987526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.KeywordTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5199030078030817932</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.NoFieldException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4412708214950596625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SymbolTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5270810980735558192</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.SyntaxError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>490889194191819310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3901587593786844134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ASTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2799997277816596178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.ArrayInit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2455192015828220874</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.AssignExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4621657704473821336</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.BinExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>493705937276265737</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CallExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6467190087868486053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CastExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4282802057512523201</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.CondExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5259064316096978698</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Declarator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7623658853007847572</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.DoubleConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7520025738220931295</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Expr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4954272843196512706</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.FieldDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2740715577722591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.InstanceOfExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4884917690955972361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.IntConst</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8467565945324056444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Keyword</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-441109204299464211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Member</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8058663079822722722</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.MethodDecl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6143642298594142396</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.NewExpr</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1149608066531689319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Pair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4983294681996546807</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Stmnt</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9161016440925075705</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.StringL</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4872959613607194275</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Symbol</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6360767401848368660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.compiler.ast.Variable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3042823100727688513</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4807719830136336780</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotInvokeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8414032860369172220</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.CannotReflectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3829918668979165876</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.ClassMetaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1446514439423711708</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.reflect.Metaobject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2488206368319211804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectImporter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6932897352659865446</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2947053296940077756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3933064703890332122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.rmi.RemoteRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2414585153283929621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javassist.web.BadHttpRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9044749387914005083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.AccessLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4089104928924996726</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.CreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6295951740865457514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.DuplicateKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7287399994705270076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.EJBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>796770993296843510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.FinderException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8785983102057433621</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchEntityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4815730078295420703</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.NoSuchObjectLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9151491108833037318</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.ObjectNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4624364141026778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.RemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4581849053220157910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRequiredLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884174204131319153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.ejb.TransactionRolledbackLocalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2897658132751784821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.model.exceptions.DDBeanCreateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8433252794388831851</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.BeanNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3319141583318924489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ClientExecuteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3580202712793889609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6211997126760402756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DConfigBeanVersionUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3061110807000384518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.DeploymentManagerCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1322593937994224595</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.InvalidModuleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3478551028858955312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.OperationUnsupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8564794200621186554</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.exceptions.TargetException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4774441890984466267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.enterprise.deploy.spi.status.ProgressEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7815118532096485937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6850763061112244487</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidClientIDException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2410181719763491702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidDestinationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588063794606036755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.InvalidSelectorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6223038613086963841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8951994251593378324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.JMSSecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7512859695190450217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageEOFException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4829621000056590895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3642297253594750138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotReadableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8044835867550650748</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.MessageNotWriteableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4241931174711518830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1172695755360706776</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionInProgressException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5611340150426335231</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.jms.TransactionRolledBackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9157976009672865857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AndQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Attribute</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2484220110589082382</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>535176054565814134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeChangeNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6347317584796410029</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4077085769279709076</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6511584241791106926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.AttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7768025046539163385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadAttributeValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3105272988410493376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadBinaryOpValueExpException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5068475589449021227</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BadStringOperationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7802201238441662100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BetweenQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2933597532866307444</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryOpValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1216286847881456786</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BinaryRelQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5690656271650491000</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.BooleanValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7754922052666594581</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ClassAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5801329450358952434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8893743928912733931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InstanceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-882579438394773049</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.IntrospectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1054516935875481725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidApplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3048022274675537269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.InvalidAttributeValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2164571879317142449</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>350520924977331825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.JMRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6573344628407841861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ListenerNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7242605822448519061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8644704819898565848</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4433990064191844427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4066342430588744142</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanFeatureInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3952882688968447265</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6451021435135161911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3888371564530107064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6178860474881375330</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanParameterInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7432616882776782338</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2416928705275160661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanRegistrationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4482382455277067805</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2876477500475969677</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5661980843569388590</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanServerPermission$MBeanServerPermissionCollections</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4111836792595161197</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MBeanTrustPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2952178077029018140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MalformedObjectNameException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-572689714442915824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.MatchQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7156603696948215014</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5175579583207963577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5269643775896723397</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.Notification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7516092053498031989</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6579080007561786969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.NumericValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4679739485102359104</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4099952623687795850</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ObjectName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1081892073854801359</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4967597595580536216</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.OrQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2962973084421716523</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QualifiedAttributeValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8832517277410933254</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.QueryEval</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2675899265640874796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ReflectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9170809325636915553</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeErrorException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>704338937753949796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5274912751982730171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.RuntimeOperationsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8408923047489133588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.ServiceNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3990675661956646827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.StringValueExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3256390509806284044</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.MLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3636148327800330130</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.loading.PrivateMLet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2503458973393711979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.DescriptorSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6292969195866300415</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.DescriptorSupport$FieldName</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2645619836053638810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.InvalidTargetObjectTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1190536278266811217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanAttributeInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6181543027787327345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanConstructorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3862947819818064362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1935722590756516193</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanNotificationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7445681389570207141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.ModelMBeanOperationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6532732096650090465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.modelmbean.XMLParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3176664577895105181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4608189663661929204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.monitor.MonitorSettingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8807913418190202007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.ArrayType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>720504429830309770</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8003518976613702244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.CompositeType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5366242454346948798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidKeyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4224269443946322062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.InvalidOpenTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2837312755412327534</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.KeyAlreadyExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1845183636745282866</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenDataException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8346311255433349870</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanAttributeInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4867215622149721849</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanConstructorInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4400441579007477003</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4349395935420511492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanOperationInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4996859732565369366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenMBeanParameterInfoSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7235016873758443122</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.OpenType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9195195325186646468</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.SimpleType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2215577471957694503</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularDataSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5720150593236309827</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.openmbean.TabularType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6554071860220659261</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationIdException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7115040321202754171</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationServiceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3400722103759507559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRelationTypeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3007446608299169961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleInfoException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7517834705158932074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.InvalidRoleValueException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2066091747301983721</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.MBeanServerNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2605900539589789736</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5434016005679159613</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3793951411158559116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6871117877523310399</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationServiceNotRegisteredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8454744887157122910</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1274155316284300752</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RelationTypeSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4611072955724144607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.Role</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-279985518429862552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2504952983494636987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleInfoNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4394092234999959939</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568344346499649313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2986406101364031481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6304063118040985512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolved</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-48350262537070138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.relation.RoleUnresolvedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4054902803091433324</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerAlarmClockNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4841061275673620641</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.management.timer.TimerNotification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1798492029603825750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5433838894743521833</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.ResourceException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>547071213627824490</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.cci.ResourceWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1233859030030360576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ApplicationServerInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7784532393279374430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.CommException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5000980212339163591</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5611772461379563249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.EISSystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5753172122428814004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.IllegalStateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3473092818417322126</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.InvalidPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-485903720300735741</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.LocalTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7495828853103281459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAdapterInternalException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1666678251804763325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.ResourceAllocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9036793565852998502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SecurityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7609456980660658364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.SharingViolationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1280304091132682215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.UnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2495485036033570467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.security.PasswordCredential</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1770833344350711674</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkCompletedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-229158982387790244</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3063612635015047218</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6360106395593829940</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.resource.spi.work.WorkRejectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-687129544691878081</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBMethodPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.EJBRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.PolicyContextException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3925692572777572935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.security.jacc.WebRoleRefPermission</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.ConnectionEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4843217645290030002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.sql.RowSetEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1875450876546332005</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicCommitException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3977609782149921760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicMixedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2345014349685956666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.HeuristicRollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3483618944556408897</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.InvalidTransactionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3597320220337691496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.NotSupportedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56870312332816390</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.RollbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4151607774785285395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.SystemException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>839699079412719325</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRequiredException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1898806419937446439</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.TransactionRolledbackException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3142798139623020577</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>javax.transaction.xa.XAException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249683284832867751</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.DeleteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8847684949621167130</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.FindException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-328565677274136182</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.InvalidRequestException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125274674633362305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.JAXRException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396751348710944315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.RegistryException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2972094643801708304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.SaveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2049281746282675377</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnexpectedObjectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2574981241743874017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>javax.xml.registry.UnsupportedCapabilityException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8122771280181567405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.btree.BPage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.btree.BTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.ByteArrayComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.ByteArraySerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.CacheEvictionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6024886898553870353</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.DefaultSerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3818545055661017388</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.IntegerComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.IntegerSerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8683732630163314356</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.IterationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5320108524567522710</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.LongComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.LongSerializer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7980451649962070585</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.ObjectBAComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.helper.StringComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.helper.WrappedRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4046883237946202808</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.htree.HashBucket</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.htree.HashDirectory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>jdbm.htree.HashNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5640415117406368094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>jdbm.recman.BlockIo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3564726132985118351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.Logo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1259395942230563981</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.awtui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7370065421049434357</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.AssertionFailedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6907951573723054750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.framework.ComparisonFailure</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>544727012405451845</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.AboutDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6586601571607744836</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.CounterPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2687873538635785002</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackEntryRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1593293433761006310</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.DefaultFailureDetailView$StackTraceListModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5938404479084696616</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.FailureRunView$FailureListCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2197075851577592477</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.ProgressBar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1311144803912540425</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.StatusLine</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5611683511998993645</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7074177803853075316</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSelector$TestCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8570682962687709951</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>668800626104011524</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>junit.swingui.TestSuitePanel$TestTreeCellRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8412767466216926631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.commons.logging.LogConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1571584275865309127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.BaseTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9158502896034797704</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DecimalTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5105356898480069452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.DefaultInfoImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2139348259136830321</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.IndexDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6494051577638099660</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.MethodAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2401184375662152654</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.ReferencedColumnsDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3179877360885574252</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.RoutineAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7497340624645489559</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.StatisticsImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4230393571147690926</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.SynonymAliasInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7810655070530271744</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.TypeDescriptorImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1288873888464524292</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.catalog.types.UserDefinedTypeIdImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1799056355106710647</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.PassThroughException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3924642559467241441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.error.StandardException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8401633304649510414</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.cache.ClassSizeCatalog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6685327926445367733</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.classfile.Attributes</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1099922852895717904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.context.ShutdownException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-645255578941026919</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableArrayHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7722110452690226158</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableBitSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5177032461701961274</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9217193027129228620</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableIntHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628901830438778174</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableLongHolder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2650935220890598731</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.services.io.FormatableProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1261261812413152266</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.depend.ProviderList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1366316628366847681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ColumnDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7414254430400923209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConglomerateDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3867714944990476760</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.ConstraintDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9037236679505216655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.GenericDescriptorList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5295661333964883709</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.IndexRowGenerator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-396538115441163883</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.sql.dictionary.TriggerDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-32469460606663392</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BigIntegerDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6318859761250203938</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.BinaryDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5065454889050820246</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>301846662550352624</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.DataTypeDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>56556292147865290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.JSQLType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6451737721593126039</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.NumberDataType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2066913646534046755</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBinary</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2008438053333525328</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6638242629038410928</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBlob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697148507752332091</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLBoolean</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5355826037058878832</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7976942440508199363</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1202486554803122153</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131035439424602061</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDecimal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4378598181224076768</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLDouble</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3822433179233268622</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLInteger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8029534526043984426</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1540374351701611931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8157908992464919846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6618410970032962999</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNClob</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-446455822150186304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalChar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5494340817457030212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalLongvarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5729633983927814888</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLNationalVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6114609753457690185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLReal</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6662944418729556978</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLRef</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7211707249890696662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLSmallint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656859080434357609</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4960299321851845821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTimestamp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6699781998014238614</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLTinyint</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3346531739133554042</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarbit</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7951316506023190146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.SQLVarchar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9154682651959409373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.TypeId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6712082221658633481</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.types.UserType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1509003486518586988</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.iapi.util.DoubleProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2076176637991999421</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1009680591218740739</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.io.DirFile4</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8284143012912643841</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4219230464646904320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.jdbc.EmbedSQLWarning</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7804867918856204209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.cache.Clock</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4312236320685380467</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1206928593820632969</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.LockSpace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7678562473138491542</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.locks.SinglePool</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7590648805367396975</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.monitor.UpdateServiceProperties</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3741799138583058</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.services.uuid.BasicUUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3718151411232522413</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4205329841347723821</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.CursorTableReference</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3487536779172920366</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericColumnDescriptor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7391106685059283619</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericResultDescription</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3250426016516532351</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.GenericStorablePreparedStatement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3307116410564599887</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDColumnDependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-307206005961795666</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DD_Version</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2578720014869961765</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.catalog.DDdependableFinder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1247784083094214331</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1968719239585371136</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.compile.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6181718236993016793</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.depend.BasicProviderInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6374500732560413607</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6434920470936692312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AggregatorInfoList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3728683433925045535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.AvgAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6588649172656353059</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ColumnInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795056845881766606</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ConstraintInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>907666986420613861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.CountAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>992685372833802847</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.DeleteConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8798662232746826004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.FKInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3645578133017885992</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexColumnOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5381802041848503659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.IndexRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6243277153338447053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.InsertConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9215984254597417967</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.MaxMinAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6200973283828785051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.OrderableAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2548979559445856799</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SumAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2191968389560168342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.SystemAggregator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3363041046814554907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.TriggerInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5992967508621942134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdatableVTIConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1069674386524766701</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.UpdateConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-304225507996092831</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.ValueRow</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-603613513999118017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.sql.execute.WriteCursorConstantAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2555675739166589204</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.PC_XenaVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7676884750261258364</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.StorableFormatId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1055887996755577717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.UTF</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5523513719371189796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.BTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2806000041739135492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.WaitError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5285171848922420095</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2I</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232442507446656804</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IStaticCompiledInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8400452328864426824</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.btree.index.B2IUndo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-762791196902980249</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.conglomerate.GenericConglomerate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4250310482563395080</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.Heap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5902040921459274872</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.access.heap.HeapRowLocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4289598659775108088</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocExtent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-964942574996053618</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.AllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1904475501742389367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ChainAllocPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7025016240618679279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CompressSpacePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2686965541794407374</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4895368432786554430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>737643866048984133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.ContainerUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1694580053106123087</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.CopyRowsOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5298806023002438329</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.DeleteOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8634310601289456663</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InitPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-653697683164018124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InsertOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7372197412796385217</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.InvalidatePageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3029903537053186655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>931621854183206917</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LogicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6379497936871106083</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.LongColumnException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8355712046325811247</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.NoSpaceOnPage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5705728020085434337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PageBasicOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4495032194360898129</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalPageOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8395034761202954774</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PhysicalUndoOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1629730437784173653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.PurgeOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1815947391742392482</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.RemoveFileOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9128463506137321686</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.SetReservedSpaceOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452338843997645457</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateFieldOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8729716610518008479</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.data.UpdateOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5022439034409403549</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.CheckpointOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3547334483634107987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.ChecksumOperation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2603075230783601529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6822213548599245381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.log.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6549540354718798294</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.BeginXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1675099279475574863</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.EndXact</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3814049087240034502</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.GlobalXactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3675162292673048435</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7367956979044103797</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.TransactionTableEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7684636587849580178</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.derby.impl.store.raw.xact.XactId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2802828528732192420</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedConnectionPoolDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7852784308039674160</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4945135214995641181</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.EmbeddedXADataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5715798975598379738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.derby.jdbc.ReferenceableDataSource</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1872877359127597176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.ProvisionNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4479121426311014469</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.RollingCalendar</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3560331770601814177</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5695670494782816506</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.DetailPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-183716192697269830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>396456838584537074</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.LoadXMLAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1959519697665333576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.Main</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6679218458268861656</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.chainsaw.MyTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2394739789728444307</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.config.PropertySetterException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1352613734254235861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.AbsoluteTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-388856345976723342</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.DateTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5547637772208514971</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.ISO8601DateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-759840745298755296</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.helpers.RelativeTimeDateFormat</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7055751607085611984</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.Log4JLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6229073500826714757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5251735053323350105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogLevelFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4274666161838212273</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.LogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3544820201891844767</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.util.AdapterLogRecord</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5682197585320945004</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.FilteredLogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8992671089131499904</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5Dialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8659689967961501340</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5ErrorDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1308340769672017318</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5InputDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6751965584219214443</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogFactor5LoadingDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-477909513711973458</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4867085140195148458</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4275827753626456547</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableColumnFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6529165785030431653</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593300685868700894</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.LogTableRowRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3951639953706443213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerModel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3413887384316015901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryExplorerTree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8066257446951323576</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5958994817693177319</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeEditorRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6094804684259929574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.lf5.viewer.categoryexplorer.CategoryNodeRenderer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6046702673278595048</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LocationInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1325822038990805636</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.LoggingEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-868428216207166145</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.apache.log4j.spi.ThrowableInformation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4748765566864322735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.ClassInstanceAdvisor</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3057976129116723527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.DispatcherConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1502745917111812781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.NotFoundInDispatcherException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5020740195889379757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.AnnotationParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>122998472196736778</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8256510811060336766</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTag</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.annotation.compiler.AnnotationDocletTagFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.instrument.TransformationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9087730534133925094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.CallerInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303974658</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776303875808</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructionInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7005423783330774114</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4671110715707463304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3045541205784967429</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1003170617993582707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6968523285026078131</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7880020293056198584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.ConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1092370003103163067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040602776393748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3337041720097890861</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldReadInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7595351292713886213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6795964118579848645</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.FieldWriteInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5435217977419419783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationBase</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4880246394729260729</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.InvocationResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2974596986988236395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6156314852981932065</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByConstructorInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4578273471486761147</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7826653633415463825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodCalledByMethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3078730663855284320</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1313717554016611763</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.joinpoint.MethodInvocationWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6399861718513077210</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3873275588469743345</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.metadata.SimpleMetaData$MetaDataValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8024138149680591337</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.ParseException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6640507307072022813</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.PointcutExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4076294802573243474</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TokenMgrError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7207593606482597998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.pointcut.ast.TypeExpressionParser$LookaheadSuccess</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8588935251567280090</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ClassProxyTemplate</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7776009946350762531</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledClassProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4049171769644464715</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.MarshalledInterfaceProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7939451715003985857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.Proxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6040609385293748583</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMethodInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2451434088790560691</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.proxy.ProxyMixin</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6150046185716362835</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.standalone.Package</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6188655039267365373</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.aop.util.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7688683906350419871</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.CacheException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-343717717992472642</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ConfigureException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1937579864964670681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Fqn</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5351930616956603651</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.GlobalTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8011434781266976149</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Modification</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3074622985730129009</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5040432493172658796</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.NodeNotExistsException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>779376138690777440</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.OptimisticTreeNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7000622696587912654</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.RegionNotEmptyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.ReplicationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2141504272926290430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.SuspectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2965599037371850141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8576324868563647538</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3593129982953807846</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5568518714172267901</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8895044368299888998</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1578599138419577069</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5577441016277949170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3796901116451916116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8985697625953238855</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1242167331988194987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7656592171312920825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7084928639244438800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$CommitTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5426108920883879873</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$EvictAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6007500908549034215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5364163916172148038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$LoadAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6998760732995584428</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4882445905140460053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2171307516592250436</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6894888234400908985</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3746013603940497991</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$RollbackTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4836748411400541430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.TreeCacheGui2$StartTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7059131008813144857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.AOPInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6492134565825613209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1242167331988194987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7656592171312920825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7084928639244438800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$CommitTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5426108920883879873</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$EvictAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6007500908549034215</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5364163916172148038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$LoadAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6998760732995584428</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4882445905140460053</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$PrintLockInfoAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2171307516592250436</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$ReleaseAllLocksAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6894888234400908985</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3746013603940497991</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$RollbackTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4836748411400541430</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.TreeCacheGui2$StartTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7059131008813144857</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.aop.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-402153636437493134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.buddyreplication.BuddyGroup</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5391883716108410301</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.EvictionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4006783737166646935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.eviction.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6796150029431162837</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.NodeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7571995794010294485</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.jdbm.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1337133713374690630</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.loader.rmi.RemoteTreeCacheImpl</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3096209368650710385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.DeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8651993450626741020</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5551396474793902133</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.OwnerNotExistedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2837393571654438480</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8096787619908687038</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.lock.UpgradeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5683212651728276028</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.JBCMethodCall</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4826713878871338199</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.MarshallingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5991339859063633060</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7719282503234213209</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.RegionNotFoundException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7321547249627414140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.marshall.TreeCacheMarshaller140$InactiveRegionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9185166496920885771</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.DefaultDataVersion</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6896315742831861046</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.optimistic.FqnComparator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-102183636437493134</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.rpc.NoHandlerForRPCException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.BatchModeTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5656602677430350961</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyBaseTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6716097342564237376</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyTransactionManager</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4396695354693176535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.cache.transaction.DummyUserTransaction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6568400755677046127</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1416258464473965574</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1131841473723490707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.DeploymentState</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2319062412502366783</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.IncompleteDeploymentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1428860525880893167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SerializableDeploymentInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3847995513551913798</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.deployment.SubDeployerSupport$ClassConfiguration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2716929675748339631</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7679468692447241311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3507018102770233526</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5117370636698417671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.InvocationType</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6460196085190851775</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-718723094688127810</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.MarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1527598981234110311</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.PayloadKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5436722659170811314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.ServiceUnavailableException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3739642441706165948</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.http.interfaces.HttpInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8249272784108192267</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3713605626489646730</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.jrmp.server.JRMPInvoker_Stub</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledInvocation</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-728630295444149842</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.PooledMarshalledValue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1265347772036749711</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.invocation.pooled.interfaces.ServerAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7206359745950445445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.lang.Enum</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8923967787677833913</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.DynamicLogger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5963699806863917370</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.logging.Logger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4232175575988879434</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.capability.OptimizedMBeanDispatcher$MethodEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1792631947840418314</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.interceptor.InterceptorNameConflictException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-696843094576327612</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.loading.LoaderRepositoryFactory$LoaderRepositoryConfig</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4226952985429700362</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.metadata.IllegalPropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1025239559959501272</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.notification.NotificationFilterProxy</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.ServerObjectInstance</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1829209376363828441</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.server.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5392945073280632822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.InstanceOfQueryExp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5765353862268810105</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotCompliantMBeanException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7441880585611238427</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JBossNotificationFilterSupport</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6442164418782871672</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.JMXInvocationHandler</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3714728148040623702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.MBeanProxyCreationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1008637966352433381</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.mx.util.RuntimeProxyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1166909485463779459</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.ExternalContext$SerializableInitialContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6512260531255770463</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.naming.LinkRefPair</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6036946190113161492</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.DefaultSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7626239955727142958</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.QueuedClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6566809337830221375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.RMIMultiSocketClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-945837789475428529</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutClientSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-920483051658660269</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.net.sockets.TimeoutServerSocketFactory</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7006964274840965634</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.exception.SerializationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3062277762364420025</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.io.MarshalledObject</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1433248532959364465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.io.MarshalledObjectForLocalCalls</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>785809358605094514</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.objectmetamodel.DataContainer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3236513144029944743</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.util.ClassMetaConsts$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>667419958363983355</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.serial.util.FastHashMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4949142555614032</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ConfigurationException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1841403351768037738</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.InvalidAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>785817154841571537</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.system.MissingAttributeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2104972080882639099</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.ServiceContext</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7461263042948325633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.system.filterfactory.DeploymentInfoNotificationFilterFactory$DeploymentInfoNotificationFilter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5067618040005609685</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.AbstractNestedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7384049506870825781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.CoercionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3248954334700890176</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7736259185393081556</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6024309396861726945</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2161377898611431781</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4683457706354663230</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Counter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1803971437884946242</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.DataConversionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6287439477349036488</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.EmptyStringException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7958716001355854762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.HashCode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2391396931740264021</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.JBossStringBuilder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1874946609763446794</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1615297462859270139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8903330696503363758</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$2</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8902748795144754375</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$3</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2584758778978644599</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.LongCounter$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6720507617603163762</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4135571897343827853</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7003381223684751953</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9017248167673450852</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NestedSQLException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8348882503434035185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NoSuchMethodException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3044955578250977290</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotCoercibleException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1125062352267547279</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NotImplementedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3915801189311749818</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.Null</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-403173436435490144</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.NullArgumentException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2308503249278841584</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6077429788585907990</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StackTrace$Entry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7013023772762859280</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4628094303187435707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$1</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6284244000894114817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.StopWatch$Wrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6859401939735540773</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnexpectedThrowable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4318032849691437298</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.UnreachableStatementException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6741968131968754812</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ArrayIterator</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6604583440222021075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1470947618739421094</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.CompoundKey</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1181463173922935047</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.EmptyCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4562591066479152759</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.FullCollectionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1795773071357559465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.ListSet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7333619218072079496</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.collection.SerializableEnumeration</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8678951571196067510</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.deadlock.ApplicationDeadlockException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-908428091244600395</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.GUID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3289509836244263718</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.UID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8093336932569424512</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.id.VMID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4339675822939194520</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.platform.PID</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6837013326314943907</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyContainer</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3347198703863412326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyError</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4956548740655706282</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyEvent</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5007209897739884086</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>452085442436956822</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyGroup</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2557641199743063159</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.property.PropertyMap</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8747802918099008518</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.state.IllegalTransitionException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3392564168782896452</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.BlockingMode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9102277941374138830</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.StartTimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2287779538710535096</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.TaskStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5166095239829218680</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolFullException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1044683480627340299</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.util.threadpool.ThreadPoolStoppedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8732248855455909385</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8229078720076583113</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-33504134223704483</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3196504305414545949</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xb.binding.SimpleTypeBindings</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4372272109355825813</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3813878809953971710</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBRuntimeException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-62219642166721806</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.JBossXBValueFormatException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>615315465309975801</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jboss.xml.binding.TypeBinding</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2815361862736153588</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5172168752255182905</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6041194633384856098</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ChannelNotConnectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6701630538465783064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3786054325601841062</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.MergeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8985324000079821575</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.Message</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1137364035832847034</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.SuspectedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6663279911010545655</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.TimeoutException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3555655828017487825</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.View</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7951521970381323220</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.ViewId</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2406586625701309394</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4974051451573194550</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$AcquireLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6598500471822545410</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$LockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2390958863499216170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$MultiLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4891399452467586184</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedLockManager$ReleaseLockDecree</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3535306842096930972</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.DistributedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4448104853965887333</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockMultiLockedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3719208228960070835</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotGrantedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4074824788210185433</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockNotReleasedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-350403929687059570</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LockingException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-712594616520011007</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$AllLinksDown</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3329785688905216843</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.LogicalLink$NoLinksAvailable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5250951711707663051</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.MethodCall</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7873471327078957662</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.NotificationBus$Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6133287486444083527</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.PullPushAdapter$PullHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-425784033525973495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2839144558164277978</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedHashtable$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8654791037075308304</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6627736371945009800</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicatedTree$Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7996418731426358548</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.ReplicationData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3945713445332028341</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.RequestCorrelator$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1355113470549886388</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.TwoPhaseVotingAdapter$TwoPhaseWrapper</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5874214163436160067</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.UpdateException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4196360091623991749</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VoteException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-878345689312038489</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$FailureVoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2809813561621497082</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.VotingAdapter$VoteResult</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3613490568129896140</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.blocks.Xid</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4409463369646897707</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.Debugger</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3701761931144574138</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.ProtocolSpecificView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7896517829304370211</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.debug.QUEUEView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7798060311888236141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.CausalMessage</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>780718666884109552</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedHashtableDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4702508639852294344</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedQueueDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7622390100963225361</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DistributedTreeDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-565717619547736367</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2259064207678152243</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Draw2Channels$DrawPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-159139558962652075</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.DrawCommand</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-539152912005072037</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$Command</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4589357003632171240</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Gossip$MyPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3949118385264358535</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyCanvas</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>830341371019288303</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5880115553330291212</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.QuoteClient</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6330572389849611533</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5845856017238569017</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddModifyDataForNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1981454998903219877</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$AddNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-844842002708012312</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$ExitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4254284786559213346</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$MyNode</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3884349667401210895</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.ReplicatedTreeDemo$ReplicatedTreeView$RemoveNodeAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7021074808114540717</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.Topology</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>236052619433869252</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotOrderRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8946333513205704225</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalOrder</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3913436032289156789</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-949231907799007987</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ColorPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3802922492190502041</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$ControlPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7659975100736213568</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$StackPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7585339684267647405</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TotalPayload</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-936838583748491815</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.TotalTokenDemo$TransmitAction</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4976326672958441937</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.applets.DrawApplet</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1812007671597941681</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.ApplFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3111759067157049661</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.GraphPanel</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8781854313694553931</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.MessageDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2502100249420840495</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Node</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1397067405132982188</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.SendDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3758787152935146447</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.UserInfoDialog</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4133061180336572911</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.demos.wb.Whiteboard</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3599910164817537912</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotConnectException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7472528586067210747</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotCreateSchemaException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>291582260022140141</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotPersistException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5157400778265186170</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRemoveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5777024088921236116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.persistence.CannotRetrieveException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2523227229540681597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.BSH$BshHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4576592161896066369</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.CAUSAL$CausalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5498836339436997735</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.COMPRESS$CompressHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>9007677999985085671</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1750370226005341630</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-493110511193765483</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT14KeystoreTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>468730481838883343</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPT1_4$EncryptHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4903164192583500536</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ENCRYPTAsymmetricTest$MockAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1481286172666845689</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ExampleHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8802317525466899597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FC$FcHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3840833975071138348</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3731636052308949891</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PID$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4600042790162330443</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_PROB$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6777017945644585942</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SIMPLE$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1167997177583945633</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FD_SOCK$FdHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6065036375091933922</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FLOW_CONTROL$FCInfo</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8365016426836017979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.FragHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>303445567493545979</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.HTOTAL$HTotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8092873137976165925</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.JMS$JMSAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-9151895560870256305</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE$MergeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6346602920868031157</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGE3$CoordAnnouncement</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5948313354065175200</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MERGEFAST$MergefastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-782778793678079625</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.MyFrame</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>487398390724731968</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8532981008982895761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PARTITIONER$PartitionerHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8563054383219742124</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PIGGYBACK$PiggybackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1931866452789177725</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfEntry</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5047065595618076465</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PerfHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5406011340890407404</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1958058124186816135</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.PingRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3634334590904551586</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.SMACK$SmackHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8177663976610985214</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.StateTransferRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7734608266762273116</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL$Header</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7091158323788670702</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_OLD$TotalHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3598787459743933165</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$RingTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4983650106365326055</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TOTAL_TOKEN$TotalTokenHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3697698829445754100</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TcpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5866113771133701445</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1534098872369632339</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TransportedVectorTime</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5857647322589533545</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.TunnelHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7822714431468070313</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UNICAST$UnicastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4896559077682024829</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.UdpHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>3935211140277615207</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.VERIFY_SUSPECT$VerifyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1941838263961448659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.VIEW_SYNC$ViewSyncHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5910687336210920515</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WANPIPE$WanPipeHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1626305070273536659</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.WanPipeAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7341271304287013960</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Digest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2839796319279463477</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.GMS$GmsHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8861180924110146917</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.Gossip</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7954243278668401185</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="hasExplicitSerialVersionUID"> 
  +   <boolean>true</boolean> 
  +  </void> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.JoinRsp</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2949193438640587597</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.MergeData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1496122908046351262</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.NakAckHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5691816788765283064</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.PbcastHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6557298950278459935</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STABLE$StableHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-8197777278200741406</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.pbcast.STATE_TRANSFER$StateHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-842305656159159756</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.RingToken</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5130788718652902761</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.protocols.ring.TokenLostException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>5113234317099931071</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.GossipData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2701708796024030817</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.IpAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2592301708270771474</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.stack.LogicalAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>188526730199324927</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryPacket</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2592954324310791792</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryRequest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7587678128986493349</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.DiscoveryResponse</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>6862354518175504139</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.EncryptOrderTestHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-122667245978500378</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.GroupRequestPull$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2311007561500635146</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PartitionerTest</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>4585450199569162213</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.PerfTest$MyHeader</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8693769141297219569</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.QueueTest2$MyQueue</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-5186485528289936315</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Data</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>8623669553705606167</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$StartData</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2149929336279677323</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest$Value</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-1784650063567334404</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.UnicastTest2$UnicastTest2Info</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>7649416783110380750</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptjms.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-3593032375684821491</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.tests.adaptudp.Request</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1467866650151597943</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.BoundedList</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7424651402352421757</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.List</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>2387756625721721326</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Proxy$MyInetSocketAddress</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-6613080612560649839</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.QueueClosedException</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-7575787375592873964</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Range</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>1895551925607652646</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.Stack</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-2156560026798275993</long> 
  +  </void> 
  + </object> 
  + <object class="org.jboss.tools.ClassVersionInfo"> 
  +  <void property="name"> 
  +   <string>org.jgroups.util.TimedWriter$Timeout</string> 
  +  </void> 
  +  <void property="serialVersion"> 
  +   <long>-4848606759617898619</long> 
  +  </void> 
  + </object> 
  +</java> 
  
  
  


From bwang at jboss.com  Fri Dec 29 23:30:31 2006
From: bwang at jboss.com (Ben Wang)
Date: Fri, 29 Dec 2006 23:30:31 -0500
Subject: [jboss-cvs] JBossCache/tests-50/functional/org/jboss/cache/pojo  ...
Message-ID: <E1H0Vrb-0002by-1P@committer01.frg.pub.inap.atl.jboss.com>

  User: bwang   
  Date: 06/12/29 23:30:31

  Modified:    tests-50/functional/org/jboss/cache/pojo  LocalTxTest.java
  Log:
  Added test for concurrent attach.
  
  Revision  Changes    Path
  1.5       +103 -0    JBossCache/tests-50/functional/org/jboss/cache/pojo/LocalTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/LocalTxTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- LocalTxTest.java	31 Oct 2006 11:07:17 -0000	1.4
  +++ LocalTxTest.java	30 Dec 2006 04:30:31 -0000	1.5
  @@ -296,6 +296,109 @@
                 2, size);
      }
   
  +   public void testConcurrentPutsNoWait() throws Exception
  +   {
  +      Thread t1 = new Thread("t1")
  +      {
  +         UserTransaction tx;
  +
  +         public void run()
  +         {
  +            try
  +            {
  +               for(int i=0; i< 10; i++)
  +               {
  +               Person p = createPerson("/p1/test7", "p6", 50);
  +               List<String> lang = new ArrayList<String>();
  +               tx = getTransaction();
  +               tx.begin();
  +               lang.add("German");
  +               lang.add("English");
  +               try {
  +                 p.setLanguages(lang);
  +               } catch (PojoCacheException ex)
  +               {
  +                  ex.printStackTrace();
  +               }
  +               tx.commit();
  +               TestingUtil.sleepThread(20); // give Thread1 time to createPerson
  +               }
  +            }
  +            catch (RollbackException rollback)
  +            {
  +               ;
  +            }
  +            catch (Exception ex)
  +            {
  +               t1_ex = ex;
  +            }
  +         }
  +      };
  +
  +      Thread t2 = new Thread("t2")
  +      {
  +         UserTransaction tx;
  +
  +         public void run()
  +         {
  +            try
  +            {
  +               for(int i=0; i< 10; i++)
  +               {
  +               Person p = createPerson("/p2/test8", "p6", 50);
  +               List<String> lang = new ArrayList<String>();
  +               tx = getTransaction();
  +               tx.begin();
  +               lang.add("German");
  +               lang.add("English");
  +                  try {
  +                    p.setLanguages(lang);
  +                  } catch (PojoCacheException ex)
  +                  {
  +                     ex.printStackTrace();
  +                  }
  +               tx.commit();
  +               TestingUtil.sleepThread(20); // give Thread1 time to createPerson
  +               }
  +            }
  +            catch (RollbackException rollback)
  +            {
  +               ;
  +            }
  +            catch (Exception ex)
  +            {
  +               try
  +               {
  +                  tx.rollback();
  +               } catch (SystemException e)
  +               {
  +                  e.printStackTrace();
  +                  t2_ex = e;
  +               }
  +            }
  +         }
  +      };
  +
  +      Person p1 = createPerson("/p1/test6", "p6", 50);
  +      Person p2 = createPerson("/p2/test6", "p6", 50);
  +
  +      t1.start();
  +      t2.start();
  +
  +      t1.join();
  +      t2.join();
  +
  +      // t2 should rollback due to timeout while t2 should succeed
  +      if (t2_ex != null)
  +         fail("Thread1 failed: " + t2_ex);
  +      if (t1_ex != null)
  +         fail("Thread2 failed: " + t1_ex);
  +
  +      int size = ((Person) cache.find("/p1/test7")).getLanguages().size();
  +      assertEquals("number of languages ",
  +              2, size);
  +   }
  +
      void log(String s)
      {
         long now;
  
  
  


From fycvt789dsfa at kittymail.com  Sat Dec 30 00:51:45 2006
From: fycvt789dsfa at kittymail.com (fycvt789dsfa at kittymail.com)
Date: Sat, 30 Dec 2006 00:51:45 -0500
Subject: [jboss-cvs] =?utf-8?b?wo3CocKCwqnCgsOnwoLCoMKCwqbCgsOpwoFI?=
Message-ID: 20061230145729.23162mail@mail.miuyyiuhjsadyttyreeweyugsdasacvsm.com

?????????????????????????????????C???c?B
???????????????????H
???t?????????????????c?A???????????B
http://www.go-perfectfree.com.tonderuyo.com/dodo/




From forge-admin at jboss.com  Sat Dec 30 01:00:27 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sat, 30 Dec 2006 01:00:27 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1H0XGd-00041g-Ee@committer01.frg.pub.inap.atl.jboss.com>

Commit from rsigal on branch remoting_2_x (2006-12-29 01:31 EST)
-----------------------------------------

JBREM-650:  Remove some log statements accidentally commited.

  JBossRemoting  src/main/org/jboss/remoting/ServerInvoker.java  1.52.2.7


Commit from rsigal on branch remoting_2_x (2006-12-29 01:33 EST)
-----------------------------------------

JBREM-650:  Removed log.info() accidentally committed.

  JBossRemoting  src/main/org/jboss/remoting/ServerInvoker.java  1.52.2.8


Commit from rsigal on branch remoting_2_x (2006-12-29 01:46 EST)
-----------------------------------------

JBREM-650:  Added test method for restarted Connector.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java  1.1.2.4


Commit from rsigal (2006-12-29 01:46 EST)
------------------

JBREM-650:  Added test method for restarted Connector.

  JBossRemoting  src/tests/org/jboss/test/remoting/transport/bisocket/BisocketTestCase.java  1.4


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-29 09:27 EST)
------------------------------------------------------

JBCACHE-917

  JBossCache  src/org/jboss/cache/marshall/JBCMethodCall.java  1.4.2.2


Commit from msurtani on branch Branch_JBossCache_1_4_0 (2006-12-29 09:40 EST)
------------------------------------------------------

added svuid

  JBossCache  src/org/jboss/cache/OptimisticTreeNode.java  1.13.2.1


Commit from msurtani (2006-12-29 09:46 EST)
--------------------

Removed serializable

  JBossCache  src/org/jboss/cache/optimistic/FqnComparator.java  1.6
  JBossCache  src/org/jboss/cache/NodeImpl.java                  1.31


Commit from msurtani (2006-12-29 10:11 EST)
--------------------

Added javadoc

  JBossCache  src/org/jboss/cache/optimistic/DataVersion.java  1.3


Commit from msurtani (2006-12-29 10:18 EST)
--------------------

Enhanced marshalling for default data versions

  JBossCache  src/org/jboss/cache/marshall/TreeCacheMarshaller200.java  1.11
  JBossCache  src/org/jboss/cache/optimistic/DefaultDataVersion.java    1.7


Commit from nrichards (2006-12-29 15:18 EST)
---------------------

date format appears to be incompatible with Java 6 (jdbc 4.0 issue?)

  jboss-seam  examples/messages/resources/import.sql  1.2


Commit from bwang (2006-12-29 21:53 EST)
-----------------

JBCACHE-919 Optimize __JBossInternal__ access.

  JBossCache  src-50/org/jboss/cache/pojo/impl/PojoCacheDelegate.java  1.17


Commit from bwang (2006-12-29 22:56 EST)
-----------------

Throw a more verbose rollback exception in PojoCacheException.

  JBossCache  src-50/org/jboss/cache/pojo/interceptors/PojoTxInterceptor.java  1.8


Commit from bwang (2006-12-29 23:07 EST)
-----------------

Created to test lock time out exception for PojoCache rollback.

+ JBossCache  tests-50/functional/org/jboss/cache/pojo/rollback/LocalExceptionUndoTest.java  1.1


Commit from bwang (2006-12-29 23:30 EST)
-----------------

Added test for concurrent attach.

  JBossCache  tests-50/functional/org/jboss/cache/pojo/LocalTxTest.java  1.5
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061230/f4494398/attachment.html 

From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:15:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:15:04 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1871 -
	branches/Branch_Bisocket_Experiment/src/main/org/jboss/jms/client/remoting
Message-ID: <E1H0YQq-0005Qa-GT@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:15:02 -0500 (Sat, 30 Dec 2006)
New Revision: 1871

Modified:
   branches/Branch_Bisocket_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
Log:
JBMESSAGING-694: Added support for bisocket transport.

Modified: branches/Branch_Bisocket_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java
===================================================================
--- branches/Branch_Bisocket_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-29 03:02:10 UTC (rev 1870)
+++ branches/Branch_Bisocket_Experiment/src/main/org/jboss/jms/client/remoting/JMSRemotingConnection.java	2006-12-30 07:15:02 UTC (rev 1871)
@@ -30,6 +30,7 @@
 import org.jboss.remoting.Client;
 import org.jboss.remoting.InvokerLocator;
 import org.jboss.remoting.callback.CallbackPoller;
+import org.jboss.remoting.transport.bisocket.Bisocket;
 import org.jboss.remoting.transport.socket.MicroSocketClientInvoker;
 import org.jboss.remoting.transport.socket.SocketServerInvoker;
 
@@ -103,7 +104,11 @@
 
       // For socket transport allow true push callbacks, with callback Connector.
       // For http transport, simulate push callbacks.
-      boolean doPushCallbacks = "socket".equals(serverLocator.getProtocol());
+      String protocol = serverLocator.getProtocol();
+      boolean isBisocket = "bisocket".equals(protocol) || "sslbisocket".equals(protocol);
+      boolean isSocket   = "socket".equals(protocol)   || "sslsocket".equals(protocol);
+      boolean doPushCallbacks = isBisocket || isSocket;
+      
       if (doPushCallbacks)
       {
          if (log.isTraceEnabled()) log.trace("doing push callbacks");
@@ -112,6 +117,9 @@
          metadata.put(InvokerLocator.SERIALIZATIONTYPE, "jms"); //Not actually used at present - but it does no harm         
          metadata.put(MicroSocketClientInvoker.CLIENT_SOCKET_CLASS_FLAG, "org.jboss.jms.client.remoting.ClientSocketWrapper");
          metadata.put(SocketServerInvoker.SERVER_SOCKET_CLASS_FLAG, "org.jboss.jms.server.remoting.ServerSocketWrapper");
+       
+         if (isBisocket)
+            metadata.put(Bisocket.IS_CALLBACK_SERVER, "true");
          
          String bindAddress = System.getProperty("jboss.messaging.callback.bind.address");
          if (bindAddress != null)



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:20:37 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:20:37 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1872 -
	branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1H0YWD-0005XW-85@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:20:34 -0500 (Sat, 30 Dec 2006)
New Revision: 1872

Modified:
   branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
Log:
JBMESSAGING-694: Closed connections in a couple of places.

Modified: branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-30 07:15:02 UTC (rev 1871)
+++ branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-30 07:20:34 UTC (rev 1872)
@@ -1333,6 +1333,7 @@
          sessReceive.commit();
 
          cons.close();
+         connReceive.close();
 
 
          connReceive = cf.createConnection();
@@ -2077,7 +2078,8 @@
    public void testTwoConsumersNonTransacted() throws Exception
    {
 
-      consumerSession.close();
+//      consumerSession.close();
+      consumerConnection.close();
 
       TextMessage tm = producerSession.createTextMessage();
       tm.setText("One");
@@ -2111,7 +2113,8 @@
    public void testTwoConsumersTransacted() throws Exception
    {
 
-      consumerSession.close();
+//      consumerSession.close();
+      consumerConnection.close();
 
       TextMessage tm = producerSession.createTextMessage();
       tm.setText("One");



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:21:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:21:19 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1873 -
	branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms
Message-ID: <E1H0YWt-0005Zd-77@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:21:18 -0500 (Sat, 30 Dec 2006)
New Revision: 1873

Modified:
   branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java
Log:
JBMESSAGING-694:  Extended test and added support for bisocket transport.

Modified: branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java
===================================================================
--- branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java	2006-12-30 07:20:34 UTC (rev 1872)
+++ branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/jms/RemotingConnectionConfigurationTest.java	2006-12-30 07:21:18 UTC (rev 1873)
@@ -152,12 +152,18 @@
 
       try
       {
+         String address = InetAddress.getLocalHost().getHostAddress();
+         System.setProperty("jboss.messaging.callback.bind.address", address);
+         log.info("address: " + address);
+         
          int freePort = PortUtil.findFreePort(InetAddress.getLocalHost().getHostName());
          System.setProperty("jboss.messaging.callback.bind.port", Integer.toString(freePort));
 
          String pollPeriod = "654";
          System.setProperty("jboss.messaging.callback.pollPeriod", pollPeriod);
 
+         System.setProperty("jboss.messaging.callback.reportPollingStatistics", "true");
+         
          connection = (JBossConnection)cf.createConnection();
          connection.start();
 
@@ -170,7 +176,10 @@
          InvokerLocator locator = (InvokerLocator)field.get(remotingConnection);
          String transport = locator.getProtocol();
 
-         if ("socket".equals(transport))
+         if ("socket".equals(transport)
+               || "sslsocket".equals(transport)
+               || "bisocket".equals(transport)
+               || "sslbisocket".equals(transport))
          {
             field = Client.class.getDeclaredField("callbackConnectors");
             field.setAccessible(true);
@@ -179,6 +188,7 @@
             InvokerCallbackHandler callbackHandler = remotingConnection.getCallbackManager();
             Connector connector = (Connector)callbackConnectors.get(callbackHandler);
             locator = new InvokerLocator(connector.getInvokerLocator());
+            assertEquals(address, locator.getHost());
             assertEquals(freePort, locator.getPort());
          }
          else if ("http".equals(transport))
@@ -193,8 +203,11 @@
 
             field = CallbackPoller.class.getDeclaredField("pollPeriod");
             field.setAccessible(true);
-
             assertEquals(pollPeriod, ((Long)field.get(callbackPoller)).toString());
+            
+            field = CallbackPoller.class.getDeclaredField("reportStatistics");
+            field.setAccessible(true);
+            assertEquals(true, ((Boolean) field.get(callbackPoller)).booleanValue());
          }
          else
          {



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:22:13 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:22:13 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1874 -
	branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/tools/jmx
Message-ID: <E1H0YXl-0005aL-2V@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:22:12 -0500 (Sat, 30 Dec 2006)
New Revision: 1874

Modified:
   branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
Log:
JBMESSAGING-694:  Added support for bisocket transport.

Modified: branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-30 07:21:18 UTC (rev 1873)
+++ branches/Branch_Bisocket_Experiment/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-30 07:22:12 UTC (rev 1874)
@@ -1178,6 +1178,13 @@
       {
          params += "&timeout=0";
       }
+      
+      if ("sslbisocket".equals(transport) || "sslsocket".equals(transport))
+      {
+         System.setProperty("javax.net.ssl.keyStorePassword", "secureexample");
+         String keyStoreFilePath = this.getClass().getResource("../../../../../../../etc/messaging.keystore").getFile();
+         System.setProperty("javax.net.ssl.keyStore", keyStoreFilePath);
+      }
 
       int freePort = PortUtil.findFreePort(ipAddressOrHostName);
       String locatorURI = transport + "://" + ipAddressOrHostName + ":" + freePort + params;



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:30:02 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:30:02 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1875 -
	branches/Branch_Bisocket_Experiment/docs/examples/secure-socket/etc
Message-ID: <E1H0YfK-0005fo-Kj@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:30:01 -0500 (Sat, 30 Dec 2006)
New Revision: 1875

Modified:
   branches/Branch_Bisocket_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml
Log:
JBMESSAGING-694: Changed transport from sslsocket to sslbisocket.

Modified: branches/Branch_Bisocket_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml
===================================================================
--- branches/Branch_Bisocket_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml	2006-12-30 07:22:12 UTC (rev 1874)
+++ branches/Branch_Bisocket_Experiment/docs/examples/secure-socket/etc/messaging-secure-socket-service.xml	2006-12-30 07:30:01 UTC (rev 1875)
@@ -18,7 +18,7 @@
           display-name="SSL Socket Transport Connector">
       <attribute name="Configuration">
          <config>
-            <invoker transport="sslsocket">
+            <invoker transport="sslbisocket">
                <attribute name="marshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
                <attribute name="unmarshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
                <attribute name="serializationtype" isParam="true">jms</attribute>



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:31:04 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:31:04 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1876 -
	branches/Branch_Bisocket_Experiment/src/etc/server/default/deploy
Message-ID: <E1H0YgK-0005i5-TS@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:31:04 -0500 (Sat, 30 Dec 2006)
New Revision: 1876

Modified:
   branches/Branch_Bisocket_Experiment/src/etc/server/default/deploy/remoting-service.xml
Log:
JBMESSAGING-694: Changed transport from socket to bisocket.

Modified: branches/Branch_Bisocket_Experiment/src/etc/server/default/deploy/remoting-service.xml
===================================================================
--- branches/Branch_Bisocket_Experiment/src/etc/server/default/deploy/remoting-service.xml	2006-12-30 07:30:01 UTC (rev 1875)
+++ branches/Branch_Bisocket_Experiment/src/etc/server/default/deploy/remoting-service.xml	2006-12-30 07:31:04 UTC (rev 1876)
@@ -13,7 +13,7 @@
           display-name="Socket transport Connector">
       <attribute name="Configuration">
          <config>
-            <invoker transport="socket">
+            <invoker transport="bisocket">
                <attribute name="marshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
                <attribute name="unmarshaller" isParam="true">org.jboss.jms.server.remoting.JMSWireFormat</attribute>
                <!-- Serialization type must be jms - do not change! -->



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 02:32:10 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 02:32:10 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1877 -
	branches/Branch_Bisocket_Experiment/tests/etc
Message-ID: <E1H0YhO-0005kb-Tz@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 02:32:10 -0500 (Sat, 30 Dec 2006)
New Revision: 1877

Modified:
   branches/Branch_Bisocket_Experiment/tests/etc/container.xml
Log:
JBMESSAGING-694: Changed transport from socket to bisocket.

Modified: branches/Branch_Bisocket_Experiment/tests/etc/container.xml
===================================================================
--- branches/Branch_Bisocket_Experiment/tests/etc/container.xml	2006-12-30 07:31:04 UTC (rev 1876)
+++ branches/Branch_Bisocket_Experiment/tests/etc/container.xml	2006-12-30 07:32:10 UTC (rev 1877)
@@ -69,9 +69,9 @@
    <serialization-type>jms</serialization-type>
 
    <!--
-       Supported values: "socket", "http"
+       Supported values: "bisocket", "sslbisocket", "socket", "sslsocket", "http"
    -->
-   <remoting-transport>socket</remoting-transport>
+   <remoting-transport>bisocket</remoting-transport>
 
    <!--
       Specifies whether to start a clustered messaging server or not. If "test.clustered" is set,



From ron_sigal at yahoo.com  Sat Dec 30 02:47:51 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Sat, 30 Dec 2006 02:47:51 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1H0YwZ-0005y8-Qv@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/30 02:47:51

  Modified:    src/main/org/jboss/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketClientInvoker.java
  Log:
  JBREM-650: (1) Distinguised behavior on client and server; (2) reorganized createSocket(); (3) added controlLock.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.3   +129 -99   JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketClientInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java,v
  retrieving revision 1.1.2.2
  retrieving revision 1.1.2.3
  diff -u -b -r1.1.2.2 -r1.1.2.3
  --- BisocketClientInvoker.java	19 Dec 2006 06:06:06 -0000	1.1.2.2
  +++ BisocketClientInvoker.java	30 Dec 2006 07:47:51 -0000	1.1.2.3
  @@ -22,7 +22,6 @@
   
   package org.jboss.remoting.transport.bisocket;
   
  -import java.io.DataOutputStream;
   import java.io.IOException;
   import java.io.OutputStream;
   import java.net.Socket;
  @@ -32,6 +31,7 @@
   import java.util.Iterator;
   import java.util.Map;
   import java.util.Set;
  +import java.util.Timer;
   import java.util.TimerTask;
   
   import org.jboss.logging.Logger;
  @@ -44,11 +44,20 @@
   import org.jboss.remoting.marshal.UnMarshaller;
   import org.jboss.remoting.transport.BidirectionalClientInvoker;
   import org.jboss.remoting.transport.socket.SocketClientInvoker;
  -import org.jboss.remoting.util.TimerUtil;
   
   /**
  - * BisocketClientInvoker uses Sockets to remotely connect to the a remote ServerInvoker,
  - * which must be a BisocketServerInvoker.
  + * The bisocket transport, an extension of the socket transport, is designed to allow
  + * a callback server to function behind a firewall.  All connections are created by
  + * a Socket constructor or factory on the client side connecting to a ServerSocket on
  + * the server side.  When a callback client invoker on the server side needs to
  + * open a connection to the callback server, it requests a connection by sending a
  + * request message over a control connection to the client side.
  + * 
  + * Because all connections are created in one direction, the bisocket transport is
  + * asymmetric, in the sense that client invokers and server invokers behave differently
  + * on the client side and on the server side.
  + * 
  + * 
    * 
    * @author <a href="mailto:ron.sigal at jboss.com">Ron Sigal</a>
    */
  @@ -58,22 +67,40 @@
   {  
      private static final Logger log = Logger.getLogger(BisocketClientInvoker.class);
      private static Map listenerIdToClientInvokerMap = Collections.synchronizedMap(new HashMap());
  +   private static Map listenerIdToCallbackClientInvokerMap = Collections.synchronizedMap(new HashMap());
      private static Map listenerIdToSocketsMap = new HashMap();
  +   private static Timer timer;
    
  -   private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;;
      protected String listenerId;
  +   
  +   private int pingFrequency = Bisocket.PING_FREQUENCY_DEFAULT;;
      private InvokerLocator secondaryLocator;
      private Socket controlSocket;
      private OutputStream controlOutputStream;
  +   private Object controlLock = new Object();
      private PingTimerTask pingTimerTask;
  +   private boolean isCallbackInvoker;
   
      
  +   /**
  +    * 
  +    * FIXME Comment this
  +    * 
  +    * @param listenerId
  +    * @return
  +    */
      static BisocketClientInvoker getBisocketClientInvoker(String listenerId)
      {
         return (BisocketClientInvoker) listenerIdToClientInvokerMap.get(listenerId);
      }
      
      
  +   static BisocketClientInvoker getBisocketCallbackClientInvoker(String listenerId)
  +   {
  +      return (BisocketClientInvoker) listenerIdToCallbackClientInvokerMap.get(listenerId);
  +   }
  +   
  +   
      static void transferSocket(String listenerId, Socket socket)
      {
         Set sockets = null;
  @@ -111,7 +138,8 @@
            listenerId = (String) config.get(Client.LISTENER_ID_KEY);
            if (listenerId != null)
            {
  -            listenerIdToClientInvokerMap.put(listenerId, this);
  +            isCallbackInvoker = true;
  +            listenerIdToCallbackClientInvokerMap.put(listenerId, this);
               
               synchronized (listenerIdToSocketsMap)
               {
  @@ -119,7 +147,7 @@
                     listenerIdToSocketsMap.put(listenerId, new HashSet());
               }
               
  -            log.info("registered " + listenerId + " -> " + this);
  +            log.debug("registered " + listenerId + " -> " + this);
            }
   
               // look for socketTimeout param
  @@ -151,7 +179,6 @@
      public void setPingFrequency(int pingFrequency)
      {
         this.pingFrequency = pingFrequency;
  -      log.info("set ping frequency: " + pingFrequency);
      }
      
      
  @@ -162,22 +189,13 @@
         // Callback client on server side.
         if (listenerId != null)
         {
  -//         pingTimerTask = new PingTimerTask();
  -//         TimerUtil.schedule(pingTimerTask, pingFrequency);
  -//         log.info("scheduled PingTimerTask");
            return;
         }
         
         // Client on client side.
         try
         {
  -         InternalInvocation ii = new InternalInvocation(Bisocket.GET_SECONDARY_INVOKER_LOCATOR, null);
  -         InvocationRequest r = new InvocationRequest(null, null, ii, null, null, null);
  -//         secondaryLocator = (InvokerLocator) invoke(r);
  -         Object o = invoke(r);
  -         log.info("secondary locator: " + o);
  -         secondaryLocator = (InvokerLocator) o;
  -         log.info("got secondary locator: " + secondaryLocator);
  +         secondaryLocator = getSecondaryLocator();
         }
         catch (Throwable e)
         {
  @@ -192,7 +210,11 @@
         super.handleDisconnect();
         if (listenerId != null)
         {
  +         if (isCallbackInvoker)
  +            listenerIdToCallbackClientInvokerMap.remove(listenerId);
  +         else
            listenerIdToClientInvokerMap.remove(listenerId);
  +
            listenerIdToSocketsMap.remove(listenerId);
            if (pingTimerTask != null)
               pingTimerTask.shutDown();
  @@ -215,6 +237,7 @@
               {
                  Map requestPayload = ir.getRequestPayload();
                  String listenerId = (String) requestPayload.get(Client.LISTENER_ID_KEY);
  +               listenerIdToClientInvokerMap.put(listenerId, this);
                  BisocketServerInvoker callbackServerInvoker;
                  callbackServerInvoker = BisocketServerInvoker.getBisocketServerInvoker(listenerId);
                  callbackServerInvoker.createControlConnection(listenerId, secondaryLocator);
  @@ -231,91 +254,85 @@
         if (listenerId == null)
            return super.createSocket(address, port);
         
  -      Socket socket = null;
         Set sockets = null;
         
         synchronized (listenerIdToSocketsMap)
         {
            sockets = (Set) listenerIdToSocketsMap.get(listenerId);
  -      }
  -      
  -      synchronized (sockets)
  -      {
  -         Iterator it = sockets.iterator();
  -         if (it.hasNext())
  -         {
  -            socket = (Socket) it.next();
  -            it.remove();
  -            
  -            if (controlSocket != null)
  -               return socket;
  -            else
  -            {
  -               controlSocket = socket;
  -               controlOutputStream = controlSocket.getOutputStream();
  -               log.info("got control socket");
  -               pingTimerTask = new PingTimerTask();
  -               TimerUtil.schedule(pingTimerTask, pingFrequency);
  -               log.info("scheduled PingTimerTask");
  -               
  -               if (it.hasNext())
  +         if (sockets == null)
                  {
  -                  socket = (Socket) it.next();
  -                  it.remove();
  -                  return socket;
  -               }
  +            sockets = new HashSet();
  +            listenerIdToSocketsMap.put(listenerId, sockets);
               }
            }
            
            if (controlSocket == null)
            {
  +         synchronized (sockets)
  +         {
  +            if (sockets.isEmpty())
  +            {
               while (true)
               {
                  try
                  {
  -                  sockets.wait(getTimeout());
  -                  if (sockets.isEmpty())
  -                     throw new IOException("Timed out trying to create control socket");
  +                     sockets.wait(1000);
                     break;
                  }
  -               catch (InterruptedException ignored) {}
  +                  catch (InterruptedException ignored)
  +                  {
  +                     log.warn("unexpected interrupt");
  +                  }
  +               }
               }
               
  -            it = sockets.iterator();
  +            if (sockets.isEmpty())
  +               throw new IOException("Timed out trying to create control socket");
  +            
  +            Iterator it = sockets.iterator();
               controlSocket = (Socket) it.next();
  -            controlOutputStream = controlSocket.getOutputStream();
               it.remove(); 
  -            log.info("got control socket");
  +            controlOutputStream = controlSocket.getOutputStream();
  +            log.debug("got control socket");
               pingTimerTask = new PingTimerTask();
  -            TimerUtil.schedule(pingTimerTask, pingFrequency);
  -            log.info("scheduled PingTimerTask");
  +            if (timer == null)
  +            {
  +               timer = new Timer();
  +            }
  +            timer.schedule(pingTimerTask, pingFrequency, pingFrequency);
  +         }
            }
            
  -         log.info("requesting socket");
  -         
  -         synchronized (controlOutputStream)
  +      synchronized (controlLock)
            {
               controlOutputStream.write(Bisocket.CREATE_ORDINARY_SOCKET);
            }
  -//         controlOutputStream.writeUTF(listenerId);
     
  +      synchronized (sockets)
  +      {
  +         if (sockets.isEmpty())
  +         {
            while (true)
            {
               try
               {
  -//               sockets.wait(getTimeout());
                  sockets.wait(1000);
  -               if (sockets.isEmpty())
  -                  throw new IOException("Timed out trying to create socket");
                  break;
               }
  -            catch (InterruptedException ignored) {}
  +               catch (InterruptedException ignored)
  +               {
  +                  log.warn("unexpected interrupt");
  +               }
  +            }
            }
            
  -         it = sockets.iterator();
  -         socket = (Socket) it.next();
  +         if (sockets.isEmpty())
  +            throw new IOException("Timed out trying to create socket");
  +         
  +         Iterator it = sockets.iterator();
  +         Socket socket = (Socket) it.next();
            it.remove();
  -         log.info("got socket: " + socket);
  +         log.debug("socket found");
            return socket;
         }
      }
  @@ -323,21 +340,35 @@
      
      void replaceControlSocket(Socket socket) throws IOException
      {
  -      synchronized (controlSocket)
  +      synchronized (controlLock)
         {
            controlSocket = socket;
  -      }
         controlOutputStream = controlSocket.getOutputStream();
  +         log.debug("replaced control socket");
  +      }
         
         if (pingTimerTask != null)
            pingTimerTask.cancel();
         
         pingTimerTask = new PingTimerTask();
  -      TimerUtil.schedule(pingTimerTask, pingFrequency);
  -      log.info("replaced PingTimerTask");
  +      if (timer == null)
  +      {
  +         timer = new Timer();
  +      }
  +      timer.schedule(pingTimerTask, pingFrequency, pingFrequency);
      }
      
      
  +   InvokerLocator getSecondaryLocator() throws Throwable
  +   {
  +      InternalInvocation ii = new InternalInvocation(Bisocket.GET_SECONDARY_INVOKER_LOCATOR, null);
  +      InvocationRequest r = new InvocationRequest(null, null, ii, null, null, null);
  +      Object o = invoke(r);
  +      log.debug("secondary locator: " + o);
  +      secondaryLocator = (InvokerLocator) o;
  +      return secondaryLocator;
  +   }
  +   
      protected Object checkType(Object o, Class c) throws IOException
      {
         if (c.isInstance(o))
  @@ -386,11 +417,10 @@
         
         public void run()
         {
  -         synchronized (controlOutputStream)
  +         synchronized (controlLock)
            {
               try
               {
  -               log.info("sending ping");
                  controlOutputStream.write(Bisocket.PING);
               }
               catch (IOException e)
  
  
  


From ron_sigal at yahoo.com  Sat Dec 30 02:57:15 2006
From: ron_sigal at yahoo.com (Ron Sigal)
Date: Sat, 30 Dec 2006 02:57:15 -0500
Subject: [jboss-cvs]
	JBossRemoting/src/main/org/jboss/remoting/transport/bisocket ...
Message-ID: <E1H0Z5f-00066a-TC@committer01.frg.pub.inap.atl.jboss.com>

  User: rsigal  
  Date: 06/12/30 02:57:15

  Modified:    src/main/org/jboss/remoting/transport/bisocket  Tag:
                        remoting_2_x BisocketServerInvoker.java
  Log:
  JBREM-650: (1) Replaced TimerUtil with separate Timer; (2) get new secondary locator on restar control connection restart; (3) control connection monitor doesn't fail if callback client never registered; (4) control socket can be created before client invoker is created; (5) control connection is restarted in new thread.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +86 -92    JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BisocketServerInvoker.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -b -r1.1.2.3 -r1.1.2.4
  --- BisocketServerInvoker.java	20 Dec 2006 08:21:01 -0000	1.1.2.3
  +++ BisocketServerInvoker.java	30 Dec 2006 07:57:15 -0000	1.1.2.4
  @@ -35,6 +35,7 @@
   import java.util.Iterator;
   import java.util.LinkedList;
   import java.util.Map;
  +import java.util.Timer;
   import java.util.TimerTask;
   
   import org.jboss.remoting.Client;
  @@ -46,13 +47,12 @@
   import org.jboss.remoting.transport.socket.LRUPool;
   import org.jboss.remoting.transport.socket.ServerThread;
   import org.jboss.remoting.transport.socket.SocketServerInvoker;
  -import org.jboss.remoting.util.TimerUtil;
   
   
   /**
    *  
    * @author <a href="ron.sigal at jboss.com">Ron Sigal</a>
  - * @version $Revision: 1.1.2.3 $
  + * @version $Revision: 1.1.2.4 $
    * <p>
    * Copyright Nov 23, 2006
    * </p>
  @@ -60,6 +60,7 @@
   public class BisocketServerInvoker extends SocketServerInvoker
   {  
      private static Map listenerIdToServerInvokerMap = Collections.synchronizedMap(new HashMap());
  +   private static Timer timer;
   
      private Map listenerIdToInvokerLocatorMap = new HashMap();
      private ServerSocket secondaryServerSocket;
  @@ -78,12 +79,6 @@
      }
      
      
  -//   public static void addBisocketServerInvoker(String listenerId, BisocketServerInvoker invoker)
  -//   {
  -//      listenerIdToServerInvokerMap.put(listenerId, invoker);
  -//   }
  -   
  -   
      public BisocketServerInvoker(InvokerLocator locator)
      {
         super(locator);
  @@ -128,10 +123,8 @@
            secondaryServerSocketThread.setName("secondaryServerSocketThread");
            secondaryServerSocketThread.setDaemon(true);
            secondaryServerSocketThread.start();
  -         log.info("started secondary port: " + host + ":" + freePort);
  +         log.debug("started secondary port: " + host + ":" + freePort);
         }
  -//    ServerInvocationHandler handler = new InternalInvocationHandler(secondaryServerSocket);
  -//    addInvocationHandler(Bisocket.BISOCKET_INTERNAL_SUBSYSTEM, handler);
      }
      
      
  @@ -146,20 +139,30 @@
      {
         boolean firstConnection;
         
  -      // first connection
  +      // restarting connection
         if (locator == null)
         {
            firstConnection = false;
  -         locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
  +         BisocketClientInvoker clientInvoker = BisocketClientInvoker.getBisocketClientInvoker(listenerId);
  +
  +         try
  +         {
  +            locator = clientInvoker.getSecondaryLocator();
         }
  -      // restarted connection
  +         catch (Throwable t)
  +         {
  +            log.error("unable to get secondary locator");
  +            throw new IOException("unable to get secondary locator: " + t.getMessage());
  +         }
  +      }
  +      // first connection
         else
         {
            firstConnection = true;
            listenerIdToInvokerLocatorMap.put(listenerId, locator);
         }
         
  -      log.info("creating control connection: " + locator);
  +      log.debug("creating control connection: " + locator);
         
         Socket socket = null;
         if (socketFactory != null)
  @@ -187,14 +190,16 @@
         }
         
         thread.start();
  -      log.info("created control connection: " + locator);
  +      log.debug("created control connection: " + socket.toString());
         
         if (controlMonitorTimerTask == null)
         {
  +         if (timer == null)
  +         {
  +            timer = new Timer();
  +         }
            controlMonitorTimerTask = new ControlMonitorTimerTask();
  -         TimerUtil.schedule(controlMonitorTimerTask, pingFrequency);
  -         log.info(this + ": scheduled ControlMonitorTimerTask: " + controlMonitorTimerTask);
  -         log.info("pingFrequency: " + pingFrequency);
  +         timer.schedule(controlMonitorTimerTask, pingFrequency, pingFrequency);
         }
      }
      
  @@ -209,7 +214,6 @@
      {
         this.pingFrequency = pingFrequency;
         pingWindow = 2 * pingFrequency;
  -      log.info("set ping frequency: " + pingFrequency);
      }
      
      
  @@ -235,13 +239,10 @@
      protected void cleanup()
      {
         super.cleanup();
  -      log.info(this + ": $$$entering cleanup()");
  -      log.info("controlMonitorTimerTask: " + this.controlMonitorTimerTask);
         
         if (controlMonitorTimerTask != null)
  -      {
            controlMonitorTimerTask.shutdown();
  -      }
  +      
         Iterator it = controlConnectionThreadMap.values().iterator();
         while (it.hasNext())
         {
  @@ -249,19 +250,15 @@
            t.shutdown();
            it.remove();
         }
  -      log.info("secondaryServerSocketThread: " + secondaryServerSocketThread);
  +
         if (secondaryServerSocketThread != null)
  -      {
            secondaryServerSocketThread.shutdown();
  -      }
  +
         if (secondaryServerSocket != null)
         {
            try
            {
               secondaryServerSocket.close();
  -            log.info("closed secondary port: " +
  -                     secondaryServerSocket.getInetAddress() + ":" +
  -                     secondaryServerSocket.getLocalPort());
            }
            catch (IOException e)
            {
  @@ -289,7 +286,6 @@
      {
         if(Bisocket.GET_SECONDARY_INVOKER_LOCATOR.equals(ii.getMethodName()))
         {
  -         log.info("returning secondaryLocator: " + secondaryLocator); 
            return secondaryLocator;
         }
         
  @@ -304,7 +300,6 @@
               if (listenerId != null)
               {
                  listenerIdToServerInvokerMap.put(listenerId, this);
  -               log.info("registered " + listenerId + " -> " + this);
               }
            }
         }
  @@ -320,7 +315,7 @@
         private DataInputStream dis;
         private boolean running;
         private int errorCount;
  -      private long lastPing = System.currentTimeMillis();
  +      private long lastPing = -1;
         
         ControlConnectionThread(Socket socket, String listenerId) throws IOException
         {
  @@ -349,9 +344,16 @@
         
         boolean checkConnection()
         {
  +         if (lastPing < 0)
  +         {
  +            return true;
  +         }
            long currentTime = System.currentTimeMillis();
  -         log.info("elapsed: " + (currentTime - lastPing));
  -         log.info("returning: " + ((currentTime - lastPing > pingWindow) ? false : true)); 
  +         
  +         if (log.isTraceEnabled())
  +         {
  +            log.trace("elapsed: " + (currentTime - lastPing));
  +         }
            return (currentTime - lastPing <= pingWindow);
         }
         
  @@ -362,7 +364,6 @@
         
         public void run()
         {
  -         log.info("starting ControlConnectionThread");
            running = true;
            while (running)
            {
  @@ -376,8 +377,6 @@
                  switch (action)
                  {
                     case Bisocket.CREATE_ORDINARY_SOCKET:
  -//                     String listenerId = dis.readUTF();
  -//                     dis.readUTF();
                        InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(listenerId);
                        if (socketFactory != null)
                           socket = socketFactory.createSocket(locator.getHost(), locator.getPort());
  @@ -389,8 +388,6 @@
                        break;
                        
                     case Bisocket.PING:
  -                     log.info("got ping");
  -//                     log.info("lastPing: " + lastPing);
                        continue;
                        
                     case -1:
  @@ -407,12 +404,13 @@
                  if (running)
                  {
                     if ("socket closed".equals(e.getMessage()) || 
  -                      "Socket is closed".equals(e.getMessage()))
  +                      "Socket is closed".equals(e.getMessage()) ||
  +                      "Connection reset".equals(e.getMessage()))
                     {
                        shutdown();
                        return;
                     }
  -                  log.error("Unable to create new Socket: " + e.getMessage());
  +                  log.error("Unable to read from control connection: " + e.getMessage());
                     e.printStackTrace();
                     if (++errorCount > 5)
                     {
  @@ -436,7 +434,9 @@
                                                  clientpool, threadpool,
                                                  getTimeout(), serverSocketClass);
                        thread.start();
  -                     log.info("created: " + thread);
  +                     
  +                     if (log.isDebugEnabled())
  +                        log.debug("created: " + thread);
                     }
                     catch (Exception e)
                     {
  @@ -455,12 +455,6 @@
      }
      
      
  -//   protected ServerThread createServerThread(Socket socket) throws Exception
  -//   {
  -//      return new BisocketServerThread(socket, this, clientpool, threadpool, getTimeout(), serverSocketClass);
  -//   }
  -   
  -   
      class SecondaryServerSocketThread extends Thread
      {
         private ServerSocket secondaryServerSocket;
  @@ -475,7 +469,6 @@
         {
            running = false;
            interrupt();
  -         log.info(this + ": shut down");
         }
         
         public void run()
  @@ -485,6 +478,7 @@
               try
               {
                  Socket socket = secondaryServerSocket.accept();
  +               log.debug("accepted: " + socket);
                  DataInputStream dis = new DataInputStream(socket.getInputStream());
                  int action = dis.read();
                  String listenerId = dis.readUTF();
  @@ -493,14 +487,22 @@
                  {
                     case Bisocket.CREATE_CONTROL_SOCKET:
                        BisocketClientInvoker invoker;
  -                     invoker =  BisocketClientInvoker.getBisocketClientInvoker(listenerId);
  +                     invoker =  BisocketClientInvoker.getBisocketCallbackClientInvoker(listenerId);
  +                     if (invoker == null)
  +                     {
  +                        log.debug("SecondaryServerSocketThread: transferring socket: " + listenerId);
  +                        BisocketClientInvoker.transferSocket(listenerId, socket);
  +                     }
  +                     else
  +                     {
                        invoker.replaceControlSocket(socket);
  -                     log.info("SecondaryServerSocketThread: created secondary socket: " + listenerId);
  +                        log.debug("SecondaryServerSocketThread: created secondary socket: " + listenerId);
  +                     }
                        break;
                        
                     case Bisocket.CREATE_ORDINARY_SOCKET: 
                        BisocketClientInvoker.transferSocket(listenerId, socket);
  -                     log.info("SecondaryServerSocketThread: transferred socket: " + listenerId);
  +                     log.debug("SecondaryServerSocketThread: transferred socket: " + listenerId);
                        break;
                        
                     default:
  @@ -533,30 +535,43 @@
         {
            running = false;
            cancel();
  -         log.info("shutting down " + this);
         }
         
         public void run()
         {
  +         if (log.isTraceEnabled())
  +            log.trace("checking connections");
  +         
            Collection controlConnectionThreads = null;
            synchronized (controlConnectionThreadMap)
            {
               controlConnectionThreads = new HashSet(controlConnectionThreadMap.values());
            }
            
  +         if (controlConnectionThreads.isEmpty())
  +            cancel();
  +         
            Iterator it = controlConnectionThreads.iterator();
            while (it.hasNext() & running)
            {
  -            ControlConnectionThread t = (ControlConnectionThread) it.next();
  +            final ControlConnectionThread t = (ControlConnectionThread) it.next();
               if (!t.checkConnection())
               {
  -               log.info("detected failure on control connection: requesting new control connection");
  +               log.warn(this + ": detected failure on control connection " + t + ": requesting new control connection");
                  t.shutdown();
  -               it.remove();
  +               
  +               synchronized (controlConnectionThreadMap)
  +               {
  +                  controlConnectionThreadMap.remove(t.getListenerId());
  +               }
                  
                  if (!running)
                     return;
                  
  +               new Thread()
  +               {
  +                  public void run()
  +                  {
                  try
                  {
                     createControlConnection(t.getListenerId(), null);
  @@ -564,34 +579,13 @@
                  catch (IOException e)
                  {
                     InvokerLocator locator = (InvokerLocator) listenerIdToInvokerLocatorMap.get(t.getListenerId());
  -                  log.error(this + ": " + "Unable to recreate control connection: " + locator, e);
  -                  e.printStackTrace();
  +                        log.error("Unable to recreate control connection: " + locator, e);
  +                     }  
                  }
  +               }.start();
  +
               }
            }
         }
      }
  -   
  -   
  -//   class InternalInvocationHandler implements ServerInvocationHandler
  -//   {
  -//      InvokerLocator locator;
  -//      
  -//      InternalInvocationHandler(ServerSocket ss)
  -//      {
  -//         String host = ss.getInetAddress().getHostAddress();
  -//         int port = ss.getLocalPort();
  -//         locator = new InvokerLocator(null, host, port, null, null);   
  -//      }
  -//      
  -//      public Object invoke(InvocationRequest invocation) throws Throwable
  -//      {
  -//         return locator;
  -//      }
  -//
  -//      public void setMBeanServer(MBeanServer server) {}
  -//      public void setInvoker(ServerInvoker invoker) {}
  -//      public void addListener(InvokerCallbackHandler callbackHandler) {}
  -//      public void removeListener(InvokerCallbackHandler callbackHandler) {}
  -//   }
   }
  \ No newline at end of file
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 03:02:49 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 03:02:49 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1878 -
	branches/Branch_Bisocket_Experiment/lib
Message-ID: <E1H0ZB3-0006MV-AD@committer01.frg.pub.inap.atl.jboss.com>

Author: ron_sigal
Date: 2006-12-30 03:02:32 -0500 (Sat, 30 Dec 2006)
New Revision: 1878

Added:
   branches/Branch_Bisocket_Experiment/lib/jboss-remoting.jar
Log:
JBMESSAGING-694: jboss-remoting.jar corresponds (closely) with state of Remoting branch remoting_2_x as of 12/30/06.

Added: branches/Branch_Bisocket_Experiment/lib/jboss-remoting.jar
===================================================================
(Binary files differ)


Property changes on: branches/Branch_Bisocket_Experiment/lib/jboss-remoting.jar
___________________________________________________________________
Name: svn:mime-type
   + application/octet-stream



From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 03:27:19 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 03:27:19 -0500
Subject: [jboss-cvs] JBossAS SVN: r59248 -
	projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins
Message-ID: <E1H0ZYl-0006kd-NL@committer01.frg.pub.inap.atl.jboss.com>

Author: alesj
Date: 2006-12-30 03:27:14 -0500 (Sat, 30 Dec 2006)
New Revision: 59248

Modified:
   projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java
Log:
todo - config options

Modified: projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java
===================================================================
--- projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java	2006-12-30 00:06:51 UTC (rev 59247)
+++ projects/microcontainer/trunk/container/src/main/org/jboss/reflect/plugins/ProgressionConvertorFactory.java	2006-12-30 08:27:14 UTC (rev 59248)
@@ -49,6 +49,7 @@
 
    public ProgressionConvertor getConvertor() throws Throwable
    {
+      // TODO - some more config options; by deployment, app, server, cluster, ...
       if (convertor == null)
       {
          ConvertorLookup lookup = new ConvertorLookup();



From gas9f5sda4gsa at lycos.com  Sat Dec 30 08:09:10 2006
From: gas9f5sda4gsa at lycos.com (gas9f5sda4gsa at lycos.com)
Date: Sat, 30 Dec 2006 08:09:10 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCosKCwq3CgsOnwpXCpcKCwqbCgsOOwojCp8KC?=
	=?utf-8?b?w4HCgsOEwoLCrcKCw6rCgsOcwoLCt8KCwqnCgUgxMDDCgsOcwoLDhcKC?=
	=?utf-8?b?w43ClcK9wotDwoLDhcKCwrfCgUI=?=
Message-ID: 20061230213748.85847mail@mail.bweroiusdkjuywerterpoidkjasiuyasjdasjdnuyysda.com

?f???????????????????A?t???????]?????????????????????H
???????????????????????????????v?????????????A?b???????????????B
?????????[?????????????????????A???????????????????????v???????????B
?????????????????????d?b???????????????H
http://allfree.todaywomanmeets.tonderuyo.com/kin/
?\???x?????????B?????}???????????B37?????g?????B
?u???}???????????H?v???d?b???????????????????B
?????????????????????B







From Shane_Bryzak at symantec.com  Sat Dec 30 09:04:03 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 09:04:03 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/authenticator
	...
Message-ID: <E1H0eod-0004HV-2i@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 09:04:03

  Modified:    src/main/org/jboss/seam/security/authenticator 
                        ProviderAuthenticator.java
  Log:
  configuration support for provider flags
  
  Revision  Changes    Path
  1.12      +105 -56   jboss-seam/src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProviderAuthenticator.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- ProviderAuthenticator.java	4 Dec 2006 01:21:52 -0000	1.11
  +++ ProviderAuthenticator.java	30 Dec 2006 14:04:03 -0000	1.12
  @@ -10,8 +10,8 @@
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
  -import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
  +import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.provider.AuthenticationProvider;
   import org.jboss.seam.util.Reflections;
   
  @@ -22,10 +22,33 @@
    */
   @Name("org.jboss.seam.security.authenticator")
   @Scope(APPLICATION)
  - at Install(value=false, precedence=BUILT_IN)
  + at Install(value = false, precedence = BUILT_IN)
   public class ProviderAuthenticator extends Authenticator
   {
  -  private List<Object> providers = new ArrayList<Object> ();
  +   /**
  +    * These constants are semantically equivalent to the JAAS login module flags
  +    * documented in javax.security.auth.login.Configuration
  +    */
  +   public enum Flag
  +   {
  +      required, requisite, sufficient, optional
  +   };
  +   
  +   private String flags;
  +   
  +   private class ProviderEntry 
  +   {      
  +      public Object provider;
  +      public Flag flag;
  +      
  +      public ProviderEntry(Object provider, Flag flag)
  +      {
  +         this.provider = provider;
  +         this.flag = flag;
  +      }
  +   }
  +
  +   private List<ProviderEntry> providers = new ArrayList<ProviderEntry>();
   
     /**
      *
  @@ -37,14 +60,16 @@
     public Identity doAuthentication(Identity authentication)
         throws AuthenticationException
     {
  -    for (Object p : providers)
  +      for (ProviderEntry entry : providers)
       {
         AuthenticationProvider provider = null;
   
  -      if (p instanceof AuthenticationProvider)
  -        provider = (AuthenticationProvider) p;
  -      else if (p instanceof Component)
  -        provider = (AuthenticationProvider) ( (Component) p).newInstance();
  +         /** todo implement flag logic */
  +         
  +         if (entry.provider instanceof AuthenticationProvider)
  +            provider = (AuthenticationProvider) entry.provider;
  +         else if (entry.provider instanceof Component)
  +            provider = (AuthenticationProvider) ((Component) entry.provider).newInstance();
   
         Identity result = provider.authenticate(authentication);
         if (result != null)
  @@ -54,31 +79,55 @@
       throw new AuthenticationException("Provider not found");
     }
   
  +   public void setFlags(String flags)
  +   {
  +     this.flags = flags;
  +     
  +     if (!providers.isEmpty())
  +        checkFlags();
  +   }
  +   
  +   private void checkFlags()
  +   {
  +      if (flags != null)
  +      {
  +         String[] parts = flags.split("[,]");
  +         
  +         for (int i = 0; i < Math.min(parts.length, providers.size()); i++)
  +         {
  +            providers.get(i).flag = Flag.valueOf(parts[i]);
  +         }
  +      }
  +   }
  +
     public void setProviders(Object values)
     {
       if (values instanceof AuthenticationProvider)
       {
  -      providers.add(values);
  +         providers.add(new ProviderEntry(values, Flag.required));
       }
       else
       {
         for (Object provider : (List) values)
         {
           if (provider instanceof Component)
  -          providers.add(provider);
  +               providers.add(new ProviderEntry(provider, Flag.required));
           else
           {
             try
             {
  -            provider = Reflections.classForName(provider.toString()).newInstance();
  -            providers.add(provider);
  +                  provider = Reflections.classForName(provider.toString())
  +                        .newInstance();
  +                  providers.add(new ProviderEntry(provider, Flag.required));
             }
             catch (Exception ex)
             {
  -//        log.error("Error creating provider", ex);
  +                  //        log.error("Error creating provider", ex);
             }
           }
         }
       }
  +      
  +      checkFlags();
     }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 09:05:23 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 09:05:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF   ...
Message-ID: <E1H0epv-0004JI-70@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 09:05:23

  Modified:    examples/seamspace/resources/META-INF   security-config.xml
                        security-rules.drl
  Log:
  minor changes
  
  Revision  Changes    Path
  1.2       +2 -2      jboss-seam/examples/seamspace/resources/META-INF/security-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: security-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/security-config.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- security-config.xml	15 Dec 2006 13:36:43 -0000	1.1
  +++ security-config.xml	30 Dec 2006 14:05:23 -0000	1.2
  @@ -13,7 +13,7 @@
     
     <roles>
       <role name="admin">
  -      <members>superuser</members>
  +      <memberships>superuser</memberships>
         
         <permissions>
           <permission name="user" action="create"/>
  @@ -23,7 +23,7 @@
       </role>
       
       <role name="superuser">
  -      <members>user</members>
  +      <memberships>user</memberships>
       
         <permissions>
           <permission name="account" action="create"/>
  
  
  
  1.2       +1 -12     jboss-seam/examples/seamspace/resources/META-INF/security-rules.drl
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: security-rules.drl
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/security-rules.drl,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- security-rules.drl	22 Dec 2006 02:04:48 -0000	1.1
  +++ security-rules.drl	30 Dec 2006 14:05:23 -0000	1.2
  @@ -4,20 +4,9 @@
   import org.jboss.seam.security.rules.PermissionCheck;
   import org.jboss.seam.example.seamspace.MemberImage;
   
  -rule AuthenticatedViewImage
  +rule ViewImage
   when
     c: PermissionCheck(name == "memberImage", action == "view")
  -  Identity()
  -  img: MemberImage()
  -  eval( img.getMember().getPicture() == img )
  -then
  -  c.grant();
  -end;
  -
  -rule UnauthenticatedViewImage
  -when
  -  c: PermissionCheck(name == "memberImage", action == "view")
  -  not Identity()
     img: MemberImage()
     eval( img.getMember().getPicture() == img )
   then
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 09:05:23 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 09:05:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF  ...
Message-ID: <E1H0epv-0004JP-Am@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 09:05:23

  Modified:    examples/seamspace/resources/WEB-INF  components.xml
  Log:
  minor changes
  
  Revision  Changes    Path
  1.9       +1 -10     jboss-seam/examples/seamspace/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/components.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- components.xml	15 Dec 2006 13:36:43 -0000	1.8
  +++ components.xml	30 Dec 2006 14:05:23 -0000	1.9
  @@ -19,18 +19,9 @@
   
       <component class="org.jboss.seam.security.authenticator.ProviderAuthenticator">
         <property name="providers">#{authenticatorAction}</property>
  +      <property name="flags">required</property>
       </component>
       
  -    <!--component name="persistentAclProvider" class="org.jboss.seam.security.acl.PersistentAclProvider">
  -      <property name="aclQuery">
  -        select p.mask, p.recipient, p.recipientType from AclPermission p
  -        where p.identity.objectIdentity = :identity
  -      </property>
  -      
  -      <property name="persistenceContextManager">#{entityManager}</property>      
  -      
  -    </component-->
  -
       <component class="org.jboss.seam.security.SeamSecurityManager"/>
       <component class="org.jboss.seam.security.config.SecurityConfiguration"/>
           
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 09:05:23 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 09:05:23 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources  ...
Message-ID: <E1H0epv-0004JW-GP@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 09:05:23

  Modified:    examples/seamspace/resources  import.sql
  Log:
  minor changes
  
  Revision  Changes    Path
  1.8       +2 -2      jboss-seam/examples/seamspace/resources/import.sql
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: import.sql
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/import.sql,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- import.sql	22 Dec 2006 07:21:01 -0000	1.7
  +++ import.sql	30 Dec 2006 14:05:23 -0000	1.8
  @@ -1,5 +1,5 @@
  -insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (1, 'demo', 'demo', 'Mr_Smiley', 'I smile because I care', 0, '1953-03-10', 'The moon')
  -insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (2, 'duke', 'duke', 'duke', 'I love the smell of coffee', 0, '1995-01-01', 'Sun Microsystems')
  +insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (1, 'demo', 'demo', 'Mr_Smiley', 'I smile because I care', 0, '1953-03-10', '')
  +insert into Member (memberid, username, password, name, tagline, gender, dob, location) values (2, 'duke', 'duke', 'duke', 'I love the smell of coffee', 0, '1995-01-01', '')
   
   insert into MemberRole (roleid, name) values (1, 'user');
   insert into MemberRole (roleid, name) values (2, 'admin');
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:52 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:52 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1H0iLA-0008H3-KJ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:52

  Modified:    tests/functional/org/jboss/cache/optimistic                              
                        AsyncCacheTest.java ThreadedCacheAccessTest.java
                        OptimisticCreateIfNotExistsInterceptorTest.java
                        NodeInterceptorKeyValTest.java
                        NodeInterceptorPutMapTest.java
                        NodeInterceptorGetChildrenNamesTest.java
                        OptimisticWithCacheLoaderTest.java
                        OptimisticVersioningTest.java
                        NodeInterceptorRemoveNodeTest.java
                        TxInterceptorTest.java
                        NodeInterceptorGetKeyValTest.java
                        NodeInterceptorPutEraseTest.java
                        ThreadedOptimisticCreateIfNotExistsInterceptorTest.java
                        VersioningOnReadTest.java
                        ValidatorInterceptorTest.java
                        ValidationFailureTest.java CacheTest.java
                        OptimisticWithPassivationTest.java
                        FullStackInterceptorTest.java
                        OpLockingInterceptorTest.java
                        AbstractOptimisticTestCase.java
                        NodeInterceptorRemoveKeyValTest.java
                        NodeInterceptorTransactionTest.java
                        AsyncFullStackInterceptorTest.java
                        OptimisticReplicationInterceptorTest.java
                        RemoveBeforeCreateTest.java
                        ConcurrentTransactionTest.java
                        NodeInterceptorRemoveDataTest.java
                        NodeInterceptorGetKeysTest.java
                        MockInterceptor.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.7       +2 -2      JBossCache/tests/functional/org/jboss/cache/optimistic/AsyncCacheTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncCacheTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/AsyncCacheTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- AsyncCacheTest.java	30 Aug 2006 21:05:16 -0000	1.6
  +++ AsyncCacheTest.java	30 Dec 2006 17:49:52 -0000	1.7
  @@ -4,10 +4,10 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.loader.SamplePojo;
   import org.jboss.cache.misc.TestingUtil;
  @@ -18,7 +18,7 @@
   public class AsyncCacheTest extends AbstractOptimisticTestCase
   {
   
  -   TreeCache cache, cache2;
  +   CacheImpl cache, cache2;
   
      protected void setUp() throws Exception
      {
  
  
  
  1.5       +3 -3      JBossCache/tests/functional/org/jboss/cache/optimistic/ThreadedCacheAccessTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThreadedCacheAccessTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ThreadedCacheAccessTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ThreadedCacheAccessTest.java	30 Aug 2006 21:05:16 -0000	1.4
  +++ ThreadedCacheAccessTest.java	30 Dec 2006 17:49:52 -0000	1.5
  @@ -9,8 +9,8 @@
   import junit.framework.Assert;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import javax.transaction.TransactionManager;
   
  @@ -34,7 +34,7 @@
      private final Fqn fqn = Fqn.fromString("/a/b");
      private final String key = "key", value = "value";
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private WorkerThread[] threads;
   
      public ThreadedCacheAccessTest(String name)
  @@ -55,7 +55,7 @@
   
         cache.put(fqn, key, value);
   
  -      threads = new WorkerThread[ numThreads ];
  +      threads = new WorkerThread[numThreads];
   
         for (int i = 0; i < numThreads; i++)
         {
  
  
  
  1.13      +11 -11    JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticCreateIfNotExistsInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticCreateIfNotExistsInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticCreateIfNotExistsInterceptorTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- OptimisticCreateIfNotExistsInterceptorTest.java	20 Sep 2006 16:28:58 -0000	1.12
  +++ OptimisticCreateIfNotExistsInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.13
  @@ -6,11 +6,11 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.loader.SamplePojo;
  @@ -41,7 +41,7 @@
         super(name);
      }
   
  -   protected void setupTransactionsInInvocationCtx(TreeCache cache) throws Exception
  +   protected void setupTransactionsInInvocationCtx(CacheImpl cache) throws Exception
      {
         txManager = DummyTransactionManager.getInstance();
         // start a tx
  @@ -65,12 +65,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(dummy);
   
  @@ -101,12 +101,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(dummy);
   
  @@ -152,12 +152,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
         interceptor.setNext(dummy);
   
         cache.setInterceptorChain(interceptor);
  
  
  
  1.12      +21 -21    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorKeyValTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorKeyValTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorKeyValTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- NodeInterceptorKeyValTest.java	6 Sep 2006 15:30:58 -0000	1.11
  +++ NodeInterceptorKeyValTest.java	30 Dec 2006 17:49:52 -0000	1.12
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -32,14 +32,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -85,14 +85,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -142,14 +142,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -198,14 +198,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -256,14 +256,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.11      +13 -13    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorPutMapTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeInterceptorPutMapTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ NodeInterceptorPutMapTest.java	30 Dec 2006 17:49:52 -0000	1.11
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -34,14 +34,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
   
         interceptor.setNext(nodeInterceptor);
  @@ -91,14 +91,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -150,14 +150,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.11      +14 -14    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorGetChildrenNamesTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeInterceptorGetChildrenNamesTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ NodeInterceptorGetChildrenNamesTest.java	30 Dec 2006 17:49:52 -0000	1.11
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -34,14 +34,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -104,14 +104,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -155,14 +155,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -202,7 +202,7 @@
   
         //assert the removal has had no effect
         assertEquals(1, cache.getChildrenNames("/one").size());
  -      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  +      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild(new Fqn("two")));
   
         mgr.commit();
   
  
  
  
  1.14      +9 -9      JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticWithCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticWithCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticWithCacheLoaderTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- OptimisticWithCacheLoaderTest.java	30 Aug 2006 20:28:50 -0000	1.13
  +++ OptimisticWithCacheLoaderTest.java	30 Dec 2006 17:49:52 -0000	1.14
  @@ -7,7 +7,7 @@
   package org.jboss.cache.optimistic;
   
   import junit.framework.Assert;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
  @@ -29,7 +29,7 @@
   
      public void testLoaderIndependently() throws Exception
      {
  -      TreeCache cache = createCacheWithLoader();
  +      CacheImpl cache = createCacheWithLoader();
         CacheLoader loader = cache.getCacheLoader();
   
         // test the cache loader independently first ...
  @@ -47,7 +47,7 @@
         CacheLoader loader = null;
         try
         {
  -         TreeCache cache = createCacheWithLoader();
  +         CacheImpl cache = createCacheWithLoader();
            loader = cache.getCacheLoader();
   
            DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  @@ -84,7 +84,7 @@
      public void testCacheStoring() throws Exception
      {
         Transaction tx;
  -      TreeCache cache = createCacheWithLoader();
  +      CacheImpl cache = createCacheWithLoader();
         CacheLoader loader = cache.getCacheLoader();
   
         // test the cache ...
  @@ -130,7 +130,7 @@
   
      public void testCacheLoading() throws Exception
      {
  -      TreeCache cache = createCacheWithLoader();
  +      CacheImpl cache = createCacheWithLoader();
         CacheLoader loader = cache.getCacheLoader();
   
         Assert.assertNull(cache.get(fqn, key));
  @@ -151,10 +151,10 @@
   
      public void testCacheLoadingWithReplication() throws Exception
      {
  -      TreeCache cache1 = createReplicatedCacheWithLoader(false);
  +      CacheImpl cache1 = createReplicatedCacheWithLoader(false);
         CacheLoader loader1 = cache1.getCacheLoader();
   
  -      TreeCache cache2 = createReplicatedCacheWithLoader(false);
  +      CacheImpl cache2 = createReplicatedCacheWithLoader(false);
         CacheLoader loader2 = cache2.getCacheLoader();
   
         // test the cache ...
  @@ -203,10 +203,10 @@
   
      public void testSharedCacheLoadingWithReplication() throws Exception
      {
  -      TreeCache cache1 = createReplicatedCacheWithLoader(true);
  +      CacheImpl cache1 = createReplicatedCacheWithLoader(true);
         CacheLoader loader1 = cache1.getCacheLoader();
   
  -      TreeCache cache2 = createReplicatedCacheWithLoader(true);
  +      CacheImpl cache2 = createReplicatedCacheWithLoader(true);
         CacheLoader loader2 = cache2.getCacheLoader();
   
         // test the cache ...
  
  
  
  1.6       +11 -11    JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticVersioningTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticVersioningTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticVersioningTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- OptimisticVersioningTest.java	30 Aug 2006 21:05:16 -0000	1.5
  +++ OptimisticVersioningTest.java	30 Dec 2006 17:49:52 -0000	1.6
  @@ -7,9 +7,9 @@
   package org.jboss.cache.optimistic;
   
   import junit.framework.Assert;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.config.Configuration;
   
   import javax.transaction.RollbackException;
  @@ -23,7 +23,7 @@
    */
   public class OptimisticVersioningTest extends AbstractOptimisticTestCase
   {
  -   TreeCache cache1, cache2;
  +   CacheImpl cache1, cache2;
   
      public OptimisticVersioningTest(String name)
      {
  @@ -52,8 +52,8 @@
   
         cache1.put(fqn, key, "value");
   
  -      DataVersion v1 = ((OptimisticTreeNode) cache1.get(fqn)).getVersion();
  -      DataVersion v2 = ((OptimisticTreeNode) cache2.get(fqn)).getVersion();
  +      DataVersion v1 = ((NodeSPI) cache1.get(fqn)).getVersion();
  +      DataVersion v2 = ((NodeSPI) cache2.get(fqn)).getVersion();
   
         Assert.assertEquals("value", cache1.get(fqn, key));
         Assert.assertEquals("value", cache2.get(fqn, key));
  @@ -62,8 +62,8 @@
         // change stuff in the node again...
         cache1.put(fqn, key, "value2");
   
  -      v1 = ((OptimisticTreeNode) cache1.get(fqn)).getVersion();
  -      v2 = ((OptimisticTreeNode) cache2.get(fqn)).getVersion();
  +      v1 = ((NodeSPI) cache1.get(fqn)).getVersion();
  +      v2 = ((NodeSPI) cache2.get(fqn)).getVersion();
   
         Assert.assertEquals("value2", cache1.get(fqn, key));
         Assert.assertEquals("value2", cache2.get(fqn, key));
  @@ -81,8 +81,8 @@
   
         cache1.put(fqn, key, "value");
   
  -      DataVersion v1 = ((OptimisticTreeNode) cache1.get(fqn)).getVersion();
  -      DataVersion v2 = ((OptimisticTreeNode) cache2.get(fqn)).getVersion();
  +      DataVersion v1 = ((NodeSPI) cache1.get(fqn)).getVersion();
  +      DataVersion v2 = ((NodeSPI) cache2.get(fqn)).getVersion();
   
         Assert.assertEquals("value", cache1.get(fqn, key));
         Assert.assertEquals("value", cache2.get(fqn, key));
  @@ -115,8 +115,8 @@
         }
   
         // data versions should be in sync.
  -      v1 = ((OptimisticTreeNode) cache1.get(fqn)).getVersion();
  -      v2 = ((OptimisticTreeNode) cache2.get(fqn)).getVersion();
  +      v1 = ((NodeSPI) cache1.get(fqn)).getVersion();
  +      v2 = ((NodeSPI) cache2.get(fqn)).getVersion();
   
         Assert.assertEquals("Version info should have propagated", v1, v2);
      }
  
  
  
  1.14      +43 -44    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorRemoveNodeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- NodeInterceptorRemoveNodeTest.java	20 Nov 2006 03:53:56 -0000	1.13
  +++ NodeInterceptorRemoveNodeTest.java	30 Dec 2006 17:49:52 -0000	1.14
  @@ -6,13 +6,12 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Node;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeNode;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -43,14 +42,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -94,14 +93,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -155,14 +154,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -203,7 +202,7 @@
         assertNotNull(workspace.getNode(Fqn.fromString("/one")));
         assertEquals(true, workspace.getNode(Fqn.fromString("/one")).isDeleted());
         assertEquals(1, workspace.getNode(Fqn.fromString("/one")).getMergedChildren().size());
  -      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  +      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
         assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("/one")));
         assertTrue(entry.getLocks().isEmpty());
         assertEquals(2, entry.getModifications().size());
  @@ -216,14 +215,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -264,8 +263,8 @@
         assertEquals(true, workspace.getNode(Fqn.fromString("/one")).isDeleted());
   
         //will still have alink from one to two
  -      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  -      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild("one"));
  +      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
  +      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("one")));
   
         //now put /one/two back in
         cache.remove("/one");
  @@ -277,8 +276,8 @@
         assertEquals(true, workspace.getNode(Fqn.fromString("/one")).isDeleted());
   
         //will still have alink from one to two
  -      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  -      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild("one"));
  +      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
  +      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("one")));
   
         assertEquals(null, dummy.getCalled());
   
  @@ -300,14 +299,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -348,8 +347,8 @@
         assertEquals(true, workspace.getNode(Fqn.fromString("/one")).isDeleted());
   
         //will still have alink from one to two
  -      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  -      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild("one"));
  +      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
  +      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("one")));
   
         //now put /one/two back in
         cache.put("/one/two", temp);
  @@ -362,8 +361,8 @@
         assertNotSame(two, twoAfter);
         assertEquals(false, twoAfter.isDeleted());
   
  -      assertEquals(twoAfter.getNode(), workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  -      assertEquals(oneAfter.getNode(), workspace.getNode(Fqn.fromString("/")).getChild("one"));
  +      assertEquals(twoAfter.getNode(), workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
  +      assertEquals(oneAfter.getNode(), workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("one")));
   
         assertEquals(null, dummy.getCalled());
   
  @@ -386,14 +385,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -434,8 +433,8 @@
         assertEquals(true, workspace.getNode(Fqn.fromString("/one")).isDeleted());
   
         //will still have alink from one to two
  -      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  -      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild("one"));
  +      assertNotNull(workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
  +      assertEquals(null, workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("one")));
   
         //now put /one back in
         SamplePojo pojo2 = new SamplePojo(21, "test");
  @@ -449,8 +448,8 @@
         assertEquals(two, twoAfter);
         assertEquals(true, twoAfter.isDeleted());
   
  -      assertNull(workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  -      assertEquals(oneAfter.getNode(), workspace.getNode(Fqn.fromString("/")).getChild("one"));
  +      assertNull(workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
  +      assertEquals(oneAfter.getNode(), workspace.getNode(Fqn.fromString("/")).getChild(Fqn.fromString("one")));
   
         assertEquals(null, dummy.getCalled());
   
  @@ -473,14 +472,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -521,7 +520,7 @@
         assertEquals(false, workspace.getNode(Fqn.fromString("/one")).isDeleted());
   
         //will still have alink from one to two
  -      assertEquals(null, workspace.getNode(Fqn.fromString("/one")).getChild("two"));
  +      assertEquals(null, workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("two")));
   
   
         assertEquals(null, dummy.getCalled());
  
  
  
  1.18      +43 -43    JBossCache/tests/functional/org/jboss/cache/optimistic/TxInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/TxInterceptorTest.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- TxInterceptorTest.java	11 Nov 2006 19:55:18 -0000	1.17
  +++ TxInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.18
  @@ -6,10 +6,10 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.loader.SamplePojo;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodCallFactory;
  @@ -34,11 +34,11 @@
      public void testNoTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         assertNull(mgr.getTransaction());
         assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
  @@ -64,11 +64,11 @@
      public void testLocalTransactionExists() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -102,11 +102,11 @@
      public void testRollbackTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -134,11 +134,11 @@
   
      public void testEmptyLocalTransaction() throws Exception
      {
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -163,11 +163,11 @@
      public void testEmptyRollbackLocalTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -193,11 +193,11 @@
      public void testLocalRollbackAftercommitTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -238,11 +238,11 @@
   
      public void testgtxTransactionExists() throws Exception
      {
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -276,11 +276,11 @@
      public void testRemotePrepareTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -381,11 +381,11 @@
      public void testRemotePrepareSuspendTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -499,11 +499,11 @@
      public void testRemoteCommitSuspendTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -625,11 +625,11 @@
      public void testRemoteRollbackSuspendTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -749,11 +749,11 @@
      public void testRemoteCommitTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -877,11 +877,11 @@
      public void testRemoteRollbackTransaction() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -1000,11 +1000,11 @@
      public void testSequentialTransactionExists() throws Exception
      {
   
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), false));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, false));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  
  
  
  1.11      +13 -13    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeyValTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorGetKeyValTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeyValTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeInterceptorGetKeyValTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ NodeInterceptorGetKeyValTest.java	30 Dec 2006 17:49:52 -0000	1.11
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -32,12 +32,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  @@ -100,12 +100,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  @@ -159,12 +159,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  @@ -217,12 +217,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  
  
  
  1.11      +13 -13    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutEraseTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorPutEraseTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutEraseTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeInterceptorPutEraseTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ NodeInterceptorPutEraseTest.java	30 Dec 2006 17:49:52 -0000	1.11
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -34,14 +34,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -88,14 +88,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -145,14 +145,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.18      +9 -9      JBossCache/tests/functional/org/jboss/cache/optimistic/ThreadedOptimisticCreateIfNotExistsInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ThreadedOptimisticCreateIfNotExistsInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ThreadedOptimisticCreateIfNotExistsInterceptorTest.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- ThreadedOptimisticCreateIfNotExistsInterceptorTest.java	6 Sep 2006 15:30:58 -0000	1.17
  +++ ThreadedOptimisticCreateIfNotExistsInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.18
  @@ -8,9 +8,9 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.OptimisticTransactionEntry;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.loader.SamplePojo;
  @@ -35,13 +35,13 @@
   
      }
   
  -   protected synchronized void setTransactionsInInvocationCtx(TransactionManager mgr, TreeCache cache) throws Exception
  +   protected synchronized void setTransactionsInInvocationCtx(TransactionManager mgr, CacheImpl cache) throws Exception
      {
         cache.getInvocationContext().setTransaction(mgr.getTransaction());
         cache.getInvocationContext().setGlobalTransaction(cache.getCurrentTransaction());
      }
   
  -   protected void resetInvocationCtx(TreeCache cache)
  +   protected void resetInvocationCtx(CacheImpl cache)
      {
         cache.getInvocationContext().setTransaction(null);
         cache.getInvocationContext().setGlobalTransaction(null);
  @@ -54,12 +54,12 @@
         final int minSleep = 0;
         final int maxSleep = 1000;
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
         interceptor.setNext(dummy);
   
         cache.setInterceptorChain(interceptor);
  @@ -122,12 +122,12 @@
         final int minSleep = 0;
         final int maxSleep = 500;
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
         interceptor.setNext(dummy);
   
         cache.setInterceptorChain(interceptor);
  
  
  
  1.3       +2 -2      JBossCache/tests/functional/org/jboss/cache/optimistic/VersioningOnReadTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: VersioningOnReadTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/VersioningOnReadTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- VersioningOnReadTest.java	11 Nov 2006 19:55:18 -0000	1.2
  +++ VersioningOnReadTest.java	30 Dec 2006 17:49:52 -0000	1.3
  @@ -1,7 +1,7 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  @@ -11,7 +11,7 @@
    */
   public class VersioningOnReadTest extends AbstractOptimisticTestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      Fqn fqn = Fqn.fromString("/a");
      TransactionManager tm;
   
  
  
  
  1.16      +457 -457  JBossCache/tests/functional/org/jboss/cache/optimistic/ValidatorInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ValidatorInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ValidatorInterceptorTest.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- ValidatorInterceptorTest.java	25 Aug 2006 14:10:10 -0000	1.15
  +++ ValidatorInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.16
  @@ -6,12 +6,12 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.OptimisticTransactionEntry;
  -import org.jboss.cache.OptimisticTreeNode;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -43,16 +43,16 @@
   
       public void testTransactionvalidateMethod() throws Exception
       {
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           Interceptor validateInterceptor = new OptimisticValidatorInterceptor();
  -        validateInterceptor.setCache(cache.getCacheSPI());
  +      validateInterceptor.setCache(cache);
           Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -        interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
           Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -        nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
           MockInterceptor dummy = new MockInterceptor();
  -        dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
           validateInterceptor.setNext(interceptor);
           interceptor.setNext(nodeInterceptor);
           nodeInterceptor.setNext(dummy);
  @@ -126,16 +126,16 @@
       public void testTransactionValidateFailureMethod() throws Exception
       {
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           Interceptor validateInterceptor = new OptimisticValidatorInterceptor();
  -        validateInterceptor.setCache(cache.getCacheSPI());
  +      validateInterceptor.setCache(cache);
           Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -        interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
           Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -        nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
           MockInterceptor dummy = new MockInterceptor();
  -        dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
           validateInterceptor.setNext(interceptor);
           interceptor.setNext(nodeInterceptor);
           nodeInterceptor.setNext(dummy);
  @@ -166,9 +166,9 @@
           TransactionWorkspace workspace = entry.getTransactionWorkSpace();
   
           /*GlobalTransaction.class,
  -List.class,
  -Address.class,
  -boolean.class*/
  +      List.class,
  +      Address.class,
  +      boolean.class*/
   
           assertEquals(3, workspace.getNodes().size());
           assertNotNull(workspace.getNode(Fqn.fromString("/one/two")));
  @@ -180,9 +180,9 @@
           assertEquals(null, dummy.getCalled());
   
           //lets change one of the underlying version numbers
  -        ((OptimisticTreeNode) workspace.getNode(Fqn.fromString("/one/two")).getNode()).setVersion(new DefaultDataVersion(2));
  +      workspace.getNode(Fqn.fromString("/one/two")).getNode().setVersion(new DefaultDataVersion(2));
           //now let us do a prepare
  -        MethodCall prepareMethod = MethodCallFactory.create(MethodDeclarations.optimisticPrepareMethod, new Object[]{gtx, entry.getModifications(), gtx.getAddress(), Boolean.FALSE});
  +      MethodCall prepareMethod = MethodCallFactory.create(MethodDeclarations.optimisticPrepareMethod, gtx, entry.getModifications(), gtx.getAddress(), Boolean.FALSE);
           try
           {
               cache._replicate(prepareMethod);
  @@ -202,16 +202,16 @@
       public void testTransactionValidateCommitMethod() throws Exception
       {
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           Interceptor validateInterceptor = new OptimisticValidatorInterceptor();
  -        validateInterceptor.setCache(cache.getCacheSPI());
  +      validateInterceptor.setCache(cache);
           Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -        interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
           Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -        nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
           MockInterceptor dummy = new MockInterceptor();
  -        dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
           validateInterceptor.setNext(interceptor);
           interceptor.setNext(nodeInterceptor);
           nodeInterceptor.setNext(dummy);
  @@ -242,9 +242,9 @@
           TransactionWorkspace workspace = entry.getTransactionWorkSpace();
   
           /*GlobalTransaction.class,
  -List.class,
  -Address.class,
  -boolean.class*/
  +      List.class,
  +      Address.class,
  +      boolean.class*/
   
           assertEquals(3, workspace.getNodes().size());
           assertNotNull(workspace.getNode(Fqn.fromString("/one/two")));
  @@ -288,16 +288,16 @@
   
   
           assertEquals(null, dummy.getCalled());
  -        OptimisticTreeNode node = (OptimisticTreeNode) workspace.getNode(Fqn.fromString("/")).getNode();
  +      NodeSPI node = workspace.getNode(Fqn.fromString("/")).getNode();
           //assert we can navigate
   
           assertNotNull(node);
  -        node = (OptimisticTreeNode) node.getChild("one");
  +      node = (NodeSPI) node.getChild("one");
           assertEquals(new DefaultDataVersion(1), node.getVersion());
           assertNotNull(node);
           assertTrue(cache.exists(node.getFqn()));
           assertEquals(new DefaultDataVersion(1), node.getVersion());
  -        node = (OptimisticTreeNode) node.getChild("two");
  +      node = (NodeSPI) node.getChild("two");
           assertNotNull(node);
           assertTrue(cache.exists(node.getFqn()));
           assertEquals(new DefaultDataVersion(1), node.getVersion());
  @@ -313,16 +313,16 @@
       public void testTransactionValidateFailRemoteCommitMethod() throws Exception
       {
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           Interceptor validateInterceptor = new OptimisticValidatorInterceptor();
  -        validateInterceptor.setCache(cache.getCacheSPI());
  +      validateInterceptor.setCache(cache);
           Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -        interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
           Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -        nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
           MockInterceptor dummy = new MockInterceptor();
  -        dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
           validateInterceptor.setNext(interceptor);
           interceptor.setNext(nodeInterceptor);
           nodeInterceptor.setNext(dummy);
  @@ -395,16 +395,16 @@
   
   
           assertEquals(null, dummy.getCalled());
  -        OptimisticTreeNode node = (OptimisticTreeNode) workspace.getNode(Fqn.fromString("/")).getNode();
  +      NodeSPI node = workspace.getNode(Fqn.fromString("/")).getNode();
           //assert we can navigate
   
           assertNotNull(node);
  -        node = (OptimisticTreeNode) node.getChild("one");
  +      node = (NodeSPI) node.getChild("one");
           assertEquals(new DefaultDataVersion(1), node.getVersion());
           assertNotNull(node);
           assertTrue(cache.exists(node.getFqn()));
           assertEquals(new DefaultDataVersion(1), node.getVersion());
  -        node = (OptimisticTreeNode) node.getChild("two");
  +      node = (NodeSPI) node.getChild("two");
           assertNotNull(node);
           assertTrue(cache.exists(node.getFqn()));
           assertEquals(new DefaultDataVersion(1), node.getVersion());
  @@ -419,15 +419,15 @@
       public void testTransactionValidateRollbackMethod() throws Exception
       {
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
           Interceptor validateInterceptor = new OptimisticValidatorInterceptor();
  -        validateInterceptor.setCache(cache.getCacheSPI());
  +      validateInterceptor.setCache(cache);
           Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -        interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
           Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -        nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
           MockInterceptor dummy = new MockInterceptor();
  -        dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
           validateInterceptor.setNext(interceptor);
           interceptor.setNext(nodeInterceptor);
           nodeInterceptor.setNext(dummy);
  @@ -458,9 +458,9 @@
           TransactionWorkspace workspace = entry.getTransactionWorkSpace();
   
           /*GlobalTransaction.class,
  -List.class,
  -Address.class,
  -boolean.class*/
  +      List.class,
  +      Address.class,
  +      boolean.class*/
   
           assertEquals(3, workspace.getNodes().size());
           assertNotNull(workspace.getNode(Fqn.fromString("/one/two")));
  
  
  
  1.3       +43 -43    JBossCache/tests/functional/org/jboss/cache/optimistic/ValidationFailureTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ValidationFailureTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ValidationFailureTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ValidationFailureTest.java	25 Apr 2006 15:18:29 -0000	1.2
  +++ ValidationFailureTest.java	30 Dec 2006 17:49:52 -0000	1.3
  @@ -6,10 +6,10 @@
    */
   package org.jboss.cache.optimistic;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   
  -import javax.transaction.TransactionManager;
   import javax.transaction.Transaction;
  +import javax.transaction.TransactionManager;
   
   /**
    * Tests a failure in validating a concurrently updated node
  @@ -25,7 +25,7 @@
   
       public void testValidationFailureLockRelease() throws Exception
       {
  -        TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
   
           TransactionManager mgr = cache.getTransactionManager();
   
  @@ -51,7 +51,7 @@
               mgr.commit();
               assertTrue("Should have failed", false);
           }
  -        catch(Exception e)
  +      catch (Exception e)
           {
               assertTrue("Expecting this to fail", true);
           }
  
  
  
  1.26      +20 -20    JBossCache/tests/functional/org/jboss/cache/optimistic/CacheTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/CacheTest.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- CacheTest.java	11 Nov 2006 19:55:18 -0000	1.25
  +++ CacheTest.java	30 Dec 2006 17:49:52 -0000	1.26
  @@ -7,11 +7,11 @@
   import junit.framework.Assert;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.loader.SamplePojo;
   import org.jboss.cache.marshall.MethodCall;
  @@ -41,7 +41,7 @@
   
      public void testExplicitTxFailure() throws Exception
      {
  -      final TreeCache c = createCache();
  +      final CacheImpl c = createCache();
   
         // explicit.
         TransactionManager mgr = c.getTransactionManager();
  @@ -64,7 +64,7 @@
   
      public void testImplicitTxFailure() throws Exception
      {
  -      final TreeCache c = createCache();
  +      final CacheImpl c = createCache();
   
         // implicit (much harder to orchestrate...
         int numThreads = 50;
  @@ -101,12 +101,12 @@
   
      public void testLocalTransaction() throws Exception
      {
  -      TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         assertNull(mgr.getTransaction());
  @@ -140,12 +140,12 @@
      public void testRollbackTransaction() throws Exception
      {
   
  -      TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         assertNull(mgr.getTransaction());
  @@ -173,12 +173,12 @@
      public void testRemotePrepareTransaction() throws Exception
      {
   
  -      TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
         //start local transaction
  @@ -278,8 +278,8 @@
      {
   
   
  -      TreeCache cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  -      TreeCache cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
         assertEquals(2, cache.getMembers().size());
         assertEquals(2, cache2.getMembers().size());
   
  @@ -330,8 +330,8 @@
      {
   
   
  -      TreeCache cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  -      TreeCache cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
         assertEquals(2, cache.getMembers().size());
         assertEquals(2, cache2.getMembers().size());
   
  @@ -386,8 +386,8 @@
      {
   
   
  -      TreeCache cache = createPessimisticCache();
  -      TreeCache cache2 = createPessimisticCache();
  +      CacheImpl cache = createPessimisticCache();
  +      CacheImpl cache2 = createPessimisticCache();
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -412,7 +412,7 @@
   
      public void testConcurrentNodeRemoval() throws Exception
      {
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
   
         cache.put(fqn, "key", "value");
   
  @@ -447,7 +447,7 @@
   
      public void testConcurrentNodeModification() throws Exception
      {
  -      TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
   
         cache.put(fqn, "key", "value");
   
  
  
  
  1.14      +4 -4      JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticWithPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticWithPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticWithPassivationTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- OptimisticWithPassivationTest.java	25 Oct 2006 04:50:20 -0000	1.13
  +++ OptimisticWithPassivationTest.java	30 Dec 2006 17:49:52 -0000	1.14
  @@ -7,7 +7,7 @@
   package org.jboss.cache.optimistic;
   
   import junit.framework.Assert;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.loader.CacheLoader;
  @@ -49,9 +49,9 @@
         return XmlConfigurationParser.parseCacheLoaderConfig(element);
      }
   
  -   private TreeCache createLocalCache() throws Exception
  +   private CacheImpl createLocalCache() throws Exception
      {
  -      TreeCache cache = createCacheUnstarted(false);
  +      CacheImpl cache = createCacheUnstarted(false);
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig(getTempDir()));
   
         cache.create();
  @@ -61,7 +61,7 @@
   
      public void testPassivationLocal() throws Exception
      {
  -      TreeCache cache = createLocalCache();
  +      CacheImpl cache = createLocalCache();
         CacheLoader loader = cache.getCacheLoader();
   
         // clean up
  
  
  
  1.20      +584 -580  JBossCache/tests/functional/org/jboss/cache/optimistic/FullStackInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FullStackInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/FullStackInterceptorTest.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- FullStackInterceptorTest.java	20 Nov 2006 03:53:56 -0000	1.19
  +++ FullStackInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.20
  @@ -3,7 +3,11 @@
   import junit.framework.Assert;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.*;
  +import org.jboss.cache.CacheImpl;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.GlobalTransaction;
  +import org.jboss.cache.OptimisticTransactionEntry;
  +import org.jboss.cache.TransactionTable;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.loader.SamplePojo;
   import org.jboss.cache.transaction.DummyTransactionManager;
  @@ -33,7 +37,7 @@
       public void testLocalTransaction() throws Exception
       {
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -66,7 +70,7 @@
       {
           TestListener listener = new TestListener();
   
  -        TreeCache cache = createCacheWithListener(listener);
  +      CacheImpl cache = createCacheWithListener(listener);
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -103,7 +107,7 @@
       public void testSingleInstanceCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -144,7 +148,7 @@
       public void testSingleInstanceRollback() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createSyncReplicatedCache();
  +      CacheImpl cache = createSyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -174,7 +178,7 @@
       public void testSingleInstanceDuplicateCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createSyncReplicatedCache();
  +      CacheImpl cache = createSyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -225,7 +229,7 @@
       public void testValidationFailCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createSyncReplicatedCache();
  +      CacheImpl cache = createSyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -292,8 +296,8 @@
       public void test2InstanceCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createSyncReplicatedCache();
  -        TreeCache cache2 = createSyncReplicatedCache();
  +      CacheImpl cache = createSyncReplicatedCache();
  +      CacheImpl cache2 = createSyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -351,8 +355,8 @@
       public void test2InstanceRemove() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createSyncReplicatedCache();
  -        TreeCache cache2 = createSyncReplicatedCache();
  +      CacheImpl cache = createSyncReplicatedCache();
  +      CacheImpl cache2 = createSyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -400,7 +404,7 @@
           assertNotNull(cache2.get(Fqn.fromString("/")).getChild("one"));
           assertEquals(false, cache2.get(Fqn.fromString("/")).getNodeSPI().getLock().isLocked());
           assertEquals(false, cache2.get(Fqn.fromString("/one")).getNodeSPI().getLock().isLocked());
  -        assertEquals(false, cache2.get(Fqn.fromString("/one/two")).getLock().isLocked());
  +      assertEquals(false, cache2.get(Fqn.fromString("/one/two")).getNodeSPI().getLock().isLocked());
           assertNotNull(cache2.get(Fqn.fromString("/one")).getChild("two"));
           assertNotNull(cache2.get(Fqn.fromString("/one/two"), "key1"));
   
  @@ -420,8 +424,8 @@
       public void testValidationFailCommit2Instances() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createSyncReplicatedCache();
  -        TreeCache cache2 = createSyncReplicatedCache();
  +      CacheImpl cache = createSyncReplicatedCache();
  +      CacheImpl cache2 = createSyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -498,7 +502,7 @@
           SamplePojo pojo1 = new SamplePojo(21, "test-1");
           SamplePojo pojo2 = new SamplePojo(21, "test-2");
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -545,7 +549,7 @@
       public void testGetKeysIsolationTransaction() throws Exception
       {
   
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           if (mgr.getTransaction() != null) mgr.rollback();
  @@ -589,7 +593,7 @@
   
       public void testTxRollbackThroughConcurrentWrite() throws Exception
       {
  -        TreeCache cache = createCacheWithListener();
  +      CacheImpl cache = createCacheWithListener();
           Set keys;
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  @@ -650,14 +654,14 @@
       }
   
   
  -    protected TreeCache createSyncReplicatedCache() throws Exception
  +   protected CacheImpl createSyncReplicatedCache() throws Exception
       {
           return createReplicatedCache("temp" + groupIncreaser, Configuration.CacheMode.REPL_SYNC);
       }
   
       public void testPuts() throws Exception
       {
  -        TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
           Transaction tx;
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  @@ -683,7 +687,7 @@
   
       public void testRemoves() throws Exception
       {
  -        TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
           Transaction tx;
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  @@ -712,7 +716,7 @@
   
       public void testRemovesBeforeGet() throws Exception
       {
  -        TreeCache cache = createCache();
  +      CacheImpl cache = createCache();
           Transaction tx;
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
  @@ -742,8 +746,8 @@
           try
           {
               log.debug("Starting test");
  -            TreeCache cache1 = createSyncReplicatedCache();
  -            TreeCache cache2 = createSyncReplicatedCache();
  +         CacheImpl cache1 = createSyncReplicatedCache();
  +         CacheImpl cache2 = createSyncReplicatedCache();
               log.debug("Created caches");
               DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  
  
  
  1.17      +16 -17    JBossCache/tests/functional/org/jboss/cache/optimistic/OpLockingInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OpLockingInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OpLockingInterceptorTest.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- OpLockingInterceptorTest.java	20 Nov 2006 03:53:56 -0000	1.16
  +++ OpLockingInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.17
  @@ -6,13 +6,12 @@
    */
   package org.jboss.cache.optimistic;
   
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Node;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticLockingInterceptor;
  @@ -49,16 +48,16 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor lockingInterceptor = new OptimisticLockingInterceptor();
  -      lockingInterceptor.setCache(cache.getCacheSPI());
  +      lockingInterceptor.setCache(cache);
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
         lockingInterceptor.setNext(interceptor);
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -140,16 +139,16 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor lockingInterceptor = new OptimisticLockingInterceptor();
  -      lockingInterceptor.setCache(cache.getCacheSPI());
  +      lockingInterceptor.setCache(cache);
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
         lockingInterceptor.setNext(interceptor);
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -257,16 +256,16 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor lockingInterceptor = new OptimisticLockingInterceptor();
  -      lockingInterceptor.setCache(cache.getCacheSPI());
  +      lockingInterceptor.setCache(cache);
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
         lockingInterceptor.setNext(interceptor);
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.43      +25 -25    JBossCache/tests/functional/org/jboss/cache/optimistic/AbstractOptimisticTestCase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractOptimisticTestCase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/AbstractOptimisticTestCase.java,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- AbstractOptimisticTestCase.java	11 Nov 2006 19:55:18 -0000	1.42
  +++ AbstractOptimisticTestCase.java	30 Dec 2006 17:49:52 -0000	1.43
  @@ -4,10 +4,10 @@
   package org.jboss.cache.optimistic;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheListener;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -69,14 +69,14 @@
         super(name);
      }
   
  -   protected TreeCache createCacheUnstarted() throws Exception
  +   protected CacheImpl createCacheUnstarted() throws Exception
      {
         return createCacheUnstarted(true);
      }
   
  -   protected TreeCache createCacheUnstarted(boolean optimistic) throws Exception
  +   protected CacheImpl createCacheUnstarted(boolean optimistic) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
         if (optimistic) c.setNodeLockingScheme("OPTIMISTIC");
  @@ -86,14 +86,14 @@
         return cache;
      }
   
  -   protected TreeCache createCacheWithListener() throws Exception
  +   protected CacheImpl createCacheWithListener() throws Exception
      {
         return createCacheWithListener(new TestListener());
      }
   
  -   protected TreeCache createCacheWithListener(CacheListener listener) throws Exception
  +   protected CacheImpl createCacheWithListener(CacheListener listener) throws Exception
      {
  -      TreeCache cache = createCacheUnstarted();
  +      CacheImpl cache = createCacheUnstarted();
         cache.create();
         cache.start();
         cache.getNotifier().addCacheListener(listener);
  @@ -106,7 +106,7 @@
       * @return
       * @throws Exception
       */
  -   protected TreeCache createCacheWithLoader() throws Exception
  +   protected CacheImpl createCacheWithLoader() throws Exception
      {
         return createCacheWithLoader(false);
      }
  @@ -130,9 +130,9 @@
         return XmlConfigurationParser.parseCacheLoaderConfig(element);
      }
   
  -   protected TreeCache createCacheWithLoader(boolean passivationEnabled) throws Exception
  +   protected CacheImpl createCacheWithLoader(boolean passivationEnabled) throws Exception
      {
  -      TreeCache cache = createCacheUnstarted();
  +      CacheImpl cache = createCacheUnstarted();
         Configuration c = cache.getConfiguration();
         cache.setConfiguration(c);
         c.setCacheLoaderConfig(getCacheLoaderConfig(true, getTempDir(), passivationEnabled));
  @@ -142,24 +142,24 @@
      }
   
   
  -   protected TreeCache createCache() throws Exception
  +   protected CacheImpl createCache() throws Exception
      {
  -      TreeCache cache = createCacheUnstarted();
  +      CacheImpl cache = createCacheUnstarted();
         cache.create();
         cache.start();
         return cache;
      }
   
  -   protected void destroyCache(TreeCache c)
  +   protected void destroyCache(CacheImpl c)
      {
         c.stop();
         c.destroy();
      }
   
   
  -   protected TreeCache createPessimisticCache() throws Exception
  +   protected CacheImpl createPessimisticCache() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
   
  @@ -176,9 +176,9 @@
         return cache;
      }
   
  -   protected TreeCache createPessimisticCacheLocal() throws Exception
  +   protected CacheImpl createPessimisticCacheLocal() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
   
  @@ -213,14 +213,14 @@
                 "pbcast.STATE_TRANSFER";
      }
   
  -   protected TreeCache createReplicatedCache(Configuration.CacheMode mode) throws Exception
  +   protected CacheImpl createReplicatedCache(Configuration.CacheMode mode) throws Exception
      {
         return createReplicatedCache("test", mode);
      }
   
  -   protected TreeCache createReplicatedCache(String name, Configuration.CacheMode mode) throws Exception
  +   protected CacheImpl createReplicatedCache(String name, Configuration.CacheMode mode) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
   
  @@ -242,24 +242,24 @@
         return cache;
      }
   
  -   protected TreeCache createReplicatedCacheWithLoader(boolean shared, Configuration.CacheMode cacheMode) throws Exception
  +   protected CacheImpl createReplicatedCacheWithLoader(boolean shared, Configuration.CacheMode cacheMode) throws Exception
      {
         return createReplicatedCacheWithLoader("temp-loader", shared, cacheMode);
      }
   
  -   protected TreeCache createReplicatedCacheWithLoader(boolean shared) throws Exception
  +   protected CacheImpl createReplicatedCacheWithLoader(boolean shared) throws Exception
      {
         return createReplicatedCacheWithLoader("temp-loader", shared, Configuration.CacheMode.REPL_SYNC);
      }
   
  -   protected TreeCache createReplicatedCacheWithLoader(String name, boolean shared) throws Exception
  +   protected CacheImpl createReplicatedCacheWithLoader(String name, boolean shared) throws Exception
      {
         return createReplicatedCacheWithLoader(name, shared, Configuration.CacheMode.REPL_SYNC);
      }
   
  -   protected TreeCache createReplicatedCacheWithLoader(String name, boolean shared, Configuration.CacheMode cacheMode) throws Exception
  +   protected CacheImpl createReplicatedCacheWithLoader(String name, boolean shared, Configuration.CacheMode cacheMode) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
         c.setClusterName(name);
  
  
  
  1.11      +10 -10    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveKeyValTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorRemoveKeyValTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveKeyValTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeInterceptorRemoveKeyValTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ NodeInterceptorRemoveKeyValTest.java	30 Dec 2006 17:49:52 -0000	1.11
  @@ -6,11 +6,11 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -41,12 +41,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  @@ -92,12 +92,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  @@ -150,12 +150,12 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
         dummy.setCache(cache);
   
  
  
  
  1.9       +9 -9      JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorTransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorTransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorTransactionTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- NodeInterceptorTransactionTest.java	6 Sep 2006 15:30:58 -0000	1.8
  +++ NodeInterceptorTransactionTest.java	30 Dec 2006 17:49:52 -0000	1.9
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.optimistic;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -30,14 +30,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -62,14 +62,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.7       +281 -277  JBossCache/tests/functional/org/jboss/cache/optimistic/AsyncFullStackInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncFullStackInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/AsyncFullStackInterceptorTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- AsyncFullStackInterceptorTest.java	20 Nov 2006 03:53:56 -0000	1.6
  +++ AsyncFullStackInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.7
  @@ -2,10 +2,14 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.*;
  +import org.jboss.cache.CacheImpl;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.GlobalTransaction;
  +import org.jboss.cache.OptimisticTransactionEntry;
  +import org.jboss.cache.TransactionTable;
   import org.jboss.cache.config.Configuration;
  -import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.loader.SamplePojo;
  +import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.transaction.Transaction;
  @@ -32,7 +36,7 @@
       public void testSingleInstanceRollback() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createAsyncReplicatedCache();
  +      CacheImpl cache = createAsyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -62,7 +66,7 @@
       public void testSingleInstanceDuplicateCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createAsyncReplicatedCache();
  +      CacheImpl cache = createAsyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -113,7 +117,7 @@
       public void testValidationFailCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createAsyncReplicatedCache();
  +      CacheImpl cache = createAsyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -180,8 +184,8 @@
       public void test2InstanceCommit() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createAsyncReplicatedCache();
  -        TreeCache cache2 = createAsyncReplicatedCache();
  +      CacheImpl cache = createAsyncReplicatedCache();
  +      CacheImpl cache2 = createAsyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -217,7 +221,7 @@
           assertNotNull(cache.get(Fqn.fromString("/one/two"), "key1"));
   
           // let async calls propagate
  -        TestingUtil.sleepThread((long)1000);
  +      TestingUtil.sleepThread((long) 1000);
   
           // cache2 asserts
           assertEquals(0, cache2.getTransactionTable().getNumGlobalTransactions());
  @@ -242,8 +246,8 @@
       public void test2InstanceRemove() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createAsyncReplicatedCache();
  -        TreeCache cache2 = createAsyncReplicatedCache();
  +      CacheImpl cache = createAsyncReplicatedCache();
  +      CacheImpl cache2 = createAsyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -280,7 +284,7 @@
           assertNotNull(cache.get(Fqn.fromString("/one/two"), "key1"));
   
           // let async calls propagate
  -        TestingUtil.sleepThread((long)1000);
  +      TestingUtil.sleepThread((long) 1000);
   
           // cache2 asserts
           assertEquals(0, cache2.getTransactionTable().getNumGlobalTransactions());
  @@ -304,7 +308,7 @@
           assertEquals(null, cache.get("/one/two", "key1"));
   
           // let async calls propagate
  -        TestingUtil.sleepThread((long)1000);
  +      TestingUtil.sleepThread((long) 1000);
   
           log.debug("  C2 " + cache2.get("/one/two"));
           assertEquals(false, cache2.exists("/one/two"));
  @@ -317,8 +321,8 @@
       public void testValidationFailCommit2Instances() throws Exception
       {
           groupIncreaser++;
  -        TreeCache cache = createAsyncReplicatedCache();
  -        TreeCache cache2 = createAsyncReplicatedCache();
  +      CacheImpl cache = createAsyncReplicatedCache();
  +      CacheImpl cache2 = createAsyncReplicatedCache();
   
           DummyTransactionManager mgr = DummyTransactionManager.getInstance();
           assertNull(mgr.getTransaction());
  @@ -355,7 +359,7 @@
           mgr.commit();
   
           // let async calls propagate
  -        TestingUtil.sleepThread((long)1000);
  +      TestingUtil.sleepThread((long) 1000);
   
           assertEquals(1, cache.getTransactionTable().getNumGlobalTransactions());
           assertEquals(1, cache.getTransactionTable().getNumLocalTransactions());
  @@ -393,7 +397,7 @@
   
       }
   
  -    protected TreeCache createAsyncReplicatedCache() throws Exception
  +   protected CacheImpl createAsyncReplicatedCache() throws Exception
       {
           return createReplicatedCache("temp" + groupIncreaser, Configuration.CacheMode.REPL_ASYNC);
       }
  
  
  
  1.19      +31 -31    JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticReplicationInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticReplicationInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticReplicationInterceptorTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- OptimisticReplicationInterceptorTest.java	11 Nov 2006 19:55:18 -0000	1.18
  +++ OptimisticReplicationInterceptorTest.java	30 Dec 2006 17:49:52 -0000	1.19
  @@ -6,10 +6,10 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.loader.SamplePojo;
   import org.jboss.cache.marshall.MethodCall;
  @@ -32,7 +32,7 @@
    */
   public class OptimisticReplicationInterceptorTest extends AbstractOptimisticTestCase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      /**
       * @param name
  @@ -57,9 +57,9 @@
      public void testLocalTransaction() throws Exception
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         assertNull(mgr.getTransaction());
  @@ -90,9 +90,9 @@
      public void testRollbackTransaction() throws Exception
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         assertNull(mgr.getTransaction());
  @@ -118,9 +118,9 @@
      public void testRemotePrepareTransaction() throws Exception
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -187,9 +187,9 @@
      public void testRemoteRollbackTransaction() throws Exception
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -271,9 +271,9 @@
      public void testRemoteCommitNoPrepareTransaction() throws Exception
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -334,9 +334,9 @@
      public void testRemoteRollbackNoPrepareTransaction() throws Throwable
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -391,9 +391,9 @@
      public void testRemoteCommitTransaction() throws Exception
      {
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -478,15 +478,15 @@
         cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
   
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
  -      TreeCache cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
         MockInterceptor dummy2 = new MockInterceptor();
  -      dummy.setCache(cache2.getCacheSPI());
  +      dummy.setCache(cache2);
   
  -      cache2.setInterceptorChain(getAlteredInterceptorChain(dummy2, cache2.getCacheSPI(), true));
  +      cache2.setInterceptorChain(getAlteredInterceptorChain(dummy2, cache2, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -537,18 +537,18 @@
         cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
   
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
  -      TreeCache cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
         MockFailureInterceptor dummy2 = new MockFailureInterceptor();
         List failures = new ArrayList();
         failures.add(MethodDeclarations.optimisticPrepareMethod);
         dummy2.setFailurelist(failures);
  -      dummy.setCache(cache2.getCacheSPI());
  +      dummy.setCache(cache2);
   
  -      cache2.setInterceptorChain(getAlteredInterceptorChain(dummy2, cache2.getCacheSPI(), true));
  +      cache2.setInterceptorChain(getAlteredInterceptorChain(dummy2, cache2, true));
   
         DummyTransactionManager mgr = DummyTransactionManager.getInstance();
   
  @@ -607,15 +607,15 @@
         cache = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
   
         MockFailureInterceptor dummy = new MockFailureInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
  -      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache.getCacheSPI(), true));
  +      cache.setInterceptorChain(getAlteredInterceptorChain(dummy, cache, true));
   
  -      TreeCache cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
  +      CacheImpl cache2 = createReplicatedCache(Configuration.CacheMode.REPL_SYNC);
         MockInterceptor dummy2 = new MockInterceptor();
  -      dummy.setCache(cache2.getCacheSPI());
  +      dummy.setCache(cache2);
   
  -      cache2.setInterceptorChain(getAlteredInterceptorChain(dummy2, cache2.getCacheSPI(), true));
  +      cache2.setInterceptorChain(getAlteredInterceptorChain(dummy2, cache2, true));
   
         List failures = new ArrayList();
         failures.add(MethodDeclarations.optimisticPrepareMethod);
  
  
  
  1.4       +6 -6      JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoveBeforeCreateTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- RemoveBeforeCreateTest.java	20 Dec 2006 13:29:16 -0000	1.3
  +++ RemoveBeforeCreateTest.java	30 Dec 2006 17:49:52 -0000	1.4
  @@ -1,8 +1,8 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -13,12 +13,12 @@
    */
   public class RemoveBeforeCreateTest extends AbstractOptimisticTestCase
   {
  -   TreeCache[] c = null;
  +   CacheImpl[] c = null;
      TransactionManager t;
   
      protected void setUp() throws Exception
      {
  -      c = new TreeCache[2];
  +      c = new CacheImpl[2];
         c[0] = createReplicatedCache(Configuration.CacheMode.REPL_ASYNC);
         c[1] = createReplicatedCache(Configuration.CacheMode.REPL_ASYNC);
   
  @@ -52,10 +52,10 @@
         assertEquals("value", c[0].get("/control", "key"));
         assertEquals("value", c[1].get("/control", "key"));
   
  -      DefaultDataVersion v1 = (DefaultDataVersion) ((OptimisticTreeNode) c[0].get("/control")).getVersion();
  +      DefaultDataVersion v1 = (DefaultDataVersion) ((NodeSPI) c[0].get("/control")).getVersion();
         assertEquals(1, v1.getRawVersion());
   
  -      DefaultDataVersion v2 = (DefaultDataVersion) ((OptimisticTreeNode) c[1].get("/control")).getVersion();
  +      DefaultDataVersion v2 = (DefaultDataVersion) ((NodeSPI) c[1].get("/control")).getVersion();
         assertEquals(1, v2.getRawVersion());
   
   
  
  
  
  1.5       +4 -4      JBossCache/tests/functional/org/jboss/cache/optimistic/ConcurrentTransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentTransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ConcurrentTransactionTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ConcurrentTransactionTest.java	6 Sep 2006 15:30:58 -0000	1.4
  +++ ConcurrentTransactionTest.java	30 Dec 2006 17:49:52 -0000	1.5
  @@ -6,9 +6,9 @@
    */
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  @@ -18,7 +18,7 @@
    */
   public class ConcurrentTransactionTest extends AbstractOptimisticTestCase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      public ConcurrentTransactionTest(String name)
      {
  @@ -75,7 +75,7 @@
   
         assertEquals(value, cache.get("/a/b/x/y", key));
   
  -      OptimisticTreeNode n = (OptimisticTreeNode) cache.get(Fqn.ROOT);
  +      NodeSPI n = (NodeSPI) cache.get(Fqn.ROOT);
         System.out.println(n.getVersion());
      }
   }
  
  
  
  1.12      +17 -17    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveDataTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorRemoveDataTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveDataTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- NodeInterceptorRemoveDataTest.java	6 Sep 2006 15:30:58 -0000	1.11
  +++ NodeInterceptorRemoveDataTest.java	30 Dec 2006 17:49:52 -0000	1.12
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -34,14 +34,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -85,14 +85,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -142,14 +142,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -202,14 +202,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.11      +13 -13    JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeysTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorGetKeysTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeysTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- NodeInterceptorGetKeysTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ NodeInterceptorGetKeysTest.java	30 Dec 2006 17:49:52 -0000	1.11
  @@ -1,10 +1,10 @@
   package org.jboss.cache.optimistic;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.OptimisticTransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
   import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
  @@ -34,14 +34,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -103,14 +103,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  @@ -152,14 +152,14 @@
      {
   
         TestListener listener = new TestListener();
  -      final TreeCache cache = createCacheWithListener(listener);
  +      final CacheImpl cache = createCacheWithListener(listener);
   
         Interceptor interceptor = new OptimisticCreateIfNotExistsInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
         Interceptor nodeInterceptor = new OptimisticNodeInterceptor();
  -      nodeInterceptor.setCache(cache.getCacheSPI());
  +      nodeInterceptor.setCache(cache);
         MockInterceptor dummy = new MockInterceptor();
  -      dummy.setCache(cache.getCacheSPI());
  +      dummy.setCache(cache);
   
         interceptor.setNext(nodeInterceptor);
         nodeInterceptor.setNext(dummy);
  
  
  
  1.7       +41 -41    JBossCache/tests/functional/org/jboss/cache/optimistic/MockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/MockInterceptor.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- MockInterceptor.java	25 Aug 2006 14:10:10 -0000	1.6
  +++ MockInterceptor.java	30 Dec 2006 17:49:52 -0000	1.7
  @@ -1,6 +1,6 @@
   package org.jboss.cache.optimistic;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.interceptors.Interceptor;
   import org.jboss.cache.marshall.MethodCall;
   
  @@ -20,9 +20,9 @@
   {
   
   
  -    public void setCache(TreeCache cache)
  +   public void setCache(CacheImpl cache)
       {
  -        super.setCache(cache.getCacheSPI());
  +      super.setCache(cache);
   
       }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:53 -0500
Subject: [jboss-cvs] JBossCache/etc/META-INF ...
Message-ID: <E1H0iLB-0008Ix-54@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:53

  Modified:    etc/META-INF                                      
                        mux-service.xml tree-service.xml
                        invalidationAsync-service.xml
                        local-elementsize-eviction-service.xml
                        pojocache-passivation-service.xml
                        interopCurSync-service.xml node2.xml node1.xml
                        replAsyncSharedCacheLoader-service.xml
                        replSync-passivation-service.xml
                        replAsync-optimistic-service.xml
                        local-eviction-cacheloader-service.xml
                        optimistic-eviction.xml interopCurAsync-service.xml
                        replSync-service.xml local-passivation-service.xml
                        interopPrevAsync-service.xml
                        local-mru-eviction-service.xml oodb-service.xml
                        policyPerRegion-eviction-service.xml
                        local-fifo-eviction-service.xml
                        local-lru-eviction-service.xml
                        singleton-nopush-service.xml
                        optimal-for-large-cluster-http-session-repl.xml
                        local-service.xml invalidationSync-service.xml
                        replSync-ChainingCacheLoader-service.xml
                        replSync-optimistic-service.xml
                        local-lfu-eviction-service.xml
                        mixedPolicy-eviction-service.xml
                        buddyreplication-service.xml
                        replSync-ClusteredCacheLoader-service.xml
                        replAsync-service.xml
                        hibernate-recommended-config.xml
                        singleton-push-service.xml local-tx-service.xml
                        replSync-eviction-service.xml
                        interopPrevSync-service.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.5       +98 -98    JBossCache/etc/META-INF/mux-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: mux-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/mux-service.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- mux-service.xml	21 Sep 2006 15:08:39 -0000	1.4
  +++ mux-service.xml	30 Dec 2006 17:49:52 -0000	1.5
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=testTreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -55,7 +55,7 @@
           <!-- Name of cluster. Needs to be the same for all nodes in a clusters, in order
                to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
           <!-- JGroups protocol stack properties. 
              ClusterConfig isn't used if the multiplexer is enabled and successfully initialized.
  
  
  
  1.7       +103 -103  JBossCache/etc/META-INF/tree-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: tree-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/tree-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- tree-service.xml	21 Sep 2006 15:08:39 -0000	1.6
  +++ tree-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=testTreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -47,11 +47,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.7       +130 -130  JBossCache/etc/META-INF/invalidationAsync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: invalidationAsync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/invalidationAsync-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- invalidationAsync-service.xml	21 Sep 2006 15:08:39 -0000	1.6
  +++ invalidationAsync-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.6       +19 -19    JBossCache/etc/META-INF/local-elementsize-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-elementsize-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-elementsize-eviction-service.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- local-elementsize-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.5
  +++ local-elementsize-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.6
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.4       +2 -2      JBossCache/etc/META-INF/pojocache-passivation-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: pojocache-passivation-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/pojocache-passivation-service.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- pojocache-passivation-service.xml	7 Nov 2006 07:05:31 -0000	1.3
  +++ pojocache-passivation-service.xml	30 Dec 2006 17:49:52 -0000	1.4
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,7 +46,7 @@
         <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
              cluster in order to find each other.
         -->
  -      <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
         <!--Uncomment next three statements to enable JGroups multiplexer.
   This configuration is dependent on the JGroups multiplexer being
  
  
  
  1.7       +143 -145  JBossCache/etc/META-INF/interopCurSync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: interopCurSync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/interopCurSync-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- interopCurSync-service.xml	21 Sep 2006 15:08:39 -0000	1.6
  +++ interopCurSync-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -60,11 +60,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  @@ -154,8 +154,6 @@
          -->
   
   
  -
  -
       </mbean>
   
   
  
  
  
  1.14      +180 -183  JBossCache/etc/META-INF/node2.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: node2.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/node2.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- node2.xml	21 Sep 2006 15:08:39 -0000	1.13
  +++ node2.xml	30 Dec 2006 17:49:52 -0000	1.14
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -64,11 +64,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  @@ -131,18 +131,17 @@
           <attribute name="EvictionPolicyClass"></attribute>
   
   
  -
          <!--
  -*************************************************************************************
  -JBossCache can use Berkeley DB Java Edition from Sleepycat Software (http://www.sleepycat.com)
  -for persistent, reliable and transaction-protected data storage.
  -If you choose to use Berkeley DB Java Edition with JBossCache, you must comply with the terms
  -of Sleepycat's public license, included in the file LICENSE.txt.
  -If you prefer not to release the source code for your own application in order to comply
  -with the Sleepycat public license, you may purchase a different license for use of
  -Berkeley DB Java Edition with JBossCache.
  -Contact Sleepycat Software at info at sleepycat.com for pricing and terms for that license
  -*************************************************************************************
  +     *************************************************************************************
  +     JBossCache can use Berkeley DB Java Edition from Sleepycat Software (http://www.sleepycat.com)
  +     for persistent, reliable and transaction-protected data storage.
  +     If you choose to use Berkeley DB Java Edition with JBossCache, you must comply with the terms
  +     of Sleepycat's public license, included in the file LICENSE.txt.
  +     If you prefer not to release the source code for your own application in order to comply
  +     with the Sleepycat public license, you may purchase a different license for use of
  +     Berkeley DB Java Edition with JBossCache.
  +     Contact Sleepycat Software at info at sleepycat.com for pricing and terms for that license
  +     *************************************************************************************
    -->
           <!--
            Whether or not to fetch state on joining a cluster
  @@ -196,7 +195,6 @@
       </mbean>
   
   
  -
      <!--  Uncomment to get a graphical view of the TreeCache MBean above -->
      <!--   <mbean code="org.jboss.cache.TreeCacheView" name="jboss.cache:service=TreeCacheView">-->
      <!--      <depends>jboss.cache:service=TreeCache</depends>-->
  @@ -204,5 +202,4 @@
      <!--   </mbean>-->
   
   
  -
   </server>
  
  
  
  1.14      +167 -169  JBossCache/etc/META-INF/node1.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: node1.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/node1.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- node1.xml	21 Sep 2006 15:08:39 -0000	1.13
  +++ node1.xml	30 Dec 2006 17:49:52 -0000	1.14
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -64,11 +64,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  @@ -181,7 +181,6 @@
       </mbean>
   
   
  -
      <!--  Uncomment to get a graphical view of the TreeCache MBean above -->
      <!--   <mbean code="org.jboss.cache.TreeCacheView" name="jboss.cache:service=TreeCacheView">-->
      <!--      <depends>jboss.cache:service=TreeCache</depends>-->
  @@ -189,5 +188,4 @@
      <!--   </mbean>-->
   
   
  -
   </server>
  
  
  
  1.14      +167 -167  JBossCache/etc/META-INF/replAsyncSharedCacheLoader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsyncSharedCacheLoader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsyncSharedCacheLoader-service.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- replAsyncSharedCacheLoader-service.xml	5 Dec 2006 23:35:41 -0000	1.13
  +++ replAsyncSharedCacheLoader-service.xml	30 Dec 2006 17:49:52 -0000	1.14
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.6       +147 -147  JBossCache/etc/META-INF/replSync-passivation-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replSync-passivation-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replSync-passivation-service.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- replSync-passivation-service.xml	23 Oct 2006 17:39:01 -0000	1.5
  +++ replSync-passivation-service.xml	30 Dec 2006 17:49:52 -0000	1.6
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.13      +141 -141  JBossCache/etc/META-INF/replAsync-optimistic-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsync-optimistic-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsync-optimistic-service.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- replAsync-optimistic-service.xml	5 Dec 2006 23:35:41 -0000	1.12
  +++ replAsync-optimistic-service.xml	30 Dec 2006 17:49:52 -0000	1.13
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -72,11 +72,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.3       +2 -2      JBossCache/etc/META-INF/local-eviction-cacheloader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-eviction-cacheloader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-eviction-cacheloader-service.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- local-eviction-cacheloader-service.xml	31 Oct 2006 17:33:36 -0000	1.2
  +++ local-eviction-cacheloader-service.xml	30 Dec 2006 17:49:52 -0000	1.3
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,7 +46,7 @@
         <!-- Name of cluster. Needs to be the same for all clusters, in order
              to find each other
         -->
  -      <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
         <!-- JGroups protocol stack properties. Can also be a URL,
              e.g. file:/home/bela/default.xml
  
  
  
  1.3       +77 -77    JBossCache/etc/META-INF/optimistic-eviction.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: optimistic-eviction.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/optimistic-eviction.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- optimistic-eviction.xml	26 Jun 2006 08:14:06 -0000	1.2
  +++ optimistic-eviction.xml	30 Dec 2006 17:49:52 -0000	1.3
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -29,7 +29,7 @@
           <attribute name="FetchInMemoryState">false</attribute>
           <attribute name="FetchPersistentState">false</attribute>
           <!--  Whether each interceptor should have an mbean
  -              registered to capture and display its statistics.  -->
  +registered to capture and display its statistics.  -->
           <attribute name="UseInterceptorMbeans">true</attribute>
   
           <!--
  
  
  
  1.7       +121 -121  JBossCache/etc/META-INF/interopCurAsync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: interopCurAsync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/interopCurAsync-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- interopCurAsync-service.xml	21 Sep 2006 15:08:39 -0000	1.6
  +++ interopCurAsync-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -59,11 +59,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.14      +124 -124  JBossCache/etc/META-INF/replSync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replSync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replSync-service.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- replSync-service.xml	14 Nov 2006 19:56:09 -0000	1.13
  +++ replSync-service.xml	30 Dec 2006 17:49:52 -0000	1.14
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.10      +2 -2      JBossCache/etc/META-INF/local-passivation-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-passivation-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-passivation-service.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- local-passivation-service.xml	6 Nov 2006 06:59:17 -0000	1.9
  +++ local-passivation-service.xml	30 Dec 2006 17:49:52 -0000	1.10
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,7 +46,7 @@
         <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
              cluster in order to find each other.
         -->
  -      <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
         <!--Uncomment next three statements to enable JGroups multiplexer.
   This configuration is dependent on the JGroups multiplexer being
  
  
  
  1.6       +111 -111  JBossCache/etc/META-INF/interopPrevAsync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: interopPrevAsync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/interopPrevAsync-service.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- interopPrevAsync-service.xml	21 Sep 2006 15:08:39 -0000	1.5
  +++ interopPrevAsync-service.xml	30 Dec 2006 17:49:52 -0000	1.6
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -58,11 +58,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.8       +121 -121  JBossCache/etc/META-INF/local-mru-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-mru-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-mru-eviction-service.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- local-mru-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.7
  +++ local-mru-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.8
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.14      +154 -154  JBossCache/etc/META-INF/oodb-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: oodb-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/oodb-service.xml,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- oodb-service.xml	21 Sep 2006 15:08:39 -0000	1.13
  +++ oodb-service.xml	30 Dec 2006 17:49:52 -0000	1.14
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -48,11 +48,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  @@ -112,28 +112,28 @@
   
           <!-- Name of the eviction policy class. -->
           <attribute name="EvictionPolicyClass"></attribute>
  -<!--
  +      <!--
           <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  --->
  +      -->
           <!--
            Whether or not to fetch state on joining a cluster
            NOTE this used to be called FetchStateOnStartup and has been renamed to be more descriptive.
           -->
           <attribute name="FetchInMemoryState">true</attribute>
   
  -<!-- old 1.2.x cache loader block
  +      <!-- old 1.2.x cache loader block
   
   
  -<attribute name="CacheLoaderClass">org.jboss.cache.loader.FileCacheLoader</attribute>
  -<attribute name="CacheLoaderConfig">
  +      <attribute name="CacheLoaderClass">org.jboss.cache.loader.FileCacheLoader</attribute>
  +      <attribute name="CacheLoaderConfig">
     location=c:\\tmp\\oodb
  -</attribute>
  -<attribute name="CacheLoaderShared">false</attribute>
  -<attribute name="CacheLoaderPreload">/aop</attribute>
  -<attribute name="CacheLoaderFetchTransientState">false</attribute>
  -<attribute name="CacheLoaderFetchPersistentState">true</attribute>
  -<attribute name="CacheLoaderPassivation">false</attribute>
  --->
  +      </attribute>
  +      <attribute name="CacheLoaderShared">false</attribute>
  +      <attribute name="CacheLoaderPreload">/aop</attribute>
  +      <attribute name="CacheLoaderFetchTransientState">false</attribute>
  +      <attribute name="CacheLoaderFetchPersistentState">true</attribute>
  +      <attribute name="CacheLoaderPassivation">false</attribute>
  +      -->
   
           <!-- New 1.3.x cache loader config block -->
           <attribute name="CacheLoaderConfiguration">
  
  
  
  1.7       +19 -19    JBossCache/etc/META-INF/policyPerRegion-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: policyPerRegion-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/policyPerRegion-eviction-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- policyPerRegion-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.6
  +++ policyPerRegion-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.8       +124 -124  JBossCache/etc/META-INF/local-fifo-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-fifo-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-fifo-eviction-service.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- local-fifo-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.7
  +++ local-fifo-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.8
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.8       +133 -133  JBossCache/etc/META-INF/local-lru-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-lru-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-lru-eviction-service.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- local-lru-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.7
  +++ local-lru-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.8
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.2       +164 -164  JBossCache/etc/META-INF/singleton-nopush-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: singleton-nopush-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/singleton-nopush-service.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- singleton-nopush-service.xml	29 Sep 2006 18:27:21 -0000	1.1
  +++ singleton-nopush-service.xml	30 Dec 2006 17:49:52 -0000	1.2
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.13      +178 -178  JBossCache/etc/META-INF/optimal-for-large-cluster-http-session-repl.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: optimal-for-large-cluster-http-session-repl.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/optimal-for-large-cluster-http-session-repl.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- optimal-for-large-cluster-http-session-repl.xml	5 Dec 2006 23:36:24 -0000	1.12
  +++ optimal-for-large-cluster-http-session-repl.xml	30 Dec 2006 17:49:52 -0000	1.13
  @@ -17,7 +17,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -64,11 +64,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.12      +134 -134  JBossCache/etc/META-INF/local-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-service.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- local-service.xml	23 Oct 2006 17:39:01 -0000	1.11
  +++ local-service.xml	30 Dec 2006 17:49:52 -0000	1.12
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -47,11 +47,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  @@ -112,9 +112,9 @@
   
           <!-- Name of the eviction policy class. -->
           <attribute name="EvictionPolicyClass"></attribute>
  -<!--
  +      <!--
           <attribute name="EvictionPolicyClass">org.jboss.cache.eviction.LRUPolicy</attribute>
  --->
  +      -->
           <!-- Specific eviction policy configurations. This is LRU -->
           <attribute name="EvictionPolicyConfig">
              <config>
  
  
  
  1.7       +131 -131  JBossCache/etc/META-INF/invalidationSync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: invalidationSync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/invalidationSync-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- invalidationSync-service.xml	21 Sep 2006 15:08:39 -0000	1.6
  +++ invalidationSync-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.12      +189 -189  JBossCache/etc/META-INF/replSync-ChainingCacheLoader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replSync-ChainingCacheLoader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replSync-ChainingCacheLoader-service.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- replSync-ChainingCacheLoader-service.xml	21 Sep 2006 15:08:39 -0000	1.11
  +++ replSync-ChainingCacheLoader-service.xml	30 Dec 2006 17:49:52 -0000	1.12
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.12      +141 -141  JBossCache/etc/META-INF/replSync-optimistic-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replSync-optimistic-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replSync-optimistic-service.xml,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- replSync-optimistic-service.xml	21 Sep 2006 15:08:39 -0000	1.11
  +++ replSync-optimistic-service.xml	30 Dec 2006 17:49:52 -0000	1.12
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -72,11 +72,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.9       +19 -19    JBossCache/etc/META-INF/local-lfu-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-lfu-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-lfu-eviction-service.xml,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- local-lfu-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.8
  +++ local-lfu-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.9
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.7       +19 -19    JBossCache/etc/META-INF/mixedPolicy-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: mixedPolicy-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/mixedPolicy-eviction-service.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- mixedPolicy-eviction-service.xml	23 Oct 2006 17:39:01 -0000	1.6
  +++ mixedPolicy-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.7
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -46,11 +46,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.10      +2 -2      JBossCache/etc/META-INF/buddyreplication-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: buddyreplication-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/buddyreplication-service.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- buddyreplication-service.xml	21 Sep 2006 15:08:39 -0000	1.9
  +++ buddyreplication-service.xml	30 Dec 2006 17:49:52 -0000	1.10
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=testTreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -48,7 +48,7 @@
         <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
              cluster in order to find each other.
         -->
  -      <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
         <!--Uncomment next three statements to enable JGroups multiplexer.
   This configuration is dependent on the JGroups multiplexer being
  
  
  
  1.11      +153 -153  JBossCache/etc/META-INF/replSync-ClusteredCacheLoader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replSync-ClusteredCacheLoader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replSync-ClusteredCacheLoader-service.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- replSync-ClusteredCacheLoader-service.xml	21 Sep 2006 15:08:39 -0000	1.10
  +++ replSync-ClusteredCacheLoader-service.xml	30 Dec 2006 17:49:52 -0000	1.11
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.13      +126 -126  JBossCache/etc/META-INF/replAsync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replAsync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replAsync-service.xml,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- replAsync-service.xml	5 Dec 2006 23:35:41 -0000	1.12
  +++ replAsync-service.xml	30 Dec 2006 17:49:52 -0000	1.13
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.10      +2 -2      JBossCache/etc/META-INF/hibernate-recommended-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: hibernate-recommended-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/hibernate-recommended-config.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- hibernate-recommended-config.xml	11 Oct 2006 08:33:17 -0000	1.9
  +++ hibernate-recommended-config.xml	30 Dec 2006 17:49:52 -0000	1.10
  @@ -17,7 +17,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -75,7 +75,7 @@
         <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
              cluster in order to find each other.
         -->
  -      <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
         <!--Uncomment next three statements to enable JGroups multiplexer.
   This configuration is dependent on the JGroups multiplexer being
  
  
  
  1.2       +164 -164  JBossCache/etc/META-INF/singleton-push-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: singleton-push-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/singleton-push-service.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- singleton-push-service.xml	29 Sep 2006 18:27:21 -0000	1.1
  +++ singleton-push-service.xml	30 Dec 2006 17:49:52 -0000	1.2
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.4       +3 -3      JBossCache/etc/META-INF/local-tx-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: local-tx-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/local-tx-service.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- local-tx-service.xml	23 Oct 2006 17:39:01 -0000	1.3
  +++ local-tx-service.xml	30 Dec 2006 17:49:52 -0000	1.4
  @@ -15,7 +15,7 @@
      <!-- Defines TreeCache configuration                                      -->
      <!-- ==================================================================== -->
   
  -   <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
             name="jboss.cache:service=TreeCache">
   
         <depends>jboss:service=Naming</depends>
  @@ -47,7 +47,7 @@
         <!-- Name of cluster. Needs to be the same for all clusters, in order
              to find each other
         -->
  -      <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
         <!-- JGroups protocol stack properties. Can also be a URL,
              e.g. file:/home/bela/default.xml
  
  
  
  1.8       +143 -143  JBossCache/etc/META-INF/replSync-eviction-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: replSync-eviction-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/replSync-eviction-service.xml,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- replSync-eviction-service.xml	21 Sep 2006 15:08:39 -0000	1.7
  +++ replSync-eviction-service.xml	30 Dec 2006 17:49:52 -0000	1.8
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -62,11 +62,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  
  1.6       +135 -135  JBossCache/etc/META-INF/interopPrevSync-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: interopPrevSync-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/META-INF/interopPrevSync-service.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- interopPrevSync-service.xml	21 Sep 2006 15:08:39 -0000	1.5
  +++ interopPrevSync-service.xml	30 Dec 2006 17:49:52 -0000	1.6
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -58,11 +58,11 @@
           <!-- Name of cluster. Needs to be the same for all TreeCache nodes in a
                cluster in order to find each other.
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
           
           <!--Uncomment next three statements to enable JGroups multiplexer.
  -              This configuration is dependent on the JGroups multiplexer being
  -              registered in an MBean server such as JBossAS.  -->
  +This configuration is dependent on the JGroups multiplexer being
  +registered in an MBean server such as JBossAS.  -->
           <!--
           <depends>jgroups.mux:name=Multiplexer</depends>
           <attribute name="MultiplexerService">jgroups.mux:name=Multiplexer</attribute>
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:53 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/api ...
Message-ID: <E1H0iLB-0008JJ-B4@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:53

  Modified:    tests/functional/org/jboss/cache/api      
                        SyncReplTxTest.java NodeAPITest.java
                        NodeReplicatedMoveTest.java CacheAPITest.java
                        NodeMoveAPITest.java SyncReplTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.3       +14 -17    JBossCache/tests/functional/org/jboss/cache/api/SyncReplTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/SyncReplTxTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- SyncReplTxTest.java	31 Oct 2006 06:57:28 -0000	1.2
  +++ SyncReplTxTest.java	30 Dec 2006 17:49:53 -0000	1.3
  @@ -9,24 +9,21 @@
   
   import junit.framework.TestCase;
   import org.jboss.cache.Cache;
  -import org.jboss.cache.Fqn;
  -import org.jboss.cache.Node;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.TreeCacheProxyImpl;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.InvocationContext;
  -import org.jboss.cache.transaction.DummyTransactionManager;
  +import org.jboss.cache.Node;
   import org.jboss.cache.config.Option;
  -import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.factories.DefaultCacheFactory;
  +import org.jboss.cache.misc.TestingUtil;
  +import org.jboss.cache.transaction.DummyTransactionManager;
   
  -import javax.transaction.Transaction;
  -import javax.transaction.SystemException;
  -import javax.transaction.NotSupportedException;
   import javax.transaction.HeuristicMixedException;
   import javax.transaction.HeuristicRollbackException;
  +import javax.transaction.NotSupportedException;
   import javax.transaction.RollbackException;
  -import java.util.Map;
  -import java.util.HashMap;
  +import javax.transaction.SystemException;
  +import javax.transaction.Transaction;
   
   /**
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  @@ -76,16 +73,16 @@
         Fqn f = Fqn.fromString("/test/data");
         String k = "key", v = "value";
   
  -      assertNull("Should be null", caches[0].getChild(f));
  -      assertNull("Should be null", caches[1].getChild(f));
  +      assertNull("Should be null", caches[0].getRoot().getChild(f));
  +      assertNull("Should be null", caches[1].getRoot().getChild(f));
   
  -      Node node = caches[0].addChild(f);
  +      Node node = caches[0].getRoot().addChild(f);
   
         assertNotNull("Should not be null", node);
   
         Transaction tx = beginTransaction();
         node.put(k, v);
  -      Transaction tx1 = ((CacheSPI)caches[0]).getInvocationContext().getTransaction();
  +      Transaction tx1 = caches[0].getInvocationContext().getTransaction();
         assertNotNull("Transaction can't be null ", tx1);
         tx.commit();
   
  @@ -98,13 +95,13 @@
      {
         for (Cache c : caches)
         {
  -         assertClusterSize(message, size, (TreeCacheProxyImpl) c);
  +         assertClusterSize(message, size, c);
         }
      }
   
  -   private void assertClusterSize(String message, int size, TreeCacheProxyImpl tcpi)
  +   private void assertClusterSize(String message, int size, Cache c)
      {
  -      assertEquals(message, size, tcpi.treeCache.getMembers().size());
  +      assertEquals(message, size, c.getMembers().size());
      }
   
      private void assertInvocationContextInitState()
  
  
  
  1.7       +6 -10     JBossCache/tests/functional/org/jboss/cache/api/NodeAPITest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeAPITest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeAPITest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- NodeAPITest.java	22 Dec 2006 03:53:30 -0000	1.6
  +++ NodeAPITest.java	30 Dec 2006 17:49:53 -0000	1.7
  @@ -1,11 +1,9 @@
   package org.jboss.cache.api;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.factories.DefaultCacheFactory;
   
   import javax.transaction.TransactionManager;
  @@ -21,8 +19,7 @@
   {
      private Node rootNode;
   
  -   private CacheSPI cache;
  -   private TreeCache treeCache;
  +   private CacheImpl cache;
   
      private TransactionManager tm;
   
  @@ -32,10 +29,9 @@
      protected void setUp()
      {
         // start a single cache instance
  -      cache = (CacheSPI) DefaultCacheFactory.createCache("META-INF/local-tx-service.xml");
  +      cache = (CacheImpl) DefaultCacheFactory.createCache("META-INF/local-tx-service.xml");
         rootNode = cache.getRoot();
         tm = cache.getTransactionManager();
  -      treeCache = ((TreeCacheProxyImpl) cache).treeCache;
      }
   
      protected void tearDown()
  @@ -96,13 +92,13 @@
         Node nodeC = nodeB.addChild(C);
   
         assertEquals(3, cache.getNumberOfNodes());
  -      assertEquals(4, treeCache.getNumberOfLocksHeld());
  +      assertEquals(4, cache.getNumberOfLocksHeld());
         tm.commit();
   
         tm.begin();
  -      assertEquals(0, treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         nodeC.put("key", "value");
  -      assertEquals(4, treeCache.getNumberOfLocksHeld());
  +      assertEquals(4, cache.getNumberOfLocksHeld());
         tm.commit();
      }
   
  
  
  
  1.6       +38 -38    JBossCache/tests/functional/org/jboss/cache/api/NodeReplicatedMoveTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeReplicatedMoveTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeReplicatedMoveTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- NodeReplicatedMoveTest.java	16 Nov 2006 13:43:22 -0000	1.5
  +++ NodeReplicatedMoveTest.java	30 Dec 2006 17:49:53 -0000	1.6
  @@ -62,20 +62,20 @@
         nodeA.put(k, vA);
         nodeB.put(k, vB);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(A).getChild(B).get(k));
   
  -      assertEquals(vA, cache[1].getChild(A).get(k));
  -      assertEquals(vB, cache[1].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[1].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[1].getRoot().getChild(A).getChild(B).get(k));
   
         // now move...
         nodeB.move(rootNode);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
   
  -      assertEquals(vA, cache[1].getChild(A).get(k));
  -      assertEquals(vB, cache[1].getChild(B).get(k));
  +      assertEquals(vA, cache[1].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[1].getRoot().getChild(B).get(k));
      }
   
      public void testInvalidations() throws Exception
  @@ -93,27 +93,27 @@
         nodeA.put(k, vA);
         nodeB.put(k, vB);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(A).getChild(B).get(k));
   
  -      assertNull(cache[1].getChild(A));
  -      assertNull(cache[1].getChild(B));
  +      assertNull(cache[1].getRoot().getChild(A));
  +      assertNull(cache[1].getRoot().getChild(B));
   
         // now move...
         nodeB.move(rootNode);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
   
  -      assertNull(cache[1].getChild(A));
  -      assertNull(cache[1].getChild(B));
  +      assertNull(cache[1].getRoot().getChild(A));
  +      assertNull(cache[1].getRoot().getChild(B));
   
         // now make sure a node exists on cache 2
  -      cache[1].addChild(A);
  +      cache[1].getRoot().addChild(A);
   
         try
         {
  -         cache[0].getChild(B).move(cache[0].getChild(A)); // should throw an NPE
  +         cache[0].getRoot().getChild(B).move(cache[0].getRoot().getChild(A)); // should throw an NPE
            fail("Expecting an exception");
         }
         catch (Exception e)
  @@ -130,25 +130,25 @@
         nodeA.put(k, vA);
         nodeB.put(k, vB);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(A).getChild(B).get(k));
   
  -      assertEquals(vA, cache[1].getChild(A).get(k));
  -      assertEquals(vB, cache[1].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[1].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[1].getRoot().getChild(A).getChild(B).get(k));
   
         // now move...
         tm.begin();
         nodeB.move(rootNode);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
   
         tm.commit();
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(B).get(k));
  -      assertEquals(vA, cache[1].getChild(A).get(k));
  -      assertEquals(vB, cache[1].getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
  +      assertEquals(vA, cache[1].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[1].getRoot().getChild(B).get(k));
   
      }
   
  @@ -160,24 +160,24 @@
         nodeA.put(k, vA);
         nodeB.put(k, vB);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(A).getChild(B).get(k));
  -      assertEquals(vA, cache[1].getChild(A).get(k));
  -      assertEquals(vB, cache[1].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[1].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[1].getRoot().getChild(A).getChild(B).get(k));
   
         // now move...
         tm.begin();
         nodeB.move(rootNode);
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
   
         tm.rollback();
   
  -      assertEquals(vA, cache[0].getChild(A).get(k));
  -      assertEquals(vB, cache[0].getChild(A).getChild(B).get(k));
  -      assertEquals(vA, cache[1].getChild(A).get(k));
  -      assertEquals(vB, cache[1].getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[0].getRoot().getChild(A).getChild(B).get(k));
  +      assertEquals(vA, cache[1].getRoot().getChild(A).get(k));
  +      assertEquals(vB, cache[1].getRoot().getChild(A).getChild(B).get(k));
      }
   
      public void testReplConcurrency()
  
  
  
  1.7       +33 -30    JBossCache/tests/functional/org/jboss/cache/api/CacheAPITest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheAPITest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/CacheAPITest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- CacheAPITest.java	20 Nov 2006 03:53:56 -0000	1.6
  +++ CacheAPITest.java	30 Dec 2006 17:49:53 -0000	1.7
  @@ -3,6 +3,7 @@
   import junit.framework.TestCase;
   import org.jboss.cache.AbstractCacheListener;
   import org.jboss.cache.Cache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheListener;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  @@ -96,7 +97,7 @@
   
         assertEquals(1, cache.getCacheListeners().size());
   
  -      cache.addChild(Fqn.fromString("/blah"));
  +      cache.getRoot().addChild(Fqn.fromString("/blah"));
   
         // test that the event was captured by the listener.
   
  @@ -175,6 +176,8 @@
   
         cache.put(fqn, data);
   
  +      System.out.println(((CacheImpl) cache).printDetails());
  +
         assertEquals(value, cache.get(fqn, key));
      }
   
  @@ -186,11 +189,11 @@
      {
         // this fqn is relative, but since it is from the root it may as well be absolute
         Fqn fqn = Fqn.fromString("/test/fqn");
  -      cache.addChild(fqn);
  -      assertTrue(cache.hasChild(fqn));
  +      cache.getRoot().addChild(fqn);
  +      assertTrue(cache.getRoot().hasChild(fqn));
   
         cache.removeNode(fqn);
  -      assertFalse(cache.hasChild(fqn));
  +      assertFalse(cache.getRoot().hasChild(fqn));
      }
   
      /**
  @@ -202,34 +205,34 @@
         Fqn two = Fqn.fromString("/one/two");
         Object key = "key", value = "value";
   
  -      cache.addChild(one).put(key, value);
  -      cache.addChild(two).put(key, value);
  +      cache.getRoot().addChild(one).put(key, value);
  +      cache.getRoot().addChild(two).put(key, value);
   
  -      assertTrue(cache.hasChild(one));
  -      assertFalse(cache.getChild(one).getData().isEmpty());
  -      assertTrue(cache.hasChild(two));
  -      assertFalse(cache.getChild(two).getData().isEmpty());
  +      assertTrue(cache.getRoot().hasChild(one));
  +      assertFalse(cache.getRoot().getChild(one).getData().isEmpty());
  +      assertTrue(cache.getRoot().hasChild(two));
  +      assertFalse(cache.getRoot().getChild(two).getData().isEmpty());
   
         // evict two
         cache.evict(two, false);
   
  -      assertTrue(cache.hasChild(one));
  -      assertTrue(cache.getChild(one).getKeys().contains(key));
  -      assertFalse(cache.hasChild(two));
  +      assertTrue(cache.getRoot().hasChild(one));
  +      assertTrue(cache.getRoot().getChild(one).getKeys().contains(key));
  +      assertFalse(cache.getRoot().hasChild(two));
   
         // now add 2 again...
  -      cache.addChild(two).put(key, value);
  +      cache.getRoot().addChild(two).put(key, value);
   
         // now evict one, NOT recursive
         cache.evict(one, false);
   
         // one will NOT be removed, just emptied.
  -      assertTrue(cache.hasChild(one));
  -      assertFalse(cache.getChild(one).getKeys().contains(key));
  +      assertTrue(cache.getRoot().hasChild(one));
  +      assertFalse(cache.getRoot().getChild(one).getKeys().contains(key));
   
         // two will be unaffected
  -      assertTrue(cache.hasChild(two));
  -      assertTrue(cache.getChild(two).getKeys().contains(key));
  +      assertTrue(cache.getRoot().hasChild(two));
  +      assertTrue(cache.getRoot().getChild(two).getKeys().contains(key));
      }
   
   
  @@ -242,29 +245,29 @@
         Fqn two = Fqn.fromString("/one/two");
         Object key = "key", value = "value";
   
  -      cache.addChild(one).put(key, value);
  -      cache.addChild(two).put(key, value);
  +      cache.getRoot().addChild(one).put(key, value);
  +      cache.getRoot().addChild(two).put(key, value);
   
  -      assertTrue(cache.hasChild(one));
  -      assertFalse(cache.getChild(one).getData().isEmpty());
  -      assertTrue(cache.hasChild(two));
  -      assertFalse(cache.getChild(two).getData().isEmpty());
  +      assertTrue(cache.getRoot().hasChild(one));
  +      assertFalse(cache.getRoot().getChild(one).getData().isEmpty());
  +      assertTrue(cache.getRoot().hasChild(two));
  +      assertFalse(cache.getRoot().getChild(two).getData().isEmpty());
   
         // evict two
         cache.evict(two, true);
   
  -      assertTrue(cache.hasChild(one));
  -      assertFalse(cache.getChild(one).getData().isEmpty());
  -      assertFalse(cache.hasChild(two));
  +      assertTrue(cache.getRoot().hasChild(one));
  +      assertFalse(cache.getRoot().getChild(one).getData().isEmpty());
  +      assertFalse(cache.getRoot().hasChild(two));
   
         // now add 2 again...
  -      cache.addChild(two).put(key, value);
  +      cache.getRoot().addChild(two).put(key, value);
   
         // now evict one, recursive
         cache.evict(one, true);
   
  -      assertFalse(cache.hasChild(one));
  -      assertFalse(cache.hasChild(two));
  +      assertFalse(cache.getRoot().hasChild(one));
  +      assertFalse(cache.getRoot().hasChild(two));
      }
   
   
  
  
  
  1.15      +20 -24    JBossCache/tests/functional/org/jboss/cache/api/NodeMoveAPITest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeMoveAPITest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeMoveAPITest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- NodeMoveAPITest.java	22 Dec 2006 03:53:30 -0000	1.14
  +++ NodeMoveAPITest.java	30 Dec 2006 17:49:53 -0000	1.15
  @@ -1,12 +1,10 @@
   package org.jboss.cache.api;
   
   import EDU.oswego.cs.dl.util.concurrent.Latch;
  -import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   import org.jboss.cache.NodeNotExistsException;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.loader.AbstractCacheLoaderTestBase;
  @@ -26,11 +24,10 @@
   {
   
      protected Node rootNode, nodeA, nodeB, nodeC, nodeD, nodeE;
  -   protected CacheSPI cache;
  +   protected CacheImpl cache;
      protected TransactionManager tm;
      protected static final Fqn A = Fqn.fromString("/a"), B = Fqn.fromString("/b"), C = Fqn.fromString("/c"), D = Fqn.fromString("/d"), E = Fqn.fromString("/e");
      protected Object k = "key", vA = "valueA", vB = "valueB", vC = "valueC", vD = "valueD", vE = "valueE";
  -   protected TreeCache treeCache;
   
      protected boolean optimistic = false;
   
  @@ -38,12 +35,11 @@
      protected void setUp() throws Exception
      {
         // start a single cache instance
  -      cache = (CacheSPI) DefaultCacheFactory.createCache("META-INF/local-tx-service.xml", false);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache("META-INF/local-tx-service.xml", false);
         cache.getConfiguration().setNodeLockingScheme(optimistic ? Configuration.NodeLockingScheme.OPTIMISTIC : Configuration.NodeLockingScheme.PESSIMISTIC);
         cache.start();
         rootNode = cache.getRoot();
         tm = cache.getTransactionManager();
  -      treeCache = ((TreeCacheProxyImpl) cache).treeCache;
      }
   
      protected void tearDown()
  @@ -84,7 +80,7 @@
         nodeC.move(nodeB);
         log.info("POST MOVE " + cache);
         log.info("HC " + nodeC + " " + System.identityHashCode(nodeC));
  -      Node x = cache.getChild(Fqn.fromString("b/c"));
  +      Node x = cache.getRoot().getChild(Fqn.fromString("b/c"));
         log.info("HC " + x + " " + System.identityHashCode(x));
         /*
            /a
  @@ -151,7 +147,7 @@
         nodeD = nodeC.getChild(D);
         nodeE = nodeD.getChild(E);
   
  -      System.out.println("Tree " + treeCache.printLockInfo());
  +      System.out.println("Tree " + cache.printLockInfo());
   
         assertTrue(rootNode.hasChild(A));
         assertTrue(rootNode.hasChild(B));
  @@ -313,31 +309,31 @@
   
         System.out.println("Loader" + loader);
   
  -      log.info("Current tree is " + treeCache.printLockInfo());
  +      log.info("Current tree is " + cache.printLockInfo());
   
         cache.evict(Fqn.ROOT, true);
   
  -      log.info("POST EVICT tree is " + treeCache.printLockInfo());
  +      log.info("POST EVICT tree is " + cache.printLockInfo());
   
         // move
         if (useTx) tm.begin();
         nodeC.move(nodeB);
         if (useTx) tm.commit();
   
  -      log.info("Post commit tree is " + treeCache.printDetails());
  +      log.info("Post commit tree is " + cache.printDetails());
   
         // after eviction, the node objects we hold are probably stale.
         nodeA = rootNode.getChild(A);
         nodeB = rootNode.getChild(B);
         nodeC = nodeB.getChild(C);
  -      log.info("Current tree is " + treeCache.printDetails());
  +      log.info("Current tree is " + cache.printDetails());
         log.info("nodeC get child B ");
         nodeD = nodeC.getChild(D);
  -      log.info("Current tree is " + treeCache.printDetails());
  +      log.info("Current tree is " + cache.printDetails());
         log.info("nodeD get child E ");
         nodeE = nodeD.getChild(E);
   
  -      log.info("Current tree is " + treeCache.printDetails());
  +      log.info("Current tree is " + cache.printDetails());
   
         Fqn old_C = new Fqn(C);
         Fqn old_D = new Fqn(old_C, D);
  @@ -387,20 +383,20 @@
         nodeB = nodeA.addChild(B);
         nodeD = nodeB.addChild(D);
         nodeC = rootNode.addChild(C);
  -      assertEquals(0, treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         tm.begin();
   
         nodeB.move(nodeC);
   //       nodeC should have a RL, nodeA should have a RL, nodeB should have a WL, nodeD should have a WL
   
  -      System.out.println("LOCKS: " + treeCache.printLockInfo());
  +      System.out.println("LOCKS: " + cache.printLockInfo());
   
  -      assertEquals("ROOT should have a RL, nodeC should have a RL, nodeA should have a RL, nodeB should have a WL, nodeD should have a WL", 5, treeCache.getNumberOfLocksHeld());
  +      assertEquals("ROOT should have a RL, nodeC should have a RL, nodeA should have a RL, nodeB should have a WL, nodeD should have a WL", 5, cache.getNumberOfLocksHeld());
   
   
         tm.commit();
   
  -      assertEquals(0, treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
      public void testLocks() throws Exception
  @@ -408,20 +404,20 @@
         nodeA = rootNode.addChild(A);
         nodeB = nodeA.addChild(B);
         nodeC = rootNode.addChild(C);
  -      assertEquals(0, treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         tm.begin();
   
         nodeB.move(nodeC);
   //       nodeC should have a RL, nodeA should have a RL, nodeB should have a WL
   
  -      System.out.println("LOCKS: " + treeCache.printLockInfo());
  +      System.out.println("LOCKS: " + cache.printLockInfo());
   
  -      assertEquals("ROOT should have a RL, nodeC should have a RL, nodeA should have a RL, nodeB should have a WL", 4, treeCache.getNumberOfLocksHeld());
  +      assertEquals("ROOT should have a RL, nodeC should have a RL, nodeA should have a RL, nodeB should have a WL", 4, cache.getNumberOfLocksHeld());
   
   
         tm.commit();
   
  -      assertEquals(0, treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
   
  @@ -507,7 +503,7 @@
            t.join();
         }
   
  -      assertEquals(0, treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         boolean found_x = false, found_x_again = false;
         for (Node n : NODES)
         {
  
  
  
  1.6       +8 -9      JBossCache/tests/functional/org/jboss/cache/api/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/SyncReplTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- SyncReplTest.java	31 Oct 2006 06:57:27 -0000	1.5
  +++ SyncReplTest.java	30 Dec 2006 17:49:53 -0000	1.6
  @@ -13,7 +13,6 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.misc.TestingUtil;
  @@ -62,10 +61,10 @@
         Fqn f = Fqn.fromString("/test/data");
         String k = "key", v = "value";
   
  -      assertNull("Should be null", caches[0].getChild(f));
  -      assertNull("Should be null", caches[1].getChild(f));
  +      assertNull("Should be null", caches[0].getRoot().getChild(f));
  +      assertNull("Should be null", caches[1].getRoot().getChild(f));
   
  -      Node node = caches[0].addChild(f);
  +      Node node = caches[0].getRoot().addChild(f);
   
         assertNotNull("Should not be null", node);
   
  @@ -103,7 +102,7 @@
         map.put("1", "1");
         map.put("2", "2");
         caches[0].getInvocationContext().getOptionOverrides().setSuppressLocking(true);
  -      caches[0].addChild(fqn).put(map);
  +      caches[0].getRoot().addChild(fqn).put(map);
         caches[0].getInvocationContext().getOptionOverrides().setSuppressLocking(true);
         assertEquals("Value should be set", "1", caches[0].get(fqn, "1"));
   
  @@ -111,7 +110,7 @@
         map.put("3", "3");
         map.put("4", "4");
         caches[0].getInvocationContext().getOptionOverrides().setSuppressLocking(true);
  -      caches[0].addChild(fqn1).put(map);
  +      caches[0].getRoot().addChild(fqn1).put(map);
   
         caches[0].getInvocationContext().getOptionOverrides().setSuppressLocking(true);
         assertEquals("Value should be set", "2", caches[0].get(fqn, "2"));
  @@ -122,13 +121,13 @@
      {
         for (Cache c : caches)
         {
  -         assertClusterSize(message, size, (TreeCacheProxyImpl) c);
  +         assertClusterSize(message, size, c);
         }
      }
   
  -   private void assertClusterSize(String message, int size, TreeCacheProxyImpl tcpi)
  +   private void assertClusterSize(String message, int size, Cache c)
      {
  -      assertEquals(message, size, tcpi.treeCache.getMembers().size());
  +      assertEquals(message, size, c.getMembers().size());
      }
   
      private void assertInvocationContextInitState()
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:53 -0500
Subject: [jboss-cvs] JBossCache/examples/PojoCache/non-annotated  ...
Message-ID: <E1H0iLB-0008JQ-Ex@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:53

  Modified:    examples/PojoCache/non-annotated  build.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.4       +2 -2      JBossCache/examples/PojoCache/non-annotated/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/examples/PojoCache/non-annotated/build.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- build.xml	24 Sep 2006 09:25:53 -0000	1.3
  +++ build.xml	30 Dec 2006 17:49:53 -0000	1.4
  @@ -23,7 +23,7 @@
      <property name="user.build" value="${build}"/>
      <property name="user.source" value="${source}"/>
   
  -   <import file="PojoCacheTasks.xml" />
  +   <import file="PojoCacheTasks.xml"/>
   
      <target name="help" description="help page">
         <echo message="build.sh &lt;command&gt; where command is:"/>
  @@ -75,7 +75,7 @@
         </java>
      </target>
   
  -   <target name="run.aop.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.aop.demo" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.aop.TreeCacheAopView" fork="yes">
            <jvmarg value="-Xmx128M"/>
            <classpath refid="lib.classpath"/>
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:53 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1H0iLB-0008KA-Ow@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:53

  Modified:    tests/functional/org/jboss/cache/transaction              
                        TransactionTest.java
                        IsolationLevelRepeatableReadTest.java
                        AbortionTest.java InvocationContextCleanupTest.java
                        ReplicatedTransactionDeadlockTest.java
                        IsolationLevelReadCommittedTest.java
                        IsolationLevelReadCommittedNodeCreationRollbackTest.java
                        PrepareTxTest.java ConcurrentTransactionalTest.java
                        SuspendTxTest.java
                        IsolationLevelSerializableTest.java
                        DeadlockTest.java ConcurrentBankTest.java
                        IsolationLevelNoneTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.20      +14 -15    JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- TransactionTest.java	14 Dec 2006 17:18:48 -0000	1.19
  +++ TransactionTest.java	30 Dec 2006 17:49:53 -0000	1.20
  @@ -12,13 +12,12 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
  -import org.jboss.cache.NodeImpl;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.lock.IdentityLock;
  +import org.jboss.cache.Node;
   import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.lock.NodeLock;
   
   import javax.naming.Context;
   import javax.naming.InitialContext;
  @@ -35,14 +34,14 @@
   import java.util.Set;
   
   /**
  - * Tests transactional access to a local TreeCache.
  + * Tests transactional access to a local CacheImpl.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: TransactionTest.java,v 1.19 2006/12/14 17:18:48 msurtani Exp $
  + * @version $Id: TransactionTest.java,v 1.20 2006/12/30 17:49:53 msurtani Exp $
    */
   public class TransactionTest extends TestCase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      UserTransaction tx = null;
      Properties p = null;
      String old_factory = null;
  @@ -68,7 +67,7 @@
         }
   
         tx = (UserTransaction) new InitialContext(p).lookup("UserTransaction");
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setClusterName("test");
         cache.getConfiguration().setInitialStateRetrievalTimeout(10000);
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -545,22 +544,22 @@
         cache.put("/a/b/c", null);
         cache.put("/a/b/c", null);
   
  -      NodeImpl n = cache.get("/a");
  -      IdentityLock lock = n.getLock();
  +      Node n = cache.get("/a");
  +      NodeLock lock = n.getNodeSPI().getLock();
         int num = lock.getReaderOwners().size();
         assertEquals(0, num);
         // make sure this is write locked.
         assertLocked(gtx, "/a", true);
   
         n = cache.get("/a/b");
  -      lock = n.getLock();
  +      lock = n.getNodeSPI().getLock();
         num = lock.getReaderOwners().size();
         assertEquals(0, num);
         // make sure this is write locked.
         assertLocked(gtx, "/a/b", true);
   
         n = cache.get("/a/b/c");
  -      lock = n.getLock();
  +      lock = n.getNodeSPI().getLock();
         num = lock.getReaderOwners().size();
         assertEquals(0, num);
         // make sure this is write locked.
  @@ -572,8 +571,8 @@
   
      private void assertLocked(Object owner, String fqn, boolean write_locked) throws Exception
      {
  -      NodeImpl n = (NodeImpl) cache.peek(Fqn.fromString(fqn));
  -      IdentityLock lock = n.getLock();
  +      Node n = cache.peek(Fqn.fromString(fqn));
  +      NodeLock lock = n.getNodeSPI().getLock();
         if (owner == null)
         {
            owner = Thread.currentThread();
  @@ -799,7 +798,7 @@
            cache.put("/bela/ban", m);
            tx.rollback();
   
  -         DataNode n = cache.get("/bela/ban");
  +         Node n = cache.get("/bela/ban");
            if (n.getData() == null) return;
            assertEquals("map should be empty", 0, n.getData().size());
         }
  
  
  
  1.3       +4 -4      JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelRepeatableReadTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IsolationLevelRepeatableReadTest.java	14 Dec 2006 14:38:59 -0000	1.2
  +++ IsolationLevelRepeatableReadTest.java	30 Dec 2006 17:49:53 -0000	1.3
  @@ -5,9 +5,9 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
   
  @@ -19,13 +19,13 @@
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  - * @version $Id: IsolationLevelRepeatableReadTest.java,v 1.2 2006/12/14 14:38:59 msurtani Exp $
  + * @version $Id: IsolationLevelRepeatableReadTest.java,v 1.3 2006/12/30 17:49:53 msurtani Exp $
    */
   
   public class IsolationLevelRepeatableReadTest extends TestCase
   {
   
  -   private TreeCache cache = null;
  +   private CacheImpl cache = null;
      private final Fqn FQN = Fqn.fromString("/a");
      private final String KEY = "key";
      private final String VALUE = "value";
  @@ -40,7 +40,7 @@
         writerFailed = false;
         writerError = null;
   
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("LOCAL");
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache.getConfiguration().setTransactionManagerLookupClass(DummyTransactionManagerLookup.class.getName());
  
  
  
  1.5       +2 -2      JBossCache/tests/functional/org/jboss/cache/transaction/AbortionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbortionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/AbortionTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- AbortionTest.java	6 Sep 2006 15:31:00 -0000	1.4
  +++ AbortionTest.java	30 Dec 2006 17:49:53 -0000	1.5
  @@ -7,7 +7,7 @@
   package org.jboss.cache.transaction;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.interceptors.OrderedSynchronizationHandler;
   import org.jboss.cache.misc.TestingUtil;
   import org.jgroups.JChannel;
  @@ -206,7 +206,7 @@
      }
   
   
  -   public static class MyTC extends TreeCache
  +   public static class MyTC extends CacheImpl
      {
         JChannel myChannel;
         RpcDispatcher myDispatcher;
  
  
  
  1.5       +7 -7      JBossCache/tests/functional/org/jboss/cache/transaction/InvocationContextCleanupTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvocationContextCleanupTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/InvocationContextCleanupTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- InvocationContextCleanupTest.java	6 Sep 2006 15:31:00 -0000	1.4
  +++ InvocationContextCleanupTest.java	30 Dec 2006 17:49:53 -0000	1.5
  @@ -7,7 +7,7 @@
   package org.jboss.cache.transaction;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.interceptors.OrderedSynchronizationHandler;
   import org.jboss.cache.misc.TestingUtil;
  @@ -24,11 +24,11 @@
    */
   public class InvocationContextCleanupTest extends TestCase
   {
  -   private TreeCache[] caches;
  +   private CacheImpl[] caches;
   
  -   private TreeCache createCache(boolean optimistic) throws Exception
  +   private CacheImpl createCache(boolean optimistic) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         if (optimistic) cache.getConfiguration().setNodeLockingScheme("OPTIMISTIC");
         cache.getConfiguration().setClusterName("InvocationContextCleanupTest");
  @@ -61,7 +61,7 @@
   
      private void test2CachesSync(boolean optimistic) throws Exception
      {
  -      caches = new TreeCache[2];
  +      caches = new CacheImpl[2];
         caches[0] = createCache(optimistic);
         caches[1] = createCache(optimistic);
   
  @@ -91,10 +91,10 @@
   
      public static class DummySynchronization implements Synchronization
      {
  -      private TreeCache cache;
  +      private CacheImpl cache;
         private TransactionManager mgr;
   
  -      public DummySynchronization(TreeCache cache, TransactionManager mgr)
  +      public DummySynchronization(CacheImpl cache, TransactionManager mgr)
         {
            this.cache = cache;
            this.mgr = mgr;
  
  
  
  1.6       +7 -7      JBossCache/tests/functional/org/jboss/cache/transaction/ReplicatedTransactionDeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedTransactionDeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/ReplicatedTransactionDeadlockTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ReplicatedTransactionDeadlockTest.java	12 Sep 2006 11:49:00 -0000	1.5
  +++ ReplicatedTransactionDeadlockTest.java	30 Dec 2006 17:49:53 -0000	1.6
  @@ -5,8 +5,8 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   
  @@ -57,7 +57,7 @@
    *
    * @author Marian Nikolov
    * @author $Author: msurtani $
  - * @version $Date: 2006/09/12 11:49:00 $
  + * @version $Date: 2006/12/30 17:49:53 $
    */
   public class ReplicatedTransactionDeadlockTest extends TestCase
   {
  @@ -93,11 +93,11 @@
      /**
       * The source cache where we put modifications.
       */
  -   private TreeCache srcCache = null;
  +   private CacheImpl srcCache = null;
      /**
       * The target cache where we replicate modifications.
       */
  -   private TreeCache dstCache = null;
  +   private CacheImpl dstCache = null;
   
      private Log log = LogFactory.getLog(ReplicatedTransactionDeadlockTest.class);
   
  @@ -129,7 +129,7 @@
         System.setProperty(Context.INITIAL_CONTEXT_FACTORY, CONTEXT_FACTORY);
         DummyTransactionManager.getInstance();
         // setup and start the source cache
  -      srcCache = new TreeCache();
  +      srcCache = new CacheImpl();
         srcCache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
         srcCache.getConfiguration().setTransactionManagerLookupClass(
                 "org.jboss.cache.DummyTransactionManagerLookup");
  @@ -140,7 +140,7 @@
         srcCache.create();
         srcCache.start();
         // setup and start the destination cache
  -      dstCache = new TreeCache();
  +      dstCache = new CacheImpl();
         dstCache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
         dstCache.getConfiguration().setTransactionManagerLookupClass(
                 "org.jboss.cache.DummyTransactionManagerLookup");
  @@ -227,7 +227,7 @@
       *
       * @author Marian Nikolov
       * @author $Author: msurtani $
  -    * @version $Date: 2006/09/12 11:49:00 $
  +    * @version $Date: 2006/12/30 17:49:53 $
       */
      private class Worker extends Thread
      {
  
  
  
  1.12      +3 -2      JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelReadCommittedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- IsolationLevelReadCommittedTest.java	14 Dec 2006 17:52:29 -0000	1.11
  +++ IsolationLevelReadCommittedTest.java	30 Dec 2006 17:49:53 -0000	1.12
  @@ -7,6 +7,7 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.jboss.cache.Cache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.config.Configuration;
  @@ -24,7 +25,7 @@
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  - * @version $Id: IsolationLevelReadCommittedTest.java,v 1.11 2006/12/14 17:52:29 msurtani Exp $
  + * @version $Id: IsolationLevelReadCommittedTest.java,v 1.12 2006/12/30 17:49:53 msurtani Exp $
    */
   
   public class IsolationLevelReadCommittedTest extends TestCase
  @@ -297,7 +298,7 @@
         // wait for the writer to finish
         writerDone.acquire();
   
  -      assertNull("Node was removed", cache.get(FQN));
  +      assertNull("Node was removed", ((CacheImpl) cache).get(FQN));
   
         // If any assertion failed, throw on the AssertionFailedError
   
  
  
  
  1.4       +4 -4      JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedNodeCreationRollbackTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelReadCommittedNodeCreationRollbackTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedNodeCreationRollbackTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- IsolationLevelReadCommittedNodeCreationRollbackTest.java	6 Sep 2006 15:31:00 -0000	1.3
  +++ IsolationLevelReadCommittedNodeCreationRollbackTest.java	30 Dec 2006 17:49:53 -0000	1.4
  @@ -11,9 +11,9 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
  @@ -26,13 +26,13 @@
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  - * @version $Id: IsolationLevelReadCommittedNodeCreationRollbackTest.java,v 1.3 2006/09/06 15:31:00 msurtani Exp $
  + * @version $Id: IsolationLevelReadCommittedNodeCreationRollbackTest.java,v 1.4 2006/12/30 17:49:53 msurtani Exp $
    */
   
   public class IsolationLevelReadCommittedNodeCreationRollbackTest extends TestCase
   {
   
  -   private TreeCache cache = null;
  +   private CacheImpl cache = null;
      private final Fqn FQN = Fqn.fromString("/a/b/c");
      private final String KEY = "key";
      private final String VALUE = "value";
  @@ -52,7 +52,7 @@
         writerError = null;
         readerError = null;
   
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setIsolationLevel(IsolationLevel.READ_COMMITTED);
         cache.getConfiguration().setTransactionManagerLookupClass(DummyTransactionManagerLookup.class.getName());
  
  
  
  1.5       +3 -3      JBossCache/tests/functional/org/jboss/cache/transaction/PrepareTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PrepareTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/PrepareTxTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- PrepareTxTest.java	14 Dec 2006 17:52:29 -0000	1.4
  +++ PrepareTxTest.java	30 Dec 2006 17:49:53 -0000	1.5
  @@ -4,8 +4,8 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   
   import javax.transaction.NotSupportedException;
   import javax.transaction.Synchronization;
  @@ -19,12 +19,12 @@
    */
   public class PrepareTxTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
   
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("local");
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.create();
  
  
  
  1.6       +5 -5      JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentTransactionalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentTransactionalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentTransactionalTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ConcurrentTransactionalTest.java	6 Sep 2006 15:31:00 -0000	1.5
  +++ ConcurrentTransactionalTest.java	30 Dec 2006 17:49:53 -0000	1.6
  @@ -12,7 +12,7 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
  @@ -29,14 +29,14 @@
   import java.util.Set;
   
   /**
  - * Unit test for local TreeCache. Use locking and multiple threads to test
  + * Unit test for local CacheImpl. Use locking and multiple threads to test
    * concurrent access to the tree.
    *
  - * @version $Id: ConcurrentTransactionalTest.java,v 1.5 2006/09/06 15:31:00 msurtani Exp $
  + * @version $Id: ConcurrentTransactionalTest.java,v 1.6 2006/12/30 17:49:53 msurtani Exp $
    */
   public class ConcurrentTransactionalTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      private Log logger_ = LogFactory.getLog(ConcurrentTransactionalTest.class);
      static Throwable thread_ex = null;
      final int NUM = 10000;
  @@ -64,7 +64,7 @@
   
      private void createCache(IsolationLevel level) throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-service.xml"));
   
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
  
  
  
  1.4       +3 -3      JBossCache/tests/functional/org/jboss/cache/transaction/SuspendTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuspendTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/SuspendTxTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SuspendTxTest.java	14 Dec 2006 17:52:29 -0000	1.3
  +++ SuspendTxTest.java	30 Dec 2006 17:49:53 -0000	1.4
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import javax.transaction.Transaction;
   import javax.transaction.TransactionManager;
  @@ -17,13 +17,13 @@
    */
   public class SuspendTxTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      TransactionManager mgr;
   
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("local");
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.start();
  
  
  
  1.3       +22 -25    JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelSerializableTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelSerializableTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelSerializableTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- IsolationLevelSerializableTest.java	22 Nov 2006 04:55:44 -0000	1.2
  +++ IsolationLevelSerializableTest.java	30 Dec 2006 17:49:53 -0000	1.3
  @@ -1,17 +1,13 @@
   package org.jboss.cache.transaction;
   
   
  -
  -import javax.transaction.NotSupportedException;
  -import javax.transaction.SystemException;
  -import javax.transaction.Transaction;
  -
  +import EDU.oswego.cs.dl.util.concurrent.Latch;
   import junit.framework.AssertionFailedError;
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -
   import org.jboss.cache.Cache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.config.Configuration;
  @@ -20,16 +16,16 @@
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
   
  -import EDU.oswego.cs.dl.util.concurrent.Latch;
  -
  +import javax.transaction.NotSupportedException;
  +import javax.transaction.SystemException;
  +import javax.transaction.Transaction;
   
   
   /**
    * Tests READ_COMMITED isolation level.
    *
    * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  - *
  - * @version $Id: IsolationLevelSerializableTest.java,v 1.2 2006/11/22 04:55:44 bstansberry Exp $
  + * @version $Id: IsolationLevelSerializableTest.java,v 1.3 2006/12/30 17:49:53 msurtani Exp $
    */
   
   public class IsolationLevelSerializableTest extends TestCase
  @@ -66,7 +62,7 @@
   
         cache.stop();
         cache.destroy();
  -      cache=null;
  +      cache = null;
      }
      
      /**
  @@ -109,7 +105,7 @@
               {
                  writerError = e;
               }
  -            catch(Throwable t)
  +            catch (Throwable t)
               {
                  t.printStackTrace();
                  writerFailed = true;
  @@ -147,7 +143,7 @@
         // wait for the writer to finish
         writerDone.acquire();
   
  -      assertNull("Node was removed", cache.get(FQN));
  +      assertNull("Node was removed", ((CacheImpl) cache).get(FQN));
   
         // If any assertion failed, throw on the AssertionFailedError
         
  @@ -165,12 +161,13 @@
   
      private Transaction startTransaction() throws SystemException, NotSupportedException
      {
  -      DummyTransactionManager mgr=DummyTransactionManager.getInstance();
  +      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
   
  -   public static Test suite() {
  +   public static Test suite()
  +   {
   
         return new TestSuite(IsolationLevelSerializableTest.class);
   
  
  
  
  1.8       +5 -5      JBossCache/tests/functional/org/jboss/cache/transaction/DeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/DeadlockTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- DeadlockTest.java	14 Dec 2006 17:52:29 -0000	1.7
  +++ DeadlockTest.java	30 Dec 2006 17:49:53 -0000	1.8
  @@ -14,8 +14,8 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
  @@ -27,14 +27,14 @@
   import javax.transaction.Transaction;
   
   /**
  - * Tests transactional access to a local TreeCache, with concurrent (deadlock-prone) access.
  + * Tests transactional access to a local CacheImpl, with concurrent (deadlock-prone) access.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: DeadlockTest.java,v 1.7 2006/12/14 17:52:29 msurtani Exp $
  + * @version $Id: DeadlockTest.java,v 1.8 2006/12/30 17:49:53 msurtani Exp $
    */
   public class DeadlockTest extends TestCase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      Exception thread_ex;
   
      final Fqn NODE = Fqn.fromString("/a/b/c");
  @@ -53,7 +53,7 @@
      {
         super.setUp();
         DummyTransactionManager.getInstance();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setInitialStateRetrievalTimeout(10000);
         cache.getConfiguration().setClusterName("test");
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
  
  
  
  1.7       +7 -7      JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentBankTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentBankTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentBankTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ConcurrentBankTest.java	6 Sep 2006 15:31:00 -0000	1.6
  +++ ConcurrentBankTest.java	30 Dec 2006 17:49:53 -0000	1.7
  @@ -6,7 +6,7 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
  @@ -21,16 +21,16 @@
   import java.util.Set;
   
   /**
  - * Unit test for local TreeCache with concurrent transactions.
  + * Unit test for local CacheImpl with concurrent transactions.
    * Uses locking and multiple threads to test concurrent r/w access to the tree.
    *
    * @author <a href="mailto:spohl at users.sourceforge.net">Stefan Pohl</a>
    * @author Ben Wang
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class ConcurrentBankTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      private static Log logger_ = LogFactory.getLog(ConcurrentBankTest.class);
      static Properties p = null;
      String old_factory = null;
  @@ -64,7 +64,7 @@
            p.put(Context.INITIAL_CONTEXT_FACTORY, "org.jboss.cache.transaction.DummyContextFactory");
         }
   
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
   
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-lru-eviction-service.xml"));
   
  @@ -148,9 +148,9 @@
   
      class Teller extends Thread
      {
  -      TreeCache cache;
  +      CacheImpl cache;
   
  -      public Teller(String str, TreeCache cache)
  +      public Teller(String str, CacheImpl cache)
         {
            super(str);
            this.cache = cache;
  
  
  
  1.6       +6 -6      JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IsolationLevelNoneTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- IsolationLevelNoneTest.java	14 Dec 2006 17:52:29 -0000	1.5
  +++ IsolationLevelNoneTest.java	30 Dec 2006 17:49:53 -0000	1.6
  @@ -3,9 +3,9 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   
  @@ -17,11 +17,11 @@
    * Tests whether modifications within callbacks (TreeCacheListener) are handled correctly
    *
    * @author Bela Ban
  - * @version $Id: IsolationLevelNoneTest.java,v 1.5 2006/12/14 17:52:29 msurtani Exp $
  + * @version $Id: IsolationLevelNoneTest.java,v 1.6 2006/12/30 17:49:53 msurtani Exp $
    */
   public class IsolationLevelNoneTest extends TestCase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      final Fqn FQN = Fqn.fromString("/a/b/c");
      final String KEY = "key";
      final String VALUE = "value";
  @@ -47,7 +47,7 @@
   
      public void testWithoutTransactions() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setIsolationLevel(IsolationLevel.NONE);
         cache.start();
  @@ -61,7 +61,7 @@
   
      public void testWithTransactions() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setIsolationLevel(IsolationLevel.NONE);
         cache.setTransactionManagerLookup(new DummyTransactionManagerLookup());
  @@ -79,7 +79,7 @@
   
      public void testWithTransactionsRepeatableRead() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache.setTransactionManagerLookup(new DummyTransactionManagerLookup());
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:53 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:53 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/collection    ...
Message-ID: <E1H0iLB-0008KN-Sy@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:53

  Modified:    src-50/org/jboss/cache/pojo/collection   
                        CachedListImpl.java CachedSetImpl.java
                        CachedMapImpl.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.13      +39 -30    JBossCache/src-50/org/jboss/cache/pojo/collection/CachedListImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CachedListImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/collection/CachedListImpl.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- CachedListImpl.java	9 Nov 2006 16:53:28 -0000	1.12
  +++ CachedListImpl.java	30 Dec 2006 17:49:53 -0000	1.13
  @@ -6,28 +6,25 @@
    */
   package org.jboss.cache.pojo.collection;
   
  -import org.jboss.cache.DataNode;
  -import org.jboss.cache.Fqn;
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.pojo.util.AopUtil;
  -import org.jboss.cache.pojo.util.Null;
  -import org.jboss.cache.pojo.util.CacheApiUtil;
  -import org.jboss.cache.pojo.PojoTreeCache;
   import org.jboss.cache.pojo.impl.PojoCacheImpl;
   import org.jboss.cache.pojo.interceptors.dynamic.AbstractCollectionInterceptor;
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.pojo.util.AopUtil;
  +import org.jboss.cache.pojo.util.CacheApiUtil;
  +import org.jboss.cache.pojo.util.Null;
   
  +import java.io.ObjectStreamException;
  +import java.util.ArrayList;
  +import java.util.Collection;
   import java.util.Iterator;
   import java.util.LinkedList;
   import java.util.List;
   import java.util.ListIterator;
  -import java.util.Map;
   import java.util.NoSuchElementException;
  -import java.util.Collection;
  -import java.util.ArrayList;
  -import java.io.ObjectStreamException;
   
   /**
    * List implementation that uses cache as a backend store.
  @@ -45,7 +42,7 @@
      public CachedListImpl(PojoCacheImpl cache, AbstractCollectionInterceptor interceptor)
      {
         pCache_ = cache;
  -      cache_ = (CacheSPI)pCache_.getCache();
  +      cache_ = (CacheSPI) pCache_.getCache();
         interceptor_ = interceptor;
      }
   
  @@ -60,14 +57,15 @@
         try
         {
            return CacheApiUtil.getDataNode(cache_, getFqn());
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
      }
   
  -   /** Serialize a normal ArrayList
  -    *
  +   /**
  +    * Serialize a normal ArrayList
       */
      private Object XwriteReplace()  throws ObjectStreamException
      {
  @@ -85,7 +83,8 @@
         try
         {
            return Null.toNullValue(pCache_.getObject(AopUtil.constructFqn(getFqn(), IntegerCache.toString(index))));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -124,7 +123,8 @@
               checkIndex(); // Since index can be size().
            return Null.toNullValue(pCache_.attach(AopUtil.constructFqn(getFqn(),
                    IntegerCache.toString(index)), Null.toNullObject(element)));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -142,7 +142,8 @@
               pCache_.attach(AopUtil.constructFqn(getFqn(), IntegerCache.toString(i)), obj);
            }
            pCache_.attach(AopUtil.constructFqn(getFqn(), IntegerCache.toString(index)), Null.toNullObject(element));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -158,7 +159,8 @@
               if (null == get(i))
                  return i;
            }
  -      } else
  +      }
  +      else
         {
            for (int i = 0; i < size; i++)
            {
  @@ -178,7 +180,8 @@
               if (null == get(i))
                  return i;
            }
  -      } else
  +      }
  +      else
         {
            for (int i = size() - 1; i >= 0; i--)
            {
  @@ -207,7 +210,8 @@
               pCache_.attach(AopUtil.constructFqn(getFqn(), IntegerCache.toString(i)), obj);
            }
            return result;
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -241,7 +245,8 @@
               try
               {
                  return Null.toNullValue(pCache_.getObject(AopUtil.constructFqn(getFqn(), IntegerCache.toString(++current))));
  -            } catch (Exception e)
  +            }
  +            catch (Exception e)
               {
                  throw new RuntimeException(e);
               }
  @@ -265,14 +270,16 @@
                        last = pCache_.detach(AopUtil.constructFqn(getFqn(), IntegerCache.toString(i)));
                        pCache_.attach(AopUtil.constructFqn(getFqn(), IntegerCache.toString(i - 1)), last);
                     }
  -               } else
  +               }
  +               else
                  { // we are the last index.
                     // Need to move back the cursor.
                     pCache_.detach(AopUtil.constructFqn(getFqn(), IntegerCache.toString(current)));
                  }
                  current--;
                  size--;
  -            } catch (Exception e)
  +            }
  +            catch (Exception e)
               {
                  throw new RuntimeException(e);
               }
  @@ -344,7 +351,8 @@
                  list_.remove(previousIndex());
                  index--;
               }
  -         } catch (Exception e)
  +         }
  +         catch (Exception e)
            {
               throw new RuntimeException(e);
            }
  @@ -442,7 +450,7 @@
               private Iterator initializeIter()
               {
                  Iterator iter = backStore_.iterator();
  -               for (int looper = 0; looper < fromIndex_; looper ++)
  +               for (int looper = 0; looper < fromIndex_; looper++)
                     if (iter.hasNext())      // skip past to where we need to start from
                        iter.next();
                  return iter;
  @@ -468,7 +476,8 @@
                  try
                  {
                     return iter_.next();
  -               } catch (Exception e)
  +               }
  +               catch (Exception e)
                  {
                     throw new RuntimeException(e);
                  }
  
  
  
  1.13      +82 -86    JBossCache/src-50/org/jboss/cache/pojo/collection/CachedSetImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CachedSetImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/collection/CachedSetImpl.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- CachedSetImpl.java	8 Nov 2006 22:20:15 -0000	1.12
  +++ CachedSetImpl.java	30 Dec 2006 17:49:53 -0000	1.13
  @@ -7,25 +7,20 @@
   package org.jboss.cache.pojo.collection;
   
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.pojo.util.AopUtil;
  -import org.jboss.cache.pojo.util.Null;
  -import org.jboss.cache.pojo.util.CacheApiUtil;
  -import org.jboss.cache.pojo.PojoTreeCache;
   import org.jboss.cache.pojo.annotation.Reentrant;
   import org.jboss.cache.pojo.impl.PojoCacheImpl;
   import org.jboss.cache.pojo.interceptors.dynamic.AbstractCollectionInterceptor;
  +import org.jboss.cache.pojo.util.AopUtil;
  +import org.jboss.cache.pojo.util.CacheApiUtil;
  +import org.jboss.cache.pojo.util.Null;
   
   import java.util.AbstractSet;
   import java.util.Collection;
   import java.util.Collections;
   import java.util.Iterator;
  -import java.util.Map;
  -import java.util.Set;
  -import java.util.ArrayList;
   
   /**
    * Set implementation that uses a cache as an underlying backend store.
  @@ -50,7 +45,7 @@
      public CachedSetImpl(PojoCacheImpl cache, AbstractCollectionInterceptor interceptor)
      {
         pCache_ = cache;
  -      this.cache_ = (CacheSPI)pCache_.getCache();
  +      this.cache_ = (CacheSPI) pCache_.getCache();
         this.interceptor_ = interceptor;
      }
   
  @@ -182,7 +177,8 @@
   	* TODO should be able to use java.lang.Long, but some CacheLoader don't
   	* support non-String keys
   	*/
  -   private String toLong(long hashCode, long count) {
  +   private String toLong(long hashCode, long count)
  +   {
   	  long key = (hashCode & 0xFFFFL) | (count << 32);
   	  return Long.toHexString(key);
      }
  
  
  
  1.15      +40 -29    JBossCache/src-50/org/jboss/cache/pojo/collection/CachedMapImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CachedMapImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/collection/CachedMapImpl.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- CachedMapImpl.java	17 Sep 2006 07:50:31 -0000	1.14
  +++ CachedMapImpl.java	30 Dec 2006 17:49:53 -0000	1.15
  @@ -6,18 +6,19 @@
    */
   package org.jboss.cache.pojo.collection;
   
  +import org.jboss.aop.Advised;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.pojo.util.Null;
  -import org.jboss.cache.pojo.util.CacheApiUtil;
   import org.jboss.cache.pojo.annotation.Reentrant;
   import org.jboss.cache.pojo.impl.PojoCacheImpl;
   import org.jboss.cache.pojo.interceptors.dynamic.AbstractCollectionInterceptor;
  -import org.jboss.aop.Advised;
  +import org.jboss.cache.pojo.util.CacheApiUtil;
  +import org.jboss.cache.pojo.util.Null;
   
  +import java.io.NotSerializableException;
  +import java.io.Serializable;
   import java.util.AbstractCollection;
   import java.util.AbstractSet;
   import java.util.ArrayList;
  @@ -26,8 +27,6 @@
   import java.util.Iterator;
   import java.util.Map;
   import java.util.Set;
  -import java.io.Serializable;
  -import java.io.NotSerializableException;
   
   /**
    * Map that uses cache as a backend store.
  @@ -48,14 +47,15 @@
      public CachedMapImpl(PojoCacheImpl pCache, AbstractCollectionInterceptor interceptor)
      {
         pCache_ = pCache;
  -      cache_ = (CacheSPI)pCache_.getCache();
  +      cache_ = (CacheSPI) pCache_.getCache();
         interceptor_ = interceptor;
   
      }
   
      private static Fqn constructFqn(Fqn baseFqn, Object relative) throws NotSerializableException
      {
  -      if(! (relative instanceof Serializable ) && !(relative instanceof Advised)) {
  +      if (!(relative instanceof Serializable) && !(relative instanceof Advised))
  +      {
            throw new NotSerializableException(relative.getClass().getName());
         }
   
  @@ -75,7 +75,8 @@
         try
         {
            return CacheApiUtil.getDataNode(cache_, getFqn());
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -86,7 +87,8 @@
         try
         {
            return Null.toNullValue(pCache_.getObject(constructFqn(getFqn(), Null.toNullKeyObject(key))));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -97,7 +99,8 @@
         try
         {
            return pCache_.attach(constructFqn(getFqn(), Null.toNullKeyObject(key)), Null.toNullObject(value));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -117,7 +120,8 @@
         try
         {
            return pCache_.detach(constructFqn(getFqn(), Null.toNullKeyObject(key)));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            throw new RuntimeException(e);
         }
  @@ -153,10 +157,10 @@
      public boolean containsKey(Object object)
      {
         Collection<Node> children = getNode().getChildren();
  -      if(children == null) return false;
  -      for(Node n: children)
  +      if (children == null) return false;
  +      for (Node n : children)
         {
  -         if(n.getFqn().getLast().equals(Null.toNullKeyObject(object))) return true;
  +         if (n.getFqn().getLast().equals(Null.toNullKeyObject(object))) return true;
         }
   
         return false;
  @@ -198,7 +202,7 @@
   
                  public Object next()
                  {
  -                  return new Entry(lastKey = ((Node)i.next()).getFqn().getLast());
  +                  return new Entry(lastKey = ((Node) i.next()).getFqn().getLast());
                  }
   
                  public void remove()
  @@ -249,7 +253,7 @@
                  {
                     try
                     {
  -                     Fqn f = ((Node)i.next()).getFqn();
  +                     Fqn f = ((Node) i.next()).getFqn();
                        lastKey = f.getLast();
                        return Null.toNullValue(pCache_.getObject(f));
                     }
  @@ -303,7 +307,7 @@
   
                  public Object next()
                  {
  -                  lastKey = ((Node)i.next()).getFqn().getLast();
  +                  lastKey = ((Node) i.next()).getFqn().getLast();
                     return Null.toNullKeyValue(lastKey);
   
                  }
  @@ -324,7 +328,8 @@
      public int hashCode()
      {
         int result = 0;
  -      for (Iterator i = entrySet().iterator(); i.hasNext();) {
  +      for (Iterator i = entrySet().iterator(); i.hasNext();)
  +      {
            result += i.next().hashCode();
         }
         return result;
  @@ -339,17 +344,21 @@
         Map map = (Map) object;
         if (size() != map.size())
            return false;
  -      for (Iterator i = entrySet().iterator(); i.hasNext();) {
  +      for (Iterator i = entrySet().iterator(); i.hasNext();)
  +      {
            Entry entry = (Entry) i.next();
            Object value = entry.getValue();
            Object key = entry.getKey();
  -         if (value == null) {
  -            if(! (map.get(key) == null && map.containsKey(key))) {
  +         if (value == null)
  +         {
  +            if (!(map.get(key) == null && map.containsKey(key)))
  +            {
                  return false;
               }
            }
  -         else {
  -            if (! value.equals(map.get(key)))
  +         else
  +         {
  +            if (!value.equals(map.get(key)))
                   return false;
            }
         }
  @@ -390,7 +399,8 @@
            try
            {
               return Null.toNullValue(pCache_.getObject(constructFqn(getFqn(), key)));
  -         } catch (Exception e)
  +         }
  +         catch (Exception e)
            {
               throw new RuntimeException(e);
            }
  @@ -401,7 +411,8 @@
            try
            {
               return pCache_.attach(constructFqn(getFqn(), key), Null.toNullObject(value));
  -         } catch (Exception e)
  +         }
  +         catch (Exception e)
            {
               throw new RuntimeException(e);
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:54 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/options ...
Message-ID: <E1H0iLC-0008LT-Bv@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:54

  Modified:    tests/functional/org/jboss/cache/options     
                        CacheModeLocalSimpleTest.java
                        SuppressLockingTest.java ExplicitVersionsTest.java
                        ExplicitVersionsReplTest.java FailSilentlyTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +4 -4      JBossCache/tests/functional/org/jboss/cache/options/CacheModeLocalSimpleTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheModeLocalSimpleTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/CacheModeLocalSimpleTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- CacheModeLocalSimpleTest.java	7 Sep 2006 15:42:16 -0000	1.5
  +++ CacheModeLocalSimpleTest.java	30 Dec 2006 17:49:54 -0000	1.6
  @@ -7,8 +7,8 @@
   package org.jboss.cache.options;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.Option;
   
  @@ -19,18 +19,18 @@
    */
   public class CacheModeLocalSimpleTest extends TestCase
   {
  -   private TreeCache cache1, cache2;
  +   private CacheImpl cache1, cache2;
      private Option cacheModeLocal;
   
      public void setUp() throws Exception
      {
  -      cache1 = new TreeCache();
  +      cache1 = new CacheImpl();
         Configuration c = new Configuration();
         cache1.setConfiguration(c);
         c.setCacheMode("REPL_SYNC");
         c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
   
  -      cache2 = new TreeCache();
  +      cache2 = new CacheImpl();
         c = new Configuration();
         cache2.setConfiguration(c);
         c.setCacheMode("REPL_SYNC");
  
  
  
  1.9       +26 -26    JBossCache/tests/functional/org/jboss/cache/options/SuppressLockingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SuppressLockingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/SuppressLockingTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- SuppressLockingTest.java	15 Dec 2006 15:28:37 -0000	1.8
  +++ SuppressLockingTest.java	30 Dec 2006 17:49:54 -0000	1.9
  @@ -7,9 +7,9 @@
   package org.jboss.cache.options;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.DefaultCacheFactory;
   
  @@ -27,7 +27,7 @@
      private Fqn fqn = Fqn.fromString("/blah");
      private Fqn fqn1 = Fqn.fromString("/blah/1");
   
  -   private TreeCacheProxyImpl cache;
  +   private CacheImpl cache;
   
      private TransactionManager m;
   
  @@ -36,7 +36,7 @@
         Configuration config = new Configuration();
         config.setCacheMode(Configuration.CacheMode.LOCAL);
         config.setTransactionManagerLookupClass(DummyTransactionManagerLookup.class.getName());
  -      cache = (TreeCacheProxyImpl) DefaultCacheFactory.createCache(config);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache(config);
         m = cache.getTransactionManager();
      }
   
  @@ -59,9 +59,9 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.put(fqn, "x", "1");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         cache.remove(fqn);
   
  @@ -70,9 +70,9 @@
         assertTrue(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.put(fqn, "x", "2");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         // test normal operation again
         cache.remove(fqn);
  @@ -81,9 +81,9 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.put(fqn, "x", "3");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
      /**
  @@ -97,9 +97,9 @@
   
         m.begin();
         cache.put(fqn, "x", "1");
  -      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         cache.remove(fqn);
   
  @@ -108,9 +108,9 @@
         cache.put(fqn, "x", "2");
         cache.getInvocationContext().getOptionOverrides().setSuppressLocking(true);
         cache.put(fqn1, "y", "3");
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         Map map = new HashMap();
         map.put("x", "1");
  @@ -119,18 +119,18 @@
         cache.put(fqn, map);
         cache.getInvocationContext().getOptionOverrides().setSuppressLocking(true);
         cache.put(fqn1, map);
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         // test normal operation again
         cache.remove(fqn);
   
         m.begin();
         cache.put(fqn, "x", "3");
  -      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
      public void testSuppressionOfReadLocks() throws Exception
  @@ -141,18 +141,18 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.get(fqn, "x");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         m.begin();
         cache.getInvocationContext().getOptionOverrides().setSuppressLocking(true);
         assertTrue(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.get(fqn, "x");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
   
         // test normal operation again
   
  @@ -160,18 +160,18 @@
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
         cache.get(fqn, "x");
         assertFalse(cache.getInvocationContext().getOptionOverrides().isSuppressLocking());
  -      assertEquals(2, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(2, cache.getNumberOfLocksHeld());
         m.commit();
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  +      assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
      public void testNodeCreation()
      {
  -      assertNull(cache.getChild(fqn));
  +      assertNull(cache.getRoot().getChild(fqn));
         cache.getInvocationContext().getOptionOverrides().setSuppressLocking(true);
         cache.put(fqn, "x", "y");
  -      assertEquals(0, cache.treeCache.getNumberOfLocksHeld());
  -      assertEquals("y", cache.getChild(fqn).get("x"));
  +      assertEquals(0, cache.getNumberOfLocksHeld());
  +      assertEquals("y", cache.getRoot().getChild(fqn).get("x"));
      }
   
   }
  
  
  
  1.9       +8 -8      JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ExplicitVersionsTest.java	12 Dec 2006 14:51:44 -0000	1.8
  +++ ExplicitVersionsTest.java	30 Dec 2006 17:49:54 -0000	1.9
  @@ -8,9 +8,9 @@
   
   import junit.framework.Assert;
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.optimistic.DataVersion;
  @@ -26,7 +26,7 @@
   public class ExplicitVersionsTest extends TestCase
   {
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private Fqn fqn = Fqn.fromString("/a");
      private String key = "key";
      private Option option = new Option();
  @@ -34,7 +34,7 @@
      protected void setUp() throws Exception
      {
         if (cache != null) tearDown();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setNodeLockingScheme("OPTIMISTIC");
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -60,7 +60,7 @@
         Assert.assertEquals("value", cache.get(fqn, key));
   
         // get a hold of the node
  -      OptimisticTreeNode node = (OptimisticTreeNode) cache.get(fqn);
  +      NodeSPI node = (NodeSPI) cache.get(fqn);
         DataVersion versionFromCache = node.getVersion();
   
         Assert.assertEquals(TestVersion.class, versionFromCache.getClass());
  @@ -115,14 +115,14 @@
      public void testExplicitVersionOnLeaf() throws Exception
      {
         cache.put("/org/domain/Entity", null);
  -      assertEquals(1, ((DefaultDataVersion) ((OptimisticTreeNode) cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(1, ((DefaultDataVersion) ((NodeSPI) cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
   
         TestVersion v = new TestVersion("Arse");
         cache.getInvocationContext().getOptionOverrides().setDataVersion(v);
         cache.put(Fqn.fromString("/org/domain/Entity/EntityInstance#1"), "k", "v");
   
  -      assertEquals(2, ((DefaultDataVersion) ((OptimisticTreeNode) cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  -      assertEquals(v, ((OptimisticTreeNode) cache.get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +      assertEquals(2, ((DefaultDataVersion) ((NodeSPI) cache.get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((NodeSPI) cache.get("/org/domain/Entity/EntityInstance#1")).getVersion());
      }
   
   }
  
  
  
  1.6       +22 -22    JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExplicitVersionsReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ExplicitVersionsReplTest.java	12 Dec 2006 14:51:44 -0000	1.5
  +++ ExplicitVersionsReplTest.java	30 Dec 2006 17:49:54 -0000	1.6
  @@ -2,9 +2,9 @@
   
   import junit.framework.Assert;
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.optimistic.DataVersion;
  @@ -20,22 +20,22 @@
    */
   public class ExplicitVersionsReplTest extends TestCase
   {
  -   private TreeCache cache[];
  +   private CacheImpl cache[];
      private Fqn fqn = Fqn.fromString("/a");
      private String key = "key";
   
      protected void setUp() throws Exception
      {
         if (cache != null) tearDown();
  -      cache = new TreeCache[2];
  +      cache = new CacheImpl[2];
         cache[0] = createCache();
         cache[1] = createCache();
         TestingUtil.blockUntilViewsReceived(cache, 20000);
      }
   
  -   private TreeCache createCache() throws Exception
  +   private CacheImpl createCache() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = cache.getConfiguration();
         c.setCacheMode(Configuration.CacheMode.REPL_SYNC);
         c.setNodeLockingScheme("OPTIMISTIC");
  @@ -55,12 +55,12 @@
      {
         if (cache != null)
         {
  -         for (TreeCache aCache : cache) destroyCache(aCache);
  +         for (CacheImpl aCache : cache) destroyCache(aCache);
            cache = null;
         }
      }
   
  -   private void destroyCache(TreeCache c)
  +   private void destroyCache(CacheImpl c)
      {
         TransactionManager tm = c.getTransactionManager();
         try
  @@ -253,16 +253,16 @@
   
         assertEquals("value", cache[0].get(fqn, key));
         assertEquals("value", cache[1].get(fqn, key));
  -      assertEquals(expected, ((OptimisticTreeNode) cache[0].get(fqn)).getVersion());
  -      assertEquals(expected, ((OptimisticTreeNode) cache[1].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[0].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[1].get(fqn)).getVersion());
   
         cache[1].put(fqn, key, "value2");
         expected = (DefaultDataVersion) expected.increment();
   
         assertEquals("value2", cache[0].get(fqn, key));
         assertEquals("value2", cache[1].get(fqn, key));
  -      assertEquals(expected, ((OptimisticTreeNode) cache[0].get(fqn)).getVersion());
  -      assertEquals(expected, ((OptimisticTreeNode) cache[1].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[0].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[1].get(fqn)).getVersion());
      }
   
      public void testPropagationOfCustomVersions() throws Exception
  @@ -273,8 +273,8 @@
   
         assertEquals("value", cache[0].get(fqn, key));
         assertEquals("value", cache[1].get(fqn, key));
  -      assertEquals(expected, ((OptimisticTreeNode) cache[0].get(fqn)).getVersion());
  -      assertEquals(expected, ((OptimisticTreeNode) cache[1].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[0].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[1].get(fqn)).getVersion());
   
         expected = new TestVersion("200");
         cache[1].getInvocationContext().getOptionOverrides().setDataVersion(expected);
  @@ -282,8 +282,8 @@
   
         assertEquals("value2", cache[0].get(fqn, key));
         assertEquals("value2", cache[1].get(fqn, key));
  -      assertEquals(expected, ((OptimisticTreeNode) cache[0].get(fqn)).getVersion());
  -      assertEquals(expected, ((OptimisticTreeNode) cache[1].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[0].get(fqn)).getVersion());
  +      assertEquals(expected, ((NodeSPI) cache[1].get(fqn)).getVersion());
      }
   
      public void testExplicitVersionOnRoot() throws Exception
  @@ -301,18 +301,18 @@
      public void testExplicitVersionOnLeaf() throws Exception
      {
         cache[0].put("/org/domain/Entity", null);
  -      assertEquals(1, ((DefaultDataVersion) ((OptimisticTreeNode) cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  -      assertEquals(1, ((DefaultDataVersion) ((OptimisticTreeNode) cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(1, ((DefaultDataVersion) ((NodeSPI) cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(1, ((DefaultDataVersion) ((NodeSPI) cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
   
         TestVersion v = new TestVersion("Arse");
         cache[0].getInvocationContext().getOptionOverrides().setDataVersion(v);
   
         cache[0].put(Fqn.fromString("/org/domain/Entity/EntityInstance#1"), "k", "v");
   
  -      assertEquals(2, ((DefaultDataVersion) ((OptimisticTreeNode) cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  -      assertEquals(v, ((OptimisticTreeNode) cache[0].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  -      assertEquals(2, ((DefaultDataVersion) ((OptimisticTreeNode) cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
  -      assertEquals(v, ((OptimisticTreeNode) cache[1].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +      assertEquals(2, ((DefaultDataVersion) ((NodeSPI) cache[0].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((NodeSPI) cache[0].get("/org/domain/Entity/EntityInstance#1")).getVersion());
  +      assertEquals(2, ((DefaultDataVersion) ((NodeSPI) cache[1].get("/org/domain/Entity")).getVersion()).getRawVersion());
  +      assertEquals(v, ((NodeSPI) cache[1].get("/org/domain/Entity/EntityInstance#1")).getVersion());
   
      }
   
  
  
  
  1.7       +3 -3      JBossCache/tests/functional/org/jboss/cache/options/FailSilentlyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FailSilentlyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/FailSilentlyTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- FailSilentlyTest.java	13 Dec 2006 18:15:52 -0000	1.6
  +++ FailSilentlyTest.java	30 Dec 2006 17:49:54 -0000	1.7
  @@ -7,8 +7,8 @@
   package org.jboss.cache.options;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   
   import javax.transaction.Transaction;
  @@ -23,7 +23,7 @@
    */
   public class FailSilentlyTest extends TestCase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private TransactionManager manager;
      private Transaction tx;
      private Fqn fqn = Fqn.fromString("/a");
  @@ -32,7 +32,7 @@
      protected void setUp() throws Exception
      {
         if (cache != null) tearDown();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         // very short acquisition timeout
         cache.getConfiguration().setLockAcquisitionTimeout(100);
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:54 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors ...
Message-ID: <E1H0iLC-0008LA-6u@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:54

  Modified:    src/org/jboss/cache/interceptors               
                        OptimisticNodeInterceptor.java
                        OptimisticValidatorInterceptor.java
                        CallInterceptor.java
                        CreateIfNotExistsInterceptor.java
                        PessimisticLockInterceptor.java
                        CacheMgmtInterceptor.java
                        InvalidationInterceptor.java
                        OptimisticCreateIfNotExistsInterceptor.java
                        CacheStoreInterceptor.java
                        CacheLoaderInterceptor.java
                        DataGravitatorInterceptor.java TxInterceptor.java
                        ActivationInterceptor.java
                        OptimisticLockingInterceptor.java
                        PassivationInterceptor.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.37      +5 -6      JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.36
  retrieving revision 1.37
  diff -u -b -r1.36 -r1.37
  --- OptimisticNodeInterceptor.java	14 Dec 2006 17:18:48 -0000	1.36
  +++ OptimisticNodeInterceptor.java	30 Dec 2006 17:49:53 -0000	1.37
  @@ -11,7 +11,6 @@
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeNode;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.marshall.MethodCall;
  @@ -195,9 +194,9 @@
   
         // now that we have the parent and target nodes:
         // first correct the pointers at the pruning point
  -      oldParent.removeChild(nodeName);
  +      oldParent.removeChild(new Fqn(nodeName));
         //      parent.addChild(nodeName, node);
  -      //      parent.createChild(nodeName, nodeFqn, parent.getNode(), ((TreeCacheProxyImpl)cache).treeCache, null);
  +      //      parent.createChild(nodeName, nodeFqn, parent.getNode(), ((TreeCacheProxyImpl)cache).cache, null);
   
         // parent pointer is calculated on the fly using Fqns.
   
  @@ -226,7 +225,7 @@
         // process children
         for (Object n : node.getChildrenNames())
         {
  -         //         movedNode.createChild(n, new Fqn(node.getFqn(), n), movedNode.getNode(), ((TreeCacheProxyImpl)cache).treeCache, null);
  +         //         movedNode.createChild(n, new Fqn(node.getFqn(), n), movedNode.getNode(), ((TreeCacheProxyImpl)cache).cache, null);
            WorkspaceNode child = getOrCreateWorkspaceNode(new Fqn(node.getFqn(), n), ws);
            moveFqns(child, newFqn, ws);
            //movedNode.addChild(n, child);
  @@ -307,7 +306,7 @@
            throw new CacheException("Unable to find parent node with Fqn " + parentFqn);
         }
   
  -      parentNode.removeChild(workspaceNode.getName());
  +      parentNode.removeChild(new Fqn(workspaceNode.getFqn().getLast()));
         workspace.addNode(parentNode);
         if (debug) log.debug("added parent node " + parentNode.getFqn() + " to workspace");
         Fqn nodeFqn = workspaceNode.getFqn();
  @@ -440,7 +439,7 @@
            {
               return null;// seems to happen quite a bit
            }
  -         workspaceNode = NodeFactory.getInstance().createWorkspaceNode((TreeNode) node, workspace);
  +         workspaceNode = NodeFactory.getInstance().createWorkspaceNode(node, workspace);
            workspace.addNode(workspaceNode);
         }
         // the node has been deleted dude!
  
  
  
  1.47      +8 -9      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -b -r1.46 -r1.47
  --- OptimisticValidatorInterceptor.java	12 Dec 2006 14:51:44 -0000	1.46
  +++ OptimisticValidatorInterceptor.java	30 Dec 2006 17:49:53 -0000	1.47
  @@ -7,12 +7,11 @@
   package org.jboss.cache.interceptors;
   
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.OptimisticTreeNode;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.optimistic.DataVersioningException;
  @@ -110,8 +109,8 @@
            Fqn fqn = workspaceNode.getFqn();
            if (trace) log.trace("Validating version for node " + fqn);
   
  -         OptimisticTreeNode realNode;
  -         realNode = (OptimisticTreeNode) cache.peek(fqn);
  +         NodeSPI realNode;
  +         realNode = cache.peek(fqn);
   
            // if this is a newly created node then we expect the underlying node to be null.
            // if not, we have a problem...
  @@ -135,13 +134,13 @@
               if (realNode.getVersion().newerThan(workspaceNode.getVersion()))
               {
                  // we have an out of date node here
  -               throw new DataVersioningException("DataNode [" + fqn + "] version " + ((OptimisticTreeNode) workspaceNode.getNode()).getVersion() + " is newer than workspace node " + workspaceNode.getVersion());
  +               throw new DataVersioningException("DataNode [" + fqn + "] version " + workspaceNode.getNode().getVersion() + " is newer than workspace node " + workspaceNode.getVersion());
               }
            }
         }
      }
   
  -   private boolean checkNotInitialRootVersion(OptimisticTreeNode n)
  +   private boolean checkNotInitialRootVersion(NodeSPI n)
      {
         return !n.getFqn().isRoot() || !(n.getVersion() instanceof DefaultDataVersion) || n.getVersion() != DefaultDataVersion.ZERO;
      }
  @@ -181,12 +180,12 @@
               else
               {
                  cache.getNotifier().notifyNodeRemoved(dNode.getFqn(), true, dNode.getNodeSPI().getRawData());
  -               DataNode parent = (DataNode) dNode.getParent();
  +               Node parent = dNode.getParent();
                  if (parent == null)
                  {
                     throw new IllegalStateException("dNode " + dNode + " has no parent");
                  }
  -               parent.removeChild(dNode.getFqn().getLast());
  +               parent.removeChild(new Fqn(dNode.getFqn().getLast()));
                  cache.getNotifier().notifyNodeRemoved(dNode.getFqn(), false, null);
               }
            }
  @@ -196,7 +195,7 @@
               // if (wrappedNode.hasCreatedOrRemovedChildren() handleChildNodes(wrappedNode);
               if (wrappedNode.isDirty())
               {
  -               OptimisticTreeNode current = (OptimisticTreeNode) wrappedNode.getNode();
  +               NodeSPI current = wrappedNode.getNode();
                  Map mergedChildren = wrappedNode.getMergedChildren();
   
                  // this could be done better to account for more subtle merges
  
  
  
  1.16      +89 -88    JBossCache/src/org/jboss/cache/interceptors/CallInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CallInterceptor.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- CallInterceptor.java	25 Aug 2006 14:10:07 -0000	1.15
  +++ CallInterceptor.java	30 Dec 2006 17:49:53 -0000	1.16
  @@ -1,12 +1,12 @@
   package org.jboss.cache.interceptors;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Option;
  -import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.marshall.MethodCall;
  +import org.jboss.cache.marshall.MethodDeclarations;
   
   import javax.transaction.Transaction;
   
  @@ -14,25 +14,25 @@
    * Always at the end of the chain, directly in front of the cache. Simply calls into the cache using reflection.
    * If the call resulted in a modification, add the Modification to the end of the modification list
    * keyed by the current transaction.
  - *
  + * <p/>
    * Although always added to the end of an optimistically locked chain as well, calls should not make it down to
    * this interceptor unless it is a call the OptimisticNodeInterceptor knows nothing about.
    *
    * @author Bela Ban
  - * @version $Id: CallInterceptor.java,v 1.15 2006/08/25 14:10:07 msurtani Exp $
  + * @version $Id: CallInterceptor.java,v 1.16 2006/12/30 17:49:53 msurtani Exp $
    */
   public class CallInterceptor extends Interceptor
   {
  -    private TreeCache treeCache;
  +   private CacheImpl cache;
   
       public void setCache(CacheSPI cache)
       {
           super.setCache(cache);
       }
   
  -    public void setTreeCacheInstance(TreeCache c)
  +   public void setTreeCacheInstance(CacheImpl c)
       {
  -        treeCache = c;
  +      cache = c;
       }
   
       public Object invoke(MethodCall m) throws Throwable
  @@ -46,7 +46,7 @@
               try
               {
                   //retval = super.invoke(m);
  -                retval = m.invoke(treeCache);
  +            retval = m.invoke(cache);
               }
               catch (Throwable t)
               {
  @@ -99,7 +99,8 @@
                           {
                               cache.getTransactionTable().addModification(gtx, m);
                           }
  -                        if (cache.getCacheLoaderManager() != null) cache.getTransactionTable().addCacheLoaderModification(gtx, m);
  +                  if (cache.getCacheLoaderManager() != null)
  +                     cache.getTransactionTable().addCacheLoaderModification(gtx, m);
                       }
                   }
               }
  
  
  
  1.21      +6 -6      JBossCache/src/org/jboss/cache/interceptors/CreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CreateIfNotExistsInterceptor.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- CreateIfNotExistsInterceptor.java	8 Dec 2006 18:49:17 -0000	1.20
  +++ CreateIfNotExistsInterceptor.java	30 Dec 2006 17:49:53 -0000	1.21
  @@ -9,16 +9,16 @@
   import org.jboss.cache.marshall.MethodCallFactory;
   import org.jboss.cache.marshall.MethodDeclarations;
   
  -import java.util.concurrent.locks.ReentrantLock;
   import java.util.ArrayList;
   import java.util.Iterator;
  +import java.util.concurrent.locks.ReentrantLock;
   
   /**
    * Handles putXXX() methods: if the given node doesn't exist, it will be created
    * (depending on the create_if_not_exists argument)
    *
    * @author Bela Ban
  - * @version $Id: CreateIfNotExistsInterceptor.java,v 1.20 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: CreateIfNotExistsInterceptor.java,v 1.21 2006/12/30 17:49:53 msurtani Exp $
    * @deprecated This code is not used anymore and will be removed in a future unlock
    */
   public class CreateIfNotExistsInterceptor extends Interceptor
  @@ -69,8 +69,8 @@
   //      Method meth=m.getMethod();
   //
   //      boolean isPut=putMethods.contains(meth),
  -//            isRemove=TreeCache.removeNodeMethodLocal.equals(meth),
  -//            isEvict=TreeCache.evictNodeMethodLocal.equals(meth);
  +//            isRemove=CacheImpl.removeNodeMethodLocal.equals(meth),
  +//            isEvict=CacheImpl.evictNodeMethodLocal.equals(meth);
   //
   //      if(isPut || isRemove || isEvict) {  // we need to sync put(), remove() and evict() calls
   //         try {
  @@ -129,7 +129,7 @@
               {
                  addFqnToPutList(fqn, put_lock);
                  findAndBlockOnRemove(fqn, remove_lock);
  -               if (!cache.hasChild(fqn))
  +               if (!cache.getRoot().hasChild(fqn))
                  {
                     GlobalTransaction gtx = cache.getInvocationContext().getGlobalTransaction();
                     if (log.isTraceEnabled())
  @@ -354,7 +354,7 @@
         synchronized (this)
         {
            int treeNodeSize = fqn.size();
  -         n = cache;
  +         n = cache.getRoot();
            for (int i = 0; i < treeNodeSize; i++)
            {
               child_name = fqn.get(i);
  
  
  
  1.39      +13 -13    JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -b -r1.38 -r1.39
  --- PessimisticLockInterceptor.java	15 Dec 2006 17:30:32 -0000	1.38
  +++ PessimisticLockInterceptor.java	30 Dec 2006 17:49:53 -0000	1.39
  @@ -6,15 +6,15 @@
    */
   package org.jboss.cache.interceptors;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.TransactionEntry;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.LockingException;
   import org.jboss.cache.lock.NodeLock;
  @@ -37,7 +37,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.38 2006/12/15 17:30:32 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.39 2006/12/30 17:49:53 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -169,7 +169,7 @@
            {
               lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, createIfNotExists, zeroLockTimeout ? 0 : lock_acquisition_timeout, isDeleteOperation);
            }
  -         while (createIfNotExists && !cache.hasChild(fqn));// keep trying until we have the lock (fixes concurrent remove())
  +         while (createIfNotExists && !cache.getRoot().hasChild(fqn));// keep trying until we have the lock (fixes concurrent remove())
         }
         else if (!lockNecessary)
         {
  @@ -184,7 +184,7 @@
         }
         Object o = super.invoke(m);
         // FIXME this should be done in UnlockInterceptor, but I didn't want
  -      // to add the removedNodes map to TreeCache
  +      // to add the removedNodes map to CacheImpl
         if (isDeleteOperation && ctx.getGlobalTransaction() == null)
         {
            //cache.getRemovedNodesMap().remove(fqn);
  @@ -195,7 +195,7 @@
            {
               lockManager.getLock(n).releaseAll(Thread.currentThread());
            }
  -         ((TreeCacheProxyImpl) cache).realRemove(fqn, true);
  +         ((CacheImpl) cache).realRemove(fqn, true);
   
         }
         return o;
  @@ -252,7 +252,7 @@
            lock_type = NodeLock.LockType.NONE;
         }
   
  -      n = cache;
  +      n = cache.getRoot();
         treeNodeSize = fqn.size();
         for (int i = -1; i < treeNodeSize; i++)
         {
  @@ -345,12 +345,12 @@
   
      private boolean needToReverseRemove(Node n, TransactionEntry te, NodeLock.LockType lockTypeRequested, boolean isRemoveOperation, boolean createIfNotExists)
      {
  -      return !isRemoveOperation && createIfNotExists && lockTypeRequested == NodeLock.LockType.WRITE && ((DataNode) n).isDeleted() && te.getRemovedNodes().contains(n.getFqn());
  +      return !isRemoveOperation && createIfNotExists && lockTypeRequested == NodeLock.LockType.WRITE && ((NodeSPI) n).isDeleted() && te.getRemovedNodes().contains(n.getFqn());
      }
   
      private void reverseRemove(Node n)
      {
  -      ((DataNode) n).markAsDeleted(false);
  +      ((NodeSPI) n).markAsDeleted(false);
      }
   
      private boolean writeLockNeeded(NodeLock.LockType lock_type, int currentNodeIndex, int treeNodeSize, boolean isRemoveOperation, boolean createIfNotExists, Fqn targetFqn, Fqn currentFqn)
  @@ -360,7 +360,7 @@
            return true;// we're doing a remove and we've reached the PARENT node of the target to be removed.
         }
   
  -      if (!isTargetNode(currentNodeIndex, treeNodeSize) && !cache.hasChild(new Fqn(currentFqn, targetFqn.get(currentNodeIndex + 1))))
  +      if (!isTargetNode(currentNodeIndex, treeNodeSize) && !cache.getRoot().hasChild(new Fqn(currentFqn, targetFqn.get(currentNodeIndex + 1))))
         {
            return createIfNotExists;// we're at a node in the tree, not yet at the target node, and we need to create the next node.  So we need a WL here.
         }
  @@ -421,7 +421,7 @@
      {
         int treeNodeSize;
         if ((treeNodeSize = fqn.size()) == 0) return;
  -      Node n = cache;
  +      Node n = cache.getRoot();
         for (int i = 0; i < treeNodeSize; i++)
         {
            Object child_name = fqn.get(i);
  @@ -473,7 +473,7 @@
   
         // first remove nodes that should be deleted.
         Iterator removedNodes = entry.getRemovedNodes().iterator();
  -      TreeCacheProxyImpl tcpi = (TreeCacheProxyImpl) cache;
  +      CacheImpl tcpi = (CacheImpl) cache;
         while (removedNodes.hasNext())
         {
            Fqn f = (Fqn) removedNodes.next();
  @@ -521,7 +521,7 @@
   
   
         Iterator removedNodes = entry.getRemovedNodes().iterator();
  -      TreeCacheProxyImpl tcpi = (TreeCacheProxyImpl) cache;
  +      CacheImpl tcpi = (CacheImpl) cache;
         while (removedNodes.hasNext())
         {
            Fqn f = (Fqn) removedNodes.next();
  
  
  
  1.25      +3 -3      JBossCache/src/org/jboss/cache/interceptors/CacheMgmtInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheMgmtInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheMgmtInterceptor.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- CacheMgmtInterceptor.java	8 Dec 2006 18:49:17 -0000	1.24
  +++ CacheMgmtInterceptor.java	30 Dec 2006 17:49:53 -0000	1.25
  @@ -43,7 +43,7 @@
    * Captures cache management statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: CacheMgmtInterceptor.java,v 1.24 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: CacheMgmtInterceptor.java,v 1.25 2006/12/30 17:49:53 msurtani Exp $
    */
   public class CacheMgmtInterceptor extends Interceptor implements CacheMgmtInterceptorMBean, NotificationBroadcaster
   {
  @@ -273,7 +273,7 @@
   
      private synchronized void emitNotifications(boolean emit)
      {
  -      // This method adds and removes the TreeCache listener.
  +      // This method adds and removes the CacheImpl listener.
         // The m_listeners counter is used to determine whether
         // we have any clients who are registered for notifications
         // from this mbean.  When the count is zero, we don't need to 
  @@ -338,7 +338,7 @@
         emitNotifications(false);
      }
   
  -   // Handler for TreeCache events
  +   // Handler for CacheImpl events
      private class CacheMgmtListener implements CacheListener
      {
         private long seq()
  
  
  
  1.29      +1 -1      JBossCache/src/org/jboss/cache/interceptors/InvalidationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvalidationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/InvalidationInterceptor.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- InvalidationInterceptor.java	10 Nov 2006 02:48:46 -0000	1.28
  +++ InvalidationInterceptor.java	30 Dec 2006 17:49:53 -0000	1.29
  @@ -31,7 +31,7 @@
   
   /**
    * This interceptor acts as a replacement to the replication interceptor when
  - * the TreeCache is configured with ClusteredSyncMode as INVALIDATE.
  + * the CacheImpl is configured with ClusteredSyncMode as INVALIDATE.
    * <p/>
    * The idea is that rather than replicating changes to all caches in a cluster
    * when CRUD (Create, Remove, Update, Delete) methods are called, simply call
  
  
  
  1.33      +4 -4      JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticCreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- OptimisticCreateIfNotExistsInterceptor.java	12 Dec 2006 14:51:44 -0000	1.32
  +++ OptimisticCreateIfNotExistsInterceptor.java	30 Dec 2006 17:49:53 -0000	1.33
  @@ -40,7 +40,7 @@
            Object[] args = m.getArgs();
            Fqn fqn = (Fqn) (args != null ? args[1] : null);
   
  -         if (!cache.hasChild(fqn))
  +         if (!cache.getRoot().hasChild(fqn))
            {
               createNode(fqn);
            }
  @@ -60,7 +60,7 @@
         fqns.add(newParent);
   
         //  peek into Node and get a hold of all child fqns as these need to be in the workspace.
  -      Node node = cache.getChild(nodeFqn);
  +      Node node = cache.getRoot().getChild(nodeFqn);
         greedyGetFqns(fqns, node, newParent);
   
   
  @@ -69,7 +69,7 @@
   
         for (Fqn f : fqns)
         {
  -         if (!cache.hasChild(f)) createNode(f);
  +         if (!cache.getRoot().hasChild(f)) createNode(f);
         }
      }
   
  @@ -149,7 +149,7 @@
   
               if (debug)
                  log.debug("workspaceNode.getChild(" + childName + ")");
  -            Node tempchildNode = workspaceNode.getChild(childName);
  +            Node tempchildNode = workspaceNode.getChild(new Fqn(childName));
   
   //                if (log.isDebugEnabled()) log.debug(" Entered synchronized workspaceNode " + workspaceNode + " access  for gtx " + gtx);
   
  
  
  
  1.40      +2 -2      JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheStoreInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -b -r1.39 -r1.40
  --- CacheStoreInterceptor.java	8 Dec 2006 18:49:17 -0000	1.39
  +++ CacheStoreInterceptor.java	30 Dec 2006 17:49:54 -0000	1.40
  @@ -27,7 +27,7 @@
    * through the CacheLoader, either after each method call (no TXs), or at TX commit.
    *
    * @author Bela Ban
  - * @version $Id: CacheStoreInterceptor.java,v 1.39 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: CacheStoreInterceptor.java,v 1.40 2006/12/30 17:49:54 msurtani Exp $
    */
   public class CacheStoreInterceptor extends BaseCacheLoaderInterceptor implements CacheStoreInterceptorMBean
   {
  @@ -258,7 +258,7 @@
      private void doMove(Fqn parent, Fqn node) throws Exception
      {
         Fqn newNodeFqn = new Fqn(parent, node.getLast());
  -      //NodeImpl n = (NodeImpl) ((TreeCacheProxyImpl) cache).peek(newNodeFqn);
  +      //UnversionedNode n = (UnversionedNode) ((TreeCacheProxyImpl) cache).peek(newNodeFqn);
         //recursiveMove(n);
         //      throw new RuntimeException("Implement me!");
   
  
  
  
  1.65      +4 -4      JBossCache/src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java,v
  retrieving revision 1.64
  retrieving revision 1.65
  diff -u -b -r1.64 -r1.65
  --- CacheLoaderInterceptor.java	20 Dec 2006 02:16:24 -0000	1.64
  +++ CacheLoaderInterceptor.java	30 Dec 2006 17:49:54 -0000	1.65
  @@ -29,7 +29,7 @@
    * Loads nodes that don't exist at the time of the call into memory from the CacheLoader
    *
    * @author Bela Ban
  - * @version $Id: CacheLoaderInterceptor.java,v 1.64 2006/12/20 02:16:24 msurtani Exp $
  + * @version $Id: CacheLoaderInterceptor.java,v 1.65 2006/12/30 17:49:54 msurtani Exp $
    */
   public class CacheLoaderInterceptor extends BaseCacheLoaderInterceptor implements CacheLoaderInterceptorMBean
   {
  @@ -373,7 +373,7 @@
         int treeNodeSize = fqn.size();
   
         // root node
  -      Node n = cache;
  +      Node n = cache.getRoot();
         Node child_node;
         Object child_name;
         for (int i = 0; i < treeNodeSize && n != null; i++)
  @@ -461,7 +461,7 @@
         int size = fqn.size();
   
         // root node
  -      Node n = cache;
  +      Node n = cache.getRoot();
         for (int i = 0; i < size; i++)
         {
            Object child_name = fqn.get(i);
  @@ -483,7 +483,7 @@
               }
               else
               {
  -               //child_node = n.createChild(child_name, tmp_fqn, n, TreeCache.UNINITIALIZED, null);
  +               //child_node = n.createChild(child_name, tmp_fqn, n, CacheImpl.UNINITIALIZED, null);
                  child_node = n.addChild(new Fqn(child_name));
                  child_node.getNodeSPI().setDataLoaded(false);
               }
  
  
  
  1.31      +9 -11     JBossCache/src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataGravitatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java,v
  retrieving revision 1.30
  retrieving revision 1.31
  diff -u -b -r1.30 -r1.31
  --- DataGravitatorInterceptor.java	8 Dec 2006 18:49:17 -0000	1.30
  +++ DataGravitatorInterceptor.java	30 Dec 2006 17:49:54 -0000	1.31
  @@ -10,7 +10,6 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.InvocationContext;
  @@ -29,6 +28,7 @@
   
   import java.io.ByteArrayInputStream;
   import java.util.ArrayList;
  +import java.util.Collection;
   import java.util.Collections;
   import java.util.Iterator;
   import java.util.List;
  @@ -87,7 +87,7 @@
               }
               else
               {
  -               if (!cache.hasChild(fqn))
  +               if (!cache.getRoot().hasChild(fqn))
                  {
                     BackupData data;
   
  @@ -370,7 +370,7 @@
            NodeData data = (NodeData) nodes.next();
            if (localOnly)
            {
  -            if (!cache.hasChild(data.getFqn()))
  +            if (!cache.getRoot().hasChild(data.getFqn()))
               {
                  createNodes(data.getFqn(), data.getAttributes());
               }
  @@ -386,7 +386,7 @@
      {
         int treeNodeSize;
         if ((treeNodeSize = fqn.size()) == 0) return;
  -      Node n = cache;
  +      Node n = cache.getRoot();
         for (int i = 0; i < treeNodeSize; i++)
         {
            Object child_name = fqn.get(i);
  @@ -422,14 +422,12 @@
   
      private boolean localBackupExists(Fqn fqn)
      {
  -      Iterator backupRoots = getBackupRootIterator();
         boolean exists = false;
   
  -      while (backupRoots.hasNext())
  +      for (Node node : getBackupRootCollection())
         {
  -         DataNode node = (DataNode) backupRoots.next();
            Fqn newSearchFqn = new Fqn(node.getFqn(), fqn);
  -         exists = cache.hasChild(newSearchFqn);
  +         exists = cache.getRoot().hasChild(newSearchFqn);
            if (exists) break;
         }
   
  @@ -464,10 +462,10 @@
         return data;
      }
   
  -   private Iterator getBackupRootIterator()
  +   private Collection<Node> getBackupRootCollection()
      {
         Node backupRoot = cache.peek(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
  -      return backupRoot == null ? Collections.EMPTY_SET.iterator() : backupRoot.getChildren().iterator();
  +      return backupRoot == null ? Collections.EMPTY_SET : backupRoot.getChildren();
      }
   
      private static class BackupData
  
  
  
  1.69      +5 -5      JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/TxInterceptor.java,v
  retrieving revision 1.68
  retrieving revision 1.69
  diff -u -b -r1.68 -r1.69
  --- TxInterceptor.java	21 Dec 2006 02:57:52 -0000	1.68
  +++ TxInterceptor.java	30 Dec 2006 17:49:54 -0000	1.69
  @@ -78,7 +78,7 @@
         {
            // first of all deal with tx methods - these are only going to be
            // prepare/commit/rollback called by a remote cache, since calling
  -         // such methods on TreeCache directly would fail.
  +         // such methods on CacheImpl directly would fail.
   
            if (MethodDeclarations.isTransactionLifecycleMethod(m.getMethodId()))
            {
  @@ -409,7 +409,7 @@
               success = false;
               if (retval instanceof Exception)
               {
  -               throw(Exception) retval;
  +               throw (Exception) retval;
               }
            }
         }
  @@ -735,7 +735,7 @@
         {
            cache.getInvocationContext().setTxHasMods(modifications != null && modifications.size() > 0);
            // JBCACHE-457
  -         //            MethodCall rollbackMethod = MethodCall(TreeCache.rollbackMethod, new Object[]{gtx, hasMods ? true : false});
  +         //            MethodCall rollbackMethod = MethodCall(CacheImpl.rollbackMethod, new Object[]{gtx, hasMods ? true : false});
            MethodCall rollbackMethod = MethodCallFactory.create(MethodDeclarations.rollbackMethod, gtx);
            if (log.isTraceEnabled()) {log.trace(" running rollback for " + gtx);}
   
  @@ -768,7 +768,7 @@
         // TODO: Manik: one phase commit for opt locking too if using repl-async?
         // build the method call
         MethodCall prepareMethod;
  -      //        if (cache.getCacheModeInternal() != TreeCache.REPL_ASYNC)
  +      //        if (cache.getCacheModeInternal() != CacheImpl.REPL_ASYNC)
         //        {
         // running a 2-phase commit.
         if (configuration.isNodeLockingOptimistic())
  @@ -1066,7 +1066,7 @@
                     if (result instanceof Throwable)
                     {
                        tx.setRollbackOnly();
  -                     throw(Throwable) result;
  +                     throw (Throwable) result;
                     }
                     break;
                  default:
  
  
  
  1.45      +3 -3      JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActivationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- ActivationInterceptor.java	20 Dec 2006 02:16:24 -0000	1.44
  +++ ActivationInterceptor.java	30 Dec 2006 17:49:54 -0000	1.45
  @@ -25,7 +25,7 @@
    * their attributes have been initialized and their children have been loaded in memory.
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: ActivationInterceptor.java,v 1.44 2006/12/20 02:16:24 msurtani Exp $
  + * @version $Id: ActivationInterceptor.java,v 1.45 2006/12/30 17:49:54 msurtani Exp $
    */
   public class ActivationInterceptor extends CacheLoaderInterceptor implements ActivationInterceptorMBean
   {
  @@ -151,7 +151,7 @@
                  log.trace("This is a remove data operation; removing the data from the loader, no activation processing needed.");
                  loader.removeData(fqn);
               }
  -            else if (cache.hasChild(fqn) && loader.exists(fqn))
  +            else if (cache.getRoot().hasChild(fqn) && loader.exists(fqn))
               {
                  // Remove the node from the cache loader if it exists in memory,
                  // its attributes have been initialized, its children have been loaded,
  @@ -301,7 +301,7 @@
                  // AND it was found in the cache loader (nodeLoaded = true).
                  // Then notify the listeners that the node has been activated.
                  Fqn fqn = (Fqn) args[1];
  -               if (fqn != null && cache.hasChild(fqn) && loader.exists(fqn))
  +               if (fqn != null && cache.getRoot().hasChild(fqn) && loader.exists(fqn))
                  {
                     Node n = getNode(fqn); // don't load
                     // node not null and attributes have been loaded?
  
  
  
  1.24      +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticLockingInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticLockingInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticLockingInterceptor.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- OptimisticLockingInterceptor.java	20 Nov 2006 03:53:54 -0000	1.23
  +++ OptimisticLockingInterceptor.java	30 Dec 2006 17:49:54 -0000	1.24
  @@ -50,7 +50,7 @@
         // bail out if _lock() is being called on the tree cache... this should never be called with o/l enabled.
         if (m.getMethodId() == MethodDeclarations.lockMethodLocal_id)
         {
  -         log.warn("OptimisticLockingInterceptor intercepted a call to TreeCache._lock().  " +
  +         log.warn("OptimisticLockingInterceptor intercepted a call to CacheImpl._lock().  " +
                    "This should NEVER be called if optimistic locking is used!!  " +
                    "Not allowing this call to proceed further down the chain.");
            return retval;
  
  
  
  1.35      +13 -11    JBossCache/src/org/jboss/cache/interceptors/PassivationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PassivationInterceptor.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- PassivationInterceptor.java	8 Dec 2006 18:49:17 -0000	1.34
  +++ PassivationInterceptor.java	30 Dec 2006 17:49:54 -0000	1.35
  @@ -1,6 +1,5 @@
   package org.jboss.cache.interceptors;
   
  -import java.util.concurrent.atomic.AtomicLong;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  @@ -10,13 +9,14 @@
   
   import java.util.HashMap;
   import java.util.Map;
  +import java.util.concurrent.atomic.AtomicLong;
   
   /**
    * Writes evicted nodes back to the store on the way in through the
    * CacheLoader, either before each method call (no TXs), or at TX commit.
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationInterceptor.java,v 1.34 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: PassivationInterceptor.java,v 1.35 2006/12/30 17:49:54 msurtani Exp $
    */
   public class PassivationInterceptor extends Interceptor implements PassivationInterceptorMBean
   {
  @@ -109,7 +109,7 @@
         {
            throw new NodeNotLoadedException();
         }
  -      Node n = cache;
  +      Node n = cache.getRoot();
         int size = fqn.size();
         for (int i = 0; i < size && n != null; i++)
         {
  @@ -128,7 +128,9 @@
      
      private static class NodeNotLoadedException extends Exception
      {
  -      /** The serialVersionUID */
  +      /**
  +       * The serialVersionUID
  +       */
         private static final long serialVersionUID = -4078972305344328905L;      
      }
   }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:54 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache          ...
Message-ID: <E1H0iLC-0008Lv-HZ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:54

  Modified:    tests/functional/org/jboss/cache          CallbackTest.java
                        GetKeysTest.java LifeCycleTest.java
                        TreeNodeTest.java HungChannelTest.java FqnTest.java
                        TreeCacheFunctionalTest.java
  Added:       tests/functional/org/jboss/cache         
                        UnversionedNodeTest.java
  Removed:     tests/functional/org/jboss/cache          NodeImplTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.14      +11 -11    JBossCache/tests/functional/org/jboss/cache/CallbackTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CallbackTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/CallbackTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- CallbackTest.java	6 Sep 2006 15:31:01 -0000	1.13
  +++ CallbackTest.java	30 Dec 2006 17:49:54 -0000	1.14
  @@ -14,11 +14,11 @@
    * Tests whether modifications within callbacks (TreeCacheListener) are handled correctly
    *
    * @author Bela Ban
  - * @version $Id: CallbackTest.java,v 1.13 2006/09/06 15:31:01 msurtani Exp $
  + * @version $Id: CallbackTest.java,v 1.14 2006/12/30 17:49:54 msurtani Exp $
    */
   public class CallbackTest extends TestCase
   {
  -   TreeCache cache = null, cache2;
  +   CacheImpl cache = null, cache2;
      Transaction tx = null;
      final Fqn FQN_A = Fqn.fromString("/a");
      final Fqn FQN_B = Fqn.fromString("/b");
  @@ -121,8 +121,8 @@
      }
   
      /*public void testSyncReplicationWith2Caches() throws Exception, NotSupportedException {
  -      cache=createCache(TreeCache.REPL_SYNC, IsolationLevel.SERIALIZABLE);
  -      cache2=createCache(TreeCache.REPL_SYNC, IsolationLevel.SERIALIZABLE);
  +      cache=createCache(CacheImpl.REPL_SYNC, IsolationLevel.SERIALIZABLE);
  +      cache2=createCache(CacheImpl.REPL_SYNC, IsolationLevel.SERIALIZABLE);
         cache.setSyncCommitPhase(true);
         cache2.setSyncCommitPhase(true);
   
  @@ -164,9 +164,9 @@
   }*/
   
   
  -   TreeCache createCache(Configuration.CacheMode mode, IsolationLevel level) throws Exception
  +   CacheImpl createCache(Configuration.CacheMode mode, IsolationLevel level) throws Exception
      {
  -      TreeCache c = new TreeCache();
  +      CacheImpl c = new CacheImpl();
         c.getConfiguration().setCacheMode(mode);
         c.getConfiguration().setIsolationLevel(level);
         c.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -201,10 +201,10 @@
   
      class GetListener extends AbstractCacheListener
      {
  -      TreeCache c;
  +      CacheImpl c;
         Fqn my_fqn;
   
  -      public GetListener(TreeCache c, Fqn my_fqn)
  +      public GetListener(CacheImpl c, Fqn my_fqn)
         {
            this.c = c;
            this.my_fqn = my_fqn;
  @@ -216,7 +216,7 @@
            {
               try
               {
  -               TreeNode n = c.get(this.my_fqn);
  +               Node n = c.get(this.my_fqn);
                  assertNotNull(n);
               }
               catch (CacheException e)
  @@ -230,9 +230,9 @@
   
      class PutListener extends AbstractCacheListener
      {
  -      TreeCache c;
  +      CacheImpl c;
   
  -      public PutListener(TreeCache c)
  +      public PutListener(CacheImpl c)
         {
            this.c = c;
         }
  
  
  
  1.3       +4 -4      JBossCache/tests/functional/org/jboss/cache/GetKeysTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GetKeysTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/GetKeysTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- GetKeysTest.java	6 Sep 2006 15:31:01 -0000	1.2
  +++ GetKeysTest.java	30 Dec 2006 17:49:54 -0000	1.3
  @@ -18,11 +18,11 @@
   
   /**
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a>
  - * @version $Id: GetKeysTest.java,v 1.2 2006/09/06 15:31:01 msurtani Exp $
  + * @version $Id: GetKeysTest.java,v 1.3 2006/12/30 17:49:54 msurtani Exp $
    */
   public class GetKeysTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
   
      public GetKeysTest(String s)
      {
  @@ -41,7 +41,7 @@
   
      public void testGetKeys() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.create();
         cache.start();
         cache.put("/a/b/c", "name", "Bela Ban");
  @@ -60,7 +60,7 @@
   
      public void testGetChildren() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.create();
         cache.start();
         cache.put("/a/b/c", null);
  
  
  
  1.6       +11 -11    JBossCache/tests/functional/org/jboss/cache/LifeCycleTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LifeCycleTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/LifeCycleTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- LifeCycleTest.java	15 Dec 2006 14:22:25 -0000	1.5
  +++ LifeCycleTest.java	30 Dec 2006 17:49:54 -0000	1.6
  @@ -13,10 +13,10 @@
   import javax.transaction.Transaction;
   
   /**
  - * Tests restart (stop-destroy-create-start) of TreeCache
  + * Tests restart (stop-destroy-create-start) of CacheImpl
    *
    * @author Bela Ban
  - * @version $Id: LifeCycleTest.java,v 1.5 2006/12/15 14:22:25 msurtani Exp $
  + * @version $Id: LifeCycleTest.java,v 1.6 2006/12/30 17:49:54 msurtani Exp $
    */
   public class LifeCycleTest extends TestCase
   {
  @@ -25,7 +25,7 @@
   
      public void testLocalRestartNoTransactions() throws Exception
      {
  -      TreeCache cache = createCache(Configuration.CacheMode.LOCAL);
  +      CacheImpl cache = createCache(Configuration.CacheMode.LOCAL);
         cache.create();
         cache.start();
   
  @@ -44,7 +44,7 @@
   
      public void testLocalRestartWithTransactions() throws Exception
      {
  -      TreeCache cache = createCache(Configuration.CacheMode.LOCAL);
  +      CacheImpl cache = createCache(Configuration.CacheMode.LOCAL);
         cache.create();
         cache.start();
   
  @@ -67,7 +67,7 @@
   
      public void testStartNoCreate() throws Exception
      {
  -      TreeCache cache = createCache(Configuration.CacheMode.LOCAL);
  +      CacheImpl cache = createCache(Configuration.CacheMode.LOCAL);
         cache.start();
   
         cache.put("/a/b/c", null);
  @@ -84,7 +84,7 @@
   
      public void testReStartNoCreate() throws Exception
      {
  -      TreeCache cache = createCache(Configuration.CacheMode.LOCAL);
  +      CacheImpl cache = createCache(Configuration.CacheMode.LOCAL);
         cache.start();
         cache.stop();
         cache.start();
  @@ -101,9 +101,9 @@
         assertEquals(0, cache.getNumberOfLocksHeld());
      }
   
  -   TreeCache createCache(Configuration.CacheMode cache_mode) throws Exception
  +   CacheImpl createCache(Configuration.CacheMode cache_mode) throws Exception
      {
  -      TreeCache retval = new TreeCache();
  +      CacheImpl retval = new CacheImpl();
         retval.getConfiguration().setCacheMode(cache_mode);
         retval.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         return retval;
  @@ -119,19 +119,19 @@
      }
   
   
  -   void startCache(TreeCache c) throws Exception
  +   void startCache(CacheImpl c) throws Exception
      {
         c.create();
         c.start();
      }
   
  -   void stopCache(TreeCache c)
  +   void stopCache(CacheImpl c)
      {
         c.stop();
         c.destroy();
      }
   
  -   void restartCache(TreeCache c) throws Exception
  +   void restartCache(CacheImpl c) throws Exception
      {
         stopCache(c);
         startCache(c);
  
  
  
  1.4       +9 -9      JBossCache/tests/functional/org/jboss/cache/TreeNodeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeNodeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/TreeNodeTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- TreeNodeTest.java	20 Nov 2006 03:53:55 -0000	1.3
  +++ TreeNodeTest.java	30 Dec 2006 17:49:54 -0000	1.4
  @@ -5,19 +5,19 @@
   import junit.framework.TestSuite;
   
   /**
  - * Tests restart (stop-destroy-create-start) of TreeCache
  + * Tests restart (stop-destroy-create-start) of CacheImpl
    *
    * @author Bela Ban
  - * @version $Id: TreeNodeTest.java,v 1.3 2006/11/20 03:53:55 genman Exp $
  + * @version $Id: TreeNodeTest.java,v 1.4 2006/12/30 17:49:54 msurtani Exp $
    */
   public class TreeNodeTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
   
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         startCache(cache);
      }
   
  @@ -31,16 +31,16 @@
      {
         Object key = new Integer(1);
         cache.put("/a/b/c", key, "test");
  -      DataNode node;
  +      Node node;
         node = cache.get("/a/b");
         assertFalse(node.getChildren().isEmpty());
  -      assertTrue(node.getChild("c") != null);
  +      assertTrue(node.getChild(new Fqn("c")) != null);
   
         Fqn fqn = Fqn.fromString("/e/f");
         cache.put(fqn, "1", "1");
         node = cache.get("/e");
         assertFalse(node.getChildren().isEmpty());
  -      assertTrue(node.getChild("f") != null);
  +      assertTrue(node.getChild(new Fqn("f")) != null);
   
      }
   
  @@ -84,13 +84,13 @@
       * }
       */
   
  -   void startCache(TreeCache c) throws Exception
  +   void startCache(CacheImpl c) throws Exception
      {
         c.create();
         c.start();
      }
   
  -   void stopCache(TreeCache c)
  +   void stopCache(CacheImpl c)
      {
         c.stop();
         c.destroy();
  
  
  
  1.3       +2 -2      JBossCache/tests/functional/org/jboss/cache/HungChannelTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: HungChannelTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/HungChannelTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- HungChannelTest.java	11 Oct 2006 13:20:27 -0000	1.2
  +++ HungChannelTest.java	30 Dec 2006 17:49:54 -0000	1.3
  @@ -18,11 +18,11 @@
    */
   public class HungChannelTest extends TestCase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      protected void setUp() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("REPL_SYNC");
      }
   
  
  
  
  1.17      +4 -4      JBossCache/tests/functional/org/jboss/cache/FqnTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FqnTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/FqnTest.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- FqnTest.java	31 Oct 2006 06:57:29 -0000	1.16
  +++ FqnTest.java	30 Dec 2006 17:49:54 -0000	1.17
  @@ -20,7 +20,7 @@
    * Tests {@link Fqn}.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> May 9, 2003
  - * @version $Revision: 1.16 $
  + * @version $Revision: 1.17 $
    */
   public class FqnTest extends TestCase
   {
  @@ -310,7 +310,7 @@
      public void testRemovalNonString() throws Exception
      {
         Fqn f = new Fqn(new Object[]{"test", new Integer(1)});
  -//       TreeCache tc = new TreeCache();
  +//       CacheImpl tc = new CacheImpl();
   //       tc.getConfiguration().setCacheMode("LOCAL");
   //       tc.start();
         Configuration c = new Configuration();
  @@ -320,12 +320,12 @@
         cache.put(f, "key", "value");
   
         assertEquals("value", cache.get(f, "key"));
  -      assertTrue(cache.hasChild(f));
  +      assertTrue(cache.getRoot().hasChild(f));
   
         cache.removeNode(f);
   
         assertNull(cache.get(f, "key"));
  -      assertFalse(cache.hasChild(f));
  +      assertFalse(cache.getRoot().hasChild(f));
      }
   
      public void testGetChildFqn()
  
  
  
  1.6       +4 -4      JBossCache/tests/functional/org/jboss/cache/TreeCacheFunctionalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheFunctionalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/TreeCacheFunctionalTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- TreeCacheFunctionalTest.java	6 Sep 2006 15:31:01 -0000	1.5
  +++ TreeCacheFunctionalTest.java	30 Dec 2006 17:49:54 -0000	1.6
  @@ -10,14 +10,14 @@
   import java.util.HashMap;
   
   /**
  - * Simple functional tests for TreeCache
  + * Simple functional tests for CacheImpl
    *
    * @author Bela Ban
  - * @version $Id: TreeCacheFunctionalTest.java,v 1.5 2006/09/06 15:31:01 msurtani Exp $
  + * @version $Id: TreeCacheFunctionalTest.java,v 1.6 2006/12/30 17:49:54 msurtani Exp $
    */
   public class TreeCacheFunctionalTest extends TestCase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      Transaction tx = null;
      final Fqn FQN = Fqn.fromString("/myNode");
      final String KEY = "key";
  @@ -28,7 +28,7 @@
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
  
  
  
  1.1      date: 2006/12/30 17:49:54;  author: msurtani;  state: Exp;JBossCache/tests/functional/org/jboss/cache/UnversionedNodeTest.java
  
  Index: UnversionedNodeTest.java
  ===================================================================
  package org.jboss.cache;
  
  import junit.framework.TestCase;
  
  import java.util.Collections;
  
  public class UnversionedNodeTest extends TestCase
  {
     UnversionedNode node = new UnversionedNode(Fqn.ROOT);
  
     public void testBasic()
     {
        assertEquals(Collections.emptyMap(), node.getData());
        assertEquals(Collections.emptySet(), node.getChildren());
     }
     /*
     public void testOrder()
     {  
        node.orderData();
        // bypass invocation chain
        Map m = node.getNodeSPI().getRawData();
        m.put("a", "x");
        m.put("b", "x");
        m.put("c", "x");
        
        SortedMap sm = (SortedMap) node.getData();
        assertEquals(null, sm.comparator());
        assertEquals("a", sm.firstKey());
        assertEquals("c", sm.lastKey());
     }
        
     public void testOrder2()
     {  
        node.orderChildren();
        SortedMap<Object, Node> sm = (SortedMap) node.getChildrenMap();
        Node a = new UnversionedNode(new Fqn("a"));
        Node b = new UnversionedNode(new Fqn("b"));
        Node c = new UnversionedNode(new Fqn("c"));
        sm.put("a", a);
        sm.put("b", b);
        sm.put("c", c);
        SortedSet<Node> ss = (SortedSet) node.getChildren();
        assertEquals(a, ss.first());
        assertEquals(c, ss.last());
     }
     */
  
  }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:54 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:54 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication  ...
Message-ID: <E1H0iLC-0008M2-LJ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:54

  Modified:    src/org/jboss/cache/buddyreplication  BuddyManager.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.56      +11 -11    JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.55
  retrieving revision 1.56
  diff -u -b -r1.55 -r1.56
  --- BuddyManager.java	21 Dec 2006 21:41:10 -0000	1.55
  +++ BuddyManager.java	30 Dec 2006 17:49:54 -0000	1.56
  @@ -10,9 +10,9 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractCacheListener;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.config.BuddyReplicationConfig.BuddyLocatorConfig;
   import org.jboss.cache.lock.TimeoutException;
  @@ -61,9 +61,9 @@
      BuddyLocator buddyLocator;
   
      /**
  -    * back-refernce to the TreeCache object
  +    * back-refernce to the CacheImpl object
       */
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      /**
       * The buddy group set up for this instance
  @@ -182,7 +182,7 @@
         return s.replace(':', '_');
      }
   
  -   public void init(TreeCache cache) throws Exception
  +   public void init(CacheImpl cache) throws Exception
      {
         log.debug("Starting buddy manager");
         this.cache = cache;
  @@ -200,7 +200,7 @@
         // allow waiting threads to process.
         initialised = true;
   
  -      // register a TreeCache Listener to reassign buddies as and when view changes occur
  +      // register a CacheImpl Listener to reassign buddies as and when view changes occur
         cache.getNotifier().addCacheListener(new AbstractCacheListener()
         {
            private Vector<Address> oldMembers;
  @@ -335,7 +335,7 @@
      // -------------- methods to be called by the tree cache  --------------------
   
      /**
  -    * Called by TreeCache._remoteAnnounceBuddyPoolName(Address address, String buddyPoolName)
  +    * Called by CacheImpl._remoteAnnounceBuddyPoolName(Address address, String buddyPoolName)
       * when a view change occurs and caches need to inform the cluster of which buddy pool it is in.
       */
      public void handlePoolNameBroadcast(Address address, String poolName)
  @@ -363,7 +363,7 @@
      }
   
      /**
  -    * Called by TreeCache._remoteRemoveFromBuddyGroup(String groupName)
  +    * Called by CacheImpl._remoteRemoveFromBuddyGroup(String groupName)
       * when a method call for this is received from a remote cache.
       */
      public void handleRemoveFromBuddyGroup(String groupName) throws BuddyNotInitException
  @@ -386,7 +386,7 @@
      }
   
      /**
  -    * Called by TreeCache._remoteAssignToBuddyGroup(BuddyGroup g) when a method
  +    * Called by CacheImpl._remoteAssignToBuddyGroup(BuddyGroup g) when a method
       * call for this is received from a remote cache.
       *
       * @param newGroup the buddy group
  @@ -429,7 +429,7 @@
                  in = new MarshalledValueInputStream(bais);              
                  stateMgr.setState(in, integrationRoot, cl);               
               }
  -            catch(Throwable t)
  +            catch (Throwable t)
               {
                  log.error("State for fqn " + fqn + " could not be transferred to a buddy at " + cache.getLocalAddress());
               }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:57 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo  ...
Message-ID: <E1H0iLF-0008NB-0X@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:57

  Modified:    src-50/org/jboss/cache/pojo  PojoTreeCache.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.17      +5 -13     JBossCache/src-50/org/jboss/cache/pojo/PojoTreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoTreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/PojoTreeCache.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- PojoTreeCache.java	20 Nov 2006 03:59:39 -0000	1.16
  +++ PojoTreeCache.java	30 Dec 2006 17:49:56 -0000	1.17
  @@ -7,22 +7,15 @@
   package org.jboss.cache.pojo;
   
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.RegionNotEmptyException;
  -import org.jboss.cache.TreeCache;
  -//import org.jboss.cache.aop.statetransfer.PojoStateTransferManager;
  -import org.jboss.cache.pojo.eviction.AopEvictionPolicy;
  -import org.jboss.cache.pojo.util.ObjectUtil;
   import org.jgroups.JChannel;
   import org.w3c.dom.Element;
   
   import javax.transaction.Transaction;
  -import java.util.Iterator;
  -import java.util.Map;
   
  -public class PojoTreeCache extends TreeCache
  +public class PojoTreeCache extends CacheImpl
   {
      private Element config_ = null;
   //   boolean detachPojoWhenEvicted_ = false;
  @@ -83,7 +76,7 @@
      }
   
      /**
  -    * Overrides the {@link TreeCache#activateRegion(String) superclass method} by
  +    * Overrides the {@link CacheImpl#activateRegion(String) superclass method} by
       * ensuring that the internal region where information on shared object is stored
       * has been activated.
       */
  @@ -92,7 +85,7 @@
      public void activateRegion(String subtreeFqn) throws RegionNotEmptyException, RegionNameConflictException, CacheException
      {
         if (!getConfiguration().isUseRegionBasedMarshalling())
  -         throw new IllegalStateException("TreeCache.activateRegion(). useRegionBasedMarshalling flag is not set!");
  +         throw new IllegalStateException("CacheImpl.activateRegion(). useRegionBasedMarshalling flag is not set!");
   
         if ("/".equals(subtreeFqn))
         {
  @@ -120,7 +113,6 @@
         }
      }
      */
  -
      public Object getLockOwner()
      {
         return getOwnerForLock();
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:57 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/mgmt ...
Message-ID: <E1H0iLF-0008NX-8W@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:57

  Modified:    tests/functional/org/jboss/cache/mgmt      
                        MgmtCoreTest.java InvalidationTest.java TxTest.java
                        NotificationTest.java CacheLoaderTest.java
                        PassivationTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.8       +4 -4      JBossCache/tests/functional/org/jboss/cache/mgmt/MgmtCoreTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MgmtCoreTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/MgmtCoreTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- MgmtCoreTest.java	10 Nov 2006 02:48:45 -0000	1.7
  +++ MgmtCoreTest.java	30 Dec 2006 17:49:57 -0000	1.8
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.interceptors.CacheMgmtInterceptor;
   
  @@ -15,7 +15,7 @@
    * Simple functional tests for CacheMgmtInterceptor
    *
    * @author Jerry Gauthier
  - * @version $Id: MgmtCoreTest.java,v 1.7 2006/11/10 02:48:45 bstansberry Exp $
  + * @version $Id: MgmtCoreTest.java,v 1.8 2006/12/30 17:49:57 msurtani Exp $
    */
   public class MgmtCoreTest extends TestCase
   {
  @@ -24,12 +24,12 @@
      private static final String POPULATION = "population";
      private static final String AREA = "area";
   
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
   
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setExposeManagementStatistics(true);
         cache.create();
  
  
  
  1.9       +9 -9      JBossCache/tests/functional/org/jboss/cache/mgmt/InvalidationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvalidationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/InvalidationTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- InvalidationTest.java	10 Nov 2006 02:48:45 -0000	1.8
  +++ InvalidationTest.java	30 Dec 2006 17:49:57 -0000	1.9
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.interceptors.InvalidationInterceptor;
  @@ -16,7 +16,7 @@
    * Simple functional tests for InvalidationInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: InvalidationTest.java,v 1.8 2006/11/10 02:48:45 bstansberry Exp $
  + * @version $Id: InvalidationTest.java,v 1.9 2006/12/30 17:49:57 msurtani Exp $
    */
   public class InvalidationTest extends TestCase
   {
  @@ -26,8 +26,8 @@
      private static final String POPULATION = "population";
      private static final String AREA = "area";
   
  -   TreeCache cache1 = null;
  -   TreeCache cache2 = null;
  +   CacheImpl cache1 = null;
  +   CacheImpl cache2 = null;
   
      protected void setUp() throws Exception
      {
  @@ -109,7 +109,7 @@
   
      }
   
  -   private void loadCache1(TreeCache cache) throws Exception
  +   private void loadCache1(CacheImpl cache) throws Exception
      {
         cache.put("Europe", new HashMap());
         cache.put("Europe/Austria", new HashMap());
  @@ -126,7 +126,7 @@
   
      }
   
  -   private void loadCache2(TreeCache cache) throws Exception
  +   private void loadCache2(CacheImpl cache) throws Exception
      {
         cache.put("Europe", new HashMap());
         cache.put("Europe/Austria", new HashMap());
  @@ -142,9 +142,9 @@
   
      }
   
  -   private TreeCache createCache(String clusterName) throws Exception
  +   private CacheImpl createCache(String clusterName) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         XmlConfigurationParser parser = new XmlConfigurationParser();
         Configuration c = parser.parseFile("META-INF/invalidationSync-service.xml");
         cache.setConfiguration(c);
  @@ -156,7 +156,7 @@
         return cache;
      }
   
  -   private InvalidationInterceptor getInvalidationInterceptor(TreeCache cache)
  +   private InvalidationInterceptor getInvalidationInterceptor(CacheImpl cache)
      {
         List interceptors = cache.getInterceptors();
         if (interceptors.isEmpty())
  
  
  
  1.9       +11 -11    JBossCache/tests/functional/org/jboss/cache/mgmt/TxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/TxTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- TxTest.java	10 Nov 2006 02:48:45 -0000	1.8
  +++ TxTest.java	30 Dec 2006 17:49:57 -0000	1.9
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.interceptors.TxInterceptor;
  @@ -17,7 +17,7 @@
    * Simple functional tests for TxInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: TxTest.java,v 1.8 2006/11/10 02:48:45 bstansberry Exp $
  + * @version $Id: TxTest.java,v 1.9 2006/12/30 17:49:57 msurtani Exp $
    */
   public class TxTest extends TestCase
   {
  @@ -27,8 +27,8 @@
      private static final String POPULATION = "population";
      private static final String AREA = "area";
   
  -   TreeCache cache1 = null;
  -   TreeCache cache2 = null;
  +   CacheImpl cache1 = null;
  +   CacheImpl cache2 = null;
   
      protected void setUp() throws Exception
      {
  @@ -134,7 +134,7 @@
         assertEquals("Cache2 Tx Rollbacks error after reset: ", new Long(0), new Long(tx2.getRollbacks()));
      }
   
  -   private void loadCacheNoTx(TreeCache cache) throws Exception
  +   private void loadCacheNoTx(CacheImpl cache) throws Exception
      {
         cache.put("Europe", new HashMap());
         cache.put("Europe/Austria", new HashMap());
  @@ -150,7 +150,7 @@
         cache.put("Europe/Albania", albania);
      }
   
  -   private void loadCacheTxCommit(TreeCache cache, TransactionManager tm) throws Exception
  +   private void loadCacheTxCommit(CacheImpl cache, TransactionManager tm) throws Exception
      {
         tm.begin();
   
  @@ -167,7 +167,7 @@
         tm.commit();
      }
   
  -   private void loadCacheTxCommit2(TreeCache cache, TransactionManager tm) throws Exception
  +   private void loadCacheTxCommit2(CacheImpl cache, TransactionManager tm) throws Exception
      {
         tm.begin();
   
  @@ -188,7 +188,7 @@
         tm.commit();
      }
   
  -   private void loadCacheTxRollback(TreeCache cache, TransactionManager tm) throws Exception
  +   private void loadCacheTxRollback(CacheImpl cache, TransactionManager tm) throws Exception
      {
         tm.begin();
   
  @@ -205,9 +205,9 @@
         tm.rollback();
      }
   
  -   private TreeCache createCache(String clusterName) throws Exception
  +   private CacheImpl createCache(String clusterName) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
         cache.getConfiguration().setUseRegionBasedMarshalling(false);
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
  @@ -218,7 +218,7 @@
         return cache;
      }
   
  -   private TxInterceptor getTxInterceptor(TreeCache cache)
  +   private TxInterceptor getTxInterceptor(CacheImpl cache)
      {
         List interceptors = cache.getInterceptors();
         if (interceptors.isEmpty())
  
  
  
  1.15      +7 -7      JBossCache/tests/functional/org/jboss/cache/mgmt/NotificationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NotificationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/NotificationTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- NotificationTest.java	16 Nov 2006 14:14:11 -0000	1.14
  +++ NotificationTest.java	30 Dec 2006 17:49:57 -0000	1.15
  @@ -1,14 +1,14 @@
   package org.jboss.cache.mgmt;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.interceptors.CacheMgmtInterceptor;
  -import org.jboss.cache.jmx.JmxUtil;
   import org.jboss.cache.jmx.Cache;
  +import org.jboss.cache.jmx.JmxUtil;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.xml.XmlHelper;
   import org.w3c.dom.Element;
  @@ -24,7 +24,7 @@
    * Functional tests for CacheMgmtInterceptor broadcast of cache event notifications
    *
    * @author Jerry Gauthier
  - * @version $Id: NotificationTest.java,v 1.14 2006/11/16 14:14:11 msurtani Exp $
  + * @version $Id: NotificationTest.java,v 1.15 2006/12/30 17:49:57 msurtani Exp $
    */
   public class NotificationTest extends TestCase
   {
  @@ -58,7 +58,7 @@
   
      private MBeanServer m_server;
   
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      boolean optimistic = false;
   
      protected void setUp() throws Exception
  @@ -68,7 +68,7 @@
         cache = createCache(CLUSTER_NAME);
         // bind manually for now.
         ObjectName mgmt = new ObjectName(JmxUtil.PREFIX + cache.getConfiguration().getClusterName() + MGMT_SERVICE);
  -      Cache cacheMBean = new Cache(cache.getCacheSPI());
  +      Cache cacheMBean = new Cache(cache);
   
         m_server.registerMBean(cacheMBean, mgmt);
      }
  @@ -156,9 +156,9 @@
         assertTrue("Expected ViewChange notification", m_viewChange);
      }
   
  -   private TreeCache createCache(String clusterName) throws Exception
  +   private CacheImpl createCache(String clusterName) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig("location=" + getTempDir()));
  
  
  
  1.10      +8 -8      JBossCache/tests/functional/org/jboss/cache/mgmt/CacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/CacheLoaderTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- CacheLoaderTest.java	10 Nov 2006 02:48:45 -0000	1.9
  +++ CacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.10
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -21,7 +21,7 @@
    * Simple functional tests for CacheLoaderInterceptor and CacheStoreInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: CacheLoaderTest.java,v 1.9 2006/11/10 02:48:45 bstansberry Exp $
  + * @version $Id: CacheLoaderTest.java,v 1.10 2006/12/30 17:49:57 msurtani Exp $
    */
   public class CacheLoaderTest extends TestCase
   {
  @@ -31,7 +31,7 @@
      private static final String AREA = "area";
      private static final String EUROPE_NODE = "Europe";
   
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
   
      protected void setUp() throws Exception
      {
  @@ -171,7 +171,7 @@
         assertEquals("CacheLoaderStores count error after reset: ", new Long(0), new Long(store.getCacheLoaderStores()));
      }
   
  -   private void loadCache(TreeCache cache) throws Exception
  +   private void loadCache(CacheImpl cache) throws Exception
      {
         cache.put(EUROPE_NODE, new HashMap());
         cache.put("Europe/Austria", new HashMap());
  @@ -200,9 +200,9 @@
   
      }
   
  -   private TreeCache createCache() throws Exception
  +   private CacheImpl createCache() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig("location=" + getTempDir()));
         cache.getConfiguration().setExposeManagementStatistics(true);
  @@ -211,7 +211,7 @@
         return cache;
      }
   
  -   private CacheLoaderInterceptor getCacheLoaderInterceptor(TreeCache cache)
  +   private CacheLoaderInterceptor getCacheLoaderInterceptor(CacheImpl cache)
      {
         List interceptors = cache.getInterceptors();
         if (interceptors.isEmpty())
  @@ -226,7 +226,7 @@
         return null;
      }
   
  -   private CacheStoreInterceptor getCacheStoreInterceptor(TreeCache cache)
  +   private CacheStoreInterceptor getCacheStoreInterceptor(CacheImpl cache)
      {
         List interceptors = cache.getInterceptors();
         if (interceptors.isEmpty())
  
  
  
  1.8       +8 -8      JBossCache/tests/functional/org/jboss/cache/mgmt/PassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/PassivationTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- PassivationTest.java	10 Nov 2006 02:48:45 -0000	1.7
  +++ PassivationTest.java	30 Dec 2006 17:49:57 -0000	1.8
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -21,7 +21,7 @@
    * Simple functional tests for ActivationInterceptor and PassivationInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: PassivationTest.java,v 1.7 2006/11/10 02:48:45 bstansberry Exp $
  + * @version $Id: PassivationTest.java,v 1.8 2006/12/30 17:49:57 msurtani Exp $
    */
   public class PassivationTest extends TestCase
   {
  @@ -31,7 +31,7 @@
      private static final String AREA = "area";
      private static final String EUROPE_NODE = "Europe";
   
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
   
      protected void setUp() throws Exception
      {
  @@ -196,7 +196,7 @@
         assertEquals("Passivations count error: ", new Long(0), new Long(pass.getPassivations()));
      }
   
  -   private void loadCache(TreeCache cache) throws Exception
  +   private void loadCache(CacheImpl cache) throws Exception
      {
         cache.put(EUROPE_NODE, new HashMap());
         cache.put("Europe/Austria", new HashMap());
  @@ -224,9 +224,9 @@
         cache.put("Europe/Hungary", hungary);
      }
   
  -   private TreeCache createCache() throws Exception
  +   private CacheImpl createCache() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         Configuration c = new Configuration();
         c.setCacheMode("LOCAL");
         c.setCacheLoaderConfig(getCacheLoaderConfig("location=" + getTempDir()));
  @@ -237,7 +237,7 @@
         return cache;
      }
   
  -   private ActivationInterceptor getActivationInterceptor(TreeCache cache)
  +   private ActivationInterceptor getActivationInterceptor(CacheImpl cache)
      {
         List interceptors = cache.getInterceptors();
         if (interceptors.isEmpty())
  @@ -252,7 +252,7 @@
         return null;
      }
   
  -   private PassivationInterceptor getPassivationInterceptor(TreeCache cache)
  +   private PassivationInterceptor getPassivationInterceptor(CacheImpl cache)
      {
         List interceptors = cache.getInterceptors();
         if (interceptors.isEmpty())
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:57 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1H0iLF-0008Nw-Dv@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:57

  Modified:    tests/functional/org/jboss/cache/marshall       
                        RegionManagerTest.java AsyncReplTest.java
                        SyncReplTest.java ActiveInactiveTest.java
                        ReplicateToInactiveRegionTest.java LocalTest.java
                        RedeploymentEmulationTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.7       +2 -2      JBossCache/tests/functional/org/jboss/cache/marshall/RegionManagerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionManagerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/RegionManagerTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- RegionManagerTest.java	15 Nov 2006 23:48:32 -0000	1.6
  +++ RegionManagerTest.java	30 Dec 2006 17:49:57 -0000	1.7
  @@ -1,10 +1,10 @@
   package org.jboss.cache.marshall;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.TreeCache;
   
   import java.util.ArrayList;
   import java.util.Collections;
  @@ -21,7 +21,7 @@
   
      public void setUp() throws Exception
      {
  -      r = new RegionManager(new TreeCache());
  +      r = new RegionManager(new CacheImpl());
      }
   
      public void tearDown() throws Exception
  
  
  
  1.13      +30 -28    JBossCache/tests/functional/org/jboss/cache/marshall/AsyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/AsyncReplTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- AsyncReplTest.java	5 Dec 2006 23:07:25 -0000	1.12
  +++ AsyncReplTest.java	30 Dec 2006 17:49:57 -0000	1.13
  @@ -12,8 +12,8 @@
   import junit.framework.Test;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.marshall.data.Address;
   import org.jboss.cache.marshall.data.Person;
  @@ -29,11 +29,11 @@
    * Test marshalling for async mode.
    *
    * @author Ben Wang
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.13 $
    */
   public class AsyncReplTest extends RegionBasedMarshallingTestBase
   {
  -   TreeCache cache1, cache2;
  +   CacheImpl cache1, cache2;
      String props = null;
      Person ben_;
      Address addr_;
  @@ -57,19 +57,19 @@
         ben_.setAddress(addr_);
   
         // Pause to give caches time to see each other
  -      TestingUtil.blockUntilViewsReceived(new TreeCache[]{cache1, cache2}, 60000);
  +      TestingUtil.blockUntilViewsReceived(new CacheImpl[]{cache1, cache2}, 60000);
      }
   
  -   private TreeCache createCache(String name) throws Exception
  +   private CacheImpl createCache(String name) throws Exception
      {
  -      TreeCache tree = new TreeCache();
  -      tree.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  -      tree.getConfiguration().setClusterName(name);
  +      CacheImpl cache = new CacheImpl();
  +      cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  +      cache.getConfiguration().setClusterName(name);
         // Use marshaller
  -      tree.getConfiguration().setUseRegionBasedMarshalling(true);
  -      tree.create();
  -      tree.start();
  -      return tree;
  +      cache.getConfiguration().setUseRegionBasedMarshalling(true);
  +      cache.create();
  +      cache.start();
  +      return cache;
      }
   
      public void tearDown() throws Exception
  @@ -180,7 +180,8 @@
            assertFalse("cache2 deserialized with scoped classloader", ben2 instanceof Person);
            assertFalse("cache2 deserialized with cache2 classloader", scopedBen1.equals(ben2));
            assertEquals("scopedBen deserialized properly", scopedBen2, ben2);
  -      } catch (Exception ex)
  +      }
  +      catch (Exception ex)
         {
            fail("Test fails with exception " + ex);
         }
  @@ -284,15 +285,16 @@
         {
            Object val = cache2.get(new Fqn(base, custom2), "key");
            assertEquals("value", val);
  -      } catch (Exception ex)
  +      }
  +      catch (Exception ex)
         {
  -         fail("Test fails with exception " +ex);
  +         fail("Test fails with exception " + ex);
         }      
      }
   
      Transaction beginTransaction() throws SystemException, NotSupportedException 
      {
  -      DummyTransactionManager mgr=DummyTransactionManager.getInstance();
  +      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
  
  
  
  1.14      +10 -10    JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/SyncReplTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- SyncReplTest.java	18 Dec 2006 12:27:52 -0000	1.13
  +++ SyncReplTest.java	30 Dec 2006 17:49:57 -0000	1.14
  @@ -11,8 +11,8 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.marshall.data.Address;
  @@ -30,11 +30,11 @@
    * Test case for marshalling using Sync mode.
    *
    * @author Ben Wang
  - * @version $Revision: 1.13 $
  + * @version $Revision: 1.14 $
    */
   public class SyncReplTest extends RegionBasedMarshallingTestBase
   {
  -   TreeCache cache1, cache2;
  +   CacheImpl cache1, cache2;
      String props = null;
      Person ben_;
      Address addr_;
  @@ -57,23 +57,23 @@
         ben_.setAddress(addr_);
   
         // Pause to give caches time to see each other
  -      TestingUtil.blockUntilViewsReceived(new TreeCache[]{cache1, cache2}, 60000);
  +      TestingUtil.blockUntilViewsReceived(new CacheImpl[]{cache1, cache2}, 60000);
      }
   
  -   private TreeCache createCache(String name) throws Exception
  +   private CacheImpl createCache(String name) throws Exception
      {
  -      TreeCache tree = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
   
         XmlConfigurationParser parser = new XmlConfigurationParser();
         Configuration c = parser.parseFile("META-INF/replSync-service.xml");
  -      tree.setConfiguration(c);
  +      cache.setConfiguration(c);
   
         c.setClusterName(name);
         // Use marshaller
         c.setUseRegionBasedMarshalling(true);
  -      tree.create();
  -      tree.start();
  -      return tree;
  +      cache.create();
  +      cache.start();
  +      return cache;
      }
   
      public void tearDown() throws Exception
  
  
  
  1.12      +3 -3      JBossCache/tests/functional/org/jboss/cache/marshall/ActiveInactiveTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActiveInactiveTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/ActiveInactiveTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- ActiveInactiveTest.java	15 Nov 2006 23:48:32 -0000	1.11
  +++ ActiveInactiveTest.java	30 Dec 2006 17:49:57 -0000	1.12
  @@ -8,9 +8,9 @@
   package org.jboss.cache.marshall;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.Version;
   
   import java.lang.reflect.Method;
  @@ -24,13 +24,13 @@
   public class ActiveInactiveTest extends TestCase
   {
      RegionManager rman;
  -   TreeCache c;
  +   CacheImpl c;
   
      @Override
      protected void setUp() throws Exception
      {
         super.setUp();
  -      c = new TreeCache();
  +      c = new CacheImpl();
         c.getConfiguration().setUseRegionBasedMarshalling(true);
         c.getConfiguration().setFetchInMemoryState(false);
         c.start();
  
  
  
  1.2       +7 -7      JBossCache/tests/functional/org/jboss/cache/marshall/ReplicateToInactiveRegionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicateToInactiveRegionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/ReplicateToInactiveRegionTest.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ReplicateToInactiveRegionTest.java	16 Nov 2006 16:51:53 -0000	1.1
  +++ ReplicateToInactiveRegionTest.java	30 Dec 2006 17:49:57 -0000	1.2
  @@ -1,18 +1,18 @@
   package org.jboss.cache.marshall;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.misc.TestingUtil;
   
   public class ReplicateToInactiveRegionTest extends TestCase
   {
  -   TreeCache[] caches;
  +   CacheImpl[] caches;
   
      protected void setUp() throws Exception
      {
         super.setUp();
  -      caches = new TreeCache[]{createCache(), createCache()};
  +      caches = new CacheImpl[]{createCache(), createCache()};
         TestingUtil.blockUntilViewsReceived(caches, 10000);
      }
   
  @@ -24,14 +24,14 @@
         caches = null;
      }
   
  -   private void destroyCache(TreeCache c)
  +   private void destroyCache(CacheImpl c)
      {
         c.stop();
      }
   
  -   private TreeCache createCache() throws Exception
  +   private CacheImpl createCache() throws Exception
      {
  -      TreeCache c = new TreeCache();
  +      CacheImpl c = new CacheImpl();
         c.getConfiguration().setCacheMode("REPL_SYNC");
         c.getConfiguration().setUseRegionBasedMarshalling(true);
         c.start();
  
  
  
  1.11      +4 -4      JBossCache/tests/functional/org/jboss/cache/marshall/LocalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/LocalTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- LocalTest.java	6 Sep 2006 15:30:58 -0000	1.10
  +++ LocalTest.java	30 Dec 2006 17:49:57 -0000	1.11
  @@ -2,8 +2,8 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.marshall.data.Debug;
  @@ -18,11 +18,11 @@
    * Simple functional tests for LegacyTreeCacheMarshaller
    *
    * @author Ben Wang
  - * @version $Id: LocalTest.java,v 1.10 2006/09/06 15:30:58 msurtani Exp $
  + * @version $Id: LocalTest.java,v 1.11 2006/12/30 17:49:57 msurtani Exp $
    */
   public class LocalTest extends RegionBasedMarshallingTestBase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      Transaction tx = null;
      final Fqn FQN = Fqn.fromString("/myNode");
      final String KEY = "key";
  @@ -33,7 +33,7 @@
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
  
  
  
  1.4       +2 -4      JBossCache/tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RedeploymentEmulationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- RedeploymentEmulationTest.java	20 Dec 2006 13:16:27 -0000	1.3
  +++ RedeploymentEmulationTest.java	30 Dec 2006 17:49:57 -0000	1.4
  @@ -8,9 +8,9 @@
   
   import junit.framework.TestCase;
   import org.jboss.cache.Cache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jgroups.Global;
   
  @@ -35,9 +35,7 @@
   
      protected void setUp() throws Exception
      {
  -      TreeCache tc = new TreeCache();
  -
  -      cache = tc.getCacheSPI();
  +      cache = new CacheImpl();
   
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         cache.getConfiguration().setUseRegionBasedMarshalling(true);
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:57 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/factories      ...
Message-ID: <E1H0iLF-0008OF-Iw@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:57

  Modified:    src/org/jboss/cache/factories      NodeFactory.java
                        CacheFactoryTest.java DefaultCacheFactory.java
                        CacheFactory.java InterceptorChainFactory.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.16      +35 -35    JBossCache/src/org/jboss/cache/factories/NodeFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/factories/NodeFactory.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- NodeFactory.java	20 Nov 2006 03:53:54 -0000	1.15
  +++ NodeFactory.java	30 Dec 2006 17:49:57 -0000	1.16
  @@ -6,34 +6,32 @@
    */
   package org.jboss.cache.factories;
   
  -import java.util.Map;
  -
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.NodeImpl;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.Cache;
  +import org.jboss.cache.NodeSPI;
  +import org.jboss.cache.UnversionedNode;
  +import org.jboss.cache.VersionedNode;
   import org.jboss.cache.optimistic.DataVersion;
   import org.jboss.cache.optimistic.TransactionWorkspace;
   import org.jboss.cache.optimistic.WorkspaceNode;
   import org.jboss.cache.optimistic.WorkspaceNodeImpl;
   
  +import java.util.Map;
  +
   /**
    * A factory that generates nodes.
  - * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    *
  + * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
   public class NodeFactory
   {
      private static NodeFactory _singleton;
   
  -   public static final byte NODE_TYPE_TREENODE = 1;
  -
  -   public static final byte NODE_TYPE_WORKSPACE_NODE = 2;
  -
  -   public static final byte NODE_TYPE_OPTIMISTIC_NODE = 3;
  +   public enum NodeType
  +   {
  +      UNVERSIONED_NODE, VERSIONED_NODE, WORKSPACE_NODE;
  +   }
   
      /**
       * private empty ctor
  @@ -44,6 +42,7 @@
   
      /**
       * Singleton accessor
  +    *
       * @return a singleton instance of the NodeFactory
       */
      public static NodeFactory getInstance()
  @@ -54,9 +53,9 @@
      }
   
      /**
  -    * Creates a new {@link DataNode} instance.
  +    * Creates a new {@link Node} instance.
       * 
  -    * @param nodeType  either {@link #NODE_TYPE_TREENODE} or {@link #NODE_TYPE_TREENODE}
  +    * @param nodeType  either {@link org.jboss.cache.factories.NodeFactory.NodeType#UNVERSIONED_NODE} or {@link org.jboss.cache.factories.NodeFactory.NodeType#VERSIONED_NODE}
       * @param childName the new node's name
       * @param fqn       the new node's Fqn
       * @param parent    the new node's parent
  @@ -66,19 +65,18 @@
       *                  <code>false</code> if param <code>data</code>'s contents
       *                  should be copied into the new node's data field.
       * @param cache     the cache to which the new node will be added
  -    * 
       * @return  the new node
       */
  -   public DataNode createDataNode(byte nodeType, Object childName, Fqn fqn, Node parent, Map data, boolean mapSafe,
  +   public Node createDataNode(NodeType nodeType, Object childName, Fqn fqn, Node parent, Map data, boolean mapSafe,
            DataVersion version, CacheSPI cache)
      {
         switch (nodeType)
         {
  -         case NODE_TYPE_TREENODE :
  -            return new NodeImpl(childName, fqn, data, mapSafe, cache);
  -         case NODE_TYPE_OPTIMISTIC_NODE :
  -            return new OptimisticTreeNode(childName, fqn, parent, data, cache);
  -         default :
  +         case UNVERSIONED_NODE:
  +            return new UnversionedNode(childName, fqn, data, mapSafe, cache);
  +         case VERSIONED_NODE:
  +            return new VersionedNode(childName, fqn, parent, data, cache);
  +         default:
               throw new IllegalArgumentException();
         }
      }
  @@ -86,8 +84,9 @@
      /**
       * Creates a node of the same type of the node passed in as a template.  The template passed in is entirely unaffected
       * and is not related in any way to the new node except that they will share the same type.
  -    * @deprecated - passing in childName and fqn shuld be redundant.
  +    *
       * @return TreeNode
  +    * @deprecated - passing in childName and fqn shuld be redundant.
       */
      public Node createNode(Object childName, Fqn fqn, Node parent, Map data, CacheSPI cache)
      {
  @@ -101,6 +100,7 @@
   
      /**
       * same as above, passing in an explicit version
  +    *
       * @deprecated - passing in childName and fqn shuld be redundant.
       */
      public Node createNodeOfType(Node template, Object childName, Fqn fqn, Node parent, Map data, CacheSPI cache,
  @@ -114,24 +114,24 @@
            return createWorkspaceNode(dataNodeParent, workspace);
         }
   
  -      if (parent instanceof DataNode)
  +      if (parent instanceof NodeSPI)
         {
  -         if (template instanceof OptimisticTreeNode)
  -            return createDataNode(NODE_TYPE_OPTIMISTIC_NODE, childName, fqn, parent, data, false, version, cache);
  -         if (template instanceof NodeImpl)
  -            return createDataNode(NODE_TYPE_TREENODE, childName, fqn, parent, data, false, null, cache);
  +         if (template instanceof VersionedNode)
  +            return createDataNode(NodeType.VERSIONED_NODE, childName, fqn, parent, data, false, version, cache);
  +         if (template instanceof UnversionedNode)
  +            return createDataNode(NodeType.UNVERSIONED_NODE, childName, fqn, parent, data, false, null, cache);
         }
         return null;
      }
   
      public WorkspaceNode createWorkspaceNode(Node dataNode, TransactionWorkspace workspace)
      {
  -      return new WorkspaceNodeImpl(dataNode, workspace);
  +      return new WorkspaceNodeImpl((NodeSPI) dataNode, workspace);
      }
   
  -   public DataNode createRootDataNode(byte type, CacheSPI cache)
  +   public NodeSPI createRootDataNode(NodeType type, CacheSPI cache)
      {
  -      return (DataNode) this.createDataNode(type, null, Fqn.ROOT, null, null, false, null, cache);
  +      return (NodeSPI) createDataNode(type, null, Fqn.ROOT, null, null, false, null, cache);
      }
   
   }
  
  
  
  1.5       +76 -77    JBossCache/src/org/jboss/cache/factories/CacheFactoryTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheFactoryTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/factories/CacheFactoryTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- CacheFactoryTest.java	31 Oct 2006 06:57:27 -0000	1.4
  +++ CacheFactoryTest.java	30 Dec 2006 17:49:57 -0000	1.5
  @@ -7,24 +7,23 @@
   package org.jboss.cache.factories;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCacheProxyImpl;
  -import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
  +import org.jboss.cache.lock.IsolationLevel;
   
   /**
  - *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
   public class CacheFactoryTest extends TestCase
   {
       Configuration expected;
       String configFile = "META-INF/replSync-service.xml";
  -    private TreeCacheProxyImpl cache;
  +   private CacheImpl cache;
   
       protected void setUp()
       {
           XmlConfigurationParser parser = new XmlConfigurationParser();
  -        expected = parser.parseFile( configFile );
  +      expected = parser.parseFile(configFile);
       }
   
       protected void tearDown()
  @@ -37,7 +36,7 @@
   
       public void testFromConfigFileStarted()
       {
  -        cache = (TreeCacheProxyImpl) DefaultCacheFactory.createCache(configFile);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache(configFile);
           assertEquals(expected, cache.getConfiguration());
   
           assertTrue("Should have started", cache.isStarted());
  @@ -46,7 +45,7 @@
   
       public void testFromConfigFileUnstarted()
       {
  -        cache = (TreeCacheProxyImpl) DefaultCacheFactory.createCache(configFile, false);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache(configFile, false);
           assertEquals(expected, cache.getConfiguration());
   
           assertFalse("Should not have started", cache.isStarted());
  @@ -56,7 +55,7 @@
   
       public void testFromConfigObjStarted()
       {
  -        cache = (TreeCacheProxyImpl) DefaultCacheFactory.createCache(expected);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache(expected);
   
           assertTrue("Should have started", cache.isStarted());
   
  @@ -65,7 +64,7 @@
   
       public void testFromConfigObjUnstarted()
       {
  -        cache = (TreeCacheProxyImpl) DefaultCacheFactory.createCache(expected, false);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache(expected, false);
   
           assertFalse("Should not have started", cache.isStarted());
   
  @@ -84,7 +83,7 @@
   
       public void testLifecycle() throws Exception
       {
  -        cache = (TreeCacheProxyImpl) DefaultCacheFactory.createCache(expected, false);
  +      cache = (CacheImpl) DefaultCacheFactory.createCache(expected, false);
           assertFalse(cache.isStarted());
           cache.start();
           assertTrue(cache.isStarted());
  
  
  
  1.12      +4 -4      JBossCache/src/org/jboss/cache/factories/DefaultCacheFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultCacheFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/factories/DefaultCacheFactory.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- DefaultCacheFactory.java	31 Oct 2006 06:57:27 -0000	1.11
  +++ DefaultCacheFactory.java	30 Dec 2006 17:49:57 -0000	1.12
  @@ -7,7 +7,7 @@
   package org.jboss.cache.factories;
   
   import org.jboss.cache.Cache;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.ConfigurationException;
   
  @@ -44,14 +44,14 @@
      {
         try
         {
  -         TreeCache cache = new TreeCache();
  +         CacheImpl cache = new CacheImpl();
            cache.setConfiguration(configuration);
            if (start) cache.start();
  -         return cache.getCacheSPI();
  +         return cache;
         }
         catch (Exception e)
         {
  -         if (e instanceof ConfigurationException) throw(ConfigurationException) e;
  +         if (e instanceof ConfigurationException) throw (ConfigurationException) e;
            throw new RuntimeException(e);
         }
      }
  
  
  
  1.4       +0 -0      JBossCache/src/org/jboss/cache/factories/CacheFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  
  
  
  1.35      +11 -14    JBossCache/src/org/jboss/cache/factories/InterceptorChainFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InterceptorChainFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/factories/InterceptorChainFactory.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- InterceptorChainFactory.java	15 Nov 2006 15:16:40 -0000	1.34
  +++ InterceptorChainFactory.java	30 Dec 2006 17:49:57 -0000	1.35
  @@ -8,8 +8,8 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.interceptors.*;
   import org.jboss.cache.loader.CacheLoaderManager;
   import org.jboss.cache.util.Util;
  @@ -18,7 +18,7 @@
   import java.util.List;
   
   /**
  - * Factory class that builds an interceptor chain based on TreeCache config.
  + * Factory class that builds an interceptor chain based on CacheImpl config.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  @@ -26,7 +26,7 @@
   {
      private static Log log = LogFactory.getLog(InterceptorChainFactory.class);
   
  -   public Interceptor buildInterceptorChain(TreeCache cache) throws IllegalAccessException, ClassNotFoundException, InstantiationException
  +   public Interceptor buildInterceptorChain(CacheImpl cache) throws IllegalAccessException, ClassNotFoundException, InstantiationException
      {
         if (cache.getConfiguration().isNodeLockingOptimistic())
         {
  @@ -123,9 +123,8 @@
       * <p/>
       * CallInterceptor is always present at the top, the others may or may not be present
       */
  -   private Interceptor createPessimisticInterceptorChain(TreeCache treeCache) throws IllegalAccessException, InstantiationException, ClassNotFoundException
  +   private Interceptor createPessimisticInterceptorChain(CacheImpl cache) throws IllegalAccessException, InstantiationException, ClassNotFoundException
      {
  -      CacheSPI cache = treeCache.getCacheSPI();
         Interceptor call_interceptor = null;
         Interceptor lock_interceptor = null;
         Interceptor repl_interceptor = null;
  @@ -143,7 +142,7 @@
   
   
         call_interceptor = createInterceptor(CallInterceptor.class, cache);
  -      ((CallInterceptor) call_interceptor).setTreeCacheInstance(treeCache);
  +      ((CallInterceptor) call_interceptor).setTreeCacheInstance(cache);
   
         if (cache.getBuddyManager() != null)
         {
  @@ -358,9 +357,9 @@
            addInterceptor(first, lock_interceptor);
         }
   
  -      if (treeCache.getConfiguration().getEvictionConfig() != null && treeCache.getConfiguration().getEvictionConfig().isValidConfig())
  +      if (cache.getConfiguration().getEvictionConfig() != null && cache.getConfiguration().getEvictionConfig().isValidConfig())
         {
  -         eviction_interceptor = createInterceptor(treeCache.getEvictionInterceptorClass(), cache);
  +         eviction_interceptor = createInterceptor(cache.getEvictionInterceptorClass(), cache);
            if (first == null)
            {
               first = eviction_interceptor;
  @@ -388,10 +387,8 @@
         return setLastInterceptorPointer(first, call_interceptor);
      }
   
  -   private Interceptor createOptimisticInterceptorChain(TreeCache treeCache) throws IllegalAccessException, InstantiationException, ClassNotFoundException
  +   private Interceptor createOptimisticInterceptorChain(CacheImpl cache) throws IllegalAccessException, InstantiationException, ClassNotFoundException
      {
  -
  -      CacheSPI cache = treeCache.getCacheSPI();
         Interceptor txInterceptor = null, replicationInterceptor = null, lockInterceptor = null, validationInterceptor = null;
         Interceptor createIfNotExistsInterceptor = null, nodeInterceptor = null, invokerInterceptor = null, activationInterceptor = null;
         Interceptor passivationInterceptor = null, cacheLoaderInterceptor = null, cacheStoreInterceptor = null, first = null;
  @@ -443,11 +440,11 @@
         nodeInterceptor = createInterceptor(OptimisticNodeInterceptor.class, cache);
   
         invokerInterceptor = createInterceptor(CallInterceptor.class, cache);
  -      ((CallInterceptor) invokerInterceptor).setTreeCacheInstance(treeCache);
  +      ((CallInterceptor) invokerInterceptor).setTreeCacheInstance(cache);
   
  -      if (treeCache.getConfiguration().getEvictionConfig() != null && treeCache.getConfiguration().getEvictionConfig().isValidConfig())
  +      if (cache.getConfiguration().getEvictionConfig() != null && cache.getConfiguration().getEvictionConfig().isValidConfig())
         {
  -         evictionInterceptor = createInterceptor(treeCache.getEvictionInterceptorClass(), cache);
  +         evictionInterceptor = createInterceptor(cache.getEvictionInterceptorClass(), cache);
         }
   
         if (first == null) first = invocationCtxInterceptor;
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:57 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:57 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer     ...
Message-ID: <E1H0iLF-0008OV-Nb@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:57

  Modified:    src/org/jboss/cache/statetransfer    
                        StateTransferManager.java
                        DefaultStateTransferIntegrator.java
                        DefaultStateTransferGenerator.java
                        StateTransferFactory.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.20      +20 -20    JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferManager.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- StateTransferManager.java	21 Dec 2006 21:41:10 -0000	1.19
  +++ StateTransferManager.java	30 Dec 2006 17:49:57 -0000	1.20
  @@ -9,9 +9,9 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.loader.CacheLoaderManager;
   import org.jboss.cache.loader.NodeData;
  @@ -32,14 +32,14 @@
   
      public static final String PARTIAL_STATE_DELIMETER = "_PARTIAL_STATE_DELIMETER";
   
  -   private final TreeCache cache;
  +   private final CacheImpl cache;
   
  -   public StateTransferManager(TreeCache cache)
  +   public StateTransferManager(CacheImpl cache)
      {
         this.cache = cache;
      }
   
  -   public TreeCache getTreeCache()
  +   public CacheImpl getTreeCache()
      {
         return cache;
      }
  @@ -47,7 +47,7 @@
      /**
       * Writes the state for the portion of the tree named by <code>fqn</code> to 
       * the provided OutputStream.
  -    * 
  +    * <p/>
       * <p/>
       *
       * @param fqn            Fqn indicating the uppermost node in the
  @@ -98,21 +98,21 @@
         {
            out.writeBoolean(false);
            Exception e = null;
  -         if(!canProvideState)
  +         if (!canProvideState)
            {
  -            String exceptionMessage = "Cache instance at " + cache.getLocalAddress() + " cannot provide state for fqn " + fqn +".";
  +            String exceptionMessage = "Cache instance at " + cache.getLocalAddress() + " cannot provide state for fqn " + fqn + ".";
               
  -            if(marshaller.isInactive(fqn.toString()))
  +            if (marshaller.isInactive(fqn.toString()))
               {
                  exceptionMessage += " Region for fqn " + fqn + " is inactive.";
               }
  -            if(cache.findNode(fqn) == null)
  +            if (cache.findNode(fqn) == null)
               {
                  exceptionMessage += " There is no cache node at fqn " + fqn;
               }
               e = new CacheException(exceptionMessage);           
            }
  -         if(!fetchPersistentState && !fetchTransientState)
  +         if (!fetchPersistentState && !fetchTransientState)
            {
               e = new CacheException("Cache instance at " + cache.getLocalAddress() + " is not configured to provide state");
            }
  @@ -161,7 +161,7 @@
       */
      public void setState(ObjectInputStream in, Fqn targetRoot, ClassLoader cl) throws Exception
      {
  -      TreeCache cache = getTreeCache();
  +      CacheImpl cache = getTreeCache();
         Node target = cache.findNode(targetRoot);
         if (target == null)
         {
  @@ -171,7 +171,7 @@
            target = cache.findNode(targetRoot);
         }
         boolean hasState = in.readBoolean();
  -      if(hasState)
  +      if (hasState)
         {
            setState(in, target, cl);
         }
  
  
  
  1.10      +24 -24    JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferIntegrator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- DefaultStateTransferIntegrator.java	21 Dec 2006 21:41:10 -0000	1.9
  +++ DefaultStateTransferIntegrator.java	30 Dec 2006 17:49:57 -0000	1.10
  @@ -9,10 +9,10 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeNode;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.buddyreplication.BuddyManager;
   import org.jboss.cache.factories.NodeFactory;
   import org.jboss.cache.loader.CacheLoader;
  @@ -30,24 +30,24 @@
   
      protected Log log = LogFactory.getLog(getClass().getName());
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      private Fqn targetFqn;
   
      private NodeFactory factory;
   
  -   private byte nodeType;
  +   private NodeFactory.NodeType nodeType;
   
      private Set internalFqns;
   
  -   public DefaultStateTransferIntegrator(Fqn targetFqn, TreeCache cache)
  +   public DefaultStateTransferIntegrator(Fqn targetFqn, CacheImpl cache)
      {
         this.targetFqn = targetFqn;
         this.cache = cache;
         this.factory = NodeFactory.getInstance();
         this.nodeType = cache.getConfiguration().isNodeLockingOptimistic()
  -              ? NodeFactory.NODE_TYPE_OPTIMISTIC_NODE
  -              : NodeFactory.NODE_TYPE_TREENODE;
  +              ? NodeFactory.NodeType.VERSIONED_NODE
  +              : NodeFactory.NodeType.UNVERSIONED_NODE;
         this.internalFqns = cache.getInternalFqns();
      }
   
  @@ -87,7 +87,7 @@
               // Clear any existing state from the targetRoot
               log.warn("transient state integration failed, removing all children of " + target);
               target.clearData();
  -            ((TreeNode) target).removeChildren();
  +            target.getNodeSPI().removeChildren();
            }
   
            resetClassLoader(oldCL);
  @@ -161,7 +161,7 @@
         }
      }
   
  -   protected TreeCache getCache()
  +   protected CacheImpl getCache()
      {
         return cache;
      }
  @@ -171,7 +171,7 @@
         return factory;
      }
   
  -   protected byte getNodeType()
  +   protected NodeFactory.NodeType getNodeType()
      {
         return nodeType;
      }
  @@ -187,7 +187,7 @@
       */
      private void notifyAllNodesCreated(Node curr)
      {
  -      TreeNode n;
  +      Node n;
   
         if (curr == null) return;
         getCache().getNotifier().notifyNodeCreated(curr.getFqn(), true);
  @@ -195,7 +195,7 @@
         Set children = curr.getChildren();
         for (Iterator it = children.iterator(); it.hasNext();)
         {
  -         n = (TreeNode) it.next();
  +         n = (Node) it.next();
            notifyAllNodesCreated(n);
         }
      }
  @@ -224,7 +224,7 @@
      {
         Set retainedNodes = retainInternalNodes(target);
   
  -      ((TreeNode) target).removeChildren();
  +      target.getNodeSPI().removeChildren();
   
         // Read the first NodeData and integrate into our target     
         NodeData nd = readNode(in);
  @@ -293,8 +293,8 @@
   
            // We handle this NodeData.  Create a TreeNode and
            // integrate its data            
  -         Node target = factory.createDataNode(nodeType, name, fqn, parent, nd.getAttributes(), false, null, cache.getCacheSPI());
  -         ((TreeNode) parent).addChild(name, target);
  +         Node target = factory.createDataNode(nodeType, name, fqn, parent, nd.getAttributes(), false, null, cache);
  +         parent.getNodeSPI().addChild(name, target);
   
            // Recursively call, which will walk down the tree
            // and return the next NodeData that's a child of our parent
  @@ -312,7 +312,7 @@
            Fqn internalFqn = (Fqn) it.next();
            if (internalFqn.isChildOf(targetFqn))
            {
  -            TreeNode internalNode = getInternalNode(target, internalFqn);
  +            Node internalNode = getInternalNode(target, internalFqn);
               if (internalNode != null)
               {
                  result.add(internalNode);
  @@ -323,10 +323,10 @@
         return result;
      }
   
  -   private TreeNode getInternalNode(Node parent, Fqn internalFqn)
  +   private Node getInternalNode(Node parent, Fqn internalFqn)
      {
         Object name = internalFqn.get(parent.getFqn().size());
  -      TreeNode result = (TreeNode) parent.getChild(new Fqn(name));
  +      Node result = parent.getChild(new Fqn(name));
         if (result != null)
         {
            if (internalFqn.size() < result.getFqn().size())
  @@ -343,7 +343,7 @@
         Fqn rootFqn = root.getFqn();
         for (Iterator it = retainedNodes.iterator(); it.hasNext();)
         {
  -         TreeNode retained = (TreeNode) it.next();
  +         Node retained = (Node) it.next();
            if (retained.getFqn().isChildOf(rootFqn))
            {
               integrateRetainedNode(root, retained);
  @@ -351,17 +351,17 @@
         }
      }
   
  -   private void integrateRetainedNode(Node ancestor, TreeNode descendant)
  +   private void integrateRetainedNode(Node ancestor, Node descendant)
      {
         Fqn descFqn = descendant.getFqn();
         Fqn ancFqn = ancestor.getFqn();
         Object name = descFqn.get(ancFqn.size());
  -      TreeNode child = (TreeNode) ancestor.getChild(new Fqn(name));
  +      Node child = ancestor.getChild(new Fqn(name));
         if (ancFqn.size() == descFqn.size() + 1)
         {
            if (child == null)
            {
  -            ((TreeNode) ancestor).addChild(name, descendant);
  +            ancestor.getNodeSPI().addChild(name, descendant);
            }
            else
            {
  @@ -375,8 +375,8 @@
               // Missing level -- have to create empty node
               // This shouldn't really happen -- internal fqns should
               // be immediately under the root
  -            child = factory.createDataNode(nodeType, name, new Fqn(ancFqn, name), ancestor, null, true, null, cache.getCacheSPI());
  -            ((TreeNode) ancestor).addChild(name, child);
  +            child = factory.createDataNode(nodeType, name, new Fqn(ancFqn, name), ancestor, null, true, null, cache);
  +            ((NodeSPI) ancestor).addChild(name, child);
            }
   
            // Keep walking down the tree
  
  
  
  1.8       +7 -7      JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferGenerator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- DefaultStateTransferGenerator.java	21 Dec 2006 21:41:10 -0000	1.7
  +++ DefaultStateTransferGenerator.java	30 Dec 2006 17:49:57 -0000	1.8
  @@ -8,9 +8,9 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.Version;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.loader.NodeData;
  @@ -28,11 +28,11 @@
   
      private Log log = LogFactory.getLog(getClass().getName());
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      private Set internalFqns;
   
  -   protected DefaultStateTransferGenerator(TreeCache cache)
  +   protected DefaultStateTransferGenerator(CacheImpl cache)
      {
         this.cache = cache;
         this.internalFqns = cache.getInternalFqns();
  @@ -158,7 +158,7 @@
         // no-op in this base class      
      }
   
  -   protected TreeCache getTreeCache()
  +   protected CacheImpl getTreeCache()
      {
         return cache;
      }
  
  
  
  1.13      +22 -24    JBossCache/src/org/jboss/cache/statetransfer/StateTransferFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/StateTransferFactory.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- StateTransferFactory.java	12 Sep 2006 21:12:45 -0000	1.12
  +++ StateTransferFactory.java	30 Dec 2006 17:49:57 -0000	1.13
  @@ -6,19 +6,19 @@
    */
   package org.jboss.cache.statetransfer;
   
  -import java.io.IOException;
  -import java.io.ObjectInputStream;
  -
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.Version;
   
  +import java.io.IOException;
  +import java.io.ObjectInputStream;
  +
   /**
    * Factory class able to create {@link StateTransferGenerator} and 
    * {@link StateTransferIntegrator} instances.
    * 
    * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.13 $
    */
   public abstract class StateTransferFactory
   {
  @@ -28,13 +28,11 @@
       * Gets the StateTransferGenerator able to handle the given cache instance.
       * 
       * @param cache the cache
  -    * 
       * @return the {@link StateTransferGenerator}
  -    * 
       * @throws IllegalStateException if the cache's ReplicationVersion is < 2.0.0
       */
      public static StateTransferGenerator 
  -         getStateTransferGenerator(TreeCache cache)
  +   getStateTransferGenerator(CacheImpl cache)
      {
         short version = cache.getConfiguration().getReplicationVersion();
         
  @@ -46,7 +44,7 @@
            return new DefaultStateTransferGenerator(cache); // current default
      } 
   
  -   public static StateTransferIntegrator getStateTransferIntegrator(ObjectInputStream in, Fqn fqn, TreeCache treeCache)
  +   public static StateTransferIntegrator getStateTransferIntegrator(ObjectInputStream in, Fqn fqn, CacheImpl cache)
            throws Exception
      {
         short version = 0;      
  @@ -61,8 +59,8 @@
            {
               in.close();
            }
  -         catch(IOException ignored){}
  -         throw new IllegalStateException("Stream corrupted ",io);                         
  +         catch (IOException ignored) {}
  +         throw new IllegalStateException("Stream corrupted ", io);
         }
   
         // Compiler won't let me use a switch
  @@ -70,7 +68,7 @@
         if (version < RV_200 && version > 0) // <= 0 is actually a version > 15.31.63
            throw new IllegalStateException("State transfer with cache replication version < 2.0.0 not supported");
         else
  -         return new DefaultStateTransferIntegrator(fqn, treeCache); // current default
  +         return new DefaultStateTransferIntegrator(fqn, cache); // current default
      }      
              
   }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:55 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:55 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache ...
Message-ID: <E1H0iLD-0008N4-5s@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:55

  Modified:    src/org/jboss/cache                           Cache.java
                        RPCManager.java CacheSPI.java AbstractNode.java
                        Version.java ConsoleListener.java RegionImpl.java
                        TreeCacheView2.java RegionNotEmptyException.java
                        ReplicationQueue.java RegionManager.java
                        TransactionEntry.java NodeSPI.java
                        TreeCacheView.java Fqn.java Node.java
                        TransactionManagerLookup.java
  Added:       src/org/jboss/cache                          
                        VersionedNode.java CacheImpl.java
                        UnversionedNode.java
  Removed:     src/org/jboss/cache                          
                        OptimisticTreeNode.java TreeCacheProxyImpl.java
                        DataNode.java NodeImpl.java TreeNode.java
                        TreeCache.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.16      +4 -13     JBossCache/src/org/jboss/cache/Cache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Cache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Cache.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- Cache.java	15 Nov 2006 06:49:25 -0000	1.15
  +++ Cache.java	30 Dec 2006 17:49:54 -0000	1.16
  @@ -9,25 +9,23 @@
   import org.jboss.cache.config.Configuration;
   import org.jgroups.Address;
   
  -import javax.transaction.TransactionManager;
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
   
   /**
  - * Along with {@link Node}, this is the central construct of JBoss Cache.
  + * Along with {@link Node}, this is the central construct and basic client API of JBoss Cache and is used for
  + * cache-wide operations.
    * <p/>
    * The cache is constructed using a {@link org.jboss.cache.factories.CacheFactory}.
    * <p/>
  - * The cache is essentially a wrapper around the default root {@link Node}.  Basic operations on the cache are
  - * inherited from {@link Node}.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @see Node
    * @see org.jboss.cache.factories.CacheFactory
    * @since 2.0.0
    */
  -public interface Cache extends Node
  +public interface Cache
   {
      /**
       * Retrieves the configuration of this cache.
  @@ -191,13 +189,6 @@
      void destroy();
   
      /**
  -    * Retrieves a reference to a running {@link javax.transaction.TransactionManager}, if one is configured.
  -    *
  -    * @return a TransactionManager
  -    */
  -   TransactionManager getTransactionManager();
  -
  -   /**
       * Retrieves the current invocation context for the current invocation and cache instance.
       *
       * @see org.jboss.cache.InvocationContext
  
  
  
  1.5       +4 -4      JBossCache/src/org/jboss/cache/RPCManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RPCManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/RPCManager.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- RPCManager.java	29 Aug 2006 17:50:14 -0000	1.4
  +++ RPCManager.java	30 Dec 2006 17:49:54 -0000	1.5
  @@ -19,14 +19,14 @@
    */
   public class RPCManager
   {
  -   TreeCache c;
  +   CacheImpl c;
   
  -   private RPCManager(TreeCache c)
  +   private RPCManager(CacheImpl c)
      {
         this.c = c;
      }
   
  -   public static RPCManager getInstance(TreeCache c)
  +   public static RPCManager getInstance(CacheImpl c)
      {
         RPCManager rpcManager = c.getRpcManager();
         if (rpcManager == null)
  @@ -38,7 +38,7 @@
         return rpcManager;
      }
   
  -   // for now, we delegate RPC calls to deprecated methods in TreeCache.
  +   // for now, we delegate RPC calls to deprecated methods in CacheImpl.
   
      public List callRemoteMethods(List<Address> recipients, MethodCall methodCall, int mode, boolean excludeSelf, long timeout) throws Exception
      {
  
  
  
  1.23      +13 -2     JBossCache/src/org/jboss/cache/CacheSPI.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheSPI.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/CacheSPI.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- CacheSPI.java	27 Nov 2006 17:07:05 -0000	1.22
  +++ CacheSPI.java	30 Dec 2006 17:49:54 -0000	1.23
  @@ -17,11 +17,15 @@
   import org.jboss.cache.statetransfer.StateTransferManager;
   
   import javax.transaction.Transaction;
  +import javax.transaction.TransactionManager;
   import java.util.List;
   import java.util.Map;
   
   /**
  - * A more detailed interface to {@link Cache}, which is used when writing plugins for or extending JBoss Cache.
  + * A more detailed interface to {@link Cache}, which is used when writing plugins for or extending JBoss Cache.  A reference
  + * to this interface should only be obtained when it is passed in to your code, for example when you write an
  + * {@link Interceptor}, {@link CacheLoader} or {@link CacheListener}.  You should not attempt to directly cast a {@link Cache} instance
  + * to this interface, as in future, the implementation may not allow it.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @see NodeSPI
  @@ -31,6 +35,13 @@
   public interface CacheSPI extends Cache
   {
      /**
  +    * Retrieves a reference to a running {@link javax.transaction.TransactionManager}, if one is configured.
  +    *
  +    * @return a TransactionManager
  +    */
  +   TransactionManager getTransactionManager();
  +
  +   /**
       * @return an immutable {@link List} of {@link Interceptor}s configured for this cache.
       */
      List<Interceptor> getInterceptorChain();
  @@ -133,7 +144,7 @@
       *
       * @return a node if one exists or null
       */
  -   Node peek(Fqn fqn);
  +   NodeSPI peek(Fqn fqn);
   
      /**
       * Used with buddy replication's data gravitation interceptor
  
  
  
  1.24      +5 -5      JBossCache/src/org/jboss/cache/AbstractNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/AbstractNode.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- AbstractNode.java	14 Dec 2006 17:18:47 -0000	1.23
  +++ AbstractNode.java	30 Dec 2006 17:49:54 -0000	1.24
  @@ -6,14 +6,14 @@
   import java.util.Map;
   
   /**
  - * Base class for {@link NodeImpl}.
  + * Base class for {@link UnversionedNode}.
    *
    * @author manik
    */
  -public abstract class AbstractNode implements DataNode, NodeSPI
  +public abstract class AbstractNode implements Node
   {
      protected boolean deleted;
  -   protected Map<Object, AbstractNode> children;
  +   protected Map<Object, Node> children;
   
      public boolean isDeleted()
      {
  @@ -30,9 +30,9 @@
         deleted = marker;
         if (recursive && children != null)
         {
  -         for (AbstractNode child : children.values())
  +         for (Node child : children.values())
            {
  -            child.markAsDeleted(marker, true);
  +            ((AbstractNode) child).markAsDeleted(marker, true);
            }
         }
      }
  
  
  
  1.26      +3 -3      JBossCache/src/org/jboss/cache/Version.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Version.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Version.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- Version.java	21 Dec 2006 18:17:12 -0000	1.25
  +++ Version.java	30 Dec 2006 17:49:54 -0000	1.26
  @@ -3,17 +3,17 @@
   import java.util.StringTokenizer;
   
   /**
  - * Contains version information about this release of TreeCache.
  + * Contains version information about this release of CacheImpl.
    *
    * @author Bela Ban
  - * @version $Id: Version.java,v 1.25 2006/12/21 18:17:12 msurtani Exp $
  + * @version $Id: Version.java,v 1.26 2006/12/30 17:49:54 msurtani Exp $
    */
   public class Version
   {
      public static final String version = "2.0.0.ALPHA2";
      public static final String codename = "Habanero";
      public static byte[] version_id = {'0', '2', '0', '0', 'a'};
  -   public static final String cvs = "$Id: Version.java,v 1.25 2006/12/21 18:17:12 msurtani Exp $";
  +   public static final String cvs = "$Id: Version.java,v 1.26 2006/12/30 17:49:54 msurtani Exp $";
   
      private static final int MAJOR_SHIFT = 11;
      private static final int MINOR_SHIFT = 6;
  
  
  
  1.11      +4 -4      JBossCache/src/org/jboss/cache/ConsoleListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConsoleListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/ConsoleListener.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ConsoleListener.java	18 Oct 2006 11:07:54 -0000	1.10
  +++ ConsoleListener.java	30 Dec 2006 17:49:54 -0000	1.11
  @@ -22,7 +22,7 @@
    */
   public class ConsoleListener implements CacheListener
   {
  -   private TreeCache _cache;
  +   private CacheImpl _cache;
      private boolean _startCache;
   
      /**
  @@ -33,7 +33,7 @@
       *
       * @param cache the cache to monitor for replication events.
       */
  -   public ConsoleListener(TreeCache cache)
  +   public ConsoleListener(CacheImpl cache)
              throws Exception
      {
         this(cache, true, true);
  @@ -48,7 +48,7 @@
       * @param stopCache  indicates whether or not the cache should be stopped by
       *                   this class.
       */
  -   public ConsoleListener(TreeCache cache,
  +   public ConsoleListener(CacheImpl cache,
                             boolean startCache, boolean stopCache)
              throws Exception
      {
  @@ -364,7 +364,7 @@
   
         try
         {
  -         TreeCache cache = new TreeCache();
  +         CacheImpl cache = new CacheImpl();
   
            String configFileName = DEFAULT_CONFIG_FILE_NAME;
   
  
  
  
  1.16      +8 -8      JBossCache/src/org/jboss/cache/RegionImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/RegionImpl.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- RegionImpl.java	8 Dec 2006 18:49:17 -0000	1.15
  +++ RegionImpl.java	30 Dec 2006 17:49:54 -0000	1.16
  @@ -6,10 +6,6 @@
    */
   package org.jboss.cache;
   
  -import java.util.concurrent.BlockingQueue;
  -import java.util.concurrent.LinkedBlockingQueue;
  -import java.util.concurrent.TimeUnit;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.config.EvictionRegionConfig;
  @@ -19,6 +15,10 @@
   import org.jboss.cache.eviction.NodeEventType;
   import org.jboss.cache.util.Util;
   
  +import java.util.concurrent.BlockingQueue;
  +import java.util.concurrent.LinkedBlockingQueue;
  +import java.util.concurrent.TimeUnit;
  +
   /**
    * Default implementation of a {@link Region}
    *
  @@ -220,7 +220,7 @@
         {
            if (log.isTraceEnabled()) log.trace("Instantiating " + className);
            EvictionPolicy ep = (EvictionPolicy) Util.loadClass(className).newInstance();
  -         ep.configure(regionManager.treeCache);
  +         ep.configure(regionManager.cache);
            return ep;
         }
         catch (Exception e)
  
  
  
  1.18      +26 -26    JBossCache/src/org/jboss/cache/TreeCacheView2.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheView2.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCacheView2.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- TreeCacheView2.java	18 Oct 2006 11:07:54 -0000	1.17
  +++ TreeCacheView2.java	30 Dec 2006 17:49:54 -0000	1.18
  @@ -48,26 +48,26 @@
   /**
    * Graphical view of a ReplicatedTree (using the MVC paradigm). An instance of this class needs to be given a
    * reference to the underlying model (ReplicatedTree) and needs to registers as a ReplicatedTreeListener. Changes
  - * to the tree structure are propagated from the model to the view (via ReplicatedTreeListener), changes from the
  - * GUI (e.g. by a user) are executed on the tree model (which will broadcast the changes to all replicas).<p>
  + * to the cache structure are propagated from the model to the view (via ReplicatedTreeListener), changes from the
  + * GUI (e.g. by a user) are executed on the cache model (which will broadcast the changes to all replicas).<p>
    * The view itself caches only the nodes, but doesn't cache any of the data (HashMap) associated with it. When
  - * data needs to be displayed, the underlying tree will be accessed directly.
  + * data needs to be displayed, the underlying cache will be accessed directly.
    *
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class TreeCacheView2
   {
      static TreeCacheGui2 gui_ = null;
      static boolean useConsole = false;
  -   TreeCache cache_ = null;
  +   CacheImpl cache_ = null;
      static Log log_ = LogFactory.getLog(TreeCacheView2.class.getName());
   
  -   public TreeCacheView2(TreeCache cache) throws Exception
  +   public TreeCacheView2(CacheImpl cache) throws Exception
      {
         this.cache_ = cache;
      }
   
  -   public static void setCache(TreeCache cache)
  +   public static void setCache(CacheImpl cache)
      {
         gui_.setCache(cache);
      }
  @@ -125,7 +125,7 @@
   
      public static void main(String args[])
      {
  -      TreeCache tree = null;
  +      CacheImpl cache = null;
         TreeCacheView2 demo;
         String start_directory = null;
         String resource = "META-INF/replSync-service.xml";
  @@ -155,12 +155,12 @@
            }
            else
            {
  -            tree = new TreeCache();
  -            tree.setConfiguration(new XmlConfigurationParser().parseFile(resource));
  +            cache = new CacheImpl();
  +            cache.setConfiguration(new XmlConfigurationParser().parseFile(resource));
   
  -            tree.start();
  -//            tree.getNotifier().addCacheListener(new TreeCacheView.MyListener());
  -            demo = new TreeCacheView2(tree);
  +            cache.start();
  +//            cache.getNotifier().addCacheListener(new TreeCacheView.MyListener());
  +            demo = new TreeCacheView2(cache);
               demo.start();
               if (start_directory != null && start_directory.length() > 0)
               {
  @@ -177,7 +177,7 @@
      static void help()
      {
         System.out.println("TreeCacheView [-help] " +
  -              "[-mbean_name <name of TreeCache MBean>] " +
  +              "[-mbean_name <name of CacheImpl MBean>] " +
                 "[-start_directory <dirname>] [-props <props>] " +
                 "[-use_queue <true/false>] [-queue_interval <ms>] [-console]" +
                 "[-queue_max_elements <num>]");
  @@ -187,16 +187,16 @@
   
   class ShutdownThread extends Thread
   {
  -   TreeCache tree = null;
  +   CacheImpl cache = null;
   
  -   ShutdownThread(TreeCache tree)
  +   ShutdownThread(CacheImpl cache)
      {
  -      this.tree = tree;
  +      this.cache = cache;
      }
   
      public void run()
      {
  -      tree.stop();
  +      cache.stop();
      }
   }
   
  @@ -205,7 +205,7 @@
   {
      private static final long serialVersionUID = -1242167331988194987L;
   
  -   TreeCache cache_;
  +   CacheImpl cache_;
      DefaultTreeModel tree_model = null;
      Log log = LogFactory.getLog(getClass());
      JTree jtree = null;
  @@ -230,7 +230,7 @@
      JPanel mainPanel;
   
   
  -   public TreeCacheGui2(TreeCache cache) throws Exception
  +   public TreeCacheGui2(CacheImpl cache) throws Exception
      {
         addNotify();
   
  @@ -318,12 +318,12 @@
         }
      }
   
  -   public void setCache(TreeCache tree)
  +   public void setCache(CacheImpl cache)
      {
  -      cache_ = tree;
  +      cache_ = cache;
         if (cache_ != null)
         {
  -         Runtime.getRuntime().addShutdownHook(new ShutdownThread(tree));
  +         Runtime.getRuntime().addShutdownHook(new ShutdownThread(cache));
            cache_.getNotifier().addCacheListener(this);
            setTitle("TreeCacheGui2: mbr=" + getLocalAddress());
            tx_mgr = cache_.getTransactionManager();
  @@ -396,7 +396,7 @@
               val = (String) table_model.getValueAt(row, col + 1);
               if (key != null && val != null)
               {
  -               // tree.put(selected_node, key, val);
  +               // cache.put(selected_node, key, val);
   
                  try
                  {
  @@ -561,7 +561,7 @@
      /* ----------------------------- Private Methods ---------------------------------- */
   
      /**
  -    * Fetches all data from underlying tree model and display it graphically
  +    * Fetches all data from underlying cache model and display it graphically
       */
      void init()
      {
  @@ -578,7 +578,7 @@
   
   
      /**
  -    * Fetches all data from underlying tree model and display it graphically
  +    * Fetches all data from underlying cache model and display it graphically
       */
      private void populateTree()
      {
  
  
  
  1.2       +10 -9     JBossCache/src/org/jboss/cache/RegionNotEmptyException.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionNotEmptyException.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/RegionNotEmptyException.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- RegionNotEmptyException.java	9 Sep 2005 07:59:06 -0000	1.1
  +++ RegionNotEmptyException.java	30 Dec 2006 17:49:54 -0000	1.2
  @@ -9,20 +9,21 @@
   
   /**
    * Thrown when an attempt is made to 
  - * {@link TreeCache#activateRegion(String) activate a subtree} 
  + * {@link CacheImpl#activateRegion(String) activate a subtree}
    * roote in  Fqn that already has an existing node in the cache.
    * 
  - * @see TreeCache#activateRegion(String)
  - * @see TreeCache#exists(Fqn)
  - * @see TreeCache#exists(String)
  - * 
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
    * @version $Revision$
  + * @see CacheImpl#activateRegion(String)
  + * @see CacheImpl#exists(Fqn)
  + * @see CacheImpl#exists(String)
    */
   public class RegionNotEmptyException extends CacheException
   {
   
  -   /** The serialVersionUID */
  +   /**
  +    * The serialVersionUID
  +    */
      private static final long serialVersionUID = 1L;
   
      public RegionNotEmptyException()
  
  
  
  1.12      +76 -45    JBossCache/src/org/jboss/cache/ReplicationQueue.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicationQueue.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/ReplicationQueue.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- ReplicationQueue.java	25 Aug 2006 14:10:09 -0000	1.11
  +++ ReplicationQueue.java	30 Dec 2006 17:49:54 -0000	1.12
  @@ -9,8 +9,8 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.marshall.MethodCall;
  +import org.jboss.cache.marshall.MethodDeclarations;
   
   import java.util.ArrayList;
   import java.util.List;
  @@ -22,53 +22,68 @@
    * Periodically (or when certain size is exceeded) takes elements and replicates them.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> May 24, 2003
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
  -public class ReplicationQueue {
  +public class ReplicationQueue
  +{
   
  -   private static Log log=LogFactory.getLog(ReplicationQueue.class);
  +   private static Log log = LogFactory.getLog(ReplicationQueue.class);
   
  -   private TreeCache cache=null;
  +   private CacheImpl cache = null;
   
  -   /** We flush every 5 seconds. Inactive if -1 or 0 */
  -   private long interval=5000;
  +   /**
  +    * We flush every 5 seconds. Inactive if -1 or 0
  +    */
  +   private long interval = 5000;
   
  -   /** Max elements before we flush */
  -   private long max_elements=500;
  +   /**
  +    * Max elements before we flush
  +    */
  +   private long max_elements = 500;
   
  -   /** Holds the replication jobs: LinkedList<MethodCall> */
  -   private List elements=new ArrayList();
  +   /**
  +    * Holds the replication jobs: LinkedList<MethodCall>
  +    */
  +   private List elements = new ArrayList();
   
  -   /** For periodical replication */
  -   private Timer timer=null;
  +   /**
  +    * For periodical replication
  +    */
  +   private Timer timer = null;
   
  -   /** The timer task, only calls flush() when executed by Timer */
  -   private MyTask task=null;
  +   /**
  +    * The timer task, only calls flush() when executed by Timer
  +    */
  +   private MyTask task = null;
   
  -   public ReplicationQueue() {
  +   public ReplicationQueue()
  +   {
      }
   
      /**
       * Constructs a new ReplicationQueue.
       */
  -   public ReplicationQueue(TreeCache cache, long interval, long max_elements) {
  -      this.cache=cache;
  -      this.interval=interval;
  -      this.max_elements=max_elements;
  +   public ReplicationQueue(CacheImpl cache, long interval, long max_elements)
  +   {
  +      this.cache = cache;
  +      this.interval = interval;
  +      this.max_elements = max_elements;
      }
   
      /**
       * Returns the flush interval in milliseconds.
       */
  -   public long getInterval() {
  +   public long getInterval()
  +   {
         return interval;
      }
   
      /**
       * Sets the flush interval in milliseconds.
       */
  -   public void setInterval(long interval) {
  -      this.interval=interval;
  +   public void setInterval(long interval)
  +   {
  +      this.interval = interval;
         stop();
         start();
      }
  @@ -77,26 +92,31 @@
       * Returns the maximum number of elements to hold.
       * If the maximum number is reached, flushes in the calling thread.
       */
  -   public long getMax_elements() {
  +   public long getMax_elements()
  +   {
         return max_elements;
      }
   
      /**
       * Sets the maximum number of elements to hold.
       */
  -   public void setMax_elements(long max_elements) {
  -      this.max_elements=max_elements;
  +   public void setMax_elements(long max_elements)
  +   {
  +      this.max_elements = max_elements;
      }
   
      /**
       * Starts the asynchronous flush queue.
       */
  -   public synchronized void start() {
  -      if(interval > 0) {
  -         if(task == null)
  -            task=new MyTask();
  -         if(timer == null) {
  -            timer=new Timer(true);
  +   public synchronized void start()
  +   {
  +      if (interval > 0)
  +      {
  +         if (task == null)
  +            task = new MyTask();
  +         if (timer == null)
  +         {
  +            timer = new Timer(true);
               timer.schedule(task,
                       500, // delay before initial flush
                       interval); // interval between flushes
  @@ -107,14 +127,17 @@
      /**
       * Stops the asynchronous flush queue.
       */
  -   public synchronized void stop() {
  -      if(task != null) {
  +   public synchronized void stop()
  +   {
  +      if (task != null)
  +      {
            task.cancel();
  -         task=null;
  +         task = null;
         }
  -      if(timer != null) {
  +      if (timer != null)
  +      {
            timer.cancel();
  -         timer=null;
  +         timer = null;
         }
      }
   
  @@ -122,10 +145,12 @@
      /**
       * Adds a new method call.
       */
  -   public void add(MethodCall job) {
  +   public void add(MethodCall job)
  +   {
         if (job == null)
            throw new NullPointerException("job is null");
  -      synchronized (elements) {
  +      synchronized (elements)
  +      {
            elements.add(job);
            if (elements.size() >= max_elements)
               flush();
  @@ -135,26 +160,32 @@
      /**
       * Flushes existing method calls.
       */
  -   public void flush() {
  +   public void flush()
  +   {
         List l;
  -      synchronized(elements) {
  +      synchronized (elements)
  +      {
            if (log.isTraceEnabled())
               log.trace("flush(): flushing repl queue (num elements=" + elements.size() + ")");
            l = new ArrayList(elements);
            elements.clear();
         }
   
  -      try {
  +      try
  +      {
            // send to all live nodes in the cluster
            cache.callRemoteMethods(null, MethodDeclarations.replicateAllMethod, new Object[]{l}, false, true, 5000);
         }
  -      catch(Throwable t) {
  +      catch (Throwable t)
  +      {
            log.error("failed replicating " + l.size() + " elements in replication queue", t);
         }
      }
   
  -   class MyTask extends TimerTask {
  -      public void run() {
  +   class MyTask extends TimerTask
  +   {
  +      public void run()
  +      {
            flush();
         }
      }
  
  
  
  1.17      +37 -37    JBossCache/src/org/jboss/cache/RegionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/RegionManager.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- RegionManager.java	14 Dec 2006 17:18:47 -0000	1.16
  +++ RegionManager.java	30 Dec 2006 17:49:54 -0000	1.17
  @@ -42,7 +42,7 @@
      Map<Fqn, Region> regionsRegistry = new ConcurrentHashMap<Fqn, Region>();
      boolean defaultInactive;
      private Log log = LogFactory.getLog(RegionManager.class);
  -   TreeCache treeCache;
  +   CacheImpl cache;
      private boolean usingEvictions;
      private EvictionConfig evictionConfig;
      private EvictionTimerTask evictionTimerTask = new EvictionTimerTask();
  @@ -59,9 +59,9 @@
         return usingEvictions;
      }
   
  -   public RegionManager(TreeCache treeCache)
  +   public RegionManager(CacheImpl cache)
      {
  -      this.treeCache = treeCache;
  +      this.cache = cache;
      }
   
      public boolean isDefaultInactive()
  @@ -79,7 +79,7 @@
       * Helper utility that checks for a classloader registered for the
       * given Fqn, and if found sets it as the TCCL. If the given Fqn is
       * under the _BUDDY_BACKUP_ region, the equivalent region in the main
  -    * tree is used to find the classloader.
  +    * cache is used to find the classloader.
       *
       * @param fqn Fqn pointing to a region for which a special classloader
       *            may have been registered.
  @@ -263,7 +263,7 @@
                  //r.activate();
                  r.setActive(true);
                  // FIXME - persistent state transfer counts too!
  -               if (treeCache.getConfiguration().isFetchInMemoryState())
  +               if (cache.getConfiguration().isFetchInMemoryState())
                  {
                     activateRegion(r.getFqn().toString());
                  }
  @@ -275,7 +275,7 @@
               r = getRegion(fqn, true);
               r.setActive(true);
               // FIXME - persistent state transfer counts too!
  -            if (treeCache.getConfiguration().isFetchInMemoryState())
  +            if (cache.getConfiguration().isFetchInMemoryState())
               {
                  activateRegion(r.getFqn().toString());
               }
  @@ -293,13 +293,13 @@
       * for that subtree.
       * <p/>
       * <strong>NOTE:</strong> This method will cause the creation of a node
  -    * in the local tree at <code>subtreeFqn</code> whether or not that
  +    * in the local cache at <code>subtreeFqn</code> whether or not that
       * node exists anywhere else in the cluster.  If the node does not exist
       * elsewhere, the local node will be empty.  The creation of this node will
       * not be replicated.
       *
       * @param subtreeFqn Fqn string indicating the uppermost node in the
  -    *                   portion of the tree that should be activated.
  +    *                   portion of the cache that should be activated.
       * @throws RegionNotEmptyException if the node <code>subtreeFqn</code>
       *                                 exists and has either data or children
       */
  @@ -308,12 +308,12 @@
         Fqn fqn = Fqn.fromString(subtreeFqn);
   
         // Check whether the node already exists and has data
  -      Node subtreeRoot = treeCache.findNode(fqn);
  +      Node subtreeRoot = cache.findNode(fqn);
   
         /*
          * Commented out on Nov 16,2006 Manik&Vladimir 
          * 
  -       * if (!(treeCache.isNodeEmpty(subtreeRoot)))
  +       * if (!(cache.isNodeEmpty(subtreeRoot)))
         {
            throw new RegionNotEmptyException("Node " + subtreeRoot.getFqn() + " already exists and is not empty");
         }*/
  @@ -340,20 +340,20 @@
            // If a classloader is registered for the node's region, use it
            ClassLoader cl = region.getClassLoader();
   
  -         BuddyManager buddyManager = treeCache.getBuddyManager();
  +         BuddyManager buddyManager = cache.getBuddyManager();
            // Request partial state from the cluster and integrate it
            if (buddyManager == null)
            {
               // Get the state from any node that has it and put it
  -            // in the main tree
  +            // in the main cache
               if (subtreeRoot == null)
               {
                  // We'll update this node with the state we receive
  -               subtreeRoot = treeCache.createSubtreeRootNode(fqn);
  +               subtreeRoot = cache.createSubtreeRootNode(fqn);
               }
   
               Address[] groupMembers = null;
  -            Vector<Address> members = treeCache.getMembers();
  +            Vector<Address> members = cache.getMembers();
               synchronized (members)
               {
                  groupMembers = members.toArray(new Address[members.size()]);
  @@ -367,13 +367,13 @@
               }
               else
               {
  -               treeCache.fetchPartialState(groupMembers, subtreeRoot.getFqn());
  +               cache.fetchPartialState(groupMembers, subtreeRoot.getFqn());
               }
            }
            else
            {
               // Get the state from each DataOwner and integrate in their
  -            // respective buddy backup tree
  +            // respective buddy backup cache
               List buddies = buddyManager.getBuddyAddresses();
               for (Iterator it = buddies.iterator(); it.hasNext();)
               {
  @@ -381,13 +381,13 @@
                  Object sources[] = new Object[]{buddy};
                  Fqn base = new Fqn(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN, BuddyManager.getGroupNameFromAddress(buddy));
                  Fqn buddyRoot = new Fqn(base, fqn);
  -               subtreeRoot = treeCache.findNode(buddyRoot);
  +               subtreeRoot = cache.findNode(buddyRoot);
                  if (subtreeRoot == null)
                  {
                     // We'll update this node with the state we receive
  -                  subtreeRoot = treeCache.createSubtreeRootNode(buddyRoot);
  +                  subtreeRoot = cache.createSubtreeRootNode(buddyRoot);
                  }
  -               treeCache.fetchPartialState(sources, subtreeRoot.getFqn());
  +               cache.fetchPartialState(sources, subtreeRoot.getFqn());
               }
            }
         }
  @@ -409,11 +409,11 @@
            // Throw the exception on, wrapping if necessary         
            if (t instanceof RegionNotEmptyException)
            {
  -            throw(RegionNotEmptyException) t;
  +            throw (RegionNotEmptyException) t;
            }
            else if (t instanceof CacheException)
            {
  -            throw(CacheException) t;
  +            throw (CacheException) t;
            }
            else
            {
  @@ -432,7 +432,7 @@
       * rooted at <code>subtreeFqn</code> and evict all nodes in that subtree.
       *
       * @param subtreeFqn Fqn string indicating the uppermost node in the
  -    *                   portion of the tree that should be activated.
  +    *                   portion of the cache that should be activated.
       * @throws RegionNameConflictException if <code>subtreeFqn</code> indicates
       *                                     a node that is part of another
       *                                     subtree that is being specially
  @@ -461,21 +461,21 @@
            // Record that this fqn is in status change, so can't provide state
            activationChangeNodes.add(fqn);
   
  -         VersionAwareMarshaller marshaller = treeCache.getMarshaller();
  +         VersionAwareMarshaller marshaller = cache.getMarshaller();
            boolean inactive = marshaller.isInactive(subtreeFqn);
            if (!inactive)
            {
               deactivate(subtreeFqn);
            }
   
  -         // Create a list with the Fqn in the main tree and any buddy backup trees
  -         BuddyManager buddyManager = treeCache.getBuddyManager();
  +         // Create a list with the Fqn in the main cache and any buddy backup trees
  +         BuddyManager buddyManager = cache.getBuddyManager();
            ArrayList list = new ArrayList();
            list.add(fqn);
   
            if (buddyManager != null)
            {
  -            Set buddies = treeCache.getChildrenNames(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
  +            Set buddies = cache.getChildrenNames(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
               if (buddies != null)
               {
                  for (Iterator it = buddies.iterator(); it.hasNext();)
  @@ -486,16 +486,16 @@
               }
            }
   
  -         long stateFetchTimeout = treeCache.getConfiguration().getLockAcquisitionTimeout() + 5000;
  -         // Remove the subtree from the main tree  and any buddy backup trees
  +         long stateFetchTimeout = cache.getConfiguration().getLockAcquisitionTimeout() + 5000;
  +         // Remove the subtree from the main cache  and any buddy backup trees
            for (Iterator it = list.iterator(); it.hasNext();)
            {
               Fqn subtree = (Fqn) it.next();
  -            subtreeRoot = treeCache.findNode(subtree);
  +            subtreeRoot = cache.findNode(subtree);
               if (subtreeRoot != null)
               {
                  // Acquire locks
  -               Object owner = treeCache.getOwnerForLock();
  +               Object owner = cache.getOwnerForLock();
                  subtreeLock = subtreeRoot.getNodeSPI().getLock();
                  subtreeLock.acquireAll(owner, stateFetchTimeout, NodeLock.LockType.WRITE);
                  subtreeLocked = true;
  @@ -510,7 +510,7 @@
                  }
   
                  // Remove the subtree
  -               treeCache._evictSubtree(subtree);
  +               cache._evictSubtree(subtree);
   
                  // Release locks
                  if (parent != null)
  @@ -630,7 +630,7 @@
                  region.setActive(false);
                  // FIXME - we should always clean up; otherwise stale data 
                  // is in memory!
  -               if (treeCache.getConfiguration().isFetchInMemoryState())
  +               if (cache.getConfiguration().isFetchInMemoryState())
                  {
                     inactivateRegion(fqn.toString());
                  }
  @@ -642,7 +642,7 @@
               region.setActive(false);
               // FIXME - we should always clean up; otherwise stale data 
               // is in memory!
  -            if (treeCache.getConfiguration().isFetchInMemoryState())
  +            if (cache.getConfiguration().isFetchInMemoryState())
               {
                  inactivateRegion(fqn.toString());
               }
  @@ -754,7 +754,7 @@
   
      public void startEvictionThread()
      {
  -      evictionTimerTask.init(evictionConfig.getWakeupIntervalSeconds(), treeCache.getNotifier());
  +      evictionTimerTask.init(evictionConfig.getWakeupIntervalSeconds(), cache.getNotifier());
      }
   
      /**
  @@ -791,7 +791,7 @@
    * @author Ben Wang 02-2004
    * @author Daniel Huang (dhuang at jboss.org)
    * @author Brian Stansberry
  - * @version $Id: RegionManager.java,v 1.16 2006/12/14 17:18:47 msurtani Exp $
  + * @version $Id: RegionManager.java,v 1.17 2006/12/30 17:49:54 msurtani Exp $
    */
   /*public class ERegionManager
   {
  @@ -806,7 +806,7 @@
      private Timer evictionThread_;
      private EvictionTimerTask evictionTimerTask_;
      private EvictionConfig config_;
  -   private TreeCache cache_;
  +   private CacheImpl cache_;
   
      *//**
    * @deprecated This is provided for JBCache 1.2 backwards API compatibility.
  @@ -974,7 +974,7 @@
         return createRegion(Fqn.fromString(fqn), policy, config);
      }
   
  -   public void configure(TreeCache cache)
  +   public void configure(CacheImpl cache)
      {
         if (log_.isTraceEnabled())
         {
  
  
  
  1.18      +5 -5      JBossCache/src/org/jboss/cache/TransactionEntry.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionEntry.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionEntry.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- TransactionEntry.java	14 Dec 2006 17:18:47 -0000	1.17
  +++ TransactionEntry.java	30 Dec 2006 17:49:54 -0000	1.18
  @@ -25,7 +25,7 @@
   
   /**
    * This is the value (key being the {@link GlobalTransaction}) in the transaction table
  - * of TreeCache.
  + * of CacheImpl.
    * <br>A TransactionEntry maintains
    * <ul>
    * <li>Handle to local Transactions: there can be more than 1 local TX associated with a GlobalTransaction
  @@ -37,7 +37,7 @@
    * </ul>
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 14, 2003
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class TransactionEntry
   {
  @@ -276,7 +276,7 @@
      }
   
      /**
  -    * Posts all undo operations to the TreeCache.
  +    * Posts all undo operations to the CacheImpl.
       */
      public void undoOperations(CacheSPI cache)
      {
  @@ -300,10 +300,10 @@
      {
         try
         {
  -         Object retval = undo_op.invoke(((TreeCacheProxyImpl) cache).getTreeCache());
  +         Object retval = undo_op.invoke(cache);
            if (retval instanceof Throwable)
            {
  -            throw(Throwable) retval;
  +            throw (Throwable) retval;
            }
         }
         catch (Throwable t)
  
  
  
  1.6       +50 -17    JBossCache/src/org/jboss/cache/NodeSPI.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeSPI.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/NodeSPI.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- NodeSPI.java	29 Nov 2006 22:12:44 -0000	1.5
  +++ NodeSPI.java	30 Dec 2006 17:49:54 -0000	1.6
  @@ -6,18 +6,20 @@
    */
   package org.jboss.cache;
   
  -import java.util.Map;
  -
   import org.jboss.cache.lock.NodeLock;
  +import org.jboss.cache.optimistic.DataVersion;
  +
  +import java.util.Map;
  +import java.util.Set;
   
   /**
    * A more detailed interface to {@link Node}, which is used when writing plugins for or extending JBoss Cache.
    *
  + * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @see Node
    * @since 2.0.0
  - * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  -public interface NodeSPI
  +public interface NodeSPI extends Node
   {
       // TODO:
       // everything that is not already represented by Node
  @@ -54,6 +56,7 @@
      /**
       * Sets the node's children explictly.
       * The data should only be modified by the cache itself.
  +    *
       * @param children cannot be null
       */
      void setChildrenMap(Map<Object, Node> children);
  @@ -77,6 +80,7 @@
      
      /**
       * Returns an existing child or creates a new one using a global transaction. 
  +    *
       * @return newly created node
       */
      Node getOrCreateChild(Object name, GlobalTransaction tx);
  @@ -90,4 +94,33 @@
       * Sets the FQN of this node and resets the names of all children as well.
       */
      void setFqn(Fqn f);
  +
  +   boolean isDeleted();
  +
  +   void markAsDeleted(boolean marker);
  +
  +   void markAsDeleted(boolean marker, boolean recursive);
  +
  +   void addChild(Object nodeName, Node nodeToAdd);
  +
  +   Set<Node> getChildren(boolean includeMarkedAsDeleted);
  +
  +   void printDetails(StringBuffer sb, int i);
  +
  +   void removeChildren();
  +
  +   void print(StringBuffer sb, int indent);
  +
  +   // versioning
  +   /**
  +    * May throw UnsupportedOperationException if versioning is not used.
  +    *
  +    * @param version
  +    */
  +   void setVersion(DataVersion version);
  +
  +   /**
  +    * May throw UnsupportedOperationException if versioning is not used.
  +    */
  +   DataVersion getVersion();
   }
  
  
  
  1.18      +64 -71    JBossCache/src/org/jboss/cache/TreeCacheView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheView.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCacheView.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- TreeCacheView.java	11 Dec 2006 21:17:51 -0000	1.17
  +++ TreeCacheView.java	30 Dec 2006 17:49:54 -0000	1.18
  @@ -8,36 +8,15 @@
   package org.jboss.cache;
   
   
  -import java.awt.BorderLayout;
  -import java.awt.event.ActionEvent;
  -import java.awt.event.MouseAdapter;
  -import java.awt.event.MouseEvent;
  -import java.awt.event.MouseListener;
  -import java.awt.event.WindowEvent;
  -import java.awt.event.WindowListener;
  -import java.io.File;
  -import java.util.ArrayList;
  -import java.util.HashMap;
  -import java.util.Iterator;
  -import java.util.List;
  -import java.util.Map;
  -import java.util.Set;
  -import java.util.Vector;
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.config.Configuration;
  +import org.jgroups.View;
   
   import javax.management.MBeanServer;
   import javax.management.MBeanServerFactory;
   import javax.management.ObjectName;
  -import javax.swing.AbstractAction;
  -import javax.swing.JFrame;
  -import javax.swing.JMenu;
  -import javax.swing.JMenuBar;
  -import javax.swing.JOptionPane;
  -import javax.swing.JPanel;
  -import javax.swing.JPopupMenu;
  -import javax.swing.JScrollPane;
  -import javax.swing.JTable;
  -import javax.swing.JTextField;
  -import javax.swing.JTree;
  +import javax.swing.*;
   import javax.swing.event.TableModelEvent;
   import javax.swing.event.TableModelListener;
   import javax.swing.event.TreeSelectionEvent;
  @@ -49,28 +28,38 @@
   import javax.swing.tree.TreeNode;
   import javax.swing.tree.TreePath;
   import javax.swing.tree.TreeSelectionModel;
  -
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.config.Configuration;
  -import org.jgroups.View;
  +import java.awt.*;
  +import java.awt.event.ActionEvent;
  +import java.awt.event.MouseAdapter;
  +import java.awt.event.MouseEvent;
  +import java.awt.event.MouseListener;
  +import java.awt.event.WindowEvent;
  +import java.awt.event.WindowListener;
  +import java.io.File;
  +import java.util.ArrayList;
  +import java.util.HashMap;
  +import java.util.Iterator;
  +import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
  +import java.util.Vector;
   
   
   /**
    * Graphical view of a ReplicatedTree (using the MVC paradigm). An instance of this class needs to be given a
    * reference to the underlying model (ReplicatedTree) and needs to registers as a ReplicatedTreeListener. Changes
  - * to the tree structure are propagated from the model to the view (via ReplicatedTreeListener), changes from the
  - * GUI (e.g. by a user) are executed on the tree model (which will broadcast the changes to all replicas).<p>
  + * to the cache structure are propagated from the model to the view (via ReplicatedTreeListener), changes from the
  + * GUI (e.g. by a user) are executed on the cache model (which will broadcast the changes to all replicas).<p>
    * The view itself caches only the nodes, but doesn't cache any of the data (HashMap) associated with it. When
  - * data needs to be displayed, the underlying tree will be accessed directly.
  + * data needs to be displayed, the underlying cache will be accessed directly.
    *
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    * @author<a href="mailto:bela at jboss.org">Bela Ban</a> March 27 2003
    */
   public class TreeCacheView implements TreeCacheViewMBean
   {
      /**
  -    * Reference to the TreeCache MBean (the model for this view)
  +    * Reference to the CacheImpl MBean (the model for this view)
       */
      ObjectName cache_service = null;
      TreeCacheGui gui = null;
  @@ -149,7 +138,7 @@
            throw new Exception("TreeCacheView.init(): no MBeanServers found");
         srv = (MBeanServer) servers.get(0);
         log.info("init(): found MBeanServer " + srv);
  -      cache = (CacheSPI)srv.getAttribute(this.cache_service, "Cache");
  +      cache = (CacheSPI) srv.getAttribute(this.cache_service, "Cache");
         System.out.println("Cache " + cache);
         TreeCacheGui gui = new TreeCacheGui(cache);
      }
  @@ -189,10 +178,10 @@
   
      public static void main(String args[])
      {
  -      TreeCache tree = null;
  +      CacheImpl cache = null;
         TreeCacheView demo;
         String start_directory = null;
  -      String mbean_name = "jboss.cache:service=TreeCache";
  +      String mbean_name = "jboss.cache:service=CacheImpl";
         String props = getDefaultProps();
         MBeanServer srv;
         Log log;
  @@ -241,7 +230,7 @@
   
         try
         {
  -         log = LogFactory.getLog(TreeCache.class);
  +         log = LogFactory.getLog(CacheImpl.class);
            srv = MBeanServerFactory.createMBeanServer();
   
   //            String  FACTORY="org.jboss.cache.transaction.DummyContextFactory";
  @@ -250,7 +239,7 @@
   //            DummyTransactionManager.getInstance();
   
   
  -         tree = new TreeCache();
  +         cache = new CacheImpl();
            Configuration c = new Configuration();
            c.setClusterName("TreeCacheGroup");
            c.setClusterConfig(props);
  @@ -264,21 +253,21 @@
               c.setReplQueueMaxElements(queue_max_elements);
            }
   
  -         tree.getNotifier().addCacheListener(new MyListener());
  +         cache.getNotifier().addCacheListener(new MyListener());
   
  -         log.info("registering the tree as " + mbean_name);
  -         srv.registerMBean(tree.getCacheMBeanInterface(), new ObjectName(mbean_name));
  +         log.info("registering the cache as " + mbean_name);
  +         srv.registerMBean(cache.getCacheMBeanInterface(), new ObjectName(mbean_name));
   
  -         tree.start();
  +         cache.start();
   
  -         Runtime.getRuntime().addShutdownHook(new ShutdownThread(tree));
  +         Runtime.getRuntime().addShutdownHook(new ShutdownThread(cache));
   
  -//            tree.put("/a/b/c", null);
  -//            tree.put("/a/b/c1", null);
  -//            tree.put("/a/b/c2", null);
  -//            tree.put("/a/b1/chat", null);
  -//            tree.put("/a/b1/chat2", null);
  -//            tree.put("/a/b1/chat5", null);
  +//            cache.put("/a/b/c", null);
  +//            cache.put("/a/b/c1", null);
  +//            cache.put("/a/b/c2", null);
  +//            cache.put("/a/b1/chat", null);
  +//            cache.put("/a/b1/chat2", null);
  +//            cache.put("/a/b1/chat5", null);
   
            demo = new TreeCacheView(mbean_name);
            demo.create();
  @@ -296,16 +285,16 @@
   
      static class ShutdownThread extends Thread
      {
  -      TreeCache tree = null;
  +      CacheImpl cache = null;
   
  -      ShutdownThread(TreeCache tree)
  +      ShutdownThread(CacheImpl cache)
         {
  -         this.tree = tree;
  +         this.cache = cache;
         }
   
         public void run()
         {
  -         tree.stop();
  +         cache.stop();
         }
      }
   
  @@ -332,7 +321,7 @@
      static void help()
      {
         System.out.println("TreeCacheView [-help] " +
  -              "[-mbean_name <name of TreeCache MBean>] " +
  +              "[-mbean_name <name of CacheImpl MBean>] " +
                 "[-start_directory <dirname>] [-props <props>] " +
                 "[-use_queue <true/false>] [-queue_interval <ms>] " +
                 "[-queue_max_elements <num>]");
  @@ -485,7 +474,7 @@
               val = (String) table_model.getValueAt(row, col + 1);
               if (key != null && val != null)
               {
  -               // tree.put(selected_node, key, val);
  +               // cache.put(selected_node, key, val);
   
   //                        server.invoke(cache_service, "put",
   //                                      new Object[]{selected_node, key, val},
  @@ -656,7 +645,7 @@
      /* ----------------------------- Private Methods ---------------------------------- */
   
      /**
  -    * Fetches all data from underlying tree model and display it graphically
  +    * Fetches all data from underlying cache model and display it graphically
       */
      void init()
      {
  @@ -674,7 +663,7 @@
   
   
      /**
  -    * Fetches all data from underlying tree model and display it graphically
  +    * Fetches all data from underlying cache model and display it graphically
       */
      private void populateTree()
      {
  @@ -696,7 +685,8 @@
   
         // 2. Then add my children
         children = getChildrenNames(fqn);
  -      for (Object o : children) {
  +      for (Object o : children)
  +      {
           addGuiNode(new Fqn(fqn, o));
         }
      }
  @@ -705,8 +695,9 @@
      Fqn makeFQN(Object[] opath)
      {
         List l = new ArrayList();
  -      for (Object o : opath) {
  -         MyNode node = (MyNode)o;
  +      for (Object o : opath)
  +      {
  +         MyNode node = (MyNode) o;
            Object name = node.name;
            if (name.equals(Fqn.SEPARATOR))
               continue;
  @@ -813,8 +804,9 @@
   
      Map getData(Fqn fqn)
      {
  -      Node n = cache.getChild(fqn);
  -      if (n == null) {
  +      Node n = cache.getRoot().getChild(fqn);
  +      if (n == null)
  +      {
            return null;
         }
         return n.getData();
  @@ -850,7 +842,7 @@
      {
         try
         {
  -         return cache.getChild(fqn).getKeys();
  +         return cache.getRoot().getChild(fqn).getKeys();
         }
         catch (Throwable t)
         {
  @@ -863,7 +855,7 @@
      {
         try
         {
  -         return cache.getChild(fqn).getData().get(key);
  +         return cache.getRoot().getChild(fqn).getData().get(key);
         }
         catch (Throwable t)
         {
  @@ -876,7 +868,7 @@
      {
         try
         {
  -         Node n = cache.getChild(fqn);
  +         Node n = cache.getRoot().getChild(fqn);
            return n.getChildrenNames();
         }
         catch (Throwable t)
  @@ -973,7 +965,7 @@
         {
            try
            {
  -            cache.removeChild(selected_node);
  +            cache.getRoot().removeChild(selected_node);
            }
            catch (Throwable t)
            {
  @@ -1029,7 +1021,8 @@
   
            if (fqn == null) return null;
            curr = this;
  -         for (Object o : fqn.peekElements()) {
  +         for (Object o : fqn.peekElements())
  +         {
               n = curr.findChild(o);
               if (n == null)
               {
  
  
  
  1.43      +4 -4      JBossCache/src/org/jboss/cache/Fqn.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Fqn.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Fqn.java,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- Fqn.java	8 Dec 2006 19:03:56 -0000	1.42
  +++ Fqn.java	30 Dec 2006 17:49:54 -0000	1.43
  @@ -42,7 +42,7 @@
    * <p/>
    * Another way to look at it is that the "/" separarator is only parsed when it form sa  part of a String passed in to Fqn.fromString() and not otherwise.
    *
  - * @version $Revision: 1.42 $
  + * @version $Revision: 1.43 $
    */
   public class Fqn implements Cloneable, Externalizable, Comparable<Fqn>
   {
  @@ -57,7 +57,7 @@
   
      /**
       * Controls the implementation of read/writeExternal.
  -    * Package protected so TreeCache can set it when ReplicationVersion is set.
  +    * Package protected so CacheImpl can set it when ReplicationVersion is set.
       */
      static boolean REL_123_COMPATIBLE = false;
   
  @@ -65,7 +65,7 @@
      {
         // Check if they set a system property telling us to use 1.2.3 compatibility mode
         // Obscure use case for this: Server has multiple caches, only one of which has
  -      // TreeCache.setReplicationVersion() set to "1.2.3".  If the 1.2.4+ caches start
  +      // CacheImpl.setReplicationVersion() set to "1.2.3".  If the 1.2.4+ caches start
         // first, they will begin exchanging 1.2.4 style fqn's, and then when the 1.2.3
         // cache starts the format will change when it changes REL_123_COMPATIBLE.  This
         // could cause chaos. The system property allows the 1.2.3 mode to be used by
  
  
  
  1.51      +11 -6     JBossCache/src/org/jboss/cache/Node.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Node.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Node.java,v
  retrieving revision 1.50
  retrieving revision 1.51
  diff -u -b -r1.50 -r1.51
  --- Node.java	20 Nov 2006 03:53:54 -0000	1.50
  +++ Node.java	30 Dec 2006 17:49:54 -0000	1.51
  @@ -10,9 +10,9 @@
   import java.util.Set;
   
   /**
  - * Along with {@link Cache}, this is a central construct in the tree structure of JBoss Cache.
  + * Along with {@link Cache}, this is a central construct in the cache structure of JBoss Cache.
    * <p/>
  - * A Node represents a point in the tree.  A Node has references to it's children, parent
  + * A Node represents a point in the cache.  A Node has references to it's children, parent
    * (each Node has a single parent) and data contained within the Node (key value pairs).
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
  @@ -47,7 +47,7 @@
      Set getKeys();
   
      /**
  -    * @return The {@link Fqn} which represents the location of this {@link Node} in the tree structure.  The {@link Fqn} returned is absolute.
  +    * @return The {@link Fqn} which represents the location of this {@link Node} in the cache structure.  The {@link Fqn} returned is absolute.
       */
      Fqn getFqn();
   
  @@ -82,6 +82,11 @@
      Node getChild(Fqn f);
   
      /**
  +    * Returns a direct child of the current node.
  +    */
  +   Node getChild(Object name);
  +
  +   /**
       * Puts a key and a value into the current node's data map.
       * Overwrites if the key already exists.
       *
  @@ -146,11 +151,11 @@
      void clearData();
   
      /**
  -    * Moves a part of the tree to a different subtree.
  +    * Moves a part of the cache to a different subtree.
       * <p/>
       * E.g.:
       * <p/>
  -    * assume a tree structure such as:
  +    * assume a cache structure such as:
       * <p/>
       * <pre>
       *  /a/b/c
  
  
  
  1.3       +5 -3      JBossCache/src/org/jboss/cache/TransactionManagerLookup.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionManagerLookup.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TransactionManagerLookup.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- TransactionManagerLookup.java	8 Apr 2006 20:30:07 -0000	1.2
  +++ TransactionManagerLookup.java	30 Dec 2006 17:49:54 -0000	1.3
  @@ -3,15 +3,17 @@
   import javax.transaction.TransactionManager;
   
   /**
  - * Factory interface, allows TreeCache to use different transactional systems.
  + * Factory interface, allows CacheImpl to use different transactional systems.
    *
    * @author Bela Ban, Aug 26 2003
  - * @version $Id: TransactionManagerLookup.java,v 1.2 2006/04/08 20:30:07 genman Exp $
  + * @version $Id: TransactionManagerLookup.java,v 1.3 2006/12/30 17:49:54 msurtani Exp $
    */
  -public interface TransactionManagerLookup {
  +public interface TransactionManagerLookup
  +{
   
      /**
       * Returns a new TransactionManager.
  +    *
       * @throws Exception if lookup failed
       */
      TransactionManager getTransactionManager() throws Exception;
  
  
  
  1.1      date: 2006/12/30 17:49:54;  author: msurtani;  state: Exp;JBossCache/src/org/jboss/cache/VersionedNode.java
  
  Index: VersionedNode.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source
   *
   * Distributable under LGPL license.
   * See terms of license at gnu.org.
   */
  package org.jboss.cache;
  
  import org.jboss.cache.optimistic.DataVersion;
  import org.jboss.cache.optimistic.DefaultDataVersion;
  
  import java.util.Map;
  
  /**
   * VersionedNode contains a data version.
   *
   * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
   */
  public class VersionedNode extends UnversionedNode
  {
  
     private DataVersion version;
  
     /**
      * Although this object has a reference to the CacheImpl, the optimistic
      * node is actually disconnected from the CacheImpl itself.
      * The parent could be looked up from the TransactionWorkspace.
      */
     private Node parent;
  
     public VersionedNode(Object childName, Fqn fqn, Node parent, Map data, DataVersion version, CacheSPI cache)
     {
        this(childName, fqn, parent, data, false, cache, DefaultDataVersion.ZERO);
     }
  
     public VersionedNode(Object childName, Fqn fqn, Node parent, Map data, boolean mapSafe, CacheSPI cache)
     {
        this(childName, fqn, parent, data, mapSafe, cache, DefaultDataVersion.ZERO);
     }
  
     public VersionedNode(Object childName, Fqn fqn, Node parent, Map data, boolean mapSafe, CacheSPI cache, DataVersion version)
     {
        super(childName, fqn, data, mapSafe, cache);
        if (version == null)
           throw new NullPointerException("version");
        if (parent == null && !fqn.isRoot())
           throw new NullPointerException("parent");
        this.parent = parent;
        this.version = version;
     }
  
     public VersionedNode(Object childName, Fqn fqn, Node parent, Map data, CacheSPI cache)
     {
        this(childName, fqn, parent, data, false, cache);
     }
  
     /**
      * Returns the version id of this node.
      *
      * @return the version
      */
     public DataVersion getVersion()
     {
        return version;
     }
  
     /**
      * Returns the parent.
      */
     public Node getParent()
     {
        return parent;
     }
  
     /**
      * Sets the version id of this node.
      *
      * @param version
      */
     public void setVersion(DataVersion version)
     {
        this.version = version;
     }
  
     public String toString()
     {
        return "Opt" + super.toString();
     }
  
  }
  
  
  
  1.1      date: 2006/12/30 17:49:54;  author: msurtani;  state: Exp;JBossCache/src/org/jboss/cache/CacheImpl.java
  
  Index: CacheImpl.java
  ===================================================================
  /*
   * JBoss, the OpenSource J2EE webOS
   *
   * Distributable under LGPL license.
   * See terms of license at gnu.org.
   */
  package org.jboss.cache;
  
  import org.apache.commons.logging.Log;
  import org.apache.commons.logging.LogFactory;
  import org.jboss.cache.buddyreplication.BuddyGroup;
  import org.jboss.cache.buddyreplication.BuddyManager;
  import org.jboss.cache.buddyreplication.BuddyNotInitException;
  import org.jboss.cache.buddyreplication.GravitateResult;
  import org.jboss.cache.config.BuddyReplicationConfig;
  import org.jboss.cache.config.CacheLoaderConfig;
  import org.jboss.cache.config.Configuration;
  import org.jboss.cache.config.RuntimeConfig;
  import org.jboss.cache.factories.InterceptorChainFactory;
  import org.jboss.cache.factories.NodeFactory;
  import org.jboss.cache.interceptors.Interceptor;
  import org.jboss.cache.jmx.CacheMBean;
  import org.jboss.cache.loader.CacheLoader;
  import org.jboss.cache.loader.CacheLoaderManager;
  import org.jboss.cache.loader.NodeData;
  import org.jboss.cache.lock.IsolationLevel;
  import org.jboss.cache.lock.LockStrategyFactory;
  import org.jboss.cache.lock.LockUtil;
  import org.jboss.cache.lock.LockingException;
  import org.jboss.cache.lock.NodeLock;
  import org.jboss.cache.lock.TimeoutException;
  import org.jboss.cache.marshall.InactiveRegionAwareRpcDispatcher;
  import org.jboss.cache.marshall.MethodCall;
  import org.jboss.cache.marshall.MethodCallFactory;
  import org.jboss.cache.marshall.MethodDeclarations;
  import org.jboss.cache.marshall.RegionNameConflictException;
  import org.jboss.cache.marshall.RegionNotFoundException;
  import org.jboss.cache.marshall.VersionAwareMarshaller;
  import org.jboss.cache.notifications.Notifier;
  import org.jboss.cache.optimistic.DataVersion;
  import org.jboss.cache.statetransfer.StateTransferManager;
  import org.jboss.cache.util.ExposedByteArrayOutputStream;
  import org.jboss.cache.util.MapCopy;
  import org.jboss.util.stream.MarshalledValueInputStream;
  import org.jboss.util.stream.MarshalledValueOutputStream;
  import org.jgroups.Address;
  import org.jgroups.Channel;
  import org.jgroups.ChannelClosedException;
  import org.jgroups.ChannelNotConnectedException;
  import org.jgroups.ExtendedMembershipListener;
  import org.jgroups.ExtendedMessageListener;
  import org.jgroups.JChannel;
  import org.jgroups.Message;
  import org.jgroups.MessageListener;
  import org.jgroups.View;
  import org.jgroups.blocks.GroupRequest;
  import org.jgroups.blocks.RpcDispatcher;
  import org.jgroups.jmx.JChannelFactoryMBean;
  import org.jgroups.stack.IpAddress;
  import org.jgroups.util.Rsp;
  import org.jgroups.util.RspList;
  import org.jgroups.util.Util;
  import org.w3c.dom.Element;
  
  import javax.management.MBeanServer;
  import javax.management.ObjectName;
  import javax.transaction.Status;
  import javax.transaction.SystemException;
  import javax.transaction.Transaction;
  import javax.transaction.TransactionManager;
  import java.io.ByteArrayInputStream;
  import java.io.ByteArrayOutputStream;
  import java.io.IOException;
  import java.io.InputStream;
  import java.io.NotSerializableException;
  import java.io.OutputStream;
  import java.lang.reflect.Method;
  import java.util.ArrayList;
  import java.util.Arrays;
  import java.util.Collections;
  import java.util.HashSet;
  import java.util.Iterator;
  import java.util.LinkedList;
  import java.util.List;
  import java.util.Map;
  import java.util.Set;
  import java.util.Vector;
  import java.util.concurrent.ConcurrentHashMap;
  import java.util.concurrent.CopyOnWriteArraySet;
  
  /**
   * A cache-like structure that is replicated across several members. Updates are
   * multicast to all group members reliably and in order. User has the
   * option to set transaction isolation levels and other options.
   *
   * @author Bela Ban
   * @author Ben Wang
   * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
   * @author Brian Stansberry
   * @author Daniel Huang (dhuang at jboss.org)
   * @version $Id: CacheImpl.java,v 1.1 2006/12/30 17:49:54 msurtani Exp $
   *          <p/>
   * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
   */
  public class CacheImpl implements Cloneable, ExtendedMembershipListener, CacheSPI
  {
     private static final String CREATE_MUX_CHANNEL = "createMultiplexerChannel";
     private static final String[] MUX_TYPES = {"java.lang.String", "java.lang.String"};
  
     // Quite poor, but for now, root may be re-initialised when setNodeLockingOptimistic() is called.
     // this is because if node locking is optimistic, we need to use OptimisticTreeNodes rather than TreeNodes.
     // - MANIK
     /**
      * Root DataNode.
      */
     protected NodeSPI root;
  
     {
        root = NodeFactory.getInstance().createRootDataNode(NodeFactory.NodeType.UNVERSIONED_NODE, this);
     }
  
     private RegionManager regionManager = null;
  
     /**
      * The JGroups JChannel in use.
      */
     protected JChannel channel = null;
  
     /**
      * True if this CacheImpl is the coordinator.
      */
     protected boolean coordinator = false;
  
     /**
      * CacheImpl log.
      */
     protected final static Log log = LogFactory.getLog(CacheImpl.class);
  
     /**
      * List of cluster group members.
      */
     protected final Vector<Address> members = new Vector<Address>();
  
     /**
      * JGroups RpcDispatcher in use.
      */
     protected RpcDispatcher disp = null;
  
     /**
      * JGroups message listener.
      */
     protected MessageListenerAdaptor ml = new MessageListenerAdaptor();
  
     /**
      * Maintains mapping of transactions (keys) and Modifications/Undo-Operations
      */
     private final TransactionTable tx_table = new TransactionTable();
  
     /**
      * HashMap<Thread, List<Lock>, maintains locks acquired by threads (used when no TXs are used)
      */
     private final Map lock_table = new ConcurrentHashMap();
  
     /**
      * Set<Fqn> of Fqns of the topmost node of internal regions that should
      * not included in standard state transfers.
      */
     protected Set internalFqns = new CopyOnWriteArraySet();
  
     /**
      * True if state was initialized during start-up.
      */
     protected volatile boolean isStateSet = false;
  
     protected String evictionInterceptorClass = "org.jboss.cache.interceptors.EvictionInterceptor";
  
     /**
      * Marshaller if register to handle marshalling
      */
     protected VersionAwareMarshaller marshaller_ = null;
  
     /**
      * {@link #invokeMethod(MethodCall)} will dispatch to this chain of interceptors.
      * In the future, this will be replaced with JBossAop. This is a first step towards refactoring JBossCache.
      */
     protected Interceptor interceptor_chain = null;
  
     /**
      * Method to acquire a TransactionManager. By default we use JBossTransactionManagerLookup. Has
      * to be set before calling {@link #start()}
      */
     protected TransactionManagerLookup tm_lookup = null;
  
     /**
      * Used to get the Transaction associated with the current thread
      */
     protected TransactionManager tm = null;
  
     protected CacheLoaderManager cacheLoaderManager;
  
     /**
      * for legacy use *
      */
     protected CacheLoaderConfig cloaderConfig;
  
     /**
      * Queue used to replicate updates when mode is repl-async
      */
     protected ReplicationQueue repl_queue = null;
  
     /**
      * create was called.
      */
     protected boolean useCreateService = false;
  
     /**
      * Buddy Manager
      */
     protected BuddyManager buddyManager;
  
     /**
      * State transfer manager. Do not access this field directly -- use the getter
      */
     private StateTransferManager stateTransferManager;
     private Notifier notifier;
     private CacheMBean cacheMBean;
  
  
     public StateTransferManager getStateTransferManager()
     {
        if (stateTransferManager == null)
        {
           stateTransferManager = new StateTransferManager(this);
        }
        return stateTransferManager;
     }
  
     public void setStateTransferManager(StateTransferManager manager)
     {
        this.stateTransferManager = manager;
     }
  
     private long stateFetchTimeout;
  
     private ThreadLocal<InvocationContext> invocationContextContainer = new ThreadLocal<InvocationContext>();
  
     public boolean started;
  
     public Configuration getConfiguration()
     {
        return configuration;
     }
  
     private Configuration configuration = new Configuration(this);
  
     private RPCManager rpcManager;
  
     public RPCManager getRpcManager()
     {
        return rpcManager;
     }
  
     public void setRpcManager(RPCManager rpcManager)
     {
        this.rpcManager = rpcManager;
     }
  
     /**
      * Creates a CacheImpl with a given configuration
      */
     public CacheImpl(Configuration configuration) throws Exception
     {
        notifier = new Notifier(this);
        this.configuration = configuration;
        regionManager = new RegionManager(this);
     }
  
     /**
      * Constructs an uninitialized CacheImpl.
      */
     public CacheImpl() throws Exception
     {
        notifier = new Notifier(this);
        regionManager = new RegionManager(this);
     }
  
     /**
      * Constructs a CacheImpl with an already connected channel.
      */
     public CacheImpl(JChannel channel) throws Exception
     {
        notifier = new Notifier(this);
        this.channel = channel;
        regionManager = new RegionManager(this);
     }
  
     /**
      * Returns the CacheImpl implementation version.
      */
     public String getVersion()
     {
        return Version.printVersion();
     }
  
     /**
      * Used internally by interceptors.
      * Don't use as client, this method will go away.
      */
     public Node getRoot()
     {
        return root;
     }
  
     /**
      * Returns the local channel address.
      */
     public Object getLocalAddress()
     {
        return channel != null ? channel.getLocalAddress() : null;
     }
  
     /**
      * Returns the members as a Vector.
      */
     public Vector<Address> getMembers()
     {
        return members;
     }
  
     /**
      * Returns <code>true</code> if this node is the group coordinator.
      */
     public boolean isCoordinator()
     {
        return coordinator;
     }
  
     /**
      * Returns the transaction table.
      */
     public TransactionTable getTransactionTable()
     {
        return tx_table;
     }
  
     /**
      * Returns the lock table.
      */
     public Map getLockTable()
     {
        return lock_table;
     }
  
     /**
      * Returns the contents of the TransactionTable as a string.
      */
     public String dumpTransactionTable()
     {
        return tx_table.toString(true);
     }
  
     /**
      * Returns false.
      *
      * @deprecated
      */
     public boolean getDeadlockDetection()
     {
        return false;
     }
  
     /**
      * Does nothing.
      *
      * @deprecated
      */
     public void setDeadlockDetection(boolean dt)
     {
        log.warn("Using deprecated configuration element 'DeadlockDetection'.  Will be ignored.");
     }
  
     /**
      * Used for testing only - sets the interceptor chain.
      */
     public void setInterceptorChain(Interceptor i)
     {
        interceptor_chain = i;
     }
  
     /**
      * Returns the list of interceptors.
      */
     public List<Interceptor> getInterceptors()
     {
        return InterceptorChainFactory.asList(interceptor_chain);
     }
  
     /**
      * Returns the underlying cache loader in use.
      */
     public CacheLoader getCacheLoader()
     {
        if (cacheLoaderManager == null) return null;
        return cacheLoaderManager.getCacheLoader();
     }
  
     /**
      * Used for PojoCache. No-op here.
      *
      * @param config
      * @throws CacheException
      */
     public void setPojoCacheConfig(Element config) throws CacheException
     {
        log.warn("setPojoCacheConfig(): You have a PojoCache config that is not used in CacheImpl.");
     }
  
     public Element getPojoCacheConfig()
     {
        return null;
     }
  
     /**
      * Returns the MessageListener in use.
      */
     public MessageListener getMessageListener()
     {
        return ml;
     }
  
     public String getEvictionInterceptorClass()
     {
        return this.evictionInterceptorClass;
     }
  
     private void setUseReplQueue(boolean flag)
     {
        if (flag)
        {
           if (repl_queue == null)
           {
              repl_queue = new ReplicationQueue(this, configuration.getReplQueueInterval(), configuration.getReplQueueMaxElements());
              if (configuration.getReplQueueInterval() >= 0)
              {
                 repl_queue.start();
              }
           }
        }
        else
        {
           if (repl_queue != null)
           {
              repl_queue.stop();
              repl_queue = null;
           }
        }
     }
  
  
     /**
      * Returns the replication queue.
      */
     public ReplicationQueue getReplQueue()
     {
        return repl_queue;
     }
  
     /**
      * @param level
      */
     private void setIsolationLevel(IsolationLevel level)
     {
        LockStrategyFactory.setIsolationLevel(level);
     }
  
     /**
      * Sets the TransactionManagerLookup object
      *
      * @param l
      */
     public void setTransactionManagerLookup(TransactionManagerLookup l)
     {
        this.tm_lookup = l;
     }
  
     /**
      */
     public TransactionManager getTransactionManager()
     {
        return tm;
     }
  
     /**
      * Fetches the group state from the current coordinator. If successful, this
      * will trigger JChannel setState() call.
      */
     public void fetchState(long timeout) throws ChannelClosedException, ChannelNotConnectedException
     {
        if (channel == null)
        {
           throw new ChannelNotConnectedException();
        }
        boolean rc = channel.getState(null, timeout);
        if (rc)
        {
           log.debug("fetchState(): state was retrieved successfully");
        }
        else
        {
           log.debug("fetchState(): state could not be retrieved (first member)");
        }
     }
  
     public void fetchPartialState(Object sources[], Fqn sourceTarget, Fqn integrationTarget) throws Exception
     {
        String encodedStateId = sourceTarget + StateTransferManager.PARTIAL_STATE_DELIMETER + integrationTarget;
        fetchPartialState(sources, encodedStateId);
     }
  
     public void fetchPartialState(Object sources[], Fqn subtree) throws Exception
     {
        if (subtree == null)
        {
           throw new IllegalArgumentException("Cannot fetch partial state. Invalid subtree " + subtree);
        }
        fetchPartialState(sources, subtree.toString());
     }
  
     private void fetchPartialState(Object sources[], String stateId) throws Exception
     {
        if (sources == null || sources.length < 1 || stateId == null)
        {
           // should this really be throwing an exception?  Are there valid use cases where partial state may not be available? - Manik
           // Yes -- cache is configured LOCAL but app doesn't know it -- Brian
           //throw new IllegalArgumentException("Cannot fetch partial state, targets are " + sources + " and stateId is " + stateId);
           if (log.isWarnEnabled())
           {
              log.warn("Cannot fetch partial state, targets are " + Arrays.asList(sources) +
                      " and stateId is " + stateId);
           }
           return;
        }
  
        ArrayList targets = new ArrayList(Arrays.asList(sources));
  
        //skip *this* node as a target
        targets.remove(getLocalAddress());
  
        if (targets.isEmpty())
        {
           // Definitely no exception here -- this happens every time the 1st node in the
           // cluster activates a region!! -- Brian
           log.debug("Cannot fetch partial state. There are no target members specified");
           return;
        }
  
        log.debug("Node " + getLocalAddress() + " fetching partial state " + stateId + " from members " + targets);
        boolean successfulTransfer = false;
        for (Iterator iter = targets.iterator(); iter.hasNext() && !successfulTransfer;)
        {
           Address target = (Address) iter.next();
           log.debug("Node " + getLocalAddress() + " fetching partial state " + stateId + " from member " + target);
           isStateSet = false;
           successfulTransfer = channel.getState(target, stateId, stateFetchTimeout);
           if (successfulTransfer)
           {
              try
              {
                 ml.waitForState();
              }
              catch (Exception transferFailed)
              {
                 successfulTransfer = false;
              }
           }
           log.debug("Node " + getLocalAddress() + " fetching partial state " + stateId + " from member " + target + (successfulTransfer ? " successful" : " failed"));
        }
  
        if (!successfulTransfer)
        {
           log.debug("Node " + getLocalAddress() + " could not fetch partial state " + stateId + " from any member " + targets);
        }
     }
  
     /**
      * Lifecycle method. This is like initialize.
      *
      * @throws Exception
      */
     public void create() throws Exception
     {
        if (notifier == null) notifier = new Notifier(this);
        stateFetchTimeout = configuration.getLockAcquisitionTimeout() + 5000;
        if (configuration.isNodeLockingOptimistic())
        {
           root = NodeFactory.getInstance().createRootDataNode(NodeFactory.NodeType.VERSIONED_NODE, this);
        }
  
        setUseReplQueue(configuration.isUseReplQueue());
        setIsolationLevel(configuration.getIsolationLevel());
  
        // See if we had a TransactionManager injected into our config
        this.tm = configuration.getRuntimeConfig().getTransactionManager();
        if (tm == null)
        {
           // Nope. See if we can look it up from JNDI
           if (this.tm_lookup == null && configuration.getTransactionManagerLookupClass() != null)
           {
              Class clazz = Thread.currentThread().getContextClassLoader().loadClass(configuration.getTransactionManagerLookupClass());
              this.tm_lookup = (TransactionManagerLookup) clazz.newInstance();
           }
  
           try
           {
              if (tm_lookup != null)
              {
                 tm = tm_lookup.getTransactionManager();
                 configuration.getRuntimeConfig().setTransactionManager(tm);
              }
              else
              {
                 log.warn("No transaction manager lookup class has been defined. Transactions cannot be used");
              }
           }
           catch (Exception e)
           {
              log.debug("failed looking up TransactionManager, will not use transactions", e);
           }
        }
  
        // create cache loader
        if ((configuration.getCacheLoaderConfig() != null || cloaderConfig != null) && cacheLoaderManager == null)
        {
           initialiseCacheLoaderManager();
        }
  
        getRegionManager();// make sure we create one
        createEvictionPolicy();
  
        switch (configuration.getCacheMode())
        {
           case LOCAL:
              log.debug("cache mode is local, will not create the channel");
              break;
           case REPL_SYNC:
           case REPL_ASYNC:
           case INVALIDATION_ASYNC:
           case INVALIDATION_SYNC:
              if (log.isDebugEnabled()) log.debug("cache mode is " + configuration.getCacheMode());
              if (channel != null)
              {// already started
                 log.info("channel is already running");
                 return;
              }
  
              // Try to create a multiplexer channel
              channel = getMultiplexerChannel();
  
              if (channel != null)
              {// mux channel
                 if (log.isDebugEnabled())
                 {
                    log.debug("Created Multiplexer Channel for cache cluster " + configuration.getClusterName() +
                            " using stack " + configuration.getMultiplexerStack());
                 }
              }
              else
              {
                 if (configuration.getClusterConfig() == null)
                 {
                    configuration.setClusterConfig(getDefaultProperties());
                    log.debug("setting cluster properties to default value");
                 }
                 channel = new JChannel(configuration.getClusterConfig());
                 if (log.isTraceEnabled())
                 {
                    log.trace("cache properties: " + configuration.getClusterConfig());
                 }
              }
              channel.setOpt(Channel.AUTO_RECONNECT, true);
              channel.setOpt(Channel.AUTO_GETSTATE, true);
              channel.setOpt(Channel.BLOCK, true);
  
              /* Used for JMX jconsole for JDK5.0
                          ArrayList servers=MBeanServerFactory.findMBeanServer(null);
                          if(servers == null || servers.size() == 0) {
                              throw new Exception("No MBeanServers found;" +
                                                  "\nJmxTest needs to be run with an MBeanServer present, or inside JDK 5"); }
                          MBeanServer server=(MBeanServer)servers.get(0);
                          JmxConfigurator.registerChannel(channel, server, "JGroups:channel=" + channel.getChannelName() , true);
              */
  
              // always use the InactiveRegionAwareRpcDispatcher - exceptions due to regions not being active should not propagate to remote
              // nodes as errors. - Manik
              disp = new InactiveRegionAwareRpcDispatcher(channel, ml, this, this);
              //            disp = new RpcDispatcher(channel, ml, this, this);
  
  
              disp.setMarshaller(getMarshaller());
  
              setBuddyReplicationConfig(configuration.getBuddyReplicationConfig());
              break;
           default:
              throw new IllegalArgumentException("cache mode " + configuration.getCacheMode() + " is invalid");
        }
  
        // build interceptor chain
        interceptor_chain = new InterceptorChainFactory().buildInterceptorChain(this);
  
        getRegionManager().setDefaultInactive(configuration.isInactiveOnStartup());
  
        useCreateService = true;
     }
  
     protected boolean shouldFetchStateOnStartup()
     {
        boolean loaderFetch = cacheLoaderManager != null && cacheLoaderManager.isFetchPersistentState();
        return !configuration.isInactiveOnStartup() && buddyManager == null && (configuration.isFetchInMemoryState() || loaderFetch);
     }
  
     /**
      * Lifecyle method.
      *
      * @throws Exception
      */
     public void start() throws Exception
     {
  
        // Get around the problem of standalone user forgets to call create.
        if (!useCreateService)
        {
           create();
        }
  
        // cache loaders should be initialised *before* any state transfers take place to prevent
        // exceptions involving cache loaders not being started. - Manik
        if (cacheLoaderManager != null)
        {
           cacheLoaderManager.startCacheLoader();
        }
  
        switch (configuration.getCacheMode())
        {
           case LOCAL:
              break;
           case REPL_SYNC:
           case REPL_ASYNC:
           case INVALIDATION_ASYNC:
           case INVALIDATION_SYNC:
              channel.connect(configuration.getClusterName());
  
              if (log.isInfoEnabled())
              {
                 log.info("CacheImpl local address is " + channel.getLocalAddress());
              }
              if (shouldFetchStateOnStartup())
              {
                 try
                 {
                    fetchStateOnStartup();
                 }
                 catch (Exception e)
                 {
                    // make sure we disconnect from the channel before we throw this exception!
                    // JBCACHE-761
                    channel.disconnect();
                    channel.close();
                    throw e;
                 }
              }
              if (buddyManager != null)
              {
                 buddyManager.init(this);
                 if (configuration.isUseReplQueue())
                 {
                    log.warn("Replication queue not supported when using buddy replication.  Disabling repliction queue.");
                    configuration.setUseReplQueue(false);
                    repl_queue = null;
                 }
              }
              break;
           default:
              throw new IllegalArgumentException("cache mode " + configuration.getCacheMode() + " is invalid");
        }
  
        //now attempt to preload the cache from the loader - Manik
        if (cacheLoaderManager != null)
        {
           cacheLoaderManager.preloadCache();
        }
  
        // Find out if we are coordinator (blocks until view is received)
        // TODO should this be moved above the buddy manager code??
        determineCoordinator();
  
        // start any eviction threads.
        if (regionManager.isUsingEvictions())
        {
           regionManager.startEvictionThread();
        }
  
        notifier.notifyCacheStarted(this);
        started = true;
        log.info("JBoss Cache version: " + getVersion());
     }
  
     /**
      * No-op.
      */
     public void destroy()
     {
        useCreateService = false;
        regionManager = null;
        notifier = null;
     }
  
  
     /**
      * Lifecycle method.
      */
     public void stop()
     {
        if (channel != null)
        {
           log.info("stop(): closing the channel");
           channel.close();
           channel = null;
        }
        if (disp != null)
        {
           log.info("stop(): stopping the dispatcher");
           disp.stop();
           disp = null;
        }
        if (members != null && members.size() > 0)
        {
           members.clear();
        }
  
        coordinator = false;
  
        if (repl_queue != null)
        {
           repl_queue.stop();
        }
  
        if (cacheLoaderManager != null)
        {
           cacheLoaderManager.stopCacheLoader();
        }
  
        if (notifier != null)
        {
           notifier.notifyCacheStopped(this);
           notifier.removeAllCacheListeners();
           notifier.setEvictionPolicyListener(null);
        }
  
        useCreateService = false;
        started = false;
     }
  
     /* ----------------------- End of MBeanSupport ----------------------- */
  
     /* ----------------------- Start of buddy replication specific methods ------------*/
  
     /**
      * Sets the buddy replication configuration element
      *
      * @param config
      */
     private void setBuddyReplicationConfig(BuddyReplicationConfig config)
     {
        if (config != null)
        {
           buddyManager = new BuddyManager(config);
           if (!buddyManager.isEnabled())
           {
              buddyManager = null;
           }
           else
           {
              internalFqns.add(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
           }
        }
     }
  
     /**
      * Retrieves the Buddy Manager configured.
      *
      * @return null if buddy replication is not enabled.
      */
     public BuddyManager getBuddyManager()
     {
        return buddyManager;
     }
  
     /**
      * Returns a Set<Fqn> of Fqns of the topmost node of internal regions that
      * should not included in standard state transfers. Will include
      * {@link BuddyManager#BUDDY_BACKUP_SUBTREE} if buddy replication is
      * enabled.
      *
      * @return an unmodifiable Set<Fqn>.  Will not return <code>null</code>.
      */
     public Set getInternalFqns()
     {
        return Collections.unmodifiableSet(internalFqns);
     }
  
     /* ----------------------- End of buddy replication specific methods ------------*/
  
     protected void createEvictionPolicy()
     {
        if (configuration.getEvictionConfig() != null
                && configuration.getEvictionConfig().isValidConfig())
        {
           regionManager.setEvictionConfig(configuration.getEvictionConfig());
           regionManager.setUsingEvictions(true);
        }
        else
        {
           regionManager.setUsingEvictions(false);
           log.debug("Not using an EvictionPolicy");
        }
     }
  
     /**
      * Loads the indicated Fqn, plus all parents recursively from the
      * CacheLoader. If no CacheLoader is present, this is a no-op
      *
      * @param fqn
      * @throws Exception
      */
     public void load(String fqn) throws Exception
     {
        if (cacheLoaderManager != null)
        {
           cacheLoaderManager.preload(Fqn.fromString(fqn), true, true);
        }
     }
  
     protected void determineCoordinator()
     {
        // Synchronize on members to make the answer atomic for the current view
        synchronized (members)
        {
           Address coord = getCoordinator();
           coordinator = (coord == null ? false : coord.equals(getLocalAddress()));
        }
     }
  
     /**
      * Returns the address of the coordinator or null if there is no
      * coordinator.
      */
     public Address getCoordinator()
     {
        if (channel == null)
        {
           return null;
        }
  
        synchronized (members)
        {
           if (members.size() == 0)
           {
              log.debug("getCoordinator(): waiting on viewAccepted()");
              try
              {
                 members.wait();
              }
              catch (InterruptedException iex)
              {
                 log.error("getCoordinator(): Interrupted while waiting for members to be set", iex);
              }
           }
           return members.size() > 0 ? (Address) members.get(0) : null;
        }
     }
  
     // -----------  Marshalling and State Transfer -----------------------
  
     /**
      * Registers a specific classloader for a region defined by a fully
      * qualified name.
      * A instance of {@link org.jboss.cache.marshall.Marshaller} is used for marshalling.
      *
      * @param fqn The fqn region. Children of this fqn will use this classloader for (un)marshalling.
      * @param cl  The class loader to use
      * @throws RegionNameConflictException If there is a conflict in existing registering for the fqn.
      * @throws IllegalStateException       if marshalling is not being used
      * @see #getMarshaller
      */
     public void registerClassLoader(String fqn, ClassLoader cl) throws RegionNameConflictException
     {
        regionManager.registerClassLoader(Fqn.fromString(fqn), cl);
     }
  
     /**
      * Unregisters a class loader for a region.
      *
      * @param fqn The fqn region.
      * @throws RegionNotFoundException If there is a conflict in fqn specification.
      * @throws IllegalStateException   if marshalling is not being used
      */
     public void unregisterClassLoader(String fqn) throws RegionNotFoundException
     {
        regionManager.unregisterClassLoader(Fqn.fromString(fqn));
     }
  
     /**
      * Creates a subtree in the local cache.
      * Returns the DataNode created.
      */
     protected Node createSubtreeRootNode(Fqn subtree) throws CacheException
     {
        NodeSPI parent = root;
        NodeSPI child = null;
        Object owner = getOwnerForLock();
        Object name;
        NodeFactory factory = NodeFactory.getInstance();
        NodeFactory.NodeType type = configuration.isNodeLockingOptimistic()
                ? NodeFactory.NodeType.VERSIONED_NODE
                : NodeFactory.NodeType.UNVERSIONED_NODE;
  
        for (int i = 0; i < subtree.size(); i++)
        {
           name = subtree.get(i);
           child = (NodeSPI) parent.getChild(new Fqn(name));
           if (child == null)
           {
              // Lock the parent, create and add the child
              try
              {
                 parent.getLock().acquire(owner, configuration.getSyncReplTimeout(), NodeLock.LockType.WRITE);
              }
              catch (InterruptedException e)
              {
                 log.error("Interrupted while locking" + parent.getFqn(), e);
                 throw new CacheException(e.getLocalizedMessage(), e);
              }
  
              try
              {
                 child = (NodeSPI) factory.createDataNode(type, name,
                         subtree.getFqnChild(i + 1),
                         parent, null, true, null, this);
                 parent.addChild(name, child);
              }
              finally
              {
                 if (log.isDebugEnabled())
                 {
                    log.debug("forcing release of locks in " + parent.getFqn());
                 }
                 try
                 {
                    parent.getNodeSPI().getLock().releaseAll();
                 }
                 catch (Throwable t)
                 {
                    log.error("failed releasing locks", t);
                 }
              }
           }
  
           parent = child;
        }
  
        return child;
     }
  
     /**
      * Evicts the node at <code>subtree</code> along with all descendant nodes.
      *
      * @param subtree Fqn indicating the uppermost node in the
      *                portion of the cache that should be evicted.
      * @throws CacheException
      */
     protected void _evictSubtree(Fqn subtree) throws CacheException
     {
  
        if (!exists(subtree))
        {
           return;// node does not exist. Maybe it has been recursively removed.
        }
  
        if (log.isTraceEnabled())
        {
           log.trace("_evictSubtree(" + subtree + ")");
        }
  
        // Recursively remove any children
        Set children = getChildrenNames(subtree);
        if (children != null)
        {
           Object[] kids = children.toArray();
  
           for (int i = 0; i < kids.length; i++)
           {
              Object s = kids[i];
              Fqn tmp = new Fqn(subtree, s);
              _remove(null, // no tx
                      tmp,
                      false, // no undo ops
                      false, // no nodeEvent
                      true);// is an eviction
           }
        }
  
        // Remove the root node of the subtree
        _remove(null, subtree, false, false, true);
  
     }
  
     /**
      * Returns the state for the portion of the cache named by <code>fqn</code>.
      * <p/>
      * State returned is a serialized byte[][], element 0 is the transient state
      * (or null), and element 1 is the persistent state (or null).
      *
      * @param fqn            Fqn indicating the uppermost node in the
      *                       portion of the cache whose state should be returned.
      * @param timeout        max number of ms this method should wait to acquire
      *                       a read lock on the nodes being transferred
      * @param force          if a read lock cannot be acquired after
      *                       <code>timeout</code> ms, should the lock acquisition
      *                       be forced, and any existing transactions holding locks
      *                       on the nodes be rolled back? <strong>NOTE:</strong>
      *                       In release 1.2.4, this parameter has no effect.
      * @param suppressErrors should any Throwable thrown be suppressed?
      * @return a serialized byte[][], element 0 is the transient state
      *         (or null), and element 1 is the persistent state (or null).
      *         <p/>
      *         <p/>
      *         TODO here only because of BuddyManager state transfer
      *         Consider for removal if BuddyManager transfer changes
      */
     public byte[] generateState(Fqn fqn, long timeout, boolean force, boolean suppressErrors) throws Throwable
     {
  
        MarshalledValueOutputStream out = null;
        byte[] result = null;
        try
        {
           ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
           out = new MarshalledValueOutputStream(baos);
           getStateTransferManager().getState(out, fqn, timeout, force, suppressErrors);
           result = baos.getRawBuffer();
        }
        finally
        {
           Util.close(out);
        }
  
        return result;
     }
  
     private void removeLocksForDeadMembers(Node node,
                                            Vector deadMembers)
     {
        Set deadOwners = new HashSet();
        NodeLock lock = node.getNodeSPI().getLock();
        Object owner = lock.getWriterOwner();
  
        if (isLockOwnerDead(owner, deadMembers))
        {
           deadOwners.add(owner);
        }
  
        Iterator iter = lock.getReaderOwners().iterator();
        while (iter.hasNext())
        {
           owner = iter.next();
           if (isLockOwnerDead(owner, deadMembers))
           {
              deadOwners.add(owner);
           }
        }
  
        for (iter = deadOwners.iterator(); iter.hasNext();)
        {
           GlobalTransaction deadOwner = (GlobalTransaction) iter.next();
           boolean localTx = deadOwner.getAddress().equals(getLocalAddress());
           boolean broken = LockUtil.breakTransactionLock(lock, deadOwner, localTx, this);
  
           if (broken && log.isTraceEnabled())
           {
              log.trace("Broke lock for node " + node.getFqn() +
                      " held by " + deadOwner);
           }
        }
  
        // Recursively unlock children
        for (Node child : node.getChildren())
        {
           removeLocksForDeadMembers(child, deadMembers);
        }
     }
  
     private boolean isLockOwnerDead(Object owner, Vector deadMembers)
     {
        boolean result = false;
        if (owner != null && owner instanceof GlobalTransaction)
        {
           Object addr = ((GlobalTransaction) owner).getAddress();
           result = deadMembers.contains(addr);
        }
        return result;
     }
  
     protected void fetchStateOnStartup() throws Exception
     {
        long start, stop;
        isStateSet = false;
        start = System.currentTimeMillis();
        boolean rc = channel.getState(null, stateFetchTimeout);
        if (rc)
        {
           ml.waitForState();
           stop = System.currentTimeMillis();
           if (log.isDebugEnabled())
           {
              log.debug("state was retrieved successfully (in " + (stop - start) + " milliseconds)");
           }
        }
        else
        {
           // No one provided us with state. We need to find out if that's because
           // we are the coordinator. But we don't know if the viewAccepted() callback
           // has been invoked, so call determineCoordinator(), which will block until
           // viewAccepted() is called at least once
           determineCoordinator();
  
           if (isCoordinator())
           {
              log.debug("State could not be retrieved (we are the first member in group)");
           }
           else
           {
              throw new CacheException("Initial state transfer failed: " +
                      "Channel.getState() returned false");
           }
        }
     }
  
     // -----------  End Marshalling and State Transfer -----------------------
  
     /**
      * @param fqn fqn String name to retrieve from cache
      * @return DataNode corresponding to the fqn. Null if does not exist. No guarantees wrt replication,
      *         cache loading are given if the underlying node is modified
      */
     public Node get(String fqn) throws CacheException
     {
        return get(Fqn.fromString(fqn));
     }
  
     /**
      * Returns a DataNode corresponding to the fully qualified name or null if
      * does not exist.
      * No guarantees wrt replication, cache loading are given if the underlying node is modified
      *
      * @param fqn name of the DataNode to retreive
      */
     public Node get(Fqn fqn) throws CacheException
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.getNodeMethodLocal, fqn);
        return (Node) invokeMethod(m);
     }
  
     /**
      * Returns the raw data of the node; called externally internally.
      */
     public Node _get(Fqn fqn) throws CacheException
     {
        return findNode(fqn);
     }
  
     /**
      * Returns the raw data of the node; called externally internally.
      */
     public Map _getData(Fqn fqn)
     {
        Node n = findNode(fqn);
        if (n == null) return null;
        return n.getNodeSPI().getRawData();
     }
  
     /**
      * Returns a set of attribute keys for the Fqn.
      * Returns null if the node is not found, otherwise a Set.
      * The set is a copy of the actual keys for this node.
      *
      * @param fqn name of the node
      */
     public Set getKeys(String fqn) throws CacheException
     {
        return getKeys(Fqn.fromString(fqn));
     }
  
     /**
      * Returns a set of attribute keys for the Fqn.
      * Returns null if the node is not found, otherwise a Set.
      * The set is a copy of the actual keys for this node.
      *
      * @param fqn name of the node
      */
     public Set getKeys(Fqn fqn) throws CacheException
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.getKeysMethodLocal, fqn);
        return (Set) invokeMethod(m);
     }
  
  
     public Set _getKeys(Fqn fqn) throws CacheException
     {
        Node n = findNode(fqn);
        if (n == null)
        {
           return null;
        }
        Set keys = n.getNodeSPI().getRawData().keySet();
        // See http://jira.jboss.com/jira/browse/JBCACHE-551
        if (keys == null)
        {
           return new HashSet(0);
        }
        return new HashSet(keys);
     }
  
     /**
      * Finds a node given its name and returns the value associated with a given key in its <code>data</code>
      * map. Returns null if the node was not found in the cache or the key was not found in the hashmap.
      *
      * @param fqn The fully qualified name of the node.
      * @param key The key.
      */
     public Object get(String fqn, Object key) throws CacheException
     {
        return get(Fqn.fromString(fqn), key);
     }
  
  
     /**
      * Finds a node given its name and returns the value associated with a given key in its <code>data</code>
      * map. Returns null if the node was not found in the cache or the key was not found in the hashmap.
      *
      * @param fqn The fully qualified name of the node.
      * @param key The key.
      */
     public Object get(Fqn fqn, Object key) throws CacheException
     {
        return get(fqn, key, true);
     }
  
     public Object _get(Fqn fqn, Object key, boolean sendNodeEvent) throws CacheException
     {
        if (log.isTraceEnabled())
        {
           log.trace(new StringBuffer("_get(").append("\"").append(fqn).append("\", \"").append(key).append("\", \"").
                   append(sendNodeEvent).append("\")"));
        }
        if (sendNodeEvent) notifier.notifyNodeVisited(fqn, true);
        Node n = findNode(fqn);
        if (n == null)
        {
           log.trace("node not found");
           return null;
        }
        if (sendNodeEvent) notifier.notifyNodeVisited(fqn, false);
        return n.get(key);
     }
  
  
     protected Object get(Fqn fqn, Object key, boolean sendNodeEvent) throws CacheException
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.getKeyValueMethodLocal, fqn, key, sendNodeEvent);
        return invokeMethod(m);
     }
  
     /**
      * Like <code>get()</code> method but without triggering a node visit event. This is used
      * to prevent refresh of the cache data in the eviction policy.
      *
      * @param fqn
      * @param key
      * @deprecated This will go away.
      */
     public Object peek(Fqn fqn, Object key) throws CacheException
     {
        return get(fqn, key, false);
     }
  
  
     /**
      * added so one can get nodes internally without triggering stuff
      *
      * @deprecated This will go away.
      */
     public NodeSPI peek(Fqn fqn)
     {
        return findInternal(fqn, true);
     }
  
     /**
      * Checks whether a given node exists in current in-memory state of the cache.
      * Does not acquire any locks in doing so (result may be dirty read). Does
      * not attempt to load nodes from a cache loader (may return false if a
      * node has been evicted).
      *
      * @param fqn The fully qualified name of the node
      * @return boolean Whether or not the node exists
      */
     public boolean exists(String fqn)
     {
        return exists(Fqn.fromString(fqn));
     }
  
  
     /**
      * Checks whether a given node exists in current in-memory state of the cache.
      * Does not acquire any locks in doing so (result may be dirty read). Does
      * not attempt to load nodes from a cache loader (may return false if a
      * node has been evicted).
      *
      * @param fqn The fully qualified name of the node
      * @return boolean Whether or not the node exists
      */
     public boolean exists(Fqn fqn)
     {
        Node n = findInternal(fqn, false);
        return n != null;
     }
  
     /**
      * Gets node without attempt to load it from CacheLoader if not present
      *
      * @param fqn
      */
     private NodeSPI findInternal(Fqn fqn, boolean includeNodesMarkedAsRemoved)
     {
        if (fqn == null || fqn.size() == 0) return root;
        NodeSPI n = root;
        int fqnSize = fqn.size();
        for (int i = 0; i < fqnSize; i++)
        {
           Object obj = fqn.get(i);
           n = (NodeSPI) n.getNodeSPI().getChildrenMap().get(obj);
           if (n == null)
           {
              return null;
           }
           else if (!includeNodesMarkedAsRemoved && n.isDeleted())
           {
              return null;
           }
        }
        return n;
     }
  
  
     /**
      * @param fqn
      * @param key
      */
     public boolean exists(String fqn, Object key)
     {
        return exists(Fqn.fromString(fqn), key);
     }
  
  
     /**
      * Checks whether a given key exists in the given node. Does not interact with CacheLoader, so the behavior is
      * different from {@link #get(Fqn,Object)}
      *
      * @param fqn The fully qualified name of the node
      * @param key
      * @return boolean Whether or not the node exists
      */
     public boolean exists(Fqn fqn, Object key)
     {
        Node n = findInternal(fqn, false);
        if (n == null)
        {
           return false;
        }
        else
        {
           return n.getKeys().contains(key);
        }
     }
  
  
     /**
      * Adds a new node to the cache and sets its data. If the node doesn not yet exist, it will be created.
      * Also, parent nodes will be created if not existent. If the node already has data, then the new data
      * will override the old one. If the node already existed, a nodeModified() notification will be generated.
      * Otherwise a nodeCreated() motification will be emitted.
      *
      * @param fqn  The fully qualified name of the new node
      * @param data The new data. May be null if no data should be set in the node.
      */
     public void put(String fqn, Map data) throws CacheException
     {
        put(Fqn.fromString(fqn), data);
     }
  
     /**
      * Sets a node's data. If the node does not yet exist, it will be created.
      * Also, parent nodes will be created if not existent. If the node already has data, then the new data
      * will override the old one. If the node already existed, a nodeModified() notification will be generated.
      * Otherwise a nodeCreated() motification will be emitted.
      *
      * @param fqn  The fully qualified name of the new node
      * @param data The new data. May be null if no data should be set in the node.
      */
     public void put(Fqn fqn, Map data) throws CacheException
     {
        GlobalTransaction tx = getCurrentTransaction();
        MethodCall m = MethodCallFactory.create(MethodDeclarations.putDataMethodLocal, tx, fqn, data, true);
        invokeMethod(m);
     }
  
     /**
      * Adds a key and value to a given node. If the node doesn't exist, it will be created. If the node
      * already existed, a nodeModified() notification will be generated. Otherwise a
      * nodeCreated() motification will be emitted.
      *
      * @param fqn   The fully qualified name of the node
      * @param key   The key
      * @param value The value
      * @return Object The previous value (if any), if node was present
      */
     public Object put(String fqn, Object key, Object value) throws CacheException
     {
        return put(Fqn.fromString(fqn), key, value);
     }
  
     /**
      * Adds a key and value to a given node. If the node doesn't exist, it will be created. If the node
      * already existed, a nodeModified() notification will be generated. Otherwise a
      * nodeCreated() motification will be emitted.
      *
      * @param fqn   The fully qualified name of the node
      * @param key   The key
      * @param value The value
      * @return Object The previous value (if any), if node was present
      */
     public Object put(Fqn fqn, Object key, Object value) throws CacheException
     {
        GlobalTransaction tx = getCurrentTransaction();
        MethodCall m = MethodCallFactory.create(MethodDeclarations.putKeyValMethodLocal, tx, fqn, key, value, true);
        return invokeMethod(m);
     }
  
     /**
      * Removes the node from the cache.
      *
      * @param fqn The fully qualified name of the node.
      */
     public void remove(String fqn) throws CacheException
     {
        remove(Fqn.fromString(fqn));
     }
  
     /**
      * Removes the node from the cache.
      *
      * @param fqn The fully qualified name of the node.
      */
     public void remove(Fqn fqn) throws CacheException
     {
        GlobalTransaction tx = getCurrentTransaction();
        MethodCall m = MethodCallFactory.create(MethodDeclarations.removeNodeMethodLocal, tx, fqn, true);
        invokeMethod(m);
     }
  
     /**
      * Called by eviction policy provider. Note that eviction is done only in
      * local mode, that is, it doesn't replicate the node removal. This will
      * cause the replication nodes to not be synchronizing, which is fine since
      * the value will be fetched again when {@link #get} returns null. After
      * that, the contents will be in sync.
      *
      * @param fqn Will remove everythign assoicated with this fqn.
      * @throws CacheException
      */
     public void evict(Fqn fqn) throws CacheException
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.evictNodeMethodLocal, fqn);
        invokeMethod(m);
     }
  
     /**
      * Removes <code>key</code> from the node's hashmap
      *
      * @param fqn The fullly qualified name of the node
      * @param key The key to be removed
      * @return The previous value, or null if none was associated with the given key
      */
     public Object remove(String fqn, Object key) throws CacheException
     {
        return remove(Fqn.fromString(fqn), key);
     }
  
     /**
      * Removes <code>key</code> from the node's hashmap
      *
      * @param fqn The fullly qualified name of the node
      * @param key The key to be removed
      * @return The previous value, or null if none was associated with the given key
      */
     public Object remove(Fqn fqn, Object key) throws CacheException
     {
        GlobalTransaction tx = getCurrentTransaction();
        MethodCall m = MethodCallFactory.create(MethodDeclarations.removeKeyMethodLocal, tx, fqn, key, true);
        return invokeMethod(m);
     }
  
     /**
      * Removes the keys and properties from a node.
      */
     public void removeData(String fqn) throws CacheException
     {
        removeData(Fqn.fromString(fqn));
     }
  
     /**
      * Removes the keys and properties from a named node.
      */
     public void removeData(Fqn fqn) throws CacheException
     {
        GlobalTransaction tx = getCurrentTransaction();
        MethodCall m = MethodCallFactory.create(MethodDeclarations.removeDataMethodLocal, tx, fqn, true);
        invokeMethod(m);
     }
  
     /**
      * Lock a given node (or the entire subtree starting at this node)
      * @param fqn The FQN of the node
      * @param owner The owner. This is simply a key into a hashtable, and can be anything, e.g.
      * a GlobalTransaction, the current thread, or a special object. If null, it is set to Thread.currentThread()
      * @param lock_type The type of lock (RO, RW). Needs to be of type DataNode.LOCK_TYPE_READ or DataNode.LOCK_TYPE_WRITE
      * @param lock_recursive If true, the entire subtree is locked, else only the given node
      * @throws CacheException If node doesn't exist, a NodeNotExistsException is throw. Other exceptions are
      * LockingException, TimeoutException and UpgradeException
      */
     //   public void lock(Fqn fqn, Object owner, int lock_type, boolean lock_recursive) throws CacheException {
     //
     //   }
  
     /**
      * Unlock a given node (or the entire subtree starting at this node)
      * @param fqn The FQN of the node
      * @param owner The owner. This is simply a key into a hashtable, and can be anything, e.g.
      * a GlobalTransaction, the current thread, or a special object. If null, it is set to Thread.currentThread()
      * @param unlock_recursive If true, the entire subtree is unlocked, else only the given node
      * @param force Release the lock even if we're not the owner
      */
     //   public void unlock(Fqn fqn, Object owner, boolean unlock_recursive, boolean force) {
     //
     //   }
  
     /**
      * Releases all locks for this node and the entire node subtree.
      */
     public void releaseAllLocks(String fqn)
     {
        releaseAllLocks(Fqn.fromString(fqn));
     }
  
     /**
      * Releases all locks for this node and the entire node subtree.
      */
     public void releaseAllLocks(Fqn fqn)
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.releaseAllLocksMethodLocal, fqn);
        try
        {
           invokeMethod(m);
        }
        catch (CacheException e)
        {
           log.error("failed releasing all locks for " + fqn, e);
        }
     }
  
     /**
      * Prints a representation of the node defined by <code>fqn</code>.
      * Output includes name, fqn and data.
      */
     public String print(String fqn)
     {
        return print(Fqn.fromString(fqn));
     }
  
     /**
      * Prints a representation of the node defined by <code>fqn</code>.
      * Output includes name, fqn and data.
      */
     public String print(Fqn fqn)
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.printMethodLocal, fqn);
        Object retval = null;
        try
        {
           retval = invokeMethod(m);
        }
        catch (Throwable e)
        {
           retval = e;
        }
        if (retval != null)
        {
           return retval.toString();
        }
        else
        {
           return "";
        }
     }
  
  
     /**
      * Returns all children of a given node.
      * Returns null of the parent node was not found, or if there are no
      * children.
      * The set is unmodifiable.
      *
      * @param fqn The fully qualified name of the node
      * @return Set A list of child names (as Strings)
      * @see #getChildrenNames(Fqn)
      */
     public Set getChildrenNames(String fqn) throws CacheException
     {
        return getChildrenNames(Fqn.fromString(fqn));
     }
  
     /**
      * Returns all children of a given node.
      * Returns null of the parent node was not found, or if there are no
      * children.
      * The set is unmodifiable.
      *
      * @param fqn The fully qualified name of the node
      * @return Set an unmodifiable set of children names, Object.
      */
     public Set getChildrenNames(Fqn fqn) throws CacheException
     {
        MethodCall m = MethodCallFactory.create(MethodDeclarations.getChildrenNamesMethodLocal, fqn);
        return (Set) invokeMethod(m);
     }
  
     public Set _getChildrenNames(Fqn fqn) throws CacheException
     {
        Node n = findNode(fqn);
        if (n == null) return null;
        Set s = n.getChildrenNames();
        return s;
     }
  
     /**
      * Returns true if the FQN exists and the node has children.
      */
     public boolean hasChild(Fqn fqn)
     {
        if (fqn == null) return false;
  
        Node n = root;
        Object obj;
        for (int i = 0; i < fqn.size(); i++)
        {
           obj = fqn.get(i);
           n = n.getNodeSPI().getChildrenMap().get(obj);
           if (n == null)
           {
              return false;
           }
        }
        return !n.getNodeSPI().getChildrenMap().isEmpty();
     }
  
     /**
      * Returns a debug string with few details.
      */
     public String toString()
     {
        return toString(true);
     }
  
  
     /**
      * Returns a debug string with optional details of contents.
      */
     public String toString(boolean details)
     {
        StringBuffer sb = new StringBuffer();
        int indent = 0;
  
        if (!details)
        {
           sb.append(getClass().getName()).append(" [").append(getNumberOfNodes()).append(" nodes, ");
           sb.append(getNumberOfLocksHeld()).append(" locks]");
        }
        else
        {
           Map<Object, Node> children;
           children = root.getNodeSPI().getChildrenMap();
           for (Node n : children.values())
           {
              n.getNodeSPI().print(sb, indent);
              sb.append("\n");
           }
        }
        return sb.toString();
     }
  
  
     /**
      * Prints information about the contents of the nodes in the cache's current
      * in-memory state.  Does not load any previously evicted nodes from a
      * cache loader, so evicted nodes will not be included.
      */
     public String printDetails()
     {
        StringBuffer sb = new StringBuffer();
        root.printDetails(sb, 0);
        sb.append("\n");
        return sb.toString();
     }
  
     /**
      * Returns lock information.
      */
     public String printLockInfo()
     {
        StringBuffer sb = new StringBuffer("\n");
        int indent = 0;
  
        for (Node n : root.getNodeSPI().getChildrenMap().values())
        {
           n.getNodeSPI().getLock().printLockInfo(sb, indent);
           sb.append("\n");
        }
        return sb.toString();
     }
  
     /**
      * Returns the number of read or write locks held across the entire cache.
      */
     public int getNumberOfLocksHeld()
     {
        return numLocks(root);
     }
  
     private int numLocks(Node n)
     {
        int num = 0;
        if (n.getNodeSPI().getLock().isLocked())
        {
           num++;
        }
        for (Node cn : n.getNodeSPI().getChildren(true))
        {
           num += numLocks(cn);
        }
        return num;
     }
  
     /**
      * Returns an <em>approximation</em> of the total number of nodes in the
      * cache. Since this method doesn't acquire any locks, the number might be
      * incorrect, or the method might even throw a
      * ConcurrentModificationException
      */
     public int getNumberOfNodes()
     {
        return numNodes(root) - 1;
     }
  
     private int numNodes(Node n)
     {
        if (n == null)
        {
           return 0;
        }
        int count = 1;// for n
        for (Node child : n.getNodeSPI().getChildrenMap().values())
        {
           count += numNodes(child);
        }
        return count;
     }
  
     /**
      * Returns an <em>approximation</em> of the total number of attributes in
      * the cache. Since this method doesn't acquire any locks, the number might
      * be incorrect, or the method might even throw a
      * ConcurrentModificationException
      */
     public int getNumberOfAttributes()
     {
        return numAttributes(getRoot());
     }
  
     /**
      * Returns an <em>approximation</em> of the total number of attributes in
      * this sub cache.
      *
      * @see #getNumberOfAttributes
      */
     public int getNumberOfAttributes(Fqn fqn)
     {
        Node n = findNode(fqn);
        return numAttributes(n);
     }
  
     private int numAttributes(Node n)
     {
        Map<Object, Node> children = n.getNodeSPI().getChildrenMap();
        int count = 0;
        for (Node child : children.values())
        {
           count += numAttributes(child);
        }
        count += n.getData().size();
        return count;
     }
  
     /* ---------------------- Remote method calls -------------------- */
  
     /**
      * @param mbrs
      * @param method_call
      * @param synchronous
      * @param exclude_self
      * @param timeout
      * @return
      * @throws Exception
      * @deprecated Note this is due to be moved to an interceptor.
      */
     public List callRemoteMethods(List mbrs, MethodCall method_call,
                                   boolean synchronous, boolean exclude_self, long timeout)
             throws Exception
     {
        return callRemoteMethods(mbrs, method_call, synchronous ? GroupRequest.GET_ALL : GroupRequest.GET_NONE, exclude_self, timeout);
     }
  
  
     /**
      * Overloaded to allow a finer grained control over JGroups mode
      *
      * @param mbrs
      * @param method_call
      * @param mode
      * @param exclude_self
      * @param timeout
      * @return
      * @throws Exception
      * @deprecated Note this is due to be moved to an interceptor.
      */
     public List callRemoteMethods(List mbrs, MethodCall method_call, int mode, boolean exclude_self, long timeout)
             throws Exception
     {
        RspList rsps;
        Rsp rsp;
        List retval;
        Vector validMembers;
  
        if (disp == null)
        {
           return null;
        }
  
        validMembers = mbrs != null ? new Vector(mbrs) : new Vector(this.members);
        if (exclude_self && validMembers.size() > 0)
        {
           Object local_addr = getLocalAddress();
           if (local_addr != null)
           {
              validMembers.remove(local_addr);
           }
        }
        if (validMembers.size() == 0)
        {
           if (log.isTraceEnabled())
           {
              log.trace("destination list is empty, discarding call");
           }
           return null;
        }
  
        if (log.isTraceEnabled())
        {
           log.trace("callRemoteMethods(): valid members are " + validMembers + " methods: " + method_call.getArgs()[0]);
        }
  
        rsps = disp.callRemoteMethods(validMembers, method_call, mode, timeout, buddyManager != null && buddyManager.isEnabled());
  
        // a null response is 99% likely to be due to a marshalling problem - we throw a NSE, this needs to be changed when
        // JGroups supports http://jira.jboss.com/jira/browse/JGRP-193
        if (rsps == null)
        {
           // return null;
           throw new NotSerializableException("RpcDispatcher returned a null.  This is most often caused by args for " + method_call + " not being serializable.");
        }
  
        if (mode == GroupRequest.GET_NONE)
        {
           return new ArrayList();// async case
        }
  
        if (log.isTraceEnabled())
        {
           log.trace("(" + getLocalAddress() + "): responses for method " + method_call.getName() + ":\n" + rsps);
        }
  
        retval = new ArrayList(rsps.size());
        for (int i = 0; i < rsps.size(); i++)
        {
           rsp = (Rsp) rsps.elementAt(i);
           if (rsp.wasSuspected() || !rsp.wasReceived())
           {
              CacheException ex;
              if (rsp.wasSuspected())
              {
                 ex = new SuspectException("suspected member: " + rsp.getSender());
              }
              else
              {
                 ex = new TimeoutException("timeout for " + rsp.getSender());
              }
              retval.add(new ReplicationException("rsp=" + rsp, ex));
           }
           else
           {
              retval.add(rsp.getValue());
           }
        }
        return retval;
     }
  
     /**
      * @param members
      * @param method
      * @param args
      * @param synchronous
      * @param exclude_self
      * @param timeout
      * @return
      * @throws Exception
      * @deprecated Note this is due to be moved to an interceptor.
      */
     public List callRemoteMethods(List members, Method method, Object[] args,
                                   boolean synchronous, boolean exclude_self, long timeout)
             throws Exception
     {
        return callRemoteMethods(members, MethodCallFactory.create(method, args), synchronous, exclude_self, timeout);
     }
  
     public List callRemoteMethods(Vector members, Method method, Object[] args,
                                   boolean synchronous, boolean exclude_self, long timeout)
             throws Exception
     {
        return callRemoteMethods(members, MethodCallFactory.create(method, args), synchronous, exclude_self, timeout);
     }
  
     /**
      * @param members
      * @param method_name
      * @param types
      * @param args
      * @param synchronous
      * @param exclude_self
      * @param timeout
      * @return
      * @throws Exception
      * @deprecated Note this is due to be moved to an interceptor.
      */
     public List callRemoteMethods(Vector members, String method_name,
                                   Class[] types, Object[] args,
                                   boolean synchronous, boolean exclude_self, long timeout)
             throws Exception
     {
        Method method = getClass().getDeclaredMethod(method_name, types);
        return callRemoteMethods(members, method, args, synchronous, exclude_self, timeout);
     }
  
     /* -------------------- End Remote method calls ------------------ */
  
     /* --------------------- Callbacks -------------------------- */
  
     /* ----- These are VERSIONED callbacks to facilitate JBCACHE-843.  Also see docs/design/DataVersion.txt --- */
  
     public void _put(GlobalTransaction tx, Fqn fqn, Map data, boolean create_undo_ops, DataVersion dv) throws CacheException
     {
        _put(tx, fqn, data, create_undo_ops, false, dv);
     }
  
     public void _put(GlobalTransaction tx, Fqn fqn, Map data, boolean create_undo_ops, boolean erase_contents, DataVersion dv) throws CacheException
     {
        _put(tx, fqn, data, create_undo_ops, erase_contents);
     }
  
     public Object _put(GlobalTransaction tx, Fqn fqn, Object key, Object value, boolean create_undo_ops, DataVersion dv) throws CacheException
     {
        return _put(tx, fqn, key, value, create_undo_ops);
     }
  
     public void _remove(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, DataVersion dv) throws CacheException
     {
        _remove(tx, fqn, create_undo_ops, true);
     }
  
     public Object _remove(GlobalTransaction tx, Fqn fqn, Object key, boolean create_undo_ops, DataVersion dv) throws CacheException
     {
        return _remove(tx, fqn, key, create_undo_ops);
     }
  
     public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, DataVersion dv) throws CacheException
     {
  
        _removeData(tx, fqn, create_undo_ops, true);
     }
  
     /* ----- End VERSIONED callbacks - Now for the NORMAL callbacks. -------- */
  
     /**
      * Internal put method.
      * Does the real work. Needs to acquire locks if accessing nodes, depending on
      * the value of <tt>locking</tt>. If run inside a transaction, needs to (a) add
      * newly acquired locks to {@link TransactionEntry}'s lock list, (b) add nodes
      * that were created to {@link TransactionEntry}'s node list and (c) create
      * {@link Modification}s and add them to {@link TransactionEntry}'s modification
      * list and (d) create compensating modifications to undo the changes in case
      * of a rollback
      *
      * @param fqn
      * @param data
      * @param create_undo_ops If true, undo operations will be created (default is true).
      *                        Otherwise they will not be created (used by rollback()).
      */
     public void _put(GlobalTransaction tx, String fqn, Map data, boolean create_undo_ops)
             throws CacheException
     {
        _put(tx, Fqn.fromString(fqn), data, create_undo_ops);
     }
  
  
     /**
      * Internal put method.
      * Does the real work. Needs to acquire locks if accessing nodes, depending on
      * the value of <tt>locking</tt>. If run inside a transaction, needs to (a) add
      * newly acquired locks to {@link TransactionEntry}'s lock list, (b) add nodes
      * that were created to {@link TransactionEntry}'s node list and (c) create
      * {@link Modification}s and add them to {@link TransactionEntry}'s modification
      * list and (d) create compensating modifications to undo the changes in case
      * of a rollback
      *
      * @param fqn
      * @param data
      * @param create_undo_ops If true, undo operations will be created (default is true).
      *                        Otherwise they will not be created (used by rollback()).
      */
     public void _put(GlobalTransaction tx, Fqn fqn, Map data, boolean create_undo_ops)
             throws CacheException
     {
        _put(tx, fqn, data, create_undo_ops, false);
     }
  
     /**
      * Internal put method.
      * Does the real work. Needs to acquire locks if accessing nodes, depending on
      * the value of <tt>locking</tt>. If run inside a transaction, needs to (a) add
      * newly acquired locks to {@link TransactionEntry}'s lock list, (b) add nodes
      * that were created to {@link TransactionEntry}'s node list and (c) create
      * {@link Modification}s and add them to {@link TransactionEntry}'s modification
      * list and (d) create compensating modifications to undo the changes in case
      * of a rollback
      *
      * @param fqn
      * @param data
      * @param create_undo_ops If true, undo operations will be created (default is true).
      * @param erase_contents  Clear the existing hashmap before putting the new data into it
      *                        Otherwise they will not be created (used by rollback()).
      */
     public void _put(GlobalTransaction tx, Fqn fqn, Map data, boolean create_undo_ops, boolean erase_contents)
             throws CacheException
     {
        if (log.isTraceEnabled())
        {
           log.trace("_put(" + tx + ", \"" + fqn + "\", " + data + " undo=" + create_undo_ops + " erase=" + erase_contents + ")");
        }
  
        Node n = findNodeCheck(tx, fqn);
        Map rawData = n.getNodeSPI().getRawData();
        notifier.notifyNodeModified(fqn, true, rawData);
  
        getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  
        // create a compensating method call (reverting the effect of
        // this modification) and put it into the TX's undo list.
        if (tx != null && create_undo_ops)
        {
           // erase and set to previous hashmap contents
           MethodCall undo_op = MethodCallFactory.create(MethodDeclarations.putDataEraseMethodLocal, tx, fqn,
                   new MapCopy(rawData),
                   false, true);
           tx_table.addUndoOperation(tx, undo_op);
        }
  
        if (erase_contents) n.clearData();
        n.put(data);
  
        notifier.notifyNodeModified(fqn, false, rawData);
  
     }
  
     /**
      * Internal put method.
      *
      * @return Previous value (if any)
      */
     public Object _put(GlobalTransaction tx, String fqn, Object key, Object value, boolean create_undo_ops)
             throws CacheException
     {
        return _put(tx, Fqn.fromString(fqn), key, value, create_undo_ops);
     }
  
  
     /**
      * Internal put method.
      *
      * @return Previous value (if any)
      */
     public Object _put(GlobalTransaction tx, Fqn fqn, Object key, Object value, boolean create_undo_ops)
             throws CacheException
     {
        if (log.isTraceEnabled())
        {
           log.trace(new StringBuffer("_put(").append(tx).append(", \"").
                   append(fqn).append("\", k=").append(key).append(", v=").append(value).append(")"));
        }
        // TODO remove before release
        if (key instanceof Map)
        {
           log.warn("using a map as a key in a map, did you mean to do that?");
        }
  
        Node n = findNodeCheck(tx, fqn);
        Map rawData = n.getNodeSPI().getRawData();
        notifier.notifyNodeModified(fqn, true, rawData);
  
        getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
        Object old_value = n.put(key, value);
  
        // create a compensating method call (reverting the effect of
        // this modification) and put it into the TX's undo list.
        if (tx != null && create_undo_ops)
        {
           MethodCall undo_op;
           if (old_value == null)
           {
              undo_op = MethodCallFactory.create(MethodDeclarations.removeKeyMethodLocal, tx, fqn, key, false);
           }
           else
           {
              undo_op = MethodCallFactory.create(MethodDeclarations.putKeyValMethodLocal, tx, fqn, key, old_value, false);
           }
           // 1. put undo-op in TX' undo-operations list (needed to rollback TX)
           tx_table.addUndoOperation(tx, undo_op);
        }
  
        notifier.notifyNodeModified(fqn, false, rawData);
        return old_value;
     }
  
     /**
      * Internal remove method.
      */
     public void _remove(GlobalTransaction tx, String fqn, boolean create_undo_ops) throws CacheException
     {
        _remove(tx, Fqn.fromString(fqn), create_undo_ops);
     }
  
     /**
      * Internal remove method.
      */
     public void _remove(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops) throws CacheException
     {
        _remove(tx, fqn, create_undo_ops, true);
     }
  
     public void _remove(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent)
             throws CacheException
     {
        _remove(tx, fqn, create_undo_ops, sendNodeEvent, false);
     }
  
     /**
      * Internal method to remove a node.
      *
      * @param tx
      * @param fqn
      * @param create_undo_ops
      * @param sendNodeEvent
      */
     public void _remove(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent, boolean eviction)
             throws CacheException
     {
        _remove(tx, fqn, create_undo_ops, sendNodeEvent, eviction, null);
     }
  
     /**
      * Internal method to remove a node.
      * Performs a remove on a node, passing in a {@link DataVersion} which is used with optimistically locked nodes.  Pass
      * in a null if optimistic locking is not used.
      *
      * @param tx
      * @param fqn
      * @param create_undo_ops
      * @param sendNodeEvent
      * @param eviction
      * @param version
      * @throws CacheException
      */
     public void _remove(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent, boolean eviction, DataVersion version)
             throws CacheException
     {
  
        NodeSPI n;
        Node parent_node;
        MethodCall undo_op = null;
  
        if (log.isTraceEnabled())
        {
           log.trace("_remove(" + tx + ", \"" + fqn + "\", undo=" + create_undo_ops + ")");
        }
  
        // check if this is triggered by a rollback operation ...
        if (tx != null)
        {
           try
           {
              int status = getTransactionManager().getTransaction().getStatus();
              if (status == Status.STATUS_MARKED_ROLLBACK || status == Status.STATUS_ROLLEDBACK || status == Status.STATUS_ROLLING_BACK)
              {
                 log.debug("This remove call is triggered by a transaction rollback, as a compensation operation.  Do a realRemove() instead.");
                 realRemove(fqn, true);
                 return;
              }
           }
           catch (Exception e)
           {
              // what do we do here?
              log.trace("Caught exception dealing with transaction manager", e);
           }
        }
  
        if (fqn.size() == 0)
        {
           Set children = getChildrenNames(fqn);
           if (children != null)
           {
              Object[] kids = children.toArray();
  
              for (int i = 0; i < kids.length; i++)
              {
                 Object s = kids[i];
                 Fqn tmp = new Fqn(fqn, s);
                 try
                 {
                    _remove(tx, tmp, create_undo_ops, true, eviction);
                 }
                 catch (Exception e)
                 {
                    log.error("failure removing node " + tmp);
                 }
              }
           }
           return;
        }
  
        // Find the node. This will add the temporarily created parent nodes to the TX's node list if tx != null)
        n = findNode(fqn, version);
        if (n == null)
        {
           if (log.isTraceEnabled())
           {
              log.trace("node " + fqn + " not found");
           }
           return;
        }
  
        if (eviction)
        {
           notifier.notifyNodeEvicted(fqn, true);
        }
        else
        {
           notifier.notifyNodeRemoved(fqn, true, n.getNodeSPI().getRawData());
        }
  
        parent_node = n.getParent();
  
        // remove subtree from parent
        if (eviction || configuration.isNodeLockingOptimistic())
        {
           parent_node.getNodeSPI().getChildrenMap().remove(n.getFqn().getLast());
        }
        else
        {
           n.markAsDeleted(true);
        }
  
        if (eviction)
        {
           parent_node.getNodeSPI().setChildrenLoaded(false);
        }
  
        // release all locks for the entire subtree
        // n.getNodeSPI().getLock().releaseAll(tx != null ? tx : (Object) Thread.currentThread());
  
        // create a compensating method call (reverting the effect of
        // this modification) and put it into the TX's undo list.
        if (tx != null && create_undo_ops && !eviction)
        {
           undo_op = MethodCallFactory.create(MethodDeclarations.addChildMethodLocal, tx, parent_node.getFqn(), n.getFqn().getLast(), n, false);
  
           // 1. put undo-op in TX' undo-operations list (needed to rollback TX)
           tx_table.addUndoOperation(tx, undo_op);
        }
  
        if (eviction)
        {
           notifier.notifyNodeEvicted(fqn, false);
        }
        else
        {
           notifier.notifyNodeRemoved(fqn, false, null);
        }
     }
  
     /**
      * Internal method to remove a key.
      *
      * @param fqn
      * @param key
      * @return Object
      */
     public Object _remove(GlobalTransaction tx, String fqn, Object key, boolean create_undo_ops)
             throws CacheException
     {
        return _remove(tx, Fqn.fromString(fqn), key, create_undo_ops);
     }
  
     /**
      * Internal method to remove a key.
      *
      * @param fqn
      * @param key
      * @return Object
      */
     public Object _remove(GlobalTransaction tx, Fqn fqn, Object key, boolean create_undo_ops)
             throws CacheException
     {
        Node n = null;
        MethodCall undo_op = null;
        Object old_value = null;
  
        if (log.isTraceEnabled())
        {
           log.trace("_remove(" + tx + ", \"" + fqn + "\", key=" + key + ")");
        }
  
        // Find the node. This will lock it (if <tt>locking</tt> is true) and
        // add the temporarily created parent nodes to the TX's node list if tx != null)
        n = findNode(fqn);
        if (n == null)
        {
           log.warn("node " + fqn + " not found");
           return null;
        }
  
        notifier.notifyNodeModified(fqn, true, n.getNodeSPI().getRawData());
  
        getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
        old_value = n.remove(key);
  
        // create a compensating method call (reverting the effect of
        // this modification) and put it into the TX's undo list.
        if (tx != null && create_undo_ops && old_value != null)
        {
           undo_op = MethodCallFactory.create(MethodDeclarations.putKeyValMethodLocal, tx, fqn, key, old_value, false);
           // 1. put undo-op in TX' undo-operations list (needed to rollback TX)
           tx_table.addUndoOperation(tx, undo_op);
        }
  
        notifier.notifyNodeModified(fqn, false, n.getNodeSPI().getRawData());
  
        return old_value;
     }
  
     /**
      * Internal method to remove data from a node.
      */
     public void _removeData(GlobalTransaction tx, String fqn, boolean create_undo_ops)
             throws CacheException
     {
        _removeData(tx, Fqn.fromString(fqn), create_undo_ops);
     }
  
     /**
      * Internal method to remove data from a node.
      */
     public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops)
             throws CacheException
     {
        _removeData(tx, fqn, create_undo_ops, true);
     }
  
     /**
      * Internal method to remove data from a node.
      */
     public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent)
             throws CacheException
     {
        _removeData(tx, fqn, create_undo_ops, sendNodeEvent, false);
     }
  
     /**
      * Internal method to remove data from a node.
      */
     public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent, boolean eviction)
             throws CacheException
     {
        _removeData(tx, fqn, create_undo_ops, sendNodeEvent, eviction, null);
     }
  
     /**
      * Internal method to remove data from a node.
      */
     public void _removeData(GlobalTransaction tx, Fqn fqn, boolean create_undo_ops, boolean sendNodeEvent, boolean eviction, DataVersion version)
             throws CacheException
     {
        Node n = null;
        MethodCall undo_op = null;
  
        if (log.isTraceEnabled())
        {
           log.trace("_removeData(" + tx + ", \"" + fqn + "\")");
        }
  
        // Find the node. This will lock it (if <tt>locking</tt> is true) and
        // add the temporarily created parent nodes to the TX's node list if tx != null)
        n = findNode(fqn, version);
        if (n == null)
        {
           log.warn("node " + fqn + " not found");
           return;
        }
  
        // create a compensating method call (reverting the effect of
        // this modification) and put it into the TX's undo list.
        if (tx != null && create_undo_ops && !eviction)
        {
           Map data = n.getData();
           if (!data.isEmpty())
           {
              undo_op = MethodCallFactory.create(MethodDeclarations.putDataMethodLocal,
                      tx, fqn, new MapCopy(data), false);
           }
        }
  
        if (eviction)
        {
           notifier.notifyNodeEvicted(fqn, true);
        }
        else
        {
           notifier.notifyNodeModified(fqn, true, n.getNodeSPI().getRawData());
        }
  
        Map raw = n.getNodeSPI().getRawData();
        raw.clear();
        if (eviction)
        {
           n.getNodeSPI().setDataLoaded(false);
        }
  
        if (sendNodeEvent)
        {
           notifier.notifyNodeVisited(fqn, false);
        }
        else
        {// FIXME Bela did this so GUI view can refresh the view after node is evicted. But this breaks eviction policy, especially AOP!!!!
           if (eviction)
           {
              notifier.notifyNodeEvicted(fqn, false);
           }
           else
           {
              notifier.notifyNodeModified(fqn, false, n.getData());
           }
        }
  
        // put undo-op in TX' undo-operations list (needed to rollback TX)
        if (tx != null && create_undo_ops)
        {
           tx_table.addUndoOperation(tx, undo_op);
        }
     }
  
  
     /**
      * Internal evict method called by eviction policy provider.
      *
      * @param fqn removes everything assoicated with this FQN
      * @throws CacheException
      */
     public void _evict(Fqn fqn) throws CacheException
     {
        if (!exists(fqn)) return;// node does not exist. Maybe it has been recursively removed.
        // use remove method now if there is a child node. Otherwise, it is removed
        boolean create_undo_ops = false;
        boolean sendNodeEvent = false;
        boolean eviction = true;
        if (log.isTraceEnabled())
        {
           log.trace("_evict(" + fqn + ")");
        }
        if (hasChild(fqn))
        {
           _removeData(null, fqn, create_undo_ops, sendNodeEvent, eviction);
        }
        else
        {
           _remove(null, fqn, create_undo_ops, sendNodeEvent, eviction);
        }
     }
  
     /**
      * Internal evict method called by eviction policy provider.
      *
      * @param fqn
      * @param version
      * @throws CacheException
      */
     public void _evict(Fqn fqn, DataVersion version) throws CacheException
     {
        if (!exists(fqn)) return;// node does not exist
  
        boolean create_undo_ops = false;
        boolean sendNodeEvent = false;
        boolean eviction = true;
        if (log.isTraceEnabled())
        {
           log.trace("_evict(" + fqn + ", " + version + ")");
        }
        if (hasChild(fqn))
        {
           _removeData(null, fqn, create_undo_ops, sendNodeEvent, eviction, version);
        }
        else
        {
           _remove(null, fqn, create_undo_ops, sendNodeEvent, eviction, version);
        }
     }
  
     /**
      * Evicts a key/value pair from a node's attributes. Note that this is <em>local</em>, will not be replicated.
      * @param fqn
      * @param key
      * @throws CacheException
      */
     //    public void _evict(Fqn fqn, Object key) throws CacheException {
     //       if(!exists(fqn)) return;
     //       boolean create_undo_ops = false;
     //       boolean sendNodeEvent = false;
     //       boolean eviction=true;
     //       _removeData(null, fqn, create_undo_ops, sendNodeEvent, eviction);
     //    }
  
  
     /**
      * Compensating method to {@link #_remove(GlobalTransaction,Fqn,boolean)}.
      */
     public void _addChild(GlobalTransaction gtx, Fqn parent_fqn, Object child_name, Node cn, boolean undoOps)
             throws CacheException
     {
        NodeSPI childNode = (NodeSPI) cn;
        if (log.isTraceEnabled())
        {
           log.trace("_addChild(\"" + parent_fqn + "\", \"" + child_name + "\", node=" + childNode + ")");
        }
  
        if (parent_fqn == null || child_name == null || childNode == null)
        {
           log.error("parent_fqn or child_name or childNode was null");
           return;
        }
        NodeSPI parentNode = findNode(parent_fqn);
        if (parentNode == null)
        {
           log.warn("node " + parent_fqn + " not found");
           return;
        }
  
        Fqn fqn = new Fqn(parent_fqn, child_name);
        notifier.notifyNodeCreated(fqn, true);
        parentNode.addChild(child_name, childNode);
  
        childNode.markAsDeleted(false, true);
  
        if (gtx != null && undoOps)
        {
           // 1. put undo-op in TX' undo-operations list (needed to rollback TX)
           tx_table.addUndoOperation(gtx, MethodCallFactory.create(MethodDeclarations.removeNodeMethodLocal, gtx, fqn, false));
        }
  
        notifier.notifyNodeCreated(fqn, false);
     }
  
  
     /**
      * Replicates changes across to other nodes in the cluster.  Invoked by the
      * ReplicationInterceptor.  Calls need to be forwarded to the
      * ReplicationInterceptor in this interceptor chain. This method will later
      * be moved entirely into the ReplicationInterceptor.
      */
     public Object _replicate(MethodCall method_call) throws Throwable
     {
        try
        {
           InvocationContext ctx = getInvocationContext();
           ctx.setOriginLocal(false);
           setInvocationContext(ctx);
           return invokeMethod(method_call);
        }
        catch (Exception ex)
        {
           log.warn("replication failure with method_call " + method_call + " exception: " + ex);
           throw ex;
        }
        finally
        {
           InvocationContext ctx = getInvocationContext();
           ctx.setOriginLocal(true);
           setInvocationContext(ctx);
        }
     }
  
     /**
      * Replicates a list of method calls.
      */
     public void _replicate(List method_calls) throws Throwable
     {
        Iterator it = method_calls.iterator();
        while (it.hasNext()) _replicate((MethodCall) it.next());
     }
  
     /**
      * A 'clustered get' call, called from a remote ClusteredCacheLoader.
      *
      * @return a List containing 2 elements: (true or false) and a value (Object).  If buddy replication
      *         is used one further element is added - an Fqn of the backup subtree in which this node may be found.
      */
     public List _clusteredGet(MethodCall methodCall, Boolean searchBackupSubtrees)
     {
        MethodCall call = methodCall;
        if (log.isTraceEnabled()) log.trace("Clustered Get called with params: " + call + ", " + searchBackupSubtrees);
        Method m = call.getMethod();
        Object[] args = call.getArgs();
  
        Object callResults = null;
  
        try
        {
           Fqn fqn = (Fqn) args[0];
  
           if (log.isTraceEnabled()) log.trace("Clustered get: invoking call " + m + " with Fqn " + fqn);
           callResults = m.invoke(this, args);
           boolean found = validResult(callResults, call, fqn);
           if (log.isTraceEnabled()) log.trace("Got result " + callResults + ", found=" + found);
           if (found && callResults == null) callResults = createEmptyResults(call);
        }
        catch (Exception e)
        {
           log.warn("Problems processing clusteredGet call", e);
        }
  
        List results = new ArrayList(2);
        if (callResults != null)
        {
           results.add(true);
           results.add(callResults);
        }
        else
        {
           results.add(false);
           results.add(null);
        }
        return results;
     }
  
     /**
      * Used with buddy replication's data gravitation interceptor
      *
      * @param fqn            the fqn to gravitate
      * @param searchSubtrees should _BUDDY_BACKUP_ subtrees be searched
      * @param marshal        should the list of NodeData being gravitated be marshalled into
      *                       a byte[] or returned as a List
      * @return <code>List</code> with 1 or 3 elements. First element is a
      *         <code>Boolean</code> indicating whether data was found.  If
      *         <code>false</code>, the list will only have one element.
      *         Otherwise, second element is the data itself, structured as
      *         a <code>List</code> of <code>NodeData</code> objects, each of
      *         which represents one <code>Node</code> in the subtree rooted
      *         at <code>fqn</code>. If param <code>mnarshal</code> is
      *         <code>true</code>, this second element will have been marshalled
      *         to a <code>byte[]</code>, otherwise it will be the raw list.
      *         The third element represents the Fqn in the _BUDDY_BACKUP_
      *         region that needs to be cleaned in order to remove this data
      *         once the new owner has acquired it.
      */
     public List _gravitateData(Fqn fqn, boolean searchSubtrees, boolean marshal)
             throws CacheException
     {
        GravitateResult result = gravitateData(fqn, searchSubtrees, marshal);
        return result.asList();
     }
  
     public GravitateResult gravitateData(Fqn fqn, boolean searchSubtrees, boolean marshal)
             throws CacheException
     {
        // we need to get the state for this Fqn and its sub-nodes.
  
        // for now, perform a very simple series of getData calls.
  
        Node actualNode = findNode(fqn);
        Fqn backupNodeFqn = null;
        if (actualNode == null && searchSubtrees)
        {
           Node backupSubtree = findNode(BuddyManager.BUDDY_BACKUP_SUBTREE_FQN);
           if (backupSubtree != null)
           {
              Map children = backupSubtree.getNodeSPI().getChildrenMap();
              if (children != null)
              {
                 Iterator childNames = children.keySet().iterator();
                 while (childNames.hasNext() && actualNode == null)
                 {
                    backupNodeFqn = BuddyManager.getBackupFqn(childNames.next().toString(), fqn);
                    actualNode = findNode(backupNodeFqn);
                 }
              }
           }
        }
  
        if (actualNode == null)
        {
           return GravitateResult.noDataFound();
        }
  
        if (backupNodeFqn == null)
        {
           backupNodeFqn = BuddyManager.getBackupFqn(BuddyManager.getGroupNameFromAddress(getLocalAddress()), fqn);
        }
  
        List list = getNodeData(new LinkedList(), actualNode);
        if (marshal)
        {
           try
           {
              ByteArrayOutputStream baos = new ByteArrayOutputStream(1024);
              MarshalledValueOutputStream maos = new MarshalledValueOutputStream(baos);
              maos.writeObject(list);
              maos.close();
              return GravitateResult.marshalledResult(baos.toByteArray(), backupNodeFqn);
           }
           catch (IOException e)
           {
              throw new CacheException("Failure marshalling subtree at " + fqn, e);
           }
        }
        else
        {
           GravitateResult gr = GravitateResult.subtreeResult(list, backupNodeFqn);
           return gr;
        }
     }
  
     private List getNodeData(List list, Node node)
     {
        NodeData data = new NodeData(BuddyManager.getActualFqn(node.getFqn()), node.getData());
        list.add(data);
        Map<Object, Node> children = node.getNodeSPI().getChildrenMap();
        for (Node childNode : children.values())
        {
           getNodeData(list, childNode);
        }
        return list;
     }
  
     // ------------- start: buddy replication specific 'lifecycle' method calls
  
     public void _remoteAssignToBuddyGroup(BuddyGroup group, Map state) throws Exception
     {
        if (buddyManager != null) buddyManager.handleAssignToBuddyGroup(group, state);
     }
  
     public void _remoteRemoveFromBuddyGroup(String groupName) throws BuddyNotInitException
     {
        if (buddyManager != null) buddyManager.handleRemoveFromBuddyGroup(groupName);
     }
  
     public void _remoteAnnounceBuddyPoolName(IpAddress address, String buddyPoolName)
     {
        if (buddyManager != null) buddyManager.handlePoolNameBroadcast(address, buddyPoolName);
     }
  
     public void _dataGravitationCleanup(GlobalTransaction gtx, Fqn primary, Fqn backup) throws Exception
     {
        MethodCall primaryDataCleanup, backupDataCleanup;
        if (buddyManager.isDataGravitationRemoveOnFind())
        {
           primaryDataCleanup = MethodCallFactory.create(MethodDeclarations.removeNodeMethodLocal, null, primary, false);
           backupDataCleanup = MethodCallFactory.create(MethodDeclarations.removeNodeMethodLocal, null, backup, false);
        }
        else
        {
           primaryDataCleanup = MethodCallFactory.create(MethodDeclarations.evictNodeMethodLocal, primary);
           backupDataCleanup = MethodCallFactory.create(MethodDeclarations.evictNodeMethodLocal, backup);
        }
  
        invokeMethod(primaryDataCleanup);
        invokeMethod(backupDataCleanup);
     }
  
     // ------------- end: buddy replication specific 'lifecycle' method calls
  
  
     /**
      * Returns true if the call results returned a valid result.
      */
     private boolean validResult(Object callResults, MethodCall mc, Fqn fqn)
     {
        switch (mc.getMethodId())
        {
           case MethodDeclarations.getDataMapMethodLocal_id:
           case MethodDeclarations.getChildrenNamesMethodLocal_id:
              return callResults != null || exists(fqn);
           case MethodDeclarations.existsMethod_id:
              return (Boolean) callResults;
           default:
              return false;
        }
     }
  
     /**
      * Creates an empty Collection class based on the return type of the method called.
      */
     private Object createEmptyResults(MethodCall mc)
     {
        switch (mc.getMethodId())
        {
           case MethodDeclarations.getDataMapMethodLocal_id:
           case MethodDeclarations.getChildrenNamesMethodLocal_id:
              return Collections.emptyMap();
           default:
              return null;
        }
     }
  
     /**
      * Releases all locks for a FQN.
      */
     public void _releaseAllLocks(Fqn fqn)
     {
        Node n;
  
        try
        {
           n = findNode(fqn);
           if (n == null)
           {
              log.error("releaseAllLocks(): node " + fqn + " not found");
              return;
           }
           releaseAll(n);
        }
        catch (Throwable t)
        {
           log.error("releaseAllLocks(): failed", t);
        }
     }
  
     private void releaseAll(Node n)
     {
        for (Node child : n.getChildren())
        {
           releaseAll(child);
        }
        n.getNodeSPI().getLock().releaseAll();
     }
  
  
     /**
      * Finds and returns the string value for the Fqn.
      * Returns null if not found or upon error.
      */
     public String _print(Fqn fqn)
     {
        try
        {
           Node n = findNode(fqn);
           if (n == null) return null;
           return n.toString();
        }
        catch (Throwable t)
        {
           return null;
        }
     }
  
     /**
      * Should not be called.
      */
     public void _lock(Fqn fqn, NodeLock.LockType lock_type, boolean recursive)
             throws TimeoutException, LockingException
     {
        log.warn("method _lock() should not be invoked on CacheImpl");
     }
  
     // todo: these methods can be removed once we move 2PC entirely into {Replication/Lock}Interceptor
  
     /**
      * Throws UnsupportedOperationException.
      */
     public void optimisticPrepare(GlobalTransaction gtx, List modifications, Map data, Address address, boolean onePhaseCommit)
     {
        throw new UnsupportedOperationException("optimisticPrepare() should not be called on CacheImpl directly");
     }
  
     /**
      * Throws UnsupportedOperationException.
      */
     public void prepare(GlobalTransaction global_tx, List modifications, Address coord, boolean onePhaseCommit)
     {
        throw new UnsupportedOperationException("prepare() should not be called on CacheImpl directly");
     }
  
     /**
      * Throws UnsupportedOperationException.
      */
     public void commit(GlobalTransaction tx)//, Boolean hasMods)
     {
        throw new UnsupportedOperationException("commit() should not be called on CacheImpl directly");
     }
  
     /**
      * Throws UnsupportedOperationException.
      */
     public void rollback(GlobalTransaction tx)//, Boolean hasMods)
     {
        throw new UnsupportedOperationException("rollback() should not be called on CacheImpl directly");
     }
  
     /* ----------------- End of  Callbacks ---------------------- */
  
     /**
      * Adds an undo operatoin to the transaction table.
      */
     public void addUndoOperation(GlobalTransaction gtx, MethodCall undo_op)
     {
        tx_table.addUndoOperation(gtx, undo_op);
     }
  
     /**
      * Returns the CacheLoaderManager.
      */
     public CacheLoaderManager getCacheLoaderManager()
     {
        return cacheLoaderManager;
     }
  
     /**
      * Sets the CacheLoaderManager.
      */
     public void setCacheLoaderManager(CacheLoaderManager cacheLoaderManager)
     {
        this.cacheLoaderManager = cacheLoaderManager;
     }
  
     public void setConfiguration(Configuration configuration)
     {
        this.configuration = configuration;
        configuration.setTreeCache(this);
     }
  
     /**
      * @return an instance of {@link Notifier} which has been configured with this instance of CacheImpl.
      */
     public Notifier getNotifier()
     {
        return notifier;
     }
  
     public InvocationContext getInvocationContext()
     {
        InvocationContext ctx = invocationContextContainer.get();
        if (ctx == null)
        {
           ctx = new InvocationContext();
           invocationContextContainer.set(ctx);
        }
        return ctx;
     }
  
     public void setInvocationContext(InvocationContext ctx)
     {
        invocationContextContainer.set(ctx);
     }
  
     public CacheMBean getCacheMBeanInterface()
     {
        if (cacheMBean == null)
        {
           cacheMBean = new org.jboss.cache.jmx.Cache(this);
        }
        return cacheMBean;
     }
  
     public void setCacheMBeanInterface(CacheMBean mbean)
     {
        this.cacheMBean = mbean;
     }
  
     /**
      * New API to efficiently relocate a node
      *
      * @since 2.0.0
      */
     public void move(Fqn newParent, Fqn nodeToMove)
     {
        // this needs to be passed up the interceptor chain
        MethodCall m = MethodCallFactory.create(MethodDeclarations.moveMethodLocal, newParent, nodeToMove);
        invokeMethod(m);
     }
  
     /**
      * Called by reflection
      *
      * @param newParentFqn
      * @param nodeToMoveFqn
      */
     public void _move(Fqn newParentFqn, Fqn nodeToMoveFqn)
     {
        // the actual move algorithm.
        NodeSPI newParent = findNode(newParentFqn);
  
        if (newParent == null)
        {
           throw new NodeNotExistsException("New parent node " + newParentFqn + " does not exist when attempting to move node!!");
        }
  
        Node node = findNode(nodeToMoveFqn);
  
        if (node == null)
        {
           throw new NodeNotExistsException("Node " + nodeToMoveFqn + " does not exist when attempting to move node!!");
        }
  
        NodeSPI oldParent = (NodeSPI) node.getParent();
        Object nodeName = nodeToMoveFqn.getLast();
  
        // now that we have the parent and target nodes:
        // first correct the pointers at the pruning point
        oldParent.removeChild(new Fqn(nodeName));
        newParent.addChild(nodeName, node);
  
        // parent pointer is calculated on the fly using Fqns.
  
        // now adjust Fqns of node and all children.
        moveFqns(node, newParent.getFqn());
  
        // now register an undo op
        if (getInvocationContext().getTransaction() != null)
        {
           MethodCall undo = MethodCallFactory.create(MethodDeclarations.moveMethodLocal, oldParent.getFqn(), new Fqn(newParentFqn, nodeToMoveFqn.getLast()));
           tx_table.addUndoOperation(getInvocationContext().getGlobalTransaction(), undo);
        }
     }
  
     public void _block()
     {
        //intentionally empty, used only for reflection in MethodDeclarations.blockChannelLocal
     }
  
     public void _unblock()
     {
        //intentionally empty, used only for reflection in MethodDeclarations.unblockChannelLocal
     }
  
     private void moveFqns(Node node, Fqn newBase)
     {
        Fqn newFqn = new Fqn(newBase, node.getFqn().getLast());
        node.getNodeSPI().setFqn(newFqn);
     }
  
     protected class MessageListenerAdaptor implements ExtendedMessageListener
     {
        /**
         * Reference to an exception that was raised during
         * state installation on this node.
         */
        protected volatile Exception setStateException;
        private final Object stateLock = new Object();
  
        protected MessageListenerAdaptor()
        {
        }
  
        public void waitForState() throws Exception
        {
           synchronized (stateLock)
           {
              while (!isStateSet)
              {
                 if (setStateException != null)
                 {
                    throw setStateException;
                 }
  
                 try
                 {
                    stateLock.wait();
                 }
                 catch (InterruptedException iex)
                 {
                 }
              }
           }
        }
  
        protected void stateReceivedSuccess()
        {
           isStateSet = true;
           setStateException = null;
        }
  
        protected void stateReceivingFailed(Throwable t)
        {
           if (t instanceof CacheException)
           {
              log.debug(t);
           }
           else
           {
              log.error("failed setting state", t);
           }
           if (t instanceof Exception)
           {
              setStateException = (Exception) t;
           }
           else
           {
              setStateException = new Exception(t);
           }
        }
  
        protected void stateProducingFailed(Throwable t)
        {
           if (t instanceof CacheException)
           {
              log.debug(t);
           }
           else
           {
              log.error("Caught " + t.getClass().getName()
                      + " while responding to state transfer request", t);
           }
        }
  
        /**
         * Callback, does nothing.
         */
        public void receive(Message msg)
        {
        }
  
        public byte[] getState()
        {
           MarshalledValueOutputStream out = null;
           byte[] result = null;
           try
           {
              ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
              out = new MarshalledValueOutputStream(baos);
  
              getStateTransferManager().getState(out, Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
              result = baos.getRawBuffer();
           }
           catch (Throwable t)
           {
              stateProducingFailed(t);
           }
           finally
           {
              Util.close(out);
           }
           return result;
        }
  
        public void setState(byte[] new_state)
        {
           if (new_state == null)
           {
              log.debug("transferred state is null (may be first member in cluster)");
              return;
           }
           ByteArrayInputStream bais = new ByteArrayInputStream(new_state);
           MarshalledValueInputStream in = null;
           try
           {
              in = new MarshalledValueInputStream(bais);
              getStateTransferManager().setState(in, Fqn.ROOT, null);
              stateReceivedSuccess();
           }
           catch (Throwable t)
           {
              stateReceivingFailed(t);
           }
           finally
           {
              Util.close(in);
              synchronized (stateLock)
              {
                 // Notify wait that state has been set.
                 stateLock.notifyAll();
              }
           }
        }
  
        public byte[] getState(String state_id)
        {
           MarshalledValueOutputStream out = null;
           String sourceRoot = state_id;
           byte[] result = null;
  
           boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
           if (hasDifferentSourceAndIntegrationRoots)
           {
              sourceRoot = state_id.split(StateTransferManager.PARTIAL_STATE_DELIMETER)[0];
           }
  
           try
           {
              ExposedByteArrayOutputStream baos = new ExposedByteArrayOutputStream(16 * 1024);
              out = new MarshalledValueOutputStream(baos);
  
              getStateTransferManager().getState(out, Fqn.fromString(sourceRoot),
                      configuration.getInitialStateRetrievalTimeout(), true, true);
              result = baos.getRawBuffer();
           }
           catch (Throwable t)
           {
              stateProducingFailed(t);
           }
           finally
           {
              Util.close(out);
           }
           return result;
        }
  
        public void getState(OutputStream ostream)
        {
           MarshalledValueOutputStream out = null;
           try
           {
              out = new MarshalledValueOutputStream(ostream);
              getStateTransferManager().getState(out, Fqn.ROOT, configuration.getInitialStateRetrievalTimeout(), true, true);
           }
           catch (Throwable t)
           {
              stateProducingFailed(t);
           }
           finally
           {
              Util.close(out);
           }
        }
  
        public void getState(String state_id, OutputStream ostream)
        {
           String sourceRoot = state_id;
           MarshalledValueOutputStream out = null;
           boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
           if (hasDifferentSourceAndIntegrationRoots)
           {
              sourceRoot = state_id.split(StateTransferManager.PARTIAL_STATE_DELIMETER)[0];
           }
           try
           {
              out = new MarshalledValueOutputStream(ostream);
              getStateTransferManager().getState(out, Fqn.fromString(sourceRoot), configuration.getInitialStateRetrievalTimeout(), true, true);
           }
           catch (Throwable t)
           {
              stateProducingFailed(t);
           }
           finally
           {
              Util.close(out);
           }
        }
  
        public void setState(InputStream istream)
        {
           if (istream == null)
           {
              log.debug("stream is null (may be first member in cluster)");
              return;
           }
           MarshalledValueInputStream in = null;
           try
           {
              in = new MarshalledValueInputStream(istream);
              getStateTransferManager().setState(in, Fqn.ROOT, null);
              stateReceivedSuccess();
           }
           catch (Throwable t)
           {
              stateReceivingFailed(t);
           }
           finally
           {
              Util.close(in);
              synchronized (stateLock)
              {
                 // Notify wait that state has been set.
                 stateLock.notifyAll();
              }
           }
        }
  
        public void setState(String state_id, byte[] state)
        {
           if (state == null)
           {
              log.debug("partial transferred state is null");
              return;
           }
  
           MarshalledValueInputStream in = null;
           String targetRoot = state_id;
           boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
           if (hasDifferentSourceAndIntegrationRoots)
           {
              targetRoot = state_id.split(StateTransferManager.PARTIAL_STATE_DELIMETER)[1];
           }
           try
           {
              log.debug("Setting received partial state for subroot " + state_id);
              Fqn subroot = Fqn.fromString(targetRoot);
              Region region = regionManager.getRegion(subroot, false);
              ClassLoader cl = null;
              if (region != null)
              {
                 // If a classloader is registered for the node's region, use it
                 cl = region.getClassLoader();
              }
              ByteArrayInputStream bais = new ByteArrayInputStream(state);
              in = new MarshalledValueInputStream(bais);
              getStateTransferManager().setState(in, subroot, cl);
              stateReceivedSuccess();
           }
           catch (Throwable t)
           {
              stateReceivingFailed(t);
           }
           finally
           {
              Util.close(in);
              synchronized (stateLock)
              {
                 // Notify wait that state has been set.
                 stateLock.notifyAll();
              }
           }
        }
  
        public void setState(String state_id, InputStream istream)
        {
           String targetRoot = state_id;
           MarshalledValueInputStream in = null;
           boolean hasDifferentSourceAndIntegrationRoots = state_id.indexOf(StateTransferManager.PARTIAL_STATE_DELIMETER) > 0;
           if (hasDifferentSourceAndIntegrationRoots)
           {
              targetRoot = state_id.split(StateTransferManager.PARTIAL_STATE_DELIMETER)[1];
           }
           if (istream == null)
           {
              log.debug("stream is null (may be first member in cluster). State is not set");
              return;
           }
  
           try
           {
              log.debug("Setting received partial state for subroot " + state_id);
              in = new MarshalledValueInputStream(istream);
              Fqn subroot = Fqn.fromString(targetRoot);
              Region region = regionManager.getRegion(subroot, false);
              ClassLoader cl = null;
              if (region != null)
              {
                 // If a classloader is registered for the node's region, use it
                 cl = region.getClassLoader();
              }
              getStateTransferManager().setState(in, subroot, cl);
              stateReceivedSuccess();
           }
           catch (Throwable t)
           {
              stateReceivingFailed(t);
           }
           finally
           {
              Util.close(in);
              synchronized (stateLock)
              {
                 // Notify wait that state has been set.
                 stateLock.notifyAll();
              }
           }
        }
     }
  
     /*-------------------- End of MessageListener ----------------------*/
  
     /*----------------------- MembershipListener ------------------------*/
  
     public void viewAccepted(View new_view)
     {
        Vector new_mbrs = new_view.getMembers();
  
        // todo: if MergeView, fetch and reconcile state from coordinator
        // actually maybe this is best left up to the application ? we just notify them and let
        // the appl handle it ?
  
        log.info("viewAccepted(): " + new_view);
        synchronized (members)
        {
           boolean needNotification = false;
           if (new_mbrs != null)
           {
              // Determine what members have been removed
              // and roll back any tx and break any locks
              Vector removed = (Vector) members.clone();
              removed.removeAll(new_mbrs);
              removeLocksForDeadMembers(root, removed);
  
              members.removeAllElements();
              members.addAll(new_view.getMembers());
  
              needNotification = true;
           }
  
           // Now that we have a view, figure out if we are the coordinator
           coordinator = (members.size() == 0 ? false : members.get(0).equals(getLocalAddress()));
  
           // now notify listeners - *after* updating the coordinator. - JBCACHE-662
           if (needNotification) notifier.notifyViewChange(new_view);
  
           // Wake up any threads that are waiting to know who the members
           // are so they can figure out who the coordinator is
           members.notifyAll();
        }
     }
  
  
     /**
      * Called when a member is suspected.
      */
     public void suspect(Address suspected_mbr)
     {
     }
  
     /**
      * Indicates that a channel has received a BLOCK event from FLUSH protocol.
      */
     public void block()
     {
        if (log.isDebugEnabled())
        {
           log.debug("Block received at " + getLocalAddress());
        }
        MethodCall m = MethodCallFactory.create(MethodDeclarations.blockChannelLocal);
        invokeMethod(m);
        if (log.isDebugEnabled())
        {
           log.debug("Block processed at " + getLocalAddress());
        }
     }
  
     /**
      * Indicates that a channel has received a UNBLOCK event from FLUSH protocol.
      */
     public void unblock()
     {
        if (log.isDebugEnabled())
        {
           log.debug("UnBlock received at " + getLocalAddress());
        }
        MethodCall m = MethodCallFactory.create(MethodDeclarations.unblockChannelLocal);
        invokeMethod(m);
        if (log.isDebugEnabled())
        {
           log.debug("UnBlock processed at " + getLocalAddress());
        }
     }
  
     /*------------------- End of MembershipListener ----------------------*/
  
     /* ------------------------------ Private methods --------------------------- */
  
     /**
      * Returns the transaction associated with the current thread. We get the
      * initial context and a reference to the TransactionManager to get the
      * transaction. This method is used by {@link #getCurrentTransaction()}
      */
     protected Transaction getLocalTransaction()
     {
        if (tm == null)
        {
           return null;
        }
        try
        {
           return tm.getTransaction();
        }
        catch (Throwable t)
        {
           return null;
        }
     }
  
  
     /**
      * Returns true if transaction is ACTIVE or PREPARING, false otherwise.
      */
     private boolean isValid(Transaction tx)
     {
        if (tx == null) return false;
        int status = -1;
        try
        {
           status = tx.getStatus();
           return status == Status.STATUS_ACTIVE || status == Status.STATUS_PREPARING;
        }
        catch (SystemException e)
        {
           log.error("failed getting transaction status", e);
           return false;
        }
     }
  
  
     /**
      * Returns the transaction associated with the current thread.
      * If a local transaction exists, but doesn't yet have a mapping to a
      * GlobalTransaction, a new GlobalTransaction will be created and mapped to
      * the local transaction.  Note that if a local transaction exists, but is
      * not ACTIVE or PREPARING, null is returned.
      *
      * @return A GlobalTransaction, or null if no (local) transaction was associated with the current thread
      */
     public GlobalTransaction getCurrentTransaction()
     {
        return getCurrentTransaction(true);
     }
  
     /**
      * Returns the transaction associated with the thread; optionally creating
      * it if is does not exist.
      */
     public GlobalTransaction getCurrentTransaction(boolean createIfNotExists)
     {
        Transaction tx;
  
        if ((tx = getLocalTransaction()) == null)
        {// no transaction is associated with the current thread
           return null;
        }
  
        if (!isValid(tx))
        {// we got a non-null transaction, but it is not active anymore
           int status = -1;
           try
           {
              status = tx.getStatus();
           }
           catch (SystemException e)
           {
           }
           log.warn("status is " + status + " (not ACTIVE or PREPARING); returning null)", new Throwable());
           return null;
        }
  
        return getCurrentTransaction(tx, createIfNotExists);
     }
  
     /**
      * Returns the global transaction for this local transaction.
      */
     public GlobalTransaction getCurrentTransaction(Transaction tx)
     {
        return getCurrentTransaction(tx, true);
     }
  
     /**
      * Returns the global transaction for this local transaction.
      *
      * @param createIfNotExists if true, if a global transaction is not found; one is created
      */
     public GlobalTransaction getCurrentTransaction(Transaction tx, boolean createIfNotExists)
     {
        // removed synchronization on tx_table because underlying implementation is thread safe
        // and JTA spec (section 3.4.3 Thread of Control, par 2) says that only one thread may
        // operate on the transaction at one time so no concern about 2 threads trying to call
        // this method for the same Transaction instance at the same time
        //
        GlobalTransaction gtx = tx_table.get(tx);
        if (gtx == null && createIfNotExists)
        {
           Address addr = (Address) getLocalAddress();
           gtx = GlobalTransaction.create(addr);
           tx_table.put(tx, gtx);
           TransactionEntry ent = configuration.isNodeLockingOptimistic() ? new OptimisticTransactionEntry() : new TransactionEntry();
           ent.setTransaction(tx);
           tx_table.put(gtx, ent);
           if (log.isTraceEnabled())
           {
              log.trace("created new GTX: " + gtx + ", local TX=" + tx);
           }
        }
        return gtx;
     }
  
  
     /**
      * Invokes a method against this object. Contains the logger_ic for handling
      * the various use cases, e.g. mode (local, repl_async, repl_sync),
      * transaction (yes or no) and locking (yes or no).
      */
     protected Object invokeMethod(MethodCall m) throws CacheException
     {
        try
        {
           return interceptor_chain.invoke(m);
        }
        catch (Throwable t)
        {
           if (t instanceof CacheException)
           {
              throw (CacheException) t;
           }
           throw new RuntimeException(t);
        }
     }
  
     /**
      * Returns an object suitable for use in node locking, either the current
      * transaction or the current thread if there is no transaction.
      */
     protected Object getOwnerForLock()
     {
        Object owner = getCurrentTransaction();
        if (owner == null)
        {
           owner = Thread.currentThread();
        }
  
        return owner;
     }
  
     /**
      * Finds a node given a fully qualified name.
      * Whenever nodes are created, and the global transaction is not null, the created
      * nodes have to be added to the transaction's {@link TransactionEntry}
      * field.<br>
      * When a lock is acquired on a node, a reference to the lock has to be
      * {@link TransactionEntry#addLock(org.jboss.cache.lock.NodeLock) added to the list of locked nodes}
      * in the {@link TransactionEntry}.
      * <p>This operation will also apply different locking to the cache nodes, depending on
      * <tt>operation_type</tt>. If it is <tt>read</tt> type, all nodes will be acquired with
      * read lock. Otherwise, the operation is <tt>write</tt> type, all parent nodes will be acquired
      * with read lock while the destination node acquires write lock.</p>
      *
      * @param fqn Fully qualified name for the corresponding node.
      * @return DataNode
      */
     public NodeSPI findNode(Fqn fqn)
     {
        try
        {
           return findNode(fqn, null);
        }
        catch (CacheException e)
        {
           log.warn("Unexpected error", e);
           return null;
        }
     }
  
     private NodeSPI findNodeCheck(GlobalTransaction tx, Fqn fqn)
     {
        NodeSPI n = findNode(fqn);
        if (n == null)
        {
           String errStr = "node " + fqn + " not found (gtx=" + tx + ", caller=" + Thread.currentThread() + ")";
           if (log.isTraceEnabled())
           {
              log.trace(errStr);
           }
           throw new NodeNotExistsException(errStr);
        }
        return n;
     }
  
     /**
      * Internal method; not to be used externally.
      *
      * @param f
      */
     public void realRemove(Fqn f, boolean skipMarkerCheck)
     {
        NodeSPI n = findInternal(f, true);
        if (n == null)
        {
           return;
        }
  
        if (log.isDebugEnabled()) log.debug("Performing a real remove for node " + f + ", marked for removal.");
        if (skipMarkerCheck || n.isDeleted())
        {
           if (n.getFqn().isRoot())
           {
              // do not actually delete; just remove deletion marker
              n.markAsDeleted(false);
              // but now remove all children, since the call has been to remove("/")
              n.removeChildren();
           }
           else
           {
              getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
              n.getParent().removeChild(n.getFqn());
           }
        }
        else
        {
           if (log.isDebugEnabled()) log.debug("Node " + f + " NOT marked for removal as expected, not removing!");
        }
     }
  
     /**
      * Finds a node given a fully qualified name and DataVersion.
      */
     private NodeSPI findNode(Fqn fqn, DataVersion version) throws CacheException
     {
        if (fqn == null) return null;
  
        NodeSPI toReturn = findInternal(fqn, false);
  
        if (version != null && configuration.isNodeLockingOptimistic())
        {
           // we need to check the version of the data node...
           DataVersion nodeVersion = toReturn.getVersion();
           if (log.isDebugEnabled())
           {
              log.debug("looking for optimistic node [" + fqn + "] with version [" + version + "].  My version is [" + nodeVersion + "]");
           }
           if (nodeVersion.newerThan(version))
           {
              // we have a versioning problem; throw an exception!
              throw new CacheException("Unable to validate versions.");
           }
        }
        return toReturn;
     }
  
     public synchronized RegionManager getRegionManager()
     {
        if (regionManager == null)
        {
           regionManager = new RegionManager(this);
        }
        return regionManager;
     }
  
  
     public VersionAwareMarshaller getMarshaller()
     {
        if (marshaller_ == null)
        {
           marshaller_ = new VersionAwareMarshaller(getRegionManager(), configuration.isInactiveOnStartup(), configuration.isUseRegionBasedMarshalling(), configuration.getReplVersionString());
        }
        return marshaller_;
     }
  
     /**
      * Returns the default JGroup properties.
      * Subclasses may wish to override this method.
      */
     protected String getDefaultProperties()
     {
        return "UDP(mcast_addr=224.0.0.36;mcast_port=55566;ip_ttl=32;" +
                "mcast_send_buf_size=150000;mcast_recv_buf_size=80000):" +
                "PING(timeout=1000;num_initial_members=2):" +
                "MERGE2(min_interval=5000;max_interval=10000):" +
                "FD_SOCK:" +
                "VERIFY_SUSPECT(timeout=1500):" +
                "pbcast.NAKACK(gc_lag=50;max_xmit_size=8192;retransmit_timeout=600,1200,2400,4800):" +
                "UNICAST(timeout=600,1200,2400,4800):" +
                "pbcast.STABLE(desired_avg_gossip=20000):" +
                "FRAG(frag_size=8192;down_thread=false;up_thread=false):" +
                "pbcast.GMS(join_timeout=5000;join_retry_timeout=2000;" +
                "shun=false;print_local_addr=true):" +
                "pbcast.STATE_TRANSFER";
     }
  
     private void initialiseCacheLoaderManager() throws Exception
     {
        if (cacheLoaderManager == null)
        {
           cacheLoaderManager = new CacheLoaderManager();
        }
        cacheLoaderManager.setConfig(configuration.getCacheLoaderConfig(), this);
     }
  
     /**
      * Sets the CacheLoader to use.
      * Provided for backwards compatibility.
      *
      * @param loader
      * @deprecated
      */
     public void setCacheLoader(CacheLoader loader)
     {
        log.warn("Using deprecated config method setCacheLoader.  This element will be removed in future, please use CacheLoaderConfiguration instead.");
  
        try
        {
           if (cacheLoaderManager == null) initialiseCacheLoaderManager();
        }
        catch (Exception e)
        {
           log.warn("Problem setting cache loader.  Perhaps your cache loader config has not been set yet?");
        }
        cacheLoaderManager.setCacheLoader(loader);
     }
  
     /**
      * Purges the contents of all configured {@link CacheLoader}s
      */
     public void purgeCacheLoaders() throws Exception
     {
        if (cacheLoaderManager != null) cacheLoaderManager.purgeLoaders(true);
     }
  
     // ---------------------------------------------------------------
     // END: Methods to provide backward compatibility with older cache loader config settings
     // ---------------------------------------------------------------
  
     private JChannel getMultiplexerChannel()
     {
        String stackName = configuration.getMultiplexerStack();
  
        RuntimeConfig rtc = configuration.getRuntimeConfig();
        JChannelFactoryMBean channelFactory = rtc.getMuxChannelFactory();
        try
        {
           if (channelFactory != null)
           {
              return (JChannel) channelFactory.createMultiplexerChannel(stackName, configuration.getClusterName());
           }
           else
           {
              // FIXME -- why do we support this?  Move into a specialized JMX class
              // meant for dealing with old-style config files
              String serviceName = configuration.getMultiplexerService();
  
              if (serviceName == null || serviceName.length() == 0)
              {
                 return null;
              }
  
              MBeanServer mbserver = rtc.getMbeanServer();
              if (mbserver == null)
              {
                 log.warn("Multiplexer service specified but MBean server not found." +
                         "  Multiplexer will not be used for cache cluster " + configuration.getClusterName() + ".");
                 return null;
              }
  
              ObjectName muxName = new ObjectName(serviceName);
  
              // see if Multiplexer service is registered
              if (!mbserver.isRegistered(muxName))
              {
                 log.warn("Multiplexer service specified but '" + serviceName + "' not registered." +
                         "  Multiplexer will not be used for cache cluster " + configuration.getClusterName() + ".");
                 return null;
              }
  
              // create the multiplexer channel and return as a JChannel instance
              Object[] params = {stackName, configuration.getClusterName()};
              return (JChannel) mbserver.invoke(muxName, CREATE_MUX_CHANNEL, params, MUX_TYPES);
           }
        }
        catch (Exception e)
        {
           log.error("Multiplexer channel creation failed." +
                   "  Multiplexer will not be used for cache cluster " + configuration.getClusterName() + ".", e);
           return null;
        }
     }
  
     // ================== methods to implement Cache and CacheSPI interfaces ============================
  
     public List<Interceptor> getInterceptorChain()
     {
        return Collections.unmodifiableList(getInterceptors());
     }
  
     public void addCacheListener(CacheListener l)
     {
        getNotifier().addCacheListener(l);
     }
  
     public void addCacheListener(Fqn region, CacheListener l)
     {
        throw new UnsupportedOperationException("Not implemented in this release");
     }
  
     public void removeCacheListener(CacheListener l)
     {
        getNotifier().removeCacheListener(l);
     }
  
     public void removeCacheListener(Fqn region, CacheListener l)
     {
        throw new UnsupportedOperationException("Not implemented in this release");
     }
  
     public Set<CacheListener> getCacheListeners()
     {
        return getNotifier().getCacheListeners();
     }
  
     public Set<CacheListener> getCacheListeners(Fqn region)
     {
        throw new UnsupportedOperationException("Not implemented in this release");
     }
  
     public synchronized void addInterceptor(Interceptor i, int position)
     {
        List<Interceptor> interceptors = getInterceptors();
  
        i.setCache(this);
  
        interceptors.add(position, i);
  
        // now correct the chaining of interceptors...
        Interceptor linkedChain = InterceptorChainFactory.correctInterceptorChaining(interceptors);
  
        setInterceptorChain(linkedChain);
     }
  
     public synchronized void removeInterceptor(int position)
     {
        List<Interceptor> i = getInterceptors();
        i.remove(position);
        setInterceptorChain(InterceptorChainFactory.correctInterceptorChaining(i));
     }
  
     public RPCManager getRPCManager()
     {
        return RPCManager.getInstance(this);
     }
  
     public String getClusterName()
     {
        return getConfiguration().getClusterName();
     }
  
     public void evict(Fqn fqn, boolean recursive)
     {
        if (recursive)
        {
           Node n = get(fqn);
           if (n != null)
           {
              evictChildren(n);
           }
        }
        else
        {
           evict(fqn);
        }
     }
  
     private void evictChildren(Node n)
     {
        Set<Node> children = n.getChildren();
        for (Node child : children)
        {
           evictChildren(child);
        }
        evict(n.getFqn());
     }
  
     public Region getRegion(Fqn fqn, boolean createIfAbsent)
     {
        return getRegionManager().getRegion(fqn, createIfAbsent);
     }
  
     public void removeNode(Fqn fqn)
     {
        remove(fqn);
     }
  
     public void putForExternalRead(Fqn fqn, Object key, Object value)
     {
        throw new UnsupportedOperationException("Not yet implemented.");
        // TODO Implement this method PROPERLY as per JBCACHE-848
  //      getInvocationContext().getOptionOverrides().setFailSilently(true);
  //      put(fqn, key, value);
     }
  
     public boolean isStarted()
     {
        return started;
     }
  }
  
  
  
  1.1      date: 2006/12/30 17:49:54;  author: msurtani;  state: Exp;JBossCache/src/org/jboss/cache/UnversionedNode.java
  
  Index: UnversionedNode.java
  ===================================================================
  /*
   * JBoss, Home of Professional Open Source
   *
   * Distributable under LGPL license.
   * See terms of license at gnu.org.
   */
  package org.jboss.cache;
  
  import org.apache.commons.logging.Log;
  import org.apache.commons.logging.LogFactory;
  import org.jboss.cache.factories.NodeFactory;
  import org.jboss.cache.lock.IdentityLock;
  import org.jboss.cache.lock.LockingException;
  import org.jboss.cache.lock.NodeLock;
  import org.jboss.cache.lock.TimeoutException;
  import org.jboss.cache.marshall.MethodCall;
  import org.jboss.cache.marshall.MethodCallFactory;
  import org.jboss.cache.marshall.MethodDeclarations;
  import org.jboss.cache.optimistic.DataVersion;
  import org.jboss.cache.util.MapCopy;
  
  import java.io.Serializable;
  import java.util.AbstractSet;
  import java.util.Collections;
  import java.util.HashMap;
  import java.util.HashSet;
  import java.util.Iterator;
  import java.util.Map;
  import java.util.Set;
  import java.util.concurrent.ConcurrentHashMap;
  
  /**
   * Basic data node class.
   */
  public class UnversionedNode extends AbstractNode implements NodeSPI
  {
  
     /**
      * Default output indent for printing.
      */
     private static final int INDENT = 4;
  
     /**
      * Debug log.
      */
     private static Log log = LogFactory.getLog(UnversionedNode.class);
  
     /**
      * True if all children have been loaded. This is set when CacheImpl.getChildrenNames() is called.
      */
     private boolean childrenLoaded = false;
  
     /**
      * True if data has been loaded from the cache loader.
      */
     private boolean dataLoaded = false;
  
     /**
      * Lock manager that manages locks to be acquired when accessing the node inside a transaction. Lazy set just in case
      * locking is not needed.
      */
     private transient IdentityLock lock_ = null;
  
     /**
      * A reference of the CacheImpl instance.
      */
     private transient CacheSPI cache;
  
     /**
      * Name of the node.
      */
     private Fqn fqn;
  
     /**
      * Map of general data keys to values.
      */
     private Map data;
  
     /**
      * Constructs a new node with an FQN of Root.
      */
     public UnversionedNode()
     {
        this(Fqn.ROOT);
     }
  
     /**
      * Constructs a new node with an FQN.
      */
     public UnversionedNode(Fqn fqn)
     {
        this.fqn = fqn;
     }
  
     /**
      * Constructs a new node with a name, etc.
      */
     public UnversionedNode(Object child_name, Fqn fqn, Map data, CacheSPI cache)
     {
        init(child_name, fqn, cache);
        if (data != null)
        {
           this.data().putAll(data);
        }
     }
  
     /**
      * Constructs a new node with a name, etc.
      *
      * @param mapSafe <code>true</code> if param <code>data</code> can safely be directly assigned to this object's
      *                {@link #data} field; <code>false</code> if param <code>data</code>'s contents should be copied into
      *                this object's {@link #data} field.
      */
     public UnversionedNode(Object child_name, Fqn fqn, Map data, boolean mapSafe, CacheSPI cache)
     {
        init(child_name, fqn, cache);
        if (data != null)
        {
           if (mapSafe)
           {
              if (data.getClass().getName().startsWith("java.util.Collections"))
              {
                 throw new IllegalArgumentException("What's this crap? " + data);
              }
              this.data = data;// ? is this safe
           }
           else
           {
              this.data = new HashMap(data);
           }
        }
     }
  
     /**
      * Initializes with a name and FQN and cache.
      */
     private void init(Object child_name, Fqn fqn, CacheSPI cache)
     {
        if (cache == null)
        {
           throw new IllegalArgumentException("no cache init for " + fqn);
        }
        this.cache = cache;
        this.fqn = fqn;
        if (!fqn.isRoot() && !child_name.equals(fqn.getLast()))
        {
           throw new IllegalArgumentException("Child " + child_name + " must be last part of " + fqn);
        }
     }
  
     /**
      * Returns a parent by checking the TreeMap by name.
      */
     public Node getParent()
     {
        if (fqn.isRoot())
        {
           return null;
        }
        return cache.peek(fqn.getParent());
     }
  
     private synchronized void initLock()
     {
        if (lock_ == null)
        {
           lock_ = new IdentityLock(cache.getConfiguration().getIsolationLevel(), this);
        }
     }
  
     private synchronized Map<Object, Node> children()
     {
        if (children == null)
        {
           if (getFqn().isRoot())
           {
              children = new ConcurrentHashMap<Object, Node>(64, .5f, 16);
           }
           else
           {
              // Less segments to save memory
              children = new ConcurrentHashMap<Object, Node>(4, .75f, 4);
           }
        }
        return children;
     }
  
     public void setCache(CacheSPI cache)
     {
        this.cache = cache;
        this.lock_ = null;
        if (children != null)
        {
           for (Node n : children.values())
           {
              n.getNodeSPI().setCache(cache);
           }
        }
     }
  
     public CacheSPI getCache()
     {
        return cache;
     }
  
     public boolean getChildrenLoaded()
     {
        return childrenLoaded;
     }
  
     public void setChildrenLoaded(boolean flag)
     {
        childrenLoaded = flag;
     }
  
     public synchronized Object get(Object key)
     {
        if (data == null)
        {
           return null;
        }
        return data.get(key);
     }
  
     public synchronized boolean containsKey(Object key)
     {
        return data != null && data.containsKey(key);
     }
  
     /**
      * Returns the data keys, or an empty set if there are no keys.
      */
     public Set getDataKeys()
     {
        return getKeys();
     }
  
     private boolean isReadLocked()
     {
        return lock_ != null && lock_.isReadLocked();
     }
  
     private boolean isWriteLocked()
     {
        return lock_ != null && lock_.isWriteLocked();
     }
  
     public IdentityLock getLock()
     {
        initLock();
        return lock_;
     }
  
     public synchronized Map getData()
     {
        if (data == null)
        {
           return Collections.EMPTY_MAP;
        }
        return Collections.unmodifiableMap(data);
     }
  
     protected void put(Map data, boolean erase)
     {
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           try
           {
              if (data == null)
              {
                 return;
              }
              if (log.isTraceEnabled())
              {
                 log.trace("put " + data.size() + " erase=" + erase);
              }
              synchronized (this)
              {
                 if (erase)
                 {
                    if (this.data != null)
                    {
                       this.data.clear();
                    }
                 }
                 data().putAll(data);
              }
           }
           finally
           {
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
           }
        }
        else
        {
           // TODO add erase option to Cache (?)
           if (erase)
           {
              ((CacheImpl) cache).removeData(fqn);
           }
           cache.put(fqn, data);
        }
     }
  
     public Object put(Object key, Object value)
     {
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           Object result;
           try
           {
              synchronized (this)
              {
                 result = data().put(key, value);
              }
           }
           finally
           {
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
           }
           return result;
        }
        else
        {
           return cache.put(getFqn(), key, value);
        }
     }
  
     public Node getOrCreateChild(Object child_name, GlobalTransaction gtx)
     {
        return getOrCreateChild(child_name, gtx, true);
     }
  
     private Node getOrCreateChild(Object child_name, GlobalTransaction gtx, boolean createIfNotExists)
     {
  
        Node child;
        if (child_name == null)
        {
           throw new IllegalArgumentException("null child name");
        }
  
        child = children().get(child_name);
        if (createIfNotExists && child == null)
        {
           // construct the new child outside the synchronized block to avoid
           // spending any more time than necessary in the synchronized section
           Fqn child_fqn = new Fqn(this.fqn, child_name);
           Node newChild = NodeFactory.getInstance().createNode(child_name, child_fqn, this, null, cache);
           if (newChild == null)
           {
              throw new IllegalStateException();
           }
           synchronized (this)
           {
              // check again to see if the child exists
              // after acquiring exclusive lock
              child = children().get(child_name);
              if (child == null)
              {
                 cache.getNotifier().notifyNodeCreated(child_fqn, true);
                 child = newChild;
                 children.put(child_name, child);
                 if (gtx != null)
                 {
                    MethodCall undo_op = MethodCallFactory.create(MethodDeclarations.removeNodeMethodLocal, gtx,
                            child_fqn, false);
                    cache.addUndoOperation(gtx, undo_op);
                    // add the node name to the list maintained for the current tx
                    // (needed for abort/rollback of transaction)
                    // cache.addNode(gtx, child.getFqn());
                 }
              }
           }
  
           // notify if we actually created a new child
           if (newChild == child)
           {
              if (log.isTraceEnabled())
              {
                 log.trace("created child: fqn=" + child_fqn);
              }
              cache.getNotifier().notifyNodeCreated(child_fqn, false);
           }
        }
        return child;
  
     }
  
     public Node createChild(Object child_name, Fqn fqn, Node parent)
     {
        return getOrCreateChild(child_name, null, true);
     }
  
     public Node createChild(Object child_name, Fqn fqn, Node parent, Object key, Object value)
     {
        Node n = getOrCreateChild(child_name, null, true);
        n.put(key, value);
        return n;
     }
  
     public Object remove(Object key)
     {
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           Object result;
           try
           {
              synchronized (this)
              {
                 if (data == null)
                 {
                    result = null;
                 }
                 else
                 {
                    result = data.remove(key);
                 }
              }
           }
           finally
           {
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
           }
           return result;
        }
        else
        {
           return cache.remove(getFqn(), key);
        }
     }
  
     public void printDetails(StringBuffer sb, int indent)
     {
        printDetailsInMap(sb, indent);
     }
  
     /**
      * Returns a debug string.
      */
     @Override
     public String toString()
     {
        StringBuffer sb = new StringBuffer();
        if (deleted)
           sb.append("Node (deleted) [ ").append(fqn);
        else
           sb.append("Node[ ").append(fqn);
        synchronized (this)
        {
           if (data != null)
           {
              sb.append(" data=").append(data.keySet());
           }
        }
        if (children != null && !children.isEmpty())
        {
           sb.append(" child=").append(children.keySet());
        }
        if (lock_ != null)
        {
           if (isReadLocked())
           {
              sb.append(" RL");
           }
           if (isWriteLocked())
           {
              sb.append(" WL");
           }
        }
        sb.append("]");
        return sb.toString();
     }
  
     public void release(Object caller)
     {
        if (lock_ != null)
        {
           if (log.isTraceEnabled())
           {
              boolean wOwner = lock_.isWriteLocked() && lock_.getWriterOwner().equals(caller);
              log.trace("releasing " + (wOwner ? "WL" : "RL") + ": fqn=" + fqn + ", caller=" + caller);
           }
           lock_.release(caller);
           if (log.isTraceEnabled())
           {
              boolean wOwner = lock_.isWriteLocked() && lock_.getWriterOwner().equals(caller);
              log.trace("released " + (wOwner ? "WL" : "RL") + ": fqn=" + fqn + ", caller=" + caller);
           }
        }
     }
  
     public Node addChild(Fqn f)
     {
        if (log.isTraceEnabled())
        {
           log.trace("adding child " + f + " to " + getFqn());
        }
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           Node newNode = this;
           try
           {
              GlobalTransaction gtx = cache.getInvocationContext().getGlobalTransaction();
  
              if (f.size() == 1)
              {
                 newNode = getOrCreateChild(f.getLast(), gtx);
              }
              else
              {
                 // recursively create children
                 Node currentParent = this;
                 for (Object o : f.peekElements())
                 {
                    newNode = currentParent.getNodeSPI().getOrCreateChild(o, gtx);
                    currentParent = newNode;
                 }
              }
           }
           finally
           {
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
           }
           return newNode;
        }
        else
        {
           Fqn nf = new Fqn(getFqn(), f);
           cache.put(nf, Collections.emptyMap());
           return getChild(f);
        }
     }
  
     public void clearData()
     {
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           try
           {
              synchronized (this)
              {
                 if (data != null)
                 {
                    data.clear();
                 }
              }
           }
           finally
           {
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
           }
        }
        else
        {
           ((CacheImpl) cache).removeData(getFqn());
        }
     }
  
     public Node getChild(Fqn fqn)
     {
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           try
           {
              Node child = getChild(fqn.getLast());
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
              return child;
           }
           finally
           {
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
           }
        }
        else
        {
           return ((CacheImpl) cache).get(new Fqn(getFqn(), fqn));
        }
     }
  
     public Set<Object> getChildrenNames()
     {
        return new ChildrenNames();
     }
  
     public synchronized Set getKeys()
     {
        if (data == null)
        {
           return Collections.emptySet();
        }
        return Collections.unmodifiableSet(data.keySet());
     }
  
     public boolean hasChild(Fqn f)
     {
        return ((CacheImpl) cache).exists(new Fqn(getFqn(), f));
     }
  
     public void move(Node newParent) throws NodeNotExistsException
     {
        if (log.isTraceEnabled())
        {
           log.trace(this.getFqn() + " move to " + newParent.getFqn());
        }
        // TODO
        // move must be added to Cache
        ((CacheImpl) cache).move(newParent.getFqn(), getFqn());
     }
  
     public void putIfNull(Object k, Object v)
     {
        if (cache.get(getFqn(), k) == null)
        {
           put(k, v);
        }
     }
  
     public void putIfNull(Map m)
     {
        if (getData().isEmpty())
        {
           put(m);
        }
     }
  
     public void removeChild(Fqn fqn)
     {
        if (cache.getInvocationContext().getOptionOverrides().isBypassInterceptorChain())
        {
           if (fqn.size() == 1)
           {
              children.remove(fqn.getName());
           }
           else
           {
              Node c = getChild(fqn);
              cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
              c.getParent().removeChild(new Fqn(fqn.getName()));
           }
           cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
        }
        else
        {
           cache.removeNode(new Fqn(getFqn(), fqn));
        }
     }
  
     public Map<Object, Node> getChildrenMap()
     {
        return children();
     }
  
     public boolean acquire(Object caller, long lock_acquisition_timeout, NodeLock.LockType lockType) throws InterruptedException,
             LockingException, TimeoutException
     {
        return getLock().acquire(caller, lock_acquisition_timeout, lockType);
     }
  
     public Set acquireAll(Object caller, long timeout, NodeLock.LockType lockType) throws LockingException, TimeoutException,
             InterruptedException
     {
        return getLock().acquireAll(caller, timeout, lockType);
     }
  
     public void setChildrenMap(Map children)
     {
        this.children = children;
     }
  
     public boolean hasChildren()
     {
        return children != null && children.size() > 0;
     }
  
     public void put(Map data)
     {
        put(data, false);
     }
  
     public void removeChild(Object child_name)
     {
        if (children != null)
        {
           children.remove(child_name);
           if (log.isTraceEnabled())
           {
              log.trace(getName() + " removed child " + child_name);
           }
        }
     }
  
     public void removeChildren()
     {
        if (children != null)
        {
           children.clear();
        }
        children = null;
     }
  
     public void print(StringBuffer sb, int indent)
     {
        printIndent(sb, indent);
        sb.append(Fqn.SEPARATOR).append(getName()).append(" ").append(getData().size());
        if (children != null)
        {
           for (Node node : children.values())
           {
              sb.append("\n");
              node.getNodeSPI().print(sb, indent + INDENT);
           }
        }
     }
  
     // versioning
  
     public void setVersion(DataVersion version)
     {
        throw new UnsupportedOperationException("Versioning not supported");
     }
  
     public DataVersion getVersion()
     {
        throw new UnsupportedOperationException("Versioning not supported");
     }
  
     private void printIndent(StringBuffer sb, int indent)
     {
        if (sb != null)
        {
           for (int i = 0; i < indent; i++)
           {
              sb.append(" ");
           }
        }
     }
  
     public void addChild(Object child_name, Node n)
     {
        if (child_name != null)
        {
           children().put(child_name, n);
        }
     }
  
     /**
      * Returns the name of this node.
      */
     public Object getName()
     {
        return fqn.getLast();
     }
  
     /**
      * Returns the name of this node.
      */
     public Fqn getFqn()
     {
        return fqn;
     }
  
     public void setFqn(Fqn fqn)
     {
        if (log.isTraceEnabled())
        {
           log.trace(getFqn() + " set FQN " + fqn);
        }
        this.fqn = fqn;
  
        if (children == null)
        {
           return;
        }
  
        // process children
        for (Map.Entry<Object, Node> me : children.entrySet())
        {
           NodeSPI n = me.getValue().getNodeSPI();
           Fqn cfqn = new Fqn(fqn, me.getKey());
           n.setFqn(cfqn);
        }
     }
  
     public Node getChild(Object child_name)
     {
        if (child_name == null)
        {
           return null;
        }
        return children == null ? null : children.get(child_name);
     }
  
     public boolean childExists(Object child_name)
     {
        return child_name != null && children != null && children.containsKey(child_name);
     }
  
     public Set<Node> getChildren()
     {
        // strip out deleted child nodes...
        if (children == null || children.size() == 0) return Collections.emptySet();
  
        Set<Node> exclDeleted = new HashSet<Node>();
        for (Node n : children.values())
        {
           if (!((NodeSPI) n).isDeleted()) exclDeleted.add(n);
        }
        return Collections.unmodifiableSet(exclDeleted);
     }
  
     public Set<Node> getChildren(boolean includeMarkedForRemoval)
     {
        if (includeMarkedForRemoval)
        {
           if (children != null && !children.isEmpty())
           {
              return Collections.unmodifiableSet(new HashSet<Node>(children.values()));
           }
           else
           {
              return Collections.emptySet();
           }
        }
        else
        {
           return getChildren();
        }
     }
  
     public synchronized Map<Object, Object> getRawData()
     {
        return data();
     }
  
     /**
      * Returns null or the Map in use with the data.
      */
     private Map data()
     {
        if (data == null)
        {
           data = new HashMap<Object, Object>();
        }
        return data;
     }
  
     /**
      * Adds details of the node into a map as strings.
      */
     private void printDetailsInMap(StringBuffer sb, int indent)
     {
        printIndent(sb, indent);
        indent += 2;// increse it
        if (!(getFqn()).isRoot())
        {
           sb.append(Fqn.SEPARATOR);
        }
        sb.append(getName());
        sb.append("  ");
        sb.append(data());
        if (children != null)
        {
           for (Node n : children.values())
           {
              sb.append("\n");
              n.getNodeSPI().printDetails(sb, indent);
           }
        }
     }
  
     /**
      * Returns true if the data was loaded from the cache loader.
      */
     public boolean getDataLoaded()
     {
        return dataLoaded;
     }
  
     /**
      * Sets if the data was loaded from the cache loader.
      */
     public void setDataLoaded(boolean dataLoaded)
     {
        this.dataLoaded = dataLoaded;
     }
  
     public NodeSPI getNodeSPI()
     {
        return this;
     }
  
     /**
      * Might be useful to expose; a debug feature for now.
      */
     void setReadOnly()
     {
        this.data = new MapCopy(data());
        this.children = new MapCopy(children());
     }
  
     private class ChildrenNames extends AbstractSet implements Serializable
     {
  
        /**
         * Since writeReplace() returns a different class, this isn't really necessary.
         */
        private static final long serialVersionUID = 5468697840097489795L;
  
        @Override
        public Iterator iterator()
        {
           if (children == null)
           {
              return Collections.emptySet().iterator();
           }
           return children.keySet().iterator();
        }
  
        @Override
        public boolean contains(Object o)
        {
           return children != null && children.containsKey(o);
        }
  
        @Override
        public int size()
        {
           if (children == null)
           {
              return 0;
           }
           return children.size();
        }
  
        private Object writeReplace()
        {
           if (children == null)
           {
              return Collections.emptySet();
           }
           return Collections.unmodifiableSet(new HashSet(children.keySet()));
        }
  
     }
  
     /*
     private class ChildrenNodes<T> extends AbstractSet
     {
        private boolean includeDeleted;
  
        public ChildrenNodes(boolean includeDeleted)
        {
           this.includeDeleted = includeDeleted;
        }
  
        @Override
        public boolean contains(Object o)
        {
           return children != null && children.containsValue(o);
        }
  
        @Override
        public Iterator iterator()
        {
           if (children == null)
           {
              return Collections.emptySet().iterator();
           }
           return children.values().iterator();
        }
  
        // although the map is empty
        @Override
        public void clear()
        {
           throw new UnsupportedOperationException();
        }
  
        @Override
        public int size()
        {
           if (children == null)
           {
              return 0;
           }
           return children.size();
        }
  
     }
     */
  
  }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader ...
Message-ID: <E1H0iLG-0008PL-0p@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    tests/functional/org/jboss/cache/loader                
                        AsyncFileCacheLoaderTest.java
                        DataSourceIntegrationTest.java
                        SharedCacheLoaderTest.java
                        InterceptorSynchronizationTest.java
                        CacheLoaderMethodCallCounterTest.java
                        ChainingCacheLoaderFullTest.java
                        TxCacheLoaderTest.java
                        LocalDelegatingCacheLoaderTest.java
                        SingletonStoreCacheLoaderTest.java BdbjeTest.java
                        ClusteredCacheLoaderTest.java DummyCacheLoader.java
                        CacheLoaderWithReplicationTest.java
                        CacheLoaderTestsBase.java
                        RpcDelegatingCacheLoaderTests.java
                        CacheLoaderPurgingTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.17      +10 -10    JBossCache/tests/functional/org/jboss/cache/loader/AsyncFileCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncFileCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/AsyncFileCacheLoaderTest.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- AsyncFileCacheLoaderTest.java	25 Oct 2006 04:50:19 -0000	1.16
  +++ AsyncFileCacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.17
  @@ -4,13 +4,13 @@
   import junit.framework.Test;
   import junit.framework.TestSuite;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.statetransfer.StateTransferManager;
  -import org.jboss.util.stream.MarshalledValueOutputStream;
   import org.jboss.util.stream.MarshalledValueInputStream;
  +import org.jboss.util.stream.MarshalledValueOutputStream;
   
   import java.io.ByteArrayInputStream;
   import java.io.ByteArrayOutputStream;
  @@ -20,7 +20,7 @@
   public class AsyncFileCacheLoaderTest extends AbstractCacheLoaderTestBase
   {
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      protected void configureCache() throws Exception
      {
  @@ -29,7 +29,7 @@
   
      protected void configureCache(String props) throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         // cache.setCacheLoaderConfiguration(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.jdbm.JdbmCacheLoader",
         cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader",
  
  
  
  1.10      +3 -3      JBossCache/tests/functional/org/jboss/cache/loader/DataSourceIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataSourceIntegrationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/DataSourceIntegrationTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- DataSourceIntegrationTest.java	25 Oct 2006 04:50:19 -0000	1.9
  +++ DataSourceIntegrationTest.java	30 Dec 2006 17:49:57 -0000	1.10
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.loader;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
  @@ -23,7 +23,7 @@
      private String old_factory = null;
      private final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
      private final String JNDI_NAME = "java:/MockDS";
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      protected void setUp() throws Exception
      {
  @@ -59,7 +59,7 @@
         {
            // expected
         }
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("local");
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig(JNDI_NAME));
  
  
  
  1.8       +8 -8      JBossCache/tests/functional/org/jboss/cache/loader/SharedCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SharedCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/SharedCacheLoaderTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- SharedCacheLoaderTest.java	25 Oct 2006 04:50:19 -0000	1.7
  +++ SharedCacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.8
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.loader;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.interceptors.CacheStoreInterceptor;
   import org.jboss.cache.interceptors.Interceptor;
   
  @@ -19,16 +19,16 @@
    */
   public class SharedCacheLoaderTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache1, cache2;
  +   private CacheImpl cache1, cache2;
      private DummyCacheLoader dummyCacheLoader;
   
      protected void setUp() throws Exception
      {
         if (cache1 != null || cache2 != null) tearDown();
   
  -      // set up 2 instances of TreeCache with shared CacheLoaders.
  -      cache1 = new TreeCache();
  -      cache2 = new TreeCache();
  +      // set up 2 instances of CacheImpl with shared CacheLoaders.
  +      cache1 = new CacheImpl();
  +      cache2 = new CacheImpl();
   
         cache1.getConfiguration().setCacheMode("REPL_SYNC");
         cache2.getConfiguration().setCacheMode("REPL_SYNC");
  @@ -44,11 +44,11 @@
   
         cache1.setCacheLoader(dummyCacheLoader);
         cache2.setCacheLoader(dummyCacheLoader);
  -      findCacheStoreInterceptor(cache1).setCache(cache1.getCacheSPI());
  -      findCacheStoreInterceptor(cache2).setCache(cache2.getCacheSPI());
  +      findCacheStoreInterceptor(cache1).setCache(cache1);
  +      findCacheStoreInterceptor(cache2).setCache(cache2);
      }
   
  -   protected CacheStoreInterceptor findCacheStoreInterceptor(TreeCache cache)
  +   protected CacheStoreInterceptor findCacheStoreInterceptor(CacheImpl cache)
      {
         Iterator ints = cache.getInterceptors().iterator();
         CacheStoreInterceptor csi = null;
  
  
  
  1.6       +6 -6      JBossCache/tests/functional/org/jboss/cache/loader/InterceptorSynchronizationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InterceptorSynchronizationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/InterceptorSynchronizationTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- InterceptorSynchronizationTest.java	23 Oct 2006 05:47:30 -0000	1.5
  +++ InterceptorSynchronizationTest.java	30 Dec 2006 17:49:57 -0000	1.6
  @@ -2,9 +2,9 @@
   
   import junit.framework.TestCase;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   
   import java.io.ObjectInputStream;
  @@ -18,7 +18,7 @@
   import java.util.Set;
   
   /**
  - * Test case that proves that the TreeCache is serialized inside the CacheLoaderInterceptor
  + * Test case that proves that the CacheImpl is serialized inside the CacheLoaderInterceptor
    * when the node is empty.  ANY call to retrieve a node that is not loaded will lock
    * up inside CacheLoaderInterceptor while the node is loaded and any other thread
    * that wants a node out of the cache will wait for the first one to finish before it can even _start_ loading.
  @@ -35,7 +35,7 @@
      public void testBlockingProblem() throws Exception
      {
   
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.setCacheLoader(new TestSlowCacheLoader());
         cache.start();
   
  @@ -220,9 +220,9 @@
      private static class Retriever implements Runnable
      {
         private final String fqn;
  -      private TreeCache cache;
  +      private CacheImpl cache;
   
  -      private Retriever(TreeCache cache, String fqn)
  +      private Retriever(CacheImpl cache, String fqn)
         {
            this.fqn = fqn;
            this.cache = cache;
  
  
  
  1.12      +3 -3      JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderMethodCallCounterTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderMethodCallCounterTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderMethodCallCounterTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- CacheLoaderMethodCallCounterTest.java	25 Oct 2006 04:50:19 -0000	1.11
  +++ CacheLoaderMethodCallCounterTest.java	30 Dec 2006 17:49:57 -0000	1.12
  @@ -7,7 +7,7 @@
   package org.jboss.cache.loader;
   
   import junit.textui.TestRunner;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   
   /**
    * A simple non-failing unit test to measure how many times each method on a cache loader is called.
  @@ -16,7 +16,7 @@
    */
   public class CacheLoaderMethodCallCounterTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private DummyCacheLoader dummyLoader;
   
      public static void main(String[] args)
  @@ -27,7 +27,7 @@
      protected void setUp() throws Exception
      {
         if (cache != null) tearDown();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", DummyCacheLoader.class.getName(), "", false, false, false));
         cache.start();
         dummyLoader = (DummyCacheLoader) cache.getCacheLoader();
  
  
  
  1.9       +3 -3      JBossCache/tests/functional/org/jboss/cache/loader/ChainingCacheLoaderFullTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChainingCacheLoaderFullTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/ChainingCacheLoaderFullTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ChainingCacheLoaderFullTest.java	25 Oct 2006 04:50:19 -0000	1.8
  +++ ChainingCacheLoaderFullTest.java	30 Dec 2006 17:49:57 -0000	1.9
  @@ -10,8 +10,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.xml.XmlHelper;
  @@ -30,7 +30,7 @@
      private String loc1 = System.getProperty("java.io.tmpdir", ".") + File.separator + "JBossCache-ChainingCacheLoaderBasicTest-1";
      private String loc2 = System.getProperty("java.io.tmpdir", ".") + File.separator + "JBossCache-ChainingCacheLoaderBasicTest-2";
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private ChainingCacheLoader chainingCacheLoader;
      private CacheLoader loader1, loader2;
      private Fqn fqn = Fqn.fromString("/a/b");
  @@ -49,7 +49,7 @@
   
      protected void startCache(boolean ignoreMods1, boolean ignoreMods2) throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig(loc1, loc2, ignoreMods1, ignoreMods2));
         cache.getConfiguration().setCacheMode("local");
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  
  1.8       +5 -5      JBossCache/tests/functional/org/jboss/cache/loader/TxCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/TxCacheLoaderTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- TxCacheLoaderTest.java	25 Oct 2006 04:50:19 -0000	1.7
  +++ TxCacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.8
  @@ -2,8 +2,8 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
  @@ -16,11 +16,11 @@
   
   /**
    * @author Bela Ban
  - * @version $Id: TxCacheLoaderTest.java,v 1.7 2006/10/25 04:50:19 bstansberry Exp $
  + * @version $Id: TxCacheLoaderTest.java,v 1.8 2006/12/30 17:49:57 msurtani Exp $
    */
   public class TxCacheLoaderTest extends AbstractCacheLoaderTestBase
   {
  -   TreeCache cache1, cache2;
  +   CacheImpl cache1, cache2;
      private Fqn fqn = Fqn.fromString("/one/two/three");
   
      protected void setUp() throws Exception
  @@ -30,7 +30,7 @@
         String tmpLoc = System.getProperty("java.io.tmpdir", "/tmp");
         String location = tmpLoc + File.separator + "TxCacheLoaderTest1";
   
  -      cache1 = new TreeCache();
  +      cache1 = new CacheImpl();
         cache1.getConfiguration().setCacheMode("repl_sync");
         cache1.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
   
  @@ -41,7 +41,7 @@
   
         location = tmpLoc + File.separator + "TxCacheLoaderTest2";
   
  -      cache2 = new TreeCache();
  +      cache2 = new CacheImpl();
         cache2.getConfiguration().setCacheMode("repl_sync");
         cache2.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache2.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader", "location=" + location, false, false, false));
  
  
  
  1.15      +6 -5      JBossCache/tests/functional/org/jboss/cache/loader/LocalDelegatingCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalDelegatingCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/LocalDelegatingCacheLoaderTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- LocalDelegatingCacheLoaderTest.java	16 Nov 2006 16:18:12 -0000	1.14
  +++ LocalDelegatingCacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.15
  @@ -2,7 +2,7 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   
   /**
  @@ -13,11 +13,11 @@
    */
   public class LocalDelegatingCacheLoaderTest extends CacheLoaderTestsBase
   {
  -   TreeCache delegating_cache;
  +   CacheImpl delegating_cache;
   
      protected void configureCache() throws Exception
      {
  -      delegating_cache = new TreeCache();
  +      delegating_cache = new CacheImpl();
         delegating_cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         delegating_cache.create();
         delegating_cache.start();
  @@ -37,11 +37,12 @@
         delegating_cache.destroy();
      }
      
  -   public void testLoadAndStore()throws Exception
  +   public void testLoadAndStore() throws Exception
      {
         //TODO intentional overload since this test does not pass
         //http://jira.jboss.com/jira/browse/JBCACHE-851
      }
  +
      public void testPartialLoadAndStore()
      {
         // do nothing
  
  
  
  1.4       +23 -28    JBossCache/tests/functional/org/jboss/cache/loader/SingletonStoreCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SingletonStoreCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/SingletonStoreCacheLoaderTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SingletonStoreCacheLoaderTest.java	20 Nov 2006 03:53:56 -0000	1.3
  +++ SingletonStoreCacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.4
  @@ -6,18 +6,16 @@
    */
   package org.jboss.cache.loader;
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.NodeImpl;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.xml.XmlHelper;
   import org.w3c.dom.Element;
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
   
   /**
    * Unit test class for SingletonStoreCacheLoader
  @@ -33,13 +31,9 @@
      {
         log.info("*** test:" + getName() + " ***");
   
  -      TreeCache tc1 = new TreeCache();
  -      TreeCache tc2 = new TreeCache();
  -      TreeCache tc3 = new TreeCache();
  -
  -      cache1 = tc1.getCacheSPI();
  -      cache2 = tc2.getCacheSPI();
  -      cache3 = tc3.getCacheSPI();
  +      cache1 = new CacheImpl();
  +      cache2 = new CacheImpl();
  +      cache3 = new CacheImpl();
   
         cache1.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         cache2.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
  @@ -377,7 +371,8 @@
            try
            {
               scl.getPushStateThread().join();
  -         } catch (InterruptedException e)
  +         }
  +         catch (InterruptedException e)
            {
               throw new RuntimeException(e);
            }
  
  
  
  1.15      +22 -20    JBossCache/tests/functional/org/jboss/cache/loader/BdbjeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BdbjeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/BdbjeTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- BdbjeTest.java	26 Oct 2006 19:30:21 -0000	1.14
  +++ BdbjeTest.java	30 Dec 2006 17:49:57 -0000	1.15
  @@ -8,9 +8,9 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.loader.bdbje.BdbjeCacheLoaderConfig;
   import org.jboss.cache.statetransfer.StateTransferManager;
   import org.jboss.util.stream.MarshalledValueInputStream;
  @@ -35,7 +35,7 @@
    * directory.  Any scratch directory will do, but beware that all files in
    * the directory will be deleted by setUp().</p>
    *
  - * @version $Revision: 1.14 $
  + * @version $Revision: 1.15 $
    */
   public class BdbjeTest extends TestCase
   {
  @@ -44,7 +44,7 @@
      private static final String envHome = ".";
      private static final Fqn FQN = new Fqn("key");
   
  -   private TreeCache treeCache;
  +   private CacheImpl cache;
      private CacheLoader loader;
   
      /**
  @@ -109,16 +109,16 @@
            }
            loader = null;
         }
  -      if (treeCache != null)
  +      if (cache != null)
         {
            try
            {
  -            treeCache.stop();
  +            cache.stop();
            }
            catch (Exception ignored)
            {
            }
  -         treeCache = null;
  +         cache = null;
         }
      }
   
  @@ -134,18 +134,18 @@
      {
   
         /*
  -       * Create a dummy TreeCache object.  This is used for setting the cluster
  +       * Create a dummy CacheImpl object.  This is used for setting the cluster
          * name and TransactionManagerLookupClass (transactional) propertes only.
  -       * the TreeCache object is not used otherwise during testing.
  +       * the CacheImpl object is not used otherwise during testing.
          */
  -      treeCache = new TreeCache();
  -      treeCache.getConfiguration().setClusterName("myCluster");
  +      cache = new CacheImpl();
  +      cache.getConfiguration().setClusterName("myCluster");
         if (transactional)
         {
  -         treeCache.getConfiguration().setTransactionManagerLookupClass(
  +         cache.getConfiguration().setTransactionManagerLookupClass(
                    "org.jboss.cache.DummyTransactionManagerLookup");
         }
  -      treeCache.start();
  +      cache.start();
   
         /* Derive the config string. */
         String configStr;
  @@ -162,7 +162,7 @@
         instantiateLoader();
   
         /* Initialize and start the loader. */
  -      loader.setCache(treeCache.getCacheSPI());
  +      loader.setCache(cache);
         BdbjeCacheLoaderConfig config = new BdbjeCacheLoaderConfig();
         config.setLocation(configStr);
         loader.setConfig(config);
  @@ -185,7 +185,7 @@
              throws Exception
      {
   
  -      /* Create the cache loader as TreeCache would. */
  +      /* Create the cache loader as CacheImpl would. */
         Class cls =
                 Class.forName("org.jboss.cache.loader.bdbje.BdbjeCacheLoader");
         loader = (CacheLoader) cls.newInstance();
  @@ -814,7 +814,7 @@
              throws Exception
      {
   
  -      loader.setCache(new TreeCache().getCacheSPI());
  +      loader.setCache(new CacheImpl());
         loader.setConfig(null);
         try
         {
  @@ -838,7 +838,7 @@
         {
         }
   
  -      loader.setCache(new TreeCache().getCacheSPI());
  +      loader.setCache(new CacheImpl());
         config = new BdbjeCacheLoaderConfig();
         config.setLocation("directory_that_does_not_exist");
         loader.setConfig(config);
  @@ -1315,7 +1315,7 @@
         assertTrue(baos.size() > STREAM_HEADER_LENGTH);
         os.close();
   
  -      byte [] savedState = baos.toByteArray();
  +      byte[] savedState = baos.toByteArray();
   
         /* Clear state. */
         baos = new ByteArrayOutputStream(1024);
  @@ -1360,7 +1360,9 @@
       */
      private static class Complex implements Serializable
      {
  -      /** The serialVersionUID */
  +      /**
  +       * The serialVersionUID
  +       */
         private static final long serialVersionUID = -1259096627833244770L;
       
         Complex nested;
  
  
  
  1.11      +4 -4      JBossCache/tests/functional/org/jboss/cache/loader/ClusteredCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClusteredCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/ClusteredCacheLoaderTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ClusteredCacheLoaderTest.java	25 Oct 2006 04:50:19 -0000	1.10
  +++ ClusteredCacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.11
  @@ -9,8 +9,8 @@
   import junit.framework.Assert;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   
   import java.util.Map;
  @@ -24,7 +24,7 @@
   public class ClusteredCacheLoaderTest extends AbstractCacheLoaderTestBase
   {
      private static Log log = LogFactory.getLog(ClusteredCacheLoaderTest.class);
  -   private TreeCache cache1, cache2;
  +   private CacheImpl cache1, cache2;
      private CacheLoader loader1, loader2;
      private Fqn fqn = Fqn.fromString("/a");
      private String key = "key";
  @@ -32,8 +32,8 @@
      protected void setUp() throws Exception
      {
         if (cache1 != null || cache2 != null) tearDown();
  -      cache1 = new TreeCache();
  -      cache2 = new TreeCache();
  +      cache1 = new CacheImpl();
  +      cache2 = new CacheImpl();
   
         cache1.getConfiguration().setClusterName("CCL-Test");
         cache1.getConfiguration().setInitialStateRetrievalTimeout(2000);
  
  
  
  1.7       +6 -6      JBossCache/tests/functional/org/jboss/cache/loader/DummyCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DummyCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/DummyCacheLoader.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- DummyCacheLoader.java	23 Oct 2006 05:47:30 -0000	1.6
  +++ DummyCacheLoader.java	30 Dec 2006 17:49:57 -0000	1.7
  @@ -6,9 +6,9 @@
    */
   package org.jboss.cache.loader;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   
   import java.io.ObjectInputStream;
  @@ -69,14 +69,14 @@
      }
   
      /**
  -    * This method allows the CacheLoader to set the TreeCache, therefore allowing the CacheLoader to invoke
  -    * methods of the TreeCache. It can also use the TreeCache to fetch configuration information. Alternatively,
  +    * This method allows the CacheLoader to set the CacheImpl, therefore allowing the CacheLoader to invoke
  +    * methods of the CacheImpl. It can also use the CacheImpl to fetch configuration information. Alternatively,
       * the CacheLoader could maintain its own configuration<br/>
       * This method will be called directly after the CacheLoader instance has been created
       *
       * @param c The cache on which this loader works
       */
  -   public void setCache(TreeCache c)
  +   public void setCache(CacheImpl c)
      {
      }
   
  
  
  
  1.25      +4 -4      JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderWithReplicationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderWithReplicationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderWithReplicationTest.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- CacheLoaderWithReplicationTest.java	13 Nov 2006 14:20:31 -0000	1.24
  +++ CacheLoaderWithReplicationTest.java	30 Dec 2006 17:49:57 -0000	1.25
  @@ -11,8 +11,8 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -26,7 +26,7 @@
    */
   public class CacheLoaderWithReplicationTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache1, cache2;
  +   private CacheImpl cache1, cache2;
      private String tmpLocation1 = System.getProperty("java.io.tmpdir", ".") + File.separator + "JBossCache-CacheLoaderWithReplicationTest1";
      private String tmpLocation2 = System.getProperty("java.io.tmpdir", ".") + File.separator + "JBossCache-CacheLoaderWithReplicationTest2";
      private File dir1 = new File(tmpLocation1);
  @@ -52,11 +52,11 @@
   
      public void setUp() throws Exception
      {
  -      cache1 = new TreeCache();
  +      cache1 = new CacheImpl();
         cache1.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", "location=" + tmpLocation1, false, true, false));
         cache1.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
   
  -      cache2 = new TreeCache();
  +      cache2 = new CacheImpl();
         cache2.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.bdbje.BdbjeCacheLoader", "location=" + tmpLocation2, false, true, false));
         cache2.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
      }
  
  
  
  1.39      +7 -7      JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -b -r1.38 -r1.39
  --- CacheLoaderTestsBase.java	15 Dec 2006 17:30:31 -0000	1.38
  +++ CacheLoaderTestsBase.java	30 Dec 2006 17:49:57 -0000	1.39
  @@ -3,10 +3,10 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.buddyreplication.BuddyManager;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.statetransfer.StateTransferManager;
  @@ -29,13 +29,13 @@
    * Commons tests for all CacheLoaders
    *
    * @author Bela Ban
  - * @version $Id: CacheLoaderTestsBase.java,v 1.38 2006/12/15 17:30:31 msurtani Exp $
  + * @version $Id: CacheLoaderTestsBase.java,v 1.39 2006/12/30 17:49:57 msurtani Exp $
    */
   abstract public class CacheLoaderTestsBase extends AbstractCacheLoaderTestBase
   {
   
      private static final Log log = LogFactory.getLog(CacheLoaderTestsBase.class);
  -   TreeCache cache;
  +   CacheImpl cache;
      CacheLoader loader = null;
      private Transaction tx = null;
      static final Fqn FQN = new Fqn("key");
  @@ -62,7 +62,7 @@
      {
         super.setUp();
         log.debug("\nTest " + getName() + "\n");
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
         c.setCacheMode(Configuration.CacheMode.LOCAL);
  @@ -329,7 +329,7 @@
   
         assertNotNull("Should not be null", retval);
   
  -      DataNode node = (DataNode) retval;
  +      Node node = (Node) retval;
         assertEquals(10, node.get("1"));
      }
   
  @@ -544,7 +544,7 @@
            cache.put("/a/3", null);
            System.out.println("cache is " + cache.printLockInfo());
   
  -         DataNode n = cache.get("/a");
  +         Node n = cache.get("/a");
            assertNotNull(n);
   
            Set children = cache.getChildrenNames("/a");
  
  
  
  1.9       +4 -4      JBossCache/tests/functional/org/jboss/cache/loader/RpcDelegatingCacheLoaderTests.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RpcDelegatingCacheLoaderTests.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/RpcDelegatingCacheLoaderTests.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- RpcDelegatingCacheLoaderTests.java	25 Oct 2006 04:50:19 -0000	1.8
  +++ RpcDelegatingCacheLoaderTests.java	30 Dec 2006 17:49:57 -0000	1.9
  @@ -1,7 +1,7 @@
   package org.jboss.cache.loader;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -11,11 +11,11 @@
   
   /**
    * @author Bela Ban
  - * @version $Id: RpcDelegatingCacheLoaderTests.java,v 1.8 2006/10/25 04:50:19 bstansberry Exp $
  + * @version $Id: RpcDelegatingCacheLoaderTests.java,v 1.9 2006/12/30 17:49:57 msurtani Exp $
    */
   public class RpcDelegatingCacheLoaderTests
   {
  -   TreeCache cache;
  +   CacheImpl cache;
   
   
      public static void main(String[] args)
  @@ -56,7 +56,7 @@
   
      private void start(boolean client) throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setClusterName("test-cluster");
         cache.getConfiguration().setInitialStateRetrievalTimeout(3000);
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_ASYNC);
  
  
  
  1.7       +5 -5      JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderPurgingTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderPurgingTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/CacheLoaderPurgingTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- CacheLoaderPurgingTest.java	25 Oct 2006 04:50:19 -0000	1.6
  +++ CacheLoaderPurgingTest.java	30 Dec 2006 17:49:57 -0000	1.7
  @@ -7,8 +7,8 @@
   package org.jboss.cache.loader;
   
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.xml.XmlHelper;
  @@ -19,7 +19,7 @@
    */
   public class CacheLoaderPurgingTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private String key = "key", value = "value";
      private Fqn fqn = Fqn.fromString("/a/b/c");
   
  @@ -35,7 +35,7 @@
   
      public void testSingleLoaderNoPurge() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
         c.setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader", "location=" + System.getProperty("java.io.tmpdir", "/tmp") + "/" + "CacheLoaderPurgingTest", false, false, false));
  @@ -59,7 +59,7 @@
   
      public void testSingleLoaderPurge() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         Configuration c = new Configuration();
         cache.setConfiguration(c);
         c.setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader", "location=" + System.getProperty("java.io.tmpdir", "/tmp") + "/" + "CacheLoaderPurgingTest", false, false, false, true));
  @@ -86,7 +86,7 @@
   
      public void testTwoLoadersPurge() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
   
         String xml = "<config>\n" +
                 "<passivation>false</passivation>\n" +
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1H0iLG-0008Q5-8C@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    tests/functional/org/jboss/cache/eviction              
                        LFUAlgorithmTest.java
                        EvictionConfigurationTest.java
                        ProgrammaticLRUPolicyTest.java
                        ElementSizePolicyTest.java FIFOPolicyTest.java
                        ExpirationPolicyTest.java
                        ConcurrentEvictionTest.java RegionManagerTest.java
                        LFUPolicyTest.java LRUPolicyTest.java
                        ReplicatedLRUPolicyTest.java
                        OptimisticEvictionTest.java MRUPolicyTest.java
                        DummyEvictionPolicy.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.7       +3 -7      JBossCache/tests/functional/org/jboss/cache/eviction/LFUAlgorithmTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LFUAlgorithmTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/LFUAlgorithmTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- LFUAlgorithmTest.java	15 Nov 2006 15:16:39 -0000	1.6
  +++ LFUAlgorithmTest.java	30 Dec 2006 17:49:58 -0000	1.7
  @@ -9,10 +9,10 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.TreeCache;
   
   import java.util.Iterator;
   
  @@ -20,7 +20,7 @@
    * Unit test for LFUAlgorithm.
    *
    * @author Daniel Huang - dhuang at jboss.org - 10/2005
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class LFUAlgorithmTest extends TestCase
   {
  @@ -39,7 +39,7 @@
   
         algo = new LFUAlgorithm();
         LFUConfiguration config = new LFUConfiguration();
  -      regionManager = new RegionManager(new TreeCache());
  +      regionManager = new RegionManager(new CacheImpl());
         config.setEvictionPolicyClass(DummyEvictionPolicy.class.getName());
         regionManager.getRegion("/a/b", true).setEvictionPolicy(config);
         // doesn't this need a cache?!?? :-/
  @@ -242,7 +242,6 @@
         // fqn3 visited 1 additional time.
         region.putNodeEvent(new EvictedEventNode(fqn3, NodeEventType.VISIT_NODE_EVENT));
   
  -
         // fqn4 visited 2 additional times.
         region.putNodeEvent(new EvictedEventNode(fqn4, NodeEventType.VISIT_NODE_EVENT));
         region.putNodeEvent(new EvictedEventNode(fqn4, NodeEventType.VISIT_NODE_EVENT));
  @@ -250,7 +249,6 @@
         // fqn9 visited 1 additional time.
         region.putNodeEvent(new EvictedEventNode(fqn9, NodeEventType.VISIT_NODE_EVENT));
   
  -
         // fqn10 visited 2 additional times.
         region.putNodeEvent(new EvictedEventNode(fqn10, NodeEventType.VISIT_NODE_EVENT));
         region.putNodeEvent(new EvictedEventNode(fqn10, NodeEventType.VISIT_NODE_EVENT));
  @@ -377,8 +375,6 @@
         region.putNodeEvent(new EvictedEventNode(fqn11, NodeEventType.VISIT_NODE_EVENT));
         region.putNodeEvent(new EvictedEventNode(fqn4, NodeEventType.VISIT_NODE_EVENT));
   
  -
  -
         // purposefully revisit a node that has been removed. assert that it is readded.
         region.putNodeEvent(new EvictedEventNode(fqn1, NodeEventType.VISIT_NODE_EVENT));
         region.putNodeEvent(new EvictedEventNode(fqn1, NodeEventType.VISIT_NODE_EVENT));
  
  
  
  1.12      +6 -6      JBossCache/tests/functional/org/jboss/cache/eviction/EvictionConfigurationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionConfigurationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/EvictionConfigurationTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- EvictionConfigurationTest.java	15 Nov 2006 15:16:39 -0000	1.11
  +++ EvictionConfigurationTest.java	30 Dec 2006 17:49:58 -0000	1.12
  @@ -7,10 +7,10 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
  @@ -19,11 +19,11 @@
    * Unit test to test Eviction configuration types.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class EvictionConfigurationTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      RegionManager regionManager;
   
      public void setUp() throws Exception
  @@ -195,7 +195,7 @@
      public void testTwoCacheInstanceConfiguration() throws Exception
      {
         this.setupCache("META-INF/local-lru-eviction-service.xml");
  -      TreeCache cache1 = cache;
  +      CacheImpl cache1 = cache;
         this.setupCache("META-INF/local-lru-eviction-service.xml");
      }
   
  @@ -207,7 +207,7 @@
   
      private void setupCache(String configurationName) throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         XmlConfigurationParser parser = new XmlConfigurationParser();
         Configuration c = parser.parseFile(configurationName);
         c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  
  1.8       +20 -20    JBossCache/tests/functional/org/jboss/cache/eviction/ProgrammaticLRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProgrammaticLRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ProgrammaticLRUPolicyTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ProgrammaticLRUPolicyTest.java	15 Nov 2006 15:48:25 -0000	1.7
  +++ ProgrammaticLRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.8
  @@ -22,29 +22,29 @@
   
   package org.jboss.cache.eviction;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.xml.XmlHelper;
  -import org.jboss.cache.misc.TestingUtil;
  -import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.config.EvictionConfig;
   import org.jboss.cache.config.EvictionRegionConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
  +import org.jboss.cache.lock.IsolationLevel;
  +import org.jboss.cache.misc.TestingUtil;
  +import org.jboss.cache.xml.XmlHelper;
   import org.w3c.dom.Element;
   
   /**
    * Unit tests for programmatic configuration of LRU policy
    *
    * @author Ben Wang, Oct, 2006
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   public class ProgrammaticLRUPolicyTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      int wakeupIntervalMillis_ = 0;
   
      public ProgrammaticLRUPolicyTest(String s)
  @@ -65,7 +65,7 @@
   
      public void initCaches() throws Exception
      {
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-lru-eviction-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  @@ -112,7 +112,7 @@
         assertNotNull("DataNode should be empty ", val);
   
         System.out.println(cache_.toString());
  -      TestingUtil.sleepThread(2*wakeupIntervalMillis_ + 500);
  +      TestingUtil.sleepThread(2 * wakeupIntervalMillis_ + 500);
         System.out.println(cache_.toString());
         val = (String) cache_.get(rootStr + "3", rootStr + "3");
         assertNull("DataNode should be empty ", val);
  @@ -172,7 +172,7 @@
         }
   
         System.out.println(cache_.toString());
  -      TestingUtil.sleepThread(2*wakeupIntervalMillis_ + 500);
  +      TestingUtil.sleepThread(2 * wakeupIntervalMillis_ + 500);
         System.out.println(cache_.toString());
   
         try
  @@ -222,7 +222,7 @@
         }
   
         System.out.println(cache_.toString());
  -      TestingUtil.sleepThread(2*wakeupIntervalMillis_ + 500);
  +      TestingUtil.sleepThread(2 * wakeupIntervalMillis_ + 500);
         System.out.println(cache_.toString());
         try
         {
  
  
  
  1.10      +7 -7      JBossCache/tests/functional/org/jboss/cache/eviction/ElementSizePolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ElementSizePolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ElementSizePolicyTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- ElementSizePolicyTest.java	20 Nov 2006 03:53:56 -0000	1.9
  +++ ElementSizePolicyTest.java	30 Dec 2006 17:49:58 -0000	1.10
  @@ -7,9 +7,9 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
   
  @@ -19,7 +19,7 @@
    */
   public class ElementSizePolicyTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      int wakeupIntervalMillis = 0;
      final String ROOT_STR = "/test";
      Throwable t1_ex, t2_ex;
  @@ -46,7 +46,7 @@
   
      void initCaches() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-elementsize-eviction-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  @@ -90,7 +90,7 @@
   
         for (int i = 0; i < 10; i++)
         {
  -         DataNode node = cache.get("/org/jboss/test/data/" + Integer.toString(i));
  +         Node node = cache.get("/org/jboss/test/data/" + Integer.toString(i));
            System.out.println(node);
            if (i % 2 == 0)
            {
  @@ -136,7 +136,7 @@
         {
            String str = rootStr + Integer.toString(i);
            Fqn fqn = Fqn.fromString(str);
  -         DataNode node = cache.get(fqn);
  +         Node node = cache.get(fqn);
            System.out.println(i + " " + node);
            if (i > 9)
            {
  @@ -153,7 +153,7 @@
            cache.put("/org/jboss/data/" + Integer.toString(3), new Integer(100 + i), "value");
         }
   
  -      DataNode node = cache.get("/org/jboss/data/" + Integer.toString(3));
  +      Node node = cache.get("/org/jboss/data/" + Integer.toString(3));
         assertEquals(21, node.getData().size());
         _sleep(wakeupIntervalMillis + 500);
   
  
  
  
  1.11      +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/FIFOPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FIFOPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/FIFOPolicyTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- FIFOPolicyTest.java	20 Nov 2006 03:53:56 -0000	1.10
  +++ FIFOPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.11
  @@ -7,8 +7,8 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.misc.TestingUtil;
  @@ -17,11 +17,11 @@
    * Unit tests for FIFOPolicy.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public class FIFOPolicyTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      int wakeupIntervalMillis = 0;
      final String ROOT_STR = "/test";
      Throwable t1_ex, t2_ex;
  @@ -48,7 +48,7 @@
   
      void initCaches() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-fifo-eviction-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  
  
  
  1.4       +4 -5      JBossCache/tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ExpirationPolicyTest.java	8 Dec 2006 19:19:05 -0000	1.3
  +++ ExpirationPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.4
  @@ -7,11 +7,10 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.EvictionConfig;
   import org.jboss.cache.misc.TestingUtil;
  @@ -20,13 +19,13 @@
    * Unit tests for {@link ExpirationPolicy}.
    *
    * @author Elias Ross
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    */
   public class ExpirationPolicyTest extends TestCase
   {
      private static final Log log = LogFactory.getLog(ExpirationPolicyTest.class);
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      Fqn fqn1 = Fqn.fromString("/node/1");
      Fqn fqn2 = Fqn.fromString("/node/2");
  @@ -39,7 +38,7 @@
      public void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         Configuration conf = new Configuration();
         EvictionConfig econf = new EvictionConfig(ExpirationPolicy.class.getName());
         econf.setWakeupIntervalSeconds(1);
  
  
  
  1.6       +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentEvictionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ConcurrentEvictionTest.java	20 Dec 2006 13:34:28 -0000	1.5
  +++ ConcurrentEvictionTest.java	30 Dec 2006 17:49:58 -0000	1.6
  @@ -10,8 +10,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -19,11 +19,11 @@
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class ConcurrentEvictionTest extends TestCase
   {
  -   private TreeCache cache_;
  +   private CacheImpl cache_;
      private int wakeupIntervalMillis_ = 0;
   
      public ConcurrentEvictionTest(String s)
  @@ -44,7 +44,7 @@
      void initCaches() throws Exception
      {
         TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader");
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-eviction-cacheloader-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.start();
  
  
  
  1.18      +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/RegionManagerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RegionManagerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/RegionManagerTest.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- RegionManagerTest.java	15 Nov 2006 15:16:39 -0000	1.17
  +++ RegionManagerTest.java	30 Dec 2006 17:49:58 -0000	1.18
  @@ -1,10 +1,10 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.EvictionConfig;
   import org.jboss.cache.config.EvictionRegionConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -18,7 +18,7 @@
    *
    * @author Ben Wang, Feb 11, 2004
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class RegionManagerTest extends TestCase
   {
  @@ -140,7 +140,7 @@
         assertEquals(10, config.getMinNodes());
         assertEquals(Fqn.fromString("/test/"), region.getFqn());
   
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         
         // test the 1.2.x style configuration
         xml = "<region name=\"abc\">" +
  
  
  
  1.9       +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/LFUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LFUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/LFUPolicyTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- LFUPolicyTest.java	16 Nov 2006 18:41:25 -0000	1.8
  +++ LFUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.9
  @@ -7,8 +7,8 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
  @@ -18,11 +18,11 @@
    * Unit tests for LFU Policy.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.8 $
  + * @version $Revision: 1.9 $
    */
   public class LFUPolicyTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      int wakeupIntervalMillis = 0;
      final String ROOT_STR = "/test";
      Throwable t1_ex, t2_ex;
  @@ -49,7 +49,7 @@
   
      void initCaches() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         XmlConfigurationParser parser = new XmlConfigurationParser();
         Configuration c = parser.parseFile("META-INF/local-lfu-eviction-service.xml");
         cache.setConfiguration(c);
  
  
  
  1.20      +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/LRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/LRUPolicyTest.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- LRUPolicyTest.java	16 Nov 2006 18:15:27 -0000	1.19
  +++ LRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.20
  @@ -3,8 +3,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.misc.TestingUtil;
  @@ -14,11 +14,11 @@
    *
    * @author Ben Wang, Feb 11, 2004
    * @author Daniel Huang - dhuang at jboss.org
  - * @version $Revision: 1.19 $
  + * @version $Revision: 1.20 $
    */
   public class LRUPolicyTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      int wakeupIntervalMillis_ = 0;
      final String ROOT_STR = "/test";
      Throwable t1_ex, t2_ex;
  @@ -45,7 +45,7 @@
   
      public void initCaches() throws Exception
      {
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-lru-eviction-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  
  
  
  1.15      +5 -5      JBossCache/tests/functional/org/jboss/cache/eviction/ReplicatedLRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedLRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ReplicatedLRUPolicyTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- ReplicatedLRUPolicyTest.java	14 Nov 2006 14:17:10 -0000	1.14
  +++ ReplicatedLRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.15
  @@ -2,8 +2,8 @@
   
   import junit.framework.TestCase;
   import org.jboss.cache.AbstractCacheListener;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -12,7 +12,7 @@
    */
   public class ReplicatedLRUPolicyTest extends TestCase
   {
  -   TreeCache cache_, cache1_, cache2_;
  +   CacheImpl cache_, cache1_, cache2_;
      int wakeupIntervalMillis_ = 0;
      EvictionListener listener_;
   
  @@ -25,14 +25,14 @@
      public void setUp() throws Exception
      {
         super.setUp();
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         initCaches(cache_);
         cache_.getConfiguration().setUseRegionBasedMarshalling(true);
         cache_.start();
         cache_.getNotifier().addCacheListener(listener_);
         listener_.resetCounter();
   
  -      cache2_ = new TreeCache();
  +      cache2_ = new CacheImpl();
         cache2_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml")); // read in generic local xml
         cache2_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache2_.getConfiguration().setUseRegionBasedMarshalling(true);
  @@ -46,7 +46,7 @@
         }
      }
   
  -   void initCaches(TreeCache cache) throws Exception
  +   void initCaches(CacheImpl cache) throws Exception
      {
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-eviction-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  
  1.9       +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/OptimisticEvictionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticEvictionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/OptimisticEvictionTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- OptimisticEvictionTest.java	6 Sep 2006 15:30:57 -0000	1.8
  +++ OptimisticEvictionTest.java	30 Dec 2006 17:49:58 -0000	1.9
  @@ -1,9 +1,9 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.DummyTransactionManagerLookup;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.interceptors.EvictionInterceptor;
   import org.jboss.cache.misc.TestingUtil;
  @@ -30,14 +30,14 @@
   
      private Fqn region = Fqn.fromString("testingRegion");
      private TransactionManager txManager;
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      protected void setUp() throws Exception
      {
         super.setUp();
   
         txManager = new DummyTransactionManagerLookup().getTransactionManager();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/optimistic-eviction.xml"));
         cache.start();
      }
  
  
  
  1.11      +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/MRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/MRUPolicyTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- MRUPolicyTest.java	16 Nov 2006 18:41:25 -0000	1.10
  +++ MRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.11
  @@ -7,7 +7,7 @@
   package org.jboss.cache.eviction;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.misc.TestingUtil;
  @@ -16,11 +16,11 @@
    * Unit tests for MRUPolicy.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public class MRUPolicyTest extends TestCase
   {
  -   TreeCache cache;
  +   CacheImpl cache;
      int wakeupIntervalMillis = 0;
      final String ROOT_STR = "/test";
      Throwable t1_ex, t2_ex;
  @@ -49,7 +49,7 @@
   
      private void initCaches() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         XmlConfigurationParser parser = new XmlConfigurationParser();
         cache.setConfiguration(parser.parseFile("META-INF/local-mru-eviction-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  
  1.3       +2 -2      JBossCache/tests/functional/org/jboss/cache/eviction/DummyEvictionPolicy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DummyEvictionPolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/DummyEvictionPolicy.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- DummyEvictionPolicy.java	5 Dec 2005 03:17:14 -0000	1.2
  +++ DummyEvictionPolicy.java	30 Dec 2006 17:49:58 -0000	1.3
  @@ -1,7 +1,7 @@
   package org.jboss.cache.eviction;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   /**
    * @author Ben Feb 13, 2004
  @@ -19,7 +19,7 @@
         return 0;  //To change body of implemented methods use File | Settings | File Templates.
      }
   
  -   public void configure(TreeCache cache)
  +   public void configure(CacheImpl cache)
      {
         // no op
      }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache/optimistic  ...
Message-ID: <E1H0iLG-0008QC-BU@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    tests/stress/org/jboss/cache/optimistic 
                        OptimisticDeadlockTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +4 -4      JBossCache/tests/stress/org/jboss/cache/optimistic/OptimisticDeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticDeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/optimistic/OptimisticDeadlockTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- OptimisticDeadlockTest.java	6 Sep 2006 15:31:02 -0000	1.5
  +++ OptimisticDeadlockTest.java	30 Dec 2006 17:49:58 -0000	1.6
  @@ -7,8 +7,8 @@
   package org.jboss.cache.optimistic;
   
   import EDU.oswego.cs.dl.util.concurrent.Latch;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import javax.transaction.TransactionManager;
   import java.util.ArrayList;
  @@ -31,7 +31,7 @@
   
      public void testConcurrentReadsLocal() throws Exception
      {
  -      TreeCache cache = createCacheUnstarted();
  +      CacheImpl cache = createCacheUnstarted();
         cache.getConfiguration().setCacheMode("INVALIDATION_ASYNC");
         cache.start();
   
  @@ -57,10 +57,10 @@
   
      public static class Processor extends Thread
      {
  -      private TreeCache cache;
  +      private CacheImpl cache;
         List exceptions = new ArrayList();
   
  -      public Processor(TreeCache cache, String name)
  +      public Processor(CacheImpl cache, String name)
         {
            super(name);
            this.cache = cache;
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/lock  ...
Message-ID: <E1H0iLG-0008QJ-Fx@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    src/org/jboss/cache/lock  LockUtil.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +4 -4      JBossCache/src/org/jboss/cache/lock/LockUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/LockUtil.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- LockUtil.java	8 Dec 2006 18:50:49 -0000	1.5
  +++ LockUtil.java	30 Dec 2006 17:49:58 -0000	1.6
  @@ -2,10 +2,10 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Node;
   import org.jboss.cache.TransactionTable;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.statetransfer.StateTransferManager;
   
   import javax.transaction.Status;
  @@ -25,7 +25,7 @@
      public static boolean breakTransactionLock(NodeLock lock,
                                                 GlobalTransaction gtx,
                                                 boolean localTx,
  -                                              TreeCache cache)
  +                                              CacheImpl cache)
      {
         TransactionTable tx_table = cache.getTransactionTable();
         TransactionManager tm = cache.getTransactionManager();
  @@ -62,7 +62,7 @@
       */
      public static void forceAcquireLock(Node node,
                                          Object newOwner,
  -                                       TreeCache cache,
  +                                       CacheImpl cache,
                                          boolean lockChildren)
      {
   
  @@ -123,7 +123,7 @@
         // Recursively unlock children
         if (lockChildren)
         {
  -         for (Node n: node.getChildren())
  +         for (Node n : node.getChildren())
            {
               forceAcquireLock(n, newOwner, cache, true);
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/lock     ...
Message-ID: <E1H0iLG-0008QZ-Ki@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    tests/functional/org/jboss/cache/lock    
                        UpgradeLockTest.java BreakDeadMemberLocksTest.java
                        AcquireAllTest.java LockReleaseTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +5 -5      JBossCache/tests/functional/org/jboss/cache/lock/UpgradeLockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UpgradeLockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/UpgradeLockTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- UpgradeLockTest.java	18 Dec 2006 12:54:23 -0000	1.5
  +++ UpgradeLockTest.java	30 Dec 2006 17:49:58 -0000	1.6
  @@ -12,7 +12,7 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
  @@ -24,11 +24,11 @@
    * Tests upgrade locks from read -> write
    *
    * @author Bela Ban
  - * @version $Id: UpgradeLockTest.java,v 1.5 2006/12/18 12:54:23 msurtani Exp $
  + * @version $Id: UpgradeLockTest.java,v 1.6 2006/12/30 17:49:58 msurtani Exp $
    */
   public class UpgradeLockTest extends TestCase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      UserTransaction tx = null;
      Log log;
      Properties p = null;
  @@ -87,9 +87,9 @@
         }
      }
   
  -   TreeCache createCache(IsolationLevel level) throws Exception
  +   CacheImpl createCache(IsolationLevel level) throws Exception
      {
  -      TreeCache c = new TreeCache();
  +      CacheImpl c = new CacheImpl();
         c.getConfiguration().setClusterName("test");
         c.getConfiguration().setInitialStateRetrievalTimeout(10000);
         c.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.JBossTransactionManagerLookup");
  
  
  
  1.4       +12 -12    JBossCache/tests/functional/org/jboss/cache/lock/BreakDeadMemberLocksTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BreakDeadMemberLocksTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/BreakDeadMemberLocksTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- BreakDeadMemberLocksTest.java	6 Sep 2006 15:30:58 -0000	1.3
  +++ BreakDeadMemberLocksTest.java	30 Dec 2006 17:49:58 -0000	1.4
  @@ -23,7 +23,7 @@
   package org.jboss.cache.lock;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -54,7 +54,7 @@
   
      public void testBreakDeadMemberLocks() throws Exception
      {
  -      TreeCache cacheA = createCache("A");
  +      CacheImpl cacheA = createCache("A");
   
         cacheA.put("/1/A", "1", "A");
         cacheA.put("/1/A", "2", "A");
  @@ -63,10 +63,10 @@
         cacheA.put("/1/A/I", "1", "A");
         cacheA.put("/1/A/I", "2", "A");
   
  -      TreeCache cacheB = createCache("B");
  +      CacheImpl cacheB = createCache("B");
   
         // Pause to give caches time to see each other
  -      TestingUtil.blockUntilViewsReceived(new TreeCache[]{cacheA, cacheB}, 60000);
  +      TestingUtil.blockUntilViewsReceived(new CacheImpl[]{cacheA, cacheB}, 60000);
   
         final TransactionManager tm = cacheB.getTransactionManager();
         tm.begin();
  @@ -135,20 +135,20 @@
         }
      }
   
  -   protected TreeCache createCache(String cacheID) throws Exception
  +   protected CacheImpl createCache(String cacheID) throws Exception
      {
         if (caches.get(cacheID) != null)
            throw new IllegalStateException(cacheID + " already created");
   
  -      TreeCache tree = new TreeCache();
  -      tree.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
  +      CacheImpl cache = new CacheImpl();
  +      cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
   
  -      tree.create();
  -      tree.start();
  +      cache.create();
  +      cache.start();
   
  -      caches.put(cacheID, tree);
  +      caches.put(cacheID, cache);
   
  -      return tree;
  +      return cache;
      }
   
      protected void tearDown() throws Exception
  @@ -166,7 +166,7 @@
   
      protected void stopCache(String id)
      {
  -      TreeCache cache = (TreeCache) caches.get(id);
  +      CacheImpl cache = (CacheImpl) caches.get(id);
         if (cache != null)
         {
            try
  
  
  
  1.8       +10 -11    JBossCache/tests/functional/org/jboss/cache/lock/AcquireAllTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AcquireAllTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/AcquireAllTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- AcquireAllTest.java	20 Nov 2006 03:53:56 -0000	1.7
  +++ AcquireAllTest.java	30 Dec 2006 17:49:58 -0000	1.8
  @@ -3,11 +3,10 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.NodeImpl;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
  @@ -15,11 +14,11 @@
   
   /**
    * @author Bela Ban
  - * @version $Id: AcquireAllTest.java,v 1.7 2006/11/20 03:53:56 genman Exp $
  + * @version $Id: AcquireAllTest.java,v 1.8 2006/12/30 17:49:58 msurtani Exp $
    */
   public class AcquireAllTest extends TestCase
   {
  -   TreeCache cache = null, cache2;
  +   CacheImpl cache = null, cache2;
      Transaction tx = null;
      final Fqn FQN = Fqn.fromString("/myNode");
      final String KEY = "key";
  @@ -50,15 +49,15 @@
   
      public void testAcquireAll() throws Exception
      {
  -      NodeImpl root;
  +      NodeSPI root;
         Object owner = Thread.currentThread();
   
         cache = createCache(Configuration.CacheMode.LOCAL, IsolationLevel.SERIALIZABLE);
         cache.put("/a/b/c", null);
         cache.put("/1/2/3", null);
   
  -      root = (NodeImpl)cache.getRoot();
  -      NodeLock lock = root.getNodeSPI().getLock();
  +      root = cache.getRoot().getNodeSPI();
  +      NodeLock lock = root.getLock();
   
         lock.acquireAll(owner, 2000, NodeLock.LockType.READ);
         lock.releaseAll(owner);
  @@ -74,7 +73,7 @@
   
      public void testAcquireAllReplicated() throws Exception
      {
  -      DataNode root;
  +      Node root;
         Object owner = Thread.currentThread();
   
         cache2 = createCache(Configuration.CacheMode.REPL_ASYNC, IsolationLevel.SERIALIZABLE);
  @@ -97,9 +96,9 @@
      }
   
   
  -   TreeCache createCache(Configuration.CacheMode mode, IsolationLevel level) throws Exception
  +   CacheImpl createCache(Configuration.CacheMode mode, IsolationLevel level) throws Exception
      {
  -      TreeCache c = new TreeCache();
  +      CacheImpl c = new CacheImpl();
         c.getConfiguration().setCacheMode(mode);
         c.getConfiguration().setIsolationLevel(level);
         c.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  
  1.6       +5 -5      JBossCache/tests/functional/org/jboss/cache/lock/LockReleaseTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LockReleaseTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/lock/LockReleaseTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- LockReleaseTest.java	18 Dec 2006 12:54:23 -0000	1.5
  +++ LockReleaseTest.java	30 Dec 2006 17:49:58 -0000	1.6
  @@ -12,8 +12,8 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
  @@ -26,11 +26,11 @@
    * Verifies that there are no read locks held when a transaction ends.
    *
    * @author Bela Ban
  - * @version $Id: LockReleaseTest.java,v 1.5 2006/12/18 12:54:23 msurtani Exp $
  + * @version $Id: LockReleaseTest.java,v 1.6 2006/12/30 17:49:58 msurtani Exp $
    */
   public class LockReleaseTest extends TestCase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
      UserTransaction tx = null;
      Log log;
      Properties p = null;
  @@ -89,9 +89,9 @@
         }
      }
   
  -   TreeCache createCache(IsolationLevel level) throws Exception
  +   CacheImpl createCache(IsolationLevel level) throws Exception
      {
  -      TreeCache c = new TreeCache();
  +      CacheImpl c = new CacheImpl();
         c.getConfiguration().setClusterName("test");
         c.getConfiguration().setInitialStateRetrievalTimeout(10000);
         c.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.JBossTransactionManagerLookup");
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/examples/PojoCache/passivation  ...
Message-ID: <E1H0iLG-0008Qg-OA@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    examples/PojoCache/passivation  build.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.2       +2 -2      JBossCache/examples/PojoCache/passivation/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/examples/PojoCache/passivation/build.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- build.xml	7 Nov 2006 04:26:51 -0000	1.1
  +++ build.xml	30 Dec 2006 17:49:58 -0000	1.2
  @@ -92,7 +92,7 @@
         </java>
      </target>
   
  -   <target name="run.aop.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.aop.demo" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.aop.TreeCacheView" fork="yes">
            <jvmarg value="-Xmx128M"/>
            <classpath refid="lib.classpath"/>
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:58 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:58 -0500
Subject: [jboss-cvs] JBossCache/tests-50/functional/org/jboss/cache/pojo ...
Message-ID: <E1H0iLG-0008Qw-Sz@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:58

  Modified:    tests-50/functional/org/jboss/cache/pojo    
                        TestingUtil.java CircularGraphTest.java
                        NewLocalTest.java NewReplicatedTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.4       +8 -8      JBossCache/tests-50/functional/org/jboss/cache/pojo/TestingUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestingUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/TestingUtil.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- TestingUtil.java	9 Oct 2006 08:14:51 -0000	1.3
  +++ TestingUtil.java	30 Dec 2006 17:49:58 -0000	1.4
  @@ -7,8 +7,7 @@
   
   package org.jboss.cache.pojo;
   
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheProxyImpl;
  +import org.jboss.cache.CacheImpl;
   
   import java.util.Vector;
   
  @@ -16,7 +15,7 @@
    * Utilities for unit testing JBossCache.
    *
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    */
   public class TestingUtil
   {
  @@ -47,7 +46,7 @@
      {
         long failTime = System.currentTimeMillis() + timeout;
   
  -      TreeCache tcache = ((TreeCacheProxyImpl)cache.getCache()).getTreeCache();
  +      CacheImpl tcache = (CacheImpl) cache.getCache();
         while (System.currentTimeMillis() < failTime)
         {
            org.jboss.cache.pojo.TestingUtil.sleepThread(100);
  @@ -60,7 +59,7 @@
   
      /**
       * Checks each cache to see if the number of elements in the array
  -    * returned by {@link org.jboss.cache.TreeCache#getMembers()} matches the size of
  +    * returned by {@link org.jboss.cache.CacheImpl#getMembers()} matches the size of
       * the <code>caches</code> parameter.
       *
       * @param caches caches that should form a View
  @@ -75,7 +74,7 @@
   
         for (int i = 0; i < memberCount; i++)
         {
  -         TreeCache cache = ((TreeCacheProxyImpl)caches[i].getCache()).getTreeCache();
  +         CacheImpl cache = (CacheImpl) caches[i].getCache();
            return org.jboss.cache.pojo.TestingUtil.isCacheViewComplete(cache, memberCount);
         }
   
  @@ -88,13 +87,14 @@
       * @param cache
       * @param memberCount
       */
  -   public static boolean isCacheViewComplete(TreeCache cache, int memberCount)
  +   public static boolean isCacheViewComplete(CacheImpl cache, int memberCount)
      {
         Vector members = cache.getMembers();
         if (members == null || memberCount > members.size())
         {
            return false;
  -      } else if (memberCount < members.size())
  +      }
  +      else if (memberCount < members.size())
         {
            // This is an exceptional condition
            StringBuffer sb = new StringBuffer("Cache at address ");
  
  
  
  1.5       +12 -12    JBossCache/tests-50/functional/org/jboss/cache/pojo/CircularGraphTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CircularGraphTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/CircularGraphTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- CircularGraphTest.java	31 Oct 2006 11:07:17 -0000	1.4
  +++ CircularGraphTest.java	30 Dec 2006 17:49:58 -0000	1.5
  @@ -7,18 +7,19 @@
   
   package org.jboss.cache.pojo;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.pojo.test.Person;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.Node;
   import org.jboss.cache.pojo.test.Link;
   import org.jboss.cache.pojo.test.NodeManager;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.pojo.test.Person;
   
  -import java.util.List;
   import java.util.ArrayList;
  +import java.util.List;
   
   /**
    * Test object graph handling in PojoCache, e.g., circular reference, multiple reference, link, etc.
  @@ -116,8 +117,8 @@
         Link link = (Link) cache_.detach("/link/parent");
         cache_.detach("/link/child");
         assertEquals("child", link.getLink().getName());
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/link/parent")));
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/link/child")));
  +      assertNull("Cache should be null ", (cache_.getCache().getRoot().getChild(Fqn.fromString("/link/parent"))));
  +      assertNull("Cache should be null ", (cache_.getCache().getRoot().getChild(Fqn.fromString("/link/child"))));
      }
   
      /**
  @@ -139,8 +140,8 @@
         cache_.detach("/link/child");
         Link link = (Link) cache_.detach("/link/parent");
         assertEquals("child", link.getLink().getName());
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/link/parent")));
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/link/child")));
  +      assertNull("Cache should be null ", (cache_.getCache().getRoot().getChild(Fqn.fromString("/link/parent"))));
  +      assertNull("Cache should be null ", (cache_.getCache().getRoot().getChild(Fqn.fromString("/link/child"))));
      }
   
      /**
  @@ -161,7 +162,7 @@
         assertEquals("child", ((Link) cache_.find("/link/parent")).getLink().getName());
         Link link = (Link) cache_.detach("/link/parent");
         assertEquals("child", link.getLink().getName());
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/parent")));
  +      assertNull("Cache should be null ", ((Node) cache_.getCache().getRoot().getChild(Fqn.fromString("/parent"))));
      }
   
      /**
  @@ -184,7 +185,7 @@
         assertEquals("parent", ((Link) cache_.find("/link/child")).getLink().getName());
         Link link = (Link) cache_.detach("/link/parent");
         assertEquals("child", link.getLink().getName());
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/parent")));
  +      assertNull("Cache should be null ", ((Node) cache_.getCache().getRoot().getChild(Fqn.fromString("/parent"))));
      }
   
      /**
  @@ -207,7 +208,7 @@
         assertEquals("parent", ((Link) cache_.find("/link/child")).getLink().getName());
         Link link = (Link) cache_.detach("/link/parent");
         assertEquals("child", link.getLink().getName());
  -      assertNull("Cache should be null ", ((DataNode) cache_.getCache().get("/parent")));
  +      assertNull("Cache should be null ", (cache_.getCache().getRoot().getChild(Fqn.fromString("/parent"))));
   
         // re-attach
         cache_.attach("/link/parent", parent);
  @@ -240,7 +241,6 @@
      }
   
      /**
  -    *
       * @throws Exception
       */
      public void testCircularReference8() throws Exception
  
  
  
  1.12      +16 -14    JBossCache/tests-50/functional/org/jboss/cache/pojo/NewLocalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewLocalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/NewLocalTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- NewLocalTest.java	16 Nov 2006 06:45:55 -0000	1.11
  +++ NewLocalTest.java	30 Dec 2006 17:49:58 -0000	1.12
  @@ -5,14 +5,14 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.pojo.test.Person;
  -import org.jboss.cache.pojo.InternalConstant;
   import org.jboss.aop.proxy.ClassProxy;
  +import org.jboss.cache.Fqn;
  +import org.jboss.cache.pojo.test.Person;
   
  -import java.util.Map;
  -import java.util.HashSet;
  -import java.util.HashMap;
   import java.util.ArrayList;
  +import java.util.HashMap;
  +import java.util.HashSet;
  +import java.util.Map;
   
   /**
    * Additional basic tests
  @@ -63,7 +63,8 @@
         {
            cache_.attach(InternalConstant.JBOSS_INTERNAL_STRING, test);
            fail("putObject under JBoss_Internal should fail");
  -      } catch (IllegalArgumentException iex)
  +      }
  +      catch (IllegalArgumentException iex)
         {
            // ok
         }
  @@ -72,7 +73,8 @@
         {
            cache_.detach(InternalConstant.JBOSS_INTERNAL_STRING);
            fail("putObject under JBoss_Internal should fail");
  -      } catch (IllegalArgumentException iex)
  +      }
  +      catch (IllegalArgumentException iex)
         {
            // ok
         }
  @@ -107,7 +109,7 @@
         assertNull("Object should be null ", cache_.find("person"));
         assertEquals("Age should be updated as ", 20, test.getAge());
   
  -      assertNull("DataNode should not exisit ", cache_.getCache().get("person"));
  +      assertNull("DataNode should not exisit ", cache_.getCache().getRoot().getChild(Fqn.fromString("person")));
      }
   
      public void testRemoveProxyList() throws Exception
  @@ -121,12 +123,12 @@
         list.add("Taiwanese");
         test.setLanguages(list);
         cache_.attach("/a", test);
  -      Person result = (Person)cache_.find("/a");
  +      Person result = (Person) cache_.find("/a");
         assertEquals(" ", test, result);
   
         assertTrue("Instance of proxyclass ", result.getLanguages() instanceof ClassProxy);
   
  -      Person r1 = (Person)cache_.detach("/a");
  +      Person r1 = (Person) cache_.detach("/a");
   
         assertEquals("Same instance ", result, r1);
         assertFalse("Instance of proxyclass ", result.getLanguages() instanceof ClassProxy);
  @@ -144,12 +146,12 @@
         set.add("Cooking");
         test.setSkills(set);
         cache_.attach("/a", test);
  -      Person result = (Person)cache_.find("/a");
  +      Person result = (Person) cache_.find("/a");
         assertEquals(" ", test, result);
   
         assertTrue("Instance of proxyclass ", result.getSkills() instanceof ClassProxy);
   
  -      Person r1 = (Person)cache_.detach("/a");
  +      Person r1 = (Person) cache_.detach("/a");
   
         assertEquals("Same instance ", result, r1);
         assertFalse("Instance of proxyclass ", result.getSkills() instanceof ClassProxy);
  @@ -169,12 +171,12 @@
         test.setHobbies(map);
   
         cache_.attach("/a", test);
  -      Person result = (Person)cache_.find("/a");
  +      Person result = (Person) cache_.find("/a");
         assertEquals(" ", test, result);
   
         assertTrue("Instance of proxyclass ", result.getHobbies() instanceof ClassProxy);
   
  -      Person r1 = (Person)cache_.detach("/a");
  +      Person r1 = (Person) cache_.detach("/a");
   
         assertEquals("Same instance ", result, r1);
         assertFalse("Instance of proxyclass ", result.getHobbies() instanceof ClassProxy);
  
  
  
  1.8       +8 -7      JBossCache/tests-50/functional/org/jboss/cache/pojo/NewReplicatedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewReplicatedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/NewReplicatedTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- NewReplicatedTest.java	3 Dec 2006 10:30:30 -0000	1.7
  +++ NewReplicatedTest.java	30 Dec 2006 17:49:58 -0000	1.8
  @@ -5,9 +5,9 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.pojo.test.Person;
   import org.jboss.cache.pojo.test.SpecialSerializedAddress;
  -import org.jboss.cache.Fqn;
   
   import javax.naming.Context;
   import java.util.Properties;
  @@ -130,7 +130,8 @@
         {
            remote.getAge();
            fail("Should throw out exception here.");
  -      } catch (PojoCacheAlreadyDetachedException pe)
  +      }
  +      catch (PojoCacheAlreadyDetachedException pe)
         {
         }
      }
  @@ -171,10 +172,10 @@
      public void testPutArray1() throws Exception
      {
         log_.info("testPutArray1() ....");
  -      long[] arr = new long[] {1, 2};
  +      long[] arr = new long[]{1, 2};
         cache_.attach("array", arr);
   
  -      long[] a2 = (long[])cache1_.find("array");
  +      long[] a2 = (long[]) cache1_.find("array");
         assertEquals("arr 0", 1, a2[0]);
      }
   
  @@ -188,11 +189,11 @@
         Person p2 = new Person();
         p2.setName("Joe");
         p2.setAge(20);
  -      Person[] arr = new Person[] {p1, p2};
  +      Person[] arr = new Person[]{p1, p2};
   
         cache_.attach("array", arr);
   
  -      Person[] a2 = (Person[])cache1_.find("array");
  +      Person[] a2 = (Person[]) cache1_.find("array");
         assertEquals("arr 0", "Ben", a2[0].getName());
      }
   
  @@ -214,7 +215,7 @@
   
         // restart cache1_
         cache1_.stop();
  -      cache1_.getCache().remove("/a");
  +      cache1_.getCache().removeNode(Fqn.fromString("/a"));
         cache1_.start();
         // Start from scratch for initial state transfer
         Person remote = (Person) cache1_.find("/a");
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/jmx    ...
Message-ID: <E1H0iLH-0008R9-0y@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    src/org/jboss/cache/jmx    CacheJmxWrapper.java
                        CacheLegacyJmxWrapperMBean.java Cache.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.9       +45 -54    JBossCache/src/org/jboss/cache/jmx/CacheJmxWrapper.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheJmxWrapper.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/jmx/CacheJmxWrapper.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- CacheJmxWrapper.java	16 Nov 2006 21:14:42 -0000	1.8
  +++ CacheJmxWrapper.java	30 Dec 2006 17:49:58 -0000	1.9
  @@ -24,21 +24,14 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Cache;
  -import org.jboss.cache.TreeCacheProxyImpl;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.ConfigurationException;
   import org.jboss.cache.factories.DefaultCacheFactory;
  -import org.jboss.cache.interceptors.CacheMgmtInterceptor;
  -import org.jboss.cache.interceptors.Interceptor;
   
  -import javax.management.ListenerNotFoundException;
  -import javax.management.MBeanNotificationInfo;
   import javax.management.MBeanRegistration;
   import javax.management.MBeanServer;
   import javax.management.MalformedObjectNameException;
  -import javax.management.NotificationBroadcaster;
  -import javax.management.NotificationFilter;
  -import javax.management.NotificationListener;
   import javax.management.ObjectName;
   
   public class CacheJmxWrapper 
  @@ -47,7 +40,7 @@
      private Log log = LogFactory.getLog(getClass().getName());
      
      private boolean registerInterceptors = true;
  -   private TreeCacheProxyImpl tcpi;
  +   private CacheImpl tcpi;
      private Configuration config;
      private MBeanServer server;
      private String cacheObjectName;
  @@ -75,7 +68,7 @@
   
      public String printCacheDetails()
      {
  -      return tcpi == null ? null : tcpi.treeCache.printDetails();
  +      return tcpi == null ? null : tcpi.printDetails();
      }
   
      public void create() throws Exception
  @@ -129,7 +122,6 @@
   
      /**
       * Caches the provided <code>server</code> and <code>objName</code>.
  -    *  
       */
      public ObjectName preRegister(MBeanServer server, ObjectName objName) 
            throws Exception
  @@ -205,7 +197,6 @@
       * Sets the configuration that the underlying cache should use.
       * 
       * @param config the configuration
  -    * 
       * @throws IllegalArgumentException if <code>config</code> is <code>null</code>.
       */
      public void setConfiguration(Configuration config)
  @@ -224,7 +215,7 @@
            throw new IllegalStateException("Cannot set underlying cache after call to create()");
         
         // FIXME -- the only reason we need to cast here is to support printCacheDetails 
  -      this.tcpi = (TreeCacheProxyImpl) cache;
  +      this.tcpi = (CacheImpl) cache;
         this.config = (tcpi == null ? null : tcpi.getConfiguration());
      }
      
  @@ -232,7 +223,7 @@
      {
         if (cacheObjectName == null)
         {
  -         cacheObjectName = JmxUtil.getCacheObjectName(config, TreeCacheProxyImpl.class.getName());
  +         cacheObjectName = JmxUtil.getCacheObjectName(config, CacheImpl.class.getName());
         }
         return cacheObjectName;
      }
  @@ -310,7 +301,7 @@
   //
   //   private CacheMgmtInterceptor getCacheMgmtInterceptor()
   //   {
  -//      for (Interceptor i : tcpi.treeCache.getInterceptors())
  +//      for (Interceptor i : tcpi.cache.getInterceptors())
   //      {
   //         if (i instanceof CacheMgmtInterceptor) return (CacheMgmtInterceptor) i;
   //      }
  
  
  
  1.3       +22 -22    JBossCache/src/org/jboss/cache/jmx/CacheLegacyJmxWrapperMBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLegacyJmxWrapperMBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/jmx/CacheLegacyJmxWrapperMBean.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- CacheLegacyJmxWrapperMBean.java	16 Nov 2006 05:19:29 -0000	1.2
  +++ CacheLegacyJmxWrapperMBean.java	30 Dec 2006 17:49:58 -0000	1.3
  @@ -21,21 +21,18 @@
    */
   package org.jboss.cache.jmx;
   
  -import javax.transaction.TransactionManager;
  -
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Region;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.config.BuddyReplicationConfig;
  -import org.jboss.cache.config.CacheLoaderConfig;
  -import org.jboss.cache.config.EvictionConfig;
   import org.jgroups.jmx.JChannelFactoryMBean;
   import org.w3c.dom.Element;
   
  +import javax.transaction.TransactionManager;
  +
   /**
    * StandardMBean interface for {@link CacheLegacyJmxWrapper}.
    * 
    * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public interface CacheLegacyJmxWrapperMBean extends CacheJmxWrapperMBean
   {
  @@ -51,7 +48,7 @@
   
      /**
       * Sets whether marshalling uses scoped class loaders on a per region basis.
  -    * <p />
  +    * <p/>
       * This property must be set to <code>true</code> before any call to
       * {@link Region#registerContextClassLoader(ClassLoader)}.
       *
  @@ -190,9 +187,9 @@
       * transfer or a call to {@link Region#activate()}.  Different
       * releases of JBossCache may format this data differently; this property
       * identifies the format version being used by this cache instance.
  -    * <p>
  +    * <p/>
       * The default value for this property is
  -    * {@link TreeCache#DEFAULT_REPLICATION_VERSION}.
  +    * {@link CacheImpl#DEFAULT_REPLICATION_VERSION}.
       * </p>
       *
       * @return    a short identifying JBossCache release; e.g. <code>124</code>
  @@ -260,27 +257,29 @@
       * Sets whether the entire tree is inactive upon startup, only responding
       * to replication messages after {@link Region#activate()} is
       * called to activate one or more parts of the tree.
  -    * <p>
  +    * <p/>
       * This property is only relevant if {@link #getUseMarshalling()} is
       * <code>true</code>.
  -    *
       */
      void setInactiveOnStartup(boolean inactiveOnStartup);
   
      /**
       * Sets the buddy replication configuration element
  +    *
       * @param config
       */
      void setBuddyReplicationConfig(Element config);
   
      /**
       * Retrieves the buddy replication cofiguration element
  +    *
       * @return config
       */
      Element getBuddyReplicationConfig();
   
      /**
       * Retrieves the JGroups multiplexer service name if defined.
  +    *
       * @return the multiplexer service name
       */
      String getMultiplexerService();
  @@ -295,6 +294,7 @@
   
      /**
       * Retrieves the JGroups multiplexer stack name if defined.
  +    *
       * @return the multiplexer stack name
       */
      String getMultiplexerStack();
  
  
  
  1.6       +9 -9      JBossCache/src/org/jboss/cache/jmx/Cache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Cache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/jmx/Cache.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- Cache.java	16 Nov 2006 21:14:42 -0000	1.5
  +++ Cache.java	30 Dec 2006 17:49:58 -0000	1.6
  @@ -1,16 +1,16 @@
   package org.jboss.cache.jmx;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.TreeCacheProxyImpl;
  +import org.jboss.cache.config.Configuration;
   import org.jboss.cache.interceptors.CacheMgmtInterceptor;
   import org.jboss.cache.interceptors.Interceptor;
  -import org.jboss.cache.config.Configuration;
   
  -import javax.management.NotificationBroadcaster;
  -import javax.management.NotificationListener;
  -import javax.management.NotificationFilter;
   import javax.management.ListenerNotFoundException;
   import javax.management.MBeanNotificationInfo;
  +import javax.management.NotificationBroadcaster;
  +import javax.management.NotificationFilter;
  +import javax.management.NotificationListener;
   
   /**
    * JMX object that operates on the cache
  @@ -19,11 +19,11 @@
    */
   public class Cache implements CacheMBean, NotificationBroadcaster
   {
  -   TreeCacheProxyImpl tcpi;
  +   private CacheImpl tcpi;
   
      public Cache(CacheSPI cacheSPI)
      {
  -      tcpi = (TreeCacheProxyImpl) cacheSPI;
  +      tcpi = (CacheImpl) cacheSPI;
      }
   
      public org.jboss.cache.Cache getCache()
  @@ -58,7 +58,7 @@
   
      public String printCacheDetails()
      {
  -      return tcpi.treeCache.printDetails();
  +      return tcpi.printDetails();
      }
   
      public void addNotificationListener(NotificationListener notificationListener, NotificationFilter notificationFilter, Object object) throws IllegalArgumentException
  @@ -78,7 +78,7 @@
   
      private CacheMgmtInterceptor getCacheMgmtInterceptor()
      {
  -      for (Interceptor i : tcpi.treeCache.getInterceptors())
  +      for (Interceptor i : tcpi.getInterceptors())
         {
            if (i instanceof CacheMgmtInterceptor) return (CacheMgmtInterceptor) i;
         }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs] JBossCache/tests/scripts  ...
Message-ID: <E1H0iLH-0008RG-4x@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    tests/scripts  bench.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.7       +131 -131  JBossCache/tests/scripts/bench.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: bench.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/scripts/bench.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- bench.xml	11 May 2006 00:01:00 -0000	1.6
  +++ bench.xml	30 Dec 2006 17:49:59 -0000	1.7
  @@ -12,7 +12,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TomcatClusteringCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -93,7 +93,7 @@
     </config>
   
     <!-- tcp-fast.xml | You have to edit bind_addr correctly. -->
  -<!-- 
  +         <!--
     <config>
       <TCP bind_addr="192.168.160.101"
            recv_buf_size="20000000"
  @@ -131,7 +131,7 @@
           min_threshold="0.10" max_block_time="1000"/>
       <pbcast.STATE_TRANSFER up_thread="false" down_thread="false"/>
     </config>
  --->
  +         -->
           </attribute>
   
           <!-- Max number of milliseconds to wait for a lock acquisition -->
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/statetransfer
	...
Message-ID: <E1H0iLH-0008RT-9P@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    tests/functional/org/jboss/cache/statetransfer   
                        StateTransfer200Test.java
                        StateTransferTestBase.java
                        FailedStateTransferTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.12      +4 -6      JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransfer200Test.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransfer200Test.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransfer200Test.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- StateTransfer200Test.java	21 Dec 2006 21:41:36 -0000	1.11
  +++ StateTransfer200Test.java	30 Dec 2006 17:49:59 -0000	1.12
  @@ -8,10 +8,8 @@
   package org.jboss.cache.statetransfer;
   
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.buddyreplication.BuddyManager;
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -26,7 +24,7 @@
    * Tests that state transfer works properly if the version is 2.0.0.GA.
    *
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class StateTransfer200Test extends VersionedTestBase
   {
  @@ -115,7 +113,7 @@
            cache2.start();
            fail("Should have caused an exception");
         }
  -      catch(Exception e)
  +      catch (Exception e)
         {
            assertNotNull(e);
         }      
  
  
  
  1.27      +8 -7      JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java,v
  retrieving revision 1.26
  retrieving revision 1.27
  diff -u -b -r1.26 -r1.27
  --- StateTransferTestBase.java	22 Dec 2006 18:55:05 -0000	1.26
  +++ StateTransferTestBase.java	30 Dec 2006 17:49:59 -0000	1.27
  @@ -33,7 +33,6 @@
   import org.jboss.cache.marshall.SelectedClassnameClassLoader;
   import org.jboss.cache.misc.TestingUtil;
   
  -
   import java.io.File;
   import java.util.HashMap;
   import java.util.Map;
  @@ -98,7 +97,7 @@
         if (caches.get(cacheID) != null)
            throw new IllegalStateException(cacheID + " already created");
   
  -//      TreeCache tree=new TreeCache();
  +//      CacheImpl tree=new CacheImpl();
         //PropertyConfigurator config=new PropertyConfigurator();
         String configFile = sync ? "META-INF/replSync-service.xml"
                 : "META-INF/replAsync-service.xml";
  @@ -338,7 +337,9 @@
         protected Exception exception;
         protected Thread thread;
   
  -      CacheUser(){}
  +      CacheUser()
  +      {
  +      }
         
         CacheUser(Semaphore semaphore,
                   String name,
  
  
  
  1.8       +24 -23    JBossCache/tests/functional/org/jboss/cache/statetransfer/FailedStateTransferTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FailedStateTransferTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/FailedStateTransferTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- FailedStateTransferTest.java	21 Dec 2006 21:41:36 -0000	1.7
  +++ FailedStateTransferTest.java	30 Dec 2006 17:49:59 -0000	1.8
  @@ -22,14 +22,14 @@
   
   package org.jboss.cache.statetransfer;
   
  -import java.io.InputStream;
  -
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Version;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.TimeoutException;
   
  +import java.io.InputStream;
  +
   /**
    * A FailedStateTransferTest.
    *
  @@ -41,22 +41,22 @@
   
      public void testFailedStateTransfer() throws Exception
      {
  -      TreeCache tree = new SecretiveStateCache();
  -      tree.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  -      tree.getConfiguration().setClusterName("VersionedTestBase");
  -      tree.getConfiguration().setReplVersionString(getReplicationVersion());
  +      CacheImpl cache = new SecretiveStateCache();
  +      cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  +      cache.getConfiguration().setClusterName("VersionedTestBase");
  +      cache.getConfiguration().setReplVersionString(getReplicationVersion());
         // Use a long timeout to facilitate setting debugger breakpoints
  -      tree.getConfiguration().setInitialStateRetrievalTimeout(60000);
  +      cache.getConfiguration().setInitialStateRetrievalTimeout(60000);
   
         // Put the cache in the map before starting, so if it fails in
         // start it can still be destroyed later
  -      caches.put("secretive", tree.getCacheSPI());
  +      caches.put("secretive", cache);
   
  -      tree.create();
  -      tree.start();
  +      cache.create();
  +      cache.start();
         
         
  -      TreeCache recipient = new SecretiveStateCache();
  +      CacheImpl recipient = new SecretiveStateCache();
         recipient.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
         recipient.getConfiguration().setClusterName("VersionedTestBase");
         recipient.getConfiguration().setReplVersionString(getReplicationVersion());
  @@ -65,7 +65,7 @@
         
         //Put the cache in the map before starting, so if it fails in
         // start it can still be destroyed later
  -      caches.put("secretive2", recipient.getCacheSPI());
  +      caches.put("secretive2", recipient);
         
         try
         {
  @@ -84,13 +84,14 @@
         return Version.version;
      }  
      
  -   private static class SecretiveStateCache extends TreeCache
  +   private static class SecretiveStateCache extends CacheImpl
      {    
         SecretiveStateCache() throws Exception
         {
            super();
            ml = new Adaptor();
         }          
  +
         class Adaptor extends MessageListenerAdaptor
         {
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1H0iLH-0008Rp-F9@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    tests/functional/org/jboss/cache/passivation      
                        PassivationToLocalDelegatingCacheLoaderTest.java
                        LocalPassivationIntegrationTest.java
                        BasicPassivationTest.java
                        ReplicatedPassivationIntegrationTest.java
                        ConcurrentPassivationTest.java
                        PassivationTestsBase.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.8       +7 -6      JBossCache/tests/functional/org/jboss/cache/passivation/PassivationToLocalDelegatingCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationToLocalDelegatingCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/PassivationToLocalDelegatingCacheLoaderTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- PassivationToLocalDelegatingCacheLoaderTest.java	16 Nov 2006 16:26:34 -0000	1.7
  +++ PassivationToLocalDelegatingCacheLoaderTest.java	30 Dec 2006 17:49:59 -0000	1.8
  @@ -2,7 +2,7 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.loader.DelegatingCacheLoader;
   import org.jboss.cache.loader.LocalDelegatingCacheLoader;
  @@ -11,17 +11,17 @@
    * Runs a test against using delegated cache loader
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationToLocalDelegatingCacheLoaderTest.java,v 1.7 2006/11/16 16:26:34 vblagojevic Exp $
  + * @version $Id: PassivationToLocalDelegatingCacheLoaderTest.java,v 1.8 2006/12/30 17:49:59 msurtani Exp $
    */
   public class PassivationToLocalDelegatingCacheLoaderTest extends PassivationTestsBase
   {
  -   TreeCache delegating_cache;
  +   CacheImpl delegating_cache;
      DelegatingCacheLoader cache_loader;
   
   
      protected void configureCache() throws Exception
      {
  -      delegating_cache = new TreeCache();
  +      delegating_cache = new CacheImpl();
         delegating_cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
         delegating_cache.create();
         delegating_cache.start();
  @@ -39,7 +39,8 @@
         delegating_cache.destroy();
      }
      
  -   public void testLoadAndStore() throws Exception{
  +   public void testLoadAndStore() throws Exception
  +   {
         //TODO intentional overload since this test does not pass
         //http://jira.jboss.com/jira/browse/JBCACHE-851
      }
  
  
  
  1.13      +5 -5      JBossCache/tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalPassivationIntegrationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- LocalPassivationIntegrationTest.java	22 Dec 2006 03:16:49 -0000	1.12
  +++ LocalPassivationIntegrationTest.java	30 Dec 2006 17:49:59 -0000	1.13
  @@ -11,8 +11,8 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractCacheListener;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -25,7 +25,7 @@
    */
   public class LocalPassivationIntegrationTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      protected final static Log log = LogFactory.getLog(LocalPassivationIntegrationTest.class);
      int wakeupIntervalMillis_ = 0;
      PassivationListener listener_;
  @@ -40,7 +40,7 @@
      {
         super.setUp();
         TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader"); // clean up any stale files left around by previous unit tests
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         initCaches(cache_);
         cache_.getConfiguration().setUseRegionBasedMarshalling(true);
   
  @@ -57,7 +57,7 @@
         }
      }
   
  -   void initCaches(TreeCache cache) throws Exception
  +   void initCaches(CacheImpl cache) throws Exception
      {
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -93,7 +93,7 @@
         cache_.put(str, str, str);
   
         TestingUtil.sleepThread(20000);
  -      assertFalse("NodeImpl should not exist", cache_.exists(str, str));
  +      assertFalse("UnversionedNode should not exist", cache_.exists(str, str));
         String val = (String) cache_.get(str, str);
         assertNotNull("DataNode should be activated ", val);
         assertEquals("Eviction counter ", 1, listener_.getCounter());
  
  
  
  1.13      +4 -4      JBossCache/tests/functional/org/jboss/cache/passivation/BasicPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BasicPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/BasicPassivationTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- BasicPassivationTest.java	20 Dec 2006 13:34:28 -0000	1.12
  +++ BasicPassivationTest.java	30 Dec 2006 17:49:59 -0000	1.13
  @@ -11,19 +11,19 @@
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.jboss.cache.AbstractCacheListener;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheListener;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
   /**
    * @author Ben Wang
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.13 $
    */
   public class BasicPassivationTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      int wakeupIntervalMillis_ = 0;
      final String ROOT_STR = "/test";
      Throwable t1_ex, t2_ex;
  @@ -54,7 +54,7 @@
   
      void initCaches() throws Exception
      {
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         CacheListener listener = new TestCacheListener();
  
  
  
  1.4       +11 -11    JBossCache/tests/functional/org/jboss/cache/passivation/ReplicatedPassivationIntegrationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedPassivationIntegrationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/ReplicatedPassivationIntegrationTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ReplicatedPassivationIntegrationTest.java	14 Nov 2006 14:17:11 -0000	1.3
  +++ ReplicatedPassivationIntegrationTest.java	30 Dec 2006 17:49:59 -0000	1.4
  @@ -23,13 +23,13 @@
   package org.jboss.cache.passivation;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractCacheListener;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.misc.TestingUtil;
   import org.jboss.cache.factories.XmlConfigurationParser;
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.misc.TestingUtil;
   
   import java.util.Map;
   
  @@ -38,8 +38,8 @@
    */
   public class ReplicatedPassivationIntegrationTest extends TestCase
   {
  -   TreeCache cache_;
  -   TreeCache cache1_;
  +   CacheImpl cache_;
  +   CacheImpl cache1_;
      protected final static Log log = LogFactory.getLog(ReplicatedPassivationIntegrationTest.class);
      int wakeupIntervalMillis_ = 0;
      ReplicatedPassivationIntegrationTest.PassivationListener listener_;
  @@ -53,12 +53,12 @@
      public void setUp() throws Exception
      {
         super.setUp();
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         initCaches(cache_);
         cache_.getConfiguration().setUseRegionBasedMarshalling(true);
         cache_.start();
   
  -      cache1_ = new TreeCache();
  +      cache1_ = new CacheImpl();
         initCaches(cache1_);
         cache1_.getConfiguration().setUseRegionBasedMarshalling(true);
   
  @@ -74,7 +74,7 @@
         }
      }
   
  -   void initCaches(TreeCache cache) throws Exception
  +   void initCaches(CacheImpl cache) throws Exception
      {
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-passivation-service.xml")); // read in generic local xml
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -101,7 +101,7 @@
         cache_.put(rootStr1, str, str);
   
         TestingUtil.sleepThread(11000);
  -      assertFalse("NodeImpl should not exist", cache1_.exists(str, str));
  +      assertFalse("UnversionedNode should not exist", cache1_.exists(str, str));
         String val;
         val = (String) cache1_.get(str, str);
         val = (String) cache1_.get(rootStr1, str);
  @@ -144,7 +144,7 @@
         {
            if (pre)
            {
  -            System.out.println("nodePassivate(): " +fqn);
  +            System.out.println("nodePassivate(): " + fqn);
            }
         }
   
  
  
  
  1.8       +4 -4      JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ConcurrentPassivationTest.java	22 Dec 2006 03:29:29 -0000	1.7
  +++ ConcurrentPassivationTest.java	30 Dec 2006 17:49:59 -0000	1.8
  @@ -10,8 +10,8 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -21,11 +21,11 @@
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   public class ConcurrentPassivationTest extends TestCase
   {
  -   private TreeCache cache_;
  +   private CacheImpl cache_;
      private int wakeupIntervalMillis_ = 0;
   
      public ConcurrentPassivationTest(String s)
  @@ -46,7 +46,7 @@
      void initCaches() throws Exception
      {
         TestingUtil.recursiveFileRemove("/tmp/JBossCacheFileCacheLoader");
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-passivation-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
   
  
  
  
  1.22      +6 -6      JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- PassivationTestsBase.java	15 Dec 2006 17:49:19 -0000	1.21
  +++ PassivationTestsBase.java	30 Dec 2006 17:49:59 -0000	1.22
  @@ -6,10 +6,10 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.loader.CacheLoader;
  @@ -38,7 +38,7 @@
    * Base tests for passivation using any of the cache loaders
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationTestsBase.java,v 1.21 2006/12/15 17:49:19 msurtani Exp $
  + * @version $Id: PassivationTestsBase.java,v 1.22 2006/12/30 17:49:59 msurtani Exp $
    */
   abstract public class PassivationTestsBase extends TestCase
   {
  @@ -46,7 +46,7 @@
      Log log = LogFactory.getLog(getClass());
   
      //Cache Loader fields
  -   TreeCache cache;
  +   CacheImpl cache;
      CacheLoader loader = null;
      Transaction tx = null;
      static final Fqn FQN = new Fqn("key");
  @@ -73,7 +73,7 @@
         super.setUp();
         log.debug("Testing " + getName());
         log.debug("");
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("local");
         configureCache();
         // cache.setCacheLoaderPreload("/1/2/3/4/5/d");
  @@ -429,7 +429,7 @@
            cache.put("/a/3", null);
            System.out.println("cache is " + cache.printLockInfo());
   
  -         DataNode n = cache.get("/a");
  +         Node n = cache.get("/a");
            assertNotNull(n);
   
            Set children = cache.getChildrenNames("/a");
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/region ...
Message-ID: <E1H0iLH-0008Rz-Ic@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    tests-50/functional/org/jboss/cache/pojo/region  
                        LocalTest.java NewLocalTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.7       +20 -16    JBossCache/tests-50/functional/org/jboss/cache/pojo/region/LocalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/region/LocalTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- LocalTest.java	31 Oct 2006 11:07:18 -0000	1.6
  +++ LocalTest.java	30 Dec 2006 17:49:59 -0000	1.7
  @@ -7,25 +7,28 @@
   
   package org.jboss.cache.pojo.region;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.pojo.*;
  -import org.jboss.cache.pojo.test.Person;
  -import org.jboss.cache.pojo.test.Address;
  -import org.jboss.cache.pojo.test.Student;
  +import org.jboss.aop.proxy.ClassProxy;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.aop.proxy.ClassProxy;
  +import org.jboss.cache.pojo.InternalConstant;
  +import org.jboss.cache.pojo.PojoCache;
  +import org.jboss.cache.pojo.PojoCacheFactory;
  +import org.jboss.cache.pojo.test.Address;
  +import org.jboss.cache.pojo.test.Person;
  +import org.jboss.cache.pojo.test.Student;
   
  +import java.util.ArrayList;
  +import java.util.HashMap;
  +import java.util.HashSet;
   import java.util.List;
   import java.util.Map;
  -import java.util.HashMap;
  -import java.util.ArrayList;
   import java.util.Set;
  -import java.util.HashSet;
   
   /**
    * Basic PojoCache test case.
  @@ -98,10 +101,10 @@
         assertEquals((Object) "Joe Black", p.getName());
   
         assertTrue("Region node should exist ",
  -              cache_.getCache().hasChild(new Fqn(REGION)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(REGION)));
         Fqn fqn = new Fqn(Fqn.fromString(REGION), InternalConstant.JBOSS_INTERNAL);
         assertTrue("Internal region node should exist ",
  -              cache_.getCache().hasChild(fqn));
  +              cache_.getCache().getRoot().hasChild(fqn));
      }
   
      public void testModification() throws Exception
  @@ -117,11 +120,11 @@
         Person joe = createPerson("person/test3", "Joe", 32);
         cache_.detach("person/test3");
   
  -      String str = ((org.jboss.cache.TreeCacheProxyImpl)cache_.getCache()).printDetails();
  -      System.out.println("**** Details ***/n" +str);
  +      String str = ((CacheImpl) cache_.getCache()).printDetails();
  +      System.out.println("**** Details ***/n" + str);
   
         Fqn fqn = new Fqn(Fqn.fromString(REGION), InternalConstant.JBOSS_INTERNAL);
  -      Node n = cache_.getCache().getChild(fqn);
  +      Node n = cache_.getCache().getRoot().getChild(fqn);
         assertTrue("Internal region node should not exist ",
                 n.getChildren().size() == 0);
      }
  @@ -137,7 +140,8 @@
            person.setAge(60);
            med = person.getMedication();
            assertEquals("Medication ", (Object) "Lipitor", (Object) med.get(0));
  -      } catch (Exception e)
  +      }
  +      catch (Exception e)
         {
            // should be thrown
         }
  @@ -195,7 +199,7 @@
         cache_.detach("person/test1");
   
         Fqn fqn = new Fqn(Fqn.fromString(REGION), InternalConstant.JBOSS_INTERNAL);
  -      Node n = cache_.getCache().getChild(fqn);
  +      Node n = cache_.getCache().getRoot().getChild(fqn);
         assertTrue("Internal region node should not exist ",
                 n.getChildren().size() == 0);
   
  
  
  
  1.6       +11 -6     JBossCache/tests-50/functional/org/jboss/cache/pojo/region/NewLocalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NewLocalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/region/NewLocalTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- NewLocalTest.java	31 Oct 2006 11:07:18 -0000	1.5
  +++ NewLocalTest.java	30 Dec 2006 17:49:59 -0000	1.6
  @@ -7,14 +7,16 @@
   
   package org.jboss.cache.pojo.region;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.pojo.*;
  -import org.jboss.cache.pojo.test.Person;
   import org.jboss.cache.Fqn;
  +import org.jboss.cache.pojo.InternalConstant;
  +import org.jboss.cache.pojo.PojoCache;
  +import org.jboss.cache.pojo.PojoCacheFactory;
  +import org.jboss.cache.pojo.test.Person;
   
   import java.util.Map;
   
  @@ -55,6 +57,7 @@
   
      /**
       * Not applied anymore.
  +    *
       * @throws Exception
       */
      public void XtestBadFqn() throws Exception
  @@ -72,7 +75,8 @@
         {
            cache_.attach(InternalConstant.JBOSS_INTERNAL_STRING, test);
            fail("putObject under JBoss_Internal should fail");
  -      } catch (IllegalArgumentException iex)
  +      }
  +      catch (IllegalArgumentException iex)
         {
            // ok
         }
  @@ -81,7 +85,8 @@
         {
            cache_.detach(InternalConstant.JBOSS_INTERNAL_STRING);
            fail("putObject under JBoss_Internal should fail");
  -      } catch (IllegalArgumentException iex)
  +      }
  +      catch (IllegalArgumentException iex)
         {
            // ok
         }
  @@ -116,7 +121,7 @@
         assertNull("Object should be null ", cache_.find("person"));
         assertEquals("Age should be updated as ", 20, test.getAge());
   
  -      assertNull("DataNode should not exisit ", cache_.getCache().get("person"));
  +      assertNull("DataNode should not exisit ", cache_.getCache().getRoot().get("person"));
      }
   
      public void testFindObjects() throws Exception
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs] JBossCache/examples/PojoCache/loadtime  ...
Message-ID: <E1H0iLH-0008S6-My@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    examples/PojoCache/loadtime  build.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.5       +92 -91    JBossCache/examples/PojoCache/loadtime/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/examples/PojoCache/loadtime/build.xml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- build.xml	21 Nov 2006 14:39:34 -0000	1.4
  +++ build.xml	30 Dec 2006 17:49:59 -0000	1.5
  @@ -1,37 +1,38 @@
   <?xml version="1.0"?>
   
  -<project name="aop examples annotated" default="help" >
  +<project name="aop examples annotated" default="help">
   
     <property name="build.sysclasspath" value="ignore"/>
  -  <property name="junit.timeout" value="180000"/> <!-- 3 minutes -->
  +   <property name="junit.timeout" value="180000"/>
  +   <!-- 3 minutes -->
   
     <property file="./build.properties"/>
   
     <!-- set local properties for this build -->
     <path id="lib.classpath">
         <fileset dir="${lib}">
  -        <include name="**/*.jar" />
  +         <include name="**/*.jar"/>
         </fileset>
         <pathelement path="${build}"/>
     </path>
   
     <path id="aop.classpath">
         <fileset dir="${lib}">
  -        <include name="javassist.jar" />
  -        <include name="trove.jar" />
  -        <include name="concurrent.jar" />
  -        <include name="jboss-common.jar" />
  -        <include name="jboss-aop-jdk50.jar" />
  -        <include name="log4j.jar" />
  +         <include name="javassist.jar"/>
  +         <include name="trove.jar"/>
  +         <include name="concurrent.jar"/>
  +         <include name="jboss-common.jar"/>
  +         <include name="jboss-aop-jdk50.jar"/>
  +         <include name="log4j.jar"/>
         </fileset>
     </path>
   
     <target name="help" description="help page">
  -      <echo message="build.sh &lt;command&gt; where command is:" />
  -      <echo message="         compile       -- compile the examples code" />
  -      <echo message="         clobber       -- clean up the whole directory" />
  -      <echo message="         run.aop.example -- run aop examples with annoc and aopc pre-compiler" />
  -      <echo message="         run.aop.demo  -- run demo gui for cache" />
  +      <echo message="build.sh &lt;command&gt; where command is:"/>
  +      <echo message="         compile       -- compile the examples code"/>
  +      <echo message="         clobber       -- clean up the whole directory"/>
  +      <echo message="         run.aop.example -- run aop examples with annoc and aopc pre-compiler"/>
  +      <echo message="         run.aop.demo  -- run demo gui for cache"/>
     </target>
   
     <!-- set up directory -->
  @@ -39,7 +40,7 @@
       <!-- Create the time stamp -->
       <tstamp/>
       <!-- Create the build directory structure used by compile
  -    and copy the deployment descriptors into it-->
  +and copy the deployment descriptors into it-->
       <mkdir dir="${build}"/>
       <mkdir dir="${reports}"/>
     </target>
  @@ -49,7 +50,7 @@
       <delete dir="${reports}"/>
     </target>
   
  -  <target name="clobber" depends="clean" />
  +   <target name="clobber" depends="clean"/>
   
     <!-- compile directory -->
     <target name="compile" depends="init" description="Build unit testing class">
  @@ -59,7 +60,7 @@
              debug="true"
              deprecation="true">
         <classpath>
  -        <path refid="lib.classpath" />
  +            <path refid="lib.classpath"/>
         </classpath>
       </javac>
   
  @@ -77,7 +78,7 @@
   
     <target name="run.aop.example" depends="compile" description="run standalone server replicator.">
   
  -    <java classname="test.examples.StudentMaintTest" fork="yes" >
  +      <java classname="test.examples.StudentMaintTest" fork="yes">
   
         <!-- Use jboss aop specific class loader -->
         <jvmarg value="-javaagent:${lib}/jboss-aop-jdk50.jar"/>
  @@ -85,20 +86,20 @@
         <!-- Alternatively aop will find META-INF/pojocache-aop.xml automatically -->
         <jvmarg value="-Djboss.aop.path=${resources}/pojocache-aop.xml;${output}/etc/user-aop.xml"/>
   
  -      <classpath refid="lib.classpath" />
  -      <classpath path="${build}" />
  -      <classpath path="${output}/etc" />
  +         <classpath refid="lib.classpath"/>
  +         <classpath path="${build}"/>
  +         <classpath path="${output}/etc"/>
       </java>
   
     </target>
   
  -  <target name="run.aop.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.aop.demo" depends="compile" description="run JBoss Cache demo.">
       <java classname="org.jboss.cache.TreeCacheView" fork="yes">
         <jvmarg value="-Xmx128M"/>
  -      <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -      <classpath path="${output}/etc" />
  -      <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
       </java>
     </target>
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:49:59 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:49:59 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/loader/deadlock ...
Message-ID: <E1H0iLH-0008SD-R7@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:49:59

  Modified:    tests/functional/org/jboss/cache/loader/deadlock 
                        ConcurrentCreationDeadlockTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.8       +13 -13    JBossCache/tests/functional/org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentCreationDeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ConcurrentCreationDeadlockTest.java	25 Oct 2006 04:50:20 -0000	1.7
  +++ ConcurrentCreationDeadlockTest.java	30 Dec 2006 17:49:59 -0000	1.8
  @@ -3,8 +3,8 @@
   import EDU.oswego.cs.dl.util.concurrent.Latch;
   import junit.framework.Test;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.loader.AbstractCacheLoaderTestBase;
  @@ -96,7 +96,7 @@
      /**
       * The cache under test.
       */
  -   private TreeCache m_cache = null;
  +   private CacheImpl cache = null;
   
      static
      {
  @@ -125,11 +125,11 @@
         m_contextFactory = System.getProperty(Context.INITIAL_CONTEXT_FACTORY);
         System.setProperty(Context.INITIAL_CONTEXT_FACTORY, CONTEXT_FACTORY);
         DummyTransactionManager.getInstance();
  -      m_cache = new TreeCache();
  +      cache = new CacheImpl();
   
         XmlConfigurationParser parser = new XmlConfigurationParser();
         Configuration c = parser.parseFile("META-INF/replSync-service.xml");
  -      m_cache.setConfiguration(c);
  +      cache.setConfiguration(c);
   
         c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
      }
  @@ -141,8 +141,8 @@
      {
         super.tearDown();
         DummyTransactionManager.destroy();
  -      m_cache.stop();
  -      m_cache = null;
  +      cache.stop();
  +      cache = null;
         if (m_contextFactory != null)
         {
            System.setProperty(Context.INITIAL_CONTEXT_FACTORY,
  @@ -161,13 +161,13 @@
      private void startCache(Configuration.CacheMode cacheMode, String cacheLoaderClass)
              throws Exception
      {
  -      m_cache.getConfiguration().setCacheMode(cacheMode);
  +      cache.getConfiguration().setCacheMode(cacheMode);
         if (cacheLoaderClass != null)
         {
  -         m_cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", cacheLoaderClass, "", false, false, false));
  +         cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", cacheLoaderClass, "", false, false, false));
         }
  -      m_cache.create();
  -      m_cache.start();
  +      cache.create();
  +      cache.start();
      }
   
      /**
  @@ -396,8 +396,8 @@
       * A worker thread that applies the concurrent modifications.
       *
       * @author Marian Nikolov
  -    * @author $Author: bstansberry $
  -    * @version $Date: 2006/10/25 04:50:20 $
  +    * @author $Author: msurtani $
  +    * @version $Date: 2006/12/30 17:49:59 $
       */
      private class Worker extends Thread
      {
  @@ -470,7 +470,7 @@
                  Fqn fqn = new Fqn(new Fqn("NODE"), new Integer(i));
                  for (int m = 0; m < m_modificationsPerTx; m++)
                  {
  -                  m_cache.put(fqn, new Integer(m), new Integer(i));
  +                  cache.put(fqn, new Integer(m), new Integer(i));
                     if (checkAndSetState())
                     {
                        return;
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/notifications
	...
Message-ID: <E1H0iLI-0008SN-0d@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    tests/functional/org/jboss/cache/notifications  
                        CacheListenerTest.java RemoteCacheListenerTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.10      +4 -4      JBossCache/tests/functional/org/jboss/cache/notifications/CacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/notifications/CacheListenerTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- CacheListenerTest.java	20 Nov 2006 07:33:14 -0000	1.9
  +++ CacheListenerTest.java	30 Dec 2006 17:49:59 -0000	1.10
  @@ -55,7 +55,7 @@
         if (optLocking) c.setNodeLockingScheme(Configuration.NodeLockingScheme.OPTIMISTIC);
         c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache = DefaultCacheFactory.createCache(c);
  -      tm = cache.getTransactionManager();
  +      tm = cache.getConfiguration().getRuntimeConfig().getTransactionManager();
         eventLog.events.clear();
         cache.addCacheListener(eventLog);
      }
  @@ -139,7 +139,7 @@
         assertEquals(expected, eventLog.events);
   
         // test that the node has in fact been removed.
  -      assertNull("Should be null", cache.getChild(fqn));
  +      assertNull("Should be null", cache.getRoot().getChild(fqn));
      }
   
   
  @@ -200,8 +200,8 @@
         cache.put(fqn, "key", "value");
         cache.put(newParent, "key", "value");
   
  -      Node n1 = cache.getChild(fqn);
  -      Node n2 = cache.getChild(newParent);
  +      Node n1 = cache.getRoot().getChild(fqn);
  +      Node n2 = cache.getRoot().getChild(newParent);
   
         eventLog.events.clear(); // clear events
         assertEquals("Event log should be empty", Collections.emptyList(), eventLog.events);
  
  
  
  1.3       +9 -9      JBossCache/tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoteCacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- RemoteCacheListenerTest.java	31 Oct 2006 06:57:28 -0000	1.2
  +++ RemoteCacheListenerTest.java	30 Dec 2006 17:49:59 -0000	1.3
  @@ -23,21 +23,21 @@
   package org.jboss.cache.notifications;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.AbstractCacheListener;
   import org.jboss.cache.Cache;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.AbstractCacheListener;
  +import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.lock.IsolationLevel;
  -import org.jboss.cache.config.Configuration;
   
  -import javax.transaction.TransactionManager;
   import javax.transaction.Transaction;
  +import javax.transaction.TransactionManager;
  +import java.util.ArrayList;
   import java.util.Collections;
  -import java.util.Map;
   import java.util.HashMap;
   import java.util.List;
  -import java.util.ArrayList;
  +import java.util.Map;
   
   /**
    * Remote conterpart of CacheListenerTest. Main difference is event is originating as local.
  @@ -71,7 +71,7 @@
         cache = DefaultCacheFactory.createCache(c);
   
         cache1 = DefaultCacheFactory.createCache(c);
  -      tm = cache1.getTransactionManager();
  +      tm = cache1.getConfiguration().getRuntimeConfig().getTransactionManager();
         eventLog.events.clear();
         cache1.addCacheListener(eventLog);
      }
  @@ -156,7 +156,7 @@
         assertEquals(expected, eventLog.events);
   
         // test that the node has in fact been removed.
  -      assertNull("Should be null", cache.getChild(fqn));
  +      assertNull("Should be null", cache.getRoot().getChild(fqn));
      }
   
   
  @@ -217,8 +217,8 @@
         cache.put(fqn, "key", "value");
         cache.put(newParent, "key", "value");
   
  -      Node n1 = cache.getChild(fqn);
  -      Node n2 = cache.getChild(newParent);
  +      Node n1 = cache.getRoot().getChild(fqn);
  +      Node n2 = cache.getRoot().getChild(newParent);
   
         eventLog.events.clear(); // clear events
         assertEquals("Event log should be empty", Collections.emptyList(), eventLog.events);
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/config   ...
Message-ID: <E1H0iLI-0008SX-4f@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    src/org/jboss/cache/config   Configuration.java
                        ConfigurationComponent.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.28      +29 -31    JBossCache/src/org/jboss/cache/config/Configuration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Configuration.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/Configuration.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- Configuration.java	11 Nov 2006 16:29:31 -0000	1.27
  +++ Configuration.java	30 Dec 2006 17:50:00 -0000	1.28
  @@ -6,7 +6,7 @@
    */
   package org.jboss.cache.config;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Version;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.lock.IsolationLevel;
  @@ -33,7 +33,7 @@
   
      public static CacheMode legacyModeToCacheMode(int legacyMode)
      {
  -      switch(legacyMode)
  +      switch (legacyMode)
         {
            case 1:
               return CacheMode.LOCAL;
  @@ -56,7 +56,8 @@
       */
      public enum NodeLockingScheme
      {
  -      PESSIMISTIC, OPTIMISTIC }
  +      PESSIMISTIC, OPTIMISTIC
  +   }
   
      /**
       * Default replication version, from {@link Version#getVersionShort}.
  @@ -67,7 +68,7 @@
      //   CONFIGURATION OPTIONS
      // ------------------------------------------------------------------------------------------------------------
   
  -   private String clusterName = "TreeCache-Group";
  +   private String clusterName = "JBossCache-Cluster";
      private String clusterConfig = null;
      private boolean useReplQueue = false;
      @Dynamic
  @@ -108,11 +109,11 @@
      // ------------------------------------------------------------------------------------------------------------
   
      /**
  -    * Sets a reference to an existing TreeCache instance
  +    * Sets a reference to an existing CacheImpl instance
       *
       * @param cache
       */
  -   public Configuration(TreeCache cache)
  +   public Configuration(CacheImpl cache)
      {
         setTreeCache(cache);
      }
  @@ -543,13 +544,10 @@
         this.runtimeConfig = runtimeConfig;
      }
      
  -
      // ------------------------------------------------------------------------------------------------------------
      //   HELPERS
      // ------------------------------------------------------------------------------------------------------------
   
  -   
  -
      // ------------------------------------------------------------------------------------------------------------
      //   OVERRIDDEN METHODS
      // ------------------------------------------------------------------------------------------------------------
  
  
  
  1.3       +31 -30    JBossCache/src/org/jboss/cache/config/ConfigurationComponent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConfigurationComponent.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/ConfigurationComponent.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ConfigurationComponent.java	10 Nov 2006 04:38:48 -0000	1.2
  +++ ConfigurationComponent.java	30 Dec 2006 17:50:00 -0000	1.3
  @@ -6,6 +6,10 @@
    */
   package org.jboss.cache.config;
   
  +import org.apache.commons.logging.Log;
  +import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
  +
   import java.io.Serializable;
   import java.util.Collection;
   import java.util.Collections;
  @@ -13,17 +17,12 @@
   import java.util.Iterator;
   import java.util.Set;
   
  -import org.apache.commons.logging.Log;
  -import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.TreeCache;
  -
   /**
    * Base superclass of Cache configuration classes that expose some properties
    * that can be changed after the cache is started.
    * 
    * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.2 $
  - * 
  + * @version $Revision: 1.3 $
    * @see #testImmutability(String)
    */
   public class ConfigurationComponent implements Serializable, Cloneable
  @@ -31,11 +30,13 @@
      private static final long serialVersionUID = 4879873994727821938L;
      
      protected Log log = LogFactory.getLog(getClass());
  -   private TreeCache cache; // back-reference to test whether the cache is running.
  +   private CacheImpl cache; // back-reference to test whether the cache is running.
      private Set<ConfigurationComponent> children = 
         Collections.synchronizedSet(new HashSet<ConfigurationComponent>());
      
  -   protected ConfigurationComponent() {}
  +   protected ConfigurationComponent()
  +   {
  +   }
      
      public void passCacheToChildConfig(ConfigurationComponent child)
      {
  @@ -110,7 +111,7 @@
         }
      }
      
  -   protected TreeCache getTreeCache()
  +   protected CacheImpl getTreeCache()
      {
         return cache;
      }
  @@ -120,7 +121,7 @@
       *
       * @param cache
       */
  -   public void setTreeCache(TreeCache cache)
  +   public void setTreeCache(CacheImpl cache)
      {
         this.cache = cache;
         synchronized (children)
  @@ -141,7 +142,7 @@
   
      /**
       * Null-safe equality test.
  -    * 
  +    * <p/>
       * FIXME this must be written elsewhere.
       */
      protected static boolean safeEquals(Object a, Object b)
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/util  ...
Message-ID: <E1H0iLI-0008Se-9U@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    src-50/org/jboss/cache/pojo/util  CacheApiUtil.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.4       +7 -7      JBossCache/src-50/org/jboss/cache/pojo/util/CacheApiUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheApiUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/util/CacheApiUtil.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- CacheApiUtil.java	11 Dec 2006 00:37:34 -0000	1.3
  +++ CacheApiUtil.java	30 Dec 2006 17:50:00 -0000	1.4
  @@ -7,17 +7,17 @@
   
   package org.jboss.cache.pojo.util;
   
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   
   import java.util.Map;
   
  -/** Utility for the 2.0 Cache API
  +/**
  + * Utility for the 2.0 Cache API
    *
    * @author Ben Wang
  - * @version $Id: CacheApiUtil.java,v 1.3 2006/12/11 00:37:34 bwang Exp $
  + * @version $Id: CacheApiUtil.java,v 1.4 2006/12/30 17:50:00 msurtani Exp $
    */
   public class CacheApiUtil
   {
  @@ -25,7 +25,7 @@
      {
   //      cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
         Node node = cache.getRoot().getChild(fqn);
  -      if(node == null) return null;
  +      if (node == null) return null;
   
   //      cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
         return node;
  @@ -33,15 +33,15 @@
   
      public static boolean exists(CacheSPI cache, Fqn fqn, Object key)
      {
  -      if(cache.getCacheLoader() != null)
  +      if (cache.getCacheLoader() != null)
         {
            // Has cache loader
            return (cache.get(fqn, key) != null) ? true : false;
         }
   
         Node node = cache.getRoot().getChild(fqn);
  -      if(node == null) return false;
  +      if (node == null) return false;
         Map map = node.getData();
  -      return (map.keySet().contains(key)) ? true: false;
  +      return (map.keySet().contains(key)) ? true : false;
      }
   }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache        ...
Message-ID: <E1H0iLI-0008T3-G8@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    tests/perf/org/jboss/cache        LocalMapPerfTest.java
                        ConcurrentEvictAndRemoveTest.java
                        LocalPerfTest.java ReplicatedAsyncMapPerfTest.java
                        ReplicatedAsyncPerfTest.java
                        ReplicatedSyncPerfTest.java
                        ReplicatedSyncMapPerfTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +9 -9      JBossCache/tests/perf/org/jboss/cache/LocalMapPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalMapPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/LocalMapPerfTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- LocalMapPerfTest.java	6 Sep 2006 15:31:01 -0000	1.5
  +++ LocalMapPerfTest.java	30 Dec 2006 17:50:00 -0000	1.6
  @@ -29,24 +29,24 @@
   import java.util.Properties;
   
   /**
  - * Local mode performance test for TreeCache.
  + * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class LocalMapPerfTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.LOCAL;
      final static Properties p_;
  -//   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
  +   //   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
      String oldFactory_ = null;
      final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
      DummyTransactionManager tm_;
      Map map_ = new HashMap();
  -//    final int SIZE = 100;
  -//    final String FQN = "/regular/test";
  -//    final String KEY = Integer.toString((SIZE/2));
  +   //    final int SIZE = 100;
  +   //    final String FQN = "/regular/test";
  +   //    final String KEY = Integer.toString((SIZE/2));
      ArrayList nodeList_;
      static final int depth_ = 3;
      static final int children_ = 4;
  @@ -122,7 +122,7 @@
      void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
         cachingMode_ = caching_mode;
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-service.xml"));
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.start();
  @@ -273,7 +273,7 @@
   
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  
  
  
  1.7       +226 -190  JBossCache/tests/perf/org/jboss/cache/ConcurrentEvictAndRemoveTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentEvictAndRemoveTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ConcurrentEvictAndRemoveTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ConcurrentEvictAndRemoveTest.java	27 Oct 2006 19:26:07 -0000	1.6
  +++ ConcurrentEvictAndRemoveTest.java	30 Dec 2006 17:50:00 -0000	1.7
  @@ -8,36 +8,37 @@
   
   package org.jboss.cache;
   
  -import java.util.Random;
  -
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.config.EvictionConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
   
  +import java.util.Random;
  +
   /**
  - * Local mode test for concurrent EvictionTimerTask evicting nodes and Client removing nodes from TreeCache.
  + * Local mode test for concurrent EvictionTimerTask evicting nodes and Client removing nodes from CacheImpl.
    *
  - * @version $Revision: 1.6 $
    * @author <a href="mailto:uwe.lamprecht at gmx.de">Uwe Lamprecht</a> July 29 2004
  + * @version $Revision: 1.7 $
    */
   public final class ConcurrentEvictAndRemoveTest extends TestCase
   {
       private static final Log log = LogFactory.getLog(ConcurrentEvictAndRemoveTest.class.getName());
  -    private TreeCache cache;
  +   private CacheImpl cache;
   
   
  -   static void log(String msg) {
  +   static void log(String msg)
  +   {
         System.out.println(msg);
         log.info(msg);
      }
   
  -   void err(String msg) {
  +   void err(String msg)
  +   {
         // System.err.println(msg);
         log.error(msg);
      }
  @@ -50,12 +51,13 @@
       public void setUp() throws Exception
       {
           super.setUp();
  -        cache = new TreeCache();
  +      cache = new CacheImpl();
           cache.getConfiguration().setCacheMode(Configuration.CacheMode.LOCAL);
           cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-mru-eviction-service.xml"));
           cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
           cache.start();
       }
  +
       public void tearDown() throws Exception
       {
           super.tearDown();
  @@ -73,11 +75,13 @@
           {
               final StopWatch stopWatch = new StopWatch();
               int i = 0;
  -            while(true) {
  +         while (true)
  +         {
                   i++;
                   final Fqn fqn = Fqn.fromString("/test/item_" + i);
                   cache.put(fqn, "att", null);
  -                if (stopWatch.getTime()>MAX_LOOP_TIME) {
  +            if (stopWatch.getTime() > MAX_LOOP_TIME)
  +            {
                       break;
                   }
               }
  @@ -99,15 +103,20 @@
               final Random random = new Random();
               final StopWatch stopWatch = new StopWatch();
   
  -            while(true) {
  +         while (true)
  +         {
                   final Fqn fqn = Fqn.fromString("/test/item_" + random.nextInt(numberOfInitialCreatedNodes));
  -                if (cache.exists(fqn)) {
  +            if (cache.exists(fqn))
  +            {
                       cache.remove(fqn);
                       numberCacheHitSuccess++;
  -                } else {
  +            }
  +            else
  +            {
                       numberCacheHitFailure++;
                   }
  -                if (stopWatch.getTime()>MAX_LOOP_TIME) {
  +            if (stopWatch.getTime() > MAX_LOOP_TIME)
  +            {
                       break;
                   }
               }
  @@ -129,58 +138,73 @@
               final long TIMEOUT_DEFAULT = 100000;
               final int MAX_TIMEOUT_FACTOR = 10;
   
  -            for(int i = 0; i < EvictionConfig.EVENT_QUEUE_SIZE_DEFAULT; i = i + SEQUENCE_SIZE) {
  +         for (int i = 0; i < EvictionConfig.EVENT_QUEUE_SIZE_DEFAULT; i = i + SEQUENCE_SIZE)
  +         {
                   final int sequenceStart = i;
  -                final int sequenceEnd = i + SEQUENCE_SIZE -1;
  +            final int sequenceEnd = i + SEQUENCE_SIZE - 1;
   
                   Thread thread = new Thread(
                           new HelperThread(cache, sequenceStart, sequenceEnd)
                   );
   
  -                long timeout = (HelperThread.getTime()==HelperThread.EXECUTION_TIME_NOT_INITIALIZED)?
  -                        TIMEOUT_DEFAULT:
  -                            HelperThread.getTime()*MAX_TIMEOUT_FACTOR;
  +            long timeout = (HelperThread.getTime() == HelperThread.EXECUTION_TIME_NOT_INITIALIZED) ?
  +                    TIMEOUT_DEFAULT :
  +                    HelperThread.getTime() * MAX_TIMEOUT_FACTOR;
   
                   thread.start();
  -                try {
  +            try
  +            {
                       thread.join(timeout);
  -                    if (thread.isAlive()) {
  +               if (thread.isAlive())
  +               {
                           // Timeout occurred; thread has not finished
                           err("Timeout of " + timeout + " ms exceeded for sequence of put/remove operations.");
                           fail("Timeout of " + timeout + " ms exceeded for sequence of put/remove operations.");
  -                    } else {
  +               }
  +               else
  +               {
                           // Finished
                       }
                   }
  -                catch(InterruptedException ignore) {
  +            catch (InterruptedException ignore)
  +            {
                       err("Thread join interrupted.");
                   }
               }
           }
           log("*** Successfully finished! ***");
       }
  +
       public static Test suite() throws Exception
       {
           return new TestSuite(ConcurrentEvictAndRemoveTest.class);
       }
   
       // private util classes
  -    private static final class StopWatch {
  -        public StopWatch() {
  -            startTime = System.currentTimeMillis() ;
  +   private static final class StopWatch
  +   {
  +      public StopWatch()
  +      {
  +         startTime = System.currentTimeMillis();
           }
  +
           private final long startTime;   // Start time of stopwatch.
           //   (Time is measured in milliseconds.)
   
  -        public String toString() {
  +      public String toString()
  +      {
               return String.valueOf(getTime());
           }
  -        public long getTime() {
  +
  +      public long getTime()
  +      {
               return System.currentTimeMillis() - startTime;
           }
       }
  -    private static final class HelperThread implements Runnable {
  -        private final TreeCache c;
  +
  +   private static final class HelperThread implements Runnable
  +   {
  +      private final CacheImpl c;
           private final int start;
           private final int end;
           // static member
  @@ -188,12 +212,15 @@
           private static long previousExceutionTime = EXECUTION_TIME_NOT_INITIALIZED;
           private static final String FQN_PREFIX =  "/test/overflow-item_";
   
  -        public HelperThread ( TreeCache cache, int start, int end) {
  +      public HelperThread(CacheImpl cache, int start, int end)
  +      {
               this.c = cache;
               this.start = start;
               this.end = end;
           }
  -        public void run() {
  +
  +      public void run()
  +      {
               StopWatch stopWatch = new StopWatch();
               log(
                       "process node range: "
  @@ -201,18 +228,25 @@
                       + "/"
                       + this.end
               );
  -            try {
  -                for (int i = start; i<=end; i++) {
  +         try
  +         {
  +            for (int i = start; i <= end; i++)
  +            {
                       final Fqn fqn = Fqn.fromString(FQN_PREFIX + i);
                       c.put(fqn, "att", null);
                       c.remove(fqn);
                       //Thread.yield();
                   }
  -            } catch (Exception e) {
  +         }
  +         catch (Exception e)
  +         {
                   System.out.println("exception: " + e);
  -                if ( e instanceof RuntimeException) {
  -                    throw (RuntimeException)e;
  -                } else {
  +            if (e instanceof RuntimeException)
  +            {
  +               throw (RuntimeException) e;
  +            }
  +            else
  +            {
                       throw new RuntimeException(e);
                   }
               }
  @@ -223,7 +257,9 @@
                       + " ms"
               );
           }
  -        public static long getTime() {
  +
  +      public static long getTime()
  +      {
               return previousExceutionTime;
           }
       }
  
  
  
  1.6       +6 -6      JBossCache/tests/perf/org/jboss/cache/LocalPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/LocalPerfTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- LocalPerfTest.java	6 Sep 2006 15:31:01 -0000	1.5
  +++ LocalPerfTest.java	30 Dec 2006 17:50:00 -0000	1.6
  @@ -27,17 +27,17 @@
   import java.util.Properties;
   
   /**
  - * Local mode performance test for TreeCache.
  + * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class LocalPerfTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.LOCAL;
      final static Properties p_;
  -//   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
  +   //   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
      String oldFactory_ = null;
      final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
      ArrayList nodeList_;
  @@ -89,7 +89,7 @@
      void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
         cachingMode_ = caching_mode;
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-service.xml"));
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.start();
  @@ -283,7 +283,7 @@
      }
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  
  
  
  1.7       +9 -9      JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncMapPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedAsyncMapPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncMapPerfTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ReplicatedAsyncMapPerfTest.java	6 Sep 2006 15:31:01 -0000	1.6
  +++ ReplicatedAsyncMapPerfTest.java	30 Dec 2006 17:50:00 -0000	1.7
  @@ -27,24 +27,24 @@
   import java.util.Properties;
   
   /**
  - * Local mode performance test for TreeCache.
  + * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class ReplicatedAsyncMapPerfTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.LOCAL;
      final static Properties p_;
  -//   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
  +   //   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
      String oldFactory_ = null;
      final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
      DummyTransactionManager tm_;
      Map map_ = new HashMap();
  -//    final int SIZE = 100;
  -//    final String FQN = "/regular/test";
  -//    final String KEY = Integer.toString((SIZE/2));
  +   //    final int SIZE = 100;
  +   //    final String FQN = "/regular/test";
  +   //    final String KEY = Integer.toString((SIZE/2));
      ArrayList nodeList_;
      static final int depth_ = 3;
      static final int children_ = 4;
  @@ -137,7 +137,7 @@
      void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
         cachingMode_ = caching_mode;
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml")); // read in generic replAsync xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.start();
  @@ -282,7 +282,7 @@
   
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  
  
  
  1.5       +11 -11    JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedAsyncPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncPerfTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ReplicatedAsyncPerfTest.java	6 Sep 2006 15:31:01 -0000	1.4
  +++ ReplicatedAsyncPerfTest.java	30 Dec 2006 17:50:00 -0000	1.5
  @@ -26,18 +26,18 @@
   import java.util.Properties;
   
   /**
  - * Replicated asynchronous mode performance test for transactional TreeCache
  + * Replicated asynchronous mode performance test for transactional CacheImpl
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class ReplicatedAsyncPerfTest extends TestCase
   {
  -   TreeCache cache1_, cache2_, cache3_;
  +   CacheImpl cache1_, cache2_, cache3_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.REPL_ASYNC;
      final String groupName_ = "TreeCacheTestGroup";
      final static Properties p_;
  -//   final static Log log_=LogFactory.getLog(ReplicatedAsyncPerfAopTest.class);
  +   //   final static Log log_=LogFactory.getLog(ReplicatedAsyncPerfAopTest.class);
      String oldFactory_ = null;
      final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
   
  @@ -89,9 +89,9 @@
   
      }
   
  -   TreeCache createCache(IsolationLevel level) throws Exception
  +   CacheImpl createCache(IsolationLevel level) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         XmlConfigurationParser parser = new XmlConfigurationParser();
         Configuration c = parser.parseFile("META-INF/replAsync-service.xml"); // read in generic replAsync xml
         cache.setConfiguration(c);
  @@ -99,7 +99,7 @@
         return cache;
      }
   
  -   private void destroyCache(TreeCache cache) throws Exception
  +   private void destroyCache(CacheImpl cache) throws Exception
      {
         if (cache != null)
         {
  @@ -354,7 +354,7 @@
         destroyCache(cache3_);
      }
   
  -   private int _add(TreeCache cache, boolean hasTx) throws Exception
  +   private int _add(CacheImpl cache, boolean hasTx) throws Exception
      {
         UserTransaction tx = null;
         if (hasTx)
  @@ -381,7 +381,7 @@
         return nodeList_.size();
      }
   
  -   private int _get(TreeCache cache, boolean hasTx) throws Exception
  +   private int _get(CacheImpl cache, boolean hasTx) throws Exception
      {
         UserTransaction tx = null;
         if (hasTx)
  @@ -407,7 +407,7 @@
         return nodeList_.size();
      }
   
  -   private int _remove(TreeCache cache, boolean hasTx) throws Exception
  +   private int _remove(CacheImpl cache, boolean hasTx) throws Exception
      {
         UserTransaction tx = null;
         if (hasTx)
  @@ -434,7 +434,7 @@
      }
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       */
      private ArrayList nodeGen(int depth, int children)
  
  
  
  1.5       +14 -14    JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedSyncPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncPerfTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ReplicatedSyncPerfTest.java	6 Sep 2006 15:31:01 -0000	1.4
  +++ ReplicatedSyncPerfTest.java	30 Dec 2006 17:50:00 -0000	1.5
  @@ -24,15 +24,15 @@
   import java.util.ArrayList;
   
   /**
  - * Replicated synchronous mode performance test for transactional TreeCache.
  + * Replicated synchronous mode performance test for transactional CacheImpl.
    *
    * @author Bela Ban
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class ReplicatedSyncPerfTest extends TestCase
   {
  -   TreeCache cache1_, cache2_, cache3_;
  +   CacheImpl cache1_, cache2_, cache3_;
      final String groupName_ = "TreeCacheTestGroup";
      Transaction tx;
   
  @@ -63,9 +63,9 @@
            tx.rollback();
      }
   
  -   TreeCache createCache(IsolationLevel level) throws Exception
  +   CacheImpl createCache(IsolationLevel level) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
         cache.getConfiguration().setIsolationLevel(level);
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -75,7 +75,7 @@
         return cache;
      }
   
  -   void destroyCache(TreeCache cache) throws Exception
  +   void destroyCache(CacheImpl cache) throws Exception
      {
         if (cache != null)
         {
  @@ -121,7 +121,7 @@
         {
            failedOps++;
            t.printStackTrace();
  -         System.out.println("tree is " + cache1_.printLockInfo());
  +         System.out.println("cache is " + cache1_.printLockInfo());
            if (tx != null)
               tx.rollback();
         }
  @@ -368,7 +368,7 @@
      }
   
   
  -   private int add(TreeCache cache, boolean hasTx, boolean oneTxOnly) throws Exception
  +   private int add(CacheImpl cache, boolean hasTx, boolean oneTxOnly) throws Exception
      {
         try
         {
  @@ -383,7 +383,7 @@
         }
      }
   
  -   private int _add(TreeCache cache, boolean hasTx, boolean oneTxOnly) throws Exception
  +   private int _add(CacheImpl cache, boolean hasTx, boolean oneTxOnly) throws Exception
      {
         if (hasTx && oneTxOnly)
         {
  @@ -414,7 +414,7 @@
         return nodeList_.size();
      }
   
  -   private int get(TreeCache cache, boolean hasTx, boolean oneTxOnly) throws Exception
  +   private int get(CacheImpl cache, boolean hasTx, boolean oneTxOnly) throws Exception
      {
         try
         {
  @@ -428,7 +428,7 @@
         }
      }
   
  -   private int _get(TreeCache cache, boolean hasTx, boolean oneTxOnly) throws Exception
  +   private int _get(CacheImpl cache, boolean hasTx, boolean oneTxOnly) throws Exception
      {
         if (hasTx && oneTxOnly)
         {
  @@ -459,7 +459,7 @@
      }
   
   
  -   private int remove(TreeCache cache, boolean hasTx, boolean oneTxOnly) throws Exception
  +   private int remove(CacheImpl cache, boolean hasTx, boolean oneTxOnly) throws Exception
      {
         try
         {
  @@ -473,7 +473,7 @@
         }
      }
   
  -   private int _remove(TreeCache cache, boolean hasTx, boolean oneTxOnly) throws Exception
  +   private int _remove(CacheImpl cache, boolean hasTx, boolean oneTxOnly) throws Exception
      {
         if (hasTx && oneTxOnly)
         {
  @@ -504,7 +504,7 @@
      }
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       */
      private ArrayList nodeGen(int depth, int children)
  
  
  
  1.6       +9 -9      JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncMapPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedSyncMapPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncMapPerfTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ReplicatedSyncMapPerfTest.java	6 Sep 2006 15:31:01 -0000	1.5
  +++ ReplicatedSyncMapPerfTest.java	30 Dec 2006 17:50:00 -0000	1.6
  @@ -29,24 +29,24 @@
   import java.util.Properties;
   
   /**
  - * Local mode performance test for TreeCache.
  + * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class ReplicatedSyncMapPerfTest extends TestCase
   {
  -   TreeCache cache_;
  +   CacheImpl cache_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.LOCAL;
      final static Properties p_;
  -//   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
  +   //   final static Log log_=LogFactory.getLog(LocalPerfAopTest.class);
      String oldFactory_ = null;
      final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
      DummyTransactionManager tm_;
      Map map_ = new HashMap();
  -//    final int SIZE = 100;
  -//    final String FQN = "/regular/test";
  -//    final String KEY = Integer.toString((SIZE/2));
  +   //    final int SIZE = 100;
  +   //    final String FQN = "/regular/test";
  +   //    final String KEY = Integer.toString((SIZE/2));
      ArrayList nodeList_;
      static final int depth_ = 3;
      static final int children_ = 4;
  @@ -141,7 +141,7 @@
      void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
         cachingMode_ = caching_mode;
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replSync-service.xml"));
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.start();
  @@ -304,7 +304,7 @@
   
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache/loader   ...
Message-ID: <E1H0iLI-0008TD-Ja@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    tests/perf/org/jboss/cache/loader  
                        JDBCCacheLoaderPerfTest.java
                        CacheLoaderPerfTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.10      +3 -3      JBossCache/tests/perf/org/jboss/cache/loader/JDBCCacheLoaderPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JDBCCacheLoaderPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/loader/JDBCCacheLoaderPerfTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- JDBCCacheLoaderPerfTest.java	14 Dec 2006 18:52:40 -0000	1.9
  +++ JDBCCacheLoaderPerfTest.java	30 Dec 2006 17:50:00 -0000	1.10
  @@ -7,8 +7,8 @@
   package org.jboss.cache.loader;
   
   import junit.textui.TestRunner;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
   
   import java.util.HashMap;
  @@ -23,7 +23,7 @@
    */
   public class JDBCCacheLoaderPerfTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
   
      private Random random = new Random();
  @@ -40,7 +40,7 @@
      protected void setUp() throws Exception
      {
         if (cache != null) tearDown();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("local");
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         configureCache();
  
  
  
  1.10      +3 -3      JBossCache/tests/perf/org/jboss/cache/loader/CacheLoaderPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/loader/CacheLoaderPerfTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- CacheLoaderPerfTest.java	25 Oct 2006 04:51:38 -0000	1.9
  +++ CacheLoaderPerfTest.java	30 Dec 2006 17:50:00 -0000	1.10
  @@ -7,8 +7,8 @@
   package org.jboss.cache.loader;
   
   import junit.textui.TestRunner;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
   
   import java.io.File;
  @@ -21,7 +21,7 @@
    */
   public class CacheLoaderPerfTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private long totalTime = 0;
   
      private Random random = new Random();
  @@ -34,7 +34,7 @@
      {
         if (cache != null) tearDown();
         String tmpLocation = System.getProperty("java.io.tmpdir", ".") + File.separator + "JBossCache-CacheLoaderPerfTest";
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheLoaderConfig(getSingleCacheLoaderConfig("", "org.jboss.cache.loader.FileCacheLoader", "location=" + tmpLocation, false, false, false));
         File dir = new File(tmpLocation);
         if (!dir.exists()) dir.mkdirs();
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/rmi     ...
Message-ID: <E1H0iLI-0008TT-OY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    src/org/jboss/cache/loader/rmi     RmiCacheServerMBean.java
                        RemoteTreeCacheImpl.java RmiCacheServer.java
                        RemoteTreeCache.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.4       +4 -4      JBossCache/src/org/jboss/cache/loader/rmi/RmiCacheServerMBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RmiCacheServerMBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/rmi/RmiCacheServerMBean.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- RmiCacheServerMBean.java	7 Sep 2006 13:52:28 -0000	1.3
  +++ RmiCacheServerMBean.java	30 Dec 2006 17:50:00 -0000	1.4
  @@ -1,6 +1,6 @@
   package org.jboss.cache.loader.rmi;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.jmx.LifeCycle;
   
   import javax.management.MalformedObjectNameException;
  @@ -8,7 +8,7 @@
   
   /**
    * @author Manik Surtani
  - * @version $Id: RmiCacheServerMBean.java,v 1.3 2006/09/07 13:52:28 msurtani Exp $
  + * @version $Id: RmiCacheServerMBean.java,v 1.4 2006/12/30 17:50:00 msurtani Exp $
    */
   public interface RmiCacheServerMBean extends LifeCycle
   {
  @@ -29,10 +29,10 @@
      void setConfig(String config);
   
      //TreeCacheMBean getCache();
  -   TreeCache getCache();
  +   CacheImpl getCache();
   
      //void setCache(TreeCacheMBean cache);
  -   void setCache(TreeCache cache);
  +   void setCache(CacheImpl cache);
   
      String getCacheName();
   
  
  
  
  1.11      +11 -11    JBossCache/src/org/jboss/cache/loader/rmi/RemoteTreeCacheImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoteTreeCacheImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/rmi/RemoteTreeCacheImpl.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- RemoteTreeCacheImpl.java	22 Sep 2006 16:27:56 -0000	1.10
  +++ RemoteTreeCacheImpl.java	30 Dec 2006 17:50:00 -0000	1.11
  @@ -6,9 +6,9 @@
    */
   package org.jboss.cache.loader.rmi;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.NodeImpl;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   
   import java.rmi.RemoteException;
   import java.rmi.server.UnicastRemoteObject;
  @@ -16,10 +16,10 @@
   import java.util.Set;
   
   /**
  - * Implementation of the {@link org.jboss.cache.TreeCache}'s remote interface.
  + * Implementation of the {@link org.jboss.cache.CacheImpl}'s remote interface.
    *
    * @author Daniel Gredler
  - * @version $Id: RemoteTreeCacheImpl.java,v 1.10 2006/09/22 16:27:56 msurtani Exp $
  + * @version $Id: RemoteTreeCacheImpl.java,v 1.11 2006/12/30 17:50:00 msurtani Exp $
    */
   public class RemoteTreeCacheImpl extends UnicastRemoteObject implements RemoteTreeCache
   {
  @@ -27,13 +27,13 @@
      private static final long serialVersionUID = 3096209368650710385L;
   
      //private TreeCacheMBean cache;
  -   private TreeCache cache;
  +   private CacheImpl cache;
   
      /**
       * @throws RemoteException
       */
      //public RemoteTreeCacheImpl(TreeCacheMBean cache) throws RemoteException {
  -   public RemoteTreeCacheImpl(TreeCache cache) throws RemoteException
  +   public RemoteTreeCacheImpl(CacheImpl cache) throws RemoteException
      {
         this.cache = cache;
      }
  @@ -47,7 +47,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#get(org.jboss.cache.Fqn, java.lang.Object)
  +    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#get(org.jboss.cache.Fqn,java.lang.Object)
       */
      public Object get(Fqn name, Object key) throws Exception, RemoteException
      {
  @@ -57,7 +57,7 @@
      /**
       * @see org.jboss.cache.loader.rmi.RemoteTreeCache#get(org.jboss.cache.Fqn)
       */
  -   public NodeImpl get(Fqn name) throws Exception, RemoteException
  +   public Node get(Fqn name) throws Exception, RemoteException
      {
         return this.cache.get(name);
      }
  @@ -71,7 +71,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#put(org.jboss.cache.Fqn, java.lang.Object, java.lang.Object)
  +    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#put(org.jboss.cache.Fqn,java.lang.Object,java.lang.Object)
       */
      public Object put(Fqn name, Object key, Object value) throws Exception, RemoteException
      {
  @@ -79,7 +79,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#put(org.jboss.cache.Fqn, java.util.Map)
  +    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#put(org.jboss.cache.Fqn,java.util.Map)
       */
      public void put(Fqn name, Map attributes) throws Exception, RemoteException
      {
  @@ -87,7 +87,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#remove(org.jboss.cache.Fqn, java.lang.Object)
  +    * @see org.jboss.cache.loader.rmi.RemoteTreeCache#remove(org.jboss.cache.Fqn,java.lang.Object)
       */
      public Object remove(Fqn name, Object key) throws Exception, RemoteException
      {
  
  
  
  1.9       +10 -10    JBossCache/src/org/jboss/cache/loader/rmi/RmiCacheServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RmiCacheServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/rmi/RmiCacheServer.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- RmiCacheServer.java	25 Oct 2006 12:49:31 -0000	1.8
  +++ RmiCacheServer.java	30 Dec 2006 17:50:00 -0000	1.9
  @@ -1,6 +1,6 @@
   package org.jboss.cache.loader.rmi;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.jmx.JmxUtil;
   
  @@ -11,16 +11,16 @@
   import java.rmi.Naming;
   
   /**
  - * Server which exports an RMI stub to the TreeCache. Clients can use the RmiDelegatingCacheLoader to remotely
  - * delegate to this TreeCache
  + * Server which exports an RMI stub to the CacheImpl. Clients can use the RmiDelegatingCacheLoader to remotely
  + * delegate to this CacheImpl
    *
    * @author Bela Ban
  - * @version $Id: RmiCacheServer.java,v 1.8 2006/10/25 12:49:31 msurtani Exp $
  + * @version $Id: RmiCacheServer.java,v 1.9 2006/12/30 17:50:00 msurtani Exp $
    */
   public class RmiCacheServer implements RmiCacheServerMBean
   {
      //TreeCacheMBean cache;
  -   TreeCache cache;
  +   CacheImpl cache;
      RemoteTreeCacheImpl remoteObj;
      String bindAddress;
      String mbeanServerName;
  @@ -70,13 +70,13 @@
      }
   
      //public TreeCacheMBean getCache()
  -   public TreeCache getCache()
  +   public CacheImpl getCache()
      {
         return cache;
      }
   
      //public void setCache(TreeCacheMBean cache)
  -   public void setCache(TreeCache cache)
  +   public void setCache(CacheImpl cache)
      {
         this.cache = cache;
      }
  @@ -122,14 +122,14 @@
            if (cacheName != null && server != null)
            {
               //cache = (TreeCacheMBean) MBeanProxyExt.create(TreeCacheMBean.class, cacheName, server);
  -            cache = (TreeCache) MBeanServerInvocationHandler.newProxyInstance(server, cacheName, TreeCache.class, false);
  -            //cache = (TreeCache) MBeanProxyExt.create(TreeCache.class, cacheName, server);
  +            cache = (CacheImpl) MBeanServerInvocationHandler.newProxyInstance(server, cacheName, CacheImpl.class, false);
  +            //cache = (CacheImpl) MBeanProxyExt.create(CacheImpl.class, cacheName, server);
            }
         }
   
         if (cache == null)
         {
  -         cache = new TreeCache();
  +         cache = new CacheImpl();
            cache.setConfiguration(new XmlConfigurationParser().parseFile(configFile));
            cache.start(); // kick start tree cache
         }
  
  
  
  1.9       +4 -4      JBossCache/src/org/jboss/cache/loader/rmi/RemoteTreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoteTreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/rmi/RemoteTreeCache.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- RemoteTreeCache.java	22 Sep 2006 16:27:56 -0000	1.8
  +++ RemoteTreeCache.java	30 Dec 2006 17:50:00 -0000	1.9
  @@ -7,7 +7,7 @@
   package org.jboss.cache.loader.rmi;
   
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.NodeImpl;
  +import org.jboss.cache.Node;
   
   import java.rmi.Remote;
   import java.rmi.RemoteException;
  @@ -15,11 +15,11 @@
   import java.util.Set;
   
   /**
  - * Remote interface to a {@link org.jboss.cache.TreeCache} instance. Used by
  + * Remote interface to a {@link org.jboss.cache.CacheImpl} instance. Used by
    * {@link org.jboss.cache.loader.RmiDelegatingCacheLoader}.
    *
    * @author Daniel Gredler
  - * @version $Id: RemoteTreeCache.java,v 1.8 2006/09/22 16:27:56 msurtani Exp $
  + * @version $Id: RemoteTreeCache.java,v 1.9 2006/12/30 17:50:00 msurtani Exp $
    */
   public interface RemoteTreeCache extends Remote
   {
  @@ -27,7 +27,7 @@
   
      public Object get(Fqn name, Object key) throws Exception, RemoteException;
   
  -   public NodeImpl get(Fqn name) throws Exception, RemoteException;
  +   public Node get(Fqn name) throws Exception, RemoteException;
   
      public boolean exists(Fqn name) throws Exception, RemoteException;
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:00 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:00 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/buddyreplication ...
Message-ID: <E1H0iLI-0008U1-VC@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:00

  Modified:    tests/functional/org/jboss/cache/buddyreplication          
                        BuddyReplicationFailoverTest.java
                        BuddyBackupActivationInactivationTest.java
                        BuddyReplicationContentTest.java
                        BuddyAssignmentStateTransferTest.java
                        BuddyGroupAssignmentTest.java
                        BuddyReplicationConfigTest.java
                        BuddyReplicationWithTransactionsTest.java
                        BuddyReplicationTestsBase.java
                        BuddyPoolBroadcastTest.java
                        BuddyReplicationWithCacheLoaderTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.19      +2 -2      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationFailoverTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationFailoverTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationFailoverTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- BuddyReplicationFailoverTest.java	10 Nov 2006 20:32:52 -0000	1.18
  +++ BuddyReplicationFailoverTest.java	30 Dec 2006 17:50:00 -0000	1.19
  @@ -6,8 +6,8 @@
    */
   package org.jboss.cache.buddyreplication;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
   
   /**
  @@ -20,7 +20,7 @@
      protected boolean optimisticLocks = false;
      private String key = "key";
      private String value = "value";
  -   private TreeCache[] caches;
  +   private CacheImpl[] caches;
   
      protected void tearDown() throws Exception
      {
  
  
  
  1.13      +30 -31    JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyBackupActivationInactivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- BuddyBackupActivationInactivationTest.java	25 Oct 2006 04:50:21 -0000	1.12
  +++ BuddyBackupActivationInactivationTest.java	30 Dec 2006 17:50:00 -0000	1.13
  @@ -6,11 +6,10 @@
    */
   package org.jboss.cache.buddyreplication;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
  -import org.jboss.cache.misc.TestingUtil;
   import org.w3c.dom.Document;
   import org.w3c.dom.Element;
   
  @@ -40,7 +39,7 @@
         /** TODO: Uncomment once we have FLUSH in place
          *
   
  -      TreeCache[] caches = new TreeCache[2];
  +       CacheImpl[] caches = new CacheImpl[2];
         caches[0] = createCache("cache1", true, true, true);
         caches[1] = createCache("cache2", true, true, true);
   
  @@ -70,7 +69,7 @@
         // was removed, presuming FLUSH will fix this.  Need to test with FLUSH.
         // - Manik Surtani (16 Oct 2006)
         /*
  -      TreeCache[] caches = new TreeCache[2];
  +      CacheImpl[] caches = new CacheImpl[2];
         caches[0] = createCache("cache1", true, true, true);
         caches[1] = createCache("cache2", true, true, true);
   
  @@ -104,7 +103,7 @@
         // was removed, presuming FLUSH will fix this.  Need to test with FLUSH.
         // - Manik Surtani (16 Oct 2006)
   /*
  -      TreeCache cache1 = createCache("cache1", true, true, true);
  +      CacheImpl cache1 = createCache("cache1", true, true, true);
   
         cache1.activateRegion("/a");
   
  @@ -122,7 +121,7 @@
   
      }
   
  -   protected TreeCache createCache(String cacheID,
  +   protected CacheImpl createCache(String cacheID,
                                      boolean sync,
                                      boolean useMarshalling,
                                      boolean startCache)
  @@ -131,29 +130,29 @@
         if (caches.get(cacheID) != null)
            throw new IllegalStateException(cacheID + " already created");
   
  -      TreeCache tree = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
   
         String configFile = sync ? "META-INF/replSync-service.xml"
                 : "META-INF/replAsync-service.xml";
  -      tree.setConfiguration(new XmlConfigurationParser().parseFile(configFile));
  -      tree.getConfiguration().setClusterName("Test");
  +      cache.setConfiguration(new XmlConfigurationParser().parseFile(configFile));
  +      cache.getConfiguration().setClusterName("Test");
         if (useMarshalling)
         {
  -         tree.getConfiguration().setUseRegionBasedMarshalling(true);
  -         tree.getConfiguration().setInactiveOnStartup(true);
  +         cache.getConfiguration().setUseRegionBasedMarshalling(true);
  +         cache.getConfiguration().setInactiveOnStartup(true);
         }
  -      tree.getConfiguration().setBuddyReplicationConfig(getBuddyConfig());
  +      cache.getConfiguration().setBuddyReplicationConfig(getBuddyConfig());
         // Put the cache in the map before starting, so if it fails in
         // start it can still be destroyed later
  -      caches.put(cacheID, tree);
  +      caches.put(cacheID, cache);
   
         if (startCache)
         {
  -         tree.create();
  -         tree.start();
  +         cache.create();
  +         cache.start();
         }
   
  -      return tree;
  +      return cache;
      }
   
      protected void setUp() throws Exception
  @@ -178,11 +177,11 @@
         cacheIDs = (String[]) keys.toArray(cacheIDs);
         for (int i = 0; i < cacheIDs.length; i++)
         {
  -         stopCache((TreeCache) caches.get(cacheIDs[i]));
  +         stopCache((CacheImpl) caches.get(cacheIDs[i]));
         }
      }
   
  -   protected void stopCache(TreeCache cache)
  +   protected void stopCache(CacheImpl cache)
      {
         if (cache != null)
         {
  
  
  
  1.14      +7 -7      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationContentTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationContentTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationContentTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- BuddyReplicationContentTest.java	20 Nov 2006 03:53:56 -0000	1.13
  +++ BuddyReplicationContentTest.java	30 Dec 2006 17:50:00 -0000	1.14
  @@ -8,7 +8,7 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.misc.TestingUtil;
   
   /**
  @@ -20,16 +20,16 @@
   {
      private String key = "key";
      private String value = "value";
  -   private TreeCache[] caches;
  +   private CacheImpl[] caches;
      private Log log = LogFactory.getLog(BuddyGroupAssignmentTest.class);
   
   
  -   private void assertNoStaleLocks(TreeCache[] caches)
  +   private void assertNoStaleLocks(CacheImpl[] caches)
      {
  -      for (TreeCache cache : caches) assertNoStaleLocks(cache);
  +      for (CacheImpl cache : caches) assertNoStaleLocks(cache);
      }
   
  -   private void assertNoStaleLocks(TreeCache cache)
  +   private void assertNoStaleLocks(CacheImpl cache)
      {
         assertEquals("Number of locks in cache instance " + cache.toString(true) + " should be 0", 0, cache.getNumberOfLocksHeld());
      }
  @@ -171,7 +171,7 @@
      {
         log.debug("Running testBuddyJoin");
         caches = createCaches(2, false);
  -      TreeCache cache2 = null;
  +      CacheImpl cache2 = null;
   
         try
         {
  
  
  
  1.10      +6 -6      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyAssignmentStateTransferTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyAssignmentStateTransferTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyAssignmentStateTransferTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- BuddyAssignmentStateTransferTest.java	18 Oct 2006 11:07:54 -0000	1.9
  +++ BuddyAssignmentStateTransferTest.java	30 Dec 2006 17:50:00 -0000	1.10
  @@ -6,8 +6,8 @@
    */
   package org.jboss.cache.buddyreplication;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.misc.TestingUtil;
   
   import java.io.File;
  @@ -29,7 +29,7 @@
   
      public void testNonRegionBasedStateTransfer() throws Exception
      {
  -      TreeCache[] caches = new TreeCache[2];
  +      CacheImpl[] caches = new CacheImpl[2];
         try
         {
            caches[0] = createCache(1, "TEST", false, true);
  @@ -48,8 +48,8 @@
   
            assertEquals("State transferred", "Joe", caches[1].get(test, "name"));
   
  -         TreeCache[] old = caches;
  -         caches = new TreeCache[3];
  +         CacheImpl[] old = caches;
  +         caches = new CacheImpl[3];
            System.arraycopy(old, 0, caches, 0, old.length);
            caches[2] = createCache(1, "TEST", false, true);
   
  @@ -81,7 +81,7 @@
         // was removed, presuming FLUSH will fix this.  Need to test with FLUSH.
         // - Manik Surtani (16 Oct 2006)
         /*
  -      TreeCache[] caches = new TreeCache[3];
  +      CacheImpl[] caches = new CacheImpl[3];
   
         try
         {
  @@ -146,7 +146,7 @@
         tmpLoc += File.separator + "BuddyReplicationTestsBase-";
         String tmpLoc0 = tmpLoc + 0;
         String tmpLoc1 = tmpLoc + 1;
  -      TreeCache[] caches = new TreeCache[2];
  +      CacheImpl[] caches = new CacheImpl[2];
   
         try
         {
  
  
  
  1.14      +3 -3      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyGroupAssignmentTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyGroupAssignmentTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyGroupAssignmentTest.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- BuddyGroupAssignmentTest.java	21 Dec 2006 16:19:33 -0000	1.13
  +++ BuddyGroupAssignmentTest.java	30 Dec 2006 17:50:00 -0000	1.14
  @@ -8,7 +8,7 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.misc.TestingUtil;
   
   /**
  @@ -18,7 +18,7 @@
    */
   public class BuddyGroupAssignmentTest extends BuddyReplicationTestsBase
   {
  -   private TreeCache[] caches;
  +   private CacheImpl[] caches;
      private Log log = LogFactory.getLog(BuddyGroupAssignmentTest.class);
   
      protected void setUp() throws Exception
  @@ -42,7 +42,7 @@
         log.debug("Running testSingleBuddy");
         caches = createCaches(3, false);
   
  -      for (TreeCache cache : caches)
  +      for (CacheImpl cache : caches)
         {
            printBuddyGroup(cache);
         }
  
  
  
  1.12      +6 -6      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationConfigTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationConfigTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationConfigTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- BuddyReplicationConfigTest.java	4 Nov 2006 22:03:24 -0000	1.11
  +++ BuddyReplicationConfigTest.java	30 Dec 2006 17:50:00 -0000	1.12
  @@ -7,7 +7,7 @@
   package org.jboss.cache.buddyreplication;
   
   import junit.framework.TestCase;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -17,7 +17,7 @@
   import org.w3c.dom.Element;
   
   /**
  - * Tests basic configuration options by passing stuff into the TreeCache.
  + * Tests basic configuration options by passing stuff into the CacheImpl.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  @@ -25,7 +25,7 @@
   {
      public void testNullConfig() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setBuddyReplicationConfig(null);
         assertNull(cache.getBuddyManager());
      }
  @@ -35,7 +35,7 @@
         String xmlConfig = "<config><buddyReplicationEnabled>false</buddyReplicationEnabled></config>";
         Element element = XmlHelper.stringToElement(xmlConfig);
         BuddyReplicationConfig config = XmlConfigurationParser.parseBuddyReplicationConfig(element);
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setBuddyReplicationConfig(config);
         assertNull(cache.getBuddyManager());
      }
  @@ -45,7 +45,7 @@
         String xmlConfig = "<config><buddyReplicationEnabled>true</buddyReplicationEnabled></config>";
         Element element = XmlHelper.stringToElement(xmlConfig);
         BuddyReplicationConfig config = XmlConfigurationParser.parseBuddyReplicationConfig(element);
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         cache.getConfiguration().setBuddyReplicationConfig(config);
         cache.create();
  @@ -61,7 +61,7 @@
   
      public void testXmlConfig() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/buddyreplication-service.xml"));
         cache.create();
         BuddyManager bm = cache.getBuddyManager();
  
  
  
  1.5       +2 -2      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationWithTransactionsTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationWithTransactionsTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationWithTransactionsTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- BuddyReplicationWithTransactionsTest.java	10 Nov 2006 20:32:52 -0000	1.4
  +++ BuddyReplicationWithTransactionsTest.java	30 Dec 2006 17:50:00 -0000	1.5
  @@ -6,8 +6,8 @@
    */
   package org.jboss.cache.buddyreplication;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import javax.transaction.TransactionManager;
   
  @@ -20,7 +20,7 @@
      private Fqn fqn = Fqn.fromString("test");
      private String key = "key";
      private String value = "value";
  -   private TreeCache[] caches;
  +   private CacheImpl[] caches;
   
      protected void tearDown() throws Exception
      {
  
  
  
  1.34      +26 -26    JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationTestsBase.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- BuddyReplicationTestsBase.java	21 Dec 2006 16:19:33 -0000	1.33
  +++ BuddyReplicationTestsBase.java	30 Dec 2006 17:50:00 -0000	1.34
  @@ -7,8 +7,8 @@
   package org.jboss.cache.buddyreplication;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
  @@ -31,34 +31,34 @@
   {
      protected static int VIEW_BLOCK_TIMEOUT = 5000;
   
  -   protected TreeCache createCache(int numBuddies, String buddyPoolName) throws Exception
  +   protected CacheImpl createCache(int numBuddies, String buddyPoolName) throws Exception
      {
         return createCache(numBuddies, buddyPoolName, false, true);
      }
   
  -   protected TreeCache createCache(int numBuddies, String buddyPoolName, boolean useDataGravitation) throws Exception
  +   protected CacheImpl createCache(int numBuddies, String buddyPoolName, boolean useDataGravitation) throws Exception
      {
         return createCache(numBuddies, buddyPoolName, useDataGravitation, true);
      }
   
  -   protected TreeCache createCache(int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean start) throws Exception
  +   protected CacheImpl createCache(int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean start) throws Exception
      {
         return createCache(false, numBuddies, buddyPoolName, useDataGravitation, true, start);
      }
   
  -   protected TreeCache createCache(boolean optimisticLocks, int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean start) throws Exception
  +   protected CacheImpl createCache(boolean optimisticLocks, int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean start) throws Exception
      {
         return createCache(optimisticLocks, numBuddies, buddyPoolName, useDataGravitation, true, start);
      }
   
  -   protected TreeCache createCache(int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean removeOnFind, boolean start) throws Exception
  +   protected CacheImpl createCache(int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean removeOnFind, boolean start) throws Exception
      {
         return createCache(false, numBuddies, buddyPoolName, useDataGravitation, removeOnFind, start);
      }
   
  -   protected TreeCache createCache(boolean optimisticLocks, int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean removeOnFind, boolean start) throws Exception
  +   protected CacheImpl createCache(boolean optimisticLocks, int numBuddies, String buddyPoolName, boolean useDataGravitation, boolean removeOnFind, boolean start) throws Exception
      {
  -      TreeCache c = new TreeCache();
  +      CacheImpl c = new CacheImpl();
         c.getConfiguration().setCacheMode("REPL_SYNC");
         c.getConfiguration().setClusterName("BuddyReplicationTest");
         // basic config
  @@ -88,32 +88,32 @@
         return c;
      }
   
  -   protected TreeCache[] createCaches(int numCaches, boolean useBuddyPool) throws Exception
  +   protected CacheImpl[] createCaches(int numCaches, boolean useBuddyPool) throws Exception
      {
         return createCaches(1, numCaches, useBuddyPool, false);
      }
   
  -   protected TreeCache[] createCaches(int numCaches, boolean useBuddyPool, boolean useDataGravitation, boolean optimisticLocks) throws Exception
  +   protected CacheImpl[] createCaches(int numCaches, boolean useBuddyPool, boolean useDataGravitation, boolean optimisticLocks) throws Exception
      {
         return createCaches(1, numCaches, useBuddyPool, useDataGravitation, optimisticLocks);
      }
   
  -   protected TreeCache[] createCaches(int numCaches, boolean useBuddyPool, boolean useDataGravitation) throws Exception
  +   protected CacheImpl[] createCaches(int numCaches, boolean useBuddyPool, boolean useDataGravitation) throws Exception
      {
         return createCaches(1, numCaches, useBuddyPool, useDataGravitation);
      }
   
  -   protected TreeCache[] createCachesWithCacheLoader(int numCaches, boolean useDataGravitation, boolean removeOnFind, boolean passivation) throws Exception
  +   protected CacheImpl[] createCachesWithCacheLoader(int numCaches, boolean useDataGravitation, boolean removeOnFind, boolean passivation) throws Exception
      {
         return this.createCachesWithCacheLoader(numCaches, useDataGravitation, removeOnFind, passivation, false);
      }
   
  -   protected TreeCache[] createCachesWithCacheLoader(int numCaches, boolean useDataGravitation, boolean removeOnFind, boolean passivation, boolean fetchPersistent) throws Exception
  +   protected CacheImpl[] createCachesWithCacheLoader(int numCaches, boolean useDataGravitation, boolean removeOnFind, boolean passivation, boolean fetchPersistent) throws Exception
      {
         String tmpLoc = System.getProperty("java.io.tmpdir", "/tmp");
         tmpLoc += File.separator + "BuddyReplicationTestsBase-";
   
  -      TreeCache[] caches = new TreeCache[numCaches];
  +      CacheImpl[] caches = new CacheImpl[numCaches];
         for (int i = 0; i < numCaches; i++)
         {
            caches[i] = createCacheWithCacheLoader((tmpLoc + i), useDataGravitation, removeOnFind, passivation, fetchPersistent, true);
  @@ -125,9 +125,9 @@
         return caches;
      }
   
  -   protected TreeCache createCacheWithCacheLoader(String location, boolean useDataGravitation, boolean removeOnFind, boolean passivation, boolean fetchPersistent, boolean start) throws Exception
  +   protected CacheImpl createCacheWithCacheLoader(String location, boolean useDataGravitation, boolean removeOnFind, boolean passivation, boolean fetchPersistent, boolean start) throws Exception
      {
  -      TreeCache cache = createCache(1, null, useDataGravitation, removeOnFind, false);
  +      CacheImpl cache = createCache(1, null, useDataGravitation, removeOnFind, false);
   
         String cloader = "<config>\n" +
                 "<passivation>" + passivation + "</passivation>\n" +
  @@ -151,19 +151,19 @@
         return cache;
      }
   
  -   protected TreeCache[] createCaches(int numBuddies, int numCaches, boolean useBuddyPool) throws Exception
  +   protected CacheImpl[] createCaches(int numBuddies, int numCaches, boolean useBuddyPool) throws Exception
      {
         return createCaches(numBuddies, numCaches, useBuddyPool, false);
      }
   
  -   protected TreeCache[] createCaches(int numBuddies, int numCaches, boolean useBuddyPool, boolean useDataGravitation) throws Exception
  +   protected CacheImpl[] createCaches(int numBuddies, int numCaches, boolean useBuddyPool, boolean useDataGravitation) throws Exception
      {
         return createCaches(numBuddies, numCaches, useBuddyPool, useDataGravitation, false);
      }
   
  -   protected TreeCache[] createCaches(int numBuddies, int numCaches, boolean useBuddyPool, boolean useDataGravitation, boolean optimisticLocks) throws Exception
  +   protected CacheImpl[] createCaches(int numBuddies, int numCaches, boolean useBuddyPool, boolean useDataGravitation, boolean optimisticLocks) throws Exception
      {
  -      TreeCache[] caches = new TreeCache[numCaches];
  +      CacheImpl[] caches = new CacheImpl[numCaches];
         for (int i = 0; i < numCaches; i++)
         {
            caches[i] = createCache(optimisticLocks, numBuddies, useBuddyPool ? Character.toString((char) ('A' + i)) : null, useDataGravitation, true);
  @@ -175,7 +175,7 @@
         return caches;
      }
   
  -   protected void cleanup(TreeCache[] caches) throws Exception
  +   protected void cleanup(CacheImpl[] caches) throws Exception
      {
         System.out.println("*** cleaning up");
   
  @@ -192,7 +192,7 @@
         }
      }
   
  -   private void destroyCache(TreeCache c) throws Exception
  +   private void destroyCache(CacheImpl c) throws Exception
      {
         TransactionManager tm = c.getTransactionManager();
         if (tm != null && tm.getTransaction() != null)
  @@ -210,7 +210,7 @@
         c.stop();
      }
   
  -   protected void printBuddyGroup(TreeCache cache)
  +   protected void printBuddyGroup(CacheImpl cache)
      {
         BuddyGroup bg = cache.getBuddyManager().buddyGroup;
         System.out.println("*** " + bg);
  @@ -225,7 +225,7 @@
         return 1000;
      }
   
  -   protected void assertIsBuddy(TreeCache dataOwner, TreeCache buddy, boolean onlyBuddy)
  +   protected void assertIsBuddy(CacheImpl dataOwner, CacheImpl buddy, boolean onlyBuddy)
      {
         Address dataOwnerLocalAddress = (Address) dataOwner.getLocalAddress();
         Address buddyLocalAddress = (Address) buddy.getLocalAddress();
  @@ -250,7 +250,7 @@
         assertTrue(buddyLocalAddress + " should be a buddy to " + group.getGroupName(), group.getBuddies().contains(buddyLocalAddress));
      }
   
  -   protected void dumpCacheContents(TreeCache[] caches)
  +   protected void dumpCacheContents(CacheImpl[] caches)
      {
         System.out.println("**** START: Cache Contents ****");
         for (int i = 0; i < caches.length; i++)
  @@ -266,7 +266,7 @@
         System.out.println("**** END: Cache Contents ****");
      }
   
  -   protected void assertNoLocks(TreeCache[] caches)
  +   protected void assertNoLocks(CacheImpl[] caches)
      {
         for (int i = 0; i < caches.length; i++)
         {
  
  
  
  1.17      +7 -7      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyPoolBroadcastTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- BuddyPoolBroadcastTest.java	21 Dec 2006 17:59:01 -0000	1.16
  +++ BuddyPoolBroadcastTest.java	30 Dec 2006 17:50:00 -0000	1.17
  @@ -9,7 +9,7 @@
   import EDU.oswego.cs.dl.util.concurrent.Latch;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.misc.TestingUtil;
   
   import java.util.Map;
  @@ -22,10 +22,10 @@
   public class BuddyPoolBroadcastTest extends BuddyReplicationTestsBase
   {
   
  -   private TreeCache[] caches;
  +   private CacheImpl[] caches;
      private Log log = LogFactory.getLog(BuddyPoolBroadcastTest.class);
   
  -   private void checkConsistentPoolState(TreeCache[] caches)
  +   private void checkConsistentPoolState(CacheImpl[] caches)
      {
         for (int i = 0; i < caches.length; i++)
         {
  @@ -35,7 +35,7 @@
               if (i != j)
               {
                  Map groupMap2 = caches[j].getBuddyManager().buddyPool;
  -               for (TreeCache cache : caches)
  +               for (CacheImpl cache : caches)
                  {
                     assertEquals("Comparing contents of cache " + (i + 1) + " pool map with cache " + (j + 1), groupMap.get(cache), groupMap2.get(cache));
                  }
  @@ -136,7 +136,7 @@
      {
         log.debug("Running testConcurrency");
         int numCaches = 15;
  -      caches = new TreeCache[numCaches];
  +      caches = new CacheImpl[numCaches];
         Latch latch = new Latch();
         CacheStarter[] starters = new CacheStarter[numCaches];
   
  @@ -169,9 +169,9 @@
      public class CacheStarter extends Thread
      {
         private Latch latch;
  -      private TreeCache cache;
  +      private CacheImpl cache;
   
  -      public CacheStarter(Latch latch, TreeCache cache)
  +      public CacheStarter(Latch latch, CacheImpl cache)
         {
            this.latch = latch;
            this.cache = cache;
  
  
  
  1.6       +4 -4      JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationWithCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyReplicationWithCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationWithCacheLoaderTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- BuddyReplicationWithCacheLoaderTest.java	10 Nov 2006 20:32:52 -0000	1.5
  +++ BuddyReplicationWithCacheLoaderTest.java	30 Dec 2006 17:50:00 -0000	1.6
  @@ -6,8 +6,8 @@
    */
   package org.jboss.cache.buddyreplication;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.misc.TestingUtil;
   
  @@ -24,7 +24,7 @@
      protected String value = "value";
      protected boolean passivation = false;
   
  -   private CacheLoader[] getLoaders(TreeCache[] caches)
  +   private CacheLoader[] getLoaders(CacheImpl[] caches)
      {
         CacheLoader[] retVal = new CacheLoader[caches.length];
   
  @@ -39,7 +39,7 @@
      public void testWithDataGravitationDefault() throws Exception
      {
   
  -      TreeCache[] caches = null;
  +      CacheImpl[] caches = null;
         try
         {
            // create 3 caches
  @@ -127,7 +127,7 @@
   
      public void testWithDataGravitationEviction() throws Exception
      {
  -      TreeCache[] caches = null;
  +      CacheImpl[] caches = null;
         try
         {
            // create 3 caches
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:01 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:01 -0500
Subject: [jboss-cvs] JBossCache/etc    ...
Message-ID: <E1H0iLJ-0008UP-4B@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:01

  Modified:    etc      tree-service.xml build.xml
                        jdbcCacheLoader-service.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.11      +183 -184  JBossCache/etc/tree-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: tree-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/tree-service.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- tree-service.xml	24 May 2006 19:56:15 -0000	1.10
  +++ tree-service.xml	30 Dec 2006 17:50:01 -0000	1.11
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -79,7 +79,7 @@
           <!-- Name of cluster. Needs to be the same for all clusters, in order
                to find each other
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
           <!-- JGroups protocol stack properties. Can also be a URL,
                e.g. file:/home/bela/default.xml
  @@ -219,5 +219,4 @@
      <!--   </mbean>-->
   
   
  -
   </server>
  
  
  
  1.19      +266 -265  JBossCache/etc/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/build.xml,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- build.xml	6 Dec 2006 15:46:09 -0000	1.18
  +++ build.xml	30 Dec 2006 17:50:01 -0000	1.19
  @@ -1,9 +1,10 @@
   <?xml version="1.0"?>
   
  -<project name="junit examples" default="help" >
  +<project name="junit examples" default="help">
   
     <property name="build.sysclasspath" value="ignore"/>
  -  <property name="junit.timeout" value="180000"/> <!-- 3 minutes -->
  +   <property name="junit.timeout" value="180000"/>
  +   <!-- 3 minutes -->
   
     <property file="./build.properties"/>
   
  @@ -13,24 +14,24 @@
     <!-- set local properties for this build -->
      <path id="lib.classpath">
          <fileset dir="${lib}">
  -         <include name="**/*.jar" />
  +         <include name="**/*.jar"/>
          </fileset>
      </path>
   
      <!-- Used for aop classloading and aopc -->
      <path id="aop.classpath">
          <fileset dir="${lib}">
  -          <include name="*.jar" />
  -          <exclude name="jboss-cache.jar" />
  -          <exclude name="**/j*unit.jar" />
  +         <include name="*.jar"/>
  +         <exclude name="jboss-cache.jar"/>
  +         <exclude name="**/j*unit.jar"/>
             <!-- exclude name="**/jgroups.jar" /-->
  -          <exclude name="**/bsh*.jar" />
  +         <exclude name="**/bsh*.jar"/>
          </fileset>
      </path>
   
      <path id="cache.classpath">
          <fileset dir="${lib}">
  -         <include name="**/jboss-cache.jar" />
  +         <include name="**/jboss-cache.jar"/>
          </fileset>
      </path>
   
  @@ -39,15 +40,15 @@
      </path>
   
     <target name="help" description="help page">
  -      <echo message="build.sh &lt;command&gt; where command is:" />
  -      <echo message="         compile       -- compile the examples code" />
  -      <echo message="         clobber       -- clean up the whole directory" />
  -      <echo message="         run.batch     -- run batch examples" />
  -      <echo message="         one.test      -- run one single test case. Need -Dtest=org.jboss.cache.??Test" />
  -      <echo message="         one.test.pojo  -- run one single PojoCache test case. Need -Dtest=org.jboss.cache.pojo.??Test" />
  -      <echo message="         run.pojocache.batch -- run batch pojocache examples" />
  -      <echo message="         run.demo      -- run demo gui for plain cache" />
  -      <echo message="         run.pojocache.demo  -- run demo gui for pojocache cache" />
  +      <echo message="build.sh &lt;command&gt; where command is:"/>
  +      <echo message="         compile       -- compile the examples code"/>
  +      <echo message="         clobber       -- clean up the whole directory"/>
  +      <echo message="         run.batch     -- run batch examples"/>
  +      <echo message="         one.test      -- run one single test case. Need -Dtest=org.jboss.cache.??Test"/>
  +      <echo message="         one.test.pojo  -- run one single PojoCache test case. Need -Dtest=org.jboss.cache.pojo.??Test"/>
  +      <echo message="         run.pojocache.batch -- run batch pojocache examples"/>
  +      <echo message="         run.demo      -- run demo gui for plain cache"/>
  +      <echo message="         run.pojocache.demo  -- run demo gui for pojocache cache"/>
     </target>
   
     <!-- set up directory -->
  @@ -55,7 +56,7 @@
       <!-- Create the time stamp -->
       <tstamp/>
       <!-- Create the build directory structure used by compile
  -    and copy the deployment descriptors into it-->
  +and copy the deployment descriptors into it-->
        <mkdir dir="${build}"/>
       <mkdir dir="${reports}"/>
     </target>
  @@ -64,7 +65,7 @@
       <delete dir="${output}"/>
     </target>
   
  -  <target name="clobber" depends="clean" />
  +   <target name="clobber" depends="clean"/>
   
     <!-- compile directory -->
      <target name="compile" depends="compile-50" description="Compiles all Java files">
  @@ -77,7 +78,7 @@
               debug="true"
               deprecation="true">
          <classpath>
  -         <path refid="lib.classpath" />
  +            <path refid="lib.classpath"/>
          </classpath>
        </javac>
   
  @@ -105,13 +106,13 @@
   
      <!-- eg. ant run.examples -Dtest=org.jboss.test.cache.test.local.NoTxUnitTestCase -->
      <target name="one.test" depends="compile" description="run one junit test case.">
  -     <junit printsummary="true" fork="yes" >
  -       <classpath refid="lib.classpath" />
  -       <classpath path="${build}" />
  -       <classpath path="${output}/etc" />
  -       <formatter type="xml" />
  +      <junit printsummary="true" fork="yes">
  +         <classpath refid="lib.classpath"/>
  +         <classpath path="${build}"/>
  +         <classpath path="${output}/etc"/>
  +         <formatter type="xml"/>
          <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -       <test name="${test}" todir="${reports}" />
  +         <test name="${test}" todir="${reports}"/>
    <!--
          <jvmarg value="-Xdebug"/>
          <jvmarg value="-Xnoagent"/>
  @@ -122,7 +123,7 @@
   
         <junitreport todir="${reports}">
            <fileset dir="${reports}">
  -            <include name="TEST-*.xml" />
  +            <include name="TEST-*.xml"/>
            </fileset>
            <report format="frames" todir="${reports}/html"/>
         </junitreport>
  @@ -131,16 +132,16 @@
     <target name="run.batch" depends="compile" description="run junit test cases.">
       <junit printsummary="true"
         timeout="${junit.timeout}"
  -      fork="yes" >
  +             fork="yes">
         <jvmarg value="-Xmx128M"/>
  -<!--
  +         <!--
         <jvmarg value="-Dbind.address=172.16.129.57"/>
  --->
  -      <classpath refid="lib.classpath" />
  -      <classpath path="${build}" />
  -      <classpath path="${output}/etc" />
  +         -->
  +         <classpath refid="lib.classpath"/>
  +         <classpath path="${build}"/>
  +         <classpath path="${output}/etc"/>
         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -      <formatter type="xml" />
  +         <formatter type="xml"/>
   
         <batchtest todir="${reports}"
                    haltonerror="no"
  @@ -157,78 +158,78 @@
   
       <junitreport todir="${reports}">
          <fileset dir="${reports}">
  -          <include name="TEST-*.xml" />
  +            <include name="TEST-*.xml"/>
          </fileset>
          <report format="frames" todir="${reports}/html"/>
       </junitreport>
     </target>
   
  -  <target name="run.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.demo" depends="compile" description="run JBoss Cache demo.">
       <java classname="org.jboss.cache.TreeCacheView2" fork="yes">
         <jvmarg value="-Xmx128M"/>
  -      <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -      <classpath path="${output}/etc" />
  -      <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
       </java>
     </target>
   
   
  -   <target name="run.demo.async" depends="compile" description="run tree cache demo.">
  +   <target name="run.demo.async" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.TreeCacheView2" fork="yes">
         <jvmarg value="-Xmx128M"/>
           <arg value="-config"/>
           <arg value="META-INF/replAsync-service.xml"/>
  -       <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
          <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -       <classpath path="${output}/etc" />
  -       <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
        </java>
      </target>
   
   
  -   <target name="run.demo.async.shared.cacheloader" depends="compile" description="run tree cache demo.">
  +   <target name="run.demo.async.shared.cacheloader" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.TreeCacheView2" fork="yes">
            <jvmarg value="-Xmx128M"/>
            <arg value="-config"/>
            <arg value="META-INF/replAsyncSharedCacheLoader-service.xml"/>
  -         <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
            <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -         <classpath path="${output}/etc" />
  -         <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
         </java>
      </target>
   
   
  -   <target name="run.demo.unshared.node1" depends="compile" description="run tree cache demo.">
  +   <target name="run.demo.unshared.node1" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.TreeCacheView2" fork="yes">
            <jvmarg value="-Xmx128M"/>
            <arg value="-config"/>
            <arg value="META-INF/node1.xml"/>
  -         <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
            <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -         <classpath path="${output}/etc" />
  -         <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
         </java>
      </target>
   
  -   <target name="run.demo.unshared.node2" depends="compile" description="run tree cache demo.">
  +   <target name="run.demo.unshared.node2" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.TreeCacheView2" fork="yes">
            <jvmarg value="-Xmx128M"/>
            <arg value="-config"/>
            <arg value="META-INF/node2.xml"/>
  -         <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
            <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -         <classpath path="${output}/etc" />
  -         <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
         </java>
      </target>
   
     <target name="run.server" depends="compile" description="run standalone server replicator.">
  -    <java classname="org.jboss.cache.Server" fork="yes" >
  -      <classpath refid="lib.classpath" />
  -      <classpath path="${build}" />
  -      <classpath path="${output}/etc" />
  +      <java classname="org.jboss.cache.Server" fork="yes">
  +         <classpath refid="lib.classpath"/>
  +         <classpath path="${build}"/>
  +         <classpath path="${output}/etc"/>
       </java>
     </target>
   
  @@ -277,8 +278,8 @@
              <jvmarg value="-Djboss.aop.path=${output}/resources/pojocache-aop.xml"/>
              <jvmarg value="-javaagent:${lib}/jboss-aop-jdk50.jar"/>
              <!-- jvmarg value="-Dbind.address=${bind.address}"/ -->
  -           <classpath path="${output}/etc" />
  -           <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml" />
  +         <classpath path="${output}/etc"/>
  +         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
              <classpath refid="lib.classpath"/>
              <classpath path="${build}"/>
              <formatter type="xml" usefile="true"/>
  @@ -287,7 +288,7 @@
   
      <junitreport todir="${reports}">
         <fileset dir="${reports}">
  -         <include name="TEST-*.xml" />
  +            <include name="TEST-*.xml"/>
         </fileset>
         <report format="frames" todir="${reports}/html"/>
      </junitreport>
  @@ -299,8 +300,8 @@
           <jvmarg value="-Djboss.aop.path=${output}/resources/pojocache-aop.xml"/>
           <jvmarg value="-javaagent:${lib}/jboss-aop-jdk50.jar"/>
           <!-- jvmarg value="-Dbind.address=${bind.address}"/ -->
  -        <classpath path="${output}/etc" />
  -        <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml" />
  +         <classpath path="${output}/etc"/>
  +         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
           <classpath refid="lib.classpath"/>
           <classpath refid="build.classpath"/>
           <formatter type="xml" usefile="true"/>
  @@ -309,27 +310,27 @@
   
         <junitreport todir="${reports}">
            <fileset dir="${reports}">
  -            <include name="TEST-*.xml" />
  +            <include name="TEST-*.xml"/>
            </fileset>
            <report format="frames" todir="${reports}/html"/>
         </junitreport>
    </target>
   
      <target name="one.test.pojocache.aopc" depends="aopc" description="run junit test cases.">
  -     <junit printsummary="true" fork="yes" >
  -       <classpath refid="lib.classpath" />
  -       <classpath refid="build.classpath" />
  +      <junit printsummary="true" fork="yes">
  +         <classpath refid="lib.classpath"/>
  +         <classpath refid="build.classpath"/>
          <jvmarg value="-Djboss.aop.path=${output}/resources/pojocache-aop.xml"/>
  -       <classpath path="${output}/etc" />
  -       <formatter type="xml" />
  +         <classpath path="${output}/etc"/>
  +         <formatter type="xml"/>
          <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -       <test name="${test}" todir="${reports}" />
  +         <test name="${test}" todir="${reports}"/>
          <jvmarg value="-Xmx128M"/>
        </junit>
   
        <junitreport todir="${reports}">
           <fileset dir="${reports}">
  -           <include name="TEST-*.xml" />
  +            <include name="TEST-*.xml"/>
           </fileset>
           <report format="frames" todir="${reports}/html"/>
        </junitreport>
  @@ -340,13 +341,13 @@
     <target name="run.pojocache.batch" depends="aopc" description="run junit test cases.">
       <junit printsummary="true"
         timeout="${junit.timeout}"
  -      fork="yes" >
  +             fork="yes">
         <jvmarg value="-Xmx128M"/>
  -      <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
         <jvmarg value="-Djboss.aop.path=${output}/resources/pojocache-aop.xml"/>
  -      <classpath refid="build.classpath" />
  -      <classpath path="${output}/etc" />
  -      <formatter type="xml" />
  +         <classpath refid="build.classpath"/>
  +         <classpath path="${output}/etc"/>
  +         <formatter type="xml"/>
         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
   
         <batchtest todir="${reports}"
  @@ -363,38 +364,38 @@
   
       <junitreport todir="${reports}">
          <fileset dir="${reports}">
  -          <include name="TEST-*.xml" />
  +            <include name="TEST-*.xml"/>
          </fileset>
          <report format="frames" todir="${reports}/html"/>
       </junitreport>
     </target>
   
  -  <target name="run.pojocache.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.pojocache.demo" depends="compile" description="run JBoss Cache demo.">
       <!--java classname="org.jboss.cache.aop.TreeCacheAopView" fork="yes"-->
         <java classname="org.jboss.cache.TreeCacheView2" fork="yes">
         <jvmarg value="-Xmx128M"/>
  -<!--
  +         <!--
         <jvmarg value="-Xdebug"/>
         <jvmarg value="-Xnoagent"/>
         <jvmarg value="-Djava.compiler=NONE"/>
         <jvmarg value="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=2401"/>
  --->
  +         -->
   
  -      <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -      <classpath path="${output}/etc" />
  -      <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
       </java>
     </target>
   
      <!-- Works only with aop package -->
      <!-- This one uses the system classloader option -->
      <target name="run.aop.server" depends="compile" description="run standalone server replicator.">
  -     <java classname="org.jboss.cache.aop.Server" fork="yes" >
  +      <java classname="org.jboss.cache.aop.Server" fork="yes">
          <jvmarg value="-Djava.system.class.loader=org.jboss.aop.standalone.SystemClassLoader"/>
  -       <classpath refid="lib.classpath" />
  -       <classpath path="${build}" />
  -       <classpath path="${output}/etc" />
  +         <classpath refid="lib.classpath"/>
  +         <classpath path="${build}"/>
  +         <classpath path="${output}/etc"/>
        </java>
      </target>
   
  
  
  
  1.11      +182 -183  JBossCache/etc/jdbcCacheLoader-service.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: jdbcCacheLoader-service.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/etc/jdbcCacheLoader-service.xml,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- jdbcCacheLoader-service.xml	30 May 2006 18:40:24 -0000	1.10
  +++ jdbcCacheLoader-service.xml	30 Dec 2006 17:50:01 -0000	1.11
  @@ -15,7 +15,7 @@
       <!-- Defines TreeCache configuration                                      -->
       <!-- ==================================================================== -->
   
  -    <mbean code="org.jboss.cache.TreeCache"
  +   <mbean code="org.jboss.cache.CacheImpl"
           name="jboss.cache:service=TreeCache">
   
           <depends>jboss:service=Naming</depends>
  @@ -66,7 +66,7 @@
           <!-- Name of cluster. Needs to be the same for all clusters, in order
                to find each other
           -->
  -        <attribute name="ClusterName">TreeCache-Cluster</attribute>
  +      <attribute name="ClusterName">JBossCache-Cluster</attribute>
   
           <!-- JGroups protocol stack properties. Can also be a URL,
                e.g. file:/home/bela/default.xml
  @@ -127,7 +127,7 @@
           <attribute name="EvictionPolicyClass"></attribute>
   
   
  -<!-- Old 1.2.x cache loader config block
  +      <!-- Old 1.2.x cache loader config block
   
          <attribute name="CacheLoaderClass">org.jboss.cache.loader.JDBCCacheLoader</attribute>
          <attribute name="CacheLoaderShared">false</attribute>
  @@ -150,7 +150,7 @@
          </attribute>
   
          <attribute name="CacheLoaderPassivation">false</attribute>
  --->
  +      -->
   
           <!-- Cache Passivation for Tree Cache
   On pasivation, The objects are written to the backend store on eviction if CacheLoaderPassivation
  @@ -210,5 +210,4 @@
      <!--   </mbean>-->
   
   
  -
   </server>
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:01 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:01 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/tcp   ...
Message-ID: <E1H0iLJ-0008Uq-9n@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:01

  Modified:    src/org/jboss/cache/loader/tcp   TcpCacheServer.java
                        TcpCacheServerMBean.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.22      +12 -12    JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpCacheServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServer.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- TcpCacheServer.java	25 Oct 2006 12:49:31 -0000	1.21
  +++ TcpCacheServer.java	30 Dec 2006 17:50:01 -0000	1.22
  @@ -3,10 +3,10 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.jmx.JmxUtil;
   import org.jboss.cache.loader.DelegatingCacheLoader;
  @@ -37,14 +37,14 @@
    * TCP-IP based CacheServer, configure TcpDelegatingCacheLoader with host and port of this server
    *
    * @author Bela Ban
  - * @version $Id: TcpCacheServer.java,v 1.21 2006/10/25 12:49:31 msurtani Exp $
  + * @version $Id: TcpCacheServer.java,v 1.22 2006/12/30 17:50:01 msurtani Exp $
    */
   public class TcpCacheServer implements TcpCacheServerMBean
   {
      ServerSocket srv_sock;
      InetAddress bind_addr = null;
      int port = 7500;
  -   TreeCache cache;
  +   CacheImpl cache;
      //TreeCacheMBean cache;
      ObjectName cache_name;
      String config;
  @@ -107,12 +107,12 @@
      }
   
      //public TreeCacheMBean getCache() {
  -   public TreeCache getCache()
  +   public CacheImpl getCache()
      {
         return cache;
      }
   
  -   public void setCache(TreeCache cache)
  +   public void setCache(CacheImpl cache)
      {
   //public void setCache(TreeCacheMBean cache) {
         this.cache = cache;
  @@ -139,8 +139,8 @@
            // 1. check whether we have an object name, pointing to the cache MBean
            if (cache_name != null && server != null)
            {
  -            //cache = (TreeCache) MBeanProxyExt.create(TreeCache.class, cache_name, server);
  -            cache = (TreeCache) MBeanServerInvocationHandler.newProxyInstance(server, cache_name, TreeCache.class, false);
  +            //cache = (CacheImpl) MBeanProxyExt.create(CacheImpl.class, cache_name, server);
  +            cache = (CacheImpl) MBeanServerInvocationHandler.newProxyInstance(server, cache_name, CacheImpl.class, false);
            }
         }
   
  @@ -148,7 +148,7 @@
         { // still not set
            if (config != null)
            {
  -            cache = new TreeCache();
  +            cache = new CacheImpl();
               cache.setConfiguration(new XmlConfigurationParser().parseFile(this.config));
               cache.create();
               cache.start();
  @@ -256,10 +256,10 @@
         Socket sock = null;
         ObjectInputStream input = null;
         ObjectOutputStream output = null;
  -      TreeCache c;
  +      CacheImpl c;
         Thread t = null;
   
  -      public Connection(Socket sock, TreeCache cache) throws IOException
  +      public Connection(Socket sock, CacheImpl cache) throws IOException
         {
            this.sock = sock;
   
  @@ -314,7 +314,7 @@
            Fqn fqn;
            Object key, val, retval;
            Map map;
  -         DataNode n;
  +         Node n;
            boolean flag;
            byte[] state;
   
  
  
  
  1.5       +4 -4      JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServerMBean.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpCacheServerMBean.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServerMBean.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- TcpCacheServerMBean.java	7 Sep 2006 13:52:28 -0000	1.4
  +++ TcpCacheServerMBean.java	30 Dec 2006 17:50:01 -0000	1.5
  @@ -1,6 +1,6 @@
   package org.jboss.cache.loader.tcp;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.jmx.LifeCycle;
   
   import javax.management.MalformedObjectNameException;
  @@ -8,7 +8,7 @@
   
   /**
    * @author Bela Ban
  - * @version $Id: TcpCacheServerMBean.java,v 1.4 2006/09/07 13:52:28 msurtani Exp $
  + * @version $Id: TcpCacheServerMBean.java,v 1.5 2006/12/30 17:50:01 msurtani Exp $
    */
   public interface TcpCacheServerMBean extends LifeCycle
   {
  @@ -29,9 +29,9 @@
      void setConfig(String config);
   
      //TreeCacheMBean getCache();
  -   TreeCache getCache();
  +   CacheImpl getCache();
   
  -   void setCache(TreeCache cache);
  +   void setCache(CacheImpl cache);
      //void setCache(TreeCacheMBean cache);
   
      String getCacheName();
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:01 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:01 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/options/cachemodelocal ...
Message-ID: <E1H0iLJ-0008Uy-FK@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:01

  Modified:    tests/functional/org/jboss/cache/options/cachemodelocal 
                        CacheModeLocalTestBase.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.8       +5 -5      JBossCache/tests/functional/org/jboss/cache/options/cachemodelocal/CacheModeLocalTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheModeLocalTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/cachemodelocal/CacheModeLocalTestBase.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- CacheModeLocalTestBase.java	7 Sep 2006 15:42:16 -0000	1.7
  +++ CacheModeLocalTestBase.java	30 Dec 2006 17:50:01 -0000	1.8
  @@ -8,8 +8,8 @@
   
   import junit.framework.Assert;
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   
   import javax.transaction.SystemException;
  @@ -34,8 +34,8 @@
       */
      protected boolean isInvalidation;
   
  -   private TreeCache cache1;
  -   private TreeCache cache2;
  +   private CacheImpl cache1;
  +   private CacheImpl cache2;
   
      private Fqn fqn = Fqn.fromString("/a");
      private String key = "key";
  @@ -45,7 +45,7 @@
         // force a tear down if the test runner didn't run one before (happens in IDEA)
         if (cache1 != null || cache2 != null) tearDown();
   
  -      cache1 = new TreeCache();
  +      cache1 = new CacheImpl();
         cache1.getConfiguration().setClusterName("test");
         cache1.getConfiguration().setInitialStateRetrievalTimeout(1000);
         cache1.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  @@ -53,7 +53,7 @@
         cache1.getConfiguration().setCacheMode(cacheMode);
         cache1.start();
   
  -      cache2 = new TreeCache();
  +      cache2 = new CacheImpl();
         cache2.getConfiguration().setClusterName("test");
         cache2.getConfiguration().setInitialStateRetrievalTimeout(1000);
         cache2.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:01 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:01 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader         ...
Message-ID: <E1H0iLJ-0008VQ-N8@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:01

  Modified:    src/org/jboss/cache/loader        
                        RmiDelegatingCacheLoader.java
                        ClusteredCacheLoader.java
                        LocalDelegatingCacheLoader.java CacheLoader.java
                        RpcDelegatingCacheLoader.java
                        DelegatingCacheLoader.java FileCacheLoader.java
                        TcpDelegatingCacheLoader.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.15      +9 -9      JBossCache/src/org/jboss/cache/loader/RmiDelegatingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RmiDelegatingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/RmiDelegatingCacheLoader.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- RmiDelegatingCacheLoader.java	26 Oct 2006 19:30:20 -0000	1.14
  +++ RmiDelegatingCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.15
  @@ -6,10 +6,10 @@
    */
   package org.jboss.cache.loader;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   import org.jboss.cache.loader.rmi.RemoteTreeCache;
   
  @@ -21,8 +21,8 @@
   
   /**
    * DelegatingCacheLoader implementation which delegates to a remote (not in the same VM)
  - * TreeCache using the Java RMI mechanism. If configured via an XML configuration file,
  - * the remote TreeCache delegated to is this cacheloader's cache's coordinator. If
  + * CacheImpl using the Java RMI mechanism. If configured via an XML configuration file,
  + * the remote CacheImpl delegated to is this cacheloader's cache's coordinator. If
    * configured programmatically, this cacheloader may delegate to any remote cache that
    * has been appropriately bound.
    * <p/>
  @@ -33,12 +33,12 @@
    * cacheloader's cache's cluster name.
    *
    * @author Daniel Gredler
  - * @version $Id: RmiDelegatingCacheLoader.java,v 1.14 2006/10/26 19:30:20 bstansberry Exp $
  + * @version $Id: RmiDelegatingCacheLoader.java,v 1.15 2006/12/30 17:50:01 msurtani Exp $
    */
   public class RmiDelegatingCacheLoader extends DelegatingCacheLoader
   {
      private RmiDelegatingCacheLoaderConfig config = new RmiDelegatingCacheLoaderConfig();
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private RemoteTreeCache remoteCache;
      private boolean programmaticInit;
   
  @@ -58,7 +58,7 @@
       * @param port     The port on which to look up the remote object.
       * @param bindName The name to which the remote object is bound.
       */
  -   public RmiDelegatingCacheLoader(TreeCache cache, String host, int port, String bindName)
  +   public RmiDelegatingCacheLoader(CacheImpl cache, String host, int port, String bindName)
      {
         this.cache = cache;
         config.setHost(host);
  @@ -123,7 +123,7 @@
       */
      protected Map delegateGet(Fqn name) throws Exception
      {
  -      DataNode n = this.remoteCache != null ? this.remoteCache.get(name) : null;
  +      Node n = this.remoteCache != null ? this.remoteCache.get(name) : null;
         if (n == null)
         {
            return null;
  
  
  
  1.20      +0 -1      JBossCache/src/org/jboss/cache/loader/ClusteredCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClusteredCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/ClusteredCacheLoader.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- ClusteredCacheLoader.java	29 Nov 2006 22:10:22 -0000	1.19
  +++ ClusteredCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.20
  @@ -11,7 +11,6 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodCallFactory;
  
  
  
  1.13      +11 -11    JBossCache/src/org/jboss/cache/loader/LocalDelegatingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalDelegatingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/LocalDelegatingCacheLoader.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- LocalDelegatingCacheLoader.java	23 Oct 2006 05:46:39 -0000	1.12
  +++ LocalDelegatingCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.13
  @@ -6,9 +6,9 @@
    */
   package org.jboss.cache.loader;
   
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   
   import java.io.ObjectInputStream;
  @@ -18,10 +18,10 @@
   import java.util.Set;
   
   /**
  - * DelegatingCacheLoader implementation which delegates to a local (in the same VM) TreeCache. Sample code:
  + * DelegatingCacheLoader implementation which delegates to a local (in the same VM) CacheImpl. Sample code:
    * <pre>
  - * TreeCache firstLevel=new TreeCache();
  - * TreeCache secondLevel=new TreeCache();
  + * CacheImpl firstLevel=new CacheImpl();
  + * CacheImpl secondLevel=new CacheImpl();
    * DelegatingCacheLoader l=new DelegatingCacheLoader(secondLevel);
    * l.setCache(firstLevel);
    * firstLevel.setCacheLoader(l);
  @@ -31,19 +31,19 @@
    *
    * @author Bela Ban
    * @author Daniel Gredler
  - * @version $Id: LocalDelegatingCacheLoader.java,v 1.12 2006/10/23 05:46:39 bstansberry Exp $
  + * @version $Id: LocalDelegatingCacheLoader.java,v 1.13 2006/12/30 17:50:01 msurtani Exp $
    */
   public class LocalDelegatingCacheLoader extends DelegatingCacheLoader
   {
   
      IndividualCacheLoaderConfig config;
  -   TreeCache delegate = null;
  +   CacheImpl delegate = null;
   
      public LocalDelegatingCacheLoader()
      {
      }
   
  -   public LocalDelegatingCacheLoader(TreeCache delegate)
  +   public LocalDelegatingCacheLoader(CacheImpl delegate)
      {
         this.delegate = delegate;
      }
  @@ -70,7 +70,7 @@
   
      protected Map delegateGet(Fqn name) throws Exception
      {
  -      DataNode n = delegate.get(name);
  +      Node n = delegate.get(name);
         if (n == null) return null;
         // after this stage we know that the node exists.  So never return a null - at worst, an empty map.
         Map m = n.getData();
  @@ -78,7 +78,7 @@
         return m;
      }
   
  -   protected void setDelegateCache(TreeCache delegate)
  +   protected void setDelegateCache(CacheImpl delegate)
      {
         this.delegate = delegate;
      }
  
  
  
  1.12      +26 -25    JBossCache/src/org/jboss/cache/loader/CacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/CacheLoader.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- CacheLoader.java	23 Oct 2006 05:46:39 -0000	1.11
  +++ CacheLoader.java	30 Dec 2006 17:50:01 -0000	1.12
  @@ -6,17 +6,17 @@
    */
   package org.jboss.cache.loader;
   
  -import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
  -import org.jboss.cache.RegionManager;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  +import org.jboss.cache.RegionManager;
  +import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
  -import java.util.Set;
  -import java.util.Map;
   import java.util.List;
  +import java.util.Map;
  +import java.util.Set;
   
   /**
    * A <code>CacheLoader</code> implementation persists and load keys to and from
  @@ -41,6 +41,7 @@
   {
       /**
        * Sets the configuration.  This is called before {@link #create()} and {@link #start()}.
  +    *
        * @param config    May be an instance of the IndividualCacheLoaderConfig base
        *                  class, in which case the cache loader should use the 
        *                  {@link IndividualCacheLoaderConfig#getProperties() getProperties()}
  @@ -196,7 +197,7 @@
      /**
       * Fetches the entire state for this cache from secondary storage (disk, database)
       * and writes it to a provided ObjectOutputStream. State written to the provided
  -    * ObjectOutputStream parameter is used for initialization of a new TreeCache instance.
  +    * ObjectOutputStream parameter is used for initialization of a new CacheImpl instance.
       * When the state gets transferred to the new cache instance its cacheloader calls
       * {@link #storeEntireState(ObjectInputStream)}
       * <p/>
  @@ -241,7 +242,7 @@
      /**
       * Fetches a portion of the state for this cache from secondary storage (disk, database)
       * and writes it to a provided ObjectOutputStream. State written to the provided
  -    * ObjectOutputStream parameter is used for activation of a portion of a new TreeCache instance.
  +    * ObjectOutputStream parameter is used for activation of a portion of a new CacheImpl instance.
       * When the state gets transferred to the new cache instance its cacheloader calls
       * {@link #storeState(Fqn,ObjectInputStream)}.
       * <p/>
  @@ -313,7 +314,7 @@
       * classloaders.
       * <p/>
       * <strong>NOTE:</strong> This method is only intended to be used
  -    * by the <code>TreeCache</code> instance this cache loader is
  +    * by the <code>CacheImpl</code> instance this cache loader is
       * associated with.
       * </p>
       *
  
  
  
  1.14      +22 -24    JBossCache/src/org/jboss/cache/loader/RpcDelegatingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RpcDelegatingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/RpcDelegatingCacheLoader.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- RpcDelegatingCacheLoader.java	26 Oct 2006 19:30:20 -0000	1.13
  +++ RpcDelegatingCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.14
  @@ -6,10 +6,10 @@
    */
   package org.jboss.cache.loader;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.NodeSPI;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   import org.jboss.cache.lock.TimeoutException;
   import org.jboss.cache.marshall.MethodCall;
  @@ -26,7 +26,7 @@
   
   /**
    * DelegatingCacheLoader implementation which delegates to a remote (not in the same VM)
  - * TreeCache using JGroups' RPC mechanism. The remote TreeCache delegated to is this
  + * CacheImpl using JGroups' RPC mechanism. The remote CacheImpl delegated to is this
    * cacheloader's cache's coordinator.
    * <p/>
    * This CacheLoader uses an optional configuration property, <tt>timeout</tt>, which
  @@ -34,7 +34,7 @@
    * specified, it defaults to <tt>5000</tt>.
    *
    * @author Daniel Gredler
  - * @version $Id: RpcDelegatingCacheLoader.java,v 1.13 2006/10/26 19:30:20 bstansberry Exp $
  + * @version $Id: RpcDelegatingCacheLoader.java,v 1.14 2006/12/30 17:50:01 msurtani Exp $
    */
   public class RpcDelegatingCacheLoader extends DelegatingCacheLoader
   {
  @@ -62,17 +62,17 @@
      {
         try
         {
  -         METHOD_GET_STATE = TreeCache.class.getDeclaredMethod("getStateBytes", new Class[]{});
  -         METHOD_SET_STATE = TreeCache.class.getDeclaredMethod("setStateBytes", new Class[]{byte[].class});
  -         METHOD_GET_CHILDREN_NAMES = TreeCache.class.getDeclaredMethod("getChildrenNames", new Class[]{Fqn.class});
  -         METHOD_GET_WITH_2_PARAMS = TreeCache.class.getDeclaredMethod("get", new Class[]{Fqn.class, Object.class});
  -         METHOD_GET_WITH_1_PARAM = TreeCache.class.getDeclaredMethod("get", new Class[]{Fqn.class});
  -         METHOD_EXISTS = TreeCache.class.getDeclaredMethod("exists", new Class[]{Fqn.class});
  -         METHOD_PUT_WITH_3_PARAMS = TreeCache.class.getDeclaredMethod("put", new Class[]{Fqn.class, Object.class, Object.class});
  -         METHOD_PUT_WITH_2_PARAMS = TreeCache.class.getDeclaredMethod("put", new Class[]{Fqn.class, Map.class});
  -         METHOD_REMOVE_WITH_2_PARAMS = TreeCache.class.getDeclaredMethod("remove", new Class[]{Fqn.class, Object.class});
  -         METHOD_REMOVE_WITH_1_PARAM = TreeCache.class.getDeclaredMethod("remove", new Class[]{Fqn.class});
  -         METHOD_REMOVE_DATA = TreeCache.class.getDeclaredMethod("removeData", new Class[]{Fqn.class});
  +         METHOD_GET_STATE = CacheImpl.class.getDeclaredMethod("getStateBytes", new Class[]{});
  +         METHOD_SET_STATE = CacheImpl.class.getDeclaredMethod("setStateBytes", new Class[]{byte[].class});
  +         METHOD_GET_CHILDREN_NAMES = CacheImpl.class.getDeclaredMethod("getChildrenNames", new Class[]{Fqn.class});
  +         METHOD_GET_WITH_2_PARAMS = CacheImpl.class.getDeclaredMethod("get", new Class[]{Fqn.class, Object.class});
  +         METHOD_GET_WITH_1_PARAM = CacheImpl.class.getDeclaredMethod("get", new Class[]{Fqn.class});
  +         METHOD_EXISTS = CacheImpl.class.getDeclaredMethod("exists", new Class[]{Fqn.class});
  +         METHOD_PUT_WITH_3_PARAMS = CacheImpl.class.getDeclaredMethod("put", new Class[]{Fqn.class, Object.class, Object.class});
  +         METHOD_PUT_WITH_2_PARAMS = CacheImpl.class.getDeclaredMethod("put", new Class[]{Fqn.class, Map.class});
  +         METHOD_REMOVE_WITH_2_PARAMS = CacheImpl.class.getDeclaredMethod("remove", new Class[]{Fqn.class, Object.class});
  +         METHOD_REMOVE_WITH_1_PARAM = CacheImpl.class.getDeclaredMethod("remove", new Class[]{Fqn.class});
  +         METHOD_REMOVE_DATA = CacheImpl.class.getDeclaredMethod("removeData", new Class[]{Fqn.class});
         }
         catch (NoSuchMethodException ex)
         {
  @@ -101,8 +101,6 @@
   
      /**
       * Allows configuration via XML config file.
  -    *
  -    * @see DelegatingCacheLoader#setConfig(java.util.Properties)
       */
      public void setConfig(IndividualCacheLoaderConfig base)
      {
  @@ -131,7 +129,7 @@
   
      // See http://jira.jboss.com/jira/browse/JBCACHE-118 for why this is commented out.
      /**
  -    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegateGet(org.jboss.cache.Fqn, java.lang.Object)
  +    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegateGet(org.jboss.cache.Fqn,java.lang.Object)
       */
   //   protected Object delegateGet(Fqn name, Object key) throws Exception {
   //      return this.doMethodCall( METHOD_GET_WITH_2_PARAMS, new Object[] { name, key } );
  @@ -142,7 +140,7 @@
       */
      protected Map delegateGet(Fqn name) throws Exception
      {
  -      DataNode n = (DataNode) this.doMethodCall(METHOD_GET_WITH_1_PARAM, new Object[]{name});
  +      NodeSPI n = (NodeSPI) this.doMethodCall(METHOD_GET_WITH_1_PARAM, new Object[]{name});
         if (n == null)
         {
            return null;
  @@ -160,7 +158,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegatePut(org.jboss.cache.Fqn, java.lang.Object, java.lang.Object)
  +    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegatePut(org.jboss.cache.Fqn,java.lang.Object,java.lang.Object)
       */
      protected Object delegatePut(Fqn name, Object key, Object value) throws Exception
      {
  @@ -168,7 +166,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegatePut(org.jboss.cache.Fqn, java.util.Map)
  +    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegatePut(org.jboss.cache.Fqn,java.util.Map)
       */
      protected void delegatePut(Fqn name, Map attributes) throws Exception
      {
  @@ -176,7 +174,7 @@
      }
   
      /**
  -    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegateRemove(org.jboss.cache.Fqn, java.lang.Object)
  +    * @see org.jboss.cache.loader.DelegatingCacheLoader#delegateRemove(org.jboss.cache.Fqn,java.lang.Object)
       */
      protected Object delegateRemove(Fqn name, Object key) throws Exception
      {
  
  
  
  1.13      +2 -2      JBossCache/src/org/jboss/cache/loader/DelegatingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DelegatingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/DelegatingCacheLoader.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- DelegatingCacheLoader.java	23 Oct 2006 05:46:39 -0000	1.12
  +++ DelegatingCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.13
  @@ -19,13 +19,13 @@
   import java.util.Set;
   
   /**
  - * CacheLoader implementation which delegates to another TreeCache. This allows to stack caches on top of each
  + * CacheLoader implementation which delegates to another CacheImpl. This allows to stack caches on top of each
    * other, allowing for hierarchical cache levels. For example, first level cache delegates to a second level cache,
    * which delegates to a persistent cache.
    *
    * @author Bela Ban
    * @author Daniel Gredler
  - * @version $Id: DelegatingCacheLoader.java,v 1.12 2006/10/23 05:46:39 bstansberry Exp $
  + * @version $Id: DelegatingCacheLoader.java,v 1.13 2006/12/30 17:50:01 msurtani Exp $
    */
   public abstract class DelegatingCacheLoader extends AbstractCacheLoader
   {
  
  
  
  1.28      +9 -9      JBossCache/src/org/jboss/cache/loader/FileCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FileCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/FileCacheLoader.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- FileCacheLoader.java	8 Dec 2006 18:49:17 -0000	1.27
  +++ FileCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.28
  @@ -17,15 +17,15 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  -import java.util.regex.Pattern;
  -import java.util.regex.Matcher;
   import java.util.concurrent.ConcurrentHashMap;
  +import java.util.regex.Matcher;
  +import java.util.regex.Pattern;
   
   /**
    * Simple file-based CacheLoader implementation. Nodes are directories, attributes of a node is a file in the directory
    *
    * @author Bela Ban
  - * @version $Id: FileCacheLoader.java,v 1.27 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: FileCacheLoader.java,v 1.28 2006/12/30 17:50:01 msurtani Exp $
    */
   public class FileCacheLoader extends AbstractCacheLoader
   {
  @@ -42,12 +42,12 @@
      Map<Object, List<Modification>> transactions = new ConcurrentHashMap();
   
      /**
  -    * TreeCache data file.
  +    * CacheImpl data file.
       */
      public static final String DATA = "data.dat";
   
      /**
  -    * TreeCache directory suffix.
  +    * CacheImpl directory suffix.
       */
      public static final String DIR_SUFFIX = "fdb";
   
  
  
  
  1.7       +11 -11    JBossCache/src/org/jboss/cache/loader/TcpDelegatingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpDelegatingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/TcpDelegatingCacheLoader.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- TcpDelegatingCacheLoader.java	26 Oct 2006 19:30:20 -0000	1.6
  +++ TcpDelegatingCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.7
  @@ -22,7 +22,7 @@
   
   /**
    * DelegatingCacheLoader implementation which delegates to a remote (not in the same VM)
  - * TreeCache using TCP/IP for communication. Example configuration for connecting to a TcpCacheServer
  + * CacheImpl using TCP/IP for communication. Example configuration for connecting to a TcpCacheServer
    * running at myHost:12345:<pre>
    * <attribute name="CacheLoaderClass">org.jboss.cache.loader.TcpDelegatingCacheLoader</attribute>
    * <attribute name="CacheLoaderConfig">
  @@ -32,7 +32,7 @@
    * </pre>
    *
    * @author Bela Ban
  - * @version $Id: TcpDelegatingCacheLoader.java,v 1.6 2006/10/26 19:30:20 bstansberry Exp $
  + * @version $Id: TcpDelegatingCacheLoader.java,v 1.7 2006/12/30 17:50:01 msurtani Exp $
    */
   public class TcpDelegatingCacheLoader extends DelegatingCacheLoader
   {
  @@ -136,7 +136,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
            return (Set) retval;
         }
  @@ -169,7 +169,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
            return (Map) retval;
         }
  @@ -190,7 +190,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
            return (Boolean) retval;
         }
  @@ -213,7 +213,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
            return retval;
         }
  @@ -235,7 +235,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
         }
      }
  @@ -261,7 +261,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
         }
      }
  @@ -282,7 +282,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
            return retval;
         }
  @@ -303,7 +303,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
         }
      }
  @@ -323,7 +323,7 @@
            Object retval = in.readObject();
            if (retval instanceof Exception)
            {
  -            throw(Exception) retval;
  +            throw (Exception) retval;
            }
         }
      }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:03 -0500
Subject: [jboss-cvs]
	JBossCache/src-50/org/jboss/cache/pojo/interceptors/dynamic ...
Message-ID: <E1H0iLL-0008Ve-DN@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:03

  Modified:    src-50/org/jboss/cache/pojo/interceptors/dynamic 
                        CacheFieldInterceptor.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.13      +22 -19    JBossCache/src-50/org/jboss/cache/pojo/interceptors/dynamic/CacheFieldInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheFieldInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/interceptors/dynamic/CacheFieldInterceptor.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- CacheFieldInterceptor.java	27 Oct 2006 01:49:09 -0000	1.12
  +++ CacheFieldInterceptor.java	30 Dec 2006 17:50:03 -0000	1.13
  @@ -17,17 +17,16 @@
   import org.jboss.aop.joinpoint.FieldWriteInvocation;
   import org.jboss.aop.joinpoint.Invocation;
   import org.jboss.aop.joinpoint.MethodInvocation;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.pojo.memory.FieldPersistentReference;
  -import org.jboss.cache.pojo.util.AopUtil;
  -import org.jboss.cache.pojo.util.CacheApiUtil;
  -import org.jboss.cache.pojo.PojoTreeCache;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.pojo.CachedType;
  -import org.jboss.cache.pojo.PojoInstance;
   import org.jboss.cache.pojo.PojoCacheAlreadyDetachedException;
  +import org.jboss.cache.pojo.PojoInstance;
   import org.jboss.cache.pojo.PojoUtil;
   import org.jboss.cache.pojo.impl.PojoCacheImpl;
  +import org.jboss.cache.pojo.memory.FieldPersistentReference;
  +import org.jboss.cache.pojo.util.AopUtil;
  +import org.jboss.cache.pojo.util.CacheApiUtil;
   
   import java.lang.reflect.Field;
   import java.util.Iterator;
  @@ -52,7 +51,7 @@
      public CacheFieldInterceptor(PojoCacheImpl pCache, Fqn fqn, CachedType type)
      {
         this.pCache_ = pCache;
  -      cache_ = (CacheSPI)this.pCache_.getCache();
  +      cache_ = (CacheSPI) this.pCache_.getCache();
         this.fqn_ = fqn;
         this.type_ = type;
         util_ = new PojoUtil();
  @@ -77,7 +76,7 @@
   
      public void setInterceptor(Interceptor intcptr)
      {
  -      CacheFieldInterceptor interceptor = (CacheFieldInterceptor)intcptr;
  +      CacheFieldInterceptor interceptor = (CacheFieldInterceptor) intcptr;
         setFqn(interceptor.getFqn());
         setAopInstance(interceptor.getAopInstance());
      }
  @@ -99,7 +98,7 @@
      public Object invoke(Invocation invocation) throws Throwable
      {
         // Kind of ad hoc now. MethodInvocation should not invoke this.
  -      if(invocation instanceof MethodInvocation)
  +      if (invocation instanceof MethodInvocation)
            return invocation.invokeNext();
   
         // Check if CLASS_INTERNAL exists. If not, that means we are done. We need to remove ourself.
  @@ -117,9 +116,9 @@
   
            Advisor advisor = fieldInvocation.getAdvisor();
            Field field = fieldInvocation.getField();
  -         if(log_.isTraceEnabled())
  +         if (log_.isTraceEnabled())
            {
  -            log_.trace("invoke(): field write interception for fqn: " +fqn_ + " and field: " +field);
  +            log_.trace("invoke(): field write interception for fqn: " + fqn_ + " and field: " + field);
            }
   
            // Only if this field is replicatable. static, transient and final are not.
  @@ -131,7 +130,8 @@
               if (fieldType.isImmediate() || hasSerializableAnnotation(field, advisor, parentType))
               {
                  cache_.put(fqn_, field.getName(), value);
  -            } else
  +            }
  +            else
               {
                  //cache_.putObject(((Fqn)fqn_.clone()).add(field.getName()), value);
                  pCache_.attach(new Fqn(fqn_, field.getName()), value);
  @@ -140,7 +140,8 @@
   
            Object obj = fieldInvocation.getTargetObject();
            util_.inMemorySubstitution(obj, field, value);
  -      } else if (invocation instanceof FieldReadInvocation)
  +      }
  +      else if (invocation instanceof FieldReadInvocation)
         {
            FieldInvocation fieldInvocation =
                    (FieldInvocation) invocation;
  @@ -156,7 +157,8 @@
               if (fieldType.isImmediate() || hasSerializableAnnotation(field, advisor, parentType))
               {
                  result = cache_.get(fqn_, field.getName());
  -            } else
  +            }
  +            else
               {
                  //result = cache_.getObject(((Fqn)fqn_.clone()).add(field.getName()));
                  result = pCache_.getObject(new Fqn(fqn_, field.getName()));
  @@ -217,11 +219,11 @@
      {
         boolean detached = false;
   
  -      if(!CacheApiUtil.exists(cache_, fqn_, PojoInstance.KEY))
  +      if (!CacheApiUtil.exists(cache_, fqn_, PojoInstance.KEY))
         {
            detached = true;
            Object obj = invocation.getTargetObject();
  -         if (! (obj instanceof Advised))
  +         if (!(obj instanceof Advised))
               throw new RuntimeException("Interception on non-advised pojo " + obj.toString());
   
            InstanceAdvisor advisor = ((Advised) obj)._getInstanceAdvisor();
  @@ -229,7 +231,7 @@
            if (interceptor != null)
            {
               advisor.removeInterceptor(interceptor.getName());
  -            throw new PojoCacheAlreadyDetachedException("pojo: " +obj.getClass() +
  +            throw new PojoCacheAlreadyDetachedException("pojo: " + obj.getClass() +
                       " has possibly been detached remotely. Internal id: " + interceptor.getFqn());
            }
         }
  @@ -257,9 +259,10 @@
            if (fieldType.isImmediate())
            {
               value = cache_.get(fqn_, field.getName());
  -         } else
  +         }
  +         else
            {
  -            //		value = removeObject(fqn_+TreeCache.SEPARATOR+field.getName());
  +            //		value = removeObject(fqn_+CacheImpl.SEPARATOR+field.getName());
               //value = cache_.getObject(((Fqn)fqn_.clone()).add(field.getName()));
               value = pCache_.getObject(new Fqn(fqn_, field.getName()));
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:03 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/impl  ...
Message-ID: <E1H0iLL-0008Vl-IE@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:03

  Modified:    src-50/org/jboss/cache/pojo/impl  PojoCacheDelegate.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.18      +62 -52    JBossCache/src-50/org/jboss/cache/pojo/impl/PojoCacheDelegate.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoCacheDelegate.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/impl/PojoCacheDelegate.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- PojoCacheDelegate.java	30 Dec 2006 02:53:07 -0000	1.17
  +++ PojoCacheDelegate.java	30 Dec 2006 17:50:03 -0000	1.18
  @@ -14,21 +14,20 @@
   import org.jboss.aop.advice.Interceptor;
   import org.jboss.aop.proxy.ClassProxy;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.Cache;
   import org.jboss.cache.config.Option;
  -import org.jboss.cache.pojo.interceptors.dynamic.AbstractCollectionInterceptor;
  -import org.jboss.cache.pojo.memory.FieldPersistentReference;
  -import org.jboss.cache.pojo.util.AopUtil;
  -import org.jboss.cache.pojo.interceptors.dynamic.BaseInterceptor;
  -import org.jboss.cache.pojo.observable.Observer;
  -import org.jboss.cache.pojo.PojoUtil;
   import org.jboss.cache.pojo.CachedType;
   import org.jboss.cache.pojo.PojoInstance;
   import org.jboss.cache.pojo.PojoReference;
  +import org.jboss.cache.pojo.PojoUtil;
   import org.jboss.cache.pojo.collection.CollectionInterceptorUtil;
  +import org.jboss.cache.pojo.interceptors.dynamic.AbstractCollectionInterceptor;
  +import org.jboss.cache.pojo.interceptors.dynamic.BaseInterceptor;
  +import org.jboss.cache.pojo.memory.FieldPersistentReference;
  +import org.jboss.cache.pojo.observable.Observer;
  +import org.jboss.cache.pojo.util.AopUtil;
   
   import java.lang.reflect.Field;
   import java.util.Collection;
  @@ -63,7 +62,7 @@
      public PojoCacheDelegate(PojoCacheImpl cache, Observer observer)
      {
         pCache_ = cache;
  -      cache_ = (CacheSPI)pCache_.getCache();
  +      cache_ = (CacheSPI) pCache_.getCache();
         internal_ = new InternalHelper(cache_);
         graphHandler_ = new ObjectGraphHandler(pCache_, internal_);
         collectionHandler_ = new CollectionClassHandler(pCache_, internal_);
  @@ -74,12 +73,12 @@
   
      public void setBulkRemove(boolean bulk)
      {
  -      bulkRemove_.set(Boolean.valueOf(bulk));
  +      bulkRemove_.set(bulk);
      }
   
      private boolean getBulkRemove()
      {
  -      return ((Boolean) bulkRemove_.get()).booleanValue();
  +      return bulkRemove_.get();
      }
   
      public Object getObject(Fqn fqn) throws CacheException
  @@ -131,7 +130,6 @@
   
      /**
       * Note that caller of this method will take care of synchronization within the <code>fqn</code> sub-tree.
  -    *
       */
      public Object putObjectII(Fqn fqn, Object obj) throws CacheException
      {
  @@ -168,18 +166,21 @@
            + internalFqn);
         }
   
  -      if( (obj instanceof Advised || obj instanceof ClassProxy) && isMultipleReferencedPut(obj))
  +      if ((obj instanceof Advised || obj instanceof ClassProxy) && isMultipleReferencedPut(obj))
         {
            // we pass in the originating fqn intentionaly
            graphHandler_.put(fqn, obj);
  -      } else if (obj instanceof Advised)
  +      }
  +      else if (obj instanceof Advised)
         {
            advisedHandler_.put(internalFqn, fqn, obj);
  -      } else if (isCollection(obj))
  +      }
  +      else if (isCollection(obj))
         {
            collectionHandler_.put(internalFqn, fqn, obj);
            //
  -      } else
  +      }
  +      else
         {
            // must be Serializable, including primitive types
            serializableHandler_.put(internalFqn, obj);
  @@ -191,8 +192,7 @@
      Fqn createInternalFqn(Fqn fqn, Object obj) throws CacheException
      {
         // Create an internal Fqn name
  -      Fqn internalFqn = AopUtil.createInternalFqn(fqn, (Cache)cache_);
  -      return internalFqn;
  +      return AopUtil.createInternalFqn(fqn, cache_);
      }
   
      Fqn setPojoReference(Fqn fqn, Object obj, Fqn internalFqn) throws CacheException
  @@ -216,12 +216,12 @@
      private void createChildNodeFirstWithoutLocking(Fqn internalFqn)
      {
         int size = internalFqn.size();
  -      Fqn f = internalFqn.getFqnChild(0, size-1);
  -      Fqn child = internalFqn.getFqnChild(size-1, size);
  +      Fqn f = internalFqn.getFqnChild(0, size - 1);
  +      Fqn child = internalFqn.getFqnChild(size - 1, size);
         Node base = cache_.getRoot().getChild(f);
  -      if(base == null)
  +      if (base == null)
         {
  -         log.debug("The node retrieved is null from fqn: " +f);
  +         log.debug("The node retrieved is null from fqn: " + f);
            return;
         }
         Option option = cache_.getInvocationContext().getOptionOverrides();
  @@ -240,7 +240,7 @@
      {
         // the class attribute is implicitly stored as an immutable read-only attribute
         PojoReference pojoReference = internal_.getPojoReference(fqn);
  -      if(pojoReference == null)
  +      if (pojoReference == null)
         {
            //  clazz and pojoReference can be not null if this node is the replicated brother node.
            if (log.isTraceEnabled())
  @@ -265,19 +265,22 @@
            return null;
         }
   
  -      if(graphHandler_.isMultipleReferenced(internalFqn))
  +      if (graphHandler_.isMultipleReferenced(internalFqn))
         {
            graphHandler_.remove(fqn, internalFqn, result);
  -      } else if (Advised.class.isAssignableFrom(clazz))
  +      }
  +      else if (Advised.class.isAssignableFrom(clazz))
         {
            advisedHandler_.remove(internalFqn, result, clazz);
            internal_.cleanUp(internalFqn);
  -      } else if (isCollectionGet(clazz))
  +      }
  +      else if (isCollectionGet(clazz))
         {
            // We need to return the original reference
            result = collectionHandler_.remove(internalFqn, result);
            internal_.cleanUp(internalFqn);
  -      } else
  +      }
  +      else
         { // Just Serializable objects. Do a brute force remove is ok.
            serializableHandler_.remove();
            internal_.cleanUp(internalFqn);
  @@ -312,7 +315,7 @@
      {
         // the class attribute is implicitly stored as an immutable read-only attribute
         PojoReference pojoReference = internal_.getPojoReference(fqn);
  -      if(pojoReference == null)
  +      if (pojoReference == null)
         {
            //  clazz and pojoReference can be not null if this node is the replicated brother node.
            return null;
  @@ -324,7 +327,7 @@
         if (log.isDebugEnabled())
         {
            log.debug("getObject(): id: " + fqn + " with a corresponding internal id: "
  -         +internalFqn);
  +                 + internalFqn);
         }
   
         /**
  @@ -344,10 +347,12 @@
         if (Advised.class.isAssignableFrom(clazz))
         {
            obj = advisedHandler_.get(internalFqn, clazz, pojoInstance);
  -      } else if(isCollectionGet(clazz))
  +      }
  +      else if (isCollectionGet(clazz))
         { // Must be Collection classes. We will use aop.ClassProxy instance instead.
            obj = collectionHandler_.get(internalFqn, clazz, pojoInstance);
  -      } else
  +      }
  +      else
         {
            // Maybe it is just a serialized object.
            obj = serializableHandler_.get(internalFqn, clazz, pojoInstance);
  @@ -359,7 +364,7 @@
   
      private boolean isCollectionGet(Class clazz)
      {
  -      if(Map.class.isAssignableFrom(clazz) || Collection.class.isAssignableFrom(clazz))
  +      if (Map.class.isAssignableFrom(clazz) || Collection.class.isAssignableFrom(clazz))
            return true;
   
         return false;
  @@ -369,7 +374,7 @@
      private boolean isMultipleReferencedPut(Object obj)
      {
         Interceptor interceptor = null;
  -      if(obj instanceof Advised)
  +      if (obj instanceof Advised)
         {
            InstanceAdvisor advisor = ((Advised) obj)._getInstanceAdvisor();
            if (advisor == null)
  @@ -377,27 +382,26 @@
   
            // Step Check for cross references
            interceptor = AopUtil.findCacheInterceptor(advisor);
  -      }else
  +      }
  +      else
         {
            interceptor = CollectionInterceptorUtil.getInterceptor((ClassProxy) obj);
         }
  -      if(interceptor == null) return false;
  +      if (interceptor == null) return false;
   
         Fqn originalFqn = null;
   
         // ah, found something. So this will be multiple referenced.
         originalFqn = ((BaseInterceptor) interceptor).getFqn();
   
  -      if (originalFqn != null) return true;
  +      return originalFqn != null;
   
  -      return false;
      }
   
      private boolean isCollection(Object obj)
      {
  -      if(obj instanceof Collection || obj instanceof Map) return true;
  +      return obj instanceof Collection || obj instanceof Map;
   
  -      return false;
      }
   
      /**
  @@ -413,9 +417,10 @@
         {
            undoInterceptorDetach(undoMap);
            return false;
  -      } else
  +      }
  +      else
         {
  -         cache_.remove(fqn); // interceptor has been removed so it is safe to do bulk remove now.
  +         cache_.removeNode(fqn); // interceptor has been removed so it is safe to do bulk remove now.
         }
         return true;
      }
  @@ -427,7 +432,8 @@
         {
            util_.detachInterceptor(advisor, interceptor, observer_);
            undoMap.put(advisor, interceptor);
  -      } else
  +      }
  +      else
         {
            undoMap.put(DETACH, interceptor);
         }
  @@ -450,7 +456,8 @@
               }
   
               advisor.appendInterceptor(interceptor);
  -         } else
  +         }
  +         else
            {
               BaseInterceptor interceptor = (BaseInterceptor) undoMap.get(obj);
               boolean copyToCache = false;
  @@ -539,7 +546,8 @@
            }
            boolean detachOnly = false;
            detachInterceptor(advisor, interceptor, detachOnly, undoMap);
  -      } else if (obj instanceof Map || obj instanceof List || obj instanceof Set)
  +      }
  +      else if (obj instanceof Map || obj instanceof List || obj instanceof Set)
         {
            // TODO Is this really necessary?
            if (!(obj instanceof ClassProxy)) return false;
  @@ -559,7 +567,8 @@
                  Object subObj = ((Map) obj).get(it.next());
                  if (pojoGraphMultipleReferenced(subObj, undoMap)) return true;
               }
  -         } else if (obj instanceof List || obj instanceof Set)
  +         }
  +         else if (obj instanceof List || obj instanceof Set)
            {
               for (Iterator it = ((Collection) obj).iterator(); it.hasNext();)
               {
  @@ -588,20 +597,21 @@
         Node root = cache_.getRoot();
         Node current = root.getChild(fqn);
   
  -      if(current == null) return;
  +      if (current == null) return;
   
         Collection<Node> col = current.getChildren();
  -      if(col == null) return;
  -      for(Node n : col)
  +      if (col == null) return;
  +      for (Node n : col)
         {
            Fqn newFqn = n.getFqn();
  -         if(InternalHelper.isInternalNode(newFqn)) continue; // skip
  +         if (InternalHelper.isInternalNode(newFqn)) continue; // skip
   
            Object pojo = getObject(newFqn);
            if (pojo != null)
            {
               map.put(newFqn, pojo);
  -         } else
  +         }
  +         else
            {
               findChildObjects(newFqn, map);
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:03 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/misc  ...
Message-ID: <E1H0iLL-0008Vs-Oe@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:03

  Modified:    tests/functional/org/jboss/cache/misc  TestingUtil.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.11      +10 -10    JBossCache/tests/functional/org/jboss/cache/misc/TestingUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TestingUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/misc/TestingUtil.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- TestingUtil.java	20 Dec 2006 13:34:28 -0000	1.10
  +++ TestingUtil.java	30 Dec 2006 17:50:03 -0000	1.11
  @@ -8,8 +8,8 @@
   package org.jboss.cache.misc;
   
   import org.jboss.cache.Cache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.TreeCache;
   
   import java.io.File;
   import java.util.List;
  @@ -52,7 +52,7 @@
      }
   
      /**
  -    * Loops, continually calling {@link #areCacheViewsComplete(TreeCache[])}
  +    * Loops, continually calling {@link #areCacheViewsComplete(CacheImpl[])}
       * until it either returns true or <code>timeout</code> ms have elapsed.
       *
       * @param caches  caches which must all have consistent views
  @@ -60,7 +60,7 @@
       * @throws RuntimeException if <code>timeout</code> ms have elapse without
       *                          all caches having the same number of members.
       */
  -   public static void blockUntilViewsReceived(TreeCache[] caches, long timeout)
  +   public static void blockUntilViewsReceived(CacheImpl[] caches, long timeout)
      {
         long failTime = System.currentTimeMillis() + timeout;
   
  @@ -77,7 +77,7 @@
      }
   
      /**
  -    * Loops, continually calling {@link #areCacheViewsComplete(TreeCache[])}
  +    * Loops, continually calling {@link #areCacheViewsComplete(CacheImpl[])}
       * until it either returns true or <code>timeout</code> ms have elapsed.
       *
       * @param groupSize number of caches expected in the group
  @@ -102,7 +102,7 @@
      }
   
      /**
  -    * Loops, continually calling {@link #areCacheViewsComplete(TreeCache[])}
  +    * Loops, continually calling {@link #areCacheViewsComplete(CacheImpl[])}
       * until it either returns true or <code>timeout</code> ms have elapsed.
       *
       * @param groupSize number of caches expected in the group
  @@ -110,7 +110,7 @@
       * @throws RuntimeException if <code>timeout</code> ms have elapse without
       *                          all caches having the same number of members.
       */
  -   public static void blockUntilViewReceived(TreeCache cache, int groupSize, long timeout)
  +   public static void blockUntilViewReceived(CacheImpl cache, int groupSize, long timeout)
      {
         long failTime = System.currentTimeMillis() + timeout;
   
  @@ -154,7 +154,7 @@
   
      /**
       * Checks each cache to see if the number of elements in the array
  -    * returned by {@link TreeCache#getMembers()} matches the size of
  +    * returned by {@link CacheImpl#getMembers()} matches the size of
       * the <code>caches</code> parameter.
       *
       * @param caches caches that should form a View
  @@ -163,13 +163,13 @@
       * @throws IllegalStateException if any of the caches have MORE view
       *                               members than caches.length
       */
  -   public static boolean areCacheViewsComplete(TreeCache[] caches)
  +   public static boolean areCacheViewsComplete(CacheImpl[] caches)
      {
         int memberCount = caches.length;
   
         for (int i = 0; i < memberCount; i++)
         {
  -         TreeCache cache = caches[i];
  +         CacheImpl cache = caches[i];
            return isCacheViewComplete(cache, memberCount);
         }
   
  @@ -180,7 +180,7 @@
       * @param cache
       * @param memberCount
       */
  -   public static boolean isCacheViewComplete(TreeCache cache, int memberCount)
  +   public static boolean isCacheViewComplete(CacheImpl cache, int memberCount)
      {
         List members = cache.getMembers();
         if (members == null || memberCount > members.size())
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:03 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:03 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/bdbje  ...
Message-ID: <E1H0iLL-0008Vz-Ss@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:03

  Modified:    src/org/jboss/cache/loader/bdbje  BdbjeCacheLoader.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.24      +21 -21    JBossCache/src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BdbjeCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java,v
  retrieving revision 1.23
  retrieving revision 1.24
  diff -u -b -r1.23 -r1.24
  --- BdbjeCacheLoader.java	8 Dec 2006 18:49:17 -0000	1.23
  +++ BdbjeCacheLoader.java	30 Dec 2006 17:50:03 -0000	1.24
  @@ -23,7 +23,6 @@
   import org.jboss.cache.Modification;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   import org.jboss.cache.loader.AbstractCacheLoader;
  -import java.util.concurrent.ConcurrentHashMap;
   
   import java.io.File;
   import java.io.IOException;
  @@ -35,6 +34,7 @@
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  +import java.util.concurrent.ConcurrentHashMap;
   
   
   /**
  @@ -43,14 +43,14 @@
    * <p>The configuration string format is:</p>
    * <pre>environmentDirectoryName[#databaseName]</pre>
    * <p>where databaseName, if omitted, defaults to the ClusterName property
  - * of the TreeCache.</p>
  + * of the CacheImpl.</p>
    * <p/>
    * <p>A je.properties file may optionally be placed in the JE environment
    * directory and used to customize the default JE configuration.</p>
    *
    * @author Mark Hayes May 16, 2004
    * @author Bela Ban
  - * @version $Id: BdbjeCacheLoader.java,v 1.23 2006/12/08 18:49:17 genman Exp $
  + * @version $Id: BdbjeCacheLoader.java,v 1.24 2006/12/30 17:50:03 msurtani Exp $
    */
   public class BdbjeCacheLoader extends AbstractCacheLoader
   {
  @@ -158,7 +158,7 @@
         catalogDbName = cacheDbName + "_class_catalog";
   
         /*
  -       * If the TreeCache is transactional, we will create transactional
  +       * If the CacheImpl is transactional, we will create transactional
          * databases.  However, we always create a transactional environment
          * since it may be shared by transactional and non-transactional caches.
          */
  @@ -296,7 +296,7 @@
      }
   
      /**
  -    * Sets the TreeCache owner of this cache loader.
  +    * Sets the CacheImpl owner of this cache loader.
       */
      public void setCache(CacheSPI c)
      {
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:04 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:04 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic   ...
Message-ID: <E1H0iLM-0008WA-Hs@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:04

  Modified:    src/org/jboss/cache/optimistic   WorkspaceNodeImpl.java
                        WorkspaceNode.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.33      +37 -154   JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.32
  retrieving revision 1.33
  diff -u -b -r1.32 -r1.33
  --- WorkspaceNodeImpl.java	20 Dec 2006 13:56:49 -0000	1.32
  +++ WorkspaceNodeImpl.java	30 Dec 2006 17:50:04 -0000	1.33
  @@ -10,20 +10,13 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractNode;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.DataNode;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Node;
   import org.jboss.cache.NodeNotExistsException;
   import org.jboss.cache.NodeSPI;
  -import org.jboss.cache.OptimisticTreeNode;
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeNode;
  +import org.jboss.cache.VersionedNode;
   import org.jboss.cache.factories.NodeFactory;
  -import org.jboss.cache.lock.IdentityLock;
  -import org.jboss.cache.lock.LockingException;
  -import org.jboss.cache.lock.NodeLock;
  -import org.jboss.cache.lock.TimeoutException;
   
   import java.util.Collections;
   import java.util.HashMap;
  @@ -43,37 +36,36 @@
   
      private static Log log = LogFactory.getLog(WorkspaceNodeImpl.class);
   
  -   private Node node;
  +   private NodeSPI node;
      private TransactionWorkspace workspace;
      private DataVersion version = DefaultDataVersion.ZERO;
      private boolean dirty;
      private boolean created;
  -   private Map<Object, Node> optimisticChildNodeMap;
  +   private Map<Object, NodeSPI> optimisticChildNodeMap;
      private Map optimisticDataMap;
      private boolean versioningImplicit;
   
      /**
       * Constructs with a node and workspace.
       */
  -   public WorkspaceNodeImpl(Node node, TransactionWorkspace workspace)
  +   public WorkspaceNodeImpl(NodeSPI node, TransactionWorkspace workspace)
      {
  -      if (!(node instanceof OptimisticTreeNode))
  +      if (!(node instanceof VersionedNode))
         {
  -         throw new IllegalArgumentException("node " + node + " not OptimisticTreeNode");
  +         throw new IllegalArgumentException("node " + node + " not VersionedNode");
         }
         this.node = node;
         this.workspace = workspace;
  -      optimisticDataMap = new HashMap(node.getNodeSPI().getRawData());
  -      //log.fatal("Children map is " + node.getNodeSPI().getChildrenMap());
  -      Map childrenMap = node.getNodeSPI().getChildrenMap();
  +      optimisticDataMap = new HashMap(node.getRawData());
  +      Map childrenMap = node.getChildrenMap();
         if (childrenMap == null)
            optimisticChildNodeMap = new ConcurrentHashMap();
         else
  -         optimisticChildNodeMap = new ConcurrentHashMap(node.getNodeSPI().getChildrenMap());
  -      this.version = ((OptimisticTreeNode) node).getVersion();
  +         optimisticChildNodeMap = new ConcurrentHashMap(node.getChildrenMap());
  +      this.version = node.getVersion();
         if (version == null)
         {
  -         throw new IllegalStateException("OptimisticTreeNode version null");
  +         throw new IllegalStateException("VersionedNode version null");
         }
      }
   
  @@ -194,12 +186,12 @@
         }
   
         //see if we already have it
  -      Node child = optimisticChildNodeMap.get(child_name);
  +      NodeSPI child = optimisticChildNodeMap.get(child_name);
   
         // if not we need to create it
         if (child == null)
         {
  -         child = NodeFactory.getInstance().createNodeOfType(parent, child_name, fqn, parent, (Map) null, cache, version);
  +         child = (NodeSPI) NodeFactory.getInstance().createNodeOfType(parent, child_name, fqn, parent, null, cache, version);
            optimisticChildNodeMap.put(child_name, child);
         }
         if (log.isTraceEnabled())
  @@ -237,7 +229,7 @@
         WorkspaceNode wrapper = workspace.getNode((Fqn) fqn);
         if (wrapper == null)
         {
  -         DataNode temp = (DataNode) optimisticChildNodeMap.get(fqn);
  +         NodeSPI temp = optimisticChildNodeMap.get(fqn);
            if (temp != null)
            {
               wrapper = new WorkspaceNodeImpl(temp, workspace);
  @@ -249,7 +241,7 @@
         return wrapper;
      }
   
  -   public Node getNode()
  +   public NodeSPI getNode()
      {
         return node;
      }
  @@ -331,126 +323,6 @@
         return optimisticDataMap.containsKey(key);
      }
   
  -   public Set getDataKeys()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public boolean childExists(Object child_name)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public NodeLock getImmutableLock()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public IdentityLock getLock()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public int numAttributes()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public boolean hasChildren()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public TreeNode getOrCreateChild(Object child_name, GlobalTransaction gtx, boolean createIfNotExists)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public TreeNode createChild(Object child_name, Fqn fqn, TreeNode parent, Object key, Object value)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void removeAllChildren()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void print(StringBuffer sb, int indent)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void printDetails(StringBuffer sb, int indent)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void printIndent(StringBuffer sb, int indent)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void addChild(Object child_name, Node n)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void printLockInfo(StringBuffer sb, int indent)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public boolean isLocked()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void releaseAll(Object owner)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void releaseAllForce()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public Set acquireAll(Object caller, long timeout, NodeLock.LockType lock_type) throws LockingException, TimeoutException, InterruptedException
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void setRecursiveTreeCacheInstance(TreeCache cache)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public boolean getChildrenLoaded()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void setChildrenLoaded(boolean b)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void setChildren(Map children)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void release(Object caller)
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
  -   public void releaseForce()
  -   {
  -      throw new UnsupportedOperationException("Unsupported for optimistic nodes");
  -   }
  -
      public String toString()
      {
         StringBuffer sb = new StringBuffer();
  @@ -476,7 +348,7 @@
            if (f.size() == 1)
            {
               Fqn ffqn = new Fqn(getFqn(), f);
  -            newNode = createChild(f.get(0), ffqn, this.node, getCache(), version);
  +            newNode = createChild(f.get(0), ffqn, node, getCache(), version);
            }
            else
            {
  @@ -484,6 +356,9 @@
               Node currentParent = this;
               for (Object o : f.peekElements())
               {
  +               if (currentParent instanceof WorkspaceNode)
  +                  newNode = ((WorkspaceNode) currentParent).getNode().getOrCreateChild(o, gtx);
  +               else
                  newNode = currentParent.getNodeSPI().getOrCreateChild(o, gtx);
                  currentParent = newNode;
               }
  @@ -507,9 +382,17 @@
   
      public Node getChild(Fqn f)
      {
  -      // ???
  +      boolean origVal = getCache().getInvocationContext().getOptionOverrides().isBypassInterceptorChain();
  +      if (!origVal) getCache().getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  +      try
  +      {
         return node.getChild(f);
      }
  +      finally
  +      {
  +         if (!origVal) getCache().getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  +      }
  +   }
   
      public Set<Node> getChildren()
      {
  @@ -524,6 +407,11 @@
         // return false;
      }
   
  +   public NodeSPI getNodeSPI()
  +   {
  +      throw new UnsupportedOperationException("WorkspaceNode has no access to a NodeSPI");
  +   }
  +
      public void move(Node newParent) throws NodeNotExistsException
      {
         throw new UnsupportedOperationException();
  @@ -556,11 +444,6 @@
         throw new UnsupportedOperationException();
      }
   
  -   public NodeSPI getNodeSPI()
  -   {
  -      return this;// node.getNodeSPI();
  -   }
  -
      public Node getOrCreateChild(Object name, GlobalTransaction tx)
      {
         throw new UnsupportedOperationException();
  @@ -573,7 +456,7 @@
   
      public CacheSPI getCache()
      {
  -      return node.getNodeSPI().getCache();
  +      return node.getCache();
      }
   
      public Map<Object, Object> getRawData()
  @@ -588,7 +471,7 @@
   
      public void setFqn(Fqn fqn)
      {
  -      node.getNodeSPI().setFqn(fqn);
  +      node.setFqn(fqn);
      }
   
      public boolean getDataLoaded()
  
  
  
  1.18      +10 -4     JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- WorkspaceNode.java	14 Dec 2006 17:18:48 -0000	1.17
  +++ WorkspaceNode.java	30 Dec 2006 17:50:04 -0000	1.18
  @@ -9,19 +9,19 @@
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeNode;
  +import org.jboss.cache.NodeSPI;
   
   import java.util.Map;
   import java.util.Set;
   
   /**
  - * Represents a type of {@link org.jboss.cache.NodeImpl} that is to be copied into a {@link TransactionWorkspace} for optimistically locked
  + * Represents a type of {@link org.jboss.cache.Node} that is to be copied into a {@link TransactionWorkspace} for optimistically locked
    * nodes.  Adds versioning and dirty flags over conventional Nodes.
    *
    * @author Manik Surtani (<a href="mailto:manik at jboss.org">manik at jboss.org</a>)
    * @author Steve Woodcock (<a href="mailto:stevew at jofti.com">stevew at jofti.com</a>)
    */
  -public interface WorkspaceNode extends TreeNode
  +public interface WorkspaceNode extends Node
   {
      public Map getMergedChildren();
   
  @@ -35,7 +35,7 @@
   
      public Map getMergedData();
   
  -   public Node getNode();
  +   public NodeSPI getNode();
   
      public Set getChildrenNames();
   
  @@ -50,4 +50,10 @@
      boolean isVersioningImplicit();
   
      void setVersioningImplicit(boolean b);
  +
  +   boolean isDeleted();
  +
  +   void markAsDeleted(boolean marker);
  +
  +   void markAsDeleted(boolean marker, boolean recursive);
   }
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:04 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:04 -0500
Subject: [jboss-cvs] JBossCache/tests/stress/org/jboss/cache   ...
Message-ID: <E1H0iLM-0008WK-Mg@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:04

  Modified:    tests/stress/org/jboss/cache   LocalStressTest.java
                        EvictionLocalStressTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.9       +5 -5      JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/LocalStressTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- LocalStressTest.java	20 Dec 2006 13:56:49 -0000	1.8
  +++ LocalStressTest.java	30 Dec 2006 17:50:04 -0000	1.9
  @@ -35,14 +35,14 @@
   //import java.text.FieldPosition;
   
   /**
  - * Local mode stress test for TreeCache.
  + * Local mode stress test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.8 $
  + * @version $Revision: 1.9 $
    */
   public class LocalStressTest extends TestCase
   {
  -   static TreeCache cache_;
  +   static CacheImpl cache_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.LOCAL;
      final static Properties p_;
      //   final static Log log_=LogFactory.getLog(LocalStressTestCase.class);
  @@ -101,7 +101,7 @@
      void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
         cachingMode_ = caching_mode;
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-lru-eviction-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache_.create();
  @@ -259,7 +259,7 @@
      }
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  
  
  
  1.8       +5 -5      JBossCache/tests/stress/org/jboss/cache/EvictionLocalStressTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionLocalStressTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/stress/org/jboss/cache/EvictionLocalStressTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- EvictionLocalStressTest.java	15 Sep 2006 15:11:35 -0000	1.7
  +++ EvictionLocalStressTest.java	30 Dec 2006 17:50:04 -0000	1.8
  @@ -27,14 +27,14 @@
   
   
   /**
  - * Local mode stress test for TreeCache.
  + * Local mode stress test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Id: EvictionLocalStressTest.java,v 1.7 2006/09/15 15:11:35 msurtani Exp $
  + * @version $Id: EvictionLocalStressTest.java,v 1.8 2006/12/30 17:50:04 msurtani Exp $
    */
   public class EvictionLocalStressTest extends TestCase
   {
  -   static TreeCache cache_;
  +   static CacheImpl cache_;
      Configuration.CacheMode cachingMode_ = Configuration.CacheMode.LOCAL;
      final static Properties p_;
      String oldFactory_ = null;
  @@ -90,7 +90,7 @@
      void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
         cachingMode_ = caching_mode;
  -      cache_ = new TreeCache();
  +      cache_ = new CacheImpl();
         cache_.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/local-lru-eviction-service.xml")); // read in generic local xml
         cache_.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         LockStrategyFactory.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
  @@ -268,7 +268,7 @@
      }
   
      /**
  -    * Generate the tree nodes quasi-exponentially. I.e., depth is the level
  +    * Generate the cache nodes quasi-exponentially. I.e., depth is the level
       * of the hierarchy and children is the number of children under each node.
       * This strucutre is used to add, get, and remove for each node.
       */
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:04 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:04 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache/manualtests  ...
Message-ID: <E1H0iLM-0008WR-Tx@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:04

  Modified:    tests/perf/org/jboss/cache/manualtests 
                        TcpCacheLoaderTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.4       +6 -6      JBossCache/tests/perf/org/jboss/cache/manualtests/TcpCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/manualtests/TcpCacheLoaderTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- TcpCacheLoaderTest.java	26 Oct 2006 19:30:21 -0000	1.3
  +++ TcpCacheLoaderTest.java	30 Dec 2006 17:50:04 -0000	1.4
  @@ -2,21 +2,21 @@
   
   import junit.textui.TestRunner;
   import org.jboss.cache.CacheException;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.loader.AbstractCacheLoaderTestBase;
  -import org.jboss.cache.loader.TcpDelegatingCacheLoaderConfig;
   import org.jboss.cache.loader.JDBCCacheLoaderPerfTest;
  +import org.jboss.cache.loader.TcpDelegatingCacheLoaderConfig;
   
   public class TcpCacheLoaderTest extends AbstractCacheLoaderTestBase
   {
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private static final int serverPort = 7500;
      private static final String serverHost = "127.0.0.1";
   
      protected void setUp() throws Exception
      {
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         CacheLoaderConfig clc = new CacheLoaderConfig();
         TcpDelegatingCacheLoaderConfig cfg = new TcpDelegatingCacheLoaderConfig();
         cfg.setHost(serverHost);
  @@ -79,11 +79,11 @@
   
      private class Runner extends Thread
      {
  -      private TreeCache cache;
  +      private CacheImpl cache;
         private int n;
         long totalTime;
   
  -      public Runner(TreeCache cache, int n, String instanceName)
  +      public Runner(CacheImpl cache, int n, String instanceName)
         {
            super(instanceName);
            this.cache = cache;
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/passivation ...
Message-ID: <E1H0iLN-00004v-1O@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    tests-50/functional/org/jboss/cache/pojo/passivation  
                        ReplicatedTest.java LocalTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.9       +23 -17    JBossCache/tests-50/functional/org/jboss/cache/pojo/passivation/ReplicatedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/passivation/ReplicatedTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ReplicatedTest.java	7 Nov 2006 03:58:58 -0000	1.8
  +++ ReplicatedTest.java	30 Dec 2006 17:50:05 -0000	1.9
  @@ -22,19 +22,19 @@
   
   package org.jboss.cache.pojo.passivation;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheListener;
  +import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.pojo.PojoCache;
   import org.jboss.cache.pojo.PojoCacheFactory;
  -import org.jboss.cache.pojo.test.Person;
   import org.jboss.cache.pojo.test.Address;
   import org.jboss.cache.pojo.test.Link;
  -import org.jboss.cache.Fqn;
  -import org.jboss.cache.CacheListener;
  -import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.pojo.test.Person;
   import org.jgroups.View;
   
   import java.util.Map;
  @@ -101,10 +101,10 @@
      private void sanityCheck() throws InterruptedException
      {
         Thread.sleep(100);
  -      if(listener_.getActivationCount() == 0 || listener_.getPassivationCount() == 0)
  +      if (listener_.getActivationCount() == 0 || listener_.getPassivationCount() == 0)
         {
  -         fail("Sanity checking for passivation failed. Counters: activation - " +listener_.getActivationCount()
  -          + " passivation - " +listener_.getPassivationCount());
  +         fail("Sanity checking for passivation failed. Counters: activation - " + listener_.getActivationCount()
  +                 + " passivation - " + listener_.getPassivationCount());
         }
   
         listener_.reset();
  @@ -119,9 +119,9 @@
         Thread.sleep(9100); // default is 3 seconds so joe should have been passivated.
   
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
  -      Person p = (Person)cache1_.find(id);
  +      Person p = (Person) cache1_.find(id);
         assertNotNull("Person on remote node ", p);
   
         sanityCheck();
  @@ -134,13 +134,13 @@
         Person joe = createPerson("Joe Black", 20);
         cache_.attach(id, joe);
   
  -      Person p = (Person)cache1_.find(id);
  +      Person p = (Person) cache1_.find(id);
         assertNotNull("Person on remote node ", p);
   
         Thread.sleep(9100); // default is 3 seconds so joe should have been passivated.
   
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
         Address addr = new Address();
         addr.setCity("Taipei");
  @@ -181,7 +181,7 @@
   
         Thread.sleep(9100); // default is 3 seconds so joe should have been passivated.
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
         assertEquals("City is ", "Santa Clara", add2.getCity());
   
  @@ -255,9 +255,15 @@
         int activation = 0;
         int passivation = 0;
   
  -      public int getActivationCount() { return activation;}
  +      public int getActivationCount()
  +      {
  +         return activation;
  +      }
   
  -      public int getPassivationCount() { return passivation;}
  +      public int getPassivationCount()
  +      {
  +         return passivation;
  +      }
   
         public void reset()
         {
  @@ -300,7 +306,7 @@
   
         public void nodeActivated(Fqn fqn, boolean pre)
         {
  -         if(!pre)
  +         if (!pre)
            {
               System.out.println("nodeActivated: " + fqn);
               activation++;
  @@ -309,7 +315,7 @@
   
         public void nodePassivated(Fqn fqn, boolean pre)
         {
  -         if(pre)
  +         if (pre)
            {
               System.out.println("nodePassivated: " + fqn);
               passivation++;
  
  
  
  1.10      +22 -19    JBossCache/tests-50/functional/org/jboss/cache/pojo/passivation/LocalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/passivation/LocalTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- LocalTest.java	8 Nov 2006 02:08:10 -0000	1.9
  +++ LocalTest.java	30 Dec 2006 17:50:05 -0000	1.10
  @@ -12,19 +12,16 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheListener;
  +import org.jboss.cache.CacheSPI;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.pojo.PojoCache;
   import org.jboss.cache.pojo.PojoCacheFactory;
   import org.jboss.cache.pojo.test.Address;
   import org.jboss.cache.pojo.test.Link;
   import org.jboss.cache.pojo.test.Person;
  -import org.jboss.cache.Fqn;
  -import org.jboss.cache.CacheListener;
  -import org.jboss.cache.CacheSPI;
  -import org.jboss.util.id.UID;
   import org.jgroups.View;
   
  -import java.util.ArrayList;
  -import java.util.List;
   import java.util.Map;
   
   /**
  @@ -84,10 +81,10 @@
   
      private void sanityCheck()
      {
  -      if(listener_.getActivationCount() == 0 || listener_.getPassivationCount() == 0)
  +      if (listener_.getActivationCount() == 0 || listener_.getPassivationCount() == 0)
         {
  -         fail("Sanity checking for passivation failed. Counters: activation - " +listener_.getActivationCount()
  -          + " passivation - " +listener_.getPassivationCount());
  +         fail("Sanity checking for passivation failed. Counters: activation - " + listener_.getActivationCount()
  +                 + " passivation - " + listener_.getPassivationCount());
         }
   
         listener_.reset();
  @@ -104,7 +101,7 @@
   //      assertFalse("Node should be evicted ",
   //              cache_.getCache().exists(id));
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
         assertEquals("age ", 20, joe.getAge());
         joe.setAge(30);
  @@ -122,7 +119,7 @@
         Thread.sleep(9100); // default is 3 seconds so joe should have been passivated.
   
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
         Address addr = new Address();
         addr.setCity("Taipei");
  @@ -144,14 +141,14 @@
   //      assertFalse("Node should be evicted ",
   //              cache_.getCache().exists(id));
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
   //      assertFalse("Node should be evicted ",
   //              cache_.getCache().exists(id));
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
  -      Person p = (Person)cache_.find(id);
  +      Person p = (Person) cache_.find(id);
   
         assertEquals("age ", 20, joe.getAge());
         joe.setAge(30);
  @@ -196,7 +193,7 @@
   //      assertFalse("Node should be evicted ",
   //              cache_.getCache().exists("/person/joe"));
         assertFalse("Node should be evicted ",
  -              cache_.getCache().hasChild(new Fqn(id)));
  +              cache_.getCache().getRoot().hasChild(new Fqn(id)));
   
         assertEquals("City is ", "Santa Clara", add2.getCity());
   
  @@ -270,9 +267,15 @@
         int activation = 0;
         int passivation = 0;
   
  -      public int getActivationCount() { return activation;}
  +      public int getActivationCount()
  +      {
  +         return activation;
  +      }
   
  -      public int getPassivationCount() { return passivation;}
  +      public int getPassivationCount()
  +      {
  +         return passivation;
  +      }
   
         public void reset()
         {
  @@ -315,7 +318,7 @@
   
         public void nodeActivated(Fqn fqn, boolean pre)
         {
  -         if(!pre)
  +         if (!pre)
            {
               System.out.println("nodeActivated: " + fqn);
               activation++;
  @@ -324,7 +327,7 @@
   
         public void nodePassivated(Fqn fqn, boolean pre)
         {
  -         if(pre)
  +         if (pre)
            {
               System.out.println("nodePassivated: " + fqn);
               passivation++;
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/invocationcontext ...
Message-ID: <E1H0iLN-000058-60@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    tests/functional/org/jboss/cache/invocationcontext 
                        TransactionTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.5       +3 -3      JBossCache/tests/functional/org/jboss/cache/invocationcontext/TransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/invocationcontext/TransactionTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- TransactionTest.java	31 Oct 2006 06:57:28 -0000	1.4
  +++ TransactionTest.java	30 Dec 2006 17:50:05 -0000	1.5
  @@ -42,8 +42,8 @@
         assertNull("Gtx should not have been set up yet", cache.getInvocationContext().getGlobalTransaction());
   
         // now make a WRITE call into the cache (should start a tx)
  -      cache.put("k", "v");
  -      Map data = cache.getData();
  +      cache.getRoot().put("k", "v");
  +      Map data = cache.getRoot().getData();
         assertEquals("Data map should not empty", 1, data.size());
   
         // but now we should have a local tx registered in the invocation context
  @@ -87,7 +87,7 @@
      private void doScrubbingTest(boolean commit) throws Exception
      {
         tm.begin();
  -      cache.put("key", "value");
  +      cache.getRoot().put("key", "value");
         assertNotNull("Tx should have been set up by now", cache.getInvocationContext().getTransaction());
         assertEquals("The same current transaction should be associated with this invocation ctx.", tm.getTransaction(), cache.getInvocationContext().getTransaction());
         assertNotNull("Gtx should have been set up by now", cache.getInvocationContext().getGlobalTransaction());
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs] JBossCache/examples/PojoCache/sensor  ...
Message-ID: <E1H0iLN-00005F-9s@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    examples/PojoCache/sensor  build.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.4       +74 -73    JBossCache/examples/PojoCache/sensor/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/examples/PojoCache/sensor/build.xml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- build.xml	25 Sep 2006 08:02:31 -0000	1.3
  +++ build.xml	30 Dec 2006 17:50:05 -0000	1.4
  @@ -1,26 +1,27 @@
   <?xml version="1.0"?>
   
  -<project name="junit examples" default="help" >
  +<project name="junit examples" default="help">
   
     <property name="build.sysclasspath" value="ignore"/>
  -  <property name="junit.timeout" value="180000"/> <!-- 3 minutes -->
  +   <property name="junit.timeout" value="180000"/>
  +   <!-- 3 minutes -->
   
     <property file="./build.properties"/>
   
     <!-- set local properties for this build -->
     <path id="lib.classpath">
         <fileset dir="${lib}">
  -        <include name="**/*.jar" />
  +         <include name="**/*.jar"/>
         </fileset>
         <pathelement path="${build}"/>
     </path>
   
     <target name="help" description="help page">
  -      <echo message="build.sh &lt;command&gt; where command is:" />
  -      <echo message="         compile       -- compile the examples code" />
  -      <echo message="         clobber       -- clean up the whole directory" />
  -      <echo message="         run.aopc.batch -- run batch aop examples with aopc pre-compiler" />
  -      <echo message="         run.aop.demo  -- run demo gui for aop cache" />
  +      <echo message="build.sh &lt;command&gt; where command is:"/>
  +      <echo message="         compile       -- compile the examples code"/>
  +      <echo message="         clobber       -- clean up the whole directory"/>
  +      <echo message="         run.aopc.batch -- run batch aop examples with aopc pre-compiler"/>
  +      <echo message="         run.aop.demo  -- run demo gui for aop cache"/>
     </target>
   
     <!-- set up directory -->
  @@ -28,7 +29,7 @@
       <!-- Create the time stamp -->
       <tstamp/>
       <!-- Create the build directory structure used by compile
  -    and copy the deployment descriptors into it-->
  +and copy the deployment descriptors into it-->
       <mkdir dir="${build}"/>
       <mkdir dir="${reports}"/>
     </target>
  @@ -38,7 +39,7 @@
       <delete dir="${reports}"/>
     </target>
   
  -  <target name="clobber" depends="clean" />
  +   <target name="clobber" depends="clean"/>
   
     <!-- compile directory -->
     <target name="compile" depends="init" description="Build unit testing class">
  @@ -48,7 +49,7 @@
              debug="true"
              deprecation="true">
         <classpath>
  -        <path refid="lib.classpath" />
  +            <path refid="lib.classpath"/>
         </classpath>
       </javac>
   
  @@ -72,20 +73,20 @@
      </target>
   
     <target name="run.aop.example" depends="compile, aopc" description="run standalone server replicator.">
  -    <java classname="test.propagation.PropagationReplAopTest" fork="yes" >
  -      <classpath refid="lib.classpath" />
  -      <classpath path="${build}" />
  -      <classpath path="${output}/etc" />
  +      <java classname="test.propagation.PropagationReplAopTest" fork="yes">
  +         <classpath refid="lib.classpath"/>
  +         <classpath path="${build}"/>
  +         <classpath path="${output}/etc"/>
       </java>
     </target>
   
  -  <target name="run.aop.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.aop.demo" depends="compile" description="run JBoss Cache demo.">
       <java classname="org.jboss.cache.TreeCacheView" fork="yes">
         <jvmarg value="-Xmx128M"/>
  -      <classpath refid="lib.classpath" />
  +         <classpath refid="lib.classpath"/>
         <sysproperty key="log4j.configuration" value="file:${output}/etc/log4j.xml"/>
  -      <classpath path="${output}/etc" />
  -      <classpath path="${build}" />
  +         <classpath path="${output}/etc"/>
  +         <classpath path="${build}"/>
       </java>
     </target>
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1H0iLN-00005c-HT@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    tests/functional/org/jboss/cache/replicated     
                        SyncReplTxTest.java ReplicationExceptionTest.java
                        SyncCacheListenerTest.java AsyncReplTest.java
                        SyncReplTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.16      +18 -18    JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- SyncReplTxTest.java	15 Dec 2006 15:18:48 -0000	1.15
  +++ SyncReplTxTest.java	30 Dec 2006 17:50:05 -0000	1.16
  @@ -15,8 +15,8 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractCacheListener;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.lock.TimeoutException;
  @@ -36,17 +36,17 @@
   import java.util.Map;
   
   /**
  - * Replicated unit test for sync transactional TreeCache
  + * Replicated unit test for sync transactional CacheImpl
    * Note: we use DummyTransactionManager for Tx purpose instead of relying on
    * jta.
    *
  - * @version $Revision: 1.15 $
  + * @version $Revision: 1.16 $
    */
   public class SyncReplTxTest extends TestCase
   {
      private static Log log = LogFactory.getLog(SyncReplTxTest.class);
  -   private TreeCache cache1;
  -   private TreeCache cache2;
  +   private CacheImpl cache1;
  +   private CacheImpl cache2;
   
      private String old_factory = null;
      private final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
  @@ -90,8 +90,8 @@
   
      private void initCaches(Configuration.CacheMode caching_mode) throws Exception
      {
  -      cache1 = new TreeCache();
  -      cache2 = new TreeCache();
  +      cache1 = new CacheImpl();
  +      cache2 = new CacheImpl();
         cache1.getConfiguration().setCacheMode(caching_mode);
         cache2.getConfiguration().setCacheMode(caching_mode);
         cache1.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  @@ -652,8 +652,8 @@
      {
         Object myMutex = new Object();
   
  -      final TreeCache c1 = new TreeCache();
  -      final TreeCache c2 = new TreeCache();
  +      final CacheImpl c1 = new CacheImpl();
  +      final CacheImpl c2 = new CacheImpl();
         c1.getConfiguration().setClusterName("TempCluster");
         c2.getConfiguration().setClusterName("TempCluster");
         c1.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
  @@ -778,8 +778,8 @@
      public void testConcurrentPutsOnTwoInstances() throws Exception
      {
         initCaches(Configuration.CacheMode.REPL_SYNC);
  -      final TreeCache c1 = this.cache1;
  -      final TreeCache c2 = this.cache2;
  +      final CacheImpl c1 = this.cache1;
  +      final CacheImpl c2 = this.cache2;
   
         Thread t1 = new Thread()
         {
  @@ -846,7 +846,7 @@
      public void testPut() throws Exception
      {
         initCaches(Configuration.CacheMode.REPL_SYNC);
  -      final TreeCache c1 = this.cache1;
  +      final CacheImpl c1 = this.cache1;
   
   
         Thread t1 = new Thread()
  @@ -987,7 +987,7 @@
      public void testPutTx1() throws Exception
      {
         initCaches(Configuration.CacheMode.REPL_SYNC);
  -      final TreeCache c1 = this.cache1;
  +      final CacheImpl c1 = this.cache1;
         Thread t1 = new Thread()
         {
            public void run()
  @@ -1085,7 +1085,7 @@
      public void testPutTxWithRollback() throws Exception
      {
         initCaches(Configuration.CacheMode.REPL_SYNC);
  -      final TreeCache c2 = this.cache1;
  +      final CacheImpl c2 = this.cache1;
         Thread t1 = new Thread()
         {
            public void run()
  @@ -1193,12 +1193,12 @@
      static class CallbackListener extends AbstractCacheListener
      {
   
  -      TreeCache callbackCache;
  +      CacheImpl callbackCache;
         Object callbackKey;
         Exception ex;
         Object mutex = new Object();
   
  -      CallbackListener(TreeCache cache, Object callbackKey)
  +      CallbackListener(CacheImpl cache, Object callbackKey)
         {
            this.callbackCache = cache;
            this.callbackKey = callbackKey;
  @@ -1241,7 +1241,7 @@
   
         TransactionManager callbackTM;
   
  -      TransactionAborterCallbackListener(TreeCache cache, Object callbackKey)
  +      TransactionAborterCallbackListener(CacheImpl cache, Object callbackKey)
         {
            super(cache, callbackKey);
            callbackTM = callbackCache.getTransactionManager();
  @@ -1283,7 +1283,7 @@
         Object mutex = new Object();
         Exception ex;
   
  -      TransactionAborterListener(TreeCache cache)
  +      TransactionAborterListener(CacheImpl cache)
         {
            callbackTM = cache.getTransactionManager();
            cache.getNotifier().addCacheListener(this);
  
  
  
  1.5       +84 -63    JBossCache/tests/functional/org/jboss/cache/replicated/ReplicationExceptionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicationExceptionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/ReplicationExceptionTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ReplicationExceptionTest.java	20 Jul 2006 10:32:03 -0000	1.4
  +++ ReplicationExceptionTest.java	30 Dec 2006 17:50:05 -0000	1.5
  @@ -12,30 +12,31 @@
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.transaction.DummyTransactionManager;
   
   import javax.naming.Context;
   import javax.transaction.NotSupportedException;
  +import javax.transaction.RollbackException;
   import javax.transaction.SystemException;
   import javax.transaction.Transaction;
  -import javax.transaction.RollbackException;
   import java.io.NotSerializableException;
   import java.io.Serializable;
   
   /**
    * Teting of replication exception for a Nonerislizable object
    *
  - * @version $Revision: 1.4 $
    * @author Ben Wang
  + * @version $Revision: 1.5 $
    */
  -public class ReplicationExceptionTest extends TestCase {
  -   TreeCache cache1, cache2;
  -   Configuration.CacheMode caching_mode= Configuration.CacheMode.REPL_SYNC;
  -   final String group_name="TreeCacheTestGroup";
  -   String props=
  +public class ReplicationExceptionTest extends TestCase
  +{
  +   CacheImpl cache1, cache2;
  +   Configuration.CacheMode caching_mode = Configuration.CacheMode.REPL_SYNC;
  +   final String group_name = "TreeCacheTestGroup";
  +   String props =
            "UDP(ip_mcast=true;ip_ttl=64;loopback=false;mcast_addr=228.1.2.3;" +
            "mcast_port=45566;mcast_recv_buf_size=80000;mcast_send_buf_size=150000;" +
            "ucast_recv_buf_size=80000;ucast_send_buf_size=150000):" +
  @@ -51,44 +52,50 @@
            "pbcast.GMS(join_retry_timeout=2000;join_timeout=5000;print_local_addr=true;shun=true):" +
            "pbcast.STATE_TRANSFER(down_thread=true;up_thread=true)";
   
  -   final static Log log_=LogFactory.getLog(ReplicationExceptionTest.class);
  -   String old_factory=null;
  -   final String FACTORY="org.jboss.cache.transaction.DummyContextFactory";
  +   final static Log log_ = LogFactory.getLog(ReplicationExceptionTest.class);
  +   String old_factory = null;
  +   final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
      DummyTransactionManager tx_mgr;
  -   Throwable t1_ex, t2_ex, ex=null;
  +   Throwable t1_ex, t2_ex, ex = null;
   
  -   public ReplicationExceptionTest(String name) {
  +   public ReplicationExceptionTest(String name)
  +   {
         super(name);
      }
   
  -   public void setUp() throws Exception {
  +   public void setUp() throws Exception
  +   {
         super.setUp();
  -      old_factory=System.getProperty(Context.INITIAL_CONTEXT_FACTORY);
  +      old_factory = System.getProperty(Context.INITIAL_CONTEXT_FACTORY);
         System.setProperty(Context.INITIAL_CONTEXT_FACTORY, FACTORY);
  -      tx_mgr=DummyTransactionManager.getInstance();
  -      t1_ex=t2_ex=ex=null;
  +      tx_mgr = DummyTransactionManager.getInstance();
  +      t1_ex = t2_ex = ex = null;
      }
   
  -   public void tearDown() throws Exception {
  +   public void tearDown() throws Exception
  +   {
         super.tearDown();
         DummyTransactionManager.destroy();
         destroyCaches();
  -      if(old_factory != null) {
  +      if (old_factory != null)
  +      {
            System.setProperty(Context.INITIAL_CONTEXT_FACTORY, old_factory);
  -         old_factory=null;
  +         old_factory = null;
         }
      }
   
  -   Transaction beginTransaction() throws SystemException, NotSupportedException {
  -      DummyTransactionManager mgr=DummyTransactionManager.getInstance();
  +   Transaction beginTransaction() throws SystemException, NotSupportedException
  +   {
  +      DummyTransactionManager mgr = DummyTransactionManager.getInstance();
         mgr.begin();
         return mgr.getTransaction();
      }
   
  -   void initCaches(Configuration.CacheMode caching_mode) throws Exception {
  -      this.caching_mode=caching_mode;
  -      cache1=new TreeCache();
  -      cache2=new TreeCache();
  +   void initCaches(Configuration.CacheMode caching_mode) throws Exception
  +   {
  +      this.caching_mode = caching_mode;
  +      cache1 = new CacheImpl();
  +      cache2 = new CacheImpl();
         cache1.getConfiguration().setCacheMode(caching_mode);
         cache2.getConfiguration().setCacheMode(caching_mode);
         cache1.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  @@ -106,17 +113,20 @@
         cache2.start();
      }
   
  -   void destroyCaches() throws Exception {
  -      if(cache1 != null)
  +   void destroyCaches() throws Exception
  +   {
  +      if (cache1 != null)
            cache1.stop();
  -      if(cache2 != null)
  +      if (cache2 != null)
            cache2.stop();
  -      cache1=null;
  -      cache2=null;
  +      cache1 = null;
  +      cache2 = null;
      }
   
  -   public void testNonSerializableRepl() throws Exception {
  -      try {
  +   public void testNonSerializableRepl() throws Exception
  +   {
  +      try
  +      {
            initCaches(Configuration.CacheMode.REPL_SYNC);
   
            cache1.put("/a/b/c", "test", new ContainerData());
  @@ -124,43 +134,52 @@
            // We should not come here.
            assertNotNull("NonSerializableData should not be null on cache2", cache2.get("/a/b/c", "test"));
         }
  -      catch(RuntimeException runtime) {
  -         Throwable t=runtime.getCause();
  -         if(t instanceof NotSerializableException) {
  +      catch (RuntimeException runtime)
  +      {
  +         Throwable t = runtime.getCause();
  +         if (t instanceof NotSerializableException)
  +         {
               System.out.println("received NotSerializableException - as expected");
            }
  -         else {
  +         else
  +         {
               fail("should have received NotSerializableException, but received " + t.getClass());
            }
         }
  -      catch(Exception exc) {
  +      catch (Exception exc)
  +      {
            fail("failure - we should not get here: " + exc);
         }
      }
   
  -   public void testNonSerizlableReplWithTx() throws Exception {
  +   public void testNonSerizlableReplWithTx() throws Exception
  +   {
         Transaction tx;
   
  -      try {
  +      try
  +      {
            initCaches(Configuration.CacheMode.REPL_SYNC);
   
  -         tx=beginTransaction();
  +         tx = beginTransaction();
            cache1.put("/a/b/c", "test", new ContainerData());
            tx.commit();
   
            // We should not come here.
            assertNotNull("NonSerializableData should not be null on cache2", cache2.get("/a/b/c", "test"));
         }
  -      catch(RollbackException rollback) {
  +      catch (RollbackException rollback)
  +      {
            System.out.println("received RollbackException - as expected");
         }
  -      catch(Exception e) {
  +      catch (Exception e)
  +      {
            // We should also examine that it is indeed throwing a NonSerilaizable exception.
            fail(e.toString());
         }
      }
   
  -   public static Test suite() throws Exception {
  +   public static Test suite() throws Exception
  +   {
         return new TestSuite(ReplicationExceptionTest.class);
      }
   
  @@ -170,14 +189,16 @@
         int i;
      }
   
  -   static class ContainerData implements Serializable {
  +   static class ContainerData implements Serializable
  +   {
         int i;
         NonSerializabeData non_serializable_data;
         private static final long serialVersionUID = -8322197791060897247L;
   
  -      public ContainerData() {
  -         i=99;
  -         non_serializable_data=new NonSerializabeData();
  +      public ContainerData()
  +      {
  +         i = 99;
  +         non_serializable_data = new NonSerializabeData();
         }
      }
   }
  
  
  
  1.12      +5 -5      JBossCache/tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncCacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- SyncCacheListenerTest.java	15 Dec 2006 15:18:48 -0000	1.11
  +++ SyncCacheListenerTest.java	30 Dec 2006 17:50:05 -0000	1.12
  @@ -14,8 +14,8 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.AbstractCacheListener;
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.lock.IsolationLevel;
   import org.jboss.cache.transaction.DummyTransactionManager;
  @@ -31,11 +31,11 @@
   /**
    * Test out the TreeCacheListener
    *
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class SyncCacheListenerTest extends TestCase
   {
  -   private TreeCache cache1, cache2;
  +   private CacheImpl cache1, cache2;
      private final static Log log_ = LogFactory.getLog(SyncCacheListenerTest.class);
      private String old_factory = null;
      private final String FACTORY = "org.jboss.cache.transaction.DummyContextFactory";
  @@ -79,8 +79,8 @@
   
      private void initCaches() throws Exception
      {
  -      cache1 = new TreeCache();
  -      cache2 = new TreeCache();
  +      cache1 = new CacheImpl();
  +      cache2 = new CacheImpl();
         cache1.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         cache2.getConfiguration().setCacheMode(Configuration.CacheMode.REPL_SYNC);
         cache1.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
  
  
  
  1.12      +13 -13    JBossCache/tests/functional/org/jboss/cache/replicated/AsyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/AsyncReplTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- AsyncReplTest.java	6 Sep 2006 15:31:00 -0000	1.11
  +++ AsyncReplTest.java	30 Dec 2006 17:50:05 -0000	1.12
  @@ -13,22 +13,22 @@
   import junit.framework.Test;
   import junit.framework.TestCase;
   import junit.framework.TestSuite;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.misc.TestingUtil;
   
   import javax.transaction.TransactionManager;
   
   /**
  - * Unit test for replicated async TreeCache. Use locking and multiple threads to test
  + * Unit test for replicated async CacheImpl. Use locking and multiple threads to test
    * concurrent access to the tree.
    *
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class AsyncReplTest extends TestCase
   {
  -   TreeCache cache1, cache2;
  +   CacheImpl cache1, cache2;
      String props = null;
   
      public AsyncReplTest(String name)
  @@ -47,14 +47,14 @@
         cache2 = createCache("CacheGroup");
      }
   
  -   private TreeCache createCache(String name) throws Exception
  +   private CacheImpl createCache(String name) throws Exception
      {
  -      TreeCache tree = new TreeCache();
  -      tree.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  -      tree.getConfiguration().setClusterName(name);
  -      tree.create();
  -      tree.start();
  -      return tree;
  +      CacheImpl cache = new CacheImpl();
  +      cache.setConfiguration(new XmlConfigurationParser().parseFile("META-INF/replAsync-service.xml"));
  +      cache.getConfiguration().setClusterName(name);
  +      cache.create();
  +      cache.start();
  +      return cache;
      }
   
      protected void tearDown() throws Exception
  @@ -130,7 +130,7 @@
   
      public void testPutShouldNotReplicateToDifferentCluster()
      {
  -      TreeCache cache3 = null;
  +      CacheImpl cache3 = null;
         try
         {
            cache3 = createCache("DifferentGroup");
  @@ -155,7 +155,7 @@
   
      public void testStateTransfer()
      {
  -      TreeCache cache4 = null;
  +      CacheImpl cache4 = null;
         try
         {
            cache1.put("a/b/c", "age", new Integer(38));
  
  
  
  1.4       +7 -9      JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/SyncReplTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- SyncReplTest.java	31 Oct 2006 06:57:28 -0000	1.3
  +++ SyncReplTest.java	30 Dec 2006 17:50:05 -0000	1.4
  @@ -8,11 +8,9 @@
   
   import junit.framework.TestCase;
   import org.jboss.cache.Cache;
  -import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.InvocationContext;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCacheProxyImpl;
   import org.jboss.cache.config.Option;
   import org.jboss.cache.factories.DefaultCacheFactory;
   import org.jboss.cache.misc.TestingUtil;
  @@ -58,10 +56,10 @@
         Fqn f = Fqn.fromString("/test/data");
         String k = "key", v = "value";
   
  -      assertNull("Should be null", caches[0].getChild(f));
  -      assertNull("Should be null", caches[1].getChild(f));
  +      assertNull("Should be null", caches[0].getRoot().getChild(f));
  +      assertNull("Should be null", caches[1].getRoot().getChild(f));
   
  -      Node node = caches[0].addChild(f);
  +      Node node = caches[0].getRoot().addChild(f);
   
         assertNotNull("Should not be null", node);
   
  @@ -92,13 +90,13 @@
      {
         for (Cache c : caches)
         {
  -         assertClusterSize(message, size, (TreeCacheProxyImpl) c);
  +         assertClusterSize(message, size, c);
         }
      }
   
  -   private void assertClusterSize(String message, int size, TreeCacheProxyImpl tcpi)
  +   private void assertClusterSize(String message, int size, Cache c)
      {
  -      assertEquals(message, size, tcpi.treeCache.getMembers().size());
  +      assertEquals(message, size, c.getMembers().size());
      }
   
      private void assertInvocationContextInitState()
  @@ -111,7 +109,7 @@
   
      private void assertInvocationContextInitState(Cache c)
      {
  -      InvocationContext ctx = ((CacheSPI) c).getInvocationContext();
  +      InvocationContext ctx = c.getInvocationContext();
         InvocationContext control = null;
         try
         {
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction    ...
Message-ID: <E1H0iLN-00005p-Mf@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    src/org/jboss/cache/eviction    LRUPolicy.java
                        BaseEvictionPolicy.java EvictionPolicy.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.12      +3 -3      JBossCache/src/org/jboss/cache/eviction/LRUPolicy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LRUPolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/LRUPolicy.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- LRUPolicy.java	14 Nov 2006 14:17:11 -0000	1.11
  +++ LRUPolicy.java	30 Dec 2006 17:50:05 -0000	1.12
  @@ -7,7 +7,7 @@
    */
   package org.jboss.cache.eviction;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.RegionManager;
   
   /**
  @@ -16,7 +16,7 @@
    *
    * @author Ben Wang 02-2004
    * @author Daniel Huang - dhuang at jboss.org
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class LRUPolicy extends BaseEvictionPolicy implements EvictionPolicy
   {
  @@ -40,7 +40,7 @@
         return LRUConfiguration.class;
      }
   
  -   public void configure(TreeCache cache)
  +   public void configure(CacheImpl cache)
      {
         super.configure(cache);
         regionManager_ = cache_.getRegionManager();
  
  
  
  1.6       +7 -6      JBossCache/src/org/jboss/cache/eviction/BaseEvictionPolicy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BaseEvictionPolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/BaseEvictionPolicy.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- BaseEvictionPolicy.java	27 Nov 2006 04:49:46 -0000	1.5
  +++ BaseEvictionPolicy.java	30 Dec 2006 17:50:05 -0000	1.6
  @@ -1,9 +1,9 @@
   package org.jboss.cache.eviction;
   
   import org.jboss.cache.CacheException;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
  -import org.jboss.cache.TreeCache;
   
   import java.util.Set;
   
  @@ -12,11 +12,11 @@
    *
    * @author Ben Wang  2-2004
    * @author Daniel Huang - dhuang at jboss.org
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public abstract class BaseEvictionPolicy implements EvictionPolicy
   {
  -   protected TreeCache cache_;
  +   protected CacheImpl cache_;
   
      public BaseEvictionPolicy()
      {
  @@ -74,7 +74,7 @@
         }
      }
   
  -   public void configure(TreeCache cache)
  +   public void configure(CacheImpl cache)
      {
         this.cache_ = cache;
      }
  @@ -84,7 +84,8 @@
       * @see org.jboss.cache.eviction.EvictionPolicy#canIgnoreEvent(org.jboss.cache.Fqn)
       * 
       */
  -   public boolean canIgnoreEvent(Fqn fqn, NodeEventType eventType) {
  +   public boolean canIgnoreEvent(Fqn fqn, NodeEventType eventType)
  +   {
          return false;
      }
   }
  
  
  
  1.9       +8 -9      JBossCache/src/org/jboss/cache/eviction/EvictionPolicy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionPolicy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/EvictionPolicy.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- EvictionPolicy.java	27 Nov 2006 04:49:46 -0000	1.8
  +++ EvictionPolicy.java	30 Dec 2006 17:50:05 -0000	1.9
  @@ -6,8 +6,8 @@
    */
   package org.jboss.cache.eviction;
   
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   
   import java.util.Set;
   
  @@ -51,7 +51,7 @@
      /**
       * Method called to configure this implementation.
       */
  -   void configure(TreeCache cache);
  +   void configure(CacheImpl cache);
   
      /**
       * Get the associated EvictionAlgorithm used by the EvictionPolicy.
  @@ -72,28 +72,27 @@
      /**
       * This method will be invoked prior to an event being processed for a node
       * with the specified Fqn.
  -    * <p>
  +    * <p/>
       * This method provides a way to optimize the performance of eviction by 
       * signalling that the node associated with the specified Fqn should not be
       * subject to normal eviction processing.  It can also be used to filter
       * out certain {@link NodeEventType event types} in which the particular
       * eviction algorithm has no interest.
       * </p>
  -    * <p>
  +    * <p/>
       * If this method returns false then the event is processed normally
       * and eviction processing for the node continues. As a result, the event
       * will be added to the {@link org.jboss.cache.Region eviction region's} event queue where
       * at some later point the particular algorithm of the eviction policy
       * can use it to decide whether to call {@link #evict(Fqn)}.
       * </p>
  -    * <p>
  +    * <p/>
       * If this method returns true, then the event is ignored and will not factor
       * in any subsequent eviction processing.
       * </p>
       * 
       * @param fqn The Fqn of the node associated with the event.
       * @param eventType the type of the event
  -    * 
       * @return <code>true</code> to ignore events of this type for this Fqn,
       *         <code>false</code> to process events normally.
       */
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/invalidation
	...
Message-ID: <E1H0iLN-00005w-QO@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    tests/functional/org/jboss/cache/invalidation 
                        InvalidationInterceptorTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.19      +27 -27    JBossCache/tests/functional/org/jboss/cache/invalidation/InvalidationInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvalidationInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/invalidation/InvalidationInterceptorTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- InvalidationInterceptorTest.java	25 Oct 2006 04:50:20 -0000	1.18
  +++ InvalidationInterceptorTest.java	30 Dec 2006 17:50:05 -0000	1.19
  @@ -13,8 +13,8 @@
   import junit.textui.TestRunner;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
  @@ -39,8 +39,8 @@
   
      public void testPessimisticNonTransactional() throws Exception
      {
  -      TreeCache cache1 = createCache(false);
  -      TreeCache cache2 = createCache(false);
  +      CacheImpl cache1 = createCache(false);
  +      CacheImpl cache2 = createCache(false);
   
         Fqn fqn = Fqn.fromString("/a/b");
         cache1.put(fqn, "key", "value");
  @@ -70,8 +70,8 @@
   
      public void testUnnecessaryEvictions() throws Exception
      {
  -      TreeCache cache1 = createCache(false);
  -      TreeCache cache2 = createCache(false);
  +      CacheImpl cache1 = createCache(false);
  +      CacheImpl cache2 = createCache(false);
   
         Fqn fqn1 = Fqn.fromString("/a/b/c");
         Fqn fqn2 = Fqn.fromString("/a/b/d");
  @@ -103,8 +103,8 @@
   
      public void testPessimisticNonTransactionalAsync() throws Exception
      {
  -      TreeCache cache1 = createUnstartedCache(false);
  -      TreeCache cache2 = createUnstartedCache(false);
  +      CacheImpl cache1 = createUnstartedCache(false);
  +      CacheImpl cache2 = createUnstartedCache(false);
         cache1.getConfiguration().setCacheMode(Configuration.CacheMode.INVALIDATION_ASYNC);
         cache2.getConfiguration().setCacheMode(Configuration.CacheMode.INVALIDATION_ASYNC);
         cache1.start();
  @@ -141,8 +141,8 @@
   
      public void testPessimisticTransactional() throws Exception
      {
  -      TreeCache cache1 = createCache(false);
  -      TreeCache cache2 = createCache(false);
  +      CacheImpl cache1 = createCache(false);
  +      CacheImpl cache2 = createCache(false);
   
         Fqn fqn = Fqn.fromString("/a/b");
         cache1.put(fqn, "key", "value");
  @@ -201,8 +201,8 @@
   
      public void testOptSyncUnableToEvict() throws Exception
      {
  -      TreeCache cache1 = createCache(true);
  -      TreeCache cache2 = createCache(true);
  +      CacheImpl cache1 = createCache(true);
  +      CacheImpl cache2 = createCache(true);
   
         Fqn fqn = Fqn.fromString("/a/b");
   
  @@ -251,8 +251,8 @@
   
      public void testPessTxSyncUnableToEvict() throws Exception
      {
  -      TreeCache cache1 = createCache(false);
  -      TreeCache cache2 = createCache(false);
  +      CacheImpl cache1 = createCache(false);
  +      CacheImpl cache2 = createCache(false);
   
         Fqn fqn = Fqn.fromString("/a/b");
   
  @@ -301,8 +301,8 @@
   
      public void testPessTxAsyncUnableToEvict() throws Exception
      {
  -      TreeCache cache1 = createUnstartedCache(false);
  -      TreeCache cache2 = createUnstartedCache(false);
  +      CacheImpl cache1 = createUnstartedCache(false);
  +      CacheImpl cache2 = createUnstartedCache(false);
         cache1.getConfiguration().setCacheMode(Configuration.CacheMode.INVALIDATION_ASYNC);
         cache2.getConfiguration().setCacheMode(Configuration.CacheMode.INVALIDATION_ASYNC);
         cache1.start();
  @@ -356,8 +356,8 @@
   
      public void testOptimistic() throws Exception
      {
  -      TreeCache cache1 = createCache(true);
  -      TreeCache cache2 = createCache(true);
  +      CacheImpl cache1 = createCache(true);
  +      CacheImpl cache2 = createCache(true);
   
         Fqn fqn = Fqn.fromString("/a/b");
         cache1.put(fqn, "key", "value");
  @@ -424,7 +424,7 @@
   
      public void testPessimisticNonTransactionalWithCacheLoader() throws Exception
      {
  -      TreeCache[] caches = createCachesWithSharedCL(false);
  +      CacheImpl[] caches = createCachesWithSharedCL(false);
   
         Fqn fqn = Fqn.fromString("/a/b");
         caches[0].put(fqn, "key", "value");
  @@ -455,7 +455,7 @@
   
      public void testPessimisticTransactionalWithCacheLoader() throws Exception
      {
  -      TreeCache[] caches = createCachesWithSharedCL(false);
  +      CacheImpl[] caches = createCachesWithSharedCL(false);
   
         Fqn fqn = Fqn.fromString("/a/b");
         TransactionManager mgr = caches[0].getTransactionManager();
  @@ -488,7 +488,7 @@
   
      public void testOptimisticWithCacheLoader() throws Exception
      {
  -      TreeCache[] caches = createCachesWithSharedCL(true);
  +      CacheImpl[] caches = createCachesWithSharedCL(true);
   
         Fqn fqn = Fqn.fromString("/a/b");
         TransactionManager mgr = caches[0].getTransactionManager();
  @@ -533,7 +533,7 @@
   
      protected void doRegionBasedTest(boolean optimistic) throws Exception
      {
  -      TreeCache[] caches = new TreeCache[2];
  +      CacheImpl[] caches = new CacheImpl[2];
         caches[0] = createUnstartedCache(false);
         caches[1] = createUnstartedCache(false);
   
  @@ -574,9 +574,9 @@
         caches[1] = null;
      }
   
  -   protected TreeCache createUnstartedCache(boolean optimistic) throws Exception
  +   protected CacheImpl createUnstartedCache(boolean optimistic) throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setClusterName("MyCluster");
         cache.getConfiguration().setInitialStateRetrievalTimeout(3000);
         cache.getConfiguration().setCacheMode(Configuration.CacheMode.INVALIDATION_SYNC);
  @@ -585,16 +585,16 @@
         return cache;
      }
   
  -   protected TreeCache createCache(boolean optimistic) throws Exception
  +   protected CacheImpl createCache(boolean optimistic) throws Exception
      {
  -      TreeCache cache = createUnstartedCache(optimistic);
  +      CacheImpl cache = createUnstartedCache(optimistic);
         cache.start();
         return cache;
      }
   
  -   protected TreeCache[] createCachesWithSharedCL(boolean optimistic) throws Exception
  +   protected CacheImpl[] createCachesWithSharedCL(boolean optimistic) throws Exception
      {
  -      TreeCache[] caches = new TreeCache[2];
  +      CacheImpl[] caches = new CacheImpl[2];
         caches[0] = createUnstartedCache(optimistic);
         caches[1] = createUnstartedCache(optimistic);
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:05 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:05 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall   ...
Message-ID: <E1H0iLN-000066-VY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:05

  Modified:    src/org/jboss/cache/marshall   MethodDeclarations.java
                        TreeCacheMarshaller200.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.28      +51 -51    JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodDeclarations.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/MethodDeclarations.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- MethodDeclarations.java	20 Dec 2006 22:28:12 -0000	1.27
  +++ MethodDeclarations.java	30 Dec 2006 17:50:05 -0000	1.28
  @@ -8,10 +8,10 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.DataNode;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.Node;
   import org.jboss.cache.buddyreplication.BuddyGroup;
   import org.jboss.cache.lock.NodeLock;
   import org.jboss.cache.optimistic.DataVersion;
  @@ -31,7 +31,7 @@
    * allowing lookup operations both ways.
    *
    * @author <a href="galder.zamarreno at jboss.com">Galder Zamarreno</a>
  - * @version $Revision: 1.27 $
  + * @version $Revision: 1.28 $
    */
   public class MethodDeclarations
   {
  @@ -42,7 +42,7 @@
      static final Set<Integer> buddyGroupOrganisationMethodIds = new HashSet<Integer>();
      static final Set<Integer> putMethodIds = new HashSet<Integer>();
   
  -   // maintain a list of method IDs that correspond to Methods in TreeCache
  +   // maintain a list of method IDs that correspond to Methods in CacheImpl
      static final Map<Integer, Method> methods = new HashMap<Integer, Method>();
   
      // and for reverse lookup
  @@ -221,59 +221,59 @@
      {
         try
         {
  -         getDataMapMethodLocal = TreeCache.class.getDeclaredMethod("_getData", Fqn.class);
  -         existsMethod = TreeCache.class.getDeclaredMethod("exists", Fqn.class);
  -         putDataMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class);
  -         putDataEraseMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, boolean.class);
  -         putKeyValMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Object.class, Object.class, boolean.class);
  -         removeNodeMethodLocal = TreeCache.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, boolean.class);
  -         removeKeyMethodLocal = TreeCache.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, Object.class, boolean.class);
  -         removeDataMethodLocal = TreeCache.class.getDeclaredMethod("_removeData", GlobalTransaction.class, Fqn.class, boolean.class);
  -         evictNodeMethodLocal = TreeCache.class.getDeclaredMethod("_evict", Fqn.class);
  -         evictVersionedNodeMethodLocal = TreeCache.class.getDeclaredMethod("_evict", Fqn.class, DataVersion.class);
  -
  -         // evictKeyValueMethodLocal=TreeCache.class.getDeclaredMethod("_evict", new Class[]{Fqn.class, Object.class});
  -         prepareMethod = TreeCache.class.getDeclaredMethod("prepare", GlobalTransaction.class, List.class, Address.class, boolean.class);
  -         commitMethod = TreeCache.class.getDeclaredMethod("commit", GlobalTransaction.class);
  -         rollbackMethod = TreeCache.class.getDeclaredMethod("rollback", GlobalTransaction.class);
  -         addChildMethodLocal = TreeCache.class.getDeclaredMethod("_addChild", GlobalTransaction.class, Fqn.class, Object.class, DataNode.class, boolean.class);
  -         getKeyValueMethodLocal = TreeCache.class.getDeclaredMethod("_get", Fqn.class, Object.class, boolean.class);
  -         getNodeMethodLocal = TreeCache.class.getDeclaredMethod("_get", Fqn.class);
  -         getKeysMethodLocal = TreeCache.class.getDeclaredMethod("_getKeys", Fqn.class);
  -         getChildrenNamesMethodLocal = TreeCache.class.getDeclaredMethod("_getChildrenNames", Fqn.class);
  -         replicateMethod = TreeCache.class.getDeclaredMethod("_replicate", MethodCall.class);
  -         replicateAllMethod = TreeCache.class.getDeclaredMethod("_replicate", List.class);
  -         releaseAllLocksMethodLocal = TreeCache.class.getDeclaredMethod("_releaseAllLocks", Fqn.class);
  -         printMethodLocal = TreeCache.class.getDeclaredMethod("_print", Fqn.class);
  -         lockMethodLocal = TreeCache.class.getDeclaredMethod("_lock", Fqn.class, NodeLock.LockType.class, boolean.class);
  +         getDataMapMethodLocal = CacheImpl.class.getDeclaredMethod("_getData", Fqn.class);
  +         existsMethod = CacheImpl.class.getDeclaredMethod("exists", Fqn.class);
  +         putDataMethodLocal = CacheImpl.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class);
  +         putDataEraseMethodLocal = CacheImpl.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, boolean.class);
  +         putKeyValMethodLocal = CacheImpl.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Object.class, Object.class, boolean.class);
  +         removeNodeMethodLocal = CacheImpl.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, boolean.class);
  +         removeKeyMethodLocal = CacheImpl.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, Object.class, boolean.class);
  +         removeDataMethodLocal = CacheImpl.class.getDeclaredMethod("_removeData", GlobalTransaction.class, Fqn.class, boolean.class);
  +         evictNodeMethodLocal = CacheImpl.class.getDeclaredMethod("_evict", Fqn.class);
  +         evictVersionedNodeMethodLocal = CacheImpl.class.getDeclaredMethod("_evict", Fqn.class, DataVersion.class);
  +
  +         // evictKeyValueMethodLocal=CacheImpl.class.getDeclaredMethod("_evict", new Class[]{Fqn.class, Object.class});
  +         prepareMethod = CacheImpl.class.getDeclaredMethod("prepare", GlobalTransaction.class, List.class, Address.class, boolean.class);
  +         commitMethod = CacheImpl.class.getDeclaredMethod("commit", GlobalTransaction.class);
  +         rollbackMethod = CacheImpl.class.getDeclaredMethod("rollback", GlobalTransaction.class);
  +         addChildMethodLocal = CacheImpl.class.getDeclaredMethod("_addChild", GlobalTransaction.class, Fqn.class, Object.class, Node.class, boolean.class);
  +         getKeyValueMethodLocal = CacheImpl.class.getDeclaredMethod("_get", Fqn.class, Object.class, boolean.class);
  +         getNodeMethodLocal = CacheImpl.class.getDeclaredMethod("_get", Fqn.class);
  +         getKeysMethodLocal = CacheImpl.class.getDeclaredMethod("_getKeys", Fqn.class);
  +         getChildrenNamesMethodLocal = CacheImpl.class.getDeclaredMethod("_getChildrenNames", Fqn.class);
  +         replicateMethod = CacheImpl.class.getDeclaredMethod("_replicate", MethodCall.class);
  +         replicateAllMethod = CacheImpl.class.getDeclaredMethod("_replicate", List.class);
  +         releaseAllLocksMethodLocal = CacheImpl.class.getDeclaredMethod("_releaseAllLocks", Fqn.class);
  +         printMethodLocal = CacheImpl.class.getDeclaredMethod("_print", Fqn.class);
  +         lockMethodLocal = CacheImpl.class.getDeclaredMethod("_lock", Fqn.class, NodeLock.LockType.class, boolean.class);
   
  -         optimisticPrepareMethod = TreeCache.class.getDeclaredMethod("optimisticPrepare", GlobalTransaction.class, List.class, Map.class, Address.class, boolean.class);
  +         optimisticPrepareMethod = CacheImpl.class.getDeclaredMethod("optimisticPrepare", GlobalTransaction.class, List.class, Map.class, Address.class, boolean.class);
   
  -         clusteredGetMethod = TreeCache.class.getDeclaredMethod("_clusteredGet", MethodCall.class, Boolean.class);
  +         clusteredGetMethod = CacheImpl.class.getDeclaredMethod("_clusteredGet", MethodCall.class, Boolean.class);
   
            // ------------ buddy replication
   
  -         remoteAnnounceBuddyPoolNameMethod = TreeCache.class.getDeclaredMethod("_remoteAnnounceBuddyPoolName", IpAddress.class, String.class);
  -         remoteRemoveFromBuddyGroupMethod = TreeCache.class.getDeclaredMethod("_remoteRemoveFromBuddyGroup", String.class);
  -         remoteAssignToBuddyGroupMethod = TreeCache.class.getDeclaredMethod("_remoteAssignToBuddyGroup", BuddyGroup.class, Map.class);
  +         remoteAnnounceBuddyPoolNameMethod = CacheImpl.class.getDeclaredMethod("_remoteAnnounceBuddyPoolName", IpAddress.class, String.class);
  +         remoteRemoveFromBuddyGroupMethod = CacheImpl.class.getDeclaredMethod("_remoteRemoveFromBuddyGroup", String.class);
  +         remoteAssignToBuddyGroupMethod = CacheImpl.class.getDeclaredMethod("_remoteAssignToBuddyGroup", BuddyGroup.class, Map.class);
   
  -         dataGravitationCleanupMethod = TreeCache.class.getDeclaredMethod("_dataGravitationCleanup", GlobalTransaction.class, Fqn.class, Fqn.class);
  -         dataGravitationMethod = TreeCache.class.getDeclaredMethod("_gravitateData", Fqn.class, boolean.class, boolean.class);
  +         dataGravitationCleanupMethod = CacheImpl.class.getDeclaredMethod("_dataGravitationCleanup", GlobalTransaction.class, Fqn.class, Fqn.class);
  +         dataGravitationMethod = CacheImpl.class.getDeclaredMethod("_gravitateData", Fqn.class, boolean.class, boolean.class);
   
            // ------------ move() api
  -         moveMethodLocal = TreeCache.class.getDeclaredMethod("_move", Fqn.class, Fqn.class);
  +         moveMethodLocal = CacheImpl.class.getDeclaredMethod("_move", Fqn.class, Fqn.class);
            
            // ------------ Channel BLOCK event 
  -         blockChannelLocal =  TreeCache.class.getDeclaredMethod("_block"); 
  -         unblockChannelLocal =  TreeCache.class.getDeclaredMethod("_unblock"); 
  +         blockChannelLocal = CacheImpl.class.getDeclaredMethod("_block");
  +         unblockChannelLocal = CacheImpl.class.getDeclaredMethod("_unblock");
   
            // ------------ version-aware methods - see JBCACHE-843
  -         putDataVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, DataVersion.class);
  -         putDataEraseVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, boolean.class, DataVersion.class);
  -         putKeyValVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Object.class, Object.class, boolean.class, DataVersion.class);
  -         removeNodeVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, boolean.class, DataVersion.class);
  -         removeKeyVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, Object.class, boolean.class, DataVersion.class);
  -         removeDataVersionedMethodLocal = TreeCache.class.getDeclaredMethod("_removeData", GlobalTransaction.class, Fqn.class, boolean.class, DataVersion.class);
  +         putDataVersionedMethodLocal = CacheImpl.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, DataVersion.class);
  +         putDataEraseVersionedMethodLocal = CacheImpl.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Map.class, boolean.class, boolean.class, DataVersion.class);
  +         putKeyValVersionedMethodLocal = CacheImpl.class.getDeclaredMethod("_put", GlobalTransaction.class, Fqn.class, Object.class, Object.class, boolean.class, DataVersion.class);
  +         removeNodeVersionedMethodLocal = CacheImpl.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, boolean.class, DataVersion.class);
  +         removeKeyVersionedMethodLocal = CacheImpl.class.getDeclaredMethod("_remove", GlobalTransaction.class, Fqn.class, Object.class, boolean.class, DataVersion.class);
  +         removeDataVersionedMethodLocal = CacheImpl.class.getDeclaredMethod("_removeData", GlobalTransaction.class, Fqn.class, boolean.class, DataVersion.class);
   
         }
         catch (NoSuchMethodException ex)
  
  
  
  1.12      +1 -1      JBossCache/src/org/jboss/cache/marshall/TreeCacheMarshaller200.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheMarshaller200.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/TreeCacheMarshaller200.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- TreeCacheMarshaller200.java	29 Dec 2006 15:18:20 -0000	1.11
  +++ TreeCacheMarshaller200.java	30 Dec 2006 17:50:05 -0000	1.12
  @@ -29,7 +29,7 @@
   import java.util.Set;
   
   /**
  - * An enhanced marshaller for RPC calls between TreeCache instances.
  + * An enhanced marshaller for RPC calls between CacheImpl instances.
    *
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    */
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/notifications  ...
Message-ID: <E1H0iLO-00006E-3x@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:06

  Modified:    src/org/jboss/cache/notifications  Notifier.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.12      +15 -19    JBossCache/src/org/jboss/cache/notifications/Notifier.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Notifier.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/notifications/Notifier.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- Notifier.java	20 Nov 2006 08:51:50 -0000	1.11
  +++ Notifier.java	30 Dec 2006 17:50:06 -0000	1.12
  @@ -8,22 +8,18 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.CacheListener;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.InvocationContext;
  -import org.jboss.cache.TreeCache;
   import org.jgroups.View;
   
  -import java.util.concurrent.CopyOnWriteArraySet;
  -import java.util.AbstractMap;
  -import java.util.AbstractSet;
  -import java.util.Arrays;
   import java.util.Collections;
   import java.util.HashMap;
  -import java.util.Iterator;
   import java.util.Map;
   import java.util.Set;
  +import java.util.concurrent.CopyOnWriteArraySet;
   
   /**
    * Helper class that handles all notifications to registered listeners.
  @@ -45,13 +41,13 @@
      private CacheListener evictionPolicyListener;
   
      private Set<CacheListener> listeners = new CopyOnWriteArraySet();
  -   private TreeCache treeCache;
  +   private CacheImpl cache;
      private InvocationContext tempCtx;
      private Log log = LogFactory.getLog(Notifier.class);
   
  -   public Notifier(TreeCache treeCache)
  +   public Notifier(CacheImpl cache)
      {
  -      this.treeCache = treeCache;
  +      this.cache = cache;
      }
   
      /**
  @@ -120,7 +116,7 @@
      public synchronized void notifyNodeCreated(Fqn fqn, boolean pre)
      {
   
  -      boolean originLocal = treeCache.getInvocationContext().isOriginLocal();
  +      boolean originLocal = cache.getInvocationContext().isOriginLocal();
         resetInvocationContext();
         if (evictionPolicyListener != null)
         {
  @@ -152,7 +148,7 @@
       */
      public synchronized void notifyNodeModified(Fqn fqn, boolean pre, Map data)
      {
  -      boolean originLocal = treeCache.getInvocationContext().isOriginLocal();
  +      boolean originLocal = cache.getInvocationContext().isOriginLocal();
         resetInvocationContext();
         if (evictionPolicyListener != null)
         {
  @@ -177,7 +173,7 @@
       */
      public synchronized void notifyNodeRemoved(Fqn fqn, boolean pre, Map data)
      {
  -      boolean originLocal = treeCache.getInvocationContext().isOriginLocal();
  +      boolean originLocal = cache.getInvocationContext().isOriginLocal();
         resetInvocationContext();
         if (evictionPolicyListener != null)
         {
  @@ -224,7 +220,7 @@
       */
      public synchronized void notifyNodeEvicted(Fqn fqn, boolean pre)
      {
  -      boolean originLocal = treeCache.getInvocationContext().isOriginLocal();
  +      boolean originLocal = cache.getInvocationContext().isOriginLocal();
         resetInvocationContext();
         if (evictionPolicyListener != null)
         {
  @@ -356,20 +352,20 @@
   
      private void restoreInvocationContext()
      {
  -      treeCache.getInvocationContext().setState(tempCtx);
  +      cache.getInvocationContext().setState(tempCtx);
      }
   
      private void resetInvocationContext()
      {
         try
         {
  -         tempCtx = treeCache.getInvocationContext().clone();
  +         tempCtx = cache.getInvocationContext().clone();
         }
         catch (CloneNotSupportedException e)
         {
  -         log.warn("Unable to clone Invocation Context " + treeCache.getInvocationContext(), e);
  +         log.warn("Unable to clone Invocation Context " + cache.getInvocationContext(), e);
         }
  -      treeCache.getInvocationContext().reset();
  +      cache.getInvocationContext().reset();
      }
   
      /**
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/rpc  ...
Message-ID: <E1H0iLO-00006L-AT@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:06

  Modified:    src/org/jboss/cache/rpc  RpcTreeCache.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.12      +14 -16    JBossCache/src/org/jboss/cache/rpc/RpcTreeCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RpcTreeCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/rpc/RpcTreeCache.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- RpcTreeCache.java	30 Aug 2006 17:08:18 -0000	1.11
  +++ RpcTreeCache.java	30 Dec 2006 17:50:06 -0000	1.12
  @@ -1,6 +1,6 @@
   package org.jboss.cache.rpc;
   
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.marshall.MethodCall;
   import org.jboss.cache.marshall.MethodCallFactory;
  @@ -15,7 +15,7 @@
   import java.util.Vector;
   
   /**
  - * {@link TreeCache} extension that adds a general purpose RPC functionality
  + * {@link CacheImpl} extension that adds a general purpose RPC functionality
    * to allow clients to make/receive RPC calls over the same JGroups Channel
    * used by the cache.
    * <p/>
  @@ -28,7 +28,7 @@
    * </p>
    * <p/>
    * <strong>NOTE: </strong> The purpose of this class is to allow services that
  - * want to use a TreeCache to avoid also having to use a HAPartition (and thus
  + * want to use a CacheImpl to avoid also having to use a HAPartition (and thus
    * potentially requiring a duplicate JGroups Channel).
    *
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
  @@ -36,11 +36,11 @@
    * @deprecated This class will be removed when JGroups adds a multiplexing
    *             capability.
    */
  -public class RpcTreeCache extends TreeCache //implements RpcTreeCacheMBean // TODO; Sort out proper JMX interfaces
  +public class RpcTreeCache extends CacheImpl //implements RpcTreeCacheMBean // TODO; Sort out proper JMX interfaces
   {
   
      /**
  -    * The {@link #_dispatchRpcCall(String, MethodCall)} method
  +    * The {@link #_dispatchRpcCall(String,MethodCall)} method
       */
      public static final Method dispatchRpcCallMethod;
   
  @@ -48,9 +48,7 @@
      {
         try
         {
  -         dispatchRpcCallMethod = RpcTreeCache.class.getDeclaredMethod("_dispatchRpcCall",
  -                 new Class[]{String.class,
  -                         MethodCall.class});
  +         dispatchRpcCallMethod = RpcTreeCache.class.getDeclaredMethod("_dispatchRpcCall", String.class, MethodCall.class);
         }
         catch (NoSuchMethodException ex)
         {
  @@ -98,10 +96,10 @@
       *
       * @param serviceName  name of a callback handler that will have been
       *                     registered on the remote end via
  -    *                     {@link #registerRPCHandler(String, Object)}.
  +    *                     {@link #registerRPCHandler(String,Object)}.
       * @param members      Vector, each of whose members is the Address of one
       *                     the nodes in the cache's
  -    *                     {@link TreeCache#getMembers() member list}.
  +    *                     {@link CacheImpl#getMembers() member list}.
       *                     If <code>null</code>, the method will be invoked on
       *                     all members.
       * @param method       method to execute
  @@ -129,14 +127,14 @@
       * Calls a remote method on nodes in the cluster, targeted at
       * objects registered under a given <code>serviceName</code>.
       * <p/>
  -    * If the cache's <code>cache mode</code> is <code>TreeCache.LOCAL</code>
  +    * If the cache's <code>cache mode</code> is <code>CacheImpl.LOCAL</code>
       * and parameter <code>exclude_self</code> is <code>false</code>
       * this request will be made directly to
       * </p>
       *
       * @param serviceName  name of a callback handler that will have been
       *                     registered on the remote end via
  -    *                     {@link #registerRPCHandler(String, Object)}.
  +    *                     {@link #registerRPCHandler(String,Object)}.
       * @param method_call  method call to execute
       * @param synchronous  <code>true</code> if the call should block until
       *                     all members respond (or timeout); <code>false</code>
  @@ -200,7 +198,7 @@
   
            // Remove any NoHandlerForRPCException
            // Its inefficient doing this here, but if we add it to
  -         // TreeCache.callRemoteMethods we slow down normal cache ops
  +         // CacheImpl.callRemoteMethods we slow down normal cache ops
            if (responses != null)
            {
               for (int i = 0; i < responses.size(); i++)
  @@ -224,10 +222,10 @@
       *
       * @param serviceName  name of a callback handler that will have been
       *                     registered on the remote end via
  -    *                     {@link #registerRPCHandler(String, Object)}.
  +    *                     {@link #registerRPCHandler(String,Object)}.
       * @param members      Vector, each of whose members is the Address of one
       *                     the nodes in the cache's
  -    *                     {@link TreeCache#getMembers() member list}.
  +    *                     {@link CacheImpl#getMembers() member list}.
       *                     If <code>null</code>, the method will be invoked on
       *                     all members.
       * @param method_name  name of the method to execute
  @@ -287,7 +285,7 @@
       *
       * @param serviceName name of a service that will be receiving RPC calls
       * @param handler     object that was previously passed to
  -    *                    {@link #registerRPCHandler(String, Object)} for
  +    *                    {@link #registerRPCHandler(String,Object)} for
       *                    <code>serviceName</code>.
       * @param handler
       */
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:06 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/jmx  ...
Message-ID: <E1H0iLO-00006S-Ha@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:06

  Modified:    tests/functional/org/jboss/cache/jmx  CacheMBeanTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.7       +3 -3      JBossCache/tests/functional/org/jboss/cache/jmx/CacheMBeanTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheMBeanTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/jmx/CacheMBeanTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- CacheMBeanTest.java	16 Nov 2006 14:51:49 -0000	1.6
  +++ CacheMBeanTest.java	30 Dec 2006 17:50:06 -0000	1.7
  @@ -36,7 +36,7 @@
         mBeanName = new ObjectName(mBeanNameStr);
   
         JmxUtil.registerCacheMBean(mBeanServer, new org.jboss.cache.jmx.Cache((CacheSPI) cache), mBeanNameStr);
  -      JmxUtil.registerInterceptors(mBeanServer, ((CacheSPI)cache).getInterceptorChain(), mBeanNameStr);
  +      JmxUtil.registerInterceptors(mBeanServer, ((CacheSPI) cache).getInterceptorChain(), mBeanNameStr);
      }
   
      protected void tearDown()
  @@ -87,9 +87,9 @@
      public void testCacheOperations() throws Exception
      {
         Cache cacheJmx = (Cache) mBeanServer.getAttribute(mBeanName, "Cache");
  -      cacheJmx.put("key", "value");
  +      cacheJmx.getRoot().put("key", "value");
   
  -      assertEquals("value", cache.get("key"));
  +      assertEquals("value", cache.getRoot().get("key"));
   
         Fqn fqn = Fqn.fromString("//testing/jmx");
         cache.put(fqn, "key", "value");
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:06 -0500
Subject: [jboss-cvs] JBossCache/examples/PojoCache/annotated50  ...
Message-ID: <E1H0iLO-00006Z-Ry@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:06

  Modified:    examples/PojoCache/annotated50  build.xml
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +2 -2      JBossCache/examples/PojoCache/annotated50/build.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: build.xml
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/examples/PojoCache/annotated50/build.xml,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- build.xml	24 Sep 2006 09:25:52 -0000	1.5
  +++ build.xml	30 Dec 2006 17:50:06 -0000	1.6
  @@ -92,7 +92,7 @@
         </java>
      </target>
   
  -   <target name="run.aop.demo" depends="compile" description="run tree cache demo.">
  +   <target name="run.aop.demo" depends="compile" description="run JBoss Cache demo.">
         <java classname="org.jboss.cache.aop.TreeCacheView" fork="yes">
            <jvmarg value="-Xmx128M"/>
            <classpath refid="lib.classpath"/>
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:06 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:06 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/jdbm  ...
Message-ID: <E1H0iLO-00006g-WD@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:06

  Modified:    src/org/jboss/cache/loader/jdbm  JdbmCacheLoader.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.19      +7 -7      JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JdbmCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- JdbmCacheLoader.java	8 Dec 2006 18:49:18 -0000	1.18
  +++ JdbmCacheLoader.java	30 Dec 2006 17:50:06 -0000	1.19
  @@ -34,7 +34,7 @@
    * <p>The configuration string format is:</p>
    * <pre>environmentDirectoryName[#databaseName]</pre>
    * <p>where databaseName, if omitted, defaults to the ClusterName property
  - * of the TreeCache.</p>
  + * of the CacheImpl.</p>
    * <p/>
    * Data is sorted out like:
    * <pre>
  @@ -55,7 +55,7 @@
    * plans to fix this.
    *
    * @author Elias Ross
  - * @version $Id: JdbmCacheLoader.java,v 1.18 2006/12/08 18:49:18 genman Exp $
  + * @version $Id: JdbmCacheLoader.java,v 1.19 2006/12/30 17:50:06 msurtani Exp $
    */
   public class JdbmCacheLoader extends AbstractCacheLoader
   {
  @@ -227,7 +227,7 @@
      }
   
      /**
  -    * Sets the TreeCache owner of this cache loader.
  +    * Sets the CacheImpl owner of this cache loader.
       */
      public void setCache(CacheSPI c)
      {
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:07 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:07 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer ...
Message-ID: <E1H0iLP-00006q-Ax@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:07

  Modified:    tests-50/functional/org/jboss/cache/pojo/statetransfer 
                        ReplicatedTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.3       +6 -4      JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer/ReplicatedTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer/ReplicatedTest.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ReplicatedTest.java	31 Oct 2006 11:07:18 -0000	1.2
  +++ ReplicatedTest.java	30 Dec 2006 17:50:07 -0000	1.3
  @@ -22,11 +22,12 @@
   
   package org.jboss.cache.pojo.statetransfer;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.pojo.PojoCache;
   import org.jboss.cache.pojo.PojoCacheFactory;
   import org.jboss.cache.pojo.test.Person;
  @@ -34,6 +35,7 @@
   
   /**
    * Simple replicated test for state transfer
  + *
    * @author Ben Wang
    */
   public class ReplicatedTest extends TestCase
  @@ -89,14 +91,14 @@
         Person ben = createPerson("/person/test1", "Ben Wang", 40);
   
         System.out.println("\n*** I ***");
  -      System.out.println(((org.jboss.cache.TreeCacheProxyImpl)cache.getCache()).printDetails());
  +      System.out.println(((CacheImpl) cache.getCache()).printDetails());
         cache1 = PojoCacheFactory.createCache(configFile, toStart);
         cache1.start();
   
         System.out.println("\n*** II ***");
  -      System.out.println(((org.jboss.cache.TreeCacheProxyImpl)cache1.getCache()).printDetails());
  +      System.out.println(((CacheImpl) cache1.getCache()).printDetails());
   
  -      Person p = (Person)cache1.find("/person/test1");
  +      Person p = (Person) cache1.find("/person/test1");
   
         log.info("testSimple() ....");
         assertEquals("Ben Wang", ben.getName());
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:07 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:07 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/util  ...
Message-ID: <E1H0iLP-00006x-Gw@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:07

  Modified:    src/org/jboss/cache/util  setCache.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.2       +22 -19    JBossCache/src/org/jboss/cache/util/setCache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: setCache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/util/setCache.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- setCache.java	18 May 2006 15:46:18 -0000	1.1
  +++ setCache.java	30 Dec 2006 17:50:07 -0000	1.2
  @@ -21,30 +21,33 @@
    */
   package org.jboss.cache.util;
   
  -import org.jboss.cache.TreeCache;
  -import org.jboss.cache.TreeCacheView2;
  -
   import bsh.CallStack;
   import bsh.Interpreter;
  +import org.jboss.cache.CacheImpl;
  +import org.jboss.cache.TreeCacheView2;
   
   /**
  - * Custom beanshell setCache(TreeCache) command allowing beanshell user to 
  - * set TreeCache reference being displayed in a JTree of TreeCacheView2 utility. 
  + * Custom beanshell setCache(CacheImpl) command allowing beanshell user to
  + * set CacheImpl reference being displayed in a JTree of TreeCacheView2 utility.
    * Class name is intentionally violating java conventions to follow beanshell 
    * command naming conventions. 
    * 
  + * @version $Id$
    * @see org.jboss.cache.TreeCacheView2
    * @see http://www.beanshell.org/
  - *  
  - * @version $Id$
    */
  -public class setCache {
  +public class setCache
  +{
   	public static void invoke(Interpreter env, CallStack callstack,
  -			TreeCache tree) {
  +                             CacheImpl cache)
  +   {
   
  -		try {
  -			TreeCacheView2.setCache(tree);
  -		} catch (Exception ex) {
  +      try
  +      {
  +         TreeCacheView2.setCache(cache);
  +      }
  +      catch (Exception ex)
  +      {
   			ex.printStackTrace();
   		}
   	}
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:07 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:07 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/interceptors
	...
Message-ID: <E1H0iLP-000074-LN@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:07

  Modified:    tests/functional/org/jboss/cache/interceptors 
                        EvictionInterceptorTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.18      +15 -15    JBossCache/tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- EvictionInterceptorTest.java	8 Dec 2006 19:09:41 -0000	1.17
  +++ EvictionInterceptorTest.java	30 Dec 2006 17:50:07 -0000	1.18
  @@ -7,11 +7,11 @@
   package org.jboss.cache.interceptors;
   
   import junit.framework.TestCase;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.NodeImpl;
  +import org.jboss.cache.Node;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
  -import org.jboss.cache.TreeCache;
   import org.jboss.cache.eviction.DummyEvictionConfiguration;
   import org.jboss.cache.eviction.EvictedEventNode;
   import org.jboss.cache.eviction.EvictionPolicyConfig;
  @@ -36,7 +36,7 @@
   
      private static final String fqn4 = "/d/e/f";
   
  -   private TreeCache cache;
  +   private CacheImpl cache;
      private Interceptor interceptor;
      private RegionManager regionManager;
   
  @@ -57,34 +57,34 @@
         regionManager.getRegion("/d/e/g", true).setEvictionPolicy(config);
         regionManager.getRegion("/d/e", true).setEvictionPolicy(config);
   
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
         cache.getConfiguration().setIsolationLevel(IsolationLevel.SERIALIZABLE);
   
  -      // make the interceptor chain (separate from the TreeCache object.
  +      // make the interceptor chain (separate from the CacheImpl object.
   
         interceptor = new CacheMgmtInterceptor();
  -      interceptor.setCache(cache.getCacheSPI());
  +      interceptor.setCache(cache);
   
         TxInterceptor ti = new TxInterceptor();
  -      ti.setCache(cache.getCacheSPI());
  +      ti.setCache(cache);
         interceptor.setNext(ti);
   
         UnlockInterceptor ui = new UnlockInterceptor();
  -      ui.setCache(cache.getCacheSPI());
  +      ui.setCache(cache);
         ti.setNext(ui);
   
         PessimisticLockInterceptor pli = new PessimisticLockInterceptor();
  -      pli.setCache(cache.getCacheSPI());
  +      pli.setCache(cache);
         ui.setNext(pli);
   
         EvictionInterceptor ei = new EvictionInterceptor();
  -      ei.setCache(cache.getCacheSPI());
  +      ei.setCache(cache);
         ei.setRegionManager(regionManager);
         pli.setNext(ei);
   
         CallInterceptor ci = new CallInterceptor();
  -      ci.setCache(cache.getCacheSPI());
  +      ci.setCache(cache);
         ci.setTreeCacheInstance(cache);
         ei.setNext(ci);
   
  @@ -111,7 +111,7 @@
   
         cache.put(fqn1, "key", "value");
         assertEquals("value", cache.get(fqn1, "key"));
  -      NodeImpl node = cache.get(fqn1);
  +      Node node = cache.get(fqn1);
         assertNotNull(node);
         assertEquals("value", node.get("key"));
   
  @@ -299,7 +299,7 @@
         assertEquals(fqn, event.getFqn());
         assertEquals(100, event.getElementDifference());
   
  -      NodeImpl node = cache.get(fqn.toString());
  +      Node node = cache.get(fqn.toString());
         assertNotNull(node);
   
         for (int i = 0; i < 100; i++)
  @@ -343,7 +343,7 @@
   
         for (int i = 0; i < 100; i++)
         {
  -         assertTrue(node.containsKey(i));
  +         assertTrue(node.getData().containsKey(i));
            assertEquals(i, node.get(i));
         }
   
  @@ -363,7 +363,7 @@
   
         for (int i = 0; i < 100; i++)
         {
  -         assertTrue(node.containsKey(i));
  +         assertTrue(node.getData().containsKey(i));
            assertEquals(i, node.get(i));
         }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:07 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:07 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/config  ...
Message-ID: <E1H0iLP-00007B-Pr@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:07

  Modified:    tests/functional/org/jboss/cache/config 
                        ConfigurationTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.8       +1 -1      JBossCache/tests/functional/org/jboss/cache/config/ConfigurationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConfigurationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/config/ConfigurationTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ConfigurationTest.java	15 Nov 2006 23:48:32 -0000	1.7
  +++ ConfigurationTest.java	30 Dec 2006 17:50:07 -0000	1.8
  @@ -28,7 +28,7 @@
         assertEquals(false, conf.isUseReplQueue());
         assertEquals(0, conf.getReplQueueInterval());
         assertEquals(0, conf.getReplQueueMaxElements());
  -      assertEquals("TreeCache-Cluster", conf.getClusterName());
  +      assertEquals("JBossCache-Cluster", conf.getClusterName());
         assertEquals(true, conf.isFetchInMemoryState());
         assertEquals(15000, conf.getInitialStateRetrievalTimeout());
         assertEquals(15000, conf.getSyncReplTimeout());
  
  
  


From msurtani at jboss.com  Sat Dec 30 12:50:07 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 12:50:07 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/factories ...
Message-ID: <E1H0iLP-00007I-Va@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 12:50:07

  Modified:    tests/functional/org/jboss/cache/factories 
                        InterceptorChainFactoryTest.java
  Log:
  Major changes to restructure cache and node object model
  
  Revision  Changes    Path
  1.6       +11 -11    JBossCache/tests/functional/org/jboss/cache/factories/InterceptorChainFactoryTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InterceptorChainFactoryTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/factories/InterceptorChainFactoryTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- InterceptorChainFactoryTest.java	15 Nov 2006 15:16:40 -0000	1.5
  +++ InterceptorChainFactoryTest.java	30 Dec 2006 17:50:07 -0000	1.6
  @@ -3,7 +3,7 @@
   import junit.framework.Assert;
   import junit.framework.Test;
   import junit.framework.TestSuite;
  -import org.jboss.cache.TreeCache;
  +import org.jboss.cache.CacheImpl;
   import org.jboss.cache.config.BuddyReplicationConfig;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.EvictionConfig;
  @@ -16,12 +16,12 @@
   
   public class InterceptorChainFactoryTest extends InterceptorChainTestBase
   {
  -   TreeCache cache = null;
  +   CacheImpl cache = null;
   
      protected void setUp() throws Exception
      {
         super.setUp();
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setCacheMode("LOCAL");
      }
   
  @@ -186,7 +186,7 @@
   
      public void testOptimisticChain() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setExposeManagementStatistics(false);
         cache.getConfiguration().setNodeLockingOptimistic(true);
   
  @@ -211,7 +211,7 @@
   
      public void testOptimisticReplicatedChain() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setExposeManagementStatistics(false);
         cache.getConfiguration().setNodeLockingOptimistic(true);
         cache.getConfiguration().setCacheMode("REPL_SYNC");
  @@ -238,7 +238,7 @@
   
      public void testOptimisticCacheLoaderChain() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setExposeManagementStatistics(false);
         cache.getConfiguration().setNodeLockingOptimistic(true);
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig(false, false));
  @@ -266,7 +266,7 @@
   
      public void testOptimisticPassivationCacheLoaderChain() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setExposeManagementStatistics(false);
         cache.getConfiguration().setNodeLockingOptimistic(true);
         cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig(true, false));
  @@ -295,7 +295,7 @@
   
      public void testInvalidationInterceptorChain() throws Exception
      {
  -      TreeCache cache = new TreeCache();
  +      CacheImpl cache = new CacheImpl();
         cache.getConfiguration().setExposeManagementStatistics(false);
         cache.getConfiguration().setCacheMode("REPL_ASYNC");
   
  @@ -317,7 +317,7 @@
         // ok, my replication chain looks good.
   
         // now for my invalidation chain.
  -      cache = new TreeCache();
  +      cache = new CacheImpl();
         cache.getConfiguration().setExposeManagementStatistics(false);
         cache.getConfiguration().setCacheMode("INVALIDATION_ASYNC");
         chain = new InterceptorChainFactory().buildInterceptorChain(cache);
  
  
  


From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 14:37:23 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 14:37:23 -0500
Subject: [jboss-cvs] JBossAS SVN: r59249 - in
	branches/Branch_AOP_1_5/aop/src: resources/test/regression
	test/org/jboss/test/aop/regression
	test/org/jboss/test/aop/regression/jbaop336callnpe
Message-ID: <E1H0k1D-000286-9X@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-30 14:37:19 -0500 (Sat, 30 Dec 2006)
New Revision: 59249

Added:
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/CallerNPETestCase.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/Log.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/LogInterceptor.java
   branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/POJO.java
Modified:
   branches/Branch_AOP_1_5/aop/src/resources/test/regression/jboss-aop.xml
Log:
[JBAOP-336] Add test demonstrating the behaviour

Modified: branches/Branch_AOP_1_5/aop/src/resources/test/regression/jboss-aop.xml
===================================================================
--- branches/Branch_AOP_1_5/aop/src/resources/test/regression/jboss-aop.xml	2006-12-30 08:27:14 UTC (rev 59248)
+++ branches/Branch_AOP_1_5/aop/src/resources/test/regression/jboss-aop.xml	2006-12-30 19:37:19 UTC (rev 59249)
@@ -127,4 +127,9 @@
    </bind>
    
    <prepare expr="all(org.jboss.test.aop.regression.jbaop316annotationsinwrapperonly.POJO)"/>
+
+   <interceptor class="org.jboss.test.aop.regression.jbaop336callnpe.LogInterceptor" scope="PER_INSTANCE"/>
+   <bind pointcut="call(org.jboss.test.aop.regression.jbaop336callnpe.Log->new(java.lang.String))">
+   	<interceptor-ref name="org.jboss.test.aop.regression.jbaop336callnpe.LogInterceptor"/>
+  	</bind>
 </aop>

Added: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/CallerNPETestCase.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/CallerNPETestCase.java	2006-12-30 08:27:14 UTC (rev 59248)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/CallerNPETestCase.java	2006-12-30 19:37:19 UTC (rev 59249)
@@ -0,0 +1,60 @@
+/*
+  * JBoss, Home of Professional Open Source
+  * Copyright 2005, JBoss Inc., and individual contributors as indicated
+  * by the @authors tag. See the copyright.txt 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.test.aop.regression.jbaop336callnpe;
+
+import junit.framework.Test;
+import junit.framework.TestSuite;
+import junit.textui.TestRunner;
+
+
+/**
+ * http://jira.jboss.com/jira/browse/JBAOP-316
+ * 
+ * @author <a href="mailto:kabir.khan at jboss.org">Kabir Khan</a>
+ * @version $Revision: 45977 $
+ */
+public class CallerNPETestCase extends junit.framework.TestCase 
+{
+   public static void main(String[] args)
+   {
+      TestRunner.run(suite());
+   }
+
+   public static Test suite()
+   {
+      TestSuite suite = new TestSuite("CallerNPETestCase");
+      suite.addTestSuite(CallerNPETestCase.class);
+      return suite;
+   }
+
+   public CallerNPETestCase(String name)
+   {
+      super(name);
+   }
+
+   public void testCallerInterceptor()throws Exception
+   {
+      POJO pojo = new POJO("XYZ");
+      assertEquals("XYZ", LogInterceptor.logFile);
+   }
+
+}

Added: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/Log.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/Log.java	2006-12-30 08:27:14 UTC (rev 59248)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/Log.java	2006-12-30 19:37:19 UTC (rev 59249)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.aop.regression.jbaop336callnpe;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class Log
+{
+   String logFile;
+   
+   public Log(String logFile)
+   {
+      this.logFile = logFile;
+   }
+}

Added: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/LogInterceptor.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/LogInterceptor.java	2006-12-30 08:27:14 UTC (rev 59248)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/LogInterceptor.java	2006-12-30 19:37:19 UTC (rev 59249)
@@ -0,0 +1,48 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.aop.regression.jbaop336callnpe;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.ConstructorCalledByConstructorInvocation;
+import org.jboss.aop.joinpoint.Invocation;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class LogInterceptor implements Interceptor
+{
+   public static String logFile;
+
+   public String getName()
+   {
+      return this.getClass().getName();
+   }
+
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+      logFile = (String)((ConstructorCalledByConstructorInvocation)invocation).getArguments()[0];
+      return invocation.invokeNext();
+   }
+
+}

Added: branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/POJO.java
===================================================================
--- branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/POJO.java	2006-12-30 08:27:14 UTC (rev 59248)
+++ branches/Branch_AOP_1_5/aop/src/test/org/jboss/test/aop/regression/jbaop336callnpe/POJO.java	2006-12-30 19:37:19 UTC (rev 59249)
@@ -0,0 +1,37 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2005, JBoss Inc., and individual contributors as indicated
+* by the @authors tag. See the copyright.txt 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.test.aop.regression.jbaop336callnpe;
+
+/**
+ * 
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class POJO
+{
+   private Log log;
+   
+   public POJO(String logFile)
+   {
+      log = new Log(logFile);
+   }
+}



From msurtani at jboss.com  Sat Dec 30 14:48:44 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:44 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader           ...
Message-ID: <E1H0kCC-0002IO-TR@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:44

  Modified:    src/org/jboss/cache/loader          
                        JDBCCacheLoaderConfig.java CacheLoader.java
                        AsynchCacheLoaderConfig.java
                        AbstractCacheLoader.java JDBCCacheLoader.java
                        ClusteredCacheLoader.java
                        FileCacheLoaderConfig.java
                        RpcDelegatingCacheLoader.java
                        ChainingCacheLoader.java
                        ClusteredCacheLoaderConfig.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.2       +41 -39    JBossCache/src/org/jboss/cache/loader/JDBCCacheLoaderConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JDBCCacheLoaderConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/JDBCCacheLoaderConfig.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- JDBCCacheLoaderConfig.java	26 Oct 2006 19:30:20 -0000	1.1
  +++ JDBCCacheLoaderConfig.java	30 Dec 2006 19:48:44 -0000	1.2
  @@ -1,12 +1,14 @@
   package org.jboss.cache.loader;
   
  -import java.util.Properties;
  -
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   
  +import java.util.Properties;
  +
   public class JDBCCacheLoaderConfig extends IndividualCacheLoaderConfig
   {
  -   /** The serialVersionUID */
  +   /**
  +    * The serialVersionUID
  +    */
      private static final long serialVersionUID = -5923661816427361643L;
      
      private boolean createTable;
  @@ -269,9 +271,9 @@
         }
   
         String prop = props.getProperty("cache.jdbc.table.create");
  -      this.createTable = (prop == null || Boolean.valueOf(prop).booleanValue());
  +      this.createTable = (prop == null || Boolean.valueOf(prop));
         prop = props.getProperty("cache.jdbc.table.drop");
  -      this.dropTable = (prop == null || Boolean.valueOf(prop).booleanValue());
  +      this.dropTable = (prop == null || Boolean.valueOf(prop));
   
         this.table = props.getProperty("cache.jdbc.table.name", "jbosscache");
         String primaryKey = props.getProperty("cache.jdbc.table.primarykey", "jbosscache_pk");
  
  
  
  1.13      +3 -3      JBossCache/src/org/jboss/cache/loader/CacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/CacheLoader.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- CacheLoader.java	30 Dec 2006 17:50:01 -0000	1.12
  +++ CacheLoader.java	30 Dec 2006 19:48:44 -0000	1.13
  @@ -80,7 +80,7 @@
       * @return Set a set of children.  Returns null if no children nodes are
       *         present, or the parent is not present
       */
  -   Set getChildrenNames(Fqn fqn) throws Exception;
  +   Set<String> getChildrenNames(Fqn fqn) throws Exception;
   
      /**
       * Returns all keys and values from the persistent store, given a fully qualified name.
  @@ -94,7 +94,7 @@
       *         null if the node is not found.  If the node is found but has no
       *         attributes, this method returns an empty Map.
       */
  -   Map get(Fqn name) throws Exception;
  +   Map<Object, Object> get(Fqn name) throws Exception;
   
   
      /**
  @@ -122,7 +122,7 @@
       * @param name       The fully qualified name of the node
       * @param attributes A Map of attributes. Can be null
       */
  -   void put(Fqn name, Map attributes) throws Exception;
  +   void put(Fqn name, Map<Object, Object> attributes) throws Exception;
   
      /**
       * Applies all modifications to the backend store.
  
  
  
  1.2       +18 -18    JBossCache/src/org/jboss/cache/loader/AsynchCacheLoaderConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsynchCacheLoaderConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/AsynchCacheLoaderConfig.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- AsynchCacheLoaderConfig.java	26 Oct 2006 19:30:20 -0000	1.1
  +++ AsynchCacheLoaderConfig.java	30 Dec 2006 19:48:44 -0000	1.2
  @@ -1,12 +1,14 @@
   package org.jboss.cache.loader;
   
  -import java.util.Properties;
  -
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   
  +import java.util.Properties;
  +
   public class AsynchCacheLoaderConfig extends IndividualCacheLoaderConfig
   {
  -   /** The serialVersionUID */
  +   /**
  +    * The serialVersionUID
  +    */
      private static final long serialVersionUID = 5038037589485991681L;
      
      private int batchSize = 100;
  @@ -17,7 +19,6 @@
      
      /**
       * Default constructor.
  -    *
       */
      public AsynchCacheLoaderConfig()
      {
  @@ -114,7 +115,7 @@
         s = props.getProperty("cache.async.returnOld");
         if (s != null)
         {
  -         returnOld = Boolean.valueOf(s).booleanValue();
  +         returnOld = Boolean.valueOf(s);
         }
   
         s = props.getProperty("cache.async.queueSize");
  @@ -126,7 +127,7 @@
         s = props.getProperty("cache.async.put");
         if (s != null)
         {
  -         useAsyncPut = Boolean.valueOf(s).booleanValue();
  +         useAsyncPut = Boolean.valueOf(s);
         }
      }
   
  @@ -156,5 +157,4 @@
      }
      
      
  -   
   }
  \ No newline at end of file
  
  
  
  1.13      +7 -9      JBossCache/src/org/jboss/cache/loader/AbstractCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/AbstractCacheLoader.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- AbstractCacheLoader.java	20 Nov 2006 07:33:14 -0000	1.12
  +++ AbstractCacheLoader.java	30 Dec 2006 19:48:44 -0000	1.13
  @@ -16,8 +16,6 @@
   
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
  -import java.util.HashMap;
  -import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  @@ -33,7 +31,7 @@
      protected CacheSPI cache;
      protected RegionManager regionManager;
   
  -   public void put(Fqn fqn, Map attributes, boolean erase) throws Exception
  +   public void put(Fqn fqn, Map<Object, Object> attributes, boolean erase) throws Exception
      {
         if (erase)
         {
  @@ -41,7 +39,7 @@
         }
   
         // JBCACHE-769 -- make a defensive copy
  -      Map attrs = (attributes == null ? null : new MapCopy(attributes));
  +      Map<Object, Object> attrs = (attributes == null ? null : new MapCopy<Object, Object>(attributes));
         put(fqn, attrs);
      }
   
  @@ -155,8 +153,8 @@
       */
      protected void loadStateHelper(Fqn fqn, ObjectOutputStream out) throws Exception
      {
  -      Map attrs;
  -      Set children_names;
  +      Map<Object, Object> attrs;
  +      Set<? extends Object> children_names;
         String child_name;
         Fqn tmp_fqn;
         NodeData nd;
  @@ -179,9 +177,9 @@
         {
            return;
         }
  -      for (Iterator it = children_names.iterator(); it.hasNext();)
  +      for (Object children_name : children_names)
         {
  -         child_name = (String) it.next();
  +         child_name = (String) children_name;
            tmp_fqn = new Fqn(fqn, child_name);
            loadStateHelper(tmp_fqn, out);
         }
  @@ -233,7 +231,7 @@
            _move(newFqn, new Fqn(fqn, c));
         }
         // get data for node.
  -      Map data = get(fqn);
  +      Map<Object, Object> data = get(fqn);
         if (data != null) // if null, then the node never existed.  Don't bother removing?
         {
            remove(fqn);
  
  
  
  1.26      +3 -3      JBossCache/src/org/jboss/cache/loader/JDBCCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JDBCCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/JDBCCacheLoader.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- JDBCCacheLoader.java	20 Dec 2006 02:16:24 -0000	1.25
  +++ JDBCCacheLoader.java	30 Dec 2006 19:48:44 -0000	1.26
  @@ -79,7 +79,7 @@
    *
    * @author <a href="mailto:alex at jboss.org">Alexey Loubyansky</a>
    * @author <a href="mailto:hmesha at novell.com">Hany Mesha </a>
  - * @version <tt>$Revision: 1.25 $</tt>
  + * @version <tt>$Revision: 1.26 $</tt>
    */
   public class JDBCCacheLoader extends AbstractCacheLoader
   {
  @@ -689,8 +689,8 @@
            else
            {
               // a hack to handles the incomp. of SQL server jdbc driver prior to SQL SERVER 2005
  -            if (driverName != null && (driverName.indexOf("SQLSERVER") >= 0
  -                    || driverName.indexOf("POSTGRESQL") >= 0))
  +            if (driverName != null && (driverName.contains("SQLSERVER")
  +                    || driverName.contains("POSTGRESQL")))
               {
                  ps.setNull(2, Types.LONGVARBINARY);
               }
  
  
  
  1.21      +1 -1      JBossCache/src/org/jboss/cache/loader/ClusteredCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClusteredCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/ClusteredCacheLoader.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- ClusteredCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.20
  +++ ClusteredCacheLoader.java	30 Dec 2006 19:48:44 -0000	1.21
  @@ -97,7 +97,7 @@
                  // keep looping till we find a FOUND answer.
                  List<Boolean> clusteredGetResp = (List<Boolean>) o;
                  // found?
  -               if ((clusteredGetResp.get(0)).booleanValue())
  +               if (clusteredGetResp.get(0))
                  {
                     result = clusteredGetResp.get(1);
                     break;
  
  
  
  1.3       +11 -11    JBossCache/src/org/jboss/cache/loader/FileCacheLoaderConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FileCacheLoaderConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/FileCacheLoaderConfig.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- FileCacheLoaderConfig.java	23 Nov 2006 16:07:38 -0000	1.2
  +++ FileCacheLoaderConfig.java	30 Dec 2006 19:48:44 -0000	1.3
  @@ -1,10 +1,10 @@
   package org.jboss.cache.loader;
   
  -import java.util.Properties;
  -
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
   import org.jboss.cache.config.Dynamic;
   
  +import java.util.Properties;
  +
   public class FileCacheLoaderConfig extends IndividualCacheLoaderConfig
   {
      private static final long serialVersionUID = 4626734068542420865L;
  @@ -59,7 +59,7 @@
         {
            setLocation(props.getProperty("location"));
            String prop = props.getProperty("check.character.portability");
  -         setCheckCharacterPortability((prop == null || Boolean.valueOf(prop).booleanValue()));         
  +         setCheckCharacterPortability((prop == null || Boolean.valueOf(prop)));
         }
      }
   
  
  
  
  1.15      +2 -2      JBossCache/src/org/jboss/cache/loader/RpcDelegatingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RpcDelegatingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/RpcDelegatingCacheLoader.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- RpcDelegatingCacheLoader.java	30 Dec 2006 17:50:01 -0000	1.14
  +++ RpcDelegatingCacheLoader.java	30 Dec 2006 19:48:44 -0000	1.15
  @@ -34,7 +34,7 @@
    * specified, it defaults to <tt>5000</tt>.
    *
    * @author Daniel Gredler
  - * @version $Id: RpcDelegatingCacheLoader.java,v 1.14 2006/12/30 17:50:01 msurtani Exp $
  + * @version $Id: RpcDelegatingCacheLoader.java,v 1.15 2006/12/30 19:48:44 msurtani Exp $
    */
   public class RpcDelegatingCacheLoader extends DelegatingCacheLoader
   {
  @@ -154,7 +154,7 @@
      protected boolean delegateExists(Fqn name) throws Exception
      {
         Boolean exists = (Boolean) this.doMethodCall(METHOD_EXISTS, new Object[]{name});
  -      return exists != null && exists.booleanValue();
  +      return exists != null && exists;
      }
   
      /**
  
  
  
  1.14      +2 -2      JBossCache/src/org/jboss/cache/loader/ChainingCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ChainingCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/ChainingCacheLoader.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ChainingCacheLoader.java	14 Nov 2006 14:17:10 -0000	1.13
  +++ ChainingCacheLoader.java	30 Dec 2006 19:48:44 -0000	1.14
  @@ -8,9 +8,9 @@
   
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Modification;
  +import org.jboss.cache.RegionManager;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
  -import org.jboss.cache.RegionManager;
   
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
  
  
  
  1.2       +14 -12    JBossCache/src/org/jboss/cache/loader/ClusteredCacheLoaderConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ClusteredCacheLoaderConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/ClusteredCacheLoaderConfig.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- ClusteredCacheLoaderConfig.java	26 Oct 2006 19:30:20 -0000	1.1
  +++ ClusteredCacheLoaderConfig.java	30 Dec 2006 19:48:44 -0000	1.2
  @@ -1,13 +1,15 @@
   package org.jboss.cache.loader;
   
  -import java.util.Properties;
  -
  -import org.jboss.cache.config.Dynamic;
   import org.jboss.cache.config.CacheLoaderConfig.IndividualCacheLoaderConfig;
  +import org.jboss.cache.config.Dynamic;
  +
  +import java.util.Properties;
   
   public class ClusteredCacheLoaderConfig extends IndividualCacheLoaderConfig
   {
  -   /** The serialVersionUID */
  +   /**
  +    * The serialVersionUID
  +    */
      private static final long serialVersionUID = -3425487656984237468L;
      
      @Dynamic
  @@ -45,7 +47,7 @@
         super.setProperties(props);
         try
         {
  -         timeout = Long.valueOf(props.getProperty("timeout")).longValue();
  +         timeout = Long.valueOf(props.getProperty("timeout"));
         }
         catch (Exception e)
         {
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/notifications  ...
Message-ID: <E1H0kCD-0002IV-1Z@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:45

  Modified:    src/org/jboss/cache/notifications  Notifier.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.13      +5 -5      JBossCache/src/org/jboss/cache/notifications/Notifier.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Notifier.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/notifications/Notifier.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- Notifier.java	30 Dec 2006 17:50:06 -0000	1.12
  +++ Notifier.java	30 Dec 2006 19:48:45 -0000	1.13
  @@ -132,11 +132,11 @@
         restoreInvocationContext();
      }
   
  -   private Map copy(Map data)
  +   private Map copy(Map<Object, Object> data)
      {
         if (data == null)
            return null;
  -      return Collections.unmodifiableMap(new HashMap(data));
  +      return Collections.unmodifiableMap(new HashMap<Object, Object>(data));
      }
   
      /**
  @@ -146,7 +146,7 @@
       * @param pre
       * @param data
       */
  -   public synchronized void notifyNodeModified(Fqn fqn, boolean pre, Map data)
  +   public synchronized void notifyNodeModified(Fqn fqn, boolean pre, Map<Object, Object> data)
      {
         boolean originLocal = cache.getInvocationContext().isOriginLocal();
         resetInvocationContext();
  @@ -171,7 +171,7 @@
       * @param pre
       * @param data
       */
  -   public synchronized void notifyNodeRemoved(Fqn fqn, boolean pre, Map data)
  +   public synchronized void notifyNodeRemoved(Fqn fqn, boolean pre, Map<Object, Object> data)
      {
         boolean originLocal = cache.getInvocationContext().isOriginLocal();
         resetInvocationContext();
  @@ -243,7 +243,7 @@
       * @param pre
       * @param data
       */
  -   public synchronized void notifyNodeLoaded(Fqn fqn, boolean pre, Map data)
  +   public synchronized void notifyNodeLoaded(Fqn fqn, boolean pre, Map<Object, Object> data)
      {
         resetInvocationContext();
         if (evictionPolicyListener != null)
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/buddyreplication     ...
Message-ID: <E1H0kCD-0002Il-7T@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:45

  Modified:    src/org/jboss/cache/buddyreplication    
                        GravitateResult.java BuddyGroup.java
                        BuddyManager.java NextMemberBuddyLocator.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.5       +12 -11    JBossCache/src/org/jboss/cache/buddyreplication/GravitateResult.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GravitateResult.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/GravitateResult.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- GravitateResult.java	29 Nov 2006 18:56:04 -0000	1.4
  +++ GravitateResult.java	30 Dec 2006 19:48:45 -0000	1.5
  @@ -1,11 +1,11 @@
   package org.jboss.cache.buddyreplication;
   
  -import java.util.ArrayList;
  -import java.util.List;
  -
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Node;
   
  +import java.util.ArrayList;
  +import java.util.List;
  +
   public class GravitateResult
   {
      private boolean dataFound;
  @@ -89,8 +89,9 @@
      public List asList()
      {
         List l = new ArrayList();
  -      l.add(Boolean.valueOf(dataFound));
  -      if (dataFound) {
  +      l.add(dataFound);
  +      if (dataFound)
  +      {
            if (marshalledData != null)
               l.add(marshalledData);
            else
  
  
  
  1.10      +1 -1      JBossCache/src/org/jboss/cache/buddyreplication/BuddyGroup.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyGroup.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyGroup.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- BuddyGroup.java	21 Dec 2006 16:19:33 -0000	1.9
  +++ BuddyGroup.java	30 Dec 2006 19:48:45 -0000	1.10
  @@ -55,7 +55,7 @@
         this.dataOwner = dataOwner;
      }
   
  -   public List getBuddies()
  +   public List<Address> getBuddies()
      {
         return buddies;
      }
  
  
  
  1.57      +7 -7      JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BuddyManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/BuddyManager.java,v
  retrieving revision 1.56
  retrieving revision 1.57
  diff -u -b -r1.56 -r1.57
  --- BuddyManager.java	30 Dec 2006 17:49:54 -0000	1.56
  +++ BuddyManager.java	30 Dec 2006 19:48:45 -0000	1.57
  @@ -393,7 +393,7 @@
       * @param state    Map<Fqn, byte[]> of any state from the DataOwner. Cannot
       *                 be <code>null</code>.
       */
  -   public void handleAssignToBuddyGroup(BuddyGroup newGroup, Map state) throws Exception
  +   public void handleAssignToBuddyGroup(BuddyGroup newGroup, Map<Fqn, byte[]> state) throws Exception
      {
         if (!initialised) throw new BuddyNotInitException("Not yet initialised");
   
  @@ -515,7 +515,7 @@
   
      // -------------- internal helpers methods --------------------
   
  -   private void removeFromGroup(List buddies) throws InterruptedException
  +   private void removeFromGroup(List<Address> buddies) throws InterruptedException
      {
         if (log.isDebugEnabled())
            log.debug("Removing obsolete buddies from buddy group [" + buddyGroup.getGroupName() + "].  Obsolete buddies are " + buddies);
  @@ -573,8 +573,8 @@
   
         // Create the state transfer map
   
  -      Map stateMap = new HashMap();
  -      byte[] state = null;
  +      Map<Fqn, byte[]> stateMap = new HashMap<Fqn, byte[]>();
  +      byte[] state;
         if (cache.getConfiguration().isUseRegionBasedMarshalling())
         {
            Collection<Region> regions = cache.getRegionManager().getAllMarshallingRegions();
  @@ -733,13 +733,13 @@
         }
      }
   
  -   private void makeRemoteCall(List recipients, MethodCall call) throws Exception
  +   private void makeRemoteCall(List<Address> recipients, MethodCall call) throws Exception
      {
         // remove non-members from dest list
         if (recipients != null)
         {
  -         Iterator recipientsIt = recipients.iterator();
  -         List members = cache.getMembers();
  +         Iterator<Address> recipientsIt = recipients.iterator();
  +         List<Address> members = cache.getMembers();
            while (recipientsIt.hasNext())
            {
               if (!members.contains(recipientsIt.next()))
  
  
  
  1.9       +6 -7      JBossCache/src/org/jboss/cache/buddyreplication/NextMemberBuddyLocator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NextMemberBuddyLocator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/buddyreplication/NextMemberBuddyLocator.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- NextMemberBuddyLocator.java	21 Dec 2006 16:19:33 -0000	1.8
  +++ NextMemberBuddyLocator.java	30 Dec 2006 19:48:45 -0000	1.9
  @@ -128,13 +128,12 @@
         return buddies;
      }
   
  -   private boolean isInSameBuddyPool(Map buddyPoolMap, Object candidate, Object dataOwner)
  +   private boolean isInSameBuddyPool(Map<Address, String> buddyPoolMap, Address candidate, Address dataOwner)
      {
         if (buddyPoolMap == null) return true;
         Object ownerPoolName = buddyPoolMap.get(dataOwner);
         Object candidatePoolName = buddyPoolMap.get(candidate);
  -      if (ownerPoolName == null || candidatePoolName == null) return false;
  -      return ownerPoolName.equals(candidatePoolName);
  +      return !(ownerPoolName == null || candidatePoolName == null) && ownerPoolName.equals(candidatePoolName);
      }
   
      private boolean isColocated(Address candidate, Address dataOwner)
  @@ -148,12 +147,12 @@
         // now check other interfaces.
         try
         {
  -         for (Enumeration nics = NetworkInterface.getNetworkInterfaces(); nics.hasMoreElements();)
  +         for (Enumeration<NetworkInterface> nics = NetworkInterface.getNetworkInterfaces(); nics.hasMoreElements();)
            {
  -            NetworkInterface i = (NetworkInterface) nics.nextElement();
  -            for (Enumeration addrs = i.getInetAddresses(); addrs.hasMoreElements();)
  +            NetworkInterface i = nics.nextElement();
  +            for (Enumeration<InetAddress> addrs = i.getInetAddresses(); addrs.hasMoreElements();)
               {
  -               InetAddress addr = (InetAddress) addrs.nextElement();
  +               InetAddress addr = addrs.nextElement();
                  if (addr.equals(inetC)) return true;
               }
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/xml  ...
Message-ID: <E1H0kCD-0002Is-BY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:45

  Modified:    src/org/jboss/cache/xml  XmlHelper.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.13      +211 -204  JBossCache/src/org/jboss/cache/xml/XmlHelper.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: XmlHelper.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/xml/XmlHelper.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- XmlHelper.java	29 Sep 2006 18:27:21 -0000	1.12
  +++ XmlHelper.java	30 Dec 2006 19:48:45 -0000	1.13
  @@ -32,14 +32,15 @@
   public class XmlHelper
   {
       private static Log log = LogFactory.getLog(XmlHelper.class);
  -    public static final String ROOT="mbean";
  -    public static final String ATTR="attribute";
  -    public static final String CONFIG_ATTR="config";
  -    public static final String NAME="name";
  +   public static final String ROOT = "mbean";
  +   public static final String ATTR = "attribute";
  +   public static final String CONFIG_ATTR = "config";
  +   public static final String NAME = "name";
   
   
       /**
        * Returns the contents of a specific node of given tagName, provided a certain attribute exists and contains value myValue.
  +    *
        * @param elem
        * @param myName
        * @param tagName
  @@ -67,6 +68,7 @@
   
       /**
        * Retrieves the value of a given attribute for the first encountered instance of a tag in an element.
  +    *
        * @param elem
        * @param tagName
        * @param attributeName
  @@ -95,13 +97,13 @@
   
       public static Element getSubElement(Element element, String subElementName)
       {
  -      NodeList nl=element.getChildNodes();
  -      for(int i=0; i < nl.getLength(); i++)
  +      NodeList nl = element.getChildNodes();
  +      for (int i = 0; i < nl.getLength(); i++)
         {
  -         Node node=nl.item(i);
  -         if(node.getNodeType() == Node.ELEMENT_NODE && subElementName.equals( ((Element)node).getTagName() ) )
  +         Node node = nl.item(i);
  +         if (node.getNodeType() == Node.ELEMENT_NODE && subElementName.equals(((Element) node).getTagName()))
            {
  -            return (Element)node;
  +            return (Element) node;
            }
         }
   
  @@ -153,17 +155,21 @@
           }
       }
   
  -   public static String escapeBackslashes(String value) {
  +   public static String escapeBackslashes(String value)
  +   {
         StringBuffer buf = new StringBuffer(value);
  -      for(int looper = 0; looper < buf.length(); looper++) {
  +      for (int looper = 0; looper < buf.length(); looper++)
  +      {
            char curr = buf.charAt(looper);
            char next = 0;
  -         if(looper + 1 < buf.length())
  -            next = buf.charAt(looper+1);
  +         if (looper + 1 < buf.length())
  +            next = buf.charAt(looper + 1);
   
  -         if(curr == '\\') {
  -            if(next != '\\') {           // only if not already escaped
  -               buf.insert(looper,'\\');  // escape backslash
  +         if (curr == '\\')
  +         {
  +            if (next != '\\')
  +            {           // only if not already escaped
  +               buf.insert(looper, '\\');  // escape backslash
               }
               looper++;                    // skip past extra backslash (either the one we added or existing)
            }
  @@ -194,7 +200,7 @@
           String val = readStringContents(element, tagName);
           if (val.equalsIgnoreCase("true") || val.equalsIgnoreCase("false"))
           {
  -            return Boolean.valueOf(val).booleanValue();
  +         return Boolean.valueOf(val);
           }
           return defaultValue;
       }
  @@ -210,27 +216,27 @@
   
       public static Element getDocumentRoot(InputStream is)
       {
  -       Document doc=null;
  +      Document doc = null;
          try
          {
  -          InputSource xmlInp=new InputSource(is);
  +         InputSource xmlInp = new InputSource(is);
   
             DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
             DocumentBuilder parser = docBuilderFactory.newDocumentBuilder();
  -          doc=parser.parse(xmlInp);
  -          Element root=doc.getDocumentElement();
  +         doc = parser.parse(xmlInp);
  +         Element root = doc.getDocumentElement();
             root.normalize();
             return root;
          }
  -       catch(SAXParseException err)
  +      catch (SAXParseException err)
          {
             log.error("Configurator SAXParse error", err);
          }
  -       catch(SAXException e)
  +      catch (SAXException e)
          {
  -          log.error("Configurator SAX error",e);
  +         log.error("Configurator SAX error", e);
          }
  -       catch(Exception pce)
  +      catch (Exception pce)
          {
             log.error("Configurator general error", pce);
          }
  @@ -239,6 +245,7 @@
   
       /**
        * Retrieves the boolean value of a given attribute for the first encountered instance of a tag in an element.
  +    *
        * @param elem
        * @param tagName
        * @param attributeName
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:45 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/statetransfer   ...
Message-ID: <E1H0kCD-0002J2-Gt@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:45

  Modified:    src/org/jboss/cache/statetransfer  
                        DefaultStateTransferIntegrator.java
                        DefaultStateTransferGenerator.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.11      +9 -15     JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferIntegrator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- DefaultStateTransferIntegrator.java	30 Dec 2006 17:49:57 -0000	1.10
  +++ DefaultStateTransferIntegrator.java	30 Dec 2006 19:48:45 -0000	1.11
  @@ -22,7 +22,6 @@
   import java.io.IOException;
   import java.io.ObjectInputStream;
   import java.util.HashSet;
  -import java.util.Iterator;
   import java.util.Set;
   
   public class DefaultStateTransferIntegrator implements StateTransferIntegrator
  @@ -38,7 +37,7 @@
   
      private NodeFactory.NodeType nodeType;
   
  -   private Set internalFqns;
  +   private Set<Fqn> internalFqns;
   
      public DefaultStateTransferIntegrator(Fqn targetFqn, CacheImpl cache)
      {
  @@ -187,15 +186,12 @@
       */
      private void notifyAllNodesCreated(Node curr)
      {
  -      Node n;
  -
         if (curr == null) return;
         getCache().getNotifier().notifyNodeCreated(curr.getFqn(), true);
         getCache().getNotifier().notifyNodeCreated(curr.getFqn(), false);
  -      Set children = curr.getChildren();
  -      for (Iterator it = children.iterator(); it.hasNext();)
  +      Set<Node> children = curr.getChildren();
  +      for (Node n : children)
         {
  -         n = (Node) it.next();
            notifyAllNodesCreated(n);
         }
      }
  @@ -222,7 +218,7 @@
      private void integrateTransientState(Node target, ObjectInputStream in) throws IOException,
              ClassNotFoundException
      {
  -      Set retainedNodes = retainInternalNodes(target);
  +      Set<Node> retainedNodes = retainInternalNodes(target);
   
         target.getNodeSPI().removeChildren();
   
  @@ -303,13 +299,12 @@
         return null;
      }
   
  -   private Set retainInternalNodes(Node target)
  +   private Set<Node> retainInternalNodes(Node target)
      {
  -      Set result = new HashSet();
  +      Set<Node> result = new HashSet<Node>();
         Fqn targetFqn = target.getFqn();
  -      for (Iterator it = internalFqns.iterator(); it.hasNext();)
  +      for (Fqn internalFqn : internalFqns)
         {
  -         Fqn internalFqn = (Fqn) it.next();
            if (internalFqn.isChildOf(targetFqn))
            {
               Node internalNode = getInternalNode(target, internalFqn);
  @@ -338,12 +333,11 @@
         return result;
      }
   
  -   private void integrateRetainedNodes(Node root, Set retainedNodes)
  +   private void integrateRetainedNodes(Node root, Set<Node> retainedNodes)
      {
         Fqn rootFqn = root.getFqn();
  -      for (Iterator it = retainedNodes.iterator(); it.hasNext();)
  +      for (Node retained : retainedNodes)
         {
  -         Node retained = (Node) it.next();
            if (retained.getFqn().isChildOf(rootFqn))
            {
               integrateRetainedNode(root, retained);
  
  
  
  1.9       +4 -6      JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DefaultStateTransferGenerator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- DefaultStateTransferGenerator.java	30 Dec 2006 17:49:57 -0000	1.8
  +++ DefaultStateTransferGenerator.java	30 Dec 2006 19:48:45 -0000	1.9
  @@ -17,7 +17,6 @@
   import org.jboss.cache.loader.NodeDataExceptionMarker;
   
   import java.io.ObjectOutputStream;
  -import java.util.Iterator;
   import java.util.Map;
   import java.util.Set;
   
  @@ -30,7 +29,7 @@
   
      private CacheImpl cache;
   
  -   private Set internalFqns;
  +   private Set<Fqn> internalFqns;
   
      protected DefaultStateTransferGenerator(CacheImpl cache)
      {
  @@ -138,15 +137,14 @@
         out.writeObject(nd);
   
         // then visit the children
  -      Map children = node.getNodeSPI().getChildrenMap();
  +      Map<Object, Node> children = node.getNodeSPI().getChildrenMap();
         if (children == null)
         {
            return;
         }
  -      for (Iterator it = children.entrySet().iterator(); it.hasNext();)
  +      for (Node child : children.values())
         {
  -         Map.Entry entry = (Map.Entry) it.next();
  -         marshallTransientState((Node) entry.getValue(), out);
  +         marshallTransientState(child, out);
         }
      }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:45 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:45 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/transaction
	...
Message-ID: <E1H0kCD-0002JF-Lt@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:45

  Modified:    tests/functional/org/jboss/cache/transaction   
                        TransactionTest.java
                        ConcurrentTransactionalTest.java
                        ConcurrentBankTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.21      +18 -18    JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/TransactionTest.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- TransactionTest.java	30 Dec 2006 17:49:53 -0000	1.20
  +++ TransactionTest.java	30 Dec 2006 19:48:45 -0000	1.21
  @@ -37,7 +37,7 @@
    * Tests transactional access to a local CacheImpl.
    * Note: we use DummpyTranasctionManager to replace jta
    *
  - * @version $Id: TransactionTest.java,v 1.20 2006/12/30 17:49:53 msurtani Exp $
  + * @version $Id: TransactionTest.java,v 1.21 2006/12/30 19:48:45 msurtani Exp $
    */
   public class TransactionTest extends TestCase
   {
  @@ -113,14 +113,14 @@
         tx.begin();
         cache.put("/a/b/c", "age", 38);
         // the tx interceptor should know that we're in the same tx.
  -      assertEquals(cache.get("/a/b/c", "age"), new Integer(38));
  +      assertEquals(cache.get("/a/b/c", "age"), 38);
   
         cache.put("/a/b/c", "age", 39);
         tx.commit();
   
         // This test is done outside the TX, it wouldn't work if someone else
         // modified "age". This works because we're the only TX running.
  -      assertEquals(cache.get("/a/b/c", "age"), new Integer(39));
  +      assertEquals(cache.get("/a/b/c", "age"), 39);
      }
   
   
  @@ -129,8 +129,8 @@
         try
         {
            tx.begin();
  -         cache.put("/a/b/c", "age", new Integer(38));
  -         cache.put("/a/b/c", "age", new Integer(39));
  +         cache.put("/a/b/c", "age", 38);
  +         cache.put("/a/b/c", "age", 39);
            tx.rollback();
   
            // This test is done outside the TX, it wouldn't work if someone else
  @@ -187,7 +187,7 @@
         try
         {
            tx.begin();
  -         cache.put("/a/b/c", "age", new Integer(38));
  +         cache.put("/a/b/c", "age", 38);
            cache.remove("/a/b/c", "age");
            tx.rollback();
   
  @@ -207,7 +207,7 @@
         try
         {
            System.out.println("locks " + cache.printLockInfo());
  -         cache.put("/a/b/c", "age", new Integer(38));
  +         cache.put("/a/b/c", "age", 38);
            System.out.println("locks " + cache.printLockInfo());
            tx.begin();
            cache.remove("/a/b/c", "age");
  @@ -215,7 +215,7 @@
   
            // This test is done outside the TX, it wouldn't work if someone else
            // modified "age". This works because we're the only TX running.
  -         assertEquals(new Integer(38), cache.get("/a/b/c", "age"));
  +         assertEquals(38, cache.get("/a/b/c", "age"));
         }
         catch (Throwable t)
         {
  @@ -229,9 +229,9 @@
         try
         {
            java.util.Map map1 = new java.util.HashMap();
  -         map1.put("age", new Integer(38));
  +         map1.put("age", 38);
            java.util.Map map2 = new java.util.HashMap();
  -         map2.put("age", new Integer(39));
  +         map2.put("age", 39);
            tx.begin();
            cache.put("/a/b/c", map1);
            cache.put("/a/b/c", map2);
  @@ -254,7 +254,7 @@
         try
         {
            Map map = new HashMap();
  -         map.put("age", new Integer(38));
  +         map.put("age", 38);
            tx.begin();
            cache.put("/a/b/c", map);
            cache.remove("/a/b/c");
  @@ -726,7 +726,7 @@
         {
            Map m = new HashMap();
            m.put("name", "Bela");
  -         m.put("id", new Integer(322649));
  +         m.put("id", 322649);
            cache.put("/bela/ban", m);
            tx.begin();
            cache.remove("/bela/ban", "name");
  @@ -766,8 +766,8 @@
         try
         {
            tx.begin();
  -         cache.put("/foo/1", "item", new Integer(1));
  -         assertEquals(cache.get("/foo/1", "item"), new Integer(1));
  +         cache.put("/foo/1", "item", 1);
  +         assertEquals(cache.get("/foo/1", "item"), 1);
            cache.remove("/foo/1");
            assertNull(cache.get("/foo/1", "item"));
            cache.remove("/foo/1");
  @@ -794,7 +794,7 @@
            tx.begin();
            Map m = new HashMap();
            m.put("name", "Bela");
  -         m.put("id", new Integer(322649));
  +         m.put("id", 322649);
            cache.put("/bela/ban", m);
            tx.rollback();
   
  @@ -817,7 +817,7 @@
         Map m1, m2;
         m1 = new HashMap();
         m1.put("name", "Bela");
  -      m1.put("id", new Integer(322649));
  +      m1.put("id", 322649);
         m2 = new HashMap();
         m2.put("other", "bla");
         m2.put("name", "Michelle");
  @@ -831,14 +831,14 @@
            Map tmp = cache.get("/bela/ban").getData();
            assertEquals(3, tmp.size());
            assertEquals("Michelle", tmp.get("name"));
  -         assertEquals(tmp.get("id"), new Integer(322649));
  +         assertEquals(tmp.get("id"), 322649);
            assertEquals("bla", tmp.get("other"));
            tx.rollback();
   
            tmp = cache.get("/bela/ban").getData();
            assertEquals(2, tmp.size());
            assertEquals("Bela", tmp.get("name"));
  -         assertEquals(tmp.get("id"), new Integer(322649));
  +         assertEquals(tmp.get("id"), 322649);
         }
         catch (Throwable t)
         {
  
  
  
  1.7       +2 -2      JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentTransactionalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentTransactionalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentTransactionalTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ConcurrentTransactionalTest.java	30 Dec 2006 17:49:53 -0000	1.6
  +++ ConcurrentTransactionalTest.java	30 Dec 2006 19:48:45 -0000	1.7
  @@ -32,7 +32,7 @@
    * Unit test for local CacheImpl. Use locking and multiple threads to test
    * concurrent access to the tree.
    *
  - * @version $Id: ConcurrentTransactionalTest.java,v 1.6 2006/12/30 17:49:53 msurtani Exp $
  + * @version $Id: ConcurrentTransactionalTest.java,v 1.7 2006/12/30 19:48:45 msurtani Exp $
    */
   public class ConcurrentTransactionalTest extends TestCase
   {
  @@ -219,7 +219,7 @@
               {
                  log("adding data i=" + i);
                  tx.begin();
  -               cache.put("/a/b/c", new Integer(i), val);
  +               cache.put("/a/b/c", i, val);
                  tx.commit();
                  yield();
               }
  
  
  
  1.8       +9 -9      JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentBankTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentBankTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/transaction/ConcurrentBankTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ConcurrentBankTest.java	30 Dec 2006 17:49:53 -0000	1.7
  +++ ConcurrentBankTest.java	30 Dec 2006 19:48:45 -0000	1.8
  @@ -26,7 +26,7 @@
    *
    * @author <a href="mailto:spohl at users.sourceforge.net">Stefan Pohl</a>
    * @author Ben Wang
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   public class ConcurrentBankTest extends TestCase
   {
  @@ -95,9 +95,9 @@
         {
            if (cache.get(NODE) == null)
            {
  -            cache.put(NODE, "cu1", new Integer(1000));
  -            cache.put(NODE, "cu2", new Integer(1000));
  -            cache.put(NODE, "cu3", new Integer(1000));
  +            cache.put(NODE, "cu1", 1000);
  +            cache.put(NODE, "cu2", 1000);
  +            cache.put(NODE, "cu3", 1000);
            }
   
            one = new Teller("one", cache);
  @@ -231,8 +231,8 @@
            log("deposit(" + from + ", " + to + ", " + amount + ") called.");
            int act;
            // debit
  -         act = ((Integer) cache.get(NODE, from)).intValue();
  -         cache.put(NODE, from, new Integer(act - amount));
  +         act = (Integer) cache.get(NODE, from);
  +         cache.put(NODE, from, act - amount);
            log("deposit(" + from + ", " + to + ", " + amount + ") debited.");
   
            // eventually rollback the transaction
  @@ -244,8 +244,8 @@
            }
   
            // credit
  -         act = ((Integer) cache.get(NODE, to)).intValue();
  -         cache.put(NODE, to, new Integer(act + amount));
  +         act = (Integer) cache.get(NODE, to);
  +         cache.put(NODE, to, act + amount);
   
            log("deposit(" + from + ", " + to + ", " + amount + ") finished.");
         }
  @@ -280,7 +280,7 @@
            int result = 0;
            while (iter.hasNext())
            {
  -            result += ((Integer) iter.next()).intValue();
  +            result += (Integer) iter.next();
            }
            return result;
         }
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:46 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/eviction ...
Message-ID: <E1H0kCE-0002Jh-1r@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:46

  Modified:    tests/functional/org/jboss/cache/eviction        
                        ElementSizePolicyTest.java
                        ConcurrentEvictionTest.java FIFOPolicyTest.java
                        LFUPolicyTest.java MRUPolicyTest.java
                        LRUPolicyTest.java ProgrammaticLRUPolicyTest.java
                        ExpirationPolicyTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.11      +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/ElementSizePolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ElementSizePolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ElementSizePolicyTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- ElementSizePolicyTest.java	30 Dec 2006 17:49:58 -0000	1.10
  +++ ElementSizePolicyTest.java	30 Dec 2006 19:48:45 -0000	1.11
  @@ -150,7 +150,7 @@
   
         for (int i = 0; i < 17; i++)
         {
  -         cache.put("/org/jboss/data/" + Integer.toString(3), new Integer(100 + i), "value");
  +         cache.put("/org/jboss/data/" + Integer.toString(3), 100 + i, "value");
         }
   
         Node node = cache.get("/org/jboss/data/" + Integer.toString(3));
  @@ -175,7 +175,7 @@
            {
               try
               {
  -               cache.put(myName + i++, "value", new Integer(i));
  +               cache.put(myName + i++, "value", i);
                  sleep(1);
               }
               catch (Throwable e)
  @@ -196,7 +196,7 @@
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
   
         cache.start();
  -      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", new Integer(1));
  +      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", 1);
   
         for (int i = 0; i < 10; i++)
         {
  
  
  
  1.7       +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentEvictionTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ConcurrentEvictionTest.java	30 Dec 2006 17:49:58 -0000	1.6
  +++ ConcurrentEvictionTest.java	30 Dec 2006 19:48:45 -0000	1.7
  @@ -19,7 +19,7 @@
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class ConcurrentEvictionTest extends TestCase
   {
  @@ -66,7 +66,7 @@
         // region's maxNodes so we know eviction will kick in
         for (int i = 0; i < 1000; i++)
         {
  -         cache_.put(new Fqn(base, new Integer(i / 100)), new Integer(i), "value");
  +         cache_.put(new Fqn(base, i / 100), new Integer(i), "value");
         }
   
         // Loop for long enough to have 5 runs of the eviction thread
  @@ -76,8 +76,8 @@
            // If any get returns null, that's a failure
            for (int i = 0; i < 1000; i++)
            {
  -            Fqn fqn = new Fqn(base, new Integer(i / 100));
  -            Integer key = new Integer(i);
  +            Fqn fqn = new Fqn(base, i / 100);
  +            Integer key = i;
               assertNotNull("found value under Fqn " + fqn + " and key " + key,
                       cache_.get(fqn, key));
            }
  
  
  
  1.12      +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/FIFOPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FIFOPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/FIFOPolicyTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- FIFOPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.11
  +++ FIFOPolicyTest.java	30 Dec 2006 19:48:45 -0000	1.12
  @@ -17,7 +17,7 @@
    * Unit tests for FIFOPolicy.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class FIFOPolicyTest extends TestCase
   {
  @@ -272,7 +272,7 @@
            {
               try
               {
  -               cache.put(myName + i++, "value", new Integer(i));
  +               cache.put(myName + i++, "value", i);
                  sleep(1);
               }
               catch (Throwable e)
  @@ -292,7 +292,7 @@
         cache.destroy();
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache.start();
  -      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", new Integer(1));
  +      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", 1);
   
         for (int i = 0; i < 10; i++)
         {
  
  
  
  1.10      +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/LFUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LFUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/LFUPolicyTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- LFUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.9
  +++ LFUPolicyTest.java	30 Dec 2006 19:48:45 -0000	1.10
  @@ -18,7 +18,7 @@
    * Unit tests for LFU Policy.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.9 $
  + * @version $Revision: 1.10 $
    */
   public class LFUPolicyTest extends TestCase
   {
  @@ -294,7 +294,7 @@
            {
               try
               {
  -               cache.put(myName + i++, "value", new Integer(i));
  +               cache.put(myName + i++, "value", i);
                  sleep(1);
               }
               catch (Throwable e)
  @@ -314,7 +314,7 @@
         cache.destroy();
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache.start();
  -      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", new Integer(1));
  +      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", 1);
   
         for (int i = 0; i < 10; i++)
         {
  
  
  
  1.12      +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/MRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/MRUPolicyTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- MRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.11
  +++ MRUPolicyTest.java	30 Dec 2006 19:48:45 -0000	1.12
  @@ -16,7 +16,7 @@
    * Unit tests for MRUPolicy.
    *
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Revision: 1.11 $
  + * @version $Revision: 1.12 $
    */
   public class MRUPolicyTest extends TestCase
   {
  @@ -123,7 +123,7 @@
            {
               try
               {
  -               cache.put(myName + i++, "value", new Integer(i));
  +               cache.put(myName + i++, "value", i);
                  TestingUtil.sleepThread(1);
               }
               catch (Throwable e)
  @@ -143,7 +143,7 @@
         cache.destroy();
         cache.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache.start();
  -      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", new Integer(1));
  +      cache.put(ROOT_STR + "/concurrentPutAndEvict", "value", 1);
   
         for (int i = 0; i < 10; i++)
         {
  
  
  
  1.21      +3 -3      JBossCache/tests/functional/org/jboss/cache/eviction/LRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/LRUPolicyTest.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- LRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.20
  +++ LRUPolicyTest.java	30 Dec 2006 19:48:45 -0000	1.21
  @@ -14,7 +14,7 @@
    *
    * @author Ben Wang, Feb 11, 2004
    * @author Daniel Huang - dhuang at jboss.org
  - * @version $Revision: 1.20 $
  + * @version $Revision: 1.21 $
    */
   public class LRUPolicyTest extends TestCase
   {
  @@ -252,7 +252,7 @@
            {
               try
               {
  -               cache_.put(myName + i++, "value", new Integer(i));
  +               cache_.put(myName + i++, "value", i);
                  sleep(1);
               }
               catch (Throwable e)
  @@ -273,7 +273,7 @@
         cache_.getConfiguration().setIsolationLevel(IsolationLevel.REPEATABLE_READ);
         cache_.create();
         cache_.start();
  -      cache_.put(ROOT_STR + "/concurrentPutAndEvict", "value", new Integer(1));
  +      cache_.put(ROOT_STR + "/concurrentPutAndEvict", "value", 1);
   
         for (int i = 0; i < 10; i++)
         {
  
  
  
  1.9       +5 -5      JBossCache/tests/functional/org/jboss/cache/eviction/ProgrammaticLRUPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ProgrammaticLRUPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ProgrammaticLRUPolicyTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ProgrammaticLRUPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.8
  +++ ProgrammaticLRUPolicyTest.java	30 Dec 2006 19:48:45 -0000	1.9
  @@ -40,7 +40,7 @@
    * Unit tests for programmatic configuration of LRU policy
    *
    * @author Ben Wang, Oct, 2006
  - * @version $Revision: 1.8 $
  + * @version $Revision: 1.9 $
    */
   public class ProgrammaticLRUPolicyTest extends TestCase
   {
  @@ -191,11 +191,11 @@
      {
         addObjectBasedRegion();
   
  -      Integer ii = new Integer(1);
  +      Integer ii = 1;
         Fqn rootfqn = new Fqn(ii);
         for (int i = 0; i < 10; i++)
         {
  -         Integer in = new Integer(i);
  +         Integer in = i;
            Fqn fqn = new Fqn(rootfqn, in);
            try
            {
  @@ -210,7 +210,7 @@
   
         try
         {
  -         Integer in = new Integer(3);
  +         Integer in = 3;
            Fqn fqn = new Fqn(rootfqn, in);
            Object val = cache_.get(fqn, in);
            assertNotNull("DataNode should be empty ", val);
  @@ -226,7 +226,7 @@
         System.out.println(cache_.toString());
         try
         {
  -         Integer in = new Integer(3);
  +         Integer in = 3;
            Fqn fqn = new Fqn(rootfqn, in);
            Object val = cache_.get(fqn, in);
            assertNull("DataNode should be empty ", val);
  
  
  
  1.5       +4 -4      JBossCache/tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationPolicyTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- ExpirationPolicyTest.java	30 Dec 2006 17:49:58 -0000	1.4
  +++ ExpirationPolicyTest.java	30 Dec 2006 19:48:45 -0000	1.5
  @@ -19,7 +19,7 @@
    * Unit tests for {@link ExpirationPolicy}.
    *
    * @author Elias Ross
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    */
   public class ExpirationPolicyTest extends TestCase
   {
  @@ -46,8 +46,8 @@
         cache.setConfiguration(conf);
         cache.start();
   
  -      future = Long.valueOf(System.currentTimeMillis() + 4000);
  -      past = Long.valueOf(System.currentTimeMillis() - 2000);
  +      future = System.currentTimeMillis() + 4000;
  +      past = System.currentTimeMillis() - 2000;
      }
   
      public void tearDown() throws Exception
  @@ -93,7 +93,7 @@
         EvictionPolicyConfig epc = cache.getRegionManager().getAllEvictionRegions().get(0).getEvictionPolicyConfig();
         ExpirationConfiguration ec = (ExpirationConfiguration) epc;
         ec.setMaxNodes(2);
  -      Long future2 = Long.valueOf(future.longValue() + 500);
  +      Long future2 = future + 500;
         cache.put(fqn1, ExpirationConfiguration.DEFAULT_EXPIRATION_KEY, future2);
         cache.put(fqn2, ExpirationConfiguration.DEFAULT_EXPIRATION_KEY, future2);
         cache.put(fqn3, ExpirationConfiguration.DEFAULT_EXPIRATION_KEY, future);
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:46 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors       ...
Message-ID: <E1H0kCE-0002K3-70@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:46

  Modified:    src/org/jboss/cache/interceptors      
                        OptimisticNodeInterceptor.java
                        CacheStoreInterceptor.java
                        DataGravitatorInterceptor.java
                        ActivationInterceptor.java EvictionInterceptor.java
                        Interceptor.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.38      +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.37
  retrieving revision 1.38
  diff -u -b -r1.37 -r1.38
  --- OptimisticNodeInterceptor.java	30 Dec 2006 17:49:53 -0000	1.37
  +++ OptimisticNodeInterceptor.java	30 Dec 2006 19:48:46 -0000	1.38
  @@ -120,7 +120,7 @@
            {
               case MethodDeclarations.putDataMethodLocal_id:
                  Boolean erase = (Boolean) args[3];
  -               putDataMap(args, erase.booleanValue(), workspace, workspaceNode);
  +               putDataMap(args, erase, workspace, workspaceNode);
                  break;
               case MethodDeclarations.putDataEraseMethodLocal_id:
                  putDataMap(args, true, workspace, workspaceNode);
  
  
  
  1.41      +3 -3      JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheStoreInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java,v
  retrieving revision 1.40
  retrieving revision 1.41
  diff -u -b -r1.40 -r1.41
  --- CacheStoreInterceptor.java	30 Dec 2006 17:49:54 -0000	1.40
  +++ CacheStoreInterceptor.java	30 Dec 2006 19:48:46 -0000	1.41
  @@ -27,7 +27,7 @@
    * through the CacheLoader, either after each method call (no TXs), or at TX commit.
    *
    * @author Bela Ban
  - * @version $Id: CacheStoreInterceptor.java,v 1.40 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: CacheStoreInterceptor.java,v 1.41 2006/12/30 19:48:46 msurtani Exp $
    */
   public class CacheStoreInterceptor extends BaseCacheLoaderInterceptor implements CacheStoreInterceptorMBean
   {
  @@ -108,7 +108,7 @@
                        Integer puts = (Integer) m_txStores.get(gtx);
                        if (puts != null)
                        {
  -                        m_cacheStores = m_cacheStores + puts.intValue();
  +                        m_cacheStores = m_cacheStores + puts;
                        }
                        m_txStores.remove(gtx);
                     }
  @@ -379,7 +379,7 @@
            preparingTxs.put(gtx, gtx);
            if (configuration.getExposeManagementStatistics() && getStatisticsEnabled() && txPuts > 0)
            {
  -            m_txStores.put(gtx, new Integer(txPuts));
  +            m_txStores.put(gtx, txPuts);
            }
         }
      }
  
  
  
  1.32      +1 -1      JBossCache/src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DataGravitatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- DataGravitatorInterceptor.java	30 Dec 2006 17:49:54 -0000	1.31
  +++ DataGravitatorInterceptor.java	30 Dec 2006 19:48:46 -0000	1.32
  @@ -339,7 +339,7 @@
                  // keep looping till we find a FOUND answer.
                  List dGravResp = (List) o;
                  // found?
  -               if (((Boolean) dGravResp.get(0)).booleanValue())
  +               if ((Boolean) dGravResp.get(0))
                  {
                     result = dGravResp.get(1);
                     backupFqn = dGravResp.get(2);
  
  
  
  1.46      +4 -4      JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ActivationInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/ActivationInterceptor.java,v
  retrieving revision 1.45
  retrieving revision 1.46
  diff -u -b -r1.45 -r1.46
  --- ActivationInterceptor.java	30 Dec 2006 17:49:54 -0000	1.45
  +++ ActivationInterceptor.java	30 Dec 2006 19:48:46 -0000	1.46
  @@ -25,7 +25,7 @@
    * their attributes have been initialized and their children have been loaded in memory.
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: ActivationInterceptor.java,v 1.45 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: ActivationInterceptor.java,v 1.46 2006/12/30 19:48:46 msurtani Exp $
    */
   public class ActivationInterceptor extends CacheLoaderInterceptor implements ActivationInterceptorMBean
   {
  @@ -250,10 +250,10 @@
      protected boolean hasModifications(Object[] args)
      {
         int hint = 1;
  -      if (args[hint] instanceof Boolean) return ((Boolean) args[hint]).booleanValue();
  +      if (args[hint] instanceof Boolean) return (Boolean) args[hint];
         for (int i = 0; i < args.length; i++)
         {
  -         if (args[i] instanceof Boolean) return ((Boolean) args[i]).booleanValue();
  +         if (args[i] instanceof Boolean) return (Boolean) args[i];
         }
         return false;
      }
  @@ -330,7 +330,7 @@
            loader.prepare(gtx, cache_loader_modifications, false);
            if (configuration.getExposeManagementStatistics() && getStatisticsEnabled() && txActs > 0)
            {
  -            m_txActivations.put(gtx, Integer.valueOf(txActs));
  +            m_txActivations.put(gtx, txActs);
            }
         }
      }
  
  
  
  1.11      +19 -19    JBossCache/src/org/jboss/cache/interceptors/EvictionInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/EvictionInterceptor.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- EvictionInterceptor.java	27 Nov 2006 04:49:46 -0000	1.10
  +++ EvictionInterceptor.java	30 Dec 2006 19:48:46 -0000	1.11
  @@ -11,12 +11,12 @@
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.CacheSPI;
   import org.jboss.cache.Fqn;
  -import org.jboss.cache.RegionManager;
   import org.jboss.cache.Region;
  +import org.jboss.cache.RegionManager;
   import org.jboss.cache.eviction.EvictedEventNode;
   import org.jboss.cache.eviction.NodeEventType;
  -import org.jboss.cache.marshall.MethodDeclarations;
   import org.jboss.cache.marshall.MethodCall;
  +import org.jboss.cache.marshall.MethodDeclarations;
   
   import java.util.HashMap;
   import java.util.Map;
  @@ -27,7 +27,7 @@
    * This interceptor is used to handle eviction events.
    *
    * @author Daniel Huang
  - * @version $Revision: 1.10 $
  + * @version $Revision: 1.11 $
    */
   public class EvictionInterceptor extends Interceptor
   {
  @@ -315,7 +315,7 @@
               }
   
               EvictedEventNode event = new EvictedEventNode(fqn, NodeEventType.ADD_NODE_EVENT, size);
  -            event.setResetElementCount(resetElementCount.booleanValue());
  +            event.setResetElementCount(resetElementCount);
               return event;
            }
   
  
  
  
  1.26      +4 -4      JBossCache/src/org/jboss/cache/interceptors/Interceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Interceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/Interceptor.java,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -b -r1.25 -r1.26
  --- Interceptor.java	13 Sep 2006 13:11:18 -0000	1.25
  +++ Interceptor.java	30 Dec 2006 19:48:46 -0000	1.26
  @@ -39,7 +39,7 @@
    * <em>Note that this will be replaced by {@link org.jboss.aop.advice.Interceptor} in one of the next releases</em>
    *
    * @author Bela Ban
  - * @version $Id: Interceptor.java,v 1.25 2006/09/13 13:11:18 msurtani Exp $
  + * @version $Id: Interceptor.java,v 1.26 2006/12/30 19:48:46 msurtani Exp $
    */
   public abstract class Interceptor implements InterceptorMBean
   {
  @@ -171,10 +171,10 @@
         switch (m.getMethodId())
         {
            case MethodDeclarations.prepareMethod_id:
  -            return ((Boolean) m.getArgs()[3]).booleanValue();
  +            return (Boolean) m.getArgs()[3];
            case MethodDeclarations.optimisticPrepareMethod_id:
  -            return ((Boolean) m.getArgs()[4]).booleanValue();
  -         default :
  +            return (Boolean) m.getArgs()[4];
  +         default:
               return false;
         }
      }
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:46 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache     ...
Message-ID: <E1H0kCE-0002KJ-BE@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:46

  Modified:    src/org/jboss/cache     CacheImpl.java CacheListener.java
                        Fqn.java Node.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.2       +4 -4      JBossCache/src/org/jboss/cache/CacheImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/CacheImpl.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- CacheImpl.java	30 Dec 2006 17:49:54 -0000	1.1
  +++ CacheImpl.java	30 Dec 2006 19:48:46 -0000	1.2
  @@ -98,7 +98,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: CacheImpl.java,v 1.1 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: CacheImpl.java,v 1.2 2006/12/30 19:48:46 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -165,7 +165,7 @@
       * Set<Fqn> of Fqns of the topmost node of internal regions that should
       * not included in standard state transfers.
       */
  -   protected Set internalFqns = new CopyOnWriteArraySet();
  +   protected Set<Fqn> internalFqns = new CopyOnWriteArraySet<Fqn>();
   
      /**
       * True if state was initialized during start-up.
  @@ -903,7 +903,7 @@
       *
       * @return an unmodifiable Set<Fqn>.  Will not return <code>null</code>.
       */
  -   public Set getInternalFqns()
  +   public Set<Fqn> getInternalFqns()
      {
         return Collections.unmodifiableSet(internalFqns);
      }
  @@ -3097,7 +3097,7 @@
      public void setConfiguration(Configuration configuration)
      {
         this.configuration = configuration;
  -      configuration.setTreeCache(this);
  +      configuration.setCacheImpl(this);
      }
   
      /**
  
  
  
  1.4       +3 -3      JBossCache/src/org/jboss/cache/CacheListener.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheListener.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/CacheListener.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- CacheListener.java	18 Oct 2006 11:07:54 -0000	1.3
  +++ CacheListener.java	30 Dec 2006 19:48:46 -0000	1.4
  @@ -42,7 +42,7 @@
       * @param pre
       * @param isLocal
       */
  -   void nodeModified(Fqn fqn, boolean pre, boolean isLocal, Map data);
  +   void nodeModified(Fqn fqn, boolean pre, boolean isLocal, Map<Object, Object> data);
   
      /**
       * Called before and after a {@link Node} is removed.  Data passed in is
  @@ -55,7 +55,7 @@
       * @param pre
       * @param isLocal
       */
  -   void nodeRemoved(Fqn fqn, boolean pre, boolean isLocal, Map data);
  +   void nodeRemoved(Fqn fqn, boolean pre, boolean isLocal, Map<Object, Object> data);
   
      /**
       * Called when a {@link Node} is visisted, i.e., {@link Node#get(Object)} is called.
  @@ -80,7 +80,7 @@
       * The data passed in is an unmodifiable {@link Map}.  If the {@link Node} is loaded but the data isn't
       * (for example when calling {@link Node#getChildren()}) the data map is null.
       */
  -   void nodeLoaded(Fqn fqn, boolean pre, Map data);
  +   void nodeLoaded(Fqn fqn, boolean pre, Map<Object, Object> data);
   
      /**
       * Called when a {@link Node} is moved using the {@link Node#move(Node)} API.
  
  
  
  1.44      +2 -2      JBossCache/src/org/jboss/cache/Fqn.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Fqn.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Fqn.java,v
  retrieving revision 1.43
  retrieving revision 1.44
  diff -u -b -r1.43 -r1.44
  --- Fqn.java	30 Dec 2006 17:49:54 -0000	1.43
  +++ Fqn.java	30 Dec 2006 19:48:46 -0000	1.44
  @@ -42,7 +42,7 @@
    * <p/>
    * Another way to look at it is that the "/" separarator is only parsed when it form sa  part of a String passed in to Fqn.fromString() and not otherwise.
    *
  - * @version $Revision: 1.43 $
  + * @version $Revision: 1.44 $
    */
   public class Fqn implements Cloneable, Externalizable, Comparable<Fqn>
   {
  @@ -78,7 +78,7 @@
                       public Object run()
                       {
                          String compatible = System.getProperty("jboss.cache.fqn.123compatible");
  -                       REL_123_COMPATIBLE = Boolean.valueOf(compatible).booleanValue();
  +                       REL_123_COMPATIBLE = Boolean.valueOf(compatible);
                          return null;
                       }
                    });
  
  
  
  1.52      +2 -2      JBossCache/src/org/jboss/cache/Node.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Node.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Node.java,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -b -r1.51 -r1.52
  --- Node.java	30 Dec 2006 17:49:54 -0000	1.51
  +++ Node.java	30 Dec 2006 19:48:46 -0000	1.52
  @@ -116,7 +116,7 @@
       *
       * @param m
       */
  -   void put(Map m);
  +   void put(Map<Object, Object> m);
   
      /**
       * Puts an entire map of key-value pairs into the current node's data map.  If any data exists, existing
  @@ -126,7 +126,7 @@
       *
       * @param m
       */
  -   void putIfNull(Map m);
  +   void putIfNull(Map<Object, Object> m);
   
   
      /**
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:46 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache     ...
Message-ID: <E1H0kCE-0002KZ-Ej@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:46

  Modified:    tests/functional/org/jboss/cache     GetKeysTest.java
                        TreeNodeTest.java FqnTest.java
                        TreeCacheFunctionalTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.4       +2 -2      JBossCache/tests/functional/org/jboss/cache/GetKeysTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: GetKeysTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/GetKeysTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- GetKeysTest.java	30 Dec 2006 17:49:54 -0000	1.3
  +++ GetKeysTest.java	30 Dec 2006 19:48:46 -0000	1.4
  @@ -18,7 +18,7 @@
   
   /**
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a>
  - * @version $Id: GetKeysTest.java,v 1.3 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: GetKeysTest.java,v 1.4 2006/12/30 19:48:46 msurtani Exp $
    */
   public class GetKeysTest extends TestCase
   {
  @@ -45,7 +45,7 @@
         cache.create();
         cache.start();
         cache.put("/a/b/c", "name", "Bela Ban");
  -      cache.put("/a/b/c", "age", new Integer(40));
  +      cache.put("/a/b/c", "age", 40);
         cache.put("/a/b/c", "city", "Kreuzlingen");
   
         Set keys = cache.getKeys("/a/b/c");
  
  
  
  1.5       +2 -2      JBossCache/tests/functional/org/jboss/cache/TreeNodeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeNodeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/TreeNodeTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- TreeNodeTest.java	30 Dec 2006 17:49:54 -0000	1.4
  +++ TreeNodeTest.java	30 Dec 2006 19:48:46 -0000	1.5
  @@ -8,7 +8,7 @@
    * Tests restart (stop-destroy-create-start) of CacheImpl
    *
    * @author Bela Ban
  - * @version $Id: TreeNodeTest.java,v 1.4 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: TreeNodeTest.java,v 1.5 2006/12/30 19:48:46 msurtani Exp $
    */
   public class TreeNodeTest extends TestCase
   {
  @@ -29,7 +29,7 @@
   
      public void testChildExist() throws Exception
      {
  -      Object key = new Integer(1);
  +      Object key = 1;
         cache.put("/a/b/c", key, "test");
         Node node;
         node = cache.get("/a/b");
  
  
  
  1.18      +19 -19    JBossCache/tests/functional/org/jboss/cache/FqnTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FqnTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/FqnTest.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- FqnTest.java	30 Dec 2006 17:49:54 -0000	1.17
  +++ FqnTest.java	30 Dec 2006 19:48:46 -0000	1.18
  @@ -20,7 +20,7 @@
    * Tests {@link Fqn}.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> May 9, 2003
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class FqnTest extends TestCase
   {
  @@ -41,7 +41,7 @@
   
      public void testOne()
      {
  -      Fqn fqn = new Fqn(new Integer(22));
  +      Fqn fqn = new Fqn(22);
         log("one fqn is " + fqn);
         assertEquals(1, fqn.size());
         int hcode = fqn.hashCode();
  @@ -70,11 +70,11 @@
   
      public void testHereogeneousNames()
      {
  -      Fqn fqn = new Fqn(new Object[]{"string", new Integer(38), new Boolean(true)});
  +      Fqn fqn = new Fqn(new Object[]{"string", 38, true});
         log("fqn is " + fqn);
         assertEquals(3, fqn.size());
   
  -      Fqn fqn2 = new Fqn(new Object[]{"string", new Integer(38), new Boolean(true)});
  +      Fqn fqn2 = new Fqn(new Object[]{"string", 38, true});
         assertEquals(fqn, fqn2);
         assertEquals(fqn.hashCode(), fqn2.hashCode());
      }
  @@ -88,15 +88,15 @@
         assertEquals(fqn1, fqn2);
   
         HashMap map = new HashMap();
  -      map.put(fqn1, new Integer(33));
  -      map.put(fqn2, new Integer(34));
  +      map.put(fqn1, 33);
  +      map.put(fqn2, 34);
         assertEquals(1, map.size());
  -      assertEquals(new Integer(34), map.get(fqn1));
  +      assertEquals(34, map.get(fqn1));
      }
   
      public void testHashcode2()
      {
  -      Fqn fqn = new Fqn(new Integer(-1));
  +      Fqn fqn = new Fqn(-1);
         log("one fqn is " + fqn);
         assertEquals(1, fqn.size());
         int hcode = fqn.hashCode();
  @@ -151,7 +151,7 @@
      public void testEquals3()
      {
         Fqn f1, f2;
  -      f1 = new Fqn(new Object[]{"a", new Integer(322649), Boolean.TRUE});
  +      f1 = new Fqn(new Object[]{"a", 322649, Boolean.TRUE});
         f2 = new Fqn();
         assertFalse(f1.equals(f2));
         assertFalse(f2.equals(f1));
  @@ -159,17 +159,17 @@
         f2 = Fqn.fromString("a/322649/TRUE");
         assertFalse(f1.equals(f2));
   
  -      f2 = new Fqn(new Object[]{"a", new Integer(322649), Boolean.FALSE});
  +      f2 = new Fqn(new Object[]{"a", 322649, Boolean.FALSE});
         assertFalse(f1.equals(f2));
   
  -      f2 = new Fqn(new Object[]{"a", new Integer(322649), Boolean.TRUE});
  +      f2 = new Fqn(new Object[]{"a", 322649, Boolean.TRUE});
         assertEquals(f1, f2);
      }
   
      public void testEquals3WithMarshalling() throws Exception
      {
         Fqn f1, f2;
  -      f1 = new Fqn(new Object[]{"a", new Integer(322649), Boolean.TRUE});
  +      f1 = new Fqn(new Object[]{"a", 322649, Boolean.TRUE});
         f2 = marshalAndUnmarshal(f1);
         assertEquals(f1, f2);
         assertEquals(f2, f1);
  @@ -178,11 +178,11 @@
         f2 = marshalAndUnmarshal(f2);
         assertFalse(f1.equals(f2));
   
  -      f2 = new Fqn(new Object[]{"a", new Integer(322649), Boolean.FALSE});
  +      f2 = new Fqn(new Object[]{"a", 322649, Boolean.FALSE});
         f2 = marshalAndUnmarshal(f2);
         assertFalse(f1.equals(f2));
   
  -      f2 = new Fqn(new Object[]{"a", new Integer(322649), Boolean.TRUE});
  +      f2 = new Fqn(new Object[]{"a", 322649, Boolean.TRUE});
         f2 = marshalAndUnmarshal(f2);
         assertEquals(f1, f2);
      }
  @@ -209,10 +209,10 @@
         Fqn fqn0 = new Fqn((Object) null);
         assertEquals(1, fqn0.size());
   
  -      Fqn fqn1 = new Fqn(new Object[]{"NULL", null, new Integer(0)});
  +      Fqn fqn1 = new Fqn(new Object[]{"NULL", null, 0});
         assertEquals(3, fqn1.size());
   
  -      Fqn fqn2 = new Fqn(new Object[]{"NULL", null, new Integer(0),});
  +      Fqn fqn2 = new Fqn(new Object[]{"NULL", null, 0,});
         assertEquals(fqn1.hashCode(), fqn2.hashCode());
         assertEquals(fqn1, fqn2);
         assertEquals(fqn1, fqn1.clone());
  @@ -287,7 +287,7 @@
   
      public void testGetName()
      {
  -      Fqn integerFqn = new Fqn(new Integer(1));
  +      Fqn integerFqn = new Fqn(1);
         assertEquals("1", integerFqn.getName());
   
         Object object = new Object();
  @@ -303,13 +303,13 @@
   
      public void testCloningOtherTypes() throws CloneNotSupportedException
      {
  -      Fqn f = new Fqn(new Object[]{"blah", new Integer(10), Boolean.TRUE});
  +      Fqn f = new Fqn(new Object[]{"blah", 10, Boolean.TRUE});
         assertEquals(f, f.clone());
      }
   
      public void testRemovalNonString() throws Exception
      {
  -      Fqn f = new Fqn(new Object[]{"test", new Integer(1)});
  +      Fqn f = new Fqn(new Object[]{"test", 1});
   //       CacheImpl tc = new CacheImpl();
   //       tc.getConfiguration().setCacheMode("LOCAL");
   //       tc.start();
  
  
  
  1.7       +5 -5      JBossCache/tests/functional/org/jboss/cache/TreeCacheFunctionalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheFunctionalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/TreeCacheFunctionalTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- TreeCacheFunctionalTest.java	30 Dec 2006 17:49:54 -0000	1.6
  +++ TreeCacheFunctionalTest.java	30 Dec 2006 19:48:46 -0000	1.7
  @@ -13,7 +13,7 @@
    * Simple functional tests for CacheImpl
    *
    * @author Bela Ban
  - * @version $Id: TreeCacheFunctionalTest.java,v 1.6 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: TreeCacheFunctionalTest.java,v 1.7 2006/12/30 19:48:46 msurtani Exp $
    */
   public class TreeCacheFunctionalTest extends TestCase
   {
  @@ -53,8 +53,8 @@
   
      public void testPut() throws CacheException
      {
  -      cache.put("/a/b/c", "age", new Integer(38));
  -      assertEquals(cache.get("/a/b/c", "age"), new Integer(38));
  +      cache.put("/a/b/c", "age", 38);
  +      assertEquals(cache.get("/a/b/c", "age"), 38);
         assertNotNull(cache.get("/a/b/c"));
         assertEquals(0, cache.getNumberOfLocksHeld());
         assertEquals(0, cache.getLockTable().size());
  @@ -95,9 +95,9 @@
   
      public void testPutKeys() throws CacheException
      {
  -      cache.put("/a/b/c", "age", new Integer(38));
  +      cache.put("/a/b/c", "age", 38);
         cache.put("/a/b/c", "name", "Bela");
  -      assertEquals(cache.get("/a/b/c", "age"), new Integer(38));
  +      assertEquals(cache.get("/a/b/c", "age"), 38);
         assertNotNull(cache.get("/a/b/c"));
         assertEquals(cache.getKeys("/a/b/c").size(), 2);
         assertEquals(cache.exists("/a/b/c"), true);
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:46 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/mgmt ...
Message-ID: <E1H0kCE-0002Ks-RV@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:46

  Modified:    tests/functional/org/jboss/cache/mgmt      MgmtCoreTest.java
                        InvalidationTest.java TxTest.java
                        CacheLoaderTest.java PassivationTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.9       +19 -19    JBossCache/tests/functional/org/jboss/cache/mgmt/MgmtCoreTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MgmtCoreTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/MgmtCoreTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- MgmtCoreTest.java	30 Dec 2006 17:49:57 -0000	1.8
  +++ MgmtCoreTest.java	30 Dec 2006 19:48:46 -0000	1.9
  @@ -15,7 +15,7 @@
    * Simple functional tests for CacheMgmtInterceptor
    *
    * @author Jerry Gauthier
  - * @version $Id: MgmtCoreTest.java,v 1.8 2006/12/30 17:49:57 msurtani Exp $
  + * @version $Id: MgmtCoreTest.java,v 1.9 2006/12/30 19:48:46 msurtani Exp $
    */
   public class MgmtCoreTest extends TestCase
   {
  @@ -107,8 +107,8 @@
         assertEquals("Evictions count error: ", new Long(0), new Long(mgmt.getEvictions()));
         assertEquals("Hits count error: ", new Long(18), new Long(mgmt.getHits()));
         assertEquals("Misses count error: ", new Long(6), new Long(mgmt.getMisses()));
  -      assertEquals("HitMissRatio error: ", new Double(0.75), new Double(mgmt.getHitMissRatio()));
  -      assertEquals("ReadWriteRatio error: ", new Double(0.60), new Double(mgmt.getReadWriteRatio()));
  +      assertEquals("HitMissRatio error: ", 0.75, mgmt.getHitMissRatio());
  +      assertEquals("ReadWriteRatio error: ", 0.60, mgmt.getReadWriteRatio());
   
         // now evict some nodes (each node has 3 attributes)
         cache.evict(Fqn.fromString("Europe/Czech Republic"));
  @@ -178,41 +178,41 @@
         cache.put("Europe/Poland", CURRENCY, "Zloty");
         cache.put("Europe/Switzerland", CURRENCY, "Swiss Franc");
   
  -      cache.put("Europe/Austria", POPULATION, new Integer(8184691));
  -      cache.put("Europe/Czech Republic", POPULATION, new Integer(10241138));
  -      cache.put("Europe/England", POPULATION, new Integer(60441457));
  -      cache.put("Europe/France", POPULATION, new Integer(60656178));
  -      cache.put("Europe/Germany", POPULATION, new Integer(82431390));
  -      cache.put("Europe/Italy", POPULATION, new Integer(58103033));
  -      cache.put("Europe/Poland", POPULATION, new Integer(38635144));
  -      cache.put("Europe/Switzerland", POPULATION, new Integer(7489370));
  +      cache.put("Europe/Austria", POPULATION, 8184691);
  +      cache.put("Europe/Czech Republic", POPULATION, 10241138);
  +      cache.put("Europe/England", POPULATION, 60441457);
  +      cache.put("Europe/France", POPULATION, 60656178);
  +      cache.put("Europe/Germany", POPULATION, 82431390);
  +      cache.put("Europe/Italy", POPULATION, 58103033);
  +      cache.put("Europe/Poland", POPULATION, 38635144);
  +      cache.put("Europe/Switzerland", POPULATION, 7489370);
   
         HashMap albania = new HashMap(4);
         albania.put(CAPITAL, "Tirana");
         albania.put(CURRENCY, "Lek");
  -      albania.put(POPULATION, new Integer(3563112));
  -      albania.put(AREA, new Integer(28748));
  +      albania.put(POPULATION, 3563112);
  +      albania.put(AREA, 28748);
         cache.put("Europe/Albania", albania);
   
         HashMap hungary = new HashMap(4);
         hungary.put(CAPITAL, "Budapest");
         hungary.put(CURRENCY, "Forint");
  -      hungary.put(POPULATION, new Integer(10006835));
  -      hungary.put(AREA, new Integer(93030));
  +      hungary.put(POPULATION, 10006835);
  +      hungary.put(AREA, 93030);
         cache.put("Europe/Hungary", hungary);
   
         HashMap romania = new HashMap(4);
         romania.put(CAPITAL, "Bucharest");
         romania.put(CURRENCY, "Leu");
  -      romania.put(POPULATION, new Integer(22329977));
  -      romania.put(AREA, new Integer(237500));
  +      romania.put(POPULATION, 22329977);
  +      romania.put(AREA, 237500);
         cache.put("Europe/Romania", romania);
   
         HashMap slovakia = new HashMap(4);
         slovakia.put(CAPITAL, "Bratislava");
         slovakia.put(CURRENCY, "Slovak Koruna");
  -      slovakia.put(POPULATION, new Integer(5431363));
  -      slovakia.put(AREA, new Integer(48845));
  +      slovakia.put(POPULATION, 5431363);
  +      slovakia.put(AREA, 48845);
         cache.put("Europe/Slovakia", slovakia);
   
      }
  
  
  
  1.10      +7 -7      JBossCache/tests/functional/org/jboss/cache/mgmt/InvalidationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InvalidationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/InvalidationTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- InvalidationTest.java	30 Dec 2006 17:49:57 -0000	1.9
  +++ InvalidationTest.java	30 Dec 2006 19:48:46 -0000	1.10
  @@ -16,7 +16,7 @@
    * Simple functional tests for InvalidationInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: InvalidationTest.java,v 1.9 2006/12/30 17:49:57 msurtani Exp $
  + * @version $Id: InvalidationTest.java,v 1.10 2006/12/30 19:48:46 msurtani Exp $
    */
   public class InvalidationTest extends TestCase
   {
  @@ -115,13 +115,13 @@
         cache.put("Europe/Austria", new HashMap());
         cache.put("Europe/Austria", CAPITAL, "Vienna");
         cache.put("Europe/Austria", CURRENCY, "Euro");
  -      cache.put("Europe/Austria", POPULATION, new Integer(8184691));
  +      cache.put("Europe/Austria", POPULATION, 8184691);
   
         HashMap albania = new HashMap(4);
         albania.put(CAPITAL, "Tirana");
         albania.put(CURRENCY, "Lek");
  -      albania.put(POPULATION, new Integer(3563112));
  -      albania.put(AREA, new Integer(28748));
  +      albania.put(POPULATION, 3563112);
  +      albania.put(AREA, 28748);
         cache.put("Europe/Albania", albania);
   
      }
  @@ -132,13 +132,13 @@
         cache.put("Europe/Austria", new HashMap());
         cache.put("Europe/Austria", CAPITAL, "Vienna");
         cache.put("Europe/Austria", CURRENCY, "Euro");
  -      cache.put("Europe/Austria", POPULATION, new Integer(8184691));
  +      cache.put("Europe/Austria", POPULATION, 8184691);
   
         cache.put("Europe/Romania", new HashMap());
         cache.put("Europe/Romania", CAPITAL, "Bucharest");
         cache.put("Europe/Romania", CURRENCY, "Leu");
  -      cache.put("Europe/Romania", POPULATION, new Integer(22329977));
  -      cache.put("Europe/Romania", AREA, new Integer(237500));
  +      cache.put("Europe/Romania", POPULATION, 22329977);
  +      cache.put("Europe/Romania", AREA, 237500);
   
      }
   
  
  
  
  1.10      +12 -12    JBossCache/tests/functional/org/jboss/cache/mgmt/TxTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TxTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/TxTest.java,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- TxTest.java	30 Dec 2006 17:49:57 -0000	1.9
  +++ TxTest.java	30 Dec 2006 19:48:46 -0000	1.10
  @@ -17,7 +17,7 @@
    * Simple functional tests for TxInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: TxTest.java,v 1.9 2006/12/30 17:49:57 msurtani Exp $
  + * @version $Id: TxTest.java,v 1.10 2006/12/30 19:48:46 msurtani Exp $
    */
   public class TxTest extends TestCase
   {
  @@ -140,13 +140,13 @@
         cache.put("Europe/Austria", new HashMap());
         cache.put("Europe/Austria", CAPITAL, "Vienna");
         cache.put("Europe/Austria", CURRENCY, "Euro");
  -      cache.put("Europe/Austria", POPULATION, new Integer(8184691));
  +      cache.put("Europe/Austria", POPULATION, 8184691);
   
         HashMap albania = new HashMap(4);
         albania.put(CAPITAL, "Tirana");
         albania.put(CURRENCY, "Lek");
  -      albania.put(POPULATION, new Integer(3563112));
  -      albania.put(AREA, new Integer(28748));
  +      albania.put(POPULATION, 3563112);
  +      albania.put(AREA, 28748);
         cache.put("Europe/Albania", albania);
      }
   
  @@ -157,12 +157,12 @@
         cache.put("Europe/Czech Republic", new HashMap());
         cache.put("Europe/Czech Republic", CAPITAL, "Prague");
         cache.put("Europe/Czech Republic", CURRENCY, "Czech Koruna");
  -      cache.put("Europe/Czech Republic", POPULATION, new Integer(10241138));
  +      cache.put("Europe/Czech Republic", POPULATION, 10241138);
   
         cache.put("Europe/England", new HashMap());
         cache.put("Europe/England", CAPITAL, "London");
         cache.put("Europe/England", CURRENCY, "British Pound");
  -      cache.put("Europe/England", POPULATION, new Integer(60441457));
  +      cache.put("Europe/England", POPULATION, 60441457);
   
         tm.commit();
      }
  @@ -174,15 +174,15 @@
         HashMap hungary = new HashMap(4);
         hungary.put(CAPITAL, "Budapest");
         hungary.put(CURRENCY, "Forint");
  -      hungary.put(POPULATION, new Integer(10006835));
  -      hungary.put(AREA, new Integer(93030));
  +      hungary.put(POPULATION, 10006835);
  +      hungary.put(AREA, 93030);
         cache.put("Europe/Hungary", hungary);
   
         HashMap romania = new HashMap(4);
         romania.put(CAPITAL, "Bucharest");
         romania.put(CURRENCY, "Leu");
  -      romania.put(POPULATION, new Integer(22329977));
  -      romania.put(AREA, new Integer(237500));
  +      romania.put(POPULATION, 22329977);
  +      romania.put(AREA, 237500);
         cache.put("Europe/Romania", romania);
   
         tm.commit();
  @@ -195,12 +195,12 @@
         cache.put("Europe/France", new HashMap());
         cache.put("Europe/France", CAPITAL, "Paris");
         cache.put("Europe/France", CURRENCY, "Euro");
  -      cache.put("Europe/France", POPULATION, new Integer(60656178));
  +      cache.put("Europe/France", POPULATION, 60656178);
   
         cache.put("Europe/Germany", new HashMap());
         cache.put("Europe/Germany", CAPITAL, "Berlin");
         cache.put("Europe/Germany", CURRENCY, "Euro");
  -      cache.put("Europe/Germany", POPULATION, new Integer(82431390));
  +      cache.put("Europe/Germany", POPULATION, 82431390);
   
         tm.rollback();
      }
  
  
  
  1.11      +7 -7      JBossCache/tests/functional/org/jboss/cache/mgmt/CacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/CacheLoaderTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- CacheLoaderTest.java	30 Dec 2006 17:49:57 -0000	1.10
  +++ CacheLoaderTest.java	30 Dec 2006 19:48:46 -0000	1.11
  @@ -21,7 +21,7 @@
    * Simple functional tests for CacheLoaderInterceptor and CacheStoreInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: CacheLoaderTest.java,v 1.10 2006/12/30 17:49:57 msurtani Exp $
  + * @version $Id: CacheLoaderTest.java,v 1.11 2006/12/30 19:48:46 msurtani Exp $
    */
   public class CacheLoaderTest extends TestCase
   {
  @@ -177,25 +177,25 @@
         cache.put("Europe/Austria", new HashMap());
         cache.put("Europe/Austria", CAPITAL, "Vienna");
         cache.put("Europe/Austria", CURRENCY, "Euro");
  -      cache.put("Europe/Austria", POPULATION, new Integer(8184691));
  +      cache.put("Europe/Austria", POPULATION, 8184691);
   
         cache.put("Europe/England", new HashMap());
         cache.put("Europe/England", CAPITAL, "London");
         cache.put("Europe/England", CURRENCY, "British Pound");
  -      cache.put("Europe/England", POPULATION, new Integer(60441457));
  +      cache.put("Europe/England", POPULATION, 60441457);
   
         HashMap albania = new HashMap(4);
         albania.put(CAPITAL, "Tirana");
         albania.put(CURRENCY, "Lek");
  -      albania.put(POPULATION, new Integer(3563112));
  -      albania.put(AREA, new Integer(28748));
  +      albania.put(POPULATION, 3563112);
  +      albania.put(AREA, 28748);
         cache.put("Europe/Albania", albania);
   
         HashMap hungary = new HashMap(4);
         hungary.put(CAPITAL, "Budapest");
         hungary.put(CURRENCY, "Forint");
  -      hungary.put(POPULATION, new Integer(10006835));
  -      hungary.put(AREA, new Integer(93030));
  +      hungary.put(POPULATION, 10006835);
  +      hungary.put(AREA, 93030);
         cache.put("Europe/Hungary", hungary);
   
      }
  
  
  
  1.9       +7 -7      JBossCache/tests/functional/org/jboss/cache/mgmt/PassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/mgmt/PassivationTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- PassivationTest.java	30 Dec 2006 17:49:57 -0000	1.8
  +++ PassivationTest.java	30 Dec 2006 19:48:46 -0000	1.9
  @@ -21,7 +21,7 @@
    * Simple functional tests for ActivationInterceptor and PassivationInterceptor statistics
    *
    * @author Jerry Gauthier
  - * @version $Id: PassivationTest.java,v 1.8 2006/12/30 17:49:57 msurtani Exp $
  + * @version $Id: PassivationTest.java,v 1.9 2006/12/30 19:48:46 msurtani Exp $
    */
   public class PassivationTest extends TestCase
   {
  @@ -202,25 +202,25 @@
         cache.put("Europe/Austria", new HashMap());
         cache.put("Europe/Austria", CAPITAL, "Vienna");
         cache.put("Europe/Austria", CURRENCY, "Euro");
  -      cache.put("Europe/Austria", POPULATION, new Integer(8184691));
  +      cache.put("Europe/Austria", POPULATION, 8184691);
   
         cache.put("Europe/England", new HashMap());
         cache.put("Europe/England", CAPITAL, "London");
         cache.put("Europe/England", CURRENCY, "British Pound");
  -      cache.put("Europe/England", POPULATION, new Integer(60441457));
  +      cache.put("Europe/England", POPULATION, 60441457);
   
         HashMap albania = new HashMap(4);
         albania.put(CAPITAL, "Tirana");
         albania.put(CURRENCY, "Lek");
  -      albania.put(POPULATION, new Integer(3563112));
  -      albania.put(AREA, new Integer(28748));
  +      albania.put(POPULATION, 3563112);
  +      albania.put(AREA, 28748);
         cache.put("Europe/Albania", albania);
   
         HashMap hungary = new HashMap(4);
         hungary.put(CAPITAL, "Budapest");
         hungary.put(CURRENCY, "Forint");
  -      hungary.put(POPULATION, new Integer(10006835));
  -      hungary.put(AREA, new Integer(93030));
  +      hungary.put(POPULATION, 10006835);
  +      hungary.put(AREA, 93030);
         cache.put("Europe/Hungary", hungary);
      }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:46 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:46 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic     ...
Message-ID: <E1H0kCE-0002L8-Vm@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:46

  Modified:    src/org/jboss/cache/optimistic     WorkspaceNode.java
                        FqnComparator.java TransactionWorkspace.java
                        WorkspaceNodeImpl.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.19      +4 -4      JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNode.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- WorkspaceNode.java	30 Dec 2006 17:50:04 -0000	1.18
  +++ WorkspaceNode.java	30 Dec 2006 19:48:46 -0000	1.19
  @@ -23,21 +23,21 @@
    */
   public interface WorkspaceNode extends Node
   {
  -   public Map getMergedChildren();
  +   public Map<Object, NodeSPI> getMergedChildren();
   
      public DataVersion getVersion();
   
      public void setVersion(DataVersion version);
   
  -   public Set getKeys();
  +   public Set<Object> getKeys();
   
      public boolean isDirty();
   
  -   public Map getMergedData();
  +   public Map<Object, Object> getMergedData();
   
      public NodeSPI getNode();
   
  -   public Set getChildrenNames();
  +   public Set<Object> getChildrenNames();
   
      public TransactionWorkspace getTransactionWorkspace();
   
  
  
  
  1.7       +1 -1      JBossCache/src/org/jboss/cache/optimistic/FqnComparator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FqnComparator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/FqnComparator.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- FqnComparator.java	29 Dec 2006 14:46:59 -0000	1.6
  +++ FqnComparator.java	30 Dec 2006 19:48:46 -0000	1.7
  @@ -81,7 +81,7 @@
       * returns e1.compareTo(e2).
       * Otherwise, returns e1.toString().compareTo(e2.toString()).
       */
  -   protected int compareElements(Object e1, Object e2)
  +   private int compareElements(Object e1, Object e2)
      {
         if (e1.getClass() == e2.getClass() && e1 instanceof Comparable)
         {
  
  
  
  1.13      +1 -1      JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspace.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TransactionWorkspace.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/TransactionWorkspace.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- TransactionWorkspace.java	12 Dec 2006 14:51:44 -0000	1.12
  +++ TransactionWorkspace.java	30 Dec 2006 19:48:46 -0000	1.13
  @@ -49,7 +49,7 @@
      /**
       * Returns all nodes equal to or after the given node.
       */
  -   public SortedMap getNodesAfter(Fqn fqn);
  +   public SortedMap<Fqn, WorkspaceNode> getNodesAfter(Fqn fqn);
   
      /**
       * Tests if versioning is implicit for a given tx.
  
  
  
  1.34      +16 -21    JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- WorkspaceNodeImpl.java	30 Dec 2006 17:50:04 -0000	1.33
  +++ WorkspaceNodeImpl.java	30 Dec 2006 19:48:46 -0000	1.34
  @@ -42,7 +42,7 @@
      private boolean dirty;
      private boolean created;
      private Map<Object, NodeSPI> optimisticChildNodeMap;
  -   private Map optimisticDataMap;
  +   private Map<Object, Object> optimisticDataMap;
      private boolean versioningImplicit;
   
      /**
  @@ -56,12 +56,12 @@
         }
         this.node = node;
         this.workspace = workspace;
  -      optimisticDataMap = new HashMap(node.getRawData());
  -      Map childrenMap = node.getChildrenMap();
  +      optimisticDataMap = new HashMap<Object, Object>(node.getRawData());
  +      Map<Object, Node> childrenMap = node.getChildrenMap();
         if (childrenMap == null)
  -         optimisticChildNodeMap = new ConcurrentHashMap();
  +         optimisticChildNodeMap = new ConcurrentHashMap<Object, NodeSPI>();
         else
  -         optimisticChildNodeMap = new ConcurrentHashMap(node.getChildrenMap());
  +         optimisticChildNodeMap = new ConcurrentHashMap(childrenMap);
         this.version = node.getVersion();
         if (version == null)
         {
  @@ -82,13 +82,13 @@
         return node.getFqn();
      }
   
  -   public void put(Map data, boolean eraseData)
  +   public void put(Map<Object, Object> data, boolean eraseData)
      {
         realPut(data, eraseData);
         dirty = true;
      }
   
  -   public void put(Map data)
  +   public void put(Map<Object, Object> data)
      {
         realPut(data, false);
         dirty = true;
  @@ -119,23 +119,23 @@
         return optimisticDataMap.get(key);
      }
   
  -   public Set getKeys()
  +   public Set<Object> getKeys()
      {
         return optimisticDataMap.keySet();
      }
   
      //not able to delete from this
  -   public Set getChildrenNames()
  +   public Set<Object> getChildrenNames()
      {
  -      return new HashSet(optimisticChildNodeMap.keySet());
  +      return new HashSet<Object>(optimisticChildNodeMap.keySet());
      }
   
  -   private void realPut(Map data, boolean eraseData)
  +   private void realPut(Map<Object, Object> data, boolean eraseData)
      {
         realPut(data, eraseData, true);
      }
   
  -   private void realPut(Map data, boolean eraseData, boolean forceDirtyFlag)
  +   private void realPut(Map<Object, Object> data, boolean eraseData, boolean forceDirtyFlag)
      {
         if (forceDirtyFlag) dirty = true;
         if (eraseData)
  @@ -256,7 +256,7 @@
         this.version = version;
      }
   
  -   public Map getMergedChildren()
  +   public Map<Object, NodeSPI> getMergedChildren()
      {
         //return mergeMaps((OptimisticMap) optimisticChildNodeMap);
         return optimisticChildNodeMap;
  @@ -282,7 +282,7 @@
      //        return opMap.getLocalMap();
      //    }
   
  -   public Map getMergedData()
  +   public Map<Object, Object> getMergedData()
      {
         return optimisticDataMap;
      }
  @@ -308,16 +308,11 @@
         dirty = true;
      }
   
  -   public Map getData()
  +   public Map<Object, Object> getData()
      {
         return Collections.unmodifiableMap(optimisticDataMap);
      }
   
  -   public Map getChildrenMap()
  -   {
  -      return Collections.unmodifiableMap(optimisticChildNodeMap);
  -   }
  -
      public boolean containsKey(Object key)
      {
         return optimisticDataMap.containsKey(key);
  @@ -426,7 +421,7 @@
   
      }
   
  -   public void putIfNull(Map m)
  +   public void putIfNull(Map<Object, Object> m)
      {
         throw new UnsupportedOperationException();
         // TODO Auto-generated method stub
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/replicated ...
Message-ID: <E1H0kCF-0002LF-3N@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    tests/functional/org/jboss/cache/replicated 
                        AsyncReplTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.13      +8 -8      JBossCache/tests/functional/org/jboss/cache/replicated/AsyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AsyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/replicated/AsyncReplTest.java,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -b -r1.12 -r1.13
  --- AsyncReplTest.java	30 Dec 2006 17:50:05 -0000	1.12
  +++ AsyncReplTest.java	30 Dec 2006 19:48:47 -0000	1.13
  @@ -24,7 +24,7 @@
    * Unit test for replicated async CacheImpl. Use locking and multiple threads to test
    * concurrent access to the tree.
    *
  - * @version $Revision: 1.12 $
  + * @version $Revision: 1.13 $
    */
   public class AsyncReplTest extends TestCase
   {
  @@ -134,7 +134,7 @@
         try
         {
            cache3 = createCache("DifferentGroup");
  -         cache1.put("/a/b/c", "age", new Integer(38));
  +         cache1.put("/a/b/c", "age", 38);
            // because we use async repl, modfication may not yet have been propagated to cache2, so
            // we have to wait a little
            TestingUtil.sleepThread((long) 1000);
  @@ -158,11 +158,11 @@
         CacheImpl cache4 = null;
         try
         {
  -         cache1.put("a/b/c", "age", new Integer(38));
  +         cache1.put("a/b/c", "age", 38);
            cache4 = createCache("CacheGroup");
            System.out.println("" + cache4.getMembers());
            assertEquals(3, cache4.getMembers().size()); // cache1, cache2 and cache4
  -         assertEquals("\"age\" should be 38", new Integer(38), cache4.get("/a/b/c", "age"));
  +         assertEquals("\"age\" should be 38", 38, cache4.get("/a/b/c", "age"));
         }
         catch (Exception e)
         {
  @@ -185,12 +185,12 @@
   
         try
         {
  -         cache1.put("/a/b/c", "age", new Integer(38));
  +         cache1.put("/a/b/c", "age", 38);
   
            // value on cache2 may be 38 or not yet replicated
            age = (Integer) cache2.get("/a/b/c", "age");
            log("attr \"age\" of \"/a/b/c\" on cache2=" + age);
  -         assertTrue("should be either null or 38", age == null || age.intValue() == 38);
  +         assertTrue("should be either null or 38", age == null || age == 38);
         }
         catch (Exception e)
         {
  @@ -206,13 +206,13 @@
         {
            TransactionManager tm = cache1.getTransactionManager();
            tm.begin();
  -         cache1.put("/a/b/c", "age", new Integer(38));
  +         cache1.put("/a/b/c", "age", 38);
            tm.commit();
   
            // value on cache2 may be 38 or not yet replicated
            age = (Integer) cache2.get("/a/b/c", "age");
            log("attr \"age\" of \"/a/b/c\" on cache2=" + age);
  -         assertTrue("should be either null or 38", age == null || age.intValue() == 38);
  +         assertTrue("should be either null or 38", age == null || age == 38);
         }
         catch (Exception e)
         {
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/passivation
	...
Message-ID: <E1H0kCF-0002LS-9b@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    tests/functional/org/jboss/cache/passivation   
                        ConcurrentPassivationTest.java
                        PassivationTestsBase.java
                        PassivationToFileCacheLoaderTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.9       +4 -4      JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentPassivationTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ConcurrentPassivationTest.java	30 Dec 2006 17:49:59 -0000	1.8
  +++ ConcurrentPassivationTest.java	30 Dec 2006 19:48:47 -0000	1.9
  @@ -21,7 +21,7 @@
    * Tests cache behavior in the presence of concurrent passivation.
    *
    * @author Brian Stansberry
  - * @version $Revision: 1.8 $
  + * @version $Revision: 1.9 $
    */
   public class ConcurrentPassivationTest extends TestCase
   {
  @@ -80,7 +80,7 @@
         // region's maxNodes so we know eviction will kick in
         for (int i = 0; i < 35000; i++)
         {
  -         cache_.put(new Fqn(base, new Integer(i / 100)), new Integer(i), "value");
  +         cache_.put(new Fqn(base, i / 100), new Integer(i), "value");
         }
   
         // Loop for long enough to have 5 runs of the eviction thread
  @@ -90,8 +90,8 @@
            // If any get returns null, that's a failure
            for (int i = 0; i < 35000; i++)
            {
  -            Fqn fqn = new Fqn(base, new Integer(i / 100));
  -            Integer key = new Integer(i);
  +            Fqn fqn = new Fqn(base, i / 100);
  +            Integer key = i;
               assertNotNull("found value under Fqn " + fqn + " and key " + key,
                       cache_.get(fqn, key));
            }
  
  
  
  1.23      +25 -25    JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationTestsBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- PassivationTestsBase.java	30 Dec 2006 17:49:59 -0000	1.22
  +++ PassivationTestsBase.java	30 Dec 2006 19:48:47 -0000	1.23
  @@ -38,7 +38,7 @@
    * Base tests for passivation using any of the cache loaders
    *
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationTestsBase.java,v 1.22 2006/12/30 17:49:59 msurtani Exp $
  + * @version $Id: PassivationTestsBase.java,v 1.23 2006/12/30 19:48:47 msurtani Exp $
    */
   abstract public class PassivationTestsBase extends TestCase
   {
  @@ -138,17 +138,17 @@
         Object retval = null;
         cache.remove(NODE); // nothing to remove
         addDelay();
  -      retval = cache.put(NODE, KEY, new Integer(10)); // put in memory
  +      retval = cache.put(NODE, KEY, 10); // put in memory
         assertNull(retval);
  -      retval = cache.put(NODE, KEY, new Integer(20)); // put in memory
  +      retval = cache.put(NODE, KEY, 20); // put in memory
         addDelay();
  -      assertEquals(new Integer(10), retval); // get from memory
  +      assertEquals(10, retval); // get from memory
         cache.evict(Fqn.fromString(NODE)); // passivate node
         addDelay();
         log.debug("______________");
  -      retval = cache.put(NODE, KEY, new Integer(30)); // activate node then does put in memory
  +      retval = cache.put(NODE, KEY, 30); // activate node then does put in memory
         assertFalse(loader.exists(Fqn.fromString(NODE)));
  -      assertEquals(new Integer(20), retval);
  +      assertEquals(20, retval);
      }
   
      public void testPut2Passivation() throws CacheException
  @@ -158,11 +158,11 @@
         Object retval = null;
         cache.remove(NODE); // nothing to remove
         addDelay();
  -      retval = cache.put(NODE, KEY, new Integer(10)); // put in memory
  +      retval = cache.put(NODE, KEY, 10); // put in memory
         assertNull(retval);
         addDelay();
  -      retval = cache.put(NODE, KEY, new Integer(20)); // put in memory
  -      assertEquals(new Integer(10), retval);
  +      retval = cache.put(NODE, KEY, 20); // put in memory
  +      assertEquals(10, retval);
         cache.evict(Fqn.fromString(NODE)); // passivate node
         cache.evict(Fqn.fromString("/a/b")); // passivate parent node
         cache.evict(Fqn.fromString("/a")); // passivate parent node
  @@ -175,7 +175,7 @@
         {
            fail(e.toString());
         }
  -      retval = cache.put(NODE, KEY, new Integer(30)); // activate node, put in memory new value
  +      retval = cache.put(NODE, KEY, 30); // activate node, put in memory new value
         try
         {
            assertFalse(loader.exists(Fqn.fromString(NODE)));
  @@ -184,7 +184,7 @@
         {
            fail(e.toString());
         }
  -      assertEquals(new Integer(20), retval);
  +      assertEquals(20, retval);
      }
   
   
  @@ -194,9 +194,9 @@
         pojo.getHobbies().add("Running");
         pojo.getHobbies().add("Beerathlon");
         pojo.getHobbies().add("Triathlon");
  -      cache.put("/mypojo", new Integer(322649), pojo); // put in memory
  +      cache.put("/mypojo", 322649, pojo); // put in memory
         addDelay();
  -      assertNotNull(cache.get("/mypojo", new Integer(322649))); // get from memory
  +      assertNotNull(cache.get("/mypojo", 322649)); // get from memory
         cache.evict(Fqn.fromString("/mypojo")); // passivate node
         try
         {
  @@ -206,7 +206,7 @@
         {
            fail(e.toString());
         }
  -      SamplePojo pojo2 = (SamplePojo) cache.get("/mypojo", new Integer(322649)); // activate node
  +      SamplePojo pojo2 = (SamplePojo) cache.get("/mypojo", 322649); // activate node
         try
         {
            assertFalse(loader.exists(Fqn.fromString("/mypojo")));
  @@ -676,11 +676,11 @@
         final String KEY = "key";
         Object retval = null;
         cache.remove(NODE);
  -      retval = cache.put(NODE, KEY, new Integer(10));
  +      retval = cache.put(NODE, KEY, 10);
         assertNull(retval);
         addDelay();
         retval = cache.remove(NODE, KEY);
  -      assertEquals(new Integer(10), retval);
  +      assertEquals(10, retval);
         addDelay();
         retval = cache.remove(NODE, KEY);
         assertNull(retval);
  @@ -692,15 +692,15 @@
         final String KEY = "key";
         Object retval = null;
         cache.remove(NODE);
  -      retval = cache.put(NODE, KEY, new Integer(10));
  +      retval = cache.put(NODE, KEY, 10);
         assertNull(retval);
   
         cache.evict(Fqn.fromString(NODE)); // passivate node
         addDelay();
         assertTrue(loader.exists(Fqn.fromString(NODE)));
  -      assertEquals(new Integer(10), loader.get(Fqn.fromString(NODE)).get(KEY));
  +      assertEquals(10, loader.get(Fqn.fromString(NODE)).get(KEY));
         retval = cache.remove(NODE, KEY); // activate node
  -      assertEquals(new Integer(10), retval);
  +      assertEquals(10, retval);
         assertFalse(loader.exists(Fqn.fromString(NODE)));
   
         cache.evict(Fqn.fromString(NODE)); // passiave node
  @@ -1557,11 +1557,11 @@
         Complex c2 = new Complex(c1);
   
         /* Add objects. */
  -      loader.put(FQN, new Integer(1), c1);
  -      loader.put(FQN, new Integer(2), c2);
  +      loader.put(FQN, 1, c1);
  +      loader.put(FQN, 2, c2);
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
   
         /* Save state. */
  @@ -1581,8 +1581,8 @@
         is.close();
   
         addDelay();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
      }
   
  
  
  
  1.8       +38 -32    JBossCache/tests/functional/org/jboss/cache/passivation/PassivationToFileCacheLoaderTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PassivationToFileCacheLoaderTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/passivation/PassivationToFileCacheLoaderTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- PassivationToFileCacheLoaderTest.java	25 Oct 2006 04:50:20 -0000	1.7
  +++ PassivationToFileCacheLoaderTest.java	30 Dec 2006 19:48:47 -0000	1.8
  @@ -2,7 +2,6 @@
   
   import junit.framework.Test;
   import junit.framework.TestSuite;
  -
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.xml.XmlHelper;
  @@ -12,19 +11,24 @@
    * tests passivation using file cache loader
    * 
    * @author <a href="mailto:{hmesha at novell.com}">{Hany Mesha}</a>
  - * @version $Id: PassivationToFileCacheLoaderTest.java,v 1.7 2006/10/25 04:50:20 bstansberry Exp $
  + * @version $Id: PassivationToFileCacheLoaderTest.java,v 1.8 2006/12/30 19:48:47 msurtani Exp $
    */
  -public class PassivationToFileCacheLoaderTest extends PassivationTestsBase {
  +public class PassivationToFileCacheLoaderTest extends PassivationTestsBase
  +{
   
   
  -   protected void configureCache() throws Exception {
  +   protected void configureCache() throws Exception
  +   {
   
         String tmp_location = null;
         String OS = System.getProperty("os.name").toLowerCase();
  -      if(OS.indexOf("win") > -1 || OS.indexOf("nt") > -1) {
  -         tmp_location=System.getProperty("java.io.tmpdir", "c:\\tmp");
  -      } else {
  -         tmp_location=System.getProperty("jva.io.tmpdir", "/tmp");
  +      if (OS.contains("win") || OS.contains("nt"))
  +      {
  +         tmp_location = System.getProperty("java.io.tmpdir", "c:\\tmp");
  +      }
  +      else
  +      {
  +         tmp_location = System.getProperty("jva.io.tmpdir", "/tmp");
         }
   
          cache.getConfiguration().setCacheLoaderConfig(getCacheLoaderConfig(tmp_location));
  @@ -52,12 +56,14 @@
       }
   
   
  -   public static Test suite() {
  +   public static Test suite()
  +   {
         return new TestSuite(PassivationToFileCacheLoaderTest.class);
      }
   
   
  -   public static void main(String[] args) {
  +   public static void main(String[] args)
  +   {
         junit.textui.TestRunner.run(suite());
      }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/jdbm  ...
Message-ID: <E1H0kCF-0002LZ-DY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    src/org/jboss/cache/loader/jdbm  JdbmCacheLoader.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.20      +8 -8      JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JdbmCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java,v
  retrieving revision 1.19
  retrieving revision 1.20
  diff -u -b -r1.19 -r1.20
  --- JdbmCacheLoader.java	30 Dec 2006 17:50:06 -0000	1.19
  +++ JdbmCacheLoader.java	30 Dec 2006 19:48:47 -0000	1.20
  @@ -55,7 +55,7 @@
    * plans to fix this.
    *
    * @author Elias Ross
  - * @version $Id: JdbmCacheLoader.java,v 1.19 2006/12/30 17:50:06 msurtani Exp $
  + * @version $Id: JdbmCacheLoader.java,v 1.20 2006/12/30 19:48:47 msurtani Exp $
    */
   public class JdbmCacheLoader extends AbstractCacheLoader
   {
  @@ -69,7 +69,7 @@
      private String cacheDbName;
      private RecordManager recman;
      private BTree tree;
  -   private Map transactions = new ConcurrentHashMap();
  +   private Map<Object, List<Modification>> transactions = new ConcurrentHashMap<Object, List<Modification>>();
   
      /*
       * Service implementation -- lifecycle methods.
  @@ -258,7 +258,7 @@
       * browser applications.  Calling this method as part of a run-time
       * transaction is not recommended.
       */
  -   public Set getChildrenNames(Fqn name)
  +   public Set<String> getChildrenNames(Fqn name)
              throws Exception
      {
   
  @@ -273,7 +273,7 @@
         }
      }
   
  -   private Set getChildrenNames0(Fqn name) throws IOException
  +   private Set<String> getChildrenNames0(Fqn name) throws IOException
      {
         TupleBrowser browser = tree.browse(name);
         Tuple t = new Tuple();
  @@ -292,7 +292,7 @@
            return null;
         }
   
  -      Set set = new HashSet();
  +      Set<String> set = new HashSet<String>();
   
         // Want only /a/b/c/X nodes
         int depth = name.size() + 1;
  @@ -306,7 +306,7 @@
            }
            if (size == depth && t.getValue().equals(NODE))
            {
  -            set.add(fqn.getLast());
  +            set.add((String) fqn.getLast());
            }
         }
   
  @@ -594,7 +594,7 @@
      /**
       * Applies and commits the given modifications in one transaction.
       */
  -   public void prepare(Object tx, List modifications, boolean onePhase)
  +   public void prepare(Object tx, List<Modification> modifications, boolean onePhase)
              throws Exception
      {
         if (onePhase)
  @@ -612,7 +612,7 @@
       */
      public void commit(Object tx) throws Exception
      {
  -      List modifications = (List) transactions.remove(tx);
  +      List<Modification> modifications = transactions.remove(tx);
         if (modifications == null)
         {
            throw new IllegalStateException("transaction " + tx + " not found in transaction table");
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/factories  ...
Message-ID: <E1H0kCF-0002Lg-HP@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    src/org/jboss/cache/factories  InterceptorChainFactory.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.36      +12 -12    JBossCache/src/org/jboss/cache/factories/InterceptorChainFactory.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: InterceptorChainFactory.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/factories/InterceptorChainFactory.java,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -b -r1.35 -r1.36
  --- InterceptorChainFactory.java	30 Dec 2006 17:49:57 -0000	1.35
  +++ InterceptorChainFactory.java	30 Dec 2006 19:48:47 -0000	1.36
  @@ -52,13 +52,13 @@
   
      private Interceptor createInterceptor(String classname, CacheSPI cache) throws ClassNotFoundException, IllegalAccessException, InstantiationException
      {
  -      Class clazz = Util.loadClass(classname);
  +      Class<Interceptor> clazz = Util.loadClass(classname);
         return createInterceptor(clazz, cache);
      }
   
  -   private Interceptor createInterceptor(Class clazz, CacheSPI cache) throws IllegalAccessException, InstantiationException
  +   private Interceptor createInterceptor(Class<? extends Interceptor> clazz, CacheSPI cache) throws IllegalAccessException, InstantiationException
      {
  -      Interceptor i = (Interceptor) clazz.newInstance();
  +      Interceptor i = clazz.newInstance();
         i.setCache(cache);
         i.setStatisticsEnabled(cache.getConfiguration().getExposeManagementStatistics());
         return i;
  @@ -125,17 +125,17 @@
       */
      private Interceptor createPessimisticInterceptorChain(CacheImpl cache) throws IllegalAccessException, InstantiationException, ClassNotFoundException
      {
  -      Interceptor call_interceptor = null;
  -      Interceptor lock_interceptor = null;
  +      Interceptor call_interceptor;
  +      Interceptor lock_interceptor;
         Interceptor repl_interceptor = null;
         Interceptor cache_loader_interceptor = null;
         Interceptor cache_store_interceptor = null;
  -      Interceptor unlock_interceptor = null;
  +      Interceptor unlock_interceptor;
         Interceptor passivation_interceptor = null;
         Interceptor activation_interceptor = null;
  -      Interceptor cacheMgmtInterceptor = null;
  -      Interceptor txInterceptor = null;
  -      Interceptor eviction_interceptor = null;
  +      Interceptor cacheMgmtInterceptor;
  +      Interceptor txInterceptor;
  +      Interceptor eviction_interceptor;
         Interceptor dataGravitatorInterceptor = null;
         Interceptor invocationCtxInterceptor = createInterceptor(InvocationContextInterceptor.class, cache);
         Interceptor first = null;
  @@ -389,10 +389,10 @@
   
      private Interceptor createOptimisticInterceptorChain(CacheImpl cache) throws IllegalAccessException, InstantiationException, ClassNotFoundException
      {
  -      Interceptor txInterceptor = null, replicationInterceptor = null, lockInterceptor = null, validationInterceptor = null;
  -      Interceptor createIfNotExistsInterceptor = null, nodeInterceptor = null, invokerInterceptor = null, activationInterceptor = null;
  +      Interceptor txInterceptor, replicationInterceptor = null, lockInterceptor, validationInterceptor;
  +      Interceptor createIfNotExistsInterceptor, nodeInterceptor, invokerInterceptor, activationInterceptor = null;
         Interceptor passivationInterceptor = null, cacheLoaderInterceptor = null, cacheStoreInterceptor = null, first = null;
  -      Interceptor cacheMgmtInterceptor = null, evictionInterceptor = null, dataGravitatorInterceptor = null;
  +      Interceptor cacheMgmtInterceptor, evictionInterceptor = null, dataGravitatorInterceptor = null;
         Interceptor invocationCtxInterceptor = createInterceptor(InvocationContextInterceptor.class, cache);
   
         CacheLoaderManager cacheLoaderManager = cache.getCacheLoaderManager();
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader  ...
Message-ID: <E1H0kCF-0002Ln-M9@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    tests/functional/org/jboss/cache/loader  BdbjeTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.16      +7 -7      JBossCache/tests/functional/org/jboss/cache/loader/BdbjeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BdbjeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/BdbjeTest.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- BdbjeTest.java	30 Dec 2006 17:49:57 -0000	1.15
  +++ BdbjeTest.java	30 Dec 2006 19:48:47 -0000	1.16
  @@ -35,7 +35,7 @@
    * directory.  Any scratch directory will do, but beware that all files in
    * the directory will be deleted by setUp().</p>
    *
  - * @version $Revision: 1.15 $
  + * @version $Revision: 1.16 $
    */
   public class BdbjeTest extends TestCase
   {
  @@ -1301,10 +1301,10 @@
         Complex c2 = new Complex(c1);
   
         /* Add objects. */
  -      loader.put(FQN, new Integer(1), c1);
  -      loader.put(FQN, new Integer(2), c2);
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      loader.put(FQN, 1, c1);
  +      loader.put(FQN, 2, c2);
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
   
         /* Save state. */
  @@ -1334,8 +1334,8 @@
         is = new MarshalledValueInputStream(bais);
         loader.storeEntireState(is);
         is.close();
  -      assertEquals(c1, loader.get(FQN).get(new Integer(1)));
  -      assertEquals(c2, loader.get(FQN).get(new Integer(2)));
  +      assertEquals(c1, loader.get(FQN).get(1));
  +      assertEquals(c2, loader.get(FQN).get(2));
         assertEquals(2, loader.get(FQN).size());
   
         stopLoader();
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/transaction   ...
Message-ID: <E1H0kCF-0002Lx-R5@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    src/org/jboss/cache/transaction   DummyUserTransaction.java
                        DummyBaseTransactionManager.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.5       +33 -18    JBossCache/src/org/jboss/cache/transaction/DummyUserTransaction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DummyUserTransaction.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/transaction/DummyUserTransaction.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- DummyUserTransaction.java	20 Feb 2006 19:34:46 -0000	1.4
  +++ DummyUserTransaction.java	30 Dec 2006 19:48:47 -0000	1.5
  @@ -3,29 +3,38 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   
  -import javax.transaction.*;
  +import javax.transaction.HeuristicMixedException;
  +import javax.transaction.HeuristicRollbackException;
  +import javax.transaction.NotSupportedException;
  +import javax.transaction.RollbackException;
  +import javax.transaction.Status;
  +import javax.transaction.Synchronization;
  +import javax.transaction.SystemException;
  +import javax.transaction.UserTransaction;
   import java.util.ArrayList;
   import java.util.List;
   
   /**
    * @author bela
  - * @version $Revision: 1.4 $
  + * @version $Revision: 1.5 $
    *          Date: May 15, 2003
    *          Time: 4:20:17 PM
    */
  -public class DummyUserTransaction implements UserTransaction, java.io.Serializable {
  -   int status=Status.STATUS_UNKNOWN;
  -   static final Log logger_=LogFactory.getLog(DummyUserTransaction.class);
  +public class DummyUserTransaction implements UserTransaction, java.io.Serializable
  +{
  +   int status = Status.STATUS_UNKNOWN;
  +   static final Log logger_ = LogFactory.getLog(DummyUserTransaction.class);
      DummyTransactionManager tm_;
      private static final long serialVersionUID = -6568400755677046127L;         
   
      /**
       * List<Synchronization>
       */
  -   List l=new ArrayList();
  +   List<Synchronization> l = new ArrayList<Synchronization>();
   
  -   public DummyUserTransaction(DummyTransactionManager tm) {
  -      tm_=tm;
  +   public DummyUserTransaction(DummyTransactionManager tm)
  +   {
  +      tm_ = tm;
      }
   
   
  @@ -38,9 +47,10 @@
       * @throws SystemException       If the transaction service fails in an
       *                               unexpected way.
       */
  -   public void begin() throws NotSupportedException, SystemException {
  +   public void begin() throws NotSupportedException, SystemException
  +   {
         tm_.begin();
  -      status=Status.STATUS_ACTIVE;
  +      status = Status.STATUS_ACTIVE;
      }
   
      /**
  @@ -61,10 +71,11 @@
       */
      public void commit()
              throws RollbackException, HeuristicMixedException,
  -           HeuristicRollbackException, SecurityException, SystemException {
  +           HeuristicRollbackException, SecurityException, SystemException
  +   {
   
         tm_.commit();
  -      status=Status.STATUS_COMMITTED;
  +      status = Status.STATUS_COMMITTED;
      }
   
      /**
  @@ -77,9 +88,10 @@
       * @throws SystemException       If the transaction service fails in an
       *                               unexpected way.
       */
  -   public void rollback() throws IllegalStateException, SystemException {
  +   public void rollback() throws IllegalStateException, SystemException
  +   {
         tm_.rollback();
  -      status=Status.STATUS_ROLLEDBACK;
  +      status = Status.STATUS_ROLLEDBACK;
      }
   
      /**
  @@ -90,7 +102,8 @@
       * @throws SystemException       If the transaction service fails in an
       *                               unexpected way.
       */
  -   public void setRollbackOnly() throws IllegalStateException, SystemException {
  +   public void setRollbackOnly() throws IllegalStateException, SystemException
  +   {
         tm_.setRollbackOnly();
      }
   
  @@ -102,7 +115,8 @@
       * @throws SystemException If the transaction service fails in an
       *                         unexpected way.
       */
  -   public int getStatus() throws SystemException {
  +   public int getStatus() throws SystemException
  +   {
         return tm_.getStatus();
      }
   
  @@ -116,7 +130,8 @@
       * @throws SystemException If the transaction service fails in an
       *                         unexpected way.
       */
  -   public void setTransactionTimeout(int seconds) throws SystemException {
  +   public void setTransactionTimeout(int seconds) throws SystemException
  +   {
         throw new SystemException("not supported");
      }
   
  
  
  
  1.4       +101 -67   JBossCache/src/org/jboss/cache/transaction/DummyBaseTransactionManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DummyBaseTransactionManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/transaction/DummyBaseTransactionManager.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- DummyBaseTransactionManager.java	9 Mar 2006 23:11:05 -0000	1.3
  +++ DummyBaseTransactionManager.java	30 Dec 2006 19:48:47 -0000	1.4
  @@ -1,62 +1,79 @@
   package org.jboss.cache.transaction;
   
  -import javax.transaction.*;
  +import javax.transaction.HeuristicMixedException;
  +import javax.transaction.HeuristicRollbackException;
  +import javax.transaction.InvalidTransactionException;
  +import javax.transaction.NotSupportedException;
  +import javax.transaction.RollbackException;
  +import javax.transaction.Status;
  +import javax.transaction.SystemException;
  +import javax.transaction.Transaction;
  +import javax.transaction.TransactionManager;
   
   /**
    * @author bela
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    *          Date: May 15, 2003
    *          Time: 4:11:37 PM
    */
  -public class DummyBaseTransactionManager implements TransactionManager, java.io.Serializable {
  -   static ThreadLocal thread_local=new ThreadLocal();
  +public class DummyBaseTransactionManager implements TransactionManager, java.io.Serializable
  +{
  +   static ThreadLocal<Transaction> thread_local = new ThreadLocal<Transaction>();
       private static final long serialVersionUID = -6716097342564237376l;
   
      /**
       * Starts a new transaction, and associate it with the calling thread.
       *
  -    * @throws javax.transaction.NotSupportedException If the calling thread is already
  +    * @throws javax.transaction.NotSupportedException
  +    *          If the calling thread is already
       *                               associated with a transaction, and nested transactions are
       *                               not supported.
  -    * @throws javax.transaction.SystemException       If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *          If the transaction service fails in an
       *                               unexpected way.
       */
  -   public void begin() throws NotSupportedException, SystemException {
  +   public void begin() throws NotSupportedException, SystemException
  +   {
         Transaction currentTx;
  -      if((currentTx=getTransaction()) != null)
  +      if ((currentTx = getTransaction()) != null)
            throw new NotSupportedException(Thread.currentThread() +
                                            " is already associated with a transaction (" + currentTx + ")");
  -      DummyTransaction tx=new DummyTransaction(this);
  +      DummyTransaction tx = new DummyTransaction(this);
         setTransaction(tx);
      }
   
      /**
       * Commit the transaction associated with the calling thread.
       *
  -    * @throws javax.transaction.RollbackException          If the transaction was marked for rollback
  +    * @throws javax.transaction.RollbackException
  +    *                               If the transaction was marked for rollback
       *                                    only, the transaction is rolled back and this exception is
       *                                    thrown.
       * @throws IllegalStateException      If the calling thread is not associated
       *                                    with a transaction.
  -    * @throws javax.transaction.SystemException            If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *                               If the transaction service fails in an
       *                                    unexpected way.
  -    * @throws javax.transaction.HeuristicMixedException    If a heuristic decision was made and
  +    * @throws javax.transaction.HeuristicMixedException
  +    *                               If a heuristic decision was made and
       *                                    some some parts of the transaction have been committed while
       *                                    other parts have been rolled back.
  -    * @throws javax.transaction.HeuristicRollbackException If a heuristic decision to roll
  +    * @throws javax.transaction.HeuristicRollbackException
  +    *                               If a heuristic decision to roll
       *                                    back the transaction was made.
       * @throws SecurityException          If the caller is not allowed to commit this
       *                                    transaction.
       */
      public void commit() throws RollbackException, HeuristicMixedException,
              HeuristicRollbackException, SecurityException,
  -           IllegalStateException, SystemException {
  +           IllegalStateException, SystemException
  +   {
         int status;
  -      Transaction tx=getTransaction();
  -      if(tx == null)
  +      Transaction tx = getTransaction();
  +      if (tx == null)
            throw new IllegalStateException("thread not associated with transaction");
  -      status=tx.getStatus();
  -      if(status == Status.STATUS_MARKED_ROLLBACK)
  +      status = tx.getStatus();
  +      if (status == Status.STATUS_MARKED_ROLLBACK)
            throw new RollbackException();
         tx.commit();
   
  @@ -74,13 +91,15 @@
       *                               {@link javax.transaction.Status#STATUS_PREPARED prepared state}.
       * @throws SecurityException     If the caller is not allowed to roll back
       *                               this transaction.
  -    * @throws javax.transaction.SystemException       If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *                               If the transaction service fails in an
       *                               unexpected way.
       */
      public void rollback() throws IllegalStateException, SecurityException,
  -           SystemException {
  -      Transaction tx=getTransaction();
  -      if(tx == null)
  +           SystemException
  +   {
  +      Transaction tx = getTransaction();
  +      if (tx == null)
            throw new IllegalStateException("no transaction associated with thread");
         tx.rollback();
   
  @@ -97,12 +116,14 @@
       *                               calling thread is not associated with a transaction, or
       *                               because it is in the
       *                               {@link javax.transaction.Status#STATUS_PREPARED prepared state}.
  -    * @throws javax.transaction.SystemException       If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *                               If the transaction service fails in an
       *                               unexpected way.
       */
  -   public void setRollbackOnly() throws IllegalStateException, SystemException {
  -      Transaction tx=getTransaction();
  -      if(tx == null)
  +   public void setRollbackOnly() throws IllegalStateException, SystemException
  +   {
  +      Transaction tx = getTransaction();
  +      if (tx == null)
            throw new IllegalStateException("no transaction associated with calling thread");
         tx.setRollbackOnly();
      }
  @@ -114,11 +135,13 @@
       *         {@link javax.transaction.Status} constants. If no transaction is associated
       *         with the calling thread,
       *         {@link javax.transaction.Status#STATUS_NO_TRANSACTION} is returned.
  -    * @throws javax.transaction.SystemException If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *          If the transaction service fails in an
       *                         unexpected way.
       */
  -   public int getStatus() throws SystemException {
  -      Transaction tx=getTransaction();
  +   public int getStatus() throws SystemException
  +   {
  +      Transaction tx = getTransaction();
         return tx != null ? tx.getStatus() : Status.STATUS_NO_TRANSACTION;
      }
   
  @@ -128,11 +151,13 @@
       * @return The transaction associated with the calling thread, or
       *         <code>null</code> if the calling thread is not associated
       *         with a transaction.
  -    * @throws javax.transaction.SystemException If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *          If the transaction service fails in an
       *                         unexpected way.
       */
  -   public Transaction getTransaction() throws SystemException {
  -      return (Transaction)thread_local.get();
  +   public Transaction getTransaction() throws SystemException
  +   {
  +      return thread_local.get();
      }
   
      /**
  @@ -142,10 +167,12 @@
       * @param seconds The new timeout value, in seconds. If this parameter
       *                is <code>0</code>, the timeout value is reset to the default
       *                value.
  -    * @throws javax.transaction.SystemException If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *          If the transaction service fails in an
       *                         unexpected way.
       */
  -   public void setTransactionTimeout(int seconds) throws SystemException {
  +   public void setTransactionTimeout(int seconds) throws SystemException
  +   {
         throw new SystemException("not supported");
      }
   
  @@ -158,11 +185,13 @@
       * @return The transaction that the calling thread was associated with,
       *         or <code>null</code> if the calling thread was not associated
       *         with a transaction.
  -    * @throws javax.transaction.SystemException If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *          If the transaction service fails in an
       *                         unexpected way.
       */
  -   public Transaction suspend() throws SystemException {
  -      Transaction retval=getTransaction();
  +   public Transaction suspend() throws SystemException
  +   {
  +      Transaction retval = getTransaction();
         setTransaction(null);
         return retval;
      }
  @@ -172,22 +201,27 @@
       * transaction.
       *
       * @param tx The transaction to be associated with the calling thread.
  -    * @throws javax.transaction.InvalidTransactionException If the argument does not represent
  +    * @throws javax.transaction.InvalidTransactionException
  +    *                               If the argument does not represent
       *                                     a valid transaction.
       * @throws IllegalStateException       If the calling thread is already
       *                                     associated with a transaction.
  -    * @throws javax.transaction.SystemException             If the transaction service fails in an
  +    * @throws javax.transaction.SystemException
  +    *                               If the transaction service fails in an
       *                                     unexpected way.
       */
  -   public void resume(Transaction tx) throws InvalidTransactionException, IllegalStateException, SystemException {
  +   public void resume(Transaction tx) throws InvalidTransactionException, IllegalStateException, SystemException
  +   {
         setTransaction(tx);
      }
   
      /**
       * Just used for unit tests
  +    *
       * @param tx
       */
  -   public void setTransaction(Transaction tx) {
  +   public void setTransaction(Transaction tx)
  +   {
         thread_local.set(tx);
      }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:47 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:47 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/interceptors
	...
Message-ID: <E1H0kCF-0002M4-VD@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:47

  Modified:    tests/functional/org/jboss/cache/interceptors 
                        EvictionInterceptorTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.19      +2 -2      JBossCache/tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionInterceptorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- EvictionInterceptorTest.java	30 Dec 2006 17:50:07 -0000	1.18
  +++ EvictionInterceptorTest.java	30 Dec 2006 19:48:47 -0000	1.19
  @@ -217,7 +217,7 @@
         fqn = Fqn.fromString("/d/e/g");
         for (int i = 0; i < 1000; i++)
         {
  -         key = new Integer(i);
  +         key = i;
   
            cache.put("/d/e/g", key, "");
   
  @@ -247,7 +247,7 @@
   
         for (int i = 0; i < 1000; i++)
         {
  -         key = new Integer(i);
  +         key = i;
   
            cache.put(fqn.toString(), key, "");
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1H0kCG-0002MB-3X@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    tests/functional/org/jboss/cache/optimistic 
                        ComparatorTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.7       +124 -115  JBossCache/tests/functional/org/jboss/cache/optimistic/ComparatorTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ComparatorTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ComparatorTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ComparatorTest.java	10 Apr 2006 00:36:54 -0000	1.6
  +++ ComparatorTest.java	30 Dec 2006 19:48:48 -0000	1.7
  @@ -8,6 +8,7 @@
   
   /**
    * Tests {@link FqnComparator}.
  + *
    * @author xenephon
    */
   public class ComparatorTest extends TestCase
  @@ -124,7 +125,7 @@
           Fqn fqn1 = Fqn.fromString("/one/two");
   
           List temp = new ArrayList();
  -        temp.add(new Integer(1234));
  +      temp.add(1234);
           Fqn fqn2 = new Fqn(temp);
   
           assertTrue(comp.compare(fqn1, fqn2) > 0);
  @@ -137,11 +138,11 @@
   
       public void testOrdinaryObjectCompare()
       {
  -        Fqn fqn1 = new Fqn(new Object[] {new XYZ(), new ABC()});
  -        Fqn fqn2 = new Fqn(new Object[] {"XYZ", "ABC"});
  -        Fqn fqn3 = new Fqn(new Object[] {"XYZ", new ABC()});
  +      Fqn fqn1 = new Fqn(new Object[]{new XYZ(), new ABC()});
  +      Fqn fqn2 = new Fqn(new Object[]{"XYZ", "ABC"});
  +      Fqn fqn3 = new Fqn(new Object[]{"XYZ", new ABC()});
   
  -        Fqn fqn4 = new Fqn(new Object[] {"XYZ", new XYZ()});
  +      Fqn fqn4 = new Fqn(new Object[]{"XYZ", new XYZ()});
   
           assertEquals(0, comp.compare(fqn1, fqn2));
           assertEquals(0, comp.compare(fqn1, fqn3));
  @@ -165,12 +166,20 @@
       }
       */
   
  -    private static class XYZ {
  -       public String toString() { return "XYZ"; }
  +   private static class XYZ
  +   {
  +      public String toString()
  +      {
  +         return "XYZ";
  +      }
       }
   
  -    private static class ABC {
  -       public String toString() { return "ABC"; }
  +   private static class ABC
  +   {
  +      public String toString()
  +      {
  +         return "ABC";
  +      }
       }
   
   }
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/collection ...
Message-ID: <E1H0kCG-0002MI-8d@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    tests-50/functional/org/jboss/cache/pojo/collection 
                        CachedMapTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.6       +84 -77    JBossCache/tests-50/functional/org/jboss/cache/pojo/collection/CachedMapTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CachedMapTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/collection/CachedMapTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- CachedMapTest.java	31 Oct 2006 11:07:16 -0000	1.5
  +++ CachedMapTest.java	30 Dec 2006 19:48:48 -0000	1.6
  @@ -130,7 +130,7 @@
      public void testLongValue() throws Throwable
      {
         Long val = new Long("8225676592564383");
  -      Long val2 = new Long(8225676592564383L);
  +      Long val2 = 8225676592564383L;
         assertTrue(0 == val.compareTo(val2));   // sanity check
         hobbies.put(val, "prateek");
         assertTrue(hobbies.containsKey(val));
  @@ -209,12 +209,12 @@
      {
         Map map1 = new HashMap();
         cache_.attach("map1", map1);
  -      map1 = (Map)cache_.find("map1");
  +      map1 = (Map) cache_.find("map1");
         map1.put("1", "test");
   
         Map map2 = new HashMap();
         cache_.attach("map2", map2);
  -      map2 = (Map)cache_.find("map2");
  +      map2 = (Map) cache_.find("map2");
         map2.put("1", "me");
   
         assertFalse("Map should not be the same ", map1.equals(map2));
  @@ -224,13 +224,13 @@
      {
         Map map1 = new HashMap();
         cache_.attach("map1", map1);
  -      map1 = (Map)cache_.find("map1");
  +      map1 = (Map) cache_.find("map1");
         map1.put("1", "test");
         map1.put("2", "test");
   
         Map map2 = new HashMap();
         cache_.attach("map2", map2);
  -      map2 = (Map)cache_.find("map2");
  +      map2 = (Map) cache_.find("map2");
         map2.put("1", "me");
         map2.put("2", "me");
   
  @@ -253,9 +253,9 @@
   
         System.out.println("**** End of cache content **** ");
         map.remove("2");
  -      map.put(new Integer(2), "Hoklo");
  +      map.put(2, "Hoklo");
         assertEquals("Size ", 3, map.size());
  -      assertEquals("Content ", "Hoklo", map.get(new Integer(2)));
  +      assertEquals("Content ", "Hoklo", map.get(2));
   
         // Try to re-attach
         cache_.attach("/test", map);
  @@ -303,61 +303,65 @@
   
      public void testKeyAsObject() throws Exception
      {
  -      SerializableKeyValue key = new SerializableKeyValue(42,"Novell");
  +      SerializableKeyValue key = new SerializableKeyValue(42, "Novell");
         Address add1 = new Address();
         add1.setCity("Waltham");
         add1.setStreet("404 Wyman Street");
         add1.setZip(02451);
   
         Map map = new HashMap();
  -      map.put(key,add1);
  +      map.put(key, add1);
         cache_.attach("/keytest", map);
  -      Map ref = (Map)cache_.find("/keytest");
  +      Map ref = (Map) cache_.find("/keytest");
   
         Iterator iter = ref.keySet().iterator();
         assertTrue(iter.hasNext());
         Object keyFromMap = iter.next();
         assertEquals("original key is same as key in pojocache map, key class=" +
  -            key.getClass().getName() +", keyFromMap class=" + keyFromMap.getClass().getName(),
  -            key , keyFromMap);
  -      assertEquals("local map is equal to pojocache map",map, ref);
  +              key.getClass().getName() + ", keyFromMap class=" + keyFromMap.getClass().getName(),
  +              key, keyFromMap);
  +      assertEquals("local map is equal to pojocache map", map, ref);
         }
   
      public void testNonSerializableKeyAsObject() throws Exception
      {
         // negative test as we should get a java.io.NotSerializableException
  -      NotSerializableKeyValue key = new NotSerializableKeyValue(42,"Novell");
  +      NotSerializableKeyValue key = new NotSerializableKeyValue(42, "Novell");
         Address add1 = new Address();
         add1.setCity("Waltham");
         add1.setStreet("404 Wyman Street");
         add1.setZip(02451);
   
         Map map = new HashMap();
  -      map.put(key,add1);
  -      try {
  +      map.put(key, add1);
  +      try
  +      {
            cache_.attach("/keytest", map);  // this should throw RuntimeException with cause of java.io.NotSerializableException
            fail("failed to get expected runtimeException when adding nonserializable key to pojocache map");
         }
  -      catch(RuntimeException e) {
  +      catch (RuntimeException e)
  +      {
            Throwable t = e;
  -         while((t.getCause() instanceof RuntimeException )) // get through wrapped runtimeexceptions
  +         while ((t.getCause() instanceof RuntimeException)) // get through wrapped runtimeexceptions
               t = t.getCause();
  -         assertTrue("we got expected RuntimeException, test that cause is java.io.NotSerializableException, t.getCause()= "+t.getCause().getClass().getName(), t.getCause() instanceof java.io.NotSerializableException);
  +         assertTrue("we got expected RuntimeException, test that cause is java.io.NotSerializableException, t.getCause()= " + t.getCause().getClass().getName(), t.getCause() instanceof java.io.NotSerializableException);
         }
         map.clear();
         cache_.attach("/keytest", map);  // this should succeed
  -      Map ref = (Map)cache_.find("/keytest");
  +      Map ref = (Map) cache_.find("/keytest");
   
         // try adding nonserializable key to pojocache based map
  -      try {
  +      try
  +      {
            ref.put(key, add1);  // this should throw RuntimeException with cause of java.io.NotSerializableException
            fail("failed to get expected runtimeException when putting nonserializable key to pojocache map");
         }
  -      catch(RuntimeException e) {
  +      catch (RuntimeException e)
  +      {
            Throwable t = e;
  -         while((t.getCause() instanceof RuntimeException )) // get through wrapped runtimeexceptions
  +         while ((t.getCause() instanceof RuntimeException)) // get through wrapped runtimeexceptions
               t = t.getCause();
  -         assertTrue("we got expected RuntimeException, test that cause is java.io.NotSerializableException, t.getCause()= "+t.getCause().getClass().getName(), t.getCause() instanceof java.io.NotSerializableException);
  +         assertTrue("we got expected RuntimeException, test that cause is java.io.NotSerializableException, t.getCause()= " + t.getCause().getClass().getName(), t.getCause() instanceof java.io.NotSerializableException);
         }
      }
   
  @@ -370,6 +374,7 @@
      {
         junit.textui.TestRunner.run(suite());
      }
  +
      static class SerializableKeyValue implements Serializable
      {
          Integer ivalue;
  @@ -378,7 +383,7 @@
          SerializableKeyValue(Integer ivalue, String svalue)
          {
              this.ivalue = ivalue;
  -           this.svalue= svalue;
  +         this.svalue = svalue;
          }
   
          public int hashCode()
  @@ -388,15 +393,16 @@
   
          public boolean equals(Object o)
          {
  -           if(o == this)
  +         if (o == this)
              {
                  return true;
              }
  -           if(! (o instanceof SerializableKeyValue)) {
  +         if (!(o instanceof SerializableKeyValue))
  +         {
                  System.out.println("equals: not instanceof SerializableKeyValue , it is a " + o.getClass().getName());
                  return false;
              }
  -           SerializableKeyValue val = (SerializableKeyValue)o;
  +         SerializableKeyValue val = (SerializableKeyValue) o;
              return val.ivalue == this.ivalue && val.svalue == this.svalue;
          }
      }
  @@ -409,7 +415,7 @@
             NotSerializableKeyValue(Integer ivalue, String svalue)
             {
                 this.ivalue = ivalue;
  -              this.svalue= svalue;
  +         this.svalue = svalue;
             }
   
             public int hashCode()
  @@ -419,15 +425,16 @@
   
             public boolean equals(Object o)
             {
  -              if(o == this)
  +         if (o == this)
                 {
                     return true;
                 }
  -              if(! (o instanceof SerializableKeyValue)) {
  +         if (!(o instanceof SerializableKeyValue))
  +         {
                     System.out.println("equals: not instanceof SerializableKeyValue , it is a " + o.getClass().getName());
                     return false;
                 }
  -              SerializableKeyValue val = (SerializableKeyValue)o;
  +         SerializableKeyValue val = (SerializableKeyValue) o;
                 return val.ivalue == this.ivalue && val.svalue == this.svalue;
             }
         }
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/config     ...
Message-ID: <E1H0kCG-0002MY-E5@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    src/org/jboss/cache/config     EvictionConfig.java
                        ConfigurationComponent.java Configuration.java
                        EvictionRegionConfig.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.7       +11 -12    JBossCache/src/org/jboss/cache/config/EvictionConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/EvictionConfig.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- EvictionConfig.java	27 Nov 2006 04:49:46 -0000	1.6
  +++ EvictionConfig.java	30 Dec 2006 19:48:48 -0000	1.7
  @@ -21,18 +21,18 @@
    */
   package org.jboss.cache.config;
   
  -import java.util.Collections;
  -import java.util.Iterator;
  -import java.util.List;
  -
  -import org.jboss.cache.RegionImpl;
   import org.jboss.cache.RegionManager;
   import org.jboss.cache.eviction.EvictionPolicy;
   import org.jboss.cache.eviction.EvictionPolicyConfig;
   
  +import java.util.Collections;
  +import java.util.List;
  +
   public class EvictionConfig extends ConfigurationComponent
   {
  -   /** The serialVersionUID */
  +   /**
  +    * The serialVersionUID
  +    */
      private static final long serialVersionUID = -7979639000026975201L;
   
      public static final String WAKEUP_INTERVAL_SECONDS = "wakeUpIntervalSeconds";
  @@ -123,9 +123,8 @@
         // Make sure region configs built by MC have the event queue size
         if (evictionRegionConfigs != null)
         {
  -         for (Iterator it = evictionRegionConfigs.iterator(); it.hasNext();)
  +         for (EvictionRegionConfig cfg : evictionRegionConfigs)
            {
  -            EvictionRegionConfig cfg = (EvictionRegionConfig) it.next();
               cfg.setDefaultEventQueueSize(getDefaultEventQueueSize());
            }
         }
  
  
  
  1.4       +7 -8      JBossCache/src/org/jboss/cache/config/ConfigurationComponent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConfigurationComponent.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/ConfigurationComponent.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ConfigurationComponent.java	30 Dec 2006 17:50:00 -0000	1.3
  +++ ConfigurationComponent.java	30 Dec 2006 19:48:48 -0000	1.4
  @@ -14,7 +14,6 @@
   import java.util.Collection;
   import java.util.Collections;
   import java.util.HashSet;
  -import java.util.Iterator;
   import java.util.Set;
   
   /**
  @@ -22,7 +21,7 @@
    * that can be changed after the cache is started.
    *
    * @author <a href="brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.3 $
  + * @version $Revision: 1.4 $
    * @see #testImmutability(String)
    */
   public class ConfigurationComponent implements Serializable, Cloneable
  @@ -42,14 +41,14 @@
      {
         if (child != null)
         {
  -         child.setTreeCache(cache);
  +         child.setCacheImpl(cache);
         }
      }
   
      protected void addChildConfig(ConfigurationComponent child)
      {
         if (child != null && children.add(child))
  -         child.setTreeCache(cache);
  +         child.setCacheImpl(cache);
      }
   
      protected void addChildConfigs(Collection<? extends ConfigurationComponent> toAdd)
  @@ -121,14 +120,14 @@
       *
       * @param cache
       */
  -   public void setTreeCache(CacheImpl cache)
  +   public void setCacheImpl(CacheImpl cache)
      {
         this.cache = cache;
         synchronized (children)
         {
  -         for (Iterator it = children.iterator(); it.hasNext();)
  +         for (ConfigurationComponent child : children)
            {
  -            ((ConfigurationComponent) it.next()).setTreeCache(cache);
  +            child.setCacheImpl(cache);
            }
         }
      }
  @@ -136,7 +135,7 @@
      public ConfigurationComponent clone() throws CloneNotSupportedException
      {
         ConfigurationComponent c = (ConfigurationComponent) super.clone();
  -      c.setTreeCache(null);
  +      c.setCacheImpl(null);
         return c;
      }
   
  
  
  
  1.29      +1 -1      JBossCache/src/org/jboss/cache/config/Configuration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Configuration.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/Configuration.java,v
  retrieving revision 1.28
  retrieving revision 1.29
  diff -u -b -r1.28 -r1.29
  --- Configuration.java	30 Dec 2006 17:50:00 -0000	1.28
  +++ Configuration.java	30 Dec 2006 19:48:48 -0000	1.29
  @@ -115,7 +115,7 @@
       */
      public Configuration(CacheImpl cache)
      {
  -      setTreeCache(cache);
  +      setCacheImpl(cache);
      }
   
      /**
  
  
  
  1.3       +27 -23    JBossCache/src/org/jboss/cache/config/EvictionRegionConfig.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: EvictionRegionConfig.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/config/EvictionRegionConfig.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- EvictionRegionConfig.java	27 Oct 2006 19:26:07 -0000	1.2
  +++ EvictionRegionConfig.java	30 Dec 2006 19:48:48 -0000	1.3
  @@ -27,7 +27,9 @@
   
   public class EvictionRegionConfig extends ConfigurationComponent
   {
  -   /** The serialVersionUID */
  +   /**
  +    * The serialVersionUID
  +    */
      private static final long serialVersionUID = -5482474634995601400L;
      
      public static final String NAME = "name";
  @@ -40,7 +42,9 @@
      private Integer eventQueueSize;
      private EvictionPolicyConfig evictionPolicyConfig;
      
  -   public EvictionRegionConfig() {}
  +   public EvictionRegionConfig()
  +   {
  +   }
      
      public EvictionPolicyConfig getEvictionPolicyConfig()
      {
  @@ -74,6 +78,7 @@
         testImmutability("regionFqn");
         this.regionFqn = regionFqn;
      }
  +
      public String getRegionName()
      {
         return regionFqn == null ? null : regionFqn.toString();
  @@ -86,7 +91,7 @@
   
      public int getEventQueueSize()
      {
  -      return eventQueueSize == null ? EvictionConfig.EVENT_QUEUE_SIZE_DEFAULT : eventQueueSize.intValue();
  +      return eventQueueSize == null ? EvictionConfig.EVENT_QUEUE_SIZE_DEFAULT : eventQueueSize;
      }
   
      public void setEventQueueSize(int queueSize)
  @@ -99,7 +104,7 @@
                                                               EvictionConfig.EVENT_QUEUE_SIZE_DEFAULT);
            queueSize = EvictionConfig.EVENT_QUEUE_SIZE_DEFAULT;
         }
  -      this.eventQueueSize = new Integer(queueSize);
  +      this.eventQueueSize = queueSize;
      }
      
      public void setDefaultEventQueueSize(int queueSize)
  @@ -133,5 +138,4 @@
      }
      
      
  -   
   }
  \ No newline at end of file
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/tcp  ...
Message-ID: <E1H0kCG-0002Mf-He@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    src/org/jboss/cache/loader/tcp  TcpCacheServer.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.23      +13 -18    JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServer.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TcpCacheServer.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/tcp/TcpCacheServer.java,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -b -r1.22 -r1.23
  --- TcpCacheServer.java	30 Dec 2006 17:50:01 -0000	1.22
  +++ TcpCacheServer.java	30 Dec 2006 19:48:48 -0000	1.23
  @@ -27,7 +27,6 @@
   import java.net.UnknownHostException;
   import java.util.ArrayList;
   import java.util.HashMap;
  -import java.util.Iterator;
   import java.util.LinkedList;
   import java.util.List;
   import java.util.Map;
  @@ -37,7 +36,7 @@
    * TCP-IP based CacheServer, configure TcpDelegatingCacheLoader with host and port of this server
    *
    * @author Bela Ban
  - * @version $Id: TcpCacheServer.java,v 1.22 2006/12/30 17:50:01 msurtani Exp $
  + * @version $Id: TcpCacheServer.java,v 1.23 2006/12/30 19:48:48 msurtani Exp $
    */
   public class TcpCacheServer implements TcpCacheServerMBean
   {
  @@ -49,7 +48,7 @@
      ObjectName cache_name;
      String config;
      boolean running = true;
  -   final List conns = new LinkedList();
  +   final List<Connection> conns = new LinkedList<Connection>();
      String agendId;
      Thread serverThread;
      /**
  @@ -130,9 +129,6 @@
   
      public void start() throws Exception
      {
  -      Socket client_sock;
  -      Connection conn;
  -
         if (cache == null)
         {
            MBeanServer server = JmxUtil.getMBeanServer();
  @@ -208,9 +204,8 @@
      public void stop()
      {
         running = false;
  -      for (Iterator it = conns.iterator(); it.hasNext();)
  +      for (Connection conn : conns)
         {
  -         Connection conn = (Connection) it.next();
            conn.close();
         }
         conns.clear();
  @@ -224,6 +219,7 @@
            }
            catch (IOException e)
            {
  +            // nada
            }
         }
      }
  @@ -232,10 +228,9 @@
      public String getConnections()
      {
         StringBuffer sb = new StringBuffer();
  -      sb.append(conns.size() + " connections:\n");
  -      for (Iterator it = conns.iterator(); it.hasNext();)
  +      sb.append(conns.size()).append(" connections:\n");
  +      for (Connection c : conns)
         {
  -         Connection c = (Connection) it.next();
            sb.append(c).append("\n");
         }
         return sb.toString();
  @@ -288,6 +283,7 @@
            }
            catch (Throwable th)
            {
  +            // nada
            }
            try
            {
  @@ -295,6 +291,7 @@
            }
            catch (Throwable th)
            {
  +            // nada
            }
            try
            {
  @@ -302,6 +299,7 @@
            }
            catch (Throwable th)
            {
  +            // nada
            }
   
            // remove self from connections list
  @@ -313,10 +311,8 @@
            int op;
            Fqn fqn;
            Object key, val, retval;
  -         Map map;
            Node n;
            boolean flag;
  -         byte[] state;
   
            while (t != null && Thread.currentThread().equals(t))
            {
  @@ -355,7 +351,7 @@
                           output.writeObject(n);
                           break;
                        }
  -                     map = n.getData();
  +                     Map map = n.getData();
                        if (map == null) map = new HashMap();
                        output.writeObject(map);
                        break;
  @@ -384,7 +380,7 @@
                        if (length > 0)
                        {
                           Modification mod;
  -                        List mods = new ArrayList(length);
  +                        List<Modification> mods = new ArrayList<Modification>(length);
                           for (int i = 0; i < length; i++)
                           {
                              mod = new Modification();
  @@ -466,12 +462,11 @@
            return sb.toString();
         }
   
  -      protected void handleModifications(List modifications) throws CacheException
  +      protected void handleModifications(List<Modification> modifications) throws CacheException
         {
   
  -         for (Iterator it = modifications.iterator(); it.hasNext();)
  +         for (Modification m : modifications)
            {
  -            Modification m = (Modification) it.next();
               switch (m.getType())
               {
                  case PUT_DATA:
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/eviction  ...
Message-ID: <E1H0kCG-0002Mm-Lq@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    src/org/jboss/cache/eviction  ExpirationAlgorithm.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.4       +36 -36    JBossCache/src/org/jboss/cache/eviction/ExpirationAlgorithm.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ExpirationAlgorithm.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/eviction/ExpirationAlgorithm.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ExpirationAlgorithm.java	8 Dec 2006 19:19:05 -0000	1.3
  +++ ExpirationAlgorithm.java	30 Dec 2006 19:48:48 -0000	1.4
  @@ -1,15 +1,15 @@
   package org.jboss.cache.eviction;
   
  -import java.util.Iterator;
  -import java.util.SortedSet;
  -import java.util.TreeSet;
  -
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
   import org.jboss.cache.Region;
   import org.jboss.cache.optimistic.FqnComparator;
   
  +import java.util.Iterator;
  +import java.util.SortedSet;
  +import java.util.TreeSet;
  +
   /**
    * Eviction algorithm that uses a key in the Node data that indicates the time
    * the node should be evicted.  The key must be a java.lang.Long object, with
  @@ -41,23 +41,23 @@
    * A node's expiration time can be changed by setting a new value in the node.
    * <p/>
    * Example usage:
  - <pre>
  - Cache cache;
  - Fqn fqn1 = Fqn.fromString("/node/1");
  - Long future = Long.valueOf(System.currentTimeMillis() + 2000);
  - cache.put(fqn1, ExpirationConfiguration.DEFAULT_EXPIRATION_KEY, future);
  - cache.put(fqn1, "foo");
  - assertTrue(cache.get(fqn1) != null);
  - 
  - Thread.sleep(5000); // 5 seconds
  - assertTrue(cache.get(fqn1) == null);
  -
  - // Alternatively, this expires a node in one second
  - cache.put(fqn1, "foo");
  - cache.getRegion(fqn1, false).markNodeCurrentlyInUse(fqn1, 1000);
  - Thread.sleep(2000); // 5 seconds
  - assertTrue(cache.get(fqn1) == null);
  - </pre>
  + * <pre>
  + * Cache cache;
  + * Fqn fqn1 = Fqn.fromString("/node/1");
  + * Long future = Long.valueOf(System.currentTimeMillis() + 2000);
  + * cache.put(fqn1, ExpirationConfiguration.DEFAULT_EXPIRATION_KEY, future);
  + * cache.put(fqn1, "foo");
  + * assertTrue(cache.get(fqn1) != null);
  + * <p/>
  + * Thread.sleep(5000); // 5 seconds
  + * assertTrue(cache.get(fqn1) == null);
  + * <p/>
  + * // Alternatively, this expires a node in one second
  + * cache.put(fqn1, "foo");
  + * cache.getRegion(fqn1, false).markNodeCurrentlyInUse(fqn1, 1000);
  + * Thread.sleep(2000); // 5 seconds
  + * assertTrue(cache.get(fqn1) == null);
  + * </pre>
    */
   public class ExpirationAlgorithm extends BaseEvictionAlgorithm
   {
  @@ -106,7 +106,7 @@
         boolean found = set.remove(new ExpirationEntry(fqn));
         if (found && log.isTraceEnabled())
            log.trace("removed old expiration for " + fqn);
  -      ExpirationEntry ee = new ExpirationEntry(fqn, l.longValue());
  +      ExpirationEntry ee = new ExpirationEntry(fqn, l);
         if (log.isTraceEnabled())
            log.trace("adding eviction entry: " + ee);
         set.add(ee);
  @@ -130,22 +130,22 @@
            count++;
            switch (node.getEventType())
            {
  -            case ADD_NODE_EVENT :
  -            case ADD_ELEMENT_EVENT :
  +            case ADD_NODE_EVENT:
  +            case ADD_ELEMENT_EVENT:
                  addEvictionEntry(node);
                  break;
  -            case REMOVE_ELEMENT_EVENT :
  -            case REMOVE_NODE_EVENT :
  -            case UNMARK_USE_EVENT :
  +            case REMOVE_ELEMENT_EVENT:
  +            case REMOVE_NODE_EVENT:
  +            case UNMARK_USE_EVENT:
                  removeEvictionEntry(node);
                  break;
  -            case VISIT_NODE_EVENT :
  +            case VISIT_NODE_EVENT:
                  // unused
                  break;
  -            case MARK_IN_USE_EVENT :
  +            case MARK_IN_USE_EVENT:
                  markInUse(node);
                  break;
  -            default :
  +            default:
                  throw new RuntimeException("Illegal Eviction Event type " + node.getEventType());
            }
         }
  @@ -159,7 +159,7 @@
      private void markInUse(EvictedEventNode node)
      {
         long expiration = node.getInUseTimeout() + System.currentTimeMillis();
  -      setExpiration(node.getFqn(), new Long(expiration));
  +      setExpiration(node.getFqn(), expiration);
      }
   
      @Override
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/statetransfer
	...
Message-ID: <E1H0kCG-0002Mw-Qq@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    tests/functional/org/jboss/cache/statetransfer  
                        VersionedTestBase.java StateTransferTestBase.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.22      +59 -62    JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: VersionedTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java,v
  retrieving revision 1.21
  retrieving revision 1.22
  diff -u -b -r1.21 -r1.22
  --- VersionedTestBase.java	22 Dec 2006 18:55:05 -0000	1.21
  +++ VersionedTestBase.java	30 Dec 2006 19:48:48 -0000	1.22
  @@ -422,7 +422,7 @@
                            aException.getCause() instanceof InactiveRegionException);
               if (gotUnexpectedException)
               {
  -               fail("Activator " + names[i] + " caught an exception " +aException);
  +               fail("Activator " + names[i] + " caught an exception " + aException);
               }
   
               for (int j = 0; j < count; j++)
  @@ -451,13 +451,13 @@
       * Starts two caches where each cache has N regions. We put some data in each of the regions. 
       * We run two threads where each thread creates a cache then goes into a loop where it 
       * activates the N regions, with a 1 sec pause between activations.
  -    * 
  +    * <p/>
       * Threads are started with 10 sec difference.
  -    * 
  +    * <p/>
       * This test simulates a 10 sec staggered start of 2 servers in a cluster, with each server 
       * then deploying webapps.
  -    * 
  -    * 
  +    * <p/>
  +    * <p/>
       * <p/>
       * Failure condition is if any node sees an exception or if the final state
       * of all caches is not consistent.
  @@ -467,7 +467,7 @@
       */
      private void concurrentActivationTest2(boolean sync) throws Exception
      {
  -      String[] names = {"A","B"};
  +      String[] names = {"A", "B"};
         int count = names.length;
         int regionsToActivate = 15;
         int sleepTimeBetweenNodeStarts = 10000;
  @@ -485,7 +485,7 @@
            CacheSPI[] caches = new CacheSPI[count];
            for (int i = 0; i < count; i++)
            {
  -            activators[i] = new StaggeredWebDeployerActivator(semaphore, names[i], sync,regionsToActivate);
  +            activators[i] = new StaggeredWebDeployerActivator(semaphore, names[i], sync, regionsToActivate);
               caches[i] = activators[i].getCacheSPI();        
               
               // Release the semaphore to allow the thread to start working 
  @@ -523,7 +523,7 @@
                            aException.getCause() instanceof InactiveRegionException);
               if (gotUnexpectedException)
               {
  -               fail("Activator " + names[i] + " caught an exception " +aException);
  +               fail("Activator " + names[i] + " caught an exception " + aException);
               }
   
               for (int j = 0; j < regionsToActivate; j++)
  @@ -550,18 +550,16 @@
       * Starts two caches where each cache has N regions. We put some data in each of the regions. 
       * We run two threads where each thread creates a cache then goes into a loop where it 
       * activates the N regions, with a 1 sec pause between activations.
  -    * 
  +    * <p/>
       * Threads are started with 10 sec difference.
  -    * 
  +    * <p/>
       * This test simulates a 10 sec staggered start of 2 servers in a cluster, with each server 
       * then deploying webapps.
  -    * 
  -    * 
  +    * <p/>
  +    * <p/>
       * <p/>
       * Failure condition is if any node sees an exception or if the final state
       * of all caches is not consistent.
  -    *  
  -    *
       */
      public void testConcurrentStartupActivationAsync() throws Exception
      {     
  @@ -572,18 +570,16 @@
       * Starts two caches where each cache has N regions. We put some data in each of the regions. 
       * We run two threads where each thread creates a cache then goes into a loop where it 
       * activates the N regions, with a 1 sec pause between activations.
  -    * 
  +    * <p/>
       * Threads are started with 10 sec difference.
  -    * 
  +    * <p/>
       * This test simulates a 10 sec staggered start of 2 servers in a cluster, with each server 
       * then deploying webapps.
  -    * 
  -    * 
  +    * <p/>
  +    * <p/>
       * <p/>
       * Failure condition is if any node sees an exception or if the final state
       * of all caches is not consistent.
  -    *  
  -    *
       */
      public void testConcurrentStartupActivationSync() throws Exception
      {     
  @@ -753,7 +749,7 @@
         Object addr = addrClazz.newInstance();
         setCity.invoke(addr, new Object[]{"San Jose"});
         setStreet.invoke(addr, new Object[]{"1007 Home"});
  -      setZip.invoke(addr, new Object[]{new Integer(90210)});
  +      setZip.invoke(addr, new Object[]{90210});
   
         Class benClazz = loader.loadClass(PERSON_CLASSNAME);
         Method setName = benClazz.getMethod("setName", new Class[]{String.class});
  @@ -798,6 +794,7 @@
      {
   
         int regionCount = 15;
  +
         StaggeredWebDeployerActivator(Semaphore semaphore,
                        String name,
                        boolean sync,
  @@ -812,7 +809,7 @@
         {         
            for (int i = 0; i < regionCount; i++)
            {
  -            cache.getRegion(Fqn.fromString("/a/"+i), true).activate();
  +            cache.getRegion(Fqn.fromString("/a/" + i), true).activate();
               
               Fqn childFqn = Fqn.fromString("/a/" + i + "/" + name);           
               cache.put(childFqn, "KEY", "VALUE");
  @@ -865,7 +862,7 @@
                  factor = random.nextInt(50);
   
                  fqn = Fqn.fromString("/" + name + "/" + String.valueOf(factor % SUBTREE_SIZE));
  -               Integer value = new Integer(factor / SUBTREE_SIZE);
  +               Integer value = factor / SUBTREE_SIZE;
                  cache.put(fqn, "KEY", value);
   
                  TestingUtil.sleepThread((long) factor);
  
  
  
  1.28      +2 -2      JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java,v
  retrieving revision 1.27
  retrieving revision 1.28
  diff -u -b -r1.27 -r1.28
  --- StateTransferTestBase.java	30 Dec 2006 17:49:59 -0000	1.27
  +++ StateTransferTestBase.java	30 Dec 2006 19:48:48 -0000	1.28
  @@ -55,8 +55,8 @@
      public static final String JOE = "JOE";
      public static final String BOB = "BOB";
      public static final String JANE = "JANE";
  -   public static final Integer TWENTY = new Integer(20);
  -   public static final Integer FORTY = new Integer(40);
  +   public static final Integer TWENTY = 20;
  +   public static final Integer FORTY = 40;
   
      protected Map caches;
      private ClassLoader orig_TCL;
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:48 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:48 -0500
Subject: [jboss-cvs] JBossCache/tests-50/functional/org/jboss/cache/pojo/util
	...
Message-ID: <E1H0kCG-0002N3-Ul@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:48

  Modified:    tests-50/functional/org/jboss/cache/pojo/util 
                        MethodCallTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.5       +4 -11     JBossCache/tests-50/functional/org/jboss/cache/pojo/util/MethodCallTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodCallTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/util/MethodCallTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- MethodCallTest.java	10 Jul 2006 02:09:28 -0000	1.4
  +++ MethodCallTest.java	30 Dec 2006 19:48:48 -0000	1.5
  @@ -7,22 +7,15 @@
   
   package org.jboss.cache.pojo.util;
   
  -import junit.framework.TestCase;
   import junit.framework.Test;
  +import junit.framework.TestCase;
   import junit.framework.TestSuite;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.aop.InstanceAdvisor;
  -import org.jboss.aop.ClassInstanceAdvisor;
  -import org.jboss.aop.advice.Interceptor;
  -import org.jboss.cache.pojo.interceptors.dynamic.CacheFieldInterceptor;
  -import org.jboss.cache.pojo.MethodDeclarations;
  -import org.jboss.cache.pojo.PojoUtil;
   
   import java.lang.reflect.Method;
   
   /**
  - *
    * @author Ben Wang
    */
   
  @@ -50,11 +43,11 @@
   
      public void testBasic() throws Throwable
      {
  -      Integer i = new Integer(1);
  +      Integer i = 1;
         Method method = Foo.class.getDeclaredMethod("setFoo",
  -                   new Class[] {Integer.class});
  +              new Class[]{Integer.class});
   
  -      Object[] args = new Object[] {i};
  +      Object[] args = new Object[]{i};
         Foo foo = new Foo();
         MethodCall mc = new MethodCall(method, args, foo);
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:49 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/util  ...
Message-ID: <E1H0kCH-0002NA-2j@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:49

  Modified:    src/org/jboss/cache/util  MapCopy.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.6       +8 -10     JBossCache/src/org/jboss/cache/util/MapCopy.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MapCopy.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/util/MapCopy.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- MapCopy.java	11 Dec 2006 21:14:35 -0000	1.5
  +++ MapCopy.java	30 Dec 2006 19:48:49 -0000	1.6
  @@ -4,11 +4,9 @@
   import java.io.Serializable;
   import java.util.AbstractMap;
   import java.util.AbstractSet;
  -import java.util.Arrays;
   import java.util.Iterator;
   import java.util.Map;
   import java.util.Set;
  -import java.util.Map.Entry;
   
   /**
    * Contains a fixed array of read-only map entries, from a copy of an existing map.
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:49 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/marshall  ...
Message-ID: <E1H0kCH-0002NH-7F@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:49

  Modified:    src/org/jboss/cache/marshall  Marshaller.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.7       +5 -3      JBossCache/src/org/jboss/cache/marshall/Marshaller.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Marshaller.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/marshall/Marshaller.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- Marshaller.java	8 Dec 2006 18:49:18 -0000	1.6
  +++ Marshaller.java	30 Dec 2006 19:48:49 -0000	1.7
  @@ -9,6 +9,7 @@
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
  +import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Region;
   import org.jboss.cache.RegionManager;
   import org.jboss.cache.buddyreplication.BuddyManager;
  @@ -16,6 +17,7 @@
   import java.io.ObjectInputStream;
   import java.io.ObjectOutputStream;
   import java.util.List;
  +import java.util.Map;
   import java.util.concurrent.ConcurrentHashMap;
   
   /**
  @@ -33,7 +35,7 @@
      /**
       * Map<GlobalTransaction, Fqn> for prepared tx that have not committed
       */
  -   private ConcurrentHashMap transactions = new ConcurrentHashMap(16);
  +   private Map<GlobalTransaction, String> transactions = new ConcurrentHashMap<GlobalTransaction, String>(16);
   
      protected void init(RegionManager manager, boolean defaultInactive, boolean useRegionBasedMarshalling)
      {
  @@ -109,13 +111,13 @@
               // we can find it when the commit/rollback comes through
               if (!one_phase_commit)
               {
  -               transactions.put(args[0], fqnStr);
  +               transactions.put((GlobalTransaction) args[0], fqnStr);
               }
               break;
            case MethodDeclarations.rollbackMethod_id:
            case MethodDeclarations.commitMethod_id:
               // We stored the fqn in the transactions map during the prepare phase
  -            fqnStr = (String) transactions.remove(args[0]);
  +            fqnStr = transactions.remove(args[0]);
               break;
            case MethodDeclarations.getPartialStateMethod_id:
            case MethodDeclarations.dataGravitationMethod_id:
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:49 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/loader/deadlock ...
Message-ID: <E1H0kCH-0002NO-Bg@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:49

  Modified:    tests/functional/org/jboss/cache/loader/deadlock 
                        ConcurrentCreationDeadlockTest.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.9       +3 -3      JBossCache/tests/functional/org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConcurrentCreationDeadlockTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- ConcurrentCreationDeadlockTest.java	30 Dec 2006 17:49:59 -0000	1.8
  +++ ConcurrentCreationDeadlockTest.java	30 Dec 2006 19:48:49 -0000	1.9
  @@ -397,7 +397,7 @@
       *
       * @author Marian Nikolov
       * @author $Author: msurtani $
  -    * @version $Date: 2006/12/30 17:49:59 $
  +    * @version $Date: 2006/12/30 19:48:49 $
       */
      private class Worker extends Thread
      {
  @@ -467,7 +467,7 @@
                  }
                  // the first worker would create a new node for the FQN
                  // all the others would update the same node
  -               Fqn fqn = new Fqn(new Fqn("NODE"), new Integer(i));
  +               Fqn fqn = new Fqn(new Fqn("NODE"), i);
                  for (int m = 0; m < m_modificationsPerTx; m++)
                  {
                     cache.put(fqn, new Integer(m), new Integer(i));
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:49 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:49 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer ...
Message-ID: <E1H0kCH-0002NV-F4@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:49

  Modified:    tests-50/functional/org/jboss/cache/pojo/statetransfer 
                        StateTransferAopTestBase.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.7       +16 -16    JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer/StateTransferAopTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferAopTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer/StateTransferAopTestBase.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- StateTransferAopTestBase.java	15 Nov 2006 15:23:05 -0000	1.6
  +++ StateTransferAopTestBase.java	30 Dec 2006 19:48:49 -0000	1.7
  @@ -11,19 +11,19 @@
   import junit.framework.TestCase;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.cache.CacheException;
  -import org.jboss.cache.Fqn;
   import org.jboss.cache.Cache;
  +import org.jboss.cache.CacheException;
   import org.jboss.cache.CacheSPI;
  -import org.jboss.cache.pojo.PojoCache;
  -import org.jboss.cache.pojo.PojoCacheFactory;
  -import org.jboss.cache.pojo.test.Address;
  -import org.jboss.cache.pojo.test.Person;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.config.CacheLoaderConfig;
   import org.jboss.cache.config.Configuration;
   import org.jboss.cache.factories.XmlConfigurationParser;
   import org.jboss.cache.loader.CacheLoader;
   import org.jboss.cache.misc.TestingUtil;
  +import org.jboss.cache.pojo.PojoCache;
  +import org.jboss.cache.pojo.PojoCacheFactory;
  +import org.jboss.cache.pojo.test.Address;
  +import org.jboss.cache.pojo.test.Person;
   import org.jboss.cache.xml.XmlHelper;
   import org.w3c.dom.Element;
   
  @@ -39,7 +39,7 @@
    * Tests state transfer in PojoCache.
    *
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public abstract class StateTransferAopTestBase extends TestCase
   {
  @@ -64,9 +64,9 @@
      private Address addr1;
      private Address addr2;
   
  -   public static final Integer TWENTY = new Integer(20);
  -   public static final Integer TWENTYFIVE = new Integer(25);
  -   public static final Integer FORTY = new Integer(40);
  +   public static final Integer TWENTY = 20;
  +   public static final Integer TWENTYFIVE = 25;
  +   public static final Integer FORTY = 40;
   
      private Log log = LogFactory.getLog(StateTransferAopTestBase.class);
   
  @@ -226,7 +226,7 @@
         TestingUtil.blockUntilViewsReceived(new Cache[]
                 {cache1.getCache(), cache2.getCache()}, 60000);
   
  -      CacheLoader loader = ((CacheSPI)cache2.getCache()).getCacheLoader();
  +      CacheLoader loader = ((CacheSPI) cache2.getCache()).getCacheLoader();
   
         Map map = loader.get(A_B_1_f);
         if (map != null)
  @@ -726,7 +726,7 @@
   
         joe = new Person();
         joe.setName("Joe");
  -      joe.setAge(TWENTY.intValue());
  +      joe.setAge(TWENTY);
         joe.setAddress(addr1);
         Set skills = new HashSet();
         skills.add("TENNIS");
  @@ -735,7 +735,7 @@
   
         jane = new Person();
         jane.setName("Jane");
  -      jane.setAge(TWENTYFIVE.intValue());
  +      jane.setAge(TWENTYFIVE);
         jane.setAddress(addr1);
         skills = new HashSet();
         skills.add("JUJITSU");
  @@ -744,7 +744,7 @@
   
         bob = new Person();
         bob.setName("Bob");
  -      bob.setAge(FORTY.intValue());
  +      bob.setAge(FORTY);
         bob.setAddress(addr2);
         skills = new HashSet();
         skills.add("LANGUAGES");
  @@ -753,7 +753,7 @@
   
         jill = new Person();
         jill.setName("Jill");
  -      jill.setAge(TWENTYFIVE.intValue());
  +      jill.setAge(TWENTYFIVE);
         jill.setAddress(addr2);
         skills = new HashSet();
         skills.add("FORTRAN");
  @@ -1031,7 +1031,7 @@
                 throws Exception
         {
            this.cache = createCache(name, sync, true, false, !activateRoot);
  -         tm = ((CacheSPI)cache.getCache()).getTransactionManager();
  +         tm = ((CacheSPI) cache.getCache()).getTransactionManager();
            if (tm == null)
               throw new IllegalStateException("TransactionManager required");
            this.semaphore = semaphore;
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:50 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:50 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/bdbje  ...
Message-ID: <E1H0kCI-0002Nj-K9@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:50

  Modified:    src/org/jboss/cache/loader/bdbje  BdbjeCacheLoader.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.25      +13 -15    JBossCache/src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: BdbjeCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -b -r1.24 -r1.25
  --- BdbjeCacheLoader.java	30 Dec 2006 17:50:03 -0000	1.24
  +++ BdbjeCacheLoader.java	30 Dec 2006 19:48:50 -0000	1.25
  @@ -30,7 +30,6 @@
   import java.util.Collections;
   import java.util.HashMap;
   import java.util.HashSet;
  -import java.util.Iterator;
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
  @@ -50,7 +49,7 @@
    *
    * @author Mark Hayes May 16, 2004
    * @author Bela Ban
  - * @version $Id: BdbjeCacheLoader.java,v 1.24 2006/12/30 17:50:03 msurtani Exp $
  + * @version $Id: BdbjeCacheLoader.java,v 1.25 2006/12/30 19:48:50 msurtani Exp $
    */
   public class BdbjeCacheLoader extends AbstractCacheLoader
   {
  @@ -68,7 +67,7 @@
      private Database catalogDb;
      private StoredClassCatalog catalog;
      private SerialBinding serialBinding;
  -   private Map txnMap;
  +   private Map<Object, Transaction> txnMap;
      private boolean transactional;
   
      /*
  @@ -204,7 +203,7 @@
         serialBinding = new SerialBinding(catalog, null);
   
         /* Start with a fresh transaction map. */
  -      txnMap = new ConcurrentHashMap();
  +      txnMap = new ConcurrentHashMap<Object, Transaction>();
      }
   
      /**
  @@ -465,7 +464,7 @@
   
         Object oldVal = null;
         /* To update-or-insert, try putNoOverwrite first, then a RMW cycle. */
  -      Map map = new HashMap();
  +      Map<Object, Object> map = new HashMap<Object, Object>();
         map.put(key, value);
         DatabaseEntry dataEntry = makeDataEntry(map);
         DatabaseEntry keyEntry = makeKeyEntry(name);
  @@ -613,16 +612,15 @@
      /**
       * Internal version of put(List) that allows passing a transaction.
       */
  -   private void doPut(Transaction txn, List modifications)
  +   private void doPut(Transaction txn, List<Modification> modifications)
              throws Exception
      {
   
         /* This could be optimized by grouping modifications by Fqn, and
          * performing a single database operation for each Fqn (record). */
   
  -      for (Iterator i = modifications.iterator(); i.hasNext();)
  +      for (Modification mod : modifications)
         {
  -         Modification mod = (Modification) i.next();
            Fqn name = mod.getFqn();
            Object oldVal;
            switch (mod.getType())
  @@ -883,7 +881,7 @@
       * transactional. Commits the transaction if successful, or aborts the
       * transaction and throws an exception if not successful.
       */
  -   private void commitModifications(List mods)
  +   private void commitModifications(List<Modification> mods)
              throws Exception
      {
   
  @@ -897,7 +895,7 @@
       * retries.  Returns the transaction if successful; aborts the transaction
       * and throws an exception if not successful.
       */
  -   private Transaction performTransaction(List modifications)
  +   private Transaction performTransaction(List<Modification> modifications)
              throws Exception
      {
   
  @@ -942,7 +940,7 @@
         checkOpen();
         checkNonNull(tx, "tx");
   
  -      Transaction txn = (Transaction) txnMap.remove(tx);
  +      Transaction txn = txnMap.remove(tx);
         if (txn != null)
         {
            txn.commit();
  @@ -963,7 +961,7 @@
         checkOpen();
         checkNonNull(tx, "tx");
   
  -      Transaction txn = (Transaction) txnMap.remove(tx);
  +      Transaction txn = txnMap.remove(tx);
         if (txn != null)
         {
            try
  @@ -1072,12 +1070,12 @@
      /**
       * Converts a database entry to a Map.
       */
  -   private Map makeDataObject(DatabaseEntry entry, boolean createIfNull)
  +   private Map<Object, Object> makeDataObject(DatabaseEntry entry, boolean createIfNull)
      {
  -      Map map = (Map) serialBinding.entryToObject(entry);
  +      Map<Object, Object> map = (Map<Object, Object>) serialBinding.entryToObject(entry);
         if (createIfNull && map == null)
         {
  -         map = new HashMap();
  +         map = new HashMap<Object, Object>();
         }
         return map;
      }
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:50 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:50 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/collection  ...
Message-ID: <E1H0kCI-0002Nc-Fi@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:50

  Modified:    src-50/org/jboss/cache/pojo/collection 
                        CollectionInterceptorUtil.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.9       +27 -19    JBossCache/src-50/org/jboss/cache/pojo/collection/CollectionInterceptorUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CollectionInterceptorUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/collection/CollectionInterceptorUtil.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- CollectionInterceptorUtil.java	20 Nov 2006 23:32:49 -0000	1.8
  +++ CollectionInterceptorUtil.java	30 Dec 2006 19:48:50 -0000	1.9
  @@ -8,12 +8,12 @@
   
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
  -import org.jboss.aop.InstanceAdvisor;
   import org.jboss.aop.AspectManager;
  -import org.jboss.aop.pointcut.ast.ParseException;
  +import org.jboss.aop.InstanceAdvisor;
   import org.jboss.aop.advice.AdviceBinding;
   import org.jboss.aop.joinpoint.Invocation;
   import org.jboss.aop.joinpoint.MethodInvocation;
  +import org.jboss.aop.pointcut.ast.ParseException;
   import org.jboss.aop.proxy.ClassProxy;
   import org.jboss.aop.proxy.ClassProxyFactory;
   import org.jboss.aop.util.MethodHashing;
  @@ -55,21 +55,24 @@
         // Also take care of just toString()
         try
         {
  -         String bindName = clazz.getName() +".toString";
  +         String bindName = clazz.getName() + ".toString";
            HashMap<String, AdviceBinding> bindings = AspectManager.instance().getBindings();
  -         if(bindings.get(bindName) == null)
  +         if (bindings.get(bindName) == null)
            {
               String bind = null;
  -            if(interceptor instanceof CachedListInterceptor)
  +            if (interceptor instanceof CachedListInterceptor)
               {
                  bind = "execution(public String " + CachedListAbstract.class.getName() + "->toString())";
  -            } else if (interceptor instanceof CachedSetInterceptor)
  +            }
  +            else if (interceptor instanceof CachedSetInterceptor)
               {
                  bind = "execution(public String " + CachedSetImpl.class.getName() + "->toString())";
  -            } else if (interceptor instanceof CachedMapInterceptor)
  +            }
  +            else if (interceptor instanceof CachedMapInterceptor)
               {
                  bind = "execution(public String " + CachedMapImpl.class.getName() + "->toString())";
  -            } else
  +            }
  +            else
               {
                  throw new IllegalStateException("CollectionInterceptorUtil.createProxy(). Non Collection interceptor"
                  + interceptor);
  @@ -81,10 +84,11 @@
               AspectManager.instance().addBinding(bindingm);
      //         result._getInstanceAdvisor().addBinding(bindingm);
            }
  -      } catch (ParseException e)
  +      }
  +      catch (ParseException e)
         {
            throw new PojoCacheException("PojoUtil._attachInterceptor(): can't parse the field binding: "
  -                 +e);
  +                 + e);
         }
   
         return result;
  @@ -119,7 +123,8 @@
            try
            {
               ClassProxyFactory.newInstance(clazz);
  -         } catch (Exception e)
  +         }
  +         catch (Exception e)
            {
               throw new RuntimeException(e);
            }
  @@ -134,7 +139,8 @@
         try
         {
            tostring = Object.class.getDeclaredMethod("toString", new Class[0]);
  -      } catch (NoSuchMethodException e)
  +      }
  +      catch (NoSuchMethodException e)
         {
            e.printStackTrace();
            throw new RuntimeException("getManagedMathods: " + e);
  @@ -147,12 +153,13 @@
            for (int i = 0; i < methods.length; i++)
            {
               long hash = MethodHashing.methodHash(methods[i]);
  -            managedMethods.put(new Long(hash), methods[i]);
  +            managedMethods.put(hash, methods[i]);
            }
            // Add toString to ManagedMethod
            long hash = MethodHashing.methodHash(tostring);
  -         managedMethods.put(new Long(hash), tostring);
  -      } catch (Exception ignored)
  +         managedMethods.put(hash, tostring);
  +      }
  +      catch (Exception ignored)
         {
            ignored.printStackTrace();
         }
  @@ -171,7 +178,7 @@
            if (invocation instanceof MethodInvocation)
            {
               MethodInvocation methodInvocation = (MethodInvocation) invocation;
  -            Long methodHash = new Long(methodInvocation.getMethodHash());
  +            Long methodHash = methodInvocation.getMethodHash();
               Method method = (Method) managedMethods.get(methodHash);
               if (log.isTraceEnabled() && method != null)
               {
  @@ -181,7 +188,8 @@
               if (method != null)
               {
                  return method.invoke(interceptor, args);
  -            } else
  +            }
  +            else
               {
                  method = methodInvocation.getMethod();
                  if (method == null)
  
  
  


From msurtani at jboss.com  Sat Dec 30 14:48:50 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 14:48:50 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/jmx  ...
Message-ID: <E1H0kCI-0002Nq-OD@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 14:48:50

  Modified:    src-50/org/jboss/cache/pojo/jmx  JmxUtil.java
  Log:
  Genericised, autoboxed
  
  Revision  Changes    Path
  1.6       +17 -17    JBossCache/src-50/org/jboss/cache/pojo/jmx/JmxUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JmxUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/jmx/JmxUtil.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- JmxUtil.java	14 Nov 2006 21:53:00 -0000	1.5
  +++ JmxUtil.java	30 Dec 2006 19:48:50 -0000	1.6
  @@ -16,7 +16,7 @@
    * Various JMX related utilities
    *
    * @author Ben Wang
  - * @version $Id: JmxUtil.java,v 1.5 2006/11/14 21:53:00 bstansberry Exp $
  + * @version $Id: JmxUtil.java,v 1.6 2006/12/30 19:48:50 msurtani Exp $
    */
   public class JmxUtil extends org.jboss.cache.jmx.JmxUtil
   {
  @@ -39,7 +39,7 @@
      public static String getPojoCacheObjectName(org.jboss.cache.pojo.PojoCache cache)
      {
         // get the cache's registration name
  -      String tmpName = getCacheObjectName((CacheSPI)cache.getCache());
  +      String tmpName = getCacheObjectName((CacheSPI) cache.getCache());
         String newName = null;
         if (tmpName.startsWith(PREFIX))
         {
  @@ -49,9 +49,9 @@
         {
            newName = tmpName.replaceFirst(JBOSS_CACHE_DOMAIN, POJO_CACHE_DOMAIN);
         }
  -      else if (tmpName.indexOf(CACHE_TYPE_KEY) > -1)
  +      else if (tmpName.contains(CACHE_TYPE_KEY))
         {
  -         if (tmpName.indexOf(POJO_CACHE_TYPE) > -1)
  +         if (tmpName.contains(POJO_CACHE_TYPE))
               throw new IllegalStateException("Plain Cache ObjectName should not include " + POJO_CACHE_TYPE);
            
            int start = tmpName.indexOf(POJO_CACHE_TYPE);
  @@ -80,9 +80,9 @@
         {
            plainName = pojoCacheObjectName.replaceFirst(POJO_CACHE_DOMAIN, JBOSS_CACHE_DOMAIN);
         }
  -      else if (pojoCacheObjectName.indexOf(CACHE_TYPE_KEY) > -1)
  +      else if (pojoCacheObjectName.contains(CACHE_TYPE_KEY))
         {
  -         if (pojoCacheObjectName.indexOf(PLAIN_CACHE_TYPE) > -1)
  +         if (pojoCacheObjectName.contains(PLAIN_CACHE_TYPE))
               throw new IllegalStateException("PojoCache ObjectName should not include " + PLAIN_CACHE_TYPE);
            
            int start = pojoCacheObjectName.indexOf(PLAIN_CACHE_TYPE);
  
  
  


From validimir.ralev at jboss.com  Sat Dec 30 15:09:57 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 30 Dec 2006 15:09:57 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1
	- New directory ...
Message-ID: <E1H0kWj-0002qP-6A@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/30 15:09:57

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1 added to the repository


From validimir.ralev at jboss.com  Sat Dec 30 15:09:57 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 30 Dec 2006 15:09:57 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib
	- New directory ...
Message-ID: <E1H0kWj-0002qT-96@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/30 15:09:57

  Log:
  Directory /cvsroot/jboss//repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib added to the repository


From validimir.ralev at jboss.com  Sat Dec 30 15:10:37 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 30 Dec 2006 15:10:37 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1
	...
Message-ID: <E1H0kXN-0002tJ-8Y@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/30 15:10:37

  Added:       repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1 
                        component-info.xml
  Log:
  preselecte="no" packs are not being installed
  
  Revision  Changes    Path
  1.1      date: 2006/12/30 20:10:37;  author: vralev;  state: Exp;/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/component-info.xml
  
  Index: component-info.xml
  ===================================================================
  <project name="grouppackmapper">
  
    <component id="jboss/jboss-install-tools/grouppackmapper-anttask" licenseType="lgpl" version="1.0.1" projectHome="http://labs.jboss.com/portal/jemsinstaller/" description="Group to packs mapper for automated install">
      <artifact id="grouppackmapper-anttask-1.0.jar"/>
  
      <export>
        <include input="grouppackmapper-anttask-1.0.jar"/>
      </export>
    </component>
  </project>
  
  


From validimir.ralev at jboss.com  Sat Dec 30 15:10:37 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 30 Dec 2006 15:10:37 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib
	...
Message-ID: <E1H0kXN-0002tP-Bd@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/30 15:10:37

  Added:       repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib 
                        grouppackmapper-anttask-1.0.jar
  Log:
  preselecte="no" packs are not being installed
  
  Revision  Changes    Path
  1.1      date: 2006/12/30 20:10:37;  author: vralev;  state: Exp;/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib/grouppackmapper-anttask-1.0.jar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Sat Dec 30 15:22:45 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 30 Dec 2006 15:22:45 -0500
Subject: [jboss-cvs] /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib ...
Message-ID: <E1H0kj7-00034e-5a@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/30 15:22:45

  Modified:    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib  
                        standalone-compiler.jar compiler.jar
  Log:
  http://jira.jboss.com/jira/browse/JBINSTALL-175
  
  Revision  Changes    Path
  1.4       +253 -263  /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar
  
  	<<Binary file>>
  
  
  1.2       +35 -41    /repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/compiler.jar
  
  	<<Binary file>>
  
  


From validimir.ralev at jboss.com  Sat Dec 30 15:49:11 2006
From: validimir.ralev at jboss.com (Vladimir Ralev)
Date: Sat, 30 Dec 2006 15:49:11 -0500
Subject: [jboss-cvs]
	/repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib
	...
Message-ID: <E1H0l8h-0003Qw-Mt@committer01.frg.pub.inap.atl.jboss.com>

  User: vralev  
  Date: 06/12/30 15:49:11

  Modified:    repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib 
                        grouppackmapper-anttask-1.0.jar
  Log:
  http://jira.jboss.com/jira/browse/JBINSTALL-176
  
  Revision  Changes    Path
  1.2       +28 -14    /repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib/grouppackmapper-anttask-1.0.jar
  
  	<<Binary file>>
  
  


From ksf68g465gfhs at mail2world.com  Sat Dec 30 16:25:44 2006
From: ksf68g465gfhs at mail2world.com (ksf68g465gfhs at mail2world.com)
Date: Sat, 30 Dec 2006 16:25:44 -0500
Subject: [jboss-cvs] =?utf-8?b?wphBwpfCjcKRw5LCgsOBwoLDhMKCw6nCgsOxwoI=?=
	=?utf-8?b?w4XCgsK3woLCr8KCw4fCgUHCg1/Cg8KBwoLDiMKCw7HCgsOFwoLCtcKC?=
	=?utf-8?b?w6XCgsKkwoLCqcKBSA==?=
Message-ID: 20061231055419.87964mail@mail.ertyuisdhfjkeruisdhfjkertyuisdhfjkerytui.com

?A?????????????????????????????p?????????????????c
???????????C???????H
???????????????A???????????????????????c?B
?A???????????????????????????????A?????????????A???????????B
http://freeweb-freewoman.tv.ksjer.com/kodx/





From jboss-cvs-commits at lists.jboss.org  Sat Dec 30 16:52:54 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sat, 30 Dec 2006 16:52:54 -0500
Subject: [jboss-cvs] JBossAS SVN: r59250 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array test/org/jboss/test/aop/array
Message-ID: <E1H0m8M-0004Wz-3B@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-30 16:52:49 -0500 (Sat, 30 Dec 2006)
New Revision: 59250

Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java
Log:
A bit of tidying up

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-30 19:37:19 UTC (rev 59249)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayElementInvocation.java	2006-12-30 21:52:49 UTC (rev 59250)
@@ -21,6 +21,7 @@
 */ 
 package org.jboss.aop.array;
 
+import java.util.List;
 import java.util.Map;
 
 import org.jboss.aop.Advisor;
@@ -159,9 +160,9 @@
       throw new NotImplementedException();
    }
    
-   public void getReferences()
+   public List<ArrayReference> getArrayOwners()
    {
       ArrayRegistry registry = ArrayRegistry.getInstance();
-      registry.getArrayOwners(targetObject);
+      return registry.getArrayOwners(targetObject);
    }
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java	2006-12-30 19:37:19 UTC (rev 59249)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayReference.java	2006-12-30 21:52:49 UTC (rev 59250)
@@ -24,13 +24,49 @@
 import java.util.List;
 
 /**
+ * Contains information about one reference to a particular array. 
  * 
  * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
  * @version $Revision: 1.1 $
  */
 public interface ArrayReference
 {
+   /**
+    * @return The object containing the field with the array reference. If the root field is non static this 
+    * will be the reference of the instance, if the field is static it will be the class
+    */
    Object getRootObject();
+
+   /**
+    * @return The field with the array reference 
+    */
    String getRootField();
+   
+   /**
+    * If the root field is a direct reference to the array this will be null. If the field is an array and the reference is from within 
+    * a nested array, this will be a list of the indexes from the top to get to the array.<BR/>
+    * 
+    * So if we have:
+    * <pre>
+    * class POJO{
+    *   int[] i;
+    * }
+    * POJO pojo = new POJO();
+    * int[] i arr = new int[]{1};
+    * pojo.i = arr;
+    * </pre>
+    *  getNestedArrayIndices will be null for arr.If we have:
+    * <pre>
+    * class POJO{
+    *   int[][][] i;
+    * }
+    * POJO pojo = new POJO();
+    * int[] arr = new int[]{1};
+    * pojo.i = new int[][][]{new int[][]{new int[]{1}}, new int[][]{new int[]{2}, new int[]{3}, arr}};
+    * </pre>
+    *  getNestedArrayIndices will {1,2} for arr.
+
+    * @ return the nested indices of the array.  
+    */
    List<Integer> getNestedArrayIndices();
 }

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-30 19:37:19 UTC (rev 59249)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ArrayRegistry.java	2006-12-30 21:52:49 UTC (rev 59250)
@@ -194,7 +194,6 @@
 
    public List<ArrayReference> getArrayOwners(Object array)
    {
-      System.out.println("----> getArrayOwners " + array);
       Lock readLock = lock.readLock();
       readLock.lock();
       

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java	2006-12-30 19:37:19 UTC (rev 59249)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/ArrayReferenceTestCase.java	2006-12-30 21:52:49 UTC (rev 59250)
@@ -468,4 +468,23 @@
       references = registry.getArrayOwners(arr);
       assertNull(references);
    }
+   
+   public void testArrayReferenceFromInvocation()
+   {
+      ClassForReference obj = new ClassForReference();
+      int[] arr = new int[] {1, 2, 3};
+      Object[][][][] fieldA = new Object[][][][] {null, null, new Object[][][] {null, new Object[][] {null, null, new Object[] {null, null, null, null}}}}; //2, 1, 2, 3
+      obj.fieldA = fieldA;
+      TestArrayElementInterceptor.clear();
+      fieldA[2][1][2][3] = "X";
+      assertEquals(1, TestArrayElementInterceptor.owners.size());
+      
+      ArrayReference reference = TestArrayElementInterceptor.owners.get(0);
+      assertEquals(obj, reference.getRootObject());
+      assertEquals("fieldA", reference.getRootField());
+      assertEquals(3, reference.getNestedArrayIndices().size());
+      assertEquals(new Integer(2), reference.getNestedArrayIndices().get(0));
+      assertEquals(new Integer(1), reference.getNestedArrayIndices().get(1));
+      assertEquals(new Integer(2), reference.getNestedArrayIndices().get(2));
+   }
 }

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java	2006-12-30 19:37:19 UTC (rev 59249)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java	2006-12-30 21:52:49 UTC (rev 59250)
@@ -21,9 +21,13 @@
 */ 
 package org.jboss.test.aop.array;
 
+import java.util.List;
+
 import org.jboss.aop.advice.Interceptor;
 import org.jboss.aop.array.ArrayElementReadInvocation;
 import org.jboss.aop.array.ArrayElementWriteInvocation;
+import org.jboss.aop.array.ArrayReference;
+import org.jboss.aop.array.ArrayRegistry;
 import org.jboss.aop.joinpoint.Invocation;
 
 /**
@@ -35,11 +39,13 @@
 {
    public static int index;
    public static Object value;
+   public static List<ArrayReference> owners;
    
    public static void clear()
    {
       index = -1;
       value = null;
+      owners = null;
    }
    
    public String getName()
@@ -59,7 +65,7 @@
          index = ((ArrayElementWriteInvocation)invocation).getIndex();
          value = ((ArrayElementWriteInvocation)invocation).getValue();
       } 
-      
+      owners = ArrayRegistry.getInstance().getArrayOwners(invocation.getTargetObject());
       invocation.getMetaData().addMetaData("test", "invoked", "TestArrayElementInterceptor");
       return invocation.invokeNext();
    }



From Shane_Bryzak at symantec.com  Sat Dec 30 20:18:31 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:18:31 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security  ...
Message-ID: <E1H0pLL-0008D1-R9@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:18:31

  Modified:    src/main/org/jboss/seam/security  SeamSecurityManager.java
  Log:
  removed proprietary authentication stuff, replaced with JAAS authentication
  
  Revision  Changes    Path
  1.32      +13 -0     jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SeamSecurityManager.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/SeamSecurityManager.java,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -b -r1.31 -r1.32
  --- SeamSecurityManager.java	22 Dec 2006 02:03:08 -0000	1.31
  +++ SeamSecurityManager.java	31 Dec 2006 01:18:31 -0000	1.32
  @@ -8,6 +8,10 @@
   import java.util.ArrayList;
   import java.util.List;
   
  +import javax.security.auth.Subject;
  +import javax.security.auth.login.LoginContext;
  +import javax.security.auth.login.LoginException;
  +
   import org.drools.FactHandle;
   import org.drools.RuleBase;
   import org.drools.RuleBaseFactory;
  @@ -28,6 +32,7 @@
   import org.jboss.seam.core.Expressions;
   import org.jboss.seam.log.LogProvider;
   import org.jboss.seam.log.Logging;
  +import org.jboss.seam.security.config.SecurityConfiguration;
   import org.jboss.seam.security.rules.PermissionCheck;
   import org.jboss.seam.util.Resources;
   
  @@ -205,4 +210,12 @@
   
         return wm;
      }
  +   
  +   public LoginContext createLoginContext()
  +       throws LoginException
  +   {
  +      Subject s = new Subject();
  +      return new LoginContext(SecurityConfiguration.LOGIN_MODULE_NAME, s, null,
  +            SecurityConfiguration.instance().getLoginModuleConfiguration());
  +   }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 20:18:31 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:18:31 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1H0pLL-0008D8-VG@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:18:31

  Modified:    src/main/org/jboss/seam/security/config 
                        SecurityConfiguration.java
  Log:
  removed proprietary authentication stuff, replaced with JAAS authentication
  
  Revision  Changes    Path
  1.8       +384 -273  jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SecurityConfiguration.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/main/org/jboss/seam/security/config/SecurityConfiguration.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- SecurityConfiguration.java	27 Dec 2006 05:03:49 -0000	1.7
  +++ SecurityConfiguration.java	31 Dec 2006 01:18:31 -0000	1.8
  @@ -1,28 +1,37 @@
   package org.jboss.seam.security.config;
   
  +import static org.jboss.seam.ScopeType.APPLICATION;
  +import static org.jboss.seam.annotations.Install.BUILT_IN;
  +
   import java.io.InputStream;
  +import java.util.ArrayList;
   import java.util.HashMap;
   import java.util.HashSet;
   import java.util.List;
   import java.util.Map;
   import java.util.Set;
   
  -import org.jboss.seam.log.LogProvider;
  -import org.jboss.seam.log.Logging;
  +import javax.security.auth.login.AppConfigurationEntry;
  +import javax.security.auth.login.Configuration;
  +
   import org.dom4j.Document;
   import org.dom4j.Element;
   import org.dom4j.io.SAXReader;
  -import static org.jboss.seam.ScopeType.APPLICATION;
  +import org.jboss.seam.Component;
   import org.jboss.seam.InterceptionType;
  -import static org.jboss.seam.annotations.Install.BUILT_IN;
  +import org.jboss.seam.ScopeType;
   import org.jboss.seam.annotations.Create;
   import org.jboss.seam.annotations.Install;
   import org.jboss.seam.annotations.Intercept;
   import org.jboss.seam.annotations.Name;
   import org.jboss.seam.annotations.Scope;
   import org.jboss.seam.annotations.Startup;
  +import org.jboss.seam.contexts.Contexts;
  +import org.jboss.seam.log.LogProvider;
  +import org.jboss.seam.log.Logging;
   import org.jboss.seam.security.Role;
   import org.jboss.seam.security.SeamPermission;
  +import org.jboss.seam.security.SeamSecurityManager;
   import org.jboss.seam.util.Resources;
   
   /**
  @@ -33,48 +42,74 @@
   @Startup
   @Scope(APPLICATION)
   @Name("org.jboss.seam.security.securityConfiguration")
  - at Install(value = false, precedence=BUILT_IN, dependencies = "org.jboss.seam.securityManager")
  + at Install(value = false, precedence = BUILT_IN, dependencies = "org.jboss.seam.securityManager")
   @Intercept(InterceptionType.NEVER)
   public class SecurityConfiguration
   {
  +   public static final String LOGIN_MODULE_NAME = "default";
  +   
     private static final String SECURITY_CONFIG_FILENAME = "/META-INF/security-config.xml";
   
  -  private static final LogProvider log = Logging.getLogProvider(SecurityConfiguration.class);
  +   private static final LogProvider log = Logging
  +         .getLogProvider(SecurityConfiguration.class);
   
     // <security-constraint>
     private static final String SECURITY_CONSTRAINT = "security-constraint";
  +
     private static final String WEB_RESOURCE_COLLECTION = "web-resource-collection";
  +
     private static final String URL_PATTERN = "url-pattern";
  +
     private static final String HTTP_METHOD = "http-method";
  +
     private static final String AUTH_CONSTRAINT = "auth-constraint";
  +
     private static final String ROLE_NAME = "role-name";
   
     // <login-config>
  -//  private static final String LOGIN_CONFIG = "login-config";
  -//  private static final String AUTH_METHOD = "auth-method";
  +   // private static final String LOGIN_CONFIG = "login-config";
  +   // private static final String AUTH_METHOD = "auth-method";
   
     // FORM
  -//  private static final String FORM_LOGIN_CONFIG = "form-login-config";
  -//  private static final String FORM_LOGIN_PAGE = "form-login-page";
  -//  private static final String FORM_ERROR_PAGE = "form-error-page";
  -//  private static final String FORM_DEFAULT_PAGE = "form-default-page";
  +   // private static final String FORM_LOGIN_CONFIG = "form-login-config";
  +   // private static final String FORM_LOGIN_PAGE = "form-login-page";
  +   // private static final String FORM_ERROR_PAGE = "form-error-page";
  +   // private static final String FORM_DEFAULT_PAGE = "form-default-page";
   
     // roles
     private static final String SECURITY_ROLES = "roles";
  +
     private static final String SECURITY_ROLE = "role";
  +
     private static final String SECURITY_MEMBERSHIPS = "memberships";
  +
     private static final String SECURITY_PERMISSIONS = "permissions";
  +
     private static final String SECURITY_PERMISSION = "permission";
   
  +   private static final String LOGIN_MODULES = "loginmodules";
  +
  +   private static final String LOGIN_MODULE = "loginmodule";
  +
  +   private static final String LOGIN_MODULE_CLASS = "class";
  +
  +   private static final String LOGIN_MODULE_FLAG = "flag";
  +
  +   private static final String LOGIN_MODULE_OPTION = "option";
  +   
  +   private static final String LOGIN_MODULE_OPTION_NAME = "name";
  +
     private Set<SecurityConstraint> securityConstraints = new HashSet<SecurityConstraint>();
   
  -  private Map<String,Role> securityRoles = new HashMap<String,Role>();
  +   private Map<String, Role> securityRoles = new HashMap<String, Role>();
   
     private String securityErrorPage = "/securityError.seam";
   
  -//  private AuthMethod authMethod;
  +   private LoginModuleConfiguration loginModuleConfig;
   
  -//  private Handler authenticator;
  +   // private AuthMethod authMethod;
  +
  +   // private Handler authenticator;
   
     /**
      * Initialization
  @@ -82,14 +117,31 @@
      * @throws SecurityConfigException
      */
     @Create
  -  public void init()
  -      throws SecurityConfigException
  +   public void init() throws SecurityConfigException
     {
       InputStream in = Resources.getResourceAsStream(SECURITY_CONFIG_FILENAME);
       if (in != null)
         loadConfigFromStream(in);
       else
  -      log.warn(String.format("Security configuration file %s not found", SECURITY_CONFIG_FILENAME));
  +         log.warn(String.format("Security configuration file %s not found",
  +               SECURITY_CONFIG_FILENAME));
  +   }
  +
  +   public static SecurityConfiguration instance()
  +   {
  +      if (!Contexts.isApplicationContextActive())
  +         throw new IllegalStateException("No active application context");
  +
  +      SecurityConfiguration instance = (SecurityConfiguration) Component
  +            .getInstance(SecurityConfiguration.class, ScopeType.APPLICATION);
  +
  +      if (instance == null)
  +      {
  +         throw new IllegalStateException(
  +               "No SecurityConfiguration could be created, make sure the Component exists in application scope");
  +      }
  +
  +      return instance;
     }
   
     public void setSecurityErrorPage(String securityErrorPage)
  @@ -128,7 +180,8 @@
         if (ex instanceof SecurityConfigException)
           throw (SecurityConfigException) ex;
         else
  -        throw new SecurityConfigException("Error loading security configuration", ex);
  +            throw new SecurityConfigException(
  +                  "Error loading security configuration", ex);
       }
     }
   
  @@ -143,23 +196,31 @@
     }
   
     /**
  +    * Returns the login module configuration
      *
  -   * @return AuthMethod
  +    * @return
      */
  -//  public AuthMethod getAuthMethod()
  -//  {
  -//    return authMethod;
  -//  }
  +   public Configuration getLoginModuleConfiguration()
  +   {
  +      return loginModuleConfig;
  +   }
   
     /**
      *
  +    * @return AuthMethod
  +    */
  +   // public AuthMethod getAuthMethod()
  +   // {
  +   // return authMethod;
  +   // }
  +   /**
  +    * 
      * @return Authenticator
      */
  -//  public Handler getAuthenticator()
  -//  {
  -//    return authenticator;
  -//  }
  -
  +   // public Handler getAuthenticator()
  +   // {
  +   // return authenticator;
  +   // }
     /**
      *
      * @return Set
  @@ -185,37 +246,38 @@
           SecurityConstraint securityConstraint = new SecurityConstraint();
           securityConstraints.add(securityConstraint);
   
  -        for (Element wrcElement :
  -            (List<Element>) element.elements(WEB_RESOURCE_COLLECTION))
  +            for (Element wrcElement : (List<Element>) element
  +                  .elements(WEB_RESOURCE_COLLECTION))
           {
             WebResourceCollection wrc = new WebResourceCollection();
             securityConstraint.getResourceCollections().add(wrc);
   
  -          for (Element urlPatternElement :
  -              (List<Element>) wrcElement.elements(URL_PATTERN))
  +               for (Element urlPatternElement : (List<Element>) wrcElement
  +                     .elements(URL_PATTERN))
             {
               wrc.getUrlPatterns().add(urlPatternElement.getTextTrim());
             }
   
  -          for (Element httpMethodElement :
  -              (List<Element>) wrcElement.elements(HTTP_METHOD))
  +               for (Element httpMethodElement : (List<Element>) wrcElement
  +                     .elements(HTTP_METHOD))
             {
               wrc.getHttpMethods().add(httpMethodElement.getTextTrim());
             }
           }
   
           securityConstraint.setAuthConstraint(new AuthConstraint());
  -        for (Element roleNameElement :
  -            (List<Element>) element.element(AUTH_CONSTRAINT).elements(ROLE_NAME))
  +            for (Element roleNameElement : (List<Element>) element.element(
  +                  AUTH_CONSTRAINT).elements(ROLE_NAME))
           {
  -          securityConstraint.getAuthConstraint().getRoles().add(roleNameElement.
  -              getTextTrim());
  +               securityConstraint.getAuthConstraint().getRoles().add(
  +                     roleNameElement.getTextTrim());
           }
         }
       }
       catch (Exception ex)
       {
  -      throw new SecurityConfigException("Error loading security constraints", ex);
  +         throw new SecurityConfigException(
  +               "Error loading security constraints", ex);
       }
     }
   
  @@ -225,53 +287,55 @@
      * @param loginConfigElement Element
      * @throws SecurityConfigurationException
      */
  -//  private void loadLoginConfig(Element loginConfigElement)
  -//      throws SecurityConfigException
  -//  {
  -//    String authMethodText = loginConfigElement.element(AUTH_METHOD).getTextTrim();
  -//    try
  -//    {
  -//      authMethod = AuthMethod.valueOf(authMethodText);
  -//    }
  -//    catch (Exception ex)
  -//    {
  -//      StringBuilder sb = new StringBuilder();
  -//      for (AuthMethod m : AuthMethod.values())
  -//      {
  -//        if (sb.length() > 0)
  -//          sb.append(',');
  -//        sb.append(m.toString());
  -//      }
  -//
  -//      throw new SecurityConfigException(
  -//          String.format("Invalid auth-method [%s].  Valid options are: %s",
  -//                        authMethodText, sb.toString()));
  -//    }
  -//
  -//    switch (authMethod)
  -//    {
  -//      case BASIC:
  -//        authenticator = new BasicHandler();
  -//        break;
  -//      case FORM:
  -//        Element formConfigElement = loginConfigElement.element(FORM_LOGIN_CONFIG);
  -//        String loginPage = formConfigElement.elementText(FORM_LOGIN_PAGE);
  -//        String errorPage = formConfigElement.elementText(FORM_ERROR_PAGE);
  -//        String defaultPage = formConfigElement.elementText(FORM_DEFAULT_PAGE);
  -//        authenticator = new FormHandler(loginPage, errorPage, defaultPage);
  -//        break;
  -//      case SEAM:
  -//        Element seamConfigElement = loginConfigElement.element(SEAM_LOGIN_CONFIG);
  -//        loginPage = seamConfigElement.elementText(SEAM_LOGIN_PAGE);
  -//        authenticator = new SeamAuthenticator(loginPage);
  -//        break;
  -//    }
  -//
  -//    if (authenticator == null)
  -//      throw new SecurityConfigException(
  -//        String.format("No valid authenticator for auth-method [%s]", authMethod.toString()));
  -//
  -//  }
  +   // private void loadLoginConfig(Element loginConfigElement)
  +   // throws SecurityConfigException
  +   // {
  +   // String authMethodText =
  +   // loginConfigElement.element(AUTH_METHOD).getTextTrim();
  +   // try
  +   // {
  +   // authMethod = AuthMethod.valueOf(authMethodText);
  +   // }
  +   // catch (Exception ex)
  +   // {
  +   // StringBuilder sb = new StringBuilder();
  +   // for (AuthMethod m : AuthMethod.values())
  +   // {
  +   // if (sb.length() > 0)
  +   // sb.append(',');
  +   // sb.append(m.toString());
  +   // }
  +   //
  +   // throw new SecurityConfigException(
  +   // String.format("Invalid auth-method [%s]. Valid options are: %s",
  +   // authMethodText, sb.toString()));
  +   // }
  +   //
  +   // switch (authMethod)
  +   // {
  +   // case BASIC:
  +   // authenticator = new BasicHandler();
  +   // break;
  +   // case FORM:
  +   // Element formConfigElement = loginConfigElement.element(FORM_LOGIN_CONFIG);
  +   // String loginPage = formConfigElement.elementText(FORM_LOGIN_PAGE);
  +   // String errorPage = formConfigElement.elementText(FORM_ERROR_PAGE);
  +   // String defaultPage = formConfigElement.elementText(FORM_DEFAULT_PAGE);
  +   // authenticator = new FormHandler(loginPage, errorPage, defaultPage);
  +   // break;
  +   // case SEAM:
  +   // Element seamConfigElement = loginConfigElement.element(SEAM_LOGIN_CONFIG);
  +   // loginPage = seamConfigElement.elementText(SEAM_LOGIN_PAGE);
  +   // authenticator = new SeamAuthenticator(loginPage);
  +   // break;
  +   // }
  +   //
  +   // if (authenticator == null)
  +   // throw new SecurityConfigException(
  +   // String.format("No valid authenticator for auth-method [%s]",
  +   // authMethod.toString()));
  +   //
  +   // }
   
     /**
      * Load the security roles
  @@ -282,9 +346,10 @@
     protected void loadSecurityRoles(Element securityRoleElement)
         throws SecurityConfigException
     {
  -    Map<String,Set<String>> members = new HashMap<String,Set<String>>();
  +      Map<String, Set<String>> members = new HashMap<String, Set<String>>();
   
  -    for (Element role : (List<Element>) securityRoleElement.elements(SECURITY_ROLE))
  +      for (Element role : (List<Element>) securityRoleElement
  +            .elements(SECURITY_ROLE))
       {
         Role r = new Role(role.attributeValue("name"));
   
  @@ -301,11 +366,12 @@
         Element permissionsElement = role.element(SECURITY_PERMISSIONS);
         if (permissionsElement != null)
         {
  -        for (Element permission : (List<Element>) permissionsElement.elements(
  -            SECURITY_PERMISSION))
  +            for (Element permission : (List<Element>) permissionsElement
  +                  .elements(SECURITY_PERMISSION))
           {
  -          r.addPermission(new SeamPermission(permission.attributeValue("name"),
  -                                             permission.attributeValue("action")));
  +               r.addPermission(new SeamPermission(permission
  +                     .attributeValue("name"), permission
  +                     .attributeValue("action")));
           }
         }
   
  @@ -320,4 +386,49 @@
       }
     }
   
  +   protected void loadLoginModules(Element loginModulesElement)
  +         throws SecurityConfigException
  +   {
  +      loginModuleConfig = new LoginModuleConfiguration();
  +      List<AppConfigurationEntry> entries = new ArrayList<AppConfigurationEntry>();
  +
  +      for (Element loginModule : (List<Element>) loginModulesElement
  +            .elements(LOGIN_MODULE))
  +      {
  +         Map<String, String> options = new HashMap<String, String>();
  +
  +         for (Element option : (List<Element>) loginModule.elements(LOGIN_MODULE_OPTION))
  +         {
  +            options.put(option.attributeValue(LOGIN_MODULE_OPTION_NAME), 
  +                        option.getTextTrim());
  +         }
  +         
  +         AppConfigurationEntry entry = new AppConfigurationEntry(loginModule
  +               .attributeValue(LOGIN_MODULE_CLASS), getControlFlag(loginModule
  +               .attributeValue(LOGIN_MODULE_FLAG)), options);
  +         entries.add(entry);
  +      }
  +      
  +      AppConfigurationEntry[] e = new AppConfigurationEntry[entries.size()];
  +      entries.toArray(e);
  +      
  +      loginModuleConfig.addEntry(LOGIN_MODULE_NAME, e);
  +      
  +   }
  +
  +   private AppConfigurationEntry.LoginModuleControlFlag getControlFlag(
  +         String flag) throws SecurityConfigException
  +   {
  +      if ("REQUIRED".equalsIgnoreCase(flag))
  +         return AppConfigurationEntry.LoginModuleControlFlag.REQUIRED;
  +      else if ("OPTIONAL".equalsIgnoreCase(flag))
  +         return AppConfigurationEntry.LoginModuleControlFlag.OPTIONAL;
  +      else if ("SUFFICIENT".equalsIgnoreCase(flag))
  +         return AppConfigurationEntry.LoginModuleControlFlag.SUFFICIENT;
  +      else if ("REQUISITE".equalsIgnoreCase(flag))
  +         return AppConfigurationEntry.LoginModuleControlFlag.REQUISITE;
  +      else
  +         throw new SecurityConfigException(String.format(
  +               "Unrecognized login module control flag [%s]", flag));
  +   }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 20:18:32 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:18:32 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/adapter  ...
Message-ID: <E1H0pLM-0008DC-3o@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:18:32

  Removed:     src/main/org/jboss/seam/security/adapter 
                        AuthenticationAdapter.java
  Log:
  removed proprietary authentication stuff, replaced with JAAS authentication


From Shane_Bryzak at symantec.com  Sat Dec 30 20:18:32 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:18:32 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/authenticator
	...
Message-ID: <E1H0pLM-0008DG-86@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:18:32

  Removed:     src/main/org/jboss/seam/security/authenticator  
                        Authenticator.java ProviderAuthenticator.java
  Log:
  removed proprietary authentication stuff, replaced with JAAS authentication


From Shane_Bryzak at symantec.com  Sat Dec 30 20:18:32 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:18:32 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/provider ...
Message-ID: <E1H0pLM-0008DK-Bz@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:18:32

  Removed:     src/main/org/jboss/seam/security/provider 
                        AuthenticationProvider.java
  Log:
  removed proprietary authentication stuff, replaced with JAAS authentication


From Shane_Bryzak at symantec.com  Sat Dec 30 20:26:42 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:26:42 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/META-INF  ...
Message-ID: <E1H0pTG-0008MZ-Fu@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:26:42

  Modified:    examples/seamspace/resources/META-INF  security-config.xml
  Log:
  use login module instead of auth provider
  
  Revision  Changes    Path
  1.3       +4 -0      jboss-seam/examples/seamspace/resources/META-INF/security-config.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: security-config.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/META-INF/security-config.xml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- security-config.xml	30 Dec 2006 14:05:23 -0000	1.2
  +++ security-config.xml	31 Dec 2006 01:26:42 -0000	1.3
  @@ -44,4 +44,8 @@
       
     </roles>
   
  +  <loginmodules>
  +    <loginmodule class="org.jboss.seam.example.seamspace.AuthenticatorAction" flag="required"/>
  +  </loginmodules>
  +
   </security-config>
  \ No newline at end of file
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 20:26:42 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:26:42 -0500
Subject: [jboss-cvs] jboss-seam/examples/seamspace/resources/WEB-INF  ...
Message-ID: <E1H0pTG-0008Mg-J6@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:26:42

  Modified:    examples/seamspace/resources/WEB-INF  components.xml
  Log:
  use login module instead of auth provider
  
  Revision  Changes    Path
  1.10      +0 -5      jboss-seam/examples/seamspace/resources/WEB-INF/components.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: components.xml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/resources/WEB-INF/components.xml,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -b -r1.9 -r1.10
  --- components.xml	30 Dec 2006 14:05:23 -0000	1.9
  +++ components.xml	31 Dec 2006 01:26:42 -0000	1.10
  @@ -17,11 +17,6 @@
           <property name="persistenceUnitJndiName">java:/seamspaceEntityManagerFactory</property>
       </component>    
   
  -    <component class="org.jboss.seam.security.authenticator.ProviderAuthenticator">
  -      <property name="providers">#{authenticatorAction}</property>
  -      <property name="flags">required</property>
  -    </component>
  -    
       <component class="org.jboss.seam.security.SeamSecurityManager"/>
       <component class="org.jboss.seam.security.config.SecurityConfiguration"/>
           
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 20:26:42 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:26:42 -0500
Subject: [jboss-cvs]
	jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace ...
Message-ID: <E1H0pTG-0008Mn-Ny@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:26:42

  Modified:    examples/seamspace/src/org/jboss/seam/example/seamspace 
                        AuthenticatorAction.java
  Log:
  use login module instead of auth provider
  
  Revision  Changes    Path
  1.3       +63 -34    jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AuthenticatorAction.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AuthenticatorAction.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/seamspace/src/org/jboss/seam/example/seamspace/AuthenticatorAction.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- AuthenticatorAction.java	14 Dec 2006 04:12:21 -0000	1.2
  +++ AuthenticatorAction.java	31 Dec 2006 01:26:42 -0000	1.3
  @@ -1,14 +1,17 @@
   package org.jboss.seam.example.seamspace;
   
  +import java.util.Map;
  +
   import javax.persistence.EntityManager;
   import javax.persistence.NoResultException;
  +import javax.security.auth.Subject;
  +import javax.security.auth.callback.CallbackHandler;
  +import javax.security.auth.login.LoginException;
  +import javax.security.auth.spi.LoginModule;
   
   import org.jboss.seam.annotations.In;
   import org.jboss.seam.annotations.Name;
  -import org.jboss.seam.security.Identity;
   import org.jboss.seam.security.AuthenticationException;
  -import org.jboss.seam.security.UsernamePasswordToken;
  -import org.jboss.seam.security.provider.AuthenticationProvider;
   import org.jboss.seam.security.Role;
   
   /**
  @@ -17,20 +20,39 @@
    * @author Shane Bryzak
    */
   @Name("authenticatorAction")
  -public class AuthenticatorAction implements AuthenticationProvider
  +public class AuthenticatorAction implements LoginModule
   {
  +   private Subject subject;
  +   
     @In(create=true)
       private EntityManager entityManager;
   
  -  public Identity authenticate(Identity authentication)
  -      throws AuthenticationException
  +  public boolean abort() throws LoginException
  +   {
  +      // TODO Auto-generated method stub
  +      return false;
  +   }
  +
  +   public boolean commit() throws LoginException
  +   {
  +      // TODO Auto-generated method stub
  +      return false;
  +   }
  +
  +   public void initialize(Subject subject, CallbackHandler callbackHandler, 
  +         Map<String, ?> sharedState, Map<String, ?> options)
  +   {
  +      this.subject = subject;     
  +   }
  +
  +   public boolean login() throws LoginException
     {
       try
       {
         Member member = (Member) entityManager.createQuery(
             "from Member where username = :username and password = :password")
  -          .setParameter("username", authentication.getPrincipal().toString())
  -          .setParameter("password", authentication.getCredentials())
  +//            .setParameter("username", auth.getPrincipal().toString())
  +//            .setParameter("password", auth.getCredentials())
             .getSingleResult();
   
         Role[] roles = new Role[member.getRoles().size()];
  @@ -38,8 +60,9 @@
         for (MemberRole mr : member.getRoles())
           roles[idx++] = new Role(mr.getName());
   
  -      return new UsernamePasswordToken(authentication.getPrincipal(),
  -                                       authentication.getCredentials(), roles);
  +//        return new UsernamePasswordToken(authentication.getPrincipal(),
  +//                                         authentication.getCredentials(), roles);
  +        return true;
       }
       catch (NoResultException ex)
       {
  @@ -50,4 +73,10 @@
         throw new AuthenticationException("Unknown authentication error", ex);
       }
     }
  +
  +   public boolean logout() throws LoginException
  +   {
  +      // TODO Auto-generated method stub
  +      return false;
  +   }
   }
  
  
  


From Shane_Bryzak at symantec.com  Sat Dec 30 20:31:14 2006
From: Shane_Bryzak at symantec.com (Shane Bryzak)
Date: Sat, 30 Dec 2006 20:31:14 -0500
Subject: [jboss-cvs] jboss-seam/src/main/org/jboss/seam/security/config  ...
Message-ID: <E1H0pXe-0008Q1-IY@committer01.frg.pub.inap.atl.jboss.com>

  User: sbryzak2
  Date: 06/12/30 20:31:14

  Added:       src/main/org/jboss/seam/security/config 
                        LoginModuleConfiguration.java
  Log:
  login module configuration
  
  Revision  Changes    Path
  1.1      date: 2006/12/31 01:31:14;  author: sbryzak2;  state: Exp;jboss-seam/src/main/org/jboss/seam/security/config/LoginModuleConfiguration.java
  
  Index: LoginModuleConfiguration.java
  ===================================================================
  package org.jboss.seam.security.config;
  
  import java.util.HashMap;
  import java.util.Map;
  
  import javax.security.auth.login.AppConfigurationEntry;
  import javax.security.auth.login.Configuration;
  
  /**
   * Implementation of a LoginModule Configuration.
   * 
   * @author Shane Bryzak
   */
  public class LoginModuleConfiguration extends Configuration
  {
     private Map<String,AppConfigurationEntry[]> entries = new HashMap<String,AppConfigurationEntry[]>();
  
     public void addEntry(String name, AppConfigurationEntry[] value)
     {
        entries.put(name, value);
     }
     
     @Override
     public AppConfigurationEntry[] getAppConfigurationEntry(String name)
     {
        return entries.get(name);
     }
  
     @Override
     public void refresh()
     {
  
     }
  }
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:39 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:39 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/notifications
	...
Message-ID: <E1H0q7r-0000hh-SY@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:39

  Modified:    tests/functional/org/jboss/cache/notifications  
                        RemoteCacheListenerTest.java CacheListenerTest.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.4       +1 -1      JBossCache/tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoteCacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- RemoteCacheListenerTest.java	30 Dec 2006 17:49:59 -0000	1.3
  +++ RemoteCacheListenerTest.java	31 Dec 2006 02:08:39 -0000	1.4
  @@ -225,7 +225,7 @@
   
         n1.move(n2);
         //expected
  -      Fqn newFqn = new Fqn(newParent, fqn.getLast());
  +      Fqn newFqn = new Fqn(newParent, fqn.getLastElement());
         List<RemoteCacheListenerTest.Event> expected = new ArrayList<RemoteCacheListenerTest.Event>();
         expected.add(new RemoteCacheListenerTest.Event(RemoteCacheListenerTest.ListenerMethod.NODE_MODIFIED, fqn, true, false, null));
         expected.add(new RemoteCacheListenerTest.Event(RemoteCacheListenerTest.ListenerMethod.NODE_MODIFIED, newFqn, true, false, null));
  
  
  
  1.11      +1 -1      JBossCache/tests/functional/org/jboss/cache/notifications/CacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/notifications/CacheListenerTest.java,v
  retrieving revision 1.10
  retrieving revision 1.11
  diff -u -b -r1.10 -r1.11
  --- CacheListenerTest.java	30 Dec 2006 17:49:59 -0000	1.10
  +++ CacheListenerTest.java	31 Dec 2006 02:08:39 -0000	1.11
  @@ -208,7 +208,7 @@
   
         n1.move(n2);
         //expected
  -      Fqn newFqn = new Fqn(newParent, fqn.getLast());
  +      Fqn newFqn = new Fqn(newParent, fqn.getLastElement());
         List<Event> expected = new ArrayList<Event>();
         expected.add(new Event(ListenerMethod.NODE_MODIFIED, fqn, true, false, null));
         expected.add(new Event(ListenerMethod.NODE_MODIFIED, newFqn, true, false, null));
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:40 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:40 -0500
Subject: [jboss-cvs]
	JBossCache/tests/functional/org/jboss/cache/options/cachemodelocal ...
Message-ID: <E1H0q7s-0000ho-0L@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:40

  Modified:    tests/functional/org/jboss/cache/options/cachemodelocal 
                        CacheModeLocalTestBase.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.9       +1 -1      JBossCache/tests/functional/org/jboss/cache/options/cachemodelocal/CacheModeLocalTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheModeLocalTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/options/cachemodelocal/CacheModeLocalTestBase.java,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -b -r1.8 -r1.9
  --- CacheModeLocalTestBase.java	30 Dec 2006 17:50:01 -0000	1.8
  +++ CacheModeLocalTestBase.java	31 Dec 2006 02:08:39 -0000	1.9
  @@ -195,7 +195,7 @@
            Assert.assertEquals("value", cache2.get(fqn, key));
   
         cache1.getInvocationContext().getOptionOverrides().setCacheModeLocal(true);
  -      cache1.remove(fqn);
  +      cache1.removeNode(fqn);
         delay();
   
         // should be removed in cache1
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:40 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:40 -0500
Subject: [jboss-cvs] JBossCache/tests/perf/org/jboss/cache       ...
Message-ID: <E1H0q7s-0000iA-5a@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:40

  Modified:    tests/perf/org/jboss/cache      
                        ReplicatedSyncMapPerfTest.java LocalPerfTest.java
                        ReplicatedAsyncPerfTest.java
                        ReplicatedSyncPerfTest.java
                        ReplicatedAsyncMapPerfTest.java
                        LocalMapPerfTest.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.7       +2 -2      JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncMapPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedSyncMapPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncMapPerfTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- ReplicatedSyncMapPerfTest.java	30 Dec 2006 17:50:00 -0000	1.6
  +++ ReplicatedSyncMapPerfTest.java	31 Dec 2006 02:08:40 -0000	1.7
  @@ -32,7 +32,7 @@
    * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class ReplicatedSyncMapPerfTest extends TestCase
   {
  @@ -349,7 +349,7 @@
   
      private void log(String str)
      {
  -//     System.out.println(this.getClass().getName() +": " +str);
  +//     System.out.println(this.getClass().getLastElementAsString() +": " +str);
         System.out.println(str);
      }
   
  
  
  
  1.7       +2 -2      JBossCache/tests/perf/org/jboss/cache/LocalPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/LocalPerfTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- LocalPerfTest.java	30 Dec 2006 17:50:00 -0000	1.6
  +++ LocalPerfTest.java	31 Dec 2006 02:08:40 -0000	1.7
  @@ -30,7 +30,7 @@
    * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class LocalPerfTest extends TestCase
   {
  @@ -327,7 +327,7 @@
   
      private void log(String str)
      {
  -//     System.out.println(this.getClass().getName() +": " +str);
  +//     System.out.println(this.getClass().getLastElementAsString() +": " +str);
         System.out.println(str);
      }
   
  
  
  
  1.6       +2 -2      JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedAsyncPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncPerfTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ReplicatedAsyncPerfTest.java	30 Dec 2006 17:50:00 -0000	1.5
  +++ ReplicatedAsyncPerfTest.java	31 Dec 2006 02:08:40 -0000	1.6
  @@ -29,7 +29,7 @@
    * Replicated asynchronous mode performance test for transactional CacheImpl
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class ReplicatedAsyncPerfTest extends TestCase
   {
  @@ -477,7 +477,7 @@
   
      private void log(String str)
      {
  -//     System.out.println(this.getClass().getName() +": " +str);
  +//     System.out.println(this.getClass().getLastElementAsString() +": " +str);
         System.out.println(str);
      }
   
  
  
  
  1.6       +2 -2      JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedSyncPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedSyncPerfTest.java,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -b -r1.5 -r1.6
  --- ReplicatedSyncPerfTest.java	30 Dec 2006 17:50:00 -0000	1.5
  +++ ReplicatedSyncPerfTest.java	31 Dec 2006 02:08:40 -0000	1.6
  @@ -28,7 +28,7 @@
    *
    * @author Bela Ban
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.5 $
  + * @version $Revision: 1.6 $
    */
   public class ReplicatedSyncPerfTest extends TestCase
   {
  @@ -547,7 +547,7 @@
   
      private void log(String str)
      {
  -//     System.out.println(this.getClass().getName() +": " +str);
  +//     System.out.println(this.getClass().getLastElementAsString() +": " +str);
         System.out.println(str);
      }
   
  
  
  
  1.8       +2 -2      JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncMapPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ReplicatedAsyncMapPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/ReplicatedAsyncMapPerfTest.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- ReplicatedAsyncMapPerfTest.java	30 Dec 2006 17:50:00 -0000	1.7
  +++ ReplicatedAsyncMapPerfTest.java	31 Dec 2006 02:08:40 -0000	1.8
  @@ -30,7 +30,7 @@
    * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   public class ReplicatedAsyncMapPerfTest extends TestCase
   {
  @@ -327,7 +327,7 @@
   
      private void log(String str)
      {
  -//     System.out.println(this.getClass().getName() +": " +str);
  +//     System.out.println(this.getClass().getLastElementAsString() +": " +str);
         System.out.println(str);
      }
   
  
  
  
  1.7       +2 -2      JBossCache/tests/perf/org/jboss/cache/LocalMapPerfTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalMapPerfTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/perf/org/jboss/cache/LocalMapPerfTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- LocalMapPerfTest.java	30 Dec 2006 17:50:00 -0000	1.6
  +++ LocalMapPerfTest.java	31 Dec 2006 02:08:40 -0000	1.7
  @@ -32,7 +32,7 @@
    * Local mode performance test for CacheImpl.
    *
    * @author <a href="mailto:bwang at jboss.org">Ben Wang</a> May 20 2003
  - * @version $Revision: 1.6 $
  + * @version $Revision: 1.7 $
    */
   public class LocalMapPerfTest extends TestCase
   {
  @@ -318,7 +318,7 @@
   
      private void log(String str)
      {
  -//     System.out.println(this.getClass().getName() +": " +str);
  +//     System.out.println(this.getClass().getLastElementAsString() +": " +str);
         System.out.println(str);
      }
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:40 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:40 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo     ...
Message-ID: <E1H0q7s-0000iQ-8t@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:40

  Modified:    src-50/org/jboss/cache/pojo     PojoReference.java
                        CachedType.java PojoUtil.java PojoInstance.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.5       +3 -2      JBossCache/src-50/org/jboss/cache/pojo/PojoReference.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoReference.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/PojoReference.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- PojoReference.java	26 Sep 2006 10:25:16 -0000	1.4
  +++ PojoReference.java	31 Dec 2006 02:08:40 -0000	1.5
  @@ -10,13 +10,14 @@
   
   import java.io.Serializable;
   
  -/** POJO reference that contains the information to point to the real POJO storage.
  +/**
  + * POJO reference that contains the information to point to the real POJO storage.
    *
    * @author Ben Wang
    */
   public class PojoReference implements Serializable // Externalizable is no more efficient
   {
  -//    protected static Log log=LogFactory.getLog(PojoReference.class.getName());
  +   //    protected static Log log=LogFactory.getLog(PojoReference.class.getLastElementAsString());
      public static final Object KEY = "PojoReference";
      static final long serialVersionUID = 6492134565825613209L;
      // If not null, it signifies that this is a reference that points to this fqn.
  
  
  
  1.7       +8 -7      JBossCache/src-50/org/jboss/cache/pojo/CachedType.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CachedType.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/CachedType.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- CachedType.java	8 Nov 2006 08:47:23 -0000	1.6
  +++ CachedType.java	31 Dec 2006 02:08:40 -0000	1.7
  @@ -2,9 +2,9 @@
   
   import org.jboss.aop.Advisor;
   import org.jboss.aop.joinpoint.FieldInvocation;
  +import org.jboss.cache.pojo.interceptors.PojoBeginInterceptor;
   import org.jboss.cache.pojo.memory.FieldPersistentReference;
   import org.jboss.cache.pojo.memory.PersistentReference;
  -import org.jboss.cache.pojo.interceptors.PojoBeginInterceptor;
   
   import java.lang.ref.WeakReference;
   import java.lang.reflect.Field;
  @@ -148,17 +148,17 @@
            CachedAttribute attr = (CachedAttribute) i.next();
            sb
                  .append("\t")
  -               .append(attr.getType().getName())
  +               .append(attr.getType().getLastElementAsString())
                  .append(" ")
  -               .append(attr.getName())
  +               .append(attr.getLastElementAsString())
                  .append(" [")
                  .append(attr.getGet() == null
                  ? "<no get>"
  -               : attr.getGet().getName())
  +               : attr.getGet().getLastElementAsString())
                  .append(", ")
                  .append(attr.getSet() == null
                  ? "<no set>"
  -               : attr.getSet().getName())
  +               : attr.getSet().getLastElementAsString())
                  .append("]\n");
         }
         */
  @@ -230,7 +230,8 @@
         if (CachedClassWithNoAnnotation_.get(clazz) != null)
         {
            return false;
  -      } else if (CachedClassWithAnnotation_.get(clazz) != null)
  +      }
  +      else if (CachedClassWithAnnotation_.get(clazz) != null)
         {
            return true;
         }
  @@ -271,7 +272,7 @@
            return true;
         }
   
  -      if(!PojoBeginInterceptor.getReplicateFinalField() && Modifier.isFinal(mods))
  +      if (!PojoBeginInterceptor.getReplicateFinalField() && Modifier.isFinal(mods))
         {
            return true;
         }
  
  
  
  1.15      +33 -30    JBossCache/src-50/org/jboss/cache/pojo/PojoUtil.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoUtil.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/PojoUtil.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- PojoUtil.java	20 Nov 2006 23:32:49 -0000	1.14
  +++ PojoUtil.java	31 Dec 2006 02:08:40 -0000	1.15
  @@ -7,26 +7,27 @@
   
   package org.jboss.cache.pojo;
   
  -import org.jboss.aop.InstanceAdvisor;
  -import org.jboss.aop.Domain;
   import org.jboss.aop.Advised;
  -import org.jboss.aop.pointcut.ast.ParseException;
  -import org.jboss.aop.advice.Interceptor;
  +import org.jboss.aop.Domain;
  +import org.jboss.aop.InstanceAdvisor;
   import org.jboss.aop.advice.AdviceBinding;
  +import org.jboss.aop.advice.Interceptor;
  +import org.jboss.aop.pointcut.ast.ParseException;
  +import org.jboss.cache.Fqn;
   import org.jboss.cache.pojo.annotation.TxUndo;
  -import org.jboss.cache.pojo.observable.Observer;
  -import org.jboss.cache.pojo.observable.Subject;
   import org.jboss.cache.pojo.interceptors.dynamic.CacheFieldInterceptor;
   import org.jboss.cache.pojo.interceptors.dynamic.ReentrancyStopperInterceptor;
  -import org.jboss.cache.Fqn;
  +import org.jboss.cache.pojo.observable.Observer;
  +import org.jboss.cache.pojo.observable.Subject;
   
   import java.lang.reflect.Field;
   import java.util.List;
   
   /**
    * Utility class for method wrappers that we are interested to rollback (i.e., rollback).
  + *
    * @author Ben Wang
  - * @version $Id: PojoUtil.java,v 1.14 2006/11/20 23:32:49 genman Exp $
  + * @version $Id: PojoUtil.java,v 1.15 2006/12/31 02:08:40 msurtani Exp $
    */
   public class PojoUtil
   {
  @@ -54,8 +55,8 @@
   
      public void undoDetachInterceptor(InstanceAdvisor advisor, Interceptor interceptor, Observer observer)
      {
  -      Object pojo = ((CacheFieldInterceptor)interceptor).getAopInstance().get();
  -      if(pojo == null)
  +      Object pojo = ((CacheFieldInterceptor) interceptor).getAopInstance().get();
  +      if (pojo == null)
         {
            throw new PojoCacheException("PojoUtil.detachInterceptor(): null pojo");
         }
  @@ -78,21 +79,21 @@
                                    Observer observer)
      {
         // add the observer
  -      ((Subject)pojo).addObserver(observer);
  +      ((Subject) pojo).addObserver(observer);
   
         // Note that subject interceptor should come before the cache interceptor.
         advisor.appendInterceptor(interceptor);
   
  -      if(checkRecursive)
  +      if (checkRecursive)
         {
            // Insert interceptor to detect recursive call
            Class clazz = pojo.getClass();
            Field[] fields = clazz.getDeclaredFields();
            String clazzName = clazz.getName();
  -         for(Field field: fields)
  +         for (Field field : fields)
            {
               String name = field.getName();
  -            if(name.contains("$aop")) continue; // this is aop declared field.
  +            if (name.contains("$aop")) continue; // this is aop declared field.
               StringBuffer buf = new StringBuffer().append("set(* ").append(clazzName).append("->").
                       append(name).append(")");
   
  @@ -100,11 +101,12 @@
               try
               {
                  binding = new AdviceBinding(BindingName + name, buf.toString(), null);
  -            } catch (ParseException e)
  +            }
  +            catch (ParseException e)
               {
                  e.printStackTrace();
                  throw new PojoCacheException("PojoUtil._attachInterceptor(): can't parse the field binding: "
  -                       +e);
  +                       + e);
               }
               binding.addInterceptor(ReentrancyStopperInterceptor.class);
               getInstanceDomain(pojo).addBinding(binding);
  @@ -114,7 +116,7 @@
   
      private Domain getInstanceDomain(Object obj)
      {
  -      Advised advised = ((Advised)obj);
  +      Advised advised = ((Advised) obj);
         InstanceAdvisor advisor = advised._getInstanceAdvisor();
         return advisor.getDomain();
      }
  @@ -124,11 +126,12 @@
         try
         {
            field.set(obj, newValue);
  -      } catch (IllegalAccessException e)
  +      }
  +      catch (IllegalAccessException e)
         {
            throw new PojoCacheException(
                    "PojoUtil.inMemorySubstitution(): Can't swap out the class of field \" " +
  -                         "+field.getName()," + e);
  +                         "+field.getLastElementAsString()," + e);
         }
      }
   
  @@ -136,25 +139,25 @@
      {
         advisor.removeInterceptor(interceptor.getName());
         // retrieve pojo
  -      Object pojo = ((CacheFieldInterceptor)interceptor).getAopInstance().get();
  +      Object pojo = ((CacheFieldInterceptor) interceptor).getAopInstance().get();
   
  -      if(pojo == null)
  +      if (pojo == null)
         {
            throw new PojoCacheException("PojoUtil.detachInterceptor(): null pojo");
         }
   
  -      ((Subject)pojo).removeObserver(observer);
  +      ((Subject) pojo).removeObserver(observer);
   
  -      if(checkRecursive)
  +      if (checkRecursive)
         {
            // Insert interceptor to detect recursive call
            Class clazz = pojo.getClass();
            Field[] fields = clazz.getDeclaredFields();
  -         for(Field field: fields)
  +         for (Field field : fields)
            {
               String name = field.getName();
  -            if(name.contains("$aop")) continue; // this is aop declared field.
  -            getInstanceDomain(pojo).removeBinding(BindingName +name);
  +            if (name.contains("$aop")) continue; // this is aop declared field.
  +            getInstanceDomain(pojo).removeBinding(BindingName + name);
            }
         }
      }
  @@ -173,7 +176,7 @@
      private int _incrementReferenceCount(Fqn sourceFqn, int count, List refList)
      {
         refList.add(sourceFqn);
  -      return count+1;
  +      return count + 1;
      }
      
      @TxUndo
  @@ -190,6 +193,6 @@
      private int _decrementReferenceCount(Fqn sourceFqn, int count, List refList)
      {
         refList.remove(sourceFqn);
  -      return count-1;
  +      return count - 1;
      }
   }
  
  
  
  1.5       +10 -9     JBossCache/src-50/org/jboss/cache/pojo/PojoInstance.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PojoInstance.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/PojoInstance.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- PojoInstance.java	20 Nov 2006 23:32:49 -0000	1.4
  +++ PojoInstance.java	31 Dec 2006 02:08:40 -0000	1.5
  @@ -12,7 +12,8 @@
   import java.util.ArrayList;
   import java.util.List;
   
  -/** POJO class metadata information.
  +/**
  + * POJO class metadata information.
    * When an object is looked up or put in PojoCache, this object will be advised with a CacheFieldInterceptor.
    * The underlying cache stores a reference to this object (for example to update the instance variables, etc.).
    * Since this reference need to be transactional but never replicated (the reference is only valid
  @@ -24,7 +25,7 @@
    */
   public class PojoInstance implements Serializable // Externalizable is no more efficient
   {
  -//    protected static Log log=LogFactory.getLog(PojoReference.class.getName());
  +   //    protected static Log log=LogFactory.getLog(PojoReference.class.getLastElementAsString());
      public static final Object KEY = "PojoInstance";
      public static final int INITIAL_COUNTER_VALUE = -1;
   
  @@ -92,7 +93,7 @@
   
      synchronized public int incrementRefCount(Fqn sourceFqn)
      {
  -      if(sourceFqn == null)
  +      if (sourceFqn == null)
         {
            throw new IllegalStateException("PojoInstance.incrementRefCount(): null sourceFqn");
         }
  @@ -106,7 +107,7 @@
            throw new IllegalStateException("PojoReference.incrementRefCount(): source fqn: " +
                    sourceFqn + " is already present.");
   
  -      if(util_ == null) util_ = new PojoUtil();
  +      if (util_ == null) util_ = new PojoUtil();
         refCount_ = util_.incrementReferenceCount(sourceFqn, refCount_, referencedBy_);
   //      referencedBy_.add(sourceFqn);
   
  @@ -117,7 +118,7 @@
   
      synchronized public int decrementRefCount(Fqn sourceFqn)
      {
  -      if(sourceFqn == null)
  +      if (sourceFqn == null)
         {
            throw new IllegalStateException("PojoInstance.incrementRefCount(): null sourceFqn");
         }
  @@ -126,7 +127,7 @@
            throw new IllegalStateException("PojoReference.decrementRefCount(): source fqn: " +
                    sourceFqn + " is not present.");
   
  -      if(util_ == null) util_ = new PojoUtil();
  +      if (util_ == null) util_ = new PojoUtil();
         refCount_ = util_.decrementReferenceCount(sourceFqn, refCount_, referencedBy_);
   //      referencedBy_.remove(sourceFqn);
   
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:40 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:40 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/lock  ...
Message-ID: <E1H0q7s-0000iX-Cf@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:40

  Modified:    src/org/jboss/cache/lock  IdentityLock.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.18      +15 -13    JBossCache/src/org/jboss/cache/lock/IdentityLock.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: IdentityLock.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/lock/IdentityLock.java,v
  retrieving revision 1.17
  retrieving revision 1.18
  diff -u -b -r1.17 -r1.18
  --- IdentityLock.java	8 Dec 2006 18:50:49 -0000	1.17
  +++ IdentityLock.java	31 Dec 2006 02:08:40 -0000	1.18
  @@ -6,8 +6,6 @@
    */
   package org.jboss.cache.lock;
   
  -import java.util.concurrent.TimeUnit;
  -import java.util.concurrent.locks.Lock;
   import org.apache.commons.logging.Log;
   import org.apache.commons.logging.LogFactory;
   import org.jboss.cache.Fqn;
  @@ -18,6 +16,8 @@
   import java.util.HashSet;
   import java.util.Iterator;
   import java.util.Set;
  +import java.util.concurrent.TimeUnit;
  +import java.util.concurrent.locks.Lock;
   
   /**
    * Lock object which grants and releases locks, and associates locks with
  @@ -58,7 +58,7 @@
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> Apr 11, 2003
    * @author Ben Wang July 2003
  - * @version $Revision: 1.17 $
  + * @version $Revision: 1.18 $
    */
   public class IdentityLock implements NodeLock
   {
  @@ -169,7 +169,8 @@
         return flag;
      }
      
  -   private boolean acquireWriteLock0(Object caller, long timeout) throws LockingException, TimeoutException, InterruptedException {
  +   private boolean acquireWriteLock0(Object caller, long timeout) throws LockingException, TimeoutException, InterruptedException
  +   {
         if (caller == null)
         {
            throw new IllegalArgumentException("acquireWriteLock(): null caller");
  @@ -532,7 +533,8 @@
      
      public void releaseAll(Object owner)
      {
  -      for (Node n: node.getChildren()) {
  +      for (Node n : node.getChildren())
  +      {
            n.getNodeSPI().getLock().releaseAll(owner);
         }
         release(owner);
  @@ -554,7 +556,7 @@
         boolean locked = isLocked();
   
         printIndent(sb, indent);
  -      sb.append(Fqn.SEPARATOR).append(node.getFqn().getLast());
  +      sb.append(Fqn.SEPARATOR).append(node.getFqn().getLastElement());
         if (locked)
         {
            sb.append("\t(");
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:40 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:40 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors      ...
Message-ID: <E1H0q7s-0000iq-Kw@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:40

  Modified:    src/org/jboss/cache/interceptors     
                        OptimisticNodeInterceptor.java
                        PessimisticLockInterceptor.java
                        OptimisticInterceptor.java
                        CacheStoreInterceptor.java
                        OptimisticValidatorInterceptor.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.39      +8 -9      JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.38
  retrieving revision 1.39
  diff -u -b -r1.38 -r1.39
  --- OptimisticNodeInterceptor.java	30 Dec 2006 19:48:46 -0000	1.38
  +++ OptimisticNodeInterceptor.java	31 Dec 2006 02:08:40 -0000	1.39
  @@ -120,10 +120,10 @@
            {
               case MethodDeclarations.putDataMethodLocal_id:
                  Boolean erase = (Boolean) args[3];
  -               putDataMap(args, erase, workspace, workspaceNode);
  +               putDataMap((Map<Object, Object>) args[2], erase, workspace, workspaceNode);
                  break;
               case MethodDeclarations.putDataEraseMethodLocal_id:
  -               putDataMap(args, true, workspace, workspaceNode);
  +               putDataMap((Map<Object, Object>) args[2], true, workspace, workspaceNode);
                  break;
               case MethodDeclarations.putKeyValMethodLocal_id:
                  result = putDataKeyValue(args, workspace, workspaceNode);
  @@ -190,7 +190,7 @@
      {
         Fqn nodeFqn = node.getFqn();
         WorkspaceNode oldParent = getOrCreateWorkspaceNode(nodeFqn.getParent(), ws);
  -      Object nodeName = nodeFqn.getLast();
  +      Object nodeName = nodeFqn.getLastElement();
   
         // now that we have the parent and target nodes:
         // first correct the pointers at the pruning point
  @@ -215,7 +215,7 @@
       */
      private void moveFqns(WorkspaceNode node, Fqn newBase, TransactionWorkspace ws)
      {
  -      Fqn newFqn = new Fqn(newBase, node.getFqn().getLast());
  +      Fqn newFqn = new Fqn(newBase, node.getFqn().getLastElement());
         WorkspaceNode movedNode = getOrCreateWorkspaceNode(newFqn, ws);
         movedNode.put(node.getData());
   
  @@ -255,16 +255,15 @@
         return (Fqn) args[1];
      }
   
  -   private void putDataMap(Object[] args, boolean eraseExisitng,
  +   private void putDataMap(Map<Object, Object> data, boolean eraseExisitng,
                              TransactionWorkspace workspace, WorkspaceNode workspaceNode)
      {
  -
  -      Map data = (Map) args[2];
         if (workspaceNode == null)
         {
            return;
         }
  -      workspaceNode.put(data, eraseExisitng);
  +      if (eraseExisitng) workspaceNode.clearData();
  +      workspaceNode.put(data);
         workspace.addNode(workspaceNode);
      }
   
  @@ -306,7 +305,7 @@
            throw new CacheException("Unable to find parent node with Fqn " + parentFqn);
         }
   
  -      parentNode.removeChild(new Fqn(workspaceNode.getFqn().getLast()));
  +      parentNode.removeChild(new Fqn(workspaceNode.getFqn().getLastElement()));
         workspace.addNode(parentNode);
         if (debug) log.debug("added parent node " + parentNode.getFqn() + " to workspace");
         Fqn nodeFqn = workspaceNode.getFqn();
  
  
  
  1.40      +2 -2      JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -b -r1.39 -r1.40
  --- PessimisticLockInterceptor.java	30 Dec 2006 17:49:53 -0000	1.39
  +++ PessimisticLockInterceptor.java	31 Dec 2006 02:08:40 -0000	1.40
  @@ -37,7 +37,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.39 2006/12/30 17:49:53 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.40 2006/12/31 02:08:40 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -259,7 +259,7 @@
            if (i == -1)
            {
               // this is the root node
  -            child_name = Fqn.ROOT.getName();
  +            child_name = Fqn.ROOT.getLastElement();
               child_node = cache.getRoot();
            }
            else
  
  
  
  1.8       +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticInterceptor.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- OptimisticInterceptor.java	20 Sep 2006 16:28:57 -0000	1.7
  +++ OptimisticInterceptor.java	31 Dec 2006 02:08:40 -0000	1.8
  @@ -57,7 +57,7 @@
      protected void greedyGetFqns(List<Fqn> list, Node n, Fqn newBase)
      {
         list.add(n.getFqn());
  -      Fqn newFqn = new Fqn(newBase, n.getFqn().getLast());
  +      Fqn newFqn = new Fqn(newBase, n.getFqn().getLastElement());
         list.add(newFqn);
   
         for (Node child : n.getChildren())
  
  
  
  1.42      +2 -2      JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheStoreInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java,v
  retrieving revision 1.41
  retrieving revision 1.42
  diff -u -b -r1.41 -r1.42
  --- CacheStoreInterceptor.java	30 Dec 2006 19:48:46 -0000	1.41
  +++ CacheStoreInterceptor.java	31 Dec 2006 02:08:40 -0000	1.42
  @@ -27,7 +27,7 @@
    * through the CacheLoader, either after each method call (no TXs), or at TX commit.
    *
    * @author Bela Ban
  - * @version $Id: CacheStoreInterceptor.java,v 1.41 2006/12/30 19:48:46 msurtani Exp $
  + * @version $Id: CacheStoreInterceptor.java,v 1.42 2006/12/31 02:08:40 msurtani Exp $
    */
   public class CacheStoreInterceptor extends BaseCacheLoaderInterceptor implements CacheStoreInterceptorMBean
   {
  @@ -257,7 +257,7 @@
   
      private void doMove(Fqn parent, Fqn node) throws Exception
      {
  -      Fqn newNodeFqn = new Fqn(parent, node.getLast());
  +      Fqn newNodeFqn = new Fqn(parent, node.getLastElement());
         //UnversionedNode n = (UnversionedNode) ((TreeCacheProxyImpl) cache).peek(newNodeFqn);
         //recursiveMove(n);
         //      throw new RuntimeException("Implement me!");
  
  
  
  1.48      +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticValidatorInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java,v
  retrieving revision 1.47
  retrieving revision 1.48
  diff -u -b -r1.47 -r1.48
  --- OptimisticValidatorInterceptor.java	30 Dec 2006 17:49:53 -0000	1.47
  +++ OptimisticValidatorInterceptor.java	31 Dec 2006 02:08:40 -0000	1.48
  @@ -185,7 +185,7 @@
                  {
                     throw new IllegalStateException("dNode " + dNode + " has no parent");
                  }
  -               parent.removeChild(new Fqn(dNode.getFqn().getLast()));
  +               parent.removeChild(new Fqn(dNode.getFqn().getLastElement()));
                  cache.getNotifier().notifyNodeRemoved(dNode.getFqn(), false, null);
               }
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:40 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:40 -0500
Subject: [jboss-cvs]
	JBossCache/src-50/org/jboss/cache/pojo/interceptors/dynamic ...
Message-ID: <E1H0q7s-0000ix-OQ@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:40

  Modified:    src-50/org/jboss/cache/pojo/interceptors/dynamic 
                        CacheFieldInterceptor.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.14      +5 -5      JBossCache/src-50/org/jboss/cache/pojo/interceptors/dynamic/CacheFieldInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheFieldInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/interceptors/dynamic/CacheFieldInterceptor.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- CacheFieldInterceptor.java	30 Dec 2006 17:50:03 -0000	1.13
  +++ CacheFieldInterceptor.java	31 Dec 2006 02:08:40 -0000	1.14
  @@ -133,7 +133,7 @@
               }
               else
               {
  -               //cache_.putObject(((Fqn)fqn_.clone()).add(field.getName()), value);
  +               //cache_.putObject(((Fqn)fqn_.clone()).add(field.getLastElementAsString()), value);
                  pCache_.attach(new Fqn(fqn_, field.getName()), value);
               }
            }
  @@ -160,7 +160,7 @@
               }
               else
               {
  -               //result = cache_.getObject(((Fqn)fqn_.clone()).add(field.getName()));
  +               //result = cache_.getObject(((Fqn)fqn_.clone()).add(field.getLastElementAsString()));
                  result = pCache_.getObject(new Fqn(fqn_, field.getName()));
               }
   
  @@ -262,11 +262,11 @@
            }
            else
            {
  -            //		value = removeObject(fqn_+CacheImpl.SEPARATOR+field.getName());
  -            //value = cache_.getObject(((Fqn)fqn_.clone()).add(field.getName()));
  +            //		value = removeObject(fqn_+CacheImpl.SEPARATOR+field.getLastElementAsString());
  +            //value = cache_.getObject(((Fqn)fqn_.clone()).add(field.getLastElementAsString()));
               value = pCache_.getObject(new Fqn(fqn_, field.getName()));
            }
  -         //	    System.out.println("Setting field " + field.getName() + "[" + field.getDeclaringClass() + "] of "+ target.getClass() + " to " + value);
  +         //	    System.out.println("Setting field " + field.getLastElementAsString() + "[" + field.getDeclaringClass() + "] of "+ target.getClass() + " to " + value);
            field.set(target, value);
         }
      }
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:41 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:41 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache     ...
Message-ID: <E1H0q7t-0000jD-89@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:41

  Modified:    src/org/jboss/cache     TreeCacheView.java CacheImpl.java
                        UnversionedNode.java Fqn.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.19      +5 -5      JBossCache/src/org/jboss/cache/TreeCacheView.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: TreeCacheView.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/TreeCacheView.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- TreeCacheView.java	30 Dec 2006 17:49:54 -0000	1.18
  +++ TreeCacheView.java	31 Dec 2006 02:08:40 -0000	1.19
  @@ -53,7 +53,7 @@
    * The view itself caches only the nodes, but doesn't cache any of the data (HashMap) associated with it. When
    * data needs to be displayed, the underlying cache will be accessed directly.
    *
  - * @version $Revision: 1.18 $
  + * @version $Revision: 1.19 $
    * @author<a href="mailto:bela at jboss.org">Bela Ban</a> March 27 2003
    */
   public class TreeCacheView implements TreeCacheViewMBean
  @@ -346,7 +346,7 @@
      JTree jtree = null;
      DefaultTableModel table_model = new DefaultTableModel();
      JTable table = new JTable(table_model);
  -   MyNode root = new MyNode(SEP.getName());
  +   MyNode root = new MyNode(SEP.getLastElementAsString());
      Fqn selected_node = null;
      JPanel tablePanel = null;
      JMenu operationsMenu = null;
  @@ -363,7 +363,7 @@
   
         //server.invoke(cache_service, "addTreeCacheListener",
         //            new Object[]{this},
  -      //          new String[]{TreeCacheListener.class.getName()});
  +      //          new String[]{TreeCacheListener.class.getLastElementAsString()});
         cache.getNotifier().addCacheListener(this);
         addNotify();
         setTitle("TreeCacheGui: mbr=" + getLocalAddress());
  @@ -478,8 +478,8 @@
   
   //                        server.invoke(cache_service, "put",
   //                                      new Object[]{selected_node, key, val},
  -//                                      new String[]{String.class.getName(),
  -//                                      String.class.getName(), Object.class.getName()});
  +//                                      new String[]{String.class.getLastElementAsString(),
  +//                                      String.class.getLastElementAsString(), Object.class.getLastElementAsString()});
                  try
                  {
                     cache.put(selected_node, key, val);
  
  
  
  1.3       +7 -7      JBossCache/src/org/jboss/cache/CacheImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/CacheImpl.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- CacheImpl.java	30 Dec 2006 19:48:46 -0000	1.2
  +++ CacheImpl.java	31 Dec 2006 02:08:40 -0000	1.3
  @@ -98,7 +98,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: CacheImpl.java,v 1.2 2006/12/30 19:48:46 msurtani Exp $
  + * @version $Id: CacheImpl.java,v 1.3 2006/12/31 02:08:40 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -1750,7 +1750,7 @@
      public Set getChildrenNames(Fqn fqn) throws CacheException
      {
         MethodCall m = MethodCallFactory.create(MethodDeclarations.getChildrenNamesMethodLocal, fqn);
  -      return (Set) invokeMethod(m);
  +      return Collections.unmodifiableSet(new HashSet((Set) invokeMethod(m)));
      }
   
      public Set _getChildrenNames(Fqn fqn) throws CacheException
  @@ -2408,7 +2408,7 @@
         // remove subtree from parent
         if (eviction || configuration.isNodeLockingOptimistic())
         {
  -         parent_node.getNodeSPI().getChildrenMap().remove(n.getFqn().getLast());
  +         parent_node.getNodeSPI().getChildrenMap().remove(n.getFqn().getLastElement());
         }
         else
         {
  @@ -2427,7 +2427,7 @@
         // this modification) and put it into the TX's undo list.
         if (tx != null && create_undo_ops && !eviction)
         {
  -         undo_op = MethodCallFactory.create(MethodDeclarations.addChildMethodLocal, tx, parent_node.getFqn(), n.getFqn().getLast(), n, false);
  +         undo_op = MethodCallFactory.create(MethodDeclarations.addChildMethodLocal, tx, parent_node.getFqn(), n.getFqn().getLastElement(), n, false);
   
            // 1. put undo-op in TX' undo-operations list (needed to rollback TX)
            tx_table.addUndoOperation(tx, undo_op);
  @@ -3174,7 +3174,7 @@
         }
   
         NodeSPI oldParent = (NodeSPI) node.getParent();
  -      Object nodeName = nodeToMoveFqn.getLast();
  +      Object nodeName = nodeToMoveFqn.getLastElement();
   
         // now that we have the parent and target nodes:
         // first correct the pointers at the pruning point
  @@ -3189,7 +3189,7 @@
         // now register an undo op
         if (getInvocationContext().getTransaction() != null)
         {
  -         MethodCall undo = MethodCallFactory.create(MethodDeclarations.moveMethodLocal, oldParent.getFqn(), new Fqn(newParentFqn, nodeToMoveFqn.getLast()));
  +         MethodCall undo = MethodCallFactory.create(MethodDeclarations.moveMethodLocal, oldParent.getFqn(), new Fqn(newParentFqn, nodeToMoveFqn.getLastElement()));
            tx_table.addUndoOperation(getInvocationContext().getGlobalTransaction(), undo);
         }
      }
  @@ -3206,7 +3206,7 @@
   
      private void moveFqns(Node node, Fqn newBase)
      {
  -      Fqn newFqn = new Fqn(newBase, node.getFqn().getLast());
  +      Fqn newFqn = new Fqn(newBase, node.getFqn().getLastElement());
         node.getNodeSPI().setFqn(newFqn);
      }
   
  
  
  
  1.2       +6 -6      JBossCache/src/org/jboss/cache/UnversionedNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UnversionedNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/UnversionedNode.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UnversionedNode.java	30 Dec 2006 17:49:54 -0000	1.1
  +++ UnversionedNode.java	31 Dec 2006 02:08:41 -0000	1.2
  @@ -142,7 +142,7 @@
         }
         this.cache = cache;
         this.fqn = fqn;
  -      if (!fqn.isRoot() && !child_name.equals(fqn.getLast()))
  +      if (!fqn.isRoot() && !child_name.equals(fqn.getLastElement()))
         {
            throw new IllegalArgumentException("Child " + child_name + " must be last part of " + fqn);
         }
  @@ -505,7 +505,7 @@
   
               if (f.size() == 1)
               {
  -               newNode = getOrCreateChild(f.getLast(), gtx);
  +               newNode = getOrCreateChild(f.getLastElement(), gtx);
               }
               else
               {
  @@ -563,7 +563,7 @@
         {
            try
            {
  -            Node child = getChild(fqn.getLast());
  +            Node child = getChild(fqn.getLastElement());
               cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
               return child;
            }
  @@ -630,13 +630,13 @@
         {
            if (fqn.size() == 1)
            {
  -            children.remove(fqn.getName());
  +            children.remove(fqn.getLastElement());
            }
            else
            {
               Node c = getChild(fqn);
               cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  -            c.getParent().removeChild(new Fqn(fqn.getName()));
  +            c.getParent().removeChild(new Fqn(fqn.getLastElement()));
            }
            cache.getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
         }
  @@ -749,7 +749,7 @@
       */
      public Object getName()
      {
  -      return fqn.getLast();
  +      return fqn.getLastElement();
      }
   
      /**
  
  
  
  1.45      +5 -5      JBossCache/src/org/jboss/cache/Fqn.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Fqn.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Fqn.java,v
  retrieving revision 1.44
  retrieving revision 1.45
  diff -u -b -r1.44 -r1.45
  --- Fqn.java	30 Dec 2006 19:48:46 -0000	1.44
  +++ Fqn.java	31 Dec 2006 02:08:41 -0000	1.45
  @@ -42,7 +42,7 @@
    * <p/>
    * Another way to look at it is that the "/" separarator is only parsed when it form sa  part of a String passed in to Fqn.fromString() and not otherwise.
    *
  - * @version $Revision: 1.44 $
  + * @version $Revision: 1.45 $
    */
   public class Fqn implements Cloneable, Externalizable, Comparable<Fqn>
   {
  @@ -292,9 +292,9 @@
      /**
       * Returns the last element in the FQN.
       *
  -    * @see #getName
  +    * @see #getLastElementAsString
       */
  -   public Object getLast()
  +   public Object getLastElement()
      {
         if (isRoot()) return SEPARATOR;
         return elements.get(elements.size() - 1);
  @@ -482,10 +482,10 @@
       * Returns a String representation of the last element that makes up this Fqn.
       * If this is the root, returns {@link Fqn#SEPARATOR}.
       */
  -   public String getName()
  +   public String getLastElementAsString()
      {
         if (isRoot()) return SEPARATOR;
  -      else return String.valueOf(getLast());
  +      else return String.valueOf(getLastElement());
      }
   
      /**
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:41 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:41 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Message-ID: <E1H0q7t-0000jN-Bu@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:41

  Modified:    tests/functional/org/jboss/cache/optimistic  
                        NodeInterceptorGetChildrenNamesTest.java
                        NodeInterceptorRemoveNodeTest.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.12      +11 -3     JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorGetChildrenNamesTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- NodeInterceptorGetChildrenNamesTest.java	30 Dec 2006 17:49:52 -0000	1.11
  +++ NodeInterceptorGetChildrenNamesTest.java	31 Dec 2006 02:08:41 -0000	1.12
  @@ -194,11 +194,19 @@
         //assert we can see this
         assertEquals(1, cache.getChildrenNames("/one").size());
   
  +      try
  +      {
         for (Iterator it = cache.getChildrenNames("/one").iterator(); it.hasNext();)
         {
            Object temp = it.next();
            it.remove();
         }
  +         fail("Should not be allowed to modify elements in the set returned by getChildrenNames()");
  +      }
  +      catch (UnsupportedOperationException uoe)
  +      {
  +         // the returned set should be unmodifiable and a remove on the iterator should fail.
  +      }
   
         //assert the removal has had no effect
         assertEquals(1, cache.getChildrenNames("/one").size());
  
  
  
  1.15      +1 -1      JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeInterceptorRemoveNodeTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java,v
  retrieving revision 1.14
  retrieving revision 1.15
  diff -u -b -r1.14 -r1.15
  --- NodeInterceptorRemoveNodeTest.java	30 Dec 2006 17:49:52 -0000	1.14
  +++ NodeInterceptorRemoveNodeTest.java	31 Dec 2006 02:08:41 -0000	1.15
  @@ -141,7 +141,7 @@
         assertNotNull(workspace.getNode(Fqn.fromString("/one")));
         assertEquals(false, workspace.getNode(Fqn.fromString("/one")).isDeleted());
         assertEquals(0, workspace.getNode(Fqn.fromString("/one")).getMergedChildren().size());
  -      assertEquals(null, workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("/one/two")));
  +      assertEquals(null, workspace.getNode(Fqn.fromString("/one")).getChild(Fqn.fromString("/two")));
         assertTrue(entry.getLocks().isEmpty());
         assertEquals(2, entry.getModifications().size());
         assertTrue(!cache.exists("/one/two"));
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:41 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:41 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache  ...
Message-ID: <E1H0q7t-0000jU-GF@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:41

  Modified:    tests/functional/org/jboss/cache  FqnTest.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.19      +3 -3      JBossCache/tests/functional/org/jboss/cache/FqnTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: FqnTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/FqnTest.java,v
  retrieving revision 1.18
  retrieving revision 1.19
  diff -u -b -r1.18 -r1.19
  --- FqnTest.java	30 Dec 2006 19:48:46 -0000	1.18
  +++ FqnTest.java	31 Dec 2006 02:08:41 -0000	1.19
  @@ -20,7 +20,7 @@
    * Tests {@link Fqn}.
    *
    * @author <a href="mailto:bela at jboss.org">Bela Ban</a> May 9, 2003
  - * @version $Revision: 1.18 $
  + * @version $Revision: 1.19 $
    */
   public class FqnTest extends TestCase
   {
  @@ -288,11 +288,11 @@
      public void testGetName()
      {
         Fqn integerFqn = new Fqn(1);
  -      assertEquals("1", integerFqn.getName());
  +      assertEquals("1", integerFqn.getLastElementAsString());
   
         Object object = new Object();
         Fqn objectFqn = new Fqn(object);
  -      assertEquals(object.toString(), objectFqn.getName());
  +      assertEquals(object.toString(), objectFqn.getLastElementAsString());
      }
   
      public void testCloningString() throws CloneNotSupportedException
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:41 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:41 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/loader  ...
Message-ID: <E1H0q7t-0000jb-Jg@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:41

  Modified:    tests/functional/org/jboss/cache/loader 
                        DummyInMemoryCacheLoader.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.5       +7 -7      JBossCache/tests/functional/org/jboss/cache/loader/DummyInMemoryCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: DummyInMemoryCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/loader/DummyInMemoryCacheLoader.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- DummyInMemoryCacheLoader.java	23 Oct 2006 05:47:30 -0000	1.4
  +++ DummyInMemoryCacheLoader.java	31 Dec 2006 02:08:41 -0000	1.5
  @@ -59,7 +59,7 @@
         {
            if (f.getParent().equals(p))
            {
  -            c.add(f.getName());
  +            c.add(f.getLastElement());
            }
         }
         return c;
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:41 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:41 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader/jdbm  ...
Message-ID: <E1H0q7t-0000ji-O2@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:41

  Modified:    src/org/jboss/cache/loader/jdbm  JdbmCacheLoader.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.21      +3 -3      JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: JdbmCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -b -r1.20 -r1.21
  --- JdbmCacheLoader.java	30 Dec 2006 19:48:47 -0000	1.20
  +++ JdbmCacheLoader.java	31 Dec 2006 02:08:41 -0000	1.21
  @@ -55,7 +55,7 @@
    * plans to fix this.
    *
    * @author Elias Ross
  - * @version $Id: JdbmCacheLoader.java,v 1.20 2006/12/30 19:48:47 msurtani Exp $
  + * @version $Id: JdbmCacheLoader.java,v 1.21 2006/12/31 02:08:41 msurtani Exp $
    */
   public class JdbmCacheLoader extends AbstractCacheLoader
   {
  @@ -306,7 +306,7 @@
            }
            if (size == depth && t.getValue().equals(NODE))
            {
  -            set.add((String) fqn.getLast());
  +            set.add((String) fqn.getLastElement());
            }
         }
   
  @@ -354,7 +354,7 @@
               {
                  break;
               }
  -            Object k = fqn.getLast();
  +            Object k = fqn.getLastElement();
               Object v = t.getValue();
               map.put(nullUnmask(k), nullUnmask(v));
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:41 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:41 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/util  ...
Message-ID: <E1H0q7t-0000jp-TN@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:41

  Modified:    src-50/org/jboss/cache/pojo/util  MethodCall.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.3       +4 -3      JBossCache/src-50/org/jboss/cache/pojo/util/MethodCall.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: MethodCall.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/util/MethodCall.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- MethodCall.java	31 Jul 2006 02:44:42 -0000	1.2
  +++ MethodCall.java	31 Dec 2006 02:08:41 -0000	1.3
  @@ -13,7 +13,7 @@
    * A special MethodCall object to wrap around the rollback method call. No Serializable is required.
    *
    * @author Ben Wang
  - * @version $Revision: 1.2 $
  + * @version $Revision: 1.3 $
    */
   public class MethodCall
   {
  @@ -34,7 +34,7 @@
      protected Class[] types = null;
   
      /**
  -    * The signature, e.g., new String[]{String.class.getName(), int.class.getName()}.
  +    * The signature, e.g., new String[]{String.class.getLastElementAsString(), int.class.getLastElementAsString()}.
       */
      protected String[] signature = null;
   
  @@ -214,7 +214,8 @@
            if (meth != null)
            {
               retval = meth.invoke(target, args);
  -         } else
  +         }
  +         else
            {
               throw new NoSuchMethodException(method_name);
            }
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:42 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:42 -0500
Subject: [jboss-cvs] JBossCache/src-50/org/jboss/cache/pojo/collection  ...
Message-ID: <E1H0q7u-0000jw-23@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:42

  Modified:    src-50/org/jboss/cache/pojo/collection  CachedMapImpl.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.16      +4 -4      JBossCache/src-50/org/jboss/cache/pojo/collection/CachedMapImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CachedMapImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src-50/org/jboss/cache/pojo/collection/CachedMapImpl.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- CachedMapImpl.java	30 Dec 2006 17:49:53 -0000	1.15
  +++ CachedMapImpl.java	31 Dec 2006 02:08:42 -0000	1.16
  @@ -160,7 +160,7 @@
         if (children == null) return false;
         for (Node n : children)
         {
  -         if (n.getFqn().getLast().equals(Null.toNullKeyObject(object))) return true;
  +         if (n.getFqn().getLastElement().equals(Null.toNullKeyObject(object))) return true;
         }
   
         return false;
  @@ -202,7 +202,7 @@
   
                  public Object next()
                  {
  -                  return new Entry(lastKey = ((Node) i.next()).getFqn().getLast());
  +                  return new Entry(lastKey = ((Node) i.next()).getFqn().getLastElement());
                  }
   
                  public void remove()
  @@ -254,7 +254,7 @@
                     try
                     {
                        Fqn f = ((Node) i.next()).getFqn();
  -                     lastKey = f.getLast();
  +                     lastKey = f.getLastElement();
                        return Null.toNullValue(pCache_.getObject(f));
                     }
                     catch (CacheException e)
  @@ -307,7 +307,7 @@
   
                  public Object next()
                  {
  -                  lastKey = ((Node) i.next()).getFqn().getLast();
  +                  lastKey = ((Node) i.next()).getFqn().getLastElement();
                     return Null.toNullKeyValue(lastKey);
   
                  }
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:42 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:42 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/marshall ...
Message-ID: <E1H0q7u-0000k3-6s@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:42

  Modified:    tests/functional/org/jboss/cache/marshall  LocalTest.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.12      +3 -3      JBossCache/tests/functional/org/jboss/cache/marshall/LocalTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: LocalTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/marshall/LocalTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- LocalTest.java	30 Dec 2006 17:49:57 -0000	1.11
  +++ LocalTest.java	31 Dec 2006 02:08:42 -0000	1.12
  @@ -18,7 +18,7 @@
    * Simple functional tests for LegacyTreeCacheMarshaller
    *
    * @author Ben Wang
  - * @version $Id: LocalTest.java,v 1.11 2006/12/30 17:49:57 msurtani Exp $
  + * @version $Id: LocalTest.java,v 1.12 2006/12/31 02:08:42 msurtani Exp $
    */
   public class LocalTest extends RegionBasedMarshallingTestBase
   {
  @@ -80,7 +80,7 @@
            }
            Class[] types = {};
            Class[] margs = {};
  -         Method getValue = clasz1.getMethod("getName", types);
  +         Method getValue = clasz1.getMethod("getLastElementAsString", types);
            value = getValue.invoke(ben, margs);
            buffer.setLength(0);
            buffer.append("main.obj.CodeSource: ");
  @@ -90,7 +90,7 @@
         catch (Exception e)
         {
            e.printStackTrace();
  -         log("Failed to invoke getName: " + e);
  +         log("Failed to invoke getLastElementAsString: " + e);
         }
   
         cache.put("/a/b/c", "ben", ben);
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:42 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:42 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/loader  ...
Message-ID: <E1H0q7u-0000kA-C3@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:42

  Modified:    src/org/jboss/cache/loader  AbstractCacheLoader.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.14      +1 -1      JBossCache/src/org/jboss/cache/loader/AbstractCacheLoader.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: AbstractCacheLoader.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/loader/AbstractCacheLoader.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- AbstractCacheLoader.java	30 Dec 2006 19:48:44 -0000	1.13
  +++ AbstractCacheLoader.java	31 Dec 2006 02:08:42 -0000	1.14
  @@ -222,7 +222,7 @@
   
      private void _move(Fqn parent, Fqn fqn) throws Exception
      {
  -      Object name = fqn.getLast();
  +      Object name = fqn.getLastElement();
         Fqn newFqn = new Fqn(parent, name);
   
         // start deep.
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:42 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:42 -0500
Subject: [jboss-cvs]
	JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer ...
Message-ID: <E1H0q7u-0000kH-G0@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:42

  Modified:    tests-50/functional/org/jboss/cache/pojo/statetransfer 
                        StateTransferAopTestBase.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.8       +15 -15    JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer/StateTransferAopTestBase.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: StateTransferAopTestBase.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests-50/functional/org/jboss/cache/pojo/statetransfer/StateTransferAopTestBase.java,v
  retrieving revision 1.7
  retrieving revision 1.8
  diff -u -b -r1.7 -r1.8
  --- StateTransferAopTestBase.java	30 Dec 2006 19:48:49 -0000	1.7
  +++ StateTransferAopTestBase.java	31 Dec 2006 02:08:42 -0000	1.8
  @@ -39,7 +39,7 @@
    * Tests state transfer in PojoCache.
    *
    * @author <a href="mailto://brian.stansberry at jboss.com">Brian Stansberry</a>
  - * @version $Revision: 1.7 $
  + * @version $Revision: 1.8 $
    */
   public abstract class StateTransferAopTestBase extends TestCase
   {
  @@ -165,9 +165,9 @@
   
         Person ab1 = (Person) cache2.find(A_B_1);
         Person ab2 = (Person) cache2.find(A_B_2);
  -      assertEquals("Name for /a/b/1 is Joe", joe.getName(), ab1.getName());
  +      assertEquals("Name for /a/b/1 is Joe", joe.getLastElementAsString(), ab1.getLastElementAsString());
         assertEquals("City for /a/b/1 is Anytown", joe.getAddress().getCity(), ab1.getAddress().getCity());
  -      assertEquals("Name for /a/b/2 is Jane", jane.getName(), ab2.getName());
  +      assertEquals("Name for /a/b/2 is Jane", jane.getLastElementAsString(), ab2.getLastElementAsString());
         assertEquals("City for /a/b/2 is Anytown", jane.getAddress().getCity(), ab2.getAddress().getCity());
         assertTrue("Address for Joe and Jane is the same object", ab1.getAddress() == ab2.getAddress());
   
  @@ -180,9 +180,9 @@
   
         Person ac1 = (Person) cache2.find(A_C_1);
         Person ac2 = (Person) cache2.find(A_C_2);
  -      assertEquals("Name for /a/c/1 is Bob", bob.getName(), ac1.getName());
  +      assertEquals("Name for /a/c/1 is Bob", bob.getLastElementAsString(), ac1.getLastElementAsString());
         assertEquals("City for /a/c/1 is Fremont", addr2.getCity(), ac1.getAddress().getCity());
  -      assertEquals("Name for /a/c/2 is Jill", jill.getName(), ac2.getName());
  +      assertEquals("Name for /a/c/2 is Jill", jill.getLastElementAsString(), ac2.getLastElementAsString());
         assertEquals("City for /a/c/2 is Fremont", addr2.getCity(), ac2.getAddress().getCity());
         assertTrue("Bob and Jill have same Address", ac1.getAddress() == ac2.getAddress());
   
  @@ -194,17 +194,17 @@
         cache1.getCache().getRegion(Fqn.fromString("/a/c/2"), true).activate();
   
         ab1 = (Person) cache1.find(A_B_1);
  -      assertEquals("Name for /a/b/1 is Joe", joe.getName(), ab1.getName());
  +      assertEquals("Name for /a/b/1 is Joe", joe.getLastElementAsString(), ab1.getLastElementAsString());
         assertEquals("City for /a/b/1 is Anytown", addr1.getCity(), ab1.getAddress().getCity());
         ab2 = (Person) cache1.find(A_B_2);
  -      assertEquals("Name for /a/b/1 is Jane", jane.getName(), ab2.getName());
  +      assertEquals("Name for /a/b/1 is Jane", jane.getLastElementAsString(), ab2.getLastElementAsString());
         assertEquals("City for /a/b/1 is Anytown", addr1.getCity(), ab2.getAddress().getCity());
         assertTrue("Address for Joe and Jane is the same object", ab1.getAddress() == ab2.getAddress());
         ac1 = (Person) cache1.find(A_C_1);
  -      assertEquals("Name for /a/c/1 is Bob", bob.getName(), ac1.getName());
  +      assertEquals("Name for /a/c/1 is Bob", bob.getLastElementAsString(), ac1.getLastElementAsString());
         assertEquals("City for /a/c/1 is Fremont", addr2.getCity(), ac1.getAddress().getCity());
         ac2 = (Person) cache1.find(A_C_2);
  -      assertEquals("Name for /a/c/2 is Jill", jill.getName(), ac2.getName());
  +      assertEquals("Name for /a/c/2 is Jill", jill.getLastElementAsString(), ac2.getLastElementAsString());
         assertEquals("City for /a/c/2 is Fremont", addr2.getCity(), ac2.getAddress().getCity());
         assertTrue("Address for Bob and Jill is the same object", ac1.getAddress() == ac2.getAddress());
         */
  @@ -245,9 +245,9 @@
   
         cache1.getCache().getRegion(Fqn.fromString("/a/b"), true).activate();
   
  -//      assertEquals("Correct name from loader for /a/b/1", joe.getName(), loader.get(A_B_1_f).get("name"));
  +//      assertEquals("Correct name from loader for /a/b/1", joe.getLastElementAsString(), loader.get(A_B_1_f).get("name"));
   //      assertEquals("Correct age from loader for /a/b/1", TWENTY, loader.get(A_B_1_f).get("age"));
  -//      assertEquals("Correct name from loader for /a/b/2", jane.getName(), loader.get(A_B_2_f).get("name"));
  +//      assertEquals("Correct name from loader for /a/b/2", jane.getLastElementAsString(), loader.get(A_B_2_f).get("name"));
   //      assertEquals("Correct age from loader for /a/b/2", TWENTYFIVE, loader.get(A_B_2_f).get("age"));
   
   
  @@ -266,13 +266,13 @@
   
         cache1.getCache().getRegion(Fqn.fromString("/a/c"), true).activate();
   
  -//     assertEquals("Correct name from loader for /a/b/1", joe.getName(), loader.get(A_B_1_f).get("name"));
  +//     assertEquals("Correct name from loader for /a/b/1", joe.getLastElementAsString(), loader.get(A_B_1_f).get("name"));
   //      assertEquals("Correct age from loader for /a/b/1", TWENTY, loader.get(A_B_1_f).get("age"));
  -//      assertEquals("Correct name from loader for /a/b/2", jane.getName(), loader.get(A_B_2_f).get("name"));
  +//      assertEquals("Correct name from loader for /a/b/2", jane.getLastElementAsString(), loader.get(A_B_2_f).get("name"));
   //      assertEquals("Correct age from loader for /a/b/2", TWENTYFIVE, loader.get(A_B_2_f).get("age"));
  -//      assertEquals("Correct name from loader for /a/c/1", bob.getName(), loader.get(A_C_1_f).get("name"));
  +//      assertEquals("Correct name from loader for /a/c/1", bob.getLastElementAsString(), loader.get(A_C_1_f).get("name"));
   //      assertEquals("Correct age from loader for /a/c/1", FORTY, loader.get(A_C_1_f).get("age"));
  -//      assertEquals("Correct name from loader for /a/c/2", jill.getName(), loader.get(A_C_2_f).get("name"));
  +//      assertEquals("Correct name from loader for /a/c/2", jill.getLastElementAsString(), loader.get(A_C_2_f).get("name"));
   //      assertEquals("Correct age from loader for /a/c/2", TWENTYFIVE, loader.get(A_C_2_f).get("age"));
   
         Person ac1 = (Person) cache2.find(A_C_1);
  
  
  


From msurtani at jboss.com  Sat Dec 30 21:08:42 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 21:08:42 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1H0q7u-0000kO-Kw@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 21:08:42

  Modified:    src/org/jboss/cache/optimistic  WorkspaceNodeImpl.java
  Log:
  Updates to tests to go along with changes in node methods
  
  Revision  Changes    Path
  1.35      +11 -13    JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.34
  retrieving revision 1.35
  diff -u -b -r1.34 -r1.35
  --- WorkspaceNodeImpl.java	30 Dec 2006 19:48:46 -0000	1.34
  +++ WorkspaceNodeImpl.java	31 Dec 2006 02:08:42 -0000	1.35
  @@ -289,7 +289,7 @@
   
      public Object getName()
      {
  -      return node.getFqn().getLast();
  +      return node.getFqn().getLastElement();
      }
   
      public TransactionWorkspace getTransactionWorkspace()
  @@ -377,16 +377,9 @@
   
      public Node getChild(Fqn f)
      {
  -      boolean origVal = getCache().getInvocationContext().getOptionOverrides().isBypassInterceptorChain();
  -      if (!origVal) getCache().getInvocationContext().getOptionOverrides().setBypassInterceptorChain(true);
  -      try
  -      {
  -         return node.getChild(f);
  -      }
  -      finally
  -      {
  -         if (!origVal) getCache().getInvocationContext().getOptionOverrides().setBypassInterceptorChain(false);
  -      }
  +      if (f.size() > 1)
  +         throw new UnsupportedOperationException("Workspace node does not support fetching indirect children");
  +      return getChild(f.getLastElement());
      }
   
      public Set<Node> getChildren()
  @@ -430,8 +423,13 @@
   
      public void removeChild(Fqn f)
      {
  -      throw new UnsupportedOperationException();
  -      // TODO Auto-generated method stub
  +      if (f.size() > 1) throw new UnsupportedOperationException("Workspace nodes can only remove direct children!");
  +      Object key = f.getLastElement();
  +      if (optimisticChildNodeMap.containsKey(key))
  +      {
  +         dirty = true;
  +         optimisticChildNodeMap.remove(key);
  +      }
      }
   
      public void removeChildren()
  
  
  


From dfshug89fds45645 at linuxmail.org  Sat Dec 30 21:36:56 2006
From: dfshug89fds45645 at linuxmail.org (dfshug89fds45645 at linuxmail.org)
Date: Sat, 30 Dec 2006 21:36:56 -0500
Subject: [jboss-cvs] =?utf-8?b?wpbCvsKTw7rCgsKpwpbCvsKMw6PCk8O6woLDicKB?=
	=?utf-8?q?c?=
Message-ID: 20061231120943.93043mail@mail.oiuysjhdasjkdhaskduashdjsdnausdasj.com

???????????????????????????H
???????????????????????H
?????v???t?B?[???A???^??????????
http://www.freewebspace.com.tonderuyo.com/sega/
?m?F????OK???????????????????B
????ID?????@2987635

??*?B.?E???E.?B*MINAKO*?B.?E???E.?B*??




From msurtani at jboss.com  Sat Dec 30 22:01:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 22:01:20 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/notifications
	...
Message-ID: <E1H0qwq-0001bQ-4j@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 22:01:20

  Modified:    tests/functional/org/jboss/cache/notifications  
                        RemoteCacheListenerTest.java CacheListenerTest.java
  Log:
  move api still WIP
  
  Revision  Changes    Path
  1.5       +1 -1      JBossCache/tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: RemoteCacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- RemoteCacheListenerTest.java	31 Dec 2006 02:08:39 -0000	1.4
  +++ RemoteCacheListenerTest.java	31 Dec 2006 03:01:20 -0000	1.5
  @@ -223,7 +223,7 @@
         eventLog.events.clear(); // clear events
         assertEquals("Event log should be empty", Collections.emptyList(), eventLog.events);
   
  -      n1.move(n2);
  +      cache.move(n1.getFqn(), n2.getFqn());
         //expected
         Fqn newFqn = new Fqn(newParent, fqn.getLastElement());
         List<RemoteCacheListenerTest.Event> expected = new ArrayList<RemoteCacheListenerTest.Event>();
  
  
  
  1.12      +3 -1      JBossCache/tests/functional/org/jboss/cache/notifications/CacheListenerTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheListenerTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/notifications/CacheListenerTest.java,v
  retrieving revision 1.11
  retrieving revision 1.12
  diff -u -b -r1.11 -r1.12
  --- CacheListenerTest.java	31 Dec 2006 02:08:39 -0000	1.11
  +++ CacheListenerTest.java	31 Dec 2006 03:01:20 -0000	1.12
  @@ -206,7 +206,7 @@
         eventLog.events.clear(); // clear events
         assertEquals("Event log should be empty", Collections.emptyList(), eventLog.events);
   
  -      n1.move(n2);
  +      cache.move(n1.getFqn(), n2.getFqn());
         //expected
         Fqn newFqn = new Fqn(newParent, fqn.getLastElement());
         List<Event> expected = new ArrayList<Event>();
  @@ -214,6 +214,8 @@
         expected.add(new Event(ListenerMethod.NODE_MODIFIED, newFqn, true, false, null));
         expected.add(new Event(ListenerMethod.NODE_MODIFIED, fqn, false, false, null));
         expected.add(new Event(ListenerMethod.NODE_MODIFIED, newFqn, false, false, null));
  +
  +      assertEquals(expected, eventLog.events);
      }
   
      // -- now the transactional ones
  
  
  


From msurtani at jboss.com  Sat Dec 30 22:01:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 22:01:20 -0500
Subject: [jboss-cvs] JBossCache/tests/functional/org/jboss/cache/api    ...
Message-ID: <E1H0qwq-0001bi-7n@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 22:01:20

  Modified:    tests/functional/org/jboss/cache/api   
                        NodeReplicatedMoveTest.java SyncReplTest.java
                        NodeMoveAPITest.java
  Log:
  move api still WIP
  
  Revision  Changes    Path
  1.7       +5 -5      JBossCache/tests/functional/org/jboss/cache/api/NodeReplicatedMoveTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeReplicatedMoveTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeReplicatedMoveTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- NodeReplicatedMoveTest.java	30 Dec 2006 17:49:53 -0000	1.6
  +++ NodeReplicatedMoveTest.java	31 Dec 2006 03:01:20 -0000	1.7
  @@ -69,7 +69,7 @@
         assertEquals(vB, cache[1].getRoot().getChild(A).getChild(B).get(k));
   
         // now move...
  -      nodeB.move(rootNode);
  +      cache[0].move(nodeB.getFqn(), Fqn.ROOT);
   
         assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
         assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
  @@ -100,7 +100,7 @@
         assertNull(cache[1].getRoot().getChild(B));
   
         // now move...
  -      nodeB.move(rootNode);
  +      cache[0].move(nodeB.getFqn(), Fqn.ROOT);
   
         assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
         assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
  @@ -113,7 +113,7 @@
   
         try
         {
  -         cache[0].getRoot().getChild(B).move(cache[0].getRoot().getChild(A)); // should throw an NPE
  +         cache[0].move(cache[0].getRoot().getChild(B).getFqn(), cache[0].getRoot().getChild(A).getFqn()); // should throw an NPE
            fail("Expecting an exception");
         }
         catch (Exception e)
  @@ -138,7 +138,7 @@
   
         // now move...
         tm.begin();
  -      nodeB.move(rootNode);
  +      cache[0].move(nodeB.getFqn(), Fqn.ROOT);
   
         assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
         assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
  @@ -167,7 +167,7 @@
   
         // now move...
         tm.begin();
  -      nodeB.move(rootNode);
  +      cache[0].move(nodeB.getFqn(), Fqn.ROOT);
   
         assertEquals(vA, cache[0].getRoot().getChild(A).get(k));
         assertEquals(vB, cache[0].getRoot().getChild(B).get(k));
  
  
  
  1.7       +2 -2      JBossCache/tests/functional/org/jboss/cache/api/SyncReplTest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: SyncReplTest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/SyncReplTest.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- SyncReplTest.java	30 Dec 2006 17:49:53 -0000	1.6
  +++ SyncReplTest.java	31 Dec 2006 03:01:20 -0000	1.7
  @@ -140,7 +140,7 @@
   
      private void assertInvocationContextInitState(Cache c)
      {
  -      InvocationContext ctx = ((CacheSPI) c).getInvocationContext();
  +      InvocationContext ctx = c.getInvocationContext();
         InvocationContext control = null;
         try
         {
  @@ -148,7 +148,7 @@
         }
         catch (CloneNotSupportedException e)
         {
  -         fail("Unable to clone InvocationCOntext");
  +         fail("Unable to clone InvocationContext");
         }
   
         control.reset();
  
  
  
  1.16      +10 -9     JBossCache/tests/functional/org/jboss/cache/api/NodeMoveAPITest.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: NodeMoveAPITest.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/api/NodeMoveAPITest.java,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -b -r1.15 -r1.16
  --- NodeMoveAPITest.java	30 Dec 2006 17:49:53 -0000	1.15
  +++ NodeMoveAPITest.java	31 Dec 2006 03:01:20 -0000	1.16
  @@ -77,7 +77,7 @@
   
         log.info("BEFORE MOVE " + cache);
         // move
  -      nodeC.move(nodeB);
  +      cache.move(nodeC.getFqn(), nodeB.getFqn());
         log.info("POST MOVE " + cache);
         log.info("HC " + nodeC + " " + System.identityHashCode(nodeC));
         Node x = cache.getRoot().getChild(Fqn.fromString("b/c"));
  @@ -139,7 +139,7 @@
   
         // move
         log.info("move " + nodeC + " to " + nodeB);
  -      nodeC.move(nodeB);
  +      cache.move(nodeC.getFqn(), nodeB.getFqn());
         //System.out.println("nodeB " + nodeB);
         //System.out.println("nodeC " + nodeC);      
   
  @@ -184,7 +184,7 @@
   
         tm.begin();
         // move node B up to hang off the root
  -      nodeB.move(rootNode);
  +      cache.move(nodeB.getFqn(), Fqn.ROOT);
   
         tm.commit();
   
  @@ -212,7 +212,7 @@
   
         tm.begin();
         // move node B up to hang off the root
  -      nodeB.move(rootNode);
  +      cache.move(nodeB.getFqn(), Fqn.ROOT);
   
         // need to think of a way to test the same with optimistically locked nodes
         if (!optimistic)
  @@ -317,7 +317,7 @@
   
         // move
         if (useTx) tm.begin();
  -      nodeC.move(nodeB);
  +      cache.move(nodeC.getFqn(), nodeB.getFqn());
         if (useTx) tm.commit();
   
         log.info("Post commit tree is " + cache.printDetails());
  @@ -386,7 +386,7 @@
         assertEquals(0, cache.getNumberOfLocksHeld());
         tm.begin();
   
  -      nodeB.move(nodeC);
  +      cache.move(nodeC.getFqn(), nodeB.getFqn());
   //       nodeC should have a RL, nodeA should have a RL, nodeB should have a WL, nodeD should have a WL
   
         System.out.println("LOCKS: " + cache.printLockInfo());
  @@ -407,7 +407,8 @@
         assertEquals(0, cache.getNumberOfLocksHeld());
         tm.begin();
   
  -      nodeB.move(nodeC);
  +      cache.move(nodeC.getFqn(), nodeB.getFqn());
  +
   //       nodeC should have a RL, nodeA should have a RL, nodeB should have a WL
   
         System.out.println("LOCKS: " + cache.printLockInfo());
  @@ -474,7 +475,7 @@
                     System.out.println(getName() + ": Attempt " + counter);
                     try
                     {
  -                     NODE_X.move(NODES[r.nextInt(NODES.length)]);
  +                     cache.move(NODE_X.getFqn(), NODES[r.nextInt(NODES.length)].getFqn());
                     }
                     catch (NodeNotExistsException e)
                     {
  @@ -483,7 +484,7 @@
                     TestingUtil.sleepRandom(250);
                     try
                     {
  -                     NODE_Y.move(NODES[r.nextInt(NODES.length)]);
  +                     cache.move(NODE_Y.getFqn(), NODES[r.nextInt(NODES.length)].getFqn());
                     }
                     catch (NodeNotExistsException e)
                     {
  
  
  


From msurtani at jboss.com  Sat Dec 30 22:01:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 22:01:20 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/interceptors      ...
Message-ID: <E1H0qwq-0001c2-Da@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 22:01:20

  Modified:    src/org/jboss/cache/interceptors     
                        OptimisticNodeInterceptor.java
                        CacheLoaderInterceptor.java
                        OptimisticCreateIfNotExistsInterceptor.java
                        PessimisticLockInterceptor.java
                        CacheStoreInterceptor.java
  Log:
  move api still WIP
  
  Revision  Changes    Path
  1.40      +10 -8     JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticNodeInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java,v
  retrieving revision 1.39
  retrieving revision 1.40
  diff -u -b -r1.39 -r1.40
  --- OptimisticNodeInterceptor.java	31 Dec 2006 02:08:40 -0000	1.39
  +++ OptimisticNodeInterceptor.java	31 Dec 2006 03:01:20 -0000	1.40
  @@ -52,7 +52,7 @@
               throw new CacheException("Setting a data version while performing a move() is not supported!!");
            }
   
  -         Fqn parentFqn = (Fqn) args[0], nodeFqn = (Fqn) args[1];
  +         Fqn parentFqn = (Fqn) args[1], nodeFqn = (Fqn) args[0];
   
            if (log.isTraceEnabled())
            {
  @@ -189,6 +189,11 @@
      public void doMove(WorkspaceNode parent, WorkspaceNode node, TransactionWorkspace ws)
      {
         Fqn nodeFqn = node.getFqn();
  +      if (nodeFqn.isRoot())
  +      {
  +         log.warn("Attempting to move the root node.  Not taking any action, treating this as a no-op.");
  +         return;
  +      }
         WorkspaceNode oldParent = getOrCreateWorkspaceNode(nodeFqn.getParent(), ws);
         Object nodeName = nodeFqn.getLastElement();
   
  @@ -203,11 +208,11 @@
         // now adjust Fqns of node and all children.
         moveFqns(node, parent.getFqn(), ws);
   
  -      // remove old nodes.
  +      // remove old nodes. this may mark some nodes which have already been moved as deleted
         removeNode(ws, node);
  -
  -
  -      System.out.println("WS: " + ws);
  +      // now remove deletion markers on the nodes moved (and their children).
  +      WorkspaceNode newChild = getOrCreateWorkspaceNode(new Fqn(parent.getFqn(), nodeFqn.getLastElement()), ws);
  +      newChild.markAsDeleted(false, true);
      }
   
      /**
  @@ -219,9 +224,6 @@
         WorkspaceNode movedNode = getOrCreateWorkspaceNode(newFqn, ws);
         movedNode.put(node.getData());
   
  -      System.out.println("  Moved node: " + movedNode);
  -      System.out.println("  Data: " + movedNode.getData());
  -
         // process children
         for (Object n : node.getChildrenNames())
         {
  
  
  
  1.66      +3 -3      JBossCache/src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheLoaderInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java,v
  retrieving revision 1.65
  retrieving revision 1.66
  diff -u -b -r1.65 -r1.66
  --- CacheLoaderInterceptor.java	30 Dec 2006 17:49:54 -0000	1.65
  +++ CacheLoaderInterceptor.java	31 Dec 2006 03:01:20 -0000	1.66
  @@ -29,7 +29,7 @@
    * Loads nodes that don't exist at the time of the call into memory from the CacheLoader
    *
    * @author Bela Ban
  - * @version $Id: CacheLoaderInterceptor.java,v 1.65 2006/12/30 17:49:54 msurtani Exp $
  + * @version $Id: CacheLoaderInterceptor.java,v 1.66 2006/12/31 03:01:20 msurtani Exp $
    */
   public class CacheLoaderInterceptor extends BaseCacheLoaderInterceptor implements CacheLoaderInterceptorMBean
   {
  @@ -132,8 +132,8 @@
               }
               break;
            case MethodDeclarations.moveMethodLocal_id:
  -            fqn = (Fqn) args[1];
  -            fqn2 = (Fqn) args[0];
  +            fqn = (Fqn) args[0];
  +            fqn2 = (Fqn) args[1];
               acquireLock = true;
               //initNode = true;
               recursive = true;
  
  
  
  1.34      +1 -1      JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: OptimisticCreateIfNotExistsInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java,v
  retrieving revision 1.33
  retrieving revision 1.34
  diff -u -b -r1.33 -r1.34
  --- OptimisticCreateIfNotExistsInterceptor.java	30 Dec 2006 17:49:53 -0000	1.33
  +++ OptimisticCreateIfNotExistsInterceptor.java	31 Dec 2006 03:01:20 -0000	1.34
  @@ -54,7 +54,7 @@
         return super.invoke(m);
      }
   
  -   private void move(Fqn newParent, Fqn nodeFqn)
  +   private void move(Fqn nodeFqn, Fqn newParent)
      {
         List<Fqn> fqns = new ArrayList<Fqn>();
         fqns.add(newParent);
  
  
  
  1.41      +14 -7     JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: PessimisticLockInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java,v
  retrieving revision 1.40
  retrieving revision 1.41
  diff -u -b -r1.40 -r1.41
  --- PessimisticLockInterceptor.java	31 Dec 2006 02:08:40 -0000	1.40
  +++ PessimisticLockInterceptor.java	31 Dec 2006 03:01:20 -0000	1.41
  @@ -37,7 +37,7 @@
    * current method and unlock when the method returns.
    *
    * @author Bela Ban
  - * @version $Id: PessimisticLockInterceptor.java,v 1.40 2006/12/31 02:08:40 msurtani Exp $
  + * @version $Id: PessimisticLockInterceptor.java,v 1.41 2006/12/31 03:01:20 msurtani Exp $
    */
   public class PessimisticLockInterceptor extends Interceptor
   {
  @@ -67,6 +67,7 @@
         Object[] args = m.getArgs();
         InvocationContext ctx = cache.getInvocationContext();
         boolean lockNecessary = false;
  +      boolean locksAlreadyObtained = false;
   
         if (log.isTraceEnabled()) log.trace("PessimisticLockInterceptor invoked for method " + m);
         if (cache.getInvocationContext().getOptionOverrides() != null && cache.getInvocationContext().getOptionOverrides().isSuppressLocking())
  @@ -101,8 +102,11 @@
         switch (m.getMethodId())
         {
            case MethodDeclarations.moveMethodLocal_id:
  -            obtainLocksForMove((Fqn) args[0], (Fqn) args[1]);
  +            fqn = (Fqn) args[0];
  +            obtainLocksForMove(fqn, (Fqn) args[1]);
  +            locksAlreadyObtained = true;
               lockNecessary = true;
  +            isDeleteOperation = true;
               break;
            case MethodDeclarations.putDataMethodLocal_id:
            case MethodDeclarations.putDataEraseMethodLocal_id:
  @@ -165,12 +169,15 @@
         // release the locks for the given TX
         if (fqn != null)
         {
  +         if (!locksAlreadyObtained)
  +         {
            do
            {
               lock(fqn, ctx.getGlobalTransaction(), lock_type, recursive, createIfNotExists, zeroLockTimeout ? 0 : lock_acquisition_timeout, isDeleteOperation);
            }
            while (createIfNotExists && !cache.getRoot().hasChild(fqn));// keep trying until we have the lock (fixes concurrent remove())
         }
  +      }
         else if (!lockNecessary)
         {
            if (log.isTraceEnabled())
  @@ -201,14 +208,14 @@
         return o;
      }
   
  -   private void obtainLocksForMove(Fqn parent, Fqn node) throws InterruptedException
  +   private void obtainLocksForMove(Fqn node, Fqn parent) throws InterruptedException
      {
         // parent node (new parent) and current node's existing parent should both get RLs.
         // node should have a WL.
   
         // this call will ensure the node gets a WL and it's current parent gets RL.
         if (log.isTraceEnabled()) log.trace("Attempting to get WL on node to be moved [" + node + "]");
  -      lock(node, cache.getInvocationContext().getGlobalTransaction(), NodeLock.LockType.WRITE, true, false, lock_acquisition_timeout, false);
  +      lock(node, cache.getInvocationContext().getGlobalTransaction(), NodeLock.LockType.WRITE, true, false, lock_acquisition_timeout, true);
   
         //now for an RL for the new parent.
         if (log.isTraceEnabled()) log.trace("Attempting to get RL on new parent [" + parent + "]");
  
  
  
  1.43      +2 -2      JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheStoreInterceptor.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/interceptors/CacheStoreInterceptor.java,v
  retrieving revision 1.42
  retrieving revision 1.43
  diff -u -b -r1.42 -r1.43
  --- CacheStoreInterceptor.java	31 Dec 2006 02:08:40 -0000	1.42
  +++ CacheStoreInterceptor.java	31 Dec 2006 03:01:20 -0000	1.43
  @@ -27,7 +27,7 @@
    * through the CacheLoader, either after each method call (no TXs), or at TX commit.
    *
    * @author Bela Ban
  - * @version $Id: CacheStoreInterceptor.java,v 1.42 2006/12/31 02:08:40 msurtani Exp $
  + * @version $Id: CacheStoreInterceptor.java,v 1.43 2006/12/31 03:01:20 msurtani Exp $
    */
   public class CacheStoreInterceptor extends BaseCacheLoaderInterceptor implements CacheStoreInterceptorMBean
   {
  @@ -255,7 +255,7 @@
         }
      }
   
  -   private void doMove(Fqn parent, Fqn node) throws Exception
  +   private void doMove(Fqn node, Fqn parent) throws Exception
      {
         Fqn newNodeFqn = new Fqn(parent, node.getLastElement());
         //UnversionedNode n = (UnversionedNode) ((TreeCacheProxyImpl) cache).peek(newNodeFqn);
  
  
  


From msurtani at jboss.com  Sat Dec 30 22:01:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 22:01:20 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache     ...
Message-ID: <E1H0qwq-0001cI-Ip@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 22:01:20

  Modified:    src/org/jboss/cache     Node.java CacheImpl.java Cache.java
                        UnversionedNode.java
  Log:
  move api still WIP
  
  Revision  Changes    Path
  1.53      +0 -45     JBossCache/src/org/jboss/cache/Node.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Node.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Node.java,v
  retrieving revision 1.52
  retrieving revision 1.53
  diff -u -b -r1.52 -r1.53
  --- Node.java	30 Dec 2006 19:48:46 -0000	1.52
  +++ Node.java	31 Dec 2006 03:01:20 -0000	1.53
  @@ -151,51 +151,6 @@
      void clearData();
   
      /**
  -    * Moves a part of the cache to a different subtree.
  -    * <p/>
  -    * E.g.:
  -    * <p/>
  -    * assume a cache structure such as:
  -    * <p/>
  -    * <pre>
  -    *  /a/b/c
  -    *  /a/b/d
  -    *  /a/b/e
  -    * <p/>
  -    * <p/>
  -    *  Node n = cache.getChild("/a/b/c");
  -    * <p/>
  -    *  n.move(cache.getChild("/a/b/d"));
  -    * </pre>
  -    * <p/>
  -    * Will result in:
  -    * <pre>
  -    * <p/>
  -    * /a/b/d/c
  -    * /a/b/e
  -    * <p/>
  -    * </pre>
  -    * <p/>
  -    * and now
  -    * <p/>
  -    * <pre>
  -    * Node n2 = cache.getChild("/a/b/e");
  -    * n2.move(cache.getChild("/a"));
  -    * </pre>
  -    * <p/>
  -    * will result in:
  -    * <pre>
  -    * /a/b/d/c
  -    * /a/e
  -    * </pre>
  -    * No-op if called on a root node.
  -    *
  -    * @param newParent new location under which to attach the current node.
  -    * @throws NodeNotExistsException may throw one of these if the target node does not exist or if a different thread has moved this node elsewhere already.
  -    */
  -   void move(Node newParent) throws NodeNotExistsException;
  -
  -   /**
       * @param f {@link Fqn} relative to the current node of the child you are testing the existence of.
       * @return Returns true if the child node denoted by the {@link Fqn} passed in exists.
       */
  
  
  
  1.4       +4 -4      JBossCache/src/org/jboss/cache/CacheImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: CacheImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/CacheImpl.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- CacheImpl.java	31 Dec 2006 02:08:40 -0000	1.3
  +++ CacheImpl.java	31 Dec 2006 03:01:20 -0000	1.4
  @@ -98,7 +98,7 @@
    * @author <a href="mailto:manik at jboss.org">Manik Surtani (manik at jboss.org)</a>
    * @author Brian Stansberry
    * @author Daniel Huang (dhuang at jboss.org)
  - * @version $Id: CacheImpl.java,v 1.3 2006/12/31 02:08:40 msurtani Exp $
  + * @version $Id: CacheImpl.java,v 1.4 2006/12/31 03:01:20 msurtani Exp $
    *          <p/>
    * @see <a href="http://labs.jboss.com/portal/jbosscache/docs">JBossCache doc</a>
    */
  @@ -3143,10 +3143,10 @@
       *
       * @since 2.0.0
       */
  -   public void move(Fqn newParent, Fqn nodeToMove)
  +   public void move(Fqn nodeToMove, Fqn newParent)
      {
         // this needs to be passed up the interceptor chain
  -      MethodCall m = MethodCallFactory.create(MethodDeclarations.moveMethodLocal, newParent, nodeToMove);
  +      MethodCall m = MethodCallFactory.create(MethodDeclarations.moveMethodLocal, nodeToMove, newParent);
         invokeMethod(m);
      }
   
  @@ -3156,7 +3156,7 @@
       * @param newParentFqn
       * @param nodeToMoveFqn
       */
  -   public void _move(Fqn newParentFqn, Fqn nodeToMoveFqn)
  +   public void _move(Fqn nodeToMoveFqn, Fqn newParentFqn)
      {
         // the actual move algorithm.
         NodeSPI newParent = findNode(newParentFqn);
  
  
  
  1.17      +48 -0     JBossCache/src/org/jboss/cache/Cache.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Cache.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/Cache.java,v
  retrieving revision 1.16
  retrieving revision 1.17
  diff -u -b -r1.16 -r1.17
  --- Cache.java	30 Dec 2006 17:49:54 -0000	1.16
  +++ Cache.java	31 Dec 2006 03:01:20 -0000	1.17
  @@ -211,4 +211,52 @@
       * @return a {@link List} of members in the cluster.  Null if running in local mode.
       */
      List<Address> getMembers();
  +
  +   /**
  +    * Moves a part of the cache to a different subtree.
  +    * <p/>
  +    * E.g.:
  +    * <p/>
  +    * assume a cache structure such as:
  +    * <p/>
  +    * <pre>
  +    *  /a/b/c
  +    *  /a/b/d
  +    *  /a/b/e
  +    * <p/>
  +    * <p/>
  +    *  Fqn f1 = Fqn.fromString("/a/b/c");
  +    *  Fqn f2 = Fqn.fromString("/a/b/d");
  +    * <p/>
  +    *  cache.move(f1, f2);
  +    * </pre>
  +    * <p/>
  +    * Will result in:
  +    * <pre>
  +    * <p/>
  +    * /a/b/d/c
  +    * /a/b/e
  +    * <p/>
  +    * </pre>
  +    * <p/>
  +    * and now
  +    * <p/>
  +    * <pre>
  +    *  Fqn f3 = Fqn.fromString("/a/b/e");
  +    *  Fqn f4 = Fqn.fromString("/a");
  +    *  cache.move(f3, f4);
  +    * </pre>
  +    * <p/>
  +    * will result in:
  +    * <pre>
  +    * /a/b/d/c
  +    * /a/e
  +    * </pre>
  +    * No-op if the node to be moved is the root node.
  +    *
  +    * @param nodeToMove the Fqn of the node to move.
  +    * @param newParent  new location under which to attach the node being moved.
  +    * @throws NodeNotExistsException may throw one of these if the target node does not exist or if a different thread has moved this node elsewhere already.
  +    */
  +   void move(Fqn nodeToMove, Fqn newParent) throws NodeNotExistsException;
   }
  
  
  
  1.3       +0 -11     JBossCache/src/org/jboss/cache/UnversionedNode.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UnversionedNode.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/UnversionedNode.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UnversionedNode.java	31 Dec 2006 02:08:41 -0000	1.2
  +++ UnversionedNode.java	31 Dec 2006 03:01:20 -0000	1.3
  @@ -597,17 +597,6 @@
         return ((CacheImpl) cache).exists(new Fqn(getFqn(), f));
      }
   
  -   public void move(Node newParent) throws NodeNotExistsException
  -   {
  -      if (log.isTraceEnabled())
  -      {
  -         log.trace(this.getFqn() + " move to " + newParent.getFqn());
  -      }
  -      // TODO
  -      // move must be added to Cache
  -      ((CacheImpl) cache).move(newParent.getFqn(), getFqn());
  -   }
  -
      public void putIfNull(Object k, Object v)
      {
         if (cache.get(getFqn(), k) == null)
  
  
  


From msurtani at jboss.com  Sat Dec 30 22:01:20 2006
From: msurtani at jboss.com (Manik Surtani)
Date: Sat, 30 Dec 2006 22:01:20 -0500
Subject: [jboss-cvs] JBossCache/src/org/jboss/cache/optimistic  ...
Message-ID: <E1H0qwq-0001cP-Md@committer01.frg.pub.inap.atl.jboss.com>

  User: msurtani
  Date: 06/12/30 22:01:20

  Modified:    src/org/jboss/cache/optimistic  WorkspaceNodeImpl.java
  Log:
  move api still WIP
  
  Revision  Changes    Path
  1.36      +0 -18     JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: WorkspaceNodeImpl.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossCache/src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java,v
  retrieving revision 1.35
  retrieving revision 1.36
  diff -u -b -r1.35 -r1.36
  --- WorkspaceNodeImpl.java	31 Dec 2006 02:08:42 -0000	1.35
  +++ WorkspaceNodeImpl.java	31 Dec 2006 03:01:20 -0000	1.36
  @@ -13,7 +13,6 @@
   import org.jboss.cache.Fqn;
   import org.jboss.cache.GlobalTransaction;
   import org.jboss.cache.Node;
  -import org.jboss.cache.NodeNotExistsException;
   import org.jboss.cache.NodeSPI;
   import org.jboss.cache.VersionedNode;
   import org.jboss.cache.factories.NodeFactory;
  @@ -391,8 +390,6 @@
      public boolean hasChild(Fqn f)
      {
         throw new UnsupportedOperationException();
  -      // TODO Auto-generated method stub
  -      // return false;
      }
   
      public NodeSPI getNodeSPI()
  @@ -400,25 +397,14 @@
         throw new UnsupportedOperationException("WorkspaceNode has no access to a NodeSPI");
      }
   
  -   public void move(Node newParent) throws NodeNotExistsException
  -   {
  -      throw new UnsupportedOperationException();
  -      // TODO Auto-generated method stub
  -
  -   }
  -
      public void putIfNull(Object k, Object v)
      {
         throw new UnsupportedOperationException();
  -      // TODO Auto-generated method stub
  -
      }
   
      public void putIfNull(Map<Object, Object> m)
      {
         throw new UnsupportedOperationException();
  -      // TODO Auto-generated method stub
  -
      }
   
      public void removeChild(Fqn f)
  @@ -469,15 +455,11 @@
   
      public boolean getDataLoaded()
      {
  -      // TODO Auto-generated method stub
  -      // return false;
         throw new UnsupportedOperationException();
      }
   
      public void setDataLoaded(boolean dataLoaded)
      {
  -      // TODO Auto-generated method stub
  -      // 
         throw new UnsupportedOperationException();
      }
   
  
  
  


From forge-admin at jboss.com  Sun Dec 31 01:00:28 2006
From: forge-admin at jboss.com (forge-admin at jboss.com)
Date: Sun, 31 Dec 2006 01:00:28 -0500
Subject: [jboss-cvs] cvs.forge.jboss.com Activity
Message-ID: <E1H0tkC-0004wB-8x@committer01.frg.pub.inap.atl.jboss.com>

Commit from rsigal on branch remoting_2_x (2006-12-30 02:47 EST)
-----------------------------------------

JBREM-650: (1) Distinguised behavior on client and server; (2) reorganized createSocket(); (3) added controlLock.

  JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketClientInvoker.java  1.1.2.3


Commit from rsigal on branch remoting_2_x (2006-12-30 02:57 EST)
-----------------------------------------

JBREM-650: (1) Replaced TimerUtil with separate Timer; (2) get new secondary locator on restar control connection restart; (3) control connection monitor doesn't fail if callback client never registered; (4) control socket can be created before client invoker is created; (5) control connection is restarted in new thread.

  JBossRemoting  src/main/org/jboss/remoting/transport/bisocket/BisocketServerInvoker.java  1.1.2.4


Commit from sbryzak2 (2006-12-30 09:04 EST)
--------------------

configuration support for provider flags

  jboss-seam  src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java  1.12


Commit from sbryzak2 (2006-12-30 09:05 EST)
--------------------

minor changes

  jboss-seam  examples/seamspace/resources/META-INF/security-config.xml  1.2
  jboss-seam  examples/seamspace/resources/META-INF/security-rules.drl   1.2
  jboss-seam  examples/seamspace/resources/WEB-INF/components.xml        1.9
  jboss-seam  examples/seamspace/resources/import.sql                    1.8


Commit from msurtani (2006-12-30 12:49 EST)
--------------------

Major changes to restructure cache and node object model

  JBossCache  tests/functional/org/jboss/cache/optimistic/AsyncCacheTest.java                                        1.7
  JBossCache  tests/functional/org/jboss/cache/optimistic/ThreadedCacheAccessTest.java                               1.5
  JBossCache  tests/functional/org/jboss/cache/optimistic/OptimisticCreateIfNotExistsInterceptorTest.java            1.13
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorKeyValTest.java                             1.12
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java                             1.11
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java                   1.11
  JBossCache  tests/functional/org/jboss/cache/optimistic/OptimisticWithCacheLoaderTest.java                         1.14
  JBossCache  tests/functional/org/jboss/cache/optimistic/OptimisticVersioningTest.java                              1.6
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java                         1.14
  JBossCache  tests/functional/org/jboss/cache/optimistic/TxInterceptorTest.java                                     1.18
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeyValTest.java                          1.11
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutEraseTest.java                           1.11
  JBossCache  tests/functional/org/jboss/cache/optimistic/ThreadedOptimisticCreateIfNotExistsInterceptorTest.java    1.18
  JBossCache  tests/functional/org/jboss/cache/optimistic/VersioningOnReadTest.java                                  1.3
  JBossCache  tests/functional/org/jboss/cache/optimistic/ValidatorInterceptorTest.java                              1.16
  JBossCache  tests/functional/org/jboss/cache/optimistic/ValidationFailureTest.java                                 1.3
  JBossCache  tests/functional/org/jboss/cache/optimistic/CacheTest.java                                             1.26
  JBossCache  tests/functional/org/jboss/cache/optimistic/OptimisticWithPassivationTest.java                         1.14
  JBossCache  tests/functional/org/jboss/cache/optimistic/FullStackInterceptorTest.java                              1.20
  JBossCache  tests/functional/org/jboss/cache/optimistic/OpLockingInterceptorTest.java                              1.17
  JBossCache  tests/functional/org/jboss/cache/optimistic/AbstractOptimisticTestCase.java                            1.43
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveKeyValTest.java                       1.11
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorTransactionTest.java                        1.9
  JBossCache  tests/functional/org/jboss/cache/optimistic/AsyncFullStackInterceptorTest.java                         1.7
  JBossCache  tests/functional/org/jboss/cache/optimistic/OptimisticReplicationInterceptorTest.java                  1.19
  JBossCache  tests/functional/org/jboss/cache/optimistic/RemoveBeforeCreateTest.java                                1.4
  JBossCache  tests/functional/org/jboss/cache/optimistic/ConcurrentTransactionTest.java                             1.5
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveDataTest.java                         1.12
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeysTest.java                            1.11
  JBossCache  tests/functional/org/jboss/cache/optimistic/MockInterceptor.java                                       1.7
  JBossCache  etc/META-INF/mux-service.xml                                                                           1.5
  JBossCache  etc/META-INF/tree-service.xml                                                                          1.7
  JBossCache  etc/META-INF/invalidationAsync-service.xml                                                             1.7
  JBossCache  etc/META-INF/local-elementsize-eviction-service.xml                                                    1.6
  JBossCache  etc/META-INF/pojocache-passivation-service.xml                                                         1.4
  JBossCache  etc/META-INF/interopCurSync-service.xml                                                                1.7
  JBossCache  etc/META-INF/node2.xml                                                                                 1.14
  JBossCache  etc/META-INF/node1.xml                                                                                 1.14
  JBossCache  etc/META-INF/replAsyncSharedCacheLoader-service.xml                                                    1.14
  JBossCache  etc/META-INF/replSync-passivation-service.xml                                                          1.6
  JBossCache  etc/META-INF/replAsync-optimistic-service.xml                                                          1.13
  JBossCache  etc/META-INF/local-eviction-cacheloader-service.xml                                                    1.3
  JBossCache  etc/META-INF/optimistic-eviction.xml                                                                   1.3
  JBossCache  etc/META-INF/interopCurAsync-service.xml                                                               1.7
  JBossCache  etc/META-INF/replSync-service.xml                                                                      1.14
  JBossCache  etc/META-INF/local-passivation-service.xml                                                             1.10
  JBossCache  etc/META-INF/interopPrevAsync-service.xml                                                              1.6
  JBossCache  etc/META-INF/local-mru-eviction-service.xml                                                            1.8
  JBossCache  etc/META-INF/oodb-service.xml                                                                          1.14
  JBossCache  etc/META-INF/policyPerRegion-eviction-service.xml                                                      1.7
  JBossCache  etc/META-INF/local-fifo-eviction-service.xml                                                           1.8
  JBossCache  etc/META-INF/local-lru-eviction-service.xml                                                            1.8
  JBossCache  etc/META-INF/singleton-nopush-service.xml                                                              1.2
  JBossCache  etc/META-INF/optimal-for-large-cluster-http-session-repl.xml                                           1.13
  JBossCache  etc/META-INF/local-service.xml                                                                         1.12
  JBossCache  etc/META-INF/invalidationSync-service.xml                                                              1.7
  JBossCache  etc/META-INF/replSync-ChainingCacheLoader-service.xml                                                  1.12
  JBossCache  etc/META-INF/replSync-optimistic-service.xml                                                           1.12
  JBossCache  etc/META-INF/local-lfu-eviction-service.xml                                                            1.9
  JBossCache  etc/META-INF/mixedPolicy-eviction-service.xml                                                          1.7
  JBossCache  etc/META-INF/buddyreplication-service.xml                                                              1.10
  JBossCache  etc/META-INF/replSync-ClusteredCacheLoader-service.xml                                                 1.11
  JBossCache  etc/META-INF/replAsync-service.xml                                                                     1.13
  JBossCache  etc/META-INF/hibernate-recommended-config.xml                                                          1.10
  JBossCache  etc/META-INF/singleton-push-service.xml                                                                1.2
  JBossCache  etc/META-INF/local-tx-service.xml                                                                      1.4
  JBossCache  etc/META-INF/replSync-eviction-service.xml                                                             1.8
  JBossCache  etc/META-INF/interopPrevSync-service.xml                                                               1.6
  JBossCache  tests/functional/org/jboss/cache/api/SyncReplTxTest.java                                               1.3
  JBossCache  tests/functional/org/jboss/cache/api/NodeAPITest.java                                                  1.7
  JBossCache  tests/functional/org/jboss/cache/api/NodeReplicatedMoveTest.java                                       1.6
  JBossCache  tests/functional/org/jboss/cache/api/CacheAPITest.java                                                 1.7
  JBossCache  tests/functional/org/jboss/cache/api/NodeMoveAPITest.java                                              1.15
  JBossCache  tests/functional/org/jboss/cache/api/SyncReplTest.java                                                 1.6
  JBossCache  examples/PojoCache/non-annotated/build.xml                                                             1.4
  JBossCache  tests/functional/org/jboss/cache/transaction/TransactionTest.java                                      1.20
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelRepeatableReadTest.java                     1.3
  JBossCache  tests/functional/org/jboss/cache/transaction/AbortionTest.java                                         1.5
  JBossCache  tests/functional/org/jboss/cache/transaction/InvocationContextCleanupTest.java                         1.5
  JBossCache  tests/functional/org/jboss/cache/transaction/ReplicatedTransactionDeadlockTest.java                    1.6
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedTest.java                      1.12
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelReadCommittedNodeCreationRollbackTest.java  1.4
  JBossCache  tests/functional/org/jboss/cache/transaction/PrepareTxTest.java                                        1.5
  JBossCache  tests/functional/org/jboss/cache/transaction/ConcurrentTransactionalTest.java                          1.6
  JBossCache  tests/functional/org/jboss/cache/transaction/SuspendTxTest.java                                        1.4
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelSerializableTest.java                       1.3
  JBossCache  tests/functional/org/jboss/cache/transaction/DeadlockTest.java                                         1.8
  JBossCache  tests/functional/org/jboss/cache/transaction/ConcurrentBankTest.java                                   1.7
  JBossCache  tests/functional/org/jboss/cache/transaction/IsolationLevelNoneTest.java                               1.6
  JBossCache  src-50/org/jboss/cache/pojo/collection/CachedListImpl.java                                             1.13
  JBossCache  src-50/org/jboss/cache/pojo/collection/CachedSetImpl.java                                              1.13
  JBossCache  src-50/org/jboss/cache/pojo/collection/CachedMapImpl.java                                              1.15
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java                                        1.37
  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java                                   1.47
  JBossCache  src/org/jboss/cache/interceptors/CallInterceptor.java                                                  1.16
  JBossCache  src/org/jboss/cache/interceptors/CreateIfNotExistsInterceptor.java                                     1.21
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java                                       1.39
  JBossCache  src/org/jboss/cache/interceptors/CacheMgmtInterceptor.java                                             1.25
  JBossCache  src/org/jboss/cache/interceptors/InvalidationInterceptor.java                                          1.29
  JBossCache  src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java                           1.33
  JBossCache  src/org/jboss/cache/interceptors/CacheStoreInterceptor.java                                            1.40
  JBossCache  src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java                                           1.65
  JBossCache  src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java                                        1.31
  JBossCache  src/org/jboss/cache/interceptors/TxInterceptor.java                                                    1.69
  JBossCache  src/org/jboss/cache/interceptors/ActivationInterceptor.java                                            1.45
  JBossCache  src/org/jboss/cache/interceptors/OptimisticLockingInterceptor.java                                     1.24
  JBossCache  src/org/jboss/cache/interceptors/PassivationInterceptor.java                                           1.35
  JBossCache  tests/functional/org/jboss/cache/options/CacheModeLocalSimpleTest.java                                 1.6
  JBossCache  tests/functional/org/jboss/cache/options/SuppressLockingTest.java                                      1.9
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsTest.java                                     1.9
  JBossCache  tests/functional/org/jboss/cache/options/ExplicitVersionsReplTest.java                                 1.6
  JBossCache  tests/functional/org/jboss/cache/options/FailSilentlyTest.java                                         1.7
  JBossCache  tests/functional/org/jboss/cache/CallbackTest.java                                                     1.14
  JBossCache  tests/functional/org/jboss/cache/GetKeysTest.java                                                      1.3
  JBossCache  tests/functional/org/jboss/cache/LifeCycleTest.java                                                    1.6
  JBossCache  tests/functional/org/jboss/cache/TreeNodeTest.java                                                     1.4
  JBossCache  tests/functional/org/jboss/cache/HungChannelTest.java                                                  1.3
- JBossCache  tests/functional/org/jboss/cache/NodeImplTest.java                                                     1.2
  JBossCache  tests/functional/org/jboss/cache/FqnTest.java                                                          1.17
+ JBossCache  tests/functional/org/jboss/cache/UnversionedNodeTest.java                                              1.1
  JBossCache  tests/functional/org/jboss/cache/TreeCacheFunctionalTest.java                                          1.6
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                                                 1.56
- JBossCache  src/org/jboss/cache/OptimisticTreeNode.java                                                            1.17
+ JBossCache  src/org/jboss/cache/VersionedNode.java                                                                 1.1
  JBossCache  src/org/jboss/cache/Cache.java                                                                         1.16
+ JBossCache  src/org/jboss/cache/CacheImpl.java                                                                     1.1
  JBossCache  src/org/jboss/cache/RPCManager.java                                                                    1.5
  JBossCache  src/org/jboss/cache/CacheSPI.java                                                                      1.23
  JBossCache  src/org/jboss/cache/AbstractNode.java                                                                  1.24
  JBossCache  src/org/jboss/cache/Version.java                                                                       1.26
- JBossCache  src/org/jboss/cache/TreeCacheProxyImpl.java                                                            1.55
  JBossCache  src/org/jboss/cache/ConsoleListener.java                                                               1.11
  JBossCache  src/org/jboss/cache/RegionImpl.java                                                                    1.16
  JBossCache  src/org/jboss/cache/TreeCacheView2.java                                                                1.18
+ JBossCache  src/org/jboss/cache/UnversionedNode.java                                                               1.1
  JBossCache  src/org/jboss/cache/RegionNotEmptyException.java                                                       1.2
- JBossCache  src/org/jboss/cache/DataNode.java                                                                      1.21
  JBossCache  src/org/jboss/cache/ReplicationQueue.java                                                              1.12
- JBossCache  src/org/jboss/cache/NodeImpl.java                                                                      1.32
  JBossCache  src/org/jboss/cache/RegionManager.java                                                                 1.17
  JBossCache  src/org/jboss/cache/TransactionEntry.java                                                              1.18
- JBossCache  src/org/jboss/cache/TreeNode.java                                                                      1.31
- JBossCache  src/org/jboss/cache/TreeCache.java                                                                     1.302
  JBossCache  src/org/jboss/cache/NodeSPI.java                                                                       1.6
  JBossCache  src/org/jboss/cache/TreeCacheView.java                                                                 1.18
  JBossCache  src/org/jboss/cache/Fqn.java                                                                           1.43
  JBossCache  src/org/jboss/cache/Node.java                                                                          1.51
  JBossCache  src/org/jboss/cache/TransactionManagerLookup.java                                                      1.3
  JBossCache  src-50/org/jboss/cache/pojo/PojoTreeCache.java                                                         1.17
  JBossCache  tests/functional/org/jboss/cache/mgmt/MgmtCoreTest.java                                                1.8
  JBossCache  tests/functional/org/jboss/cache/mgmt/InvalidationTest.java                                            1.9
  JBossCache  tests/functional/org/jboss/cache/mgmt/TxTest.java                                                      1.9
  JBossCache  tests/functional/org/jboss/cache/mgmt/NotificationTest.java                                            1.15
  JBossCache  tests/functional/org/jboss/cache/mgmt/CacheLoaderTest.java                                             1.10
  JBossCache  tests/functional/org/jboss/cache/mgmt/PassivationTest.java                                             1.8
  JBossCache  tests/functional/org/jboss/cache/marshall/RegionManagerTest.java                                       1.7
  JBossCache  tests/functional/org/jboss/cache/marshall/AsyncReplTest.java                                           1.13
  JBossCache  tests/functional/org/jboss/cache/marshall/SyncReplTest.java                                            1.14
  JBossCache  tests/functional/org/jboss/cache/marshall/ActiveInactiveTest.java                                      1.12
  JBossCache  tests/functional/org/jboss/cache/marshall/ReplicateToInactiveRegionTest.java                           1.2
  JBossCache  tests/functional/org/jboss/cache/marshall/LocalTest.java                                               1.11
  JBossCache  tests/functional/org/jboss/cache/marshall/RedeploymentEmulationTest.java                               1.4
  JBossCache  src/org/jboss/cache/factories/NodeFactory.java                                                         1.16
  JBossCache  src/org/jboss/cache/factories/CacheFactoryTest.java                                                    1.5
  JBossCache  src/org/jboss/cache/factories/DefaultCacheFactory.java                                                 1.12
  JBossCache  src/org/jboss/cache/factories/CacheFactory.java                                                        1.4
  JBossCache  src/org/jboss/cache/factories/InterceptorChainFactory.java                                             1.35
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferManager.java                                            1.20
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java                                  1.10
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java                                   1.8
  JBossCache  src/org/jboss/cache/statetransfer/StateTransferFactory.java                                            1.13
  JBossCache  tests/functional/org/jboss/cache/loader/AsyncFileCacheLoaderTest.java                                  1.17
  JBossCache  tests/functional/org/jboss/cache/loader/DataSourceIntegrationTest.java                                 1.10
  JBossCache  tests/functional/org/jboss/cache/loader/SharedCacheLoaderTest.java                                     1.8
  JBossCache  tests/functional/org/jboss/cache/loader/InterceptorSynchronizationTest.java                            1.6
  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderMethodCallCounterTest.java                          1.12
  JBossCache  tests/functional/org/jboss/cache/loader/ChainingCacheLoaderFullTest.java                               1.9
  JBossCache  tests/functional/org/jboss/cache/loader/TxCacheLoaderTest.java                                         1.8
  JBossCache  tests/functional/org/jboss/cache/loader/LocalDelegatingCacheLoaderTest.java                            1.15
  JBossCache  tests/functional/org/jboss/cache/loader/SingletonStoreCacheLoaderTest.java                             1.4
  JBossCache  tests/functional/org/jboss/cache/loader/BdbjeTest.java                                                 1.15
  JBossCache  tests/functional/org/jboss/cache/loader/ClusteredCacheLoaderTest.java                                  1.11
  JBossCache  tests/functional/org/jboss/cache/loader/DummyCacheLoader.java                                          1.7
  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderWithReplicationTest.java                            1.25
  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderTestsBase.java                                      1.39
  JBossCache  tests/functional/org/jboss/cache/loader/RpcDelegatingCacheLoaderTests.java                             1.9
  JBossCache  tests/functional/org/jboss/cache/loader/CacheLoaderPurgingTest.java                                    1.7
  JBossCache  tests/functional/org/jboss/cache/eviction/LFUAlgorithmTest.java                                        1.7
  JBossCache  tests/functional/org/jboss/cache/eviction/EvictionConfigurationTest.java                               1.12
  JBossCache  tests/functional/org/jboss/cache/eviction/ProgrammaticLRUPolicyTest.java                               1.8
  JBossCache  tests/functional/org/jboss/cache/eviction/ElementSizePolicyTest.java                                   1.10
  JBossCache  tests/functional/org/jboss/cache/eviction/FIFOPolicyTest.java                                          1.11
  JBossCache  tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java                                    1.4
  JBossCache  tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java                                  1.6
  JBossCache  tests/functional/org/jboss/cache/eviction/RegionManagerTest.java                                       1.18
  JBossCache  tests/functional/org/jboss/cache/eviction/LFUPolicyTest.java                                           1.9
  JBossCache  tests/functional/org/jboss/cache/eviction/LRUPolicyTest.java                                           1.20
  JBossCache  tests/functional/org/jboss/cache/eviction/ReplicatedLRUPolicyTest.java                                 1.15
  JBossCache  tests/functional/org/jboss/cache/eviction/OptimisticEvictionTest.java                                  1.9
  JBossCache  tests/functional/org/jboss/cache/eviction/MRUPolicyTest.java                                           1.11
  JBossCache  tests/functional/org/jboss/cache/eviction/DummyEvictionPolicy.java                                     1.3
  JBossCache  tests/stress/org/jboss/cache/optimistic/OptimisticDeadlockTest.java                                    1.6
  JBossCache  src/org/jboss/cache/lock/LockUtil.java                                                                 1.6
  JBossCache  tests/functional/org/jboss/cache/lock/UpgradeLockTest.java                                             1.6
  JBossCache  tests/functional/org/jboss/cache/lock/BreakDeadMemberLocksTest.java                                    1.4
  JBossCache  tests/functional/org/jboss/cache/lock/AcquireAllTest.java                                              1.8
  JBossCache  tests/functional/org/jboss/cache/lock/LockReleaseTest.java                                             1.6
  JBossCache  examples/PojoCache/passivation/build.xml                                                               1.2
  JBossCache  tests-50/functional/org/jboss/cache/pojo/TestingUtil.java                                              1.4
  JBossCache  tests-50/functional/org/jboss/cache/pojo/CircularGraphTest.java                                        1.5
  JBossCache  tests-50/functional/org/jboss/cache/pojo/NewLocalTest.java                                             1.12
  JBossCache  tests-50/functional/org/jboss/cache/pojo/NewReplicatedTest.java                                        1.8
  JBossCache  src/org/jboss/cache/jmx/CacheJmxWrapper.java                                                           1.9
  JBossCache  src/org/jboss/cache/jmx/CacheLegacyJmxWrapperMBean.java                                                1.3
  JBossCache  src/org/jboss/cache/jmx/Cache.java                                                                     1.6
  JBossCache  tests/scripts/bench.xml                                                                                1.7
  JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransfer200Test.java                               1.12
  JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java                              1.27
  JBossCache  tests/functional/org/jboss/cache/statetransfer/FailedStateTransferTest.java                            1.8
  JBossCache  tests/functional/org/jboss/cache/passivation/PassivationToLocalDelegatingCacheLoaderTest.java          1.8
  JBossCache  tests/functional/org/jboss/cache/passivation/LocalPassivationIntegrationTest.java                      1.13
  JBossCache  tests/functional/org/jboss/cache/passivation/BasicPassivationTest.java                                 1.13
  JBossCache  tests/functional/org/jboss/cache/passivation/ReplicatedPassivationIntegrationTest.java                 1.4
  JBossCache  tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java                            1.8
  JBossCache  tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java                                 1.22
  JBossCache  tests-50/functional/org/jboss/cache/pojo/region/LocalTest.java                                         1.7
  JBossCache  tests-50/functional/org/jboss/cache/pojo/region/NewLocalTest.java                                      1.6
  JBossCache  examples/PojoCache/loadtime/build.xml                                                                  1.5
  JBossCache  tests/functional/org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest.java                   1.8
  JBossCache  tests/functional/org/jboss/cache/notifications/CacheListenerTest.java                                  1.10
  JBossCache  tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java                            1.3
  JBossCache  src/org/jboss/cache/config/Configuration.java                                                          1.28
  JBossCache  src/org/jboss/cache/config/ConfigurationComponent.java                                                 1.3
  JBossCache  src-50/org/jboss/cache/pojo/util/CacheApiUtil.java                                                     1.4
  JBossCache  tests/perf/org/jboss/cache/LocalMapPerfTest.java                                                       1.6
  JBossCache  tests/perf/org/jboss/cache/ConcurrentEvictAndRemoveTest.java                                           1.7
  JBossCache  tests/perf/org/jboss/cache/LocalPerfTest.java                                                          1.6
  JBossCache  tests/perf/org/jboss/cache/ReplicatedAsyncMapPerfTest.java                                             1.7
  JBossCache  tests/perf/org/jboss/cache/ReplicatedAsyncPerfTest.java                                                1.5
  JBossCache  tests/perf/org/jboss/cache/ReplicatedSyncPerfTest.java                                                 1.5
  JBossCache  tests/perf/org/jboss/cache/ReplicatedSyncMapPerfTest.java                                              1.6
  JBossCache  tests/perf/org/jboss/cache/loader/JDBCCacheLoaderPerfTest.java                                         1.10
  JBossCache  tests/perf/org/jboss/cache/loader/CacheLoaderPerfTest.java                                             1.10
  JBossCache  src/org/jboss/cache/loader/rmi/RmiCacheServerMBean.java                                                1.4
  JBossCache  src/org/jboss/cache/loader/rmi/RemoteTreeCacheImpl.java                                                1.11
  JBossCache  src/org/jboss/cache/loader/rmi/RmiCacheServer.java                                                     1.9
  JBossCache  src/org/jboss/cache/loader/rmi/RemoteTreeCache.java                                                    1.9
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationFailoverTest.java                    1.19
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyBackupActivationInactivationTest.java           1.13
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationContentTest.java                     1.14
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyAssignmentStateTransferTest.java                1.10
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyGroupAssignmentTest.java                        1.14
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationConfigTest.java                      1.12
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationWithTransactionsTest.java            1.5
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationTestsBase.java                       1.34
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyPoolBroadcastTest.java                          1.17
  JBossCache  tests/functional/org/jboss/cache/buddyreplication/BuddyReplicationWithCacheLoaderTest.java             1.6
  JBossCache  etc/tree-service.xml                                                                                   1.11
  JBossCache  etc/build.xml                                                                                          1.19
  JBossCache  etc/jdbcCacheLoader-service.xml                                                                        1.11
  JBossCache  src/org/jboss/cache/loader/tcp/TcpCacheServer.java                                                     1.22
  JBossCache  src/org/jboss/cache/loader/tcp/TcpCacheServerMBean.java                                                1.5
  JBossCache  tests/functional/org/jboss/cache/options/cachemodelocal/CacheModeLocalTestBase.java                    1.8
  JBossCache  src/org/jboss/cache/loader/RmiDelegatingCacheLoader.java                                               1.15
  JBossCache  src/org/jboss/cache/loader/ClusteredCacheLoader.java                                                   1.20
  JBossCache  src/org/jboss/cache/loader/LocalDelegatingCacheLoader.java                                             1.13
  JBossCache  src/org/jboss/cache/loader/CacheLoader.java                                                            1.12
  JBossCache  src/org/jboss/cache/loader/RpcDelegatingCacheLoader.java                                               1.14
  JBossCache  src/org/jboss/cache/loader/DelegatingCacheLoader.java                                                  1.13
  JBossCache  src/org/jboss/cache/loader/FileCacheLoader.java                                                        1.28
  JBossCache  src/org/jboss/cache/loader/TcpDelegatingCacheLoader.java                                               1.7
  JBossCache  src-50/org/jboss/cache/pojo/interceptors/dynamic/CacheFieldInterceptor.java                            1.13
  JBossCache  src-50/org/jboss/cache/pojo/impl/PojoCacheDelegate.java                                                1.18
  JBossCache  tests/functional/org/jboss/cache/misc/TestingUtil.java                                                 1.11
  JBossCache  src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java                                                 1.24
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                                                  1.33
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNode.java                                                      1.18
  JBossCache  tests/stress/org/jboss/cache/LocalStressTest.java                                                      1.9
  JBossCache  tests/stress/org/jboss/cache/EvictionLocalStressTest.java                                              1.8
  JBossCache  tests/perf/org/jboss/cache/manualtests/TcpCacheLoaderTest.java                                         1.4
  JBossCache  tests-50/functional/org/jboss/cache/pojo/passivation/ReplicatedTest.java                               1.9
  JBossCache  tests-50/functional/org/jboss/cache/pojo/passivation/LocalTest.java                                    1.10
  JBossCache  tests/functional/org/jboss/cache/invocationcontext/TransactionTest.java                                1.5
  JBossCache  examples/PojoCache/sensor/build.xml                                                                    1.4
  JBossCache  tests/functional/org/jboss/cache/replicated/SyncReplTxTest.java                                        1.16
  JBossCache  tests/functional/org/jboss/cache/replicated/ReplicationExceptionTest.java                              1.5
  JBossCache  tests/functional/org/jboss/cache/replicated/SyncCacheListenerTest.java                                 1.12
  JBossCache  tests/functional/org/jboss/cache/replicated/AsyncReplTest.java                                         1.12
  JBossCache  tests/functional/org/jboss/cache/replicated/SyncReplTest.java                                          1.4
  JBossCache  src/org/jboss/cache/eviction/LRUPolicy.java                                                            1.12
  JBossCache  src/org/jboss/cache/eviction/BaseEvictionPolicy.java                                                   1.6
  JBossCache  src/org/jboss/cache/eviction/EvictionPolicy.java                                                       1.9
  JBossCache  tests/functional/org/jboss/cache/invalidation/InvalidationInterceptorTest.java                         1.19
  JBossCache  src/org/jboss/cache/marshall/MethodDeclarations.java                                                   1.28
  JBossCache  src/org/jboss/cache/marshall/TreeCacheMarshaller200.java                                               1.12
  JBossCache  src/org/jboss/cache/notifications/Notifier.java                                                        1.12
  JBossCache  src/org/jboss/cache/rpc/RpcTreeCache.java                                                              1.12
  JBossCache  tests/functional/org/jboss/cache/jmx/CacheMBeanTest.java                                               1.7
  JBossCache  examples/PojoCache/annotated50/build.xml                                                               1.6
  JBossCache  src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java                                                   1.19
  JBossCache  tests-50/functional/org/jboss/cache/pojo/statetransfer/ReplicatedTest.java                             1.3
  JBossCache  src/org/jboss/cache/util/setCache.java                                                                 1.2
  JBossCache  tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java                             1.18
  JBossCache  tests/functional/org/jboss/cache/config/ConfigurationTest.java                                         1.8
  JBossCache  tests/functional/org/jboss/cache/factories/InterceptorChainFactoryTest.java                            1.6


Commit from msurtani (2006-12-30 14:48 EST)
--------------------

Genericised, autoboxed

  JBossCache  src/org/jboss/cache/loader/JDBCCacheLoaderConfig.java                                 1.2
  JBossCache  src/org/jboss/cache/loader/CacheLoader.java                                           1.13
  JBossCache  src/org/jboss/cache/loader/AsynchCacheLoaderConfig.java                               1.2
  JBossCache  src/org/jboss/cache/loader/AbstractCacheLoader.java                                   1.13
  JBossCache  src/org/jboss/cache/loader/JDBCCacheLoader.java                                       1.26
  JBossCache  src/org/jboss/cache/loader/ClusteredCacheLoader.java                                  1.21
  JBossCache  src/org/jboss/cache/loader/FileCacheLoaderConfig.java                                 1.3
  JBossCache  src/org/jboss/cache/loader/RpcDelegatingCacheLoader.java                              1.15
  JBossCache  src/org/jboss/cache/loader/ChainingCacheLoader.java                                   1.14
  JBossCache  src/org/jboss/cache/loader/ClusteredCacheLoaderConfig.java                            1.2
  JBossCache  src/org/jboss/cache/notifications/Notifier.java                                       1.13
  JBossCache  src/org/jboss/cache/buddyreplication/GravitateResult.java                             1.5
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyGroup.java                                  1.10
  JBossCache  src/org/jboss/cache/buddyreplication/BuddyManager.java                                1.57
  JBossCache  src/org/jboss/cache/buddyreplication/NextMemberBuddyLocator.java                      1.9
  JBossCache  src/org/jboss/cache/xml/XmlHelper.java                                                1.13
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferIntegrator.java                 1.11
  JBossCache  src/org/jboss/cache/statetransfer/DefaultStateTransferGenerator.java                  1.9
  JBossCache  tests/functional/org/jboss/cache/transaction/TransactionTest.java                     1.21
  JBossCache  tests/functional/org/jboss/cache/transaction/ConcurrentTransactionalTest.java         1.7
  JBossCache  tests/functional/org/jboss/cache/transaction/ConcurrentBankTest.java                  1.8
  JBossCache  tests/functional/org/jboss/cache/eviction/ElementSizePolicyTest.java                  1.11
  JBossCache  tests/functional/org/jboss/cache/eviction/ConcurrentEvictionTest.java                 1.7
  JBossCache  tests/functional/org/jboss/cache/eviction/FIFOPolicyTest.java                         1.12
  JBossCache  tests/functional/org/jboss/cache/eviction/LFUPolicyTest.java                          1.10
  JBossCache  tests/functional/org/jboss/cache/eviction/MRUPolicyTest.java                          1.12
  JBossCache  tests/functional/org/jboss/cache/eviction/LRUPolicyTest.java                          1.21
  JBossCache  tests/functional/org/jboss/cache/eviction/ProgrammaticLRUPolicyTest.java              1.9
  JBossCache  tests/functional/org/jboss/cache/eviction/ExpirationPolicyTest.java                   1.5
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java                       1.38
  JBossCache  src/org/jboss/cache/interceptors/CacheStoreInterceptor.java                           1.41
  JBossCache  src/org/jboss/cache/interceptors/DataGravitatorInterceptor.java                       1.32
  JBossCache  src/org/jboss/cache/interceptors/ActivationInterceptor.java                           1.46
  JBossCache  src/org/jboss/cache/interceptors/EvictionInterceptor.java                             1.11
  JBossCache  src/org/jboss/cache/interceptors/Interceptor.java                                     1.26
  JBossCache  src/org/jboss/cache/CacheImpl.java                                                    1.2
  JBossCache  src/org/jboss/cache/CacheListener.java                                                1.4
  JBossCache  src/org/jboss/cache/Fqn.java                                                          1.44
  JBossCache  src/org/jboss/cache/Node.java                                                         1.52
  JBossCache  tests/functional/org/jboss/cache/GetKeysTest.java                                     1.4
  JBossCache  tests/functional/org/jboss/cache/TreeNodeTest.java                                    1.5
  JBossCache  tests/functional/org/jboss/cache/FqnTest.java                                         1.18
  JBossCache  tests/functional/org/jboss/cache/TreeCacheFunctionalTest.java                         1.7
  JBossCache  tests/functional/org/jboss/cache/mgmt/MgmtCoreTest.java                               1.9
  JBossCache  tests/functional/org/jboss/cache/mgmt/InvalidationTest.java                           1.10
  JBossCache  tests/functional/org/jboss/cache/mgmt/TxTest.java                                     1.10
  JBossCache  tests/functional/org/jboss/cache/mgmt/CacheLoaderTest.java                            1.11
  JBossCache  tests/functional/org/jboss/cache/mgmt/PassivationTest.java                            1.9
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNode.java                                     1.19
  JBossCache  src/org/jboss/cache/optimistic/FqnComparator.java                                     1.7
  JBossCache  src/org/jboss/cache/optimistic/TransactionWorkspace.java                              1.13
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                                 1.34
  JBossCache  tests/functional/org/jboss/cache/replicated/AsyncReplTest.java                        1.13
  JBossCache  tests/functional/org/jboss/cache/passivation/ConcurrentPassivationTest.java           1.9
  JBossCache  tests/functional/org/jboss/cache/passivation/PassivationTestsBase.java                1.23
  JBossCache  tests/functional/org/jboss/cache/passivation/PassivationToFileCacheLoaderTest.java    1.8
  JBossCache  src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java                                  1.20
  JBossCache  src/org/jboss/cache/factories/InterceptorChainFactory.java                            1.36
  JBossCache  tests/functional/org/jboss/cache/loader/BdbjeTest.java                                1.16
  JBossCache  src/org/jboss/cache/transaction/DummyUserTransaction.java                             1.5
  JBossCache  src/org/jboss/cache/transaction/DummyBaseTransactionManager.java                      1.4
  JBossCache  tests/functional/org/jboss/cache/interceptors/EvictionInterceptorTest.java            1.19
  JBossCache  tests/functional/org/jboss/cache/optimistic/ComparatorTest.java                       1.7
  JBossCache  tests-50/functional/org/jboss/cache/pojo/collection/CachedMapTest.java                1.6
  JBossCache  src/org/jboss/cache/config/EvictionConfig.java                                        1.7
  JBossCache  src/org/jboss/cache/config/ConfigurationComponent.java                                1.4
  JBossCache  src/org/jboss/cache/config/Configuration.java                                         1.29
  JBossCache  src/org/jboss/cache/config/EvictionRegionConfig.java                                  1.3
  JBossCache  src/org/jboss/cache/loader/tcp/TcpCacheServer.java                                    1.23
  JBossCache  src/org/jboss/cache/eviction/ExpirationAlgorithm.java                                 1.4
  JBossCache  tests/functional/org/jboss/cache/statetransfer/VersionedTestBase.java                 1.22
  JBossCache  tests/functional/org/jboss/cache/statetransfer/StateTransferTestBase.java             1.28
  JBossCache  tests-50/functional/org/jboss/cache/pojo/util/MethodCallTest.java                     1.5
  JBossCache  src/org/jboss/cache/util/MapCopy.java                                                 1.6
  JBossCache  src/org/jboss/cache/marshall/Marshaller.java                                          1.7
  JBossCache  tests/functional/org/jboss/cache/loader/deadlock/ConcurrentCreationDeadlockTest.java  1.9
  JBossCache  tests-50/functional/org/jboss/cache/pojo/statetransfer/StateTransferAopTestBase.java  1.7
  JBossCache  src-50/org/jboss/cache/pojo/collection/CollectionInterceptorUtil.java                 1.9
  JBossCache  src/org/jboss/cache/loader/bdbje/BdbjeCacheLoader.java                                1.25
  JBossCache  src-50/org/jboss/cache/pojo/jmx/JmxUtil.java                                          1.6


Commit from vralev (2006-12-30 15:10 EST)
------------------

preselecte="no" packs are not being installed

+   repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/component-info.xml                   1.1
+   repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib/grouppackmapper-anttask-1.0.jar  1.1


Commit from vralev (2006-12-30 15:22 EST)
------------------

http://jira.jboss.com/jira/browse/JBINSTALL-175

    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/standalone-compiler.jar  1.4
    repository.jboss.com/izpack/3.9.0.jboss.patch3/lib/compiler.jar             1.2


Commit from vralev (2006-12-30 15:49 EST)
------------------

http://jira.jboss.com/jira/browse/JBINSTALL-176

    repository.jboss.com/jboss/jboss-install-tools/grouppackmapper-anttask/1.0.1/lib/grouppackmapper-anttask-1.0.jar  1.2


Commit from sbryzak2 (2006-12-30 20:18 EST)
--------------------

removed proprietary authentication stuff, replaced with JAAS authentication

  jboss-seam  src/main/org/jboss/seam/security/SeamSecurityManager.java                  1.32
  jboss-seam  src/main/org/jboss/seam/security/config/SecurityConfiguration.java         1.8
- jboss-seam  src/main/org/jboss/seam/security/adapter/AuthenticationAdapter.java        1.4
- jboss-seam  src/main/org/jboss/seam/security/authenticator/Authenticator.java          1.18
- jboss-seam  src/main/org/jboss/seam/security/authenticator/ProviderAuthenticator.java  1.13
- jboss-seam  src/main/org/jboss/seam/security/provider/AuthenticationProvider.java      1.9


Commit from sbryzak2 (2006-12-30 20:26 EST)
--------------------

use login module instead of auth provider

  jboss-seam  examples/seamspace/resources/META-INF/security-config.xml                         1.3
  jboss-seam  examples/seamspace/resources/WEB-INF/components.xml                               1.10
  jboss-seam  examples/seamspace/src/org/jboss/seam/example/seamspace/AuthenticatorAction.java  1.3


Commit from sbryzak2 (2006-12-30 20:31 EST)
--------------------

login module configuration

+ jboss-seam  src/main/org/jboss/seam/security/config/LoginModuleConfiguration.java  1.1


Commit from msurtani (2006-12-30 21:08 EST)
--------------------

Updates to tests to go along with changes in node methods

  JBossCache  tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java           1.4
  JBossCache  tests/functional/org/jboss/cache/notifications/CacheListenerTest.java                 1.11
  JBossCache  tests/functional/org/jboss/cache/options/cachemodelocal/CacheModeLocalTestBase.java   1.9
  JBossCache  tests/perf/org/jboss/cache/ReplicatedSyncMapPerfTest.java                             1.7
  JBossCache  tests/perf/org/jboss/cache/LocalPerfTest.java                                         1.7
  JBossCache  tests/perf/org/jboss/cache/ReplicatedAsyncPerfTest.java                               1.6
  JBossCache  tests/perf/org/jboss/cache/ReplicatedSyncPerfTest.java                                1.6
  JBossCache  tests/perf/org/jboss/cache/ReplicatedAsyncMapPerfTest.java                            1.8
  JBossCache  tests/perf/org/jboss/cache/LocalMapPerfTest.java                                      1.7
  JBossCache  src-50/org/jboss/cache/pojo/PojoReference.java                                        1.5
  JBossCache  src-50/org/jboss/cache/pojo/CachedType.java                                           1.7
  JBossCache  src-50/org/jboss/cache/pojo/PojoUtil.java                                             1.15
  JBossCache  src-50/org/jboss/cache/pojo/PojoInstance.java                                         1.5
  JBossCache  src/org/jboss/cache/lock/IdentityLock.java                                            1.18
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java                       1.39
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java                      1.40
  JBossCache  src/org/jboss/cache/interceptors/OptimisticInterceptor.java                           1.8
  JBossCache  src/org/jboss/cache/interceptors/CacheStoreInterceptor.java                           1.42
  JBossCache  src/org/jboss/cache/interceptors/OptimisticValidatorInterceptor.java                  1.48
  JBossCache  src-50/org/jboss/cache/pojo/interceptors/dynamic/CacheFieldInterceptor.java           1.14
  JBossCache  src/org/jboss/cache/TreeCacheView.java                                                1.19
  JBossCache  src/org/jboss/cache/CacheImpl.java                                                    1.3
  JBossCache  src/org/jboss/cache/UnversionedNode.java                                              1.2
  JBossCache  src/org/jboss/cache/Fqn.java                                                          1.45
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java  1.12
  JBossCache  tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java        1.15
  JBossCache  tests/functional/org/jboss/cache/FqnTest.java                                         1.19
  JBossCache  tests/functional/org/jboss/cache/loader/DummyInMemoryCacheLoader.java                 1.5
  JBossCache  src/org/jboss/cache/loader/jdbm/JdbmCacheLoader.java                                  1.21
  JBossCache  src-50/org/jboss/cache/pojo/util/MethodCall.java                                      1.3
  JBossCache  src-50/org/jboss/cache/pojo/collection/CachedMapImpl.java                             1.16
  JBossCache  tests/functional/org/jboss/cache/marshall/LocalTest.java                              1.12
  JBossCache  src/org/jboss/cache/loader/AbstractCacheLoader.java                                   1.14
  JBossCache  tests-50/functional/org/jboss/cache/pojo/statetransfer/StateTransferAopTestBase.java  1.8
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                                 1.35


Commit from msurtani (2006-12-30 22:01 EST)
--------------------

move api still WIP

  JBossCache  tests/functional/org/jboss/cache/notifications/RemoteCacheListenerTest.java   1.5
  JBossCache  tests/functional/org/jboss/cache/notifications/CacheListenerTest.java         1.12
  JBossCache  tests/functional/org/jboss/cache/api/NodeReplicatedMoveTest.java              1.7
  JBossCache  tests/functional/org/jboss/cache/api/SyncReplTest.java                        1.7
  JBossCache  tests/functional/org/jboss/cache/api/NodeMoveAPITest.java                     1.16
  JBossCache  src/org/jboss/cache/interceptors/OptimisticNodeInterceptor.java               1.40
  JBossCache  src/org/jboss/cache/interceptors/CacheLoaderInterceptor.java                  1.66
  JBossCache  src/org/jboss/cache/interceptors/OptimisticCreateIfNotExistsInterceptor.java  1.34
  JBossCache  src/org/jboss/cache/interceptors/PessimisticLockInterceptor.java              1.41
  JBossCache  src/org/jboss/cache/interceptors/CacheStoreInterceptor.java                   1.43
  JBossCache  src/org/jboss/cache/Node.java                                                 1.53
  JBossCache  src/org/jboss/cache/CacheImpl.java                                            1.4
  JBossCache  src/org/jboss/cache/Cache.java                                                1.17
  JBossCache  src/org/jboss/cache/UnversionedNode.java                                      1.3
  JBossCache  src/org/jboss/cache/optimistic/WorkspaceNodeImpl.java                         1.36
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-cvs-commits/attachments/20061231/221fe8cf/attachment.html 

From norman.richards at jboss.com  Sun Dec 31 01:50:05 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 31 Dec 2006 01:50:05 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf  ...
Message-ID: <E1H0uWD-0006Fl-PS@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/31 01:50:05

  Modified:    src/pdf/org/jboss/seam/pdf  ITextUtils.java
  Log:
  improved tables
  
  Revision  Changes    Path
  1.3       +33 -0     jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ITextUtils.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ITextUtils.java	26 Dec 2006 06:12:56 -0000	1.2
  +++ ITextUtils.java	31 Dec 2006 06:50:05 -0000	1.3
  @@ -3,7 +3,29 @@
   import com.lowagie.text.*;
   import com.lowagie.text.pdf.*;
   
  +import java.awt.Color;
  +import java.util.HashMap;
  +import java.util.Map;
  +
   public class ITextUtils {
  +	static Map<String,Color> colorMap = new HashMap<String,Color>(); 
  +	
  +	static {
  +		colorMap.put("white", Color.white);
  +		colorMap.put("gray", Color.gray);
  +		colorMap.put("lightgray", Color.lightGray);
  +		colorMap.put("darkgray", Color.darkGray);
  +		colorMap.put("black", Color.black);
  +		colorMap.put("red", Color.red);
  +		colorMap.put("pink", Color.pink);
  +		colorMap.put("yellow", Color.yellow);
  +		colorMap.put("green", Color.green);
  +		colorMap.put("magenta", Color.magenta);
  +		colorMap.put("cyan", Color.cyan);
  +		colorMap.put("blue", Color.blue);
  +	}
  +
  +	
       /**
        *  not all itext objects accept a string value as input,
        *  so we'll copy that logic here. 
  @@ -36,4 +58,15 @@
   
           return Element.ALIGN_UNDEFINED;
       }
  +
  +    /**
  +     * return a color value from a string specification.  
  +     */ 
  +    public static Color colorValue(String colorName) {
  +    	Color color = colorMap.get(colorName.toLowerCase());
  +    	if (color == null) {
  +    	  color = Color.decode(colorName);
  +    	}
  +    	return color;
  +    }
   }
  
  
  


From norman.richards at jboss.com  Sun Dec 31 01:50:06 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 31 Dec 2006 01:50:06 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui    ...
Message-ID: <E1H0uWE-0006G3-1r@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/31 01:50:06

  Modified:    src/pdf/org/jboss/seam/pdf/ui    ITextComponent.java
                        UICell.java UITable.java
  Log:
  improved tables
  
  Revision  Changes    Path
  1.3       +7 -10     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ITextComponent.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- ITextComponent.java	25 Dec 2006 16:17:54 -0000	1.2
  +++ ITextComponent.java	31 Dec 2006 06:50:05 -0000	1.3
  @@ -2,20 +2,15 @@
   
   
   import javax.faces.*;
  -import javax.faces.event.*;
   import javax.faces.context.*;
  -import javax.faces.convert.*;
   import javax.faces.component.*;
  -import javax.servlet.http.*;
  -
  -import java.awt.Color;
   import java.io.*;
   import java.util.List;
   
  +import org.jboss.seam.pdf.ITextUtils;
   import org.jboss.seam.ui.JSF;
   
   import com.lowagie.text.*;
  -import com.lowagie.text.pdf.*;
   
   public abstract class ITextComponent
       extends UIComponentBase
  @@ -134,6 +129,7 @@
           removeITextObject();
       }
   
  +    @SuppressWarnings("unchecked")
       @Override
       public void encodeChildren(FacesContext context)
           throws IOException
  @@ -143,12 +139,13 @@
               if (child.getFamily().equals("facelets.LiteralText")) {
                   String text = replaceEntities(extractText(context, child));
                   Font   font = getFont();
  +                Chunk chunk = null;
                   if (font == null) {
  -                    Chunk chunk = new Chunk(text);
  -                    add(chunk);
  +                    chunk = new Chunk(text);
                   } else {
  -                    add(new Chunk(text, getFont()));
  +                    chunk = new Chunk(text, getFont());
                   }
  +                add(chunk);
               } else {
                   encode(context, child);
               }
  
  
  
  1.3       +107 -12   jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UICell.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UICell.java	26 Dec 2006 06:12:56 -0000	1.2
  +++ UICell.java	31 Dec 2006 06:50:05 -0000	1.3
  @@ -2,16 +2,11 @@
   
   import org.jboss.seam.pdf.ITextUtils;
   
  -import javax.faces.event.*;
  -import javax.faces.context.*;
  -import javax.faces.component.*;
  -import javax.servlet.http.*;
  -
  -import java.io.*;
  -
   import com.lowagie.text.*;
   import com.lowagie.text.pdf.*;
   
  +import java.awt.Color;
  +
   public class UICell
       extends ITextComponent
   {
  @@ -20,6 +15,7 @@
       PdfPCell cell;
       String  horizontalAlignment;
       String  verticalAlignment;
  +    Float   padding;
       Float   paddingLeft;
       Float   paddingRight;
       Float   paddingTop;
  @@ -40,7 +36,42 @@
       Integer arabicOptions;
       Boolean useAscender;
       Integer rotation;
  +    Color borderColor;
  +    Color borderColorLeft;
  +    Color borderColorRight;
  +    Color borderColorTop;
  +    Color borderColorBottom;
  +    Color backgroundColor;
  +    Float grayFill;
  +    Float borderWidth;
  +    Float borderWidthLeft;
  +    Float borderWidthRight; 
  +    Float borderWidthTop;
  +    Float borderWidthBottom;
   
  +    public void setBorderWidth(Float borderWidth) {
  +		this.borderWidth = borderWidth;
  +	}
  +
  +	public void setBorderWidthBottom(Float borderWidthBottom) {
  +		this.borderWidthBottom = borderWidthBottom;
  +	}
  +
  +	public void setBorderWidthLeft(Float borderWidthLeft) {
  +		this.borderWidthLeft = borderWidthLeft;
  +	}
  +
  +	public void setBorderWidthRight(Float borderWidthRight) {
  +		this.borderWidthRight = borderWidthRight;
  +	}
  +
  +	public void setBorderWidthTop(Float borderWidthTop) {
  +		this.borderWidthTop = borderWidthTop;
  +	}
  +
  +	public void setGrayFill(Float grayFill) {
  +        this.grayFill = grayFill;
  +    }
   
       public void setHorizontalAlignment(String horizontalAlignment) {
           this.horizontalAlignment = horizontalAlignment;
  @@ -50,6 +81,10 @@
           this.verticalAlignment = verticalAlignment;
       }
   
  +    public void setPadding(Float padding) {
  +    	this.padding = padding;
  +    }
  +    
       public void setPaddingLeft(Float paddingLeft) {
           this.paddingLeft = paddingLeft;
       }
  @@ -130,7 +165,29 @@
           this.rotation = rotation;
       }
   
  +	public void setBackgroundColor(String backgroundColor) {
  +		this.backgroundColor = ITextUtils.colorValue(backgroundColor);
  +	}
   
  +	public void setBorderColor(String borderColor) {
  +    	this.borderColor = ITextUtils.colorValue(borderColor);
  +    }
  +
  +	public void setBorderColorBottom(String borderColorBottom) {
  +		this.borderColorBottom =  ITextUtils.colorValue(borderColorBottom);
  +	}
  +
  +	public void setBorderColorLeft(String borderColorLeft) {
  +		this.borderColorLeft = ITextUtils.colorValue(borderColorLeft)  ;
  +	}
  +
  +	public void setBorderColorRight(String borderColorRight) {
  +		this.borderColorRight = ITextUtils.colorValue(borderColorRight);
  +	}
  +
  +	public void setBorderColorTop(String borderColorTop) {
  +		this.borderColorTop = ITextUtils.colorValue(borderColorTop);
  +	}
   
       public Object getITextObject() {
           return cell;
  @@ -145,11 +202,13 @@
   
           if (horizontalAlignment != null) {
               cell.setHorizontalAlignment(ITextUtils.alignmentValue(horizontalAlignment));
  -            System.out.println("---> " + cell.getHorizontalAlignment());
           }
           if (verticalAlignment != null) {
               cell.setVerticalAlignment(ITextUtils.alignmentValue(verticalAlignment));
           }
  +        if (padding != null) {
  +        	cell.setPadding(padding);
  +        }
           if (paddingLeft != null) {
               cell.setPaddingLeft(paddingLeft);
           }
  @@ -208,7 +267,42 @@
           if (rotation != null) {
               cell.setRotation(rotation);
           }
  -
  +        if (backgroundColor!=null) {
  +        	cell.setBackgroundColor(backgroundColor);
  +        }
  +        if (borderColor!=null) {
  +        	cell.setBorderColor(borderColor);
  +        }
  +        if (borderColorLeft!=null) {
  +        	cell.setBorderColorLeft(borderColorLeft);
  +        }
  +        if (borderColorRight!=null) {
  +        	cell.setBorderColorRight(borderColorRight);
  +        }     
  +        if (borderColorTop!=null) {
  +        	cell.setBorderColorTop(borderColorTop);
  +        }
  +        if (borderColorBottom!=null) {
  +        	cell.setBorderColorBottom(borderColorBottom);
  +        }    
  +        if (borderWidth!=null) {
  +        	cell.setBorderWidth(borderWidth);
  +        }
  +        if (borderWidthLeft!=null) {
  +        	cell.setBorderWidthLeft(borderWidthLeft);
  +        }
  +        if (borderWidthRight!=null) {
  +        	cell.setBorderWidthRight(borderWidthRight);
  +        }     
  +        if (borderWidthTop!=null) {
  +        	cell.setBorderWidthTop(borderWidthTop);
  +        }
  +        if (borderWidthBottom!=null) {
  +        	cell.setBorderWidthBottom(borderWidthBottom);
  +        }    
  +        if (grayFill!=null) {
  +           cell.setGrayFill(grayFill);
  +        }
       }
   
       public void add(Object o) {
  @@ -219,4 +313,5 @@
                                          " to cell");
           }
       }
  +
   }
  
  
  
  1.2       +139 -13   jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UITable.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UITable.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UITable.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UITable.java	25 Dec 2006 16:17:54 -0000	1.1
  +++ UITable.java	31 Dec 2006 06:50:05 -0000	1.2
  @@ -1,11 +1,5 @@
   package org.jboss.seam.pdf.ui;
   
  -import javax.faces.event.*;
  -import javax.faces.context.*;
  -import javax.faces.component.*;
  -import javax.servlet.http.*;
  -import java.io.*;
  -
   import com.lowagie.text.*;
   import com.lowagie.text.pdf.*;
   
  @@ -15,9 +9,27 @@
       public static final String COMPONENT_TYPE   = "org.jboss.seam.pdf.ui.UITable";
   
       PdfPTable table;
  +    String  widths;
       int columns    = 1;
       Integer headerRows = 0;
       Integer footerRows = 0;
  +    Float   widthPercentage;
  +    Integer horizontalAlignment;
  +    Boolean skipFirstHeader;
  +    Integer runDirection;
  +    Boolean lockedWidth;
  +    Boolean splitRows;
  +    Float   spacingBefore;
  +    Float   spacingAfter;
  +    Boolean extendLastRow;
  +    Boolean headersInEvent;
  +    Boolean splitLate;
  +    Boolean keepTogether;
  +
  +
  +    public void setWidths(String Widths) {
  +    	this.widths = Widths;
  +    }
   
       public void setColumns(int columns) {
           this.columns = columns;
  @@ -31,6 +43,59 @@
           this.footerRows = footerRows;
       }
   
  +    public void setExtendLastRow(Boolean extendLastRow) {
  +        this.extendLastRow = extendLastRow;
  +    }
  +    
  +    public void setHeadersInEvent(Boolean headersInEvent) {
  +        this.headersInEvent = headersInEvent;
  +    }
  +    
  +    public void setHorizontalAlignment(Integer horizontalAlignment) {
  +        this.horizontalAlignment = horizontalAlignment;
  +    }
  +    
  +    public void setKeepTogether(Boolean keepTogether) {
  +        this.keepTogether = keepTogether;
  +    }
  +    
  +    public void setLockedWidth(Boolean lockedWidth) {
  +        this.lockedWidth = lockedWidth;
  +    }
  +    
  +    public void setRunDirection(Integer runDirection) {
  +        this.runDirection = runDirection;
  +    }
  +    
  +    public void setSkipFirstHeader(Boolean skipFirstHeader) {
  +        this.skipFirstHeader = skipFirstHeader;
  +    }
  +    
  +    public void setSpacingAfter(Float spacingAfter) {
  +        this.spacingAfter = spacingAfter;
  +    }
  +    
  +    public void setSpacingBefore(Float spacingBefore) {
  +        this.spacingBefore = spacingBefore;
  +    }
  +    
  +    public void setSplitLate(Boolean splitLate) {
  +        this.splitLate = splitLate;
  +    }
  +    
  +    public void setSplitRows(Boolean splitRows) {
  +        this.splitRows = splitRows;
  +    }
  +    
  +    public void setTable(PdfPTable table) {
  +        this.table = table;
  +    }
  +    
  +    public void setWidthPercentage(Float widthPercentage) {
  +        this.widthPercentage = widthPercentage;
  +    }
  +	
  +    
   
       public Object getITextObject() {
           return table;
  @@ -42,17 +107,78 @@
   
       public void createITextObject() {
           table = new PdfPTable(columns);
  +        
  +        if (widths != null) {
  +        	try {
  +				table.setWidths(stringToFloatArray(widths));
  +			} catch (DocumentException e) {
  +				throw new RuntimeException(e);
  +			}       	
  +        }
  +        
           if (headerRows != null) {
  -            table.setHeaderRows(headerRows.intValue());
  +            table.setHeaderRows(headerRows);
           }
           if (footerRows != null) {
  -            table.setFooterRows(footerRows.intValue());
  +            table.setFooterRows(footerRows);
  +        }
  +        if (widthPercentage!=null) {
  +            table.setWidthPercentage(widthPercentage);
  +        }
  +        if (horizontalAlignment!=null) {
  +            table.setHorizontalAlignment(horizontalAlignment);
  +        }
  +        if (skipFirstHeader!=null) {
  +            table.setSkipFirstHeader(skipFirstHeader);
  +        }
  +        if (runDirection!=null) {
  +            table.setRunDirection(runDirection);
           }
  +        if (lockedWidth!=null) {
  +            table.setLockedWidth(lockedWidth);
  +        }
  +        if (splitRows!=null) {
  +            table.setSplitRows(splitRows);
  +        }
  +        if (spacingBefore!=null) {
  +            table.setSpacingBefore(spacingBefore);
  +        }
  +        if (spacingAfter!=null) {
  +            table.setSpacingAfter(spacingAfter);
  +        }
  +        if (extendLastRow!=null) {
  +            table.setExtendLastRow(extendLastRow);
  +        }
  +        if (headersInEvent!=null) {
  +            table.setHeadersInEvent(headersInEvent);
  +        }
  +        if (splitLate!=null) {
  +            table.setSplitLate(splitLate);
  +        }
  +        if (keepTogether!=null) {
  +            table.setKeepTogether(keepTogether);
  +        }
  +    }
  +    
  +    private float[] stringToFloatArray(String widths) {
  +		String[] parts = widths.split("\\s");
  +		float[]  values = new float[parts.length];
  +		for (int i=0;i<parts.length;i++) {
  +		   values[i] = Float.valueOf(parts[i]);
  +		}
  +		
  +		return values;
       }
   
       public void add(Object o) {
           if (o instanceof PdfPCell) {
               table.addCell((PdfPCell) o);
  +        } else if (o instanceof PdfPTable) {
  +            table.addCell((PdfPTable) o);
  +        } else if (o instanceof Phrase) {
  +            table.addCell((Phrase) o);
  +        } else if (o instanceof Image) {
  +            table.addCell((Image) o);
           } else {
               throw new RuntimeException("Can't add " + o.getClass().getName() +
                                          " to table");
  
  
  


From norman.richards at jboss.com  Sun Dec 31 01:51:13 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 31 Dec 2006 01:51:13 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view    ...
Message-ID: <E1H0uXJ-0006Id-4w@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/31 01:51:13

  Modified:    examples/pdf/view    index.xhtml table.xhtml
  Added:       examples/pdf/view    nested.xhtml
  Log:
  add nested tables
  
  Revision  Changes    Path
  1.4       +1 -0      jboss-seam/examples/pdf/view/index.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: index.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/index.xhtml,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- index.xhtml	25 Dec 2006 16:28:52 -0000	1.3
  +++ index.xhtml	31 Dec 2006 06:51:13 -0000	1.4
  @@ -20,6 +20,7 @@
           <li><s:link view="/anchor.xhtml"    value="Anchors" /></li>
           <li><s:link view="/chapters.xhtml"  value="Chapters" /></li>
           <li><s:link view="/table.xhtml"     value="Tables" /></li>
  +        <li><s:link view="/nested.xhtml"    value="Nested Tables" /></li>
       </ul>
       
   </body>
  
  
  
  1.3       +6 -6      jboss-seam/examples/pdf/view/table.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: table.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/table.xhtml,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- table.xhtml	26 Dec 2006 06:12:57 -0000	1.2
  +++ table.xhtml	31 Dec 2006 06:51:13 -0000	1.3
  @@ -6,22 +6,22 @@
       <p:font size="24"><p:paragraph spacingAfter="50">Table Test</p:paragraph></p:font>  
   
   
  -    <p:table columns="4">
  -        <p:cell colspan="2">cell 1</p:cell>
  +    <p:table widths="1 2 2 1"  columns="4">
  +        <p:cell backgroundColor="yellow" colspan="2">cell 1</p:cell>
           <p:cell>cell 2</p:cell>
           <p:cell>cell 3</p:cell>
           <p:cell>cell 4</p:cell>
  -        <p:cell colspan="2">cell 5</p:cell>
  +        <p:cell backgroundColor="red" colspan="2">cell 5</p:cell>
           <p:cell>cell 6</p:cell>
           <p:cell>cell 7</p:cell>
           <p:cell>cell 8</p:cell>
  -        <p:cell colspan="2">cell 9</p:cell>
  +        <p:cell backgroundColor="blue" colspan="2">cell 9</p:cell>
       </p:table>
   
       <p:paragraph spacingBefore="10" spacingAfter="10">This is another table.  It should be large enough to span multiple pages with the headers repeated on other page</p:paragraph>
   
  -    <p:table columns="2" headerRows="1">
  -        <p:cell colspan="2"><p:font size="20"><p:paragraph alignment="center">This is a header</p:paragraph></p:font></p:cell>
  +    <p:table widths="1 4" columns="2" headerRows="1">
  +        <p:cell grayFill=".3" paddingBottom="10" colspan="2"><p:font size="20"><p:paragraph alignment="center">This is a header</p:paragraph></p:font></p:cell>
           <ui:repeat value="#{lists.daysOfWeek}" var="day">
               <p:cell>#{day}</p:cell>
               <p:cell>Blah blah blah</p:cell>
  
  
  
  1.1      date: 2006/12/31 06:51:13;  author: nrichards;  state: Exp;jboss-seam/examples/pdf/view/nested.xhtml
  
  Index: nested.xhtml
  ===================================================================
  <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
              xmlns:p="http://jboss.com/products/seam/pdf">
  
  
      <p:image alignment="right" wrap="true" resource="jboss.jpg" /> 
      <p:font size="24"><p:paragraph spacingAfter="50">Nested Tables</p:paragraph></p:font>  
  
      <p:table spacingBefore="25" columns="1">
          <p:cell borderWidthTop=".5f" grayFill=".7">
              <p:paragraph alignment="center">Horizontal split using nested tables</p:paragraph>
          </p:cell>
  
          <p:cell borderWidthTop="0">one</p:cell>
          <p:cell borderWidthTop="0" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
              <p:table widthPercentage="100" columns="2">
                  <p:cell borderWidth="0">two</p:cell>
                  <p:cell borderWidth="0" borderWidthLeft=".5">three</p:cell>
              </p:table>
          </p:cell>
  
          <p:cell borderWidthTop="0" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
              <p:table widthPercentage="100" columns="3">
                  <p:cell borderWidth="0">four</p:cell>
                  <p:cell borderWidth="0" borderWidthLeft=".5">five</p:cell>
                  <p:cell borderWidth="0" borderWidthLeft=".5">six</p:cell>
              </p:table>
          </p:cell>
          <p:cell borderWidthTop="0">seven</p:cell>
      </p:table>
  
      <p:table spacingBefore="25" columns="2" headerRows="1">
          <p:cell borderWidthTop=".5f" colspan="2" grayFill=".7">
              <p:paragraph alignment="center">Vertical split using nested tables</p:paragraph>
          </p:cell>
          
          <p:cell borderWidthTop="0">one</p:cell>
          <p:cell borderWidth="0" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
              <p:table widthPercentage="100" columns="1">
                  <p:cell borderWidthTop="0">A</p:cell>
                  <p:cell borderWidthTop="0">B</p:cell>
              </p:table>
          </p:cell>
  
          <p:cell borderWidthTop="0">two</p:cell>
          <p:cell borderWidth="0" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
              <p:table widthPercentage="100" columns="1">
                  <p:cell borderWidthTop="0">C</p:cell>
                  <p:cell borderWidthTop="0">D</p:cell>
              </p:table>
          </p:cell>
  
      </p:table>
  
  </p:document>
  
  
  


From gfjgd7734 at kobej.zzn.com  Sun Dec 31 02:31:10 2006
From: gfjgd7734 at kobej.zzn.com (gfjgd7734 at kobej.zzn.com)
Date: Sun, 31 Dec 2006 02:31:10 -0500
Subject: [jboss-cvs] =?utf-8?b?wpHDpcKKQcKTw7rCgsK+woLCqcKCw6fCllrCgsK1?=
	=?utf-8?b?woLCosKBSMKCwr/CgsOlwoLDgcKCw4bCgsOFwoLCosKCwqLCgsKpwoI=?=
	=?utf-8?b?w6fCjcKhwoLCqcKCw6fCiMKnwoLCosKCwr3CgsKiwoLDiMKBw7Q=?=
Message-ID: 20061231154035.35199mail@mail.nsuyiujksjadiutyrijkljaasjkdasdnajghj.com

???????????\?????????????????????H
???????????????????V?????s???????????H
?????????A????????????????????
?????????????A???????A?y?????C?????N?z??????????????

http://www.go-perfectfree.com.tonderuyo.com/DL/




From jboss-cvs-commits at lists.jboss.org  Sun Dec 31 04:50:12 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 31 Dec 2006 04:50:12 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1879 - in trunk: src/etc
	src/etc/server/default/deploy src/etc/xmdesc
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state
	src/main/org/jboss/jms/delegate src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/destination
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/remoting
	src/main/org/jboss/jms/tx src/main/org/jboss/messaging/core
	src/main/org/jboss/messaging/core/message
	tests/src/org/jboss/test/messaging/jms
Message-ID: <E1H0xKW-0001F4-MI@committer01.frg.pub.inap.atl.jboss.com>

Author: timfox
Date: 2006-12-31 04:49:46 -0500 (Sun, 31 Dec 2006)
New Revision: 1879

Added:
   trunk/tests/src/org/jboss/test/messaging/jms/ExpiryQueueTest.java
Removed:
   trunk/src/main/org/jboss/jms/client/container/ReceiverAspect.java
   trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
Modified:
   trunk/src/etc/aop-messaging-client.xml
   trunk/src/etc/server/default/deploy/destinations-service.xml
   trunk/src/etc/server/default/deploy/messaging-service.xml
   trunk/src/etc/xmdesc/Queue-xmbean.xml
   trunk/src/etc/xmdesc/ServerPeer-xmbean.xml
   trunk/src/etc/xmdesc/Topic-xmbean.xml
   trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java
   trunk/src/main/org/jboss/jms/server/destination/ManagedDestination.java
   trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
   trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java
   trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
   trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
   trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
   trunk/src/main/org/jboss/messaging/core/Routable.java
   trunk/src/main/org/jboss/messaging/core/message/RoutableSupport.java
   trunk/tests/src/org/jboss/test/messaging/jms/DLQTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
Log:
Expiry Queue functionality and now both expiry queue and dlq can be specified on a per queue basis



Modified: trunk/src/etc/aop-messaging-client.xml
===================================================================
--- trunk/src/etc/aop-messaging-client.xml	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/etc/aop-messaging-client.xml	2006-12-31 09:49:46 UTC (rev 1879)
@@ -10,11 +10,9 @@
    <interceptor class="org.jboss.jms.client.container.ConcurrencyInterceptor" scope="PER_INSTANCE"/>
 
    <aspect class="org.jboss.jms.client.container.StateCreationAspect" scope="PER_VM"/>
-   <aspect class="org.jboss.jms.client.container.ReceiverAspect" scope="PER_VM"/>
    <aspect class="org.jboss.jms.client.container.ConsumerAspect" scope="PER_VM"/>
    <aspect class="org.jboss.jms.client.container.ProducerAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.SessionAspect" scope="PER_VM"/>
-   <aspect class="org.jboss.jms.client.container.TransactionAspect" scope="PER_VM"/>
    <aspect class="org.jboss.jms.client.container.AsfAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.BrowserAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.ConnectionAspect" scope="PER_INSTANCE"/>
@@ -141,20 +139,14 @@
       <advice name="handleClose" aspect="org.jboss.jms.client.container.SessionAspect"/>         
    </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->commit())">
-      <advice name="handleCommit" aspect="org.jboss.jms.client.container.TransactionAspect"/>
+      <advice name="handleCommit" aspect="org.jboss.jms.client.container.SessionAspect"/>
    </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->rollback())">
-      <advice name="handleRollback" aspect="org.jboss.jms.client.container.TransactionAspect"/>
+      <advice name="handleRollback" aspect="org.jboss.jms.client.container.SessionAspect"/>
    </bind>
-   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->preDeliver(..))">
-      <advice name="handlePreDeliver" aspect="org.jboss.jms.client.container.TransactionAspect"/>
-   </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->send(..))">
-      <advice name="handleSend" aspect="org.jboss.jms.client.container.TransactionAspect"/>
+      <advice name="handleSend" aspect="org.jboss.jms.client.container.SessionAspect"/>
    </bind>
-   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->close())">
-      <advice name="handleClose" aspect="org.jboss.jms.client.container.TransactionAspect"/>
-   </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->createConsumerDelegate(..))">
       <advice name="handleCreateConsumerDelegate" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         
    </bind>   
@@ -181,16 +173,16 @@
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>          
    </bind>       
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConsumerDelegate->getMessageListener())">
-      <advice name="handleGetMessageListener" aspect="org.jboss.jms.client.container.ReceiverAspect"/>         
+      <advice name="handleGetMessageListener" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         
    </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConsumerDelegate->setMessageListener(..))">
-      <advice name="handleSetMessageListener" aspect="org.jboss.jms.client.container.ReceiverAspect"/>         
+      <advice name="handleSetMessageListener" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         
    </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConsumerDelegate->receive(..))">
-      <advice name="handleReceive" aspect="org.jboss.jms.client.container.ReceiverAspect"/>         
+      <advice name="handleReceive" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         
    </bind>  
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConsumerDelegate->receiveNoWait())">
-      <advice name="handleReceiveNoWait" aspect="org.jboss.jms.client.container.ReceiverAspect"/>         
+      <advice name="handleReceiveNoWait" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         
    </bind>    
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConsumerDelegate->closing())">
       <advice name="handleClosing" aspect="org.jboss.jms.client.container.ConsumerAspect"/>         

Modified: trunk/src/etc/server/default/deploy/destinations-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/destinations-service.xml	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/etc/server/default/deploy/destinations-service.xml	2006-12-31 09:49:46 UTC (rev 1879)
@@ -9,7 +9,7 @@
 <server>
 
    <!--
-      The Dead Letter Queue. This destination is a dependency of an EJB MDB container.
+      The Default Dead Letter Queue. This destination is a dependency of an EJB MDB container.
    -->
 
    <mbean code="org.jboss.jms.server.destination.QueueService"
@@ -18,7 +18,18 @@
       <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
       <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
+   
+   <!--
+      The Default Expiry Queue.
+   -->
 
+   <mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=ExpiryQueue"
+      xmbean-dd="xmdesc/Queue-xmbean.xml">
+      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
+   </mbean>   
+
    <!--
         Example destinations.
    -->
@@ -112,6 +123,41 @@
       <depends>jboss.messaging:service=PostOffice</depends>
    </mbean>
    
+   <!-- It's possible for indiviual queues and topics to use a specific queue for
+   an expiry or DLQ -->
+   
+   <mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=PrivateDLQ"
+      xmbean-dd="xmdesc/Queue-xmbean.xml">
+      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
+   </mbean>
+   
+   <mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue"
+      xmbean-dd="xmdesc/Queue-xmbean.xml">
+      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
+   </mbean>      
+   
+   <mbean code="org.jboss.jms.server.destination.QueueService"
+      name="jboss.messaging.destination:service=Queue,name=QueueWithOwnDLQAndExpiryQueue"
+      xmbean-dd="xmdesc/Queue-xmbean.xml">
+      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
+      <attribute name="DLQ">jboss.messaging.destination:service=Queue,name=PrivateDLQ</attribute>
+      <attribute name="ExpiryQueue">jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue</attribute>
+   </mbean> 
+   
+   <mbean code="org.jboss.jms.server.destination.TopicService"
+      name="jboss.messaging.destination:service=Topic,name=TopicWithOwnDLQAndExpiryQueue"
+      xmbean-dd="xmdesc/Topic-xmbean.xml">
+      <depends optional-attribute-name="ServerPeer">jboss.messaging:service=ServerPeer</depends>
+      <depends>jboss.messaging:service=PostOffice</depends>
+      <attribute name="DLQ">jboss.messaging.destination:service=Queue,name=PrivateDLQ</attribute>
+      <attribute name="ExpiryQueue">jboss.messaging.destination:service=Queue,name=PrivateExpiryQueue</attribute>
+   </mbean>       
+   
    <!--
         Example clustered destinations.
    -->

Modified: trunk/src/etc/server/default/deploy/messaging-service.xml
===================================================================
--- trunk/src/etc/server/default/deploy/messaging-service.xml	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/etc/server/default/deploy/messaging-service.xml	2006-12-31 09:49:46 UTC (rev 1879)
@@ -22,20 +22,29 @@
       </constructor>
 
       <depends optional-attribute-name="PersistenceManager">jboss.messaging:service=PersistenceManager</depends>    
+      
       <depends optional-attribute-name="JMSUserManager">jboss.messaging:service=JMSUserManager</depends>
+      
       <depends>jboss.messaging:service=Connector,transport=socket</depends>
 
 	   <attribute name="PostOffice">jboss.messaging:service=PostOffice</attribute>
 
       <attribute name="SecurityDomain">java:/jaas/messaging</attribute>
+      
       <attribute name="DefaultSecurityConfig">
         <security>
             <role name="guest" read="true" write="true" create="true"/>
         </security>
       </attribute>
-      <attribute name="MaxDeliveryAttempts">10</attribute>
-      <attribute name="DLQName">DLQ</attribute>
+      
+      <attribute name="DefaultDLQ">jboss.messaging.destination:service=Queue,name=DLQ</attribute>
+      
+      <attribute name="DefaultMaxDeliveryAttempts">10</attribute>           
+      
+      <attribute name="DefaultExpiryQueue">jboss.messaging.destination:service=Queue,name=ExpiryQueue</attribute> 
+
       <attribute name="FailoverStartTimeout">3000</attribute>
+      
       <attribute name="FailoverCompleteTimeout">12000</attribute>
    </mbean>
 

Modified: trunk/src/etc/xmdesc/Queue-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/Queue-xmbean.xml	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/etc/xmdesc/Queue-xmbean.xml	2006-12-31 09:49:46 UTC (rev 1879)
@@ -59,6 +59,18 @@
       <name>ServerPeer</name>
       <type>javax.management.ObjectName</type>
    </attribute>
+   
+   <attribute access="read-write" getMethod="getDLQ" setMethod="setDLQ">
+      <description>The DLQ for this queue, overrides the default DLQ on the server peer</description>
+      <name>DLQ</name>
+      <type>javax.management.ObjectName</type>
+   </attribute>
+   
+   <attribute access="read-write" getMethod="getExpiryQueue" setMethod="setExpiryQueue">
+      <description>The expiry queue for this queue, overrides the default expiry queue on the server peer</description>
+      <name>ExpiryQueue</name>
+      <type>javax.management.ObjectName</type>
+   </attribute>
 
    <attribute access="read-write" getMethod="getSecurityConfig" setMethod="setSecurityConfig">
       <description>The destination's security configuration</description>
@@ -102,6 +114,14 @@
       <type>boolean</type>
    </attribute>   
    
+   <!-- instance access -->
+
+   <attribute access="read-only" getMethod="getInstance">
+      <description>The instance to be accessed by select plugins via a typed hard reference</description>
+      <name>Instance</name>
+      <type>org.jboss.messaging.core.plugin.contract.MessagingComponent</type>
+   </attribute>
+   
    <!-- Managed operations -->
 
    <operation>

Modified: trunk/src/etc/xmdesc/ServerPeer-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/etc/xmdesc/ServerPeer-xmbean.xml	2006-12-31 09:49:46 UTC (rev 1879)
@@ -46,6 +46,18 @@
       <type>javax.management.ObjectName</type>
    </attribute>   
    
+   <attribute access="read-write" getMethod="getDefaultDLQ" setMethod="setDefaultDLQ">
+      <description>The ObjectName of the default DLQ - used when an individual queue does not specify a DLQ</description>
+      <name>DefaultDLQ</name>
+      <type>javax.management.ObjectName</type>
+   </attribute>  
+   
+   <attribute access="read-write" getMethod="getDefaultExpiryQueue" setMethod="setDefaultExpiryQueue">
+      <description>The ObjectName of the default expiry queue - used when an individual queue does not specify an expiry queue</description>
+      <name>DefaultExpiryQueue</name>
+      <type>javax.management.ObjectName</type>
+   </attribute>    
+   
    <!-- instance access -->
 
    <attribute access="read-only" getMethod="getInstance">
@@ -139,19 +151,13 @@
       <name>QueuedExecutorPoolSize</name>
       <type>int</type>
    </attribute>
-   
-   <attribute access="read-write" getMethod="getMaxDeliveryAttempts" setMethod="setMaxDeliveryAttempts">
-      <description>The maximum delivery attempts for destinations</description>
-      <name>MaxDeliveryAttempts</name>
+         
+   <attribute access="read-write" getMethod="getDefaultMaxDeliveryAttempts" setMethod="setDefaultMaxDeliveryAttempts">
+      <description>The default maximum delivery attempts for destinations, unless overridden on the destination</description>
+      <name>DefaultMaxDeliveryAttempts</name>
       <type>int</type>
    </attribute>  
    
-   <attribute access="read-write" getMethod="getDLQName" setMethod="setDLQName">
-      <description>The JNDI name of the DLQ</description>
-      <name>DLQName</name>
-      <type>java.lang.String</type>
-   </attribute>  
-   
    <attribute access="read-write" getMethod="getFailoverStartTimeout" setMethod="setFailoverStartTimeout">
       <description>The maximum amount of time to wait for failover to begin</description>
       <name>FailoverStartTimeout</name>

Modified: trunk/src/etc/xmdesc/Topic-xmbean.xml
===================================================================
--- trunk/src/etc/xmdesc/Topic-xmbean.xml	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/etc/xmdesc/Topic-xmbean.xml	2006-12-31 09:49:46 UTC (rev 1879)
@@ -57,6 +57,18 @@
       <name>ServerPeer</name>
       <type>javax.management.ObjectName</type>
    </attribute>
+   
+   <attribute access="read-write" getMethod="getDLQ" setMethod="setDLQ">
+      <description>The DLQ for this queue, overrides the default DLQ on the server peer</description>
+      <name>DLQ</name>
+      <type>javax.management.ObjectName</type>
+   </attribute>
+   
+   <attribute access="read-write" getMethod="getExpiryQueue" setMethod="setExpiryQueue">
+      <description>The expiry queue for this queue, overrides the default expiry queue on the server peer</description>
+      <name>ExpiryQueue</name>
+      <type>javax.management.ObjectName</type>
+   </attribute>   
 
    <attribute access="read-write" getMethod="getSecurityConfig" setMethod="setSecurityConfig">
       <description>The destination's security configuration</description>
@@ -93,7 +105,15 @@
       <name>Clustered</name>
       <type>boolean</type>
    </attribute>
+   
+   <!-- instance access -->
 
+   <attribute access="read-only" getMethod="getInstance">
+      <description>The instance to be accessed by select plugins via a typed hard reference</description>
+      <name>Instance</name>
+      <type>org.jboss.messaging.core.plugin.contract.MessagingComponent</type>
+   </attribute>
+
    <!-- Managed operations -->
 
    <operation>

Modified: trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -21,6 +21,8 @@
   */
 package org.jboss.jms.client.container;
 
+import javax.jms.MessageListener;
+
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.delegate.DelegateSupport;
@@ -31,6 +33,8 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
+import org.jboss.jms.server.endpoint.ServerSessionEndpoint;
+import org.jboss.logging.Logger;
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
@@ -50,6 +54,8 @@
 {
    // Constants -----------------------------------------------------
    
+   private static final Logger log = Logger.getLogger(ConsumerAspect.class);
+   
    // Static --------------------------------------------------------
 
    // Attributes ----------------------------------------------------
@@ -133,12 +139,42 @@
       //in the right order
       del.cancelInflightMessages(lastDeliveryId);
       
-      //And then we cancel any messages still in the message callback handler buffer
+      //And then we cancel any messages still in the message callback handler buffer     
       consumerState.getMessageCallbackHandler().cancelBuffer();
                                    
       return res;
    }      
    
+   public Object handleReceive(Invocation invocation) throws Throwable
+   {
+      MethodInvocation mi = (MethodInvocation)invocation;
+      Object[] args = mi.getArguments();
+      long timeout = args == null ? 0 : ((Long)args[0]).longValue();
+      
+      return getMessageCallbackHandler(invocation).receive(timeout);
+   }
+   
+   public Object handleReceiveNoWait(Invocation invocation) throws Throwable
+   {      
+      return getMessageCallbackHandler(invocation).receive(-1);
+   }
+   
+   public Object handleSetMessageListener(Invocation invocation) throws Throwable
+   {   
+      MethodInvocation mi = (MethodInvocation)invocation;
+      Object[] args = mi.getArguments();
+      MessageListener l = (MessageListener)args[0];
+      
+      getMessageCallbackHandler(invocation).setMessageListener(l);
+      
+      return null;
+   }
+   
+   public MessageListener handleGetMessageListener(Invocation invocation) throws Throwable
+   {       
+      return getMessageCallbackHandler(invocation).getMessageListener();
+   }
+   
    public Object handleGetDestination(Invocation invocation) throws Throwable
    {
       return getState(invocation).getDestination();
@@ -165,5 +201,11 @@
       return (ConsumerState)((DelegateSupport)inv.getTargetObject()).getState();
    }
    
+   private MessageCallbackHandler getMessageCallbackHandler(Invocation inv)
+   {      
+      ConsumerState state = (ConsumerState)((DelegateSupport)inv.getTargetObject()).getState();
+      return state.getMessageCallbackHandler();      
+   }
+   
    // Inner classes -------------------------------------------------
 }

Deleted: trunk/src/main/org/jboss/jms/client/container/ReceiverAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ReceiverAspect.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/container/ReceiverAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -1,101 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.client.container;
-
-import javax.jms.MessageListener;
-
-import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.remoting.MessageCallbackHandler;
-import org.jboss.jms.client.state.ConsumerState;
-
-/**
- * 
- * This aspect handles receive functionality for a message consumer
- * 
- * This aspect is PER_VM.
- * 
- * 
- * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision$</tt>
- *
- * $Id$
- */
-public class ReceiverAspect
-{
-   // Constants -----------------------------------------------------
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   // Public --------------------------------------------------------
-   
-   public Object handleReceive(Invocation invocation) throws Throwable
-   {
-      MethodInvocation mi = (MethodInvocation)invocation;
-      Object[] args = mi.getArguments();
-      long timeout = args == null ? 0 : ((Long)args[0]).longValue();
-      
-      return getMessageCallbackHandler(invocation).receive(timeout);
-   }
-   
-   public Object handleReceiveNoWait(Invocation invocation) throws Throwable
-   {      
-      return getMessageCallbackHandler(invocation).receive(-1);
-   }
-   
-   public Object handleSetMessageListener(Invocation invocation) throws Throwable
-   {   
-      MethodInvocation mi = (MethodInvocation)invocation;
-      Object[] args = mi.getArguments();
-      MessageListener l = (MessageListener)args[0];
-      
-      getMessageCallbackHandler(invocation).setMessageListener(l);
-      
-      return null;
-   }
-   
-   public MessageListener handleGetMessageListener(Invocation invocation) throws Throwable
-   {       
-      return getMessageCallbackHandler(invocation).getMessageListener();
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-   
-   private MessageCallbackHandler getMessageCallbackHandler(Invocation inv)
-   {      
-      ConsumerState state = (ConsumerState)((DelegateSupport)inv.getTargetObject()).getState();
-      return state.getMessageCallbackHandler();      
-   }
-
-   // Inner classes -------------------------------------------------
-
-}

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -26,18 +26,24 @@
 import java.util.List;
 
 import javax.jms.IllegalStateException;
+import javax.jms.Message;
 import javax.jms.Session;
+import javax.jms.TransactionInProgressException;
 
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.client.state.SessionState;
+import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
+import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.jms.tx.LocalTx;
 import org.jboss.jms.tx.ResourceManager;
 import org.jboss.logging.Logger;
 
@@ -109,7 +115,7 @@
           ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
           (state.isXA() && state.getCurrentTxId() == null))
       {
-         //Acknowledge any outstanding auto ack
+         //Acknowledge or cancel any outstanding auto ack
          
          DeliveryInfo remainingAutoAck = state.getAutoAckInfo();
          
@@ -117,8 +123,8 @@
          {
             if (trace) { log.trace(this + " handleClosing(). Found remaining auto ack. Will ack it " + remainingAutoAck.getDeliveryId()); }
             
-            ackDelivery(del, remainingAutoAck);
-            
+            ackDelivery(del, remainingAutoAck);            
+                        
             if (trace) { log.trace(this + " acked it"); }
             
             state.setAutoAckInfo(null);
@@ -139,34 +145,46 @@
          {
             DeliveryInfo ack = (DeliveryInfo)i.next();            
             
-            DefaultCancel cancel = new DefaultCancel(ack.getMessageProxy().getDeliveryId(), ack.getMessageProxy().getDeliveryCount());
+            DefaultCancel cancel = new DefaultCancel(ack.getMessageProxy().getDeliveryId(),
+                                                     ack.getMessageProxy().getDeliveryCount(),
+                                                     false, false);
+            
             cancels.add(cancel);
-         }
+         }         
          
          if (!cancels.isEmpty())
-         {            
-            del.cancelDeliveries(cancels);            
+         {
+            del.cancelDeliveries(cancels);
          }
          
          state.getClientAckList().clear();
       }
-      
-      
+            
       //TODO - we should also cancel any deliveries remaining in any transaction for the session
       //so the delivery count gets updated to the server, and not rely on the server side close
       //cancelling them
       
       return invocation.invokeNext();
    }
-
-
+   
    public Object handleClose(Invocation invocation) throws Throwable
    {      
       Object res = invocation.invokeNext();
+      
+      SessionState state = getState(invocation);
 
+      ConnectionState connState = (ConnectionState)state.getParent();
+
+      Object xid = state.getCurrentTxId();
+
+      if (xid != null)
+      {
+         //Remove transaction from the resource manager
+         connState.getResourceManager().removeTx(xid);
+      }
+
       // We must explicitly shutdown the executor
 
-      SessionState state = getState(invocation);
       state.getExecutor().shutdownNow();
 
       return res;
@@ -194,10 +212,7 @@
             throw new IllegalStateException("CLIENT_ACKNOWLEDGE cannot be used with a connection consumer");
          }
                   
-         state.getClientAckList().add(info);
-         
-         //We can return immediately
-         return null;
+         state.getClientAckList().add(info);         
       }
       else if (ackMode == Session.AUTO_ACKNOWLEDGE ||
                ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
@@ -206,36 +221,39 @@
          //We collect the single acknowledgement in the state.
          //Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE
          //Also XA sessions not enlisted in a global tx are treated as AUTO_ACKNOWLEDGE
-                  
-         
+                           
          if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack member"); }
          
          state.setAutoAckInfo(info);         
-         
-         //We can return immediately         
-         return null;
       }
-              
-      //Transactional - need to carry on down the stack
-      return invocation.invokeNext();
-   }
+      else
+      {             
+         Object txID = state.getCurrentTxId();
    
-   /* Used for client acknowledge */
-   public Object handleAcknowledgeAll(Invocation invocation) throws Throwable
-   {    
-      MethodInvocation mi = (MethodInvocation)invocation;
-      SessionState state = getState(invocation);
-      SessionDelegate del = (SessionDelegate)mi.getTargetObject();
-    
-      if (!state.getClientAckList().isEmpty())
-      {                 
-         //CLIENT_ACKNOWLEDGE can't be used with a MDB so it is safe to always acknowledge all
-         //on this session (rather than the connection consumer session)
-         del.acknowledgeDeliveries(state.getClientAckList());
+         if (txID != null)
+         {
+            // the session is non-XA and transacted, or XA and enrolled in a global transaction. An
+            // XA session that has not been enrolled in a global transaction behaves as a
+            // non-transacted session.
+            
+            ConnectionState connState = (ConnectionState)state.getParent();
+   
+            if (trace) { log.trace("sending acknowlegment transactionally, queueing on resource manager"); }
+   
+            //If the ack is for a delivery that came through via a connection consumer then we
+            //use the connectionConsumer session as the session id, otherwise we use this sessions'
+            //session id
+            
+            ClientSessionDelegate connectionConsumerDelegate =
+               (ClientSessionDelegate)info.getConnectionConsumerSession();
+            
+            int sessionId = connectionConsumerDelegate != null ?
+               connectionConsumerDelegate.getID() : state.getSessionId();
+            
+            connState.getResourceManager().addAck(txID, sessionId, info);
+         }        
+      }
       
-         state.getClientAckList().clear();
-      }
-        
       return null;
    }
    
@@ -246,13 +264,6 @@
       
       int ackMode = state.getAcknowledgeMode();
       
-      boolean cancel = ((Boolean)mi.getArguments()[0]).booleanValue();
-      
-      if (cancel && ackMode != Session.AUTO_ACKNOWLEDGE && ackMode != Session.DUPS_OK_ACKNOWLEDGE)
-      {
-         throw new IllegalStateException("Ack mode must be AUTO_ACKNOWLEDGE or DUPS_OK_ACKNOWLEDGE");
-      }
-      
       if (ackMode == Session.AUTO_ACKNOWLEDGE ||
           ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
           (state.isXA() && state.getCurrentTxId() == null))
@@ -263,6 +274,10 @@
          
          SessionDelegate sd = (SessionDelegate)mi.getTargetObject();
 
+         //It is possible that session.recover() is called inside a message listener onMessage
+         //method - i.e. between the invocations of preDeliver and postDeliver.
+         //In this case we don't want to acknowledge the last delivered messages - since it
+         //will be redelivered
          if (!state.isRecoverCalled())
          {
             DeliveryInfo deliveryInfo = state.getAutoAckInfo();
@@ -274,14 +289,7 @@
                                  
             if (trace) { log.trace(this + " auto acking delivery " + deliveryInfo.getDeliveryId()); }
                         
-            if (cancel)
-            {
-               cancelDelivery(sd, deliveryInfo);
-            }
-            else
-            {
-               ackDelivery(sd, deliveryInfo);
-            }
+            ackDelivery(sd, deliveryInfo);            
             
             state.setAutoAckInfo(null);
          }
@@ -295,7 +303,26 @@
 
       return null;
    }
-                  
+   
+   /* Used for client acknowledge */
+   public Object handleAcknowledgeAll(Invocation invocation) throws Throwable
+   {    
+      MethodInvocation mi = (MethodInvocation)invocation;
+      SessionState state = getState(invocation);
+      SessionDelegate del = (SessionDelegate)mi.getTargetObject();            
+    
+      if (!state.getClientAckList().isEmpty())
+      {                 
+         //CLIENT_ACKNOWLEDGE can't be used with a MDB so it is safe to always acknowledge all
+         //on this session (rather than the connection consumer session)
+         del.acknowledgeDeliveries(state.getClientAckList());
+      
+         state.getClientAckList().clear();
+      }      
+        
+      return null;
+   }
+                       
    /*
     * Called when session.recover is called
     */
@@ -325,8 +352,12 @@
       }
       else
       {
+         //auto_ack or dups_ok
+         
          DeliveryInfo info = state.getAutoAckInfo();
          
+         //Don't recover if it's already to cancel
+         
          if (info != null)
          {
             List redels = new ArrayList();
@@ -377,18 +408,17 @@
    public Object handleRedeliver(Invocation invocation) throws Throwable
    {            
       MethodInvocation mi = (MethodInvocation)invocation;
-      SessionState state = getState(invocation);
+      SessionState state = getState(invocation);            
             
-      // We put the messages back in the front of their appropriate consumer buffers and set
-      // JMSRedelivered to true.
+      // We put the messages back in the front of their appropriate consumer buffers
       
       List toRedeliver = (List)mi.getArguments()[0];
-      
+       
       if (trace) { log.trace(this + " handleRedeliver() called: " + toRedeliver); }
       
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
       
-      // Need to be recovered in reverse order.
+      // Need to be redelivered in reverse order.
       for (int i = toRedeliver.size() - 1; i >= 0; i--)
       {
          DeliveryInfo info = (DeliveryInfo)toRedeliver.get(i);
@@ -400,11 +430,14 @@
          {
             // This is ok. The original consumer has closed, so we cancel the message
             
+            //FIXME - this needs to be done atomically for all cancels
+            
             cancelDelivery(del, info);
          }
          else
          {
             if (trace) { log.trace("Adding proxy back to front of buffer"); }
+            
             handler.addToFrontOfBuffer(proxy);
          }                                    
       }
@@ -412,6 +445,100 @@
       return null;  
    }
    
+   public Object handleCommit(Invocation invocation) throws Throwable
+   {
+      SessionState state = getState(invocation);
+
+      if (!state.isTransacted())
+      {
+         throw new IllegalStateException("Cannot commit a non-transacted session");
+      }
+
+      if (state.isXA())
+      {
+         throw new TransactionInProgressException("Cannot call commit on an XA session");
+      }
+
+      ConnectionState connState = (ConnectionState)state.getParent();
+      ConnectionDelegate conn = (ConnectionDelegate)connState.getDelegate();
+
+      try
+      {
+         connState.getResourceManager().commitLocal((LocalTx)state.getCurrentTxId(), conn);
+      }
+      finally
+      {
+         //Start new local tx
+         Object xid = connState.getResourceManager().createLocalTx();
+
+         state.setCurrentTxId(xid);
+      }
+      
+      //TODO on commit we don't want to ACK any messages that have exceeded the max delivery count OR
+
+      return null;
+   }
+
+   public Object handleRollback(Invocation invocation) throws Throwable
+   {
+      SessionState state = getState(invocation);
+
+      if (!state.isTransacted())
+      {
+         throw new IllegalStateException("Cannot rollback a non-transacted session");
+      }
+
+      if (state.isXA())
+      {
+         throw new TransactionInProgressException("Cannot call rollback on an XA session");
+      }
+      
+      ConnectionState connState = (ConnectionState)state.getParent();
+      ResourceManager rm = connState.getResourceManager();
+      ConnectionDelegate conn = (ConnectionDelegate)connState.getDelegate();
+
+      try
+      {
+         rm.rollbackLocal((LocalTx)state.getCurrentTxId(), conn);
+      }
+      finally
+      {
+         // start new local tx
+         Object xid = rm.createLocalTx();
+         state.setCurrentTxId(xid);
+      }
+
+      return null;
+   }
+   
+   public Object handleSend(Invocation invocation) throws Throwable
+   {
+      SessionState state = getState(invocation);
+      Object txID = state.getCurrentTxId();
+
+      if (txID != null)
+      {
+         // the session is non-XA and transacted, or XA and enrolled in a global transaction, so
+         // we add the message to a transaction instead of sending it now. An XA session that has
+         // not been enrolled in a global transaction behaves as a non-transacted session.
+
+         ConnectionState connState = (ConnectionState)state.getParent();
+         MethodInvocation mi = (MethodInvocation)invocation;
+         Message m = (Message)mi.getArguments()[0];
+
+         if (trace) { log.trace("sending message " + m + " transactionally, queueing on resource manager txID=" + txID + " sessionID= " + state.getSessionId()); }
+
+         connState.getResourceManager().addMessage(txID, state.getSessionId(), (JBossMessage)m);
+
+         // ... and we don't invoke any further interceptors in the stack
+         return null;
+      }
+
+      if (trace) { log.trace("sending message NON-transactionally"); }
+
+      return invocation.invokeNext();
+   }
+   
    public Object handleGetXAResource(Invocation invocation) throws Throwable
    {
       return getState(invocation).getXAResource();
@@ -462,7 +589,8 @@
       
       SessionDelegate sessionToUse = connectionConsumerSession != null ? connectionConsumerSession : sess;
       
-      sessionToUse.cancelDelivery(new DefaultCancel(delivery.getDeliveryId(), delivery.getMessageProxy().getDeliveryCount()));      
+      sessionToUse.cancelDelivery(new DefaultCancel(delivery.getDeliveryId(),
+                                  delivery.getMessageProxy().getDeliveryCount(), false, false));      
    }
 
    // Inner Classes -------------------------------------------------

Deleted: trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/container/TransactionAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -1,229 +0,0 @@
-/*
-  * JBoss, Home of Professional Open Source
-  * Copyright 2005, JBoss Inc., and individual contributors as indicated
-  * by the @authors tag. See the copyright.txt 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.jms.client.container;
-
-import javax.jms.IllegalStateException;
-import javax.jms.Message;
-import javax.jms.TransactionInProgressException;
-
-import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.client.state.HierarchicalState;
-import org.jboss.jms.client.state.SessionState;
-import org.jboss.jms.delegate.ConnectionDelegate;
-import org.jboss.jms.message.JBossMessage;
-import org.jboss.jms.server.endpoint.DeliveryInfo;
-import org.jboss.jms.tx.LocalTx;
-import org.jboss.jms.tx.ResourceManager;
-import org.jboss.logging.Logger;
-
-/**
- * This aspect handles transaction related logic
- * 
- * This aspect is PER_VM.
- * 
- * @author <a href="mailto:tim.fox at jboss.com>Tim Fox</a>
- * @author <a href="mailto:ovidiu at jboss.com>Ovidiu Feodorov</a>
- *
- * $Id$
- */
-public class TransactionAspect
-{
-   // Constants -----------------------------------------------------
-
-   private static final Logger log = Logger.getLogger(TransactionAspect.class);
-
-   // Attributes ----------------------------------------------------
-
-   private boolean trace = log.isTraceEnabled();
-
-   // Static --------------------------------------------------------
-
-   // Constructors --------------------------------------------------
-
-   // Public --------------------------------------------------------
-
-   public Object handleClose(Invocation invocation) throws Throwable
-   {
-      Object res = invocation.invokeNext();
-
-      SessionState state = (SessionState)getState(invocation);
-
-      ConnectionState connState = (ConnectionState)state.getParent();
-
-      Object xid = state.getCurrentTxId();
-
-      if (xid != null)
-      {
-         //Remove transaction from the resource manager
-         connState.getResourceManager().removeTx(xid);
-      }
-
-      return res;
-   }
-
-   public Object handleCommit(Invocation invocation) throws Throwable
-   {
-      SessionState state = (SessionState)getState(invocation);
-
-      if (!state.isTransacted())
-      {
-         throw new IllegalStateException("Cannot commit a non-transacted session");
-      }
-
-      if (state.isXA())
-      {
-         throw new TransactionInProgressException("Cannot call commit on an XA session");
-      }
-
-      ConnectionState connState = (ConnectionState)state.getParent();
-      ConnectionDelegate conn = (ConnectionDelegate)connState.getDelegate();
-
-      try
-      {
-         connState.getResourceManager().commitLocal((LocalTx)state.getCurrentTxId(), conn);
-      }
-      finally
-      {
-         //Start new local tx
-         Object xid = connState.getResourceManager().createLocalTx();
-
-         state.setCurrentTxId(xid);
-      }
-
-      return null;
-   }
-
-   public Object handleRollback(Invocation invocation) throws Throwable
-   {
-      SessionState state = (SessionState)getState(invocation);
-
-      if (!state.isTransacted())
-      {
-         throw new IllegalStateException("Cannot rollback a non-transacted session");
-      }
-
-      if (state.isXA())
-      {
-         throw new TransactionInProgressException("Cannot call rollback on an XA session");
-      }
-
-      ConnectionState connState = (ConnectionState)state.getParent();
-      ResourceManager rm = connState.getResourceManager();
-      ConnectionDelegate conn = (ConnectionDelegate)connState.getDelegate();
-
-      try
-      {
-         rm.rollbackLocal((LocalTx)state.getCurrentTxId(), conn);
-      }
-      finally
-      {
-         // start new local tx
-         Object xid = rm.createLocalTx();
-         state.setCurrentTxId(xid);
-      }
-
-      return null;
-   }
-
-   public Object handleSend(Invocation invocation) throws Throwable
-   {
-      SessionState state = (SessionState)getState(invocation);
-      Object txID = state.getCurrentTxId();
-
-      if (txID != null)
-      {
-         // the session is non-XA and transacted, or XA and enrolled in a global transaction, so
-         // we add the message to a transaction instead of sending it now. An XA session that has
-         // not been enrolled in a global transaction behaves as a non-transacted session.
-
-         ConnectionState connState = (ConnectionState)state.getParent();
-         MethodInvocation mi = (MethodInvocation)invocation;
-         Message m = (Message)mi.getArguments()[0];
-
-         if (trace) { log.trace("sending message " + m + " transactionally, queueing on resource manager txID=" + txID + " sessionID= " + state.getSessionId()); }
-
-         connState.getResourceManager().addMessage(txID, state.getSessionId(), (JBossMessage)m);
-
-         // ... and we don't invoke any further interceptors in the stack
-         return null;
-      }
-
-      if (trace) { log.trace("sending message NON-transactionally"); }
-
-      return invocation.invokeNext();
-   }
-
-   public Object handlePreDeliver(Invocation invocation) throws Throwable
-   {
-      SessionState state = (SessionState)getState(invocation);
-      Object txID = state.getCurrentTxId();
-
-      if (txID != null)
-      {
-         // the session is non-XA and transacted, or XA and enrolled in a global transaction. An
-         // XA session that has not been enrolled in a global transaction behaves as a
-         // non-transacted session.
-         
-         MethodInvocation mi = (MethodInvocation)invocation;
-         
-         DeliveryInfo info = (DeliveryInfo)mi.getArguments()[0];
-
-         ConnectionState connState = (ConnectionState)state.getParent();
-
-         if (trace) { log.trace("sending acknowlegment transactionally, queueing on resource manager"); }
-
-         //If the ack is for a delivery that came through via a connection consumer then we
-         //use the connectionConsumer session as the session id, otherwise we use this sessions'
-         //session id
-         
-         ClientSessionDelegate connectionConsumerDelegate =
-            (ClientSessionDelegate)info.getConnectionConsumerSession();
-         
-         int sessionId = connectionConsumerDelegate != null ?
-            connectionConsumerDelegate.getID() : state.getSessionId();
-         
-         connState.getResourceManager().addAck(txID, sessionId, info);
-      }
-
-      return null;
-   }
-
-   // Protected ------------------------------------------------------
-
-   // Package Private ------------------------------------------------
-
-   // Private --------------------------------------------------------
-
-   private HierarchicalState getState(Invocation inv)
-   {
-      return ((DelegateSupport)inv.getTargetObject()).getState();
-   }
-
-   // Inner Classes --------------------------------------------------
-
-}
-
-

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -306,7 +306,7 @@
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
     */
-   public void postDeliver(boolean cancel) throws JMSException
+   public void postDeliver() throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }

Modified: trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/remoting/MessageCallbackHandler.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -34,11 +34,14 @@
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.message.MessageProxy;
+import org.jboss.jms.server.endpoint.Cancel;
 import org.jboss.jms.server.endpoint.DefaultCancel;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.logging.Logger;
+import org.jboss.messaging.core.Message;
 import org.jboss.messaging.util.Future;
 
+import EDU.oswego.cs.dl.util.concurrent.Executor;
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
 /**
@@ -63,6 +66,67 @@
       log = Logger.getLogger(MessageCallbackHandler.class);
       trace = log.isTraceEnabled();
    }
+   
+   //FIXME temporary - until remoting provides true asynch invocations
+   static Executor exec = new QueuedExecutor();
+   
+   private static boolean checkExpiredOrReachedMaxdeliveries(MessageProxy proxy, SessionDelegate del,
+                                                             int maxDeliveries) throws JMSException
+   {
+      Message msg = proxy.getMessage();
+      
+      boolean expired = msg.isExpired();
+      
+      boolean reachedMaxDeliveries = proxy.getDeliveryCount() == maxDeliveries;
+      
+      if (expired || reachedMaxDeliveries)
+      {
+         if (trace)
+         {
+            if (expired)
+            {
+               log.trace("Message " + proxy.getMessage() + " has expired - cancelling to server");
+            }
+            else
+            {
+               log.trace("Message " + proxy.getMessage() + " has reached max deliveries - cancelling to server");
+            }
+         }
+         final Cancel cancel = new DefaultCancel(proxy.getDeliveryId(), proxy.getDeliveryCount(),
+                                           expired, reachedMaxDeliveries);
+         
+         //FIXME - this cancel should be sent using remoting true asynch invocations
+         //for now we just send on a different thread to prevent deadlocks
+         
+         final SessionDelegate sess = del;
+         
+         try
+         {
+            
+            exec.execute(new Runnable() { public void run()
+            {
+               try
+               {
+                  sess.cancelDelivery(cancel);
+               }
+               catch (JMSException e)
+               {
+                  log.error("Failed to cancel delivery", e);
+               }
+            }});
+         }
+         catch (InterruptedException e)
+         {
+            log.error("Thread interrupted", e);
+         }
+                  
+         return true;
+      }
+      else
+      {
+         return false;
+      }
+   }
      
    //This is static so it can be called by the asf layer too
    public static void callOnMessage(SessionDelegate sess,
@@ -75,79 +139,58 @@
                                     int maxDeliveries,
                                     SessionDelegate connectionConsumerSession)
       throws JMSException
-   {
+   {      
+      if (checkExpiredOrReachedMaxdeliveries(m, sess, maxDeliveries))
+      {
+         //Message has been cancelled
+         return;
+      }
+      
+      DeliveryInfo deliveryInfo = new DeliveryInfo(m, consumerID, channelID, connectionConsumerSession);
+            
+      m.incDeliveryCount();
+      
       // If this is the callback-handler for a connection consumer we don't want to acknowledge or
       // add anything to the tx for this session.
       if (!isConnectionConsumer)
       {
-         sess.preDeliver(new DeliveryInfo(m, consumerID, channelID, connectionConsumerSession));
-      }  
-                  
-      int tries = 0;
+         //We need to call preDeliver, deliver the message then call postDeliver - this is because
+         //it is legal to call session.recover(), or session.rollback() from within the onMessage()
+         //method in which case the last message needs to be delivered so it needs to know about it
+         sess.preDeliver(deliveryInfo);
+      } 
       
-      boolean cancel = false;
-      
-      while (true)
+      try
       {
-         try
-         {
-            if (trace) { log.trace("calling listener's onMessage(" + m + ")"); }
-            
-            m.incDeliveryCount();
-            
-            listener.onMessage(m);
+         if (trace) { log.trace("calling listener's onMessage(" + m + ")"); }
+                     
+         listener.onMessage(m);
 
-            if (trace) { log.trace("listener's onMessage() finished"); }
-            
-            break;
-         }
-         catch (RuntimeException e)
-         {
-            long id = m.getMessage().getMessageID();
-   
-            log.error("RuntimeException was thrown from onMessage, " + id + " will be redelivered", e);
-            
-            // See JMS 1.1 spec 4.5.2
-   
-            if (ackMode == Session.AUTO_ACKNOWLEDGE || ackMode == Session.DUPS_OK_ACKNOWLEDGE)
-            {
-               // We redeliver a certain number of times
-               if (tries < maxDeliveries)
-               {                            
-                  tries++;
-               }
-               else
-               {
-                  log.error("Max redeliveries has occurred for message: " + m.getJMSMessageID());
-                  
-                  // postdeliver will do a cancel rather than an ack which will cause the mesage
-                  // to end up in the DLQ
-                  
-                  cancel = true;
-                  
-                  break;
-               }
-            }
-            else
-            {
-               // Session is either transacted or CLIENT_ACKNOWLEDGE
-               // We just deliver next message
-               if (trace) { log.trace("ignoring exception on " + id); }
-               
-               break;
-            }
-         }
+         if (trace) { log.trace("listener's onMessage() finished"); }
       }
+      catch (RuntimeException e)
+      {
+         long id = m.getMessage().getMessageID();
 
+         log.error("RuntimeException was thrown from onMessage, " + id + " will be redelivered", e);
+         
+         // See JMS 1.1 spec 4.5.2
+
+         if (ackMode == Session.AUTO_ACKNOWLEDGE || ackMode == Session.DUPS_OK_ACKNOWLEDGE)
+         {              
+            sess.recover();
+         }
+      }   
+
       if (!sess.isClosed())
       {
          // postDeliver only if the session is not closed
-
+               
          // If this is the callback-handler for a connection consumer we don't want to acknowledge or
          // add anything to the tx for this session
          if (!isConnectionConsumer)
          {
-            sess.postDeliver(cancel);
+            sess.postDeliver();
          }   
       }
    }
@@ -278,7 +321,7 @@
          // delivered in a session.
          
          if (!buffer.isEmpty())
-         {            
+         {                        
             // Now we cancel any deliveries that might be waiting in our buffer. This is because
             // otherwise the messages wouldn't get cancelled until the corresponding session died.
             // So if another consumer in another session tried to consume from the channel before that
@@ -293,7 +336,7 @@
             {
                MessageProxy mp = (MessageProxy)i.next();
                
-               DefaultCancel ack = new DefaultCancel(mp.getDeliveryId(), mp.getDeliveryCount());
+               DefaultCancel ack = new DefaultCancel(mp.getDeliveryId(), mp.getDeliveryCount(), false, false);
                
                cancels.add(ack);
             }
@@ -409,17 +452,20 @@
                               
                if (trace) { log.trace(this + " received " + m + " after being blocked on buffer"); }
                        
-               // If message is expired we still call pre and post deliver. This makes sure the
-               // message is acknowledged so it gets removed from the queue/subscription.
-
-               if (!isConnectionConsumer)
+               boolean ignore = checkExpiredOrReachedMaxdeliveries(m, sessionDelegate, maxDeliveries);
+               
+               if (!isConnectionConsumer && !ignore)
                {
-                  sessionDelegate.preDeliver(new DeliveryInfo(m, consumerID, channelID, null));
+                  DeliveryInfo info = new DeliveryInfo(m, consumerID, channelID, null);
+                                                    
+                  m.incDeliveryCount();           
+ 
+                  sessionDelegate.preDeliver(info);                  
                   
-                  sessionDelegate.postDeliver(false);
+                  sessionDelegate.postDeliver();                                    
                }
-               
-               if (!m.getMessage().isExpired())
+                                             
+               if (!ignore)
                {
                   if (trace) { log.trace(this + ": message " + m + " is not expired, pushing it to the caller"); }
                   
@@ -428,7 +474,7 @@
                
                if (trace)
                {
-                  log.trace(this + ": message expired, discarding");
+                  log.trace(this + ": message expired or exceeded max deliveries, discarding");
                }
                
                // the message expired, so discard the message, adjust timeout and reenter the buffer
@@ -456,8 +502,6 @@
          sendChangeRateMessage(1);                    
       }
       
-      m.incDeliveryCount();
-      
       if (trace) { log.trace(this + " receive() returning " + m); }
       
       return m;
@@ -480,7 +524,7 @@
 
    public void setConsumerId(int consumerId)
    {
-       this.consumerID=consumerId;
+       this.consumerID = consumerId;
    }
    
    public void addToFrontOfBuffer(MessageProxy proxy)

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -72,6 +72,9 @@
    // List<DeliveryInfo>
    private List clientAckList;
    
+   // List<DeliveryInfo>
+   //private List clientCancelList;
+   
    private DeliveryInfo autoAckInfo;
 
    private ConnectionState parent;
@@ -111,6 +114,8 @@
       
       clientAckList = new ArrayList();
       
+     // clientCancelList = new ArrayList();
+      
       // TODO could optimise this to use the same map of callbackmanagers (which holds refs
       // to callbackhandlers) in the connection, instead of maintaining another map
       callbackHandlers = new HashMap();
@@ -135,8 +140,7 @@
    {
       this.delegate=(SessionDelegate)delegate;
    }
-   
-   
+      
    /**
     * @return List<AckInfo>
     */
@@ -232,9 +236,7 @@
    // When failing over a session, we keep the old session's state but there are certain fields
    // we need to update
    public void copyState(SessionState newState)
-   {      
-      //this.delegate = newState.delegate;
-      
+   {       
       this.sessionId = newState.sessionId;
    }
 }

Modified: trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -68,7 +68,7 @@
    
    void preDeliver(DeliveryInfo deliveryInfo) throws JMSException;
    
-   void postDeliver(boolean cancel) throws JMSException;
+   void postDeliver() throws JMSException;
    
    MessageListener getMessageListener() throws JMSException;
    

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -30,6 +30,7 @@
 import java.util.Set;
 
 import javax.management.Attribute;
+import javax.management.InstanceNotFoundException;
 import javax.management.MBeanServer;
 import javax.management.ObjectName;
 
@@ -37,6 +38,7 @@
 import org.jboss.jms.server.connectionfactory.ConnectionFactoryJNDIMapper;
 import org.jboss.jms.server.connectionmanager.SimpleConnectionManager;
 import org.jboss.jms.server.connectormanager.SimpleConnectorManager;
+import org.jboss.jms.server.destination.ManagedQueue;
 import org.jboss.jms.server.endpoint.ServerSessionEndpoint;
 import org.jboss.jms.server.plugin.contract.JMSUserManager;
 import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
@@ -106,10 +108,9 @@
 
    private int objectIDSequence = 1;
 
-   private int maxDeliveryAttempts = 10;
+   //The default maximum number of delivery attempts before sending to DLQ - can be overridden on the destination
+   private int defaultMaxDeliveryAttempts = 10;
 
-   private String dlqName;
-
    private Object failoverStatusLock;
    
    private long failoverStartTimeout = 3000;
@@ -143,6 +144,12 @@
 
    protected ObjectName jmsUserManagerObjectName;
    protected JMSUserManager jmsUserManager;
+   
+   protected ObjectName defaultDLQObjectName;
+   protected Queue defaultDLQ;
+   
+   protected ObjectName defaultExpiryQueueObjectName;
+   protected Queue defaultExpiryQueue;
 
    //Other stuff
 
@@ -304,60 +311,81 @@
 
    // JMX Attributes ------------------------------------------------
 
-   public String getDLQName()
+   // Plugins
+   
+   public synchronized ObjectName getPersistenceManager()
    {
-      return dlqName;
+      return persistenceManagerObjectName;
    }
 
-   public void setDLQName(String dlqName)
+   public synchronized void setPersistenceManager(ObjectName on)
    {
-      this.dlqName = dlqName;
+      if (started)
+      {
+         log.warn("Cannot set persistence manager on server peer when server peer is started");
+         return;         
+      }
+      persistenceManagerObjectName = on;
    }
 
-   public int getMaxDeliveryAttempts()
+   public synchronized ObjectName getPostOffice()
    {
-      return maxDeliveryAttempts;
+      return postOfficeObjectName;
    }
 
-   public void setMaxDeliveryAttempts(int attempts)
+   public synchronized void setPostOffice(ObjectName on)
    {
-      this.maxDeliveryAttempts = attempts;
+      if (started)
+      {
+         log.warn("Cannot set post office on server peer when server peer is started");
+         return;         
+      }
+      postOfficeObjectName = on;
    }
 
-   public ObjectName getPersistenceManager()
+   public synchronized ObjectName getJmsUserManager()
    {
-      return persistenceManagerObjectName;
+      return jmsUserManagerObjectName;
    }
 
-   public void setPersistenceManager(ObjectName on)
+   public synchronized void setJMSUserManager(ObjectName on)
    {
-      persistenceManagerObjectName = on;
+      if (started)
+      {
+         log.warn("Cannot set jms user manager on server peer when server peer is started");
+         return;         
+      }
+      jmsUserManagerObjectName = on;
    }
-
-   public ObjectName getPostOffice()
+   
+   public synchronized ObjectName getDefaultDLQ()
    {
-      return postOfficeObjectName;
+      return defaultDLQObjectName;
    }
 
-   public void setPostOffice(ObjectName on)
+   public synchronized void setDefaultDLQ(ObjectName on)
    {
-      postOfficeObjectName = on;
+      defaultDLQObjectName = on;
    }
-
-   public ObjectName getJmsUserManager()
+   
+   public synchronized ObjectName getDefaultExpiryQueue()
    {
-      return jmsUserManagerObjectName;
+      return defaultExpiryQueueObjectName;
    }
 
-   public void setJMSUserManager(ObjectName on)
+   public synchronized void setDefaultExpiryQueue(ObjectName on)
    {
-      jmsUserManagerObjectName = on;
+      this.defaultExpiryQueueObjectName = on;
    }
+   
+   // Instance access
 
    public Object getInstance()
    {
       return this;
    }
+   
+   //read only JMX attributes
 
    public String getJMSVersion()
    {
@@ -408,8 +436,10 @@
    {
       return defaultTopicJNDIContext;
    }
+   
+   //Read - write attributes
 
-   public void setSecurityDomain(String securityDomain) throws Exception
+   public synchronized void setSecurityDomain(String securityDomain) throws Exception
    {
       try
       {
@@ -421,66 +451,66 @@
       }
    }
 
-   public String getSecurityDomain()
+   public synchronized String getSecurityDomain()
    {
       return securityStore.getSecurityDomain();
    }
 
-   public void setDefaultSecurityConfig(Element conf) throws Exception
+   public synchronized void setDefaultSecurityConfig(Element conf) throws Exception
    {
       securityStore.setDefaultSecurityConfig(conf);
    }
 
-   public Element getDefaultSecurityConfig()
+   public synchronized Element getDefaultSecurityConfig()
    {
       return securityStore.getDefaultSecurityConfig();
    }
-
-   public IDManager getMessageIDManager()
+        
+   public synchronized int getQueuedExecutorPoolSize()
    {
-      return messageIDManager;
-   }
-
-   public IDManager getChannelIDManager()
-   {
-      return channelIDManager;
-   }
-
-   public ServerInvocationHandler getInvocationHandler()
-   {
-      return handler;
-   }
-
-   public int getQueuedExecutorPoolSize()
-   {
       return queuedExecutorPoolSize;
    }
 
-   public void setQueuedExecutorPoolSize(int poolSize)
+   public synchronized void setQueuedExecutorPoolSize(int poolSize)
    {
+      if (started)
+      {
+         log.warn("Cannot set jms queued executor pool size on server peer when server peer is started");
+         return;         
+      }
       this.queuedExecutorPoolSize = poolSize;
    }
    
-   public long getFailoverStartTimeout()
+   public synchronized long getFailoverStartTimeout()
    {
       return this.failoverStartTimeout;
    }
    
-   public void setFailoverStartTimeout(long timeout)
+   public synchronized void setFailoverStartTimeout(long timeout)
    {
       this.failoverStartTimeout = timeout;
    }
    
-   public long getFailoverCompleteTimeout()
+   public synchronized long getFailoverCompleteTimeout()
    {
       return this.failoverCompleteTimeout;
    }
    
-   public void setFailoverCompleteTimeout(long timeout)
+   public synchronized void setFailoverCompleteTimeout(long timeout)
    {
       this.failoverCompleteTimeout = timeout;
    }
    
+   public synchronized int getDefaultMaxDeliveryAttempts()
+   {
+      return defaultMaxDeliveryAttempts;
+   }
+
+   public synchronized void setDefaultMaxDeliveryAttempts(int attempts)
+   {
+      this.defaultMaxDeliveryAttempts = attempts;
+   }
+   
    // JMX Operations ------------------------------------------------
 
    public String createQueue(String name, String jndiName) throws Exception
@@ -569,6 +599,21 @@
 
    // Public --------------------------------------------------------
    
+   public IDManager getMessageIDManager()
+   {
+      return messageIDManager;
+   }
+
+   public IDManager getChannelIDManager()
+   {
+      return channelIDManager;
+   }
+
+   public ServerInvocationHandler getInvocationHandler()
+   {
+      return handler;
+   }
+   
    public ServerSessionEndpoint getSession(Integer sessionID)
    {
       return (ServerSessionEndpoint)sessions.get(sessionID);
@@ -587,26 +632,72 @@
       }
    }
 
-   public Queue getDLQ() throws Exception
+   public synchronized Queue getDefaultDLQInstance() throws Exception
    {
-      if (dlqName == null)
-      {
-         //No DLQ name specified so there is no DLQ
-         return null;
+      Queue dlq = null;
+      
+      if (defaultDLQObjectName != null)
+      { 
+         ManagedQueue dest = null;
+         
+         try
+         {         
+            dest = (ManagedQueue)getServer().
+               getAttribute(defaultDLQObjectName, "Instance");
+         }
+         catch (InstanceNotFoundException e)
+         {
+            //Ok
+         }
+         
+         if (dest != null)
+         {            
+            PostOffice po = getPostOfficeInstance();
+            
+            Binding binding = po.getBindingForQueueName(dest.getName());
+            
+            if (binding != null && binding.getQueue().isActive())
+            {
+               dlq =  binding.getQueue();
+            }
+         }
       }
-
-      PostOffice postOffice = getPostOfficeInstance();
-
-      Binding binding = postOffice.getBindingForQueueName(dlqName);
       
-      if (binding != null && binding.getQueue().isActive())
+      return dlq;
+   }
+   
+   public synchronized Queue getDefaultExpiryQueueInstance() throws Exception
+   {
+      Queue expiryQueue = null;
+      
+      if (defaultExpiryQueueObjectName != null)
       {
-         return binding.getQueue();
+         ManagedQueue dest = null;
+         
+         try
+         {         
+            dest = (ManagedQueue)getServer().
+               getAttribute(defaultExpiryQueueObjectName, "Instance");
+         }
+         catch (InstanceNotFoundException e)
+         {
+            //Ok
+         }
+
+         if (dest != null)
+         {            
+            PostOffice po = getPostOfficeInstance();
+            
+            Binding binding = po.getBindingForQueueName(dest.getName());
+            
+            if (binding != null && binding.getQueue().isActive())
+            {
+               expiryQueue =  binding.getQueue();
+            }
+         }
       }
-      else
-      {
-         return null;
-      }   
+      
+      return expiryQueue;
    }
 
    public TransactionRepository getTxRepository()
@@ -735,8 +826,8 @@
       
       Replicator replicator = getReplicator();
 
-      long startToWait = failoverStartTimeout;
-      long completeToWait = failoverCompleteTimeout;
+      long startToWait = getFailoverStartTimeout();
+      long completeToWait = getFailoverCompleteTimeout();
                      
       // Must lock here
       synchronized (failoverStatusLock)

Modified: trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/destination/DestinationServiceSupport.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -6,6 +6,7 @@
  */
 package org.jboss.jms.server.destination;
 
+import javax.management.InstanceNotFoundException;
 import javax.management.ObjectName;
 
 import org.jboss.jms.server.DestinationManager;
@@ -13,10 +14,14 @@
 import org.jboss.jms.server.SecurityManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.util.ExceptionUtil;
+import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.plugin.IDManager;
 import org.jboss.messaging.core.plugin.contract.MessageStore;
+import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PersistenceManager;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
+import org.jboss.messaging.core.plugin.contract.ServerPlugin;
+import org.jboss.messaging.core.plugin.postoffice.Binding;
 import org.jboss.messaging.core.tx.TransactionRepository;
 import org.jboss.system.ServiceMBeanSupport;
 import org.w3c.dom.Element;
@@ -33,7 +38,7 @@
  *
  * $Id$
  */
-public abstract class DestinationServiceSupport extends ServiceMBeanSupport
+public abstract class DestinationServiceSupport extends ServiceMBeanSupport implements ServerPlugin
 {
    // Constants -----------------------------------------------------
 
@@ -43,6 +48,10 @@
 
    private ObjectName serverPeerObjectName;
    
+   private ObjectName dlqObjectName;
+   
+   private ObjectName expiryQueueObjectName;
+   
    protected boolean started = false;
    
    protected ManagedDestination destination;
@@ -79,6 +88,13 @@
    public DestinationServiceSupport()
    {
    }
+   
+   // ServerPlugin implementation ------------------------------------------
+   
+   public MessagingComponent getInstance()
+   {
+      return destination;
+   }
 
    // ServiceMBeanSupport overrides -----------------------------------
    
@@ -167,7 +183,74 @@
    {
       return serverPeerObjectName;
    }
-
+   
+   public void setDLQ(ObjectName on)
+   {
+      dlqObjectName = on;
+      
+      ManagedQueue dest = null;
+      
+      try
+      {
+         
+         try
+         {         
+            dest = (ManagedQueue)getServer().
+               getAttribute(dlqObjectName, "Instance");
+         }
+         catch (InstanceNotFoundException e)
+         {
+            //Ok
+         }
+         
+         Queue dlq = null;
+   
+         if (dest != null)
+         {            
+            Binding binding = postOffice.getBindingForQueueName(dest.getName());
+            
+            if (binding != null && binding.getQueue().isActive())
+            {
+               dlq =  binding.getQueue();
+            }
+         }
+         
+         destination.setDLQ(dlq); 
+      }
+      catch (Exception e)
+      {
+         log.error("Failed to set DLQ", e);
+      }
+   }
+   
+   public ObjectName getDLQ()
+   {
+      return dlqObjectName;
+   }
+   
+   public void setExpiryQueue(ObjectName on)
+   {
+      expiryQueueObjectName = on;
+      
+      Queue expiryQueue = null;
+      
+      try
+      {
+         expiryQueue = (Queue)server.getAttribute(expiryQueueObjectName, "Instance");
+      }
+      catch (Exception e)
+      {
+         //Ok
+      }
+      
+      destination.setExpiryQueue(expiryQueue);
+   }
+   
+   public ObjectName getExpiryQueue()
+   {
+      return expiryQueueObjectName;
+   }
+   
    public void setSecurityConfig(Element securityConfig) throws Exception
    {
       try

Modified: trunk/src/main/org/jboss/jms/server/destination/ManagedDestination.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/destination/ManagedDestination.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/destination/ManagedDestination.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -21,6 +21,8 @@
  */
 package org.jboss.jms.server.destination;
 
+import org.jboss.messaging.core.Queue;
+import org.jboss.messaging.core.plugin.contract.MessagingComponent;
 import org.jboss.messaging.core.plugin.contract.PostOffice;
 import org.w3c.dom.Element;
 
@@ -33,7 +35,7 @@
  * $Id$
  *
  */
-public abstract class ManagedDestination
+public abstract class ManagedDestination implements MessagingComponent
 {
    private static final int DEFAULT_FULL_SIZE = 75000;
    
@@ -62,6 +64,10 @@
    
    protected PostOffice postOffice;
    
+   protected Queue dlq;
+   
+   protected Queue expiryQueue;
+   
    public ManagedDestination()
    {      
    }
@@ -167,5 +173,35 @@
       this.temporary = temporary;
    }
    
+   public Queue getDLQ()
+   {
+      return dlq;
+   }
+   
+   public void setDLQ(Queue dlq)
+   {
+      this.dlq = dlq;
+   }
+   
+   public Queue getExpiryQueue()
+   {
+      return expiryQueue;
+   }
+   
+   public void setExpiryQueue(Queue expiryQueue)
+   {
+      this.expiryQueue = expiryQueue;
+   }
+   
    public abstract boolean isQueue();
+
+   public void start() throws Exception
+   {
+      //NOOP
+   }
+
+   public void stop() throws Exception
+   {   
+      //NOOP
+   }
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/endpoint/Cancel.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -35,4 +35,8 @@
    long getDeliveryId();
    
    int getDeliveryCount();
+   
+   boolean isExpired();
+   
+   boolean isReachedMaxDeliveryAttempts();
 }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DefaultCancel.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -46,7 +46,11 @@
    
    private long deliveryId;
    
-   private int deliveryCount;      
+   private int deliveryCount;    
+   
+   private boolean expired;
+   
+   private boolean reachedMaxDeliveryAttempts;
 
    // Static --------------------------------------------------------
    
@@ -56,11 +60,15 @@
    {      
    }
    
-   public DefaultCancel(long deliveryId, int deliveryCount)
+   public DefaultCancel(long deliveryId, int deliveryCount, boolean expired, boolean maxDeliveries)
    {      
       this.deliveryId = deliveryId;
       
       this.deliveryCount = deliveryCount;
+      
+      this.expired = expired;
+      
+      this.reachedMaxDeliveryAttempts = maxDeliveries;
    }
 
    // Public --------------------------------------------------------
@@ -74,6 +82,16 @@
    {
       return deliveryCount;
    }
+   
+   public boolean isExpired()
+   {
+      return expired;
+   }
+   
+   public boolean isReachedMaxDeliveryAttempts()
+   {
+      return reachedMaxDeliveryAttempts;
+   }
 
    // Class YYY overrides -------------------------------------------
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -58,6 +58,10 @@
    //to the connection consumer's session, otherwise it will be null
    private SessionDelegate connectionConsumerSession;
    
+  // private boolean exceedDeliveryAttempts;
+   
+  // private boolean expired;
+   
    // Static --------------------------------------------------------
    
    // Constructors --------------------------------------------------
@@ -95,6 +99,31 @@
    {
       return connectionConsumerSession;
    }
+   
+//   public void setExceededDeliveryAttempts()
+//   {
+//      exceedDeliveryAttempts = true;
+//   }
+//   
+//   public void setExpired()
+//   {
+//      expired = true;
+//   }
+//        
+//   public boolean exceededDeliveryAttempts()
+//   {
+//      return exceedDeliveryAttempts;
+//   }
+//   
+//   public boolean isExpired()
+//   {
+//      return expired;
+//   }
+//   
+//   public boolean isToCancel()
+//   {
+//      return exceedDeliveryAttempts || expired;
+//   }
 
    public String toString()
    {

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -29,6 +29,7 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.selector.Selector;
+import org.jboss.jms.server.destination.ManagedDestination;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.util.ExceptionUtil;
@@ -37,6 +38,7 @@
 import org.jboss.messaging.core.Delivery;
 import org.jboss.messaging.core.DeliveryObserver;
 import org.jboss.messaging.core.MessageReference;
+import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.Receiver;
 import org.jboss.messaging.core.Routable;
 import org.jboss.messaging.core.SimpleDelivery;
@@ -92,6 +94,10 @@
 
    private JBossDestination destination;
    
+   private Queue dlq;
+   
+   private Queue expiryQueue;
+   
    private boolean started;
    
    //This lock protects starting and stopping
@@ -103,9 +109,10 @@
    // Constructors --------------------------------------------------
 
    ServerConsumerEndpoint(int id, Channel messageQueue, String queueName,
-                         ServerSessionEndpoint sessionEndpoint,
-                         String selector, boolean noLocal, JBossDestination dest)
-                         throws InvalidSelectorException
+                          ServerSessionEndpoint sessionEndpoint,
+                          String selector, boolean noLocal, JBossDestination dest,
+                          Queue dlq, Queue expiryQueue)
+                          throws InvalidSelectorException
    {
       if (trace) { log.trace("constructing consumer endpoint " + id); }
 
@@ -125,6 +132,10 @@
       
       this.destination = dest;
       
+      this.dlq = dlq;
+      
+      this.expiryQueue = expiryQueue;
+      
       //Always start as false - wait for consumer to initiate
       this.clientAccepting = false;
       
@@ -164,6 +175,20 @@
          
          return null;
       }
+      
+      if (ref.isExpired())
+      {
+         SimpleDelivery delivery = new SimpleDelivery(observer, ref);
+         
+         try
+         {
+            sessionEndpoint.expireDelivery(delivery, expiryQueue);
+         }
+         catch (Throwable t)
+         {
+            log.error("Failed to expire delivery: " + delivery, t);
+         }
+      }
         
       synchronized (startStopLock)
       {         
@@ -385,6 +410,16 @@
    
    // Package protected ---------------------------------------------
    
+   Queue getDLQ()
+   {
+      return dlq;
+   }
+   
+   Queue getExpiryQueue()
+   {
+      return expiryQueue;
+   }
+     
    void localClose() throws Throwable
    {      
       if (trace) { log.trace(this + " grabbed the main lock in close() " + this); }

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerSessionEndpoint.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -135,7 +135,8 @@
    private PostOffice postOffice;
    private int nodeId;
    private int maxDeliveryAttempts;
-   private Queue dlq;
+   private Queue defaultDLQ;
+   private Queue defaultExpiryQueue;
    
    // Map < deliveryId, Delivery>
    private Map deliveries;
@@ -166,9 +167,10 @@
       consumers = new HashMap();
 		browsers = new HashMap();
       
-      dlq = sp.getDLQ();
+      defaultDLQ = sp.getDefaultDLQInstance();
+      defaultExpiryQueue = sp.getDefaultExpiryQueueInstance();
       tr = sp.getTxRepository();
-      maxDeliveryAttempts = sp.getMaxDeliveryAttempts();
+      maxDeliveryAttempts = sp.getDefaultMaxDeliveryAttempts();
       
       deliveries = new ConcurrentHashMap();
       
@@ -371,7 +373,7 @@
          throw ExceptionUtil.handleJMSInvocation(t, this + " acknowledgeBatch");
       }
    }
-       
+             
    public void cancelDelivery(Cancel cancel) throws JMSException
    {
       if (trace) {log.trace(this + " cancelDelivery " + cancel); }
@@ -386,31 +388,30 @@
       catch (Throwable t)
       {
          throw ExceptionUtil.handleJMSInvocation(t, this + " cancelDelivery");
-      }
-     
-   }      
+      }     
+   }            
 
    public void cancelDeliveries(List cancels) throws JMSException
    {
       if (trace) {log.trace(this + " cancelDeliveries " + cancels); }
-      
+        
       try
       {
          // deliveries must be cancelled in reverse order
 
          Set channels = new HashSet();
-                           
+                          
          for (int i = cancels.size() - 1; i >= 0; i--)
          {
             Cancel cancel = (Cancel)cancels.get(i);       
             
             if (trace) { log.trace(this + " cancelling delivery " + cancel.getDeliveryId()); }
-            
+                        
             Delivery del = cancelDeliveryInternal(cancel);
             
             channels.add(del.getObserver());
          }
-                  
+                              
          // need to prompt delivery for all affected channels
          
          promptDelivery(channels);
@@ -431,8 +432,6 @@
             throw new IllegalStateException("Recovering deliveries but post office is not clustered!");
          }
          
-         ClusteredPostOffice po = (ClusteredPostOffice)postOffice;
-         
          long maxDeliveryId = 0;
                   
          //Sort into different list for each channel
@@ -465,7 +464,7 @@
             Long channelId = (Long)entry.getKey();
             
             //Look up channel
-            Binding binding = po.getBindingforChannelId(channelId.longValue());
+            Binding binding = postOffice.getBindingforChannelId(channelId.longValue());
             
             if (binding == null)
             {
@@ -703,7 +702,23 @@
    }
 
    // Package protected ---------------------------------------------
+   
+   void expireDelivery(Delivery del, Queue expiryQueue) throws Throwable
+   {
+      if (trace) { log.trace("Reference has expired: " + del.getReference()); }
       
+      if (expiryQueue != null)
+      {
+         if (trace) { log.trace("Sending to expiry queue"); }
+         
+         moveInTransaction(del, expiryQueue);
+      }
+      else
+      {
+         log.warn("No expiry queue has been configured so removing the reference");
+      }
+   }
+      
    void cancelDeliveriesForConsumerAfterDeliveryId(int consumerId, long lastDeliveryId) throws Throwable
    {
       //Need to cancel in reverse
@@ -921,20 +936,6 @@
 
    // Private -------------------------------------------------------
    
-   private void acknowledgeDeliveryInternal(Ack ack) throws Throwable
-   {
-      if (trace) { log.trace(this + " acknowledging delivery " + ack.getDeliveryId()); }
-      
-      DeliveryRecord rec = (DeliveryRecord)deliveries.remove(new Long(ack.getDeliveryId()));
-      
-      if (rec == null)
-      {
-         throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
-      }
-      
-      rec.del.acknowledge(null);    
-   } 
-   
    private Delivery cancelDeliveryInternal(Cancel cancel) throws Throwable
    {
       DeliveryRecord rec = (DeliveryRecord)deliveries.remove(new Long(cancel.getDeliveryId()));
@@ -943,51 +944,112 @@
       {
          throw new IllegalStateException("Cannot find delivery to cancel " + cancel.getDeliveryId());
       }
-                              
-      if (cancel.getDeliveryCount() >= maxDeliveryAttempts)
+                 
+      //Note we check the flag *and* evaluate again, this is because the server and client clocks may
+      //be out of synch and don't want to send back to the client a message it thought it has sent to
+      //the expiry queue  
+      boolean expired = cancel.isExpired() || rec.del.getReference().isExpired();
+      
+      //Note we check the flag *and* evaluate again, this is because the server value of maxDeliveries
+      //might get changed after the client has sent the cancel - and we don't want to end up cancelling
+      //back to the original queue
+      boolean reachedMaxDeliveryAttempts =
+         cancel.isReachedMaxDeliveryAttempts() || cancel.getDeliveryCount() >= maxDeliveryAttempts;
+         
+      if (!expired && !reachedMaxDeliveryAttempts)
       {
-         //Send to DLQ
+         //Normal cancel back to the queue
          
-         //We do this in a tx so we don't end up with the message in both the original queue
-         //and the dlq if it fails half way through
-         Transaction tx = tr.createTransaction();
+         rec.del.getReference().setDeliveryCount(cancel.getDeliveryCount());
          
-         try
-         {               
-            if (dlq != null)
-            {         
-               //reset delivery count to zero
-               rec.del.getReference().setDeliveryCount(0);
-               
-               dlq.handle(null, rec.del.getReference(), tx);
-               
-               rec.del.acknowledge(tx);           
-            }
-            else
-            {
-               log.warn("Cannot send to DLQ since DLQ has not been deployed! The message will be removed");
-               
-               rec.del.acknowledge(tx);
-            }                              
-                        
-            tx.commit();
+         rec.del.cancel();
+      }
+      else
+      {
+         ServerConsumerEndpoint consumer = null;
+         
+         synchronized (consumers)
+         {
+            consumer = (ServerConsumerEndpoint)consumers.get(new Integer(rec.consumerId));
          }
-         catch (Throwable t)
+         
+         if (consumer == null)
          {
-            tx.rollback();
+            throw new IllegalStateException("Cannot find consumer with id " + rec.consumerId);
+         }
+         
+         if (expired)
+         {
+            //Sent to expiry queue
             
-            throw t;
-         }         
+            this.moveInTransaction(rec.del, consumer.getExpiryQueue());
+         }
+         else
+         {
+            //Send to DLQ
+            
+            this.moveInTransaction(rec.del, consumer.getDLQ());
+         }
+      }      
+      
+      return rec.del;
+   }      
+   
+   private void moveInTransaction(Delivery del, Queue queue) throws Throwable
+   {
+      Transaction tx = tr.createTransaction();
+      
+      try
+      {               
+         if (queue != null)
+         {                               
+            //Need to reset expiration and delivery account
+            del.getReference().setExpiration(0);
+            del.getReference().getMessage().setExpiration(0);
+            del.getReference().setDeliveryCount(0);
+            
+            queue.handle(null, del.getReference(), tx);
+            
+            del.acknowledge(tx);           
+         }
+         else
+         {
+            log.warn("Cannot move to destination since destination has not been deployed! The message will be removed");
+            
+            del.acknowledge(tx);
+         }             
+         
+         tx.commit();
+         
+         if (queue != null)
+         {
+            queue.deliver(false);
+         }
       }
-      else
-      {                                                   
-         rec.del.getReference().setDeliveryCount(cancel.getDeliveryCount());
+      catch (Throwable t)
+      {
+         tx.rollback();
          
-         rec.del.cancel();
+         throw t;
+      } 
+   }
+   
+   
+   private void acknowledgeDeliveryInternal(Ack ack) throws Throwable
+   {
+      if (trace) { log.trace(this + " acknowledging delivery " + ack.getDeliveryId()); }
+      
+      DeliveryRecord rec = (DeliveryRecord)deliveries.remove(new Long(ack.getDeliveryId()));
+      
+      if (rec == null)
+      {
+         throw new IllegalStateException("Cannot find delivery to acknowledge: " + ack.getDeliveryId());
       }
       
-      return rec.del;
-   }
+      rec.del.acknowledge(null);    
+   } 
+   
+   
 
    private ConsumerDelegate failoverConsumer(JBossDestination jmsDestination,
                                              String selectorString,
@@ -1023,10 +1085,22 @@
       int consumerID = connectionEndpoint.getServerPeer().getNextObjectID();
       int prefetchSize = connectionEndpoint.getPrefetchSize();
       
+      ManagedDestination dest = 
+         sp.getDestinationManager().getDestination(jmsDestination.getName(), jmsDestination.isQueue());
+      
+      if (dest == null)
+      {
+         throw new IllegalStateException("Cannot find managed destination for dest: " + jmsDestination);
+      }
+      
+      Queue dlqToUse = dest.getDLQ() == null ? defaultDLQ : dest.getDLQ();
+      
+      Queue expiryQueueToUse = dest.getExpiryQueue() == null ? defaultExpiryQueue : dest.getExpiryQueue();
+            
       ServerConsumerEndpoint ep =
          new ServerConsumerEndpoint(consumerID, binding.getQueue(),
                                     binding.getQueue().getName(), this, selectorString, noLocal,
-                                    jmsDestination);
+                                    jmsDestination, dlqToUse, expiryQueueToUse);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
 
@@ -1295,10 +1369,14 @@
       
       int prefetchSize = connectionEndpoint.getPrefetchSize();
       
+      Queue dlqToUse = mDest.getDLQ() == null ? defaultDLQ : mDest.getDLQ();
+      
+      Queue expiryQueueToUse = mDest.getExpiryQueue() == null ? defaultExpiryQueue : mDest.getExpiryQueue();
+      
       ServerConsumerEndpoint ep =
          new ServerConsumerEndpoint(consumerID, (PagingFilteredQueue)binding.getQueue(),
                   binding.getQueue().getName(), this, selectorString, noLocal,
-                  jmsDestination);
+                  jmsDestination, dlqToUse, expiryQueueToUse);
       
       JMSDispatcher.instance.registerTarget(new Integer(consumerID), new ConsumerAdvised(ep));
       
@@ -1342,7 +1420,7 @@
     * In such a case we might otherwise end up with the consumer closing but not all it's deliveries being
     * cancelled, which would mean they wouldn't be cancelled until the session is closed which is too late
     */
-   private class DeliveryRecord
+   private static class DeliveryRecord
    {
       Delivery del;
       

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -285,6 +285,10 @@
                   
                   dos.writeInt(cancel.getDeliveryCount());
                   
+                  dos.writeBoolean(cancel.isExpired());
+                  
+                  dos.writeBoolean(cancel.isReachedMaxDeliveryAttempts());
+                  
                   dos.flush();
    
                   if (trace) { log.trace("wrote cancelDelivery()"); }
@@ -308,6 +312,10 @@
                      dos.writeLong(cancel.getDeliveryId());
                      
                      dos.writeInt(cancel.getDeliveryCount());
+                     
+                     dos.writeBoolean(cancel.isExpired());
+                     
+                     dos.writeBoolean(cancel.isReachedMaxDeliveryAttempts());
                   }
    
                   dos.flush();
@@ -723,7 +731,11 @@
                
                int deliveryCount = dis.readInt();
                
-               Object[] args = new Object[] {new DefaultCancel(deliveryId, deliveryCount)};
+               boolean expired = dis.readBoolean();
+               
+               boolean reachedMaxDeliveries = dis.readBoolean();
+               
+               Object[] args = new Object[] {new DefaultCancel(deliveryId, deliveryCount, expired, reachedMaxDeliveries)};
    
                mi.setArguments(args);
    
@@ -749,7 +761,11 @@
                   
                   int deliveryCount = dis.readInt();
                   
-                  DefaultCancel cancel = new DefaultCancel(deliveryId, deliveryCount);
+                  boolean expired = dis.readBoolean();
+                  
+                  boolean reachedMaxDeliveries = dis.readBoolean();
+                  
+                  DefaultCancel cancel = new DefaultCancel(deliveryId, deliveryCount, expired, reachedMaxDeliveries);
                                     
                   acks.add(cancel);
                }

Modified: trunk/src/main/org/jboss/jms/tx/ClientTransaction.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/jms/tx/ClientTransaction.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -48,7 +48,6 @@
    
    private static final Logger log = Logger.getLogger(ClientTransaction.class);
    
-
    public final static byte TX_OPEN = 0;
    
    public final static byte TX_ENDED = 1;

Modified: trunk/src/main/org/jboss/messaging/core/ChannelSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/messaging/core/ChannelSupport.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -519,54 +519,45 @@
             {
                ref = nextReference(iter);               
             }
+            
             if (ref != null)
             {
-               // Check if message is expired (we also do this on the clientside) If so ack it from the channel
-               if (ref.isExpired())
+               // Attempt to push the ref to a receiver
+               
+               if (trace) { log.trace(this + " pushing " + ref); }                                  
+
+               Delivery del = router.handle(this, ref, null);
+
+               receiversReady = del != null;
+               
+               if (del == null)
                {
-                  expireRef(ref, iter);
+                  // No receiver, broken receiver or full receiver so we stop delivering
+                  if (trace) { log.trace(this + ": no delivery returned for message" + ref + " so no receiver got the message. Delivery is now complete"); }
+
+                  break;
                }
-               else
+               else if (!del.isSelectorAccepted())
                {
-                  // Reference is not expired
-
-                  // Attempt to push the ref to a receiver
+                  // No receiver accepted the message because no selectors matched, so we create
+                  // an iterator (if we haven't already created it) to iterate through the refs
+                  // in the channel. No delivery was really performed
                   
-                  if (trace) { log.trace(this + " pushing " + ref); }                                  
-
-                  Delivery del = router.handle(this, ref, null);
-
-                  receiversReady = del != null;
-                  
-                  if (del == null)
+                  if (iter == null)
                   {
-                     // No receiver, broken receiver or full receiver so we stop delivering
-                     if (trace) { log.trace(this + ": no delivery returned for message" + ref + " so no receiver got the message. Delivery is now complete"); }
-
-                     break;
-                  }
-                  else if (!del.isSelectorAccepted())
-                  {
-                     // No receiver accepted the message because no selectors matched, so we create
-                     // an iterator (if we haven't already created it) to iterate through the refs
-                     // in the channel. No delivery was really performed
-                     
-                     if (iter == null)
-                     {
-                        iter = messageRefs.iterator();
-                     }                     
-                  }
-                  else
-                  {
-                     if (trace) { log.trace(this + ": " + del + " returned for message:" + ref); }
-                     
-                     // Receiver accepted the reference
-                     
-                     removeReference(iter);
-                     
-                     deliveringCount.increment();                     
-                  }
+                     iter = messageRefs.iterator();
+                  }                     
                }
+               else
+               {
+                  if (trace) { log.trace(this + ": " + del + " returned for message:" + ref); }
+                  
+                  // Receiver accepted the reference
+                  
+                  removeReference(iter);
+                  
+                  deliveringCount.increment();                     
+               }               
             }
             else
             {
@@ -783,28 +774,6 @@
    
    // Private -------------------------------------------------------
    
-   private void expireRef(MessageReference ref, ListIterator iter) throws Exception
-   {
-      if (trace) { log.trace("Message reference: " + ref + " has expired"); }
-
-      // remove and acknowledge it
-      synchronized (refLock)
-      {
-         if (iter == null)
-         {
-            removeFirstInMemory();
-         }
-         else
-         {
-            iter.remove();
-         }
-      }
-
-      Delivery delivery = new SimpleDelivery(this, ref, true);
-
-      acknowledgeInternal(delivery, null, true, false);
-   }
-   
    private void removeReference(ListIterator iter) throws Exception
    {
       synchronized (refLock)

Modified: trunk/src/main/org/jboss/messaging/core/Routable.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/Routable.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/messaging/core/Routable.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -72,6 +72,8 @@
    long getExpiration();
 
    boolean isExpired();
+   
+   void setExpiration(long expiration);
 
    /**
     * @return the time (in GMT milliseconds) when this routable was delivered to the provider.

Modified: trunk/src/main/org/jboss/messaging/core/message/RoutableSupport.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/message/RoutableSupport.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/src/main/org/jboss/messaging/core/message/RoutableSupport.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -147,6 +147,11 @@
    {
       return expiration;
    }
+   
+   public void setExpiration(long expiration)
+   {
+      this.expiration = expiration;
+   }
 
    public long getTimestamp()
    {

Modified: trunk/tests/src/org/jboss/test/messaging/jms/DLQTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/DLQTest.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/tests/src/org/jboss/test/messaging/jms/DLQTest.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -31,6 +31,7 @@
 import javax.jms.Queue;
 import javax.jms.Session;
 import javax.jms.TextMessage;
+import javax.management.ObjectName;
 import javax.naming.InitialContext;
 import javax.naming.NameNotFoundException;
 
@@ -72,13 +73,30 @@
    {
       if (ServerManagement.isRemote())
       {
-         //This test can only run in local mode
          return;
       }
-
+      
       ServerManagement.deployQueue("DLQ");
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+      
+      ObjectName dlqObjectName = (ObjectName)ServerManagement.getAttribute(serverPeerObjectName, "DefaultDLQ");
+      
+      assertNotNull(dlqObjectName);
+            
+      String name = (String)ServerManagement.getAttribute(dlqObjectName, "Name");
+      
+      assertNotNull(name);
+      
+      assertEquals("DLQ", name);
 
-      org.jboss.messaging.core.Queue dlq = ServerManagement.getServer().getServerPeer().getDLQ();
+      String jndiName = (String)ServerManagement.getAttribute(dlqObjectName, "JNDIName");
+      
+      assertNotNull(jndiName);
+      
+      assertEquals("/queue/DLQ", jndiName);
+      
+      org.jboss.messaging.core.Queue dlq = ServerManagement.getServer().getServerPeer().getDefaultDLQInstance();
 
       assertNotNull(dlq);
 
@@ -98,9 +116,8 @@
       {
          if (ic != null) ic.close();
 
-         log.info("undeploying dlq");
          ServerManagement.undeployQueue("DLQ");
-         log.info("undeployed dlq");
+
       }
    }
 
@@ -108,12 +125,11 @@
    {
       if (ServerManagement.isRemote())
       {
-         //This test can only run in local mode
          return;
       }
+      
+      org.jboss.messaging.core.Queue dlq = ServerManagement.getServer().getServerPeer().getDefaultDLQInstance();
 
-      org.jboss.messaging.core.Queue dlq = ServerManagement.getServer().getServerPeer().getDLQ();
-
       assertNull(dlq);
 
       InitialContext ic = null;
@@ -138,272 +154,517 @@
          if (ic != null) ic.close();
       }
    }
-//
-//   public void testSendToDLQWithMessageListenerPersistent() throws Exception
-//   {
-//      sendToDLQWithMessageListener(true);
-//   }
-//
-//   public void testSendToDLQWithMessageListenerNonPersistent() throws Exception
-//   {
-//      sendToDLQWithMessageListener(false);
-//   }
-//
-//   public void testSendToDLQWithReceivePersistent() throws Exception
-//   {
-//      sendToDLQWithReceive(true);
-//   }
-//
-//   public void testSendToDLQWithReceiveNonPersistent() throws Exception
-//   {
-//      sendToDLQWithReceive(false);
-//   }
-//
-//   public void testSendToDLQWithReceivePartialPersistent() throws Exception
-//   {
-//      sendToDLQWithReceivePartial(true);
-//   }
-//
-//   public void testSendToDLQWithReceivePartialNonPersistent() throws Exception
-//   {
-//      sendToDLQWithReceivePartial(false);
-//   }
-//
-//   public void sendToDLQWithMessageListener(boolean persistent) throws Exception
-//   {
-//      Connection conn = null;
-//
-//      ServerManagement.deployQueue("DLQ");
-//
-//      Queue dlq = (Queue)ic.lookup("/queue/DLQ");
-//
-//      try
-//      {
-//         conn = cf.createConnection();
-//
-//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//
-//         MessageProducer prod = sess.createProducer(queue);
-//
-//         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-//
-//         for (int i = 0; i < 10; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("Message:" + i);
-//
-//            prod.send(tm);
-//         }
-//
-//         MessageConsumer cons = sess.createConsumer(queue);
-//
-//         cons.setMessageListener(new FailingMessageListener());
-//
-//         conn.start();
-//
-//         Thread.sleep(4000);
-//
-//         cons.setMessageListener(null);
-//
-//         Message m = cons.receive(1000);
-//
-//         assertNull(m);
-//
-//         //Message should all be in the dlq - let's check
-//
-//         MessageConsumer cons2 = sess.createConsumer(dlq);
-//
-//         for (int i = 0; i < 10; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons2.receive(1000);
-//
-//            assertNotNull(tm);
-//
-//            assertEquals("Message:" + i, tm.getText());
-//         }
-//
-//      }
-//      finally
-//      {
-//         ServerManagement.undeployQueue("DLQ");
-//
-//         if (conn != null) conn.close();
-//      }
-//   }
-//
-//   public void sendToDLQWithReceive(boolean persistent) throws Exception
-//   {
-//      Connection conn = null;
-//
-//      ServerManagement.deployQueue("DLQ");
-//
-//      Queue dlq = (Queue)ic.lookup("/queue/DLQ");
-//
-//      try
-//      {
-//         conn = cf.createConnection();
-//
-//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//
-//         MessageProducer prod = sess.createProducer(queue);
-//
-//         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-//
-//         for (int i = 0; i < 10; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("Message:" + i);
-//
-//            prod.send(tm);
-//         }
-//
-//         Session sess2 = conn.createSession(true, Session.SESSION_TRANSACTED);
-//
-//         MessageConsumer cons = sess2.createConsumer(queue);
-//
-//         conn.start();
-//
-//         for (int i = 0; i < 10; i++)  // retries - default is 10
-//         {
-//            for (int j = 0; j < 10; j++)
-//            {
-//               TextMessage tm = (TextMessage)cons.receive(1000);
-//
-//               assertNotNull(tm);
-//
-//               assertEquals("Message:" + j, tm.getText());
-//            }
-//
-//            //rollback should cause redelivery
-//            sess2.rollback();
-//         }
-//
-//         cons.close();
-//
-//         MessageConsumer cons2 = sess2.createConsumer(queue);
-//
-//         Message m = cons2.receive(1000);
-//
-//         assertNull(m);
-//
-//         //Message should all be in the dlq - let's check
-//
-//         MessageConsumer cons3 = sess.createConsumer(dlq);
-//
-//         for (int i = 0; i < 10; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons3.receive(1000);
-//
-//            assertNotNull(tm);
-//
-//            assertEquals("Message:" + i, tm.getText());
-//         }
-//
-//      }
-//      finally
-//      {
-//         ServerManagement.undeployQueue("DLQ");
-//
-//         if (conn != null) conn.close();
-//      }
-//   }
-//
-//   public void sendToDLQWithReceivePartial(boolean persistent) throws Exception
-//   {
-//      Connection conn = null;
-//
-//      ServerManagement.deployQueue("DLQ");
-//
-//      Queue dlq = (Queue)ic.lookup("/queue/DLQ");
-//
-//      try
-//      {
-//         conn = cf.createConnection();
-//
-//         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-//
-//         MessageProducer prod = sess.createProducer(queue);
-//
-//         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
-//
-//         for (int i = 0; i < 10; i++)
-//         {
-//            TextMessage tm = sess.createTextMessage("Message:" + i);
-//
-//            prod.send(tm);
-//         }
-//
-//         Session sess2 = conn.createSession(true, Session.SESSION_TRANSACTED);
-//
-//         MessageConsumer cons = sess2.createConsumer(queue);
-//
-//         conn.start();
-//
-//         for (int i = 0; i < 5; i++)  // retries - default is 10
-//         {
-//            for (int j = 0; j < 10; j++)
-//            {
-//               TextMessage tm = (TextMessage)cons.receive(1000);
-//
-//               assertNotNull(tm);
-//
-//               assertEquals("Message:" + j, tm.getText());
-//            }
-//
-//            //rollback should cause redelivery
-//            sess2.rollback();
-//         }
-//
-//         //They should now be cancelled back to the server
-//         cons.close();
-//
-//         cons = sess2.createConsumer(queue);
-//
-//         for (int i = 0; i < 5; i++)  // retries - default is 10
-//         {
-//            for (int j = 0; j < 10; j++)
-//            {
-//               TextMessage tm = (TextMessage)cons.receive(1000);
-//
-//               assertNotNull(tm);
-//
-//               assertEquals("Message:" + j, tm.getText());
-//            }
-//
-//            //rollback should cause redelivery
-//            sess2.rollback();
-//         }
-//
-//         cons.close();
-//
-//         //Now they should be in DLQ
-//
-//         MessageConsumer cons2 = sess2.createConsumer(queue);
-//
-//         Message m = cons2.receive(1000);
-//
-//         assertNull(m);
-//
-//         //Message should all be in the dlq - let's check
-//
-//         MessageConsumer cons3 = sess.createConsumer(dlq);
-//
-//         for (int i = 0; i < 10; i++)
-//         {
-//            TextMessage tm = (TextMessage)cons3.receive(1000);
-//
-//            assertNotNull(tm);
-//
-//            assertEquals("Message:" + i, tm.getText());
-//         }
-//
-//      }
-//      finally
-//      {
-//         ServerManagement.undeployQueue("DLQ");
-//
-//         if (conn != null) conn.close();
-//      }
-//   }
+   
+   public void testDefaultAndOverrideDLQ() throws Exception
+   {
+      if (ServerManagement.isRemote())
+      {
+         return;
+      }
+      
+      final int NUM_MESSAGES = 5;
+      
+      final int MAX_DELIVERIES = 8;
+      
+      ServerManagement.deployQueue("DefaultDLQ");
+      
+      ServerManagement.deployQueue("OverrideDLQ");
+      
+      ServerManagement.deployQueue("TestQueue");
+      
+      String defaultDLQObjectName = "jboss.messaging.destination:service=Queue,name=DefaultDLQ";
+      
+      String overrideDLQObjectName = "jboss.messaging.destination:service=Queue,name=OverrideDLQ";
+      
+      String testQueueObjectName = "jboss.messaging.destination:service=Queue,name=TestQueue";
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+      
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts", String.valueOf(MAX_DELIVERIES));
+            
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultDLQ", defaultDLQObjectName);
+      
+      ServerManagement.setAttribute(new ObjectName(testQueueObjectName), "DLQ", "");
+      
+      Queue testQueue = (Queue)ic.lookup("/queue/TestQueue");
+      
+      Queue defaultDLQ = (Queue)ic.lookup("/queue/DefaultDLQ");
+      
+      Queue overrideDLQ = (Queue)ic.lookup("/queue/OverrideDLQ");
+      
+      drainDestination(cf, testQueue);
+            
+      drainDestination(cf, defaultDLQ);
+            
+      drainDestination(cf, overrideDLQ);
+            
+      Connection conn = null;
+      
+      try
+      {      
+         conn = cf.createConnection();
+         
+         {         
+            Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+            MessageProducer prod = sess.createProducer(testQueue);
+   
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = sess.createTextMessage("Message:" + i);
+   
+               prod.send(tm);
+            }
+   
+            Session sess2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+            
+            MessageConsumer cons = sess2.createConsumer(testQueue);
+            
+            conn.start();
+   
+            for (int i = 0; i < MAX_DELIVERIES; i++) 
+            {
+               for (int j = 0; j < NUM_MESSAGES; j++)
+               {
+                  TextMessage tm = (TextMessage)cons.receive(1000);
+   
+                  assertNotNull(tm);
+   
+                  assertEquals("Message:" + j, tm.getText());
+               }
+   
+               sess2.recover();
+            }
+            
+            //At this point all the messages have been delivered exactly MAX_DELIVERIES times 
+            
+            Message m = cons.receive(1000);
+            
+            assertNull(m);
+            
+            //Now should be in default dlq
+            
+            MessageConsumer cons3 = sess.createConsumer(defaultDLQ);
+            
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = (TextMessage)cons3.receive(1000);
+   
+               assertNotNull(tm);
+   
+               assertEquals("Message:" + i, tm.getText());
+            }
+            
+            conn.close();
+         }
+         
+         
+         {
+            //Now try with overriding the default dlq
+            
+            conn = cf.createConnection();
+            
+            log.info("I am setting dlq with " + overrideDLQObjectName);
+            ServerManagement.setAttribute(new ObjectName(testQueueObjectName), "DLQ", overrideDLQObjectName);
+            
+            Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+            MessageProducer prod = sess.createProducer(testQueue);
+   
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = sess.createTextMessage("Message:" + i);
+   
+               prod.send(tm);
+            }
+   
+            Session sess2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+            
+            MessageConsumer cons = sess2.createConsumer(testQueue);
+            
+            conn.start();
+   
+            for (int i = 0; i < MAX_DELIVERIES; i++) 
+            {
+               for (int j = 0; j < NUM_MESSAGES; j++)
+               {
+                  TextMessage tm = (TextMessage)cons.receive(1000);
+   
+                  assertNotNull(tm);
+   
+                  assertEquals("Message:" + j, tm.getText());
+               }
+   
+               sess2.recover();
+            }
+            
+            //At this point all the messages have been delivered exactly MAX_DELIVERIES times 
+            
+            Message m = cons.receive(1000);
+            
+            assertNull(m);
+            
+            //Now should be in override dlq
+            
+            MessageConsumer cons3 = sess.createConsumer(overrideDLQ);
+            
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = (TextMessage)cons3.receive(1000);
+   
+               assertNotNull(tm);
+   
+               assertEquals("Message:" + i, tm.getText());
+            }
+         }
+      }
+      finally
+      {
+         ServerManagement.setAttribute(serverPeerObjectName, "DefaultDLQ", "jboss.messaging.destination:service=Queue,name=DLQ");
+                  
+         ServerManagement.undeployQueue("DefaultDLQ");
+         
+         ServerManagement.undeployQueue("OverrideDLQ");
+         
+         ServerManagement.undeployQueue("TestQueue");
+         
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+            
 
+   public void testWithMessageListenerPersistent() throws Exception
+   {
+      testWithMessageListener(true);
+   }
+
+   public void testWithMessageListenerNonPersistent() throws Exception
+   {
+      testWithMessageListener(false);
+   }
+
+   public void testWithReceiveClientAckPersistent() throws Exception
+   {
+      this.testWithReceiveClientAck(true);
+   }
+
+   public void testWithReceiveClientAckNonPersistent() throws Exception
+   {
+      testWithReceiveClientAck(false);
+   }
+   
+   public void testWithReceiveTransactionalPersistent() throws Exception
+   {
+      this.testWithReceiveTransactional(true);
+   }
+
+   public void testWithReceiveTransactionalNonPersistent() throws Exception
+   {
+      testWithReceiveTransactional(false);
+   }
+
+   public void testWithMessageListener(boolean persistent) throws Exception
+   {
+      Connection conn = null;
+
+      ServerManagement.deployQueue("DLQ");
+
+      Queue dlq = (Queue)ic.lookup("/queue/DLQ");
+      
+      drainDestination(cf, dlq);
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+      
+      final int MAX_DELIVERIES = 16;
+      
+      final int NUM_MESSAGES = 5;
+      
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts", String.valueOf(MAX_DELIVERIES));
+      
+      int maxRedeliveryAttempts =
+         ((Integer)ServerManagement.getAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts")).intValue();
+      
+      assertEquals(MAX_DELIVERIES, maxRedeliveryAttempts);
+      
+      try
+      {
+         conn = cf.createConnection();
+
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageProducer prod = sess.createProducer(queue);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("Message:" + i);
+
+            prod.send(tm);
+         }
+
+         MessageConsumer cons = sess.createConsumer(queue);
+         
+         FailingMessageListener listener  = new FailingMessageListener();
+
+         cons.setMessageListener(listener);
+
+         conn.start();
+
+         Thread.sleep(4000);
+
+         cons.setMessageListener(null);
+         
+         assertEquals(MAX_DELIVERIES * NUM_MESSAGES, listener.deliveryCount);
+
+         Message m = cons.receive(1000);
+
+         assertNull(m);
+
+         //Message should all be in the dlq - let's check
+
+         MessageConsumer cons2 = sess.createConsumer(dlq);
+
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+
+            assertNotNull(tm);
+
+            assertEquals("Message:" + i, tm.getText());
+         }
+
+      }
+      finally
+      {
+         ServerManagement.undeployQueue("DLQ");
+
+         if (conn != null) conn.close();
+      }
+   }
+   
+
+   public void testWithReceiveClientAck(boolean persistent) throws Exception
+   {
+      Connection conn = null;
+
+      ServerManagement.deployQueue("DLQ");
+
+      Queue dlq = (Queue)ic.lookup("/queue/DLQ");
+      
+      drainDestination(cf, dlq);
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+      
+      final int MAX_DELIVERIES = 16;
+      
+      final int NUM_MESSAGES = 5;      
+         
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts", String.valueOf(MAX_DELIVERIES));
+      
+      int maxRedeliveryAttempts =
+         ((Integer)ServerManagement.getAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts")).intValue();
+      
+      assertEquals(MAX_DELIVERIES, maxRedeliveryAttempts);
+
+      try
+      {
+         conn = cf.createConnection();
+
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageProducer prod = sess.createProducer(queue);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+    
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("Message:" + i);
+
+            prod.send(tm);
+         }
+
+         Session sess2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+
+         MessageConsumer cons = sess2.createConsumer(queue);
+
+         conn.start();
+
+         for (int i = 0; i < MAX_DELIVERIES; i++) 
+         {
+            for (int j = 0; j < NUM_MESSAGES; j++)
+            {
+               TextMessage tm = (TextMessage)cons.receive(1000);
+
+               assertNotNull(tm);
+
+               assertEquals("Message:" + j, tm.getText());
+            }
+
+            sess2.recover();
+         }
+         
+         //At this point all the messages have been delivered exactly MAX_DELIVERIES times - this is ok
+         //they haven't exceeded max delivery attempts so shouldn't be in the DLQ - let's check
+         
+         MessageConsumer cons3 = sess.createConsumer(dlq);
+         
+         Message m = cons3.receive(1000);
+         
+         assertNull(m);
+         
+         //So let's try and consume them - this should cause them to go to the DLQ - since they will then exceed max
+         //delivery attempts
+         
+         m = cons.receive(1000);
+         
+         assertNull(m);
+         
+         //Now, all the messages should now be in the DLQ
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+            
+            assertNotNull(tm);
+
+            assertEquals("Message:" + i, tm.getText());
+         }
+
+         //No more should be available
+         
+         m = cons.receive(1000);
+         
+         assertNull(m);
+         
+         cons.close();
+
+         MessageConsumer cons2 = sess2.createConsumer(queue);
+
+         m = cons2.receive(1000);
+
+         assertNull(m);
+      }
+      finally
+      {
+         ServerManagement.undeployQueue("DLQ");
+
+         if (conn != null) conn.close();
+      }
+   }
+   
+   public void testWithReceiveTransactional(boolean persistent) throws Exception
+   {
+      Connection conn = null;
+
+      ServerManagement.deployQueue("DLQ");
+
+      Queue dlq = (Queue)ic.lookup("/queue/DLQ");
+      
+      drainDestination(cf, dlq);
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+      
+      final int MAX_DELIVERIES = 16;
+      
+      final int NUM_MESSAGES = 5;      
+        
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts", String.valueOf(MAX_DELIVERIES));
+      
+      int maxRedeliveryAttempts =
+         ((Integer)ServerManagement.getAttribute(serverPeerObjectName, "DefaultMaxDeliveryAttempts")).intValue();
+      
+      assertEquals(MAX_DELIVERIES, maxRedeliveryAttempts);
+
+      try
+      {
+         conn = cf.createConnection();
+
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageProducer prod = sess.createProducer(queue);
+
+         prod.setDeliveryMode(persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT);
+    
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("Message:" + i);
+
+            prod.send(tm);
+         }
+
+         Session sess2 = conn.createSession(true, Session.SESSION_TRANSACTED);
+
+         MessageConsumer cons = sess2.createConsumer(queue);
+
+         conn.start();
+
+         for (int i = 0; i < MAX_DELIVERIES; i++) 
+         {
+            for (int j = 0; j < NUM_MESSAGES; j++)
+            {
+               TextMessage tm = (TextMessage)cons.receive(1000);
+
+               assertNotNull(tm);
+
+               assertEquals("Message:" + j, tm.getText());
+            }
+
+            sess2.rollback();
+         }
+         
+         //At this point all the messages have been delivered exactly MAX_DELIVERIES times - this is ok
+         //they haven't exceeded max delivery attempts so shouldn't be in the DLQ - let's check
+         
+         MessageConsumer cons3 = sess.createConsumer(dlq);
+         
+         Message m = cons3.receive(1000);
+         
+         assertNull(m);
+         
+         //So let's try and consume them - this should cause them to go to the DLQ - since they will then exceed max
+         //delivery attempts
+         m = cons.receive(1000);
+         
+         assertNull(m);
+         
+         //All the messages should now be in the DLQ
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons3.receive(1000);
+            
+            assertNotNull(tm);
+
+            assertEquals("Message:" + i, tm.getText());
+         }
+
+         //No more should be available
+         
+         m = cons.receive(1000);
+         
+         assertNull(m);
+         
+         cons.close();
+
+         MessageConsumer cons2 = sess2.createConsumer(queue);
+
+         m = cons2.receive(1000);
+
+         assertNull(m);
+      }
+      finally
+      {
+         ServerManagement.undeployQueue("DLQ");
+
+         if (conn != null) conn.close();
+      }
+   }
+
+      
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------
@@ -439,9 +700,12 @@
    
    class FailingMessageListener implements MessageListener
    {
+      volatile int deliveryCount;
 
       public void onMessage(Message msg)
       {
+         deliveryCount++;
+         
          throw new RuntimeException("Your mum!");
       }
       

Added: trunk/tests/src/org/jboss/test/messaging/jms/ExpiryQueueTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/ExpiryQueueTest.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/tests/src/org/jboss/test/messaging/jms/ExpiryQueueTest.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -0,0 +1,631 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.test.messaging.jms;
+
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.jms.DeliveryMode;
+import javax.jms.Message;
+import javax.jms.MessageConsumer;
+import javax.jms.MessageListener;
+import javax.jms.MessageProducer;
+import javax.jms.Queue;
+import javax.jms.Session;
+import javax.jms.TextMessage;
+import javax.jms.Topic;
+import javax.management.ObjectName;
+import javax.naming.InitialContext;
+import javax.naming.NameNotFoundException;
+
+import org.jboss.jms.destination.JBossQueue;
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+/**
+ * 
+ * A ExpiryQueueTest
+ *
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ *
+ */
+public class ExpiryQueueTest extends MessagingTestCase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   protected InitialContext ic;
+   protected ConnectionFactory cf;
+   protected Queue queue;
+   protected Topic topic;
+
+   // Constructors --------------------------------------------------
+
+   public ExpiryQueueTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testExpiryQueueAlreadyDeployed() throws Exception
+   {
+      if (ServerManagement.isRemote())
+      {
+         return;
+      }
+      ServerManagement.deployQueue("ExpiryQueue");
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+      
+      ObjectName expiryQueueObjectName = (ObjectName)ServerManagement.getAttribute(serverPeerObjectName, "DefaultExpiryQueue");
+      
+      assertNotNull(expiryQueueObjectName);
+            
+      String name = (String)ServerManagement.getAttribute(expiryQueueObjectName, "Name");
+      
+      assertNotNull(name);
+      
+      assertEquals("ExpiryQueue", name);
+
+      String jndiName = (String)ServerManagement.getAttribute(expiryQueueObjectName, "JNDIName");
+      
+      assertNotNull(jndiName);
+      
+      assertEquals("/queue/ExpiryQueue", jndiName);
+      
+      org.jboss.messaging.core.Queue expiryQueue = ServerManagement.getServer().getServerPeer().getDefaultExpiryQueueInstance();
+
+      assertNotNull(expiryQueue);
+
+      InitialContext ic = null;
+
+      try
+      {
+         ic = new InitialContext(ServerManagement.getJNDIEnvironment());
+
+         JBossQueue q = (JBossQueue)ic.lookup("/queue/ExpiryQueue");
+
+         assertNotNull(q);
+
+         assertEquals("ExpiryQueue", q.getName());
+      }
+      finally
+      {
+         if (ic != null) ic.close();
+
+         ServerManagement.undeployQueue("ExpiryQueue");
+
+      }
+   }
+
+   public void testExpiryQueueNotAlreadyDeployed() throws Exception
+   {
+      if (ServerManagement.isRemote())
+      {
+         return;
+      }
+      
+      org.jboss.messaging.core.Queue expiryQueue = ServerManagement.getServer().getServerPeer().getDefaultExpiryQueueInstance();
+
+      assertNull(expiryQueue);
+
+      InitialContext ic = null;
+
+      try
+      {
+         ic = new InitialContext(ServerManagement.getJNDIEnvironment());
+
+         try
+         {
+            ic.lookup("/queue/ExpiryQueue");
+
+            fail();
+         }
+         catch (NameNotFoundException e)
+         {
+            //Ok
+         }
+      }
+      finally
+      {
+         if (ic != null) ic.close();
+      }
+   }
+   
+   public void testDefaultAndOverrideExpiryQueue() throws Exception
+   {
+      final int NUM_MESSAGES = 5;
+      
+      ServerManagement.deployQueue("DefaultExpiry");
+      
+      ServerManagement.deployQueue("OverrideExpiry");
+      
+      ServerManagement.deployQueue("TestQueue");
+      
+      String defaultExpiryObjectName = "jboss.messaging.destination:service=Queue,name=DefaultExpiry";
+      
+      String overrideExpiryObjectName = "jboss.messaging.destination:service=Queue,name=OverrideExpiry";
+      
+      String testQueueObjectName = "jboss.messaging.destination:service=Queue,name=TestQueue";
+      
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+          
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultExpiryQueue", defaultExpiryObjectName);
+      
+      ServerManagement.setAttribute(new ObjectName(testQueueObjectName), "ExpiryQueue", "");
+      
+      Queue testQueue = (Queue)ic.lookup("/queue/TestQueue");
+      
+      Queue defaultExpiry = (Queue)ic.lookup("/queue/DefaultExpiry");
+      
+      Queue overrideExpiry = (Queue)ic.lookup("/queue/OverrideExpiry");
+      
+      drainDestination(cf, testQueue);
+            
+      drainDestination(cf, defaultExpiry);
+            
+      drainDestination(cf, overrideExpiry);
+            
+      Connection conn = null;
+      
+      try
+      {      
+         conn = cf.createConnection();
+         
+         {         
+            Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+            MessageProducer prod = sess.createProducer(testQueue);
+            
+            conn.start();
+   
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = sess.createTextMessage("Message:" + i);
+   
+               //Send messages with time to live of 2000 enough time to get to client consumer - so 
+               //they won't be expired on the server side
+               prod.send(tm, DeliveryMode.PERSISTENT, 4, 2000);
+            }
+            
+            Session sess2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+                        
+            MessageConsumer cons = sess2.createConsumer(testQueue);
+            
+            //The messages should now be sitting in the consumer buffer
+            
+            //Now give them enough time to expire
+            
+            Thread.sleep(2500);
+            
+            //Now try and receive
+            
+            Message m = cons.receive(1000);
+
+            assertNull(m);
+
+            //Message should all be in the default expiry queue - let's check
+                        
+            MessageConsumer cons3 = sess.createConsumer(defaultExpiry);
+            
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = (TextMessage)cons3.receive(1000);
+   
+               assertNotNull(tm);
+   
+               assertEquals("Message:" + i, tm.getText());
+            }
+            
+            conn.close();
+         }
+         
+         
+         //now try with overriding the default expiry queue
+         {         
+            ServerManagement.setAttribute(new ObjectName(testQueueObjectName), "ExpiryQueue", overrideExpiryObjectName);
+            
+            conn = cf.createConnection();
+            
+            Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+            MessageProducer prod = sess.createProducer(testQueue);
+            
+            conn.start();
+   
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = sess.createTextMessage("Message:" + i);
+   
+               //Send messages with time to live of 2000 enough time to get to client consumer - so 
+               //they won't be expired on the server side
+               prod.send(tm, DeliveryMode.PERSISTENT, 4, 2000);
+            }
+            
+            Session sess2 = conn.createSession(false, Session.CLIENT_ACKNOWLEDGE);
+                        
+            MessageConsumer cons = sess2.createConsumer(testQueue);
+            
+            //The messages should now be sitting in the consumer buffer
+            
+            //Now give them enough time to expire
+            
+            Thread.sleep(2500);
+            
+            //Now try and receive
+            
+            Message m = cons.receive(1000);
+
+            assertNull(m);
+
+            //Message should all be in the default expiry queue - let's check
+                        
+            MessageConsumer cons3 = sess.createConsumer(defaultExpiry);
+            
+            for (int i = 0; i < NUM_MESSAGES; i++)
+            {
+               TextMessage tm = (TextMessage)cons3.receive(1000);
+   
+               assertNotNull(tm);
+   
+               assertEquals("Message:" + i, tm.getText());
+            }
+         }
+      }
+      finally
+      {
+         ServerManagement.setAttribute(serverPeerObjectName, "DefaultExpiryQueue", "jboss.messaging.destination:service=Queue,name=ExpiryQueue");
+                  
+         ServerManagement.undeployQueue("DefaultDLQ");
+         
+         ServerManagement.undeployQueue("OverrideDLQ");
+         
+         ServerManagement.undeployQueue("TestQueue");
+         
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+   
+   public void testExpireSameMessagesMultiple() throws Exception
+   {
+      final int NUM_MESSAGES = 5;
+      
+      ServerManagement.deployQueue("ExpiryQueue");
+      
+      String defaultExpiryObjectName = "jboss.messaging.destination:service=Queue,name=ExpiryQueue";
+         
+      ObjectName serverPeerObjectName = ServerManagement.getServerPeerObjectName();
+          
+      ServerManagement.setAttribute(serverPeerObjectName, "DefaultExpiryQueue", defaultExpiryObjectName);
+       
+      Queue defaultExpiry = (Queue)ic.lookup("/queue/ExpiryQueue");
+      
+      drainDestination(cf, defaultExpiry);
+                  
+      Connection conn = null;
+      
+      try
+      {      
+         conn = cf.createConnection();
+         
+         conn.setClientID("wib1");
+                        
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+   
+         MessageProducer prod = sess.createProducer(topic);
+            
+         conn.start();
+         
+         //Create 3 durable subscriptions
+         
+         MessageConsumer sub1 = sess.createDurableSubscriber(topic, "sub1");
+         
+         MessageConsumer sub2 = sess.createDurableSubscriber(topic, "sub2");
+         
+         MessageConsumer sub3 = sess.createDurableSubscriber(topic, "sub3");
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("Message:" + i);
+
+            //Send messages with time to live of 3000 enough time to get to client consumer - so 
+            //they won't be expired on the server side
+            prod.send(tm, DeliveryMode.PERSISTENT, 4, 3000);
+         }
+         
+         //Now sleep. This wil give them enough time to expire
+         
+         Thread.sleep(3500);
+         
+         //Now try and consume from each - this should force the message to the expiry queue
+         
+         Message m = sub1.receive(500);
+         assertNull(m);
+         
+         m = sub2.receive(500);
+         assertNull(m);
+         
+         m = sub3.receive(500);
+         assertNull(m);
+         
+         //Now the messages should all be in the expiry queue
+         
+         MessageConsumer cons2 = sess.createConsumer(defaultExpiry);
+         
+         while (true)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(500);
+            
+            if (tm == null)
+            {
+               break;
+            }
+            
+            log.info("Got message: " + tm.getText());
+         }
+            
+      }
+      finally
+      {        
+         ServerManagement.undeployQueue("ExpiryQueue");
+         
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+
+   public void testWithMessageListenerPersistent() throws Exception
+   {
+      testWithMessageListener(true);
+   }
+
+   public void testWithMessageListenerNonPersistent() throws Exception
+   {
+      testWithMessageListener(false);
+   }
+
+   public void testWithReceivePersistent() throws Exception
+   {
+      this.testWithReceive(true);
+   }
+
+   public void testWithReceiveNonPersistent() throws Exception
+   {
+      testWithReceive(false);
+   }   
+
+   public void testWithMessageListener(boolean persistent) throws Exception
+   {
+      Connection conn = null;
+
+      ServerManagement.deployQueue("ExpiryQueue");
+
+      Queue expiryQueue = (Queue)ic.lookup("/queue/ExpiryQueue");
+      
+      drainDestination(cf, expiryQueue);
+       
+      final int NUM_MESSAGES = 5;
+
+      try
+      {
+         conn = cf.createConnection();
+         
+         conn.start();
+
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageProducer prod = sess.createProducer(queue);
+
+         int deliveryMode = persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("Message:" + i);
+                        
+            //Send messages with time to live of 2000 enough time to get to client consumer - so 
+            //they won't be expired on the server side
+            prod.send(tm, deliveryMode, 4, 2000);
+         }
+
+         MessageConsumer cons = sess.createConsumer(queue);
+         
+         //The messages should now be sitting in the consumer buffer
+         
+         //Now give them enough time to expire
+         
+         Thread.sleep(2500);
+         
+         //Now set a listener
+         
+         FailingMessageListener listener  = new FailingMessageListener();
+
+         cons.setMessageListener(listener);
+         
+         Thread.sleep(1000);
+
+         cons.setMessageListener(null);
+         
+         //No messages should have been received
+         assertEquals(0, listener.deliveryCount);
+                  
+         //Shouldn't be able to receive any more
+         
+         Message m = cons.receive(1000);
+
+         assertNull(m);
+
+         //Message should all be in the expiry queue - let's check
+         
+         MessageConsumer cons2 = sess.createConsumer(expiryQueue);
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+            
+            assertNotNull(tm);
+
+            assertEquals("Message:" + i, tm.getText());
+         }
+
+      }
+      finally
+      {
+         ServerManagement.undeployQueue("ExpiryQueue");
+
+         if (conn != null) conn.close();
+      }
+   }
+   
+   public void testWithReceive(boolean persistent) throws Exception
+   {
+      Connection conn = null;
+
+      ServerManagement.deployQueue("ExpiryQueue");
+
+      Queue expiryQueue = (Queue)ic.lookup("/queue/ExpiryQueue");
+      
+      drainDestination(cf, expiryQueue);
+       
+      final int NUM_MESSAGES = 5;
+
+      try
+      {
+         conn = cf.createConnection();
+         
+         conn.start();
+
+         Session sess = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         MessageProducer prod = sess.createProducer(queue);
+
+         int deliveryMode = persistent ? DeliveryMode.PERSISTENT : DeliveryMode.NON_PERSISTENT;
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = sess.createTextMessage("Message:" + i);
+                        
+            //Send messages with time to live of 2000 enough time to get to client consumer - so 
+            //they won't be expired on the server side
+            prod.send(tm, deliveryMode, 4, 2000);
+         }
+
+         MessageConsumer cons = sess.createConsumer(queue);
+         
+         //The messages should now be sitting in the consumer buffer
+         
+         //Now give them enough time to expire
+         
+         Thread.sleep(2500);
+         
+         //Now try and receive
+         
+         Message m = cons.receive(1000);
+
+         assertNull(m);
+
+         //Message should all be in the expiry queue - let's check
+         
+         MessageConsumer cons2 = sess.createConsumer(expiryQueue);
+         
+         for (int i = 0; i < NUM_MESSAGES; i++)
+         {
+            TextMessage tm = (TextMessage)cons2.receive(1000);
+            
+            assertNotNull(tm);
+
+            assertEquals("Message:" + i, tm.getText());
+         }
+
+      }
+      finally
+      {
+         ServerManagement.undeployQueue("ExpiryQueue");
+
+         if (conn != null) conn.close();
+      }
+   }
+
+      
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      ServerManagement.start("all");
+
+      ic = new InitialContext(ServerManagement.getJNDIEnvironment());
+
+      cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+
+      ServerManagement.deployQueue("Queue");
+      
+      ServerManagement.deployTopic("Topic");
+
+      queue = (Queue)ic.lookup("/queue/Queue");
+      
+      topic = (Topic)ic.lookup("/topic/Topic");
+
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+
+      ServerManagement.undeployQueue("Queue");
+      
+      ServerManagement.undeployTopic("Topic");
+
+      if (ic != null) ic.close();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+   
+   class FailingMessageListener implements MessageListener
+   {
+      volatile int deliveryCount;
+
+      public void onMessage(Message msg)
+      {
+         deliveryCount++;
+         
+         throw new RuntimeException("Your mum!");
+      }
+      
+   }
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/tests/src/org/jboss/test/messaging/jms/MessageConsumerTest.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -3055,6 +3055,7 @@
       Session sess1 = consumerConnection.createSession(false, Session.CLIENT_ACKNOWLEDGE);
       MessageConsumer cons1 = sess1.createConsumer(queue);
       TextMessage tm2 = (TextMessage)cons1.receive(3000);
+      
       assertNotNull(tm2);
       assertEquals("testRedeliveredDifferentSessions", tm2.getText());
 
@@ -3064,6 +3065,7 @@
       Session sess2 = consumerConnection.createSession(false, Session.CLIENT_ACKNOWLEDGE);
       MessageConsumer cons2 = sess2.createConsumer(queue);
       TextMessage tm3 = (TextMessage)cons2.receive(3000);
+      
       assertNotNull(tm3);
       assertEquals("testRedeliveredDifferentSessions", tm3.getText());
       

Modified: trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-30 08:02:32 UTC (rev 1878)
+++ trunk/tests/src/org/jboss/test/messaging/jms/WireFormatTest.java	2006-12-31 09:49:46 UTC (rev 1879)
@@ -486,7 +486,7 @@
          
          int deliveryCount = 12;
          
-         Cancel cancel = new DefaultCancel(deliveryID, deliveryCount);
+         Cancel cancel = new DefaultCancel(deliveryID, deliveryCount, true, true);
          
          Object[] args = new Object[] { cancel };
          
@@ -530,9 +530,17 @@
          //Then delivery count
          int count = dis.readInt();
          
+         boolean expired = dis.readBoolean();
+         
+         boolean reachedMaxDeliveries = dis.readBoolean();
+         
          assertEquals(deliveryID, l);
          
          assertEquals(deliveryCount, count);
+         
+         assertEquals(expired, true);
+         
+         assertEquals(reachedMaxDeliveries, true);
 
          //Now eos
          try
@@ -567,6 +575,10 @@
          
          assertEquals(deliveryCount, l2.getDeliveryCount());
          
+         assertEquals(expired, l2.isExpired());
+         
+         assertEquals(reachedMaxDeliveries, l2.isReachedMaxDeliveryAttempts());
+         
       }
       
       public void testCancelDeliveries() throws Exception
@@ -577,8 +589,8 @@
          
          List cancels = new ArrayList();
          
-         DefaultCancel cancel1 = new DefaultCancel(65654, 43);
-         DefaultCancel cancel2 = new DefaultCancel(65765, 2);
+         DefaultCancel cancel1 = new DefaultCancel(65654, 43, true, false);
+         DefaultCancel cancel2 = new DefaultCancel(65765, 2, false, true);
          cancels.add(cancel1);
          cancels.add(cancel2);
          
@@ -629,19 +641,31 @@
          //then the AckInfos
          long deliveryId = dis.readLong();
          int deliveryCount = dis.readInt();
-         DefaultCancel rcancel1 = new DefaultCancel(deliveryId, deliveryCount);
+         boolean expired = dis.readBoolean();
+         boolean reachedMaxDeliveries = dis.readBoolean();
+         DefaultCancel rcancel1 = new DefaultCancel(deliveryId, deliveryCount, expired, reachedMaxDeliveries);
          
          deliveryId = dis.readLong();
          deliveryCount = dis.readInt();
-         DefaultCancel rcancel2 = new DefaultCancel(deliveryId, deliveryCount);
+         expired = dis.readBoolean();
+         reachedMaxDeliveries = dis.readBoolean();
+         DefaultCancel rcancel2 = new DefaultCancel(deliveryId, deliveryCount, expired, reachedMaxDeliveries);
 
          assertEquals(cancel1.getDeliveryCount(), rcancel1.getDeliveryCount());
          
          assertEquals(cancel1.getDeliveryId(), cancel1.getDeliveryId());
          
+         assertEquals(cancel1.isExpired(), cancel1.isExpired());
+         
+         assertEquals(cancel1.isReachedMaxDeliveryAttempts(), cancel1.isReachedMaxDeliveryAttempts());
+         
          assertEquals(cancel2.getDeliveryCount(), rcancel2.getDeliveryCount());
          
          assertEquals(cancel2.getDeliveryId(), cancel2.getDeliveryId());
+         
+         assertEquals(cancel2.isExpired(), cancel2.isExpired());
+         
+         assertEquals(cancel2.isReachedMaxDeliveryAttempts(), cancel2.isReachedMaxDeliveryAttempts());
                    
          //should be eos
                 



From jboss-cvs-commits at lists.jboss.org  Sun Dec 31 05:52:07 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 31 Dec 2006 05:52:07 -0500
Subject: [jboss-cvs] JBoss Messaging SVN: r1880 - in trunk: . src/etc
	src/main/org/jboss/jms src/main/org/jboss/jms/client
	src/main/org/jboss/jms/client/container
	src/main/org/jboss/jms/client/delegate
	src/main/org/jboss/jms/client/remoting
	src/main/org/jboss/jms/client/state
	src/main/org/jboss/jms/delegate src/main/org/jboss/jms/server
	src/main/org/jboss/jms/server/connectionfactory
	src/main/org/jboss/jms/server/endpoint
	src/main/org/jboss/jms/server/endpoint/advised
	src/main/org/jboss/jms/server/remoting src/main/org/jboss/jms/tx
	src/main/org/jboss/messaging/core/tx tests
	tests/src/org/jboss/test/messaging/jms
	tests/src/org/jboss/test/messaging/jms/clustering
	tests/src/org/jboss/test/messaging/jms/clustering/base
	tests/src/org/jboss/test/messaging/tools
	tests/src/org/jboss/test/messaging/tools/jmx
Message-ID: <E1H0yIR-0002KB-Cs@committer01.frg.pub.inap.atl.jboss.com>

Author: ovidiu.feodorov at jboss.com
Date: 2006-12-31 05:51:38 -0500 (Sun, 31 Dec 2006)
New Revision: 1880

Added:
   trunk/src/main/org/jboss/jms/client/ClientAOPStackLoader.java
   trunk/src/main/org/jboss/jms/client/ClientAOPStackProvider.java
   trunk/src/main/org/jboss/jms/client/FailoverEvent.java
   trunk/src/main/org/jboss/jms/client/FailoverListener.java
   trunk/src/main/org/jboss/jms/client/Valve.java
   trunk/src/main/org/jboss/jms/client/container/ClusteringAspect.java
   trunk/src/main/org/jboss/jms/client/container/ConnectionFailureListener.java
   trunk/src/main/org/jboss/jms/client/container/FailoverAspect.java
   trunk/src/main/org/jboss/jms/client/container/FailoverValveInterceptor.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientClusteredConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/Initializable.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ClientAOPStackProviderAdvised.java
   trunk/tests/src/org/jboss/test/messaging/jms/AOPStackInitializationTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/FailoverValveTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/LoadBalancingTest.java
Removed:
   trunk/src/main/org/jboss/jms/client/container/HAAspect.java
   trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/perf/
Modified:
   trunk/messaging.ipr
   trunk/src/etc/aop-messaging-client.xml
   trunk/src/etc/prepare-aop.xml
   trunk/src/main/org/jboss/jms/client/JBossConnection.java
   trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java
   trunk/src/main/org/jboss/jms/client/JBossMessageProducer.java
   trunk/src/main/org/jboss/jms/client/JBossQueueBrowser.java
   trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java
   trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
   trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
   trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
   trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientBrowserDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientProducerDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
   trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
   trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
   trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java
   trunk/src/main/org/jboss/jms/client/state/BrowserState.java
   trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
   trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
   trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java
   trunk/src/main/org/jboss/jms/client/state/HierarchicalStateSupport.java
   trunk/src/main/org/jboss/jms/client/state/ProducerState.java
   trunk/src/main/org/jboss/jms/client/state/SessionState.java
   trunk/src/main/org/jboss/jms/delegate/BrowserDelegate.java
   trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java
   trunk/src/main/org/jboss/jms/delegate/ConnectionFactoryDelegate.java
   trunk/src/main/org/jboss/jms/delegate/ConsumerDelegate.java
   trunk/src/main/org/jboss/jms/delegate/ProducerDelegate.java
   trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
   trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java
   trunk/src/main/org/jboss/jms/server/ServerPeer.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
   trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
   trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
   trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
   trunk/src/main/org/jboss/jms/server/remoting/JMSDispatcher.java
   trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
   trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
   trunk/tests/build.xml
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
   trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
   trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
   trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
Log:
1. The clustering/failover support has been refactored as follows:

There is a new PER_INSTANCE ClusteringAspect  part of ClusteredConnectionFactory's stack, 
which encapsulates load balancing and failover node picking policies. Each client-side 
delegate is guarded by a PER_INSTANCE FailoverValveInterceptor instance. The valve is 
normally open. On failover, all valves under a connection are closed recursively. If there 
are active threads through valve on closing, the current behavior is that closeValve() 
waits until all active threads unwrap (I could change this if necessary). Once the valve 
is closed, no threads are allowed through it until is explicitly opened again. 
The client-side failover event (which includes operating the valves, among other things) 
is detected and controlled by PER_VM FailoverAspect.

2. ClientClusteredConnectionFactoryDelegate doesn't extend ClientConnectionFactoryDelegate
 anymore. Also, I introduced two distinct aspect stacks corresponding to clustered 
ConnectionFactories and non-clustered ConnectionFactories.

3. One can register a FailoverListener to a JBossConnection and so to be notified when 
a failover starts and ends. So far, known events are FAILURE_DETECTED, FAILOVER_STARTED, 
FAILOVER_COMPLETED, FAILOVER_FAILED.

4. The initialization of the AOP stack is done by a specialized component 
(ClientAOPStackLoader). Both ConnectionDelegate and ClusteredConnectionDelegate delegate 
to it. getAOPStackConfig() is not part of the ConnectionFactory interface anymore.


Modified: trunk/messaging.ipr
===================================================================
--- trunk/messaging.ipr	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/messaging.ipr	2006-12-31 10:51:38 UTC (rev 1880)
@@ -234,7 +234,9 @@
         <root url="jar://$PROJECT_DIR$/thirdparty/jboss/aop/lib/jboss-aop.jar!/" />
       </CLASSES>
       <JAVADOC />
-      <SOURCES />
+      <SOURCES>
+        <root url="file://C:/work/src/jboss-aop_1.5.0.GA/src/aspect-framework/main" />
+      </SOURCES>
     </library>
     <library name="jboss-remoting">
       <CLASSES>

Modified: trunk/src/etc/aop-messaging-client.xml
===================================================================
--- trunk/src/etc/aop-messaging-client.xml	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/etc/aop-messaging-client.xml	2006-12-31 10:51:38 UTC (rev 1880)
@@ -8,6 +8,7 @@
    <interceptor class="org.jboss.jms.client.container.ClientLogInterceptor" scope="PER_VM"/>
    <interceptor class="org.jboss.jms.client.container.ClosedInterceptor" scope="PER_INSTANCE"/>                  	
    <interceptor class="org.jboss.jms.client.container.ConcurrencyInterceptor" scope="PER_INSTANCE"/>
+   <interceptor class="org.jboss.jms.client.container.FailoverValveInterceptor" scope="PER_INSTANCE"/>
 
    <aspect class="org.jboss.jms.client.container.StateCreationAspect" scope="PER_VM"/>
    <aspect class="org.jboss.jms.client.container.ConsumerAspect" scope="PER_VM"/>
@@ -16,24 +17,45 @@
    <aspect class="org.jboss.jms.client.container.AsfAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.BrowserAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.ConnectionAspect" scope="PER_INSTANCE"/>
-   <aspect class="org.jboss.jms.client.container.HAAspect" scope="PER_INSTANCE"/>
+   <aspect class="org.jboss.jms.client.container.ClusteringAspect" scope="PER_INSTANCE"/>
    <aspect class="org.jboss.jms.client.container.FactoryAspect" scope="PER_INSTANCE"/>
+   <aspect class="org.jboss.jms.client.container.FailoverAspect" scope="PER_VM"/>
 
-   <!-- ConnectionFactory Stack-->        
+   <!--
+       Clustered ConnectionFactory Stack
+   -->
+
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate->$implementing{org.jboss.jms.delegate.ConnectionFactoryDelegate}(..))">
+      <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
+      <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>
+   </bind>
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate->createConnectionDelegate(..))">
+      <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.ClusteringAspect"/>
+   </bind>
+
+   <!--
+        (Non-clustered) ConnectionFactory Stack
+   -->
+
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->$implementing{org.jboss.jms.delegate.ConnectionFactoryDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>
    </bind>   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
       <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
-   </bind>  
-   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->createConnectionDelegate(..))">
-      <advice name="handleCreateConnectionDelegate" aspect="org.jboss.jms.client.container.HAAspect"/>
    </bind>
-               
-   <!-- Connection Stack -->   
+
+   <!--
+        Connection Stack
+   -->
+
+   <!-- It is important that FailoverAspect intercepts performFailover() before FailoverValveInterceptor -->
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->performFailover())">
+      <advice name="handlePerformFailover" aspect="org.jboss.jms.client.container.FailoverAspect"/>
+   </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->$implementing{org.jboss.jms.delegate.ConnectionDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
+      <interceptor-ref name="org.jboss.jms.client.container.FailoverValveInterceptor"/>
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>      
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>               
    </bind>  
@@ -66,15 +88,24 @@
    </bind>         
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->close())">
       <advice name="handleClose" aspect="org.jboss.jms.client.container.ConnectionAspect"/>
-   </bind>   
+   </bind>
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->registerFailoverListener(..))">
+      <advice name="handleRegisterFailoverListener" aspect="org.jboss.jms.client.container.ConnectionAspect"/>
+   </bind>
+   <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->unregisterFailoverListener(..))">
+      <advice name="handleUnregisterFailoverListener" aspect="org.jboss.jms.client.container.ConnectionAspect"/>
+   </bind>
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->createSessionDelegate(..))">
       <advice name="handleCreateSessionDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
    </bind>
-    
 
-   <!-- Session Stack -->   
+   <!--
+        Session Stack
+   -->
+
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->$implementing{org.jboss.jms.delegate.SessionDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
+      <interceptor-ref name="org.jboss.jms.client.container.FailoverValveInterceptor"/>
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>      
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>       
    </bind>
@@ -166,9 +197,13 @@
       <advice name="handleCreateBrowserDelegate" aspect="org.jboss.jms.client.container.StateCreationAspect"/>
    </bind>
    
-   <!-- Consumer Stack -->   
+   <!--
+        Consumer Stack
+   -->
+
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientConsumerDelegate->$implementing{org.jboss.jms.delegate.ConsumerDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
+      <interceptor-ref name="org.jboss.jms.client.container.FailoverValveInterceptor"/>
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>      
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>          
    </bind>       
@@ -198,9 +233,12 @@
    </bind>   
 
    
-   <!-- Producer Stack -->   
+   <!--
+        Producer Stack
+   -->   
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientProducerDelegate->$implementing{org.jboss.jms.delegate.ProducerDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
+      <interceptor-ref name="org.jboss.jms.client.container.FailoverValveInterceptor"/>
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>      
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>  
    </bind>        
@@ -250,10 +288,12 @@
       <advice name="handleClose" aspect="org.jboss.jms.client.container.ProducerAspect"/>
    </bind>     
 
-   
-   <!-- Browser Stack -->   
+   <!--
+        Browser Stack
+   -->
    <bind pointcut="execution(* org.jboss.jms.client.delegate.ClientBrowserDelegate->$implementing{org.jboss.jms.delegate.BrowserDelegate}(..))">
       <interceptor-ref name="org.jboss.jms.client.container.ClientLogInterceptor"/>
+      <interceptor-ref name="org.jboss.jms.client.container.FailoverValveInterceptor"/>
       <interceptor-ref name="org.jboss.jms.client.container.ExceptionInterceptor"/>      
       <interceptor-ref name="org.jboss.jms.client.container.ClosedInterceptor"/>
    </bind>      

Modified: trunk/src/etc/prepare-aop.xml
===================================================================
--- trunk/src/etc/prepare-aop.xml	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/etc/prepare-aop.xml	2006-12-31 10:51:38 UTC (rev 1880)
@@ -6,6 +6,7 @@
 <aop>
 
   <!-- Prepare the client stub classes - these provide the client side advice stack -->
+  <prepare expr="execution(* org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate->$implementing{org.jboss.jms.delegate.ConnectionFactoryDelegate}(..))"/>
   <prepare expr="execution(* org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate->$implementing{org.jboss.jms.delegate.ConnectionFactoryDelegate}(..))"/>
   <prepare expr="execution(* org.jboss.jms.client.delegate.ClientConnectionDelegate->$implementing{org.jboss.jms.delegate.ConnectionDelegate}(..))"/>
   <prepare expr="execution(* org.jboss.jms.client.delegate.ClientSessionDelegate->$implementing{org.jboss.jms.delegate.SessionDelegate}(..))"/>
@@ -14,6 +15,7 @@
   <prepare expr="execution(* org.jboss.jms.client.delegate.ClientBrowserDelegate->$implementing{org.jboss.jms.delegate.BrowserDelegate}(..))"/>
  
   <!-- Prepare the server delegate classes - these provide the server side advice stack -->
+  <prepare expr="execution(* org.jboss.jms.server.endpoint.advised.ClientAOPStackProviderAdvised->$implementing{org.jboss.jms.client.ClientAOPStackProvider}(..))"/>
   <prepare expr="execution(* org.jboss.jms.server.endpoint.advised.ConnectionFactoryAdvised->$implementing{org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint}(..))"/>
   <prepare expr="execution(* org.jboss.jms.server.endpoint.advised.ConnectionAdvised->$implementing{org.jboss.jms.server.endpoint.ConnectionEndpoint}(..))"/>
   <prepare expr="execution(* org.jboss.jms.server.endpoint.advised.SessionAdvised->$implementing{org.jboss.jms.server.endpoint.SessionEndpoint}(..))"/> 

Added: trunk/src/main/org/jboss/jms/client/ClientAOPStackLoader.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/ClientAOPStackLoader.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/ClientAOPStackLoader.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,80 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client;
+
+import org.jboss.jms.client.container.JmsClientAspectXMLLoader;
+
+/**
+ * A static singleton that insures the client-side AOP stack is loaded.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class ClientAOPStackLoader
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   public static ClientAOPStackLoader getInstance()
+   {
+      synchronized(ClientAOPStackLoader.class)
+      {
+         if (instance == null)
+         {
+            instance = new ClientAOPStackLoader();
+         }
+         return instance;
+      }
+   }
+
+   // Attributes ----------------------------------------------------
+
+   private static ClientAOPStackLoader instance;
+
+   private boolean loaded;
+
+   // Constructors --------------------------------------------------
+
+   private ClientAOPStackLoader()
+   {
+      loaded = false;
+   }
+
+   // Public --------------------------------------------------------
+
+   /**
+    * @param delegate - either an instance of ClientClusteredConnectionFactoryDelegate or
+    *        ClientConnectionFactoryDelegate.
+    *
+    * @throws Exception - if something goes wrong with downloading the AOP configuration from the
+    *         server and installing it.
+    */
+   public synchronized void load(ClientAOPStackProvider delegate) throws Exception
+   {
+      if (loaded)
+      {
+         return;
+      }
+
+      byte[] clientAOPStack = delegate.getClientAOPStack();
+
+      new JmsClientAspectXMLLoader().deployXML(clientAOPStack);
+
+      loaded = true;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+}

Added: trunk/src/main/org/jboss/jms/client/ClientAOPStackProvider.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/ClientAOPStackProvider.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/ClientAOPStackProvider.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,23 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client;
+
+/**
+ * An interface implemented by an object that can provide a client-side AOP stack configuration.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public interface ClientAOPStackProvider
+{
+   /**
+    * @return the AOP stack as byte[]. Use JmsClientAspectXMLLoader to deploy it on the client.
+    */
+   byte[] getClientAOPStack();
+}

Added: trunk/src/main/org/jboss/jms/client/FailoverEvent.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/FailoverEvent.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/FailoverEvent.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,74 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client;
+
+import java.util.EventObject;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class FailoverEvent extends EventObject
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   public static final int FAILURE_DETECTED = 10;
+   public static final int FAILOVER_STARTED = 20;
+   public static final int FAILOVER_COMPLETED = 30;
+   public static final int FAILOVER_FAILED = 100;
+
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   private int type;
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   public FailoverEvent(int type, Object source)
+   {
+      super(source);
+      checkType(type);
+      this.type = type;
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public int getType()
+   {
+      return type;
+   }
+
+   public String toString()
+   {
+      return
+         type == FAILURE_DETECTED ? "FAILURE_DETECTED" :
+            type == FAILOVER_STARTED ? "FAILOVER_STARTED" :
+               type == FAILOVER_COMPLETED ? "FAILOVER_COMPLETED" :
+                  type == FAILOVER_FAILED ? "FAILOVER_FAILED" : "UNKNOWN_FAILOVER_EVENT";
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   private void checkType(int type) throws IllegalArgumentException
+   {
+      if (type != FAILURE_DETECTED &&
+         type != FAILOVER_STARTED &&
+         type != FAILOVER_COMPLETED &&
+         type != FAILOVER_FAILED)
+      {
+         throw new IllegalArgumentException("Illegal failover event type: " + type);
+      }
+   }
+
+   // Inner classes --------------------------------------------------------------------------------
+}

Added: trunk/src/main/org/jboss/jms/client/FailoverListener.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/FailoverListener.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/FailoverListener.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,18 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client;
+
+/**
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public interface FailoverListener
+{
+   void failoverEventOccured(FailoverEvent event);
+}

Modified: trunk/src/main/org/jboss/jms/client/JBossConnection.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnection.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/JBossConnection.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -45,12 +45,11 @@
 import javax.jms.XATopicSession;
 
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.remoting.JMSRemotingConnection;
+import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.util.ThreadContextClassLoaderChanger;
-import org.jboss.logging.Logger;
 
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -64,24 +63,21 @@
     XAConnection, XAQueueConnection, XATopicConnection, Serializable
 {
 
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
    private static final long serialVersionUID = -3715868654823177898L;
    
-   private static final Logger log = Logger.getLogger(JBossConnection.class);
-   
-
    static final int TYPE_GENERIC_CONNECTION = 0;
    static final int TYPE_QUEUE_CONNECTION = 1;
    static final int TYPE_TOPIC_CONNECTION = 2;
 
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
    protected ConnectionDelegate delegate;
    private int connectionType;
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
    public JBossConnection(ConnectionDelegate delegate, int connectionType)
    {
@@ -89,7 +85,7 @@
       this.connectionType = connectionType;
    }
 
-   // Connection implementation -------------------------------------
+   // Connection implementation --------------------------------------------------------------------
 
    public Session createSession(boolean transacted, int acknowledgeMode) throws JMSException
    {
@@ -158,11 +154,11 @@
          String msg = "Cannot create a durable connection consumer on a QueueConnection";
          throw new IllegalStateException(msg);
       }
-      return delegate.
-         createConnectionConsumer(topic, subscriptionName, messageSelector, sessionPool, maxMessages);
+      return delegate.createConnectionConsumer(topic, subscriptionName, messageSelector,
+                                               sessionPool, maxMessages);
    }
 
-   // QueueConnection implementation ---------------------------------
+   // QueueConnection implementation ---------------------------------------------------------------
 
    public QueueSession createQueueSession(boolean transacted,
                                           int acknowledgeMode) throws JMSException
@@ -175,10 +171,11 @@
                                                       ServerSessionPool sessionPool,
                                                       int maxMessages) throws JMSException
     {
-      return delegate.createConnectionConsumer(queue, null, messageSelector, sessionPool, maxMessages);
+      return delegate.
+         createConnectionConsumer(queue, null, messageSelector, sessionPool, maxMessages);
     }
 
-   // TopicConnection implementation ---------------------------------
+   // TopicConnection implementation ---------------------------------------------------------------
 
    public TopicSession createTopicSession(boolean transacted,
                                           int acknowledgeMode) throws JMSException
@@ -191,10 +188,11 @@
                                                       ServerSessionPool sessionPool,
                                                       int maxMessages) throws JMSException
    {
-      return delegate.createConnectionConsumer(topic, null, messageSelector, sessionPool, maxMessages);
+      return delegate.
+         createConnectionConsumer(topic, null, messageSelector, sessionPool, maxMessages);
    }
 
-   // XAConnection implementation -------------------------------------
+   // XAConnection implementation ------------------------------------------------------------------
 
    public XASession createXASession() throws JMSException
    {
@@ -202,7 +200,7 @@
                                     JBossSession.TYPE_GENERIC_SESSION);
    }
 
-   // XAQueueConnection implementation ---------------------------------
+   // XAQueueConnection implementation -------------------------------------------------------------
 
    public XAQueueSession createXAQueueSession() throws JMSException
    {
@@ -211,7 +209,7 @@
 
    }
 
-   // XATopicConnection implementation ---------------------------------
+   // XATopicConnection implementation -------------------------------------------------------------
 
    public XATopicSession createXATopicSession() throws JMSException
    {
@@ -220,13 +218,8 @@
 
    }
 
-   // Public --------------------------------------------------------
+   // Public ---------------------------------------------------------------------------------------
 
-   public String toString()
-   {
-      return "JBossConnection->" + delegate;
-   }
-
    public String getRemotingClientSessionId()
    {
       ConnectionState state = (ConnectionState)((ClientConnectionDelegate)delegate).getState();
@@ -239,10 +232,33 @@
       return delegate;
    }
 
-   // Package protected ---------------------------------------------
+   /**
+    * Convenience method.
+    */
+   public int getServerID()
+   {
+      return ((ConnectionState)((DelegateSupport)delegate).getState()).getServerID();
+   }
 
-   // Protected -----------------------------------------------------
+   public void registerFailoverListener(FailoverListener listener)
+   {
+      delegate.registerFailoverListener(listener);
+   }
 
+   public synchronized boolean unregisterFailoverListener(FailoverListener listener)
+   {
+      return delegate.unregisterFailoverListener(listener);
+   }
+
+   public String toString()
+   {
+      return "JBossConnection->" + delegate;
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
    protected JBossSession createSessionInternal(boolean transacted, int acknowledgeMode,
                                                 boolean isXA, int type) throws JMSException
    {
@@ -283,7 +299,7 @@
 //      }
 //   }
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   // Inner classes -------------------------------------------------
+   // Inner classes --------------------------------------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/JBossConnectionFactory.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -39,13 +39,11 @@
 import javax.naming.NamingException;
 import javax.naming.Reference;
 
-import org.jboss.aop.Advised;
-import org.jboss.jms.client.container.JmsClientAspectXMLLoader;
-import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
 import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.referenceable.SerializableObjectRefAddr;
 import org.jboss.jms.server.endpoint.CreateConnectionResult;
 import org.jboss.jms.util.ThreadContextClassLoaderChanger;
+import org.jboss.jms.client.delegate.Initializable;
 import org.jboss.logging.Logger;
 
 /**
@@ -56,35 +54,30 @@
  * $Id$
  */
 public class JBossConnectionFactory implements
-               ConnectionFactory, QueueConnectionFactory, TopicConnectionFactory,
-               XAConnectionFactory, XAQueueConnectionFactory, XATopicConnectionFactory,
-               Serializable/*, Referenceable http://jira.jboss.org/jira/browse/JBMESSAGING-395*/
+   ConnectionFactory, QueueConnectionFactory, TopicConnectionFactory,
+   XAConnectionFactory, XAQueueConnectionFactory, XATopicConnectionFactory,
+   Serializable/*, Referenceable http://jira.jboss.org/jira/browse/JBMESSAGING-395*/
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
    
    private final static long serialVersionUID = -2810634789345348326L;
    
    private static final Logger log = Logger.getLogger(JBossConnectionFactory.class);
+
+   // Static ---------------------------------------------------------------------------------------
    
+   // Attributes -----------------------------------------------------------------------------------
    
-   // Static --------------------------------------------------------
-   
-   private static boolean configLoaded;
-   
-   // Attributes ----------------------------------------------------
-   
    protected ConnectionFactoryDelegate delegate;
+
+   // Constructors ---------------------------------------------------------------------------------
    
-   private boolean initialised;
-   
-   // Constructors --------------------------------------------------
-   
    public JBossConnectionFactory(ConnectionFactoryDelegate delegate)
    {
       this.delegate = delegate;      
    }
    
-   // ConnectionFactory implementation ------------------------------
+   // ConnectionFactory implementation -------------------------------------------------------------
    
    public Connection createConnection() throws JMSException
    {
@@ -93,34 +86,39 @@
    
    public Connection createConnection(String username, String password) throws JMSException
    {
-      return createConnectionInternal(username, password, false, JBossConnection.TYPE_GENERIC_CONNECTION);
+      return createConnectionInternal(username, password, false,
+                                      JBossConnection.TYPE_GENERIC_CONNECTION);
    }
    
-   // QueueConnectionFactory implementation -------------------------
+   // QueueConnectionFactory implementation --------------------------------------------------------
    
    public QueueConnection createQueueConnection() throws JMSException
    {
       return createQueueConnection(null, null);
    }
    
-   public QueueConnection createQueueConnection(String username, String password) throws JMSException
+   public QueueConnection createQueueConnection(String username, String password)
+      throws JMSException
    {
-      return createConnectionInternal(username, password, false, JBossConnection.TYPE_QUEUE_CONNECTION);
+      return createConnectionInternal(username, password, false,
+                                      JBossConnection.TYPE_QUEUE_CONNECTION);
    }
    
-   // TopicConnectionFactory implementation -------------------------
+   // TopicConnectionFactory implementation --------------------------------------------------------
    
    public TopicConnection createTopicConnection() throws JMSException
    {
       return createTopicConnection(null, null);
    }
    
-   public TopicConnection createTopicConnection(String username, String password) throws JMSException
+   public TopicConnection createTopicConnection(String username, String password)
+      throws JMSException
    {
-      return createConnectionInternal(username, password, false, JBossConnection.TYPE_TOPIC_CONNECTION);
+      return createConnectionInternal(username, password, false,
+                                      JBossConnection.TYPE_TOPIC_CONNECTION);
    }
    
-   // XAConnectionFactory implementation ------------------------------
+   // XAConnectionFactory implementation -----------------------------------------------------------
    
    public XAConnection createXAConnection() throws JMSException
    {
@@ -129,34 +127,39 @@
    
    public XAConnection createXAConnection(String username, String password) throws JMSException
    {
-      return createConnectionInternal(username, password, true, JBossConnection.TYPE_GENERIC_CONNECTION);   
+      return createConnectionInternal(username, password, true,
+                                      JBossConnection.TYPE_GENERIC_CONNECTION);
    }
    
-   // XAQueueConnectionFactory implementation -------------------------
+   // XAQueueConnectionFactory implementation ------------------------------------------------------
    
    public XAQueueConnection createXAQueueConnection() throws JMSException
    {
       return createXAQueueConnection(null, null);
    }
    
-   public XAQueueConnection createXAQueueConnection(String username, String password) throws JMSException
+   public XAQueueConnection createXAQueueConnection(String username, String password)
+      throws JMSException
    {
-      return createConnectionInternal(username, password, true, JBossConnection.TYPE_QUEUE_CONNECTION);   
+      return createConnectionInternal(username, password, true,
+                                      JBossConnection.TYPE_QUEUE_CONNECTION);
    }
    
-   // XATopicConnectionFactory implementation -------------------------
+   // XATopicConnectionFactory implementation ------------------------------------------------------
    
    public XATopicConnection createXATopicConnection() throws JMSException
    {
       return createXATopicConnection(null, null);
    }
    
-   public XATopicConnection createXATopicConnection(String username, String password) throws JMSException
+   public XATopicConnection createXATopicConnection(String username, String password)
+      throws JMSException
    {
-      return createConnectionInternal(username, password, true, JBossConnection.TYPE_TOPIC_CONNECTION);   
+      return createConnectionInternal(username, password, true,
+                                      JBossConnection.TYPE_TOPIC_CONNECTION);
    }
    
-   // Referenceable implementation ---------------------------------------
+   // Referenceable implementation -----------------------------------------------------------------
    
    public Reference getReference() throws NamingException
    {
@@ -166,7 +169,7 @@
                null);
    }
    
-   // Public --------------------------------------------------------
+   // Public ---------------------------------------------------------------------------------------
    
    public String toString()
    {
@@ -178,24 +181,34 @@
       return delegate;
    }
    
-   // Package protected ---------------------------------------------
+   // Package protected ----------------------------------------------------------------------------
    
-   // Protected -----------------------------------------------------
+   // Protected ------------------------------------------------------------------------------------
    
    protected JBossConnection createConnectionInternal(String username, String password,
-            boolean isXA, int type)
+                                                      boolean isXA, int type)
       throws JMSException
    {
-      
       ThreadContextClassLoaderChanger tccc = new ThreadContextClassLoaderChanger();
       
       try
       {
          tccc.set(getClass().getClassLoader());
-         
-         ensureAOPConfigLoaded((ClientConnectionFactoryDelegate)delegate);
-         initDelegate();
-         
+
+         try
+         {
+            ClientAOPStackLoader.getInstance().load(delegate);
+         }
+         catch(Exception e)
+         {
+            // Need to log message since no guarantee that client will log it
+            final String msg = "Failed to download and/or install client side AOP stack";
+            log.error(msg, e);
+            throw new RuntimeException(msg, e);
+         }
+
+         ((Initializable)delegate).init();
+
          // The version used by the connection is the minimum of the server version for the
          // connection factory and the client code version
          
@@ -209,50 +222,7 @@
       }
    }
    
-   protected synchronized void initDelegate()
-   {
-      if (!initialised)
-      {
-         ((ClientConnectionFactoryDelegate)delegate).init();
-         initialised = true;
-      }         
-   }
-   
-   protected void ensureAOPConfigLoaded(ClientConnectionFactoryDelegate delegate)
-   {
-      try
-      {
-         synchronized (JBossConnectionFactory.class)
-         {
-            if (!configLoaded)
-            {
-               // Load the client side aspect stack configuration from the server and apply it
-               
-               delegate.init();
-               
-               byte[] clientAOPConfig = delegate.getClientAOPConfig();
-               
-               // Remove interceptor since we don't want it on the front of the stack
-               ((Advised)delegate)._getInstanceAdvisor().removeInterceptor(delegate.getName());
-               
-               JmsClientAspectXMLLoader loader = new JmsClientAspectXMLLoader();
-               
-               loader.deployXML(clientAOPConfig);
-               
-               configLoaded = true;               
-            }
-         }   
-      }
-      catch(Exception e)
-      {
-         // Need to log message since no guarantee that client will log it
-         final String msg = "Failed to config client side AOP";
-         log.error(msg, e);
-         throw new RuntimeException(msg, e);
-      }
-   }
-   
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
       
-   // Inner classes -------------------------------------------------
+   // Inner classes --------------------------------------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/client/JBossMessageProducer.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossMessageProducer.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/JBossMessageProducer.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -45,7 +45,7 @@
  *
  * $Id$
  */
-class JBossMessageProducer implements MessageProducer, QueueSender, TopicPublisher, Serializable
+public class JBossMessageProducer implements MessageProducer, QueueSender, TopicPublisher, Serializable
 {
    // Constants -----------------------------------------------------
    
@@ -226,6 +226,11 @@
    
    // Public --------------------------------------------------------
 
+   public ProducerDelegate getDelegate()
+   {
+      return delegate;
+   }
+
    public String toString()
    {
       return "JBossMessageProducer->" + delegate;

Modified: trunk/src/main/org/jboss/jms/client/JBossQueueBrowser.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/JBossQueueBrowser.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/JBossQueueBrowser.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -35,7 +35,7 @@
  *
  * $Id$
  */
-class JBossQueueBrowser implements QueueBrowser, Serializable
+public class JBossQueueBrowser implements QueueBrowser, Serializable
 {
    // Constants -----------------------------------------------------
 
@@ -90,6 +90,11 @@
       return "JBossQueueBrowser->" + delegate;
    }
 
+   public BrowserDelegate getDelegate()
+   {
+      return delegate;
+   }
+
    // Package protected ---------------------------------------------
 
    // Protected -----------------------------------------------------

Added: trunk/src/main/org/jboss/jms/client/Valve.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/Valve.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/Valve.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,38 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client;
+
+/**
+ * An interface that controls the permeability of implementing objects.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public interface Valve
+{
+   /**
+    * "Closes" the valve. The implementing object becomes impermeable. Did't go for "close()" to
+    * avoid name conflicts with Closeable.close().
+    */
+   void closeValve() throws Exception;
+
+   /**
+    * "Opens" the valve. The implementing object becomes permeable. Didn't go for "open()" for
+    * symmetry reasons.
+    */
+   void openValve() throws Exception;
+
+   boolean isValveOpen();
+
+   /**
+    * @return the number of threads currenty "penetrating" the open valve. Shold be 0 if the valve
+    *         is closed.
+    */
+   int getActiveThreadsCount();
+
+}

Modified: trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ClosedInterceptor.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -126,7 +126,7 @@
          id = DelegateIdentity.getIdentity(invocation);
       }
 
-      String methodName = ((MethodInvocation) invocation).getMethod().getName();
+      String methodName = ((MethodInvocation)invocation).getMethod().getName();
 
       if ("isClosed".equals(methodName))
       {

Added: trunk/src/main/org/jboss/jms/client/container/ClusteringAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ClusteringAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ClusteringAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,254 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.container;
+
+import org.jboss.logging.Logger;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
+
+import javax.jms.JMSException;
+import java.util.Map;
+
+/**
+ * This aspect is part of a clustered ConnectionFactory aspect stack.
+ * Some of its responsibilities are:
+ *
+ * - To choose the next node to create a physical connection to, based on a pluggable load balancing
+ *   policy.
+ * - To handle physical connection creation (by delegating it to a non-clustered ConnectionFactory
+ *   delegate) and instal failure listeners.
+ * - etc.
+ *
+ * It's a PER_INSTANCE aspect (one of these per each clustered ConnectionFactory instance)
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ *
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class ClusteringAspect
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(ClusteringAspect.class);
+
+   public static final int MAX_RECONNECT_HOP_COUNT = 10;
+
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   // This is a PER_INSTANCE aspect, so it has a 1-to-1 relationship with its delegate
+   private ClientClusteredConnectionFactoryDelegate clusteredDelegate;
+
+   // The index of the next non-clustered delegate to be used. Only access it from a synchronized
+   // block. Currently hardcoded round-robin, the algorithm must be made pluggable.
+   private int next;
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   public ClusteringAspect()
+   {
+      next = 0;
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public CreateConnectionResult handleCreateConnectionDelegate(Invocation invocation)
+      throws Throwable
+   {
+      // initalize this PER_INSTANCE aspect by getting a hold of its corresponding clustered
+      // delegate and maintaining a reference to it
+      if (clusteredDelegate == null)
+      {
+         clusteredDelegate = (ClientClusteredConnectionFactoryDelegate)invocation.getTargetObject();
+      }
+
+      // the method handles both the case of a first connection creation attempt and a re-try during
+      // a client-side failover. The difference is given by the failedNodeID (-1 for first attempt)
+
+      MethodInvocation mi = (MethodInvocation)invocation;
+      String username = (String)mi.getArguments()[0];
+      String password = (String)mi.getArguments()[1];
+      Integer failedNodeID = (Integer)mi.getArguments()[2];
+
+      // We attempt to connect to the next node in a loop, since we might need to go through
+      // multiple hops
+
+      int attemptCount = 0;
+      ClientConnectionFactoryDelegate delegate = null;
+
+      while (attemptCount < MAX_RECONNECT_HOP_COUNT)
+      {
+         if (delegate == null)
+         {
+            if (failedNodeID != null && failedNodeID.intValue() >= 0)
+            {
+               delegate = getFailoverDelegateForNode(failedNodeID);
+            }
+            else
+            {
+               delegate = getNextRoundRobinDelegate();
+            }
+         }
+
+         log.debug(this + " has chosen " + delegate + " as target, " +
+            (attemptCount == 0 ? "first connection attempt" : attemptCount + " connection attempts"));
+
+         CreateConnectionResult res = delegate.createConnectionDelegate(username, password, -1); // TODO get rid of -1 from signature
+         ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
+
+         if (cd != null)
+         {
+            // valid connection
+
+            log.debug(this + " got local connection delegate " + cd);
+
+            ConnectionState state = (ConnectionState)((DelegateSupport)cd).getState();
+
+            // add a connection listener to detect failure; the consolidated remoting connection
+            // listener must be already in place and configured
+            state.getRemotingConnectionListener().
+               addDelegateListener(new ConnectionFailureListener(cd));
+
+            log.debug(this + " installed failure listener on " + cd);
+
+            // also cache the username and the password into state, useful in case FailoverAspect
+            // needs to create a new connection instead of a failed on
+            state.setUsername(username);
+            state.setPassword(password);
+
+            // also add a reference to the clustered ConnectionFactory delegate, useful in case
+            // FailoverAspect needs to create a new connection instead of a failed on
+            state.setClusteredConnectionFactoryDeleage(clusteredDelegate);
+
+            return new CreateConnectionResult(cd);
+         }
+         else
+         {
+            // we did not get a valid connection to the node we've just tried
+
+            int actualServerID = res.getActualFailoverNodeID();
+
+            if (actualServerID == -1)
+            {
+               // No failover attempt was detected on the server side; this might happen if the
+               // client side network fails temporarily so the client connection breaks but the
+               // server cluster is still up and running - in this case we don't perform failover.
+
+               // TODO Is this the right thing to do?
+
+               log.warn("Client attempted failover, but no failover attempt " +
+                        "has been detected on the server side.");
+
+               return null;
+            }
+
+            // Server side failover has occurred / is occurring but trying to go to the 'default'
+            // failover node did not succeed. Retry with the node suggested by the cluster.
+
+            attemptCount++;
+
+            delegate = getDelegateForNode(actualServerID);
+
+            if (delegate == null)
+            {
+               // the delegate corresponding to the actualServerID not found among the cached
+               // delegates. TODO Could this ever happen? Should we send back the cf, or update it
+               // instead of just the id??
+               throw new JMSException("Cannot find a cached connection factory delegate for " +
+                  "node " + actualServerID);
+            }
+         }
+      }
+
+      throw new JMSException("Maximum number of failover attempts exceeded. " +
+                             "Cannot find a server to failover onto.");
+   }
+
+   public String toString()
+   {
+      return "ClusteringAspect[" + clusteredDelegate + "]";
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+
+   /**
+    * TODO This is currently hardcoded as round robin. The policy should be pluggable.
+    */
+   private synchronized ClientConnectionFactoryDelegate getNextRoundRobinDelegate()
+   {
+      ClientConnectionFactoryDelegate[] delegates = clusteredDelegate.getDelegates();
+
+      if (next >= delegates.length)
+      {
+         next = 0;
+      }
+
+      ClientConnectionFactoryDelegate delegate = delegates[next++];
+
+         if (next >= delegates.length)
+         {
+            next = 0;
+         }
+
+      return delegate;
+   }
+
+   private synchronized ClientConnectionFactoryDelegate getFailoverDelegateForNode(Integer nodeID)
+   {
+      ClientConnectionFactoryDelegate[] delegates = clusteredDelegate.getDelegates();
+
+      if (nodeID.intValue() < 0)
+      {
+         throw new IllegalArgumentException("nodeID must be 0 or positive");
+      }
+
+      Map failoverMap = clusteredDelegate.getFailoverMap();
+      Integer failoverNodeID = (Integer)failoverMap.get(nodeID);
+
+      for (int i = 0; i < delegates.length; i++)
+      {
+         if (delegates[i].getServerID() == failoverNodeID.intValue())
+         {
+            return delegates[i];
+         }
+      }
+
+      return null;
+   }
+
+   private synchronized ClientConnectionFactoryDelegate getDelegateForNode(int nodeID)
+   {
+      ClientConnectionFactoryDelegate[] delegates = clusteredDelegate.getDelegates();
+
+      for (int i = 0; i < delegates.length; i++)
+      {
+         if (delegates[i].getServerID() == nodeID)
+         {
+            return delegates[i];
+         }
+      }
+
+      return null;
+   }
+
+   // Inner classes --------------------------------------------------------------------------------
+
+}

Modified: trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -27,6 +27,7 @@
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.jms.client.JBossConnectionMetaData;
+import org.jboss.jms.client.FailoverListener;
 import org.jboss.jms.client.remoting.ConsolidatedRemotingConnectionListener;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
@@ -193,6 +194,30 @@
       return ret;
    }
 
+   public Object  handleRegisterFailoverListener(Invocation invocation) throws Throwable
+   {
+      ConnectionState state = getConnectionState(invocation);
+
+      MethodInvocation mi = (MethodInvocation)invocation;
+      FailoverListener listener = (FailoverListener)mi.getArguments()[0];
+
+      state.registerFailoverListener(listener);
+
+      return null;
+   }
+
+   public Object handleUnregisterFailoverListener(Invocation invocation) throws Throwable
+   {
+      ConnectionState state = getConnectionState(invocation);
+
+      MethodInvocation mi = (MethodInvocation)invocation;
+      FailoverListener listener = (FailoverListener)mi.getArguments()[0];
+
+      boolean result = state.unregisterFailoverListener(listener);
+
+      return new Boolean(result);
+   }
+
    public String toString()
    {
       StringBuffer sb = new StringBuffer("ConnectionAspect[");

Added: trunk/src/main/org/jboss/jms/client/container/ConnectionFailureListener.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConnectionFailureListener.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ConnectionFailureListener.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,80 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.container;
+
+import org.jboss.remoting.ConnectionListener;
+import org.jboss.remoting.Client;
+import org.jboss.logging.Logger;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.FailoverEvent;
+import org.jboss.jms.client.state.ConnectionState;
+
+/**
+ * The listener that detects a connection failure and initiates the failover process. Each physical
+ * connection created under the supervision of ClusteredAspect has one of these.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public class ConnectionFailureListener implements ConnectionListener
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(ConnectionFailureListener.class);
+
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   private ClientConnectionDelegate cd;
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   ConnectionFailureListener(ClientConnectionDelegate cd)
+   {
+      this.cd = cd;
+   }
+
+   // ConnectionListener implementation ------------------------------------------------------------
+
+   public void handleConnectionException(Throwable throwable, Client client)
+   {
+      try
+      {
+         log.debug(this + " is being notified of connection failure: " + throwable);
+
+         // generate a FAILURE_DETECTED event
+         ((ConnectionState)cd.getState()).
+            broadcastFailoverEvent(new FailoverEvent(FailoverEvent.FAILURE_DETECTED, cd));
+
+         log.debug(this + " initiating client-side failover");
+
+         cd.performFailover();
+      }
+      catch (Throwable e)
+      {
+         log.error("Caught exception in handling failure", e);
+      }
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public String toString()
+   {
+      return "ConnectionFailureListener[" + cd + "]";
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   // Inner classes --------------------------------------------------------------------------------
+}

Modified: trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ConsumerAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -33,8 +33,6 @@
 import org.jboss.jms.client.state.SessionState;
 import org.jboss.jms.delegate.ConsumerDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
-import org.jboss.jms.server.endpoint.ServerSessionEndpoint;
-import org.jboss.logging.Logger;
 
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
@@ -54,8 +52,6 @@
 {
    // Constants -----------------------------------------------------
    
-   private static final Logger log = Logger.getLogger(ConsumerAspect.class);
-   
    // Static --------------------------------------------------------
 
    // Attributes ----------------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ExceptionInterceptor.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -76,7 +76,7 @@
       }
       catch (Throwable t)
       {
-         //We log everything else
+         // We log everything else
          
          log(t);
          

Added: trunk/src/main/org/jboss/jms/client/container/FailoverAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/FailoverAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/FailoverAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,119 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.container;
+
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.client.FailoverEvent;
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
+import org.jboss.jms.delegate.ConnectionFactoryDelegate;
+import org.jboss.logging.Logger;
+
+/**
+ * PER_VM Aspect.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class FailoverAspect
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(FailoverAspect.class);
+
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public Object handlePerformFailover(Invocation invocation) throws Throwable
+   {
+      Object target = invocation.getTargetObject();
+
+      if(target instanceof ClientConnectionDelegate)
+      {
+         performConnectionFailover((ClientConnectionDelegate)target);
+      }
+
+      return null;
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   private void performConnectionFailover(ClientConnectionDelegate delegate) throws Exception
+   {
+      ConnectionState state = (ConnectionState)delegate.getState();
+
+      CreateConnectionResult res = null;
+      boolean failoverSuccessful = false;
+
+      try
+      {
+         // block any other invocations ariving while we're doing failover, on this delegate and
+         // recursively down the hierarchy
+
+         // WARNING - this may block if there are active invocations through valves!
+         delegate.closeValve();
+
+         log.debug("starting client-side failover");
+
+         // generate a FAILOVER_STARTED event. The event must be broadcasted AFTER valve closure,
+         // to insure the client-side stack is in a deterministic state
+         state.broadcastFailoverEvent(new FailoverEvent(FailoverEvent.FAILOVER_STARTED, delegate));
+
+         int failedNodeID = state.getServerID();
+         ConnectionFactoryDelegate clusteredDelegate =
+            state.getClusteredConnectionFactoryDelegate();
+
+         // re-try creating the connection
+         res = clusteredDelegate.
+            createConnectionDelegate(state.getUsername(), state.getPassword(), failedNodeID);
+
+         if (res == null)
+         {
+            // No failover attempt was detected on the server side; this might happen if the
+            // client side network fails temporarily so the client connection breaks but the
+            // server cluster is still up and running - in this case we don't perform failover.
+            failoverSuccessful = false;
+         }
+         else
+         {
+            // recursively synchronize state
+            ClientConnectionDelegate newDelegate = (ClientConnectionDelegate)res.getDelegate();
+            delegate.synchronizeWith(newDelegate);
+            failoverSuccessful = true;
+         }
+      }
+      finally
+      {
+         if (failoverSuccessful)
+         {
+            state.broadcastFailoverEvent(new FailoverEvent(FailoverEvent.FAILOVER_COMPLETED,
+                                                           res.getDelegate()));
+         }
+         else
+         {
+            state.broadcastFailoverEvent(new FailoverEvent(FailoverEvent.FAILOVER_FAILED,
+                                                           delegate));
+         }
+
+         // failover done, open valves
+         delegate.openValve();
+      }
+   }
+
+   // Inner classes --------------------------------------------------------------------------------
+}

Added: trunk/src/main/org/jboss/jms/client/container/FailoverValveInterceptor.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/FailoverValveInterceptor.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/FailoverValveInterceptor.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,229 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.container;
+
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.logging.Logger;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.state.HierarchicalState;
+import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.WriterPreferenceReadWriteLock;
+import EDU.oswego.cs.dl.util.concurrent.Sync;
+
+import java.util.List;
+import java.util.ArrayList;
+
+/**
+ * An interceptor that acts as a failover valve: it allows all invocations to go through as long
+ * as there is no failover in progress (valve is open), and holds all invocations while client-side
+ * failover is taking place (valve is closed). The interceptor fields org.jboss.jms.client.Valve's
+ * method calls.
+ *
+ * It is a PER_INSTANCE interceptor.
+ *
+ * An instance of this interceptor must guard access to each connection, session, producer, consumer
+ * and queue browser delegate.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ * $Id$
+ */
+public class FailoverValveInterceptor implements Interceptor
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   private static final Logger log = Logger.getLogger(FailoverValveInterceptor.class);
+
+   // Static ---------------------------------------------------------------------------------------
+
+   private static boolean trace = log.isTraceEnabled();
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   private DelegateSupport delegate;
+   private HierarchicalState state;
+   private volatile boolean valveOpen;
+
+   private ReadWriteLock rwLock;
+
+   // the number of threads currently "penetrating" the open valve
+   private int activeThreadsCount;
+
+   // only for tracing
+   private List activeMethods;
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   public FailoverValveInterceptor()
+   {
+      valveOpen = true;
+      activeThreadsCount = 0;
+      rwLock = new WriterPreferenceReadWriteLock();
+      if (trace)
+      {
+         activeMethods = new ArrayList();
+      }
+   }
+
+   // Interceptor implemenation --------------------------------------------------------------------
+
+   public String getName()
+   {
+      return "FailoverValveInterceptor";
+   }
+
+   public Object invoke(Invocation invocation) throws Throwable
+   {
+      // maintain a reference to the delegate that sends invocation through this interceptor. It
+      // makes sense, since it's an PER_INSTANCE interceptor.
+      if (delegate == null)
+      {
+         delegate = (DelegateSupport)invocation.getTargetObject();
+         state = delegate.getState();
+      }
+
+      String methodName = ((MethodInvocation)invocation).getMethod().getName();
+      Sync writeLock =  rwLock.writeLock();
+      Sync readLock = rwLock.readLock();
+
+      if("closeValve".equals(methodName))
+      {
+         if (!valveOpen)
+         {
+            // valve already closed, this is a noop
+            log.warn(this + " already closed!");
+            return null;
+         }
+
+         state.closeChildrensValves();
+
+         boolean acquired = false;
+
+         while(!acquired)
+         {
+            try
+            {
+               acquired = writeLock.attempt(500);
+            }
+            catch(InterruptedException e)
+            {
+               // OK
+            }
+
+            if (!acquired)
+            {
+               log.debug(this + " failed to close");
+            }
+         }
+
+         valveOpen = false;
+
+         log.debug(this + " has been closed");
+
+         return null;
+      }
+      else if("openValve".equals(methodName))
+      {
+         if (valveOpen)
+         {
+            // valve already open, this is a noop
+            log.warn(this + " already open!");
+            return null;
+         }
+
+         state.openChildrensValves();
+
+         writeLock.release();
+         valveOpen = true;
+
+         log.debug(this + " has been opened");
+
+         return null;
+      }
+      else if("isValveOpen".equals(methodName))
+      {
+         if (valveOpen)
+         {
+            return Boolean.TRUE;
+         }
+         else
+         {
+            return Boolean.FALSE;
+         }
+      }
+      else if("getActiveThreadsCount".equals(methodName))
+      {
+         return new Integer(activeThreadsCount);
+      }
+
+      // attempt to grab the reader's lock and go forward
+
+      try
+      {
+         boolean acquired = false;
+
+         while(!acquired)
+         {
+            try
+            {
+               acquired = readLock.attempt(500);
+            }
+            catch(InterruptedException e)
+            {
+               // OK
+            }
+
+            if (trace && !acquired ) { log.trace(methodName + "() trying to pass through " + this); }
+         }
+
+         synchronized(this)
+         {
+            activeThreadsCount++;
+            if (trace)
+            {
+               activeMethods.add(methodName);
+            }
+         }
+
+         if(trace) { log.trace(this + " has let " + methodName + "() pass through"); }
+
+         return invocation.invokeNext();
+      }
+      finally
+      {
+         readLock.release();
+         synchronized(this)
+         {
+            activeThreadsCount--;
+            if (trace)
+            {
+               activeMethods.remove(methodName);
+            }
+         }
+      }
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public String toString()
+   {
+      return "FailoverValve." +
+         (delegate == null ? "UNITIALIZED" : delegate.toString()) +
+         (valveOpen ? "[OPEN(" + activeThreadsCount +
+            (trace ? " " + activeMethods.toString() : "") + ")]":"[CLOSED]");
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   // Inner classes --------------------------------------------------------------------------------
+}

Deleted: trunk/src/main/org/jboss/jms/client/container/HAAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/HAAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -1,700 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.jms.client.container;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Map;
-
-import javax.jms.JMSException;
-import javax.jms.Session;
-
-import org.jboss.aop.Advised;
-import org.jboss.aop.advice.Interceptor;
-import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.aop.joinpoint.MethodInvocation;
-import org.jboss.jms.client.delegate.ClientBrowserDelegate;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.ClientConsumerDelegate;
-import org.jboss.jms.client.delegate.ClientProducerDelegate;
-import org.jboss.jms.client.delegate.ClientSessionDelegate;
-import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.remoting.CallbackManager;
-import org.jboss.jms.client.remoting.MessageCallbackHandler;
-import org.jboss.jms.client.state.BrowserState;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.client.state.ConsumerState;
-import org.jboss.jms.client.state.HierarchicalStateSupport;
-import org.jboss.jms.client.state.ProducerState;
-import org.jboss.jms.client.state.SessionState;
-import org.jboss.jms.delegate.SessionDelegate;
-import org.jboss.jms.destination.JBossDestination;
-import org.jboss.jms.server.endpoint.CreateConnectionResult;
-import org.jboss.jms.server.endpoint.DeliveryInfo;
-import org.jboss.jms.server.endpoint.DeliveryRecovery;
-import org.jboss.jms.tx.ResourceManager;
-import org.jboss.jms.tx.ResourceManagerFactory;
-import org.jboss.logging.Logger;
-import org.jboss.remoting.Client;
-import org.jboss.remoting.ConnectionListener;
-
-/**
- *
- * A HAAspect
- *
- * There is one of these PER_INSTANCE of connection factory
- *
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
- *
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- */
-public class HAAspect
-{
-   // Constants -----------------------------------------------------
-
-   private static final Logger log = Logger.getLogger(HAAspect.class);
-
-   public static final int MAX_RECONNECT_HOP_COUNT = 10;
-
-   public static final int MAX_IO_RETRY_COUNT = 2;
-
-   // Setting this attribute to false will disable the valve
-   public static final boolean INSTALL_VALVE = true;
-
-   // Static --------------------------------------------------------
-
-   private static boolean trace = log.isTraceEnabled();
-
-   // Attributes ----------------------------------------------------
-
-   private ClientConnectionFactoryDelegate[] delegates;
-
-   private Map failoverMap;
-
-   private int currentRobinIndex;
-
-   // The identity of the delegate this interceptor is associated with
-   private DelegateIdentity id;
-
-   // Constructors --------------------------------------------------
-
-   public HAAspect()
-   {
-      id = null;
-   }
-
-   /** A Copy Constructor Used on creationg of ValveAspect */
-   protected HAAspect(HAAspect copyFrom)
-   {
-      this.delegates = copyFrom.delegates;
-      this.failoverMap = copyFrom.failoverMap;
-      this.id = copyFrom.id;
-   }
-
-   // Public --------------------------------------------------------
-
-   public Object handleCreateConnectionDelegate(Invocation invocation) throws Throwable
-   {
-      // maintain the identity of the delegate that sends invocation through this aspect, for
-      // logging purposes. It makes sense, since it's an PER_INSTANCE aspect.
-      if (id == null)
-      {
-         id = DelegateIdentity.getIdentity(invocation);
-      }
-
-      cacheLocalDelegates(invocation);
-
-      // TODO: I wanted to change aop-messaging-client.xml to only execute handleCreateConnectionDelegate
-      //       on instances of ClusteredClientConnectionFactoryDelegate, but I couldn't find the right
-      //       pointcut expression. So, this is a to do.
-      //      However the following test is enough for now.
-      if (delegates == null)
-      {
-         // not clustered, pass the invocation through
-         if(trace) { log.trace(this + " detecting non-clustered connection creation request, letting it pass through"); }
-
-         return invocation.invokeNext();
-      }
-
-      // clustered, stopping the invocation here and re-send it as non-clustered down the stack
-
-      // TODO: this should be in loop while we get exceptions creating connections, always trying
-      //       the next Delegate when we get an exception.
-
-      // In a clustered configuration we create connections in a round-robin fashion, contacting
-      // successively all available servers.
-
-      ClientConnectionFactoryDelegate cfDelegate = getDelegateRoundRobin();
-
-      if(trace) { log.trace(this + " detecting clustered connection creation request, choosing " + cfDelegate + " as target"); }
-
-      // Now create a connection delegate for this
-
-      MethodInvocation mi = (MethodInvocation)invocation;
-      String username = (String)mi.getArguments()[0];
-      String password = (String)mi.getArguments()[1];
-
-      CreateConnectionResult res = (CreateConnectionResult)cfDelegate.
-         createConnectionDelegate(username, password, -1);
-
-      ClientConnectionDelegate cd = (ClientConnectionDelegate)res.getDelegate();
-
-      // TODO: The valve is optional for now
-      if (INSTALL_VALVE)
-      {
-         installValveAspect(cd, new ValveAspect(cd, this));
-      }
-      else
-      {
-         ((ConnectionState) ((DelegateSupport) cd).getState()).
-            getRemotingConnectionListener().addDelegateListener(new ConnectionFailureListener(cd));
-      }
-
-      if(trace) { log.trace(this + " got local connection delegate " + cd); }
-
-      // Add a connection listener to detect failure; the consolidated remoting connection listener
-      // must be already in place and configured
-
-      return new CreateConnectionResult(cd);
-   }
-
-   public String toString()
-   {
-      StringBuffer sb = new StringBuffer("HAAspect.");
-      if (id == null)
-      {
-         sb.append("UNINITIALIZED");
-      }
-      else
-      {
-         sb.append(id.getType()).append("[").append(id.getID()).append("]");
-      }
-      return sb.toString();
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   private synchronized void cacheLocalDelegates(Invocation invocation)
-   {
-      if (delegates != null)
-      {
-         // the first set of delegates is already cached, return
-         return;
-      }
-
-      MethodInvocation mi = (MethodInvocation)invocation;
-      Object target = mi.getTargetObject();
-
-      if (target instanceof ClusteredClientConnectionFactoryDelegate)
-      {
-         ClusteredClientConnectionFactoryDelegate cccfd =
-            (ClusteredClientConnectionFactoryDelegate)target;
-
-         delegates = cccfd.getDelegates();
-
-         if (delegates != null)
-         {
-            failoverMap = cccfd.getFailoverMap();
-
-            if (failoverMap == null)
-            {
-               throw new IllegalStateException("HAAspect cannot find the failover map!");
-            }
-         }
-      }
-   }
-
-   /** The valve aspect needs to stay after ExceptionInterceptor, and before DelegateSupport.
-    *  This method will place the aspect on the proper place */
-   protected void installValveAspect(DelegateSupport delegate, Interceptor interceptor)
-   {
-      Advised advised = (Advised)delegate;
-      Interceptor interceptors[] = advised._getInstanceAdvisor().getInterceptors();
-
-      //printInterceptors(interceptors);
-
-      Interceptor delegateInterceptorFound = null;
-
-      for (int i=0;i<interceptors.length;i++)
-      {
-         if (interceptors[i] instanceof DelegateSupport)
-         {
-            delegateInterceptorFound = interceptors[i];
-         }
-      }
-
-
-      if (delegateInterceptorFound!=null)
-      {
-         advised._getInstanceAdvisor().removeInterceptor(delegateInterceptorFound.getName());
-      }
-
-      advised._getInstanceAdvisor().appendInterceptor(interceptor);
-
-      if (delegateInterceptorFound!=null)
-      {
-         advised._getInstanceAdvisor().appendInterceptor(delegateInterceptorFound);
-      }
-
-      //printInterceptors(advised._getInstanceAdvisor().getInterceptors());
-
-   }
-   
-
-   //TODO this is currently hardcoded as round-robin, this should be made pluggable
-   private synchronized ClientConnectionFactoryDelegate getDelegateRoundRobin()
-   {
-      ClientConnectionFactoryDelegate currentDelegate = delegates[currentRobinIndex++];
-
-      if (currentRobinIndex >= delegates.length)
-      {
-         currentRobinIndex = 0;
-      }
-
-      return currentDelegate;
-   }
-
-   /**
-    * @return a failover ClientConnectionFactoryDelegate or null if a suitable delegate cannot be
-    *         found.
-    */
-   private ClientConnectionFactoryDelegate getFailoverDelegate(int failedServerID)
-   {
-      // Look up the server to failover onto in the failover map
-
-      Integer failoverServerID = (Integer)failoverMap.get(new Integer(failedServerID));
-
-      for (int i = 0; i < delegates.length; i++)
-      {
-         if (delegates[i].getServerID() == failoverServerID.intValue())
-         {
-            return delegates[i];
-         }
-      }
-
-      return null;
-   }
-
-   protected void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate)
-      throws Exception
-   {
-      log.debug(this + " handling failed connection " + failedConnDelegate);
-
-      ConnectionState failedConnState =
-         (ConnectionState)((DelegateSupport)failedConnDelegate).getState();
-
-      int failedServerID = failedConnState.getServerID();
-
-      // Get the default connection factory delegate we are going to failover onto
-
-      ClientConnectionFactoryDelegate failoverDelegate = getFailoverDelegate(failedServerID);
-
-      if (failoverDelegate == null)
-      {
-         throw new IllegalStateException("Cannot find default failover node for server " +
-                                         failedServerID);
-      }
-
-      // We attempt to connect to the failover node in a loop, since we might need to go through
-      // multiple hops
-
-      int attemptCount = 0;
-
-      outer: while (attemptCount < MAX_RECONNECT_HOP_COUNT)
-      {
-         // Create a connection using that connection factory
-         CreateConnectionResult r = failoverDelegate.
-            createConnectionDelegate(failedConnState.getUser(),
-                                     failedConnState.getPassword(),
-                                     failedConnState.getServerID());
-
-         if (r.getDelegate() != null)
-         {
-            // We got the right server and created a new connection
-            performClientSideFailover(failedConnDelegate, (ClientConnectionDelegate)r.getDelegate());
-            return;
-         }
-
-         // Did not get a valid connection to the node we've just tried
-
-         int actualServerID = r.getActualFailoverNodeID();
-
-         if (actualServerID == -1)
-         {
-            // No failover attempt was detected on the server side; this might happen if the client
-            // side network fails temporarily so the client connection breaks but the server cluster
-            // is still up and running - in this case we don't perform failover.
-
-            //TODO Is this the right thing to do?
-
-            log.warn("Client attempted failover, but no failover attempt " +
-                     "has been detected on the server side.");
-
-            return;
-         }
-
-         // Server side failover has occurred / is occurring but trying to go to the 'default'
-         // failover node did not succeed. Retry with the node suggested by the cluster.
-
-         attemptCount++;
-
-         for (int i = 0; i < delegates.length; i++)
-         {
-            if (delegates[i].getServerID() == actualServerID)
-            {
-               failoverDelegate = delegates[i];
-               continue outer;
-            }
-         }
-
-         // the delegate corresponding to the actualServerID not found among the cached delegates
-         //TODO Could this ever happen? Should we send back the cf, or update it instead of just the id??
-         throw new JMSException("Cannot find a cached connection factory delegate for " +
-                                "node " + actualServerID);
-      }
-
-      throw new JMSException("Maximum number of failover attempts exceeded. " +
-                             "Cannot find a server to failover onto.");
-   }
-
-   protected void performClientSideFailover(ClientConnectionDelegate failedConnDelegate,
-                                            ClientConnectionDelegate newConnDelegate)
-      throws Exception
-   {
-      log.debug(this + " performing client side failover");
-
-      ConnectionState failedState = (ConnectionState)failedConnDelegate.getState();
-      ConnectionState newState = (ConnectionState)newConnDelegate.getState();
-
-      if (failedState.getClientID() != null)
-      {
-         newConnDelegate.setClientID(failedState.getClientID());
-      }
-
-      // Transfer attributes from newDelegate to failedDelegate
-      failedConnDelegate.copyAttributes(newConnDelegate);
-
-      CallbackManager oldCallbackManager = failedState.getRemotingConnection().getCallbackManager();
-
-      // We need to update some of the attributes on the state
-      failedState.copyState(newState);
-      
-      int failedServerId = failedConnDelegate.getServerID();
-      
-      int newServerId = newConnDelegate.getServerID();
-      
-      if (trace) { log.trace("Failing over from " + failedServerId + " to " + newServerId); }
-      
-      // There is one RM per server, so we need to merge the rms if necessary
-      ResourceManagerFactory.instance.handleFailover(failedServerId, newServerId);
-      
-      ResourceManager rm = failedState.getResourceManager();
-
-      for(Iterator i = failedState.getChildren().iterator(); i.hasNext(); )
-      {
-         SessionState failedSessionState = (SessionState)i.next();
-         
-         int oldSessionId = failedSessionState.getSessionId();
-
-         ClientSessionDelegate failedSessionDelegate =
-            (ClientSessionDelegate)failedSessionState.getDelegate();
-
-         ClientSessionDelegate newSessionDelegate = (ClientSessionDelegate)newConnDelegate.
-            createSessionDelegate(failedSessionState.isTransacted(),
-                                  failedSessionState.getAcknowledgeMode(),
-                                  failedSessionState.isXA());
-
-         SessionState newSessionState = (SessionState)newSessionDelegate.getState();
-         
-         int newSessionId = newSessionState.getSessionId();
-
-         if (trace) { log.trace("new session state has " + newSessionState.getClientAckList().size() + " deliveries"); }
-
-         failedSessionDelegate.copyAttributes(newSessionDelegate);
-
-         // We need to update some of the attributes on the state
-         failedSessionState.copyState(newSessionState);
-
-         for (Iterator j = failedSessionState.getChildren().iterator(); j.hasNext(); )
-         {
-            HierarchicalStateSupport sessionChild = (HierarchicalStateSupport)j.next();
-
-            if (sessionChild instanceof ProducerState)
-            {
-               handleFailoverOnProducer((ProducerState)sessionChild, newSessionDelegate);
-            }
-            else if (sessionChild instanceof ConsumerState)
-            {
-               handleFailoverOnConsumer(failedConnDelegate, (ConsumerState)sessionChild,
-                                         newSessionDelegate, oldCallbackManager);
-            }
-            else if (sessionChild instanceof BrowserState)
-            {
-                handleFailoverOnBrowser((BrowserState)sessionChild, newSessionDelegate);
-            }
-         }
-         
-         // We need to failover from one session id to another in the resource manager
-         rm.handleFailover(newServerId, oldSessionId, newSessionId);
-               
-         List ackInfos = Collections.EMPTY_LIST;
-
-         if (!failedSessionState.isTransacted() ||
-             (failedSessionState.isXA() && failedSessionState.getCurrentTxId() == null))
-         {
-            // Non transacted session or an XA session with no transaction set (it falls back
-            // to auto_ack)
-
-            if (trace) { log.trace(failedSessionState + " is not transacted (or XA with no tx set), retrieving deliveries from session state"); }
-
-            // We remove any unacked non-persistent messages - this is because we don't want to ack
-            // them since the server won't know about them and will get confused
-
-            if (failedSessionState.getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
-            {
-               for(Iterator j = failedSessionState.getClientAckList().iterator(); j.hasNext(); )
-               {
-                  DeliveryInfo info = (DeliveryInfo)j.next();
-                  if (!info.getMessageProxy().getMessage().isReliable())
-                  {
-                     j.remove();
-                     if (trace) { log.trace("removed non persistent delivery " + info); }
-                  }
-               }
-
-               ackInfos = failedSessionState.getClientAckList();
-            }
-            else
-            {
-               DeliveryInfo autoAck = failedSessionState.getAutoAckInfo();
-               if (autoAck != null)
-               {
-                  if (!autoAck.getMessageProxy().getMessage().isReliable())
-                  {
-                     // unreliable, discard
-                     failedSessionState.setAutoAckInfo(null);
-                  }
-                  else
-                  {
-                     // reliable
-                     ackInfos = new ArrayList();
-                     ackInfos.add(autoAck);
-                  }
-               }
-            }
-
-            if (trace) { log.trace(this + " retrieved " + ackInfos.size() + " deliveries"); }
-         }
-         else
-         {
-            // Transacted session - we need to get the acks from the resource manager. BTW we have
-            // kept the old resource manager
-
-            ackInfos = rm.getDeliveriesForSession(failedSessionState.getSessionId());
-         }
-
-         if (!ackInfos.isEmpty())
-         {
-            SessionDelegate newDelegate = (SessionDelegate)failedSessionState.getDelegate();
-
-            List recoveryInfos = new ArrayList();
-
-            for (Iterator iter2 = ackInfos.iterator(); iter2.hasNext(); )
-            {
-               DeliveryInfo info = (DeliveryInfo)iter2.next();
-
-               DeliveryRecovery recInfo =
-                  new DeliveryRecovery(info.getMessageProxy().getDeliveryId(),
-                                       info.getMessageProxy().getMessage().getMessageID(),
-                                       info.getChannelId());
-
-               recoveryInfos.add(recInfo);
-            }
-
-            if (trace) { log.trace(this + " sending delivery recovery info: " + recoveryInfos); }
-            newDelegate.recoverDeliveries(recoveryInfos);
-         }
-         else
-         {
-            if (trace) { log.trace(this + " no delivery recovery info to send"); }
-         }
-      }
-
-      // We must not start the connection until the end
-      if (failedState.isStarted())
-      {
-         failedConnDelegate.start();
-      }
-
-      log.info(this + " completed client-side failover");
-   }
-
-   private void handleFailoverOnConsumer(ClientConnectionDelegate failedConnectionDelegate,
-                                         ConsumerState failedConsumerState,
-                                         ClientSessionDelegate newSessionDelegate,
-                                         CallbackManager oldCallbackManager)
-      throws JMSException
-   {
-      log.debug(this + " failing over consumer " + failedConsumerState);
-
-      ClientConsumerDelegate failedConsumerDelegate =
-         (ClientConsumerDelegate)failedConsumerState.getDelegate();
-
-      if (trace) { log.trace(this + " creating alternate consumer"); }
-
-      ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)newSessionDelegate.
-         createConsumerDelegate((JBossDestination)failedConsumerState.getDestination(),
-                                 failedConsumerState.getSelector(),
-                                 failedConsumerState.isNoLocal(),
-                                 failedConsumerState.getSubscriptionName(),
-                                 failedConsumerState.isConnectionConsumer(),
-                                 failedConsumerState.getChannelId());
-
-      if (trace) { log.trace(this + " alternate consumer created"); }
-
-      // Copy the attributes from the new consumer to the old consumer
-      failedConsumerDelegate.copyAttributes(newConsumerDelegate);
-
-      ConsumerState newState = (ConsumerState)newConsumerDelegate.getState();
-
-      int oldConsumerID = failedConsumerState.getConsumerID();
-
-      // Update attributes on the old state
-      failedConsumerState.copyState(newState);
-
-      // We need to re-use the existing message callback handler
-
-      MessageCallbackHandler oldHandler =
-         oldCallbackManager.unregisterHandler(oldConsumerID);
-
-      ConnectionState newConnectionState = (ConnectionState)failedConnectionDelegate.getState();
-
-      CallbackManager newCallbackManager =
-         newConnectionState.getRemotingConnection().getCallbackManager();
-
-      // Remove the new handler
-      MessageCallbackHandler newHandler = newCallbackManager.
-         unregisterHandler(newState.getConsumerID());
-
-      log.debug("New handler is " + System.identityHashCode(newHandler));
-
-      //But we need to update some fields from the new one
-      oldHandler.copyState(newHandler);
-
-      //Now we re-register the old handler with the new callback manager
-
-      newCallbackManager.registerHandler(newState.getConsumerID(),
-                                         oldHandler);
-
-      // We don't need to add the handler to the session state since it is already there - we
-      // are re-using the old handler
-
-      log.debug(this + " failed over consumer");
-   }
-
-
-   private void handleFailoverOnProducer(ProducerState failedProducerState,
-                                         ClientSessionDelegate failedSessionDelegate)
-      throws JMSException
-   {
-      ClientProducerDelegate newProducerDelegate = (ClientProducerDelegate)failedSessionDelegate.
-         createProducerDelegate((JBossDestination)failedProducerState.getDestination());
-
-      ClientProducerDelegate failedProducerDelegate =
-         (ClientProducerDelegate)failedProducerState.getDelegate();
-
-      failedProducerDelegate.copyAttributes(newProducerDelegate);
-      failedProducerState.copyState((ProducerState)newProducerDelegate.getState());
-
-      if (trace) { log.trace("handling fail over on producerDelegate " + failedProducerDelegate + " destination=" + failedProducerState.getDestination()); }
-   }
-
-   private void handleFailoverOnBrowser(BrowserState failedBrowserState,
-                                         ClientSessionDelegate failedSessionDelegate)
-      throws JMSException
-   {
-      ClientBrowserDelegate newBrowserDelegate = (ClientBrowserDelegate)failedSessionDelegate.
-         createBrowserDelegate(failedBrowserState.getJmsDestination(),
-                               failedBrowserState.getMessageSelector());
-
-      ClientBrowserDelegate failedBrowserDelegate =
-         (ClientBrowserDelegate)failedBrowserState.getDelegate();
-
-      failedBrowserDelegate.copyAttributes(newBrowserDelegate);
-      failedBrowserState.copyState((BrowserState)newBrowserDelegate.getState());
-
-      if (trace) { log.trace("handling fail over on browserDelegate " + failedBrowserDelegate + " destination=" + failedBrowserState.getJmsDestination() + " selector=" + failedBrowserState.getMessageSelector()); }
-
-   }
-
-   /** I have moved this ConnectionListener to ValveAspect (from HAAspect) because
-    *  it needs to use the same valve as exception listeners.
-    *  While we are processing failover, we should block any calls on the client side.
-    *  (No call should be made while the client failover is being executed). It doesn't matter if
-    *  the failover was captured by Lease (ConnectionFactory) or Exception handling on invoke at this class */
-   private class ConnectionFailureListener implements ConnectionListener
-   {
-      private ClientConnectionDelegate cd;
-
-      ConnectionFailureListener(ClientConnectionDelegate cd)
-      {
-         this.cd = cd;
-      }
-
-      // ConnectionListener implementation ---------------------------
-
-      public void handleConnectionException(Throwable throwable, Client client)
-      {
-         try
-         {
-            log.debug(this + " is being notified of connection failure: " + throwable);
-            handleConnectionFailure(cd);
-         }
-         catch (Throwable e)
-         {
-            log.error("Caught exception in handling failure", e);
-         }
-      }
-
-      public String toString()
-      {
-         return "ConnectionFailureListener[" + cd + "]";
-      }
-   }
-
-   
-}
-
-

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -79,7 +79,8 @@
       SessionState state = getState(invocation);
       SessionDelegate del = (SessionDelegate)mi.getTargetObject();
             
-      if (trace) { log.trace("In handleClosing"); }
+      if (trace) { log.trace("handleClosing()"); }
+
       //Sanity check
       if (state.isXA())
       {
@@ -204,25 +205,25 @@
       {
          // We collect acknowledgments in the list
          
-         if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack list"); }
+         if (trace) { log.trace(this + " added to CLIENT_ACKNOWLEDGE list delivery " + info); }
          
-         //Sanity check
+         // Sanity check
          if (info.getConnectionConsumerSession() != null)
          {
             throw new IllegalStateException("CLIENT_ACKNOWLEDGE cannot be used with a connection consumer");
          }
                   
-         state.getClientAckList().add(info);         
+         state.getClientAckList().add(info);
       }
       else if (ackMode == Session.AUTO_ACKNOWLEDGE ||
                ackMode == Session.DUPS_OK_ACKNOWLEDGE ||
                (state.isXA() && state.getCurrentTxId() == null))
       {
-         //We collect the single acknowledgement in the state.
-         //Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE
-         //Also XA sessions not enlisted in a global tx are treated as AUTO_ACKNOWLEDGE
+         // We collect the single acknowledgement in the state. Currently DUPS_OK is treated the
+         // same as AUTO_ACKNOWLDGE. Also XA sessions not enlisted in a global tx are treated as
+         // AUTO_ACKNOWLEDGE.
                            
-         if (trace) { log.trace(this + " delivery id: " + info.getDeliveryId() + " added to client ack member"); }
+         if (trace) { log.trace(this + " added " + info + " to session state"); }
          
          state.setAutoAckInfo(info);         
       }
@@ -280,22 +281,22 @@
          //will be redelivered
          if (!state.isRecoverCalled())
          {
-            DeliveryInfo deliveryInfo = state.getAutoAckInfo();
+            DeliveryInfo delivery = state.getAutoAckInfo();
             
-            if (deliveryInfo == null)
+            if (delivery == null)
             {
-               throw new IllegalStateException("Cannot find delivery to auto ack");
+               throw new IllegalStateException("Cannot find delivery to AUTO_ACKNOWLEDGE");
             }
                                  
-            if (trace) { log.trace(this + " auto acking delivery " + deliveryInfo.getDeliveryId()); }
+            if (trace) { log.trace(this + " auto acknowledging delivery " + delivery); }
                         
-            ackDelivery(sd, deliveryInfo);            
-            
+            ackDelivery(sd, delivery);
+
             state.setAutoAckInfo(null);
          }
          else
          {
-            if (trace) { log.trace("recover called, so NOT acknowledging"); }
+            if (trace) { log.trace(this + " recover called, so NOT acknowledging"); }
 
             state.setRecoverCalled(false);
          }
@@ -553,6 +554,12 @@
    {
       return new Integer(getState(invocation).getAcknowledgeMode());
    }
+
+   public String toString()
+   {
+      return "SessionAspect[" + Integer.toHexString(hashCode()) + "]";
+   }
+
    
 
    // Class YYY overrides -------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/StateCreationAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -79,8 +79,6 @@
 
    // Public --------------------------------------------------------
 
-   // Interceptor implementation -----------------------------------
-
    public Object handleCreateConnectionDelegate(Invocation inv) throws Throwable
    {
       ConnectionFactoryDelegate cfd = (ConnectionFactoryDelegate)inv.getTargetObject();
@@ -117,14 +115,10 @@
             MessageIdGeneratorFactory.instance.checkOutGenerator(serverID, cfd);
 
          ConnectionState connectionState =
-            new ConnectionState(serverID, connectionDelegate, remotingConnection,
-                                listener, versionToUse, idGenerator);
+            new ConnectionState(serverID, connectionDelegate,
+                                remotingConnection, listener, versionToUse, idGenerator);
 
          connectionDelegate.setState(connectionState);
-
-         // the delegate is completely configured now; will use this state to avoid redundant
-         // configuration on a double pass through StateCreationAspect, which happens for clustered
-         // connections
       }
 
       return res;

Deleted: trunk/src/main/org/jboss/jms/client/container/ValveAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/container/ValveAspect.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -1,256 +0,0 @@
-/*
-   * JBoss, Home of Professional Open Source
-   * Copyright 2005, JBoss Inc., and individual contributors as indicated
-   * by the @authors tag. See the copyright.txt 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.jms.client.container;
-
-import org.jboss.aop.advice.Interceptor;
-import org.jboss.aop.joinpoint.Invocation;
-import org.jboss.jms.client.delegate.DelegateSupport;
-import org.jboss.jms.client.delegate.ClientConnectionDelegate;
-import org.jboss.jms.client.state.ConnectionState;
-import org.jboss.jms.client.remoting.JMSRemotingConnection;
-import org.jboss.logging.Logger;
-import org.jboss.remoting.CannotConnectException;
-import org.jboss.remoting.ConnectionListener;
-import org.jboss.remoting.Client;
-import java.io.IOException;
-import EDU.oswego.cs.dl.util.concurrent.ReadWriteLock;
-import EDU.oswego.cs.dl.util.concurrent.ReentrantWriterPreferenceReadWriteLock;
-
-/**
- * This aspect will intercept failures from any HA object.
- * <p/>
- * The reason why I've made an extension of HAAspect instead of implementing new methods there is
- * ValveAspect needs to cache ClientConnectionDelegate while HAAspect needs to cache CF related objects.
- * I have made this an extension of HAAspect as it's needed one instance of this aspect per
- * ConnectionCreated.
- * <p/>
- * We will cache the ClientConnectionDelegate on this aspect so we won't need to do any operation on delegates
- * to retrieve the current ConnectionDelegate.
- *
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
- */
-public class ValveAspect extends HAAspect implements Interceptor
-{
-   private static final Logger log = Logger.getLogger(ValveAspect.class);
-
-   private ClientConnectionDelegate delegate;
-
-   private ReadWriteLock lockValve;
-
-   ValveAspect(ClientConnectionDelegate delegate, HAAspect copy)
-   {
-      super(copy);
-      this.delegate = delegate;
-      lockValve = new ReentrantWriterPreferenceReadWriteLock();
-
-      ConnectionListener listener = new ConnectionFailureListener(delegate);
-
-      ((ConnectionState) ((DelegateSupport) delegate).getState()).
-         getRemotingConnectionListener().addDelegateListener(listener);
-
-
-   }
-
-   public String getName()
-   {
-      return this.getClass().getName();
-   }
-
-
-   /**
-    * This method executes the valve, listening for erros on the underlaying IO layer,
-    * and it will call the failure for HA
-    */
-   public Object invoke(Invocation invocation) throws Throwable
-   {
-
-      Object returnObject = null;
-
-      boolean failure = false;
-
-      // Eventually retries in case of listed exceptions
-      for (int invocationCount = 0; invocationCount < MAX_IO_RETRY_COUNT; invocationCount++)
-      {
-
-         if (invocationCount > 0)
-         {
-            log.info("Retrying a call " + invocationCount);
-         }
-
-         // We shouldn't have any calls being made while the failover is being executed
-         if (invocationCount > 0)
-         {
-            // On retries we will use writeLocks, as the failover was already being processed
-            lockValve.writeLock().acquire();
-         }
-         else
-         {
-            lockValve.readLock().acquire();
-         }
-
-         failure = false;
-
-         try
-         {
-            returnObject = invocation.invokeNext();
-
-            if (returnObject instanceof DelegateSupport)
-            {
-               installValveAspect((DelegateSupport) returnObject, this);
-            }
-         }
-         catch (CannotConnectException e)
-         {
-            log.error("Got an exception on HAAspect, retryCount=" + invocationCount, e);
-            failure = true;
-         }
-         catch (IOException e)
-         {
-            log.error("Got an exception on HAAspect, retryCount=" + invocationCount, e);
-            failure = true;
-         }
-         catch (Throwable e)
-         {
-            // just rethrow
-            throw e;
-         }
-         finally
-         {
-            if (invocationCount > 0)
-            {
-               lockValve.writeLock().release();
-            }
-            else
-            {
-               lockValve.readLock().release();
-            }
-         }
-
-         if (!failure)
-         {
-            break;
-         }
-      }
-
-
-      if (failure)
-      {
-         handleConnectionFailure(delegate, delegate.getRemotingConnection());
-         // if on the end we still have an exception there is nothing we can do besides throw an exception
-         // so, no retires on the failedOver Invocation
-         returnObject = invocation.invokeNext();
-      }
-
-      // if the object returned is another DelegateSupport, we will install the aspect on the returned object
-
-      return returnObject;
-
-   }
-
-
-   /**
-    * Since we are listening for exceptions on the invocation layer, several objects might
-    * get the exception at the same time.
-    * Suppose you have 30 (or any X number>=2) Consumers, using the same JBossConnection failing at the same time.
-    * We will get simultaneous calls on handleFailures while we just need to process one single failure.
-    * <p/>
-    * On this case this method will open a valve and it will perform only the first handleFailure captured, and
-    * it will just return all the others as soon as the valve is closed. This way all the simultaneous failures will
-    * act as they were processed while we called failover only once.
-    */
-   protected void handleConnectionFailure(ClientConnectionDelegate failedConnDelegate,
-                                          JMSRemotingConnection jmsConnection) throws Exception
-   {
-      log.info("Processing handleConnectionFailure ");
-
-      // only one execution should be performed if multiple exceptions happened at the same time
-      lockValve.writeLock().acquire();
-
-      try
-      {
-         if (jmsConnection.isFailed())
-         {
-            log.info("Failover on " + failedConnDelegate + " was already performed, so just ignoring call to handleConnectionFailure");
-            return;
-         }
-
-         log.info("Processing valve on exception failure");
-         jmsConnection.setFailed(true);
-         super.handleConnectionFailure(failedConnDelegate);
-         log.info("Failover on client finished");
-      }
-      catch (Exception e)
-      {
-         log.error("An exception happened during client failover processing!", e);
-         throw e;
-      }
-      finally
-      {
-         lockValve.writeLock().release();
-      }
-
-   }
-
-   // Inner classes -------------------------------------------------
-
-
-   /** I have moved this ConnectionListener to ValveAspect (from HAAspect) because
-    *  it needs to use the same valve as exception listeners.
-    *  While we are processing failover, we should block any calls on the client side.
-    *  (No call should be made while the client failover is being executed). It doesn't matter if
-    *  the failover was captured by Lease (ConnectionFactory) or Exception handling on invoke at this class */
-   private class ConnectionFailureListener implements ConnectionListener
-   {
-      private ClientConnectionDelegate cd;
-
-      ConnectionFailureListener(ClientConnectionDelegate cd)
-      {
-         this.cd = cd;
-      }
-
-      // ConnectionListener implementation ---------------------------
-
-      public void handleConnectionException(Throwable throwable, Client client)
-      {
-         try
-         {
-            log.debug(this + " is being notified of connection failure: " + throwable);
-            handleConnectionFailure(cd, cd.getRemotingConnection());
-         }
-         catch (Throwable e)
-         {
-            log.error("Caught exception in handling failure", e);
-         }
-      }
-
-      public String toString()
-      {
-         return "ConnectionFailureListener[" + cd + "]";
-      }
-   }
-
-
-}

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientBrowserDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientBrowserDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientBrowserDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -57,7 +57,6 @@
    
    public ClientBrowserDelegate()
    {     
-      
    }
 
    // BrowserDelegate implementation --------------------------------
@@ -96,6 +95,42 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void closeValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void openValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public boolean isValveOpen()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public int getActiveThreadsCount()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
    // Public --------------------------------------------------------
 
    public String getStackName()

Copied: trunk/src/main/org/jboss/jms/client/delegate/ClientClusteredConnectionFactoryDelegate.java (from rev 1870, trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java)
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-29 03:02:10 UTC (rev 1870)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientClusteredConnectionFactoryDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,172 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright 2005, JBoss Inc., and individual contributors as indicated
+ * by the @authors tag. See the copyright.txt 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.jms.client.delegate;
+
+import java.util.Map;
+import java.io.Serializable;
+
+import org.jboss.jms.server.endpoint.CreateConnectionResult;
+import org.jboss.jms.delegate.ConnectionFactoryDelegate;
+import org.jboss.messaging.core.plugin.IDBlock;
+import org.jboss.logging.Logger;
+
+import javax.jms.JMSException;
+
+/**
+ * A ClientClusteredConnectionFactoryDelegate.
+ *
+ * It DOESN'T extend DelegateSupport, because none of DelegateSupport's attributes make sense here:
+ * there is no corresponding enpoint on the server, there's no ID, etc. This is just a "shallow"
+ * delegate, that in turn delegates to its sub-delegates (ClientConnectionFactoryDelegate instances)
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
+ * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
+ *
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ */
+public class ClientClusteredConnectionFactoryDelegate
+   implements Serializable, Initializable, ConnectionFactoryDelegate
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   private static final long serialVersionUID = 8286850860206289277L;
+
+   private static final Logger log =
+      Logger.getLogger(ClientClusteredConnectionFactoryDelegate.class);
+
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   private ClientConnectionFactoryDelegate[] delegates;
+
+   // Map <Integer(nodeID)->Integer(failoverNodeID)>
+   private Map failoverMap;
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   public ClientClusteredConnectionFactoryDelegate(ClientConnectionFactoryDelegate[] delegates,
+                                                   Map failoverMap)
+   {
+      this.delegates = delegates;
+      this.failoverMap = failoverMap;
+   }
+
+   // ConnectionFactoryDelegate implementation -----------------------------------------------------
+
+   public byte[] getClientAOPStack()
+   {
+      // Use one of the non-clustered ConnectionFactory delegates to retrieve the client AOP stack
+      // from one of the nodes.
+
+      ConnectionFactoryDelegate aopStackProvider = delegates[0];
+
+      log.debug("getting AOP stack from " + aopStackProvider);
+
+      return aopStackProvider.getClientAOPStack();
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public CreateConnectionResult createConnectionDelegate(String username, String password,
+                                                          int failedNodeID) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public IDBlock getIdBlock(int size) throws JMSException
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   // Initializable implemenation ------------------------------------------------------------------
+
+   public void init()
+   {
+      for (int i = 0; i < delegates.length; i++)
+      {
+         delegates[i].init();
+      }
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public ClientConnectionFactoryDelegate[] getDelegates()
+   {
+      return delegates;
+   }
+
+   public void setDelegates(ClientConnectionFactoryDelegate[] dels)
+   {
+      this.delegates = dels;
+   }
+
+   public Map getFailoverMap()
+   {
+      return failoverMap;
+   }
+
+   public void setFailoverMap(Map failoverMap)
+   {
+      this.failoverMap = failoverMap;
+   }
+
+   public String toString()
+   {
+      StringBuffer sb = new StringBuffer("ClusteredConnectionFactoryDelegate[");
+      if (delegates == null)
+      {
+         sb.append("-]");
+      }
+      else
+      {
+         for(int i = 0; i < delegates.length; i++)
+         {
+            sb.append(delegates[i].getServerID());
+            if (i < delegates.length - 1)
+            {
+               sb.append(',');
+            }
+         }
+         sb.append("]");
+      }
+      return sb.toString();
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   // Inner classes --------------------------------------------------------------------------------
+
+}

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -29,12 +29,14 @@
 import javax.transaction.xa.Xid;
 
 import org.jboss.jms.client.JBossConnectionConsumer;
+import org.jboss.jms.client.FailoverListener;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.delegate.ConnectionDelegate;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.TransactionRequest;
+import org.jboss.jms.tx.ResourceManagerFactory;
 import org.jboss.remoting.Client;
 
 /**
@@ -50,35 +52,72 @@
  */
 public class ClientConnectionDelegate extends DelegateSupport implements ConnectionDelegate
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
    private static final long serialVersionUID = 6680015509555859038L;
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
    private int serverID;
-
    private transient JMSRemotingConnection remotingConnection;
-   
    private Version versionToUse;
    
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
-   public ClientConnectionDelegate(int objectID, int serverId)
+   public ClientConnectionDelegate(int objectID, int serverID)
    {
       super(objectID);
-      
-      this.serverID = serverId;
+      this.serverID = serverID;
    }
 
    public ClientConnectionDelegate()
    {
    }
 
-   // ConnectionDelegate implementation -----------------------------
+   // DelegateSupport overrides --------------------------------------------------------------------
 
+   public void synchronizeWith(DelegateSupport nd) throws Exception
+   {
+      super.synchronizeWith(nd);
+
+      ClientConnectionDelegate newDelegate = (ClientConnectionDelegate)nd;
+
+      // synchronize the server endpoint state
+
+      // this is a bit counterintuitve, as we're not copying from new delegate, but modifying its
+      // state based on the old state. It makes sense, since in the end the state makes it to the
+      // server
+
+      ConnectionState thisState = (ConnectionState)state;
+
+      if (thisState.getClientID() != null)
+      {
+         newDelegate.setClientID(thisState.getClientID());
+      }
+
+      // synchronize the delegates
+
+      remotingConnection = newDelegate.getRemotingConnection();
+      versionToUse = newDelegate.getVersionToUse();
+
+      // There is one RM per server, so we need to merge the rms if necessary
+      ResourceManagerFactory.instance.handleFailover(serverID, newDelegate.getServerID());
+
+      // synchronize (recursively) the client-side state
+
+      state.synchronizeWith(newDelegate.getState());
+
+      // start the new connection if necessary
+      if (thisState.isStarted())
+      {
+         newDelegate.start();
+      }
+   }
+
+   // ConnectionDelegate implementation ------------------------------------------------------------
+
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
@@ -213,13 +252,68 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
-   // Public --------------------------------------------------------
+   /**
+    * This invocation should be handled by the client-side interceptor chain.
+    */
+   public void registerFailoverListener(FailoverListener l)
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
 
-   public String toString()
+   /**
+    * This invocation should be handled by the client-side interceptor chain.
+    */
+   public boolean unregisterFailoverListener(FailoverListener l)
    {
-      return "ConnectionDelegate[" + id + ", SID=" + serverID + "]";
+      throw new IllegalStateException("This invocation should not be handled here!");
    }
 
+   /**
+    * This invocation should be handled by the client-side interceptor chain.
+    */
+   public void performFailover()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void closeValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void openValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public boolean isValveOpen()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public int getActiveThreadsCount()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
    public void init()
    {
       super.init();
@@ -249,27 +343,23 @@
    {
       this.versionToUse = versionToUse;
    }
-   
-   public void copyAttributes(DelegateSupport newDelegate)
+
+   public String toString()
    {
-      super.copyAttributes(newDelegate);
-      
-      this.remotingConnection = ((ClientConnectionDelegate)newDelegate).getRemotingConnection();
-      
-      this.versionToUse = ((ClientConnectionDelegate)newDelegate).getVersionToUse();
+      return "ConnectionDelegate[" + id + ", SID=" + serverID + "]";
    }
 
-   // Protected -----------------------------------------------------   
+   // Protected ------------------------------------------------------------------------------------
 
    protected Client getClient()
    {
       return ((ConnectionState)state).getRemotingConnection().getInvokingClient();
    }
 
-   // Package Private -----------------------------------------------
+   // Package Private ------------------------------------------------------------------------------
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   // Inner Classes -------------------------------------------------
+   // Inner Classes --------------------------------------------------------------------------------
 
 }

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConnectionFactoryDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -27,6 +27,7 @@
 import javax.jms.JMSException;
 
 import org.jboss.aop.Dispatcher;
+import org.jboss.aop.Advised;
 import org.jboss.aop.joinpoint.Invocation;
 import org.jboss.aop.joinpoint.MethodInvocation;
 import org.jboss.aop.metadata.SimpleMetaData;
@@ -58,13 +59,13 @@
 public class ClientConnectionFactoryDelegate
    extends DelegateSupport implements ConnectionFactoryDelegate
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
    private static final long serialVersionUID = 2512460695662741413L;
 
    private static final Logger log = Logger.getLogger(ClientConnectionFactoryDelegate.class);
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
    //This data is needed in order to create a connection
    private String serverLocatorURI;
@@ -77,7 +78,7 @@
    
    private transient boolean trace;
 
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
    
    /*
     * Calculate what version to use.
@@ -90,7 +91,8 @@
 
       Version versionToUse;
 
-      if (connectionVersion.getProviderIncrementingVersion() <= clientVersion.getProviderIncrementingVersion())
+      if (connectionVersion.getProviderIncrementingVersion() <=
+          clientVersion.getProviderIncrementingVersion())
       {
          versionToUse = connectionVersion;
       }
@@ -102,39 +104,50 @@
       return versionToUse;
    }
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
-   public ClientConnectionFactoryDelegate(int objectID, int serverId, String serverLocatorURI,
-                                          Version serverVersion,
-                                          boolean clientPing)
+   public ClientConnectionFactoryDelegate(int objectID, int serverID, String serverLocatorURI,
+                                          Version serverVersion, boolean clientPing)
    {
       super(objectID);
 
-      this.serverID = serverId;
+      this.serverID = serverID;
       this.serverLocatorURI = serverLocatorURI;
       this.serverVersion = serverVersion;
       this.clientPing = clientPing;
       trace = log.isTraceEnabled();
    }
 
-   // ConnectionFactoryDelegateImplementation -----------------------
- 
-   /**
-    * This invocation should either be handled by the client-side interceptor chain or by the
-    * server-side endpoint.
-    */
-   public CreateConnectionResult createConnectionDelegate(String username, String password, int failedNodeId)
-      throws JMSException
+   // ClientAOPStackProvider implementation --------------------------------------------------------
+
+   public byte[] getClientAOPStack()
    {
-      throw new IllegalStateException("This invocation should not be handled here!");
+      // When the invocation lands here the first time, the AOP stack hasn't been initialized yet,
+      // so we "manually" add this delegate at the end of its empty stack and re-send the invocation
+      // down the stack; it will eventually end up on the server.
+
+      ((Advised)this)._getInstanceAdvisor().appendInterceptor(this);
+
+      byte[] clientAOPStack = this.getClientAOPStack();
+
+      // remove ourselves from the end of our own AOP stack now that we have the "real" AOP
+      // configuration that we can use.
+
+      ((Advised)this)._getInstanceAdvisor().removeInterceptor(this.getName());
+
+      return clientAOPStack;
    }
 
+   // ConnectionFactoryDelegate implementation -----------------------------------------------------
+ 
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
-    * @see org.jboss.jms.server.endpoint.ServerConnectionFactoryEndpoint#getClientAOPConfig()
     */
-   public byte[] getClientAOPConfig()
+   public CreateConnectionResult createConnectionDelegate(String username,
+                                                          String password,
+                                                          int failedNodeID)
+      throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -149,7 +162,7 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
-   // Public --------------------------------------------------------
+   // Public ---------------------------------------------------------------------------------------
 
    public synchronized Object invoke(Invocation invocation) throws Throwable
    {
@@ -160,21 +173,31 @@
 
       SimpleMetaData md = mi.getMetaData();
 
-      md.addMetaData(Dispatcher.DISPATCHER,
-                     Dispatcher.OID,
-                     new Integer(id),
-                     PayloadKey.AS_IS);
+      if ("getClientAOPStack".equals(methodName))
+      {
+         // the ClientAOPStackProvider on the server-side is the ServerPeer itself
+         md.addMetaData(Dispatcher.DISPATCHER,
+                        Dispatcher.OID,
+                        new Integer(serverID),
+                        PayloadKey.AS_IS);
+      }
+      else
+      {
+         md.addMetaData(Dispatcher.DISPATCHER,
+                        Dispatcher.OID,
+                        new Integer(id),
+                        PayloadKey.AS_IS);
+      }
 
-      /*
-       * If the method being invoked is createConnectionDelegate then we must invoke it on the same
-       * remoting client subsequently used by the connection.
-       * This is because we need to pass in the remoting session id in the call to createConnection
-       * All other invocations can be invoked on an arbitrary client, which can be created for each invocation.
-       * If we disable pinging on the client then it is a reasonably light weight operation to create the client
-       * since it will use the already existing invoker.
-       * This prevents us from having to maintain a Client instance per connection factory, which gives
-       * difficulties in knowing when to close it.
-       */
+      // If the method being invoked is createConnectionDelegate() then we must invoke it on the
+      // same remoting client subsequently used by the connection. This is because we need to pass
+      // in the remoting session id in the call to createConnection. All other invocations can be
+      // invoked on an arbitrary client, which can be created for each invocation.
+      //
+      // If we disable pinging on the client then it is a reasonably light weight operation to
+      // create the client since it will use the already existing invoker. This prevents us from
+      // having to maintain a Client instance per connection factory, which gives difficulties in
+      // knowing when to close it.
 
       Client client;
 
@@ -208,16 +231,14 @@
          configuration.put(Client.ENABLE_LEASE, String.valueOf(false));
 
          client = new Client(new InvokerLocator(serverLocatorURI), configuration);
-
          client.setSubsystem(ServerPeer.REMOTING_JMS_SUBSYSTEM);
-
          client.connect();
 
          client.setMarshaller(new JMSWireFormat());
          client.setUnMarshaller(new JMSWireFormat());
       }
 
-      //What version should we use for invocations on this connection factory?
+      // What version should we use for invocations on this connection factory?
       Version version = getVersionToUse(serverVersion);
       byte v = version.getProviderIncrementingVersion();
 
@@ -233,8 +254,8 @@
       }
       catch (Throwable t)
       {
-         //If we were invoking createConnectionDelegate and failure occurs then we need to clear
-         //up the JMSRemotingConnection
+         // If we were invoking createConnectionDelegate and failure occurs then we need to clear
+         // up the JMSRemotingConnection
 
          if (remotingConnection != null)
          {
@@ -253,9 +274,9 @@
       {
          if (remotingConnection == null)
          {
-            //Not a call to createConnectionDelegate - disconnect the client
+            // Not a call to createConnectionDelegate - disconnect the client
 
-            //client.disconnect();
+            // client.disconnect();
          }
       }
 
@@ -317,24 +338,22 @@
       return serverVersion;
    }
    
-   public void copyAttributes(DelegateSupport newDelegate)
+   public void synchronizeWith(DelegateSupport newDelegate) throws Exception
    {
-      super.copyAttributes(newDelegate);
+      super.synchronizeWith(newDelegate);
    }
 
-   // Protected -----------------------------------------------------
+   // Protected ------------------------------------------------------------------------------------
 
-   
-
    protected Client getClient()
    {
       return null;
    }
 
-   // Package Private -----------------------------------------------
+   // Package Private ------------------------------------------------------------------------------
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   // Inner Classes -------------------------------------------------
+   // Inner Classes --------------------------------------------------------------------------------
 
 }

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientConsumerDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -171,6 +171,42 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void closeValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void openValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public boolean isValveOpen()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public int getActiveThreadsCount()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
    // Public --------------------------------------------------------
 
    public String toString()
@@ -193,9 +229,9 @@
       return channelId;
    }
    
-   public void copyAttributes(DelegateSupport newDelegate)
+   public void synchronizeWith(DelegateSupport newDelegate) throws Exception
    {
-      super.copyAttributes(newDelegate);
+      super.synchronizeWith(newDelegate);
       
       this.bufferSize = ((ClientConsumerDelegate)newDelegate).getBufferSize();
       

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientProducerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientProducerDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientProducerDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -212,6 +212,42 @@
       throw new IllegalStateException("This invocation should not be handled here!");
    }
 
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void closeValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void openValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public boolean isValveOpen()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public int getActiveThreadsCount()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
    // Public --------------------------------------------------------
 
    public String toString()

Modified: trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClientSessionDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -61,15 +61,15 @@
  */
 public class ClientSessionDelegate extends DelegateSupport implements SessionDelegate
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
    private static final long serialVersionUID = -8096852898620279131L;
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
    public ClientSessionDelegate(int objectID)
    {
@@ -79,9 +79,26 @@
    public ClientSessionDelegate()
    {      
    }
-   
-   // SessionDelegate implementation --------------------------------
 
+   // DelegateSupport overrides --------------------------------------------------------------------
+
+   public void synchronizeWith(DelegateSupport nd) throws Exception
+   {
+      super.synchronizeWith(nd);
+
+      ClientSessionDelegate newDelegate = (ClientSessionDelegate)nd;
+
+      // synchronize server endpoint state
+
+      // synchronize the delegates
+
+      // synchronize (recursively) the client-side state
+      
+      state.synchronizeWith(newDelegate.getState());
+   }
+
+   // SessionDelegate implementation ---------------------------------------------------------------
+
    /**
     * This invocation should either be handled by the client-side interceptor chain or by the
     * server-side endpoint.
@@ -189,7 +206,8 @@
     */
    public ConsumerDelegate createConsumerDelegate(JBossDestination destination, String selector,
                                                   boolean noLocal, String subscriptionName,
-                                                  boolean connectionConsumer, long failoverChannelId) throws JMSException
+                                                  boolean connectionConsumer,
+                                                  long failoverChannelId) throws JMSException
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
@@ -447,16 +465,51 @@
    {
       throw new IllegalStateException("This invocation should not be handled here!");
    }
-   
 
-   // Public --------------------------------------------------------
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void closeValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
 
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public void openValve()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public boolean isValveOpen()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   /**
+    * This invocation should either be handled by the client-side interceptor chain or by the
+    * server-side endpoint.
+    */
+   public int getActiveThreadsCount()
+   {
+      throw new IllegalStateException("This invocation should not be handled here!");
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
    public String toString()
    {
       return "SessionDelegate[" + id + "]";
    }
 
-   // Protected -----------------------------------------------------
+   // Protected ------------------------------------------------------------------------------------
    
    protected Client getClient()
    {
@@ -465,10 +518,10 @@
    }
 
 
-   // Package Private -----------------------------------------------
+   // Package Private ------------------------------------------------------------------------------
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   // Inner Classes -------------------------------------------------
+   // Inner Classes --------------------------------------------------------------------------------
 
 }

Deleted: trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/ClusteredClientConnectionFactoryDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -1,151 +0,0 @@
-/*
- * JBoss, Home of Professional Open Source
- * Copyright 2005, JBoss Inc., and individual contributors as indicated
- * by the @authors tag. See the copyright.txt 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.jms.client.delegate;
-
-import java.util.Map;
-
-import org.jboss.jms.server.Version;
-
-/**
- * A ClusteredClientConnectionFactoryDelegate
- * 
- * This ConnectionFactoryDelegate handles connection factory operations
- * (getIdBlock, getClientAOPConfig like any other connection factory)
- * 
- * The actual failover logic is in the FailoverAspect
- * 
- * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
- * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
- * @version <tt>$Revision: 1.1 $</tt>
- *
- * $Id$
- */
-public class ClusteredClientConnectionFactoryDelegate extends ClientConnectionFactoryDelegate
-{
-   // Constants -----------------------------------------------------
-
-   private static final long serialVersionUID = 8286850860206289277L;
-
-   // Static --------------------------------------------------------
-
-   // Attributes ----------------------------------------------------
-
-   private ClientConnectionFactoryDelegate[] delegates;
-
-   //Map <node Id, failover node id>
-   private Map failoverMap;
-
-   // Constructors --------------------------------------------------
-
-   public ClusteredClientConnectionFactoryDelegate(int objectID, int serverId,
-                                                   String serverLocatorURI,
-                                                   Version serverVersion, boolean clientPing,
-                                                   ClientConnectionFactoryDelegate[] delegates,
-                                                   Map failoverMap)
-   {
-      super(objectID, serverId, serverLocatorURI, serverVersion, clientPing);
-      this.delegates = delegates;
-      this.failoverMap = failoverMap;
-   }
-
-   // Some of the properties of ClientConnectionFactoryDelegate are not exposed.
-   // I didn't want to expose then while I needed another delegate's properties to perform a copy.
-   // So, I created this Constructor so I could have access into protected members inside an
-   // extension class.
-
-   public ClusteredClientConnectionFactoryDelegate(ClientConnectionFactoryDelegate mainDelegate,
-                                                   ClientConnectionFactoryDelegate[] delegates,
-                                                   Map failoverMap)
-   {
-      this(mainDelegate.getID(), mainDelegate.getServerID(), mainDelegate.getServerLocatorURI(),
-           mainDelegate.getServerVersion(), mainDelegate.getClientPing(), delegates, failoverMap);
-   }
-
-   // DelegateSupport overrides -------------------------------------
-
-   public void init()
-   {
-      super.init();
-
-      for (int i = 0; i < delegates.length; i++)
-      {
-         if (this!=delegates[i])
-         {
-            delegates[i].init();
-         }
-      }      
-   }
-
-   // Public --------------------------------------------------------
-
-   public ClientConnectionFactoryDelegate[] getDelegates()
-   {
-      return delegates;
-   }
-
-   public Map getFailoverMap()
-   {
-      return failoverMap;
-   }
-   
-   public void setFailoverMap(Map failoverMap)
-   {
-      this.failoverMap = failoverMap;
-   }
-   
-   public void setDelegates(ClientConnectionFactoryDelegate[] dels)
-   {
-      this.delegates = dels;
-   }
-
-   public String toString()
-   {
-      StringBuffer sb = new StringBuffer("ClusteredConnectionFactoryDelegate[");
-      sb.append(id).append("][");
-      if (delegates == null)
-      {
-         sb.append("-]");
-      }
-      else
-      {
-         for(int i = 0; i < delegates.length; i++)
-         {
-            sb.append(delegates[i].getServerID());
-            if (i < delegates.length - 1)
-            {
-               sb.append(',');
-            }
-         }
-         sb.append("]");
-      }
-      return sb.toString();
-   }
-
-   // Package protected ---------------------------------------------
-
-   // Protected -----------------------------------------------------
-
-   // Private -------------------------------------------------------
-
-   // Inner classes -------------------------------------------------
-
-}

Modified: trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/DelegateSupport.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -54,9 +54,9 @@
  *
  * $Id$
  */
-public abstract class DelegateSupport implements Interceptor, Serializable
+public abstract class DelegateSupport implements Interceptor, Serializable, Initializable
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
    private static final long serialVersionUID = 8005108339439737469L;
 
@@ -64,7 +64,7 @@
 
    private static boolean trace = log.isTraceEnabled();
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
    // This is set on the server.
    protected int id;
@@ -75,9 +75,9 @@
    // queried for many aspects in an a single invocation.
    protected transient HierarchicalState state;
 
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
    public DelegateSupport(int id)
    {
@@ -94,7 +94,7 @@
 
    public String getName()
    {
-      // it's needed a meaninful name to change the aop stack programatically (HA uses that)
+      // Neede a meaninful name to change the aop stack programatically (HA uses that)
       return this.getClass().getName();
    }
 
@@ -104,7 +104,7 @@
     */
    public Object invoke(Invocation invocation) throws Throwable
    {
-      if (trace) { log.trace("invoking " + ((MethodInvocation)invocation).getMethod().getName() + " on server"); }
+      if (trace) { log.trace(this + " invoking " + ((MethodInvocation)invocation).getMethod().getName() + " on server"); }
 
       invocation.getMetaData().addMetaData(Dispatcher.DISPATCHER,
                                            Dispatcher.OID,
@@ -116,13 +116,20 @@
       MessagingMarshallable request = new MessagingMarshallable(version, invocation);
       MessagingMarshallable response = (MessagingMarshallable)getClient().invoke(request, null);
 
-      if (trace) { log.trace("got server response for " + ((MethodInvocation)invocation).getMethod().getName()); }
+      if (trace) { log.trace(this + " got server response for " + ((MethodInvocation)invocation).getMethod().getName()); }
 
       return response.getLoad();
    }
 
-   // Public --------------------------------------------------------
+   // Initializable implemenation ------------------------------------------------------------------
 
+   public void init()
+   {
+      ((Advised)this)._getInstanceAdvisor().appendInterceptor(this);
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
    public HierarchicalState getState()
    {
       return state;
@@ -133,34 +140,25 @@
       this.state = state;
    }
 
-   /**
-    *  Add Invoking interceptor and prepare the stack for invocations.
-    */
-   public void init()
-   {
-      ((Advised)this)._getInstanceAdvisor().appendInterceptor(this);
-
-      checkMarshallers();
-   }
-
    public int getID()
    {
       return id;
    }
 
    /**
-    * During HA events, a new object is created on the new server and the state on that new object
-    * has to be transfered to this actual object. For example, a Connection will have to assume the
-    * ObjectID of the new connection endpoint and the new RemotingConnection.
+    * During HA events, delegates corresponding to new enpoints on the new server are created and
+    * the state of those delegates has to be transfered to the "failed" delegates. For example, a
+    * "failed" connection delegate will have to assume the ID of the new connection endpoint, the
+    * new RemotingConnection instance, etc.
     */
-   public void copyAttributes(DelegateSupport newDelegate)
+   public void synchronizeWith(DelegateSupport newDelegate) throws Exception
    {
       id = newDelegate.getID();
    }
 
-   // Package protected ---------------------------------------------
+   // Package protected ----------------------------------------------------------------------------
 
-   // Protected -----------------------------------------------------
+   // Protected ------------------------------------------------------------------------------------
 
    protected SimpleMetaData getMetaData()
    {
@@ -170,24 +168,8 @@
    protected abstract Client getClient() throws Exception;
 
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   private static boolean checked;
+   // Inner classes --------------------------------------------------------------------------------
 
-   /**
-    * Check that the correct marshallers have been registered with the MarshalFactory.
-    * This is only done once.
-    */
-   private synchronized void checkMarshallers()
-   {
-      if (checked)
-      {
-         return;
-      }
-
-      checked = true;
-   }
-
-   // Inner classes -------------------------------------------------
-
 }

Added: trunk/src/main/org/jboss/jms/client/delegate/Initializable.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/delegate/Initializable.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/delegate/Initializable.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,24 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.client.delegate;
+
+/**
+ * Applies to delegates.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision$</tt>
+ *
+ * $Id$
+ */
+public interface Initializable
+{
+   /**
+    * Usually add the delegate itself as the last invoking interceptor in the stack, and prepare
+    * the stack for invocations.
+    */
+   void init();
+}

Modified: trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/remoting/CallbackManager.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -40,8 +40,8 @@
  * The CallbackManager is an InvocationHandler used for handling callbacks to message consumers.
  * The callback is received and dispatched off to the relevant consumer.
  * 
- * There is one instance of this class per remoting connection - which is to a unique server - therefore
- * there is no need to add the server id to the key when doing look ups
+ * There is one instance of this class per remoting connection - which is to a unique server -
+ * therefore there is no need to add the server id to the key when doing look ups.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="ovidiu at jboss.org">Ovidiu Feodorov</a>
@@ -51,13 +51,13 @@
  */
 public class CallbackManager implements InvokerCallbackHandler
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
    protected static final Logger log;
 
    public static final String JMS_CALLBACK_SUBSYSTEM = "CALLBACK";
 
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
 
    protected static CallbackManager theManager;
    
@@ -69,19 +69,19 @@
       trace = log.isTraceEnabled();
    }
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
    // Map<Long(lookup)-MessageCallbackHandler>
    protected Map callbackHandlers;
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
    public CallbackManager()
    {
       callbackHandlers = new ConcurrentReaderHashMap();
    }
 
-   // InvokerCallbackHandler implementation -------------------------
+   // InvokerCallbackHandler implementation --------------------------------------------------------
 
    public void handleCallback(Callback callback) throws HandleCallbackException
    {
@@ -89,7 +89,8 @@
       ClientDelivery dr = (ClientDelivery)mm.getLoad();
       MessageProxy msg = dr.getMessage();
 
-      MessageCallbackHandler handler = (MessageCallbackHandler)callbackHandlers.get(new Integer(dr.getConsumerId()));
+      MessageCallbackHandler handler =
+         (MessageCallbackHandler)callbackHandlers.get(new Integer(dr.getConsumerId()));
 
       if (handler == null)
       {
@@ -103,7 +104,7 @@
       handler.handleMessage(msg);
    }
 
-   // Public --------------------------------------------------------
+   // Public ---------------------------------------------------------------------------------------
 
    public void registerHandler(int consumerID, MessageCallbackHandler handler)
    {
@@ -115,12 +116,12 @@
       return (MessageCallbackHandler)callbackHandlers.remove(new Integer(consumerID));
    }
 
-   // Package protected ---------------------------------------------
+   // Package protected ----------------------------------------------------------------------------
 
-   // Protected -----------------------------------------------------
+   // Protected ------------------------------------------------------------------------------------
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   // Inner classes -------------------------------------------------
+   // Inner classes --------------------------------------------------------------------------------
 
 }

Modified: trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/remoting/ConsolidatedRemotingConnectionListener.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -79,7 +79,7 @@
 
          try
          {
-            log.debug(this + " forwarding remoting failure " + throwable + " to " + l);
+            log.debug(this + " forwarding remoting failure \"" + throwable + "\" to " + l);
             l.handleConnectionException(throwable, client);
          }
          catch(Exception e)
@@ -154,9 +154,9 @@
    {
       if (state == null)
       {
-         return "ConsolidatedRemotingConnectionListener(UNINITIALIZED)";
+         return "ConsolidatedListener(UNINITIALIZED)";
       }
-      return state + ".ConsolidatedRemotingConnectionListener";
+      return state + ".ConsolidatedListener";
    }
 
    // Package protected ---------------------------------------------

Modified: trunk/src/main/org/jboss/jms/client/state/BrowserState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/BrowserState.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -53,6 +53,10 @@
       this.messageSelector=selector;
    }
 
+   public void synchronizeWith(HierarchicalState newState) throws Exception {
+      //To change body of implemented methods use File | Settings | File Templates.
+   }
+   
    public DelegateSupport getDelegate()
    {
       return (DelegateSupport)delegate;

Modified: trunk/src/main/org/jboss/jms/client/state/ConnectionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/ConnectionState.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -22,12 +22,19 @@
 package org.jboss.jms.client.state;
 
 import java.util.HashSet;
+import java.util.List;
+import java.util.ArrayList;
+import java.util.Iterator;
 
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.remoting.ConsolidatedRemotingConnectionListener;
+import org.jboss.jms.client.FailoverEvent;
+import org.jboss.jms.client.FailoverListener;
 import org.jboss.jms.delegate.ConnectionDelegate;
+import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.jms.message.MessageIdGenerator;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.tx.ResourceManager;
@@ -43,41 +50,55 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ *
  * @version <tt>$Revision$</tt>
  *
  * $Id$
  */
 public class ConnectionState extends HierarchicalStateSupport
 {
+   // Constants ------------------------------------------------------------------------------------
+
    private static final Logger log = Logger.getLogger(ConnectionState.class);
 
-   private JMSRemotingConnection remotingConnection;
+   // Static ---------------------------------------------------------------------------------------
 
-   private ConsolidatedRemotingConnectionListener remotingConnectionListener;
+   private static boolean trace = log.isTraceEnabled();
 
-   private ResourceManager resourceManager;
+   // Attributes -----------------------------------------------------------------------------------
 
-   private MessageIdGenerator idGenerator;
-
    private int serverID;
 
    private Version versionToUse;
 
    private ConnectionDelegate delegate;
 
-   // This is filled from and for the HA interceptors only
-   private transient String user;
+   protected boolean started;
 
-   // This is filled from and for the HA interceptors only
+   private boolean justCreated = true;
+
+   private String clientID;
+
+   private JMSRemotingConnection remotingConnection;
+   private ConsolidatedRemotingConnectionListener remotingConnectionListener;
+   private ResourceManager resourceManager;
+   private MessageIdGenerator idGenerator;
+
+   // Cached by the connection state in case ClusteringAspect needs to re-try establishing
+   // connection on a different node
+   private transient String username;
+
+   // Cached by the connection state in case ClusteringAspect needs to re-try establishing
+   // connection on a different node
    private transient String password;
 
-   protected boolean started;
+   private List failoverListeners;
 
-   /** This property used to be delcared on ConnectionAspect */
-   private String clientID;
+   // needed to try re-creating connection in case failure is detected on the current connection
+   private ConnectionFactoryDelegate clusteredConnectionFactoryDelegate;
 
-    /** This property used to be delcared on ConnectionAspect */
-   private boolean justCreated = true;
+   // Constructors ---------------------------------------------------------------------------------
 
    public ConnectionState(int serverID, ConnectionDelegate delegate,
                           JMSRemotingConnection remotingConnection,
@@ -99,32 +120,37 @@
       remotingConnectionListener.setConnectionState(this);
 
       // Each connection has its own resource manager. If we can failover all connections with the
-      // same server id at the same time then we can maintain one rm per unique server as opposed to
-      // per connection.
+      // same server id at the same time then we can maintain one rm per unique server as opposed
+      // to per connection.
       this.resourceManager = ResourceManagerFactory.instance.checkOutResourceManager(serverID);
 
       this.idGenerator = gen;
       this.serverID = serverID;
+
+      failoverListeners = new ArrayList();
    }
 
-   public ResourceManager getResourceManager()
+   // HierarchicalState implementation -------------------------------------------------------------
+
+   public DelegateSupport getDelegate()
    {
-      return resourceManager;
+      return (DelegateSupport) delegate;
    }
 
-   public MessageIdGenerator getIdGenerator()
+   public void setDelegate(DelegateSupport delegate)
    {
-      return idGenerator;
+      this.delegate = (ConnectionDelegate) delegate;
    }
 
-   public JMSRemotingConnection getRemotingConnection()
+   public HierarchicalState getParent()
    {
-      return remotingConnection;
+      // A connection doesn't have a parent
+      return null;
    }
 
-   public ConsolidatedRemotingConnectionListener getRemotingConnectionListener()
+   public void setParent(HierarchicalState parent)
    {
-      return remotingConnectionListener;
+      // noop - a connection doesn't have a parent
    }
 
    public Version getVersionToUse()
@@ -132,28 +158,62 @@
       return versionToUse;
    }
 
-   public int getServerID()
+   public void synchronizeWith(HierarchicalState ns) throws Exception
    {
-      return serverID;
+      ConnectionState newState = (ConnectionState)ns;
+
+      remotingConnection = newState.remotingConnection;
+      idGenerator = newState.idGenerator;
+      serverID = newState.serverID;
+      versionToUse = newState.versionToUse;
+
+      // I removed this due to http://jira.jboss.com/jira/browse/JBMESSAGING-686
+      //this.delegate = newState.delegate;
+
+      ConnectionDelegate newDelegate = (ConnectionDelegate)newState.getDelegate();
+
+      for(Iterator i = getChildren().iterator(); i.hasNext(); )
+      {
+         SessionState sessionState = (SessionState)i.next();
+         ClientSessionDelegate sessionDelegate = (ClientSessionDelegate)sessionState.getDelegate();
+
+         // create a new session on the new connection for each session on the old connection
+         ClientSessionDelegate newSessionDelegate = (ClientSessionDelegate)newDelegate.
+            createSessionDelegate(sessionState.isTransacted(),
+                                  sessionState.getAcknowledgeMode(),
+                                  sessionState.isXA());
+
+         sessionDelegate.synchronizeWith(newSessionDelegate);
+      }
    }
 
-   public DelegateSupport getDelegate()
+   // Public ---------------------------------------------------------------------------------------
+
+   public ResourceManager getResourceManager()
    {
-      return (DelegateSupport) delegate;
+      return resourceManager;
    }
 
-   public void setDelegate(DelegateSupport delegate)
+   public MessageIdGenerator getIdGenerator()
    {
-      this.delegate = (ConnectionDelegate) delegate;
+      return idGenerator;
    }
 
-   /**
-    * Connection doesn't have a parent
-    */
-   public void setParent(HierarchicalState parent)
+   public JMSRemotingConnection getRemotingConnection()
    {
+      return remotingConnection;
    }
 
+   public ConsolidatedRemotingConnectionListener getRemotingConnectionListener()
+   {
+      return remotingConnectionListener;
+   }
+
+   public int getServerID()
+   {
+      return serverID;
+   }
+
    public boolean isStarted()
    {
       return started;
@@ -174,14 +234,14 @@
       this.password = password;
    }
 
-   public String getUser()
+   public String getUsername()
    {
-      return user;
+      return username;
    }
 
-   public void setUser(String user)
+   public void setUsername(String username)
    {
-      this.user = user;
+      this.username = username;
    }
 
    public String getClientID()
@@ -204,29 +264,69 @@
       this.justCreated = justCreated;
    }
 
-   /**
-    * Connection doesn't have a parent
-    */
-   public HierarchicalState getParent()
+   public void broadcastFailoverEvent(FailoverEvent e)
    {
-      return null;
+      if (trace) { log.trace(this + " broadcasting " + e); }
+
+      List listenersCopy;
+
+      synchronized(failoverListeners)
+      {
+         listenersCopy = new ArrayList(failoverListeners);
+      }
+
+      for(Iterator i = listenersCopy.iterator(); i.hasNext(); )
+      {
+         FailoverListener listener = (FailoverListener)i.next();
+
+         try
+         {
+            listener.failoverEventOccured(e);
+         }
+         catch(Exception ex)
+         {
+            log.warn("Failover listener " + listener + " did not accept event", ex);
+         }
+      }
    }
 
-   //When failing over a connection, we keep the old connection's state but there are certain fields
-   //we need to update
-   public void copyState(ConnectionState newState)
+   public void registerFailoverListener(FailoverListener listener)
    {
-      this.remotingConnection = newState.remotingConnection;
-      this.idGenerator = newState.idGenerator;
-      this.serverID = newState.serverID;
-      this.versionToUse = newState.versionToUse;
+      synchronized(failoverListeners)
+      {
+         failoverListeners.add(listener);
+      }
+   }
 
-      // I removed this due to http://jira.jboss.com/jira/browse/JBMESSAGING-686
-      //this.delegate = newState.delegate;
+   public boolean unregisterFailoverListener(FailoverListener listener)
+   {
+      synchronized(failoverListeners)
+      {
+         return failoverListeners.remove(listener);
+      }
    }
 
+   public void setClusteredConnectionFactoryDeleage(ConnectionFactoryDelegate d)
+   {
+      this.clusteredConnectionFactoryDelegate = d;
+   }
+
+   public ConnectionFactoryDelegate getClusteredConnectionFactoryDelegate()
+   {
+      return clusteredConnectionFactoryDelegate;
+   }
+
    public String toString()
    {
       return "ConnectionState[" + ((ClientConnectionDelegate)delegate).getID() + "]";
    }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   // Inner classes --------------------------------------------------------------------------------
+
 }

Modified: trunk/src/main/org/jboss/jms/client/state/ConsumerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/ConsumerState.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -134,6 +134,10 @@
       return parent.getVersionToUse();
    }
 
+   public void synchronizeWith(HierarchicalState newState) throws Exception {
+      //To change body of implemented methods use File | Settings | File Templates.
+   }
+
    public int getBufferSize()
    {
       return bufferSize;

Modified: trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/HierarchicalState.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -32,6 +32,7 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
  *
  * $Id$
@@ -49,4 +50,22 @@
    void setParent(HierarchicalState parent);
 
    Version getVersionToUse();
+
+   /**
+    * Closes children's failover valves, by sending closeValve() invocations down children's
+    * delegate stack. It is NOT intended to be recursive, unless the children chose so.
+    */
+   void closeChildrensValves() throws Exception;
+
+   /**
+    * Opens children's failover valves, by sending openValve() invocations down children's
+    * delegate stack. It is NOT intended to be recursive, unless the children chose so.
+    */
+   void openChildrensValves() throws Exception;
+
+   /**
+    * Update my own state based on the new state.
+    */
+   void synchronizeWith(HierarchicalState newState) throws Exception;
+
 }

Modified: trunk/src/main/org/jboss/jms/client/state/HierarchicalStateSupport.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/HierarchicalStateSupport.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/HierarchicalStateSupport.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -22,11 +22,12 @@
 package org.jboss.jms.client.state;
 
 import java.util.Set;
+import java.util.Iterator;
 
 import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.Valve;
 
 /**
- * 
  * Base implementation of HierarchicalState.
  * 
  * State is created and maintained by the StateCreationAspect. The state is placed in the meta data
@@ -36,48 +37,80 @@
  * 
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @author <a href="mailto:clebert.suconic at jboss.com">Clebert Suconic</a>
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ *
  * @version <tt>$Revision$</tt>
  *
  * $Id$
  */
 public abstract class HierarchicalStateSupport implements HierarchicalState
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
+   // Set<HierarchicalState>
    protected Set children;
 
+   // Static ---------------------------------------------------------------------------------------
 
-   // Static --------------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
-   // Constructors --------------------------------------------------
-
    public HierarchicalStateSupport(HierarchicalState parent, DelegateSupport delegate)
    {
-      this.setParent(parent);
-      this.setDelegate(delegate); // TODO - find a more elegant solution, delegate must implement an interface that has getID()
+      setParent(parent);
+      setDelegate(delegate); // TODO - find a more elegant solution, delegate must implement an interface that has getID()
       if (parent != null)
       {
          parent.getChildren().add(this);
       }
    }
 
-   // HierarchicalState implementation -------------------------------
+   // HierarchicalState implementation -------------------------------------------------------------
 
+   /**
+    * @return Set<HierarchicalState>
+    */
    public Set getChildren()
    {
       return children;
    }
 
+   public void closeChildrensValves() throws Exception
+   {
+      if (children == null)
+      {
+         return;
+      }
 
-   // Public --------------------------------------------------------
+      for(Iterator i = children.iterator(); i.hasNext(); )
+      {
+         HierarchicalState s = (HierarchicalState)i.next();
+         ((Valve)s.getDelegate()).closeValve();
+      }
+   }
 
-   // Protected ------------------------------------------------------
+   public void openChildrensValves() throws Exception
+   {
+      if (children == null)
+      {
+         return;
+      }
 
-   // Package Private ------------------------------------------------
+      for(Iterator i = children.iterator(); i.hasNext(); )
+      {
+         HierarchicalState s = (HierarchicalState)i.next();
+         ((Valve)s.getDelegate()).openValve();
+      }
+   }
 
-   // Private --------------------------------------------------------
+   // Public ---------------------------------------------------------------------------------------
 
-   // Inner Classes --------------------------------------------------
+   // Protected ------------------------------------------------------------------------------------
+
+   // Package Private ------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   // Inner Classes --------------------------------------------------------------------------------
 }

Modified: trunk/src/main/org/jboss/jms/client/state/ProducerState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/ProducerState.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/ProducerState.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -63,6 +63,10 @@
       children = Collections.EMPTY_SET;
       this.destination = dest;
    }
+
+   public void synchronizeWith(HierarchicalState newState) throws Exception {
+      //To change body of implemented methods use File | Settings | File Templates.
+   }
    
    public Destination getDestination()
    {

Modified: trunk/src/main/org/jboss/jms/client/state/SessionState.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/client/state/SessionState.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -26,19 +26,31 @@
 import java.util.HashSet;
 import java.util.List;
 import java.util.Map;
+import java.util.Iterator;
+import java.util.Collections;
 
 import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.delegate.ClientConnectionDelegate;
+import org.jboss.jms.client.delegate.ClientConsumerDelegate;
+import org.jboss.jms.client.delegate.ClientProducerDelegate;
+import org.jboss.jms.client.delegate.ClientBrowserDelegate;
 import org.jboss.jms.client.remoting.MessageCallbackHandler;
+import org.jboss.jms.client.remoting.CallbackManager;
 import org.jboss.jms.delegate.SessionDelegate;
 import org.jboss.jms.server.Version;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
+import org.jboss.jms.server.endpoint.DeliveryRecovery;
 import org.jboss.jms.tx.MessagingXAResource;
+import org.jboss.jms.tx.ResourceManager;
+import org.jboss.jms.destination.JBossDestination;
 import org.jboss.logging.Logger;
 
 import EDU.oswego.cs.dl.util.concurrent.LinkedQueue;
 import EDU.oswego.cs.dl.util.concurrent.QueuedExecutor;
 
+import javax.jms.Session;
+
 /**
  * State corresponding to a session. This state is acessible inside aspects/interceptors.
  * 
@@ -50,97 +62,230 @@
  */
 public class SessionState extends HierarchicalStateSupport
 {
+
+   // Constants ------------------------------------------------------------------------------------
+
    protected static Logger log = Logger.getLogger(SessionState.class);
 
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   private ConnectionState parent;
+   private SessionDelegate delegate;
+
    private int sessionId;
-   
    private int acknowledgeMode;
-   
    private boolean transacted;
-   
    private boolean xa;
-   
+
    private MessagingXAResource xaResource;
-   
    private Object currentTxId;
-   
+
    // Executor used for executing onMessage methods
    private QueuedExecutor executor;
-   
+
    private boolean recoverCalled;
 
    // List<DeliveryInfo>
    private List clientAckList;
-   
+
    // List<DeliveryInfo>
    //private List clientCancelList;
    
    private DeliveryInfo autoAckInfo;
+   private Map callbackHandlers;
 
-   private ConnectionState parent;
-   
-   private SessionDelegate delegate;
-   
-   private Map callbackHandlers;     
-   
+
+   // Constructors ---------------------------------------------------------------------------------
+
    public SessionState(ConnectionState parent, ClientSessionDelegate delegate,
                        boolean transacted, int ackMode, boolean xa)
    {
       super(parent, (DelegateSupport)delegate);
-      
+
       this.sessionId = delegate.getID();
-      
+
       children = new HashSet();
       this.acknowledgeMode = ackMode;
       this.transacted = transacted;
       this.xa = xa;
-      
+
       if (xa)
       {
          // Create an XA resource
-         xaResource = new MessagingXAResource(parent.getResourceManager(), this);                            
+         xaResource = new MessagingXAResource(parent.getResourceManager(), this);
       }
-      
+
       // If session is transacted and XA, the currentTxId will be updated when the XAResource will
       // be enrolled with a global transaction.
-      
+
       if (transacted & !xa)
       {
          // Create a local tx
-         currentTxId = parent.getResourceManager().createLocalTx();        
+         currentTxId = parent.getResourceManager().createLocalTx();
       }
-      
+
       executor = new QueuedExecutor(new LinkedQueue());
-      
+
       clientAckList = new ArrayList();
-      
+
      // clientCancelList = new ArrayList();
       
       // TODO could optimise this to use the same map of callbackmanagers (which holds refs
       // to callbackhandlers) in the connection, instead of maintaining another map
       callbackHandlers = new HashMap();
    }
-   
-   
-   public void setParent(HierarchicalState parent)
+
+
+   // HierarchicalState implementation -------------------------------------------------------------
+
+   public DelegateSupport getDelegate()
    {
-      this.parent = (ConnectionState)parent;
+      return (DelegateSupport)delegate;
    }
+
+   public void setDelegate(DelegateSupport delegate)
+   {
+      this.delegate = (SessionDelegate)delegate;
+   }
+
    public HierarchicalState getParent()
    {
       return parent;
    }
-   
-   public DelegateSupport getDelegate()
+
+   public void setParent(HierarchicalState parent)
    {
-      return (DelegateSupport)delegate;
+      this.parent = (ConnectionState)parent;
    }
-   
-   public void setDelegate(DelegateSupport delegate)
+
+   public Version getVersionToUse()
    {
-      this.delegate=(SessionDelegate)delegate;
+      return parent.getVersionToUse();
    }
-      
+
+   // HierarchicalStateSupport overrides -----------------------------------------------------------
+
+   public void synchronizeWith(HierarchicalState ns) throws Exception
+   {
+      SessionState newState = (SessionState)ns;
+
+      int oldSessionID = sessionId;
+      sessionId = newState.sessionId;
+
+      ClientSessionDelegate newDelegate = (ClientSessionDelegate)newState.getDelegate();
+
+      for (Iterator i = getChildren().iterator(); i.hasNext(); )
+      {
+         HierarchicalState child = (HierarchicalState)i.next();
+
+         if (child instanceof ProducerState)
+         {
+            handleFailoverOnProducer((ProducerState)child, newDelegate);
+         }
+         else if (child instanceof ConsumerState)
+         {
+            handleFailoverOnConsumer((ClientConnectionDelegate)getParent().getDelegate(),
+                                     (ConsumerState)child, newDelegate);
+         }
+         else if (child instanceof BrowserState)
+         {
+             handleFailoverOnBrowser((BrowserState)child, newDelegate);
+         }
+      }
+
+      ConnectionState connState = (ConnectionState)getParent();
+      ResourceManager rm = connState.getResourceManager();
+
+      // We need to failover from one session ID to another in the resource manager
+      rm.handleFailover(connState.getServerID(), oldSessionID, newState.sessionId);
+
+      List ackInfos = Collections.EMPTY_LIST;
+
+      if (!isTransacted() || (isXA() && getCurrentTxId() == null))
+      {
+         // Non transacted session or an XA session with no transaction set (it falls back
+         // to auto_ack)
+
+         log.debug(this + " is not transacted (or XA with no tx set), " +
+            "retrieving deliveries from session state");
+
+         // We remove any unacked non-persistent messages - this is because we don't want to ack
+         // them since the server won't know about them and will get confused
+
+         if (getAcknowledgeMode() == Session.CLIENT_ACKNOWLEDGE)
+         {
+            for(Iterator i = getClientAckList().iterator(); i.hasNext(); )
+            {
+               DeliveryInfo info = (DeliveryInfo)i.next();
+               if (!info.getMessageProxy().getMessage().isReliable())
+               {
+                  i.remove();
+                  log.debug("removed non persistent delivery " + info);
+               }
+            }
+
+            ackInfos = getClientAckList();
+         }
+         else
+         {
+            DeliveryInfo autoAck = getAutoAckInfo();
+            if (autoAck != null)
+            {
+               if (!autoAck.getMessageProxy().getMessage().isReliable())
+               {
+                  // unreliable, discard
+                  setAutoAckInfo(null);
+               }
+               else
+               {
+                  // reliable
+                  ackInfos = new ArrayList();
+                  ackInfos.add(autoAck);
+               }
+            }
+         }
+
+         log.debug(this + " retrieved " + ackInfos.size() + " deliveries");
+      }
+      else
+      {
+         // Transacted session - we need to get the acks from the resource manager. BTW we have
+         // kept the old resource manager
+
+         ackInfos = rm.getDeliveriesForSession(getSessionId());
+      }
+
+      if (!ackInfos.isEmpty())
+      {
+         SessionDelegate nd = (SessionDelegate)getDelegate();
+
+         List recoveryInfos = new ArrayList();
+
+         for (Iterator i = ackInfos.iterator(); i.hasNext(); )
+         {
+            DeliveryInfo info = (DeliveryInfo)i.next();
+
+            DeliveryRecovery recInfo =
+               new DeliveryRecovery(info.getMessageProxy().getDeliveryId(),
+                                    info.getMessageProxy().getMessage().getMessageID(),
+                                    info.getChannelId());
+
+            recoveryInfos.add(recInfo);
+         }
+
+         log.debug(this + " sending delivery recovery info: " + recoveryInfos);
+         nd.recoverDeliveries(recoveryInfos);
+      }
+      else
+      {
+         log.debug(this + " no delivery recovery info to send");
+      }
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
    /**
     * @return List<AckInfo>
     */
@@ -148,12 +293,12 @@
    {
       return clientAckList;
    }
-   
+
    public DeliveryInfo getAutoAckInfo()
    {
       return autoAckInfo;
    }
-   
+
    public void setAutoAckInfo(DeliveryInfo info)
    {
       if (info != null && autoAckInfo != null)
@@ -162,82 +307,198 @@
       }
       autoAckInfo = info;
    }
-   
+
    public int getAcknowledgeMode()
    {
       return acknowledgeMode;
    }
-   
+
    public boolean isTransacted()
    {
       return transacted;
    }
-   
+
    public boolean isXA()
    {
       return xa;
    }
-   
+
    public MessagingXAResource getXAResource()
    {
       return xaResource;
    }
-   
+
    public QueuedExecutor getExecutor()
    {
       return executor;
    }
-   
+
    public Object getCurrentTxId()
    {
       return currentTxId;
    }
-   
+
    public boolean isRecoverCalled()
    {
       return recoverCalled;
    }
-   
+
    public void setCurrentTxId(Object id)
    {
       this.currentTxId = id;
    }
-   
-   public Version getVersionToUse()
-   {
-      return parent.getVersionToUse();
-   }
-   
+
    public void setRecoverCalled(boolean recoverCalled)
    {
       this.recoverCalled = recoverCalled;
    }
-   
+
    public MessageCallbackHandler getCallbackHandler(int consumerID)
    {
       return (MessageCallbackHandler)callbackHandlers.get(new Integer(consumerID));
    }
-   
+
    public void addCallbackHandler(MessageCallbackHandler handler)
    {
       callbackHandlers.put(new Integer(handler.getConsumerId()), handler);
    }
-   
+
    public void removeCallbackHandler(MessageCallbackHandler handler)
    {
       callbackHandlers.remove(new Integer(handler.getConsumerId()));
    }
-      
+
    public int getSessionId()
    {
       return sessionId;
    }
-   
-   // When failing over a session, we keep the old session's state but there are certain fields
-   // we need to update
-   public void copyState(SessionState newState)
-   {       
-      this.sessionId = newState.sessionId;
+
+   public String toString()
+   {
+      return "SessionState[" + sessionId + "]";
    }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   /**
+    * TODO See http://jira.jboss.org/jira/browse/JBMESSAGING-708
+    */
+   private void handleFailoverOnConsumer(ClientConnectionDelegate failedConnectionDelegate,
+                                         ConsumerState failedConsumerState,
+                                         ClientSessionDelegate newSessionDelegate)
+
+      throws Exception
+   {
+      log.debug(this + " failing over consumer " + failedConsumerState);
+
+      CallbackManager oldCallbackManager =
+         failedConnectionDelegate.getRemotingConnection().getCallbackManager();
+
+      ClientConsumerDelegate failedConsumerDelegate =
+         (ClientConsumerDelegate)failedConsumerState.getDelegate();
+
+      log.debug(this + " creating alternate consumer");
+
+      ClientConsumerDelegate newConsumerDelegate = (ClientConsumerDelegate)newSessionDelegate.
+         createConsumerDelegate((JBossDestination)failedConsumerState.getDestination(),
+                                failedConsumerState.getSelector(),
+                                failedConsumerState.isNoLocal(),
+                                failedConsumerState.getSubscriptionName(),
+                                failedConsumerState.isConnectionConsumer(),
+                                failedConsumerState.getChannelId());
+
+      log.debug(this + " alternate consumer created");
+
+      // Copy the attributes from the new consumer to the old consumer
+      failedConsumerDelegate.synchronizeWith(newConsumerDelegate);
+
+      ConsumerState newState = (ConsumerState)newConsumerDelegate.getState();
+
+      int oldConsumerID = failedConsumerState.getConsumerID();
+
+      // Update attributes on the old state
+      failedConsumerState.copyState(newState);
+
+      // We need to re-use the existing message callback handler
+
+      MessageCallbackHandler oldHandler =
+         oldCallbackManager.unregisterHandler(oldConsumerID);
+
+      ConnectionState newConnectionState = (ConnectionState)failedConnectionDelegate.getState();
+
+      CallbackManager newCallbackManager =
+         newConnectionState.getRemotingConnection().getCallbackManager();
+
+      // Remove the new handler
+      MessageCallbackHandler newHandler = newCallbackManager.
+         unregisterHandler(newState.getConsumerID());
+
+      log.debug("New handler is " + System.identityHashCode(newHandler));
+
+      //But we need to update some fields from the new one
+      oldHandler.copyState(newHandler);
+
+      //Now we re-register the old handler with the new callback manager
+
+      newCallbackManager.registerHandler(newState.getConsumerID(),
+                                         oldHandler);
+
+      // We don't need to add the handler to the session state since it is already there - we
+      // are re-using the old handler
+
+      log.debug(this + " failed over consumer");
+   }
+
+
+   /**
+    * TODO see http://jira.jboss.org/jira/browse/JBMESSAGING-709
+    */
+   private void handleFailoverOnProducer(ProducerState failedProducerState,
+                                         ClientSessionDelegate failedSessionDelegate)
+      throws Exception
+   {
+      ClientProducerDelegate newProducerDelegate = (ClientProducerDelegate)failedSessionDelegate.
+         createProducerDelegate((JBossDestination)failedProducerState.getDestination());
+
+      ClientProducerDelegate failedProducerDelegate =
+         (ClientProducerDelegate)failedProducerState.getDelegate();
+
+      failedProducerDelegate.synchronizeWith(newProducerDelegate);
+      failedProducerState.copyState((ProducerState)newProducerDelegate.getState());
+
+      log.debug("handling fail over on producerDelegate " + failedProducerDelegate + " destination=" + failedProducerState.getDestination());
+   }
+
+
+   /**
+    * TODO see http://jira.jboss.org/jira/browse/JBMESSAGING-710
+    */
+   private void handleFailoverOnBrowser(BrowserState failedBrowserState,
+                                        ClientSessionDelegate failedSessionDelegate)
+      throws Exception
+   {
+      ClientBrowserDelegate newBrowserDelegate = (ClientBrowserDelegate)failedSessionDelegate.
+         createBrowserDelegate(failedBrowserState.getJmsDestination(),
+                               failedBrowserState.getMessageSelector());
+
+      ClientBrowserDelegate failedBrowserDelegate =
+         (ClientBrowserDelegate)failedBrowserState.getDelegate();
+
+      failedBrowserDelegate.synchronizeWith(newBrowserDelegate);
+      failedBrowserState.copyState((BrowserState)newBrowserDelegate.getState());
+
+      log.debug("handling fail over on browserDelegate " + failedBrowserDelegate + " destination=" + failedBrowserState.getJmsDestination() + " selector=" + failedBrowserState.getMessageSelector());
+
+   }
+
+
+   // Inner classes --------------------------------------------------------------------------------
+
+
+
 }
 

Modified: trunk/src/main/org/jboss/jms/delegate/BrowserDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/BrowserDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/delegate/BrowserDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -22,6 +22,7 @@
 package org.jboss.jms.delegate;
 
 import org.jboss.jms.server.endpoint.BrowserEndpoint;
+import org.jboss.jms.client.Valve;
 
 /**
  * Represents the minimal set of operations to provide browser
@@ -32,8 +33,8 @@
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision$</tt>
  */
-public interface BrowserDelegate extends BrowserEndpoint
-{   
+public interface BrowserDelegate extends Valve, BrowserEndpoint
+{
 }
    
 

Modified: trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/delegate/ConnectionDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -28,6 +28,8 @@
 import javax.jms.ServerSessionPool;
 
 import org.jboss.jms.client.JBossConnectionConsumer;
+import org.jboss.jms.client.FailoverListener;
+import org.jboss.jms.client.Valve;
 import org.jboss.jms.server.endpoint.ConnectionEndpoint;
 
 /**
@@ -40,7 +42,7 @@
  *
  * $Id$
  */
-public interface ConnectionDelegate extends ConnectionEndpoint
+public interface ConnectionDelegate extends Valve, ConnectionEndpoint
 {      
    ExceptionListener getExceptionListener() throws JMSException;
    
@@ -53,4 +55,10 @@
                                                     String messageSelector,
                                                     ServerSessionPool sessionPool,
                                                     int maxMessages) throws JMSException;
+
+   void registerFailoverListener(FailoverListener failoverListener);
+   boolean unregisterFailoverListener(FailoverListener failoverListener);
+
+   void performFailover() throws Exception;
+
 }

Modified: trunk/src/main/org/jboss/jms/delegate/ConnectionFactoryDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/ConnectionFactoryDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/delegate/ConnectionFactoryDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -22,6 +22,7 @@
 package org.jboss.jms.delegate;
 
 import org.jboss.jms.server.endpoint.ConnectionFactoryEndpoint;
+import org.jboss.jms.client.ClientAOPStackProvider;
 
 /**
  * Represents the minimal set of operations to provide connection factory
@@ -33,6 +34,6 @@
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision$</tt>
  */
-public interface ConnectionFactoryDelegate extends ConnectionFactoryEndpoint
+public interface ConnectionFactoryDelegate extends ClientAOPStackProvider, ConnectionFactoryEndpoint
 {
 }

Modified: trunk/src/main/org/jboss/jms/delegate/ConsumerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/ConsumerDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/delegate/ConsumerDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -27,6 +27,7 @@
 
 import org.jboss.jms.destination.JBossDestination;
 import org.jboss.jms.server.endpoint.ConsumerEndpoint;
+import org.jboss.jms.client.Valve;
 
 /**
  * Represents the minimal set of operations to provide consumer
@@ -40,17 +41,17 @@
  *
  * $Id$
  */
-public interface ConsumerDelegate extends ConsumerEndpoint
+public interface ConsumerDelegate extends Valve, ConsumerEndpoint
 {
    MessageListener getMessageListener();
-   
+
    void setMessageListener(MessageListener listener);
-   
+
    JBossDestination getDestination();
-   
+
    boolean getNoLocal();
-   
-   String getMessageSelector();   
-   
+
+   String getMessageSelector();
+
    Message receive(long timeout) throws JMSException;
 }

Modified: trunk/src/main/org/jboss/jms/delegate/ProducerDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/ProducerDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/delegate/ProducerDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -25,6 +25,7 @@
 import javax.jms.Message;
 
 import org.jboss.jms.client.Closeable;
+import org.jboss.jms.client.Valve;
 import org.jboss.jms.destination.JBossDestination;
 
 /**
@@ -34,7 +35,7 @@
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version <tt>$Revision$</tt>
  */
-public interface ProducerDelegate extends Closeable
+public interface ProducerDelegate extends Valve, Closeable
 {
    void setDisableMessageID(boolean value) throws JMSException;
    

Modified: trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java
===================================================================
--- trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/delegate/SessionDelegate.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -37,6 +37,7 @@
 import org.jboss.jms.message.TextMessageProxy;
 import org.jboss.jms.server.endpoint.DeliveryInfo;
 import org.jboss.jms.server.endpoint.SessionEndpoint;
+import org.jboss.jms.client.Valve;
 
 /**
  * Represents the minimal set of operations to provide session functionality.
@@ -48,12 +49,12 @@
  *
  * $Id$
  */
-public interface SessionDelegate extends SessionEndpoint
-{   
+public interface SessionDelegate extends Valve, SessionEndpoint
+{
    MessageProxy createMessage() throws JMSException;
-   
+
    BytesMessageProxy createBytesMessage() throws JMSException;
-  
+
    MapMessageProxy createMapMessage() throws JMSException;
 
    ObjectMessageProxy createObjectMessage() throws JMSException;
@@ -63,37 +64,37 @@
    StreamMessageProxy createStreamMessage() throws JMSException;
 
    TextMessageProxy createTextMessage() throws JMSException;
-   
+
    TextMessageProxy createTextMessage(String text) throws JMSException;
-   
+
    void preDeliver(DeliveryInfo deliveryInfo) throws JMSException;
-   
+
    void postDeliver() throws JMSException;
-   
+
    MessageListener getMessageListener() throws JMSException;
-   
+
    void setMessageListener(MessageListener listener) throws JMSException;
-   
+
    void run();
-   
+
    XAResource getXAResource();
-   
+
    void addAsfMessage(MessageProxy m, int consumerID, long channelID,
                       int maxDeliveries, SessionDelegate connectionConsumerDelegate);
-   
+
    boolean getTransacted();
-   
+
    int getAcknowledgeMode();
-   
+
    void commit() throws JMSException;
-   
+
    void rollback() throws JMSException;
-   
+
    void recover() throws JMSException;
-   
+
    void redeliver(List deliveryInfos) throws JMSException;
-   
+
    ProducerDelegate createProducerDelegate(JBossDestination destination) throws JMSException;
-   
+
    void acknowledgeAll() throws JMSException;
 }

Modified: trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/ConnectionFactoryManager.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -36,8 +36,6 @@
    /**
     * @param jndiBindings - if null, the connection factory will be created and registered with the
     *        AOP subsystem, but not bound in JNDI.
-    *
-    * @return an identifier that uniques identifies the registered ConnectionFactory.
     */
    void registerConnectionFactory(String uniqueName, String clientID, JNDIBindings jndiBindings,
                                  String locatorURI, boolean clientPing,

Modified: trunk/src/main/org/jboss/jms/server/ServerPeer.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/ServerPeer.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -40,11 +40,14 @@
 import org.jboss.jms.server.connectormanager.SimpleConnectorManager;
 import org.jboss.jms.server.destination.ManagedQueue;
 import org.jboss.jms.server.endpoint.ServerSessionEndpoint;
+import org.jboss.jms.server.endpoint.advised.ClientAOPStackProviderAdvised;
 import org.jboss.jms.server.plugin.contract.JMSUserManager;
 import org.jboss.jms.server.remoting.JMSServerInvocationHandler;
 import org.jboss.jms.server.remoting.JMSWireFormat;
+import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.server.security.SecurityMetadataStore;
 import org.jboss.jms.util.ExceptionUtil;
+import org.jboss.jms.client.ClientAOPStackProvider;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.Queue;
 import org.jboss.messaging.core.memory.MemoryManager;
@@ -81,7 +84,7 @@
  *
  * $Id$
  */
-public class ServerPeer extends ServiceMBeanSupport
+public class ServerPeer extends ServiceMBeanSupport implements ClientAOPStackProvider
 {
    // Constants -----------------------------------------------------
 
@@ -96,7 +99,7 @@
    // Attributes ----------------------------------------------------
 
    private int serverPeerID;
-   private byte[] clientAOPConfig;
+   private byte[] clientAOPStack;
    private Version version;
 
    private String defaultQueueJNDIContext;
@@ -246,6 +249,10 @@
          
          initializeRemoting(mbeanServer);
 
+         // Register myself as ClientAOPStackProvider with the JMSDispatcher
+         ClientAOPStackProviderAdvised advised = new ClientAOPStackProviderAdvised(this);
+         JMSDispatcher.instance.registerTarget(new Integer(serverPeerID), advised);
+
          started = true;
 
          log.info("JBoss Messaging " + getVersion().getProviderVersion() + " server [" +
@@ -597,6 +604,13 @@
       }
    }
 
+   // ClientAOPStackProvider implementation -------------------------------
+
+   public byte[] getClientAOPStack()
+   {
+      return clientAOPStack;
+   }
+
    // Public --------------------------------------------------------
    
    public IDManager getMessageIDManager()
@@ -710,11 +724,6 @@
       return started;
    }
 
-   public byte[] getClientAOPConfig()
-   {
-      return clientAOPConfig;
-   }
-
    public Version getVersion()
    {
       return version;
@@ -774,8 +783,7 @@
       // We get the reference lazily to avoid problems with MBean circular dependencies
       if (postOffice == null)
       {
-         postOffice = (PostOffice)getServer().
-            getAttribute(postOfficeObjectName, "Instance");
+         postOffice = (PostOffice)getServer().getAttribute(postOfficeObjectName, "Instance");
 
          // We also inject the replicator dependency into the ConnectionFactoryJNDIMapper. This is
          // a bit messy but we have a circular dependency POJOContainer should be able to help us
@@ -788,8 +796,8 @@
             rep.registerListener(new FailoverListener());
          }
          
-         //Also need to inject into txRepository
-         this.txRepository.injectPostOffice(postOffice);
+         // Also need to inject into txRepository
+         txRepository.injectPostOffice(postOffice);
       }
       return postOffice;
    }
@@ -978,7 +986,7 @@
             os.write(b);
          }
          os.flush();
-         clientAOPConfig = os.toByteArray();
+         clientAOPStack = os.toByteArray();
       }
       finally
       {

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactory.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -70,32 +70,36 @@
    {
       try
       {
+         log.debug(this + " starting");
+
          started = true;
          
          if (connectorObjectName == null)
          {
-            throw new IllegalArgumentException("A Connector must be specified for each Connection Factory");
+            throw new IllegalArgumentException("A Connector must be specified for " +
+                                               "each Connection Factory");
          }
          
          if (serverPeerObjectName == null)
          {
-            throw new IllegalArgumentException("ServerPeer must be specified for each Connection Factory");
+            throw new IllegalArgumentException("ServerPeer must be specified for " +
+                                               "each Connection Factory");
          }
       
          String locatorURI = (String)server.getAttribute(connectorObjectName, "InvokerLocator");
-         
          ServerPeer serverPeer = (ServerPeer)server.getAttribute(serverPeerObjectName, "Instance");
          
          connectionFactoryManager = serverPeer.getConnectionFactoryManager();
          connectorManager = serverPeer.getConnectorManager();
          connectionManager = serverPeer.getConnectionManager();
-         
-         long leasePeriod = ((Long)server.getAttribute(connectorObjectName, "LeasePeriod")).longValue();
-         
+
+         int refCount = connectorManager.registerConnector(connectorObjectName.getCanonicalName());
+
+         long leasePeriod =
+            ((Long)server.getAttribute(connectorObjectName, "LeasePeriod")).longValue();
+
          // if leasePeriod <= 0, disable pinging altogether
-         
-         int refCount = connectorManager.registerConnector(connectorObjectName.getCanonicalName());
-         
+
          boolean enablePing = leasePeriod > 0;
          
          if (refCount == 1 && enablePing)
@@ -109,15 +113,15 @@
          // We use the MBean service name to uniquely identify the connection factory
          
          connectionFactoryManager.
-            registerConnectionFactory(getServiceName().toString(), clientID, jndiBindings, locatorURI,
-                                      enablePing, prefetchSize, defaultTempQueueFullSize,
-                                      defaultTempQueuePageSize, defaultTempQueueDownCacheSize,
-                                      clustered);
+            registerConnectionFactory(getServiceName().toString(), clientID, jndiBindings,
+                                      locatorURI, enablePing, prefetchSize,
+                                      defaultTempQueueFullSize, defaultTempQueuePageSize,
+                                      defaultTempQueueDownCacheSize, clustered);
       
          InvokerLocator locator = new InvokerLocator(locatorURI);
 
-         String info =
-            "Connector " + locator.getProtocol() + "://" + locator.getHost() + ":" + locator.getPort();
+         String info = "Connector " + locator.getProtocol() + "://" +
+            locator.getHost() + ":" + locator.getPort();
                  
          if (enablePing)
          {
@@ -129,7 +133,7 @@
          }
       
          log.info(info);
-         log.info(this + " deployed");
+         log.info(this + " started");
       }
       catch (Throwable t)
       {

Modified: trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/connectionfactory/ConnectionFactoryJNDIMapper.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -30,6 +30,7 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
+import java.util.Set;
 
 import javax.naming.Context;
 import javax.naming.InitialContext;
@@ -37,7 +38,7 @@
 
 import org.jboss.jms.client.JBossConnectionFactory;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate;
 import org.jboss.jms.server.ConnectionFactoryManager;
 import org.jboss.jms.server.ServerPeer;
 import org.jboss.jms.server.Version;
@@ -45,6 +46,7 @@
 import org.jboss.jms.server.endpoint.advised.ConnectionFactoryAdvised;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.util.JNDIUtil;
+import org.jboss.jms.delegate.ConnectionFactoryDelegate;
 import org.jboss.logging.Logger;
 import org.jboss.messaging.core.plugin.contract.ReplicationListener;
 import org.jboss.messaging.core.plugin.contract.Replicator;
@@ -72,8 +74,6 @@
 
    // Attributes ----------------------------------------------------
 
-   private boolean trace = log.isTraceEnabled();
-
    protected Context initialContext;
    protected ServerPeer serverPeer;
 
@@ -85,11 +85,9 @@
 
    private Replicator replicator;
 
-   /*
-   We cache the map of node->failover node in here.
-   This is then updated when node joins or leaves the cluster via the replicationListener
-   When new cfs are deployed we use the cached map
-   */
+   // Map<Integer(nodeID)->Integer(failoverNodeID)>
+   // The map is updated when a node joins of leaves the cluster via the replicationListener. When
+   // a new ConnectionFactories are deployed we use the cached map.
    protected Map failoverMap;
 
    // Constructors --------------------------------------------------
@@ -115,12 +113,14 @@
                                                       boolean clustered)
       throws Exception
    {
-      log.debug(this + " registering connection factory '" + uniqueName + "', bindings: " + jndiBindings);
+      log.debug(this + " registering connection factory '" + uniqueName +
+         "', bindings: " + jndiBindings);
 
       // Sanity check
       if (delegates.containsKey(uniqueName))
       {
-         throw new IllegalArgumentException("There's already a connection factory registered with name " + uniqueName);
+         throw new IllegalArgumentException("There's already a connection factory " +
+                                            "registered with name " + uniqueName);
       }
 
       int id = serverPeer.getNextObjectID();
@@ -134,16 +134,12 @@
                                              defaultTempQueueDownCacheSize);
       endpoints.put(uniqueName, endpoint);
 
-      ClientConnectionFactoryDelegate delegate = null;
+      ConnectionFactoryDelegate delegate = null;
 
       if (clustered)
       {
          setupReplicator();
       }
-      else
-      {
-         log.info("ConnectionFactoryJNDIMapper is non clustered");
-      }
 
       boolean creatingClustered = clustered && replicator != null;
 
@@ -151,6 +147,8 @@
          new ClientConnectionFactoryDelegate(id, serverPeer.getServerPeerID(),
                                              locatorURI, version, clientPing);
 
+      log.debug(this + " created local delegate " + localDelegate);
+
       // When registering a new clustered connection factory I should first create it with the
       // available delegates then send the replication message. We then listen for connection
       // factories added to global state using the replication listener and then update their
@@ -169,6 +167,7 @@
          Map localDelegates = replicator.get(CF_PREFIX + uniqueName);
          delegate = createClusteredDelegate(localDelegates.values());
 
+         log.debug(this + " created clustered delegate " + delegate);
       }
       else
       {
@@ -216,8 +215,7 @@
       log.trace("Removing delegate from delegates list with key=" + uniqueName + " at serverPeerID=" +
                   this.serverPeer.getServerPeerID());
 
-      ClientConnectionFactoryDelegate delegate =
-         (ClientConnectionFactoryDelegate)delegates.remove(uniqueName);
+      ConnectionFactoryDelegate delegate = (ConnectionFactoryDelegate)delegates.remove(uniqueName);
 
       if (delegate == null)
       {
@@ -293,7 +291,7 @@
             // failoverMap and rebind all connection factories with the new mapping. We cannot just
             // reference a single map since the objects are bound in JNDI in serialized form.
 
-            recalculateFailoverMap(updatedReplicantMap);
+            failoverMap = recalculateFailoverMap(updatedReplicantMap.keySet());
 
             // Rebind
 
@@ -304,8 +302,8 @@
                ServerConnectionFactoryEndpoint endpoint =
                   (ServerConnectionFactoryEndpoint)entry.getValue();
 
-               ClusteredClientConnectionFactoryDelegate del =
-                  (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+               ClientClusteredConnectionFactoryDelegate del =
+                  (ClientClusteredConnectionFactoryDelegate)delegates.get(uniqueName);
 
                if (del == null)
                {
@@ -328,15 +326,15 @@
 
             log.debug(this + " received '" + uniqueName + "' connection factory update " + updatedReplicantMap);
 
-            ClusteredClientConnectionFactoryDelegate del =
-               (ClusteredClientConnectionFactoryDelegate)delegates.get(uniqueName);
+            ClientClusteredConnectionFactoryDelegate del =
+               (ClientClusteredConnectionFactoryDelegate)delegates.get(uniqueName);
 
             if (del == null)
             {
                throw new IllegalStateException("Cannot find cf with name " + uniqueName);
             }
 
-            List newDels = sortCFS(updatedReplicantMap.values());
+            List newDels = sortDelegatesOnServerID(updatedReplicantMap.values());
 
             ClientConnectionFactoryDelegate[] delArr =
                (ClientConnectionFactoryDelegate[])newDels.
@@ -382,25 +380,29 @@
 
    private void setupReplicator() throws Exception
    {
-      this.serverPeer.getPostOfficeInstance();
+      serverPeer.getPostOfficeInstance();
    }
 
-   private void recalculateFailoverMap(Map nodeAddressMap) throws Exception
+   /**
+    * @param nodeIDs Set<Integer(nodeID)>
+    * @return Map<Integer(nodeID)->Integer(failoverNodeID)>
+    */
+   private Map recalculateFailoverMap(Set nodeIDs) throws Exception
    {
       FailoverMapper mapper = replicator.getFailoverMapper();
-      failoverMap = mapper.generateMapping(nodeAddressMap.keySet());
+      return mapper.generateMapping(nodeIDs);
    }
 
    /**
-    * @param localDelegates - Map<Integer(nodeId) - ClientConnectionFactoryDelegate>
+    * @param localDelegates - Collection<ClientConnectionFactoryDelegate>
     */
-   private ClusteredClientConnectionFactoryDelegate
-      createClusteredDelegate(Collection localDelegates)  throws Exception
+   private ClientClusteredConnectionFactoryDelegate
+      createClusteredDelegate(Collection localDelegates) throws Exception
    {
-      if (trace) { log.trace(this + " updating failover delegates with " + localDelegates); }
+      log.trace(this + " creating a clustered ConnectionFactoryDelegate based on " + localDelegates);
 
-      // First sort the local delegates in order of server id
-      List sortedLocalDelegates = sortCFS(localDelegates);
+      // First sort the local delegates in order of server ID
+      List sortedLocalDelegates = sortDelegatesOnServerID(localDelegates);
 
       ClientConnectionFactoryDelegate[] delegates =
          (ClientConnectionFactoryDelegate[])sortedLocalDelegates.
@@ -417,39 +419,14 @@
             throw new IllegalStateException("Cannot find address node mapping!");
          }
 
-         recalculateFailoverMap(nodeAddressMap);
+         failoverMap = recalculateFailoverMap(nodeAddressMap.keySet());
       }
 
-      // The main delegated is needed for the construction of
-      // ClusteredClientConnectionFactoryDelegate. ClusteredClientConnectionFactoryDelegate extends
-      // ClientConnectionFactoryDelegate and it will need the current server's delegate properties
-      // to be bound to ObjectId, ServerLocator and other connection properties.
-      // The ClusteredCFDelegate will copy these properties on its contructor defined bellow after
-      // this loop.
-
-      ClientConnectionFactoryDelegate mainDelegate = null;
-
-      for(Iterator i = localDelegates.iterator(); i.hasNext();)
-      {
-         ClientConnectionFactoryDelegate del = (ClientConnectionFactoryDelegate)i.next();
-
-         if (del.getServerID() == serverPeer.getServerPeerID())
-         {
-            // sanity check
-            if (mainDelegate != null)
-            {
-               throw new IllegalStateException("There are two servers with serverID=" +
-                        this.serverPeer.getServerPeerID() + ", verify your clustering configuration");
-            }
-            mainDelegate = del;
-         }
-      }
-
-      return new ClusteredClientConnectionFactoryDelegate(mainDelegate, delegates, failoverMap);
+      return new ClientClusteredConnectionFactoryDelegate(delegates, failoverMap);
    }
 
    private void rebindConnectionFactory(Context ic, JNDIBindings jndiBindings,
-                                        ClientConnectionFactoryDelegate delegate)
+                                        ConnectionFactoryDelegate delegate)
       throws NamingException
    {
       JBossConnectionFactory cf = new JBossConnectionFactory(delegate);
@@ -466,10 +443,7 @@
       }
    }
 
-   /**
-    * Sort the collection of delegates in order of server id
-    */
-   private List sortCFS(Collection delegates)
+   private List sortDelegatesOnServerID(Collection delegates)
    {
       List localDels = new ArrayList(delegates);
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ConnectionFactoryEndpoint.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -39,11 +39,9 @@
 { 
    CreateConnectionResult createConnectionDelegate(String username,
                                                    String password, 
-                                                   int failedNodeId)
+                                                   int failedNodeID)
       throws JMSException;
    
-   byte[] getClientAOPConfig() throws JMSException;
-
    IDBlock getIdBlock(int size) throws JMSException;
 }
 

Modified: trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/endpoint/DeliveryInfo.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -127,7 +127,7 @@
 
    public String toString()
    {
-      return "Delivery[" + msg + "]";
+      return "Delivery[" + getDeliveryId() + ", " + msg + "]";
    }
 
    // Ack Implementation  -------------------------------------------

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConnectionFactoryEndpoint.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -172,18 +172,6 @@
       return new ClientConnectionDelegate(connectionID, serverPeer.getServerPeerID());
    }
    
-   public byte[] getClientAOPConfig() throws JMSException
-   {
-      try
-      {
-         return serverPeer.getClientAOPConfig();
-      }
-      catch (Throwable t)
-      {
-         throw ExceptionUtil.handleJMSInvocation(t, this + " getClientAOPConfig");
-      }
-   }
-
    public IDBlock getIdBlock(int size) throws JMSException
    {
       try

Modified: trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/endpoint/ServerConsumerEndpoint.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -29,7 +29,6 @@
 import org.jboss.jms.message.JBossMessage;
 import org.jboss.jms.message.MessageProxy;
 import org.jboss.jms.selector.Selector;
-import org.jboss.jms.server.destination.ManagedDestination;
 import org.jboss.jms.server.remoting.JMSDispatcher;
 import org.jboss.jms.server.remoting.MessagingMarshallable;
 import org.jboss.jms.util.ExceptionUtil;

Added: trunk/src/main/org/jboss/jms/server/endpoint/advised/ClientAOPStackProviderAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ClientAOPStackProviderAdvised.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ClientAOPStackProviderAdvised.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,57 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.jms.server.endpoint.advised;
+
+import org.jboss.jms.server.ServerPeer;
+import org.jboss.jms.client.ClientAOPStackProvider;
+
+/**
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ *
+ * $Id$
+ */
+public class ClientAOPStackProviderAdvised implements ClientAOPStackProvider
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   private ServerPeer serverPeer;
+
+   // Constructors --------------------------------------------------
+
+   public ClientAOPStackProviderAdvised(ServerPeer serverPeer)
+   {
+      this.serverPeer = serverPeer;
+   }
+
+   // ClientAOPStackProvider implementation --------------------------------
+
+   public byte[] getClientAOPStack()
+   {
+      return serverPeer.getClientAOPStack();
+   }
+
+   // Public --------------------------------------------------------
+
+   public String toString()
+   {
+      return "ClientAOPStackProviderAdvised->" + serverPeer;
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Modified: trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/endpoint/advised/ConnectionFactoryAdvised.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -65,11 +65,6 @@
       return endpoint.createConnectionDelegate(username, password, failedNodeId);
    }
 
-   public byte[] getClientAOPConfig() throws JMSException
-   {
-      return endpoint.getClientAOPConfig();
-   }
-
    public IDBlock getIdBlock(int size) throws JMSException
    {
       return endpoint.getIdBlock(size);

Modified: trunk/src/main/org/jboss/jms/server/remoting/JMSDispatcher.java
===================================================================
--- trunk/src/main/org/jboss/jms/server/remoting/JMSDispatcher.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/server/remoting/JMSDispatcher.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -25,8 +25,8 @@
 
 /**
  * 
- * We have our own Dispatcher so we don't have the possibility with conflicts with other
- * systems using the same object ids
+ * We have our own Dispatcher so we don't have the possibility with conflicts with other systems
+ * using the same object ids.
  * 
  * @author <a href="tim.fox at jboss.com">Tim Fox</a>
  * @version 1.1

Modified: trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java
===================================================================
--- trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/jms/tx/ResourceManagerFactory.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -25,14 +25,14 @@
 import java.util.Map;
 
 /**
- * This class manages instances of ResourceManager. It ensures there is one instance per instance
- * of JMS server as specified by the server id.
+ * This class manages ResourceManager instances. It ensures there is one instance per instance of
+ * JMS server as specified by the server ID.
  * 
- * This allows different JMS connections to the same JMS server (the underlying resource is the JMS server)
- * to use the same resource manager.
+ * This allows different JMS connections to the same JMS server (the underlying resource is the JMS
+ * server) to use the same resource manager.
  * 
- * This means isSameRM() on XAResource returns true, allowing the Transaction manager to join work in one
- * tx to another thus allowing 1PC optimization which should help performance.
+ * This means isSameRM() on XAResource returns true, allowing the Transaction manager to join work
+ * in one tx to another thus allowing 1PC optimization which should help performance.
  *
  * @author <a href="mailto:tim.fox at jboss.com">Tim Fox</a>
  * @version $Revision: 1329 $
@@ -40,107 +40,120 @@
  * $Id: ResourceManagerFactory.java 1329 2006-09-20 21:29:56Z ovidiu.feodorov at jboss.com $
  */
 public class ResourceManagerFactory
-{      
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   // Static ---------------------------------------------------------------------------------------
+
    public static ResourceManagerFactory instance = new ResourceManagerFactory();
-   
+
+   // Attributes -----------------------------------------------------------------------------------
+
    private Map holders;
-   
+
+   // Constructors ---------------------------------------------------------------------------------
+
    private ResourceManagerFactory()
-   {      
+   {
       holders = new HashMap();
    }
-   
-   /*
-    * Need to failover rm from old server id to new server id, merging resource managers if it already exists
-    */
-   public synchronized void handleFailover(int oldServerId, int newServerId)
-   {       
-      Holder hOld = (Holder)holders.remove(new Integer(oldServerId));
-      
-      if (hOld == null)
-      {
-         //This is ok - this would happen if there are more than one connections for the old server failing
-         //in which only the first one to fail would failover the resource manager factory - since they
-         //share the same rm
-         return;
-      }
-      
-      ResourceManager oldRM = hOld.rm;
-      
-      ResourceManager newRM = null;
-      
-      Holder hNew = (Holder)holders.get(new Integer(newServerId));      
-      
-      if (hNew != null)
-      {
-         //Need to merge into the new
-         
-         newRM = hNew.rm;
-         
-         newRM.merge(oldRM);         
-      }
-      else
-      {
-         //re-register the old rm with the new id
-         
-         Holder h = new Holder(oldRM);
-         
-         holders.put(new Integer(newServerId), h);
-      }  
-   }
-   
+
+   // Public ---------------------------------------------------------------------------------------
+
    public synchronized int size()
    {
       return holders.size();
    }
-      
+
    public synchronized boolean containsResourceManager(int serverID)
    {
       return holders.containsKey(new Integer(serverID));
    }
-   
+
    /**
     * @param serverID - server peer ID.
     */
    public synchronized ResourceManager checkOutResourceManager(int serverID)
    {
       Integer i = new Integer(serverID);
-      
+
       Holder h = (Holder)holders.get(i);
-      
+
       if (h == null)
       {
          h = new Holder();
-         
          holders.put(i, h);
       }
       else
       {
          h.refCount++;
       }
-      
+
       return h.rm;
    }
-   
+
    public synchronized void checkInResourceManager(int serverID)
    {
       Integer i = new Integer(serverID);
-      
       Holder h = (Holder)holders.get(i);
-      
+
       if (h == null)
       {
          throw new IllegalArgumentException("Cannot find resource manager for server: " + serverID);
       }
-      
+
       h.refCount--;
-      
+
       if (h.refCount == 0)
       {
          holders.remove(i);
-      }      
+      }
    }
-   
+
+   /**
+    * Need to failover rm from old server id to new server id, merging resource managers if it
+    * already exists.
+    */
+   public synchronized void handleFailover(int oldServerID, int newServerID)
+   {
+      Holder hOld = (Holder)holders.remove(new Integer(oldServerID));
+
+      if (hOld == null)
+      {
+         // This is ok - this would happen if there are more than one connections for the old server
+         // failing in which only the first one to fail would failover the resource manager factory
+         // - since they share the same rm.
+         return;
+      }
+
+      ResourceManager oldRM = hOld.rm;
+      ResourceManager newRM = null;
+      Holder hNew = (Holder)holders.get(new Integer(newServerID));
+
+      if (hNew != null)
+      {
+         // need to merge into the new
+
+         newRM = hNew.rm;
+         newRM.merge(oldRM);
+      }
+      else
+      {
+         // re-register the old rm with the new id
+
+         Holder h = new Holder(oldRM);
+         holders.put(new Integer(newServerID), h);
+      }
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   // Private --------------------------------------------------------------------------------------
+
+   // Inner classes --------------------------------------------------------------------------------
+
    private static class Holder
    {
       ResourceManager rm;
@@ -157,5 +170,4 @@
       
       int refCount = 1;
    }
-  
 }

Modified: trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java
===================================================================
--- trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/src/main/org/jboss/messaging/core/tx/TransactionRepository.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -176,7 +176,7 @@
 
       prepared = persistenceManager.retrievePreparedTransactions();
 
-      if (trace) log.trace ("Found " + prepared.size() + " transactions in prepared state:");
+      if (trace) log.trace ("found " + prepared.size() + " transactions in prepared state");
 
       if (prepared != null)
       {
@@ -186,7 +186,7 @@
          {
             PreparedTxInfo txInfo = (PreparedTxInfo) iter.next();
 
-            if (trace) log.trace("Reinstating TX(XID: " + txInfo.getXid() + ", LocalId " + txInfo.getTxId() +")");
+            if (trace) log.trace("reinstating TX(XID: " + txInfo.getXid() + ", LocalId " + txInfo.getTxId() +")");
             
             Transaction tx = createTransaction(txInfo);
             

Modified: trunk/tests/build.xml
===================================================================
--- trunk/tests/build.xml	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/build.xml	2006-12-31 10:51:38 UTC (rev 1880)
@@ -358,7 +358,7 @@
 
    <target name="http-tests" depends="tests-jar, prepare-testdirs, clear-test-logs">
       <antcall target="remote-tests">
-            <param name="test.remoting" value="http"/>
+         <param name="test.remoting" value="http"/>
       </antcall>
    </target>
 

Added: trunk/tests/src/org/jboss/test/messaging/jms/AOPStackInitializationTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/AOPStackInitializationTest.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/AOPStackInitializationTest.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,80 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms;
+
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+
+import javax.naming.InitialContext;
+import javax.jms.ConnectionFactory;
+import javax.jms.Connection;
+
+/**
+ * Tests the very first server invocation, when the client-side AOP stack is initialized.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 1843 $</tt>
+ *
+ * $Id: JMSTest.java 1843 2006-12-21 23:41:19Z timfox $
+ */
+public class AOPStackInitializationTest extends MessagingTestCase
+{
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   InitialContext ic;
+
+   // Constructors --------------------------------------------------
+
+   public AOPStackInitializationTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testSimpleInitialization() throws Exception
+   {
+      ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+
+      Connection conn = cf.createConnection();
+
+      conn.close();
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      ServerManagement.start("all");
+
+      ic = new InitialContext(ServerManagement.getJNDIEnvironment());
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      ic.close();
+
+      ServerManagement.stop();
+
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Added: trunk/tests/src/org/jboss/test/messaging/jms/FailoverValveTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/FailoverValveTest.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/FailoverValveTest.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,909 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms;
+
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.jms.client.Valve;
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.JBossSession;
+import org.jboss.jms.client.JBossQueueBrowser;
+import org.jboss.jms.client.JBossMessageProducer;
+import org.jboss.jms.client.JBossMessageConsumer;
+import org.jboss.jms.client.state.HierarchicalState;
+import org.jboss.jms.client.state.HierarchicalStateSupport;
+import org.jboss.jms.client.delegate.DelegateSupport;
+import org.jboss.jms.client.container.FailoverValveInterceptor;
+import org.jboss.jms.server.Version;
+import org.jboss.aop.joinpoint.Invocation;
+import org.jboss.aop.joinpoint.MethodInvocation;
+import org.jboss.aop.MethodInfo;
+import org.jboss.aop.util.MethodHashing;
+import org.jboss.aop.advice.Interceptor;
+import org.jboss.remoting.Client;
+
+import javax.naming.InitialContext;
+import javax.jms.Connection;
+import javax.jms.Session;
+import javax.jms.ConnectionFactory;
+import javax.jms.Queue;
+import javax.jms.MessageProducer;
+import javax.jms.MessageConsumer;
+import javax.jms.QueueBrowser;
+import java.util.Set;
+import java.util.HashSet;
+import java.util.Collections;
+import java.util.Iterator;
+
+import EDU.oswego.cs.dl.util.concurrent.LinkedQueue;
+import EDU.oswego.cs.dl.util.concurrent.Slot;
+
+/**
+ * This is not necessarily a clustering test, as the failover valves are installed even for a
+ * non-clustered configuration.
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 1843 $</tt>
+ *
+ * $Id: JMSTest.java 1843 2006-12-21 23:41:19Z timfox $
+ */
+public class FailoverValveTest extends MessagingTestCase
+{
+   // Constants ------------------------------------------------------------------------------------
+
+   // Static ---------------------------------------------------------------------------------------
+
+   // Attributes -----------------------------------------------------------------------------------
+
+   private InitialContext ic;
+   private ConnectionFactory cf;
+   private Queue queue;
+
+   // Constructors ---------------------------------------------------------------------------------
+
+   public FailoverValveTest(String name)
+   {
+      super(name);
+   }
+
+   // Public ---------------------------------------------------------------------------------------
+
+   public void testCloseValveHierarchy() throws Exception
+   {
+      Connection conn = null;
+
+      try
+      {
+         conn = cf.createConnection();
+
+         assertTrue(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+
+         Session session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         assertTrue(((Valve)((JBossSession)session).getDelegate()).isValveOpen());
+
+         MessageProducer prod = session.createProducer(queue);
+         assertTrue(((Valve)((JBossMessageProducer)prod).getDelegate()).isValveOpen());
+
+         MessageConsumer cons = session.createConsumer(queue);
+         assertTrue(((Valve)((JBossMessageConsumer)cons).getDelegate()).isValveOpen());
+
+         QueueBrowser browser = session.createBrowser(queue);
+         assertTrue(((Valve)((JBossQueueBrowser)browser).getDelegate()).isValveOpen());
+
+         ((JBossConnection)conn).getDelegate().closeValve();
+
+         log.debug("top level valve closed");
+
+         assertFalse(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossSession)session).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageProducer)prod).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageConsumer)cons).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossQueueBrowser)browser).getDelegate()).isValveOpen());
+
+         ((JBossConnection)conn).getDelegate().openValve();
+
+         log.debug("top level valve open");
+
+         assertTrue(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageProducer)prod).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageConsumer)cons).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossQueueBrowser)browser).getDelegate()).isValveOpen());
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+
+   }
+
+   public void testCloseValveHierarchy2() throws Exception
+   {
+      Connection conn = null;
+
+      try
+      {
+         conn = cf.createConnection();
+
+         assertTrue(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+
+         Session session1 = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session session2 = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         assertTrue(((Valve)((JBossSession)session1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session2).getDelegate()).isValveOpen());
+
+         MessageProducer prod1 = session1.createProducer(queue);
+         assertTrue(((Valve)((JBossMessageProducer)prod1).getDelegate()).isValveOpen());
+
+         MessageConsumer cons1 = session1.createConsumer(queue);
+         assertTrue(((Valve)((JBossMessageConsumer)cons1).getDelegate()).isValveOpen());
+
+         QueueBrowser browser1 = session1.createBrowser(queue);
+         assertTrue(((Valve)((JBossQueueBrowser)browser1).getDelegate()).isValveOpen());
+
+         MessageProducer prod2 = session2.createProducer(queue);
+         assertTrue(((Valve)((JBossMessageProducer)prod2).getDelegate()).isValveOpen());
+
+         MessageConsumer cons2 = session2.createConsumer(queue);
+         assertTrue(((Valve)((JBossMessageConsumer)cons2).getDelegate()).isValveOpen());
+
+         QueueBrowser browser2 = session2.createBrowser(queue);
+         assertTrue(((Valve)((JBossQueueBrowser)browser2).getDelegate()).isValveOpen());
+
+         ((JBossConnection)conn).getDelegate().closeValve();
+
+         log.debug("top level valve closed");
+
+         assertFalse(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossSession)session1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossSession)session2).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageProducer)prod1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageConsumer)cons1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossQueueBrowser)browser1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageProducer)prod2).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageConsumer)cons2).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossQueueBrowser)browser2).getDelegate()).isValveOpen());
+
+         ((JBossConnection)conn).getDelegate().openValve();
+
+         log.debug("top level valve open");
+
+         assertTrue(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session2).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageProducer)prod1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageConsumer)cons1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossQueueBrowser)browser1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageProducer)prod2).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageConsumer)cons2).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossQueueBrowser)browser2).getDelegate()).isValveOpen());
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+
+   public void testValveOpenByDefault() throws Throwable
+   {
+      FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      assertEquals(Boolean.TRUE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+
+      // try to open the valve again, it should be a noop
+      valve.invoke(buildInvocation("openValve", target));
+
+      assertEquals(Boolean.TRUE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+   }
+
+   public void testPassThroughOpenValve() throws Throwable
+   {
+      final FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      final SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      // send a thread through the open valve
+      Thread t = new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("businessMethod1", target));
+            }
+            catch(Throwable t)
+            {
+               log.error("businessMethod1 invocation failed", t);
+            }
+         }
+      }, "Business Thread 1");
+
+      t.start();
+      t.join();
+
+      // the thread should have passed through the open valve
+      assertEquals(1, target.getBusinessMethod1InvocationCount());
+      assertEquals(1, target.getActiveThreadsHighWaterMark());
+
+   }
+
+   public void testFlipValve() throws Throwable
+   {
+      FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      valve.invoke(buildInvocation("closeValve", target));
+
+      assertEquals(Boolean.FALSE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+
+      // child states also must have been notified to close their corresponding valves
+      ParentHierarchicalState state = (ParentHierarchicalState)target.getState();
+
+      for(Iterator i = state.getChildren().iterator(); i.hasNext(); )
+      {
+         ChildState cs = (ChildState)i.next();
+         assertFalse(((Valve)cs.getDelegate()).isValveOpen());
+      }
+
+      // try to close the valve again, it should be a noop
+
+      valve.invoke(buildInvocation("closeValve", target));
+
+      assertEquals(Boolean.FALSE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+   }
+
+   public void testFlipValve2() throws Throwable
+   {
+      FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      valve.invoke(buildInvocation("closeValve", target));
+
+      assertEquals(Boolean.FALSE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+
+      // child states also must have been notified to close their corresponding valves
+      ParentHierarchicalState state = (ParentHierarchicalState)target.getState();
+
+      for(Iterator i = state.getChildren().iterator(); i.hasNext(); )
+      {
+         ChildState cs = (ChildState)i.next();
+         assertFalse(((Valve)cs.getDelegate()).isValveOpen());
+      }
+
+      // re-open the valve
+
+      valve.invoke(buildInvocation("openValve", target));
+
+      assertEquals(Boolean.TRUE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+
+      // child states also must have been notified to open their corresponding valves
+      state = (ParentHierarchicalState)target.getState();
+
+      for(Iterator i = state.getChildren().iterator(); i.hasNext(); )
+      {
+         ChildState cs = (ChildState)i.next();
+         assertTrue(((Valve)cs.getDelegate()).isValveOpen());
+      }
+   }
+
+   /**
+    * Close the valve and send a thread through it. The thread must be put on hold until the valve
+    * is opened again.
+    */
+   public void testCloseValveOneBusinessThread() throws Throwable
+   {
+      final FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      final SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      valve.invoke(buildInvocation("closeValve", target));
+
+      assertEquals(Boolean.FALSE, valve.invoke(buildInvocation("isValveOpen", target)));
+
+      log.debug("the valve is closed");
+
+      // smack a thread into the closed valve
+      Thread t = new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("businessMethod1", target));
+            }
+            catch(Throwable t)
+            {
+               log.error("businessMethod1 invocation failed", t);
+            }
+         }
+      }, "Business Thread 1");
+
+      t.start();
+
+      // wait for 10 secs for the invocation to reach target object. It shouldn't ...
+      long waitTime = 10000;
+      log.info("probing target for " + waitTime / 1000 + " seconds ...");
+      InvocationToken arrived = target.waitForInvocation(waitTime);
+
+      if (arrived != null)
+      {
+         fail(arrived.getMethodName() + "() reached target, while it shouldn't have!");
+      }
+
+
+      log.debug("the business thread didn't go through");
+
+      // open the valve
+
+      valve.invoke(buildInvocation("openValve", target));
+
+      // the business invocation should complete almost immediately; wait on mutex to avoid race
+      // condition
+
+      arrived = target.waitForInvocation(2000);
+
+      assertEquals("businessMethod1", arrived.getMethodName());
+      assertEquals(1, target.getBusinessMethod1InvocationCount());
+      assertEquals(1, target.getActiveThreadsHighWaterMark());
+   }
+
+
+   /**
+    * Close the valve and send three threads through it. The threads must be put on hold until the
+    * valve is opened again.
+    */
+   public void testCloseValveThreeBusinessThread() throws Throwable
+   {
+      final FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      final SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      valve.invoke(buildInvocation("closeValve", target));
+
+      assertEquals(Boolean.FALSE, valve.invoke(buildInvocation("isValveOpen", target)));
+
+      log.debug("the valve is closed");
+
+      // smack thread 1 into the closed valve
+      new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("businessMethod1", target));
+            }
+            catch(Throwable t)
+            {
+               log.error("businessMethod1 invocation failed", t);
+            }
+         }
+      }, "Business Thread 1").start();
+
+      // smack thread 2 into the closed valve
+      new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("businessMethod1", target));
+            }
+            catch(Throwable t)
+            {
+               log.error("businessMethod1 invocation failed", t);
+            }
+         }
+      }, "Business Thread 2").start();
+
+      // smack thread 3 into the closed valve
+      new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("businessMethod2", target));
+            }
+            catch(Throwable t)
+            {
+               log.error("businessMethod2 invocation failed", t);
+            }
+         }
+      }, "Business Thread 3").start();
+
+      // wait for 10 secs for any invocation to reach target object. It shouldn't ...
+      long waitTime = 10000;
+      log.info("probing target for " + waitTime / 1000 + " seconds ...");
+      InvocationToken arrived = target.waitForInvocation(waitTime);
+
+      if (arrived != null)
+      {
+         fail(arrived.getMethodName() + "() reached target, while it shouldn't have!");
+      }
+
+      log.debug("the business threads didn't go through");
+
+      // open the valve
+
+      valve.invoke(buildInvocation("openValve", target));
+
+      // the business invocations should complete almost immediately; wait on mutex to avoid race
+      // condition
+
+      arrived = target.waitForInvocation(2000);
+      assertNotNull(arrived);
+
+      arrived = target.waitForInvocation(2000);
+      assertNotNull(arrived);
+
+      arrived = target.waitForInvocation(2000);
+      assertNotNull(arrived);
+
+      // wait for 3 secs for any invocation to reach target object. It shouldn't ...
+      waitTime = 3000;
+      log.info("probing target for " + waitTime / 1000 + " seconds ...");
+      arrived = target.waitForInvocation(waitTime);
+
+      if (arrived != null)
+      {
+         fail("Extra " + arrived.getMethodName() + "() reached target, " +
+            "while it shouldn't have!");
+      }
+
+      assertEquals(2, target.getBusinessMethod1InvocationCount());
+      assertEquals(1, target.getBusinessMethod2InvocationCount());
+      assertEquals(3, target.getActiveThreadsHighWaterMark());
+   }
+
+   /**
+    * The current standard behavior is that the valve cannot be closed as long as there are
+    * active threads. closeValve() will block undefinitely.
+    */
+   public void testCloseWhileActiveThreads() throws Throwable
+   {
+      final FailoverValveInterceptor valve = new FailoverValveInterceptor();
+      final SimpleInvocationTargetObject target = new SimpleInvocationTargetObject(valve);
+
+      assertEquals(Boolean.TRUE, valve.invoke(buildInvocation("isValveOpen", target)));
+
+      // send a long running thread through the valve
+      new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("blockingBusinessMethod", target));
+            }
+            catch(Throwable t)
+            {
+               log.error("blockingBusinessMethod invocation failed", t);
+            }
+         }
+      }, "Long running business thread").start();
+
+      // allow blockingBusinessMethod time to block
+      Thread.sleep(2000);
+
+      assertEquals(new Integer(1), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+
+      final Slot closingCompleted = new Slot();
+
+      // from a different thread try to close the valve; this thread will block until we unblock
+      // the business method
+
+      new Thread(new Runnable()
+      {
+         public void run()
+         {
+            try
+            {
+               valve.invoke(buildInvocation("closeValve", target));
+               closingCompleted.put(Boolean.TRUE);
+
+            }
+            catch(Throwable t)
+            {
+               log.error("blockingBusinessMethod() invocation failed", t);
+            }
+         }
+      }, "Valve closing thread").start();
+
+
+      // closing shouldn't be completed for a long time .... actually never, if I don't unblock
+      // the business method
+
+      // wait for 15 secs for closing. It shouldn't ...
+      long waitTime = 15000;
+      log.info("probing closing for " + waitTime / 1000 + " seconds ...");
+
+      Boolean closed = (Boolean)closingCompleted.poll(waitTime);
+
+      if (closed != null)
+      {
+         fail("closeValve() went through, while it shouldn't have!");
+      }
+
+      assertEquals(Boolean.TRUE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(1), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+
+      log.info("valve still open ...");
+
+      // unblock blockingBusinessMethod
+      target.unblockBlockingBusinessMethod();
+
+      // valve closing should complete immediately after that
+      closed = (Boolean)closingCompleted.poll(1000);
+      assertTrue(closed.booleanValue());
+      assertEquals(Boolean.FALSE, valve.invoke(buildInvocation("isValveOpen", target)));
+      assertEquals(new Integer(0), valve.invoke(buildInvocation("getActiveThreadsCount", target)));
+   }
+
+   // Package protected ----------------------------------------------------------------------------
+
+   // Protected ------------------------------------------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+
+      ServerManagement.start("all");
+
+      ic = new InitialContext(ServerManagement.getJNDIEnvironment());
+
+      ServerManagement.deployQueue("TestQueue");
+
+      cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+      queue = (Queue)ic.lookup("/queue/TestQueue");
+
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      ServerManagement.undeployQueue("TestQueue");
+
+      ic.close();
+
+      super.tearDown();
+   }
+
+   // Private --------------------------------------------------------------------------------------
+
+   private Invocation buildInvocation(String methodName, Object targetObject)
+      throws Exception
+   {
+      long hash =
+         MethodHashing.calculateHash(targetObject.getClass().getMethod(methodName, new Class[0]));
+      MethodInfo mi = new MethodInfo(targetObject.getClass(), hash, hash, null);
+      MethodInvocation invocation = new MethodInvocation(mi, new Interceptor[0]);
+      invocation.setTargetObject(targetObject);
+      return invocation;
+   }
+
+   // Inner classes --------------------------------------------------------------------------------
+
+   public interface BusinessObject
+   {
+      void businessMethod1();
+      void businessMethod2();
+      /**
+       * Must be unblocked externally.
+       */
+      void blockingBusinessMethod() throws InterruptedException;
+   }
+
+   public class SimpleInvocationTargetObject
+      extends DelegateSupport implements BusinessObject, Valve
+   {
+      private int businessMethod1InvocationCount;
+      private int businessMethod2InvocationCount;
+
+      // LinkedQueue<InvocationToken>
+      private LinkedQueue invocationTokens;
+
+      private FailoverValveInterceptor valve;
+      private int activeThreadsCountHighWaterMark;
+
+      private Object blockingMethodWaitArea;
+
+      public SimpleInvocationTargetObject(FailoverValveInterceptor valve)
+      {
+         super();
+         setState(new ParentHierarchicalState());
+         businessMethod1InvocationCount = 0;
+         businessMethod2InvocationCount = 0;
+         invocationTokens = new LinkedQueue();
+         this.valve = valve;
+         activeThreadsCountHighWaterMark = 0;
+         blockingMethodWaitArea = new Object();
+      }
+
+      protected Client getClient() throws Exception
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public boolean isValveOpen()
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public void closeValve() throws Exception
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public void openValve() throws Exception
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public int getActiveThreadsCount()
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public synchronized void businessMethod1()
+      {
+         businessMethod1InvocationCount++;
+         updateActiveThreadsCountHighWaterMark();
+         notifyInvocationWaiter("businessMethod1");
+      }
+
+      public synchronized void businessMethod2()
+      {
+         businessMethod2InvocationCount++;
+         updateActiveThreadsCountHighWaterMark();
+         notifyInvocationWaiter("businessMethod2");
+      }
+
+      public void blockingBusinessMethod() throws InterruptedException
+      {
+         synchronized(blockingMethodWaitArea)
+         {
+            log.info("blockingBusinessMethod() blocking ...");
+            // block calling thread undefinitely until blockingMethodWaitArea is notified
+            blockingMethodWaitArea.wait();
+            log.info("blockingBusinessMethod() unblocked");
+         }
+      }
+
+      public synchronized int getBusinessMethod1InvocationCount()
+      {
+         return businessMethod1InvocationCount;
+      }
+
+      public synchronized int getBusinessMethod2InvocationCount()
+      {
+         return businessMethod2InvocationCount;
+      }
+
+      public synchronized int getActiveThreadsHighWaterMark()
+      {
+         return activeThreadsCountHighWaterMark;
+      }
+
+      /**
+       * Block until an invocation arrives into the target. If the invocation arrived prior to
+       * calling this method, it returns immediately.
+       *
+       * @return a token corresponding to the business invocation, or null if the method exited with
+       *         timout, without an invocation to arive.
+       */
+      public InvocationToken waitForInvocation(long timeout) throws InterruptedException
+      {
+         return (InvocationToken)invocationTokens.poll(timeout);
+      }
+
+      public void unblockBlockingBusinessMethod()
+      {
+         synchronized(blockingMethodWaitArea)
+         {
+            blockingMethodWaitArea.notify();
+         }
+      }
+
+      /**
+       * Reset the state
+       */
+      public synchronized void reset()
+      {
+         businessMethod1InvocationCount = 0;
+         businessMethod2InvocationCount = 0;
+         activeThreadsCountHighWaterMark = 0;
+      }
+
+      /**
+       * Notify someone who waits for this invocation to arrive.
+       */
+      private void notifyInvocationWaiter(String methodName)
+      {
+         try
+         {
+            invocationTokens.put(new InvocationToken(methodName));
+         }
+         catch(InterruptedException e)
+         {
+            throw new RuntimeException("Failed to deposit notification in queue", e);
+         }
+      }
+
+      private synchronized void updateActiveThreadsCountHighWaterMark()
+      {
+         try
+         {
+            int c =
+               ((Integer)valve.invoke(buildInvocation("getActiveThreadsCount", this))).intValue();
+            if (c > activeThreadsCountHighWaterMark)
+            {
+               activeThreadsCountHighWaterMark = c;
+            }
+         }
+         catch(Throwable t)
+         {
+            throw new RuntimeException("Failed to get getActiveThreadsCount", t);
+         }
+      }
+   }
+
+   private class ParentHierarchicalState extends HierarchicalStateSupport
+   {
+      private DelegateSupport delegate;
+      private HierarchicalState parent;
+
+      ParentHierarchicalState()
+      {
+         super(null, null);
+
+         children = new HashSet();
+
+         // populate it with a child state
+         children.add(new ChildState());
+      }
+
+      public DelegateSupport getDelegate()
+      {
+         return delegate;
+      }
+
+      public void setDelegate(DelegateSupport delegate)
+      {
+         this.delegate = delegate;
+      }
+
+      public HierarchicalState getParent()
+      {
+         return parent;
+      }
+
+      public void setParent(HierarchicalState parent)
+      {
+         this.parent = parent;
+      }
+
+      public Version getVersionToUse()
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public void synchronizeWith(HierarchicalState newState) throws Exception
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+   }
+
+   private class ChildState extends HierarchicalStateSupport
+   {
+      private DelegateSupport delegate;
+      private HierarchicalState parent;
+
+      ChildState()
+      {
+         super(null, new ChildDelegate());
+      }
+
+      public Set getChildren()
+      {
+         return Collections.EMPTY_SET;
+      }
+
+      public DelegateSupport getDelegate()
+      {
+         return delegate;
+      }
+
+      public void setDelegate(DelegateSupport delegate)
+      {
+         this.delegate = delegate;
+      }
+
+      public HierarchicalState getParent()
+      {
+         return parent;
+      }
+
+      public void setParent(HierarchicalState parent)
+      {
+         this.parent = parent;
+      }
+
+      public Version getVersionToUse()
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public void synchronizeWith(HierarchicalState newState) throws Exception
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+   }
+
+   private class ChildDelegate extends DelegateSupport implements Valve
+   {
+      private boolean valveOpen;
+
+      ChildDelegate()
+      {
+         valveOpen = true;
+      }
+
+      protected Client getClient() throws Exception
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+
+      public synchronized void closeValve() throws Exception
+      {
+         valveOpen = false;
+      }
+
+      public void openValve() throws Exception
+      {
+         valveOpen = true;
+      }
+
+      public boolean isValveOpen()
+      {
+         return valveOpen;
+      }
+
+      public int getActiveThreadsCount()
+      {
+         throw new RuntimeException("NOT YET IMPLEMENTED");
+      }
+   }
+
+   private class InvocationToken
+   {
+      private String methodName;
+
+      public InvocationToken(String methodName)
+      {
+         this.methodName = methodName;
+      }
+
+      public String getMethodName()
+      {
+         return methodName;
+      }
+   }
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/FailoverTest.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -9,16 +9,26 @@
 import org.jboss.test.messaging.jms.clustering.base.ClusteringTestBase;
 import org.jboss.test.messaging.tools.ServerManagement;
 import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.FailoverListener;
+import org.jboss.jms.client.FailoverEvent;
+import org.jboss.jms.client.Valve;
+import org.jboss.jms.client.JBossSession;
+import org.jboss.jms.client.JBossQueueBrowser;
+import org.jboss.jms.client.JBossMessageConsumer;
+import org.jboss.jms.client.JBossMessageProducer;
 import org.jboss.jms.client.state.ConnectionState;
 import org.jboss.jms.client.delegate.DelegateSupport;
 
 import javax.jms.Connection;
 import javax.jms.Session;
 import javax.jms.MessageProducer;
-import javax.jms.DeliveryMode;
 import javax.jms.MessageConsumer;
+import javax.jms.QueueBrowser;
 import javax.jms.TextMessage;
+import javax.jms.DeliveryMode;
 
+import EDU.oswego.cs.dl.util.concurrent.LinkedQueue;
+
 /**
  * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
  * @version <tt>$Revision$</tt>
@@ -27,75 +37,333 @@
  */
 public class FailoverTest extends ClusteringTestBase
 {
-   // Constants -----------------------------------------------------
+   // Constants ------------------------------------------------------------------------------------
 
-   // Static --------------------------------------------------------
+   // Static ---------------------------------------------------------------------------------------
 
-   // Attributes ----------------------------------------------------
+   // Attributes -----------------------------------------------------------------------------------
 
-   // Constructors --------------------------------------------------
+   // Constructors ---------------------------------------------------------------------------------
 
    public FailoverTest(String name)
    {
       super(name);
    }
 
-   // Public --------------------------------------------------------
+   // Public ---------------------------------------------------------------------------------------
 
-   public void testSimpleFailover() throws Exception
+   public void testSimpleConnectionFailover() throws Exception
    {
       Connection conn = null;
 
       try
       {
+         // skip connection to node 0
          conn = cf.createConnection();
          conn.close();
 
+         // create a connection to node 1
          conn = cf.createConnection();
          conn.start();
 
-         // create a producer/consumer on node 1
+         assertEquals(1, ((JBossConnection)conn).getServerID());
 
-         // make sure we're connecting to node 1
+         // register a failover listener
+         SimpleFailoverListener failoverListener = new SimpleFailoverListener();
+         ((JBossConnection)conn).registerFailoverListener(failoverListener);
 
+         log.debug("killing node 1 ....");
+
+         ServerManagement.kill(1);
+
+         log.info("########");
+         log.info("######## KILLED NODE 1");
+         log.info("########");
+
+         // wait for the client-side failover to complete
+
+         while(true)
+         {
+            FailoverEvent event = failoverListener.getEvent(120000);
+            if (event != null && FailoverEvent.FAILOVER_COMPLETED == event.getType())
+            {
+               break;
+            }
+            if (event == null)
+            {
+               fail("Did not get expected FAILOVER_COMPLETED event");
+            }
+         }
+
+         // failover complete
+         log.info("failover completed");
+
+         assertEquals(0, ((JBossConnection)conn).getServerID());
+
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+
+   public void testConnectionAndSessionFailover() throws Exception
+   {
+      Connection conn = null;
+
+      try
+      {
+         // skip connection to node 0
+         conn = cf.createConnection();
+         conn.close();
+
+         // create a connection to node 1
+         conn = cf.createConnection();
+         conn.start();
+
+         assertEquals(1, ((JBossConnection)conn).getServerID());
+
+         Session session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         // register a failover listener
+         SimpleFailoverListener failoverListener = new SimpleFailoverListener();
+         ((JBossConnection)conn).registerFailoverListener(failoverListener);
+
+         log.debug("killing node 1 ....");
+
+         ServerManagement.kill(1);
+
+         log.info("########");
+         log.info("######## KILLED NODE 1");
+         log.info("########");
+
+         // wait for the client-side failover to complete
+
+         while(true)
+         {
+            FailoverEvent event = failoverListener.getEvent(120000);
+            if (event != null && FailoverEvent.FAILOVER_COMPLETED == event.getType())
+            {
+               break;
+            }
+            if (event == null)
+            {
+               fail("Did not get expected FAILOVER_COMPLETED event");
+            }
+         }
+
+         // failover complete
+         log.info("failover completed");
+
+         assertEquals(0, ((JBossConnection)conn).getServerID());
+
+         // use the old session to send/receive a message
+         session.createProducer(queue[0]).send(session.createTextMessage("blik"));
+
+         TextMessage m = (TextMessage)session.createConsumer(queue[0]).receive(2000);
+
+         assertEquals("blik", m.getText());
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+
+
+   public void testFailoverListener() throws Exception
+   {
+      Connection conn = null;
+
+      try
+      {
+         conn = cf.createConnection();
+         conn.close();
+
+         conn = cf.createConnection();
+         conn.start();
+
+         // create a producer/consumer on node 1 and make sure we're connecting to node 1
+
          int nodeID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn).
             getDelegate()).getState()).getServerID();
 
          assertEquals(1, nodeID);
 
-         Session s1 = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
-         MessageConsumer c1 = s1.createConsumer(queue[1]);
-         MessageProducer p1 = s1.createProducer(queue[1]);
-         p1.setDeliveryMode(DeliveryMode.PERSISTENT);
+         SimpleFailoverListener failoverListener = new SimpleFailoverListener();
+         ((JBossConnection)conn).registerFailoverListener(failoverListener);
 
+         // kill node 1
+
+         log.debug("killing node 1");
+
+         ServerManagement.kill(1);
+
+         log.info("########");
+         log.info("######## KILLED NODE 1");
+         log.info("########");
+
+         FailoverEvent event = failoverListener.getEvent(120000);
+
+         assertNotNull(event);
+         assertEquals(FailoverEvent.FAILURE_DETECTED, event.getType());
+         log.info("got " + event);
+
+         event = failoverListener.getEvent(120000);
+
+         assertNotNull(event);
+         assertEquals(FailoverEvent.FAILOVER_STARTED, event.getType());
+         log.info("got " + event);
+
+         event = failoverListener.getEvent(120000);
+
+         assertNotNull(event);
+         assertEquals(FailoverEvent.FAILOVER_COMPLETED, event.getType());
+         log.info("got " + event);
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+
+   public void testCloseValveHierarchy() throws Exception
+   {
+      Connection conn = null;
+
+      try
+      {
+         conn = cf.createConnection();
+
+         assertTrue(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+
+         Session session1 = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         Session session2 = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+
+         assertTrue(((Valve)((JBossSession)session1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session2).getDelegate()).isValveOpen());
+
+         MessageProducer prod1 = session1.createProducer(queue[0]);
+         assertTrue(((Valve)((JBossMessageProducer)prod1).getDelegate()).isValveOpen());
+
+         MessageConsumer cons1 = session1.createConsumer(queue[0]);
+         assertTrue(((Valve)((JBossMessageConsumer)cons1).getDelegate()).isValveOpen());
+
+         QueueBrowser browser1 = session1.createBrowser(queue[0]);
+         assertTrue(((Valve)((JBossQueueBrowser)browser1).getDelegate()).isValveOpen());
+
+         MessageProducer prod2 = session2.createProducer(queue[0]);
+         assertTrue(((Valve)((JBossMessageProducer)prod2).getDelegate()).isValveOpen());
+
+         MessageConsumer cons2 = session2.createConsumer(queue[0]);
+         assertTrue(((Valve)((JBossMessageConsumer)cons2).getDelegate()).isValveOpen());
+
+         QueueBrowser browser2 = session2.createBrowser(queue[0]);
+         assertTrue(((Valve)((JBossQueueBrowser)browser2).getDelegate()).isValveOpen());
+
+         ((JBossConnection)conn).getDelegate().closeValve();
+
+         log.debug("top level valve closed");
+
+         assertFalse(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossSession)session1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossSession)session2).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageProducer)prod1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageConsumer)cons1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossQueueBrowser)browser1).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageProducer)prod2).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossMessageConsumer)cons2).getDelegate()).isValveOpen());
+         assertFalse(((Valve)((JBossQueueBrowser)browser2).getDelegate()).isValveOpen());
+
+         ((JBossConnection)conn).getDelegate().openValve();
+
+         log.debug("top level valve open");
+
+         assertTrue(((Valve)((JBossConnection)conn).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossSession)session2).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageProducer)prod1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageConsumer)cons1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossQueueBrowser)browser1).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageProducer)prod2).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossMessageConsumer)cons2).getDelegate()).isValveOpen());
+         assertTrue(((Valve)((JBossQueueBrowser)browser2).getDelegate()).isValveOpen());
+      }
+      finally
+      {
+         if (conn != null)
+         {
+            conn.close();
+         }
+      }
+   }
+
+   public void testFailoverMessageOnServer() throws Exception
+   {
+      Connection conn = null;
+
+      try
+      {
+         conn = cf.createConnection();
+         conn.close();
+
+         conn = cf.createConnection();
+         conn.start();
+
+         assertEquals(1, ((JBossConnection)conn).getServerID());
+
+         SimpleFailoverListener listener = new SimpleFailoverListener();
+         ((JBossConnection)conn).registerFailoverListener(listener);
+
+         Session session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+         MessageProducer prod = session.createProducer(queue[1]);
+         prod.setDeliveryMode(DeliveryMode.PERSISTENT);
+         MessageConsumer cons = session.createConsumer(queue[0]);
+
+
          // send a message
 
-         p1.send(s1.createTextMessage("blip"));
+         prod.send(session.createTextMessage("blip"));
 
          // kill node 1
 
+         log.debug("killing node 1");
 
+         ServerManagement.kill(1);
 
-         ServerManagement.killAndWait(1);
-
          log.info("########");
          log.info("######## KILLED NODE 1");
          log.info("########");
 
-         try
+         // wait until the failure (not the completion of client-side failover) is detected
+
+         while(true)
          {
-            ic[1].lookup("queue"); // looking up anything
-            fail("The server still alive, kill didn't work yet");
+            FailoverEvent event = listener.getEvent(120000);
+            if (event != null && FailoverEvent.FAILOVER_STARTED == event.getType())
+            {
+               break;
+            }
+            if (event == null)
+            {
+               fail("Did not get expected FAILOVER_COMPLETED event");
+            }
          }
-         catch (Exception e)
-         {
-         }
 
-         // we must receive the message
+         // start to receive the very next moment the failure is detected. This way, we also
+         // test the client-side failover valve
 
-         TextMessage tm = (TextMessage)c1.receive(1000);
+         TextMessage tm = (TextMessage)cons.receive(60000);
          assertEquals("blip", tm.getText());
-
       }
       finally
       {
@@ -106,10 +374,69 @@
       }
    }
 
-   // Package protected ---------------------------------------------
+   // TODO http://jira.jboss.org/jira/browse/JBMESSAGING-712
+//   public void testFailoverMessageOnServer2() throws Exception
+//   {
+//      Connection conn = null;
+//
+//      try
+//      {
+//         conn = cf.createConnection();
+//         conn.close();
+//
+//         conn = cf.createConnection();
+//         conn.start();
+//
+//         assertEquals(1, ((JBossConnection)conn).getServerID());
+//
+//         SimpleFailoverListener listener = new SimpleFailoverListener();
+//         ((JBossConnection)conn).registerFailoverListener(listener);
+//
+//         Session session = conn.createSession(false, Session.AUTO_ACKNOWLEDGE);
+//         MessageProducer prod = session.createProducer(queue[1]);
+//         prod.setDeliveryMode(DeliveryMode.PERSISTENT);
+//
+//         // send a message
+//
+//         prod.send(session.createTextMessage("blip"));
+//
+//         // kill node 1
+//
+//         log.debug("killing node 1");
+//
+//         ServerManagement.kill(1);
+//
+//         log.info("########");
+//         log.info("######## KILLED NODE 1");
+//         log.info("########");
+//
+//         // wait until the failure (not the completion of client-side failover) is detected
+//
+//         assertEquals(FailoverEvent.FAILURE_DETECTED, listener.getEvent(60000).getType());
+//
+//         // create a consumer the very next moment the failure is detected. This way, we also
+//         // test the client-side failover valve
+//
+//         MessageConsumer cons = session.createConsumer(queue[0]);
+//
+//         // we must receive the message
+//
+//         TextMessage tm = (TextMessage)cons.receive(60000);
+//         assertEquals("blip", tm.getText());
+//      }
+//      finally
+//      {
+//         if (conn != null)
+//         {
+//            conn.close();
+//         }
+//      }
+//   }
 
-   // Protected -----------------------------------------------------
+   // Package protected ----------------------------------------------------------------------------
 
+   // Protected ------------------------------------------------------------------------------------
+
    protected void setUp() throws Exception
    {
       nodeCount = 2;
@@ -124,8 +451,39 @@
       super.tearDown();
    }
 
-   // Private -------------------------------------------------------
+   // Private --------------------------------------------------------------------------------------
 
-   // Inner classes -------------------------------------------------
+   // Inner classes --------------------------------------------------------------------------------
 
+   private class SimpleFailoverListener implements FailoverListener
+   {
+      private LinkedQueue buffer;
+
+      public SimpleFailoverListener()
+      {
+         buffer = new LinkedQueue();
+      }
+
+      public void failoverEventOccured(FailoverEvent event)
+      {
+         try
+         {
+            buffer.put(event);
+         }
+         catch(InterruptedException e)
+         {
+            throw new RuntimeException("Putting thread interrupted while trying to add event " +
+               "to buffer", e);
+         }
+      }
+
+      /**
+       * Blocks until a FailoverEvent is available or timeout occurs, in which case returns null.
+       */
+      public FailoverEvent getEvent(long timeout) throws InterruptedException
+      {
+         return (FailoverEvent)buffer.poll(timeout);
+      }
+   }
+
 }

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HAStressTest.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -41,8 +41,9 @@
 /**
  * @author <a href="mailto:clebert.suconic at jboss.org">Clebert Suconic</a>
  * @version <tt>$Revision:$</tt>
- *          <p/>
- *          $Id:$
+ *
+ * 
+ * $Id:$
  */
 public class HAStressTest extends ClusteringTestBase
 {

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/HATest.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -41,7 +41,7 @@
 import org.jboss.jms.client.remoting.JMSRemotingConnection;
 import org.jboss.jms.client.delegate.ClientConnectionDelegate;
 import org.jboss.jms.client.delegate.ClientConnectionFactoryDelegate;
-import org.jboss.jms.client.delegate.ClusteredClientConnectionFactoryDelegate;
+import org.jboss.jms.client.delegate.ClientClusteredConnectionFactoryDelegate;
 import org.jboss.jms.client.delegate.DelegateSupport;
 import org.jboss.jms.client.delegate.ClientSessionDelegate;
 import org.jboss.jms.client.state.ConnectionState;
@@ -156,8 +156,8 @@
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
 
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      ClientClusteredConnectionFactoryDelegate delegate =
+         (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
       log.info ("number of delegates = " + delegate.getDelegates().length);
       log.info ("number of servers = " + ServerManagement.getServer(0).getNodeIDView().size());
@@ -368,8 +368,8 @@
       {
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
 
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         ClientClusteredConnectionFactoryDelegate delegate =
+            (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
          assertEquals(3, ServerManagement.getServer(0).getNodeIDView().size());
 
@@ -429,8 +429,8 @@
 
          log.info("Got connection factory");
 
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         ClientClusteredConnectionFactoryDelegate delegate =
+            (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
 
@@ -475,8 +475,8 @@
 
          JBossConnectionFactory factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
 
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         ClientClusteredConnectionFactoryDelegate delegate =
+            (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
 
@@ -503,8 +503,8 @@
 
          log.info("Got connection factory");
 
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         ClientClusteredConnectionFactoryDelegate delegate =
+            (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
 
@@ -544,8 +544,8 @@
 
          log.info("Got connection factory");
 
-         ClusteredClientConnectionFactoryDelegate delegate =
-            (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+         ClientClusteredConnectionFactoryDelegate delegate =
+            (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
          ClientConnectionFactoryDelegate[] delegates = delegate.getDelegates();
 
@@ -588,8 +588,8 @@
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
 
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      ClientClusteredConnectionFactoryDelegate delegate =
+         (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
       Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
       assertEquals(3, nodeIDView.size());
@@ -726,8 +726,8 @@
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
 
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      ClientClusteredConnectionFactoryDelegate delegate =
+         (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
       Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
       assertEquals(3, nodeIDView.size());
@@ -919,8 +919,8 @@
    {
       JBossConnectionFactory factory =  (JBossConnectionFactory )ic[0].lookup("/ConnectionFactory");
 
-      ClusteredClientConnectionFactoryDelegate delegate =
-         (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+      ClientClusteredConnectionFactoryDelegate delegate =
+         (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 
       Set nodeIDView = ServerManagement.getServer(0).getNodeIDView();
       assertEquals(3, nodeIDView.size());
@@ -1189,8 +1189,8 @@
 // try
 // {
 // JBossConnectionFactory factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
-// ClusteredClientConnectionFactoryDelegate delegate =
-// (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+// ClientClusteredConnectionFactoryDelegate delegate =
+// (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 // log.info ("number of delegates = " + delegate.getDelegates().length);
 // log.info ("number of servers = " + ServerManagement.getServer(0).getNumberOfNodesOnCluster());
 // 
@@ -1218,7 +1218,7 @@
 // ServerManagement.log(ServerManagement.INFO,"##### Looking up ConnectionFactory at testConnectionFactoryConnect");
 // 
 // factory =  (JBossConnectionFactory )ic[2].lookup("/ConnectionFactory");
-// delegate = (ClusteredClientConnectionFactoryDelegate)factory.getDelegate();
+// delegate = (ClientClusteredConnectionFactoryDelegate)factory.getDelegate();
 // 
 // assertEquals(2, ServerManagement.getServer(0).getNumberOfNodesOnCluster());
 // assertEquals(2, delegate.getDelegates().length);
@@ -1240,7 +1240,7 @@
 // 
 // 
 // JBossConnectionFactory jbcf1 = (JBossConnectionFactory)cf;
-// assertTrue(jbcf1.getDelegate() instanceof ClusteredClientConnectionFactoryDelegate);
+// assertTrue(jbcf1.getDelegate() instanceof ClientClusteredConnectionFactoryDelegate);
 // 
 // log.info(">>Lookup Queue");
 // Destination destination = (Destination) ic[2].lookup("topic/testDistributedTopic");

Added: trunk/tests/src/org/jboss/test/messaging/jms/clustering/LoadBalancingTest.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/LoadBalancingTest.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/LoadBalancingTest.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -0,0 +1,175 @@
+/**
+ * JBoss, Home of Professional Open Source
+ *
+ * Distributable under LGPL license.
+ * See terms of license at gnu.org.
+ */
+package org.jboss.test.messaging.jms.clustering;
+
+import org.jboss.test.messaging.tools.ServerManagement;
+import org.jboss.test.messaging.MessagingTestCase;
+import org.jboss.jms.client.JBossConnection;
+import org.jboss.jms.client.state.ConnectionState;
+import org.jboss.jms.client.delegate.DelegateSupport;
+
+import javax.jms.Connection;
+import javax.jms.ConnectionFactory;
+import javax.naming.InitialContext;
+
+/**
+ * This test DOESN'T extend ClusteringTestBase because I want to have control over first invocations
+ * to the server (which are outside of of my control if I use ClusteringTestBase).
+ *
+ * @author <a href="mailto:ovidiu at jboss.org">Ovidiu Feodorov</a>
+ * @version <tt>$Revision: 1.1 $</tt>
+ *
+ * $Id$
+ */
+public class LoadBalancingTest extends MessagingTestCase
+{
+
+   // Constants -----------------------------------------------------
+
+   // Static --------------------------------------------------------
+
+   // Attributes ----------------------------------------------------
+
+   // Constructors --------------------------------------------------
+
+   public LoadBalancingTest(String name)
+   {
+      super(name);
+   }
+
+   // Public --------------------------------------------------------
+
+   public void testLoadBalancingOneNode() throws Exception
+   {
+      ServerManagement.start(0, "all", true);
+
+      try
+      {
+         InitialContext ic = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+
+         ConnectionFactory cf = (ConnectionFactory)ic.lookup("/ConnectionFactory");
+
+         Connection conn0 = cf.createConnection();
+
+         int serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn0).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(0, serverID);
+
+         Connection conn1 = cf.createConnection();
+
+         serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn1).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(0, serverID);
+
+         Connection conn2 = cf.createConnection();
+
+         serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn2).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(0, serverID);
+
+         conn0.close();
+         conn1.close();
+         conn2.close();
+
+         ic.close();
+      }
+      finally
+      {
+         ServerManagement.stop(0);
+      }
+   }
+
+   public void testLoadBalancingTwoNodes() throws Exception
+   {
+      // Make sure all servers are created and started; make sure that database is zapped ONLY for
+      // the first server, the others rely on values they expect to find in shared tables; don't
+      // clear the database for those.
+
+      ServerManagement.start(0, "all", true);
+      ServerManagement.start(1, "all", false);
+
+
+      try
+      {
+         InitialContext ic0 = new InitialContext(ServerManagement.getJNDIEnvironment(0));
+
+         ConnectionFactory cf = (ConnectionFactory)ic0.lookup("/ConnectionFactory");
+
+         Connection conn0 = cf.createConnection();
+
+         int serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn0).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(0, serverID);
+
+         Connection conn1 = cf.createConnection();
+
+         serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn1).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(1, serverID);
+
+         Connection conn2 = cf.createConnection();
+
+         serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn2).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(0, serverID);
+
+         Connection conn3 = cf.createConnection();
+
+         serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn3).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(1, serverID);
+
+         Connection conn4 = cf.createConnection();
+
+         serverID = ((ConnectionState)((DelegateSupport)((JBossConnection)conn4).getDelegate()).
+            getState()).getServerID();
+
+         assertEquals(0, serverID);
+
+
+         conn0.close();
+         conn1.close();
+         conn2.close();
+         conn3.close();
+         conn4.close();
+
+         ic0.close();
+      }
+      finally
+      {
+         ServerManagement.stop(1);
+         ServerManagement.stop(0);
+      }
+   }
+
+   // Package protected ---------------------------------------------
+
+   // Protected -----------------------------------------------------
+
+   protected void setUp() throws Exception
+   {
+      super.setUp();
+      log.debug("setup done");
+   }
+
+   protected void tearDown() throws Exception
+   {
+      super.tearDown();
+   }
+
+   // Private -------------------------------------------------------
+
+   // Inner classes -------------------------------------------------
+
+}

Modified: trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/jms/clustering/base/ClusteringTestBase.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -132,7 +132,8 @@
 
    protected String getLocatorURL(Connection conn)
    {
-      return getConnectionState(conn).getRemotingConnection().getInvokingClient().getInvoker().getLocator().getLocatorURI();
+      return getConnectionState(conn).getRemotingConnection().
+         getInvokingClient().getInvoker().getLocator().getLocatorURI();
    }
 
    protected int getServerId(Connection conn)
@@ -152,7 +153,8 @@
          getDelegate()).getState());
    }
 
-   protected Connection createConnectionOnServer(ConnectionFactory factory, int serverId) throws Exception
+   protected Connection createConnectionOnServer(ConnectionFactory factory, int serverId)
+      throws Exception
    {
       int count=0;
 

Modified: trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/tools/ServerManagement.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -275,7 +275,7 @@
          while(true)
          {
             server.ping();
-            log.info("Server still alive... pinging again");
+            log.debug("Server " + i + " still alive... pinging again");
             Thread.sleep(10);
          }
       }

Modified: trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java
===================================================================
--- trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-31 09:49:46 UTC (rev 1879)
+++ trunk/tests/src/org/jboss/test/messaging/tools/jmx/ServiceContainer.java	2006-12-31 10:51:38 UTC (rev 1880)
@@ -510,7 +510,7 @@
       String persistenceConfigFile =
          "server/default/deploy/" + databaseType + "-persistence-service.xml";
 
-      log.info("********* Using config file: " + persistenceConfigFile);
+      log.info("Peristence config file: .. " + persistenceConfigFile);
 
       URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
       if (persistenceConfigFileURL == null)
@@ -548,7 +548,7 @@
       String persistenceConfigFile =
          "server/default/deploy/" + databaseType + "-persistence-service.xml";
 
-      log.info("********* Using config file: " + persistenceConfigFile);
+      log.info("Peristence config file: .. " + persistenceConfigFile);
 
       URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
       if (persistenceConfigFileURL == null)
@@ -595,7 +595,7 @@
             "server/default/deploy/clustered-" + databaseType + "-persistence-service.xml";
       }
 
-      log.info("********* Using config file: " + persistenceConfigFile);
+      log.info("Peristence config file: .. " + persistenceConfigFile);
 
       URL persistenceConfigFileURL = getClass().getClassLoader().getResource(persistenceConfigFile);
       if (persistenceConfigFileURL == null)



From g8we87g4sa at doramail.com  Sun Dec 31 06:30:34 2006
From: g8we87g4sa at doramail.com (g8we87g4sa at doramail.com)
Date: Sun, 31 Dec 2006 06:30:34 -0500
Subject: [jboss-cvs] =?iso-2022-jp?b?GyRCO2QkSDBsPW8kSzg1QzYkcjdeJCgbKEI=?=
	=?iso-2022-jp?b?GyRCJEYkLyRsJF4kOyRzJCshKRsoQg==?=
Message-ID: 20061231183848.79490mail@mail.buiuweyrwerwepoisdfskdfuisdskdsm.com

????????????????????????
????????????????????????????????
????????????????????????
??????????????????????
?????????????????????
???????????????????????????

http://www.go-perfectfree.com.tonderuyo.com/hame/








???g8we87g4sa at doramail.com




From jboss-cvs-commits at lists.jboss.org  Sun Dec 31 10:13:53 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 31 Dec 2006 10:13:53 -0500
Subject: [jboss-cvs] JBossAS SVN: r59251 - in
	projects/aop/branches/arrays/aop/src:
	main/org/jboss/aop/array test/org/jboss/test/aop/array
Message-ID: <E1H12Nl-00074l-Ao@committer01.frg.pub.inap.atl.jboss.com>

Author: kabir.khan at jboss.com
Date: 2006-12-31 10:13:49 -0500 (Sun, 31 Dec 2006)
New Revision: 59251

Modified:
   projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java
   projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java
Log:
Test that the primitive and object values stored in the arrayelementwriteinvocations match

Modified: projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java
===================================================================
--- projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java	2006-12-30 21:52:49 UTC (rev 59250)
+++ projects/aop/branches/arrays/aop/src/main/org/jboss/aop/array/ShortArrayElementWriteInvocation.java	2006-12-31 15:13:49 UTC (rev 59251)
@@ -54,7 +54,7 @@
       return new Short(value);
    }
 
-   public float getShortValue()
+   public short getShortValue()
    {
       return value;
    }

Modified: projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java
===================================================================
--- projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java	2006-12-30 21:52:49 UTC (rev 59250)
+++ projects/aop/branches/arrays/aop/src/test/org/jboss/test/aop/array/TestArrayElementInterceptor.java	2006-12-31 15:13:49 UTC (rev 59251)
@@ -23,11 +23,23 @@
 
 import java.util.List;
 
+import junit.framework.Assert;
+
 import org.jboss.aop.advice.Interceptor;
 import org.jboss.aop.array.ArrayElementReadInvocation;
 import org.jboss.aop.array.ArrayElementWriteInvocation;
 import org.jboss.aop.array.ArrayReference;
 import org.jboss.aop.array.ArrayRegistry;
+import org.jboss.aop.array.BooleanArrayElementWriteInvocation;
+import org.jboss.aop.array.ByteArrayElementWriteInvocation;
+import org.jboss.aop.array.CharArrayElementWriteInvocation;
+import org.jboss.aop.array.DoubleArrayElementWriteInvocation;
+import org.jboss.aop.array.FloatArrayElementWriteInvocation;
+import org.jboss.aop.array.IntArrayElementReadInvocation;
+import org.jboss.aop.array.IntArrayElementWriteInvocation;
+import org.jboss.aop.array.LongArrayElementWriteInvocation;
+import org.jboss.aop.array.ObjectArrayElementWriteInvocation;
+import org.jboss.aop.array.ShortArrayElementWriteInvocation;
 import org.jboss.aop.joinpoint.Invocation;
 
 /**
@@ -64,10 +76,67 @@
       {
          index = ((ArrayElementWriteInvocation)invocation).getIndex();
          value = ((ArrayElementWriteInvocation)invocation).getValue();
+         checkType((ArrayElementWriteInvocation)invocation);
       } 
       owners = ArrayRegistry.getInstance().getArrayOwners(invocation.getTargetObject());
       invocation.getMetaData().addMetaData("test", "invoked", "TestArrayElementInterceptor");
       return invocation.invokeNext();
    }
 
+   public static class Value
+   {
+      public Object value;
+   }
+   
+   private void checkType(ArrayElementWriteInvocation invocation)
+   {
+      if (invocation instanceof ObjectArrayElementWriteInvocation)
+      {
+         
+      }
+      else if (invocation instanceof ByteArrayElementWriteInvocation)
+      {
+         byte b = ((ByteArrayElementWriteInvocation)invocation).getByteValue();
+         Assert.assertEquals(b, ((Byte)invocation.getValue()).byteValue());
+      }
+      else if (invocation instanceof BooleanArrayElementWriteInvocation)
+      {
+         boolean b = ((BooleanArrayElementWriteInvocation)invocation).getBooleanValue();
+         Assert.assertEquals(b, ((Boolean)invocation.getValue()).booleanValue());
+      }
+      else if (invocation instanceof CharArrayElementWriteInvocation)
+      {
+         char c = ((CharArrayElementWriteInvocation)invocation).getCharValue();
+         Assert.assertEquals(c, ((Character)invocation.getValue()).charValue());
+      }
+      else if (invocation instanceof DoubleArrayElementWriteInvocation)
+      {
+         double d = ((DoubleArrayElementWriteInvocation)invocation).getDoubleValue();
+         Assert.assertEquals(d, ((Double)invocation.getValue()).doubleValue());         
+      }
+      else if (invocation instanceof FloatArrayElementWriteInvocation)
+      {
+         float f = ((FloatArrayElementWriteInvocation)invocation).getFloatValue();
+         Assert.assertEquals(f, ((Float)invocation.getValue()).floatValue());         
+      }
+      else if (invocation instanceof IntArrayElementWriteInvocation)
+      {
+         int i = ((IntArrayElementWriteInvocation)invocation).getIntValue();
+         Assert.assertEquals(i, ((Integer)invocation.getValue()).intValue());         
+      }
+      else if (invocation instanceof LongArrayElementWriteInvocation)
+      {
+         long l = ((LongArrayElementWriteInvocation)invocation).getLongValue();
+         Assert.assertEquals(l, ((Long)invocation.getValue()).longValue());         
+      }
+      else if (invocation instanceof ShortArrayElementWriteInvocation)
+      {
+         short s = ((ShortArrayElementWriteInvocation)invocation).getShortValue();
+         Assert.assertEquals(s, ((Short)invocation.getValue()).shortValue());         
+      }
+      else
+      {
+         throw new RuntimeException("Dodgy invocation type " + invocation.getClass().getName());
+      }
+   }
 }



From gdsa87rewdddd at lycos.com  Sun Dec 31 13:19:29 2006
From: gdsa87rewdddd at lycos.com (gdsa87rewdddd at lycos.com)
Date: Sun, 31 Dec 2006 13:19:29 -0500
Subject: [jboss-cvs] =?utf-8?b?wo7ChMKCw4bCiMOqwo/Cj8KCw4nCjMKzwpJVwok=?=
	=?utf-8?b?w5/CgsKywoLCtcKCw5zCgsK5woLDscKCwqnCgUg=?=
Message-ID: 20070101035149.39891mail@mail.noterrterweoisdfksfjduyisdfskdfjsdkfsim.com



???????N???????X?????[?????????????????????????Im(__)m
???N???????N?????l?????????????????????????N?????y?????????????????v?????c?B
???????????????????????H
???w?????s?????????H
???????????????????????????????????????H(^??^)
??????????????????????????????????
http://www.freeweb.allfreemail.net.tonderuyo.com/meets/
??????????????????????????????????????????????????





From jboss-cvs-commits at lists.jboss.org  Sun Dec 31 14:35:27 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 31 Dec 2006 14:35:27 -0500
Subject: [jboss-cvs] JBossAS SVN: r59252 -
	projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed
Message-ID: <E1H16St-00030T-8q@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-31 14:35:25 -0500 (Sun, 31 Dec 2006)
New Revision: 59252

Modified:
   projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java
Log:
Update the javadoc

Modified: projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java
===================================================================
--- projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java	2006-12-31 15:13:49 UTC (rev 59251)
+++ projects/microcontainer/trunk/managed/src/tests/org/jboss/test/managed/ManagedTestDelegate.java	2006-12-31 19:35:25 UTC (rev 59252)
@@ -29,9 +29,12 @@
 
 /**
  * 
- * ManagedTestDelegate.
+ * ManagedTestDelegate overrides the AbstractTestDelegate to
+ * deploy/undeploy test specific aop descriptors in setUp/tearDown.
  * 
+ * 
  * @author <a href="adrian at jboss.com">Adrian Brock</a>
+ * @author Scott.Stark at jboss.com
  * @version $Revision: 58245 $
  */
 public class ManagedTestDelegate extends AbstractTestDelegate
@@ -50,6 +53,10 @@
       super(clazz);
    }
 
+   /**
+    * Look for a test specific aop descriptor based on the ctor
+    * class first, and if none is found, the ManagedTest.class.
+    */
    public void setUp() throws Exception
    {
       super.setUp();
@@ -57,12 +64,26 @@
          deployAOP(ManagedTest.class);
    }
 
+   /**
+    * Undeployment any test specific aop descriptor deployed in setUp.
+    */
    public void tearDown() throws Exception
    {
       super.tearDown();
       undeployAOP();
    }
 
+   /**
+    * Look for a test specific resource name by appending "-aop.xml"
+    * to the referenceClass name as a resource. For example, a.b.SomeTest
+    * would produce a a/b/SomeTest-aop.xml resource that is queried
+    * for using clazz.getClassLoader().getResource("a/b/SomeTest-aop.xml");
+    *  
+    * @param referenceClass - the class to use as the aop descriptor base name.
+    * @return true if the aop descriptor was found and deployed,
+    *    false otherwise.
+    * @throws Exception on failure to deploy the aop descriptor.
+    */
    protected boolean deployAOP(Class referenceClass) throws Exception
    {
       String testName = referenceClass.getName();
@@ -90,6 +111,11 @@
       }
    }
 
+   /**
+    * Undeploy the aop descriptor deployed in deployAOP if
+    * one was found.
+    *
+    */
    protected void undeployAOP()
    {
       if (aopURL == null)
@@ -105,6 +131,11 @@
       }
    }
 
+   /**
+    * Update the java.protocol.handler.pkgs system property
+    * to include the org.jboss.net.protocol package.
+    *
+    */
    private void initURLHandlers()
    {
       try



From jboss-cvs-commits at lists.jboss.org  Sun Dec 31 15:57:22 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 31 Dec 2006 15:57:22 -0500
Subject: [jboss-cvs] JBossAS SVN:  r59253 - projects/aop/trunk/aop
Message-ID: <E1H17kA-0004Nw-4s@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-31 15:57:20 -0500 (Sun, 31 Dec 2006)
New Revision: 59253

Modified:
   projects/aop/trunk/aop/build.xml
Log:
Add a source artifact

Modified: projects/aop/trunk/aop/build.xml
===================================================================
--- projects/aop/trunk/aop/build.xml	2006-12-31 19:35:25 UTC (rev 59252)
+++ projects/aop/trunk/aop/build.xml	2006-12-31 20:57:20 UTC (rev 59253)
@@ -306,14 +306,14 @@
       | Build all jar files.
     -->
    <target name="jars" description="Builds all jar files."
-      depends="_buildmagic:build-bypass-check"
+      depends="_buildmagic:build-bypass-check, source-jar"
       unless="build-bypass.on">
 
       <call target="compile"/>
 
       <mkdir dir="${build.lib}"/>
 
-      <!-- Build the jnpserver.jar -->
+      <!-- Build the jboss-aop.jar -->
       <jar jarfile="${build.lib}/jboss-aop.jar"
          manifest="${build.etc}/default.mf">
          <fileset dir="${build.classes.retro}">
@@ -352,7 +352,7 @@
    </target>
 
    <target name="jars15" description="Builds all jar files."
-      depends="compile-classes">
+      depends="compile-classes, source-jar">
 
       <mkdir dir="${build.lib}"/>
 
@@ -415,6 +415,14 @@
       </jar>
    </target>
 
+	<target name="source-jar">
+      <jar destfile="${build.lib}/jboss-aop-src.zip"
+         manifest="${build.etc}/default.mf">
+      	<fileset dir="${source.java}">
+      	</fileset>
+     	</jar>
+	</target>
+
    <!-- ================================================================== -->
    <!-- Install & Release                                                  -->
    <!-- ================================================================== -->
@@ -580,6 +588,7 @@
          <fileset dir="output/lib">
             <include name="jboss-aop-jdk50-client.jar"/>
             <include name="jboss-aop-jdk50.jar"/>
+            <include name="jboss-aop-src.zip"/>
             <include name="jrockit-pluggable-instrumentor.jar"/>
             <include name="pluggable-instrumentor.jar"/>
          </fileset>



From gdsar789waga at graffiti.net  Sun Dec 31 15:59:30 2006
From: gdsar789waga at graffiti.net (gdsar789waga at graffiti.net)
Date: Sun, 31 Dec 2006 15:59:30 -0500
Subject: [jboss-cvs] =?utf-8?b?woLCqMKLw6DCgsOwwpdwwojDk8KCwrXCgsOcwoI=?=
	=?utf-8?b?wrXCgsK9woFCwoLCosKCw4LCgsOIwoLDp8KRw6XCj8OkwpV2woLDhcKC?=
	=?utf-8?b?wrfCgsKpwoFI?=
Message-ID: 20040428071749.59219mail@mail.juytgsfsbcnmerrploijnhdytbgrjfnvkgiod.com

?O???????????????????????H
?????????????????????n?????????v???????????B
?????????z???????????????????????A???z?????z?????????c?B
???????l?????????????A?????????????T???u?????????????????????{?S?????B
???????????????s?????????????????????H
http://www.go-perfectfree.com.ksjer.com/yokuy/







From scott.stark at jboss.com  Sun Dec 31 15:59:59 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 31 Dec 2006 15:59:59 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata  ...
Message-ID: <E1H17mh-0004OR-46@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/31 15:59:59

  Modified:    jboss/aop/snapshot-metadata  component-info.xml
  Log:
  Add a jboss-aop-src.zip artifact
  
  Revision  Changes    Path
  1.2       +1 -0      repository.jboss.com/jboss/aop/snapshot-metadata/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/aop/snapshot-metadata/component-info.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- component-info.xml	13 Dec 2006 23:19:48 -0000	1.1
  +++ component-info.xml	31 Dec 2006 20:59:59 -0000	1.2
  @@ -7,6 +7,7 @@
         description="JBoss Aspect Oriented Programming - snapshot from trunk">
   
         <artifact id="jboss-aop-jdk50.jar"/>
  +      <artifact id="jboss-aop-src.zip"/>
         <artifact id="jboss-aop-jdk50-client.jar"/>
         <artifact id="jrockit-pluggable-instrumentor.jar"/>
         <artifact id="pluggable-instrumentor.jar"/>
  
  
  


From scott.stark at jboss.com  Sun Dec 31 15:59:59 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 31 Dec 2006 15:59:59 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot-metadata/lib ...
Message-ID: <E1H17mh-0004Od-AC@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/31 15:59:59

  Modified:    jboss/aop/snapshot-metadata/lib    
                        jboss-aop-jdk50-client.jar jboss-aop-jdk50.jar
                        pluggable-instrumentor.jar
  Added:       jboss/aop/snapshot-metadata/lib     jboss-aop-src.zip
  Log:
  Add a jboss-aop-src.zip artifact
  
  Revision  Changes    Path
  1.2       +205 -230  repository.jboss.com/jboss/aop/snapshot-metadata/lib/jboss-aop-jdk50-client.jar
  
  	<<Binary file>>
  
  
  1.2       +1928 -1917repository.jboss.com/jboss/aop/snapshot-metadata/lib/jboss-aop-jdk50.jar
  
  	<<Binary file>>
  
  
  1.2       +15 -17    repository.jboss.com/jboss/aop/snapshot-metadata/lib/pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/31 20:59:59;  author: starksm;  state: Exp;repository.jboss.com/jboss/aop/snapshot-metadata/lib/jboss-aop-src.zip
  
  	<<Binary file>>
  
  


From scott.stark at jboss.com  Sun Dec 31 16:03:17 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 31 Dec 2006 16:03:17 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot  ...
Message-ID: <E1H17pt-0004fl-2Q@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/31 16:03:17

  Modified:    jboss/aop/snapshot  component-info.xml
  Log:
  Add a jboss-aop-src.zip artifact
  
  Revision  Changes    Path
  1.7       +1 -0      repository.jboss.com/jboss/aop/snapshot/component-info.xml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: component-info.xml
  ===================================================================
  RCS file: /cvsroot/jboss/repository.jboss.com/jboss/aop/snapshot/component-info.xml,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -b -r1.6 -r1.7
  --- component-info.xml	16 Nov 2006 15:58:58 -0000	1.6
  +++ component-info.xml	31 Dec 2006 21:03:17 -0000	1.7
  @@ -7,6 +7,7 @@
         description="JBoss Aspect Oriented Programming - snapshot from trunk">
   
         <artifact id="jboss-aop-jdk50.jar"/>
  +      <artifact id="jboss-aop-src.zip"/>
         <artifact id="jboss-aop-jdk50-client.jar"/>
         <artifact id="jrockit-pluggable-instrumentor.jar"/>
         <artifact id="pluggable-instrumentor.jar"/>
  
  
  


From scott.stark at jboss.com  Sun Dec 31 16:03:17 2006
From: scott.stark at jboss.com (Scott Stark)
Date: Sun, 31 Dec 2006 16:03:17 -0500
Subject: [jboss-cvs] repository.jboss.com/jboss/aop/snapshot/lib     ...
Message-ID: <E1H17pt-0004fx-Mm@committer01.frg.pub.inap.atl.jboss.com>

  User: starksm 
  Date: 06/12/31 16:03:17

  Modified:    jboss/aop/snapshot/lib     jboss-aop-jdk50-client.jar
                        jboss-aop-jdk50.jar pluggable-instrumentor.jar
  Added:       jboss/aop/snapshot/lib     jboss-aop-src.zip
  Log:
  Add a jboss-aop-src.zip artifact
  
  Revision  Changes    Path
  1.13      +132 -131  repository.jboss.com/jboss/aop/snapshot/lib/jboss-aop-jdk50-client.jar
  
  	<<Binary file>>
  
  
  1.19      +1841 -1812repository.jboss.com/jboss/aop/snapshot/lib/jboss-aop-jdk50.jar
  
  	<<Binary file>>
  
  
  1.11      +15 -15    repository.jboss.com/jboss/aop/snapshot/lib/pluggable-instrumentor.jar
  
  	<<Binary file>>
  
  
  1.1      date: 2006/12/31 21:03:17;  author: starksm;  state: Exp;repository.jboss.com/jboss/aop/snapshot/lib/jboss-aop-src.zip
  
  	<<Binary file>>
  
  


From jboss-cvs-commits at lists.jboss.org  Sun Dec 31 16:07:24 2006
From: jboss-cvs-commits at lists.jboss.org (jboss-cvs-commits at lists.jboss.org)
Date: Sun, 31 Dec 2006 16:07:24 -0500
Subject: [jboss-cvs] JBossAS SVN: r59254 -
	projects/microcontainer/trunk/aop-mc-int
Message-ID: <E1H17ts-0004kH-QW@committer01.frg.pub.inap.atl.jboss.com>

Author: scott.stark at jboss.org
Date: 2006-12-31 16:07:22 -0500 (Sun, 31 Dec 2006)
New Revision: 59254

Modified:
   projects/microcontainer/trunk/aop-mc-int/.classpath
Log:
Add jboss-aop-src.zip as the source for aop

Modified: projects/microcontainer/trunk/aop-mc-int/.classpath
===================================================================
--- projects/microcontainer/trunk/aop-mc-int/.classpath	2006-12-31 20:57:20 UTC (rev 59253)
+++ projects/microcontainer/trunk/aop-mc-int/.classpath	2006-12-31 21:07:22 UTC (rev 59254)
@@ -17,6 +17,6 @@
 	<classpathentry kind="lib" path="src/resources/schema"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/jbossxb/lib/jboss-xml-binding.jar"/>
 	<classpathentry kind="lib" path="/thirdparty/jboss/test/lib/jboss-test.jar" sourcepath="/thirdparty/jboss/test/lib/jboss-test-src.zip"/>
-	<classpathentry kind="lib" path="/thirdparty/jboss/aop/lib/jboss-aop-jdk50.jar"/>
+	<classpathentry kind="lib" path="/thirdparty/jboss/aop/lib/jboss-aop-jdk50.jar" sourcepath="/thirdparty/jboss/aop/lib/jboss-aop-src.zip"/>
 	<classpathentry kind="output" path="output/eclipse-classes"/>
 </classpath>



From norman.richards at jboss.com  Sun Dec 31 19:27:48 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 31 Dec 2006 19:27:48 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf  ...
Message-ID: <E1H1B1o-000859-SX@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/31 19:27:48

  Modified:    src/pdf/org/jboss/seam/pdf  ITextUtils.java
  Log:
  add basic facet support, use for default cell style
  
  Revision  Changes    Path
  1.4       +3 -0      jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ITextUtils.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ITextUtils.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ITextUtils.java	31 Dec 2006 06:50:05 -0000	1.3
  +++ ITextUtils.java	1 Jan 2007 00:27:48 -0000	1.4
  @@ -34,6 +34,9 @@
           if (ElementTags.ALIGN_CENTER.equalsIgnoreCase(alignment)) {
               return Element.ALIGN_CENTER;
           }
  +        if (ElementTags.ALIGN_LEFT.equalsIgnoreCase(alignment)) {
  +            return Element.ALIGN_LEFT;
  +        }
           if (ElementTags.ALIGN_RIGHT.equalsIgnoreCase(alignment)) {
               return Element.ALIGN_RIGHT;
           }
  
  
  


From norman.richards at jboss.com  Sun Dec 31 19:27:49 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 31 Dec 2006 19:27:49 -0500
Subject: [jboss-cvs] jboss-seam/src/pdf/org/jboss/seam/pdf/ui ...
Message-ID: <E1H1B1p-00085q-3J@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/31 19:27:49

  Modified:    src/pdf/org/jboss/seam/pdf/ui             
                        ITextComponent.java UIAnchor.java UICell.java
                        UIChapter.java UIDocument.java UIFont.java
                        UIImage.java UIList.java UIListItem.java
                        UIPage.java UIParagraph.java UISection.java
                        UITable.java
  Log:
  add basic facet support, use for default cell style
  
  Revision  Changes    Path
  1.4       +34 -9     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ITextComponent.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/ITextComponent.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- ITextComponent.java	31 Dec 2006 06:50:05 -0000	1.3
  +++ ITextComponent.java	1 Jan 2007 00:27:48 -0000	1.4
  @@ -1,13 +1,15 @@
   package org.jboss.seam.pdf.ui;
   
  -
   import javax.faces.*;
   import javax.faces.context.*;
   import javax.faces.component.*;
  +
   import java.io.*;
  +import java.util.Collection;
  +import java.util.HashMap;
   import java.util.List;
  +import java.util.Map;
   
  -import org.jboss.seam.pdf.ITextUtils;
   import org.jboss.seam.ui.JSF;
   
   import com.lowagie.text.*;
  @@ -17,6 +19,8 @@
   {
       public static final String COMPONENT_FAMILY = "org.jboss.seam.pdf";    
   
  +    protected String inFacet;
  +	protected Map<String,Object> facets = new HashMap<String,Object>();   
     
       /**
        * get the current Itext object
  @@ -32,11 +36,24 @@
        * remove the itext objext
        */
       abstract public void removeITextObject();
  + 
       /** 
  -     * subcomponents should implement this
  +     * subcomponents should implement this to add child components
  +     * to themselves
        */ 
  -    abstract public void add(Object other);
  +    abstract public void handleAdd(Object other);
  +    
  +    final public void add(Object other) {
  +        if (inFacet != null) {
  +           handleFacet(inFacet, other);
  +        } else {
  +            handleAdd(other);
  +        }
  +    }
   
  +    public void handleFacet(String facetName, Object obj) {
  +        facets.put(facetName,obj);
  +	}
   
       /**
        *  look up the tree for an itext font
  @@ -98,6 +115,7 @@
           
       }
   
  +   
       // ------------------------------------------------------
   
       @Override
  @@ -134,6 +152,12 @@
       public void encodeChildren(FacesContext context)
           throws IOException
       {
  +        for (String name: (Collection<String>) this.getFacets().keySet()) {
  +            inFacet = name;
  +    		encode(context, this.getFacet(name));
  +    		inFacet = null;
  +    	}
  +    	
           for (UIComponent child: (List<UIComponent>) this.getChildren()) {
               // ugly hack to be able to capture facelets text
               if (child.getFamily().equals("facelets.LiteralText")) {
  @@ -190,6 +214,7 @@
       }
   
   
  +    @SuppressWarnings("unchecked")
       public void encode(FacesContext context,
                          UIComponent component) 
           throws IOException, 
  
  
  
  1.3       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIAnchor.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIAnchor.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIAnchor.java	25 Dec 2006 16:17:54 -0000	1.2
  +++ UIAnchor.java	1 Jan 2007 00:27:48 -0000	1.3
  @@ -46,7 +46,7 @@
           }
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           anchor.add(o);
       }
   }
  
  
  
  1.4       +16 -4     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UICell.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UICell.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- UICell.java	31 Dec 2006 06:50:05 -0000	1.3
  +++ UICell.java	1 Jan 2007 00:27:48 -0000	1.4
  @@ -198,8 +198,12 @@
       }
   
       public void createITextObject() {
  +    	PdfPCell defaultCell = getDefaultCellFromTable();
  +    	if (defaultCell != null) {
  +    	    cell = new PdfPCell(defaultCell);	   	 
  +    	} else {
           cell = new PdfPCell();
  -
  +    	}
           if (horizontalAlignment != null) {
               cell.setHorizontalAlignment(ITextUtils.alignmentValue(horizontalAlignment));
           }
  @@ -305,7 +309,15 @@
           }
       }
   
  -    public void add(Object o) {
  +    private PdfPCell getDefaultCellFromTable() {
  +    	UITable parentTable = (UITable) findITextParent(this, UITable.class);
  +    	if (parentTable != null) {
  +    		return parentTable.getDefaultCellFacet();
  +    	}
  +		return null;
  +	}
  +
  +	public void handleAdd(Object o) {
           if (o instanceof Element) {
               cell.addElement((Element) o);
           } else {
  
  
  
  1.2       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIChapter.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIChapter.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIChapter.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UIChapter.java	25 Dec 2006 16:17:54 -0000	1.1
  +++ UIChapter.java	1 Jan 2007 00:27:48 -0000	1.2
  @@ -31,7 +31,7 @@
           chapter = new Chapter("*chapter title*",1);
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           chapter.add(o);
       }
   }
  
  
  
  1.3       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIDocument.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIDocument.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIDocument.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIDocument.java	25 Dec 2006 16:17:54 -0000	1.2
  +++ UIDocument.java	1 Jan 2007 00:27:48 -0000	1.3
  @@ -32,7 +32,7 @@
           document = null;
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           if (o instanceof Element) {
               try {
                   document.add((Element) o);
  
  
  
  1.3       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIFont.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIFont.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIFont.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIFont.java	25 Dec 2006 16:17:54 -0000	1.2
  +++ UIFont.java	1 Jan 2007 00:27:48 -0000	1.3
  @@ -52,7 +52,7 @@
           }
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           addToITextParent(o);
       }
   }
  
  
  
  1.4       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIImage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIImage.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- UIImage.java	25 Dec 2006 16:17:54 -0000	1.3
  +++ UIImage.java	1 Jan 2007 00:27:48 -0000	1.4
  @@ -109,7 +109,7 @@
           }
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           throw new RuntimeException("can't add " + o.getClass().getName() + " to image");
           //image.add(o);
       }
  
  
  
  1.4       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIList.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIList.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- UIList.java	25 Dec 2006 16:17:54 -0000	1.3
  +++ UIList.java	1 Jan 2007 00:27:48 -0000	1.4
  @@ -81,7 +81,7 @@
           }
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           list.add(o);
       }
   }
  
  
  
  1.3       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIListItem.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIListItem.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIListItem.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIListItem.java	25 Dec 2006 16:17:54 -0000	1.2
  +++ UIListItem.java	1 Jan 2007 00:27:48 -0000	1.3
  @@ -28,7 +28,7 @@
           listItem = null;
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           listItem.add(o);
       }
   }
  
  
  
  1.3       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIPage.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIPage.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIPage.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UIPage.java	25 Dec 2006 16:17:54 -0000	1.2
  +++ UIPage.java	1 Jan 2007 00:27:48 -0000	1.3
  @@ -26,7 +26,7 @@
           
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           addToITextParent(o);
       }
   
  
  
  
  1.4       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UIParagraph.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UIParagraph.java,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -b -r1.3 -r1.4
  --- UIParagraph.java	25 Dec 2006 16:17:54 -0000	1.3
  +++ UIParagraph.java	1 Jan 2007 00:27:48 -0000	1.4
  @@ -113,7 +113,7 @@
           }
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           paragraph.add(o);
       }
   }
  
  
  
  1.2       +1 -1      jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UISection.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UISection.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UISection.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- UISection.java	25 Dec 2006 16:17:54 -0000	1.1
  +++ UISection.java	1 Jan 2007 00:27:48 -0000	1.2
  @@ -30,7 +30,7 @@
           section.setTitle(new Paragraph("*section title*"));
       }
   
  -    public void add(Object o) {
  +    public void handleAdd(Object o) {
           section.add(o);
       }
   }
  
  
  
  1.3       +16 -3     jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UITable.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: UITable.java
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/src/pdf/org/jboss/seam/pdf/ui/UITable.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -b -r1.2 -r1.3
  --- UITable.java	31 Dec 2006 06:50:05 -0000	1.2
  +++ UITable.java	1 Jan 2007 00:27:48 -0000	1.3
  @@ -1,5 +1,7 @@
   package org.jboss.seam.pdf.ui;
   
  +import org.jboss.seam.pdf.ITextUtils;
  +
   import com.lowagie.text.*;
   import com.lowagie.text.pdf.*;
   
  @@ -51,8 +53,8 @@
           this.headersInEvent = headersInEvent;
       }
       
  -    public void setHorizontalAlignment(Integer horizontalAlignment) {
  -        this.horizontalAlignment = horizontalAlignment;
  +    public void setHorizontalAlignment(String horizontalAlignment) {
  +        this.horizontalAlignment = ITextUtils.alignmentValue(horizontalAlignment);
       }
       
       public void setKeepTogether(Boolean keepTogether) {
  @@ -170,7 +172,7 @@
   		return values;
   	}
   
  -	public void add(Object o) {
  +	public void handleAdd(Object o) {
           if (o instanceof PdfPCell) {
               table.addCell((PdfPCell) o);
           } else if (o instanceof PdfPTable) {
  @@ -184,4 +186,15 @@
                                          " to table");
           }
       }
  +
  +	public PdfPCell getDefaultCellFacet() {
  +		Object facet = facets.get("defaultCell");
  +		if (facet != null) {
  +		    if (!(facet instanceof PdfPCell)) {
  +		    	throw new RuntimeException("UITable defaultCell facet must be a PdfPCell - found " + facet.getClass());
  +		    }
  +		    return (PdfPCell) facet;
  + 		}
  +		return null;
  +	}
   }
  
  
  


From norman.richards at jboss.com  Sun Dec 31 19:31:41 2006
From: norman.richards at jboss.com (Norman Richards)
Date: Sun, 31 Dec 2006 19:31:41 -0500
Subject: [jboss-cvs] jboss-seam/examples/pdf/view   ...
Message-ID: <E1H1B5Z-00089U-FJ@committer01.frg.pub.inap.atl.jboss.com>

  User: nrichards
  Date: 06/12/31 19:31:41

  Modified:    examples/pdf/view   index.xhtml nested.xhtml
  Log:
  use facet for table
  
  Revision  Changes    Path
  1.5       +2 -3      jboss-seam/examples/pdf/view/index.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: index.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/index.xhtml,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -b -r1.4 -r1.5
  --- index.xhtml	31 Dec 2006 06:51:13 -0000	1.4
  +++ index.xhtml	1 Jan 2007 00:31:41 -0000	1.5
  @@ -11,8 +11,8 @@
       <ui:remove><link href="screen.css" rel="stylesheet" type="text/css" /></ui:remove>
   </head>
   <body>
  -      
       <h1>Sample Documents:</h1>
  +
       <ul>
           <li><s:link view="/whyseam.xhtml"   value="Why Seam?" /></li>
           <li><s:link view="/lists.xhtml"     value="PDF Lists" /></li>
  @@ -22,6 +22,5 @@
           <li><s:link view="/table.xhtml"     value="Tables" /></li>
           <li><s:link view="/nested.xhtml"    value="Nested Tables" /></li>
       </ul>
  -    
   </body>
   </html>
  
  
  
  1.2       +15 -9     jboss-seam/examples/pdf/view/nested.xhtml
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: nested.xhtml
  ===================================================================
  RCS file: /cvsroot/jboss/jboss-seam/examples/pdf/view/nested.xhtml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -b -r1.1 -r1.2
  --- nested.xhtml	31 Dec 2006 06:51:13 -0000	1.1
  +++ nested.xhtml	1 Jan 2007 00:31:41 -0000	1.2
  @@ -1,4 +1,5 @@
   <p:document xmlns:ui="http://java.sun.com/jsf/facelets"
  +            xmlns:f="http://java.sun.com/jsf/core"
               xmlns:p="http://jboss.com/products/seam/pdf">
   
   
  @@ -6,26 +7,33 @@
       <p:font size="24"><p:paragraph spacingAfter="50">Nested Tables</p:paragraph></p:font>  
   
       <p:table spacingBefore="25" columns="1">
  +        <f:facet name="defaultCell">
  +            <p:cell borderWidthTop="0" />
  +        </f:facet>
  +
           <p:cell borderWidthTop=".5f" grayFill=".7">
               <p:paragraph alignment="center">Horizontal split using nested tables</p:paragraph>
           </p:cell>
   
  -        <p:cell borderWidthTop="0">one</p:cell>
  -        <p:cell borderWidthTop="0" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
  +        <p:cell>one</p:cell>
  +        <p:cell paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
               <p:table widthPercentage="100" columns="2">
                   <p:cell borderWidth="0">two</p:cell>
                   <p:cell borderWidth="0" borderWidthLeft=".5">three</p:cell>
               </p:table>
           </p:cell>
   
  -        <p:cell borderWidthTop="0" paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
  +        <p:cell paddingLeft="0" paddingRight="0" paddingTop="0" paddingBottom="0">
               <p:table widthPercentage="100" columns="3">
  -                <p:cell borderWidth="0">four</p:cell>
  -                <p:cell borderWidth="0" borderWidthLeft=".5">five</p:cell>
  -                <p:cell borderWidth="0" borderWidthLeft=".5">six</p:cell>
  +                <f:facet name="defaultCell">
  +                    <p:cell borderWidth="0" borderWidthLeft=".5" />
  +                </f:facet>
  +                <p:cell borderWidthLeft="0">four</p:cell>
  +                <p:cell>five</p:cell>
  +                <p:cell>six</p:cell>
               </p:table>
           </p:cell>
  -        <p:cell borderWidthTop="0">seven</p:cell>
  +        <p:cell>seven</p:cell>
       </p:table>
   
       <p:table spacingBefore="25" columns="2" headerRows="1">
  @@ -48,7 +56,5 @@
                   <p:cell borderWidthTop="0">D</p:cell>
               </p:table>
           </p:cell>
  -
       </p:table>
  -
   </p:document>
  
  
  


